• Jessica Yu's avatar
    module: break nested ARCH_HAS_STRICT_MODULE_RWX and STRICT_MODULE_RWX #ifdefs · db991af0
    Jessica Yu authored
    Various frob_* and module_{enable,disable}_* functions are defined in a
    CONFIG_ARCH_HAS_STRICT_MODULE_RWX ifdef block which also has a nested
    CONFIG_STRICT_MODULE_RWX ifdef block within it. This is unecessary and
    makes things hard to read. Not only that, this construction requires
    redundant empty stubs for module_enable_nx(). I suspect this was
    originally done for cosmetic reasons - to keep all the frob_* functions
    in the same place, and all the module_{enable,disable}_* functions right
    after, but as a result it made the code harder to read.
    
    Make this more readable by unnesting the ifdef blocks and getting rid of
    the redundant empty stubs.
    Signed-off-by: default avatarJessica Yu <jeyu@kernel.org>
    db991af0
module.c 115 KB