• Arnd Bergmann's avatar
    kallsyms: fix building without printk · 01c313dd
    Arnd Bergmann authored
    Building kallsyms fails without CONFIG_PRINTK due to a missing
    declaration:
    
      kernel/kallsyms.c: In function 'kallsyms_show_value':
      kernel/kallsyms.c:670:10: error: 'kptr_restrict' undeclared (first use in this function); did you mean 'keyring_restrict'?
    
    This moves the declaration outside of the #ifdef guard, the definition
    is already available without CONFIG_PRINTK.
    
    Fixes: c0f3ea15 ("stop using '%pK' for /proc/kallsyms pointer values")
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    [ I clearly need to start doing "allnoconfig" builds too, or just have a
      test branch for the 0day robot - Linus ]
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    01c313dd
printk.h 14.4 KB