• Arnd Bergmann's avatar
    lkdtm: mark execute_location as noinline · ececdc02
    Arnd Bergmann authored
    The kernel sometimes fails to link when lkdrm is built-in and
    compiled with clang:
    
    relocation truncated to fit: R_ARM_THM_CALL against `.bss'
    
    The reason here is that a relocation from .text to .bss fails to
    generate a trampoline because .bss is not an executable section.
    
    Marking the function 'noinline' turns the relative branch to .bss
    into an absolute branch to the function argument, and that works
    fine.
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    ececdc02
lkdtm.c 19.8 KB