Package init
This commit is contained in:
commit
7b516a1789
165
Add-support-for-dev-u-random-ioctls.patch
Normal file
165
Add-support-for-dev-u-random-ioctls.patch
Normal file
@ -0,0 +1,165 @@
|
||||
From 2649c8c8b6832f267fb20cbcfdead19d32b8f2fc Mon Sep 17 00:00:00 2001
|
||||
From: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
|
||||
Date: Mon, 5 Nov 2018 17:29:00 +0000
|
||||
Subject: [PATCH 102/293] Add support for /dev/[u]random ioctls
|
||||
|
||||
* random_ioctl.c: New file.
|
||||
* Makefile.am (strace_SOURCES): Add it.
|
||||
* defs.h (DECL_IOCTL): Add random.
|
||||
* ioctl.c (ioctl_decode): Add 'R' case.
|
||||
* xlat/random_ioctl_cmds.in: New file.
|
||||
* tests/ioctl_random.c: New file.
|
||||
* tests/pure_executables.list: Likewise.
|
||||
* tests/gen_tests.in (ioctl_random): New entry.
|
||||
|
||||
Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
|
||||
---
|
||||
Makefile.am | 1 +
|
||||
defs.h | 1 +
|
||||
ioctl.c | 2 ++
|
||||
random_ioctl.c | 81 +++++++++++++++++++++++++++++++++++++++++++++
|
||||
xlat/random_ioctl_cmds.in | 7 ++++
|
||||
5 files changed, 92 insertions(+)
|
||||
create mode 100644 random_ioctl.c
|
||||
create mode 100644 xlat/random_ioctl_cmds.in
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index db16b3a..350bc51 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -267,6 +267,7 @@ strace_SOURCES = \
|
||||
ptp.c \
|
||||
ptrace.h \
|
||||
quota.c \
|
||||
+ random_ioctl.c \
|
||||
readahead.c \
|
||||
readlink.c \
|
||||
reboot.c \
|
||||
diff --git a/defs.h b/defs.h
|
||||
index 5ba95f5..b8d561a 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -973,6 +973,7 @@ DECL_IOCTL(kvm);
|
||||
DECL_IOCTL(nbd);
|
||||
DECL_IOCTL(nsfs);
|
||||
DECL_IOCTL(ptp);
|
||||
+DECL_IOCTL(random);
|
||||
DECL_IOCTL(scsi);
|
||||
DECL_IOCTL(term);
|
||||
DECL_IOCTL(ubi);
|
||||
diff --git a/ioctl.c b/ioctl.c
|
||||
index 4c9e7db..e7dd4c4 100644
|
||||
--- a/ioctl.c
|
||||
+++ b/ioctl.c
|
||||
@@ -329,6 +329,8 @@ ioctl_decode(struct tcb *tcp)
|
||||
return inotify_ioctl(tcp, code, arg);
|
||||
case 0xab:
|
||||
return nbd_ioctl(tcp, code, arg);
|
||||
+ case 'R':
|
||||
+ return random_ioctl(tcp, code, arg);
|
||||
default:
|
||||
break;
|
||||
}
|
||||
diff --git a/random_ioctl.c b/random_ioctl.c
|
||||
new file mode 100644
|
||||
index 0000000..6eaf6da
|
||||
--- /dev/null
|
||||
+++ b/random_ioctl.c
|
||||
@@ -0,0 +1,81 @@
|
||||
+/*
|
||||
+ * Copyright (c) 2018 The strace developers.
|
||||
+ * All rights reserved.
|
||||
+ *
|
||||
+ * Redistribution and use in source and binary forms, with or without
|
||||
+ * modification, are permitted provided that the following conditions
|
||||
+ * are met:
|
||||
+ * 1. Redistributions of source code must retain the above copyright
|
||||
+ * notice, this list of conditions and the following disclaimer.
|
||||
+ * 2. Redistributions in binary form must reproduce the above copyright
|
||||
+ * notice, this list of conditions and the following disclaimer in the
|
||||
+ * documentation and/or other materials provided with the distribution.
|
||||
+ * 3. The name of the author may not be used to endorse or promote products
|
||||
+ * derived from this software without specific prior written permission.
|
||||
+ *
|
||||
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
||||
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
||||
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
+ */
|
||||
+
|
||||
+#include "defs.h"
|
||||
+#include "print_fields.h"
|
||||
+
|
||||
+#include <linux/types.h>
|
||||
+#include <linux/random.h>
|
||||
+
|
||||
+#define XLAT_MACROS_ONLY
|
||||
+# include "xlat/random_ioctl_cmds.h"
|
||||
+#undef XLAT_MACROS_ONLY
|
||||
+
|
||||
+/*
|
||||
+ * RNDGETPOOL was removed in 2.6.9, so non-ancient kernels always
|
||||
+ * return -EINVAL for that.
|
||||
+ */
|
||||
+
|
||||
+int
|
||||
+random_ioctl(struct tcb *const tcp, const unsigned int code,
|
||||
+ const kernel_ulong_t arg)
|
||||
+{
|
||||
+ struct rand_pool_info info;
|
||||
+ kernel_ulong_t buf;
|
||||
+
|
||||
+ switch (code) {
|
||||
+ case RNDGETENTCNT:
|
||||
+ if (entering(tcp))
|
||||
+ return 0;
|
||||
+ ATTRIBUTE_FALLTHROUGH;
|
||||
+ case RNDADDTOENTCNT:
|
||||
+ tprints(", ");
|
||||
+ printnum_int(tcp, arg, "%d");
|
||||
+ break;
|
||||
+
|
||||
+ case RNDADDENTROPY:
|
||||
+ tprints(", ");
|
||||
+ if (!umove_or_printaddr(tcp, arg, &info)) {
|
||||
+ PRINT_FIELD_D("{", info, entropy_count);
|
||||
+ PRINT_FIELD_D(", ", info, buf_size);
|
||||
+ tprints(", buf=");
|
||||
+ buf = arg + offsetof(struct rand_pool_info, buf);
|
||||
+ printstrn(tcp, buf, info.buf_size);
|
||||
+ tprints("}");
|
||||
+ }
|
||||
+ break;
|
||||
+
|
||||
+ /* ioctls with no parameters */
|
||||
+ case RNDZAPENTCNT:
|
||||
+ case RNDCLEARPOOL:
|
||||
+ case RNDRESEEDCRNG:
|
||||
+ break;
|
||||
+ default:
|
||||
+ return RVAL_DECODED;
|
||||
+ }
|
||||
+ return RVAL_IOCTL_DECODED;
|
||||
+}
|
||||
diff --git a/xlat/random_ioctl_cmds.in b/xlat/random_ioctl_cmds.in
|
||||
new file mode 100644
|
||||
index 0000000..1b31dc5
|
||||
--- /dev/null
|
||||
+++ b/xlat/random_ioctl_cmds.in
|
||||
@@ -0,0 +1,7 @@
|
||||
+RNDGETENTCNT _IOR( 'R', 0x00, int )
|
||||
+RNDADDTOENTCNT _IOW( 'R', 0x01, int )
|
||||
+RNDGETPOOL _IOR( 'R', 0x02, int [2] )
|
||||
+RNDADDENTROPY _IOW( 'R', 0x03, int [2] )
|
||||
+RNDZAPENTCNT _IO( 'R', 0x04 )
|
||||
+RNDCLEARPOOL _IO( 'R', 0x06 )
|
||||
+RNDRESEEDCRNG _IO( 'R', 0x07 )
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
200
Implement-decoding-of-NBD_-ioctl-commands.patch
Normal file
200
Implement-decoding-of-NBD_-ioctl-commands.patch
Normal file
@ -0,0 +1,200 @@
|
||||
From 7a7f6c6a7c24177e7e2960c06564798e322e9ca0 Mon Sep 17 00:00:00 2001
|
||||
From: Elvira Khabirova <lineprinter@altlinux.org>
|
||||
Date: Sat, 22 Sep 2018 15:09:50 +0200
|
||||
Subject: [PATCH 093/293] Implement decoding of NBD_* ioctl commands
|
||||
|
||||
* nbd_ioctl.c: New file.
|
||||
* Makefile.am (strace_SOURCES): Add it.
|
||||
* defs.h (DECL_IOCTL): Add nbd.
|
||||
* ioctl.c (ioctl_decode): Add 0xab (nbd) case.
|
||||
* xlat/nbd_ioctl_cmds.in: Likewise.
|
||||
* xlat/nbd_ioctl_flags.in: Likewise.
|
||||
* tests/ioctl_nbd.c: Likewise.
|
||||
* tests/.gitignore: Add ioctl_nbd.
|
||||
* tests/pure_executables.list: Likewise.
|
||||
* tests/gen_tests.in (ioctl_nbd): New entry.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
Makefile.am | 1 +
|
||||
defs.h | 1 +
|
||||
ioctl.c | 2 +
|
||||
nbd_ioctl.c | 73 +++++++++++++++++++++++++++++
|
||||
xlat/nbd_ioctl_cmds.in | 11 +++++
|
||||
xlat/nbd_ioctl_flags.in | 29 ++++++++++++
|
||||
6 files changed, 117 insertions(+)
|
||||
create mode 100644 nbd_ioctl.c
|
||||
create mode 100644 xlat/nbd_ioctl_cmds.in
|
||||
create mode 100644 xlat/nbd_ioctl_flags.in
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index 9e5eef2..913d26a 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -204,6 +204,7 @@ strace_SOURCES = \
|
||||
msghdr.h \
|
||||
mtd.c \
|
||||
native_defs.h \
|
||||
+ nbd_ioctl.c \
|
||||
negated_errno.h \
|
||||
net.c \
|
||||
netlink.c \
|
||||
diff --git a/defs.h b/defs.h
|
||||
index 7f1e64d..5ba95f5 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -970,6 +970,7 @@ DECL_IOCTL(file);
|
||||
DECL_IOCTL(fs_x);
|
||||
DECL_IOCTL(inotify);
|
||||
DECL_IOCTL(kvm);
|
||||
+DECL_IOCTL(nbd);
|
||||
DECL_IOCTL(nsfs);
|
||||
DECL_IOCTL(ptp);
|
||||
DECL_IOCTL(scsi);
|
||||
diff --git a/ioctl.c b/ioctl.c
|
||||
index 66b10ec..4c9e7db 100644
|
||||
--- a/ioctl.c
|
||||
+++ b/ioctl.c
|
||||
@@ -327,6 +327,8 @@ ioctl_decode(struct tcb *tcp)
|
||||
#endif
|
||||
case 'I':
|
||||
return inotify_ioctl(tcp, code, arg);
|
||||
+ case 0xab:
|
||||
+ return nbd_ioctl(tcp, code, arg);
|
||||
default:
|
||||
break;
|
||||
}
|
||||
diff --git a/nbd_ioctl.c b/nbd_ioctl.c
|
||||
new file mode 100644
|
||||
index 0000000..0ceec3e
|
||||
--- /dev/null
|
||||
+++ b/nbd_ioctl.c
|
||||
@@ -0,0 +1,73 @@
|
||||
+/*
|
||||
+ * Copyright (c) 2018 The strace developers.
|
||||
+ * All rights reserved.
|
||||
+ *
|
||||
+ * Redistribution and use in source and binary forms, with or without
|
||||
+ * modification, are permitted provided that the following conditions
|
||||
+ * are met:
|
||||
+ * 1. Redistributions of source code must retain the above copyright
|
||||
+ * notice, this list of conditions and the following disclaimer.
|
||||
+ * 2. Redistributions in binary form must reproduce the above copyright
|
||||
+ * notice, this list of conditions and the following disclaimer in the
|
||||
+ * documentation and/or other materials provided with the distribution.
|
||||
+ * 3. The name of the author may not be used to endorse or promote products
|
||||
+ * derived from this software without specific prior written permission.
|
||||
+ *
|
||||
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
||||
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
||||
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
+ */
|
||||
+
|
||||
+#include "defs.h"
|
||||
+#include "print_fields.h"
|
||||
+#include <linux/ioctl.h>
|
||||
+#include <linux/types.h>
|
||||
+#include <linux/nbd.h>
|
||||
+
|
||||
+#define XLAT_MACROS_ONLY
|
||||
+# include "xlat/nbd_ioctl_cmds.h"
|
||||
+#undef XLAT_MACROS_ONLY
|
||||
+
|
||||
+#include "xlat/nbd_ioctl_flags.h"
|
||||
+
|
||||
+int
|
||||
+nbd_ioctl(struct tcb *const tcp, const unsigned int code,
|
||||
+ const kernel_ulong_t arg)
|
||||
+{
|
||||
+ switch (code) {
|
||||
+ case NBD_DISCONNECT:
|
||||
+ case NBD_CLEAR_SOCK:
|
||||
+ case NBD_DO_IT:
|
||||
+ case NBD_CLEAR_QUE:
|
||||
+ case NBD_PRINT_DEBUG:
|
||||
+ return RVAL_IOCTL_DECODED;
|
||||
+
|
||||
+ case NBD_SET_SOCK:
|
||||
+ tprints(", ");
|
||||
+ printfd(tcp, arg);
|
||||
+ return RVAL_IOCTL_DECODED;
|
||||
+
|
||||
+ case NBD_SET_BLKSIZE:
|
||||
+ case NBD_SET_SIZE:
|
||||
+ case NBD_SET_SIZE_BLOCKS:
|
||||
+ case NBD_SET_TIMEOUT:
|
||||
+ tprints(", ");
|
||||
+ tprintf("%" PRI_klu, arg);
|
||||
+ return RVAL_IOCTL_DECODED;
|
||||
+
|
||||
+ case NBD_SET_FLAGS:
|
||||
+ tprints(", ");
|
||||
+ printflags(nbd_ioctl_flags, arg, "NBD_IOC_FLAG_???");
|
||||
+ return RVAL_IOCTL_DECODED;
|
||||
+
|
||||
+ default:
|
||||
+ return RVAL_DECODED;
|
||||
+ }
|
||||
+}
|
||||
diff --git a/xlat/nbd_ioctl_cmds.in b/xlat/nbd_ioctl_cmds.in
|
||||
new file mode 100644
|
||||
index 0000000..34f891e
|
||||
--- /dev/null
|
||||
+++ b/xlat/nbd_ioctl_cmds.in
|
||||
@@ -0,0 +1,11 @@
|
||||
+NBD_SET_SOCK _IO( 0xab, 0 )
|
||||
+NBD_SET_BLKSIZE _IO( 0xab, 1 )
|
||||
+NBD_SET_SIZE _IO( 0xab, 2 )
|
||||
+NBD_DO_IT _IO( 0xab, 3 )
|
||||
+NBD_CLEAR_SOCK _IO( 0xab, 4 )
|
||||
+NBD_CLEAR_QUE _IO( 0xab, 5 )
|
||||
+NBD_PRINT_DEBUG _IO( 0xab, 6 )
|
||||
+NBD_SET_SIZE_BLOCKS _IO( 0xab, 7 )
|
||||
+NBD_DISCONNECT _IO( 0xab, 8 )
|
||||
+NBD_SET_TIMEOUT _IO( 0xab, 9 )
|
||||
+NBD_SET_FLAGS _IO( 0xab, 10)
|
||||
diff --git a/xlat/nbd_ioctl_flags.in b/xlat/nbd_ioctl_flags.in
|
||||
new file mode 100644
|
||||
index 0000000..60bb07f
|
||||
--- /dev/null
|
||||
+++ b/xlat/nbd_ioctl_flags.in
|
||||
@@ -0,0 +1,29 @@
|
||||
+/*
|
||||
+ * Some flags are not defined in <linux/nbd.h>, but are passed anyway.
|
||||
+ * These flags are sent from nbd-server to the client, and the client
|
||||
+ * passes them to the kernel unmodified after parsing. Both the client
|
||||
+ * and the kernel ignore flags unknown to them.
|
||||
+ */
|
||||
+
|
||||
+/* The server supports flags */
|
||||
+NBD_FLAG_HAS_FLAGS (1 << 0)
|
||||
+/* The export is read-only */
|
||||
+NBD_FLAG_READ_ONLY (1 << 1)
|
||||
+/* The server supports NBD_CMD_FLUSH */
|
||||
+NBD_FLAG_SEND_FLUSH (1 << 2)
|
||||
+/* The server supports NBD_CMD_FLAG_FUA (Force Unit Access) */
|
||||
+NBD_FLAG_SEND_FUA (1 << 3)
|
||||
+/* The export is a rotational medium */
|
||||
+NBD_FLAG_ROTATIONAL (1 << 4)
|
||||
+/* The server supports NBD_CMD_TRIM */
|
||||
+NBD_FLAG_SEND_TRIM (1 << 5)
|
||||
+/* The server supports NBD_CMD_WRITE_ZEROES and NBD_CMD_FLAG_NO_HOLE */
|
||||
+NBD_FLAG_SEND_WRITE_ZEROES (1 << 6)
|
||||
+/* The server supports NBD_CMD_FLAG_DF (don't fragment replies) */
|
||||
+NBD_FLAG_SEND_DF (1 << 7)
|
||||
+/* The server supports multiple connections */
|
||||
+NBD_FLAG_CAN_MULTI_CONN (1 << 8)
|
||||
+/* The server supports NBD_CMD_RESIZE (resizing the device) */
|
||||
+NBD_FLAG_SEND_RESIZE (1 << 9)
|
||||
+/* The server supports NBD_CMD_CACHE */
|
||||
+NBD_FLAG_SEND_CACHE (1 << 10)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
33
Make-inline-message-on-failed-restart-attempt-more-v.patch
Normal file
33
Make-inline-message-on-failed-restart-attempt-more-v.patch
Normal file
@ -0,0 +1,33 @@
|
||||
From fe64f96ac09bfc97b6554816a19ae1fe138f1cae Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 10 Feb 2019 19:49:46 +0100
|
||||
Subject: [PATCH 224/293] Make inline message on failed restart attempt more
|
||||
verbose
|
||||
|
||||
Hopefully, now it is less confusing.
|
||||
|
||||
* strace.c (ptrace_restart): Provide intent and pid in the inline error
|
||||
message.
|
||||
|
||||
References: https://bugzilla.redhat.com/show_bug.cgi?id=1662936
|
||||
---
|
||||
strace.c | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/strace.c b/strace.c
|
||||
index 6413297..246eb0c 100644
|
||||
--- a/strace.c
|
||||
+++ b/strace.c
|
||||
@@ -382,7 +382,8 @@ ptrace_restart(const unsigned int op, struct tcb *const tcp, unsigned int sig)
|
||||
* but before we tried to restart it. Log looks ugly.
|
||||
*/
|
||||
if (current_tcp && current_tcp->curcol != 0) {
|
||||
- tprintf(" <ptrace(%s):%s>\n", msg, strerror(err));
|
||||
+ tprintf(" <Cannot restart pid %d with ptrace(%s): %s>\n",
|
||||
+ tcp->pid, msg, strerror(err));
|
||||
line_ended();
|
||||
}
|
||||
if (err == ESRCH)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
32
Print-stack-traces-on-signals.patch
Normal file
32
Print-stack-traces-on-signals.patch
Normal file
@ -0,0 +1,32 @@
|
||||
From 302cf02757abb99ab7744af38a5dc3015804a2e8 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Wed, 29 Aug 2018 18:09:57 +0200
|
||||
Subject: [PATCH 074/293] Print stack traces on signals
|
||||
|
||||
I don't know why it hasn't been done earlier.
|
||||
|
||||
* strace.c (print_stopped) [ENABLE_STACKTRACE]: Call unwind_tcb_print
|
||||
if stack trace printing is enabled.
|
||||
---
|
||||
strace.c | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/strace.c b/strace.c
|
||||
index 6d70d20..62142d8 100644
|
||||
--- a/strace.c
|
||||
+++ b/strace.c
|
||||
@@ -2168,6 +2168,11 @@ print_stopped(struct tcb *tcp, const siginfo_t *si, const unsigned int sig)
|
||||
} else
|
||||
tprintf("--- stopped by %s ---\n", signame(sig));
|
||||
line_ended();
|
||||
+
|
||||
+#ifdef ENABLE_STACKTRACE
|
||||
+ if (stack_trace_enabled)
|
||||
+ unwind_tcb_print(tcp);
|
||||
+#endif
|
||||
}
|
||||
}
|
||||
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
166
Remove-redundant-VIDIOC_SUBDEV_-constants.patch
Normal file
166
Remove-redundant-VIDIOC_SUBDEV_-constants.patch
Normal file
@ -0,0 +1,166 @@
|
||||
From 5993d50813620bea8a200c8fadf96d97d4f27156 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Wed, 24 Oct 2018 07:48:56 +0000
|
||||
Subject: [PATCH 088/293] Remove redundant VIDIOC_SUBDEV_* constants
|
||||
|
||||
Remove those of VIDIOC_SUBDEV_* constants are defined exactly the same
|
||||
way by the Linux kernel as their VIDIOC_* origins.
|
||||
|
||||
Linux kernel commit v4.19-rc1~137^2~248 introduced more of such
|
||||
duplicates, forward remove them as well.
|
||||
|
||||
* linux/32/ioctls_inc_align16.h: Remove VIDIOC_SUBDEV_DV_TIMINGS_CAP,
|
||||
VIDIOC_SUBDEV_ENUM_DV_TIMINGS, VIDIOC_SUBDEV_G_DV_TIMINGS,
|
||||
VIDIOC_SUBDEV_G_EDID, VIDIOC_SUBDEV_QUERY_DV_TIMINGS,
|
||||
VIDIOC_SUBDEV_S_DV_TIMINGS, and VIDIOC_SUBDEV_S_EDID.
|
||||
* linux/32/ioctls_inc_align32.h: Likewise.
|
||||
* linux/32/ioctls_inc_align64.h: Likewise.
|
||||
* linux/64/ioctls_inc.h: Likewise.
|
||||
* linux/x32/ioctls_inc0.h: Likewise.
|
||||
* maint/ioctls_sym.sh: Remove VIDIOC_SUBDEV_DV_TIMINGS_CAP,
|
||||
VIDIOC_SUBDEV_ENUM_DV_TIMINGS, VIDIOC_SUBDEV_ENUMSTD,
|
||||
VIDIOC_SUBDEV_G_DV_TIMINGS, VIDIOC_SUBDEV_G_EDID, VIDIOC_SUBDEV_G_STD,
|
||||
VIDIOC_SUBDEV_QUERY_DV_TIMINGS, VIDIOC_SUBDEV_QUERYSTD,
|
||||
VIDIOC_SUBDEV_S_DV_TIMINGS, VIDIOC_SUBDEV_S_EDID, and
|
||||
VIDIOC_SUBDEV_S_STD.
|
||||
---
|
||||
linux/32/ioctls_inc_align16.h | 7 -------
|
||||
linux/32/ioctls_inc_align32.h | 7 -------
|
||||
linux/32/ioctls_inc_align64.h | 7 -------
|
||||
linux/64/ioctls_inc.h | 7 -------
|
||||
linux/x32/ioctls_inc0.h | 7 -------
|
||||
6 files changed, 4 insertions(+), 35 deletions(-)
|
||||
|
||||
diff --git a/linux/32/ioctls_inc_align16.h b/linux/32/ioctls_inc_align16.h
|
||||
index 2bd5779..c8264e6 100644
|
||||
--- a/linux/32/ioctls_inc_align16.h
|
||||
+++ b/linux/32/ioctls_inc_align16.h
|
||||
@@ -2087,21 +2087,14 @@
|
||||
{ "linux/userfaultfd.h", "UFFDIO_ZEROPAGE", _IOC_READ|_IOC_WRITE, 0xaa04, 0x20 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_MAP", _IOC_READ|_IOC_WRITE, 0x7520, 0x58 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_QUERY", _IOC_READ|_IOC_WRITE, 0x7521, 0x0a },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x564b, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", _IOC_READ|_IOC_WRITE, 0x564a, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_MBUS_CODE", _IOC_READ|_IOC_WRITE, 0x5602, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5615, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x563d, 0x40 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_CROP", _IOC_READ|_IOC_WRITE, 0x563c, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5616, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x563e, 0x40 },
|
||||
diff --git a/linux/32/ioctls_inc_align32.h b/linux/32/ioctls_inc_align32.h
|
||||
index 80ed706..daa5645 100644
|
||||
--- a/linux/32/ioctls_inc_align32.h
|
||||
+++ b/linux/32/ioctls_inc_align32.h
|
||||
@@ -2087,21 +2087,14 @@
|
||||
{ "linux/userfaultfd.h", "UFFDIO_ZEROPAGE", _IOC_READ|_IOC_WRITE, 0xaa04, 0x20 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_MAP", _IOC_READ|_IOC_WRITE, 0x7520, 0x58 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_QUERY", _IOC_READ|_IOC_WRITE, 0x7521, 0x0c },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x564b, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", _IOC_READ|_IOC_WRITE, 0x564a, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_MBUS_CODE", _IOC_READ|_IOC_WRITE, 0x5602, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5615, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x563d, 0x40 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_CROP", _IOC_READ|_IOC_WRITE, 0x563c, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5616, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x563e, 0x40 },
|
||||
diff --git a/linux/32/ioctls_inc_align64.h b/linux/32/ioctls_inc_align64.h
|
||||
index 7e6205d..78a78ac 100644
|
||||
--- a/linux/32/ioctls_inc_align64.h
|
||||
+++ b/linux/32/ioctls_inc_align64.h
|
||||
@@ -2087,21 +2087,14 @@
|
||||
{ "linux/userfaultfd.h", "UFFDIO_ZEROPAGE", _IOC_READ|_IOC_WRITE, 0xaa04, 0x20 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_MAP", _IOC_READ|_IOC_WRITE, 0x7520, 0x58 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_QUERY", _IOC_READ|_IOC_WRITE, 0x7521, 0x0c },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x564b, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", _IOC_READ|_IOC_WRITE, 0x564a, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_MBUS_CODE", _IOC_READ|_IOC_WRITE, 0x5602, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5615, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x563d, 0x40 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_CROP", _IOC_READ|_IOC_WRITE, 0x563c, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5616, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x563e, 0x40 },
|
||||
diff --git a/linux/64/ioctls_inc.h b/linux/64/ioctls_inc.h
|
||||
index b3e5166..c9fca6b 100644
|
||||
--- a/linux/64/ioctls_inc.h
|
||||
+++ b/linux/64/ioctls_inc.h
|
||||
@@ -2087,21 +2087,14 @@
|
||||
{ "linux/userfaultfd.h", "UFFDIO_ZEROPAGE", _IOC_READ|_IOC_WRITE, 0xaa04, 0x20 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_MAP", _IOC_READ|_IOC_WRITE, 0x7520, 0x60 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_QUERY", _IOC_READ|_IOC_WRITE, 0x7521, 0x10 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x564b, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", _IOC_READ|_IOC_WRITE, 0x564a, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_MBUS_CODE", _IOC_READ|_IOC_WRITE, 0x5602, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x28 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5615, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x563d, 0x40 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_CROP", _IOC_READ|_IOC_WRITE, 0x563c, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x28 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5616, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x563e, 0x40 },
|
||||
diff --git a/linux/x32/ioctls_inc0.h b/linux/x32/ioctls_inc0.h
|
||||
index 7f23586..b20c29b 100644
|
||||
--- a/linux/x32/ioctls_inc0.h
|
||||
+++ b/linux/x32/ioctls_inc0.h
|
||||
@@ -2087,21 +2087,14 @@
|
||||
{ "linux/userfaultfd.h", "UFFDIO_ZEROPAGE", _IOC_READ|_IOC_WRITE, 0xaa04, 0x20 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_MAP", _IOC_READ|_IOC_WRITE, 0x7520, 0x58 },
|
||||
{ "linux/uvcvideo.h", "UVCIOC_CTRL_QUERY", _IOC_READ|_IOC_WRITE, 0x7521, 0x0c },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x564b, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", _IOC_READ|_IOC_WRITE, 0x564a, 0x40 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_ENUM_MBUS_CODE", _IOC_READ|_IOC_WRITE, 0x5602, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5615, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x563d, 0x40 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_CROP", _IOC_READ|_IOC_WRITE, 0x563c, 0x38 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
|
||||
-{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0x58 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_FRAME_INTERVAL", _IOC_READ|_IOC_WRITE, 0x5616, 0x30 },
|
||||
{ "linux/v4l2-subdev.h", "VIDIOC_SUBDEV_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x563e, 0x40 },
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
837
Update-ioctl-entries-from-linux-v4.19.patch
Normal file
837
Update-ioctl-entries-from-linux-v4.19.patch
Normal file
@ -0,0 +1,837 @@
|
||||
From 3960969554aad44c1269536b1c1baa4a69dc5da4 Mon Sep 17 00:00:00 2001
|
||||
From: Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org>
|
||||
Date: Sun, 21 Oct 2018 11:47:44 +0300
|
||||
Subject: [PATCH 090/293] Update ioctl entries from linux v4.19
|
||||
|
||||
* linux/32/ioctls_inc_align16.h: Update from linux v4.19-rc8
|
||||
using ioctls_gen.sh.
|
||||
* linux/32/ioctls_inc_align32.h: Likewise.
|
||||
* linux/32/ioctls_inc_align64.h: Likewise.
|
||||
* linux/64/ioctls_inc.h: Likewise.
|
||||
* linux/x32/ioctls_inc0.h: Likewise.
|
||||
* linux/i386/ioctls_arch0.h: Likewise.
|
||||
* linux/x86_64/ioctls_arch0.h: Likewise.
|
||||
* NEWS: Mention this.
|
||||
---
|
||||
linux/32/ioctls_inc_align16.h | 41 ++++++++++++++++++++++++++++-------------
|
||||
linux/32/ioctls_inc_align32.h | 41 ++++++++++++++++++++++++++++-------------
|
||||
linux/32/ioctls_inc_align64.h | 41 ++++++++++++++++++++++++++++-------------
|
||||
linux/64/ioctls_inc.h | 41 ++++++++++++++++++++++++++++-------------
|
||||
linux/i386/ioctls_arch0.h | 2 ++
|
||||
linux/x32/ioctls_inc0.h | 41 ++++++++++++++++++++++++++++-------------
|
||||
linux/x86_64/ioctls_arch0.h | 2 ++
|
||||
8 files changed, 147 insertions(+), 65 deletions(-)
|
||||
|
||||
diff --git a/linux/32/ioctls_inc_align16.h b/linux/32/ioctls_inc_align16.h
|
||||
index c8264e6..85f657d 100644
|
||||
--- a/linux/32/ioctls_inc_align16.h
|
||||
+++ b/linux/32/ioctls_inc_align16.h
|
||||
@@ -794,17 +794,13 @@
|
||||
{ "linux/dvb/audio.h", "AUDIO_CLEAR_BUFFER", _IOC_NONE, 0x6f0c, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_CONTINUE", _IOC_NONE, 0x6f04, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_CAPABILITIES", _IOC_READ, 0x6f0b, 0x04 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_GET_PTS", _IOC_READ, 0x6f13, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_STATUS", _IOC_READ, 0x6f0a, 0x20 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PAUSE", _IOC_NONE, 0x6f03, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PLAY", _IOC_NONE, 0x6f02, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SELECT_SOURCE", _IOC_NONE, 0x6f05, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_ATTRIBUTES", _IOC_WRITE, 0x6f11, 0x02 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_AV_SYNC", _IOC_NONE, 0x6f07, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_BYPASS_MODE", _IOC_NONE, 0x6f08, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_EXT_ID", _IOC_NONE, 0x6f10, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_ID", _IOC_NONE, 0x6f0d, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_KARAOKE", _IOC_WRITE, 0x6f12, 0x0c },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MIXER", _IOC_WRITE, 0x6f0e, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MUTE", _IOC_NONE, 0x6f06, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_STREAMTYPE", _IOC_NONE, 0x6f0f, 0x00 },
|
||||
@@ -863,23 +859,15 @@
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_CAPABILITIES", _IOC_READ, 0x6f21, 0x04 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_EVENT", _IOC_READ, 0x6f1c, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_FRAME_COUNT", _IOC_READ, 0x6f3a, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_FRAME_RATE", _IOC_READ, 0x6f38, 0x04 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_NAVI", _IOC_READ, 0x6f34, 0x404 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_PTS", _IOC_READ, 0x6f39, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_SIZE", _IOC_READ, 0x6f37, 0x0c },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_STATUS", _IOC_READ, 0x6f1b, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_PLAY", _IOC_NONE, 0x6f16, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SELECT_SOURCE", _IOC_NONE, 0x6f19, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ATTRIBUTES", _IOC_NONE, 0x6f35, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_BLANK", _IOC_NONE, 0x6f1a, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_DISPLAY_FORMAT", _IOC_NONE, 0x6f1d, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_FORMAT", _IOC_NONE, 0x6f25, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_HIGHLIGHT", _IOC_WRITE, 0x6f27, 0x10 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ID", _IOC_NONE, 0x6f23, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU", _IOC_WRITE, 0x6f32, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU_PALETTE", _IOC_WRITE, 0x6f33, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_STREAMTYPE", _IOC_NONE, 0x6f24, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SYSTEM", _IOC_NONE, 0x6f26, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SLOWMOTION", _IOC_NONE, 0x6f20, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STILLPICTURE", _IOC_WRITE, 0x6f1e, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STOP", _IOC_NONE, 0x6f15, 0x00 },
|
||||
@@ -952,6 +940,14 @@
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SET_ISO_CHANNELS", _IOC_WRITE, 0x2317, 0x0c },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_START_ISO", _IOC_WRITE, 0x230a, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_STOP_ISO", _IOC_WRITE, 0x230b, 0x04 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_CHECK_EXTENSION", _IOC_NONE, 0xb601, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_FME_PORT_PR", _IOC_NONE, 0xb680, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_GET_API_VERSION", _IOC_NONE, 0xb600, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_MAP", _IOC_NONE, 0xb643, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_UNMAP", _IOC_NONE, 0xb644, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_INFO", _IOC_NONE, 0xb641, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_REGION_INFO", _IOC_NONE, 0xb642, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_RESET", _IOC_NONE, 0xb640, 0x00 },
|
||||
{ "linux/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
|
||||
{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
|
||||
{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
|
||||
@@ -1004,6 +1000,10 @@
|
||||
{ "linux/fs.h", "FS_IOC_SETFSLABEL", _IOC_WRITE, 0x9432, 0x100 },
|
||||
{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
|
||||
{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_CHECK", _IOC_READ, 0x7300, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_READ", _IOC_READ|_IOC_WRITE, 0x7301, 0x1e },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_RESET", _IOC_WRITE, 0x7303, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_WRITE", _IOC_READ|_IOC_WRITE, 0x7302, 0x1e },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_ALPHA", _IOC_READ, 0x4d00, 0x01 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_AOID", _IOC_READ, 0x4d04, 0x08 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_GAMMA", _IOC_READ, 0x4d01, 0x01 },
|
||||
@@ -1335,6 +1335,7 @@
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_MAP_MEMORY_TO_GPU", _IOC_READ|_IOC_WRITE, 0x4b18, 0x18 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
|
||||
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_CU_MASK", _IOC_WRITE, 0x4b1a, 0x10 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_EVENT", _IOC_WRITE, 0x4b0a, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_MEMORY_POLICY", _IOC_WRITE, 0x4b04, 0x20 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_SCRATCH_BACKING_VA", _IOC_READ|_IOC_WRITE, 0x4b11, 0x10 },
|
||||
@@ -1512,9 +1513,12 @@
|
||||
{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_BAR", _IOC_NONE, 0x5001, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_COPY", _IOC_WRITE, 0x5006, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_GET_IRQTYPE", _IOC_NONE, 0x5009, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_LEGACY_IRQ", _IOC_NONE, 0x5002, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_MSI", _IOC_WRITE, 0x5003, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_MSIX", _IOC_WRITE, 0x5007, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_READ", _IOC_WRITE, 0x5005, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_SET_IRQTYPE", _IOC_WRITE, 0x5008, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_WRITE", _IOC_WRITE, 0x5004, 0x04 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
|
||||
@@ -2027,6 +2031,7 @@
|
||||
{ "linux/usb/functionfs.h", "FUNCTIONFS_INTERFACE_REVMAP", _IOC_NONE, 0x6780, 0x00 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_GET_PRINTER_STATUS", _IOC_READ, 0x6721, 0x01 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_SET_PRINTER_STATUS", _IOC_READ|_IOC_WRITE, 0x6722, 0x01 },
|
||||
+{ "linux/usb/g_uvc.h", "UVCIOC_SEND_RESPONSE", _IOC_WRITE, 0x5501, 0x40 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
|
||||
@@ -2038,12 +2043,17 @@
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_LOCAL_LOCKOUT", _IOC_NONE, 0x5b15, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_READ_STB", _IOC_READ, 0x5b12, 0x01 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_REN_CONTROL", _IOC_WRITE, 0x5b13, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_TRIGGER", _IOC_NONE, 0x5b16, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_IN", _IOC_NONE, 0x5b04, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_OUT", _IOC_NONE, 0x5b03, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR", _IOC_NONE, 0x5b02, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_IN_HALT", _IOC_NONE, 0x5b07, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_OUT_HALT", _IOC_NONE, 0x5b06, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_CONFIG_TERMCHAR", _IOC_WRITE, 0x5b0c, 0x02 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_EOM_ENABLE", _IOC_WRITE, 0x5b0b, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_GET_TIMEOUT", _IOC_READ, 0x5b09, 0x04 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_SET_TIMEOUT", _IOC_WRITE, 0x5b0a, 0x04 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_ALLOC_STREAMS", _IOC_READ, 0x551c, 0x08 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK32", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
@@ -2136,6 +2146,7 @@
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", _IOC_NONE, 0x3b76, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_UNMAP_DMA", _IOC_NONE, 0x3b72, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_SET_IOMMU", _IOC_NONE, 0x3b66, 0x00 },
|
||||
+{ "linux/vhost.h", "VHOST_GET_BACKEND_FEATURES", _IOC_READ, 0xaf26, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_FEATURES", _IOC_READ, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BASE", _IOC_READ|_IOC_WRITE, 0xaf12, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf24, 0x08 },
|
||||
@@ -2147,6 +2158,7 @@
|
||||
{ "linux/vhost.h", "VHOST_SCSI_GET_EVENTS_MISSED", _IOC_WRITE, 0xaf44, 0x04 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_ENDPOINT", _IOC_WRITE, 0xaf40, 0xe8 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_EVENTS_MISSED", _IOC_WRITE, 0xaf43, 0x04 },
|
||||
+{ "linux/vhost.h", "VHOST_SET_BACKEND_FEATURES", _IOC_WRITE, 0xaf25, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_FEATURES", _IOC_WRITE, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_BASE", _IOC_WRITE, 0xaf04, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_FD", _IOC_WRITE, 0xaf07, 0x04 },
|
||||
@@ -2216,7 +2228,6 @@
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_EXT_CTRL", _IOC_READ|_IOC_WRITE, 0x5667, 0xe8 },
|
||||
{ "linux/videodev2.h", "VIDIOC_REQBUFS", _IOC_READ|_IOC_WRITE, 0x5608, 0x14 },
|
||||
-{ "linux/videodev2.h", "VIDIOC_RESERVED", _IOC_NONE, 0x5601, 0x00 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMOFF", _IOC_WRITE, 0x5613, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMON", _IOC_WRITE, 0x5612, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_SUBSCRIBE_EVENT", _IOC_WRITE, 0x565a, 0x20 },
|
||||
@@ -2743,6 +2754,10 @@
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESTRICT_DOMID", _IOC_NONE, 0x4506, 0x02 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_FROM_REFS", _IOC_NONE, 0x4709, 0x14 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_WAIT_RELEASED", _IOC_NONE, 0x470a, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_RELEASE", _IOC_NONE, 0x470c, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_TO_REFS", _IOC_NONE, 0x470b, 0x14 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", _IOC_NONE, 0x4702, 0x18 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GRANT_COPY", _IOC_NONE, 0x4708, 0x08 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_MAP_GRANT_REF", _IOC_NONE, 0x4700, 0x18 },
|
||||
diff --git a/linux/32/ioctls_inc_align32.h b/linux/32/ioctls_inc_align32.h
|
||||
index daa5645..ce23a36 100644
|
||||
--- a/linux/32/ioctls_inc_align32.h
|
||||
+++ b/linux/32/ioctls_inc_align32.h
|
||||
@@ -794,17 +794,13 @@
|
||||
{ "linux/dvb/audio.h", "AUDIO_CLEAR_BUFFER", _IOC_NONE, 0x6f0c, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_CONTINUE", _IOC_NONE, 0x6f04, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_CAPABILITIES", _IOC_READ, 0x6f0b, 0x04 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_GET_PTS", _IOC_READ, 0x6f13, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_STATUS", _IOC_READ, 0x6f0a, 0x20 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PAUSE", _IOC_NONE, 0x6f03, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PLAY", _IOC_NONE, 0x6f02, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SELECT_SOURCE", _IOC_NONE, 0x6f05, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_ATTRIBUTES", _IOC_WRITE, 0x6f11, 0x02 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_AV_SYNC", _IOC_NONE, 0x6f07, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_BYPASS_MODE", _IOC_NONE, 0x6f08, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_EXT_ID", _IOC_NONE, 0x6f10, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_ID", _IOC_NONE, 0x6f0d, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_KARAOKE", _IOC_WRITE, 0x6f12, 0x0c },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MIXER", _IOC_WRITE, 0x6f0e, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MUTE", _IOC_NONE, 0x6f06, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_STREAMTYPE", _IOC_NONE, 0x6f0f, 0x00 },
|
||||
@@ -863,23 +859,15 @@
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_CAPABILITIES", _IOC_READ, 0x6f21, 0x04 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_EVENT", _IOC_READ, 0x6f1c, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_FRAME_COUNT", _IOC_READ, 0x6f3a, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_FRAME_RATE", _IOC_READ, 0x6f38, 0x04 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_NAVI", _IOC_READ, 0x6f34, 0x404 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_PTS", _IOC_READ, 0x6f39, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_SIZE", _IOC_READ, 0x6f37, 0x0c },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_STATUS", _IOC_READ, 0x6f1b, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_PLAY", _IOC_NONE, 0x6f16, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SELECT_SOURCE", _IOC_NONE, 0x6f19, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ATTRIBUTES", _IOC_NONE, 0x6f35, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_BLANK", _IOC_NONE, 0x6f1a, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_DISPLAY_FORMAT", _IOC_NONE, 0x6f1d, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_FORMAT", _IOC_NONE, 0x6f25, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_HIGHLIGHT", _IOC_WRITE, 0x6f27, 0x10 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ID", _IOC_NONE, 0x6f23, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU", _IOC_WRITE, 0x6f32, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU_PALETTE", _IOC_WRITE, 0x6f33, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_STREAMTYPE", _IOC_NONE, 0x6f24, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SYSTEM", _IOC_NONE, 0x6f26, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SLOWMOTION", _IOC_NONE, 0x6f20, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STILLPICTURE", _IOC_WRITE, 0x6f1e, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STOP", _IOC_NONE, 0x6f15, 0x00 },
|
||||
@@ -952,6 +940,14 @@
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SET_ISO_CHANNELS", _IOC_WRITE, 0x2317, 0x0c },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_START_ISO", _IOC_WRITE, 0x230a, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_STOP_ISO", _IOC_WRITE, 0x230b, 0x04 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_CHECK_EXTENSION", _IOC_NONE, 0xb601, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_FME_PORT_PR", _IOC_NONE, 0xb680, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_GET_API_VERSION", _IOC_NONE, 0xb600, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_MAP", _IOC_NONE, 0xb643, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_UNMAP", _IOC_NONE, 0xb644, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_INFO", _IOC_NONE, 0xb641, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_REGION_INFO", _IOC_NONE, 0xb642, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_RESET", _IOC_NONE, 0xb640, 0x00 },
|
||||
{ "linux/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
|
||||
{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
|
||||
{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
|
||||
@@ -1004,6 +1000,10 @@
|
||||
{ "linux/fs.h", "FS_IOC_SETFSLABEL", _IOC_WRITE, 0x9432, 0x100 },
|
||||
{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
|
||||
{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_CHECK", _IOC_READ, 0x7300, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_READ", _IOC_READ|_IOC_WRITE, 0x7301, 0x20 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_RESET", _IOC_WRITE, 0x7303, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_WRITE", _IOC_READ|_IOC_WRITE, 0x7302, 0x20 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_ALPHA", _IOC_READ, 0x4d00, 0x01 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_AOID", _IOC_READ, 0x4d04, 0x08 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_GAMMA", _IOC_READ, 0x4d01, 0x01 },
|
||||
@@ -1335,6 +1335,7 @@
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_MAP_MEMORY_TO_GPU", _IOC_READ|_IOC_WRITE, 0x4b18, 0x18 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
|
||||
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_CU_MASK", _IOC_WRITE, 0x4b1a, 0x10 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_EVENT", _IOC_WRITE, 0x4b0a, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_MEMORY_POLICY", _IOC_WRITE, 0x4b04, 0x20 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_SCRATCH_BACKING_VA", _IOC_READ|_IOC_WRITE, 0x4b11, 0x10 },
|
||||
@@ -1512,9 +1513,12 @@
|
||||
{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_BAR", _IOC_NONE, 0x5001, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_COPY", _IOC_WRITE, 0x5006, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_GET_IRQTYPE", _IOC_NONE, 0x5009, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_LEGACY_IRQ", _IOC_NONE, 0x5002, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_MSI", _IOC_WRITE, 0x5003, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_MSIX", _IOC_WRITE, 0x5007, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_READ", _IOC_WRITE, 0x5005, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_SET_IRQTYPE", _IOC_WRITE, 0x5008, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_WRITE", _IOC_WRITE, 0x5004, 0x04 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
|
||||
@@ -2027,6 +2031,7 @@
|
||||
{ "linux/usb/functionfs.h", "FUNCTIONFS_INTERFACE_REVMAP", _IOC_NONE, 0x6780, 0x00 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_GET_PRINTER_STATUS", _IOC_READ, 0x6721, 0x01 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_SET_PRINTER_STATUS", _IOC_READ|_IOC_WRITE, 0x6722, 0x01 },
|
||||
+{ "linux/usb/g_uvc.h", "UVCIOC_SEND_RESPONSE", _IOC_WRITE, 0x5501, 0x40 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
|
||||
@@ -2038,12 +2043,17 @@
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_LOCAL_LOCKOUT", _IOC_NONE, 0x5b15, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_READ_STB", _IOC_READ, 0x5b12, 0x01 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_REN_CONTROL", _IOC_WRITE, 0x5b13, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_TRIGGER", _IOC_NONE, 0x5b16, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_IN", _IOC_NONE, 0x5b04, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_OUT", _IOC_NONE, 0x5b03, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR", _IOC_NONE, 0x5b02, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_IN_HALT", _IOC_NONE, 0x5b07, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_OUT_HALT", _IOC_NONE, 0x5b06, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_CONFIG_TERMCHAR", _IOC_WRITE, 0x5b0c, 0x02 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_EOM_ENABLE", _IOC_WRITE, 0x5b0b, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_GET_TIMEOUT", _IOC_READ, 0x5b09, 0x04 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_SET_TIMEOUT", _IOC_WRITE, 0x5b0a, 0x04 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_ALLOC_STREAMS", _IOC_READ, 0x551c, 0x08 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK32", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
@@ -2136,6 +2146,7 @@
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", _IOC_NONE, 0x3b76, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_UNMAP_DMA", _IOC_NONE, 0x3b72, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_SET_IOMMU", _IOC_NONE, 0x3b66, 0x00 },
|
||||
+{ "linux/vhost.h", "VHOST_GET_BACKEND_FEATURES", _IOC_READ, 0xaf26, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_FEATURES", _IOC_READ, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BASE", _IOC_READ|_IOC_WRITE, 0xaf12, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf24, 0x08 },
|
||||
@@ -2147,6 +2158,7 @@
|
||||
{ "linux/vhost.h", "VHOST_SCSI_GET_EVENTS_MISSED", _IOC_WRITE, 0xaf44, 0x04 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_ENDPOINT", _IOC_WRITE, 0xaf40, 0xe8 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_EVENTS_MISSED", _IOC_WRITE, 0xaf43, 0x04 },
|
||||
+{ "linux/vhost.h", "VHOST_SET_BACKEND_FEATURES", _IOC_WRITE, 0xaf25, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_FEATURES", _IOC_WRITE, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_BASE", _IOC_WRITE, 0xaf04, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_FD", _IOC_WRITE, 0xaf07, 0x04 },
|
||||
@@ -2216,7 +2228,6 @@
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_EXT_CTRL", _IOC_READ|_IOC_WRITE, 0x5667, 0xe8 },
|
||||
{ "linux/videodev2.h", "VIDIOC_REQBUFS", _IOC_READ|_IOC_WRITE, 0x5608, 0x14 },
|
||||
-{ "linux/videodev2.h", "VIDIOC_RESERVED", _IOC_NONE, 0x5601, 0x00 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMOFF", _IOC_WRITE, 0x5613, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMON", _IOC_WRITE, 0x5612, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_SUBSCRIBE_EVENT", _IOC_WRITE, 0x565a, 0x20 },
|
||||
@@ -2743,6 +2754,10 @@
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESTRICT_DOMID", _IOC_NONE, 0x4506, 0x02 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_FROM_REFS", _IOC_NONE, 0x4709, 0x14 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_WAIT_RELEASED", _IOC_NONE, 0x470a, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_RELEASE", _IOC_NONE, 0x470c, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_TO_REFS", _IOC_NONE, 0x470b, 0x14 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", _IOC_NONE, 0x4702, 0x18 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GRANT_COPY", _IOC_NONE, 0x4708, 0x08 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_MAP_GRANT_REF", _IOC_NONE, 0x4700, 0x18 },
|
||||
diff --git a/linux/32/ioctls_inc_align64.h b/linux/32/ioctls_inc_align64.h
|
||||
index 78a78ac..31059f6 100644
|
||||
--- a/linux/32/ioctls_inc_align64.h
|
||||
+++ b/linux/32/ioctls_inc_align64.h
|
||||
@@ -794,17 +794,13 @@
|
||||
{ "linux/dvb/audio.h", "AUDIO_CLEAR_BUFFER", _IOC_NONE, 0x6f0c, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_CONTINUE", _IOC_NONE, 0x6f04, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_CAPABILITIES", _IOC_READ, 0x6f0b, 0x04 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_GET_PTS", _IOC_READ, 0x6f13, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_STATUS", _IOC_READ, 0x6f0a, 0x20 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PAUSE", _IOC_NONE, 0x6f03, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PLAY", _IOC_NONE, 0x6f02, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SELECT_SOURCE", _IOC_NONE, 0x6f05, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_ATTRIBUTES", _IOC_WRITE, 0x6f11, 0x02 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_AV_SYNC", _IOC_NONE, 0x6f07, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_BYPASS_MODE", _IOC_NONE, 0x6f08, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_EXT_ID", _IOC_NONE, 0x6f10, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_ID", _IOC_NONE, 0x6f0d, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_KARAOKE", _IOC_WRITE, 0x6f12, 0x0c },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MIXER", _IOC_WRITE, 0x6f0e, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MUTE", _IOC_NONE, 0x6f06, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_STREAMTYPE", _IOC_NONE, 0x6f0f, 0x00 },
|
||||
@@ -863,23 +859,15 @@
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_CAPABILITIES", _IOC_READ, 0x6f21, 0x04 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_EVENT", _IOC_READ, 0x6f1c, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_FRAME_COUNT", _IOC_READ, 0x6f3a, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_FRAME_RATE", _IOC_READ, 0x6f38, 0x04 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_NAVI", _IOC_READ, 0x6f34, 0x404 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_PTS", _IOC_READ, 0x6f39, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_SIZE", _IOC_READ, 0x6f37, 0x0c },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_STATUS", _IOC_READ, 0x6f1b, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_PLAY", _IOC_NONE, 0x6f16, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SELECT_SOURCE", _IOC_NONE, 0x6f19, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ATTRIBUTES", _IOC_NONE, 0x6f35, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_BLANK", _IOC_NONE, 0x6f1a, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_DISPLAY_FORMAT", _IOC_NONE, 0x6f1d, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_FORMAT", _IOC_NONE, 0x6f25, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_HIGHLIGHT", _IOC_WRITE, 0x6f27, 0x10 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ID", _IOC_NONE, 0x6f23, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU", _IOC_WRITE, 0x6f32, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU_PALETTE", _IOC_WRITE, 0x6f33, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_STREAMTYPE", _IOC_NONE, 0x6f24, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SYSTEM", _IOC_NONE, 0x6f26, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SLOWMOTION", _IOC_NONE, 0x6f20, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STILLPICTURE", _IOC_WRITE, 0x6f1e, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STOP", _IOC_NONE, 0x6f15, 0x00 },
|
||||
@@ -952,6 +940,14 @@
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SET_ISO_CHANNELS", _IOC_WRITE, 0x2317, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_START_ISO", _IOC_WRITE, 0x230a, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_STOP_ISO", _IOC_WRITE, 0x230b, 0x04 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_CHECK_EXTENSION", _IOC_NONE, 0xb601, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_FME_PORT_PR", _IOC_NONE, 0xb680, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_GET_API_VERSION", _IOC_NONE, 0xb600, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_MAP", _IOC_NONE, 0xb643, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_UNMAP", _IOC_NONE, 0xb644, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_INFO", _IOC_NONE, 0xb641, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_REGION_INFO", _IOC_NONE, 0xb642, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_RESET", _IOC_NONE, 0xb640, 0x00 },
|
||||
{ "linux/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
|
||||
{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
|
||||
{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
|
||||
@@ -1004,6 +1000,10 @@
|
||||
{ "linux/fs.h", "FS_IOC_SETFSLABEL", _IOC_WRITE, 0x9432, 0x100 },
|
||||
{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
|
||||
{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_CHECK", _IOC_READ, 0x7300, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_READ", _IOC_READ|_IOC_WRITE, 0x7301, 0x20 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_RESET", _IOC_WRITE, 0x7303, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_WRITE", _IOC_READ|_IOC_WRITE, 0x7302, 0x20 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_ALPHA", _IOC_READ, 0x4d00, 0x01 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_AOID", _IOC_READ, 0x4d04, 0x08 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_GAMMA", _IOC_READ, 0x4d01, 0x01 },
|
||||
@@ -1335,6 +1335,7 @@
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_MAP_MEMORY_TO_GPU", _IOC_READ|_IOC_WRITE, 0x4b18, 0x18 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
|
||||
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_CU_MASK", _IOC_WRITE, 0x4b1a, 0x10 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_EVENT", _IOC_WRITE, 0x4b0a, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_MEMORY_POLICY", _IOC_WRITE, 0x4b04, 0x20 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_SCRATCH_BACKING_VA", _IOC_READ|_IOC_WRITE, 0x4b11, 0x10 },
|
||||
@@ -1512,9 +1513,12 @@
|
||||
{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_BAR", _IOC_NONE, 0x5001, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_COPY", _IOC_WRITE, 0x5006, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_GET_IRQTYPE", _IOC_NONE, 0x5009, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_LEGACY_IRQ", _IOC_NONE, 0x5002, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_MSI", _IOC_WRITE, 0x5003, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_MSIX", _IOC_WRITE, 0x5007, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_READ", _IOC_WRITE, 0x5005, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_SET_IRQTYPE", _IOC_WRITE, 0x5008, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_WRITE", _IOC_WRITE, 0x5004, 0x04 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
|
||||
@@ -2027,6 +2031,7 @@
|
||||
{ "linux/usb/functionfs.h", "FUNCTIONFS_INTERFACE_REVMAP", _IOC_NONE, 0x6780, 0x00 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_GET_PRINTER_STATUS", _IOC_READ, 0x6721, 0x01 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_SET_PRINTER_STATUS", _IOC_READ|_IOC_WRITE, 0x6722, 0x01 },
|
||||
+{ "linux/usb/g_uvc.h", "UVCIOC_SEND_RESPONSE", _IOC_WRITE, 0x5501, 0x40 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
|
||||
@@ -2038,12 +2043,17 @@
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_LOCAL_LOCKOUT", _IOC_NONE, 0x5b15, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_READ_STB", _IOC_READ, 0x5b12, 0x01 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_REN_CONTROL", _IOC_WRITE, 0x5b13, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_TRIGGER", _IOC_NONE, 0x5b16, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_IN", _IOC_NONE, 0x5b04, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_OUT", _IOC_NONE, 0x5b03, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR", _IOC_NONE, 0x5b02, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_IN_HALT", _IOC_NONE, 0x5b07, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_OUT_HALT", _IOC_NONE, 0x5b06, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_CONFIG_TERMCHAR", _IOC_WRITE, 0x5b0c, 0x02 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_EOM_ENABLE", _IOC_WRITE, 0x5b0b, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_GET_TIMEOUT", _IOC_READ, 0x5b09, 0x04 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_SET_TIMEOUT", _IOC_WRITE, 0x5b0a, 0x04 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_ALLOC_STREAMS", _IOC_READ, 0x551c, 0x08 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK32", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
@@ -2136,6 +2146,7 @@
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", _IOC_NONE, 0x3b76, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_UNMAP_DMA", _IOC_NONE, 0x3b72, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_SET_IOMMU", _IOC_NONE, 0x3b66, 0x00 },
|
||||
+{ "linux/vhost.h", "VHOST_GET_BACKEND_FEATURES", _IOC_READ, 0xaf26, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_FEATURES", _IOC_READ, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BASE", _IOC_READ|_IOC_WRITE, 0xaf12, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf24, 0x08 },
|
||||
@@ -2147,6 +2158,7 @@
|
||||
{ "linux/vhost.h", "VHOST_SCSI_GET_EVENTS_MISSED", _IOC_WRITE, 0xaf44, 0x04 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_ENDPOINT", _IOC_WRITE, 0xaf40, 0xe8 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_EVENTS_MISSED", _IOC_WRITE, 0xaf43, 0x04 },
|
||||
+{ "linux/vhost.h", "VHOST_SET_BACKEND_FEATURES", _IOC_WRITE, 0xaf25, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_FEATURES", _IOC_WRITE, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_BASE", _IOC_WRITE, 0xaf04, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_FD", _IOC_WRITE, 0xaf07, 0x04 },
|
||||
@@ -2216,7 +2228,6 @@
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_EXT_CTRL", _IOC_READ|_IOC_WRITE, 0x5667, 0xe8 },
|
||||
{ "linux/videodev2.h", "VIDIOC_REQBUFS", _IOC_READ|_IOC_WRITE, 0x5608, 0x14 },
|
||||
-{ "linux/videodev2.h", "VIDIOC_RESERVED", _IOC_NONE, 0x5601, 0x00 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMOFF", _IOC_WRITE, 0x5613, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMON", _IOC_WRITE, 0x5612, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_SUBSCRIBE_EVENT", _IOC_WRITE, 0x565a, 0x20 },
|
||||
@@ -2743,6 +2754,10 @@
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESTRICT_DOMID", _IOC_NONE, 0x4506, 0x02 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_FROM_REFS", _IOC_NONE, 0x4709, 0x14 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_WAIT_RELEASED", _IOC_NONE, 0x470a, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_RELEASE", _IOC_NONE, 0x470c, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_TO_REFS", _IOC_NONE, 0x470b, 0x14 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", _IOC_NONE, 0x4702, 0x18 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GRANT_COPY", _IOC_NONE, 0x4708, 0x08 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_MAP_GRANT_REF", _IOC_NONE, 0x4700, 0x18 },
|
||||
diff --git a/linux/64/ioctls_inc.h b/linux/64/ioctls_inc.h
|
||||
index c9fca6b..94c5f56 100644
|
||||
--- a/linux/64/ioctls_inc.h
|
||||
+++ b/linux/64/ioctls_inc.h
|
||||
@@ -794,17 +794,13 @@
|
||||
{ "linux/dvb/audio.h", "AUDIO_CLEAR_BUFFER", _IOC_NONE, 0x6f0c, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_CONTINUE", _IOC_NONE, 0x6f04, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_CAPABILITIES", _IOC_READ, 0x6f0b, 0x04 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_GET_PTS", _IOC_READ, 0x6f13, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_STATUS", _IOC_READ, 0x6f0a, 0x20 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PAUSE", _IOC_NONE, 0x6f03, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PLAY", _IOC_NONE, 0x6f02, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SELECT_SOURCE", _IOC_NONE, 0x6f05, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_ATTRIBUTES", _IOC_WRITE, 0x6f11, 0x02 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_AV_SYNC", _IOC_NONE, 0x6f07, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_BYPASS_MODE", _IOC_NONE, 0x6f08, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_EXT_ID", _IOC_NONE, 0x6f10, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_ID", _IOC_NONE, 0x6f0d, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_KARAOKE", _IOC_WRITE, 0x6f12, 0x0c },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MIXER", _IOC_WRITE, 0x6f0e, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MUTE", _IOC_NONE, 0x6f06, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_STREAMTYPE", _IOC_NONE, 0x6f0f, 0x00 },
|
||||
@@ -863,23 +859,15 @@
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_CAPABILITIES", _IOC_READ, 0x6f21, 0x04 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_EVENT", _IOC_READ, 0x6f1c, 0x20 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_FRAME_COUNT", _IOC_READ, 0x6f3a, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_FRAME_RATE", _IOC_READ, 0x6f38, 0x04 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_NAVI", _IOC_READ, 0x6f34, 0x404 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_PTS", _IOC_READ, 0x6f39, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_SIZE", _IOC_READ, 0x6f37, 0x0c },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_STATUS", _IOC_READ, 0x6f1b, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_PLAY", _IOC_NONE, 0x6f16, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SELECT_SOURCE", _IOC_NONE, 0x6f19, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ATTRIBUTES", _IOC_NONE, 0x6f35, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_BLANK", _IOC_NONE, 0x6f1a, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_DISPLAY_FORMAT", _IOC_NONE, 0x6f1d, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_FORMAT", _IOC_NONE, 0x6f25, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_HIGHLIGHT", _IOC_WRITE, 0x6f27, 0x10 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ID", _IOC_NONE, 0x6f23, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU", _IOC_WRITE, 0x6f32, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU_PALETTE", _IOC_WRITE, 0x6f33, 0x10 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_STREAMTYPE", _IOC_NONE, 0x6f24, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SYSTEM", _IOC_NONE, 0x6f26, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SLOWMOTION", _IOC_NONE, 0x6f20, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STILLPICTURE", _IOC_WRITE, 0x6f1e, 0x10 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STOP", _IOC_NONE, 0x6f15, 0x00 },
|
||||
@@ -952,6 +940,14 @@
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SET_ISO_CHANNELS", _IOC_WRITE, 0x2317, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_START_ISO", _IOC_WRITE, 0x230a, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_STOP_ISO", _IOC_WRITE, 0x230b, 0x04 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_CHECK_EXTENSION", _IOC_NONE, 0xb601, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_FME_PORT_PR", _IOC_NONE, 0xb680, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_GET_API_VERSION", _IOC_NONE, 0xb600, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_MAP", _IOC_NONE, 0xb643, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_UNMAP", _IOC_NONE, 0xb644, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_INFO", _IOC_NONE, 0xb641, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_REGION_INFO", _IOC_NONE, 0xb642, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_RESET", _IOC_NONE, 0xb640, 0x00 },
|
||||
{ "linux/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
|
||||
{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x08 },
|
||||
{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x08 },
|
||||
@@ -1004,6 +1000,10 @@
|
||||
{ "linux/fs.h", "FS_IOC_SETFSLABEL", _IOC_WRITE, 0x9432, 0x100 },
|
||||
{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x08 },
|
||||
{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_CHECK", _IOC_READ, 0x7300, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_READ", _IOC_READ|_IOC_WRITE, 0x7301, 0x20 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_RESET", _IOC_WRITE, 0x7303, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_WRITE", _IOC_READ|_IOC_WRITE, 0x7302, 0x20 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_ALPHA", _IOC_READ, 0x4d00, 0x01 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_AOID", _IOC_READ, 0x4d04, 0x08 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_GAMMA", _IOC_READ, 0x4d01, 0x01 },
|
||||
@@ -1335,6 +1335,7 @@
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_MAP_MEMORY_TO_GPU", _IOC_READ|_IOC_WRITE, 0x4b18, 0x18 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
|
||||
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_CU_MASK", _IOC_WRITE, 0x4b1a, 0x10 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_EVENT", _IOC_WRITE, 0x4b0a, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_MEMORY_POLICY", _IOC_WRITE, 0x4b04, 0x20 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_SCRATCH_BACKING_VA", _IOC_READ|_IOC_WRITE, 0x4b11, 0x10 },
|
||||
@@ -1512,9 +1513,12 @@
|
||||
{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_BAR", _IOC_NONE, 0x5001, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_COPY", _IOC_WRITE, 0x5006, 0x08 },
|
||||
+{ "linux/pcitest.h", "PCITEST_GET_IRQTYPE", _IOC_NONE, 0x5009, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_LEGACY_IRQ", _IOC_NONE, 0x5002, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_MSI", _IOC_WRITE, 0x5003, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_MSIX", _IOC_WRITE, 0x5007, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_READ", _IOC_WRITE, 0x5005, 0x08 },
|
||||
+{ "linux/pcitest.h", "PCITEST_SET_IRQTYPE", _IOC_WRITE, 0x5008, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_WRITE", _IOC_WRITE, 0x5004, 0x08 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
|
||||
@@ -2027,6 +2031,7 @@
|
||||
{ "linux/usb/functionfs.h", "FUNCTIONFS_INTERFACE_REVMAP", _IOC_NONE, 0x6780, 0x00 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_GET_PRINTER_STATUS", _IOC_READ, 0x6721, 0x01 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_SET_PRINTER_STATUS", _IOC_READ|_IOC_WRITE, 0x6722, 0x01 },
|
||||
+{ "linux/usb/g_uvc.h", "UVCIOC_SEND_RESPONSE", _IOC_WRITE, 0x5501, 0x40 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
|
||||
@@ -2038,12 +2043,17 @@
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_LOCAL_LOCKOUT", _IOC_NONE, 0x5b15, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_READ_STB", _IOC_READ, 0x5b12, 0x01 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_REN_CONTROL", _IOC_WRITE, 0x5b13, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_TRIGGER", _IOC_NONE, 0x5b16, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_IN", _IOC_NONE, 0x5b04, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_OUT", _IOC_NONE, 0x5b03, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR", _IOC_NONE, 0x5b02, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_IN_HALT", _IOC_NONE, 0x5b07, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_OUT_HALT", _IOC_NONE, 0x5b06, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_CONFIG_TERMCHAR", _IOC_WRITE, 0x5b0c, 0x02 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_EOM_ENABLE", _IOC_WRITE, 0x5b0b, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_GET_TIMEOUT", _IOC_READ, 0x5b09, 0x04 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_SET_TIMEOUT", _IOC_WRITE, 0x5b0a, 0x04 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_ALLOC_STREAMS", _IOC_READ, 0x551c, 0x08 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK", _IOC_READ|_IOC_WRITE, 0x5502, 0x18 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK32", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
@@ -2136,6 +2146,7 @@
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", _IOC_NONE, 0x3b76, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_UNMAP_DMA", _IOC_NONE, 0x3b72, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_SET_IOMMU", _IOC_NONE, 0x3b66, 0x00 },
|
||||
+{ "linux/vhost.h", "VHOST_GET_BACKEND_FEATURES", _IOC_READ, 0xaf26, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_FEATURES", _IOC_READ, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BASE", _IOC_READ|_IOC_WRITE, 0xaf12, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf24, 0x08 },
|
||||
@@ -2147,6 +2158,7 @@
|
||||
{ "linux/vhost.h", "VHOST_SCSI_GET_EVENTS_MISSED", _IOC_WRITE, 0xaf44, 0x04 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_ENDPOINT", _IOC_WRITE, 0xaf40, 0xe8 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_EVENTS_MISSED", _IOC_WRITE, 0xaf43, 0x04 },
|
||||
+{ "linux/vhost.h", "VHOST_SET_BACKEND_FEATURES", _IOC_WRITE, 0xaf25, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_FEATURES", _IOC_WRITE, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_BASE", _IOC_WRITE, 0xaf04, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_FD", _IOC_WRITE, 0xaf07, 0x04 },
|
||||
@@ -2216,7 +2228,6 @@
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_EXT_CTRL", _IOC_READ|_IOC_WRITE, 0x5667, 0xe8 },
|
||||
{ "linux/videodev2.h", "VIDIOC_REQBUFS", _IOC_READ|_IOC_WRITE, 0x5608, 0x14 },
|
||||
-{ "linux/videodev2.h", "VIDIOC_RESERVED", _IOC_NONE, 0x5601, 0x00 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMOFF", _IOC_WRITE, 0x5613, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMON", _IOC_WRITE, 0x5612, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_SUBSCRIBE_EVENT", _IOC_WRITE, 0x565a, 0x20 },
|
||||
@@ -2743,6 +2754,10 @@
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESTRICT_DOMID", _IOC_NONE, 0x4506, 0x02 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_FROM_REFS", _IOC_NONE, 0x4709, 0x14 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_WAIT_RELEASED", _IOC_NONE, 0x470a, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_RELEASE", _IOC_NONE, 0x470c, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_TO_REFS", _IOC_NONE, 0x470b, 0x14 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", _IOC_NONE, 0x4702, 0x18 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GRANT_COPY", _IOC_NONE, 0x4708, 0x10 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_MAP_GRANT_REF", _IOC_NONE, 0x4700, 0x18 },
|
||||
diff --git a/linux/i386/ioctls_arch0.h b/linux/i386/ioctls_arch0.h
|
||||
index 5b6d3f3..6706dca 100644
|
||||
--- a/linux/i386/ioctls_arch0.h
|
||||
+++ b/linux/i386/ioctls_arch0.h
|
||||
@@ -44,6 +44,7 @@
|
||||
{ "linux/kvm.h", "KVM_GET_MSRS", _IOC_READ|_IOC_WRITE, 0xae88, 0x08 },
|
||||
{ "linux/kvm.h", "KVM_GET_MSR_FEATURE_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae0a, 0x04 },
|
||||
{ "linux/kvm.h", "KVM_GET_MSR_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae02, 0x04 },
|
||||
+{ "linux/kvm.h", "KVM_GET_NESTED_STATE", _IOC_READ|_IOC_WRITE, 0xaebe, 0x80 },
|
||||
{ "linux/kvm.h", "KVM_GET_NR_MMU_PAGES", _IOC_NONE, 0xae45, 0x00 },
|
||||
{ "linux/kvm.h", "KVM_GET_ONE_REG", _IOC_WRITE, 0xaeab, 0x10 },
|
||||
{ "linux/kvm.h", "KVM_GET_PIT", _IOC_READ|_IOC_WRITE, 0xae65, 0x48 },
|
||||
@@ -88,6 +89,7 @@
|
||||
{ "linux/kvm.h", "KVM_SET_MEMORY_REGION", _IOC_WRITE, 0xae40, 0x18 },
|
||||
{ "linux/kvm.h", "KVM_SET_MP_STATE", _IOC_WRITE, 0xae99, 0x04 },
|
||||
{ "linux/kvm.h", "KVM_SET_MSRS", _IOC_WRITE, 0xae89, 0x08 },
|
||||
+{ "linux/kvm.h", "KVM_SET_NESTED_STATE", _IOC_WRITE, 0xaebf, 0x80 },
|
||||
{ "linux/kvm.h", "KVM_SET_NR_MMU_PAGES", _IOC_NONE, 0xae44, 0x00 },
|
||||
{ "linux/kvm.h", "KVM_SET_ONE_REG", _IOC_WRITE, 0xaeac, 0x10 },
|
||||
{ "linux/kvm.h", "KVM_SET_PIT", _IOC_READ, 0xae66, 0x48 },
|
||||
diff --git a/linux/x32/ioctls_inc0.h b/linux/x32/ioctls_inc0.h
|
||||
index b20c29b..193526e 100644
|
||||
--- a/linux/x32/ioctls_inc0.h
|
||||
+++ b/linux/x32/ioctls_inc0.h
|
||||
@@ -794,17 +794,13 @@
|
||||
{ "linux/dvb/audio.h", "AUDIO_CLEAR_BUFFER", _IOC_NONE, 0x6f0c, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_CONTINUE", _IOC_NONE, 0x6f04, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_CAPABILITIES", _IOC_READ, 0x6f0b, 0x04 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_GET_PTS", _IOC_READ, 0x6f13, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_GET_STATUS", _IOC_READ, 0x6f0a, 0x20 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PAUSE", _IOC_NONE, 0x6f03, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_PLAY", _IOC_NONE, 0x6f02, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SELECT_SOURCE", _IOC_NONE, 0x6f05, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_ATTRIBUTES", _IOC_WRITE, 0x6f11, 0x02 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_AV_SYNC", _IOC_NONE, 0x6f07, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_BYPASS_MODE", _IOC_NONE, 0x6f08, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_EXT_ID", _IOC_NONE, 0x6f10, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_ID", _IOC_NONE, 0x6f0d, 0x00 },
|
||||
-{ "linux/dvb/audio.h", "AUDIO_SET_KARAOKE", _IOC_WRITE, 0x6f12, 0x0c },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MIXER", _IOC_WRITE, 0x6f0e, 0x08 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_MUTE", _IOC_NONE, 0x6f06, 0x00 },
|
||||
{ "linux/dvb/audio.h", "AUDIO_SET_STREAMTYPE", _IOC_NONE, 0x6f0f, 0x00 },
|
||||
@@ -863,23 +859,15 @@
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_CAPABILITIES", _IOC_READ, 0x6f21, 0x04 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_EVENT", _IOC_READ, 0x6f1c, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_FRAME_COUNT", _IOC_READ, 0x6f3a, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_FRAME_RATE", _IOC_READ, 0x6f38, 0x04 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_GET_NAVI", _IOC_READ, 0x6f34, 0x404 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_PTS", _IOC_READ, 0x6f39, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_SIZE", _IOC_READ, 0x6f37, 0x0c },
|
||||
{ "linux/dvb/video.h", "VIDEO_GET_STATUS", _IOC_READ, 0x6f1b, 0x14 },
|
||||
{ "linux/dvb/video.h", "VIDEO_PLAY", _IOC_NONE, 0x6f16, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SELECT_SOURCE", _IOC_NONE, 0x6f19, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ATTRIBUTES", _IOC_NONE, 0x6f35, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_BLANK", _IOC_NONE, 0x6f1a, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_DISPLAY_FORMAT", _IOC_NONE, 0x6f1d, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_FORMAT", _IOC_NONE, 0x6f25, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_HIGHLIGHT", _IOC_WRITE, 0x6f27, 0x10 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_ID", _IOC_NONE, 0x6f23, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU", _IOC_WRITE, 0x6f32, 0x08 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SPU_PALETTE", _IOC_WRITE, 0x6f33, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SET_STREAMTYPE", _IOC_NONE, 0x6f24, 0x00 },
|
||||
-{ "linux/dvb/video.h", "VIDEO_SET_SYSTEM", _IOC_NONE, 0x6f26, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_SLOWMOTION", _IOC_NONE, 0x6f20, 0x00 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STILLPICTURE", _IOC_WRITE, 0x6f1e, 0x08 },
|
||||
{ "linux/dvb/video.h", "VIDEO_STOP", _IOC_NONE, 0x6f15, 0x00 },
|
||||
@@ -952,6 +940,14 @@
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SET_ISO_CHANNELS", _IOC_WRITE, 0x2317, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_START_ISO", _IOC_WRITE, 0x230a, 0x10 },
|
||||
{ "linux/firewire-cdev.h", "FW_CDEV_IOC_STOP_ISO", _IOC_WRITE, 0x230b, 0x04 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_CHECK_EXTENSION", _IOC_NONE, 0xb601, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_FME_PORT_PR", _IOC_NONE, 0xb680, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_GET_API_VERSION", _IOC_NONE, 0xb600, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_MAP", _IOC_NONE, 0xb643, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_DMA_UNMAP", _IOC_NONE, 0xb644, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_INFO", _IOC_NONE, 0xb641, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_GET_REGION_INFO", _IOC_NONE, 0xb642, 0x00 },
|
||||
+{ "linux/fpga-dfl.h", "DFL_FPGA_PORT_RESET", _IOC_NONE, 0xb640, 0x00 },
|
||||
{ "linux/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
|
||||
{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
|
||||
{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
|
||||
@@ -1004,6 +1000,10 @@
|
||||
{ "linux/fs.h", "FS_IOC_SETFSLABEL", _IOC_WRITE, 0x9432, 0x100 },
|
||||
{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
|
||||
{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_CHECK", _IOC_READ, 0x7300, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_READ", _IOC_READ|_IOC_WRITE, 0x7301, 0x20 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_RESET", _IOC_WRITE, 0x7303, 0x04 },
|
||||
+{ "linux/fsi.h", "FSI_SCOM_WRITE", _IOC_READ|_IOC_WRITE, 0x7302, 0x20 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_ALPHA", _IOC_READ, 0x4d00, 0x01 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_AOID", _IOC_READ, 0x4d04, 0x08 },
|
||||
{ "linux/fsl-diu-fb.h", "MFB_GET_GAMMA", _IOC_READ, 0x4d01, 0x01 },
|
||||
@@ -1335,6 +1335,7 @@
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_MAP_MEMORY_TO_GPU", _IOC_READ|_IOC_WRITE, 0x4b18, 0x18 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
|
||||
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_CU_MASK", _IOC_WRITE, 0x4b1a, 0x10 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_EVENT", _IOC_WRITE, 0x4b0a, 0x08 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_MEMORY_POLICY", _IOC_WRITE, 0x4b04, 0x20 },
|
||||
{ "linux/kfd_ioctl.h", "AMDKFD_IOC_SET_SCRATCH_BACKING_VA", _IOC_READ|_IOC_WRITE, 0x4b11, 0x10 },
|
||||
@@ -1512,9 +1513,12 @@
|
||||
{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_BAR", _IOC_NONE, 0x5001, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_COPY", _IOC_WRITE, 0x5006, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_GET_IRQTYPE", _IOC_NONE, 0x5009, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_LEGACY_IRQ", _IOC_NONE, 0x5002, 0x00 },
|
||||
{ "linux/pcitest.h", "PCITEST_MSI", _IOC_WRITE, 0x5003, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_MSIX", _IOC_WRITE, 0x5007, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_READ", _IOC_WRITE, 0x5005, 0x04 },
|
||||
+{ "linux/pcitest.h", "PCITEST_SET_IRQTYPE", _IOC_WRITE, 0x5008, 0x04 },
|
||||
{ "linux/pcitest.h", "PCITEST_WRITE", _IOC_WRITE, 0x5004, 0x04 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
|
||||
{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
|
||||
@@ -2027,6 +2031,7 @@
|
||||
{ "linux/usb/functionfs.h", "FUNCTIONFS_INTERFACE_REVMAP", _IOC_NONE, 0x6780, 0x00 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_GET_PRINTER_STATUS", _IOC_READ, 0x6721, 0x01 },
|
||||
{ "linux/usb/g_printer.h", "GADGET_SET_PRINTER_STATUS", _IOC_READ|_IOC_WRITE, 0x6722, 0x01 },
|
||||
+{ "linux/usb/g_uvc.h", "UVCIOC_SEND_RESPONSE", _IOC_WRITE, 0x5501, 0x40 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
|
||||
{ "linux/usb/gadgetfs.h", "GADGETFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
|
||||
@@ -2038,12 +2043,17 @@
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_LOCAL_LOCKOUT", _IOC_NONE, 0x5b15, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_READ_STB", _IOC_READ, 0x5b12, 0x01 },
|
||||
{ "linux/usb/tmc.h", "USBTMC488_IOCTL_REN_CONTROL", _IOC_WRITE, 0x5b13, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_TRIGGER", _IOC_NONE, 0x5b16, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_IN", _IOC_NONE, 0x5b04, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_ABORT_BULK_OUT", _IOC_NONE, 0x5b03, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR", _IOC_NONE, 0x5b02, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_IN_HALT", _IOC_NONE, 0x5b07, 0x00 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_CLEAR_OUT_HALT", _IOC_NONE, 0x5b06, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_CONFIG_TERMCHAR", _IOC_WRITE, 0x5b0c, 0x02 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_EOM_ENABLE", _IOC_WRITE, 0x5b0b, 0x01 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_GET_TIMEOUT", _IOC_READ, 0x5b09, 0x04 },
|
||||
{ "linux/usb/tmc.h", "USBTMC_IOCTL_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
|
||||
+{ "linux/usb/tmc.h", "USBTMC_IOCTL_SET_TIMEOUT", _IOC_WRITE, 0x5b0a, 0x04 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_ALLOC_STREAMS", _IOC_READ, 0x551c, 0x08 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
{ "linux/usbdevice_fs.h", "USBDEVFS_BULK32", _IOC_READ|_IOC_WRITE, 0x5502, 0x10 },
|
||||
@@ -2136,6 +2146,7 @@
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", _IOC_NONE, 0x3b76, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_IOMMU_UNMAP_DMA", _IOC_NONE, 0x3b72, 0x00 },
|
||||
{ "linux/vfio.h", "VFIO_SET_IOMMU", _IOC_NONE, 0x3b66, 0x00 },
|
||||
+{ "linux/vhost.h", "VHOST_GET_BACKEND_FEATURES", _IOC_READ, 0xaf26, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_FEATURES", _IOC_READ, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BASE", _IOC_READ|_IOC_WRITE, 0xaf12, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf24, 0x08 },
|
||||
@@ -2147,6 +2158,7 @@
|
||||
{ "linux/vhost.h", "VHOST_SCSI_GET_EVENTS_MISSED", _IOC_WRITE, 0xaf44, 0x04 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_ENDPOINT", _IOC_WRITE, 0xaf40, 0xe8 },
|
||||
{ "linux/vhost.h", "VHOST_SCSI_SET_EVENTS_MISSED", _IOC_WRITE, 0xaf43, 0x04 },
|
||||
+{ "linux/vhost.h", "VHOST_SET_BACKEND_FEATURES", _IOC_WRITE, 0xaf25, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_FEATURES", _IOC_WRITE, 0xaf00, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_BASE", _IOC_WRITE, 0xaf04, 0x08 },
|
||||
{ "linux/vhost.h", "VHOST_SET_LOG_FD", _IOC_WRITE, 0xaf07, 0x04 },
|
||||
@@ -2216,7 +2228,6 @@
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_DV_TIMINGS", _IOC_READ, 0x5663, 0x84 },
|
||||
{ "linux/videodev2.h", "VIDIOC_QUERY_EXT_CTRL", _IOC_READ|_IOC_WRITE, 0x5667, 0xe8 },
|
||||
{ "linux/videodev2.h", "VIDIOC_REQBUFS", _IOC_READ|_IOC_WRITE, 0x5608, 0x14 },
|
||||
-{ "linux/videodev2.h", "VIDIOC_RESERVED", _IOC_NONE, 0x5601, 0x00 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMOFF", _IOC_WRITE, 0x5613, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_STREAMON", _IOC_WRITE, 0x5612, 0x04 },
|
||||
{ "linux/videodev2.h", "VIDIOC_SUBSCRIBE_EVENT", _IOC_WRITE, 0x565a, 0x20 },
|
||||
@@ -2743,6 +2754,10 @@
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_RESTRICT_DOMID", _IOC_NONE, 0x4506, 0x02 },
|
||||
{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_FROM_REFS", _IOC_NONE, 0x4709, 0x14 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_EXP_WAIT_RELEASED", _IOC_NONE, 0x470a, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_RELEASE", _IOC_NONE, 0x470c, 0x08 },
|
||||
+{ "xen/gntdev.h", "IOCTL_GNTDEV_DMABUF_IMP_TO_REFS", _IOC_NONE, 0x470b, 0x14 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", _IOC_NONE, 0x4702, 0x18 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_GRANT_COPY", _IOC_NONE, 0x4708, 0x08 },
|
||||
{ "xen/gntdev.h", "IOCTL_GNTDEV_MAP_GRANT_REF", _IOC_NONE, 0x4700, 0x18 },
|
||||
diff --git a/linux/x86_64/ioctls_arch0.h b/linux/x86_64/ioctls_arch0.h
|
||||
index 3399500..368dbc3 100644
|
||||
--- a/linux/x86_64/ioctls_arch0.h
|
||||
+++ b/linux/x86_64/ioctls_arch0.h
|
||||
@@ -44,6 +44,7 @@
|
||||
{ "linux/kvm.h", "KVM_GET_MSRS", _IOC_READ|_IOC_WRITE, 0xae88, 0x08 },
|
||||
{ "linux/kvm.h", "KVM_GET_MSR_FEATURE_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae0a, 0x04 },
|
||||
{ "linux/kvm.h", "KVM_GET_MSR_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae02, 0x04 },
|
||||
+{ "linux/kvm.h", "KVM_GET_NESTED_STATE", _IOC_READ|_IOC_WRITE, 0xaebe, 0x80 },
|
||||
{ "linux/kvm.h", "KVM_GET_NR_MMU_PAGES", _IOC_NONE, 0xae45, 0x00 },
|
||||
{ "linux/kvm.h", "KVM_GET_ONE_REG", _IOC_WRITE, 0xaeab, 0x10 },
|
||||
{ "linux/kvm.h", "KVM_GET_PIT", _IOC_READ|_IOC_WRITE, 0xae65, 0x48 },
|
||||
@@ -88,6 +89,7 @@
|
||||
{ "linux/kvm.h", "KVM_SET_MEMORY_REGION", _IOC_WRITE, 0xae40, 0x18 },
|
||||
{ "linux/kvm.h", "KVM_SET_MP_STATE", _IOC_WRITE, 0xae99, 0x04 },
|
||||
{ "linux/kvm.h", "KVM_SET_MSRS", _IOC_WRITE, 0xae89, 0x08 },
|
||||
+{ "linux/kvm.h", "KVM_SET_NESTED_STATE", _IOC_WRITE, 0xaebf, 0x80 },
|
||||
{ "linux/kvm.h", "KVM_SET_NR_MMU_PAGES", _IOC_NONE, 0xae44, 0x00 },
|
||||
{ "linux/kvm.h", "KVM_SET_ONE_REG", _IOC_WRITE, 0xaeac, 0x10 },
|
||||
{ "linux/kvm.h", "KVM_SET_PIT", _IOC_READ, 0xae66, 0x48 },
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
38
Wire-up-rseq-syscall-on-architectures-that-use-gener.patch
Normal file
38
Wire-up-rseq-syscall-on-architectures-that-use-gener.patch
Normal file
@ -0,0 +1,38 @@
|
||||
From 0b051a218d5e7e51677c26c691dcf619a7d894e9 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Mon, 11 Feb 2019 23:35:07 +0000
|
||||
Subject: [PATCH 229/293] Wire up rseq syscall on architectures that use
|
||||
generic unistd.h
|
||||
|
||||
* linux/32/syscallent.h [293]: Wire up rseq syscall introduced by linux
|
||||
commit v4.19-rc1~109^2~47.
|
||||
* linux/64/syscallent.h [293]: Likewise.
|
||||
---
|
||||
linux/32/syscallent.h | 1 +
|
||||
linux/64/syscallent.h | 1 +
|
||||
3 files changed, 4 insertions(+)
|
||||
|
||||
diff --git a/linux/32/syscallent.h b/linux/32/syscallent.h
|
||||
index 901b889..145f07b 100644
|
||||
--- a/linux/32/syscallent.h
|
||||
+++ b/linux/32/syscallent.h
|
||||
@@ -290,6 +290,7 @@
|
||||
[290] = { 1, 0, SEN(pkey_free), "pkey_free" },
|
||||
[291] = { 5, TD|TF|TSTA, SEN(statx), "statx" },
|
||||
[292] = { 6, 0, SEN(io_pgetevents), "io_pgetevents" },
|
||||
+[293] = { 4, 0, SEN(rseq), "rseq" },
|
||||
|
||||
#undef sys_ARCH_mmap
|
||||
#undef ARCH_WANT_SYNC_FILE_RANGE2
|
||||
diff --git a/linux/64/syscallent.h b/linux/64/syscallent.h
|
||||
index d08b161..1c4b80d 100644
|
||||
--- a/linux/64/syscallent.h
|
||||
+++ b/linux/64/syscallent.h
|
||||
@@ -283,3 +283,4 @@
|
||||
[290] = { 1, 0, SEN(pkey_free), "pkey_free" },
|
||||
[291] = { 5, TD|TF|TSTA, SEN(statx), "statx" },
|
||||
[292] = { 6, 0, SEN(io_pgetevents), "io_pgetevents" },
|
||||
+[293] = { 4, 0, SEN(rseq), "rseq" },
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
3271
adapt-for-backport-patch.patch
Normal file
3271
adapt-for-backport-patch.patch
Normal file
File diff suppressed because one or more lines are too long
64
arm-sparc-sparc64-wire-up-io_pgetevents.patch
Normal file
64
arm-sparc-sparc64-wire-up-io_pgetevents.patch
Normal file
@ -0,0 +1,64 @@
|
||||
From 43700247534bee217cdf1ec553558c4dcf158335 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Wed, 24 Oct 2018 09:05:38 +0000
|
||||
Subject: [PATCH 091/293] arm, sparc, sparc64: wire up io_pgetevents
|
||||
|
||||
* linux/arm/syscallent.h ([399]): Wire up io_pgetevents syscall
|
||||
introduced by Linux commit v4.19-rc7~24^2~1.
|
||||
(ARM_FIRST_SHUFFLED_SYSCALL, SYS_socket_subcall): Raise from 400 to 500,
|
||||
to make room for new syscalls.
|
||||
* linux/sparc/syscallent.h ([361]): Wire up io_pgetevents syscall
|
||||
introduced by Linux commit v4.19~31^2~5.
|
||||
* linux/sparc64/syscallent.h: Likewise.
|
||||
---
|
||||
linux/arm/syscallent.h | 5 +++--
|
||||
linux/sparc/syscallent.h | 1 +
|
||||
linux/sparc64/syscallent.h | 1 +
|
||||
3 files changed, 5 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/linux/arm/syscallent.h b/linux/arm/syscallent.h
|
||||
index 568d946..4577db8 100644
|
||||
--- a/linux/arm/syscallent.h
|
||||
+++ b/linux/arm/syscallent.h
|
||||
@@ -424,11 +424,12 @@
|
||||
[396] = { 1, 0, SEN(pkey_free), "pkey_free" },
|
||||
[397] = { 5, TD|TF|TSTA, SEN(statx), "statx" },
|
||||
[398] = { 4, 0, SEN(rseq), "rseq" },
|
||||
+[399] = { 6, 0, SEN(io_pgetevents), "io_pgetevents" },
|
||||
|
||||
#ifdef __ARM_EABI__
|
||||
-# define ARM_FIRST_SHUFFLED_SYSCALL 400
|
||||
+# define ARM_FIRST_SHUFFLED_SYSCALL 500
|
||||
#else
|
||||
-# define SYS_socket_subcall 400
|
||||
+# define SYS_socket_subcall 500
|
||||
# include "subcall.h"
|
||||
# define ARM_FIRST_SHUFFLED_SYSCALL (SYS_ipc_subcall + SYS_ipc_nsubcalls)
|
||||
#endif /* !__ARM_EABI__ */
|
||||
diff --git a/linux/sparc/syscallent.h b/linux/sparc/syscallent.h
|
||||
index b6a378a..4c409b4 100644
|
||||
--- a/linux/sparc/syscallent.h
|
||||
+++ b/linux/sparc/syscallent.h
|
||||
@@ -359,6 +359,7 @@
|
||||
[358] = { 6, TD, SEN(preadv2), "preadv2" },
|
||||
[359] = { 6, TD, SEN(pwritev2), "pwritev2" },
|
||||
[360] = { 5, TD|TF|TSTA, SEN(statx), "statx" },
|
||||
+[361] = { 6, 0, SEN(io_pgetevents), "io_pgetevents" },
|
||||
|
||||
#define SYS_socket_subcall 400
|
||||
#include "subcall.h"
|
||||
diff --git a/linux/sparc64/syscallent.h b/linux/sparc64/syscallent.h
|
||||
index fc2e921..a3a2858 100644
|
||||
--- a/linux/sparc64/syscallent.h
|
||||
+++ b/linux/sparc64/syscallent.h
|
||||
@@ -357,6 +357,7 @@
|
||||
[358] = { 6, TD, SEN(preadv2), "preadv2" },
|
||||
[359] = { 6, TD, SEN(pwritev2), "pwritev2" },
|
||||
[360] = { 5, TD|TF|TSTA, SEN(statx), "statx" },
|
||||
+[361] = { 6, 0, SEN(io_pgetevents), "io_pgetevents" },
|
||||
|
||||
#define SYS_socket_subcall 400
|
||||
#include "subcall.h"
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
110
bpf-add-support-for-btf_-fields-in-BPF_MAP_CREATE.patch
Normal file
110
bpf-add-support-for-btf_-fields-in-BPF_MAP_CREATE.patch
Normal file
@ -0,0 +1,110 @@
|
||||
From 14a9b6ca66109fc1231eb16e98a9ce4262fb610c Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Tue, 12 Mar 2019 11:17:20 +0000
|
||||
Subject: [PATCH 269/293] bpf: add support for btf_* fields in BPF_MAP_CREATE
|
||||
|
||||
* bpf_attr.h (struct BPF_MAP_CREATE_struct): Add btf_fd,
|
||||
btf_key_type_id, and btf_value_type_id fields.
|
||||
* bpf.c (BEGIN_BPF_CMD_DECODER(BPF_MAP_CREATE)): Decode btf_fd,
|
||||
btf_key_type_id, and btf_value_type_id fields introduced by Linux
|
||||
commits v4.18-rc1~114^2~417^2~1^2~3 and v4.18-rc1~114^2~148^2~7^2~2.
|
||||
* tests/bpf.c (BPF_MAP_CREATE_checks): Check it.
|
||||
* tests/bpf-obj_get_info_by_fd.c (print_map_create): Update expected
|
||||
output.
|
||||
---
|
||||
bpf.c | 10 ++++++++++
|
||||
bpf_attr.h | 5 ++++-
|
||||
tests/bpf-obj_get_info_by_fd.c | 4 ++++
|
||||
tests/bpf.c | 20 ++++++++++++++++++++
|
||||
4 files changed, 38 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bpf.c b/bpf.c
|
||||
index 6fb4c2c..bf7cd6c 100644
|
||||
--- a/bpf.c
|
||||
+++ b/bpf.c
|
||||
@@ -232,6 +232,16 @@ BEGIN_BPF_CMD_DECODER(BPF_MAP_CREATE)
|
||||
if (len <= offsetof(struct BPF_MAP_CREATE_struct, map_ifindex))
|
||||
break;
|
||||
PRINT_FIELD_IFINDEX(", ", attr, map_ifindex);
|
||||
+
|
||||
+ /*
|
||||
+ * The following three fields were introduced by Linux commits
|
||||
+ * v4.18-rc1~114^2~417^2~1^2~3 and v4.18-rc1~114^2~148^2~7^2~2.
|
||||
+ */
|
||||
+ if (len <= offsetof(struct BPF_MAP_CREATE_struct, btf_fd))
|
||||
+ break;
|
||||
+ PRINT_FIELD_FD(", ", attr, btf_fd, tcp);
|
||||
+ PRINT_FIELD_U(", ", attr, btf_key_type_id);
|
||||
+ PRINT_FIELD_U(", ", attr, btf_value_type_id);
|
||||
}
|
||||
END_BPF_CMD_DECODER(RVAL_DECODED | RVAL_FD)
|
||||
|
||||
diff --git a/bpf_attr.h b/bpf_attr.h
|
||||
index cb49896..a789d10 100644
|
||||
--- a/bpf_attr.h
|
||||
+++ b/bpf_attr.h
|
||||
@@ -65,11 +65,14 @@ struct BPF_MAP_CREATE_struct {
|
||||
uint32_t numa_node;
|
||||
char map_name[BPF_OBJ_NAME_LEN];
|
||||
uint32_t map_ifindex;
|
||||
+ uint32_t btf_fd;
|
||||
+ uint32_t btf_key_type_id;
|
||||
+ uint32_t btf_value_type_id;
|
||||
};
|
||||
|
||||
#define BPF_MAP_CREATE_struct_size \
|
||||
sizeof(struct BPF_MAP_CREATE_struct)
|
||||
-#define expected_BPF_MAP_CREATE_struct_size 48
|
||||
+#define expected_BPF_MAP_CREATE_struct_size 60
|
||||
|
||||
struct BPF_MAP_LOOKUP_ELEM_struct {
|
||||
uint32_t map_fd;
|
||||
diff --git a/tests/bpf-obj_get_info_by_fd.c b/tests/bpf-obj_get_info_by_fd.c
|
||||
index ff06e27..02d14e5 100644
|
||||
--- a/tests/bpf-obj_get_info_by_fd.c
|
||||
+++ b/tests/bpf-obj_get_info_by_fd.c
|
||||
@@ -103,6 +103,10 @@ print_map_create(void *attr_void, size_t size, long rc)
|
||||
printf(", map_name=\"test_map\"");
|
||||
if (size > offsetof(struct BPF_MAP_CREATE_struct, map_ifindex))
|
||||
printf(", map_ifindex=0");
|
||||
+ if (size > offsetof(struct BPF_MAP_CREATE_struct, btf_fd)) {
|
||||
+ printf(", btf_fd=0</dev/null>"
|
||||
+ ", btf_key_type_id=0, btf_value_type_id=0");
|
||||
+ }
|
||||
printf("}, %zu) = ", size);
|
||||
if (rc >= 0)
|
||||
printf("%ld<anon_inode:bpf-map>\n", rc);
|
||||
diff --git a/tests/bpf.c b/tests/bpf.c
|
||||
index cfed319..b18a056 100644
|
||||
--- a/tests/bpf.c
|
||||
+++ b/tests/bpf.c
|
||||
@@ -420,6 +420,26 @@ static struct bpf_attr_check BPF_MAP_CREATE_checks[] = {
|
||||
", map_ifindex=" IFINDEX_LO_STR,
|
||||
.init_fn = init_BPF_MAP_CREATE_attr7,
|
||||
},
|
||||
+ { /* 8 */
|
||||
+ .data = { .BPF_MAP_CREATE_data = {
|
||||
+ .btf_fd = 0xbadc0ded,
|
||||
+ .btf_key_type_id = 0xfacefeed,
|
||||
+ .btf_value_type_id = 0xcafef00d
|
||||
+ } },
|
||||
+ .size = offsetofend(struct BPF_MAP_CREATE_struct,
|
||||
+ btf_value_type_id),
|
||||
+ .str = "map_type=BPF_MAP_TYPE_UNSPEC"
|
||||
+ ", key_size=0"
|
||||
+ ", value_size=0"
|
||||
+ ", max_entries=0"
|
||||
+ ", map_flags=0"
|
||||
+ ", inner_map_fd=0"
|
||||
+ ", map_name=\"\""
|
||||
+ ", map_ifindex=0"
|
||||
+ ", btf_fd=-1159983635"
|
||||
+ ", btf_key_type_id=4207869677"
|
||||
+ ", btf_value_type_id=3405705229"
|
||||
+ },
|
||||
};
|
||||
|
||||
static const struct bpf_attr_check BPF_MAP_LOOKUP_ELEM_checks[] = {
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
145
bpf-add-support-for-jited_ksyms-and-jited_func_lens-.patch
Normal file
145
bpf-add-support-for-jited_ksyms-and-jited_func_lens-.patch
Normal file
@ -0,0 +1,145 @@
|
||||
From d1f90bcdc7cf95cf442321f18452d0367e80b7d5 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Tue, 12 Mar 2019 11:17:20 +0000
|
||||
Subject: [PATCH 271/293] bpf: add support for *jited_ksyms and
|
||||
*jited_func_lens fields in struct bpf_prog_info
|
||||
|
||||
* bpf_attr.h (struct bpf_prog_info_struct): Add nr_jited_ksyms,
|
||||
nr_jited_func_lens, jited_ksyms, and jited_func_lens fields.
|
||||
* bpf.c (struct obj_get_info_saved): Likewise.
|
||||
(print_bpf_prog_info): Decode these fields introduced by Linux commits
|
||||
v4.18-rc1~114^2~148^2~3^2~6 and v4.18-rc1~114^2~148^2~3^2~2.
|
||||
* tests/bpf-obj_get_info_by_fd.c (main): Update expected output.
|
||||
---
|
||||
bpf.c | 40 ++++++++++++++++++++++++++++++++++++++++
|
||||
bpf_attr.h | 6 +++++-
|
||||
tests/bpf-obj_get_info_by_fd.c | 21 +++++++++++++++++++++
|
||||
3 files changed, 66 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bpf.c b/bpf.c
|
||||
index 31bdd9b..c1a4e52 100644
|
||||
--- a/bpf.c
|
||||
+++ b/bpf.c
|
||||
@@ -447,6 +447,11 @@ struct obj_get_info_saved {
|
||||
uint32_t jited_prog_len;
|
||||
uint32_t xlated_prog_len;
|
||||
uint32_t nr_map_ids;
|
||||
+ uint32_t nr_jited_ksyms;
|
||||
+
|
||||
+ uint32_t nr_jited_func_lens;
|
||||
+ uint64_t jited_ksyms;
|
||||
+ uint64_t jited_func_lens;
|
||||
};
|
||||
|
||||
static void
|
||||
@@ -507,6 +512,10 @@ print_bpf_prog_info(struct tcb * const tcp, uint32_t bpf_fd,
|
||||
saved->jited_prog_len = info.jited_prog_len;
|
||||
saved->xlated_prog_len = info.xlated_prog_len;
|
||||
saved->nr_map_ids = info.nr_map_ids;
|
||||
+ saved->nr_jited_ksyms = info.nr_jited_ksyms;
|
||||
+ saved->nr_jited_func_lens = info.nr_jited_func_lens;
|
||||
+ saved->jited_ksyms = info.jited_ksyms;
|
||||
+ saved->jited_func_lens = info.jited_func_lens;
|
||||
|
||||
return;
|
||||
}
|
||||
@@ -569,6 +578,37 @@ print_bpf_prog_info(struct tcb * const tcp, uint32_t bpf_fd,
|
||||
PRINT_FIELD_DEV(", ", info, netns_dev);
|
||||
PRINT_FIELD_U(", ", info, netns_ino);
|
||||
|
||||
+ /*
|
||||
+ * The next four fields were introduced by Linux commits
|
||||
+ * v4.18-rc1~114^2~148^2~3^2~6 and v4.18-rc1~114^2~148^2~3^2~2.
|
||||
+ */
|
||||
+ if (len <= offsetof(struct bpf_prog_info_struct, nr_jited_ksyms))
|
||||
+ goto print_bpf_prog_info_end;
|
||||
+
|
||||
+ tprints(", nr_jited_ksyms=");
|
||||
+ if (saved->nr_jited_ksyms != info.nr_jited_ksyms)
|
||||
+ tprintf("%" PRIu32 " => ", saved->nr_jited_ksyms);
|
||||
+ tprintf("%" PRIu32, info.nr_jited_ksyms);
|
||||
+
|
||||
+ tprints(", nr_jited_func_lens=");
|
||||
+ if (saved->nr_jited_func_lens != info.nr_jited_func_lens)
|
||||
+ tprintf("%" PRIu32 " => ", saved->nr_jited_func_lens);
|
||||
+ tprintf("%" PRIu32, info.nr_jited_func_lens);
|
||||
+
|
||||
+ tprints(", jited_ksyms=");
|
||||
+ if (saved->jited_ksyms != info.jited_ksyms) {
|
||||
+ printaddr64(saved->jited_ksyms);
|
||||
+ tprints(" => ");
|
||||
+ }
|
||||
+ printaddr64(info.jited_ksyms);
|
||||
+
|
||||
+ tprints(", jited_func_lens=");
|
||||
+ if (saved->jited_func_lens != info.jited_func_lens) {
|
||||
+ printaddr64(saved->jited_func_lens);
|
||||
+ tprints(" => ");
|
||||
+ }
|
||||
+ printaddr64(info.jited_func_lens);
|
||||
+
|
||||
decode_attr_extra_data(tcp, info_buf, size, bpf_prog_info_struct_size);
|
||||
|
||||
print_bpf_prog_info_end:
|
||||
diff --git a/bpf_attr.h b/bpf_attr.h
|
||||
index 7da8af6..d23d464 100644
|
||||
--- a/bpf_attr.h
|
||||
+++ b/bpf_attr.h
|
||||
@@ -289,10 +289,14 @@ struct bpf_prog_info_struct {
|
||||
*/
|
||||
uint64_t ATTRIBUTE_ALIGNED(8) netns_dev; /* skip check */
|
||||
uint64_t ATTRIBUTE_ALIGNED(8) netns_ino; /* skip check */
|
||||
+ uint32_t nr_jited_ksyms;
|
||||
+ uint32_t nr_jited_func_lens;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) jited_ksyms;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) jited_func_lens;
|
||||
};
|
||||
|
||||
#define bpf_prog_info_struct_size \
|
||||
sizeof(struct bpf_prog_info_struct)
|
||||
-#define expected_bpf_prog_info_struct_size 104
|
||||
+#define expected_bpf_prog_info_struct_size 128
|
||||
|
||||
#endif /* !STRACE_BPF_ATTR_H */
|
||||
diff --git a/tests/bpf-obj_get_info_by_fd.c b/tests/bpf-obj_get_info_by_fd.c
|
||||
index 5096f16..96c8837 100644
|
||||
--- a/tests/bpf-obj_get_info_by_fd.c
|
||||
+++ b/tests/bpf-obj_get_info_by_fd.c
|
||||
@@ -366,6 +366,8 @@ main(void)
|
||||
|
||||
for (unsigned int i = 0; i < 4; i++) {
|
||||
prog_info->jited_prog_len = 0;
|
||||
+ prog_info->nr_jited_ksyms = 0;
|
||||
+ prog_info->nr_jited_func_lens = 0;
|
||||
switch (i) {
|
||||
case 1:
|
||||
prog_info->xlated_prog_insns =
|
||||
@@ -492,6 +494,25 @@ main(void)
|
||||
offsetof(struct bpf_prog_info_struct, netns_ino))
|
||||
printf(", netns_ino=%" PRIu64, prog_info->netns_ino);
|
||||
|
||||
+ if (bpf_prog_get_info_attr.info_len >
|
||||
+ offsetof(struct bpf_prog_info_struct, nr_jited_ksyms)) {
|
||||
+ printf(", nr_jited_ksyms=0");
|
||||
+ if (prog_info->nr_jited_ksyms)
|
||||
+ printf(" => %u", prog_info->nr_jited_ksyms);
|
||||
+ }
|
||||
+ if (bpf_prog_get_info_attr.info_len >
|
||||
+ offsetof(struct bpf_prog_info_struct, nr_jited_func_lens)) {
|
||||
+ printf(", nr_jited_func_lens=0");
|
||||
+ if (prog_info->nr_jited_func_lens)
|
||||
+ printf(" => %u", prog_info->nr_jited_func_lens);
|
||||
+ }
|
||||
+ if (bpf_prog_get_info_attr.info_len >
|
||||
+ offsetof(struct bpf_prog_info_struct, jited_ksyms))
|
||||
+ printf(", jited_ksyms=NULL");
|
||||
+ if (bpf_prog_get_info_attr.info_len >
|
||||
+ offsetof(struct bpf_prog_info_struct, jited_func_lens))
|
||||
+ printf(", jited_func_lens=NULL");
|
||||
+
|
||||
printf("}");
|
||||
# else /* !VERBOSE */
|
||||
printf("%p", prog_info);
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
108
bpf-implement-decoding-of-BPF_BTF_GET_FD_BY_ID-comma.patch
Normal file
108
bpf-implement-decoding-of-BPF_BTF_GET_FD_BY_ID-comma.patch
Normal file
@ -0,0 +1,108 @@
|
||||
From 9c183d96f7bba6c6ff0e8349241a6dd1418e8d4d Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Wed, 13 Mar 2019 18:38:51 +0000
|
||||
Subject: [PATCH 275/293] bpf: implement decoding of BPF_BTF_GET_FD_BY_ID
|
||||
command
|
||||
|
||||
BPF_BTF_GET_FD_BY_ID command was introduced by Linux commit
|
||||
v4.18-rc1~114^2~223^2~21^2~4.
|
||||
|
||||
* bpf_attr.h (struct BPF_BTF_GET_FD_BY_ID_struct): New type.
|
||||
(BPF_BTF_GET_FD_BY_ID_struct_size,
|
||||
expected_BPF_BTF_GET_FD_BY_ID_struct_size): New macros.
|
||||
* bpf.c (BEGIN_BPF_CMD_DECODER(BPF_BTF_GET_FD_BY_ID)): New bpf command
|
||||
decoder.
|
||||
(SYS_FUNC(bpf)) <bpf_cmd_decoders[]>: Add
|
||||
BPF_CMD_ENTRY(BPF_BTF_GET_FD_BY_ID).
|
||||
* tests/bpf.c (union bpf_attr_data): Add
|
||||
BPF_ATTR_DATA_FIELD(BPF_BTF_GET_FD_BY_ID).
|
||||
(BPF_BTF_GET_FD_BY_ID_checks): New checks array.
|
||||
(main) <checks>: Add CHK(BPF_BTF_GET_FD_BY_ID).
|
||||
---
|
||||
bpf.c | 7 +++++++
|
||||
bpf_attr.h | 8 ++++++++
|
||||
tests/bpf.c | 10 ++++++++++
|
||||
3 files changed, 25 insertions(+)
|
||||
|
||||
diff --git a/bpf.c b/bpf.c
|
||||
index 5fedbd1..69c9a4f 100644
|
||||
--- a/bpf.c
|
||||
+++ b/bpf.c
|
||||
@@ -837,6 +837,12 @@ BEGIN_BPF_CMD_DECODER(BPF_BTF_LOAD)
|
||||
}
|
||||
END_BPF_CMD_DECODER(RVAL_DECODED | RVAL_FD)
|
||||
|
||||
+BEGIN_BPF_CMD_DECODER(BPF_BTF_GET_FD_BY_ID)
|
||||
+{
|
||||
+ PRINT_FIELD_U("{", attr, btf_id);
|
||||
+}
|
||||
+END_BPF_CMD_DECODER(RVAL_DECODED | RVAL_FD)
|
||||
+
|
||||
SYS_FUNC(bpf)
|
||||
{
|
||||
static const bpf_cmd_decoder_t bpf_cmd_decoders[] = {
|
||||
@@ -859,6 +865,7 @@ SYS_FUNC(bpf)
|
||||
BPF_CMD_ENTRY(BPF_PROG_QUERY),
|
||||
BPF_CMD_ENTRY(BPF_RAW_TRACEPOINT_OPEN),
|
||||
BPF_CMD_ENTRY(BPF_BTF_LOAD),
|
||||
+ BPF_CMD_ENTRY(BPF_BTF_GET_FD_BY_ID),
|
||||
};
|
||||
|
||||
const unsigned int cmd = tcp->u_arg[0];
|
||||
diff --git a/bpf_attr.h b/bpf_attr.h
|
||||
index a04f79e..37ddc41 100644
|
||||
--- a/bpf_attr.h
|
||||
+++ b/bpf_attr.h
|
||||
@@ -239,6 +239,14 @@ struct BPF_BTF_LOAD_struct {
|
||||
offsetofend(struct BPF_BTF_LOAD_struct, btf_log_level)
|
||||
# define expected_BPF_BTF_LOAD_struct_size 28
|
||||
|
||||
+struct BPF_BTF_GET_FD_BY_ID_struct {
|
||||
+ uint32_t btf_id;
|
||||
+};
|
||||
+
|
||||
+# define BPF_BTF_GET_FD_BY_ID_struct_size \
|
||||
+ sizeof(struct BPF_BTF_GET_FD_BY_ID_struct)
|
||||
+# define expected_BPF_BTF_GET_FD_BY_ID_struct_size 4
|
||||
+
|
||||
struct bpf_map_info_struct {
|
||||
uint32_t type;
|
||||
uint32_t id;
|
||||
diff --git a/tests/bpf.c b/tests/bpf.c
|
||||
index 85b27d5..8f887fb 100644
|
||||
--- a/tests/bpf.c
|
||||
+++ b/tests/bpf.c
|
||||
@@ -72,6 +72,7 @@ union bpf_attr_data {
|
||||
BPF_ATTR_DATA_FIELD(BPF_PROG_QUERY);
|
||||
BPF_ATTR_DATA_FIELD(BPF_RAW_TRACEPOINT_OPEN);
|
||||
BPF_ATTR_DATA_FIELD(BPF_BTF_LOAD);
|
||||
+ BPF_ATTR_DATA_FIELD(BPF_BTF_GET_FD_BY_ID);
|
||||
char char_data[256];
|
||||
};
|
||||
|
||||
@@ -1117,6 +1118,14 @@ static struct bpf_attr_check BPF_BTF_LOAD_checks[] = {
|
||||
}
|
||||
};
|
||||
|
||||
+static const struct bpf_attr_check BPF_BTF_GET_FD_BY_ID_checks[] = {
|
||||
+ {
|
||||
+ .data = { .BPF_BTF_GET_FD_BY_ID_data = { .btf_id = 0xdeadbeef } },
|
||||
+ .size = offsetofend(struct BPF_BTF_GET_FD_BY_ID_struct, btf_id),
|
||||
+ .str = "btf_id=3735928559"
|
||||
+ }
|
||||
+};
|
||||
+
|
||||
|
||||
#define CHK(cmd_) \
|
||||
{ \
|
||||
@@ -1148,6 +1157,7 @@ main(void)
|
||||
CHK(BPF_PROG_QUERY),
|
||||
CHK(BPF_RAW_TRACEPOINT_OPEN),
|
||||
CHK(BPF_BTF_LOAD),
|
||||
+ CHK(BPF_BTF_GET_FD_BY_ID),
|
||||
};
|
||||
|
||||
page_size = get_page_size();
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
146
bpf-implement-decoding-of-BPF_BTF_LOAD-command.patch
Normal file
146
bpf-implement-decoding-of-BPF_BTF_LOAD-command.patch
Normal file
@ -0,0 +1,146 @@
|
||||
From bc4224a8fa641819d42639ac5b3252681304bfc3 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Wed, 13 Mar 2019 18:38:51 +0000
|
||||
Subject: [PATCH 274/293] bpf: implement decoding of BPF_BTF_LOAD command
|
||||
|
||||
BPF_BTF_LOAD command was introduced by Linux commit
|
||||
v4.18-rc1~114^2~417^2~1^2~5.
|
||||
|
||||
* bpf_attr.h (struct BPF_BTF_LOAD_struct): New type.
|
||||
(BPF_BTF_LOAD_struct_size, expected_BPF_BTF_LOAD_struct_size): New
|
||||
macros.
|
||||
* bpf.c (BEGIN_BPF_CMD_DECODER(BPF_BTF_LOAD)): New bpf command decoder.
|
||||
(SYS_FUNC(bpf)) <bpf_cmd_decoders[]>: Add BPF_CMD_ENTRY(BPF_BTF_LOAD).
|
||||
* tests/bpf.c (union bpf_attr_data): Add
|
||||
BPF_ATTR_DATA_FIELD(BPF_BTF_LOAD).
|
||||
(init_BPF_BTF_LOAD_attr): New function.
|
||||
(BPF_BTF_LOAD_checks): New checks array.
|
||||
(main) <checks>: Add CHK(BPF_BTF_LOAD).
|
||||
---
|
||||
bpf.c | 13 +++++++++++++
|
||||
bpf_attr.h | 12 ++++++++++++
|
||||
tests/bpf.c | 40 ++++++++++++++++++++++++++++++++++++++++
|
||||
3 files changed, 65 insertions(+)
|
||||
|
||||
diff --git a/bpf.c b/bpf.c
|
||||
index fbd77dc..5fedbd1 100644
|
||||
--- a/bpf.c
|
||||
+++ b/bpf.c
|
||||
@@ -825,6 +825,18 @@ BEGIN_BPF_CMD_DECODER(BPF_RAW_TRACEPOINT_OPEN)
|
||||
}
|
||||
END_BPF_CMD_DECODER(RVAL_DECODED)
|
||||
|
||||
+BEGIN_BPF_CMD_DECODER(BPF_BTF_LOAD)
|
||||
+{
|
||||
+ tprints("{btf=");
|
||||
+ print_big_u64_addr(attr.btf);
|
||||
+ printstrn(tcp, attr.btf, attr.btf_size);
|
||||
+ PRINT_FIELD_ADDR64(", ", attr, btf_log_buf);
|
||||
+ PRINT_FIELD_U(", ", attr, btf_size);
|
||||
+ PRINT_FIELD_U(", ", attr, btf_log_size);
|
||||
+ PRINT_FIELD_U(", ", attr, btf_log_level);
|
||||
+}
|
||||
+END_BPF_CMD_DECODER(RVAL_DECODED | RVAL_FD)
|
||||
+
|
||||
SYS_FUNC(bpf)
|
||||
{
|
||||
static const bpf_cmd_decoder_t bpf_cmd_decoders[] = {
|
||||
@@ -846,6 +858,7 @@ SYS_FUNC(bpf)
|
||||
BPF_CMD_ENTRY(BPF_OBJ_GET_INFO_BY_FD),
|
||||
BPF_CMD_ENTRY(BPF_PROG_QUERY),
|
||||
BPF_CMD_ENTRY(BPF_RAW_TRACEPOINT_OPEN),
|
||||
+ BPF_CMD_ENTRY(BPF_BTF_LOAD),
|
||||
};
|
||||
|
||||
const unsigned int cmd = tcp->u_arg[0];
|
||||
diff --git a/bpf_attr.h b/bpf_attr.h
|
||||
index b34983a..a04f79e 100644
|
||||
--- a/bpf_attr.h
|
||||
+++ b/bpf_attr.h
|
||||
@@ -227,6 +227,18 @@ struct BPF_RAW_TRACEPOINT_OPEN_struct /* raw_tracepoint */ {
|
||||
offsetofend(struct BPF_RAW_TRACEPOINT_OPEN_struct, prog_fd)
|
||||
#define expected_BPF_RAW_TRACEPOINT_OPEN_struct_size 12
|
||||
|
||||
+struct BPF_BTF_LOAD_struct {
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) btf;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) btf_log_buf;
|
||||
+ uint32_t btf_size;
|
||||
+ uint32_t btf_log_size;
|
||||
+ uint32_t btf_log_level;
|
||||
+};
|
||||
+
|
||||
+# define BPF_BTF_LOAD_struct_size \
|
||||
+ offsetofend(struct BPF_BTF_LOAD_struct, btf_log_level)
|
||||
+# define expected_BPF_BTF_LOAD_struct_size 28
|
||||
+
|
||||
struct bpf_map_info_struct {
|
||||
uint32_t type;
|
||||
uint32_t id;
|
||||
diff --git a/tests/bpf.c b/tests/bpf.c
|
||||
index b18a056..85b27d5 100644
|
||||
--- a/tests/bpf.c
|
||||
+++ b/tests/bpf.c
|
||||
@@ -71,6 +71,7 @@ union bpf_attr_data {
|
||||
BPF_ATTR_DATA_FIELD(BPF_OBJ_GET_INFO_BY_FD);
|
||||
BPF_ATTR_DATA_FIELD(BPF_PROG_QUERY);
|
||||
BPF_ATTR_DATA_FIELD(BPF_RAW_TRACEPOINT_OPEN);
|
||||
+ BPF_ATTR_DATA_FIELD(BPF_BTF_LOAD);
|
||||
char char_data[256];
|
||||
};
|
||||
|
||||
@@ -1078,6 +1079,44 @@ static struct bpf_attr_check BPF_RAW_TRACEPOINT_OPEN_checks[] = {
|
||||
}
|
||||
};
|
||||
|
||||
+static void
|
||||
+init_BPF_BTF_LOAD_attr(struct bpf_attr_check *check)
|
||||
+{
|
||||
+ static const char sample_btf_data[] = "bPf\0daTum";
|
||||
+
|
||||
+ static char *btf_data;
|
||||
+ if (!btf_data)
|
||||
+ btf_data = tail_memdup(sample_btf_data,
|
||||
+ sizeof(sample_btf_data) - 1);
|
||||
+
|
||||
+ struct BPF_BTF_LOAD_struct *attr = &check->data.BPF_BTF_LOAD_data;
|
||||
+ attr->btf = (uintptr_t) btf_data;
|
||||
+}
|
||||
+
|
||||
+static struct bpf_attr_check BPF_BTF_LOAD_checks[] = {
|
||||
+ {
|
||||
+ .data = { .BPF_BTF_LOAD_data = { .btf = 0 } },
|
||||
+ .size = offsetofend(struct BPF_BTF_LOAD_struct, btf),
|
||||
+ .str = "btf=NULL, btf_log_buf=NULL, btf_size=0"
|
||||
+ ", btf_log_size=0, btf_log_level=0"
|
||||
+ },
|
||||
+ { /* 1 */
|
||||
+ .data = { .BPF_BTF_LOAD_data = {
|
||||
+ .btf_log_buf = 0xfacefeeddeadbeefULL,
|
||||
+ .btf_size = 9,
|
||||
+ .btf_log_size = -1U,
|
||||
+ .btf_log_level = 42
|
||||
+ } },
|
||||
+ .size = offsetofend(struct BPF_BTF_LOAD_struct, btf_log_level),
|
||||
+ .init_fn = init_BPF_BTF_LOAD_attr,
|
||||
+ .str = "btf=\"bPf\\0daTum\""
|
||||
+ ", btf_log_buf=0xfacefeeddeadbeef"
|
||||
+ ", btf_size=9"
|
||||
+ ", btf_log_size=4294967295"
|
||||
+ ", btf_log_level=42"
|
||||
+ }
|
||||
+};
|
||||
+
|
||||
|
||||
#define CHK(cmd_) \
|
||||
{ \
|
||||
@@ -1108,6 +1147,7 @@ main(void)
|
||||
CHK(BPF_OBJ_GET_INFO_BY_FD),
|
||||
CHK(BPF_PROG_QUERY),
|
||||
CHK(BPF_RAW_TRACEPOINT_OPEN),
|
||||
+ CHK(BPF_BTF_LOAD),
|
||||
};
|
||||
|
||||
page_size = get_page_size();
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
191
bpf-implement-decoding-of-BPF_TASK_FD_QUERY-command.patch
Normal file
191
bpf-implement-decoding-of-BPF_TASK_FD_QUERY-command.patch
Normal file
@ -0,0 +1,191 @@
|
||||
From 4207c1115d11f40a9cb045bb61128fe49ad760e7 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Wed, 13 Mar 2019 18:38:51 +0000
|
||||
Subject: [PATCH 277/293] bpf: implement decoding of BPF_TASK_FD_QUERY command
|
||||
|
||||
BPF_TASK_FD_QUERY command was introduced by Linux commit
|
||||
v4.18-rc1~114^2~148^2~1^2~5.
|
||||
|
||||
* bpf_attr.h (struct BPF_TASK_FD_QUERY_struct): New type.
|
||||
(BPF_TASK_FD_QUERY_struct_size,
|
||||
expected_BPF_TASK_FD_QUERY_struct_size): New macros.
|
||||
* bpf.c: Include "xlat/bpf_task_fd_type.h".
|
||||
(BEGIN_BPF_CMD_DECODER(BPF_TASK_FD_QUERY)): New bpf command decoder.
|
||||
(SYS_FUNC(bpf)) <bpf_cmd_decoders[]>: Add
|
||||
BPF_CMD_ENTRY(BPF_TASK_FD_QUERY).
|
||||
* xlat/bpf_task_fd_type.in: New file.
|
||||
* tests/bpf.c (union bpf_attr_data): Add
|
||||
BPF_ATTR_DATA_FIELD(BPF_TASK_FD_QUERY).
|
||||
(BPF_TASK_FD_QUERY_checks): New checks array.
|
||||
(main) <checks>: Add CHK(BPF_TASK_FD_QUERY).
|
||||
---
|
||||
bpf.c | 34 ++++++++++++++++++++++++++++++++++
|
||||
bpf_attr.h | 16 ++++++++++++++++
|
||||
tests/bpf.c | 36 ++++++++++++++++++++++++++++++++++++
|
||||
xlat/bpf_task_fd_type.in | 7 +++++++
|
||||
4 files changed, 93 insertions(+)
|
||||
create mode 100644 xlat/bpf_task_fd_type.in
|
||||
|
||||
diff --git a/bpf.c b/bpf.c
|
||||
index 3c68957..66fae2d 100644
|
||||
--- a/bpf.c
|
||||
+++ b/bpf.c
|
||||
@@ -47,6 +47,7 @@
|
||||
#include "xlat/bpf_attach_type.h"
|
||||
#include "xlat/bpf_attach_flags.h"
|
||||
#include "xlat/bpf_query_flags.h"
|
||||
+#include "xlat/bpf_task_fd_type.h"
|
||||
#include "xlat/ebpf_regs.h"
|
||||
#include "xlat/numa_node.h"
|
||||
|
||||
@@ -778,6 +779,38 @@ BEGIN_BPF_CMD_DECODER(BPF_BTF_GET_FD_BY_ID)
|
||||
}
|
||||
END_BPF_CMD_DECODER(RVAL_DECODED | RVAL_FD)
|
||||
|
||||
+BEGIN_BPF_CMD_DECODER(BPF_TASK_FD_QUERY)
|
||||
+{
|
||||
+ if (entering(tcp)) {
|
||||
+ set_tcb_priv_ulong(tcp, attr.buf_len);
|
||||
+
|
||||
+ PRINT_FIELD_U("{task_fd_query={", attr, pid);
|
||||
+ PRINT_FIELD_FD(", ", attr, fd, tcp);
|
||||
+ PRINT_FIELD_U(", ", attr, flags);
|
||||
+ PRINT_FIELD_U(", ", attr, buf_len);
|
||||
+
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+ unsigned int saved_buf_len = get_tcb_priv_ulong(tcp);
|
||||
+
|
||||
+ if (saved_buf_len != attr.buf_len)
|
||||
+ tprintf(" => %u", attr.buf_len);
|
||||
+
|
||||
+ const unsigned int buf_len = MIN(saved_buf_len, attr.buf_len);
|
||||
+ tprintf(", buf=");
|
||||
+ print_big_u64_addr(attr.buf);
|
||||
+ printstr_ex(tcp, attr.buf, buf_len, QUOTE_0_TERMINATED);
|
||||
+ PRINT_FIELD_U(", ", attr, prog_id);
|
||||
+ PRINT_FIELD_XVAL_INDEX(", ", attr, fd_type, bpf_task_fd_type,
|
||||
+ "BPF_FD_TYPE_???");
|
||||
+ PRINT_FIELD_X(", ", attr, probe_offset);
|
||||
+ PRINT_FIELD_X(", ", attr, probe_addr);
|
||||
+
|
||||
+ tprints("}");
|
||||
+}
|
||||
+END_BPF_CMD_DECODER(RVAL_DECODED)
|
||||
+
|
||||
SYS_FUNC(bpf)
|
||||
{
|
||||
static const bpf_cmd_decoder_t bpf_cmd_decoders[] = {
|
||||
@@ -801,6 +834,7 @@ SYS_FUNC(bpf)
|
||||
BPF_CMD_ENTRY(BPF_RAW_TRACEPOINT_OPEN),
|
||||
BPF_CMD_ENTRY(BPF_BTF_LOAD),
|
||||
BPF_CMD_ENTRY(BPF_BTF_GET_FD_BY_ID),
|
||||
+ BPF_CMD_ENTRY(BPF_TASK_FD_QUERY),
|
||||
};
|
||||
|
||||
const unsigned int cmd = tcp->u_arg[0];
|
||||
diff --git a/bpf_attr.h b/bpf_attr.h
|
||||
index 584aa75..750198b 100644
|
||||
--- a/bpf_attr.h
|
||||
+++ b/bpf_attr.h
|
||||
@@ -267,6 +267,22 @@ struct BPF_BTF_GET_FD_BY_ID_struct {
|
||||
sizeof(struct BPF_BTF_GET_FD_BY_ID_struct)
|
||||
# define expected_BPF_BTF_GET_FD_BY_ID_struct_size 4
|
||||
|
||||
+struct BPF_TASK_FD_QUERY_struct /* task_fd_query */ {
|
||||
+ uint32_t pid;
|
||||
+ uint32_t fd;
|
||||
+ uint32_t flags;
|
||||
+ uint32_t buf_len;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) buf;
|
||||
+ uint32_t prog_id;
|
||||
+ uint32_t fd_type;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) probe_offset;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) probe_addr;
|
||||
+};
|
||||
+
|
||||
+# define BPF_TASK_FD_QUERY_struct_size \
|
||||
+ sizeof(struct BPF_TASK_FD_QUERY_struct)
|
||||
+# define expected_BPF_TASK_FD_QUERY_struct_size 48
|
||||
+
|
||||
struct bpf_map_info_struct {
|
||||
uint32_t type;
|
||||
uint32_t id;
|
||||
diff --git a/tests/bpf.c b/tests/bpf.c
|
||||
index 3f707e4..c1ec568 100644
|
||||
--- a/tests/bpf.c
|
||||
+++ b/tests/bpf.c
|
||||
@@ -93,6 +93,7 @@ union bpf_attr_data {
|
||||
BPF_ATTR_DATA_FIELD(BPF_RAW_TRACEPOINT_OPEN);
|
||||
BPF_ATTR_DATA_FIELD(BPF_BTF_LOAD);
|
||||
BPF_ATTR_DATA_FIELD(BPF_BTF_GET_FD_BY_ID);
|
||||
+ BPF_ATTR_DATA_FIELD(BPF_TASK_FD_QUERY);
|
||||
char char_data[256];
|
||||
};
|
||||
|
||||
@@ -1146,6 +1147,40 @@ static const struct bpf_attr_check BPF_BTF_GET_FD_BY_ID_checks[] = {
|
||||
}
|
||||
};
|
||||
|
||||
+static const struct bpf_attr_check BPF_TASK_FD_QUERY_checks[] = {
|
||||
+ {
|
||||
+ .data = { .BPF_TASK_FD_QUERY_data = { .pid = 0xdeadbeef } },
|
||||
+ .size = offsetofend(struct BPF_TASK_FD_QUERY_struct, pid),
|
||||
+ .str = "task_fd_query={pid=3735928559, fd=0, flags=0"
|
||||
+ ", buf_len=0, buf=NULL, prog_id=0"
|
||||
+ ", fd_type=BPF_FD_TYPE_RAW_TRACEPOINT"
|
||||
+ ", probe_offset=0, probe_addr=0}"
|
||||
+ },
|
||||
+ { /* 1 */
|
||||
+ .data = { .BPF_TASK_FD_QUERY_data = {
|
||||
+ .pid = 0xcafef00d,
|
||||
+ .fd = 0xdeadbeef,
|
||||
+ .flags = 0xfacefeed,
|
||||
+ .buf_len = 0xdefaced,
|
||||
+ .buf = 0xfffffffffffffffe,
|
||||
+ .prog_id = 0xbadc0ded,
|
||||
+ .fd_type = 5,
|
||||
+ .probe_offset = 0xfac1fed2fac3fed4,
|
||||
+ .probe_addr = 0xfac5fed5fac7fed8
|
||||
+ } },
|
||||
+ .size = offsetofend(struct BPF_TASK_FD_QUERY_struct, probe_addr),
|
||||
+ .str = "task_fd_query={pid=3405705229"
|
||||
+ ", fd=-559038737"
|
||||
+ ", flags=4207869677"
|
||||
+ ", buf_len=233811181"
|
||||
+ ", buf=" BIG_ADDR("0xfffffffffffffffe", "0xfffffffe")
|
||||
+ ", prog_id=3134983661"
|
||||
+ ", fd_type=BPF_FD_TYPE_URETPROBE"
|
||||
+ ", probe_offset=0xfac1fed2fac3fed4"
|
||||
+ ", probe_addr=0xfac5fed5fac7fed8}"
|
||||
+ }
|
||||
+};
|
||||
+
|
||||
|
||||
#define CHK(cmd_) \
|
||||
{ \
|
||||
@@ -1178,6 +1213,7 @@ main(void)
|
||||
CHK(BPF_RAW_TRACEPOINT_OPEN),
|
||||
CHK(BPF_BTF_LOAD),
|
||||
CHK(BPF_BTF_GET_FD_BY_ID),
|
||||
+ CHK(BPF_TASK_FD_QUERY),
|
||||
};
|
||||
|
||||
page_size = get_page_size();
|
||||
diff --git a/xlat/bpf_task_fd_type.in b/xlat/bpf_task_fd_type.in
|
||||
new file mode 100644
|
||||
index 0000000..df554e6
|
||||
--- /dev/null
|
||||
+++ b/xlat/bpf_task_fd_type.in
|
||||
@@ -0,0 +1,7 @@
|
||||
+#value_indexed
|
||||
+BPF_FD_TYPE_RAW_TRACEPOINT 0
|
||||
+BPF_FD_TYPE_TRACEPOINT 1
|
||||
+BPF_FD_TYPE_KPROBE 2
|
||||
+BPF_FD_TYPE_KRETPROBE 3
|
||||
+BPF_FD_TYPE_UPROBE 4
|
||||
+BPF_FD_TYPE_URETPROBE 5
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
65
bpf-print-struct-bpf_prog_info.gpl_compatible.patch
Normal file
65
bpf-print-struct-bpf_prog_info.gpl_compatible.patch
Normal file
@ -0,0 +1,65 @@
|
||||
From cabd6955d3c3048bb2ba19032b504eeb3776a86f Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Tue, 12 Mar 2019 11:17:20 +0000
|
||||
Subject: [PATCH 268/293] bpf: print struct bpf_prog_info.gpl_compatible
|
||||
|
||||
This bit field was added by Linux commit v4.18-rc1~114^2~376^2~6.
|
||||
|
||||
* bpf_attr.h (struct bpf_prog_info_struct): Add gpl_compatible field.
|
||||
* bpf.c (print_bpf_prog_info): Print gpl_compatible field.
|
||||
* tests/bpf-obj_get_info_by_fd.c (main): Update expected output.
|
||||
---
|
||||
bpf.c | 5 ++++-
|
||||
bpf_attr.h | 1 +
|
||||
tests/bpf-obj_get_info_by_fd.c | 3 +++
|
||||
3 files changed, 8 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bpf.c b/bpf.c
|
||||
index 397521e..6fb4c2c 100644
|
||||
--- a/bpf.c
|
||||
+++ b/bpf.c
|
||||
@@ -525,11 +525,14 @@ print_bpf_prog_info(struct tcb * const tcp, uint32_t bpf_fd,
|
||||
|
||||
/*
|
||||
* ifindex, netns_dev, and netns_ino fields were introduced
|
||||
- * by Linux commit v4.16-rc1~123^2~227^2~5^2~2.
|
||||
+ * by Linux commit v4.16-rc1~123^2~227^2~5^2~2, and
|
||||
+ * gpl_compatible was added later by Linux commit
|
||||
+ * v4.18-rc1~114^2~376^2~6.
|
||||
*/
|
||||
if (len <= offsetof(struct bpf_prog_info_struct, ifindex))
|
||||
goto print_bpf_prog_info_end;
|
||||
PRINT_FIELD_IFINDEX(", ", info, ifindex);
|
||||
+ tprintf(", gpl_compatible=%u", info.gpl_compatible);
|
||||
PRINT_FIELD_DEV(", ", info, netns_dev);
|
||||
PRINT_FIELD_U(", ", info, netns_ino);
|
||||
|
||||
diff --git a/bpf_attr.h b/bpf_attr.h
|
||||
index dc7694c..cb49896 100644
|
||||
--- a/bpf_attr.h
|
||||
+++ b/bpf_attr.h
|
||||
@@ -259,6 +259,7 @@ struct bpf_prog_info_struct {
|
||||
uint64_t ATTRIBUTE_ALIGNED(8) map_ids;
|
||||
char name[BPF_OBJ_NAME_LEN];
|
||||
uint32_t ifindex;
|
||||
+ uint32_t gpl_compatible:1;
|
||||
/*
|
||||
* The kernel UAPI is broken by Linux commit
|
||||
* v4.16-rc1~123^2~227^2~5^2~2 .
|
||||
diff --git a/tests/bpf-obj_get_info_by_fd.c b/tests/bpf-obj_get_info_by_fd.c
|
||||
index fba0e75..ff06e27 100644
|
||||
--- a/tests/bpf-obj_get_info_by_fd.c
|
||||
+++ b/tests/bpf-obj_get_info_by_fd.c
|
||||
@@ -461,6 +461,9 @@ main(void)
|
||||
offsetof(struct bpf_prog_info_struct, ifindex))
|
||||
printf(", ifindex=%u", prog_info->ifindex);
|
||||
if (bpf_prog_get_info_attr.info_len >
|
||||
+ offsetofend(struct bpf_prog_info_struct, ifindex))
|
||||
+ printf(", gpl_compatible=%u", prog_info->gpl_compatible);
|
||||
+ if (bpf_prog_get_info_attr.info_len >
|
||||
offsetof(struct bpf_prog_info_struct, netns_dev))
|
||||
printf(", netns_dev=makedev(%u, %u)",
|
||||
major(prog_info->netns_dev),
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
129
evdev-fix-decoding-of-EVIOCGBIT-0.patch
Normal file
129
evdev-fix-decoding-of-EVIOCGBIT-0.patch
Normal file
@ -0,0 +1,129 @@
|
||||
From 5ee385e2eb9288ae49e07dca67e576abb2e10fea Mon Sep 17 00:00:00 2001
|
||||
From: Zhibin Li <08826794brmt@gmail.com>
|
||||
Date: Wed, 1 Aug 2018 17:53:57 +0800
|
||||
Subject: [PATCH 006/293] evdev: fix decoding of EVIOCGBIT(0, ...)
|
||||
|
||||
There is a comment in drivers/input/evdev.c which says:
|
||||
/* EV_SYN==0 is EV_CNT, _not_ SYN_CNT, see EVIOCGBIT */
|
||||
|
||||
That is, EVIOCGBIT(0, ...) should return a bit mask with supported
|
||||
event types instead of SYN_* event codes.
|
||||
|
||||
* defs.h (evdev_ev): New prototype.
|
||||
* evdev.c: Include "xlat/evdev_ev.h" and remove "xlat/evdev_sync.h".
|
||||
(bit_ioctl) <case EV_SYN>: Replace EV_SYN with 0, use evdev_ev
|
||||
with XT_SORTED in decode_bitset invocation instead.
|
||||
* ioctl.c: Do not include "xlat/evdev_ev.h".
|
||||
(evdev_decode_number): Print nr == 0x20 as "0" instead of "EV_SYN".
|
||||
* tests/ioctl_evdev.c (main): Use 0 instead of EV_SYN in EVIOCGBIT
|
||||
output.
|
||||
* xlat/evdev_sync.in: Remove.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
Fixes: v4.10~89 "Add decoding for evdev ioctls"
|
||||
---
|
||||
defs.h | 1 +
|
||||
evdev.c | 8 ++++----
|
||||
ioctl.c | 7 ++++---
|
||||
tests/ioctl_evdev.c | 2 +-
|
||||
xlat/evdev_sync.in | 5 -----
|
||||
5 files changed, 10 insertions(+), 13 deletions(-)
|
||||
delete mode 100644 xlat/evdev_sync.in
|
||||
|
||||
diff --git a/defs.h b/defs.h
|
||||
index 0d4bf82..2c19dd3 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -330,6 +330,7 @@ extern const struct xlat evdev_abs[];
|
||||
/** Number of elements in evdev_abs array without the terminating record. */
|
||||
extern const size_t evdev_abs_size;
|
||||
|
||||
+extern const struct xlat evdev_ev[];
|
||||
extern const struct xlat iffflags[];
|
||||
extern const struct xlat ip_type_of_services[];
|
||||
extern const struct xlat ipc_private[];
|
||||
diff --git a/evdev.c b/evdev.c
|
||||
index 3c1aaa8..cae2ef1 100644
|
||||
--- a/evdev.c
|
||||
+++ b/evdev.c
|
||||
@@ -30,6 +30,7 @@
|
||||
#include "defs.h"
|
||||
|
||||
#include "xlat/evdev_abs.h"
|
||||
+#include "xlat/evdev_ev.h"
|
||||
|
||||
#ifdef HAVE_LINUX_INPUT_H
|
||||
|
||||
@@ -47,7 +48,6 @@
|
||||
# include "xlat/evdev_relative_axes.h"
|
||||
# include "xlat/evdev_snd.h"
|
||||
# include "xlat/evdev_switch.h"
|
||||
-# include "xlat/evdev_sync.h"
|
||||
|
||||
# ifndef SYN_MAX
|
||||
# define SYN_MAX 0xf
|
||||
@@ -258,9 +258,9 @@ bit_ioctl(struct tcb *const tcp, const unsigned int ev_nr,
|
||||
const kernel_ulong_t arg)
|
||||
{
|
||||
switch (ev_nr) {
|
||||
- case EV_SYN:
|
||||
- return decode_bitset(tcp, arg, evdev_sync,
|
||||
- SYN_MAX, "SYN_???", XT_INDEXED);
|
||||
+ case 0:
|
||||
+ return decode_bitset(tcp, arg, evdev_ev,
|
||||
+ EV_MAX, "EV_???", XT_SORTED);
|
||||
case EV_KEY:
|
||||
return decode_bitset(tcp, arg, evdev_keycode,
|
||||
KEY_MAX, "KEY_???", XT_INDEXED);
|
||||
diff --git a/ioctl.c b/ioctl.c
|
||||
index 93fb526..66b10ec 100644
|
||||
--- a/ioctl.c
|
||||
+++ b/ioctl.c
|
||||
@@ -33,8 +33,6 @@
|
||||
#include <linux/ioctl.h>
|
||||
#include "xlat/ioctl_dirs.h"
|
||||
|
||||
-#include "xlat/evdev_ev.h"
|
||||
-
|
||||
static int
|
||||
compare(const void *a, const void *b)
|
||||
{
|
||||
@@ -99,7 +97,10 @@ evdev_decode_number(const unsigned int code)
|
||||
|
||||
if (nr >= 0x20 && nr <= 0x20 + 0x1f) {
|
||||
tprints("EVIOCGBIT(");
|
||||
- printxval(evdev_ev, nr - 0x20, "EV_???");
|
||||
+ if (nr == 0x20)
|
||||
+ tprintf("0");
|
||||
+ else
|
||||
+ printxval(evdev_ev, nr - 0x20, "EV_???");
|
||||
tprintf(", %u)", _IOC_SIZE(code));
|
||||
return 1;
|
||||
} else if (nr >= 0x40 && nr <= 0x40 + 0x3f) {
|
||||
diff --git a/tests/ioctl_evdev.c b/tests/ioctl_evdev.c
|
||||
index 5eacac0..071b6b0 100644
|
||||
--- a/tests/ioctl_evdev.c
|
||||
+++ b/tests/ioctl_evdev.c
|
||||
@@ -138,7 +138,7 @@ main(void)
|
||||
TEST_NULL_ARG_EX(EVIOCGABS(0x3f), "EVIOCGABS(0x3f /* ABS_??? */)");
|
||||
TEST_NULL_ARG_EX(EVIOCSABS(0x3f), "EVIOCSABS(0x3f /* ABS_??? */)");
|
||||
|
||||
- TEST_NULL_ARG(EVIOCGBIT(EV_SYN, 0));
|
||||
+ TEST_NULL_ARG(EVIOCGBIT(0, 0));
|
||||
TEST_NULL_ARG(EVIOCGBIT(EV_KEY, 1));
|
||||
TEST_NULL_ARG(EVIOCGBIT(EV_REL, 2));
|
||||
TEST_NULL_ARG(EVIOCGBIT(EV_ABS, 3));
|
||||
diff --git a/xlat/evdev_sync.in b/xlat/evdev_sync.in
|
||||
deleted file mode 100644
|
||||
index ca9ea50..0000000
|
||||
--- a/xlat/evdev_sync.in
|
||||
+++ /dev/null
|
||||
@@ -1,5 +0,0 @@
|
||||
-#value_indexed
|
||||
-SYN_REPORT 0
|
||||
-SYN_CONFIG 1
|
||||
-SYN_MT_REPORT 2
|
||||
-SYN_DROPPED 3
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
37
evdev-fix-decoding-of-bit-sets.patch
Normal file
37
evdev-fix-decoding-of-bit-sets.patch
Normal file
@ -0,0 +1,37 @@
|
||||
From 99300f217b7870fcaa752e1350a33cf98d61a993 Mon Sep 17 00:00:00 2001
|
||||
From: Zhibin Li <08826794brmt@gmail.com>
|
||||
Date: Wed, 1 Aug 2018 17:53:57 +0800
|
||||
Subject: [PATCH 005/293] evdev: fix decoding of bit sets
|
||||
|
||||
According to drivers/input/evdev.c:bits_to_user(),
|
||||
the Linux kernel returns the number of bytes, not bits.
|
||||
|
||||
* evdev.c (decode_bitset_): Treat syscall return value as the number
|
||||
of bytes.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
Fixes: v4.10~89 "Add decoding for evdev ioctls"
|
||||
---
|
||||
evdev.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/evdev.c b/evdev.c
|
||||
index 7ca15c9..3c1aaa8 100644
|
||||
--- a/evdev.c
|
||||
+++ b/evdev.c
|
||||
@@ -171,10 +171,10 @@ decode_bitset_(struct tcb *const tcp, const kernel_ulong_t arg,
|
||||
tprints(", ");
|
||||
|
||||
unsigned int size;
|
||||
- if ((kernel_ulong_t) tcp->u_rval > max_nr)
|
||||
+ if ((kernel_ulong_t) tcp->u_rval > max_nr / 8)
|
||||
size = max_nr;
|
||||
else
|
||||
- size = tcp->u_rval;
|
||||
+ size = tcp->u_rval * 8;
|
||||
char decoded_arg[size];
|
||||
|
||||
if (umove_or_printaddr(tcp, arg, &decoded_arg))
|
||||
--
|
||||
17.12.4
|
||||
|
||||
89
futex-recognise-FUTEX_BITSET_MATCH_ANY-bitmask.patch
Normal file
89
futex-recognise-FUTEX_BITSET_MATCH_ANY-bitmask.patch
Normal file
@ -0,0 +1,89 @@
|
||||
From c3ac40611c339ff0a80598a1f0bf5ab3d2120d99 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Wed, 29 Aug 2018 22:18:36 +0200
|
||||
Subject: [PATCH 065/293] futex: recognise FUTEX_BITSET_MATCH_ANY bitmask
|
||||
|
||||
* xlat/futexbitset.in: New file.
|
||||
* futex.c: Include "xlat/futexbitset.h".
|
||||
(futex) <FUTEX_WAIT_BITSET, FUTEX_WAKE_BITSET>: Decode val3 using
|
||||
futexbitset xlat.
|
||||
* tests/futex.c: Add checks for 0xffffffff bitset mask printing.
|
||||
|
||||
Closes: Linux commit v4.16-rc1~166^2^2~2
|
||||
---
|
||||
futex.c | 7 +++++--
|
||||
tests/futex.c | 16 ++++++++++++++++
|
||||
2 files changed, 21 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/futex.c b/futex.c
|
||||
index 9ce4ced..e4dfa08 100644
|
||||
--- a/futex.c
|
||||
+++ b/futex.c
|
||||
@@ -41,6 +41,7 @@
|
||||
# define FUTEX_OP_OPARG_SHIFT 8
|
||||
#endif
|
||||
|
||||
+#include "xlat/futexbitset.h"
|
||||
#include "xlat/futexops.h"
|
||||
#include "xlat/futexwakeops.h"
|
||||
#include "xlat/futexwakecmps.h"
|
||||
@@ -74,11 +75,13 @@ SYS_FUNC(futex)
|
||||
tprintf(", %u", val);
|
||||
tprints(", ");
|
||||
print_timespec(tcp, timeout);
|
||||
- tprintf(", %#x", val3);
|
||||
+ tprints(", ");
|
||||
+ printxval(futexbitset, val3, NULL);
|
||||
break;
|
||||
case FUTEX_WAKE_BITSET:
|
||||
tprintf(", %u", val);
|
||||
- tprintf(", %#x", val3);
|
||||
+ tprints(", ");
|
||||
+ printxval(futexbitset, val3, NULL);
|
||||
break;
|
||||
case FUTEX_REQUEUE:
|
||||
tprintf(", %u", val);
|
||||
diff --git a/tests/futex.c b/tests/futex.c
|
||||
index 174100f..5250d60 100644
|
||||
--- a/tests/futex.c
|
||||
+++ b/tests/futex.c
|
||||
@@ -166,6 +166,9 @@ void invalid_op(int *val, int op, uint32_t argmask, ...)
|
||||
# define VAL3 ((unsigned long) 0xbadda7a09caffee1LLU)
|
||||
# define VAL3_PR ((unsigned) VAL3)
|
||||
|
||||
+# define VAL3A ((unsigned long) 0xbadda7a0ffffffffLLU)
|
||||
+# define VAL3A_PR "FUTEX_BITSET_MATCH_ANY"
|
||||
+
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
@@ -288,6 +291,14 @@ main(int argc, char *argv[])
|
||||
zero_extend_signed_to_ull(tmout->tv_nsec), VAL3_PR,
|
||||
sprintrc(rc));
|
||||
|
||||
+ CHECK_FUTEX_ENOSYS(uaddr, FUTEX_WAIT_BITSET, VAL, tmout, uaddr2 + 1,
|
||||
+ VAL3A, (rc == -1) && (errno == EAGAIN));
|
||||
+ printf("futex(%p, FUTEX_WAIT_BITSET, %u, {tv_sec=%lld, tv_nsec=%llu}"
|
||||
+ ", %s) = %s\n",
|
||||
+ uaddr, VAL_PR, (long long) tmout->tv_sec,
|
||||
+ zero_extend_signed_to_ull(tmout->tv_nsec), VAL3A_PR,
|
||||
+ sprintrc(rc));
|
||||
+
|
||||
/* val3 of 0 is invalid */
|
||||
CHECK_FUTEX_ENOSYS(uaddr, FUTEX_WAIT_BITSET, VAL, tmout, uaddr2 + 1, 0,
|
||||
(rc == -1) && (errno == EINVAL));
|
||||
@@ -375,6 +386,11 @@ main(int argc, char *argv[])
|
||||
printf("futex(%p, FUTEX_WAKE_BITSET, %u, %#x) = %s\n", uaddr, 10,
|
||||
VAL3_PR, sprintrc(rc));
|
||||
|
||||
+ CHECK_FUTEX_ENOSYS(uaddr, FUTEX_WAKE_BITSET, 10, NULL, NULL,
|
||||
+ VAL3A, (rc == 0));
|
||||
+ printf("futex(%p, FUTEX_WAKE_BITSET, %u, %s) = %s\n", uaddr, 10,
|
||||
+ VAL3A_PR, sprintrc(rc));
|
||||
+
|
||||
/* bitset 0 is invalid */
|
||||
CHECK_FUTEX_ENOSYS(uaddr, FUTEX_WAKE_BITSET, 10, NULL, NULL, 0,
|
||||
(rc == -1) && (errno == EINVAL));
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
69
ioprio-move-constant-definitions-to-xlat.patch
Normal file
69
ioprio-move-constant-definitions-to-xlat.patch
Normal file
@ -0,0 +1,69 @@
|
||||
From 8a56b8a1b7c2f49ed90d152a1ff765214016c95a Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 21:26:04 +0200
|
||||
Subject: [PATCH 064/293] ioprio: move constant definitions to xlat
|
||||
|
||||
* xlat/ioprio_class.in: Add fallback values.
|
||||
* xlat/ioprio_who.in: Likewise.
|
||||
* ioprio.c: Remove IOPRIO_WHO_* and IOPRIO_CLASS_* enums.
|
||||
---
|
||||
ioprio.c | 14 --------------
|
||||
xlat/ioprio_class.in | 9 ++++-----
|
||||
xlat/ioprio_who.in | 7 +++----
|
||||
3 files changed, 7 insertions(+), 23 deletions(-)
|
||||
|
||||
diff --git a/ioprio.c b/ioprio.c
|
||||
index 19ea74c..a9d4288 100644
|
||||
--- a/ioprio.c
|
||||
+++ b/ioprio.c
|
||||
@@ -29,21 +29,7 @@
|
||||
#include "defs.h"
|
||||
#include "xstring.h"
|
||||
|
||||
-enum {
|
||||
- IOPRIO_WHO_PROCESS = 1,
|
||||
- IOPRIO_WHO_PGRP,
|
||||
- IOPRIO_WHO_USER
|
||||
-};
|
||||
-
|
||||
#include "xlat/ioprio_who.h"
|
||||
-
|
||||
-enum {
|
||||
- IOPRIO_CLASS_NONE,
|
||||
- IOPRIO_CLASS_RT,
|
||||
- IOPRIO_CLASS_BE,
|
||||
- IOPRIO_CLASS_IDLE
|
||||
-};
|
||||
-
|
||||
#include "xlat/ioprio_class.h"
|
||||
|
||||
#define IOPRIO_CLASS_SHIFT (13)
|
||||
diff --git a/xlat/ioprio_class.in b/xlat/ioprio_class.in
|
||||
index 5020e5a..f7a3ed2 100644
|
||||
--- a/xlat/ioprio_class.in
|
||||
+++ b/xlat/ioprio_class.in
|
||||
@@ -1,5 +1,4 @@
|
||||
-#unconditional
|
||||
-IOPRIO_CLASS_NONE
|
||||
-IOPRIO_CLASS_RT
|
||||
-IOPRIO_CLASS_BE
|
||||
-IOPRIO_CLASS_IDLE
|
||||
+IOPRIO_CLASS_NONE 0
|
||||
+IOPRIO_CLASS_RT 1
|
||||
+IOPRIO_CLASS_BE 2
|
||||
+IOPRIO_CLASS_IDLE 3
|
||||
diff --git a/xlat/ioprio_who.in b/xlat/ioprio_who.in
|
||||
index 20b1bd1..dfb967c 100644
|
||||
--- a/xlat/ioprio_who.in
|
||||
+++ b/xlat/ioprio_who.in
|
||||
@@ -1,4 +1,3 @@
|
||||
-#unconditional
|
||||
-IOPRIO_WHO_PROCESS
|
||||
-IOPRIO_WHO_PGRP
|
||||
-IOPRIO_WHO_USER
|
||||
+IOPRIO_WHO_PROCESS 1
|
||||
+IOPRIO_WHO_PGRP 2
|
||||
+IOPRIO_WHO_USER 3
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
234
kvm-decode-the-argument-of-KVM_CHECK_EXTENSION.patch
Normal file
234
kvm-decode-the-argument-of-KVM_CHECK_EXTENSION.patch
Normal file
@ -0,0 +1,234 @@
|
||||
From e38143b00e8b03462ec66c8d0bd6f9413f10656d Mon Sep 17 00:00:00 2001
|
||||
From: Pierre Marsais <pierre.marsais@lse.epita.fr>
|
||||
Date: Thu, 16 Aug 2018 20:04:41 +0100
|
||||
Subject: [PATCH 004/293] kvm: decode the argument of KVM_CHECK_EXTENSION
|
||||
|
||||
xlat/kvm_cap.in has been generated using the following command line:
|
||||
|
||||
grep '#define\s\+KVM_CAP' $linux/include/uapi/linux/kvm.h |
|
||||
sed -E -e 's/^#define\s+([^ \t]+)\s*([0-9]+).*$/printf "%-40s%s\n" \1 \2/e' \
|
||||
-e 's/ {8}/\t/g; s/ +/\t/g'
|
||||
|
||||
* xlat/kvm_cap.in: New file.
|
||||
* kvm.c: Include "xlat/kvm_cap.h".
|
||||
(kvm_ioctl_decode_check_extension): New function.
|
||||
(kvm_ioctl): Use it.
|
||||
* tests/ioctl_kvm_run_common.c (main): Check decoding
|
||||
of KVM_CHECK_EXTENSION command.
|
||||
|
||||
Signed-off-by: Pierre Marsais <pierre.marsais@lse.epita.fr>
|
||||
---
|
||||
kvm.c | 13 ++++
|
||||
tests/ioctl_kvm_run_common.c | 5 ++
|
||||
xlat/kvm_cap.in | 152 +++++++++++++++++++++++++++++++++++++++++++
|
||||
3 files changed, 170 insertions(+)
|
||||
create mode 100644 xlat/kvm_cap.in
|
||||
|
||||
diff --git a/kvm.c b/kvm.c
|
||||
index c284e83..36c6404 100644
|
||||
--- a/kvm.c
|
||||
+++ b/kvm.c
|
||||
@@ -323,6 +323,16 @@ kvm_ioctl_decode_sregs(struct tcb *const tcp, const unsigned int code,
|
||||
}
|
||||
# endif /* HAVE_STRUCT_KVM_SREGS */
|
||||
|
||||
+# include "xlat/kvm_cap.h"
|
||||
+static int
|
||||
+kvm_ioctl_decode_check_extension(struct tcb *const tcp, const unsigned int code,
|
||||
+ const kernel_ulong_t arg)
|
||||
+{
|
||||
+ tprints(", ");
|
||||
+ printxval_index(kvm_cap, arg, "KVM_CAP_???");
|
||||
+ return RVAL_IOCTL_DECODED;
|
||||
+}
|
||||
+
|
||||
# include "xlat/kvm_exit_reason.h"
|
||||
static void
|
||||
kvm_ioctl_run_attach_auxstr(struct tcb *const tcp,
|
||||
@@ -403,6 +413,9 @@ kvm_ioctl(struct tcb *const tcp, const unsigned int code, const kernel_ulong_t a
|
||||
return kvm_ioctl_decode_cpuid2(tcp, code, arg);
|
||||
# endif
|
||||
|
||||
+ case KVM_CHECK_EXTENSION:
|
||||
+ return kvm_ioctl_decode_check_extension(tcp, code, arg);
|
||||
+
|
||||
case KVM_CREATE_VM:
|
||||
return RVAL_DECODED | RVAL_FD;
|
||||
|
||||
diff --git a/tests/ioctl_kvm_run_common.c b/tests/ioctl_kvm_run_common.c
|
||||
index 522935a..2e7eda4 100644
|
||||
--- a/tests/ioctl_kvm_run_common.c
|
||||
+++ b/tests/ioctl_kvm_run_common.c
|
||||
@@ -306,6 +306,11 @@ main(void)
|
||||
printf("ioctl(%d<%s>, KVM_GET_API_VERSION, 0) = %d\n",
|
||||
kvm, dev, ret);
|
||||
|
||||
+ ret = KVM_IOCTL(kvm, KVM_CHECK_EXTENSION,
|
||||
+ (void *) (uintptr_t) KVM_CAP_USER_MEMORY);
|
||||
+ printf("ioctl(%d<%s>, KVM_CHECK_EXTENSION, KVM_CAP_USER_MEMORY) = %d\n",
|
||||
+ kvm, dev, ret);
|
||||
+
|
||||
int vm_fd = KVM_IOCTL(kvm, KVM_CREATE_VM, 0);
|
||||
printf("ioctl(%d<%s>, KVM_CREATE_VM, 0) = %d<%s>\n",
|
||||
kvm, dev, vm_fd, vm_dev);
|
||||
diff --git a/xlat/kvm_cap.in b/xlat/kvm_cap.in
|
||||
new file mode 100644
|
||||
index 0000000..a3819e7
|
||||
--- /dev/null
|
||||
+++ b/xlat/kvm_cap.in
|
||||
@@ -0,0 +1,152 @@
|
||||
+#value_indexed
|
||||
+KVM_CAP_IRQCHIP 0
|
||||
+KVM_CAP_HLT 1
|
||||
+KVM_CAP_MMU_SHADOW_CACHE_CONTROL 2
|
||||
+KVM_CAP_USER_MEMORY 3
|
||||
+KVM_CAP_SET_TSS_ADDR 4
|
||||
+KVM_CAP_VAPIC 6
|
||||
+KVM_CAP_EXT_CPUID 7
|
||||
+KVM_CAP_CLOCKSOURCE 8
|
||||
+KVM_CAP_NR_VCPUS 9
|
||||
+KVM_CAP_NR_MEMSLOTS 10
|
||||
+KVM_CAP_PIT 11
|
||||
+KVM_CAP_NOP_IO_DELAY 12
|
||||
+KVM_CAP_PV_MMU 13
|
||||
+KVM_CAP_MP_STATE 14
|
||||
+KVM_CAP_COALESCED_MMIO 15
|
||||
+KVM_CAP_SYNC_MMU 16
|
||||
+KVM_CAP_IOMMU 18
|
||||
+KVM_CAP_DESTROY_MEMORY_REGION_WORKS 21
|
||||
+KVM_CAP_USER_NMI 22
|
||||
+KVM_CAP_SET_GUEST_DEBUG 23
|
||||
+KVM_CAP_REINJECT_CONTROL 24
|
||||
+KVM_CAP_IRQ_ROUTING 25
|
||||
+KVM_CAP_IRQ_INJECT_STATUS 26
|
||||
+KVM_CAP_ASSIGN_DEV_IRQ 29
|
||||
+KVM_CAP_JOIN_MEMORY_REGIONS_WORKS 30
|
||||
+KVM_CAP_MCE 31
|
||||
+KVM_CAP_IRQFD 32
|
||||
+KVM_CAP_PIT2 33
|
||||
+KVM_CAP_SET_BOOT_CPU_ID 34
|
||||
+KVM_CAP_PIT_STATE2 35
|
||||
+KVM_CAP_IOEVENTFD 36
|
||||
+KVM_CAP_SET_IDENTITY_MAP_ADDR 37
|
||||
+KVM_CAP_XEN_HVM 38
|
||||
+KVM_CAP_ADJUST_CLOCK 39
|
||||
+KVM_CAP_INTERNAL_ERROR_DATA 40
|
||||
+KVM_CAP_VCPU_EVENTS 41
|
||||
+KVM_CAP_S390_PSW 42
|
||||
+KVM_CAP_PPC_SEGSTATE 43
|
||||
+KVM_CAP_HYPERV 44
|
||||
+KVM_CAP_HYPERV_VAPIC 45
|
||||
+KVM_CAP_HYPERV_SPIN 46
|
||||
+KVM_CAP_PCI_SEGMENT 47
|
||||
+KVM_CAP_PPC_PAIRED_SINGLES 48
|
||||
+KVM_CAP_INTR_SHADOW 49
|
||||
+KVM_CAP_DEBUGREGS 50
|
||||
+KVM_CAP_X86_ROBUST_SINGLESTEP 51
|
||||
+KVM_CAP_PPC_OSI 52
|
||||
+KVM_CAP_PPC_UNSET_IRQ 53
|
||||
+KVM_CAP_ENABLE_CAP 54
|
||||
+KVM_CAP_XSAVE 55
|
||||
+KVM_CAP_XCRS 56
|
||||
+KVM_CAP_PPC_GET_PVINFO 57
|
||||
+KVM_CAP_PPC_IRQ_LEVEL 58
|
||||
+KVM_CAP_ASYNC_PF 59
|
||||
+KVM_CAP_TSC_CONTROL 60
|
||||
+KVM_CAP_GET_TSC_KHZ 61
|
||||
+KVM_CAP_PPC_BOOKE_SREGS 62
|
||||
+KVM_CAP_SPAPR_TCE 63
|
||||
+KVM_CAP_PPC_SMT 64
|
||||
+KVM_CAP_PPC_RMA 65
|
||||
+KVM_CAP_MAX_VCPUS 66
|
||||
+KVM_CAP_PPC_HIOR 67
|
||||
+KVM_CAP_PPC_PAPR 68
|
||||
+KVM_CAP_SW_TLB 69
|
||||
+KVM_CAP_ONE_REG 70
|
||||
+KVM_CAP_S390_GMAP 71
|
||||
+KVM_CAP_TSC_DEADLINE_TIMER 72
|
||||
+KVM_CAP_S390_UCONTROL 73
|
||||
+KVM_CAP_SYNC_REGS 74
|
||||
+KVM_CAP_PCI_2_3 75
|
||||
+KVM_CAP_KVMCLOCK_CTRL 76
|
||||
+KVM_CAP_SIGNAL_MSI 77
|
||||
+KVM_CAP_PPC_GET_SMMU_INFO 78
|
||||
+KVM_CAP_S390_COW 79
|
||||
+KVM_CAP_PPC_ALLOC_HTAB 80
|
||||
+KVM_CAP_READONLY_MEM 81
|
||||
+KVM_CAP_IRQFD_RESAMPLE 82
|
||||
+KVM_CAP_PPC_BOOKE_WATCHDOG 83
|
||||
+KVM_CAP_PPC_HTAB_FD 84
|
||||
+KVM_CAP_S390_CSS_SUPPORT 85
|
||||
+KVM_CAP_PPC_EPR 86
|
||||
+KVM_CAP_ARM_PSCI 87
|
||||
+KVM_CAP_ARM_SET_DEVICE_ADDR 88
|
||||
+KVM_CAP_DEVICE_CTRL 89
|
||||
+KVM_CAP_IRQ_MPIC 90
|
||||
+KVM_CAP_PPC_RTAS 91
|
||||
+KVM_CAP_IRQ_XICS 92
|
||||
+KVM_CAP_ARM_EL1_32BIT 93
|
||||
+KVM_CAP_SPAPR_MULTITCE 94
|
||||
+KVM_CAP_EXT_EMUL_CPUID 95
|
||||
+KVM_CAP_HYPERV_TIME 96
|
||||
+KVM_CAP_IOAPIC_POLARITY_IGNORED 97
|
||||
+KVM_CAP_ENABLE_CAP_VM 98
|
||||
+KVM_CAP_S390_IRQCHIP 99
|
||||
+KVM_CAP_IOEVENTFD_NO_LENGTH 100
|
||||
+KVM_CAP_VM_ATTRIBUTES 101
|
||||
+KVM_CAP_ARM_PSCI_0_2 102
|
||||
+KVM_CAP_PPC_FIXUP_HCALL 103
|
||||
+KVM_CAP_PPC_ENABLE_HCALL 104
|
||||
+KVM_CAP_CHECK_EXTENSION_VM 105
|
||||
+KVM_CAP_S390_USER_SIGP 106
|
||||
+KVM_CAP_S390_VECTOR_REGISTERS 107
|
||||
+KVM_CAP_S390_MEM_OP 108
|
||||
+KVM_CAP_S390_USER_STSI 109
|
||||
+KVM_CAP_S390_SKEYS 110
|
||||
+KVM_CAP_MIPS_FPU 111
|
||||
+KVM_CAP_MIPS_MSA 112
|
||||
+KVM_CAP_S390_INJECT_IRQ 113
|
||||
+KVM_CAP_S390_IRQ_STATE 114
|
||||
+KVM_CAP_PPC_HWRNG 115
|
||||
+KVM_CAP_DISABLE_QUIRKS 116
|
||||
+KVM_CAP_X86_SMM 117
|
||||
+KVM_CAP_MULTI_ADDRESS_SPACE 118
|
||||
+KVM_CAP_GUEST_DEBUG_HW_BPS 119
|
||||
+KVM_CAP_GUEST_DEBUG_HW_WPS 120
|
||||
+KVM_CAP_SPLIT_IRQCHIP 121
|
||||
+KVM_CAP_IOEVENTFD_ANY_LENGTH 122
|
||||
+KVM_CAP_HYPERV_SYNIC 123
|
||||
+KVM_CAP_S390_RI 124
|
||||
+KVM_CAP_SPAPR_TCE_64 125
|
||||
+KVM_CAP_ARM_PMU_V3 126
|
||||
+KVM_CAP_VCPU_ATTRIBUTES 127
|
||||
+KVM_CAP_MAX_VCPU_ID 128
|
||||
+KVM_CAP_X2APIC_API 129
|
||||
+KVM_CAP_S390_USER_INSTR0 130
|
||||
+KVM_CAP_MSI_DEVID 131
|
||||
+KVM_CAP_PPC_HTM 132
|
||||
+KVM_CAP_SPAPR_RESIZE_HPT 133
|
||||
+KVM_CAP_PPC_MMU_RADIX 134
|
||||
+KVM_CAP_PPC_MMU_HASH_V3 135
|
||||
+KVM_CAP_IMMEDIATE_EXIT 136
|
||||
+KVM_CAP_MIPS_VZ 137
|
||||
+KVM_CAP_MIPS_TE 138
|
||||
+KVM_CAP_MIPS_64BIT 139
|
||||
+KVM_CAP_S390_GS 140
|
||||
+KVM_CAP_S390_AIS 141
|
||||
+KVM_CAP_SPAPR_TCE_VFIO 142
|
||||
+KVM_CAP_X86_DISABLE_EXITS 143
|
||||
+KVM_CAP_ARM_USER_IRQ 144
|
||||
+KVM_CAP_S390_CMMA_MIGRATION 145
|
||||
+KVM_CAP_PPC_FWNMI 146
|
||||
+KVM_CAP_PPC_SMT_POSSIBLE 147
|
||||
+KVM_CAP_HYPERV_SYNIC2 148
|
||||
+KVM_CAP_HYPERV_VP_INDEX 149
|
||||
+KVM_CAP_S390_AIS_MIGRATION 150
|
||||
+KVM_CAP_PPC_GET_CPU_CHAR 151
|
||||
+KVM_CAP_S390_BPB 152
|
||||
+KVM_CAP_GET_MSR_FEATURES 153
|
||||
+KVM_CAP_HYPERV_EVENTFD 154
|
||||
+KVM_CAP_HYPERV_TLBFLUSH 155
|
||||
+KVM_CAP_S390_HPAGE_1M 156
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
111
net-add-support-for-AX.25-protocols-and-socket-optio.patch
Normal file
111
net-add-support-for-AX.25-protocols-and-socket-optio.patch
Normal file
@ -0,0 +1,111 @@
|
||||
From cfb86ab4e94f0d453dcc7c604a14df47ef9b5739 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 06:22:52 +0200
|
||||
Subject: [PATCH 068/293] net: add support for AX.25 protocols and socket
|
||||
option names decoding
|
||||
|
||||
* xlat/ax25_protocols.in: New file.
|
||||
* xlat/sock_ax25_options.in: Likewise.
|
||||
* net.c: Include "xlat/ax25_protocols.h" and "xlat/sock_ax25_options.h".
|
||||
* (SYS_FUNC(socket)): <[AF_AX25]>: Print protocol name using
|
||||
ax25_protocols xlat.
|
||||
(print_sockopt_fd_level_name) <[SOL_AX25]>: Print socket option name
|
||||
using sock_ax25_options xlat.
|
||||
---
|
||||
net.c | 11 +++++++++++
|
||||
xlat/ax25_protocols.in | 17 +++++++++++++++++
|
||||
xlat/sock_ax25_options.in | 15 +++++++++++++++
|
||||
3 files changed, 43 insertions(+)
|
||||
create mode 100644 xlat/ax25_protocols.in
|
||||
create mode 100644 xlat/sock_ax25_options.in
|
||||
|
||||
diff --git a/net.c b/net.c
|
||||
index 58296b9..f791a92 100644
|
||||
--- a/net.c
|
||||
+++ b/net.c
|
||||
@@ -88,6 +88,7 @@
|
||||
# include "xlat/addrfams.h"
|
||||
# include "xlat/ethernet_protocols.h"
|
||||
#undef XLAT_MACROS_ONLY
|
||||
+#include "xlat/ax25_protocols.h"
|
||||
#include "xlat/irda_protocols.h"
|
||||
#include "xlat/can_protocols.h"
|
||||
#include "xlat/bt_protocols.h"
|
||||
@@ -145,6 +146,12 @@ SYS_FUNC(socket)
|
||||
printxval_search(inet_protocols, tcp->u_arg[2], "IPPROTO_???");
|
||||
break;
|
||||
|
||||
+ case AF_AX25:
|
||||
+ /* Those are not available in public headers. */
|
||||
+ printxval_searchn_ex(ARRSZ_PAIR(ax25_protocols), tcp->u_arg[2],
|
||||
+ "AX25_P_???", XLAT_STYLE_VERBOSE);
|
||||
+ break;
|
||||
+
|
||||
case AF_NETLINK:
|
||||
printxval(netlink_protocols, tcp->u_arg[2], "NETLINK_???");
|
||||
break;
|
||||
@@ -445,6 +452,7 @@ SYS_FUNC(socketpair)
|
||||
#include "xlat/getsock_ipv6_options.h"
|
||||
#include "xlat/setsock_ipv6_options.h"
|
||||
#include "xlat/sock_ipx_options.h"
|
||||
+#include "xlat/sock_ax25_options.h"
|
||||
#include "xlat/sock_netlink_options.h"
|
||||
#include "xlat/sock_packet_options.h"
|
||||
#include "xlat/sock_raw_options.h"
|
||||
@@ -496,6 +504,9 @@ print_sockopt_fd_level_name(struct tcb *tcp, int fd, unsigned int level,
|
||||
case SOL_IPX:
|
||||
printxval(sock_ipx_options, name, "IPX_???");
|
||||
break;
|
||||
+ case SOL_AX25:
|
||||
+ printxval_search(sock_ax25_options, name, "AX25_???");
|
||||
+ break;
|
||||
case SOL_PACKET:
|
||||
printxval(sock_packet_options, name, "PACKET_???");
|
||||
break;
|
||||
diff --git a/xlat/ax25_protocols.in b/xlat/ax25_protocols.in
|
||||
new file mode 100644
|
||||
index 0000000..89ced43
|
||||
--- /dev/null
|
||||
+++ b/xlat/ax25_protocols.in
|
||||
@@ -0,0 +1,17 @@
|
||||
+/* sorted */
|
||||
+/* Those are pulled from include/net/ax25.h, they should be part of UAPI */
|
||||
+AX25_P_ROSE 0x01
|
||||
+AX25_P_VJCOMP 0x06 /* Compressed TCP/IP packet */
|
||||
+ /* Van Jacobsen (RFC 1144) */
|
||||
+AX25_P_VJUNCOMP 0x07 /* Uncompressed TCP/IP packet */
|
||||
+ /* Van Jacobsen (RFC 1144) */
|
||||
+AX25_P_SEGMENT 0x08 /* Segmentation fragment */
|
||||
+AX25_P_TEXNET 0xc3 /* TEXTNET datagram protocol */
|
||||
+AX25_P_LQ 0xc4 /* Link Quality Protocol */
|
||||
+AX25_P_ATALK 0xca /* Appletalk */
|
||||
+AX25_P_ATALK_ARP 0xcb /* Appletalk ARP */
|
||||
+AX25_P_IP 0xcc /* ARPA Internet Protocol */
|
||||
+AX25_P_ARP 0xcd /* ARPA Address Resolution */
|
||||
+AX25_P_FLEXNET 0xce /* FlexNet */
|
||||
+AX25_P_NETROM 0xcf /* NET/ROM */
|
||||
+AX25_P_TEXT 0xf0 /* No layer 3 protocol impl. */
|
||||
diff --git a/xlat/sock_ax25_options.in b/xlat/sock_ax25_options.in
|
||||
new file mode 100644
|
||||
index 0000000..4b6bed5
|
||||
--- /dev/null
|
||||
+++ b/xlat/sock_ax25_options.in
|
||||
@@ -0,0 +1,15 @@
|
||||
+/* sorted */
|
||||
+AX25_WINDOW 1
|
||||
+AX25_T1 2
|
||||
+AX25_N2 3
|
||||
+AX25_T3 4
|
||||
+AX25_T2 5
|
||||
+AX25_BACKOFF 6
|
||||
+AX25_EXTSEQ 7
|
||||
+AX25_PIDINCL 8
|
||||
+AX25_IDLE 9
|
||||
+AX25_PACLEN 10
|
||||
+AX25_IAMDIGI 12
|
||||
+
|
||||
+/* 13, 25, or 16409, depending on arch */
|
||||
+SO_BINDTODEVICE
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
40
net-decode-AF_PACKET-protocols-in-socket-syscall.patch
Normal file
40
net-decode-AF_PACKET-protocols-in-socket-syscall.patch
Normal file
@ -0,0 +1,40 @@
|
||||
From 38e0f556022f9b38b401c63201b95a95fdefa91d Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 15:20:33 +0200
|
||||
Subject: [PATCH 063/293] net: decode AF_PACKET protocols in socket syscall
|
||||
|
||||
* net.c: Include "xlat/ethernet_protocols.h" in XLAT_MACROS_ONLY mode.
|
||||
(SYS_FUNC(socket)) <AF_PACKET>: Decode using ethernet_protocols xlat.
|
||||
---
|
||||
net.c | 8 ++++++++
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/net.c b/net.c
|
||||
index 66dde0f..58296b9 100644
|
||||
--- a/net.c
|
||||
+++ b/net.c
|
||||
@@ -86,6 +86,7 @@
|
||||
|
||||
#define XLAT_MACROS_ONLY
|
||||
# include "xlat/addrfams.h"
|
||||
+# include "xlat/ethernet_protocols.h"
|
||||
#undef XLAT_MACROS_ONLY
|
||||
#include "xlat/irda_protocols.h"
|
||||
#include "xlat/can_protocols.h"
|
||||
@@ -148,6 +149,13 @@ SYS_FUNC(socket)
|
||||
printxval(netlink_protocols, tcp->u_arg[2], "NETLINK_???");
|
||||
break;
|
||||
|
||||
+ case AF_PACKET:
|
||||
+ tprints("htons(");
|
||||
+ printxval_searchn(ethernet_protocols, ethernet_protocols_size,
|
||||
+ ntohs(tcp->u_arg[2]), "ETH_P_???");
|
||||
+ tprints(")");
|
||||
+ break;
|
||||
+
|
||||
case AF_IRDA:
|
||||
printxval_index(can_protocols, tcp->u_arg[2], "IRDAPROTO_???");
|
||||
break;
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
54
net-decode-SOL_XDP-socket-option-names.patch
Normal file
54
net-decode-SOL_XDP-socket-option-names.patch
Normal file
@ -0,0 +1,54 @@
|
||||
From 1d7b8edda9837572e9ef53cac88d928f07cefacc Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 21:53:14 +0200
|
||||
Subject: [PATCH 045/293] net: decode SOL_XDP socket option names
|
||||
|
||||
* xlat/sock_xdp_options.in: New file.
|
||||
* net.c: Include "xlat/sock_xdp_options.h".
|
||||
(print_sockopt_fd_level_name) <case SOL_XDP>: Print SOL_XDP socket
|
||||
option names.
|
||||
---
|
||||
net.c | 4 ++++
|
||||
xlat/sock_xdp_options.in | 8 ++++++++
|
||||
2 files changed, 12 insertions(+)
|
||||
create mode 100644 xlat/sock_xdp_options.in
|
||||
|
||||
diff --git a/net.c b/net.c
|
||||
index 1c4e8ba..66dde0f 100644
|
||||
--- a/net.c
|
||||
+++ b/net.c
|
||||
@@ -458,6 +458,7 @@ SYS_FUNC(socketpair)
|
||||
#include "xlat/sock_nfcllcp_options.h"
|
||||
#include "xlat/sock_kcm_options.h"
|
||||
#include "xlat/sock_tls_options.h"
|
||||
+#include "xlat/sock_xdp_options.h"
|
||||
|
||||
static void
|
||||
print_sockopt_fd_level_name(struct tcb *tcp, int fd, unsigned int level,
|
||||
@@ -550,6 +551,9 @@ print_sockopt_fd_level_name(struct tcb *tcp, int fd, unsigned int level,
|
||||
case SOL_TLS:
|
||||
printxval(sock_tls_options, name, "TLS_???");
|
||||
break;
|
||||
+ case SOL_XDP:
|
||||
+ printxval_index(sock_xdp_options, name, "XDP_???");
|
||||
+ break;
|
||||
|
||||
/* Other SOL_* protocol levels still need work. */
|
||||
|
||||
diff --git a/xlat/sock_xdp_options.in b/xlat/sock_xdp_options.in
|
||||
new file mode 100644
|
||||
index 0000000..f2b7a68
|
||||
--- /dev/null
|
||||
+++ b/xlat/sock_xdp_options.in
|
||||
@@ -0,0 +1,8 @@
|
||||
+#value_indexed
|
||||
+XDP_MMAP_OFFSETS 1
|
||||
+XDP_RX_RING 2
|
||||
+XDP_TX_RING 3
|
||||
+XDP_UMEM_REG 4
|
||||
+XDP_UMEM_FILL_RING 5
|
||||
+XDP_UMEM_COMPLETION_RING 6
|
||||
+XDP_STATISTICS 7
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
60
net-enhance-decoding-of-getsockopt-SO_ERROR.patch
Normal file
60
net-enhance-decoding-of-getsockopt-SO_ERROR.patch
Normal file
@ -0,0 +1,60 @@
|
||||
From 692dbd2c3d2052025e3d4b121d94689f24458651 Mon Sep 17 00:00:00 2001
|
||||
From: Masatake YAMATO <yamato@redhat.com>
|
||||
Date: Tue, 18 Dec 2018 04:16:11 +0900
|
||||
Subject: [PATCH 146/293] net: enhance decoding of getsockopt(SO_ERROR)
|
||||
|
||||
* net.c (print_get_error): New function decoding error
|
||||
number returned as option value for SO_ERROR option.
|
||||
(print_getsockopt) <case SO_ERROR>: Call print_get_error.
|
||||
|
||||
* tests/so_error.c: New test.
|
||||
* tests/gen_tests.in (so_error): Likewise.
|
||||
* tests/pure_executables.list: Add so_error.
|
||||
|
||||
Signed-off-by: Masatake YAMATO <yamato@redhat.com>
|
||||
Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
net.c | 20 +++++++++
|
||||
1 files changed, 20 insertions(+)
|
||||
|
||||
diff --git a/net.c b/net.c
|
||||
index 3058e2d..bcab329 100644
|
||||
--- a/net.c
|
||||
+++ b/net.c
|
||||
@@ -651,6 +651,23 @@ print_get_ucred(struct tcb *const tcp, const kernel_ulong_t addr,
|
||||
tprints("}");
|
||||
}
|
||||
|
||||
+static void
|
||||
+print_get_error(struct tcb *const tcp, const kernel_ulong_t addr,
|
||||
+ unsigned int len)
|
||||
+{
|
||||
+ unsigned int err;
|
||||
+
|
||||
+ if (len > sizeof(err))
|
||||
+ err = sizeof(err);
|
||||
+
|
||||
+ if (umoven_or_printaddr(tcp, addr, len, &err))
|
||||
+ return;
|
||||
+
|
||||
+ tprints("[");
|
||||
+ print_xlat_ex(err, err_name(err), XLAT_STYLE_FMT_U);
|
||||
+ tprints("]");
|
||||
+}
|
||||
+
|
||||
#ifdef PACKET_STATISTICS
|
||||
static void
|
||||
print_tpacket_stats(struct tcb *const tcp, const kernel_ulong_t addr,
|
||||
@@ -766,6 +783,9 @@ print_getsockopt(struct tcb *const tcp, const unsigned int level,
|
||||
else
|
||||
printaddr(addr);
|
||||
return;
|
||||
+ case SO_ERROR:
|
||||
+ print_get_error(tcp, addr, rlen);
|
||||
+ return;
|
||||
}
|
||||
break;
|
||||
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
175
netlink_packet_diag-assorted-decoding-fixes.patch
Normal file
175
netlink_packet_diag-assorted-decoding-fixes.patch
Normal file
@ -0,0 +1,175 @@
|
||||
From ac2f6695cd896d9b33f9b39efb167db7fb893d2d Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 21:34:06 +0200
|
||||
Subject: [PATCH 070/293] netlink_packet_diag: assorted decoding fixes
|
||||
|
||||
* xlat/af_packet_versions.in: New file.
|
||||
* netlink_packet_diag.c: Include "xlat/af_packet_versions.h".
|
||||
(decode_packet_diag_req): sdiag_protocol shouldn't be decoded as a protocol,
|
||||
currently it should be set to 0.
|
||||
(decode_packet_diag_info): Decode pdi_version field using af_packet_versions
|
||||
xlat; decode pdi_index field as an interface index.
|
||||
(packet_diag_msg_nla_decoders) <PACKET_DIAG_UID>: Decode using
|
||||
decode_nla_uid.
|
||||
(decode_packet_diag_msg): Decode pdiag_num as an low-level protocol.
|
||||
* tests/netlink_sock_diag.c: Update expected output.
|
||||
* tests/nlattr_packet_diag_msg.c: Likewise.
|
||||
---
|
||||
netlink_packet_diag.c | 22 ++++++++++++++--------
|
||||
tests/netlink_sock_diag.c | 6 +++---
|
||||
tests/nlattr_packet_diag_msg.c | 15 ++++++++-------
|
||||
xlat/af_packet_versions.in | 3 +++
|
||||
4 files changed, 28 insertions(+), 18 deletions(-)
|
||||
create mode 100644 xlat/af_packet_versions.in
|
||||
|
||||
diff --git a/netlink_packet_diag.c b/netlink_packet_diag.c
|
||||
index 18b7091..9794f56 100644
|
||||
--- a/netlink_packet_diag.c
|
||||
+++ b/netlink_packet_diag.c
|
||||
@@ -37,6 +37,7 @@
|
||||
#include <linux/sock_diag.h>
|
||||
#include <linux/packet_diag.h>
|
||||
|
||||
+#include "xlat/af_packet_versions.h"
|
||||
#include "xlat/packet_diag_attrs.h"
|
||||
#include "xlat/packet_diag_info_flags.h"
|
||||
#include "xlat/packet_diag_show.h"
|
||||
@@ -52,10 +53,11 @@ DECL_NETLINK_DIAG_DECODER(decode_packet_diag_req)
|
||||
if (!umoven_or_printaddr(tcp, addr + offset,
|
||||
sizeof(req) - offset,
|
||||
(char *) &req + offset)) {
|
||||
- tprints("sdiag_protocol=");
|
||||
- printxval_searchn(ethernet_protocols,
|
||||
- ethernet_protocols_size,
|
||||
- req.sdiag_protocol, "ETH_P_???");
|
||||
+ /*
|
||||
+ * AF_PACKET currently doesn't support protocol values
|
||||
+ * other than 0.
|
||||
+ */
|
||||
+ PRINT_FIELD_X("", req, sdiag_protocol);
|
||||
PRINT_FIELD_U(", ", req, pdiag_ino);
|
||||
PRINT_FIELD_FLAGS(", ", req, pdiag_show,
|
||||
packet_diag_show, "PACKET_SHOW_???");
|
||||
@@ -79,8 +81,9 @@ decode_packet_diag_info(struct tcb *const tcp,
|
||||
if (umove_or_printaddr(tcp, addr, &pinfo))
|
||||
return true;
|
||||
|
||||
- PRINT_FIELD_U("{", pinfo, pdi_index);
|
||||
- PRINT_FIELD_U(", ", pinfo, pdi_version);
|
||||
+ PRINT_FIELD_IFINDEX("{", pinfo, pdi_index);
|
||||
+ PRINT_FIELD_XVAL(", ", pinfo, pdi_version, af_packet_versions,
|
||||
+ "TPACKET_???");
|
||||
PRINT_FIELD_U(", ", pinfo, pdi_reserve);
|
||||
PRINT_FIELD_U(", ", pinfo, pdi_copy_thresh);
|
||||
PRINT_FIELD_U(", ", pinfo, pdi_tstamp);
|
||||
@@ -172,7 +175,7 @@ static const nla_decoder_t packet_diag_msg_nla_decoders[] = {
|
||||
[PACKET_DIAG_RX_RING] = decode_packet_diag_ring,
|
||||
[PACKET_DIAG_TX_RING] = decode_packet_diag_ring,
|
||||
[PACKET_DIAG_FANOUT] = decode_nla_u32,
|
||||
- [PACKET_DIAG_UID] = decode_nla_u32,
|
||||
+ [PACKET_DIAG_UID] = decode_nla_uid,
|
||||
[PACKET_DIAG_MEMINFO] = decode_nla_meminfo,
|
||||
[PACKET_DIAG_FILTER] = decode_packet_diag_filter
|
||||
};
|
||||
@@ -191,7 +194,10 @@ DECL_NETLINK_DIAG_DECODER(decode_packet_diag_msg)
|
||||
(char *) &msg + offset)) {
|
||||
PRINT_FIELD_XVAL("", msg, pdiag_type,
|
||||
socktypes, "SOCK_???");
|
||||
- PRINT_FIELD_U(", ", msg, pdiag_num);
|
||||
+ PRINT_FIELD_XVAL_SORTED_SIZED(", ", msg, pdiag_num,
|
||||
+ ethernet_protocols,
|
||||
+ ethernet_protocols_size,
|
||||
+ "ETH_P_???");
|
||||
PRINT_FIELD_U(", ", msg, pdiag_ino);
|
||||
PRINT_FIELD_COOKIE(", ", msg, pdiag_cookie);
|
||||
decode_nla = true;
|
||||
diff --git a/tests/netlink_sock_diag.c b/tests/netlink_sock_diag.c
|
||||
index dfe3526..6049253 100644
|
||||
--- a/tests/netlink_sock_diag.c
|
||||
+++ b/tests/netlink_sock_diag.c
|
||||
@@ -338,7 +338,7 @@ test_packet_diag_req(const int fd)
|
||||
TEST_SOCK_DIAG(fd, nlh0, AF_PACKET,
|
||||
SOCK_DIAG_BY_FAMILY, NLM_F_REQUEST, req,
|
||||
printf("{sdiag_family=AF_PACKET"),
|
||||
- printf(", sdiag_protocol=ETH_P_LOOP");
|
||||
+ printf(", sdiag_protocol=%#x", req.sdiag_protocol);
|
||||
PRINT_FIELD_U(", ", req, pdiag_ino);
|
||||
printf(", pdiag_show=PACKET_SHOW_INFO");
|
||||
PRINT_FIELD_COOKIE(", ", req, pdiag_cookie);
|
||||
@@ -351,7 +351,7 @@ test_packet_diag_msg(const int fd)
|
||||
static const struct packet_diag_msg msg = {
|
||||
.pdiag_family = AF_PACKET,
|
||||
.pdiag_type = SOCK_STREAM,
|
||||
- .pdiag_num = 0xbadc,
|
||||
+ .pdiag_num = 0x9100,
|
||||
.pdiag_ino = 0xfacefeed,
|
||||
.pdiag_cookie = { 0xdeadbeef, 0xbadc0ded }
|
||||
};
|
||||
@@ -360,7 +360,7 @@ test_packet_diag_msg(const int fd)
|
||||
SOCK_DIAG_BY_FAMILY, NLM_F_DUMP, msg,
|
||||
printf("{pdiag_family=AF_PACKET"),
|
||||
printf(", pdiag_type=SOCK_STREAM");
|
||||
- PRINT_FIELD_U(", ", msg, pdiag_num);
|
||||
+ printf(", pdiag_num=ETH_P_QINQ1");
|
||||
PRINT_FIELD_U(", ", msg, pdiag_ino);
|
||||
PRINT_FIELD_COOKIE(", ", msg, pdiag_cookie);
|
||||
printf("}"));
|
||||
diff --git a/tests/nlattr_packet_diag_msg.c b/tests/nlattr_packet_diag_msg.c
|
||||
index 016d052..6ac9907 100644
|
||||
--- a/tests/nlattr_packet_diag_msg.c
|
||||
+++ b/tests/nlattr_packet_diag_msg.c
|
||||
@@ -51,7 +51,8 @@ init_packet_diag_msg(struct nlmsghdr *const nlh, const unsigned int msg_len)
|
||||
struct packet_diag_msg *const msg = NLMSG_DATA(nlh);
|
||||
SET_STRUCT(struct packet_diag_msg, msg,
|
||||
.pdiag_family = AF_PACKET,
|
||||
- .pdiag_type = SOCK_STREAM
|
||||
+ .pdiag_type = SOCK_STREAM,
|
||||
+ .pdiag_num = 3,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -61,7 +62,7 @@ print_packet_diag_msg(const unsigned int msg_len)
|
||||
printf("{len=%u, type=SOCK_DIAG_BY_FAMILY"
|
||||
", flags=NLM_F_DUMP, seq=0, pid=0}"
|
||||
", {pdiag_family=AF_PACKET"
|
||||
- ", pdiag_type=SOCK_STREAM, pdiag_num=0"
|
||||
+ ", pdiag_type=SOCK_STREAM, pdiag_num=ETH_P_ALL"
|
||||
", pdiag_ino=0, pdiag_cookie=[0, 0]}",
|
||||
msg_len);
|
||||
}
|
||||
@@ -98,9 +99,9 @@ main(void)
|
||||
{
|
||||
skip_if_unavailable("/proc/self/fd/");
|
||||
|
||||
- static const struct packet_diag_info pinfo = {
|
||||
- .pdi_index = 0xabcddafa,
|
||||
- .pdi_version = 0xbabcdafb,
|
||||
+ struct packet_diag_info pinfo = {
|
||||
+ .pdi_index = ifindex_lo(),
|
||||
+ .pdi_version = 2,
|
||||
.pdi_reserve = 0xcfaacdaf,
|
||||
.pdi_copy_thresh = 0xdabacdaf,
|
||||
.pdi_tstamp = 0xeafbaadf,
|
||||
@@ -143,8 +144,8 @@ main(void)
|
||||
TEST_NLATTR_OBJECT(fd, nlh0, hdrlen,
|
||||
init_packet_diag_msg, print_packet_diag_msg,
|
||||
PACKET_DIAG_INFO, pattern, pinfo,
|
||||
- PRINT_FIELD_U("{", pinfo, pdi_index);
|
||||
- PRINT_FIELD_U(", ", pinfo, pdi_version);
|
||||
+ printf("{pdi_index=%s", IFINDEX_LO_STR);
|
||||
+ printf(", pdi_version=TPACKET_V3");
|
||||
PRINT_FIELD_U(", ", pinfo, pdi_reserve);
|
||||
PRINT_FIELD_U(", ", pinfo, pdi_copy_thresh);
|
||||
PRINT_FIELD_U(", ", pinfo, pdi_tstamp);
|
||||
diff --git a/xlat/af_packet_versions.in b/xlat/af_packet_versions.in
|
||||
new file mode 100644
|
||||
index 0000000..399cdf4
|
||||
--- /dev/null
|
||||
+++ b/xlat/af_packet_versions.in
|
||||
@@ -0,0 +1,3 @@
|
||||
+TPACKET_V1 0
|
||||
+TPACKET_V2 1
|
||||
+TPACKET_V3 2
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
137
netlink_smc_diag-add-SMC_DIAG_FALLBACK-attribute-sup.patch
Normal file
137
netlink_smc_diag-add-SMC_DIAG_FALLBACK-attribute-sup.patch
Normal file
@ -0,0 +1,137 @@
|
||||
From df7dd5aa664e499058039f7526a51adc376e9756 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:20:33 +0200
|
||||
Subject: [PATCH 032/293] netlink_smc_diag: add SMC_DIAG_FALLBACK attribute
|
||||
support
|
||||
|
||||
Introduced by Linux commit v4.19-rc1~140^2~253^2~1.
|
||||
|
||||
* linux/smc_diag.h (SMC_DIAG_FALLBACK): New enumeration item.
|
||||
(struct smc_diag_fallback): New type definition.
|
||||
* netlink_smc_diag.c: Include "xlat/smc_decl_codes.h".
|
||||
(decode_smc_diag_fallback): New function.
|
||||
(smc_diag_msg_nla_decoders) <[SMC_DIAG_FALLBACK]>: New decoder, calls
|
||||
decode_smc_diag_fallback.
|
||||
* tests/nlattr_smc_diag_msg.c: Add checks for SMC_DIAG_FALLBACK
|
||||
attribute decoding.
|
||||
* xlat/smc_decl_codes.in: New file.
|
||||
* xlat/smc_diag_attrs.in (SMC_DIAG_FALLBACK): New constant.
|
||||
---
|
||||
linux/smc_diag.h | 7 +++++++
|
||||
netlink_smc_diag.c | 29 +++++++++++++++++++++++++++++
|
||||
xlat/smc_decl_codes.in | 17 +++++++++++++++++
|
||||
xlat/smc_diag_attrs.in | 1 +
|
||||
4 files changed, 54 insertions(+)
|
||||
create mode 100644 xlat/smc_decl_codes.in
|
||||
|
||||
diff --git a/linux/smc_diag.h b/linux/smc_diag.h
|
||||
index 287cb55..ebdbe8c 100644
|
||||
--- a/linux/smc_diag.h
|
||||
+++ b/linux/smc_diag.h
|
||||
@@ -31,6 +31,7 @@ enum {
|
||||
SMC_DIAG_LGRINFO,
|
||||
SMC_DIAG_SHUTDOWN,
|
||||
SMC_DIAG_DMBINFO,
|
||||
+ SMC_DIAG_FALLBACK,
|
||||
};
|
||||
|
||||
/* SMC_DIAG_CONNINFO */
|
||||
@@ -82,4 +83,10 @@ struct smcd_diag_dmbinfo {
|
||||
uint64_t ATTRIBUTE_ALIGNED(8) peer_token;
|
||||
};
|
||||
|
||||
+/* SMC_DIAG_FALLBACK */
|
||||
+struct smc_diag_fallback {
|
||||
+ uint32_t reason;
|
||||
+ uint32_t peer_diagnosis;
|
||||
+};
|
||||
+
|
||||
#endif /* !STRACE_LINUX_SMC_DIAG_H */
|
||||
diff --git a/netlink_smc_diag.c b/netlink_smc_diag.c
|
||||
index c2e2c66..b9293a9 100644
|
||||
--- a/netlink_smc_diag.c
|
||||
+++ b/netlink_smc_diag.c
|
||||
@@ -43,6 +43,7 @@
|
||||
# include <arpa/inet.h>
|
||||
# include <linux/smc_diag.h>
|
||||
|
||||
+# include "xlat/smc_decl_codes.h"
|
||||
# include "xlat/smc_diag_attrs.h"
|
||||
# include "xlat/smc_diag_extended_flags.h"
|
||||
# include "xlat/smc_diag_mode.h"
|
||||
@@ -169,12 +170,40 @@ decode_smc_diag_dmbinfo(struct tcb *const tcp,
|
||||
|
||||
return true;
|
||||
}
|
||||
+static bool
|
||||
+decode_smc_diag_fallback(struct tcb *const tcp,
|
||||
+ const kernel_ulong_t addr,
|
||||
+ const unsigned int len,
|
||||
+ const void *const opaque_data)
|
||||
+{
|
||||
+ struct smc_diag_fallback fb;
|
||||
+
|
||||
+ if (len < sizeof(fb))
|
||||
+ return false;
|
||||
+ if (umove_or_printaddr(tcp, addr, &fb))
|
||||
+ return true;
|
||||
+
|
||||
+ /*
|
||||
+ * We print them verbose since they are defined in a non-UAPI header,
|
||||
+ * net/smc/smc_clc.h
|
||||
+ */
|
||||
+ tprints("{reason=");
|
||||
+ printxval_search_ex(smc_decl_codes, fb.reason,
|
||||
+ "SMC_CLC_DECL_???");
|
||||
+ tprints(", peer_diagnosis=");
|
||||
+ printxval_search_ex(smc_decl_codes, fb.peer_diagnosis,
|
||||
+ "SMC_CLC_DECL_???");
|
||||
+ tprints("}");
|
||||
+
|
||||
+ return true;
|
||||
+}
|
||||
|
||||
static const nla_decoder_t smc_diag_msg_nla_decoders[] = {
|
||||
[SMC_DIAG_CONNINFO] = decode_smc_diag_conninfo,
|
||||
[SMC_DIAG_LGRINFO] = decode_smc_diag_lgrinfo,
|
||||
[SMC_DIAG_SHUTDOWN] = decode_nla_u8,
|
||||
[SMC_DIAG_DMBINFO] = decode_smc_diag_dmbinfo,
|
||||
+ [SMC_DIAG_FALLBACK] = decode_smc_diag_fallback,
|
||||
};
|
||||
|
||||
DECL_NETLINK_DIAG_DECODER(decode_smc_diag_msg)
|
||||
diff --git a/xlat/smc_decl_codes.in b/xlat/smc_decl_codes.in
|
||||
new file mode 100644
|
||||
index 0000000..d7810f8
|
||||
--- /dev/null
|
||||
+++ b/xlat/smc_decl_codes.in
|
||||
@@ -0,0 +1,17 @@
|
||||
+/* sorted */
|
||||
+SMC_CLC_DECL_MEM 0x01010000
|
||||
+SMC_CLC_DECL_TIMEOUT_CL 0x02010000
|
||||
+SMC_CLC_DECL_TIMEOUT_AL 0x02020000
|
||||
+SMC_CLC_DECL_CNFERR 0x03000000
|
||||
+SMC_CLC_DECL_PEERNOSMC 0x03010000
|
||||
+SMC_CLC_DECL_IPSEC 0x03020000
|
||||
+SMC_CLC_DECL_NOSMCDEV 0x03030000
|
||||
+SMC_CLC_DECL_MODEUNSUPP 0x03040000
|
||||
+SMC_CLC_DECL_RMBE_EC 0x03050000
|
||||
+SMC_CLC_DECL_OPTUNSUPP 0x03060000
|
||||
+SMC_CLC_DECL_SYNCERR 0x04000000
|
||||
+SMC_CLC_DECL_PEERDECL 0x05000000
|
||||
+SMC_CLC_DECL_INTERR 0x99990000
|
||||
+SMC_CLC_DECL_ERR_RTOK 0x99990001
|
||||
+SMC_CLC_DECL_ERR_RDYLNK 0x99990002
|
||||
+SMC_CLC_DECL_ERR_REGRMB 0x99990003
|
||||
diff --git a/xlat/smc_diag_attrs.in b/xlat/smc_diag_attrs.in
|
||||
index 023f398..8d0ebeb 100644
|
||||
--- a/xlat/smc_diag_attrs.in
|
||||
+++ b/xlat/smc_diag_attrs.in
|
||||
@@ -4,3 +4,4 @@ SMC_DIAG_CONNINFO
|
||||
SMC_DIAG_LGRINFO
|
||||
SMC_DIAG_SHUTDOWN
|
||||
SMC_DIAG_DMBINFO
|
||||
+SMC_DIAG_FALLBACK
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
71
netlink_smc_diag-decode-SMC_DIAG_SHUTDOWN-attribute-.patch
Normal file
71
netlink_smc_diag-decode-SMC_DIAG_SHUTDOWN-attribute-.patch
Normal file
@ -0,0 +1,71 @@
|
||||
From 587d1d56630bd7e193ffe50834e57431454d1003 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 21:33:26 +0200
|
||||
Subject: [PATCH 042/293] netlink_smc_diag: decode SMC_DIAG_SHUTDOWN attribute
|
||||
value
|
||||
|
||||
* xlat/sock_shutdown_flags.in: New file.
|
||||
* netlink_smc_diag.c: Include "xlat/sock_shutdown_flags.h".
|
||||
(decode_smc_diag_shutdown): New function.
|
||||
(smc_diag_msg_nla_decoders) <[SMC_DIAG_SHUTDOWN]>: Use
|
||||
decode_smc_diag_shutdown.
|
||||
* tests/nlattr_smc_diag_msg.c: Add checks for SMC_DIAG_SHUTDOWN.
|
||||
---
|
||||
netlink_smc_diag.c | 17 ++++++++++++++++-
|
||||
xlat/sock_shutdown_flags.in | 2 ++
|
||||
2 files changed, 18 insertions(+), 1 deletion(-)
|
||||
create mode 100644 xlat/sock_shutdown_flags.in
|
||||
|
||||
diff --git a/netlink_smc_diag.c b/netlink_smc_diag.c
|
||||
index b9293a9..0248712 100644
|
||||
--- a/netlink_smc_diag.c
|
||||
+++ b/netlink_smc_diag.c
|
||||
@@ -49,6 +49,7 @@
|
||||
# include "xlat/smc_diag_mode.h"
|
||||
# include "xlat/smc_link_group_roles.h"
|
||||
# include "xlat/smc_states.h"
|
||||
+# include "xlat/sock_shutdown_flags.h"
|
||||
|
||||
DECL_NETLINK_DIAG_DECODER(decode_smc_diag_req)
|
||||
{
|
||||
@@ -149,6 +150,20 @@ decode_smc_diag_lgrinfo(struct tcb *const tcp,
|
||||
}
|
||||
|
||||
static bool
|
||||
+decode_smc_diag_shutdown(struct tcb *const tcp,
|
||||
+ const kernel_ulong_t addr,
|
||||
+ const unsigned int len,
|
||||
+ const void *const opaque_data)
|
||||
+{
|
||||
+ const struct decode_nla_xlat_opts opts = {
|
||||
+ ARRSZ_PAIR(sock_shutdown_flags), "???_SHUTDOWN",
|
||||
+ .size = 1,
|
||||
+ };
|
||||
+
|
||||
+ return decode_nla_flags(tcp, addr, len, &opts);
|
||||
+}
|
||||
+
|
||||
+static bool
|
||||
decode_smc_diag_dmbinfo(struct tcb *const tcp,
|
||||
const kernel_ulong_t addr,
|
||||
const unsigned int len,
|
||||
@@ -201,7 +216,7 @@ decode_smc_diag_fallback(struct tcb *const tcp,
|
||||
static const nla_decoder_t smc_diag_msg_nla_decoders[] = {
|
||||
[SMC_DIAG_CONNINFO] = decode_smc_diag_conninfo,
|
||||
[SMC_DIAG_LGRINFO] = decode_smc_diag_lgrinfo,
|
||||
- [SMC_DIAG_SHUTDOWN] = decode_nla_u8,
|
||||
+ [SMC_DIAG_SHUTDOWN] = decode_smc_diag_shutdown,
|
||||
[SMC_DIAG_DMBINFO] = decode_smc_diag_dmbinfo,
|
||||
[SMC_DIAG_FALLBACK] = decode_smc_diag_fallback,
|
||||
};
|
||||
diff --git a/xlat/sock_shutdown_flags.in b/xlat/sock_shutdown_flags.in
|
||||
new file mode 100644
|
||||
index 0000000..ff7d432
|
||||
--- /dev/null
|
||||
+++ b/xlat/sock_shutdown_flags.in
|
||||
@@ -0,0 +1,2 @@
|
||||
+RCV_SHUTDOWN 1
|
||||
+SEND_SHUTDOWN 2
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
93
netlink_smc_diag-decode-smc_diag_msg.diag_fallback-c.patch
Normal file
93
netlink_smc_diag-decode-smc_diag_msg.diag_fallback-c.patch
Normal file
@ -0,0 +1,93 @@
|
||||
From f7d175b562bda6c36f5d7303e497d0fd7cbf4cdd Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 11:56:21 +0200
|
||||
Subject: [PATCH 029/293] netlink_smc_diag: decode smc_diag_msg.diag_fallback
|
||||
constant names
|
||||
|
||||
Introduced by Linux commit v4.19-rc1~140^2~285^2~4.
|
||||
|
||||
* xlat/smc_diag_mode.in: New file.
|
||||
* netlink_smc_diag.c: Include "xlat/smc_diag_mode.h".
|
||||
(decode_smc_diag_msg): Print diag_fallback field using smc_diag_mode
|
||||
xlat.
|
||||
* tests/netlink_sock_diag.c (test_smc_diag_msg): Update expected output.
|
||||
* tests/nlattr_smc_diag_msg.c (print_smc_diag_msg): Likewise.
|
||||
---
|
||||
netlink_smc_diag.c | 5 ++++-
|
||||
tests/netlink_sock_diag.c | 4 ++--
|
||||
tests/nlattr_smc_diag_msg.c | 2 +-
|
||||
xlat/smc_diag_mode.in | 4 ++++
|
||||
4 files changed, 11 insertions(+), 4 deletions(-)
|
||||
create mode 100644 xlat/smc_diag_mode.in
|
||||
|
||||
diff --git a/netlink_smc_diag.c b/netlink_smc_diag.c
|
||||
index 42369ad..c2e2c66 100644
|
||||
--- a/netlink_smc_diag.c
|
||||
+++ b/netlink_smc_diag.c
|
||||
@@ -45,6 +45,7 @@
|
||||
|
||||
# include "xlat/smc_diag_attrs.h"
|
||||
# include "xlat/smc_diag_extended_flags.h"
|
||||
+# include "xlat/smc_diag_mode.h"
|
||||
# include "xlat/smc_link_group_roles.h"
|
||||
# include "xlat/smc_states.h"
|
||||
|
||||
@@ -190,7 +191,9 @@ DECL_NETLINK_DIAG_DECODER(decode_smc_diag_msg)
|
||||
(void *) &msg + offset)) {
|
||||
PRINT_FIELD_XVAL("", msg, diag_state,
|
||||
smc_states, "SMC_???");
|
||||
- PRINT_FIELD_U(", ", msg, diag_fallback);
|
||||
+ PRINT_FIELD_XVAL_INDEX(", ", msg, diag_fallback,
|
||||
+ smc_diag_mode,
|
||||
+ "SMC_DIAG_MODE_???");
|
||||
PRINT_FIELD_U(", ", msg, diag_shutdown);
|
||||
/*
|
||||
* AF_SMC protocol family socket handler
|
||||
diff --git a/tests/netlink_sock_diag.c b/tests/netlink_sock_diag.c
|
||||
index 880069f..dfe3526 100644
|
||||
--- a/tests/netlink_sock_diag.c
|
||||
+++ b/tests/netlink_sock_diag.c
|
||||
@@ -609,7 +609,7 @@ test_smc_diag_msg(const int fd)
|
||||
struct smc_diag_msg msg = {
|
||||
.diag_family = AF_SMC,
|
||||
.diag_state = SMC_ACTIVE,
|
||||
- .diag_fallback = 0xde,
|
||||
+ .diag_fallback = 0x1,
|
||||
.diag_shutdown = 0xba,
|
||||
.id = {
|
||||
.idiag_sport = 0xdead,
|
||||
@@ -630,7 +630,7 @@ test_smc_diag_msg(const int fd)
|
||||
SOCK_DIAG_BY_FAMILY, NLM_F_DUMP, msg,
|
||||
printf("{diag_family=AF_SMC"),
|
||||
printf(", diag_state=SMC_ACTIVE");
|
||||
- PRINT_FIELD_U(", ", msg, diag_fallback);
|
||||
+ printf(", diag_fallback=SMC_DIAG_MODE_FALLBACK_TCP");
|
||||
PRINT_FIELD_U(", ", msg, diag_shutdown);
|
||||
printf(", id={idiag_sport=htons(%u)"
|
||||
", idiag_dport=htons(%u)"
|
||||
diff --git a/tests/nlattr_smc_diag_msg.c b/tests/nlattr_smc_diag_msg.c
|
||||
index 227ade0..1389027 100644
|
||||
--- a/tests/nlattr_smc_diag_msg.c
|
||||
+++ b/tests/nlattr_smc_diag_msg.c
|
||||
@@ -77,7 +77,7 @@ print_smc_diag_msg(const unsigned int msg_len)
|
||||
printf("{len=%u, type=SOCK_DIAG_BY_FAMILY"
|
||||
", flags=NLM_F_DUMP, seq=0, pid=0}"
|
||||
", {diag_family=AF_SMC, diag_state=SMC_ACTIVE"
|
||||
- ", diag_fallback=0, diag_shutdown=0"
|
||||
+ ", diag_fallback=SMC_DIAG_MODE_SMCR, diag_shutdown=0"
|
||||
", id={idiag_sport=htons(0), idiag_dport=htons(0)"
|
||||
", idiag_src=inet_addr(\"%s\")"
|
||||
", idiag_dst=inet_addr(\"%s\")"
|
||||
diff --git a/xlat/smc_diag_mode.in b/xlat/smc_diag_mode.in
|
||||
new file mode 100644
|
||||
index 0000000..4ac3963
|
||||
--- /dev/null
|
||||
+++ b/xlat/smc_diag_mode.in
|
||||
@@ -0,0 +1,4 @@
|
||||
+#value_indexed
|
||||
+SMC_DIAG_MODE_SMCR 0
|
||||
+SMC_DIAG_MODE_FALLBACK_TCP 1
|
||||
+SMC_DIAG_MODE_SMCD 2
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
115
netlink_smc_diag-implement-SMC_DIAG_DMBINFO-decoding.patch
Normal file
115
netlink_smc_diag-implement-SMC_DIAG_DMBINFO-decoding.patch
Normal file
@ -0,0 +1,115 @@
|
||||
From cf174ac87a04d386513b5af9bf5cc08dc333febf Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 10:48:06 +0200
|
||||
Subject: [PATCH 021/293] netlink_smc_diag: implement SMC_DIAG_DMBINFO
|
||||
decoding
|
||||
|
||||
The message has been added by Linux commit v4.19-rc1~140^2~507^2~1.
|
||||
|
||||
* linux/smc_diag.h: Include "gcc_compat.h".
|
||||
(enum): Add SMC_DIAG_DMBINFO.
|
||||
(struct smcd_diag_dmbinfo): New type definition.
|
||||
* xlat/smc_diag_attrs.in (SMC_DIAG_DMBINFO): New constant.
|
||||
* netlink_smc_diag.c (decode_smc_diag_dmbinfo): New function.
|
||||
(smc_diag_msg_nla_decoders) [SMC_DIAG_DMBINFO]: New decoder, calls
|
||||
decode_smc_diag_dmbinfo.
|
||||
* tests/nlattr_smc_diag_msg.c: Add SMC_DIAG_DMBINFO check.
|
||||
---
|
||||
linux/smc_diag.h | 13 +++++++++++++
|
||||
netlink_smc_diag.c | 26 +++++++++++++++++++++++++-
|
||||
xlat/smc_diag_attrs.in | 1 +
|
||||
3 files changed, 39 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/linux/smc_diag.h b/linux/smc_diag.h
|
||||
index a9d4a51..287cb55 100644
|
||||
--- a/linux/smc_diag.h
|
||||
+++ b/linux/smc_diag.h
|
||||
@@ -3,6 +3,8 @@
|
||||
|
||||
#include <linux/inet_diag.h>
|
||||
|
||||
+#include "gcc_compat.h"
|
||||
+
|
||||
/* Request structure */
|
||||
struct smc_diag_req {
|
||||
uint8_t diag_family;
|
||||
@@ -28,6 +30,7 @@ enum {
|
||||
SMC_DIAG_CONNINFO,
|
||||
SMC_DIAG_LGRINFO,
|
||||
SMC_DIAG_SHUTDOWN,
|
||||
+ SMC_DIAG_DMBINFO,
|
||||
};
|
||||
|
||||
/* SMC_DIAG_CONNINFO */
|
||||
@@ -64,9 +67,19 @@ struct smc_diag_linkinfo {
|
||||
uint8_t peer_gid[40];
|
||||
};
|
||||
|
||||
+/* SMC_DIAG_LGRINFO */
|
||||
struct smc_diag_lgrinfo {
|
||||
struct smc_diag_linkinfo lnk[1];
|
||||
uint8_t role;
|
||||
};
|
||||
|
||||
+/* SMC_DIAG_DMBINFO */
|
||||
+struct smcd_diag_dmbinfo {
|
||||
+ uint32_t linkid;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) peer_gid;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) my_gid;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) token;
|
||||
+ uint64_t ATTRIBUTE_ALIGNED(8) peer_token;
|
||||
+};
|
||||
+
|
||||
#endif /* !STRACE_LINUX_SMC_DIAG_H */
|
||||
diff --git a/netlink_smc_diag.c b/netlink_smc_diag.c
|
||||
index 4ce31e7..42369ad 100644
|
||||
--- a/netlink_smc_diag.c
|
||||
+++ b/netlink_smc_diag.c
|
||||
@@ -146,10 +146,34 @@ decode_smc_diag_lgrinfo(struct tcb *const tcp,
|
||||
return true;
|
||||
}
|
||||
|
||||
+static bool
|
||||
+decode_smc_diag_dmbinfo(struct tcb *const tcp,
|
||||
+ const kernel_ulong_t addr,
|
||||
+ const unsigned int len,
|
||||
+ const void *const opaque_data)
|
||||
+{
|
||||
+ struct smcd_diag_dmbinfo dinfo;
|
||||
+
|
||||
+ if (len < sizeof(dinfo))
|
||||
+ return false;
|
||||
+ if (umove_or_printaddr(tcp, addr, &dinfo))
|
||||
+ return true;
|
||||
+
|
||||
+ PRINT_FIELD_U("{", dinfo, linkid);
|
||||
+ PRINT_FIELD_X(", ", dinfo, peer_gid);
|
||||
+ PRINT_FIELD_X(", ", dinfo, my_gid);
|
||||
+ PRINT_FIELD_X(", ", dinfo, token);
|
||||
+ PRINT_FIELD_X(", ", dinfo, peer_token);
|
||||
+ tprints("}");
|
||||
+
|
||||
+ return true;
|
||||
+}
|
||||
+
|
||||
static const nla_decoder_t smc_diag_msg_nla_decoders[] = {
|
||||
[SMC_DIAG_CONNINFO] = decode_smc_diag_conninfo,
|
||||
[SMC_DIAG_LGRINFO] = decode_smc_diag_lgrinfo,
|
||||
- [SMC_DIAG_SHUTDOWN] = decode_nla_u8
|
||||
+ [SMC_DIAG_SHUTDOWN] = decode_nla_u8,
|
||||
+ [SMC_DIAG_DMBINFO] = decode_smc_diag_dmbinfo,
|
||||
};
|
||||
|
||||
DECL_NETLINK_DIAG_DECODER(decode_smc_diag_msg)
|
||||
diff --git a/xlat/smc_diag_attrs.in b/xlat/smc_diag_attrs.in
|
||||
index cd6179b..023f398 100644
|
||||
--- a/xlat/smc_diag_attrs.in
|
||||
+++ b/xlat/smc_diag_attrs.in
|
||||
@@ -3,3 +3,4 @@ SMC_DIAG_NONE
|
||||
SMC_DIAG_CONNINFO
|
||||
SMC_DIAG_LGRINFO
|
||||
SMC_DIAG_SHUTDOWN
|
||||
+SMC_DIAG_DMBINFO
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
41
ptrace_restart-do-not-print-diagnostics-when-ptrace-.patch
Normal file
41
ptrace_restart-do-not-print-diagnostics-when-ptrace-.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From e0632590bdc041ef937ecf0491d6cd1504dec36f Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 11 Feb 2019 00:57:38 +0100
|
||||
Subject: [PATCH 227/293] ptrace_restart: do not print diagnostics when ptrace
|
||||
returns ESRCH
|
||||
|
||||
After some discussion, it was decided that the situation
|
||||
when the tracee is gone does not worth reporting.
|
||||
|
||||
* strace.c (ptrace_restart): Return early if ptrace returned ESRCH.
|
||||
|
||||
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1662936
|
||||
---
|
||||
strace.c | 4 +---
|
||||
1 file changed, 1 insertion(+), 3 deletions(-)
|
||||
|
||||
diff --git a/strace.c b/strace.c
|
||||
index e083cc3..ce89d5c 100644
|
||||
--- a/strace.c
|
||||
+++ b/strace.c
|
||||
@@ -366,7 +366,7 @@ ptrace_restart(const unsigned int op, struct tcb *const tcp, unsigned int sig)
|
||||
errno = 0;
|
||||
ptrace(op, tcp->pid, 0L, (unsigned long) sig);
|
||||
err = errno;
|
||||
- if (!err)
|
||||
+ if (!err || err == ESRCH)
|
||||
return 0;
|
||||
|
||||
/*
|
||||
@@ -383,8 +383,6 @@ ptrace_restart(const unsigned int op, struct tcb *const tcp, unsigned int sig)
|
||||
tcp->pid, ptrace_op_str(op), strerror(err));
|
||||
line_ended();
|
||||
}
|
||||
- if (err == ESRCH)
|
||||
- return 0;
|
||||
errno = err;
|
||||
perror_msg("ptrace(%s,pid:%d,sig:%u)",
|
||||
ptrace_op_str(op), tcp->pid, sig);
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
98
ptrace_restart-use-xlat-based-approach-for-printing-.patch
Normal file
98
ptrace_restart-use-xlat-based-approach-for-printing-.patch
Normal file
@ -0,0 +1,98 @@
|
||||
From 4bdfb2f2f58e90ddde8144c740882f393b341026 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 11 Feb 2019 00:45:37 +0100
|
||||
Subject: [PATCH 226/293] ptrace_restart: use xlat-based approach for printing
|
||||
ptrace requests
|
||||
|
||||
* defs.h (ptrace_cmds): New prototype.
|
||||
* strace.c (ptrace_op_str): New function.
|
||||
(ptrace_restart): Use it.
|
||||
---
|
||||
defs.h | 1 +
|
||||
strace.c | 32 +++++++++++++++-----------------
|
||||
2 files changed, 16 insertions(+), 17 deletions(-)
|
||||
|
||||
diff --git a/defs.h b/defs.h
|
||||
index ca1c39c..53f30f2 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -329,6 +329,7 @@ extern const struct xlat nl_netfilter_msg_types[];
|
||||
extern const struct xlat nl_route_types[];
|
||||
extern const struct xlat open_access_modes[];
|
||||
extern const struct xlat open_mode_flags[];
|
||||
+extern const struct xlat ptrace_cmds[];
|
||||
extern const struct xlat resource_flags[];
|
||||
extern const struct xlat routing_scopes[];
|
||||
extern const struct xlat routing_table_ids[];
|
||||
diff --git a/strace.c b/strace.c
|
||||
index 246eb0c..e083cc3 100644
|
||||
--- a/strace.c
|
||||
+++ b/strace.c
|
||||
@@ -339,6 +339,18 @@ ptrace_attach_or_seize(int pid)
|
||||
return ptrace_attach_cmd = "PTRACE_INTERRUPT", r;
|
||||
}
|
||||
|
||||
+static const char *
|
||||
+ptrace_op_str(unsigned int op)
|
||||
+{
|
||||
+ const char *str = xlookup(ptrace_cmds, op);
|
||||
+ if (str)
|
||||
+ return str;
|
||||
+
|
||||
+ static char buf[sizeof(op) * 3];
|
||||
+ xsprintf(buf, "%u", op);
|
||||
+ return buf;
|
||||
+}
|
||||
+
|
||||
/*
|
||||
* Used when we want to unblock stopped traced process.
|
||||
* Should be only used with PTRACE_CONT, PTRACE_DETACH and PTRACE_SYSCALL.
|
||||
@@ -350,7 +362,6 @@ static int
|
||||
ptrace_restart(const unsigned int op, struct tcb *const tcp, unsigned int sig)
|
||||
{
|
||||
int err;
|
||||
- const char *msg;
|
||||
|
||||
errno = 0;
|
||||
ptrace(op, tcp->pid, 0L, (unsigned long) sig);
|
||||
@@ -358,20 +369,6 @@ ptrace_restart(const unsigned int op, struct tcb *const tcp, unsigned int sig)
|
||||
if (!err)
|
||||
return 0;
|
||||
|
||||
- switch (op) {
|
||||
- case PTRACE_CONT:
|
||||
- msg = "CONT";
|
||||
- break;
|
||||
- case PTRACE_DETACH:
|
||||
- msg = "DETACH";
|
||||
- break;
|
||||
- case PTRACE_LISTEN:
|
||||
- msg = "LISTEN";
|
||||
- break;
|
||||
- default:
|
||||
- msg = "SYSCALL";
|
||||
- }
|
||||
-
|
||||
/*
|
||||
* Why curcol != 0? Otherwise sometimes we get this:
|
||||
*
|
||||
@@ -383,13 +380,14 @@ ptrace_restart(const unsigned int op, struct tcb *const tcp, unsigned int sig)
|
||||
*/
|
||||
if (current_tcp && current_tcp->curcol != 0) {
|
||||
tprintf(" <Cannot restart pid %d with ptrace(%s): %s>\n",
|
||||
- tcp->pid, msg, strerror(err));
|
||||
+ tcp->pid, ptrace_op_str(op), strerror(err));
|
||||
line_ended();
|
||||
}
|
||||
if (err == ESRCH)
|
||||
return 0;
|
||||
errno = err;
|
||||
- perror_msg("ptrace(PTRACE_%s,pid:%d,sig:%u)", msg, tcp->pid, sig);
|
||||
+ perror_msg("ptrace(%s,pid:%d,sig:%u)",
|
||||
+ ptrace_op_str(op), tcp->pid, sig);
|
||||
return -1;
|
||||
}
|
||||
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
42
rtnl_link-add-IFLA_BRPORT_BACKUP_PORT-attribute.patch
Normal file
42
rtnl_link-add-IFLA_BRPORT_BACKUP_PORT-attribute.patch
Normal file
@ -0,0 +1,42 @@
|
||||
From 701fd04d8a992bb9bbdba6ee18c7057c1d5c4674 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 11:47:11 +0200
|
||||
Subject: [PATCH 028/293] rtnl_link: add IFLA_BRPORT_BACKUP_PORT attribute
|
||||
|
||||
Introduced by Linux commit v4.19-rc1~140^2~288^2.
|
||||
|
||||
* xlat/rtnl_ifla_brport_attrs.in (IFLA_BRPORT_BACKUP_PORT): New
|
||||
constant.
|
||||
* rtnl_link.c (ifla_brport_nla_decoders) <[IFLA_BRPORT_BACKUP_PORT]>:
|
||||
New decoder.
|
||||
---
|
||||
rtnl_link.c | 3 ++-
|
||||
xlat/rtnl_ifla_brport_attrs.in | 1 +
|
||||
2 files changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/rtnl_link.c b/rtnl_link.c
|
||||
index 2421088..67ac7d1 100644
|
||||
--- a/rtnl_link.c
|
||||
+++ b/rtnl_link.c
|
||||
@@ -171,7 +171,8 @@ static const nla_decoder_t ifla_brport_nla_decoders[] = {
|
||||
[IFLA_BRPORT_BCAST_FLOOD] = decode_nla_u8,
|
||||
[IFLA_BRPORT_GROUP_FWD_MASK] = decode_nla_u16,
|
||||
[IFLA_BRPORT_NEIGH_SUPPRESS] = decode_nla_u8,
|
||||
- [IFLA_BRPORT_ISOLATED] = decode_nla_u8
|
||||
+ [IFLA_BRPORT_ISOLATED] = decode_nla_u8,
|
||||
+ [IFLA_BRPORT_BACKUP_PORT] = decode_nla_ifindex,
|
||||
};
|
||||
|
||||
static bool
|
||||
diff --git a/xlat/rtnl_ifla_brport_attrs.in b/xlat/rtnl_ifla_brport_attrs.in
|
||||
index 74c8841..7017716 100644
|
||||
--- a/xlat/rtnl_ifla_brport_attrs.in
|
||||
+++ b/xlat/rtnl_ifla_brport_attrs.in
|
||||
@@ -32,3 +32,4 @@ IFLA_BRPORT_BCAST_FLOOD 30
|
||||
IFLA_BRPORT_GROUP_FWD_MASK 31
|
||||
IFLA_BRPORT_NEIGH_SUPPRESS 32
|
||||
IFLA_BRPORT_ISOLATED 33
|
||||
+IFLA_BRPORT_BACKUP_PORT 34
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
42
rtnl_link-add-IFLA_MIN_MTU-and-IFLA_MAX_MTU-attribut.patch
Normal file
42
rtnl_link-add-IFLA_MIN_MTU-and-IFLA_MAX_MTU-attribut.patch
Normal file
@ -0,0 +1,42 @@
|
||||
From 24535be245597cef39e9e26ae963df199f25a45d Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:31:11 +0200
|
||||
Subject: [PATCH 035/293] rtnl_link: add IFLA_MIN_MTU and IFLA_MAX_MTU
|
||||
attributes
|
||||
|
||||
Introduced by Linux commit v4.19-rc1~140^2~205^2~1.
|
||||
|
||||
* rtnl_link.c (ifinfomsg_nla_decoders) <[IFLA_MIN_MTU], [IFLA_MAX_MTU]>:
|
||||
New decoder, calls decode_nla_u32.
|
||||
* xlat/rtnl_link_attrs.in (IFLA_MIN_MTU, IFLA_MAX_MTU): New constant.
|
||||
---
|
||||
rtnl_link.c | 2 ++
|
||||
xlat/rtnl_link_attrs.in | 2 ++
|
||||
2 files changed, 4 insertions(+)
|
||||
|
||||
diff --git a/rtnl_link.c b/rtnl_link.c
|
||||
index 67ac7d1..41c5efb 100644
|
||||
--- a/rtnl_link.c
|
||||
+++ b/rtnl_link.c
|
||||
@@ -903,6 +903,8 @@ static const nla_decoder_t ifinfomsg_nla_decoders[] = {
|
||||
[IFLA_CARRIER_UP_COUNT] = decode_nla_u32,
|
||||
[IFLA_CARRIER_DOWN_COUNT] = decode_nla_u32,
|
||||
[IFLA_NEW_IFINDEX] = decode_nla_ifindex,
|
||||
+ [IFLA_MIN_MTU] = decode_nla_u32,
|
||||
+ [IFLA_MAX_MTU] = decode_nla_u32,
|
||||
};
|
||||
|
||||
DECL_NETLINK_ROUTE_DECODER(decode_ifinfomsg)
|
||||
diff --git a/xlat/rtnl_link_attrs.in b/xlat/rtnl_link_attrs.in
|
||||
index 9ba08ad..1c0fa2d 100644
|
||||
--- a/xlat/rtnl_link_attrs.in
|
||||
+++ b/xlat/rtnl_link_attrs.in
|
||||
@@ -48,3 +48,5 @@ IFLA_IF_NETNSID 46
|
||||
IFLA_CARRIER_UP_COUNT 47
|
||||
IFLA_CARRIER_DOWN_COUNT 48
|
||||
IFLA_NEW_IFINDEX 49
|
||||
+IFLA_MIN_MTU 50
|
||||
+IFLA_MAX_MTU 51
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
101
rtnl_link-add-new-IFLA_XDP_-attributes.patch
Normal file
101
rtnl_link-add-new-IFLA_XDP_-attributes.patch
Normal file
@ -0,0 +1,101 @@
|
||||
From eded21f5c020cb5cdbf10dadf818746ca094a48a Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 11:14:27 +0200
|
||||
Subject: [PATCH 024/293] rtnl_link: add new IFLA_XDP_* attributes
|
||||
|
||||
Introduced by Linux commit v4.19-rc1~140^2~364^2~6^2~6.
|
||||
|
||||
* xlat/rtnl_ifla_xdp_attrs.in (IFLA_XDP_DRV_PROG_ID,
|
||||
IFLA_XDP_SKB_PROG_ID, IFLA_XDP_HW_PROG_ID): New constants.
|
||||
* rtnl_link.c (ifla_xdp_nla_decoders): Add decoders for
|
||||
IFLA_XDP_DRV_PROG_ID, IFLA_XDP_SKB_PROG_ID, and IFLA_XDP_HW_PROG_ID.
|
||||
* tests/nlattr_ifla_xdp.c: Add checks for new attributes.
|
||||
---
|
||||
rtnl_link.c | 5 ++++-
|
||||
tests/nlattr_ifla_xdp.c | 35 +++++++++++++++++++++++++++++++++++
|
||||
xlat/rtnl_ifla_xdp_attrs.in | 3 +++
|
||||
3 files changed, 42 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/rtnl_link.c b/rtnl_link.c
|
||||
index 1fbfd26..6f63d7f 100644
|
||||
--- a/rtnl_link.c
|
||||
+++ b/rtnl_link.c
|
||||
@@ -578,7 +578,10 @@ static const nla_decoder_t ifla_xdp_nla_decoders[] = {
|
||||
[IFLA_XDP_FD] = decode_nla_fd,
|
||||
[IFLA_XDP_ATTACHED] = decode_nla_u8,
|
||||
[IFLA_XDP_FLAGS] = decode_ifla_xdp_flags,
|
||||
- [IFLA_XDP_PROG_ID] = decode_nla_u32
|
||||
+ [IFLA_XDP_PROG_ID] = decode_nla_u32,
|
||||
+ [IFLA_XDP_DRV_PROG_ID] = decode_nla_u32,
|
||||
+ [IFLA_XDP_SKB_PROG_ID] = decode_nla_u32,
|
||||
+ [IFLA_XDP_HW_PROG_ID] = decode_nla_u32,
|
||||
};
|
||||
|
||||
static bool
|
||||
diff --git a/tests/nlattr_ifla_xdp.c b/tests/nlattr_ifla_xdp.c
|
||||
index 93149fa..c98f8a3 100644
|
||||
--- a/tests/nlattr_ifla_xdp.c
|
||||
+++ b/tests/nlattr_ifla_xdp.c
|
||||
@@ -44,6 +44,22 @@ enum { IFLA_XDP = 43 };
|
||||
# define IFLA_XDP_FD 1
|
||||
#endif
|
||||
|
||||
+#ifndef IFLA_XDP_PROG_ID
|
||||
+# define IFLA_XDP_PROG_ID 4
|
||||
+#endif
|
||||
+
|
||||
+#ifndef IFLA_XDP_DRV_PROG_ID
|
||||
+# define IFLA_XDP_DRV_PROG_ID 5
|
||||
+#endif
|
||||
+
|
||||
+#ifndef IFLA_XDP_SKB_PROG_ID
|
||||
+# define IFLA_XDP_SKB_PROG_ID 6
|
||||
+#endif
|
||||
+
|
||||
+#ifndef IFLA_XDP_HW_PROG_ID
|
||||
+# define IFLA_XDP_HW_PROG_ID 7
|
||||
+#endif
|
||||
+
|
||||
#define IFLA_ATTR IFLA_XDP
|
||||
#include "nlattr_ifla.h"
|
||||
|
||||
@@ -73,6 +89,25 @@ main(void)
|
||||
printf("XDP_FLAGS_UPDATE_IF_NOEXIST"));
|
||||
#endif
|
||||
|
||||
+ static const struct {
|
||||
+ uint32_t val;
|
||||
+ const char *str;
|
||||
+ } attrs[] = {
|
||||
+ { ARG_STR(IFLA_XDP_PROG_ID) },
|
||||
+ { ARG_STR(IFLA_XDP_DRV_PROG_ID) },
|
||||
+ { ARG_STR(IFLA_XDP_SKB_PROG_ID) },
|
||||
+ { ARG_STR(IFLA_XDP_HW_PROG_ID) },
|
||||
+ };
|
||||
+
|
||||
+ for (size_t i = 0; i < ARRAY_SIZE(attrs); i++) {
|
||||
+ TEST_NESTED_NLATTR_OBJECT_EX_(fd, nlh0, hdrlen,
|
||||
+ init_ifinfomsg, print_ifinfomsg,
|
||||
+ attrs[i].val, attrs[i].str,
|
||||
+ pattern, num,
|
||||
+ print_quoted_hex, 1,
|
||||
+ printf("%u", num));
|
||||
+ }
|
||||
+
|
||||
puts("+++ exited with 0 +++");
|
||||
return 0;
|
||||
}
|
||||
diff --git a/xlat/rtnl_ifla_xdp_attrs.in b/xlat/rtnl_ifla_xdp_attrs.in
|
||||
index ef3f458..b12958f 100644
|
||||
--- a/xlat/rtnl_ifla_xdp_attrs.in
|
||||
+++ b/xlat/rtnl_ifla_xdp_attrs.in
|
||||
@@ -3,3 +3,6 @@ IFLA_XDP_FD 1
|
||||
IFLA_XDP_ATTACHED 2
|
||||
IFLA_XDP_FLAGS 3
|
||||
IFLA_XDP_PROG_ID 4
|
||||
+IFLA_XDP_DRV_PROG_ID 5
|
||||
+IFLA_XDP_SKB_PROG_ID 6
|
||||
+IFLA_XDP_HW_PROG_ID 7
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
129
rtnl_link-decode-named-constants-for-IFLA_XDP_ATTACH.patch
Normal file
129
rtnl_link-decode-named-constants-for-IFLA_XDP_ATTACH.patch
Normal file
@ -0,0 +1,129 @@
|
||||
From d029a5efd1e8bc5273473f0a7991a5d93f10f5cf Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 11:31:34 +0200
|
||||
Subject: [PATCH 025/293] rtnl_link: decode named constants for
|
||||
IFLA_XDP_ATTACHED attribute value
|
||||
|
||||
* xlat/rtnl_ifla_xdp_attached_mode.in: New file.
|
||||
* rtnl_link.c: Include "xlat/rtnl_ifla_xdp_attached_mode.h".
|
||||
(decode_ifla_xdp_attached): New function.
|
||||
(ifla_xdp_nla_decoders) <[IFLA_XDP_ATTACHED]>: Use
|
||||
decode_ifla_xdp_attached instead of decode_nla_u8.
|
||||
* tests/nlattr_ifla_xdp.c: Add checks for IFLA_XDP_ATTACHED decoding.
|
||||
---
|
||||
rtnl_link.c | 20 +++++++++++++++++++-
|
||||
tests/nlattr_ifla_xdp.c | 30 ++++++++++++++++++++++++++++++
|
||||
xlat/rtnl_ifla_xdp_attached_mode.in | 6 ++++++
|
||||
3 files changed, 55 insertions(+), 1 deletion(-)
|
||||
create mode 100644 xlat/rtnl_ifla_xdp_attached_mode.in
|
||||
|
||||
diff --git a/rtnl_link.c b/rtnl_link.c
|
||||
index 6f63d7f..2421088 100644
|
||||
--- a/rtnl_link.c
|
||||
+++ b/rtnl_link.c
|
||||
@@ -54,6 +54,7 @@
|
||||
#include "xlat/rtnl_ifla_info_data_tun_attrs.h"
|
||||
#include "xlat/rtnl_ifla_port_attrs.h"
|
||||
#include "xlat/rtnl_ifla_vf_port_attrs.h"
|
||||
+#include "xlat/rtnl_ifla_xdp_attached_mode.h"
|
||||
#include "xlat/rtnl_ifla_xdp_attrs.h"
|
||||
#include "xlat/rtnl_link_attrs.h"
|
||||
#include "xlat/snmp_icmp6_stats.h"
|
||||
@@ -574,9 +575,26 @@ decode_ifla_xdp_flags(struct tcb *const tcp,
|
||||
return true;
|
||||
}
|
||||
|
||||
+bool
|
||||
+decode_ifla_xdp_attached(struct tcb *const tcp,
|
||||
+ const kernel_ulong_t addr,
|
||||
+ const unsigned int len,
|
||||
+ const void *const opaque_data)
|
||||
+{
|
||||
+ const struct decode_nla_xlat_opts opts = {
|
||||
+ .xlat = rtnl_ifla_xdp_attached_mode,
|
||||
+ .xlat_size = ARRAY_SIZE(rtnl_ifla_xdp_attached_mode),
|
||||
+ .xt = XT_INDEXED,
|
||||
+ .dflt = "XDP_ATTACHED_???",
|
||||
+ .size = 1,
|
||||
+ };
|
||||
+
|
||||
+ return decode_nla_xval(tcp, addr, len, &opts);
|
||||
+}
|
||||
+
|
||||
static const nla_decoder_t ifla_xdp_nla_decoders[] = {
|
||||
[IFLA_XDP_FD] = decode_nla_fd,
|
||||
- [IFLA_XDP_ATTACHED] = decode_nla_u8,
|
||||
+ [IFLA_XDP_ATTACHED] = decode_ifla_xdp_attached,
|
||||
[IFLA_XDP_FLAGS] = decode_ifla_xdp_flags,
|
||||
[IFLA_XDP_PROG_ID] = decode_nla_u32,
|
||||
[IFLA_XDP_DRV_PROG_ID] = decode_nla_u32,
|
||||
diff --git a/tests/nlattr_ifla_xdp.c b/tests/nlattr_ifla_xdp.c
|
||||
index c98f8a3..a44b798 100644
|
||||
--- a/tests/nlattr_ifla_xdp.c
|
||||
+++ b/tests/nlattr_ifla_xdp.c
|
||||
@@ -44,6 +44,10 @@ enum { IFLA_XDP = 43 };
|
||||
# define IFLA_XDP_FD 1
|
||||
#endif
|
||||
|
||||
+#ifndef IFLA_XDP_ATTACHED
|
||||
+# define IFLA_XDP_ATTACHED 2
|
||||
+#endif
|
||||
+
|
||||
#ifndef IFLA_XDP_PROG_ID
|
||||
# define IFLA_XDP_PROG_ID 4
|
||||
#endif
|
||||
@@ -60,6 +64,14 @@ enum { IFLA_XDP = 43 };
|
||||
# define IFLA_XDP_HW_PROG_ID 7
|
||||
#endif
|
||||
|
||||
+#ifndef XDP_ATTACHED_NONE
|
||||
+# define XDP_ATTACHED_NONE 0
|
||||
+#endif
|
||||
+
|
||||
+#ifndef XDP_ATTACHED_MULTI
|
||||
+# define XDP_ATTACHED_MULTI 4
|
||||
+#endif
|
||||
+
|
||||
#define IFLA_ATTR IFLA_XDP
|
||||
#include "nlattr_ifla.h"
|
||||
|
||||
@@ -81,6 +93,24 @@ main(void)
|
||||
IFLA_XDP_FD, pattern, num,
|
||||
printf("%d", num));
|
||||
|
||||
+ static const struct {
|
||||
+ uint8_t val;
|
||||
+ const char *str;
|
||||
+ } attach_types[] = {
|
||||
+ { ARG_STR(XDP_ATTACHED_NONE) },
|
||||
+ { ARG_STR(XDP_ATTACHED_MULTI) },
|
||||
+ { ARG_STR(0x5) " /* XDP_ATTACHED_??? */" },
|
||||
+ { ARG_STR(0xfe) " /* XDP_ATTACHED_??? */" },
|
||||
+ };
|
||||
+
|
||||
+ for (size_t i = 0; i < ARRAY_SIZE(attach_types); i++) {
|
||||
+ TEST_NESTED_NLATTR_OBJECT(fd, nlh0, hdrlen,
|
||||
+ init_ifinfomsg, print_ifinfomsg,
|
||||
+ IFLA_XDP_ATTACHED, pattern,
|
||||
+ attach_types[i].val,
|
||||
+ printf("%s", attach_types[i].str));
|
||||
+ }
|
||||
+
|
||||
#ifdef XDP_FLAGS_UPDATE_IF_NOEXIST
|
||||
const uint32_t flags = XDP_FLAGS_UPDATE_IF_NOEXIST;
|
||||
TEST_NESTED_NLATTR_OBJECT(fd, nlh0, hdrlen,
|
||||
diff --git a/xlat/rtnl_ifla_xdp_attached_mode.in b/xlat/rtnl_ifla_xdp_attached_mode.in
|
||||
new file mode 100644
|
||||
index 0000000..f374230
|
||||
--- /dev/null
|
||||
+++ b/xlat/rtnl_ifla_xdp_attached_mode.in
|
||||
@@ -0,0 +1,6 @@
|
||||
+#value_indexed
|
||||
+XDP_ATTACHED_NONE 0
|
||||
+XDP_ATTACHED_DRV 1
|
||||
+XDP_ATTACHED_SKB 2
|
||||
+XDP_ATTACHED_HW 3
|
||||
+XDP_ATTACHED_MULTI 4
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
41
rtnl_netconf-add-NETCONFA_BC_FORWARDING-attribute.patch
Normal file
41
rtnl_netconf-add-NETCONFA_BC_FORWARDING-attribute.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From fb7c51690e8e62204c25c3ee205bd4dd0f78f1ed Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:29:06 +0200
|
||||
Subject: [PATCH 033/293] rtnl_netconf: add NETCONFA_BC_FORWARDING attribute
|
||||
|
||||
Introduced by Linux commit v4.19-rc1~140^2~208^2~1.
|
||||
|
||||
* rtnl_netconf.c (netconfmsg_nla_decoders) <[NETCONFA_BC_FORWARDING]>:
|
||||
New decoder, calls decode_nla_s32.
|
||||
* xlat/rtnl_netconf_attrs.in (NETCONFA_BC_FORWARDING): New constant.
|
||||
---
|
||||
rtnl_netconf.c | 3 ++-
|
||||
xlat/rtnl_netconf_attrs.in | 1 +
|
||||
2 files changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/rtnl_netconf.c b/rtnl_netconf.c
|
||||
index f01c543..9c750d4 100644
|
||||
--- a/rtnl_netconf.c
|
||||
+++ b/rtnl_netconf.c
|
||||
@@ -47,7 +47,8 @@ static const nla_decoder_t netconfmsg_nla_decoders[] = {
|
||||
[NETCONFA_MC_FORWARDING] = decode_nla_s32,
|
||||
[NETCONFA_PROXY_NEIGH] = decode_nla_s32,
|
||||
[NETCONFA_IGNORE_ROUTES_WITH_LINKDOWN] = decode_nla_s32,
|
||||
- [NETCONFA_INPUT] = decode_nla_s32
|
||||
+ [NETCONFA_INPUT] = decode_nla_s32,
|
||||
+ [NETCONFA_BC_FORWARDING] = decode_nla_s32,
|
||||
};
|
||||
|
||||
DECL_NETLINK_ROUTE_DECODER(decode_netconfmsg)
|
||||
diff --git a/xlat/rtnl_netconf_attrs.in b/xlat/rtnl_netconf_attrs.in
|
||||
index b376b78..285398f 100644
|
||||
--- a/xlat/rtnl_netconf_attrs.in
|
||||
+++ b/xlat/rtnl_netconf_attrs.in
|
||||
@@ -6,3 +6,4 @@ NETCONFA_MC_FORWARDING 4
|
||||
NETCONFA_PROXY_NEIGH 5
|
||||
NETCONFA_IGNORE_ROUTES_WITH_LINKDOWN 6
|
||||
NETCONFA_INPUT 7
|
||||
+NETCONFA_BC_FORWARDING 8
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
93
sockaddr-add-X.25-socket-address-decoding-support.patch
Normal file
93
sockaddr-add-X.25-socket-address-decoding-support.patch
Normal file
@ -0,0 +1,93 @@
|
||||
From da048e91a1d81fd609cee5422c3dc7440625c3f6 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 06:26:56 +0200
|
||||
Subject: [PATCH 069/293] sockaddr: add X.25 socket address decoding support
|
||||
|
||||
* sockaddr.c: Include <linux/x25.h>.
|
||||
(print_sockaddr_data_x25): New function.
|
||||
(sa_printers) <[AF_X25]>: New socket address handler.
|
||||
* tests/net-sockaddr.c (check_x25): New function.
|
||||
(main): Use it to check X.25 socket address decoding.
|
||||
---
|
||||
defs.h | 1 +
|
||||
print_fields.h | 6 ++++++
|
||||
sockaddr.c | 20 ++++++++++++++++++++
|
||||
3 files changed, 27 insertions(+)
|
||||
|
||||
diff --git a/defs.h b/defs.h
|
||||
index c4d271a..7f1e64d 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -892,6 +892,7 @@ extern bool
|
||||
decode_inet_addr(struct tcb *, kernel_ulong_t addr,
|
||||
unsigned int len, int family, const char *var_name);
|
||||
extern void print_ax25_addr(const void /* ax25_address */ *addr);
|
||||
+extern void print_x25_addr(const void /* struct x25_address */ *addr);
|
||||
extern const char *get_sockaddr_by_inode(struct tcb *, int fd, unsigned long inode);
|
||||
extern bool print_sockaddr_by_inode(struct tcb *, int fd, unsigned long inode);
|
||||
extern void print_dirfd(struct tcb *, int);
|
||||
diff --git a/print_fields.h b/print_fields.h
|
||||
index c52d0ac..eccd7ae 100644
|
||||
--- a/print_fields.h
|
||||
+++ b/print_fields.h
|
||||
@@ -189,6 +189,12 @@
|
||||
print_ax25_addr(&(where_).field_); \
|
||||
} while (0)
|
||||
|
||||
+#define PRINT_FIELD_X25_ADDR(prefix_, where_, field_) \
|
||||
+ do { \
|
||||
+ STRACE_PRINTF("%s%s=", (prefix_), #field_); \
|
||||
+ print_x25_addr(&(where_).field_); \
|
||||
+ } while (0)
|
||||
+
|
||||
#define PRINT_FIELD_NET_PORT(prefix_, where_, field_) \
|
||||
STRACE_PRINTF("%s%s=htons(%u)", (prefix_), #field_, \
|
||||
ntohs((where_).field_))
|
||||
diff --git a/sockaddr.c b/sockaddr.c
|
||||
index 970991b..cf60c32 100644
|
||||
--- a/sockaddr.c
|
||||
+++ b/sockaddr.c
|
||||
@@ -43,6 +43,7 @@
|
||||
#include <linux/if_packet.h>
|
||||
#include <linux/if_arp.h>
|
||||
#include <linux/if_ether.h>
|
||||
+#include <linux/x25.h>
|
||||
|
||||
#ifdef HAVE_NETIPX_IPX_H
|
||||
# include <netipx/ipx.h>
|
||||
@@ -365,6 +366,24 @@ print_sockaddr_data_ipx(const void *const buf, const int addrlen)
|
||||
PRINT_FIELD_0X("], ", *sa_ipx, sipx_type);
|
||||
}
|
||||
|
||||
+void
|
||||
+print_x25_addr(const void /* struct x25_address */ *addr_void)
|
||||
+{
|
||||
+ const struct x25_address *addr = addr_void;
|
||||
+
|
||||
+ tprints("{x25_addr=");
|
||||
+ print_quoted_cstring(addr->x25_addr, sizeof(addr->x25_addr));
|
||||
+ tprints("}");
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+print_sockaddr_data_x25(const void *const buf, const int addrlen)
|
||||
+{
|
||||
+ const struct sockaddr_x25 *const sa_x25 = buf;
|
||||
+
|
||||
+ PRINT_FIELD_X25_ADDR("", *sa_x25, sx25_addr);
|
||||
+}
|
||||
+
|
||||
static void
|
||||
print_sockaddr_data_nl(const void *const buf, const int addrlen)
|
||||
{
|
||||
@@ -587,6 +606,7 @@ static const struct {
|
||||
[AF_INET] = { print_sockaddr_data_in, sizeof(struct sockaddr_in) },
|
||||
[AF_AX25] = { print_sockaddr_data_ax25, sizeof(struct sockaddr_ax25) },
|
||||
[AF_IPX] = { print_sockaddr_data_ipx, sizeof(struct sockaddr_ipx) },
|
||||
+ [AF_X25] = { print_sockaddr_data_x25, sizeof(struct sockaddr_x25) },
|
||||
[AF_INET6] = { print_sockaddr_data_in6, SIN6_MIN_LEN },
|
||||
[AF_NETLINK] = { print_sockaddr_data_nl, SIZEOF_SA_FAMILY + 1 },
|
||||
[AF_PACKET] = { print_sockaddr_data_ll, sizeof(struct sockaddr_ll) },
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
237
sockaddr-decode-AX.25-socket-addresses.patch
Normal file
237
sockaddr-decode-AX.25-socket-addresses.patch
Normal file
@ -0,0 +1,237 @@
|
||||
From 92d020787fd5d55b3314b7ca54b0c5437c66d6c4 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 03:13:04 +0200
|
||||
Subject: [PATCH 067/293] sockaddr: decode AX.25 socket addresses
|
||||
|
||||
* defs.h (print_ax25_addr): New prototype.
|
||||
* print_fields.h (PRINT_FIELD_AX25_ADDR): New macro.
|
||||
* sockaddr.c: Include <linux/ax25.h>.
|
||||
(check_ax25_address, ax25_addr2str, print_ax25_addr_raw,
|
||||
print_ax25_addr, print_sockaddr_data_ax25): New functions.
|
||||
(sa_printers) <[AF_AX25]>: New printer.
|
||||
* tests/net-sockaddr.c (AX25_ADDR): New macro.
|
||||
(check_ax25): New function.
|
||||
(main): Use it to check AX.25 socket address decoding.
|
||||
---
|
||||
defs.h | 1 +
|
||||
print_fields.h | 6 ++
|
||||
sockaddr.c | 160 +++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
3 files changed, 167 insertions(+)
|
||||
|
||||
diff --git a/defs.h b/defs.h
|
||||
index ec96bf6..c4d271a 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -891,6 +891,7 @@ print_inet_addr(int af, const void *addr, unsigned int len, const char *var_name
|
||||
extern bool
|
||||
decode_inet_addr(struct tcb *, kernel_ulong_t addr,
|
||||
unsigned int len, int family, const char *var_name);
|
||||
+extern void print_ax25_addr(const void /* ax25_address */ *addr);
|
||||
extern const char *get_sockaddr_by_inode(struct tcb *, int fd, unsigned long inode);
|
||||
extern bool print_sockaddr_by_inode(struct tcb *, int fd, unsigned long inode);
|
||||
extern void print_dirfd(struct tcb *, int);
|
||||
diff --git a/print_fields.h b/print_fields.h
|
||||
index 936db02..c52d0ac 100644
|
||||
--- a/print_fields.h
|
||||
+++ b/print_fields.h
|
||||
@@ -183,6 +183,12 @@
|
||||
STRACE_PRINTF("%s%s=inet_addr(\"%s\")", (prefix_), #field_, \
|
||||
inet_ntoa((where_).field_))
|
||||
|
||||
+#define PRINT_FIELD_AX25_ADDR(prefix_, where_, field_) \
|
||||
+ do { \
|
||||
+ STRACE_PRINTF("%s%s=", (prefix_), #field_); \
|
||||
+ print_ax25_addr(&(where_).field_); \
|
||||
+ } while (0)
|
||||
+
|
||||
#define PRINT_FIELD_NET_PORT(prefix_, where_, field_) \
|
||||
STRACE_PRINTF("%s%s=htons(%u)", (prefix_), #field_, \
|
||||
ntohs((where_).field_))
|
||||
diff --git a/sockaddr.c b/sockaddr.c
|
||||
index 2cf149f..970991b 100644
|
||||
--- a/sockaddr.c
|
||||
+++ b/sockaddr.c
|
||||
@@ -39,6 +39,7 @@
|
||||
#include <arpa/inet.h>
|
||||
|
||||
#include "netlink.h"
|
||||
+#include <linux/ax25.h>
|
||||
#include <linux/if_packet.h>
|
||||
#include <linux/if_arp.h>
|
||||
#include <linux/if_ether.h>
|
||||
@@ -189,6 +190,164 @@ print_sockaddr_data_in6(const void *const buf, const int addrlen)
|
||||
PRINT_FIELD_U(", ", *sa_in6, sin6_scope_id);
|
||||
}
|
||||
|
||||
+/**
|
||||
+ * Check that we can print an AX.25 address in its native form, otherwise it
|
||||
+ * makes sense to print it in raw also (or in raw only).
|
||||
+ */
|
||||
+enum xlat_style
|
||||
+check_ax25_address(const ax25_address *addr)
|
||||
+{
|
||||
+ enum xlat_style ret = XLAT_STYLE_DEFAULT;
|
||||
+ bool space_seen = false;
|
||||
+ bool char_seen = false;
|
||||
+
|
||||
+ for (size_t i = 0; i < ARRAY_SIZE(addr->ax25_call) - 1; i++) {
|
||||
+ unsigned char c = addr->ax25_call[i];
|
||||
+
|
||||
+ /* The lowest bit should be zero */
|
||||
+ if (c & 1)
|
||||
+ ret = XLAT_STYLE_VERBOSE;
|
||||
+
|
||||
+ c >>= 1;
|
||||
+
|
||||
+ if (c == ' ')
|
||||
+ space_seen = true;
|
||||
+ else
|
||||
+ char_seen = true;
|
||||
+
|
||||
+ /* Sane address contains only numbers and uppercase letters */
|
||||
+ if ((c < '0' || c > '9') && (c < 'A' || c > 'Z') && c != ' ')
|
||||
+ ret = XLAT_STYLE_VERBOSE;
|
||||
+ if (c != ' ' && space_seen)
|
||||
+ ret = XLAT_STYLE_VERBOSE;
|
||||
+
|
||||
+ /* non-printable chars */
|
||||
+ if (c < ' ' || c > 0x7e
|
||||
+ /* characters used for printing comments */
|
||||
+ || c == '*' || c == '/')
|
||||
+ return XLAT_STYLE_RAW;
|
||||
+ }
|
||||
+
|
||||
+ if (addr->ax25_call[ARRAY_SIZE(addr->ax25_call) - 1] & ~0x1e)
|
||||
+ ret = XLAT_STYLE_VERBOSE;
|
||||
+
|
||||
+ if (!char_seen && addr->ax25_call[ARRAY_SIZE(addr->ax25_call) - 1])
|
||||
+ ret = XLAT_STYLE_VERBOSE;
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+/** Convert a (presumably) valid AX.25 to a string */
|
||||
+static const char *
|
||||
+ax25_addr2str(const ax25_address *addr)
|
||||
+{
|
||||
+ static char buf[ARRAY_SIZE(addr->ax25_call) + sizeof("-15")];
|
||||
+ char *p = buf;
|
||||
+ size_t end;
|
||||
+
|
||||
+ for (end = ARRAY_SIZE(addr->ax25_call) - 1; end; end--)
|
||||
+ if ((addr->ax25_call[end - 1] >> 1) != ' ')
|
||||
+ break;
|
||||
+
|
||||
+ for (size_t i = 0; i < end; i++)
|
||||
+ *p++ = ((unsigned char) addr->ax25_call[i]) >> 1;
|
||||
+
|
||||
+ *p++ = '-';
|
||||
+
|
||||
+ unsigned char ssid = (addr->ax25_call[ARRAY_SIZE(addr->ax25_call) - 1]
|
||||
+ >> 1) & 0xf;
|
||||
+
|
||||
+ if (ssid > 9) {
|
||||
+ *p++ = '1';
|
||||
+ ssid -= 10;
|
||||
+ }
|
||||
+
|
||||
+ *p++ = ssid + '0';
|
||||
+ *p = '\0';
|
||||
+
|
||||
+ if (buf[0] == '-' && buf[1] == '0')
|
||||
+ return "*";
|
||||
+
|
||||
+ return buf;
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+print_ax25_addr_raw(const ax25_address *addr)
|
||||
+{
|
||||
+ PRINT_FIELD_HEX_ARRAY("{", *addr, ax25_call);
|
||||
+ tprints("}");
|
||||
+}
|
||||
+
|
||||
+void
|
||||
+print_ax25_addr(const void /* ax25_address */ *addr_void)
|
||||
+{
|
||||
+ const ax25_address *addr = addr_void;
|
||||
+ enum xlat_style xs = check_ax25_address(addr);
|
||||
+
|
||||
+ if (xs == XLAT_STYLE_DEFAULT)
|
||||
+ xs = xlat_verbose(xlat_verbosity);
|
||||
+
|
||||
+ if (xs != XLAT_STYLE_ABBREV)
|
||||
+ print_ax25_addr_raw(addr);
|
||||
+
|
||||
+ if (xs == XLAT_STYLE_RAW)
|
||||
+ return;
|
||||
+
|
||||
+ const char *addr_str = ax25_addr2str(addr);
|
||||
+
|
||||
+ (xs == XLAT_STYLE_VERBOSE ? tprints_comment : tprints)(addr_str);
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+print_sockaddr_data_ax25(const void *const buf, const int addrlen)
|
||||
+{
|
||||
+ const struct full_sockaddr_ax25 *const sax25 = buf;
|
||||
+ size_t addrlen_us = MAX(addrlen, 0);
|
||||
+ bool full = sax25->fsa_ax25.sax25_ndigis ||
|
||||
+ (addrlen_us > sizeof(struct sockaddr_ax25));
|
||||
+
|
||||
+ if (full)
|
||||
+ tprints("fsa_ax25={");
|
||||
+
|
||||
+ tprints("sax25_call=");
|
||||
+ print_ax25_addr(&sax25->fsa_ax25.sax25_call);
|
||||
+ PRINT_FIELD_D(", ", sax25->fsa_ax25, sax25_ndigis);
|
||||
+
|
||||
+ if (!full)
|
||||
+ return;
|
||||
+
|
||||
+ tprints("}");
|
||||
+
|
||||
+ size_t has_digis = MIN((addrlen_us - sizeof(sax25->fsa_ax25))
|
||||
+ / sizeof(sax25->fsa_digipeater[0]),
|
||||
+ ARRAY_SIZE(sax25->fsa_digipeater));
|
||||
+ size_t want_digis = MIN(
|
||||
+ (unsigned int) MAX(sax25->fsa_ax25.sax25_ndigis, 0),
|
||||
+ ARRAY_SIZE(sax25->fsa_digipeater));
|
||||
+ size_t digis = MIN(has_digis, want_digis);
|
||||
+
|
||||
+ if (want_digis == 0)
|
||||
+ goto digis_end;
|
||||
+
|
||||
+ tprints(", fsa_digipeater=[");
|
||||
+ for (size_t i = 0; i < digis; i++) {
|
||||
+ if (i)
|
||||
+ tprints(", ");
|
||||
+
|
||||
+ print_ax25_addr(sax25->fsa_digipeater + i);
|
||||
+ }
|
||||
+
|
||||
+ if (want_digis > has_digis)
|
||||
+ tprintf("%s/* ??? */", digis ? ", " : "");
|
||||
+
|
||||
+ tprints("]");
|
||||
+
|
||||
+digis_end:
|
||||
+ if (addrlen_us > (has_digis * sizeof(sax25->fsa_digipeater[0])
|
||||
+ + sizeof(sax25->fsa_ax25)))
|
||||
+ tprints(", ...");
|
||||
+}
|
||||
+
|
||||
static void
|
||||
print_sockaddr_data_ipx(const void *const buf, const int addrlen)
|
||||
{
|
||||
@@ -426,6 +585,7 @@ static const struct {
|
||||
} sa_printers[] = {
|
||||
[AF_UNIX] = { print_sockaddr_data_un, SIZEOF_SA_FAMILY + 1 },
|
||||
[AF_INET] = { print_sockaddr_data_in, sizeof(struct sockaddr_in) },
|
||||
+ [AF_AX25] = { print_sockaddr_data_ax25, sizeof(struct sockaddr_ax25) },
|
||||
[AF_IPX] = { print_sockaddr_data_ipx, sizeof(struct sockaddr_ipx) },
|
||||
[AF_INET6] = { print_sockaddr_data_in6, SIN6_MIN_LEN },
|
||||
[AF_NETLINK] = { print_sockaddr_data_nl, SIZEOF_SA_FAMILY + 1 },
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
106
socketutils-add-more-IP-IPv6-transport-protocols.patch
Normal file
106
socketutils-add-more-IP-IPv6-transport-protocols.patch
Normal file
@ -0,0 +1,106 @@
|
||||
From 54fc755c56db517e911717fe40e995de5467adbb Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 12:46:34 +0200
|
||||
Subject: [PATCH 060/293] socketutils: add more IP/IPv6 transport protocols
|
||||
|
||||
* defs.h (sock_proto): Add SOCK_PROTO_UDPLITE, SOCK_PROTO_DCCP,
|
||||
SOCK_PROTO_SCTP, SOCK_PROTO_L2TP_IP, SOCK_PROTO_PING, SOCK_PROTO_RAW,
|
||||
SOCK_PROTO_UDPLITEv6, SOCK_PROTO_DCCPv6, SOCK_PROTO_L2TP_IPv6,
|
||||
SOCK_PROTO_SCTPv6, SOCK_PROTO_PINGv6, and SOCK_PROTO_RAWv6.
|
||||
* socketutils.c: Include "xlat/inet_protocols.h" in XLAT_MACROS_ONLY
|
||||
mode.
|
||||
(protocols): Add protocol descriptions for them.
|
||||
---
|
||||
defs.h | 14 +++++++++++++-
|
||||
socketutils.c | 33 +++++++++++++++++++++++++++++++++
|
||||
2 files changed, 46 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/defs.h b/defs.h
|
||||
index 78e2d9a..22ab197 100644
|
||||
--- a/defs.h
|
||||
+++ b/defs.h
|
||||
@@ -379,9 +379,21 @@ enum sock_proto {
|
||||
SOCK_PROTO_UNIX,
|
||||
SOCK_PROTO_TCP,
|
||||
SOCK_PROTO_UDP,
|
||||
+ SOCK_PROTO_UDPLITE,
|
||||
+ SOCK_PROTO_DCCP,
|
||||
+ SOCK_PROTO_SCTP,
|
||||
+ SOCK_PROTO_L2TP_IP,
|
||||
+ SOCK_PROTO_PING,
|
||||
+ SOCK_PROTO_RAW,
|
||||
SOCK_PROTO_TCPv6,
|
||||
SOCK_PROTO_UDPv6,
|
||||
- SOCK_PROTO_NETLINK
|
||||
+ SOCK_PROTO_UDPLITEv6,
|
||||
+ SOCK_PROTO_DCCPv6,
|
||||
+ SOCK_PROTO_L2TP_IPv6,
|
||||
+ SOCK_PROTO_SCTPv6,
|
||||
+ SOCK_PROTO_PINGv6,
|
||||
+ SOCK_PROTO_RAWv6,
|
||||
+ SOCK_PROTO_NETLINK,
|
||||
};
|
||||
extern enum sock_proto get_proto_by_name(const char *);
|
||||
|
||||
diff --git a/socketutils.c b/socketutils.c
|
||||
index ff02c2f..dd8451e 100644
|
||||
--- a/socketutils.c
|
||||
+++ b/socketutils.c
|
||||
@@ -48,6 +48,10 @@
|
||||
|
||||
#include "xstring.h"
|
||||
|
||||
+#define XLAT_MACROS_ONLY
|
||||
+# include "xlat/inet_protocols.h"
|
||||
+#undef XLAT_MACROS_ONLY
|
||||
+
|
||||
typedef struct {
|
||||
unsigned long inode;
|
||||
char *details;
|
||||
@@ -451,14 +455,43 @@ static const struct {
|
||||
int proto;
|
||||
} protocols[] = {
|
||||
[SOCK_PROTO_UNIX] = { "UNIX", unix_get, AF_UNIX},
|
||||
+ /*
|
||||
+ * inet_diag handlers are currently implemented only for TCP,
|
||||
+ * UDP(lite), SCTP, RAW, and DCCP, but we try to resolve it for all
|
||||
+ * protocols anyway, just in case.
|
||||
+ */
|
||||
[SOCK_PROTO_TCP] =
|
||||
{ "TCP", inet_get, AF_INET, IPPROTO_TCP },
|
||||
[SOCK_PROTO_UDP] =
|
||||
{ "UDP", inet_get, AF_INET, IPPROTO_UDP },
|
||||
+ [SOCK_PROTO_UDPLITE] =
|
||||
+ { "UDPLITE", inet_get, AF_INET, IPPROTO_UDPLITE },
|
||||
+ [SOCK_PROTO_DCCP] =
|
||||
+ { "DCCP", inet_get, AF_INET, IPPROTO_DCCP },
|
||||
+ [SOCK_PROTO_SCTP] =
|
||||
+ { "SCTP", inet_get, AF_INET, IPPROTO_SCTP },
|
||||
+ [SOCK_PROTO_L2TP_IP] =
|
||||
+ { "L2TP/IP", inet_get, AF_INET, IPPROTO_L2TP },
|
||||
+ [SOCK_PROTO_PING] =
|
||||
+ { "PING", inet_get, AF_INET, IPPROTO_ICMP },
|
||||
+ [SOCK_PROTO_RAW] =
|
||||
+ { "RAW", inet_get, AF_INET, IPPROTO_RAW },
|
||||
[SOCK_PROTO_TCPv6] =
|
||||
{ "TCPv6", inet_get, AF_INET6, IPPROTO_TCP },
|
||||
[SOCK_PROTO_UDPv6] =
|
||||
{ "UDPv6", inet_get, AF_INET6, IPPROTO_UDP },
|
||||
+ [SOCK_PROTO_UDPLITEv6] =
|
||||
+ { "UDPLITEv6", inet_get, AF_INET6, IPPROTO_UDPLITE },
|
||||
+ [SOCK_PROTO_DCCPv6] =
|
||||
+ { "DCCPv6", inet_get, AF_INET6, IPPROTO_DCCP },
|
||||
+ [SOCK_PROTO_SCTPv6] =
|
||||
+ { "SCTPv6", inet_get, AF_INET6, IPPROTO_SCTP },
|
||||
+ [SOCK_PROTO_L2TP_IPv6] =
|
||||
+ { "L2TP/IPv6", inet_get, AF_INET6, IPPROTO_L2TP },
|
||||
+ [SOCK_PROTO_PINGv6] =
|
||||
+ { "PINGv6", inet_get, AF_INET6, IPPROTO_ICMP },
|
||||
+ [SOCK_PROTO_RAWv6] =
|
||||
+ { "RAWv6", inet_get, AF_INET6, IPPROTO_RAW },
|
||||
[SOCK_PROTO_NETLINK] = { "NETLINK", netlink_get, AF_NETLINK },
|
||||
};
|
||||
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
131
socketutils-store-more-information-in-protocols-tabl.patch
Normal file
131
socketutils-store-more-information-in-protocols-tabl.patch
Normal file
@ -0,0 +1,131 @@
|
||||
From 7c08fe37a1144fa9ee00e44e3a0b4c0084e5924b Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 12:41:48 +0200
|
||||
Subject: [PATCH 059/293] socketutils: store more information in protocols
|
||||
table
|
||||
|
||||
This also allows getting rid of all these *_v[46]_get calls.
|
||||
|
||||
* socketutils.c (unix_get, inet_get, netlink_gen): Add family, protocol,
|
||||
and proto_name paramteres, use them where appropriate.
|
||||
(tcp_v4_get, udp_v4_get, tcp_v6_get, udp_v6_get): Remove.
|
||||
(protocols): Add family and proto fields to the structure, call inet_get
|
||||
for IP/IPv6 protocols.
|
||||
(get_sockaddr_by_inode_uncached): Update protocols->get calls.
|
||||
---
|
||||
socketutils.c | 67 ++++++++++++++++++++++++++---------------------------------
|
||||
1 file changed, 30 insertions(+), 37 deletions(-)
|
||||
|
||||
diff --git a/socketutils.c b/socketutils.c
|
||||
index a646b5b..ff02c2f 100644
|
||||
--- a/socketutils.c
|
||||
+++ b/socketutils.c
|
||||
@@ -412,11 +412,12 @@ netlink_parse_response(const void *data, const int data_len,
|
||||
}
|
||||
|
||||
static const char *
|
||||
-unix_get(struct tcb *tcp, const int fd, const unsigned long inode)
|
||||
+unix_get(struct tcb *tcp, const int fd, const int family, const int proto,
|
||||
+ const unsigned long inode, const char *name)
|
||||
{
|
||||
return unix_send_query(tcp, fd, inode)
|
||||
&& receive_responses(tcp, fd, inode, SOCK_DIAG_BY_FAMILY,
|
||||
- unix_parse_response, (void *) "UNIX")
|
||||
+ unix_parse_response, (void *) name)
|
||||
? get_sockaddr_by_inode_cached(inode) : NULL;
|
||||
}
|
||||
|
||||
@@ -431,48 +432,34 @@ inet_get(struct tcb *tcp, const int fd, const int family, const int protocol,
|
||||
}
|
||||
|
||||
static const char *
|
||||
-tcp_v4_get(struct tcb *tcp, const int fd, const unsigned long inode)
|
||||
-{
|
||||
- return inet_get(tcp, fd, AF_INET, IPPROTO_TCP, inode, "TCP");
|
||||
-}
|
||||
-
|
||||
-static const char *
|
||||
-udp_v4_get(struct tcb *tcp, const int fd, const unsigned long inode)
|
||||
-{
|
||||
- return inet_get(tcp, fd, AF_INET, IPPROTO_UDP, inode, "UDP");
|
||||
-}
|
||||
-
|
||||
-static const char *
|
||||
-tcp_v6_get(struct tcb *tcp, const int fd, const unsigned long inode)
|
||||
-{
|
||||
- return inet_get(tcp, fd, AF_INET6, IPPROTO_TCP, inode, "TCPv6");
|
||||
-}
|
||||
-
|
||||
-static const char *
|
||||
-udp_v6_get(struct tcb *tcp, const int fd, const unsigned long inode)
|
||||
-{
|
||||
- return inet_get(tcp, fd, AF_INET6, IPPROTO_UDP, inode, "UDPv6");
|
||||
-}
|
||||
-
|
||||
-static const char *
|
||||
-netlink_get(struct tcb *tcp, const int fd, const unsigned long inode)
|
||||
+netlink_get(struct tcb *tcp, const int fd, const int family, const int protocol,
|
||||
+ const unsigned long inode, const char *proto_name)
|
||||
{
|
||||
return netlink_send_query(tcp, fd, inode)
|
||||
&& receive_responses(tcp, fd, inode, SOCK_DIAG_BY_FAMILY,
|
||||
- netlink_parse_response, (void *) "NETLINK")
|
||||
+ netlink_parse_response,
|
||||
+ (void *) proto_name)
|
||||
? get_sockaddr_by_inode_cached(inode) : NULL;
|
||||
}
|
||||
|
||||
static const struct {
|
||||
const char *const name;
|
||||
- const char * (*const get)(struct tcb *, int, unsigned long);
|
||||
+ const char * (*const get)(struct tcb *, int fd, int family,
|
||||
+ int protocol, unsigned long inode,
|
||||
+ const char *proto_name);
|
||||
+ int family;
|
||||
+ int proto;
|
||||
} protocols[] = {
|
||||
- [SOCK_PROTO_UNIX] = { "UNIX", unix_get },
|
||||
- [SOCK_PROTO_TCP] = { "TCP", tcp_v4_get },
|
||||
- [SOCK_PROTO_UDP] = { "UDP", udp_v4_get },
|
||||
- [SOCK_PROTO_TCPv6] = { "TCPv6", tcp_v6_get },
|
||||
- [SOCK_PROTO_UDPv6] = { "UDPv6", udp_v6_get },
|
||||
- [SOCK_PROTO_NETLINK] = { "NETLINK", netlink_get }
|
||||
+ [SOCK_PROTO_UNIX] = { "UNIX", unix_get, AF_UNIX},
|
||||
+ [SOCK_PROTO_TCP] =
|
||||
+ { "TCP", inet_get, AF_INET, IPPROTO_TCP },
|
||||
+ [SOCK_PROTO_UDP] =
|
||||
+ { "UDP", inet_get, AF_INET, IPPROTO_UDP },
|
||||
+ [SOCK_PROTO_TCPv6] =
|
||||
+ { "TCPv6", inet_get, AF_INET6, IPPROTO_TCP },
|
||||
+ [SOCK_PROTO_UDPv6] =
|
||||
+ { "UDPv6", inet_get, AF_INET6, IPPROTO_UDP },
|
||||
+ [SOCK_PROTO_NETLINK] = { "NETLINK", netlink_get, AF_NETLINK },
|
||||
};
|
||||
|
||||
enum sock_proto
|
||||
@@ -501,14 +488,20 @@ get_sockaddr_by_inode_uncached(struct tcb *tcp, const unsigned long inode,
|
||||
const char *details = NULL;
|
||||
|
||||
if (proto != SOCK_PROTO_UNKNOWN) {
|
||||
- details = protocols[proto].get(tcp, fd, inode);
|
||||
+ details = protocols[proto].get(tcp, fd, protocols[proto].family,
|
||||
+ protocols[proto].proto, inode,
|
||||
+ protocols[proto].name);
|
||||
} else {
|
||||
unsigned int i;
|
||||
for (i = (unsigned int) SOCK_PROTO_UNKNOWN + 1;
|
||||
i < ARRAY_SIZE(protocols); ++i) {
|
||||
if (!protocols[i].get)
|
||||
continue;
|
||||
- details = protocols[i].get(tcp, fd, inode);
|
||||
+ details = protocols[i].get(tcp, fd,
|
||||
+ protocols[proto].family,
|
||||
+ protocols[proto].proto,
|
||||
+ inode,
|
||||
+ protocols[proto].name);
|
||||
if (details)
|
||||
break;
|
||||
}
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
BIN
strace-4.24.tar.xz
Normal file
BIN
strace-4.24.tar.xz
Normal file
Binary file not shown.
78
strace.patches
Normal file
78
strace.patches
Normal file
@ -0,0 +1,78 @@
|
||||
Patch6000: xlat-workaround-V4L2_CID_USER_IMX_BASE-Linux-kernel-.patch
|
||||
Patch6001: xlat-update-V4L2_CID_USER_-_BASE-constants.patch
|
||||
Patch6002: kvm-decode-the-argument-of-KVM_CHECK_EXTENSION.patch
|
||||
Patch6003: evdev-fix-decoding-of-bit-sets.patch
|
||||
Patch6004: evdev-fix-decoding-of-EVIOCGBIT-0.patch
|
||||
Patch6005: tests-check-decoding-of-successful-evdev-ioctl.patch
|
||||
Patch6006: tests-enhance-test-coverage-of-evdev-ioctl.patch
|
||||
Patch6007: xlat-fix-typo-in-smc_protocols.in.patch
|
||||
Patch6008: xlat-add-IN_MASK_CREATE-to-inotify_flags.in.patch
|
||||
Patch6009: xlat-add-SCTP_REUSE_PORT-to-sock_sctp_options.in.patch
|
||||
Patch6010: netlink_smc_diag-implement-SMC_DIAG_DMBINFO-decoding.patch
|
||||
Patch6011: xlat-add-SO_TXTIME-to-sock_options.in.patch
|
||||
Patch6012: xlat-update-v4l2_control_ids.in.patch
|
||||
Patch6013: rtnl_link-add-new-IFLA_XDP_-attributes.patch
|
||||
Patch6014: rtnl_link-decode-named-constants-for-IFLA_XDP_ATTACH.patch
|
||||
Patch6015: xlat-add-AUDIT_INTEGRITY_POLICY_RULE-to-nl_audit_typ.patch
|
||||
Patch6016: xlat-update-nt_descriptor_types.in.patch
|
||||
Patch6017: rtnl_link-add-IFLA_BRPORT_BACKUP_PORT-attribute.patch
|
||||
Patch6018: netlink_smc_diag-decode-smc_diag_msg.diag_fallback-c.patch
|
||||
Patch6019: xlat-update-v4l2_pix_fmts.in.patch
|
||||
Patch6020: netlink_smc_diag-add-SMC_DIAG_FALLBACK-attribute-sup.patch
|
||||
Patch6021: rtnl_netconf-add-NETCONFA_BC_FORWARDING-attribute.patch
|
||||
Patch6022: xlat-add-IPV4_DEVCONF_BC_FORWARDING-1-to-inet_devcon.patch
|
||||
Patch6023: rtnl_link-add-IFLA_MIN_MTU-and-IFLA_MAX_MTU-attribut.patch
|
||||
Patch6024: xlat-update-bpf_map_types.in.patch
|
||||
Patch6025: xlat-add-IPSTATS_MIB_REASM_OVERLAPS-to-snmp_ip_stats.patch
|
||||
Patch6026: xlat-add-BPF_PROG_TYPE_SK_REUSEPORT-to-bpf_prog_type.patch
|
||||
Patch6027: netlink_smc_diag-decode-SMC_DIAG_SHUTDOWN-attribute-.patch
|
||||
Patch6028: xlat-add-AF_XDP-to-addrfams.in.patch
|
||||
Patch6029: xlat-add-SOL_XDP-to-socketlayers.in.patch
|
||||
Patch6030: net-decode-SOL_XDP-socket-option-names.patch
|
||||
Patch6031: xlat-provide-fallback-values-to-route_nexthop_flags.patch
|
||||
Patch6032: xlat-provide-fallback-values-for-socktypes.patch
|
||||
Patch6033: xlat-provide-fallback-definitions-to-pollflags.patch
|
||||
Patch6034: xlat-provide-fallback-definitions-for-epollevents.patch
|
||||
Patch6035: socketutils-store-more-information-in-protocols-tabl.patch
|
||||
Patch6036: socketutils-add-more-IP-IPv6-transport-protocols.patch
|
||||
Patch6037: net-decode-AF_PACKET-protocols-in-socket-syscall.patch
|
||||
Patch6038: ioprio-move-constant-definitions-to-xlat.patch
|
||||
Patch6039: futex-recognise-FUTEX_BITSET_MATCH_ANY-bitmask.patch
|
||||
Patch6040: sockaddr-decode-AX.25-socket-addresses.patch
|
||||
Patch6041: net-add-support-for-AX.25-protocols-and-socket-optio.patch
|
||||
Patch6042: sockaddr-add-X.25-socket-address-decoding-support.patch
|
||||
Patch6043: netlink_packet_diag-assorted-decoding-fixes.patch
|
||||
Patch6044: xlat-update-resources.patch
|
||||
Patch6045: xlat-provide-fallback-definitions-for-open_access_mo.patch
|
||||
Patch6046: Print-stack-traces-on-signals.patch
|
||||
Patch6047: xlat-print-_IOC_NONE-in-symbolic-form-even-if-it-is-.patch
|
||||
Patch6048: Remove-redundant-VIDIOC_SUBDEV_-constants.patch
|
||||
Patch6049: Update-ioctl-entries-from-linux-v4.19.patch
|
||||
Patch6050: arm-sparc-sparc64-wire-up-io_pgetevents.patch
|
||||
Patch6051: tests-fix-build-with-recent-kernel-headers.patch
|
||||
Patch6052: Implement-decoding-of-NBD_-ioctl-commands.patch
|
||||
Patch6053: Add-support-for-dev-u-random-ioctls.patch
|
||||
Patch6054: net-enhance-decoding-of-getsockopt-SO_ERROR.patch
|
||||
Patch6055: xlat-update-siginfo_codes.patch
|
||||
Patch6056: xlat-add-FAN_ENABLE_AUDIT-and-FAN_REPORT_TID-to-fan_.patch
|
||||
Patch6057: xlat-add-SOL_CAN_-to-socketlayers.patch
|
||||
Patch6058: xlat-add-fallback-definitions-to-setsock_ipv6_option.patch
|
||||
Patch6059: xlat-add-TCP_CLOSE-to-netlink_states.patch
|
||||
Patch6060: xlat-update-neighbor_cache_entry_flags.patch
|
||||
Patch6061: xlat-update-kvm_cap.patch
|
||||
Patch6062: xlat-add-ABS_RESERVED-to-evdev_abs.patch
|
||||
Patch6063: xlat-add-PR_SPEC_INDIRECT_BRANCH-to-pr_spec_cmds.patch
|
||||
Patch6064: xlat-update-KERN_-constants.patch
|
||||
Patch6065: Make-inline-message-on-failed-restart-attempt-more-v.patch
|
||||
Patch6066: ptrace_restart-use-xlat-based-approach-for-printing-.patch
|
||||
Patch6067: ptrace_restart-do-not-print-diagnostics-when-ptrace-.patch
|
||||
Patch6068: tests-robustify-preadv2-pwritev2-test-against-odd-ke.patch
|
||||
Patch6069: Wire-up-rseq-syscall-on-architectures-that-use-gener.patch
|
||||
Patch6070: bpf-print-struct-bpf_prog_info.gpl_compatible.patch
|
||||
Patch6071: bpf-add-support-for-btf_-fields-in-BPF_MAP_CREATE.patch
|
||||
Patch6072: bpf-add-support-for-jited_ksyms-and-jited_func_lens-.patch
|
||||
Patch6073: bpf-implement-decoding-of-BPF_BTF_LOAD-command.patch
|
||||
Patch6074: bpf-implement-decoding-of-BPF_BTF_GET_FD_BY_ID-comma.patch
|
||||
Patch6075: bpf-implement-decoding-of-BPF_TASK_FD_QUERY-command.patch
|
||||
Patch6076: adapt-for-backport-patch.patch
|
||||
Patch6077: xlat_idx-do-not-issue-warnings-for-holes-in-indices.patch
|
||||
60
strace.spec
Normal file
60
strace.spec
Normal file
@ -0,0 +1,60 @@
|
||||
Name: strace
|
||||
Version: 4.24
|
||||
Release: 2
|
||||
Summary: The linux syscall tracer
|
||||
License: LGPLv2.1+
|
||||
URL: https://strace.io
|
||||
Source0: https://strace.io/files/%{version}/%{name}-%{version}.tar.xz
|
||||
Source1: strace.patches
|
||||
|
||||
%include %{SOURCE1}
|
||||
|
||||
#Dependency
|
||||
BuildRequires: gcc gzip pkgconfig(bluez)
|
||||
BuildRequires: elfutils-devel binutils-devel
|
||||
|
||||
%description
|
||||
strace is a diagnostic, debugging and instructional userspace utility
|
||||
for Linux. It is used to monitor and tamper with interactions between
|
||||
processes and the Linux kernel, which include system calls,signal deliveries,
|
||||
and changes of process state.
|
||||
|
||||
%package_help
|
||||
|
||||
#Build sections
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version} -p1
|
||||
|
||||
%build
|
||||
CFLAGS_FOR_BUILD="$RPM_OPT_FLAGS"; export CFLAGS_FOR_BUILD
|
||||
%configure --enable-mpers=check
|
||||
%make_build
|
||||
|
||||
%install
|
||||
%make_install
|
||||
|
||||
%check
|
||||
make %{?_smp_mflags} check
|
||||
|
||||
#Install and uninstall scripts
|
||||
%pre
|
||||
|
||||
%preun
|
||||
|
||||
%post
|
||||
|
||||
%postun
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc COPYING CREDITS ChangeLog ChangeLog-CVS NEWS README
|
||||
%{_bindir}/strace
|
||||
%{_bindir}/strace-log-merge
|
||||
%exclude %{_bindir}/strace-graph
|
||||
|
||||
%files help
|
||||
%{_mandir}/man1/*
|
||||
|
||||
%changelog
|
||||
* Wed Jul 18 2018 openEuler Buildteam <buildteam@openeuler.org> - 4.24-2
|
||||
- Package init
|
||||
333
tests-check-decoding-of-successful-evdev-ioctl.patch
Normal file
333
tests-check-decoding-of-successful-evdev-ioctl.patch
Normal file
@ -0,0 +1,333 @@
|
||||
From e286b9cbc0bd542bb441c5acb65fef5f58b71aef Mon Sep 17 00:00:00 2001
|
||||
From: Zhibin Li <08826794brmt@gmail.com>
|
||||
Date: Wed, 1 Aug 2018 17:54:35 +0800
|
||||
Subject: [PATCH 007/293] tests: check decoding of successful evdev ioctl
|
||||
|
||||
* tests/ioctl_evdev-success.c: New file.
|
||||
* tests/ioctl_evdev-success-v.c: Likewise.
|
||||
* tests/ioctl_evdev-success.test: New test.
|
||||
* tests/ioctl_evdev-success-v.test: Likewise.
|
||||
* tests/.gitignore: Add ioctl_evdev-success and ioctl_evdev-success-v.
|
||||
* tests/Makefile.am (check_PROGRAMS): Likewise.
|
||||
(DECODER_TESTS): Add the two tests mentioned above.
|
||||
---
|
||||
tests/Makefile.am | 4 +
|
||||
tests/ioctl_evdev-success-v.c | 2 +
|
||||
tests/ioctl_evdev-success-v.test | 13 +++
|
||||
tests/ioctl_evdev-success.c | 232 +++++++++++++++++++++++++++++++++++++++
|
||||
tests/ioctl_evdev-success.test | 13 +++
|
||||
6 files changed, 266 insertions(+)
|
||||
create mode 100644 tests/ioctl_evdev-success-v.c
|
||||
create mode 100755 tests/ioctl_evdev-success-v.test
|
||||
create mode 100644 tests/ioctl_evdev-success.c
|
||||
create mode 100755 tests/ioctl_evdev-success.test
|
||||
|
||||
diff --git a/tests/Makefile.am b/tests/Makefile.am
|
||||
index a2f3950..5bb580a 100644
|
||||
--- a/tests/Makefile.am
|
||||
+++ b/tests/Makefile.am
|
||||
@@ -118,6 +118,8 @@ check_PROGRAMS = $(PURE_EXECUTABLES) \
|
||||
int_0x80 \
|
||||
ioctl_dm-v \
|
||||
ioctl_evdev-v \
|
||||
+ ioctl_evdev-success \
|
||||
+ ioctl_evdev-success-v \
|
||||
ioctl_loop-nv \
|
||||
ioctl_loop-v \
|
||||
ioctl_nsfs \
|
||||
@@ -247,6 +249,8 @@ DECODER_TESTS = \
|
||||
futex.test \
|
||||
getuid.test \
|
||||
ioctl.test \
|
||||
+ ioctl_evdev-success.test \
|
||||
+ ioctl_evdev-success-v.test \
|
||||
ioctl_perf-success.test \
|
||||
ipc_msgbuf.test \
|
||||
kern_features-fault.test \
|
||||
diff --git a/tests/ioctl_evdev-success-v.c b/tests/ioctl_evdev-success-v.c
|
||||
new file mode 100644
|
||||
index 0000000..6fc3547
|
||||
--- /dev/null
|
||||
+++ b/tests/ioctl_evdev-success-v.c
|
||||
@@ -0,0 +1,2 @@
|
||||
+#define VERBOSE 1
|
||||
+#include "ioctl_evdev-success.c"
|
||||
diff --git a/tests/ioctl_evdev-success-v.test b/tests/ioctl_evdev-success-v.test
|
||||
new file mode 100755
|
||||
index 0000000..358d9a3
|
||||
--- /dev/null
|
||||
+++ b/tests/ioctl_evdev-success-v.test
|
||||
@@ -0,0 +1,13 @@
|
||||
+#!/bin/sh -efu
|
||||
+
|
||||
+. "${srcdir=.}/scno_tampering.sh"
|
||||
+
|
||||
+: ${IOCTL_INJECT_START=256}
|
||||
+: ${IOCTL_INJECT_RETVAL=8}
|
||||
+
|
||||
+run_prog
|
||||
+run_strace -a16 -v -e trace=ioctl \
|
||||
+ -e inject=ioctl:retval="${IOCTL_INJECT_RETVAL}":when="${IOCTL_INJECT_START}+" \
|
||||
+ ../ioctl_evdev-success-v "${IOCTL_INJECT_START}" "${IOCTL_INJECT_RETVAL}"> "$EXP"
|
||||
+grep -v '^ioctl([012][,<]' < "$LOG" > "$OUT"
|
||||
+match_diff "$OUT" "$EXP"
|
||||
diff --git a/tests/ioctl_evdev-success.c b/tests/ioctl_evdev-success.c
|
||||
new file mode 100644
|
||||
index 0000000..8c3f8f0
|
||||
--- /dev/null
|
||||
+++ b/tests/ioctl_evdev-success.c
|
||||
@@ -0,0 +1,232 @@
|
||||
+#include "tests.h"
|
||||
+
|
||||
+#ifdef HAVE_LINUX_INPUT_H
|
||||
+
|
||||
+# include <inttypes.h>
|
||||
+# include <stdio.h>
|
||||
+# include <stdlib.h>
|
||||
+# include <sys/ioctl.h>
|
||||
+# include <linux/input.h>
|
||||
+# include "print_fields.h"
|
||||
+
|
||||
+static const char *errstr;
|
||||
+
|
||||
+struct evdev_check {
|
||||
+ unsigned long cmd;
|
||||
+ const char *cmd_str;
|
||||
+ void *arg_ptr;
|
||||
+ void (*print_arg)(long rc, void *ptr, void *arg);
|
||||
+};
|
||||
+
|
||||
+static long
|
||||
+invoke_test_syscall(unsigned long cmd, void *p)
|
||||
+{
|
||||
+ long rc = ioctl(-1, cmd, p);
|
||||
+ errstr = sprintrc(rc);
|
||||
+ static char inj_errstr[4096];
|
||||
+
|
||||
+ snprintf(inj_errstr, sizeof(inj_errstr), "%s (INJECTED)", errstr);
|
||||
+ errstr = inj_errstr;
|
||||
+ return rc;
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+test_evdev(struct evdev_check *check, void *arg)
|
||||
+{
|
||||
+ long rc = invoke_test_syscall(check->cmd, check->arg_ptr);
|
||||
+ printf("ioctl(-1, %s, ", check->cmd_str);
|
||||
+ if (check->print_arg)
|
||||
+ check->print_arg(rc, check->arg_ptr, arg);
|
||||
+ else
|
||||
+ printf("%p", check->arg_ptr);
|
||||
+ printf(") = %s\n", errstr);
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+print_input_absinfo(long rc, void *ptr, void *arg)
|
||||
+{
|
||||
+ struct input_absinfo *absinfo = ptr;
|
||||
+
|
||||
+ if (rc < 0) {
|
||||
+ printf("%p", absinfo);
|
||||
+ return;
|
||||
+ }
|
||||
+ PRINT_FIELD_U("{", *absinfo, value);
|
||||
+ PRINT_FIELD_U(", ", *absinfo, minimum);
|
||||
+# if VERBOSE
|
||||
+ PRINT_FIELD_U(", ", *absinfo, maximum);
|
||||
+ PRINT_FIELD_U(", ", *absinfo, fuzz);
|
||||
+ PRINT_FIELD_U(", ", *absinfo, flat);
|
||||
+# ifdef HAVE_STRUCT_INPUT_ABSINFO_RESOLUTION
|
||||
+ PRINT_FIELD_U(", ", *absinfo, resolution);
|
||||
+# endif
|
||||
+# else
|
||||
+ printf(", ...");
|
||||
+# endif
|
||||
+ printf("}");
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+print_input_id(long rc, void *ptr, void *arg)
|
||||
+{
|
||||
+ struct input_id *id = ptr;
|
||||
+
|
||||
+ if (rc < 0) {
|
||||
+ printf("%p", id);
|
||||
+ return;
|
||||
+ }
|
||||
+ printf("{ID_BUS=%" PRIu16
|
||||
+ ", ID_VENDOR=%" PRIu16
|
||||
+ ", ID_PRODUCT=%" PRIu16
|
||||
+ ", ID_VERSION=%" PRIu16 "}",
|
||||
+ id->bustype, id->vendor, id->product, id->version);
|
||||
+}
|
||||
+
|
||||
+# ifdef EVIOCGMTSLOTS
|
||||
+static void
|
||||
+print_mtslots(long rc, void *ptr, void *arg)
|
||||
+{
|
||||
+ int *buffer = ptr;
|
||||
+ const char **str = arg;
|
||||
+ int num = atoi(*(str + 1));
|
||||
+
|
||||
+ if (rc < 0) {
|
||||
+ printf("%p", buffer);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ printf("{code=%s", *str);
|
||||
+ printf(", values=[");
|
||||
+ for (unsigned int i = 1; i <= (unsigned) num; i++)
|
||||
+ printf("%s%s", i > 1 ? ", " : "", *(str + i + 1));
|
||||
+ printf("]}");
|
||||
+}
|
||||
+# endif
|
||||
+
|
||||
+static void
|
||||
+print_getbit(long rc, void *ptr, void *arg)
|
||||
+{
|
||||
+ const char **str = arg;
|
||||
+ int num = atoi(*str);
|
||||
+
|
||||
+ if (rc < 0) {
|
||||
+ printf("%p", ptr);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ printf("[");
|
||||
+ printf("%s", *(str + 1));
|
||||
+ for (unsigned int i = 2; i <= (unsigned) num; i++) {
|
||||
+# if ! VERBOSE
|
||||
+ if (i > 4) {
|
||||
+ printf(", ...");
|
||||
+ break;
|
||||
+ }
|
||||
+# endif
|
||||
+ printf(", ");
|
||||
+ printf("%s", *(str + i));
|
||||
+ }
|
||||
+ printf("]");
|
||||
+}
|
||||
+
|
||||
+int
|
||||
+main(int argc, char **argv)
|
||||
+{
|
||||
+ unsigned long num_skip;
|
||||
+ long inject_retval;
|
||||
+ bool locked = false;
|
||||
+
|
||||
+ if (argc == 1)
|
||||
+ return 0;
|
||||
+
|
||||
+ if (argc < 3)
|
||||
+ error_msg_and_fail("Usage: %s NUM_SKIP INJECT_RETVAL", argv[0]);
|
||||
+
|
||||
+ num_skip = strtoul(argv[1], NULL, 0);
|
||||
+ inject_retval = strtol(argv[2], NULL, 0);
|
||||
+
|
||||
+ if (inject_retval < 0)
|
||||
+ error_msg_and_fail("Expected non-negative INJECT_RETVAL, "
|
||||
+ "but got %ld", inject_retval);
|
||||
+
|
||||
+ for (unsigned int i = 0; i < num_skip; i++) {
|
||||
+ long rc = ioctl(-1, EVIOCGID, NULL);
|
||||
+ printf("ioctl(-1, EVIOCGID, NULL) = %s%s\n",
|
||||
+ sprintrc(rc),
|
||||
+ rc == inject_retval ? " (INJECTED)" : "");
|
||||
+
|
||||
+ if (rc != inject_retval)
|
||||
+ continue;
|
||||
+
|
||||
+ locked = true;
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ if (!locked)
|
||||
+ error_msg_and_fail("Hasn't locked on ioctl(-1"
|
||||
+ ", EVIOCGID, NULL) returning %lu",
|
||||
+ inject_retval);
|
||||
+
|
||||
+ TAIL_ALLOC_OBJECT_CONST_PTR(struct input_id, id);
|
||||
+ TAIL_ALLOC_OBJECT_CONST_PTR(struct input_absinfo, absinfo);
|
||||
+ TAIL_ALLOC_OBJECT_CONST_PTR(int, bad_addr_slot);
|
||||
+# ifdef EVIOCGMTSLOTS
|
||||
+ int mtslots[] = { ABS_MT_SLOT, 1, 3 };
|
||||
+ /* we use the second element to indicate the number of values */
|
||||
+ /* mtslots_str[1] is "2" so the number of values is 2 */
|
||||
+ const char *mtslots_str[] = { "ABS_MT_SLOT", "2", "1", "3" };
|
||||
+
|
||||
+ /* invalid flag */
|
||||
+ int invalid_mtslot[] = { -1, 1 };
|
||||
+ char invalid_str[4096];
|
||||
+ snprintf(invalid_str, sizeof(invalid_str), "%#x /* ABS_MT_??? */", invalid_mtslot[0]);
|
||||
+ const char *invalid_mtslot_str[] = { invalid_str, "1", "1" };
|
||||
+# endif
|
||||
+
|
||||
+ /* set more than 4 bits */
|
||||
+ unsigned long ev_more[] = { 1 << EV_ABS | 1 << EV_MSC | 1 << EV_LED | 1 << EV_SND | 1 << EV_PWR };
|
||||
+ /* we use the first element to indicate the number of set bits */
|
||||
+ /* ev_more_str[0] is "5" so the number of set bits is 5 */
|
||||
+ const char *ev_more_str[] = { "5", "EV_ABS", "EV_MSC", "EV_LED", "EV_SND", "EV_PWR" };
|
||||
+
|
||||
+ /* set less than 4 bits */
|
||||
+ unsigned long ev_less[] = { 1 << EV_ABS | 1 << EV_MSC | 1 << EV_LED };
|
||||
+ const char *ev_less_str[] = { "3", "EV_ABS", "EV_MSC", "EV_LED" };
|
||||
+
|
||||
+ /* set zero bit */
|
||||
+ unsigned long ev_zero[] = { 0x0 };
|
||||
+ const char *ev_zero_str[] = { "0", " 0 " };
|
||||
+
|
||||
+ /* KEY_MAX is 0x2ff which is greater than retval * 8 */
|
||||
+ unsigned long key[] = { 1 << KEY_1 | 1 << KEY_2, 0 };
|
||||
+ const char *key_str[] = { "2", "KEY_1", "KEY_2" };
|
||||
+
|
||||
+ struct {
|
||||
+ struct evdev_check check;
|
||||
+ void *ptr;
|
||||
+ } a[] = {
|
||||
+ { { ARG_STR(EVIOCGID), id, print_input_id }, NULL },
|
||||
+ { { ARG_STR(EVIOCGABS(ABS_X)), absinfo, print_input_absinfo }, NULL },
|
||||
+ { { ARG_STR(EVIOCGABS(ABS_Y)), absinfo, print_input_absinfo }, NULL },
|
||||
+ { { ARG_STR(EVIOCGABS(ABS_Y)), absinfo, print_input_absinfo }, NULL },
|
||||
+ { { ARG_STR(EVIOCGBIT(0, 0)), ev_more, print_getbit }, &ev_more_str },
|
||||
+ { { ARG_STR(EVIOCGBIT(0, 0)), ev_less, print_getbit }, &ev_less_str },
|
||||
+ { { ARG_STR(EVIOCGBIT(0, 0)), ev_zero, print_getbit }, &ev_zero_str },
|
||||
+ { { ARG_STR(EVIOCGBIT(EV_KEY, 0)), key, print_getbit }, &key_str},
|
||||
+# ifdef EVIOCGMTSLOTS
|
||||
+ { { ARG_STR(EVIOCGMTSLOTS(12)), mtslots, print_mtslots }, &mtslots_str },
|
||||
+ { { ARG_STR(EVIOCGMTSLOTS(8)), invalid_mtslot, print_mtslots }, &invalid_mtslot_str }
|
||||
+# endif
|
||||
+ };
|
||||
+ for (unsigned int i = 0; i < ARRAY_SIZE(a); i++) {
|
||||
+ test_evdev(&a[i].check, a[i].ptr);
|
||||
+ }
|
||||
+
|
||||
+ puts("+++ exited with 0 +++");
|
||||
+ return 0;
|
||||
+}
|
||||
+#else
|
||||
+
|
||||
+SKIP_MAIN_UNDEFINED("HAVE_LINUX_INPUT_H")
|
||||
+
|
||||
+#endif
|
||||
diff --git a/tests/ioctl_evdev-success.test b/tests/ioctl_evdev-success.test
|
||||
new file mode 100755
|
||||
index 0000000..e735af9
|
||||
--- /dev/null
|
||||
+++ b/tests/ioctl_evdev-success.test
|
||||
@@ -0,0 +1,13 @@
|
||||
+#!/bin/sh -efu
|
||||
+
|
||||
+. "${srcdir=.}/scno_tampering.sh"
|
||||
+
|
||||
+: ${IOCTL_INJECT_START=256}
|
||||
+: ${IOCTL_INJECT_RETVAL=8}
|
||||
+
|
||||
+run_prog
|
||||
+run_strace -a16 -e trace=ioctl \
|
||||
+ -e inject=ioctl:retval="${IOCTL_INJECT_RETVAL}":when="${IOCTL_INJECT_START}+" \
|
||||
+ ../ioctl_evdev-success "${IOCTL_INJECT_START}" "${IOCTL_INJECT_RETVAL}"> "$EXP"
|
||||
+grep -v '^ioctl([012][,<]' < "$LOG" > "$OUT"
|
||||
+match_diff "$OUT" "$EXP"
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
25
tests-enhance-test-coverage-of-evdev-ioctl.patch
Normal file
25
tests-enhance-test-coverage-of-evdev-ioctl.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From ed29ac33bbe541cc10c51bef57cd76011df39e5d Mon Sep 17 00:00:00 2001
|
||||
From: Zhibin Li <08826794brmt@gmail.com>
|
||||
Date: Fri, 10 Aug 2018 20:17:38 +0800
|
||||
Subject: [PATCH 008/293] tests: enhance test coverage of evdev ioctl
|
||||
|
||||
* tests/ioctl_evdev.c (main): Test EVIOCGMTSLOTS(8) command.
|
||||
---
|
||||
tests/ioctl_evdev.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/tests/ioctl_evdev.c b/tests/ioctl_evdev.c
|
||||
index 071b6b0..d6f50ac 100644
|
||||
--- a/tests/ioctl_evdev.c
|
||||
+++ b/tests/ioctl_evdev.c
|
||||
@@ -114,6 +114,7 @@ main(void)
|
||||
TEST_NULL_ARG(EVIOCGLED(0));
|
||||
# ifdef EVIOCGMTSLOTS
|
||||
TEST_NULL_ARG(EVIOCGMTSLOTS(0));
|
||||
+ TEST_NULL_ARG(EVIOCGMTSLOTS(8));
|
||||
# endif
|
||||
# ifdef EVIOCGPROP
|
||||
TEST_NULL_ARG(EVIOCGPROP(0));
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
34
tests-fix-build-with-recent-kernel-headers.patch
Normal file
34
tests-fix-build-with-recent-kernel-headers.patch
Normal file
@ -0,0 +1,34 @@
|
||||
From 6d6d5bc4807a2c09784dfa3290aa0b4128a5183b Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Thu, 25 Oct 2018 13:36:54 +0000
|
||||
Subject: [PATCH 092/293] tests: fix build with recent kernel headers
|
||||
|
||||
Linux commit v4.19-rc2-5-g2ecefa0a15fd0ef88b9cd5d15ceb813008136431
|
||||
changed the definition of struct keyctl_dh_params in an incompatible
|
||||
way again. Workaround this issue by using designated initializers.
|
||||
|
||||
* tests/keyctl.c (main): Use designated initializers for
|
||||
struct keyctl_dh_params.
|
||||
---
|
||||
tests/keyctl.c | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tests/keyctl.c b/tests/keyctl.c
|
||||
index 881f24b..e53cdc4 100644
|
||||
--- a/tests/keyctl.c
|
||||
+++ b/tests/keyctl.c
|
||||
@@ -312,7 +312,10 @@ main(void)
|
||||
static const char *bogus_key3_str = "-557785390";
|
||||
|
||||
static const struct keyctl_dh_params kcdhp_data = {
|
||||
- KEY_SPEC_GROUP_KEYRING, 1234567890, 3141592653U };
|
||||
+ .private = KEY_SPEC_GROUP_KEYRING,
|
||||
+ .prime = 1234567890,
|
||||
+ .base = 3141592653U
|
||||
+ };
|
||||
static const char *kcdhp_str = "{private="
|
||||
#if XLAT_RAW || XLAT_VERBOSE
|
||||
"-6"
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
81
tests-robustify-preadv2-pwritev2-test-against-odd-ke.patch
Normal file
81
tests-robustify-preadv2-pwritev2-test-against-odd-ke.patch
Normal file
@ -0,0 +1,81 @@
|
||||
From 28030d2b51951be018d063b49e19972b45c81daf Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Mon, 11 Feb 2019 21:00:05 +0000
|
||||
Subject: [PATCH 228/293] tests: robustify preadv2-pwritev2 test against odd
|
||||
kernels
|
||||
|
||||
The test used to assume that either both preadv2 and pwritev2 syscalls
|
||||
are implemented or both are not implemented, but, apparently, there are
|
||||
kernels in the wild that implement just preadv2 syscall without
|
||||
pwritev2.
|
||||
|
||||
* tests/preadv2-pwritev2.c (main): Skip the dumpio part of the test
|
||||
if either preadv2 or pwritev2 syscall is not implemented.
|
||||
|
||||
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1668750
|
||||
---
|
||||
tests/preadv2-pwritev2.c | 31 ++++++++++++++++++++++++-------
|
||||
1 file changed, 24 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/tests/preadv2-pwritev2.c b/tests/preadv2-pwritev2.c
|
||||
index f0e6987..1dfd674 100644
|
||||
--- a/tests/preadv2-pwritev2.c
|
||||
+++ b/tests/preadv2-pwritev2.c
|
||||
@@ -186,7 +186,7 @@ main(void)
|
||||
const unsigned long long pos = 0x7ac5fed6dad7bef8;
|
||||
const kernel_ulong_t pos_l = (kernel_ulong_t) pos;
|
||||
long rc;
|
||||
- int test_dumpio;
|
||||
+ bool skip_dumpio_test = false;
|
||||
|
||||
tprintf("%s", "");
|
||||
|
||||
@@ -203,9 +203,17 @@ main(void)
|
||||
(kernel_ulong_t) (pos >> 32);
|
||||
rc = syscall(__NR_preadv2, -1, NULL, vlen, pos_l, pos_h, 1);
|
||||
#endif
|
||||
- if (rc != -1 || (ENOSYS != errno && EBADF != errno))
|
||||
- perror_msg_and_fail("preadv2");
|
||||
- test_dumpio = EBADF == errno;
|
||||
+ if (rc != -1)
|
||||
+ error_msg_and_fail("preadv2: expected -1, returned %ld", rc);
|
||||
+ switch (errno) {
|
||||
+ case ENOSYS:
|
||||
+ skip_dumpio_test = true;
|
||||
+ break;
|
||||
+ case EBADF:
|
||||
+ break;
|
||||
+ default:
|
||||
+ perror_msg_and_fail("preadv2");
|
||||
+ }
|
||||
tprintf("preadv2(-1, NULL, %lu, %lld, RWF_HIPRI) = %s\n",
|
||||
(unsigned long) vlen, pos, sprintrc(rc));
|
||||
|
||||
@@ -218,12 +226,21 @@ main(void)
|
||||
#else
|
||||
rc = syscall(__NR_pwritev2, -1, NULL, vlen, pos_l, pos_h, 1);
|
||||
#endif
|
||||
- if (rc != -1 || (ENOSYS != errno && EBADF != errno))
|
||||
- perror_msg_and_fail("pwritev2");
|
||||
+ if (rc != -1)
|
||||
+ error_msg_and_fail("pwritev2: expected -1, returned %ld", rc);
|
||||
+ switch (errno) {
|
||||
+ case ENOSYS:
|
||||
+ skip_dumpio_test = true;
|
||||
+ break;
|
||||
+ case EBADF:
|
||||
+ break;
|
||||
+ default:
|
||||
+ perror_msg_and_fail("pwritev2");
|
||||
+ }
|
||||
tprintf("pwritev2(-1, NULL, %lu, %lld, RWF_HIPRI) = %s\n",
|
||||
(unsigned long) vlen, pos, sprintrc(rc));
|
||||
|
||||
- if (test_dumpio)
|
||||
+ if (!skip_dumpio_test)
|
||||
dumpio();
|
||||
|
||||
tprintf("%s\n", "+++ exited with 0 +++");
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
28
xlat-add-ABS_RESERVED-to-evdev_abs.patch
Normal file
28
xlat-add-ABS_RESERVED-to-evdev_abs.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From 0954bf0ec84c356d95dac302d1e1922e5847b4f3 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Thu, 1 Nov 2018 18:10:06 +0100
|
||||
Subject: [PATCH 184/293] xlat: add ABS_RESERVED to evdev_abs
|
||||
|
||||
* xlat/evdev_abs.in (ABS_RESERVED): New constant, introduced by Linux
|
||||
commit v4.20-rc1~133^2~2^2.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
xlat/evdev_abs.in | 1 +
|
||||
2 files changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/xlat/evdev_abs.in b/xlat/evdev_abs.in
|
||||
index d65b846..e2d6900 100644
|
||||
--- a/xlat/evdev_abs.in
|
||||
+++ b/xlat/evdev_abs.in
|
||||
@@ -25,6 +25,7 @@ ABS_TILT_Y 0x1b
|
||||
ABS_TOOL_WIDTH 0x1c
|
||||
ABS_VOLUME 0x20
|
||||
ABS_MISC 0x28
|
||||
+ABS_RESERVED 0x2e
|
||||
ABS_MT_SLOT 0x2f
|
||||
ABS_MT_TOUCH_MAJOR 0x30
|
||||
ABS_MT_TOUCH_MINOR 0x31
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
23
xlat-add-AF_XDP-to-addrfams.in.patch
Normal file
23
xlat-add-AF_XDP-to-addrfams.in.patch
Normal file
@ -0,0 +1,23 @@
|
||||
From dac524ad9802f0fd55236ea36d153b62b4a96123 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 21:44:10 +0200
|
||||
Subject: [PATCH 043/293] xlat: add AF_XDP to addrfams.in
|
||||
|
||||
* xlat/addrfams.in (AF_XDP): New constant, introduced by Linux commit
|
||||
v4.18-rc1~114^2~304^2~4^2~14.
|
||||
---
|
||||
xlat/addrfams.in | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/xlat/addrfams.in b/xlat/addrfams.in
|
||||
index 5824c3b..e6a6232 100644
|
||||
--- a/xlat/addrfams.in
|
||||
+++ b/xlat/addrfams.in
|
||||
@@ -43,3 +43,4 @@ AF_VSOCK 40
|
||||
AF_KCM 41
|
||||
AF_QIPCRTR 42
|
||||
AF_SMC 43
|
||||
+AF_XDP 44
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
27
xlat-add-AUDIT_INTEGRITY_POLICY_RULE-to-nl_audit_typ.patch
Normal file
27
xlat-add-AUDIT_INTEGRITY_POLICY_RULE-to-nl_audit_typ.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From 6b141f643aa60fb9bd8ba1ad551a0e020c04555e Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 11:38:51 +0200
|
||||
Subject: [PATCH 026/293] xlat: add AUDIT_INTEGRITY_POLICY_RULE to
|
||||
nl_audit_types.in
|
||||
|
||||
* xlat/nl_audit_types.in (AUDIT_INTEGRITY_POLICY_RULE): New constant,
|
||||
introduced by Linux commit v4.19-rc1~124^2~5.
|
||||
---
|
||||
xlat/nl_audit_types.in | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/xlat/nl_audit_types.in b/xlat/nl_audit_types.in
|
||||
index a9d7622..afba5cd 100644
|
||||
--- a/xlat/nl_audit_types.in
|
||||
+++ b/xlat/nl_audit_types.in
|
||||
@@ -109,6 +109,7 @@ AUDIT_INTEGRITY_HASH 1803
|
||||
AUDIT_INTEGRITY_PCR 1804
|
||||
AUDIT_INTEGRITY_RULE 1805
|
||||
AUDIT_INTEGRITY_EVM_XATTR 1806
|
||||
+AUDIT_INTEGRITY_POLICY_RULE 1807
|
||||
|
||||
AUDIT_KERNEL 2000
|
||||
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
25
xlat-add-BPF_PROG_TYPE_SK_REUSEPORT-to-bpf_prog_type.patch
Normal file
25
xlat-add-BPF_PROG_TYPE_SK_REUSEPORT-to-bpf_prog_type.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From 6e7da522869a7ff5f4f2880390723f996a526300 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:46:26 +0200
|
||||
Subject: [PATCH 038/293] xlat: add BPF_PROG_TYPE_SK_REUSEPORT to
|
||||
bpf_prog_types.in
|
||||
|
||||
* xlat/bpf_prog_types.in (BPF_PROG_TYPE_SK_REUSEPORT): New constant,
|
||||
introduced by Linux commit v4.19-rc1~140^2~24^2~2^2~5.
|
||||
* tests/bpf.c: Update expected output.
|
||||
---
|
||||
xlat/bpf_prog_types.in | 1 +
|
||||
1 files changed, 1 insertions(+)
|
||||
|
||||
diff --git a/xlat/bpf_prog_types.in b/xlat/bpf_prog_types.in
|
||||
index 77b864e..d32ca7f 100644
|
||||
--- a/xlat/bpf_prog_types.in
|
||||
+++ b/xlat/bpf_prog_types.in
|
||||
@@ -19,3 +19,4 @@ BPF_PROG_TYPE_SK_MSG 16
|
||||
BPF_PROG_TYPE_RAW_TRACEPOINT 17
|
||||
BPF_PROG_TYPE_LWT_SEG6LOCAL 18
|
||||
BPF_PROG_TYPE_LIRC_MODE2 19
|
||||
+BPF_PROG_TYPE_SK_REUSEPORT 20
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
31
xlat-add-FAN_ENABLE_AUDIT-and-FAN_REPORT_TID-to-fan_.patch
Normal file
31
xlat-add-FAN_ENABLE_AUDIT-and-FAN_REPORT_TID-to-fan_.patch
Normal file
@ -0,0 +1,31 @@
|
||||
From 5be335ceaac0390ecf6bf72c933cecc1e78c546d Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Tue, 11 Sep 2018 01:45:30 +0200
|
||||
Subject: [PATCH 172/293] xlat: add FAN_ENABLE_AUDIT and FAN_REPORT_TID to
|
||||
fan_init_flags
|
||||
|
||||
* xlat/fan_init_flags.in (FAN_ENABLE_AUDIT): New constant, introduced
|
||||
by Linux commit v4.15-rc1~130^2^2~11.
|
||||
(FAN_REPORT_TID): New constant, introduced by Linux commit
|
||||
v4.20-rc1~75^2~2.
|
||||
* NEWS: Mention this.
|
||||
* tests/fanotify_init.c (main): Update expected output.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
xlat/fan_init_flags.in | 2 ++
|
||||
1 files changed, 2 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/xlat/fan_init_flags.in b/xlat/fan_init_flags.in
|
||||
index ca33039..54d681f 100644
|
||||
--- a/xlat/fan_init_flags.in
|
||||
+++ b/xlat/fan_init_flags.in
|
||||
@@ -2,3 +2,5 @@ FAN_CLOEXEC 0x00000001
|
||||
FAN_NONBLOCK 0x00000002
|
||||
FAN_UNLIMITED_QUEUE 0x00000010
|
||||
FAN_UNLIMITED_MARKS 0x00000020
|
||||
+FAN_ENABLE_AUDIT 0x00000040
|
||||
+FAN_REPORT_TID 0x00000100
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
27
xlat-add-IN_MASK_CREATE-to-inotify_flags.in.patch
Normal file
27
xlat-add-IN_MASK_CREATE-to-inotify_flags.in.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From 9aa1efde5818008f9110bc6a282809a7799c9d91 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 09:57:04 +0200
|
||||
Subject: [PATCH 019/293] xlat: add IN_MASK_CREATE to inotify_flags.in
|
||||
|
||||
* xlat/inotify_flags.in (IN_MASK_CREATE): New constant, introduced by
|
||||
Linux commit v4.19-rc1~115^2.
|
||||
* tests/inotify.c (main): Update expected output.
|
||||
---
|
||||
xlat/inotify_flags.in | 1 +
|
||||
1 files changed, 1 insertions(+)
|
||||
|
||||
diff --git a/xlat/inotify_flags.in b/xlat/inotify_flags.in
|
||||
index db1d839..671bd0e 100644
|
||||
--- a/xlat/inotify_flags.in
|
||||
+++ b/xlat/inotify_flags.in
|
||||
@@ -16,6 +16,7 @@ IN_IGNORED 0x00008000
|
||||
IN_ONLYDIR 0x01000000
|
||||
IN_DONT_FOLLOW 0x02000000
|
||||
IN_EXCL_UNLINK 0x04000000
|
||||
+IN_MASK_CREATE 0x10000000
|
||||
IN_MASK_ADD 0x20000000
|
||||
IN_ISDIR 0x40000000
|
||||
IN_ONESHOT 0x80000000
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
24
xlat-add-IPSTATS_MIB_REASM_OVERLAPS-to-snmp_ip_stats.patch
Normal file
24
xlat-add-IPSTATS_MIB_REASM_OVERLAPS-to-snmp_ip_stats.patch
Normal file
@ -0,0 +1,24 @@
|
||||
From 930864b0834e400ace10337a2a6dfd8ee71f7f20 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:42:13 +0200
|
||||
Subject: [PATCH 037/293] xlat: add IPSTATS_MIB_REASM_OVERLAPS to
|
||||
snmp_ip_stats_mib.in
|
||||
|
||||
* xlat/snmp_ip_stats.in (IPSTATS_MIB_REASM_OVERLAPS): New constant,
|
||||
introduced by Linux commit v4.19-rc1~140^2~128^2~2.
|
||||
---
|
||||
xlat/snmp_ip_stats.in | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/xlat/snmp_ip_stats.in b/xlat/snmp_ip_stats.in
|
||||
index 4bfb7ee..7de755d 100644
|
||||
--- a/xlat/snmp_ip_stats.in
|
||||
+++ b/xlat/snmp_ip_stats.in
|
||||
@@ -35,3 +35,4 @@ IPSTATS_MIB_NOECTPKTS 32
|
||||
IPSTATS_MIB_ECT1PKTS 33
|
||||
IPSTATS_MIB_ECT0PKTS 34
|
||||
IPSTATS_MIB_CEPKTS 35
|
||||
+IPSTATS_MIB_REASM_OVERLAPS 36
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
24
xlat-add-IPV4_DEVCONF_BC_FORWARDING-1-to-inet_devcon.patch
Normal file
24
xlat-add-IPV4_DEVCONF_BC_FORWARDING-1-to-inet_devcon.patch
Normal file
@ -0,0 +1,24 @@
|
||||
From 4fa680e63ff1b4f35404d108408521adf30a6197 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:30:27 +0200
|
||||
Subject: [PATCH 034/293] xlat: add IPV4_DEVCONF_BC_FORWARDING-1 to
|
||||
inet_devconf_indices.in
|
||||
|
||||
* xlat/inet_devconf_indices.in (IPV4_DEVCONF_BC_FORWARDING-1): New
|
||||
constant, introduced by Linux commit v4.19-rc1~140^2~208^2~1.
|
||||
---
|
||||
xlat/inet_devconf_indices.in | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/xlat/inet_devconf_indices.in b/xlat/inet_devconf_indices.in
|
||||
index eabcfc5..dd26237 100644
|
||||
--- a/xlat/inet_devconf_indices.in
|
||||
+++ b/xlat/inet_devconf_indices.in
|
||||
@@ -31,3 +31,4 @@ IPV4_DEVCONF_IGMPV3_UNSOLICITED_REPORT_INTERVAL-1 28
|
||||
IPV4_DEVCONF_IGNORE_ROUTES_WITH_LINKDOWN-1 29
|
||||
IPV4_DEVCONF_DROP_UNICAST_IN_L2_MULTICAST-1 30
|
||||
IPV4_DEVCONF_DROP_GRATUITOUS_ARP-1 31
|
||||
+IPV4_DEVCONF_BC_FORWARDING-1 32
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
140
xlat-add-PR_SPEC_INDIRECT_BRANCH-to-pr_spec_cmds.patch
Normal file
140
xlat-add-PR_SPEC_INDIRECT_BRANCH-to-pr_spec_cmds.patch
Normal file
@ -0,0 +1,140 @@
|
||||
From 38ea49ad111f8a622756e62bc99cab6ce515dc27 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Fri, 14 Dec 2018 17:25:24 +0100
|
||||
Subject: [PATCH 186/293] xlat: add PR_SPEC_INDIRECT_BRANCH to pr_spec_cmds
|
||||
|
||||
* xlat/pr_spec_cmds.in (PR_SPEC_INDIRECT_BRANCH): New constant,
|
||||
introduced by Linux commit v4.20-rc5~4^2~3.
|
||||
* prctl.c (SYS_FUNC(prctl)) <case PR_GET_SPECULATION_CTRL, case
|
||||
PR_SET_SPECULATION_CTRL>: Add PR_SPEC_INDIRECT_BRANCH handling.
|
||||
* tests/prctl-spec-inject.c (main): Add PR_SPEC_INDIRECT_BRANCH decoding
|
||||
checks, update expected output.
|
||||
* NEWS: Mention this.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
prctl.c | 2 ++
|
||||
tests/prctl-spec-inject.c | 51 +++++++++++++++++++++++++++++------------------
|
||||
xlat/pr_spec_cmds.in | 2 ++
|
||||
4 files changed, 37 insertions(+), 20 deletions(-)
|
||||
|
||||
diff --git a/prctl.c b/prctl.c
|
||||
index 669f263..7516510 100644
|
||||
--- a/prctl.c
|
||||
+++ b/prctl.c
|
||||
@@ -221,6 +221,7 @@ SYS_FUNC(prctl)
|
||||
|
||||
switch (arg2) {
|
||||
case PR_SPEC_STORE_BYPASS:
|
||||
+ case PR_SPEC_INDIRECT_BRANCH:
|
||||
tcp->auxstr = sprintflags("",
|
||||
pr_spec_get_store_bypass_flags,
|
||||
(kernel_ulong_t) tcp->u_rval);
|
||||
@@ -393,6 +394,7 @@ SYS_FUNC(prctl)
|
||||
|
||||
switch (arg2) {
|
||||
case PR_SPEC_STORE_BYPASS:
|
||||
+ case PR_SPEC_INDIRECT_BRANCH:
|
||||
printxval64(pr_spec_set_store_bypass_flags, arg3,
|
||||
"PR_SPEC_???");
|
||||
break;
|
||||
diff --git a/tests/prctl-spec-inject.c b/tests/prctl-spec-inject.c
|
||||
index 1247c3c..04403b4 100644
|
||||
--- a/tests/prctl-spec-inject.c
|
||||
+++ b/tests/prctl-spec-inject.c
|
||||
@@ -40,6 +40,15 @@ main(int argc, char **argv)
|
||||
(kernel_ulong_t) 0xdeadfacebadc0dedULL;
|
||||
static const kernel_ulong_t bogus_arg3 =
|
||||
(kernel_ulong_t) 0xdecafeedbeefda7eULL;
|
||||
+
|
||||
+ static const struct {
|
||||
+ long arg;
|
||||
+ const char *str;
|
||||
+ } spec_strs[] = {
|
||||
+ { 0, "PR_SPEC_STORE_BYPASS" },
|
||||
+ { 1, "PR_SPEC_INDIRECT_BRANCH" },
|
||||
+ };
|
||||
+
|
||||
static const struct {
|
||||
long arg;
|
||||
const char *str;
|
||||
@@ -78,8 +87,8 @@ main(int argc, char **argv)
|
||||
injected_val = strtol(argv[1], NULL, 0);
|
||||
|
||||
/* PR_GET_SPECULATION_CTRL */
|
||||
- rc = do_prctl(52, 1, bogus_arg3);
|
||||
- printf("prctl(PR_GET_SPECULATION_CTRL, 0x1 /* PR_SPEC_??? */) "
|
||||
+ rc = do_prctl(52, 2, bogus_arg3);
|
||||
+ printf("prctl(PR_GET_SPECULATION_CTRL, 0x2 /* PR_SPEC_??? */) "
|
||||
"= %s (INJECTED)\n", sprintrc(rc));
|
||||
|
||||
rc = do_prctl(52, bogus_arg2, bogus_arg3);
|
||||
@@ -87,24 +96,26 @@ main(int argc, char **argv)
|
||||
"= %s (INJECTED)\n",
|
||||
(unsigned long long) bogus_arg2, sprintrc(rc));
|
||||
|
||||
- rc = do_prctl(52, 0, bogus_arg3);
|
||||
+ for (unsigned c = 0; c < ARRAY_SIZE(spec_strs); c++) {
|
||||
+ rc = do_prctl(52, spec_strs[c].arg, bogus_arg3);
|
||||
|
||||
- for (unsigned i = 0; i < ARRAY_SIZE(get_strs); i++) {
|
||||
- if (get_strs[i].arg == rc) {
|
||||
- str = get_strs[i].str;
|
||||
- break;
|
||||
+ for (unsigned i = 0; i < ARRAY_SIZE(get_strs); i++) {
|
||||
+ if (get_strs[i].arg == rc) {
|
||||
+ str = get_strs[i].str;
|
||||
+ break;
|
||||
+ }
|
||||
}
|
||||
- }
|
||||
- if (!str)
|
||||
- error_msg_and_fail("Unknown return value: %ld", rc);
|
||||
+ if (!str)
|
||||
+ error_msg_and_fail("Unknown return value: %ld", rc);
|
||||
|
||||
- printf("prctl(PR_GET_SPECULATION_CTRL, PR_SPEC_STORE_BYPASS) "
|
||||
- "= %s%s (INJECTED)\n", sprintrc(rc), str);
|
||||
+ printf("prctl(PR_GET_SPECULATION_CTRL, %s) = %s%s (INJECTED)\n",
|
||||
+ spec_strs[c].str, sprintrc(rc), str);
|
||||
+ }
|
||||
|
||||
|
||||
/* PR_SET_SPECULATION_CTRL*/
|
||||
- rc = do_prctl(53, 1, bogus_arg3);
|
||||
- printf("prctl(PR_SET_SPECULATION_CTRL, 0x1 /* PR_SPEC_??? */, %#llx) "
|
||||
+ rc = do_prctl(53, 2, bogus_arg3);
|
||||
+ printf("prctl(PR_SET_SPECULATION_CTRL, 0x2 /* PR_SPEC_??? */, %#llx) "
|
||||
"= %s (INJECTED)\n",
|
||||
(unsigned long long) bogus_arg3, sprintrc(rc));
|
||||
|
||||
@@ -115,11 +126,13 @@ main(int argc, char **argv)
|
||||
(unsigned long long) bogus_arg3,
|
||||
sprintrc(rc));
|
||||
|
||||
- for (unsigned i = 0; i < ARRAY_SIZE(set_strs); i++) {
|
||||
- rc = do_prctl(53, 0, set_strs[i].arg);
|
||||
- printf("prctl(PR_SET_SPECULATION_CTRL, PR_SPEC_STORE_BYPASS"
|
||||
- ", %s) = %s (INJECTED)\n",
|
||||
- set_strs[i].str, sprintrc(rc));
|
||||
+ for (unsigned c = 0; c < ARRAY_SIZE(spec_strs); c++) {
|
||||
+ for (unsigned i = 0; i < ARRAY_SIZE(set_strs); i++) {
|
||||
+ rc = do_prctl(53, spec_strs[c].arg, set_strs[i].arg);
|
||||
+ printf("prctl(PR_SET_SPECULATION_CTRL, %s"
|
||||
+ ", %s) = %s (INJECTED)\n",
|
||||
+ spec_strs[c].str, set_strs[i].str, sprintrc(rc));
|
||||
+ }
|
||||
}
|
||||
|
||||
puts("+++ exited with 0 +++");
|
||||
diff --git a/xlat/pr_spec_cmds.in b/xlat/pr_spec_cmds.in
|
||||
index e006923..8e5ded0 100644
|
||||
--- a/xlat/pr_spec_cmds.in
|
||||
+++ b/xlat/pr_spec_cmds.in
|
||||
@@ -1 +1,3 @@
|
||||
+#value_indexed
|
||||
PR_SPEC_STORE_BYPASS 0
|
||||
+PR_SPEC_INDIRECT_BRANCH 1
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
26
xlat-add-SCTP_REUSE_PORT-to-sock_sctp_options.in.patch
Normal file
26
xlat-add-SCTP_REUSE_PORT-to-sock_sctp_options.in.patch
Normal file
@ -0,0 +1,26 @@
|
||||
From f9578731fcabf329c1d5deb05afd12d2b8c61974 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 09:59:01 +0200
|
||||
Subject: [PATCH 020/293] xlat: add SCTP_REUSE_PORT to sock_sctp_options.in
|
||||
|
||||
* xlat/sock_sctp_options.in (SCTP_REUSE_PORT): New constant, introduced
|
||||
by Linux commit v4.19-rc1~140^2~518.
|
||||
---
|
||||
xlat/sock_sctp_options.in | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/xlat/sock_sctp_options.in b/xlat/sock_sctp_options.in
|
||||
index bbb914e..db13680 100644
|
||||
--- a/xlat/sock_sctp_options.in
|
||||
+++ b/xlat/sock_sctp_options.in
|
||||
@@ -34,6 +34,7 @@ SCTP_RECVRCVINFO 32
|
||||
SCTP_RECVNXTINFO 33
|
||||
SCTP_DEFAULT_SNDINFO 34
|
||||
SCTP_AUTH_DEACTIVATE_KEY 35
|
||||
+SCTP_REUSE_PORT 36
|
||||
/* linux specific things */
|
||||
SCTP_SOCKOPT_BINDX_ADD 100
|
||||
SCTP_SOCKOPT_BINDX_REM 101
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
31
xlat-add-SOL_CAN_-to-socketlayers.patch
Normal file
31
xlat-add-SOL_CAN_-to-socketlayers.patch
Normal file
@ -0,0 +1,31 @@
|
||||
From 88863bf3edd7ab1e1a7ccfd64569f44bb15f1b86 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 15 Oct 2018 17:32:01 +0200
|
||||
Subject: [PATCH 173/293] xlat: add SOL_CAN_* to socketlayers
|
||||
|
||||
* xlat/socketlayers.in (SOL_CAN_BASE): New constant, introduced by Linux
|
||||
commit v2.6.25-rc1~1162^2~1414.
|
||||
(SOL_CAN_RAW): New constant, introduced by Linux commit
|
||||
v2.6.25-rc1~1162^2~1413.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
xlat/socketlayers.in | 2 ++
|
||||
2 files changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xlat/socketlayers.in b/xlat/socketlayers.in
|
||||
index 0ff09d8..fd44dd1 100644
|
||||
--- a/xlat/socketlayers.in
|
||||
+++ b/xlat/socketlayers.in
|
||||
@@ -7,6 +7,8 @@ SOL_TCP 6
|
||||
SOL_UDP 17
|
||||
SOL_IPV6 41
|
||||
SOL_ICMPV6 58
|
||||
+SOL_CAN_BASE 100
|
||||
+SOL_CAN_RAW 101
|
||||
SOL_SCTP 132
|
||||
SOL_UDPLITE 136
|
||||
SOL_RAW 255
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
26
xlat-add-SOL_XDP-to-socketlayers.in.patch
Normal file
26
xlat-add-SOL_XDP-to-socketlayers.in.patch
Normal file
@ -0,0 +1,26 @@
|
||||
From 45afd0c7a36a4edf486f0001507871d39c76560b Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 21:44:51 +0200
|
||||
Subject: [PATCH 044/293] xlat: add SOL_XDP to socketlayers.in
|
||||
|
||||
* xlat/socketlayers.in (SOL_XDP): New constant, introduced by Linux
|
||||
commit v4.18-rc1~114^2~304^2~4^2~14.
|
||||
---
|
||||
xlat/socketlayers.in | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/xlat/socketlayers.in b/xlat/socketlayers.in
|
||||
index 0dfa446..0ff09d8 100644
|
||||
--- a/xlat/socketlayers.in
|
||||
+++ b/xlat/socketlayers.in
|
||||
@@ -37,6 +37,7 @@ SOL_ALG 279
|
||||
SOL_NFC 280
|
||||
SOL_KCM 281
|
||||
SOL_TLS 282
|
||||
+SOL_XDP 283
|
||||
#if defined __alpha__ || defined __hppa__ || defined __mips__ || defined __sparc__
|
||||
SOL_SOCKET 0xffff
|
||||
#endif
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
30
xlat-add-SO_TXTIME-to-sock_options.in.patch
Normal file
30
xlat-add-SO_TXTIME-to-sock_options.in.patch
Normal file
@ -0,0 +1,30 @@
|
||||
From db5235d0e930ac959cd62e3b022f94f3db7eae2a Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 10:54:51 +0200
|
||||
Subject: [PATCH 022/293] xlat: add SO_TXTIME to sock_options.in
|
||||
|
||||
* xlat/sock_options.in (SO_TXTIME): New constant, introduced by Linux
|
||||
commit v4.19-rc1~140^2~465^2~12.
|
||||
---
|
||||
xlat/sock_options.in | 8 ++++++++
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/xlat/sock_options.in b/xlat/sock_options.in
|
||||
index 2d2d439..9f96d2d 100644
|
||||
--- a/xlat/sock_options.in
|
||||
+++ b/xlat/sock_options.in
|
||||
@@ -445,3 +445,11 @@ SO_ZEROCOPY 16437
|
||||
#else
|
||||
SO_ZEROCOPY 60
|
||||
#endif
|
||||
+
|
||||
+#if defined __sparc__
|
||||
+SO_TXTIME 63
|
||||
+#elif defined __hppa__
|
||||
+SO_TXTIME 16438
|
||||
+#else
|
||||
+SO_TXTIME 61
|
||||
+#endif
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
23
xlat-add-TCP_CLOSE-to-netlink_states.patch
Normal file
23
xlat-add-TCP_CLOSE-to-netlink_states.patch
Normal file
@ -0,0 +1,23 @@
|
||||
From cd933c16c968f6209c198ca14ceedce18c6e3ca3 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sat, 20 Oct 2018 06:16:05 +0200
|
||||
Subject: [PATCH 175/293] xlat: add TCP_CLOSE to netlink_states
|
||||
|
||||
* xlat/netlink_states.in: Decode state 7 as TCP_CLOSE, since that's what
|
||||
net core sets socket's initial state to.
|
||||
---
|
||||
xlat/netlink_states.in | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/xlat/netlink_states.in b/xlat/netlink_states.in
|
||||
index 4d4aee7..d2ffb7b 100644
|
||||
--- a/xlat/netlink_states.in
|
||||
+++ b/xlat/netlink_states.in
|
||||
@@ -1,2 +1,4 @@
|
||||
NETLINK_UNCONNECTED 0
|
||||
NETLINK_CONNECTED 1
|
||||
+/* The initial socket state, as set by net/code/sock.c:sock_init_data */
|
||||
+TCP_CLOSE 7
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
26
xlat-add-fallback-definitions-to-setsock_ipv6_option.patch
Normal file
26
xlat-add-fallback-definitions-to-setsock_ipv6_option.patch
Normal file
@ -0,0 +1,26 @@
|
||||
From 6c9cfeaaa44dc524263572f535be7d011318c5f8 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 15 Oct 2018 17:56:42 +0200
|
||||
Subject: [PATCH 174/293] xlat: add fallback definitions to
|
||||
setsock_ipv6_options
|
||||
|
||||
* xlat/setsock_ipv6_options.in: Add fallback definitions.
|
||||
---
|
||||
xlat/setsock_ipv6_options.in | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/xlat/setsock_ipv6_options.in b/xlat/setsock_ipv6_options.in
|
||||
index 087a176..5a42cdf 100644
|
||||
--- a/xlat/setsock_ipv6_options.in
|
||||
+++ b/xlat/setsock_ipv6_options.in
|
||||
@@ -4,5 +4,5 @@
|
||||
* should be in sock_ipv6_options.in instead.
|
||||
*/
|
||||
|
||||
-IP6T_SO_SET_REPLACE
|
||||
-IP6T_SO_SET_ADD_COUNTERS
|
||||
+IP6T_SO_SET_REPLACE 64
|
||||
+IP6T_SO_SET_ADD_COUNTERS 65
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
22
xlat-fix-typo-in-smc_protocols.in.patch
Normal file
22
xlat-fix-typo-in-smc_protocols.in.patch
Normal file
@ -0,0 +1,22 @@
|
||||
From 2d88ec9e392edc2652ad5617498765f21af2b611 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 21:51:15 +0200
|
||||
Subject: [PATCH 013/293] xlat: fix typo in smc_protocols.in
|
||||
|
||||
* xlat/smc_protocols.in: s/^MCPROTO_SMC/SMCPROTO_SMC/.
|
||||
---
|
||||
xlat/smc_protocols.in | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xlat/smc_protocols.in b/xlat/smc_protocols.in
|
||||
index 3a65a39..b8c1aae 100644
|
||||
--- a/xlat/smc_protocols.in
|
||||
+++ b/xlat/smc_protocols.in
|
||||
@@ -1,3 +1,3 @@
|
||||
#value_indexed
|
||||
-MCPROTO_SMC 0
|
||||
+SMCPROTO_SMC 0
|
||||
SMCPROTO_SMC6 1
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
31
xlat-print-_IOC_NONE-in-symbolic-form-even-if-it-is-.patch
Normal file
31
xlat-print-_IOC_NONE-in-symbolic-form-even-if-it-is-.patch
Normal file
@ -0,0 +1,31 @@
|
||||
From e78becf8b93d7cc7649864a1344ed1db0b86e50e Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Sun, 23 Sep 2018 09:54:55 +0000
|
||||
Subject: [PATCH 086/293] xlat: print _IOC_NONE in symbolic form even if it is
|
||||
equal to 0
|
||||
|
||||
On some architectures _IOC_NONE equals to 1, on others it is 0.
|
||||
Change the way how ioctl direction flags are printed so that
|
||||
_IOC_NONE is printed in symbolic form even if it is equal to 0.
|
||||
|
||||
* xlat/ioctl_dirs.in (_IOC_NONE): Move to the head of the list.
|
||||
* tests/ioctl_inotify.c (main): Update expected output.
|
||||
* tests/ioctl_loop. (main): Likewise.c
|
||||
* tests/ioctl_perf.c (main): Likewise.
|
||||
* tests/ioctl_scsi.c (main): Likewise.
|
||||
---
|
||||
xlat/ioctl_dirs.in | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/xlat/ioctl_dirs.in b/xlat/ioctl_dirs.in
|
||||
index 4c97a86..c069dd7 100644
|
||||
--- a/xlat/ioctl_dirs.in
|
||||
+++ b/xlat/ioctl_dirs.in
|
||||
@@ -1,3 +1,3 @@
|
||||
+_IOC_NONE
|
||||
_IOC_READ
|
||||
_IOC_WRITE
|
||||
-_IOC_NONE
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
50
xlat-provide-fallback-definitions-for-epollevents.patch
Normal file
50
xlat-provide-fallback-definitions-for-epollevents.patch
Normal file
@ -0,0 +1,50 @@
|
||||
From 6177e74134042008d5a41ae3df9726988e96f886 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 21:23:47 +0200
|
||||
Subject: [PATCH 053/293] xlat: provide fallback definitions for epollevents
|
||||
|
||||
* xlat/epollevents.in: Provide fallback definitions, add EPOLLNVAL
|
||||
constant (introduced by Linux commit v4.16-rc1~3^2~3).
|
||||
---
|
||||
xlat/epollevents.in | 31 ++++++++++++++++---------------
|
||||
1 file changed, 16 insertions(+), 15 deletions(-)
|
||||
|
||||
diff --git a/xlat/epollevents.in b/xlat/epollevents.in
|
||||
index 6fa6707..2dced00 100644
|
||||
--- a/xlat/epollevents.in
|
||||
+++ b/xlat/epollevents.in
|
||||
@@ -1,15 +1,16 @@
|
||||
-EPOLLIN
|
||||
-EPOLLPRI
|
||||
-EPOLLOUT
|
||||
-EPOLLRDNORM
|
||||
-EPOLLRDBAND
|
||||
-EPOLLWRNORM
|
||||
-EPOLLWRBAND
|
||||
-EPOLLMSG
|
||||
-EPOLLERR
|
||||
-EPOLLHUP
|
||||
-EPOLLRDHUP
|
||||
-EPOLLEXCLUSIVE
|
||||
-EPOLLWAKEUP
|
||||
-EPOLLONESHOT
|
||||
-EPOLLET
|
||||
+EPOLLIN 0x00000001
|
||||
+EPOLLPRI 0x00000002
|
||||
+EPOLLOUT 0x00000004
|
||||
+EPOLLERR 0x00000008
|
||||
+EPOLLHUP 0x00000010
|
||||
+EPOLLNVAL 0x00000020
|
||||
+EPOLLRDNORM 0x00000040
|
||||
+EPOLLRDBAND 0x00000080
|
||||
+EPOLLWRNORM 0x00000100
|
||||
+EPOLLWRBAND 0x00000200
|
||||
+EPOLLMSG 0x00000400
|
||||
+EPOLLRDHUP 0x00002000
|
||||
+EPOLLEXCLUSIVE 0x10000000
|
||||
+EPOLLWAKEUP 0x20000000
|
||||
+EPOLLONESHOT 0x40000000
|
||||
+EPOLLET 0x80000000
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
28
xlat-provide-fallback-definitions-for-open_access_mo.patch
Normal file
28
xlat-provide-fallback-definitions-for-open_access_mo.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From a5918bf7e6b1ff8283f78814216ce29177205dbb Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Fri, 31 Aug 2018 09:08:08 +0200
|
||||
Subject: [PATCH 073/293] xlat: provide fallback definitions for
|
||||
open_access_modes constants
|
||||
|
||||
* xlat/open_access_modes.in: Add fallback values.
|
||||
---
|
||||
xlat/open_access_modes.in | 9 +++++----
|
||||
1 file changed, 5 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/xlat/open_access_modes.in b/xlat/open_access_modes.in
|
||||
index 423a29b..45dcd73 100644
|
||||
--- a/xlat/open_access_modes.in
|
||||
+++ b/xlat/open_access_modes.in
|
||||
@@ -1,4 +1,5 @@
|
||||
-O_RDONLY
|
||||
-O_WRONLY
|
||||
-O_RDWR
|
||||
-O_ACCMODE
|
||||
+#value_indexed
|
||||
+O_RDONLY 0
|
||||
+O_WRONLY 1
|
||||
+O_RDWR 2
|
||||
+O_ACCMODE 3
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
68
xlat-provide-fallback-definitions-to-pollflags.patch
Normal file
68
xlat-provide-fallback-definitions-to-pollflags.patch
Normal file
@ -0,0 +1,68 @@
|
||||
From b05d2667e96718416997d2f39828647e677211d9 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 21:20:51 +0200
|
||||
Subject: [PATCH 052/293] xlat: provide fallback definitions to pollflags
|
||||
|
||||
* xlat/pollflags.in: Add fallback definitions for POLLWRNORM,
|
||||
POLLWRBAND, POLLMSG, POLLREMOVE, and POLLRDHUP.
|
||||
---
|
||||
xlat/pollflags.in | 42 +++++++++++++++++++++++++++++++++++-------
|
||||
1 file changed, 35 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/xlat/pollflags.in b/xlat/pollflags.in
|
||||
index 3140011..8081e78 100644
|
||||
--- a/xlat/pollflags.in
|
||||
+++ b/xlat/pollflags.in
|
||||
@@ -1,14 +1,42 @@
|
||||
POLLIN 0x0001
|
||||
POLLPRI 0x0002
|
||||
POLLOUT 0x0004
|
||||
-POLLRDNORM 0x0040
|
||||
-POLLWRNORM
|
||||
-POLLRDBAND 0x0080
|
||||
-POLLWRBAND
|
||||
POLLERR 0x0008
|
||||
POLLHUP 0x0010
|
||||
POLLNVAL 0x0020
|
||||
-POLLMSG
|
||||
-POLLREMOVE
|
||||
-POLLRDHUP
|
||||
+POLLRDNORM 0x0040
|
||||
+POLLRDBAND 0x0080
|
||||
+
|
||||
+#if defined(__m68k__) || defined(__mips__) || defined(__sparc__) || defined(__xtensa__)
|
||||
+/* POLLWRNORM POLLOUT */
|
||||
+#else
|
||||
+POLLWRNORM 0x0100
|
||||
+#endif
|
||||
+
|
||||
+#if defined(__m68k__) || defined(__mips__) || defined(__sparc__) || defined(__xtensa__)
|
||||
+POLLWRBAND 0x0100
|
||||
+#else
|
||||
+POLLWRBAND 0x0200
|
||||
+#endif
|
||||
+
|
||||
+#if defined(__sparc__)
|
||||
+POLLMSG 0x0200
|
||||
+#else
|
||||
+POLLMSG 0x0400
|
||||
+#endif
|
||||
+
|
||||
+#if defined(__sparc__)
|
||||
+POLLREMOVE 0x0400
|
||||
+#elif defined(__xtensa__)
|
||||
+POLLREMOVE 0x0800
|
||||
+#else
|
||||
+POLLREMOVE 0x1000
|
||||
+#endif
|
||||
+
|
||||
+#if defined(__sparc__)
|
||||
+POLLRDHUP 0x0800
|
||||
+#else
|
||||
+POLLRDHUP 0x2000
|
||||
+#endif
|
||||
+
|
||||
POLL_BUSY_LOOP 0x8000
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
37
xlat-provide-fallback-values-for-socktypes.patch
Normal file
37
xlat-provide-fallback-values-for-socktypes.patch
Normal file
@ -0,0 +1,37 @@
|
||||
From fdfc68a98460114755e95b9a3a9a66ef083f9a2f Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 15:15:20 +0200
|
||||
Subject: [PATCH 051/293] xlat: provide fallback values for socktypes
|
||||
|
||||
* xlat/socktypes.in: Provide fallback values.
|
||||
---
|
||||
xlat/socktypes.in | 19 ++++++++++++-------
|
||||
1 file changed, 12 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/xlat/socktypes.in b/xlat/socktypes.in
|
||||
index 4b3eadc..678c2da 100644
|
||||
--- a/xlat/socktypes.in
|
||||
+++ b/xlat/socktypes.in
|
||||
@@ -1,7 +1,12 @@
|
||||
-SOCK_STREAM
|
||||
-SOCK_DGRAM
|
||||
-SOCK_RAW
|
||||
-SOCK_RDM
|
||||
-SOCK_SEQPACKET
|
||||
-SOCK_DCCP
|
||||
-SOCK_PACKET
|
||||
+#ifdef __mips__
|
||||
+SOCK_DGRAM 1
|
||||
+SOCK_STREAM 2
|
||||
+#else
|
||||
+SOCK_STREAM 1
|
||||
+SOCK_DGRAM 2
|
||||
+#endif
|
||||
+SOCK_RAW 3
|
||||
+SOCK_RDM 4
|
||||
+SOCK_SEQPACKET 5
|
||||
+SOCK_DCCP 6
|
||||
+SOCK_PACKET 10
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
30
xlat-provide-fallback-values-to-route_nexthop_flags.patch
Normal file
30
xlat-provide-fallback-values-to-route_nexthop_flags.patch
Normal file
@ -0,0 +1,30 @@
|
||||
From 3f10639284bf60b939a3b7cc8cb54d0f57937d9b Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 27 Aug 2018 12:32:42 +0200
|
||||
Subject: [PATCH 050/293] xlat: provide fallback values to route_nexthop_flags
|
||||
|
||||
* xlat/route_nexthop_flags.in: Add fallback values.
|
||||
---
|
||||
xlat/route_nexthop_flags.in | 12 ++++++------
|
||||
1 file changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/xlat/route_nexthop_flags.in b/xlat/route_nexthop_flags.in
|
||||
index 907515e..a64a988 100644
|
||||
--- a/xlat/route_nexthop_flags.in
|
||||
+++ b/xlat/route_nexthop_flags.in
|
||||
@@ -1,6 +1,6 @@
|
||||
-RTNH_F_DEAD
|
||||
-RTNH_F_PERVASIVE
|
||||
-RTNH_F_ONLINK
|
||||
-RTNH_F_OFFLOAD
|
||||
-RTNH_F_LINKDOWN
|
||||
-RTNH_F_UNRESOLVED
|
||||
+RTNH_F_DEAD 1
|
||||
+RTNH_F_PERVASIVE 2
|
||||
+RTNH_F_ONLINK 4
|
||||
+RTNH_F_OFFLOAD 8
|
||||
+RTNH_F_LINKDOWN 16
|
||||
+RTNH_F_UNRESOLVED 32
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
41
xlat-update-KERN_-constants.patch
Normal file
41
xlat-update-KERN_-constants.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From 25a73fb12f5693b4382a8405c297faf9ecd0a9cb Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Sat, 5 Jan 2019 21:14:42 +0000
|
||||
Subject: [PATCH 199/293] xlat: update KERN_* constants
|
||||
|
||||
* xlat/sysctl_kern.in (KERN_PANIC_ON_WARN, KERN_PANIC_PRINT): New
|
||||
constants introduced by Linux kernel commits v3.19-rc1~135^2~91
|
||||
and v5.0-rc1~38^2~16, respectively.
|
||||
* configure.ac (AC_CHECK_DECLS): Add them.
|
||||
* NEWS: Mention this.
|
||||
---
|
||||
configure.ac | 2 ++
|
||||
xlat/sysctl_kern.in | 2 ++
|
||||
3 files changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 8045ebd..9bf64c3 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -645,6 +645,8 @@ AC_CHECK_DECLS(m4_normalize([
|
||||
KERN_MAX_LOCK_DEPTH,
|
||||
KERN_NMI_WATCHDOG,
|
||||
KERN_PANIC_ON_NMI,
|
||||
+ KERN_PANIC_ON_WARN,
|
||||
+ KERN_PANIC_PRINT,
|
||||
NET_LLC,
|
||||
NET_NETFILTER,
|
||||
NET_DCCP,
|
||||
diff --git a/xlat/sysctl_kern.in b/xlat/sysctl_kern.in
|
||||
index b0568ce..f920f1f 100644
|
||||
--- a/xlat/sysctl_kern.in
|
||||
+++ b/xlat/sysctl_kern.in
|
||||
@@ -66,3 +66,5 @@ KERN_COMPAT_LOG
|
||||
KERN_MAX_LOCK_DEPTH
|
||||
KERN_NMI_WATCHDOG
|
||||
KERN_PANIC_ON_NMI
|
||||
+KERN_PANIC_ON_WARN
|
||||
+KERN_PANIC_PRINT
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
46
xlat-update-V4L2_CID_USER_-_BASE-constants.patch
Normal file
46
xlat-update-V4L2_CID_USER_-_BASE-constants.patch
Normal file
@ -0,0 +1,46 @@
|
||||
From 0f09267db00468b9204395c6990fc8816fd3c0e5 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Sat, 18 Aug 2018 07:22:47 +0000
|
||||
Subject: [PATCH 003/293] xlat: update V4L2_CID_USER_*_BASE constants
|
||||
|
||||
* xlat/v4l2_control_id_bases.in (V4L2_CID_USER_S2255_BASE,
|
||||
V4L2_CID_USER_SI476X_BASE, V4L2_CID_USER_SAA7134_BASE,
|
||||
V4L2_CID_USER_ADV7180_BASE, V4L2_CID_USER_TC358743_BASE,
|
||||
V4L2_CID_USER_MAX217X_BASE): New constants.
|
||||
---
|
||||
xlat/v4l2_control_id_bases.in | 14 ++++++++++----
|
||||
1 file changed, 10 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/xlat/v4l2_control_id_bases.in b/xlat/v4l2_control_id_bases.in
|
||||
index f3fd925..a0f9cca 100644
|
||||
--- a/xlat/v4l2_control_id_bases.in
|
||||
+++ b/xlat/v4l2_control_id_bases.in
|
||||
@@ -1,7 +1,13 @@
|
||||
V4L2_CID_BASE (V4L2_CTRL_CLASS_USER | 0x900)
|
||||
-V4L2_CID_USER_MEYE_BASE (V4L2_CID_BASE + 0x1000)
|
||||
-V4L2_CID_USER_BTTV_BASE (V4L2_CID_BASE + 0x1010)
|
||||
-V4L2_CID_USER_TI_VPE_BASE (V4L2_CID_BASE + 0x1050)
|
||||
+V4L2_CID_USER_MEYE_BASE (V4L2_CID_BASE | 0x1000)
|
||||
+V4L2_CID_USER_BTTV_BASE (V4L2_CID_BASE | 0x1010)
|
||||
+V4L2_CID_USER_S2255_BASE (V4L2_CID_BASE | 0x1030)
|
||||
+V4L2_CID_USER_SI476X_BASE (V4L2_CID_BASE | 0x1040)
|
||||
+V4L2_CID_USER_TI_VPE_BASE (V4L2_CID_BASE | 0x1050)
|
||||
+V4L2_CID_USER_SAA7134_BASE (V4L2_CID_BASE | 0x1060)
|
||||
+V4L2_CID_USER_ADV7180_BASE (V4L2_CID_BASE | 0x1070)
|
||||
+V4L2_CID_USER_TC358743_BASE (V4L2_CID_BASE | 0x1080)
|
||||
+V4L2_CID_USER_MAX217X_BASE (V4L2_CID_BASE | 0x1090)
|
||||
#ifndef STRACE_WORKAROUND_FOR_V4L2_CID_USER_IMX_BASE
|
||||
# define STRACE_WORKAROUND_FOR_V4L2_CID_USER_IMX_BASE
|
||||
/*
|
||||
@@ -17,7 +23,7 @@ V4L2_CID_USER_TI_VPE_BASE (V4L2_CID_BASE + 0x1050)
|
||||
*/
|
||||
# undef V4L2_CID_USER_IMX_BASE
|
||||
#endif
|
||||
-V4L2_CID_USER_IMX_BASE (V4L2_CID_BASE + 0x10b0)
|
||||
+V4L2_CID_USER_IMX_BASE (V4L2_CID_BASE | 0x10b0)
|
||||
V4L2_CID_MPEG_BASE (V4L2_CTRL_CLASS_MPEG | 0x900)
|
||||
V4L2_CID_MPEG_CX2341X_BASE (V4L2_CTRL_CLASS_MPEG | 0x1000)
|
||||
V4L2_CID_MPEG_MFC51_BASE (V4L2_CTRL_CLASS_MPEG | 0x1100)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
27
xlat-update-bpf_map_types.in.patch
Normal file
27
xlat-update-bpf_map_types.in.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From 3926f4a07da13ef0adcd330b2d8d8b21eac2fa19 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 15:39:54 +0200
|
||||
Subject: [PATCH 036/293] xlat: update bpf_map_types.in
|
||||
|
||||
* xlat/bpf_map_types.in (BPF_MAP_TYPE_CGROUP_STORAGE): New constant,
|
||||
introduced by Linux commit v4.19-rc1~140^2~108^2~3^2~12.
|
||||
(BPF_MAP_TYPE_REUSEPORT_SOCKARRAY): New constant, introduced by Linux
|
||||
commit v4.19-rc1~140^2~24^2~2^2~6.
|
||||
* tests/bpf.c: Update expected output.
|
||||
---
|
||||
xlat/bpf_map_types.in | 2 ++
|
||||
1 files changed, 2 insertions(+)
|
||||
|
||||
diff --git a/xlat/bpf_map_types.in b/xlat/bpf_map_types.in
|
||||
index 24c2fe9..e227382 100644
|
||||
--- a/xlat/bpf_map_types.in
|
||||
+++ b/xlat/bpf_map_types.in
|
||||
@@ -18,3 +18,5 @@ BPF_MAP_TYPE_SOCKMAP 15
|
||||
BPF_MAP_TYPE_CPUMAP 16
|
||||
BPF_MAP_TYPE_XSKMAP 17
|
||||
BPF_MAP_TYPE_SOCKHASH 18
|
||||
+BPF_MAP_TYPE_CGROUP_STORAGE 19
|
||||
+BPF_MAP_TYPE_REUSEPORT_SOCKARRAY 20
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
53
xlat-update-kvm_cap.patch
Normal file
53
xlat-update-kvm_cap.patch
Normal file
@ -0,0 +1,53 @@
|
||||
From a55f5485c65ffe1c7812b3722eaa36c15bc63385 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 24 Sep 2018 00:43:52 +0200
|
||||
Subject: [PATCH 182/293] xlat: update kvm_cap
|
||||
|
||||
* xlat/kvm_cap.in (KVM_CAP_NESTED_STATE): New constant, introduced
|
||||
by Linux commit v4.19-rc1~87^2~62.
|
||||
(KVM_CAP_ARM_INJECT_SERROR_ESR): New constant, introduced by Linux
|
||||
commit v4.19-rc1~55^2~12^2~14, merged with its final value
|
||||
in v4.19-rc1~55^2~12.
|
||||
(KVM_CAP_MSR_PLATFORM_INFO): New constant, introduced by Linux commit
|
||||
v4.19-rc5~8^2~2.
|
||||
(KVM_CAP_PPC_NESTED_HV): New constant, introduced by Linux commit
|
||||
v4.20-rc1~113^2~107^2~1.
|
||||
(KVM_CAP_HYPERV_SEND_IPI): New constant, introduced by Linux commit
|
||||
v4.20-rc1~113^2~72.
|
||||
KVM_CAP_COALESCED_PIO): New constant, introduced by Linux commit
|
||||
v4.20-rc1~113^2~31.
|
||||
(KVM_CAP_HYPERV_ENLIGHTENED_VMCS): New constant, introduced by Linux
|
||||
commit v4.20-rc1~113^2~25.
|
||||
(KVM_CAP_EXCEPTION_PAYLOAD): New constant, introduced by Linux commit
|
||||
v4.20-rc1~113^2~8.
|
||||
(KVM_CAP_ARM_VM_IPA_SIZE): New constant, introduced by Linux commit
|
||||
v4.20-rc1~113^2~5^2~8 and updated by Linux commit
|
||||
v4.20-rc1~113^2~5.
|
||||
* NEWS: Mention this.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
xlat/kvm_cap.in | 9 +++++++++
|
||||
2 files changed, 11 insertions(+), 2 deletions(-)
|
||||
|
||||
* Bug fixes
|
||||
diff --git a/xlat/kvm_cap.in b/xlat/kvm_cap.in
|
||||
index a3819e7..6d229e0 100644
|
||||
--- a/xlat/kvm_cap.in
|
||||
+++ b/xlat/kvm_cap.in
|
||||
@@ -150,3 +150,12 @@ KVM_CAP_GET_MSR_FEATURES 153
|
||||
KVM_CAP_HYPERV_EVENTFD 154
|
||||
KVM_CAP_HYPERV_TLBFLUSH 155
|
||||
KVM_CAP_S390_HPAGE_1M 156
|
||||
+KVM_CAP_NESTED_STATE 157
|
||||
+KVM_CAP_ARM_INJECT_SERROR_ESR 158
|
||||
+KVM_CAP_MSR_PLATFORM_INFO 159
|
||||
+KVM_CAP_PPC_NESTED_HV 160
|
||||
+KVM_CAP_HYPERV_SEND_IPI 161
|
||||
+KVM_CAP_COALESCED_PIO 162
|
||||
+KVM_CAP_HYPERV_ENLIGHTENED_VMCS 163
|
||||
+KVM_CAP_EXCEPTION_PAYLOAD 164
|
||||
+KVM_CAP_ARM_VM_IPA_SIZE 165
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
40
xlat-update-neighbor_cache_entry_flags.patch
Normal file
40
xlat-update-neighbor_cache_entry_flags.patch
Normal file
@ -0,0 +1,40 @@
|
||||
From e3d913d5fb9ffbd7a229c4c2d7b392f419e97dc8 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Thu, 1 Nov 2018 17:29:29 +0100
|
||||
Subject: [PATCH 180/293] xlat: update neighbor_cache_entry_flags
|
||||
|
||||
* xlat/neighbor_cache_entry_flags.in (NTF_OFFLOADED): New constant,
|
||||
introduced by Linux commit v4.13-rc1~157^2~252^2~13.
|
||||
(NTF_STICKY): New constant, introduced by Linux commit
|
||||
v4.20-rc1~14^2~392.
|
||||
(NTF_USE, NTF_SELF, NTF_MASTER, NTF_PROXY, NTF_EXT_LEARNED, NTF_ROUTER):
|
||||
Add fallback definitions.
|
||||
* NEWS: Mention this.
|
||||
|
||||
Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
|
||||
---
|
||||
xlat/neighbor_cache_entry_flags.in | 14 ++++++++------
|
||||
2 files changed, 9 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/xlat/neighbor_cache_entry_flags.in b/xlat/neighbor_cache_entry_flags.in
|
||||
index 6a210f5..0f0a83e 100644
|
||||
--- a/xlat/neighbor_cache_entry_flags.in
|
||||
+++ b/xlat/neighbor_cache_entry_flags.in
|
||||
@@ -1,6 +1,8 @@
|
||||
-NTF_USE
|
||||
-NTF_SELF
|
||||
-NTF_MASTER
|
||||
-NTF_PROXY
|
||||
-NTF_EXT_LEARNED
|
||||
-NTF_ROUTER
|
||||
+NTF_USE 0x01
|
||||
+NTF_SELF 0x02
|
||||
+NTF_MASTER 0x04
|
||||
+NTF_PROXY 0x08
|
||||
+NTF_EXT_LEARNED 0x10
|
||||
+NTF_OFFLOADED 0x20
|
||||
+NTF_STICKY 0x40
|
||||
+NTF_ROUTER 0x80
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
29
xlat-update-nt_descriptor_types.in.patch
Normal file
29
xlat-update-nt_descriptor_types.in.patch
Normal file
@ -0,0 +1,29 @@
|
||||
From cde23ff80c6ffbb89bdeafa74c6926680ddbce54 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 11:41:16 +0200
|
||||
Subject: [PATCH 027/293] xlat: update nt_descriptor_types.in
|
||||
|
||||
* xlat/nt_descriptor_types.in (NT_VMCOREDD): New named constant,
|
||||
introduced by Linux commit v4.18-rc1~114^2~252^2~2.
|
||||
(NT_MIPS_DSP): New named constant, introduced by Linux commit
|
||||
v4.19-rc1~42^2~63.
|
||||
(NT_MIPS_FP_MODE): New named constant, introduced by Linux commit
|
||||
v4.19-rc1~42^2~62.
|
||||
---
|
||||
xlat/nt_descriptor_types.in | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/xlat/nt_descriptor_types.in b/xlat/nt_descriptor_types.in
|
||||
index d90b870..34decc0 100644
|
||||
--- a/xlat/nt_descriptor_types.in
|
||||
+++ b/xlat/nt_descriptor_types.in
|
||||
@@ -61,3 +61,6 @@ NT_METAG_CBUF 0x500
|
||||
NT_METAG_RPIPE 0x501
|
||||
NT_METAG_TLS 0x502
|
||||
NT_ARC_V2 0x600
|
||||
+NT_VMCOREDD 0x700
|
||||
+NT_MIPS_DSP 0x800
|
||||
+NT_MIPS_FP_MODE 0x801
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
75
xlat-update-resources.patch
Normal file
75
xlat-update-resources.patch
Normal file
@ -0,0 +1,75 @@
|
||||
From 4499e109ecfbace80362aab185095bdfb1038ecf Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Fri, 31 Aug 2018 05:22:29 +0200
|
||||
Subject: [PATCH 072/293] xlat: update resources
|
||||
|
||||
* xlat/resources.in: Declare as #value indexed, provide fallback values.
|
||||
(RLIMIT_VMEM): Remove.
|
||||
---
|
||||
xlat/resources.in | 56 ++++++++++++++++++++++++++++++++++++++-----------------
|
||||
1 file changed, 39 insertions(+), 17 deletions(-)
|
||||
|
||||
diff --git a/xlat/resources.in b/xlat/resources.in
|
||||
index 8c45b7f..f12cb85 100644
|
||||
--- a/xlat/resources.in
|
||||
+++ b/xlat/resources.in
|
||||
@@ -1,17 +1,39 @@
|
||||
-RLIMIT_AS
|
||||
-RLIMIT_CORE
|
||||
-RLIMIT_CPU
|
||||
-RLIMIT_DATA
|
||||
-RLIMIT_FSIZE
|
||||
-RLIMIT_LOCKS
|
||||
-RLIMIT_MEMLOCK
|
||||
-RLIMIT_MSGQUEUE
|
||||
-RLIMIT_NICE
|
||||
-RLIMIT_NOFILE
|
||||
-RLIMIT_NPROC
|
||||
-RLIMIT_RSS
|
||||
-RLIMIT_RTPRIO
|
||||
-RLIMIT_RTTIME
|
||||
-RLIMIT_SIGPENDING
|
||||
-RLIMIT_STACK
|
||||
-RLIMIT_VMEM
|
||||
+#value_indexed
|
||||
+RLIMIT_CPU 0
|
||||
+RLIMIT_FSIZE 1
|
||||
+RLIMIT_DATA 2
|
||||
+RLIMIT_STACK 3
|
||||
+RLIMIT_CORE 4
|
||||
+
|
||||
+#if defined(__alpha__)
|
||||
+RLIMIT_RSS 5
|
||||
+RLIMIT_NOFILE 6
|
||||
+RLIMIT_AS 7
|
||||
+RLIMIT_NPROC 8
|
||||
+RLIMIT_MEMLOCK 9
|
||||
+#elif defined(__mips__)
|
||||
+RLIMIT_NOFILE 5
|
||||
+RLIMIT_AS 6
|
||||
+RLIMIT_RSS 7
|
||||
+RLIMIT_NPROC 8
|
||||
+RLIMIT_MEMLOCK 9
|
||||
+#elif defined(__sparc__)
|
||||
+RLIMIT_RSS 5
|
||||
+RLIMIT_NOFILE 6
|
||||
+RLIMIT_NPROC 7
|
||||
+RLIMIT_MEMLOCK 8
|
||||
+RLIMIT_AS 9
|
||||
+#else
|
||||
+RLIMIT_RSS 5
|
||||
+RLIMIT_NPROC 6
|
||||
+RLIMIT_NOFILE 7
|
||||
+RLIMIT_MEMLOCK 8
|
||||
+RLIMIT_AS 9
|
||||
+#endif
|
||||
+
|
||||
+RLIMIT_LOCKS 10
|
||||
+RLIMIT_SIGPENDING 11
|
||||
+RLIMIT_MSGQUEUE 12
|
||||
+RLIMIT_NICE 13
|
||||
+RLIMIT_RTPRIO 14
|
||||
+RLIMIT_RTTIME 15
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
28
xlat-update-siginfo_codes.patch
Normal file
28
xlat-update-siginfo_codes.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From 7e15b04b20e9149e7f732c2b56c61d3c386d7972 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Mon, 15 Oct 2018 17:47:01 +0200
|
||||
Subject: [PATCH 171/293] xlat: update siginfo_codes
|
||||
|
||||
* xlat/siginfo_codes.in (SI_LWP): Remove, as it is not present on Linux.
|
||||
(SI_NOINFO): Define only on SPARC, provide fallback value.
|
||||
---
|
||||
xlat/siginfo_codes.in | 6 ++++--
|
||||
1 file changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/xlat/siginfo_codes.in b/xlat/siginfo_codes.in
|
||||
index 968c660..b3e0888 100644
|
||||
--- a/xlat/siginfo_codes.in
|
||||
+++ b/xlat/siginfo_codes.in
|
||||
@@ -16,5 +16,7 @@ SI_SIGIO -5
|
||||
SI_TKILL -6
|
||||
SI_DETHREAD -7
|
||||
SI_ASYNCNL -60
|
||||
-SI_NOINFO
|
||||
-SI_LWP
|
||||
+
|
||||
+#ifdef __sparc__
|
||||
+SI_NOINFO 32767
|
||||
+#endif
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
31
xlat-update-v4l2_control_ids.in.patch
Normal file
31
xlat-update-v4l2_control_ids.in.patch
Normal file
@ -0,0 +1,31 @@
|
||||
From 9624d9f09d92a6f6ec3c144ef12d476f82426205 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 10:58:11 +0200
|
||||
Subject: [PATCH 023/293] xlat: update v4l2_control_ids.in
|
||||
|
||||
* xlat/v4l2_control_ids.in (V4L2_CID_MPEG_VIDEO_VP8_PROFILE): Renamed
|
||||
from V4L2_CID_MPEG_VIDEO_VPX_PROFILE (the latter is now a synonym),
|
||||
by Linux commit v4.19-rc1~137^2~270.
|
||||
(V4L2_CID_MPEG_VIDEO_VP9_PROFILE): New constant, introduced by Linux
|
||||
commit v4.19-rc1~137^2~269.
|
||||
---
|
||||
xlat/v4l2_control_ids.in | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xlat/v4l2_control_ids.in b/xlat/v4l2_control_ids.in
|
||||
index 0885944..1cdda75 100644
|
||||
--- a/xlat/v4l2_control_ids.in
|
||||
+++ b/xlat/v4l2_control_ids.in
|
||||
@@ -155,7 +155,8 @@ V4L2_CID_MPEG_VIDEO_VPX_MIN_QP (V4L2_CID_MPEG_BASE+507)
|
||||
V4L2_CID_MPEG_VIDEO_VPX_MAX_QP (V4L2_CID_MPEG_BASE+508)
|
||||
V4L2_CID_MPEG_VIDEO_VPX_I_FRAME_QP (V4L2_CID_MPEG_BASE+509)
|
||||
V4L2_CID_MPEG_VIDEO_VPX_P_FRAME_QP (V4L2_CID_MPEG_BASE+510)
|
||||
-V4L2_CID_MPEG_VIDEO_VPX_PROFILE (V4L2_CID_MPEG_BASE+511)
|
||||
+V4L2_CID_MPEG_VIDEO_VP8_PROFILE (V4L2_CID_MPEG_BASE+511)
|
||||
+V4L2_CID_MPEG_VIDEO_VP9_PROFILE (V4L2_CID_MPEG_BASE+512)
|
||||
/* CIDs for HEVC encoding. */
|
||||
V4L2_CID_MPEG_VIDEO_HEVC_MIN_QP (V4L2_CID_MPEG_BASE + 600)
|
||||
V4L2_CID_MPEG_VIDEO_HEVC_MAX_QP (V4L2_CID_MPEG_BASE + 601)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
50
xlat-update-v4l2_pix_fmts.in.patch
Normal file
50
xlat-update-v4l2_pix_fmts.in.patch
Normal file
@ -0,0 +1,50 @@
|
||||
From fe8861f6b42c8fe4e4a08d38da6668253fe745f7 Mon Sep 17 00:00:00 2001
|
||||
From: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
Date: Sun, 19 Aug 2018 14:52:58 +0200
|
||||
Subject: [PATCH 030/293] xlat: update v4l2_pix_fmts.in
|
||||
|
||||
* xlat/v4l2_pix_fmts.in (V4L2_PIX_FMT_FWHT): New constant, introduced by
|
||||
Linux commit v4.19-rc1~137^2~221.
|
||||
(V4L2_PIX_FMT_SBGGR14P, V4L2_PIX_FMT_SGBRG14P, V4L2_PIX_FMT_SGRBG14P,
|
||||
V4L2_PIX_FMT_SRGGB14P): New constants, introduced by Linux commit
|
||||
v4.19-rc1~137^2~97.
|
||||
(V4L2_PIX_FMT_Y10P): New constant, introduced by Linux commit
|
||||
v4.19-rc1~137^2~95.
|
||||
---
|
||||
xlat/v4l2_pix_fmts.in | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/xlat/v4l2_pix_fmts.in b/xlat/v4l2_pix_fmts.in
|
||||
index c595d57..445ca7a 100644
|
||||
--- a/xlat/v4l2_pix_fmts.in
|
||||
+++ b/xlat/v4l2_pix_fmts.in
|
||||
@@ -114,6 +114,10 @@ V4L2_PIX_FMT_SRGGB12P v4l2_fourcc('p', 'R', 'C', 'C')
|
||||
V4L2_PIX_FMT_SGRBG12P v4l2_fourcc('p', 'g', 'C', 'C')
|
||||
V4L2_PIX_FMT_HEVC v4l2_fourcc('H', 'E', 'V', 'C')
|
||||
V4L2_PIX_FMT_XVID v4l2_fourcc('X', 'V', 'I', 'D') /* Xvid */
|
||||
+V4L2_PIX_FMT_SBGGR14P v4l2_fourcc('p', 'B', 'E', 'E')
|
||||
+V4L2_PIX_FMT_SGBRG14P v4l2_fourcc('p', 'G', 'E', 'E')
|
||||
+V4L2_PIX_FMT_SGRBG14P v4l2_fourcc('p', 'g', 'E', 'E')
|
||||
+V4L2_PIX_FMT_SRGGB14P v4l2_fourcc('p', 'R', 'E', 'E')
|
||||
V4L2_PIX_FMT_VC1_ANNEX_G v4l2_fourcc('V', 'C', '1', 'G') /* SMPTE 421M Annex G compliant stream */
|
||||
V4L2_PIX_FMT_IPU3_SGRBG10 v4l2_fourcc('i', 'p', '3', 'G') /* IPU3 packed 10-bit GRBG bayer */
|
||||
V4L2_PIX_FMT_SGRBG8 v4l2_fourcc('G', 'R', 'B', 'G') /* 8 GRGR.. BGBG.. */
|
||||
@@ -131,6 +135,7 @@ V4L2_PIX_FMT_VC1_ANNEX_L v4l2_fourcc('V', 'C', '1', 'L') /* SMPTE 421M Annex L c
|
||||
V4L2_PIX_FMT_JPGL v4l2_fourcc('J', 'P', 'G', 'L') /* JPEG-Lite */
|
||||
V4L2_PIX_FMT_RGB555 v4l2_fourcc('R', 'G', 'B', 'O') /* 16 RGB-5-5-5 */
|
||||
V4L2_PIX_FMT_YUV555 v4l2_fourcc('Y', 'U', 'V', 'O') /* 16 YUV-5-5-5 */
|
||||
+V4L2_PIX_FMT_Y10P v4l2_fourcc('Y', '1', '0', 'P') /* 10 Greyscale, MIPI RAW10 packed */
|
||||
V4L2_PIX_FMT_YUV411P v4l2_fourcc('4', '1', '1', 'P') /* 12 YVU411 planar */
|
||||
V4L2_PIX_FMT_Y41P v4l2_fourcc('Y', '4', '1', 'P') /* 12 YUV 4:1:1 */
|
||||
V4L2_PIX_FMT_YUV422P v4l2_fourcc('4', '2', '2', 'P') /* 16 YVU422 planar */
|
||||
@@ -138,6 +143,7 @@ V4L2_PIX_FMT_RGB565 v4l2_fourcc('R', 'G', 'B', 'P') /* 16 RGB-5-6-5 */
|
||||
V4L2_PIX_FMT_YUV565 v4l2_fourcc('Y', 'U', 'V', 'P') /* 16 YUV-5-6-5 */
|
||||
V4L2_PIX_FMT_RGB555X v4l2_fourcc('R', 'G', 'B', 'Q') /* 16 RGB-5-5-5 BE */
|
||||
V4L2_PIX_FMT_RGB565X v4l2_fourcc('R', 'G', 'B', 'R') /* 16 RGB-5-6-5 BE */
|
||||
+V4L2_PIX_FMT_FWHT v4l2_fourcc('F', 'W', 'H', 'T') /* Fast Walsh Hadamard Transform (vicodec) */
|
||||
V4L2_PIX_FMT_YVYU v4l2_fourcc('Y', 'V', 'Y', 'U') /* 16 YVU 4:2:2 */
|
||||
V4L2_PIX_FMT_CIT_YYVYUY v4l2_fourcc('C', 'I', 'T', 'V') /* one line of Y then 1 line of VYUY */
|
||||
V4L2_PIX_FMT_YYUV v4l2_fourcc('Y', 'Y', 'U', 'V') /* 16 YUV 4:2:2 */
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
56
xlat-workaround-V4L2_CID_USER_IMX_BASE-Linux-kernel-.patch
Normal file
56
xlat-workaround-V4L2_CID_USER_IMX_BASE-Linux-kernel-.patch
Normal file
@ -0,0 +1,56 @@
|
||||
From b89a69dec27cf638df0e17db80ed937c3e1abf77 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Sat, 18 Aug 2018 07:22:47 +0000
|
||||
Subject: [PATCH 002/293] xlat: workaround V4L2_CID_USER_IMX_BASE Linux kernel
|
||||
ABI breakage
|
||||
|
||||
Linux kernel commit v4.18-rc2-106-g421860b9d47053badce4b247576fa48df9ab4c48
|
||||
has changed the value of V4L2_CID_USER_IMX_BASE constant introduced
|
||||
by commit v4.13-rc1~141^2~121 because the old value was already used
|
||||
by V4L2_CID_USER_MAX217X_BASE.
|
||||
|
||||
This is of course an ABI breakage that affects Linux kernels starting
|
||||
with 4.13 and up to 4.18, as well as their LTS derivatives.
|
||||
|
||||
Since the imx driver didn't provide any public control ID definitions,
|
||||
it looks like the best way to handle this situation is to pretend that
|
||||
the old value of V4L2_CID_USER_IMX_BASE didn't exist.
|
||||
|
||||
* xlat/v4l2_control_id_bases.in (V4L2_CID_USER_IMX_BASE): Redefine.
|
||||
|
||||
Co-Authored-by: Eugene Syromyatnikov <evgsyr@gmail.com>
|
||||
---
|
||||
xlat/v4l2_control_id_bases.in | 17 ++++++++++++++++-
|
||||
1 file changed, 16 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xlat/v4l2_control_id_bases.in b/xlat/v4l2_control_id_bases.in
|
||||
index a0359be..f3fd925 100644
|
||||
--- a/xlat/v4l2_control_id_bases.in
|
||||
+++ b/xlat/v4l2_control_id_bases.in
|
||||
@@ -2,7 +2,22 @@ V4L2_CID_BASE (V4L2_CTRL_CLASS_USER | 0x900)
|
||||
V4L2_CID_USER_MEYE_BASE (V4L2_CID_BASE + 0x1000)
|
||||
V4L2_CID_USER_BTTV_BASE (V4L2_CID_BASE + 0x1010)
|
||||
V4L2_CID_USER_TI_VPE_BASE (V4L2_CID_BASE + 0x1050)
|
||||
-V4L2_CID_USER_IMX_BASE (V4L2_CID_BASE + 0x1090)
|
||||
+#ifndef STRACE_WORKAROUND_FOR_V4L2_CID_USER_IMX_BASE
|
||||
+# define STRACE_WORKAROUND_FOR_V4L2_CID_USER_IMX_BASE
|
||||
+/*
|
||||
+ * Linux kernel commit v4.18-rc2-106-g421860b9d47053badce4b247576fa48df9ab4c48
|
||||
+ * has changed the value of V4L2_CID_USER_IMX_BASE constant introduced
|
||||
+ * by commit v4.13-rc1~141^2~121 because the old value was already used
|
||||
+ * by V4L2_CID_USER_MAX217X_BASE.
|
||||
+ * This is of course an ABI breakage that affects Linux kernels starting
|
||||
+ * with 4.13 and up to 4.18, as well as their LTS derivatives.
|
||||
+ * Since the imx driver didn't provide any public control ID definitions,
|
||||
+ * it looks like the best way to handle this situation is to pretend that
|
||||
+ * the old value of V4L2_CID_USER_IMX_BASE didn't exist.
|
||||
+ */
|
||||
+# undef V4L2_CID_USER_IMX_BASE
|
||||
+#endif
|
||||
+V4L2_CID_USER_IMX_BASE (V4L2_CID_BASE + 0x10b0)
|
||||
V4L2_CID_MPEG_BASE (V4L2_CTRL_CLASS_MPEG | 0x900)
|
||||
V4L2_CID_MPEG_CX2341X_BASE (V4L2_CTRL_CLASS_MPEG | 0x1000)
|
||||
V4L2_CID_MPEG_MFC51_BASE (V4L2_CTRL_CLASS_MPEG | 0x1100)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
30
xlat_idx-do-not-issue-warnings-for-holes-in-indices.patch
Normal file
30
xlat_idx-do-not-issue-warnings-for-holes-in-indices.patch
Normal file
@ -0,0 +1,30 @@
|
||||
From b967e34d70895b799d16f5d45a9a5228d7eb73a3 Mon Sep 17 00:00:00 2001
|
||||
From: "Dmitry V. Levin" <ldv@altlinux.org>
|
||||
Date: Mon, 24 Dec 2018 10:19:24 +0000
|
||||
Subject: [PATCH 161/294] xlat_idx: do not issue warnings for holes in indices
|
||||
|
||||
Some xlat indices like evdev_abs have holes, avoid issuing warnings
|
||||
about them.
|
||||
|
||||
* xlat.c (xlat_idx): Do not issue warnings for holes in the index.
|
||||
---
|
||||
xlat.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/xlat.c b/xlat.c
|
||||
index 16bfb94..62245f9 100644
|
||||
--- a/xlat.c
|
||||
+++ b/xlat.c
|
||||
@@ -249,6 +249,9 @@ xlat_idx(const struct xlat *xlat, size_t nmemb, uint64_t val)
|
||||
return NULL;
|
||||
|
||||
if (val != pos[val].val) {
|
||||
+ if (pos[val].val == 0)
|
||||
+ return NULL; /* a hole in the index */
|
||||
+
|
||||
error_func_msg("Unexpected xlat value %" PRIu64
|
||||
" at index %" PRIu64,
|
||||
pos[val].val, val);
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user