• Andrew Morton's avatar
    [PATCH] fix modversions now __this_module is created only in .ko · 7fdaa121
    Andrew Morton authored
    From: Rusty Russell <rusty@rustcorp.com.au>
    
    Brian Gerst's patch which moved __this_module out from module.h into the
    module post-processing had a side effect.  genksyms didn't see the
    undefined symbols for modules without a module_init (or module_exit), and
    hence didn't generate a version for them, causing the kernel to be tainted.
    
    The simple solution is to always include the versions for these functions. 
    Also includes two cleanups:
    
    1) alloc_symbol is easier to use if it populates ->next for us.
    
    2) add_exported_symbol should set owner to module, not head of module
       list (we don't use this field in entries in that list, fortunately).
    7fdaa121
modpost.c 13.7 KB