Add new system call for non-destructive peek and inspection to posix ipc mqueue
Subsystems (20)
cover Add new system call for non-destructive peek and inspection to posix ipc mqueue
Patch series overview:
1. Add New system call do_mq_timedreceive2() and handler implementation
2. Add system call number in all most common arch.
3. Prepared Documentation and test
4. Add entry in performance tools all most common file
Short Description:
POSIX message queues currently lack a mechanism to read a message without removing it from the queue. This is a long-standing limitation,when we require inspection of queue state without altering it.
Design considerations:
Two approaches for copying message data to userspace were evaluated:
1) Refcount-based message lifecycle handling
- This can help us Avoids intermediate temp kernel copy
- Extends message lifetime
-But this may increase writer starvation under heavy load and
add unnecessary complication on priority management and delay more time to free space in inode due refcount may prevent
2) Temporary kernel buffer copy
- Copies message into a bounded kernel buffer
- Reduces time message remains locked
- Improves fairness under write-heavy workloads
- Simpler lifetime management
My implementation adopts the temporary buffer approach to minimize starvation and reduce locking complexity. The design allows future transition if refcounting is deemed preferable.
Testing:
- 17 functional test cases
- Multi-threaded producer/consumer scenarios
- concurrent pop and peek
- Edge cases: empty queue, FIFO invalid flags, signal interruption etc.
Use Case:
1) Observability in distributed systems
e.g Monitoring tools can inspect queue contents without interfering with
normal processing
2) Check pointing system like CRIU can have a look into queue without consuming and can store messages
3) Resource-aware processing
4) Selective Consumption for Specialized Workers
Thanks for reviewing.
Documentation/userspace-api/index.rst | 1 + Documentation/userspace-api/ipc.rst | 222 +++++ arch/alpha/kernel/syscalls/syscall.tbl | 1 + arch/arm/tools/syscall.tbl | 1 + arch/arm64/tools/syscall_32.tbl | 1 + arch/m68k/kernel/syscalls/syscall.tbl | 1 + arch/microblaze/kernel/syscalls/syscall.tbl | 1 + arch/mips/kernel/syscalls/syscall_n32.tbl | 1 + arch/mips/kernel/syscalls/syscall_n64.tbl | 1 + arch/mips/kernel/syscalls/syscall_o32.tbl | 1 + arch/parisc/kernel/syscalls/syscall.tbl | 1 + arch/powerpc/kernel/syscalls/syscall.tbl | 1 + arch/s390/kernel/syscalls/syscall.tbl | 1 + arch/sh/kernel/syscalls/syscall.tbl | 1 + arch/sparc/kernel/syscalls/syscall.tbl | 1 + arch/x86/entry/syscalls/syscall_32.tbl | 1 + arch/x86/entry/syscalls/syscall_64.tbl | 1 + arch/xtensa/kernel/syscalls/syscall.tbl | 1 + include/linux/compat.h | 6 +- include/linux/syscalls.h | 6 + include/uapi/asm-generic/unistd.h | 7 +- include/uapi/linux/mqueue.h | 18 +- ipc/mqueue.c | 186 ++++- ipc/msg.c | 2 +- ipc/msgutil.c | 48 +- ipc/util.h | 3 +- kernel/sys_ni.c | 1 + scripts/syscall.tbl | 1 + .../arch/alpha/entry/syscalls/syscall.tbl | 1 + .../perf/arch/arm/entry/syscalls/syscall.tbl | 1 + .../arch/arm64/entry/syscalls/syscall_32.tbl | 1 + .../arch/mips/entry/syscalls/syscall_n64.tbl | 1 + .../arch/parisc/entry/syscalls/syscall.tbl | 1 + .../arch/powerpc/entry/syscalls/syscall.tbl | 1 + .../perf/arch/s390/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/sh/entry/syscalls/syscall.tbl | 1 + .../arch/sparc/entry/syscalls/syscall.tbl | 1 + .../arch/x86/entry/syscalls/syscall_32.tbl | 1 + .../arch/x86/entry/syscalls/syscall_64.tbl | 1 + .../arch/xtensa/entry/syscalls/syscall.tbl | 1 + tools/scripts/syscall.tbl | 1 + tools/testing/selftests/ipc/.gitignore | 1 + tools/testing/selftests/ipc/Makefile | 9 +- tools/testing/selftests/ipc/mq_peek.c | 785 ++++++++++++++++++ 44 files changed, 1282 insertions(+), 43 deletions(-) create mode 100644 Documentation/userspace-api/ipc.rst create mode 100644 tools/testing/selftests/ipc/mq_peek.c
Signature · 1 line
2.43.0
PATCH 1/4 IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue
--- include/linux/compat.h | 6 +- include/linux/syscalls.h | 6 + include/uapi/asm-generic/unistd.h | 7 +- include/uapi/linux/mqueue.h | 18 ++- ipc/mqueue.c | 186 ++++++++++++++++++++++++++++-- ipc/msg.c | 2 +- ipc/msgutil.c | 48 ++++---- ipc/util.h | 3 +- kernel/sys_ni.c | 1 + 9 files changed, 235 insertions(+), 42 deletions(-)
include/linux/compat.h +4 -2
@@ -22,6 +22,7 @@#include <asm/compat.h> #include <asm/siginfo.h> #include <asm/signal.h> +#include <linux/mqueue.h> #ifdef CONFIG_ARCH_HAS_SYSCALL_WRAPPER /*
@@ -801,8 +802,9 @@ asmlinkage long compat_sys_pwritev64v2(unsigned long fd,const struct iovec __user *vec, unsigned long vlen, loff_t pos, rwf_t flags);#endif - - +asmlinkage long compat_sys_mq_timedreceive2 (mqd_t mqdes,struct compat_mq_timedreceive2_args __user *uargs, +unsigned int flags,unsigned long index, +struct old_timespec32 __user *abs_timeout);/* * Deprecated system calls which are still defined in * include/uapi/asm-generic/unistd.h and wanted by >= 1 arch
include/linux/syscalls.h +6 -0
@@ -79,6 +79,7 @@ struct mnt_id_req;struct ns_id_req ;struct xattr_args ;struct file_attr ; +struct mq_timedreceive2_args ;#include <linux/types.h> #include <linux/aio_abi.h>
@@ -93,6 +94,7 @@ struct file_attr;#include <linux/key.h> #include <linux/personality.h> #include <trace/syscall.h> +#include <linux/mqueue.h> #ifdef CONFIG_ARCH_HAS_SYSCALL_WRAPPER /*
@@ -746,6 +748,10 @@ asmlinkage long sys_mq_timedsend_time32(mqd_t mqdes,const char __user *u_msg_ptr, unsigned int msg_len, unsigned int msg_prio, const struct old_timespec32 __user *u_abs_timeout); +asmlinkage long +sys_mq_timedreceive2 (mqd_t mqdes,struct mq_timedreceive2_args __user *uargs, +unsigned int flags,unsigned long index, +struct __kernel_timespec __user *abs_timeout);asmlinkage long sys_msgget (key_t key,int msgflg);asmlinkage long sys_old_msgctl (int msqid,int cmd,struct msqid_ds __user *buf);asmlinkage long sys_msgctl (int msqid,int cmd,struct msqid_ds __user *buf);
include/uapi/asm-generic/unistd.h +5 -2
@@ -863,9 +863,12 @@ __SYSCALL(__NR_listns, sys_listns)#define __NR_rseq_slice_yield 471 __SYSCALL(__NR_rseq_slice_yield, sys_rseq_slice_yield) -#undef __NR_syscalls -#define __NR_syscalls 472 +#define __NR_mq_timedreceive2 472 +__SC_COMP (__NR_mq_timedreceive2, sys_mq_timedreceive2, + compat_sys_mq_timedreceive2) +#undef __NR_syscalls +#define __NR_syscalls 473/* * 32 bit systems traditionally used different * syscalls for off_t and loff_t arguments, while
include/uapi/linux/mqueue.h +17 -1
@@ -18,7 +18,6 @@#ifndef _LINUX_MQUEUE_H#define _LINUX_MQUEUE_H -#include <linux/types.h> #define MQ_PRIO_MAX 32768
@@ -33,6 +32,23 @@ struct mq_attr {__kernel_long_t __reserved[4 ];/* ignored for input, zeroed for output */ }; +struct mq_timedreceive2_args { +size_t msg_len; +unsigned int *msg_prio; +char *msg_ptr; +}; + +#ifdef CONFIG_COMPAT +#include <asm/compat.h> + +struct compat_mq_timedreceive2_args { +compat_size_t msg_len; +compat_uptr_t msg_prio; +compat_uptr_t msg_ptr; +}; + +#endif +/* * SIGEV_THREAD implementation: * SIGEV_THREAD must be implemented in user space. If SIGEV_THREAD is passed
ipc/mqueue.c +178 -8
233 lines not on this page · raw message
ipc/msg.c +1 -1
@@ -1156,7 +1156,7 @@ static long do_msgrcv(int msqid, void __user *buf, size_t bufsz, long msgtyp, in* not update queue parameters. */ if (msgflg &MSG_COPY ) { - msg =copy_msg (msg, copy); + msg =copy_msg (msg, copy, msg->m_ts); goto out_unlock0; }
ipc/msgutil.c +21 -27
67 lines not on this page · raw message
ipc/util.h +2 -1
@@ -197,8 +197,9 @@ int ipc_parse_version(int *cmd);extern void free_msg (struct msg_msg *msg);extern struct msg_msg *load_msg (const void __user *src,size_t len); -extern struct msg_msg *copy_msg (struct msg_msg *src,struct msg_msg *dst); +extern struct msg_msg *copy_msg (struct msg_msg *src,struct msg_msg *dst,size_t len);extern int store_msg (void __user *dest,struct msg_msg *msg,size_t len); +extern struct msg_msg *alloc_msg (size_t len);static inline int ipc_checkid (struct kern_ipc_perm *ipcp,int id) {
kernel/sys_ni.c +1 -0
@@ -391,6 +391,7 @@ COND_SYSCALL(setuid16);/* restartable sequence */ COND_SYSCALL (rseq);COND_SYSCALL (rseq_slice_yield); +COND_SYSCALL (mq_timedreceive2);COND_SYSCALL (uretprobe);COND_SYSCALL (uprobe);
Signature · 1 line
2.43.0
PATCH 2/4 IPC: Added system call number in all most common arch.
In reply to Mathura_Kumar--- arch/alpha/kernel/syscalls/syscall.tbl | 1 + arch/arm/tools/syscall.tbl | 1 + arch/arm64/tools/syscall_32.tbl | 1 + arch/m68k/kernel/syscalls/syscall.tbl | 1 + arch/microblaze/kernel/syscalls/syscall.tbl | 1 + arch/mips/kernel/syscalls/syscall_n32.tbl | 1 + arch/mips/kernel/syscalls/syscall_n64.tbl | 1 + arch/mips/kernel/syscalls/syscall_o32.tbl | 1 + arch/parisc/kernel/syscalls/syscall.tbl | 1 + arch/powerpc/kernel/syscalls/syscall.tbl | 1 + arch/s390/kernel/syscalls/syscall.tbl | 1 + arch/sh/kernel/syscalls/syscall.tbl | 1 + arch/sparc/kernel/syscalls/syscall.tbl | 1 + arch/x86/entry/syscalls/syscall_32.tbl | 1 + arch/x86/entry/syscalls/syscall_64.tbl | 1 + arch/xtensa/kernel/syscalls/syscall.tbl | 1 + scripts/syscall.tbl | 1 + 17 files changed, 17 insertions(+)
arch/alpha/kernel/syscalls/syscall.tbl +1 -0
@@ -511,3 +511,4 @@ 579 common file_setattr sys_file_setattr 580 common listns sys_listns 581 common rseq_slice_yield sys_rseq_slice_yield +582 common mq_timedreceive2 sys_mq_timedreceive2
arch/arm/tools/syscall.tbl +1 -0
@@ -486,3 +486,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/arm64/tools/syscall_32.tbl +1 -0
@@ -483,3 +483,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/m68k/kernel/syscalls/syscall.tbl +1 -0
@@ -471,3 +471,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2
arch/microblaze/kernel/syscalls/syscall.tbl +1 -0
@@ -477,3 +477,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2
arch/mips/kernel/syscalls/syscall_n32.tbl +1 -0
@@ -410,3 +410,4 @@ 469 n32 file_setattr sys_file_setattr 470 n32 listns sys_listns 471 n32 rseq_slice_yield sys_rseq_slice_yield +472 n32 mq_timedreceive2 compat_sys_mq_timedreceive2
arch/mips/kernel/syscalls/syscall_n64.tbl +1 -0
@@ -386,3 +386,4 @@ 469 n64 file_setattr sys_file_setattr 470 n64 listns sys_listns 471 n64 rseq_slice_yield sys_rseq_slice_yield +472 n64 mq_timedreceive2 sys_mq_timedreceive2
arch/mips/kernel/syscalls/syscall_o32.tbl +1 -0
@@ -459,3 +459,4 @@ 469 o32 file_setattr sys_file_setattr 470 o32 listns sys_listns 471 o32 rseq_slice_yield sys_rseq_slice_yield +472 o32 mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/parisc/kernel/syscalls/syscall.tbl +1 -0
@@ -470,3 +470,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/powerpc/kernel/syscalls/syscall.tbl +1 -0
@@ -562,3 +562,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 nospu rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/s390/kernel/syscalls/syscall.tbl +1 -0
@@ -398,3 +398,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2
arch/sh/kernel/syscalls/syscall.tbl +1 -0
@@ -475,3 +475,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2
arch/sparc/kernel/syscalls/syscall.tbl +1 -0
@@ -517,3 +517,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/x86/entry/syscalls/syscall_32.tbl +1 -0
@@ -477,3 +477,4 @@ 469 i386 file_setattr sys_file_setattr 470 i386 listns sys_listns 471 i386 rseq_slice_yield sys_rseq_slice_yield +472 i386 mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
arch/x86/entry/syscalls/syscall_64.tbl +1 -0
@@ -441,3 +441,4 @@ 547 x32 pwritev2 compat_sys_pwritev64v2 # This is the end of the legacy x32 range. Numbers 548 and above are # not special and are not to be used for x32-specific syscalls. +548 common mq_timedreceive2 sys_mq_timedreceive2
arch/xtensa/kernel/syscalls/syscall.tbl +1 -0
@@ -442,3 +442,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2
scripts/syscall.tbl +1 -0
@@ -412,3 +412,4 @@ 469 common file_setattr sys_file_setattr 470 common listns sys_listns 471 common rseq_slice_yield sys_rseq_slice_yield +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
Signature · 1 line
2.43.0
PATCH 3/4 IPC: Prepared Documentation and test
In reply to Mathura_Kumar--- Documentation/userspace-api/index.rst | 1 + Documentation/userspace-api/ipc.rst | 222 +++++++ tools/testing/selftests/ipc/.gitignore | 1 + tools/testing/selftests/ipc/Makefile | 9 +- tools/testing/selftests/ipc/mq_peek.c | 785 +++++++++++++++++++++++++ 5 files changed, 1017 insertions(+), 1 deletion(-) create mode 100644 Documentation/userspace-api/ipc.rst create mode 100644 tools/testing/selftests/ipc/mq_peek.c
Documentation/userspace-api/index.rst +1 -0
@@ -22,6 +22,7 @@ System calls ioctl/index mseal rseq + ipc Security-related interfaces ===========================
Documentation/userspace-api/ipc.rst new file +222 -0
222 lines not on this page · raw message
tools/testing/selftests/ipc/.gitignore +1 -0
@@ -1,3 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only msgque_test msgque +mq_peek
tools/testing/selftests/ipc/Makefile +8 -1
@@ -1,6 +1,8 @@ # SPDX-License-Identifier: GPL-2.0 uname_M := $(shell uname -m 2>/dev/null || echo not) ARCH ?= $(shell echo $(uname_M) | sed -e s/i.86/i386/) +CC = gcc +CFLAGS = -static -O2 ifeq ($(ARCH),i386) ARCH := x86 CFLAGS := -DCONFIG_X86_32 -D__i386__
@@ -9,10 +11,15 @@ ifeq ($(ARCH),x86_64) ARCH := x86 CFLAGS := -DCONFIG_X86_64 -D__x86_64__ endif +ifeq ($(ARCH),aarch64) + ARCH := arm64 + CFLAGS := -DCONFIG_ARM64 +endif CFLAGS += $(KHDR_INCLUDES) -TEST_GEN_PROGS := msgque +TEST_GEN_PROGS := msgque mq_peek +LDLIBS += -lrt -lpthread include ../lib.mk
tools/testing/selftests/ipc/mq_peek.c new file +785 -0
785 lines not on this page · raw message
Signature · 1 line
2.43.0
PATCH 4/4 IPC:Added entry in performance tools for new system call
In reply to Mathura_Kumar--- tools/perf/arch/alpha/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/arm/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/arm64/entry/syscalls/syscall_32.tbl | 1 + tools/perf/arch/mips/entry/syscalls/syscall_n64.tbl | 1 + tools/perf/arch/parisc/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/powerpc/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/s390/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/sh/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/sparc/entry/syscalls/syscall.tbl | 1 + tools/perf/arch/x86/entry/syscalls/syscall_32.tbl | 1 + tools/perf/arch/x86/entry/syscalls/syscall_64.tbl | 1 + tools/perf/arch/xtensa/entry/syscalls/syscall.tbl | 1 + tools/scripts/syscall.tbl | 1 + 13 files changed, 13 insertions(+)
tools/perf/arch/alpha/entry/syscalls/syscall.tbl +1 -0
@@ -502,3 +502,4 @@ 570 common lsm_set_self_attr sys_lsm_set_self_attr 571 common lsm_list_modules sys_lsm_list_modules 572 common mseal sys_mseal +582 common mq_timedreceive2 sys_mq_timedreceive2
tools/perf/arch/arm/entry/syscalls/syscall.tbl +1 -0
@@ -485,3 +485,4 @@ 468 common file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr 470 common listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2
tools/perf/arch/arm64/entry/syscalls/syscall_32.tbl +1 -0
@@ -474,3 +474,4 @@ 460 common lsm_set_self_attr sys_lsm_set_self_attr 461 common lsm_list_modules sys_lsm_list_modules 462 common mseal sys_mseal +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/mips/entry/syscalls/syscall_n64.tbl +1 -0
@@ -385,3 +385,4 @@ 468 n64 file_getattr sys_file_getattr 469 n64 file_setattr sys_file_setattr 470 n64 listns sys_listns +472 n64 mq_timedreceive2 sys_mq_timedreceive2
tools/perf/arch/parisc/entry/syscalls/syscall.tbl +1 -0
@@ -461,3 +461,4 @@ 460 common lsm_set_self_attr sys_lsm_set_self_attr 461 common lsm_list_modules sys_lsm_list_modules 462 common mseal sys_mseal +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/powerpc/entry/syscalls/syscall.tbl +1 -0
@@ -561,3 +561,4 @@ 468 common file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr 470 common listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/s390/entry/syscalls/syscall.tbl +1 -0
@@ -473,3 +473,4 @@ 468 common file_getattr sys_file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr sys_file_setattr 470 common listns sys_listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/sh/entry/syscalls/syscall.tbl +1 -0
@@ -474,3 +474,4 @@ 468 common file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr 470 common listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2
tools/perf/arch/sparc/entry/syscalls/syscall.tbl +1 -0
@@ -516,3 +516,4 @@ 468 common file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr 470 common listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/x86/entry/syscalls/syscall_32.tbl +1 -0
@@ -476,3 +476,4 @@ 468 i386 file_getattr sys_file_getattr 469 i386 file_setattr sys_file_setattr 470 i386 listns sys_listns +472 i386 mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/x86/entry/syscalls/syscall_64.tbl +1 -0
@@ -440,3 +440,4 @@ 547 x32 pwritev2 compat_sys_pwritev64v2 # This is the end of the legacy x32 range. Numbers 548 and above are # not special and are not to be used for x32-specific syscalls. +548 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
tools/perf/arch/xtensa/entry/syscalls/syscall.tbl +1 -0
@@ -441,3 +441,4 @@ 468 common file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr 470 common listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2
tools/scripts/syscall.tbl +1 -0
@@ -411,3 +411,4 @@ 468 common file_getattr sys_file_getattr 469 common file_setattr sys_file_setattr 470 common listns sys_listns +472 common mq_timedreceive2 sys_mq_timedreceive2 compat_sys_mq_timedreceive2
Signature · 1 line
2.43.0
kernel test robot
build botRe: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue
In reply to Mathura_Kumarkernel test robot noticed the following build errors:
Hi Mathura_Kumar,
kernel test robot noticed the following build errors:
[auto build test ERROR on perf-tools-next/perf-tools-next]
[also build test ERROR on tip/perf/core perf-tools/perf-tools linus/master v7.0-rc3 next-20260313] [cannot apply to acme/perf/core]
[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/IPC-Added-New-system-call-do_mq_timedreceive2-for-non-destructive-peek-on-posix-mqueue/20260315-143134 base: https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git perf-tools-next patch link: https://lore.kernel.org/r/20260315040827.156558-2-academic1mathura%40gmail.com patch subject: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue config: powerpc64-allnoconfig-bpf (https://download.01.org/0day-ci/archive/20260315/[email protected]/config) compiler: powerpc64-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/20260315/[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/r/[email protected]/
All errors (new ones prefixed by >>):
>> error: include/uapi/linux/mqueue.h: leak CONFIG_COMPAT to user-space
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
kernel test robot
build botRe: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue
In reply to Mathura_Kumarkernel test robot noticed the following build warnings:
Hi Mathura_Kumar,
kernel test robot noticed the following build warnings:
[auto build test WARNING on perf-tools-next/perf-tools-next]
[also build test WARNING on tip/perf/core perf-tools/perf-tools linus/master v7.0-rc6 next-20260402] [cannot apply to acme/perf/core]
[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/IPC-Added-New-system-call-do_mq_timedreceive2-for-non-destructive-peek-on-posix-mqueue/20260315-143134 base: https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git perf-tools-next patch link: https://lore.kernel.org/r/20260315040827.156558-2-academic1mathura%40gmail.com patch subject: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue config: parisc-allyesconfig (https://download.01.org/0day-ci/archive/20260403/[email protected]/config) compiler: hppa-linux-gcc (GCC) 15.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260403/[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 >>):
error: include/uapi/linux/mqueue.h: leak CONFIG_COMPAT to user-space make[3]: *** [scripts/Makefile.headersinst:63: usr/include/linux/mqueue.h] Error 1 make[3]: Target '__headers' not remade because of errors.
make[2]: *** [Makefile:1431: headers] Error 2
In file included from arch/parisc/kernel/signal32.h:9,
from arch/parisc/kernel/asm-offsets.c:34:
>> include/linux/compat.h:805:65: warning: 'struct compat_mq_timedreceive2_args' declared inside parameter list will not be visible outside of this definition or declaration
805 | asmlinkage long compat_sys_mq_timedreceive2(mqd_t mqdes, struct compat_mq_timedreceive2_args __user *uargs,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
make[2]: Target 'prepare' not remade because of errors.
make[1]: *** [Makefile:248: __sub-make] Error 2
make[1]: Target 'prepare' not remade because of errors.
make: *** [Makefile:248: __sub-make] Error 2
make: Target 'prepare' not remade because of errors.
vim +805 include/linux/compat.h
799
800 #ifdef __ARCH_WANT_COMPAT_SYS_PWRITEV64V2
801 asmlinkage long compat_sys_pwritev64v2(unsigned long fd,
802 const struct iovec __user *vec,
803 unsigned long vlen, loff_t pos, rwf_t flags);
804 #endif
> 805 asmlinkage long compat_sys_mq_timedreceive2(mqd_t mqdes, struct compat_mq_timedreceive2_args __user *uargs,
806 unsigned int flags, unsigned long index,
807 struct old_timespec32 __user *abs_timeout);
808 /*
809 * Deprecated system calls which are still defined in
810 * include/uapi/asm-generic/unistd.h and wanted by >= 1 arch
811 */
812
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
kernel test robot
build botRe: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue
In reply to Mathura_Kumarkernel test robot noticed the following build errors:
Hi Mathura_Kumar,
kernel test robot noticed the following build errors:
[auto build test ERROR on perf-tools-next/perf-tools-next]
[also build test ERROR on tip/perf/core perf-tools/perf-tools linus/master v7.0-rc6 next-20260401] [cannot apply to acme/perf/core]
[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/IPC-Added-New-system-call-do_mq_timedreceive2-for-non-destructive-peek-on-posix-mqueue/20260315-143134 base: https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git perf-tools-next patch link: https://lore.kernel.org/r/20260315040827.156558-2-academic1mathura%40gmail.com patch subject: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue config: arc-allmodconfig (https://download.01.org/0day-ci/archive/20260403/[email protected]/config) compiler: arc-linux-gcc (GCC) 15.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260403/[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 errors (new ones prefixed by >>):
>> error: include/uapi/linux/mqueue.h: leak CONFIG_COMPAT to user-space
make[3]: *** [scripts/Makefile.headersinst:63: usr/include/linux/mqueue.h] Error 1 make[3]: Target '__headers' not remade because of errors.
make[2]: *** [Makefile:1431: headers] Error 2
make[2]: Target 'prepare' not remade because of errors.
make[1]: *** [Makefile:248: __sub-make] Error 2
make[1]: Target 'prepare' not remade because of errors.
make: *** [Makefile:248: __sub-make] Error 2
make: Target 'prepare' not remade because of errors.
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
kernel test robot
build botRe: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue
In reply to Mathura_Kumarkernel test robot noticed the following build warnings:
Hi Mathura_Kumar,
kernel test robot noticed the following build warnings:
[auto build test WARNING on perf-tools-next/perf-tools-next]
[also build test WARNING on tip/perf/core perf-tools/perf-tools linus/master v7.0-rc6 next-20260401] [cannot apply to acme/perf/core]
[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/IPC-Added-New-system-call-do_mq_timedreceive2-for-non-destructive-peek-on-posix-mqueue/20260315-143134 base: https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git perf-tools-next patch link: https://lore.kernel.org/r/20260315040827.156558-2-academic1mathura%40gmail.com patch subject: [PATCH v1 1/4] IPC: Added New system call do_mq_timedreceive2() for non-destructive peek on posix mqueue config: arm-allnoconfig (https://download.01.org/0day-ci/archive/20260403/[email protected]/config) compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project e3cbd9984a78422c3799629eb6b5f7f7818c1a11) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260403/[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 init/do_mounts.c:23:
In file included from include/linux/nfs_fs.h:32:
In file included from include/linux/sunrpc/clnt.h:29:
In file included from include/net/ipv6.h:12:
In file included from include/linux/ipv6.h:103:
In file included from include/linux/tcp.h:19:
In file included from include/net/sock.h:46:
In file included from include/linux/netdevice.h:44:
In file included from include/uapi/linux/neighbour.h:6:
In file included from include/linux/netlink.h:9:
In file included from include/net/scm.h:13:
In file included from include/net/compat.h:8:
>> include/linux/compat.h:805:65: warning: declaration of 'struct compat_mq_timedreceive2_args' will not be visible outside of this function [-Wvisibility]
805 | asmlinkage long compat_sys_mq_timedreceive2(mqd_t mqdes, struct compat_mq_timedreceive2_args __user *uargs,
| ^
1 warning generated.
vim +805 include/linux/compat.h
799
800 #ifdef __ARCH_WANT_COMPAT_SYS_PWRITEV64V2
801 asmlinkage long compat_sys_pwritev64v2(unsigned long fd,
802 const struct iovec __user *vec,
803 unsigned long vlen, loff_t pos, rwf_t flags);
804 #endif
> 805 asmlinkage long compat_sys_mq_timedreceive2(mqd_t mqdes, struct compat_mq_timedreceive2_args __user *uargs,
806 unsigned int flags, unsigned long index,
807 struct old_timespec32 __user *abs_timeout);
808 /*
809 * Deprecated system calls which are still defined in
810 * include/uapi/asm-generic/unistd.h and wanted by >= 1 arch
811 */
812
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki