Module Name:    src
Committed By:   christos
Date:           Mon Jul  1 01:36:19 UTC 2024

Modified Files:
        src/sys/compat/linux/arch/aarch64: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c linux_systrace_args.c
        src/sys/compat/linux/arch/alpha: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c
        src/sys/compat/linux/arch/amd64: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c linux_systrace_args.c
        src/sys/compat/linux/arch/arm: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c linux_systrace_args.c
        src/sys/compat/linux/arch/i386: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c linux_systrace_args.c
        src/sys/compat/linux/arch/m68k: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c
        src/sys/compat/linux/arch/mips: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c
        src/sys/compat/linux/arch/powerpc: linux_syscall.h linux_syscallargs.h
            linux_syscalls.c linux_sysent.c

Log Message:
regen


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/sys/compat/linux/arch/aarch64/linux_syscall.h \
    src/sys/compat/linux/arch/aarch64/linux_syscallargs.h \
    src/sys/compat/linux/arch/aarch64/linux_syscalls.c \
    src/sys/compat/linux/arch/aarch64/linux_sysent.c \
    src/sys/compat/linux/arch/aarch64/linux_systrace_args.c
cvs rdiff -u -r1.120 -r1.121 src/sys/compat/linux/arch/alpha/linux_syscall.h \
    src/sys/compat/linux/arch/alpha/linux_sysent.c
cvs rdiff -u -r1.119 -r1.120 \
    src/sys/compat/linux/arch/alpha/linux_syscallargs.h
cvs rdiff -u -r1.121 -r1.122 src/sys/compat/linux/arch/alpha/linux_syscalls.c
cvs rdiff -u -r1.82 -r1.83 src/sys/compat/linux/arch/amd64/linux_syscall.h \
    src/sys/compat/linux/arch/amd64/linux_syscallargs.h \
    src/sys/compat/linux/arch/amd64/linux_syscalls.c \
    src/sys/compat/linux/arch/amd64/linux_sysent.c
cvs rdiff -u -r1.26 -r1.27 \
    src/sys/compat/linux/arch/amd64/linux_systrace_args.c
cvs rdiff -u -r1.93 -r1.94 src/sys/compat/linux/arch/arm/linux_syscall.h \
    src/sys/compat/linux/arch/arm/linux_syscallargs.h \
    src/sys/compat/linux/arch/arm/linux_syscalls.c \
    src/sys/compat/linux/arch/arm/linux_sysent.c
cvs rdiff -u -r1.26 -r1.27 \
    src/sys/compat/linux/arch/arm/linux_systrace_args.c
cvs rdiff -u -r1.127 -r1.128 src/sys/compat/linux/arch/i386/linux_syscall.h \
    src/sys/compat/linux/arch/i386/linux_syscallargs.h \
    src/sys/compat/linux/arch/i386/linux_sysent.c
cvs rdiff -u -r1.128 -r1.129 src/sys/compat/linux/arch/i386/linux_syscalls.c
cvs rdiff -u -r1.22 -r1.23 \
    src/sys/compat/linux/arch/i386/linux_systrace_args.c
cvs rdiff -u -r1.118 -r1.119 src/sys/compat/linux/arch/m68k/linux_syscall.h \
    src/sys/compat/linux/arch/m68k/linux_syscalls.c \
    src/sys/compat/linux/arch/m68k/linux_sysent.c
cvs rdiff -u -r1.117 -r1.118 \
    src/sys/compat/linux/arch/m68k/linux_syscallargs.h
cvs rdiff -u -r1.91 -r1.92 src/sys/compat/linux/arch/mips/linux_syscall.h
cvs rdiff -u -r1.90 -r1.91 src/sys/compat/linux/arch/mips/linux_syscallargs.h \
    src/sys/compat/linux/arch/mips/linux_syscalls.c \
    src/sys/compat/linux/arch/mips/linux_sysent.c
cvs rdiff -u -r1.97 -r1.98 src/sys/compat/linux/arch/powerpc/linux_syscall.h \
    src/sys/compat/linux/arch/powerpc/linux_sysent.c
cvs rdiff -u -r1.96 -r1.97 \
    src/sys/compat/linux/arch/powerpc/linux_syscallargs.h \
    src/sys/compat/linux/arch/powerpc/linux_syscalls.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/compat/linux/arch/aarch64/linux_syscall.h
diff -u src/sys/compat/linux/arch/aarch64/linux_syscall.h:1.11 src/sys/compat/linux/arch/aarch64/linux_syscall.h:1.12
--- src/sys/compat/linux/arch/aarch64/linux_syscall.h:1.11	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/aarch64/linux_syscall.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.11 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.12 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.12 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.13 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -456,6 +456,24 @@
 /* syscall: "sysinfo" ret: "int" args: "struct linux_sysinfo *" */
 #define	LINUX_SYS_sysinfo	179
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	180
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	181
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	182
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	183
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	184
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	185
+
 #ifdef SYSVMSG
 /* syscall: "msgget" ret: "int" args: "key_t" "int" */
 #define	LINUX_SYS_msgget	186
Index: src/sys/compat/linux/arch/aarch64/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/aarch64/linux_syscallargs.h:1.11 src/sys/compat/linux/arch/aarch64/linux_syscallargs.h:1.12
--- src/sys/compat/linux/arch/aarch64/linux_syscallargs.h:1.11	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/aarch64/linux_syscallargs.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.11 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.12 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.12 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.13 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -779,6 +779,50 @@ struct linux_sys_sysinfo_args {
 	syscallarg(struct linux_sysinfo *) arg;
 };
 check_syscall_args(linux_sys_sysinfo)
+
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
 #ifdef SYSVMSG
 
 struct sys_msgget_args;
@@ -1377,6 +1421,18 @@ int	linux_sys_gettid(struct lwp *, const
 
 int	linux_sys_sysinfo(struct lwp *, const struct linux_sys_sysinfo_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 #ifdef SYSVMSG
 int	sys_msgget(struct lwp *, const struct sys_msgget_args *, register_t *);
 
Index: src/sys/compat/linux/arch/aarch64/linux_syscalls.c
diff -u src/sys/compat/linux/arch/aarch64/linux_syscalls.c:1.11 src/sys/compat/linux/arch/aarch64/linux_syscalls.c:1.12
--- src/sys/compat/linux/arch/aarch64/linux_syscalls.c:1.11	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/aarch64/linux_syscalls.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.11 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.12 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.12 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.13 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.11 2024/06/29 13:46:31 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.12 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #if defined(_KERNEL_OPT)
@@ -35,6 +35,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_shm.h>
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_signal.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/linux_syscallargs.h>
 #else /* _KERNEL_OPT */
 #include <sys/null.h>
@@ -221,12 +222,12 @@ const char *const linux_syscallnames[] =
 	/* 177 */	"getegid",
 	/* 178 */	"gettid",
 	/* 179 */	"sysinfo",
-	/* 180 */	"#180 (unimplemented mq_open)",
-	/* 181 */	"#181 (unimplemented mq_unlink)",
-	/* 182 */	"#182 (unimplemented mq_timedsend)",
-	/* 183 */	"#183 (unimplemented mq_timedreceive)",
-	/* 184 */	"#184 (unimplemented mq_notify)",
-	/* 185 */	"#185 (unimplemented mq_getsetattr)",
+	/* 180 */	"mq_open",
+	/* 181 */	"mq_unlink",
+	/* 182 */	"mq_timedsend",
+	/* 183 */	"mq_timedreceive",
+	/* 184 */	"mq_notify",
+	/* 185 */	"mq_getsetattr",
 #ifdef SYSVMSG
 	/* 186 */	"msgget",
 	/* 187 */	"msgctl",
@@ -759,12 +760,12 @@ const char *const altlinux_syscallnames[
 	/* 177 */	NULL, /* getegid */
 	/* 178 */	NULL, /* gettid */
 	/* 179 */	NULL, /* sysinfo */
-	/* 180 */	NULL, /* unimplemented mq_open */
-	/* 181 */	NULL, /* unimplemented mq_unlink */
-	/* 182 */	NULL, /* unimplemented mq_timedsend */
-	/* 183 */	NULL, /* unimplemented mq_timedreceive */
-	/* 184 */	NULL, /* unimplemented mq_notify */
-	/* 185 */	NULL, /* unimplemented mq_getsetattr */
+	/* 180 */	NULL, /* mq_open */
+	/* 181 */	NULL, /* mq_unlink */
+	/* 182 */	NULL, /* mq_timedsend */
+	/* 183 */	NULL, /* mq_timedreceive */
+	/* 184 */	NULL, /* mq_notify */
+	/* 185 */	NULL, /* mq_getsetattr */
 #ifdef SYSVMSG
 	/* 186 */	NULL, /* msgget */
 	/* 187 */	NULL, /* msgctl */
Index: src/sys/compat/linux/arch/aarch64/linux_sysent.c
diff -u src/sys/compat/linux/arch/aarch64/linux_sysent.c:1.11 src/sys/compat/linux/arch/aarch64/linux_sysent.c:1.12
--- src/sys/compat/linux/arch/aarch64/linux_sysent.c:1.11	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/aarch64/linux_sysent.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.11 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.12 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.12 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.13 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.11 2024/06/29 13:46:31 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.12 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_sysv.h"
@@ -34,6 +34,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_shm.h>
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_signal.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/linux_syscallargs.h>
 
 #define	s(type)	sizeof(type)
@@ -815,23 +816,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = (sy_call_t *)linux_sys_sysinfo
 	},		/* 179 = sysinfo */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 180 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 180 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 181 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 181 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 182 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 182 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 183 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 183 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 184 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 184 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 185 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 185 = mq_getsetattr */
 #ifdef SYSVMSG
 	{
 		ns(struct sys_msgget_args),
Index: src/sys/compat/linux/arch/aarch64/linux_systrace_args.c
diff -u src/sys/compat/linux/arch/aarch64/linux_systrace_args.c:1.11 src/sys/compat/linux/arch/aarch64/linux_systrace_args.c:1.12
--- src/sys/compat/linux/arch/aarch64/linux_systrace_args.c:1.11	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/aarch64/linux_systrace_args.c	Sun Jun 30 21:36:18 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_systrace_args.c,v 1.11 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_systrace_args.c,v 1.12 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument to DTrace register array conversion.
@@ -1244,6 +1244,62 @@ systrace_args(register_t sysnum, const v
 		*n_args = 1;
 		break;
 	}
+	/* linux_sys_mq_open */
+	case 180: {
+		const struct linux_sys_mq_open_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		iarg[1] = SCARG(p, oflag); /* int */
+		iarg[2] = SCARG(p, mode); /* linux_umode_t */
+		uarg[3] = (intptr_t) SCARG(p, attr); /* struct linux_mq_attr * */
+		*n_args = 4;
+		break;
+	}
+	/* linux_sys_mq_unlink */
+	case 181: {
+		const struct linux_sys_mq_unlink_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		*n_args = 1;
+		break;
+	}
+	/* linux_sys_mq_timedsend */
+	case 182: {
+		const struct linux_sys_mq_timedsend_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* const char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = SCARG(p, msg_prio); /* unsigned int */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_timedreceive */
+	case 183: {
+		const struct linux_sys_mq_timedreceive_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = (intptr_t) SCARG(p, msg_prio); /* unsigned int * */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_notify */
+	case 184: {
+		const struct linux_sys_mq_notify_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, sevp); /* const struct linux_sigevent * */
+		*n_args = 2;
+		break;
+	}
+	/* linux_sys_mq_getsetattr */
+	case 185: {
+		const struct linux_sys_mq_getsetattr_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, newattr); /* const struct linux_mq_attr * */
+		uarg[2] = (intptr_t) SCARG(p, oldattr); /* struct linux_mq_attr * */
+		*n_args = 3;
+		break;
+	}
 #ifdef SYSVMSG
 	/* sys_msgget */
 	case 186: {
@@ -3832,6 +3888,108 @@ systrace_entry_setargdesc(int sysnum, in
 			break;
 		};
 		break;
+	/* linux_sys_mq_open */
+	case 180:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		case 1:
+			p = "int";
+			break;
+		case 2:
+			p = "linux_umode_t";
+			break;
+		case 3:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_unlink */
+	case 181:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedsend */
+	case 182:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 183:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int *";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_notify */
+	case 184:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_sigevent *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 185:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_mq_attr *";
+			break;
+		case 2:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
 #ifdef SYSVMSG
 	/* sys_msgget */
 	case 186:
@@ -5477,6 +5635,36 @@ systrace_return_setargdesc(int sysnum, i
 		if (ndx == 0 || ndx == 1)
 			p = "int";
 		break;
+	/* linux_sys_mq_open */
+	case 180:
+		if (ndx == 0 || ndx == 1)
+			p = "linux_mqd_t";
+		break;
+	/* linux_sys_mq_unlink */
+	case 181:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedsend */
+	case 182:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 183:
+		if (ndx == 0 || ndx == 1)
+			p = "ssize_t";
+		break;
+	/* linux_sys_mq_notify */
+	case 184:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 185:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
 #ifdef SYSVMSG
 	/* sys_msgget */
 	case 186:

Index: src/sys/compat/linux/arch/alpha/linux_syscall.h
diff -u src/sys/compat/linux/arch/alpha/linux_syscall.h:1.120 src/sys/compat/linux/arch/alpha/linux_syscall.h:1.121
--- src/sys/compat/linux/arch/alpha/linux_syscall.h:1.120	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/alpha/linux_syscall.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.120 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.121 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.107 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.108 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -675,6 +675,24 @@
 /* syscall: "fstat64" ret: "int" args: "int" "struct linux_stat64 *" */
 #define	LINUX_SYS_fstat64	427
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	432
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	433
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	434
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	435
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	436
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	437
+
 /* syscall: "waitid" ret: "int" args: "int" "id_t" "linux_siginfo_t *" "int" "struct rusage50 *" */
 #define	LINUX_SYS_waitid	438
 
Index: src/sys/compat/linux/arch/alpha/linux_sysent.c
diff -u src/sys/compat/linux/arch/alpha/linux_sysent.c:1.120 src/sys/compat/linux/arch/alpha/linux_sysent.c:1.121
--- src/sys/compat/linux/arch/alpha/linux_sysent.c:1.120	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/alpha/linux_sysent.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.120 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.121 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.107 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.108 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.120 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.121 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_sysv.h"
@@ -28,6 +28,8 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_sem.h>
 #include <compat/linux/common/linux_shm.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_machdep.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/linux_syscallargs.h>
 #include <compat/linux/arch/alpha/linux_osf1.h>
 
@@ -1740,23 +1742,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 431 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 432 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 432 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 433 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 433 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 434 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 434 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 435 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 435 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 436 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 436 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 437 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 437 = mq_getsetattr */
 	{
 		ns(struct linux_sys_waitid_args),
 		.sy_flags = SYCALL_ARG_PTR,

Index: src/sys/compat/linux/arch/alpha/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/alpha/linux_syscallargs.h:1.119 src/sys/compat/linux/arch/alpha/linux_syscallargs.h:1.120
--- src/sys/compat/linux/arch/alpha/linux_syscallargs.h:1.119	Sat Jun 29 09:46:31 2024
+++ src/sys/compat/linux/arch/alpha/linux_syscallargs.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.119 2024/06/29 13:46:31 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.120 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.107 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.108 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -1060,6 +1060,50 @@ struct linux_sys_fstat64_args {
 };
 check_syscall_args(linux_sys_fstat64)
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_waitid_args {
 	syscallarg(int) idtype;
 	syscallarg(id_t) id;
@@ -1795,6 +1839,18 @@ int	linux_sys_lstat64(struct lwp *, cons
 
 int	linux_sys_fstat64(struct lwp *, const struct linux_sys_fstat64_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_waitid(struct lwp *, const struct linux_sys_waitid_args *, register_t *);
 
 int	linux_sys_inotify_init(struct lwp *, const void *, register_t *);

Index: src/sys/compat/linux/arch/alpha/linux_syscalls.c
diff -u src/sys/compat/linux/arch/alpha/linux_syscalls.c:1.121 src/sys/compat/linux/arch/alpha/linux_syscalls.c:1.122
--- src/sys/compat/linux/arch/alpha/linux_syscalls.c:1.121	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/alpha/linux_syscalls.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.121 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.122 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.107 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.108 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.121 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.122 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #if defined(_KERNEL_OPT)
@@ -29,6 +29,8 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_sem.h>
 #include <compat/linux/common/linux_shm.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_machdep.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/linux_syscallargs.h>
 #include <compat/linux/arch/alpha/linux_osf1.h>
 #else /* _KERNEL_OPT */
@@ -492,12 +494,12 @@ const char *const linux_syscallnames[] =
 	/* 429 */	"#429 (unimplemented mbind)",
 	/* 430 */	"#430 (unimplemented get_mempolicy)",
 	/* 431 */	"#431 (unimplemented set_mempolicy)",
-	/* 432 */	"#432 (unimplemented mq_open)",
-	/* 433 */	"#433 (unimplemented mq_unlink)",
-	/* 434 */	"#434 (unimplemented mq_timedsend)",
-	/* 435 */	"#435 (unimplemented mq_timedreceive)",
-	/* 436 */	"#436 (unimplemented mq_notify)",
-	/* 437 */	"#437 (unimplemented mq_getsetattr)",
+	/* 432 */	"mq_open",
+	/* 433 */	"mq_unlink",
+	/* 434 */	"mq_timedsend",
+	/* 435 */	"mq_timedreceive",
+	/* 436 */	"mq_notify",
+	/* 437 */	"mq_getsetattr",
 	/* 438 */	"waitid",
 	/* 439 */	"#439 (unimplemented add_key)",
 	/* 440 */	"#440 (unimplemented request_key)",
@@ -1545,12 +1547,12 @@ const char *const altlinux_syscallnames[
 	/* 429 */	NULL, /* unimplemented mbind */
 	/* 430 */	NULL, /* unimplemented get_mempolicy */
 	/* 431 */	NULL, /* unimplemented set_mempolicy */
-	/* 432 */	NULL, /* unimplemented mq_open */
-	/* 433 */	NULL, /* unimplemented mq_unlink */
-	/* 434 */	NULL, /* unimplemented mq_timedsend */
-	/* 435 */	NULL, /* unimplemented mq_timedreceive */
-	/* 436 */	NULL, /* unimplemented mq_notify */
-	/* 437 */	NULL, /* unimplemented mq_getsetattr */
+	/* 432 */	NULL, /* mq_open */
+	/* 433 */	NULL, /* mq_unlink */
+	/* 434 */	NULL, /* mq_timedsend */
+	/* 435 */	NULL, /* mq_timedreceive */
+	/* 436 */	NULL, /* mq_notify */
+	/* 437 */	NULL, /* mq_getsetattr */
 	/* 438 */	NULL, /* waitid */
 	/* 439 */	NULL, /* unimplemented add_key */
 	/* 440 */	NULL, /* unimplemented request_key */

Index: src/sys/compat/linux/arch/amd64/linux_syscall.h
diff -u src/sys/compat/linux/arch/amd64/linux_syscall.h:1.82 src/sys/compat/linux/arch/amd64/linux_syscall.h:1.83
--- src/sys/compat/linux/arch/amd64/linux_syscall.h:1.82	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/amd64/linux_syscall.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.82 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.83 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.73 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.74 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -621,6 +621,24 @@
 /* syscall: "utimes" ret: "int" args: "const char *" "const struct timeval50 *" */
 #define	LINUX_SYS_utimes	235
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	240
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	241
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	242
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	243
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	244
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	245
+
 /* syscall: "waitid" ret: "int" args: "int" "id_t" "linux_siginfo_t *" "int" "struct rusage50 *" */
 #define	LINUX_SYS_waitid	247
 
Index: src/sys/compat/linux/arch/amd64/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/amd64/linux_syscallargs.h:1.82 src/sys/compat/linux/arch/amd64/linux_syscallargs.h:1.83
--- src/sys/compat/linux/arch/amd64/linux_syscallargs.h:1.82	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/amd64/linux_syscallargs.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.82 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.83 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.73 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.74 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -950,6 +950,50 @@ check_syscall_args(linux_sys_tgkill)
 
 struct compat_50_sys_utimes_args;
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_waitid_args {
 	syscallarg(int) idtype;
 	syscallarg(id_t) id;
@@ -1658,6 +1702,18 @@ int	linux_sys_tgkill(struct lwp *, const
 
 int	compat_50_sys_utimes(struct lwp *, const struct compat_50_sys_utimes_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_waitid(struct lwp *, const struct linux_sys_waitid_args *, register_t *);
 
 int	linux_sys_inotify_init(struct lwp *, const void *, register_t *);
Index: src/sys/compat/linux/arch/amd64/linux_syscalls.c
diff -u src/sys/compat/linux/arch/amd64/linux_syscalls.c:1.82 src/sys/compat/linux/arch/amd64/linux_syscalls.c:1.83
--- src/sys/compat/linux/arch/amd64/linux_syscalls.c:1.82	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/amd64/linux_syscalls.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.82 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.83 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.73 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.74 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.82 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.83 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #if defined(_KERNEL_OPT)
@@ -34,6 +34,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_shm.h>
 #include <compat/linux/common/linux_signal.h>
 #include <compat/linux/common/linux_siginfo.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/linux_syscallargs.h>
 #else /* _KERNEL_OPT */
@@ -308,12 +309,12 @@ const char *const linux_syscallnames[] =
 	/* 237 */	"#237 (unimplemented mbind)",
 	/* 238 */	"#238 (unimplemented set_mempolicy)",
 	/* 239 */	"#239 (unimplemented get_mempolicy)",
-	/* 240 */	"#240 (unimplemented mq_open)",
-	/* 241 */	"#241 (unimplemented mq_unlink)",
-	/* 242 */	"#242 (unimplemented mq_timedsend)",
-	/* 243 */	"#243 (unimplemented mq_timedreceive)",
-	/* 244 */	"#244 (unimplemented mq_notify)",
-	/* 245 */	"#245 (unimplemented mq_getsetattr)",
+	/* 240 */	"mq_open",
+	/* 241 */	"mq_unlink",
+	/* 242 */	"mq_timedsend",
+	/* 243 */	"mq_timedreceive",
+	/* 244 */	"mq_notify",
+	/* 245 */	"mq_getsetattr",
 	/* 246 */	"#246 (unimplemented kexec_load)",
 	/* 247 */	"waitid",
 	/* 248 */	"#248 (unimplemented add_key)",
@@ -852,12 +853,12 @@ const char *const altlinux_syscallnames[
 	/* 237 */	NULL, /* unimplemented mbind */
 	/* 238 */	NULL, /* unimplemented set_mempolicy */
 	/* 239 */	NULL, /* unimplemented get_mempolicy */
-	/* 240 */	NULL, /* unimplemented mq_open */
-	/* 241 */	NULL, /* unimplemented mq_unlink */
-	/* 242 */	NULL, /* unimplemented mq_timedsend */
-	/* 243 */	NULL, /* unimplemented mq_timedreceive */
-	/* 244 */	NULL, /* unimplemented mq_notify */
-	/* 245 */	NULL, /* unimplemented mq_getsetattr */
+	/* 240 */	NULL, /* mq_open */
+	/* 241 */	NULL, /* mq_unlink */
+	/* 242 */	NULL, /* mq_timedsend */
+	/* 243 */	NULL, /* mq_timedreceive */
+	/* 244 */	NULL, /* mq_notify */
+	/* 245 */	NULL, /* mq_getsetattr */
 	/* 246 */	NULL, /* unimplemented kexec_load */
 	/* 247 */	NULL, /* waitid */
 	/* 248 */	NULL, /* unimplemented add_key */
Index: src/sys/compat/linux/arch/amd64/linux_sysent.c
diff -u src/sys/compat/linux/arch/amd64/linux_sysent.c:1.82 src/sys/compat/linux/arch/amd64/linux_sysent.c:1.83
--- src/sys/compat/linux/arch/amd64/linux_sysent.c:1.82	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/amd64/linux_sysent.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.82 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.83 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.73 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.74 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.82 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.83 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_sysv.h"
@@ -33,6 +33,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_shm.h>
 #include <compat/linux/common/linux_signal.h>
 #include <compat/linux/common/linux_siginfo.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/linux_syscallargs.h>
 
@@ -1127,23 +1128,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 239 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 240 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 240 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 241 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 241 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 242 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 242 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 243 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 243 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 244 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 244 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 245 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 245 = mq_getsetattr */
 	{
 		.sy_call = linux_sys_nosys,
 	},		/* 246 = filler */

Index: src/sys/compat/linux/arch/amd64/linux_systrace_args.c
diff -u src/sys/compat/linux/arch/amd64/linux_systrace_args.c:1.26 src/sys/compat/linux/arch/amd64/linux_systrace_args.c:1.27
--- src/sys/compat/linux/arch/amd64/linux_systrace_args.c:1.26	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/amd64/linux_systrace_args.c	Sun Jun 30 21:36:18 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_systrace_args.c,v 1.26 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_systrace_args.c,v 1.27 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument to DTrace register array conversion.
@@ -1654,6 +1654,62 @@ systrace_args(register_t sysnum, const v
 		*n_args = 2;
 		break;
 	}
+	/* linux_sys_mq_open */
+	case 240: {
+		const struct linux_sys_mq_open_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		iarg[1] = SCARG(p, oflag); /* int */
+		iarg[2] = SCARG(p, mode); /* linux_umode_t */
+		uarg[3] = (intptr_t) SCARG(p, attr); /* struct linux_mq_attr * */
+		*n_args = 4;
+		break;
+	}
+	/* linux_sys_mq_unlink */
+	case 241: {
+		const struct linux_sys_mq_unlink_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		*n_args = 1;
+		break;
+	}
+	/* linux_sys_mq_timedsend */
+	case 242: {
+		const struct linux_sys_mq_timedsend_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* const char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = SCARG(p, msg_prio); /* unsigned int */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_timedreceive */
+	case 243: {
+		const struct linux_sys_mq_timedreceive_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = (intptr_t) SCARG(p, msg_prio); /* unsigned int * */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_notify */
+	case 244: {
+		const struct linux_sys_mq_notify_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, sevp); /* const struct linux_sigevent * */
+		*n_args = 2;
+		break;
+	}
+	/* linux_sys_mq_getsetattr */
+	case 245: {
+		const struct linux_sys_mq_getsetattr_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, newattr); /* const struct linux_mq_attr * */
+		uarg[2] = (intptr_t) SCARG(p, oldattr); /* struct linux_mq_attr * */
+		*n_args = 3;
+		break;
+	}
 	/* linux_sys_waitid */
 	case 247: {
 		const struct linux_sys_waitid_args *p = params;
@@ -4793,6 +4849,108 @@ systrace_entry_setargdesc(int sysnum, in
 			break;
 		};
 		break;
+	/* linux_sys_mq_open */
+	case 240:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		case 1:
+			p = "int";
+			break;
+		case 2:
+			p = "linux_umode_t";
+			break;
+		case 3:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_unlink */
+	case 241:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedsend */
+	case 242:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 243:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int *";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_notify */
+	case 244:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_sigevent *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 245:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_mq_attr *";
+			break;
+		case 2:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
 	/* linux_sys_waitid */
 	case 247:
 		switch(ndx) {
@@ -6534,6 +6692,36 @@ systrace_return_setargdesc(int sysnum, i
 		if (ndx == 0 || ndx == 1)
 			p = "int";
 		break;
+	/* linux_sys_mq_open */
+	case 240:
+		if (ndx == 0 || ndx == 1)
+			p = "linux_mqd_t";
+		break;
+	/* linux_sys_mq_unlink */
+	case 241:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedsend */
+	case 242:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 243:
+		if (ndx == 0 || ndx == 1)
+			p = "ssize_t";
+		break;
+	/* linux_sys_mq_notify */
+	case 244:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 245:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
 	/* linux_sys_waitid */
 	case 247:
 		if (ndx == 0 || ndx == 1)

Index: src/sys/compat/linux/arch/arm/linux_syscall.h
diff -u src/sys/compat/linux/arch/arm/linux_syscall.h:1.93 src/sys/compat/linux/arch/arm/linux_syscall.h:1.94
--- src/sys/compat/linux/arch/arm/linux_syscall.h:1.93	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/arm/linux_syscall.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.93 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.94 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -679,6 +679,24 @@
 /* syscall: "fadvise64_64" ret: "int" args: "int" "off_t" "off_t" "int" */
 #define	LINUX_SYS_fadvise64_64	270
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	274
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	275
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	276
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	277
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	278
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	279
+
 /* syscall: "waitid" ret: "int" args: "int" "id_t" "linux_siginfo_t *" "int" "struct rusage50 *" */
 #define	LINUX_SYS_waitid	280
 
Index: src/sys/compat/linux/arch/arm/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/arm/linux_syscallargs.h:1.93 src/sys/compat/linux/arch/arm/linux_syscallargs.h:1.94
--- src/sys/compat/linux/arch/arm/linux_syscallargs.h:1.93	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/arm/linux_syscallargs.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.93 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.94 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:52 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -1024,6 +1024,50 @@ struct linux_sys_fadvise64_64_args {
 };
 check_syscall_args(linux_sys_fadvise64_64)
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_waitid_args {
 	syscallarg(int) idtype;
 	syscallarg(id_t) id;
@@ -1747,6 +1791,18 @@ int	compat_50_sys_utimes(struct lwp *, c
 
 int	linux_sys_fadvise64_64(struct lwp *, const struct linux_sys_fadvise64_64_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_waitid(struct lwp *, const struct linux_sys_waitid_args *, register_t *);
 
 int	linux_sys_inotify_init(struct lwp *, const void *, register_t *);
Index: src/sys/compat/linux/arch/arm/linux_syscalls.c
diff -u src/sys/compat/linux/arch/arm/linux_syscalls.c:1.93 src/sys/compat/linux/arch/arm/linux_syscalls.c:1.94
--- src/sys/compat/linux/arch/arm/linux_syscalls.c:1.93	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/arm/linux_syscalls.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.93 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.94 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.93 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.94 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include <sys/param.h>
@@ -24,6 +24,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_signal.h>
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 #else /* _KERNEL_OPT */
@@ -310,12 +311,12 @@ const char *const linux_syscallnames[] =
 	/* 271 */	"#271 (unimplemented pciconfig_iobase)",
 	/* 272 */	"#272 (unimplemented pciconfig_read)",
 	/* 273 */	"#273 (unimplemented pciconfig_write)",
-	/* 274 */	"#274 (unimplemented mq_open)",
-	/* 275 */	"#275 (unimplemented mq_unlink)",
-	/* 276 */	"#276 (unimplemented mq_timedsend)",
-	/* 277 */	"#277 (unimplemented mq_timedreceive)",
-	/* 278 */	"#278 (unimplemented mq_notify)",
-	/* 279 */	"#279 (unimplemented mq_getsetattr)",
+	/* 274 */	"mq_open",
+	/* 275 */	"mq_unlink",
+	/* 276 */	"mq_timedsend",
+	/* 277 */	"mq_timedreceive",
+	/* 278 */	"mq_notify",
+	/* 279 */	"mq_getsetattr",
 	/* 280 */	"waitid",
 	/* 281 */	"#281 (unimplemented socket)",
 	/* 282 */	"#282 (unimplemented bind)",
@@ -832,12 +833,12 @@ const char *const altlinux_syscallnames[
 	/* 271 */	NULL, /* unimplemented pciconfig_iobase */
 	/* 272 */	NULL, /* unimplemented pciconfig_read */
 	/* 273 */	NULL, /* unimplemented pciconfig_write */
-	/* 274 */	NULL, /* unimplemented mq_open */
-	/* 275 */	NULL, /* unimplemented mq_unlink */
-	/* 276 */	NULL, /* unimplemented mq_timedsend */
-	/* 277 */	NULL, /* unimplemented mq_timedreceive */
-	/* 278 */	NULL, /* unimplemented mq_notify */
-	/* 279 */	NULL, /* unimplemented mq_getsetattr */
+	/* 274 */	NULL, /* mq_open */
+	/* 275 */	NULL, /* mq_unlink */
+	/* 276 */	NULL, /* mq_timedsend */
+	/* 277 */	NULL, /* mq_timedreceive */
+	/* 278 */	NULL, /* mq_notify */
+	/* 279 */	NULL, /* mq_getsetattr */
 	/* 280 */	NULL, /* waitid */
 	/* 281 */	NULL, /* unimplemented socket */
 	/* 282 */	NULL, /* unimplemented bind */
Index: src/sys/compat/linux/arch/arm/linux_sysent.c
diff -u src/sys/compat/linux/arch/arm/linux_sysent.c:1.93 src/sys/compat/linux/arch/arm/linux_sysent.c:1.94
--- src/sys/compat/linux/arch/arm/linux_sysent.c:1.93	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/arm/linux_sysent.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.93 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.94 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:52 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.93 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.94 2024/07/01 01:36:18 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/poll.h>
@@ -23,6 +23,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_signal.h>
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 
@@ -1200,23 +1201,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 273 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 274 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 274 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 275 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 275 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 276 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 276 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 277 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 277 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 278 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 278 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 279 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 279 = mq_getsetattr */
 	{
 		ns(struct linux_sys_waitid_args),
 		.sy_flags = SYCALL_ARG_PTR,

Index: src/sys/compat/linux/arch/arm/linux_systrace_args.c
diff -u src/sys/compat/linux/arch/arm/linux_systrace_args.c:1.26 src/sys/compat/linux/arch/arm/linux_systrace_args.c:1.27
--- src/sys/compat/linux/arch/arm/linux_systrace_args.c:1.26	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/arm/linux_systrace_args.c	Sun Jun 30 21:36:18 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_systrace_args.c,v 1.26 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_systrace_args.c,v 1.27 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument to DTrace register array conversion.
@@ -1753,6 +1753,62 @@ systrace_args(register_t sysnum, const v
 		*n_args = 4;
 		break;
 	}
+	/* linux_sys_mq_open */
+	case 274: {
+		const struct linux_sys_mq_open_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		iarg[1] = SCARG(p, oflag); /* int */
+		iarg[2] = SCARG(p, mode); /* linux_umode_t */
+		uarg[3] = (intptr_t) SCARG(p, attr); /* struct linux_mq_attr * */
+		*n_args = 4;
+		break;
+	}
+	/* linux_sys_mq_unlink */
+	case 275: {
+		const struct linux_sys_mq_unlink_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		*n_args = 1;
+		break;
+	}
+	/* linux_sys_mq_timedsend */
+	case 276: {
+		const struct linux_sys_mq_timedsend_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* const char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = SCARG(p, msg_prio); /* unsigned int */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_timedreceive */
+	case 277: {
+		const struct linux_sys_mq_timedreceive_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = (intptr_t) SCARG(p, msg_prio); /* unsigned int * */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_notify */
+	case 278: {
+		const struct linux_sys_mq_notify_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, sevp); /* const struct linux_sigevent * */
+		*n_args = 2;
+		break;
+	}
+	/* linux_sys_mq_getsetattr */
+	case 279: {
+		const struct linux_sys_mq_getsetattr_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, newattr); /* const struct linux_mq_attr * */
+		uarg[2] = (intptr_t) SCARG(p, oldattr); /* struct linux_mq_attr * */
+		*n_args = 3;
+		break;
+	}
 	/* linux_sys_waitid */
 	case 280: {
 		const struct linux_sys_waitid_args *p = params;
@@ -4996,6 +5052,108 @@ systrace_entry_setargdesc(int sysnum, in
 			break;
 		};
 		break;
+	/* linux_sys_mq_open */
+	case 274:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		case 1:
+			p = "int";
+			break;
+		case 2:
+			p = "linux_umode_t";
+			break;
+		case 3:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_unlink */
+	case 275:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedsend */
+	case 276:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 277:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int *";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_notify */
+	case 278:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_sigevent *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 279:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_mq_attr *";
+			break;
+		case 2:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
 	/* linux_sys_waitid */
 	case 280:
 		switch(ndx) {
@@ -6803,6 +6961,36 @@ systrace_return_setargdesc(int sysnum, i
 		if (ndx == 0 || ndx == 1)
 			p = "int";
 		break;
+	/* linux_sys_mq_open */
+	case 274:
+		if (ndx == 0 || ndx == 1)
+			p = "linux_mqd_t";
+		break;
+	/* linux_sys_mq_unlink */
+	case 275:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedsend */
+	case 276:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 277:
+		if (ndx == 0 || ndx == 1)
+			p = "ssize_t";
+		break;
+	/* linux_sys_mq_notify */
+	case 278:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 279:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
 	/* linux_sys_waitid */
 	case 280:
 		if (ndx == 0 || ndx == 1)

Index: src/sys/compat/linux/arch/i386/linux_syscall.h
diff -u src/sys/compat/linux/arch/i386/linux_syscall.h:1.127 src/sys/compat/linux/arch/i386/linux_syscall.h:1.128
--- src/sys/compat/linux/arch/i386/linux_syscall.h:1.127	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/i386/linux_syscall.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.127 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.128 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.135 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.136 2024/07/01 01:35:53 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -701,6 +701,24 @@
 /* syscall: "fadvise64_64" ret: "int" args: "int" "off_t" "off_t" "int" */
 #define	LINUX_SYS_fadvise64_64	272
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	277
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	278
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	279
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	280
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	281
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	282
+
 /* syscall: "waitid" ret: "int" args: "int" "id_t" "linux_siginfo_t *" "int" "struct rusage50 *" */
 #define	LINUX_SYS_waitid	284
 
Index: src/sys/compat/linux/arch/i386/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/i386/linux_syscallargs.h:1.127 src/sys/compat/linux/arch/i386/linux_syscallargs.h:1.128
--- src/sys/compat/linux/arch/i386/linux_syscallargs.h:1.127	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/i386/linux_syscallargs.h	Sun Jun 30 21:36:18 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.127 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.128 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.135 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.136 2024/07/01 01:35:53 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -1071,6 +1071,50 @@ struct linux_sys_fadvise64_64_args {
 };
 check_syscall_args(linux_sys_fadvise64_64)
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_waitid_args {
 	syscallarg(int) idtype;
 	syscallarg(id_t) id;
@@ -1781,6 +1825,18 @@ int	compat_50_sys_utimes(struct lwp *, c
 
 int	linux_sys_fadvise64_64(struct lwp *, const struct linux_sys_fadvise64_64_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_waitid(struct lwp *, const struct linux_sys_waitid_args *, register_t *);
 
 int	linux_sys_inotify_init(struct lwp *, const void *, register_t *);
Index: src/sys/compat/linux/arch/i386/linux_sysent.c
diff -u src/sys/compat/linux/arch/i386/linux_sysent.c:1.127 src/sys/compat/linux/arch/i386/linux_sysent.c:1.128
--- src/sys/compat/linux/arch/i386/linux_sysent.c:1.127	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/i386/linux_sysent.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.127 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.128 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.135 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.136 2024/07/01 01:35:53 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.127 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.128 2024/07/01 01:36:18 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/poll.h>
@@ -22,6 +22,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_signal.h>
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 
@@ -1222,23 +1223,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 276 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 277 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 277 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 278 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 278 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 279 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 279 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 280 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 280 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 281 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 281 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 282 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 282 = mq_getsetattr */
 	{
 		.sy_call = linux_sys_nosys,
 	},		/* 283 = filler */

Index: src/sys/compat/linux/arch/i386/linux_syscalls.c
diff -u src/sys/compat/linux/arch/i386/linux_syscalls.c:1.128 src/sys/compat/linux/arch/i386/linux_syscalls.c:1.129
--- src/sys/compat/linux/arch/i386/linux_syscalls.c:1.128	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/i386/linux_syscalls.c	Sun Jun 30 21:36:18 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.128 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.129 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.135 2024/06/29 13:46:09 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.136 2024/07/01 01:35:53 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.128 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.129 2024/07/01 01:36:18 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include <sys/param.h>
@@ -23,6 +23,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_signal.h>
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 #else /* _KERNEL_OPT */
@@ -312,12 +313,12 @@ const char *const linux_syscallnames[] =
 	/* 274 */	"#274 (unimplemented mbind)",
 	/* 275 */	"#275 (unimplemented get_mempolicy)",
 	/* 276 */	"#276 (unimplemented set_mempolicy)",
-	/* 277 */	"#277 (unimplemented mq_open)",
-	/* 278 */	"#278 (unimplemented mq_unlink)",
-	/* 279 */	"#279 (unimplemented mq_timedsend)",
-	/* 280 */	"#280 (unimplemented mq_timedreceive)",
-	/* 281 */	"#281 (unimplemented mq_notify)",
-	/* 282 */	"#282 (unimplemented mq_getsetattr)",
+	/* 277 */	"mq_open",
+	/* 278 */	"mq_unlink",
+	/* 279 */	"mq_timedsend",
+	/* 280 */	"mq_timedreceive",
+	/* 281 */	"mq_notify",
+	/* 282 */	"mq_getsetattr",
 	/* 283 */	"#283 (unimplemented sys_kexec_load)",
 	/* 284 */	"waitid",
 	/* 285 */	"#285 (unimplemented / * unused * /)",
@@ -834,12 +835,12 @@ const char *const altlinux_syscallnames[
 	/* 274 */	NULL, /* unimplemented mbind */
 	/* 275 */	NULL, /* unimplemented get_mempolicy */
 	/* 276 */	NULL, /* unimplemented set_mempolicy */
-	/* 277 */	NULL, /* unimplemented mq_open */
-	/* 278 */	NULL, /* unimplemented mq_unlink */
-	/* 279 */	NULL, /* unimplemented mq_timedsend */
-	/* 280 */	NULL, /* unimplemented mq_timedreceive */
-	/* 281 */	NULL, /* unimplemented mq_notify */
-	/* 282 */	NULL, /* unimplemented mq_getsetattr */
+	/* 277 */	NULL, /* mq_open */
+	/* 278 */	NULL, /* mq_unlink */
+	/* 279 */	NULL, /* mq_timedsend */
+	/* 280 */	NULL, /* mq_timedreceive */
+	/* 281 */	NULL, /* mq_notify */
+	/* 282 */	NULL, /* mq_getsetattr */
 	/* 283 */	NULL, /* unimplemented sys_kexec_load */
 	/* 284 */	NULL, /* waitid */
 	/* 285 */	NULL, /* unimplemented / * unused * / */

Index: src/sys/compat/linux/arch/i386/linux_systrace_args.c
diff -u src/sys/compat/linux/arch/i386/linux_systrace_args.c:1.22 src/sys/compat/linux/arch/i386/linux_systrace_args.c:1.23
--- src/sys/compat/linux/arch/i386/linux_systrace_args.c:1.22	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/i386/linux_systrace_args.c	Sun Jun 30 21:36:18 2024
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_systrace_args.c,v 1.22 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_systrace_args.c,v 1.23 2024/07/01 01:36:18 christos Exp $ */
 
 /*
  * System call argument to DTrace register array conversion.
@@ -1816,6 +1816,62 @@ systrace_args(register_t sysnum, const v
 		*n_args = 4;
 		break;
 	}
+	/* linux_sys_mq_open */
+	case 277: {
+		const struct linux_sys_mq_open_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		iarg[1] = SCARG(p, oflag); /* int */
+		iarg[2] = SCARG(p, mode); /* linux_umode_t */
+		uarg[3] = (intptr_t) SCARG(p, attr); /* struct linux_mq_attr * */
+		*n_args = 4;
+		break;
+	}
+	/* linux_sys_mq_unlink */
+	case 278: {
+		const struct linux_sys_mq_unlink_args *p = params;
+		uarg[0] = (intptr_t) SCARG(p, name); /* const char * */
+		*n_args = 1;
+		break;
+	}
+	/* linux_sys_mq_timedsend */
+	case 279: {
+		const struct linux_sys_mq_timedsend_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* const char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = SCARG(p, msg_prio); /* unsigned int */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_timedreceive */
+	case 280: {
+		const struct linux_sys_mq_timedreceive_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, msg_ptr); /* char * */
+		uarg[2] = SCARG(p, msg_len); /* size_t */
+		uarg[3] = (intptr_t) SCARG(p, msg_prio); /* unsigned int * */
+		uarg[4] = (intptr_t) SCARG(p, abs_timeout); /* const struct linux_timespec * */
+		*n_args = 5;
+		break;
+	}
+	/* linux_sys_mq_notify */
+	case 281: {
+		const struct linux_sys_mq_notify_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, sevp); /* const struct linux_sigevent * */
+		*n_args = 2;
+		break;
+	}
+	/* linux_sys_mq_getsetattr */
+	case 282: {
+		const struct linux_sys_mq_getsetattr_args *p = params;
+		iarg[0] = SCARG(p, mqdes); /* linux_mqd_t */
+		uarg[1] = (intptr_t) SCARG(p, newattr); /* const struct linux_mq_attr * */
+		uarg[2] = (intptr_t) SCARG(p, oldattr); /* struct linux_mq_attr * */
+		*n_args = 3;
+		break;
+	}
 	/* linux_sys_waitid */
 	case 284: {
 		const struct linux_sys_waitid_args *p = params;
@@ -5125,6 +5181,108 @@ systrace_entry_setargdesc(int sysnum, in
 			break;
 		};
 		break;
+	/* linux_sys_mq_open */
+	case 277:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		case 1:
+			p = "int";
+			break;
+		case 2:
+			p = "linux_umode_t";
+			break;
+		case 3:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_unlink */
+	case 278:
+		switch(ndx) {
+		case 0:
+			p = "const char *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedsend */
+	case 279:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 280:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "char *";
+			break;
+		case 2:
+			p = "size_t";
+			break;
+		case 3:
+			p = "unsigned int *";
+			break;
+		case 4:
+			p = "const struct linux_timespec *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_notify */
+	case 281:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_sigevent *";
+			break;
+		default:
+			break;
+		};
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 282:
+		switch(ndx) {
+		case 0:
+			p = "linux_mqd_t";
+			break;
+		case 1:
+			p = "const struct linux_mq_attr *";
+			break;
+		case 2:
+			p = "struct linux_mq_attr *";
+			break;
+		default:
+			break;
+		};
+		break;
 	/* linux_sys_waitid */
 	case 284:
 		switch(ndx) {
@@ -6912,6 +7070,36 @@ systrace_return_setargdesc(int sysnum, i
 		if (ndx == 0 || ndx == 1)
 			p = "int";
 		break;
+	/* linux_sys_mq_open */
+	case 277:
+		if (ndx == 0 || ndx == 1)
+			p = "linux_mqd_t";
+		break;
+	/* linux_sys_mq_unlink */
+	case 278:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedsend */
+	case 279:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_timedreceive */
+	case 280:
+		if (ndx == 0 || ndx == 1)
+			p = "ssize_t";
+		break;
+	/* linux_sys_mq_notify */
+	case 281:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
+	/* linux_sys_mq_getsetattr */
+	case 282:
+		if (ndx == 0 || ndx == 1)
+			p = "int";
+		break;
 	/* linux_sys_waitid */
 	case 284:
 		if (ndx == 0 || ndx == 1)

Index: src/sys/compat/linux/arch/m68k/linux_syscall.h
diff -u src/sys/compat/linux/arch/m68k/linux_syscall.h:1.118 src/sys/compat/linux/arch/m68k/linux_syscall.h:1.119
--- src/sys/compat/linux/arch/m68k/linux_syscall.h:1.118	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/m68k/linux_syscall.h	Sun Jun 30 21:36:19 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.118 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.119 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.105 2024/06/29 13:46:10 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.106 2024/07/01 01:35:53 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -684,6 +684,24 @@
 /* syscall: "fadvise64_64" ret: "int" args: "int" "off_t" "off_t" "int" */
 #define	LINUX_SYS_fadvise64_64	267
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	271
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	272
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	273
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	274
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	275
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	276
+
 /* syscall: "inotify_init" ret: "int" args: */
 #define	LINUX_SYS_inotify_init	284
 
Index: src/sys/compat/linux/arch/m68k/linux_syscalls.c
diff -u src/sys/compat/linux/arch/m68k/linux_syscalls.c:1.118 src/sys/compat/linux/arch/m68k/linux_syscalls.c:1.119
--- src/sys/compat/linux/arch/m68k/linux_syscalls.c:1.118	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/m68k/linux_syscalls.c	Sun Jun 30 21:36:19 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.118 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.119 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.105 2024/06/29 13:46:10 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.106 2024/07/01 01:35:53 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.118 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.119 2024/07/01 01:36:19 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #if defined(_KERNEL_OPT)
@@ -27,6 +27,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 #else /* _KERNEL_OPT */
@@ -326,12 +327,12 @@ const char *const linux_syscallnames[] =
 	/* 268 */	"#268 (unimplemented mbind)",
 	/* 269 */	"#269 (unimplemented get_mempolicy)",
 	/* 270 */	"#270 (unimplemented set_mempolicy)",
-	/* 271 */	"#271 (unimplemented mq_open)",
-	/* 272 */	"#272 (unimplemented mq_unlink)",
-	/* 273 */	"#273 (unimplemented mq_timedsend)",
-	/* 274 */	"#274 (unimplemented mq_timedreceive)",
-	/* 275 */	"#275 (unimplemented mq_notify)",
-	/* 276 */	"#276 (unimplemented mq_getsetattr)",
+	/* 271 */	"mq_open",
+	/* 272 */	"mq_unlink",
+	/* 273 */	"mq_timedsend",
+	/* 274 */	"mq_timedreceive",
+	/* 275 */	"mq_notify",
+	/* 276 */	"mq_getsetattr",
 	/* 277 */	"#277 (unimplemented waitid)",
 	/* 278 */	"#278 (unimplemented vserver)",
 	/* 279 */	"#279 (unimplemented add_key)",
@@ -864,12 +865,12 @@ const char *const altlinux_syscallnames[
 	/* 268 */	NULL, /* unimplemented mbind */
 	/* 269 */	NULL, /* unimplemented get_mempolicy */
 	/* 270 */	NULL, /* unimplemented set_mempolicy */
-	/* 271 */	NULL, /* unimplemented mq_open */
-	/* 272 */	NULL, /* unimplemented mq_unlink */
-	/* 273 */	NULL, /* unimplemented mq_timedsend */
-	/* 274 */	NULL, /* unimplemented mq_timedreceive */
-	/* 275 */	NULL, /* unimplemented mq_notify */
-	/* 276 */	NULL, /* unimplemented mq_getsetattr */
+	/* 271 */	NULL, /* mq_open */
+	/* 272 */	NULL, /* mq_unlink */
+	/* 273 */	NULL, /* mq_timedsend */
+	/* 274 */	NULL, /* mq_timedreceive */
+	/* 275 */	NULL, /* mq_notify */
+	/* 276 */	NULL, /* mq_getsetattr */
 	/* 277 */	NULL, /* unimplemented waitid */
 	/* 278 */	NULL, /* unimplemented vserver */
 	/* 279 */	NULL, /* unimplemented add_key */
Index: src/sys/compat/linux/arch/m68k/linux_sysent.c
diff -u src/sys/compat/linux/arch/m68k/linux_sysent.c:1.118 src/sys/compat/linux/arch/m68k/linux_sysent.c:1.119
--- src/sys/compat/linux/arch/m68k/linux_sysent.c:1.118	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/m68k/linux_sysent.c	Sun Jun 30 21:36:19 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.118 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.119 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.105 2024/06/29 13:46:10 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.106 2024/07/01 01:35:53 christos Exp
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.118 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.119 2024/07/01 01:36:19 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -26,6 +26,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 
@@ -1210,23 +1211,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 270 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 271 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 271 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 272 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 272 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 273 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 273 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 274 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 274 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 275 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 275 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 276 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 276 = mq_getsetattr */
 	{
 		.sy_call = linux_sys_nosys,
 	},		/* 277 = filler */

Index: src/sys/compat/linux/arch/m68k/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/m68k/linux_syscallargs.h:1.117 src/sys/compat/linux/arch/m68k/linux_syscallargs.h:1.118
--- src/sys/compat/linux/arch/m68k/linux_syscallargs.h:1.117	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/m68k/linux_syscallargs.h	Sun Jun 30 21:36:19 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.117 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.118 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.105 2024/06/29 13:46:10 christos Exp
+ * created from	NetBSD: syscalls.master,v 1.106 2024/07/01 01:35:53 christos Exp
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -1018,6 +1018,50 @@ struct linux_sys_fadvise64_64_args {
 };
 check_syscall_args(linux_sys_fadvise64_64)
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_inotify_add_watch_args {
 	syscallarg(int) fd;
 	syscallarg(const char *) pathname;
@@ -1744,6 +1788,18 @@ int	compat_50_sys_utimes(struct lwp *, c
 
 int	linux_sys_fadvise64_64(struct lwp *, const struct linux_sys_fadvise64_64_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_inotify_init(struct lwp *, const void *, register_t *);
 
 int	linux_sys_inotify_add_watch(struct lwp *, const struct linux_sys_inotify_add_watch_args *, register_t *);

Index: src/sys/compat/linux/arch/mips/linux_syscall.h
diff -u src/sys/compat/linux/arch/mips/linux_syscall.h:1.91 src/sys/compat/linux/arch/mips/linux_syscall.h:1.92
--- src/sys/compat/linux/arch/mips/linux_syscall.h:1.91	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/mips/linux_syscall.h	Sun Jun 30 21:36:19 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.91 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.92 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:53 christos Exp  
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -655,6 +655,24 @@
 /* syscall: "utimes" ret: "int" args: "const char *" "const struct timeval50 *" */
 #define	LINUX_SYS_utimes	267
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	271
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	272
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	273
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	274
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	275
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	276
+
 /* syscall: "waitid" ret: "int" args: "int" "id_t" "linux_siginfo_t *" "int" "struct rusage50 *" */
 #define	LINUX_SYS_waitid	278
 

Index: src/sys/compat/linux/arch/mips/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/mips/linux_syscallargs.h:1.90 src/sys/compat/linux/arch/mips/linux_syscallargs.h:1.91
--- src/sys/compat/linux/arch/mips/linux_syscallargs.h:1.90	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/mips/linux_syscallargs.h	Sun Jun 30 21:36:19 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.90 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.91 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:53 christos Exp  
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -1065,6 +1065,50 @@ check_syscall_args(linux_sys_tgkill)
 
 struct compat_50_sys_utimes_args;
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_waitid_args {
 	syscallarg(int) idtype;
 	syscallarg(id_t) id;
@@ -1785,6 +1829,18 @@ int	linux_sys_tgkill(struct lwp *, const
 
 int	compat_50_sys_utimes(struct lwp *, const struct compat_50_sys_utimes_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_waitid(struct lwp *, const struct linux_sys_waitid_args *, register_t *);
 
 int	linux_sys_set_thread_area(struct lwp *, const struct linux_sys_set_thread_area_args *, register_t *);
Index: src/sys/compat/linux/arch/mips/linux_syscalls.c
diff -u src/sys/compat/linux/arch/mips/linux_syscalls.c:1.90 src/sys/compat/linux/arch/mips/linux_syscalls.c:1.91
--- src/sys/compat/linux/arch/mips/linux_syscalls.c:1.90	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/mips/linux_syscalls.c	Sun Jun 30 21:36:19 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.90 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.91 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:53 christos Exp  
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.90 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.91 2024/07/01 01:36:19 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include <sys/param.h>
@@ -22,6 +22,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_socketcall.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
@@ -302,12 +303,12 @@ const char *const linux_syscallnames[] =
 	/* 268 */	"#268 (unimplemented mbind)",
 	/* 269 */	"#269 (unimplemented get_mempolicy)",
 	/* 270 */	"#270 (unimplemented set_mempolicy)",
-	/* 271 */	"#271 (unimplemented mq_open)",
-	/* 272 */	"#272 (unimplemented mq_unlink)",
-	/* 273 */	"#273 (unimplemented mq_timedsend)",
-	/* 274 */	"#274 (unimplemented mq_timedreceive)",
-	/* 275 */	"#275 (unimplemented mq_notify)",
-	/* 276 */	"#276 (unimplemented mq_getsetattr)",
+	/* 271 */	"mq_open",
+	/* 272 */	"mq_unlink",
+	/* 273 */	"mq_timedsend",
+	/* 274 */	"mq_timedreceive",
+	/* 275 */	"mq_notify",
+	/* 276 */	"mq_getsetattr",
 	/* 277 */	"#277 (unimplemented vserve)",
 	/* 278 */	"waitid",
 	/* 279 */	"#279 (unimplemented setaltroot)",
@@ -819,12 +820,12 @@ const char *const altlinux_syscallnames[
 	/* 268 */	NULL, /* unimplemented mbind */
 	/* 269 */	NULL, /* unimplemented get_mempolicy */
 	/* 270 */	NULL, /* unimplemented set_mempolicy */
-	/* 271 */	NULL, /* unimplemented mq_open */
-	/* 272 */	NULL, /* unimplemented mq_unlink */
-	/* 273 */	NULL, /* unimplemented mq_timedsend */
-	/* 274 */	NULL, /* unimplemented mq_timedreceive */
-	/* 275 */	NULL, /* unimplemented mq_notify */
-	/* 276 */	NULL, /* unimplemented mq_getsetattr */
+	/* 271 */	NULL, /* mq_open */
+	/* 272 */	NULL, /* mq_unlink */
+	/* 273 */	NULL, /* mq_timedsend */
+	/* 274 */	NULL, /* mq_timedreceive */
+	/* 275 */	NULL, /* mq_notify */
+	/* 276 */	NULL, /* mq_getsetattr */
 	/* 277 */	NULL, /* unimplemented vserve */
 	/* 278 */	NULL, /* waitid */
 	/* 279 */	NULL, /* unimplemented setaltroot */
Index: src/sys/compat/linux/arch/mips/linux_sysent.c
diff -u src/sys/compat/linux/arch/mips/linux_sysent.c:1.90 src/sys/compat/linux/arch/mips/linux_sysent.c:1.91
--- src/sys/compat/linux/arch/mips/linux_sysent.c:1.90	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/mips/linux_sysent.c	Sun Jun 30 21:36:19 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.90 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.91 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.80 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.81 2024/07/01 01:35:53 christos Exp  
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.90 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.91 2024/07/01 01:36:19 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/poll.h>
@@ -21,6 +21,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_socketcall.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
@@ -1190,23 +1191,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 270 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 271 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 271 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 272 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 272 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 273 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 273 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 274 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 274 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 275 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 275 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 276 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 276 = mq_getsetattr */
 	{
 		.sy_call = linux_sys_nosys,
 	},		/* 277 = filler */

Index: src/sys/compat/linux/arch/powerpc/linux_syscall.h
diff -u src/sys/compat/linux/arch/powerpc/linux_syscall.h:1.97 src/sys/compat/linux/arch/powerpc/linux_syscall.h:1.98
--- src/sys/compat/linux/arch/powerpc/linux_syscall.h:1.97	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/powerpc/linux_syscall.h	Sun Jun 30 21:36:19 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscall.h,v 1.97 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscall.h,v 1.98 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call numbers.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.85 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.86 2024/07/01 01:35:53 christos Exp  
  */
 
 #ifndef _LINUX_SYS_SYSCALL_H_
@@ -627,6 +627,24 @@
 /* syscall: "fadvise64_64" ret: "int" args: "int" "off_t" "off_t" "int" */
 #define	LINUX_SYS_fadvise64_64	254
 
+/* syscall: "mq_open" ret: "linux_mqd_t" args: "const char *" "int" "linux_umode_t" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_open	262
+
+/* syscall: "mq_unlink" ret: "int" args: "const char *" */
+#define	LINUX_SYS_mq_unlink	263
+
+/* syscall: "mq_timedsend" ret: "int" args: "linux_mqd_t" "const char *" "size_t" "unsigned int" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedsend	264
+
+/* syscall: "mq_timedreceive" ret: "ssize_t" args: "linux_mqd_t" "char *" "size_t" "unsigned int *" "const struct linux_timespec *" */
+#define	LINUX_SYS_mq_timedreceive	265
+
+/* syscall: "mq_notify" ret: "int" args: "linux_mqd_t" "const struct linux_sigevent *" */
+#define	LINUX_SYS_mq_notify	266
+
+/* syscall: "mq_getsetattr" ret: "int" args: "linux_mqd_t" "const struct linux_mq_attr *" "struct linux_mq_attr *" */
+#define	LINUX_SYS_mq_getsetattr	267
+
 /* syscall: "waitid" ret: "int" args: "int" "id_t" "linux_siginfo_t *" "int" "struct rusage50 *" */
 #define	LINUX_SYS_waitid	272
 
Index: src/sys/compat/linux/arch/powerpc/linux_sysent.c
diff -u src/sys/compat/linux/arch/powerpc/linux_sysent.c:1.97 src/sys/compat/linux/arch/powerpc/linux_sysent.c:1.98
--- src/sys/compat/linux/arch/powerpc/linux_sysent.c:1.97	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/powerpc/linux_sysent.c	Sun Jun 30 21:36:19 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_sysent.c,v 1.97 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_sysent.c,v 1.98 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call switch table.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.85 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.86 2024/07/01 01:35:53 christos Exp  
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.97 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_sysent.c,v 1.98 2024/07/01 01:36:19 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/poll.h>
@@ -21,6 +21,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_sysent
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 
@@ -1144,23 +1145,35 @@ struct sysent linux_sysent[] = {
 		.sy_call = linux_sys_nosys,
 	},		/* 261 = filler */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 262 = filler */
+		ns(struct linux_sys_mq_open_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_open
+	},		/* 262 = mq_open */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 263 = filler */
+		ns(struct linux_sys_mq_unlink_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_unlink
+	},		/* 263 = mq_unlink */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 264 = filler */
+		ns(struct linux_sys_mq_timedsend_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedsend
+	},		/* 264 = mq_timedsend */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 265 = filler */
+		ns(struct linux_sys_mq_timedreceive_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_timedreceive
+	},		/* 265 = mq_timedreceive */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 266 = filler */
+		ns(struct linux_sys_mq_notify_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_notify
+	},		/* 266 = mq_notify */
 	{
-		.sy_call = linux_sys_nosys,
-	},		/* 267 = filler */
+		ns(struct linux_sys_mq_getsetattr_args),
+		.sy_flags = SYCALL_ARG_PTR,
+		.sy_call = (sy_call_t *)linux_sys_mq_getsetattr
+	},		/* 267 = mq_getsetattr */
 	{
 		.sy_call = linux_sys_nosys,
 	},		/* 268 = filler */

Index: src/sys/compat/linux/arch/powerpc/linux_syscallargs.h
diff -u src/sys/compat/linux/arch/powerpc/linux_syscallargs.h:1.96 src/sys/compat/linux/arch/powerpc/linux_syscallargs.h:1.97
--- src/sys/compat/linux/arch/powerpc/linux_syscallargs.h:1.96	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/powerpc/linux_syscallargs.h	Sun Jun 30 21:36:19 2024
@@ -1,10 +1,10 @@
-/* $NetBSD: linux_syscallargs.h,v 1.96 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscallargs.h,v 1.97 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call argument lists.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.85 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.86 2024/07/01 01:35:53 christos Exp  
  */
 
 #ifndef _LINUX_SYS_SYSCALLARGS_H_
@@ -957,6 +957,50 @@ struct linux_sys_fadvise64_64_args {
 };
 check_syscall_args(linux_sys_fadvise64_64)
 
+struct linux_sys_mq_open_args {
+	syscallarg(const char *) name;
+	syscallarg(int) oflag;
+	syscallarg(linux_umode_t) mode;
+	syscallarg(struct linux_mq_attr *) attr;
+};
+check_syscall_args(linux_sys_mq_open)
+
+struct linux_sys_mq_unlink_args {
+	syscallarg(const char *) name;
+};
+check_syscall_args(linux_sys_mq_unlink)
+
+struct linux_sys_mq_timedsend_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedsend)
+
+struct linux_sys_mq_timedreceive_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(char *) msg_ptr;
+	syscallarg(size_t) msg_len;
+	syscallarg(unsigned int *) msg_prio;
+	syscallarg(const struct linux_timespec *) abs_timeout;
+};
+check_syscall_args(linux_sys_mq_timedreceive)
+
+struct linux_sys_mq_notify_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_sigevent *) sevp;
+};
+check_syscall_args(linux_sys_mq_notify)
+
+struct linux_sys_mq_getsetattr_args {
+	syscallarg(linux_mqd_t) mqdes;
+	syscallarg(const struct linux_mq_attr *) newattr;
+	syscallarg(struct linux_mq_attr *) oldattr;
+};
+check_syscall_args(linux_sys_mq_getsetattr)
+
 struct linux_sys_waitid_args {
 	syscallarg(int) idtype;
 	syscallarg(id_t) id;
@@ -1652,6 +1696,18 @@ int	linux_sys_fstatfs64(struct lwp *, co
 
 int	linux_sys_fadvise64_64(struct lwp *, const struct linux_sys_fadvise64_64_args *, register_t *);
 
+int	linux_sys_mq_open(struct lwp *, const struct linux_sys_mq_open_args *, register_t *);
+
+int	linux_sys_mq_unlink(struct lwp *, const struct linux_sys_mq_unlink_args *, register_t *);
+
+int	linux_sys_mq_timedsend(struct lwp *, const struct linux_sys_mq_timedsend_args *, register_t *);
+
+int	linux_sys_mq_timedreceive(struct lwp *, const struct linux_sys_mq_timedreceive_args *, register_t *);
+
+int	linux_sys_mq_notify(struct lwp *, const struct linux_sys_mq_notify_args *, register_t *);
+
+int	linux_sys_mq_getsetattr(struct lwp *, const struct linux_sys_mq_getsetattr_args *, register_t *);
+
 int	linux_sys_waitid(struct lwp *, const struct linux_sys_waitid_args *, register_t *);
 
 int	linux_sys_inotify_init(struct lwp *, const void *, register_t *);
Index: src/sys/compat/linux/arch/powerpc/linux_syscalls.c
diff -u src/sys/compat/linux/arch/powerpc/linux_syscalls.c:1.96 src/sys/compat/linux/arch/powerpc/linux_syscalls.c:1.97
--- src/sys/compat/linux/arch/powerpc/linux_syscalls.c:1.96	Sat Jun 29 09:46:32 2024
+++ src/sys/compat/linux/arch/powerpc/linux_syscalls.c	Sun Jun 30 21:36:19 2024
@@ -1,14 +1,14 @@
-/* $NetBSD: linux_syscalls.c,v 1.96 2024/06/29 13:46:32 christos Exp $ */
+/* $NetBSD: linux_syscalls.c,v 1.97 2024/07/01 01:36:19 christos Exp $ */
 
 /*
  * System call names.
  *
  * DO NOT EDIT-- this file is automatically generated.
- * created from	NetBSD: syscalls.master,v 1.85 2024/06/29 13:46:10 christos Exp  
+ * created from	NetBSD: syscalls.master,v 1.86 2024/07/01 01:35:53 christos Exp  
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.96 2024/06/29 13:46:32 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_syscalls.c,v 1.97 2024/07/01 01:36:19 christos Exp $");
 
 #if defined(_KERNEL_OPT)
 #include <sys/param.h>
@@ -22,6 +22,7 @@ __KERNEL_RCSID(0, "$NetBSD: linux_syscal
 #include <compat/linux/common/linux_siginfo.h>
 #include <compat/linux/common/linux_machdep.h>
 #include <compat/linux/common/linux_mmap.h>
+#include <compat/linux/common/linux_mqueue.h>
 #include <compat/linux/common/linux_sched.h>
 #include <compat/linux/linux_syscallargs.h>
 #else /* _KERNEL_OPT */
@@ -296,12 +297,12 @@ const char *const linux_syscallnames[] =
 	/* 259 */	"#259 (unimplemented / * reserved for new sys_mbind * /)",
 	/* 260 */	"#260 (unimplemented / * reserved for new sys_get_mempolicy * /)",
 	/* 261 */	"#261 (unimplemented / * reserved for new sys_set_mempolicy * /)",
-	/* 262 */	"#262 (unimplemented mq_open)",
-	/* 263 */	"#263 (unimplemented mq_unlink)",
-	/* 264 */	"#264 (unimplemented mq_timedsend)",
-	/* 265 */	"#265 (unimplemented mq_timedreceive)",
-	/* 266 */	"#266 (unimplemented mq_notify)",
-	/* 267 */	"#267 (unimplemented mq_getsetattr)",
+	/* 262 */	"mq_open",
+	/* 263 */	"mq_unlink",
+	/* 264 */	"mq_timedsend",
+	/* 265 */	"mq_timedreceive",
+	/* 266 */	"mq_notify",
+	/* 267 */	"mq_getsetattr",
 	/* 268 */	"#268 (unimplemented kexec_load)",
 	/* 269 */	"#269 (unimplemented add_key)",
 	/* 270 */	"#270 (unimplemented request_key)",
@@ -818,12 +819,12 @@ const char *const altlinux_syscallnames[
 	/* 259 */	NULL, /* unimplemented / * reserved for new sys_mbind * / */
 	/* 260 */	NULL, /* unimplemented / * reserved for new sys_get_mempolicy * / */
 	/* 261 */	NULL, /* unimplemented / * reserved for new sys_set_mempolicy * / */
-	/* 262 */	NULL, /* unimplemented mq_open */
-	/* 263 */	NULL, /* unimplemented mq_unlink */
-	/* 264 */	NULL, /* unimplemented mq_timedsend */
-	/* 265 */	NULL, /* unimplemented mq_timedreceive */
-	/* 266 */	NULL, /* unimplemented mq_notify */
-	/* 267 */	NULL, /* unimplemented mq_getsetattr */
+	/* 262 */	NULL, /* mq_open */
+	/* 263 */	NULL, /* mq_unlink */
+	/* 264 */	NULL, /* mq_timedsend */
+	/* 265 */	NULL, /* mq_timedreceive */
+	/* 266 */	NULL, /* mq_notify */
+	/* 267 */	NULL, /* mq_getsetattr */
 	/* 268 */	NULL, /* unimplemented kexec_load */
 	/* 269 */	NULL, /* unimplemented add_key */
 	/* 270 */	NULL, /* unimplemented request_key */

Reply via email to