Skip to contentSkip to conversation

include/linux/security.h:2379:12: warning: no previous prototype for function 'security_uring_allowed'

PATCH kernel test robot 1 participant 1 message Feb 8, 2025

lore
Share & tools
lore

kernel test robot

author build bot
#0 lore raw
tree:   https://github.com/LinuxSecurityModule/kernel next
head:   c6ad9fdbd44b78f51fa50138247694774ab99e97
commit: c6ad9fdbd44b78f51fa50138247694774ab99e97 [2/2] io_uring,lsm,selinux: add LSM hooks for io_uring_setup()
config: x86_64-allnoconfig (https://download.01.org/0day-ci/archive/20250208/[email protected]/config)
compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250208/[email protected]/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

All warnings (new ones prefixed by >>):

In file included from arch/x86/kernel/apic/apic.c:18:
In file included from include/linux/perf_event.h:62:

>> include/linux/security.h:2379:12: warning: no previous prototype for function 'security_uring_allowed' [-Wmissing-prototypes]
    2379 | extern int security_uring_allowed(void)
         |            ^
   include/linux/security.h:2379:8: note: declare 'static' if the function is not intended to be used outside of this translation unit
    2379 | extern int security_uring_allowed(void)
         |        ^
   arch/x86/kernel/apic/apic.c:1889:20: warning: unused function '__x2apic_enable' [-Wunused-function]
    1889 | static inline void __x2apic_enable(void) { }
         |                    ^~~~~~~~~~~~~~~

2 warnings generated.
--
In file included from arch/x86/kernel/apic/vector.c:18:
In file included from arch/x86/include/asm/traps.h:9:
In file included from arch/x86/include/asm/idtentry.h:11:
In file included from include/linux/entry-common.h:7:
In file included from include/linux/syscalls.h:94:
In file included from include/trace/syscall.h:7:
In file included from include/linux/trace_events.h:10:
In file included from include/linux/perf_event.h:62:

>> include/linux/security.h:2379:12: warning: no previous prototype for function 'security_uring_allowed' [-Wmissing-prototypes]

2379 | extern int security_uring_allowed(void)
| ^
include/linux/security.h:2379:8: note: declare 'static' if the function is not intended to be used outside of this translation unit
2379 | extern int security_uring_allowed(void)
| ^
1 warning generated.

vim +/security_uring_allowed +2379 include/linux/security.h

2359
2360 #ifdef CONFIG_IO_URING
2361 #ifdef CONFIG_SECURITY
2362 extern int security_uring_override_creds(const struct cred *new);
2363 extern int security_uring_sqpoll(void);
2364 extern int security_uring_cmd(struct io_uring_cmd *ioucmd);
2365 extern int security_uring_allowed(void);
2366 #else
2367 static inline int security_uring_override_creds(const struct cred *new)
2368 {
2369 return 0;
2370 }
2371 static inline int security_uring_sqpoll(void)
2372 {
2373 return 0;
2374 }
2375 static inline int security_uring_cmd(struct io_uring_cmd *ioucmd)
2376 {
2377 return 0;
2378 }

> 2379	extern int security_uring_allowed(void)

2380 {
2381 return 0;
2382 }
2383 #endif /* CONFIG_SECURITY */
2384 #endif /* CONFIG_IO_URING */
2385

Signature · 2 lines
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki