Re: [PATCH 1/3] mqueue: introduce new do_mq_timedreceive2() [ mq_peek syscall] for non-destructive receive and inspection
From: kernel test robot
Date: Thu Mar 05 2026 - 00:09:55 EST
Hi Mathura_Kumar,
kernel test robot noticed the following build errors:
[auto build test ERROR on shuah-kselftest/next]
[also build test ERROR on shuah-kselftest/fixes next-20260304]
[cannot apply to arnd-asm-generic/master linus/master tip/x86/asm v6.16-rc1]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Mathura_Kumar/mqueue-introduce-new-do_mq_timedreceive2-mq_peek-syscall-for-non-destructive-receive-and-inspection/20260305-020107
base: https://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest.git next
patch link: https://lore.kernel.org/r/20260304135126.77270-1-academic1mathura%40gmail.com
patch subject: [PATCH 1/3] mqueue: introduce new do_mq_timedreceive2() [ mq_peek syscall] for non-destructive receive and inspection
config: arm64-allnoconfig-bpf (https://download.01.org/0day-ci/archive/20260305/202603050617.WQwaYhvS-lkp@xxxxxxxxx/config)
compiler: aarch64-linux-gnu-gcc (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260305/202603050617.WQwaYhvS-lkp@xxxxxxxxx/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 <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603050617.WQwaYhvS-lkp@xxxxxxxxx/
All error/warnings (new ones prefixed by >>):
122 | #define __MAP5(m,t,a,...) m(t,a), __MAP4(m,__VA_ARGS__)
| ^~~~~~
./include/linux/syscalls.h:124:22: note: in expansion of macro '__MAP5'
124 | #define __MAP(n,...) __MAP##n(__VA_ARGS__)
| ^~~~~
./arch/arm64/include/asm/syscall_wrapper.h:58:36: note: in expansion of macro '__MAP'
58 | static long __se_sys##name(__MAP(x,__SC_LONG,__VA_ARGS__)) \
| ^~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
ipc/mqueue.c: In function '__se_sys_mq_timedreceive2_time32':
./include/linux/syscalls.h:132:25: error: passing argument 2 of '__do_sys_mq_timedreceive2_time32' from incompatible pointer type [-Wincompatible-pointer-types]
132 | #define __SC_CAST(t, a) (__force t) a
./include/linux/syscalls.h:121:27: note: in expansion of macro '__SC_CAST'
121 | #define __MAP4(m,t,a,...) m(t,a), __MAP3(m,__VA_ARGS__)
| ^
./include/linux/syscalls.h:122:35: note: in expansion of macro '__MAP4'
122 | #define __MAP5(m,t,a,...) m(t,a), __MAP4(m,__VA_ARGS__)
| ^~~~~~
./include/linux/syscalls.h:124:22: note: in expansion of macro '__MAP5'
124 | #define __MAP(n,...) __MAP##n(__VA_ARGS__)
| ^~~~~
./arch/arm64/include/asm/syscall_wrapper.h:60:43: note: in expansion of macro '__MAP'
60 | long ret = __do_sys##name(__MAP(x,__SC_CAST,__VA_ARGS__)); \
| ^~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1745:63: note: expected 'struct compat_mq_timedreceive2_args *' but argument is of type 'struct compat_mq_timedreceive2_args *'
1745 | struct compat_mq_timedreceive2_args __user *, uargs,
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
./include/linux/syscalls.h:126:27: note: in definition of macro '__SC_DECL'
126 | #define __SC_DECL(t, a) t a
| ^
./include/linux/syscalls.h:122:35: note: in expansion of macro '__MAP4'
122 | #define __MAP5(m,t,a,...) m(t,a), __MAP4(m,__VA_ARGS__)
| ^~~~~~
./include/linux/syscalls.h:124:22: note: in expansion of macro '__MAP5'
124 | #define __MAP(n,...) __MAP##n(__VA_ARGS__)
| ^~~~~
./arch/arm64/include/asm/syscall_wrapper.h:53:43: note: in expansion of macro '__MAP'
53 | static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)); \
| ^~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
ipc/mqueue.c: At top level:
ipc/mqueue.c:1745:24: warning: 'struct compat_mq_timedreceive2_args' declared inside parameter list will not be visible outside of this definition or declaration
1745 | struct compat_mq_timedreceive2_args __user *, uargs,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:126:25: note: in definition of macro '__SC_DECL'
126 | #define __SC_DECL(t, a) t a
| ^
./include/linux/syscalls.h:122:35: note: in expansion of macro '__MAP4'
122 | #define __MAP5(m,t,a,...) m(t,a), __MAP4(m,__VA_ARGS__)
| ^~~~~~
./include/linux/syscalls.h:124:22: note: in expansion of macro '__MAP5'
124 | #define __MAP(n,...) __MAP##n(__VA_ARGS__)
| ^~~~~
./arch/arm64/include/asm/syscall_wrapper.h:65:43: note: in expansion of macro '__MAP'
65 | static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__))
| ^~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
In file included from ./include/linux/compat.h:34,
from ./arch/arm64/include/asm/ftrace.h:41,
from ./include/linux/ftrace.h:23,
from ./include/linux/kprobes.h:28,
from ./include/linux/kgdb.h:17,
from ./arch/arm64/include/asm/cacheflush.h:11,
from ./include/linux/cacheflush.h:5,
from ./include/linux/highmem.h:8,
from ./include/linux/pagemap.h:11,
from ipc/mqueue.c:17:
>> ./arch/arm64/include/asm/syscall_wrapper.h:65:28: error: conflicting types for '__do_sys_mq_timedreceive2_time32'; have 'long int(mqd_t, struct compat_mq_timedreceive2_args *, unsigned int, const long unsigned int, const struct old_timespec32 *)' {aka 'long int(int, struct compat_mq_timedreceive2_args *, unsigned int, const long unsigned int, const struct old_timespec32 *)'}
65 | static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__))
| ^~~~~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
./arch/arm64/include/asm/syscall_wrapper.h:53:28: note: previous declaration of '__do_sys_mq_timedreceive2_time32' with type 'long int(mqd_t, struct compat_mq_timedreceive2_args *, unsigned int, const long unsigned int, const struct old_timespec32 *)' {aka 'long int(int, struct compat_mq_timedreceive2_args *, unsigned int, const long unsigned int, const struct old_timespec32 *)'}
53 | static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)); \
| ^~~~~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
ipc/mqueue.c: In function '__do_sys_mq_timedreceive2_time32':
ipc/mqueue.c:1753:13: error: implicit declaration of function 'get_compat_mq_args'; did you mean 'get_compat_msghdr'? [-Wimplicit-function-declaration]
1753 | if (get_compat_mq_args(pargs, uargs))
| ^~~~~~~~~~~~~~~~~~
| get_compat_msghdr
ipc/mqueue.c: At top level:
>> ./arch/arm64/include/asm/syscall_wrapper.h:53:28: warning: '__do_sys_mq_timedreceive2_time32' used but never defined
53 | static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)); \
| ^~~~~~~~
./include/linux/syscalls.h:236:9: note: in expansion of macro '__SYSCALL_DEFINEx'
236 | __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~
./include/linux/syscalls.h:229:36: note: in expansion of macro 'SYSCALL_DEFINEx'
229 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
| ^~~~~~~~~~~~~~~
ipc/mqueue.c:1744:1: note: in expansion of macro 'SYSCALL_DEFINE5'
1744 | SYSCALL_DEFINE5(mq_timedreceive2_time32, mqd_t, mqdes,
| ^~~~~~~~~~~~~~~
vim +65 ./arch/arm64/include/asm/syscall_wrapper.h
4378a7d4be30ec Mark Rutland 2018-07-11 48
4378a7d4be30ec Mark Rutland 2018-07-11 49 #define __SYSCALL_DEFINEx(x, name, ...) \
4378a7d4be30ec Mark Rutland 2018-07-11 50 asmlinkage long __arm64_sys##name(const struct pt_regs *regs); \
4378a7d4be30ec Mark Rutland 2018-07-11 51 ALLOW_ERROR_INJECTION(__arm64_sys##name, ERRNO); \
4378a7d4be30ec Mark Rutland 2018-07-11 52 static long __se_sys##name(__MAP(x,__SC_LONG,__VA_ARGS__)); \
4378a7d4be30ec Mark Rutland 2018-07-11 @53 static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)); \
4378a7d4be30ec Mark Rutland 2018-07-11 54 asmlinkage long __arm64_sys##name(const struct pt_regs *regs) \
4378a7d4be30ec Mark Rutland 2018-07-11 55 { \
4378a7d4be30ec Mark Rutland 2018-07-11 56 return __se_sys##name(SC_ARM64_REGS_TO_ARGS(x,__VA_ARGS__)); \
4378a7d4be30ec Mark Rutland 2018-07-11 57 } \
4378a7d4be30ec Mark Rutland 2018-07-11 58 static long __se_sys##name(__MAP(x,__SC_LONG,__VA_ARGS__)) \
4378a7d4be30ec Mark Rutland 2018-07-11 59 { \
4378a7d4be30ec Mark Rutland 2018-07-11 60 long ret = __do_sys##name(__MAP(x,__SC_CAST,__VA_ARGS__)); \
4378a7d4be30ec Mark Rutland 2018-07-11 61 __MAP(x,__SC_TEST,__VA_ARGS__); \
4378a7d4be30ec Mark Rutland 2018-07-11 62 __PROTECT(x, ret,__MAP(x,__SC_ARGS,__VA_ARGS__)); \
4378a7d4be30ec Mark Rutland 2018-07-11 63 return ret; \
4378a7d4be30ec Mark Rutland 2018-07-11 64 } \
4378a7d4be30ec Mark Rutland 2018-07-11 @65 static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__))
4378a7d4be30ec Mark Rutland 2018-07-11 66
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki