tree: https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git tmp.tmp2 head: adcceb5eb7aee38e4a9c15bdf599655f0e1b1324 commit: 49f47f35436a241df45c13d01c04e19bc5f18799 [318/364] sched/headers, security: Simplify config: x86_64-kexec (attached as .config) compiler: gcc-9 (Debian 9.3.0-22) 9.3.0 reproduce (this is a W=1 build): # https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=49f47f35436a241df45c13d01c04e19bc5f18799 git remote add tip https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git git fetch --no-tags tip tmp.tmp2 git checkout 49f47f35436a241df45c13d01c04e19bc5f18799 # save the attached .config to linux build tree make W=1 ARCH=x86_64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>): In file included from net/core/rtnetlink.c:33: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ In file included from include/linux/uaccess.h:11, from arch/x86/include/asm/fpu/xstate.h:5, from arch/x86/include/asm/pgtable.h:26, from include/linux/pgtable.h:6, from include/linux/mm.h:35, from include/linux/net.h:23, from net/core/rtnetlink.c:25: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from include/linux/workqueue.h:16, from include/linux/srcu_types.h:20, from include/linux/srcu.h:19, from include/linux/notifier.h:16, from arch/x86/include/asm/uprobes.h:13, from include/linux/uprobes.h:49, from include/linux/mm_types.h:14, from include/linux/mmzone.h:21, from include/linux/gfp.h:8, from include/linux/slab.h:15, from fs/nfsd/nfsctl.c:8: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from include/linux/fs_context.h:14, from fs/nfsd/nfsctl.c:11: include/linux/security.h: At top level: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ In file included from include/linux/uaccess.h:11, from include/linux/sched/task.h:11, from include/linux/sched/signal.h:12, from include/linux/sunrpc/types.h:14, from include/linux/sunrpc/svc.h:16, from include/linux/sunrpc/svcsock.h:13, from fs/nfsd/nfsctl.c:13: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from include/linux/xarray.h:16, from include/linux/fs.h:12, from fs/sysfs/symlink.c:12: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from fs/sysfs/symlink.c:16: include/linux/security.h: At top level: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ -- In file included from include/linux/workqueue.h:16, from include/linux/srcu_types.h:20, from include/linux/srcu.h:19, from include/linux/notifier.h:16, from arch/x86/include/asm/uprobes.h:13, from include/linux/uprobes.h:49, from include/linux/mm_types.h:14, from include/linux/mmzone.h:21, from include/linux/gfp.h:8, from include/linux/mm.h:12, from include/linux/pagemap.h:8, from drivers/dax/super.c:5: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from include/linux/fs_context.h:14, from include/linux/pseudo_fs.h:4, from drivers/dax/super.c:8: include/linux/security.h: At top level: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ drivers/dax/super.c:453:6: warning: no previous prototype for 'run_dax' [-Wmissing-prototypes] 453 | void run_dax(struct dax_device *dax_dev) | ^~~~~~~ In file included from include/linux/uaccess.h:11, from arch/x86/include/asm/fpu/xstate.h:5, from arch/x86/include/asm/pgtable.h:26, from include/linux/pgtable.h:6, from include/linux/mm.h:35, from include/linux/pagemap.h:8, from drivers/dax/super.c:5: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from include/linux/workqueue.h:16, from include/linux/srcu_types.h:20, from include/linux/srcu.h:19, from include/linux/notifier.h:16, from arch/x86/include/asm/uprobes.h:13, from include/linux/uprobes.h:49, from include/linux/mm_types.h:14, from include/linux/mmzone.h:21, from include/linux/swap.h:7, from include/linux/suspend.h:5, from kernel/power/hibernate.c:15: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from kernel/power/hibernate.c:33: include/linux/security.h: At top level: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ kernel/power/hibernate.c:272:12: warning: no previous prototype for 'arch_resume_nosmt' [-Wmissing-prototypes] 272 | __weak int arch_resume_nosmt(void) | ^~~~~~~~~~~~~~~~~ In file included from include/linux/uaccess.h:11, from arch/x86/include/asm/fpu/xstate.h:5, from arch/x86/include/asm/pgtable.h:26, from include/linux/pgtable.h:6, from include/linux/mm.h:35, from include/linux/pagemap.h:8, from include/linux/swap.h:11, from include/linux/suspend.h:5, from kernel/power/hibernate.c:15: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from arch/x86/kernel/ioport.c:7: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ In file included from include/linux/xarray.h:16, from include/linux/fs.h:12, from include/uapi/linux/aio_abi.h:31, from include/linux/syscalls.h:76, from arch/x86/kernel/ioport.c:8: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from include/linux/uaccess.h:11, from arch/x86/include/asm/fpu/xstate.h:5, from arch/x86/include/asm/pgtable.h:26, from include/linux/pgtable.h:6, from include/linux/mm.h:35, from include/linux/ring_buffer.h:5, from include/linux/trace_events.h:6, from include/trace/syscall.h:7, from include/linux/syscalls.h:88, from arch/x86/kernel/ioport.c:8: arch/x86/kernel/ioport.c: At top level: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from kernel/header_test_security.h.c:1: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ -- In file included from kernel/uid16.c:15: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ In file included from include/linux/workqueue.h:16, from include/linux/srcu_types.h:20, from include/linux/srcu.h:19, from include/linux/notifier.h:16, from arch/x86/include/asm/uprobes.h:13, from include/linux/uprobes.h:49, from include/linux/mm_types.h:14, from include/linux/mmzone.h:21, from include/linux/gfp.h:8, from include/linux/mm.h:12, from kernel/uid16.c:7: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from include/linux/uaccess.h:11, from arch/x86/include/asm/fpu/xstate.h:5, from arch/x86/include/asm/pgtable.h:26, from include/linux/pgtable.h:6, from include/linux/mm.h:35, from kernel/uid16.c:7: kernel/uid16.c: At top level: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from include/linux/fs_context.h:14, from fs/cifs/fs_context.c:19: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ In file included from include/linux/xarray.h:16, from include/linux/fs.h:12, from fs/cifs/fs_context.c:21: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from include/linux/uaccess.h:11, from arch/x86/include/asm/fpu/xstate.h:5, from arch/x86/include/asm/pgtable.h:26, from include/linux/pgtable.h:6, from include/linux/mm.h:35, from include/linux/bvec.h:14, from include/linux/skbuff.h:19, from include/net/net_namespace.h:39, from include/linux/netdevice.h:39, from include/net/sock.h:48, from fs/cifs/cifspdu.h:25, from fs/cifs/fs_context.c:26: fs/cifs/fs_context.c: At top level: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from kernel/trace/trace_kprobe.c:10: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ In file included from include/linux/rculist.h:11, from kernel/trace/trace_kprobe.c:13: include/linux/rcuwait.h: In function 'rcuwait_active': include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct' 364 | typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \ | ^ include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer' 474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu) | ^~~~~~~~~~~~~~~~~~~~ include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer' 33 | return !!rcu_access_pointer(w->task); | ^~~~~~~~~~~~~~~~~~ In file included from include/linux/uaccess.h:11, from kernel/trace/trace_kprobe.c:12: kernel/trace/trace_kprobe.c: At top level: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ -- In file included from kernel/trace/ftrace.c:22: >> include/linux/security.h:1872:43: error: unknown type name 'key_ref_t' 1872 | static inline int security_key_permission(key_ref_t key_ref, | ^~~~~~~~~ kernel/trace/ftrace.c:303:5: warning: no previous prototype for '__register_ftrace_function' [-Wmissing-prototypes] 303 | int __register_ftrace_function(struct ftrace_ops *ops) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:346:5: warning: no previous prototype for '__unregister_ftrace_function' [-Wmissing-prototypes] 346 | int __unregister_ftrace_function(struct ftrace_ops *ops) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:3877:15: warning: no previous prototype for 'arch_ftrace_match_adjust' [-Wmissing-prototypes] 3877 | char * __weak arch_ftrace_match_adjust(char *str, const char *search) | ^~~~~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/uaccess.h:11, from include/linux/sched/task.h:11, from kernel/trace/ftrace.c:19: arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined 46 | static inline bool pagefault_disabled(void); | ^~~~~~~~~~~~~~~~~~ .. vim +/key_ref_t +1872 include/linux/security.h 29db9190634067 David Howells 2005-10-30 1871 29db9190634067 David Howells 2005-10-30 @1872 static inline int security_key_permission(key_ref_t key_ref, d84f4f992cbd76 David Howells 2008-11-14 1873 const struct cred *cred, 8c0637e950d689 David Howells 2020-05-12 1874 enum key_need_perm need_perm) 29db9190634067 David Howells 2005-10-30 1875 { 29db9190634067 David Howells 2005-10-30 1876 return 0; 29db9190634067 David Howells 2005-10-30 1877 } 29db9190634067 David Howells 2005-10-30 1878 :::::: The code at line 1872 was first introduced by commit :::::: 29db9190634067c5a328ee5fcc2890251b836b4b [PATCH] Keys: Add LSM hooks for key management [try #3] :::::: TO: David Howells :::::: CC: Linus Torvalds --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org