Project import
diff --git a/strace/.mailmap b/strace/.mailmap
new file mode 100644
index 0000000..a04a2f8
--- /dev/null
+++ b/strace/.mailmap
@@ -0,0 +1,7 @@
+# Map git author names and email addresses to canonical/preferred form.
+<ak@linux.intel.com>	<ak@suse.de>
+<holger@freyther.de>	<zecke@selfish.org>
+<kirill@shutemov.name>	<kirill.shutemov@linux.intel.com>
+<schwab@linux-m68k.org>	<schwab@redhat.com>
+<schwab@linux-m68k.org>	<schwab@suse.de>
+<vda.linux@googlemail.com>	<dvlasenk@redhat.com>
diff --git a/strace/.travis.yml b/strace/.travis.yml
new file mode 100644
index 0000000..d3307a0
--- /dev/null
+++ b/strace/.travis.yml
@@ -0,0 +1,41 @@
+language: c
+
+dist: trusty
+
+before_install: ./travis-install.sh
+
+script: ./travis-build.sh
+
+after_success: ./travis-success.sh
+
+sudo: required
+
+git:
+  depth: 2147483647
+
+env:
+  global:
+    - SLEEP_A_BIT="sleep 0.2"
+    - VERBOSE="1"
+
+matrix:
+  include:
+    - compiler: gcc
+      env:
+        - TARGET=x86_64
+        - COVERAGE=true
+    - compiler: gcc
+      env:
+        - TARGET=x32
+    - compiler: gcc
+      env:
+        - TARGET=x86
+    - compiler: clang-3.6
+      env:
+        - TARGET=x86_64
+    - compiler: musl-gcc
+      env:
+        - TARGET=x86_64
+    - compiler: clang-3.6
+      env:
+        - TARGET=x86
diff --git a/strace/AUTHORS b/strace/AUTHORS
new file mode 100644
index 0000000..bbba831
--- /dev/null
+++ b/strace/AUTHORS
@@ -0,0 +1 @@
+See the file CREDITS.  Automake likes us to have this file called AUTHORS.
diff --git a/strace/Android.mk b/strace/Android.mk
new file mode 100644
index 0000000..86f6bae
--- /dev/null
+++ b/strace/Android.mk
@@ -0,0 +1,359 @@
+#
+# Copyright (C) 2006 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+LOCAL_PATH := $(call my-dir)
+
+#
+# To update:
+#
+
+#  repo sync .
+#  repo start merge .
+#  git merge aosp/upstream-master --no-ff # resolve any conflicts
+#  ./configure && make
+#  mm -j32
+#  # (Make any necessary Android.mk changes and test the new strace.)
+#  # Beware the .gitignore files --- xlat especially.
+#  git commit -a --amend
+#
+
+# We don't currently have a good solution for the 'configure' side of things.
+# You can get a list of the HAVE_* variables in use and manually go through it:
+#
+#   find . -name "*.[ch]" | xargs grep HAVE_ | sed 's/.*\(HAVE_[A-Z0-9_]*\).*/\1/p' | grep -v HAVE_DECL_ | sort | uniq -d
+
+# -------------------------------------------------------------------------
+
+include $(CLEAR_VARS)
+
+strace_version := $(shell grep strace $(LOCAL_PATH)/debian/changelog.in | \
+                          head -2 | tail -1 | cut -d " " -f 2)
+
+LOCAL_SRC_FILES := \
+    access.c \
+    affinity.c \
+    aio.c \
+    bjm.c \
+    block.c \
+    bpf.c \
+    btrfs.c \
+    cacheflush.c \
+    capability.c \
+    chdir.c \
+    chmod.c \
+    clone.c \
+    copy_file_range.c \
+    count.c \
+    desc.c \
+    dirent.c \
+    dirent64.c \
+    epoll.c \
+    evdev.c \
+    eventfd.c \
+    execve.c \
+    exit.c \
+    fadvise.c \
+    fallocate.c \
+    fanotify.c \
+    fchownat.c \
+    fcntl.c \
+    fetch_seccomp_fprog.c \
+    fetch_struct_flock.c \
+    fetch_struct_mmsghdr.c \
+    fetch_struct_msghdr.c \
+    fetch_struct_statfs.c \
+    file.c \
+    file_handle.c \
+    file_ioctl.c \
+    flock.c \
+    fstatfs.c \
+    fstatfs64.c \
+    fs_x_ioctl.c \
+    futex.c \
+    getcpu.c \
+    getcwd.c \
+    getrandom.c \
+    get_robust_list.c \
+    hdio.c \
+    hostname.c \
+    inotify.c \
+    io.c \
+    ioctl.c \
+    ioperm.c \
+    iopl.c \
+    ioprio.c \
+    ipc.c \
+    ipc_msg.c \
+    ipc_msgctl.c \
+    ipc_sem.c \
+    ipc_shm.c \
+    ipc_shmctl.c \
+    kcmp.c \
+    kexec.c \
+    keyctl.c \
+    ldt.c \
+    link.c \
+    lookup_dcookie.c \
+    loop.c \
+    lseek.c \
+    mem.c \
+    membarrier.c \
+    memfd_create.c \
+    mknod.c \
+    mmsghdr.c \
+    mount.c \
+    mq.c \
+    msghdr.c \
+    mtd.c \
+    net.c \
+    netlink.c \
+    numa.c \
+    open.c \
+    pathtrace.c \
+    perf.c \
+    personality.c \
+    poll.c \
+    prctl.c \
+    print_mq_attr.c \
+    print_msgbuf.c \
+    print_sigevent.c \
+    print_statfs.c \
+    print_time.c \
+    print_timex.c \
+    printmode.c \
+    printrusage.c \
+    printsiginfo.c \
+    process.c \
+    process_vm.c \
+    ptp.c \
+    quota.c \
+    readahead.c \
+    readlink.c \
+    reboot.c \
+    renameat.c \
+    resource.c \
+    rtc.c \
+    sched.c \
+    scsi.c \
+    seccomp.c \
+    sendfile.c \
+    sigaltstack.c \
+    signal.c \
+    signalfd.c \
+    sigreturn.c \
+    sock.c \
+    sockaddr.c \
+    socketcall.c \
+    socketutils.c \
+    sram_alloc.c \
+    statfs.c \
+    statfs64.c \
+    strace.c \
+    swapon.c \
+    sync_file_range.c \
+    sync_file_range2.c \
+    syscall.c \
+    sysctl.c \
+    sysinfo.c \
+    syslog.c \
+    sysmips.c \
+    term.c \
+    time.c \
+    times.c \
+    truncate.c \
+    ubi.c \
+    uid16.c \
+    uid.c \
+    umask.c \
+    umount.c \
+    uname.c \
+    upeek.c \
+    userfaultfd.c \
+    util.c \
+    utime.c \
+    utimes.c \
+    v4l2.c \
+    vsprintf.c \
+    wait.c \
+    xattr.c \
+    xmalloc.c \
+
+LOCAL_SHARED_LIBRARIES :=
+
+#    -DHAVE_DECL_PTRACE_EVENT_FORK=1 \
+    -DHAVE_DECL_PTRACE_EVENT_VFORK=1 \
+    -DHAVE_DECL_PTRACE_EVENT_CLONE=1 \
+    -DHAVE_DECL_PTRACE_EVENT_EXEC=1 \
+    -DHAVE_DECL_PTRACE_EVENT_VFORK_DONE=1 \
+    -DHAVE_DECL_PTRACE_EVENT_EXIT=1 \
+    -DHAVE_DECL_PTRACE_GETEVENTMSG=1 \
+    -DHAVE_DECL_PTRACE_GETSIGINFO=1 \
+    -DHAVE_DECL_PTRACE_O_TRACECLONE=1 \
+    -DHAVE_DECL_PTRACE_O_TRACEEXEC=1 \
+    -DHAVE_DECL_PTRACE_O_TRACEEXIT=1 \
+    -DHAVE_DECL_PTRACE_O_TRACEFORK=1 \
+    -DHAVE_DECL_PTRACE_O_TRACESYSGOOD=1 \
+    -DHAVE_DECL_PTRACE_O_TRACEVFORK=1 \
+    -DHAVE_DECL_PTRACE_SETOPTIONS=1 \
+    -UHAVE_DECL_IO_CMD_PWRITE \
+    -UHAVE_DECL_IO_CMD_PWRITEV \
+    -UHAVE_DECL_LO_FLAGS_AUTOCLEAR \
+    -UHAVE_DECL_LO_FLAGS_PARTSCAN \
+    -DHAVE_DECL_SYS_ERRLIST=1 \
+
+LOCAL_CFLAGS := \
+    -DGETGROUPS_T=gid_t \
+    \
+    -UHAVE_ASM_CACHECTL_H \
+    -DHAVE_ASM_SIGCONTEXT_H=1 \
+    -DHAVE_BLKGETSIZE64=1 \
+    -UHAVE_BLUETOOTH_BLUETOOTH_H \
+    -DHAVE___BUILTIN_POPCOUNT=1 \
+    -DHAVE_DIRENT_H=1 \
+    -DHAVE_DLADDR=1 \
+    -DHAVE_ELF_H=1 \
+    -DHAVE_FOPEN64=1 \
+    -DHAVE_FORK=1 \
+    -DHAVE_FSTATAT=1 \
+    -DHAVE_FTRUNCATE=1 \
+    -DHAVE_FUTIMENS=1 \
+    -DHAVE_IF_INDEXTONAME=1 \
+    -DHAVE_INET_NTOP=1 \
+    -DHAVE_INET_PTON=1 \
+    -DHAVE_INTTYPES_H=1 \
+    -DHAVE_LINUX_BPF_H=1 \
+    -DHAVE_LINUX_BSG_H=1 \
+    -DHAVE_LINUX_BTRFS_H=1 \
+    -DHAVE_LINUX_FALLOC_H=1 \
+    -DHAVE_LINUX_FILTER_H=1 \
+    -DHAVE_LINUX_FUTEX_H=1 \
+    -DHAVE_LINUX_ICMP_H=1 \
+    -DHAVE_LINUX_IF_PACKET_H=1 \
+    -DHAVE_LINUX_INPUT_H=1 \
+    -DHAVE_LINUX_IN6_H=1 \
+    -DHAVE_LINUX_IPC_H=1 \
+    -DHAVE_LINUX_MQUEUE=1 \
+    -DHAVE_LINUX_MSG_H=1 \
+    -DHAVE_LINUX_NETLINK_H=1 \
+    -DHAVE_LINUX_PERF_EVENT_H=1 \
+    -DHAVE_LINUX_SEM_H=1 \
+    -DHAVE_LINUX_SHM_H=1 \
+    -DHAVE_LITTLE_ENDIAN_LONG_LONG=1 \
+    -DHAVE_LONG_LONG=1 \
+    -DHAVE_NETINET_TCP_H=1 \
+    -DHAVE_NETINET_UDP_H=1 \
+    -DHAVE_POLL_H=1 \
+    -DHAVE_PRCTL=1 \
+    -DHAVE_PWRITEV=1 \
+    -DHAVE_SENDMSG=1 \
+    -DHAVE_SIGACTION=1 \
+    -DHAVE_SIG_ATOMIC_T=1 \
+    -DHAVE_SIGINFO_T=1 \
+    -DHAVE_SIGINFO_T_SI_OVERRUN=1 \
+    -DHAVE_SIGINFO_T_SI_SYSCALL=1 \
+    -DHAVE_SIGINFO_T_SI_TIMERID=1 \
+    -UHAVE_STAT64 \
+    -DHAVE_STATFS64=1 \
+    -DHAVE_STDBOOL_H=1 \
+    -DHAVE_STRERROR=1 \
+    -DHAVE_STRUCT_BTRFS_IOCTL_FEATURE_FLAGS_COMPAT_FLAGS=1 \
+    -DHAVE_STRUCT_FLOCK=1 \
+    -DHAVE_STRUCT_FLOCK64=1 \
+    -DHAVE_STRUCT_MMSGHDR=1 \
+    -DHAVE_STRUCT_MSGHDR_MSG_CONTROL=1 \
+    -DHAVE_STRUCT_SIGCONTEXT=1 \
+    -DHAVE_STRUCT_SIGEVENT__SIGEV_UN__PAD=1 \
+    -DHAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID=1 \
+    -DHAVE_STRUCT_STATFS64=1 \
+    -UHAVE_STRUCT_STAT_ST_ACLCNT \
+    -DHAVE_STRUCT_STAT_ST_BLKSIZE=1 \
+    -DHAVE_STRUCT_STAT_ST_BLOCKS=1 \
+    -UHAVE_STRUCT_STAT_ST_FLAGS \
+    -UHAVE_STRUCT_STAT_ST_FSTYPE \
+    -UHAVE_STRUCT_STAT_ST_GEN \
+    -UHAVE_STRUCT_STAT_ST_LEVEL \
+    -DHAVE_STRUCT_STAT_ST_RDEV=1 \
+    -DHAVE_STRUCT_SYSINFO_FREEHIGH=1 \
+    -DHAVE_STRUCT_SYSINFO_MEM_UNIT=1 \
+    -DHAVE_STRUCT_SYSINFO_TOTALHIGH=1 \
+    -DHAVE_STRUCT_UTSNAME_DOMAINNAME=1 \
+    -DHAVE_SYS_EPOLL_H=1 \
+    -DHAVE_SYS_IOCTL_H=1 \
+    -DHAVE_SYS_POLL_H=1 \
+    -DHAVE_SYS_REG_H=1 \
+    -DHAVE_SYS_VFS_H=1 \
+    -DHAVE_SYS_XATTR_H=1 \
+    -DHAVE_UNISTD_H=1 \
+    -DHAVE_UTIMENSAT=1 \
+    \
+    -DMAJOR_IN_SYSMACROS \
+    -DPACKAGE_NAME='"strace"' \
+    -DVERSION='"$(strace_version)"' \
+    -DSIZEOF_OFF_T=SIZEOF_LONG \
+    -DSIZEOF_LONG_LONG=8 \
+    -DSTDC_HEADERS=1 \
+    -DSTRACE_KNOWS_ONLY_EABI=1 \
+    -D_LFS64_LARGEFILE=1 \
+
+LOCAL_CFLAGS += -D_GNU_SOURCE=1 -D_POSIX_SOURCE=1
+
+LOCAL_CFLAGS += -fno-strict-aliasing
+
+LOCAL_CFLAGS_32 += -DSIZEOF_LONG=4 -DSIZEOF_RLIM_T=4 -DHAVE_STAT64=1
+LOCAL_CFLAGS_64 += -DSIZEOF_LONG=8 -DSIZEOF_RLIM_T=8
+
+LOCAL_CFLAGS_arm += -DARM=1
+LOCAL_CFLAGS_arm += -DHAVE_STRUCT___OLD_KERNEL_STAT=1
+
+LOCAL_CFLAGS_arm64 += -DAARCH64=1
+
+LOCAL_CFLAGS_mips += -DMIPS=1 -DLINUX_MIPSO32=1
+LOCAL_CFLAGS_mips += -DHAVE_ASM_SYSMIPS_H=1
+
+LOCAL_CFLAGS_mips64 += -DMIPS=1 -DLINUX_MIPSN64=1
+LOCAL_CFLAGS_mips64 += -DHAVE_ASM_SYSMIPS_H=1
+
+LOCAL_CFLAGS_x86 += -DI386=1
+LOCAL_CFLAGS_x86 += -DHAVE_STRUCT___OLD_KERNEL_STAT=1
+
+LOCAL_CFLAGS_x86_64 += -DX86_64=1
+
+LOCAL_CFLAGS += \
+    -Wall \
+    -Wwrite-strings \
+    -Wsign-compare \
+    -Wno-missing-field-initializers \
+    -Wno-unused-parameter \
+    -Wno-sign-compare \
+
+LOCAL_C_INCLUDES_arm := $(LOCAL_PATH)/linux/arm $(LOCAL_PATH)/linux
+LOCAL_C_INCLUDES_arm64 := $(LOCAL_PATH)/linux/aarch64 $(LOCAL_PATH)/linux
+LOCAL_C_INCLUDES_mips := $(LOCAL_PATH)/linux/mips $(LOCAL_PATH)/linux
+LOCAL_C_INCLUDES_mips64 := $(LOCAL_PATH)/linux/mips $(LOCAL_PATH)/linux
+LOCAL_C_INCLUDES_x86 := $(LOCAL_PATH)/linux/i386 $(LOCAL_PATH)/linux
+LOCAL_C_INCLUDES_x86_64 := $(LOCAL_PATH)/linux/x86_64 $(LOCAL_PATH)/linux
+
+LOCAL_CLANG := true
+
+LOCAL_MODULE := strace
+
+LOCAL_MODULE_PATH := $(TARGET_OUT_OPTIONAL_EXECUTABLES)
+
+LOCAL_MODULE_TAGS := debug
+
+LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
+
+include $(BUILD_EXECUTABLE)
diff --git a/strace/COPYING b/strace/COPYING
new file mode 100644
index 0000000..e9078d3
--- /dev/null
+++ b/strace/COPYING
@@ -0,0 +1,29 @@
+Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+Copyright (c) 1995, 1996 Michael Elizabeth Chastain <mec@duracef.shout.net>
+Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+Copyright (C) 1998-2001 Wichert Akkerman <wakkerma@deephackmode.org>
+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.
diff --git a/strace/CREDITS.in b/strace/CREDITS.in
new file mode 100644
index 0000000..d55f2f8
--- /dev/null
+++ b/strace/CREDITS.in
@@ -0,0 +1,91 @@
+The primary authors of strace were:
+
+	Paul Kranenburg <pk@cs.few.eur.nl>
+	Branko Lankester <branko@hacktic.nl>
+	Rick Sladkey <jrs@world.std.com>
+
+These people have contributed to strace.  Some have reported problems, others
+have contributed improvements to the documentation, actual code, provided
+information, provided resources, or helped to port strace to new systems.
+Those contributions are described in the version control logs and ChangeLog-CVS
+file.  If your name has been left out, if you'd rather not be listed, or if
+you'd prefer a different address be used, please send a note to the
+strace-devel@lists.sourceforge.net mailing list.
+
+##<
+## There is no need to list here any name that appears as an Author in
+## "git log" output.  Those are automatically added when this template
+## is used to generate the CREDITS file.
+##>
+Aaron Ucko                      ucko@vax1.rockhurst.edu
+Adrien Kunysz                   adrien@kunysz.be
+Anton Blanchard                 anton@samba.org
+Arkadiusz Miskiewicz            misiek@pld.org.pl
+Bai Weidong                     baiwd@cn.fujitsu.com
+Bo Kullmar                      bk@kullmar.se
+Cai Fei                         caifei@cn.fujitsu.com
+D.J. Barrow                     djbarrow@de.ibm.com
+David Mosberger-Tang            davidm@hpl.hp.com
+David S. Miller                 davem@caip.rutgers.edu
+David Wilder                    wilder@us.ibm.com
+David Woodhouse                 dwmw2@redhat.com
+Douglas Mencken                 dougmencken@gmail.com
+Fernando Luis Vazquez Cao       fernando@oss.ntt.co.jp
+Florian Lohoff                  flo@rfc822.org
+Gabor Gombas                    gombasg@sztaki.hu
+Ganesan Rajagopal               rganesan@myrealbox.com
+Gaël Roualland                  gael.roualland@iname.com
+Greg Banks                      gbanks@pocketpenguins.com
+Henrik Storner                  storner@osiris.ping.dk
+Jakub Jelinek                   jj@ultra.linux.cz
+Jeff Mahoney                    jeffm@suse.com
+Jian Zhen                       zhenjl@gmail.com
+Joe Ilacqua                     spike@world.std.com
+Johannes Stezenbach             js@sig21.net
+Ju"rgen Fluk                    louis@marco.de
+Juergen Weigert                 jnweiger@immd4.informatik.uni-erlangen.de
+Keith Thompson                  kst@alsys.com
+Kyle McMartin                   kyle@mcmartin.ca
+Lai JiangShan                   laijs@cn.fujitsu.com
+Leonard N. Zubkoff              lnz@dandelion.com
+Linus Torvalds                  Linus.Torvalds@cs.helsinki.fi
+Lupe Christoph                  lupe@alanya.isar.muc.de
+Marty Leisner                   leisner@sdsp.mc.xerox.com
+Matt Day                        mday@artisoft.com
+Matthias Pfaller                leo@dachau.marco.de
+Maxim Shchetynin                maxim@de.ibm.com
+Michael E Chastain              mec@duracef.shout.net
+Michael Holzheu                 holzheu@de.ibm.com
+Michail Litvak                  mci@owl.openwall.com
+Mike Stroyan                    mike.stroyan@hp.com
+Muttley Meen                    muttley.meen@gmail.com
+Nate Eldredge                   nate@cartsys.com
+Paul Mundt                      lethal@linux-sh.org
+Peter Jones                     pjones@redhat.com
+Pádraig Brady                   P@draigBrady.com
+Rajeev V. Pillai                rajeevvp@gmail.com
+Randolph Chung                  tausq@debian.org
+Reuben Sumner                   rasumner@undergrad.math.uwaterloo.ca
+Richard Braakman                dark@xs4all.nl
+Richard Henderson               richard@twiddle.tamu.edu
+Richard Hirst                   rhirst@linuxcare.com
+Roland Borde                    bo@uebemc.siemens.de
+Sami Farin                      safari@u.safari.iki.fi
+Scott Tsai                      scottt958@yahoo.com.tw
+Simon Murray                    simon@transitive.com
+Solar Designer                  solar@openwall.com
+Srinivasa Ds                    srinivasa@in.ibm.com
+Steve Bennett                   steveb@workware.net.au
+Thanh Ma                        tma@encore.com
+Thiemo Seufer                   ths@networkno.de
+Thomas Bogendoerfer             tsbogend@bigbug.franken.de
+Tim Yamin                       plasmaroo@gentoo.org
+Timo Lindfors                   timo.lindfors@iki.fi
+Tom Dyas                        tdyas@eden.rutgers.edu
+Tommi Rantala                   ext-tommi.1.rantala@nokia.com
+Topi Miettinen                  Topi.Miettinen@nic.fi
+Xiaoning Ding                   dingxn@gmail.com
+Yang Zhiguo                     yzgcsu@cn.fujitsu.com
+Zach Brown                      zach.brown@oracle.com
+Zhang Le                        zhilg@users.sourceforge.net
+Марк Коренберг                  socketpair@gmail.com
diff --git a/strace/ChangeLog-CVS b/strace/ChangeLog-CVS
new file mode 100644
index 0000000..b5262ad
--- /dev/null
+++ b/strace/ChangeLog-CVS
@@ -0,0 +1,5614 @@
+2009-07-08  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Clean up spacing to fix warnings reported by git diff --check.
+	* ChangeLog: Fix spaces before tab in indent.
+	* bjm.c: Likewise.
+	* debian/changelog: Likewise.
+	* strace-graph: Likewise.
+	* syscall.c: Likewise.
+	* INSTALL: Fix trailing blank lines.
+	* README-linux: Likewise.
+	* README-svr4: Likewise.
+	* linux/sparc/gen.pl: Likewise.
+	* linux/sparc/syscall1.h: Likewise.
+	* linux/sparc64/syscall1.h: Likewise.
+	* linux/x86_64/gentab.pl: Likewise.
+	* sunos4/syscall.h: Likewise.
+	* test/Makefile: Likewise.
+	* debian/rules: Fix trailing whitespaces.
+	* desc.c: Likewise.
+	* svr4/syscallent.h: Likewise.
+	* test/childthread.c: Likewise.
+	* test/leaderkill.c: Likewise.
+
+2009-07-07  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* .cvsignore: Remove.
+	* README-CVS: Rename to README-hacking.
+	* Makefile.am (EXTRA_DIST): Remove README-CVS.
+
+2009-06-01  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* bjm.c (sys_query_module): Fix format warning reported by
+	gcc -Wformat-security.
+	* file.c (tprint_open_modes): Likewise.
+	* process.c (printargv): Likewise.
+	* signal.c (printsignal): Likewise.
+
+	Clean up header checks.
+	* configure.ac: Reformat AC_CHECK_HEADERS to keep it sorted and
+	easily updated, and reduce merging errors in the future.
+	* system.c: Convert all non-standard #ifdef checks for specific
+	headers to regular #ifdef HAVE_*_H checks.
+	Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+2009-04-20  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* file.c (printstatsol, printstat_sparc64):
+	Remove NULL/error check for addr parameter.
+	(printoldstat, printstat, printoldstat64):
+	Move NULL/error check for addr parameter
+	so that it happens before printstatsol/printstat_sparc64 calls.
+
+2009-04-16  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* file.c (print_dirfd): Use int for file descriptor, not a long.
+	* process.c (printwaitn): Use int for PID, not a long.
+
+2009-04-15  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* signal (sys_rt_sigtimedwait): Fix sigtimedwait syscall decoding.
+
+2009-04-15  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* signal (sys_rt_sigaction): Print struct sigaction correctly
+	in 32/64 environment.
+	* desc.c (printflock): Add #ifdefs around earlier flock 32/64 fix
+	so that we don't waste time on arches with one personality.
+
+2009-04-14  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* signal.c: Whitespace, comment, and style fixes, no code changes.
+	* file.c: Ditto.
+	* time.c: Ditto.
+	* process.c: Ditto.
+	* resource.c: Ditto.
+
+2009-03-23  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* system.c (sram_alloc_flag): Add L2_SRAM constant.
+	by Mike Frysinger (vapier AT gentoo.org).
+	(sys_sram_alloc): Fix improperly used %zu:
+	tcp->u_arg is not a size_t, it is a long.
+	* net.c (printcmsghdr): Fix improperly used %zu:
+	struct cmsghdr::cmsg_len is not a size_t.
+
+2009-03-10  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Decode fcntl's F_{GET,SET}LEASE, F_NOTIFY, and F_DUPFD_CLOEXEC.
+	By Mike Frysinger (vapier AT gentoo.org)
+	* desc.c: Add F_SETLEASE, F_GETLEASE, F_NOTIFY,
+	F_DUPFD_CLOEXEC to fcntlcmds[]. Create notifyflags[] array.
+	(sys_fcntl): Handle new flags.
+
+	Optimize printing of open modes.
+	* defs.h: Declare sprint_open_modes(),
+	remove unused parameter in tprint_open_modes().
+	* desc.c (sprint_open_modes): Move fuction definition from here...
+	* file.c (sprint_open_modes): To here.
+	(tprint_open_modes): Use sprint_open_modes(), it already
+	generates needed string.
+	* ipc.c: Remove unused parameter from calls
+	to tprint_open_modes().
+
+2009-02-27  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	AVR32 support by Hans-Christian Egtvedt
+	(hans-christian.egtvedt AT atmel.com).
+	* configure.ac: Make it recognize avr32.
+	* defs.h: Define LINUX_AVR32.
+	* linux/avr32/syscallent.h: New file.
+	* Makefile.am: Reference linux/avr32/syscallent.h.
+	* proc.c (change_syscall, setarg): Add support for avr32.
+	(struct xlat struct_user_offsets[]): Ditto.
+	* syscall.c (get_scno): Ditto.
+	(get_error, force_result, syscall_enter): Ditto.
+	* util.c (getpc, printcall): Ditto.
+
+2009-02-25  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	CRIS support by Hinko Kocevar (hinko.kocevar AT cetrtapot.si)
+	* configure.ac: Make it recognize cris.
+	* process.c: Define ARG_xxx constants for cris.
+	(change_syscall): Add support for cris.
+	(struct_user_offsets): Add cris-specific data.
+	* signal.c (sys_sigreturn): Add support for cris.
+	* syscall.c (get_scno): Add support for cris.
+	(syscall_fixup): Add support for cris.
+	(get_error): Add support for cris.
+	(syscall_enter): Add support for cris.
+	(force_result): While at it, fix cpp directives indentation.
+	* util.c (printcall): Add support for cris.
+
+2009-02-24  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* process.c: Indent preprocessor directives so that nesting
+	can be figured out. Add PTRACE_SET_SYSCALL to ptrace_cmds[].
+	* ioctlent.sh: Improved by Mike Frysinger.
+	* HACKING-scripts: New file by Mike Frysinger.
+
+2009-02-20  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Further signalent.h cleanup.
+	* linux/ia64/signalent.h: Remove, it is identical to common signalent.h
+	sans "SIGRTnn" definitions which are redundant.
+	* linux/powerpc/signalent.h: Remove, it is identical to common signalent.h
+	sans outdated "SIGUNUSED" which should be "SIGSYS".
+	* linux/s390/signalent.h: Ditto.
+	* linux/s390x/signalent.h: Ditto.
+	* Makefile.am: Remove references to the above files.
+
+2009-02-20  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Patch by Mike Frysinger (vapier AT gentoo.org).
+	* linux/ioctlent.sh: Update sed machinery to parse _IOC() macros
+	with two constants.
+
+2009-02-20  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Patch by Mike Frysinger (vapier AT gentoo.org).
+	* Makefile.am: Remove reference to linux/sh/signalent.h.
+	* linux/sh/signalent.h: Remove, it is identical to common signalent.h.
+
+2009-02-20  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Patch by Mike Frysinger (vapier AT gentoo.org).
+	* linux/errnoent.h: Make ERRNO_58 show EDEADLOCK for POWERPC.
+	* Makefile.am: Remove reference to linux/powerpc/errnoent.h.
+	* linux/powerpc/errnoent.h: Remove, we can use common errnoent.h now.
+
+2009-02-20  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Patch by Mike Frysinger (vapier AT gentoo.org).
+	Removing redundant errnoent.h files.
+	* Makefile.am: Remove reference to linux/ia64/errnoent.h,
+	linux/s390/errnoent.h, linux/s390x/errnoent.h and linux/sh/errnoent.h.
+	* linux/ia64/errnoent.h: Remove, this arch uses common errnoent.h.
+	* linux/s390/errnoent.h: Ditto.
+	* linux/s390x/errnoent.h: Ditto.
+	* linux/sh/errnoent.h: Ditto.
+
+2009-02-10  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: Check for struct sigcontext.
+	* signal.c [LINUX] [M68K] (struct sigcontext): Don't define it if
+	[HAVE_STRUCT_SIGCONTEXT].
+	From Muttley Meen <muttley.meen@gmail.com>.
+
+2009-02-09  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* defs.h: Correct the comment about TCB_SUSPENDED.
+	* strace.c: Fix misplaced #endif.
+	* util.c: Indent preprocessor directives, mark code parts
+	which can never be reached by compilation because of
+	the combination of #if directives. These are likely dead code,
+	I want to remove them later.
+
+2009-01-29  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* strace.c (newoutf): Prevent -o FILENAME overflowing the stack.
+	(startup_attach): Fix wrong pid in "Process <PID> attached".
+	(handle_group_exit): Do not consider exit to be spurious if
+	tcb has TCB_STARTUP bit set - we can attach to the task
+	right before its death, it can legitimately happen.
+	(handle_stopped_tcbs): Ditto.
+
+2009-01-26  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* process.c (printwaitn): Add comment about wait4() pid expansion.
+	Use #ifdef ALPHA instead of LINUX_64BIT, it was misleading
+	(by implying "any 64-bit platform").
+	* defs.h: Remove now-unused LINUX_64BIT define.
+	* resource.c (sys_osf_getrusage): Fix indentation.
+
+2009-01-26  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* process.c (internal_clone): Fix fallout from tcb table expansion
+	simplification. Due to overlooked else, I forgot to group
+	fork_tcb(tcp) and alloctcb(pid) in a block.
+
+2009-01-23  Michal Nowak  <mnowak@redhat.com>
+
+	* syscall.c (get_scno): Fix warnings about unused variable 'pid'.
+
+2009-01-23  Michal Nowak  <mnowak@redhat.com>
+
+	* mem.c (print_ldt_entry): Fix warning:
+	Format '%#08lx' expects type 'long unsigned int', but
+	argument 2 was type 'unsigned int'.
+
+2009-01-17  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Two cleanups: tcb table expansion failure is not really a survivable
+	event, we do not have any viable way to continue. No wonder most
+	places where that is detected have FIXMEs.
+	It's way simpler to treat as fatal failure, and handle it inside
+	tcb table expansion finctions.
+	Second cleanup: tidy up haphazard locations of a few externs.
+
+	* defs.h: Change return type of expand_tcbtab() to void.
+	Declare change_syscall().
+	* process.c: Change all callsites of alloctcb(), alloc_tcb() and
+	fork_tcb(), removing now-redundant error checks.
+	(fork_tcb): Change return type to void - it can't fail now.
+	* strace.c: Move extern declarations out of function bodies.
+	Change all callsites of alloctcb(), alloc_tcb() and
+	fork_tcb(), removing now-redundant error checks.
+	(expand_tcbtab): Change return type to void - it can't fail now.
+	On failure to expand, print a message, clean up, and exit.
+	(alloc_tcb): On failure to expand, print a message, clean up, and exit.
+	* util.c (setbpt): Remove extern declaration from function body.
+
+2009-01-14  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* linux/bfin/syscallent.h: sys_futex has 6 parameters, not 5.
+
+2009-01-13  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Fixes for ptrace() argument parsing.
+	* process.c: Add parsing of PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG,
+	PTRACE_GETSIGINFO, PTRACE_SETSIGINFO.
+	* defs.h: Declare several "extern const struct xlat" arrays here.
+	* desc.c: Remove open_mode_flags[] and open_access_modes[]
+	extern declarations.
+	* net.c: Remove open_mode_flags[] extern declaration.
+	* sock.c: Remove addrfams[] extern declaration.
+	* util.c: Remove struct_user_offsets[] extern declaration.
+	* signal.c: Remove open_mode_flags[] extern declaration.
+
+2009-01-06  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Output format fixes, improving the situation after recent
+	change which added beeter handling of processes suddenly
+	disappearing. Now we often do not finish last line
+	before exiting in those cases.
+	The only change affecting something other than output
+	is change in umovestr where we were calling
+	abort() on ptrace error.
+
+	* strace.c (trace): If trace_syscall() failed with ESRCH,
+	finish current output line with " <unfinished ...>".
+	(mp_ioctl): While we are at it, fix gross style mismatch
+	in this function definition. No code chages.
+	* syscall.c (trace_syscall): If decode fails on syscall exit,
+	finish current output line with "= ? <unavailable>".
+	* util.c (umoven): Do not complain if error is ESRCH.
+	(umovestr): Do not complain and do not abort() if error is ESRCH.
+	* defs.h: Remove unused tcp parameter from printtrailer().
+	* process.c: Adjust printtrailer() calls accordingly.
+	* strace.c: Adjust printtrailer() calls accordingly.
+	* syscall.c: Adjust printtrailer() calls accordingly.
+
+2009-01-06  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* desc.c (printflock): Fix display of fcntl(F_SETLK) on
+	non-native 32-bit architecture.
+	Fixes RH#471169 "format fcntl64() system calls for
+	32 bit application incorrect".
+	* desc.c: const'ify two static struct xlat vector[]'s,
+	convert all remaining old style C parameter declarations
+	in this file.
+
+2008-11-13  Kirill A. Shutemov  <kirill@shutemov.name>
+
+	* linux/arm/syscallent.h: Update syscalls.
+	Based on patch by Enrico Scholz.
+
+	* linux/arm/syscallent.h: Fix build on ARM EABI which does not
+	provide syscalls socketcall and ipc.
+
+2009-01-01  Andreas Schwab  <schwab@suse.de>
+
+	* net.c (sys_accept): Properly decode third argument as pointer to
+	int.
+
+2008-12-30  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Experimental support for -D option.
+	Unlike normal case, with -D *grandparent* process exec's,
+	becoming a traced process. Child exits (this prevents traced process
+	from having children it doesn't expect to have), and grandchild
+	attaches to grandparent similarly to strace -p PID.
+	This allows for more transparent interaction in cases
+	when process and its parent are communicating via signals,
+	wait() etc. Without -D, strace process gets lodged in between,
+	disrupting parent<->child link.
+	* strace.c: Add global flag variable daemonized_tracer for -D option.
+	(startup_attach): If -D, fork and block parent in pause().
+	In this case we are already a child, we in fact created a grandchild.
+	After attaching to grandparent, grandchild SIGKILLs parent.
+	(startup_child): If -D, parent blocks in wait(), then
+	execs the program to strace. Normally (w/o -D), it is child
+	who execs the program.
+	(main): Detect -D option, call startup_attach() if it is given.
+
+2008-12-30  Kirill A. Shutemov  <kirill@shutemov.name>
+
+	Fix some warnings on ARM build.
+	* defs.h: include <sys/ptrace.h> on arm too.
+	* syscall.c: EABI arm does not need decode_subcall(),
+	ifdef it out.
+
+2008-12-29  Nick Black  <dankamongmen@acm.org>
+
+	* linux/syscallent.h: Mark sendfile(2) as network syscall.
+	* linux/*/syscallent.h: Same, for all architectures.
+
+2008-12-17  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	Make strace detect when traced process suddenly disappeared
+	(prime example is randomly arriving SIGKILL).
+	* defs.h (do_ptrace, ptrace_restart): Declare new functions
+	* process.c: Use ptrace_restart instead of bare ptrace.
+	This catches and records ESRCH errors.
+	Print "<unavailable>" if syscall decode or result can't be
+	determined because of an earlier error in ptrace()
+	* syscall.c (trace_syscall): Stop indiscriminately bailing out
+	on errors, print "syscall(????" or even "????(????" but continue.
+	* util.c (do_ptrace, ptrace_restart): Define new functions.
+	(upeek): use do_ptrace in order to catch and record ESRCH.
+	Do not print error message in this case.
+	Fixes RH#472053.
+
+2008-12-17  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* signal.c (sys_sigaction, sys_rt_sigaction): Fix typo
+	in (sa_handler == SIG_IGN) comparison, it was using SIG_DFL
+	instead.
+
+2008-12-16  Denys Vlasenko  <dvlasenk@redhat.com>
+
+	* defs.h: Modify declaration of upeek to take struct tcb *
+	parameter instead of pid_t.
+	* process.c: Change all upeek calls accordingly.
+	* signal.c: Likewise.
+	* strace.c: Likewise.
+	* syscall.c: Likewise.
+	* util.c: Likewise.
+
+2008-11-11  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* sock.c [LINUX] (sock_ioctl): Parse more SIOCS* ioctls.
+
+2008-12-09  Roland McGrath  <roland@redhat.com>
+
+	* strace.1 (DIAGNOSTICS): New section, describe exit behavior.
+
+2008-11-09  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* process.c (prctl_options): Update constants from linux 2.6.27.
+	* system.c (capabilities): Add more capability values.
+
+	* util.c (string_quote): Fix support for NUL-terminated string.
+	Add comments.
+	(printpathn): Fix the case when "..." was appended to the output
+	but no truncation was actually made.  Add comments.
+	(printstr): Fix memory allocation.  Fix two cases when "..." was
+	appended to the output but no truncation was actually made.
+	Add comments.
+	Fixes RH#470529.
+
+2008-10-23  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Implement parsers for new linux syscalls.
+	* desc.c (do_dup2, [LINUX] sys_dup3): New functions.
+	(sys_dup2): Use do_dup2.
+	[LINUX] (sys_epoll_create1): New function.
+	[LINUX] (do_eventfd, sys_eventfd2): New functions.
+	[LINUX] (sys_eventfd): Use do_eventfd.
+	* net.c (do_pipe, [LINUX] sys_pipe2): New functions.
+	(sys_pipe): Use do_pipe.
+	* signal.c [LINUX] (do_signalfd, sys_signalfd4): New functions.
+	[LINUX] (sys_signalfd): Use do_signalfd.
+	* linux/syscall.h: Declare new sys_* functions.
+	* linux/syscallent.h: Hook up signalfd4, eventfd2, epoll_create1,
+	dup3, pipe2, inotify_init1.
+	* linux/x86_64/syscallent.h: Hook up paccept, signalfd4, eventfd2,
+	epoll_create1, dup3, pipe2, inotify_init1.
+
+2008-10-23  Mike Frysinger  <vapier@gentoo.org>
+
+	Port strace to the Blackfin architecture.
+	* configure.ac: Add bfin to supported architectures.
+	* process.c: Skip u_fpvalid/u_fpstate for Blackfin architecture.
+	(change_syscall): Support Blackfin architecture.
+	* syscall.c: Declare r0 for Blackfin architecture.
+	(get_scno): Decode Blackfin syscall number.
+	(syscall_fixup): Extract Blackfin return value.
+	(get_error): Decode Blackfin return value.
+	(force_result): Poke Blackfin return value.
+	(syscall_enter): Extract Blackfin syscall arguments.
+	* defs.h: Define TCB_WAITEXECVE for Blackfin architecture.
+	* linux/syscall.h (sys_sram_alloc): Declare for Blackfin
+	architecture.
+	* system.c (sys_sram_alloc): Decode Blackfin sram_alloc() syscall.
+	* util.c (getpc): Handle PC on Blackfin architecture.
+	(printcall): Likewise.
+	* linux/bfin/ioctlent.h, linux/bfin/syscallent.h: New Blackfin
+	headers.
+	* Makefile.am (EXTRA_DIST): Add linux/bfin/ioctlent.h and
+	linux/bfin/syscallent.h.
+
+2008-09-18  Mike Frysinger  <vapier@gentoo.org>
+
+	* configure.ac: Accept uclinux hosts as linux.
+
+2008-10-22  Dmitry V. Levin <ldv@altlinux.org>
+
+	Handle socket type flags introduced in linux 2.6.27.
+	* net.c (socktypes): Add SOCK_DCCP.
+	(sock_type_flags): New xlat structure.
+	(tprint_sock_type): New function.
+	(sys_socket, sys_socketpair): Use it to parse socket type and
+	socket type flags.
+
+2008-09-29  Dmitry V. Levin <ldv@altlinux.org>
+
+	* strace.c (startup_child): Save child pid for future use.
+	(main): Exit/kill ourself with straced child's exitcode/signal.
+	(trace): If signalled process pid matches the saved child pid,
+	save the signal number.  If terminated process pid matches the
+	saved child pid, save its exit status.
+	Patch from Denys Vlasenko <dvlasenk@redhat.com>
+	Fixes RH#105371.
+
+2008-09-12  Tomas Pospisek  <tpo@sourcepole.ch>
+	    Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* strace.1 (DESCRIPTION): New description of unfinished system calls
+	and system calls restarting.
+
+2008-09-03  Dmitry V. Levin <ldv@altlinux.org>
+
+	* desc.c (sys_fcntl): Do not initialize auxstr for failed syscall.
+	* process.c (sys_fork, sys_rfork) [USE_PROCFS]: Likewise.
+	* signal.c (sys_signal): Likewise.
+	* stream.c (internal_stream_ioctl): Likewise.
+	* time.c (sys_adjtimex): Likewise.
+	* syscall.c (trace_syscall): If RVAL_STR is set, then
+	print auxstr for failed syscall as well.
+
+	* syscall.c (is_restart_error): New function.
+	* defs.h (is_restart_error): Declare it.
+
+	* linux/dummy.h (sys_nanosleep): Uncouple from sys_adjtime().
+	* time.c (sys_nanosleep): New function, based on is_restart_error().
+
+	* process.c (sys_prctl): Decode PR_SET_PDEATHSIG, PR_GET_PDEATHSIG,
+	PR_SET_DUMPABLE, PR_GET_DUMPABLE, PR_SET_KEEPCAPS, PR_GET_KEEPCAPS.
+	Fix PR_GET_UNALIGN decoder.
+	(prctl_options): Add more constants.
+
+	* linux/syscallent.h: Use sys_prctl() decoder for "prctl" syscall.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/arm/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+
+2008-09-02  Dmitry V. Levin <ldv@altlinux.org>
+
+	* linux/x86_64/syscallent.h: Fix syscall numbers for "tee" and
+	"sync_file_range".
+	From Fernando Luis Vazquez Cao <fernando@oss.ntt.co.jp>
+
+2008-08-28  Roland McGrath  <roland@redhat.com>
+
+	* strace.1 (BUGS): New section, mention SIGTRAP interference.
+
+	* strace.spec (%ifarch %{strace64_arches}): Use cp -p instead of ln
+	for %{rhel} < 6.
+
+	* configure.ac, NEWS: Version 4.5.18.
+	* strace.spec: 4.5.18-1.
+
+2008-08-24  Roland McGrath  <roland@redhat.com>
+
+	* linux/syscall.h (SYS_socket_subcall et al, SYS_ipc_subcall et al):
+	Don't define these if [__ARM_EABI__].
+	Reported by Johannes Stezenbach <js@sig21.net>.
+
+	* syscall.c (trace_syscall): Conditionalize on [SYS_socket_subcall]
+	and [SYS_ipc_subcall] individually.
+
+	* linux/powerpc/syscallent.h: Handle subpage_prot.
+	* mem.c [LINUX && POWERPC] (sys_subpage_prot): New function.
+	* linux/syscall.h [POWERPC]: Declare it.
+	From Simon Murray <simon@transitive.com>.
+
+	* mem.c (mmap_prot): Handle PROT_SAO.
+	From Simon Murray <simon@transitive.com>.
+
+	* mem.c (madvise_flags): Typo fixes.  Rename to madvise_cmds.
+	(sys_madvise): Use printxval, not printflags.
+	Reported by Rajeev V. Pillai <rajeevvp@gmail.com>.
+
+2008-08-19  Roland McGrath  <roland@redhat.com>
+
+	* signal.c (sys_sigaction, sys_rt_sigaction): Don't omit the rest of
+	the struct after sa_handler is a known constant.  Some sa_flags bits
+	have meaning even for SIG_IGN/SIG_DFL.
+
+2008-08-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* util.c (CLONE_VM): Define if not defined already.
+	(setbpt): Clear CLONE_VM in the case we already clear CLONE_VFORK for
+	SYS_clone and SYS_clone2.
+	Reported by Michal Nowak.
+	Fixes RH#455078.
+
+2008-08-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	Fix compiler warnings.
+	* signal.c (sys_signal): Cast to SIG_* to the matching type LONG.
+	* strace.c (trace): Variables PSR and PC are now signed.
+	* syscall.c (syscall_enter): Variable RBS_END is now signed long.
+	Remove/add the RBS_END casts appropriately.
+	* util.c [IA64] (arg_setup): Variable BSP is now signed long.
+	Remove/add the BSP casts appropriately.
+	<ia32>: Initialize *STATE.
+
+2008-07-31  Roland McGrath  <roland@redhat.com>
+
+	* Makefile.am (EXTRA_DIST): Add new linux/arm/ files.
+
+	* file.c [LINUX] (struct kernel_dirent): Define it locally,
+	do not use <linux/dirent.h>.
+	Fixes RH#457291.
+
+	* configure.ac: Add AC_HEADER_STDBOOL.
+	* defs.h [HAVE_STDBOOL_H]: #include <stdbool.h>.
+	Fixes Debian#492774.
+
+2008-07-24  Dmitry V. Levin <ldv@altlinux.org>
+
+	* strace.c (main): Fix -F option backwards compatibility.
+
+2008-07-22  Roland McGrath  <roland@redhat.com>
+
+	* Makefile.am (EXTRA_DIST): Add new debian/ files.
+
+2008-07-21  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: Version 4.5.17.
+	* strace.spec: 4.5.17-1.
+
+	* defs.h [LINUXSPARC]: Don't #include <linux/a.out.h>.
+
+2008-07-19  Frederik Schüler <fs@debian.org>
+
+	* debian/control: Add strace64 package.
+	* debian/rules: Use debhelper flag --same-arch instead of --arch in
+	order to build strace64 only on the specified architectures.
+	* debian/strace64.install: New file, list for dh_install.
+	* debian/strace64.manpages: New file, list for dh_install.
+	* debian/changelog: Add prereleases entries.
+	Fixes Debian#491167, Debian#491188.
+
+2008-07-18  Andreas Schwab  <schwab@suse.de>
+
+	* linux/ia64/syscallent.h: Decode mincore syscall.
+
+	* linux/powerpc/syscallent.h: Fix argument count for request_key.
+
+	* term.c (term_ioctl): Decode indirect parameter as int, not long.
+
+2008-07-17  Roland McGrath  <roland@redhat.com>
+
+	* NEWS, strace.spec: Updates in preparation for release.
+
+	* process.c (printwaitn): When current personality's wordsize is
+	smaller than native, sign-extend the PID argument from 32 bits.
+
+	* process.c (futexops): Update table.
+	(sys_futex): Handle FUTEX_WAIT_BITSET correctly.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#448628.
+
+	* linux/syscallent.h: Fix "futex" argument count.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/arm/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#448629.
+
+	* signal.c (sigact_flags): Prefer SA_NODEFER to SA_NOMASK,
+	SA_RESETHAND to SA_ONESHOT.
+	Fixes RH#455821.
+
+2008-07-09  Frederik Schüler <fs@debian.org>
+
+	* debian/rules: Remove the broken udeb creation routines, and redo the
+	complete install procedure using debhelper.
+	* debian/strace.docs: New file, list for dh_installdocs.
+	* debian/strace.examples: New file, list for dh_installexamples.
+	* debian/strace.install: New file, list for dh_install.
+	* debian/strace-udeb.install: New file, list for dh_install.
+	* debian/strace.manpages : New file, list for dh_installmanpages.
+	* debian/copyright: Update.
+	* debian/control: Fix libc6 build dependency for alpha and ia64.
+	(strace-udeb: XC-Package-Type): Add header.
+	* debian/changelog: Cosmetic changes.
+
+2008-07-03  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	Trace vfork under -f on all the platforms.
+	* strace.1 <-f>: Describe Linux catches new children immediately.
+	<-F>: Make the option obsolete.  Move the SunOS VFORK comment to the
+	`-f' option description.
+	* defs.h (followvfork): Declaration removed.
+	* strace.c (followvfork): Variable removed.
+	(main) <-F>: Merge with the `-f' option.
+	(trace): Make !FOLLOWVFORK unconditional.
+	* process.c (internal_fork): Make !FOLLOWVFORK unconditional.
+
+2008-07-01  Frederik Schüler <fs@debian.org>
+
+	* debian/changelog: List all bugs closed since the last release.
+	* debian/control: Remove Wichert Akkerman from uploaders list.
+	* debian/control: Bump standards version to 3.8.0.
+	* debian/control: Add Homepage field.
+	* debian/rules: Fix dpkg-gencontrol call.
+	* debian/compat: New file, set to compatibility level 5.
+	* debian/rules: Call dh_clean on clean target.
+	* debian/rules: Add dh_md5sums call.
+	Fixes Debian#439428.
+
+2008-06-30  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	Fix ia64 `-f' on clone2 formerly crashing the child.
+	* util.c [IA64] (restore_arg0, restore_arg1): Define as empty.
+	Fixes RH#453438.
+
+2008-06-27  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* util.c (CLONE_VFORK): Define if not defined already.
+	(setbpt): Clear CLONE_VFORK for SYS_clone and SYS_clone2.
+	Reported by Vitaly Mayatskikh.
+	Fixes RH#455078.
+
+2008-06-29  Dmitry V. Levin <ldv@altlinux.org>
+
+	* linux/x86_64/syscallent.h: Remove duplicate syscall entries
+	for #283 and #284.
+
+2008-06-27  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* linux/syscallent.h: Remove a duplicite syscall stub #326.
+
+2008-05-27  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c [LINUX] (is_negated_errno): New function.
+	(get_error) [LINUX]: Use it for all such cases.
+	Fixes RH#447587.
+
+2008-05-19  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: Update entries for timerfd_* and fallocate.
+
+	* file.c (sys_fallocate): New function.
+	* linux/syscall.h: Declare it.
+	* linux/syscallent.h: Update entry.
+	From Kyle McMartin <kyle@mcmartin.ca>.
+
+	* time.c (sys_timerfd_create): New function.
+	(sys_timerfd_settime, sys_timerfd_gettime): New functions.
+	* linux/syscall.h: Declare them.
+	* linux/syscallent.h: Update entries for those syscalls.
+	From Kyle McMartin <kyle@mcmartin.ca>.
+
+	* debian/rules (binary-arch): Fix chmod/chown typo.
+	Fixes Debian#459255.
+
+	* debian/rules (binary-arch): Install strace-graph in examples/
+	directory under package doc.
+	Fixes Debian#469068.
+
+	* signal.c (sys_kill): When current personality's wordsize is smaller
+	than native, sign-extend the PID argument from 32 bits.
+	Fixes RH#430585.
+
+	* configure.ac: Add check for struct sigcontext_struct in <signal.h>.
+	* signal.c [! HAVE_ASM_SIGCONTEXT_H] [I386] (struct sigcontext_struct):
+	Conditionalize definition on !HAVE_STRUCT_SIGCONTEXT_STRUCT.
+	Fixes Debian#456879.
+
+	* util.c [LINUX] (setbpt): Use correct SYS_clone number for current
+	personality.
+	Fixes RH#447475.
+
+2008-05-08  David S. Miller  <davem@davemloft.net>
+
+	* syscall.c (socket_map, sparc_socket_decode): Delete.
+	(trace_syscall): Use common socketcall and ipc subcall
+	support on sparc.
+	* linux/sparc/syscall.h (sys_semtimedop): Declare.
+	(SYS_socket_subcall, SYS_sub_socket, SYS_sub_bind,
+	SYS_sub_connect, SYS_sub_listen, SYS_sub_accept,
+	SYS_sub_getsockname, SYS_sub_getpeername,
+	SYS_sub_socketpair, SYS_sub_send, SYS_sub_recv,
+	SYS_sub_sendto, SYS_sub_recvfrom, SYS_sub_shutdown,
+	SYS_sub_setsockopt, SYS_sub_getsockopt, SYS_sub_sendmsg,
+	SYS_sub_recvmsg, SYS_socket_nsubcalls, SYS_ipc_subcall,
+	SYS_sub_semop, SYS_sub_semget, SYS_sub_semctl,
+	SYS_sub_semtimedop, SYS_sub_msgsnd, SYS_sub_msgrcv,
+	SYS_sub_msgget, SYS_sub_msgctl, SYS_sub_shmat,
+	SYS_sub_shmdt, SYS_sub_shmget, SYS_sub_shmctl,
+	SYS_ipc_nsubcalls): Define
+	* linux/sparc/syscallent.h: Add socketcall and ipc entries.
+
+2008-01-25  Bruna Moreira  <bruna.moreira@indt.org>
+
+	* defs.h [ARM]: Define SUPPORTED_PERSONALITIES to 2.
+	* syscall.c (get_scno) [ARM]: Add support for architecture specific
+	syscalls.
+	* linux/arm/syscallent.h: Update network syscalls list.
+	* linux/arm/syscallent1.h: New file. Add new architecture specific
+	syscalls.
+	* linux/arm/errnoent1.h: New file.
+	* linux/arm/ioctlent1.h: New file.
+	* linux/arm/signalent1.h: New file.
+	Fixes Debian#441000.
+
+2008-01-07  Paul Mundt  <lethal@linux-sh.org>
+
+	* linux/sh64/syscallent.h: Update numerous calls, fix others.
+
+2007-08-26  Daniel Jacobowitz  <dan@codesourcery.com>
+
+	* defs.h [MIPS]: Include <sgidefs.h>.
+	(MAX_QUALS): Update for MIPS.
+	(LINUX_MIPSO32, LINUX_MIPSN32, LINUX_MIPSN64, LINUX_MIPS64): Define.
+	(struct tcb): Add ext_arg for MIPS N32.
+	(TCB_WAITEXECVE): Define for MIPS.
+	(ALIGN64): Use LINUX_MIPSO32.
+	* file.c (sys_lseek): Use ext_arg for MIPS N32.
+	(sys_readahead, sys_fadvise64_64): Likewise.
+	* io.c (sys_pread64, sys_pwrite64): Likewise.
+	* mem.c (print_mmap): Take OFFSET argument.
+	(sys_old_mmap): Update call to print_mmap.
+	(sys_mmap): Use ext_arg for MIPS N32.
+	* process.c (struct_user_offsets): Add MIPS registers.
+	* signal.c (sys_sigreturn): Handle MIPS N32 and MIPS N64.  Correct
+	MIPS O32 call to sprintsigmask.
+	* syscall.c (internal_syscall): Handle MIPS N32.  Check for
+	TCB_WAITEXECVE on MIPS.
+	(force_result): Add a comment about MIPS N32.
+	(syscall_enter): Handle MIPS N32 and MIPS N64.
+	* linux/syscall.h (sys_pread64, sys_pwrite64): Declare.
+	* linux/mips/syscallent.h: Include "dummy.h".  Handle alternate
+	MIPS ABIs.
+
+2008-04-19  Dmitry V. Levin <ldv@altlinux.org>
+
+	* file.c [_LFS64_LARGEFILE] (sys_getdents64): Do the same
+	d_reclen check as in sys_getdents: warn if d_reclen is 0 rather
+	than looping forever.
+	[FREEBSD] (sys_getdirentries): Likewise.
+	Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+	* file.c [LINUXSPARC] (printstatsol): Fix sprinttime()
+	invocation.  The sprinttime() function takes a time_t argument,
+	but timestruct_t argument was given.
+	Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+	* file.c (sprinttime): Check localtime() return value, to avoid
+	potential NULL dereference due to invalid time structures.
+	Signed-off-by: Harald van Dijk <truedfx@gentoo.org>
+	Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+	* linux/errnoent.h: Update errno list based on latest
+	linux/errno.h and asm-generic/errno*.h files.
+	Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+	* signalent.sh: Fix sort(1) old-style options.
+	* syscallent.sh: Likewise.
+	Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+	* count.c (call_summary_pers): Check calloc() return value.
+	Signed-off-by: "Yang Zhiguo" <yzgcsu@cn.fujitsu.com>
+
+2008-03-26  Roland McGrath  <roland@redhat.com>
+
+	* strace.spec (strace64_arches): Add sparc64.
+
+2007-11-20  Roland McGrath  <roland@redhat.com>
+
+	* CREDITS, ChangeLog: Converted contents to UTF8.
+
+2007-11-19  Roland McGrath  <roland@redhat.com>
+
+	* strace.spec: Add BuildRequires on libaio-devel, libacl-devel.
+
+2007-11-19  Andreas Schwab  <schwab@suse.de>
+
+	* process.c (sys_ptrace) [IA64]: For PTRACE_PEEKDATA,
+	PTRACE_PEEKTEXT and PTRACE_PEEKUSER the data is returned directly.
+
+	* linux/syscallent.h: Fix argument count for getdents64.
+	* linux/arm/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+
+	* linux/ia64/syscallent.h: Use sys_getdents64.
+	* linux/sh/syscallent.h: Likewise.
+
+2007-11-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* strace.c [LINUX] (droptcb): Recurse on TCP->parent if it is a
+	TCB_EXITING zombie group leader.
+	* test/childthread.c: New file.
+	* test/.cvsignore, test/Makefile: Add it.
+	Code advisory: Roland McGrath
+	Fixes RH#354261.
+
+2007-11-03  Roland McGrath  <roland@redhat.com>
+
+	* process.c (prctl_options): Add numerous constants.
+	From Sami Farin <safari@u.safari.iki.fi>.
+	Fixes RH#364401.
+
+2007-11-03  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* strace.c (main): Move the STARTUP_CHILD call before setting up the
+	signal handlers.  New comment about the valid internal states.
+
+2007-11-02  Thiemo Seufer  <ths@networkno.de>
+
+	* signal.c (m_siginfo_t): Add for MIPS.
+	(sys_sigreturn): struct sigcontext on MIPS has no sigset_t member,
+	acquire the signal mask with the same trick as on Sparc.
+	Fixes Debian#448802.
+
+2007-11-01  Roland McGrath  <roland@redhat.com>
+
+	* util.c (string_quote): Return nonzero if the string was unterminated.
+	(printstr): Use that value instead of just our own test.
+	(printpathn): Likewise.
+	Fixes RH#358241.
+
+	* linux/mips/syscallent.h: Fix argument count for fadvise64_64.
+	From Paul Mundt <lethal@linux-sh.org>.
+
+	* linux/mips/syscallent.h: Fix argument count for lookup_dcookie.
+	From Paul Mundt <lethal@linux-sh.org>.
+
+	* linux/sh64/syscallent.h: Fix SYS_socket_subcall check.
+	From Paul Mundt <lethal@linux-sh.org>.
+
+	* linux/sh/syscallent.h: Update numerous calls.
+	From Paul Mundt <lethal@linux-sh.org>.
+
+2007-09-22  Dmitry V. Levin <ldv@altlinux.org>
+
+	* desc.c (sys_pselect6): Decode signal mask when entering syscall.
+	Relax signal mask size check.
+
+	* time.c (print_timespec, sprint_timespec): New functions.
+	* defs.h (print_timespec, sprint_timespec): Declare them.
+	* desc.c (sys_io_getevents): Use print_timespec.
+	* stream.c (sys_ppoll): Likewise.
+	(decode_poll): Use sprint_timespec.
+
+2007-09-22  Alan Curry <pacman@world.std.com>
+	    Dmitry V. Levin <ldv@altlinux.org>
+
+	* stream.c (decode_poll): Rearrange so that arguments are decoded
+	and printed on syscall entry, except for revents and the output
+	timespec which are now printed in the auxstr.
+	(sys_poll): Print the input timeout argument on syscall entry.
+	[LINUX] (sys_ppoll): Likewise.
+	Fixes Debian#369651.
+
+2007-09-22  Dmitry V. Levin <ldv@altlinux.org>
+
+	* desc.c (sprintflags): Remove static qualifier, add "prefix"
+	argument, move function to ...
+	* util.c (sprintflags): ... here.
+	* defs.h (sprintflags): Declare it.
+
+2007-11-01  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (get_scno) [ARM]: Check TCB_WAITEXECVE.
+	Reported by Bernhard Fischer <rep.dot.nop@gmail.com>.
+
+	* net.c (sockpacketoptions): Make PACKET_ADD_MEMBERSHIP and
+	PACKET_DROP_MEMBERSHIP conditional.
+	From Bernhard Fischer <rep.dot.nop@gmail.com>.
+
+	* configure.ac: Match sh64* for SH64, sh* for SH.
+	Reported by Bernhard Fischer <rep.dot.nop@gmail.com>.
+
+2007-10-01  Dmitry V. Levin <ldv@altlinux.org>
+
+	* net.c (printsock): Output AF_UNIX socket address using
+	printpathn() to avoid unprintable characters in output.
+	Suggested by Neil Campbell.
+
+2007-10-01  Dmitry V. Levin <ldv@altlinux.org>
+
+	* util.c (string_quote): Move quoting code from ...
+	(printstr) ... here.  Use string_quote.
+	(printpathn): Update for new string_quote interface.
+	(printpath): Use printpathn.
+
+2007-09-25  Dmitry V. Levin <ldv@altlinux.org>
+
+	* strace.c (main): Use calloc for tcbtab allocation.
+	Check calloc return value.
+	Reported by Bai Weidong.
+
+2007-09-11  Roland McGrath  <roland@redhat.com>
+
+	* linux/sparc/syscall.h: Add missing decls.
+	* linux/sparc/syscallent.h: Correct entries for setgroups32,
+	getgroups32, sys_getdents64.
+	From Jakub Bogusz <qboosh@pld-linux.org>.
+
+	* linux/alpha/syscallent.h: Correct entries for madvise, setresgid,
+	getresgid, pivot_root, mincore, pciconfig_iobase, getdents64.
+	From Jakub Bogusz <qboosh@pld-linux.org>.
+
+	* linux/syscallent.h: Fix getegid32 entry.
+	From Jakub Bogusz <qboosh@pld-linux.org>.
+
+	* defs.h [LINUXSPARC]: Use asm/psrcompat.h for [SPARC64], not asm/psr.h.
+	From Jakub Bogusz <qboosh@pld-linux.org>.
+
+	* mem.c (sys_getpagesize): Define for [SPARC || SPARC64] too.
+	From Jakub Bogusz <qboosh@pld-linux.org>.
+
+2007-08-20  Dmitry V. Levin <ldv@altlinux.org>
+
+	* syscall.c (qual_syscall, qualify): Fix nsyscalls and MAX_QUALS misuse.
+	Reported by Xiaoning Ding.
+
+2007-08-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
+	    Roland McGrath  <roland@redhat.com>
+
+	* file.c [!HAVE_STAT64 && LINUX && X86_64] (struct stat64): Define it.
+	[!HAVE_STAT64 && LINUX && X86_64] (HAVE_STAT64, STAT64_SIZE): Define.
+	[HAVE_STAT64] (printstat64) [STAT64_SIZE]: Add compile-time assertion.
+	Fixes RH#222275.
+
+	* file.c (printstat64): Test [HAVE_LONG_LONG] for st_size printing
+	and cast to widest type available.
+
+2007-08-03  Ulrich Drepper  <drepper@redhat.com>
+
+	* file.c (open_mode_flags): Add O_CLOEXEC.
+	* net.c (msg_flags): Add MSG_CMSG_CLOEXEC.
+	Fixes RH#365781.
+
+2007-08-03  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.16.
+	* debian/changelog, strace.spec: 4.5.16-1.
+
+	* debian/control (Build-Depends): Replace libc6-dev-s390x and
+	libc6-dev-sparc64 with gcc-multilib.
+	* debian/rules: Replace sparc-linux, s390-linux conditionals with
+	general "arch64_map" hair, handle x86_64 and powerpc64 too.
+	From Matthias Klose <doko@cs.tu-berlin.de>.
+	Fixes Debian#435303.
+
+2007-08-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* strace.c (detach): Moved the resume notification code to ...
+	(resume_from_tcp): ... a new function here.
+	(handle_group_exit): No longer detach also the thread group leader.
+	(trace): Fixed panic on exit of the TCB_GROUP_EXITING leader itself.
+	Fixes RH#247907.
+
+	* test/leaderkill.c (start): Renamed to ...
+	(start0): ... here.
+	(start1): New function.
+	(main): Created a new spare thread.
+
+2007-08-01  Roland McGrath  <roland@redhat.com>
+
+	* util.c (umoven): Don't perror for EIO.
+	(umovestr): Likewise.
+
+	* process.c (printargv): Handle boundary cases correctly.
+	Handle biarch fetching correctly.
+
+	* util.c (printstr): Don't print ... if the string matches the length
+	limit exactly.
+
+	* linux/sparc64/syscallent.h: Just #include the sparc file.
+	* linux/sparc64/syscallent1.h: Likewise.
+	* linux/sparc64/syscallent2.h: Likewise.
+
+	* linux/arm/syscallent.h: Add entry for getcpu.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+
+	* linux/arm/syscallent.h: Add entry for eventfd.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+
+	* linux/arm/syscallent.h: Add entry for timerfd.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+
+	* linux/arm/syscallent.h: Add entry for signalfd.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+
+	* linux/hppa/syscallent.h: Add entry for epoll_pwait.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+
+2007-07-23  Ulrich Drepper  <drepper@redhat.com>
+
+	* process.c (sys_getcpu): New function.
+	* linux/syscall.h: Declare sys_getcpu.
+	* linux/syscallent.h: Add entry for getcpu.
+
+	* desc.c (sys_eventfd): New function.
+	* linux/syscall.h: Declare sys_eventfd.
+	* linux/syscallent.h: Add entry for eventfd.
+	* linux/x86_64/syscallent.h: Likewise.
+
+	* time.c (printitv_bitness): Add missing braces to enclose
+	conditional code.
+	(TDF_TIMER_ABSTIME): Define if not already.
+	(timerfdflags): New variable.
+	(sys_timerfd): New function.
+	* linux/syscall.h: Declare sys_timerfd.
+	* linux/syscallent.h: Add timerfd entry.
+	* linux/x86_64/syscallent.h: Likewise.
+
+	* linux/syscall.h: Declare sys_signalfd.
+	* linux/syscallent.h: Add entry for signalfd.
+	* linux/x86_64/syscallent.h: Likewise.
+	* signal.c (sys_signalfd): New function.
+
+	* desc.c (sys_epoll_wait): Move body of function to ...
+	(epoll_wait_common): ...here.  New function.
+	(sys_epoll_pwait): New function.
+	* linux/syscall.h: Declare sys_epoll_pwait.
+	* linux/syscallent.h: Add entry for epoll_pwait.
+	* linux/x86_64/syscallent.h: Likewise.
+
+2007-07-23  Roland McGrath  <roland@redhat.com>
+
+	* time.c (printtv_bitness): SPECIAL only counts when tv_sec == 0.
+
+	* linux/arm/syscallent.h: Add move_pages.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+
+	* linux/syscallent.h: move_pages takes 6 args, not 5.
+	* linux/x86_64/syscallent.h: Likewise.
+
+2007-07-23  Ulrich Drepper  <drepper@redhat.com>
+
+	* defs.h: Add new parameter to printtv_bitness prototype.
+	(printttv): Pass zero for the new parameter.
+	(printtv_special): New macro.
+	* desc.c (decode_select): Pass zero for the new parameter of
+	printtv_bitness.
+	* file.c (utimensatflags): New macro.
+	(sys_osf_utimes): Pass zero for the new parameter of
+	printtv_bitness.
+	(sys_utimes): Likewise.
+	(sys_futimesat): Likewise.
+	(decode_utimes): Add new parameter.  Pass it to the
+	printtv_bitness calls.  Fix printing of time values.
+	(sys_utimensat): New function.
+	* time.c (UTIME_NOW, UTIME_OMIT): Define if not already
+	happened.
+	(printtv_bitness): Add new parameter.  Print special UTIME_*
+	values as strings if set.
+	(sys_osf_gettimeofday): Pass zero for the new parameter of
+	printtv_bitness.
+	(sys_osf_settimeofday): Likewise.
+	* linux/syscall.h: Declare sys_utimensat.
+	* linux/syscallent.h: Add utimensat entry.
+	* linux/x86_64/syscallent.h: Likewise.
+
+	* mem.c (move_pages_flags): New variable.
+	(sys_move_pages): New function.
+	* linux/syscall.h: Declare sys_move_pages.
+	* linux/syscallent.h: Add entry for sys_move_pages.
+	* linux/x86_64/syscallent.h: Likewise.
+
+	* mem.c (MPOL_MF_MOVE, MPOL_MF_MOVE_ALL): Define.
+	(mbindflags): Add MPOL_MF_MOVE and MPOL_MF_MOVE_ALL entries.
+
+2007-07-23  Roland McGrath  <roland@redhat.com>
+
+	* util.c (tv_add): Fix rounding comparison.
+	Reported by Bai Weidong <baiwd@cn.fujitsu.com>.
+
+2007-07-11  Roland McGrath  <roland@redhat.com>
+
+	* count.c (call_summary_pers): Use tv_float conversion for output of
+	cumulative time, in case it is negative from bogus -O value.
+	From Lai JiangShan <laijs@cn.fujitsu.com>.
+
+	* strace.c (handle_group_exit): Detach TCP before LEADER.
+	Don't use PTRACE_KILL on LEADER.
+
+	* util.c (printstr): Fix size calculation for outstr allocation.
+
+	* configure.ac (struct sigcontext.sc_hi2): Use #ifdef around
+	<asm/sigcontext.h> to match signal.c include conditions.
+
+2007-07-05  Roland McGrath  <roland@redhat.com>
+
+	* debian/rules: Use debian/$(package) instead of debian/tmp as temp dir.
+
+	* configure.ac: Use <stddef.h> before <linux/socket.h>.
+
+	* debian/changelog: Harmonize with debian version.
+	* debian/control (Uploaders): Fix surname spelling.
+	(Build-Depends): Make debhelper requirement (>= 5.0.0).
+	(Standards-Version): Update to 3.7.2.
+
+	* .cvsignore: Add some automake-created files.
+
+	* file.c (sys_utime): Use personality_wordsize to handle biarch.
+	Fixes RH#247185.
+
+	* signal.c (sys_sigreturn) [MIPS]: Pass 3rd arg to sprintsigmask.
+	From Zhang Le <zhilg@users.sourceforge.net>.
+
+	* strace.c (strace_fopen): [_LFS64_LARGEFILE]: Use fopen64.
+	Fixes Debian#385310.
+
+	* strace.c (main): Fix error message for unfound -u user.
+	From Srinivasa Ds <srinivasa@in.ibm.com>.
+	Fixes RH#247170.
+
+	* debian/control (Architecture): Add armel.
+
+	* linux/syscallent.h: Fix sys_delete_module arg count.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/arm/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/sparc64/syscallent2.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	* linux/dummy.h (sys_delete_module): Use sys_open.
+	From Johannes Stezenbach <js@linuxtv.org>.
+
+	* configure.ac: Check for struct sigcontext.sc_hi2.
+	* signal.c (sys_sigreturn) [MIPS]: Use sc_hi2 vs sc_sigset if found.
+
+	* process.c [LINUX] (futexops): Add many new values.
+	[LINUX] (futexwakeops, futexwakecmps): New tables.
+	[LINUX] (sys_futex): Use them.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#241467.
+
+2007-07-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* strace.c (detach): New prototype.  Extended the function comment.
+	[LINUX] (detach): Call droptcb() instead of the wrongly parametrized
+	detach() call.
+	(handle_group_exit): Call droptcb() instead of the wrongly parametrized
+	detach() call.	Always call detach() only once from the group leader.
+	Comment the leader killing known bug tested by `test/leaderkill.c'.
+	Code advisory: Roland McGrath
+	Fixes RH#240961.
+
+	* test/leaderkill.c: New file.
+	* test/.cvsignore, test/Makefile: Add it.
+
+2007-03-21  Andreas Schwab  <schwab@suse.de>
+
+	* file.c (sys_newfstatat): Don't use printstat64 on ppc64.
+
+2007-03-29  Vladimir Nadvornik <nadvornik@suse.cz>
+	    Dmitry V. Levin <ldv@altlinux.org>
+
+	Trace linux SG_IO ioctl arguments and results.
+	* scsi.c: New file.
+	* Makefile.am (strace_SOURCES): Add it.
+	* defs.h (scsi_ioctl): New function.
+	* ioctl.c (ioctl_decode): Use scsi_ioctl().
+
+2007-06-28  Dmitry V. Levin <ldv@altlinux.org>
+
+	* util.c (tv_mul): Multiply tv_usec properly.
+	Patch from Cai Fei <caifei@cn.fujitsu.com>.
+
+2007-06-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	Never interrupt when the attached traced process would be left stopped.
+	* strace.c (main): `-p' attaching moved to ...
+	(startup_attach): ... a new function, renamed a variable C to TCBI.
+	Block interrupting signals since the first tracee has been attached.
+	New comment about INTERRUPTED in the nonthreaded case.
+	[LINUX] (startup_attach): Check INTERRUPTED after each attached thread.
+	(main): Command spawning moved to ...
+	(startup_child): ... a new function, replaced RETURN with EXIT.
+	[LINUX] (detach): New variable CATCH_SIGSTOP, do not signal
+	new SIGSTOP for processes still in TCB_STARTUP.
+	(main): Move signals and BLOCKED_SET init before the tracees attaching,
+	[SUNOS4] (trace): Removed fixvfork () call as a dead code, SIGSTOP must
+	have been already caught before clearing TCB_STARTUP.
+	(trace): Removed the `!WIFSTOPPED(status)' dead code.
+	Clear TCB_STARTUP only in the case the received signal was SIGSTOP.
+	New comment when `TCB_BPTSET && TCB_STARTUP' combination can be set.
+	Code advisory: Roland McGrath
+	Fixes RH#240986.
+
+2007-05-24  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+	* strace.c [LINUX] (my_tgkill): New macro.
+	[LINUX] (detach): Use my_tgkill () instead of kill(2).
+	Fixes RH#240962.
+
+2007-03-30  Dmitry V. Levin <ldv@altlinux.org>
+
+	* mem.c (mmap_flags): Add MAP_32BIT.
+	Reported by Kirill A. Shutemov.
+
+2007-01-12  Dmitry V. Levin <ldv@altlinux.org>
+
+	* sock.c (sock_ioctl): Check umove() return code.
+	[LINUX]: Handle SIOCGIFTXQLEN and SIOCGIFMAP.
+
+2007-03-16  Roland McGrath  <roland@redhat.com>
+
+	* linux/s390/syscallent.h: Use sys_restart_syscall for 7.
+	* linux/s390x/syscallent.h: Likewise.
+
+2007-02-18  Roland McGrath  <roland@redhat.com>
+
+	* strace.spec (Summary): Remove trailing period.
+	(%files): Add %doc files.
+	(%changelog): Double %s in text.
+	(BuildRoot): Change to Fedora canonical.
+	(%install): Don't use %makeinstall macro.
+	(%build): Use %{?_smp_mflags}.
+
+2007-01-16  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.15.
+	* debian/changelog, strace.spec: 4.5.15-1.
+
+2007-01-16  Dmitry V. Levin <ldv@altlinux.org>
+
+	Update mount parser to match kernel behaviour.
+	* system.c [LINUX] (MS_VERBOSE): Rename to MS_SILENT.
+	[LINUX] (MS_UNBINDABLE, MS_PRIVATE, MS_SLAVE, MS_SHARED):
+	New macros.
+	[LINUX] (mount_flags): Add them.
+	[LINUX] (MS_MGC_MSK): New macro.
+	[LINUX] (sys_mount): Update parser to match kernel behaviour:
+	discard MS_MGC_VAL magic, do not decode type and/or data
+	strings when specified flags do not imply valid strings.
+
+2007-01-12  Dmitry V. Levin <ldv@altlinux.org>
+
+	* time.c [LINUX] (tprint_timex32, tprint_timex): Decode adjtimex
+	modes as flags.
+
+2007-01-11  Dmitry V. Levin <ldv@altlinux.org>
+
+	Update umount parser.
+	* system.c [LINUX] (MNT_FORCE, MNT_DETACH, MNT_EXPIRE): New macros.
+	[LINUX] (umount_flags): New xlat structure with MNT_* entries.
+	[LINUX] (sys_umount2): Use umount_flags.
+
+	Fix open(2) flags parser.
+	* defs.h (tprint_open_modes): New function.
+	* desc.c (sprint_open_modes): New function.
+	(sys_fcntl): Use tprint_open_modes() and sprint_open_modes().
+	* file.c (openmodes): Split xlat into open_access_modes and
+	open_mode_flags.
+	(tprint_open_modes): New function.
+	(decode_open): Use it.
+	* ipc.c (sys_mq_open, printmqattr): Likewise.
+	Fixes RH#222385.
+
+2007-01-11  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.15.
+	* debian/changelog, strace.spec: 4.5.15-1.
+
+	* debian/control (Uploaders): Add Frederik Schueler <fs@debian.org>.
+
+	* strace.spec (Release): Use %{?dist}.
+
+	* system.c [LINUX] (CTL_CPU): Define in case header is missing it.
+
+2006-12-27  Dmitry V. Levin <ldv@altlinux.org>
+
+	Add const qualifier to xlookup() return value.
+	* defs.h (xlookup): Add const qualifier to return value.
+	* desc.c (sprintflags): Likewise.
+	* process.c (printpriv): Update xlookup() use.
+	* signal.c (sprintsigmask): Add const qualifier to first argument and
+	return value.
+	* util.c (xlookup): Add const qualifier to return value.
+	(printxval): Update xlookup() use.
+
+2006-12-21  Dmitry V. Levin <ldv@altlinux.org>
+
+	Move counts code to separate file.
+	* count.c: New file.
+	* Makefile.am (strace_SOURCES): Add count.c.
+	* syscall.c (call_counts, countv, counts, shortest, time_cmp,
+	syscall_cmp, count_cmp, sortfun, overhead, set_sortby,
+	set_overhead, call_summary_pers, call_summary): Move to count.c
+	* count.c (count_syscall): New function.
+	* defs.h (count_syscall): Declare it.
+	* syscall.c (trace_syscall): Use it.
+
+2006-12-20  Dmitry V. Levin <ldv@altlinux.org>
+
+	* syscall.c (internal_syscall): Change conditions for internal_exit,
+	internal_fork, internal_clone, internal_exec and internal_wait
+	calls from switching on known scno values to switching on known
+	sysent[tcp->scno].sys_func values.
+	Fixes RH#179740.
+
+	Show system call summary for each personality.
+	* syscall.c (countv): New call_counts pointers array.
+	(counts): Convert to macro wrapper around countv.
+	(call_summary_pers): New function.
+	(call_summary): Use it for each personality.
+	Fixes RH#192193.
+
+2006-12-12  Dmitry V. Levin <ldv@altlinux.org>
+
+	Fix -ff -o behaviour.  Fix piping trace output.
+	* defs.h (newoutf): Remove.
+	(alloctcb): Rename to alloc_tcb.  Add alloctcb() macro wrapper
+	around alloc_tcb().
+	* process.c [!USE_PROCFS] (internal_clone, internal_fork):
+	Remove newoutf() call.
+	* strace.c (set_cloexec_flag, strace_fopen, strace_popen,
+	swap_uid): New functions.
+	(popen_pid): New variable.
+	(newoutf): Make static, use strace_fopen().
+	(main): Use strace_fopen() and strace_popen(), remove uids
+	swapping.  Do not open outfname when followfork > 1.
+	Reinitialize tcp->outf properly.
+	(alloctcb): Rename to alloc_tcb.  Use newoutf().
+	(trace): Check popen_pid.  Remove newoutf() call.
+	[USE_PROCFS] (proc_open, proc_poll_open): Use set_cloexec_flag().
+	Fixes RH#204950, RH#218435, Debian#353935.
+
+2006-12-10  Dmitry V. Levin <ldv@altlinux.org>
+
+	Add biarch support for "struct sigevent".
+	* time.c [LINUX && SUPPORTED_PERSONALITIES > 1] (printsigevent32):
+	New function.
+	[LINUX] (printsigevent): [SUPPORTED_PERSONALITIES > 1]
+	Handle 32-bit personality.
+
+	Add biarch support for "struct timex".
+	* time.c [LINUX && SUPPORTED_PERSONALITIES > 1] (tprint_timex32):
+	New function.
+	[LINUX] (tprint_timex): New function.
+	[LINUX] (sys_adjtimex): Use it.
+
+	Enhance adjtimex parser.
+	* time.c [LINUX] (adjtimex_modes, adjtimex_status,
+	adjtimex_state): New xlat structures.
+	[LINUX] (sys_adjtimex): Print the whole struct timex.
+	Decode modes, status and return code.
+
+	Add biarch support for "struct itimerval".
+	* time.c (printitv): Rename to printitv_bitness().
+	Add printitv() macro wrapper around printitv_bitness().
+	(printitv_bitness): Handle 32-bit personality.
+	[ALPHA] (sys_osf_getitimer, sys_osf_setitimer):
+	Use printitv_bitness().
+	(tprint_timeval, tprint_timeval32): New functions.
+	(printtv_bitness, printitv_bitness, sys_adjtimex): Use them.
+	(printitv32): Remove.
+
+	Add biarch support for "struct timeval".
+	* defs.h (bitness_t): New enum type.
+	(printtv_bitness, sprinttv): New function prototypes.
+	(printtv): Convert to macro wrapper around printtv_bitness().
+	(printtv32): Remove.
+	* desc.c (decode_select): Use printtv_bitness() and sprinttv().
+	(sys_oldselect, sys_osf_select, sys_select, sys_pselect6):
+	Update decode_select() use.
+	* file.c [ALPHA] (sys_osf_utimes): Use printtv_bitness().
+	* time.c (printtv_bitness, sprinttv): New functions.
+	(printtv, printtv32): Remove.
+	[ALPHA] (sys_osf_settimeofday, sys_osf_settimeofday):
+	Use printtv_bitness().
+	Fixes RH#171626, RH#173050.
+
+	Add biarch support for "struct iovec".
+	* defs.h (personality_wordsize): Add.
+	* io.c [HAVE_SYS_UIO_H] (tprint_iov): [LINUX &&
+	SUPPORTED_PERSONALITIES > 1] Handle 32-bit personality.
+	* util.c [HAVE_SYS_UIO_H] (dumpiov): [LINUX &&
+	SUPPORTED_PERSONALITIES > 1] Likewise.
+	Patch from Jakub Jelinek.
+	Fixes RH#218433.
+
+	* time.c (sys_timer_create): Check umove() return code.
+
+	Make several global variables static.
+	#ifdef definitions of rarely unused functions.
+	* defs.h (rflag, tflag, outfname): Remove.
+	* strace.c (iflag, interactive, pflag_seen, rflag, tflag,
+	outfname, username): Make static.
+	* desc.c (sys_getdtablesize): Define only for
+	ALPHA || FREEBSD || SUNOS4.
+	* file.c (sys_fchroot): Define only for SUNOS4 || SVR4.
+	(sys_mkfifo): Define only for FREEBSD.
+	* mem.c (sys_sbrk): Define only for FREEBSD || SUNOS4.
+	(sys_getpagesize): Define only for
+	ALPHA || FREEBSD || IA64 || SUNOS4 || SVR4.
+	* net.c (sys_so_socket): Define only for SVR4.
+	* process.c (sys_gethostid): Define only for
+	FREEBSD || SUNOS4 || SVR4.
+	(sys_gethostname): Define only for
+	ALPHA || FREEBSD || SUNOS4 || SVR4.
+	(sys_setpgrp): Define only for ALPHA || SUNOS4 || SVR4.
+	(sys_execv): Define only for SPARC || SPARC64 || SUNOS4.
+	* signal.c (sys_sigblock): Define only for FREEBSD || SUNOS4.
+	(sys_sighold, sys_sigwait): Define only for SVR4.
+	(sys_killpg): Define only for FREEBSD || SUNOS4.
+	* stream.c (sys_getmsg): Define only for
+	SPARC || SPARC64 || SUNOS4 || SVR4.
+	* syscall.c (sys_indir): Define only for SUNOS4.
+
+2006-11-27  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* system.c [LINUX]: Define CTL_PROC, since Linux 2.6.18+ headers
+	removed CTL_PROC enum.	Patch from Jakub Jelinek.
+	[LINUX] (sysctl_root): Add CTL_BUS, CTL_ABI and CTL_CPU.
+
+2006-11-20  Jakub Jelinek  <jakub@redhat.com>
+
+	* linux/ia64/syscallent.h: Add #if check to make sure that
+	SYS_socket_subcall adjustment isn't forgotten again.
+
+2006-10-16  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Implement comprehensive quotactl(2) parser for Linux.
+	* Makefile.am (strace_SOURCES): Add quota.c.
+	* quota.c: New file.
+	* resource.c: Remove old quotactl(2) parser.
+	Fixes RH#118696.
+
+2006-10-14  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* configure.ac (AC_CHECK_HEADERS): Add inttypes.h.
+	* file.c [_LFS64_LARGEFILE && (LINUX || SVR4)]:
+	Include <inttypes.h>.
+	(sys_getdents64): Use PRIu64/PRId64 to avoid gcc warnings on
+	64-bit platforms.
+
+	* strace.c (main): Check getcwd() return code.
+
+2006-10-13  Ulrich Drepper  <drepper@redhat.com>
+	    Bernhard Kaindl <bk@suse.de>
+	    Dmitry V. Levin  <ldv@altlinux.org>
+	    Michael Holzheu <holzheu@de.ibm.com>
+
+	Add hooks for new syscalls.  Add decoders for *at, inotify*,
+	pselect6, ppoll and unshare syscalls.
+
+	* defs.h: Declare print_sigset.
+	* desc.c (sys_pselect6): New function.
+	* file.c (decode_open, decode_access, decode_mkdir,
+	decode_readlink, decode_chmod, decode_utimes, decode_mknod):
+	New functions.
+	(sys_open, sys_access, sys_mkdir, sys_readlink, sys_chmod,
+	sys_utimes, sys_mknod): Use them.
+	[LINUX] (fstatatflags, unlinkatflags, inotify_modes): New
+	variables.
+	[LINUX] (print_dirfd, sys_openat, sys_faccessat,
+	sys_newfstatat, sys_mkdirat, sys_linkat, sys_unlinkat,
+	sys_symlinkat, sys_readlinkat, sys_renameat, sys_fchownat,
+	sys_fchmodat, sys_futimesat, sys_mknodat, sys_inotify_add_watch,
+	sys_inotify_rm_watch): New functions.
+	* process.c [LINUX] (sys_unshare): New function.
+	* signal.c (print_sigset): New function.
+	(sys_sigprocmask): Use it.
+	* stream.c (decode_poll): New function.
+	(sys_poll): Use it.
+	[LINUX] (sys_ppoll): New function.
+	* linux/syscall.h: Delcare new syscall handlers.
+	* linux/syscallent.h: Hook up new syscalls.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	Fixes RH#178633.
+
+2006-10-06  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* strace.c [!USE_PROCFS] (trace): Presence of PT_GETSIGINFO
+	macro does not mean that PT_CR_IPSR and PT_CR_IIP macros are
+	also defined, so check them along with PT_GETSIGINFO.
+	Fixes RH#209856.
+
+2006-09-01  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* file.c (print_xattr_val): Fix memory corruption bug reported
+	by James Antill.
+	Fixes RH#200621.
+
+2006-04-21  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* defs.h [LINUX && X86_64 && !__NR_exit_group]: Define
+	__NR_exit_group.
+
+2006-03-29  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Fix race conditions in tcb allocation.
+	* process.c (fork_tcb): Return error code as documented.  Do not
+	print "tcb table full" error message.
+	[USE_PROCFS] (internal_fork): Do not print "tcb table full"
+	error message.
+	[SYS_clone || SYS_clone2] (internal_clone, internal_fork): Call
+	fork_tcb() before alloctcb().  Do not print "tcb table full"
+	error message.
+	* strace.c (main): Do not print "tcb table full" error message.
+	(expand_tcbtab): Print error message in case of memory allocation
+	failure.
+	(alloctcb): Print error message when tcb table is full.
+	(trace): Expand tcb table if necessary prior to allocating
+	entry there.  Do not print "tcb table full" error message.
+	Fixes RH#180293.
+
+2006-08-22  Roland McGrath  <roland@redhat.com>
+
+	* ipc.c (sys_msgget, sys_semget, sys_shmget): Show key values in hex.
+	Fixes RH#198179.
+
+2006-08-21  Roland McGrath  <roland@redhat.com>
+
+	* linux/syscall.h (SYS_socket_subcall): Bump to 400.
+	* linux/syscallent.h: Update table.
+	* linux/arm/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	Fixes RH#201462.
+
+2006-04-25  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Fail when -c is given with -ff.
+	* strace.1: Note their incompatibility.
+	Fixes RH#187847.
+
+	* strace.c (main): Fail when nonoption args follow -p switches.
+	Fixes Debian#361302.
+
+	* Makefile.am (EXTRA_DIST): Add xlate.el.
+
+	* linux/mips/Makefile.in: File removed, unused cruft.
+	* linux/sparc/Makefile.in: Likewise.
+
+	* strace.spec (Source0): Use http://dl.sourceforge.net URL.
+
+	* ipc.c (sys_semtimedop): Fixed inverted indirect_ipccall test.
+	* linux/hppa/syscallent.h: Fixed semtimedop entry.
+	From Mike Stroyan <mike.stroyan@hp.com>.
+	Fixes Debian#340239.
+
+2006-03-30  Daniel Jacobowitz  <dan@codesourcery.com>
+
+	* linux/arm/syscallent.h: Correct the name of exit.  Remove
+	M68K conditionals and sys_security.  Correct syscalls 243-282.
+	Fixes Debian#360154.
+
+	* process.c (change_syscall): Add ARM support.
+	* syscall.c (get_scno): Handle ARM EABI.
+	Fixes Debian#360152.
+
+2006-01-16  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.14.
+	* debian/changelog, strace.spec: 4.5.14-1.
+
+2006-01-13  Roland McGrath  <roland@redhat.com>
+
+	* debian/control (Build-Depends): Add debhelper.
+
+2006-01-12  Roland McGrath  <roland@redhat.com>
+
+	* signal.c [LINUX] (sys_restart_syscall): New function.
+	* linux/syscall.h: Declare sys_restart_syscall.
+	* linux/sparc/syscall.h: Likewise.
+	* linux/syscallent.h: Call 0 is restart_syscall.
+	* linux/arm/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/m68k/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/alpha/syscallent.h: Use sys_restart_syscall.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	Fixes RH#165469, Debian#350641.
+
+2005-08-08  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* system.c [LINUX] (MS_MGC_VAL): New macro.
+	[LINUX] (mount_flags): Add it.
+	[LINUX] (sys_mount): If neither MS_BIND nor MS_MOVE bits are
+        set in the flags argument, try to fetch data string.
+	Fixes RH#165377.
+
+2006-01-12  Roland McGrath  <roland@redhat.com>
+
+	* system.c (sys_sysctl): Don't read off end of NAME when max_strlen
+	exceeds INFO.nlen.
+	From Timo Lindfors <timo.lindfors@iki.fi>.
+	Fixes Debian#339117.
+
+	* debian/rules (binary-arch): Don't pass -s to install.  Use dh_strip.
+	Fixes Debian#325132.
+
+	* debian/control (Standards-Version): Update to 3.6.2.
+
+	* defs.h [LINUXSPARC] (PERSONALITY0_WORDSIZE, PERSONALITY1_WORDSIZE):
+	New macros.
+	[SPARC64] (PERSONALITY2_WORDSIZE): New macro.
+	[X86_64] (PERSONALITY0_WORDSIZE, PERSONALITY1_WORDSIZE): New macros.
+	* syscall.c (PERSONALITY0_WORDSIZE): New macro if undefined.
+	(personality_wordsize): New variable.
+	(decode_subcall): Use it for size of argument words.
+	Fixes RH#174354.
+
+2005-11-17  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Implement qual_flags support for each personality.
+	* strace.c (main): Move qualify calls after set_personality call.
+	* syscall.c (qual_flags0): New variable..
+	[SUPPORTED_PERSONALITIES >= 2] (qual_flags1): New variable.
+	[SUPPORTED_PERSONALITIES >= 3] (qual_flags2): New variable.
+	(qual_flags): Change variable definition from array to pointer.
+	(set_personality): Initialize qual_flags variable.
+	(qualify_one): Add "pers" argument to specify personality.
+	[SUPPORTED_PERSONALITIES >= 2]: Set qual_flags1 if requested.
+	[SUPPORTED_PERSONALITIES >= 3]: Set qual_flags2 if requested.
+	(qual_syscall): Pass personality to qualify_one.
+	[SUPPORTED_PERSONALITIES >= 2]: Look for syscall also in sysent1
+	table.
+	[SUPPORTED_PERSONALITIES >= 3]: Look for syscall also in sysent2
+	table.
+	(qual_signal): Pass personality to qualify_one.
+	(qual_desc): Likewise.
+	(qualify): Use qualify_one instead of manual qual_flags
+	manipulations.
+	[SUPPORTED_PERSONALITIES >= 2]: Look for syscall also in sysent1
+	table.
+	[SUPPORTED_PERSONALITIES >= 3]: Look for syscall also in sysent2
+	table.
+	* defs.h: Update qual_flags declaration.
+	Fixes RH#173986.
+
+2005-11-14  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* syscall.c (qual_syscall): Handle numeric syscall specification.
+	Fixes RH#174798.
+
+	* syscall.c (qual_signal, qual_options): Remove redundant argument
+	check.
+
+2005-12-01  Roland McGrath  <roland@redhat.com>
+
+	* ipc.c (indirect_ipccall) [MIPS || HPPA]: Return false.
+	Fixes Debian#340239.
+
+	* Makefile.am (EXTRA_DIST): Add linux/arm/syscallent.h
+	and linux/m68k/syscallent.h.
+	Fixes Debian#336197.
+
+	* debian/control (Architecture): Add armeb.
+	Fixes Debian#335681.
+
+2005-11-02 Michal Marek  <mmarek@suse.cz>
+
+	* strace-graph (handle_trace): follow clone() and vfork() calls.
+
+2005-10-25  Heiko Carstens  <heiko.carstens@de.ibm.com>
+
+	* linux/s390/syscallent.h: Added ioprio_set, ioprio_get,
+	inotify_init, inotify_add_watch, inotify_rm_watch.
+	Corrected number of arguments for request_key.
+	* linux/s390x/syscallent.h: Likewise.
+
+2005-12-01  Roland McGrath  <roland@redhat.com>
+
+	* ipc.c (indirect_ipccall) [IA64]: Return false unless the syscall
+	number is in the low range of IA32 syscalls.
+
+2005-10-07  Andreas Schwab  <schwab@suse.de>
+
+	* linux/ia64/syscallent.h: Syscall 1105 is gettid, not ioperm.
+
+2005-12-01  Roland McGrath  <roland@redhat.com>
+
+	* resource.c (resources): Add RLIMIT_NICE, RLIMIT_RTPRIO.
+	Reported by Scott Tsai <scottt958@yahoo.com.tw>.
+
+	* ipc.c (indirect_ipccall): New function.
+	(sys_msgctl, sys_msgsnd, sys_msgrcv, sys_semop): Use that predicate
+	instead of #ifdef LINUX test.
+	[LINUX] (sys_semtimedop): Likewise.
+	(sys_shmctl, sys_shmat, sys_shmdt): Likewise.
+	Fixes RH#164755.
+
+2005-07-31  Ulrich Drepper  <drepper@redhat.com>
+
+	* linux/x86_64/syscallent.h: Fix syscall parameter count for msgrcv and
+	msgctl.
+
+	* ipc.c (sys_msgrcv): Add entering handling and print first parameter
+	there.
+	Fixes RH#164757.
+
+2005-08-08  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* strace.1: Update "SEE ALSO" links to reference to valid
+	manpages.
+	Patch from Michail Litvak <mci@owl.openwall.com>.
+	Fixes RH#165375.
+
+2005-10-21  Roland McGrath  <roland@redhat.com>
+
+	* util.c (printpathn): Cap N at sizeof path - 1.
+
+2005-08-03  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.13.
+	* debian/changelog, strace.spec: 4.5.13-1.
+
+	* configure.ac: Check for struct dqblk.dqb_curblocks field.
+	* resource.c [LINUX] (OLD_CMD): New macro.
+	(quotacmds): Use it to hard-wire old O_* values, don't use macros.
+	(sys_quotactl): If dqb_curblocks is not there, it's called
+	dqb_curspace instead.  Print dqb_* fields as unsigned long long.
+
+2005-07-19  Michael Schmitz  <schmitz@debian.org>
+
+	Long overdue m68k cleanup.
+	* linux/syscallent.h: remove m68k declarations.
+	* linux/m68k/syscallent.h: new file, fixed up declarations
+	to match kernel version 2.6.11. Newer syscalls are sufficiently
+	different from i386 to merit a separate file.
+
+2005-08-03  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: Update init_module argument count.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent2.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/arm/syscallent.h: Likewise.
+
+2005-07-22  James Lentini  <jlentini@gmail.com>
+
+	* bjm.c (sys_init_module): Display all three arguments.
+	* linux/syscallent.h: Update argument count.
+
+2005-08-03  Roland McGrath  <roland@redhat.com>
+
+	* process.c (internal_wait): Don't suspend when known child is known
+	to be exiting already.
+
+	* strace.c (detach): If detaching the last live thread in a group with
+	a zombie leader, then detach the leader too.
+	(handle_group_exit): Use detach, not droptcb, for predeceased thread.
+	Mark process about to take a signal with TCB_GROUP_EXITING flag.
+	Fixes RH#161919.
+
+2005-07-19  Roland McGrath  <roland@redhat.com>
+
+	* defs.h [LINUX] [M68K] (__NR_exit_group): Define it if missing.
+	Fixes Debian#315500.
+
+2005-07-14  Heiko Carstens  <heiko.carstens@de.ibm.com>
+
+	* linux/s390/syscallent.h (sys_tgkill, vserver, fadvise64_64)
+	(statfs64, fstatfs64, remap_file_pages, mbind, get_mempolicy)
+	(set_mempolicy, mq_open, mq_unlink, mq_timedsend, mq_timedreceive)
+	(mq_notify, mq_getsetattr, sys_kexec_load, add_key, request_key)
+	(keyctl, waitid): Added.
+	* linux/s390x/syscallent.h: Likewise and added missing _llseek.
+	* linux/s390/errnoent.h (ECANCELED, ENOKEY, EKEYEXPIRED)
+	(EKEYREVOKED, EKEYREJECTED, EOWNERDEAD, ENOTRECOVERABLE): Added.
+	* linux/s390x/errnoent.h: Likewise.
+
+2005-07-05  Roland McGrath  <roland@redhat.com>
+
+	* mem.c [LINUX] (sys_old_mmap) [X86_64]: Extract 32-bit values if
+	child is 32-bit.
+	Fixes RH#162467.
+
+2005-06-08  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Introduce "-e trace=desc".
+	* defs.h (TRACE_DESC): New flag.
+	* syscall.c: Define TD macro before include of syscallent files
+	and undefine it afterwards.
+	(lookup_class): Recognize "desc" keyword.
+	* strace.1: Document "-e trace=desc".
+	* freebsd/i386/syscallent.h: Mark those syscalls which take a
+	file descriptor as an argument or return a file descriptor with
+	TD flag.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sh64/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent2.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	* sunos4/syscallent.h: Likewise.
+	* svr4/syscallent.h: Likewise.
+	Fixes RH#159400.
+
+	Remove TF flag from those syscalls which have no filename argument.
+	* freebsd/i386/syscallent.h: Remove TF flag from fstat, pread,
+	pwrite, fstat, sendfile.
+	* linux/alpha/syscallent.h: Remove TF flag from read, write,
+	pread, pwrite, sendfile.
+	* linux/hppa/syscallent.h: Remove TF flag from read, write,
+	pread, pwrite, fstat64, sendfile, ftruncate64.
+	* linux/ia64/syscallent.h: Remove TF flag from read, write,
+	sendfile, fstat, fadvise64.
+	* linux/mips/syscallent.h: Remove TF flag from read, write,
+	fstatfs, fstat, pread, pwrite, sendfile, ftruncate64, fstat64,
+	sendfile64, fadvise64, fstatfs64.
+	* linux/powerpc/syscallent.h: Remove TF flag from read, write,
+	fstat, pread, pwrite, sendfile, ftruncate64, fstat64, sendfile64,
+	fadvise64, fstatfs64, fadvise64_64.
+	* linux/s390/syscallent.h: Remove TF flag from pread, pwrite,
+	sendfile, ftruncate64, fstat64, sendfile64.
+	* linux/s390x/syscallent.h: Remove TF flag from pread, pwrite,
+	sendfile, sendfile64.
+	* linux/sh/syscallent.h: Remove TF flag from pread, pwrite,
+	sendfile, fstat64.
+	* linux/sh64/syscallent.h: Remove TF flag from pread, pwrite,
+	sendfile, ftruncate64, fstat64.
+	* linux/sparc/syscallent.h: Remove TF flag from sendfile, fstat64,
+	pread, pwrite, sendfile64.
+	* linux/sparc64/syscallent2.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/syscallent.h: Remove TF flag from pread, pwrite, sendfile,
+	ftruncate64, fstat64, sendfile64, fadvise64, fadvise64, fstatfs64,
+	fadvise64_64.
+	* linux/x86_64/syscallent.h: Remove TF flag from pread, pwrite,
+	sendfile, fadvise64_64.
+	* svr4/syscallent.h: Remove TF flag from pread, pwrite, ftruncate,
+	fstatvfs64, ftruncate64.
+	Fixes RH#159340.
+
+2005-07-04  Roland McGrath  <roland@redhat.com>
+
+	* net.c (sockipv6options): Add IPV6_ADD_MEMBERSHIP,
+	IPV6_DROP_MEMBERSHIP, IPV6_ROUTER_ALERT.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#162450.
+
+	* net.c (sockipoptions): Fix typos.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#161578.
+
+	* util.c (printnum_int): New function, printnum with s/long/int/.
+	* defs.h: Declare it.
+	* net.c (printsockopt): Use it for int-sized option.
+	Fixes RH#162449.
+	Reported by Ulrich Drepper <drepper@redhat.com>.
+
+2005-06-09  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.12.
+	* debian/changelog, strace.spec: 4.5.12-1.
+
+2005-06-08  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Minor namespace cleanup.
+	* defs.h (string_quote): Remove declaration.
+	* file.c (openmodessol) [LINUXSPARC]: Make static.
+	(fileflags): Likewise.
+	(aclcmds, aclipc) [HAVE_SYS_ACL_H]: Likewise.
+	(direnttypes) [FREEBSD || LINUX]: Likewise.
+	(xattrflags): Likewise.
+	* process.c (unalignctl_string): Make static.
+	(setarg): Disable.
+	* syscall.c (subcalls_table): Make static.
+	(socket_map) [!(LINUX && (ALPHA || MIPS))]: Likewise.
+	(sparc_socket_decode): Make static, define for [SPARC || SPARC64] only.
+	(decode_subcall): Make static.
+	(syscall_fixup): Likewise.
+	(get_error): Likewise.
+	(syscall_enter): Likewise.
+	* util.c (tv_tv): Disable.
+	(getpc): Likewise.
+	(string_quote): Make static.
+	Fixes RH#159688.
+
+2005-05-12  Philippe De Muyter  <phdm@macqel.be>
+
+	* util.c (getpc, printcall): Check #if defined(M68K), not M68k.
+	Enables `-i' on m68k machines.
+
+2005-06-06  Roland McGrath  <roland@redhat.com>
+
+	* process.c (struct_user_offsets) [X86_64]: Reorder elements so
+	matching works right.
+	Fixes RH#159787.
+
+	* linux/syscall.h (SYS_socket, SYS_bind, SYS_connect, SYS_listen)
+	(SYS_accept, SYS_getsockname, SYS_getpeername, SYS_socketpair)
+	(SYS_send, SYS_recv, SYS_sendto, SYS_recvfrom, SYS_shutdown)
+	(SYS_setsockopt, SYS_getsockopt, SYS_sendmsg, SYS_recvmsg)
+	(SYS_getsockname, SYS_semop, SYS_semgsub_et, SYS_semget, SYS_semctl)
+	(SYS_semtimedop, SYS_msgsnd, SYS_msgrcv, SYS_msgget)
+	(SYS_msgctl, SYS_shmat, SYS_shmdt, SYS_shmget)
+	(SYS_shmctl): Macros renamed to SYS_sub_*.
+	* syscall.c (dumpio): Match SYS_sub_* if defined instead of SYS_*.
+
+	* linux/syscall.h (SYS_waitid): Define if not defined.
+
+	* linux/syscallent.h: Fix pread/pwrite names to pread64/pwrite64.
+
+	* defs.h (struct sysent): New member `native_scno'.
+	(known_scno): Declare new function.
+	* linux/syscallent.h: Add new final field to interesting syscalls.
+	* syscall.c (known_scno): New function.
+	(dumpio, internal_syscall, syscall_fixup, trace_syscall): Use it.
+	* process.c (internal_fork, internal_exit): Likewise.
+	[IA64] (ARG_STACKSIZE, ARG_PTID, ARG_CTID, ARG_TLS): Likewise.
+	* strace.c (proc_open): Likewise.
+	* util.c [LINUX] (setbpt): Likewise.
+	* linux/syscall.h: Remove [!defined(X86_64)] from conditional
+	for defining SYS_socket_subcall et al.
+	* linux/syscallent.h: Likewise for #error check.
+	* syscall.c (trace_syscall): Likewise for SYS_{socketcall,ipc} cases.
+	Fixes RH#158934.
+
+2005-06-02  Roland McGrath  <roland@redhat.com>
+
+	* file.c (printstatfs64): Cast values to unsigned long long and use
+	%llu formats.
+	Fixes RH#158243.
+
+2005-05-31  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Deal with memory management issues.
+	* defs.h (tprint_iov): Update prototype.
+	* desc.c (sys_epoll_wait) [HAVE_SYS_EPOLL_H]: Do not allocate
+	epoll_event array of arbitrary size on the stack, to avoid
+	stack overflow.
+	* file.c (print_xattr_val): Check for integer overflow during
+	malloc size calculation, to avoid heap corruption.
+	* io.c (tprint_iov) [HAVE_SYS_UIO_H]: Check for integer overflow
+	during malloc size calculation, to avoid heap corruption.
+	Change iovec array handling to avoid heap memory allocation.
+	* mem.c (get_nodes) [LINUX]: Check for integer overflow during
+	size calculation and do not allocate array of arbitrary size on
+	the stack, to avoid stack overflow.
+	* net.c (printcmsghdr) [HAVE_SENDMSG]: Do not allocate array of
+	arbitrary size on the stack, to avoid stack overflow.  Do not
+	trust cmsg.cmsg_len to avoid read beyond the end of allocated
+	object.
+	(printmsghdr) [HAVE_SENDMSG]: Update tprint_iov() usage.
+	* process.c (sys_setgroups): Check for integer overflow during
+	malloc size calculation, to avoid heap corruption.  Change gid_t
+	array handling to avoid heap memory allocation.
+	(sys_getgroups): Likewise.
+	(sys_setgroups32) [LINUX]: Likewise.
+	(sys_getgroups32) [LINUX]: Likewise.
+	* stream.c (sys_poll) [HAVE_SYS_POLL_H]: Check for integer
+	overflow during malloc size calculation, to avoid heap corruption.
+	Change pollfd array handling to avoid heap memory allocation.
+	* system.c (sys_sysctl) [LINUX]: Check for integer overflow
+	during malloc size calculation, to avoid heap corruption.
+	* util.c (dumpiov) [HAVE_SYS_UIO_H]: Check for integer overflow
+	during malloc size calculation, to avoid heap corruption.
+	Fixes RH#159196.
+
+	* util.c (printxval): Change third argument from "char *" to
+	"const char *".
+	(printflags): Add third argument, "const char *", with similar
+	meaning to the third argument of printxval().
+	* defs.h (printxval): Change third argument from "char *" to
+	"const char *".
+	(printflags): Add third argument.
+	* bjm.c (sys_query_module) [LINUX]: Pass third argument to
+	printflags().
+	* desc.c (sys_fcntl): Likewise.
+	(sys_flock) [LOCK_SH]: Likewise.
+	(print_epoll_event) [HAVE_SYS_EPOLL_H]: Likewise.
+	* file.c (sys_open): Likewise.
+	(solaris_open) [LINUXSPARC]: Likewise.
+	(sys_access): Likewise.
+	(sys_chflags, sys_fchflags) [FREEBSD]: Likewise.
+	(realprintstat) [HAVE_LONG_LONG_OFF_T &&
+	HAVE_STRUCT_STAT_ST_FLAGS]: Likewise.
+	(printstat64) [HAVE_STAT64 &&
+	HAVE_STRUCT_STAT_ST_FLAGS]: Likewise.
+	(sys_setxattr, sys_fsetxattr): Likewise.
+	* ipc.c (sys_msgget, sys_msgsnd, sys_msgrcv, sys_semget,
+	sys_shmget, sys_shmat) [LINUX || SUNOS4 || FREEBSD]: Likewise.
+	(sys_mq_open) [LINUX]: Likewise.
+	(printmqattr) [HAVE_MQUEUE_H]: Likewise.
+	* mem.c (print_mmap) [!HAVE_LONG_LONG_OFF_T]: Likewise.
+	(sys_mmap64) [_LFS64_LARGEFILE || HAVE_LONG_LONG_OFF_T]: Likewise.
+	(sys_mprotect): Likewise.
+	(sys_mremap, sys_madvise, sys_mlockall) [LINUX]: Likewise.
+	(sys_msync) [MS_ASYNC]: Likewise.
+	(sys_mctl) [MC_SYNC]: Likewise.
+	(sys_remap_file_pages, sys_mbind, sys_get_mempolicy) [LINUX]:
+	Likewise.
+	* net.c (printmsghdr) [HAVE_STRUCT_MSGHDR_MSG_CONTROL]: Likewise.
+	(sys_send, sys_sendto): Likewise.
+	(sys_sendmsg) [HAVE_SENDMSG]: Likewise.
+	(sys_recv, sys_recvfrom): Likewise.
+	(sys_recvmsg) [HAVE_SENDMSG]: Likewise.
+	(printicmpfilter) [ICMP_FILTER]: Likewise.
+	* proc.c (proc_ioctl) [SVR4 && !HAVE_MP_PROCFS || FREEBSD]: Likewise.
+	* process.c (sys_clone) [LINUX]: Likewise.
+	(printwaitn): Likewise.
+	(sys_waitid) [SVR4 || LINUX]: Likewise.
+	* signal.c (sys_sigvec) [SUNOS4 || FREEBSD]: Likewise.
+	(sys_sigaction): Likewise.
+	(printcontext) [SVR4]: Likewise.
+	(print_stack_t) [LINUX) || FREEBSD]: Likewise.
+	(sys_rt_sigaction) [LINUX]: Likewise.
+	* sock.c (sock_ioctl) [LINUX]: Likewise.
+	* stream.c (sys_putmsg, sys_getmsg): Likewise.
+	(sys_putpmsg) [SYS_putpmsg]: Likewise.
+	(sys_getpmsg) [SYS_getpmsg]: Likewise.
+	(sys_poll): Likewise.
+	(print_transport_message) [TI_BIND]: Likewise.
+	(stream_ioctl): Likewise.
+	* system.c (sys_mount, sys_reboot): Likewise.
+	(sys_cacheflush) [LINUX && M68K]: Likewise.
+	(sys_capget, sys_capset) [SYS_capget]: Likewise.
+	* term.c (term_ioctl) [TIOCMGET]: Likewise.
+	* time.c (sys_clock_nanosleep, sys_timer_settime) [LINUX]:
+	Likewise.
+	Fixes RH#159310.
+
+	* bjm.c (sys_query_module) [LINUX]: Unitize "out of memory"
+	errors reporting style.
+	* strace.c (rebuild_pollv) [USE_PROCFS]: Likewise.
+	* system.c (sys_capget, sys_capset) [SYS_capget]: Likewise.
+	* util.c (printstr): Likewise.
+	(dumpiov) [HAVE_SYS_UIO_H]: Likewise.
+	(fixvfork) [SUNOS4]: Likewise.
+	* desc.c (decode_select): Continue to decode syscall arguments
+	in case of OOM condition.
+	* file.c (sys_getdents): Likewise.
+	(sys_getdents64) [_LFS64_LARGEFILE]: Likewise.
+	(sys_getdirentries) [FREEBSD]: Likewise.
+	* mem.c (sys_mincore): Changed type of variables which deal with
+	malloc size from int to unsigned long.
+	Fixes RH#159308.
+
+2005-05-22  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* bjm.c [LINUX]: Do not include <linux/linkage.h>.  It is not
+	safe to include kernel headers, and this one is not used anyway.
+	Fixes RH#158488.
+
+2005-05-26  Roland McGrath  <roland@redhat.com>
+
+	* system.c (sys_sysctl): Check for errors accessing user pointers.
+	Use malloc instead of alloca in case size is insane.
+
+2005-05-09  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: Check for libaio.h.
+	* desc.c (sys_io_setup, sys_io_submit, sys_io_cancel,
+	sys_io_getevents, sys_io_destroy): New functions.
+	* linux/syscall.h: Declare them.
+	* linux/syscallent.h: Use those for io_* syscalls.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	From Zach Brown <zach.brown@oracle.com>.
+	Fixes RH#155065.
+
+	* debian/control (Architecture): Add ppc64.
+	Fixes Debian bug #301089.
+
+2005-05-05  Anton Blanchard  <anton@samba.org>
+
+	* process.c (ptrace_cmds): Add PTRACE_GETVRREGS and PTRACE_SETVRREGS
+	if defined.
+
+2005-05-09  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Refuse negative -s argument value.
+	Fixes Debian bug #303256.
+
+2005-04-25  Anton Blanchard  <anton@samba.org>
+
+	* file.c (openmodes): Add O_NOATIME flag if defined.
+
+2005-04-05  Anton Blanchard  <anton@samba.org>
+
+	* linux/powerpc/ioctlent.h: Regenerated.
+
+	* signal.c (signame): Don't try and dereference negative index.
+
+	* linux/powerpc/syscallent.h: Add debug_setcontext, vserver,
+	mbind, *_mempolicy, mq_*, sys_kexec_load, add_key, request_key,
+	keyctl, waitid, sys_semtimedop.  Fix various other syscalls.
+
+	* ipc.c (shm_resource_flags): New variable, table has SHM_HUGETLB
+	but not IPC_NOWAIT, which have the same value.
+	(sys_shmget): Use that instead of resource_flags.
+
+2005-03-22  Roland McGrath  <roland@redhat.com>
+
+	* desc.c (decode_select): Increase local buffer size.
+	Fixes RH#151570.
+
+	* configure.ac, NEWS: Version 4.5.11.
+	* debian/changelog, strace.spec: 4.5.11-1.
+
+	* linux/arm/syscallent.h: Fix 113 entry (syscall, not vm86old).
+
+2005-03-14  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.10.
+	* debian/changelog, strace.spec: 4.5.10-1.
+
+2005-02-26  GOTO Masanori  <gotom@debian.or.jp>
+
+	* linux/alpha/syscallent.h: Fix the reversed order of lstat64 and
+	fstat64.  Clean up osf_nrecvmsg and osf_ngetsockname.
+
+2005-02-28  Andreas Schwab  <schwab@suse.de>
+
+	* syscall.c (getrval2): Move #ifdef IA64 inside #ifdef LINUX.
+
+2005-03-14  Roland McGrath  <roland@redhat.com>
+
+	* linux/mips/syscallent.h: Update various calls.
+	From Thiemo Seufer <ths@networkno.de>.
+	Fixes Debian bug #256684.
+
+	* debian/control (Architecture): Add s390.
+	Fixes Debian bug #294172.
+
+2005-03-06  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (trace) [PTRACE_GETSIGINFO]: Fetch siginfo_t for SIGSEGV
+	and SIGBUS signals, use si_addr in output.
+
+2005-03-01  Roland McGrath  <roland@redhat.com>
+
+	* file.c (print_xattr_val): Add a cast.
+
+2005-02-05  Roland McGrath  <roland@redhat.com>
+
+	* desc.c (decode_select): Calculate size of passed fd_set vectors and
+	copy in the user's size rather than the standard sizeof(fd_set).
+	Fixes Debian bug #65654, #284290.
+
+	* util.c (printpath, printpathn): Print NULL and don't try any fetch
+	when ADDR is zero.
+	Fixes Debian bug #63093.
+
+	* debian/control (Build-Depends): Fix for s390 and sparc.
+	From Bastian Blank <waldi@debian.org>.
+	Fixes Debian bug #293564.
+
+2004-12-19  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* strace.c (main) [!USE_PROCFS]: In child process, raise SIGSTOP
+	right before execv() call.  Remove fake_execve() call.
+	* defs.h (fake_execve): Remove unused declaration.
+	* process.c (fake_execve): Remove unused function.
+	Fixes RH#143365.
+
+2005-02-04  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.9.
+	* debian/changelog, strace.spec: 4.5.9-2.
+
+	* file.c (O_LARGEFILE): Omit when #undef'd because it was zero.
+
+2005-02-02  Roland McGrath  <roland@redhat.com>
+
+	* debian/control: Add strace-udeb package for installer debugging.
+	* debian/rules (binary-arch): Build it.
+	From Joshua Kwan <joshk@triplehelix.org>.
+	Fixes Debian bug #268294.
+
+	* file.c (openmodes) [O_LARGEFILE] [O_LARGEFILE == 0]: Redefine to
+	known values for Linux.
+
+	* util.c (printcall): Print 16 ?s when long is 8 bytes.
+	Fixes RH#146932.
+
+	* linux/sparc/syscall.h: Declare sys_epoll_create, sys_epoll_ctl,
+	sys_epoll_wait.
+	* linux/sparc64/syscall.h: Just #include "../sparc/syscall.h" here.
+	* ioctl.c (nioctlents2): Add const to type.
+	Fixes Debian bug #278449.
+
+	* sock.c (iffflags): New variable, table of IFF_* values.
+	(print_addr): New function.
+	(sock_ioctl): Handle SIOCGIFADDR, SIOCGIFDSTADDR, SIOCGIFBRDADDR,
+	SIOCGIFNETMASK, SIOCGIFFLAGS, SIOCGIFMETRIC, SIOCGIFMTU, SIOCGIFSLAVE,
+	SIOCGIFHWADDR.	Use print_addr for SIOCGIFCONF, SIOCGIFNAME, and
+	SIOCGIFINDEX, and fix their output.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#138223.
+	Fixes Debian bug #192164.
+
+2004-12-20  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* configure.ac: Use AC_GNU_SOURCE macro instead of changing CFLAGS.
+	* defs.h [HAVE_CONFIG_H]: Include config.h first.
+	* strace.c: Include "defs.h" first.
+	Fixes RH#143370.
+
+	* syscall.c (call_summary): Fix potential NULL dereference.
+	Fixes RH#143369.
+
+2004-12-19  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* syscall.c (qual_signal): Check bounds for numeric signal names.
+	Fix parser of symbolic signal names.
+	Fix return code, as required by qualify() function.
+	* syscall.c (qual_desc): Check bounds for descriptor number.
+	* syscall.c (qual_syscall): Correct return code, to be consistent
+	with qualify() and other qual_* functions.
+	Fixes RH#143362.
+
+2005-02-01  Roland McGrath  <roland@redhat.com>
+
+	* system.c [LINUX] (MS_MANDLOCK, MS_NOATIME, MS_NODIRATIME, MS_BIND,
+	MS_MOVE, MS_REC, MS_VERBOSE, MS_POSIXACL, MS_ACTIVE, MS_NOUSER):
+	New macros.
+	[LINUX] (mount_flags): Add them.
+	[LINUX] (sys_mount): If any of (MS_BIND|MS_MOVE|MS_REMOUNT) bits are
+	set in the flags argument, don't try to fetch the filesystem string.
+	Fixes RH#141932.
+
+	* config.guess: Update from canonical version, timestamp 2004-11-12.
+	* config.sub: Likewise, timestamp 2004-11-30.
+
+	* process.c [LINUX] [X86_64] (sys_arch_prctl): New function.
+	* linux/syscall.h: Declare it.
+	* linux/x86_64/syscallent.h: Use it.
+	Part of RH#142667.
+
+	* process.c (sys_sched_setscheduler): Use %#lx format for bad pointer.
+	(sys_sched_getparam, sys_sched_setparam): Likewise.
+	Part of RH#142667.
+
+	* signal.c [HAVE_SIGACTION] [LINUX && X86_64] (SA_RESTORER): Define
+	here too.
+	Part of RH#142667.
+
+	* linux/syscallent.h: Use sys_mincore instead of printargs.
+	* linux/x86_64/syscallent.h: Likewise.  Also use sys_getrlimit,
+	sys_semtimedop, sys_umount2.
+	Part of RH#142667.
+
+	* syscall.c (qual_signal): Fix inverted return value and bogus
+	argument to qualify_one in the named case.
+
+	* file.c (print_xattr_val): Don't use auto array sized by syscall
+	argument.  Use malloc instead, so it can fail for insane values.
+	Fixes Debian bug #283704.
+
+	* net.c (sys_getsockopt): Fix a format %ld -> %d.
+
+	* linux/syscall.h [IA64] (SYS_semtimedop): #undef it.
+
+	* syscall.c (syscall_enter) [X86_64]: Fix 32-bit argument register map
+	not to double the middle entry!
+	Fixes RH#146093.
+
+	* linux/x86_64/syscallent.h: Fix exit_group entry.
+
+	* util.c (getpc) [S390 || S390X]: Implement it.
+	Patch by David Wilder <wilder@us.ibm.com>.
+
+	* linux/ia64/syscallent.h: Add fadvise64, fstatfs64, statfs64, mbind,
+	[gs]et_mempolicy, mq_*, sys_kexec_load, vserver, and waitid.
+	Fixes RH#146245.
+
+2005-01-22  Andreas Schwab  <schwab@suse.de>
+
+	* net.c (sys_getsockopt): Change type of len to int.
+
+2004-10-19  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.8.
+	* debian/changelog, strace.spec: 4.5.8-1.
+
+	* file.c (sys_fadvise64): Conditionalize just on [LINUX].
+
+	* configure.ac: Check for sys/epoll.h.
+	* desc.c: Protect #include <sys/epoll.h> with [HAVE_SYS_EPOLL_H].
+	(epollctls, epollevents): Protect each entry with #ifdef on its macro.
+
+	* strace.c (handle_group_exit): Don't detach leader that wasn't
+	TCB_ATTACHED.  Instead mark it with TCB_GROUP_EXITING.
+	Remove droptcb loop at end, no longer required since 2.6 reports each
+	thread death.
+	Fixes RH#135254.
+
+	* strace.c (trace): Use handle_group_exit for non-TCB_ATTACHED child
+	taking signal when it has nclone_threads > 0.
+
+	* strace.c (handle_group_exit, trace): Mark leader with
+	TCB_GROUP_EXITING and don't be surprised at child deaths when their
+	leader has it set.
+	Fixes RH#132150.
+
+	* process.c (WCOREFLAG): Define if not defined.
+	(W_STOPCODE, W_EXITCODE): Likewise.
+	Reported by Marty Leisner <mleisner@eng.mc.xerox.com>.
+
+	* sock.c [! LINUX]: Include <sys/socket.h> before <sys/sockio.h>.
+	Reported by Marty Leisner <mleisner@eng.mc.xerox.com>.
+
+	* debian/rules: Make strace64.1.gz symlink to strace.1.gz instead of
+	strace64.1 to strace.1, which doesn't exist.
+	Fixes Debian bug #269220.
+
+2004-09-05  Phil Blundell  <pb@nexus.co.uk>
+
+	* linux/arm/syscallent.h: New file.
+
+2004-10-19  Roland McGrath  <roland@redhat.com>
+
+	* debian/rules (DEB_BUILD_GNU_TYPE, CONFIG_OPTS): New variables.
+	[$(DEB_HOST_GNU_TYPE) == s390-linux] (build64, HOST64, CC64): Set them.
+	(build/Makefile): Use $(CONFIG_OPTS).
+	(build64/Makefile): Pass --host as well as --build.
+	From Bastian Blank <waldi@debian.org>.
+	Fixes Debian bug #271500.
+
+	* linux/hppa/syscallent.h: Update for 2.6.9 syscalls.
+	From Randolph Chung <tausq@debian.org>
+	Fixes Debian bug #273887.
+
+	* file.c (sys_llseek): Revert last change.
+
+2004-09-14  Richard Henderson  <rth@twiddle.net>
+
+	* linux/alpha/syscallent.h: Add tgkill, *stat64, vserver, mbind,
+	[gs]et_mempolicy, mq_*, waitid.
+
+2004-10-07  Roland McGrath  <roland@redhat.com>
+
+	* file.c (sys_llssek, sys_readahead, sys_fadvise64, sys_fadvise64_64):
+	Use LONG_LONG macro.
+	* io.c (sys_pread, sys_pwrite, sys_sendfile): Likewise.
+
+	* linux/x86_64/syscallent.h: Fix botched table entries.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+	* mem.c [LINUX] (sys_mbind, sys_set_mempolicy, sys_get_mempolicy):
+	New functions.
+	* linux/syscall.h: Declare them.
+	* linux/x86_64/syscallent.h: Likewise.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+	* linux/syscallent.h: Handle mbind, set_mempolicy, get_mempolicy.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+	* file.c [LINUX && (I386 || X86_64)] (sys_fadvise64, sys_fadvise64_64):
+	New functions.
+	* linux/syscall.h: Declare them.
+	* linux/syscallent.h: Handle fadvise64 and fadvise64_64 using those.
+	* linux/x86_64/syscallent.h: Likewise.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+2004-09-13  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* linux/ioctlsort.c (main): Omit duplicate lines
+	(with same name and code) from output.
+	* linux/ioctlent.sh: Build the list of ioctls defined in
+	scsi/sg.h (0x22..), scsi/scsi.h and scsi/scsi_ioctl.h (0x53..),
+	as suggested by Peter Jones <pjones@redhat.com>
+	* linux/ioctlent.h: Regenerated.
+	Fixes RH#129808.
+
+2004-09-13  Ulrich Drepper <drepper@redhat.com>
+	    Dmitry V. Levin <ldv@altlinux.org>
+
+	* time.c [LINUX] (print_rtc): New function, for printing rtc_time
+	structure.
+	[LINUX] (rtc_ioctl): New function, for parsing RTC_* ioctls.
+	* ioctl.c [LINUX] (ioctl_decode): Call rtc_ioctl.
+	* defs.h [LINUX]: Declare rtc_ioctl.
+	Fixes RH#58606.
+
+2004-10-06  Roland McGrath  <roland@redhat.com>
+
+	* desc.c [LINUX] (sys_epoll_create, sys_epoll_ctl, sys_epoll_wait):
+	New functions.
+	* linux/syscall.h: Declare them.
+	* linux/syscallent.h: Use those for epoll_* syscalls.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/sparc64/syscallent.h: Likewise.
+	* linux/sparc64/syscallent2.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#134463.
+
+	* resource.c (resources): Add RLIMIT_LOCKS, RLIMIT_SIGPENDING,
+	and RLIMIT_MSGQUEUE, if defined.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#133594.
+
+	* net.c [HAVE_SENDMSG] (printcmsghdr): New function.
+	(printmsghdr): Use it.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#131689.
+
+	* file.c (sprintmode): Add const to return type.
+	(sprintfstype): Likewise.
+	* signal.c (printsiginfo): Add a const.
+
+2004-09-15  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: Use sys_waitid.
+
+	* linux/syscallent.h: waitid takes 5 arguments, and is in TP category.
+	* process.c (sys_waitid): Handle fifth argument (struct rusage *).
+
+2004-09-11  Roland McGrath  <roland@redhat.com>
+
+	* time.c (sys_clock_nanosleep): Print zero flags arg correctly.
+	(sys_timer_settime): Likewise.
+	(printsigevent): Print signals by name for SIGEV_SIGNAL.
+	(sys_timer_create): Print clock ID symbolically.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#131420.
+
+2004-09-07  Michal Ludvig  <mludvig@suse.cz>
+
+	* defs.h (nioctlents1, nsignals2): Fix typos in decls.
+
+2004-09-03  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (qual_options): Add const to defn.
+	Update all uses.
+	(call_count, error_count, tv_count): Variables removed.
+	(struct call_counts, counts): New type and variable.
+	Update all users of the old three to use the new array of structs.
+	(trace_syscall): Allocate counts on first use.
+	(sorted_count): Variable removed.
+	(call_summary): Allocate locally.
+
+	* syscall.c (sysent0, sysent1, sysent2, sysent): Add const to defn.
+	(nsyscalls0, nsyscalls1, nsyscalls2): Likewise.
+	(errnoent0, errnoent1, errnoent2, errnoent): Likewise.
+	(nerrnos0, nerrnos1, nerrnos2): Likewise.
+	* signal.c (signalent0, signalent1, signalent2): Likewise.
+	(nsignals0, nsignals1, nsignals2): Likewise.
+	(signame): LIkewise.
+	* ioctl.c (ioctlent0, ioctlent1, ioctlent2): Likewise.
+	(nioctlents0, nioctlents1, nioctlents2): Likewise.
+	(ioctl_lookup, ioctl_next_match): Likewise.
+	* defs.h: Update decls.
+	* io.c (sys_ioctl): Update users.
+
+	* util.c (xlookup, printxval, addflags, printflags): Use const for
+	struct xlat * argument.
+	* defs.h (xlookup, printxval, addflags, printflags): Update decls.
+	* bjm.c: Add const to all struct xlat defns.
+	* desc.c: Likewise.
+	* file.c: Likewise.
+	* ipc.c: Likewise.
+	* mem.c: Likewise.
+	* net.c: Likewise.
+	* proc.c: Likewise.
+	* process.c: Likewise.
+	* resource.c: Likewise.
+	* signal.c: Likewise.
+	* sock.c: Likewise.
+	* stream.c: Likewise.
+	* system.c: Likewise.
+	* term.c: Likewise.
+	* time.c: Likewise.
+	* util.c: Likewise.
+
+2004-09-01  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: Add new entries for timer_*, clock_*, and
+	mq_* syscalls, and names only for new calls up to 252.
+	* linux/syscallent.h: Add waitid.
+	* linux/x86_64/syscallent.h: Likewise.
+	* linux/syscall.h: Declare sys_waitid.
+
+	* process.c (internal_wait): Take second arg giving index of flags
+	argument.
+	* defs.h: Update prototype.
+	* syscall.c (internal_syscall): Update caller.
+	Also use internal_wait for SYS_waitid.
+	* process.c (sys_waitid): Define for [LINUX] as well.
+	Don't tweak TCB_SUSPENDED--internal_wait does that.
+	(waitid_types): Conditionalize use of nonstandard P_* macros.
+
+2004-08-31  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.7.
+	* debian/changelog: 4.5.7-1.
+	* strace.spec: 4.5.7-2.
+
+	* debian/rules: Rewrite sparc64 change of 2004-07-12.
+	Always do each build in a separate build directory.
+	Fixes Debian bug #254728.
+
+	* time.c (clocknames): Use #ifdef around CLOCK_* uses.
+
+	* strace.1: Say that -c shows system CPU time, not real time.
+	Fixes Debian bug #254438.
+
+	* syscall.c (dumpio): Match pread and pwrite system calls too.
+	Fixes Debian bug #239947.
+
+	* net.c (sockoptions): Add all SO_* macros known in Linux 2.6.9.
+	Fixes Debian bug #171653.
+
+2004-07-12  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* signal.c [LINUX] (parse_sigset_t): Fix hex strings parser.
+	Fixes RH#128091.
+
+2004-08-30  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Don't call fake_execve under -c.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#129166.
+
+	* net.c (sockipoptions): Add some options.
+	[SOL_IPV6] (sockipv6options): New variable.
+	(sys_getsockopt, printsockopt): Use it for SOL_IPV6 level.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#128391.
+
+	* time.c (clocknames): New variable, symbolic names for clock_t.
+	(sys_clock_settime, sys_clock_gettime, sys_clock_nanosleep): Use it.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#129378.
+
+	* system.c (personality_options): Hard-code values here.
+	Don't #include <linux/personality.h> at all.
+	Fixes RH#130965 and Debian bug #40588.
+
+	* file.c (print_xattr_val): New function to show attribute values.
+	(sys_setxattr, sys_fsetxattr, sys_getxattr, sys_fgetxattr): Use it.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#131177.
+
+2004-07-12  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.6.
+	* strace.spec, debian/changelog: 4.5.6-1.
+
+	* Makefile.am (EXTRA_DIST): Add linux/sparc64 files.
+
+	* debian/rules: On sparc-linux, build strace64 as well.
+	From Ben Collins <bcollins@debian.org>.
+	Fixes Debian bug #254728.
+
+2004-07-07  David S. Miller  <davem@nuts.davemloft.net>
+
+	* linux/sparc/syscallent.h: Sync with reality.
+	* linux/sparc/syscall.h (sys_sendfile64, sys_futex, sys_gettid,
+	sys_sched_setaffinity, sys_sched_getaffinity, sys_setxattr,
+	sys_lsetxattr, sys_fsetxattr, sys_getxattr, sys_lgetxattr,
+	sys_fgetxattr, sys_listxattr, sys_llistxattr, sys_flistxattr,
+	sys_removexattr, sys_lremovexattr, sys_fremovexattr,
+	sys_remap_file_pages, sys_readahead, sys_tgkill, sys_statfs64,
+	sys_fstatfs64, sys_clock_settime, sys_clock_gettime,
+	sys_clock_getres, sys_clock_nanosleep, sys_timer_create,
+	sys_timer_settime, sys_timer_gettime): New declarations.
+	* linux/sparc64/dummy2.h, linux/sparc64/syscallent2.h,
+	linux/sparc64/syscall.h, linux/sparc64/errnoent.h,
+	linux/sparc64/errnoent1.h, linux/sparc64/errnoent2.h,
+	linux/sparc64/ioctlent.h, linux/sparc64/ioctlent1.h,
+	linux/sparc64/ioctlent2.h, linux/sparc64/signalent.h,
+	linux/sparc64/signalent.h, linux/sparc64/signalent.h,
+	linux/sparc64/signalent1.h, linux/sparc64/signalent2.h,
+	linux/sparc64/syscall1.h, linux/sparc64/syscallent.h,
+	linux/sparc64/syscallent1.h: New files.
+	* defs.h (LINUXSPARC): Define also when SPARC64.
+	(LINUX && SPARC64): Set SUPPORTED_PERSONALITIES to 3.
+	Ignore SIGTRAP after execve by defining TCB_WAITEXECVE.
+	Define possibly missing __NR_exit_group.  Declare getrval2.
+	* configure.ac (sparc64): New architecture case.
+	* file.c (stat_sparc64): New structure.
+	(printstat_sparc64): New output routine for that.
+	(printstat): Call it, if personality is 2.
+	(printstat64): Likewise.
+	* util.c: Conditionalize ptrace defines on LINUXSPARC
+	not LINUX && SPARC.
+	(SPARC64 && LINUX): Define r_pc to r_tpc, and PTRACE_FOOREGS
+	to PTRACE_FOOREGS64 so that more sparc code can be shared
+	between 64-bit and 32-bit.
+	(_hack_syscall5): Correct trap number when SPARC64.
+	(PTRACE_WRITE{TEXT,DATA}): Add SPARC64 to ifdef guard.
+	(getpc): Handle SPARC64 && LINUX.
+	(printcall): Likewise.
+	(arg fetching/setting): Use same code for SPARC64 LINUX
+	as for SPARC.
+	(setbpt): Handle SPARC64 && LINUX.
+	(clearbpt): Likewise.
+	* signal.c: Conditionalize ptrace defines on SPARC and
+	SPARC64.
+	(SPARC64 && LINUX): Define r_pc to r_tpc, and PTRACE_FOOREGS
+	to PTRACE_FOOREGS64 so that more sparc code can be shared
+	between 64-bit and 32-bit.
+	(m_siginfo): Use same definition on SPARC64 as SPARC.
+	(sys_sigreturn): Handle LINUX && SPARC64.
+	* syscall.c: Conditionalize ptrace defines on SPARC and
+	SPARC64.
+	(SPARC64 && LINUX): Define r_pc to r_tpc, and PTRACE_FOOREGS
+	to PTRACE_FOOREGS64 so that more sparc code can be shared
+	between 64-bit and 32-bit.
+	(getscno): Use same static state on SPARC64 as SPARC,
+	and add SPARC64 handling.
+	(get_error): Handle LINUX && SPARC64.
+	(force_result): Likewise.
+	(syscall_enter): Likewise.
+	(trace_syscall): Handle sys_socketcall and sys_ipc on SPARC64
+	just like SPARC.
+	(getrval2): Handle LINUX && SPARC64.
+	* process.c: Conditionalize ptrace defines on SPARC and
+	SPARC64.
+	(SPARC64 && LINUX): Define r_pc to r_tpc, and PTRACE_FOOREGS
+	to PTRACE_FOOREGS64 so that more sparc code can be shared
+	between 64-bit and 32-bit.
+	(change_syscall): Handle LINUX && SPARC64.
+	(struct_user_offsets): Ifdef out those which do not exist
+	on SPARC64.
+	* net.c (sys_pipe): Handle LINUX && SPARC64.
+	* ioctl.c: Fix initializer typo for nioctlents2, was
+	nioctlents1 by accident.
+
+2004-06-28  Andreas Schwab  <schwab@suse.de>
+
+	* process.c (internal_exec): Move TCB_WAITEXECVE handling here.
+	(sys_execve): Remove it here.
+
+2004-07-12  Roland McGrath  <roland@redhat.com>
+
+	* Makefile.am (EXTRA_DIST): Add linux/sh64/syscallent.h.
+
+	* debian/control (Section): Move to utils, matching Debian override.
+
+	* net.c (addrfams): Make variable global.
+	* sock.c (sock_ioctl): Decode the arguments for SIOCGIFNAME,
+	SIOCGIFINDEX, and SIOCGIFCONF.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#126917.
+
+	* linux/ioctlsort.c: Add some #includes.
+	[POWERPC]: Kludge out high bits.
+	* linux/ia64/ioctlent.h: Regenerated using RHEL3 headers.
+	* linux/powerpc/ioctlent.h: Likewise.
+
+2004-07-11  Roland McGrath  <roland@redhat.com>
+
+	* linux/ioctlent.sh: Replace asm with $asm in all places.
+
+	* configure.ac: Add I386 as AM_CONDITIONAL.
+	* Makefile.am [LINUX]: Add maintainer-mode rules to regenerate
+	the ioctlent.h file.
+
+2004-07-08  Roland McGrath  <roland@redhat.com>
+
+	* resource.c (sys_quotactl): Truncate first argument to 32 bits, since
+	that's what the kernel will do.
+
+2004-07-07  Roland McGrath  <roland@redhat.com>
+
+	* linux/ioctlent.sh: Take optional second argument to use as directory
+	name in place of `asm'.
+
+2004-06-27  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.5.
+	* strace.spec, debian/changelog: 4.5.5-1.
+
+2004-06-22  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (syscall_fixup) [LINUX && X86_64]: For 32-bit process,
+	sign extend the low 32 bits of RAX to 64 bits.
+	Fixes RH#126547.
+
+	* syscall.c (force_result): [LINUX && X86_64]: Fix RAX*4 -> RAX*8.
+
+2004-06-03  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.4.
+	* strace.spec, debian/changelog: 4.5.4-1.
+
+	* net.c (domains): Add many PF_* values #ifdef PF_*.
+	(addrfams): Add many AF_* values #ifdef AF_*.
+	Fixes Debian bug #250506.
+
+2004-05-02  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* linux/ioctlsort.c (compare): When ioctl codes equal, compare
+	names.
+	(main): Print a note that program output is generated by
+	ioctlsort.
+	* linux/ioctlent.sh: Build the list of ioctls defined in
+	linux/fb.h (0x46..), linux/kd.h (0x4B..), linux/cdrom.h (0x53..),
+	asm/ioctls.h (0x54..), linux/vt.h (0x56..), linux/videotext.h
+	(0x71..), linux/videotext.h (0x72..), asm/sockios.h (0x89..),
+	linux/sockios.h (0x89..), linux/wireless.h (0x8B..).
+	* linux/ioctlent.h: Regenerated from linux-2.6.5.
+	Fixes RH#122257.
+
+2004-06-03  Roland McGrath  <roland@redhat.com>
+
+	* debian/control (Architecture): Add amd64.
+	Fixes Debian bug #246568.
+
+	* strace.c (main) [LINUX]: Expand TCBTAB as necessary for threads
+	attached.  Attach threads only under -f.  Set TCB_FOLLOWFORK in them.
+	(expand_tcbtab): New function, broken out of ...
+	* process.c (fork_tcb): ... here, call that.
+	* defs.h: Declare expand_tcbtab.
+
+2004-04-19  Roland McGrath  <roland@redhat.com>
+
+	* process.c (printstatus): Add a space before | in output.
+
+2004-04-16  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: Version 4.5.3.
+	* strace.spec, debian/changelog: 4.5.3-1.
+
+2004-03-18  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* resource.c (sys_quotactl) [LINUX]: Cast arithmetic shift operand
+	from long to unsigned long, to fix output of the quotactl command
+	parser.
+	Fixes RH#118694.
+
+2004-04-16  Roland McGrath  <roland@redhat.com>
+
+	* linux/s390/ioctlent.h, linux/s390x/ioctlent.h: Update DASD ioctls.
+	From Maxim Shchetynin <maxim@de.ibm.com>.
+
+	* configure.ac: Check for <mqueue.h>.
+	* ipc.c (sys_mq_open, printmqattr) [! HAVE_MQUEUE_H]: Don't try to
+	decode struct mq_attr.
+	* NEWS: Mention mq support.
+
+	* linux/syscall.h: Support new mq_* syscalls on Linux.
+	* linux/syscallent.h: Likewise.
+	* linux/dummy.h: Likewise.
+	* ipc.c: Likewise.
+	* time.c (printsigevent): Handle SIGEV_THREAD.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#120701.
+
+2004-04-13  Roland McGrath  <roland@redhat.com>
+
+	* net.c (msg_flags): Grok MSG_FIX, MSG_SYN, MSG_RST, MSG_NOSIGNAL,
+	MSG_MORE.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#120541.
+
+	* process.c (printstatus): Mask out bits presented symbolically, and
+	print "| 0xnnn" if the remaining bits are not all zero.
+	Fixes Debian bug #240062.
+
+	* process.c (print_affinitylist): Rewritten to handle indirect values.
+	(sys_sched_setaffinity, sys_sched_getaffinity): Update callers.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#118685.
+
+	* acinclude.m4: Quote first argument to AC_DEFUN in all cases.
+
+2004-04-08  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main) [LINUX]: When attaching for -p, look in
+	/proc/PID/task for all threads and attach them as presumed
+	CLONE_THREAD children.
+	* NEWS: Mention the feature.
+	Fixes RH#120462.
+
+2004-03-02  Roland McGrath  <roland@redhat.com>
+
+	* util.c (setbpt): Fix one missed spot to use new arg0_index macro.
+	From Michael Holzheu <HOLZHEU@de.ibm.com>.
+
+	* debian/control (Standards-Version): Update to 3.6.1.
+
+2004-03-01  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.2.
+	* strace.spec, debian/changelog: 4.5.2-1.
+
+	* strace.c (main): Avoid potential buffer overruns from ludicrous
+	arguments or PATH values.
+	* syscall.c (qual_signal): Bail out for too-long string.
+
+	* mem.c [LINUX]: <asm/mman.h> -> <linux/mman.h>
+	Fixes Debian bug #223207.
+
+	* linux/sparc/syscall.h: Copy linux/syscall.h decls of sys_sched_*.
+
+	* configure.ac: Check for `struct user_desc' in <asm/ldt.h>.
+	* process.c [HAVE_STRUCT_USER_DESC]: Use struct user_desc in place of
+	struct modify_ldt_ldt_s.
+	* mem.c [HAVE_STRUCT_USER_DESC]: Likewise.
+
+	* system.c (sysctl_vm): Conditionalize VM_* macro uses, add some more.
+	From Tim Yamin <plasmaroo@gentoo.org>.
+
+	* process.c (sys_execve): Clear instead of set TCB_WAITEXECVE on
+	erring syscall.
+
+	* configure.ac: Check for `struct pt_all_user_regs'
+	and `struct ia64_fpreg' in <sys/ptrace.h>.
+	* util.c, process.c, syscall.c, signal.c: Work around conflicts between
+	<sys/ptrace.h> and <linux/ptrace.h> for defining those types.
+
+	* process.c (struct_user_offsets) [LINUX && IA64]: Conditionalize
+	PT_AR_CSD and PT_AR_SSD uses in case of older kernel headers.
+
+	* util.c [LINUX] (arg0_index, arg1_index): New macros.
+	[S390 || S390X]: Define them with inverted values.
+	(setbpt): Use them for u_arg indices.
+
+2004-02-26  Andreas Schwab  <schwab@suse.de>
+
+	* defs.h [LINUX && IA64]: Declare getrval2 also on IA64.
+	* net.c (sys_pipe) [LINUX && IA64]: For IA64 use the two return values.
+	* syscall.c (getrval2) [LINUX && IA64]: Implement for IA64.
+
+2004-03-01  Roland McGrath  <roland@redhat.com>
+
+	* linux/dummy.h (sys_sched_getscheduler, sys_sched_setparam,
+	sys_sched_getparam, sys_sched_setscheduler, sys_sched_getscheduler,
+	sys_sched_get_priority_max, sys_sched_get_priority_min): Remove macros.
+	* process.c [LINUX] (sys_sched_getscheduler, sys_sched_setparam,
+	sys_sched_getparam, sys_sched_setscheduler, sys_sched_getscheduler,
+	sys_sched_get_priority_min): New functions.
+	From Ulrich Drepper <drepper@redhat.com>.
+	Fixes RH#116990.
+
+2004-02-20  Roland McGrath  <roland@redhat.com>
+
+	* linux/hppa/syscallent.h: Update some syscalls.
+	From Randolph Chung <tausq@debian.org>.
+	Fixes Debian bug #231632.
+
+2003-12-31  David Mosberger  <davidm@hpl.hp.com>
+
+	* process.c (internal_exit): For ia64, also recognize IA-32 252
+	as exit_group().
+	(change_syscall): For IA64, also support changing IA-32 syscalls.
+	* syscall.c (internal_syscall): For IA64, also recognize IA-32
+        syscall 252 (exit_group) as an internal_exit() syscall.
+	* util.c (SYS_fork): For IA64, define them to the IA-32 syscall
+	number.
+	(SYS_vfork): Likewise.
+	(arg_setup): For IA64 version, also support IA-32 syscalls.
+	(get_arg0): Likewise.
+	(get_arg1): Likewise.
+	(set_arg0): Likewise.
+	(set_arg1): Likewise.
+
+2004-02-15  Anton Blanchard  <anton@samba.org>
+
+	* linux/powerpc/syscallent.h: Add rtas call.
+	Shift multiplexed syscalls to start at 300, we are already about
+	to hit 256 real syscalls.
+	* linux/syscall.h: SYS_socket_subcall is now 300 for [POWERPC].
+
+2004-02-19  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Use TCP->pid, not PID, in -p message.
+	Fixes Debian bug #229802.
+
+2004-01-13  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (force_result) [LINUX] [S390 || S390X]: Remove bogus upeek
+	call.
+
+	* stream.c (internal_stream_ioctl): Fix typo strict -> struct.
+	Reported by Petter Reinholdtsen <pere@hungry.com>.
+
+2003-12-31  David Mosberger  <davidm@hpl.hp.com>
+
+	* process.c (struct_user_offsets) [IA64]: Fix up register name list.
+
+2003-12-14  Anton Blanchard  <anton@samba.org>
+
+	* file.c (sys_getdents64): Don't cast d_ino and d_off to unsigned long.
+	Use %llu formats for them.
+
+	* file.c [LINUX] (fsmagic): Add SYSFS_MAGIC.
+
+	* linux/powerpc/syscallent.h: Update to include recently added
+	syscalls.
+
+	* syscall.c (get_error) [POWERPC]: Cast result to unsigned long for
+	ppc64, we were misreporting syscalls that really succeeded as having
+	failed.
+
+2004-01-13  Roland McGrath  <roland@redhat.com>
+
+	* strace.1: Remove comment about vfork on Linux.
+	Fixes Debian bug #223390.
+
+	* file.c (direnttypes): Define under [LINUX] as well.  Add DT_UNKNOWN.
+	(sys_getdents64) [LINUX]: Print d_type field.
+
+2003-12-15  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* strace.c (trace) [WCOREDUMP]: Show coredump status of the
+	killed process if available.  Fixes RH#112117.
+
+2003-11-13  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.1.
+	* strace.spec, debian/changelog: 4.5.1-1.
+
+2003-09-06  Dmitry V. Levin  <ldv@altlinux.org>
+
+	* defs.h (ioctl_lookup): Prototype change.
+	* ioctl.c (ioctl_next_match): New function.
+	* defs.h: Declare it.
+	* io.c (sys_ioctl): Use it, to display all possible ioctl names
+	when there's more than one match.
+	* ioctl.c (ioctl_lookup): Likewise.
+	* stream.c (internal_stream_ioctl): Likewise.
+	Patch from Solar Designer <solar@openwall.com>.
+
+2003-11-13  Roland McGrath  <roland@redhat.com>
+
+	* linux/sh/syscallent.h: Use sys_setgroups32, sys_getgroups32.
+	* linux/sh64/syscallent.h: Likewise.
+
+2003-09-06  Dmitry V. Levin  <ldv@altlinux.org>
+
+	Fixes for RH#105359.
+	* util.c (printuid): New function.
+	* defs.h: Declare it.
+	* file.c (sys_chown): Use it.
+	* file.c (sys_fchown): Likewise.
+	* process.c (sys_setreuid, sys_setregid, sys_setresuid,
+	sys_setresgid): Likewise.
+	* linux/syscallent.h: Better handle getgid32, geteuid32, getegid32,
+	setreuid32, setregid32, getgroups32, setgroups32, fchown32,
+	setresuid32, getresuid32, setresgid32, getresgid32, chown32,
+	setuid32, setgid32, setfsuid32, setfsgid32.
+	* process.c [LINUX]: Define GETGROUPS32_T.
+	* process.c [LINUX] (sys_setgroups32, sys_getgroups32):
+	New functions.
+	* linux/syscall.h (sys_setgroups32, sys_getgroups32):
+	Declare them.
+
+2003-11-11  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Bail with usage error for missing command before we
+	open the -o file or fiddle uids.
+
+2003-11-06  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Treat piped output more like file output.
+	Disallow -ff with piped output.  Fixes RH#105366.
+	Reported by Dmitry V. Levin <ldv@altlinux.org>
+
+	* strace.c (tprintf): Check result of vfprintf and use perror when it
+	fails while not writing to stderr itself.  Fixes Debian bug #218762.
+
+	* net.c (printsock): Fix typo in #ifdef AF_NETLINK.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+2003-11-01  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (trace_syscall) [LINUX]: Calculate ONE_TICK once using
+	setitimer rather than hard-coding a value based on HZ.
+	Fixes RH#108012, reported by Florian La Roche <laroche@redhat.com>.
+
+2003-10-21  Roland McGrath  <roland@redhat.com>
+
+	* strace.1: Fixed a few spelling errors.
+	Fixes Debian bug #217008.
+
+	* syscall.c: Revert last change, was broken.
+
+2003-10-01  Roland McGrath  <roland@redhat.com>
+
+	* process.c (internal_clone): Don't suspend parent when call requested
+	a specific PID that is not a traced child.
+
+	* signal.c [LINUX] (parse_sigset_t): Rewrite to process hex strings
+	from right to left so we don't have to presume the size.
+	Reported by David Woodhouse <dwmw2@redhat.com>.
+
+2003-09-25  Roland McGrath  <roland@redhat.com>
+
+	* mem.c (mmap_prot) [PROT_SEM, PROT_GROWSDOWN, PROT_GROWSUP]: Include
+	these in the table if they are defined.
+
+2003-09-24  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.5.
+	* strace.spec, debian/changelog: 4.5-1.
+
+	* syscall.c (get_scno) [LINUX] [S390 || S390X]: Bail out of
+	instruction decoding branch if TCB_INSYSCALL is clear.
+	Reported by <jochen@penguin-breeder.org>.
+
+	* linux/ioctlent.h: Swap order of overloaded TC* and SNDCTL_* values.
+
+2003-09-23  Roland McGrath  <roland@redhat.com>
+
+	* strace.spec: On ppc64 (maybe others later), create an strace64
+	package as well containing just /usr/bin/strace64.
+
+	* signal.c (sprintsigmask): Print RT_%u for __SIGRTMIN..__SIGRTMAX.
+	Fixes RH#104365.
+
+2003-08-21  Roland McGrath  <roland@redhat.com>
+
+	* linux/syscallent.h: Fix mlock argument count.  Fixes RH#101499.
+	* linux/x86_64/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+
+2003-07-28  Daniel Jacobowitz  <drow@mvista.com>
+
+	* defs.h (ALIGN64): Define for MIPS.
+	* io.c (PREAD_OFFSET_ARG): Define.
+	(sys_pread, sys_pwrite): Use it.
+	* process.c (struct_user_offsets) [SH]: Check whether REG_XDREG0
+	is defined.
+	* linux/sh/syscallent.h (pread, pwrite): Take six arguments.
+	(truncate64, ftruncate64): Pretty-print.
+	* linux/mips/syscallent.h (pread, pwrite): Take six arguments.
+	(truncate64, ftruncate64): Take four arguments.
+
+2003-07-17  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.4.99.
+	* strace.spec, debian/changelog: 4.4.99-1.
+
+2003-07-15  Anton Blanchard  <anton@samba.org>
+
+	* ipc.c: Add SHM_HUGETLB field.
+	Mask out permission bits in msgget, semget and shmget before
+		printing resource_flags.
+	Mask execute permission bits (even though we dont currently
+		use them).
+
+2003-07-17  Roland McGrath  <roland@redhat.com>
+
+	* linux/powerpc/syscallent.h (tgkill): New at 250.
+
+	* linux/syscallent.h: truncate64/ftruncate64 need 3 args.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+	* linux/syscallent.h: Handle statfs64, fstatfs64, utimes.
+	* file.c (printstatfs): Print f_fsid and f_frsize.
+	[LINUX] (printstatfs64, sys_statfs64, sys_fstatfs64): New functions.
+	* linux/syscall.h: Add decls.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+2003-07-09  Roland McGrath  <roland@redhat.com>
+
+	* linux/ia64/syscallent.h (tgkill): New at 1235.
+
+2003-07-05  Richard Henderson  <rth@twiddle.net>
+
+	* process.c (sys_clone): Order arguments for alpha the same as x86_64.
+	* syscall.c (ERESTART_RESTARTBLOCK): New.
+	(trace_syscall): Print it.
+	* linux/alpha/syscallent.h (osf_syscall): Name properly.
+	(osf_set_program_attributes): Fix typo.
+	(osf_nfssvc): Likewise.
+	(osf_sigsendset): Likewise.
+	(getdents64, gettid, readahead, tkill, setxattr, lsetxattr, fsetxattr,
+	getxattr, lgetxattr, fgetxattr, listxattr, llistxattr, flistxattr,
+	removexattr, lremovexattr, fremovexattr, futex, sched_setaffinity,
+	sched_getaffinity, tuxcall, io_setup, io_destroy, io_getevents,
+	io_submit, io_cancel, exit_group, lookup_dcookie, epoll_create,
+	epoll_ctl, epoll_wait, remap_file_pages, set_tid_address,
+	restart_syscall, fadvise, timer_create, timer_settime, timer_gettime,
+	timer_getoverrun, timer_delete, clock_settime, clock_gettime,
+	clock_getres, clock_nanosleep, semtimedop): New.
+
+2003-07-08  Roland McGrath  <roland@redhat.com>
+
+	* signal.c (sys_tgkill): New function.
+	* linux/syscall.h: Declare it.
+	* linux/syscallent.h: Add tgkill.
+
+2003-06-27  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: Check for type `struct __old_kernel_stat'.
+	* file.c (convertoldstat, printoldstat): Define under
+	[LINUX && HAVE_STRUCT___OLD_KERNEL_STAT] rather than a list of archs.
+	(sys_oldstat, sys_oldfstat, sys_oldlstat): Likewise.
+	* linux/dummy.h [! HAVE_STRUCT___OLD_KERNEL_STAT]
+	(sys_oldstat, sys_oldfstat, sys_oldlstat): #define to printargs.
+
+2003-06-26  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: SHMEDIA -> SH64
+	* defs.h: Likewise.
+	* mem.c: Likewise.
+	* process.c: Likewise.
+	* sock.c: Likewise.
+	* syscall.c: Likewise.
+	* util.c: Likewise.
+	* linux/shmedia/syscallent.h: Moved to ...
+	* linux/sh64/syscallent.h: ... here.
+
+	* config.guess: Update from canonical version, timestamp 2003-06-17.
+	* config.sub: Likewise.
+
+	* syscall.c (force_result) [LINUX] [ARM]: Fix variable usage.
+	From: Joshua Neal <tinara@netpipeline.net>.
+
+	* process.c [LINUX] (sys_futex): Grok FUTEX_REQUEUE and print 5th arg.
+	* linux/syscallent.h: sys_futex argument count is now 5, not 4.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/x86_64/syscallent.h: Likewise.
+	From Jakub Jelinek <jakub@redhat.com>.
+
+	* syscall.c (get_scno) [S390 || S390X]: Fix old vs new mode detection.
+	From Michael Holzheu <HOLZHEU@de.ibm.com>.
+
+2003-06-23  Roland McGrath  <roland@redhat.com>
+
+	* net.c (sys_socket): Decode protocol for PF_INET6 same as PF_INET.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+2003-06-10  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.4.98.
+	* strace.spec, debian/changelog: 4.4.98-1.
+
+2003-06-09  Roland McGrath  <roland@redhat.com>
+
+	* linux/s390x/syscallent.h: Update many syscalls.
+	* linux/syscall.h (SYS_socket_subcall): Update [S390X] value.
+
+	* linux/s390/syscallent.h: Update many syscalls.
+	* linux/syscall.h (SYS_socket_subcall): Update [S390] value.
+
+	* linux/shmedia/syscallent.h: New file.
+	From Stephen Thomas <stephen.thomas@superh.com>.
+
+	* strace.c (trace): Print a message and newline for a WIFEXITED report
+	from the process we just printed an unterminated syscall line for.
+
+2003-06-03  Roland McGrath  <roland@redhat.com>
+
+	* util.c (printcall) [LINUX]: Fix typo [IA62] -> [IA64].
+
+	Linux/ARM improvements from Russell King <rmk@arm.linux.org.uk>:
+	* defs.h [LINUX] (TCB_WAITEXECVE): Define for [ARM] too.
+	* process.c (struct_user_offsets) [LINUX] [ARM]: Add ARM registers.
+	* signal.c [LINUX] (sys_sigreturn) [ARM]: New case.
+	* syscall.c (get_scno, syscall_fixup) [LINUX] [ARM]: Case rewritten.
+	(get_error) [LINUX] [ARM]: Update.
+	(syscall_enter) [LINUX] [ARM]: New case.
+	* util.c (printcall) [LINUX] [ARM]: New case.
+
+	* debian/control (Standards-Version): Update to 3.5.10.
+
+	* strace.c (main): In PATH search, accept only a regular file with
+	execute bits set.  Fixes Debian bug #137103.
+
+2003-06-02  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (main): Set -q when given -o and not -p, and not when not
+	given -o, to match what the man page always said.
+	Fixes Debian bug #47113, #153678.
+
+	* configure.ac, NEWS: Version 4.4.97.
+	* strace.spec, debian/changelog: 4.4.97-1.
+
+	* configure.ac, defs.h, mem.c, process.c, sock.c, syscall.c, util.c:
+	Merged in SHmedia port from Stephen Thomas <stephen.thomas@superh.com>.
+
+	* config.guess: Update from ftp://ftp.gnu.org/pub/gnu/config/,
+	timestamp 2003-05-22.
+	* config.sub: Likewise, timestamp 2003-05-24.
+
+2003-05-22  Roland McGrath  <roland@redhat.com>
+
+	* defs.h (struct tcb): New member `nzombies'.
+	* strace.c (alloctcb): Initialize it.
+	(droptcb): Increment our parent's zombie count.
+	* process.c (internal_wait): Don't go into TCB_SUSPENDED if the
+	process has zombies it can reap.  On the way out, if we reaped
+	an untraced process, decrement the zombie count.
+
+	* process.c (sys_clone): Mask CSIGNAL out of flags and print that
+	separately using signame.
+
+	* process.c (internal_clone) [TCB_CLONE_THREAD]: Use ARG_FLAGS instead
+	of literal 0 for index.  Consult the right flags without clobbering
+	anything when we reparent the new child to the caller's parent thread.
+
+	* linux/s390/syscallent.h: Fix sys_clone argument count.
+	* linux/s390x/syscallent.h: Likewise.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/alpha/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/sh/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+
+	* process.c [LINUX] [S390 || S390X] (ARG_CTID, ARG_TLS): Fix swapped
+	indices.  Reported by Jakub Jelinek <jakub@redhat.com>.
+
+	* signal.c [LINUX] (SI_SIGIO, SI_TKILL): New macros.
+	[LINUX || SVR4] (siginfo_codes): Add strings for them.
+
+	* process.c (print_affinitylist): Fix loop condition.
+	Reported by Ian Wienand <ianw@gelato.unsw.edu.au>.
+
+2003-04-10  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (qual_desc): Return zero after parsing number.
+	From Rob Leslie <rob@mars.org>, fixes Debian bug #188379.
+
+2003-04-07  Roland McGrath  <roland@redhat.com>
+
+	* linux/syscallent.h: Handle semtimedop subcall of ipc syscall.
+	* linux/syscall.h: Likewise.
+	* ipc.c [LINUX] (sys_semtimedop): New function.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+	* ipc.c (sys_semget): Mask off permission bits for resource_flags.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+2003-04-01  Philippe De Muyter  <phdm@macqel.be>
+
+	* sock.c, stream.c: Check #ifdef LINUX, not linux.
+	* file.c: Always provide sys_*attr, regardless of #ifdef XATTR_CREATE.
+
+2003-03-30  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.4.96.
+	* strace.spec, debian/changelog: 4.4.96-1.
+
+2003-02-26  Stuart Menefy <stuart.menefy@st.com>
+
+	Various fixes for SuperH [SH]:
+	* mem.c (sys_old_mmap): mmap() parameters passed in registers
+	* net.c (sys_pipe), syscall.c (getrval2): pipe() results returned
+	in registers
+	* process.c (change_syscall): Fixed register which holds system
+	call number
+	* util.c (arg0_offset, arg1_offset): provide definition
+	* Makefile.am: Added new files in linux/sh
+	* linux/sh/syscallent.h: New file.
+	* linux/sh/errnoent.h: New file.
+	* linux/sh/ioctlent.h: New file.
+	* linux/sh/signalent.h: New file.
+
+	* linux/ioctlent.sh: Take an arg for location of header files
+	* syscallent.sh: Replaced lost $
+
+2003-03-30  Roland McGrath  <roland@redhat.com>
+
+	* time.c [LINUX]: Handle new Linux 2.5 clock/timer syscalls.
+	* linux/syscall.h, linux/syscallent.h, linux/dummy.h: Likewise.
+	From Ulrich Drepper <drepper@redhat.com>.
+
+	* linux/syscallent.h: Use sys_getrlimit for 191.
+	Use name "old_getrlimit" for 76.
+	Reported by Ulrich Drepper <drepper@redhat.com>.
+
+2003-03-18  Roland McGrath  <roland@redhat.com>
+
+	* process.c [LINUX] (sys_clone): Don't dereference parent_tid argument.
+
+2003-03-17  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: clone takes 5 args.
+	* process.c [LINUX] (sys_clone) [X86_64]: Fix argument order.
+
+2003-03-15  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: Add exit_group syscall at 231.
+
+2003-03-14  Roland McGrath  <roland@redhat.com>
+
+	* linux/x86_64/syscallent.h: Update and add many 2.5 syscalls.
+
+	* linux/ia64/syscallent.h: clone takes 5 arguments.
+	* process.c [LINUX && IA64] (ARG_*): Update for 2.5 clone calls.
+
+2003-03-12  Roland McGrath  <roland@redhat.com>
+
+	* linux/ia64/syscallent.h: Fix arg counts for clone and clone2.
+	Use sys_clone for clone2.
+	* linux/syscall.h: Don't declare sys_clone2.
+	* process.c (sys_clone): Rewritten to handle both flavors,
+	print all extra args depending on flag bits.
+	(sys_clone2): Function removed.
+
+	* linux/ia64/syscallent.h: Add a bunch of 2.5 syscalls.
+
+2003-03-04  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (get_scno) [IA64]: Do TCB_WAITEXECVE check only when
+	TCB_INSYSCALL is clear, like other platforms do.
+
+2003-03-04  Ulrich Drepper  <drepper@redhat.com>
+
+	* mem.c [LINUX] (sys_remap_file_pages): New function.
+	* linux/syscall.h: Declare it.
+	* linux/syscallent.h: Use it.
+	* linux/powerpc/syscallent.h: Likewise.
+
+	* process.c [LINUX] (sys_futex): Omit final if op is not FUTEX_WAIT.
+
+2003-02-26  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac: Fix typo in netinet/in.h check.
+	Also include <sys/types.h> and <sys/socket.h> before <netinet/in.h>.
+	Reported by Alex Semenyaka <alexs@snark.rinet.ru>.
+
+2003-02-24  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.4.95.
+	* strace.spec, debian/changelog: 4.4.95-1.
+
+	* process.c (sys_getresgid): Fix typos in argument access.
+
+2003-02-23  Roland McGrath  <roland@redhat.com>
+
+	* process.c (sys_getresuid): Fix typos in argument access.
+	Reported by Anton Blanchard <anton@samba.org>.
+
+2003-02-19  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.4.94.
+	* strace.spec, debian/changelog: 4.4.94-1.
+
+	* version.c: Removed.
+	* Makefile.am (strace_SOURCES): Remove it.
+	* strace.c: Use PACKAGE_NAME and VERSION macros instead of version var.
+
+	FreeBSD rfork support changes from Russ Cox <rsc@plan9.bell-labs.com>:
+	* syscall.c (internal_syscall): Handle SYS_rfork with internal_fork.
+	* process.c (internal_fork) [SYS_rfork]: Bail if RFPROC flag not set.
+
+2003-01-23  Roland McGrath  <roland@redhat.com>
+
+	* signal.c: Reorder #ifdefs so HAVE_ASM_SIGCONTEXT_H doesn't matter on
+	SPARC, which doesn't use the header regardless.
+
+	* util.c [LINUX && SPARC]: Do renaming kludges around <asm/reg.h>
+	like signal.c does.
+
+	* linux/sparc/syscall.h: Declare sys_getdents64, sys_llseek.
+
+	* linux/dummy.h [! SYS_getpmsg] (sys_getpmsg): #define to printargs.
+	[! SYS_putpmsg] (sys_putpmsg): Likewise.
+
+	* process.c: Reorder includes to put sys/reg.h before linux/ptrace.h,
+	since they can conflict.
+
+2003-01-21  Roland McGrath  <roland@redhat.com>
+
+	* strace.c (usage): Omit -z, since it has never worked properly.
+	* NEWS: Likewise.
+
+	* strace.c (main): Grok new option `-E var=val' or `-E var' to put
+	var=val in environ or to remove var, respectively.
+	(usage): Mention it.
+	* strace.1, NEWS: Document it.
+
+	* configure.ac, NEWS: Version 4.4.93.
+	* strace.spec, debian/changelog: 4.4.93-1.
+	* strace.spec (Source0): Use strace-VERSION.tar.bz2 now.
+
+2003-01-20  Roland McGrath  <roland@redhat.com>
+
+	* defs.h [LINUX] [S390 || S390X] (TCB_WAITEXECVE): Define it.
+	* syscall.c (get_scno, syscall_fixup) [LINUX] [S390 || S390X]: Handle
+	TCB_WAITEXECVE state with special kludges.
+
+	* process.c [LINUX] (sys_clone) [S390 || S390X]: Argument order is
+	reversed from other architectures.
+
+	* process.c (sys_execve) [LINUX]: Make setting TCB_WAITEXECVE flag
+	conditional on [TCB_WAITEXECVE] instead of list of processors.
+
+	* util.c (restore_arg0): Evaluate args in no-op defns.
+
+	* util.c [S390 || S390X] (arg0_offset, arg1_offset): Fix definitions
+	for clone call on S390.  From Michael Holzheu <holzheu@de.ibm.com>.
+
+2003-01-17  Anton Blanchard <anton@samba.org>
+
+	* util.c [LINUX] (setbpt): Handle SYS_vfork like SYS_fork.
+
+	* linux/syscall.h (SYS_socket_subcall): 256 also for POWERPC.
+
+2003-01-14  Roland McGrath  <roland@redhat.com>
+
+	* linux/powerpc/errnoent.h: Add missing errnos.
+	* linux/powerpc/ioctlent.h: Update ioctl values.
+	From Anton Blanchard <anton@samba.org>.
+
+	* io.c [LINUX] (sys_pread, sys_pwrite): Fix last change.
+	From Anton Blanchard <anton@samba.org>.
+
+	* linux/hppa/syscallent.h: Use sys_getdents64, sys_truncate64,
+	sys_ftruncate64, instead of printargs, for those syscalls.
+	* linux/mips/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+	* linux/s390/syscallent.h: Likewise.
+	* linux/sparc/syscallent.h: Likewise.
+
+	* linux/syscall.h (SYS_socket_subcall): Only 256 for S390, S390X.
+	All others at the moment use linux/syscallent.h, where it's 300.
+
+	* strace.1: Update bug reporting info.
+
+	* resource.c [LINUX] (quotacmds): Grok new command encodings.
+	From Nathan Scott <nathans@debian.org>.
+
+	* configure.ac, NEWS: Version 4.4.92.
+	* strace.spec, debian/changelog: 4.4.92-1.
+
+	* configure.ac: Match powerpc* (includes powerpc64), and don't match
+	ppc (never comes out of config.sub).
+
+	* process.c (sys_ptrace): Use #lx format for address argument.
+	[POWERPC]: Use sizeof(unsigned long) in place of 4 for multipliers.
+	* process.c [POWERPC]: Likewise.
+	* signal.c (sys_sigreturn) [POWERPC]: Likewise.
+	* syscall.c (get_scno) [POWERPC]: Likewise.
+	* util.c [POWERPC]: Likewise.
+	(printnum): Use long for NUM.
+	From Anton Blanchard <anton@samba.org>.
+
+	* defs.h (ALIGN64): Fix defn for PPC, same as FreeBSD one.
+
+	* util.c [LINUX] (restore_arg0, restore_arg1): New macros, defined
+	appropriately via set_arg0 or no-ops for each architecture.
+	(clearbpt): Use those instead of set_arg0 and set_arg1.
+
+	* defs.h [_LARGEFILE64_SOURCE] (_LFS64_LARGEFILE): Define it.
+	* linux/syscallent.h: Use sys_getdents64, sys_truncate64,
+	sys_ftruncate64, instead of printargs, for those syscalls.
+
+	* process.c: Use <linux/ptrace.h> regardless of <sys/reg.h>.
+	(sys_ptrace): Use printxval.
+	(ptrace_cmds): Make PTRACE_GETREGS et al conditional on #ifdef PTRACE_*
+	instead of only #ifdef SUNOS4.  Add PTRACE_[GS]ETFPXREGS.
+
+	* ipc.c (PRINTCTL): New macro.  #ifdef IPC_64, factor out the flag and
+	print it before using printxval.
+	(sys_msgctl, sys_semctl, sys_shmctl): Use it.
+
+2003-01-13  Roland McGrath  <roland@redhat.com>
+
+	* config.guess: Update from ftp://ftp.gnu.org/pub/gnu/config/,
+	timestamp 2003-01-10.
+	* config.sub: Likewise, timestamp 2003-01-03.
+	* install-sh: Update from Automake 1.7.2.
+
+	* linux/powerpc/signalent.h: Add SIGRTMIN.
+	From Anton Blanchard <anton@samba.org>.
+
+	* linux/powerpc/syscallent.h: Add missing system calls.
+	Decode more system calls, we were just printargs for many things.
+	Remove some x86-specific system calls.
+	Remove two syscalls between the socket and ipc syscalls,
+	it was resulting in all IPC syscalls being off by two.
+
+	* ioctl.c (ioctl_decode) [POWERPC]: Decode term ioctls like Alpha.
+	From Anton Blanchard <anton@samba.org>.
+
+	* defs.h [POWERPC] (UESP, EIP, EAX, ORIG_EAX): Remove this cruft.
+	[LINUX && POWERPC && !__powerpc64__] (ALIGN64): New macro.
+	* io.c (sys_pread, sys_pwrite): Use ALIGN64.
+	From Anton Blanchard <anton@samba.org>.
+
+	* term.c [LINUX]: Get kernel definition of struct termios.
+	From Anton Blanchard <anton@samba.org>.
+
+	* linux/ioctlent.sh: Look in sound/ directory too.
+	From Anton Blanchard <anton@samba.org>.
+
+	* desc.c (printflock64): Fix ADDR argument type.
+	From Anton Blanchard <anton@samba.org>.
+
+	* strace.c [! HAVE_STRSIGNAL]: Clean up #ifdefs on decls for
+	sys_siglist and _sys_siglist.
+	Reported by John Hughes <john@Calva.COM>.
+
+	* net.c: HAVE_OPTHDR -> HAVE_STRUCT_OPTHDR
+	Reported by John Hughes <john@Calva.COM>.
+
+	* linux/syscall.h [ARM] (SYS_socket_subcall): Set to 300.
+
+2003-01-10  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, NEWS: Version 4.4.91.
+	* strace.spec, debian/changelog: 4.4.91-1
+
+	* util.c [LINUX && X86_64] (arg0_offset, arg1_offset): Use correct
+	values for x86-64, conditional on current_personality.
+
+	* strace.c (droptcb): Clear flags word before calling rebuild_pollv.
+
+	* configure.ac: Check struct T_conn_res for QUEUE_ptr or ACCEPTOR_id.
+	* stream.c (print_transport_message): Use #ifdefs for those members.
+
+	* strace.c (rebuild_pollv): Fix typo: struct poll -> struct pollfd.
+
+	* configure.ac: Fix siginfo_t/sig_atomic_t checks.
+	Use prerequisite #include <netinet/in.h> for netinet/*.h checks.
+
+	* strace.c (pfd2tcb): Fix for new tcbtab type.
+	(rebuild_pollv): Likewise.
+	(detach): Put variables used under [LINUX] inside #ifdef.
+
+	* process.c (change_syscall) [POWERPC]: Add missing return.
+	* util.c [POWERPC] (arg0_offset): Set to 4*PT_R3, not 4*PT_ORIG_R3.
+
+	* strace.spec: New file.
+	* debian/changelog: 4.4.90-1
+	* debian/rules (binary-arch): Depend on build.
+	(clean): Don't try to run Makefile.in.
+	* debian/control (Standards-Version): Now 3.5.8.
+
+	* configure.ac: Diddle CFLAGS after AC_PROG_CC, not before.
+
+2003-01-09  Roland McGrath  <roland@redhat.com>
+
+	* syscall.c (force_result) [S390 || S390X]: Fix typo.
+
+	* debian/control: Update Maintainer: field.
+
+2003-01-08  Roland McGrath  <roland@redhat.com>
+
+	* NEWS: Update for 4.4.90 test release.
+
+	Support for new Linux 2.5 thread features.
+	* defs.h [LINUX]: Define __NR_exit_group if not defined.
+	(struct tcb): New members nclone_threads, nclone_detached,
+	and nclone_waiting.
+	(TCB_CLONE_DETACHED, TCB_CLONE_THREAD, TCB_GROUP_EXITING): New macros.
+	(waiting_parent): Macro removed.
+	(pid2tcb): Declare it.
+	* process.c (internal_clone) [TCB_CLONE_THREAD]: Reparent the new
+	child to our parent if we are a CLONE_THREAD child ourselves.
+	Maintain TCB_CLONE_THREAD and TCB_CLONE_DETACHED flags and counts.
+	(internal_wait) [TCB_CLONE_THREAD]: Factor out detached children when
+	determining if we have any.  If TCB_CLONE_THREAD is set, check
+	parent's children instead of our own, and bump nclone_waiting count.
+	(internal_exit) [__NR_exit_group]: Set the TCB_GROUP_EXITING flag if
+	the syscall was exit_group.
+	* syscall.c (internal_syscall): Use internal_exit for exit_group.
+	* strace.c (pid2tcb): No longer static.
+	(alloctcb) [TCB_CLONE_THREAD]: Initialize new fields.
+	(droptcb) [TCB_CLONE_THREAD]: Maintain new fields.
+	If we have thread children, set TCB_EXITING and don't clear the TCB.
+	(resume) [TCB_CLONE_THREAD]: Decrement parent's nclone_waiting.
+	(detach) [TCB_CLONE_THREAD]: When calling resume, check all thread
+	children of our parent that might be waiting for us too.
+	[TCB_GROUP_EXITING] (handle_group_exit): New function.
+	(trace) [TCB_GROUP_EXITING]: Use that in place of detach or droptcb.
+
+	Revamp -f support for Linux.
+	* util.c [LINUX] (setbpt, clearbpt): New implementations that tweak
+	the system call to be clone with CLONE_PTRACE set.  Various new static
+	helper functions.
+	* process.c (internal_clone): Define also #ifdef SYS_clone2.
+	Initialize TCPCHILD->parent field.
+	[CLONE_PTRACE]: Don't do PTRACE_ATTACH here, because it's preattached.
+	Check in case the new child is in the tcb already.
+	(internal_fork) [LINUX]: Just call internal_clone.
+	* strace.c (trace) [LINUX]: Under -f/-F, grok an unknown pid
+	reporting to wait, put it in the TCB with TCB_ATTACHED|TCB_SUSPENDED.
+
+	* linux/x86_64/syscallent1.h (sys_oldlstat): #define as printargs.
+
+	* file.c [LINUX]: #undef st_[amc]time in case they are macros.
+
+	* Makefile.am (AM_CFLAGS): New variable, define to $(WARNFLAGS).
+
+	* Makefile.am (EXTRA_DIST): Remove debian/postinst and debian/prerm.
+
+2003-01-09  Wichert Akkerman  <wichert@deephackmode.org>
+
+	* debian/postinst, debian/prerm: removed, /usr/doc symlink is no
+	longer used
+	* debian/rules: no longer install postinst and prerm
+	* debian/control: do not end summary with full stop (lintian)
+
+2002-12-30  Roland McGrath  <roland@redhat.com>
+
+	* Makefile.am (bin_SCRIPTS): New variable, list strace-graph.
+	(EXTRA_DIST): Add missing files.
+
+	* configure.ac: Fix asm/sigcontext.h check to include prerequisite.
+
+	* syscall.c (qualify_one): New function.
+	(qual_options): Replace lookup field with qualify, update initializer.
+	(qualify): Update caller.
+	(qual_signal, qual_fault, qual_desc): Rewritten from lookup_*.
+	(qual_syscall): Rewritten lookup_syscall, match name more than once.
+	Fixes RH#70579, bites IA64 -efoo when foo exists on IA32.
+
+	* version.c (version): Make const, bump to 4.4.90.
+	* strace.c: Update decl.
+
+	* Makefile.am [LINUX && X86_64]: Remove cruft.
+	* linux/x86_64/errnoent1.h: New file.
+	* linux/x86_64/ioctlent1.h: New file.
+	* linux/x86_64/signalent1.h: New file.
+	* linux/x86_64/syscallent1.h: New file.
+	* linux/x86_64/i386-headers.diff: File removed.
+	* linux/x86_64/makeheaders.sh: File removed.
+	* linux/x86_64/Makefile.in: File removed.
+
+	* linux/syscallent.h [X86_64]: Disable sanity checks, subcall stuff is
+	already broken for 32-bit personality on x86-64.
+
+2002-12-29  Roland McGrath  <roland@redhat.com>
+
+	* configure.ac, Makefile.am: Punt subdirs, handle everything here.
+	* linux/Makefile.am: File removed.
+	* freebsd/Makefile.am: File removed.
+	* sunos4/Makefile.in: File removed.
+	* svr4/Makefile.in: File removed.
+
+	* linux/alpha/Makefile.in: File removed.
+	* linux/hppa/Makefile.in: File removed.
+	* linux/ia64/Makefile.in: File removed.
+	* linux/powerpc/Makefile.in: File removed.
+	* linux/s390/Makefile.in: File removed.
+	* linux/s390x/Makefile.in: File removed.
+
+2002-12-26  Roland McGrath  <roland@redhat.com>
+
+	* syscallent.sh: Grok three flavors of #define line, uniquify.
+	* linux/hppa/syscallent.sh: File removed.
+	* linux/powerpc/syscallent.sh: File removed.
+
+	* linux/Makefile.am: New file.
+	* linux/Makefile.in: File removed.
+	* freebsd/Makefile.am: New file.
+	* freebsd/i386/Makefile.am: New file.
+	* freebsd/i386/Makefile.in: File removed.
+
+2002-12-22  Roland McGrath  <roland@redhat.com>
+
+	Update to Autoconf 2.57, and Automakify with version 1.7.
+	* Makefile.am: New file.
+	* Makefile.in: File removed.
+	* configure.in: Moved to ...
+	* configure.ac: ... here.  Update for Autoconf 2.5x and Automake.
+	* aclocal.m4: Moved to ...
+	* acinclude.m4: ... here.  Update for Autoconf 2.5x.
+	* acconfig.h: File removed.
+	* AUTHORS: New file, makes automake happy.
+	* autogen.sh: File removed.
+	* README-CVS: Update to recommend autoreconf instead.
+	* file.c: HAVE_ST_* -> HAVE_STRUCT_STAT_ST_*.
+	* net.c: HAVE_SIN6_SCOPE_ID -> HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID,
+	HAVE_MSG_CONTROL -> HAVE_STRUCT_MSGHDR_MSG_CONTROL.
+	* strace.c: *_DECLARED -> HAVE_DECL_*
+	* stream.c: HAVE_* -> HAVE_STRUCT_*
+
+	* linux/Makefile.in (ioctldefs.h ioctls.h): Use $(SHELL) instead of
+	sh, and use $(srcdir) to find the script.
+	* linux/powerpc/Makefile.in (ioctlent.raw): Find ioctlent.sh in ../.
+	(ioctlsort.o): Use ../ioctlsort.c, not ../../ioctlsort.c.
+	* linux/x86_64/Makefile.in (headers): Renamed to all.
+	* linux/alpha/Makefile.in: Add empty install target.
+	* linux/x86_64/Makefile.in: Likewise.
+	* linux/powerpc/Makefile.in: Likewise.
+	* linux/Makefile.in: Likewise.
+
+2002-12-26  Roland McGrath  <roland@redhat.com>
+
+	* defs.h [LINUX && MIPS] (MAX_QUALS): Set to 5000, not 4999.
+	From Daniel Jacobowitz <drow@false.org>.
+
+2002-12-21  Roland McGrath  <roland@redhat.com>
+
+	* linux/syscallent.h: Add some new 2.5 syscall names.
+	Now clone takes 5 args.
+	* process.c [LINUX] (clone_flags): Update with 2.5 flag bits.
+	[LINUX] (sys_clone): Print new args.
+	* mem.c (print_ldt_entry): Make global.
+
+	* linux/syscall.h [I386 || IA64] (SYS_socket_subcall): Bump to 300 for
+	safety, since up to 260 are already used in 2.5 kernels.
+	* linux/syscallent.h: Update the table.
+	* linux/ia64/syscallent.h: Likewise.
+
+	* syscall.c (force_result): New function.
+	* process.c (internal_wait): Handle ECHILD exit from wait call with
+	WNOHANG flag set; force the return value to 0 in the inferior when it
+	has live children we are tracing.
+	* NEWS: Mention the bug fix.
+
+2002-12-17  Roland McGrath  <roland@redhat.com>
+
+	* linux/ia64/syscallent.h: Remove placeholders 275-298 to catch up
+	with linux/syscallent.h additions.
+
+	* strace.c (tcbtab): Make this a pointer to pointers, not an array.
+	(tcbtabsize): New variable.
+	(main): Initialize them using dynamic allocation.
+	(alloctcb, main): Use tcbtabsize in place of MAX_PROCS; indirect.
+	(pid2tcb, cleanup): Likewise.
+	[USE_PROCFS] (pollv): Make this a pointer, not an array; make static.
+	(rebuild_pollv): Dynamically allocate the vector.
+	* defs.h (tcbtab): Update decls.
+	(MAX_PROCS): Macro removed, no more static limit on this.
+	* process.c (fork_tcb): New function.
+	(internal_clone, internal_fork): Use it instead of checking nprocs.
+
+	* strace.c (detach) [LINUX]: Use __WALL (or a second try with __WCLONE)
+	in wait after sending SIGSTOP.
+
+2002-12-16  Roland McGrath  <roland@redhat.com>
+
+	* signal.c (sprintsigmask): Increase static buffer size to account for
+	worst possible case.  Reported by Daniel Jacobowitz <drow@false.org>.
+
+	* process.c [LINUX] (wait4_options): Fix __WCLONE value.  Add
+	__WNOTHREAD and __WALL.
+
+	* strace.c (trace) [LINUX]: Only check errno if wait4 actually fails,
+	so we don't repeat a wait and thus drop a status.  Fixes RH#62591.
+
+2002-12-15  Roland McGrath  <roland@redhat.com>
+
+	* process.c (setarg) [POWERPC]: Support it.
+
+	* util.c [POWERPC] (LOOP): Fix value, now 0x48000000 (0: b 0b).
+	Old value was bogus, not even a proper instruction.
+	From Guy M. Streeter <streeter@redhat.com>.
+
+	* strace.c (main) [! USE_PROCFS]: Always reset SIGCHLD to SIG_DFL.
+
+	* configure.in: Don't check for putpmsg.
+	* stream.c (sys_getpmsg, sys_putpmsg): Make these conditional on
+	#ifdef SYS_*, rather than on HAVE_PUTPMSG.
+
+	* aclocal.m4 (AC_STAT64): Include <linux/types.h> before <asm/stat.h>
+	in test.  Test our own #ifdef LINUX rather than predefined `linux'.
+
+	* linux/powerpc/syscallent.h: Use sys_llseek for _llseek.
+	* linux/sparc/syscallent.h: Likewise.
+	* linux/hppa/syscallent.h: Likewise.
+
+	* syscall.c (syscall_enter) [LINUX && POWERPC]: Define PT_ORIG_R3 if
+	not defined, since <asm/ptrace.h> defines it only #ifdef __KERNEL__.
+	* process.c: Likewise.
+
+	* desc.c (sys_osf_select): Add missing return type.
+
+	* syscall.c (trace_syscall): Use strerror, not sys_errlist/sys_nerr.
+
+	* linux/ia64/syscallent.h: Remove macros for sys_delete_module,
+	sys_nanosleep, both already in linux/dummy.h.
+
+	* syscall.c (get_scno): Move static `currpers' inside #ifdef X86_64.
+	(trace_syscall): Fix return without value.
+
+	* linux/syscallent.h: Update table with names of new syscalls
+	io_setup, io_destroy, io_getvents, io_submit, io_cancel.
+	* linux/ia64/syscallent.h: Likewise.
+	* linux/powerpc/syscallent.h: Likewise.
+
+	* signal.c [LINUX && I386]: Provide SA_RESTORER constant if not
+	defined.  If the bit is set, print the sa_restorer field of sigaction.
+
+	* mem.c: Add sys_{get,set}_thread_area.
+	* linux/syscall.h: Declare them.
+	* linux/syscallent.h: Update the table for these.
+	* linux/dummy.h (sys_modify_ldt): Define only #ifndef I386.
+	(sys_get_thread_area, sys_set_thread_area): New macros #ifndef I386.
+
+	* configure.in: Check for linux/xattr.h and linux/futex.h headers.
+	* linux/syscall.h: Add sys_* decls for new syscalls getpmsg, putpmsg,
+	readahead, sendfile64, setxattr, fsetxattr, getxattr, fgetxattr, int
+	listxattr, flistxattr, removexattr, fremovexattr, sched_setaffinity,
+	sched_getaffinity, futex.
+	* linux/syscallent.h: Update the table.
+	* io.c: Add sys_sendfile64.
+	* file.c: Add sys_readahead, sys_*xattr.
+	* process.c: Add sys_futex, sys_*affinity.
+
+	* linux/syscall.h (SYS_socket_subcall): Define to 256 on all machines.
+	(SYS_ipc_subcall): Always SYS_socket_subcall + SYS_socket_nsubcalls.
+	* linux/syscallent.h: Update the table for socket and ipc subcalls.
+
+2002-11-09  Heiko Carstens <heiko.carstens@de.ibm.com>
+
+	Bugfix for s390/s390x:
+	* syscall.c: Fixed scno derivation for s390/s390x.
+
+2002-11-06  Michal Ludvig  <mludvig@suse.cz>
+
+	Merged patch from Steven J. Hill <sjhill@realitydiluted.com>
+	to allow the compilation of a native MIPS strace.
+
+2002-11-06  Michal Ludvig  <mludvig@suse.cz>
+
+	From Marty Leisner <leisner@rochester.rr.com>,
+	rewritten by mludvig:
+	* strace.c (not_failing_only): New.
+	(usage): Added -z switch description.
+	(main): Added -z switch parsing to not_failing_only variable.
+	* syscall.c (trace_syscall): Added not_failing_only handling.
+
+2002-10-08  Heiko Carstens <heiko.carstens@de.ibm.com>
+
+	Missing complete changelog for 2002-10-07 commit:
+	* Makefile.in: Added linux/s390, linux/s390x to ALL_SUBDIRS.
+	* acconfig.h: New define for s390x.
+	* config.sub: Added missing define for s390 and new one for s390x.
+	* configure.in: Added new define for s390x.
+	* file.c: Added missing #undef dirent64 and new defines for s390x.
+	* linux/s390: New directory.
+	* linux/s390/Makefile.in: New file.
+	* linux/s390/errnoent.h: New file.
+	* linux/s390/ioctlent.h: New file.
+	* linux/s390/signalent.h: New file.
+	* linux/s390/syscallent.h: New file.
+	* linux/s390x: New directoy.
+	* linux/s390x/Makefile.in: New file.
+	* linux/s390x/errnoent.h: New file.
+	* linux/s390x/ioctlent.h: New file.
+	* linux/s390x/signalent.h: New file.
+	* linux/s390x/syscallent.h: New file.
+	* linux/syscall.h: Added sys_mincore() prototype and added new
+	s390x defines.
+	* process.c: Added s390x defines.
+	(change_syscall): Changed handling for s390.
+	(setarg): Added missing s390/s390x code in setarg().
+	* signal.c: Added s390x define.
+	(sys_sigreturn): Bugfix in s390/s390x code (wrong number of
+	arguments to sprintsigmask()).
+	* stream.c (internal_stream_ioctl): Changed int cast to long cast,
+	since printstr() expects a long.
+	* syscall.c (decode_subcall): Changed several variables to be long
+	instead of int to match 64 bit requirements. Added s390x defines.
+	(syscall_enter): Changed upeek() call to match s390 and s390x
+	requirements.
+	* util.c: Added s390x defines.
+
+2002-10-07  Michal Ludvig  <mludvig@suse.cz>
+
+	Merged s390x port by Heiko Carstens <Heiko.Carstens@de.ibm.com>
+	and bugfixes to s390 by D.J. Barrow.
+
+2002-09-23  Michal Ludvig  <mludvig@suse.cz>
+
+	Merged x86-64 port by Andi Kleen <ak@suse.de>
+	and Michal Ludvig <mludvig@suse.cz>
+	* Makefile.in: New target 'headers'. Failure ignored.
+	* acconfig.h: New defines for x86-64.
+	* configure.in: Ditto.
+	* defs.h: Ditto.
+	* file.c: Ditto.
+	* signal.c: Ditto.
+	* process.c: Added support for x86-64.
+	* util.c: Ditto.
+	* syscall.c: Ditto + added automatic personality switching.
+	* linux/syscall.h: Ditto.
+	* linux/x86_64: New directory.
+	* linux/x86_64/Makefile.in: New file.
+	* linux/x86_64/gentab.pl: Ditto.
+	* linux/x86_64/i386-headers.diff: Ditto.
+	* linux/x86_64/makeheaders.sh: Ditto.
+	* linux/x86_64/syscallent.h: Ditto.
+	* mem.c (print_mmap): Always print arg[4] as int.
+
+2002-09-23  Michal Ludvig  <mludvig@suse.cz>
+
+	* configure.in: Fix regular expressions.
+	* linux/syscall.h: Added missing braces in prototype of
+	sys_getdents64().
+	* file.c: Use '#ifdef LINUX' instead of '#ifdef linux'.
+	(struct fileflags): Made extern to inhibit compiation warnings.
+	(sys_getdents64): Merged LINUX and SVR4 part.
+	* syscall.c (get_scno): Split multiline string into two distinct
+	strings.
+
+2002-05-24  John Hughes <john@calva.com>
+
+	* stream.h, net.h: Avoid possible infinite loop caused by
+	unsigned arithmetic in preceeding change.
+
+2002-05-23  John Hughes <john@calva.com>
+
+	* acconfig.h: Add HAVE_OPTHDR and HAVE_T_OPTHDR defines.
+
+	* aclocal.m4: Add tests for struct opthdr in sys/socket.h and
+	struct t_opthdr in sys/tiuser.h, define HAVE_OPTHDR and HAVE_T_OPTHDR
+	if found.
+
+	* configure.in: use tests for struct opthdr and struct t_opthdr.
+
+	* defs.h: add new function print_sock_optmgmt.
+
+	* io.c: add hack that lets ioctl decode functions set auxilliary
+	string return.
+
+	* stream.c: better decoding for timod ioctls.
+
+	* net.c: add function print_sock_optmgmt, used by timod ioctl
+	decoding functions in stream.c.
+
+2002-05-23  John Hughes <john@calva.com>
+
+	* acconfig.h: Make autoheader happy about Linux/SuperH
+
+2002-05-23  John Hughes <john@calva.com>
+
+	* strace.c: Get rid of warning if not using POLL_HACK
+
+2002-05-22  John Hughes <john@calva.com>
+
+	* net.c: Simplify {get,set}sockopt, decode SO_LINGER, cope with
+	options that are not just ints, cope with systems that don't
+	#define SOL_TCP and so on.
+
+2002-05-21  John Hughes <john@calva.com>
+
+	* strace.c: Fix warning if POLL_HACK is used.
+
+2002-05-17  John Hughes <john@calva.com>
+
+	* svr4/ioctlent.sh: Some defines on UW come with too many spaces.
+
+2002-05-17  John Hughes <john@calva.com>
+
+	* svr4/ioctlent.sh: Cope with #defines wrapped in #ifdefs.
+
+2002-05-17  John Hughes <john@calva.com>
+
+	* stream.c: tidy up output a little.
+
+2002-05-17  John Hughes <john@calva.com>
+
+	* process.c, svr4/dummy.h, svr4/syscall.h: decode arguments
+	to procpriv syscall.
+
+2002-05-01  Wichert Akkerman <wichert@deephackmode.org>
+
+	* configure.in, defs.h, process.c, sock.c, syscall.c, util.c: merge
+	  patch from Greg Banks <gbanks@pocketpenguins.com> for Linux/SuperH
+	  support
+
+2002-04-01  Wichert Akkerman <wichert@deephackmode.org>
+
+	* strace.c: close tcp->outf in droptcb()
+
+2002-04-01  Wichert Akkerman <wichert@deephackmode.org>
+
+	* net.c: decode packet options
+
+2002-03-31  Wichert Akkerman <wichert@deephackmode.org>
+
+	* linux/{alpha,hppa,ia64,mips,powerpc,sparc}/syscallent.h: regenerated
+
+2002-03-31  Wichert Akkerman <wichert@deephackmode.org>
+
+	* debian/*: added
+	* linux/syscallent.h: fix typo and add the reserved stream syscalls
+	* defs.h, file.c, io.c: fix signed/unsigned issues
+	* syscall.c: check for negative u_errors
+	* cvsbuild: renamed to autogen.sh
+
+2001-12-17  Wichert Akkerman <wakkerma@debian.org>
+
+	* net.c: add new TCP socket options
+
+2001-10-26  John Hughes <john@calva.com>
+
+	* svr4/ioctlent.sh: Cope with #define lines containing
+	comments that terminate on subsequent lines.  Used to
+	comment out subsequent ioctls!
+
+2001-10-25  Wichert Akkerman <wakkerma@debian.org>
+
+	* linux/ioctlent.h: regenerated using current scripts so
+	  term ioctls are included
+
+2001-10-19  John Hughes  <john@Calva.COM>
+
+	* strace.c(proc_open): On SVR4 only trace the syscalls,
+	signals and faults we care about.
+
+2001-10-18  John Hughes  <john@Calva.COM>
+
+	* acconfig.h: Add HAS_SIGINFO_T.
+	* aclocal.m4: add check for siginfo_t in signal.h.
+	* configure.in: use check for siginfo_t.
+	* defs.h: if HAVE_SIGINFO_T the declare printsiginfo.  On SVR4
+	  allow access to siginfo when signal recieved.
+	* process.c: Remove SVR4 only version of printsiginfo.
+	* signal.c: merge SVR4 and LINUX versions of printsiginfo.
+	* strace.c: on SVR4 print siginfo when signal recieved.
+
+2001-10-18  John Hughes  <john@Calva.COM>
+
+	* system.c(sys_ssisys): handle return values for ssisys
+
+2001-10-18  John Hughes  <john@Calva.COM>
+
+	* signal.c: handle sigwait
+	* svr4/dummy.c: Move sigwait to done
+	* svr4/syscall.h: handle sigwait
+
+2001-10-16  John Hughes  <john@Calva.COM>
+
+	* system.c(sys_ssisys): decode some args for ssisys.
+
+2001-10-16  John Hughes  <john@Calva.COM>
+
+	* mem.c: MS_SYNC is zero, so must be first in xlat list.
+
+	* svr4/dummy.h: memcntl is much like mctl.
+
+2001-10-16  John Hughes  <john@Calva.COM>
+
+	* util.c (umovestr): UnixWare (svr4?) returns 0 when trying
+	to read unmapped page.  Make it possible to strace ksh.
+
+2001-10-03  David Mosberger  <davidm@hpl.hp.com>
+
+	* process.c (internal_clone): Avoid race condition by clearing
+	breakpoint after attaching to child.
+
+2001-10-02  David Mosberger  <davidm@hpl.hp.com>
+
+	* linux/ia64/syscallent.h: Define ia32 syscall numbers (originally
+	by Don Dugger, with my refinements).
+
+	* linux/ia64/ioctlent.h: Regenerate and manually merge conflicting
+	ioctls (TCGETS & SNDCTL_TMR_TIMEBASE, etc.).
+
+	* linux/ia64/Makefile.in (ioctldefs.h ioctls.h): Update for
+	new ioctlent.h generation scheme.
+
+	* linux/syscall.h (sys_clone2): Declare.
+	[IA64] Define ia32 socket, ipc, and extra syscall numbers.
+
+	* linux/ioctlent.sh (regexp): Also handle <asm/ioctls.h> so we
+	don't miss the tty ioctls (unfortunately, some of the sound timer
+	ioctls are in conflict with them!).
+
+	* util.c (setbpt) [IA64]: Add ia32 support (by Don Dugger).
+	(clrbpt) [IA64]: Ditto.
+
+	* syscall.c (internal_syscall): Handle SYS_clone2, SYS32_wait4,
+	and SYS32_exit.
+	(get_scno): Get ia32 syscall number from r1 (orig eax) instead of
+	r8 (eax).  Handle TCB_WAITEXECVE.
+	(syscall_fixup): Handle ia64.
+	(syscall_enter): Fix argument fetching for ia64.
+
+	* strace.c [IA64 && LINUX]: Include <asm/ptrace_offsets.h>.
+	(trace) [PT_GETSIGINFO]: Print signal address and pc if possible.
+
+	* process.c (tcp): New function.
+	(change_syscall): Add support for ia64 linux.
+	(sys_execve): Turn on TCB_WAITEXECVE for ia64 linux.
+
+	* desc.c (getlk): Cast l_len to "long long" to avoid warnings when
+	type is narrower.
+	* resource.c (sprintrlim64): Ditto.
+
+	* defs.h (TCB_WAITEXECVE) [IA64]: Define.
+	[IA64]: Declare "ia32" variable.
+
+	* bjm.c: Do not include <linux/module.h>.  It's not safe to include
+	kernel headers.  Declare the necessary constants and structures
+	directly instead.
+
+2001-10-01  David Mosberger  <davidm@hpl.hp.com>
+
+	* signal.c (parse_sigset_t): New function.
+	(sigishandled): Fix off-by-one bug by using parse_sigset_t() and
+	avoiding relying on internal layout of sigset_t datastructure.
+
+2001-04-26  David Mosberger  <davidm@hpl.hp.com>
+
+	* linux/ia64/syscallent.h: Add getunwind().
+
+2001-04-11  David Mosberger  <davidm@hpl.hp.com>
+
+	* syscall.c (syscall_enter): Use PT_RBS_END instead of deprecated
+	PT_AR_BSP.  Pick up arguments starting with out0, which is not
+	always the same as r32 (e.g., consider inlined syscalls).
+
+2001-09-28   John Hughes <john@Calva.COM>
+
+  * process.c: FreeBSD-CURRENT no longer has PT_READ_U, and anyway we
+    were showing it as PT_WRITE_U!  Fix from Maxime Henrion.
+
+2001-09-18   John Hughes <john@Calva.COM>
+
+  * net.c: fix display of sockaddr structures, sometimes too many "}",
+    sometimes too few.  Fix suggested by Richard Kettlewell.
+
+2001-08-19   Wichert Akkerman <wakkerma@debian.org>
+
+  * signal.c: do not include asm/sigcontext.h on IA64 since it gets
+    the struct from bits/sigcontext.h already which signal.h includes.
+
+2001-08-03   Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/ioctlent.sh: change regexps so we catch sound ioctls as well in
+    Linux
+  * linux/Makefile.in: fix a few things so the ioctl list is generated
+    properly
+  * ioctl.c: remember to shift ioctl masks as well
+
+2001-08-03   Wichert Akkerman <wakkerma@debian.org>
+
+  * Linux/**/syscallent.h: synchronize section for fcntl and use sys_fcntl
+    for sys_fcntl as well
+
+2001-08-03   Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/hppa/syscallent.h: updated from Matthew Wilcox
+
+2001-08-03   Wichert Akkerman <wakkerma@debian.org>
+
+  * process.c: seems Linux/IA64 changed register names on us, switch to
+    using new names.
+
+2001-08-03   Wichert Akkerman <wakkerma@debian.org>
+
+  * strace.c: set CLOEXEC  flag for outputfile
+
+2001-08-03   Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/sparc/syscall.h, linux/sparc/syscallent.h: add some LFS calls
+
+2001-07-23  Wichert Akkerman <wakkerma@debian.org>
+
+  * configure.in: Support cross-compiling between architectures
+
+2001-07-13  Wichert Akkerman <wakkerma@debian.org>
+
+  * configure.in: add S390 to architecture list
+
+2001-07-10  John Hughes <john@Calva.COM>
+
+  * TODO, defs.h, io.h, net.c, strace.c, syscall.c, util.c: Merge fixes
+    from Richard Kettlewell <rkettlewell@zeus.com> which add I/O dumping
+    of args to readv/writev.  Also gets rid of redundant printiovec
+    routine from net.c (duplicate of tprint_iov in util.c).
+
+2001-07-02  Wichert Akkerman <wakkerma@debian.org>
+
+  * config.{guess,sub}: updated
+
+2001-05-15  John Hughes <john@Calva.COM>
+
+  * signal.c: pass a pointer to sigmask to printsigmask from printcontext,
+    it was just passing the sigmask (ucp->uc_sigmask).
+
+2001-05-15  John Hughes <john@Calva.COM>
+
+  * util.c: Don't run off the end of valid memory in umovestr when
+    USE_PROCFS.  Important for FREEBSD systems (which seem to have an
+    unmapped page just after the args/env area).
+
+2001-04-18  John Hughes <john@Calva.COM>
+
+  * configure.in: test for sys/nscsys.h, the non-stop clusters includes.
+  * process.c: handle rfork{1,all} and rexecve calls on non-stop clusters.
+  * syscall.c: treat rfork{1,all} and fork{1,all} as fork like calls.
+    Treat rexecve as an exec.
+  * system.c: decode arguments to ssisys call on nsc systems.
+  * svr4/dummy.h, svr4/syscall.h: now we handle rfork{1,all}, ssisys and
+    rexecve calls.
+
+2001-04-12  Wichert Akkerman <wakkerma@debian.org>
+
+  * process.c: fix cast for powerpc code
+  * linux/powerpc/syscallent.h: update syscall list
+  * README: fix address for the strace mailinglist
+  * signal.c: switch to using /proc/<pid>/status on Linux so we can get
+    the realtime signals as well
+
+2001-04-10  Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patches from Maciej W. Rozycki:
+    + util.c: add code to print PC for MIPS
+    + linux/mips/syscallent.h: updated
+    + system.c: formating fixes for sys_sysmips
+    + configure.in: test for yet more headers
+    + stream.c: use configure-headertests instead of relying on OS hints
+
+2001-04-07  Wichert Akkerman <wakkerma@debian.org>
+
+  * NEWS: start 4.3.1 items
+  * version.c: updated to say 4.3.1 (was still 4.2, oops!)
+
+2001-04-07  Wichert Akkerman <wakkerma@debian.org>
+
+  * configure.in: test for asm/sysmips.h and linux/utsname.h
+  * linux/syscall.h: fix a typo for sys_sysmips
+  * system.c: include asm/sysmips.h and linux/utsname.h if they exist,
+    fix typo
+
+2001-03-31  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/mips/ioctlent.h: updated using new Linux ioctl setup
+
+2001-03-31  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/ia64/ioctlent.h: regenerated
+
+2001-03-31  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/{alpha,ia64,powerpc}/ioctlent.sh: removed, all archs use the
+    general Linux ioctlent.sh
+
+2001-03-31  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/ioctlent.sh: add dir variable for location of kernel headers
+
+2001-03-29  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/ia64/ioctlent.h: updated using new Linux ioctl setup
+
+2001-03-29  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/powerpc/ioctlent.h: updated using new Linux ioctl setup
+
+2001-03-29  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/hppa/ioctlent.h: updated using new Linux ioctl setup
+
+2001-03-29  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/alpha/ioctlent.h: updated using new Linux ioctl setup
+
+2001-03-28  Wichert Akkerman <wakkerma@debian.org>
+
+  * configure.in: use sparc* so we can compile on sparc64 as well
+  * process.c, syscall.c: work around double define of fpq, fq and fpu
+    structs on Linux/sparc, and use regs instead of pt_regs
+  * don't use asm/sigcontext.h on Linux/sparc
+
+2001-03-28  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/sparc/ioctlent.h: updated using new Linux ioctl setup
+
+2001-03-28  Wichert Akkerman <wakkerma@debian.org>
+
+  * strace.c: use __WALL as wait4 flag if it exists so we can properly
+    trace threaded programs
+
+2001-03-27  John Hughes <john@Calva.COM>
+
+  * aclocal.m4: add check for endianness of long long.
+  * acconfig.h: add #define for LITTLE_ENDIAN_LONG_LONG.
+  * configure.in: check for endianness of long long.
+  * defs.h: change LONG_LONG macro to work with either endianness of
+    long long.
+
+2001-03-27  John Hughes <john@Calva.COM>
+
+  * net.c: Make compilable by SCO UDK compiler (doesn't like empty
+    initialisation list for array).
+
+2001-03-27  John Hughes <john@Calva.COM>
+
+  * svr4/syscallent.h: ntp_adjtime entry was duplicated on Solaris
+    systems - bad merge of Harald Boehme's patch by me.
+
+2001-03-27  Wichert Akkerman <wakkerma@debian.org>
+
+  * lots of files: add Linux/hppa support
+
+2001-03-19  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/mips/syscallent.h: we can't have -1 nargs, change to 0
+  * linux/syscallent.h: not that syscalls 220 and 221 are used now
+  * config.guess: updated
+
+2001-03-17  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/ioclsort.c: new file
+  * linux/ioctlent.sh: complete rewrite to use a more sane approach to get
+    the ioctl list that doesn't involve attempting to #include all kernel
+    headers
+  * linux/.cvsignore: added ioctdefs.h and ioctls.h which are generated
+    by the new ioctlent.sh
+  * ioctl.c: only look at the number and type bits for linux, since
+    ioctlent.sh no longer supplies the others
+
+2001-03-08  John Hughes <john@Calva.COM>
+
+  * freebsd/syscalls.pl: On FreeBSD we must cope with COMPATibility syscalls,
+    pretend they have names ending with "?" so that -e trace=stat (for
+    example) will work.
+  * freebsd/i386/syscallent.h: add ? to compatability syscalls.
+  * freebsd/i386/syscall.h: consistency.
+
+2001-03-08  John Hughes <john@Calva.COM>
+
+  * acconfig.h: add new ST_xxx defines.
+  * aclocal.m4: macros to check for more fields in struct stat.
+  * configure.in: use new macros to check for fields in struct stat.
+  * file.c: use new defines to replace #ifdef FREEBSD by #if HAVE_ST_xxx.
+
+2001-03-08  John Hughes <john@Calva.COM>
+
+  * defs.h: rename wimpy get64 as powerful new LONG_LONG
+  * file.c: use LONG_LONG
+  * io.c: use LONG_LONG
+  * mem.c use LONG_LONG
+
+2001-03-08  John Hughes <john@Calva.COM>
+
+  * acconfig.h: new #defines HAVE_LONG_LONG_OFF_T and HAVE_LONG_LONG_RLIM_T.
+  * aclocal.m4: routines to check for long long off_t and rlim_t.
+  * configure.in: check for long long off_t and rlim_t.
+  * desc.c: if HAVE_LONG_LONG_OFF_T treat flock as flock64
+  * file.c: if HAVE_LONG_LONG_OFF_T treat stat,lstat,fstat and lseek as 64
+    bit versions.
+  * io.c: if HAVE_LONG_LONG_OFF_T use 64 bit versions of pread and pwrite.
+  * mem.c: if HAVE_LONG_LONG_OFF_T use 64 bit version of mmap
+  * resource.c: if HAVE_LONG_LONG_OFF_T use 64 bit versions of getrlimit
+    and setrlimit.
+  * freebsd/syscalls.print: don't explicitly use 64 bit versions of calls,
+    now done automaticaly for us.
+  * freebsd/i386/syscall.h: ditto.
+  * freebsd/i386/syscallent.h ditto.
+
+2001-03-07  John Hughes <john@Calva.COM>
+
+  * desc.c: On FreeBSD flock structure uses 64 bit offsets.
+  * file.c: On FreeBSD use stat64 and pals instead of stat.
+  * freebsd/syscalls.print: use stat64, lstat64 and fstat64.
+  * freebsd/i386/syscall.h: ditto.
+  * freebsd/i386/syscallent.h: ditto.
+
+2001-03-07  John Hughes <john@Calva.COM>
+
+  * file.c: merge missing part of Harald Böhme's solaris patches,
+    was only declaring sys_{stat64,lstat64,fstat64} on linux!
+
+2001-03-07  John Hughes <john@Calva.COM>
+
+  * svr4/dummy.h: fix multiple define warning on non LFS64 systems.
+  * svr4/syscallent.h: pread/pwrite are TF calls.
+
+2001-03-07  John Hughes <john@Calva.COM>
+
+  * defs.h: add ALIGN64 macro to cope with FreeBSD's strange insistence
+    on alignment for off_t (64 bit) arguments.  Also simplify get64 so
+    we don't need to know endianness of long long.
+  * file.c: FreeBSD now uses 64 bit versions of lseek, truncate,
+    ftruncate, allows reduction in numvber of horrid #if's
+  * io.c: FreeBSD now uses 64 bit versions of pread, pwrite.
+  * mem.c: FreeBSD now uses 64 bit version of mmap.
+  * freebsd/syscalls.print: use 64 bit versions of various syscalls.
+  * freebsd/i386/syscall.h: use 64 bit versions of various syscalls.
+  * freebsd/i386/syscallent.h: use 64 bit versions of various syscalls.
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * file.c: Implement truncate64 and ftruncate64
+  * svr4/dummy.h: add dummies for truncate64 and ftruncate64 for non
+    LFS64 systems.
+  * svr4/syscall.h: add declarations for truncate64 and ftruncate64.
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * freebsd/syscalls.pl: fix for FreeBSD 4.1 (new optional field in
+    syscall master file).
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * syscall.c: fix for FreeBSD 4.1 (SYS_semconfig has disappeared).  Also
+    zap incorrect syscall subarg range check.
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * configure.in, defs.h, desc.c, file.c, io.c, mem.c, net.c, resource.c,
+    signal.c, syscall.c, svr4/dummy.h, svr4/syscall.h, svr4/syscallent.h:
+    merge Harald Böhme's solaris patches (_LFS64_LARGEFILE and kernel aio
+    mostly).
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * dummy.h: add unimplemented UW sycalls
+  * syscall.h: we can do settimeofday for UW, whopee!
+  * syscallent.h: fix unimplemented UW syscalls
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * aclocal.m4: look for pr_syscall in pr_lwp if we HAVE_MP_PROCFS
+  * defs.h: add PR_SYSCALL to allow use of pr_lwp.pr_syscall if it exists.
+  * syscall.c: use PR_SYSCALL instead of pr_syscall, fix up UnixWare code
+    so it doesn't try to use pr_sysarg.
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * aclocal.m4: on systems other than linux look for stat64 in sys/stat.h
+  * file.c: handle xstat version _STAT64_VER, aka stat64.
+
+2001-03-06  John Hughes <john@Calva.COM>
+
+  * net.c: make sure SOL_ options are defined before using.
+  * signal.c: declare sigset variable, only used on linux, inside #ifdef.
+
+2001-02-21  Wichert Akkerman <wakkerma@debian.org>
+
+  * net.c: fix format for printing Unix domain sockets
+
+2001-02-19  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/mips/syscallent.h: use new sys_sysmips
+  * system.c: add sys_sysmips decoding
+
+2001-02-16  Wichert Akkerman <wakkerma@debian.org>
+
+  * CREDITS: add Arkadiusz Miskiewicz <misiek@pld.org.pl> who
+    submitted the IP6 scope ID updates
+  * acconfig.h: add HAVE_SIN6_SCOPE_ID and HAVE_SIN6_SCOPE_ID_LINUX
+  * aclocal.m4: add AC_SIN6_SCOPE_ID to check if sin6_scope_id is
+    available
+  * configure.in: check for if_indextoname function and sin6_scope_id
+  * net.c: teach printsock about IP6 scope ids
+
+2001-02-16  Wichert Akkerman <wakkerma@debian.org>
+
+  * configure.in: test for netinet/tcp.h and netinet/udp.h existance
+  * net.c: include netinet/tcp.h and netinet/udp.h if they exist
+  * Makefile.in: use @mandir@ and @bindir@
+
+2000-11-26  Wichert Akkerman <wakkerma@debian.org>
+
+  *  net.c: fix formating error in sys_setsockopt
+  *  net.c: add list of socketlayers and use that for [gs]etsockopt
+
+2000-10-12  Wichert Akkerman <wakkerma@debian.org>
+
+  * time.c: use sys/timex.h so things compile with 2.2 kernels
+  * stream.c: test if MSG_* constants are #defined
+
+2000-09-03  Wichert Akkerman <wakkerma@debian.org>
+
+  * process.c: perform bpt trick for clone as well so we can get the
+    pid of the child before it starts doing something
+  * file.c: rename dirent64 struct to kernel_dirent64 so things compile
+    again with newer libcs
+  * test/clone.c: improve our testcase a bit
+  * Merge another patch from Gäel Roualland with FreeBSD updates
+
+2000-09-01  Wichert Akkerman <wakkerma@debian.org>
+
+  * lots of files: merge patch from Gaël Roualland to add
+    support for FreeBSD.
+
+2000-08-09  Wichert Akkerman <wakkerma@debian.org>
+
+  * file.c: update to reflect that st_ino suddenly became a long long
+    in the in Linux 2.4.0-test6
+
+2000-08-09  Wichert Akkerman <wakkerma@debian.org>
+
+  * test/clone.c: minor fixup
+  * Another bunch of patches from John Hughes merged:
+  * signal.c:
+    + SVR4 printcontext(): sigset_t != sigset_t*
+    + getcontext returns a value, so print on exit of syscall
+    + add UC_FP to ucontext_flags for OS writers that can't spell
+    + sys_signal(): special case SIG_{ERR,DFL,IGN}
+    + decode_subcall(): only do subcall range checking when needed
+  * bunch of UnixWare updates
+  * aclocal.m4, acconfig.h, configure.in: add test for long long type
+
+2000-07-04  Wichert Akkerman <wakkerma@debian.org>
+
+  * net.c: add SOL_PACKET and SOL_RAW socket options, update
+    SOL_IP and SOL_TCP
+
+2000-06-23  Wichert Akkerman <wakkerma@debian.org>
+
+  * strace.c: close outf before we exec a child process
+
+2000-06-09  Ulrich Drepper  <drepper@redhat.com>
+
+  * configure.in: Don't link against libnsl on Linux, it's unnecessary.
+  * defs.h (struct tcb): Make auxstr member const.
+  * file.c (fsmagic): And many more magic numbers.
+  * util.c: Don't include <linux/ptrace.h> for glibc 2.1 and up.
+
+2000-04-26  Wichert Akkerman <wakkerma@debian.org>
+
+  * defs.h: balance #if/#endif again
+  * system.c: fix return statements in sys_capget()
+  * Merge updates from Topi Miettinen <Topi.Miettinen@nic.fi>:
+    + file.c: add F_[SG]ETSIG to fcntl flags
+    + strace.c: don't setre[gu]id if not needed
+    + system.c: handle sys_reboot for Linux
+    + term.c: add baudrate constants up to B4000000
+    + linux/**/syscallent.h: note that munlockall has no arguments
+
+2000-04-25  David Mosberger  <davidm@hpl.hp.com>
+
+  * CREDITS: fix email address
+  * process.c: handle PR_[GS]ET_UNALIGN and PR_[GS]ET_KEEPCAPS
+  * signal.c: honour offset of sigconfig in sigframe structure for
+    Linux/ia64
+  * linux/ia64/syscallent.h: Add perfmonctl, pivotroot, mincore, and
+    madvise syscalls.
+  * syscall.c (syscall_enter): With Kevin's latest ptrace patches,
+    AR_BSP points to the _end_ of the active register frame, so we need
+    to adjust bsp by moving it back by the size of the active frame
+    before using it.
+
+2000-04-24  Wichert Akkerman <wakkerma@debian.org>
+
+  * process.c: add sparc support to change_syscall
+
+2000-04-22  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/mips/syscallent.h: fix some typos
+
+2000-04-14  Wichert Akkerman <wakkerma@debian.org>
+
+  * linux/mips/syscallent.h: added names for SVR4, SYSV, BSD4.3 and POSIX
+    syscalls
+
+2000-04-13  Wichert Akkerman <wakkerma@debian.org>
+
+  * defs.h: Linux/MIPS uses syscalls up to >4k, so set MAX_QUALS to
+    4999
+
+2000-04-09  Wichert Akkerman <wakkerma@debian.org>
+
+  * README-linux: updated to note that strace might not compile
+    with development kernels
+  * bjm.c: sys_query_module: check if malloc succeeds
+  * system.c: sys_cap[gs]et(): check if malloc succeeds, only malloc once
+  * linux/syscallent.h: updated for 2.3.99pre3
+  * linux/alpha/syscallent.h: updated for 2.3.99pre3, add all osf syscalls
+    even though Linux doesn't implement them
+  * syscall.c: add global variables for MIPS registers as well
+  * syscall.c: move global variables to before get_scno since that uses them
+  * util.c: oops, misspelled defined
+  * process.c: fix ptrace calls in change_syscall
+  * mem.c: decode sys_madvise
+  * Merge patch from Topi Miettinen <Topi.Miettinen@nic.fi>
+    + add support for quotactl, fdatasync, mlock, mlockall, munlockall & acct
+    + small fix for RLIMIT_* and RUSAGE_BOTH
+    + enhace support for capget and capset
+
+2000-02-19 Wichert Akkerman <wakkerma@debian.org>
+
+  * test/vfork.c: new file to test vfork traces
+  * test/.cvsignore: new file
+  * defs.h: Up maximum number of traced processed to 64
+  * strace.c: Disable some debugging code from davidm
+  * implement setarg for more architectures
+  * implement change_syscall
+
+1999-12-27  Morten Welinder  <terra@diku.dk>
+
+	* syscall.c (lookup_signal, lookup_desc): isdigit requires an
+	_unsigned_ char parameter.
+
+2000-02-14 Wichert Akkerman <wakkerma@debian.org>
+
+  * S390 updates
+
+2000-02-03 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge Linux/ia64 patches
+
+2000-01-02 Pavel Machek	     <pavel@ucw.cz>
+
+  * probe if sys/poll.h exists in configure + minor cleanups
+
+  * syscall.c: split trace_syscall into few pieces to make code readable
+
+2000-01-21 Wichert Akkerman  <wakkerma@debian.org>
+
+  * Release version 4.2 to get the current updates out and so
+    we can concentrate in finishing the clone support.
+
+2000-01-11 Wichert Akkerman  <wakkerma@debian.org>
+
+  * Add 1900 to tm_year in sprinttime
+
+1999-12-24  Wichert Akkerman  <wakkerma@debian.org>
+
+ * file.c: protect printstat64 with STAT64 instead of linux so we can
+   compile on Linux architectures that don't have it
+ * util.c: fix LOOP for ARM
+
+Fri Dec 24 18:05:00 EST 1999
+
+1999-12-23  Ulrich Drepper  <drepper@cygnus.com>
+
+ * file.c: Use ugly libc_stat trick also for stat64.
+   Implement sys_stat64, sys_fstat64, sys_lstat64, and printstat64.
+ * process.c (internal_clone): Fix a few typos and add definitions to make
+   it at least compile.
+ * linux/syscall.h: Declare sys_stat64, sys_lstat64, and sys_fstat64.
+ * linux/syscallent.h: Define table entries for sys_stat64, sys_lstat64,
+   and sys_fstat64.
+ * aclocal.m4: Define AC_STAT64.
+ * acconfig.h: Define HAVE_STAT64.
+ * configure.in: Add AC_STAT64.
+
+Thu Dec 23 15:01:37 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patch from ftp://oss.software.ibm.com/linux390/ to add
+    support for Linux on the IBM S/390 architecture
+  * process.c: add internal_clone(), currently only shows the options
+  * syscall.c: use internal_clone to handle SYS_clone
+
+Mon Dec 20 00:27:50 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Rewrite mmap-handling to support mmap2 on Linux
+
+Tue Dec 14 11:35:16 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Note that Linux can handle sys_semop() as well
+
+Tue Nov 30 11:05:26 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Include linux/in6.h for glibc2.0 and older
+
+Mon Nov 29 16:33:04 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patches from John Hughes to make configure support UnixWare
+
+Sat Nov 27 21:38:17 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Enhance sys_query_module
+
+Fri Nov 26 10:51:55 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Patches from John Hughes:
+    + cosmectic fix in sys_getpmsg
+    + allow net.c to compile on systems without AF_INET6
+    + Only use long_to_sigset on Linux systems
+    + UnixWare treats sigmask_t and sigmask_t* as the same thing
+    + Add pollhack
+    + Parse mount arguments for UnixWare
+    + ACL fixes for UnixWare
+
+Fri Nov 26 01:28:09 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Release 4.1 to get all the changes made out there
+
+Thu Nov 18 18:04:04 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge stracefork from Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
+    + Socket calls parsed better
+	+ bunch of alpha OSF syscalls added
+	+ Fix alpha 32/64 bit issues
+
+Mon Nov  1 20:52:08 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Move Linux kernelmodule-functions from system.c to bjm.c and
+    remove duplicate for sys_create_module
+  * Linux MIPS updates:
+    + Play with #ifdef's in net.c to get IPv6 right
+    + Use printargs for vm86-syscall
+
+Sun Oct 31 22:03:00 CET 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge Linux mips patch from Florian Lohoff <flo@rfc822.org>
+
+Mon Oct 11 00:36:25 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patch from Keith Owens <kaos@ocs.com.au> to sys_query_module
+    and sys_delete_module correctly
+
+Wed Oct  6 02:00:33 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Update cvsbuild to give a better error if autoconf isn't installed
+  * Add test for linux/ptrace.h to configure
+  * Since we define GNU_SOURCE in the Makefile we don't need to define
+    USE_GNU in file.c anymore
+
+Fri Sep 10 04:35:16 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * #define USE_GNU before including file.c so we get some extra O_* flags
+
+Tue Aug 31 16:27:21 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Add missing } in IPv6 output
+
+Tue Aug 31 01:23:08 CEST 1999  Wichert Akkerman <wakkerma@debian.org>
+
+  * Update copyright for strace-graph to BSD to be consistent with
+    the rest of strace
+
+Mon Aug 30 00:53:57 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patch from Daniel Jacobowitz: KERN_JAVA_* and KERN_SECURELVL aren't
+    defined for all kernelversions
+  * Add strace-graph, written by Richard Braakman <dark@xs4all.nl>
+
+Thu Aug 19 13:10:15 CEST 1999 Jakub Jelinek <jj@ultra.linux.cz>
+
+  * linux/sparc/syscall.h: Declare create_module/init_module.
+  * configure.in: Allow compilation in a different directory
+    than the source one.
+  * signal.c: Use asm/reg.h and struct regs instead of pt_regs
+    so that we don't depend on asm/ptrace.h which clashes with
+    glibc sys/ptrace.h.
+  * util.c: Likewise.
+  * syscall.c: Likewise.
+
+Wed Aug  4 18:01:50 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Syscall 94 on Linux alpha is sys_poll
+
+Sun Jul 25 14:38:33 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge in UnixWare patches from John Hughes <john@Calva.COM>
+
+Thu Jul 15 23:00:32 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patch from Maciej W. Rozycki <macro@ds2.pg.gda.pl>:
+    + Correctly implement fix sys_createmodule (Linux)
+    + Add limited handlig of sys_initmodule (Linux)
+
+Tue Jul 13 17:07:50 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Add configure-test for sys/reg.h and use that
+  * Use sys/reg.h instead of asm/ptrace.h
+
+Sat Jul 10 01:46:10 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Remove hack in signal.c for arm architecture
+  * Add hack so we compile correctly on powerpc
+
+Fri Jul  9 02:28:16 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Add a corrected patch from Daniel Jacobowitz
+
+Thu Jul  8 16:00:04 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patch from Daniel Jacobowitz to allow us to use the kernel types
+    for the stat structure
+
+Thu Jun 24 15:54:18 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Fix test for sys/reg include
+
+Tue Jun 22 17:26:33 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Fixed some Linux/powerpc sillyness, thanks to Daniel Jacobowitz
+  * Fixed some SunOS compile problems earlier that I forgot to include
+    here
+
+Mon Jun 14 12:44:25 CEST 1999
+
+  * Avoid leakint fd into child when forking, patch from
+    John Hughes <john@Calva.COM>
+
+Fri Jun 11 14:54:47 CEST 1999
+
+  * Applied IRIX64 patch from Thomas E. Dickey <dickey@clark.net>
+  * Applied Solaris and manpage updates from Guy Harris <guy@netapp.com>
+
+Wed Jun  9 14:48:49 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Brought syscall list for alpha up to date
+
+Wed Jun  2 18:30:12 CEST 1999 Jakub Jelinek <jj@ultra.linux.cz>
+
+  * system.c: sys_umount2 syscall support.
+  * linux/sparc/errnoent.h: Update sparc-linux errnos.
+  * linux/sparc/syscall.h: Update used sparc-linux syscalls.
+  * linux/sparc/syscallent.h: Match 2.2.9 system calls.
+  * file.c: sparc-linux asm/stat.h uses dev_t etc. types,
+    so it needs strace's own copy of the stat structure.
+  * util.c: Make it compile on sparc-linux.
+  * strace.c: Fix strace -f and -ff operation on sparc-linux.
+  * signal.c: rt_sigaction has different arguments on sparc*-linux
+    and alpha-linux.
+  * syscall.c: Recognize sparc64-linux binaries.
+
+Fri May 28 21:09:00 PST Ulrich Drepper <drepper@cygnus.com>
+
+  * configure.in: Fix typo (CFLAG -> CFLAGS).
+
+  * syscall.c: Don't include linux/ptrace.h explicitly for glibc.
+
+Thu May 27 13:59:27 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Add some sysctl support, patch from Ulrich Drepper
+
+Wed May 26 01:04:34 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Use kernel dirent structure for Linux
+
+Sun May  9 02:18:30 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge in patches from Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
+    + some layout and other minor fixes
+    + add some m68k-specific things to linux/syscallent.h. Note that m68k
+      is similar enough to i386 to not need it's own subdirectory
+    + add support for sendfile and mremap syscalls for Linux
+  * Merge in patches from Sascha Schumann <sascha@schumann.2ns.de>
+    + ioctls.h vs sys/ioctl.h on Alpha platform
+    + pointer was casted to an int in stream.c
+    + strsignal() needs -D_GNU_SOURCE in CFLAGS
+    + several other casts changed
+    + correct ARM/POWERPC architecture defines in acconfig.h
+  * Merge in patches from Morten Welinder <terra@diku.dk>
+    + add some autoconf-tests for includefiles
+    + handle solaris version of sigcontext struct (actually I hacked this
+      up again, but the idea is his :)
+
+Sun Apr 18 22:32:42 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Update syscalls for linux alpha, patch from Bart Warmerdam
+    <bartw@debian.org>
+  * Update sparc code so it actually compiles
+
+Fri Apr 16 02:18:05 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Add support for old_*stat functions for Linux. Please note you need
+    to use reasonably recent kernel headers to compile strace now.
+  * Change references to LINUX into linux in file.c
+  * Fix include for LDT in mem.c
+
+Thu Apr 15 22:28:15 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Change in strace maintainership, jrs passed the torch to me.
+  * Use autoconf 2.13
+  * Incorporate all changes already made in the Debian strace package:
+    + compiles with more Linux kernels
+    + added support for more Linux architectures
+    + add support for a lot of extra syscalls
+    + fix some problems with hanging children
+    + check stray syscall after execv
+    + decode capget and capset arguments
+    + add more constants to net.c
+    + detect ROSE networking
+    + add more protocol families to domains
+    + add IPIP protocol
+    + added MSG_PROXY and MSG_CTRUNC to msg_flags
+    + added SO_BSDCOMPAT and SO_REUSEPORT to sockoptions
+    + added IP, IPX and TCP-options
+    + added IP, IPX and TCP support to get-/setsockopt()
+    + added IPX support
+    + updated handling of signals
+
+Sun Oct 27 22:28:00 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* util.c (umovestr) [LINUX]: Handle Linux like SunOS4
+	instead of SVR4.  That is, read a few bytes at a time
+	to avoid overrunning the end of the stack.
+
+Fri May 31 01:48:49 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.1 is released.
+
+Thu May 23 01:04:43 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* aclocal.m4 (AC_DECL_SYS_ERRLIST): Try looking in stdio.h
+	as well since that's where glibc declares it.  Go figure.
+	* signal.c (sys_sigreturn) [ALPHA]: Use sigcontext
+	instead of sigcontext_struct since glibc v5+ apparently
+	plays games with the native OS namespace.
+	From David Mosberger-Tang <davidm@AZStarNet.com>.
+
+Mon May 20 23:17:14 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.14 is released.
+
+	* aclocal.m4 (AC_STRUCT_MSG_CONTROL): New macro.
+	* configure.in: Add call to AC_STRUCT_MSG_CONTROL.
+	* net.c (printmsghdr): Handle BSD 4.3 and 4.4 msghdr members
+	differently.
+	Reported by Henrik Storner <storner@osiris.ping.dk>.
+
+	* configure.in: (AC_CHECK_{HEADERS,FUNCS}): Add checks for
+	sys/filio.h and sys/stream.h and remove check for poll.
+	* desc.c (decode_select, sys_select, sys_oldselect) [LINUX]:
+	Handle old and new styles of argument passing for select on Linux.
+	* ioctl.c, stream.c: Conditionalize stream code on presence of
+	sys/stream.h instead of poll because glibc implements poll but
+	not the rest of the stream interface.
+	* signal.c [LINUX]: Standardize on the name sigcontext_struct.
+	(sys_sigprocmask) [ALPHA]: Handle OSF flavor which is more like
+	sigsetmask.
+	* term.c (term_ioctl): Use _VMIN, if present, for TC{G,S}ETA*.
+	* util.c (umoven, umovestr): Move data in long-sized chunks
+	at a time, instead of hard coding it to be 4.
+	From David Mosberger-Tang <davidm@AZStarNet.com>.
+
+Mon May 20 01:19:36 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.13 is released.
+
+	* configure.in (AC_CHECK_HEADERS): Add check for asm/sigcontext.h.
+	* signal.c [HAVE_ASM_SIGCONTEXT_H]: Conditionally include
+	asm/sigcontext.h to define sigcontext_struct and don't define it
+	locally if the header is present.
+
+	* syscall.c (nerrnos{0,2}): Correct size computation.
+
+	* Makefile.in: Remove dependencies and rules relating to files
+	normally found in the os directory.  Because of the new scheme we
+	don't know precisely where they come from.  Sigh.
+	* signalent.sh: Make it work for sunos4, linux, and svr4.
+	* {sunos4,linux{,/alpha},svr4}/Makefile.in: Make rules correspond
+	to traditional make syntax.  Add signalent.h to files which can
+	unconditionally be rebuilt.  Prevent signalent.h from being
+	unconditionally being rebuilt since it's customized.
+	* {sunos4,linux{,/alpha},svr4}/{ioctlent,errnoent,signalent}.h:
+	Use versions built by {ioctlent,errnoent,signaltent}.sh.
+	* sunos4/ioctlent.sh: Work around sprintf troubles with SunOS
+	4.1.4 and gcc 2.7.2.
+
+Sun May 19 17:14:09 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* configure.in, Makefile.in: Add OSARCH concept to finish
+	build support for the alpha.
+	* Makefile.in, linux/Makefile.in: Rewrite clean, distclean,
+	and maintainer-clean rules.
+	* defs.h, ioctlsort.c: Make ioctl code member unsigned.
+	* ioctl.c, ioctlsort.c (compare): Perform explicit checking
+	for less, greater, and equal since subtraction on two's
+	complement numbers isn't an order relation (it isn't transitive)!
+	* linux/Makefile.in: Add rules for the signalent.h file.
+	* linux/alpha/Makefile.in: New file.
+
+Sun May 19 01:12:28 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.12 is released.
+
+	* linux{,alpha}/ioctlent.sh: Tweak for recent kernels.
+	From Michael E Chastain <mec@duracef.shout.net>.
+
+	* defs.h (SUPPORTED_PERSONALITES, DEFAULT_PERSONALITY): New.
+	* syscall.c (set_personality): New.
+	* strace.c (main): Call set_personality.
+	* defs.h, syscall.c, ioctl.c, signal.c: Make sysent, errnoent,
+	ioctlent, and signalent indirect pointers and redirect them
+	based on personality.
+	* {sunos4,svr4,linux{,/alpha}}/signalent.h: New files.
+	Suggested by Tom Dyas <tdyas@eden.rutgers.edu>.
+
+	* util.c (upeek): Handle case where ptrace returns a long
+	and sizeof(long) != sizeof(int).
+	From Richard Henderson <richard@twiddle.tamu.edu>
+
+Fri May 17 21:03:36 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.11 is released.
+
+	* many files: Fix more printf warnings for other platforms.
+
+	* ipc.c (sys_msgrcv) [LINUX]: Conditionalize definition of ipc_wrapper.
+
+	* linux/dummy.h: Handle missing library support for {send,recv}msg.
+	Reported by Thomas Bogendoerfer <tsbogend@bigbug.franken.de>.
+
+	* linux/syscall.h (sys_utimes): Fix a typo in the declaration.
+	From Thomas Bogendoerfer <tsbogend@bigbug.franken.de>.
+
+Fri May 17 00:50:06 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.10 is released.
+
+	* Makfile.in: Add os/arch to includes so that a given arch
+	(like alpha) can override the native arch (like i386).
+	* configure.in: Check for sendmsg.
+
+	* net.c: Make sendmsg and recvmsg dependent on an autoconf
+	test.  Reported by Michael E Chastain <mec@duracef.shout.net>.
+
+	* acconfig.h, configure.in: Detect the alpha.
+	* ioctl.c: Handle the alpha.
+	* defs.h: Make some members long for the alpha.  Define
+	some register nicknames.  Add support for WAITEXECVE.
+	* file.c [ALPHA]: Support the alpha for statfs.  Add
+	osf_statfs and osf_fstatfs for the alpha.  Make damn sure
+	major and minor results are suitable for passing to printf.
+	* signal.c, syscall.c: Support the alpha.
+	* process.c: Add alpha user offsets.
+	* most files: Use %l? for printf arguments since
+	most are now longs for the alpha.
+	* linux/alpha/{errnoent.h,ioctlent.{h,sh},syscallent.h}:
+	New for the alpha.
+	From Thomas Bogendoerfer <tsbogend@bigbug.franken.de>.
+
+Wed May 15 00:29:37 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.9 is released.
+
+	* config.in, config.sub, install-sh: Upgrade to autoconf 2.10.
+
+	* linux/dummy.h, linux/syscallent.h, linux/syscall.h: Add recent
+	Linux kernel version system calls.
+
+Wed Mar 13 01:03:38 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* ipc.c [SUNOS4]: Add SunOS support for decoding IPC calls.
+	* syscall.c [SUNOS4]: Compile decode_subcall on SunOS and
+	decode IPC calls using it.
+	* sunos4/dummy.h: Alias sys_semop to printargs.
+	* sunos4/syscall.h: Add new pseudo syscalls for IPC.
+	* sunos4/syscallent.h: Include new subcalls for IPC.
+	From Matthias Pfaller <leo@dachau.marco.de>.
+
+Tue Feb 13 22:08:25 1996  J. Richard Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.8 is released.
+
+	* time.c [LINUX]: Explicitly include linux/version.h.
+
+	* strace.c (main): Don't let them even *try* to
+	get strace to attach to itself since some systems
+	don't handle this case very gracefully.
+	Reported by David S. Miller <davem@caip.rutgers.edu>.
+
+	* Makefile.in (distclean): Fix it for subdirectories.
+
+	* sunos4/syscallent.h, svr4/syscallent.h: Fill in the new
+	sys_flags member for each defined system call.
+
+Fri Dec  8 01:17:28 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* defs.h (TRACE_*): New flags to describe what class
+	of system call each system call is.
+	(sysent): Add sys_flags member.
+	* syscall.c (sysent): Define (and later undef) abbreviations
+	for the system call class flags.
+	(lookup_class): New function to translate strings to
+	system call class flags.
+	(qualify): Handle new system call class mechanism.
+	* linux/syscallent.h: Fill in the new sys_flags member
+	for each defined system call.
+
+	* defs.h (print_sock): Remove redundant and non-K&R C
+	compatible prototype.  From Juergen Weigert
+	<jnweiger@immd4.informatik.uni-erlangen.de>.
+
+Thu Dec  7 01:17:40 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* linux/ioctlent.sh: Tweak to improve ioctl accuracy.
+	From Michael E Chastain <mec@duracef.shout.net>.
+
+	* system.c (includes) [LINUX]: Add linux/nfs.h for recent
+	kernels.  From Michael E Chastain <mec@duracef.shout.net>.
+
+Wed Dec  6 21:52:28 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* file.c (sprintfstype): Enclose string result in double
+	quotes.
+
+	* time.c (sys_adjtimex) [LINUX]: Conditionalize
+	constantly evolving timex structure.
+	From Aaron Ucko <UCKO@VAX1.ROCKHURST.EDU>.
+
+	* defs.h, syscall.c, strace.c: Rename syscall to
+	trace_syscall and change prototype and all callers
+	because of broken Linux shared libraries.
+	From Aaron Ucko <UCKO@VAX1.ROCKHURST.EDU>.
+
+	* Makefile.in (clean): Check for a file with test -f not
+	test -d.  From Aaron Ucko <UCKO@VAX1.ROCKHURST.EDU>.
+
+Tue Sep 26 02:32:31 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.7 is released.
+
+	* util.c (string_quote): Fix thinko which caused core
+	dumps for strings with quotes in them.
+	Reported by Marty Leisner <leisner@sdsp.mc.xerox.com>.
+
+	* linux/Makefile.in (errnoent.h rule): Grab all errno.h
+	files from /usr/include, not just the linux one.
+	From Michael E Chastain <mec@duracef.shout.net>.
+
+	* linux/errnoent.sh: Total rewrite to handle more ioctls with
+	fewer false positives on more kernel flavors.
+	From Michael E Chastain <mec@duracef.shout.net>.
+
+Mon Sep  4 01:29:22 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.6 is released.
+
+	* linux/dummy.h, linux/syscall.h, linux/syscallent.h: Add
+	sys_msync.
+	* mem.c (mctl_funcs, mctl_lockas, sys_mctl): Conditionalize
+	on MC_SYNC instead of HAVE_MCTL.
+	(mctl_sync): Conditionalize on MS_ASYNC instead of HAVE_MCTL.
+	(sys_msync): New function.
+
+Sat Sep  2 12:06:04 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* linux/dummy.h, linux/syscall.h, linux/syscallent.h: Add
+	sys_flock and sys_getdents.
+	* desc.c (flockcmds, sys_flock): Conditionalize on LOCK_SH
+	not SUNOS4.
+	* file.c (sys_getdents): Define unconditionally and handle
+	LINUX case.
+	* strace.c (main): Disallow username option unless both real
+	and effective uids are root.
+
+Wed Aug 30 01:29:58 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* strace.c (main): Ensure that run_uid and run_gid are
+	always set to something meaningful.
+	(main, newoutf) [!SVR4]: Swap real and effective uids while
+	opening any output files.
+	(main) [!SVR4]: Treat effective uid of root as a request
+	to handle suid binaries correctly using the real uid of
+	the invoking user.
+
+Sat Aug 19 00:06:08 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* Makefile.in: Add `|| true' to clean rule because
+	although GNU make 3.74 uses `sh -c' to invoke commands
+	every other make in the world uses `sh -ec'.
+
+	* syscall.c (syscall) [SVR4, MIPS]: The fifth and subsequent
+	arguments appear to be stored on the stack, not in the
+	registers following A3 (empirical result).
+
+	* defs.h: Add prototype for printsock.
+	* svr4/dummy.h: Remove generic handling of sys_mount.
+	* system.c [SVR4, MIPS]: Include several system headers to cleanly
+	get access to SGI mount information.
+	(mount_flags, nfs_flags) [SVR4, MIPS]: New objects.
+	(sys_mount) [SVR4, MIPS]: New function.
+	(sys_mount) [SVR4, !MIPS]: New function.
+
+Tue Jul  4 00:30:34 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.5 is released.
+
+	* desc.c, resource.c, strace.c, syscall.c, time.c: Cast tv_sec and
+	tv_usec members to long when using printf.
+
+	* ipc.c: Omit define of __KERNEL__.
+	({MSG,SEM,SHM}_{STAT,INFO}): Explicitly define those things we
+	want which __KERNEL__ used to provide.
+	(sys_msgrcv): Change reference to ipc_kludge structure to
+	look-alike ipc_wrapper to avoid dependence on __KERNEL__.
+
+	mem.c (mmap_flags) [MAP_{GROWSDOWN,DENYWRITE,EXECUTABLE}]: Add
+	Linux specific options.
+
+	syscall.c: Use SYS_ERRLIST_DECLARED instead of guessing.
+	[E{RESTART{SYS,NO{INTR,HAND}},NOIOCTLCMD}]: Explicitly define
+	instead of depending of __KERNEL__.
+
+	term.c: Cast c_{i,o,c,l}flag to long when using printf.
+
+Tue Jun  6 00:27:48 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* aclocal.m4 (AC_DECL_SYS_ERRLIST, AC_DECL__SYS_SIGLIST): New.
+	* configure.in: Call AC_DECL_SYS_ERRLIST, AC_DECL_SYS_SIGLIST,
+	and AC_DECL__SYS_SIGLIST.
+	* acconfig.h (SYS_ERRLIST_DECLARED): New.
+	* strace.c (strerror): Use SYS_ERRLIST_DECLARED.
+	(strsignal): Use SYS_SIGLIST_DECLARED.
+
+	net.c (sys_socket): Omit inadvertent surplus comma when
+	protocol family isn't PF_INET.
+
+	util.c (dumpstr): Fix incorrect printing of one too many
+	characters when the length is not an even multiple of 16 bytes.
+	Reported by Juergen Weigert
+	<jnweiger@immd4.informatik.uni-erlangen.de>.
+
+Thu May  4 23:37:47 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* ioctl.c (compare): Change prototype to match POSIX qsort.
+	* signal.c (sigishandled) [SVR4]: Omit everything after return.
+	* strace.c (trace) [SVR4]: Break out of for loop instead of
+	returning when finished so final return statement is executed.
+	* syscall.c (internal_syscall): Add more SYS_wait* variations.
+	(syscall) [LINUX]: Correct typo which commented out the M68K
+	argument to ifdef.
+	* util.c (printstr): Cast unsigned char pointer argument
+	to char pointer in umovestr call.
+	(dumpstr): Likewise for umoven.
+
+Wed May  3 01:10:56 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.4 is released.
+
+	* signal.c (sys_sigblock): Move after the definition of
+	sys_sigsetmask that it calls to avoid an implicit declaration.
+	* stream.c (transport_user_options, transport_server_options):
+	Only needed if TI_BIND is defined.
+	* configure.in: Add -Wno-implicit to WARNFLAGS on SunOS 4.x.
+
+	* process.c (internal_fork) [SVR4]: Fix a typo that omitted
+	the tcp arguement from the call to exiting.  Add getrval2
+	check so no fork processing is done in the child.
+	(printwaitn): Initialize exited so that its value is defined
+	for all flows of execution.
+
+Tue May  2 22:39:42 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* linux/dummy.h: Add aliases for sysfs, personality, afs_syscall,
+	setfsuid, setfsgid, and _llseek syscalls.
+	* linux/syscall.h: Add prototypes for them.
+	* linux/syscallent.h: Add them to the syscall entries table.
+	* system.c (headers) [LINUX]: Include linux/unistd.h to get __NR_*
+	defines and conditionally include linux/personality.h if
+	__NR_personality is defined.
+	(personality_options) [LINUX]: New table.
+	(sys_personality) [LINUX]: New function.
+
+Tue May  2 00:20:39 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* strace.c (trace) [!SVR4]: Change forever loop to one predicated
+	on the number of traced processes so that we can have untraced
+	children (e.g. via popen).
+
+	* strace (main) [!SVR4]: Call fake_execve to get the actual
+	exec and its arguments into the trace.
+	(environ): Declare it.
+	* process.c (fake_execve): New function.
+	(headers): Include sys/syscall.h to get SYS_* defines.
+
+	* process.c (sys_execv, sys_execve): Surround argument annotations
+	with C comment delimiters.
+	(printargv, printargc): The arg vector is an array of char pointers
+	not ints.
+
+	* strace.c (printleader): Also check for multiple -p arguments
+	when deciding whether to print the pid field.
+
+	* strace.c (strerror) [!HAVE_STRERROR]: New function.
+	* defs.h (strerror, strsignal): Add these prototypes if we provide
+	the functions.
+	* configure.in (AC_CHECK_FUNCS): Add strerror.
+
+	* strace.c (main, proc_poller): Add SIGPIPE to the list of caught
+	and blocked signals.
+
+	* strace.c (main): Add username option.  Verify they are root before
+	letting them use it.  Look up the ids in the password file.  Set
+	them just before executing the program.
+	From Reuben Sumner <rasumner@undergrad.math.uwaterloo.ca>.
+
+Sat Apr 29 00:09:56 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.3 is released.
+
+	* system.c (mount_flags) [LINUX]: Omit duplicated MS_NOSUID entry.
+	From Reuben Sumner <rasumner@undergrad.math.uwaterloo.ca>.
+
+	* strace.c (outfname): Initialize to NULL.
+	(main): Defer output file processing until after arguments.
+	Allow either a pipe or a bang for command arguments.
+	Check if outfname is NULL instead of checking outf for stderr.
+	Reinitialize each startup TCB's outf to fix -p/-o ordering bug.
+	(droptcb): Reset close TCB's outf to NULL instead of stderr.
+	(tprintf): Avoid calling vfprintf if outf is NULL.
+
+	* strace.c (main): Use popen if -o argument begins with a pipe.
+	From Marty Leisner <leisner@sdsp.mc.xerox.com>.
+
+	* process.c (printstatus): Fix a typo where WIFSIGNALED was meant
+	but WIFSTOPPED was used.
+
+	* Makefile.in: Add an EXTRA_DEFS variable and use it in the .c.o
+	rule to prevent the comment from being untrue.
+
+Fri Apr 28 22:01:56 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* strace.c (sys_exit): Move follow fork code to internal_exit.
+	(sys_fork): Move follow fork code to internal_fork.
+	(sys_execv, sys_execve): Move follow fork code to internal_exec.
+	(sys_waitpid, sys_wait4): Move follow fork code to internal_wait.
+	(vforking): Remove this static variable and check scno in
+	internal_fork instead.
+	(internal_exit, internal_fork, internal_exec, internal_wait): New
+	functions.
+	* defs.h: Add prototypes for the new internal_* functions.
+	* syscall.c (syscall): Move syscall entering trace qualifier check
+	and reprint checking after context decoding and precede them with
+	a call to internal_syscall.  Precede syscall exiting trace
+	qualifier check with a call to internal_syscall.
+	(internal_syscall): New function.
+
+	* defs.h (struct tcb): Make scno signed.
+	* strace.c (syscall) Make u_error signed.
+	[LINUX, I386]: Avoid unsigned cast in eax check.
+	* syscall.c (sys_indir): Make i, scno, and nargs signed.
+	* desc.c (sys_select): Make cumlen unsigned
+
+Mon Apr 24 23:52:47 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* net.c (socktypes): Add SOCK_PACKET.
+
+Sun Apr  2 23:50:39 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* Makefile (clean): Check explicitly for a Makefile in subdirs
+	before running make in them.
+
+Sun Mar 26 12:37:21 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* strace.c [MIPS] (proc_open): Conditionalize run on MIPS.
+	[MIPS] (detach): Initialize error for MIPS case.
+	(trace): Initialize ioctl_result and ioctl_errno for overly helpful
+	compilers.
+	* syscall.c (decode_subcall): Move variable i into conditionals
+	that use use it.
+	* system.c (syssgi_options): Conditionalize SGI_RECVLMSG and
+	SGI_SET_FPDEBUG that SGI decided to drop.  I don't have the stomach
+	to change them all.
+	* term.c (term_ioctl): Force [c_[iocl]flags members to long before
+	printing since we don't know what the size of their type is.
+	* util.c [SVR4, MIPS] (umoven): Prevent MIPS from using pread even
+	if autoconf detects it since it seems to either not work or do
+	something else entirely on Irix 5.3.
+
+Sun Mar 26 00:01:11 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.2 is released.
+	* linux/dummy.h: Make sys_fchdir like sys_close instead of printargs
+	so that the file descriptor arg is decimal.
+
+Sat Mar 25 22:50:13 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* net.c [LINUX] (protocols): Explicitly define all IPPROTO_* entries
+	because on Linux they are enumerators.
+
+	* system.c [LINUX] (mount_flags): Handle renaming of MS_SYNC to
+	MS_SYNCHRONOUS.
+
+	* util.c (printxval): When there is no translation, print the actual
+	number first and the the default value as a C comment.
+
+	* net.c (sys_send, sys_sendto, sys_sendmsg, sys_getsockopt,
+	sys_setsockopt): Change first argument from unsigned to signed to
+	cater to the frequent practice of calling system calls with a file
+	descriptor of -1.
+	* mem.c (sys_mmap): Likewise.
+
+Sun Mar 19 13:53:52 1995  Rick Sladkey  <jrs@world.std.com>
+
+	* signal.c [LINUX] (signalent): Handle old and new values of SIGIO.
+
+Sun Dec 11 22:51:51 1994  Rick Sladkey  <jrs@world.std.com>
+
+	* version.c: Version 3.0.1 is released.
+	* Makefile.in, configure.in, aclocal.m4: Changes for autoconf 2.0.
+	* config.guess, config.guess: Update from the FSF.
+	* install-sh: New from the FSF.
+
+Mon Dec  5 20:51:29 1994  Rick Sladkey  <jrs@world.std.com>
+
+	* Makefile.in: Add m68k arch.
+	* acconfig.h (M68K): Add m68k define.
+	* configure.in: Add detection of arch m68k.
+	* process.c [M68K] (struct_user_offsets): Support m68k registers and
+	offsets.
+	* signal.c [M68K] (sigcontext_struct): Support m68k sigcontext
+	structure.
+	[M68K] (sys_sigreturn): Support m68k sigreturn handling.
+	* syscall.c [M68K] (syscall): Support m68k syscall number register
+	and errno in d0 instead of eax.
+	* util.c [M68K] (getpc, printcall, setbpt, clearbpt): Support m68k
+	program counter in PT_PC instead of EIP.
+	[M68K] (LOOP): Support m68k loop instruction.
+	From Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>.
+
+	* mem.c [MAP_ANONYMOUS] (mmap_flags): Correct inadvertent reference
+	to MAP_FIXED instead of MAP_ANONYMOUS.
+	From Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>.
+
+	* signal.c [LINUX] (signalent): Signal 30 is now SIGPWR.
+	From Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>.
+
+Mon Dec  5 01:05:46 1994  Rick Sladkey  <jrs@world.std.com>
+
+	* defs.h (tprintf): Fix typo in non-gcc ansi prototype for tprintf.
+	Reported by Thanh Ma <tma@encore.com>.
+
+	* strace.c (cleanup): Send SIGCONT before SIGTERM because Linux
+	1.1.62 doesn't continue a traced child when the parent exits.
+	Reported by Matt Day <mday@artisoft.com>.
+
+	* system.c [LINUX]: Include netinet/in.h before arpa/inet.h.
+
+	* util.c (printstr): Fix longstanding bug in notating string
+	continuation.
+
+	* strace.c [SVR4] (proc_open): Specifically wait for the child the
+	child to go into the execve syscall to avoid spurious traces.
+	[LINUX] (detach): Conditionalize the status variable.
+
+Sun Dec  4 23:21:42 1994  Rick Sladkey  <jrs@world.std.com>
+
+	* Makefile.in: Add mips arch.
+	* acconfig.h (MIPS): Add mips define.
+	* configure.in: Add detection of opsys irix5 and arch mips.  Check
+	for prctl function.
+	Check for sys/sysconfig.h header.
+	* defs.h (MAX_ARGS): Bump maximum syscall arguments from 8 to 32.
+	* file.c [SVR4]: Include sys/cred.h.
+	(access_flags): Update access flags for SGI.
+	(sprinttime): Change type of sprinttime argument from unsigned
+	long to time_t.
+	* process.c [HAVE_PRCTL]: Include sys/prctl.h.
+	[HAVE_PRCTL] (prctl_options, sys_prctl): New for SGI.
+	(printsiginfo): Conditionally compile SI_TIMER and SI_MESGQ.
+	Cast si_band member to long before printing.
+	* signal.c (sigact_flags): Add _SA_BSDCALL for SGI.
+	(sigprocmaskcmds): Add SIG_SETMASK32 for SGI.
+	* strace.c [SVR4] [MIPS]:
+	(foobar): New dummy signal handler.
+	(main): Install a dummy signal handler in the child before pausing
+	to work around an SGI bug in PRSABORT.
+	(proc_open): Send a interrupt to the child instead of aborting the
+	syscall which doesn't work on Irix5.2.
+	* svr4/dummy.h: Add new unfinished SGI syscalls
+	(e.g. sys_sysmp, sys_sginap, etc.).  Handle some SGI syscalls like
+	existing calls (e.g. sys_ksigaction like sys_sigaction).
+	Printargs does the print thing for sys_sethostid.
+	* svr4/syscall.h: Declare all new SGI syscalls.
+	(SGI_KLUDGE): Define syscall table starting index to be 1 for SGI
+	and add it to all subcall entry points.
+	(SYS_pgrpsys_subcall, SYS_sigcall_subcall, SYS_context): Don't
+	decode as subcalls on MIPS. Instead, use the normal syscalls.
+	* svr4/syscallent.h [MIPS]: Lead syscall table with a dummy entry
+	since SGI syscall numbers are off by one.
+	[MIPS] (sys_pgrpsys): Rename to sys_setpgrp on SGI.
+	[MIPS] (sys_xenix): Rename to sys_syssgi on SGI.
+	[MIPS] (sys_sysmachine): Rename to sys_sysmips on SGI.
+	[MIPS]: Conditionalize SVR4 extension into SGI and Solaris classes.
+	* syscall.c (dumpio): Validate descriptor against MAX_QUALS.
+	[HAVE_PR_SYSCALL] (syscall): Conditionalize SYS_vfork.
+	[MIPS] (syscall): Add SGI section for decoding u_error and u_rval.
+	Add workaround for broken SGI pr_sysarg on syscall entry.
+	[SVR4] (syscall): Conditionalize subcall decoding for
+	SYS_ptrpsys_subcall, SYS_sigcall_subcall and SYS_context_subcall.
+	[SVR4] [MIPS] (getrval2): Handle SGI.
+	* syscallent.sh: Dork the sed line to be choosier about SYS_ lines.
+	* system.c [HAVE_SYSCONFIG_H]: Include sys/sysconfig.h.
+	[MIPS] (syssgi_options, sys_syssgi): New for SGI.
diff --git a/strace/HACKING-scripts b/strace/HACKING-scripts
new file mode 100644
index 0000000..1220fdd
--- /dev/null
+++ b/strace/HACKING-scripts
@@ -0,0 +1,58 @@
+Each strace port relies heavily on port-specific headers:
+	- errnoent.h - map error number to error name like strerror()
+	- ioctlent.h - map ioctl number to symbolic define
+	- signalent.h - map signal number to signal name like strsignal()
+	- syscallent.h - map syscall number to name and function signature
+
+Since generating these headers from scratch (or even just updating them) can be
+a big pain, there are a few scripts to help automate the process.  Since each
+port organizes their kernel sources differently, there may be a specific script
+for your kernel.
+
+We will use the Linux kernel (2.6.20+) as an example below (the Blackfin
+architecture to be specific).  Hopefully, it'll be obvious how to swap out a
+different system or architecture as your circumstances apply.
+
+ksrc=/usr/src/linux
+asrc=$ksrc/arch/blackfin/include
+
+To use the errnoent.sh script, give it all the headers that might contain
+appropriate errno values.  Excessive headers are not a problem.  The resulting
+output should be directly usable without modification.
+	sh ./errnoent.sh \
+		$ksrc/include/linux/*errno*.h \
+		$ksrc/include/asm-generic/*errno*.h \
+		$asrc/asm/*errno*.h \
+		> errnoent.h
+
+To use the ioctls_gen.sh script, give it all the base include directories.  The
+script will crawl all the headers and try to discover appropriate ioctls.
+Unlike the other scripts, this one creates files for further processing.  This
+is because ioctls tend to have a lot of define indirection, and the ioctlent0.h
+header needs to be fully expanded into numeric form and sorted properly.  So
+first we process all of the ioctls with the ioctls_gen.sh into ioctls_inc.h and
+ioctls_arch.h, and then we compile them into ioctlsort.c.  The resulting
+output, while directly usable, only contains definitions that match exactly the
+current kernel version that the script ran against.  That means older/newer
+ioctl defines that might be present in the existing ioctlent0.h header will be
+lost if things are copied directly.  A little creative use of `diff` and manual
+merging should be used to produce the final ioctlent0.h header.
+	sh ./maint/ioctls_gen.sh $ksrc/include $asrc
+	gcc -Wall -I. ioctlsort.c -o ioctlsort
+	./ioctlsort > ioctlent0.h
+
+To use the signalent.sh script, give it all the headers that might contain
+appropriate signal values.  Excessive headers are not a problem.  The resulting
+output should be directly usable without modification.
+	sh ./signalent.sh \
+		$asrc/asm/signal.h \
+		> signalent.h
+
+To use the syscallent.sh script, give it the header with the list of your
+system call numbers.  The resulting output is useful as a template for creating
+a proper header as it can really only detect the system call number and its
+name.  It has no way of knowing the number of arguments or strace flags for
+decoding them (yet?).
+	sh ./syscallent.sh \
+		$asrc/asm/unistd.h \
+		> syscallent.h
diff --git a/strace/INSTALL b/strace/INSTALL
new file mode 100644
index 0000000..0fad641
--- /dev/null
+++ b/strace/INSTALL
@@ -0,0 +1,302 @@
+Installation Instructions
+*************************
+
+Copyright (C) 1994-1996, 1999-2002, 2004-2012 Free Software Foundation,
+Inc.
+
+Copying and distribution of this file, with or without modification, are
+permitted in any medium without royalty provided the copyright notice
+and this notice are preserved.  This file is offered as-is, without
+warranty of any kind.
+
+Basic Installation
+==================
+
+Briefly, the shell commands `./configure; make; make install' should
+configure, build, and install this package.  The following
+more-detailed instructions are generic; see the `README' file for
+instructions specific to this package.  Some packages provide this
+`INSTALL' file but do not implement all of the features documented
+below.  The lack of an optional feature in a given package is not
+necessarily a bug.  More recommendations for GNU packages can be found
+in *note Makefile Conventions: (standards)Makefile Conventions.
+
+   The `configure' shell script attempts to guess correct values for
+various system-dependent variables used during compilation.  It uses
+those values to create a `Makefile' in each directory of the package.
+It may also create one or more `.h' files containing system-dependent
+definitions.  Finally, it creates a shell script `config.status' that
+you can run in the future to recreate the current configuration, and a
+file `config.log' containing compiler output (useful mainly for
+debugging `configure').
+
+   It can also use an optional file (typically called `config.cache'
+and enabled with `--cache-file=config.cache' or simply `-C') that saves
+the results of its tests to speed up reconfiguring.  Caching is
+disabled by default to prevent problems with accidental use of stale
+cache files.
+
+   If you need to do unusual things to compile the package, please try
+to figure out how `configure' could check whether to do them, and mail
+diffs or instructions to the address given in the `README' so they can
+be considered for the next release.  If you are using the cache, and at
+some point `config.cache' contains results you don't want to keep, you
+may remove or edit it.
+
+   The file `configure.ac' (or `configure.in') is used to create
+`configure' by a program called `autoconf'.  You need `configure.ac' if
+you want to change it or regenerate `configure' using a newer version
+of `autoconf'.
+
+The simplest way to compile this package is:
+
+  1. `cd' to the directory containing the package's source code and type
+     `./configure' to configure the package for your system.
+
+     Running `configure' might take a while.  While running, it prints
+     some messages telling which features it is checking for.
+
+  2. Type `make' to compile the package.
+
+  3. Optionally, type `make check' to run any self-tests that come with
+     the package, generally using the just-built uninstalled binaries.
+
+  4. Type `make install' to install the programs and any data files and
+     documentation.  When installing into a prefix owned by root, it is
+     recommended that the package be configured and built as a regular
+     user, and only the `make install' phase executed with root
+     privileges.
+
+  5. Optionally, type `make installcheck' to repeat any self-tests, but
+     this time using the binaries in their final installed location.
+     This target does not install anything.  Running this target as a
+     regular user, particularly if the prior `make install' required
+     root privileges, verifies that the installation completed
+     correctly.
+
+  6. You can remove the program binaries and object files from the
+     source code directory by typing `make clean'.  To also remove the
+     files that `configure' created (so you can compile the package for
+     a different kind of computer), type `make distclean'.  There is
+     also a `make maintainer-clean' target, but that is intended mainly
+     for the package's developers.  If you use it, you may have to get
+     all sorts of other programs in order to regenerate files that came
+     with the distribution.
+
+  7. Often, you can also type `make uninstall' to remove the installed
+     files again.  In practice, not all packages have tested that
+     uninstallation works correctly, even though it is required by the
+     GNU Coding Standards.
+
+  8. Some packages, particularly those that use Automake, provide `make
+     distcheck', which can by used by developers to test that all other
+     targets like `make install' and `make uninstall' work correctly.
+     This target is generally not run by end users.
+
+Compilers and Options
+=====================
+
+Some systems require unusual options for compilation or linking that the
+`configure' script does not know about.  Run `./configure --help' for
+details on some of the pertinent environment variables.
+
+   You can give `configure' initial values for configuration parameters
+by setting variables in the command line or in the environment.  Here
+is an example:
+
+     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
+
+   *Note Defining Variables::, for more details.
+
+Installation Names
+==================
+
+By default, `make install' installs the package's commands under
+`/usr/local/bin', include files under `/usr/local/include', etc.  You
+can specify an installation prefix other than `/usr/local' by giving
+`configure' the option `--prefix=PREFIX', where PREFIX must be an
+absolute file name.
+
+   You can specify separate installation prefixes for
+architecture-specific files and architecture-independent files.  If you
+pass the option `--exec-prefix=PREFIX' to `configure', the package uses
+PREFIX as the prefix for installing programs and libraries.
+Documentation and other data files still use the regular prefix.
+
+   In addition, if you use an unusual directory layout you can give
+options like `--bindir=DIR' to specify different values for particular
+kinds of files.  Run `configure --help' for a list of the directories
+you can set and what kinds of files go in them.  In general, the
+default for these options is expressed in terms of `${prefix}', so that
+specifying just `--prefix' will affect all of the other directory
+specifications that were not explicitly provided.
+
+   The most portable way to affect installation locations is to pass the
+correct locations to `configure'; however, many packages provide one or
+both of the following shortcuts of passing variable assignments to the
+`make install' command line to change installation locations without
+having to reconfigure or recompile.
+
+   The first method involves providing an override variable for each
+affected directory.  For example, `make install
+prefix=/alternate/directory' will choose an alternate location for all
+directory configuration variables that were expressed in terms of
+`${prefix}'.  Any directories that were specified during `configure',
+but not in terms of `${prefix}', must each be overridden at install
+time for the entire installation to be relocated.  The approach of
+makefile variable overrides for each directory variable is required by
+the GNU Coding Standards, and ideally causes no recompilation.
+However, some platforms have known limitations with the semantics of
+shared libraries that end up requiring recompilation when using this
+method, particularly noticeable in packages that use GNU Libtool.
+
+   The second method involves providing the `DESTDIR' variable.  For
+example, `make install DESTDIR=/alternate/directory' will prepend
+`/alternate/directory' before all installation names.  The approach of
+`DESTDIR' overrides is not required by the GNU Coding Standards, and
+does not work on platforms that have drive letters.  On the other hand,
+it does better at avoiding recompilation issues, and works well even
+when some directory options were not specified in terms of `${prefix}'
+at `configure' time.
+
+Optional Features
+=================
+
+If the package supports it, you can cause programs to be installed with
+an extra prefix or suffix on their names by giving `configure' the
+option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
+
+   Some packages pay attention to `--enable-FEATURE' options to
+`configure', where FEATURE indicates an optional part of the package.
+They may also pay attention to `--with-PACKAGE' options, where PACKAGE
+is something like `gnu-as' or `x' (for the X Window System).  The
+`README' should mention any `--enable-' and `--with-' options that the
+package recognizes.
+
+   For packages that use the X Window System, `configure' can usually
+find the X include and library files automatically, but if it doesn't,
+you can use the `configure' options `--x-includes=DIR' and
+`--x-libraries=DIR' to specify their locations.
+
+   Some packages offer the ability to configure how verbose the
+execution of `make' will be.  For these packages, running `./configure
+--enable-silent-rules' sets the default to minimal output, which can be
+overridden with `make V=1'; while running `./configure
+--disable-silent-rules' sets the default to verbose, which can be
+overridden with `make V=0'.
+
+Specifying the System Type
+==========================
+
+There may be some features `configure' cannot figure out automatically,
+but needs to determine by the type of machine the package will run on.
+Usually, assuming the package is built to be run on the _same_
+architectures, `configure' can figure that out, but if it prints a
+message saying it cannot guess the machine type, give it the
+`--build=TYPE' option.  TYPE can either be a short name for the system
+type, such as `sun4', or a canonical name which has the form:
+
+     CPU-COMPANY-SYSTEM
+
+where SYSTEM can have one of these forms:
+
+     OS
+     KERNEL-OS
+
+See the file `config.sub' for the possible values of each field.  If
+`config.sub' isn't included in this package, then this package doesn't
+need to know the machine type.
+
+   If you are _building_ compiler tools for cross-compiling, you should
+use the option `--target=TYPE' to select the type of system they will
+produce code for.
+
+   If you want to _use_ a cross compiler, that generates code for a
+platform different from the build platform, you should specify the
+"host" platform (i.e., that on which the generated programs will
+eventually be run) with `--host=TYPE'.
+
+Sharing Defaults
+================
+
+If you want to set default values for `configure' scripts to share, you
+can create a site shell script called `config.site' that gives default
+values for variables like `CC', `cache_file', and `prefix'.
+`configure' looks for `PREFIX/share/config.site' if it exists, then
+`PREFIX/etc/config.site' if it exists.  Or, you can set the
+`CONFIG_SITE' environment variable to the location of the site script.
+A warning: not all `configure' scripts look for a site script.
+
+Defining Variables
+==================
+
+Variables not defined in a site shell script can be set in the
+environment passed to `configure'.  However, some packages may run
+configure again during the build, and the customized values of these
+variables may be lost.  In order to avoid this problem, you should set
+them in the `configure' command line, using `VAR=value'.  For example:
+
+     ./configure CC=/usr/local2/bin/gcc
+
+causes the specified `gcc' to be used as the C compiler (unless it is
+overridden in the site shell script).
+
+Unfortunately, this technique does not work for `CONFIG_SHELL' due to
+an Autoconf limitation.  Until the limitation is lifted, you can use
+this workaround:
+
+     CONFIG_SHELL=/bin/bash ./configure CONFIG_SHELL=/bin/bash
+
+`configure' Invocation
+======================
+
+`configure' recognizes the following options to control how it operates.
+
+`--help'
+`-h'
+     Print a summary of all of the options to `configure', and exit.
+
+`--help=short'
+`--help=recursive'
+     Print a summary of the options unique to this package's
+     `configure', and exit.  The `short' variant lists options used
+     only in the top level, while the `recursive' variant lists options
+     also present in any nested packages.
+
+`--version'
+`-V'
+     Print the version of Autoconf used to generate the `configure'
+     script, and exit.
+
+`--cache-file=FILE'
+     Enable the cache: use and save the results of the tests in FILE,
+     traditionally `config.cache'.  FILE defaults to `/dev/null' to
+     disable caching.
+
+`--config-cache'
+`-C'
+     Alias for `--cache-file=config.cache'.
+
+`--quiet'
+`--silent'
+`-q'
+     Do not print messages saying which checks are being made.  To
+     suppress all normal output, redirect it to `/dev/null' (any error
+     messages will still be shown).
+
+`--srcdir=DIR'
+     Look for the package's source code in directory DIR.  Usually
+     `configure' can determine that directory automatically.
+
+`--prefix=DIR'
+     Use DIR as the installation prefix.  *note Installation Names::
+     for more details, including other options available for fine-tuning
+     the installation locations.
+
+`--no-create'
+`-n'
+     Run the configure checks, but stop before creating any output
+     files.
+
+`configure' also accepts some other, not widely useful, options.  Run
+`configure --help' for more details.
diff --git a/strace/MODULE_LICENSE_BSD b/strace/MODULE_LICENSE_BSD
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/strace/MODULE_LICENSE_BSD
diff --git a/strace/Makefile.am b/strace/Makefile.am
new file mode 100644
index 0000000..1e7554e
--- /dev/null
+++ b/strace/Makefile.am
@@ -0,0 +1,880 @@
+# Automake input for strace.
+#
+# Copyright (c) 2002-2009 Roland McGrath <roland@redhat.com>
+# Copyright (c) 2006-2016 Dmitry V. Levin <ldv@altlinux.org>
+# Copyright (c) 2008-2015 Mike Frysinger <vapier@gentoo.org>
+# Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+# 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.
+
+if HAVE_M32_RUNTIME
+TESTS_M32 = tests-m32
+endif
+if HAVE_MX32_RUNTIME
+TESTS_MX32 = tests-mx32
+endif
+SUBDIRS = tests $(TESTS_M32) $(TESTS_MX32)
+
+bin_PROGRAMS = strace
+man_MANS = strace.1
+bin_SCRIPTS = strace-graph strace-log-merge
+
+OS		= linux
+# ARCH is `i386', `m68k', `sparc', etc.
+ARCH		= @arch@
+
+ACLOCAL_AMFLAGS = -I m4
+AM_CFLAGS = $(WARN_CFLAGS)
+AM_CPPFLAGS = -I$(builddir)/$(OS)/$(ARCH) \
+	      -I$(srcdir)/$(OS)/$(ARCH) \
+	      -I$(builddir)/$(OS) \
+	      -I$(srcdir)/$(OS) \
+	      -I$(builddir) \
+	      -I$(srcdir)
+
+include xlat/Makemodule.am
+
+strace_CPPFLAGS = $(AM_CPPFLAGS)
+strace_CFLAGS = $(AM_CFLAGS)
+strace_LDFLAGS =
+strace_LDADD = libstrace.a
+noinst_LIBRARIES = libstrace.a
+
+libstrace_a_CPPFLAGS = $(strace_CPPFLAGS)
+libstrace_a_CFLAGS = $(strace_CFLAGS)
+libstrace_a_SOURCES =	\
+	fstatfs.c \
+	fstatfs64.c \
+	ipc.c \
+	socketcall.c \
+	statfs.c \
+	statfs64.c \
+	sync_file_range.c \
+	sync_file_range2.c \
+	upeek.c		\
+	# end of libstrace_a_SOURCES
+
+strace_SOURCES =	\
+	access.c	\
+	affinity.c	\
+	aio.c		\
+	alpha.c		\
+	bjm.c		\
+	block.c		\
+	bpf.c		\
+	btrfs.c		\
+	cacheflush.c	\
+	capability.c	\
+	caps0.h		\
+	caps1.h		\
+	chdir.c		\
+	chmod.c		\
+	clone.c		\
+	copy_file_range.c \
+	count.c		\
+	defs.h		\
+	desc.c		\
+	dirent.c	\
+	dirent64.c	\
+	empty.h		\
+	epoll.c		\
+	evdev.c		\
+	eventfd.c	\
+	execve.c	\
+	exit.c		\
+	fadvise.c	\
+	fallocate.c	\
+	fanotify.c	\
+	fchownat.c	\
+	fcntl.c		\
+	fetch_seccomp_fprog.c \
+	fetch_struct_flock.c \
+	fetch_struct_mmsghdr.c \
+	fetch_struct_msghdr.c \
+	fetch_struct_statfs.c \
+	file.c		\
+	file_handle.c	\
+	file_ioctl.c	\
+	fs_x_ioctl.c	\
+	flock.c		\
+	flock.h		\
+	futex.c		\
+	gcc_compat.h	\
+	get_robust_list.c \
+	getcpu.c	\
+	getcwd.c	\
+	getrandom.c	\
+	hdio.c		\
+	hostname.c	\
+	inotify.c	\
+	io.c		\
+	ioctl.c		\
+	ioperm.c	\
+	iopl.c		\
+	ioprio.c	\
+	ipc_defs.h	\
+	ipc_msg.c	\
+	ipc_msgctl.c	\
+	ipc_sem.c	\
+	ipc_shm.c	\
+	ipc_shmctl.c	\
+	kcmp.c		\
+	kernel_types.h	\
+	kexec.c		\
+	keyctl.c	\
+	ldt.c		\
+	link.c		\
+	linux/asm_stat.h \
+	linux/x32/asm_stat.h \
+	lookup_dcookie.c \
+	loop.c		\
+	lseek.c		\
+	mem.c		\
+	membarrier.c	\
+	memfd_create.c	\
+	mknod.c		\
+	mmsghdr.c	\
+	mount.c		\
+	mpers_type.h	\
+	mq.c		\
+	msghdr.c	\
+	msghdr.h	\
+	mtd.c		\
+	native_defs.h	\
+	net.c		\
+	netlink.c       \
+	numa.c		\
+	open.c		\
+	or1k_atomic.c	\
+	pathtrace.c	\
+	perf.c		\
+	personality.c	\
+	poll.c		\
+	prctl.c		\
+	print_mq_attr.c	\
+	print_msgbuf.c	\
+	print_sigevent.c \
+	print_statfs.c	\
+	print_time.c	\
+	print_timex.c	\
+	printmode.c	\
+	printrusage.c	\
+	printsiginfo.c	\
+	printsiginfo.h	\
+	printstat.h	\
+	process.c	\
+	process_vm.c	\
+	ptp.c		\
+	ptrace.h	\
+	quota.c		\
+	readahead.c	\
+	readlink.c	\
+	reboot.c	\
+	regs.h		\
+	renameat.c	\
+	resource.c	\
+	rtc.c		\
+	sched.c		\
+	scsi.c		\
+	seccomp.c	\
+	seccomp_fprog.h \
+	sendfile.c	\
+	sigaltstack.c	\
+	sigevent.h	\
+	signal.c	\
+	signalfd.c	\
+	sigreturn.c	\
+	sock.c		\
+	sockaddr.c	\
+	socketutils.c	\
+	sram_alloc.c	\
+	statfs.c	\
+	statfs.h	\
+	strace.c	\
+	swapon.c	\
+	syscall.c	\
+	sysctl.c	\
+	sysinfo.c	\
+	syslog.c	\
+	sysmips.c	\
+	term.c		\
+	time.c		\
+	times.c		\
+	truncate.c	\
+	ubi.c		\
+	uid.c		\
+	uid16.c		\
+	umask.c		\
+	umount.c	\
+	uname.c		\
+	userfaultfd.c	\
+	util.c		\
+	utime.c		\
+	utimes.c	\
+	v4l2.c		\
+	vsprintf.c	\
+	wait.c		\
+	xattr.c		\
+	xlat.h		\
+	xmalloc.c	\
+	# end of strace_SOURCES
+
+if USE_LIBUNWIND
+strace_SOURCES += unwind.c
+strace_CPPFLAGS += $(libunwind_CPPFLAGS)
+strace_LDFLAGS += $(libunwind_LDFLAGS)
+strace_LDADD += $(libunwind_LIBS)
+endif
+
+@CODE_COVERAGE_RULES@
+CODE_COVERAGE_BRANCH_COVERAGE = 1
+CODE_COVERAGE_GENHTML_OPTIONS = $(CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT) \
+	--prefix $(shell realpath -Ls $(abs_top_srcdir)/..)
+CODE_COVERAGE_IGNORE_PATTERN = '/usr/include/*'
+strace_CPPFLAGS += $(CODE_COVERAGE_CPPFLAGS)
+strace_CFLAGS += $(CODE_COVERAGE_CFLAGS)
+strace_LDADD += $(CODE_COVERAGE_LDFLAGS)
+
+# Enable this to get link map generated
+#strace_LDFLAGS += -Wl,-Map=strace.mapfile
+
+EXTRA_DIST =				\
+	$(man_MANS)			\
+	.version			\
+	COPYING				\
+	CREDITS				\
+	ChangeLog			\
+	ChangeLog-CVS			\
+	README-linux-ptrace		\
+	debian/changelog		\
+	debian/compat			\
+	debian/control			\
+	debian/copyright		\
+	debian/rules			\
+	debian/source/format		\
+	debian/strace-udeb.install	\
+	debian/strace.docs		\
+	debian/strace.examples		\
+	debian/strace.install		\
+	debian/strace.manpages		\
+	debian/strace64.install		\
+	debian/strace64.manpages	\
+	debian/watch			\
+	errnoent.sh			\
+	generate_sen.sh			\
+	ioctlsort.c			\
+	linux/32/ioctls_inc.h		\
+	linux/32/ioctls_inc_align32.h	\
+	linux/32/ioctls_inc_align64.h	\
+	linux/32/syscallent.h		\
+	linux/64/ioctls_inc.h		\
+	linux/64/syscallent.h		\
+	linux/aarch64/arch_regs.c	\
+	linux/aarch64/arch_regs.h	\
+	linux/aarch64/arch_sigreturn.c	\
+	linux/aarch64/errnoent1.h	\
+	linux/aarch64/get_error.c	\
+	linux/aarch64/get_scno.c	\
+	linux/aarch64/get_syscall_args.c\
+	linux/aarch64/ioctls_arch0.h	\
+	linux/aarch64/ioctls_arch1.h	\
+	linux/aarch64/ioctls_inc0.h	\
+	linux/aarch64/ioctls_inc1.h	\
+	linux/aarch64/signalent1.h	\
+	linux/aarch64/syscallent.h	\
+	linux/aarch64/syscallent1.h	\
+	linux/alpha/arch_getrval2.c	\
+	linux/alpha/arch_regs.c		\
+	linux/alpha/arch_regs.h		\
+	linux/alpha/arch_sigreturn.c	\
+	linux/alpha/errnoent.h		\
+	linux/alpha/get_error.c		\
+	linux/alpha/get_scno.c		\
+	linux/alpha/get_syscall_args.c	\
+	linux/alpha/get_syscall_result.c\
+	linux/alpha/ioctls_arch0.h	\
+	linux/alpha/ioctls_inc0.h	\
+	linux/alpha/signalent.h		\
+	linux/alpha/syscallent.h	\
+	linux/alpha/userent.h		\
+	linux/arc/arch_regs.c		\
+	linux/arc/get_error.c		\
+	linux/arc/get_scno.c		\
+	linux/arc/get_syscall_args.c	\
+	linux/arc/ioctls_arch0.h	\
+	linux/arc/ioctls_inc0.h		\
+	linux/arc/syscallent.h		\
+	linux/arch_regs.h		\
+	linux/arch_sigreturn.c		\
+	linux/arm/arch_regs.c		\
+	linux/arm/arch_regs.h		\
+	linux/arm/arch_sigreturn.c	\
+	linux/arm/get_error.c		\
+	linux/arm/get_scno.c		\
+	linux/arm/get_syscall_args.c	\
+	linux/arm/ioctls_arch0.h	\
+	linux/arm/ioctls_inc0.h		\
+	linux/arm/syscallent.h		\
+	linux/arm/userent.h		\
+	linux/avr32/arch_regs.c		\
+	linux/avr32/get_error.c		\
+	linux/avr32/get_scno.c		\
+	linux/avr32/get_syscall_args.c	\
+	linux/avr32/ioctls_arch0.h	\
+	linux/avr32/ioctls_inc0.h	\
+	linux/avr32/syscallent.h	\
+	linux/avr32/userent.h		\
+	linux/bfin/arch_regs.c		\
+	linux/bfin/get_error.c		\
+	linux/bfin/get_scno.c		\
+	linux/bfin/get_syscall_args.c	\
+	linux/bfin/get_syscall_result.c	\
+	linux/bfin/ioctls_arch0.h	\
+	linux/bfin/ioctls_inc0.h	\
+	linux/bfin/syscallent.h		\
+	linux/bfin/userent.h		\
+	linux/crisv10/arch_regs.c	\
+	linux/crisv10/arch_sigreturn.c	\
+	linux/crisv10/get_error.c	\
+	linux/crisv10/get_scno.c	\
+	linux/crisv10/get_syscall_args.c	\
+	linux/crisv10/get_syscall_result.c	\
+	linux/crisv10/userent.h		\
+	linux/crisv32/arch_regs.c	\
+	linux/crisv32/arch_sigreturn.c	\
+	linux/crisv32/get_error.c	\
+	linux/crisv32/get_scno.c	\
+	linux/crisv32/get_syscall_args.c	\
+	linux/crisv32/get_syscall_result.c	\
+	linux/crisv32/userent.h		\
+	linux/dummy.h			\
+	linux/errnoent.h		\
+	linux/hppa/arch_regs.c		\
+	linux/hppa/arch_regs.h		\
+	linux/hppa/errnoent.h		\
+	linux/hppa/get_error.c		\
+	linux/hppa/get_scno.c		\
+	linux/hppa/get_syscall_args.c	\
+	linux/hppa/get_syscall_result.c	\
+	linux/hppa/ioctls_arch0.h	\
+	linux/hppa/ioctls_inc0.h	\
+	linux/hppa/signalent.h		\
+	linux/hppa/syscallent.h		\
+	linux/i386/arch_regs.c		\
+	linux/i386/arch_regs.h		\
+	linux/i386/arch_sigreturn.c	\
+	linux/i386/get_error.c		\
+	linux/i386/get_scno.c		\
+	linux/i386/get_syscall_args.c	\
+	linux/i386/ioctls_arch0.h	\
+	linux/i386/ioctls_inc0.h	\
+	linux/i386/syscallent.h		\
+	linux/i386/userent.h		\
+	linux/i386/userent0.h		\
+	linux/ia64/arch_getrval2.c	\
+	linux/ia64/arch_regs.c		\
+	linux/ia64/arch_regs.h		\
+	linux/ia64/arch_sigreturn.c	\
+	linux/ia64/get_error.c		\
+	linux/ia64/get_scno.c		\
+	linux/ia64/get_syscall_args.c	\
+	linux/ia64/ioctls_arch0.h	\
+	linux/ia64/ioctls_inc0.h	\
+	linux/ia64/syscallent.h		\
+	linux/ia64/userent.h		\
+	linux/inet_diag.h		\
+	linux/m68k/arch_regs.c		\
+	linux/m68k/arch_sigreturn.c	\
+	linux/m68k/get_error.c		\
+	linux/m68k/get_scno.c		\
+	linux/m68k/get_syscall_args.c	\
+	linux/m68k/get_syscall_result.c	\
+	linux/m68k/ioctls_arch0.h	\
+	linux/m68k/ioctls_inc0.h	\
+	linux/m68k/syscallent.h		\
+	linux/m68k/userent.h		\
+	linux/metag/arch_regs.c		\
+	linux/metag/get_error.c		\
+	linux/metag/get_scno.c		\
+	linux/metag/get_syscall_args.c	\
+	linux/metag/ioctls_arch0.h	\
+	linux/metag/ioctls_inc0.h	\
+	linux/metag/syscallent.h	\
+	linux/microblaze/arch_regs.c	\
+	linux/microblaze/arch_sigreturn.c	\
+	linux/microblaze/get_error.c	\
+	linux/microblaze/get_scno.c	\
+	linux/microblaze/get_syscall_args.c	\
+	linux/microblaze/get_syscall_result.c	\
+	linux/microblaze/ioctls_arch0.h	\
+	linux/microblaze/ioctls_inc0.h	\
+	linux/microblaze/syscallent.h	\
+	linux/microblaze/userent.h	\
+	linux/mips/arch_getrval2.c	\
+	linux/mips/arch_regs.c		\
+	linux/mips/arch_regs.h		\
+	linux/mips/arch_sigreturn.c	\
+	linux/mips/errnoent.h		\
+	linux/mips/genstub.sh		\
+	linux/mips/get_error.c		\
+	linux/mips/get_scno.c		\
+	linux/mips/get_syscall_args.c	\
+	linux/mips/ioctls_arch0.h	\
+	linux/mips/ioctls_inc0.h	\
+	linux/mips/signalent.h		\
+	linux/mips/syscallent-compat.h	\
+	linux/mips/syscallent-n32.h	\
+	linux/mips/syscallent-n64.h	\
+	linux/mips/syscallent-o32.h	\
+	linux/mips/syscallent.h		\
+	linux/mips/userent.h		\
+	linux/mtd-abi.h			\
+	linux/netlink_diag.h		\
+	linux/nios2/arch_regs.c		\
+	linux/nios2/get_error.c		\
+	linux/nios2/get_scno.c		\
+	linux/nios2/get_syscall_args.c	\
+	linux/nios2/ioctls_arch0.h	\
+	linux/nios2/ioctls_inc0.h	\
+	linux/nios2/syscallent.h	\
+	linux/or1k/arch_regs.c		\
+	linux/or1k/get_error.c		\
+	linux/or1k/get_scno.c		\
+	linux/or1k/get_syscall_args.c	\
+	linux/or1k/ioctls_arch0.h	\
+	linux/or1k/ioctls_inc0.h	\
+	linux/or1k/syscallent.h		\
+	linux/or1k/userent.h		\
+	linux/personality.h		\
+	linux/powerpc/arch_regs.c	\
+	linux/powerpc/arch_regs.h	\
+	linux/powerpc/arch_sigreturn.c	\
+	linux/powerpc/errnoent.h	\
+	linux/powerpc/get_error.c	\
+	linux/powerpc/get_scno.c	\
+	linux/powerpc/get_syscall_args.c	\
+	linux/powerpc/getregs_old.c	\
+	linux/powerpc/ioctls_arch0.h	\
+	linux/powerpc/ioctls_inc0.h	\
+	linux/powerpc/syscallent.h	\
+	linux/powerpc/userent.h		\
+	linux/powerpc64/arch_regs.c	\
+	linux/powerpc64/arch_regs.h	\
+	linux/powerpc64/arch_sigreturn.c	\
+	linux/powerpc64/errnoent.h	\
+	linux/powerpc64/errnoent1.h	\
+	linux/powerpc64/get_error.c	\
+	linux/powerpc64/get_scno.c	\
+	linux/powerpc64/get_syscall_args.c	\
+	linux/powerpc64/getregs_old.c	\
+	linux/powerpc64/ioctls_arch0.h	\
+	linux/powerpc64/ioctls_arch1.h	\
+	linux/powerpc64/ioctls_inc0.h	\
+	linux/powerpc64/ioctls_inc1.h	\
+	linux/powerpc64/signalent1.h	\
+	linux/powerpc64/syscallent.h	\
+	linux/powerpc64/syscallent1.h	\
+	linux/powerpc64/userent.h	\
+	linux/ptp_clock.h		\
+	linux/s390/arch_regs.c		\
+	linux/s390/arch_regs.h		\
+	linux/s390/arch_sigreturn.c	\
+	linux/s390/get_error.c		\
+	linux/s390/get_scno.c		\
+	linux/s390/get_syscall_args.c	\
+	linux/s390/ioctls_arch0.h	\
+	linux/s390/ioctls_inc0.h	\
+	linux/s390/syscallent.h		\
+	linux/s390/userent.h		\
+	linux/s390/userent0.h		\
+	linux/s390/userent1.h		\
+	linux/s390x/arch_regs.c		\
+	linux/s390x/arch_regs.h		\
+	linux/s390x/arch_sigreturn.c	\
+	linux/s390x/get_error.c		\
+	linux/s390x/get_scno.c		\
+	linux/s390x/get_syscall_args.c	\
+	linux/s390x/ioctls_arch0.h	\
+	linux/s390x/ioctls_inc0.h	\
+	linux/s390x/syscallent.h	\
+	linux/s390x/userent.h		\
+	linux/sh/arch_getrval2.c	\
+	linux/sh/arch_regs.c		\
+	linux/sh/get_error.c		\
+	linux/sh/get_scno.c		\
+	linux/sh/get_syscall_args.c	\
+	linux/sh/get_syscall_result.c	\
+	linux/sh/ioctls_arch0.h		\
+	linux/sh/ioctls_inc0.h		\
+	linux/sh/syscallent.h		\
+	linux/sh/userent.h		\
+	linux/sh/userent0.h		\
+	linux/sh64/arch_regs.c		\
+	linux/sh64/arch_regs.h		\
+	linux/sh64/get_error.c		\
+	linux/sh64/get_scno.c		\
+	linux/sh64/get_syscall_args.c	\
+	linux/sh64/get_syscall_result.c	\
+	linux/sh64/ioctls_arch0.h	\
+	linux/sh64/ioctls_inc0.h	\
+	linux/sh64/syscallent.h		\
+	linux/sh64/userent.h		\
+	linux/signalent.h		\
+	linux/sock_diag.h		\
+	linux/sparc/arch_getrval2.c	\
+	linux/sparc/arch_regs.c		\
+	linux/sparc/arch_regs.h		\
+	linux/sparc/arch_sigreturn.c	\
+	linux/sparc/errnoent.h		\
+	linux/sparc/gen.pl		\
+	linux/sparc/get_error.c		\
+	linux/sparc/get_scno.c		\
+	linux/sparc/get_syscall_args.c	\
+	linux/sparc/ioctls_arch0.h	\
+	linux/sparc/ioctls_inc0.h	\
+	linux/sparc/signalent.h		\
+	linux/sparc/syscallent.h	\
+	linux/sparc/userent.h		\
+	linux/sparc64/arch_getrval2.c	\
+	linux/sparc64/arch_regs.c	\
+	linux/sparc64/arch_regs.h	\
+	linux/sparc64/arch_sigreturn.c	\
+	linux/sparc64/errnoent.h	\
+	linux/sparc64/errnoent1.h	\
+	linux/sparc64/get_error.c	\
+	linux/sparc64/get_scno.c	\
+	linux/sparc64/get_syscall_args.c\
+	linux/sparc64/ioctls_arch0.h	\
+	linux/sparc64/ioctls_arch1.h	\
+	linux/sparc64/ioctls_inc0.h	\
+	linux/sparc64/ioctls_inc1.h	\
+	linux/sparc64/signalent.h	\
+	linux/sparc64/signalent1.h	\
+	linux/sparc64/syscallent.h	\
+	linux/sparc64/syscallent1.h	\
+	linux/sparc64/userent.h		\
+	linux/subcall.h			\
+	linux/syscall.h			\
+	linux/tile/arch_regs.c		\
+	linux/tile/arch_regs.h		\
+	linux/tile/arch_sigreturn.c	\
+	linux/tile/errnoent1.h		\
+	linux/tile/get_error.c		\
+	linux/tile/get_scno.c		\
+	linux/tile/get_syscall_args.c	\
+	linux/tile/ioctls_arch0.h	\
+	linux/tile/ioctls_arch1.h	\
+	linux/tile/ioctls_inc0.h	\
+	linux/tile/ioctls_inc1.h	\
+	linux/tile/signalent1.h		\
+	linux/tile/syscallent.h		\
+	linux/tile/syscallent1.h	\
+	linux/tile/userent.h		\
+	linux/ubi-user.h		\
+	linux/unix_diag.h		\
+	linux/userent.h			\
+	linux/userent0.h		\
+	linux/x32/arch_regs.c		\
+	linux/x32/arch_regs.h		\
+	linux/x32/arch_sigreturn.c	\
+	linux/x32/errnoent1.h		\
+	linux/x32/get_error.c		\
+	linux/x32/get_scno.c		\
+	linux/x32/get_syscall_args.c	\
+	linux/x32/ioctls_arch0.h	\
+	linux/x32/ioctls_arch1.h	\
+	linux/x32/ioctls_inc0.h		\
+	linux/x32/ioctls_inc1.h		\
+	linux/x32/signalent1.h		\
+	linux/x32/syscallent.h		\
+	linux/x32/syscallent1.h		\
+	linux/x32/userent.h		\
+	linux/x86_64/arch_regs.c	\
+	linux/x86_64/arch_regs.h	\
+	linux/x86_64/arch_sigreturn.c	\
+	linux/x86_64/errnoent1.h	\
+	linux/x86_64/errnoent2.h	\
+	linux/x86_64/gentab.pl		\
+	linux/x86_64/get_error.c	\
+	linux/x86_64/get_scno.c		\
+	linux/x86_64/get_syscall_args.c	\
+	linux/x86_64/getregs_old.c	\
+	linux/x86_64/ioctls_arch0.h	\
+	linux/x86_64/ioctls_arch1.h	\
+	linux/x86_64/ioctls_arch2.h	\
+	linux/x86_64/ioctls_inc0.h	\
+	linux/x86_64/ioctls_inc1.h	\
+	linux/x86_64/ioctls_inc2.h	\
+	linux/x86_64/signalent1.h	\
+	linux/x86_64/signalent2.h	\
+	linux/x86_64/syscallent.h	\
+	linux/x86_64/syscallent1.h	\
+	linux/x86_64/syscallent2.h	\
+	linux/x86_64/userent.h		\
+	linux/xtensa/arch_regs.c	\
+	linux/xtensa/get_error.c	\
+	linux/xtensa/get_scno.c		\
+	linux/xtensa/get_syscall_args.c	\
+	linux/xtensa/get_syscall_result.c	\
+	linux/xtensa/ioctls_arch0.h	\
+	linux/xtensa/ioctls_inc0.h	\
+	linux/xtensa/syscallent.h	\
+	linux/xtensa/userent.h		\
+	maint/ioctls_gen.sh		\
+	maint/ioctls_hex.sh		\
+	maint/ioctls_sym.sh		\
+	maint/print_ioctlent.c		\
+	mpers.awk			\
+	mpers.sh			\
+	mpers_test.sh			\
+	mpers_xlat.h			\
+	signalent.sh			\
+	strace-graph			\
+	strace-log-merge		\
+	strace.spec			\
+	syscallent.sh			\
+	$(XLAT_INPUT_FILES)		\
+	$(XLAT_HEADER_FILES)		\
+	xlat/gen.sh			\
+	xlate.el
+
+.PHONY: srpm
+srpm: dist-xz
+	rpmbuild --define '%_srcrpmdir .' -ts $(distdir).tar.xz
+
+$(srcdir)/.version:
+	$(AM_V_GEN)echo $(VERSION) > $@-t && mv $@-t $@
+
+strace_SOURCES_c = \
+	$(filter %.c,$(strace_SOURCES)) $(filter %.c,$(libstrace_a_SOURCES))
+
+sys_func.h: $(patsubst %,$(srcdir)/%,$(strace_SOURCES_c))
+	for f in $^; do \
+		sed -n 's/^SYS_FUNC(.*/extern &;/p' $$f; \
+	done | sort -u > $@
+
+syscallent_names = subcall.h syscallent.h syscallent1.h \
+		   syscallent-n32.h syscallent-n64.h syscallent-o32.h
+syscallent_patterns = $(patsubst %,\%/%,$(syscallent_names))
+syscallent_files = $(filter $(syscallent_patterns),$(EXTRA_DIST))
+
+sen.h: $(patsubst %,$(srcdir)/%,$(syscallent_files))
+	for f in $^; do cat -- $$f; done | \
+		$(srcdir)/generate_sen.sh > $@
+
+dist-hook:
+	$(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version
+
+today = $(shell date +%Y-%m-%d)
+version_regexp = $(subst .,\.,$(VERSION))
+news_check_regexp = 'Noteworthy changes in release $(version_regexp) ($(today))'
+
+news-check: NEWS
+	$(AM_V_GEN)if head -1 $< |				\
+	  grep -x $(news_check_regexp) >/dev/null; then		\
+		:;						\
+	else							\
+		echo >&2 '$<: check failed';			\
+		exit 1;						\
+	fi
+
+ioctlsort_CC = $(CC_FOR_BUILD)
+ioctlsort_DEFS = $(DEFS)
+ioctlsort_INCLUDES = $(DEFAULT_INCLUDES) $(INCLUDES)
+ioctlsort_CPPFLAGS = $(AM_CPPFLAGS) $(CPPFLAGS_FOR_BUILD)
+ioctlsort_CFLAGS = $(AM_CFLAGS) $(CFLAGS_FOR_BUILD)
+ioctlsort_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_FOR_BUILD)
+
+ioctls_inc_h = $(wildcard $(srcdir)/$(OS)/$(ARCH)/ioctls_inc*.h)
+ioctlent_h = $(patsubst $(srcdir)/$(OS)/$(ARCH)/ioctls_inc%,ioctlent%,$(ioctls_inc_h))
+ioctl_redefs_h = $(filter-out ioctl_redefs0.h,$(subst ioctlent,ioctl_redefs,$(ioctlent_h)))
+
+ioctl_redefs%.h: ioctlent%.h ioctlent0.h
+	sort $< > $<-t
+	sort ioctlent0.h | comm -23 $<-t - | \
+		sed -n 's/^{ "\([^"]\+\)", \(0x[[:xdigit:]]\+\) },$$/#ifdef \1\n# undef \1\n# define \1 \2\n#endif/p' \
+		> $@-t
+	rm -f $<-t
+	mv $@-t $@
+
+ioctlent%.h: ioctlsort%
+	./$< > $@
+
+ioctlsort%$(BUILD_EXEEXT): ioctlsort%.o
+	$(ioctlsort_CC) $(ioctlsort_CFLAGS) $(ioctlsort_LDFLAGS) $< -o $@
+
+ioctlsort%.o: ioctls_all%.h $(srcdir)/ioctlsort.c
+	$(ioctlsort_CC) $(ioctlsort_DEFS) $(ioctlsort_INCLUDES) $(ioctlsort_CPPFLAGS) $(ioctlsort_CFLAGS) -DIOCTLSORT_INC=\"$<\" -c -o $@ $(srcdir)/ioctlsort.c
+
+ioctls_all%.h: $(srcdir)/$(OS)/$(ARCH)/ioctls_inc%.h $(srcdir)/$(OS)/$(ARCH)/ioctls_arch%.h
+	cat $^ > $@
+
+BUILT_SOURCES = $(ioctl_redefs_h) $(ioctlent_h) \
+		native_printer_decls.h native_printer_defs.h printers.h sen.h sys_func.h .version
+CLEANFILES    = $(ioctl_redefs_h) $(ioctlent_h) $(mpers_preproc_files) \
+		native_printer_decls.h native_printer_defs.h printers.h sen.h sys_func.h
+DISTCLEANFILES = gnu/stubs-32.h gnu/stubs-x32.h
+
+# defines mpers_source_files
+include mpers.am
+srcdir_mpers_source_files = $(patsubst %,$(srcdir)/%,$(mpers_source_files))
+mpers_preproc_files = $(mpers_source_files:.c=.c.mpers.i)
+
+mpers_NAME =
+mpers_PREFIX = $(mpers_NAME)_
+mpers_DEFS = $(DEFS)
+mpers_INCLUDES = $(DEFAULT_INCLUDES) $(INCLUDES)
+mpers_CPPFLAGS = $(strace_CPPFLAGS) $(CPPFLAGS)
+mpers_sh_opts = $(mpers_DEFS) $(mpers_INCLUDES) $(mpers_CPPFLAGS)
+libmpers_CPPFLAGS = $(strace_CPPFLAGS) -DIN_MPERS
+libmpers_CFLAGS = $(strace_CFLAGS)
+
+# mpers targets
+
+mpers-m%.stamp: $(srcdir_mpers_source_files) | printers.h
+	for f in $^; do \
+		CC="$(CC)" CFLAGS="$(mpers_sh_opts)" \
+		CPP="$(CPP)" CPPFLAGS="$(mpers_sh_opts) -DIN_MPERS -DMPERS_IS_$(mpers_NAME)" \
+		$(srcdir)/mpers.sh -$(mpers_NAME) $$f || exit; \
+	done
+	> $@
+
+m%_type_defs.h: $(srcdir_mpers_source_files)
+	for f in $^; do \
+		sed -n 's/^#include DEF_MPERS_TYPE(\([^)]\+\))/#ifdef MPERS_$(mpers_PREFIX)\1\n# define \1 MPERS_$(mpers_PREFIX)\1\n#endif/p' $$f || exit; \
+	done > $@-t
+	echo '#undef MPERS_PRINTER_NAME' >> $@-t
+	echo '#define MPERS_PRINTER_NAME(printer_name) printer_name' >> $@-t
+	echo '#include "$(mpers_PREFIX)printer_decls.h"' >> $@-t
+	echo '#include MPERS_$(mpers_PREFIX)IOCTL_MACROS' >> $@-t
+	mv $@-t $@
+
+m%_funcs.h: $(srcdir_mpers_source_files)
+	for f in $^; do \
+		sed -n 's/^SYS_FUNC(\([^)]\+\))/#undef sys_\1\n#define sys_\1 $(mpers_PREFIX)sys_\1/p' $$f || exit; \
+	done > $@-t && \
+	echo '#include "sys_func.h"' >> $@-t
+	mv $@-t $@
+
+# printers
+
+%.c.mpers.i: $(srcdir)/%.c
+	$(CPP) -P $(mpers_sh_opts) -DIN_MPERS_BOOTSTRAP $< -o $@
+
+mpers_printer_decl_pattern = ^MPERS_PRINTER_DECL(\([^,)]\+\),[[:space:]]*\([^,)]\+\),[[:space:]]*\([^)]\+\))$$
+
+printers.h: $(mpers_preproc_files)
+	echo '/* Generated by Makefile from $^; do not edit. */' > $@-t
+	echo 'typedef struct {' >> $@-t
+	for f in $^; do \
+		sed -n 's/$(mpers_printer_decl_pattern)/ \1 (*\2)(\3);\n#define \2 MPERS_PRINTER_NAME(\2)\n/p' $$f \
+		|| exit; \
+	done >> $@-t
+	echo '} struct_printers;' >> $@-t
+	echo 'extern const struct_printers *printers;' >> $@-t
+	echo '#define MPERS_PRINTER_NAME(printer_name) printers->printer_name' >> $@-t
+	mv $@-t $@
+
+%_printer_decls.h: $(mpers_preproc_files)
+	echo '/* Generated by Makefile from $^; do not edit. */' > $@-t
+	for f in $^; do \
+		sed -n 's/$(mpers_printer_decl_pattern)/extern \1 $(mpers_PREFIX)\2(\3);/p' $$f \
+		|| exit; \
+	done >> $@-t
+	mv $@-t $@
+
+%_printer_defs.h: $(mpers_preproc_files)
+	echo '/* Generated by Makefile from $^; do not edit. */' > $@-t
+	for f in $^; do \
+		sed -n 's/$(mpers_printer_decl_pattern)/\.\2 = $(mpers_PREFIX)\2,/p' $$f \
+		|| exit; \
+	done >> $@-t
+	mv $@-t $@
+
+native_printer_decls.h native_printer_defs.h: mpers_PREFIX =
+
+if HAVE_M32_MPERS
+
+strace_LDADD += libmpers-m32.a
+noinst_LIBRARIES += libmpers-m32.a
+libmpers_m32_a_SOURCES = $(mpers_source_files)
+libmpers_m32_a_CPPFLAGS = $(libmpers_CPPFLAGS) -DMPERS_IS_m32 -I$(builddir)/mpers-m32
+libmpers_m32_a_CFLAGS = $(libmpers_CFLAGS)
+mpers_m32_targets = mpers-m32.stamp m32_type_defs.h m32_funcs.h m32_printer_decls.h m32_printer_defs.h
+
+BUILT_SOURCES += $(mpers_m32_targets)
+CLEANFILES    += $(mpers_m32_targets)
+
+$(mpers_m32_targets): mpers_NAME = m32
+
+endif # HAVE_M32_MPERS
+
+if HAVE_MX32_MPERS
+
+strace_LDADD += libmpers-mx32.a
+noinst_LIBRARIES += libmpers-mx32.a
+libmpers_mx32_a_SOURCES = $(mpers_source_files)
+libmpers_mx32_a_CPPFLAGS = $(libmpers_CPPFLAGS) -DMPERS_IS_mx32 -I$(builddir)/mpers-mx32
+libmpers_mx32_a_CFLAGS = $(libmpers_CFLAGS)
+mpers_mx32_targets = mpers-mx32.stamp mx32_type_defs.h mx32_funcs.h mx32_printer_decls.h mx32_printer_defs.h
+
+BUILT_SOURCES += $(mpers_mx32_targets)
+CLEANFILES    += $(mpers_mx32_targets)
+
+$(mpers_mx32_targets): mpers_NAME = mx32
+
+endif # HAVE_MX32_MPERS
+
+clean-local:
+	-rm -rf mpers-m32 mpers-mx32
+
+if MAINTAINER_MODE
+
+gen_changelog_start_date = 2009-07-08 20:00
+$(srcdir)/ChangeLog: $(srcdir)/gitlog-to-changelog $(srcdir)/Makefile.in \
+		     $(srcdir)/.version
+	@rm -f $@.new
+	(cd $(srcdir); \
+	 ./gitlog-to-changelog --append-dot \
+	   --since='$(gen_changelog_start_date)'; \
+	 echo; echo; echo 'See ChangeLog-CVS for older changes.' \
+	) > $@.new
+	chmod 444 $@.new
+	mv -f $@.new $@
+
+$(srcdir)/CREDITS: $(srcdir)/CREDITS.in $(srcdir)/.mailmap \
+		   $(srcdir)/Makefile.in $(srcdir)/.version
+	$(AM_V_GEN)							\
+	(								\
+	  cd $(srcdir);							\
+	  sed '/^##/,$$d' CREDITS.in;					\
+	  { sed -n '1,/^##>/d; s/  \+/\t/; s/^./&/p' CREDITS.in;	\
+	    git log --pretty=format:'%aN	%aE';			\
+	  } | LC_ALL=C sort -u						\
+	    | awk -F'\t' '{printf("\t%s <%s>\n",$$1,$$2)}';		\
+	) > $@-t && mv $@-t $@
+
+export TAR_OPTIONS = --owner=0 --group=0 --numeric-owner --mode=go-w,go+rX
+
+endif
diff --git a/strace/NEWS b/strace/NEWS
new file mode 100644
index 0000000..19a870d
--- /dev/null
+++ b/strace/NEWS
@@ -0,0 +1,774 @@
+Noteworthy changes in release ?.?? (????-??-??)
+===============================================
+
+Noteworthy changes in release 4.13 (2016-07-26)
+===============================================
+
+* Improvements
+  * Implemented a general netlink socket parser.
+  * Enhanced decoding of socket addresses.
+  * Enhanced decoding of cmsghdr, msghdr, and mmsghdr structures.
+  * Enhanced decoding of accept, accept4, bind, getpeername, getsockname,
+    ipc, recvfrom, recvmsg, recvmmsg, sendto, sendmmsg, and socketcall syscalls.
+  * Updated lists of AF_*, BPF_MAP_TYPE_*, KEY_*, KEYCTL_*, RWF_*, SS_*,
+    and *_MAGIC constants.
+  * Updated lists of ioctl commands from Linux 4.7.
+
+* Bug fixes
+  * Fixed decoding of pid_t argument of prlimit64 syscall.
+  * Fixed sign extension issues in the parser of struct rusage.
+  * Fixed race condition in decoding of timeout argument of recvmmsg and
+    rt_sigtimedwait syscalls.
+  * Fixed build with fresh linux kernel headers.
+
+Noteworthy changes in release 4.12 (2016-05-31)
+===============================================
+
+* Improvements
+  * Implemented simultaneous use of -p option and tracing of a command.
+    (addresses Debian bug #549942).
+  * Implemented caching of netlink conversations to reduce amount of time
+    spent in decoding socket details in -yy mode.
+  * Implemented -yy mode decoding of protocol:portid pairs associated with
+    netlink socket descriptors.
+  * Implemented decoding of copy_file_range, preadv2, and pwritev2 syscalls.
+  * Implemented dumping of preadv, preadv2, pwritev, pwritev2, and vmsplice
+    syscalls.
+  * Implemented decoding of BTRFS_* and UFFDIO_* ioctl commands.
+  * Enhanced decoding of BLK*, EVIOC*, RTC_*, and VIDIOC_* ioctl commands.
+  * Enhanced decoding of fstatfs, fstatfs64, get_mempolicy, getdents,
+    getdents64, getgroups, getpriority, kill, mbind, migrate_pages, mknod,
+    mknodat, personality, poll, ppoll, quotactl, rt_sigpending,
+    rt_sigqueueinfo, rt_sigtimedwait, rt_tgsigqueueinfo, sched_getaffinity,
+    sched_setaffinity, seccomp, set_mempolicy, setgroups, setpriority, statfs,
+    statfs64, tgkill, waitid, and xattr family syscalls.
+  * Enhanced decoding of getxpid, getxuid, and getxgid syscalls on alpha.
+  * Enhanced decoding of pipe syscall on alpha, ia64, mips, sh, and sparc.
+  * Added decoding of bind, listen, and setsockopt direct syscalls on sparc.
+  * Added decoding of osf_statfs64 and osf_fstatfs64 syscalls on alpha.
+  * Added decoding of fadvise64 and fadvise64_64 on s390.
+  * Updated lists of AF_*, BPF_MAP_TYPE_*, CLONE_*, EPOLL*, IPV6_*, MADV_*,
+    MSG_*, PTRACE_*, SEGV_*, SO_*, SOL_*, *_MAGIC, and quotactl constants.
+  * Updated lists of ioctl commands from Linux 4.6.
+
+* Bug fixes
+  * Fixed build on arc, metag, nios2, or1k, and tile architectures.
+  * Fixed decoding of 32-bit times syscall return value on 64-bit architectures.
+  * Fixed decoding of mlock2 syscall on sparc.
+  * Fixed decoding of osf_shmat syscall on alpha.
+  * Fixed decoding of syscalls unknown to the kernel on s390/s390x.
+    (addresses Debian bug #485979 and Fedora bug #1298294).
+  * Fixed decoding of preadv syscall in case of short read.
+  * Fixed decoding and dumping of readv syscall in case of short read.
+  * Fixed dumping of recvmsg and recvmmsg syscalls in case of short read.
+  * Fixed decoding of mincore syscall's last argument.
+  * Fixed remaining errors in mapping between syscall numbers and numbers
+    of syscall arguments.
+  * Applied various fixes to strace-graph script.
+
+Noteworthy changes in release 4.11 (2015-12-21)
+===============================================
+
+* Changes in behavior
+  * Some syscalls have different names depending on architecture and
+    personality.  In these cases, syscall filtering and printing now
+    consistently uses the names that match corresponding __NR_* kernel
+    macros of the tracee's architecture and personality.
+  * Added strace prefix to all diagnostic messages.
+
+* Improvements
+  * Enhanced and extended test suite.
+  * Implemented reliable tracing of processes whose personality differs
+    from the personality of strace, fixed decoding of 32-bit personality
+    syscalls on 64-bit architectures.
+  * When some data referenced by syscall arguments is irrelevant or cannot
+    be read from tracee's memory, strace now prints its address consistently.
+  * When a syscall is restarted using restart_syscall mechanism, strace now
+    shows the syscall name on architectures that expose this information.
+  * Print values returned by epoll_create1, eventfd, eventfd2, fanotify_init,
+    inotify_init1, perf_event_open, pipe, pipe2, signalfd, signalfd4, socket,
+    socketpair, timerfd, and timerfd_create syscalls, as well as F_DUPFD and
+    F_DUPFD_CLOEXEC fcntl commands, as file descriptors.
+  * Optimized decoding of indirect socket syscalls.
+  * Implemented decoding of nanoseconds along with seconds in stat family
+    syscalls (addresses Fedora bug #1251176).
+  * Implemented decoding of struct statfs.f_flags in statfs syscall.
+  * Implemented decoding of siginfo_t.si_syscall and siginfo_t.si_arch
+    in SIGSYS signal.
+  * Implemented decoding of indirect syscall on mips o32.
+  * Implemented decoding of IPPROTO_IP control messages.
+  * Implemented decoding of setsockopt syscall multicast arguments.
+  * Enhanced decoding of struct sigevent.
+  * Enhanced decoding of block, loop, mtd, ptp, rtc, SG_IO, socket, tty,
+    and v4l2 ioctl syscall arguments.
+  * Enhanced decoding of epoll_create, fcntl, fcntl64, futex, getdents,
+    getdents64, getsockopt, io_*, mount, msgctl, prctl, quotactl, recvfrom,
+    sendfile, setsockopt, and shmctl syscalls.
+  * Implemented decoding of bpf, execveat, ioperm, iopl, kcmp, kexec_file_load,
+    lookup_dcookie, membarrier, memfd_create, mlock2, name_to_handle_at,
+    open_by_handle_at, sched_getattr, sched_setattr, and userfaultfd syscalls.
+  * Updated lists of AF_*, EPOLL_*, FALLOC_FL_*, F_*, INPUT_PROP_*, IPPROTO_*,
+    IPV6_*, IP_*, KEY_*, LOCK_*, MNT_*, MS_*, PACKET_*, PERF_FLAG_*, PF_*,
+    PR_*, PTRACE_O_*, RENAME_*, SCTP_*, SECBIT_*, SO_*, TCP_*, and siginfo_t
+    constants.
+  * Added Nios II architecture support.
+  * Added new syscall entries to match Linux 4.4.
+
+* Bug fixes
+  * Fixed potential short read of strings from tracee's memory.
+  * Fixed -qq option in conjunction with -o option.
+  * Fixed filtering of <unavailable> syscalls.
+  * Fixed decoding of ioctl syscall command on aarch64 and 32-bit architectures
+    with 64-bit aligned structures.
+  * Fixed decoding of eventfd2, epoll_create1, signalfd4, and sync_file_range2
+    syscall flags arguments.
+  * Fixed decoding of 4th argument of clock_nanosleep syscall.
+  * Fixed decoding of getpagesize syscall on m68k.
+  * Fixed decoding of getrandom and seccomp syscalls on aarch64.
+  * Fixed decoding of timezone argument of gettimeofday and settimeofday
+  * syscalls.
+  * Fixed decoding of offset argument of mmap2 syscall on arm, sparc,
+    and sparc64.
+  * Fixed decoding of pipe syscall on alpha and mips.
+  * Fixed decoding of pipe2 syscall on ia64, sh, sparc, and sparc64.
+  * Fixed decoding of signal mask argument of pselect6 syscall on x32.
+  * Fixed decoding of signal mask of rt_sigreturn syscall on aarch64, m68k,
+    and x32.
+  * Fixed decoding of 4th argument of semctl indirect syscall.
+  * Fixed decoding of sa_restorer and sa_mask of sigaction syscall on m68k.
+  * Fixed decoding of statfs64 and fstatfs64 syscalls on arm eabi.
+  * Fixed decoding of struct dirent on x32.
+  * Fixed decoding of times syscall return value on mips n32 and x32.
+  * Fixed decoding of path argument of umount2 syscall
+    (addresses Debian bug #785050).
+  * Worked around a kernel bug in tracing privileged executables.
+  * Fixed various errors in mapping between syscall numbers and associated
+    information like the number of syscall arguments, the name of syscall,
+    and syscall decoder.
+
+Noteworthy changes in release 4.10 (2015-03-06)
+===============================================
+
+* Improvements
+  * Added -yy option to print protocol and address information associated with
+    socket descriptors.
+  * Extended "-e read=set" and "-e write=set" options to cover sendmsg,
+    recvmsg, sendmmsg, and recvmmsg syscalls.
+  * Implemented full 32-bit decoding of ioctl commands
+    (addresses Debian bug #692913 and Fedora bug #902788).
+  * Implemented PTRACE_GETREGS API support on ia64.
+  * Implemented PTRACE_GETREGS API support on mips.
+  * Implemented PTRACE_GETREGSET API support on s390/s390x.
+  * Implemented decoding of getrandom and seccomp syscalls.
+  * Implemented full decoding of 64-bit capability sets.
+  * Implemented decoding of all prctl commands.
+  * Implemented decoding of parametrized ioctl commands.
+  * Implemented decoding of evdev ioctl commands.
+  * Implemented decoding of v4l ioctl commands.
+  * Implemented decoding of SG_IO v4 ioctl commands.
+  * Implemented decoding of FIFREEZE/FITHAW/FITRIM ioctl commands.
+  * Implemented decoding of FALLOC_FL_* fallocate flags.
+  * Implemented decoding of rt_sigreturn signal mask on aarch64,
+    x32, and x86_64.
+  * Enhanced socket decoder to support bluetooth sockets.
+  * Enhanced decoding of unlisted ioctl commands.
+  * Enhanced decoding of getsockopt and setsockopt syscall.
+  * Enhanced decoding of sysinfo syscall.
+  * Enhanced decoding of struct cmsghdr.
+  * Enhanced decoding of wait status.
+  * Enhanced aio support on non-x86 architectures by using external libaio.h.
+  * Added O_TMPFILE to the list of recognized open mode flags.
+  * Updated the list of filesystem type constants that is used in decoding
+    statfs family syscalls.
+  * Updated lists of CAP_*, PR_*, PTRACE_*, SCHED_*, SO_*, SOL_*, SWAP_FLAG_*,
+    and TFD_* constants.
+  * Updated lists of signal constants from Linux 3.19.
+  * Updated lists of errno constants from Linux 3.19.
+  * Updated lists of ioctl commands from Linux 3.9.
+  * Added new syscall entries to match Linux 3.19.
+
+* Bug fixes
+  * Fixed various errors in mapping between syscall numbers and associated
+    information like the number of syscall arguments, the name of syscall,
+    and syscall decoder.
+  * Fixed quoting issues in printing descriptors, filenames, network interface
+    names, struct utsname members, device/volume names of BLK* ioctl commands.
+  * Fixed uid_t/git_t decoding.
+  * Fixed potential out-of-bounds read issues in getdents/getdents64 decoders.
+  * Fixed potential open flags truncation on some architectures.
+  * Fixed decoding of struct ifreq.ifr_name.
+  * Fixed decoding of SIOCSIFNAME ioctl command.
+  * Fixed decoding of RENAME_* renameat2 flags.
+  * Fixed decoding of UTIME_NOW/UTIME_OMIT timeval structures.
+  * Fixed decoding of indirect ipc subcalls on some architectures.
+  * Fixed decoding of fanotify_mark syscall on 32-bit architectures.
+  * Fixed decoding of 32-bit stat structures on 64-bit architectures.
+  * Fixed decoding of 32-bit struct cmsghdr on 64-bit architectures.
+  * Fixed decoding of 32-bit preadv/pwritev offset on 64-bit architectures.
+  * Fixed decoding of sigreturn/rt_sigreturn signal mask on ia64, ppc, ppc64,
+    sparc, sparc64, mips, and s390.
+  * Fixed instruction pointer output (-i option) on architectures that support
+    several personalities.
+  * Fixed behaviour of "-e read=set" and "-e write=set" when read and write
+    sets intersect.
+  * Fixed build on systems where struct sigaction has no sa_restorer member.
+  * Fixed build with uclibc and musl libc.
+
+* Portability
+  * Linux kernel >= 2.5.46 is required.
+    Older versions without a decent PTRACE_SETOPTIONS support will not work.
+  * On mips, linux kernel >= 2.6.15 is required.
+    Older versions without a decent PTRACE_GETREGS support will not work.
+  * On s390 and s390x, linux kernel >= 2.6.27 is required.
+    Older versions without a decent PTRACE_GETREGSET support will not work.
+
+Noteworthy changes in release 4.9 (2014-08-15)
+==============================================
+
+* Changes in behavior
+  * Disabled OABI support on ARM EABI systems by default,
+    added --enable-arm-oabi option to enable it at configure time.
+
+* Improvements
+  * Added experimental -k option to print stack trace after each traced syscall.
+  * Added -w option to produce stats on syscall latency.
+    (addresses Debian bug #457497).
+  * Added ARC architecture support.
+  * Added PTRACE_GETREGS API support on PowerPC.
+  * Enhanced Bionic libc and musl libc support.
+  * Enhanced tracing of x86 personality processes on x86_64 and x32.
+  * Enhanced tracing of ARM personality processes on AArch64.
+  * Enhanced 32/64bit personality detection on PowerPC.
+  * Implemented decoding of add_key, ioprio_get, ioprio_set, kexec_load, keyctl,
+    renameat2, and request_key syscalls.
+  * Robustified decoding of select, pselect, and io_submit syscalls.
+  * Enhanced decoding of delete_module, fanotify_init, fanotify_mark, fcntl,
+    setdomainname, sethostname, setns, and sync_file_range syscalls.
+  * Enhanced decoding of signal bitmasks.
+  * Enhanced decoding of file descriptors.
+  * Enhanced siginfo_t decoding.
+  * Enhanced PF_NETLINK decoding.
+  * Updated CLOCK_* constants
+    (addresses Fedora bug #1088455).
+  * Added new syscall entries to match Linux 3.16.
+
+* Bug fixes
+  * Added shmat and shmdt to the set of memory mapping related syscalls.
+  * Fixed detaching from stopped processes.
+  * Fixed fanotify_mark decoding on 32bit architectures.
+  * Fixed offset decoding in preadv and pwritev syscalls.
+  * Fixed select decoding for glibc in _FORTIFY_SOURCE mode.
+  * Fixed decoding of epoll_ctl syscall with EPOLL_CTL_DEL argument.
+  * Fixed build when <sys/ptrace.h> and <linux/ptrace.h> conflict
+    (addresses Fedora bug #993384).
+  * Miscellaneous corrections in the manual page.
+    (Addresses Debian bug #725987).
+
+Noteworthy changes in release 4.8 (2013-06-03)
+==============================================
+
+* Changes in behavior
+  * In case of normal strace termination, when the trace output is
+    redirected to a pipe, strace now closes it and waits for the pipe
+    process termination before exit.
+
+* Improvements
+  * Implemented tracing using PTRACE_SEIZE API (when available).
+  * Implemented more reliable PTRACE_GETREGSET-based process personality
+    detection on x86-64 and x32 (when available).
+  * Added -e trace=memory option for tracing memory mapping related syscalls.
+  * Documented -b option.
+  * Allowed exit status messages to be suppressed by giving -q option twice.
+  * Added AArch64 architecture support
+    (addresses Debian bug #693074 and Fedora bug #969858).
+  * Added support for OpenRISC 1000, Meta, and Xtensa architectures.
+  * Added tilegx personality support for Tile.
+  * Enhanced support of NOMMU architectures.
+  * Enhanced decoding of getdents, mmap, perf_event_open, ptrace, and
+    quotactl syscalls.
+  * Added new syscall entries to match Linux 3.9.
+  * Regenerated the list of common ioctl names from Linux 3.9.
+  * Updated the list of errno constants.
+  * Updated lists of AF_*, MADV_*, MAP_*, MSG_*, MS_*, PF_*, PR_*,
+    PTRACE_O_*, and TCP_* constants.
+  * Implemented decoding of UBI ioctls.
+  * Removed redundant "*32" ioctl names.
+
+* Bug fixes
+  * Fixed ERESTARTNOINTR leaking to userspace on ancient kernels
+    (addresses Fedora bug #659382).
+  * Fixed kernel release string parsing
+    (addresses Debian bug #702309).
+  * Fixed decoding of *xattr syscalls
+    (addresses Fedora bug #885233).
+  * Fixed handling of files with 64-bit inode numbers by 32-bit strace
+    (addresses Fedora bug #912790).
+  * Fixed tracing forks on SPARC.
+  * Fixed decoding of fadvise64, fallocate, ftruncate64, io_submit, pread,
+    preadv, pwrite, pwritev, readahead, sigaltstack, sync_file_range, sysctl,
+    and truncate64 syscalls.
+  * Fixed categories of multiple syscalls on most of supported architectures.
+  * Fixed decoding of non-native 32-bit personality recv[m]msg syscalls.
+  * Fixed decoding of multiple 32-bit personality syscalls on x32.
+  * Fixed decoding of long long syscall arguments on ARM, MIPS/o32, PowerPC,
+    S390x, and Tile architectures.
+  * Fixed semtimedop decoding on S390x.
+  * Fixed sram_alloc decoding on Blackfin.
+  * Fixed build when process_vm_readv is a stab.
+  * Fixed build with older versions of libaio.h.
+
+Noteworthy changes in release 4.7 (2012-05-02)
+==============================================
+
+* Changes in behavior
+  * strace no longer suspends waitpid until there is a child
+    for waitpid'ing process to collect status from.
+  * strace no longer detaches from a tracee which is supposed
+    to be going to die.
+  * strace now issues a new message: "+++ exited with EXITCODE +++"
+    which shows exact moment strace got exit notification,
+    analogous to existing "+++ killed by SIG +++" message.
+
+* Improvements
+  * Added x32 personality support (x86_64 architecture).
+  * Added -y and -P options to print file descriptor paths and
+    filter by those paths.
+  * Added -I option to control strace interactivity.
+  * Allowed -p option to take comma or whitespace-separated list of PIDs.
+  * Added strace_log_merge script helper to merge timestamped "strace -ff"
+    log files.
+  * Implemented decoding of clock_adjtime, get_robust_list, migrate_pages,
+    preadv, prlimit64, process_vm_readv, process_vm_writev, pwritev,
+    recvmmsg, recvmsg, rt_tgsigqueueinfo, sendmmsg, setns, set_robust_list,
+    sched_rr_get_interval, splice, syslog, tee and vmsplice syscalls.
+  * Enhanced decoding of capget, capset, getrlimit, flistxattr, io_submit,
+    listxattr, setrlimit and swapon syscalls.
+  * Implemented decoding of loop and mtd ioctls.
+  * Added syscall entries for new linux syscalls.
+  * Added syscall entries for direct socket system calls on powerpc.
+  * Updated the list of errno constants.
+  * Updated lists of MSG_*, STA_*, and TCP_* constants.
+  * Regenerated the list of ioctl names from Linux 3.3.
+  * Enhanced switching between processes with different personalities.
+  * Enhanced signals reporting by using short signal names.
+  * Made ERESTART* messages more descriptive.
+  * Made parsing of numbers from strings more robust.
+  * Added support for compat_statfs64 and statfs64.f_flags.
+  * Changed read of data blocks to use single process_vm_readv syscall
+    (when available) instead of several PTRACE_PEEKDATA operations.
+  * Changed read of registers on x86 and x86-64 to use single PTRACE_GETREGS
+    operation instead of several PTRACE_PEEKUSER operations.
+  * Applied various optimizations to make strace work faster.
+
+* Bug fixes
+  * Implemented proper handling of real SIGTRAPs on kernels supporting
+    PTRACE_O_TRACESYSGOOD.
+    (Addresses Fedora bug #162774).
+  * Fixed sockaddr_un.sun_path name in decoded output.
+    (Addresses Debian bug #554946).
+  * Fixed to avoid potential core file clobbering on exit.
+    (Addresses Debian bug #656398).
+  * Fixed a typo in documentation.
+    (Addresses Debian bug #653309).
+  * Fixed decoding of timer id returned by timer_create.
+  * Fixed epoll_create1, epoll_wait and epoll_pwait decoding.
+  * Fixed *at syscalls flags decoding.
+  * Fixed ARM EABI 64-bit syscall's arguments decoding.
+  * Fixed semtimedop decoding on s390.
+  * Fixed osf_sigprocmask decoding on alpha.
+  * Fixed ipc and socket subcall decoding on several architectures.
+  * Corrected syscall entries for epoll_pwait, epoll_create, epoll_ctl,
+    epoll_wait, mincore, mlockall, prctl, reboot, sendfile, sendfile64,
+    sendmsg, sgetmask, ssetmask, swapon, tgkill and tkill syscalls.
+  * Corrected io_* syscall entries on ARM.
+  * Fixed PID prefix printing in "strace -oLOG -ff -p1 -p2 -p3" case.
+  * Fixed logging of unfinished lines in "strace -oLOG -ff" case.
+  * Fixed build when libaio-devel is not available.
+  * Fixed configure checks for PTRACE_* constants.
+  * Fixed compilation warnings remained on several architectures.
+
+* Portability
+  * Removed all non-Linux code.  After years of neglect, that dead code
+    just hampered further strace development.
+  * Linux kernel >= 2.6.18 is recommended.  Older versions might still
+    work but they haven't been thoroughly tested with this release.
+
+Noteworthy changes in release 4.6 (2011-03-15)
+==============================================
+
+* Changes in behavior
+  * Print diagnostic information about changes in personality mode to
+    standard error instead of standard output.
+
+* Improvements
+  * Implemented a new method of following clone, fork, and vfork
+    syscalls using the Linux kernel's explicit facilities for tracing
+    creation of threads and child processes.
+  * Implemented CLONE_PARENT and CLONE_UNTRACED flags handling.
+  * Implemented decoding of TLS syscalls on m68k.
+  * Implemented biarch support on powerpc64.
+  * Implemented biarch support for getrlimit() and setrlimit().
+  * Implemented decoding of struct ucred in getsockopt SO_PEERCRED.
+  * Implemented SOL_SCTP socket options decoding.
+  * Added HDIO_* ioctl names.
+    (Addresses Debian bug #450953).
+  * Added LOOP_* ioctl names.
+  * Updated lists of CLOCK_*, CLONE_*, MS_*, and SOL_* constants
+    to match Linux 2.6.37.
+  * Updated the list of IPPROTO_* constants to match netinet/in.h.
+  * Implemented decoding of HDIO_* and BLK* ioctls.
+  * Added MicroBlaze architecture support.
+  * Added new syscall entries to match Linux 2.6.37.
+  * Regenerated list of ioctl names from Linux 2.6.37.
+  * Enhanced signal notification decoding.
+  * Documented -C and -D options.
+
+* Bug fixes
+  * Fixed fetching syscall arguments on m68k.
+  * Fixed an error when judging whether a process has children.
+  * Fixed get/set_robust_list syscall numbers for powerpc.
+  * Fixed a corner case in printing clone flags.
+  * Fixed cross-compiling issues.
+  * Fixed build issues on powerpc64, SH and SPARC.
+  * Fixed syscall flags of fstatat*, mmap, mmap2, fadvise64*, swapoff,
+    fgetxattr, flistxattr, fremovexattr, epoll_create, fallocate,
+    fanotify_init, and fanotify_mark syscalls.
+  * Fixed decoding of get[ug]id, gete[ug]id and setfs[ug]id return values.
+  * Fixed biarch support in IO dumping.
+  * Fixed raw exit_group decoding.
+  * Fixed decoding of file descriptors on 64-bit architectures.
+  * Fixed a corner case in waitpid handling.
+    (Addresses Red Hat bug #663547).
+  * Fixed stat64 decoding on mips
+    (Addresses Debian bug #599028).
+  * Fixed misleading italics in the manual page.
+    (Addresses Debian bug #589323).
+
+Noteworthy changes in release 4.5.20 (2010-04-13)
+=================================================
+
+* Improvements
+  * Implemented decoding of new linux syscalls: inotify_init1, recvmmsg.
+  * Implemented basic decoding of new linux syscalls: preadv, pwritev,
+    rt_tgsigqueueinfo, perf_event_open.
+  * Enhanced decoding of recently added syscalls on non-x86 architectures
+    by replacing a bare decoder with elaborate parsers enabled earlier
+    for x86/x86-64.
+  * Implemented -C option to combine regular and -c output.
+    (Addresses Debian bug #466196)
+  * Enhanced decoding of mbind and mremap syscalls.
+  * Enhanced SOL_PACKET socket options decoding.
+  * Regenerated list of ioctl names from linux 2.6.33.
+  * Added TILE architecture support.
+
+* Bug fixes
+  * Fixed build with Linux kernel headers 2.6.32-rc5+.
+    (Addresses Debian bug #560516 and Fedora bug #539044)
+  * Fixed build on mips.
+  * Fixed handling of Linux systems without struct statfs64.
+  * Fixed reporting signal mask by sigreturn on powerpc.
+  * Fixed potential stack buffer overflow in select decoder.
+    (Addresses Fedora bug #556678)
+  * Corrected msgsnd indirect ipccall decoding.
+  * Corrected decoding of 64bit syscalls.
+    (Addresses Debian bug #570603)
+  * Corrected getsockopt decoding on architectures where
+    sizeof(long) > sizeof(int).
+    (Addresses Debian bug #494844)
+  * Corrected decoding of epoll_pwait.
+    (Addresses Debian bug #513014)
+  * Corrected handling of killed threads.
+
+Noteworthy changes in release 4.5.19 (2009-10-21)
+=================================================
+
+* Changes in behavior
+  * When command exits, strace now exits with the same exit status.
+    If command is terminated by a signal, strace terminates itself
+    with the same signal, so that strace can be used as a wrapper
+    process transparent to the invoking parent process.
+    When using -p option, the exit status of strace is zero unless
+    there was an unexpected error in doing the tracing.
+    (Addresses Fedora bug #105371 and Debian bug #37665)
+
+* Improvements
+  * Implemented decoding of new Linux syscalls: accept4, dup3,
+    epoll_create1, eventfd2, inotify_init1, pipe2, signalfd4.
+  * Implemented decoding of socket type flags introduced in Linux 2.6.27.
+  * Implemented decoding of accept4 socketcall.
+  * Enhanced prctl decoding.
+  * Enhanced nanosleep decoding.
+  * Enhanced ptrace decoding.
+  * Enhanced futex decoding.
+  * Enhanced CAP_* decoding.
+  * Enhanced SIOCS* ioctls decoding.
+  * Enhanced fcntl F_* flags decoding.
+  * Enhanced semop/semtimedop decoding.
+  * Updated ARM architecture support.
+  * Added Blackfin architecture support.
+  * Added AVR32 architecture support.
+  * Added CRIS architecture support.
+  * Made strace detect when traced process suddenly disappeared.
+
+* Bug fixes
+  * Fixed syscall numbers for tee and sync_file_range.
+    (Addresses Debian bug #503124)
+  * Fixed several bugs in strings decoder, including potential heap
+    memory corruption.
+    (Addresses Fedora bugs #470529, #478324 and #511035)
+  * Marked sendfile(2) as a network syscall.
+    (Addresses Debian bug #509499)
+  * Fixed accept(2) decoding.
+    (Addresses Debian bug #507573)
+  * Fixed sigtimedwait(2) decoding.
+  * Fixed build on ARM EABI.
+    (Addresses Debian bugs #520084 and #535564, and Fedora bug #507576)
+  * Fixed display of 32-bit fcntl(F_SETLK) on 64-bit architectures.
+    (Addresses Red Hat bug #471169)
+  * Fixed display of 32-bit argv array on 64-bit architectures.
+    (Addresses Fedora bug #519480)
+  * Fixed display of 32-bit struct sigaction on 64-bit architectures.
+  * Fixed HPPA architecture support.
+    (Addresses Debian bugs #437928 and #546619)
+
+Changes in 4.5.18
+==============
+* Bug fixes.
+* Support new Linux/PPC system call subpage_prot and PROT_SAO flag.
+* In sigaction system call, display sa_flags value along with SIG_DFL/SIG_IGN.
+
+Changes in 4.5.17
+==============
+* Many bug fixes.
+* -F is now deprecated, -f has traced vfork too on Linux for a long time now.
+* Print O_CLOEXEC, MSG_CMSG_CLOEXEC flag bits.
+* Improved output for prctl system call on Linux.
+* Improved support for Linux/ARM.
+* SA_NOMASK is now spelled SA_NODEFER, and SA_ONESHOT is spelled SA_RESETHAND.
+
+Changes in 4.5.16
+==============
+* Bug fixes.
+* Improved output for delete_module, futex, and mbind system calls on Linux.
+* Improved output for SG_IO ioctls on Linux.
+* Support new Linux system calls move_pages, utimensat, signalfd, timerfd,
+  eventfd, getcpu, epoll_pwait.
+
+Changes in 4.5.15
+==============
+* Bug fixes.
+* Several biarch improvements.
+* Improved output for adjtimex, sysctl, quotactl, mount, umount.
+* Support new Linux system calls *at, inotify*, pselect6, ppoll and unshare.
+
+Changes in 4.5.14
+==============
+* Bug fixes.
+* Accept numeric system calls in -e.
+
+Changes in 4.5.13
+==============
+* Bug fixes.
+* Introduce "-e trace=desc".
+
+Changes in 4.5.12
+==============
+* Bug fixes.
+* Better x86-64 support for IA32 processes.
+* Update PowerPC system calls.
+* Better printing for Linux aio system calls.
+
+Changes in 4.5.11
+==============
+* Quick fix release for build issues.
+* One fix for Linux/ARM system call table.
+
+Changes in 4.5.10
+==============
+* Bug fixes.
+* Print fault address for SIGSEGV/SIGBUS signals when available.
+
+Changes in 4.5.9
+==============
+* Bug fixes.
+* Improve socket ioctl printing.
+* Update Linux/IA64 syscall list.
+* Fix Linux/x86-64 syscall argument extraction for 32-bit processes.
+* Improve mount flags printing.
+* Support symbolic printing of x86_64 arch_prctl parameters.
+
+Changes in 4.5.8
+==============
+* Bug fixes.
+* Update syscall tables for Alpha, ARM, HPPA.
+* Support new Linux syscalls mbind, set_mempolicy, get_mempolicy, waitid.
+* Support Linux syscalls fadvise64, fadvise64_64, and epoll_*.
+* Improve ioctl command name matching.
+* Print RTC_* ioctl structure contents.
+* Support newer RLIMIT_* values.
+* Print struct cmsghdr details in sendmsg.
+
+Changes in 4.5.7
+==============
+* Bug fixes.
+* Print attribute values in *xattr system calls on Linux.
+* Include pread and pwrite calls in -e read and -e write tracing.
+* Update SO_* and IP_* value lists and add IPV6_* values for socket options.
+* Print clock_t values symbolically in Linux clock_* system calls.
+
+Changes in 4.5.6
+==============
+* Bug fixes, Linux ioctl updates.
+* David Miller contributed support for Linux/SPARC64.
+
+Changes in 4.5.5
+==============
+* Just bug fixes.
+
+Changes in 4.5.4
+==============
+* Update Linux ioctl lists.
+* Update PF_* and AF_* value lists.
+* The 4.5.3 -p behavior for NPTL threads applies only under -f, and got fixed.
+
+Changes in 4.5.3
+==============
+* Bug fixes.
+* On Linux using NPTL threads, -p will now attach to all threads in a process.
+* Handle new mq_* system calls in Linux 2.6.6 and later.
+
+Changes in 4.5.2
+==============
+* Bug fixes.
+* Report some new VM_* bit values on Linux.
+* Better output for Linux sched_* system calls.
+
+Changes in 4.5.1
+==============
+* Bug fixes.
+* Display multiple ioctl name matches on Linux.
+
+Changes in 4.5
+==============
+* New port to AMD's x86-64 architecture. One strace binary can
+  handle both new x86-64 and old i386 processes.
+* Fixed support for LFS64 calls.
+* New switch -E to add/remove environment variables for the command.
+* Merged s390/s390x port.
+* Trace an unbounded number of processes.
+* Handle numerous new system calls in Linux 2.5, and new threads semantics.
+* Fixed bugs with attach/detach leaving things stopped.
+* Fixed traced process seeing ECHILD despite live, traced children
+  in waitpid calls with WNOHANG.
+* Stuart Menefy contributed a port to Linux/SH.
+* Stephen Thomas contributed a port to Linux/SH64.
+* Many other bug fixes.
+
+Changes in 4.4
+==============
+* Fix Linux/ia64 support, looks like someone renamed a few things on us
+* Fix the ioctl setup for Linux, turned out it did not really work.
+  Improve the ioctl extracter as well so we decode some more ones.
+
+Changes in 4.3.1
+================
+* compile fixes for Linux/mips
+
+Changes in 4.3
+==============
+* Linux ia64 and hppa ports added
+* The usual Linux syscall updates (includes 32bit uid/gid support),
+* Linux ioctl list updated
+* Support IPv6 scope ids
+* FreeBSD/i386 port added
+* UnixWare and Solaris updates
+* Better support for tracing multithreaded processes in Linux
+
+Changes in 4.2
+==============
+* Compiles on glibc2.0 systems again
+* Linux/S390 port added
+* The usual Linux syscall updates
+* we can follow fork on arm now
+
+Changes in 4.1
+================
+* Linux/MIPS port added
+* Lots of Linux updates again
+* Improved IPv6 support
+* Add strace-graph
+
+Changes in 4.0.1
+================
+* Minor bugfixes
+* Compiles on glibc2.0 systems again
+
+Changes in 4.0
+==============
+* Get stat structure properly on Linux 64bit archs
+* Personalities work again
+* Compile correctly on SunOS again
+* IRIX64 updates
+* Solaris updates
+
+Changes in 3.99.1
+=================
+* Linux (ultra)sparc fixes
+* Linux alpha fixes
+* Minor cleanups
+
+Changes in 3.99
+===============
+* New maintainer
+* add support for more Linux architectures (powerpc, sparc, arm)
+* support lots more Linux syscalls
+* fix signal handling
+* add IPX and IPIP support
+* check stray syscall after execv
+* fix hanging children
+
+Changes in version 3.1
+======================
+
+* Irix5 is supported
+* Linux 68k is supported
+* Linux alpha is supported
+* configure is upgraded to autoconf 2.x
+* using -f in combination with -e now works correctly
+* output can be piped to a program
+* tracing setuid programs works better
+* it is now reasonable to install strace setuid to root in some circumstances
+* new useful tracing names like file and process to trace whole
+  classes of system calls, e.g. -efile traces all system calls that
+  take a file name as an argument
+* IPC calls on SunOS 4.1.x are decoded
+* Linux program memory is reliably dereferenced
+* Linux decodes at least the name of all syscalls as of pre2.0.4
+* various cosmetic changes and bug fixes
+
+Changes from versions 2.x to version 3.0
+========================================
+
+* filename arguments are neither abbreviated nor stringified
+* string arguments are now true C strings using octal instead of hex by default
+* preprocessor constants are never shortened (e.g. was RDONLY => now O_RDONLY)
+* by default the output for multiple processes now goes into one file
+* all structures, vectors, bitsets, etc. use consistent output formats
+* the -c option now means count calls, -i does what the old -c used to do
+
+New Features in version 3.0
+===========================
+
+* non-ascii strings can be optionally printed entirely in hex
+* the output format is readable when mutiple processes are generating output
+* exit values are printed in an alignment column
+* is is possible to suppress messages about attaching and detaching
+* various tracing features can be enabled on a per syscall/signal/desc basis
+* selective tracing of syscalls
+* selective printing of syscall structures
+* selective abbreviation of long structures on a per syscall basis
+* selective printing of raw syscall arguments and results
+* selective tracing of signals
+* selective dumping of all I/O read from file descriptors
+* selective dumping of all I/O written to file descriptors
+* optional counting of time, calls, and errors for each syscall
diff --git a/strace/NOTICE b/strace/NOTICE
new file mode 100644
index 0000000..e9078d3
--- /dev/null
+++ b/strace/NOTICE
@@ -0,0 +1,29 @@
+Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+Copyright (c) 1995, 1996 Michael Elizabeth Chastain <mec@duracef.shout.net>
+Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+Copyright (C) 1998-2001 Wichert Akkerman <wakkerma@deephackmode.org>
+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.
diff --git a/strace/README b/strace/README
new file mode 100644
index 0000000..ae80800
--- /dev/null
+++ b/strace/README
@@ -0,0 +1,24 @@
+This is strace, a system call tracer for Linux.
+
+strace is released under a Berkeley-style license at the request
+of Paul Kranenburg.
+
+See the file CREDITS for a list of authors and other contributors.
+See the file INSTALL for compilation and installation instructions.
+See the file NEWS for information on what has changed in recent versions.
+
+The project's homepage is at
+	https://sourceforge.net/projects/strace/
+
+strace has a mailing list:
+	strace-devel@lists.sourceforge.net.
+
+System requirements:
+	* Linux kernel >= 2.6.18 is recommended.  Older versions might still work
+	  but they haven't been thoroughly tested with this release.
+	* Linux kernel >= 2.5.46 is required.
+	  Older versions without a decent PTRACE_SETOPTIONS support will not work.
+	* On mips, linux kernel >= 2.6.15 is required.
+	  Older versions without a decent PTRACE_GETREGS support will not work.
+	* On s390 and s390x, linux kernel >= 2.6.27 is required.
+	  Older versions without a decent PTRACE_GETREGSET support will not work.
diff --git a/strace/README-hacking b/strace/README-hacking
new file mode 100644
index 0000000..16d12c0
--- /dev/null
+++ b/strace/README-hacking
@@ -0,0 +1,32 @@
+Requirements
+============
+If you use the GIT version of strace there will be some files missing
+that you need to build strace.  These files are generated by tools from
+the GNU Autoconf and Automake packages.
+
+Note: rather than run `autoreconf' directly, use the `./bootstrap' script.
+
+
+No more ChangeLog file
+======================
+Do not create or modify the ChangeLog files.  Starting at 2009-07-09, the
+policy changed.  Before, we would insert the exact same text (or worse,
+sometimes slightly differing) into both the ChangeLog file and the commit
+log.  Now we put that information only in the commit log, and generate
+the top-level ChangeLog file from logs at "make dist" time.  As such,
+there are strict requirements on the form of the commit log messages.
+
+
+Commit log requirements
+=======================
+Each commit log should always start with a one-line summary, the second
+line should be blank, and the remaining lines are usually ChangeLog-style
+entries for all affected files, except the leading TABs which should
+be omitted.
+
+
+Documentation
+=============
+All noteworthy changes should be mentioned in NEWS.  All changes in strace
+command interface should be reflected in the man page.  New options should
+be documented both in -h output and in the man page.
diff --git a/strace/README-linux-ptrace b/strace/README-linux-ptrace
new file mode 100644
index 0000000..97e2c01
--- /dev/null
+++ b/strace/README-linux-ptrace
@@ -0,0 +1,542 @@
+This document describes Linux ptrace implementation in Linux kernels
+version 3.0.0. (Update this notice if you update the document
+to reflect newer kernels).
+
+
+		Ptrace userspace API.
+
+Ptrace API (ab)uses standard Unix parent/child signaling over waitpid.
+An unfortunate effect of it is that resulting API is complex and has
+subtle quirks. This document aims to describe these quirks.
+
+Debugged processes (tracees) first need to be attached to the debugging
+process (tracer). Attachment and subsequent commands are per-thread: in
+multi-threaded process, every thread can be individually attached to a
+(potentially different) tracer, or left not attached and thus not
+debugged. Therefore, "tracee" always means "(one) thread", never "a
+(possibly multi-threaded) process". Ptrace commands are always sent to
+a specific tracee using ptrace(PTRACE_foo, pid, ...), where pid is a
+TID of the corresponding Linux thread.
+
+After attachment, each tracee can be in two states: running or stopped.
+
+There are many kinds of states when tracee is stopped, and in ptrace
+discussions they are often conflated. Therefore, it is important to use
+precise terms.
+
+In this document, any stopped state in which tracee is ready to accept
+ptrace commands from the tracer is called ptrace-stop. Ptrace-stops can
+be further subdivided into signal-delivery-stop, group-stop,
+syscall-stop and so on. They are described in detail later.
+
+
+	1.x Death under ptrace.
+
+When a (possibly multi-threaded) process receives a killing signal (a
+signal set to SIG_DFL and whose default action is to kill the process),
+all threads exit. Tracees report their death to the tracer(s). This is
+not a ptrace-stop (because tracer can't query tracee status such as
+register contents, cannot restart tracee etc) but the notification
+about this event is delivered through waitpid API similarly to
+ptrace-stop.
+
+Note that killing signal will first cause signal-delivery-stop (on one
+tracee only), and only after it is injected by tracer (or after it was
+dispatched to a thread which isn't traced), death from signal will
+happen on ALL tracees within multi-threaded process.
+
+SIGKILL operates similarly, with exceptions. No signal-delivery-stop is
+generated for SIGKILL and therefore tracer can't suppress it. SIGKILL
+kills even within syscalls (syscall-exit-stop is not generated prior to
+death by SIGKILL). The net effect is that SIGKILL always kills the
+process (all its threads), even if some threads of the process are
+ptraced.
+
+Tracer can kill a tracee with ptrace(PTRACE_KILL, pid, 0, 0). This
+operation is deprecated, use kill/tgkill(SIGKILL) instead.
+
+^^^ Oleg prefers to deprecate it instead of describing (and needing to
+support) PTRACE_KILL's quirks.
+
+When tracee executes exit syscall, it reports its death to its tracer.
+Other threads are not affected.
+
+When any thread executes exit_group syscall, every tracee in its thread
+group reports its death to its tracer.
+
+If PTRACE_O_TRACEEXIT option is on, PTRACE_EVENT_EXIT will happen
+before actual death. This applies to exits on exit syscall, group_exit
+syscall, signal deaths (except SIGKILL), and when threads are torn down
+on execve in multi-threaded process.
+
+Tracer cannot assume that ptrace-stopped tracee exists. There are many
+scenarios when tracee may die while stopped (such as SIGKILL).
+Therefore, tracer must always be prepared to handle ESRCH error on any
+ptrace operation. Unfortunately, the same error is returned if tracee
+exists but is not ptrace-stopped (for commands which require stopped
+tracee), or if it is not traced by process which issued ptrace call.
+Tracer needs to keep track of stopped/running state, and interpret
+ESRCH as "tracee died unexpectedly" only if it knows that tracee has
+been observed to enter ptrace-stop. Note that there is no guarantee
+that waitpid(WNOHANG) will reliably report tracee's death status if
+ptrace operation returned ESRCH. waitpid(WNOHANG) may return 0 instead.
+IOW: tracee may be "not yet fully dead" but already refusing ptrace ops.
+
+Tracer can not assume that tracee ALWAYS ends its life by reporting
+WIFEXITED(status) or WIFSIGNALED(status).
+
+??? or can it? Do we include such a promise into ptrace API?
+
+
+	1.x Stopped states.
+
+When running tracee enters ptrace-stop, it notifies its tracer using
+waitpid API. Tracer should use waitpid family of syscalls to wait for
+tracee to stop. Most of this document assumes that tracer waits with:
+
+	pid = waitpid(pid_or_minus_1, &status, __WALL);
+
+Ptrace-stopped tracees are reported as returns with pid > 0 and
+WIFSTOPPED(status) == true.
+
+??? Do we require __WALL usage, or will just using 0 be ok? Are the
+rules different if user wants to use waitid? Will waitid require
+WEXITED?
+
+__WALL value does not include WSTOPPED and WEXITED bits, but implies
+their functionality.
+
+Setting of WCONTINUED bit in waitpid flags is not recommended: the
+continued state is per-process and consuming it can confuse real parent
+of the tracee.
+
+Use of WNOHANG bit in waitpid flags may cause waitpid return 0 ("no
+wait results available yet") even if tracer knows there should be a
+notification. Example: kill(tracee, SIGKILL); waitpid(tracee, &status,
+__WALL | WNOHANG);
+
+??? waitid usage? WNOWAIT?
+
+??? describe how wait notifications queue (or not queue)
+
+The following kinds of ptrace-stops exist: signal-delivery-stops,
+group-stop, PTRACE_EVENT stops, syscall-stops [, SINGLESTEP, SYSEMU,
+SYSEMU_SINGLESTEP]. They all are reported as waitpid result with
+WIFSTOPPED(status) == true. They may be differentiated by checking
+(status >> 8) value, and if looking at (status >> 8) value doesn't
+resolve ambiguity, by querying PTRACE_GETSIGINFO. (Note:
+WSTOPSIG(status) macro returns ((status >> 8) & 0xff) value).
+
+
+	1.x.x Signal-delivery-stop
+
+When (possibly multi-threaded) process receives any signal except
+SIGKILL, kernel selects a thread which handles the signal (if signal is
+generated with t[g]kill, thread selection is done by user). If selected
+thread is traced, it enters signal-delivery-stop. By this point, signal
+is not yet delivered to the process, and can be suppressed by tracer.
+If tracer doesn't suppress the signal, it passes signal to tracee in
+the next ptrace request. This second step of signal delivery is called
+"signal injection" in this document. Note that if signal is blocked,
+signal-delivery-stop doesn't happen until signal is unblocked, with the
+usual exception that SIGSTOP can't be blocked.
+
+Signal-delivery-stop is observed by tracer as waitpid returning with
+WIFSTOPPED(status) == true, WSTOPSIG(status) == signal. If
+WSTOPSIG(status) == SIGTRAP, this may be a different kind of
+ptrace-stop - see "Syscall-stops" and "execve" sections below for
+details. If WSTOPSIG(status) == stopping signal, this may be a
+group-stop - see below.
+
+
+	1.x.x Signal injection and suppression.
+
+After signal-delivery-stop is observed by tracer, tracer should restart
+tracee with
+
+	ptrace(PTRACE_rest, pid, 0, sig)
+
+call, where PTRACE_rest is one of the restarting ptrace ops. If sig is
+0, then signal is not delivered. Otherwise, signal sig is delivered.
+This operation is called "signal injection" in this document, to
+distinguish it from signal-delivery-stop.
+
+Note that sig value may be different from WSTOPSIG(status) value -
+tracer can cause a different signal to be injected.
+
+Note that suppressed signal still causes syscalls to return
+prematurely. Kernel should always restart the syscall in this case:
+tracer would observe a new syscall-enter-stop for the same syscall,
+or, in case of syscalls returning ERESTART_RESTARTBLOCK,
+tracer would observe a syscall-enter-stop for restart_syscall(2)
+syscall. There may still be bugs in this area which cause some syscalls
+to instead return with -EINTR even though no observable signal
+was injected to the tracee.
+
+This is a cause of confusion among ptrace users. One typical scenario
+is that tracer observes group-stop, mistakes it for
+signal-delivery-stop, restarts tracee with ptrace(PTRACE_rest, pid, 0,
+stopsig) with the intention of injecting stopsig, but stopsig gets
+ignored and tracee continues to run.
+
+SIGCONT signal has a side effect of waking up (all threads of)
+group-stopped process. This side effect happens before
+signal-delivery-stop. Tracer can't suppress this side-effect (it can
+only suppress signal injection, which only causes SIGCONT handler to
+not be executed in the tracee, if such handler is installed). In fact,
+waking up from group-stop may be followed by signal-delivery-stop for
+signal(s) *other than* SIGCONT, if they were pending when SIGCONT was
+delivered. IOW: SIGCONT may be not the first signal observed by the
+tracee after it was sent.
+
+Stopping signals cause (all threads of) process to enter group-stop.
+This side effect happens after signal injection, and therefore can be
+suppressed by tracer.
+
+PTRACE_GETSIGINFO can be used to retrieve siginfo_t structure which
+corresponds to delivered signal. PTRACE_SETSIGINFO may be used to
+modify it. If PTRACE_SETSIGINFO has been used to alter siginfo_t,
+si_signo field and sig parameter in restarting command must match,
+otherwise the result is undefined.
+
+
+	1.x.x Group-stop
+
+When a (possibly multi-threaded) process receives a stopping signal,
+all threads stop. If some threads are traced, they enter a group-stop.
+Note that stopping signal will first cause signal-delivery-stop (on one
+tracee only), and only after it is injected by tracer (or after it was
+dispatched to a thread which isn't traced), group-stop will be
+initiated on ALL tracees within multi-threaded process. As usual, every
+tracee reports its group-stop separately to corresponding tracer.
+
+Group-stop is observed by tracer as waitpid returning with
+WIFSTOPPED(status) == true, WSTOPSIG(status) == signal. The same result
+is returned by some other classes of ptrace-stops, therefore the
+recommended practice is to perform
+
+	ptrace(PTRACE_GETSIGINFO, pid, 0, &siginfo)
+
+call. The call can be avoided if signal number is not SIGSTOP, SIGTSTP,
+SIGTTIN or SIGTTOU - only these four signals are stopping signals. If
+tracer sees something else, it can't be group-stop. Otherwise, tracer
+needs to call PTRACE_GETSIGINFO. If PTRACE_GETSIGINFO fails with
+EINVAL, then it is definitely a group-stop. (Other failure codes are
+possible, such as ESRCH "no such process" if SIGKILL killed the tracee).
+
+As of kernel 2.6.38, after tracer sees tracee ptrace-stop and until it
+restarts or kills it, tracee will not run, and will not send
+notifications (except SIGKILL death) to tracer, even if tracer enters
+into another waitpid call.
+
+Currently, it causes a problem with transparent handling of stopping
+signals: if tracer restarts tracee after group-stop, SIGSTOP is
+effectively ignored: tracee doesn't remain stopped, it runs. If tracer
+doesn't restart tracee before entering into next waitpid, future
+SIGCONT will not be reported to the tracer. Which would make SIGCONT to
+have no effect.
+
+
+	1.x.x PTRACE_EVENT stops
+
+If tracer sets TRACE_O_TRACEfoo options, tracee will enter ptrace-stops
+called PTRACE_EVENT stops.
+
+PTRACE_EVENT stops are observed by tracer as waitpid returning with
+WIFSTOPPED(status) == true, WSTOPSIG(status) == SIGTRAP. Additional bit
+is set in a higher byte of status word: value ((status >> 8) & 0xffff)
+will be (SIGTRAP | PTRACE_EVENT_foo << 8). The following events exist:
+
+PTRACE_EVENT_VFORK - stop before return from vfork/clone+CLONE_VFORK.
+When tracee is continued after this, it will wait for child to
+exit/exec before continuing its execution (IOW: usual behavior on
+vfork).
+
+PTRACE_EVENT_FORK - stop before return from fork/clone+SIGCHLD
+
+PTRACE_EVENT_CLONE - stop before return from clone
+
+PTRACE_EVENT_VFORK_DONE - stop before return from
+vfork/clone+CLONE_VFORK, but after vfork child unblocked this tracee by
+exiting or exec'ing.
+
+For all four stops described above: stop occurs in parent, not in newly
+created thread. PTRACE_GETEVENTMSG can be used to retrieve new thread's
+tid.
+
+PTRACE_EVENT_EXEC - stop before return from exec.
+
+PTRACE_EVENT_EXIT - stop before exit (including death from exit_group),
+signal death, or exit caused by execve in multi-threaded process.
+PTRACE_GETEVENTMSG returns exit status. Registers can be examined
+(unlike when "real" exit happens). The tracee is still alive, it needs
+to be PTRACE_CONTed or PTRACE_DETACHed to finish exit.
+
+PTRACE_GETSIGINFO on PTRACE_EVENT stops returns si_signo = SIGTRAP,
+si_code = (event << 8) | SIGTRAP.
+
+
+	1.x.x Syscall-stops
+
+If tracee was restarted by PTRACE_SYSCALL, tracee enters
+syscall-enter-stop just prior to entering any syscall. If tracer
+restarts it with PTRACE_SYSCALL, tracee enters syscall-exit-stop when
+syscall is finished, or if it is interrupted by a signal. (That is,
+signal-delivery-stop never happens between syscall-enter-stop and
+syscall-exit-stop, it happens *after* syscall-exit-stop).
+
+Other possibilities are that tracee may stop in a PTRACE_EVENT stop,
+exit (if it entered exit or exit_group syscall), be killed by SIGKILL,
+or die silently (if execve syscall happened in another thread).
+
+Syscall-enter-stop and syscall-exit-stop are observed by tracer as
+waitpid returning with WIFSTOPPED(status) == true, WSTOPSIG(status) ==
+SIGTRAP. If PTRACE_O_TRACESYSGOOD option was set by tracer, then
+WSTOPSIG(status) == (SIGTRAP | 0x80).
+
+Syscall-stops can be distinguished from signal-delivery-stop with
+SIGTRAP by querying PTRACE_GETSIGINFO: si_code <= 0 if sent by usual
+suspects like [tg]kill/sigqueue/etc; or = SI_KERNEL (0x80) if sent by
+kernel, whereas syscall-stops have si_code = SIGTRAP or (SIGTRAP |
+0x80). However, syscall-stops happen very often (twice per syscall),
+and performing PTRACE_GETSIGINFO for every syscall-stop may be somewhat
+expensive.
+
+Some architectures allow to distinguish them by examining registers.
+For example, on x86 rax = -ENOSYS in syscall-enter-stop. Since SIGTRAP
+(like any other signal) always happens *after* syscall-exit-stop, and
+at this point rax almost never contains -ENOSYS, SIGTRAP looks like
+"syscall-stop which is not syscall-enter-stop", IOW: it looks like a
+"stray syscall-exit-stop" and can be detected this way. But such
+detection is fragile and is best avoided.
+
+Using PTRACE_O_TRACESYSGOOD option is a recommended method, since it is
+reliable and does not incur performance penalty.
+
+Syscall-enter-stop and syscall-exit-stop are indistinguishable from
+each other by tracer. Tracer needs to keep track of the sequence of
+ptrace-stops in order to not misinterpret syscall-enter-stop as
+syscall-exit-stop or vice versa. The rule is that syscall-enter-stop is
+always followed by syscall-exit-stop, PTRACE_EVENT stop or tracee's
+death - no other kinds of ptrace-stop can occur in between.
+
+If after syscall-enter-stop tracer uses restarting command other than
+PTRACE_SYSCALL, syscall-exit-stop is not generated.
+
+PTRACE_GETSIGINFO on syscall-stops returns si_signo = SIGTRAP, si_code
+= SIGTRAP or (SIGTRAP | 0x80).
+
+
+	1.x.x SINGLESTEP, SYSEMU, SYSEMU_SINGLESTEP
+
+??? document PTRACE_SINGLESTEP, PTRACE_SYSEMU, PTRACE_SYSEMU_SINGLESTEP
+
+
+	1.x Informational and restarting ptrace commands.
+
+Most ptrace commands (all except ATTACH, TRACEME, KILL) require tracee
+to be in ptrace-stop, otherwise they fail with ESRCH.
+
+When tracee is in ptrace-stop, tracer can read and write data to tracee
+using informational commands. They leave tracee in ptrace-stopped state:
+
+longv = ptrace(PTRACE_PEEKTEXT/PEEKDATA/PEEKUSER, pid, addr, 0);
+	ptrace(PTRACE_POKETEXT/POKEDATA/POKEUSER, pid, addr, long_val);
+	ptrace(PTRACE_GETREGS/GETFPREGS, pid, 0, &struct);
+	ptrace(PTRACE_SETREGS/SETFPREGS, pid, 0, &struct);
+	ptrace(PTRACE_GETSIGINFO, pid, 0, &siginfo);
+	ptrace(PTRACE_SETSIGINFO, pid, 0, &siginfo);
+	ptrace(PTRACE_GETEVENTMSG, pid, 0, &long_var);
+	ptrace(PTRACE_SETOPTIONS, pid, 0, PTRACE_O_flags);
+
+Note that some errors are not reported. For example, setting siginfo
+may have no effect in some ptrace-stops, yet the call may succeed
+(return 0 and don't set errno).
+
+ptrace(PTRACE_SETOPTIONS, pid, 0, PTRACE_O_flags) affects one tracee.
+Current flags are replaced. Flags are inherited by new tracees created
+and "auto-attached" via active PTRACE_O_TRACE[V]FORK or
+PTRACE_O_TRACECLONE options.
+
+Another group of commands makes ptrace-stopped tracee run. They have
+the form:
+
+	ptrace(PTRACE_cmd, pid, 0, sig);
+
+where cmd is CONT, DETACH, SYSCALL, SINGLESTEP, SYSEMU, or
+SYSEMU_SINGLESTEP. If tracee is in signal-delivery-stop, sig is the
+signal to be injected. Otherwise, sig may be ignored.
+
+
+	1.x Attaching and detaching
+
+A thread can be attached to tracer using ptrace(PTRACE_ATTACH, pid, 0,
+0) call. This also sends SIGSTOP to this thread. If tracer wants this
+SIGSTOP to have no effect, it needs to suppress it. Note that if other
+signals are concurrently sent to this thread during attach, tracer may
+see tracee enter signal-delivery-stop with other signal(s) first! The
+usual practice is to reinject these signals until SIGSTOP is seen, then
+suppress SIGSTOP injection. The design bug here is that attach and
+concurrent SIGSTOP are racing and SIGSTOP may be lost.
+
+??? Describe how to attach to a thread which is already group-stopped.
+
+Since attaching sends SIGSTOP and tracer usually suppresses it, this
+may cause stray EINTR return from the currently executing syscall in
+the tracee, as described in "signal injection and suppression" section.
+
+ptrace(PTRACE_TRACEME, 0, 0, 0) request turns current thread into a
+tracee. It continues to run (doesn't enter ptrace-stop). A common
+practice is to follow ptrace(PTRACE_TRACEME) with raise(SIGSTOP) and
+allow parent (which is our tracer now) to observe our
+signal-delivery-stop.
+
+If PTRACE_O_TRACE[V]FORK or PTRACE_O_TRACECLONE options are in effect,
+then children created by (vfork or clone(CLONE_VFORK)), (fork or
+clone(SIGCHLD)) and (other kinds of clone) respectively are
+automatically attached to the same tracer which traced their parent.
+SIGSTOP is delivered to them, causing them to enter
+signal-delivery-stop after they exit syscall which created them.
+
+Detaching of tracee is performed by ptrace(PTRACE_DETACH, pid, 0, sig).
+PTRACE_DETACH is a restarting operation, therefore it requires tracee
+to be in ptrace-stop. If tracee is in signal-delivery-stop, signal can
+be injected. Othervice, sig parameter may be silently ignored.
+
+If tracee is running when tracer wants to detach it, the usual solution
+is to send SIGSTOP (using tgkill, to make sure it goes to the correct
+thread), wait for tracee to stop in signal-delivery-stop for SIGSTOP
+and then detach it (suppressing SIGSTOP injection). Design bug is that
+this can race with concurrent SIGSTOPs. Another complication is that
+tracee may enter other ptrace-stops and needs to be restarted and
+waited for again, until SIGSTOP is seen. Yet another complication is to
+be sure that tracee is not already ptrace-stopped, because no signal
+delivery happens while it is - not even SIGSTOP.
+
+??? Describe how to detach from a group-stopped tracee so that it
+    doesn't run, but continues to wait for SIGCONT.
+
+If tracer dies, all tracees are automatically detached and restarted,
+unless they were in group-stop. Handling of restart from group-stop is
+currently buggy, but "as planned" behavior is to leave tracee stopped
+and waiting for SIGCONT. If tracee is restarted from
+signal-delivery-stop, pending signal is injected.
+
+
+	1.x execve under ptrace.
+
+During execve, kernel destroys all other threads in the process, and
+resets execve'ing thread tid to tgid (process id). This looks very
+confusing to tracers:
+
+All other threads stop in PTRACE_EXIT stop, if requested by active
+ptrace option. Then all other threads except thread group leader report
+death as if they exited via exit syscall with exit code 0. Then
+PTRACE_EVENT_EXEC stop happens, if requested by active ptrace option
+(on which tracee - leader? execve-ing one?).
+
+The execve-ing tracee changes its pid while it is in execve syscall.
+(Remember, under ptrace 'pid' returned from waitpid, or fed into ptrace
+calls, is tracee's tid). That is, pid is reset to process id, which
+coincides with thread group leader tid.
+
+If thread group leader has reported its death by this time, for tracer
+this looks like dead thread leader "reappears from nowhere". If thread
+group leader was still alive, for tracer this may look as if thread
+group leader returns from a different syscall than it entered, or even
+"returned from syscall even though it was not in any syscall". If
+thread group leader was not traced (or was traced by a different
+tracer), during execve it will appear as if it has become a tracee of
+the tracer of execve'ing tracee. All these effects are the artifacts of
+pid change.
+
+PTRACE_O_TRACEEXEC option is the recommended tool for dealing with this
+case. It enables PTRACE_EVENT_EXEC stop which occurs before execve
+syscall return.
+
+Pid change happens before PTRACE_EVENT_EXEC stop, not after.
+
+When tracer receives PTRACE_EVENT_EXEC stop notification, it is
+guaranteed that except this tracee and thread group leader, no other
+threads from the process are alive.
+
+On receiving this notification, tracer should clean up all its internal
+data structures about all threads of this process, and retain only one
+data structure, one which describes single still running tracee, with
+pid = tgid = process id.
+
+Currently, there is no way to retrieve former pid of execve-ing tracee.
+If tracer doesn't keep track of its tracees' thread group relations, it
+may be unable to know which tracee  execve-ed and therefore no longer
+exists under old pid due to pid change.
+
+Example: two threads execve at the same time:
+
+  ** we get syscall-entry-stop in thread 1: **
+ PID1 execve("/bin/foo", "foo" <unfinished ...>
+  ** we issue PTRACE_SYSCALL for thread 1 **
+  ** we get syscall-entry-stop in thread 2: **
+ PID2 execve("/bin/bar", "bar" <unfinished ...>
+  ** we issue PTRACE_SYSCALL for thread 2 **
+  ** we get PTRACE_EVENT_EXEC for PID0, we issue PTRACE_SYSCALL **
+  ** we get syscall-exit-stop for PID0: **
+ PID0 <... execve resumed> )             = 0
+
+In this situation there is no way to know which execve succeeded.
+
+If PTRACE_O_TRACEEXEC option is NOT in effect for the execve'ing
+tracee, kernel delivers an extra SIGTRAP to tracee after execve syscall
+returns. This is an ordinary signal (similar to one which can be
+generated by "kill -TRAP"), not a special kind of ptrace-stop.
+GETSIGINFO on it has si_code = 0 (SI_USER). It can be blocked by signal
+mask, and thus can happen (much) later.
+
+Usually, tracer (for example, strace) would not want to show this extra
+post-execve SIGTRAP signal to the user, and would suppress its delivery
+to the tracee (if SIGTRAP is set to SIG_DFL, it is a killing signal).
+However, determining *which* SIGTRAP to suppress is not easy. Setting
+PTRACE_O_TRACEEXEC option and thus suppressing this extra SIGTRAP is
+the recommended approach.
+
+
+	1.x Real parent
+
+Ptrace API (ab)uses standard Unix parent/child signaling over waitpid.
+This used to cause real parent of the process to stop receiving several
+kinds of waitpid notifications when child process is traced by some
+other process.
+
+Many of these bugs have been fixed, but as of 2.6.38 several still
+exist.
+
+As of 2.6.38, the following is believed to work correctly:
+
+- exit/death by signal is reported first to tracer, then, when tracer
+consumes waitpid result, to real parent (to real parent only when the
+whole multi-threaded process exits). If they are the same process, the
+report is sent only once.
+
+
+	1.x Known bugs
+
+Following bugs still exist:
+
+Group-stop notifications are sent to tracer, but not to real parent.
+Last confirmed on 2.6.38.6.
+
+If thread group leader is traced and exits by calling exit syscall,
+PTRACE_EVENT_EXIT stop will happen for it (if requested), but subsequent
+WIFEXITED notification will not be delivered until all other threads
+exit. As explained above, if one of other threads execve's, thread
+group leader death will *never* be reported. If execve-ed thread is not
+traced by this tracer, tracer will never know that execve happened.
+
+??? need to test this scenario
+
+One possible workaround is to detach thread group leader instead of
+restarting it in this case. Last confirmed on 2.6.38.6.
+
+SIGKILL signal may still cause PTRACE_EVENT_EXIT stop before actual
+signal death. This may be changed in the future - SIGKILL is meant to
+always immediately kill tasks even under ptrace. Last confirmed on
+2.6.38.6.
diff --git a/strace/README-mpers b/strace/README-mpers
new file mode 100644
index 0000000..ad1ca18
--- /dev/null
+++ b/strace/README-mpers
@@ -0,0 +1,14 @@
+To use mpers functionality, one should:
+* typedef all of the target types which are compound and not typedefed
+already;
+* for each target type, include DEF_MPERS_TYPE(target_type_t), these can
+be included conditionally;
+* include MPERS_DEFS once;
+* before inclusion of MPERS_DEFS include all important headers
+(containing definitions of these types or other behaviour-affecting
+defines);
+* printers should be defined
+as MPERS_PRINTER_DECL(return_type, function_name, args),
+inside files that include MPERS_DEFS these printers should be called
+as MPERS_FUNC_NAME(function_name)(args), in other files
+they should be called just as function_name(args).
diff --git a/strace/README.md b/strace/README.md
new file mode 100644
index 0000000..71c6ec0
--- /dev/null
+++ b/strace/README.md
@@ -0,0 +1,9 @@
+This is [strace](http://strace.io) -- a diagnostic, debugging and instructional userspace utility for Linux.  It is used to monitor interactions between processes and the Linux kernel, which include system calls, signal deliveries, and changes of process state.  The operation of strace is made possible by the kernel feature known as [ptrace](http://man7.org/linux/man-pages/man2/ptrace.2.html).
+
+strace is released under a Berkeley-style license at the request of Paul Kranenburg; see the file [COPYING](https://raw.githubusercontent.com/strace/strace/master/COPYING) for details.
+
+See the file [NEWS](https://raw.githubusercontent.com/strace/strace/master/NEWS) for information on what has changed in recent versions.
+
+Please send bug reports and enhancements to [the strace mailing list](https://lists.sourceforge.net/lists/listinfo/strace-devel).
+
+[![Build Status](https://travis-ci.org/strace/strace.svg?branch=master)](https://travis-ci.org/strace/strace) [![Code Coverage](https://codecov.io/github/strace/strace/coverage.svg?branch=master)](https://codecov.io/github/strace/strace?branch=master)
diff --git a/strace/access.c b/strace/access.c
new file mode 100644
index 0000000..a9663dc
--- /dev/null
+++ b/strace/access.c
@@ -0,0 +1,26 @@
+#include "defs.h"
+
+#include <fcntl.h>
+
+#include "xlat/access_flags.h"
+
+static int
+decode_access(struct tcb *tcp, int offset)
+{
+	printpath(tcp, tcp->u_arg[offset]);
+	tprints(", ");
+	printflags(access_flags, tcp->u_arg[offset + 1], "?_OK");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(access)
+{
+	return decode_access(tcp, 0);
+}
+
+SYS_FUNC(faccessat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	return decode_access(tcp, 1);
+}
diff --git a/strace/affinity.c b/strace/affinity.c
new file mode 100644
index 0000000..6b6eaa3
--- /dev/null
+++ b/strace/affinity.c
@@ -0,0 +1,110 @@
+/*
+ * Copyright (c) 2002-2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2009-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sched.h>
+
+static unsigned int
+get_cpuset_size(void)
+{
+	static unsigned int cpuset_size;
+
+	if (!cpuset_size) {
+		pid_t pid = getpid();
+		cpuset_size = 128;
+		while (cpuset_size &&
+		       sched_getaffinity(pid, cpuset_size, NULL) == -1 &&
+		       EINVAL == errno) {
+			cpuset_size <<= 1;
+		}
+		if (!cpuset_size)
+			cpuset_size = 128;
+	}
+
+	return cpuset_size;
+}
+
+static void
+print_affinitylist(struct tcb *tcp, const unsigned long addr, const unsigned int len)
+{
+	const unsigned int max_size = get_cpuset_size();
+	const unsigned int umove_size = len < max_size ? len : max_size;
+	const unsigned int size =
+		(umove_size + current_wordsize - 1) & -current_wordsize;
+	const unsigned int ncpu = size * 8;
+	void *cpu;
+
+	if (!verbose(tcp) || (exiting(tcp) && syserror(tcp)) ||
+	    !addr || !len || !(cpu = calloc(size, 1))) {
+		printaddr(addr);
+		return;
+	}
+
+	if (!umoven_or_printaddr(tcp, addr, umove_size, cpu)) {
+		int i = 0;
+		const char *sep = "";
+
+		tprints("[");
+		for (;; i++) {
+			i = next_set_bit(cpu, i, ncpu);
+			if (i < 0)
+				break;
+			tprintf("%s%d", sep, i);
+			sep = " ";
+		}
+		if (size < len)
+			tprintf("%s...", sep);
+		tprints("]");
+	}
+
+	free(cpu);
+}
+
+SYS_FUNC(sched_setaffinity)
+{
+	const int pid = tcp->u_arg[0];
+	const unsigned int len = tcp->u_arg[1];
+
+	tprintf("%d, %u, ", pid, len);
+	print_affinitylist(tcp, tcp->u_arg[2], len);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sched_getaffinity)
+{
+	const int pid = tcp->u_arg[0];
+	const unsigned int len = tcp->u_arg[1];
+
+	if (entering(tcp)) {
+		tprintf("%d, %u, ", pid, len);
+	} else {
+		print_affinitylist(tcp, tcp->u_arg[2], tcp->u_rval);
+	}
+	return 0;
+}
diff --git a/strace/aio.c b/strace/aio.c
new file mode 100644
index 0000000..29562d2
--- /dev/null
+++ b/strace/aio.c
@@ -0,0 +1,252 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <linux/aio_abi.h>
+
+SYS_FUNC(io_setup)
+{
+	if (entering(tcp))
+		tprintf("%u, ", (unsigned int) tcp->u_arg[0]);
+	else
+		printnum_ulong(tcp, tcp->u_arg[1]);
+	return 0;
+}
+
+SYS_FUNC(io_destroy)
+{
+	tprintf("%lu", tcp->u_arg[0]);
+
+	return RVAL_DECODED;
+}
+
+enum iocb_sub {
+	SUB_NONE, SUB_COMMON, SUB_VECTOR
+};
+
+static enum iocb_sub
+tprint_lio_opcode(unsigned cmd)
+{
+	static const struct {
+		const char *name;
+		enum iocb_sub sub;
+	} cmds[] = {
+		{ "pread", SUB_COMMON },
+		{ "pwrite", SUB_COMMON },
+		{ "fsync", SUB_NONE },
+		{ "fdsync", SUB_NONE },
+		{ "preadx", SUB_NONE },
+		{ "poll", SUB_NONE },
+		{ "noop", SUB_NONE },
+		{ "preadv", SUB_VECTOR },
+		{ "pwritev", SUB_VECTOR },
+	};
+
+	if (cmd < ARRAY_SIZE(cmds)) {
+		tprints(cmds[cmd].name);
+		return cmds[cmd].sub;
+	}
+	tprintf("%u /* SUB_??? */", cmd);
+	return SUB_NONE;
+}
+
+static void
+print_common_flags(const struct iocb *cb)
+{
+/* IOCB_FLAG_RESFD is available since v2.6.22-rc1~47 */
+#ifdef IOCB_FLAG_RESFD
+	if (cb->aio_flags & IOCB_FLAG_RESFD)
+		tprintf(", resfd=%d", cb->aio_resfd);
+	if (cb->aio_flags & ~IOCB_FLAG_RESFD)
+		tprintf(", flags=%x", cb->aio_flags);
+#endif
+}
+
+static bool
+iocb_is_valid(const struct iocb *cb)
+{
+	return cb->aio_buf == (unsigned long) cb->aio_buf &&
+	       cb->aio_nbytes == (size_t) cb->aio_nbytes &&
+	       (ssize_t) cb->aio_nbytes >= 0;
+}
+
+static enum iocb_sub
+print_iocb_header(const struct iocb *cb)
+{
+	enum iocb_sub sub;
+
+	if (cb->aio_data)
+		tprintf("data=%#" PRIx64 ", ",
+			(uint64_t) cb->aio_data);
+
+	if (cb->aio_key)
+		tprintf("key=%u, ", cb->aio_key);
+
+	sub = tprint_lio_opcode(cb->aio_lio_opcode);
+	if (cb->aio_reqprio)
+		tprintf(", reqprio=%hd", cb->aio_reqprio);
+
+	tprintf(", fildes=%d", cb->aio_fildes);
+
+	return sub;
+}
+
+static void
+print_iocb(struct tcb *tcp, const struct iocb *cb)
+{
+	enum iocb_sub sub = print_iocb_header(cb);
+
+	switch (sub) {
+	case SUB_COMMON:
+		if (cb->aio_lio_opcode == 1 && iocb_is_valid(cb)) {
+			tprints(", str=");
+			printstr(tcp, (unsigned long) cb->aio_buf,
+				 (unsigned long) cb->aio_nbytes);
+		} else {
+			tprintf(", buf=%#" PRIx64, (uint64_t) cb->aio_buf);
+		}
+		tprintf(", nbytes=%" PRIu64 ", offset=%" PRId64,
+			(uint64_t) cb->aio_nbytes, (int64_t) cb->aio_offset);
+		print_common_flags(cb);
+		break;
+	case SUB_VECTOR:
+		if (iocb_is_valid(cb)) {
+			tprints(", iovec=");
+			tprint_iov(tcp, cb->aio_nbytes, cb->aio_buf,
+				   cb->aio_lio_opcode == 8
+				   ? IOV_DECODE_STR
+				   : IOV_DECODE_ADDR);
+		} else {
+			tprintf(", buf=%#" PRIx64 ", nbytes=%" PRIu64,
+				(uint64_t) cb->aio_buf,
+				(uint64_t) cb->aio_nbytes);
+		}
+		tprintf(", offset=%" PRId64, (int64_t) cb->aio_offset);
+		print_common_flags(cb);
+		break;
+	case SUB_NONE:
+		break;
+	}
+}
+
+static bool
+print_iocbp(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	unsigned long addr;
+	struct iocb cb;
+
+	if (elem_size < sizeof(long)) {
+		addr = * (unsigned int *) elem_buf;
+	} else {
+		addr = * (unsigned long *) elem_buf;
+	}
+
+	tprints("{");
+	if (!umove_or_printaddr(tcp, addr, &cb))
+		print_iocb(tcp, &cb);
+	tprints("}");
+
+	return true;
+}
+
+SYS_FUNC(io_submit)
+{
+	const long nr = widen_to_long(tcp->u_arg[1]);
+	const unsigned long addr = tcp->u_arg[2];
+	unsigned long iocbp;
+
+	tprintf("%lu, %ld, ", tcp->u_arg[0], nr);
+
+	if (nr < 0)
+		printaddr(addr);
+	else
+		print_array(tcp, addr, nr, &iocbp, current_wordsize,
+			    umoven_or_printaddr, print_iocbp, 0);
+
+	return RVAL_DECODED;
+}
+
+static bool
+print_io_event(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	struct io_event *event = elem_buf;
+
+	tprintf("{data=%#" PRIx64 ", obj=%#" PRIx64
+		", res=%" PRId64 ", res2=%" PRId64 "}",
+		(uint64_t) event->data, (uint64_t) event->obj,
+		(int64_t) event->res, (int64_t) event->res2);
+
+	return true;
+}
+
+SYS_FUNC(io_cancel)
+{
+	if (entering(tcp)) {
+		tprintf("%lu, ", tcp->u_arg[0]);
+		struct iocb cb;
+
+		if (!umove_or_printaddr(tcp, tcp->u_arg[1], &cb)) {
+			tprints("{");
+			print_iocb_header(&cb);
+			tprints("}");
+		}
+		tprints(", ");
+	} else {
+		struct io_event event;
+
+		if (!umove_or_printaddr(tcp, tcp->u_arg[2], &event))
+			print_io_event(tcp, &event, sizeof(event), 0);
+	}
+	return 0;
+}
+
+SYS_FUNC(io_getevents)
+{
+	if (entering(tcp)) {
+		tprintf("%lu, %ld, %ld, ",
+			tcp->u_arg[0],
+			widen_to_long(tcp->u_arg[1]),
+			widen_to_long(tcp->u_arg[2]));
+	} else {
+		struct io_event buf;
+		print_array(tcp, tcp->u_arg[3], tcp->u_rval, &buf, sizeof(buf),
+			    umoven_or_printaddr, print_io_event, 0);
+		tprints(", ");
+		/*
+		 * Since the timeout parameter is read by the kernel
+		 * on entering syscall, it has to be decoded the same way
+		 * whether the syscall has failed or not.
+		 */
+		temporarily_clear_syserror(tcp);
+		print_timespec(tcp, tcp->u_arg[4]);
+		restore_cleared_syserror(tcp);
+	}
+	return 0;
+}
diff --git a/strace/alpha.c b/strace/alpha.c
new file mode 100644
index 0000000..70d4ca5
--- /dev/null
+++ b/strace/alpha.c
@@ -0,0 +1,83 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef ALPHA
+
+static int
+decode_getxxid(struct tcb *tcp, const char *what)
+{
+	if (entering(tcp))
+		return 0;
+
+	long rval = getrval2(tcp);
+	if (rval == -1)
+		return 0;
+	static const char const fmt[] = "%s %ld";
+	static char outstr[sizeof(fmt) + 3 * sizeof(rval)];
+	snprintf(outstr, sizeof(outstr), fmt, what, rval);
+	tcp->auxstr = outstr;
+	return RVAL_STR;
+}
+
+SYS_FUNC(getxpid)
+{
+	return decode_getxxid(tcp, "ppid");
+}
+
+SYS_FUNC(getxuid)
+{
+	return decode_getxxid(tcp, "euid");
+}
+
+SYS_FUNC(getxgid)
+{
+	return decode_getxxid(tcp, "egid");
+}
+
+SYS_FUNC(osf_statfs)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printaddr(tcp->u_arg[1]);
+	tprints(", ");
+	tprintf("%lu", tcp->u_arg[2]);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(osf_fstatfs)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printaddr(tcp->u_arg[1]);
+	tprints(", ");
+	tprintf("%lu", tcp->u_arg[2]);
+	return RVAL_DECODED;
+}
+
+#endif /* ALPHA */
diff --git a/strace/bjm.c b/strace/bjm.c
new file mode 100644
index 0000000..7a72809
--- /dev/null
+++ b/strace/bjm.c
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <fcntl.h>
+
+#include "xlat/delete_module_flags.h"
+
+SYS_FUNC(create_module)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprintf(", %lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+SYS_FUNC(delete_module)
+{
+	printstr(tcp, tcp->u_arg[0], -1);
+	tprints(", ");
+	printflags(delete_module_flags, tcp->u_arg[1], "O_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(init_module)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	printstr(tcp, tcp->u_arg[2], -1);
+
+	return RVAL_DECODED;
+}
+
+#define MODULE_INIT_IGNORE_MODVERSIONS  1
+#define MODULE_INIT_IGNORE_VERMAGIC     2
+
+#include "xlat/module_init_flags.h"
+
+SYS_FUNC(finit_module)
+{
+	/* file descriptor */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* param_values */
+	printstr(tcp, tcp->u_arg[1], -1);
+	tprints(", ");
+	/* flags */
+	printflags(module_init_flags, tcp->u_arg[2], "MODULE_INIT_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/block.c b/strace/block.c
new file mode 100644
index 0000000..3c00746
--- /dev/null
+++ b/strace/block.c
@@ -0,0 +1,254 @@
+/*
+ * Copyright (c) 2009, 2010 Jeff Mahoney <jeffm@suse.com>
+ * Copyright (c) 2011-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_blk_user_trace_setup)
+#include DEF_MPERS_TYPE(struct_blkpg_ioctl_arg)
+#include DEF_MPERS_TYPE(struct_blkpg_partition)
+
+#include <linux/blkpg.h>
+#include <linux/fs.h>
+
+#define BLKTRACE_BDEV_SIZE      32
+typedef struct blk_user_trace_setup {
+	char name[BLKTRACE_BDEV_SIZE];	/* output */
+	uint16_t act_mask;		/* input */
+	uint32_t buf_size;		/* input */
+	uint32_t buf_nr;		/* input */
+	uint64_t start_lba;
+	uint64_t end_lba;
+	uint32_t pid;
+} struct_blk_user_trace_setup;
+
+typedef struct blkpg_ioctl_arg struct_blkpg_ioctl_arg;
+typedef struct blkpg_partition struct_blkpg_partition;
+
+#include MPERS_DEFS
+
+/*
+ * ioctl numbers <= 114 are present in Linux 2.4.  The following ones have been
+ * added since then and headers containing them may not be available on every
+ * system.
+ */
+
+#ifndef BLKTRACESETUP
+# define BLKTRACESETUP _IOWR(0x12, 115, struct_blk_user_trace_setup)
+#endif
+#ifndef BLKTRACESTART
+# define BLKTRACESTART _IO(0x12,116)
+#endif
+#ifndef BLKTRACESTOP
+# define BLKTRACESTOP _IO(0x12,117)
+#endif
+#ifndef BLKTRACETEARDOWN
+# define BLKTRACETEARDOWN _IO(0x12,118)
+#endif
+#ifndef BLKDISCARD
+# define BLKDISCARD _IO(0x12,119)
+#endif
+#ifndef BLKIOMIN
+# define BLKIOMIN _IO(0x12,120)
+#endif
+#ifndef BLKIOOPT
+# define BLKIOOPT _IO(0x12,121)
+#endif
+#ifndef BLKALIGNOFF
+# define BLKALIGNOFF _IO(0x12,122)
+#endif
+#ifndef BLKPBSZGET
+# define BLKPBSZGET _IO(0x12,123)
+#endif
+#ifndef BLKDISCARDZEROES
+# define BLKDISCARDZEROES _IO(0x12,124)
+#endif
+#ifndef BLKSECDISCARD
+# define BLKSECDISCARD _IO(0x12,125)
+#endif
+#ifndef BLKROTATIONAL
+# define BLKROTATIONAL _IO(0x12,126)
+#endif
+#ifndef BLKZEROOUT
+# define BLKZEROOUT _IO(0x12,127)
+#endif
+
+#include "xlat/blkpg_ops.h"
+
+static void
+print_blkpg_req(struct tcb *tcp, const struct_blkpg_ioctl_arg *blkpg)
+{
+	struct_blkpg_partition p;
+
+	tprints("{");
+	printxval(blkpg_ops, blkpg->op, "BLKPG_???");
+
+	tprintf(", flags=%d, datalen=%d, data=",
+		blkpg->flags, blkpg->datalen);
+
+	if (!umove_or_printaddr(tcp, (long) blkpg->data, &p)) {
+		tprintf("{start=%lld, length=%lld, pno=%d, devname=",
+			(long long) p.start, (long long) p.length, p.pno);
+		print_quoted_string(p.devname, sizeof(p.devname),
+				    QUOTE_0_TERMINATED);
+		tprints(", volname=");
+		print_quoted_string(p.volname, sizeof(p.volname),
+				    QUOTE_0_TERMINATED);
+		tprints("}");
+	}
+	tprints("}");
+}
+
+MPERS_PRINTER_DECL(int, block_ioctl, struct tcb *tcp,
+		   const unsigned int code, const long arg)
+{
+	switch (code) {
+	/* take arg as a value, not as a pointer */
+	case BLKRASET:
+	case BLKFRASET:
+		tprintf(", %lu", arg);
+		break;
+
+	/* return an unsigned short */
+	case BLKSECTGET:
+	case BLKROTATIONAL:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_short(tcp, arg, "%hu");
+		break;
+
+	/* return a signed int */
+	case BLKROGET:
+	case BLKBSZGET:
+	case BLKSSZGET:
+	case BLKALIGNOFF:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	/* take a signed int */
+	case BLKROSET:
+	case BLKBSZSET:
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+
+	/* return an unsigned int */
+	case BLKPBSZGET:
+	case BLKIOMIN:
+	case BLKIOOPT:
+	case BLKDISCARDZEROES:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_int(tcp, arg, "%u");
+		break;
+
+	/* return a signed long */
+	case BLKRAGET:
+	case BLKFRAGET:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_slong(tcp, arg);
+		break;
+
+	/* returns an unsigned long */
+	case BLKGETSIZE:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_ulong(tcp, arg);
+		break;
+
+#ifdef HAVE_BLKGETSIZE64
+	/* returns an uint64_t */
+	case BLKGETSIZE64:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_int64(tcp, arg, "%" PRIu64);
+		break;
+#endif
+
+	/* takes a pair of uint64_t */
+	case BLKDISCARD:
+	case BLKSECDISCARD:
+	case BLKZEROOUT:
+		tprints(", ");
+		printpair_int64(tcp, arg, "%" PRIu64);
+		break;
+
+	/* More complex types */
+	case BLKPG: {
+		struct_blkpg_ioctl_arg blkpg;
+
+		tprints(", ");
+		if (!umove_or_printaddr(tcp, arg, &blkpg))
+			print_blkpg_req(tcp, &blkpg);
+		break;
+	}
+
+	case BLKTRACESETUP:
+		if (entering(tcp)) {
+			struct_blk_user_trace_setup buts;
+
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &buts))
+				break;
+			tprintf("{act_mask=%u, buf_size=%u, "
+				"buf_nr=%u, start_lba=%" PRIu64 ", "
+				"end_lba=%" PRIu64 ", pid=%u",
+				(unsigned)buts.act_mask, buts.buf_size,
+				buts.buf_nr, buts.start_lba,
+				buts.end_lba, buts.pid);
+			return 1;
+		} else {
+			struct_blk_user_trace_setup buts;
+
+			if (!syserror(tcp) && !umove(tcp, arg, &buts)) {
+				tprints(", name=");
+				print_quoted_string(buts.name, sizeof(buts.name),
+						    QUOTE_0_TERMINATED);
+			}
+			tprints("}");
+			break;
+		}
+
+	/* No arguments */
+	case BLKRRPART:
+	case BLKFLSBUF:
+	case BLKTRACESTART:
+	case BLKTRACESTOP:
+	case BLKTRACETEARDOWN:
+		break;
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/bootstrap b/strace/bootstrap
new file mode 100755
index 0000000..395fc80
--- /dev/null
+++ b/strace/bootstrap
@@ -0,0 +1,21 @@
+#!/bin/sh -eu
+
+for m in m32 mx32; do
+	tests=tests-$m
+	rm -rf $tests
+	mkdir $tests
+	s='[[:space:]]*'
+	sed "s/@arch@/@arch_$m@/;s/^MPERS_NAME$s=.*/& $m/;s/^ARCH_MFLAGS$s=.*/& -$m/" \
+		tests/Makefile.am > $tests/Makefile.am
+	for f in tests/*; do
+		case "${f##*/}" in
+		Makefile*) continue;;
+		esac
+		ln -s ../"$f" $tests/
+	done
+done
+
+./generate_mpers_am.sh
+./xlat/gen.sh
+
+exec autoreconf -f -i "$@"
diff --git a/strace/bpf.c b/strace/bpf.c
new file mode 100644
index 0000000..20070b3
--- /dev/null
+++ b/strace/bpf.c
@@ -0,0 +1,215 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_LINUX_BPF_H
+# include <linux/bpf.h>
+#endif
+
+#include "xlat/bpf_commands.h"
+#include "xlat/bpf_map_types.h"
+#include "xlat/bpf_prog_types.h"
+#include "xlat/bpf_map_update_elem_flags.h"
+
+static int
+bpf_map_create(struct tcb *tcp, const long addr, unsigned int size)
+{
+	struct {
+		uint32_t map_type, key_size, value_size, max_entries;
+	} attr = {};
+
+	if (!size) {
+		printaddr(addr);
+		return RVAL_DECODED | RVAL_FD;
+	}
+	if (size > sizeof(attr))
+		size = sizeof(attr);
+	if (umoven_or_printaddr(tcp, addr, size, &attr))
+		return RVAL_DECODED | RVAL_FD;
+
+	tprints("{map_type=");
+	printxval(bpf_map_types, attr.map_type, "BPF_MAP_TYPE_???");
+	tprintf(", key_size=%u, value_size=%u, max_entries=%u}",
+		attr.key_size, attr.value_size, attr.max_entries);
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+static void
+bpf_map_update_elem(struct tcb *tcp, const long addr, unsigned int size)
+{
+	struct {
+		uint32_t map_fd;
+		uint64_t ATTRIBUTE_ALIGNED(8) key;
+		uint64_t ATTRIBUTE_ALIGNED(8) value;
+		uint64_t flags;
+	} attr = {};
+
+	if (!size) {
+		printaddr(addr);
+		return;
+	}
+	if (size > sizeof(attr))
+		size = sizeof(attr);
+	if (umoven_or_printaddr(tcp, addr, size, &attr))
+		return;
+
+	tprints("{map_fd=");
+	printfd(tcp, attr.map_fd);
+	tprintf(", key=%#" PRIx64 ", value=%#" PRIx64 ", flags=",
+		attr.key, attr.value);
+	printxval64(bpf_map_update_elem_flags, attr.flags, "BPF_???");
+	tprints("}");
+}
+
+static void
+bpf_map_delete_elem(struct tcb *tcp, const long addr, unsigned int size)
+{
+	struct {
+		uint32_t map_fd;
+		uint64_t ATTRIBUTE_ALIGNED(8) key;
+	} attr = {};
+
+	if (!size) {
+		printaddr(addr);
+		return;
+	}
+	if (size > sizeof(attr))
+		size = sizeof(attr);
+	if (umoven_or_printaddr(tcp, addr, size, &attr))
+		return;
+
+	tprints("{map_fd=");
+	printfd(tcp, attr.map_fd);
+	tprintf(", key=%#" PRIx64 "}", attr.key);
+}
+
+static int
+bpf_map_io(struct tcb *tcp, const long addr, unsigned int size, const char *text)
+{
+	struct bpf_io_elem_struct {
+		uint32_t map_fd;
+		uint64_t ATTRIBUTE_ALIGNED(8) key;
+		uint64_t ATTRIBUTE_ALIGNED(8) value;
+	} attr = {};
+
+	if (exiting(tcp)) {
+		if (!syserror(tcp) && !umove_or_printaddr(tcp, addr, &attr))
+			tprintf(", %s=%#" PRIx64, text, attr.value);
+		tprints("}");
+		return RVAL_DECODED;
+	}
+
+	if (!size) {
+		printaddr(addr);
+		return RVAL_DECODED;
+	}
+	if (size > sizeof(attr))
+		size = sizeof(attr);
+	if (umoven_or_printaddr(tcp, addr, size, &attr))
+		return RVAL_DECODED;
+
+	tprints("{map_fd=");
+	printfd(tcp, attr.map_fd);
+	tprintf(", key=%#" PRIx64, attr.key);
+
+	return 0;
+}
+
+static int
+bpf_prog_load(struct tcb *tcp, const long addr, unsigned int size)
+{
+	struct {
+		uint32_t prog_type, insn_cnt;
+		uint64_t ATTRIBUTE_ALIGNED(8) insns, license;
+		uint32_t log_level, log_size;
+		uint64_t ATTRIBUTE_ALIGNED(8) log_buf;
+		uint32_t kern_version;
+	} attr = {};
+
+	if (!size) {
+		printaddr(addr);
+		return RVAL_DECODED | RVAL_FD;
+	}
+	if (size > sizeof(attr))
+		size = sizeof(attr);
+	if (umoven_or_printaddr(tcp, addr, size, &attr))
+		return RVAL_DECODED | RVAL_FD;
+
+	tprints("{prog_type=");
+	printxval(bpf_prog_types, attr.prog_type, "BPF_PROG_TYPE_???");
+	tprintf(", insn_cnt=%u, insns=%#" PRIx64 ", license=",
+		attr.insn_cnt, attr.insns);
+	printstr(tcp, attr.license, -1);
+	tprintf(", log_level=%u, log_size=%u, log_buf=%#" PRIx64 ", kern_version=%u}",
+		attr.log_level, attr.log_size, attr.log_buf, attr.kern_version);
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(bpf)
+{
+	const int cmd = tcp->u_arg[0];
+	const long addr = tcp->u_arg[1];
+	const unsigned int size = tcp->u_arg[2];
+	int rc = RVAL_DECODED;
+
+	if (entering(tcp)) {
+		printxval(bpf_commands, cmd, "BPF_???");
+		tprints(", ");
+	}
+
+	switch (cmd) {
+	case BPF_MAP_CREATE:
+		rc = bpf_map_create(tcp, addr, size);
+		break;
+	case BPF_MAP_LOOKUP_ELEM:
+		rc = bpf_map_io(tcp, addr, size, "value");
+		break;
+	case BPF_MAP_UPDATE_ELEM:
+		bpf_map_update_elem(tcp, addr, size);
+		break;
+	case BPF_MAP_DELETE_ELEM:
+		bpf_map_delete_elem(tcp, addr, size);
+		break;
+	case BPF_MAP_GET_NEXT_KEY:
+		rc = bpf_map_io(tcp, addr, size, "next_key");
+		break;
+	case BPF_PROG_LOAD:
+		rc = bpf_prog_load(tcp, addr, size);
+		break;
+	default:
+		printaddr(addr);
+		break;
+	}
+
+	if (rc & RVAL_DECODED)
+		tprintf(", %u", size);
+
+	return rc;
+}
diff --git a/strace/btrfs.c b/strace/btrfs.c
new file mode 100644
index 0000000..9c71768
--- /dev/null
+++ b/strace/btrfs.c
@@ -0,0 +1,1364 @@
+/*
+ * Copyright (c) 2016 Jeff Mahoney <jeffm@suse.com>
+ * 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"
+
+#ifdef HAVE_LINUX_BTRFS_H
+
+#include DEF_MPERS_TYPE(struct_btrfs_ioctl_dev_replace_args)
+#include DEF_MPERS_TYPE(struct_btrfs_ioctl_send_args)
+#include DEF_MPERS_TYPE(struct_btrfs_ioctl_received_subvol_args)
+
+# include <linux/btrfs.h>
+
+typedef struct btrfs_ioctl_dev_replace_args
+	struct_btrfs_ioctl_dev_replace_args;
+typedef struct btrfs_ioctl_send_args
+	struct_btrfs_ioctl_send_args;
+typedef struct btrfs_ioctl_received_subvol_args
+	struct_btrfs_ioctl_received_subvol_args;
+
+#endif /* HAVE_LINUX_BTRFS_H */
+
+#include MPERS_DEFS
+
+#ifdef HAVE_LINUX_BTRFS_H
+
+#include <linux/fs.h>
+
+/*
+ * Prior to Linux 3.12, the BTRFS_IOC_DEFAULT_SUBVOL used u64 in
+ * its definition, which isn't exported by the kernel.
+ */
+typedef __u64 u64;
+
+#ifndef HAVE_STRUCT_BTRFS_IOCTL_FEATURE_FLAGS_COMPAT_FLAGS
+struct btrfs_ioctl_feature_flags {
+	uint64_t compat_flags;
+	uint64_t compat_ro_flags;
+	uint64_t incompat_flags;
+};
+#endif
+
+#ifndef HAVE_STRUCT_BTRFS_IOCTL_DEFRAG_RANGE_ARGS_START
+struct btrfs_ioctl_defrag_range_args {
+	uint64_t start;
+	uint64_t len;
+	uint64_t flags;
+	uint32_t extent_thresh;
+	uint32_t compress_type;
+	uint32_t unused[4];
+};
+#endif
+
+#ifndef BTRFS_LABEL_SIZE
+# define BTRFS_LABEL_SIZE 256
+#endif
+
+#ifndef BTRFS_FIRST_FREE_OBJECTID
+# define BTRFS_FIRST_FREE_OBJECTID 256ULL
+#endif
+
+#ifndef BTRFS_IOC_QUOTA_RESCAN
+struct btrfs_ioctl_quota_rescan_args {
+	uint64_t flags, progress, reserved[6];
+};
+# define BTRFS_IOC_QUOTA_RESCAN _IOW(BTRFS_IOCTL_MAGIC, 44, \
+					struct btrfs_ioctl_quota_rescan_args)
+# define BTRFS_IOC_QUOTA_RESCAN_STATUS _IOR(BTRFS_IOCTL_MAGIC, 45, \
+					struct btrfs_ioctl_quota_rescan_args)
+#endif
+
+#ifndef BTRFS_IOC_QUOTA_RESCAN_WAIT
+# define BTRFS_IOC_QUOTA_RESCAN_WAIT _IO(BTRFS_IOCTL_MAGIC, 46)
+#endif
+
+#ifndef BTRFS_IOC_GET_FEATURES
+# define BTRFS_IOC_GET_FEATURES _IOR(BTRFS_IOCTL_MAGIC, 57, \
+					struct btrfs_ioctl_feature_flags)
+# define BTRFS_IOC_SET_FEATURES _IOW(BTRFS_IOCTL_MAGIC, 57, \
+					struct btrfs_ioctl_feature_flags[2])
+# define BTRFS_IOC_GET_SUPPORTED_FEATURES _IOR(BTRFS_IOCTL_MAGIC, 57, \
+					struct btrfs_ioctl_feature_flags[3])
+#endif
+
+#ifndef BTRFS_IOC_TREE_SEARCH_V2
+# define BTRFS_IOC_TREE_SEARCH_V2 _IOWR(BTRFS_IOCTL_MAGIC, 17, \
+					struct btrfs_ioctl_search_args_v2)
+struct btrfs_ioctl_search_args_v2 {
+	struct btrfs_ioctl_search_key key; /* in/out - search parameters */
+	uint64_t buf_size;		   /* in - size of buffer
+					    * out - on EOVERFLOW: needed size
+					    *       to store item */
+	uint64_t buf[0];		   /* out - found items */
+};
+#endif
+
+#include "xlat/btrfs_balance_args.h"
+#include "xlat/btrfs_balance_ctl_cmds.h"
+#include "xlat/btrfs_balance_flags.h"
+#include "xlat/btrfs_balance_state.h"
+#include "xlat/btrfs_compress_types.h"
+#include "xlat/btrfs_defrag_flags.h"
+#include "xlat/btrfs_dev_replace_cmds.h"
+#include "xlat/btrfs_dev_replace_results.h"
+#include "xlat/btrfs_dev_replace_state.h"
+#include "xlat/btrfs_dev_stats_flags.h"
+#include "xlat/btrfs_dev_stats_values.h"
+#include "xlat/btrfs_features_compat.h"
+#include "xlat/btrfs_features_compat_ro.h"
+#include "xlat/btrfs_features_incompat.h"
+#include "xlat/btrfs_key_types.h"
+#include "xlat/btrfs_qgroup_ctl_cmds.h"
+#include "xlat/btrfs_qgroup_inherit_flags.h"
+#include "xlat/btrfs_qgroup_limit_flags.h"
+#include "xlat/btrfs_qgroup_status_flags.h"
+#include "xlat/btrfs_scrub_flags.h"
+#include "xlat/btrfs_send_flags.h"
+#include "xlat/btrfs_snap_flags_v2.h"
+#include "xlat/btrfs_space_info_flags.h"
+#include "xlat/btrfs_tree_objectids.h"
+
+static inline char
+prnibble(char v)
+{
+	if (v >= 10)
+		return 'a' + (v - 10);
+	return '0' + v;
+}
+
+/* 8-4-4-4-12 = 36 characters */
+#define UUID_STRING_SIZE 36
+
+/* Formats uuid, returns 0 if it's all zeroes */
+static int
+btrfs_unparse_uuid(unsigned char *uuid, char *out)
+{
+	int i;
+	int ret = 0;
+	for (i = 0; i < BTRFS_UUID_SIZE; i++) {
+		if (i == 4 || i == 6 || i == 8 || i == 10)
+			*out++ = '-';
+		*out++ = prnibble(uuid[i] >> 4);
+		*out++ = prnibble(uuid[i] & 0xf);
+		if (uuid[i])
+			ret = 1;
+	}
+	*out = '\0';
+	return ret;
+}
+
+static void
+print_u64(const char *name, uint64_t value)
+{
+	tprintf(", %s=%" PRIu64, name, value);
+	if (value == UINT64_MAX)
+		tprints(" /* UINT64_MAX */");
+}
+
+#define print_member_u64(obj, name) print_u64(#name, obj->name)
+
+static void
+btrfs_print_balance_args(const char *name, const struct btrfs_balance_args *bba)
+{
+	tprintf(", %s={profiles=", name);
+	printflags64(btrfs_space_info_flags, bba->profiles,
+		     "BTRFS_BLOCK_GROUP_???");
+	print_member_u64(bba, usage);
+	print_member_u64(bba, devid);
+	print_member_u64(bba, pstart);
+	print_member_u64(bba, pend);
+	print_member_u64(bba, vstart);
+	print_member_u64(bba, vend);
+	print_member_u64(bba, target);
+	tprints(", flags=");
+	printflags64(btrfs_balance_args, bba->flags, "BTRFS_BALANCE_ARGS_???");
+	tprints("}");
+}
+
+static void
+btrfs_print_balance(struct tcb *tcp, const long arg, bool out)
+{
+	struct btrfs_ioctl_balance_args balance_args;
+
+	if (umove_or_printaddr(tcp, arg, &balance_args))
+		return;
+
+	tprints("{flags=");
+	printflags64(btrfs_balance_flags, balance_args.flags,
+		     "BTRFS_BALANCE_???");
+	if (out) {
+		tprints(", state=");
+		printflags64(btrfs_balance_state, balance_args.state,
+			     "BTRFS_BALANCE_STATE_???");
+	}
+
+	if (balance_args.flags & BTRFS_BALANCE_DATA)
+		btrfs_print_balance_args("data", &balance_args.data);
+	if (balance_args.flags & BTRFS_BALANCE_METADATA)
+		btrfs_print_balance_args("meta", &balance_args.meta);
+	if (balance_args.flags & BTRFS_BALANCE_SYSTEM)
+		btrfs_print_balance_args("sys", &balance_args.sys);
+	tprints("}");
+}
+
+static void
+btrfs_print_features(const struct btrfs_ioctl_feature_flags *flags)
+{
+	tprints("{compat_flags=");
+	printflags64(btrfs_features_compat, flags->compat_flags,
+		     "BTRFS_FEATURE_COMPAT_???");
+
+	tprints(", compat_ro_flags=");
+	printflags64(btrfs_features_compat_ro, flags->compat_ro_flags,
+		     "BTRFS_FEATURE_COMPAT_RO_???");
+
+	tprints(", incompat_flags=");
+	printflags64(btrfs_features_incompat, flags->incompat_flags,
+		     "BTRFS_FEATURE_INCOMPAT_???");
+	tprints("}");
+}
+
+static void
+btrfs_print_qgroup_limit(const struct btrfs_qgroup_limit *lim)
+{
+	tprints("{flags=");
+	printflags64(btrfs_qgroup_limit_flags, lim->flags,
+		     "BTRFS_QGROUP_LIMIT_???");
+	tprintf(", max_rfer=%" PRI__u64 ", max_excl=%" PRI__u64
+		", rsv_rfer=%" PRI__u64 ", rsv_excl=%" PRI__u64 "}",
+		lim->max_rfer, lim->max_excl,
+		lim->rsv_rfer, lim->rsv_excl);
+}
+
+static void
+btrfs_print_key_type(uint32_t type)
+{
+	const char *str = xlookup(btrfs_key_types, type);
+	tprintf("%u", type);
+	if (str)
+		tprintf(" /* %s */", str);
+}
+
+static void
+btrfs_print_objectid(uint64_t objectid)
+{
+	const char *str = xlookup(btrfs_tree_objectids, objectid);
+	tprintf("%" PRIu64, objectid);
+	if (str)
+		tprintf(" /* %s */", str);
+}
+
+static void
+btrfs_print_data_container_header(const struct btrfs_data_container *container)
+{
+	tprintf("{bytes_left=%u, bytes_missing=%u"
+		", elem_cnt=%u, elem_missed=%u, val=",
+		container->bytes_left, container->bytes_missing,
+		container->elem_cnt, container->elem_missed);
+}
+
+static void
+btrfs_print_data_container_footer(void)
+{
+	tprints("}");
+}
+
+static bool
+print_btrfs_data_container_logical_ino(struct tcb *tcp, void *elem_buf,
+				       size_t elem_size, void *data)
+{
+	const uint64_t *const record = elem_buf;
+
+	tprintf("{inum=%" PRIu64 ", offset=%" PRIu64 ", root=%" PRIu64 "}",
+		record[0], record[1], record[2]);
+
+	return true;
+}
+
+static void
+btrfs_print_logical_ino_container(struct tcb *tcp,
+				  const uint64_t inodes_addr)
+{
+	struct btrfs_data_container container;
+
+	if (umove_or_printaddr(tcp, inodes_addr, &container))
+		return;
+
+	btrfs_print_data_container_header(&container);
+
+	if (abbrev(tcp)) {
+		tprints("...");
+	} else {
+		const uint64_t val_addr =
+			inodes_addr + offsetof(typeof(container), val);
+		uint64_t record[3];
+		print_array(tcp, val_addr, container.elem_cnt / 3,
+			    record, sizeof(record),
+			    umoven_or_printaddr,
+			    print_btrfs_data_container_logical_ino, 0);
+	}
+
+	btrfs_print_data_container_footer();
+}
+
+static bool
+print_btrfs_data_container_ino_path(struct tcb *tcp, void *elem_buf,
+				       size_t elem_size, void *data)
+{
+	const uint64_t *const offset = elem_buf;
+	const uint64_t *const val_addr = data;
+
+	printpath(tcp, *val_addr + *offset);
+
+	return true;
+}
+
+static void
+btrfs_print_ino_path_container(struct tcb *tcp,
+			       const uint64_t fspath_addr)
+{
+	struct btrfs_data_container container;
+
+	if (umove_or_printaddr(tcp, fspath_addr, &container))
+		return;
+
+	btrfs_print_data_container_header(&container);
+
+	if (abbrev(tcp)) {
+		tprints("...");
+	} else {
+		uint64_t val_addr =
+			fspath_addr + offsetof(typeof(container), val);
+		uint64_t offset;
+		print_array(tcp, val_addr, container.elem_cnt,
+			    &offset, sizeof(offset),
+			    umoven_or_printaddr,
+			    print_btrfs_data_container_ino_path, &val_addr);
+	}
+
+	btrfs_print_data_container_footer();
+}
+
+static bool
+print_uint64(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	tprintf("%" PRIu64, * (uint64_t *) elem_buf);
+
+	return true;
+}
+
+static void
+btrfs_print_qgroup_inherit(struct tcb *tcp, const uint64_t qgi_addr)
+{
+	struct btrfs_qgroup_inherit inherit;
+
+	if (umove_or_printaddr(tcp, qgi_addr, &inherit))
+		return;
+
+	tprintf("{flags=");
+	printflags64(btrfs_qgroup_inherit_flags, inherit.flags,
+		     "BTRFS_QGROUP_INHERIT_???");
+	tprintf(", num_qgroups=%" PRI__u64 ", num_ref_copies=%" PRI__u64
+		", num_excl_copies=%" PRI__u64 ", lim=",
+		inherit.num_qgroups, inherit.num_ref_copies,
+		inherit.num_excl_copies);
+
+	btrfs_print_qgroup_limit(&inherit.lim);
+
+	tprints(", qgroups=");
+
+	if (abbrev(tcp)) {
+		tprints("...");
+	} else {
+		uint64_t record;
+		print_array(tcp, qgi_addr + offsetof(typeof(inherit), qgroups),
+			    inherit.num_qgroups, &record, sizeof(record),
+			    umoven_or_printaddr, print_uint64, 0);
+	}
+	tprints("}");
+}
+
+static void
+print_key_value_internal(struct tcb *tcp, const char *name, uint64_t value)
+{
+	if (value) {
+		tprintf(", %s=%" PRIu64, name, value);
+		if (value == UINT64_MAX)
+			tprints(" /* UINT64_MAX */");
+	}
+}
+#define print_key_value(tcp, key, name)					\
+	print_key_value_internal((tcp), #name, (key)->name)
+
+static void
+btrfs_print_tree_search(struct tcb *tcp, struct btrfs_ioctl_search_key *key,
+			uint64_t buf_addr, uint64_t buf_size, bool print_size)
+{
+	if (entering(tcp)) {
+		tprintf("{key={tree_id=");
+		btrfs_print_objectid(key->tree_id);
+
+		if (key->min_objectid != BTRFS_FIRST_FREE_OBJECTID ||
+		    !abbrev(tcp)) {
+			tprints(", min_objectid=");
+			btrfs_print_objectid(key->min_objectid);
+		}
+
+		if (key->max_objectid != BTRFS_LAST_FREE_OBJECTID ||
+		    !abbrev(tcp)) {
+			tprints(", max_objectid=");
+			btrfs_print_objectid(key->max_objectid);
+		}
+
+		print_key_value(tcp, key, min_offset);
+		print_key_value(tcp, key, max_offset);
+		print_key_value(tcp, key, min_transid);
+		print_key_value(tcp, key, max_transid);
+
+		tprints(", min_type=");
+		btrfs_print_key_type(key->min_type);
+		tprints(", max_type=");
+		btrfs_print_key_type(key->max_type);
+		tprintf(", nr_items=%u}", key->nr_items);
+		if (print_size)
+			tprintf(", buf_size=%" PRIu64, buf_size);
+		tprints("}");
+	} else {
+		tprintf("{key={nr_items=%u}", key->nr_items);
+		if (print_size)
+			tprintf(", buf_size=%" PRIu64, buf_size);
+		tprints(", buf=");
+		if (abbrev(tcp))
+			tprints("...");
+		else {
+			uint64_t i;
+			uint64_t off = 0;
+			tprints("[");
+			for (i = 0; i < key->nr_items; i++) {
+				struct btrfs_ioctl_search_header sh;
+				uint64_t addr = buf_addr + off;
+				if (i)
+					tprints(", ");
+				if (i > max_strlen ||
+				    umove(tcp, addr, &sh)) {
+					tprints("...");
+					break;
+				}
+				tprintf("{transid=%" PRI__u64 ", objectid=",
+					sh.transid);
+				btrfs_print_objectid(sh.objectid);
+				tprintf(", offset=%" PRI__u64 ", type=", sh.offset);
+				btrfs_print_key_type(sh.type);
+				tprintf(", len=%u}", sh.len);
+				off += sizeof(sh) + sh.len;
+
+			}
+			tprints("]");
+		}
+		tprints("}");
+	}
+}
+
+static bool
+print_objectid_callback(struct tcb *tcp, void *elem_buf,
+			size_t elem_size, void *data)
+{
+	btrfs_print_objectid(* (uint64_t *) elem_buf);
+
+	return true;
+}
+
+static bool
+print_btrfs_ioctl_space_info(struct tcb *tcp, void *elem_buf,
+			     size_t elem_size, void *data)
+{
+	const struct btrfs_ioctl_space_info *info = elem_buf;
+
+	tprints("{flags=");
+	printflags64(btrfs_space_info_flags, info->flags,
+		     "BTRFS_SPACE_INFO_???");
+	tprintf(", total_bytes=%" PRI__u64 ", used_bytes=%" PRI__u64 "}",
+		info->total_bytes, info->used_bytes);
+
+	return true;
+}
+
+MPERS_PRINTER_DECL(int, btrfs_ioctl,
+		   struct tcb *tcp, const unsigned int code, const long arg)
+{
+	switch (code) {
+	/* Take no arguments; command only. */
+	case BTRFS_IOC_TRANS_START:
+	case BTRFS_IOC_TRANS_END:
+	case BTRFS_IOC_SYNC:
+	case BTRFS_IOC_SCRUB_CANCEL:
+	case BTRFS_IOC_QUOTA_RESCAN_WAIT:
+	/*
+	 * The codes for these ioctls are based on each accepting a
+	 * vol_args but none of them actually consume an argument.
+	 */
+	case BTRFS_IOC_DEFRAG:
+	case BTRFS_IOC_BALANCE:
+		break;
+
+	/* takes a signed int */
+	case BTRFS_IOC_BALANCE_CTL:
+		tprints(", ");
+		printxval(btrfs_balance_ctl_cmds, arg, "BTRFS_BALANCE_CTL_???");
+		break;
+
+	/* returns a 64 */
+	case BTRFS_IOC_START_SYNC: /* R */
+		if (entering(tcp))
+			return 0;
+	/* fall through */
+	/* takes a u64 */
+	case BTRFS_IOC_DEFAULT_SUBVOL: /* W */
+	case BTRFS_IOC_WAIT_SYNC: /* W */
+		tprints(", ");
+		printnum_int64(tcp, arg, "%" PRIu64);
+		break;
+
+	/* u64 but describe a flags bitfield; we can make that symbolic */
+	case BTRFS_IOC_SUBVOL_GETFLAGS: { /* R */
+		uint64_t flags;
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+
+		if (umove_or_printaddr(tcp, arg, &flags))
+			break;
+
+		printflags64(btrfs_snap_flags_v2, flags, "BTRFS_SUBVOL_???");
+		break;
+	}
+
+	case BTRFS_IOC_SUBVOL_SETFLAGS: { /* W */
+		uint64_t flags;
+
+		tprints(", ");
+
+		if (umove_or_printaddr(tcp, arg, &flags))
+			break;
+
+		printflags64(btrfs_snap_flags_v2, flags, "BTRFS_SUBVOL_???");
+		break;
+	}
+
+	/* More complex types */
+	case BTRFS_IOC_BALANCE_V2: /* RW */
+		if (entering(tcp)) {
+			tprints(", ");
+			btrfs_print_balance(tcp, arg, false);
+			return 0;
+		}
+
+		if (syserror(tcp))
+			break;
+
+		tprints(" => ");
+		btrfs_print_balance(tcp, arg, true);
+		break;
+	case BTRFS_IOC_BALANCE_PROGRESS: /* R */
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		btrfs_print_balance(tcp, arg, true);
+		break;
+
+	case BTRFS_IOC_DEFRAG_RANGE: { /* W */
+		struct btrfs_ioctl_defrag_range_args args;
+
+		tprints(", ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprintf("{start=%" PRIu64 ", len=", (uint64_t)args.start);
+
+		tprintf("%" PRIu64, (uint64_t) args.len);
+		if (args.len == UINT64_MAX)
+			tprints(" /* UINT64_MAX */");
+
+		tprints(", flags=");
+		printflags64(btrfs_defrag_flags, args.flags,
+			     "BTRFS_DEFRAG_RANGE_???");
+		tprintf(", extent_thresh=%u, compress_type=",
+			args.extent_thresh);
+		printxval(btrfs_compress_types, args.compress_type,
+			  "BTRFS_COMPRESS_???");
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_DEV_INFO: { /* RW */
+		struct btrfs_ioctl_dev_info_args args;
+		char uuid[UUID_STRING_SIZE+1];
+		int valid;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+		tprints("{");
+
+		valid = btrfs_unparse_uuid(args.uuid, uuid);
+		if (entering(tcp)) {
+			tprintf("devid=%" PRI__u64, args.devid);
+			if (valid)
+				tprintf(", uuid=%s", uuid);
+			tprints("}");
+			return 0;
+		}
+		if (valid)
+			tprintf("uuid=%s, ", uuid);
+		tprintf("bytes_used=%" PRI__u64
+			", total_bytes=%" PRI__u64 ", path=",
+			args.bytes_used, args.total_bytes);
+		print_quoted_string((const char *)args.path, sizeof(args.path),
+				    QUOTE_0_TERMINATED);
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_DEV_REPLACE: { /* RW */
+		struct_btrfs_ioctl_dev_replace_args args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		if (entering(tcp)) {
+			tprints("{cmd=");
+			printxval64(btrfs_dev_replace_cmds, args.cmd,
+				    "BTRFS_IOCTL_DEV_REPLACE_CMD_???");
+			if (args.cmd == BTRFS_IOCTL_DEV_REPLACE_CMD_START) {
+				const char *str;
+				tprintf(", start={srcdevid=%" PRIu64
+				   ", cont_reading_from_srcdev_mode=%" PRIu64
+				   ", srcdev_name=",
+				   (uint64_t) args.start.srcdevid,
+				   (uint64_t) args.start.cont_reading_from_srcdev_mode);
+
+				str = (const char*) args.start.srcdev_name;
+				print_quoted_string(str,
+						sizeof(args.start.srcdev_name),
+						QUOTE_0_TERMINATED);
+				tprints(", tgtdev_name=");
+				str = (const char*) args.start.tgtdev_name;
+				print_quoted_string(str,
+						sizeof(args.start.tgtdev_name),
+						QUOTE_0_TERMINATED);
+				tprints("}");
+
+			}
+			tprints("}");
+			return 0;
+		}
+
+		tprints("{result=");
+		printxval64(btrfs_dev_replace_results, args.result,
+			    "BTRFS_IOCTL_DEV_REPLACE_RESULT_???");
+		if (args.cmd == BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS) {
+			char buf[sizeof("HH:MM:SS") + 1];
+			time_t time;
+			tprints(", ");
+			printxval64(btrfs_dev_replace_state,
+				   args.status.replace_state,
+				   "BTRFS_IOCTL_DEV_REPLACE_STATE_???");
+			tprintf(", progress_1000=%" PRIu64 " /* ",
+				(uint64_t) args.status.progress_1000);
+			if (args.status.progress_1000 <= 1000)
+				tprintf("%" PRIu64 ".%.2" PRIu64 "%%",
+					(uint64_t) args.status.progress_1000 / 10,
+					(uint64_t) args.status.progress_1000 % 10);
+			else
+				tprints("???");
+			tprints(" */ ,");
+
+			time = args.status.time_started;
+			strftime(buf, sizeof(buf), "%T",
+				 localtime(&time));
+			tprintf("time_started=%" PRIu64" /* %s */, ",
+				(uint64_t) args.status.time_started, buf);
+
+			time = args.status.time_stopped;
+			strftime(buf, sizeof(buf), "%T",
+				 localtime(&time));
+			tprintf("time_stopped=%" PRIu64" /* %s */, ",
+				(uint64_t) args.status.time_stopped, buf);
+
+			tprintf("num_write_errors=%" PRIu64
+				", num_uncorrectable_read_errors=%" PRIu64,
+				(uint64_t) args.status.num_write_errors,
+				(uint64_t) args.status.num_uncorrectable_read_errors);
+		}
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_GET_FEATURES: { /* R */
+		struct btrfs_ioctl_feature_flags flags;
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &flags))
+			break;
+
+		btrfs_print_features(&flags);
+		break;
+	}
+
+	case BTRFS_IOC_SET_FEATURES: { /* W */
+		struct btrfs_ioctl_feature_flags flarg[2];
+
+		tprints(", ");
+
+		if (umove_or_printaddr(tcp, arg, &flarg))
+			break;
+
+		tprints("[");
+		btrfs_print_features(&flarg[0]);
+		tprints(", ");
+		btrfs_print_features(&flarg[1]);
+		tprints("]");
+		break;
+	}
+
+	case BTRFS_IOC_GET_SUPPORTED_FEATURES: { /* R */
+		struct btrfs_ioctl_feature_flags flarg[3];
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &flarg))
+			break;
+
+		tprints("[ /* supported */ ");
+		btrfs_print_features(&flarg[0]);
+
+		tprints(", /* safe to set */ ");
+		btrfs_print_features(&flarg[1]);
+
+		tprints(", /* safe to clear */ ");
+		btrfs_print_features(&flarg[2]);
+		tprints("]");
+
+		break;
+	}
+
+	case BTRFS_IOC_FS_INFO: { /* R */
+		struct btrfs_ioctl_fs_info_args args;
+		char uuid[UUID_STRING_SIZE+1];
+		uint32_t nodesize, sectorsize, clone_alignment;
+#ifndef HAVE_STRUCT_BTRFS_IOCTL_FS_INFO_ARGS_NODESIZE
+		__u32 *reserved32;
+#endif
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+#ifdef HAVE_STRUCT_BTRFS_IOCTL_FS_INFO_ARGS_NODESIZE
+		nodesize = args.nodesize,
+		sectorsize = args.sectorsize,
+		clone_alignment = args.clone_alignment;
+#else
+		reserved32 = (__u32 *) (void *) args.reserved;
+		nodesize = reserved32[0];
+		sectorsize = reserved32[1];
+		clone_alignment = reserved32[2];
+#endif
+		btrfs_unparse_uuid(args.fsid, uuid);
+
+		tprints("{");
+		tprintf("max_id=%" PRI__u64 ", num_devices=%" PRI__u64
+			", fsid=%s, nodesize=%u, sectorsize=%u"
+			", clone_alignment=%u",
+			args.max_id, args.num_devices, uuid,
+			nodesize, sectorsize, clone_alignment);
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_GET_DEV_STATS: { /* RW */
+		struct btrfs_ioctl_get_dev_stats args;
+		uint64_t i;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{");
+
+		if (entering(tcp))
+			tprintf("devid=%" PRI__u64 ", ", args.devid);
+
+		tprintf("nr_items=%" PRI__u64 ", flags=", args.nr_items);
+		printflags64(btrfs_dev_stats_flags, args.flags,
+			     "BTRFS_DEV_STATS_???");
+
+		if (entering(tcp)) {
+			tprints("}");
+			return 0;
+		}
+
+		/*
+		 * The structure has a 1k limit; Let's make sure we don't
+		 * go off into the middle of nowhere with a bad nr_items
+		 * value.
+		 */
+		tprints(", [");
+		for (i = 0; i < args.nr_items; i++) {
+			if (i)
+				tprints(", ");
+			if (i >= ARRAY_SIZE(args.values)) {
+				tprints("...");
+				break;
+			}
+			const char *name = xlookup(btrfs_dev_stats_values, i);
+			if (name)
+				tprintf("/* %s */ ", name);
+			tprintf("%" PRI__u64, args.values[i]);
+		}
+		tprints("]}");
+		break;
+	}
+
+	case BTRFS_IOC_INO_LOOKUP: { /* RW */
+		struct btrfs_ioctl_ino_lookup_args args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		if (entering(tcp)) {
+			/* Use subvolume id of the containing root */
+			if (args.treeid == 0)
+				set_tcb_priv_ulong(tcp, 1);
+
+			tprints("{treeid=");
+			btrfs_print_objectid(args.treeid);
+			tprints(", objectid=");
+			btrfs_print_objectid(args.objectid);
+			tprints("}");
+			return 0;
+		}
+
+		tprints("{");
+		if (get_tcb_priv_ulong(tcp)) {
+			tprints("treeid=");
+			btrfs_print_objectid(args.treeid);
+			tprints(", ");
+		}
+
+		tprints("name=");
+		print_quoted_string(args.name, sizeof(args.name),
+				    QUOTE_0_TERMINATED);
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_INO_PATHS: { /* RW */
+		struct btrfs_ioctl_ino_path_args args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{");
+
+		if (entering(tcp)) {
+			tprintf("inum=%" PRI__u64 ", size=%" PRI__u64,
+				args.inum, args.size);
+			tprintf(", fspath=0x%" PRI__x64 "}", args.fspath);
+			return 0;
+		}
+
+		tprints("fspath=");
+		btrfs_print_ino_path_container(tcp, args.fspath);
+
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_LOGICAL_INO: { /* RW */
+		struct btrfs_ioctl_logical_ino_args args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{");
+
+		if (entering(tcp)) {
+			tprintf("logical=%" PRI__u64 ", size=%" PRI__u64,
+				args.logical, args.size);
+			tprintf(", inodes=0x%" PRI__x64 "}", args.inodes);
+			return 0;
+		}
+
+		tprints("inodes=");
+		btrfs_print_logical_ino_container(tcp, args.inodes);
+
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_QGROUP_ASSIGN: { /* W */
+		struct btrfs_ioctl_qgroup_assign_args args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprintf("{assign=%" PRI__u64 ", src=%" PRI__u64
+			", dst=%" PRI__u64 "}",
+			args.assign, args.src, args.dst);
+		break;
+	}
+
+	case BTRFS_IOC_QGROUP_CREATE: { /* W */
+		struct btrfs_ioctl_qgroup_create_args args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprintf("{create=%" PRI__u64 ", qgroupid=%" PRI__u64 "}",
+			args.create, args.qgroupid);
+		break;
+	}
+
+	case BTRFS_IOC_QGROUP_LIMIT: { /* R */
+		struct btrfs_ioctl_qgroup_limit_args args;
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprintf("{qgroupid=%" PRI__u64 ", lim=", args.qgroupid);
+		btrfs_print_qgroup_limit(&args.lim);
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_QUOTA_CTL: { /* W */
+		struct btrfs_ioctl_quota_ctl_args args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		printxval64(btrfs_qgroup_ctl_cmds, args.cmd,
+			    "BTRFS_QUOTA_CTL_???");
+		tprints("}");
+
+		break;
+	}
+
+	case BTRFS_IOC_QUOTA_RESCAN: { /* W */
+		struct btrfs_ioctl_quota_rescan_args args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprintf("{flags=%" PRIu64 "}", (uint64_t) args.flags);
+		break;
+	}
+
+	case BTRFS_IOC_QUOTA_RESCAN_STATUS: { /* R */
+		struct btrfs_ioctl_quota_rescan_args args;
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprintf("{flags=%" PRIu64 ", progress=", (uint64_t) args.flags);
+		btrfs_print_objectid(args.progress);
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_SET_RECEIVED_SUBVOL: { /* RW */
+		struct_btrfs_ioctl_received_subvol_args args;
+		char uuid[UUID_STRING_SIZE+1];
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		if (entering(tcp)) {
+			btrfs_unparse_uuid((unsigned char *)args.uuid, uuid);
+			tprintf("{uuid=%s, stransid=%" PRIu64
+				", stime=%" PRIu64 ".%u, flags=%" PRIu64
+				"}", uuid, (uint64_t) args.stransid,
+				(uint64_t) args.stime.sec, args.stime.nsec,
+				(uint64_t) args.flags);
+			return 0;
+		}
+		tprintf("{rtransid=%" PRIu64 ", rtime=%" PRIu64 ".%u}",
+			(uint64_t) args.rtransid, (uint64_t) args.rtime.sec,
+			args.rtime.nsec);
+		break;
+	}
+
+	case BTRFS_IOC_SCRUB: /* RW */
+	case BTRFS_IOC_SCRUB_PROGRESS: { /* RW */
+		struct btrfs_ioctl_scrub_args args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		if (entering(tcp)) {
+			tprintf("{devid=%" PRI__u64, args.devid);
+			if (code == BTRFS_IOC_SCRUB) {
+				tprintf(", start=%" PRI__u64 ", end=",
+					args.start);
+				tprintf("%" PRI__u64, args.end);
+				if (args.end == UINT64_MAX)
+					tprints(" /* UINT64_MAX */");
+				tprints(", flags=");
+				printflags64(btrfs_scrub_flags, args.flags,
+					     "BTRFS_SCRUB_???");
+			}
+			tprints("}");
+			return 0;
+		}
+		tprintf("{data_extents_scrubbed=%" PRI__u64
+			", tree_extents_scrubbed=%" PRI__u64
+			", data_bytes_scrubbed=%" PRI__u64
+			", tree_bytes_scrubbed=%" PRI__u64
+			", read_errors=%" PRI__u64
+			", csum_errors=%" PRI__u64
+			", verify_errors=%" PRI__u64
+			", no_csum=%" PRI__u64
+			", csum_discards=%" PRI__u64
+			", super_errors=%" PRI__u64
+			", malloc_errors=%" PRI__u64
+			", uncorrectable_errors=%" PRI__u64
+			", corrected_errors=%" PRI__u64
+			", last_physical=%" PRI__u64
+			", unverified_errors=%" PRI__u64 "}",
+			args.progress.data_extents_scrubbed,
+			args.progress.tree_extents_scrubbed,
+			args.progress.data_bytes_scrubbed,
+			args.progress.tree_bytes_scrubbed,
+			args.progress.read_errors,
+			args.progress.csum_errors,
+			args.progress.verify_errors,
+			args.progress.no_csum,
+			args.progress.csum_discards,
+			args.progress.super_errors,
+			args.progress.malloc_errors,
+			args.progress.uncorrectable_errors,
+			args.progress.corrected_errors,
+			args.progress.last_physical,
+			args.progress.unverified_errors);
+		break;
+	}
+
+	case BTRFS_IOC_TREE_SEARCH: { /* RW */
+		struct btrfs_ioctl_search_args args;
+		uint64_t buf_offset;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		buf_offset = offsetof(struct btrfs_ioctl_search_args, buf);
+		btrfs_print_tree_search(tcp, &args.key, arg + buf_offset,
+					sizeof(args.buf), false);
+		if (entering(tcp))
+			return 0;
+		break;
+	}
+
+	case BTRFS_IOC_TREE_SEARCH_V2: { /* RW */
+		struct btrfs_ioctl_search_args_v2 args;
+		uint64_t buf_offset;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp)) {
+			if (tcp->u_error == EOVERFLOW) {
+				tprints(" => ");
+				tcp->u_error = 0;
+				if (!umove_or_printaddr(tcp, arg, &args))
+					tprintf("{buf_size=%" PRIu64 "}",
+						(uint64_t)args.buf_size);
+				tcp->u_error = EOVERFLOW;
+			}
+			break;
+		} else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		buf_offset = offsetof(struct btrfs_ioctl_search_args_v2, buf);
+		btrfs_print_tree_search(tcp, &args.key, arg + buf_offset,
+					args.buf_size, true);
+		if (entering(tcp))
+			return 0;
+		break;
+	}
+
+	case BTRFS_IOC_SEND: { /* W */
+		struct_btrfs_ioctl_send_args args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{send_fd=");
+		printfd(tcp, args.send_fd);
+		tprintf(", clone_sources_count=%" PRIu64 ", clone_sources=",
+			(uint64_t) args.clone_sources_count);
+
+		if (abbrev(tcp))
+			tprints("...");
+		else {
+			uint64_t record;
+			print_array(tcp, (unsigned long) args.clone_sources,
+				    args.clone_sources_count,
+				    &record, sizeof(record),
+				    umoven_or_printaddr,
+				    print_objectid_callback, 0);
+		}
+		tprints(", parent_root=");
+		btrfs_print_objectid(args.parent_root);
+		tprints(", flags=");
+		printflags64(btrfs_send_flags, args.flags,
+			     "BTRFS_SEND_FLAGS_???");
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_SPACE_INFO: { /* RW */
+		struct btrfs_ioctl_space_args args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{");
+		if (entering(tcp)) {
+			tprintf("space_slots=%" PRI__u64 "}", args.space_slots);
+			return 0;
+		}
+
+		tprintf("total_spaces=%" PRI__u64, args.total_spaces);
+
+		if (args.space_slots == 0 && args.total_spaces) {
+			tprints("}");
+			break;
+		}
+
+		tprints(", spaces=");
+
+		if (abbrev(tcp))
+			tprints("...");
+		else {
+			struct btrfs_ioctl_space_info info;
+			print_array(tcp, arg + offsetof(typeof(args), spaces),
+				    args.total_spaces,
+				    &info, sizeof(info), umoven_or_printaddr,
+				    print_btrfs_ioctl_space_info, 0);
+		}
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_SNAP_CREATE:
+	case BTRFS_IOC_RESIZE:
+	case BTRFS_IOC_SCAN_DEV:
+	case BTRFS_IOC_ADD_DEV:
+	case BTRFS_IOC_RM_DEV:
+	case BTRFS_IOC_SUBVOL_CREATE:
+	case BTRFS_IOC_SNAP_DESTROY:
+	case BTRFS_IOC_DEVICES_READY: { /* W */
+		struct btrfs_ioctl_vol_args args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{fd=");
+		printfd(tcp, args.fd);
+		tprints(", name=");
+		print_quoted_string(args.name, sizeof(args.name),
+				    QUOTE_0_TERMINATED);
+		tprints("}");
+		break;
+	}
+
+	case BTRFS_IOC_SNAP_CREATE_V2:
+	case BTRFS_IOC_SUBVOL_CREATE_V2: { /* code is W, but is actually RW */
+		struct btrfs_ioctl_vol_args_v2 args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		if (entering(tcp)) {
+			tprints("{fd=");
+			printfd(tcp, args.fd);
+			tprints(", flags=");
+			printflags64(btrfs_snap_flags_v2, args.flags,
+				     "BTRFS_SUBVOL_???");
+			if (args.flags & BTRFS_SUBVOL_QGROUP_INHERIT) {
+				tprintf(", size=%" PRI__u64 ", qgroup_inherit=",
+					args.size);
+
+				btrfs_print_qgroup_inherit(tcp,
+					(unsigned long)args.qgroup_inherit);
+			}
+			tprintf(", name=");
+			print_quoted_string(args.name, sizeof(args.name),
+					    QUOTE_0_TERMINATED);
+			tprints("}");
+			return 0;
+		}
+		tprintf("{transid=%" PRI__u64 "}", args.transid);
+		break;
+	}
+
+	case BTRFS_IOC_GET_FSLABEL: /* R */
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case BTRFS_IOC_SET_FSLABEL: { /* W */
+		char label[BTRFS_LABEL_SIZE];
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &label))
+			break;
+		print_quoted_string(label, sizeof(label), QUOTE_0_TERMINATED);
+		break;
+	}
+
+	case BTRFS_IOC_CLONE:			/* FICLONE */
+	case BTRFS_IOC_CLONE_RANGE:		/* FICLONERANGE */
+#ifdef BTRFS_IOC_FILE_EXTENT_SAME
+	case BTRFS_IOC_FILE_EXTENT_SAME:	/* FIDEDUPERANGE */
+#endif
+		/*
+		 * FICLONE, FICLONERANGE, and FIDEDUPERANGE started out as
+		 * btrfs ioctls and the code was kept for the generic
+		 * implementations.  We use the BTRFS_* names here because
+		 * they will be available on older systems.
+		 */
+		return file_ioctl(tcp, code, arg);
+
+	default:
+		return RVAL_DECODED;
+	};
+	return RVAL_DECODED | 1;
+}
+#endif /* HAVE_LINUX_BTRFS_H */
diff --git a/strace/cacheflush.c b/strace/cacheflush.c
new file mode 100644
index 0000000..8c2c05c
--- /dev/null
+++ b/strace/cacheflush.c
@@ -0,0 +1,133 @@
+/*
+ * Copyright (c) 1999 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
+ * Copyright (c) 2010 Mike Frysinger <vapier@gentoo.org>
+ * Copyright (c) 2010 Carmelo Amoroso <carmelo.amoroso@st.com>
+ * Copyright (c) 2015 Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_ASM_CACHECTL_H
+# include <asm/cachectl.h>
+#endif
+
+#ifdef M68K
+# include "xlat/cacheflush_scope.h"
+
+static const struct xlat cacheflush_flags[] = {
+#ifdef FLUSH_CACHE_BOTH
+	XLAT(FLUSH_CACHE_BOTH),
+#endif
+#ifdef FLUSH_CACHE_DATA
+	XLAT(FLUSH_CACHE_DATA),
+#endif
+#ifdef FLUSH_CACHE_INSN
+	XLAT(FLUSH_CACHE_INSN),
+#endif
+	XLAT_END
+};
+
+SYS_FUNC(cacheflush)
+{
+	/* addr */
+	printaddr(tcp->u_arg[0]);
+	tprints(", ");
+	/* scope */
+	printxval(cacheflush_scope, tcp->u_arg[1], "FLUSH_SCOPE_???");
+	tprints(", ");
+	/* flags */
+	printflags(cacheflush_flags, tcp->u_arg[2], "FLUSH_CACHE_???");
+	/* len */
+	tprintf(", %lu", tcp->u_arg[3]);
+
+	return RVAL_DECODED;
+}
+#endif /* M68K */
+
+#ifdef BFIN
+static const struct xlat cacheflush_flags[] = {
+	XLAT(ICACHE),
+	XLAT(DCACHE),
+	XLAT(BCACHE),
+	XLAT_END
+};
+
+SYS_FUNC(cacheflush)
+{
+	/* start addr */
+	printaddr(tcp->u_arg[0]);
+	/* length */
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	/* flags */
+	printxval(cacheflush_flags, tcp->u_arg[2], "?CACHE");
+
+	return RVAL_DECODED;
+}
+#endif /* BFIN */
+
+#ifdef SH
+static const struct xlat cacheflush_flags[] = {
+#ifdef CACHEFLUSH_D_INVAL
+	XLAT(CACHEFLUSH_D_INVAL),
+#endif
+#ifdef CACHEFLUSH_D_WB
+	XLAT(CACHEFLUSH_D_WB),
+#endif
+#ifdef CACHEFLUSH_D_PURGE
+	XLAT(CACHEFLUSH_D_PURGE),
+#endif
+#ifdef CACHEFLUSH_I
+	XLAT(CACHEFLUSH_I),
+#endif
+	XLAT_END
+};
+
+SYS_FUNC(cacheflush)
+{
+	/* addr */
+	printaddr(tcp->u_arg[0]);
+	/* len */
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	/* flags */
+	printflags(cacheflush_flags, tcp->u_arg[2], "CACHEFLUSH_???");
+
+	return RVAL_DECODED;
+}
+#endif /* SH */
+
+#ifdef NIOS2
+SYS_FUNC(cacheflush)
+{
+	/* addr */
+	printaddr(tcp->u_arg[0]);
+	/* len */
+	tprintf(", %lu, ", tcp->u_arg[3]);
+	/* scope and flags (cache type) are currently ignored */
+
+	return RVAL_DECODED;
+}
+#endif /* NIOS2 */
diff --git a/strace/capability.c b/strace/capability.c
new file mode 100644
index 0000000..421649d
--- /dev/null
+++ b/strace/capability.c
@@ -0,0 +1,159 @@
+/*
+ * Copyright (c) 2000 Wichert Akkerman <wakkerma@debian.org>
+ * Copyright (c) 2011 Denys Vlasenko <dvlasenk@redhat.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+/* these constants are the same as in <linux/capability.h> */
+enum {
+#include "caps0.h"
+};
+
+#include "xlat/cap_mask0.h"
+
+/* these constants are CAP_TO_INDEX'ed constants from <linux/capability.h> */
+enum {
+#include "caps1.h"
+};
+
+#include "xlat/cap_mask1.h"
+
+/* these constants are the same as in <linux/capability.h> */
+enum {
+	_LINUX_CAPABILITY_VERSION_1 = 0x19980330,
+	_LINUX_CAPABILITY_VERSION_2 = 0x20071026,
+	_LINUX_CAPABILITY_VERSION_3 = 0x20080522
+};
+
+#include "xlat/cap_version.h"
+
+typedef struct user_cap_header_struct {
+	uint32_t version;
+	int pid;
+} *cap_user_header_t;
+
+typedef struct user_cap_data_struct {
+	uint32_t effective;
+	uint32_t permitted;
+	uint32_t inheritable;
+} *cap_user_data_t;
+
+static cap_user_header_t
+get_cap_header(struct tcb *tcp, unsigned long addr)
+{
+	static struct user_cap_header_struct header;
+
+	if (!addr || !verbose(tcp))
+		return NULL;
+
+	if (umove(tcp, addr, &header) < 0)
+		return NULL;
+
+	return &header;
+}
+
+static void
+print_cap_header(struct tcb *tcp, unsigned long addr, cap_user_header_t h)
+{
+	if (!addr || !h) {
+		printaddr(addr);
+		return;
+	}
+
+	tprints("{");
+	printxval(cap_version, h->version,
+		  "_LINUX_CAPABILITY_VERSION_???");
+	tprintf(", %d}", h->pid);
+}
+
+static void
+print_cap_bits(const uint32_t lo, const uint32_t hi)
+{
+	if (lo || !hi)
+		printflags(cap_mask0, lo, "CAP_???");
+
+	if (hi) {
+		if (lo)
+			tprints("|");
+		printflags(cap_mask1, hi, "CAP_???");
+	}
+}
+
+static void
+print_cap_data(struct tcb *tcp, unsigned long addr, const cap_user_header_t h)
+{
+	struct user_cap_data_struct data[2];
+	unsigned int len;
+
+	if (!addr || !h) {
+		printaddr(addr);
+		return;
+	}
+
+	if (_LINUX_CAPABILITY_VERSION_2 == h->version ||
+	    _LINUX_CAPABILITY_VERSION_3 == h->version)
+		len = 2;
+	else
+		len = 1;
+
+	if (umoven_or_printaddr(tcp, addr, len * sizeof(data[0]), data))
+		return;
+
+	tprints("{");
+	print_cap_bits(data[0].effective, len > 1 ? data[1].effective : 0);
+	tprints(", ");
+	print_cap_bits(data[0].permitted, len > 1 ? data[1].permitted : 0);
+	tprints(", ");
+	print_cap_bits(data[0].inheritable, len > 1 ? data[1].inheritable : 0);
+	tprints("}");
+}
+
+SYS_FUNC(capget)
+{
+	cap_user_header_t h;
+
+	if (entering(tcp)) {
+		h = get_cap_header(tcp, tcp->u_arg[0]);
+		print_cap_header(tcp, tcp->u_arg[0], h);
+		tprints(", ");
+	} else {
+		h = syserror(tcp) ? NULL : get_cap_header(tcp, tcp->u_arg[0]);
+		print_cap_data(tcp, tcp->u_arg[1], h);
+	}
+	return 0;
+}
+
+SYS_FUNC(capset)
+{
+	cap_user_header_t h = get_cap_header(tcp, tcp->u_arg[0]);
+	print_cap_header(tcp, tcp->u_arg[0], h);
+	tprints(", ");
+	print_cap_data(tcp, tcp->u_arg[1], h);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/caps0.h b/strace/caps0.h
new file mode 100644
index 0000000..ad206ff
--- /dev/null
+++ b/strace/caps0.h
@@ -0,0 +1,32 @@
+CAP_CHOWN,
+CAP_DAC_OVERRIDE,
+CAP_DAC_READ_SEARCH,
+CAP_FOWNER,
+CAP_FSETID,
+CAP_KILL,
+CAP_SETGID,
+CAP_SETUID,
+CAP_SETPCAP,
+CAP_LINUX_IMMUTABLE,
+CAP_NET_BIND_SERVICE,
+CAP_NET_BROADCAST,
+CAP_NET_ADMIN,
+CAP_NET_RAW,
+CAP_IPC_LOCK,
+CAP_IPC_OWNER,
+CAP_SYS_MODULE,
+CAP_SYS_RAWIO,
+CAP_SYS_CHROOT,
+CAP_SYS_PTRACE,
+CAP_SYS_PACCT,
+CAP_SYS_ADMIN,
+CAP_SYS_BOOT,
+CAP_SYS_NICE,
+CAP_SYS_RESOURCE,
+CAP_SYS_TIME,
+CAP_SYS_TTY_CONFIG,
+CAP_MKNOD,
+CAP_LEASE,
+CAP_AUDIT_WRITE,
+CAP_AUDIT_CONTROL,
+CAP_SETFCAP,
diff --git a/strace/caps1.h b/strace/caps1.h
new file mode 100644
index 0000000..d8fa6f4
--- /dev/null
+++ b/strace/caps1.h
@@ -0,0 +1,6 @@
+CAP_MAC_OVERRIDE,
+CAP_MAC_ADMIN,
+CAP_SYSLOG,
+CAP_WAKE_ALARM,
+CAP_BLOCK_SUSPEND,
+CAP_AUDIT_READ,
diff --git a/strace/chdir.c b/strace/chdir.c
new file mode 100644
index 0000000..e8ac285
--- /dev/null
+++ b/strace/chdir.c
@@ -0,0 +1,8 @@
+#include "defs.h"
+
+SYS_FUNC(chdir)
+{
+	printpath(tcp, tcp->u_arg[0]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/chmod.c b/strace/chmod.c
new file mode 100644
index 0000000..83741c9
--- /dev/null
+++ b/strace/chmod.c
@@ -0,0 +1,31 @@
+#include "defs.h"
+
+static void
+decode_chmod(struct tcb *tcp, const int offset)
+{
+	printpath(tcp, tcp->u_arg[offset]);
+	tprintf(", %#lo", tcp->u_arg[offset + 1]);
+}
+
+SYS_FUNC(chmod)
+{
+	decode_chmod(tcp, 0);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fchmodat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	decode_chmod(tcp, 1);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fchmod)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprintf(", %#lo", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/clone.c b/strace/clone.c
new file mode 100644
index 0000000..99d0da7
--- /dev/null
+++ b/strace/clone.c
@@ -0,0 +1,161 @@
+/*
+ * Copyright (c) 1999-2000 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2002-2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2008 Jan Kratochvil <jan.kratochvil@redhat.com>
+ * Copyright (c) 2009-2013 Denys Vlasenko <dvlasenk@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sched.h>
+
+#ifndef CSIGNAL
+# define CSIGNAL 0x000000ff
+#endif
+
+#include "xlat/clone_flags.h"
+
+#if defined IA64
+# define ARG_FLAGS	0
+# define ARG_STACK	1
+# define ARG_STACKSIZE	(tcp->scno == SYS_clone2 ? 2 : -1)
+# define ARG_PTID	(tcp->scno == SYS_clone2 ? 3 : 2)
+# define ARG_CTID	(tcp->scno == SYS_clone2 ? 4 : 3)
+# define ARG_TLS	(tcp->scno == SYS_clone2 ? 5 : 4)
+#elif defined S390 || defined S390X || defined CRISV10 || defined CRISV32
+# define ARG_STACK	0
+# define ARG_FLAGS	1
+# define ARG_PTID	2
+# define ARG_CTID	3
+# define ARG_TLS	4
+#elif defined X86_64 || defined X32
+/* x86 personality processes have the last two arguments flipped. */
+# define ARG_FLAGS	0
+# define ARG_STACK	1
+# define ARG_PTID	2
+# define ARG_CTID	((current_personality != 1) ? 3 : 4)
+# define ARG_TLS	((current_personality != 1) ? 4 : 3)
+#elif defined ALPHA || defined TILE || defined OR1K
+# define ARG_FLAGS	0
+# define ARG_STACK	1
+# define ARG_PTID	2
+# define ARG_CTID	3
+# define ARG_TLS	4
+#else
+# define ARG_FLAGS	0
+# define ARG_STACK	1
+# define ARG_PTID	2
+# define ARG_TLS	3
+# define ARG_CTID	4
+#endif
+
+#if defined I386 || defined X86_64 || defined X32
+extern void print_user_desc(struct tcb *, long);
+#endif /* I386 || X86_64 || X32 */
+
+SYS_FUNC(clone)
+{
+	if (exiting(tcp)) {
+		const char *sep = "|";
+		unsigned long flags = tcp->u_arg[ARG_FLAGS];
+		tprints("child_stack=");
+		printaddr(tcp->u_arg[ARG_STACK]);
+		tprints(", ");
+#ifdef ARG_STACKSIZE
+		if (ARG_STACKSIZE != -1)
+			tprintf("stack_size=%#lx, ",
+				tcp->u_arg[ARG_STACKSIZE]);
+#endif
+		tprints("flags=");
+		if (!printflags(clone_flags, flags &~ CSIGNAL, NULL))
+			sep = "";
+		if ((flags & CSIGNAL) != 0)
+			tprintf("%s%s", sep, signame(flags & CSIGNAL));
+		if ((flags & (CLONE_PARENT_SETTID|CLONE_CHILD_SETTID
+			      |CLONE_CHILD_CLEARTID|CLONE_SETTLS)) == 0)
+			return 0;
+		if (flags & CLONE_PARENT_SETTID) {
+			tprints(", parent_tidptr=");
+			printaddr(tcp->u_arg[ARG_PTID]);
+		}
+		if (flags & CLONE_SETTLS) {
+#if defined I386 || defined X86_64 || defined X32
+# ifndef I386
+			if (current_personality == 1)
+# endif
+			{
+				tprints(", tls=");
+				print_user_desc(tcp, tcp->u_arg[ARG_TLS]);
+			}
+# ifndef I386
+			else
+# endif
+#endif /* I386 || X86_64 || X32 */
+			{
+				tprints(", tls=");
+				printaddr(tcp->u_arg[ARG_TLS]);
+			}
+		}
+		if (flags & (CLONE_CHILD_SETTID|CLONE_CHILD_CLEARTID)) {
+			tprints(", child_tidptr=");
+			printaddr(tcp->u_arg[ARG_CTID]);
+		}
+	}
+	/* TODO on syscall entry:
+	 * We can clear CLONE_PTRACE here since it is an ancient hack
+	 * to allow us to catch children, and we use another hack for that.
+	 * But CLONE_PTRACE can conceivably be used by malicious programs
+	 * to subvert us. By clearing this bit, we can defend against it:
+	 * in untraced execution, CLONE_PTRACE should have no effect.
+	 *
+	 * We can also clear CLONE_UNTRACED, since it allows to start
+	 * children outside of our control. At the moment
+	 * I'm trying to figure out whether there is a *legitimate*
+	 * use of this flag which we should respect.
+	 */
+	return 0;
+}
+
+SYS_FUNC(setns)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printflags(clone_flags, tcp->u_arg[1], "CLONE_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(unshare)
+{
+	printflags_long(clone_flags, tcp->u_arg[0], "CLONE_???");
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fork)
+{
+	return RVAL_DECODED | RVAL_UDECIMAL;
+}
diff --git a/strace/configure.ac b/strace/configure.ac
new file mode 100644
index 0000000..4af1649
--- /dev/null
+++ b/strace/configure.ac
@@ -0,0 +1,790 @@
+# Configure template for strace.
+#
+# Copyright (c) 1999-2001 Wichert Akkerman <wichert@deephackmode.org>
+# Copyright (c) 2002-2009 Roland McGrath <roland@redhat.com>
+# Copyright (c) 2006-2016 Dmitry V. Levin <ldv@altlinux.org>
+# Copyright (c) 2008-2015 Mike Frysinger <vapier@gentoo.org>
+# Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+# 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.
+
+AC_PREREQ(2.57)
+AC_INIT([strace],
+	m4_esyscmd([./git-version-gen .tarball-version]),
+	[strace-devel@lists.sourceforge.net])
+AC_CONFIG_SRCDIR([strace.c])
+AC_CONFIG_AUX_DIR([.])
+AC_CONFIG_HEADERS([config.h])
+AM_INIT_AUTOMAKE([foreign nostdinc dist-xz silent-rules parallel-tests])
+AM_MAINTAINER_MODE
+AC_CANONICAL_HOST
+
+RPM_CHANGELOGTIME="$(LC_TIME=C date '+%a %b %d %Y')"
+AC_SUBST(RPM_CHANGELOGTIME)
+DEB_CHANGELOGTIME="$(LC_TIME=C date -R)"
+AC_SUBST(DEB_CHANGELOGTIME)
+
+AC_PROG_CC
+AC_PROG_CPP
+AX_PROG_CC_FOR_BUILD
+AC_PROG_INSTALL
+AC_PROG_RANLIB
+
+AC_USE_SYSTEM_EXTENSIONS
+AX_CODE_COVERAGE
+
+AC_MSG_CHECKING([for supported architecture])
+arch_m32=
+arch_mx32=
+case "$host_cpu" in
+bfin)
+	arch=bfin
+	AC_DEFINE([BFIN], 1, [Define for the Blackfin architecture.])
+	;;
+i[[3456]]86|pentium)
+	arch=i386
+	AC_DEFINE([I386], 1, [Define for the i386 architecture.])
+	;;
+ia64)
+	arch=ia64
+	AC_DEFINE([IA64], 1, [Define for the IA64 architecture.])
+	;;
+m68k)
+	arch=m68k
+	AC_DEFINE([M68K], 1, [Define for the m68k architecture.])
+	;;
+sparc64*)
+	arch=sparc64
+	arch_m32=sparc
+	AC_DEFINE([SPARC64], 1, [Define for the SPARC64 architecture.])
+	;;
+sparc*)
+	arch=sparc
+	AC_DEFINE([SPARC], 1, [Define for the SPARC architecture.])
+	;;
+metag*)
+	arch=metag
+	AC_DEFINE([METAG], 1, [Define for the Meta architecture.])
+	;;
+mips*)
+	arch=mips
+	AC_DEFINE([MIPS], 1, [Define for the MIPS architecture.])
+	;;
+alpha*)
+	arch=alpha
+	AC_DEFINE([ALPHA], 1, [Define for the Alpha architecture.])
+	;;
+powerpc*)
+	AC_DEFINE([POWERPC], 1, [Define for the PowerPC architecture.])
+	AC_TRY_COMPILE(
+[#ifndef __LP64__
+# error 32 bit
+#endif], [], arch=powerpc64, arch=powerpc)
+	if test "$arch" = "powerpc64"; then
+		arch_m32=powerpc
+		AC_DEFINE([POWERPC64], 1, [Define for the PowerPC64 architecture.])
+	fi
+	;;
+arm*)
+	arch=arm
+	AC_DEFINE([ARM], 1, [Define for the ARM architecture.])
+	;;
+aarch64*)
+	arch=aarch64
+	arch_m32=arm
+	AC_DEFINE([AARCH64], 1, [Define for the AArch64 architecture.])
+	;;
+avr32*)
+	arch=avr32
+	AC_DEFINE([AVR32], 1, [Define for the AVR32 architecture.])
+	;;
+arc*)
+	arch=arc
+	AC_DEFINE([ARC], 1, [Define for the ARC architecture.])
+	;;
+s390)
+	arch=s390
+	AC_DEFINE([S390], 1, [Define for the S390 architecture.])
+	;;
+s390x)
+	arch=s390x
+	AC_DEFINE([S390X], 1, [Define for the S390x architecture.])
+	;;
+hppa*|parisc*)
+	arch=hppa
+	AC_DEFINE([HPPA], 1, [Define for the HPPA architecture.])
+	;;
+sh64*)
+	arch=sh64
+	AC_DEFINE([SH64], 1, [Define for the SH64 architecture.])
+	;;
+sh*)
+	arch=sh
+	AC_DEFINE([SH], 1, [Define for the SH architecture.])
+	;;
+x86?64*)
+	arch_m32=i386
+	AC_TRY_COMPILE(
+[#ifndef __ILP32__
+# error not x32
+#endif], [], arch=x32, arch=x86_64)
+	if test "$arch" = "x86_64"; then
+		arch_mx32=x32
+		AC_DEFINE([X86_64], 1, [Define for the 64bit AMD x86-64 architecture.])
+	else
+		AC_DEFINE([X32], 1, [Define for the 32bit AMD x86-64 architecture.])
+	fi
+	;;
+cris|crisv10)
+	arch=crisv10
+	AC_DEFINE([CRISV10], 1, [Define for the CRISv10 architecture.])
+	;;
+crisv32)
+	arch=crisv32
+	AC_DEFINE([CRISV32], 1, [Define for the CRISv32 architecture.])
+	;;
+tile*)
+	arch=tile
+	AC_DEFINE([TILE], 1, [Define for the Tile architecture])
+	;;
+microblaze*)
+	arch=microblaze
+	AC_DEFINE([MICROBLAZE], 1, [Define for the MicroBlaze architecture.])
+	;;
+nios2*)
+	arch=nios2
+	AC_DEFINE([NIOS2], 1, [Define for the Nios-II architecture.])
+	;;
+
+or1k*)
+	arch=or1k
+	AC_DEFINE([OR1K], 1, [Define for the OpenRISC 1000 architecture.])
+	;;
+
+xtensa*)
+	arch=xtensa
+	AC_DEFINE([XTENSA], 1, [Define for the Xtensa architecture])
+	;;
+
+*)
+	AC_MSG_RESULT([NO!])
+	AC_MSG_ERROR([architecture $host_cpu is not supported by strace])
+	;;
+esac
+AC_MSG_RESULT($arch)
+
+test -n "$arch_m32" ||
+	arch_m32=$arch
+test -n "$arch_mx32" ||
+	arch_mx32=$arch
+AC_SUBST(arch)
+AC_SUBST(arch_m32)
+AC_SUBST(arch_mx32)
+
+if test "$arch" = mips; then
+	AC_CACHE_CHECK([for _MIPS_SIM], [st_cv__MIPS_SIM],
+		       [AC_COMPUTE_INT([st_cv__MIPS_SIM], [_MIPS_SIM],
+				       [#include <sgidefs.h>],
+				       [AC_MSG_ERROR([_MIPS_SIM cannot be determined])])])
+
+	AC_CACHE_CHECK([for MIPS ABI], [st_cv_mips_abi],
+		[AC_COMPILE_IFELSE(
+			[AC_LANG_PROGRAM([[#include <sgidefs.h>]],
+					 [[int i[_MIPS_SIM == _MIPS_SIM_ABI32 ? 1 : - 1];]])],
+			[st_cv_mips_abi=o32],
+		[AC_COMPILE_IFELSE(
+			[AC_LANG_PROGRAM([[#include <sgidefs.h>]],
+					 [[int i[_MIPS_SIM == _MIPS_SIM_NABI32 ? 1 : - 1];]])],
+			[st_cv_mips_abi=n32],
+		[AC_COMPILE_IFELSE(
+			[AC_LANG_PROGRAM([[#include <sgidefs.h>]],
+					 [[int i[_MIPS_SIM == _MIPS_SIM_ABI64 ? 1 : - 1];]])],
+			[st_cv_mips_abi=n64],
+			[st_cv_mips_abi=unknown])])])])
+
+	case "$st_cv_mips_abi" in
+		o32) AC_DEFINE([LINUX_MIPSO32], [1], [Define for _MIPS_SIM_ABI32.]);;
+		n32) AC_DEFINE([LINUX_MIPSN32], [1], [Define for _MIPS_SIM_NABI32.]);;
+		n64) AC_DEFINE([LINUX_MIPSN64], [1], [Define for _MIPS_SIM_ABI64.]);;
+		*) AC_MSG_ERROR([Unsupported _MIPS_SIM]);;
+	esac
+fi
+
+AC_ARG_ENABLE([arm-oabi],
+	      [AS_HELP_STRING([--enable-arm-oabi],
+			      [enable OABI support on ARM EABI])],
+	      [], [enable_arm_oabi=no])
+case "$enable_arm_oabi" in
+	yes) enable_arm_oabi=1 ;;
+	no) enable_arm_oabi=0 ;;
+	*) AC_MSG_ERROR([bad value $enable_arm_oabi for arm-oabi option]) ;;
+esac
+AC_DEFINE_UNQUOTED([ENABLE_ARM_OABI], [$enable_arm_oabi],
+		   [Define to 1 if you want OABI support on ARM EABI.])
+
+gl_WARN_ADD([-Wall])
+gl_WARN_ADD([-Wempty-body])
+gl_WARN_ADD([-Wformat-security])
+gl_WARN_ADD([-Wignored-qualifiers])
+gl_WARN_ADD([-Winit-self])
+gl_WARN_ADD([-Wlogical-op])
+gl_WARN_ADD([-Wmissing-parameter-type])
+gl_WARN_ADD([-Wnested-externs])
+gl_WARN_ADD([-Wold-style-declaration])
+gl_WARN_ADD([-Wold-style-definition])
+gl_WARN_ADD([-Wsign-compare])
+gl_WARN_ADD([-Wtype-limits])
+gl_WARN_ADD([-Wwrite-strings])
+AC_ARG_ENABLE([gcc-Werror],
+  [AS_HELP_STRING([--enable-gcc-Werror], [turn on gcc's -Werror option])],
+  [case $enableval in
+     yes) gl_WARN_ADD([-Werror]) ;;
+     no)  ;;
+     *)   AC_MSG_ERROR([bad value $enableval for gcc-Werror option]) ;;
+   esac]
+)
+AC_SUBST([WARN_CFLAGS])
+
+AC_C_BIGENDIAN
+AC_C_CONST
+AC_C_TYPEOF
+
+AC_TYPE_GETGROUPS
+AC_TYPE_MODE_T
+AC_TYPE_SIGNAL
+AC_TYPE_UID_T
+
+AC_HEADER_DIRENT
+AC_HEADER_MAJOR
+AC_HEADER_STAT
+AC_HEADER_STDBOOL
+AC_HEADER_STDC
+
+AC_CHECK_FUNCS(m4_normalize([
+	accept4
+	fanotify_mark
+	fopen64
+	fork
+	fputs_unlocked
+	fstatat
+	ftruncate
+	futimens
+	if_indextoname
+	open64
+	pipe2
+	prctl
+	preadv
+	process_vm_readv
+	pwritev
+	sigaction
+	signalfd
+	stpcpy
+	strerror
+	strsignal
+	sync_file_range
+	utimensat
+]))
+
+AC_CHECK_TYPES([sig_atomic_t, struct sigcontext],,, [#include <signal.h>])
+
+AC_CHECK_TYPES([struct mmsghdr],,, [#include <sys/socket.h>])
+
+AC_CHECK_TYPES([__kernel_long_t, __kernel_ulong_t],,,
+[#include <asm/posix_types.h>])
+
+AC_CHECK_TYPES([struct stat64, struct __old_kernel_stat],,,
+[#include <sys/types.h>
+#include <asm/stat.h>])
+
+AC_CHECK_TYPES(m4_normalize([
+	struct pt_all_user_regs,
+	struct ia64_fpreg,
+	struct ptrace_peeksiginfo_args
+]),,, [#include <sys/ptrace.h>])
+
+AC_CHECK_TYPES(m4_normalize([
+	struct flock,
+	struct flock64,
+	struct __kernel_flock,
+	struct __kernel_flock64
+]),,,
+[#include <sys/types.h>
+#include <linux/fcntl.h>])
+
+AC_CHECK_MEMBERS(m4_normalize([
+	struct stat.st_atim.tv_nsec,
+	struct stat.st_blksize,
+	struct stat.st_blocks,
+	struct stat.st_ctim.tv_nsec,
+	struct stat.st_flags,
+	struct stat.st_fstype,
+	struct stat.st_gen,
+	struct stat.st_mtim.tv_nsec,
+	struct stat.st_rdev
+]))
+
+AC_CHECK_MEMBERS([struct timex.tai],,, [#include <sys/timex.h>])
+
+AC_CHECK_MEMBERS([struct utsname.domainname],,, [#include <sys/utsname.h>])
+
+AC_CHECK_MEMBERS(m4_normalize([
+	struct stat.st_atime_nsec,
+	struct stat.st_ctime_nsec,
+	struct stat.st_mtime_nsec
+]),,, [#include <sys/types.h>
+#include <asm/stat.h>])
+
+AC_CHECK_MEMBERS(m4_normalize([
+	siginfo_t.si_syscall,
+	siginfo_t.si_timerid,
+	siginfo_t.si_overrun
+]),,, [#include <signal.h>])
+
+AC_CHECK_HEADERS(m4_normalize([
+	asm/cachectl.h
+	asm/sysmips.h
+	bluetooth/bluetooth.h
+	elf.h
+	inttypes.h
+	linux/bsg.h
+	linux/falloc.h
+	linux/fiemap.h
+	linux/filter.h
+	linux/hiddev.h
+	linux/ip_vs.h
+	linux/ipc.h
+	linux/mmtimer.h
+	linux/msg.h
+	linux/perf_event.h
+	linux/seccomp.h
+	linux/securebits.h
+	linux/sem.h
+	linux/shm.h
+	linux/userfaultfd.h
+	linux/utsname.h
+	mqueue.h
+	netinet/sctp.h
+	netipx/ipx.h
+	scsi/sg.h
+	stropts.h
+	sys/conf.h
+	sys/eventfd.h
+	sys/fanotify.h
+	sys/ipc.h
+	sys/msg.h
+	sys/reg.h
+	sys/sem.h
+	sys/shm.h
+	sys/signalfd.h
+	sys/xattr.h
+]))
+
+AC_CHECK_HEADERS([asm/sigcontext.h],,, [#include <signal.h>])
+
+AC_CHECK_HEADERS([netinet/tcp.h netinet/udp.h],,, [#include <netinet/in.h>])
+
+AC_CHECK_HEADERS([linux/mqueue.h],,, [#include <linux/types.h>])
+
+AC_CHECK_HEADERS(m4_normalize([
+	linux/netfilter_arp/arp_tables.h
+	linux/netfilter_bridge/ebtables.h
+	linux/netfilter_ipv4/ip_tables.h
+	linux/netfilter_ipv6/ip6_tables.h
+]),,, [#include <netinet/in.h>
+#include <net/if.h>])
+
+AC_CHECK_HEADERS([linux/input.h], [
+	AC_CHECK_MEMBERS([struct input_absinfo.resolution],,, [#include <linux/input.h>])
+])
+
+AC_CHECK_HEADERS([linux/bpf.h], [
+	AC_CACHE_CHECK([whether union bpf_attr.log_buf initialization works],
+		       [st_cv_have_union_bpf_attr_log_buf],
+		[AC_COMPILE_IFELSE(
+			[AC_LANG_PROGRAM([[#include <linux/bpf.h>]],
+					 [[union bpf_attr a = { .log_buf = 0 };]])],
+			[st_cv_have_union_bpf_attr_log_buf=yes],
+			[st_cv_have_union_bpf_attr_log_buf=no])])
+	if test $st_cv_have_union_bpf_attr_log_buf = yes; then
+		AC_DEFINE(HAVE_UNION_BPF_ATTR_LOG_BUF, [1],
+			  [Define to 1 if union bpf_attr.log_buf initialization works])
+	fi
+])
+
+AC_CHECK_TYPES([struct statfs], [
+	AC_CHECK_MEMBERS([struct statfs.f_frsize],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+	AC_CHECK_MEMBERS([struct statfs.f_flags],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+	AC_CHECK_MEMBERS([struct statfs.f_fsid.val],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+	AC_CHECK_MEMBERS([struct statfs.f_fsid.__val],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+],, [#include <linux/types.h>
+#include <asm/statfs.h>])
+
+AC_CHECK_TYPES([struct statfs64], [
+	AC_CHECK_MEMBERS([struct statfs64.f_frsize],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+	AC_CHECK_MEMBERS([struct statfs64.f_flags],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+	AC_CHECK_MEMBERS([struct statfs64.f_fsid.val],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+	AC_CHECK_MEMBERS([struct statfs64.f_fsid.__val],,, [#include <linux/types.h>
+#include <asm/statfs.h>])
+],, [#include <linux/types.h>
+#include <asm/statfs.h>])
+
+AC_CHECK_TYPES([struct blk_user_trace_setup],,, [#include <linux/blktrace_api.h>])
+
+AC_CHECK_HEADERS([linux/btrfs.h], [
+	AC_CHECK_MEMBERS(m4_normalize([
+		struct btrfs_ioctl_feature_flags.compat_flags,
+		struct btrfs_ioctl_fs_info_args.nodesize,
+		struct btrfs_ioctl_defrag_range_args.start,
+		struct btrfs_ioctl_search_args_v2.buf_size
+		]),,, [ #include <stdio.h>
+#include <linux/btrfs.h>])
+        AC_CHECK_DECLS(m4_normalize([BTRFS_COMPRESS_NONE, BTRFS_COMPRESS_ZLIB,
+	                        BTRFS_COMPRESS_LZO]),,,[ #include <stdio.h>
+#include <linux/btrfs.h>])])
+
+AC_CHECK_DECLS([sys_errlist])
+AC_CHECK_DECLS(m4_normalize([
+	PTRACE_PEEKUSER,
+	PTRACE_POKEUSER
+]),,, [#include <sys/ptrace.h>])
+
+AC_CHECK_DECLS(m4_normalize([
+	P_PID,
+	P_PPID,
+	P_PGID,
+	P_SID,
+	P_CID,
+	P_UID,
+	P_GID,
+	P_ALL,
+	P_LWPID
+]),,, [#include <sys/wait.h>])
+
+AC_CHECK_DECLS(m4_normalize([
+	LO_FLAGS_READ_ONLY,
+	LO_FLAGS_AUTOCLEAR,
+	LO_FLAGS_PARTSCAN
+]),,, [#include <linux/loop.h>])
+
+AC_CHECK_DECLS(m4_normalize([
+	CTL_PROC,
+	CTL_ARLAN,
+	CTL_S390DBF,
+	CTL_SUNRPC,
+	CTL_PM,
+	CTL_FRV,
+	KERN_PRINTK_RATELIMIT,
+	KERN_PRINTK_RATELIMIT_BURST,
+	KERN_PTY,
+	KERN_NGROUPS_MAX,
+	KERN_SPARC_SCONS_PWROFF,
+	KERN_HZ_TIMER,
+	KERN_UNKNOWN_NMI_PANIC,
+	KERN_BOOTLOADER_TYPE,
+	KERN_RANDOMIZE,
+	KERN_SETUID_DUMPABLE,
+	KERN_SPIN_RETRY,
+	KERN_ACPI_VIDEO_FLAGS,
+	KERN_IA64_UNALIGNED,
+	KERN_COMPAT_LOG,
+	KERN_MAX_LOCK_DEPTH,
+	KERN_NMI_WATCHDOG,
+	KERN_PANIC_ON_NMI,
+	NET_LLC,
+	NET_NETFILTER,
+	NET_DCCP,
+	NET_IRDA,
+	NET_CORE_DESTROY_DELAY,
+	NET_CORE_BUDGET,
+	NET_CORE_AEVENT_ETIME,
+	NET_CORE_AEVENT_RSEQTH,
+	NET_CORE_WARNINGS,
+	NET_IPV4_IGMP_MAX_MSF,
+	NET_TCP_NO_METRICS_SAVE,
+	NET_TCP_DEFAULT_WIN_SCALE,
+	NET_TCP_MODERATE_RCVBUF,
+	NET_TCP_TSO_WIN_DIVISOR,
+	NET_TCP_BIC_BETA,
+	NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR,
+	NET_TCP_CONG_CONTROL,
+	NET_TCP_ABC,
+	NET_IPV4_IPFRAG_MAX_DIST,
+	NET_TCP_MTU_PROBING,
+	NET_TCP_BASE_MSS,
+	NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS,
+	NET_TCP_DMA_COPYBREAK,
+	NET_TCP_SLOW_START_AFTER_IDLE,
+	NET_CIPSOV4_CACHE_ENABLE,
+	NET_CIPSOV4_CACHE_BUCKET_SIZE,
+	NET_CIPSOV4_RBM_OPTFMT,
+	NET_CIPSOV4_RBM_STRICTVALID,
+	NET_TCP_AVAIL_CONG_CONTROL,
+	NET_TCP_ALLOWED_CONG_CONTROL,
+	NET_TCP_MAX_SSTHRESH,
+	NET_TCP_FRTO_RESPONSE,
+	NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS,
+	NET_IPV4_CONF_FORCE_IGMP_VERSION,
+	NET_IPV4_CONF_ARP_ANNOUNCE,
+	NET_IPV4_CONF_ARP_IGNORE,
+	NET_IPV4_CONF_PROMOTE_SECONDARIES,
+	NET_IPV4_CONF_ARP_ACCEPT,
+	NET_IPV4_CONF_ARP_NOTIFY,
+	NET_IPV6_MLD_MAX_MSF,
+	NET_IPV6_ROUTE_GC_MIN_INTERVAL_MS,
+	VM_MAX_MAP_COUNT,
+	VM_LAPTOP_MODE,
+	VM_BLOCK_DUMP,
+	VM_HUGETLB_GROUP,
+	VM_VFS_CACHE_PRESSURE,
+	VM_LEGACY_VA_LAYOUT,
+	VM_SWAP_TOKEN_TIMEOUT
+]),,,
+[#include <sys/types.h>
+#include <linux/sysctl.h>])
+
+AC_CHECK_DECLS(m4_normalize([
+	V4L2_FIELD_ANY,
+	V4L2_FIELD_NONE,
+	V4L2_FIELD_TOP,
+	V4L2_FIELD_BOTTOM,
+	V4L2_FIELD_INTERLACED,
+	V4L2_FIELD_SEQ_TB,
+	V4L2_FIELD_SEQ_BT,
+	V4L2_FIELD_ALTERNATE,
+	V4L2_FIELD_INTERLACED_TB,
+	V4L2_FIELD_INTERLACED_BT,
+	V4L2_BUF_TYPE_VIDEO_CAPTURE,
+	V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE,
+	V4L2_BUF_TYPE_VIDEO_OUTPUT,
+	V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE,
+	V4L2_BUF_TYPE_VIDEO_OVERLAY,
+	V4L2_BUF_TYPE_VBI_CAPTURE,
+	V4L2_BUF_TYPE_VBI_OUTPUT,
+	V4L2_BUF_TYPE_SLICED_VBI_CAPTURE,
+	V4L2_BUF_TYPE_SLICED_VBI_OUTPUT,
+	V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY,
+	V4L2_TUNER_RADIO,
+	V4L2_TUNER_ANALOG_TV,
+	V4L2_TUNER_DIGITAL_TV,
+	V4L2_MEMORY_MMAP,
+	V4L2_MEMORY_USERPTR,
+	V4L2_MEMORY_OVERLAY,
+	V4L2_MEMORY_DMABUF,
+	V4L2_COLORSPACE_SMPTE170M,
+	V4L2_COLORSPACE_SMPTE240M,
+	V4L2_COLORSPACE_REC709,
+	V4L2_COLORSPACE_BT878,
+	V4L2_COLORSPACE_470_SYSTEM_M,
+	V4L2_COLORSPACE_470_SYSTEM_BG,
+	V4L2_COLORSPACE_JPEG,
+	V4L2_COLORSPACE_SRGB,
+	V4L2_PRIORITY_UNSET,
+	V4L2_PRIORITY_BACKGROUND,
+	V4L2_PRIORITY_INTERACTIVE,
+	V4L2_PRIORITY_RECORD,
+	V4L2_FRMSIZE_TYPE_DISCRETE,
+	V4L2_FRMSIZE_TYPE_CONTINUOUS,
+	V4L2_FRMSIZE_TYPE_STEPWISE,
+	V4L2_FRMIVAL_TYPE_DISCRETE,
+	V4L2_FRMIVAL_TYPE_CONTINUOUS,
+	V4L2_FRMIVAL_TYPE_STEPWISE,
+	V4L2_CTRL_TYPE_INTEGER,
+	V4L2_CTRL_TYPE_BOOLEAN,
+	V4L2_CTRL_TYPE_MENU,
+	V4L2_CTRL_TYPE_BUTTON,
+	V4L2_CTRL_TYPE_INTEGER64,
+	V4L2_CTRL_TYPE_CTRL_CLASS,
+	V4L2_CTRL_TYPE_STRING,
+	V4L2_CTRL_TYPE_BITMASK,
+	V4L2_CTRL_TYPE_INTEGER_MENU
+]),,, [#include <sys/time.h>
+#include <linux/ioctl.h>
+#include <linux/types.h>
+#include <linux/videodev2.h>])
+
+AC_CACHE_CHECK([for BLKGETSIZE64], [ac_cv_have_blkgetsize64],
+	[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([
+#include <stdlib.h>
+#include <linux/fs.h>], [return !BLKGETSIZE64;])],
+			   [ac_cv_have_blkgetsize64=yes], [ac_cv_have_blkgetsize64=no])]
+	if test $ac_cv_have_blkgetsize64 = yes; then
+		AC_DEFINE([HAVE_BLKGETSIZE64], [1], [Define to 1 if you have BLKGETSIZE64.])
+	fi)
+
+AC_CHECK_SIZEOF([long])
+AC_CHECK_SIZEOF([long long])
+AC_CHECK_SIZEOF([off_t],,[#include <sys/types.h>])
+AC_CHECK_SIZEOF([struct i64_i32],,[struct i64_i32 {long long i64; int i32;};])
+
+AC_CACHE_CHECK([for SIGRTMIN], [st_cv_SIGRTMIN],
+	       [[st_cv_SIGRTMIN="$(echo SIGRTMIN |
+			$CPP $CPPFLAGS -P -imacros asm/signal.h - |
+			grep '^[0-9]')"
+	         test -n "$st_cv_SIGRTMIN" || st_cv_SIGRTMIN=no]])
+if test "x$st_cv_SIGRTMIN" != xno; then
+	AC_DEFINE_UNQUOTED([ASM_SIGRTMIN], [$st_cv_SIGRTMIN],
+			   [SIGRTMIN defined in <asm/signal.h>])
+fi
+AC_CACHE_CHECK([for SA_RESTORER], [st_cv_SA_RESTORER],
+	       [st_cv_SA_RESTORER="$(echo SA_RESTORER |
+			$CPP $CPPFLAGS -P -imacros asm/signal.h - |
+			grep ^0x)"
+	        test -n "$st_cv_SA_RESTORER" || st_cv_SA_RESTORER=no])
+if test "x$st_cv_SA_RESTORER" != xno; then
+	AC_DEFINE_UNQUOTED([ASM_SA_RESTORER], [$st_cv_SA_RESTORER],
+			   [SA_RESTORER defined in <asm/signal.h>])
+fi
+
+AC_CACHE_CHECK([for __builtin_popcount], [st_cv_have___builtin_popcount],
+	       [AC_LINK_IFELSE([AC_LANG_PROGRAM([], [__builtin_popcount(0)])],
+			       [st_cv_have___builtin_popcount=yes],
+			       [st_cv_have___builtin_popcount=no])])
+if test "x$st_cv_have___builtin_popcount" = xyes; then
+	AC_DEFINE([HAVE___BUILTIN_POPCOUNT], [1],
+		  [Define to 1 if the system provides __builtin_popcount function])
+fi
+
+AC_CHECK_LIB([dl], [dladdr], [dl_LIBS='-ldl'], [dl_LIBS=])
+if test "x$ac_cv_lib_dl_dladdr" = xyes; then
+	AC_DEFINE([HAVE_DLADDR], [1], [Define to 1 if the system provides dladdr])
+fi
+AC_SUBST(dl_LIBS)
+
+AC_PATH_PROG([PERL], [perl])
+
+dnl stack trace with libunwind
+libunwind_CPPFLAGS=
+libunwind_LDFLAGS=
+libunwind_LIBS=
+AC_ARG_WITH([libunwind],
+            [AS_HELP_STRING([--with-libunwind],
+                            [use libunwind to implement stack tracing support])],
+            [case "${withval}" in
+             yes|no|check) ;;
+             *) with_libunwind=yes
+                libunwind_CPPFLAGS="-I${withval}/include"
+                libunwind_LDFLAGS="-L${withval}/lib" ;;
+             esac],
+            [with_libunwind=check]
+)
+
+use_libunwind=no
+AS_IF([test "x$with_libunwind" != xno],
+      [saved_CPPFLAGS="$CPPFLAGS"
+       CPPFLAGS="$CPPFLAGS $libunwind_CPPFLAGS"
+
+       AC_CHECK_HEADERS([libunwind-ptrace.h],
+         [saved_LDFLAGS="$LDFLAGS"
+          LDFLAGS="$LDFLAGS $libunwind_LDFLAGS"
+
+          AC_CHECK_LIB([unwind], [backtrace],
+            [libunwind_LIBS="-lunwind $libunwind_LIBS"
+
+             AC_MSG_CHECKING([for unw_create_addr_space in libunwind-generic])
+             saved_LIBS="$LIBS"
+             LIBS="-lunwind-generic $libunwind_LIBS $LIBS"
+
+             AC_LINK_IFELSE(
+               [AC_LANG_PROGRAM([[#include <libunwind-ptrace.h>]],
+                                [[return !unw_create_addr_space(0, 0)]])
+               ],
+               [AC_MSG_RESULT([yes])
+                libunwind_LIBS="-lunwind-generic $libunwind_LIBS"
+
+                AC_CHECK_LIB([unwind-ptrace], [_UPT_create],
+                  [libunwind_LIBS="-lunwind-ptrace $libunwind_LIBS"
+                   use_libunwind=yes
+                  ],
+                  [if test "x$with_libunwind" != xcheck; then
+                     AC_MSG_FAILURE([failed to find _UPT_create in libunwind-ptrace])
+                   fi
+                  ],
+                  [$libunwind_LIBS]
+                )
+               ],
+               [AC_MSG_RESULT([no])
+                if test "x$with_libunwind" != xcheck; then
+                  AC_MSG_FAILURE([failed to find unw_create_addr_space in libunwind-generic])
+                fi
+               ]
+             )
+
+             LIBS="$saved_LIBS"
+            ],
+            [if test "x$with_libunwind" != xcheck; then
+               AC_MSG_FAILURE([failed to find libunwind])
+             fi
+            ],
+            [$libunwind_LIBS]
+          )
+
+          LDFLAGS="$saved_LDFLAGS"
+         ],
+         [if test "x$with_libunwind" != xcheck; then
+            AC_MSG_FAILURE([failed to find libunwind-ptrace.h])
+          fi
+         ]
+       )
+
+       CPPFLAGS="$saved_CPPFLAGS"
+      ]
+)
+
+dnl enable libunwind
+AC_MSG_CHECKING([whether to enable stack tracing support using libunwind])
+if test "x$use_libunwind" = xyes; then
+	AC_DEFINE([USE_LIBUNWIND], 1, [Compile stack tracing functionality])
+	AC_SUBST(libunwind_LIBS)
+	AC_SUBST(libunwind_LDFLAGS)
+	AC_SUBST(libunwind_CPPFLAGS)
+fi
+AM_CONDITIONAL([USE_LIBUNWIND], [test "x$use_libunwind" = xyes])
+AC_MSG_RESULT([$use_libunwind])
+
+if test "$arch" = mips && test "$no_create" != yes; then
+	mkdir -p linux/mips
+	if $srcdir/linux/mips/genstub.sh linux/mips; then
+		AC_MSG_RESULT([Generated MIPS syscallent stubs])
+	else
+		AC_MSG_FAILURE([Failed to generate syscallent stubs])
+	fi
+fi
+
+st_MPERS([m32], [aarch64|powerpc64|sparc64|tile|x32|x86_64])
+st_MPERS([mx32], [x86_64])
+
+AC_CONFIG_FILES([Makefile
+		 tests/Makefile
+		 tests-m32/Makefile
+		 tests-mx32/Makefile
+		 strace.spec
+		 debian/changelog])
+AC_OUTPUT
diff --git a/strace/copy_file_range.c b/strace/copy_file_range.c
new file mode 100644
index 0000000..8e711d1
--- /dev/null
+++ b/strace/copy_file_range.c
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+SYS_FUNC(copy_file_range)
+{
+	/* int fd_in */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* loff_t *off_in */
+	printnum_int64(tcp, tcp->u_arg[1], "%" PRId64);
+	tprints(", ");
+	/* int fd_out */
+	printfd(tcp, tcp->u_arg[2]);
+	tprints(", ");
+	/* loff_t *off_out */
+	printnum_int64(tcp, tcp->u_arg[3], "%" PRId64);
+	tprints(", ");
+	/* size_t len */
+	tprintf("%lu, ", tcp->u_arg[4]);
+	/* unsigned int flags */
+	tprintf("%u", (unsigned int) tcp->u_arg[5]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/count.c b/strace/count.c
new file mode 100644
index 0000000..1393b6e
--- /dev/null
+++ b/strace/count.c
@@ -0,0 +1,246 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 1999 IBM Deutschland Entwicklung GmbH, IBM Corporation
+ *                     Linux for s390 port by D.J. Barrow
+ *                    <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * Copyright (c) 2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+/* Per-syscall stats structure */
+struct call_counts {
+	/* time may be total latency or system time */
+	struct timeval time;
+	int calls, errors;
+};
+
+static struct call_counts *countv[SUPPORTED_PERSONALITIES];
+#define counts (countv[current_personality])
+
+static struct timeval shortest = { 1000000, 0 };
+
+void
+count_syscall(struct tcb *tcp, const struct timeval *syscall_exiting_tv)
+{
+	struct timeval wtv;
+	struct timeval *tv = &wtv;
+	struct call_counts *cc;
+	unsigned long scno = tcp->scno;
+
+	if (!SCNO_IN_RANGE(scno))
+		return;
+
+	if (!counts)
+		counts = xcalloc(nsyscalls, sizeof(*counts));
+	cc = &counts[scno];
+
+	cc->calls++;
+	if (tcp->u_error)
+		cc->errors++;
+
+	/* tv = wall clock time spent while in syscall */
+	tv_sub(tv, syscall_exiting_tv, &tcp->etime);
+
+	/* Spent more wall clock time than spent system time? (usually yes) */
+	if (tv_cmp(tv, &tcp->dtime) > 0) {
+		static struct timeval one_tick = { -1, 0 };
+
+		if (one_tick.tv_sec == -1) {
+			/* Initialize it.  */
+			struct itimerval it;
+
+			memset(&it, 0, sizeof it);
+			it.it_interval.tv_usec = 1;
+			setitimer(ITIMER_REAL, &it, NULL);
+			getitimer(ITIMER_REAL, &it);
+			one_tick = it.it_interval;
+//FIXME: this hack doesn't work (tested on linux-3.6.11): one_tick = 0.000000
+//tprintf(" one_tick.tv_usec:%u\n", (unsigned)one_tick.tv_usec);
+		}
+
+		if (tv_nz(&tcp->dtime))
+			/* tv = system time spent, if it isn't 0 */
+			tv = &tcp->dtime;
+		else if (tv_cmp(tv, &one_tick) > 0) {
+			/* tv = smallest "sane" time interval */
+			if (tv_cmp(&shortest, &one_tick) < 0)
+				tv = &shortest;
+			else
+				tv = &one_tick;
+		}
+	}
+	if (tv_cmp(tv, &shortest) < 0)
+		shortest = *tv;
+	tv_add(&cc->time, &cc->time, count_wallclock ? &wtv : tv);
+}
+
+static int
+time_cmp(void *a, void *b)
+{
+	return -tv_cmp(&counts[*((int *) a)].time,
+		       &counts[*((int *) b)].time);
+}
+
+static int
+syscall_cmp(void *a, void *b)
+{
+	const char *a_name = sysent[*((int *) a)].sys_name;
+	const char *b_name = sysent[*((int *) b)].sys_name;
+	return strcmp(a_name ? a_name : "", b_name ? b_name : "");
+}
+
+static int
+count_cmp(void *a, void *b)
+{
+	int     m = counts[*((int *) a)].calls;
+	int     n = counts[*((int *) b)].calls;
+
+	return (m < n) ? 1 : (m > n) ? -1 : 0;
+}
+
+static int (*sortfun)();
+static struct timeval overhead = { -1, -1 };
+
+void
+set_sortby(const char *sortby)
+{
+	if (strcmp(sortby, "time") == 0)
+		sortfun = time_cmp;
+	else if (strcmp(sortby, "calls") == 0)
+		sortfun = count_cmp;
+	else if (strcmp(sortby, "name") == 0)
+		sortfun = syscall_cmp;
+	else if (strcmp(sortby, "nothing") == 0)
+		sortfun = NULL;
+	else {
+		error_msg_and_help("invalid sortby: '%s'", sortby);
+	}
+}
+
+void set_overhead(int n)
+{
+	overhead.tv_sec = n / 1000000;
+	overhead.tv_usec = n % 1000000;
+}
+
+static void
+call_summary_pers(FILE *outf)
+{
+	unsigned int i;
+	int     call_cum, error_cum;
+	struct timeval tv_cum, dtv;
+	double  float_tv_cum;
+	double  percent;
+	const char *dashes = "----------------";
+	char    error_str[sizeof(int)*3];
+	int    *sorted_count;
+
+	fprintf(outf, "%6.6s %11.11s %11.11s %9.9s %9.9s %s\n",
+		"% time", "seconds", "usecs/call",
+		"calls", "errors", "syscall");
+	fprintf(outf, "%6.6s %11.11s %11.11s %9.9s %9.9s %s\n",
+		dashes, dashes, dashes, dashes, dashes, dashes);
+
+	sorted_count = xcalloc(sizeof(int), nsyscalls);
+	call_cum = error_cum = tv_cum.tv_sec = tv_cum.tv_usec = 0;
+	if (overhead.tv_sec == -1) {
+		tv_mul(&overhead, &shortest, 8);
+		tv_div(&overhead, &overhead, 10);
+	}
+	for (i = 0; i < nsyscalls; i++) {
+		sorted_count[i] = i;
+		if (counts == NULL || counts[i].calls == 0)
+			continue;
+		tv_mul(&dtv, &overhead, counts[i].calls);
+		tv_sub(&counts[i].time, &counts[i].time, &dtv);
+		call_cum += counts[i].calls;
+		error_cum += counts[i].errors;
+		tv_add(&tv_cum, &tv_cum, &counts[i].time);
+	}
+	float_tv_cum = tv_float(&tv_cum);
+	if (counts) {
+		if (sortfun)
+			qsort((void *) sorted_count, nsyscalls, sizeof(int), sortfun);
+		for (i = 0; i < nsyscalls; i++) {
+			double float_syscall_time;
+			int idx = sorted_count[i];
+			struct call_counts *cc = &counts[idx];
+			if (cc->calls == 0)
+				continue;
+			tv_div(&dtv, &cc->time, cc->calls);
+			error_str[0] = '\0';
+			if (cc->errors)
+				sprintf(error_str, "%u", cc->errors);
+			float_syscall_time = tv_float(&cc->time);
+			percent = (100.0 * float_syscall_time);
+			if (percent != 0.0)
+				   percent /= float_tv_cum;
+			/* else: float_tv_cum can be 0.0 too and we get 0/0 = NAN */
+			fprintf(outf, "%6.2f %11.6f %11lu %9u %9.9s %s\n",
+				percent, float_syscall_time,
+				(long) (1000000 * dtv.tv_sec + dtv.tv_usec),
+				cc->calls,
+				error_str, sysent[idx].sys_name);
+		}
+	}
+	free(sorted_count);
+
+	fprintf(outf, "%6.6s %11.11s %11.11s %9.9s %9.9s %s\n",
+		dashes, dashes, dashes, dashes, dashes, dashes);
+	error_str[0] = '\0';
+	if (error_cum)
+		sprintf(error_str, "%u", error_cum);
+	fprintf(outf, "%6.6s %11.6f %11.11s %9u %9.9s %s\n",
+		"100.00", float_tv_cum, "",
+		call_cum, error_str, "total");
+}
+
+void
+call_summary(FILE *outf)
+{
+	unsigned int i, old_pers = current_personality;
+
+	for (i = 0; i < SUPPORTED_PERSONALITIES; ++i) {
+		if (!countv[i])
+			continue;
+
+		if (current_personality != i)
+			set_personality(i);
+		if (i)
+			fprintf(outf,
+				"System call usage summary for %d bit mode:\n",
+				current_wordsize * 8);
+		call_summary_pers(outf);
+	}
+
+	if (old_pers != current_personality)
+		set_personality(old_pers);
+}
diff --git a/strace/debian/changelog.in b/strace/debian/changelog.in
new file mode 100644
index 0000000..3f4bd04
--- /dev/null
+++ b/strace/debian/changelog.in
@@ -0,0 +1,919 @@
+strace (@PACKAGE_VERSION@-1) experimental; urgency=low
+
+  * @PACKAGE_STRING@ snapshot.
+
+ -- Strace <@PACKAGE_BUGREPORT@>  @DEB_CHANGELOGTIME@
+
+strace (4.13-1) unstable; urgency=medium
+
+  * New upstream version.
+
+ -- Dmitry V. Levin <ldv@altlinux.org>  Tue, 26 Jul 2016 16:17:18 +0000
+
+strace (4.12-3) unstable; urgency=medium
+
+  * Fix up 32/64-bit test output in strace -S test to fix i386 build
+  * Run make check with VERBOSE=1 so we get useful information in build logs
+
+ -- Steve McIntyre <93sam@debian.org>  Sat, 04 Jun 2016 02:37:44 +0100
+
+strace (4.12-2) unstable; urgency=medium
+
+  * Remove libunwind dependency. Closes: #826223
+
+ -- Steve McIntyre <93sam@debian.org>  Fri, 03 Jun 2016 13:43:44 +0100
+
+strace (4.12-1) unstable; urgency=low
+
+  [ Dmitry V. Levin ]
+  * New upstream version.
+    + implemented simultaneous use of -p option and tracing of a command,
+      closes: #549942
+    + fixed decoding of syscalls unknown to the kernel on s390/s390x,
+      closes: #485979
+
+ -- Dmitry V. Levin <ldv@altlinux.org>  Tue, 31 May 2016 11:12:13 +0000
+
+strace (4.11-1) unstable; urgency=low
+
+  [ Dmitry V. Levin ]
+  * New upstream version.
+    + fixed decoding of path argument of umount2 syscall, closes: #785050
+
+  [ Steve McIntyre ]
+  * Drop patches against old upstream - all upstream now.
+  * Add simple upstream patch to fix printing of 32-bit times syscall
+    return value on 64-bit architectures.
+
+ -- Steve McIntyre <93sam@debian.org>  Fri, 08 Jan 2015 00:52:05 +0000
+
+strace (4.10-3) unstable; urgency=medium
+
+  * Really fix mips* builds - fix sys_syscall() handling.
+    Closes: #781753
+  * Clean up strace64.substvars at clean time
+  * Remove ancient changelog entries that annoy lintian
+  * Update Standards-Version to 3.9.6 (no changes needed)
+
+ -- Steve McIntyre <93sam@debian.org>  Wed, 08 Jul 2015 23:44:03 +0100
+
+strace (4.10-2) unstable; urgency=medium
+
+  * Fix building on arm64 using patches from upstream. Closes: #790770
+  * Fix various test suite failures using patches from upstream.
+    Closes: #781040
+  * Fix mips o32 build. Thanks to Arturo Borrero Gonzalez
+    <arturo.borrero.glez@gmail.com> for tracking this.
+  * Add build-dependency on gawk for the test suite. Closes: #780992
+
+ -- Steve McIntyre <93sam@debian.org>  Thu, 02 Jul 2015 02:03:25 +0100
+
+strace (4.10-1) unstable; urgency=low
+
+  [ Dmitry V. Levin ]
+  * New upstream version.
+    + enhanced ioctl decoding,  closes: #692913
+    + enabled mips64el build, closes: #773375
+    + updated signal and errno numbers, closes: #768642
+    + updated generic and added arch-specific PTRACE_* constants,
+      closes: #734554
+
+ -- Steve McIntyre <93sam@debian.org>  Sat, 21 Mar 2015 22:18:25 +0000
+
+strace (4.9-2) unstable; urgency=medium
+
+  * Turn on support for ppc64el, code is already in upstream.
+    Closes: #744121.
+
+ -- Steve McIntyre <93sam@debian.org>  Wed, 20 Aug 2014 18:00:20 +0100
+
+strace (4.9-1) unstable; urgency=medium
+
+  [ Dmitry V. Levin ]
+  * New upstream version.
+    + added -w option to produce stats on syscall latency, closes: #457497
+    + applied miscellaneous corrections to the manpage, closes: #725987
+    + fixed a typo in package description, closes: #697625
+    + enabled or1k build, closes: #742235
+    + enabled maximum security hardening, thanks to Markus <waldeck@gmx.de>
+
+  [ Steve McIntyre ]
+  * New maintainer. Thanks to Frederik for all his prior work!
+
+ -- Steve McIntyre <93sam@debian.org>  Wed, 20 Aug 2014 15:11:36 +0100
+
+strace (4.8-1.1) unstable; urgency=low
+
+  * NMU
+  * Uploading 4.8 to unstable to fix long-standing bugs that have been
+    fixed for ages in experimental only.
+  * enable arm64 build, Closes: #749956
+  * enable x32 build, Closes: #727018
+  * lintian-inspired fixes:
+    + add build-arch and build-indep targets in debian/rules
+    + update standards-version to 3.9.5
+    + remove ancient changelog entries causing syntax checker errors
+    + add hardening using buildflags.mk
+    + trivial changes to Description: fields
+
+ -- Steve McIntyre <93sam@debian.org>  Thu, 10 Jul 2014 14:22:18 +0000
+
+strace (4.8-1) experimental; urgency=low
+
+  * New upstream version.
+    + Added aarch64 support, closes: #693074
+    + Fixed kernel release string parsing, closes: #702309
+
+ -- Dmitry V. Levin <ldv@altlinux.org>  Mon, 03 Jun 2013 15:16:17 +0000
+
+strace (4.7-1) experimental; urgency=low
+
+  [ Dmitry V. Levin ]
+  * New upstream version.
+    + Fixed sockaddr_un.sun_path name in decoded output, closes: #554946
+    + Avoid potential core file clobbering on exit, closes: #656398
+    + Fixed a typo in documentation, closes: #653309
+
+ -- Frederik Schüler <fs@debian.org>  Tue, 12 Feb 2013 10:35:22 +0100
+
+strace (4.6-1) unstable; urgency=low
+
+  * New upstream version.
+    + Added HDIO_* ioctl names, closes: #450953
+    + Fixed stat64 decoding on mips, closes: #599028
+    + Fixed misleading italics in the manual page, closes: #589323
+
+ -- Dmitry V. Levin <ldv@altlinux.org>  Mon, 14 Mar 2011 15:16:17 +0000
+
+strace (4.5.20-2.3) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Add sh4 to arch list.
+  * Add powerpcspe to arch list (Closes: #579842).
+
+ -- Nobuhiro Iwamatsu <iwamatsu@debian.org>  Tue, 22 Mar 2011 09:03:49 +0900
+
+strace (4.5.20-2.2) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Add sh4 to arch list (Closes: #537105).
+
+ -- Nobuhiro Iwamatsu <iwamatsu@debian.org>  Wed, 09 Mar 2011 09:22:01 +0900
+
+strace (4.5.20-2.1) unstable; urgency=low
+
+  * NMU, added armhf support. (Closes: #596960)
+
+ -- Konstantinos Margaritis <markos@debian.org>  Thu, 24 Feb 2011 14:47:54 +0000
+
+strace (4.5.20-2) unstable; urgency=low
+
+  * Add missing sparc syscall defines to fix FTBFS on sparc.
+
+ -- Frederik Schüler <fs@debian.org>  Tue, 04 May 2010 14:31:46 +0200
+
+strace (4.5.20-1) unstable; urgency=low
+
+  [ Dmitry V. Levin ]
+  * New upstream version.
+    + Corrected decoding of 64bit syscalls, closes: #570603
+    + Corrected getsockopt decoding on architectures where
+      sizeof(long) > sizeof(int), closes: #494844
+    + Corrected decoding of epoll_pwait, closes: #513014
+    + Implemented -C option to combine regular and -c output, closes: #466196
+
+  [ Frederik Schüler ]
+  * Update standards-version to 3.8.4.
+  * debian/rules: allow parallel building.
+  * debian/rules: comment out verbose build, only needed for debugging.
+  * debian/rules: clean up clean: target, dh_clean does most of the work
+    already.
+  * debian/rules: use *-stamp instead of stamp-*, so dh_clean can tidy
+    up for us.
+
+ -- Frederik Schüler <fs@debian.org>  Tue, 13 Apr 2010 13:02:57 +0200
+
+strace (4.5.19-2) unstable; urgency=low
+
+  * Add sparc64 to the architectures list, closes: #560062
+  * Fix FTBFS, thanks to Aurelien Jarno <aurelien@aurel32.net> for pointing
+    out the solution. Closes: #560516
+  * Rebuild as normal package, closes: #566968
+  * Update standards-version to 3.8.3.
+  * Lower package priority to optional, matching the archive override.
+  * Add watch file.
+
+ -- Frederik Schüler <fs@debian.org>  Tue, 26 Jan 2010 12:20:51 +0100
+
+strace (4.5.19-1) unstable; urgency=low
+
+  [ Dmitry V. Levin ]
+  * New upstream release.
+    + Fixed FTBFS on armel, closes: #520084, #535564
+    + Marked sendfile(2) as a network syscall, closes: #509499
+    + Fixed syscall numbers for tee and sync_file_range, closes: #503124
+    + Corrected accept(2) decoding, closes: #507573
+    + Changed strace to exit/kill with traced process
+      exitcode/signal, closes: #37665
+
+  [ Frederik Schüler ]
+  * Move myself from uploaders to maintainers, and drop Roland from the list,
+    closes: #521458
+  * Apply hppa fixes, thanks to Carlos O'Donell <carlos@systemhalted.org>
+    and Helge Deller <deller@gmx.de> for the fixes, closes: #546619, #437928
+  * Update standards-version to 3.8.1.
+
+ -- Frederik Schüler <fs@debian.org>  Mon, 05 Oct 2009 22:39:54 +0200
+
+strace (4.5.18-1) unstable; urgency=low
+
+  * New upstream release, closes: #515655
+    + Fix FTBFS, closes: #518852
+  * Backported patch from CVS: Fix support for NUL-terminated
+    string, closes: #508484
+  * Build-depend on debhelper (>= 7.0.0).
+
+ -- Frederik Schüler <fs@debian.org>  Mon, 09 Mar 2009 14:39:42 +0100
+
+strace (4.5.17+cvs080723-2) unstable; urgency=low
+
+  * Pull Fix for sparc FTBFS from CVS, closes: #492774
+  * Make strace64 priority extra.
+
+ -- Frederik Schüler <fs@debian.org>  Sat, 02 Aug 2008 10:36:59 +0200
+
+strace (4.5.17+cvs080723-1) unstable; urgency=low
+
+  * New upstream cvs snapshot.
+    - fixes arm and armel FTBFS.
+
+ -- Frederik Schüler <fs@debian.org>  Wed, 23 Jul 2008 15:23:22 +0200
+
+strace (4.5.17-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Frederik Schüler <fs@debian.org>  Sat, 19 Jul 2008 21:38:30 +0200
+
+strace (4.5.16+cvs20080708-2) unstable; urgency=low
+
+  * Rerun autotools in correct order.
+  * Add strace64 package on i386, powerpc, s390 and sparc,
+    closes: #491167, #491188
+
+ -- Frederik Schüler <fs@debian.org>  Thu, 17 Jul 2008 17:21:27 +0200
+
+strace (4.5.16+cvs20080708-1) unstable; urgency=low
+
+  * New upstream snapshot.
+    + Fix chmod/chown typo in debian/rules, closes: #459255.
+    + Install strace-graph too, closes: 469068.
+    + Fix m68k build, closes: 456879.
+    + Arm updates, closes: #441000.
+    + fix build on mips/mipsel, closes: #448802.
+    + show poll() parameters before blocking, closes: #369651.
+    + use dh_strip instead of install -s, closes: #438055, #396682.
+    + fix sparc build, closes: #469379.
+  * Acknowledge NMU, closes: #469380.
+  * Remove Wichert Akkerman from uploaders list.
+  * Bump standards version to 3.8.0.
+    - Add Homepage field.
+  * Add dh_md5sums call, closes: #439428.
+  * Fix dpkg-gencontrol call.
+  * Update debian/copyright.
+
+ -- Frederik Schüler <fs@debian.org>  Tue, 01 Jul 2008 23:05:51 +0200
+
+strace (4.5.16-1) unstable; urgency=low
+
+  * New upstream version.
+    + 64-bit builds, closes: #435303.
+    + LFS build fix, closes: #385310.
+    + Fix multithread issues
+    + Fix spurious SIGSTOP on early interrupt.
+    + Fix utime for biarch.
+    + Fix -u error message.
+    + Better futex syscall printing.
+    + Fix argv/envp printing with small -s settings, and for biarch.
+    + New syscalls: getcpu, eventfd, timerfd, signalfd, epoll_pwait,
+      move_pages, utimensat.
+
+ -- Roland McGrath <frob@debian.org>  Fri, 03 Aug 2007 03:24:21 -0700
+
+strace (4.5.15-1) unstable; urgency=high
+
+  [ Roland McGrath ]
+  * New upstream version.
+    + Fix -ff -o behavior, closes: #353935.
+    + Fail when nonoption args follow -p switches, closes: #361302.
+    + Fix semtimedop, closes: #340239.
+    + ARM support fixes, closes: #360152, #360154.
+
+  [ Frederik Schüler ]
+  * Fix configure script, closes: #428997
+
+ -- Frederik Schüler <fs@debian.org>  Fri, 22 Jun 2007 16:28:08 +0000
+
+strace (4.5.14-2) unstable; urgency=low
+
+  * New comaintainer.
+  * Fix build failure with linux-2.6.18, thanks to Andreas Henriksson for the
+    patch, closes: #392556.
+  * Fix build with libc6 2.5.
+  * Acknowledge NMUs, closes: #315500, #355733
+
+ -- Frederik Schüler <fs@debian.org>  Thu, 26 Oct 2006 22:11:25 +0200
+
+strace (4.5.14-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fix crash in printing sysctl, closes: #339117.
+    + Respect DEB_BUILD_OPTIONS=nostrip, closes: #325132.
+    + Fix ipc syscall decoding, closes: #340239.
+    + Add missing source files to tarball, closes: #336197.
+    + Build on armeb, closes: #335681.
+
+ -- Roland McGrath <frob@debian.org>  Mon, 16 Jan 2006 22:17:38 -0800
+
+strace (4.5.13-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fix m68k build, closes: #315500.
+    + Fix setsockopt decoding on 64-bit.
+    + Fix typos in socket option name strings.
+    + Display more IPV6 socket options by name.
+    + Don't display inappropriate syscalls for -e trace=file.
+    + New selector type -e trace=desc for file-descriptor using calls.
+    + Fix 32-bit old_mmap syscall decoding on x86-64.
+    + Fix errors detaching from multithreaded process on interrupt.
+    + Note 4.5.12 fix for crash handling bad signal numbers.
+
+ -- Roland McGrath <frob@debian.org>  Wed,  3 Aug 2005 04:41:49 -0700
+
+strace (4.5.12-1) unstable; urgency=low
+
+  * New upstream version.
+    + Build on ppc64, closes: #301089.
+    + Refuse negative -s argument value, closes: #303256.
+    + Fix known syscall recognition for IA32 processes on x86-64.
+    + Fix bad output for ptrace on x86-64.
+    + Fix potential buffer overruns.
+    + Make some diagnostics more consistent.
+    + Update PowerPC system calls.
+    + Better printing for Linux aio system calls.
+    + Don't truncate statfs64 fields to 32 bits in output.
+    + Cosmetic code cleanups.
+
+ -- Roland McGrath <frob@debian.org>  Wed,  8 Jun 2005 13:52:39 -0700
+
+strace (4.5.11-1) unstable; urgency=low
+
+  * New upstream version.
+    + Update MIPS system call table, closes: #256684.
+    + Fix build on s390 and sparc, closes: #294172, #293564.
+    + Fix select handling on nonstandard fd_set sizes, closes: #65654, #284290.
+    + Don't print errors for null file name pointers, closes: #63093.
+    + Fix initial execve output with -i.
+    + Fix build nits, closes: #300598.
+
+ -- Roland McGrath <frob@debian.org>  Tue, 22 Mar 2005 15:12:22 -0800
+
+strace (4.5.9-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fix potential crash in getxattr printing, closes: #283704.
+    + Improve socket ioctl printing, closes: #192164.
+    + Fix sparc build, closes: #278449.
+    + Update ia64 syscall list.
+    + Fix x86_64 syscall argument extraction for 32-bit processes.
+    + Fix -e signal=NAME parsing.
+    + Fix x86_64 exit_group syscall handling.
+    + Improve mount flags printing.
+    + Support symbolic printing of x86_64 arch_prctl parameters.
+    + Add strace-udeb package for Debian installer debugging, closes: #268294.
+
+ -- Roland McGrath <frob@debian.org>  Fri,  4 Feb 2005 01:53:01 -0800
+
+strace (4.5.8-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fix strace64 man page symlink, closes: #269220.
+    + Update syscall tables for Alpha, ARM, HPPA, closes: #273887.
+    + Build strace64 for s390, closes: #271500.
+    + Fix some endian issues in 64-bit argument output on 32-bit machines.
+    + Support new Linux syscalls mbind, set_mempolicy, get_mempolicy, waitid.
+    + Support Linux syscalls fadvise64, fadvise64_64, and epoll_*.
+    + Improve ioctl command name matching.
+    + Print RTC_* ioctl structure contents.
+    + Support newer RLIMIT_* values.
+    + Print struct cmsghdr details in sendmsg.
+
+ -- Roland McGrath <frob@debian.org>  Tue, 19 Oct 2004 18:05:28 -0700
+
+strace (4.5.7-1) unstable; urgency=low
+
+  * New upstream version.
+    + Update man page about -c, closes: #254438.
+    + Include pread/pwrite calls in -e read/write tracing, closes: #239947.
+    + Update SO_* and IP_* value lists, closes: #171653.
+    + Print attribute values in *xattr system calls.
+    + Print clock_t values symbolically in Linux clock_* system calls.
+    + Show PER_* values correctly, closes: #40588.
+    + Fix `strace64' build on sparc, closes: #254728.
+
+ -- Roland McGrath <frob@debian.org>  Tue, 31 Aug 2004 01:41:19 -0700
+
+strace (4.5.6-1) unstable; urgency=low
+
+  * New upstream version.
+    + Update Linux ioctl lists and decode some more network ioctls.
+    + Fix `quotactl' argument decoding on 64-bit.
+    + Linux/SPARC64 support, closes: #254728.
+
+ -- Roland McGrath <frob@debian.org>  Mon, 12 Jul 2004 00:18:32 -0700
+
+strace (4.5.5-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fix support for 32-bit (i386) binaries on Linux/AMD64.
+
+ -- Roland McGrath <frob@debian.org>  Sun, 27 Jun 2004 22:19:15 -0700
+
+strace (4.5.4-1) unstable; urgency=low
+
+  * Build package on amd64, closes: #246568.
+  * New upstream version.
+    + Recognize more PF_* and AF_* values, closes: #250506.
+    + Other  fixes.
+
+ -- Roland McGrath <frob@debian.org>  Thu,  3 Jun 2004 19:35:37 -0700
+
+strace (4.5.3-1) unstable; urgency=low
+
+  * New upstream version.
+    + Finish fix for -f on Linux/S390(x).
+    + Print extra wait status bits, closes: #240062.
+
+ -- Roland McGrath <frob@debian.org>  Fri, 16 Apr 2004 15:27:43 -0700
+
+strace (4.5.2-1) unstable; urgency=low
+
+  * New upstream version.
+    + Check for errors writing to -o file, closes: #218762
+    + Print multiple ioctl code matches on Linux.
+    + Various other fixes.
+    + Update typos and obsolete bits in man page, closes: #217008, #223390
+    + Fix compilation problems with newer kernel headers, closes: #223207
+    + Update HPPA system calls, closes: #231632
+    + Fix PID in messages, closes: #229802
+    + Fix s390 brokenness in 4.5, closes: #226098
+
+ -- Roland McGrath <frob@debian.org>  Mon,  1 Mar 2004 22:44:55 -0800
+
+strace (4.5-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fix mlock syscall printing.
+    + MIPS & S390 updates.
+    + Print names for SIGRT_* in sets.
+
+ -- Roland McGrath <frob@debian.org>  Wed, 24 Sep 2003 15:20:18 -0700
+
+strace (4.4.99-1) unstable; urgency=low
+
+  * New upstream version.
+    + Alpha updates.
+    + Add a few more new Linux 2.5 system calls.
+    + Stephen Thomas contributed a port to Linux/SH64.
+    + Print protocol names for PF_INET6 sockets.
+
+ -- Roland McGrath <frob@debian.org>  Thu, 17 Jul 2003 02:04:43 -0700
+
+strace (4.4.98-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fixes clone argument bugs.
+    + Fixes sem* printing bugs.
+    + Fixes -e argument parsing, closes: #188379.
+    + Fixes hanging parent in odd wait cases, closes: #47608, #109656.
+    + Fixes -q defaulting, closes: #47113, #153678.
+    + Fixes trying to execute directories, closes: #137103.
+    + Updates ARM support, thanks to Russell King.
+    + Updates S390/S390x support.
+  * Bump standards-version to 3.5.10
+
+ -- Roland McGrath <frob@debian.org>  Mon,  2 Jun 2003 12:26:29 -0700
+
+strace (4.4.96-1) unstable; urgency=low
+
+  * New upstream version.
+    + Handles yet more new Linux 2.5 system calls.
+    + Fixes x86_64 and ia64 clone printing.
+    + Updates SH port.
+
+ -- Roland McGrath <frob@debian.org>  Sun, 30 Mar 2003 17:14:34 -0800
+
+strace (4.4.95-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fixes printing of getresuid and getresgid values.
+
+ -- Roland McGrath <frob@debian.org>  Mon, 24 Feb 2003 02:50:43 -0800
+
+strace (4.4.94-1) unstable; urgency=low
+
+  * New upstream version.
+    + New option -E to set environment variables.
+    + Build fixes for sparc, closes: #178636.
+
+ -- Roland McGrath <frob@debian.org>  Wed, 19 Feb 2003 19:12:40 -0800
+
+strace (4.4.93-1) unstable; urgency=low
+
+  * New upstream version.
+    + Grok new quotactl arguments, closes: #154067.
+    + Fix m68k build problem, closes: #176528.
+    + Old bugs prior release actually closes: #154068.
+    + Fix S390 bugs with -f, and bugs with execve.
+  * Switched to non-native packaging (empty .diff), closes: #176388.
+
+ -- Roland McGrath <frob@debian.org>  Tue, 21 Jan 2003 12:22:08 -0800
+
+strace (4.4.92-1) unstable; urgency=low
+
+  * New upstream version.
+    + Updated config.guess and config.sub, closes: #176241.
+    + Several fixes for PPC, closes: #144326.
+    + Fixed ptrace output for unknown requests, closes: #77728.
+    + Fixed output of getdents64, truncate64, ftruncate64, closes: #169528.
+    + Old bugs the last release actually closes: #153750, #38467, #109993,
+      #109815, #104594, #113087, #134803, #166622, #96356, #94725, #32147,
+      #32798, #36801, #41066, #81637, #138300, #143791.
+
+ -- Roland McGrath <frob@debian.org>  Tue, 14 Jan 2003 02:02:44 -0800
+
+strace (4.4.91-1) unstable; urgency=low
+
+  * New upstream version.
+    + Fixes -f on x86-64.
+
+ -- Roland McGrath <frob@debian.org>  Fri, 10 Jan 2003 12:55:34 -0800
+
+strace (4.4.90-1) unstable; urgency=low
+
+  * New maintainer.
+  * New upstream version.
+
+ -- Roland McGrath <frob@debian.org>  Fri, 10 Jan 2003 01:58:40 -0800
+
+strace (4.4-1.2) unstable; urgency=low
+
+  * NMU
+  * Quick one-liner to allow building on the ARM. Closes: #109993.
+  * Re-ran autoconf, hopefully I didn't break other arches.
+
+ -- Anand Kumria <wildfire@progsoc.org>  Mon,  1 Oct 2001 14:22:25 +1000
+
+strace (4.4-1.1) unstable; urgency=low
+
+  * NMU.
+  * Added patch from David Mosberger which fixes some ia64 issues.
+    Closes: #113087.
+  * Added ia64-specific Build-Depends on libc6.1-dev.  Closes:
+    #109815.
+  * Ran autoheader, so the s390 patch applies.  Closes: #104594.
+
+ -- Jeff Licquia <jlicquia@progeny.com>  Tue, 25 Sep 2001 13:15:28 -0500
+
+strace (4.4-1) unstable; urgency=low
+
+  * New upstream version
+    + Added S390 support. Closes: Bug#104594
+    + New config.{guess,sub}. Closes: Bug#92532
+    + LFS support for Linux/sparc. Closes: Bug#99215
+    * Works on IA64 again. Closes: Bug#103854
+  * Don't override CFLAGS in debian/rules
+  * Remove rules to create configure & friends. Closes: Bug#92483
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sun, 19 Aug 2001 14:10:58 +0200
+
+strace (4.3-3.1) unstable; urgency=low
+
+  * copy in new config.{guess,sub} to get support for new architectures.
+    Closes: #94725
+
+ -- LaMont Jones <lamont@debian.org>  Mon,  9 Jul 2001 21:39:34 -0600
+
+strace (4.3-3) unstable; urgency=low
+
+  * Update architecture list
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sat, 14 Apr 2001 10:42:19 +0200
+
+strace (4.3-2) unstable; urgency=low
+
+  * Run cvsbuild so we don't need to run autohead & friends
+  * Sync to current CVS
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 13 Apr 2001 19:08:53 +0200
+
+strace (4.3-1) unstable; urgency=low
+
+  * New upstream version
+  * Updated Build-Depends to use a recent glibc so we get the 2.4 kernel
+    headers
+  * Changed Architecture so we only build on Linux
+  * Include section and priority in control info
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sun,  1 Apr 2001 16:35:32 +0200
+
+strace (4.2-4) frozen unstable; urgency=low
+
+  * Actually install postinst and prerm so we get the proper /usr/doc/strace
+    symlink
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Thu, 17 Feb 2000 21:49:17 +0100
+
+strace (4.2-3) frozen unstable; urgency=low
+
+  * Fix typo in aclocal.m4 that prevented compilation on architectures without
+    LFS
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sun, 13 Feb 2000 01:19:11 +0100
+
+strace (4.2-2) frozen unstable; urgency=low
+
+  * only include linux/ptrace.h if sys/reg.h hasn't been found by configure,
+    Closes: Bug# 39556
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Thu, 27 Jan 2000 03:22:55 +0100
+
+strace (4.2-1) frozen unstable; urgency=low
+
+  * New upstream version:
+    + Builds correctly on glibc2.0 again, Closes: Bug# 51648
+    + Small y2k fix in printtimes, Closes: Bug# 54592
+    + semop is handled now, Closes: Bug# 52684
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 21 Jan 2000 21:45:41 +0100
+
+strace (4.1-1) unstable; urgency=low
+
+  * New upstream version
+  * Bump standards-version to 3.1.0
+  * FHS 2.1 compliant
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 26 Nov 1999 01:42:07 +0100
+
+strace (4.0-1) unstable; urgency=low
+
+  * New upstream version
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri,  9 Jul 1999 16:12:34 +0200
+
+strace (3.99.1-1) unstable; urgency=low
+
+  * New upstream version, second pre-release for 4.0
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Wed,  9 Jun 1999 15:20:42 +0200
+
+strace (3.99-1) unstable; urgency=low
+
+  * New upstream maintainer (me :)
+  * New upstream version, pre-release for strace 4.0
+  * See upstream changelog for changes
+  * Build with glibc2.1
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Tue, 27 Apr 1999 14:00:15 +0200
+
+strace (3.1.0.1-12) unstable; urgency=low
+
+  * Only i386 has a LDT, so check for architecture in mem.c (Bug# 32798)
+  * Check for nsignals properly, closes: #34445
+  * Fix check for overruns in umove*, patch by Nate Eldredge <nate@cartsys.com>
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon, 15 Mar 1999 00:43:14 +0100
+
+strace (3.1.0.1-11) unstable; urgency=low
+
+  * Merge some ARM stuff that got stuck in my mailbox
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sun, 31 Jan 1999 13:04:13 +0100
+
+strace (3.1.0.1-10) unstable; urgency=low
+
+  * Move sys_poll to the DONE section in linux/dummy.h
+  * Support subarchitectures for alpha (Bug# 32147)
+  * Incorporate changes from Ulrich Drepper
+    + up number of supported personalities on Linux sparc to 3
+    + add O_DIRECT, O_LARGEFILE and O_DIRECTORY to openmodes
+    + change prefix for printxval to SEEK_ in sys_lseek
+    + add a support for a whole bunch of syscalls
+    + updated sys_pread and sys_pwrite for SVR4
+    + handle sys_delete_module properly
+    + change SYS_socket_subcall to 230 for non-powerpc architectures
+    + sys_chown is now lchown
+    + looks like a whole lot of syscalls is moved from 180 to 230
+    + Revamp a lot of the signal handling code
+    + handle sys_clone
+    + Lots more (it was a 6494-line patch and I'm too lazy to put all
+      changes in here..)
+  * Please note you need to have 2.1 or 2.2 kernel sources in /usr/src/linux
+    in order to compile this.
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 29 Jan 1999 02:04:12 +0100
+
+strace (3.1.0.1-9) unstable; urgency=low
+
+  * Add support for poll() systemcall
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Thu, 31 Dec 1998 16:03:44 +0100
+
+strace (3.1.0.1-8) frozen unstable; urgency=low
+
+  * Use new_stat from libc6 now, except for powerpc and sparc
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Thu, 24 Dec 1998 11:35:32 +0100
+
+strace (3.1.0.1-7) frozen unstable; urgency=low
+
+  * Fix sparc support
+  * Display nanosleep call correctly (Bug# 25904)
+  * Honour -v flag in printargs (Bug# 10426)
+  * Play with #define to get proper kernel struct stat
+  * Compile with 2.1.131 kernel source
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sat, 19 Dec 1998 15:02:14 +0100
+
+strace (3.1.0.1-6) frozen unstable; urgency=low
+
+  * Set NSIG correctly for ARM
+  * Include strace-graph script from Richard Braakman <dark@debian.org>
+    as an example. Try it and be amazed!
+  * Fix sigaction problem, patch from Topi Miettinen
+    <Topi.Miettinen@medialab.sonera.net>
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon,  7 Dec 1998 02:10:30 +0100
+
+strace (3.1.0.1-5) unstable; urgency=low
+
+  * Patched from Richard Braakman <dark@debian.org>:
+    + use correct dirent.h on Linux
+    + remove debugging code left from the powerpc patch
+    + fix output for execve when -v is used
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 13 Nov 1998 15:59:17 +0100
+
+strace (3.1.0.1-5) unstable; urgency=low
+
+  * Add location of upstream sources to the copyright
+  * Merged ARM architecture support from Jim Studt <jim@federated.com>
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon,  9 Nov 1998 16:43:24 +0100
+
+strace (3.1.0.1-4) unstable; urgency=low
+
+  * More ppc patches from Daniel Jacobowitz <dan@debian.org>
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon, 12 Oct 1998 00:59:44 +0200
+
+strace (3.1.0.1-3) unstable; urgency=low
+
+  * Added support for sys_query_module, patch from Brian J. Murrell
+    <brian@interlinx.bc.ca>
+  * Preserve timestamps for documentation when installed
+  * Incorporate patches from Daniel Jacobowitz <dan@debian.org>:
+    + powerpc patches
+    + Patches include changing SYS_socket_subcall and SYS_ipc_subcall,
+      check for stray syscall exit after execv, and completely regenerated
+      syscall, errno, and ioctl lists.
+    + Decode capget and capset arguments.
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Sun, 11 Oct 1998 22:42:56 +0200
+
+strace (3.1.0.1-2) unstable; urgency=low
+
+  * Patch to support sparc, courtesy of RedHat
+  * Cleaned up some stuff the patch left broken
+  * Fix some more compilation-issues for IPX with current kernels
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 24 Jul 1998 22:53:43 +0200
+
+strace (3.1.0.1-1) unstable; urgency=low
+
+  * New (actually very old) upstream version. Fixes something we
+    already had fixed
+  * Compiled with current kernel-headers from libc6-dev
+  * Fixed spelling-error
+  * Compress changelog
+  * Bumped standard-version to 2.4.1.0
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Wed, 22 Jul 1998 15:53:23 +0200
+
+strace (3.1-14) unstable; urgency=low
+
+  * Don't let libc6 trick us anymore with {f,l,}stat() calls
+  * Fix configure.in to support PentiumII processors
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon, 22 Jun 1998 20:17:20 +0200
+
+strace (3.1-13) unstable; urgency=low
+
+  * Corrected error on PowerPC patch that broke other archictectures
+    (Bug# 13837)
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Tue, 14 Oct 1997 15:41:29 +0200
+
+strace (3.1-12) unstable; urgency=low
+
+  * PowerPC patches by Klee Dienes (Bug# 10788, 10790)
+  * Create correct md5sums (Bug# 13363)
+  * Put changelog in correct place (Bug# 13363)
+  * Pristine sources
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon,  6 Oct 1997 15:42:25 +0200
+
+strace (3.1-11) unstable; urgency=low
+
+  * Ported to libc6 / glibc2 (Bug# 11729)
+  * Compress manpage
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>  Fri,  1 Aug 1997 00:13:38 +0200
+
+strace (3.1-10) unstable; urgency=low
+
+  * Install upstream changelog
+  * Added dependencies to control file for libc
+  * Added md5sums to .deb file
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Fri, 11 Jul 1997 12:26:12 +0200
+
+strace (3.1-9) stable; urgency=low
+
+  * Fixed bug with hanging children. Patch by Matthias Urlichs
+  * Added some more constants to net.c.
+  * glibc patches, courtesy of Klee Dienes (Bug# 7735)
+
+ -- Wichert Akkerman <wakkerma@debian.org>  Mon, 21 Apr 1997 11:59:45 +0200
+
+strace (3.1-8) frozen unstable; urgency=low
+
+  * Added detection of ROSE networking
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>  Tue, 12 Nov 1996 22:21:22 +0100
+
+strace (3.1-7) stable; urgency=low
+
+  * Install manpage with correct mode (0644) (Bug#4813)
+  * Renamed debian changelog to changelog.Debian
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>  Sat, 26 Oct 1996 18:15:41 +0200
+
+strace (3.1-6) stable; urgency=low
+
+  * Small patch for compilation on kernels 2.1.0 and later (see signal.c)
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>  Fri, 18 Oct 1996 00:28:47 +0200
+
+strace (3.1-5) stable unstable; urgency=low
+
+  * Moved to new packagingformat
+  * Fixed umoven bug (Bug# 4523)
+  * Corrected number of parameters for mmap systemcall (bug# 4508)
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>  Sat, 23 Sep 1996 23:33:58 +0200
+
+strace (3.1-4) unstable; urgency=low
+
+  * Fixed changestemplate
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>, Thu Sep 12 14:59:44 MET DST 1996
+
+strace (3.1-3) unstable; urgency=low
+
+  * Revamped debian files
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>, Thu Jul 11 20:19:11 MET DST 1996
+
+
+strace (3.1-2) unstable; urgency=low
+  * Added some #ifdef's around IPX stuff to make it compilable on non-Linux
+    systems.
+  * changed debian.control and debian.rules to conform to new debian naming
+    schemes
+  * added architecture-option to debian.rules and debian.control
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>
+
+strace (3.1-1) unstable; urgency=low
+
+  * Moved to new upstream version
+  * added more protocol families to domains
+  * added IPIP-protocol to protocols
+  * added MSG_PROXY and MSG_CTRUNC to msg_flags
+  * added SO_BSDCOMPAT and SO_REUSEPORT to sockoptions
+  * added IP, IPX and TCP-options
+  * added IP, IPX and TCP support to get-/setsockopt()
+  * added IPX support
+
+ -- Wichert Akkerman <wakkerma@wi.leidenuniv.nl>
diff --git a/strace/debian/compat b/strace/debian/compat
new file mode 100644
index 0000000..7f8f011
--- /dev/null
+++ b/strace/debian/compat
@@ -0,0 +1 @@
+7
diff --git a/strace/debian/control b/strace/debian/control
new file mode 100644
index 0000000..570542f
--- /dev/null
+++ b/strace/debian/control
@@ -0,0 +1,56 @@
+Source: strace
+Maintainer: Steve McIntyre <93sam@debian.org>
+Section: utils
+Priority: optional
+Build-Depends: libc6-dev (>= 2.2.2) [!alpha !ia64], libc6.1-dev (>= 2.2.2) [alpha ia64], gcc-multilib [amd64 i386 powerpc ppc64 s390 sparc sparc64 x32], debhelper (>= 7.0.0), gawk
+Standards-Version: 3.9.6
+Homepage: http://sourceforge.net/projects/strace/
+
+Package: strace
+Architecture: alpha amd64 arm64 armeb armel armhf hppa i386 ia64 m68k mips mipsel mips64 mips64el or1k powerpc powerpcspe ppc64 ppc64el s390 s390x sh4 sparc sparc64 x32
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: System call tracer
+ strace is a system call tracer, i.e. a debugging tool which prints out
+ a trace of all the system calls made by a another process/program.
+ The program to be traced need not be recompiled for this, so you can
+ use it on binaries for which you don't have source.
+ .
+ System calls and signals are events that happen at the user/kernel
+ interface. A close examination of this boundary is very useful for bug
+ isolation, sanity checking and attempting to capture race conditions.
+
+Package: strace64
+Architecture: i386 powerpc s390 sparc
+Priority: extra
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: System call tracer for 64bit binaries
+ strace is a system call tracer, i.e. a debugging tool which prints out
+ a trace of all the system calls made by a another process/program.
+ The program to be traced need not be recompiled for this, so you can
+ use it on binaries for which you don't have source.
+ .
+ This package contains the 64bit version of the binary, intended for
+ biarch systems with 32bit userland and 64bit kernel.
+ .
+ System calls and signals are events that happen at the user/kernel
+ interface. A close examination of this boundary is very useful for bug
+ isolation, sanity checking and attempting to capture race conditions.
+
+Package: strace-udeb
+Section: debian-installer
+XC-Package-Type: udeb
+Priority: extra
+Architecture: alpha amd64 arm64 armeb armel armhf hppa i386 ia64 m68k mips mipsel mips64 mips64el or1k powerpc powerpcspe ppc64 ppc64el s390 sh4 sparc sparc64 x32
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: System call tracer
+ strace is a system call tracer, i.e. a debugging tool which prints out
+ a trace of all the system calls made by a another process/program.
+ The program to be traced need not be recompiled for this, so you can
+ use it on binaries for which you don't have source.
+ .
+ System calls and signals are events that happen at the user/kernel
+ interface. A close examination of this boundary is very useful for bug
+ isolation, sanity checking and attempting to capture race conditions.
+ .
+ This is a stripped down package intended for debugging use in the Debian
+ installer.
diff --git a/strace/debian/copyright b/strace/debian/copyright
new file mode 100644
index 0000000..fd35507
--- /dev/null
+++ b/strace/debian/copyright
@@ -0,0 +1,39 @@
+This is the Debian packaged version of strace. For a complete list of
+changes from the upstream version please see the changelog.
+
+The upstream sources can be found at http://sourceforge.net/projects/strace/
+
+This is the copyright as found in the upstream sources:
+
+Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+Copyright (c) 1995, 1996 Michael Elizabeth Chastain <mec@duracef.shout.net>
+Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+Copyright (C) 1998-2003 Wichert Akkerman <wakkerma@deephackmode.org>
+Copyright (c) 2002-2008 Roland McGrath  <roland@redhat.com>
+Copyright (c) 2003-2008 Dmitry V. Levin <ldv@altlinux.org>
+Copyright (c) 2007-2008 Jan Kratochvil  <jan.kratochvil@redhat.com>
+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.
diff --git a/strace/debian/rules b/strace/debian/rules
new file mode 100755
index 0000000..4b556a7
--- /dev/null
+++ b/strace/debian/rules
@@ -0,0 +1,95 @@
+#! /usr/bin/make -f
+
+#export DH_VERBOSE=1
+
+export DEB_BUILD_MAINT_OPTIONS = hardening=+all
+DPKG_EXPORT_BUILDFLAGS = 1
+include /usr/share/dpkg/buildflags.mk
+
+CFLAGS += -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+  CFLAGS += -O0
+else
+  CFLAGS += -O2
+endif
+
+ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
+  NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
+  MAKEFLAGS += -j$(NUMJOBS)
+endif
+
+DEB_BUILD_GNU_TYPE := $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+DEB_HOST_GNU_TYPE := $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_HOST_ARCH := $(shell dpkg-architecture -qDEB_HOST_ARCH)
+
+arch64_map = i386=x86_64 powerpc=powerpc64 sparc=sparc64 s390=s390x
+ifneq (,$(filter $(DEB_HOST_ARCH)=%, $(arch64_map)))
+  HOST64 = $(strip $(patsubst $(DEB_HOST_ARCH)=%, %, \
+	     $(filter $(DEB_HOST_ARCH)=%, $(arch64_map))))-linux-gnu
+  CC64 = gcc -m64
+  extra_build_targets += build64-stamp
+endif
+
+ifeq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
+  CONFIG_OPTS = --build=$(DEB_BUILD_GNU_TYPE)
+else
+  CONFIG_OPTS = --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE)
+endif
+
+all: build
+
+build: build-arch build-indep
+
+build-arch: build-stamp $(extra_build_targets)
+build-indep: build-stamp $(extra_build_targets)
+
+%-stamp: %/Makefile
+	$(MAKE) -C $*
+ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
+	$(MAKE) -C $* check VERBOSE=1
+endif
+	touch $@
+
+build/Makefile:
+	mkdir -p $(@D)
+	cd $(@D); sh ../configure --prefix=/usr $(CONFIG_OPTS)
+
+build64/Makefile:
+	mkdir -p $(@D)
+	cd $(@D); CC="$(CC64)" sh ../configure --prefix=/usr --build=$(DEB_BUILD_GNU_TYPE) --host=$(HOST64)
+
+clean:
+	dh_testdir
+	dh_testroot
+	rm -rf build build64 strace64.1 debian/strace64.substvars
+	dh_clean
+
+binary: binary-indep binary-arch
+
+binary-indep:
+
+binary-arch: build
+	test -f build-stamp || make $(MFLAGS) -f debian/rules build
+
+	# prepare 64bit executable and manpage, if it has been built
+	test -f build64-stamp && ( mv build64/strace build64/strace64 ; \
+		cp strace.1 strace64.1 ) || true
+
+	dh_testdir -s
+	dh_testroot -s
+	dh_installdirs -s
+	dh_installdocs -s
+	dh_installman -s
+	dh_installexamples -s
+	dh_installchangelogs -s
+	dh_install -s
+	dh_link -s
+	dh_strip -s
+	dh_compress -s
+	dh_fixperms -s
+	dh_installdeb -s
+	dh_shlibdeps -s
+	dh_gencontrol -s
+	dh_md5sums -s
+	dh_builddeb -s
diff --git a/strace/debian/source/format b/strace/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/strace/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/strace/debian/strace-udeb.install b/strace/debian/strace-udeb.install
new file mode 100644
index 0000000..1f41928
--- /dev/null
+++ b/strace/debian/strace-udeb.install
@@ -0,0 +1 @@
+build/strace usr/bin
diff --git a/strace/debian/strace.docs b/strace/debian/strace.docs
new file mode 100644
index 0000000..edc0071
--- /dev/null
+++ b/strace/debian/strace.docs
@@ -0,0 +1 @@
+NEWS
diff --git a/strace/debian/strace.examples b/strace/debian/strace.examples
new file mode 100644
index 0000000..06b4d96
--- /dev/null
+++ b/strace/debian/strace.examples
@@ -0,0 +1 @@
+strace-graph
diff --git a/strace/debian/strace.install b/strace/debian/strace.install
new file mode 100644
index 0000000..1f41928
--- /dev/null
+++ b/strace/debian/strace.install
@@ -0,0 +1 @@
+build/strace usr/bin
diff --git a/strace/debian/strace.manpages b/strace/debian/strace.manpages
new file mode 100644
index 0000000..5e74dd7
--- /dev/null
+++ b/strace/debian/strace.manpages
@@ -0,0 +1 @@
+strace.1
diff --git a/strace/debian/strace64.install b/strace/debian/strace64.install
new file mode 100644
index 0000000..2d3036d
--- /dev/null
+++ b/strace/debian/strace64.install
@@ -0,0 +1 @@
+build64/strace64 usr/bin
diff --git a/strace/debian/strace64.manpages b/strace/debian/strace64.manpages
new file mode 100644
index 0000000..e3adc93
--- /dev/null
+++ b/strace/debian/strace64.manpages
@@ -0,0 +1 @@
+strace64.1
diff --git a/strace/debian/watch b/strace/debian/watch
new file mode 100644
index 0000000..5e4f652
--- /dev/null
+++ b/strace/debian/watch
@@ -0,0 +1,2 @@
+version=3
+opts="uversionmangle=s/-/./g" http://sf.net/strace/strace-([[:digit:].-]*)\.tar\.xz
diff --git a/strace/defs.h b/strace/defs.h
new file mode 100644
index 0000000..4b7e8ed
--- /dev/null
+++ b/strace/defs.h
@@ -0,0 +1,901 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
+#include <features.h>
+#ifdef HAVE_STDBOOL_H
+# include <stdbool.h>
+#endif
+#include <stdint.h>
+#include <inttypes.h>
+#include <sys/types.h>
+#ifdef STDC_HEADERS
+# include <stddef.h>
+#endif
+#include <unistd.h>
+#include <stdlib.h>
+#include <stdio.h>
+/* Open-coding isprint(ch) et al proved more efficient than calling
+ * generalized libc interface. We don't *want* to do non-ASCII anyway.
+ */
+/* #include <ctype.h> */
+#include <string.h>
+#include <errno.h>
+#include <time.h>
+#include <sys/time.h>
+#include <sys/syscall.h>
+
+#include "mpers_type.h"
+#include "gcc_compat.h"
+
+#ifndef HAVE_STRERROR
+const char *strerror(int);
+#endif
+#ifndef HAVE_STPCPY
+/* Some libc have stpcpy, some don't. Sigh...
+ * Roll our private implementation...
+ */
+#undef stpcpy
+#define stpcpy strace_stpcpy
+extern char *stpcpy(char *dst, const char *src);
+#endif
+
+#ifndef offsetof
+# define offsetof(type, member)	\
+	(((char *) &(((type *) NULL)->member)) - ((char *) (type *) NULL))
+#endif
+
+#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0]))
+
+/* macros */
+#ifndef MAX
+# define MAX(a, b)		(((a) > (b)) ? (a) : (b))
+#endif
+#ifndef MIN
+# define MIN(a, b)		(((a) < (b)) ? (a) : (b))
+#endif
+#define CLAMP(val, min, max) MIN(MAX(min, val), max)
+
+/* Glibc has an efficient macro for sigemptyset
+ * (it just does one or two assignments of 0 to internal vector of longs).
+ */
+#if defined(__GLIBC__) && defined(__sigemptyset) && !defined(sigemptyset)
+# define sigemptyset __sigemptyset
+#endif
+
+/* Configuration section */
+#ifndef DEFAULT_STRLEN
+/* default maximum # of bytes printed in `printstr', change with -s switch */
+# define DEFAULT_STRLEN	32
+#endif
+#ifndef DEFAULT_ACOLUMN
+# define DEFAULT_ACOLUMN	40	/* default alignment column for results */
+#endif
+/*
+ * Maximum number of args to a syscall.
+ *
+ * Make sure that all entries in all syscallent.h files have nargs <= MAX_ARGS!
+ * linux/<ARCH>/syscallent*.h:
+ * 	all have nargs <= 6 except mips o32 which has nargs <= 7.
+ */
+#ifndef MAX_ARGS
+# ifdef LINUX_MIPSO32
+#  define MAX_ARGS	7
+# else
+#  define MAX_ARGS	6
+# endif
+#endif
+/* default sorting method for call profiling */
+#ifndef DEFAULT_SORTBY
+# define DEFAULT_SORTBY "time"
+#endif
+/*
+ * Experimental code using PTRACE_SEIZE can be enabled here.
+ * This needs Linux kernel 3.4.x or later to work.
+ */
+#define USE_SEIZE 1
+/* To force NOMMU build, set to 1 */
+#define NOMMU_SYSTEM 0
+/*
+ * Set to 1 to use speed-optimized vfprintf implementation.
+ * It results in strace using about 5% less CPU in user space
+ * (compared to glibc version).
+ * But strace spends a lot of time in kernel space,
+ * so overall it does not appear to be a significant win.
+ * Thus disabled by default.
+ */
+#define USE_CUSTOM_PRINTF 0
+
+#ifndef ERESTARTSYS
+# define ERESTARTSYS    512
+#endif
+#ifndef ERESTARTNOINTR
+# define ERESTARTNOINTR 513
+#endif
+#ifndef ERESTARTNOHAND
+# define ERESTARTNOHAND 514
+#endif
+#ifndef ERESTART_RESTARTBLOCK
+# define ERESTART_RESTARTBLOCK 516
+#endif
+
+#if defined(SPARC) || defined(SPARC64)
+# define PERSONALITY0_WORDSIZE 4
+# if defined(SPARC64)
+#  define SUPPORTED_PERSONALITIES 2
+#  define PERSONALITY1_WORDSIZE 8
+#  ifdef HAVE_M32_MPERS
+#   define PERSONALITY1_INCLUDE_FUNCS "m32_funcs.h"
+#   define PERSONALITY1_INCLUDE_PRINTERS_DECLS "m32_printer_decls.h"
+#   define PERSONALITY1_INCLUDE_PRINTERS_DEFS "m32_printer_defs.h"
+#   define MPERS_m32_IOCTL_MACROS "ioctl_redefs1.h"
+#  endif
+# endif
+#endif
+
+#ifdef X86_64
+# define SUPPORTED_PERSONALITIES 3
+# define PERSONALITY0_WORDSIZE 8
+# define PERSONALITY1_WORDSIZE 4
+# define PERSONALITY2_WORDSIZE 4
+# ifdef HAVE_M32_MPERS
+#  define PERSONALITY1_INCLUDE_FUNCS "m32_funcs.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DECLS "m32_printer_decls.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DEFS "m32_printer_defs.h"
+#  define MPERS_m32_IOCTL_MACROS "ioctl_redefs1.h"
+# endif
+# ifdef HAVE_MX32_MPERS
+#  define PERSONALITY2_INCLUDE_FUNCS "mx32_funcs.h"
+#  define PERSONALITY2_INCLUDE_PRINTERS_DECLS "mx32_printer_decls.h"
+#  define PERSONALITY2_INCLUDE_PRINTERS_DEFS "mx32_printer_defs.h"
+#  define MPERS_mx32_IOCTL_MACROS "ioctl_redefs2.h"
+# endif
+#endif
+
+#ifdef X32
+# define SUPPORTED_PERSONALITIES 2
+# define PERSONALITY0_WORDSIZE 4
+# define PERSONALITY1_WORDSIZE 4
+# ifdef HAVE_M32_MPERS
+#  define PERSONALITY1_INCLUDE_FUNCS "m32_funcs.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DECLS "m32_printer_decls.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DEFS "m32_printer_defs.h"
+#  define MPERS_m32_IOCTL_MACROS "ioctl_redefs1.h"
+# endif
+#endif
+
+#ifdef ARM
+/* one personality */
+#endif
+
+#ifdef AARCH64
+/* The existing ARM personality, then AArch64 */
+# define SUPPORTED_PERSONALITIES 2
+# define PERSONALITY0_WORDSIZE 8
+# define PERSONALITY1_WORDSIZE 4
+# ifdef HAVE_M32_MPERS
+#  define PERSONALITY1_INCLUDE_FUNCS "m32_funcs.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DECLS "m32_printer_decls.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DEFS "m32_printer_defs.h"
+#  define MPERS_m32_IOCTL_MACROS "ioctl_redefs1.h"
+# endif
+#endif
+
+#ifdef POWERPC64
+# define SUPPORTED_PERSONALITIES 2
+# define PERSONALITY0_WORDSIZE 8
+# define PERSONALITY1_WORDSIZE 4
+# ifdef HAVE_M32_MPERS
+#  define PERSONALITY1_INCLUDE_FUNCS "m32_funcs.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DECLS "m32_printer_decls.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DEFS "m32_printer_defs.h"
+#  define MPERS_m32_IOCTL_MACROS "ioctl_redefs1.h"
+# endif
+#endif
+
+#ifdef TILE
+# define SUPPORTED_PERSONALITIES 2
+# define PERSONALITY0_WORDSIZE 8
+# define PERSONALITY1_WORDSIZE 4
+# ifdef __tilepro__
+#  define DEFAULT_PERSONALITY 1
+# endif
+# ifdef HAVE_M32_MPERS
+#  define PERSONALITY1_INCLUDE_FUNCS "m32_funcs.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DECLS "m32_printer_decls.h"
+#  define PERSONALITY1_INCLUDE_PRINTERS_DEFS "m32_printer_defs.h"
+#  define MPERS_m32_IOCTL_MACROS "ioctl_redefs1.h"
+# endif
+#endif
+
+#ifndef SUPPORTED_PERSONALITIES
+# define SUPPORTED_PERSONALITIES 1
+#endif
+#ifndef DEFAULT_PERSONALITY
+# define DEFAULT_PERSONALITY 0
+#endif
+#ifndef PERSONALITY0_WORDSIZE
+# define PERSONALITY0_WORDSIZE SIZEOF_LONG
+#endif
+
+#ifndef PERSONALITY0_INCLUDE_PRINTERS_DECLS
+# define PERSONALITY0_INCLUDE_PRINTERS_DECLS "native_printer_decls.h"
+#endif
+#ifndef PERSONALITY0_INCLUDE_PRINTERS_DEFS
+# define PERSONALITY0_INCLUDE_PRINTERS_DEFS "native_printer_defs.h"
+#endif
+
+#ifndef PERSONALITY1_INCLUDE_PRINTERS_DECLS
+# define PERSONALITY1_INCLUDE_PRINTERS_DECLS "native_printer_decls.h"
+#endif
+#ifndef PERSONALITY1_INCLUDE_PRINTERS_DEFS
+# define PERSONALITY1_INCLUDE_PRINTERS_DEFS "native_printer_defs.h"
+#endif
+
+#ifndef PERSONALITY2_INCLUDE_PRINTERS_DECLS
+# define PERSONALITY2_INCLUDE_PRINTERS_DECLS "native_printer_decls.h"
+#endif
+#ifndef PERSONALITY2_INCLUDE_PRINTERS_DEFS
+# define PERSONALITY2_INCLUDE_PRINTERS_DEFS "native_printer_defs.h"
+#endif
+
+#ifndef PERSONALITY1_INCLUDE_FUNCS
+# define PERSONALITY1_INCLUDE_FUNCS "empty.h"
+#endif
+#ifndef PERSONALITY2_INCLUDE_FUNCS
+# define PERSONALITY2_INCLUDE_FUNCS "empty.h"
+#endif
+
+typedef struct sysent {
+	unsigned nargs;
+	int	sys_flags;
+	int	sen;
+	int	(*sys_func)();
+	const char *sys_name;
+} struct_sysent;
+
+typedef struct ioctlent {
+	const char *symbol;
+	unsigned int code;
+} struct_ioctlent;
+
+#if defined LINUX_MIPSN32 || defined X32
+# define HAVE_STRUCT_TCB_EXT_ARG 1
+#else
+# define HAVE_STRUCT_TCB_EXT_ARG 0
+#endif
+
+/* Trace Control Block */
+struct tcb {
+	int flags;		/* See below for TCB_ values */
+	int pid;		/* If 0, this tcb is free */
+	int qual_flg;		/* qual_flags[scno] or DEFAULT_QUAL_FLAGS + RAW */
+	int u_error;		/* Error code */
+	long scno;		/* System call number */
+	long u_arg[MAX_ARGS];	/* System call arguments */
+#if HAVE_STRUCT_TCB_EXT_ARG
+	long long ext_arg[MAX_ARGS];
+	long long u_lrval;	/* long long return value */
+#endif
+	long u_rval;		/* Return value */
+#if SUPPORTED_PERSONALITIES > 1
+	unsigned int currpers;	/* Personality at the time of scno update */
+#endif
+	int sys_func_rval;	/* Syscall entry parser's return value */
+	int curcol;		/* Output column for this process */
+	FILE *outf;		/* Output file for this process */
+	const char *auxstr;	/* Auxiliary info from syscall (see RVAL_STR) */
+	void *_priv_data;	/* Private data for syscall decoding functions */
+	void (*_free_priv_data)(void *); /* Callback for freeing priv_data */
+	const struct_sysent *s_ent; /* sysent[scno] or dummy struct for bad scno */
+	const struct_sysent *s_prev_ent; /* for "resuming interrupted SYSCALL" msg */
+	struct timeval stime;	/* System time usage as of last process wait */
+	struct timeval dtime;	/* Delta for system time usage */
+	struct timeval etime;	/* Syscall entry time */
+
+#ifdef USE_LIBUNWIND
+	struct UPT_info* libunwind_ui;
+	struct mmap_cache_t* mmap_cache;
+	unsigned int mmap_cache_size;
+	unsigned int mmap_cache_generation;
+	struct queue_t* queue;
+#endif
+};
+
+/* TCB flags */
+/* We have attached to this process, but did not see it stopping yet */
+#define TCB_STARTUP		0x01
+#define TCB_IGNORE_ONE_SIGSTOP	0x02	/* Next SIGSTOP is to be ignored */
+/*
+ * Are we in system call entry or in syscall exit?
+ *
+ * This bit is set after all syscall entry processing is done.
+ * Therefore, this bit will be set when next ptrace stop occurs,
+ * which should be syscall exit stop. Other stops which are possible
+ * directly after syscall entry (death, ptrace event stop)
+ * are simpler and handled without calling trace_syscall(), therefore
+ * the places where TCB_INSYSCALL can be set but we aren't in syscall stop
+ * are limited to trace(), this condition is never observed in trace_syscall()
+ * and below.
+ * The bit is cleared after all syscall exit processing is done.
+ *
+ * Use entering(tcp) / exiting(tcp) to check this bit to make code more readable.
+ */
+#define TCB_INSYSCALL	0x04
+#define TCB_ATTACHED	0x08	/* We attached to it already */
+#define TCB_REPRINT	0x10	/* We should reprint this syscall on exit */
+#define TCB_FILTERED	0x20	/* This system call has been filtered out */
+
+/* qualifier flags */
+#define QUAL_TRACE	0x001	/* this system call should be traced */
+#define QUAL_ABBREV	0x002	/* abbreviate the structures of this syscall */
+#define QUAL_VERBOSE	0x004	/* decode the structures of this syscall */
+#define QUAL_RAW	0x008	/* print all args in hex for this syscall */
+#define QUAL_SIGNAL	0x010	/* report events with this signal */
+#define QUAL_READ	0x020	/* dump data read on this file descriptor */
+#define QUAL_WRITE	0x040	/* dump data written to this file descriptor */
+typedef uint8_t qualbits_t;
+
+#define DEFAULT_QUAL_FLAGS (QUAL_TRACE | QUAL_ABBREV | QUAL_VERBOSE)
+
+#define entering(tcp)	(!((tcp)->flags & TCB_INSYSCALL))
+#define exiting(tcp)	((tcp)->flags & TCB_INSYSCALL)
+#define syserror(tcp)	((tcp)->u_error != 0)
+#define verbose(tcp)	((tcp)->qual_flg & QUAL_VERBOSE)
+#define abbrev(tcp)	((tcp)->qual_flg & QUAL_ABBREV)
+#define filtered(tcp)	((tcp)->flags & TCB_FILTERED)
+
+#include "xlat.h"
+
+extern const struct xlat addrfams[];
+extern const struct xlat at_flags[];
+extern const struct xlat dirent_types[];
+extern const struct xlat evdev_abs[];
+extern const struct xlat msg_flags[];
+extern const struct xlat open_access_modes[];
+extern const struct xlat open_mode_flags[];
+extern const struct xlat resource_flags[];
+extern const struct xlat socketlayers[];
+extern const struct xlat whence_codes[];
+
+/* Format of syscall return values */
+#define RVAL_DECIMAL	000	/* decimal format */
+#define RVAL_HEX	001	/* hex format */
+#define RVAL_OCTAL	002	/* octal format */
+#define RVAL_UDECIMAL	003	/* unsigned decimal format */
+#if HAVE_STRUCT_TCB_EXT_ARG
+# if 0 /* unused so far */
+#  define RVAL_LDECIMAL	004	/* long decimal format */
+#  define RVAL_LHEX	005	/* long hex format */
+#  define RVAL_LOCTAL	006	/* long octal format */
+# endif
+# define RVAL_LUDECIMAL	007	/* long unsigned decimal format */
+#endif /* HAVE_STRUCT_TCB_EXT_ARG */
+#define RVAL_FD		010	/* file descriptor */
+#define RVAL_MASK	017	/* mask for these values */
+
+#define RVAL_STR	020	/* Print `auxstr' field after return val */
+#define RVAL_NONE	040	/* Print nothing */
+
+#define RVAL_DECODED	0100	/* syscall decoding finished */
+
+#define TRACE_FILE	001	/* Trace file-related syscalls. */
+#define TRACE_IPC	002	/* Trace IPC-related syscalls. */
+#define TRACE_NETWORK	004	/* Trace network-related syscalls. */
+#define TRACE_PROCESS	010	/* Trace process-related syscalls. */
+#define TRACE_SIGNAL	020	/* Trace signal-related syscalls. */
+#define TRACE_DESC	040	/* Trace file descriptor-related syscalls. */
+#define TRACE_MEMORY	0100	/* Trace memory mapping-related syscalls. */
+#define SYSCALL_NEVER_FAILS	0200	/* Syscall is always successful. */
+#define STACKTRACE_INVALIDATE_CACHE 0400  /* Trigger proc/maps cache updating */
+#define STACKTRACE_CAPTURE_ON_ENTER 01000 /* Capture stacktrace on "entering" stage */
+#define TRACE_INDIRECT_SUBCALL	02000	/* Syscall is an indirect socket/ipc subcall. */
+
+#define IOCTL_NUMBER_UNKNOWN 0
+#define IOCTL_NUMBER_HANDLED 1
+#define IOCTL_NUMBER_STOP_LOOKUP 010
+
+#define indirect_ipccall(tcp) (tcp->s_ent->sys_flags & TRACE_INDIRECT_SUBCALL)
+
+#if defined(ARM) || defined(AARCH64) \
+ || defined(I386) || defined(X32) || defined(X86_64) \
+ || defined(IA64) \
+ || defined(BFIN) \
+ || defined(M68K) \
+ || defined(MICROBLAZE) \
+ || defined(S390) \
+ || defined(SH) || defined(SH64) \
+ || defined(SPARC) || defined(SPARC64) \
+ /**/
+# define NEED_UID16_PARSERS 1
+#else
+# define NEED_UID16_PARSERS 0
+#endif
+
+enum sock_proto {
+	SOCK_PROTO_UNKNOWN,
+	SOCK_PROTO_UNIX,
+	SOCK_PROTO_TCP,
+	SOCK_PROTO_UDP,
+	SOCK_PROTO_TCPv6,
+	SOCK_PROTO_UDPv6,
+	SOCK_PROTO_NETLINK
+};
+extern enum sock_proto get_proto_by_name(const char *);
+
+enum iov_decode {
+	IOV_DECODE_ADDR,
+	IOV_DECODE_STR,
+	IOV_DECODE_NETLINK
+};
+
+typedef enum {
+	CFLAG_NONE = 0,
+	CFLAG_ONLY_STATS,
+	CFLAG_BOTH
+} cflag_t;
+extern cflag_t cflag;
+extern bool debug_flag;
+extern bool Tflag;
+extern bool iflag;
+extern bool count_wallclock;
+extern unsigned int qflag;
+extern bool not_failing_only;
+extern unsigned int show_fd_path;
+extern bool hide_log_until_execve;
+/* are we filtering traces based on paths? */
+extern const char **paths_selected;
+#define tracing_paths (paths_selected != NULL)
+extern unsigned xflag;
+extern unsigned followfork;
+#ifdef USE_LIBUNWIND
+/* if this is true do the stack trace for every system call */
+extern bool stack_trace_enabled;
+#endif
+extern unsigned ptrace_setoptions;
+extern unsigned max_strlen;
+extern unsigned os_release;
+#undef KERNEL_VERSION
+#define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))
+
+void error_msg(const char *fmt, ...) ATTRIBUTE_FORMAT((printf, 1, 2));
+void perror_msg(const char *fmt, ...) ATTRIBUTE_FORMAT((printf, 1, 2));
+void error_msg_and_die(const char *fmt, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+void error_msg_and_help(const char *fmt, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+void perror_msg_and_die(const char *fmt, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+void die_out_of_memory(void) ATTRIBUTE_NORETURN;
+
+void *xmalloc(size_t size) ATTRIBUTE_MALLOC ATTRIBUTE_ALLOC_SIZE((1));
+void *xcalloc(size_t nmemb, size_t size)
+	ATTRIBUTE_MALLOC ATTRIBUTE_ALLOC_SIZE((1, 2));
+void *xreallocarray(void *ptr, size_t nmemb, size_t size)
+	ATTRIBUTE_ALLOC_SIZE((2, 3));
+char *xstrdup(const char *str) ATTRIBUTE_MALLOC;
+
+#if USE_CUSTOM_PRINTF
+/*
+ * See comment in vsprintf.c for allowed formats.
+ * Short version: %h[h]u, %zu, %tu are not allowed, use %[l[l]]u.
+ */
+int strace_vfprintf(FILE *fp, const char *fmt, va_list args);
+#else
+# define strace_vfprintf vfprintf
+#endif
+
+extern int read_int_from_file(const char *, int *);
+
+extern void set_sortby(const char *);
+extern void set_overhead(int);
+extern void qualify(const char *);
+extern void print_pc(struct tcb *);
+extern int trace_syscall(struct tcb *);
+extern void count_syscall(struct tcb *, const struct timeval *);
+extern void call_summary(FILE *);
+
+extern void clear_regs(void);
+extern void get_regs(pid_t pid);
+extern int get_scno(struct tcb *tcp);
+extern const char *syscall_name(long scno);
+
+extern bool is_erestart(struct tcb *);
+extern void temporarily_clear_syserror(struct tcb *);
+extern void restore_cleared_syserror(struct tcb *);
+
+extern void *get_tcb_priv_data(const struct tcb *);
+extern int set_tcb_priv_data(struct tcb *, void *priv_data,
+			     void (*free_priv_data)(void *));
+extern void free_tcb_priv_data(struct tcb *);
+
+static inline unsigned long get_tcb_priv_ulong(const struct tcb *tcp)
+{
+	return (unsigned long) get_tcb_priv_data(tcp);
+}
+
+static inline int set_tcb_priv_ulong(struct tcb *tcp, unsigned long val)
+{
+	return set_tcb_priv_data(tcp, (void *) val, 0);
+}
+
+extern int umoven(struct tcb *, long, unsigned int, void *);
+#define umove(pid, addr, objp)	\
+	umoven((pid), (addr), sizeof(*(objp)), (void *) (objp))
+extern int umoven_or_printaddr(struct tcb *, long, unsigned int, void *);
+#define umove_or_printaddr(pid, addr, objp)	\
+	umoven_or_printaddr((pid), (addr), sizeof(*(objp)), (void *) (objp))
+extern int umovestr(struct tcb *, long, unsigned int, char *);
+extern int upeek(int pid, long, long *);
+
+extern bool
+print_array(struct tcb *tcp,
+	    const unsigned long start_addr,
+	    const size_t nmemb,
+	    void *const elem_buf,
+	    const size_t elem_size,
+	    int (*const umoven_func)(struct tcb *,
+				     long,
+				     unsigned int,
+				     void *),
+	    bool (*const print_func)(struct tcb *,
+				     void *elem_buf,
+				     size_t elem_size,
+				     void *opaque_data),
+	    void *const opaque_data);
+
+#if defined ALPHA || defined IA64 || defined MIPS \
+ || defined SH || defined SPARC || defined SPARC64
+# define HAVE_GETRVAL2
+extern long getrval2(struct tcb *);
+#else
+# undef HAVE_GETRVAL2
+#endif
+
+extern const char *signame(const int);
+extern void pathtrace_select(const char *);
+extern int pathtrace_match(struct tcb *);
+extern int getfdpath(struct tcb *, int, char *, unsigned);
+extern enum sock_proto getfdproto(struct tcb *, int);
+
+extern const char *xlookup(const struct xlat *, const uint64_t);
+extern const char *xlat_search(const struct xlat *, const size_t, const uint64_t);
+
+extern unsigned long get_pagesize(void);
+extern int string_to_uint(const char *str);
+extern int next_set_bit(const void *bit_array, unsigned cur_bit, unsigned size_bits);
+
+#define QUOTE_0_TERMINATED			0x01
+#define QUOTE_OMIT_LEADING_TRAILING_QUOTES	0x02
+
+extern int string_quote(const char *, char *, unsigned int, unsigned int);
+extern int print_quoted_string(const char *, unsigned int, unsigned int);
+
+/* a refers to the lower numbered u_arg,
+ * b refers to the higher numbered u_arg
+ */
+#ifdef WORDS_BIGENDIAN
+# define LONG_LONG(a,b) \
+	((long long)((unsigned long long)(unsigned)(b) | ((unsigned long long)(a)<<32)))
+#else
+# define LONG_LONG(a,b) \
+	((long long)((unsigned long long)(unsigned)(a) | ((unsigned long long)(b)<<32)))
+#endif
+extern int getllval(struct tcb *, unsigned long long *, int);
+extern int printllval(struct tcb *, const char *, int)
+	ATTRIBUTE_FORMAT((printf, 2, 0));
+
+extern void printaddr(long);
+extern void printxvals(const uint64_t, const char *, const struct xlat *, ...)
+	ATTRIBUTE_SENTINEL;
+extern int printargs(struct tcb *);
+extern int printargs_u(struct tcb *);
+extern int printargs_d(struct tcb *);
+
+extern void addflags(const struct xlat *, uint64_t);
+extern int printflags64(const struct xlat *, uint64_t, const char *);
+extern const char *sprintflags(const char *, const struct xlat *, uint64_t);
+extern const char *sprintmode(unsigned int);
+extern const char *sprinttime(time_t);
+extern void dumpiov_in_msghdr(struct tcb *, long, unsigned long);
+extern void dumpiov_in_mmsghdr(struct tcb *, long);
+extern void dumpiov_upto(struct tcb *, int, long, unsigned long);
+#define dumpiov(tcp, len, addr) \
+	dumpiov_upto((tcp), (len), (addr), (unsigned long) -1L)
+extern void dumpstr(struct tcb *, long, int);
+extern void printstr(struct tcb *, long, long);
+extern bool printnum_short(struct tcb *, long, const char *)
+	ATTRIBUTE_FORMAT((printf, 3, 0));
+extern bool printnum_int(struct tcb *, long, const char *)
+	ATTRIBUTE_FORMAT((printf, 3, 0));
+extern bool printnum_int64(struct tcb *, long, const char *)
+	ATTRIBUTE_FORMAT((printf, 3, 0));
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+extern bool printnum_long_int(struct tcb *, long, const char *, const char *)
+	ATTRIBUTE_FORMAT((printf, 3, 0))
+	ATTRIBUTE_FORMAT((printf, 4, 0));
+# define printnum_slong(tcp, addr) \
+	printnum_long_int((tcp), (addr), "%" PRId64, "%d")
+# define printnum_ulong(tcp, addr) \
+	printnum_long_int((tcp), (addr), "%" PRIu64, "%u")
+# define printnum_ptr(tcp, addr) \
+	printnum_long_int((tcp), (addr), "%#" PRIx64, "%#x")
+#elif SIZEOF_LONG > 4
+# define printnum_slong(tcp, addr) \
+	printnum_int64((tcp), (addr), "%" PRId64)
+# define printnum_ulong(tcp, addr) \
+	printnum_int64((tcp), (addr), "%" PRIu64)
+# define printnum_ptr(tcp, addr) \
+	printnum_int64((tcp), (addr), "%#" PRIx64)
+#else
+# define printnum_slong(tcp, addr) \
+	printnum_int((tcp), (addr), "%d")
+# define printnum_ulong(tcp, addr) \
+	printnum_int((tcp), (addr), "%u")
+# define printnum_ptr(tcp, addr) \
+	printnum_int((tcp), (addr), "%#x")
+#endif
+
+extern bool printpair_int(struct tcb *, long, const char *)
+	ATTRIBUTE_FORMAT((printf, 3, 0));
+extern bool printpair_int64(struct tcb *, long, const char *)
+	ATTRIBUTE_FORMAT((printf, 3, 0));
+extern void printpath(struct tcb *, long);
+extern void printpathn(struct tcb *, long, unsigned int);
+#define TIMESPEC_TEXT_BUFSIZE \
+		(sizeof(intmax_t)*3 * 2 + sizeof("{tv_sec=%jd, tv_nsec=%jd}"))
+extern void printfd(struct tcb *, int);
+extern void print_sockaddr(struct tcb *tcp, const void *, int);
+extern bool print_sockaddr_by_inode(const unsigned long, const enum sock_proto);
+extern bool print_sockaddr_by_inode_cached(const unsigned long);
+extern void print_dirfd(struct tcb *, int);
+extern int decode_sockaddr(struct tcb *, long, int);
+#ifdef ALPHA
+extern void printrusage32(struct tcb *, long);
+extern const char *sprint_timeval32(struct tcb *tcp, long);
+extern void print_timeval32(struct tcb *tcp, long);
+extern void print_timeval32_pair(struct tcb *tcp, long);
+extern void print_itimerval32(struct tcb *tcp, long);
+#endif
+extern void printuid(const char *, const unsigned int);
+extern void print_sigset_addr_len(struct tcb *, long, long);
+extern const char *sprintsigmask_n(const char *, const void *, unsigned int);
+#define tprintsigmask_addr(prefix, mask) \
+	tprints(sprintsigmask_n((prefix), (mask), sizeof(mask)))
+extern void printsignal(int);
+extern void tprint_iov(struct tcb *, unsigned long, unsigned long, enum iov_decode);
+extern void tprint_iov_upto(struct tcb *, unsigned long, unsigned long,
+			    enum iov_decode, unsigned long);
+extern void decode_netlink(struct tcb *, unsigned long, unsigned long);
+extern void tprint_open_modes(unsigned int);
+extern const char *sprint_open_modes(unsigned int);
+extern void print_seccomp_filter(struct tcb *, unsigned long);
+extern void print_seccomp_fprog(struct tcb *, unsigned long, unsigned short);
+
+struct strace_statfs;
+extern void print_struct_statfs(struct tcb *tcp, long);
+extern void print_struct_statfs64(struct tcb *tcp, long, unsigned long);
+
+extern void print_ifindex(unsigned int);
+
+extern int file_ioctl(struct tcb *, const unsigned int, long);
+extern int fs_x_ioctl(struct tcb *, const unsigned int, long);
+extern int loop_ioctl(struct tcb *, const unsigned int, long);
+extern int ptp_ioctl(struct tcb *, const unsigned int, long);
+extern int scsi_ioctl(struct tcb *, const unsigned int, long);
+extern int sock_ioctl(struct tcb *, const unsigned int, long);
+extern int term_ioctl(struct tcb *, const unsigned int, long);
+extern int ubi_ioctl(struct tcb *, const unsigned int, long);
+extern int uffdio_ioctl(struct tcb *, const unsigned int, long);
+
+extern int tv_nz(const struct timeval *);
+extern int tv_cmp(const struct timeval *, const struct timeval *);
+extern double tv_float(const struct timeval *);
+extern void tv_add(struct timeval *, const struct timeval *, const struct timeval *);
+extern void tv_sub(struct timeval *, const struct timeval *, const struct timeval *);
+extern void tv_mul(struct timeval *, const struct timeval *, int);
+extern void tv_div(struct timeval *, const struct timeval *, int);
+
+#ifdef USE_LIBUNWIND
+extern void unwind_init(void);
+extern void unwind_tcb_init(struct tcb *tcp);
+extern void unwind_tcb_fin(struct tcb *tcp);
+extern void unwind_cache_invalidate(struct tcb* tcp);
+extern void unwind_print_stacktrace(struct tcb* tcp);
+extern void unwind_capture_stacktrace(struct tcb* tcp);
+#endif
+
+static inline int
+printflags(const struct xlat *x, unsigned int flags, const char *dflt)
+{
+	return printflags64(x, flags, dflt);
+}
+
+static inline int
+printflags_long(const struct xlat *x, unsigned long flags, const char *dflt)
+{
+	return printflags64(x, flags, dflt);
+}
+
+static inline void
+printxval64(const struct xlat *x, const uint64_t val, const char *dflt)
+{
+	printxvals(val, dflt, x, NULL);
+}
+
+static inline void
+printxval(const struct xlat *x, const unsigned int val, const char *dflt)
+{
+	printxvals(val, dflt, x, NULL);
+}
+
+static inline void
+printxval_long(const struct xlat *x, const unsigned long val, const char *dflt)
+{
+	printxvals(val, dflt, x, NULL);
+}
+
+/* Strace log generation machinery.
+ *
+ * printing_tcp: tcb which has incomplete line being printed right now.
+ * NULL if last line has been completed ('\n'-terminated).
+ * printleader(tcp) examines it, finishes incomplete line if needed,
+ * the sets it to tcp.
+ * line_ended() clears printing_tcp and resets ->curcol = 0.
+ * tcp->curcol == 0 check is also used to detect completeness
+ * of last line, since in -ff mode just checking printing_tcp for NULL
+ * is not enough.
+ *
+ * If you change this code, test log generation in both -f and -ff modes
+ * using:
+ * strace -oLOG -f[f] test/threaded_execve
+ * strace -oLOG -f[f] test/sigkill_rain
+ * strace -oLOG -f[f] -p "`pidof web_browser`"
+ */
+extern struct tcb *printing_tcp;
+extern void printleader(struct tcb *);
+extern void line_ended(void);
+extern void tabto(void);
+extern void tprintf(const char *fmt, ...) ATTRIBUTE_FORMAT((printf, 1, 2));
+extern void tprints(const char *str);
+
+#if SUPPORTED_PERSONALITIES > 1
+extern void set_personality(int personality);
+extern unsigned current_personality;
+#else
+# define set_personality(personality) ((void)0)
+# define current_personality 0
+#endif
+
+#if SUPPORTED_PERSONALITIES == 1
+# define current_wordsize PERSONALITY0_WORDSIZE
+#else
+# if SUPPORTED_PERSONALITIES == 2 && PERSONALITY0_WORDSIZE == PERSONALITY1_WORDSIZE
+#  define current_wordsize PERSONALITY0_WORDSIZE
+# else
+extern unsigned current_wordsize;
+# endif
+#endif
+
+/* In many, many places we play fast and loose and use
+ * tprintf("%d", (int) tcp->u_arg[N]) to print fds, pids etc.
+ * We probably need to use widen_to_long() instead:
+ */
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+# define widen_to_long(v) (current_wordsize == 4 ? (long)(int32_t)(v) : (long)(v))
+#else
+# define widen_to_long(v) ((long)(v))
+#endif
+
+/*
+ * Widen without sign-extension a signed integer type to unsigned long long.
+ */
+#define widen_to_ull(v) \
+	(sizeof(v) == sizeof(int) ? (unsigned long long) (unsigned int) (v) : \
+	 sizeof(v) == sizeof(long) ? (unsigned long long) (unsigned long) (v) : \
+	 (unsigned long long) (v))
+
+extern const struct_sysent sysent0[];
+extern const char *const errnoent0[];
+extern const char *const signalent0[];
+extern const struct_ioctlent ioctlent0[];
+extern qualbits_t *qual_vec[SUPPORTED_PERSONALITIES];
+#define qual_flags (qual_vec[current_personality])
+
+#if SUPPORTED_PERSONALITIES > 1
+extern const struct_sysent *sysent;
+extern const char *const *errnoent;
+extern const char *const *signalent;
+extern const struct_ioctlent *ioctlent;
+#else
+# define sysent     sysent0
+# define errnoent   errnoent0
+# define signalent  signalent0
+# define ioctlent   ioctlent0
+#endif
+
+extern unsigned nsyscalls;
+extern unsigned nerrnos;
+extern unsigned nsignals;
+extern unsigned nioctlents;
+extern unsigned num_quals;
+
+#ifdef IN_MPERS_BOOTSTRAP
+/* Transform multi-line MPERS_PRINTER_DECL statements to one-liners.  */
+# define MPERS_PRINTER_DECL(type, name, ...) MPERS_PRINTER_DECL(type, name, __VA_ARGS__)
+#else /* !IN_MPERS_BOOTSTRAP */
+# if SUPPORTED_PERSONALITIES > 1
+#  include "printers.h"
+# else
+#  include "native_printer_decls.h"
+# endif
+# define MPERS_PRINTER_DECL(type, name, ...) type MPERS_FUNC_NAME(name)(__VA_ARGS__)
+#endif /* !IN_MPERS_BOOTSTRAP */
+
+/*
+ * If you need non-NULL sysent[scno].sys_func and sysent[scno].sys_name
+ */
+#define SCNO_IS_VALID(scno) \
+	((unsigned long)(scno) < nsyscalls && sysent[scno].sys_func)
+
+/* Only ensures that sysent[scno] isn't out of range */
+#define SCNO_IN_RANGE(scno) \
+	((unsigned long)(scno) < nsyscalls)
+
+#define MPERS_FUNC_NAME__(prefix, name) prefix ## name
+#define MPERS_FUNC_NAME_(prefix, name) MPERS_FUNC_NAME__(prefix, name)
+#define MPERS_FUNC_NAME(name) MPERS_FUNC_NAME_(MPERS_PREFIX, name)
+
+#define SYS_FUNC_NAME(syscall_name) MPERS_FUNC_NAME(syscall_name)
+
+#define SYS_FUNC(syscall_name) int SYS_FUNC_NAME(sys_ ## syscall_name)(struct tcb *tcp)
+
+/*
+ * The kernel used to define 64-bit types on 64-bit systems on a per-arch
+ * basis.  Some architectures would use unsigned long and others would use
+ * unsigned long long.  These types were exported as part of the
+ * kernel-userspace ABI and now must be maintained forever.  This matches
+ * what the kernel exports for each architecture so we don't need to cast
+ * every printing of __u64 or __s64 to stdint types.
+ */
+#if SIZEOF_LONG == 4
+# define PRI__64 "ll"
+#elif defined ALPHA || defined IA64 || defined MIPS || defined POWERPC
+# define PRI__64 "l"
+#else
+# define PRI__64 "ll"
+#endif
+
+#define PRI__d64 PRI__64"d"
+#define PRI__u64 PRI__64"u"
+#define PRI__x64 PRI__64"x"
diff --git a/strace/desc.c b/strace/desc.c
new file mode 100644
index 0000000..4695db5
--- /dev/null
+++ b/strace/desc.c
@@ -0,0 +1,271 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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"
+
+SYS_FUNC(close)
+{
+	printfd(tcp, tcp->u_arg[0]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(dup)
+{
+	printfd(tcp, tcp->u_arg[0]);
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+static int
+do_dup2(struct tcb *tcp, int flags_arg)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printfd(tcp, tcp->u_arg[1]);
+	if (flags_arg >= 0) {
+		tprints(", ");
+		printflags(open_mode_flags, tcp->u_arg[flags_arg], "O_???");
+	}
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(dup2)
+{
+	return do_dup2(tcp, -1);
+}
+
+SYS_FUNC(dup3)
+{
+	return do_dup2(tcp, 2);
+}
+
+static int
+decode_select(struct tcb *tcp, long *args,
+	      void (*print_tv_ts) (struct tcb *, const long),
+	      const char * (*sprint_tv_ts) (struct tcb *, const long))
+{
+	int i, j;
+	int nfds, fdsize;
+	fd_set *fds = NULL;
+	const char *sep;
+	long arg;
+
+	/* Kernel truncates arg[0] to int, we do the same. */
+	nfds = (int) args[0];
+
+	/* Kernel rejects negative nfds, so we don't parse it either. */
+	if (nfds < 0)
+		nfds = 0;
+
+	/* Beware of select(2^31-1, NULL, NULL, NULL) and similar... */
+	if (nfds > 1024*1024)
+		nfds = 1024*1024;
+
+	/*
+	 * We had bugs a-la "while (j < args[0])" and "umoven(args[0])" below.
+	 * Instead of args[0], use nfds for fd count, fdsize for array lengths.
+	 */
+	fdsize = (((nfds + 7) / 8) + current_wordsize-1) & -current_wordsize;
+
+	if (entering(tcp)) {
+		tprintf("%d", (int) args[0]);
+
+		if (verbose(tcp) && fdsize > 0)
+			fds = malloc(fdsize);
+		for (i = 0; i < 3; i++) {
+			arg = args[i+1];
+			tprints(", ");
+			if (!fds) {
+				printaddr(arg);
+				continue;
+			}
+			if (umoven_or_printaddr(tcp, arg, fdsize, fds))
+				continue;
+			tprints("[");
+			for (j = 0, sep = "";; j++) {
+				j = next_set_bit(fds, j, nfds);
+				if (j < 0)
+					break;
+				tprints(sep);
+				printfd(tcp, j);
+				sep = " ";
+			}
+			tprints("]");
+		}
+		free(fds);
+		tprints(", ");
+		print_tv_ts(tcp, args[4]);
+	} else {
+		static char outstr[1024];
+		char *outptr;
+#define end_outstr (outstr + sizeof(outstr))
+		int ready_fds;
+
+		if (syserror(tcp))
+			return 0;
+
+		ready_fds = tcp->u_rval;
+		if (ready_fds == 0) {
+			tcp->auxstr = "Timeout";
+			return RVAL_STR;
+		}
+
+		fds = malloc(fdsize);
+
+		outptr = outstr;
+		sep = "";
+		for (i = 0; i < 3 && ready_fds > 0; i++) {
+			int first = 1;
+
+			arg = args[i+1];
+			if (!arg || !fds || umoven(tcp, arg, fdsize, fds) < 0)
+				continue;
+			for (j = 0;; j++) {
+				j = next_set_bit(fds, j, nfds);
+				if (j < 0)
+					break;
+				/* +2 chars needed at the end: ']',NUL */
+				if (outptr < end_outstr - (sizeof(", except [") + sizeof(int)*3 + 2)) {
+					if (first) {
+						outptr += sprintf(outptr, "%s%s [%u",
+							sep,
+							i == 0 ? "in" : i == 1 ? "out" : "except",
+							j
+						);
+						first = 0;
+						sep = ", ";
+					}
+					else {
+						outptr += sprintf(outptr, " %u", j);
+					}
+				}
+				if (--ready_fds == 0)
+					break;
+			}
+			if (outptr != outstr)
+				*outptr++ = ']';
+		}
+		free(fds);
+		/* This contains no useful information on SunOS.  */
+		if (args[4]) {
+			const char *str = sprint_tv_ts(tcp, args[4]);
+			if (outptr + sizeof("left ") + strlen(sep) + strlen(str) < end_outstr) {
+				outptr += sprintf(outptr, "%sleft %s", sep, str);
+			}
+		}
+		*outptr = '\0';
+		tcp->auxstr = outstr;
+		return RVAL_STR;
+#undef end_outstr
+	}
+	return 0;
+}
+
+SYS_FUNC(oldselect)
+{
+	long long_args[5];
+#undef oldselect_args
+#if SIZEOF_LONG == 4
+# define oldselect_args long_args
+#else
+	unsigned int oldselect_args[5];
+	unsigned int i;
+#endif
+
+	if (umove(tcp, tcp->u_arg[0], &oldselect_args) < 0) {
+		printaddr(tcp->u_arg[0]);
+		return 0;
+	}
+#ifndef oldselect_args
+	for (i = 0; i < 5; i++) {
+		long_args[i] = oldselect_args[i];
+	}
+#endif
+	return decode_select(tcp, long_args, print_timeval, sprint_timeval);
+#undef oldselect_args
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_select)
+{
+	return decode_select(tcp, tcp->u_arg, print_timeval32, sprint_timeval32);
+}
+#endif
+
+SYS_FUNC(select)
+{
+	return decode_select(tcp, tcp->u_arg, print_timeval, sprint_timeval);
+}
+
+#include "kernel_types.h"
+
+static int
+umove_kulong_array_or_printaddr(struct tcb *tcp, const long addr,
+				kernel_ulong_t *ptr, size_t n)
+{
+#if defined X86_64 || defined X32
+	if (current_personality == 1) {
+#else
+	if (current_wordsize < sizeof(*ptr)) {
+#endif
+		uint32_t ptr32[n];
+		int r = umove_or_printaddr(tcp, addr, &ptr32);
+		if (!r) {
+			size_t i;
+
+			for (i = 0; i < n; ++i)
+				ptr[i] = (kernel_ulong_t) ptr32[i];
+		}
+		return r;
+	}
+	return umoven_or_printaddr(tcp, addr, n * sizeof(*ptr), ptr);
+}
+
+SYS_FUNC(pselect6)
+{
+	int rc = decode_select(tcp, tcp->u_arg, print_timespec, sprint_timespec);
+	if (entering(tcp)) {
+		kernel_ulong_t data[2];
+
+		tprints(", ");
+		if (!umove_kulong_array_or_printaddr(tcp, tcp->u_arg[5],
+						     data, ARRAY_SIZE(data))) {
+			tprints("{");
+			/* NB: kernel requires data[1] == NSIG / 8 */
+			print_sigset_addr_len(tcp, (unsigned long) data[0],
+					      (unsigned long) data[1]);
+			tprintf(", %llu}", (unsigned long long) data[1]);
+		}
+	}
+
+	return rc;
+}
diff --git a/strace/dirent.c b/strace/dirent.c
new file mode 100644
index 0000000..75e3635
--- /dev/null
+++ b/strace/dirent.c
@@ -0,0 +1,159 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(kernel_dirent)
+
+#include "kernel_types.h"
+
+#include MPERS_DEFS
+
+#define D_NAME_LEN_MAX 256
+
+static void
+print_old_dirent(struct tcb *tcp, long addr)
+{
+	kernel_dirent d;
+
+	if (umove_or_printaddr(tcp, addr, &d))
+		return;
+
+	tprintf("{d_ino=%llu, d_off=%llu, d_reclen=%u, d_name=",
+		widen_to_ull(d.d_ino),
+		widen_to_ull(d.d_off), d.d_reclen);
+	if (d.d_reclen > D_NAME_LEN_MAX)
+		d.d_reclen = D_NAME_LEN_MAX;
+	printpathn(tcp, addr + offsetof(kernel_dirent, d_name), d.d_reclen);
+	tprints("}");
+}
+
+SYS_FUNC(readdir)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		if (tcp->u_rval == 0)
+			printaddr(tcp->u_arg[1]);
+		else
+			print_old_dirent(tcp, tcp->u_arg[1]);
+		/* Not much point in printing this out, it is always 1. */
+		if (tcp->u_arg[2] != 1)
+			tprintf(", %lu", tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(getdents)
+{
+	unsigned int i, len, dents = 0;
+	unsigned char *buf;
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		return 0;
+	}
+
+	const unsigned int count = tcp->u_arg[2];
+
+	if (syserror(tcp) || !verbose(tcp)) {
+		printaddr(tcp->u_arg[1]);
+		tprintf(", %u", count);
+		return 0;
+	}
+
+	/* Beware of insanely large or too small values in tcp->u_rval */
+	if (tcp->u_rval > 1024*1024)
+		len = 1024*1024;
+	else if (tcp->u_rval < (int) sizeof(kernel_dirent))
+		len = 0;
+	else
+		len = tcp->u_rval;
+
+	if (len) {
+		buf = malloc(len);
+		if (!buf || umoven(tcp, tcp->u_arg[1], len, buf) < 0) {
+			printaddr(tcp->u_arg[1]);
+			tprintf(", %u", count);
+			free(buf);
+			return 0;
+		}
+	} else {
+		buf = NULL;
+	}
+
+	if (!abbrev(tcp))
+		tprints("[");
+	for (i = 0; len && i <= len - sizeof(kernel_dirent); ) {
+		kernel_dirent *d = (kernel_dirent *) &buf[i];
+
+		if (!abbrev(tcp)) {
+			int oob = d->d_reclen < sizeof(kernel_dirent) ||
+				  i + d->d_reclen - 1 >= len;
+			int d_name_len = oob ? len - i : d->d_reclen;
+			d_name_len -= offsetof(kernel_dirent, d_name) + 1;
+			if (d_name_len > D_NAME_LEN_MAX)
+				d_name_len = D_NAME_LEN_MAX;
+
+			tprintf("%s{d_ino=%llu, d_off=%llu, d_reclen=%u"
+				", d_name=", i ? ", " : "",
+				widen_to_ull(d->d_ino),
+				widen_to_ull(d->d_off), d->d_reclen);
+
+			if (print_quoted_string(d->d_name, d_name_len,
+					        QUOTE_0_TERMINATED) > 0) {
+				tprints("...");
+			}
+
+			tprints(", d_type=");
+			if (oob)
+				tprints("?");
+			else
+				printxval(dirent_types, buf[i + d->d_reclen - 1], "DT_???");
+			tprints("}");
+		}
+		dents++;
+		if (d->d_reclen < sizeof(kernel_dirent)) {
+			tprints("/* d_reclen < sizeof(struct dirent) */");
+			break;
+		}
+		i += d->d_reclen;
+	}
+	if (!abbrev(tcp))
+		tprints("]");
+	else
+		tprintf("/* %u entries */", dents);
+	tprintf(", %u", count);
+	free(buf);
+	return 0;
+}
diff --git a/strace/dirent64.c b/strace/dirent64.c
new file mode 100644
index 0000000..448a2f1
--- /dev/null
+++ b/strace/dirent64.c
@@ -0,0 +1,126 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <dirent.h>
+
+#include "xlat/dirent_types.h"
+
+#define D_NAME_LEN_MAX 256
+
+SYS_FUNC(getdents64)
+{
+	/* the minimum size of a valid dirent64 structure */
+	const unsigned int d_name_offset = offsetof(struct dirent64, d_name);
+
+	unsigned int i, len, dents = 0;
+	char *buf;
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		return 0;
+	}
+
+	const unsigned int count = tcp->u_arg[2];
+
+	if (syserror(tcp) || !verbose(tcp)) {
+		printaddr(tcp->u_arg[1]);
+		tprintf(", %u", count);
+		return 0;
+	}
+
+	/* Beware of insanely large or too small values in tcp->u_rval */
+	if (tcp->u_rval > 1024*1024)
+		len = 1024*1024;
+	else if (tcp->u_rval < (int) d_name_offset)
+		len = 0;
+	else
+		len = tcp->u_rval;
+
+	if (len) {
+		buf = malloc(len);
+		if (!buf || umoven(tcp, tcp->u_arg[1], len, buf) < 0) {
+			printaddr(tcp->u_arg[1]);
+			tprintf(", %u", count);
+			free(buf);
+			return 0;
+		}
+	} else {
+		buf = NULL;
+	}
+
+	if (!abbrev(tcp))
+		tprints("[");
+	for (i = 0; len && i <= len - d_name_offset; ) {
+		struct dirent64 *d = (struct dirent64 *) &buf[i];
+		if (!abbrev(tcp)) {
+			int d_name_len;
+			if (d->d_reclen >= d_name_offset
+			    && i + d->d_reclen <= len) {
+				d_name_len = d->d_reclen - d_name_offset;
+			} else {
+				d_name_len = len - i - d_name_offset;
+			}
+			if (d_name_len > D_NAME_LEN_MAX)
+				d_name_len = D_NAME_LEN_MAX;
+
+			tprintf("%s{d_ino=%" PRIu64 ", d_off=%" PRId64
+				", d_reclen=%u, d_type=",
+				i ? ", " : "",
+				d->d_ino,
+				d->d_off,
+				d->d_reclen);
+			printxval(dirent_types, d->d_type, "DT_???");
+
+			tprints(", d_name=");
+			if (print_quoted_string(d->d_name, d_name_len,
+					        QUOTE_0_TERMINATED) > 0) {
+				tprints("...");
+			}
+
+			tprints("}");
+		}
+		if (d->d_reclen < d_name_offset) {
+			tprints("/* d_reclen < offsetof(struct dirent64, d_name) */");
+			break;
+		}
+		i += d->d_reclen;
+		dents++;
+	}
+	if (!abbrev(tcp))
+		tprints("]");
+	else
+		tprintf("/* %u entries */", dents);
+	tprintf(", %u", count);
+	free(buf);
+	return 0;
+}
diff --git a/strace/empty.h b/strace/empty.h
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/strace/empty.h
diff --git a/strace/epoll.c b/strace/epoll.c
new file mode 100644
index 0000000..7382e0c
--- /dev/null
+++ b/strace/epoll.c
@@ -0,0 +1,117 @@
+/*
+ * Copyright (c) 2004-2007 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+#include <sys/epoll.h>
+
+SYS_FUNC(epoll_create)
+{
+	tprintf("%d", (int) tcp->u_arg[0]);
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+#include "xlat/epollflags.h"
+
+SYS_FUNC(epoll_create1)
+{
+	printflags(epollflags, tcp->u_arg[0], "EPOLL_???");
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+#include "xlat/epollevents.h"
+
+static bool
+print_epoll_event(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const struct epoll_event *ev = elem_buf;
+
+	tprints("{");
+	printflags(epollevents, ev->events, "EPOLL???");
+	/* We cannot know what format the program uses, so print u32 and u64
+	   which will cover every value.  */
+	tprintf(", {u32=%" PRIu32 ", u64=%" PRIu64 "}}",
+		ev->data.u32, ev->data.u64);
+
+	return true;
+}
+
+#include "xlat/epollctls.h"
+
+SYS_FUNC(epoll_ctl)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	const unsigned int op = tcp->u_arg[1];
+	printxval(epollctls, op, "EPOLL_CTL_???");
+	tprints(", ");
+	printfd(tcp, tcp->u_arg[2]);
+	tprints(", ");
+	struct epoll_event ev;
+	if (EPOLL_CTL_DEL == op)
+		printaddr(tcp->u_arg[3]);
+	else if (!umove_or_printaddr(tcp, tcp->u_arg[3], &ev))
+		print_epoll_event(tcp, &ev, sizeof(ev), 0);
+
+	return RVAL_DECODED;
+}
+
+static void
+epoll_wait_common(struct tcb *tcp)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		struct epoll_event ev;
+		print_array(tcp, tcp->u_arg[1], tcp->u_rval, &ev, sizeof(ev),
+			    umoven_or_printaddr, print_epoll_event, 0);
+		tprintf(", %d, %d", (int) tcp->u_arg[2], (int) tcp->u_arg[3]);
+	}
+}
+
+SYS_FUNC(epoll_wait)
+{
+	epoll_wait_common(tcp);
+	return 0;
+}
+
+SYS_FUNC(epoll_pwait)
+{
+	epoll_wait_common(tcp);
+	if (exiting(tcp)) {
+		tprints(", ");
+		/* NB: kernel requires arg[5] == NSIG / 8 */
+		print_sigset_addr_len(tcp, tcp->u_arg[4], tcp->u_arg[5]);
+		tprintf(", %lu", tcp->u_arg[5]);
+	}
+	return 0;
+}
diff --git a/strace/errnoent.sh b/strace/errnoent.sh
new file mode 100755
index 0000000..0b1b06a
--- /dev/null
+++ b/strace/errnoent.sh
@@ -0,0 +1,38 @@
+#!/bin/sh
+# Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+# 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.
+
+awk '
+$1 == "#define" && $2 ~ /^E[A-Z0-9_]+$/ && $3 ~ /^[0-9]+$/ {
+	errno[$3] = $2
+	if ($3 > max)
+		max = $3
+}
+END {
+	for (i = 0; i <= max; i++)
+		if (errno[i])
+			printf("[%3d] = \"%s\",\n", i, errno[i])
+}
+' "$@"
diff --git a/strace/evdev.c b/strace/evdev.c
new file mode 100644
index 0000000..b7b6402
--- /dev/null
+++ b/strace/evdev.c
@@ -0,0 +1,527 @@
+/*
+ * Copyright (c) 2015 Etienne Gemsa <etienne.gemsa@lse.epita.fr>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_LINUX_INPUT_H
+
+#include DEF_MPERS_TYPE(struct_ff_effect)
+
+# include <linux/ioctl.h>
+# include <linux/input.h>
+
+typedef struct ff_effect struct_ff_effect;
+
+#endif /* HAVE_LINUX_BTRFS_H */
+
+#include MPERS_DEFS
+
+#ifdef HAVE_LINUX_INPUT_H
+
+# include "xlat/evdev_autorepeat.h"
+# include "xlat/evdev_ff_status.h"
+# include "xlat/evdev_ff_types.h"
+# include "xlat/evdev_keycode.h"
+# include "xlat/evdev_leds.h"
+# include "xlat/evdev_misc.h"
+# include "xlat/evdev_mtslots.h"
+# include "xlat/evdev_prop.h"
+# 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
+# endif
+
+static void
+decode_envelope(void *const data)
+{
+	const struct ff_envelope *const envelope = data;
+
+	tprintf(", envelope={attack_length=%" PRIu16
+		", attack_level=%" PRIu16
+		", fade_length=%" PRIu16
+		", fade_level=%#x}",
+		envelope->attack_length,
+		envelope->attack_level,
+		envelope->fade_length,
+		envelope->fade_level);
+}
+
+static int
+ff_effect_ioctl(struct tcb *tcp, long arg)
+{
+	tprints(", ");
+
+	struct_ff_effect ffe;
+
+	if (umove_or_printaddr(tcp, arg, &ffe))
+		return 1;
+
+	tprints("{type=");
+	printxval(evdev_ff_types, ffe.type, "FF_???");
+	tprintf(", id=%" PRIu16
+		", direction=%" PRIu16 ", ",
+		ffe.id,
+		ffe.direction);
+
+	if (abbrev(tcp)) {
+		tprints("...}");
+		return 1;
+	}
+
+	tprintf("trigger={button=%" PRIu16
+		", interval=%" PRIu16 "}"
+		", replay={length=%" PRIu16
+		", delay=%" PRIu16 "}",
+		ffe.trigger.button,
+		ffe.trigger.interval,
+		ffe.replay.length,
+		ffe.replay.delay);
+
+	switch (ffe.type) {
+		case FF_CONSTANT:
+			tprintf(", constant={level=%" PRId16,
+				ffe.u.constant.level);
+			decode_envelope(&ffe.u.constant.envelope);
+			tprints("}");
+			break;
+		case FF_RAMP:
+			tprintf(", ramp={start_level=%" PRId16
+				", end_level=%" PRId16,
+				ffe.u.ramp.start_level,
+				ffe.u.ramp.end_level);
+			decode_envelope(&ffe.u.ramp.envelope);
+			tprints("}");
+			break;
+		case FF_PERIODIC:
+			tprintf(", periodic={waveform=%" PRIu16
+				", period=%" PRIu16
+				", magnitude=%" PRId16
+				", offset=%" PRId16
+				", phase=%" PRIu16,
+				ffe.u.periodic.waveform,
+				ffe.u.periodic.period,
+				ffe.u.periodic.magnitude,
+				ffe.u.periodic.offset,
+				ffe.u.periodic.phase);
+			decode_envelope(&ffe.u.periodic.envelope);
+			tprintf(", custom_len=%u, custom_data=",
+				ffe.u.periodic.custom_len);
+			printaddr((unsigned long) ffe.u.periodic.custom_data);
+			tprints("}");
+			break;
+		case FF_RUMBLE:
+			tprintf(", rumble={strong_magnitude=%" PRIu16
+				", weak_magnitude=%" PRIu16 "}",
+				ffe.u.rumble.strong_magnitude,
+				ffe.u.rumble.weak_magnitude);
+			break;
+		default:
+			break;
+	}
+
+	tprints("}");
+
+	return 1;
+}
+
+static int
+abs_ioctl(struct tcb *tcp, long arg)
+{
+	tprints(", ");
+
+	struct input_absinfo absinfo;
+
+	if (!umove_or_printaddr(tcp, arg, &absinfo)) {
+		tprintf("{value=%u"
+			", minimum=%u, ",
+			absinfo.value,
+			absinfo.minimum);
+
+		if (!abbrev(tcp)) {
+			tprintf("maximum=%u"
+				", fuzz=%u"
+				", flat=%u",
+				absinfo.maximum,
+				absinfo.fuzz,
+				absinfo.flat);
+# ifdef HAVE_STRUCT_INPUT_ABSINFO_RESOLUTION
+			tprintf(", resolution=%u",
+				absinfo.resolution);
+# endif
+		} else {
+			tprints("...");
+		}
+
+		tprints("}");
+	}
+
+	return 1;
+}
+
+static int
+keycode_ioctl(struct tcb *tcp, long arg)
+{
+	tprints(", ");
+
+	unsigned int keycode[2];
+
+	if (!umove_or_printaddr(tcp, arg, &keycode)) {
+		tprintf("[%u, ", keycode[0]);
+		printxval(evdev_keycode, keycode[1], "KEY_???");
+		tprints("]");
+	}
+
+	return 1;
+}
+
+# ifdef EVIOCGKEYCODE_V2
+static int
+keycode_V2_ioctl(struct tcb *tcp, long arg)
+{
+	tprints(", ");
+
+	struct input_keymap_entry ike;
+
+	if (umove_or_printaddr(tcp, arg, &ike))
+		return 1;
+
+	tprintf("{flags=%" PRIu8
+		", len=%" PRIu8 ", ",
+		ike.flags,
+		ike.len);
+
+	if (!abbrev(tcp)) {
+		unsigned int i;
+
+		tprintf("index=%" PRIu16 ", keycode=", ike.index);
+		printxval(evdev_keycode, ike.keycode, "KEY_???");
+		tprints(", scancode=[");
+		for (i = 0; i < ARRAY_SIZE(ike.scancode); i++) {
+			if (i > 0)
+				tprints(", ");
+			tprintf("%" PRIx8, ike.scancode[i]);
+		}
+		tprints("]");
+	} else {
+		tprints("...");
+	}
+
+	tprints("}");
+
+	return 1;
+}
+# endif /* EVIOCGKEYCODE_V2 */
+
+static int
+getid_ioctl(struct tcb *tcp, long arg)
+{
+	tprints(", ");
+
+	struct input_id id;
+
+	if (!umove_or_printaddr(tcp, arg, &id))
+		tprintf("{ID_BUS=%" PRIu16
+			", ID_VENDOR=%" PRIu16
+			", ID_PRODUCT=%" PRIu16
+			", ID_VERSION=%" PRIu16 "}",
+			id.bustype,
+			id.vendor,
+			id.product,
+			id.version);
+
+	return 1;
+}
+
+static int
+decode_bitset(struct tcb *tcp, long arg, const struct xlat decode_nr[],
+	      const unsigned int max_nr, const char *dflt)
+{
+	tprints(", ");
+
+	unsigned int size;
+	if ((unsigned long) tcp->u_rval > max_nr)
+		size = max_nr;
+	else
+		size = tcp->u_rval;
+	char decoded_arg[size];
+
+	if (umove_or_printaddr(tcp, arg, &decoded_arg))
+		return 1;
+
+	tprints("[");
+
+	int bit_displayed = 0;
+	int i = next_set_bit(decoded_arg, 0, size);
+	if (i < 0) {
+		tprints(" 0 ");
+	} else {
+		printxval(decode_nr, i, dflt);
+
+		while ((i = next_set_bit(decoded_arg, i + 1, size)) > 0) {
+			if (abbrev(tcp) && bit_displayed >= 3) {
+				tprints(", ...");
+				break;
+			}
+			tprints(", ");
+			printxval(decode_nr, i, dflt);
+			bit_displayed++;
+		}
+	}
+
+	tprints("]");
+
+	return 1;
+}
+
+# ifdef EVIOCGMTSLOTS
+static int
+mtslots_ioctl(struct tcb *tcp, const unsigned int code, long arg)
+{
+	tprints(", ");
+
+	const size_t size = _IOC_SIZE(code) / sizeof(int);
+	if (!size) {
+		printaddr(arg);
+		return 1;
+	}
+
+	int buffer[size];
+
+	if (umove_or_printaddr(tcp, arg, &buffer))
+		return 1;
+
+	tprints("{code=");
+	printxval(evdev_mtslots, buffer[0], "ABS_MT_???");
+
+	tprints(", values=[");
+
+	unsigned int i;
+	for (i = 1; i < ARRAY_SIZE(buffer); i++)
+		tprintf("%s%d", i > 1 ? ", " : "", buffer[i]);
+
+	tprints("]}");
+
+	return 1;
+}
+# endif /* EVIOCGMTSLOTS */
+
+# if defined EVIOCGREP || defined EVIOCSREP
+static int
+repeat_ioctl(struct tcb *tcp, long arg)
+{
+	tprints(", ");
+	printpair_int(tcp, arg, "%u");
+	return 1;
+}
+# endif /* EVIOCGREP || EVIOCSREP */
+
+static int
+bit_ioctl(struct tcb *tcp, const unsigned int ev_nr, const long arg)
+{
+	switch (ev_nr) {
+		case EV_SYN:
+			return decode_bitset(tcp, arg, evdev_sync,
+					     SYN_MAX, "SYN_???");
+		case EV_KEY:
+			return decode_bitset(tcp, arg, evdev_keycode,
+					     KEY_MAX, "KEY_???");
+		case EV_REL:
+			return decode_bitset(tcp, arg, evdev_relative_axes,
+					     REL_MAX, "REL_???");
+		case EV_ABS:
+			return decode_bitset(tcp, arg, evdev_abs,
+					     ABS_MAX, "ABS_???");
+		case EV_MSC:
+			return decode_bitset(tcp, arg, evdev_misc,
+					     MSC_MAX, "MSC_???");
+# ifdef EV_SW
+		case EV_SW:
+			return decode_bitset(tcp, arg, evdev_switch,
+					     SW_MAX, "SW_???");
+# endif
+		case EV_LED:
+			return decode_bitset(tcp, arg, evdev_leds,
+					     LED_MAX, "LED_???");
+		case EV_SND:
+			return decode_bitset(tcp, arg, evdev_snd,
+					     SND_MAX, "SND_???");
+		case EV_REP:
+			return decode_bitset(tcp, arg, evdev_autorepeat,
+					     REP_MAX, "REP_???");
+		case EV_FF:
+			return decode_bitset(tcp, arg, evdev_ff_types,
+					     FF_MAX, "FF_???");
+		case EV_PWR:
+			tprints(", ");
+			printnum_int(tcp, arg, "%d");
+			return 1;
+		case EV_FF_STATUS:
+			return decode_bitset(tcp, arg, evdev_ff_status,
+					     FF_STATUS_MAX, "FF_STATUS_???");
+		default:
+			tprints(", ");
+			printaddr(arg);
+			return 1;
+	}
+}
+
+static int
+evdev_read_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	/* fixed-number fixed-length commands */
+	switch (code) {
+		case EVIOCGVERSION:
+			tprints(", ");
+			printnum_int(tcp, arg, "%#x");
+			return 1;
+		case EVIOCGEFFECTS:
+			tprints(", ");
+			printnum_int(tcp, arg, "%u");
+			return 1;
+		case EVIOCGID:
+			return getid_ioctl(tcp, arg);
+# ifdef EVIOCGREP
+		case EVIOCGREP:
+			return repeat_ioctl(tcp, arg);
+# endif
+		case EVIOCGKEYCODE:
+			return keycode_ioctl(tcp, arg);
+# ifdef EVIOCGKEYCODE_V2
+		case EVIOCGKEYCODE_V2:
+			return keycode_V2_ioctl(tcp, arg);
+# endif
+	}
+
+	/* fixed-number variable-length commands */
+	switch (_IOC_NR(code)) {
+# ifdef EVIOCGMTSLOTS
+		case _IOC_NR(EVIOCGMTSLOTS(0)):
+			return mtslots_ioctl(tcp, code, arg);
+# endif
+		case _IOC_NR(EVIOCGNAME(0)):
+		case _IOC_NR(EVIOCGPHYS(0)):
+		case _IOC_NR(EVIOCGUNIQ(0)):
+			tprints(", ");
+			if (syserror(tcp))
+				printaddr(arg);
+			else
+				printstr(tcp, arg, tcp->u_rval);
+			return 1;
+# ifdef EVIOCGPROP
+		case _IOC_NR(EVIOCGPROP(0)):
+			return decode_bitset(tcp, arg, evdev_prop,
+					     INPUT_PROP_MAX, "PROP_???");
+# endif
+		case _IOC_NR(EVIOCGSND(0)):
+			return decode_bitset(tcp, arg, evdev_snd,
+					     SND_MAX, "SND_???");
+# ifdef EVIOCGSW
+		case _IOC_NR(EVIOCGSW(0)):
+			return decode_bitset(tcp, arg, evdev_switch,
+					     SW_MAX, "SW_???");
+# endif
+		case _IOC_NR(EVIOCGKEY(0)):
+			return decode_bitset(tcp, arg, evdev_keycode,
+					     KEY_MAX, "KEY_???");
+		case _IOC_NR(EVIOCGLED(0)):
+			return decode_bitset(tcp, arg, evdev_leds,
+					     LED_MAX, "LED_???");
+	}
+
+	/* multi-number fixed-length commands */
+	if ((_IOC_NR(code) & ~ABS_MAX) == _IOC_NR(EVIOCGABS(0)))
+		return abs_ioctl(tcp, arg);
+
+	/* multi-number variable-length commands */
+	if ((_IOC_NR(code) & ~EV_MAX) == _IOC_NR(EVIOCGBIT(0, 0)))
+		return bit_ioctl(tcp, _IOC_NR(code) & EV_MAX, arg);
+
+	return 0;
+}
+
+static int
+evdev_write_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	/* fixed-number fixed-length commands */
+	switch (code) {
+# ifdef EVIOCSREP
+		case EVIOCSREP:
+			return repeat_ioctl(tcp, arg);
+# endif
+		case EVIOCSKEYCODE:
+			return keycode_ioctl(tcp, arg);
+# ifdef EVIOCSKEYCODE_V2
+		case EVIOCSKEYCODE_V2:
+			return keycode_V2_ioctl(tcp, arg);
+# endif
+		case EVIOCSFF:
+			return ff_effect_ioctl(tcp, arg);
+		case EVIOCRMFF:
+			tprintf(", %d", (int) arg);
+			return 1;
+		case EVIOCGRAB:
+# ifdef EVIOCREVOKE
+		case EVIOCREVOKE:
+# endif
+			tprintf(", %lu", arg);
+			return 1;
+# ifdef EVIOCSCLOCKID
+		case EVIOCSCLOCKID:
+			tprints(", ");
+			printnum_int(tcp, arg, "%u");
+			return 1;
+# endif
+	}
+
+	/* multi-number fixed-length commands */
+	if ((_IOC_NR(code) & ~ABS_MAX) == _IOC_NR(EVIOCSABS(0)))
+		return abs_ioctl(tcp, arg);
+
+	return 0;
+}
+
+MPERS_PRINTER_DECL(int, evdev_ioctl, struct tcb *tcp,
+		   const unsigned int code, const long arg)
+{
+	switch(_IOC_DIR(code)) {
+		case _IOC_READ:
+			if (entering(tcp))
+				return 0;
+			return evdev_read_ioctl(tcp, code, arg);
+		case _IOC_WRITE:
+			return evdev_write_ioctl(tcp, code, arg) | RVAL_DECODED;
+		default:
+			return RVAL_DECODED;
+	}
+}
+
+#endif /* HAVE_LINUX_INPUT_H */
diff --git a/strace/eventfd.c b/strace/eventfd.c
new file mode 100644
index 0000000..0e7babc
--- /dev/null
+++ b/strace/eventfd.c
@@ -0,0 +1,57 @@
+/*
+ * Copyright (c) 2007 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2008-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+#ifdef HAVE_SYS_EVENTFD_H
+# include <sys/eventfd.h>
+#endif
+
+#include "xlat/efd_flags.h"
+
+static int
+do_eventfd(struct tcb *tcp, int flags_arg)
+{
+	tprintf("%u", (unsigned int) tcp->u_arg[0]);
+	if (flags_arg >= 0) {
+		tprints(", ");
+		printflags(efd_flags, tcp->u_arg[flags_arg], "EFD_???");
+	}
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(eventfd)
+{
+	return do_eventfd(tcp, -1);
+}
+
+SYS_FUNC(eventfd2)
+{
+	return do_eventfd(tcp, 1);
+}
diff --git a/strace/execve.c b/strace/execve.c
new file mode 100644
index 0000000..d2ff9f7
--- /dev/null
+++ b/strace/execve.c
@@ -0,0 +1,145 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2007 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2011-2012 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2010-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+static void
+printargv(struct tcb *tcp, long addr)
+{
+	if (!addr || !verbose(tcp)) {
+		printaddr(addr);
+		return;
+	}
+
+	const char *const start_sep = "[";
+	const char *sep = start_sep;
+	const unsigned int wordsize = current_wordsize;
+	unsigned int n;
+
+	for (n = 0; addr; sep = ", ", addr += wordsize, ++n) {
+		union {
+			unsigned int p32;
+			unsigned long p64;
+			char data[sizeof(long)];
+		} cp;
+
+		if (umoven(tcp, addr, wordsize, cp.data)) {
+			if (sep == start_sep)
+				printaddr(addr);
+			else
+				tprints(", ???]");
+			return;
+		}
+		if (!(wordsize < sizeof(cp.p64) ? cp.p32 : cp.p64)) {
+			if (sep == start_sep)
+				tprints(start_sep);
+			break;
+		}
+		if (abbrev(tcp) && n >= max_strlen) {
+			tprintf("%s...", sep);
+			break;
+		}
+		tprints(sep);
+		printstr(tcp, wordsize < sizeof(cp.p64) ? cp.p32 : cp.p64, -1);
+	}
+	tprints("]");
+}
+
+static void
+printargc(struct tcb *tcp, long addr)
+{
+	if (!addr || !verbose(tcp)) {
+		printaddr(addr);
+		return;
+	}
+
+	bool unterminated = false;
+	unsigned int count = 0;
+	char *cp = NULL;
+
+	for (; addr; addr += current_wordsize, ++count) {
+		if (umoven(tcp, addr, current_wordsize, &cp)) {
+			if (count) {
+				unterminated = true;
+				break;
+			}
+			printaddr(addr);
+			return;
+		}
+		if (!cp)
+			break;
+	}
+	tprintf("[/* %u var%s%s */]",
+		count, count == 1 ? "" : "s",
+		unterminated ? ", unterminated" : "");
+}
+
+static void
+decode_execve(struct tcb *tcp, const unsigned int index)
+{
+	printpath(tcp, tcp->u_arg[index + 0]);
+	tprints(", ");
+
+	printargv(tcp, tcp->u_arg[index + 1]);
+	tprints(", ");
+
+	(abbrev(tcp) ? printargc : printargv) (tcp, tcp->u_arg[index + 2]);
+}
+
+SYS_FUNC(execve)
+{
+	decode_execve(tcp, 0);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(execveat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	decode_execve(tcp, 1);
+	tprints(", ");
+	printflags(at_flags, tcp->u_arg[4], "AT_???");
+
+	return RVAL_DECODED;
+}
+
+#if defined(SPARC) || defined(SPARC64)
+SYS_FUNC(execv)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printargv(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+#endif /* SPARC || SPARC64 */
diff --git a/strace/exit.c b/strace/exit.c
new file mode 100644
index 0000000..aec01da
--- /dev/null
+++ b/strace/exit.c
@@ -0,0 +1,15 @@
+#include "defs.h"
+
+SYS_FUNC(exit)
+{
+	if (exiting(tcp)) {
+		error_msg("_exit returned!");
+		return -1;
+	}
+	/* special case: we stop tracing this process, finish line now */
+	tprintf("%ld) ", tcp->u_arg[0]);
+	tabto();
+	tprints("= ?\n");
+	line_ended();
+	return 0;
+}
diff --git a/strace/fadvise.c b/strace/fadvise.c
new file mode 100644
index 0000000..2001394
--- /dev/null
+++ b/strace/fadvise.c
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2007 Daniel Jacobowitz  <dan@codesourcery.com>
+ * Copyright (c) 2009 Andreas Schwab <schwab@redhat.com>
+ * Copyright (c) 2009 Kirill A. Shutemov <kirill@shutemov.name>
+ * Copyright (c) 2011-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+
+#include "xlat/advise.h"
+
+SYS_FUNC(fadvise64)
+{
+	int argn;
+
+	printfd(tcp, tcp->u_arg[0]);
+	argn = printllval(tcp, ", %lld", 1);
+	tprintf(", %ld, ", tcp->u_arg[argn++]);
+	printxval(advise, tcp->u_arg[argn], "POSIX_FADV_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fadvise64_64)
+{
+	int argn;
+
+	printfd(tcp, tcp->u_arg[0]);
+	argn = printllval(tcp, ", %lld, ", 1);
+	argn = printllval(tcp, "%lld, ", argn);
+#if defined __ARM_EABI__ || defined AARCH64 || defined POWERPC || defined XTENSA
+	printxval(advise, tcp->u_arg[1], "POSIX_FADV_???");
+#else
+	printxval(advise, tcp->u_arg[argn], "POSIX_FADV_???");
+#endif
+
+	return RVAL_DECODED;
+}
diff --git a/strace/fallocate.c b/strace/fallocate.c
new file mode 100644
index 0000000..0b1cfec
--- /dev/null
+++ b/strace/fallocate.c
@@ -0,0 +1,28 @@
+#include "defs.h"
+
+#ifdef HAVE_LINUX_FALLOC_H
+# include <linux/falloc.h>
+#endif
+
+#include "xlat/falloc_flags.h"
+
+SYS_FUNC(fallocate)
+{
+	int argn;
+
+	/* fd */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+
+	/* mode */
+	printflags(falloc_flags, tcp->u_arg[1], "FALLOC_FL_???");
+	tprints(", ");
+
+	/* offset */
+	argn = printllval(tcp, "%llu, ", 2);
+
+	/* len */
+	printllval(tcp, "%llu", argn);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/fanotify.c b/strace/fanotify.c
new file mode 100644
index 0000000..203e9d2
--- /dev/null
+++ b/strace/fanotify.c
@@ -0,0 +1,84 @@
+/*
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/fan_classes.h"
+#include "xlat/fan_init_flags.h"
+
+#ifndef FAN_ALL_CLASS_BITS
+# define FAN_ALL_CLASS_BITS (FAN_CLASS_NOTIF | FAN_CLASS_CONTENT | FAN_CLASS_PRE_CONTENT)
+#endif
+#ifndef FAN_NOFD
+# define FAN_NOFD -1
+#endif
+
+SYS_FUNC(fanotify_init)
+{
+	unsigned int flags = tcp->u_arg[0];
+
+	printxval(fan_classes, flags & FAN_ALL_CLASS_BITS, "FAN_CLASS_???");
+	flags &= ~FAN_ALL_CLASS_BITS;
+	if (flags) {
+		tprints("|");
+		printflags(fan_init_flags, flags, "FAN_???");
+	}
+	tprints(", ");
+	tprint_open_modes((unsigned) tcp->u_arg[1]);
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+#include "xlat/fan_mark_flags.h"
+#include "xlat/fan_event_flags.h"
+
+SYS_FUNC(fanotify_mark)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printflags(fan_mark_flags, tcp->u_arg[1], "FAN_MARK_???");
+	tprints(", ");
+	/*
+	 * the mask argument is defined as 64-bit,
+	 * but kernel uses the lower 32 bits only.
+	 */
+	unsigned long long mask = 0;
+	int argn = getllval(tcp, &mask, 2);
+#ifdef HPPA
+	/* Parsic is weird.  See arch/parisc/kernel/sys_parisc32.c.  */
+	mask = (mask << 32) | (mask >> 32);
+#endif
+	printflags64(fan_event_flags, mask, "FAN_???");
+	tprints(", ");
+	if ((int) tcp->u_arg[argn] == FAN_NOFD)
+		tprints("FAN_NOFD, ");
+	else
+		print_dirfd(tcp, tcp->u_arg[argn]);
+	printpath(tcp, tcp->u_arg[argn + 1]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/fchownat.c b/strace/fchownat.c
new file mode 100644
index 0000000..6aed51d
--- /dev/null
+++ b/strace/fchownat.c
@@ -0,0 +1,13 @@
+#include "defs.h"
+
+SYS_FUNC(fchownat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	printpath(tcp, tcp->u_arg[1]);
+	printuid(", ", tcp->u_arg[2]);
+	printuid(", ", tcp->u_arg[3]);
+	tprints(", ");
+	printflags(at_flags, tcp->u_arg[4], "AT_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/fcntl.c b/strace/fcntl.c
new file mode 100644
index 0000000..bfe8b14
--- /dev/null
+++ b/strace/fcntl.c
@@ -0,0 +1,242 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 "flock.h"
+
+#include "xlat/f_owner_types.h"
+#include "xlat/f_seals.h"
+#include "xlat/fcntlcmds.h"
+#include "xlat/fcntl64cmds.h"
+#include "xlat/fdflags.h"
+#include "xlat/lockfcmds.h"
+#include "xlat/notifyflags.h"
+
+static void
+print_struct_flock64(const struct_kernel_flock64 *fl, const int getlk)
+{
+	tprints("{l_type=");
+	printxval(lockfcmds, (unsigned short) fl->l_type, "F_???");
+	tprints(", l_whence=");
+	printxval(whence_codes, (unsigned short) fl->l_whence, "SEEK_???");
+	tprintf(", l_start=%lld, l_len=%lld",
+		(long long) fl->l_start, (long long) fl->l_len);
+	if (getlk)
+		tprintf(", l_pid=%lu", (unsigned long) fl->l_pid);
+	tprints("}");
+}
+
+static void
+printflock64(struct tcb *tcp, const long addr, const int getlk)
+{
+	struct_kernel_flock64 fl;
+
+	if (fetch_struct_flock64(tcp, addr, &fl))
+		print_struct_flock64(&fl, getlk);
+}
+
+static void
+printflock(struct tcb *tcp, const long addr, const int getlk)
+{
+	struct_kernel_flock64 fl;
+
+	if (fetch_struct_flock(tcp, addr, &fl))
+		print_struct_flock64(&fl, getlk);
+}
+
+static void
+print_f_owner_ex(struct tcb *tcp, const long addr)
+{
+	struct { int type, pid; } owner;
+
+	if (umove_or_printaddr(tcp, addr, &owner))
+		return;
+
+	tprints("{type=");
+	printxval(f_owner_types, owner.type, "F_OWNER_???");
+	tprintf(", pid=%d}", owner.pid);
+}
+
+static int
+print_fcntl(struct tcb *tcp)
+{
+	const unsigned int cmd = tcp->u_arg[1];
+
+	switch (cmd) {
+	case F_SETFD:
+		tprints(", ");
+		printflags(fdflags, tcp->u_arg[2], "FD_???");
+		break;
+	case F_SETOWN:
+	case F_SETPIPE_SZ:
+		tprintf(", %ld", tcp->u_arg[2]);
+		break;
+	case F_DUPFD:
+	case F_DUPFD_CLOEXEC:
+		tprintf(", %ld", tcp->u_arg[2]);
+		return RVAL_DECODED | RVAL_FD;
+	case F_SETFL:
+		tprints(", ");
+		tprint_open_modes(tcp->u_arg[2]);
+		break;
+	case F_SETLK:
+	case F_SETLKW:
+		tprints(", ");
+		printflock(tcp, tcp->u_arg[2], 0);
+		break;
+	case F_OFD_SETLK:
+	case F_OFD_SETLKW:
+		tprints(", ");
+		printflock64(tcp, tcp->u_arg[2], 0);
+		break;
+	case F_SETOWN_EX:
+		tprints(", ");
+		print_f_owner_ex(tcp, tcp->u_arg[2]);
+		break;
+	case F_NOTIFY:
+		tprints(", ");
+		printflags_long(notifyflags, tcp->u_arg[2], "DN_???");
+		break;
+	case F_SETLEASE:
+		tprints(", ");
+		printxval_long(lockfcmds, tcp->u_arg[2], "F_???");
+		break;
+	case F_ADD_SEALS:
+		tprints(", ");
+		printflags_long(f_seals, tcp->u_arg[2], "F_SEAL_???");
+		break;
+	case F_SETSIG:
+		tprints(", ");
+		tprints(signame(tcp->u_arg[2]));
+		break;
+	case F_GETOWN:
+	case F_GETPIPE_SZ:
+		break;
+	case F_GETFD:
+		if (entering(tcp) || syserror(tcp) || tcp->u_rval == 0)
+			return 0;
+		tcp->auxstr = sprintflags("flags ", fdflags,
+					  (unsigned long) tcp->u_rval);
+		return RVAL_HEX | RVAL_STR;
+	case F_GETFL:
+		if (entering(tcp) || syserror(tcp))
+			return 0;
+		tcp->auxstr = sprint_open_modes(tcp->u_rval);
+		return RVAL_HEX | RVAL_STR;
+	case F_GETLK:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printflock(tcp, tcp->u_arg[2], 1);
+		break;
+	case F_OFD_GETLK:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printflock64(tcp, tcp->u_arg[2], 1);
+		break;
+	case F_GETOWN_EX:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		print_f_owner_ex(tcp, tcp->u_arg[2]);
+		break;
+	case F_GETLEASE:
+		if (entering(tcp) || syserror(tcp))
+			return 0;
+		tcp->auxstr = xlookup(lockfcmds, (unsigned long) tcp->u_rval);
+		return RVAL_HEX | RVAL_STR;
+	case F_GET_SEALS:
+		if (entering(tcp) || syserror(tcp) || tcp->u_rval == 0)
+			return 0;
+		tcp->auxstr = sprintflags("seals ", f_seals,
+					  (unsigned long) tcp->u_rval);
+		return RVAL_HEX | RVAL_STR;
+	case F_GETSIG:
+		if (entering(tcp) || syserror(tcp) || tcp->u_rval == 0)
+			return 0;
+		tcp->auxstr = signame(tcp->u_rval);
+		return RVAL_STR;
+	default:
+		tprintf(", %#lx", tcp->u_arg[2]);
+		break;
+	}
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fcntl)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		const unsigned int cmd = tcp->u_arg[1];
+		const char *str = xlookup(fcntlcmds, cmd);
+		if (str) {
+			tprints(str);
+		} else {
+			/*
+			 * fcntl syscall does not recognize these
+			 * constants, but we would like to show them
+			 * for better debugging experience.
+			 */
+			printxval(fcntl64cmds, cmd, "F_???");
+		}
+	}
+	return print_fcntl(tcp);
+}
+
+SYS_FUNC(fcntl64)
+{
+	const unsigned int cmd = tcp->u_arg[1];
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		const char *str = xlookup(fcntl64cmds, cmd);
+		if (str) {
+			tprints(str);
+		} else {
+			printxval(fcntlcmds, cmd, "F_???");
+		}
+	}
+	switch (cmd) {
+		case F_SETLK64:
+		case F_SETLKW64:
+			tprints(", ");
+			printflock64(tcp, tcp->u_arg[2], 0);
+			return RVAL_DECODED;
+		case F_GETLK64:
+			if (exiting(tcp)) {
+				tprints(", ");
+				printflock64(tcp, tcp->u_arg[2], 1);
+			}
+			return 0;
+	}
+	return print_fcntl(tcp);
+}
diff --git a/strace/fetch_seccomp_fprog.c b/strace/fetch_seccomp_fprog.c
new file mode 100644
index 0000000..d54b979
--- /dev/null
+++ b/strace/fetch_seccomp_fprog.c
@@ -0,0 +1,52 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(seccomp_fprog_t)
+
+#include "seccomp_fprog.h"
+typedef struct seccomp_fprog seccomp_fprog_t;
+
+#include MPERS_DEFS
+
+MPERS_PRINTER_DECL(bool, fetch_seccomp_fprog,
+		   struct tcb *tcp, const long addr, void *p)
+{
+	struct seccomp_fprog *pfp = p;
+	seccomp_fprog_t mfp;
+
+	if (sizeof(*pfp) == sizeof(mfp))
+		return !umove_or_printaddr(tcp, addr, pfp);
+
+	if (umove_or_printaddr(tcp, addr, &mfp))
+		return false;
+
+	pfp->len = mfp.len;
+	pfp->filter = mfp.filter;
+	return true;
+}
diff --git a/strace/fetch_struct_flock.c b/strace/fetch_struct_flock.c
new file mode 100644
index 0000000..b5713f4
--- /dev/null
+++ b/strace/fetch_struct_flock.c
@@ -0,0 +1,92 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_flock)
+#include DEF_MPERS_TYPE(struct_flock64)
+
+#include "flock.h"
+typedef struct_kernel_flock struct_flock;
+typedef struct_kernel_flock64 struct_flock64;
+
+#include MPERS_DEFS
+
+#define SIZEOF_MEMBER(type, member) \
+	sizeof(((type *) NULL)->member)
+
+#define FLOCK_MEMBERS_EQ(type, member) \
+	(SIZEOF_MEMBER(struct_kernel_flock64, member) == SIZEOF_MEMBER(type, member) \
+	 && offsetof(struct_kernel_flock64, member) == offsetof(type, member))
+
+#define FLOCK_STRUCTS_EQ(type) \
+	(sizeof(struct_kernel_flock64) == sizeof(type) \
+	 && FLOCK_MEMBERS_EQ(type, l_type) \
+	 && FLOCK_MEMBERS_EQ(type, l_whence) \
+	 && FLOCK_MEMBERS_EQ(type, l_start) \
+	 && FLOCK_MEMBERS_EQ(type, l_len) \
+	 && FLOCK_MEMBERS_EQ(type, l_pid))
+
+MPERS_PRINTER_DECL(bool, fetch_struct_flock,
+		   struct tcb *tcp, const long addr, void *p)
+{
+	struct_kernel_flock64 *pfl = p;
+	struct_flock mfl;
+
+	if (FLOCK_STRUCTS_EQ(struct_flock))
+		return !umove_or_printaddr(tcp, addr, pfl);
+
+	if (umove_or_printaddr(tcp, addr, &mfl))
+		return false;
+
+	pfl->l_type = mfl.l_type;
+	pfl->l_whence = mfl.l_whence;
+	pfl->l_start = mfl.l_start;
+	pfl->l_len = mfl.l_len;
+	pfl->l_pid = mfl.l_pid;
+	return true;
+}
+
+MPERS_PRINTER_DECL(bool, fetch_struct_flock64,
+		   struct tcb *tcp, const long addr, void *p)
+{
+	struct_kernel_flock64 *pfl = p;
+	struct_flock64 mfl;
+
+	if (FLOCK_STRUCTS_EQ(struct_flock64))
+		return !umove_or_printaddr(tcp, addr, pfl);
+
+	if (umove_or_printaddr(tcp, addr, &mfl))
+		return false;
+
+	pfl->l_type = mfl.l_type;
+	pfl->l_whence = mfl.l_whence;
+	pfl->l_start = mfl.l_start;
+	pfl->l_len = mfl.l_len;
+	pfl->l_pid = mfl.l_pid;
+	return true;
+}
diff --git a/strace/fetch_struct_mmsghdr.c b/strace/fetch_struct_mmsghdr.c
new file mode 100644
index 0000000..87d52c6
--- /dev/null
+++ b/strace/fetch_struct_mmsghdr.c
@@ -0,0 +1,87 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_mmsghdr)
+
+#include "msghdr.h"
+typedef struct mmsghdr struct_mmsghdr;
+
+#include MPERS_DEFS
+
+/*
+ * On success, return the number of fetched bytes.
+ * On error, return 0;
+ *
+ * This function cannot use umove_or_printaddr because
+ * it is called by dumpio and therefore cannot print anything.
+ */
+
+MPERS_PRINTER_DECL(int, fetch_struct_mmsghdr,
+		   struct tcb *tcp, const unsigned long addr, void *p)
+{
+	struct mmsghdr *p_native = p;
+	struct_mmsghdr v_compat;
+
+	if (sizeof(*p_native) == sizeof(v_compat))
+		return umove(tcp, addr, p_native) ? 0 : sizeof(*p_native);
+
+	if (umove(tcp, addr, &v_compat))
+		return 0;
+
+	p_native->msg_hdr.msg_name = (void *) (unsigned long)
+	 v_compat.msg_hdr.msg_name;
+
+	p_native->msg_hdr.msg_namelen =
+	 v_compat.msg_hdr.msg_namelen;
+
+	p_native->msg_hdr.msg_iov = (void *) (unsigned long)
+	 v_compat.msg_hdr.msg_iov;
+
+	p_native->msg_hdr.msg_iovlen =
+	 v_compat.msg_hdr.msg_iovlen;
+
+	p_native->msg_hdr.msg_control = (void *) (unsigned long)
+	 v_compat.msg_hdr.msg_control;
+
+	p_native->msg_hdr.msg_controllen =
+	 v_compat.msg_hdr.msg_controllen;
+
+	p_native->msg_hdr.msg_flags =
+	 v_compat.msg_hdr.msg_flags;
+
+	p_native->msg_len =
+	 v_compat.msg_len;
+
+	return sizeof(v_compat);
+}
+
+MPERS_PRINTER_DECL(unsigned int, sizeof_struct_mmsghdr, void)
+{
+	return sizeof(struct_mmsghdr);
+}
diff --git a/strace/fetch_struct_msghdr.c b/strace/fetch_struct_msghdr.c
new file mode 100644
index 0000000..78b505b
--- /dev/null
+++ b/strace/fetch_struct_msghdr.c
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_msghdr)
+
+#include "msghdr.h"
+typedef struct msghdr struct_msghdr;
+
+#include MPERS_DEFS
+
+/*
+ * On success, return the number of fetched bytes.
+ * On error, return 0;
+ *
+ * This function cannot use umove_or_printaddr because
+ * it is called by dumpio and therefore cannot print anything.
+ */
+
+MPERS_PRINTER_DECL(int, fetch_struct_msghdr,
+		   struct tcb *tcp, const unsigned long addr, void *p)
+{
+	struct msghdr *p_native = p;
+	struct_msghdr v_compat;
+
+	if (sizeof(*p_native) == sizeof(v_compat))
+		return umove(tcp, addr, p_native) ? 0 : sizeof(*p_native);
+
+	if (umove(tcp, addr, &v_compat))
+		return 0;
+
+	p_native->msg_name = (void *) (unsigned long)
+	 v_compat.msg_name;
+
+	p_native->msg_namelen =
+	 v_compat.msg_namelen;
+
+	p_native->msg_iov = (void *) (unsigned long)
+	 v_compat.msg_iov;
+
+	p_native->msg_iovlen =
+	 v_compat.msg_iovlen;
+
+	p_native->msg_control = (void *) (unsigned long)
+	 v_compat.msg_control;
+
+	p_native->msg_controllen =
+	 v_compat.msg_controllen;
+
+	p_native->msg_flags =
+	 v_compat.msg_flags;
+
+	return sizeof(v_compat);
+}
diff --git a/strace/fetch_struct_statfs.c b/strace/fetch_struct_statfs.c
new file mode 100644
index 0000000..0cfe5ba
--- /dev/null
+++ b/strace/fetch_struct_statfs.c
@@ -0,0 +1,121 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_statfs)
+#include DEF_MPERS_TYPE(struct_statfs64)
+
+#include <linux/types.h>
+#include <asm/statfs.h>
+typedef struct statfs struct_statfs;
+typedef struct statfs64 struct_statfs64;
+
+#include MPERS_DEFS
+
+#include "statfs.h"
+
+MPERS_PRINTER_DECL(bool, fetch_struct_statfs,
+		   struct tcb *tcp, const long addr, struct strace_statfs *p)
+{
+	struct_statfs b;
+
+	if (umove_or_printaddr(tcp, addr, &b))
+		return false;
+
+	p->f_type = widen_to_ull(b.f_type);
+	p->f_bsize = widen_to_ull(b.f_bsize);
+	p->f_blocks = widen_to_ull(b.f_blocks);
+	p->f_bfree = widen_to_ull(b.f_bfree);
+	p->f_bavail = widen_to_ull(b.f_bavail);
+	p->f_files = widen_to_ull(b.f_files);
+	p->f_ffree = widen_to_ull(b.f_ffree);
+#if defined HAVE_STRUCT_STATFS_F_FSID_VAL
+	p->f_fsid[0] = widen_to_ull(b.f_fsid.val[0]);
+	p->f_fsid[1] = widen_to_ull(b.f_fsid.val[1]);
+#elif defined HAVE_STRUCT_STATFS_F_FSID___VAL
+	p->f_fsid[0] = widen_to_ull(b.f_fsid.__val[0]);
+	p->f_fsid[1] = widen_to_ull(b.f_fsid.__val[1]);
+#endif
+	p->f_namelen = widen_to_ull(b.f_namelen);
+#ifdef HAVE_STRUCT_STATFS_F_FRSIZE
+	p->f_frsize = widen_to_ull(b.f_frsize);
+#endif
+#ifdef HAVE_STRUCT_STATFS_F_FLAGS
+	p->f_flags = widen_to_ull(b.f_flags);
+#endif
+
+	return true;
+}
+
+#if defined ARM || (defined AARCH64 && defined IN_MPERS)
+/* See arch/arm/kernel/sys_oabi-compat.c for details. */
+# define COMPAT_STATFS64_PADDED_SIZE (sizeof(struct_statfs64) + 4)
+#endif
+
+MPERS_PRINTER_DECL(bool, fetch_struct_statfs64,
+		   struct tcb *tcp, const long addr, const unsigned long size,
+		   struct strace_statfs *p)
+{
+	struct_statfs64 b;
+
+        if (sizeof(b) != size
+#ifdef COMPAT_STATFS64_PADDED_SIZE
+	    && sizeof(b) != COMPAT_STATFS64_PADDED_SIZE
+#endif
+	   ) {
+		printaddr(addr);
+		return false;
+	}
+
+	if (umove_or_printaddr(tcp, addr, &b))
+		return false;
+
+	p->f_type = widen_to_ull(b.f_type);
+	p->f_bsize = widen_to_ull(b.f_bsize);
+	p->f_blocks = widen_to_ull(b.f_blocks);
+	p->f_bfree = widen_to_ull(b.f_bfree);
+	p->f_bavail = widen_to_ull(b.f_bavail);
+	p->f_files = widen_to_ull(b.f_files);
+	p->f_ffree = widen_to_ull(b.f_ffree);
+#if defined HAVE_STRUCT_STATFS64_F_FSID_VAL
+	p->f_fsid[0] = widen_to_ull(b.f_fsid.val[0]);
+	p->f_fsid[1] = widen_to_ull(b.f_fsid.val[1]);
+#elif defined HAVE_STRUCT_STATFS64_F_FSID___VAL
+	p->f_fsid[0] = widen_to_ull(b.f_fsid.__val[0]);
+	p->f_fsid[1] = widen_to_ull(b.f_fsid.__val[1]);
+#endif
+	p->f_namelen = widen_to_ull(b.f_namelen);
+#ifdef HAVE_STRUCT_STATFS64_F_FRSIZE
+	p->f_frsize = widen_to_ull(b.f_frsize);
+#endif
+#ifdef HAVE_STRUCT_STATFS64_F_FLAGS
+	p->f_flags = widen_to_ull(b.f_flags);
+#endif
+
+	return true;
+}
diff --git a/strace/file.c b/strace/file.c
new file mode 100644
index 0000000..3ea0b5d
--- /dev/null
+++ b/strace/file.c
@@ -0,0 +1,493 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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"
+
+#undef dev_t
+#undef ino_t
+#undef mode_t
+#undef nlink_t
+#undef uid_t
+#undef gid_t
+#undef off_t
+#undef loff_t
+#define dev_t __kernel_dev_t
+#define ino_t __kernel_ino_t
+#define mode_t __kernel_mode_t
+#define nlink_t __kernel_nlink_t
+#define uid_t __kernel_uid_t
+#define gid_t __kernel_gid_t
+#define off_t __kernel_off_t
+#define loff_t __kernel_loff_t
+
+#include "asm_stat.h"
+
+#undef dev_t
+#undef ino_t
+#undef mode_t
+#undef nlink_t
+#undef uid_t
+#undef gid_t
+#undef off_t
+#undef loff_t
+#define dev_t dev_t
+#define ino_t ino_t
+#define mode_t mode_t
+#define nlink_t nlink_t
+#define uid_t uid_t
+#define gid_t gid_t
+#define off_t off_t
+#define loff_t loff_t
+
+/* for S_IFMT */
+#define stat libc_stat
+#define stat64 libc_stat64
+#include <sys/stat.h>
+#undef stat
+#undef stat64
+/* These might be macros. */
+#undef st_atime
+#undef st_mtime
+#undef st_ctime
+
+#if defined MAJOR_IN_SYSMACROS
+# include <sys/sysmacros.h>
+#elif defined MAJOR_IN_MKDEV
+# include <sys/mkdev.h>
+#endif
+
+/* several stats */
+
+#include "printstat.h"
+
+/* all locally defined structures provide these fields */
+#undef HAVE_STRUCT_STAT_ST_ATIME_NSEC
+#define HAVE_STRUCT_STAT_ST_ATIME_NSEC 1
+#undef HAVE_STRUCT_STAT_ST_CTIME_NSEC
+#define HAVE_STRUCT_STAT_ST_CTIME_NSEC 1
+#undef HAVE_STRUCT_STAT_ST_MTIME_NSEC
+#define HAVE_STRUCT_STAT_ST_MTIME_NSEC 1
+
+#undef STAT32_PERSONALITY
+#if SUPPORTED_PERSONALITIES > 1
+# if defined AARCH64 || defined X86_64 || defined X32
+struct stat32 {
+	unsigned int	st_dev;
+	unsigned int	st_ino;
+	unsigned short	st_mode;
+	unsigned short	st_nlink;
+	unsigned short	st_uid;
+	unsigned short	st_gid;
+	unsigned int	st_rdev;
+	unsigned int	st_size;
+	unsigned int	st_blksize;
+	unsigned int	st_blocks;
+	unsigned int	st_atime;
+	unsigned int	st_atime_nsec;
+	unsigned int	st_mtime;
+	unsigned int	st_mtime_nsec;
+	unsigned int	st_ctime;
+	unsigned int	st_ctime_nsec;
+	unsigned int	__unused4;
+	unsigned int	__unused5;
+};
+#  define STAT32_PERSONALITY 1
+# elif defined POWERPC64
+struct stat32 {
+	unsigned int	st_dev;
+	unsigned int	st_ino;
+	unsigned int	st_mode;
+	unsigned short	st_nlink;
+	unsigned int	st_uid;
+	unsigned int	st_gid;
+	unsigned int	st_rdev;
+	unsigned int	st_size;
+	unsigned int	st_blksize;
+	unsigned int	st_blocks;
+	unsigned int	st_atime;
+	unsigned int	st_atime_nsec;
+	unsigned int	st_mtime;
+	unsigned int	st_mtime_nsec;
+	unsigned int	st_ctime;
+	unsigned int	st_ctime_nsec;
+	unsigned int	__unused4;
+	unsigned int	__unused5;
+};
+#  define STAT32_PERSONALITY 1
+# elif defined SPARC64
+struct stat32 {
+	unsigned short	st_dev;
+	unsigned int	st_ino;
+	unsigned short	st_mode;
+	unsigned short	st_nlink;
+	unsigned short	st_uid;
+	unsigned short	st_gid;
+	unsigned short	st_rdev;
+	unsigned int	st_size;
+	unsigned int	st_atime;
+	unsigned int	st_atime_nsec;
+	unsigned int	st_mtime;
+	unsigned int	st_mtime_nsec;
+	unsigned int	st_ctime;
+	unsigned int	st_ctime_nsec;
+	unsigned int	st_blksize;
+	unsigned int	st_blocks;
+	unsigned int	__unused4[2];
+};
+#  define STAT32_PERSONALITY 0
+# elif defined SPARC
+#  /* no 64-bit personalities */
+# elif defined TILE
+#  /* no 32-bit stat */
+# else
+#  warning FIXME: check whether struct stat32 definition is needed for this architecture!
+# endif /* X86_64 || X32 || POWERPC64 */
+#endif /* SUPPORTED_PERSONALITIES > 1 */
+
+#ifdef STAT32_PERSONALITY
+# define DO_PRINTSTAT do_printstat32
+# define STRUCT_STAT struct stat32
+# undef HAVE_STRUCT_STAT_ST_FLAGS
+# undef HAVE_STRUCT_STAT_ST_FSTYPE
+# undef HAVE_STRUCT_STAT_ST_GEN
+# include "printstat.h"
+#endif /* STAT32_PERSONALITY */
+
+#if defined(SPARC) || defined(SPARC64)
+
+struct solstat {
+	unsigned	st_dev;
+	unsigned int	st_pad1[3];     /* network id */
+	unsigned	st_ino;
+	unsigned	st_mode;
+	unsigned	st_nlink;
+	unsigned	st_uid;
+	unsigned	st_gid;
+	unsigned	st_rdev;
+	unsigned int	st_pad2[2];
+	unsigned int	st_size;
+	unsigned int	st_pad3;        /* st_size, off_t expansion */
+	unsigned int	st_atime;
+	unsigned int	st_atime_nsec;
+	unsigned int	st_mtime;
+	unsigned int	st_mtime_nsec;
+	unsigned int	st_ctime;
+	unsigned int	st_ctime_nsec;
+	unsigned int	st_blksize;
+	unsigned int	st_blocks;
+	char		st_fstype[16];
+	unsigned int	st_pad4[8];     /* expansion area */
+};
+
+# define DO_PRINTSTAT	do_printstat_sol
+# define STRUCT_STAT	struct solstat
+# define STAT_MAJOR(x)	(((x) >> 18) & 0x3fff)
+# define STAT_MINOR(x)	((x) & 0x3ffff)
+# undef HAVE_STRUCT_STAT_ST_FLAGS
+# undef HAVE_STRUCT_STAT_ST_FSTYPE
+# undef HAVE_STRUCT_STAT_ST_GEN
+# include "printstat.h"
+#endif /* SPARC || SPARC64 */
+
+static void
+printstat(struct tcb *tcp, long addr)
+{
+	struct stat statbuf;
+
+#ifdef STAT32_PERSONALITY
+	if (current_personality == STAT32_PERSONALITY) {
+		struct stat32 statbuf;
+
+		if (!umove_or_printaddr(tcp, addr, &statbuf))
+			do_printstat32(tcp, &statbuf);
+		return;
+	}
+#endif
+
+#if defined(SPARC) || defined(SPARC64)
+	if (current_personality == 1) {
+		struct solstat statbuf;
+
+		if (!umove_or_printaddr(tcp, addr, &statbuf))
+			do_printstat_sol(tcp, &statbuf);
+		return;
+	}
+#endif /* SPARC || SPARC64 */
+
+	if (!umove_or_printaddr(tcp, addr, &statbuf))
+		do_printstat(tcp, &statbuf);
+}
+
+SYS_FUNC(stat)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		printstat(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+SYS_FUNC(fstat)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		printstat(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+#if defined STAT32_PERSONALITY && !defined HAVE_STRUCT_STAT64
+# if defined AARCH64 || defined X86_64 || defined X32
+/*
+ * Linux x86_64 and x32 have unified `struct stat' but their i386 personality
+ * needs `struct stat64'.
+ * linux/arch/x86/include/uapi/asm/stat.h defines `struct stat64' only for i386.
+ *
+ * Similarly, aarch64 has a unified `struct stat' but its arm personality
+ * needs `struct stat64' (unlike x86, it shouldn't be packed).
+ */
+struct stat64 {
+	unsigned long long	st_dev;
+	unsigned char	__pad0[4];
+	unsigned int	__st_ino;
+	unsigned int	st_mode;
+	unsigned int	st_nlink;
+	unsigned int	st_uid;
+	unsigned int	st_gid;
+	unsigned long long	st_rdev;
+	unsigned char	__pad3[4];
+	long long	st_size;
+	unsigned int	st_blksize;
+	unsigned long long	st_blocks;
+	unsigned int	st_atime;
+	unsigned int	st_atime_nsec;
+	unsigned int	st_mtime;
+	unsigned int	st_mtime_nsec;
+	unsigned int	st_ctime;
+	unsigned int	st_ctime_nsec;
+	unsigned long long	st_ino;
+}
+#  if defined X86_64 || defined X32
+  ATTRIBUTE_PACKED
+#   define STAT64_SIZE	96
+#  else
+#   define STAT64_SIZE	104
+#  endif
+;
+#  define HAVE_STRUCT_STAT64	1
+# else /* !(AARCH64 || X86_64 || X32) */
+#  warning FIXME: check whether struct stat64 definition is needed for this architecture!
+# endif
+#endif /* STAT32_PERSONALITY && !HAVE_STRUCT_STAT64 */
+
+#ifdef HAVE_STRUCT_STAT64
+
+# define DO_PRINTSTAT do_printstat64
+# define STRUCT_STAT struct stat64
+# undef HAVE_STRUCT_STAT_ST_FLAGS
+# undef HAVE_STRUCT_STAT_ST_FSTYPE
+# undef HAVE_STRUCT_STAT_ST_GEN
+# include "printstat.h"
+
+static void
+printstat64(struct tcb *tcp, long addr)
+{
+	struct stat64 statbuf;
+
+# ifdef STAT64_SIZE
+	(void) sizeof(char[sizeof statbuf == STAT64_SIZE ? 1 : -1]);
+# endif
+
+# ifdef STAT32_PERSONALITY
+	if (current_personality != STAT32_PERSONALITY) {
+		printstat(tcp, addr);
+		return;
+	}
+# endif /* STAT32_PERSONALITY */
+
+	if (!umove_or_printaddr(tcp, addr, &statbuf))
+		do_printstat64(tcp, &statbuf);
+}
+
+SYS_FUNC(stat64)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		printstat64(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+SYS_FUNC(fstat64)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		printstat64(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+#else
+
+SYS_FUNC(stat64)
+{
+	return sys_stat(tcp);
+}
+
+SYS_FUNC(fstat64)
+{
+	return sys_fstat(tcp);
+}
+
+#endif /* HAVE_STRUCT_STAT64 */
+
+SYS_FUNC(newfstatat)
+{
+	if (entering(tcp)) {
+		print_dirfd(tcp, tcp->u_arg[0]);
+		printpath(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+#if defined STAT32_PERSONALITY
+		if (current_personality == STAT32_PERSONALITY)
+			printstat64(tcp, tcp->u_arg[2]);
+		else
+			printstat(tcp, tcp->u_arg[2]);
+#elif defined HAVE_STRUCT_STAT64
+		printstat64(tcp, tcp->u_arg[2]);
+#else
+		printstat(tcp, tcp->u_arg[2]);
+#endif /* STAT32_PERSONALITY || HAVE_STRUCT_STAT64 */
+		tprints(", ");
+		printflags(at_flags, tcp->u_arg[3], "AT_???");
+	}
+	return 0;
+}
+
+#if defined(HAVE_STRUCT___OLD_KERNEL_STAT)
+
+static void
+convertoldstat(const struct __old_kernel_stat *oldbuf, struct stat *newbuf)
+{
+	memset(newbuf, 0, sizeof(*newbuf));
+	newbuf->st_dev = oldbuf->st_dev;
+	newbuf->st_ino = oldbuf->st_ino;
+	newbuf->st_mode = oldbuf->st_mode;
+	newbuf->st_nlink = oldbuf->st_nlink;
+	newbuf->st_uid = oldbuf->st_uid;
+	newbuf->st_gid = oldbuf->st_gid;
+	newbuf->st_rdev = oldbuf->st_rdev;
+	newbuf->st_size = oldbuf->st_size;
+	newbuf->st_atime = oldbuf->st_atime;
+	newbuf->st_mtime = oldbuf->st_mtime;
+	newbuf->st_ctime = oldbuf->st_ctime;
+}
+
+static void
+printoldstat(struct tcb *tcp, long addr)
+{
+	struct __old_kernel_stat statbuf;
+	struct stat newstatbuf;
+
+# if defined(SPARC) || defined(SPARC64)
+	if (current_personality == 1) {
+		struct solstat statbuf;
+
+		if (!umove_or_printaddr(tcp, addr, &statbuf))
+			do_printstat_sol(tcp, &statbuf);
+		return;
+	}
+# endif
+
+	if (!umove_or_printaddr(tcp, addr, &statbuf)) {
+		convertoldstat(&statbuf, &newstatbuf);
+		do_printstat(tcp, &newstatbuf);
+	}
+}
+
+SYS_FUNC(oldstat)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		printoldstat(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+SYS_FUNC(oldfstat)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		printoldstat(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+#endif /* HAVE_STRUCT___OLD_KERNEL_STAT */
+
+#if defined(SPARC) || defined(SPARC64)
+
+SYS_FUNC(xstat)
+{
+	if (entering(tcp)) {
+		tprintf("%ld, ", tcp->u_arg[0]);
+		printpath(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+		printstat(tcp, tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(fxstat)
+{
+	if (entering(tcp)) {
+		tprintf("%ld, ", tcp->u_arg[0]);
+		printfd(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+		printstat(tcp, tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+#endif /* SPARC || SPARC64 */
diff --git a/strace/file_handle.c b/strace/file_handle.c
new file mode 100644
index 0000000..21cf0f1
--- /dev/null
+++ b/strace/file_handle.c
@@ -0,0 +1,135 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifndef MAX_HANDLE_SZ
+# define MAX_HANDLE_SZ 128
+#endif
+
+typedef struct {
+	unsigned int handle_bytes;
+	int handle_type;
+} file_handle_header;
+
+SYS_FUNC(name_to_handle_at)
+{
+	file_handle_header h;
+	const long addr = tcp->u_arg[2];
+
+	if (entering(tcp)) {
+		/* dirfd */
+		print_dirfd(tcp, tcp->u_arg[0]);
+
+		/* pathname */
+		printpath(tcp, tcp->u_arg[1]);
+		tprints(", ");
+
+		/* handle */
+		if (umove_or_printaddr(tcp, addr, &h)) {
+			tprints(", ");
+
+			/* mount_id */
+			printaddr(tcp->u_arg[3]);
+			tprints(", ");
+
+			/* flags */
+			printflags(at_flags, tcp->u_arg[4], "AT_???");
+
+			return RVAL_DECODED;
+		}
+		tprintf("{handle_bytes=%u", h.handle_bytes);
+
+		set_tcb_priv_ulong(tcp, h.handle_bytes);
+
+		return 0;
+	} else {
+		unsigned int i = get_tcb_priv_ulong(tcp);
+
+		if ((!syserror(tcp) || EOVERFLOW == tcp->u_error)
+		    && !umove(tcp, addr, &h)) {
+			unsigned char f_handle[MAX_HANDLE_SZ];
+
+			if (i != h.handle_bytes)
+				tprintf(" => %u", h.handle_bytes);
+			if (!syserror(tcp)) {
+				tprintf(", handle_type=%d", h.handle_type);
+				if (h.handle_bytes > MAX_HANDLE_SZ)
+					h.handle_bytes = MAX_HANDLE_SZ;
+				if (!umoven(tcp, addr + sizeof(h), h.handle_bytes,
+					    f_handle)) {
+					tprints(", f_handle=0x");
+					for (i = 0; i < h.handle_bytes; ++i)
+						tprintf("%02x", f_handle[i]);
+				}
+			}
+		}
+		tprints("}, ");
+
+		/* mount_id */
+		printnum_int(tcp, tcp->u_arg[3], "%d");
+		tprints(", ");
+
+		/* flags */
+		printflags(at_flags, tcp->u_arg[4], "AT_???");
+	}
+	return 0;
+}
+
+SYS_FUNC(open_by_handle_at)
+{
+	file_handle_header h;
+	const long addr = tcp->u_arg[1];
+
+	/* mount_fd */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+
+	/* handle */
+	if (!umove_or_printaddr(tcp, addr, &h)) {
+		unsigned char f_handle[MAX_HANDLE_SZ];
+
+		tprintf("{handle_bytes=%u, handle_type=%d",
+			h.handle_bytes, h.handle_type);
+		if (h.handle_bytes > MAX_HANDLE_SZ)
+			h.handle_bytes = MAX_HANDLE_SZ;
+		if (!umoven(tcp, addr + sizeof(h), h.handle_bytes, &f_handle)) {
+			unsigned int i;
+
+			tprints(", f_handle=0x");
+			for (i = 0; i < h.handle_bytes; ++i)
+				tprintf("%02x", f_handle[i]);
+		}
+		tprints("}");
+	}
+	tprints(", ");
+
+	/* flags */
+	tprint_open_modes(tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/file_ioctl.c b/strace/file_ioctl.c
new file mode 100644
index 0000000..de81019
--- /dev/null
+++ b/strace/file_ioctl.c
@@ -0,0 +1,248 @@
+/*
+ * Copyright (c) 2016 Jeff Mahoney <jeffm@suse.com>
+ * 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 <linux/ioctl.h>
+#include <linux/fs.h>
+
+#ifdef HAVE_LINUX_FIEMAP_H
+# include <linux/fiemap.h>
+# include "xlat/fiemap_flags.h"
+# include "xlat/fiemap_extent_flags.h"
+#endif
+
+#ifndef FICLONE
+# define FICLONE         _IOW(0x94, 9, int)
+#endif
+
+#ifndef FICLONERANGE
+# define FICLONERANGE    _IOW(0x94, 13, struct file_clone_range)
+struct file_clone_range {
+	int64_t src_fd;
+	uint64_t src_offset;
+	uint64_t src_length;
+	uint64_t dest_offset;
+};
+#endif
+
+#ifndef FIDEDUPERANGE
+# define FIDEDUPERANGE   _IOWR(0x94, 54, struct file_dedupe_range)
+struct file_dedupe_range_info {
+	int64_t dest_fd;	/* in - destination file */
+	uint64_t dest_offset;	/* in - start of extent in destination */
+	uint64_t bytes_deduped;	/* out - total # of bytes we were able
+				 * to dedupe from this file. */
+	/* status of this dedupe operation:
+	 * < 0 for error
+	 * == FILE_DEDUPE_RANGE_SAME if dedupe succeeds
+	 * == FILE_DEDUPE_RANGE_DIFFERS if data differs
+	 */
+	int32_t status;		/* out - see above description */
+	uint32_t reserved;	/* must be zero */
+};
+
+struct file_dedupe_range {
+	uint64_t src_offset;	/* in - start of extent in source */
+	uint64_t src_length;	/* in - length of extent */
+	uint16_t dest_count;	/* in - total elements in info array */
+	uint16_t reserved1;	/* must be zero */
+	uint32_t reserved2;	/* must be zero */
+	struct file_dedupe_range_info info[0];
+};
+#endif
+
+static bool
+print_file_dedupe_range_info(struct tcb *tcp, void *elem_buf,
+			     size_t elem_size, void *data)
+{
+	const struct file_dedupe_range_info *info = elem_buf;
+	unsigned int *count = data;
+
+	if (count) {
+		if (*count == 0) {
+			tprints("...");
+			return false;
+		}
+		--*count;
+	}
+
+	if (entering(tcp)) {
+		tprints("{dest_fd=");
+		printfd(tcp, info->dest_fd);
+		tprintf(", dest_offset=%" PRIu64 "}",
+			(uint64_t) info->dest_offset);
+	} else {
+		tprintf("{bytes_deduped=%" PRIu64 ", status=%d}",
+			(uint64_t) info->bytes_deduped, info->status);
+	}
+
+	return true;
+}
+
+#ifdef HAVE_LINUX_FIEMAP_H
+static bool
+print_fiemap_extent(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const struct fiemap_extent *fe = elem_buf;
+
+	tprintf("{fe_logical=%" PRI__u64
+		", fe_physical=%" PRI__u64
+		", fe_length=%" PRI__u64 ", ",
+		fe->fe_logical, fe->fe_physical, fe->fe_length);
+
+	printflags64(fiemap_extent_flags, fe->fe_flags,
+		     "FIEMAP_EXTENT_???");
+	tprints("}");
+
+	return true;
+}
+#endif /* HAVE_LINUX_FIEMAP_H */
+
+int
+file_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	switch (code) {
+	case FICLONE:	/* W */
+		tprintf(", %d", (int) arg);
+		break;
+
+	case FICLONERANGE: { /* W */
+		struct file_clone_range args;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{src_fd=");
+		printfd(tcp, args.src_fd);
+		tprintf(", src_offset=%" PRIu64
+			", src_length=%" PRIu64
+			", dest_offset=%" PRIu64 "}",
+			(uint64_t) args.src_offset,
+			(uint64_t) args.src_length,
+			(uint64_t) args.dest_offset);
+		break;
+	}
+
+	case FIDEDUPERANGE: { /* RW */
+		struct file_dedupe_range args;
+		struct file_dedupe_range_info info;
+		unsigned int *limit = NULL;
+		unsigned int count = 2;
+		bool rc;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		tprints("{");
+		if (entering(tcp)) {
+			tprintf("src_offset=%" PRIu64
+				", src_length=%" PRIu64
+				", dest_count=%hu, ",
+				(uint64_t) args.src_offset,
+				(uint64_t) args.src_length,
+				(uint16_t) args.dest_count);
+		}
+
+		tprints("info=");
+
+		/* Limit how many elements we print in abbrev mode. */
+		if (abbrev(tcp) && args.dest_count > count)
+			limit = &count;
+
+		rc = print_array(tcp, arg + offsetof(typeof(args), info),
+				 args.dest_count, &info, sizeof(info),
+				 umoven_or_printaddr,
+				 print_file_dedupe_range_info, limit);
+
+		tprints("}");
+		if (!rc || exiting(tcp))
+			break;
+
+		return 0;
+	}
+
+#ifdef HAVE_LINUX_FIEMAP_H
+	case FS_IOC_FIEMAP: {
+		struct fiemap args;
+
+		if (entering(tcp))
+			tprints(", ");
+		else if (syserror(tcp))
+			break;
+		else
+			tprints(" => ");
+
+		if (umove_or_printaddr(tcp, arg, &args))
+			break;
+
+		if (entering(tcp)) {
+			tprintf("{fm_start=%" PRI__u64 ", "
+				"fm_length=%" PRI__u64 ", "
+				"fm_flags=",
+				args.fm_start, args.fm_length);
+			printflags64(fiemap_flags, args.fm_flags,
+				     "FIEMAP_FLAG_???");
+			tprintf(", fm_extent_count=%u}", args.fm_extent_count);
+			return 0;
+		}
+
+		tprints("{fm_flags=");
+		printflags64(fiemap_flags, args.fm_flags,
+			     "FIEMAP_FLAG_???");
+		tprintf(", fm_mapped_extents=%u",
+			args.fm_mapped_extents);
+		tprints(", fm_extents=");
+		if (abbrev(tcp)) {
+			tprints("...");
+		} else {
+			struct fiemap_extent fe;
+			print_array(tcp,
+				    arg + offsetof(typeof(args), fm_extents),
+				    args.fm_mapped_extents, &fe, sizeof(fe),
+				    umoven_or_printaddr,
+				    print_fiemap_extent, 0);
+		}
+		tprints("}");
+
+		break;
+	}
+#endif /* HAVE_LINUX_FIEMAP_H */
+
+	default:
+		return RVAL_DECODED;
+	};
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/flock.c b/strace/flock.c
new file mode 100644
index 0000000..6ec43db
--- /dev/null
+++ b/strace/flock.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <sys/file.h>
+
+#include "xlat/flockcmds.h"
+
+SYS_FUNC(flock)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printflags(flockcmds, tcp->u_arg[1], "LOCK_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/flock.h b/strace/flock.h
new file mode 100644
index 0000000..b1ab8ff
--- /dev/null
+++ b/strace/flock.h
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <linux/fcntl.h>
+
+#if defined HAVE_STRUCT_FLOCK
+typedef struct flock struct_kernel_flock;
+#elif defined HAVE_STRUCT___KERNEL_FLOCK
+typedef struct __kernel_flock struct_kernel_flock;
+#else
+# error struct flock definition not found in <linux/fcntl.h>
+#endif
+
+#if defined HAVE_STRUCT_FLOCK64
+typedef struct flock64 struct_kernel_flock64;
+#elif defined HAVE_STRUCT___KERNEL_FLOCK64
+typedef struct __kernel_flock64 struct_kernel_flock64;
+#else
+# error struct flock64 definition not found in <linux/fcntl.h>
+#endif
diff --git a/strace/fs_x_ioctl.c b/strace/fs_x_ioctl.c
new file mode 100644
index 0000000..7403e6b
--- /dev/null
+++ b/strace/fs_x_ioctl.c
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2014 Mike Frysinger <vapier@gentoo.org>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <linux/fs.h>
+
+int
+fs_x_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	switch (code) {
+#ifdef FITRIM
+	/* First seen in linux-2.6.37 */
+	case FITRIM: {
+		struct fstrim_range fstrim;
+
+		tprints(", ");
+		if (!umove_or_printaddr(tcp, arg, &fstrim))
+			tprintf("{start=%#" PRIx64
+				", len=%#" PRIx64
+				", minlen=%#" PRIx64 "}",
+				(uint64_t) fstrim.start,
+				(uint64_t) fstrim.len,
+				(uint64_t) fstrim.minlen);
+		break;
+	}
+#endif
+
+	/* No arguments */
+#ifdef FIFREEZE
+	case FIFREEZE:
+	case FITHAW:
+		break;
+#endif
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/fstatfs.c b/strace/fstatfs.c
new file mode 100644
index 0000000..1f35824
--- /dev/null
+++ b/strace/fstatfs.c
@@ -0,0 +1,12 @@
+#include "defs.h"
+
+SYS_FUNC(fstatfs)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_struct_statfs(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/fstatfs64.c b/strace/fstatfs64.c
new file mode 100644
index 0000000..63eb3df
--- /dev/null
+++ b/strace/fstatfs64.c
@@ -0,0 +1,14 @@
+#include "defs.h"
+
+SYS_FUNC(fstatfs64)
+{
+	const unsigned long size = tcp->u_arg[1];
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprintf(", %lu, ", size);
+	} else {
+		print_struct_statfs64(tcp, tcp->u_arg[2], size);
+	}
+	return 0;
+}
diff --git a/strace/futex.c b/strace/futex.c
new file mode 100644
index 0000000..7090c7d
--- /dev/null
+++ b/strace/futex.c
@@ -0,0 +1,116 @@
+/*
+ * Copyright (c) 2002-2003 Roland McGrath  <roland@redhat.com>
+ * Copyright (c) 2007-2008 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2009 Andreas Schwab <schwab@redhat.com>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_LINUX_FUTEX_H
+# include <linux/futex.h>
+#endif
+
+#ifndef FUTEX_PRIVATE_FLAG
+# define FUTEX_PRIVATE_FLAG 128
+#endif
+#ifndef FUTEX_CLOCK_REALTIME
+# define FUTEX_CLOCK_REALTIME 256
+#endif
+
+#include "xlat/futexops.h"
+#include "xlat/futexwakeops.h"
+#include "xlat/futexwakecmps.h"
+
+SYS_FUNC(futex)
+{
+	const long uaddr = tcp->u_arg[0];
+	const int op = tcp->u_arg[1];
+	const int cmd = op & 127;
+	const long timeout = tcp->u_arg[3];
+	const long uaddr2 = tcp->u_arg[4];
+	const unsigned int val = tcp->u_arg[2];
+	const unsigned int val2 = tcp->u_arg[3];
+	const unsigned int val3 = tcp->u_arg[5];
+
+	printaddr(uaddr);
+	tprints(", ");
+	printxval(futexops, op, "FUTEX_???");
+	tprintf(", %u", val);
+	switch (cmd) {
+	case FUTEX_WAIT:
+	case FUTEX_LOCK_PI:
+		tprints(", ");
+		print_timespec(tcp, timeout);
+		break;
+	case FUTEX_WAIT_BITSET:
+		tprints(", ");
+		print_timespec(tcp, timeout);
+		tprintf(", %x", val3);
+		break;
+	case FUTEX_WAKE_BITSET:
+		tprintf(", %x", val3);
+		break;
+	case FUTEX_REQUEUE:
+		tprintf(", %u, ", val2);
+		printaddr(uaddr2);
+		break;
+	case FUTEX_CMP_REQUEUE:
+	case FUTEX_CMP_REQUEUE_PI:
+		tprintf(", %u, ", val2);
+		printaddr(uaddr2);
+		tprintf(", %u", val3);
+		break;
+	case FUTEX_WAKE_OP:
+		tprintf(", %u, ", val2);
+		printaddr(uaddr2);
+		tprints(", {");
+		if ((val3 >> 28) & 8)
+			tprints("FUTEX_OP_OPARG_SHIFT|");
+		printxval(futexwakeops, (val3 >> 28) & 0x7, "FUTEX_OP_???");
+		tprintf(", %u, ", (val3 >> 12) & 0xfff);
+		if ((val3 >> 24) & 8)
+			tprints("FUTEX_OP_OPARG_SHIFT|");
+		printxval(futexwakecmps, (val3 >> 24) & 0x7, "FUTEX_OP_CMP_???");
+		tprintf(", %u}", val3 & 0xfff);
+		break;
+	case FUTEX_WAIT_REQUEUE_PI:
+		tprints(", ");
+		print_timespec(tcp, timeout);
+		tprints(", ");
+		printaddr(uaddr2);
+		break;
+	case FUTEX_WAKE:
+	case FUTEX_UNLOCK_PI:
+	case FUTEX_TRYLOCK_PI:
+		break;
+	default:
+		tprintf(", %lx, %lx, %x", timeout, uaddr2, val3);
+		break;
+	}
+
+	return RVAL_DECODED;
+}
diff --git a/strace/gcc_compat.h b/strace/gcc_compat.h
new file mode 100644
index 0000000..c06d3c1
--- /dev/null
+++ b/strace/gcc_compat.h
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef GCC_COMPAT_H_
+#define GCC_COMPAT_H_
+
+#if defined __GNUC__ && defined __GNUC_MINOR__
+# define GNUC_PREREQ(maj, min)	\
+	((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
+#else
+# define __attribute__(x)	/* empty */
+# define GNUC_PREREQ(maj, min)	0
+#endif
+
+#if GNUC_PREREQ(2, 5)
+# define ATTRIBUTE_NORETURN	__attribute__((__noreturn__))
+#else
+# define ATTRIBUTE_NORETURN	/* empty */
+#endif
+
+#if GNUC_PREREQ(2, 7)
+# define ATTRIBUTE_FORMAT(args)	__attribute__((__format__ args))
+# define ATTRIBUTE_ALIGNED(arg)	__attribute__((__aligned__(arg)))
+# define ATTRIBUTE_PACKED	__attribute__((__packed__))
+#else
+# define ATTRIBUTE_FORMAT(args)	/* empty */
+# define ATTRIBUTE_ALIGNED(arg)	/* empty */
+# define ATTRIBUTE_PACKED	/* empty */
+#endif
+
+#if GNUC_PREREQ(3, 0)
+# define ATTRIBUTE_MALLOC	__attribute__((__malloc__))
+#else
+# define ATTRIBUTE_MALLOC	/* empty */
+#endif
+
+#if GNUC_PREREQ(3, 1)
+# define ATTRIBUTE_NOINLINE	__attribute__((__noinline__))
+#else
+# define ATTRIBUTE_NOINLINE	/* empty */
+#endif
+
+#if GNUC_PREREQ(4, 0)
+# define ATTRIBUTE_SENTINEL	__attribute__((__sentinel__))
+#else
+# define ATTRIBUTE_SENTINEL	/* empty */
+#endif
+
+#if GNUC_PREREQ(4, 3)
+# define ATTRIBUTE_ALLOC_SIZE(args)	__attribute__((__alloc_size__ args))
+#else
+# define ATTRIBUTE_ALLOC_SIZE(args)	/* empty */
+#endif
+
+#endif
diff --git a/strace/generate_mpers_am.sh b/strace/generate_mpers_am.sh
new file mode 100755
index 0000000..1ee4791
--- /dev/null
+++ b/strace/generate_mpers_am.sh
@@ -0,0 +1,13 @@
+#!/bin/sh -e
+
+list="$(sed -n '/^strace_SOURCES[[:space:]]*=/,/^[[:space:]]*# end of strace_SOURCES/ s/^[[:space:]]*\([[:alnum:]][^.]*\.c\)[[:space:]]*\\$/\1/p' Makefile.am |
+	xargs -r grep -lx '#[[:space:]]*include[[:space:]]\+MPERS_DEFS' |
+	tr '\n' ' ')"
+
+cat > mpers.am <<EOF
+# Generated by $0; do not edit.
+mpers_source_files = $list
+EOF
+
+sed -n 's/^#[[:space:]]*include[[:space:]]*"xlat\/\([^."]\+\)\.h".*/extern const struct xlat \1[];/p' \
+	$list > mpers_xlat.h
diff --git a/strace/generate_sen.sh b/strace/generate_sen.sh
new file mode 100755
index 0000000..6c177ab
--- /dev/null
+++ b/strace/generate_sen.sh
@@ -0,0 +1,8 @@
+#!/bin/sh -e
+
+echo 'enum {'
+echo 'SEN_printargs = 0,'
+    sed -n '/printargs/! s/.*SEN(\([^)]*\)).*/\1/p' |
+    sort -u |
+    sed 's/.*/SEN_&,/'
+echo '};'
diff --git a/strace/get_robust_list.c b/strace/get_robust_list.c
new file mode 100644
index 0000000..1977023
--- /dev/null
+++ b/strace/get_robust_list.c
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2012-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+SYS_FUNC(get_robust_list)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+	} else {
+		printnum_ptr(tcp, tcp->u_arg[1]);
+		tprints(", ");
+		printnum_ulong(tcp, tcp->u_arg[2]);
+	}
+	return 0;
+}
diff --git a/strace/getcpu.c b/strace/getcpu.c
new file mode 100644
index 0000000..5d0f52d
--- /dev/null
+++ b/strace/getcpu.c
@@ -0,0 +1,13 @@
+#include "defs.h"
+
+SYS_FUNC(getcpu)
+{
+	if (exiting(tcp)) {
+		printnum_int(tcp, tcp->u_arg[0], "%u");
+		tprints(", ");
+		printnum_int(tcp, tcp->u_arg[1], "%u");
+		tprints(", ");
+		printaddr(tcp->u_arg[2]);
+	}
+	return 0;
+}
diff --git a/strace/getcwd.c b/strace/getcwd.c
new file mode 100644
index 0000000..3297623
--- /dev/null
+++ b/strace/getcwd.c
@@ -0,0 +1,13 @@
+#include "defs.h"
+
+SYS_FUNC(getcwd)
+{
+	if (exiting(tcp)) {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[0]);
+		else
+			printpathn(tcp, tcp->u_arg[0], tcp->u_rval - 1);
+		tprintf(", %lu", tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/getrandom.c b/strace/getrandom.c
new file mode 100644
index 0000000..c82b3b7
--- /dev/null
+++ b/strace/getrandom.c
@@ -0,0 +1,15 @@
+#include "defs.h"
+#include "xlat/getrandom_flags.h"
+
+SYS_FUNC(getrandom)
+{
+	if (exiting(tcp)) {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[0]);
+		else
+			printstr(tcp, tcp->u_arg[0], tcp->u_rval);
+		tprintf(", %lu, ", tcp->u_arg[1]);
+		printflags(getrandom_flags, tcp->u_arg[2], "GRND_???");
+	}
+	return 0;
+}
diff --git a/strace/git-set-file-times b/strace/git-set-file-times
new file mode 100755
index 0000000..077ac0e
--- /dev/null
+++ b/strace/git-set-file-times
@@ -0,0 +1,37 @@
+#!/usr/bin/perl
+use strict;
+use warnings;
+
+# Sets mtime and atime of files to the latest commit time in git.
+#
+# This is useful after the first clone of the rsync repository BEFORE you
+# do any building.  It is also safe if you have done a "make distclean".
+
+my %ls;
+my $commit_time;
+my $prefix = @ARGV && $ARGV[0] =~ s/^--prefix=// ? shift : '';
+
+$/ = "\0";
+open FH, 'git ls-files -z|' or die $!;
+while (<FH>) {
+    chomp;
+    $ls{$_} = $_;
+}
+close FH;
+
+$/ = "\n";
+open FH, "git log -r --name-only --no-color --pretty=raw -z @ARGV |" or die $!;
+while (<FH>) {
+    chomp;
+    if (/^committer .*? (\d+) (?:[\-\+]\d+)$/) {
+	$commit_time = $1;
+    } elsif (s/\0\0commit [a-f0-9]{40}$// or s/\0$//) {
+	my @files = delete @ls{split(/\0/, $_)};
+	@files = grep { defined $_ } @files;
+	next unless @files;
+	map { s/^/$prefix/ } @files;
+	utime $commit_time, $commit_time, @files;
+    }
+    last unless %ls;
+}
+close FH;
diff --git a/strace/git-version-gen b/strace/git-version-gen
new file mode 100755
index 0000000..28e9109
--- /dev/null
+++ b/strace/git-version-gen
@@ -0,0 +1,227 @@
+#!/bin/sh
+# Print a version string.
+scriptversion=2014-12-02.19; # UTC
+
+# Copyright (C) 2007-2014 Free Software Foundation, Inc.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# This script is derived from GIT-VERSION-GEN from GIT: http://git.or.cz/.
+# It may be run two ways:
+# - from a git repository in which the "git describe" command below
+#   produces useful output (thus requiring at least one signed tag)
+# - from a non-git-repo directory containing a .tarball-version file, which
+#   presumes this script is invoked like "./git-version-gen .tarball-version".
+
+# In order to use intra-version strings in your project, you will need two
+# separate generated version string files:
+#
+# .tarball-version - present only in a distribution tarball, and not in
+#   a checked-out repository.  Created with contents that were learned at
+#   the last time autoconf was run, and used by git-version-gen.  Must not
+#   be present in either $(srcdir) or $(builddir) for git-version-gen to
+#   give accurate answers during normal development with a checked out tree,
+#   but must be present in a tarball when there is no version control system.
+#   Therefore, it cannot be used in any dependencies.  GNUmakefile has
+#   hooks to force a reconfigure at distribution time to get the value
+#   correct, without penalizing normal development with extra reconfigures.
+#
+# .version - present in a checked-out repository and in a distribution
+#   tarball.  Usable in dependencies, particularly for files that don't
+#   want to depend on config.h but do want to track version changes.
+#   Delete this file prior to any autoconf run where you want to rebuild
+#   files to pick up a version string change; and leave it stale to
+#   minimize rebuild time after unrelated changes to configure sources.
+#
+# As with any generated file in a VC'd directory, you should add
+# /.version to .gitignore, so that you don't accidentally commit it.
+# .tarball-version is never generated in a VC'd directory, so needn't
+# be listed there.
+#
+# Use the following line in your configure.ac, so that $(VERSION) will
+# automatically be up-to-date each time configure is run (and note that
+# since configure.ac no longer includes a version string, Makefile rules
+# should not depend on configure.ac for version updates).
+#
+# AC_INIT([GNU project],
+#         m4_esyscmd([build-aux/git-version-gen .tarball-version]),
+#         [bug-project@example])
+#
+# Then use the following lines in your Makefile.am, so that .version
+# will be present for dependencies, and so that .version and
+# .tarball-version will exist in distribution tarballs.
+#
+# EXTRA_DIST = $(top_srcdir)/.version
+# BUILT_SOURCES = $(top_srcdir)/.version
+# $(top_srcdir)/.version:
+#	echo $(VERSION) > $@-t && mv $@-t $@
+# dist-hook:
+#	echo $(VERSION) > $(distdir)/.tarball-version
+
+
+me=$0
+
+version="git-version-gen $scriptversion
+
+Copyright 2011 Free Software Foundation, Inc.
+There is NO warranty.  You may redistribute this software
+under the terms of the GNU General Public License.
+For more information about these matters, see the files named COPYING."
+
+usage="\
+Usage: $me [OPTION]... \$srcdir/.tarball-version [TAG-NORMALIZATION-SED-SCRIPT]
+Print a version string.
+
+Options:
+
+   --prefix PREFIX    prefix of git tags (default 'v')
+   --fallback VERSION
+                      fallback version to use if \"git --version\" fails
+
+   --help             display this help and exit
+   --version          output version information and exit
+
+Running without arguments will suffice in most cases."
+
+prefix=v
+fallback=
+
+while test $# -gt 0; do
+  case $1 in
+    --help) echo "$usage"; exit 0;;
+    --version) echo "$version"; exit 0;;
+    --prefix) shift; prefix="$1";;
+    --fallback) shift; fallback="$1";;
+    -*)
+      echo "$0: Unknown option '$1'." >&2
+      echo "$0: Try '--help' for more information." >&2
+      exit 1;;
+    *)
+      if test "x$tarball_version_file" = x; then
+        tarball_version_file="$1"
+      elif test "x$tag_sed_script" = x; then
+        tag_sed_script="$1"
+      else
+        echo "$0: extra non-option argument '$1'." >&2
+        exit 1
+      fi;;
+  esac
+  shift
+done
+
+if test "x$tarball_version_file" = x; then
+    echo "$usage"
+    exit 1
+fi
+
+tag_sed_script="${tag_sed_script:-s/x/x/}"
+
+nl='
+'
+
+# Avoid meddling by environment variable of the same name.
+v=
+v_from_git=
+
+# First see if there is a tarball-only version file.
+# then try "git describe", then default.
+if test -f $tarball_version_file
+then
+    v=`cat $tarball_version_file` || v=
+    case $v in
+        *$nl*) v= ;; # reject multi-line output
+        [0-9]*) ;;
+        *) v= ;;
+    esac
+    test "x$v" = x \
+        && echo "$0: WARNING: $tarball_version_file is missing or damaged" 1>&2
+fi
+
+if test "x$v" != x
+then
+    : # use $v
+# Otherwise, if there is at least one git commit involving the working
+# directory, and "git describe" output looks sensible, use that to
+# derive a version string.
+elif test "`git log -1 --pretty=format:x . 2>&1`" = x \
+    && v=`git describe --abbrev=4 --match="$prefix*" HEAD 2>/dev/null \
+          || git describe --abbrev=4 HEAD 2>/dev/null` \
+    && v=`printf '%s\n' "$v" | sed "$tag_sed_script"` \
+    && case $v in
+         $prefix[0-9]*) ;;
+         *) (exit 1) ;;
+       esac
+then
+    # Is this a new git that lists number of commits since the last
+    # tag or the previous older version that did not?
+    #   Newer: v6.10-77-g0f8faeb
+    #   Older: v6.10-g0f8faeb
+    case $v in
+        *-*-*) : git describe is okay three part flavor ;;
+        *-*)
+            : git describe is older two part flavor
+            # Recreate the number of commits and rewrite such that the
+            # result is the same as if we were using the newer version
+            # of git describe.
+            vtag=`echo "$v" | sed 's/-.*//'`
+            commit_list=`git rev-list "$vtag"..HEAD 2>/dev/null` \
+                || { commit_list=failed;
+                     echo "$0: WARNING: git rev-list failed" 1>&2; }
+            numcommits=`echo "$commit_list" | wc -l`
+            v=`echo "$v" | sed "s/\(.*\)-\(.*\)/\1-$numcommits-\2/"`;
+            test "$commit_list" = failed && v=UNKNOWN
+            ;;
+    esac
+
+    # Change the first '-' to a '.', so version-comparing tools work properly.
+    # Remove the "g" in git describe's output string, to save a byte.
+    # Change remaining '-' to '.', so version conforms to policies.
+    v=`echo "$v" | sed 's/-/.0./;s/\(.*\)-g/\1-/;s/-/./g'`;
+    v_from_git=1
+elif test "x$fallback" = x || git --version >/dev/null 2>&1; then
+    v=UNKNOWN
+else
+    v=$fallback
+fi
+
+v=`echo "$v" |sed "s/^$prefix//"`
+
+# Test whether to append the "-dirty" suffix only if the version
+# string we're using came from git.  I.e., skip the test if it's "UNKNOWN"
+# or if it came from .tarball-version.
+if test "x$v_from_git" != x; then
+  # Don't declare a version "dirty" merely because a time stamp has changed.
+  git update-index --refresh > /dev/null 2>&1
+
+  dirty=`exec 2>/dev/null;git diff-index --name-only HEAD` || dirty=
+  case "$dirty" in
+      '') ;;
+      *) # Append the suffix only if there isn't one already.
+          case $v in
+            *-dirty) ;;
+            *) v="$v-dirty" ;;
+          esac ;;
+  esac
+fi
+
+# Omit the trailing newline, so that m4_esyscmd can use the result directly.
+printf %s "$v"
+
+# Local variables:
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "scriptversion="
+# time-stamp-format: "%:y-%02m-%02d.%02H"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
+# End:
diff --git a/strace/gitlog-to-changelog b/strace/gitlog-to-changelog
new file mode 100755
index 0000000..190f7b5
--- /dev/null
+++ b/strace/gitlog-to-changelog
@@ -0,0 +1,437 @@
+eval '(exit $?0)' && eval 'exec perl -wS "$0" ${1+"$@"}'
+  & eval 'exec perl -wS "$0" $argv:q'
+    if 0;
+# Convert git log output to ChangeLog format.
+
+my $VERSION = '2014-11-20 17:25'; # UTC
+# The definition above must lie within the first 8 lines in order
+# for the Emacs time-stamp write hook (at end) to update it.
+# If you change this file with Emacs, please let the write hook
+# do its job.  Otherwise, update this string manually.
+
+# Copyright (C) 2008-2014 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# Written by Jim Meyering
+
+use strict;
+use warnings;
+use Getopt::Long;
+use POSIX qw(strftime);
+
+(my $ME = $0) =~ s|.*/||;
+
+# use File::Coda; # http://meyering.net/code/Coda/
+END {
+  defined fileno STDOUT or return;
+  close STDOUT and return;
+  warn "$ME: failed to close standard output: $!\n";
+  $? ||= 1;
+}
+
+sub usage ($)
+{
+  my ($exit_code) = @_;
+  my $STREAM = ($exit_code == 0 ? *STDOUT : *STDERR);
+  if ($exit_code != 0)
+    {
+      print $STREAM "Try '$ME --help' for more information.\n";
+    }
+  else
+    {
+      print $STREAM <<EOF;
+Usage: $ME [OPTIONS] [ARGS]
+
+Convert git log output to ChangeLog format.  If present, any ARGS
+are passed to "git log".  To avoid ARGS being parsed as options to
+$ME, they may be preceded by '--'.
+
+OPTIONS:
+
+   --amend=FILE FILE maps from an SHA1 to perl code (i.e., s/old/new/) that
+                  makes a change to SHA1's commit log text or metadata.
+   --append-dot append a dot to the first line of each commit message if
+                  there is no other punctuation or blank at the end.
+   --no-cluster never cluster commit messages under the same date/author
+                  header; the default is to cluster adjacent commit messages
+                  if their headers are the same and neither commit message
+                  contains multiple paragraphs.
+   --srcdir=DIR the root of the source tree, from which the .git/
+                  directory can be derived.
+   --since=DATE convert only the logs since DATE;
+                  the default is to convert all log entries.
+   --until=DATE convert only the logs older than DATE.
+   --format=FMT set format string for commit subject and body;
+                  see 'man git-log' for the list of format metacharacters;
+                  the default is '%s%n%b%n'
+   --strip-tab  remove one additional leading TAB from commit message lines.
+   --strip-cherry-pick  remove data inserted by "git cherry-pick";
+                  this includes the "cherry picked from commit ..." line,
+                  and the possible final "Conflicts:" paragraph.
+   --help       display this help and exit
+   --version    output version information and exit
+
+EXAMPLE:
+
+  $ME --since=2008-01-01 > ChangeLog
+  $ME -- -n 5 foo > last-5-commits-to-branch-foo
+
+SPECIAL SYNTAX:
+
+The following types of strings are interpreted specially when they appear
+at the beginning of a log message line.  They are not copied to the output.
+
+  Copyright-paperwork-exempt: Yes
+    Append the "(tiny change)" notation to the usual "date name email"
+    ChangeLog header to mark a change that does not require a copyright
+    assignment.
+  Co-authored-by: Joe User <user\@example.com>
+    List the specified name and email address on a second
+    ChangeLog header, denoting a co-author.
+  Signed-off-by: Joe User <user\@example.com>
+    These lines are simply elided.
+
+In a FILE specified via --amend, comment lines (starting with "#") are ignored.
+FILE must consist of <SHA,CODE+> pairs where SHA is a 40-byte SHA1 (alone on
+a line) referring to a commit in the current project, and CODE refers to one
+or more consecutive lines of Perl code.  Pairs must be separated by one or
+more blank line.
+
+Here is sample input for use with --amend=FILE, from coreutils:
+
+3a169f4c5d9159283548178668d2fae6fced3030
+# fix typo in title:
+s/all tile types/all file types/
+
+1379ed974f1fa39b12e2ffab18b3f7a607082202
+# Due to a bug in vc-dwim, I mis-attributed a patch by Paul to myself.
+# Change the author to be Paul.  Note the escaped "@":
+s,Jim .*>,Paul Eggert <eggert\\\@cs.ucla.edu>,
+
+EOF
+    }
+  exit $exit_code;
+}
+
+# If the string $S is a well-behaved file name, simply return it.
+# If it contains white space, quotes, etc., quote it, and return the new string.
+sub shell_quote($)
+{
+  my ($s) = @_;
+  if ($s =~ m![^\w+/.,-]!)
+    {
+      # Convert each single quote to '\''
+      $s =~ s/\'/\'\\\'\'/g;
+      # Then single quote the string.
+      $s = "'$s'";
+    }
+  return $s;
+}
+
+sub quoted_cmd(@)
+{
+  return join (' ', map {shell_quote $_} @_);
+}
+
+# Parse file F.
+# Comment lines (starting with "#") are ignored.
+# F must consist of <SHA,CODE+> pairs where SHA is a 40-byte SHA1
+# (alone on a line) referring to a commit in the current project, and
+# CODE refers to one or more consecutive lines of Perl code.
+# Pairs must be separated by one or more blank line.
+sub parse_amend_file($)
+{
+  my ($f) = @_;
+
+  open F, '<', $f
+    or die "$ME: $f: failed to open for reading: $!\n";
+
+  my $fail;
+  my $h = {};
+  my $in_code = 0;
+  my $sha;
+  while (defined (my $line = <F>))
+    {
+      $line =~ /^\#/
+        and next;
+      chomp $line;
+      $line eq ''
+        and $in_code = 0, next;
+
+      if (!$in_code)
+        {
+          $line =~ /^([0-9a-fA-F]{40})$/
+            or (warn "$ME: $f:$.: invalid line; expected an SHA1\n"),
+              $fail = 1, next;
+          $sha = lc $1;
+          $in_code = 1;
+          exists $h->{$sha}
+            and (warn "$ME: $f:$.: duplicate SHA1\n"),
+              $fail = 1, next;
+        }
+      else
+        {
+          $h->{$sha} ||= '';
+          $h->{$sha} .= "$line\n";
+        }
+    }
+  close F;
+
+  $fail
+    and exit 1;
+
+  return $h;
+}
+
+# git_dir_option $SRCDIR
+#
+# From $SRCDIR, the --git-dir option to pass to git (none if $SRCDIR
+# is undef).  Return as a list (0 or 1 element).
+sub git_dir_option($)
+{
+  my ($srcdir) = @_;
+  my @res = ();
+  if (defined $srcdir)
+    {
+      my $qdir = shell_quote $srcdir;
+      my $cmd = "cd $qdir && git rev-parse --show-toplevel";
+      my $qcmd = shell_quote $cmd;
+      my $git_dir = qx($cmd);
+      defined $git_dir
+        or die "$ME: cannot run $qcmd: $!\n";
+      $? == 0
+        or die "$ME: $qcmd had unexpected exit code or signal ($?)\n";
+      chomp $git_dir;
+      push @res, "--git-dir=$git_dir/.git";
+    }
+  @res;
+}
+
+{
+  my $since_date;
+  my $until_date;
+  my $format_string = '%s%n%b%n';
+  my $amend_file;
+  my $append_dot = 0;
+  my $cluster = 1;
+  my $strip_tab = 0;
+  my $strip_cherry_pick = 0;
+  my $srcdir;
+  GetOptions
+    (
+     help => sub { usage 0 },
+     version => sub { print "$ME version $VERSION\n"; exit },
+     'since=s' => \$since_date,
+     'until=s' => \$until_date,
+     'format=s' => \$format_string,
+     'amend=s' => \$amend_file,
+     'append-dot' => \$append_dot,
+     'cluster!' => \$cluster,
+     'strip-tab' => \$strip_tab,
+     'strip-cherry-pick' => \$strip_cherry_pick,
+     'srcdir=s' => \$srcdir,
+    ) or usage 1;
+
+  defined $since_date
+    and unshift @ARGV, "--since=$since_date";
+  defined $until_date
+    and unshift @ARGV, "--until=$until_date";
+
+  # This is a hash that maps an SHA1 to perl code (i.e., s/old/new/)
+  # that makes a correction in the log or attribution of that commit.
+  my $amend_code = defined $amend_file ? parse_amend_file $amend_file : {};
+
+  my @cmd = ('git',
+             git_dir_option $srcdir,
+             qw(log --log-size),
+             '--pretty=format:%H:%ct  %an  <%ae>%n%n'.$format_string, @ARGV);
+  open PIPE, '-|', @cmd
+    or die ("$ME: failed to run '". quoted_cmd (@cmd) ."': $!\n"
+            . "(Is your Git too old?  Version 1.5.1 or later is required.)\n");
+
+  my $prev_multi_paragraph;
+  my $prev_date_line = '';
+  my @prev_coauthors = ();
+  while (1)
+    {
+      defined (my $in = <PIPE>)
+        or last;
+      $in =~ /^log size (\d+)$/
+        or die "$ME:$.: Invalid line (expected log size):\n$in";
+      my $log_nbytes = $1;
+
+      my $log;
+      my $n_read = read PIPE, $log, $log_nbytes;
+      $n_read == $log_nbytes
+        or die "$ME:$.: unexpected EOF\n";
+
+      # Extract leading hash.
+      my ($sha, $rest) = split ':', $log, 2;
+      defined $sha
+        or die "$ME:$.: malformed log entry\n";
+      $sha =~ /^[0-9a-fA-F]{40}$/
+        or die "$ME:$.: invalid SHA1: $sha\n";
+
+      # If this commit's log requires any transformation, do it now.
+      my $code = $amend_code->{$sha};
+      if (defined $code)
+        {
+          eval 'use Safe';
+          my $s = new Safe;
+          # Put the unpreprocessed entry into "$_".
+          $_ = $rest;
+
+          # Let $code operate on it, safely.
+          my $r = $s->reval("$code")
+            or die "$ME:$.:$sha: failed to eval \"$code\":\n$@\n";
+
+          # Note that we've used this entry.
+          delete $amend_code->{$sha};
+
+          # Update $rest upon success.
+          $rest = $_;
+        }
+
+      # Remove lines inserted by "git cherry-pick".
+      if ($strip_cherry_pick)
+        {
+          $rest =~ s/^\s*Conflicts:\n.*//sm;
+          $rest =~ s/^\s*\(cherry picked from commit [\da-f]+\)\n//m;
+        }
+
+      my @line = split "\n", $rest;
+      my $author_line = shift @line;
+      defined $author_line
+        or die "$ME:$.: unexpected EOF\n";
+      $author_line =~ /^(\d+)  (.*>)$/
+        or die "$ME:$.: Invalid line "
+          . "(expected date/author/email):\n$author_line\n";
+
+      # Format 'Copyright-paperwork-exempt: Yes' as a standard ChangeLog
+      # `(tiny change)' annotation.
+      my $tiny = (grep (/^Copyright-paperwork-exempt:\s+[Yy]es$/, @line)
+                  ? '  (tiny change)' : '');
+
+      my $date_line = sprintf "%s  %s$tiny\n",
+        strftime ("%F", localtime ($1)), $2;
+
+      my @coauthors = grep /^Co-authored-by:.*$/, @line;
+      # Omit meta-data lines we've already interpreted.
+      @line = grep !/^(?:Signed-off-by:[ ].*>$
+                       |Co-authored-by:[ ]
+                       |Copyright-paperwork-exempt:[ ]
+                       )/x, @line;
+
+      # Remove leading and trailing blank lines.
+      if (@line)
+        {
+          while ($line[0] =~ /^\s*$/) { shift @line; }
+          while ($line[$#line] =~ /^\s*$/) { pop @line; }
+        }
+
+      # Record whether there are two or more paragraphs.
+      my $multi_paragraph = grep /^\s*$/, @line;
+
+      # Format 'Co-authored-by: A U Thor <email@example.com>' lines in
+      # standard multi-author ChangeLog format.
+      for (@coauthors)
+        {
+          s/^Co-authored-by:\s*/\t    /;
+          s/\s*</  </;
+
+          /<.*?@.*\..*>/
+            or warn "$ME: warning: missing email address for "
+              . substr ($_, 5) . "\n";
+        }
+
+      # If clustering of commit messages has been disabled, if this header
+      # would be different from the previous date/name/email/coauthors header,
+      # or if this or the previous entry consists of two or more paragraphs,
+      # then print the header.
+      if ( ! $cluster
+          || $date_line ne $prev_date_line
+          || "@coauthors" ne "@prev_coauthors"
+          || $multi_paragraph
+          || $prev_multi_paragraph)
+        {
+          $prev_date_line eq ''
+            or print "\n";
+          print $date_line;
+          @coauthors
+            and print join ("\n", @coauthors), "\n";
+        }
+      $prev_date_line = $date_line;
+      @prev_coauthors = @coauthors;
+      $prev_multi_paragraph = $multi_paragraph;
+
+      # If there were any lines
+      if (@line == 0)
+        {
+          warn "$ME: warning: empty commit message:\n  $date_line\n";
+        }
+      else
+        {
+          if ($append_dot)
+            {
+              # If the first line of the message has enough room, then
+              if (length $line[0] < 72)
+                {
+                  # append a dot if there is no other punctuation or blank
+                  # at the end.
+                  $line[0] =~ /[[:punct:]\s]$/
+                    or $line[0] .= '.';
+                }
+            }
+
+          # Remove one additional leading TAB from each line.
+          $strip_tab
+            and map { s/^\t// } @line;
+
+          # Prefix each non-empty line with a TAB.
+          @line = map { length $_ ? "\t$_" : '' } @line;
+
+          print "\n", join ("\n", @line), "\n";
+        }
+
+      defined ($in = <PIPE>)
+        or last;
+      $in ne "\n"
+        and die "$ME:$.: unexpected line:\n$in";
+    }
+
+  close PIPE
+    or die "$ME: error closing pipe from " . quoted_cmd (@cmd) . "\n";
+  # FIXME-someday: include $PROCESS_STATUS in the diagnostic
+
+  # Complain about any unused entry in the --amend=F specified file.
+  my $fail = 0;
+  foreach my $sha (keys %$amend_code)
+    {
+      warn "$ME:$amend_file: unused entry: $sha\n";
+      $fail = 1;
+    }
+
+  exit $fail;
+}
+
+# Local Variables:
+# mode: perl
+# indent-tabs-mode: nil
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "my $VERSION = '"
+# time-stamp-format: "%:y-%02m-%02d %02H:%02M"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "'; # UTC"
+# End:
diff --git a/strace/hdio.c b/strace/hdio.c
new file mode 100644
index 0000000..e9dbdf1
--- /dev/null
+++ b/strace/hdio.c
@@ -0,0 +1,64 @@
+/*
+ * Copyright (c) 2009, 2010 Jeff Mahoney <jeffm@suse.com>
+ * Copyright (c) 2011-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_hd_geometry)
+
+#include <linux/hdreg.h>
+
+typedef struct hd_geometry struct_hd_geometry;
+
+#include MPERS_DEFS
+
+MPERS_PRINTER_DECL(int, hdio_ioctl, struct tcb *tcp,
+		   const unsigned int code, const long arg)
+{
+	switch (code) {
+	case HDIO_GETGEO:
+		if (entering(tcp))
+			return 0;
+		else {
+			struct_hd_geometry geo;
+
+			tprints(", ");
+			if (!umove_or_printaddr(tcp, arg, &geo))
+				tprintf("{heads=%u, sectors=%u, "
+					"cylinders=%hu, start=%lu}",
+					(unsigned) geo.heads,
+					(unsigned) geo.sectors,
+					geo.cylinders,
+					(unsigned long) geo.start);
+		}
+		break;
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/hostname.c b/strace/hostname.c
new file mode 100644
index 0000000..c64d954
--- /dev/null
+++ b/strace/hostname.c
@@ -0,0 +1,23 @@
+#include "defs.h"
+
+SYS_FUNC(sethostname)
+{
+	printstr(tcp, tcp->u_arg[0], tcp->u_arg[1]);
+	tprintf(", %lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+#if defined(ALPHA)
+SYS_FUNC(gethostname)
+{
+	if (exiting(tcp)) {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[0]);
+		else
+			printstr(tcp, tcp->u_arg[0], -1);
+		tprintf(", %lu", tcp->u_arg[1]);
+	}
+	return 0;
+}
+#endif /* ALPHA */
diff --git a/strace/inotify.c b/strace/inotify.c
new file mode 100644
index 0000000..5ada8a8
--- /dev/null
+++ b/strace/inotify.c
@@ -0,0 +1,64 @@
+/*
+ * Copyright (c) 2006 Bernhard Kaindl <bk@suse.de>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+
+#include "xlat/inotify_flags.h"
+#include "xlat/inotify_init_flags.h"
+
+SYS_FUNC(inotify_add_watch)
+{
+	/* file descriptor */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* pathname */
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	/* mask */
+	printflags(inotify_flags, tcp->u_arg[2], "IN_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(inotify_rm_watch)
+{
+	/* file descriptor */
+	printfd(tcp, tcp->u_arg[0]);
+	/* watch descriptor */
+	tprintf(", %d", (int) tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(inotify_init1)
+{
+	printflags(inotify_init_flags, tcp->u_arg[0], "IN_???");
+
+	return RVAL_DECODED | RVAL_FD;
+}
diff --git a/strace/io.c b/strace/io.c
new file mode 100644
index 0000000..58323a7
--- /dev/null
+++ b/strace/io.c
@@ -0,0 +1,338 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <fcntl.h>
+#include <sys/uio.h>
+
+SYS_FUNC(read)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[1]);
+		else
+			printstr(tcp, tcp->u_arg[1], tcp->u_rval);
+		tprintf(", %lu", tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(write)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+struct print_iovec_config {
+	enum iov_decode decode_iov;
+	unsigned long data_size;
+};
+
+static bool
+print_iovec(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const unsigned long *iov;
+	unsigned long iov_buf[2], len;
+	struct print_iovec_config *c = data;
+
+        if (elem_size < sizeof(iov_buf)) {
+		iov_buf[0] = ((unsigned int *) elem_buf)[0];
+		iov_buf[1] = ((unsigned int *) elem_buf)[1];
+		iov = iov_buf;
+	} else {
+		iov = elem_buf;
+	}
+
+	tprints("{iov_base=");
+
+	len = iov[1];
+
+	switch (c->decode_iov) {
+		case IOV_DECODE_STR:
+			if (len > c->data_size)
+				len = c->data_size;
+			c->data_size -= len;
+			printstr(tcp, iov[0], len);
+			break;
+		case IOV_DECODE_NETLINK:
+			if (len > c->data_size)
+				len = c->data_size;
+			c->data_size -= len;
+			decode_netlink(tcp, iov[0], iov[1]);
+			break;
+		default:
+			printaddr(iov[0]);
+			break;
+	}
+
+	tprintf(", iov_len=%lu}", iov[1]);
+
+	return true;
+}
+
+/*
+ * data_size limits the cumulative size of printed data.
+ * Example: recvmsg returing a short read.
+ */
+void
+tprint_iov_upto(struct tcb *tcp, unsigned long len, unsigned long addr,
+		enum iov_decode decode_iov, unsigned long data_size)
+{
+	unsigned long iov[2];
+	struct print_iovec_config config =
+		{ .decode_iov = decode_iov, .data_size = data_size };
+
+	print_array(tcp, addr, len, iov, current_wordsize * 2,
+		    umoven_or_printaddr, print_iovec, &config);
+}
+
+void
+tprint_iov(struct tcb *tcp, unsigned long len, unsigned long addr,
+	   enum iov_decode decode_iov)
+{
+	tprint_iov_upto(tcp, len, addr, decode_iov, (unsigned long) -1L);
+}
+
+SYS_FUNC(readv)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		tprint_iov_upto(tcp, tcp->u_arg[2], tcp->u_arg[1],
+				IOV_DECODE_STR, tcp->u_rval);
+		tprintf(", %lu", tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(writev)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	tprint_iov(tcp, tcp->u_arg[2], tcp->u_arg[1], IOV_DECODE_STR);
+	tprintf(", %lu", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+/* The SH4 ABI does allow long longs in odd-numbered registers, but
+   does not allow them to be split between registers and memory - and
+   there are only four argument registers for normal functions.  As a
+   result pread takes an extra padding argument before the offset.  This
+   was changed late in the 2.4 series (around 2.4.20).  */
+#if defined(SH)
+#define PREAD_OFFSET_ARG 4
+#else
+#define PREAD_OFFSET_ARG 3
+#endif
+
+SYS_FUNC(pread)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[1]);
+		else
+			printstr(tcp, tcp->u_arg[1], tcp->u_rval);
+		tprintf(", %lu, ", tcp->u_arg[2]);
+		printllval(tcp, "%lld", PREAD_OFFSET_ARG);
+	}
+	return 0;
+}
+
+SYS_FUNC(pwrite)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu, ", tcp->u_arg[2]);
+	printllval(tcp, "%lld", PREAD_OFFSET_ARG);
+
+	return RVAL_DECODED;
+}
+
+static void
+print_lld_from_low_high_val(struct tcb *tcp, int arg)
+{
+#if SIZEOF_LONG > 4 && SIZEOF_LONG == SIZEOF_LONG_LONG
+# if SUPPORTED_PERSONALITIES > 1
+#  ifdef X86_64
+	if (current_personality != 1)
+#  else
+	if (current_wordsize == sizeof(long))
+#  endif
+# endif
+		tprintf("%ld", tcp->u_arg[arg]);
+# if SUPPORTED_PERSONALITIES > 1
+	else
+		tprintf("%ld",
+			((unsigned long) tcp->u_arg[arg + 1] << current_wordsize * 8)
+			| (unsigned long) tcp->u_arg[arg]);
+# endif
+#elif SIZEOF_LONG > 4
+# error Unsupported configuration: SIZEOF_LONG > 4 && SIZEOF_LONG_LONG > SIZEOF_LONG
+#elif HAVE_STRUCT_TCB_EXT_ARG
+# if SUPPORTED_PERSONALITIES > 1
+	if (current_personality == 1) {
+		tprintf("%lld",
+			(widen_to_ull(tcp->u_arg[arg + 1]) << sizeof(long) * 8)
+			| widen_to_ull(tcp->u_arg[arg]));
+	} else
+# endif
+	{
+		tprintf("%lld", tcp->ext_arg[arg]);
+	}
+#else /* SIZEOF_LONG_LONG > SIZEOF_LONG && !HAVE_STRUCT_TCB_EXT_ARG */
+	tprintf("%lld",
+		(widen_to_ull(tcp->u_arg[arg + 1]) << sizeof(long) * 8)
+		| widen_to_ull(tcp->u_arg[arg]));
+#endif
+}
+
+#include "xlat/rwf_flags.h"
+
+static int
+do_preadv(struct tcb *tcp, const int flags_arg)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		tprint_iov_upto(tcp, tcp->u_arg[2], tcp->u_arg[1], IOV_DECODE_STR,
+				tcp->u_rval);
+		tprintf(", %lu, ", tcp->u_arg[2]);
+		print_lld_from_low_high_val(tcp, 3);
+		if (flags_arg >= 0) {
+			tprints(", ");
+			printflags(rwf_flags, tcp->u_arg[flags_arg], "RWF_???");
+		}
+	}
+	return 0;
+}
+
+SYS_FUNC(preadv)
+{
+	return do_preadv(tcp, -1);
+}
+
+SYS_FUNC(preadv2)
+{
+	return do_preadv(tcp, 5);
+}
+
+static int
+do_pwritev(struct tcb *tcp, const int flags_arg)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	tprint_iov(tcp, tcp->u_arg[2], tcp->u_arg[1], IOV_DECODE_STR);
+	tprintf(", %lu, ", tcp->u_arg[2]);
+	print_lld_from_low_high_val(tcp, 3);
+	if (flags_arg >= 0) {
+		tprints(", ");
+		printflags(rwf_flags, tcp->u_arg[flags_arg], "RWF_???");
+	}
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(pwritev)
+{
+	return do_pwritev(tcp, -1);
+}
+
+SYS_FUNC(pwritev2)
+{
+	return do_pwritev(tcp, 5);
+}
+
+#include "xlat/splice_flags.h"
+
+SYS_FUNC(tee)
+{
+	/* int fd_in */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* int fd_out */
+	printfd(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	/* size_t len */
+	tprintf("%lu, ", tcp->u_arg[2]);
+	/* unsigned int flags */
+	printflags(splice_flags, tcp->u_arg[3], "SPLICE_F_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(splice)
+{
+	/* int fd_in */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* loff_t *off_in */
+	printnum_int64(tcp, tcp->u_arg[1], "%" PRId64);
+	tprints(", ");
+	/* int fd_out */
+	printfd(tcp, tcp->u_arg[2]);
+	tprints(", ");
+	/* loff_t *off_out */
+	printnum_int64(tcp, tcp->u_arg[3], "%" PRId64);
+	tprints(", ");
+	/* size_t len */
+	tprintf("%lu, ", tcp->u_arg[4]);
+	/* unsigned int flags */
+	printflags(splice_flags, tcp->u_arg[5], "SPLICE_F_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(vmsplice)
+{
+	/* int fd */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* const struct iovec *iov, unsigned long nr_segs */
+	tprint_iov(tcp, tcp->u_arg[2], tcp->u_arg[1], IOV_DECODE_STR);
+	tprintf(", %lu, ", tcp->u_arg[2]);
+	/* unsigned int flags */
+	printflags(splice_flags, tcp->u_arg[3], "SPLICE_F_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ioctl.c b/strace/ioctl.c
new file mode 100644
index 0000000..e4b20d9
--- /dev/null
+++ b/strace/ioctl.c
@@ -0,0 +1,330 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-2001 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <linux/ioctl.h>
+#include "xlat/ioctl_dirs.h"
+
+#ifdef HAVE_LINUX_INPUT_H
+# include <linux/input.h>
+#endif
+
+#include "xlat/evdev_abs.h"
+#include "xlat/evdev_ev.h"
+
+static int
+compare(const void *a, const void *b)
+{
+	const unsigned int code1 = (const unsigned long) a;
+	const unsigned int code2 = ((struct_ioctlent *) b)->code;
+	return (code1 > code2) ? 1 : (code1 < code2) ? -1 : 0;
+}
+
+static const struct_ioctlent *
+ioctl_lookup(const unsigned int code)
+{
+	struct_ioctlent *iop;
+
+	iop = bsearch((const void *) (const unsigned long) code, ioctlent,
+			nioctlents, sizeof(ioctlent[0]), compare);
+	while (iop > ioctlent) {
+		iop--;
+		if (iop->code != code) {
+			iop++;
+			break;
+		}
+	}
+	return iop;
+}
+
+static const struct_ioctlent *
+ioctl_next_match(const struct_ioctlent *iop)
+{
+	const unsigned int code = iop->code;
+	iop++;
+	if (iop < ioctlent + nioctlents && iop->code == code)
+		return iop;
+	return NULL;
+}
+
+static void
+ioctl_print_code(const unsigned int code)
+{
+	tprints("_IOC(");
+	printflags(ioctl_dirs, _IOC_DIR(code), "_IOC_???");
+	tprintf(", 0x%02x, 0x%02x, 0x%02x)",
+		_IOC_TYPE(code), _IOC_NR(code), _IOC_SIZE(code));
+}
+
+static int
+evdev_decode_number(const unsigned int code)
+{
+	const unsigned int nr = _IOC_NR(code);
+
+	if (_IOC_DIR(code) == _IOC_WRITE) {
+		if (nr >= 0xc0 && nr <= 0xc0 + 0x3f) {
+			tprints("EVIOCSABS(");
+			printxval(evdev_abs, nr - 0xc0, "ABS_???");
+			tprints(")");
+			return 1;
+		}
+	}
+
+	if (_IOC_DIR(code) != _IOC_READ)
+		return 0;
+
+	if (nr >= 0x20 && nr <= 0x20 + 0x1f) {
+		tprints("EVIOCGBIT(");
+		printxval(evdev_ev, nr - 0x20, "EV_???");
+		tprintf(", %u)", _IOC_SIZE(code));
+		return 1;
+	} else if (nr >= 0x40 && nr <= 0x40 + 0x3f) {
+		tprints("EVIOCGABS(");
+		printxval(evdev_abs, nr - 0x40, "ABS_???");
+		tprints(")");
+		return 1;
+	}
+
+	switch (_IOC_NR(nr)) {
+		case 0x06:
+			tprintf("EVIOCGNAME(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x07:
+			tprintf("EVIOCGPHYS(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x08:
+			tprintf("EVIOCGUNIQ(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x09:
+			tprintf("EVIOCGPROP(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x0a:
+			tprintf("EVIOCGMTSLOTS(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x18:
+			tprintf("EVIOCGKEY(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x19:
+			tprintf("EVIOCGLED(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x1a:
+			tprintf("EVIOCGSND(%u)", _IOC_SIZE(code));
+			return 1;
+		case 0x1b:
+			tprintf("EVIOCGSW(%u)", _IOC_SIZE(code));
+			return 1;
+		default:
+			return 0;
+	}
+}
+
+static int
+hiddev_decode_number(const unsigned int code)
+{
+	if (_IOC_DIR(code) == _IOC_READ) {
+		switch (_IOC_NR(code)) {
+			case 0x04:
+				tprintf("HIDIOCGRAWNAME(%u)", _IOC_SIZE(code));
+				return 1;
+			case 0x05:
+				tprintf("HIDIOCGRAWPHYS(%u)", _IOC_SIZE(code));
+				return 1;
+			case 0x06:
+				tprintf("HIDIOCSFEATURE(%u)", _IOC_SIZE(code));
+				return 1;
+			case 0x12:
+				tprintf("HIDIOCGPHYS(%u)", _IOC_SIZE(code));
+				return 1;
+			default:
+				return 0;
+		}
+	} else if (_IOC_DIR(code) == (_IOC_READ | _IOC_WRITE)) {
+		switch (_IOC_NR(code)) {
+			case 0x06:
+				tprintf("HIDIOCSFEATURE(%u)", _IOC_SIZE(code));
+				return 1;
+			case 0x07:
+				tprintf("HIDIOCGFEATURE(%u)", _IOC_SIZE(code));
+				return 1;
+			default:
+				return 0;
+		}
+	}
+
+	return 0;
+}
+
+static int
+ioctl_decode_command_number(struct tcb *tcp)
+{
+	const unsigned int code = tcp->u_arg[1];
+
+	switch (_IOC_TYPE(code)) {
+		case 'E':
+			return evdev_decode_number(code);
+		case 'H':
+			return hiddev_decode_number(code);
+		case 'M':
+			if (_IOC_DIR(code) == _IOC_WRITE) {
+				tprintf("MIXER_WRITE(%u)", _IOC_NR(code));
+				return 1;
+			} else if (_IOC_DIR(code) == _IOC_READ) {
+				tprintf("MIXER_READ(%u)", _IOC_NR(code));
+				return 1;
+			}
+			return 0;
+		case 'U':
+			if (_IOC_DIR(code) == _IOC_READ && _IOC_NR(code) == 0x2c) {
+				tprintf("UI_GET_SYSNAME(%u)", _IOC_SIZE(code));
+				return 1;
+			}
+			return 0;
+		case 'j':
+			if (_IOC_DIR(code) == _IOC_READ && _IOC_NR(code) == 0x13) {
+				tprintf("JSIOCGNAME(%u)", _IOC_SIZE(code));
+				return 1;
+			}
+			return 0;
+		case 'k':
+			if (_IOC_DIR(code) == _IOC_WRITE && _IOC_NR(code) == 0) {
+				tprintf("SPI_IOC_MESSAGE(%u)", _IOC_SIZE(code));
+				return 1;
+			}
+			return 0;
+		default:
+			return 0;
+	}
+}
+
+static int
+ioctl_decode(struct tcb *tcp)
+{
+	const unsigned int code = tcp->u_arg[1];
+	const long arg = tcp->u_arg[2];
+
+	switch (_IOC_TYPE(code)) {
+#if defined(ALPHA) || defined(POWERPC)
+	case 'f': {
+		int ret = file_ioctl(tcp, code, arg);
+		if (ret != RVAL_DECODED)
+			return ret;
+	}
+	case 't':
+	case 'T':
+		return term_ioctl(tcp, code, arg);
+#else /* !ALPHA */
+	case 'f':
+		return file_ioctl(tcp, code, arg);
+	case 0x54:
+#endif /* !ALPHA */
+		return term_ioctl(tcp, code, arg);
+	case 0x89:
+		return sock_ioctl(tcp, code, arg);
+	case 'p':
+		return rtc_ioctl(tcp, code, arg);
+	case 0x03:
+		return hdio_ioctl(tcp, code, arg);
+	case 0x12:
+		return block_ioctl(tcp, code, arg);
+	case 'X':
+		return fs_x_ioctl(tcp, code, arg);
+#ifdef HAVE_SCSI_SG_H
+	case 0x22:
+		return scsi_ioctl(tcp, code, arg);
+#endif
+	case 'L':
+		return loop_ioctl(tcp, code, arg);
+	case 'M':
+		return mtd_ioctl(tcp, code, arg);
+	case 'o':
+	case 'O':
+		return ubi_ioctl(tcp, code, arg);
+	case 'V':
+		return v4l2_ioctl(tcp, code, arg);
+	case '=':
+		return ptp_ioctl(tcp, code, arg);
+#ifdef HAVE_LINUX_INPUT_H
+	case 'E':
+		return evdev_ioctl(tcp, code, arg);
+#endif
+#ifdef HAVE_LINUX_USERFAULTFD_H
+	case 0xaa:
+		return uffdio_ioctl(tcp, code, arg);
+#endif
+#ifdef HAVE_LINUX_BTRFS_H
+	case 0x94:
+		return btrfs_ioctl(tcp, code, arg);
+#endif
+	default:
+		break;
+	}
+	return 0;
+}
+
+SYS_FUNC(ioctl)
+{
+	const struct_ioctlent *iop;
+	int ret;
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		ret = ioctl_decode_command_number(tcp);
+		if (!(ret & IOCTL_NUMBER_STOP_LOOKUP)) {
+			iop = ioctl_lookup(tcp->u_arg[1]);
+			if (iop) {
+				if (ret)
+					tprints(" or ");
+				tprints(iop->symbol);
+				while ((iop = ioctl_next_match(iop)))
+					tprintf(" or %s", iop->symbol);
+			} else if (!ret) {
+				ioctl_print_code(tcp->u_arg[1]);
+			}
+		}
+		ret = ioctl_decode(tcp);
+	} else {
+		ret = ioctl_decode(tcp) | RVAL_DECODED;
+	}
+
+	if (ret & RVAL_DECODED) {
+		ret &= ~RVAL_DECODED;
+		if (ret)
+			--ret;
+		else
+			tprintf(", %#lx", tcp->u_arg[2]);
+		ret |= RVAL_DECODED;
+	} else {
+		if (ret)
+			--ret;
+	}
+
+	return ret;
+}
diff --git a/strace/ioctl_redefs1.h b/strace/ioctl_redefs1.h
new file mode 100644
index 0000000..ea91699
--- /dev/null
+++ b/strace/ioctl_redefs1.h
@@ -0,0 +1,1540 @@
+#ifdef AGPIOC_ALLOCATE
+# undef AGPIOC_ALLOCATE
+# define AGPIOC_ALLOCATE 0xc0044106
+#endif
+#ifdef AGPIOC_BIND
+# undef AGPIOC_BIND
+# define AGPIOC_BIND 0x40044108
+#endif
+#ifdef AGPIOC_INFO
+# undef AGPIOC_INFO
+# define AGPIOC_INFO 0x80044100
+#endif
+#ifdef AGPIOC_PROTECT
+# undef AGPIOC_PROTECT
+# define AGPIOC_PROTECT 0x40044105
+#endif
+#ifdef AGPIOC_RESERVE
+# undef AGPIOC_RESERVE
+# define AGPIOC_RESERVE 0x40044104
+#endif
+#ifdef AGPIOC_SETUP
+# undef AGPIOC_SETUP
+# define AGPIOC_SETUP 0x40044103
+#endif
+#ifdef AGPIOC_UNBIND
+# undef AGPIOC_UNBIND
+# define AGPIOC_UNBIND 0x40044109
+#endif
+#ifdef ASHMEM_SET_PROT_MASK
+# undef ASHMEM_SET_PROT_MASK
+# define ASHMEM_SET_PROT_MASK 0x40047705
+#endif
+#ifdef ASHMEM_SET_SIZE
+# undef ASHMEM_SET_SIZE
+# define ASHMEM_SET_SIZE 0x40047703
+#endif
+#ifdef ATM_ADDADDR
+# undef ATM_ADDADDR
+# define ATM_ADDADDR 0x400c6188
+#endif
+#ifdef ATM_ADDLECSADDR
+# undef ATM_ADDLECSADDR
+# define ATM_ADDLECSADDR 0x400c618e
+#endif
+#ifdef ATM_ADDPARTY
+# undef ATM_ADDPARTY
+# define ATM_ADDPARTY 0x400861f4
+#endif
+#ifdef ATM_DELADDR
+# undef ATM_DELADDR
+# define ATM_DELADDR 0x400c6189
+#endif
+#ifdef ATM_DELLECSADDR
+# undef ATM_DELLECSADDR
+# define ATM_DELLECSADDR 0x400c618f
+#endif
+#ifdef ATM_GETADDR
+# undef ATM_GETADDR
+# define ATM_GETADDR 0x400c6186
+#endif
+#ifdef ATM_GETCIRANGE
+# undef ATM_GETCIRANGE
+# define ATM_GETCIRANGE 0x400c618a
+#endif
+#ifdef ATM_GETESI
+# undef ATM_GETESI
+# define ATM_GETESI 0x400c6185
+#endif
+#ifdef ATM_GETLECSADDR
+# undef ATM_GETLECSADDR
+# define ATM_GETLECSADDR 0x400c6190
+#endif
+#ifdef ATM_GETLINKRATE
+# undef ATM_GETLINKRATE
+# define ATM_GETLINKRATE 0x400c6181
+#endif
+#ifdef ATM_GETLOOP
+# undef ATM_GETLOOP
+# define ATM_GETLOOP 0x400c6152
+#endif
+#ifdef ATM_GETNAMES
+# undef ATM_GETNAMES
+# define ATM_GETNAMES 0x40086183
+#endif
+#ifdef ATM_GETSTAT
+# undef ATM_GETSTAT
+# define ATM_GETSTAT 0x400c6150
+#endif
+#ifdef ATM_GETSTATZ
+# undef ATM_GETSTATZ
+# define ATM_GETSTATZ 0x400c6151
+#endif
+#ifdef ATM_GETTYPE
+# undef ATM_GETTYPE
+# define ATM_GETTYPE 0x400c6184
+#endif
+#ifdef ATM_QUERYLOOP
+# undef ATM_QUERYLOOP
+# define ATM_QUERYLOOP 0x400c6154
+#endif
+#ifdef ATM_RSTADDR
+# undef ATM_RSTADDR
+# define ATM_RSTADDR 0x400c6187
+#endif
+#ifdef ATM_SETCIRANGE
+# undef ATM_SETCIRANGE
+# define ATM_SETCIRANGE 0x400c618b
+#endif
+#ifdef ATM_SETESI
+# undef ATM_SETESI
+# define ATM_SETESI 0x400c618c
+#endif
+#ifdef ATM_SETESIF
+# undef ATM_SETESIF
+# define ATM_SETESIF 0x400c618d
+#endif
+#ifdef ATM_SETLOOP
+# undef ATM_SETLOOP
+# define ATM_SETLOOP 0x400c6153
+#endif
+#ifdef AUTOFS_IOC_SETTIMEOUT
+# undef AUTOFS_IOC_SETTIMEOUT
+# define AUTOFS_IOC_SETTIMEOUT 0xc0049364
+#endif
+#ifdef BLKBSZGET
+# undef BLKBSZGET
+# define BLKBSZGET 0x80041270
+#endif
+#ifdef BLKBSZSET
+# undef BLKBSZSET
+# define BLKBSZSET 0x40041271
+#endif
+#ifdef BLKGETSIZE64
+# undef BLKGETSIZE64
+# define BLKGETSIZE64 0x80041272
+#endif
+#ifdef BLKTRACESETUP
+# undef BLKTRACESETUP
+# define BLKTRACESETUP 0xc0401273
+#endif
+#ifdef BR_ATTEMPT_ACQUIRE
+# undef BR_ATTEMPT_ACQUIRE
+# define BR_ATTEMPT_ACQUIRE 0x8014720b
+#endif
+#ifdef BTRFS_IOC_DEV_REPLACE
+# undef BTRFS_IOC_DEV_REPLACE
+# define BTRFS_IOC_DEV_REPLACE 0xca249435
+#endif
+#ifdef BTRFS_IOC_SEND
+# undef BTRFS_IOC_SEND
+# define BTRFS_IOC_SEND 0x40449426
+#endif
+#ifdef BTRFS_IOC_SET_RECEIVED_SUBVOL
+# undef BTRFS_IOC_SET_RECEIVED_SUBVOL
+# define BTRFS_IOC_SET_RECEIVED_SUBVOL 0xc0c09425
+#endif
+#ifdef CAPI_MANUFACTURER_CMD
+# undef CAPI_MANUFACTURER_CMD
+# define CAPI_MANUFACTURER_CMD 0xc0084320
+#endif
+#ifdef CCISS_BIG_PASSTHRU
+# undef CCISS_BIG_PASSTHRU
+# define CCISS_BIG_PASSTHRU 0xc0584212
+#endif
+#ifdef CCISS_PASSTHRU
+# undef CCISS_PASSTHRU
+# define CCISS_PASSTHRU 0xc054420b
+#endif
+#ifdef CHIOGSTATUS
+# undef CHIOGSTATUS
+# define CHIOGSTATUS 0x40086308
+#endif
+#ifdef CIOC_KERNEL_VERSION
+# undef CIOC_KERNEL_VERSION
+# define CIOC_KERNEL_VERSION 0xc004630a
+#endif
+#ifdef CM_IOCGATR
+# undef CM_IOCGATR
+# define CM_IOCGATR 0xc0046301
+#endif
+#ifdef CM_IOCGSTATUS
+# undef CM_IOCGSTATUS
+# define CM_IOCGSTATUS 0x80046300
+#endif
+#ifdef CM_IOCSPTS
+# undef CM_IOCSPTS
+# define CM_IOCSPTS 0x40046302
+#endif
+#ifdef CM_IOSDBGLVL
+# undef CM_IOSDBGLVL
+# define CM_IOSDBGLVL 0x400463fa
+#endif
+#ifdef DRM_IOCTL_ADD_BUFS
+# undef DRM_IOCTL_ADD_BUFS
+# define DRM_IOCTL_ADD_BUFS 0xc0186416
+#endif
+#ifdef DRM_IOCTL_ADD_MAP
+# undef DRM_IOCTL_ADD_MAP
+# define DRM_IOCTL_ADD_MAP 0xc0186415
+#endif
+#ifdef DRM_IOCTL_AGP_ALLOC
+# undef DRM_IOCTL_AGP_ALLOC
+# define DRM_IOCTL_AGP_ALLOC 0xc0106434
+#endif
+#ifdef DRM_IOCTL_AGP_BIND
+# undef DRM_IOCTL_AGP_BIND
+# define DRM_IOCTL_AGP_BIND 0x40086436
+#endif
+#ifdef DRM_IOCTL_AGP_ENABLE
+# undef DRM_IOCTL_AGP_ENABLE
+# define DRM_IOCTL_AGP_ENABLE 0x40046432
+#endif
+#ifdef DRM_IOCTL_AGP_FREE
+# undef DRM_IOCTL_AGP_FREE
+# define DRM_IOCTL_AGP_FREE 0x40106435
+#endif
+#ifdef DRM_IOCTL_AGP_INFO
+# undef DRM_IOCTL_AGP_INFO
+# define DRM_IOCTL_AGP_INFO 0x80206433
+#endif
+#ifdef DRM_IOCTL_AGP_UNBIND
+# undef DRM_IOCTL_AGP_UNBIND
+# define DRM_IOCTL_AGP_UNBIND 0x40086437
+#endif
+#ifdef DRM_IOCTL_AMDGPU_GEM_METADATA
+# undef DRM_IOCTL_AMDGPU_GEM_METADATA
+# define DRM_IOCTL_AMDGPU_GEM_METADATA 0xc11c6446
+#endif
+#ifdef DRM_IOCTL_DMA
+# undef DRM_IOCTL_DMA
+# define DRM_IOCTL_DMA 0xc0286429
+#endif
+#ifdef DRM_IOCTL_FREE_BUFS
+# undef DRM_IOCTL_FREE_BUFS
+# define DRM_IOCTL_FREE_BUFS 0x4008641a
+#endif
+#ifdef DRM_IOCTL_GET_CLIENT
+# undef DRM_IOCTL_GET_CLIENT
+# define DRM_IOCTL_GET_CLIENT 0xc0186405
+#endif
+#ifdef DRM_IOCTL_GET_MAP
+# undef DRM_IOCTL_GET_MAP
+# define DRM_IOCTL_GET_MAP 0xc0186404
+#endif
+#ifdef DRM_IOCTL_GET_SAREA_CTX
+# undef DRM_IOCTL_GET_SAREA_CTX
+# define DRM_IOCTL_GET_SAREA_CTX 0xc008641d
+#endif
+#ifdef DRM_IOCTL_GET_STATS
+# undef DRM_IOCTL_GET_STATS
+# define DRM_IOCTL_GET_STATS 0x807c6406
+#endif
+#ifdef DRM_IOCTL_GET_UNIQUE
+# undef DRM_IOCTL_GET_UNIQUE
+# define DRM_IOCTL_GET_UNIQUE 0xc0086401
+#endif
+#ifdef DRM_IOCTL_I810_COPY
+# undef DRM_IOCTL_I810_COPY
+# define DRM_IOCTL_I810_COPY 0x400c6447
+#endif
+#ifdef DRM_IOCTL_I810_GETBUF
+# undef DRM_IOCTL_I810_GETBUF
+# define DRM_IOCTL_I810_GETBUF 0xc0106445
+#endif
+#ifdef DRM_IOCTL_I810_MC
+# undef DRM_IOCTL_I810_MC
+# define DRM_IOCTL_I810_MC 0x4014644c
+#endif
+#ifdef DRM_IOCTL_I915_ALLOC
+# undef DRM_IOCTL_I915_ALLOC
+# define DRM_IOCTL_I915_ALLOC 0xc0106448
+#endif
+#ifdef DRM_IOCTL_I915_BATCHBUFFER
+# undef DRM_IOCTL_I915_BATCHBUFFER
+# define DRM_IOCTL_I915_BATCHBUFFER 0x40186443
+#endif
+#ifdef DRM_IOCTL_I915_CMDBUFFER
+# undef DRM_IOCTL_I915_CMDBUFFER
+# define DRM_IOCTL_I915_CMDBUFFER 0x4018644b
+#endif
+#ifdef DRM_IOCTL_I915_GETPARAM
+# undef DRM_IOCTL_I915_GETPARAM
+# define DRM_IOCTL_I915_GETPARAM 0xc0086446
+#endif
+#ifdef DRM_IOCTL_I915_IRQ_EMIT
+# undef DRM_IOCTL_I915_IRQ_EMIT
+# define DRM_IOCTL_I915_IRQ_EMIT 0xc0046444
+#endif
+#ifdef DRM_IOCTL_INFO_BUFS
+# undef DRM_IOCTL_INFO_BUFS
+# define DRM_IOCTL_INFO_BUFS 0xc0086418
+#endif
+#ifdef DRM_IOCTL_MAP_BUFS
+# undef DRM_IOCTL_MAP_BUFS
+# define DRM_IOCTL_MAP_BUFS 0xc00c6419
+#endif
+#ifdef DRM_IOCTL_MARK_BUFS
+# undef DRM_IOCTL_MARK_BUFS
+# define DRM_IOCTL_MARK_BUFS 0x40186417
+#endif
+#ifdef DRM_IOCTL_MGA_DMA_BOOTSTRAP
+# undef DRM_IOCTL_MGA_DMA_BOOTSTRAP
+# define DRM_IOCTL_MGA_DMA_BOOTSTRAP 0xc01c644c
+#endif
+#ifdef DRM_IOCTL_MGA_GETPARAM
+# undef DRM_IOCTL_MGA_GETPARAM
+# define DRM_IOCTL_MGA_GETPARAM 0xc0086449
+#endif
+#ifdef DRM_IOCTL_MGA_INIT
+# undef DRM_IOCTL_MGA_INIT
+# define DRM_IOCTL_MGA_INIT 0x405c6440
+#endif
+#ifdef DRM_IOCTL_MODE_ADDFB2
+# undef DRM_IOCTL_MODE_ADDFB2
+# define DRM_IOCTL_MODE_ADDFB2 0xc06464b8
+#endif
+#ifdef DRM_IOCTL_MODE_GETPLANERESOURCES
+# undef DRM_IOCTL_MODE_GETPLANERESOURCES
+# define DRM_IOCTL_MODE_GETPLANERESOURCES 0xc00c64b5
+#endif
+#ifdef DRM_IOCTL_MODE_OBJ_GETPROPERTIES
+# undef DRM_IOCTL_MODE_OBJ_GETPROPERTIES
+# define DRM_IOCTL_MODE_OBJ_GETPROPERTIES 0xc01c64b9
+#endif
+#ifdef DRM_IOCTL_MODE_OBJ_SETPROPERTY
+# undef DRM_IOCTL_MODE_OBJ_SETPROPERTY
+# define DRM_IOCTL_MODE_OBJ_SETPROPERTY 0xc01464ba
+#endif
+#ifdef DRM_IOCTL_R128_DEPTH
+# undef DRM_IOCTL_R128_DEPTH
+# define DRM_IOCTL_R128_DEPTH 0x4018644c
+#endif
+#ifdef DRM_IOCTL_R128_GETPARAM
+# undef DRM_IOCTL_R128_GETPARAM
+# define DRM_IOCTL_R128_GETPARAM 0xc0086452
+#endif
+#ifdef DRM_IOCTL_R128_INIT
+# undef DRM_IOCTL_R128_INIT
+# define DRM_IOCTL_R128_INIT 0x40586440
+#endif
+#ifdef DRM_IOCTL_R128_STIPPLE
+# undef DRM_IOCTL_R128_STIPPLE
+# define DRM_IOCTL_R128_STIPPLE 0x4004644d
+#endif
+#ifdef DRM_IOCTL_RADEON_ALLOC
+# undef DRM_IOCTL_RADEON_ALLOC
+# define DRM_IOCTL_RADEON_ALLOC 0xc0106453
+#endif
+#ifdef DRM_IOCTL_RADEON_CLEAR
+# undef DRM_IOCTL_RADEON_CLEAR
+# define DRM_IOCTL_RADEON_CLEAR 0x40186448
+#endif
+#ifdef DRM_IOCTL_RADEON_CMDBUF
+# undef DRM_IOCTL_RADEON_CMDBUF
+# define DRM_IOCTL_RADEON_CMDBUF 0x40106450
+#endif
+#ifdef DRM_IOCTL_RADEON_CP_INIT
+# undef DRM_IOCTL_RADEON_CP_INIT
+# define DRM_IOCTL_RADEON_CP_INIT 0x40546440
+#endif
+#ifdef DRM_IOCTL_RADEON_GEM_CREATE
+# undef DRM_IOCTL_RADEON_GEM_CREATE
+# define DRM_IOCTL_RADEON_GEM_CREATE 0xc01c645d
+#endif
+#ifdef DRM_IOCTL_RADEON_GETPARAM
+# undef DRM_IOCTL_RADEON_GETPARAM
+# define DRM_IOCTL_RADEON_GETPARAM 0xc0086451
+#endif
+#ifdef DRM_IOCTL_RADEON_IRQ_EMIT
+# undef DRM_IOCTL_RADEON_IRQ_EMIT
+# define DRM_IOCTL_RADEON_IRQ_EMIT 0xc0046456
+#endif
+#ifdef DRM_IOCTL_RADEON_SETPARAM
+# undef DRM_IOCTL_RADEON_SETPARAM
+# define DRM_IOCTL_RADEON_SETPARAM 0x400c6459
+#endif
+#ifdef DRM_IOCTL_RADEON_STIPPLE
+# undef DRM_IOCTL_RADEON_STIPPLE
+# define DRM_IOCTL_RADEON_STIPPLE 0x4004644c
+#endif
+#ifdef DRM_IOCTL_RADEON_TEXTURE
+# undef DRM_IOCTL_RADEON_TEXTURE
+# define DRM_IOCTL_RADEON_TEXTURE 0xc018644e
+#endif
+#ifdef DRM_IOCTL_RADEON_VERTEX2
+# undef DRM_IOCTL_RADEON_VERTEX2
+# define DRM_IOCTL_RADEON_VERTEX2 0x4018644f
+#endif
+#ifdef DRM_IOCTL_RES_CTX
+# undef DRM_IOCTL_RES_CTX
+# define DRM_IOCTL_RES_CTX 0xc0086426
+#endif
+#ifdef DRM_IOCTL_RM_MAP
+# undef DRM_IOCTL_RM_MAP
+# define DRM_IOCTL_RM_MAP 0x4018641b
+#endif
+#ifdef DRM_IOCTL_SAVAGE_BCI_CMDBUF
+# undef DRM_IOCTL_SAVAGE_BCI_CMDBUF
+# define DRM_IOCTL_SAVAGE_BCI_CMDBUF 0x40246441
+#endif
+#ifdef DRM_IOCTL_SAVAGE_BCI_INIT
+# undef DRM_IOCTL_SAVAGE_BCI_INIT
+# define DRM_IOCTL_SAVAGE_BCI_INIT 0x40506440
+#endif
+#ifdef DRM_IOCTL_SET_SAREA_CTX
+# undef DRM_IOCTL_SET_SAREA_CTX
+# define DRM_IOCTL_SET_SAREA_CTX 0x4008641c
+#endif
+#ifdef DRM_IOCTL_SET_UNIQUE
+# undef DRM_IOCTL_SET_UNIQUE
+# define DRM_IOCTL_SET_UNIQUE 0x40086410
+#endif
+#ifdef DRM_IOCTL_SG_ALLOC
+# undef DRM_IOCTL_SG_ALLOC
+# define DRM_IOCTL_SG_ALLOC 0xc0086438
+#endif
+#ifdef DRM_IOCTL_SG_FREE
+# undef DRM_IOCTL_SG_FREE
+# define DRM_IOCTL_SG_FREE 0x40086439
+#endif
+#ifdef DRM_IOCTL_SIS_AGP_ALLOC
+# undef DRM_IOCTL_SIS_AGP_ALLOC
+# define DRM_IOCTL_SIS_AGP_ALLOC 0xc0106454
+#endif
+#ifdef DRM_IOCTL_SIS_AGP_FREE
+# undef DRM_IOCTL_SIS_AGP_FREE
+# define DRM_IOCTL_SIS_AGP_FREE 0x40106455
+#endif
+#ifdef DRM_IOCTL_SIS_AGP_INIT
+# undef DRM_IOCTL_SIS_AGP_INIT
+# define DRM_IOCTL_SIS_AGP_INIT 0xc0086453
+#endif
+#ifdef DRM_IOCTL_SIS_FB_ALLOC
+# undef DRM_IOCTL_SIS_FB_ALLOC
+# define DRM_IOCTL_SIS_FB_ALLOC 0xc0106444
+#endif
+#ifdef DRM_IOCTL_SIS_FB_FREE
+# undef DRM_IOCTL_SIS_FB_FREE
+# define DRM_IOCTL_SIS_FB_FREE 0x40106445
+#endif
+#ifdef DRM_IOCTL_SIS_FB_INIT
+# undef DRM_IOCTL_SIS_FB_INIT
+# define DRM_IOCTL_SIS_FB_INIT 0x40086456
+#endif
+#ifdef DRM_IOCTL_UPDATE_DRAW
+# undef DRM_IOCTL_UPDATE_DRAW
+# define DRM_IOCTL_UPDATE_DRAW 0x4014643f
+#endif
+#ifdef DRM_IOCTL_VERSION
+# undef DRM_IOCTL_VERSION
+# define DRM_IOCTL_VERSION 0xc0246400
+#endif
+#ifdef DRM_IOCTL_VIA_ALLOCMEM
+# undef DRM_IOCTL_VIA_ALLOCMEM
+# define DRM_IOCTL_VIA_ALLOCMEM 0xc0146440
+#endif
+#ifdef DRM_IOCTL_VIA_CMDBUFFER
+# undef DRM_IOCTL_VIA_CMDBUFFER
+# define DRM_IOCTL_VIA_CMDBUFFER 0x40086448
+#endif
+#ifdef DRM_IOCTL_VIA_DMA_BLIT
+# undef DRM_IOCTL_VIA_DMA_BLIT
+# define DRM_IOCTL_VIA_DMA_BLIT 0x4028644e
+#endif
+#ifdef DRM_IOCTL_VIA_DMA_INIT
+# undef DRM_IOCTL_VIA_DMA_INIT
+# define DRM_IOCTL_VIA_DMA_INIT 0xc0106447
+#endif
+#ifdef DRM_IOCTL_VIA_FREEMEM
+# undef DRM_IOCTL_VIA_FREEMEM
+# define DRM_IOCTL_VIA_FREEMEM 0x40146441
+#endif
+#ifdef DRM_IOCTL_VIA_MAP_INIT
+# undef DRM_IOCTL_VIA_MAP_INIT
+# define DRM_IOCTL_VIA_MAP_INIT 0xc0146444
+#endif
+#ifdef DRM_IOCTL_VIA_PCICMD
+# undef DRM_IOCTL_VIA_PCICMD
+# define DRM_IOCTL_VIA_PCICMD 0x4008644a
+#endif
+#ifdef DRM_IOCTL_VIA_WAIT_IRQ
+# undef DRM_IOCTL_VIA_WAIT_IRQ
+# define DRM_IOCTL_VIA_WAIT_IRQ 0xc010644d
+#endif
+#ifdef DRM_IOCTL_WAIT_VBLANK
+# undef DRM_IOCTL_WAIT_VBLANK
+# define DRM_IOCTL_WAIT_VBLANK 0xc010643a
+#endif
+#ifdef ENI_MEMDUMP
+# undef ENI_MEMDUMP
+# define ENI_MEMDUMP 0x400c6160
+#endif
+#ifdef ENI_SETMULT
+# undef ENI_SETMULT
+# define ENI_SETMULT 0x400c6167
+#endif
+#ifdef EVIOCSFF
+# undef EVIOCSFF
+# define EVIOCSFF 0x402c4580
+#endif
+#ifdef FBIO_CURSOR
+# undef FBIO_CURSOR
+# define FBIO_CURSOR 0xc0484608
+#endif
+#ifdef FBIO_GETCONTROL2
+# undef FBIO_GETCONTROL2
+# define FBIO_GETCONTROL2 0x80044689
+#endif
+#ifdef FBIO_RADEON_GET_MIRROR
+# undef FBIO_RADEON_GET_MIRROR
+# define FBIO_RADEON_GET_MIRROR 0x80044003
+#endif
+#ifdef FBIO_RADEON_SET_MIRROR
+# undef FBIO_RADEON_SET_MIRROR
+# define FBIO_RADEON_SET_MIRROR 0x40044004
+#endif
+#ifdef FDDEFPRM
+# undef FDDEFPRM
+# define FDDEFPRM 0x401c0243
+#endif
+#ifdef FDGETDRVPRM
+# undef FDGETDRVPRM
+# define FDGETDRVPRM 0x80580211
+#endif
+#ifdef FDGETDRVSTAT
+# undef FDGETDRVSTAT
+# define FDGETDRVSTAT 0x80340212
+#endif
+#ifdef FDGETFDCSTAT
+# undef FDGETFDCSTAT
+# define FDGETFDCSTAT 0x80200215
+#endif
+#ifdef FDGETPRM
+# undef FDGETPRM
+# define FDGETPRM 0x801c0204
+#endif
+#ifdef FDPOLLDRVSTAT
+# undef FDPOLLDRVSTAT
+# define FDPOLLDRVSTAT 0x80340213
+#endif
+#ifdef FDSETDRVPRM
+# undef FDSETDRVPRM
+# define FDSETDRVPRM 0x40580290
+#endif
+#ifdef FDSETPRM
+# undef FDSETPRM
+# define FDSETPRM 0x401c0242
+#endif
+#ifdef FDWERRORGET
+# undef FDWERRORGET
+# define FDWERRORGET 0x80180217
+#endif
+#ifdef FE_GET_PROPERTY
+# undef FE_GET_PROPERTY
+# define FE_GET_PROPERTY 0x80086f53
+#endif
+#ifdef FE_SET_PROPERTY
+# undef FE_SET_PROPERTY
+# define FE_SET_PROPERTY 0x40086f52
+#endif
+#ifdef FS_IOC_GETFLAGS
+# undef FS_IOC_GETFLAGS
+# define FS_IOC_GETFLAGS 0x80046601
+#endif
+#ifdef FS_IOC_GETVERSION
+# undef FS_IOC_GETVERSION
+# define FS_IOC_GETVERSION 0x80047601
+#endif
+#ifdef FS_IOC_SETFLAGS
+# undef FS_IOC_SETFLAGS
+# define FS_IOC_SETFLAGS 0x40046602
+#endif
+#ifdef FS_IOC_SETVERSION
+# undef FS_IOC_SETVERSION
+# define FS_IOC_SETVERSION 0x40047602
+#endif
+#ifdef FW_CDEV_IOC_CREATE_ISO_CONTEXT
+# undef FW_CDEV_IOC_CREATE_ISO_CONTEXT
+# define FW_CDEV_IOC_CREATE_ISO_CONTEXT 0xc01c2308
+#endif
+#ifdef FW_CDEV_IOC_GET_CYCLE_TIMER
+# undef FW_CDEV_IOC_GET_CYCLE_TIMER
+# define FW_CDEV_IOC_GET_CYCLE_TIMER 0x800c230c
+#endif
+#ifdef FW_CDEV_IOC_GET_CYCLE_TIMER2
+# undef FW_CDEV_IOC_GET_CYCLE_TIMER2
+# define FW_CDEV_IOC_GET_CYCLE_TIMER2 0xc0142314
+#endif
+#ifdef FW_CDEV_IOC_GET_INFO
+# undef FW_CDEV_IOC_GET_INFO
+# define FW_CDEV_IOC_GET_INFO 0xc0242300
+#endif
+#ifdef FW_CDEV_IOC_SEND_BROADCAST_REQUEST
+# undef FW_CDEV_IOC_SEND_BROADCAST_REQUEST
+# define FW_CDEV_IOC_SEND_BROADCAST_REQUEST 0x40242312
+#endif
+#ifdef FW_CDEV_IOC_SEND_PHY_PACKET
+# undef FW_CDEV_IOC_SEND_PHY_PACKET
+# define FW_CDEV_IOC_SEND_PHY_PACKET 0xc0142315
+#endif
+#ifdef FW_CDEV_IOC_SEND_REQUEST
+# undef FW_CDEV_IOC_SEND_REQUEST
+# define FW_CDEV_IOC_SEND_REQUEST 0x40242301
+#endif
+#ifdef FW_CDEV_IOC_SEND_RESPONSE
+# undef FW_CDEV_IOC_SEND_RESPONSE
+# define FW_CDEV_IOC_SEND_RESPONSE 0x40142304
+#endif
+#ifdef FW_CDEV_IOC_SET_ISO_CHANNELS
+# undef FW_CDEV_IOC_SET_ISO_CHANNELS
+# define FW_CDEV_IOC_SET_ISO_CHANNELS 0x400c2317
+#endif
+#ifdef HE_GET_REG
+# undef HE_GET_REG
+# define HE_GET_REG 0x400c6160
+#endif
+#ifdef HFI1_IOCTL_ACK_EVENT
+# undef HFI1_IOCTL_ACK_EVENT
+# define HFI1_IOCTL_ACK_EVENT 0x40041bea
+#endif
+#ifdef HPET_INFO
+# undef HPET_INFO
+# define HPET_INFO 0x800c6803
+#endif
+#ifdef HPET_IRQFREQ
+# undef HPET_IRQFREQ
+# define HPET_IRQFREQ 0x40046806
+#endif
+#ifdef I2OHRTGET
+# undef I2OHRTGET
+# define I2OHRTGET 0xc00c6901
+#endif
+#ifdef I2OHTML
+# undef I2OHTML
+# define I2OHTML 0xc01c6909
+#endif
+#ifdef I2OLCTGET
+# undef I2OLCTGET
+# define I2OLCTGET 0xc00c6902
+#endif
+#ifdef I2OPARMGET
+# undef I2OPARMGET
+# define I2OPARMGET 0xc0186904
+#endif
+#ifdef I2OPARMSET
+# undef I2OPARMSET
+# define I2OPARMSET 0xc0186903
+#endif
+#ifdef I2OPASSTHRU
+# undef I2OPASSTHRU
+# define I2OPASSTHRU 0x8008690c
+#endif
+#ifdef I2OSWDEL
+# undef I2OSWDEL
+# define I2OSWDEL 0xc01c6907
+#endif
+#ifdef I2OSWDL
+# undef I2OSWDL
+# define I2OSWDL 0xc01c6905
+#endif
+#ifdef I2OSWUL
+# undef I2OSWUL
+# define I2OSWUL 0xc01c6906
+#endif
+#ifdef I8K_FN_STATUS
+# undef I8K_FN_STATUS
+# define I8K_FN_STATUS 0x80046983
+#endif
+#ifdef I8K_GET_FAN
+# undef I8K_GET_FAN
+# define I8K_GET_FAN 0xc0046986
+#endif
+#ifdef I8K_GET_SPEED
+# undef I8K_GET_SPEED
+# define I8K_GET_SPEED 0xc0046985
+#endif
+#ifdef I8K_GET_TEMP
+# undef I8K_GET_TEMP
+# define I8K_GET_TEMP 0x80046984
+#endif
+#ifdef I8K_POWER_STATUS
+# undef I8K_POWER_STATUS
+# define I8K_POWER_STATUS 0x80046982
+#endif
+#ifdef I8K_SET_FAN
+# undef I8K_SET_FAN
+# define I8K_SET_FAN 0xc0046987
+#endif
+#ifdef IDT77105_GETSTAT
+# undef IDT77105_GETSTAT
+# define IDT77105_GETSTAT 0x400c6132
+#endif
+#ifdef IDT77105_GETSTATZ
+# undef IDT77105_GETSTATZ
+# define IDT77105_GETSTATZ 0x400c6133
+#endif
+#ifdef IOCTL_GNTDEV_GRANT_COPY
+# undef IOCTL_GNTDEV_GRANT_COPY
+# define IOCTL_GNTDEV_GRANT_COPY 0x00084708
+#endif
+#ifdef ION_IOC_ALLOC
+# undef ION_IOC_ALLOC
+# define ION_IOC_ALLOC 0xc0144900
+#endif
+#ifdef ION_IOC_CUSTOM
+# undef ION_IOC_CUSTOM
+# define ION_IOC_CUSTOM 0xc0084906
+#endif
+#ifdef IOW_READ
+# undef IOW_READ
+# define IOW_READ 0x4004c002
+#endif
+#ifdef IOW_WRITE
+# undef IOW_WRITE
+# define IOW_WRITE 0x4004c001
+#endif
+#ifdef IPMICTL_RECEIVE_MSG
+# undef IPMICTL_RECEIVE_MSG
+# define IPMICTL_RECEIVE_MSG 0xc018690c
+#endif
+#ifdef IPMICTL_RECEIVE_MSG_TRUNC
+# undef IPMICTL_RECEIVE_MSG_TRUNC
+# define IPMICTL_RECEIVE_MSG_TRUNC 0xc018690b
+#endif
+#ifdef IPMICTL_SEND_COMMAND
+# undef IPMICTL_SEND_COMMAND
+# define IPMICTL_SEND_COMMAND 0x8014690d
+#endif
+#ifdef IPMICTL_SEND_COMMAND_SETTIME
+# undef IPMICTL_SEND_COMMAND_SETTIME
+# define IPMICTL_SEND_COMMAND_SETTIME 0x801c6915
+#endif
+#ifdef IVTVFB_IOC_DMA_FRAME
+# undef IVTVFB_IOC_DMA_FRAME
+# define IVTVFB_IOC_DMA_FRAME 0x400c56c0
+#endif
+#ifdef IVTV_IOC_DMA_FRAME
+# undef IVTV_IOC_DMA_FRAME
+# define IVTV_IOC_DMA_FRAME 0x403856c0
+#endif
+#ifdef IXJCTL_CID
+# undef IXJCTL_CID
+# define IXJCTL_CID 0x800471d4
+#endif
+#ifdef IXJCTL_CIDCW
+# undef IXJCTL_CIDCW
+# define IXJCTL_CIDCW 0x400471d9
+#endif
+#ifdef IXJCTL_DRYBUFFER_READ
+# undef IXJCTL_DRYBUFFER_READ
+# define IXJCTL_DRYBUFFER_READ 0x800471e6
+#endif
+#ifdef IXJCTL_FILTER_CADENCE
+# undef IXJCTL_FILTER_CADENCE
+# define IXJCTL_FILTER_CADENCE 0x400471d6
+#endif
+#ifdef IXJCTL_FRAMES_READ
+# undef IXJCTL_FRAMES_READ
+# define IXJCTL_FRAMES_READ 0x800471e2
+#endif
+#ifdef IXJCTL_FRAMES_WRITTEN
+# undef IXJCTL_FRAMES_WRITTEN
+# define IXJCTL_FRAMES_WRITTEN 0x800471e3
+#endif
+#ifdef IXJCTL_INIT_TONE
+# undef IXJCTL_INIT_TONE
+# define IXJCTL_INIT_TONE 0x400471c9
+#endif
+#ifdef IXJCTL_READ_WAIT
+# undef IXJCTL_READ_WAIT
+# define IXJCTL_READ_WAIT 0x800471e4
+#endif
+#ifdef IXJCTL_SET_FILTER
+# undef IXJCTL_SET_FILTER
+# define IXJCTL_SET_FILTER 0x400471c7
+#endif
+#ifdef IXJCTL_SET_FILTER_RAW
+# undef IXJCTL_SET_FILTER_RAW
+# define IXJCTL_SET_FILTER_RAW 0x400471dd
+#endif
+#ifdef IXJCTL_SIGCTL
+# undef IXJCTL_SIGCTL
+# define IXJCTL_SIGCTL 0x400471e9
+#endif
+#ifdef IXJCTL_TONE_CADENCE
+# undef IXJCTL_TONE_CADENCE
+# define IXJCTL_TONE_CADENCE 0x400471ca
+#endif
+#ifdef IXJCTL_VERSION
+# undef IXJCTL_VERSION
+# define IXJCTL_VERSION 0x800471da
+#endif
+#ifdef IXJCTL_WRITE_WAIT
+# undef IXJCTL_WRITE_WAIT
+# define IXJCTL_WRITE_WAIT 0x800471e5
+#endif
+#ifdef KCOV_INIT_TRACE
+# undef KCOV_INIT_TRACE
+# define KCOV_INIT_TRACE 0x80046301
+#endif
+#ifdef KVM_DIRTY_TLB
+# undef KVM_DIRTY_TLB
+# define KVM_DIRTY_TLB 0x400caeaa
+#endif
+#ifdef KVM_S390_STORE_STATUS
+# undef KVM_S390_STORE_STATUS
+# define KVM_S390_STORE_STATUS 0x4004ae95
+#endif
+#ifdef KVM_S390_VCPU_FAULT
+# undef KVM_S390_VCPU_FAULT
+# define KVM_S390_VCPU_FAULT 0x4004ae52
+#endif
+#ifdef MATROXFB_GET_ALL_OUTPUTS
+# undef MATROXFB_GET_ALL_OUTPUTS
+# define MATROXFB_GET_ALL_OUTPUTS 0x80046efb
+#endif
+#ifdef MATROXFB_GET_AVAILABLE_OUTPUTS
+# undef MATROXFB_GET_AVAILABLE_OUTPUTS
+# define MATROXFB_GET_AVAILABLE_OUTPUTS 0x80046ef9
+#endif
+#ifdef MATROXFB_GET_OUTPUT_CONNECTION
+# undef MATROXFB_GET_OUTPUT_CONNECTION
+# define MATROXFB_GET_OUTPUT_CONNECTION 0x80046ef8
+#endif
+#ifdef MATROXFB_GET_OUTPUT_MODE
+# undef MATROXFB_GET_OUTPUT_MODE
+# define MATROXFB_GET_OUTPUT_MODE 0xc0046efa
+#endif
+#ifdef MATROXFB_SET_OUTPUT_CONNECTION
+# undef MATROXFB_SET_OUTPUT_CONNECTION
+# define MATROXFB_SET_OUTPUT_CONNECTION 0x40046ef8
+#endif
+#ifdef MATROXFB_SET_OUTPUT_MODE
+# undef MATROXFB_SET_OUTPUT_MODE
+# define MATROXFB_SET_OUTPUT_MODE 0x40046efa
+#endif
+#ifdef MEDIA_IOC_ENUM_LINKS
+# undef MEDIA_IOC_ENUM_LINKS
+# define MEDIA_IOC_ENUM_LINKS 0xc01c7c02
+#endif
+#ifdef MEMREADOOB
+# undef MEMREADOOB
+# define MEMREADOOB 0xc00c4d04
+#endif
+#ifdef MEMWRITEOOB
+# undef MEMWRITEOOB
+# define MEMWRITEOOB 0xc00c4d03
+#endif
+#ifdef MGSL_IOCGPARAMS
+# undef MGSL_IOCGPARAMS
+# define MGSL_IOCGPARAMS 0x80206d01
+#endif
+#ifdef MGSL_IOCSPARAMS
+# undef MGSL_IOCSPARAMS
+# define MGSL_IOCSPARAMS 0x40206d00
+#endif
+#ifdef MIC_VIRTIO_ADD_DEVICE
+# undef MIC_VIRTIO_ADD_DEVICE
+# define MIC_VIRTIO_ADD_DEVICE 0xc0047301
+#endif
+#ifdef MIC_VIRTIO_CONFIG_CHANGE
+# undef MIC_VIRTIO_CONFIG_CHANGE
+# define MIC_VIRTIO_CONFIG_CHANGE 0xc0047305
+#endif
+#ifdef MIC_VIRTIO_COPY_DESC
+# undef MIC_VIRTIO_COPY_DESC
+# define MIC_VIRTIO_COPY_DESC 0xc0047302
+#endif
+#ifdef MMTIMER_GETCOUNTER
+# undef MMTIMER_GETCOUNTER
+# define MMTIMER_GETCOUNTER 0x80046d09
+#endif
+#ifdef MMTIMER_GETFREQ
+# undef MMTIMER_GETFREQ
+# define MMTIMER_GETFREQ 0x80046d02
+#endif
+#ifdef MMTIMER_GETRES
+# undef MMTIMER_GETRES
+# define MMTIMER_GETRES 0x80046d01
+#endif
+#ifdef MTIOCGET
+# undef MTIOCGET
+# define MTIOCGET 0x801c6d02
+#endif
+#ifdef MTIOCPOS
+# undef MTIOCPOS
+# define MTIOCPOS 0x80046d03
+#endif
+#ifdef MTRRIOC_ADD_ENTRY
+# undef MTRRIOC_ADD_ENTRY
+# define MTRRIOC_ADD_ENTRY 0x400c4d00
+#endif
+#ifdef MTRRIOC_ADD_PAGE_ENTRY
+# undef MTRRIOC_ADD_PAGE_ENTRY
+# define MTRRIOC_ADD_PAGE_ENTRY 0x400c4d05
+#endif
+#ifdef MTRRIOC_DEL_ENTRY
+# undef MTRRIOC_DEL_ENTRY
+# define MTRRIOC_DEL_ENTRY 0x400c4d02
+#endif
+#ifdef MTRRIOC_DEL_PAGE_ENTRY
+# undef MTRRIOC_DEL_PAGE_ENTRY
+# define MTRRIOC_DEL_PAGE_ENTRY 0x400c4d07
+#endif
+#ifdef MTRRIOC_GET_ENTRY
+# undef MTRRIOC_GET_ENTRY
+# define MTRRIOC_GET_ENTRY 0xc0104d03
+#endif
+#ifdef MTRRIOC_GET_PAGE_ENTRY
+# undef MTRRIOC_GET_PAGE_ENTRY
+# define MTRRIOC_GET_PAGE_ENTRY 0xc0104d08
+#endif
+#ifdef MTRRIOC_KILL_ENTRY
+# undef MTRRIOC_KILL_ENTRY
+# define MTRRIOC_KILL_ENTRY 0x400c4d04
+#endif
+#ifdef MTRRIOC_KILL_PAGE_ENTRY
+# undef MTRRIOC_KILL_PAGE_ENTRY
+# define MTRRIOC_KILL_PAGE_ENTRY 0x400c4d09
+#endif
+#ifdef MTRRIOC_SET_ENTRY
+# undef MTRRIOC_SET_ENTRY
+# define MTRRIOC_SET_ENTRY 0x400c4d01
+#endif
+#ifdef MTRRIOC_SET_PAGE_ENTRY
+# undef MTRRIOC_SET_PAGE_ENTRY
+# define MTRRIOC_SET_PAGE_ENTRY 0x400c4d06
+#endif
+#ifdef NCIUARTSETDRIVER
+# undef NCIUARTSETDRIVER
+# define NCIUARTSETDRIVER 0x40045500
+#endif
+#ifdef NCP_IOC_GET_FS_INFO_V2
+# undef NCP_IOC_GET_FS_INFO_V2
+# define NCP_IOC_GET_FS_INFO_V2 0xc0246e04
+#endif
+#ifdef NCP_IOC_GETMOUNTUID2
+# undef NCP_IOC_GETMOUNTUID2
+# define NCP_IOC_GETMOUNTUID2 0x40046e02
+#endif
+#ifdef NCP_IOC_GETOBJECTNAME
+# undef NCP_IOC_GETOBJECTNAME
+# define NCP_IOC_GETOBJECTNAME 0xc00c6e09
+#endif
+#ifdef NCP_IOC_GETPRIVATEDATA
+# undef NCP_IOC_GETPRIVATEDATA
+# define NCP_IOC_GETPRIVATEDATA 0xc0086e0a
+#endif
+#ifdef NCP_IOC_NCPREQUEST
+# undef NCP_IOC_NCPREQUEST
+# define NCP_IOC_NCPREQUEST 0x800c6e01
+#endif
+#ifdef NCP_IOC_SETOBJECTNAME
+# undef NCP_IOC_SETOBJECTNAME
+# define NCP_IOC_SETOBJECTNAME 0x800c6e09
+#endif
+#ifdef NCP_IOC_SETPRIVATEDATA
+# undef NCP_IOC_SETPRIVATEDATA
+# define NCP_IOC_SETPRIVATEDATA 0x80086e0a
+#endif
+#ifdef NS_GETPSTAT
+# undef NS_GETPSTAT
+# define NS_GETPSTAT 0xc00c6161
+#endif
+#ifdef NS_SETBUFLEV
+# undef NS_SETBUFLEV
+# define NS_SETBUFLEV 0x400c6162
+#endif
+#ifdef NVME_IOCTL_SUBMIT_IO
+# undef NVME_IOCTL_SUBMIT_IO
+# define NVME_IOCTL_SUBMIT_IO 0x402c4e42
+#endif
+#ifdef OMAPFB_MEMORY_READ
+# undef OMAPFB_MEMORY_READ
+# define OMAPFB_MEMORY_READ 0x80104f3a
+#endif
+#ifdef OSD_GET_CAPABILITY
+# undef OSD_GET_CAPABILITY
+# define OSD_GET_CAPABILITY 0x80086fa1
+#endif
+#ifdef OSD_SEND_CMD
+# undef OSD_SEND_CMD
+# define OSD_SEND_CMD 0x401c6fa0
+#endif
+#ifdef PERF_EVENT_IOC_ID
+# undef PERF_EVENT_IOC_ID
+# define PERF_EVENT_IOC_ID 0x80042407
+#endif
+#ifdef PERF_EVENT_IOC_SET_FILTER
+# undef PERF_EVENT_IOC_SET_FILTER
+# define PERF_EVENT_IOC_SET_FILTER 0x40042406
+#endif
+#ifdef PHN_GET_REG
+# undef PHN_GET_REG
+# define PHN_GET_REG 0xc0047000
+#endif
+#ifdef PHN_GET_REGS
+# undef PHN_GET_REGS
+# define PHN_GET_REGS 0xc0047002
+#endif
+#ifdef PHN_SET_REG
+# undef PHN_SET_REG
+# define PHN_SET_REG 0x40047001
+#endif
+#ifdef PHN_SET_REGS
+# undef PHN_SET_REGS
+# define PHN_SET_REGS 0x40047003
+#endif
+#ifdef PHONE_CAPABILITIES_CHECK
+# undef PHONE_CAPABILITIES_CHECK
+# define PHONE_CAPABILITIES_CHECK 0x40047182
+#endif
+#ifdef PHONE_CAPABILITIES_LIST
+# undef PHONE_CAPABILITIES_LIST
+# define PHONE_CAPABILITIES_LIST 0x80047181
+#endif
+#ifdef PHONE_QUERY_CODEC
+# undef PHONE_QUERY_CODEC
+# define PHONE_QUERY_CODEC 0xc00471a7
+#endif
+#ifdef PHONE_RING_START
+# undef PHONE_RING_START
+# define PHONE_RING_START 0x40047187
+#endif
+#ifdef PMU_IOC_CAN_SLEEP
+# undef PMU_IOC_CAN_SLEEP
+# define PMU_IOC_CAN_SLEEP 0x80044205
+#endif
+#ifdef PMU_IOC_GET_BACKLIGHT
+# undef PMU_IOC_GET_BACKLIGHT
+# define PMU_IOC_GET_BACKLIGHT 0x80044201
+#endif
+#ifdef PMU_IOC_GET_MODEL
+# undef PMU_IOC_GET_MODEL
+# define PMU_IOC_GET_MODEL 0x80044203
+#endif
+#ifdef PMU_IOC_GRAB_BACKLIGHT
+# undef PMU_IOC_GRAB_BACKLIGHT
+# define PMU_IOC_GRAB_BACKLIGHT 0x80044206
+#endif
+#ifdef PMU_IOC_HAS_ADB
+# undef PMU_IOC_HAS_ADB
+# define PMU_IOC_HAS_ADB 0x80044204
+#endif
+#ifdef PMU_IOC_SET_BACKLIGHT
+# undef PMU_IOC_SET_BACKLIGHT
+# define PMU_IOC_SET_BACKLIGHT 0x40044202
+#endif
+#ifdef PPGETTIME
+# undef PPGETTIME
+# define PPGETTIME 0x80087095
+#endif
+#ifdef PPPIOCGCOMPRESSORS
+# undef PPPIOCGCOMPRESSORS
+# define PPPIOCGCOMPRESSORS 0x80207486
+#endif
+#ifdef PPPIOCGIDLE
+# undef PPPIOCGIDLE
+# define PPPIOCGIDLE 0x8008743f
+#endif
+#ifdef PPPIOCSACTIVE
+# undef PPPIOCSACTIVE
+# define PPPIOCSACTIVE 0x40087446
+#endif
+#ifdef PPPIOCSCOMPRESS
+# undef PPPIOCSCOMPRESS
+# define PPPIOCSCOMPRESS 0x400c744d
+#endif
+#ifdef PPPIOCSPASS
+# undef PPPIOCSPASS
+# define PPPIOCSPASS 0x40087447
+#endif
+#ifdef PPPOEIOCSFWD
+# undef PPPOEIOCSFWD
+# define PPPOEIOCSFWD 0x4004b100
+#endif
+#ifdef PPSETTIME
+# undef PPSETTIME
+# define PPSETTIME 0x40087096
+#endif
+#ifdef PPS_FETCH
+# undef PPS_FETCH
+# define PPS_FETCH 0xc00470a4
+#endif
+#ifdef PPS_GETCAP
+# undef PPS_GETCAP
+# define PPS_GETCAP 0x800470a3
+#endif
+#ifdef PPS_GETPARAMS
+# undef PPS_GETPARAMS
+# define PPS_GETPARAMS 0x800470a1
+#endif
+#ifdef PPS_KC_BIND
+# undef PPS_KC_BIND
+# define PPS_KC_BIND 0x400470a5
+#endif
+#ifdef PPS_SETPARAMS
+# undef PPS_SETPARAMS
+# define PPS_SETPARAMS 0x400470a2
+#endif
+#ifdef REISERFS_IOC_UNPACK
+# undef REISERFS_IOC_UNPACK
+# define REISERFS_IOC_UNPACK 0x4004cd01
+#endif
+#ifdef RTC_EPOCH_READ
+# undef RTC_EPOCH_READ
+# define RTC_EPOCH_READ 0x8004700d
+#endif
+#ifdef RTC_EPOCH_SET
+# undef RTC_EPOCH_SET
+# define RTC_EPOCH_SET 0x4004700e
+#endif
+#ifdef RTC_IRQP_READ
+# undef RTC_IRQP_READ
+# define RTC_IRQP_READ 0x8004700b
+#endif
+#ifdef RTC_IRQP_SET
+# undef RTC_IRQP_SET
+# define RTC_IRQP_SET 0x4004700c
+#endif
+#ifdef RTC_PLL_GET
+# undef RTC_PLL_GET
+# define RTC_PLL_GET 0x801c7011
+#endif
+#ifdef RTC_PLL_SET
+# undef RTC_PLL_SET
+# define RTC_PLL_SET 0x401c7012
+#endif
+#ifdef SCIF_FENCE_MARK
+# undef SCIF_FENCE_MARK
+# define SCIF_FENCE_MARK 0xc00c730f
+#endif
+#ifdef SCIF_FENCE_SIGNAL
+# undef SCIF_FENCE_SIGNAL
+# define SCIF_FENCE_SIGNAL 0xc0247311
+#endif
+#ifdef SCIF_GET_NODEIDS
+# undef SCIF_GET_NODEIDS
+# define SCIF_GET_NODEIDS 0xc014730e
+#endif
+#ifdef SCIF_READFROM
+# undef SCIF_READFROM
+# define SCIF_READFROM 0xc024730a
+#endif
+#ifdef SCIF_RECV
+# undef SCIF_RECV
+# define SCIF_RECV 0xc0147307
+#endif
+#ifdef SCIF_SEND
+# undef SCIF_SEND
+# define SCIF_SEND 0xc0147306
+#endif
+#ifdef SCIF_VREADFROM
+# undef SCIF_VREADFROM
+# define SCIF_VREADFROM 0xc024730c
+#endif
+#ifdef SCIF_VWRITETO
+# undef SCIF_VWRITETO
+# define SCIF_VWRITETO 0xc024730d
+#endif
+#ifdef SCIF_WRITETO
+# undef SCIF_WRITETO
+# define SCIF_WRITETO 0xc024730b
+#endif
+#ifdef SNDCTL_DSP_MAPINBUF
+# undef SNDCTL_DSP_MAPINBUF
+# define SNDCTL_DSP_MAPINBUF 0x80085013
+#endif
+#ifdef SNDCTL_DSP_MAPOUTBUF
+# undef SNDCTL_DSP_MAPOUTBUF
+# define SNDCTL_DSP_MAPOUTBUF 0x80085014
+#endif
+#ifdef SNDRV_CTL_IOCTL_ELEM_LIST
+# undef SNDRV_CTL_IOCTL_ELEM_LIST
+# define SNDRV_CTL_IOCTL_ELEM_LIST 0xc0485510
+#endif
+#ifdef SNDRV_CTL_IOCTL_ELEM_READ
+# undef SNDRV_CTL_IOCTL_ELEM_READ
+# define SNDRV_CTL_IOCTL_ELEM_READ 0xc2c45512
+#endif
+#ifdef SNDRV_CTL_IOCTL_ELEM_WRITE
+# undef SNDRV_CTL_IOCTL_ELEM_WRITE
+# define SNDRV_CTL_IOCTL_ELEM_WRITE 0xc2c45513
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_CODE_PEEK
+# undef SNDRV_EMU10K1_IOCTL_CODE_PEEK
+# define SNDRV_EMU10K1_IOCTL_CODE_PEEK 0xc18c4812
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_CODE_POKE
+# undef SNDRV_EMU10K1_IOCTL_CODE_POKE
+# define SNDRV_EMU10K1_IOCTL_CODE_POKE 0x418c4811
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_TRAM_PEEK
+# undef SNDRV_EMU10K1_IOCTL_TRAM_PEEK
+# define SNDRV_EMU10K1_IOCTL_TRAM_PEEK 0xc00c4822
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_TRAM_POKE
+# undef SNDRV_EMU10K1_IOCTL_TRAM_POKE
+# define SNDRV_EMU10K1_IOCTL_TRAM_POKE 0x400c4821
+#endif
+#ifdef SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE
+# undef SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE
+# define SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE 0x40044842
+#endif
+#ifdef SNDRV_HDSPM_IOCTL_GET_MIXER
+# undef SNDRV_HDSPM_IOCTL_GET_MIXER
+# define SNDRV_HDSPM_IOCTL_GET_MIXER 0x80044844
+#endif
+#ifdef SNDRV_HDSPM_IOCTL_GET_STATUS
+# undef SNDRV_HDSPM_IOCTL_GET_STATUS
+# define SNDRV_HDSPM_IOCTL_GET_STATUS 0x801c4847
+#endif
+#ifdef SNDRV_HWDEP_IOCTL_DSP_LOAD
+# undef SNDRV_HWDEP_IOCTL_DSP_LOAD
+# define SNDRV_HWDEP_IOCTL_DSP_LOAD 0x40504803
+#endif
+#ifdef SNDRV_PCM_IOCTL_CHANNEL_INFO
+# undef SNDRV_PCM_IOCTL_CHANNEL_INFO
+# define SNDRV_PCM_IOCTL_CHANNEL_INFO 0x80104132
+#endif
+#ifdef SNDRV_PCM_IOCTL_DELAY
+# undef SNDRV_PCM_IOCTL_DELAY
+# define SNDRV_PCM_IOCTL_DELAY 0x80044121
+#endif
+#ifdef SNDRV_PCM_IOCTL_FORWARD
+# undef SNDRV_PCM_IOCTL_FORWARD
+# define SNDRV_PCM_IOCTL_FORWARD 0x40044149
+#endif
+#ifdef SNDRV_PCM_IOCTL_HW_PARAMS
+# undef SNDRV_PCM_IOCTL_HW_PARAMS
+# define SNDRV_PCM_IOCTL_HW_PARAMS 0xc25c4111
+#endif
+#ifdef SNDRV_PCM_IOCTL_HW_REFINE
+# undef SNDRV_PCM_IOCTL_HW_REFINE
+# define SNDRV_PCM_IOCTL_HW_REFINE 0xc25c4110
+#endif
+#ifdef SNDRV_PCM_IOCTL_READI_FRAMES
+# undef SNDRV_PCM_IOCTL_READI_FRAMES
+# define SNDRV_PCM_IOCTL_READI_FRAMES 0x800c4151
+#endif
+#ifdef SNDRV_PCM_IOCTL_READN_FRAMES
+# undef SNDRV_PCM_IOCTL_READN_FRAMES
+# define SNDRV_PCM_IOCTL_READN_FRAMES 0x800c4153
+#endif
+#ifdef SNDRV_PCM_IOCTL_REWIND
+# undef SNDRV_PCM_IOCTL_REWIND
+# define SNDRV_PCM_IOCTL_REWIND 0x40044146
+#endif
+#ifdef SNDRV_PCM_IOCTL_STATUS
+# undef SNDRV_PCM_IOCTL_STATUS
+# define SNDRV_PCM_IOCTL_STATUS 0x806c4120
+#endif
+#ifdef SNDRV_PCM_IOCTL_STATUS_EXT
+# undef SNDRV_PCM_IOCTL_STATUS_EXT
+# define SNDRV_PCM_IOCTL_STATUS_EXT 0xc06c4124
+#endif
+#ifdef SNDRV_PCM_IOCTL_SW_PARAMS
+# undef SNDRV_PCM_IOCTL_SW_PARAMS
+# define SNDRV_PCM_IOCTL_SW_PARAMS 0xc0684113
+#endif
+#ifdef SNDRV_PCM_IOCTL_SYNC_PTR
+# undef SNDRV_PCM_IOCTL_SYNC_PTR
+# define SNDRV_PCM_IOCTL_SYNC_PTR 0xc0844123
+#endif
+#ifdef SNDRV_PCM_IOCTL_WRITEI_FRAMES
+# undef SNDRV_PCM_IOCTL_WRITEI_FRAMES
+# define SNDRV_PCM_IOCTL_WRITEI_FRAMES 0x400c4150
+#endif
+#ifdef SNDRV_PCM_IOCTL_WRITEN_FRAMES
+# undef SNDRV_PCM_IOCTL_WRITEN_FRAMES
+# define SNDRV_PCM_IOCTL_WRITEN_FRAMES 0x400c4152
+#endif
+#ifdef SNDRV_RAWMIDI_IOCTL_PARAMS
+# undef SNDRV_RAWMIDI_IOCTL_PARAMS
+# define SNDRV_RAWMIDI_IOCTL_PARAMS 0xc0205710
+#endif
+#ifdef SNDRV_RAWMIDI_IOCTL_STATUS
+# undef SNDRV_RAWMIDI_IOCTL_STATUS
+# define SNDRV_RAWMIDI_IOCTL_STATUS 0xc0245720
+#endif
+#ifdef SNDRV_SEQ_IOCTL_CREATE_PORT
+# undef SNDRV_SEQ_IOCTL_CREATE_PORT
+# define SNDRV_SEQ_IOCTL_CREATE_PORT 0xc0a45320
+#endif
+#ifdef SNDRV_SEQ_IOCTL_DELETE_PORT
+# undef SNDRV_SEQ_IOCTL_DELETE_PORT
+# define SNDRV_SEQ_IOCTL_DELETE_PORT 0x40a45321
+#endif
+#ifdef SNDRV_SEQ_IOCTL_GET_PORT_INFO
+# undef SNDRV_SEQ_IOCTL_GET_PORT_INFO
+# define SNDRV_SEQ_IOCTL_GET_PORT_INFO 0xc0a45322
+#endif
+#ifdef SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT
+# undef SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT
+# define SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT 0xc0a45352
+#endif
+#ifdef SNDRV_SEQ_IOCTL_SET_PORT_INFO
+# undef SNDRV_SEQ_IOCTL_SET_PORT_INFO
+# define SNDRV_SEQ_IOCTL_SET_PORT_INFO 0x40a45323
+#endif
+#ifdef SNDRV_TIMER_IOCTL_GINFO
+# undef SNDRV_TIMER_IOCTL_GINFO
+# define SNDRV_TIMER_IOCTL_GINFO 0xc0e05403
+#endif
+#ifdef SNDRV_TIMER_IOCTL_GPARAMS
+# undef SNDRV_TIMER_IOCTL_GPARAMS
+# define SNDRV_TIMER_IOCTL_GPARAMS 0x403c5404
+#endif
+#ifdef SNDRV_TIMER_IOCTL_GSTATUS
+# undef SNDRV_TIMER_IOCTL_GSTATUS
+# define SNDRV_TIMER_IOCTL_GSTATUS 0xc0405405
+#endif
+#ifdef SNDRV_TIMER_IOCTL_INFO
+# undef SNDRV_TIMER_IOCTL_INFO
+# define SNDRV_TIMER_IOCTL_INFO 0x80e05411
+#endif
+#ifdef SNDRV_TIMER_IOCTL_STATUS
+# undef SNDRV_TIMER_IOCTL_STATUS
+# define SNDRV_TIMER_IOCTL_STATUS 0x80585414
+#endif
+#ifdef SPIOCSTYPE
+# undef SPIOCSTYPE
+# define SPIOCSTYPE 0x40047101
+#endif
+#ifdef TUNATTACHFILTER
+# undef TUNATTACHFILTER
+# define TUNATTACHFILTER 0x400854d5
+#endif
+#ifdef TUNDETACHFILTER
+# undef TUNDETACHFILTER
+# define TUNDETACHFILTER 0x400854d6
+#endif
+#ifdef TUNER_SET_CONFIG
+# undef TUNER_SET_CONFIG
+# define TUNER_SET_CONFIG 0x4008645c
+#endif
+#ifdef TUNGETFILTER
+# undef TUNGETFILTER
+# define TUNGETFILTER 0x800854db
+#endif
+#ifdef UDF_GETEABLOCK
+# undef UDF_GETEABLOCK
+# define UDF_GETEABLOCK 0x80046c41
+#endif
+#ifdef UDF_GETVOLIDENT
+# undef UDF_GETVOLIDENT
+# define UDF_GETVOLIDENT 0x80046c42
+#endif
+#ifdef UDF_RELOCATE_BLOCKS
+# undef UDF_RELOCATE_BLOCKS
+# define UDF_RELOCATE_BLOCKS 0xc0046c43
+#endif
+#ifdef UI_BEGIN_FF_UPLOAD
+# undef UI_BEGIN_FF_UPLOAD
+# define UI_BEGIN_FF_UPLOAD 0xc06055c8
+#endif
+#ifdef UI_END_FF_UPLOAD
+# undef UI_END_FF_UPLOAD
+# define UI_END_FF_UPLOAD 0x406055c9
+#endif
+#ifdef UI_SET_PHYS
+# undef UI_SET_PHYS
+# define UI_SET_PHYS 0x4004556c
+#endif
+#ifdef USBDEVFS_BULK
+# undef USBDEVFS_BULK
+# define USBDEVFS_BULK 0xc0105502
+#endif
+#ifdef USBDEVFS_CONTROL
+# undef USBDEVFS_CONTROL
+# define USBDEVFS_CONTROL 0xc0105500
+#endif
+#ifdef USBDEVFS_DISCSIGNAL
+# undef USBDEVFS_DISCSIGNAL
+# define USBDEVFS_DISCSIGNAL 0x8008550e
+#endif
+#ifdef USBDEVFS_IOCTL
+# undef USBDEVFS_IOCTL
+# define USBDEVFS_IOCTL 0xc00c5512
+#endif
+#ifdef USBDEVFS_REAPURB
+# undef USBDEVFS_REAPURB
+# define USBDEVFS_REAPURB 0x4004550c
+#endif
+#ifdef USBDEVFS_REAPURBNDELAY
+# undef USBDEVFS_REAPURBNDELAY
+# define USBDEVFS_REAPURBNDELAY 0x4004550d
+#endif
+#ifdef USBDEVFS_SUBMITURB
+# undef USBDEVFS_SUBMITURB
+# define USBDEVFS_SUBMITURB 0x802c550a
+#endif
+#ifdef UVCIOC_CTRL_MAP
+# undef UVCIOC_CTRL_MAP
+# define UVCIOC_CTRL_MAP 0xc0587520
+#endif
+#ifdef UVCIOC_CTRL_QUERY
+# undef UVCIOC_CTRL_QUERY
+# define UVCIOC_CTRL_QUERY 0xc00c7521
+#endif
+#ifdef V4L2_DEVICE_NOTIFY_EVENT
+# undef V4L2_DEVICE_NOTIFY_EVENT
+# define V4L2_DEVICE_NOTIFY_EVENT 0x40787602
+#endif
+#ifdef VFAT_IOCTL_READDIR_BOTH
+# undef VFAT_IOCTL_READDIR_BOTH
+# define VFAT_IOCTL_READDIR_BOTH 0x82187201
+#endif
+#ifdef VFAT_IOCTL_READDIR_SHORT
+# undef VFAT_IOCTL_READDIR_SHORT
+# define VFAT_IOCTL_READDIR_SHORT 0x82187202
+#endif
+#ifdef VIDEO_GET_EVENT
+# undef VIDEO_GET_EVENT
+# define VIDEO_GET_EVENT 0x80146f1c
+#endif
+#ifdef VIDEO_SET_SPU_PALETTE
+# undef VIDEO_SET_SPU_PALETTE
+# define VIDEO_SET_SPU_PALETTE 0x40086f33
+#endif
+#ifdef VIDEO_STILLPICTURE
+# undef VIDEO_STILLPICTURE
+# define VIDEO_STILLPICTURE 0x40086f1e
+#endif
+#ifdef VIDIOC_AM437X_CCDC_CFG
+# undef VIDIOC_AM437X_CCDC_CFG
+# define VIDIOC_AM437X_CCDC_CFG 0x400456c1
+#endif
+#ifdef VIDIOC_CREATE_BUFS
+# undef VIDIOC_CREATE_BUFS
+# define VIDIOC_CREATE_BUFS 0xc0f8565c
+#endif
+#ifdef VIDIOC_DQBUF
+# undef VIDIOC_DQBUF
+# define VIDIOC_DQBUF 0xc0445611
+#endif
+#ifdef VIDIOC_DQEVENT
+# undef VIDIOC_DQEVENT
+# define VIDIOC_DQEVENT 0x80785659
+#endif
+#ifdef VIDIOC_ENUMINPUT
+# undef VIDIOC_ENUMINPUT
+# define VIDIOC_ENUMINPUT 0xc04c561a
+#endif
+#ifdef VIDIOC_ENUMSTD
+# undef VIDIOC_ENUMSTD
+# define VIDIOC_ENUMSTD 0xc0405619
+#endif
+#ifdef VIDIOC_G_EDID
+# undef VIDIOC_G_EDID
+# define VIDIOC_G_EDID 0xc0245628
+#endif
+#ifdef VIDIOC_G_EXT_CTRLS
+# undef VIDIOC_G_EXT_CTRLS
+# define VIDIOC_G_EXT_CTRLS 0xc0185647
+#endif
+#ifdef VIDIOC_G_FBUF
+# undef VIDIOC_G_FBUF
+# define VIDIOC_G_FBUF 0x802c560a
+#endif
+#ifdef VIDIOC_G_FMT
+# undef VIDIOC_G_FMT
+# define VIDIOC_G_FMT 0xc0cc5604
+#endif
+#ifdef VIDIOC_OMAP3ISP_CCDC_CFG
+# undef VIDIOC_OMAP3ISP_CCDC_CFG
+# define VIDIOC_OMAP3ISP_CCDC_CFG 0xc02056c1
+#endif
+#ifdef VIDIOC_OMAP3ISP_PRV_CFG
+# undef VIDIOC_OMAP3ISP_PRV_CFG
+# define VIDIOC_OMAP3ISP_PRV_CFG 0xc03c56c2
+#endif
+#ifdef VIDIOC_OMAP3ISP_STAT_EN
+# undef VIDIOC_OMAP3ISP_STAT_EN
+# define VIDIOC_OMAP3ISP_STAT_EN 0xc00456c7
+#endif
+#ifdef VIDIOC_OMAP3ISP_STAT_REQ
+# undef VIDIOC_OMAP3ISP_STAT_REQ
+# define VIDIOC_OMAP3ISP_STAT_REQ 0xc01856c6
+#endif
+#ifdef VIDIOC_PREPARE_BUF
+# undef VIDIOC_PREPARE_BUF
+# define VIDIOC_PREPARE_BUF 0xc044565d
+#endif
+#ifdef VIDIOC_QBUF
+# undef VIDIOC_QBUF
+# define VIDIOC_QBUF 0xc044560f
+#endif
+#ifdef VIDIOC_QUERYBUF
+# undef VIDIOC_QUERYBUF
+# define VIDIOC_QUERYBUF 0xc0445609
+#endif
+#ifdef VIDIOC_S_EDID
+# undef VIDIOC_S_EDID
+# define VIDIOC_S_EDID 0xc0245629
+#endif
+#ifdef VIDIOC_S_EXT_CTRLS
+# undef VIDIOC_S_EXT_CTRLS
+# define VIDIOC_S_EXT_CTRLS 0xc0185648
+#endif
+#ifdef VIDIOC_S_FBUF
+# undef VIDIOC_S_FBUF
+# define VIDIOC_S_FBUF 0x402c560b
+#endif
+#ifdef VIDIOC_S_FMT
+# undef VIDIOC_S_FMT
+# define VIDIOC_S_FMT 0xc0cc5605
+#endif
+#ifdef VIDIOC_SUBDEV_G_EDID
+# undef VIDIOC_SUBDEV_G_EDID
+# define VIDIOC_SUBDEV_G_EDID 0xc0245628
+#endif
+#ifdef VIDIOC_SUBDEV_S_EDID
+# undef VIDIOC_SUBDEV_S_EDID
+# define VIDIOC_SUBDEV_S_EDID 0xc0245629
+#endif
+#ifdef VIDIOC_TRY_EXT_CTRLS
+# undef VIDIOC_TRY_EXT_CTRLS
+# define VIDIOC_TRY_EXT_CTRLS 0xc0185649
+#endif
+#ifdef VIDIOC_TRY_FMT
+# undef VIDIOC_TRY_FMT
+# define VIDIOC_TRY_FMT 0xc0cc5640
+#endif
+#ifdef VPFE_CMD_S_CCDC_RAW_PARAMS
+# undef VPFE_CMD_S_CCDC_RAW_PARAMS
+# define VPFE_CMD_S_CCDC_RAW_PARAMS 0x400456c1
+#endif
+#ifdef ZATM_GETPOOL
+# undef ZATM_GETPOOL
+# define ZATM_GETPOOL 0x400c6161
+#endif
+#ifdef ZATM_GETPOOLZ
+# undef ZATM_GETPOOLZ
+# define ZATM_GETPOOLZ 0x400c6162
+#endif
+#ifdef ZATM_SETPOOL
+# undef ZATM_SETPOOL
+# define ZATM_SETPOOL 0x400c6163
+#endif
diff --git a/strace/ioctl_redefs2.h b/strace/ioctl_redefs2.h
new file mode 100644
index 0000000..d691a61
--- /dev/null
+++ b/strace/ioctl_redefs2.h
@@ -0,0 +1,1312 @@
+#ifdef AGPIOC_ALLOCATE
+# undef AGPIOC_ALLOCATE
+# define AGPIOC_ALLOCATE 0xc0044106
+#endif
+#ifdef AGPIOC_BIND
+# undef AGPIOC_BIND
+# define AGPIOC_BIND 0x40044108
+#endif
+#ifdef AGPIOC_INFO
+# undef AGPIOC_INFO
+# define AGPIOC_INFO 0x80044100
+#endif
+#ifdef AGPIOC_PROTECT
+# undef AGPIOC_PROTECT
+# define AGPIOC_PROTECT 0x40044105
+#endif
+#ifdef AGPIOC_RESERVE
+# undef AGPIOC_RESERVE
+# define AGPIOC_RESERVE 0x40044104
+#endif
+#ifdef AGPIOC_SETUP
+# undef AGPIOC_SETUP
+# define AGPIOC_SETUP 0x40044103
+#endif
+#ifdef AGPIOC_UNBIND
+# undef AGPIOC_UNBIND
+# define AGPIOC_UNBIND 0x40044109
+#endif
+#ifdef ASHMEM_SET_PROT_MASK
+# undef ASHMEM_SET_PROT_MASK
+# define ASHMEM_SET_PROT_MASK 0x40047705
+#endif
+#ifdef ASHMEM_SET_SIZE
+# undef ASHMEM_SET_SIZE
+# define ASHMEM_SET_SIZE 0x40047703
+#endif
+#ifdef ATM_ADDADDR
+# undef ATM_ADDADDR
+# define ATM_ADDADDR 0x400c6188
+#endif
+#ifdef ATM_ADDLECSADDR
+# undef ATM_ADDLECSADDR
+# define ATM_ADDLECSADDR 0x400c618e
+#endif
+#ifdef ATM_ADDPARTY
+# undef ATM_ADDPARTY
+# define ATM_ADDPARTY 0x400861f4
+#endif
+#ifdef ATM_DELADDR
+# undef ATM_DELADDR
+# define ATM_DELADDR 0x400c6189
+#endif
+#ifdef ATM_DELLECSADDR
+# undef ATM_DELLECSADDR
+# define ATM_DELLECSADDR 0x400c618f
+#endif
+#ifdef ATM_GETADDR
+# undef ATM_GETADDR
+# define ATM_GETADDR 0x400c6186
+#endif
+#ifdef ATM_GETCIRANGE
+# undef ATM_GETCIRANGE
+# define ATM_GETCIRANGE 0x400c618a
+#endif
+#ifdef ATM_GETESI
+# undef ATM_GETESI
+# define ATM_GETESI 0x400c6185
+#endif
+#ifdef ATM_GETLECSADDR
+# undef ATM_GETLECSADDR
+# define ATM_GETLECSADDR 0x400c6190
+#endif
+#ifdef ATM_GETLINKRATE
+# undef ATM_GETLINKRATE
+# define ATM_GETLINKRATE 0x400c6181
+#endif
+#ifdef ATM_GETLOOP
+# undef ATM_GETLOOP
+# define ATM_GETLOOP 0x400c6152
+#endif
+#ifdef ATM_GETNAMES
+# undef ATM_GETNAMES
+# define ATM_GETNAMES 0x40086183
+#endif
+#ifdef ATM_GETSTAT
+# undef ATM_GETSTAT
+# define ATM_GETSTAT 0x400c6150
+#endif
+#ifdef ATM_GETSTATZ
+# undef ATM_GETSTATZ
+# define ATM_GETSTATZ 0x400c6151
+#endif
+#ifdef ATM_GETTYPE
+# undef ATM_GETTYPE
+# define ATM_GETTYPE 0x400c6184
+#endif
+#ifdef ATM_QUERYLOOP
+# undef ATM_QUERYLOOP
+# define ATM_QUERYLOOP 0x400c6154
+#endif
+#ifdef ATM_RSTADDR
+# undef ATM_RSTADDR
+# define ATM_RSTADDR 0x400c6187
+#endif
+#ifdef ATM_SETCIRANGE
+# undef ATM_SETCIRANGE
+# define ATM_SETCIRANGE 0x400c618b
+#endif
+#ifdef ATM_SETESI
+# undef ATM_SETESI
+# define ATM_SETESI 0x400c618c
+#endif
+#ifdef ATM_SETESIF
+# undef ATM_SETESIF
+# define ATM_SETESIF 0x400c618d
+#endif
+#ifdef ATM_SETLOOP
+# undef ATM_SETLOOP
+# define ATM_SETLOOP 0x400c6153
+#endif
+#ifdef AUTOFS_IOC_SETTIMEOUT
+# undef AUTOFS_IOC_SETTIMEOUT
+# define AUTOFS_IOC_SETTIMEOUT 0xc0049364
+#endif
+#ifdef BLKBSZGET
+# undef BLKBSZGET
+# define BLKBSZGET 0x80041270
+#endif
+#ifdef BLKBSZSET
+# undef BLKBSZSET
+# define BLKBSZSET 0x40041271
+#endif
+#ifdef BLKGETSIZE64
+# undef BLKGETSIZE64
+# define BLKGETSIZE64 0x80041272
+#endif
+#ifdef CAPI_MANUFACTURER_CMD
+# undef CAPI_MANUFACTURER_CMD
+# define CAPI_MANUFACTURER_CMD 0xc0084320
+#endif
+#ifdef CCISS_BIG_PASSTHRU
+# undef CCISS_BIG_PASSTHRU
+# define CCISS_BIG_PASSTHRU 0xc0584212
+#endif
+#ifdef CCISS_PASSTHRU
+# undef CCISS_PASSTHRU
+# define CCISS_PASSTHRU 0xc054420b
+#endif
+#ifdef CHIOGSTATUS
+# undef CHIOGSTATUS
+# define CHIOGSTATUS 0x40086308
+#endif
+#ifdef CIOC_KERNEL_VERSION
+# undef CIOC_KERNEL_VERSION
+# define CIOC_KERNEL_VERSION 0xc004630a
+#endif
+#ifdef CM_IOCGATR
+# undef CM_IOCGATR
+# define CM_IOCGATR 0xc0046301
+#endif
+#ifdef CM_IOCGSTATUS
+# undef CM_IOCGSTATUS
+# define CM_IOCGSTATUS 0x80046300
+#endif
+#ifdef CM_IOCSPTS
+# undef CM_IOCSPTS
+# define CM_IOCSPTS 0x40046302
+#endif
+#ifdef CM_IOSDBGLVL
+# undef CM_IOSDBGLVL
+# define CM_IOSDBGLVL 0x400463fa
+#endif
+#ifdef DRM_IOCTL_ADD_BUFS
+# undef DRM_IOCTL_ADD_BUFS
+# define DRM_IOCTL_ADD_BUFS 0xc0186416
+#endif
+#ifdef DRM_IOCTL_ADD_MAP
+# undef DRM_IOCTL_ADD_MAP
+# define DRM_IOCTL_ADD_MAP 0xc0186415
+#endif
+#ifdef DRM_IOCTL_AGP_ALLOC
+# undef DRM_IOCTL_AGP_ALLOC
+# define DRM_IOCTL_AGP_ALLOC 0xc0106434
+#endif
+#ifdef DRM_IOCTL_AGP_BIND
+# undef DRM_IOCTL_AGP_BIND
+# define DRM_IOCTL_AGP_BIND 0x40086436
+#endif
+#ifdef DRM_IOCTL_AGP_ENABLE
+# undef DRM_IOCTL_AGP_ENABLE
+# define DRM_IOCTL_AGP_ENABLE 0x40046432
+#endif
+#ifdef DRM_IOCTL_AGP_FREE
+# undef DRM_IOCTL_AGP_FREE
+# define DRM_IOCTL_AGP_FREE 0x40106435
+#endif
+#ifdef DRM_IOCTL_AGP_INFO
+# undef DRM_IOCTL_AGP_INFO
+# define DRM_IOCTL_AGP_INFO 0x80206433
+#endif
+#ifdef DRM_IOCTL_AGP_UNBIND
+# undef DRM_IOCTL_AGP_UNBIND
+# define DRM_IOCTL_AGP_UNBIND 0x40086437
+#endif
+#ifdef DRM_IOCTL_DMA
+# undef DRM_IOCTL_DMA
+# define DRM_IOCTL_DMA 0xc0286429
+#endif
+#ifdef DRM_IOCTL_FREE_BUFS
+# undef DRM_IOCTL_FREE_BUFS
+# define DRM_IOCTL_FREE_BUFS 0x4008641a
+#endif
+#ifdef DRM_IOCTL_GET_CLIENT
+# undef DRM_IOCTL_GET_CLIENT
+# define DRM_IOCTL_GET_CLIENT 0xc0186405
+#endif
+#ifdef DRM_IOCTL_GET_MAP
+# undef DRM_IOCTL_GET_MAP
+# define DRM_IOCTL_GET_MAP 0xc0186404
+#endif
+#ifdef DRM_IOCTL_GET_SAREA_CTX
+# undef DRM_IOCTL_GET_SAREA_CTX
+# define DRM_IOCTL_GET_SAREA_CTX 0xc008641d
+#endif
+#ifdef DRM_IOCTL_GET_STATS
+# undef DRM_IOCTL_GET_STATS
+# define DRM_IOCTL_GET_STATS 0x807c6406
+#endif
+#ifdef DRM_IOCTL_GET_UNIQUE
+# undef DRM_IOCTL_GET_UNIQUE
+# define DRM_IOCTL_GET_UNIQUE 0xc0086401
+#endif
+#ifdef DRM_IOCTL_I810_COPY
+# undef DRM_IOCTL_I810_COPY
+# define DRM_IOCTL_I810_COPY 0x400c6447
+#endif
+#ifdef DRM_IOCTL_I810_GETBUF
+# undef DRM_IOCTL_I810_GETBUF
+# define DRM_IOCTL_I810_GETBUF 0xc0106445
+#endif
+#ifdef DRM_IOCTL_I810_MC
+# undef DRM_IOCTL_I810_MC
+# define DRM_IOCTL_I810_MC 0x4014644c
+#endif
+#ifdef DRM_IOCTL_I915_ALLOC
+# undef DRM_IOCTL_I915_ALLOC
+# define DRM_IOCTL_I915_ALLOC 0xc0106448
+#endif
+#ifdef DRM_IOCTL_I915_BATCHBUFFER
+# undef DRM_IOCTL_I915_BATCHBUFFER
+# define DRM_IOCTL_I915_BATCHBUFFER 0x40186443
+#endif
+#ifdef DRM_IOCTL_I915_CMDBUFFER
+# undef DRM_IOCTL_I915_CMDBUFFER
+# define DRM_IOCTL_I915_CMDBUFFER 0x4018644b
+#endif
+#ifdef DRM_IOCTL_I915_GETPARAM
+# undef DRM_IOCTL_I915_GETPARAM
+# define DRM_IOCTL_I915_GETPARAM 0xc0086446
+#endif
+#ifdef DRM_IOCTL_I915_IRQ_EMIT
+# undef DRM_IOCTL_I915_IRQ_EMIT
+# define DRM_IOCTL_I915_IRQ_EMIT 0xc0046444
+#endif
+#ifdef DRM_IOCTL_INFO_BUFS
+# undef DRM_IOCTL_INFO_BUFS
+# define DRM_IOCTL_INFO_BUFS 0xc0086418
+#endif
+#ifdef DRM_IOCTL_MAP_BUFS
+# undef DRM_IOCTL_MAP_BUFS
+# define DRM_IOCTL_MAP_BUFS 0xc00c6419
+#endif
+#ifdef DRM_IOCTL_MARK_BUFS
+# undef DRM_IOCTL_MARK_BUFS
+# define DRM_IOCTL_MARK_BUFS 0x40186417
+#endif
+#ifdef DRM_IOCTL_MGA_DMA_BOOTSTRAP
+# undef DRM_IOCTL_MGA_DMA_BOOTSTRAP
+# define DRM_IOCTL_MGA_DMA_BOOTSTRAP 0xc01c644c
+#endif
+#ifdef DRM_IOCTL_MGA_GETPARAM
+# undef DRM_IOCTL_MGA_GETPARAM
+# define DRM_IOCTL_MGA_GETPARAM 0xc0086449
+#endif
+#ifdef DRM_IOCTL_MGA_INIT
+# undef DRM_IOCTL_MGA_INIT
+# define DRM_IOCTL_MGA_INIT 0x405c6440
+#endif
+#ifdef DRM_IOCTL_R128_DEPTH
+# undef DRM_IOCTL_R128_DEPTH
+# define DRM_IOCTL_R128_DEPTH 0x4018644c
+#endif
+#ifdef DRM_IOCTL_R128_GETPARAM
+# undef DRM_IOCTL_R128_GETPARAM
+# define DRM_IOCTL_R128_GETPARAM 0xc0086452
+#endif
+#ifdef DRM_IOCTL_R128_INIT
+# undef DRM_IOCTL_R128_INIT
+# define DRM_IOCTL_R128_INIT 0x40586440
+#endif
+#ifdef DRM_IOCTL_R128_STIPPLE
+# undef DRM_IOCTL_R128_STIPPLE
+# define DRM_IOCTL_R128_STIPPLE 0x4004644d
+#endif
+#ifdef DRM_IOCTL_RADEON_ALLOC
+# undef DRM_IOCTL_RADEON_ALLOC
+# define DRM_IOCTL_RADEON_ALLOC 0xc0106453
+#endif
+#ifdef DRM_IOCTL_RADEON_CLEAR
+# undef DRM_IOCTL_RADEON_CLEAR
+# define DRM_IOCTL_RADEON_CLEAR 0x40186448
+#endif
+#ifdef DRM_IOCTL_RADEON_CMDBUF
+# undef DRM_IOCTL_RADEON_CMDBUF
+# define DRM_IOCTL_RADEON_CMDBUF 0x40106450
+#endif
+#ifdef DRM_IOCTL_RADEON_CP_INIT
+# undef DRM_IOCTL_RADEON_CP_INIT
+# define DRM_IOCTL_RADEON_CP_INIT 0x40546440
+#endif
+#ifdef DRM_IOCTL_RADEON_GETPARAM
+# undef DRM_IOCTL_RADEON_GETPARAM
+# define DRM_IOCTL_RADEON_GETPARAM 0xc0086451
+#endif
+#ifdef DRM_IOCTL_RADEON_IRQ_EMIT
+# undef DRM_IOCTL_RADEON_IRQ_EMIT
+# define DRM_IOCTL_RADEON_IRQ_EMIT 0xc0046456
+#endif
+#ifdef DRM_IOCTL_RADEON_STIPPLE
+# undef DRM_IOCTL_RADEON_STIPPLE
+# define DRM_IOCTL_RADEON_STIPPLE 0x4004644c
+#endif
+#ifdef DRM_IOCTL_RADEON_TEXTURE
+# undef DRM_IOCTL_RADEON_TEXTURE
+# define DRM_IOCTL_RADEON_TEXTURE 0xc018644e
+#endif
+#ifdef DRM_IOCTL_RADEON_VERTEX2
+# undef DRM_IOCTL_RADEON_VERTEX2
+# define DRM_IOCTL_RADEON_VERTEX2 0x4018644f
+#endif
+#ifdef DRM_IOCTL_RES_CTX
+# undef DRM_IOCTL_RES_CTX
+# define DRM_IOCTL_RES_CTX 0xc0086426
+#endif
+#ifdef DRM_IOCTL_RM_MAP
+# undef DRM_IOCTL_RM_MAP
+# define DRM_IOCTL_RM_MAP 0x4018641b
+#endif
+#ifdef DRM_IOCTL_SAVAGE_BCI_CMDBUF
+# undef DRM_IOCTL_SAVAGE_BCI_CMDBUF
+# define DRM_IOCTL_SAVAGE_BCI_CMDBUF 0x40246441
+#endif
+#ifdef DRM_IOCTL_SAVAGE_BCI_INIT
+# undef DRM_IOCTL_SAVAGE_BCI_INIT
+# define DRM_IOCTL_SAVAGE_BCI_INIT 0x40506440
+#endif
+#ifdef DRM_IOCTL_SET_SAREA_CTX
+# undef DRM_IOCTL_SET_SAREA_CTX
+# define DRM_IOCTL_SET_SAREA_CTX 0x4008641c
+#endif
+#ifdef DRM_IOCTL_SET_UNIQUE
+# undef DRM_IOCTL_SET_UNIQUE
+# define DRM_IOCTL_SET_UNIQUE 0x40086410
+#endif
+#ifdef DRM_IOCTL_SG_ALLOC
+# undef DRM_IOCTL_SG_ALLOC
+# define DRM_IOCTL_SG_ALLOC 0xc0086438
+#endif
+#ifdef DRM_IOCTL_SG_FREE
+# undef DRM_IOCTL_SG_FREE
+# define DRM_IOCTL_SG_FREE 0x40086439
+#endif
+#ifdef DRM_IOCTL_SIS_AGP_ALLOC
+# undef DRM_IOCTL_SIS_AGP_ALLOC
+# define DRM_IOCTL_SIS_AGP_ALLOC 0xc0106454
+#endif
+#ifdef DRM_IOCTL_SIS_AGP_FREE
+# undef DRM_IOCTL_SIS_AGP_FREE
+# define DRM_IOCTL_SIS_AGP_FREE 0x40106455
+#endif
+#ifdef DRM_IOCTL_SIS_AGP_INIT
+# undef DRM_IOCTL_SIS_AGP_INIT
+# define DRM_IOCTL_SIS_AGP_INIT 0xc0086453
+#endif
+#ifdef DRM_IOCTL_SIS_FB_ALLOC
+# undef DRM_IOCTL_SIS_FB_ALLOC
+# define DRM_IOCTL_SIS_FB_ALLOC 0xc0106444
+#endif
+#ifdef DRM_IOCTL_SIS_FB_FREE
+# undef DRM_IOCTL_SIS_FB_FREE
+# define DRM_IOCTL_SIS_FB_FREE 0x40106445
+#endif
+#ifdef DRM_IOCTL_SIS_FB_INIT
+# undef DRM_IOCTL_SIS_FB_INIT
+# define DRM_IOCTL_SIS_FB_INIT 0x40086456
+#endif
+#ifdef DRM_IOCTL_VERSION
+# undef DRM_IOCTL_VERSION
+# define DRM_IOCTL_VERSION 0xc0246400
+#endif
+#ifdef DRM_IOCTL_VIA_ALLOCMEM
+# undef DRM_IOCTL_VIA_ALLOCMEM
+# define DRM_IOCTL_VIA_ALLOCMEM 0xc0146440
+#endif
+#ifdef DRM_IOCTL_VIA_CMDBUFFER
+# undef DRM_IOCTL_VIA_CMDBUFFER
+# define DRM_IOCTL_VIA_CMDBUFFER 0x40086448
+#endif
+#ifdef DRM_IOCTL_VIA_DMA_BLIT
+# undef DRM_IOCTL_VIA_DMA_BLIT
+# define DRM_IOCTL_VIA_DMA_BLIT 0x4028644e
+#endif
+#ifdef DRM_IOCTL_VIA_DMA_INIT
+# undef DRM_IOCTL_VIA_DMA_INIT
+# define DRM_IOCTL_VIA_DMA_INIT 0xc0106447
+#endif
+#ifdef DRM_IOCTL_VIA_FREEMEM
+# undef DRM_IOCTL_VIA_FREEMEM
+# define DRM_IOCTL_VIA_FREEMEM 0x40146441
+#endif
+#ifdef DRM_IOCTL_VIA_MAP_INIT
+# undef DRM_IOCTL_VIA_MAP_INIT
+# define DRM_IOCTL_VIA_MAP_INIT 0xc0146444
+#endif
+#ifdef DRM_IOCTL_VIA_PCICMD
+# undef DRM_IOCTL_VIA_PCICMD
+# define DRM_IOCTL_VIA_PCICMD 0x4008644a
+#endif
+#ifdef DRM_IOCTL_VIA_WAIT_IRQ
+# undef DRM_IOCTL_VIA_WAIT_IRQ
+# define DRM_IOCTL_VIA_WAIT_IRQ 0xc010644d
+#endif
+#ifdef DRM_IOCTL_WAIT_VBLANK
+# undef DRM_IOCTL_WAIT_VBLANK
+# define DRM_IOCTL_WAIT_VBLANK 0xc010643a
+#endif
+#ifdef ENI_MEMDUMP
+# undef ENI_MEMDUMP
+# define ENI_MEMDUMP 0x400c6160
+#endif
+#ifdef ENI_SETMULT
+# undef ENI_SETMULT
+# define ENI_SETMULT 0x400c6167
+#endif
+#ifdef EVIOCSFF
+# undef EVIOCSFF
+# define EVIOCSFF 0x402c4580
+#endif
+#ifdef FBIO_CURSOR
+# undef FBIO_CURSOR
+# define FBIO_CURSOR 0xc0484608
+#endif
+#ifdef FBIO_GETCONTROL2
+# undef FBIO_GETCONTROL2
+# define FBIO_GETCONTROL2 0x80044689
+#endif
+#ifdef FBIO_RADEON_GET_MIRROR
+# undef FBIO_RADEON_GET_MIRROR
+# define FBIO_RADEON_GET_MIRROR 0x80044003
+#endif
+#ifdef FBIO_RADEON_SET_MIRROR
+# undef FBIO_RADEON_SET_MIRROR
+# define FBIO_RADEON_SET_MIRROR 0x40044004
+#endif
+#ifdef FDDEFPRM
+# undef FDDEFPRM
+# define FDDEFPRM 0x401c0243
+#endif
+#ifdef FDGETDRVPRM
+# undef FDGETDRVPRM
+# define FDGETDRVPRM 0x80580211
+#endif
+#ifdef FDGETDRVSTAT
+# undef FDGETDRVSTAT
+# define FDGETDRVSTAT 0x80340212
+#endif
+#ifdef FDGETFDCSTAT
+# undef FDGETFDCSTAT
+# define FDGETFDCSTAT 0x80200215
+#endif
+#ifdef FDGETPRM
+# undef FDGETPRM
+# define FDGETPRM 0x801c0204
+#endif
+#ifdef FDPOLLDRVSTAT
+# undef FDPOLLDRVSTAT
+# define FDPOLLDRVSTAT 0x80340213
+#endif
+#ifdef FDSETDRVPRM
+# undef FDSETDRVPRM
+# define FDSETDRVPRM 0x40580290
+#endif
+#ifdef FDSETPRM
+# undef FDSETPRM
+# define FDSETPRM 0x401c0242
+#endif
+#ifdef FDWERRORGET
+# undef FDWERRORGET
+# define FDWERRORGET 0x80180217
+#endif
+#ifdef FE_GET_PROPERTY
+# undef FE_GET_PROPERTY
+# define FE_GET_PROPERTY 0x80086f53
+#endif
+#ifdef FE_SET_PROPERTY
+# undef FE_SET_PROPERTY
+# define FE_SET_PROPERTY 0x40086f52
+#endif
+#ifdef FS_IOC_GETFLAGS
+# undef FS_IOC_GETFLAGS
+# define FS_IOC_GETFLAGS 0x80046601
+#endif
+#ifdef FS_IOC_GETVERSION
+# undef FS_IOC_GETVERSION
+# define FS_IOC_GETVERSION 0x80047601
+#endif
+#ifdef FS_IOC_SETFLAGS
+# undef FS_IOC_SETFLAGS
+# define FS_IOC_SETFLAGS 0x40046602
+#endif
+#ifdef FS_IOC_SETVERSION
+# undef FS_IOC_SETVERSION
+# define FS_IOC_SETVERSION 0x40047602
+#endif
+#ifdef HE_GET_REG
+# undef HE_GET_REG
+# define HE_GET_REG 0x400c6160
+#endif
+#ifdef HFI1_IOCTL_ACK_EVENT
+# undef HFI1_IOCTL_ACK_EVENT
+# define HFI1_IOCTL_ACK_EVENT 0x40041bea
+#endif
+#ifdef HPET_INFO
+# undef HPET_INFO
+# define HPET_INFO 0x800c6803
+#endif
+#ifdef HPET_IRQFREQ
+# undef HPET_IRQFREQ
+# define HPET_IRQFREQ 0x40046806
+#endif
+#ifdef I2OHRTGET
+# undef I2OHRTGET
+# define I2OHRTGET 0xc00c6901
+#endif
+#ifdef I2OHTML
+# undef I2OHTML
+# define I2OHTML 0xc01c6909
+#endif
+#ifdef I2OLCTGET
+# undef I2OLCTGET
+# define I2OLCTGET 0xc00c6902
+#endif
+#ifdef I2OPARMGET
+# undef I2OPARMGET
+# define I2OPARMGET 0xc0186904
+#endif
+#ifdef I2OPARMSET
+# undef I2OPARMSET
+# define I2OPARMSET 0xc0186903
+#endif
+#ifdef I2OPASSTHRU
+# undef I2OPASSTHRU
+# define I2OPASSTHRU 0x8008690c
+#endif
+#ifdef I2OSWDEL
+# undef I2OSWDEL
+# define I2OSWDEL 0xc01c6907
+#endif
+#ifdef I2OSWDL
+# undef I2OSWDL
+# define I2OSWDL 0xc01c6905
+#endif
+#ifdef I2OSWUL
+# undef I2OSWUL
+# define I2OSWUL 0xc01c6906
+#endif
+#ifdef I8K_FN_STATUS
+# undef I8K_FN_STATUS
+# define I8K_FN_STATUS 0x80046983
+#endif
+#ifdef I8K_GET_FAN
+# undef I8K_GET_FAN
+# define I8K_GET_FAN 0xc0046986
+#endif
+#ifdef I8K_GET_SPEED
+# undef I8K_GET_SPEED
+# define I8K_GET_SPEED 0xc0046985
+#endif
+#ifdef I8K_GET_TEMP
+# undef I8K_GET_TEMP
+# define I8K_GET_TEMP 0x80046984
+#endif
+#ifdef I8K_POWER_STATUS
+# undef I8K_POWER_STATUS
+# define I8K_POWER_STATUS 0x80046982
+#endif
+#ifdef I8K_SET_FAN
+# undef I8K_SET_FAN
+# define I8K_SET_FAN 0xc0046987
+#endif
+#ifdef IDT77105_GETSTAT
+# undef IDT77105_GETSTAT
+# define IDT77105_GETSTAT 0x400c6132
+#endif
+#ifdef IDT77105_GETSTATZ
+# undef IDT77105_GETSTATZ
+# define IDT77105_GETSTATZ 0x400c6133
+#endif
+#ifdef IOCTL_GNTDEV_GRANT_COPY
+# undef IOCTL_GNTDEV_GRANT_COPY
+# define IOCTL_GNTDEV_GRANT_COPY 0x00084708
+#endif
+#ifdef ION_IOC_ALLOC
+# undef ION_IOC_ALLOC
+# define ION_IOC_ALLOC 0xc0144900
+#endif
+#ifdef ION_IOC_CUSTOM
+# undef ION_IOC_CUSTOM
+# define ION_IOC_CUSTOM 0xc0084906
+#endif
+#ifdef IOW_READ
+# undef IOW_READ
+# define IOW_READ 0x4004c002
+#endif
+#ifdef IOW_WRITE
+# undef IOW_WRITE
+# define IOW_WRITE 0x4004c001
+#endif
+#ifdef IPMICTL_RECEIVE_MSG
+# undef IPMICTL_RECEIVE_MSG
+# define IPMICTL_RECEIVE_MSG 0xc018690c
+#endif
+#ifdef IPMICTL_RECEIVE_MSG_TRUNC
+# undef IPMICTL_RECEIVE_MSG_TRUNC
+# define IPMICTL_RECEIVE_MSG_TRUNC 0xc018690b
+#endif
+#ifdef IPMICTL_SEND_COMMAND
+# undef IPMICTL_SEND_COMMAND
+# define IPMICTL_SEND_COMMAND 0x8014690d
+#endif
+#ifdef IPMICTL_SEND_COMMAND_SETTIME
+# undef IPMICTL_SEND_COMMAND_SETTIME
+# define IPMICTL_SEND_COMMAND_SETTIME 0x801c6915
+#endif
+#ifdef IVTVFB_IOC_DMA_FRAME
+# undef IVTVFB_IOC_DMA_FRAME
+# define IVTVFB_IOC_DMA_FRAME 0x400c56c0
+#endif
+#ifdef IVTV_IOC_DMA_FRAME
+# undef IVTV_IOC_DMA_FRAME
+# define IVTV_IOC_DMA_FRAME 0x403856c0
+#endif
+#ifdef IXJCTL_CID
+# undef IXJCTL_CID
+# define IXJCTL_CID 0x800471d4
+#endif
+#ifdef IXJCTL_CIDCW
+# undef IXJCTL_CIDCW
+# define IXJCTL_CIDCW 0x400471d9
+#endif
+#ifdef IXJCTL_DRYBUFFER_READ
+# undef IXJCTL_DRYBUFFER_READ
+# define IXJCTL_DRYBUFFER_READ 0x800471e6
+#endif
+#ifdef IXJCTL_FILTER_CADENCE
+# undef IXJCTL_FILTER_CADENCE
+# define IXJCTL_FILTER_CADENCE 0x400471d6
+#endif
+#ifdef IXJCTL_FRAMES_READ
+# undef IXJCTL_FRAMES_READ
+# define IXJCTL_FRAMES_READ 0x800471e2
+#endif
+#ifdef IXJCTL_FRAMES_WRITTEN
+# undef IXJCTL_FRAMES_WRITTEN
+# define IXJCTL_FRAMES_WRITTEN 0x800471e3
+#endif
+#ifdef IXJCTL_INIT_TONE
+# undef IXJCTL_INIT_TONE
+# define IXJCTL_INIT_TONE 0x400471c9
+#endif
+#ifdef IXJCTL_READ_WAIT
+# undef IXJCTL_READ_WAIT
+# define IXJCTL_READ_WAIT 0x800471e4
+#endif
+#ifdef IXJCTL_SET_FILTER
+# undef IXJCTL_SET_FILTER
+# define IXJCTL_SET_FILTER 0x400471c7
+#endif
+#ifdef IXJCTL_SET_FILTER_RAW
+# undef IXJCTL_SET_FILTER_RAW
+# define IXJCTL_SET_FILTER_RAW 0x400471dd
+#endif
+#ifdef IXJCTL_SIGCTL
+# undef IXJCTL_SIGCTL
+# define IXJCTL_SIGCTL 0x400471e9
+#endif
+#ifdef IXJCTL_TONE_CADENCE
+# undef IXJCTL_TONE_CADENCE
+# define IXJCTL_TONE_CADENCE 0x400471ca
+#endif
+#ifdef IXJCTL_VERSION
+# undef IXJCTL_VERSION
+# define IXJCTL_VERSION 0x800471da
+#endif
+#ifdef IXJCTL_WRITE_WAIT
+# undef IXJCTL_WRITE_WAIT
+# define IXJCTL_WRITE_WAIT 0x800471e5
+#endif
+#ifdef KCOV_INIT_TRACE
+# undef KCOV_INIT_TRACE
+# define KCOV_INIT_TRACE 0x80046301
+#endif
+#ifdef KVM_S390_STORE_STATUS
+# undef KVM_S390_STORE_STATUS
+# define KVM_S390_STORE_STATUS 0x4004ae95
+#endif
+#ifdef KVM_S390_VCPU_FAULT
+# undef KVM_S390_VCPU_FAULT
+# define KVM_S390_VCPU_FAULT 0x4004ae52
+#endif
+#ifdef MATROXFB_GET_ALL_OUTPUTS
+# undef MATROXFB_GET_ALL_OUTPUTS
+# define MATROXFB_GET_ALL_OUTPUTS 0x80046efb
+#endif
+#ifdef MATROXFB_GET_AVAILABLE_OUTPUTS
+# undef MATROXFB_GET_AVAILABLE_OUTPUTS
+# define MATROXFB_GET_AVAILABLE_OUTPUTS 0x80046ef9
+#endif
+#ifdef MATROXFB_GET_OUTPUT_CONNECTION
+# undef MATROXFB_GET_OUTPUT_CONNECTION
+# define MATROXFB_GET_OUTPUT_CONNECTION 0x80046ef8
+#endif
+#ifdef MATROXFB_GET_OUTPUT_MODE
+# undef MATROXFB_GET_OUTPUT_MODE
+# define MATROXFB_GET_OUTPUT_MODE 0xc0046efa
+#endif
+#ifdef MATROXFB_SET_OUTPUT_CONNECTION
+# undef MATROXFB_SET_OUTPUT_CONNECTION
+# define MATROXFB_SET_OUTPUT_CONNECTION 0x40046ef8
+#endif
+#ifdef MATROXFB_SET_OUTPUT_MODE
+# undef MATROXFB_SET_OUTPUT_MODE
+# define MATROXFB_SET_OUTPUT_MODE 0x40046efa
+#endif
+#ifdef MEDIA_IOC_ENUM_LINKS
+# undef MEDIA_IOC_ENUM_LINKS
+# define MEDIA_IOC_ENUM_LINKS 0xc01c7c02
+#endif
+#ifdef MEMREADOOB
+# undef MEMREADOOB
+# define MEMREADOOB 0xc00c4d04
+#endif
+#ifdef MEMWRITEOOB
+# undef MEMWRITEOOB
+# define MEMWRITEOOB 0xc00c4d03
+#endif
+#ifdef MGSL_IOCGPARAMS
+# undef MGSL_IOCGPARAMS
+# define MGSL_IOCGPARAMS 0x80206d01
+#endif
+#ifdef MGSL_IOCSPARAMS
+# undef MGSL_IOCSPARAMS
+# define MGSL_IOCSPARAMS 0x40206d00
+#endif
+#ifdef MIC_VIRTIO_ADD_DEVICE
+# undef MIC_VIRTIO_ADD_DEVICE
+# define MIC_VIRTIO_ADD_DEVICE 0xc0047301
+#endif
+#ifdef MIC_VIRTIO_CONFIG_CHANGE
+# undef MIC_VIRTIO_CONFIG_CHANGE
+# define MIC_VIRTIO_CONFIG_CHANGE 0xc0047305
+#endif
+#ifdef MIC_VIRTIO_COPY_DESC
+# undef MIC_VIRTIO_COPY_DESC
+# define MIC_VIRTIO_COPY_DESC 0xc0047302
+#endif
+#ifdef MMTIMER_GETCOUNTER
+# undef MMTIMER_GETCOUNTER
+# define MMTIMER_GETCOUNTER 0x80046d09
+#endif
+#ifdef MMTIMER_GETFREQ
+# undef MMTIMER_GETFREQ
+# define MMTIMER_GETFREQ 0x80046d02
+#endif
+#ifdef MMTIMER_GETRES
+# undef MMTIMER_GETRES
+# define MMTIMER_GETRES 0x80046d01
+#endif
+#ifdef MTIOCGET
+# undef MTIOCGET
+# define MTIOCGET 0x801c6d02
+#endif
+#ifdef MTIOCPOS
+# undef MTIOCPOS
+# define MTIOCPOS 0x80046d03
+#endif
+#ifdef NCIUARTSETDRIVER
+# undef NCIUARTSETDRIVER
+# define NCIUARTSETDRIVER 0x40045500
+#endif
+#ifdef NCP_IOC_GET_FS_INFO_V2
+# undef NCP_IOC_GET_FS_INFO_V2
+# define NCP_IOC_GET_FS_INFO_V2 0xc0246e04
+#endif
+#ifdef NCP_IOC_GETMOUNTUID2
+# undef NCP_IOC_GETMOUNTUID2
+# define NCP_IOC_GETMOUNTUID2 0x40046e02
+#endif
+#ifdef NCP_IOC_GETOBJECTNAME
+# undef NCP_IOC_GETOBJECTNAME
+# define NCP_IOC_GETOBJECTNAME 0xc00c6e09
+#endif
+#ifdef NCP_IOC_GETPRIVATEDATA
+# undef NCP_IOC_GETPRIVATEDATA
+# define NCP_IOC_GETPRIVATEDATA 0xc0086e0a
+#endif
+#ifdef NCP_IOC_NCPREQUEST
+# undef NCP_IOC_NCPREQUEST
+# define NCP_IOC_NCPREQUEST 0x800c6e01
+#endif
+#ifdef NCP_IOC_SETOBJECTNAME
+# undef NCP_IOC_SETOBJECTNAME
+# define NCP_IOC_SETOBJECTNAME 0x800c6e09
+#endif
+#ifdef NCP_IOC_SETPRIVATEDATA
+# undef NCP_IOC_SETPRIVATEDATA
+# define NCP_IOC_SETPRIVATEDATA 0x80086e0a
+#endif
+#ifdef NS_GETPSTAT
+# undef NS_GETPSTAT
+# define NS_GETPSTAT 0xc00c6161
+#endif
+#ifdef NS_SETBUFLEV
+# undef NS_SETBUFLEV
+# define NS_SETBUFLEV 0x400c6162
+#endif
+#ifdef OMAPFB_MEMORY_READ
+# undef OMAPFB_MEMORY_READ
+# define OMAPFB_MEMORY_READ 0x80104f3a
+#endif
+#ifdef OSD_GET_CAPABILITY
+# undef OSD_GET_CAPABILITY
+# define OSD_GET_CAPABILITY 0x80086fa1
+#endif
+#ifdef OSD_SEND_CMD
+# undef OSD_SEND_CMD
+# define OSD_SEND_CMD 0x401c6fa0
+#endif
+#ifdef PERF_EVENT_IOC_ID
+# undef PERF_EVENT_IOC_ID
+# define PERF_EVENT_IOC_ID 0x80042407
+#endif
+#ifdef PERF_EVENT_IOC_SET_FILTER
+# undef PERF_EVENT_IOC_SET_FILTER
+# define PERF_EVENT_IOC_SET_FILTER 0x40042406
+#endif
+#ifdef PHN_GET_REG
+# undef PHN_GET_REG
+# define PHN_GET_REG 0xc0047000
+#endif
+#ifdef PHN_GET_REGS
+# undef PHN_GET_REGS
+# define PHN_GET_REGS 0xc0047002
+#endif
+#ifdef PHN_SET_REG
+# undef PHN_SET_REG
+# define PHN_SET_REG 0x40047001
+#endif
+#ifdef PHN_SET_REGS
+# undef PHN_SET_REGS
+# define PHN_SET_REGS 0x40047003
+#endif
+#ifdef PHONE_CAPABILITIES_CHECK
+# undef PHONE_CAPABILITIES_CHECK
+# define PHONE_CAPABILITIES_CHECK 0x40047182
+#endif
+#ifdef PHONE_CAPABILITIES_LIST
+# undef PHONE_CAPABILITIES_LIST
+# define PHONE_CAPABILITIES_LIST 0x80047181
+#endif
+#ifdef PHONE_QUERY_CODEC
+# undef PHONE_QUERY_CODEC
+# define PHONE_QUERY_CODEC 0xc00471a7
+#endif
+#ifdef PHONE_RING_START
+# undef PHONE_RING_START
+# define PHONE_RING_START 0x40047187
+#endif
+#ifdef PMU_IOC_CAN_SLEEP
+# undef PMU_IOC_CAN_SLEEP
+# define PMU_IOC_CAN_SLEEP 0x80044205
+#endif
+#ifdef PMU_IOC_GET_BACKLIGHT
+# undef PMU_IOC_GET_BACKLIGHT
+# define PMU_IOC_GET_BACKLIGHT 0x80044201
+#endif
+#ifdef PMU_IOC_GET_MODEL
+# undef PMU_IOC_GET_MODEL
+# define PMU_IOC_GET_MODEL 0x80044203
+#endif
+#ifdef PMU_IOC_GRAB_BACKLIGHT
+# undef PMU_IOC_GRAB_BACKLIGHT
+# define PMU_IOC_GRAB_BACKLIGHT 0x80044206
+#endif
+#ifdef PMU_IOC_HAS_ADB
+# undef PMU_IOC_HAS_ADB
+# define PMU_IOC_HAS_ADB 0x80044204
+#endif
+#ifdef PMU_IOC_SET_BACKLIGHT
+# undef PMU_IOC_SET_BACKLIGHT
+# define PMU_IOC_SET_BACKLIGHT 0x40044202
+#endif
+#ifdef PPPIOCGCOMPRESSORS
+# undef PPPIOCGCOMPRESSORS
+# define PPPIOCGCOMPRESSORS 0x80207486
+#endif
+#ifdef PPPIOCSACTIVE
+# undef PPPIOCSACTIVE
+# define PPPIOCSACTIVE 0x40087446
+#endif
+#ifdef PPPIOCSCOMPRESS
+# undef PPPIOCSCOMPRESS
+# define PPPIOCSCOMPRESS 0x400c744d
+#endif
+#ifdef PPPIOCSPASS
+# undef PPPIOCSPASS
+# define PPPIOCSPASS 0x40087447
+#endif
+#ifdef PPPOEIOCSFWD
+# undef PPPOEIOCSFWD
+# define PPPOEIOCSFWD 0x4004b100
+#endif
+#ifdef PPS_FETCH
+# undef PPS_FETCH
+# define PPS_FETCH 0xc00470a4
+#endif
+#ifdef PPS_GETCAP
+# undef PPS_GETCAP
+# define PPS_GETCAP 0x800470a3
+#endif
+#ifdef PPS_GETPARAMS
+# undef PPS_GETPARAMS
+# define PPS_GETPARAMS 0x800470a1
+#endif
+#ifdef PPS_KC_BIND
+# undef PPS_KC_BIND
+# define PPS_KC_BIND 0x400470a5
+#endif
+#ifdef PPS_SETPARAMS
+# undef PPS_SETPARAMS
+# define PPS_SETPARAMS 0x400470a2
+#endif
+#ifdef REISERFS_IOC_UNPACK
+# undef REISERFS_IOC_UNPACK
+# define REISERFS_IOC_UNPACK 0x4004cd01
+#endif
+#ifdef RTC_EPOCH_READ
+# undef RTC_EPOCH_READ
+# define RTC_EPOCH_READ 0x8004700d
+#endif
+#ifdef RTC_EPOCH_SET
+# undef RTC_EPOCH_SET
+# define RTC_EPOCH_SET 0x4004700e
+#endif
+#ifdef RTC_IRQP_READ
+# undef RTC_IRQP_READ
+# define RTC_IRQP_READ 0x8004700b
+#endif
+#ifdef RTC_IRQP_SET
+# undef RTC_IRQP_SET
+# define RTC_IRQP_SET 0x4004700c
+#endif
+#ifdef RTC_PLL_GET
+# undef RTC_PLL_GET
+# define RTC_PLL_GET 0x801c7011
+#endif
+#ifdef RTC_PLL_SET
+# undef RTC_PLL_SET
+# define RTC_PLL_SET 0x401c7012
+#endif
+#ifdef SNDCTL_DSP_MAPINBUF
+# undef SNDCTL_DSP_MAPINBUF
+# define SNDCTL_DSP_MAPINBUF 0x80085013
+#endif
+#ifdef SNDCTL_DSP_MAPOUTBUF
+# undef SNDCTL_DSP_MAPOUTBUF
+# define SNDCTL_DSP_MAPOUTBUF 0x80085014
+#endif
+#ifdef SNDRV_CTL_IOCTL_ELEM_LIST
+# undef SNDRV_CTL_IOCTL_ELEM_LIST
+# define SNDRV_CTL_IOCTL_ELEM_LIST 0xc0485510
+#endif
+#ifdef SNDRV_CTL_IOCTL_ELEM_READ
+# undef SNDRV_CTL_IOCTL_ELEM_READ
+# define SNDRV_CTL_IOCTL_ELEM_READ 0xc2c85512
+#endif
+#ifdef SNDRV_CTL_IOCTL_ELEM_WRITE
+# undef SNDRV_CTL_IOCTL_ELEM_WRITE
+# define SNDRV_CTL_IOCTL_ELEM_WRITE 0xc2c85513
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_CODE_PEEK
+# undef SNDRV_EMU10K1_IOCTL_CODE_PEEK
+# define SNDRV_EMU10K1_IOCTL_CODE_PEEK 0xc18c4812
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_CODE_POKE
+# undef SNDRV_EMU10K1_IOCTL_CODE_POKE
+# define SNDRV_EMU10K1_IOCTL_CODE_POKE 0x418c4811
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_TRAM_PEEK
+# undef SNDRV_EMU10K1_IOCTL_TRAM_PEEK
+# define SNDRV_EMU10K1_IOCTL_TRAM_PEEK 0xc00c4822
+#endif
+#ifdef SNDRV_EMU10K1_IOCTL_TRAM_POKE
+# undef SNDRV_EMU10K1_IOCTL_TRAM_POKE
+# define SNDRV_EMU10K1_IOCTL_TRAM_POKE 0x400c4821
+#endif
+#ifdef SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE
+# undef SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE
+# define SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE 0x40044842
+#endif
+#ifdef SNDRV_HDSPM_IOCTL_GET_MIXER
+# undef SNDRV_HDSPM_IOCTL_GET_MIXER
+# define SNDRV_HDSPM_IOCTL_GET_MIXER 0x80044844
+#endif
+#ifdef SNDRV_HWDEP_IOCTL_DSP_LOAD
+# undef SNDRV_HWDEP_IOCTL_DSP_LOAD
+# define SNDRV_HWDEP_IOCTL_DSP_LOAD 0x40504803
+#endif
+#ifdef SNDRV_PCM_IOCTL_DELAY
+# undef SNDRV_PCM_IOCTL_DELAY
+# define SNDRV_PCM_IOCTL_DELAY 0x80044121
+#endif
+#ifdef SNDRV_PCM_IOCTL_FORWARD
+# undef SNDRV_PCM_IOCTL_FORWARD
+# define SNDRV_PCM_IOCTL_FORWARD 0x40044149
+#endif
+#ifdef SNDRV_PCM_IOCTL_HW_PARAMS
+# undef SNDRV_PCM_IOCTL_HW_PARAMS
+# define SNDRV_PCM_IOCTL_HW_PARAMS 0xc25c4111
+#endif
+#ifdef SNDRV_PCM_IOCTL_HW_REFINE
+# undef SNDRV_PCM_IOCTL_HW_REFINE
+# define SNDRV_PCM_IOCTL_HW_REFINE 0xc25c4110
+#endif
+#ifdef SNDRV_PCM_IOCTL_READI_FRAMES
+# undef SNDRV_PCM_IOCTL_READI_FRAMES
+# define SNDRV_PCM_IOCTL_READI_FRAMES 0x800c4151
+#endif
+#ifdef SNDRV_PCM_IOCTL_READN_FRAMES
+# undef SNDRV_PCM_IOCTL_READN_FRAMES
+# define SNDRV_PCM_IOCTL_READN_FRAMES 0x800c4153
+#endif
+#ifdef SNDRV_PCM_IOCTL_REWIND
+# undef SNDRV_PCM_IOCTL_REWIND
+# define SNDRV_PCM_IOCTL_REWIND 0x40044146
+#endif
+#ifdef SNDRV_PCM_IOCTL_STATUS
+# undef SNDRV_PCM_IOCTL_STATUS
+# define SNDRV_PCM_IOCTL_STATUS 0x80804120
+#endif
+#ifdef SNDRV_PCM_IOCTL_STATUS_EXT
+# undef SNDRV_PCM_IOCTL_STATUS_EXT
+# define SNDRV_PCM_IOCTL_STATUS_EXT 0xc0804124
+#endif
+#ifdef SNDRV_PCM_IOCTL_SW_PARAMS
+# undef SNDRV_PCM_IOCTL_SW_PARAMS
+# define SNDRV_PCM_IOCTL_SW_PARAMS 0xc0684113
+#endif
+#ifdef SNDRV_PCM_IOCTL_WRITEI_FRAMES
+# undef SNDRV_PCM_IOCTL_WRITEI_FRAMES
+# define SNDRV_PCM_IOCTL_WRITEI_FRAMES 0x400c4150
+#endif
+#ifdef SNDRV_PCM_IOCTL_WRITEN_FRAMES
+# undef SNDRV_PCM_IOCTL_WRITEN_FRAMES
+# define SNDRV_PCM_IOCTL_WRITEN_FRAMES 0x400c4152
+#endif
+#ifdef SNDRV_RAWMIDI_IOCTL_PARAMS
+# undef SNDRV_RAWMIDI_IOCTL_PARAMS
+# define SNDRV_RAWMIDI_IOCTL_PARAMS 0xc0205710
+#endif
+#ifdef SNDRV_RAWMIDI_IOCTL_STATUS
+# undef SNDRV_RAWMIDI_IOCTL_STATUS
+# define SNDRV_RAWMIDI_IOCTL_STATUS 0xc0305720
+#endif
+#ifdef SNDRV_SEQ_IOCTL_CREATE_PORT
+# undef SNDRV_SEQ_IOCTL_CREATE_PORT
+# define SNDRV_SEQ_IOCTL_CREATE_PORT 0xc0a45320
+#endif
+#ifdef SNDRV_SEQ_IOCTL_DELETE_PORT
+# undef SNDRV_SEQ_IOCTL_DELETE_PORT
+# define SNDRV_SEQ_IOCTL_DELETE_PORT 0x40a45321
+#endif
+#ifdef SNDRV_SEQ_IOCTL_GET_PORT_INFO
+# undef SNDRV_SEQ_IOCTL_GET_PORT_INFO
+# define SNDRV_SEQ_IOCTL_GET_PORT_INFO 0xc0a45322
+#endif
+#ifdef SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT
+# undef SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT
+# define SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT 0xc0a45352
+#endif
+#ifdef SNDRV_SEQ_IOCTL_SET_PORT_INFO
+# undef SNDRV_SEQ_IOCTL_SET_PORT_INFO
+# define SNDRV_SEQ_IOCTL_SET_PORT_INFO 0x40a45323
+#endif
+#ifdef SNDRV_TIMER_IOCTL_GINFO
+# undef SNDRV_TIMER_IOCTL_GINFO
+# define SNDRV_TIMER_IOCTL_GINFO 0xc0e05403
+#endif
+#ifdef SNDRV_TIMER_IOCTL_GPARAMS
+# undef SNDRV_TIMER_IOCTL_GPARAMS
+# define SNDRV_TIMER_IOCTL_GPARAMS 0x403c5404
+#endif
+#ifdef SNDRV_TIMER_IOCTL_GSTATUS
+# undef SNDRV_TIMER_IOCTL_GSTATUS
+# define SNDRV_TIMER_IOCTL_GSTATUS 0xc0405405
+#endif
+#ifdef SNDRV_TIMER_IOCTL_INFO
+# undef SNDRV_TIMER_IOCTL_INFO
+# define SNDRV_TIMER_IOCTL_INFO 0x80e05411
+#endif
+#ifdef SPIOCSTYPE
+# undef SPIOCSTYPE
+# define SPIOCSTYPE 0x40047101
+#endif
+#ifdef TUNATTACHFILTER
+# undef TUNATTACHFILTER
+# define TUNATTACHFILTER 0x400854d5
+#endif
+#ifdef TUNDETACHFILTER
+# undef TUNDETACHFILTER
+# define TUNDETACHFILTER 0x400854d6
+#endif
+#ifdef TUNER_SET_CONFIG
+# undef TUNER_SET_CONFIG
+# define TUNER_SET_CONFIG 0x4008645c
+#endif
+#ifdef TUNGETFILTER
+# undef TUNGETFILTER
+# define TUNGETFILTER 0x800854db
+#endif
+#ifdef UDF_GETEABLOCK
+# undef UDF_GETEABLOCK
+# define UDF_GETEABLOCK 0x80046c41
+#endif
+#ifdef UDF_GETVOLIDENT
+# undef UDF_GETVOLIDENT
+# define UDF_GETVOLIDENT 0x80046c42
+#endif
+#ifdef UDF_RELOCATE_BLOCKS
+# undef UDF_RELOCATE_BLOCKS
+# define UDF_RELOCATE_BLOCKS 0xc0046c43
+#endif
+#ifdef UI_BEGIN_FF_UPLOAD
+# undef UI_BEGIN_FF_UPLOAD
+# define UI_BEGIN_FF_UPLOAD 0xc06055c8
+#endif
+#ifdef UI_END_FF_UPLOAD
+# undef UI_END_FF_UPLOAD
+# define UI_END_FF_UPLOAD 0x406055c9
+#endif
+#ifdef UI_SET_PHYS
+# undef UI_SET_PHYS
+# define UI_SET_PHYS 0x4004556c
+#endif
+#ifdef USBDEVFS_BULK
+# undef USBDEVFS_BULK
+# define USBDEVFS_BULK 0xc0105502
+#endif
+#ifdef USBDEVFS_CONTROL
+# undef USBDEVFS_CONTROL
+# define USBDEVFS_CONTROL 0xc0105500
+#endif
+#ifdef USBDEVFS_DISCSIGNAL
+# undef USBDEVFS_DISCSIGNAL
+# define USBDEVFS_DISCSIGNAL 0x8008550e
+#endif
+#ifdef USBDEVFS_IOCTL
+# undef USBDEVFS_IOCTL
+# define USBDEVFS_IOCTL 0xc00c5512
+#endif
+#ifdef USBDEVFS_REAPURB
+# undef USBDEVFS_REAPURB
+# define USBDEVFS_REAPURB 0x4004550c
+#endif
+#ifdef USBDEVFS_REAPURBNDELAY
+# undef USBDEVFS_REAPURBNDELAY
+# define USBDEVFS_REAPURBNDELAY 0x4004550d
+#endif
+#ifdef USBDEVFS_SUBMITURB
+# undef USBDEVFS_SUBMITURB
+# define USBDEVFS_SUBMITURB 0x802c550a
+#endif
+#ifdef UVCIOC_CTRL_MAP
+# undef UVCIOC_CTRL_MAP
+# define UVCIOC_CTRL_MAP 0xc0587520
+#endif
+#ifdef UVCIOC_CTRL_QUERY
+# undef UVCIOC_CTRL_QUERY
+# define UVCIOC_CTRL_QUERY 0xc00c7521
+#endif
+#ifdef VIDEO_SET_SPU_PALETTE
+# undef VIDEO_SET_SPU_PALETTE
+# define VIDEO_SET_SPU_PALETTE 0x40086f33
+#endif
+#ifdef VIDEO_STILLPICTURE
+# undef VIDEO_STILLPICTURE
+# define VIDEO_STILLPICTURE 0x40086f1e
+#endif
+#ifdef VIDIOC_AM437X_CCDC_CFG
+# undef VIDIOC_AM437X_CCDC_CFG
+# define VIDIOC_AM437X_CCDC_CFG 0x400456c1
+#endif
+#ifdef VIDIOC_CREATE_BUFS
+# undef VIDIOC_CREATE_BUFS
+# define VIDIOC_CREATE_BUFS 0xc0f8565c
+#endif
+#ifdef VIDIOC_DQBUF
+# undef VIDIOC_DQBUF
+# define VIDIOC_DQBUF 0xc0505611
+#endif
+#ifdef VIDIOC_G_EDID
+# undef VIDIOC_G_EDID
+# define VIDIOC_G_EDID 0xc0245628
+#endif
+#ifdef VIDIOC_G_EXT_CTRLS
+# undef VIDIOC_G_EXT_CTRLS
+# define VIDIOC_G_EXT_CTRLS 0xc0185647
+#endif
+#ifdef VIDIOC_G_FBUF
+# undef VIDIOC_G_FBUF
+# define VIDIOC_G_FBUF 0x802c560a
+#endif
+#ifdef VIDIOC_G_FMT
+# undef VIDIOC_G_FMT
+# define VIDIOC_G_FMT 0xc0cc5604
+#endif
+#ifdef VIDIOC_OMAP3ISP_CCDC_CFG
+# undef VIDIOC_OMAP3ISP_CCDC_CFG
+# define VIDIOC_OMAP3ISP_CCDC_CFG 0xc02056c1
+#endif
+#ifdef VIDIOC_OMAP3ISP_PRV_CFG
+# undef VIDIOC_OMAP3ISP_PRV_CFG
+# define VIDIOC_OMAP3ISP_PRV_CFG 0xc03c56c2
+#endif
+#ifdef VIDIOC_OMAP3ISP_STAT_EN
+# undef VIDIOC_OMAP3ISP_STAT_EN
+# define VIDIOC_OMAP3ISP_STAT_EN 0xc00456c7
+#endif
+#ifdef VIDIOC_OMAP3ISP_STAT_REQ
+# undef VIDIOC_OMAP3ISP_STAT_REQ
+# define VIDIOC_OMAP3ISP_STAT_REQ 0xc02056c6
+#endif
+#ifdef VIDIOC_PREPARE_BUF
+# undef VIDIOC_PREPARE_BUF
+# define VIDIOC_PREPARE_BUF 0xc050565d
+#endif
+#ifdef VIDIOC_QBUF
+# undef VIDIOC_QBUF
+# define VIDIOC_QBUF 0xc050560f
+#endif
+#ifdef VIDIOC_QUERYBUF
+# undef VIDIOC_QUERYBUF
+# define VIDIOC_QUERYBUF 0xc0505609
+#endif
+#ifdef VIDIOC_S_EDID
+# undef VIDIOC_S_EDID
+# define VIDIOC_S_EDID 0xc0245629
+#endif
+#ifdef VIDIOC_S_EXT_CTRLS
+# undef VIDIOC_S_EXT_CTRLS
+# define VIDIOC_S_EXT_CTRLS 0xc0185648
+#endif
+#ifdef VIDIOC_S_FBUF
+# undef VIDIOC_S_FBUF
+# define VIDIOC_S_FBUF 0x402c560b
+#endif
+#ifdef VIDIOC_S_FMT
+# undef VIDIOC_S_FMT
+# define VIDIOC_S_FMT 0xc0cc5605
+#endif
+#ifdef VIDIOC_SUBDEV_G_EDID
+# undef VIDIOC_SUBDEV_G_EDID
+# define VIDIOC_SUBDEV_G_EDID 0xc0245628
+#endif
+#ifdef VIDIOC_SUBDEV_S_EDID
+# undef VIDIOC_SUBDEV_S_EDID
+# define VIDIOC_SUBDEV_S_EDID 0xc0245629
+#endif
+#ifdef VIDIOC_TRY_EXT_CTRLS
+# undef VIDIOC_TRY_EXT_CTRLS
+# define VIDIOC_TRY_EXT_CTRLS 0xc0185649
+#endif
+#ifdef VIDIOC_TRY_FMT
+# undef VIDIOC_TRY_FMT
+# define VIDIOC_TRY_FMT 0xc0cc5640
+#endif
+#ifdef VPFE_CMD_S_CCDC_RAW_PARAMS
+# undef VPFE_CMD_S_CCDC_RAW_PARAMS
+# define VPFE_CMD_S_CCDC_RAW_PARAMS 0x400456c1
+#endif
+#ifdef ZATM_GETPOOL
+# undef ZATM_GETPOOL
+# define ZATM_GETPOOL 0x400c6161
+#endif
+#ifdef ZATM_GETPOOLZ
+# undef ZATM_GETPOOLZ
+# define ZATM_GETPOOLZ 0x400c6162
+#endif
+#ifdef ZATM_SETPOOL
+# undef ZATM_SETPOOL
+# define ZATM_SETPOOL 0x400c6163
+#endif
diff --git a/strace/ioctlent0.h b/strace/ioctlent0.h
new file mode 100644
index 0000000..40f33f4
--- /dev/null
+++ b/strace/ioctlent0.h
@@ -0,0 +1,2839 @@
+/* Generated by ioctlsort. */
+{ "FIBMAP", 0x00000001 },
+{ "FIGETBSZ", 0x00000002 },
+{ "FDCLRPRM", 0x00000241 },
+{ "FDMSGON", 0x00000245 },
+{ "FDMSGOFF", 0x00000246 },
+{ "FDFMTBEG", 0x00000247 },
+{ "FDFMTEND", 0x00000249 },
+{ "FDSETEMSGTRESH", 0x0000024a },
+{ "FDFLUSH", 0x0000024b },
+{ "FDRESET", 0x00000254 },
+{ "FDWERRORCLR", 0x00000256 },
+{ "FDRAWCMD", 0x00000258 },
+{ "FDTWADDLE", 0x00000259 },
+{ "FDEJECT", 0x0000025a },
+{ "HDIO_GETGEO", 0x00000301 },
+{ "HDIO_GET_UNMASKINTR", 0x00000302 },
+{ "HDIO_GET_MULTCOUNT", 0x00000304 },
+{ "HDIO_GET_QDMA", 0x00000305 },
+{ "HDIO_SET_XFER", 0x00000306 },
+{ "HDIO_OBSOLETE_IDENTITY", 0x00000307 },
+{ "HDIO_GET_KEEPSETTINGS", 0x00000308 },
+{ "HDIO_GET_32BIT", 0x00000309 },
+{ "HDIO_GET_NOWERR", 0x0000030a },
+{ "HDIO_GET_DMA", 0x0000030b },
+{ "HDIO_GET_NICE", 0x0000030c },
+{ "HDIO_GET_IDENTITY", 0x0000030d },
+{ "HDIO_GET_WCACHE", 0x0000030e },
+{ "HDIO_GET_ACOUSTIC", 0x0000030f },
+{ "HDIO_GET_ADDRESS", 0x00000310 },
+{ "HDIO_GET_BUSSTATE", 0x0000031a },
+{ "HDIO_TRISTATE_HWIF", 0x0000031b },
+{ "HDIO_DRIVE_RESET", 0x0000031c },
+{ "HDIO_DRIVE_TASKFILE", 0x0000031d },
+{ "HDIO_DRIVE_TASK", 0x0000031e },
+{ "HDIO_DRIVE_CMD", 0x0000031f },
+{ "HDIO_SET_MULTCOUNT", 0x00000321 },
+{ "HDIO_SET_UNMASKINTR", 0x00000322 },
+{ "HDIO_SET_KEEPSETTINGS", 0x00000323 },
+{ "HDIO_SET_32BIT", 0x00000324 },
+{ "HDIO_SET_NOWERR", 0x00000325 },
+{ "HDIO_SET_DMA", 0x00000326 },
+{ "HDIO_SET_PIO_MODE", 0x00000327 },
+{ "HDIO_SCAN_HWIF", 0x00000328 },
+{ "HDIO_SET_NICE", 0x00000329 },
+{ "HDIO_UNREGISTER_HWIF", 0x0000032a },
+{ "HDIO_SET_WCACHE", 0x0000032b },
+{ "HDIO_SET_ACOUSTIC", 0x0000032c },
+{ "HDIO_SET_BUSSTATE", 0x0000032d },
+{ "HDIO_SET_QDMA", 0x0000032e },
+{ "HDIO_SET_ADDRESS", 0x0000032f },
+{ "IOCTL_VMCI_VERSION", 0x0000079f },
+{ "IOCTL_VMCI_INIT_CONTEXT", 0x000007a0 },
+{ "IOCTL_VMCI_QUEUEPAIR_SETVA", 0x000007a4 },
+{ "IOCTL_VMCI_NOTIFY_RESOURCE", 0x000007a5 },
+{ "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", 0x000007a6 },
+{ "IOCTL_VMCI_VERSION2", 0x000007a7 },
+{ "IOCTL_VMCI_QUEUEPAIR_ALLOC", 0x000007a8 },
+{ "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", 0x000007a9 },
+{ "IOCTL_VMCI_QUEUEPAIR_DETACH", 0x000007aa },
+{ "IOCTL_VMCI_DATAGRAM_SEND", 0x000007ab },
+{ "IOCTL_VMCI_DATAGRAM_RECEIVE", 0x000007ac },
+{ "IOCTL_VMCI_CTX_ADD_NOTIFICATION", 0x000007af },
+{ "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", 0x000007b0 },
+{ "IOCTL_VMCI_CTX_GET_CPT_STATE", 0x000007b1 },
+{ "IOCTL_VMCI_CTX_SET_CPT_STATE", 0x000007b2 },
+{ "IOCTL_VMCI_GET_CONTEXT_ID", 0x000007b3 },
+{ "IOCTL_VMCI_SOCKETS_VERSION", 0x000007b4 },
+{ "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", 0x000007b8 },
+{ "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", 0x000007b9 },
+{ "IOCTL_VM_SOCKETS_GET_LOCAL_CID", 0x000007b9 },
+{ "IOCTL_VMCI_SET_NOTIFY", 0x000007cb },
+{ "RAID_AUTORUN", 0x00000914 },
+{ "CLEAR_ARRAY", 0x00000920 },
+{ "HOT_REMOVE_DISK", 0x00000922 },
+{ "SET_DISK_INFO", 0x00000924 },
+{ "WRITE_RAID_INFO", 0x00000925 },
+{ "UNPROTECT_ARRAY", 0x00000926 },
+{ "PROTECT_ARRAY", 0x00000927 },
+{ "HOT_ADD_DISK", 0x00000928 },
+{ "SET_DISK_FAULTY", 0x00000929 },
+{ "HOT_GENERATE_ERROR", 0x0000092a },
+{ "STOP_ARRAY", 0x00000932 },
+{ "STOP_ARRAY_RO", 0x00000933 },
+{ "RESTART_ARRAY_RW", 0x00000934 },
+{ "CLUSTERED_DISK_NACK", 0x00000935 },
+{ "BLKROSET", 0x0000125d },
+{ "BLKROGET", 0x0000125e },
+{ "BLKRRPART", 0x0000125f },
+{ "BLKGETSIZE", 0x00001260 },
+{ "BLKFLSBUF", 0x00001261 },
+{ "BLKRASET", 0x00001262 },
+{ "BLKRAGET", 0x00001263 },
+{ "BLKFRASET", 0x00001264 },
+{ "BLKFRAGET", 0x00001265 },
+{ "BLKSECTSET", 0x00001266 },
+{ "BLKSECTGET", 0x00001267 },
+{ "BLKSSZGET", 0x00001268 },
+{ "BLKPG", 0x00001269 },
+{ "BLKTRACESTART", 0x00001274 },
+{ "BLKTRACESTOP", 0x00001275 },
+{ "BLKTRACETEARDOWN", 0x00001276 },
+{ "BLKDISCARD", 0x00001277 },
+{ "BLKIOMIN", 0x00001278 },
+{ "BLKIOOPT", 0x00001279 },
+{ "BLKALIGNOFF", 0x0000127a },
+{ "BLKPBSZGET", 0x0000127b },
+{ "BLKDISCARDZEROES", 0x0000127c },
+{ "BLKSECDISCARD", 0x0000127d },
+{ "BLKROTATIONAL", 0x0000127e },
+{ "BLKZEROOUT", 0x0000127f },
+{ "IB_USER_MAD_ENABLE_PKEY", 0x00001b03 },
+{ "HFI1_IOCTL_CREDIT_UPD", 0x00001be6 },
+{ "HFI1_IOCTL_CTXT_RESET", 0x00001bec },
+{ "SG_SET_TIMEOUT", 0x00002201 },
+{ "SG_GET_TIMEOUT", 0x00002202 },
+{ "SG_EMULATED_HOST", 0x00002203 },
+{ "SG_SET_TRANSFORM", 0x00002204 },
+{ "SG_GET_TRANSFORM", 0x00002205 },
+{ "SG_GET_COMMAND_Q", 0x00002270 },
+{ "SG_SET_COMMAND_Q", 0x00002271 },
+{ "SG_GET_RESERVED_SIZE", 0x00002272 },
+{ "SG_SET_RESERVED_SIZE", 0x00002275 },
+{ "SG_GET_SCSI_ID", 0x00002276 },
+{ "SG_SET_FORCE_LOW_DMA", 0x00002279 },
+{ "SG_GET_LOW_DMA", 0x0000227a },
+{ "SG_SET_FORCE_PACK_ID", 0x0000227b },
+{ "SG_GET_PACK_ID", 0x0000227c },
+{ "SG_GET_NUM_WAITING", 0x0000227d },
+{ "SG_SET_DEBUG", 0x0000227e },
+{ "SG_GET_SG_TABLESIZE", 0x0000227f },
+{ "SG_GET_VERSION_NUM", 0x00002282 },
+{ "SG_NEXT_CMD_LEN", 0x00002283 },
+{ "SG_SCSI_RESET", 0x00002284 },
+{ "SG_IO", 0x00002285 },
+{ "SG_GET_REQUEST_TABLE", 0x00002286 },
+{ "SG_SET_KEEP_ORPHAN", 0x00002287 },
+{ "SG_GET_KEEP_ORPHAN", 0x00002288 },
+{ "SG_GET_ACCESS_COUNT", 0x00002289 },
+{ "FW_CDEV_IOC_GET_SPEED", 0x00002311 },
+{ "PERF_EVENT_IOC_ENABLE", 0x00002400 },
+{ "PERF_EVENT_IOC_DISABLE", 0x00002401 },
+{ "PERF_EVENT_IOC_REFRESH", 0x00002402 },
+{ "PERF_EVENT_IOC_RESET", 0x00002403 },
+{ "PERF_EVENT_IOC_SET_OUTPUT", 0x00002405 },
+{ "SNAPSHOT_FREEZE", 0x00003301 },
+{ "SNAPSHOT_UNFREEZE", 0x00003302 },
+{ "SNAPSHOT_ATOMIC_RESTORE", 0x00003304 },
+{ "SNAPSHOT_FREE", 0x00003305 },
+{ "SNAPSHOT_FREE_SWAP_PAGES", 0x00003309 },
+{ "SNAPSHOT_S2RAM", 0x0000330b },
+{ "SNAPSHOT_PLATFORM_SUPPORT", 0x0000330f },
+{ "SNAPSHOT_POWER_OFF", 0x00003310 },
+{ "SNAPSHOT_PREF_IMAGE_SIZE", 0x00003312 },
+{ "VFIO_GET_API_VERSION", 0x00003b64 },
+{ "VFIO_CHECK_EXTENSION", 0x00003b65 },
+{ "VFIO_SET_IOMMU", 0x00003b66 },
+{ "VFIO_GROUP_GET_STATUS", 0x00003b67 },
+{ "VFIO_GROUP_SET_CONTAINER", 0x00003b68 },
+{ "VFIO_GROUP_UNSET_CONTAINER", 0x00003b69 },
+{ "VFIO_GROUP_GET_DEVICE_FD", 0x00003b6a },
+{ "VFIO_DEVICE_GET_INFO", 0x00003b6b },
+{ "VFIO_DEVICE_GET_REGION_INFO", 0x00003b6c },
+{ "VFIO_DEVICE_GET_IRQ_INFO", 0x00003b6d },
+{ "VFIO_DEVICE_SET_IRQS", 0x00003b6e },
+{ "VFIO_DEVICE_RESET", 0x00003b6f },
+{ "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", 0x00003b70 },
+{ "VFIO_IOMMU_GET_INFO", 0x00003b70 },
+{ "VFIO_IOMMU_SPAPR_TCE_GET_INFO", 0x00003b70 },
+{ "VFIO_DEVICE_PCI_HOT_RESET", 0x00003b71 },
+{ "VFIO_IOMMU_MAP_DMA", 0x00003b71 },
+{ "VFIO_IOMMU_UNMAP_DMA", 0x00003b72 },
+{ "VFIO_IOMMU_ENABLE", 0x00003b73 },
+{ "VFIO_IOMMU_DISABLE", 0x00003b74 },
+{ "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", 0x00003b75 },
+{ "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", 0x00003b76 },
+{ "VFIO_IOMMU_SPAPR_TCE_CREATE", 0x00003b77 },
+{ "VFIO_IOMMU_SPAPR_TCE_REMOVE", 0x00003b78 },
+{ "VFIO_EEH_PE_OP", 0x00003b79 },
+{ "AGPIOC_ACQUIRE", 0x00004101 },
+{ "APM_IOC_STANDBY", 0x00004101 },
+{ "AGPIOC_RELEASE", 0x00004102 },
+{ "APM_IOC_SUSPEND", 0x00004102 },
+{ "AGPIOC_CHIPSET_FLUSH", 0x0000410a },
+{ "SNDRV_PCM_IOCTL_HW_FREE", 0x00004112 },
+{ "SNDRV_PCM_IOCTL_HWSYNC", 0x00004122 },
+{ "SNDRV_PCM_IOCTL_PREPARE", 0x00004140 },
+{ "SNDRV_PCM_IOCTL_RESET", 0x00004141 },
+{ "SNDRV_PCM_IOCTL_START", 0x00004142 },
+{ "SNDRV_PCM_IOCTL_DROP", 0x00004143 },
+{ "SNDRV_PCM_IOCTL_DRAIN", 0x00004144 },
+{ "SNDRV_PCM_IOCTL_RESUME", 0x00004147 },
+{ "SNDRV_PCM_IOCTL_XRUN", 0x00004148 },
+{ "SNDRV_PCM_IOCTL_UNLINK", 0x00004161 },
+{ "IOCTL_XENBUS_BACKEND_EVTCHN", 0x00004200 },
+{ "PMU_IOC_SLEEP", 0x00004200 },
+{ "IOCTL_XENBUS_BACKEND_SETUP", 0x00004201 },
+{ "CCISS_REVALIDVOLS", 0x0000420a },
+{ "CCISS_DEREGDISK", 0x0000420c },
+{ "CCISS_REGNEWD", 0x0000420e },
+{ "CCISS_RESCANDISK", 0x00004210 },
+{ "SNDCTL_COPR_RESET", 0x00004300 },
+{ "SNDRV_COMPRESS_PAUSE", 0x00004330 },
+{ "SNDRV_COMPRESS_RESUME", 0x00004331 },
+{ "SNDRV_COMPRESS_START", 0x00004332 },
+{ "SNDRV_COMPRESS_STOP", 0x00004333 },
+{ "SNDRV_COMPRESS_DRAIN", 0x00004334 },
+{ "SNDRV_COMPRESS_NEXT_TRACK", 0x00004335 },
+{ "SNDRV_COMPRESS_PARTIAL_DRAIN", 0x00004336 },
+{ "IOCTL_EVTCHN_RESET", 0x00004505 },
+{ "FBIOGET_VSCREENINFO", 0x00004600 },
+{ "FBIOPUT_VSCREENINFO", 0x00004601 },
+{ "FBIOGET_FSCREENINFO", 0x00004602 },
+{ "FBIOGETCMAP", 0x00004604 },
+{ "FBIOPUTCMAP", 0x00004605 },
+{ "FBIOPAN_DISPLAY", 0x00004606 },
+{ "FBIOGET_CON2FBMAP", 0x0000460f },
+{ "FBIOPUT_CON2FBMAP", 0x00004610 },
+{ "FBIOBLANK", 0x00004611 },
+{ "FBIO_ALLOC", 0x00004613 },
+{ "FBIO_FREE", 0x00004614 },
+{ "FBIOGET_GLYPH", 0x00004615 },
+{ "FBIOGET_HWCINFO", 0x00004616 },
+{ "FBIOPUT_MODEINFO", 0x00004617 },
+{ "FBIOGET_DISPINFO", 0x00004618 },
+{ "FBIO_WAITEVENT", 0x00004688 },
+{ "GSMIOC_DISABLE_NET", 0x00004703 },
+{ "HIDIOCAPPLICATION", 0x00004802 },
+{ "HIDIOCINITREPORT", 0x00004805 },
+{ "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", 0x00004812 },
+{ "SNDRV_SB_CSP_IOCTL_STOP", 0x00004814 },
+{ "SNDRV_SB_CSP_IOCTL_PAUSE", 0x00004815 },
+{ "SNDRV_SB_CSP_IOCTL_RESTART", 0x00004816 },
+{ "SNDRV_DM_FM_IOCTL_RESET", 0x00004821 },
+{ "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", 0x00004840 },
+{ "SNDRV_EMU10K1_IOCTL_STOP", 0x00004880 },
+{ "SNDRV_EMU10K1_IOCTL_CONTINUE", 0x00004881 },
+{ "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", 0x00004882 },
+{ "SNDRV_EMUX_IOCTL_RESET_SAMPLES", 0x00004882 },
+{ "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", 0x00004883 },
+{ "SNDRV_FIREWIRE_IOCTL_LOCK", 0x000048f9 },
+{ "SNDRV_FIREWIRE_IOCTL_UNLOCK", 0x000048fa },
+{ "IIOCNETAIF", 0x00004901 },
+{ "IIOCNETDIF", 0x00004902 },
+{ "IIOCNETSCF", 0x00004903 },
+{ "IIOCNETGCF", 0x00004904 },
+{ "IIOCNETANM", 0x00004905 },
+{ "IIOCNETDNM", 0x00004906 },
+{ "IIOCNETGNM", 0x00004907 },
+{ "IIOCGETSET", 0x00004908 },
+{ "IIOCSETSET", 0x00004909 },
+{ "IIOCSETVER", 0x0000490a },
+{ "IIOCNETHUP", 0x0000490b },
+{ "IIOCSETGST", 0x0000490c },
+{ "IIOCSETBRJ", 0x0000490d },
+{ "IIOCSIGPRF", 0x0000490e },
+{ "IIOCGETPRF", 0x0000490f },
+{ "IIOCSETPRF", 0x00004910 },
+{ "IIOCGETMAP", 0x00004911 },
+{ "IIOCSETMAP", 0x00004912 },
+{ "IIOCNETASL", 0x00004913 },
+{ "IIOCNETDIL", 0x00004914 },
+{ "IIOCGETCPS", 0x00004915 },
+{ "IIOCGETDVR", 0x00004916 },
+{ "IIOCNETLCR", 0x00004917 },
+{ "IIOCNETDWRSET", 0x00004918 },
+{ "IIOCNETALN", 0x00004920 },
+{ "IIOCNETDLN", 0x00004921 },
+{ "IIOCNETGPN", 0x00004922 },
+{ "IIOCDBGVAR", 0x0000497f },
+{ "IIOCDRVCTL", 0x00004980 },
+{ "ION_IOC_TEST_SET_FD", 0x000049f0 },
+{ "KIOCSOUND", 0x00004b2f },
+{ "KDMKTONE", 0x00004b30 },
+{ "KDGETLED", 0x00004b31 },
+{ "KDSETLED", 0x00004b32 },
+{ "KDGKBTYPE", 0x00004b33 },
+{ "KDADDIO", 0x00004b34 },
+{ "KDDELIO", 0x00004b35 },
+{ "KDENABIO", 0x00004b36 },
+{ "KDDISABIO", 0x00004b37 },
+{ "KDSETMODE", 0x00004b3a },
+{ "KDGETMODE", 0x00004b3b },
+{ "KDMAPDISP", 0x00004b3c },
+{ "KDUNMAPDISP", 0x00004b3d },
+{ "GIO_SCRNMAP", 0x00004b40 },
+{ "PIO_SCRNMAP", 0x00004b41 },
+{ "KDGKBMODE", 0x00004b44 },
+{ "KDSKBMODE", 0x00004b45 },
+{ "KDGKBENT", 0x00004b46 },
+{ "KDSKBENT", 0x00004b47 },
+{ "KDGKBSENT", 0x00004b48 },
+{ "KDSKBSENT", 0x00004b49 },
+{ "KDGKBDIACR", 0x00004b4a },
+{ "KDSKBDIACR", 0x00004b4b },
+{ "KDGETKEYCODE", 0x00004b4c },
+{ "KDSETKEYCODE", 0x00004b4d },
+{ "KDSIGACCEPT", 0x00004b4e },
+{ "KDKBDREP", 0x00004b52 },
+{ "GIO_FONT", 0x00004b60 },
+{ "PIO_FONT", 0x00004b61 },
+{ "KDGKBMETA", 0x00004b62 },
+{ "KDSKBMETA", 0x00004b63 },
+{ "KDGKBLED", 0x00004b64 },
+{ "KDSKBLED", 0x00004b65 },
+{ "GIO_UNIMAP", 0x00004b66 },
+{ "PIO_UNIMAP", 0x00004b67 },
+{ "PIO_UNIMAPCLR", 0x00004b68 },
+{ "GIO_UNISCRNMAP", 0x00004b69 },
+{ "PIO_UNISCRNMAP", 0x00004b6a },
+{ "GIO_FONTX", 0x00004b6b },
+{ "PIO_FONTX", 0x00004b6c },
+{ "PIO_FONTRESET", 0x00004b6d },
+{ "GIO_CMAP", 0x00004b70 },
+{ "PIO_CMAP", 0x00004b71 },
+{ "KDFONTOP", 0x00004b72 },
+{ "KDGKBDIACRUC", 0x00004bfa },
+{ "KDSKBDIACRUC", 0x00004bfb },
+{ "LOOP_SET_FD", 0x00004c00 },
+{ "LOOP_CLR_FD", 0x00004c01 },
+{ "LOOP_SET_STATUS", 0x00004c02 },
+{ "LOOP_GET_STATUS", 0x00004c03 },
+{ "LOOP_SET_STATUS64", 0x00004c04 },
+{ "LOOP_GET_STATUS64", 0x00004c05 },
+{ "LOOP_CHANGE_FD", 0x00004c06 },
+{ "LOOP_SET_CAPACITY", 0x00004c07 },
+{ "LOOP_SET_DIRECT_IO", 0x00004c08 },
+{ "LOOP_CTL_ADD", 0x00004c80 },
+{ "LOOP_CTL_REMOVE", 0x00004c81 },
+{ "LOOP_CTL_GET_FREE", 0x00004c82 },
+{ "MTDFILEMODE", 0x00004d13 },
+{ "NVME_IOCTL_ID", 0x00004e40 },
+{ "NVME_IOCTL_RESET", 0x00004e44 },
+{ "NVME_IOCTL_SUBSYS_RESET", 0x00004e45 },
+{ "NVME_IOCTL_RESCAN", 0x00004e46 },
+{ "UBI_IOCVOLRMBLK", 0x00004f08 },
+{ "OMAPFB_SYNC_GFX", 0x00004f25 },
+{ "OMAPFB_VSYNC", 0x00004f26 },
+{ "OMAPFB_WAITFORVSYNC", 0x00004f39 },
+{ "OMAPFB_WAITFORGO", 0x00004f3c },
+{ "SNDCTL_DSP_RESET", 0x00005000 },
+{ "SNDCTL_DSP_SYNC", 0x00005001 },
+{ "SNDCTL_DSP_POST", 0x00005008 },
+{ "SNDCTL_DSP_NONBLOCK", 0x0000500e },
+{ "SNDCTL_DSP_SETSYNCRO", 0x00005015 },
+{ "SNDCTL_DSP_SETDUPLEX", 0x00005016 },
+{ "SNDCTL_SEQ_RESET", 0x00005100 },
+{ "SNDCTL_SEQ_SYNC", 0x00005101 },
+{ "SNDCTL_SEQ_PANIC", 0x00005111 },
+{ "RFKILL_IOCTL_NOINPUT", 0x00005201 },
+{ "RNDZAPENTCNT", 0x00005204 },
+{ "RNDCLEARPOOL", 0x00005206 },
+{ "CDROMPAUSE", 0x00005301 },
+{ "CDROMRESUME", 0x00005302 },
+{ "CDROMPLAYMSF", 0x00005303 },
+{ "CDROMPLAYTRKIND", 0x00005304 },
+{ "CDROMREADTOCHDR", 0x00005305 },
+{ "CDROMREADTOCENTRY", 0x00005306 },
+{ "CDROMSTOP", 0x00005307 },
+{ "CDROMSTART", 0x00005308 },
+{ "CDROMEJECT", 0x00005309 },
+{ "CDROMVOLCTRL", 0x0000530a },
+{ "CDROMSUBCHNL", 0x0000530b },
+{ "CDROMREADMODE2", 0x0000530c },
+{ "CDROMREADMODE1", 0x0000530d },
+{ "CDROMREADAUDIO", 0x0000530e },
+{ "CDROMEJECT_SW", 0x0000530f },
+{ "CDROMMULTISESSION", 0x00005310 },
+{ "CDROM_GET_MCN", 0x00005311 },
+{ "CDROMRESET", 0x00005312 },
+{ "CDROMVOLREAD", 0x00005313 },
+{ "CDROMREADRAW", 0x00005314 },
+{ "CDROMREADCOOKED", 0x00005315 },
+{ "CDROMSEEK", 0x00005316 },
+{ "CDROMPLAYBLK", 0x00005317 },
+{ "CDROMREADALL", 0x00005318 },
+{ "CDROMCLOSETRAY", 0x00005319 },
+{ "CDROMGETSPINDOWN", 0x0000531d },
+{ "CDROMSETSPINDOWN", 0x0000531e },
+{ "CDROM_SET_OPTIONS", 0x00005320 },
+{ "CDROM_CLEAR_OPTIONS", 0x00005321 },
+{ "CDROM_SELECT_SPEED", 0x00005322 },
+{ "CDROM_SELECT_DISC", 0x00005323 },
+{ "CDROM_MEDIA_CHANGED", 0x00005325 },
+{ "CDROM_DRIVE_STATUS", 0x00005326 },
+{ "CDROM_DISC_STATUS", 0x00005327 },
+{ "CDROM_CHANGER_NSLOTS", 0x00005328 },
+{ "CDROM_LOCKDOOR", 0x00005329 },
+{ "CDROM_DEBUG", 0x00005330 },
+{ "CDROM_GET_CAPABILITY", 0x00005331 },
+{ "SCSI_IOCTL_DOORLOCK", 0x00005380 },
+{ "SCSI_IOCTL_DOORUNLOCK", 0x00005381 },
+{ "CDROMAUDIOBUFSIZ", 0x00005382 },
+{ "SCSI_IOCTL_GET_IDLUN", 0x00005382 },
+{ "SCSI_IOCTL_PROBE_HOST", 0x00005385 },
+{ "SCSI_IOCTL_GET_BUS_NUMBER", 0x00005386 },
+{ "SCSI_IOCTL_GET_PCI", 0x00005387 },
+{ "DVD_READ_STRUCT", 0x00005390 },
+{ "DVD_WRITE_STRUCT", 0x00005391 },
+{ "DVD_AUTH", 0x00005392 },
+{ "CDROM_SEND_PACKET", 0x00005393 },
+{ "CDROM_NEXT_WRITABLE", 0x00005394 },
+{ "CDROM_LAST_WRITTEN", 0x00005395 },
+{ "TCGETS", 0x00005401 },
+{ "SNDCTL_TMR_START", 0x00005402 },
+{ "TCSETS", 0x00005402 },
+{ "SNDCTL_TMR_STOP", 0x00005403 },
+{ "TCSETSW", 0x00005403 },
+{ "SNDCTL_TMR_CONTINUE", 0x00005404 },
+{ "TCSETSF", 0x00005404 },
+{ "TCGETA", 0x00005405 },
+{ "TCSETA", 0x00005406 },
+{ "TCSETAW", 0x00005407 },
+{ "TCSETAF", 0x00005408 },
+{ "TCSBRK", 0x00005409 },
+{ "TCXONC", 0x0000540a },
+{ "TCFLSH", 0x0000540b },
+{ "TIOCEXCL", 0x0000540c },
+{ "TIOCNXCL", 0x0000540d },
+{ "TIOCSCTTY", 0x0000540e },
+{ "TIOCGPGRP", 0x0000540f },
+{ "TIOCSPGRP", 0x00005410 },
+{ "TIOCOUTQ", 0x00005411 },
+{ "TIOCSTI", 0x00005412 },
+{ "TIOCGWINSZ", 0x00005413 },
+{ "TIOCSWINSZ", 0x00005414 },
+{ "TIOCMGET", 0x00005415 },
+{ "TIOCMBIS", 0x00005416 },
+{ "TIOCMBIC", 0x00005417 },
+{ "TIOCMSET", 0x00005418 },
+{ "TIOCGSOFTCAR", 0x00005419 },
+{ "TIOCSSOFTCAR", 0x0000541a },
+{ "FIONREAD", 0x0000541b },
+{ "TIOCLINUX", 0x0000541c },
+{ "TIOCCONS", 0x0000541d },
+{ "TIOCGSERIAL", 0x0000541e },
+{ "TIOCSSERIAL", 0x0000541f },
+{ "TIOCPKT", 0x00005420 },
+{ "FIONBIO", 0x00005421 },
+{ "TIOCNOTTY", 0x00005422 },
+{ "TIOCSETD", 0x00005423 },
+{ "TIOCGETD", 0x00005424 },
+{ "TCSBRKP", 0x00005425 },
+{ "TIOCSBRK", 0x00005427 },
+{ "TIOCCBRK", 0x00005428 },
+{ "TIOCGSID", 0x00005429 },
+{ "TIOCGRS485", 0x0000542e },
+{ "TIOCSRS485", 0x0000542f },
+{ "TCGETX", 0x00005432 },
+{ "TCSETX", 0x00005433 },
+{ "TCSETXF", 0x00005434 },
+{ "TCSETXW", 0x00005435 },
+{ "TIOCVHANGUP", 0x00005437 },
+{ "FIONCLEX", 0x00005450 },
+{ "FIOCLEX", 0x00005451 },
+{ "FIOASYNC", 0x00005452 },
+{ "TIOCSERCONFIG", 0x00005453 },
+{ "TIOCSERGWILD", 0x00005454 },
+{ "TIOCSERSWILD", 0x00005455 },
+{ "TIOCGLCKTRMIOS", 0x00005456 },
+{ "TIOCSLCKTRMIOS", 0x00005457 },
+{ "TIOCSERGSTRUCT", 0x00005458 },
+{ "TIOCSERGETLSR", 0x00005459 },
+{ "TIOCSERGETMULTI", 0x0000545a },
+{ "TIOCSERSETMULTI", 0x0000545b },
+{ "TIOCMIWAIT", 0x0000545c },
+{ "TIOCGICOUNT", 0x0000545d },
+{ "FIOQSIZE", 0x00005460 },
+{ "SNDRV_TIMER_IOCTL_START", 0x000054a0 },
+{ "SNDRV_TIMER_IOCTL_STOP", 0x000054a1 },
+{ "SNDRV_TIMER_IOCTL_CONTINUE", 0x000054a2 },
+{ "SNDRV_TIMER_IOCTL_PAUSE", 0x000054a3 },
+{ "UI_DEV_CREATE", 0x00005501 },
+{ "UI_DEV_DESTROY", 0x00005502 },
+{ "USBDEVFS_DISCARDURB", 0x0000550b },
+{ "USBDEVFS_RESET", 0x00005514 },
+{ "USBDEVFS_DISCONNECT", 0x00005516 },
+{ "USBDEVFS_CONNECT", 0x00005517 },
+{ "VT_OPENQRY", 0x00005600 },
+{ "VIDIOC_RESERVED", 0x00005601 },
+{ "VT_GETMODE", 0x00005601 },
+{ "VT_SETMODE", 0x00005602 },
+{ "VT_GETSTATE", 0x00005603 },
+{ "VT_SENDSIG", 0x00005604 },
+{ "VT_RELDISP", 0x00005605 },
+{ "VT_ACTIVATE", 0x00005606 },
+{ "VT_WAITACTIVE", 0x00005607 },
+{ "VT_DISALLOCATE", 0x00005608 },
+{ "VT_RESIZE", 0x00005609 },
+{ "VT_RESIZEX", 0x0000560a },
+{ "VT_LOCKSWITCH", 0x0000560b },
+{ "VT_UNLOCKSWITCH", 0x0000560c },
+{ "VT_GETHIFONTMASK", 0x0000560d },
+{ "VT_WAITEVENT", 0x0000560e },
+{ "VT_SETACTIVATE", 0x0000560f },
+{ "VIDIOC_LOG_STATUS", 0x00005646 },
+{ "ADV7842_CMD_RAM_TEST", 0x000056c0 },
+{ "USBTMC_IOCTL_INDICATOR_PULSE", 0x00005b01 },
+{ "USBTMC_IOCTL_CLEAR", 0x00005b02 },
+{ "USBTMC_IOCTL_ABORT_BULK_OUT", 0x00005b03 },
+{ "USBTMC_IOCTL_ABORT_BULK_IN", 0x00005b04 },
+{ "USBTMC_IOCTL_CLEAR_OUT_HALT", 0x00005b06 },
+{ "USBTMC_IOCTL_CLEAR_IN_HALT", 0x00005b07 },
+{ "USBTMC488_IOCTL_GOTO_LOCAL", 0x00005b14 },
+{ "USBTMC488_IOCTL_LOCAL_LOCKOUT", 0x00005b15 },
+{ "NS_ADJBUFLEV", 0x00006163 },
+{ "SIOCSIFATMTCP", 0x00006180 },
+{ "ATMTCP_CREATE", 0x0000618e },
+{ "ATMTCP_REMOVE", 0x0000618f },
+{ "ATMLEC_CTRL", 0x000061d0 },
+{ "ATMLEC_DATA", 0x000061d1 },
+{ "ATMLEC_MCAST", 0x000061d2 },
+{ "ATMMPC_CTRL", 0x000061d8 },
+{ "ATMMPC_DATA", 0x000061d9 },
+{ "SIOCMKCLIP", 0x000061e0 },
+{ "ATMARPD_CTRL", 0x000061e1 },
+{ "ATMARP_MKIP", 0x000061e2 },
+{ "ATMARP_SETENTRY", 0x000061e3 },
+{ "ATMARP_ENCAP", 0x000061e5 },
+{ "ATMSIGD_CTRL", 0x000061f0 },
+{ "BT819_FIFO_RESET_LOW", 0x00006200 },
+{ "BT819_FIFO_RESET_HIGH", 0x00006201 },
+{ "CM_IOCSRDR", 0x00006303 },
+{ "CM_IOCARDOFF", 0x00006304 },
+{ "BC_REGISTER_LOOPER", 0x0000630b },
+{ "BC_ENTER_LOOPER", 0x0000630c },
+{ "BC_EXIT_LOOPER", 0x0000630d },
+{ "CHIOINITELEM", 0x00006311 },
+{ "KCOV_ENABLE", 0x00006364 },
+{ "KCOV_DISABLE", 0x00006365 },
+{ "DRM_IOCTL_SET_MASTER", 0x0000641e },
+{ "DRM_IOCTL_DROP_MASTER", 0x0000641f },
+{ "DRM_IOCTL_AGP_ACQUIRE", 0x00006430 },
+{ "DRM_IOCTL_AGP_RELEASE", 0x00006431 },
+{ "DRM_IOCTL_I915_FLUSH", 0x00006441 },
+{ "DRM_IOCTL_R128_CCE_START", 0x00006441 },
+{ "DRM_IOCTL_RADEON_CP_START", 0x00006441 },
+{ "DRM_IOCTL_I915_FLIP", 0x00006442 },
+{ "DRM_IOCTL_MGA_RESET", 0x00006442 },
+{ "DRM_IOCTL_I810_FLUSH", 0x00006443 },
+{ "DRM_IOCTL_MGA_SWAP", 0x00006443 },
+{ "DRM_IOCTL_R128_CCE_RESET", 0x00006443 },
+{ "DRM_IOCTL_RADEON_CP_RESET", 0x00006443 },
+{ "DRM_IOCTL_I810_GETAGE", 0x00006444 },
+{ "DRM_IOCTL_R128_CCE_IDLE", 0x00006444 },
+{ "DRM_IOCTL_RADEON_CP_IDLE", 0x00006444 },
+{ "DRM_IOCTL_RADEON_RESET", 0x00006445 },
+{ "DRM_IOCTL_I810_SWAP", 0x00006446 },
+{ "DRM_IOCTL_R128_RESET", 0x00006446 },
+{ "DRM_IOCTL_R128_SWAP", 0x00006447 },
+{ "DRM_IOCTL_RADEON_SWAP", 0x00006447 },
+{ "DRM_IOCTL_I810_DOCOPY", 0x00006448 },
+{ "DRM_IOCTL_VIA_FLUSH", 0x00006449 },
+{ "DRM_IOCTL_I810_FSTATUS", 0x0000644a },
+{ "DRM_IOCTL_I810_OV0FLIP", 0x0000644b },
+{ "DRM_IOCTL_I810_RSTATUS", 0x0000644d },
+{ "DRM_IOCTL_I810_FLIP", 0x0000644e },
+{ "DRM_IOCTL_RADEON_FLIP", 0x00006452 },
+{ "DRM_IOCTL_R128_FLIP", 0x00006453 },
+{ "DRM_IOCTL_I915_GEM_THROTTLE", 0x00006458 },
+{ "DRM_IOCTL_RADEON_CP_RESUME", 0x00006458 },
+{ "DRM_IOCTL_I915_GEM_ENTERVT", 0x00006459 },
+{ "DRM_IOCTL_I915_GEM_LEAVEVT", 0x0000645a },
+{ "S5P_FIMC_TX_END_NOTIFY", 0x00006500 },
+{ "FUNCTIONFS_FIFO_STATUS", 0x00006701 },
+{ "GADGETFS_FIFO_STATUS", 0x00006701 },
+{ "FUNCTIONFS_FIFO_FLUSH", 0x00006702 },
+{ "GADGETFS_FIFO_FLUSH", 0x00006702 },
+{ "FUNCTIONFS_CLEAR_HALT", 0x00006703 },
+{ "GADGETFS_CLEAR_HALT", 0x00006703 },
+{ "FUNCTIONFS_INTERFACE_REVMAP", 0x00006780 },
+{ "FUNCTIONFS_ENDPOINT_REVMAP", 0x00006781 },
+{ "HPET_IE_ON", 0x00006801 },
+{ "HPET_IE_OFF", 0x00006802 },
+{ "HPET_EPI", 0x00006804 },
+{ "HPET_DPI", 0x00006805 },
+{ "LIRC_NOTIFY_DECODE", 0x00006920 },
+{ "LIRC_SETUP_START", 0x00006921 },
+{ "LIRC_SETUP_END", 0x00006922 },
+{ "KYRO_IOCTL_OVERLAY_CREATE", 0x00006b00 },
+{ "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", 0x00006b01 },
+{ "KYRO_IOCTL_SET_VIDEO_MODE", 0x00006b02 },
+{ "KYRO_IOCTL_UVSTRIDE", 0x00006b03 },
+{ "KYRO_IOCTL_OVERLAY_OFFSET", 0x00006b04 },
+{ "KYRO_IOCTL_STRIDE", 0x00006b05 },
+{ "HSC_RESET", 0x00006b10 },
+{ "HSC_SET_PM", 0x00006b11 },
+{ "HSC_SEND_BREAK", 0x00006b12 },
+{ "MMTIMER_GETOFFSET", 0x00006d00 },
+{ "MGSL_IOCSTXIDLE", 0x00006d02 },
+{ "MGSL_IOCGTXIDLE", 0x00006d03 },
+{ "MGSL_IOCTXENABLE", 0x00006d04 },
+{ "MMTIMER_GETBITS", 0x00006d04 },
+{ "MGSL_IOCRXENABLE", 0x00006d05 },
+{ "MGSL_IOCTXABORT", 0x00006d06 },
+{ "MMTIMER_MMAPAVAIL", 0x00006d06 },
+{ "MGSL_IOCGSTATS", 0x00006d07 },
+{ "MGSL_IOCLOOPTXDONE", 0x00006d09 },
+{ "MGSL_IOCSIF", 0x00006d0a },
+{ "MGSL_IOCGIF", 0x00006d0b },
+{ "MGSL_IOCCLRMODCOUNT", 0x00006d0f },
+{ "MGSL_IOCSXSYNC", 0x00006d13 },
+{ "MGSL_IOCGXSYNC", 0x00006d14 },
+{ "MGSL_IOCSXCTRL", 0x00006d15 },
+{ "MGSL_IOCGXCTRL", 0x00006d16 },
+{ "NCP_IOC_CONN_LOGGED_IN", 0x00006e03 },
+{ "AUDIO_STOP", 0x00006f01 },
+{ "AUDIO_PLAY", 0x00006f02 },
+{ "AUDIO_PAUSE", 0x00006f03 },
+{ "AUDIO_CONTINUE", 0x00006f04 },
+{ "AUDIO_SELECT_SOURCE", 0x00006f05 },
+{ "AUDIO_SET_MUTE", 0x00006f06 },
+{ "AUDIO_SET_AV_SYNC", 0x00006f07 },
+{ "AUDIO_SET_BYPASS_MODE", 0x00006f08 },
+{ "AUDIO_CHANNEL_SELECT", 0x00006f09 },
+{ "AUDIO_CLEAR_BUFFER", 0x00006f0c },
+{ "AUDIO_SET_ID", 0x00006f0d },
+{ "AUDIO_SET_STREAMTYPE", 0x00006f0f },
+{ "AUDIO_SET_EXT_ID", 0x00006f10 },
+{ "AUDIO_BILINGUAL_CHANNEL_SELECT", 0x00006f14 },
+{ "VIDEO_STOP", 0x00006f15 },
+{ "VIDEO_PLAY", 0x00006f16 },
+{ "VIDEO_FREEZE", 0x00006f17 },
+{ "VIDEO_CONTINUE", 0x00006f18 },
+{ "VIDEO_SELECT_SOURCE", 0x00006f19 },
+{ "VIDEO_SET_BLANK", 0x00006f1a },
+{ "VIDEO_SET_DISPLAY_FORMAT", 0x00006f1d },
+{ "VIDEO_FAST_FORWARD", 0x00006f1f },
+{ "VIDEO_SLOWMOTION", 0x00006f20 },
+{ "VIDEO_CLEAR_BUFFER", 0x00006f22 },
+{ "VIDEO_SET_ID", 0x00006f23 },
+{ "VIDEO_SET_STREAMTYPE", 0x00006f24 },
+{ "VIDEO_SET_FORMAT", 0x00006f25 },
+{ "VIDEO_SET_SYSTEM", 0x00006f26 },
+{ "DMX_START", 0x00006f29 },
+{ "DMX_STOP", 0x00006f2a },
+{ "DMX_SET_BUFFER_SIZE", 0x00006f2d },
+{ "NET_REMOVE_IF", 0x00006f35 },
+{ "VIDEO_SET_ATTRIBUTES", 0x00006f35 },
+{ "FE_DISEQC_RESET_OVERLOAD", 0x00006f3e },
+{ "FE_DISEQC_SEND_BURST", 0x00006f41 },
+{ "FE_SET_TONE", 0x00006f42 },
+{ "FE_SET_VOLTAGE", 0x00006f43 },
+{ "FE_ENABLE_HIGH_LNB_VOLTAGE", 0x00006f44 },
+{ "FE_DISHNETWORK_SEND_LEGACY_CMD", 0x00006f50 },
+{ "FE_SET_FRONTEND_TUNE_MODE", 0x00006f51 },
+{ "CA_RESET", 0x00006f80 },
+{ "RTC_AIE_ON", 0x00007001 },
+{ "RTC_AIE_OFF", 0x00007002 },
+{ "RTC_UIE_ON", 0x00007003 },
+{ "PHN_NOT_OH", 0x00007004 },
+{ "RTC_UIE_OFF", 0x00007004 },
+{ "RTC_PIE_ON", 0x00007005 },
+{ "RTC_PIE_OFF", 0x00007006 },
+{ "RTC_WIE_ON", 0x0000700f },
+{ "RTC_WIE_OFF", 0x00007010 },
+{ "RTC_VL_CLR", 0x00007014 },
+{ "NVRAM_INIT", 0x00007040 },
+{ "NVRAM_SETCKS", 0x00007041 },
+{ "PPCLAIM", 0x0000708b },
+{ "PPRELEASE", 0x0000708c },
+{ "PPYIELD", 0x0000708d },
+{ "PPEXCL", 0x0000708f },
+{ "PHONE_CAPABILITIES", 0x00007180 },
+{ "PHONE_RING", 0x00007183 },
+{ "PHONE_HOOKSTATE", 0x00007184 },
+{ "OLD_PHONE_RING_START", 0x00007187 },
+{ "PHONE_RING_STOP", 0x00007188 },
+{ "PHONE_REC_START", 0x0000718a },
+{ "PHONE_REC_STOP", 0x0000718b },
+{ "PHONE_REC_LEVEL", 0x0000718f },
+{ "PHONE_PLAY_START", 0x00007191 },
+{ "PHONE_PLAY_STOP", 0x00007192 },
+{ "PHONE_PLAY_LEVEL", 0x00007195 },
+{ "PHONE_GET_TONE_ON_TIME", 0x0000719e },
+{ "PHONE_GET_TONE_OFF_TIME", 0x0000719f },
+{ "PHONE_GET_TONE_STATE", 0x000071a0 },
+{ "PHONE_BUSY", 0x000071a1 },
+{ "PHONE_RINGBACK", 0x000071a2 },
+{ "PHONE_DIALTONE", 0x000071a3 },
+{ "PHONE_CPT_STOP", 0x000071a4 },
+{ "PHONE_PSTN_GET_STATE", 0x000071a5 },
+{ "PHONE_PSTN_LINETEST", 0x000071a8 },
+{ "IXJCTL_DSP_RESET", 0x000071c0 },
+{ "IXJCTL_DSP_IDLE", 0x000071c5 },
+{ "IXJCTL_TESTRAM", 0x000071c6 },
+{ "IXJCTL_AEC_STOP", 0x000071cc },
+{ "IXJCTL_AEC_GET_LEVEL", 0x000071cd },
+{ "IXJCTL_PSTN_LINETEST", 0x000071d3 },
+{ "IXJCTL_PLAY_CID", 0x000071d7 },
+{ "IXJCTL_DRYBUFFER_CLEAR", 0x000071e7 },
+{ "BR_OK", 0x00007201 },
+{ "BR_DEAD_REPLY", 0x00007205 },
+{ "BR_TRANSACTION_COMPLETE", 0x00007206 },
+{ "BR_NOOP", 0x0000720c },
+{ "BR_SPAWN_LOOPER", 0x0000720d },
+{ "BR_FINISHED", 0x0000720e },
+{ "BR_FAILED_REPLY", 0x00007211 },
+{ "PPPIOCDISCONN", 0x00007439 },
+{ "PPPIOCXFERUNIT", 0x0000744e },
+{ "MEYEIOC_STILLCAPT", 0x000076c4 },
+{ "ASHMEM_GET_SIZE", 0x00007704 },
+{ "ASHMEM_GET_PROT_MASK", 0x00007706 },
+{ "ASHMEM_GET_PIN_STATUS", 0x00007709 },
+{ "ASHMEM_PURGE_ALL_CACHES", 0x0000770a },
+{ "FIOSETOWN", 0x00008901 },
+{ "SIOCSPGRP", 0x00008902 },
+{ "FIOGETOWN", 0x00008903 },
+{ "SIOCGPGRP", 0x00008904 },
+{ "SIOCATMARK", 0x00008905 },
+{ "SIOCGSTAMP", 0x00008906 },
+{ "SIOCGSTAMPNS", 0x00008907 },
+{ "SIOCADDRT", 0x0000890b },
+{ "SIOCDELRT", 0x0000890c },
+{ "SIOCRTMSG", 0x0000890d },
+{ "SIOCGIFNAME", 0x00008910 },
+{ "SIOCSIFLINK", 0x00008911 },
+{ "SIOCGIFCONF", 0x00008912 },
+{ "SIOCGIFFLAGS", 0x00008913 },
+{ "SIOCSIFFLAGS", 0x00008914 },
+{ "SIOCGIFADDR", 0x00008915 },
+{ "SIOCSIFADDR", 0x00008916 },
+{ "SIOCGIFDSTADDR", 0x00008917 },
+{ "SIOCSIFDSTADDR", 0x00008918 },
+{ "SIOCGIFBRDADDR", 0x00008919 },
+{ "SIOCSIFBRDADDR", 0x0000891a },
+{ "SIOCGIFNETMASK", 0x0000891b },
+{ "SIOCSIFNETMASK", 0x0000891c },
+{ "SIOCGIFMETRIC", 0x0000891d },
+{ "SIOCSIFMETRIC", 0x0000891e },
+{ "SIOCGIFMEM", 0x0000891f },
+{ "SIOCSIFMEM", 0x00008920 },
+{ "SIOCGIFMTU", 0x00008921 },
+{ "SIOCSIFMTU", 0x00008922 },
+{ "SIOCSIFNAME", 0x00008923 },
+{ "SIOCSIFHWADDR", 0x00008924 },
+{ "SIOCGIFENCAP", 0x00008925 },
+{ "SIOCSIFENCAP", 0x00008926 },
+{ "SIOCGIFHWADDR", 0x00008927 },
+{ "SIOCGIFSLAVE", 0x00008929 },
+{ "SIOCSIFSLAVE", 0x00008930 },
+{ "SIOCADDMULTI", 0x00008931 },
+{ "SIOCDELMULTI", 0x00008932 },
+{ "SIOCGIFINDEX", 0x00008933 },
+{ "SIOCSIFPFLAGS", 0x00008934 },
+{ "SIOCGIFPFLAGS", 0x00008935 },
+{ "SIOCDIFADDR", 0x00008936 },
+{ "SIOCSIFHWBROADCAST", 0x00008937 },
+{ "SIOCGIFCOUNT", 0x00008938 },
+{ "SIOCGIFBR", 0x00008940 },
+{ "SIOCSIFBR", 0x00008941 },
+{ "SIOCGIFTXQLEN", 0x00008942 },
+{ "SIOCSIFTXQLEN", 0x00008943 },
+{ "SIOCETHTOOL", 0x00008946 },
+{ "SIOCGMIIPHY", 0x00008947 },
+{ "SIOCGMIIREG", 0x00008948 },
+{ "SIOCSMIIREG", 0x00008949 },
+{ "SIOCWANDEV", 0x0000894a },
+{ "SIOCOUTQNSD", 0x0000894b },
+{ "SIOCDARP", 0x00008953 },
+{ "SIOCGARP", 0x00008954 },
+{ "SIOCSARP", 0x00008955 },
+{ "SIOCDRARP", 0x00008960 },
+{ "SIOCGRARP", 0x00008961 },
+{ "SIOCSRARP", 0x00008962 },
+{ "SIOCGIFMAP", 0x00008970 },
+{ "SIOCSIFMAP", 0x00008971 },
+{ "SIOCADDDLCI", 0x00008980 },
+{ "SIOCDELDLCI", 0x00008981 },
+{ "SIOCGIFVLAN", 0x00008982 },
+{ "SIOCSIFVLAN", 0x00008983 },
+{ "SIOCBONDENSLAVE", 0x00008990 },
+{ "SIOCBONDRELEASE", 0x00008991 },
+{ "SIOCBONDSETHWADDR", 0x00008992 },
+{ "SIOCBONDSLAVEINFOQUERY", 0x00008993 },
+{ "SIOCBONDINFOQUERY", 0x00008994 },
+{ "SIOCBONDCHANGEACTIVE", 0x00008995 },
+{ "SIOCBRADDBR", 0x000089a0 },
+{ "SIOCBRDELBR", 0x000089a1 },
+{ "SIOCBRADDIF", 0x000089a2 },
+{ "SIOCBRDELIF", 0x000089a3 },
+{ "SIOCSHWTSTAMP", 0x000089b0 },
+{ "SIOCGHWTSTAMP", 0x000089b1 },
+{ "SIOCPROTOPRIVATE", 0x000089e0 },
+{ "SIOCDEVPRIVATE", 0x000089f0 },
+{ "SIOCIWFIRST", 0x00008b00 },
+{ "SIOCSIWCOMMIT", 0x00008b00 },
+{ "SIOCGIWNAME", 0x00008b01 },
+{ "SIOCSIWNWID", 0x00008b02 },
+{ "SIOCGIWNWID", 0x00008b03 },
+{ "SIOCSIWFREQ", 0x00008b04 },
+{ "SIOCGIWFREQ", 0x00008b05 },
+{ "SIOCSIWMODE", 0x00008b06 },
+{ "SIOCGIWMODE", 0x00008b07 },
+{ "SIOCSIWSENS", 0x00008b08 },
+{ "SIOCGIWSENS", 0x00008b09 },
+{ "SIOCSIWRANGE", 0x00008b0a },
+{ "SIOCGIWRANGE", 0x00008b0b },
+{ "SIOCSIWPRIV", 0x00008b0c },
+{ "SIOCGIWPRIV", 0x00008b0d },
+{ "SIOCSIWSTATS", 0x00008b0e },
+{ "SIOCGIWSTATS", 0x00008b0f },
+{ "SIOCSIWSPY", 0x00008b10 },
+{ "SIOCGIWSPY", 0x00008b11 },
+{ "SIOCSIWTHRSPY", 0x00008b12 },
+{ "SIOCGIWTHRSPY", 0x00008b13 },
+{ "SIOCSIWAP", 0x00008b14 },
+{ "SIOCGIWAP", 0x00008b15 },
+{ "SIOCSIWMLME", 0x00008b16 },
+{ "SIOCGIWAPLIST", 0x00008b17 },
+{ "SIOCSIWSCAN", 0x00008b18 },
+{ "SIOCGIWSCAN", 0x00008b19 },
+{ "SIOCSIWESSID", 0x00008b1a },
+{ "SIOCGIWESSID", 0x00008b1b },
+{ "SIOCSIWNICKN", 0x00008b1c },
+{ "SIOCGIWNICKN", 0x00008b1d },
+{ "SIOCSIWRATE", 0x00008b20 },
+{ "SIOCGIWRATE", 0x00008b21 },
+{ "SIOCSIWRTS", 0x00008b22 },
+{ "SIOCGIWRTS", 0x00008b23 },
+{ "SIOCSIWFRAG", 0x00008b24 },
+{ "SIOCGIWFRAG", 0x00008b25 },
+{ "SIOCSIWTXPOW", 0x00008b26 },
+{ "SIOCGIWTXPOW", 0x00008b27 },
+{ "SIOCSIWRETRY", 0x00008b28 },
+{ "SIOCGIWRETRY", 0x00008b29 },
+{ "SIOCSIWENCODE", 0x00008b2a },
+{ "SIOCGIWENCODE", 0x00008b2b },
+{ "SIOCSIWPOWER", 0x00008b2c },
+{ "SIOCGIWPOWER", 0x00008b2d },
+{ "SIOCSIWGENIE", 0x00008b30 },
+{ "SIOCGIWGENIE", 0x00008b31 },
+{ "SIOCSIWAUTH", 0x00008b32 },
+{ "SIOCGIWAUTH", 0x00008b33 },
+{ "SIOCSIWENCODEEXT", 0x00008b34 },
+{ "SIOCGIWENCODEEXT", 0x00008b35 },
+{ "SIOCSIWPMKSA", 0x00008b36 },
+{ "SIOCIWFIRSTPRIV", 0x00008be0 },
+{ "SIOCIWLASTPRIV", 0x00008bff },
+{ "AUTOFS_IOC_READY", 0x00009360 },
+{ "AUTOFS_IOC_FAIL", 0x00009361 },
+{ "AUTOFS_IOC_CATATONIC", 0x00009362 },
+{ "BTRFS_IOC_TRANS_START", 0x00009406 },
+{ "BTRFS_IOC_TRANS_END", 0x00009407 },
+{ "BTRFS_IOC_SYNC", 0x00009408 },
+{ "BTRFS_IOC_SCRUB_CANCEL", 0x0000941c },
+{ "BTRFS_IOC_QUOTA_RESCAN_WAIT", 0x0000942e },
+{ "NBD_SET_SOCK", 0x0000ab00 },
+{ "NBD_SET_BLKSIZE", 0x0000ab01 },
+{ "NBD_SET_SIZE", 0x0000ab02 },
+{ "NBD_DO_IT", 0x0000ab03 },
+{ "NBD_CLEAR_SOCK", 0x0000ab04 },
+{ "NBD_CLEAR_QUE", 0x0000ab05 },
+{ "NBD_PRINT_DEBUG", 0x0000ab06 },
+{ "NBD_SET_SIZE_BLOCKS", 0x0000ab07 },
+{ "NBD_DISCONNECT", 0x0000ab08 },
+{ "NBD_SET_TIMEOUT", 0x0000ab09 },
+{ "NBD_SET_FLAGS", 0x0000ab0a },
+{ "RAW_SETBIND", 0x0000ac00 },
+{ "RAW_GETBIND", 0x0000ac01 },
+{ "KVM_GET_API_VERSION", 0x0000ae00 },
+{ "KVM_CREATE_VM", 0x0000ae01 },
+{ "KVM_CHECK_EXTENSION", 0x0000ae03 },
+{ "KVM_GET_VCPU_MMAP_SIZE", 0x0000ae04 },
+{ "KVM_S390_ENABLE_SIE", 0x0000ae06 },
+{ "KVM_CREATE_VCPU", 0x0000ae41 },
+{ "KVM_SET_NR_MMU_PAGES", 0x0000ae44 },
+{ "KVM_GET_NR_MMU_PAGES", 0x0000ae45 },
+{ "KVM_SET_TSS_ADDR", 0x0000ae47 },
+{ "KVM_CREATE_IRQCHIP", 0x0000ae60 },
+{ "KVM_CREATE_PIT", 0x0000ae64 },
+{ "KVM_REINJECT_CONTROL", 0x0000ae71 },
+{ "KVM_SET_BOOT_CPU_ID", 0x0000ae78 },
+{ "KVM_RUN", 0x0000ae80 },
+{ "KVM_S390_INITIAL_RESET", 0x0000ae97 },
+{ "KVM_NMI", 0x0000ae9a },
+{ "KVM_SET_TSC_KHZ", 0x0000aea2 },
+{ "KVM_GET_TSC_KHZ", 0x0000aea3 },
+{ "KVM_KVMCLOCK_CTRL", 0x0000aead },
+{ "KVM_SMI", 0x0000aeb7 },
+{ "VHOST_SET_OWNER", 0x0000af01 },
+{ "VHOST_RESET_OWNER", 0x0000af02 },
+{ "PPPOEIOCDFWD", 0x0000b101 },
+{ "IOCTL_EVTCHN_BIND_VIRQ", 0x00044500 },
+{ "IOCTL_EVTCHN_BIND_UNBOUND_PORT", 0x00044502 },
+{ "IOCTL_EVTCHN_UNBIND", 0x00044503 },
+{ "IOCTL_EVTCHN_NOTIFY", 0x00044504 },
+{ "IOCTL_GNTDEV_SET_MAX_GRANTS", 0x00044703 },
+{ "IOCTL_EVTCHN_BIND_INTERDOMAIN", 0x00084501 },
+{ "IOCTL_GNTDEV_UNMAP_GRANT_REF", 0x00104701 },
+{ "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", 0x00104707 },
+{ "IOCTL_GNTDEV_GRANT_COPY", 0x00104708 },
+{ "IOCTL_GNTDEV_MAP_GRANT_REF", 0x00184700 },
+{ "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", 0x00184702 },
+{ "MFB_SET_ALPHA", 0x40014d00 },
+{ "MFB_SET_GAMMA", 0x40014d01 },
+{ "MFB_SET_BRIGHTNESS", 0x40014d03 },
+{ "USBTMC488_IOCTL_REN_CONTROL", 0x40015b13 },
+{ "SPI_IOC_WR_MODE", 0x40016b01 },
+{ "SPI_IOC_WR_LSB_FIRST", 0x40016b02 },
+{ "SPI_IOC_WR_BITS_PER_WORD", 0x40016b03 },
+{ "PPWCONTROL", 0x40017084 },
+{ "PPWDATA", 0x40017086 },
+{ "PPWCTLONIRQ", 0x40017092 },
+{ "PHONE_MAXRINGS", 0x40017185 },
+{ "PHONE_PLAY_TONE", 0x4001719b },
+{ "SONYPI_IOCSBRT", 0x40017600 },
+{ "SONYPI_IOCSBLUE", 0x40017609 },
+{ "SONYPI_IOCSFAN", 0x4001760b },
+{ "HFI1_IOCTL_SET_PKEY", 0x40021beb },
+{ "ATM_SETBACKEND", 0x400261f2 },
+{ "ATM_NEWBACKENDIF", 0x400261f3 },
+{ "RIO_MPORT_MAINT_HDID_SET", 0x40026d01 },
+{ "NCP_IOC_GETMOUNTUID", 0x40026e02 },
+{ "AUDIO_SET_ATTRIBUTES", 0x40026f11 },
+{ "DMX_ADD_PID", 0x40026f33 },
+{ "DMX_REMOVE_PID", 0x40026f34 },
+{ "PPFCONTROL", 0x4002708e },
+{ "PHONE_RING_CADENCE", 0x40027186 },
+{ "SET_BITMAP_FILE", 0x4004092b },
+{ "IB_USER_MAD_UNREGISTER_AGENT", 0x40041b02 },
+{ "HFI1_IOCTL_RECV_CTRL", 0x40041be8 },
+{ "HFI1_IOCTL_POLL_TYPE", 0x40041be9 },
+{ "FW_CDEV_IOC_DEALLOCATE", 0x40042303 },
+{ "FW_CDEV_IOC_INITIATE_BUS_RESET", 0x40042305 },
+{ "FW_CDEV_IOC_REMOVE_DESCRIPTOR", 0x40042307 },
+{ "FW_CDEV_IOC_STOP_ISO", 0x4004230b },
+{ "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", 0x4004230e },
+{ "FW_CDEV_IOC_FLUSH_ISO", 0x40042318 },
+{ "PERF_EVENT_IOC_SET_BPF", 0x40042408 },
+{ "PERF_EVENT_IOC_PAUSE_OUTPUT", 0x40042409 },
+{ "SNAPSHOT_CREATE_IMAGE", 0x40043311 },
+{ "PTP_ENABLE_PPS", 0x40043d04 },
+{ "SNDRV_PCM_IOCTL_TSTAMP", 0x40044102 },
+{ "SNDRV_PCM_IOCTL_TTSTAMP", 0x40044103 },
+{ "AGPIOC_DEALLOCATE", 0x40044107 },
+{ "SNDRV_PCM_IOCTL_PAUSE", 0x40044145 },
+{ "SNDRV_PCM_IOCTL_LINK", 0x40044160 },
+{ "CCISS_REGNEWDISK", 0x4004420d },
+{ "CS_SET_WAKELINE", 0x40044317 },
+{ "EVIOCRMFF", 0x40044581 },
+{ "EVIOCGRAB", 0x40044590 },
+{ "EVIOCREVOKE", 0x40044591 },
+{ "EVIOCSCLOCKID", 0x400445a0 },
+{ "FBIOPUT_CONTRAST", 0x40044602 },
+{ "FBIPUT_BRIGHTNESS", 0x40044603 },
+{ "FBIPUT_COLOR", 0x40044606 },
+{ "FBIPUT_HSYNC", 0x40044609 },
+{ "FBIPUT_VSYNC", 0x4004460a },
+{ "FBIO_WAITFORVSYNC", 0x40044620 },
+{ "SSTFB_SET_VGAPASS", 0x400446dd },
+{ "IOCTL_MEI_NOTIFY_SET", 0x40044802 },
+{ "HIDIOCSFLAG", 0x4004480f },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", 0x40044820 },
+{ "SNDRV_DM_FM_IOCTL_SET_MODE", 0x40044825 },
+{ "SNDRV_DM_FM_IOCTL_SET_CONNECTION", 0x40044826 },
+{ "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", 0x40044883 },
+{ "SNDRV_EMUX_IOCTL_MEM_AVAIL", 0x40044884 },
+{ "HCIDEVUP", 0x400448c9 },
+{ "HCIDEVDOWN", 0x400448ca },
+{ "HCIDEVRESET", 0x400448cb },
+{ "HCIDEVRESTAT", 0x400448cc },
+{ "HCISETRAW", 0x400448dc },
+{ "HCISETSCAN", 0x400448dd },
+{ "HCISETAUTH", 0x400448de },
+{ "HCISETENCRYPT", 0x400448df },
+{ "HCISETPTYPE", 0x400448e0 },
+{ "HCISETLINKPOL", 0x400448e1 },
+{ "HCISETLINKMODE", 0x400448e2 },
+{ "HCISETACLMTU", 0x400448e3 },
+{ "HCISETSCOMTU", 0x400448e4 },
+{ "HCIBLOCKADDR", 0x400448e6 },
+{ "HCIUNBLOCKADDR", 0x400448e7 },
+{ "MFB_SET_PIXFMT", 0x40044d08 },
+{ "OTPGETREGIONCOUNT", 0x40044d0e },
+{ "UBI_IOCEBER", 0x40044f01 },
+{ "UBI_IOCEBCH", 0x40044f02 },
+{ "UBI_IOCEBUNMAP", 0x40044f04 },
+{ "OMAPFB_MIRROR", 0x40044f1f },
+{ "OMAPFB_SET_UPDATE_MODE", 0x40044f28 },
+{ "OMAPFB_GET_UPDATE_MODE", 0x40044f2b },
+{ "OMAPFB_LCD_TEST", 0x40044f2d },
+{ "OMAPFB_CTRL_TEST", 0x40044f2e },
+{ "SNDCTL_DSP_SETTRIGGER", 0x40045010 },
+{ "SNDCTL_DSP_PROFILE", 0x40045017 },
+{ "SNDCTL_DSP_SETSPDIF", 0x40045042 },
+{ "SNDCTL_SEQ_PERCMODE", 0x40045106 },
+{ "SNDCTL_SEQ_TESTMIDI", 0x40045108 },
+{ "SNDCTL_SEQ_RESETSAMPLES", 0x40045109 },
+{ "SNDCTL_SEQ_THRESHOLD", 0x4004510d },
+{ "SNDCTL_FM_4OP_ENABLE", 0x4004510f },
+{ "RNDADDTOENTCNT", 0x40045201 },
+{ "SAA6588_CMD_CLOSE", 0x40045202 },
+{ "RFCOMMCREATEDEV", 0x400452c8 },
+{ "RFCOMMRELEASEDEV", 0x400452c9 },
+{ "RFCOMMSTEALDLC", 0x400452dc },
+{ "SNDRV_TIMER_IOCTL_TREAD", 0x40045402 },
+{ "SNDCTL_TMR_METRONOME", 0x40045407 },
+{ "SNDCTL_TMR_SELECT", 0x40045408 },
+{ "TIOCSPTLCK", 0x40045431 },
+{ "TIOCSIG", 0x40045436 },
+{ "TUNSETNOCSUM", 0x400454c8 },
+{ "TUNSETDEBUG", 0x400454c9 },
+{ "TUNSETIFF", 0x400454ca },
+{ "TUNSETPERSIST", 0x400454cb },
+{ "TUNSETOWNER", 0x400454cc },
+{ "TUNSETLINK", 0x400454cd },
+{ "TUNSETGROUP", 0x400454ce },
+{ "TUNSETOFFLOAD", 0x400454d0 },
+{ "TUNSETTXFILTER", 0x400454d1 },
+{ "TUNSETSNDBUF", 0x400454d4 },
+{ "TUNSETVNETHDRSZ", 0x400454d8 },
+{ "TUNSETQUEUE", 0x400454d9 },
+{ "TUNSETIFINDEX", 0x400454da },
+{ "TUNSETVNETLE", 0x400454dc },
+{ "TUNSETVNETBE", 0x400454de },
+{ "USBDEVFS_REAPURB32", 0x4004550c },
+{ "USBDEVFS_REAPURBNDELAY32", 0x4004550d },
+{ "USBDEVFS_DROP_PRIVILEGES", 0x4004551e },
+{ "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", 0x40045532 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", 0x40045542 },
+{ "UI_SET_EVBIT", 0x40045564 },
+{ "UI_SET_KEYBIT", 0x40045565 },
+{ "UI_SET_RELBIT", 0x40045566 },
+{ "UI_SET_ABSBIT", 0x40045567 },
+{ "UI_SET_MSCBIT", 0x40045568 },
+{ "UI_SET_LEDBIT", 0x40045569 },
+{ "UI_SET_SNDBIT", 0x4004556a },
+{ "UI_SET_FFBIT", 0x4004556b },
+{ "UI_SET_SWBIT", 0x4004556d },
+{ "UI_SET_PROPBIT", 0x4004556e },
+{ "VIDIOC_OVERLAY", 0x4004560e },
+{ "VIDIOC_STREAMON", 0x40045612 },
+{ "VIDIOC_STREAMOFF", 0x40045613 },
+{ "VIDIOC_S_PRIORITY", 0x40045644 },
+{ "IVTV_IOC_PASSTHROUGH_MODE", 0x400456c1 },
+{ "SW_SYNC_IOC_INC", 0x40045701 },
+{ "SNDRV_RAWMIDI_IOCTL_DROP", 0x40045730 },
+{ "SNDRV_RAWMIDI_IOCTL_DRAIN", 0x40045731 },
+{ "SONET_SETFRAMING", 0x40046115 },
+{ "ATM_SETSC", 0x400461f1 },
+{ "ATM_DROPPARTY", 0x400461f5 },
+{ "BINDER_SET_MAX_THREADS", 0x40046205 },
+{ "BINDER_SET_IDLE_PRIORITY", 0x40046206 },
+{ "BINDER_SET_CONTEXT_MGR", 0x40046207 },
+{ "BINDER_THREAD_EXIT", 0x40046208 },
+{ "BC_ACQUIRE_RESULT", 0x40046302 },
+{ "BC_INCREFS", 0x40046304 },
+{ "BC_ACQUIRE", 0x40046305 },
+{ "CHIOSPICKER", 0x40046305 },
+{ "BC_RELEASE", 0x40046306 },
+{ "BC_DECREFS", 0x40046307 },
+{ "DRM_IOCTL_AUTH_MAGIC", 0x40046411 },
+{ "DRM_IOCTL_I915_IRQ_WAIT", 0x40046445 },
+{ "DRM_IOCTL_MSM_GEM_CPU_FINI", 0x40046445 },
+{ "DRM_IOCTL_RADEON_FULLSCREEN", 0x40046446 },
+{ "DRM_IOCTL_MGA_SET_FENCE", 0x4004644a },
+{ "DRM_IOCTL_I915_DESTROY_HEAP", 0x4004644c },
+{ "DRM_IOCTL_I915_SET_VBLANK_PIPE", 0x4004644d },
+{ "DRM_IOCTL_R128_FULLSCREEN", 0x40046450 },
+{ "DRM_IOCTL_RADEON_IRQ_WAIT", 0x40046457 },
+{ "DRM_IOCTL_RADEON_SURF_FREE", 0x4004645b },
+{ "DRM_IOCTL_I915_GEM_SW_FINISH", 0x40046460 },
+{ "VIDIOC_INT_RESET", 0x40046466 },
+{ "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", 0x40046483 },
+{ "FS_IOC32_SETFLAGS", 0x40046602 },
+{ "LIRC_SET_SEND_MODE", 0x40046911 },
+{ "LIRC_SET_REC_MODE", 0x40046912 },
+{ "LIRC_SET_SEND_CARRIER", 0x40046913 },
+{ "LIRC_SET_REC_CARRIER", 0x40046914 },
+{ "LIRC_SET_SEND_DUTY_CYCLE", 0x40046915 },
+{ "LIRC_SET_REC_DUTY_CYCLE", 0x40046916 },
+{ "LIRC_SET_TRANSMITTER_MASK", 0x40046917 },
+{ "LIRC_SET_REC_TIMEOUT", 0x40046918 },
+{ "LIRC_SET_REC_TIMEOUT_REPORTS", 0x40046919 },
+{ "LIRC_SET_REC_FILTER_PULSE", 0x4004691a },
+{ "LIRC_SET_REC_FILTER_SPACE", 0x4004691b },
+{ "LIRC_SET_REC_FILTER", 0x4004691c },
+{ "LIRC_SET_MEASURE_CARRIER_MODE", 0x4004691d },
+{ "LIRC_SET_REC_DUTY_CYCLE_RANGE", 0x4004691e },
+{ "IPMICTL_SET_MAINTENANCE_MODE_CMD", 0x4004691f },
+{ "LIRC_SET_REC_CARRIER_RANGE", 0x4004691f },
+{ "LIRC_SET_WIDEBAND_RECEIVER", 0x40046923 },
+{ "SPI_IOC_WR_MAX_SPEED_HZ", 0x40046b04 },
+{ "SPI_IOC_WR_MODE32", 0x40046b05 },
+{ "RIO_MPORT_MAINT_COMPTAG_SET", 0x40046d02 },
+{ "RIO_SET_EVENT_MASK", 0x40046d0d },
+{ "NCP_IOC_SET_SIGN_WANTED", 0x40046e06 },
+{ "NCP_IOC_GETDENTRYTTL", 0x40046e0c },
+{ "SISFB_SET_AUTOMAXIMIZE_OLD", 0x40046efa },
+{ "UBI_IOCRMVOL", 0x40046f01 },
+{ "DMX_SET_SOURCE", 0x40046f31 },
+{ "UBI_IOCDET", 0x40046f41 },
+{ "PPSETMODE", 0x40047080 },
+{ "PPDATADIR", 0x40047090 },
+{ "PPNEGOT", 0x40047091 },
+{ "PPSETPHASE", 0x40047094 },
+{ "PPSETFLAGS", 0x4004709b },
+{ "PHONE_REC_CODEC", 0x40047189 },
+{ "PHONE_REC_DEPTH", 0x4004718c },
+{ "PHONE_FRAME", 0x4004718d },
+{ "PHONE_REC_VOLUME", 0x4004718e },
+{ "PHONE_PLAY_CODEC", 0x40047190 },
+{ "PHONE_PLAY_DEPTH", 0x40047193 },
+{ "PHONE_PLAY_VOLUME", 0x40047194 },
+{ "PHONE_DTMF_OOB", 0x40047199 },
+{ "PHONE_SET_TONE_ON_TIME", 0x4004719c },
+{ "PHONE_SET_TONE_OFF_TIME", 0x4004719d },
+{ "PHONE_PSTN_SET_STATE", 0x400471a4 },
+{ "PHONE_WINK_DURATION", 0x400471a6 },
+{ "PHONE_VAD", 0x400471a9 },
+{ "PHONE_WINK", 0x400471aa },
+{ "IXJCTL_GET_FILTER_HIST", 0x400471c8 },
+{ "IXJCTL_AEC_START", 0x400471cb },
+{ "IXJCTL_SET_LED", 0x400471ce },
+{ "IXJCTL_MIXER", 0x400471cf },
+{ "IXJCTL_DAA_COEFF_SET", 0x400471d0 },
+{ "IXJCTL_PORT", 0x400471d1 },
+{ "IXJCTL_DAA_AGAIN", 0x400471d2 },
+{ "IXJCTL_POTS_PSTN", 0x400471d5 },
+{ "PHONE_REC_VOLUME_LINEAR", 0x400471db },
+{ "PHONE_PLAY_VOLUME_LINEAR", 0x400471dc },
+{ "IXJCTL_HZ", 0x400471e0 },
+{ "IXJCTL_RATE", 0x400471e1 },
+{ "IXJCTL_DTMF_PRESCALE", 0x400471e8 },
+{ "IXJCTL_SC_RXG", 0x400471ea },
+{ "IXJCTL_SC_TXG", 0x400471eb },
+{ "IXJCTL_INTERCOM_START", 0x400471fd },
+{ "IXJCTL_INTERCOM_STOP", 0x400471fe },
+{ "FAT_IOCTL_SET_ATTRIBUTES", 0x40047211 },
+{ "SCIF_LISTEN", 0x40047302 },
+{ "PPPIOCATTCHAN", 0x40047438 },
+{ "PPPIOCCONNECT", 0x4004743a },
+{ "PPPIOCSMRRU", 0x4004743b },
+{ "PPPIOCDETACH", 0x4004743c },
+{ "PPPIOCATTACH", 0x4004743d },
+{ "PPPIOCSDEBUG", 0x40047440 },
+{ "PPPIOCSMAXCID", 0x40047451 },
+{ "PPPIOCSMRU", 0x40047452 },
+{ "PPPIOCSRASYNCMAP", 0x40047454 },
+{ "PPPIOCSASYNCMAP", 0x40047457 },
+{ "PPPIOCSFLAGS", 0x40047459 },
+{ "PPPIOCBUNDLE", 0x40047481 },
+{ "PPPIOCSMPFLAGS", 0x40047483 },
+{ "PPPIOCSMPMTU", 0x40047484 },
+{ "PPPIOCSMPMRU", 0x40047485 },
+{ "PPPIOCSCOMPRESSOR", 0x40047487 },
+{ "V4L2_SUBDEV_IR_RX_NOTIFY", 0x40047600 },
+{ "V4L2_SUBDEV_IR_TX_NOTIFY", 0x40047601 },
+{ "FS_IOC32_SETVERSION", 0x40047602 },
+{ "MEYEIOC_QBUF_CAPT", 0x400476c2 },
+{ "OSIOCSNETADDR", 0x400489e0 },
+{ "SIOCSNETADDR", 0x400489e0 },
+{ "AUTOFS_IOC_EXPIRE_MULTI", 0x40049366 },
+{ "BTRFS_IOC_CLONE", 0x40049409 },
+{ "FICLONE", 0x40049409 },
+{ "BTRFS_IOC_BALANCE_CTL", 0x40049421 },
+{ "KVM_INTERRUPT", 0x4004ae86 },
+{ "KVM_SET_SIGNAL_MASK", 0x4004ae8b },
+{ "KVM_SET_MP_STATE", 0x4004ae99 },
+{ "VHOST_SET_LOG_FD", 0x4004af07 },
+{ "VHOST_SCSI_GET_ABI_VERSION", 0x4004af42 },
+{ "VHOST_SCSI_SET_EVENTS_MISSED", 0x4004af43 },
+{ "VHOST_SCSI_GET_EVENTS_MISSED", 0x4004af44 },
+{ "SISFB_SET_AUTOMAXIMIZE", 0x4004f303 },
+{ "SISFB_SET_TVPOSOFFSET", 0x4004f304 },
+{ "SISFB_SET_LOCK", 0x4004f306 },
+{ "GIGASET_BRKCHARS", 0x40064702 },
+{ "MEYEIOC_S_PARAMS", 0x400676c1 },
+{ "FE_DISEQC_SEND_MASTER_CMD", 0x40076f3f },
+{ "BLKBSZSET", 0x40081271 },
+{ "HFI1_IOCTL_ACK_EVENT", 0x40081bea },
+{ "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", 0x40082316 },
+{ "PERF_EVENT_IOC_PERIOD", 0x40082404 },
+{ "PERF_EVENT_IOC_SET_FILTER", 0x40082406 },
+{ "STP_SET_OPTIONS", 0x40082502 },
+{ "FBIO_RADEON_SET_MIRROR", 0x40084004 },
+{ "AGPIOC_SETUP", 0x40084103 },
+{ "AGPIOC_RESERVE", 0x40084104 },
+{ "AGPIOC_PROTECT", 0x40084105 },
+{ "AGPIOC_BIND", 0x40084108 },
+{ "AGPIOC_UNBIND", 0x40084109 },
+{ "SNDRV_PCM_IOCTL_REWIND", 0x40084146 },
+{ "SNDRV_PCM_IOCTL_FORWARD", 0x40084149 },
+{ "PMU_IOC_SET_BACKLIGHT", 0x40084202 },
+{ "CCISS_SETINTINFO", 0x40084203 },
+{ "APEI_ERST_CLEAR_RECORD", 0x40084501 },
+{ "EVIOCSREP", 0x40084503 },
+{ "EVIOCSKEYCODE", 0x40084504 },
+{ "SNDRV_SB_CSP_IOCTL_START", 0x40084813 },
+{ "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", 0x40084842 },
+{ "AMDKFD_IOC_DESTROY_EVENT", 0x40084b09 },
+{ "AMDKFD_IOC_SET_EVENT", 0x40084b0a },
+{ "AMDKFD_IOC_RESET_EVENT", 0x40084b0b },
+{ "AMDKFD_IOC_DBG_REGISTER", 0x40084b0d },
+{ "AMDKFD_IOC_DBG_UNREGISTER", 0x40084b0e },
+{ "MEMERASE", 0x40084d02 },
+{ "MFB_SET_AOID", 0x40084d04 },
+{ "MEMLOCK", 0x40084d05 },
+{ "MEMUNLOCK", 0x40084d06 },
+{ "MEMGETBADBLOCK", 0x40084d0b },
+{ "MEMSETBADBLOCK", 0x40084d0c },
+{ "UBI_IOCVOLUP", 0x40084f00 },
+{ "UBI_IOCEBMAP", 0x40084f03 },
+{ "OMAPFB_SETUP_MEM", 0x40084f37 },
+{ "OMAPFB_QUERY_MEM", 0x40084f38 },
+{ "OMAPFB_SET_TEARSYNC", 0x40084f3e },
+{ "SNDCTL_SEQ_OUTOFBAND", 0x40085112 },
+{ "RNDADDENTROPY", 0x40085203 },
+{ "TFD_IOC_SET_TICKS", 0x40085400 },
+{ "NCIUARTSETDRIVER", 0x40085500 },
+{ "USBDEVFS_REAPURB", 0x4008550c },
+{ "USBDEVFS_REAPURBNDELAY", 0x4008550d },
+{ "USBDEVFS_CONNECTINFO", 0x40085511 },
+{ "UI_SET_PHYS", 0x4008556c },
+{ "VIDIOC_S_STD", 0x40085618 },
+{ "VIDIOC_AM437X_CCDC_CFG", 0x400856c1 },
+{ "VPFE_CMD_S_CCDC_RAW_PARAMS", 0x400856c1 },
+{ "DMA_BUF_IOCTL_SYNC", 0x40086200 },
+{ "BINDER_SET_IDLE_TIMEOUT", 0x40086203 },
+{ "CM_IOCSPTS", 0x40086302 },
+{ "BC_FREE_BUFFER", 0x40086303 },
+{ "BC_ATTEMPT_ACQUIRE", 0x4008630a },
+{ "BC_DEAD_BINDER_DONE", 0x40086310 },
+{ "CM_IOSDBGLVL", 0x400863fa },
+{ "DRM_IOCTL_MODESET_CTL", 0x40086408 },
+{ "DRM_IOCTL_GEM_CLOSE", 0x40086409 },
+{ "DRM_IOCTL_CONTROL", 0x40086414 },
+{ "DRM_IOCTL_MOD_CTX", 0x40086422 },
+{ "DRM_IOCTL_SWITCH_CTX", 0x40086424 },
+{ "DRM_IOCTL_NEW_CTX", 0x40086425 },
+{ "DRM_IOCTL_LOCK", 0x4008642a },
+{ "DRM_IOCTL_UNLOCK", 0x4008642b },
+{ "DRM_IOCTL_FINISH", 0x4008642c },
+{ "DRM_IOCTL_AGP_ENABLE", 0x40086432 },
+{ "DRM_IOCTL_MGA_FLUSH", 0x40086441 },
+{ "DRM_IOCTL_R128_CCE_STOP", 0x40086442 },
+{ "DRM_IOCTL_RADEON_CP_STOP", 0x40086442 },
+{ "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", 0x40086443 },
+{ "DRM_IOCTL_OMAP_GEM_CPU_PREP", 0x40086444 },
+{ "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", 0x40086445 },
+{ "DRM_IOCTL_QXL_CLIENTCAP", 0x40086445 },
+{ "DRM_IOCTL_I915_SETPARAM", 0x40086447 },
+{ "DRM_IOCTL_I915_FREE", 0x40086449 },
+{ "DRM_IOCTL_RADEON_STIPPLE", 0x4008644c },
+{ "DRM_IOCTL_R128_STIPPLE", 0x4008644d },
+{ "DRM_IOCTL_VIA_BLIT_SYNC", 0x4008644f },
+{ "DRM_IOCTL_RADEON_FREE", 0x40086454 },
+{ "DRM_IOCTL_I915_GEM_UNPIN", 0x40086456 },
+{ "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", 0x40086464 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", 0x4008646e },
+{ "DRM_IOCTL_I915_GEM_SET_CACHING", 0x4008646f },
+{ "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", 0x40086482 },
+{ "FS_IOC_SETFLAGS", 0x40086602 },
+{ "HPET_IRQFREQ", 0x40086806 },
+{ "MTIOCTOP", 0x40086d01 },
+{ "RIO_ENABLE_DOORBELL_RANGE", 0x40086d09 },
+{ "RIO_DISABLE_DOORBELL_RANGE", 0x40086d0a },
+{ "RIO_UNMAP_INBOUND", 0x40086d12 },
+{ "RIO_FREE_DMA", 0x40086d14 },
+{ "RIO_WAIT_FOR_ASYNC", 0x40086d16 },
+{ "NCP_IOC_GETMOUNTUID2", 0x40086e02 },
+{ "NILFS_IOCTL_DELETE_CHECKPOINT", 0x40086e81 },
+{ "NILFS_IOCTL_RESIZE", 0x40086e8b },
+{ "MATROXFB_SET_OUTPUT_CONNECTION", 0x40086ef8 },
+{ "MATROXFB_SET_OUTPUT_MODE", 0x40086efa },
+{ "AUDIO_SET_MIXER", 0x40086f0e },
+{ "VIDEO_SET_SPU", 0x40086f32 },
+{ "CA_SET_PID", 0x40086f87 },
+{ "PHN_SET_REG", 0x40087001 },
+{ "PHN_SET_REGS", 0x40087003 },
+{ "PHN_SETREG", 0x40087006 },
+{ "RTC_IRQP_SET", 0x4008700c },
+{ "RTC_EPOCH_SET", 0x4008700e },
+{ "PPS_SETPARAMS", 0x400870a2 },
+{ "PPS_KC_BIND", 0x400870a5 },
+{ "SPIOCSTYPE", 0x40087101 },
+{ "PHONE_CAPABILITIES_CHECK", 0x40087182 },
+{ "PHONE_RING_START", 0x40087187 },
+{ "IXJCTL_SET_FILTER", 0x400871c7 },
+{ "IXJCTL_INIT_TONE", 0x400871c9 },
+{ "IXJCTL_TONE_CADENCE", 0x400871ca },
+{ "IXJCTL_FILTER_CADENCE", 0x400871d6 },
+{ "IXJCTL_CIDCW", 0x400871d9 },
+{ "IXJCTL_SET_FILTER_RAW", 0x400871dd },
+{ "IXJCTL_SIGCTL", 0x400871e9 },
+{ "PPPIOCSNPMODE", 0x4008744b },
+{ "FS_IOC_SETVERSION", 0x40087602 },
+{ "ASHMEM_SET_SIZE", 0x40087703 },
+{ "ASHMEM_SET_PROT_MASK", 0x40087705 },
+{ "ASHMEM_PIN", 0x40087707 },
+{ "ASHMEM_UNPIN", 0x40087708 },
+{ "BTRFS_IOC_DEFAULT_SUBVOL", 0x40089413 },
+{ "BTRFS_IOC_WAIT_SYNC", 0x40089416 },
+{ "BTRFS_IOC_SUBVOL_SETFLAGS", 0x4008941a },
+{ "KVM_SET_IDENTITY_MAP_ADDR", 0x4008ae48 },
+{ "KVM_S390_VCPU_FAULT", 0x4008ae52 },
+{ "KVM_IRQ_LINE", 0x4008ae61 },
+{ "KVM_SET_GSI_ROUTING", 0x4008ae6a },
+{ "KVM_ASSIGN_SET_MSIX_NR", 0x4008ae73 },
+{ "KVM_SET_MSRS", 0x4008ae89 },
+{ "KVM_SET_CPUID", 0x4008ae8a },
+{ "KVM_SET_CPUID2", 0x4008ae90 },
+{ "KVM_SET_VAPIC_ADDR", 0x4008ae93 },
+{ "KVM_S390_STORE_STATUS", 0x4008ae95 },
+{ "KVM_X86_SETUP_MCE", 0x4008ae9c },
+{ "VHOST_SET_FEATURES", 0x4008af00 },
+{ "VHOST_SET_MEM_TABLE", 0x4008af03 },
+{ "VHOST_SET_LOG_BASE", 0x4008af04 },
+{ "VHOST_SET_VRING_NUM", 0x4008af10 },
+{ "VHOST_SET_VRING_BASE", 0x4008af12 },
+{ "VHOST_SET_VRING_ENDIAN", 0x4008af13 },
+{ "VHOST_GET_VRING_ENDIAN", 0x4008af14 },
+{ "VHOST_SET_VRING_KICK", 0x4008af20 },
+{ "VHOST_SET_VRING_CALL", 0x4008af21 },
+{ "VHOST_SET_VRING_ERR", 0x4008af22 },
+{ "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", 0x4008af23 },
+{ "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", 0x4008af24 },
+{ "VHOST_NET_SET_BACKEND", 0x4008af30 },
+{ "PPPOEIOCSFWD", 0x4008b100 },
+{ "IOW_WRITE", 0x4008c001 },
+{ "IOW_READ", 0x4008c002 },
+{ "REISERFS_IOC_UNPACK", 0x4008cd01 },
+{ "SNDRV_DM_FM_IOCTL_SET_PARAMS", 0x40094824 },
+{ "FDFMTTRK", 0x400c0248 },
+{ "RUN_ARRAY", 0x400c0930 },
+{ "SNAPSHOT_SET_SWAP_AREA", 0x400c330d },
+{ "CAPI_REGISTER", 0x400c4301 },
+{ "HIDIOCGREPORT", 0x400c4807 },
+{ "HIDIOCSREPORT", 0x400c4808 },
+{ "SNDRV_DM_FM_IOCTL_PLAY_NOTE", 0x400c4822 },
+{ "MFB_SET_CHROMA_KEY", 0x400c4d01 },
+{ "OTPGETREGIONINFO", 0x400c4d0f },
+{ "UI_END_FF_ERASE", 0x400c55cb },
+{ "CHIOPOSITION", 0x400c6303 },
+{ "BC_REQUEST_DEATH_NOTIFICATION", 0x400c630e },
+{ "BC_CLEAR_DEATH_NOTIFICATION", 0x400c630f },
+{ "DRM_IOCTL_I810_VERTEX", 0x400c6441 },
+{ "DRM_IOCTL_I810_CLEAR", 0x400c6442 },
+{ "DRM_IOCTL_MGA_VERTEX", 0x400c6445 },
+{ "DRM_IOCTL_MGA_ILOAD", 0x400c6447 },
+{ "DRM_IOCTL_I915_INIT_HEAP", 0x400c644a },
+{ "DRM_IOCTL_RADEON_INIT_HEAP", 0x400c6455 },
+{ "DRM_IOCTL_RADEON_SURF_ALLOC", 0x400c645a },
+{ "DRM_IOCTL_I915_GEM_SET_DOMAIN", 0x400c645f },
+{ "FS_IOC_GET_ENCRYPTION_POLICY", 0x400c6615 },
+{ "I2OEVTREG", 0x400c690a },
+{ "HSC_SET_RX", 0x400c6b13 },
+{ "HSC_GET_RX", 0x400c6b14 },
+{ "NCP_IOC_GETROOT", 0x400c6e08 },
+{ "UBI_IOCRSVOL", 0x400c6f02 },
+{ "AUDIO_SET_KARAOKE", 0x400c6f12 },
+{ "KVM_CREATE_SPAPR_TCE", 0x400caea8 },
+{ "MBXFB_IOCS_REG", 0x400cf404 },
+{ "FW_CDEV_IOC_START_ISO", 0x4010230a },
+{ "FW_CDEV_IOC_SET_ISO_CHANNELS", 0x40102317 },
+{ "PTP_EXTTS_REQUEST", 0x40103d02 },
+{ "CCISS_SETNODENAME", 0x40104205 },
+{ "EVIOCSMASK", 0x40104593 },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_POKE", 0x40104821 },
+{ "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", 0x40104890 },
+{ "AMDKFD_IOC_DBG_ADDRESS_WATCH", 0x40104b0f },
+{ "AMDKFD_IOC_DBG_WAVE_CONTROL", 0x40104b10 },
+{ "MTRRIOC_ADD_ENTRY", 0x40104d00 },
+{ "MTRRIOC_SET_ENTRY", 0x40104d01 },
+{ "MTRRIOC_DEL_ENTRY", 0x40104d02 },
+{ "MTRRIOC_KILL_ENTRY", 0x40104d04 },
+{ "MTRRIOC_ADD_PAGE_ENTRY", 0x40104d05 },
+{ "MTRRIOC_SET_PAGE_ENTRY", 0x40104d06 },
+{ "MTRRIOC_DEL_PAGE_ENTRY", 0x40104d07 },
+{ "MTRRIOC_KILL_PAGE_ENTRY", 0x40104d09 },
+{ "MEMERASE64", 0x40104d14 },
+{ "UBI_IOCSETVOLPROP", 0x40104f06 },
+{ "OMAPFB_SET_COLOR_KEY", 0x40104f32 },
+{ "OMAPFB_GET_COLOR_KEY", 0x40104f33 },
+{ "TUNATTACHFILTER", 0x401054d5 },
+{ "TUNDETACHFILTER", 0x401054d6 },
+{ "IDT77105_GETSTAT", 0x40106132 },
+{ "IDT77105_GETSTATZ", 0x40106133 },
+{ "ATM_GETSTAT", 0x40106150 },
+{ "ATM_GETSTATZ", 0x40106151 },
+{ "ATM_GETLOOP", 0x40106152 },
+{ "ATM_SETLOOP", 0x40106153 },
+{ "ATM_QUERYLOOP", 0x40106154 },
+{ "ENI_MEMDUMP", 0x40106160 },
+{ "HE_GET_REG", 0x40106160 },
+{ "ZATM_GETPOOL", 0x40106161 },
+{ "NS_SETBUFLEV", 0x40106162 },
+{ "ZATM_GETPOOLZ", 0x40106162 },
+{ "ZATM_SETPOOL", 0x40106163 },
+{ "ENI_SETMULT", 0x40106167 },
+{ "ATM_GETLINKRATE", 0x40106181 },
+{ "ATM_GETNAMES", 0x40106183 },
+{ "ATM_GETTYPE", 0x40106184 },
+{ "ATM_GETESI", 0x40106185 },
+{ "ATM_GETADDR", 0x40106186 },
+{ "ATM_RSTADDR", 0x40106187 },
+{ "ATM_ADDADDR", 0x40106188 },
+{ "ATM_DELADDR", 0x40106189 },
+{ "ATM_GETCIRANGE", 0x4010618a },
+{ "ATM_SETCIRANGE", 0x4010618b },
+{ "ATM_SETESI", 0x4010618c },
+{ "ATM_SETESIF", 0x4010618d },
+{ "ATM_ADDLECSADDR", 0x4010618e },
+{ "ATM_DELLECSADDR", 0x4010618f },
+{ "ATM_GETLECSADDR", 0x40106190 },
+{ "ATM_ADDPARTY", 0x401061f4 },
+{ "BC_INCREFS_DONE", 0x40106308 },
+{ "CHIOGSTATUS", 0x40106308 },
+{ "BC_ACQUIRE_DONE", 0x40106309 },
+{ "DRM_IOCTL_SET_CLIENT_CAP", 0x4010640d },
+{ "DRM_IOCTL_SET_UNIQUE", 0x40106410 },
+{ "DRM_IOCTL_FREE_BUFS", 0x4010641a },
+{ "DRM_IOCTL_SET_SAREA_CTX", 0x4010641c },
+{ "DRM_IOCTL_AGP_BIND", 0x40106436 },
+{ "DRM_IOCTL_AGP_UNBIND", 0x40106437 },
+{ "DRM_IOCTL_SG_FREE", 0x40106439 },
+{ "DRM_IOCTL_OMAP_SET_PARAM", 0x40106441 },
+{ "DRM_IOCTL_QXL_EXECBUFFER", 0x40106442 },
+{ "DRM_IOCTL_OMAP_GEM_CPU_FINI", 0x40106445 },
+{ "DRM_IOCTL_VIA_DEC_FUTEX", 0x40106445 },
+{ "DRM_IOCTL_MGA_INDICES", 0x40106446 },
+{ "DRM_IOCTL_I810_COPY", 0x40106447 },
+{ "DRM_IOCTL_VIA_CMDBUFFER", 0x40106448 },
+{ "DRM_IOCTL_R128_VERTEX", 0x40106449 },
+{ "DRM_IOCTL_RADEON_VERTEX", 0x40106449 },
+{ "DRM_IOCTL_VIA_PCICMD", 0x4010644a },
+{ "DRM_IOCTL_I915_HWS_ADDR", 0x40106451 },
+{ "DRM_IOCTL_I915_GEM_INIT", 0x40106453 },
+{ "DRM_IOCTL_SIS_FB_INIT", 0x40106456 },
+{ "DRM_IOCTL_RADEON_SETPARAM", 0x40106459 },
+{ "TUNER_SET_CONFIG", 0x4010645c },
+{ "FS_IOC_GET_ENCRYPTION_PWSALT", 0x40106614 },
+{ "HSC_SET_TX", 0x40106b15 },
+{ "HSC_GET_TX", 0x40106b16 },
+{ "RIO_ENABLE_PORTWRITE_RANGE", 0x40106d0b },
+{ "RIO_DISABLE_PORTWRITE_RANGE", 0x40106d0c },
+{ "MGSL_IOCSGPIO", 0x40106d10 },
+{ "NILFS_IOCTL_CHANGE_CPMODE", 0x40106e80 },
+{ "NILFS_IOCTL_SET_ALLOC_RANGE", 0x40106e8c },
+{ "VIDEO_STILLPICTURE", 0x40106f1e },
+{ "VIDEO_SET_HIGHLIGHT", 0x40106f27 },
+{ "VIDEO_SET_SPU_PALETTE", 0x40106f33 },
+{ "FE_SET_PROPERTY", 0x40106f52 },
+{ "CA_SET_DESCR", 0x40106f86 },
+{ "PPSETTIME", 0x40107096 },
+{ "IOC_PR_RESERVE", 0x401070c9 },
+{ "IOC_PR_RELEASE", 0x401070ca },
+{ "IOC_PR_CLEAR", 0x401070cd },
+{ "PPPIOCSACTIVE", 0x40107446 },
+{ "PPPIOCSPASS", 0x40107447 },
+{ "PPPIOCSCOMPRESS", 0x4010744d },
+{ "BTRFS_IOC_QGROUP_CREATE", 0x4010942a },
+{ "GENWQE_WRITE_REG64", 0x4010a51f },
+{ "GENWQE_WRITE_REG32", 0x4010a521 },
+{ "GENWQE_WRITE_REG16", 0x4010a523 },
+{ "KVM_GET_DIRTY_LOG", 0x4010ae42 },
+{ "KVM_REGISTER_COALESCED_MMIO", 0x4010ae67 },
+{ "KVM_UNREGISTER_COALESCED_MMIO", 0x4010ae68 },
+{ "KVM_ASSIGN_SET_MSIX_ENTRY", 0x4010ae74 },
+{ "KVM_S390_INTERRUPT", 0x4010ae94 },
+{ "KVM_S390_SET_INITIAL_PSW", 0x4010ae96 },
+{ "KVM_DIRTY_TLB", 0x4010aeaa },
+{ "KVM_ARM_SET_DEVICE_ADDR", 0x4010aeab },
+{ "KVM_GET_ONE_REG", 0x4010aeab },
+{ "KVM_SET_ONE_REG", 0x4010aeac },
+{ "SNDRV_DM_FM_IOCTL_SET_VOICE", 0x40124823 },
+{ "FDSETMAXERRS", 0x4014024c },
+{ "ADD_NEW_DISK", 0x40140921 },
+{ "SNDCTL_COPR_WDATA", 0x40144304 },
+{ "SNDCTL_COPR_WCODE", 0x40144305 },
+{ "OMAPFB_UPDATE_WINDOW_OLD", 0x40144f2f },
+{ "VIDIOC_S_CROP", 0x4014563c },
+{ "CHIOMOVE", 0x40146301 },
+{ "DRM_IOCTL_MGA_CLEAR", 0x40146444 },
+{ "DRM_IOCTL_R128_CLEAR", 0x40146448 },
+{ "DRM_IOCTL_R128_INDICES", 0x4014644a },
+{ "DRM_IOCTL_RADEON_INDICES", 0x4014644a },
+{ "DMX_SET_PES_FILTER", 0x40146f2c },
+{ "FW_CDEV_IOC_SEND_RESPONSE", 0x40182304 },
+{ "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", 0x4018230f },
+{ "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", 0x40182310 },
+{ "SNDRV_PCM_IOCTL_WRITEI_FRAMES", 0x40184150 },
+{ "SNDRV_PCM_IOCTL_WRITEN_FRAMES", 0x40184152 },
+{ "HIDIOCSUSAGE", 0x4018480c },
+{ "HIDIOCGCOLLECTIONINDEX", 0x40184810 },
+{ "AMDKFD_IOC_UPDATE_QUEUE", 0x40184b07 },
+{ "IVTVFB_IOC_DMA_FRAME", 0x401856c0 },
+{ "DRM_IOCTL_UPDATE_DRAW", 0x4018643f },
+{ "DRM_IOCTL_QXL_UPDATE_AREA", 0x40186443 },
+{ "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", 0x40186444 },
+{ "DRM_IOCTL_MSM_GEM_CPU_PREP", 0x40186444 },
+{ "DRM_IOCTL_MSM_WAIT_FENCE", 0x40186447 },
+{ "DRM_IOCTL_R128_BLIT", 0x4018644b },
+{ "RIO_MPORT_MAINT_WRITE_LOCAL", 0x40186d06 },
+{ "RIO_MPORT_MAINT_WRITE_REMOTE", 0x40186d08 },
+{ "NILFS_IOCTL_SET_SUINFO", 0x40186e8d },
+{ "UBI_IOCATT", 0x40186f40 },
+{ "IOC_PR_REGISTER", 0x401870c8 },
+{ "IOC_PR_PREEMPT", 0x401870cb },
+{ "IOC_PR_PREEMPT_ABORT", 0x401870cc },
+{ "BTRFS_IOC_QGROUP_ASSIGN", 0x40189429 },
+{ "KVM_SET_MEMORY_REGION", 0x4018ae40 },
+{ "KVM_S390_UCAS_MAP", 0x4018ae50 },
+{ "KVM_S390_UCAS_UNMAP", 0x4018ae51 },
+{ "KVM_SET_DEVICE_ATTR", 0x4018aee1 },
+{ "KVM_GET_DEVICE_ATTR", 0x4018aee2 },
+{ "KVM_HAS_DEVICE_ATTR", 0x4018aee3 },
+{ "MBXFB_IOCS_ALPHA", 0x4018f402 },
+{ "UI_ABS_SETUP", 0x401c5504 },
+{ "FS_IOC_FSSETXATTR", 0x401c5820 },
+{ "BR2684_SETFILT", 0x401c6190 },
+{ "CHIOEXCHANGE", 0x401c6302 },
+{ "FDSETPRM", 0x40200242 },
+{ "FDDEFPRM", 0x40200243 },
+{ "CS_CONFIG_BUFS", 0x4020431f },
+{ "ION_IOC_TEST_DMA_MAPPING", 0x402049f1 },
+{ "ION_IOC_TEST_KERNEL_MAPPING", 0x402049f2 },
+{ "AMDKFD_IOC_SET_MEMORY_POLICY", 0x40204b04 },
+{ "VIDIOC_SUBSCRIBE_EVENT", 0x4020565a },
+{ "VIDIOC_UNSUBSCRIBE_EVENT", 0x4020565b },
+{ "DRM_IOCTL_MARK_BUFS", 0x40206417 },
+{ "DRM_IOCTL_AGP_FREE", 0x40206435 },
+{ "DRM_IOCTL_VIA_FREEMEM", 0x40206441 },
+{ "DRM_IOCTL_VIRTGPU_EXECBUFFER", 0x40206442 },
+{ "DRM_IOCTL_I915_BATCHBUFFER", 0x40206443 },
+{ "DRM_IOCTL_AMDGPU_INFO", 0x40206445 },
+{ "DRM_IOCTL_SIS_FB_FREE", 0x40206445 },
+{ "DRM_IOCTL_ETNAVIV_WAIT_FENCE", 0x40206447 },
+{ "DRM_IOCTL_RADEON_CLEAR", 0x40206448 },
+{ "DRM_IOCTL_ETNAVIV_GEM_WAIT", 0x40206449 },
+{ "DRM_IOCTL_I915_CMDBUFFER", 0x4020644b },
+{ "DRM_IOCTL_I810_MC", 0x4020644c },
+{ "DRM_IOCTL_RADEON_CMDBUF", 0x40206450 },
+{ "DRM_IOCTL_SIS_AGP_FREE", 0x40206455 },
+{ "DRM_IOCTL_I915_GEM_PREAD", 0x4020645c },
+{ "DRM_IOCTL_I915_GEM_PWRITE", 0x4020645d },
+{ "RIO_DEV_ADD", 0x40206d17 },
+{ "RIO_DEV_DEL", 0x40206d18 },
+{ "OSD_SEND_CMD", 0x40206fa0 },
+{ "RTC_PLL_SET", 0x40207012 },
+{ "PPPIOCSXASYNCMAP", 0x4020744f },
+{ "BTRFS_IOC_CLONE_RANGE", 0x4020940d },
+{ "FICLONERANGE", 0x4020940d },
+{ "KVM_SET_MEMORY_ALIAS", 0x4020ae43 },
+{ "KVM_SET_USER_MEMORY_REGION", 0x4020ae46 },
+{ "KVM_IRQFD", 0x4020ae76 },
+{ "KVM_SIGNAL_MSI", 0x4020aea5 },
+{ "KVM_CREATE_SPAPR_TCE_64", 0x4020aea8 },
+{ "KVM_PPC_GET_HTAB_FD", 0x4020aeaa },
+{ "KVM_ARM_VCPU_INIT", 0x4020aeae },
+{ "KVM_S390_SET_IRQ_STATE", 0x4020aeb5 },
+{ "KVM_S390_GET_IRQ_STATE", 0x4020aeb6 },
+{ "SNDRV_COMPRESS_SET_METADATA", 0x40244314 },
+{ "NVM_DEV_REMOVE", 0x40244c23 },
+{ "NVM_DEV_FACTORY", 0x40244c25 },
+{ "JSIOCSCORR", 0x40246a21 },
+{ "FE_SET_FRONTEND", 0x40246f4c },
+{ "RTC_ALM_SET", 0x40247007 },
+{ "RTC_SET_TIME", 0x4024700a },
+{ "HFI1_IOCTL_CTXT_INFO", 0x40281be2 },
+{ "FW_CDEV_IOC_SEND_REQUEST", 0x40282301 },
+{ "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", 0x40282312 },
+{ "FW_CDEV_IOC_SEND_STREAM_PACKET", 0x40282313 },
+{ "EVIOCSKEYCODE_V2", 0x40284504 },
+{ "SNDCTL_FM_LOAD_INSTR", 0x40285107 },
+{ "DRM_IOCTL_RM_MAP", 0x4028641b },
+{ "DRM_IOCTL_AMDGPU_GEM_VA", 0x40286448 },
+{ "DRM_IOCTL_R128_DEPTH", 0x4028644c },
+{ "DRM_IOCTL_RADEON_VERTEX2", 0x4028644f },
+{ "DRM_IOCTL_I915_GEM_EXECBUFFER", 0x40286454 },
+{ "RIO_UNMAP_OUTBOUND", 0x40286d10 },
+{ "PHN_SETREGS", 0x40287008 },
+{ "RTC_WKALM_SET", 0x4028700f },
+{ "VHOST_SET_VRING_ADDR", 0x4028af11 },
+{ "NVM_DEV_INIT", 0x402c4c24 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", 0x402c5342 },
+{ "TCSETS2", 0x402c542b },
+{ "TCSETSW2", 0x402c542c },
+{ "TCSETSF2", 0x402c542d },
+{ "VIDIOC_S_FREQUENCY", 0x402c5639 },
+{ "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", 0x402c6467 },
+{ "EVIOCSFF", 0x40304580 },
+{ "NVME_IOCTL_SUBMIT_IO", 0x40304e42 },
+{ "VIDIOC_S_FBUF", 0x4030560b },
+{ "VIDIOC_S_HW_FREQ_SEEK", 0x40305652 },
+{ "CHIOSVOLTAG", 0x40306312 },
+{ "DRM_IOCTL_VIA_DMA_BLIT", 0x4030644e },
+{ "MGSL_IOCSPARAMS", 0x40306d00 },
+{ "BTRFS_IOC_DEFRAG_RANGE", 0x40309410 },
+{ "BTRFS_IOC_SET_FEATURES", 0x40309439 },
+{ "KVM_SET_CLOCK", 0x4030ae7b },
+{ "GSMIOC_ENABLE_NET", 0x40344702 },
+{ "SNDRV_TIMER_IOCTL_SELECT", 0x40345410 },
+{ "VIDIOC_S_AUDIO", 0x40345622 },
+{ "VIDIOC_S_AUDOUT", 0x40345632 },
+{ "DRM_IOCTL_MGA_BLIT", 0x40346448 },
+{ "PTP_PEROUT_REQUEST", 0x40383d03 },
+{ "VIDIOC_DBG_S_REGISTER", 0x4038564f },
+{ "DRM_IOCTL_SAVAGE_BCI_CMDBUF", 0x40386441 },
+{ "KVM_XEN_HVM_CONFIG", 0x4038ae7a },
+{ "DMX_SET_FILTER", 0x403c6f2b },
+{ "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", 0x4040534e },
+{ "SNDRV_CTL_IOCTL_ELEM_LOCK", 0x40405514 },
+{ "SNDRV_CTL_IOCTL_ELEM_UNLOCK", 0x40405515 },
+{ "IVTV_IOC_DMA_FRAME", 0x404056c0 },
+{ "BC_TRANSACTION", 0x40406300 },
+{ "BC_REPLY", 0x40406301 },
+{ "DRM_IOCTL_I810_INIT", 0x40406440 },
+{ "DRM_IOCTL_I915_GEM_EXECBUFFER2", 0x40406469 },
+{ "JSIOCSAXMAP", 0x40406a31 },
+{ "BTRFS_IOC_QUOTA_RESCAN", 0x4040942c },
+{ "KVM_ASSIGN_DEV_IRQ", 0x4040ae70 },
+{ "KVM_DEASSIGN_PCI_DEVICE", 0x4040ae72 },
+{ "KVM_DEASSIGN_DEV_IRQ", 0x4040ae75 },
+{ "KVM_CREATE_PIT2", 0x4040ae77 },
+{ "KVM_IOEVENTFD", 0x4040ae79 },
+{ "KVM_X86_SET_MCE", 0x4040ae9e },
+{ "KVM_SET_VCPU_EVENTS", 0x4040aea0 },
+{ "KVM_ASSIGN_SET_INTX_MASK", 0x4040aea4 },
+{ "KVM_S390_MEM_OP", 0x4040aeb1 },
+{ "KVM_S390_GET_SKEYS", 0x4040aeb2 },
+{ "KVM_S390_SET_SKEYS", 0x4040aeb3 },
+{ "CXL_IOCTL_START_WORK", 0x4040ca00 },
+{ "CXL_IOCTL_DOWNLOAD_IMAGE", 0x4040ca0a },
+{ "CXL_IOCTL_VALIDATE_IMAGE", 0x4040ca0b },
+{ "OMAPFB_SETUP_PLANE", 0x40444f34 },
+{ "OMAPFB_QUERY_PLANE", 0x40444f35 },
+{ "OMAPFB_UPDATE_WINDOW", 0x40444f36 },
+{ "VIDIOC_S_MODULATOR", 0x40445637 },
+{ "DRM_IOCTL_I915_INIT", 0x40446440 },
+{ "SET_ARRAY_INFO", 0x40480923 },
+{ "SNDRV_EMU10K1_IOCTL_PCM_POKE", 0x40484830 },
+{ "SNDRV_TIMER_IOCTL_GPARAMS", 0x40485404 },
+{ "BTRFS_IOC_SEND", 0x40489426 },
+{ "KVM_SET_GUEST_DEBUG", 0x4048ae9b },
+{ "KVM_S390_IRQ", 0x4048aeb4 },
+{ "GSMIOC_SETCONF", 0x404c4701 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", 0x404c534a },
+{ "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", 0x40505330 },
+{ "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", 0x40505331 },
+{ "SNDRV_TIMER_IOCTL_PARAMS", 0x40505412 },
+{ "VIDIOC_S_TUNER", 0x4054561e },
+{ "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", 0x4058534c },
+{ "UI_DEV_SETUP", 0x405c5503 },
+{ "PTP_PIN_SETFUNC", 0x40603d07 },
+{ "SNDRV_HWDEP_IOCTL_DSP_LOAD", 0x40604803 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", 0x40605346 },
+{ "DRM_IOCTL_SAVAGE_BCI_INIT", 0x40606440 },
+{ "UI_END_FF_UPLOAD", 0x406855c9 },
+{ "KVM_ENABLE_CAP", 0x4068aea3 },
+{ "CHIOGELEM", 0x406c6310 },
+{ "KVM_SET_PIT2", 0x4070aea0 },
+{ "HFI1_IOCTL_USER_INFO", 0x40781be3 },
+{ "DRM_IOCTL_R128_INIT", 0x40786440 },
+{ "DRM_IOCTL_RADEON_CP_INIT", 0x40786440 },
+{ "NILFS_IOCTL_CLEAN_SEGMENTS", 0x40786e88 },
+{ "FDSETDRVPRM", 0x40800290 },
+{ "NVM_DEV_CREATE", 0x40804c22 },
+{ "UBI_IOCVOLCRBLK", 0x40804f07 },
+{ "DRM_IOCTL_MGA_INIT", 0x40806440 },
+{ "KVM_PPC_GET_PVINFO", 0x4080aea1 },
+{ "KVM_SET_DEBUGREGS", 0x4080aea2 },
+{ "KVM_PPC_RTAS_DEFINE_TOKEN", 0x4080aeac },
+{ "SNDRV_COMPRESS_SET_PARAMS", 0x40844312 },
+{ "V4L2_DEVICE_NOTIFY_EVENT", 0x40887602 },
+{ "SNDRV_SEQ_IOCTL_DELETE_QUEUE", 0x408c5333 },
+{ "VIDIOC_S_JPEGCOMP", 0x408c563e },
+{ "KVM_SET_REGS", 0x4090ae82 },
+{ "UBI_IOCMKVOL", 0x40986f00 },
+{ "SNDRV_SEQ_IOCTL_DELETE_PORT", 0x40a85321 },
+{ "SNDRV_SEQ_IOCTL_SET_PORT_INFO", 0x40a85323 },
+{ "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", 0x40bc5311 },
+{ "VHOST_SCSI_SET_ENDPOINT", 0x40e8af40 },
+{ "VHOST_SCSI_CLEAR_ENDPOINT", 0x40e8af41 },
+{ "ASHMEM_SET_NAME", 0x41007701 },
+{ "BTRFS_IOC_SET_FSLABEL", 0x41009432 },
+{ "USBDEVFS_GETDRIVER", 0x41045508 },
+{ "CA_SEND_MSG", 0x410c6f85 },
+{ "KVM_SET_SREGS", 0x4138ae84 },
+{ "KVM_SET_XCRS", 0x4188aea7 },
+{ "KVM_SET_FPU", 0x41a0ae8d },
+{ "SNDRV_EMU10K1_IOCTL_CODE_POKE", 0x41b04811 },
+{ "PTP_SYS_OFFSET", 0x43403d05 },
+{ "JSIOCSBTNMAP", 0x44006a33 },
+{ "KVM_SET_LAPIC", 0x4400ae8f },
+{ "BTRFS_IOC_SNAP_CREATE", 0x50009401 },
+{ "BTRFS_IOC_DEFRAG", 0x50009402 },
+{ "BTRFS_IOC_RESIZE", 0x50009403 },
+{ "BTRFS_IOC_SCAN_DEV", 0x50009404 },
+{ "BTRFS_IOC_ADD_DEV", 0x5000940a },
+{ "BTRFS_IOC_RM_DEV", 0x5000940b },
+{ "BTRFS_IOC_BALANCE", 0x5000940c },
+{ "BTRFS_IOC_SUBVOL_CREATE", 0x5000940e },
+{ "BTRFS_IOC_SNAP_DESTROY", 0x5000940f },
+{ "BTRFS_IOC_SNAP_CREATE_V2", 0x50009417 },
+{ "BTRFS_IOC_SUBVOL_CREATE_V2", 0x50009418 },
+{ "BTRFS_IOC_RM_DEV_V2", 0x5000943a },
+{ "KVM_SET_XSAVE", 0x5000aea5 },
+{ "HIDIOCSUSAGES", 0x501c4814 },
+{ "UBI_IOCRNVOL", 0x51106f03 },
+{ "SNDRV_SB_CSP_IOCTL_LOAD_CODE", 0x70124811 },
+{ "MFB_GET_ALPHA", 0x80014d00 },
+{ "MFB_GET_GAMMA", 0x80014d01 },
+{ "USBTMC488_IOCTL_GET_CAPS", 0x80015b11 },
+{ "USBTMC488_IOCTL_READ_STB", 0x80015b12 },
+{ "GADGET_GET_PRINTER_STATUS", 0x80016721 },
+{ "JSIOCGAXES", 0x80016a11 },
+{ "JSIOCGBUTTONS", 0x80016a12 },
+{ "SPI_IOC_RD_MODE", 0x80016b01 },
+{ "SPI_IOC_RD_LSB_FIRST", 0x80016b02 },
+{ "SPI_IOC_RD_BITS_PER_WORD", 0x80016b03 },
+{ "PPRSTATUS", 0x80017081 },
+{ "PPRCONTROL", 0x80017083 },
+{ "PPRDATA", 0x80017085 },
+{ "SONYPI_IOCGBRT", 0x80017600 },
+{ "SONYPI_IOCGBATFLAGS", 0x80017607 },
+{ "SONYPI_IOCGBLUE", 0x80017608 },
+{ "SONYPI_IOCGFAN", 0x8001760a },
+{ "SONYPI_IOCGTEMP", 0x8001760c },
+{ "CAPI_GET_ERRCODE", 0x80024321 },
+{ "CAPI_INSTALLED", 0x80024322 },
+{ "SNDRV_DM_FM_IOCTL_INFO", 0x80024820 },
+{ "IOCTL_WDM_MAX_COMMAND", 0x800248a0 },
+{ "IPMICTL_REGISTER_FOR_CMD", 0x8002690e },
+{ "IPMICTL_UNREGISTER_FOR_CMD", 0x8002690f },
+{ "FE_READ_SIGNAL_STRENGTH", 0x80026f47 },
+{ "FE_READ_SNR", 0x80026f48 },
+{ "SONYPI_IOCGBAT1CAP", 0x80027602 },
+{ "SONYPI_IOCGBAT1REM", 0x80027603 },
+{ "SONYPI_IOCGBAT2CAP", 0x80027604 },
+{ "SONYPI_IOCGBAT2REM", 0x80027605 },
+{ "MBXFB_IOCS_PLANEORDER", 0x8002f403 },
+{ "HFI1_IOCTL_GET_VERS", 0x80041bee },
+{ "SNDRV_PCM_IOCTL_PVERSION", 0x80044100 },
+{ "CCISS_GETHEARTBEAT", 0x80044206 },
+{ "CCISS_GETBUSTYPES", 0x80044207 },
+{ "CCISS_GETFIRMVER", 0x80044208 },
+{ "CCISS_GETDRIVVER", 0x80044209 },
+{ "SNDRV_COMPRESS_IOCTL_VERSION", 0x80044300 },
+{ "CS_GET_STATE", 0x80044315 },
+{ "CS_GET_IF_VERSION", 0x8004431e },
+{ "CAPI_GET_FLAGS", 0x80044323 },
+{ "CAPI_SET_FLAGS", 0x80044324 },
+{ "CAPI_CLR_FLAGS", 0x80044325 },
+{ "CAPI_NCCI_OPENCOUNT", 0x80044326 },
+{ "CAPI_NCCI_GETUNIT", 0x80044327 },
+{ "EVIOCGVERSION", 0x80044501 },
+{ "APEI_ERST_GET_RECORD_COUNT", 0x80044502 },
+{ "EVIOCGEFFECTS", 0x80044584 },
+{ "FBIOGET_CONTRAST", 0x80044601 },
+{ "FBIGET_BRIGHTNESS", 0x80044603 },
+{ "FBIGET_COLOR", 0x80044605 },
+{ "SSTFB_GET_VGAPASS", 0x800446dd },
+{ "SNDRV_HWDEP_IOCTL_PVERSION", 0x80044800 },
+{ "HIDIOCGRDESCSIZE", 0x80044801 },
+{ "HIDIOCGVERSION", 0x80044801 },
+{ "IOCTL_MEI_NOTIFY_GET", 0x80044803 },
+{ "HIDIOCGFLAG", 0x8004480e },
+{ "HDA_IOCTL_PVERSION", 0x80044810 },
+{ "SNDRV_EMU10K1_IOCTL_PVERSION", 0x80044840 },
+{ "SNDRV_EMUX_IOCTL_VERSION", 0x80044880 },
+{ "SNDRV_EMU10K1_IOCTL_DBG_READ", 0x80044884 },
+{ "HCIGETDEVLIST", 0x800448d2 },
+{ "HCIGETDEVINFO", 0x800448d3 },
+{ "HCIGETCONNLIST", 0x800448d4 },
+{ "HCIGETCONNINFO", 0x800448d5 },
+{ "HCIGETAUTHINFO", 0x800448d7 },
+{ "HCIINQUIRY", 0x800448f0 },
+{ "ROCCATIOCGREPSIZE", 0x800448f1 },
+{ "IMADDTIMER", 0x80044940 },
+{ "IMDELTIMER", 0x80044941 },
+{ "IMGETVERSION", 0x80044942 },
+{ "IMGETCOUNT", 0x80044943 },
+{ "IMGETDEVINFO", 0x80044944 },
+{ "IMCTRLREQ", 0x80044945 },
+{ "IMCLEAR_L2", 0x80044946 },
+{ "IMHOLD_L1", 0x80044948 },
+{ "MCE_GET_RECORD_LEN", 0x80044d01 },
+{ "MCE_GET_LOG_LEN", 0x80044d02 },
+{ "MCE_GETCLEAR_FLAGS", 0x80044d03 },
+{ "MEMGETREGIONCOUNT", 0x80044d07 },
+{ "MFB_GET_PIXFMT", 0x80044d08 },
+{ "OTPSELECT", 0x80044d0d },
+{ "OSS_GETVERSION", 0x80044d76 },
+{ "UBI_IOCEBISMAP", 0x80044f05 },
+{ "SOUND_PCM_READ_RATE", 0x80045002 },
+{ "SOUND_PCM_READ_BITS", 0x80045005 },
+{ "SOUND_PCM_READ_CHANNELS", 0x80045006 },
+{ "SOUND_PCM_READ_FILTER", 0x80045007 },
+{ "SNDCTL_DSP_GETFMTS", 0x8004500b },
+{ "SNDCTL_DSP_GETCAPS", 0x8004500f },
+{ "SNDCTL_DSP_GETTRIGGER", 0x80045010 },
+{ "SNDCTL_DSP_GETODELAY", 0x80045017 },
+{ "SNDCTL_DSP_GETSPDIF", 0x80045043 },
+{ "SNDCTL_SEQ_GETOUTCOUNT", 0x80045104 },
+{ "SNDCTL_SEQ_GETINCOUNT", 0x80045105 },
+{ "SNDCTL_SEQ_NRSYNTHS", 0x8004510a },
+{ "SNDCTL_SEQ_NRMIDIS", 0x8004510b },
+{ "SNDCTL_SEQ_GETTIME", 0x80045113 },
+{ "RNDGETENTCNT", 0x80045200 },
+{ "SAA6588_CMD_READ", 0x80045203 },
+{ "SAA6588_CMD_POLL", 0x80045204 },
+{ "RFCOMMGETDEVLIST", 0x800452d2 },
+{ "RFCOMMGETDEVINFO", 0x800452d3 },
+{ "SNDRV_SEQ_IOCTL_PVERSION", 0x80045300 },
+{ "SNDRV_SEQ_IOCTL_CLIENT_ID", 0x80045301 },
+{ "SNDRV_TIMER_IOCTL_PVERSION", 0x80045400 },
+{ "TIOCGPTN", 0x80045430 },
+{ "TIOCGDEV", 0x80045432 },
+{ "TIOCGPKT", 0x80045438 },
+{ "TIOCGPTLCK", 0x80045439 },
+{ "TIOCGEXCL", 0x80045440 },
+{ "TUNGETFEATURES", 0x800454cf },
+{ "TUNGETIFF", 0x800454d2 },
+{ "TUNGETSNDBUF", 0x800454d3 },
+{ "TUNGETVNETHDRSZ", 0x800454d7 },
+{ "TUNGETVNETLE", 0x800454dd },
+{ "TUNGETVNETBE", 0x800454df },
+{ "SNDRV_CTL_IOCTL_PVERSION", 0x80045500 },
+{ "USBDEVFS_RESETEP", 0x80045503 },
+{ "USBDEVFS_SETCONFIGURATION", 0x80045505 },
+{ "USBDEVFS_CLAIMINTERFACE", 0x8004550f },
+{ "USBDEVFS_RELEASEINTERFACE", 0x80045510 },
+{ "USBDEVFS_CLEAR_HALT", 0x80045515 },
+{ "USBDEVFS_CLAIM_PORT", 0x80045518 },
+{ "USBDEVFS_RELEASE_PORT", 0x80045519 },
+{ "USBDEVFS_GET_CAPABILITIES", 0x8004551a },
+{ "UI_GET_VERSION", 0x8004552d },
+{ "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", 0x80045530 },
+{ "SNDRV_CTL_IOCTL_POWER_STATE", 0x800455d1 },
+{ "VIDIOC_G_INPUT", 0x80045626 },
+{ "VIDIOC_G_OUTPUT", 0x8004562e },
+{ "VIDIOC_G_PRIORITY", 0x80045643 },
+{ "SNDRV_RAWMIDI_IOCTL_PVERSION", 0x80045700 },
+{ "WDIOC_GETSTATUS", 0x80045701 },
+{ "WDIOC_GETBOOTSTATUS", 0x80045702 },
+{ "WDIOC_GETTEMP", 0x80045703 },
+{ "WDIOC_SETOPTIONS", 0x80045704 },
+{ "WDIOC_KEEPALIVE", 0x80045705 },
+{ "WDIOC_GETTIMEOUT", 0x80045707 },
+{ "WDIOC_GETPRETIMEOUT", 0x80045709 },
+{ "WDIOC_GETTIMELEFT", 0x8004570a },
+{ "SONET_GETDIAG", 0x80046114 },
+{ "SONET_GETFRAMING", 0x80046116 },
+{ "CHIOGPICKER", 0x80046304 },
+{ "DRM_IOCTL_GET_MAGIC", 0x80046402 },
+{ "DRM_IOCTL_I915_GET_VBLANK_PIPE", 0x8004644e },
+{ "FS_IOC32_GETFLAGS", 0x80046601 },
+{ "LIRC_GET_FEATURES", 0x80046900 },
+{ "LIRC_GET_SEND_MODE", 0x80046901 },
+{ "LIRC_GET_REC_MODE", 0x80046902 },
+{ "LIRC_GET_SEND_CARRIER", 0x80046903 },
+{ "LIRC_GET_REC_CARRIER", 0x80046904 },
+{ "LIRC_GET_SEND_DUTY_CYCLE", 0x80046905 },
+{ "LIRC_GET_REC_DUTY_CYCLE", 0x80046906 },
+{ "LIRC_GET_REC_RESOLUTION", 0x80046907 },
+{ "I2OVALIDATE", 0x80046908 },
+{ "LIRC_GET_MIN_TIMEOUT", 0x80046908 },
+{ "LIRC_GET_MAX_TIMEOUT", 0x80046909 },
+{ "LIRC_GET_MIN_FILTER_PULSE", 0x8004690a },
+{ "LIRC_GET_MAX_FILTER_PULSE", 0x8004690b },
+{ "LIRC_GET_MIN_FILTER_SPACE", 0x8004690c },
+{ "LIRC_GET_MAX_FILTER_SPACE", 0x8004690d },
+{ "LIRC_GET_LENGTH", 0x8004690f },
+{ "IPMICTL_SET_GETS_EVENTS_CMD", 0x80046910 },
+{ "IPMICTL_SET_MY_ADDRESS_CMD", 0x80046911 },
+{ "IPMICTL_GET_MY_ADDRESS_CMD", 0x80046912 },
+{ "IPMICTL_SET_MY_LUN_CMD", 0x80046913 },
+{ "IPMICTL_GET_MY_LUN_CMD", 0x80046914 },
+{ "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", 0x80046918 },
+{ "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", 0x80046919 },
+{ "IPMICTL_SET_MY_CHANNEL_LUN_CMD", 0x8004691a },
+{ "IPMICTL_GET_MY_CHANNEL_LUN_CMD", 0x8004691b },
+{ "IPMICTL_GET_MAINTENANCE_MODE_CMD", 0x8004691e },
+{ "I8K_BIOS_VERSION", 0x80046980 },
+{ "I8K_MACHINE_ID", 0x80046981 },
+{ "IIO_GET_EVENT_FD_IOCTL", 0x80046990 },
+{ "JSIOCGVERSION", 0x80046a01 },
+{ "SPI_IOC_RD_MAX_SPEED_HZ", 0x80046b04 },
+{ "SPI_IOC_RD_MODE32", 0x80046b05 },
+{ "UDF_GETEASIZE", 0x80046c40 },
+{ "RIO_MPORT_MAINT_PORT_IDX_GET", 0x80046d03 },
+{ "RIO_GET_EVENT_MASK", 0x80046d0e },
+{ "NCP_IOC_SIGN_WANTED", 0x80046e06 },
+{ "NCP_IOC_SETDENTRYTTL", 0x80046e0c },
+{ "SISFB_GET_INFO_OLD", 0x80046ef8 },
+{ "SISFB_GET_VBRSTATUS_OLD", 0x80046ef9 },
+{ "SISFB_GET_AUTOMAXIMIZE_OLD", 0x80046efa },
+{ "AUDIO_GET_CAPABILITIES", 0x80046f0b },
+{ "VIDEO_GET_CAPABILITIES", 0x80046f21 },
+{ "VIDEO_GET_FRAME_RATE", 0x80046f38 },
+{ "FE_READ_STATUS", 0x80046f45 },
+{ "FE_READ_BER", 0x80046f46 },
+{ "FE_READ_UNCORRECTED_BLOCKS", 0x80046f49 },
+{ "RTC_VL_READ", 0x80047013 },
+{ "PPCLRIRQ", 0x80047093 },
+{ "PPGETMODES", 0x80047097 },
+{ "PPGETMODE", 0x80047098 },
+{ "PPGETPHASE", 0x80047099 },
+{ "PPGETFLAGS", 0x8004709a },
+{ "PHONE_DTMF_READY", 0x80047196 },
+{ "PHONE_GET_DTMF", 0x80047197 },
+{ "PHONE_GET_DTMF_ASCII", 0x80047198 },
+{ "PHONE_EXCEPTION", 0x8004719a },
+{ "IXJCTL_CARDTYPE", 0x800471c1 },
+{ "IXJCTL_SERIAL", 0x800471c2 },
+{ "IXJCTL_DSP_TYPE", 0x800471c3 },
+{ "IXJCTL_DSP_VERSION", 0x800471c4 },
+{ "IXJCTL_VMWI", 0x800471d8 },
+{ "BR_ERROR", 0x80047200 },
+{ "BR_ACQUIRE_RESULT", 0x80047204 },
+{ "FAT_IOCTL_GET_ATTRIBUTES", 0x80047210 },
+{ "FAT_IOCTL_GET_VOLUME_ID", 0x80047213 },
+{ "PPPIOCGCHAN", 0x80047437 },
+{ "PPPIOCGDEBUG", 0x80047441 },
+{ "PPPIOCGMRU", 0x80047453 },
+{ "PPPIOCGRASYNCMAP", 0x80047455 },
+{ "PPPIOCGUNIT", 0x80047456 },
+{ "PPPIOCGASYNCMAP", 0x80047458 },
+{ "PPPIOCGFLAGS", 0x8004745a },
+{ "PPPIOCGMPFLAGS", 0x80047482 },
+{ "FS_IOC32_GETVERSION", 0x80047601 },
+{ "MEYEIOC_STILLJCAPT", 0x800476c5 },
+{ "OSIOCGNETADDR", 0x800489e1 },
+{ "SIOCGNETADDR", 0x800489e1 },
+{ "AUTOFS_IOC_PROTOVER", 0x80049363 },
+{ "AUTOFS_IOC_PROTOSUBVER", 0x80049367 },
+{ "AUTOFS_IOC_ASKUMOUNT", 0x80049370 },
+{ "GENWQE_GET_CARD_STATE", 0x8004a524 },
+{ "KVM_GET_MP_STATE", 0x8004ae98 },
+{ "CXL_IOCTL_GET_PROCESS_ELEMENT", 0x8004ca01 },
+{ "FUSE_DEV_IOC_CLONE", 0x8004e500 },
+{ "SISFB_GET_INFO_SIZE", 0x8004f300 },
+{ "SISFB_GET_VBRSTATUS", 0x8004f302 },
+{ "SISFB_GET_AUTOMAXIMIZE", 0x8004f303 },
+{ "SISFB_GET_TVPOSOFFSET", 0x8004f304 },
+{ "SONET_GETFRSENSE", 0x80066117 },
+{ "MEYEIOC_G_PARAMS", 0x800676c0 },
+{ "BLKBSZGET", 0x80081270 },
+{ "BLKGETSIZE64", 0x80081272 },
+{ "PERF_EVENT_IOC_ID", 0x80082407 },
+{ "SNAPSHOT_GET_IMAGE_SIZE", 0x8008330e },
+{ "SNAPSHOT_AVAIL_SWAP_SIZE", 0x80083313 },
+{ "SNAPSHOT_ALLOC_SWAP_PAGE", 0x80083314 },
+{ "FBIO_RADEON_GET_MIRROR", 0x80084003 },
+{ "AGPIOC_INFO", 0x80084100 },
+{ "SNDRV_PCM_IOCTL_DELAY", 0x80084121 },
+{ "CCISS_GETPCIINFO", 0x80084201 },
+{ "PMU_IOC_GET_BACKLIGHT", 0x80084201 },
+{ "CCISS_GETINTINFO", 0x80084202 },
+{ "PMU_IOC_GET_MODEL", 0x80084203 },
+{ "PMU_IOC_HAS_ADB", 0x80084204 },
+{ "PMU_IOC_CAN_SLEEP", 0x80084205 },
+{ "PMU_IOC_GRAB_BACKLIGHT", 0x80084206 },
+{ "EVIOCGID", 0x80084502 },
+{ "EVIOCGREP", 0x80084503 },
+{ "EVIOCGKEYCODE", 0x80084504 },
+{ "FBIO_GETCONTROL2", 0x80084689 },
+{ "HIDIOCGRAWINFO", 0x80084803 },
+{ "SNDRV_HDSP_IOCTL_GET_VERSION", 0x80084843 },
+{ "SNDRV_HDSPM_IOCTL_GET_MIXER", 0x80084844 },
+{ "SNDRV_HDSP_IOCTL_GET_9632_AEB", 0x80084845 },
+{ "AMDKFD_IOC_GET_VERSION", 0x80084b01 },
+{ "MFB_GET_AOID", 0x80084d04 },
+{ "MEMISLOCKED", 0x80084d17 },
+{ "RNDGETPOOL", 0x80085202 },
+{ "USBDEVFS_SETINTERFACE", 0x80085504 },
+{ "USBDEVFS_DISCSIGNAL32", 0x8008550e },
+{ "USBDEVFS_ALLOC_STREAMS", 0x8008551c },
+{ "USBDEVFS_FREE_STREAMS", 0x8008551d },
+{ "VIDIOC_G_STD", 0x80085617 },
+{ "VIDIOC_QUERYSTD", 0x8008563f },
+{ "CM_IOCGSTATUS", 0x80086300 },
+{ "KCOV_INIT_TRACE", 0x80086301 },
+{ "DRM_IOCTL_I810_OV0INFO", 0x80086449 },
+{ "FS_IOC_GETFLAGS", 0x80086601 },
+{ "I2OPASSTHRU32", 0x8008690c },
+{ "IPMICTL_SET_TIMING_PARMS_CMD", 0x80086916 },
+{ "IPMICTL_GET_TIMING_PARMS_CMD", 0x80086917 },
+{ "I8K_POWER_STATUS", 0x80086982 },
+{ "I8K_FN_STATUS", 0x80086983 },
+{ "I8K_GET_TEMP", 0x80086984 },
+{ "UDF_GETEABLOCK", 0x80086c41 },
+{ "UDF_GETVOLIDENT", 0x80086c42 },
+{ "MMTIMER_GETRES", 0x80086d01 },
+{ "MMTIMER_GETFREQ", 0x80086d02 },
+{ "MTIOCPOS", 0x80086d03 },
+{ "MMTIMER_GETCOUNTER", 0x80086d09 },
+{ "NILFS_IOCTL_SYNC", 0x80086e8a },
+{ "MATROXFB_GET_OUTPUT_CONNECTION", 0x80086ef8 },
+{ "MATROXFB_GET_AVAILABLE_OUTPUTS", 0x80086ef9 },
+{ "MATROXFB_GET_ALL_OUTPUTS", 0x80086efb },
+{ "AUDIO_GET_PTS", 0x80086f13 },
+{ "DMX_GET_CAPS", 0x80086f30 },
+{ "VIDEO_GET_PTS", 0x80086f39 },
+{ "VIDEO_GET_FRAME_COUNT", 0x80086f3a },
+{ "CA_GET_DESCR_INFO", 0x80086f83 },
+{ "RTC_IRQP_READ", 0x8008700b },
+{ "RTC_EPOCH_READ", 0x8008700d },
+{ "PPS_GETPARAMS", 0x800870a1 },
+{ "PPS_GETCAP", 0x800870a3 },
+{ "PHONE_CAPABILITIES_LIST", 0x80087181 },
+{ "IXJCTL_CID", 0x800871d4 },
+{ "IXJCTL_VERSION", 0x800871da },
+{ "IXJCTL_FRAMES_READ", 0x800871e2 },
+{ "IXJCTL_FRAMES_WRITTEN", 0x800871e3 },
+{ "IXJCTL_READ_WAIT", 0x800871e4 },
+{ "IXJCTL_WRITE_WAIT", 0x800871e5 },
+{ "IXJCTL_DRYBUFFER_READ", 0x800871e6 },
+{ "BR_DEAD_BINDER", 0x8008720f },
+{ "BR_CLEAR_DEATH_NOTIFICATION_DONE", 0x80087210 },
+{ "FS_IOC_GETVERSION", 0x80087601 },
+{ "BTRFS_IOC_START_SYNC", 0x80089418 },
+{ "BTRFS_IOC_SUBVOL_GETFLAGS", 0x80089419 },
+{ "KVM_X86_GET_MCE_CAP_SUPPORTED", 0x8008ae9d },
+{ "KVM_ALLOCATE_RMA", 0x8008aea9 },
+{ "VHOST_GET_FEATURES", 0x8008af00 },
+{ "FUNCTIONFS_ENDPOINT_DESC", 0x80096782 },
+{ "DMX_GET_PES_PIDS", 0x800a6f2f },
+{ "RAID_VERSION", 0x800c0910 },
+{ "CCISS_GETLUNINFO", 0x800c4211 },
+{ "OTPLOCK", 0x800c4d10 },
+{ "OMAPFB_GET_CAPS", 0x800c4f2a },
+{ "SNDCTL_DSP_GETIPTR", 0x800c5011 },
+{ "SNDCTL_DSP_GETOPTR", 0x800c5012 },
+{ "FS_IOC_SET_ENCRYPTION_POLICY", 0x800c6613 },
+{ "IPMICTL_REGISTER_FOR_CMD_CHANS", 0x800c691c },
+{ "IPMICTL_UNREGISTER_FOR_CMD_CHANS", 0x800c691d },
+{ "NCP_IOC_SETROOT", 0x800c6e08 },
+{ "VIDEO_GET_SIZE", 0x800c6f37 },
+{ "FE_DISEQC_RECV_SLAVE_REPLY", 0x800c6f40 },
+{ "CA_GET_SLOT_INFO", 0x800c6f82 },
+{ "FDGETDRVTYP", 0x8010020f },
+{ "FW_CDEV_IOC_GET_CYCLE_TIMER", 0x8010230c },
+{ "STP_POLICY_ID_GET", 0x80102501 },
+{ "CCISS_GETNODENAME", 0x80104204 },
+{ "EVIOCGMASK", 0x80104592 },
+{ "SNDRV_HDSPM_IOCTL_GET_LTC", 0x80104846 },
+{ "ECCGETSTATS", 0x80104d12 },
+{ "SNDCTL_DSP_GETOSPACE", 0x8010500c },
+{ "SNDCTL_DSP_GETISPACE", 0x8010500d },
+{ "SNDCTL_DSP_MAPINBUF", 0x80105013 },
+{ "SNDCTL_DSP_MAPOUTBUF", 0x80105014 },
+{ "TUNGETFILTER", 0x801054db },
+{ "USBDEVFS_DISCSIGNAL", 0x8010550e },
+{ "DRM_IOCTL_I915_GEM_GET_APERTURE", 0x80106463 },
+{ "I2OPASSTHRU", 0x8010690c },
+{ "MGSL_IOCGGPIO", 0x80106d11 },
+{ "NCP_IOC_NCPREQUEST", 0x80106e01 },
+{ "NCP_IOC_SETPRIVATEDATA", 0x80106e0a },
+{ "FE_GET_PROPERTY", 0x80106f53 },
+{ "CA_GET_CAP", 0x80106f81 },
+{ "OSD_GET_CAPABILITY", 0x80106fa1 },
+{ "PPGETTIME", 0x80107095 },
+{ "BR_INCREFS", 0x80107207 },
+{ "BR_ACQUIRE", 0x80107208 },
+{ "BR_RELEASE", 0x80107209 },
+{ "BR_DECREFS", 0x8010720a },
+{ "PPPIOCGIDLE", 0x8010743f },
+{ "PPPIOCGIFNAME", 0x80107488 },
+{ "GENWQE_READ_REG64", 0x8010a51e },
+{ "GENWQE_READ_REG32", 0x8010a520 },
+{ "GENWQE_READ_REG16", 0x8010a522 },
+{ "UFFDIO_UNREGISTER", 0x8010aa01 },
+{ "UFFDIO_WAKE", 0x8010aa02 },
+{ "FDGETMAXERRS", 0x8014020e },
+{ "GET_DISK_INFO", 0x80140912 },
+{ "SNDRV_COMPRESS_TSTAMP", 0x80144320 },
+{ "CHIOGPARAMS", 0x80146306 },
+{ "NCP_IOC_LOCKUNLOCK", 0x80146e07 },
+{ "VIDEO_GET_STATUS", 0x80146f1b },
+{ "SNDRV_PCM_IOCTL_CHANNEL_INFO", 0x80184132 },
+{ "SNDRV_PCM_IOCTL_READI_FRAMES", 0x80184151 },
+{ "SNDRV_PCM_IOCTL_READN_FRAMES", 0x80184153 },
+{ "SNDRV_HDSPM_IOCTL_GET_CONFIG", 0x80184841 },
+{ "IMSETDEVNAME", 0x80184947 },
+{ "OMAPFB_MEMORY_READ", 0x80184f3a },
+{ "HPET_INFO", 0x80186803 },
+{ "RIO_MPORT_MAINT_READ_LOCAL", 0x80186d05 },
+{ "RIO_MPORT_MAINT_READ_REMOTE", 0x80186d07 },
+{ "NCP_IOC_SIGN_INIT", 0x80186e05 },
+{ "NCP_IOC_SETOBJECTNAME", 0x80186e09 },
+{ "NILFS_IOCTL_GET_CPINFO", 0x80186e82 },
+{ "NILFS_IOCTL_GET_CPSTAT", 0x80186e83 },
+{ "NILFS_IOCTL_GET_SUINFO", 0x80186e84 },
+{ "BR_ATTEMPT_ACQUIRE", 0x8018720b },
+{ "BTRFS_IOC_GET_FEATURES", 0x80189439 },
+{ "MBXFB_IOCG_ALPHA", 0x8018f401 },
+{ "SNDRV_COMPRESS_AVAIL", 0x801c4321 },
+{ "HIDIOCGDEVINFO", 0x801c4803 },
+{ "FS_IOC_FSGETXATTR", 0x801c581f },
+{ "FDGETPRM", 0x80200204 },
+{ "FBIOGET_VBLANK", 0x80204612 },
+{ "SNDRV_HDSPM_IOCTL_GET_STATUS", 0x80204847 },
+{ "SNDRV_FIREWIRE_IOCTL_GET_INFO", 0x802048f8 },
+{ "MEMGETINFO", 0x80204d01 },
+{ "OMAPFB_GET_VRAM_INFO", 0x80204f3d },
+{ "OMAPFB_GET_DISPLAY_INFO", 0x80204f3f },
+{ "I2OGETIOPS", 0x80206900 },
+{ "AUDIO_GET_STATUS", 0x80206f0a },
+{ "VIDEO_GET_EVENT", 0x80206f1c },
+{ "RTC_PLL_GET", 0x80207011 },
+{ "PPPIOCGXASYNCMAP", 0x80207450 },
+{ "KVM_ARM_PREFERRED_TARGET", 0x8020aeaf },
+{ "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", 0x80244841 },
+{ "SNDRV_HDSPM_IOCTL_GET_VERSION", 0x80244848 },
+{ "SONET_GETSTAT", 0x80246110 },
+{ "SONET_GETSTATZ", 0x80246111 },
+{ "JSIOCGCORR", 0x80246a22 },
+{ "FE_GET_FRONTEND", 0x80246f4d },
+{ "RTC_ALM_READ", 0x80247008 },
+{ "RTC_RD_TIME", 0x80247009 },
+{ "FDGETFDCSTAT", 0x80280215 },
+{ "FDWERRORGET", 0x80280217 },
+{ "EVIOCGKEYCODE_V2", 0x80284504 },
+{ "SNDRV_SB_CSP_IOCTL_INFO", 0x80284810 },
+{ "WDIOC_GETSUPPORT", 0x80285700 },
+{ "IPMICTL_SEND_COMMAND", 0x8028690d },
+{ "FE_GET_EVENT", 0x80286f4e },
+{ "RTC_WKALM_RD", 0x80287010 },
+{ "IOW_GETINFO", 0x8028c003 },
+{ "USBDEVFS_SUBMITURB32", 0x802a550a },
+{ "NCP_IOC_SETCHARSETS", 0x802a6e0b },
+{ "TCGETS2", 0x802c542a },
+{ "SOUND_OLD_MIXER_INFO", 0x80304d65 },
+{ "VIDIOC_G_FBUF", 0x8030560a },
+{ "IPMICTL_SEND_COMMAND_SETTIME", 0x80306915 },
+{ "MGSL_IOCGPARAMS", 0x80306d01 },
+{ "MTIOCGET", 0x80306d02 },
+{ "RIO_MPORT_GET_PROPERTIES", 0x80306d04 },
+{ "NILFS_IOCTL_GET_SUSTAT", 0x80306e85 },
+{ "BTRFS_IOC_QGROUP_LIMIT", 0x8030942b },
+{ "KVM_GET_CLOCK", 0x8030ae7c },
+{ "VIDIOC_G_AUDIO", 0x80345621 },
+{ "VIDIOC_G_AUDOUT", 0x80345631 },
+{ "USBDEVFS_SUBMITURB", 0x8038550a },
+{ "DRM_IOCTL_AGP_INFO", 0x80386433 },
+{ "OMAPFB_GET_OVERLAY_COLORMODE", 0x803c4f3b },
+{ "SNDRV_HWDEP_IOCTL_DSP_STATUS", 0x80404802 },
+{ "JSIOCGAXMAP", 0x80406a32 },
+{ "BR_TRANSACTION", 0x80407202 },
+{ "BR_REPLY", 0x80407203 },
+{ "PPPIOCGCOMPRESSORS", 0x80407486 },
+{ "BTRFS_IOC_QUOTA_RESCAN_STATUS", 0x8040942d },
+{ "KVM_ASSIGN_PCI_DEVICE", 0x8040ae69 },
+{ "KVM_GET_VCPU_EVENTS", 0x8040ae9f },
+{ "CXL_IOCTL_GET_AFU_ID", 0x8040ca02 },
+{ "GPIO_GET_CHIPINFO_IOCTL", 0x8044b401 },
+{ "GET_ARRAY_INFO", 0x80480911 },
+{ "PPPIOCGL2TPSTATS", 0x80487436 },
+{ "BTRFS_IOC_GET_SUPPORTED_FEATURES", 0x80489439 },
+{ "KVM_SET_PIT", 0x8048ae66 },
+{ "GSMIOC_GETCONF", 0x804c4700 },
+{ "FDGETDRVSTAT", 0x80500212 },
+{ "FDPOLLDRVSTAT", 0x80500213 },
+{ "PTP_CLOCK_GETCAPS", 0x80503d01 },
+{ "SOUND_MIXER_INFO", 0x805c4d65 },
+{ "SNDRV_TIMER_IOCTL_STATUS", 0x80605414 },
+{ "VIDIOC_QUERYCAP", 0x80685600 },
+{ "I2OEVTGET", 0x8068690b },
+{ "CHIOGVPARAMS", 0x80706313 },
+{ "KVM_GET_PIT2", 0x8070ae9f },
+{ "SNDRV_COMPRESS_GET_PARAMS", 0x80784313 },
+{ "FDGETDRVPRM", 0x80800211 },
+{ "USBDEVFS_HUB_PORTINFO", 0x80805513 },
+{ "KVM_GET_DEBUGREGS", 0x8080aea1 },
+{ "VIDIOC_QUERY_DV_TIMINGS", 0x80845663 },
+{ "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", 0x80845663 },
+{ "VIDIOC_DQEVENT", 0x80885659 },
+{ "VIDIOC_G_JPEGCOMP", 0x808c563d },
+{ "KVM_GET_REGS", 0x8090ae81 },
+{ "SNDRV_PCM_IOCTL_STATUS", 0x80984120 },
+{ "FE_GET_INFO", 0x80a86f3d },
+{ "MEMGETOOBSEL", 0x80c84d0a },
+{ "SNDRV_HWDEP_IOCTL_INFO", 0x80dc4801 },
+{ "SNDRV_CTL_IOCTL_HWDEP_INFO", 0x80dc5521 },
+{ "SNDRV_TIMER_IOCTL_INFO", 0x80e85411 },
+{ "DRM_IOCTL_GET_STATS", 0x80f86406 },
+{ "ASHMEM_GET_NAME", 0x81007702 },
+{ "BTRFS_IOC_GET_FSLABEL", 0x81009431 },
+{ "HIDIOCGSTRING", 0x81044804 },
+{ "USBDEVFS_DISCONNECT_CLAIM", 0x8108551b },
+{ "SNDRV_RAWMIDI_IOCTL_INFO", 0x810c5701 },
+{ "CA_GET_MSG", 0x810c6f84 },
+{ "AUTOFS_IOC_EXPIRE", 0x810c9365 },
+{ "SISFB_GET_INFO", 0x811cf301 },
+{ "SNDRV_PCM_IOCTL_INFO", 0x81204101 },
+{ "KVM_GET_SREGS", 0x8138ae83 },
+{ "ECCGETLAYOUT", 0x81484d11 },
+{ "SNDRV_CTL_IOCTL_CARD_INFO", 0x81785501 },
+{ "KVM_GET_XCRS", 0x8188aea6 },
+{ "AMDKFD_IOC_GET_PROCESS_APERTURES", 0x81904b06 },
+{ "KVM_GET_FPU", 0x81a0ae8c },
+{ "KVM_SET_IRQCHIP", 0x8208ae63 },
+{ "VFAT_IOCTL_READDIR_BOTH", 0x82307201 },
+{ "VFAT_IOCTL_READDIR_SHORT", 0x82307202 },
+{ "KVM_PPC_GET_SMMU_INFO", 0x8250aea6 },
+{ "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", 0x83b04840 },
+{ "JSIOCGBTNMAP", 0x84006a34 },
+{ "BTRFS_IOC_FS_INFO", 0x8400941f },
+{ "BTRFS_IOC_BALANCE_PROGRESS", 0x84009422 },
+{ "KVM_GET_LAPIC", 0x8400ae8e },
+{ "VIDEO_GET_NAVI", 0x84046f34 },
+{ "SNDRV_EMU10K1_IOCTL_INFO", 0x880c4810 },
+{ "VIDIOC_G_ENC_INDEX", 0x8818564c },
+{ "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", 0x89084842 },
+{ "SNDCTL_COPR_RCVMSG", 0x8fa44309 },
+{ "GET_BITMAP_FILE", 0x90000915 },
+{ "SNDRV_HDSP_IOCTL_GET_MIXER", 0x90004844 },
+{ "NVM_GET_DEVICES", 0x90004c21 },
+{ "BTRFS_IOC_DEVICES_READY", 0x90009427 },
+{ "KVM_GET_XSAVE", 0x9000aea4 },
+{ "HIDIOCGRDESC", 0x90044802 },
+{ "GADGET_SET_PRINTER_STATUS", 0xc0016722 },
+{ "CAPI_GET_MANUFACTURER", 0xc0044306 },
+{ "CAPI_GET_SERIAL", 0xc0044308 },
+{ "GIGASET_REDIR", 0xc0044700 },
+{ "GIGASET_CONFIG", 0xc0044701 },
+{ "ION_IOC_FREE", 0xc0044901 },
+{ "SOUND_MIXER_AGC", 0xc0044d67 },
+{ "SOUND_MIXER_3DSE", 0xc0044d68 },
+{ "SOUND_MIXER_PRIVATE1", 0xc0044d6f },
+{ "SOUND_MIXER_PRIVATE2", 0xc0044d70 },
+{ "SOUND_MIXER_PRIVATE3", 0xc0044d71 },
+{ "SOUND_MIXER_PRIVATE4", 0xc0044d72 },
+{ "SOUND_MIXER_PRIVATE5", 0xc0044d73 },
+{ "SNDCTL_DSP_SPEED", 0xc0045002 },
+{ "SNDCTL_DSP_STEREO", 0xc0045003 },
+{ "SNDCTL_DSP_GETBLKSIZE", 0xc0045004 },
+{ "SNDCTL_DSP_SETFMT", 0xc0045005 },
+{ "SNDCTL_DSP_CHANNELS", 0xc0045006 },
+{ "SOUND_PCM_WRITE_FILTER", 0xc0045007 },
+{ "SNDCTL_DSP_SUBDIVIDE", 0xc0045009 },
+{ "SNDCTL_DSP_SETFRAGMENT", 0xc004500a },
+{ "SNDCTL_DSP_GETCHANNELMASK", 0xc0045040 },
+{ "SNDCTL_DSP_BIND_CHANNEL", 0xc0045041 },
+{ "SNDCTL_SEQ_CTRLRATE", 0xc0045103 },
+{ "SNDCTL_SYNTH_MEMAVL", 0xc004510e },
+{ "SNDCTL_TMR_TIMEBASE", 0xc0045401 },
+{ "SNDCTL_TMR_TEMPO", 0xc0045405 },
+{ "SNDCTL_TMR_SOURCE", 0xc0045406 },
+{ "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", 0xc0045516 },
+{ "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", 0xc0045520 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", 0xc0045540 },
+{ "SNDRV_CTL_IOCTL_POWER", 0xc00455d0 },
+{ "VIDIOC_S_INPUT", 0xc0045627 },
+{ "VIDIOC_S_OUTPUT", 0xc004562f },
+{ "WDIOC_SETTIMEOUT", 0xc0045706 },
+{ "WDIOC_SETPRETIMEOUT", 0xc0045708 },
+{ "FIFREEZE", 0xc0045877 },
+{ "FITHAW", 0xc0045878 },
+{ "SONET_SETDIAG", 0xc0046112 },
+{ "SONET_CLRDIAG", 0xc0046113 },
+{ "BINDER_VERSION", 0xc0046209 },
+{ "DRM_IOCTL_BLOCK", 0xc0046412 },
+{ "DRM_IOCTL_UNBLOCK", 0xc0046413 },
+{ "DRM_IOCTL_ADD_DRAW", 0xc0046427 },
+{ "DRM_IOCTL_RM_DRAW", 0xc0046428 },
+{ "DRM_IOCTL_MGA_WAIT_FENCE", 0xc004644b },
+{ "DRM_IOCTL_MODE_RMFB", 0xc00464af },
+{ "DRM_IOCTL_MODE_DESTROY_DUMB", 0xc00464b4 },
+{ "DRM_IOCTL_MODE_DESTROYPROPBLOB", 0xc00464be },
+{ "SNDCTL_MIDI_PRETIME", 0xc0046d00 },
+{ "SNDCTL_MIDI_MPUMODE", 0xc0046d01 },
+{ "MGSL_IOCWAITEVENT", 0xc0046d08 },
+{ "SCIF_FENCE_WAIT", 0xc0047310 },
+{ "PPPIOCNEWUNIT", 0xc004743e },
+{ "MEYEIOC_SYNC", 0xc00476c3 },
+{ "AUTOFS_IOC_SETTIMEOUT32", 0xc0049364 },
+{ "KVM_GET_MSR_INDEX_LIST", 0xc004ae02 },
+{ "KVM_PPC_ALLOCATE_HTAB", 0xc004aea7 },
+{ "NET_ADD_IF", 0xc0066f34 },
+{ "NET_GET_IF", 0xc0066f36 },
+{ "AGPIOC_ALLOCATE", 0xc0084106 },
+{ "HDA_IOCTL_VERB_WRITE", 0xc0084811 },
+{ "HDA_IOCTL_GET_WCAP", 0xc0084812 },
+{ "ION_IOC_MAP", 0xc0084902 },
+{ "ION_IOC_SHARE", 0xc0084904 },
+{ "ION_IOC_IMPORT", 0xc0084905 },
+{ "ION_IOC_SYNC", 0xc0084907 },
+{ "AMDKFD_IOC_DESTROY_QUEUE", 0xc0084b03 },
+{ "ND_IOCTL_DIMM_FLAGS", 0xc0084e03 },
+{ "ND_IOCTL_SET_CONFIG_DATA", 0xc0084e06 },
+{ "ND_IOCTL_VENDOR", 0xc0084e09 },
+{ "SNDRV_CTL_IOCTL_TLV_READ", 0xc008551a },
+{ "SNDRV_CTL_IOCTL_TLV_WRITE", 0xc008551b },
+{ "SNDRV_CTL_IOCTL_TLV_COMMAND", 0xc008551c },
+{ "VIDIOC_G_CTRL", 0xc008561b },
+{ "VIDIOC_S_CTRL", 0xc008561c },
+{ "VIDIOC_OMAP3ISP_STAT_EN", 0xc00856c7 },
+{ "CM_IOCGATR", 0xc0086301 },
+{ "CIOC_KERNEL_VERSION", 0xc008630a },
+{ "DRM_IOCTL_GEM_FLINK", 0xc008640a },
+{ "DRM_IOCTL_ADD_CTX", 0xc0086420 },
+{ "DRM_IOCTL_RM_CTX", 0xc0086421 },
+{ "DRM_IOCTL_GET_CTX", 0xc0086423 },
+{ "DRM_IOCTL_QXL_ALLOC", 0xc0086440 },
+{ "DRM_IOCTL_AMDGPU_GEM_MMAP", 0xc0086441 },
+{ "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", 0xc0086442 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_READ", 0xc0086442 },
+{ "DRM_IOCTL_VIA_AGP_INIT", 0xc0086442 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_INCR", 0xc0086443 },
+{ "DRM_IOCTL_VIA_FB_INIT", 0xc0086443 },
+{ "DRM_IOCTL_I915_IRQ_EMIT", 0xc0086444 },
+{ "DRM_IOCTL_VIRTGPU_WAIT", 0xc0086448 },
+{ "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", 0xc008644c },
+{ "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", 0xc008644d },
+{ "DRM_IOCTL_RADEON_IRQ_EMIT", 0xc0086456 },
+{ "DRM_IOCTL_I915_GEM_BUSY", 0xc0086457 },
+{ "DRM_IOCTL_EXYNOS_G2D_GET_VER", 0xc0086460 },
+{ "DRM_IOCTL_EXYNOS_G2D_EXEC", 0xc0086462 },
+{ "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", 0xc0086465 },
+{ "DRM_IOCTL_RADEON_GEM_BUSY", 0xc008646a },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", 0xc008646d },
+{ "DRM_IOCTL_I915_GEM_GET_CACHING", 0xc0086470 },
+{ "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", 0xc0086473 },
+{ "I8K_GET_SPEED", 0xc0086985 },
+{ "I8K_GET_FAN", 0xc0086986 },
+{ "I8K_SET_FAN", 0xc0086987 },
+{ "UDF_RELOCATE_BLOCKS", 0xc0086c43 },
+{ "MATROXFB_GET_OUTPUT_MODE", 0xc0086efa },
+{ "PHN_GET_REG", 0xc0087000 },
+{ "PHN_GET_REGS", 0xc0087002 },
+{ "PHN_GETREG", 0xc0087005 },
+{ "PPS_FETCH", 0xc00870a4 },
+{ "PHONE_QUERY_CODEC", 0xc00871a7 },
+{ "MIC_VIRTIO_ADD_DEVICE", 0xc0087301 },
+{ "SCIF_BIND", 0xc0087301 },
+{ "MIC_VIRTIO_COPY_DESC", 0xc0087302 },
+{ "SCIF_CONNECT", 0xc0087303 },
+{ "MIC_VIRTIO_CONFIG_CHANGE", 0xc0087305 },
+{ "SCIF_ACCEPTREG", 0xc0087305 },
+{ "PPPIOCGNPMODE", 0xc008744c },
+{ "AUTOFS_IOC_SETTIMEOUT", 0xc0089364 },
+{ "KVM_GET_SUPPORTED_CPUID", 0xc008ae05 },
+{ "KVM_GET_EMULATED_CPUID", 0xc008ae09 },
+{ "KVM_IRQ_LINE_STATUS", 0xc008ae67 },
+{ "KVM_GET_MSRS", 0xc008ae88 },
+{ "KVM_GET_CPUID2", 0xc008ae91 },
+{ "KVM_GET_REG_LIST", 0xc008aeb0 },
+{ "FSL_HV_IOCTL_PARTITION_RESTART", 0xc008af01 },
+{ "FSL_HV_IOCTL_PARTITION_STOP", 0xc008af04 },
+{ "FSL_HV_IOCTL_DOORBELL", 0xc008af06 },
+{ "VHOST_GET_VRING_BASE", 0xc008af12 },
+{ "MMC_IOC_MULTI_CMD", 0xc008b301 },
+{ "HIDIOCGREPORTINFO", 0xc00c4809 },
+{ "ND_IOCTL_SMART_THRESHOLD", 0xc00c4e02 },
+{ "ND_IOCTL_GET_CONFIG_SIZE", 0xc00c4e04 },
+{ "ND_IOCTL_GET_CONFIG_DATA", 0xc00c4e05 },
+{ "SNDCTL_SYNTH_REMOVESAMPLE", 0xc00c5116 },
+{ "USBDEVFS_IOCTL32", 0xc00c5512 },
+{ "UI_BEGIN_FF_ERASE", 0xc00c55ca },
+{ "DRM_IOCTL_PRIME_HANDLE_TO_FD", 0xc00c642d },
+{ "DRM_IOCTL_PRIME_FD_TO_HANDLE", 0xc00c642e },
+{ "DRM_IOCTL_VIA_CMDBUF_SIZE", 0xc00c644b },
+{ "DRM_IOCTL_I915_VBLANK_SWAP", 0xc00c644f },
+{ "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", 0xc00c6463 },
+{ "DRM_IOCTL_I915_GEM_MADVISE", 0xc00c6466 },
+{ "DRM_IOCTL_RADEON_GEM_SET_TILING", 0xc00c6468 },
+{ "DRM_IOCTL_RADEON_GEM_GET_TILING", 0xc00c6469 },
+{ "KVM_CREATE_DEVICE", 0xc00caee0 },
+{ "FSL_HV_IOCTL_PARTITION_GET_STATUS", 0xc00caf02 },
+{ "MBXFB_IOCX_REG", 0xc00cf405 },
+{ "STP_POLICY_ID_SET", 0xc0102500 },
+{ "CAPI_GET_VERSION", 0xc0104307 },
+{ "CAPI_MANUFACTURER_CMD", 0xc0104320 },
+{ "GIGASET_VERSION", 0xc0104703 },
+{ "IOCTL_MEI_CONNECT_CLIENT", 0xc0104801 },
+{ "HIDIOCGCOLLECTIONINFO", 0xc0104811 },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", 0xc0104822 },
+{ "SNDRV_EMUX_IOCTL_LOAD_PATCH", 0xc0104881 },
+{ "SNDRV_EMUX_IOCTL_MISC_MODE", 0xc0104884 },
+{ "ION_IOC_CUSTOM", 0xc0104906 },
+{ "MEMWRITEOOB", 0xc0104d03 },
+{ "MEMREADOOB", 0xc0104d04 },
+{ "MEMGETREGIONINFO", 0xc0104d08 },
+{ "SNDRV_SEQ_IOCTL_RUNNING_MODE", 0xc0105303 },
+{ "USBDEVFS_CONTROL32", 0xc0105500 },
+{ "USBDEVFS_BULK32", 0xc0105502 },
+{ "USBDEVFS_IOCTL", 0xc0105512 },
+{ "NS_GETPSTAT", 0xc0106161 },
+{ "DRM_IOCTL_GET_UNIQUE", 0xc0106401 },
+{ "DRM_IOCTL_IRQ_BUSID", 0xc0106403 },
+{ "DRM_IOCTL_SET_VERSION", 0xc0106407 },
+{ "DRM_IOCTL_GEM_OPEN", 0xc010640b },
+{ "DRM_IOCTL_GET_CAP", 0xc010640c },
+{ "DRM_IOCTL_INFO_BUFS", 0xc0106418 },
+{ "DRM_IOCTL_GET_SAREA_CTX", 0xc010641d },
+{ "DRM_IOCTL_RES_CTX", 0xc0106426 },
+{ "DRM_IOCTL_SG_ALLOC", 0xc0106438 },
+{ "DRM_IOCTL_ETNAVIV_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_EXYNOS_GEM_CREATE", 0xc0106440 },
+{ "DRM_IOCTL_MSM_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_OMAP_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_TEGRA_GEM_CREATE", 0xc0106440 },
+{ "DRM_IOCTL_EXYNOS_GEM_MAP", 0xc0106441 },
+{ "DRM_IOCTL_QXL_MAP", 0xc0106441 },
+{ "DRM_IOCTL_TEGRA_GEM_MMAP", 0xc0106441 },
+{ "DRM_IOCTL_VC4_WAIT_SEQNO", 0xc0106441 },
+{ "DRM_IOCTL_VIRTGPU_MAP", 0xc0106441 },
+{ "DRM_IOCTL_AMDGPU_CTX", 0xc0106442 },
+{ "DRM_IOCTL_ETNAVIV_GEM_NEW", 0xc0106442 },
+{ "DRM_IOCTL_MSM_GEM_NEW", 0xc0106442 },
+{ "DRM_IOCTL_VC4_WAIT_BO", 0xc0106442 },
+{ "DRM_IOCTL_ETNAVIV_GEM_INFO", 0xc0106443 },
+{ "DRM_IOCTL_MSM_GEM_INFO", 0xc0106443 },
+{ "DRM_IOCTL_OMAP_GEM_NEW", 0xc0106443 },
+{ "DRM_IOCTL_VC4_CREATE_BO", 0xc0106443 },
+{ "DRM_IOCTL_VIRTGPU_GETPARAM", 0xc0106443 },
+{ "DRM_IOCTL_EXYNOS_GEM_GET", 0xc0106444 },
+{ "DRM_IOCTL_QXL_GETPARAM", 0xc0106444 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_WAIT", 0xc0106444 },
+{ "DRM_IOCTL_VC4_MMAP_BO", 0xc0106444 },
+{ "DRM_IOCTL_TEGRA_OPEN_CHANNEL", 0xc0106445 },
+{ "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", 0xc0106445 },
+{ "DRM_IOCTL_I915_GETPARAM", 0xc0106446 },
+{ "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", 0xc0106446 },
+{ "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", 0xc0106447 },
+{ "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", 0xc0106447 },
+{ "DRM_IOCTL_TEGRA_GET_SYNCPT", 0xc0106447 },
+{ "DRM_IOCTL_MGA_GETPARAM", 0xc0106449 },
+{ "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", 0xc0106449 },
+{ "DRM_IOCTL_TEGRA_GEM_SET_TILING", 0xc010644a },
+{ "DRM_IOCTL_TEGRA_GEM_GET_TILING", 0xc010644b },
+{ "DRM_IOCTL_RADEON_INDIRECT", 0xc010644d },
+{ "DRM_IOCTL_R128_INDIRECT", 0xc010644f },
+{ "DRM_IOCTL_AMDGPU_GEM_OP", 0xc0106450 },
+{ "DRM_IOCTL_RADEON_GETPARAM", 0xc0106451 },
+{ "DRM_IOCTL_R128_GETPARAM", 0xc0106452 },
+{ "DRM_IOCTL_SIS_AGP_INIT", 0xc0106453 },
+{ "DRM_IOCTL_I915_GEM_CREATE", 0xc010645b },
+{ "DRM_IOCTL_I915_GEM_SET_TILING", 0xc0106461 },
+{ "DRM_IOCTL_I915_GEM_GET_TILING", 0xc0106462 },
+{ "DRM_IOCTL_I915_GEM_MMAP_GTT", 0xc0106464 },
+{ "DRM_IOCTL_RADEON_INFO", 0xc0106467 },
+{ "DRM_IOCTL_I915_GEM_WAIT", 0xc010646c },
+{ "DRM_IOCTL_RADEON_GEM_OP", 0xc010646c },
+{ "DRM_IOCTL_I915_REG_READ", 0xc0106471 },
+{ "DRM_IOCTL_MODE_SETPROPERTY", 0xc01064ab },
+{ "DRM_IOCTL_MODE_GETPROPBLOB", 0xc01064ac },
+{ "DRM_IOCTL_MODE_MAP_DUMB", 0xc01064b3 },
+{ "DRM_IOCTL_MODE_GETPLANERESOURCES", 0xc01064b5 },
+{ "DRM_IOCTL_MODE_CREATEPROPBLOB", 0xc01064bd },
+{ "MGSL_IOCWAITGPIO", 0xc0106d12 },
+{ "NCP_IOC_GETPRIVATEDATA", 0xc0106e0a },
+{ "DMX_GET_STC", 0xc0106f32 },
+{ "SCIF_ACCEPTREQ", 0xc0107304 },
+{ "SCIF_UNREG", 0xc0107309 },
+{ "SCIF_FENCE_MARK", 0xc010730f },
+{ "UVCIOC_CTRL_QUERY", 0xc0107521 },
+{ "BTRFS_IOC_SPACE_INFO", 0xc0109414 },
+{ "BTRFS_IOC_QUOTA_CTL", 0xc0109428 },
+{ "FSL_HV_IOCTL_PARTITION_START", 0xc010af03 },
+{ "SNDCTL_COPR_RDATA", 0xc0144302 },
+{ "SNDCTL_COPR_RCODE", 0xc0144303 },
+{ "SNDCTL_COPR_RUN", 0xc0144306 },
+{ "SNDCTL_COPR_HALT", 0xc0144307 },
+{ "SNDRV_TIMER_IOCTL_NEXT_DEVICE", 0xc0145401 },
+{ "VIDIOC_REQBUFS", 0xc0145608 },
+{ "VIDIOC_G_CROP", 0xc014563b },
+{ "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", 0xc014646a },
+{ "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", 0xc014646b },
+{ "DRM_IOCTL_MODE_GETENCODER", 0xc01464a6 },
+{ "HFI1_IOCTL_TID_UPDATE", 0xc0181be4 },
+{ "HFI1_IOCTL_TID_FREE", 0xc0181be5 },
+{ "HFI1_IOCTL_TID_INVAL_READ", 0xc0181bed },
+{ "FW_CDEV_IOC_ADD_DESCRIPTOR", 0xc0182306 },
+{ "FW_CDEV_IOC_QUEUE_ISO", 0xc0182309 },
+{ "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", 0xc018230d },
+{ "FW_CDEV_IOC_GET_CYCLE_TIMER2", 0xc0182314 },
+{ "FW_CDEV_IOC_SEND_PHY_PACKET", 0xc0182315 },
+{ "HIDIOCGUSAGE", 0xc018480b },
+{ "HIDIOCGUCODE", 0xc018480d },
+{ "AMDKFD_IOC_WAIT_EVENTS", 0xc0184b0c },
+{ "MTRRIOC_GET_ENTRY", 0xc0184d03 },
+{ "MTRRIOC_GET_PAGE_ENTRY", 0xc0184d08 },
+{ "MEMWRITEOOB64", 0xc0184d15 },
+{ "MEMREADOOB64", 0xc0184d16 },
+{ "USBDEVFS_CONTROL", 0xc0185500 },
+{ "USBDEVFS_BULK", 0xc0185502 },
+{ "PACKET_CTRL_CMD", 0xc0185801 },
+{ "FITRIM", 0xc0185879 },
+{ "DRM_IOCTL_MAP_BUFS", 0xc0186419 },
+{ "DRM_IOCTL_WAIT_VBLANK", 0xc018643a },
+{ "DRM_IOCTL_AMDGPU_BO_LIST", 0xc0186443 },
+{ "DRM_IOCTL_AMDGPU_CS", 0xc0186444 },
+{ "DRM_IOCTL_I810_GETBUF", 0xc0186445 },
+{ "DRM_IOCTL_VC4_CREATE_SHADER_BO", 0xc0186445 },
+{ "DRM_IOCTL_OMAP_GEM_INFO", 0xc0186446 },
+{ "DRM_IOCTL_QXL_ALLOC_SURF", 0xc0186446 },
+{ "DRM_IOCTL_ETNAVIV_GEM_USERPTR", 0xc0186448 },
+{ "DRM_IOCTL_I915_ALLOC", 0xc0186448 },
+{ "DRM_IOCTL_VIRTGPU_GET_CAPS", 0xc0186449 },
+{ "DRM_IOCTL_VIA_WAIT_IRQ", 0xc018644d },
+{ "DRM_IOCTL_AMDGPU_GEM_USERPTR", 0xc0186451 },
+{ "DRM_IOCTL_RADEON_ALLOC", 0xc0186453 },
+{ "DRM_IOCTL_I915_GEM_PIN", 0xc0186455 },
+{ "DRM_IOCTL_RADEON_GEM_INFO", 0xc018645c },
+{ "DRM_IOCTL_RADEON_GEM_VA", 0xc018646b },
+{ "DRM_IOCTL_RADEON_GEM_USERPTR", 0xc018646d },
+{ "DRM_IOCTL_I915_GET_RESET_STATS", 0xc0186472 },
+{ "DRM_IOCTL_I915_GEM_USERPTR", 0xc0186473 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", 0xc0186474 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", 0xc0186475 },
+{ "DRM_IOCTL_MODE_PAGE_FLIP", 0xc01864b0 },
+{ "DRM_IOCTL_MODE_DIRTYFB", 0xc01864b1 },
+{ "DRM_IOCTL_MODE_OBJ_SETPROPERTY", 0xc01864ba },
+{ "I2OHRTGET", 0xc0186901 },
+{ "I2OLCTGET", 0xc0186902 },
+{ "RIO_ALLOC_DMA", 0xc0186d13 },
+{ "RIO_TRANSFER", 0xc0186d15 },
+{ "NCP_IOC_GETOBJECTNAME", 0xc0186e09 },
+{ "NILFS_IOCTL_GET_VINFO", 0xc0186e86 },
+{ "NILFS_IOCTL_GET_BDESCS", 0xc0186e87 },
+{ "SCIF_SEND", 0xc0187306 },
+{ "SCIF_RECV", 0xc0187307 },
+{ "SCIF_GET_NODEIDS", 0xc018730e },
+{ "TOSH_SMM", 0xc0187490 },
+{ "TOSHIBA_ACPI_SCI", 0xc0187491 },
+{ "AUTOFS_DEV_IOCTL_VERSION", 0xc0189371 },
+{ "AUTOFS_DEV_IOCTL_PROTOVER", 0xc0189372 },
+{ "AUTOFS_DEV_IOCTL_PROTOSUBVER", 0xc0189373 },
+{ "AUTOFS_DEV_IOCTL_OPENMOUNT", 0xc0189374 },
+{ "AUTOFS_DEV_IOCTL_CLOSEMOUNT", 0xc0189375 },
+{ "AUTOFS_DEV_IOCTL_READY", 0xc0189376 },
+{ "AUTOFS_DEV_IOCTL_FAIL", 0xc0189377 },
+{ "AUTOFS_DEV_IOCTL_SETPIPEFD", 0xc0189378 },
+{ "AUTOFS_DEV_IOCTL_CATATONIC", 0xc0189379 },
+{ "AUTOFS_DEV_IOCTL_TIMEOUT", 0xc018937a },
+{ "AUTOFS_DEV_IOCTL_REQUESTER", 0xc018937b },
+{ "AUTOFS_DEV_IOCTL_EXPIRE", 0xc018937c },
+{ "AUTOFS_DEV_IOCTL_ASKUMOUNT", 0xc018937d },
+{ "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", 0xc018937e },
+{ "BTRFS_IOC_FILE_EXTENT_SAME", 0xc0189436 },
+{ "FIDEDUPERANGE", 0xc0189436 },
+{ "UFFDIO_API", 0xc018aa3f },
+{ "KVM_TRANSLATE", 0xc018ae85 },
+{ "IB_USER_MAD_REGISTER_AGENT", 0xc01c1b01 },
+{ "HFI1_IOCTL_ASSIGN_CTXT", 0xc01c1be1 },
+{ "SI4713_IOC_MEASURE_RNL", 0xc01c56c0 },
+{ "DRM_IOCTL_MODE_CURSOR", 0xc01c64a3 },
+{ "DRM_IOCTL_MODE_GETFB", 0xc01c64ad },
+{ "DRM_IOCTL_MODE_ADDFB", 0xc01c64ae },
+{ "FW_CDEV_IOC_ALLOCATE", 0xc0202302 },
+{ "FW_CDEV_IOC_CREATE_ISO_CONTEXT", 0xc0202308 },
+{ "ION_IOC_ALLOC", 0xc0204900 },
+{ "AMDKFD_IOC_CREATE_EVENT", 0xc0204b08 },
+{ "ND_IOCTL_ARS_CAP", 0xc0204e01 },
+{ "ND_IOCTL_ARS_START", 0xc0204e02 },
+{ "ND_IOCTL_CLEAR_ERROR", 0xc0204e04 },
+{ "VIDIOC_G_EXT_CTRLS", 0xc0205647 },
+{ "VIDIOC_S_EXT_CTRLS", 0xc0205648 },
+{ "VIDIOC_TRY_EXT_CTRLS", 0xc0205649 },
+{ "VIDIOC_OMAP3ISP_AEWB_CFG", 0xc02056c3 },
+{ "X86_IOC_RDMSR_REGS", 0xc02063a0 },
+{ "X86_IOC_WRMSR_REGS", 0xc02063a1 },
+{ "DRM_IOCTL_ADD_BUFS", 0xc0206416 },
+{ "DRM_IOCTL_AGP_ALLOC", 0xc0206434 },
+{ "DRM_IOCTL_AMDGPU_GEM_CREATE", 0xc0206440 },
+{ "DRM_IOCTL_VIA_ALLOCMEM", 0xc0206440 },
+{ "DRM_IOCTL_SIS_FB_ALLOC", 0xc0206444 },
+{ "DRM_IOCTL_MSM_GEM_SUBMIT", 0xc0206446 },
+{ "DRM_IOCTL_VIA_DMA_INIT", 0xc0206447 },
+{ "DRM_IOCTL_AMDGPU_WAIT_CS", 0xc0206449 },
+{ "DRM_IOCTL_MGA_DMA_BOOTSTRAP", 0xc020644c },
+{ "DRM_IOCTL_RADEON_TEXTURE", 0xc020644e },
+{ "DRM_IOCTL_SIS_AGP_ALLOC", 0xc0206454 },
+{ "DRM_IOCTL_RADEON_GEM_CREATE", 0xc020645d },
+{ "DRM_IOCTL_RADEON_GEM_MMAP", 0xc020645e },
+{ "DRM_IOCTL_RADEON_GEM_PREAD", 0xc0206461 },
+{ "DRM_IOCTL_RADEON_GEM_PWRITE", 0xc0206462 },
+{ "DRM_IOCTL_RADEON_CS", 0xc0206466 },
+{ "DRM_IOCTL_MODE_GETGAMMA", 0xc02064a4 },
+{ "DRM_IOCTL_MODE_SETGAMMA", 0xc02064a5 },
+{ "DRM_IOCTL_MODE_CREATE_DUMB", 0xc02064b2 },
+{ "DRM_IOCTL_MODE_GETPLANE", 0xc02064b6 },
+{ "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", 0xc02064b9 },
+{ "FS_IOC_FIEMAP", 0xc020660b },
+{ "GENWQE_PIN_MEM", 0xc020a528 },
+{ "GENWQE_UNPIN_MEM", 0xc020a529 },
+{ "UFFDIO_REGISTER", 0xc020aa00 },
+{ "UFFDIO_ZEROPAGE", 0xc020aa04 },
+{ "SNDCTL_MIDI_MPUCMD", 0xc0216d02 },
+{ "SNDRV_COMPRESS_GET_METADATA", 0xc0244315 },
+{ "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", 0xc0246446 },
+{ "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", 0xc0246447 },
+{ "DRM_IOCTL_MODE_CURSOR2", 0xc02464bb },
+{ "IB_USER_MAD_REGISTER_AGENT2", 0xc0281b04 },
+{ "FW_CDEV_IOC_GET_INFO", 0xc0282300 },
+{ "AMDKFD_IOC_GET_CLOCK_COUNTERS", 0xc0284b05 },
+{ "VIDIOC_G_EDID", 0xc0285628 },
+{ "VIDIOC_SUBDEV_G_EDID", 0xc0285628 },
+{ "VIDIOC_SUBDEV_S_EDID", 0xc0285629 },
+{ "VIDIOC_S_EDID", 0xc0285629 },
+{ "VIDIOC_ENCODER_CMD", 0xc028564d },
+{ "VIDIOC_TRY_ENCODER_CMD", 0xc028564e },
+{ "VIDIOC_OMAP3ISP_STAT_REQ", 0xc02856c6 },
+{ "SW_SYNC_IOC_CREATE_FENCE", 0xc0285700 },
+{ "DRM_IOCTL_GET_MAP", 0xc0286404 },
+{ "DRM_IOCTL_GET_CLIENT", 0xc0286405 },
+{ "DRM_IOCTL_ADD_MAP", 0xc0286415 },
+{ "DRM_IOCTL_VIA_MAP_INIT", 0xc0286444 },
+{ "DRM_IOCTL_I915_GEM_MMAP", 0xc028645e },
+{ "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", 0xc0286461 },
+{ "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", 0xc0286472 },
+{ "DRM_IOCTL_NOUVEAU_GEM_INFO", 0xc0286484 },
+{ "I2OPARMSET", 0xc0286903 },
+{ "I2OPARMGET", 0xc0286904 },
+{ "RIO_MAP_OUTBOUND", 0xc0286d0f },
+{ "RIO_MAP_INBOUND", 0xc0286d11 },
+{ "NCP_IOC_GET_FS_INFO", 0xc0286e04 },
+{ "PHN_GETREGS", 0xc0287007 },
+{ "SCIF_REG", 0xc0287308 },
+{ "SCIF_READFROM", 0xc028730a },
+{ "SCIF_WRITETO", 0xc028730b },
+{ "SCIF_VREADFROM", 0xc028730c },
+{ "SCIF_VWRITETO", 0xc028730d },
+{ "SCIF_FENCE_SIGNAL", 0xc0287311 },
+{ "MEDIA_IOC_ENUM_LINKS", 0xc0287c02 },
+{ "UFFDIO_COPY", 0xc028aa03 },
+{ "KVM_TPR_ACCESS_REPORTING", 0xc028ae92 },
+{ "FSL_HV_IOCTL_MEMCPY", 0xc028af05 },
+{ "FSL_HV_IOCTL_GETPROP", 0xc028af07 },
+{ "FSL_HV_IOCTL_SETPROP", 0xc028af08 },
+{ "NCP_IOC_GETCHARSETS", 0xc02a6e0b },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", 0xc02c5341 },
+{ "VIDIOC_QUERYMENU", 0xc02c5625 },
+{ "VIDIOC_G_FREQUENCY", 0xc02c5638 },
+{ "VIDIOC_CROPCAP", 0xc02c563a },
+{ "VIDIOC_ENUM_FRAMESIZES", 0xc02c564a },
+{ "DRM_IOCTL_I915_OVERLAY_ATTRS", 0xc02c6468 },
+{ "SYNC_IOC_MERGE", 0xc0303e03 },
+{ "MEMWRITE", 0xc0304d18 },
+{ "ND_IOCTL_ARS_STATUS", 0xc0304e03 },
+{ "SNDRV_SEQ_IOCTL_SYSTEM_INFO", 0xc0305302 },
+{ "VIDIOC_SUBDEV_ENUM_MBUS_CODE", 0xc0305602 },
+{ "VIDIOC_SUBDEV_G_FRAME_INTERVAL", 0xc0305615 },
+{ "VIDIOC_SUBDEV_S_FRAME_INTERVAL", 0xc0305616 },
+{ "VIDIOC_OMAP3ISP_HIST_CFG", 0xc03056c4 },
+{ "SNDRV_RAWMIDI_IOCTL_PARAMS", 0xc0305710 },
+{ "BINDER_WRITE_READ", 0xc0306201 },
+{ "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", 0xc0306446 },
+{ "DRM_IOCTL_NOUVEAU_GEM_NEW", 0xc0306480 },
+{ "DRM_IOCTL_MODE_SETPLANE", 0xc03064b7 },
+{ "I2OSWDL", 0xc0306905 },
+{ "I2OSWUL", 0xc0306906 },
+{ "I2OSWDEL", 0xc0306907 },
+{ "I2OHTML", 0xc0306909 },
+{ "IPMICTL_RECEIVE_MSG_TRUNC", 0xc030690b },
+{ "IPMICTL_RECEIVE_MSG", 0xc030690c },
+{ "NCP_IOC_GET_FS_INFO_V2", 0xc0306e04 },
+{ "MBXFB_IOCX_OVERLAY", 0xc030f400 },
+{ "VIDIOC_ENUMAUDIO", 0xc0345641 },
+{ "VIDIOC_ENUMAUDOUT", 0xc0345642 },
+{ "VIDIOC_ENUM_FRAMEINTERVALS", 0xc034564b },
+{ "MEDIA_IOC_SETUP_LINK", 0xc0347c03 },
+{ "SYNC_IOC_FILE_INFO", 0xc0383e04 },
+{ "HIDIOCGFIELDINFO", 0xc038480a },
+{ "VIDIOC_SUBDEV_G_CROP", 0xc038563b },
+{ "VIDIOC_SUBDEV_S_CROP", 0xc038563c },
+{ "VIDIOC_DBG_G_REGISTER", 0xc0385650 },
+{ "VIDIOC_OMAP3ISP_CCDC_CFG", 0xc03856c1 },
+{ "SNDRV_RAWMIDI_IOCTL_STATUS", 0xc0385720 },
+{ "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", 0xc0386444 },
+{ "DRM_IOCTL_MODE_ATOMIC", 0xc03864bc },
+{ "BTRFS_IOC_INO_PATHS", 0xc0389423 },
+{ "BTRFS_IOC_LOGICAL_INO", 0xc0389424 },
+{ "GENWQE_SLU_UPDATE", 0xc038a550 },
+{ "GENWQE_SLU_READ", 0xc038a551 },
+{ "PTP_SYS_OFFSET_PRECISE", 0xc0403d08 },
+{ "CAPI_GET_PROFILE", 0xc0404309 },
+{ "ND_IOCTL_CALL", 0xc0404e0a },
+{ "SNDRV_CTL_IOCTL_ELEM_REMOVE", 0xc0405519 },
+{ "VIDIOC_ENUM_FMT", 0xc0405602 },
+{ "VIDIOC_EXPBUF", 0xc0405610 },
+{ "VIDIOC_SUBDEV_G_SELECTION", 0xc040563d },
+{ "VIDIOC_SUBDEV_S_SELECTION", 0xc040563e },
+{ "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", 0xc040564a },
+{ "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", 0xc040564b },
+{ "VIDIOC_G_SELECTION", 0xc040565e },
+{ "VIDIOC_S_SELECTION", 0xc040565f },
+{ "VIDIOC_ENUM_FREQ_BANDS", 0xc0405665 },
+{ "DRM_IOCTL_VERSION", 0xc0406400 },
+{ "DRM_IOCTL_DMA", 0xc0406429 },
+{ "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", 0xc0406481 },
+{ "DRM_IOCTL_MODE_GETRESOURCES", 0xc04064a0 },
+{ "DRM_IOCTL_MODE_GETPROPERTY", 0xc04064aa },
+{ "VIDIOC_QUERYCTRL", 0xc0445624 },
+{ "VIDIOC_G_MODULATOR", 0xc0445636 },
+{ "BLKTRACESETUP", 0xc0481273 },
+{ "SNDRV_EMU10K1_IOCTL_PCM_PEEK", 0xc0484831 },
+{ "NVME_IOCTL_ADMIN_CMD", 0xc0484e41 },
+{ "NVME_IOCTL_IO_CMD", 0xc0484e43 },
+{ "VIDIOC_ENUMSTD", 0xc0485619 },
+{ "VIDIOC_ENUMOUTPUT", 0xc0485630 },
+{ "VIDIOC_DECODER_CMD", 0xc0485660 },
+{ "VIDIOC_TRY_DECODER_CMD", 0xc0485661 },
+{ "DRM_IOCTL_MODE_ATTACHMODE", 0xc04864a8 },
+{ "DRM_IOCTL_MODE_DETACHMODE", 0xc04864a9 },
+{ "VIDEO_COMMAND", 0xc0486f3b },
+{ "VIDEO_TRY_COMMAND", 0xc0486f3c },
+{ "MEDIA_IOC_G_TOPOLOGY", 0xc0487c04 },
+{ "KVM_GET_PIT", 0xc048ae65 },
+{ "MMC_IOC_CMD", 0xc048b300 },
+{ "GPIO_GET_LINEINFO_IOCTL", 0xc048b402 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", 0xc04c5349 },
+{ "VIDIOC_OMAP3ISP_AF_CFG", 0xc04c56c5 },
+{ "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", 0xc0505350 },
+{ "SNDRV_TIMER_IOCTL_GSTATUS", 0xc0505405 },
+{ "SNDRV_CTL_IOCTL_ELEM_LIST", 0xc0505510 },
+{ "VIDIOC_ENUMINPUT", 0xc050561a },
+{ "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", 0xc0506470 },
+{ "DRM_IOCTL_MODE_GETCONNECTOR", 0xc05064a7 },
+{ "VIDIOC_G_TUNER", 0xc054561d },
+{ "SISFB_COMMAND", 0xc054f305 },
+{ "CCISS_PASSTHRU", 0xc058420b },
+{ "AMDKFD_IOC_CREATE_QUEUE", 0xc0584b02 },
+{ "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", 0xc058534b },
+{ "SNDRV_SEQ_IOCTL_QUERY_SUBS", 0xc058534f },
+{ "VIDIOC_SUBDEV_G_FMT", 0xc0585604 },
+{ "VIDIOC_SUBDEV_S_FMT", 0xc0585605 },
+{ "VIDIOC_QUERYBUF", 0xc0585609 },
+{ "VIDIOC_QBUF", 0xc058560f },
+{ "VIDIOC_DQBUF", 0xc0585611 },
+{ "VIDIOC_PREPARE_BUF", 0xc058565d },
+{ "DRM_IOCTL_TEGRA_SUBMIT", 0xc0586448 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", 0xc05c5340 },
+{ "PTP_PIN_GETFUNC", 0xc0603d06 },
+{ "CCISS_BIG_PASSTHRU", 0xc0604212 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", 0xc0605345 },
+{ "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", 0xc0606471 },
+{ "UVCIOC_CTRL_MAP", 0xc0607520 },
+{ "DK_CXLFLASH_DETACH", 0xc060ca83 },
+{ "FBIO_CURSOR", 0xc0684608 },
+{ "UI_BEGIN_FF_UPLOAD", 0xc06855c8 },
+{ "DRM_IOCTL_MODE_GETCRTC", 0xc06864a1 },
+{ "DRM_IOCTL_MODE_SETCRTC", 0xc06864a2 },
+{ "DRM_IOCTL_MODE_ADDFB2", 0xc06864b8 },
+{ "DK_CXLFLASH_RELEASE", 0xc068ca82 },
+{ "DK_CXLFLASH_MANAGE_LUN", 0xc068ca86 },
+{ "VIDIOC_OMAP3ISP_PRV_CFG", 0xc07056c2 },
+{ "BTRFS_IOC_TREE_SEARCH_V2", 0xc0709411 },
+{ "DK_CXLFLASH_USER_DIRECT", 0xc070ca81 },
+{ "DK_CXLFLASH_VLUN_CLONE", 0xc070ca89 },
+{ "SNDCTL_MIDI_INFO", 0xc074510c },
+{ "VIDIOC_G_SLICED_VBI_CAP", 0xc0745645 },
+{ "DK_CXLFLASH_RECOVER_AFU", 0xc078ca85 },
+{ "DK_CXLFLASH_USER_VIRTUAL", 0xc078ca87 },
+{ "DK_CXLFLASH_VLUN_RESIZE", 0xc078ca88 },
+{ "SOUND_MIXER_ACCESS", 0xc0804d66 },
+{ "ND_IOCTL_SMART", 0xc0844e01 },
+{ "VIDIOC_SUBDEV_S_DV_TIMINGS", 0xc0845657 },
+{ "VIDIOC_S_DV_TIMINGS", 0xc0845657 },
+{ "VIDIOC_G_DV_TIMINGS", 0xc0845658 },
+{ "VIDIOC_SUBDEV_G_DV_TIMINGS", 0xc0845658 },
+{ "SNDRV_PCM_IOCTL_SW_PARAMS", 0xc0884113 },
+{ "SNDRV_PCM_IOCTL_SYNC_PTR", 0xc0884123 },
+{ "PPPIOCGCALLINFO", 0xc0887480 },
+{ "SNDCTL_SYNTH_INFO", 0xc08c5102 },
+{ "SNDCTL_SYNTH_ID", 0xc08c5114 },
+{ "SNDRV_SEQ_IOCTL_CREATE_QUEUE", 0xc08c5332 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", 0xc08c5334 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", 0xc08c5335 },
+{ "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", 0xc08c5336 },
+{ "VIDIOC_DV_TIMINGS_CAP", 0xc0905664 },
+{ "VIDIOC_SUBDEV_DV_TIMINGS_CAP", 0xc0905664 },
+{ "DK_CXLFLASH_ATTACH", 0xc090ca80 },
+{ "DK_CXLFLASH_VERIFY", 0xc090ca84 },
+{ "VIDIOC_ENUM_DV_TIMINGS", 0xc0945662 },
+{ "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", 0xc0945662 },
+{ "SNDRV_PCM_IOCTL_STATUS_EXT", 0xc0984124 },
+{ "DRM_IOCTL_VC4_SUBMIT_CL", 0xc0a06440 },
+{ "DRM_IOCTL_VC4_GET_HANG_STATE", 0xc0a06446 },
+{ "SOUND_MIXER_GETLEVELS", 0xc0a44d74 },
+{ "SOUND_MIXER_SETLEVELS", 0xc0a44d75 },
+{ "SNDRV_SEQ_IOCTL_CREATE_PORT", 0xc0a85320 },
+{ "SNDRV_SEQ_IOCTL_GET_PORT_INFO", 0xc0a85322 },
+{ "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", 0xc0a85352 },
+{ "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", 0xc0bc5310 },
+{ "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", 0xc0bc5351 },
+{ "SNDRV_COMPRESS_GET_CAPS", 0xc0c44310 },
+{ "VIDIOC_DBG_G_CHIP_INFO", 0xc0c85666 },
+{ "BTRFS_IOC_SET_RECEIVED_SUBVOL", 0xc0c89425 },
+{ "VIDIOC_G_PARM", 0xc0cc5615 },
+{ "VIDIOC_S_PARM", 0xc0cc5616 },
+{ "VIDIOC_G_FMT", 0xc0d05604 },
+{ "VIDIOC_S_FMT", 0xc0d05605 },
+{ "VIDIOC_TRY_FMT", 0xc0d05640 },
+{ "VIDIOC_QUERY_EXT_CTRL", 0xc0e85667 },
+{ "GENWQE_EXECUTE_DDCB", 0xc0e8a532 },
+{ "GENWQE_EXECUTE_RAW_DDCB", 0xc0e8a533 },
+{ "SNDRV_TIMER_IOCTL_GINFO", 0xc0f85403 },
+{ "VIDIOC_CREATE_BUFS", 0xc100565c },
+{ "MEDIA_IOC_DEVICE_INFO", 0xc1007c00 },
+{ "MEDIA_IOC_ENUM_ENTITIES", 0xc1007c01 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_INFO", 0xc10c5541 },
+{ "SNDRV_CTL_IOCTL_ELEM_INFO", 0xc1105511 },
+{ "SNDRV_CTL_IOCTL_ELEM_ADD", 0xc1105517 },
+{ "SNDRV_CTL_IOCTL_ELEM_REPLACE", 0xc1105518 },
+{ "SNDRV_CTL_IOCTL_PCM_INFO", 0xc1205531 },
+{ "DRM_IOCTL_AMDGPU_GEM_METADATA", 0xc1206446 },
+{ "DM_VERSION", 0xc138fd00 },
+{ "DM_REMOVE_ALL", 0xc138fd01 },
+{ "DM_LIST_DEVICES", 0xc138fd02 },
+{ "DM_DEV_CREATE", 0xc138fd03 },
+{ "DM_DEV_REMOVE", 0xc138fd04 },
+{ "DM_DEV_RENAME", 0xc138fd05 },
+{ "DM_DEV_SUSPEND", 0xc138fd06 },
+{ "DM_DEV_STATUS", 0xc138fd07 },
+{ "DM_DEV_WAIT", 0xc138fd08 },
+{ "DM_TABLE_LOAD", 0xc138fd09 },
+{ "DM_TABLE_CLEAR", 0xc138fd0a },
+{ "DM_TABLE_DEPS", 0xc138fd0b },
+{ "DM_TABLE_STATUS", 0xc138fd0c },
+{ "DM_LIST_VERSIONS", 0xc138fd0d },
+{ "DM_TARGET_MSG", 0xc138fd0e },
+{ "DM_DEV_SET_GEOMETRY", 0xc138fd0f },
+{ "SNDRV_EMU10K1_IOCTL_CODE_PEEK", 0xc1b04812 },
+{ "KVM_GET_IRQCHIP", 0xc208ae62 },
+{ "SNDRV_PCM_IOCTL_HW_REFINE", 0xc2604110 },
+{ "SNDRV_PCM_IOCTL_HW_PARAMS", 0xc2604111 },
+{ "VIDIOC_VSP1_LUT_CONFIG", 0xc40056c1 },
+{ "BTRFS_IOC_SCRUB", 0xc400941b },
+{ "BTRFS_IOC_SCRUB_PROGRESS", 0xc400941d },
+{ "BTRFS_IOC_BALANCE_V2", 0xc4009420 },
+{ "BTRFS_IOC_GET_DEV_STATS", 0xc4089434 },
+{ "SNDRV_CTL_IOCTL_ELEM_READ", 0xc4c85512 },
+{ "SNDRV_CTL_IOCTL_ELEM_WRITE", 0xc4c85513 },
+{ "BTRFS_IOC_DEV_REPLACE", 0xca289435 },
+{ "SNDCTL_COPR_SENDMSG", 0xcfa44308 },
+{ "SNDCTL_SYNTH_CONTROL", 0xcfa45115 },
+{ "SNDCTL_COPR_LOAD", 0xcfb04301 },
+{ "NVM_INFO", 0xd0004c20 },
+{ "BTRFS_IOC_TREE_SEARCH", 0xd0009411 },
+{ "BTRFS_IOC_INO_LOOKUP", 0xd0009412 },
+{ "BTRFS_IOC_DEV_INFO", 0xd000941e },
+{ "HIDIOCGUSAGES", 0xd01c4813 },
+{ "SNDRV_COMPRESS_GET_CODEC_CAPS", 0xeb884311 },
diff --git a/strace/ioctlent1.h b/strace/ioctlent1.h
new file mode 100644
index 0000000..03384b3
--- /dev/null
+++ b/strace/ioctlent1.h
@@ -0,0 +1,2831 @@
+/* Generated by ioctlsort. */
+{ "FIBMAP", 0x00000001 },
+{ "FIGETBSZ", 0x00000002 },
+{ "FDCLRPRM", 0x00000241 },
+{ "FDMSGON", 0x00000245 },
+{ "FDMSGOFF", 0x00000246 },
+{ "FDFMTBEG", 0x00000247 },
+{ "FDFMTEND", 0x00000249 },
+{ "FDSETEMSGTRESH", 0x0000024a },
+{ "FDFLUSH", 0x0000024b },
+{ "FDRESET", 0x00000254 },
+{ "FDWERRORCLR", 0x00000256 },
+{ "FDRAWCMD", 0x00000258 },
+{ "FDTWADDLE", 0x00000259 },
+{ "FDEJECT", 0x0000025a },
+{ "HDIO_GETGEO", 0x00000301 },
+{ "HDIO_GET_UNMASKINTR", 0x00000302 },
+{ "HDIO_GET_MULTCOUNT", 0x00000304 },
+{ "HDIO_GET_QDMA", 0x00000305 },
+{ "HDIO_SET_XFER", 0x00000306 },
+{ "HDIO_OBSOLETE_IDENTITY", 0x00000307 },
+{ "HDIO_GET_KEEPSETTINGS", 0x00000308 },
+{ "HDIO_GET_32BIT", 0x00000309 },
+{ "HDIO_GET_NOWERR", 0x0000030a },
+{ "HDIO_GET_DMA", 0x0000030b },
+{ "HDIO_GET_NICE", 0x0000030c },
+{ "HDIO_GET_IDENTITY", 0x0000030d },
+{ "HDIO_GET_WCACHE", 0x0000030e },
+{ "HDIO_GET_ACOUSTIC", 0x0000030f },
+{ "HDIO_GET_ADDRESS", 0x00000310 },
+{ "HDIO_GET_BUSSTATE", 0x0000031a },
+{ "HDIO_TRISTATE_HWIF", 0x0000031b },
+{ "HDIO_DRIVE_RESET", 0x0000031c },
+{ "HDIO_DRIVE_TASKFILE", 0x0000031d },
+{ "HDIO_DRIVE_TASK", 0x0000031e },
+{ "HDIO_DRIVE_CMD", 0x0000031f },
+{ "HDIO_SET_MULTCOUNT", 0x00000321 },
+{ "HDIO_SET_UNMASKINTR", 0x00000322 },
+{ "HDIO_SET_KEEPSETTINGS", 0x00000323 },
+{ "HDIO_SET_32BIT", 0x00000324 },
+{ "HDIO_SET_NOWERR", 0x00000325 },
+{ "HDIO_SET_DMA", 0x00000326 },
+{ "HDIO_SET_PIO_MODE", 0x00000327 },
+{ "HDIO_SCAN_HWIF", 0x00000328 },
+{ "HDIO_SET_NICE", 0x00000329 },
+{ "HDIO_UNREGISTER_HWIF", 0x0000032a },
+{ "HDIO_SET_WCACHE", 0x0000032b },
+{ "HDIO_SET_ACOUSTIC", 0x0000032c },
+{ "HDIO_SET_BUSSTATE", 0x0000032d },
+{ "HDIO_SET_QDMA", 0x0000032e },
+{ "HDIO_SET_ADDRESS", 0x0000032f },
+{ "IOCTL_VMCI_VERSION", 0x0000079f },
+{ "IOCTL_VMCI_INIT_CONTEXT", 0x000007a0 },
+{ "IOCTL_VMCI_QUEUEPAIR_SETVA", 0x000007a4 },
+{ "IOCTL_VMCI_NOTIFY_RESOURCE", 0x000007a5 },
+{ "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", 0x000007a6 },
+{ "IOCTL_VMCI_VERSION2", 0x000007a7 },
+{ "IOCTL_VMCI_QUEUEPAIR_ALLOC", 0x000007a8 },
+{ "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", 0x000007a9 },
+{ "IOCTL_VMCI_QUEUEPAIR_DETACH", 0x000007aa },
+{ "IOCTL_VMCI_DATAGRAM_SEND", 0x000007ab },
+{ "IOCTL_VMCI_DATAGRAM_RECEIVE", 0x000007ac },
+{ "IOCTL_VMCI_CTX_ADD_NOTIFICATION", 0x000007af },
+{ "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", 0x000007b0 },
+{ "IOCTL_VMCI_CTX_GET_CPT_STATE", 0x000007b1 },
+{ "IOCTL_VMCI_CTX_SET_CPT_STATE", 0x000007b2 },
+{ "IOCTL_VMCI_GET_CONTEXT_ID", 0x000007b3 },
+{ "IOCTL_VMCI_SOCKETS_VERSION", 0x000007b4 },
+{ "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", 0x000007b8 },
+{ "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", 0x000007b9 },
+{ "IOCTL_VM_SOCKETS_GET_LOCAL_CID", 0x000007b9 },
+{ "IOCTL_VMCI_SET_NOTIFY", 0x000007cb },
+{ "RAID_AUTORUN", 0x00000914 },
+{ "CLEAR_ARRAY", 0x00000920 },
+{ "HOT_REMOVE_DISK", 0x00000922 },
+{ "SET_DISK_INFO", 0x00000924 },
+{ "WRITE_RAID_INFO", 0x00000925 },
+{ "UNPROTECT_ARRAY", 0x00000926 },
+{ "PROTECT_ARRAY", 0x00000927 },
+{ "HOT_ADD_DISK", 0x00000928 },
+{ "SET_DISK_FAULTY", 0x00000929 },
+{ "HOT_GENERATE_ERROR", 0x0000092a },
+{ "STOP_ARRAY", 0x00000932 },
+{ "STOP_ARRAY_RO", 0x00000933 },
+{ "RESTART_ARRAY_RW", 0x00000934 },
+{ "CLUSTERED_DISK_NACK", 0x00000935 },
+{ "BLKROSET", 0x0000125d },
+{ "BLKROGET", 0x0000125e },
+{ "BLKRRPART", 0x0000125f },
+{ "BLKGETSIZE", 0x00001260 },
+{ "BLKFLSBUF", 0x00001261 },
+{ "BLKRASET", 0x00001262 },
+{ "BLKRAGET", 0x00001263 },
+{ "BLKFRASET", 0x00001264 },
+{ "BLKFRAGET", 0x00001265 },
+{ "BLKSECTSET", 0x00001266 },
+{ "BLKSECTGET", 0x00001267 },
+{ "BLKSSZGET", 0x00001268 },
+{ "BLKPG", 0x00001269 },
+{ "BLKTRACESTART", 0x00001274 },
+{ "BLKTRACESTOP", 0x00001275 },
+{ "BLKTRACETEARDOWN", 0x00001276 },
+{ "BLKDISCARD", 0x00001277 },
+{ "BLKIOMIN", 0x00001278 },
+{ "BLKIOOPT", 0x00001279 },
+{ "BLKALIGNOFF", 0x0000127a },
+{ "BLKPBSZGET", 0x0000127b },
+{ "BLKDISCARDZEROES", 0x0000127c },
+{ "BLKSECDISCARD", 0x0000127d },
+{ "BLKROTATIONAL", 0x0000127e },
+{ "BLKZEROOUT", 0x0000127f },
+{ "IB_USER_MAD_ENABLE_PKEY", 0x00001b03 },
+{ "HFI1_IOCTL_CREDIT_UPD", 0x00001be6 },
+{ "HFI1_IOCTL_CTXT_RESET", 0x00001bec },
+{ "SG_SET_TIMEOUT", 0x00002201 },
+{ "SG_GET_TIMEOUT", 0x00002202 },
+{ "SG_EMULATED_HOST", 0x00002203 },
+{ "SG_SET_TRANSFORM", 0x00002204 },
+{ "SG_GET_TRANSFORM", 0x00002205 },
+{ "SG_GET_COMMAND_Q", 0x00002270 },
+{ "SG_SET_COMMAND_Q", 0x00002271 },
+{ "SG_GET_RESERVED_SIZE", 0x00002272 },
+{ "SG_SET_RESERVED_SIZE", 0x00002275 },
+{ "SG_GET_SCSI_ID", 0x00002276 },
+{ "SG_SET_FORCE_LOW_DMA", 0x00002279 },
+{ "SG_GET_LOW_DMA", 0x0000227a },
+{ "SG_SET_FORCE_PACK_ID", 0x0000227b },
+{ "SG_GET_PACK_ID", 0x0000227c },
+{ "SG_GET_NUM_WAITING", 0x0000227d },
+{ "SG_SET_DEBUG", 0x0000227e },
+{ "SG_GET_SG_TABLESIZE", 0x0000227f },
+{ "SG_GET_VERSION_NUM", 0x00002282 },
+{ "SG_NEXT_CMD_LEN", 0x00002283 },
+{ "SG_SCSI_RESET", 0x00002284 },
+{ "SG_IO", 0x00002285 },
+{ "SG_GET_REQUEST_TABLE", 0x00002286 },
+{ "SG_SET_KEEP_ORPHAN", 0x00002287 },
+{ "SG_GET_KEEP_ORPHAN", 0x00002288 },
+{ "SG_GET_ACCESS_COUNT", 0x00002289 },
+{ "FW_CDEV_IOC_GET_SPEED", 0x00002311 },
+{ "PERF_EVENT_IOC_ENABLE", 0x00002400 },
+{ "PERF_EVENT_IOC_DISABLE", 0x00002401 },
+{ "PERF_EVENT_IOC_REFRESH", 0x00002402 },
+{ "PERF_EVENT_IOC_RESET", 0x00002403 },
+{ "PERF_EVENT_IOC_SET_OUTPUT", 0x00002405 },
+{ "SNAPSHOT_FREEZE", 0x00003301 },
+{ "SNAPSHOT_UNFREEZE", 0x00003302 },
+{ "SNAPSHOT_ATOMIC_RESTORE", 0x00003304 },
+{ "SNAPSHOT_FREE", 0x00003305 },
+{ "SNAPSHOT_FREE_SWAP_PAGES", 0x00003309 },
+{ "SNAPSHOT_S2RAM", 0x0000330b },
+{ "SNAPSHOT_PLATFORM_SUPPORT", 0x0000330f },
+{ "SNAPSHOT_POWER_OFF", 0x00003310 },
+{ "SNAPSHOT_PREF_IMAGE_SIZE", 0x00003312 },
+{ "VFIO_GET_API_VERSION", 0x00003b64 },
+{ "VFIO_CHECK_EXTENSION", 0x00003b65 },
+{ "VFIO_SET_IOMMU", 0x00003b66 },
+{ "VFIO_GROUP_GET_STATUS", 0x00003b67 },
+{ "VFIO_GROUP_SET_CONTAINER", 0x00003b68 },
+{ "VFIO_GROUP_UNSET_CONTAINER", 0x00003b69 },
+{ "VFIO_GROUP_GET_DEVICE_FD", 0x00003b6a },
+{ "VFIO_DEVICE_GET_INFO", 0x00003b6b },
+{ "VFIO_DEVICE_GET_REGION_INFO", 0x00003b6c },
+{ "VFIO_DEVICE_GET_IRQ_INFO", 0x00003b6d },
+{ "VFIO_DEVICE_SET_IRQS", 0x00003b6e },
+{ "VFIO_DEVICE_RESET", 0x00003b6f },
+{ "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", 0x00003b70 },
+{ "VFIO_IOMMU_GET_INFO", 0x00003b70 },
+{ "VFIO_IOMMU_SPAPR_TCE_GET_INFO", 0x00003b70 },
+{ "VFIO_DEVICE_PCI_HOT_RESET", 0x00003b71 },
+{ "VFIO_IOMMU_MAP_DMA", 0x00003b71 },
+{ "VFIO_IOMMU_UNMAP_DMA", 0x00003b72 },
+{ "VFIO_IOMMU_ENABLE", 0x00003b73 },
+{ "VFIO_IOMMU_DISABLE", 0x00003b74 },
+{ "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", 0x00003b75 },
+{ "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", 0x00003b76 },
+{ "VFIO_IOMMU_SPAPR_TCE_CREATE", 0x00003b77 },
+{ "VFIO_IOMMU_SPAPR_TCE_REMOVE", 0x00003b78 },
+{ "VFIO_EEH_PE_OP", 0x00003b79 },
+{ "AGPIOC_ACQUIRE", 0x00004101 },
+{ "APM_IOC_STANDBY", 0x00004101 },
+{ "AGPIOC_RELEASE", 0x00004102 },
+{ "APM_IOC_SUSPEND", 0x00004102 },
+{ "AGPIOC_CHIPSET_FLUSH", 0x0000410a },
+{ "SNDRV_PCM_IOCTL_HW_FREE", 0x00004112 },
+{ "SNDRV_PCM_IOCTL_HWSYNC", 0x00004122 },
+{ "SNDRV_PCM_IOCTL_PREPARE", 0x00004140 },
+{ "SNDRV_PCM_IOCTL_RESET", 0x00004141 },
+{ "SNDRV_PCM_IOCTL_START", 0x00004142 },
+{ "SNDRV_PCM_IOCTL_DROP", 0x00004143 },
+{ "SNDRV_PCM_IOCTL_DRAIN", 0x00004144 },
+{ "SNDRV_PCM_IOCTL_RESUME", 0x00004147 },
+{ "SNDRV_PCM_IOCTL_XRUN", 0x00004148 },
+{ "SNDRV_PCM_IOCTL_UNLINK", 0x00004161 },
+{ "IOCTL_XENBUS_BACKEND_EVTCHN", 0x00004200 },
+{ "PMU_IOC_SLEEP", 0x00004200 },
+{ "IOCTL_XENBUS_BACKEND_SETUP", 0x00004201 },
+{ "CCISS_REVALIDVOLS", 0x0000420a },
+{ "CCISS_DEREGDISK", 0x0000420c },
+{ "CCISS_REGNEWD", 0x0000420e },
+{ "CCISS_RESCANDISK", 0x00004210 },
+{ "SNDCTL_COPR_RESET", 0x00004300 },
+{ "SNDRV_COMPRESS_PAUSE", 0x00004330 },
+{ "SNDRV_COMPRESS_RESUME", 0x00004331 },
+{ "SNDRV_COMPRESS_START", 0x00004332 },
+{ "SNDRV_COMPRESS_STOP", 0x00004333 },
+{ "SNDRV_COMPRESS_DRAIN", 0x00004334 },
+{ "SNDRV_COMPRESS_NEXT_TRACK", 0x00004335 },
+{ "SNDRV_COMPRESS_PARTIAL_DRAIN", 0x00004336 },
+{ "IOCTL_EVTCHN_RESET", 0x00004505 },
+{ "FBIOGET_VSCREENINFO", 0x00004600 },
+{ "FBIOPUT_VSCREENINFO", 0x00004601 },
+{ "FBIOGET_FSCREENINFO", 0x00004602 },
+{ "FBIOGETCMAP", 0x00004604 },
+{ "FBIOPUTCMAP", 0x00004605 },
+{ "FBIOPAN_DISPLAY", 0x00004606 },
+{ "FBIOGET_CON2FBMAP", 0x0000460f },
+{ "FBIOPUT_CON2FBMAP", 0x00004610 },
+{ "FBIOBLANK", 0x00004611 },
+{ "FBIO_ALLOC", 0x00004613 },
+{ "FBIO_FREE", 0x00004614 },
+{ "FBIOGET_GLYPH", 0x00004615 },
+{ "FBIOGET_HWCINFO", 0x00004616 },
+{ "FBIOPUT_MODEINFO", 0x00004617 },
+{ "FBIOGET_DISPINFO", 0x00004618 },
+{ "FBIO_WAITEVENT", 0x00004688 },
+{ "GSMIOC_DISABLE_NET", 0x00004703 },
+{ "HIDIOCAPPLICATION", 0x00004802 },
+{ "HIDIOCINITREPORT", 0x00004805 },
+{ "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", 0x00004812 },
+{ "SNDRV_SB_CSP_IOCTL_STOP", 0x00004814 },
+{ "SNDRV_SB_CSP_IOCTL_PAUSE", 0x00004815 },
+{ "SNDRV_SB_CSP_IOCTL_RESTART", 0x00004816 },
+{ "SNDRV_DM_FM_IOCTL_RESET", 0x00004821 },
+{ "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", 0x00004840 },
+{ "SNDRV_EMU10K1_IOCTL_STOP", 0x00004880 },
+{ "SNDRV_EMU10K1_IOCTL_CONTINUE", 0x00004881 },
+{ "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", 0x00004882 },
+{ "SNDRV_EMUX_IOCTL_RESET_SAMPLES", 0x00004882 },
+{ "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", 0x00004883 },
+{ "SNDRV_FIREWIRE_IOCTL_LOCK", 0x000048f9 },
+{ "SNDRV_FIREWIRE_IOCTL_UNLOCK", 0x000048fa },
+{ "IIOCNETAIF", 0x00004901 },
+{ "IIOCNETDIF", 0x00004902 },
+{ "IIOCNETSCF", 0x00004903 },
+{ "IIOCNETGCF", 0x00004904 },
+{ "IIOCNETANM", 0x00004905 },
+{ "IIOCNETDNM", 0x00004906 },
+{ "IIOCNETGNM", 0x00004907 },
+{ "IIOCGETSET", 0x00004908 },
+{ "IIOCSETSET", 0x00004909 },
+{ "IIOCSETVER", 0x0000490a },
+{ "IIOCNETHUP", 0x0000490b },
+{ "IIOCSETGST", 0x0000490c },
+{ "IIOCSETBRJ", 0x0000490d },
+{ "IIOCSIGPRF", 0x0000490e },
+{ "IIOCGETPRF", 0x0000490f },
+{ "IIOCSETPRF", 0x00004910 },
+{ "IIOCGETMAP", 0x00004911 },
+{ "IIOCSETMAP", 0x00004912 },
+{ "IIOCNETASL", 0x00004913 },
+{ "IIOCNETDIL", 0x00004914 },
+{ "IIOCGETCPS", 0x00004915 },
+{ "IIOCGETDVR", 0x00004916 },
+{ "IIOCNETLCR", 0x00004917 },
+{ "IIOCNETDWRSET", 0x00004918 },
+{ "IIOCNETALN", 0x00004920 },
+{ "IIOCNETDLN", 0x00004921 },
+{ "IIOCNETGPN", 0x00004922 },
+{ "IIOCDBGVAR", 0x0000497f },
+{ "IIOCDRVCTL", 0x00004980 },
+{ "ION_IOC_TEST_SET_FD", 0x000049f0 },
+{ "KIOCSOUND", 0x00004b2f },
+{ "KDMKTONE", 0x00004b30 },
+{ "KDGETLED", 0x00004b31 },
+{ "KDSETLED", 0x00004b32 },
+{ "KDGKBTYPE", 0x00004b33 },
+{ "KDADDIO", 0x00004b34 },
+{ "KDDELIO", 0x00004b35 },
+{ "KDENABIO", 0x00004b36 },
+{ "KDDISABIO", 0x00004b37 },
+{ "KDSETMODE", 0x00004b3a },
+{ "KDGETMODE", 0x00004b3b },
+{ "KDMAPDISP", 0x00004b3c },
+{ "KDUNMAPDISP", 0x00004b3d },
+{ "GIO_SCRNMAP", 0x00004b40 },
+{ "PIO_SCRNMAP", 0x00004b41 },
+{ "KDGKBMODE", 0x00004b44 },
+{ "KDSKBMODE", 0x00004b45 },
+{ "KDGKBENT", 0x00004b46 },
+{ "KDSKBENT", 0x00004b47 },
+{ "KDGKBSENT", 0x00004b48 },
+{ "KDSKBSENT", 0x00004b49 },
+{ "KDGKBDIACR", 0x00004b4a },
+{ "KDSKBDIACR", 0x00004b4b },
+{ "KDGETKEYCODE", 0x00004b4c },
+{ "KDSETKEYCODE", 0x00004b4d },
+{ "KDSIGACCEPT", 0x00004b4e },
+{ "KDKBDREP", 0x00004b52 },
+{ "GIO_FONT", 0x00004b60 },
+{ "PIO_FONT", 0x00004b61 },
+{ "KDGKBMETA", 0x00004b62 },
+{ "KDSKBMETA", 0x00004b63 },
+{ "KDGKBLED", 0x00004b64 },
+{ "KDSKBLED", 0x00004b65 },
+{ "GIO_UNIMAP", 0x00004b66 },
+{ "PIO_UNIMAP", 0x00004b67 },
+{ "PIO_UNIMAPCLR", 0x00004b68 },
+{ "GIO_UNISCRNMAP", 0x00004b69 },
+{ "PIO_UNISCRNMAP", 0x00004b6a },
+{ "GIO_FONTX", 0x00004b6b },
+{ "PIO_FONTX", 0x00004b6c },
+{ "PIO_FONTRESET", 0x00004b6d },
+{ "GIO_CMAP", 0x00004b70 },
+{ "PIO_CMAP", 0x00004b71 },
+{ "KDFONTOP", 0x00004b72 },
+{ "KDGKBDIACRUC", 0x00004bfa },
+{ "KDSKBDIACRUC", 0x00004bfb },
+{ "LOOP_SET_FD", 0x00004c00 },
+{ "LOOP_CLR_FD", 0x00004c01 },
+{ "LOOP_SET_STATUS", 0x00004c02 },
+{ "LOOP_GET_STATUS", 0x00004c03 },
+{ "LOOP_SET_STATUS64", 0x00004c04 },
+{ "LOOP_GET_STATUS64", 0x00004c05 },
+{ "LOOP_CHANGE_FD", 0x00004c06 },
+{ "LOOP_SET_CAPACITY", 0x00004c07 },
+{ "LOOP_SET_DIRECT_IO", 0x00004c08 },
+{ "LOOP_CTL_ADD", 0x00004c80 },
+{ "LOOP_CTL_REMOVE", 0x00004c81 },
+{ "LOOP_CTL_GET_FREE", 0x00004c82 },
+{ "MTDFILEMODE", 0x00004d13 },
+{ "NVME_IOCTL_ID", 0x00004e40 },
+{ "NVME_IOCTL_RESET", 0x00004e44 },
+{ "NVME_IOCTL_SUBSYS_RESET", 0x00004e45 },
+{ "NVME_IOCTL_RESCAN", 0x00004e46 },
+{ "UBI_IOCVOLRMBLK", 0x00004f08 },
+{ "OMAPFB_SYNC_GFX", 0x00004f25 },
+{ "OMAPFB_VSYNC", 0x00004f26 },
+{ "OMAPFB_WAITFORVSYNC", 0x00004f39 },
+{ "OMAPFB_WAITFORGO", 0x00004f3c },
+{ "SNDCTL_DSP_RESET", 0x00005000 },
+{ "SNDCTL_DSP_SYNC", 0x00005001 },
+{ "SNDCTL_DSP_POST", 0x00005008 },
+{ "SNDCTL_DSP_NONBLOCK", 0x0000500e },
+{ "SNDCTL_DSP_SETSYNCRO", 0x00005015 },
+{ "SNDCTL_DSP_SETDUPLEX", 0x00005016 },
+{ "SNDCTL_SEQ_RESET", 0x00005100 },
+{ "SNDCTL_SEQ_SYNC", 0x00005101 },
+{ "SNDCTL_SEQ_PANIC", 0x00005111 },
+{ "RFKILL_IOCTL_NOINPUT", 0x00005201 },
+{ "RNDZAPENTCNT", 0x00005204 },
+{ "RNDCLEARPOOL", 0x00005206 },
+{ "CDROMPAUSE", 0x00005301 },
+{ "CDROMRESUME", 0x00005302 },
+{ "CDROMPLAYMSF", 0x00005303 },
+{ "CDROMPLAYTRKIND", 0x00005304 },
+{ "CDROMREADTOCHDR", 0x00005305 },
+{ "CDROMREADTOCENTRY", 0x00005306 },
+{ "CDROMSTOP", 0x00005307 },
+{ "CDROMSTART", 0x00005308 },
+{ "CDROMEJECT", 0x00005309 },
+{ "CDROMVOLCTRL", 0x0000530a },
+{ "CDROMSUBCHNL", 0x0000530b },
+{ "CDROMREADMODE2", 0x0000530c },
+{ "CDROMREADMODE1", 0x0000530d },
+{ "CDROMREADAUDIO", 0x0000530e },
+{ "CDROMEJECT_SW", 0x0000530f },
+{ "CDROMMULTISESSION", 0x00005310 },
+{ "CDROM_GET_MCN", 0x00005311 },
+{ "CDROMRESET", 0x00005312 },
+{ "CDROMVOLREAD", 0x00005313 },
+{ "CDROMREADRAW", 0x00005314 },
+{ "CDROMREADCOOKED", 0x00005315 },
+{ "CDROMSEEK", 0x00005316 },
+{ "CDROMPLAYBLK", 0x00005317 },
+{ "CDROMREADALL", 0x00005318 },
+{ "CDROMCLOSETRAY", 0x00005319 },
+{ "CDROMGETSPINDOWN", 0x0000531d },
+{ "CDROMSETSPINDOWN", 0x0000531e },
+{ "CDROM_SET_OPTIONS", 0x00005320 },
+{ "CDROM_CLEAR_OPTIONS", 0x00005321 },
+{ "CDROM_SELECT_SPEED", 0x00005322 },
+{ "CDROM_SELECT_DISC", 0x00005323 },
+{ "CDROM_MEDIA_CHANGED", 0x00005325 },
+{ "CDROM_DRIVE_STATUS", 0x00005326 },
+{ "CDROM_DISC_STATUS", 0x00005327 },
+{ "CDROM_CHANGER_NSLOTS", 0x00005328 },
+{ "CDROM_LOCKDOOR", 0x00005329 },
+{ "CDROM_DEBUG", 0x00005330 },
+{ "CDROM_GET_CAPABILITY", 0x00005331 },
+{ "SCSI_IOCTL_DOORLOCK", 0x00005380 },
+{ "SCSI_IOCTL_DOORUNLOCK", 0x00005381 },
+{ "CDROMAUDIOBUFSIZ", 0x00005382 },
+{ "SCSI_IOCTL_GET_IDLUN", 0x00005382 },
+{ "SCSI_IOCTL_PROBE_HOST", 0x00005385 },
+{ "SCSI_IOCTL_GET_BUS_NUMBER", 0x00005386 },
+{ "SCSI_IOCTL_GET_PCI", 0x00005387 },
+{ "DVD_READ_STRUCT", 0x00005390 },
+{ "DVD_WRITE_STRUCT", 0x00005391 },
+{ "DVD_AUTH", 0x00005392 },
+{ "CDROM_SEND_PACKET", 0x00005393 },
+{ "CDROM_NEXT_WRITABLE", 0x00005394 },
+{ "CDROM_LAST_WRITTEN", 0x00005395 },
+{ "TCGETS", 0x00005401 },
+{ "SNDCTL_TMR_START", 0x00005402 },
+{ "TCSETS", 0x00005402 },
+{ "SNDCTL_TMR_STOP", 0x00005403 },
+{ "TCSETSW", 0x00005403 },
+{ "SNDCTL_TMR_CONTINUE", 0x00005404 },
+{ "TCSETSF", 0x00005404 },
+{ "TCGETA", 0x00005405 },
+{ "TCSETA", 0x00005406 },
+{ "TCSETAW", 0x00005407 },
+{ "TCSETAF", 0x00005408 },
+{ "TCSBRK", 0x00005409 },
+{ "TCXONC", 0x0000540a },
+{ "TCFLSH", 0x0000540b },
+{ "TIOCEXCL", 0x0000540c },
+{ "TIOCNXCL", 0x0000540d },
+{ "TIOCSCTTY", 0x0000540e },
+{ "TIOCGPGRP", 0x0000540f },
+{ "TIOCSPGRP", 0x00005410 },
+{ "TIOCOUTQ", 0x00005411 },
+{ "TIOCSTI", 0x00005412 },
+{ "TIOCGWINSZ", 0x00005413 },
+{ "TIOCSWINSZ", 0x00005414 },
+{ "TIOCMGET", 0x00005415 },
+{ "TIOCMBIS", 0x00005416 },
+{ "TIOCMBIC", 0x00005417 },
+{ "TIOCMSET", 0x00005418 },
+{ "TIOCGSOFTCAR", 0x00005419 },
+{ "TIOCSSOFTCAR", 0x0000541a },
+{ "FIONREAD", 0x0000541b },
+{ "TIOCLINUX", 0x0000541c },
+{ "TIOCCONS", 0x0000541d },
+{ "TIOCGSERIAL", 0x0000541e },
+{ "TIOCSSERIAL", 0x0000541f },
+{ "TIOCPKT", 0x00005420 },
+{ "FIONBIO", 0x00005421 },
+{ "TIOCNOTTY", 0x00005422 },
+{ "TIOCSETD", 0x00005423 },
+{ "TIOCGETD", 0x00005424 },
+{ "TCSBRKP", 0x00005425 },
+{ "TIOCSBRK", 0x00005427 },
+{ "TIOCCBRK", 0x00005428 },
+{ "TIOCGSID", 0x00005429 },
+{ "TIOCGRS485", 0x0000542e },
+{ "TIOCSRS485", 0x0000542f },
+{ "TCGETX", 0x00005432 },
+{ "TCSETX", 0x00005433 },
+{ "TCSETXF", 0x00005434 },
+{ "TCSETXW", 0x00005435 },
+{ "TIOCVHANGUP", 0x00005437 },
+{ "FIONCLEX", 0x00005450 },
+{ "FIOCLEX", 0x00005451 },
+{ "FIOASYNC", 0x00005452 },
+{ "TIOCSERCONFIG", 0x00005453 },
+{ "TIOCSERGWILD", 0x00005454 },
+{ "TIOCSERSWILD", 0x00005455 },
+{ "TIOCGLCKTRMIOS", 0x00005456 },
+{ "TIOCSLCKTRMIOS", 0x00005457 },
+{ "TIOCSERGSTRUCT", 0x00005458 },
+{ "TIOCSERGETLSR", 0x00005459 },
+{ "TIOCSERGETMULTI", 0x0000545a },
+{ "TIOCSERSETMULTI", 0x0000545b },
+{ "TIOCMIWAIT", 0x0000545c },
+{ "TIOCGICOUNT", 0x0000545d },
+{ "FIOQSIZE", 0x00005460 },
+{ "SNDRV_TIMER_IOCTL_START", 0x000054a0 },
+{ "SNDRV_TIMER_IOCTL_STOP", 0x000054a1 },
+{ "SNDRV_TIMER_IOCTL_CONTINUE", 0x000054a2 },
+{ "SNDRV_TIMER_IOCTL_PAUSE", 0x000054a3 },
+{ "UI_DEV_CREATE", 0x00005501 },
+{ "UI_DEV_DESTROY", 0x00005502 },
+{ "USBDEVFS_DISCARDURB", 0x0000550b },
+{ "USBDEVFS_RESET", 0x00005514 },
+{ "USBDEVFS_DISCONNECT", 0x00005516 },
+{ "USBDEVFS_CONNECT", 0x00005517 },
+{ "VT_OPENQRY", 0x00005600 },
+{ "VIDIOC_RESERVED", 0x00005601 },
+{ "VT_GETMODE", 0x00005601 },
+{ "VT_SETMODE", 0x00005602 },
+{ "VT_GETSTATE", 0x00005603 },
+{ "VT_SENDSIG", 0x00005604 },
+{ "VT_RELDISP", 0x00005605 },
+{ "VT_ACTIVATE", 0x00005606 },
+{ "VT_WAITACTIVE", 0x00005607 },
+{ "VT_DISALLOCATE", 0x00005608 },
+{ "VT_RESIZE", 0x00005609 },
+{ "VT_RESIZEX", 0x0000560a },
+{ "VT_LOCKSWITCH", 0x0000560b },
+{ "VT_UNLOCKSWITCH", 0x0000560c },
+{ "VT_GETHIFONTMASK", 0x0000560d },
+{ "VT_WAITEVENT", 0x0000560e },
+{ "VT_SETACTIVATE", 0x0000560f },
+{ "VIDIOC_LOG_STATUS", 0x00005646 },
+{ "ADV7842_CMD_RAM_TEST", 0x000056c0 },
+{ "USBTMC_IOCTL_INDICATOR_PULSE", 0x00005b01 },
+{ "USBTMC_IOCTL_CLEAR", 0x00005b02 },
+{ "USBTMC_IOCTL_ABORT_BULK_OUT", 0x00005b03 },
+{ "USBTMC_IOCTL_ABORT_BULK_IN", 0x00005b04 },
+{ "USBTMC_IOCTL_CLEAR_OUT_HALT", 0x00005b06 },
+{ "USBTMC_IOCTL_CLEAR_IN_HALT", 0x00005b07 },
+{ "USBTMC488_IOCTL_GOTO_LOCAL", 0x00005b14 },
+{ "USBTMC488_IOCTL_LOCAL_LOCKOUT", 0x00005b15 },
+{ "NS_ADJBUFLEV", 0x00006163 },
+{ "SIOCSIFATMTCP", 0x00006180 },
+{ "ATMTCP_CREATE", 0x0000618e },
+{ "ATMTCP_REMOVE", 0x0000618f },
+{ "ATMLEC_CTRL", 0x000061d0 },
+{ "ATMLEC_DATA", 0x000061d1 },
+{ "ATMLEC_MCAST", 0x000061d2 },
+{ "ATMMPC_CTRL", 0x000061d8 },
+{ "ATMMPC_DATA", 0x000061d9 },
+{ "SIOCMKCLIP", 0x000061e0 },
+{ "ATMARPD_CTRL", 0x000061e1 },
+{ "ATMARP_MKIP", 0x000061e2 },
+{ "ATMARP_SETENTRY", 0x000061e3 },
+{ "ATMARP_ENCAP", 0x000061e5 },
+{ "ATMSIGD_CTRL", 0x000061f0 },
+{ "BT819_FIFO_RESET_LOW", 0x00006200 },
+{ "BT819_FIFO_RESET_HIGH", 0x00006201 },
+{ "CM_IOCSRDR", 0x00006303 },
+{ "CM_IOCARDOFF", 0x00006304 },
+{ "BC_REGISTER_LOOPER", 0x0000630b },
+{ "BC_ENTER_LOOPER", 0x0000630c },
+{ "BC_EXIT_LOOPER", 0x0000630d },
+{ "CHIOINITELEM", 0x00006311 },
+{ "KCOV_ENABLE", 0x00006364 },
+{ "KCOV_DISABLE", 0x00006365 },
+{ "DRM_IOCTL_SET_MASTER", 0x0000641e },
+{ "DRM_IOCTL_DROP_MASTER", 0x0000641f },
+{ "DRM_IOCTL_AGP_ACQUIRE", 0x00006430 },
+{ "DRM_IOCTL_AGP_RELEASE", 0x00006431 },
+{ "DRM_IOCTL_I915_FLUSH", 0x00006441 },
+{ "DRM_IOCTL_R128_CCE_START", 0x00006441 },
+{ "DRM_IOCTL_RADEON_CP_START", 0x00006441 },
+{ "DRM_IOCTL_I915_FLIP", 0x00006442 },
+{ "DRM_IOCTL_MGA_RESET", 0x00006442 },
+{ "DRM_IOCTL_I810_FLUSH", 0x00006443 },
+{ "DRM_IOCTL_MGA_SWAP", 0x00006443 },
+{ "DRM_IOCTL_R128_CCE_RESET", 0x00006443 },
+{ "DRM_IOCTL_RADEON_CP_RESET", 0x00006443 },
+{ "DRM_IOCTL_I810_GETAGE", 0x00006444 },
+{ "DRM_IOCTL_R128_CCE_IDLE", 0x00006444 },
+{ "DRM_IOCTL_RADEON_CP_IDLE", 0x00006444 },
+{ "DRM_IOCTL_RADEON_RESET", 0x00006445 },
+{ "DRM_IOCTL_I810_SWAP", 0x00006446 },
+{ "DRM_IOCTL_R128_RESET", 0x00006446 },
+{ "DRM_IOCTL_R128_SWAP", 0x00006447 },
+{ "DRM_IOCTL_RADEON_SWAP", 0x00006447 },
+{ "DRM_IOCTL_I810_DOCOPY", 0x00006448 },
+{ "DRM_IOCTL_VIA_FLUSH", 0x00006449 },
+{ "DRM_IOCTL_I810_FSTATUS", 0x0000644a },
+{ "DRM_IOCTL_I810_OV0FLIP", 0x0000644b },
+{ "DRM_IOCTL_I810_RSTATUS", 0x0000644d },
+{ "DRM_IOCTL_I810_FLIP", 0x0000644e },
+{ "DRM_IOCTL_RADEON_FLIP", 0x00006452 },
+{ "DRM_IOCTL_R128_FLIP", 0x00006453 },
+{ "DRM_IOCTL_I915_GEM_THROTTLE", 0x00006458 },
+{ "DRM_IOCTL_RADEON_CP_RESUME", 0x00006458 },
+{ "DRM_IOCTL_I915_GEM_ENTERVT", 0x00006459 },
+{ "DRM_IOCTL_I915_GEM_LEAVEVT", 0x0000645a },
+{ "S5P_FIMC_TX_END_NOTIFY", 0x00006500 },
+{ "FUNCTIONFS_FIFO_STATUS", 0x00006701 },
+{ "GADGETFS_FIFO_STATUS", 0x00006701 },
+{ "FUNCTIONFS_FIFO_FLUSH", 0x00006702 },
+{ "GADGETFS_FIFO_FLUSH", 0x00006702 },
+{ "FUNCTIONFS_CLEAR_HALT", 0x00006703 },
+{ "GADGETFS_CLEAR_HALT", 0x00006703 },
+{ "FUNCTIONFS_INTERFACE_REVMAP", 0x00006780 },
+{ "FUNCTIONFS_ENDPOINT_REVMAP", 0x00006781 },
+{ "HPET_IE_ON", 0x00006801 },
+{ "HPET_IE_OFF", 0x00006802 },
+{ "HPET_EPI", 0x00006804 },
+{ "HPET_DPI", 0x00006805 },
+{ "LIRC_NOTIFY_DECODE", 0x00006920 },
+{ "LIRC_SETUP_START", 0x00006921 },
+{ "LIRC_SETUP_END", 0x00006922 },
+{ "KYRO_IOCTL_OVERLAY_CREATE", 0x00006b00 },
+{ "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", 0x00006b01 },
+{ "KYRO_IOCTL_SET_VIDEO_MODE", 0x00006b02 },
+{ "KYRO_IOCTL_UVSTRIDE", 0x00006b03 },
+{ "KYRO_IOCTL_OVERLAY_OFFSET", 0x00006b04 },
+{ "KYRO_IOCTL_STRIDE", 0x00006b05 },
+{ "HSC_RESET", 0x00006b10 },
+{ "HSC_SET_PM", 0x00006b11 },
+{ "HSC_SEND_BREAK", 0x00006b12 },
+{ "MMTIMER_GETOFFSET", 0x00006d00 },
+{ "MGSL_IOCSTXIDLE", 0x00006d02 },
+{ "MGSL_IOCGTXIDLE", 0x00006d03 },
+{ "MGSL_IOCTXENABLE", 0x00006d04 },
+{ "MMTIMER_GETBITS", 0x00006d04 },
+{ "MGSL_IOCRXENABLE", 0x00006d05 },
+{ "MGSL_IOCTXABORT", 0x00006d06 },
+{ "MMTIMER_MMAPAVAIL", 0x00006d06 },
+{ "MGSL_IOCGSTATS", 0x00006d07 },
+{ "MGSL_IOCLOOPTXDONE", 0x00006d09 },
+{ "MGSL_IOCSIF", 0x00006d0a },
+{ "MGSL_IOCGIF", 0x00006d0b },
+{ "MGSL_IOCCLRMODCOUNT", 0x00006d0f },
+{ "MGSL_IOCSXSYNC", 0x00006d13 },
+{ "MGSL_IOCGXSYNC", 0x00006d14 },
+{ "MGSL_IOCSXCTRL", 0x00006d15 },
+{ "MGSL_IOCGXCTRL", 0x00006d16 },
+{ "NCP_IOC_CONN_LOGGED_IN", 0x00006e03 },
+{ "AUDIO_STOP", 0x00006f01 },
+{ "AUDIO_PLAY", 0x00006f02 },
+{ "AUDIO_PAUSE", 0x00006f03 },
+{ "AUDIO_CONTINUE", 0x00006f04 },
+{ "AUDIO_SELECT_SOURCE", 0x00006f05 },
+{ "AUDIO_SET_MUTE", 0x00006f06 },
+{ "AUDIO_SET_AV_SYNC", 0x00006f07 },
+{ "AUDIO_SET_BYPASS_MODE", 0x00006f08 },
+{ "AUDIO_CHANNEL_SELECT", 0x00006f09 },
+{ "AUDIO_CLEAR_BUFFER", 0x00006f0c },
+{ "AUDIO_SET_ID", 0x00006f0d },
+{ "AUDIO_SET_STREAMTYPE", 0x00006f0f },
+{ "AUDIO_SET_EXT_ID", 0x00006f10 },
+{ "AUDIO_BILINGUAL_CHANNEL_SELECT", 0x00006f14 },
+{ "VIDEO_STOP", 0x00006f15 },
+{ "VIDEO_PLAY", 0x00006f16 },
+{ "VIDEO_FREEZE", 0x00006f17 },
+{ "VIDEO_CONTINUE", 0x00006f18 },
+{ "VIDEO_SELECT_SOURCE", 0x00006f19 },
+{ "VIDEO_SET_BLANK", 0x00006f1a },
+{ "VIDEO_SET_DISPLAY_FORMAT", 0x00006f1d },
+{ "VIDEO_FAST_FORWARD", 0x00006f1f },
+{ "VIDEO_SLOWMOTION", 0x00006f20 },
+{ "VIDEO_CLEAR_BUFFER", 0x00006f22 },
+{ "VIDEO_SET_ID", 0x00006f23 },
+{ "VIDEO_SET_STREAMTYPE", 0x00006f24 },
+{ "VIDEO_SET_FORMAT", 0x00006f25 },
+{ "VIDEO_SET_SYSTEM", 0x00006f26 },
+{ "DMX_START", 0x00006f29 },
+{ "DMX_STOP", 0x00006f2a },
+{ "DMX_SET_BUFFER_SIZE", 0x00006f2d },
+{ "NET_REMOVE_IF", 0x00006f35 },
+{ "VIDEO_SET_ATTRIBUTES", 0x00006f35 },
+{ "FE_DISEQC_RESET_OVERLOAD", 0x00006f3e },
+{ "FE_DISEQC_SEND_BURST", 0x00006f41 },
+{ "FE_SET_TONE", 0x00006f42 },
+{ "FE_SET_VOLTAGE", 0x00006f43 },
+{ "FE_ENABLE_HIGH_LNB_VOLTAGE", 0x00006f44 },
+{ "FE_DISHNETWORK_SEND_LEGACY_CMD", 0x00006f50 },
+{ "FE_SET_FRONTEND_TUNE_MODE", 0x00006f51 },
+{ "CA_RESET", 0x00006f80 },
+{ "RTC_AIE_ON", 0x00007001 },
+{ "RTC_AIE_OFF", 0x00007002 },
+{ "RTC_UIE_ON", 0x00007003 },
+{ "PHN_NOT_OH", 0x00007004 },
+{ "RTC_UIE_OFF", 0x00007004 },
+{ "RTC_PIE_ON", 0x00007005 },
+{ "RTC_PIE_OFF", 0x00007006 },
+{ "RTC_WIE_ON", 0x0000700f },
+{ "RTC_WIE_OFF", 0x00007010 },
+{ "RTC_VL_CLR", 0x00007014 },
+{ "NVRAM_INIT", 0x00007040 },
+{ "NVRAM_SETCKS", 0x00007041 },
+{ "PPCLAIM", 0x0000708b },
+{ "PPRELEASE", 0x0000708c },
+{ "PPYIELD", 0x0000708d },
+{ "PPEXCL", 0x0000708f },
+{ "PHONE_CAPABILITIES", 0x00007180 },
+{ "PHONE_RING", 0x00007183 },
+{ "PHONE_HOOKSTATE", 0x00007184 },
+{ "OLD_PHONE_RING_START", 0x00007187 },
+{ "PHONE_RING_STOP", 0x00007188 },
+{ "PHONE_REC_START", 0x0000718a },
+{ "PHONE_REC_STOP", 0x0000718b },
+{ "PHONE_REC_LEVEL", 0x0000718f },
+{ "PHONE_PLAY_START", 0x00007191 },
+{ "PHONE_PLAY_STOP", 0x00007192 },
+{ "PHONE_PLAY_LEVEL", 0x00007195 },
+{ "PHONE_GET_TONE_ON_TIME", 0x0000719e },
+{ "PHONE_GET_TONE_OFF_TIME", 0x0000719f },
+{ "PHONE_GET_TONE_STATE", 0x000071a0 },
+{ "PHONE_BUSY", 0x000071a1 },
+{ "PHONE_RINGBACK", 0x000071a2 },
+{ "PHONE_DIALTONE", 0x000071a3 },
+{ "PHONE_CPT_STOP", 0x000071a4 },
+{ "PHONE_PSTN_GET_STATE", 0x000071a5 },
+{ "PHONE_PSTN_LINETEST", 0x000071a8 },
+{ "IXJCTL_DSP_RESET", 0x000071c0 },
+{ "IXJCTL_DSP_IDLE", 0x000071c5 },
+{ "IXJCTL_TESTRAM", 0x000071c6 },
+{ "IXJCTL_AEC_STOP", 0x000071cc },
+{ "IXJCTL_AEC_GET_LEVEL", 0x000071cd },
+{ "IXJCTL_PSTN_LINETEST", 0x000071d3 },
+{ "IXJCTL_PLAY_CID", 0x000071d7 },
+{ "IXJCTL_DRYBUFFER_CLEAR", 0x000071e7 },
+{ "BR_OK", 0x00007201 },
+{ "BR_DEAD_REPLY", 0x00007205 },
+{ "BR_TRANSACTION_COMPLETE", 0x00007206 },
+{ "BR_NOOP", 0x0000720c },
+{ "BR_SPAWN_LOOPER", 0x0000720d },
+{ "BR_FINISHED", 0x0000720e },
+{ "BR_FAILED_REPLY", 0x00007211 },
+{ "PPPIOCDISCONN", 0x00007439 },
+{ "PPPIOCXFERUNIT", 0x0000744e },
+{ "MEYEIOC_STILLCAPT", 0x000076c4 },
+{ "ASHMEM_GET_SIZE", 0x00007704 },
+{ "ASHMEM_GET_PROT_MASK", 0x00007706 },
+{ "ASHMEM_GET_PIN_STATUS", 0x00007709 },
+{ "ASHMEM_PURGE_ALL_CACHES", 0x0000770a },
+{ "FIOSETOWN", 0x00008901 },
+{ "SIOCSPGRP", 0x00008902 },
+{ "FIOGETOWN", 0x00008903 },
+{ "SIOCGPGRP", 0x00008904 },
+{ "SIOCATMARK", 0x00008905 },
+{ "SIOCGSTAMP", 0x00008906 },
+{ "SIOCGSTAMPNS", 0x00008907 },
+{ "SIOCADDRT", 0x0000890b },
+{ "SIOCDELRT", 0x0000890c },
+{ "SIOCRTMSG", 0x0000890d },
+{ "SIOCGIFNAME", 0x00008910 },
+{ "SIOCSIFLINK", 0x00008911 },
+{ "SIOCGIFCONF", 0x00008912 },
+{ "SIOCGIFFLAGS", 0x00008913 },
+{ "SIOCSIFFLAGS", 0x00008914 },
+{ "SIOCGIFADDR", 0x00008915 },
+{ "SIOCSIFADDR", 0x00008916 },
+{ "SIOCGIFDSTADDR", 0x00008917 },
+{ "SIOCSIFDSTADDR", 0x00008918 },
+{ "SIOCGIFBRDADDR", 0x00008919 },
+{ "SIOCSIFBRDADDR", 0x0000891a },
+{ "SIOCGIFNETMASK", 0x0000891b },
+{ "SIOCSIFNETMASK", 0x0000891c },
+{ "SIOCGIFMETRIC", 0x0000891d },
+{ "SIOCSIFMETRIC", 0x0000891e },
+{ "SIOCGIFMEM", 0x0000891f },
+{ "SIOCSIFMEM", 0x00008920 },
+{ "SIOCGIFMTU", 0x00008921 },
+{ "SIOCSIFMTU", 0x00008922 },
+{ "SIOCSIFNAME", 0x00008923 },
+{ "SIOCSIFHWADDR", 0x00008924 },
+{ "SIOCGIFENCAP", 0x00008925 },
+{ "SIOCSIFENCAP", 0x00008926 },
+{ "SIOCGIFHWADDR", 0x00008927 },
+{ "SIOCGIFSLAVE", 0x00008929 },
+{ "SIOCSIFSLAVE", 0x00008930 },
+{ "SIOCADDMULTI", 0x00008931 },
+{ "SIOCDELMULTI", 0x00008932 },
+{ "SIOCGIFINDEX", 0x00008933 },
+{ "SIOCSIFPFLAGS", 0x00008934 },
+{ "SIOCGIFPFLAGS", 0x00008935 },
+{ "SIOCDIFADDR", 0x00008936 },
+{ "SIOCSIFHWBROADCAST", 0x00008937 },
+{ "SIOCGIFCOUNT", 0x00008938 },
+{ "SIOCGIFBR", 0x00008940 },
+{ "SIOCSIFBR", 0x00008941 },
+{ "SIOCGIFTXQLEN", 0x00008942 },
+{ "SIOCSIFTXQLEN", 0x00008943 },
+{ "SIOCETHTOOL", 0x00008946 },
+{ "SIOCGMIIPHY", 0x00008947 },
+{ "SIOCGMIIREG", 0x00008948 },
+{ "SIOCSMIIREG", 0x00008949 },
+{ "SIOCWANDEV", 0x0000894a },
+{ "SIOCOUTQNSD", 0x0000894b },
+{ "SIOCDARP", 0x00008953 },
+{ "SIOCGARP", 0x00008954 },
+{ "SIOCSARP", 0x00008955 },
+{ "SIOCDRARP", 0x00008960 },
+{ "SIOCGRARP", 0x00008961 },
+{ "SIOCSRARP", 0x00008962 },
+{ "SIOCGIFMAP", 0x00008970 },
+{ "SIOCSIFMAP", 0x00008971 },
+{ "SIOCADDDLCI", 0x00008980 },
+{ "SIOCDELDLCI", 0x00008981 },
+{ "SIOCGIFVLAN", 0x00008982 },
+{ "SIOCSIFVLAN", 0x00008983 },
+{ "SIOCBONDENSLAVE", 0x00008990 },
+{ "SIOCBONDRELEASE", 0x00008991 },
+{ "SIOCBONDSETHWADDR", 0x00008992 },
+{ "SIOCBONDSLAVEINFOQUERY", 0x00008993 },
+{ "SIOCBONDINFOQUERY", 0x00008994 },
+{ "SIOCBONDCHANGEACTIVE", 0x00008995 },
+{ "SIOCBRADDBR", 0x000089a0 },
+{ "SIOCBRDELBR", 0x000089a1 },
+{ "SIOCBRADDIF", 0x000089a2 },
+{ "SIOCBRDELIF", 0x000089a3 },
+{ "SIOCSHWTSTAMP", 0x000089b0 },
+{ "SIOCGHWTSTAMP", 0x000089b1 },
+{ "SIOCPROTOPRIVATE", 0x000089e0 },
+{ "SIOCDEVPRIVATE", 0x000089f0 },
+{ "SIOCIWFIRST", 0x00008b00 },
+{ "SIOCSIWCOMMIT", 0x00008b00 },
+{ "SIOCGIWNAME", 0x00008b01 },
+{ "SIOCSIWNWID", 0x00008b02 },
+{ "SIOCGIWNWID", 0x00008b03 },
+{ "SIOCSIWFREQ", 0x00008b04 },
+{ "SIOCGIWFREQ", 0x00008b05 },
+{ "SIOCSIWMODE", 0x00008b06 },
+{ "SIOCGIWMODE", 0x00008b07 },
+{ "SIOCSIWSENS", 0x00008b08 },
+{ "SIOCGIWSENS", 0x00008b09 },
+{ "SIOCSIWRANGE", 0x00008b0a },
+{ "SIOCGIWRANGE", 0x00008b0b },
+{ "SIOCSIWPRIV", 0x00008b0c },
+{ "SIOCGIWPRIV", 0x00008b0d },
+{ "SIOCSIWSTATS", 0x00008b0e },
+{ "SIOCGIWSTATS", 0x00008b0f },
+{ "SIOCSIWSPY", 0x00008b10 },
+{ "SIOCGIWSPY", 0x00008b11 },
+{ "SIOCSIWTHRSPY", 0x00008b12 },
+{ "SIOCGIWTHRSPY", 0x00008b13 },
+{ "SIOCSIWAP", 0x00008b14 },
+{ "SIOCGIWAP", 0x00008b15 },
+{ "SIOCSIWMLME", 0x00008b16 },
+{ "SIOCGIWAPLIST", 0x00008b17 },
+{ "SIOCSIWSCAN", 0x00008b18 },
+{ "SIOCGIWSCAN", 0x00008b19 },
+{ "SIOCSIWESSID", 0x00008b1a },
+{ "SIOCGIWESSID", 0x00008b1b },
+{ "SIOCSIWNICKN", 0x00008b1c },
+{ "SIOCGIWNICKN", 0x00008b1d },
+{ "SIOCSIWRATE", 0x00008b20 },
+{ "SIOCGIWRATE", 0x00008b21 },
+{ "SIOCSIWRTS", 0x00008b22 },
+{ "SIOCGIWRTS", 0x00008b23 },
+{ "SIOCSIWFRAG", 0x00008b24 },
+{ "SIOCGIWFRAG", 0x00008b25 },
+{ "SIOCSIWTXPOW", 0x00008b26 },
+{ "SIOCGIWTXPOW", 0x00008b27 },
+{ "SIOCSIWRETRY", 0x00008b28 },
+{ "SIOCGIWRETRY", 0x00008b29 },
+{ "SIOCSIWENCODE", 0x00008b2a },
+{ "SIOCGIWENCODE", 0x00008b2b },
+{ "SIOCSIWPOWER", 0x00008b2c },
+{ "SIOCGIWPOWER", 0x00008b2d },
+{ "SIOCSIWGENIE", 0x00008b30 },
+{ "SIOCGIWGENIE", 0x00008b31 },
+{ "SIOCSIWAUTH", 0x00008b32 },
+{ "SIOCGIWAUTH", 0x00008b33 },
+{ "SIOCSIWENCODEEXT", 0x00008b34 },
+{ "SIOCGIWENCODEEXT", 0x00008b35 },
+{ "SIOCSIWPMKSA", 0x00008b36 },
+{ "SIOCIWFIRSTPRIV", 0x00008be0 },
+{ "SIOCIWLASTPRIV", 0x00008bff },
+{ "AUTOFS_IOC_READY", 0x00009360 },
+{ "AUTOFS_IOC_FAIL", 0x00009361 },
+{ "AUTOFS_IOC_CATATONIC", 0x00009362 },
+{ "BTRFS_IOC_TRANS_START", 0x00009406 },
+{ "BTRFS_IOC_TRANS_END", 0x00009407 },
+{ "BTRFS_IOC_SYNC", 0x00009408 },
+{ "BTRFS_IOC_SCRUB_CANCEL", 0x0000941c },
+{ "BTRFS_IOC_QUOTA_RESCAN_WAIT", 0x0000942e },
+{ "NBD_SET_SOCK", 0x0000ab00 },
+{ "NBD_SET_BLKSIZE", 0x0000ab01 },
+{ "NBD_SET_SIZE", 0x0000ab02 },
+{ "NBD_DO_IT", 0x0000ab03 },
+{ "NBD_CLEAR_SOCK", 0x0000ab04 },
+{ "NBD_CLEAR_QUE", 0x0000ab05 },
+{ "NBD_PRINT_DEBUG", 0x0000ab06 },
+{ "NBD_SET_SIZE_BLOCKS", 0x0000ab07 },
+{ "NBD_DISCONNECT", 0x0000ab08 },
+{ "NBD_SET_TIMEOUT", 0x0000ab09 },
+{ "NBD_SET_FLAGS", 0x0000ab0a },
+{ "RAW_SETBIND", 0x0000ac00 },
+{ "RAW_GETBIND", 0x0000ac01 },
+{ "KVM_GET_API_VERSION", 0x0000ae00 },
+{ "KVM_CREATE_VM", 0x0000ae01 },
+{ "KVM_CHECK_EXTENSION", 0x0000ae03 },
+{ "KVM_GET_VCPU_MMAP_SIZE", 0x0000ae04 },
+{ "KVM_S390_ENABLE_SIE", 0x0000ae06 },
+{ "KVM_CREATE_VCPU", 0x0000ae41 },
+{ "KVM_SET_NR_MMU_PAGES", 0x0000ae44 },
+{ "KVM_GET_NR_MMU_PAGES", 0x0000ae45 },
+{ "KVM_SET_TSS_ADDR", 0x0000ae47 },
+{ "KVM_CREATE_IRQCHIP", 0x0000ae60 },
+{ "KVM_CREATE_PIT", 0x0000ae64 },
+{ "KVM_REINJECT_CONTROL", 0x0000ae71 },
+{ "KVM_SET_BOOT_CPU_ID", 0x0000ae78 },
+{ "KVM_RUN", 0x0000ae80 },
+{ "KVM_S390_INITIAL_RESET", 0x0000ae97 },
+{ "KVM_NMI", 0x0000ae9a },
+{ "KVM_SET_TSC_KHZ", 0x0000aea2 },
+{ "KVM_GET_TSC_KHZ", 0x0000aea3 },
+{ "KVM_KVMCLOCK_CTRL", 0x0000aead },
+{ "KVM_SMI", 0x0000aeb7 },
+{ "VHOST_SET_OWNER", 0x0000af01 },
+{ "VHOST_RESET_OWNER", 0x0000af02 },
+{ "PPPOEIOCDFWD", 0x0000b101 },
+{ "IOCTL_EVTCHN_BIND_VIRQ", 0x00044500 },
+{ "IOCTL_EVTCHN_BIND_UNBOUND_PORT", 0x00044502 },
+{ "IOCTL_EVTCHN_UNBIND", 0x00044503 },
+{ "IOCTL_EVTCHN_NOTIFY", 0x00044504 },
+{ "IOCTL_GNTDEV_SET_MAX_GRANTS", 0x00044703 },
+{ "IOCTL_EVTCHN_BIND_INTERDOMAIN", 0x00084501 },
+{ "IOCTL_GNTDEV_GRANT_COPY", 0x00084708 },
+{ "IOCTL_GNTDEV_UNMAP_GRANT_REF", 0x00104701 },
+{ "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", 0x00104707 },
+{ "IOCTL_GNTDEV_MAP_GRANT_REF", 0x00184700 },
+{ "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", 0x00184702 },
+{ "MFB_SET_ALPHA", 0x40014d00 },
+{ "MFB_SET_GAMMA", 0x40014d01 },
+{ "MFB_SET_BRIGHTNESS", 0x40014d03 },
+{ "USBTMC488_IOCTL_REN_CONTROL", 0x40015b13 },
+{ "SPI_IOC_WR_MODE", 0x40016b01 },
+{ "SPI_IOC_WR_LSB_FIRST", 0x40016b02 },
+{ "SPI_IOC_WR_BITS_PER_WORD", 0x40016b03 },
+{ "PPWCONTROL", 0x40017084 },
+{ "PPWDATA", 0x40017086 },
+{ "PPWCTLONIRQ", 0x40017092 },
+{ "PHONE_MAXRINGS", 0x40017185 },
+{ "PHONE_PLAY_TONE", 0x4001719b },
+{ "SONYPI_IOCSBRT", 0x40017600 },
+{ "SONYPI_IOCSBLUE", 0x40017609 },
+{ "SONYPI_IOCSFAN", 0x4001760b },
+{ "HFI1_IOCTL_SET_PKEY", 0x40021beb },
+{ "ATM_SETBACKEND", 0x400261f2 },
+{ "ATM_NEWBACKENDIF", 0x400261f3 },
+{ "RIO_MPORT_MAINT_HDID_SET", 0x40026d01 },
+{ "NCP_IOC_GETMOUNTUID", 0x40026e02 },
+{ "AUDIO_SET_ATTRIBUTES", 0x40026f11 },
+{ "DMX_ADD_PID", 0x40026f33 },
+{ "DMX_REMOVE_PID", 0x40026f34 },
+{ "PPFCONTROL", 0x4002708e },
+{ "PHONE_RING_CADENCE", 0x40027186 },
+{ "SET_BITMAP_FILE", 0x4004092b },
+{ "BLKBSZSET", 0x40041271 },
+{ "IB_USER_MAD_UNREGISTER_AGENT", 0x40041b02 },
+{ "HFI1_IOCTL_RECV_CTRL", 0x40041be8 },
+{ "HFI1_IOCTL_POLL_TYPE", 0x40041be9 },
+{ "HFI1_IOCTL_ACK_EVENT", 0x40041bea },
+{ "FW_CDEV_IOC_DEALLOCATE", 0x40042303 },
+{ "FW_CDEV_IOC_INITIATE_BUS_RESET", 0x40042305 },
+{ "FW_CDEV_IOC_REMOVE_DESCRIPTOR", 0x40042307 },
+{ "FW_CDEV_IOC_STOP_ISO", 0x4004230b },
+{ "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", 0x4004230e },
+{ "FW_CDEV_IOC_FLUSH_ISO", 0x40042318 },
+{ "PERF_EVENT_IOC_SET_FILTER", 0x40042406 },
+{ "PERF_EVENT_IOC_SET_BPF", 0x40042408 },
+{ "PERF_EVENT_IOC_PAUSE_OUTPUT", 0x40042409 },
+{ "SNAPSHOT_CREATE_IMAGE", 0x40043311 },
+{ "PTP_ENABLE_PPS", 0x40043d04 },
+{ "FBIO_RADEON_SET_MIRROR", 0x40044004 },
+{ "SNDRV_PCM_IOCTL_TSTAMP", 0x40044102 },
+{ "AGPIOC_SETUP", 0x40044103 },
+{ "SNDRV_PCM_IOCTL_TTSTAMP", 0x40044103 },
+{ "AGPIOC_RESERVE", 0x40044104 },
+{ "AGPIOC_PROTECT", 0x40044105 },
+{ "AGPIOC_DEALLOCATE", 0x40044107 },
+{ "AGPIOC_BIND", 0x40044108 },
+{ "AGPIOC_UNBIND", 0x40044109 },
+{ "SNDRV_PCM_IOCTL_PAUSE", 0x40044145 },
+{ "SNDRV_PCM_IOCTL_REWIND", 0x40044146 },
+{ "SNDRV_PCM_IOCTL_FORWARD", 0x40044149 },
+{ "SNDRV_PCM_IOCTL_LINK", 0x40044160 },
+{ "PMU_IOC_SET_BACKLIGHT", 0x40044202 },
+{ "CCISS_REGNEWDISK", 0x4004420d },
+{ "CS_SET_WAKELINE", 0x40044317 },
+{ "EVIOCRMFF", 0x40044581 },
+{ "EVIOCGRAB", 0x40044590 },
+{ "EVIOCREVOKE", 0x40044591 },
+{ "EVIOCSCLOCKID", 0x400445a0 },
+{ "FBIOPUT_CONTRAST", 0x40044602 },
+{ "FBIPUT_BRIGHTNESS", 0x40044603 },
+{ "FBIPUT_COLOR", 0x40044606 },
+{ "FBIPUT_HSYNC", 0x40044609 },
+{ "FBIPUT_VSYNC", 0x4004460a },
+{ "FBIO_WAITFORVSYNC", 0x40044620 },
+{ "SSTFB_SET_VGAPASS", 0x400446dd },
+{ "IOCTL_MEI_NOTIFY_SET", 0x40044802 },
+{ "HIDIOCSFLAG", 0x4004480f },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", 0x40044820 },
+{ "SNDRV_DM_FM_IOCTL_SET_MODE", 0x40044825 },
+{ "SNDRV_DM_FM_IOCTL_SET_CONNECTION", 0x40044826 },
+{ "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", 0x40044842 },
+{ "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", 0x40044883 },
+{ "SNDRV_EMUX_IOCTL_MEM_AVAIL", 0x40044884 },
+{ "HCIDEVUP", 0x400448c9 },
+{ "HCIDEVDOWN", 0x400448ca },
+{ "HCIDEVRESET", 0x400448cb },
+{ "HCIDEVRESTAT", 0x400448cc },
+{ "HCISETRAW", 0x400448dc },
+{ "HCISETSCAN", 0x400448dd },
+{ "HCISETAUTH", 0x400448de },
+{ "HCISETENCRYPT", 0x400448df },
+{ "HCISETPTYPE", 0x400448e0 },
+{ "HCISETLINKPOL", 0x400448e1 },
+{ "HCISETLINKMODE", 0x400448e2 },
+{ "HCISETACLMTU", 0x400448e3 },
+{ "HCISETSCOMTU", 0x400448e4 },
+{ "HCIBLOCKADDR", 0x400448e6 },
+{ "HCIUNBLOCKADDR", 0x400448e7 },
+{ "MFB_SET_PIXFMT", 0x40044d08 },
+{ "OTPGETREGIONCOUNT", 0x40044d0e },
+{ "UBI_IOCEBER", 0x40044f01 },
+{ "UBI_IOCEBCH", 0x40044f02 },
+{ "UBI_IOCEBUNMAP", 0x40044f04 },
+{ "OMAPFB_MIRROR", 0x40044f1f },
+{ "OMAPFB_SET_UPDATE_MODE", 0x40044f28 },
+{ "OMAPFB_GET_UPDATE_MODE", 0x40044f2b },
+{ "OMAPFB_LCD_TEST", 0x40044f2d },
+{ "OMAPFB_CTRL_TEST", 0x40044f2e },
+{ "SNDCTL_DSP_SETTRIGGER", 0x40045010 },
+{ "SNDCTL_DSP_PROFILE", 0x40045017 },
+{ "SNDCTL_DSP_SETSPDIF", 0x40045042 },
+{ "SNDCTL_SEQ_PERCMODE", 0x40045106 },
+{ "SNDCTL_SEQ_TESTMIDI", 0x40045108 },
+{ "SNDCTL_SEQ_RESETSAMPLES", 0x40045109 },
+{ "SNDCTL_SEQ_THRESHOLD", 0x4004510d },
+{ "SNDCTL_FM_4OP_ENABLE", 0x4004510f },
+{ "RNDADDTOENTCNT", 0x40045201 },
+{ "SAA6588_CMD_CLOSE", 0x40045202 },
+{ "RFCOMMCREATEDEV", 0x400452c8 },
+{ "RFCOMMRELEASEDEV", 0x400452c9 },
+{ "RFCOMMSTEALDLC", 0x400452dc },
+{ "SNDRV_TIMER_IOCTL_TREAD", 0x40045402 },
+{ "SNDCTL_TMR_METRONOME", 0x40045407 },
+{ "SNDCTL_TMR_SELECT", 0x40045408 },
+{ "TIOCSPTLCK", 0x40045431 },
+{ "TIOCSIG", 0x40045436 },
+{ "TUNSETNOCSUM", 0x400454c8 },
+{ "TUNSETDEBUG", 0x400454c9 },
+{ "TUNSETIFF", 0x400454ca },
+{ "TUNSETPERSIST", 0x400454cb },
+{ "TUNSETOWNER", 0x400454cc },
+{ "TUNSETLINK", 0x400454cd },
+{ "TUNSETGROUP", 0x400454ce },
+{ "TUNSETOFFLOAD", 0x400454d0 },
+{ "TUNSETTXFILTER", 0x400454d1 },
+{ "TUNSETSNDBUF", 0x400454d4 },
+{ "TUNSETVNETHDRSZ", 0x400454d8 },
+{ "TUNSETQUEUE", 0x400454d9 },
+{ "TUNSETIFINDEX", 0x400454da },
+{ "TUNSETVNETLE", 0x400454dc },
+{ "TUNSETVNETBE", 0x400454de },
+{ "NCIUARTSETDRIVER", 0x40045500 },
+{ "USBDEVFS_REAPURB", 0x4004550c },
+{ "USBDEVFS_REAPURBNDELAY", 0x4004550d },
+{ "USBDEVFS_DROP_PRIVILEGES", 0x4004551e },
+{ "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", 0x40045532 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", 0x40045542 },
+{ "UI_SET_EVBIT", 0x40045564 },
+{ "UI_SET_KEYBIT", 0x40045565 },
+{ "UI_SET_RELBIT", 0x40045566 },
+{ "UI_SET_ABSBIT", 0x40045567 },
+{ "UI_SET_MSCBIT", 0x40045568 },
+{ "UI_SET_LEDBIT", 0x40045569 },
+{ "UI_SET_SNDBIT", 0x4004556a },
+{ "UI_SET_FFBIT", 0x4004556b },
+{ "UI_SET_PHYS", 0x4004556c },
+{ "UI_SET_SWBIT", 0x4004556d },
+{ "UI_SET_PROPBIT", 0x4004556e },
+{ "VIDIOC_OVERLAY", 0x4004560e },
+{ "VIDIOC_STREAMON", 0x40045612 },
+{ "VIDIOC_STREAMOFF", 0x40045613 },
+{ "VIDIOC_S_PRIORITY", 0x40045644 },
+{ "IVTV_IOC_PASSTHROUGH_MODE", 0x400456c1 },
+{ "VIDIOC_AM437X_CCDC_CFG", 0x400456c1 },
+{ "VPFE_CMD_S_CCDC_RAW_PARAMS", 0x400456c1 },
+{ "SW_SYNC_IOC_INC", 0x40045701 },
+{ "SNDRV_RAWMIDI_IOCTL_DROP", 0x40045730 },
+{ "SNDRV_RAWMIDI_IOCTL_DRAIN", 0x40045731 },
+{ "SONET_SETFRAMING", 0x40046115 },
+{ "ATM_SETSC", 0x400461f1 },
+{ "ATM_DROPPARTY", 0x400461f5 },
+{ "BINDER_SET_MAX_THREADS", 0x40046205 },
+{ "BINDER_SET_IDLE_PRIORITY", 0x40046206 },
+{ "BINDER_SET_CONTEXT_MGR", 0x40046207 },
+{ "BINDER_THREAD_EXIT", 0x40046208 },
+{ "BC_ACQUIRE_RESULT", 0x40046302 },
+{ "CM_IOCSPTS", 0x40046302 },
+{ "BC_INCREFS", 0x40046304 },
+{ "BC_ACQUIRE", 0x40046305 },
+{ "CHIOSPICKER", 0x40046305 },
+{ "BC_RELEASE", 0x40046306 },
+{ "BC_DECREFS", 0x40046307 },
+{ "CM_IOSDBGLVL", 0x400463fa },
+{ "DRM_IOCTL_AUTH_MAGIC", 0x40046411 },
+{ "DRM_IOCTL_AGP_ENABLE", 0x40046432 },
+{ "DRM_IOCTL_I915_IRQ_WAIT", 0x40046445 },
+{ "DRM_IOCTL_MSM_GEM_CPU_FINI", 0x40046445 },
+{ "DRM_IOCTL_RADEON_FULLSCREEN", 0x40046446 },
+{ "DRM_IOCTL_MGA_SET_FENCE", 0x4004644a },
+{ "DRM_IOCTL_I915_DESTROY_HEAP", 0x4004644c },
+{ "DRM_IOCTL_RADEON_STIPPLE", 0x4004644c },
+{ "DRM_IOCTL_I915_SET_VBLANK_PIPE", 0x4004644d },
+{ "DRM_IOCTL_R128_STIPPLE", 0x4004644d },
+{ "DRM_IOCTL_R128_FULLSCREEN", 0x40046450 },
+{ "DRM_IOCTL_RADEON_IRQ_WAIT", 0x40046457 },
+{ "DRM_IOCTL_RADEON_SURF_FREE", 0x4004645b },
+{ "DRM_IOCTL_I915_GEM_SW_FINISH", 0x40046460 },
+{ "VIDIOC_INT_RESET", 0x40046466 },
+{ "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", 0x40046483 },
+{ "FS_IOC32_SETFLAGS", 0x40046602 },
+{ "FS_IOC_SETFLAGS", 0x40046602 },
+{ "HPET_IRQFREQ", 0x40046806 },
+{ "LIRC_SET_SEND_MODE", 0x40046911 },
+{ "LIRC_SET_REC_MODE", 0x40046912 },
+{ "LIRC_SET_SEND_CARRIER", 0x40046913 },
+{ "LIRC_SET_REC_CARRIER", 0x40046914 },
+{ "LIRC_SET_SEND_DUTY_CYCLE", 0x40046915 },
+{ "LIRC_SET_REC_DUTY_CYCLE", 0x40046916 },
+{ "LIRC_SET_TRANSMITTER_MASK", 0x40046917 },
+{ "LIRC_SET_REC_TIMEOUT", 0x40046918 },
+{ "LIRC_SET_REC_TIMEOUT_REPORTS", 0x40046919 },
+{ "LIRC_SET_REC_FILTER_PULSE", 0x4004691a },
+{ "LIRC_SET_REC_FILTER_SPACE", 0x4004691b },
+{ "LIRC_SET_REC_FILTER", 0x4004691c },
+{ "LIRC_SET_MEASURE_CARRIER_MODE", 0x4004691d },
+{ "LIRC_SET_REC_DUTY_CYCLE_RANGE", 0x4004691e },
+{ "IPMICTL_SET_MAINTENANCE_MODE_CMD", 0x4004691f },
+{ "LIRC_SET_REC_CARRIER_RANGE", 0x4004691f },
+{ "LIRC_SET_WIDEBAND_RECEIVER", 0x40046923 },
+{ "SPI_IOC_WR_MAX_SPEED_HZ", 0x40046b04 },
+{ "SPI_IOC_WR_MODE32", 0x40046b05 },
+{ "RIO_MPORT_MAINT_COMPTAG_SET", 0x40046d02 },
+{ "RIO_SET_EVENT_MASK", 0x40046d0d },
+{ "NCP_IOC_GETMOUNTUID2", 0x40046e02 },
+{ "NCP_IOC_SET_SIGN_WANTED", 0x40046e06 },
+{ "NCP_IOC_GETDENTRYTTL", 0x40046e0c },
+{ "MATROXFB_SET_OUTPUT_CONNECTION", 0x40046ef8 },
+{ "MATROXFB_SET_OUTPUT_MODE", 0x40046efa },
+{ "SISFB_SET_AUTOMAXIMIZE_OLD", 0x40046efa },
+{ "UBI_IOCRMVOL", 0x40046f01 },
+{ "DMX_SET_SOURCE", 0x40046f31 },
+{ "UBI_IOCDET", 0x40046f41 },
+{ "PHN_SET_REG", 0x40047001 },
+{ "PHN_SET_REGS", 0x40047003 },
+{ "RTC_IRQP_SET", 0x4004700c },
+{ "RTC_EPOCH_SET", 0x4004700e },
+{ "PPSETMODE", 0x40047080 },
+{ "PPDATADIR", 0x40047090 },
+{ "PPNEGOT", 0x40047091 },
+{ "PPSETPHASE", 0x40047094 },
+{ "PPSETFLAGS", 0x4004709b },
+{ "PPS_SETPARAMS", 0x400470a2 },
+{ "PPS_KC_BIND", 0x400470a5 },
+{ "SPIOCSTYPE", 0x40047101 },
+{ "PHONE_CAPABILITIES_CHECK", 0x40047182 },
+{ "PHONE_RING_START", 0x40047187 },
+{ "PHONE_REC_CODEC", 0x40047189 },
+{ "PHONE_REC_DEPTH", 0x4004718c },
+{ "PHONE_FRAME", 0x4004718d },
+{ "PHONE_REC_VOLUME", 0x4004718e },
+{ "PHONE_PLAY_CODEC", 0x40047190 },
+{ "PHONE_PLAY_DEPTH", 0x40047193 },
+{ "PHONE_PLAY_VOLUME", 0x40047194 },
+{ "PHONE_DTMF_OOB", 0x40047199 },
+{ "PHONE_SET_TONE_ON_TIME", 0x4004719c },
+{ "PHONE_SET_TONE_OFF_TIME", 0x4004719d },
+{ "PHONE_PSTN_SET_STATE", 0x400471a4 },
+{ "PHONE_WINK_DURATION", 0x400471a6 },
+{ "PHONE_VAD", 0x400471a9 },
+{ "PHONE_WINK", 0x400471aa },
+{ "IXJCTL_SET_FILTER", 0x400471c7 },
+{ "IXJCTL_GET_FILTER_HIST", 0x400471c8 },
+{ "IXJCTL_INIT_TONE", 0x400471c9 },
+{ "IXJCTL_TONE_CADENCE", 0x400471ca },
+{ "IXJCTL_AEC_START", 0x400471cb },
+{ "IXJCTL_SET_LED", 0x400471ce },
+{ "IXJCTL_MIXER", 0x400471cf },
+{ "IXJCTL_DAA_COEFF_SET", 0x400471d0 },
+{ "IXJCTL_PORT", 0x400471d1 },
+{ "IXJCTL_DAA_AGAIN", 0x400471d2 },
+{ "IXJCTL_POTS_PSTN", 0x400471d5 },
+{ "IXJCTL_FILTER_CADENCE", 0x400471d6 },
+{ "IXJCTL_CIDCW", 0x400471d9 },
+{ "PHONE_REC_VOLUME_LINEAR", 0x400471db },
+{ "PHONE_PLAY_VOLUME_LINEAR", 0x400471dc },
+{ "IXJCTL_SET_FILTER_RAW", 0x400471dd },
+{ "IXJCTL_HZ", 0x400471e0 },
+{ "IXJCTL_RATE", 0x400471e1 },
+{ "IXJCTL_DTMF_PRESCALE", 0x400471e8 },
+{ "IXJCTL_SIGCTL", 0x400471e9 },
+{ "IXJCTL_SC_RXG", 0x400471ea },
+{ "IXJCTL_SC_TXG", 0x400471eb },
+{ "IXJCTL_INTERCOM_START", 0x400471fd },
+{ "IXJCTL_INTERCOM_STOP", 0x400471fe },
+{ "FAT_IOCTL_SET_ATTRIBUTES", 0x40047211 },
+{ "SCIF_LISTEN", 0x40047302 },
+{ "PPPIOCATTCHAN", 0x40047438 },
+{ "PPPIOCCONNECT", 0x4004743a },
+{ "PPPIOCSMRRU", 0x4004743b },
+{ "PPPIOCDETACH", 0x4004743c },
+{ "PPPIOCATTACH", 0x4004743d },
+{ "PPPIOCSDEBUG", 0x40047440 },
+{ "PPPIOCSMAXCID", 0x40047451 },
+{ "PPPIOCSMRU", 0x40047452 },
+{ "PPPIOCSRASYNCMAP", 0x40047454 },
+{ "PPPIOCSASYNCMAP", 0x40047457 },
+{ "PPPIOCSFLAGS", 0x40047459 },
+{ "PPPIOCBUNDLE", 0x40047481 },
+{ "PPPIOCSMPFLAGS", 0x40047483 },
+{ "PPPIOCSMPMTU", 0x40047484 },
+{ "PPPIOCSMPMRU", 0x40047485 },
+{ "PPPIOCSCOMPRESSOR", 0x40047487 },
+{ "V4L2_SUBDEV_IR_RX_NOTIFY", 0x40047600 },
+{ "V4L2_SUBDEV_IR_TX_NOTIFY", 0x40047601 },
+{ "FS_IOC32_SETVERSION", 0x40047602 },
+{ "FS_IOC_SETVERSION", 0x40047602 },
+{ "MEYEIOC_QBUF_CAPT", 0x400476c2 },
+{ "ASHMEM_SET_SIZE", 0x40047703 },
+{ "ASHMEM_SET_PROT_MASK", 0x40047705 },
+{ "OSIOCSNETADDR", 0x400489e0 },
+{ "SIOCSNETADDR", 0x400489e0 },
+{ "AUTOFS_IOC_EXPIRE_MULTI", 0x40049366 },
+{ "BTRFS_IOC_CLONE", 0x40049409 },
+{ "FICLONE", 0x40049409 },
+{ "BTRFS_IOC_BALANCE_CTL", 0x40049421 },
+{ "KVM_S390_VCPU_FAULT", 0x4004ae52 },
+{ "KVM_INTERRUPT", 0x4004ae86 },
+{ "KVM_SET_SIGNAL_MASK", 0x4004ae8b },
+{ "KVM_S390_STORE_STATUS", 0x4004ae95 },
+{ "KVM_SET_MP_STATE", 0x4004ae99 },
+{ "VHOST_SET_LOG_FD", 0x4004af07 },
+{ "VHOST_SCSI_GET_ABI_VERSION", 0x4004af42 },
+{ "VHOST_SCSI_SET_EVENTS_MISSED", 0x4004af43 },
+{ "VHOST_SCSI_GET_EVENTS_MISSED", 0x4004af44 },
+{ "PPPOEIOCSFWD", 0x4004b100 },
+{ "IOW_WRITE", 0x4004c001 },
+{ "IOW_READ", 0x4004c002 },
+{ "REISERFS_IOC_UNPACK", 0x4004cd01 },
+{ "SISFB_SET_AUTOMAXIMIZE", 0x4004f303 },
+{ "SISFB_SET_TVPOSOFFSET", 0x4004f304 },
+{ "SISFB_SET_LOCK", 0x4004f306 },
+{ "GIGASET_BRKCHARS", 0x40064702 },
+{ "MEYEIOC_S_PARAMS", 0x400676c1 },
+{ "FE_DISEQC_SEND_MASTER_CMD", 0x40076f3f },
+{ "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", 0x40082316 },
+{ "PERF_EVENT_IOC_PERIOD", 0x40082404 },
+{ "STP_SET_OPTIONS", 0x40082502 },
+{ "CCISS_SETINTINFO", 0x40084203 },
+{ "APEI_ERST_CLEAR_RECORD", 0x40084501 },
+{ "EVIOCSREP", 0x40084503 },
+{ "EVIOCSKEYCODE", 0x40084504 },
+{ "SNDRV_SB_CSP_IOCTL_START", 0x40084813 },
+{ "AMDKFD_IOC_DESTROY_EVENT", 0x40084b09 },
+{ "AMDKFD_IOC_SET_EVENT", 0x40084b0a },
+{ "AMDKFD_IOC_RESET_EVENT", 0x40084b0b },
+{ "AMDKFD_IOC_DBG_REGISTER", 0x40084b0d },
+{ "AMDKFD_IOC_DBG_UNREGISTER", 0x40084b0e },
+{ "MEMERASE", 0x40084d02 },
+{ "MFB_SET_AOID", 0x40084d04 },
+{ "MEMLOCK", 0x40084d05 },
+{ "MEMUNLOCK", 0x40084d06 },
+{ "MEMGETBADBLOCK", 0x40084d0b },
+{ "MEMSETBADBLOCK", 0x40084d0c },
+{ "UBI_IOCVOLUP", 0x40084f00 },
+{ "UBI_IOCEBMAP", 0x40084f03 },
+{ "OMAPFB_SETUP_MEM", 0x40084f37 },
+{ "OMAPFB_QUERY_MEM", 0x40084f38 },
+{ "OMAPFB_SET_TEARSYNC", 0x40084f3e },
+{ "SNDCTL_SEQ_OUTOFBAND", 0x40085112 },
+{ "RNDADDENTROPY", 0x40085203 },
+{ "TFD_IOC_SET_TICKS", 0x40085400 },
+{ "TUNATTACHFILTER", 0x400854d5 },
+{ "TUNDETACHFILTER", 0x400854d6 },
+{ "USBDEVFS_CONNECTINFO", 0x40085511 },
+{ "VIDIOC_S_STD", 0x40085618 },
+{ "ATM_GETNAMES", 0x40086183 },
+{ "ATM_ADDPARTY", 0x400861f4 },
+{ "DMA_BUF_IOCTL_SYNC", 0x40086200 },
+{ "BINDER_SET_IDLE_TIMEOUT", 0x40086203 },
+{ "BC_FREE_BUFFER", 0x40086303 },
+{ "CHIOGSTATUS", 0x40086308 },
+{ "BC_ATTEMPT_ACQUIRE", 0x4008630a },
+{ "BC_DEAD_BINDER_DONE", 0x40086310 },
+{ "DRM_IOCTL_MODESET_CTL", 0x40086408 },
+{ "DRM_IOCTL_GEM_CLOSE", 0x40086409 },
+{ "DRM_IOCTL_SET_UNIQUE", 0x40086410 },
+{ "DRM_IOCTL_CONTROL", 0x40086414 },
+{ "DRM_IOCTL_FREE_BUFS", 0x4008641a },
+{ "DRM_IOCTL_SET_SAREA_CTX", 0x4008641c },
+{ "DRM_IOCTL_MOD_CTX", 0x40086422 },
+{ "DRM_IOCTL_SWITCH_CTX", 0x40086424 },
+{ "DRM_IOCTL_NEW_CTX", 0x40086425 },
+{ "DRM_IOCTL_LOCK", 0x4008642a },
+{ "DRM_IOCTL_UNLOCK", 0x4008642b },
+{ "DRM_IOCTL_FINISH", 0x4008642c },
+{ "DRM_IOCTL_AGP_BIND", 0x40086436 },
+{ "DRM_IOCTL_AGP_UNBIND", 0x40086437 },
+{ "DRM_IOCTL_SG_FREE", 0x40086439 },
+{ "DRM_IOCTL_MGA_FLUSH", 0x40086441 },
+{ "DRM_IOCTL_R128_CCE_STOP", 0x40086442 },
+{ "DRM_IOCTL_RADEON_CP_STOP", 0x40086442 },
+{ "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", 0x40086443 },
+{ "DRM_IOCTL_OMAP_GEM_CPU_PREP", 0x40086444 },
+{ "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", 0x40086445 },
+{ "DRM_IOCTL_QXL_CLIENTCAP", 0x40086445 },
+{ "DRM_IOCTL_I915_SETPARAM", 0x40086447 },
+{ "DRM_IOCTL_VIA_CMDBUFFER", 0x40086448 },
+{ "DRM_IOCTL_I915_FREE", 0x40086449 },
+{ "DRM_IOCTL_VIA_PCICMD", 0x4008644a },
+{ "DRM_IOCTL_VIA_BLIT_SYNC", 0x4008644f },
+{ "DRM_IOCTL_RADEON_FREE", 0x40086454 },
+{ "DRM_IOCTL_I915_GEM_UNPIN", 0x40086456 },
+{ "DRM_IOCTL_SIS_FB_INIT", 0x40086456 },
+{ "TUNER_SET_CONFIG", 0x4008645c },
+{ "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", 0x40086464 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", 0x4008646e },
+{ "DRM_IOCTL_I915_GEM_SET_CACHING", 0x4008646f },
+{ "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", 0x40086482 },
+{ "MTIOCTOP", 0x40086d01 },
+{ "RIO_ENABLE_DOORBELL_RANGE", 0x40086d09 },
+{ "RIO_DISABLE_DOORBELL_RANGE", 0x40086d0a },
+{ "RIO_UNMAP_INBOUND", 0x40086d12 },
+{ "RIO_FREE_DMA", 0x40086d14 },
+{ "RIO_WAIT_FOR_ASYNC", 0x40086d16 },
+{ "NILFS_IOCTL_DELETE_CHECKPOINT", 0x40086e81 },
+{ "NILFS_IOCTL_RESIZE", 0x40086e8b },
+{ "AUDIO_SET_MIXER", 0x40086f0e },
+{ "VIDEO_STILLPICTURE", 0x40086f1e },
+{ "VIDEO_SET_SPU", 0x40086f32 },
+{ "VIDEO_SET_SPU_PALETTE", 0x40086f33 },
+{ "FE_SET_PROPERTY", 0x40086f52 },
+{ "CA_SET_PID", 0x40086f87 },
+{ "PHN_SETREG", 0x40087006 },
+{ "PPSETTIME", 0x40087096 },
+{ "PPPIOCSACTIVE", 0x40087446 },
+{ "PPPIOCSPASS", 0x40087447 },
+{ "PPPIOCSNPMODE", 0x4008744b },
+{ "ASHMEM_PIN", 0x40087707 },
+{ "ASHMEM_UNPIN", 0x40087708 },
+{ "BTRFS_IOC_DEFAULT_SUBVOL", 0x40089413 },
+{ "BTRFS_IOC_WAIT_SYNC", 0x40089416 },
+{ "BTRFS_IOC_SUBVOL_SETFLAGS", 0x4008941a },
+{ "KVM_SET_IDENTITY_MAP_ADDR", 0x4008ae48 },
+{ "KVM_IRQ_LINE", 0x4008ae61 },
+{ "KVM_SET_GSI_ROUTING", 0x4008ae6a },
+{ "KVM_ASSIGN_SET_MSIX_NR", 0x4008ae73 },
+{ "KVM_SET_MSRS", 0x4008ae89 },
+{ "KVM_SET_CPUID", 0x4008ae8a },
+{ "KVM_SET_CPUID2", 0x4008ae90 },
+{ "KVM_SET_VAPIC_ADDR", 0x4008ae93 },
+{ "KVM_X86_SETUP_MCE", 0x4008ae9c },
+{ "VHOST_SET_FEATURES", 0x4008af00 },
+{ "VHOST_SET_MEM_TABLE", 0x4008af03 },
+{ "VHOST_SET_LOG_BASE", 0x4008af04 },
+{ "VHOST_SET_VRING_NUM", 0x4008af10 },
+{ "VHOST_SET_VRING_BASE", 0x4008af12 },
+{ "VHOST_SET_VRING_ENDIAN", 0x4008af13 },
+{ "VHOST_GET_VRING_ENDIAN", 0x4008af14 },
+{ "VHOST_SET_VRING_KICK", 0x4008af20 },
+{ "VHOST_SET_VRING_CALL", 0x4008af21 },
+{ "VHOST_SET_VRING_ERR", 0x4008af22 },
+{ "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", 0x4008af23 },
+{ "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", 0x4008af24 },
+{ "VHOST_NET_SET_BACKEND", 0x4008af30 },
+{ "SNDRV_DM_FM_IOCTL_SET_PARAMS", 0x40094824 },
+{ "FDFMTTRK", 0x400c0248 },
+{ "RUN_ARRAY", 0x400c0930 },
+{ "FW_CDEV_IOC_SET_ISO_CHANNELS", 0x400c2317 },
+{ "SNAPSHOT_SET_SWAP_AREA", 0x400c330d },
+{ "SNDRV_PCM_IOCTL_WRITEI_FRAMES", 0x400c4150 },
+{ "SNDRV_PCM_IOCTL_WRITEN_FRAMES", 0x400c4152 },
+{ "CAPI_REGISTER", 0x400c4301 },
+{ "HIDIOCGREPORT", 0x400c4807 },
+{ "HIDIOCSREPORT", 0x400c4808 },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_POKE", 0x400c4821 },
+{ "SNDRV_DM_FM_IOCTL_PLAY_NOTE", 0x400c4822 },
+{ "MTRRIOC_ADD_ENTRY", 0x400c4d00 },
+{ "MFB_SET_CHROMA_KEY", 0x400c4d01 },
+{ "MTRRIOC_SET_ENTRY", 0x400c4d01 },
+{ "MTRRIOC_DEL_ENTRY", 0x400c4d02 },
+{ "MTRRIOC_KILL_ENTRY", 0x400c4d04 },
+{ "MTRRIOC_ADD_PAGE_ENTRY", 0x400c4d05 },
+{ "MTRRIOC_SET_PAGE_ENTRY", 0x400c4d06 },
+{ "MTRRIOC_DEL_PAGE_ENTRY", 0x400c4d07 },
+{ "MTRRIOC_KILL_PAGE_ENTRY", 0x400c4d09 },
+{ "OTPGETREGIONINFO", 0x400c4d0f },
+{ "UI_END_FF_ERASE", 0x400c55cb },
+{ "IVTVFB_IOC_DMA_FRAME", 0x400c56c0 },
+{ "IDT77105_GETSTAT", 0x400c6132 },
+{ "IDT77105_GETSTATZ", 0x400c6133 },
+{ "ATM_GETSTAT", 0x400c6150 },
+{ "ATM_GETSTATZ", 0x400c6151 },
+{ "ATM_GETLOOP", 0x400c6152 },
+{ "ATM_SETLOOP", 0x400c6153 },
+{ "ATM_QUERYLOOP", 0x400c6154 },
+{ "ENI_MEMDUMP", 0x400c6160 },
+{ "HE_GET_REG", 0x400c6160 },
+{ "ZATM_GETPOOL", 0x400c6161 },
+{ "NS_SETBUFLEV", 0x400c6162 },
+{ "ZATM_GETPOOLZ", 0x400c6162 },
+{ "ZATM_SETPOOL", 0x400c6163 },
+{ "ENI_SETMULT", 0x400c6167 },
+{ "ATM_GETLINKRATE", 0x400c6181 },
+{ "ATM_GETTYPE", 0x400c6184 },
+{ "ATM_GETESI", 0x400c6185 },
+{ "ATM_GETADDR", 0x400c6186 },
+{ "ATM_RSTADDR", 0x400c6187 },
+{ "ATM_ADDADDR", 0x400c6188 },
+{ "ATM_DELADDR", 0x400c6189 },
+{ "ATM_GETCIRANGE", 0x400c618a },
+{ "ATM_SETCIRANGE", 0x400c618b },
+{ "ATM_SETESI", 0x400c618c },
+{ "ATM_SETESIF", 0x400c618d },
+{ "ATM_ADDLECSADDR", 0x400c618e },
+{ "ATM_DELLECSADDR", 0x400c618f },
+{ "ATM_GETLECSADDR", 0x400c6190 },
+{ "CHIOPOSITION", 0x400c6303 },
+{ "BC_REQUEST_DEATH_NOTIFICATION", 0x400c630e },
+{ "BC_CLEAR_DEATH_NOTIFICATION", 0x400c630f },
+{ "DRM_IOCTL_I810_VERTEX", 0x400c6441 },
+{ "DRM_IOCTL_I810_CLEAR", 0x400c6442 },
+{ "DRM_IOCTL_MGA_VERTEX", 0x400c6445 },
+{ "DRM_IOCTL_I810_COPY", 0x400c6447 },
+{ "DRM_IOCTL_MGA_ILOAD", 0x400c6447 },
+{ "DRM_IOCTL_I915_INIT_HEAP", 0x400c644a },
+{ "DRM_IOCTL_RADEON_INIT_HEAP", 0x400c6455 },
+{ "DRM_IOCTL_RADEON_SETPARAM", 0x400c6459 },
+{ "DRM_IOCTL_RADEON_SURF_ALLOC", 0x400c645a },
+{ "DRM_IOCTL_I915_GEM_SET_DOMAIN", 0x400c645f },
+{ "FS_IOC_GET_ENCRYPTION_POLICY", 0x400c6615 },
+{ "I2OEVTREG", 0x400c690a },
+{ "HSC_SET_RX", 0x400c6b13 },
+{ "HSC_GET_RX", 0x400c6b14 },
+{ "NCP_IOC_GETROOT", 0x400c6e08 },
+{ "UBI_IOCRSVOL", 0x400c6f02 },
+{ "AUDIO_SET_KARAOKE", 0x400c6f12 },
+{ "PPPIOCSCOMPRESS", 0x400c744d },
+{ "KVM_CREATE_SPAPR_TCE", 0x400caea8 },
+{ "KVM_DIRTY_TLB", 0x400caeaa },
+{ "MBXFB_IOCS_REG", 0x400cf404 },
+{ "FW_CDEV_IOC_START_ISO", 0x4010230a },
+{ "PTP_EXTTS_REQUEST", 0x40103d02 },
+{ "CCISS_SETNODENAME", 0x40104205 },
+{ "EVIOCSMASK", 0x40104593 },
+{ "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", 0x40104890 },
+{ "AMDKFD_IOC_DBG_ADDRESS_WATCH", 0x40104b0f },
+{ "AMDKFD_IOC_DBG_WAVE_CONTROL", 0x40104b10 },
+{ "MEMERASE64", 0x40104d14 },
+{ "UBI_IOCSETVOLPROP", 0x40104f06 },
+{ "OMAPFB_SET_COLOR_KEY", 0x40104f32 },
+{ "OMAPFB_GET_COLOR_KEY", 0x40104f33 },
+{ "BC_INCREFS_DONE", 0x40106308 },
+{ "BC_ACQUIRE_DONE", 0x40106309 },
+{ "DRM_IOCTL_SET_CLIENT_CAP", 0x4010640d },
+{ "DRM_IOCTL_AGP_FREE", 0x40106435 },
+{ "DRM_IOCTL_OMAP_SET_PARAM", 0x40106441 },
+{ "DRM_IOCTL_QXL_EXECBUFFER", 0x40106442 },
+{ "DRM_IOCTL_OMAP_GEM_CPU_FINI", 0x40106445 },
+{ "DRM_IOCTL_SIS_FB_FREE", 0x40106445 },
+{ "DRM_IOCTL_VIA_DEC_FUTEX", 0x40106445 },
+{ "DRM_IOCTL_MGA_INDICES", 0x40106446 },
+{ "DRM_IOCTL_R128_VERTEX", 0x40106449 },
+{ "DRM_IOCTL_RADEON_VERTEX", 0x40106449 },
+{ "DRM_IOCTL_RADEON_CMDBUF", 0x40106450 },
+{ "DRM_IOCTL_I915_HWS_ADDR", 0x40106451 },
+{ "DRM_IOCTL_I915_GEM_INIT", 0x40106453 },
+{ "DRM_IOCTL_SIS_AGP_FREE", 0x40106455 },
+{ "FS_IOC_GET_ENCRYPTION_PWSALT", 0x40106614 },
+{ "HSC_SET_TX", 0x40106b15 },
+{ "HSC_GET_TX", 0x40106b16 },
+{ "RIO_ENABLE_PORTWRITE_RANGE", 0x40106d0b },
+{ "RIO_DISABLE_PORTWRITE_RANGE", 0x40106d0c },
+{ "MGSL_IOCSGPIO", 0x40106d10 },
+{ "NILFS_IOCTL_CHANGE_CPMODE", 0x40106e80 },
+{ "NILFS_IOCTL_SET_ALLOC_RANGE", 0x40106e8c },
+{ "VIDEO_SET_HIGHLIGHT", 0x40106f27 },
+{ "CA_SET_DESCR", 0x40106f86 },
+{ "IOC_PR_RESERVE", 0x401070c9 },
+{ "IOC_PR_RELEASE", 0x401070ca },
+{ "IOC_PR_CLEAR", 0x401070cd },
+{ "BTRFS_IOC_QGROUP_CREATE", 0x4010942a },
+{ "GENWQE_WRITE_REG64", 0x4010a51f },
+{ "GENWQE_WRITE_REG32", 0x4010a521 },
+{ "GENWQE_WRITE_REG16", 0x4010a523 },
+{ "KVM_GET_DIRTY_LOG", 0x4010ae42 },
+{ "KVM_REGISTER_COALESCED_MMIO", 0x4010ae67 },
+{ "KVM_UNREGISTER_COALESCED_MMIO", 0x4010ae68 },
+{ "KVM_ASSIGN_SET_MSIX_ENTRY", 0x4010ae74 },
+{ "KVM_S390_INTERRUPT", 0x4010ae94 },
+{ "KVM_S390_SET_INITIAL_PSW", 0x4010ae96 },
+{ "KVM_ARM_SET_DEVICE_ADDR", 0x4010aeab },
+{ "KVM_GET_ONE_REG", 0x4010aeab },
+{ "KVM_SET_ONE_REG", 0x4010aeac },
+{ "SNDRV_DM_FM_IOCTL_SET_VOICE", 0x40124823 },
+{ "FDSETMAXERRS", 0x4014024c },
+{ "ADD_NEW_DISK", 0x40140921 },
+{ "FW_CDEV_IOC_SEND_RESPONSE", 0x40142304 },
+{ "SNDCTL_COPR_WDATA", 0x40144304 },
+{ "SNDCTL_COPR_WCODE", 0x40144305 },
+{ "OMAPFB_UPDATE_WINDOW_OLD", 0x40144f2f },
+{ "VIDIOC_S_CROP", 0x4014563c },
+{ "CHIOMOVE", 0x40146301 },
+{ "DRM_IOCTL_UPDATE_DRAW", 0x4014643f },
+{ "DRM_IOCTL_VIA_FREEMEM", 0x40146441 },
+{ "DRM_IOCTL_MGA_CLEAR", 0x40146444 },
+{ "DRM_IOCTL_R128_CLEAR", 0x40146448 },
+{ "DRM_IOCTL_R128_INDICES", 0x4014644a },
+{ "DRM_IOCTL_RADEON_INDICES", 0x4014644a },
+{ "DRM_IOCTL_I810_MC", 0x4014644c },
+{ "DMX_SET_PES_FILTER", 0x40146f2c },
+{ "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", 0x4018230f },
+{ "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", 0x40182310 },
+{ "HIDIOCSUSAGE", 0x4018480c },
+{ "HIDIOCGCOLLECTIONINDEX", 0x40184810 },
+{ "AMDKFD_IOC_UPDATE_QUEUE", 0x40184b07 },
+{ "DRM_IOCTL_MARK_BUFS", 0x40186417 },
+{ "DRM_IOCTL_RM_MAP", 0x4018641b },
+{ "DRM_IOCTL_I915_BATCHBUFFER", 0x40186443 },
+{ "DRM_IOCTL_QXL_UPDATE_AREA", 0x40186443 },
+{ "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", 0x40186444 },
+{ "DRM_IOCTL_MSM_GEM_CPU_PREP", 0x40186444 },
+{ "DRM_IOCTL_MSM_WAIT_FENCE", 0x40186447 },
+{ "DRM_IOCTL_RADEON_CLEAR", 0x40186448 },
+{ "DRM_IOCTL_I915_CMDBUFFER", 0x4018644b },
+{ "DRM_IOCTL_R128_BLIT", 0x4018644b },
+{ "DRM_IOCTL_R128_DEPTH", 0x4018644c },
+{ "DRM_IOCTL_RADEON_VERTEX2", 0x4018644f },
+{ "RIO_MPORT_MAINT_WRITE_LOCAL", 0x40186d06 },
+{ "RIO_MPORT_MAINT_WRITE_REMOTE", 0x40186d08 },
+{ "NILFS_IOCTL_SET_SUINFO", 0x40186e8d },
+{ "UBI_IOCATT", 0x40186f40 },
+{ "IOC_PR_REGISTER", 0x401870c8 },
+{ "IOC_PR_PREEMPT", 0x401870cb },
+{ "IOC_PR_PREEMPT_ABORT", 0x401870cc },
+{ "BTRFS_IOC_QGROUP_ASSIGN", 0x40189429 },
+{ "KVM_SET_MEMORY_REGION", 0x4018ae40 },
+{ "KVM_S390_UCAS_MAP", 0x4018ae50 },
+{ "KVM_S390_UCAS_UNMAP", 0x4018ae51 },
+{ "KVM_SET_DEVICE_ATTR", 0x4018aee1 },
+{ "KVM_GET_DEVICE_ATTR", 0x4018aee2 },
+{ "KVM_HAS_DEVICE_ATTR", 0x4018aee3 },
+{ "MBXFB_IOCS_ALPHA", 0x4018f402 },
+{ "FDSETPRM", 0x401c0242 },
+{ "FDDEFPRM", 0x401c0243 },
+{ "UI_ABS_SETUP", 0x401c5504 },
+{ "FS_IOC_FSSETXATTR", 0x401c5820 },
+{ "BR2684_SETFILT", 0x401c6190 },
+{ "CHIOEXCHANGE", 0x401c6302 },
+{ "OSD_SEND_CMD", 0x401c6fa0 },
+{ "RTC_PLL_SET", 0x401c7012 },
+{ "CS_CONFIG_BUFS", 0x4020431f },
+{ "ION_IOC_TEST_DMA_MAPPING", 0x402049f1 },
+{ "ION_IOC_TEST_KERNEL_MAPPING", 0x402049f2 },
+{ "AMDKFD_IOC_SET_MEMORY_POLICY", 0x40204b04 },
+{ "VIDIOC_SUBSCRIBE_EVENT", 0x4020565a },
+{ "VIDIOC_UNSUBSCRIBE_EVENT", 0x4020565b },
+{ "DRM_IOCTL_VIRTGPU_EXECBUFFER", 0x40206442 },
+{ "DRM_IOCTL_AMDGPU_INFO", 0x40206445 },
+{ "DRM_IOCTL_ETNAVIV_WAIT_FENCE", 0x40206447 },
+{ "DRM_IOCTL_ETNAVIV_GEM_WAIT", 0x40206449 },
+{ "DRM_IOCTL_I915_GEM_PREAD", 0x4020645c },
+{ "DRM_IOCTL_I915_GEM_PWRITE", 0x4020645d },
+{ "MGSL_IOCSPARAMS", 0x40206d00 },
+{ "RIO_DEV_ADD", 0x40206d17 },
+{ "RIO_DEV_DEL", 0x40206d18 },
+{ "PPPIOCSXASYNCMAP", 0x4020744f },
+{ "BTRFS_IOC_CLONE_RANGE", 0x4020940d },
+{ "FICLONERANGE", 0x4020940d },
+{ "KVM_SET_MEMORY_ALIAS", 0x4020ae43 },
+{ "KVM_SET_USER_MEMORY_REGION", 0x4020ae46 },
+{ "KVM_IRQFD", 0x4020ae76 },
+{ "KVM_SIGNAL_MSI", 0x4020aea5 },
+{ "KVM_CREATE_SPAPR_TCE_64", 0x4020aea8 },
+{ "KVM_PPC_GET_HTAB_FD", 0x4020aeaa },
+{ "KVM_ARM_VCPU_INIT", 0x4020aeae },
+{ "KVM_S390_SET_IRQ_STATE", 0x4020aeb5 },
+{ "KVM_S390_GET_IRQ_STATE", 0x4020aeb6 },
+{ "FW_CDEV_IOC_SEND_REQUEST", 0x40242301 },
+{ "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", 0x40242312 },
+{ "SNDRV_COMPRESS_SET_METADATA", 0x40244314 },
+{ "NVM_DEV_REMOVE", 0x40244c23 },
+{ "NVM_DEV_FACTORY", 0x40244c25 },
+{ "DRM_IOCTL_SAVAGE_BCI_CMDBUF", 0x40246441 },
+{ "JSIOCSCORR", 0x40246a21 },
+{ "FE_SET_FRONTEND", 0x40246f4c },
+{ "RTC_ALM_SET", 0x40247007 },
+{ "RTC_SET_TIME", 0x4024700a },
+{ "HFI1_IOCTL_CTXT_INFO", 0x40281be2 },
+{ "FW_CDEV_IOC_SEND_STREAM_PACKET", 0x40282313 },
+{ "EVIOCSKEYCODE_V2", 0x40284504 },
+{ "SNDCTL_FM_LOAD_INSTR", 0x40285107 },
+{ "DRM_IOCTL_AMDGPU_GEM_VA", 0x40286448 },
+{ "DRM_IOCTL_VIA_DMA_BLIT", 0x4028644e },
+{ "DRM_IOCTL_I915_GEM_EXECBUFFER", 0x40286454 },
+{ "RIO_UNMAP_OUTBOUND", 0x40286d10 },
+{ "PHN_SETREGS", 0x40287008 },
+{ "RTC_WKALM_SET", 0x4028700f },
+{ "VHOST_SET_VRING_ADDR", 0x4028af11 },
+{ "EVIOCSFF", 0x402c4580 },
+{ "NVM_DEV_INIT", 0x402c4c24 },
+{ "NVME_IOCTL_SUBMIT_IO", 0x402c4e42 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", 0x402c5342 },
+{ "TCSETS2", 0x402c542b },
+{ "TCSETSW2", 0x402c542c },
+{ "TCSETSF2", 0x402c542d },
+{ "VIDIOC_S_FBUF", 0x402c560b },
+{ "VIDIOC_S_FREQUENCY", 0x402c5639 },
+{ "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", 0x402c6467 },
+{ "VIDIOC_S_HW_FREQ_SEEK", 0x40305652 },
+{ "CHIOSVOLTAG", 0x40306312 },
+{ "BTRFS_IOC_DEFRAG_RANGE", 0x40309410 },
+{ "BTRFS_IOC_SET_FEATURES", 0x40309439 },
+{ "KVM_SET_CLOCK", 0x4030ae7b },
+{ "GSMIOC_ENABLE_NET", 0x40344702 },
+{ "SNDRV_TIMER_IOCTL_SELECT", 0x40345410 },
+{ "VIDIOC_S_AUDIO", 0x40345622 },
+{ "VIDIOC_S_AUDOUT", 0x40345632 },
+{ "DRM_IOCTL_MGA_BLIT", 0x40346448 },
+{ "PTP_PEROUT_REQUEST", 0x40383d03 },
+{ "VIDIOC_DBG_S_REGISTER", 0x4038564f },
+{ "IVTV_IOC_DMA_FRAME", 0x403856c0 },
+{ "KVM_XEN_HVM_CONFIG", 0x4038ae7a },
+{ "SNDRV_TIMER_IOCTL_GPARAMS", 0x403c5404 },
+{ "DMX_SET_FILTER", 0x403c6f2b },
+{ "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", 0x4040534e },
+{ "SNDRV_CTL_IOCTL_ELEM_LOCK", 0x40405514 },
+{ "SNDRV_CTL_IOCTL_ELEM_UNLOCK", 0x40405515 },
+{ "BC_TRANSACTION", 0x40406300 },
+{ "BC_REPLY", 0x40406301 },
+{ "DRM_IOCTL_I810_INIT", 0x40406440 },
+{ "DRM_IOCTL_I915_GEM_EXECBUFFER2", 0x40406469 },
+{ "JSIOCSAXMAP", 0x40406a31 },
+{ "BTRFS_IOC_QUOTA_RESCAN", 0x4040942c },
+{ "KVM_ASSIGN_DEV_IRQ", 0x4040ae70 },
+{ "KVM_DEASSIGN_PCI_DEVICE", 0x4040ae72 },
+{ "KVM_DEASSIGN_DEV_IRQ", 0x4040ae75 },
+{ "KVM_CREATE_PIT2", 0x4040ae77 },
+{ "KVM_IOEVENTFD", 0x4040ae79 },
+{ "KVM_X86_SET_MCE", 0x4040ae9e },
+{ "KVM_SET_VCPU_EVENTS", 0x4040aea0 },
+{ "KVM_ASSIGN_SET_INTX_MASK", 0x4040aea4 },
+{ "KVM_S390_MEM_OP", 0x4040aeb1 },
+{ "KVM_S390_GET_SKEYS", 0x4040aeb2 },
+{ "KVM_S390_SET_SKEYS", 0x4040aeb3 },
+{ "CXL_IOCTL_START_WORK", 0x4040ca00 },
+{ "CXL_IOCTL_DOWNLOAD_IMAGE", 0x4040ca0a },
+{ "CXL_IOCTL_VALIDATE_IMAGE", 0x4040ca0b },
+{ "OMAPFB_SETUP_PLANE", 0x40444f34 },
+{ "OMAPFB_QUERY_PLANE", 0x40444f35 },
+{ "OMAPFB_UPDATE_WINDOW", 0x40444f36 },
+{ "VIDIOC_S_MODULATOR", 0x40445637 },
+{ "DRM_IOCTL_I915_INIT", 0x40446440 },
+{ "BTRFS_IOC_SEND", 0x40449426 },
+{ "SET_ARRAY_INFO", 0x40480923 },
+{ "SNDRV_EMU10K1_IOCTL_PCM_POKE", 0x40484830 },
+{ "KVM_SET_GUEST_DEBUG", 0x4048ae9b },
+{ "KVM_S390_IRQ", 0x4048aeb4 },
+{ "GSMIOC_SETCONF", 0x404c4701 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", 0x404c534a },
+{ "SNDRV_HWDEP_IOCTL_DSP_LOAD", 0x40504803 },
+{ "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", 0x40505330 },
+{ "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", 0x40505331 },
+{ "SNDRV_TIMER_IOCTL_PARAMS", 0x40505412 },
+{ "DRM_IOCTL_SAVAGE_BCI_INIT", 0x40506440 },
+{ "VIDIOC_S_TUNER", 0x4054561e },
+{ "DRM_IOCTL_RADEON_CP_INIT", 0x40546440 },
+{ "FDSETDRVPRM", 0x40580290 },
+{ "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", 0x4058534c },
+{ "DRM_IOCTL_R128_INIT", 0x40586440 },
+{ "UI_DEV_SETUP", 0x405c5503 },
+{ "DRM_IOCTL_MGA_INIT", 0x405c6440 },
+{ "PTP_PIN_SETFUNC", 0x40603d07 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", 0x40605346 },
+{ "UI_END_FF_UPLOAD", 0x406055c9 },
+{ "KVM_ENABLE_CAP", 0x4068aea3 },
+{ "CHIOGELEM", 0x406c6310 },
+{ "KVM_SET_PIT2", 0x4070aea0 },
+{ "HFI1_IOCTL_USER_INFO", 0x40781be3 },
+{ "NILFS_IOCTL_CLEAN_SEGMENTS", 0x40786e88 },
+{ "V4L2_DEVICE_NOTIFY_EVENT", 0x40787602 },
+{ "NVM_DEV_CREATE", 0x40804c22 },
+{ "UBI_IOCVOLCRBLK", 0x40804f07 },
+{ "KVM_PPC_GET_PVINFO", 0x4080aea1 },
+{ "KVM_SET_DEBUGREGS", 0x4080aea2 },
+{ "KVM_PPC_RTAS_DEFINE_TOKEN", 0x4080aeac },
+{ "SNDRV_COMPRESS_SET_PARAMS", 0x40844312 },
+{ "SNDRV_SEQ_IOCTL_DELETE_QUEUE", 0x408c5333 },
+{ "VIDIOC_S_JPEGCOMP", 0x408c563e },
+{ "KVM_SET_REGS", 0x4090ae82 },
+{ "UBI_IOCMKVOL", 0x40986f00 },
+{ "SNDRV_SEQ_IOCTL_DELETE_PORT", 0x40a45321 },
+{ "SNDRV_SEQ_IOCTL_SET_PORT_INFO", 0x40a45323 },
+{ "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", 0x40bc5311 },
+{ "VHOST_SCSI_SET_ENDPOINT", 0x40e8af40 },
+{ "VHOST_SCSI_CLEAR_ENDPOINT", 0x40e8af41 },
+{ "ASHMEM_SET_NAME", 0x41007701 },
+{ "BTRFS_IOC_SET_FSLABEL", 0x41009432 },
+{ "USBDEVFS_GETDRIVER", 0x41045508 },
+{ "CA_SEND_MSG", 0x410c6f85 },
+{ "KVM_SET_SREGS", 0x4138ae84 },
+{ "KVM_SET_XCRS", 0x4188aea7 },
+{ "SNDRV_EMU10K1_IOCTL_CODE_POKE", 0x418c4811 },
+{ "KVM_SET_FPU", 0x41a0ae8d },
+{ "PTP_SYS_OFFSET", 0x43403d05 },
+{ "JSIOCSBTNMAP", 0x44006a33 },
+{ "KVM_SET_LAPIC", 0x4400ae8f },
+{ "BTRFS_IOC_SNAP_CREATE", 0x50009401 },
+{ "BTRFS_IOC_DEFRAG", 0x50009402 },
+{ "BTRFS_IOC_RESIZE", 0x50009403 },
+{ "BTRFS_IOC_SCAN_DEV", 0x50009404 },
+{ "BTRFS_IOC_ADD_DEV", 0x5000940a },
+{ "BTRFS_IOC_RM_DEV", 0x5000940b },
+{ "BTRFS_IOC_BALANCE", 0x5000940c },
+{ "BTRFS_IOC_SUBVOL_CREATE", 0x5000940e },
+{ "BTRFS_IOC_SNAP_DESTROY", 0x5000940f },
+{ "BTRFS_IOC_SNAP_CREATE_V2", 0x50009417 },
+{ "BTRFS_IOC_SUBVOL_CREATE_V2", 0x50009418 },
+{ "BTRFS_IOC_RM_DEV_V2", 0x5000943a },
+{ "KVM_SET_XSAVE", 0x5000aea5 },
+{ "HIDIOCSUSAGES", 0x501c4814 },
+{ "UBI_IOCRNVOL", 0x51106f03 },
+{ "SNDRV_SB_CSP_IOCTL_LOAD_CODE", 0x70124811 },
+{ "MFB_GET_ALPHA", 0x80014d00 },
+{ "MFB_GET_GAMMA", 0x80014d01 },
+{ "USBTMC488_IOCTL_GET_CAPS", 0x80015b11 },
+{ "USBTMC488_IOCTL_READ_STB", 0x80015b12 },
+{ "GADGET_GET_PRINTER_STATUS", 0x80016721 },
+{ "JSIOCGAXES", 0x80016a11 },
+{ "JSIOCGBUTTONS", 0x80016a12 },
+{ "SPI_IOC_RD_MODE", 0x80016b01 },
+{ "SPI_IOC_RD_LSB_FIRST", 0x80016b02 },
+{ "SPI_IOC_RD_BITS_PER_WORD", 0x80016b03 },
+{ "PPRSTATUS", 0x80017081 },
+{ "PPRCONTROL", 0x80017083 },
+{ "PPRDATA", 0x80017085 },
+{ "SONYPI_IOCGBRT", 0x80017600 },
+{ "SONYPI_IOCGBATFLAGS", 0x80017607 },
+{ "SONYPI_IOCGBLUE", 0x80017608 },
+{ "SONYPI_IOCGFAN", 0x8001760a },
+{ "SONYPI_IOCGTEMP", 0x8001760c },
+{ "CAPI_GET_ERRCODE", 0x80024321 },
+{ "CAPI_INSTALLED", 0x80024322 },
+{ "SNDRV_DM_FM_IOCTL_INFO", 0x80024820 },
+{ "IOCTL_WDM_MAX_COMMAND", 0x800248a0 },
+{ "IPMICTL_REGISTER_FOR_CMD", 0x8002690e },
+{ "IPMICTL_UNREGISTER_FOR_CMD", 0x8002690f },
+{ "FE_READ_SIGNAL_STRENGTH", 0x80026f47 },
+{ "FE_READ_SNR", 0x80026f48 },
+{ "SONYPI_IOCGBAT1CAP", 0x80027602 },
+{ "SONYPI_IOCGBAT1REM", 0x80027603 },
+{ "SONYPI_IOCGBAT2CAP", 0x80027604 },
+{ "SONYPI_IOCGBAT2REM", 0x80027605 },
+{ "MBXFB_IOCS_PLANEORDER", 0x8002f403 },
+{ "BLKBSZGET", 0x80041270 },
+{ "BLKGETSIZE64", 0x80041272 },
+{ "HFI1_IOCTL_GET_VERS", 0x80041bee },
+{ "PERF_EVENT_IOC_ID", 0x80042407 },
+{ "FBIO_RADEON_GET_MIRROR", 0x80044003 },
+{ "AGPIOC_INFO", 0x80044100 },
+{ "SNDRV_PCM_IOCTL_PVERSION", 0x80044100 },
+{ "SNDRV_PCM_IOCTL_DELAY", 0x80044121 },
+{ "PMU_IOC_GET_BACKLIGHT", 0x80044201 },
+{ "PMU_IOC_GET_MODEL", 0x80044203 },
+{ "PMU_IOC_HAS_ADB", 0x80044204 },
+{ "PMU_IOC_CAN_SLEEP", 0x80044205 },
+{ "CCISS_GETHEARTBEAT", 0x80044206 },
+{ "PMU_IOC_GRAB_BACKLIGHT", 0x80044206 },
+{ "CCISS_GETBUSTYPES", 0x80044207 },
+{ "CCISS_GETFIRMVER", 0x80044208 },
+{ "CCISS_GETDRIVVER", 0x80044209 },
+{ "SNDRV_COMPRESS_IOCTL_VERSION", 0x80044300 },
+{ "CS_GET_STATE", 0x80044315 },
+{ "CS_GET_IF_VERSION", 0x8004431e },
+{ "CAPI_GET_FLAGS", 0x80044323 },
+{ "CAPI_SET_FLAGS", 0x80044324 },
+{ "CAPI_CLR_FLAGS", 0x80044325 },
+{ "CAPI_NCCI_OPENCOUNT", 0x80044326 },
+{ "CAPI_NCCI_GETUNIT", 0x80044327 },
+{ "EVIOCGVERSION", 0x80044501 },
+{ "APEI_ERST_GET_RECORD_COUNT", 0x80044502 },
+{ "EVIOCGEFFECTS", 0x80044584 },
+{ "FBIOGET_CONTRAST", 0x80044601 },
+{ "FBIGET_BRIGHTNESS", 0x80044603 },
+{ "FBIGET_COLOR", 0x80044605 },
+{ "FBIO_GETCONTROL2", 0x80044689 },
+{ "SSTFB_GET_VGAPASS", 0x800446dd },
+{ "SNDRV_HWDEP_IOCTL_PVERSION", 0x80044800 },
+{ "HIDIOCGRDESCSIZE", 0x80044801 },
+{ "HIDIOCGVERSION", 0x80044801 },
+{ "IOCTL_MEI_NOTIFY_GET", 0x80044803 },
+{ "HIDIOCGFLAG", 0x8004480e },
+{ "HDA_IOCTL_PVERSION", 0x80044810 },
+{ "SNDRV_EMU10K1_IOCTL_PVERSION", 0x80044840 },
+{ "SNDRV_HDSPM_IOCTL_GET_MIXER", 0x80044844 },
+{ "SNDRV_EMUX_IOCTL_VERSION", 0x80044880 },
+{ "SNDRV_EMU10K1_IOCTL_DBG_READ", 0x80044884 },
+{ "HCIGETDEVLIST", 0x800448d2 },
+{ "HCIGETDEVINFO", 0x800448d3 },
+{ "HCIGETCONNLIST", 0x800448d4 },
+{ "HCIGETCONNINFO", 0x800448d5 },
+{ "HCIGETAUTHINFO", 0x800448d7 },
+{ "HCIINQUIRY", 0x800448f0 },
+{ "ROCCATIOCGREPSIZE", 0x800448f1 },
+{ "IMADDTIMER", 0x80044940 },
+{ "IMDELTIMER", 0x80044941 },
+{ "IMGETVERSION", 0x80044942 },
+{ "IMGETCOUNT", 0x80044943 },
+{ "IMGETDEVINFO", 0x80044944 },
+{ "IMCTRLREQ", 0x80044945 },
+{ "IMCLEAR_L2", 0x80044946 },
+{ "IMHOLD_L1", 0x80044948 },
+{ "MCE_GET_RECORD_LEN", 0x80044d01 },
+{ "MCE_GET_LOG_LEN", 0x80044d02 },
+{ "MCE_GETCLEAR_FLAGS", 0x80044d03 },
+{ "MEMGETREGIONCOUNT", 0x80044d07 },
+{ "MFB_GET_PIXFMT", 0x80044d08 },
+{ "OTPSELECT", 0x80044d0d },
+{ "OSS_GETVERSION", 0x80044d76 },
+{ "UBI_IOCEBISMAP", 0x80044f05 },
+{ "SOUND_PCM_READ_RATE", 0x80045002 },
+{ "SOUND_PCM_READ_BITS", 0x80045005 },
+{ "SOUND_PCM_READ_CHANNELS", 0x80045006 },
+{ "SOUND_PCM_READ_FILTER", 0x80045007 },
+{ "SNDCTL_DSP_GETFMTS", 0x8004500b },
+{ "SNDCTL_DSP_GETCAPS", 0x8004500f },
+{ "SNDCTL_DSP_GETTRIGGER", 0x80045010 },
+{ "SNDCTL_DSP_GETODELAY", 0x80045017 },
+{ "SNDCTL_DSP_GETSPDIF", 0x80045043 },
+{ "SNDCTL_SEQ_GETOUTCOUNT", 0x80045104 },
+{ "SNDCTL_SEQ_GETINCOUNT", 0x80045105 },
+{ "SNDCTL_SEQ_NRSYNTHS", 0x8004510a },
+{ "SNDCTL_SEQ_NRMIDIS", 0x8004510b },
+{ "SNDCTL_SEQ_GETTIME", 0x80045113 },
+{ "RNDGETENTCNT", 0x80045200 },
+{ "SAA6588_CMD_READ", 0x80045203 },
+{ "SAA6588_CMD_POLL", 0x80045204 },
+{ "RFCOMMGETDEVLIST", 0x800452d2 },
+{ "RFCOMMGETDEVINFO", 0x800452d3 },
+{ "SNDRV_SEQ_IOCTL_PVERSION", 0x80045300 },
+{ "SNDRV_SEQ_IOCTL_CLIENT_ID", 0x80045301 },
+{ "SNDRV_TIMER_IOCTL_PVERSION", 0x80045400 },
+{ "TIOCGPTN", 0x80045430 },
+{ "TIOCGDEV", 0x80045432 },
+{ "TIOCGPKT", 0x80045438 },
+{ "TIOCGPTLCK", 0x80045439 },
+{ "TIOCGEXCL", 0x80045440 },
+{ "TUNGETFEATURES", 0x800454cf },
+{ "TUNGETIFF", 0x800454d2 },
+{ "TUNGETSNDBUF", 0x800454d3 },
+{ "TUNGETVNETHDRSZ", 0x800454d7 },
+{ "TUNGETVNETLE", 0x800454dd },
+{ "TUNGETVNETBE", 0x800454df },
+{ "SNDRV_CTL_IOCTL_PVERSION", 0x80045500 },
+{ "USBDEVFS_RESETEP", 0x80045503 },
+{ "USBDEVFS_SETCONFIGURATION", 0x80045505 },
+{ "USBDEVFS_CLAIMINTERFACE", 0x8004550f },
+{ "USBDEVFS_RELEASEINTERFACE", 0x80045510 },
+{ "USBDEVFS_CLEAR_HALT", 0x80045515 },
+{ "USBDEVFS_CLAIM_PORT", 0x80045518 },
+{ "USBDEVFS_RELEASE_PORT", 0x80045519 },
+{ "USBDEVFS_GET_CAPABILITIES", 0x8004551a },
+{ "UI_GET_VERSION", 0x8004552d },
+{ "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", 0x80045530 },
+{ "SNDRV_CTL_IOCTL_POWER_STATE", 0x800455d1 },
+{ "VIDIOC_G_INPUT", 0x80045626 },
+{ "VIDIOC_G_OUTPUT", 0x8004562e },
+{ "VIDIOC_G_PRIORITY", 0x80045643 },
+{ "SNDRV_RAWMIDI_IOCTL_PVERSION", 0x80045700 },
+{ "WDIOC_GETSTATUS", 0x80045701 },
+{ "WDIOC_GETBOOTSTATUS", 0x80045702 },
+{ "WDIOC_GETTEMP", 0x80045703 },
+{ "WDIOC_SETOPTIONS", 0x80045704 },
+{ "WDIOC_KEEPALIVE", 0x80045705 },
+{ "WDIOC_GETTIMEOUT", 0x80045707 },
+{ "WDIOC_GETPRETIMEOUT", 0x80045709 },
+{ "WDIOC_GETTIMELEFT", 0x8004570a },
+{ "SONET_GETDIAG", 0x80046114 },
+{ "SONET_GETFRAMING", 0x80046116 },
+{ "CM_IOCGSTATUS", 0x80046300 },
+{ "KCOV_INIT_TRACE", 0x80046301 },
+{ "CHIOGPICKER", 0x80046304 },
+{ "DRM_IOCTL_GET_MAGIC", 0x80046402 },
+{ "DRM_IOCTL_I915_GET_VBLANK_PIPE", 0x8004644e },
+{ "FS_IOC32_GETFLAGS", 0x80046601 },
+{ "FS_IOC_GETFLAGS", 0x80046601 },
+{ "LIRC_GET_FEATURES", 0x80046900 },
+{ "LIRC_GET_SEND_MODE", 0x80046901 },
+{ "LIRC_GET_REC_MODE", 0x80046902 },
+{ "LIRC_GET_SEND_CARRIER", 0x80046903 },
+{ "LIRC_GET_REC_CARRIER", 0x80046904 },
+{ "LIRC_GET_SEND_DUTY_CYCLE", 0x80046905 },
+{ "LIRC_GET_REC_DUTY_CYCLE", 0x80046906 },
+{ "LIRC_GET_REC_RESOLUTION", 0x80046907 },
+{ "I2OVALIDATE", 0x80046908 },
+{ "LIRC_GET_MIN_TIMEOUT", 0x80046908 },
+{ "LIRC_GET_MAX_TIMEOUT", 0x80046909 },
+{ "LIRC_GET_MIN_FILTER_PULSE", 0x8004690a },
+{ "LIRC_GET_MAX_FILTER_PULSE", 0x8004690b },
+{ "LIRC_GET_MIN_FILTER_SPACE", 0x8004690c },
+{ "LIRC_GET_MAX_FILTER_SPACE", 0x8004690d },
+{ "LIRC_GET_LENGTH", 0x8004690f },
+{ "IPMICTL_SET_GETS_EVENTS_CMD", 0x80046910 },
+{ "IPMICTL_SET_MY_ADDRESS_CMD", 0x80046911 },
+{ "IPMICTL_GET_MY_ADDRESS_CMD", 0x80046912 },
+{ "IPMICTL_SET_MY_LUN_CMD", 0x80046913 },
+{ "IPMICTL_GET_MY_LUN_CMD", 0x80046914 },
+{ "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", 0x80046918 },
+{ "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", 0x80046919 },
+{ "IPMICTL_SET_MY_CHANNEL_LUN_CMD", 0x8004691a },
+{ "IPMICTL_GET_MY_CHANNEL_LUN_CMD", 0x8004691b },
+{ "IPMICTL_GET_MAINTENANCE_MODE_CMD", 0x8004691e },
+{ "I8K_BIOS_VERSION", 0x80046980 },
+{ "I8K_MACHINE_ID", 0x80046981 },
+{ "I8K_POWER_STATUS", 0x80046982 },
+{ "I8K_FN_STATUS", 0x80046983 },
+{ "I8K_GET_TEMP", 0x80046984 },
+{ "IIO_GET_EVENT_FD_IOCTL", 0x80046990 },
+{ "JSIOCGVERSION", 0x80046a01 },
+{ "SPI_IOC_RD_MAX_SPEED_HZ", 0x80046b04 },
+{ "SPI_IOC_RD_MODE32", 0x80046b05 },
+{ "UDF_GETEASIZE", 0x80046c40 },
+{ "UDF_GETEABLOCK", 0x80046c41 },
+{ "UDF_GETVOLIDENT", 0x80046c42 },
+{ "MMTIMER_GETRES", 0x80046d01 },
+{ "MMTIMER_GETFREQ", 0x80046d02 },
+{ "MTIOCPOS", 0x80046d03 },
+{ "RIO_MPORT_MAINT_PORT_IDX_GET", 0x80046d03 },
+{ "MMTIMER_GETCOUNTER", 0x80046d09 },
+{ "RIO_GET_EVENT_MASK", 0x80046d0e },
+{ "NCP_IOC_SIGN_WANTED", 0x80046e06 },
+{ "NCP_IOC_SETDENTRYTTL", 0x80046e0c },
+{ "MATROXFB_GET_OUTPUT_CONNECTION", 0x80046ef8 },
+{ "SISFB_GET_INFO_OLD", 0x80046ef8 },
+{ "MATROXFB_GET_AVAILABLE_OUTPUTS", 0x80046ef9 },
+{ "SISFB_GET_VBRSTATUS_OLD", 0x80046ef9 },
+{ "SISFB_GET_AUTOMAXIMIZE_OLD", 0x80046efa },
+{ "MATROXFB_GET_ALL_OUTPUTS", 0x80046efb },
+{ "AUDIO_GET_CAPABILITIES", 0x80046f0b },
+{ "VIDEO_GET_CAPABILITIES", 0x80046f21 },
+{ "VIDEO_GET_FRAME_RATE", 0x80046f38 },
+{ "FE_READ_STATUS", 0x80046f45 },
+{ "FE_READ_BER", 0x80046f46 },
+{ "FE_READ_UNCORRECTED_BLOCKS", 0x80046f49 },
+{ "RTC_IRQP_READ", 0x8004700b },
+{ "RTC_EPOCH_READ", 0x8004700d },
+{ "RTC_VL_READ", 0x80047013 },
+{ "PPCLRIRQ", 0x80047093 },
+{ "PPGETMODES", 0x80047097 },
+{ "PPGETMODE", 0x80047098 },
+{ "PPGETPHASE", 0x80047099 },
+{ "PPGETFLAGS", 0x8004709a },
+{ "PPS_GETPARAMS", 0x800470a1 },
+{ "PPS_GETCAP", 0x800470a3 },
+{ "PHONE_CAPABILITIES_LIST", 0x80047181 },
+{ "PHONE_DTMF_READY", 0x80047196 },
+{ "PHONE_GET_DTMF", 0x80047197 },
+{ "PHONE_GET_DTMF_ASCII", 0x80047198 },
+{ "PHONE_EXCEPTION", 0x8004719a },
+{ "IXJCTL_CARDTYPE", 0x800471c1 },
+{ "IXJCTL_SERIAL", 0x800471c2 },
+{ "IXJCTL_DSP_TYPE", 0x800471c3 },
+{ "IXJCTL_DSP_VERSION", 0x800471c4 },
+{ "IXJCTL_CID", 0x800471d4 },
+{ "IXJCTL_VMWI", 0x800471d8 },
+{ "IXJCTL_VERSION", 0x800471da },
+{ "IXJCTL_FRAMES_READ", 0x800471e2 },
+{ "IXJCTL_FRAMES_WRITTEN", 0x800471e3 },
+{ "IXJCTL_READ_WAIT", 0x800471e4 },
+{ "IXJCTL_WRITE_WAIT", 0x800471e5 },
+{ "IXJCTL_DRYBUFFER_READ", 0x800471e6 },
+{ "BR_ERROR", 0x80047200 },
+{ "BR_ACQUIRE_RESULT", 0x80047204 },
+{ "FAT_IOCTL_GET_ATTRIBUTES", 0x80047210 },
+{ "FAT_IOCTL_GET_VOLUME_ID", 0x80047213 },
+{ "PPPIOCGCHAN", 0x80047437 },
+{ "PPPIOCGDEBUG", 0x80047441 },
+{ "PPPIOCGMRU", 0x80047453 },
+{ "PPPIOCGRASYNCMAP", 0x80047455 },
+{ "PPPIOCGUNIT", 0x80047456 },
+{ "PPPIOCGASYNCMAP", 0x80047458 },
+{ "PPPIOCGFLAGS", 0x8004745a },
+{ "PPPIOCGMPFLAGS", 0x80047482 },
+{ "FS_IOC32_GETVERSION", 0x80047601 },
+{ "FS_IOC_GETVERSION", 0x80047601 },
+{ "MEYEIOC_STILLJCAPT", 0x800476c5 },
+{ "OSIOCGNETADDR", 0x800489e1 },
+{ "SIOCGNETADDR", 0x800489e1 },
+{ "AUTOFS_IOC_PROTOVER", 0x80049363 },
+{ "AUTOFS_IOC_PROTOSUBVER", 0x80049367 },
+{ "AUTOFS_IOC_ASKUMOUNT", 0x80049370 },
+{ "GENWQE_GET_CARD_STATE", 0x8004a524 },
+{ "KVM_GET_MP_STATE", 0x8004ae98 },
+{ "CXL_IOCTL_GET_PROCESS_ELEMENT", 0x8004ca01 },
+{ "FUSE_DEV_IOC_CLONE", 0x8004e500 },
+{ "SISFB_GET_INFO_SIZE", 0x8004f300 },
+{ "SISFB_GET_VBRSTATUS", 0x8004f302 },
+{ "SISFB_GET_AUTOMAXIMIZE", 0x8004f303 },
+{ "SISFB_GET_TVPOSOFFSET", 0x8004f304 },
+{ "SONET_GETFRSENSE", 0x80066117 },
+{ "MEYEIOC_G_PARAMS", 0x800676c0 },
+{ "SNAPSHOT_GET_IMAGE_SIZE", 0x8008330e },
+{ "SNAPSHOT_AVAIL_SWAP_SIZE", 0x80083313 },
+{ "SNAPSHOT_ALLOC_SWAP_PAGE", 0x80083314 },
+{ "CCISS_GETPCIINFO", 0x80084201 },
+{ "CCISS_GETINTINFO", 0x80084202 },
+{ "EVIOCGID", 0x80084502 },
+{ "EVIOCGREP", 0x80084503 },
+{ "EVIOCGKEYCODE", 0x80084504 },
+{ "HIDIOCGRAWINFO", 0x80084803 },
+{ "SNDRV_HDSP_IOCTL_GET_VERSION", 0x80084843 },
+{ "SNDRV_HDSP_IOCTL_GET_9632_AEB", 0x80084845 },
+{ "AMDKFD_IOC_GET_VERSION", 0x80084b01 },
+{ "MFB_GET_AOID", 0x80084d04 },
+{ "MEMISLOCKED", 0x80084d17 },
+{ "SNDCTL_DSP_MAPINBUF", 0x80085013 },
+{ "SNDCTL_DSP_MAPOUTBUF", 0x80085014 },
+{ "RNDGETPOOL", 0x80085202 },
+{ "TUNGETFILTER", 0x800854db },
+{ "USBDEVFS_SETINTERFACE", 0x80085504 },
+{ "USBDEVFS_DISCSIGNAL", 0x8008550e },
+{ "USBDEVFS_ALLOC_STREAMS", 0x8008551c },
+{ "USBDEVFS_FREE_STREAMS", 0x8008551d },
+{ "VIDIOC_G_STD", 0x80085617 },
+{ "VIDIOC_QUERYSTD", 0x8008563f },
+{ "DRM_IOCTL_I810_OV0INFO", 0x80086449 },
+{ "I2OPASSTHRU", 0x8008690c },
+{ "IPMICTL_SET_TIMING_PARMS_CMD", 0x80086916 },
+{ "IPMICTL_GET_TIMING_PARMS_CMD", 0x80086917 },
+{ "NCP_IOC_SETPRIVATEDATA", 0x80086e0a },
+{ "NILFS_IOCTL_SYNC", 0x80086e8a },
+{ "AUDIO_GET_PTS", 0x80086f13 },
+{ "DMX_GET_CAPS", 0x80086f30 },
+{ "VIDEO_GET_PTS", 0x80086f39 },
+{ "VIDEO_GET_FRAME_COUNT", 0x80086f3a },
+{ "FE_GET_PROPERTY", 0x80086f53 },
+{ "CA_GET_DESCR_INFO", 0x80086f83 },
+{ "OSD_GET_CAPABILITY", 0x80086fa1 },
+{ "PPGETTIME", 0x80087095 },
+{ "BR_DEAD_BINDER", 0x8008720f },
+{ "BR_CLEAR_DEATH_NOTIFICATION_DONE", 0x80087210 },
+{ "PPPIOCGIDLE", 0x8008743f },
+{ "BTRFS_IOC_START_SYNC", 0x80089418 },
+{ "BTRFS_IOC_SUBVOL_GETFLAGS", 0x80089419 },
+{ "KVM_X86_GET_MCE_CAP_SUPPORTED", 0x8008ae9d },
+{ "KVM_ALLOCATE_RMA", 0x8008aea9 },
+{ "VHOST_GET_FEATURES", 0x8008af00 },
+{ "FUNCTIONFS_ENDPOINT_DESC", 0x80096782 },
+{ "DMX_GET_PES_PIDS", 0x800a6f2f },
+{ "RAID_VERSION", 0x800c0910 },
+{ "FW_CDEV_IOC_GET_CYCLE_TIMER", 0x800c230c },
+{ "SNDRV_PCM_IOCTL_READI_FRAMES", 0x800c4151 },
+{ "SNDRV_PCM_IOCTL_READN_FRAMES", 0x800c4153 },
+{ "CCISS_GETLUNINFO", 0x800c4211 },
+{ "OTPLOCK", 0x800c4d10 },
+{ "OMAPFB_GET_CAPS", 0x800c4f2a },
+{ "SNDCTL_DSP_GETIPTR", 0x800c5011 },
+{ "SNDCTL_DSP_GETOPTR", 0x800c5012 },
+{ "FS_IOC_SET_ENCRYPTION_POLICY", 0x800c6613 },
+{ "HPET_INFO", 0x800c6803 },
+{ "IPMICTL_REGISTER_FOR_CMD_CHANS", 0x800c691c },
+{ "IPMICTL_UNREGISTER_FOR_CMD_CHANS", 0x800c691d },
+{ "NCP_IOC_NCPREQUEST", 0x800c6e01 },
+{ "NCP_IOC_SETROOT", 0x800c6e08 },
+{ "NCP_IOC_SETOBJECTNAME", 0x800c6e09 },
+{ "VIDEO_GET_SIZE", 0x800c6f37 },
+{ "FE_DISEQC_RECV_SLAVE_REPLY", 0x800c6f40 },
+{ "CA_GET_SLOT_INFO", 0x800c6f82 },
+{ "FDGETDRVTYP", 0x8010020f },
+{ "STP_POLICY_ID_GET", 0x80102501 },
+{ "SNDRV_PCM_IOCTL_CHANNEL_INFO", 0x80104132 },
+{ "CCISS_GETNODENAME", 0x80104204 },
+{ "EVIOCGMASK", 0x80104592 },
+{ "SNDRV_HDSPM_IOCTL_GET_LTC", 0x80104846 },
+{ "ECCGETSTATS", 0x80104d12 },
+{ "OMAPFB_MEMORY_READ", 0x80104f3a },
+{ "SNDCTL_DSP_GETOSPACE", 0x8010500c },
+{ "SNDCTL_DSP_GETISPACE", 0x8010500d },
+{ "DRM_IOCTL_I915_GEM_GET_APERTURE", 0x80106463 },
+{ "MGSL_IOCGGPIO", 0x80106d11 },
+{ "CA_GET_CAP", 0x80106f81 },
+{ "BR_INCREFS", 0x80107207 },
+{ "BR_ACQUIRE", 0x80107208 },
+{ "BR_RELEASE", 0x80107209 },
+{ "BR_DECREFS", 0x8010720a },
+{ "PPPIOCGIFNAME", 0x80107488 },
+{ "GENWQE_READ_REG64", 0x8010a51e },
+{ "GENWQE_READ_REG32", 0x8010a520 },
+{ "GENWQE_READ_REG16", 0x8010a522 },
+{ "UFFDIO_UNREGISTER", 0x8010aa01 },
+{ "UFFDIO_WAKE", 0x8010aa02 },
+{ "FDGETMAXERRS", 0x8014020e },
+{ "GET_DISK_INFO", 0x80140912 },
+{ "SNDRV_COMPRESS_TSTAMP", 0x80144320 },
+{ "CHIOGPARAMS", 0x80146306 },
+{ "IPMICTL_SEND_COMMAND", 0x8014690d },
+{ "NCP_IOC_LOCKUNLOCK", 0x80146e07 },
+{ "VIDEO_GET_STATUS", 0x80146f1b },
+{ "VIDEO_GET_EVENT", 0x80146f1c },
+{ "BR_ATTEMPT_ACQUIRE", 0x8014720b },
+{ "FDWERRORGET", 0x80180217 },
+{ "SNDRV_HDSPM_IOCTL_GET_CONFIG", 0x80184841 },
+{ "IMSETDEVNAME", 0x80184947 },
+{ "RIO_MPORT_MAINT_READ_LOCAL", 0x80186d05 },
+{ "RIO_MPORT_MAINT_READ_REMOTE", 0x80186d07 },
+{ "NCP_IOC_SIGN_INIT", 0x80186e05 },
+{ "NILFS_IOCTL_GET_CPINFO", 0x80186e82 },
+{ "NILFS_IOCTL_GET_CPSTAT", 0x80186e83 },
+{ "NILFS_IOCTL_GET_SUINFO", 0x80186e84 },
+{ "BTRFS_IOC_GET_FEATURES", 0x80189439 },
+{ "MBXFB_IOCG_ALPHA", 0x8018f401 },
+{ "FDGETPRM", 0x801c0204 },
+{ "SNDRV_COMPRESS_AVAIL", 0x801c4321 },
+{ "HIDIOCGDEVINFO", 0x801c4803 },
+{ "SNDRV_HDSPM_IOCTL_GET_STATUS", 0x801c4847 },
+{ "FS_IOC_FSGETXATTR", 0x801c581f },
+{ "IPMICTL_SEND_COMMAND_SETTIME", 0x801c6915 },
+{ "MTIOCGET", 0x801c6d02 },
+{ "RTC_PLL_GET", 0x801c7011 },
+{ "FDGETFDCSTAT", 0x80200215 },
+{ "FBIOGET_VBLANK", 0x80204612 },
+{ "SNDRV_FIREWIRE_IOCTL_GET_INFO", 0x802048f8 },
+{ "MEMGETINFO", 0x80204d01 },
+{ "OMAPFB_GET_VRAM_INFO", 0x80204f3d },
+{ "OMAPFB_GET_DISPLAY_INFO", 0x80204f3f },
+{ "DRM_IOCTL_AGP_INFO", 0x80206433 },
+{ "I2OGETIOPS", 0x80206900 },
+{ "MGSL_IOCGPARAMS", 0x80206d01 },
+{ "AUDIO_GET_STATUS", 0x80206f0a },
+{ "PPPIOCGXASYNCMAP", 0x80207450 },
+{ "PPPIOCGCOMPRESSORS", 0x80207486 },
+{ "KVM_ARM_PREFERRED_TARGET", 0x8020aeaf },
+{ "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", 0x80244841 },
+{ "SNDRV_HDSPM_IOCTL_GET_VERSION", 0x80244848 },
+{ "SONET_GETSTAT", 0x80246110 },
+{ "SONET_GETSTATZ", 0x80246111 },
+{ "JSIOCGCORR", 0x80246a22 },
+{ "FE_GET_FRONTEND", 0x80246f4d },
+{ "RTC_ALM_READ", 0x80247008 },
+{ "RTC_RD_TIME", 0x80247009 },
+{ "EVIOCGKEYCODE_V2", 0x80284504 },
+{ "SNDRV_SB_CSP_IOCTL_INFO", 0x80284810 },
+{ "WDIOC_GETSUPPORT", 0x80285700 },
+{ "FE_GET_EVENT", 0x80286f4e },
+{ "RTC_WKALM_RD", 0x80287010 },
+{ "IOW_GETINFO", 0x8028c003 },
+{ "USBDEVFS_SUBMITURB32", 0x802a550a },
+{ "NCP_IOC_SETCHARSETS", 0x802a6e0b },
+{ "TCGETS2", 0x802c542a },
+{ "USBDEVFS_SUBMITURB", 0x802c550a },
+{ "VIDIOC_G_FBUF", 0x802c560a },
+{ "SOUND_OLD_MIXER_INFO", 0x80304d65 },
+{ "RIO_MPORT_GET_PROPERTIES", 0x80306d04 },
+{ "NILFS_IOCTL_GET_SUSTAT", 0x80306e85 },
+{ "BTRFS_IOC_QGROUP_LIMIT", 0x8030942b },
+{ "KVM_GET_CLOCK", 0x8030ae7c },
+{ "FDGETDRVSTAT", 0x80340212 },
+{ "FDPOLLDRVSTAT", 0x80340213 },
+{ "VIDIOC_G_AUDIO", 0x80345621 },
+{ "VIDIOC_G_AUDOUT", 0x80345631 },
+{ "OMAPFB_GET_OVERLAY_COLORMODE", 0x803c4f3b },
+{ "SNDRV_HWDEP_IOCTL_DSP_STATUS", 0x80404802 },
+{ "JSIOCGAXMAP", 0x80406a32 },
+{ "BR_TRANSACTION", 0x80407202 },
+{ "BR_REPLY", 0x80407203 },
+{ "BTRFS_IOC_QUOTA_RESCAN_STATUS", 0x8040942d },
+{ "KVM_ASSIGN_PCI_DEVICE", 0x8040ae69 },
+{ "KVM_GET_VCPU_EVENTS", 0x8040ae9f },
+{ "CXL_IOCTL_GET_AFU_ID", 0x8040ca02 },
+{ "GPIO_GET_CHIPINFO_IOCTL", 0x8044b401 },
+{ "GET_ARRAY_INFO", 0x80480911 },
+{ "PPPIOCGL2TPSTATS", 0x80487436 },
+{ "BTRFS_IOC_GET_SUPPORTED_FEATURES", 0x80489439 },
+{ "KVM_SET_PIT", 0x8048ae66 },
+{ "GSMIOC_GETCONF", 0x804c4700 },
+{ "PTP_CLOCK_GETCAPS", 0x80503d01 },
+{ "FDGETDRVPRM", 0x80580211 },
+{ "SNDRV_TIMER_IOCTL_STATUS", 0x80585414 },
+{ "SOUND_MIXER_INFO", 0x805c4d65 },
+{ "VIDIOC_QUERYCAP", 0x80685600 },
+{ "I2OEVTGET", 0x8068690b },
+{ "SNDRV_PCM_IOCTL_STATUS", 0x806c4120 },
+{ "CHIOGVPARAMS", 0x80706313 },
+{ "KVM_GET_PIT2", 0x8070ae9f },
+{ "SNDRV_COMPRESS_GET_PARAMS", 0x80784313 },
+{ "VIDIOC_DQEVENT", 0x80785659 },
+{ "DRM_IOCTL_GET_STATS", 0x807c6406 },
+{ "USBDEVFS_HUB_PORTINFO", 0x80805513 },
+{ "KVM_GET_DEBUGREGS", 0x8080aea1 },
+{ "VIDIOC_QUERY_DV_TIMINGS", 0x80845663 },
+{ "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", 0x80845663 },
+{ "VIDIOC_G_JPEGCOMP", 0x808c563d },
+{ "KVM_GET_REGS", 0x8090ae81 },
+{ "FE_GET_INFO", 0x80a86f3d },
+{ "MEMGETOOBSEL", 0x80c84d0a },
+{ "SNDRV_HWDEP_IOCTL_INFO", 0x80dc4801 },
+{ "SNDRV_CTL_IOCTL_HWDEP_INFO", 0x80dc5521 },
+{ "SNDRV_TIMER_IOCTL_INFO", 0x80e05411 },
+{ "ASHMEM_GET_NAME", 0x81007702 },
+{ "BTRFS_IOC_GET_FSLABEL", 0x81009431 },
+{ "HIDIOCGSTRING", 0x81044804 },
+{ "USBDEVFS_DISCONNECT_CLAIM", 0x8108551b },
+{ "SNDRV_RAWMIDI_IOCTL_INFO", 0x810c5701 },
+{ "CA_GET_MSG", 0x810c6f84 },
+{ "AUTOFS_IOC_EXPIRE", 0x810c9365 },
+{ "SISFB_GET_INFO", 0x811cf301 },
+{ "SNDRV_PCM_IOCTL_INFO", 0x81204101 },
+{ "KVM_GET_SREGS", 0x8138ae83 },
+{ "ECCGETLAYOUT", 0x81484d11 },
+{ "SNDRV_CTL_IOCTL_CARD_INFO", 0x81785501 },
+{ "KVM_GET_XCRS", 0x8188aea6 },
+{ "AMDKFD_IOC_GET_PROCESS_APERTURES", 0x81904b06 },
+{ "KVM_GET_FPU", 0x81a0ae8c },
+{ "KVM_SET_IRQCHIP", 0x8208ae63 },
+{ "VFAT_IOCTL_READDIR_BOTH", 0x82187201 },
+{ "VFAT_IOCTL_READDIR_SHORT", 0x82187202 },
+{ "KVM_PPC_GET_SMMU_INFO", 0x8250aea6 },
+{ "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", 0x83b04840 },
+{ "JSIOCGBTNMAP", 0x84006a34 },
+{ "BTRFS_IOC_FS_INFO", 0x8400941f },
+{ "BTRFS_IOC_BALANCE_PROGRESS", 0x84009422 },
+{ "KVM_GET_LAPIC", 0x8400ae8e },
+{ "VIDEO_GET_NAVI", 0x84046f34 },
+{ "SNDRV_EMU10K1_IOCTL_INFO", 0x880c4810 },
+{ "VIDIOC_G_ENC_INDEX", 0x8818564c },
+{ "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", 0x89084842 },
+{ "SNDCTL_COPR_RCVMSG", 0x8fa44309 },
+{ "GET_BITMAP_FILE", 0x90000915 },
+{ "SNDRV_HDSP_IOCTL_GET_MIXER", 0x90004844 },
+{ "NVM_GET_DEVICES", 0x90004c21 },
+{ "BTRFS_IOC_DEVICES_READY", 0x90009427 },
+{ "KVM_GET_XSAVE", 0x9000aea4 },
+{ "HIDIOCGRDESC", 0x90044802 },
+{ "GADGET_SET_PRINTER_STATUS", 0xc0016722 },
+{ "AGPIOC_ALLOCATE", 0xc0044106 },
+{ "CAPI_GET_MANUFACTURER", 0xc0044306 },
+{ "CAPI_GET_SERIAL", 0xc0044308 },
+{ "GIGASET_REDIR", 0xc0044700 },
+{ "GIGASET_CONFIG", 0xc0044701 },
+{ "ION_IOC_FREE", 0xc0044901 },
+{ "SOUND_MIXER_AGC", 0xc0044d67 },
+{ "SOUND_MIXER_3DSE", 0xc0044d68 },
+{ "SOUND_MIXER_PRIVATE1", 0xc0044d6f },
+{ "SOUND_MIXER_PRIVATE2", 0xc0044d70 },
+{ "SOUND_MIXER_PRIVATE3", 0xc0044d71 },
+{ "SOUND_MIXER_PRIVATE4", 0xc0044d72 },
+{ "SOUND_MIXER_PRIVATE5", 0xc0044d73 },
+{ "SNDCTL_DSP_SPEED", 0xc0045002 },
+{ "SNDCTL_DSP_STEREO", 0xc0045003 },
+{ "SNDCTL_DSP_GETBLKSIZE", 0xc0045004 },
+{ "SNDCTL_DSP_SETFMT", 0xc0045005 },
+{ "SNDCTL_DSP_CHANNELS", 0xc0045006 },
+{ "SOUND_PCM_WRITE_FILTER", 0xc0045007 },
+{ "SNDCTL_DSP_SUBDIVIDE", 0xc0045009 },
+{ "SNDCTL_DSP_SETFRAGMENT", 0xc004500a },
+{ "SNDCTL_DSP_GETCHANNELMASK", 0xc0045040 },
+{ "SNDCTL_DSP_BIND_CHANNEL", 0xc0045041 },
+{ "SNDCTL_SEQ_CTRLRATE", 0xc0045103 },
+{ "SNDCTL_SYNTH_MEMAVL", 0xc004510e },
+{ "SNDCTL_TMR_TIMEBASE", 0xc0045401 },
+{ "SNDCTL_TMR_TEMPO", 0xc0045405 },
+{ "SNDCTL_TMR_SOURCE", 0xc0045406 },
+{ "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", 0xc0045516 },
+{ "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", 0xc0045520 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", 0xc0045540 },
+{ "SNDRV_CTL_IOCTL_POWER", 0xc00455d0 },
+{ "VIDIOC_S_INPUT", 0xc0045627 },
+{ "VIDIOC_S_OUTPUT", 0xc004562f },
+{ "VIDIOC_OMAP3ISP_STAT_EN", 0xc00456c7 },
+{ "WDIOC_SETTIMEOUT", 0xc0045706 },
+{ "WDIOC_SETPRETIMEOUT", 0xc0045708 },
+{ "FIFREEZE", 0xc0045877 },
+{ "FITHAW", 0xc0045878 },
+{ "SONET_SETDIAG", 0xc0046112 },
+{ "SONET_CLRDIAG", 0xc0046113 },
+{ "BINDER_VERSION", 0xc0046209 },
+{ "CM_IOCGATR", 0xc0046301 },
+{ "CIOC_KERNEL_VERSION", 0xc004630a },
+{ "DRM_IOCTL_BLOCK", 0xc0046412 },
+{ "DRM_IOCTL_UNBLOCK", 0xc0046413 },
+{ "DRM_IOCTL_ADD_DRAW", 0xc0046427 },
+{ "DRM_IOCTL_RM_DRAW", 0xc0046428 },
+{ "DRM_IOCTL_I915_IRQ_EMIT", 0xc0046444 },
+{ "DRM_IOCTL_MGA_WAIT_FENCE", 0xc004644b },
+{ "DRM_IOCTL_RADEON_IRQ_EMIT", 0xc0046456 },
+{ "DRM_IOCTL_MODE_RMFB", 0xc00464af },
+{ "DRM_IOCTL_MODE_DESTROY_DUMB", 0xc00464b4 },
+{ "DRM_IOCTL_MODE_DESTROYPROPBLOB", 0xc00464be },
+{ "I8K_GET_SPEED", 0xc0046985 },
+{ "I8K_GET_FAN", 0xc0046986 },
+{ "I8K_SET_FAN", 0xc0046987 },
+{ "UDF_RELOCATE_BLOCKS", 0xc0046c43 },
+{ "SNDCTL_MIDI_PRETIME", 0xc0046d00 },
+{ "SNDCTL_MIDI_MPUMODE", 0xc0046d01 },
+{ "MGSL_IOCWAITEVENT", 0xc0046d08 },
+{ "MATROXFB_GET_OUTPUT_MODE", 0xc0046efa },
+{ "PHN_GET_REG", 0xc0047000 },
+{ "PHN_GET_REGS", 0xc0047002 },
+{ "PPS_FETCH", 0xc00470a4 },
+{ "PHONE_QUERY_CODEC", 0xc00471a7 },
+{ "MIC_VIRTIO_ADD_DEVICE", 0xc0047301 },
+{ "MIC_VIRTIO_COPY_DESC", 0xc0047302 },
+{ "MIC_VIRTIO_CONFIG_CHANGE", 0xc0047305 },
+{ "SCIF_FENCE_WAIT", 0xc0047310 },
+{ "PPPIOCNEWUNIT", 0xc004743e },
+{ "MEYEIOC_SYNC", 0xc00476c3 },
+{ "AUTOFS_IOC_SETTIMEOUT", 0xc0049364 },
+{ "KVM_GET_MSR_INDEX_LIST", 0xc004ae02 },
+{ "KVM_PPC_ALLOCATE_HTAB", 0xc004aea7 },
+{ "NET_ADD_IF", 0xc0066f34 },
+{ "NET_GET_IF", 0xc0066f36 },
+{ "CAPI_MANUFACTURER_CMD", 0xc0084320 },
+{ "HDA_IOCTL_VERB_WRITE", 0xc0084811 },
+{ "HDA_IOCTL_GET_WCAP", 0xc0084812 },
+{ "ION_IOC_MAP", 0xc0084902 },
+{ "ION_IOC_SHARE", 0xc0084904 },
+{ "ION_IOC_IMPORT", 0xc0084905 },
+{ "ION_IOC_CUSTOM", 0xc0084906 },
+{ "ION_IOC_SYNC", 0xc0084907 },
+{ "AMDKFD_IOC_DESTROY_QUEUE", 0xc0084b03 },
+{ "ND_IOCTL_DIMM_FLAGS", 0xc0084e03 },
+{ "ND_IOCTL_SET_CONFIG_DATA", 0xc0084e06 },
+{ "ND_IOCTL_VENDOR", 0xc0084e09 },
+{ "SNDRV_CTL_IOCTL_TLV_READ", 0xc008551a },
+{ "SNDRV_CTL_IOCTL_TLV_WRITE", 0xc008551b },
+{ "SNDRV_CTL_IOCTL_TLV_COMMAND", 0xc008551c },
+{ "VIDIOC_G_CTRL", 0xc008561b },
+{ "VIDIOC_S_CTRL", 0xc008561c },
+{ "DRM_IOCTL_GET_UNIQUE", 0xc0086401 },
+{ "DRM_IOCTL_GEM_FLINK", 0xc008640a },
+{ "DRM_IOCTL_INFO_BUFS", 0xc0086418 },
+{ "DRM_IOCTL_GET_SAREA_CTX", 0xc008641d },
+{ "DRM_IOCTL_ADD_CTX", 0xc0086420 },
+{ "DRM_IOCTL_RM_CTX", 0xc0086421 },
+{ "DRM_IOCTL_GET_CTX", 0xc0086423 },
+{ "DRM_IOCTL_RES_CTX", 0xc0086426 },
+{ "DRM_IOCTL_SG_ALLOC", 0xc0086438 },
+{ "DRM_IOCTL_QXL_ALLOC", 0xc0086440 },
+{ "DRM_IOCTL_AMDGPU_GEM_MMAP", 0xc0086441 },
+{ "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", 0xc0086442 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_READ", 0xc0086442 },
+{ "DRM_IOCTL_VIA_AGP_INIT", 0xc0086442 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_INCR", 0xc0086443 },
+{ "DRM_IOCTL_VIA_FB_INIT", 0xc0086443 },
+{ "DRM_IOCTL_I915_GETPARAM", 0xc0086446 },
+{ "DRM_IOCTL_VIRTGPU_WAIT", 0xc0086448 },
+{ "DRM_IOCTL_MGA_GETPARAM", 0xc0086449 },
+{ "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", 0xc008644c },
+{ "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", 0xc008644d },
+{ "DRM_IOCTL_RADEON_GETPARAM", 0xc0086451 },
+{ "DRM_IOCTL_R128_GETPARAM", 0xc0086452 },
+{ "DRM_IOCTL_SIS_AGP_INIT", 0xc0086453 },
+{ "DRM_IOCTL_I915_GEM_BUSY", 0xc0086457 },
+{ "DRM_IOCTL_EXYNOS_G2D_GET_VER", 0xc0086460 },
+{ "DRM_IOCTL_EXYNOS_G2D_EXEC", 0xc0086462 },
+{ "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", 0xc0086465 },
+{ "DRM_IOCTL_RADEON_GEM_BUSY", 0xc008646a },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", 0xc008646d },
+{ "DRM_IOCTL_I915_GEM_GET_CACHING", 0xc0086470 },
+{ "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", 0xc0086473 },
+{ "NCP_IOC_GETPRIVATEDATA", 0xc0086e0a },
+{ "PHN_GETREG", 0xc0087005 },
+{ "SCIF_BIND", 0xc0087301 },
+{ "SCIF_CONNECT", 0xc0087303 },
+{ "SCIF_ACCEPTREG", 0xc0087305 },
+{ "PPPIOCGNPMODE", 0xc008744c },
+{ "KVM_GET_SUPPORTED_CPUID", 0xc008ae05 },
+{ "KVM_GET_EMULATED_CPUID", 0xc008ae09 },
+{ "KVM_IRQ_LINE_STATUS", 0xc008ae67 },
+{ "KVM_GET_MSRS", 0xc008ae88 },
+{ "KVM_GET_CPUID2", 0xc008ae91 },
+{ "KVM_GET_REG_LIST", 0xc008aeb0 },
+{ "FSL_HV_IOCTL_PARTITION_RESTART", 0xc008af01 },
+{ "FSL_HV_IOCTL_PARTITION_STOP", 0xc008af04 },
+{ "FSL_HV_IOCTL_DOORBELL", 0xc008af06 },
+{ "VHOST_GET_VRING_BASE", 0xc008af12 },
+{ "MMC_IOC_MULTI_CMD", 0xc008b301 },
+{ "HIDIOCGREPORTINFO", 0xc00c4809 },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", 0xc00c4822 },
+{ "MEMWRITEOOB", 0xc00c4d03 },
+{ "MEMREADOOB", 0xc00c4d04 },
+{ "ND_IOCTL_SMART_THRESHOLD", 0xc00c4e02 },
+{ "ND_IOCTL_GET_CONFIG_SIZE", 0xc00c4e04 },
+{ "ND_IOCTL_GET_CONFIG_DATA", 0xc00c4e05 },
+{ "SNDCTL_SYNTH_REMOVESAMPLE", 0xc00c5116 },
+{ "USBDEVFS_IOCTL", 0xc00c5512 },
+{ "UI_BEGIN_FF_ERASE", 0xc00c55ca },
+{ "NS_GETPSTAT", 0xc00c6161 },
+{ "DRM_IOCTL_MAP_BUFS", 0xc00c6419 },
+{ "DRM_IOCTL_PRIME_HANDLE_TO_FD", 0xc00c642d },
+{ "DRM_IOCTL_PRIME_FD_TO_HANDLE", 0xc00c642e },
+{ "DRM_IOCTL_VIA_CMDBUF_SIZE", 0xc00c644b },
+{ "DRM_IOCTL_I915_VBLANK_SWAP", 0xc00c644f },
+{ "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", 0xc00c6463 },
+{ "DRM_IOCTL_I915_GEM_MADVISE", 0xc00c6466 },
+{ "DRM_IOCTL_RADEON_GEM_SET_TILING", 0xc00c6468 },
+{ "DRM_IOCTL_RADEON_GEM_GET_TILING", 0xc00c6469 },
+{ "DRM_IOCTL_MODE_GETPLANERESOURCES", 0xc00c64b5 },
+{ "I2OHRTGET", 0xc00c6901 },
+{ "I2OLCTGET", 0xc00c6902 },
+{ "NCP_IOC_GETOBJECTNAME", 0xc00c6e09 },
+{ "SCIF_FENCE_MARK", 0xc00c730f },
+{ "UVCIOC_CTRL_QUERY", 0xc00c7521 },
+{ "KVM_CREATE_DEVICE", 0xc00caee0 },
+{ "FSL_HV_IOCTL_PARTITION_GET_STATUS", 0xc00caf02 },
+{ "MBXFB_IOCX_REG", 0xc00cf405 },
+{ "STP_POLICY_ID_SET", 0xc0102500 },
+{ "CAPI_GET_VERSION", 0xc0104307 },
+{ "GIGASET_VERSION", 0xc0104703 },
+{ "IOCTL_MEI_CONNECT_CLIENT", 0xc0104801 },
+{ "HIDIOCGCOLLECTIONINFO", 0xc0104811 },
+{ "SNDRV_EMUX_IOCTL_LOAD_PATCH", 0xc0104881 },
+{ "SNDRV_EMUX_IOCTL_MISC_MODE", 0xc0104884 },
+{ "MTRRIOC_GET_ENTRY", 0xc0104d03 },
+{ "MEMGETREGIONINFO", 0xc0104d08 },
+{ "MTRRIOC_GET_PAGE_ENTRY", 0xc0104d08 },
+{ "SNDRV_SEQ_IOCTL_RUNNING_MODE", 0xc0105303 },
+{ "USBDEVFS_CONTROL", 0xc0105500 },
+{ "USBDEVFS_BULK", 0xc0105502 },
+{ "DRM_IOCTL_IRQ_BUSID", 0xc0106403 },
+{ "DRM_IOCTL_SET_VERSION", 0xc0106407 },
+{ "DRM_IOCTL_GEM_OPEN", 0xc010640b },
+{ "DRM_IOCTL_GET_CAP", 0xc010640c },
+{ "DRM_IOCTL_AGP_ALLOC", 0xc0106434 },
+{ "DRM_IOCTL_WAIT_VBLANK", 0xc010643a },
+{ "DRM_IOCTL_ETNAVIV_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_EXYNOS_GEM_CREATE", 0xc0106440 },
+{ "DRM_IOCTL_MSM_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_OMAP_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_TEGRA_GEM_CREATE", 0xc0106440 },
+{ "DRM_IOCTL_EXYNOS_GEM_MAP", 0xc0106441 },
+{ "DRM_IOCTL_QXL_MAP", 0xc0106441 },
+{ "DRM_IOCTL_TEGRA_GEM_MMAP", 0xc0106441 },
+{ "DRM_IOCTL_VC4_WAIT_SEQNO", 0xc0106441 },
+{ "DRM_IOCTL_VIRTGPU_MAP", 0xc0106441 },
+{ "DRM_IOCTL_AMDGPU_CTX", 0xc0106442 },
+{ "DRM_IOCTL_ETNAVIV_GEM_NEW", 0xc0106442 },
+{ "DRM_IOCTL_MSM_GEM_NEW", 0xc0106442 },
+{ "DRM_IOCTL_VC4_WAIT_BO", 0xc0106442 },
+{ "DRM_IOCTL_ETNAVIV_GEM_INFO", 0xc0106443 },
+{ "DRM_IOCTL_MSM_GEM_INFO", 0xc0106443 },
+{ "DRM_IOCTL_OMAP_GEM_NEW", 0xc0106443 },
+{ "DRM_IOCTL_VC4_CREATE_BO", 0xc0106443 },
+{ "DRM_IOCTL_VIRTGPU_GETPARAM", 0xc0106443 },
+{ "DRM_IOCTL_EXYNOS_GEM_GET", 0xc0106444 },
+{ "DRM_IOCTL_QXL_GETPARAM", 0xc0106444 },
+{ "DRM_IOCTL_SIS_FB_ALLOC", 0xc0106444 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_WAIT", 0xc0106444 },
+{ "DRM_IOCTL_VC4_MMAP_BO", 0xc0106444 },
+{ "DRM_IOCTL_I810_GETBUF", 0xc0106445 },
+{ "DRM_IOCTL_TEGRA_OPEN_CHANNEL", 0xc0106445 },
+{ "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", 0xc0106445 },
+{ "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", 0xc0106446 },
+{ "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", 0xc0106447 },
+{ "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", 0xc0106447 },
+{ "DRM_IOCTL_TEGRA_GET_SYNCPT", 0xc0106447 },
+{ "DRM_IOCTL_VIA_DMA_INIT", 0xc0106447 },
+{ "DRM_IOCTL_I915_ALLOC", 0xc0106448 },
+{ "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", 0xc0106449 },
+{ "DRM_IOCTL_TEGRA_GEM_SET_TILING", 0xc010644a },
+{ "DRM_IOCTL_TEGRA_GEM_GET_TILING", 0xc010644b },
+{ "DRM_IOCTL_RADEON_INDIRECT", 0xc010644d },
+{ "DRM_IOCTL_VIA_WAIT_IRQ", 0xc010644d },
+{ "DRM_IOCTL_R128_INDIRECT", 0xc010644f },
+{ "DRM_IOCTL_AMDGPU_GEM_OP", 0xc0106450 },
+{ "DRM_IOCTL_RADEON_ALLOC", 0xc0106453 },
+{ "DRM_IOCTL_SIS_AGP_ALLOC", 0xc0106454 },
+{ "DRM_IOCTL_I915_GEM_CREATE", 0xc010645b },
+{ "DRM_IOCTL_I915_GEM_SET_TILING", 0xc0106461 },
+{ "DRM_IOCTL_I915_GEM_GET_TILING", 0xc0106462 },
+{ "DRM_IOCTL_I915_GEM_MMAP_GTT", 0xc0106464 },
+{ "DRM_IOCTL_RADEON_INFO", 0xc0106467 },
+{ "DRM_IOCTL_I915_GEM_WAIT", 0xc010646c },
+{ "DRM_IOCTL_RADEON_GEM_OP", 0xc010646c },
+{ "DRM_IOCTL_I915_REG_READ", 0xc0106471 },
+{ "DRM_IOCTL_MODE_SETPROPERTY", 0xc01064ab },
+{ "DRM_IOCTL_MODE_GETPROPBLOB", 0xc01064ac },
+{ "DRM_IOCTL_MODE_MAP_DUMB", 0xc01064b3 },
+{ "DRM_IOCTL_MODE_CREATEPROPBLOB", 0xc01064bd },
+{ "MGSL_IOCWAITGPIO", 0xc0106d12 },
+{ "DMX_GET_STC", 0xc0106f32 },
+{ "SCIF_ACCEPTREQ", 0xc0107304 },
+{ "SCIF_UNREG", 0xc0107309 },
+{ "BTRFS_IOC_SPACE_INFO", 0xc0109414 },
+{ "BTRFS_IOC_QUOTA_CTL", 0xc0109428 },
+{ "FSL_HV_IOCTL_PARTITION_START", 0xc010af03 },
+{ "FW_CDEV_IOC_GET_CYCLE_TIMER2", 0xc0142314 },
+{ "FW_CDEV_IOC_SEND_PHY_PACKET", 0xc0142315 },
+{ "SNDCTL_COPR_RDATA", 0xc0144302 },
+{ "SNDCTL_COPR_RCODE", 0xc0144303 },
+{ "SNDCTL_COPR_RUN", 0xc0144306 },
+{ "SNDCTL_COPR_HALT", 0xc0144307 },
+{ "ION_IOC_ALLOC", 0xc0144900 },
+{ "SNDRV_TIMER_IOCTL_NEXT_DEVICE", 0xc0145401 },
+{ "VIDIOC_REQBUFS", 0xc0145608 },
+{ "VIDIOC_G_CROP", 0xc014563b },
+{ "DRM_IOCTL_VIA_ALLOCMEM", 0xc0146440 },
+{ "DRM_IOCTL_VIA_MAP_INIT", 0xc0146444 },
+{ "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", 0xc014646a },
+{ "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", 0xc014646b },
+{ "DRM_IOCTL_MODE_GETENCODER", 0xc01464a6 },
+{ "DRM_IOCTL_MODE_OBJ_SETPROPERTY", 0xc01464ba },
+{ "SCIF_SEND", 0xc0147306 },
+{ "SCIF_RECV", 0xc0147307 },
+{ "SCIF_GET_NODEIDS", 0xc014730e },
+{ "HFI1_IOCTL_TID_UPDATE", 0xc0181be4 },
+{ "HFI1_IOCTL_TID_FREE", 0xc0181be5 },
+{ "HFI1_IOCTL_TID_INVAL_READ", 0xc0181bed },
+{ "FW_CDEV_IOC_ADD_DESCRIPTOR", 0xc0182306 },
+{ "FW_CDEV_IOC_QUEUE_ISO", 0xc0182309 },
+{ "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", 0xc018230d },
+{ "HIDIOCGUSAGE", 0xc018480b },
+{ "HIDIOCGUCODE", 0xc018480d },
+{ "AMDKFD_IOC_WAIT_EVENTS", 0xc0184b0c },
+{ "MEMWRITEOOB64", 0xc0184d15 },
+{ "MEMREADOOB64", 0xc0184d16 },
+{ "VIDIOC_G_EXT_CTRLS", 0xc0185647 },
+{ "VIDIOC_S_EXT_CTRLS", 0xc0185648 },
+{ "VIDIOC_TRY_EXT_CTRLS", 0xc0185649 },
+{ "VIDIOC_OMAP3ISP_STAT_REQ", 0xc01856c6 },
+{ "PACKET_CTRL_CMD", 0xc0185801 },
+{ "FITRIM", 0xc0185879 },
+{ "DRM_IOCTL_GET_MAP", 0xc0186404 },
+{ "DRM_IOCTL_GET_CLIENT", 0xc0186405 },
+{ "DRM_IOCTL_ADD_MAP", 0xc0186415 },
+{ "DRM_IOCTL_ADD_BUFS", 0xc0186416 },
+{ "DRM_IOCTL_AMDGPU_BO_LIST", 0xc0186443 },
+{ "DRM_IOCTL_AMDGPU_CS", 0xc0186444 },
+{ "DRM_IOCTL_VC4_CREATE_SHADER_BO", 0xc0186445 },
+{ "DRM_IOCTL_OMAP_GEM_INFO", 0xc0186446 },
+{ "DRM_IOCTL_QXL_ALLOC_SURF", 0xc0186446 },
+{ "DRM_IOCTL_ETNAVIV_GEM_USERPTR", 0xc0186448 },
+{ "DRM_IOCTL_VIRTGPU_GET_CAPS", 0xc0186449 },
+{ "DRM_IOCTL_RADEON_TEXTURE", 0xc018644e },
+{ "DRM_IOCTL_AMDGPU_GEM_USERPTR", 0xc0186451 },
+{ "DRM_IOCTL_I915_GEM_PIN", 0xc0186455 },
+{ "DRM_IOCTL_RADEON_GEM_INFO", 0xc018645c },
+{ "DRM_IOCTL_RADEON_GEM_VA", 0xc018646b },
+{ "DRM_IOCTL_RADEON_GEM_USERPTR", 0xc018646d },
+{ "DRM_IOCTL_I915_GET_RESET_STATS", 0xc0186472 },
+{ "DRM_IOCTL_I915_GEM_USERPTR", 0xc0186473 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", 0xc0186474 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", 0xc0186475 },
+{ "DRM_IOCTL_MODE_PAGE_FLIP", 0xc01864b0 },
+{ "DRM_IOCTL_MODE_DIRTYFB", 0xc01864b1 },
+{ "I2OPARMSET", 0xc0186903 },
+{ "I2OPARMGET", 0xc0186904 },
+{ "IPMICTL_RECEIVE_MSG_TRUNC", 0xc018690b },
+{ "IPMICTL_RECEIVE_MSG", 0xc018690c },
+{ "RIO_ALLOC_DMA", 0xc0186d13 },
+{ "RIO_TRANSFER", 0xc0186d15 },
+{ "NILFS_IOCTL_GET_VINFO", 0xc0186e86 },
+{ "NILFS_IOCTL_GET_BDESCS", 0xc0186e87 },
+{ "TOSH_SMM", 0xc0187490 },
+{ "TOSHIBA_ACPI_SCI", 0xc0187491 },
+{ "AUTOFS_DEV_IOCTL_VERSION", 0xc0189371 },
+{ "AUTOFS_DEV_IOCTL_PROTOVER", 0xc0189372 },
+{ "AUTOFS_DEV_IOCTL_PROTOSUBVER", 0xc0189373 },
+{ "AUTOFS_DEV_IOCTL_OPENMOUNT", 0xc0189374 },
+{ "AUTOFS_DEV_IOCTL_CLOSEMOUNT", 0xc0189375 },
+{ "AUTOFS_DEV_IOCTL_READY", 0xc0189376 },
+{ "AUTOFS_DEV_IOCTL_FAIL", 0xc0189377 },
+{ "AUTOFS_DEV_IOCTL_SETPIPEFD", 0xc0189378 },
+{ "AUTOFS_DEV_IOCTL_CATATONIC", 0xc0189379 },
+{ "AUTOFS_DEV_IOCTL_TIMEOUT", 0xc018937a },
+{ "AUTOFS_DEV_IOCTL_REQUESTER", 0xc018937b },
+{ "AUTOFS_DEV_IOCTL_EXPIRE", 0xc018937c },
+{ "AUTOFS_DEV_IOCTL_ASKUMOUNT", 0xc018937d },
+{ "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", 0xc018937e },
+{ "BTRFS_IOC_FILE_EXTENT_SAME", 0xc0189436 },
+{ "FIDEDUPERANGE", 0xc0189436 },
+{ "UFFDIO_API", 0xc018aa3f },
+{ "KVM_TRANSLATE", 0xc018ae85 },
+{ "IB_USER_MAD_REGISTER_AGENT", 0xc01c1b01 },
+{ "HFI1_IOCTL_ASSIGN_CTXT", 0xc01c1be1 },
+{ "FW_CDEV_IOC_CREATE_ISO_CONTEXT", 0xc01c2308 },
+{ "SI4713_IOC_MEASURE_RNL", 0xc01c56c0 },
+{ "DRM_IOCTL_MGA_DMA_BOOTSTRAP", 0xc01c644c },
+{ "DRM_IOCTL_RADEON_GEM_CREATE", 0xc01c645d },
+{ "DRM_IOCTL_MODE_CURSOR", 0xc01c64a3 },
+{ "DRM_IOCTL_MODE_GETFB", 0xc01c64ad },
+{ "DRM_IOCTL_MODE_ADDFB", 0xc01c64ae },
+{ "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", 0xc01c64b9 },
+{ "I2OSWDL", 0xc01c6905 },
+{ "I2OSWUL", 0xc01c6906 },
+{ "I2OSWDEL", 0xc01c6907 },
+{ "I2OHTML", 0xc01c6909 },
+{ "MEDIA_IOC_ENUM_LINKS", 0xc01c7c02 },
+{ "FW_CDEV_IOC_ALLOCATE", 0xc0202302 },
+{ "AMDKFD_IOC_CREATE_EVENT", 0xc0204b08 },
+{ "ND_IOCTL_ARS_CAP", 0xc0204e01 },
+{ "ND_IOCTL_ARS_START", 0xc0204e02 },
+{ "ND_IOCTL_CLEAR_ERROR", 0xc0204e04 },
+{ "VIDIOC_OMAP3ISP_CCDC_CFG", 0xc02056c1 },
+{ "VIDIOC_OMAP3ISP_AEWB_CFG", 0xc02056c3 },
+{ "SNDRV_RAWMIDI_IOCTL_PARAMS", 0xc0205710 },
+{ "X86_IOC_RDMSR_REGS", 0xc02063a0 },
+{ "X86_IOC_WRMSR_REGS", 0xc02063a1 },
+{ "DRM_IOCTL_AMDGPU_GEM_CREATE", 0xc0206440 },
+{ "DRM_IOCTL_MSM_GEM_SUBMIT", 0xc0206446 },
+{ "DRM_IOCTL_AMDGPU_WAIT_CS", 0xc0206449 },
+{ "DRM_IOCTL_RADEON_GEM_MMAP", 0xc020645e },
+{ "DRM_IOCTL_RADEON_GEM_PREAD", 0xc0206461 },
+{ "DRM_IOCTL_RADEON_GEM_PWRITE", 0xc0206462 },
+{ "DRM_IOCTL_RADEON_CS", 0xc0206466 },
+{ "DRM_IOCTL_MODE_GETGAMMA", 0xc02064a4 },
+{ "DRM_IOCTL_MODE_SETGAMMA", 0xc02064a5 },
+{ "DRM_IOCTL_MODE_CREATE_DUMB", 0xc02064b2 },
+{ "DRM_IOCTL_MODE_GETPLANE", 0xc02064b6 },
+{ "FS_IOC_FIEMAP", 0xc020660b },
+{ "GENWQE_PIN_MEM", 0xc020a528 },
+{ "GENWQE_UNPIN_MEM", 0xc020a529 },
+{ "UFFDIO_REGISTER", 0xc020aa00 },
+{ "UFFDIO_ZEROPAGE", 0xc020aa04 },
+{ "SNDCTL_MIDI_MPUCMD", 0xc0216d02 },
+{ "FW_CDEV_IOC_GET_INFO", 0xc0242300 },
+{ "SNDRV_COMPRESS_GET_METADATA", 0xc0244315 },
+{ "VIDIOC_G_EDID", 0xc0245628 },
+{ "VIDIOC_SUBDEV_G_EDID", 0xc0245628 },
+{ "VIDIOC_SUBDEV_S_EDID", 0xc0245629 },
+{ "VIDIOC_S_EDID", 0xc0245629 },
+{ "SNDRV_RAWMIDI_IOCTL_STATUS", 0xc0245720 },
+{ "DRM_IOCTL_VERSION", 0xc0246400 },
+{ "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", 0xc0246446 },
+{ "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", 0xc0246447 },
+{ "DRM_IOCTL_MODE_CURSOR2", 0xc02464bb },
+{ "NCP_IOC_GET_FS_INFO_V2", 0xc0246e04 },
+{ "SCIF_READFROM", 0xc024730a },
+{ "SCIF_WRITETO", 0xc024730b },
+{ "SCIF_VREADFROM", 0xc024730c },
+{ "SCIF_VWRITETO", 0xc024730d },
+{ "SCIF_FENCE_SIGNAL", 0xc0247311 },
+{ "IB_USER_MAD_REGISTER_AGENT2", 0xc0281b04 },
+{ "AMDKFD_IOC_GET_CLOCK_COUNTERS", 0xc0284b05 },
+{ "VIDIOC_ENCODER_CMD", 0xc028564d },
+{ "VIDIOC_TRY_ENCODER_CMD", 0xc028564e },
+{ "SW_SYNC_IOC_CREATE_FENCE", 0xc0285700 },
+{ "DRM_IOCTL_DMA", 0xc0286429 },
+{ "DRM_IOCTL_I915_GEM_MMAP", 0xc028645e },
+{ "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", 0xc0286461 },
+{ "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", 0xc0286472 },
+{ "DRM_IOCTL_NOUVEAU_GEM_INFO", 0xc0286484 },
+{ "RIO_MAP_OUTBOUND", 0xc0286d0f },
+{ "RIO_MAP_INBOUND", 0xc0286d11 },
+{ "NCP_IOC_GET_FS_INFO", 0xc0286e04 },
+{ "PHN_GETREGS", 0xc0287007 },
+{ "SCIF_REG", 0xc0287308 },
+{ "UFFDIO_COPY", 0xc028aa03 },
+{ "KVM_TPR_ACCESS_REPORTING", 0xc028ae92 },
+{ "FSL_HV_IOCTL_MEMCPY", 0xc028af05 },
+{ "FSL_HV_IOCTL_GETPROP", 0xc028af07 },
+{ "FSL_HV_IOCTL_SETPROP", 0xc028af08 },
+{ "NCP_IOC_GETCHARSETS", 0xc02a6e0b },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", 0xc02c5341 },
+{ "VIDIOC_QUERYMENU", 0xc02c5625 },
+{ "VIDIOC_G_FREQUENCY", 0xc02c5638 },
+{ "VIDIOC_CROPCAP", 0xc02c563a },
+{ "VIDIOC_ENUM_FRAMESIZES", 0xc02c564a },
+{ "DRM_IOCTL_I915_OVERLAY_ATTRS", 0xc02c6468 },
+{ "SYNC_IOC_MERGE", 0xc0303e03 },
+{ "MEMWRITE", 0xc0304d18 },
+{ "ND_IOCTL_ARS_STATUS", 0xc0304e03 },
+{ "SNDRV_SEQ_IOCTL_SYSTEM_INFO", 0xc0305302 },
+{ "VIDIOC_SUBDEV_ENUM_MBUS_CODE", 0xc0305602 },
+{ "VIDIOC_SUBDEV_G_FRAME_INTERVAL", 0xc0305615 },
+{ "VIDIOC_SUBDEV_S_FRAME_INTERVAL", 0xc0305616 },
+{ "VIDIOC_OMAP3ISP_HIST_CFG", 0xc03056c4 },
+{ "BINDER_WRITE_READ", 0xc0306201 },
+{ "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", 0xc0306446 },
+{ "DRM_IOCTL_NOUVEAU_GEM_NEW", 0xc0306480 },
+{ "DRM_IOCTL_MODE_SETPLANE", 0xc03064b7 },
+{ "MBXFB_IOCX_OVERLAY", 0xc030f400 },
+{ "VIDIOC_ENUMAUDIO", 0xc0345641 },
+{ "VIDIOC_ENUMAUDOUT", 0xc0345642 },
+{ "VIDIOC_ENUM_FRAMEINTERVALS", 0xc034564b },
+{ "MEDIA_IOC_SETUP_LINK", 0xc0347c03 },
+{ "SYNC_IOC_FILE_INFO", 0xc0383e04 },
+{ "HIDIOCGFIELDINFO", 0xc038480a },
+{ "VIDIOC_SUBDEV_G_CROP", 0xc038563b },
+{ "VIDIOC_SUBDEV_S_CROP", 0xc038563c },
+{ "VIDIOC_DBG_G_REGISTER", 0xc0385650 },
+{ "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", 0xc0386444 },
+{ "DRM_IOCTL_MODE_ATOMIC", 0xc03864bc },
+{ "BTRFS_IOC_INO_PATHS", 0xc0389423 },
+{ "BTRFS_IOC_LOGICAL_INO", 0xc0389424 },
+{ "GENWQE_SLU_UPDATE", 0xc038a550 },
+{ "GENWQE_SLU_READ", 0xc038a551 },
+{ "VIDIOC_OMAP3ISP_PRV_CFG", 0xc03c56c2 },
+{ "BLKTRACESETUP", 0xc0401273 },
+{ "PTP_SYS_OFFSET_PRECISE", 0xc0403d08 },
+{ "CAPI_GET_PROFILE", 0xc0404309 },
+{ "ND_IOCTL_CALL", 0xc0404e0a },
+{ "SNDRV_TIMER_IOCTL_GSTATUS", 0xc0405405 },
+{ "SNDRV_CTL_IOCTL_ELEM_REMOVE", 0xc0405519 },
+{ "VIDIOC_ENUM_FMT", 0xc0405602 },
+{ "VIDIOC_EXPBUF", 0xc0405610 },
+{ "VIDIOC_ENUMSTD", 0xc0405619 },
+{ "VIDIOC_SUBDEV_G_SELECTION", 0xc040563d },
+{ "VIDIOC_SUBDEV_S_SELECTION", 0xc040563e },
+{ "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", 0xc040564a },
+{ "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", 0xc040564b },
+{ "VIDIOC_G_SELECTION", 0xc040565e },
+{ "VIDIOC_S_SELECTION", 0xc040565f },
+{ "VIDIOC_ENUM_FREQ_BANDS", 0xc0405665 },
+{ "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", 0xc0406481 },
+{ "DRM_IOCTL_MODE_GETRESOURCES", 0xc04064a0 },
+{ "DRM_IOCTL_MODE_GETPROPERTY", 0xc04064aa },
+{ "VIDIOC_QUERYBUF", 0xc0445609 },
+{ "VIDIOC_QBUF", 0xc044560f },
+{ "VIDIOC_DQBUF", 0xc0445611 },
+{ "VIDIOC_QUERYCTRL", 0xc0445624 },
+{ "VIDIOC_G_MODULATOR", 0xc0445636 },
+{ "VIDIOC_PREPARE_BUF", 0xc044565d },
+{ "FBIO_CURSOR", 0xc0484608 },
+{ "SNDRV_EMU10K1_IOCTL_PCM_PEEK", 0xc0484831 },
+{ "NVME_IOCTL_ADMIN_CMD", 0xc0484e41 },
+{ "NVME_IOCTL_IO_CMD", 0xc0484e43 },
+{ "SNDRV_CTL_IOCTL_ELEM_LIST", 0xc0485510 },
+{ "VIDIOC_ENUMOUTPUT", 0xc0485630 },
+{ "VIDIOC_DECODER_CMD", 0xc0485660 },
+{ "VIDIOC_TRY_DECODER_CMD", 0xc0485661 },
+{ "DRM_IOCTL_MODE_ATTACHMODE", 0xc04864a8 },
+{ "DRM_IOCTL_MODE_DETACHMODE", 0xc04864a9 },
+{ "VIDEO_COMMAND", 0xc0486f3b },
+{ "VIDEO_TRY_COMMAND", 0xc0486f3c },
+{ "MEDIA_IOC_G_TOPOLOGY", 0xc0487c04 },
+{ "KVM_GET_PIT", 0xc048ae65 },
+{ "MMC_IOC_CMD", 0xc048b300 },
+{ "GPIO_GET_LINEINFO_IOCTL", 0xc048b402 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", 0xc04c5349 },
+{ "VIDIOC_ENUMINPUT", 0xc04c561a },
+{ "VIDIOC_OMAP3ISP_AF_CFG", 0xc04c56c5 },
+{ "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", 0xc0505350 },
+{ "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", 0xc0506470 },
+{ "DRM_IOCTL_MODE_GETCONNECTOR", 0xc05064a7 },
+{ "CCISS_PASSTHRU", 0xc054420b },
+{ "VIDIOC_G_TUNER", 0xc054561d },
+{ "SISFB_COMMAND", 0xc054f305 },
+{ "CCISS_BIG_PASSTHRU", 0xc0584212 },
+{ "AMDKFD_IOC_CREATE_QUEUE", 0xc0584b02 },
+{ "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", 0xc058534b },
+{ "SNDRV_SEQ_IOCTL_QUERY_SUBS", 0xc058534f },
+{ "VIDIOC_SUBDEV_G_FMT", 0xc0585604 },
+{ "VIDIOC_SUBDEV_S_FMT", 0xc0585605 },
+{ "DRM_IOCTL_TEGRA_SUBMIT", 0xc0586448 },
+{ "UVCIOC_CTRL_MAP", 0xc0587520 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", 0xc05c5340 },
+{ "PTP_PIN_GETFUNC", 0xc0603d06 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", 0xc0605345 },
+{ "UI_BEGIN_FF_UPLOAD", 0xc06055c8 },
+{ "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", 0xc0606471 },
+{ "DK_CXLFLASH_DETACH", 0xc060ca83 },
+{ "DRM_IOCTL_MODE_ADDFB2", 0xc06464b8 },
+{ "SNDRV_PCM_IOCTL_SW_PARAMS", 0xc0684113 },
+{ "DRM_IOCTL_MODE_GETCRTC", 0xc06864a1 },
+{ "DRM_IOCTL_MODE_SETCRTC", 0xc06864a2 },
+{ "DK_CXLFLASH_RELEASE", 0xc068ca82 },
+{ "DK_CXLFLASH_MANAGE_LUN", 0xc068ca86 },
+{ "SNDRV_PCM_IOCTL_STATUS_EXT", 0xc06c4124 },
+{ "BTRFS_IOC_TREE_SEARCH_V2", 0xc0709411 },
+{ "DK_CXLFLASH_USER_DIRECT", 0xc070ca81 },
+{ "DK_CXLFLASH_VLUN_CLONE", 0xc070ca89 },
+{ "SNDCTL_MIDI_INFO", 0xc074510c },
+{ "VIDIOC_G_SLICED_VBI_CAP", 0xc0745645 },
+{ "DK_CXLFLASH_RECOVER_AFU", 0xc078ca85 },
+{ "DK_CXLFLASH_USER_VIRTUAL", 0xc078ca87 },
+{ "DK_CXLFLASH_VLUN_RESIZE", 0xc078ca88 },
+{ "SOUND_MIXER_ACCESS", 0xc0804d66 },
+{ "SNDRV_PCM_IOCTL_SYNC_PTR", 0xc0844123 },
+{ "ND_IOCTL_SMART", 0xc0844e01 },
+{ "VIDIOC_SUBDEV_S_DV_TIMINGS", 0xc0845657 },
+{ "VIDIOC_S_DV_TIMINGS", 0xc0845657 },
+{ "VIDIOC_G_DV_TIMINGS", 0xc0845658 },
+{ "VIDIOC_SUBDEV_G_DV_TIMINGS", 0xc0845658 },
+{ "PPPIOCGCALLINFO", 0xc0887480 },
+{ "SNDCTL_SYNTH_INFO", 0xc08c5102 },
+{ "SNDCTL_SYNTH_ID", 0xc08c5114 },
+{ "SNDRV_SEQ_IOCTL_CREATE_QUEUE", 0xc08c5332 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", 0xc08c5334 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", 0xc08c5335 },
+{ "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", 0xc08c5336 },
+{ "VIDIOC_DV_TIMINGS_CAP", 0xc0905664 },
+{ "VIDIOC_SUBDEV_DV_TIMINGS_CAP", 0xc0905664 },
+{ "DK_CXLFLASH_ATTACH", 0xc090ca80 },
+{ "DK_CXLFLASH_VERIFY", 0xc090ca84 },
+{ "VIDIOC_ENUM_DV_TIMINGS", 0xc0945662 },
+{ "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", 0xc0945662 },
+{ "DRM_IOCTL_VC4_SUBMIT_CL", 0xc0a06440 },
+{ "DRM_IOCTL_VC4_GET_HANG_STATE", 0xc0a06446 },
+{ "SOUND_MIXER_GETLEVELS", 0xc0a44d74 },
+{ "SOUND_MIXER_SETLEVELS", 0xc0a44d75 },
+{ "SNDRV_SEQ_IOCTL_CREATE_PORT", 0xc0a45320 },
+{ "SNDRV_SEQ_IOCTL_GET_PORT_INFO", 0xc0a45322 },
+{ "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", 0xc0a45352 },
+{ "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", 0xc0bc5310 },
+{ "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", 0xc0bc5351 },
+{ "BTRFS_IOC_SET_RECEIVED_SUBVOL", 0xc0c09425 },
+{ "SNDRV_COMPRESS_GET_CAPS", 0xc0c44310 },
+{ "VIDIOC_DBG_G_CHIP_INFO", 0xc0c85666 },
+{ "VIDIOC_G_FMT", 0xc0cc5604 },
+{ "VIDIOC_S_FMT", 0xc0cc5605 },
+{ "VIDIOC_G_PARM", 0xc0cc5615 },
+{ "VIDIOC_S_PARM", 0xc0cc5616 },
+{ "VIDIOC_TRY_FMT", 0xc0cc5640 },
+{ "SNDRV_TIMER_IOCTL_GINFO", 0xc0e05403 },
+{ "VIDIOC_QUERY_EXT_CTRL", 0xc0e85667 },
+{ "GENWQE_EXECUTE_DDCB", 0xc0e8a532 },
+{ "GENWQE_EXECUTE_RAW_DDCB", 0xc0e8a533 },
+{ "VIDIOC_CREATE_BUFS", 0xc0f8565c },
+{ "MEDIA_IOC_DEVICE_INFO", 0xc1007c00 },
+{ "MEDIA_IOC_ENUM_ENTITIES", 0xc1007c01 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_INFO", 0xc10c5541 },
+{ "SNDRV_CTL_IOCTL_ELEM_INFO", 0xc1105511 },
+{ "SNDRV_CTL_IOCTL_ELEM_ADD", 0xc1105517 },
+{ "SNDRV_CTL_IOCTL_ELEM_REPLACE", 0xc1105518 },
+{ "DRM_IOCTL_AMDGPU_GEM_METADATA", 0xc11c6446 },
+{ "SNDRV_CTL_IOCTL_PCM_INFO", 0xc1205531 },
+{ "DM_VERSION", 0xc138fd00 },
+{ "DM_REMOVE_ALL", 0xc138fd01 },
+{ "DM_LIST_DEVICES", 0xc138fd02 },
+{ "DM_DEV_CREATE", 0xc138fd03 },
+{ "DM_DEV_REMOVE", 0xc138fd04 },
+{ "DM_DEV_RENAME", 0xc138fd05 },
+{ "DM_DEV_SUSPEND", 0xc138fd06 },
+{ "DM_DEV_STATUS", 0xc138fd07 },
+{ "DM_DEV_WAIT", 0xc138fd08 },
+{ "DM_TABLE_LOAD", 0xc138fd09 },
+{ "DM_TABLE_CLEAR", 0xc138fd0a },
+{ "DM_TABLE_DEPS", 0xc138fd0b },
+{ "DM_TABLE_STATUS", 0xc138fd0c },
+{ "DM_LIST_VERSIONS", 0xc138fd0d },
+{ "DM_TARGET_MSG", 0xc138fd0e },
+{ "DM_DEV_SET_GEOMETRY", 0xc138fd0f },
+{ "SNDRV_EMU10K1_IOCTL_CODE_PEEK", 0xc18c4812 },
+{ "KVM_GET_IRQCHIP", 0xc208ae62 },
+{ "SNDRV_PCM_IOCTL_HW_REFINE", 0xc25c4110 },
+{ "SNDRV_PCM_IOCTL_HW_PARAMS", 0xc25c4111 },
+{ "SNDRV_CTL_IOCTL_ELEM_READ", 0xc2c45512 },
+{ "SNDRV_CTL_IOCTL_ELEM_WRITE", 0xc2c45513 },
+{ "VIDIOC_VSP1_LUT_CONFIG", 0xc40056c1 },
+{ "BTRFS_IOC_SCRUB", 0xc400941b },
+{ "BTRFS_IOC_SCRUB_PROGRESS", 0xc400941d },
+{ "BTRFS_IOC_BALANCE_V2", 0xc4009420 },
+{ "BTRFS_IOC_GET_DEV_STATS", 0xc4089434 },
+{ "BTRFS_IOC_DEV_REPLACE", 0xca249435 },
+{ "SNDCTL_COPR_SENDMSG", 0xcfa44308 },
+{ "SNDCTL_SYNTH_CONTROL", 0xcfa45115 },
+{ "SNDCTL_COPR_LOAD", 0xcfb04301 },
+{ "NVM_INFO", 0xd0004c20 },
+{ "BTRFS_IOC_TREE_SEARCH", 0xd0009411 },
+{ "BTRFS_IOC_INO_LOOKUP", 0xd0009412 },
+{ "BTRFS_IOC_DEV_INFO", 0xd000941e },
+{ "HIDIOCGUSAGES", 0xd01c4813 },
+{ "SNDRV_COMPRESS_GET_CODEC_CAPS", 0xeb884311 },
diff --git a/strace/ioctlent2.h b/strace/ioctlent2.h
new file mode 100644
index 0000000..5fc9de9
--- /dev/null
+++ b/strace/ioctlent2.h
@@ -0,0 +1,2831 @@
+/* Generated by ioctlsort. */
+{ "FIBMAP", 0x00000001 },
+{ "FIGETBSZ", 0x00000002 },
+{ "FDCLRPRM", 0x00000241 },
+{ "FDMSGON", 0x00000245 },
+{ "FDMSGOFF", 0x00000246 },
+{ "FDFMTBEG", 0x00000247 },
+{ "FDFMTEND", 0x00000249 },
+{ "FDSETEMSGTRESH", 0x0000024a },
+{ "FDFLUSH", 0x0000024b },
+{ "FDRESET", 0x00000254 },
+{ "FDWERRORCLR", 0x00000256 },
+{ "FDRAWCMD", 0x00000258 },
+{ "FDTWADDLE", 0x00000259 },
+{ "FDEJECT", 0x0000025a },
+{ "HDIO_GETGEO", 0x00000301 },
+{ "HDIO_GET_UNMASKINTR", 0x00000302 },
+{ "HDIO_GET_MULTCOUNT", 0x00000304 },
+{ "HDIO_GET_QDMA", 0x00000305 },
+{ "HDIO_SET_XFER", 0x00000306 },
+{ "HDIO_OBSOLETE_IDENTITY", 0x00000307 },
+{ "HDIO_GET_KEEPSETTINGS", 0x00000308 },
+{ "HDIO_GET_32BIT", 0x00000309 },
+{ "HDIO_GET_NOWERR", 0x0000030a },
+{ "HDIO_GET_DMA", 0x0000030b },
+{ "HDIO_GET_NICE", 0x0000030c },
+{ "HDIO_GET_IDENTITY", 0x0000030d },
+{ "HDIO_GET_WCACHE", 0x0000030e },
+{ "HDIO_GET_ACOUSTIC", 0x0000030f },
+{ "HDIO_GET_ADDRESS", 0x00000310 },
+{ "HDIO_GET_BUSSTATE", 0x0000031a },
+{ "HDIO_TRISTATE_HWIF", 0x0000031b },
+{ "HDIO_DRIVE_RESET", 0x0000031c },
+{ "HDIO_DRIVE_TASKFILE", 0x0000031d },
+{ "HDIO_DRIVE_TASK", 0x0000031e },
+{ "HDIO_DRIVE_CMD", 0x0000031f },
+{ "HDIO_SET_MULTCOUNT", 0x00000321 },
+{ "HDIO_SET_UNMASKINTR", 0x00000322 },
+{ "HDIO_SET_KEEPSETTINGS", 0x00000323 },
+{ "HDIO_SET_32BIT", 0x00000324 },
+{ "HDIO_SET_NOWERR", 0x00000325 },
+{ "HDIO_SET_DMA", 0x00000326 },
+{ "HDIO_SET_PIO_MODE", 0x00000327 },
+{ "HDIO_SCAN_HWIF", 0x00000328 },
+{ "HDIO_SET_NICE", 0x00000329 },
+{ "HDIO_UNREGISTER_HWIF", 0x0000032a },
+{ "HDIO_SET_WCACHE", 0x0000032b },
+{ "HDIO_SET_ACOUSTIC", 0x0000032c },
+{ "HDIO_SET_BUSSTATE", 0x0000032d },
+{ "HDIO_SET_QDMA", 0x0000032e },
+{ "HDIO_SET_ADDRESS", 0x0000032f },
+{ "IOCTL_VMCI_VERSION", 0x0000079f },
+{ "IOCTL_VMCI_INIT_CONTEXT", 0x000007a0 },
+{ "IOCTL_VMCI_QUEUEPAIR_SETVA", 0x000007a4 },
+{ "IOCTL_VMCI_NOTIFY_RESOURCE", 0x000007a5 },
+{ "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", 0x000007a6 },
+{ "IOCTL_VMCI_VERSION2", 0x000007a7 },
+{ "IOCTL_VMCI_QUEUEPAIR_ALLOC", 0x000007a8 },
+{ "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", 0x000007a9 },
+{ "IOCTL_VMCI_QUEUEPAIR_DETACH", 0x000007aa },
+{ "IOCTL_VMCI_DATAGRAM_SEND", 0x000007ab },
+{ "IOCTL_VMCI_DATAGRAM_RECEIVE", 0x000007ac },
+{ "IOCTL_VMCI_CTX_ADD_NOTIFICATION", 0x000007af },
+{ "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", 0x000007b0 },
+{ "IOCTL_VMCI_CTX_GET_CPT_STATE", 0x000007b1 },
+{ "IOCTL_VMCI_CTX_SET_CPT_STATE", 0x000007b2 },
+{ "IOCTL_VMCI_GET_CONTEXT_ID", 0x000007b3 },
+{ "IOCTL_VMCI_SOCKETS_VERSION", 0x000007b4 },
+{ "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", 0x000007b8 },
+{ "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", 0x000007b9 },
+{ "IOCTL_VM_SOCKETS_GET_LOCAL_CID", 0x000007b9 },
+{ "IOCTL_VMCI_SET_NOTIFY", 0x000007cb },
+{ "RAID_AUTORUN", 0x00000914 },
+{ "CLEAR_ARRAY", 0x00000920 },
+{ "HOT_REMOVE_DISK", 0x00000922 },
+{ "SET_DISK_INFO", 0x00000924 },
+{ "WRITE_RAID_INFO", 0x00000925 },
+{ "UNPROTECT_ARRAY", 0x00000926 },
+{ "PROTECT_ARRAY", 0x00000927 },
+{ "HOT_ADD_DISK", 0x00000928 },
+{ "SET_DISK_FAULTY", 0x00000929 },
+{ "HOT_GENERATE_ERROR", 0x0000092a },
+{ "STOP_ARRAY", 0x00000932 },
+{ "STOP_ARRAY_RO", 0x00000933 },
+{ "RESTART_ARRAY_RW", 0x00000934 },
+{ "CLUSTERED_DISK_NACK", 0x00000935 },
+{ "BLKROSET", 0x0000125d },
+{ "BLKROGET", 0x0000125e },
+{ "BLKRRPART", 0x0000125f },
+{ "BLKGETSIZE", 0x00001260 },
+{ "BLKFLSBUF", 0x00001261 },
+{ "BLKRASET", 0x00001262 },
+{ "BLKRAGET", 0x00001263 },
+{ "BLKFRASET", 0x00001264 },
+{ "BLKFRAGET", 0x00001265 },
+{ "BLKSECTSET", 0x00001266 },
+{ "BLKSECTGET", 0x00001267 },
+{ "BLKSSZGET", 0x00001268 },
+{ "BLKPG", 0x00001269 },
+{ "BLKTRACESTART", 0x00001274 },
+{ "BLKTRACESTOP", 0x00001275 },
+{ "BLKTRACETEARDOWN", 0x00001276 },
+{ "BLKDISCARD", 0x00001277 },
+{ "BLKIOMIN", 0x00001278 },
+{ "BLKIOOPT", 0x00001279 },
+{ "BLKALIGNOFF", 0x0000127a },
+{ "BLKPBSZGET", 0x0000127b },
+{ "BLKDISCARDZEROES", 0x0000127c },
+{ "BLKSECDISCARD", 0x0000127d },
+{ "BLKROTATIONAL", 0x0000127e },
+{ "BLKZEROOUT", 0x0000127f },
+{ "IB_USER_MAD_ENABLE_PKEY", 0x00001b03 },
+{ "HFI1_IOCTL_CREDIT_UPD", 0x00001be6 },
+{ "HFI1_IOCTL_CTXT_RESET", 0x00001bec },
+{ "SG_SET_TIMEOUT", 0x00002201 },
+{ "SG_GET_TIMEOUT", 0x00002202 },
+{ "SG_EMULATED_HOST", 0x00002203 },
+{ "SG_SET_TRANSFORM", 0x00002204 },
+{ "SG_GET_TRANSFORM", 0x00002205 },
+{ "SG_GET_COMMAND_Q", 0x00002270 },
+{ "SG_SET_COMMAND_Q", 0x00002271 },
+{ "SG_GET_RESERVED_SIZE", 0x00002272 },
+{ "SG_SET_RESERVED_SIZE", 0x00002275 },
+{ "SG_GET_SCSI_ID", 0x00002276 },
+{ "SG_SET_FORCE_LOW_DMA", 0x00002279 },
+{ "SG_GET_LOW_DMA", 0x0000227a },
+{ "SG_SET_FORCE_PACK_ID", 0x0000227b },
+{ "SG_GET_PACK_ID", 0x0000227c },
+{ "SG_GET_NUM_WAITING", 0x0000227d },
+{ "SG_SET_DEBUG", 0x0000227e },
+{ "SG_GET_SG_TABLESIZE", 0x0000227f },
+{ "SG_GET_VERSION_NUM", 0x00002282 },
+{ "SG_NEXT_CMD_LEN", 0x00002283 },
+{ "SG_SCSI_RESET", 0x00002284 },
+{ "SG_IO", 0x00002285 },
+{ "SG_GET_REQUEST_TABLE", 0x00002286 },
+{ "SG_SET_KEEP_ORPHAN", 0x00002287 },
+{ "SG_GET_KEEP_ORPHAN", 0x00002288 },
+{ "SG_GET_ACCESS_COUNT", 0x00002289 },
+{ "FW_CDEV_IOC_GET_SPEED", 0x00002311 },
+{ "PERF_EVENT_IOC_ENABLE", 0x00002400 },
+{ "PERF_EVENT_IOC_DISABLE", 0x00002401 },
+{ "PERF_EVENT_IOC_REFRESH", 0x00002402 },
+{ "PERF_EVENT_IOC_RESET", 0x00002403 },
+{ "PERF_EVENT_IOC_SET_OUTPUT", 0x00002405 },
+{ "SNAPSHOT_FREEZE", 0x00003301 },
+{ "SNAPSHOT_UNFREEZE", 0x00003302 },
+{ "SNAPSHOT_ATOMIC_RESTORE", 0x00003304 },
+{ "SNAPSHOT_FREE", 0x00003305 },
+{ "SNAPSHOT_FREE_SWAP_PAGES", 0x00003309 },
+{ "SNAPSHOT_S2RAM", 0x0000330b },
+{ "SNAPSHOT_PLATFORM_SUPPORT", 0x0000330f },
+{ "SNAPSHOT_POWER_OFF", 0x00003310 },
+{ "SNAPSHOT_PREF_IMAGE_SIZE", 0x00003312 },
+{ "VFIO_GET_API_VERSION", 0x00003b64 },
+{ "VFIO_CHECK_EXTENSION", 0x00003b65 },
+{ "VFIO_SET_IOMMU", 0x00003b66 },
+{ "VFIO_GROUP_GET_STATUS", 0x00003b67 },
+{ "VFIO_GROUP_SET_CONTAINER", 0x00003b68 },
+{ "VFIO_GROUP_UNSET_CONTAINER", 0x00003b69 },
+{ "VFIO_GROUP_GET_DEVICE_FD", 0x00003b6a },
+{ "VFIO_DEVICE_GET_INFO", 0x00003b6b },
+{ "VFIO_DEVICE_GET_REGION_INFO", 0x00003b6c },
+{ "VFIO_DEVICE_GET_IRQ_INFO", 0x00003b6d },
+{ "VFIO_DEVICE_SET_IRQS", 0x00003b6e },
+{ "VFIO_DEVICE_RESET", 0x00003b6f },
+{ "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", 0x00003b70 },
+{ "VFIO_IOMMU_GET_INFO", 0x00003b70 },
+{ "VFIO_IOMMU_SPAPR_TCE_GET_INFO", 0x00003b70 },
+{ "VFIO_DEVICE_PCI_HOT_RESET", 0x00003b71 },
+{ "VFIO_IOMMU_MAP_DMA", 0x00003b71 },
+{ "VFIO_IOMMU_UNMAP_DMA", 0x00003b72 },
+{ "VFIO_IOMMU_ENABLE", 0x00003b73 },
+{ "VFIO_IOMMU_DISABLE", 0x00003b74 },
+{ "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", 0x00003b75 },
+{ "VFIO_IOMMU_SPAPR_UNREGISTER_MEMORY", 0x00003b76 },
+{ "VFIO_IOMMU_SPAPR_TCE_CREATE", 0x00003b77 },
+{ "VFIO_IOMMU_SPAPR_TCE_REMOVE", 0x00003b78 },
+{ "VFIO_EEH_PE_OP", 0x00003b79 },
+{ "AGPIOC_ACQUIRE", 0x00004101 },
+{ "APM_IOC_STANDBY", 0x00004101 },
+{ "AGPIOC_RELEASE", 0x00004102 },
+{ "APM_IOC_SUSPEND", 0x00004102 },
+{ "AGPIOC_CHIPSET_FLUSH", 0x0000410a },
+{ "SNDRV_PCM_IOCTL_HW_FREE", 0x00004112 },
+{ "SNDRV_PCM_IOCTL_HWSYNC", 0x00004122 },
+{ "SNDRV_PCM_IOCTL_PREPARE", 0x00004140 },
+{ "SNDRV_PCM_IOCTL_RESET", 0x00004141 },
+{ "SNDRV_PCM_IOCTL_START", 0x00004142 },
+{ "SNDRV_PCM_IOCTL_DROP", 0x00004143 },
+{ "SNDRV_PCM_IOCTL_DRAIN", 0x00004144 },
+{ "SNDRV_PCM_IOCTL_RESUME", 0x00004147 },
+{ "SNDRV_PCM_IOCTL_XRUN", 0x00004148 },
+{ "SNDRV_PCM_IOCTL_UNLINK", 0x00004161 },
+{ "IOCTL_XENBUS_BACKEND_EVTCHN", 0x00004200 },
+{ "PMU_IOC_SLEEP", 0x00004200 },
+{ "IOCTL_XENBUS_BACKEND_SETUP", 0x00004201 },
+{ "CCISS_REVALIDVOLS", 0x0000420a },
+{ "CCISS_DEREGDISK", 0x0000420c },
+{ "CCISS_REGNEWD", 0x0000420e },
+{ "CCISS_RESCANDISK", 0x00004210 },
+{ "SNDCTL_COPR_RESET", 0x00004300 },
+{ "SNDRV_COMPRESS_PAUSE", 0x00004330 },
+{ "SNDRV_COMPRESS_RESUME", 0x00004331 },
+{ "SNDRV_COMPRESS_START", 0x00004332 },
+{ "SNDRV_COMPRESS_STOP", 0x00004333 },
+{ "SNDRV_COMPRESS_DRAIN", 0x00004334 },
+{ "SNDRV_COMPRESS_NEXT_TRACK", 0x00004335 },
+{ "SNDRV_COMPRESS_PARTIAL_DRAIN", 0x00004336 },
+{ "IOCTL_EVTCHN_RESET", 0x00004505 },
+{ "FBIOGET_VSCREENINFO", 0x00004600 },
+{ "FBIOPUT_VSCREENINFO", 0x00004601 },
+{ "FBIOGET_FSCREENINFO", 0x00004602 },
+{ "FBIOGETCMAP", 0x00004604 },
+{ "FBIOPUTCMAP", 0x00004605 },
+{ "FBIOPAN_DISPLAY", 0x00004606 },
+{ "FBIOGET_CON2FBMAP", 0x0000460f },
+{ "FBIOPUT_CON2FBMAP", 0x00004610 },
+{ "FBIOBLANK", 0x00004611 },
+{ "FBIO_ALLOC", 0x00004613 },
+{ "FBIO_FREE", 0x00004614 },
+{ "FBIOGET_GLYPH", 0x00004615 },
+{ "FBIOGET_HWCINFO", 0x00004616 },
+{ "FBIOPUT_MODEINFO", 0x00004617 },
+{ "FBIOGET_DISPINFO", 0x00004618 },
+{ "FBIO_WAITEVENT", 0x00004688 },
+{ "GSMIOC_DISABLE_NET", 0x00004703 },
+{ "HIDIOCAPPLICATION", 0x00004802 },
+{ "HIDIOCINITREPORT", 0x00004805 },
+{ "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", 0x00004812 },
+{ "SNDRV_SB_CSP_IOCTL_STOP", 0x00004814 },
+{ "SNDRV_SB_CSP_IOCTL_PAUSE", 0x00004815 },
+{ "SNDRV_SB_CSP_IOCTL_RESTART", 0x00004816 },
+{ "SNDRV_DM_FM_IOCTL_RESET", 0x00004821 },
+{ "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", 0x00004840 },
+{ "SNDRV_EMU10K1_IOCTL_STOP", 0x00004880 },
+{ "SNDRV_EMU10K1_IOCTL_CONTINUE", 0x00004881 },
+{ "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", 0x00004882 },
+{ "SNDRV_EMUX_IOCTL_RESET_SAMPLES", 0x00004882 },
+{ "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", 0x00004883 },
+{ "SNDRV_FIREWIRE_IOCTL_LOCK", 0x000048f9 },
+{ "SNDRV_FIREWIRE_IOCTL_UNLOCK", 0x000048fa },
+{ "IIOCNETAIF", 0x00004901 },
+{ "IIOCNETDIF", 0x00004902 },
+{ "IIOCNETSCF", 0x00004903 },
+{ "IIOCNETGCF", 0x00004904 },
+{ "IIOCNETANM", 0x00004905 },
+{ "IIOCNETDNM", 0x00004906 },
+{ "IIOCNETGNM", 0x00004907 },
+{ "IIOCGETSET", 0x00004908 },
+{ "IIOCSETSET", 0x00004909 },
+{ "IIOCSETVER", 0x0000490a },
+{ "IIOCNETHUP", 0x0000490b },
+{ "IIOCSETGST", 0x0000490c },
+{ "IIOCSETBRJ", 0x0000490d },
+{ "IIOCSIGPRF", 0x0000490e },
+{ "IIOCGETPRF", 0x0000490f },
+{ "IIOCSETPRF", 0x00004910 },
+{ "IIOCGETMAP", 0x00004911 },
+{ "IIOCSETMAP", 0x00004912 },
+{ "IIOCNETASL", 0x00004913 },
+{ "IIOCNETDIL", 0x00004914 },
+{ "IIOCGETCPS", 0x00004915 },
+{ "IIOCGETDVR", 0x00004916 },
+{ "IIOCNETLCR", 0x00004917 },
+{ "IIOCNETDWRSET", 0x00004918 },
+{ "IIOCNETALN", 0x00004920 },
+{ "IIOCNETDLN", 0x00004921 },
+{ "IIOCNETGPN", 0x00004922 },
+{ "IIOCDBGVAR", 0x0000497f },
+{ "IIOCDRVCTL", 0x00004980 },
+{ "ION_IOC_TEST_SET_FD", 0x000049f0 },
+{ "KIOCSOUND", 0x00004b2f },
+{ "KDMKTONE", 0x00004b30 },
+{ "KDGETLED", 0x00004b31 },
+{ "KDSETLED", 0x00004b32 },
+{ "KDGKBTYPE", 0x00004b33 },
+{ "KDADDIO", 0x00004b34 },
+{ "KDDELIO", 0x00004b35 },
+{ "KDENABIO", 0x00004b36 },
+{ "KDDISABIO", 0x00004b37 },
+{ "KDSETMODE", 0x00004b3a },
+{ "KDGETMODE", 0x00004b3b },
+{ "KDMAPDISP", 0x00004b3c },
+{ "KDUNMAPDISP", 0x00004b3d },
+{ "GIO_SCRNMAP", 0x00004b40 },
+{ "PIO_SCRNMAP", 0x00004b41 },
+{ "KDGKBMODE", 0x00004b44 },
+{ "KDSKBMODE", 0x00004b45 },
+{ "KDGKBENT", 0x00004b46 },
+{ "KDSKBENT", 0x00004b47 },
+{ "KDGKBSENT", 0x00004b48 },
+{ "KDSKBSENT", 0x00004b49 },
+{ "KDGKBDIACR", 0x00004b4a },
+{ "KDSKBDIACR", 0x00004b4b },
+{ "KDGETKEYCODE", 0x00004b4c },
+{ "KDSETKEYCODE", 0x00004b4d },
+{ "KDSIGACCEPT", 0x00004b4e },
+{ "KDKBDREP", 0x00004b52 },
+{ "GIO_FONT", 0x00004b60 },
+{ "PIO_FONT", 0x00004b61 },
+{ "KDGKBMETA", 0x00004b62 },
+{ "KDSKBMETA", 0x00004b63 },
+{ "KDGKBLED", 0x00004b64 },
+{ "KDSKBLED", 0x00004b65 },
+{ "GIO_UNIMAP", 0x00004b66 },
+{ "PIO_UNIMAP", 0x00004b67 },
+{ "PIO_UNIMAPCLR", 0x00004b68 },
+{ "GIO_UNISCRNMAP", 0x00004b69 },
+{ "PIO_UNISCRNMAP", 0x00004b6a },
+{ "GIO_FONTX", 0x00004b6b },
+{ "PIO_FONTX", 0x00004b6c },
+{ "PIO_FONTRESET", 0x00004b6d },
+{ "GIO_CMAP", 0x00004b70 },
+{ "PIO_CMAP", 0x00004b71 },
+{ "KDFONTOP", 0x00004b72 },
+{ "KDGKBDIACRUC", 0x00004bfa },
+{ "KDSKBDIACRUC", 0x00004bfb },
+{ "LOOP_SET_FD", 0x00004c00 },
+{ "LOOP_CLR_FD", 0x00004c01 },
+{ "LOOP_SET_STATUS", 0x00004c02 },
+{ "LOOP_GET_STATUS", 0x00004c03 },
+{ "LOOP_SET_STATUS64", 0x00004c04 },
+{ "LOOP_GET_STATUS64", 0x00004c05 },
+{ "LOOP_CHANGE_FD", 0x00004c06 },
+{ "LOOP_SET_CAPACITY", 0x00004c07 },
+{ "LOOP_SET_DIRECT_IO", 0x00004c08 },
+{ "LOOP_CTL_ADD", 0x00004c80 },
+{ "LOOP_CTL_REMOVE", 0x00004c81 },
+{ "LOOP_CTL_GET_FREE", 0x00004c82 },
+{ "MTDFILEMODE", 0x00004d13 },
+{ "NVME_IOCTL_ID", 0x00004e40 },
+{ "NVME_IOCTL_RESET", 0x00004e44 },
+{ "NVME_IOCTL_SUBSYS_RESET", 0x00004e45 },
+{ "NVME_IOCTL_RESCAN", 0x00004e46 },
+{ "UBI_IOCVOLRMBLK", 0x00004f08 },
+{ "OMAPFB_SYNC_GFX", 0x00004f25 },
+{ "OMAPFB_VSYNC", 0x00004f26 },
+{ "OMAPFB_WAITFORVSYNC", 0x00004f39 },
+{ "OMAPFB_WAITFORGO", 0x00004f3c },
+{ "SNDCTL_DSP_RESET", 0x00005000 },
+{ "SNDCTL_DSP_SYNC", 0x00005001 },
+{ "SNDCTL_DSP_POST", 0x00005008 },
+{ "SNDCTL_DSP_NONBLOCK", 0x0000500e },
+{ "SNDCTL_DSP_SETSYNCRO", 0x00005015 },
+{ "SNDCTL_DSP_SETDUPLEX", 0x00005016 },
+{ "SNDCTL_SEQ_RESET", 0x00005100 },
+{ "SNDCTL_SEQ_SYNC", 0x00005101 },
+{ "SNDCTL_SEQ_PANIC", 0x00005111 },
+{ "RFKILL_IOCTL_NOINPUT", 0x00005201 },
+{ "RNDZAPENTCNT", 0x00005204 },
+{ "RNDCLEARPOOL", 0x00005206 },
+{ "CDROMPAUSE", 0x00005301 },
+{ "CDROMRESUME", 0x00005302 },
+{ "CDROMPLAYMSF", 0x00005303 },
+{ "CDROMPLAYTRKIND", 0x00005304 },
+{ "CDROMREADTOCHDR", 0x00005305 },
+{ "CDROMREADTOCENTRY", 0x00005306 },
+{ "CDROMSTOP", 0x00005307 },
+{ "CDROMSTART", 0x00005308 },
+{ "CDROMEJECT", 0x00005309 },
+{ "CDROMVOLCTRL", 0x0000530a },
+{ "CDROMSUBCHNL", 0x0000530b },
+{ "CDROMREADMODE2", 0x0000530c },
+{ "CDROMREADMODE1", 0x0000530d },
+{ "CDROMREADAUDIO", 0x0000530e },
+{ "CDROMEJECT_SW", 0x0000530f },
+{ "CDROMMULTISESSION", 0x00005310 },
+{ "CDROM_GET_MCN", 0x00005311 },
+{ "CDROMRESET", 0x00005312 },
+{ "CDROMVOLREAD", 0x00005313 },
+{ "CDROMREADRAW", 0x00005314 },
+{ "CDROMREADCOOKED", 0x00005315 },
+{ "CDROMSEEK", 0x00005316 },
+{ "CDROMPLAYBLK", 0x00005317 },
+{ "CDROMREADALL", 0x00005318 },
+{ "CDROMCLOSETRAY", 0x00005319 },
+{ "CDROMGETSPINDOWN", 0x0000531d },
+{ "CDROMSETSPINDOWN", 0x0000531e },
+{ "CDROM_SET_OPTIONS", 0x00005320 },
+{ "CDROM_CLEAR_OPTIONS", 0x00005321 },
+{ "CDROM_SELECT_SPEED", 0x00005322 },
+{ "CDROM_SELECT_DISC", 0x00005323 },
+{ "CDROM_MEDIA_CHANGED", 0x00005325 },
+{ "CDROM_DRIVE_STATUS", 0x00005326 },
+{ "CDROM_DISC_STATUS", 0x00005327 },
+{ "CDROM_CHANGER_NSLOTS", 0x00005328 },
+{ "CDROM_LOCKDOOR", 0x00005329 },
+{ "CDROM_DEBUG", 0x00005330 },
+{ "CDROM_GET_CAPABILITY", 0x00005331 },
+{ "SCSI_IOCTL_DOORLOCK", 0x00005380 },
+{ "SCSI_IOCTL_DOORUNLOCK", 0x00005381 },
+{ "CDROMAUDIOBUFSIZ", 0x00005382 },
+{ "SCSI_IOCTL_GET_IDLUN", 0x00005382 },
+{ "SCSI_IOCTL_PROBE_HOST", 0x00005385 },
+{ "SCSI_IOCTL_GET_BUS_NUMBER", 0x00005386 },
+{ "SCSI_IOCTL_GET_PCI", 0x00005387 },
+{ "DVD_READ_STRUCT", 0x00005390 },
+{ "DVD_WRITE_STRUCT", 0x00005391 },
+{ "DVD_AUTH", 0x00005392 },
+{ "CDROM_SEND_PACKET", 0x00005393 },
+{ "CDROM_NEXT_WRITABLE", 0x00005394 },
+{ "CDROM_LAST_WRITTEN", 0x00005395 },
+{ "TCGETS", 0x00005401 },
+{ "SNDCTL_TMR_START", 0x00005402 },
+{ "TCSETS", 0x00005402 },
+{ "SNDCTL_TMR_STOP", 0x00005403 },
+{ "TCSETSW", 0x00005403 },
+{ "SNDCTL_TMR_CONTINUE", 0x00005404 },
+{ "TCSETSF", 0x00005404 },
+{ "TCGETA", 0x00005405 },
+{ "TCSETA", 0x00005406 },
+{ "TCSETAW", 0x00005407 },
+{ "TCSETAF", 0x00005408 },
+{ "TCSBRK", 0x00005409 },
+{ "TCXONC", 0x0000540a },
+{ "TCFLSH", 0x0000540b },
+{ "TIOCEXCL", 0x0000540c },
+{ "TIOCNXCL", 0x0000540d },
+{ "TIOCSCTTY", 0x0000540e },
+{ "TIOCGPGRP", 0x0000540f },
+{ "TIOCSPGRP", 0x00005410 },
+{ "TIOCOUTQ", 0x00005411 },
+{ "TIOCSTI", 0x00005412 },
+{ "TIOCGWINSZ", 0x00005413 },
+{ "TIOCSWINSZ", 0x00005414 },
+{ "TIOCMGET", 0x00005415 },
+{ "TIOCMBIS", 0x00005416 },
+{ "TIOCMBIC", 0x00005417 },
+{ "TIOCMSET", 0x00005418 },
+{ "TIOCGSOFTCAR", 0x00005419 },
+{ "TIOCSSOFTCAR", 0x0000541a },
+{ "FIONREAD", 0x0000541b },
+{ "TIOCLINUX", 0x0000541c },
+{ "TIOCCONS", 0x0000541d },
+{ "TIOCGSERIAL", 0x0000541e },
+{ "TIOCSSERIAL", 0x0000541f },
+{ "TIOCPKT", 0x00005420 },
+{ "FIONBIO", 0x00005421 },
+{ "TIOCNOTTY", 0x00005422 },
+{ "TIOCSETD", 0x00005423 },
+{ "TIOCGETD", 0x00005424 },
+{ "TCSBRKP", 0x00005425 },
+{ "TIOCSBRK", 0x00005427 },
+{ "TIOCCBRK", 0x00005428 },
+{ "TIOCGSID", 0x00005429 },
+{ "TIOCGRS485", 0x0000542e },
+{ "TIOCSRS485", 0x0000542f },
+{ "TCGETX", 0x00005432 },
+{ "TCSETX", 0x00005433 },
+{ "TCSETXF", 0x00005434 },
+{ "TCSETXW", 0x00005435 },
+{ "TIOCVHANGUP", 0x00005437 },
+{ "FIONCLEX", 0x00005450 },
+{ "FIOCLEX", 0x00005451 },
+{ "FIOASYNC", 0x00005452 },
+{ "TIOCSERCONFIG", 0x00005453 },
+{ "TIOCSERGWILD", 0x00005454 },
+{ "TIOCSERSWILD", 0x00005455 },
+{ "TIOCGLCKTRMIOS", 0x00005456 },
+{ "TIOCSLCKTRMIOS", 0x00005457 },
+{ "TIOCSERGSTRUCT", 0x00005458 },
+{ "TIOCSERGETLSR", 0x00005459 },
+{ "TIOCSERGETMULTI", 0x0000545a },
+{ "TIOCSERSETMULTI", 0x0000545b },
+{ "TIOCMIWAIT", 0x0000545c },
+{ "TIOCGICOUNT", 0x0000545d },
+{ "FIOQSIZE", 0x00005460 },
+{ "SNDRV_TIMER_IOCTL_START", 0x000054a0 },
+{ "SNDRV_TIMER_IOCTL_STOP", 0x000054a1 },
+{ "SNDRV_TIMER_IOCTL_CONTINUE", 0x000054a2 },
+{ "SNDRV_TIMER_IOCTL_PAUSE", 0x000054a3 },
+{ "UI_DEV_CREATE", 0x00005501 },
+{ "UI_DEV_DESTROY", 0x00005502 },
+{ "USBDEVFS_DISCARDURB", 0x0000550b },
+{ "USBDEVFS_RESET", 0x00005514 },
+{ "USBDEVFS_DISCONNECT", 0x00005516 },
+{ "USBDEVFS_CONNECT", 0x00005517 },
+{ "VT_OPENQRY", 0x00005600 },
+{ "VIDIOC_RESERVED", 0x00005601 },
+{ "VT_GETMODE", 0x00005601 },
+{ "VT_SETMODE", 0x00005602 },
+{ "VT_GETSTATE", 0x00005603 },
+{ "VT_SENDSIG", 0x00005604 },
+{ "VT_RELDISP", 0x00005605 },
+{ "VT_ACTIVATE", 0x00005606 },
+{ "VT_WAITACTIVE", 0x00005607 },
+{ "VT_DISALLOCATE", 0x00005608 },
+{ "VT_RESIZE", 0x00005609 },
+{ "VT_RESIZEX", 0x0000560a },
+{ "VT_LOCKSWITCH", 0x0000560b },
+{ "VT_UNLOCKSWITCH", 0x0000560c },
+{ "VT_GETHIFONTMASK", 0x0000560d },
+{ "VT_WAITEVENT", 0x0000560e },
+{ "VT_SETACTIVATE", 0x0000560f },
+{ "VIDIOC_LOG_STATUS", 0x00005646 },
+{ "ADV7842_CMD_RAM_TEST", 0x000056c0 },
+{ "USBTMC_IOCTL_INDICATOR_PULSE", 0x00005b01 },
+{ "USBTMC_IOCTL_CLEAR", 0x00005b02 },
+{ "USBTMC_IOCTL_ABORT_BULK_OUT", 0x00005b03 },
+{ "USBTMC_IOCTL_ABORT_BULK_IN", 0x00005b04 },
+{ "USBTMC_IOCTL_CLEAR_OUT_HALT", 0x00005b06 },
+{ "USBTMC_IOCTL_CLEAR_IN_HALT", 0x00005b07 },
+{ "USBTMC488_IOCTL_GOTO_LOCAL", 0x00005b14 },
+{ "USBTMC488_IOCTL_LOCAL_LOCKOUT", 0x00005b15 },
+{ "NS_ADJBUFLEV", 0x00006163 },
+{ "SIOCSIFATMTCP", 0x00006180 },
+{ "ATMTCP_CREATE", 0x0000618e },
+{ "ATMTCP_REMOVE", 0x0000618f },
+{ "ATMLEC_CTRL", 0x000061d0 },
+{ "ATMLEC_DATA", 0x000061d1 },
+{ "ATMLEC_MCAST", 0x000061d2 },
+{ "ATMMPC_CTRL", 0x000061d8 },
+{ "ATMMPC_DATA", 0x000061d9 },
+{ "SIOCMKCLIP", 0x000061e0 },
+{ "ATMARPD_CTRL", 0x000061e1 },
+{ "ATMARP_MKIP", 0x000061e2 },
+{ "ATMARP_SETENTRY", 0x000061e3 },
+{ "ATMARP_ENCAP", 0x000061e5 },
+{ "ATMSIGD_CTRL", 0x000061f0 },
+{ "BT819_FIFO_RESET_LOW", 0x00006200 },
+{ "BT819_FIFO_RESET_HIGH", 0x00006201 },
+{ "CM_IOCSRDR", 0x00006303 },
+{ "CM_IOCARDOFF", 0x00006304 },
+{ "BC_REGISTER_LOOPER", 0x0000630b },
+{ "BC_ENTER_LOOPER", 0x0000630c },
+{ "BC_EXIT_LOOPER", 0x0000630d },
+{ "CHIOINITELEM", 0x00006311 },
+{ "KCOV_ENABLE", 0x00006364 },
+{ "KCOV_DISABLE", 0x00006365 },
+{ "DRM_IOCTL_SET_MASTER", 0x0000641e },
+{ "DRM_IOCTL_DROP_MASTER", 0x0000641f },
+{ "DRM_IOCTL_AGP_ACQUIRE", 0x00006430 },
+{ "DRM_IOCTL_AGP_RELEASE", 0x00006431 },
+{ "DRM_IOCTL_I915_FLUSH", 0x00006441 },
+{ "DRM_IOCTL_R128_CCE_START", 0x00006441 },
+{ "DRM_IOCTL_RADEON_CP_START", 0x00006441 },
+{ "DRM_IOCTL_I915_FLIP", 0x00006442 },
+{ "DRM_IOCTL_MGA_RESET", 0x00006442 },
+{ "DRM_IOCTL_I810_FLUSH", 0x00006443 },
+{ "DRM_IOCTL_MGA_SWAP", 0x00006443 },
+{ "DRM_IOCTL_R128_CCE_RESET", 0x00006443 },
+{ "DRM_IOCTL_RADEON_CP_RESET", 0x00006443 },
+{ "DRM_IOCTL_I810_GETAGE", 0x00006444 },
+{ "DRM_IOCTL_R128_CCE_IDLE", 0x00006444 },
+{ "DRM_IOCTL_RADEON_CP_IDLE", 0x00006444 },
+{ "DRM_IOCTL_RADEON_RESET", 0x00006445 },
+{ "DRM_IOCTL_I810_SWAP", 0x00006446 },
+{ "DRM_IOCTL_R128_RESET", 0x00006446 },
+{ "DRM_IOCTL_R128_SWAP", 0x00006447 },
+{ "DRM_IOCTL_RADEON_SWAP", 0x00006447 },
+{ "DRM_IOCTL_I810_DOCOPY", 0x00006448 },
+{ "DRM_IOCTL_VIA_FLUSH", 0x00006449 },
+{ "DRM_IOCTL_I810_FSTATUS", 0x0000644a },
+{ "DRM_IOCTL_I810_OV0FLIP", 0x0000644b },
+{ "DRM_IOCTL_I810_RSTATUS", 0x0000644d },
+{ "DRM_IOCTL_I810_FLIP", 0x0000644e },
+{ "DRM_IOCTL_RADEON_FLIP", 0x00006452 },
+{ "DRM_IOCTL_R128_FLIP", 0x00006453 },
+{ "DRM_IOCTL_I915_GEM_THROTTLE", 0x00006458 },
+{ "DRM_IOCTL_RADEON_CP_RESUME", 0x00006458 },
+{ "DRM_IOCTL_I915_GEM_ENTERVT", 0x00006459 },
+{ "DRM_IOCTL_I915_GEM_LEAVEVT", 0x0000645a },
+{ "S5P_FIMC_TX_END_NOTIFY", 0x00006500 },
+{ "FUNCTIONFS_FIFO_STATUS", 0x00006701 },
+{ "GADGETFS_FIFO_STATUS", 0x00006701 },
+{ "FUNCTIONFS_FIFO_FLUSH", 0x00006702 },
+{ "GADGETFS_FIFO_FLUSH", 0x00006702 },
+{ "FUNCTIONFS_CLEAR_HALT", 0x00006703 },
+{ "GADGETFS_CLEAR_HALT", 0x00006703 },
+{ "FUNCTIONFS_INTERFACE_REVMAP", 0x00006780 },
+{ "FUNCTIONFS_ENDPOINT_REVMAP", 0x00006781 },
+{ "HPET_IE_ON", 0x00006801 },
+{ "HPET_IE_OFF", 0x00006802 },
+{ "HPET_EPI", 0x00006804 },
+{ "HPET_DPI", 0x00006805 },
+{ "LIRC_NOTIFY_DECODE", 0x00006920 },
+{ "LIRC_SETUP_START", 0x00006921 },
+{ "LIRC_SETUP_END", 0x00006922 },
+{ "KYRO_IOCTL_OVERLAY_CREATE", 0x00006b00 },
+{ "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", 0x00006b01 },
+{ "KYRO_IOCTL_SET_VIDEO_MODE", 0x00006b02 },
+{ "KYRO_IOCTL_UVSTRIDE", 0x00006b03 },
+{ "KYRO_IOCTL_OVERLAY_OFFSET", 0x00006b04 },
+{ "KYRO_IOCTL_STRIDE", 0x00006b05 },
+{ "HSC_RESET", 0x00006b10 },
+{ "HSC_SET_PM", 0x00006b11 },
+{ "HSC_SEND_BREAK", 0x00006b12 },
+{ "MMTIMER_GETOFFSET", 0x00006d00 },
+{ "MGSL_IOCSTXIDLE", 0x00006d02 },
+{ "MGSL_IOCGTXIDLE", 0x00006d03 },
+{ "MGSL_IOCTXENABLE", 0x00006d04 },
+{ "MMTIMER_GETBITS", 0x00006d04 },
+{ "MGSL_IOCRXENABLE", 0x00006d05 },
+{ "MGSL_IOCTXABORT", 0x00006d06 },
+{ "MMTIMER_MMAPAVAIL", 0x00006d06 },
+{ "MGSL_IOCGSTATS", 0x00006d07 },
+{ "MGSL_IOCLOOPTXDONE", 0x00006d09 },
+{ "MGSL_IOCSIF", 0x00006d0a },
+{ "MGSL_IOCGIF", 0x00006d0b },
+{ "MGSL_IOCCLRMODCOUNT", 0x00006d0f },
+{ "MGSL_IOCSXSYNC", 0x00006d13 },
+{ "MGSL_IOCGXSYNC", 0x00006d14 },
+{ "MGSL_IOCSXCTRL", 0x00006d15 },
+{ "MGSL_IOCGXCTRL", 0x00006d16 },
+{ "NCP_IOC_CONN_LOGGED_IN", 0x00006e03 },
+{ "AUDIO_STOP", 0x00006f01 },
+{ "AUDIO_PLAY", 0x00006f02 },
+{ "AUDIO_PAUSE", 0x00006f03 },
+{ "AUDIO_CONTINUE", 0x00006f04 },
+{ "AUDIO_SELECT_SOURCE", 0x00006f05 },
+{ "AUDIO_SET_MUTE", 0x00006f06 },
+{ "AUDIO_SET_AV_SYNC", 0x00006f07 },
+{ "AUDIO_SET_BYPASS_MODE", 0x00006f08 },
+{ "AUDIO_CHANNEL_SELECT", 0x00006f09 },
+{ "AUDIO_CLEAR_BUFFER", 0x00006f0c },
+{ "AUDIO_SET_ID", 0x00006f0d },
+{ "AUDIO_SET_STREAMTYPE", 0x00006f0f },
+{ "AUDIO_SET_EXT_ID", 0x00006f10 },
+{ "AUDIO_BILINGUAL_CHANNEL_SELECT", 0x00006f14 },
+{ "VIDEO_STOP", 0x00006f15 },
+{ "VIDEO_PLAY", 0x00006f16 },
+{ "VIDEO_FREEZE", 0x00006f17 },
+{ "VIDEO_CONTINUE", 0x00006f18 },
+{ "VIDEO_SELECT_SOURCE", 0x00006f19 },
+{ "VIDEO_SET_BLANK", 0x00006f1a },
+{ "VIDEO_SET_DISPLAY_FORMAT", 0x00006f1d },
+{ "VIDEO_FAST_FORWARD", 0x00006f1f },
+{ "VIDEO_SLOWMOTION", 0x00006f20 },
+{ "VIDEO_CLEAR_BUFFER", 0x00006f22 },
+{ "VIDEO_SET_ID", 0x00006f23 },
+{ "VIDEO_SET_STREAMTYPE", 0x00006f24 },
+{ "VIDEO_SET_FORMAT", 0x00006f25 },
+{ "VIDEO_SET_SYSTEM", 0x00006f26 },
+{ "DMX_START", 0x00006f29 },
+{ "DMX_STOP", 0x00006f2a },
+{ "DMX_SET_BUFFER_SIZE", 0x00006f2d },
+{ "NET_REMOVE_IF", 0x00006f35 },
+{ "VIDEO_SET_ATTRIBUTES", 0x00006f35 },
+{ "FE_DISEQC_RESET_OVERLOAD", 0x00006f3e },
+{ "FE_DISEQC_SEND_BURST", 0x00006f41 },
+{ "FE_SET_TONE", 0x00006f42 },
+{ "FE_SET_VOLTAGE", 0x00006f43 },
+{ "FE_ENABLE_HIGH_LNB_VOLTAGE", 0x00006f44 },
+{ "FE_DISHNETWORK_SEND_LEGACY_CMD", 0x00006f50 },
+{ "FE_SET_FRONTEND_TUNE_MODE", 0x00006f51 },
+{ "CA_RESET", 0x00006f80 },
+{ "RTC_AIE_ON", 0x00007001 },
+{ "RTC_AIE_OFF", 0x00007002 },
+{ "RTC_UIE_ON", 0x00007003 },
+{ "PHN_NOT_OH", 0x00007004 },
+{ "RTC_UIE_OFF", 0x00007004 },
+{ "RTC_PIE_ON", 0x00007005 },
+{ "RTC_PIE_OFF", 0x00007006 },
+{ "RTC_WIE_ON", 0x0000700f },
+{ "RTC_WIE_OFF", 0x00007010 },
+{ "RTC_VL_CLR", 0x00007014 },
+{ "NVRAM_INIT", 0x00007040 },
+{ "NVRAM_SETCKS", 0x00007041 },
+{ "PPCLAIM", 0x0000708b },
+{ "PPRELEASE", 0x0000708c },
+{ "PPYIELD", 0x0000708d },
+{ "PPEXCL", 0x0000708f },
+{ "PHONE_CAPABILITIES", 0x00007180 },
+{ "PHONE_RING", 0x00007183 },
+{ "PHONE_HOOKSTATE", 0x00007184 },
+{ "OLD_PHONE_RING_START", 0x00007187 },
+{ "PHONE_RING_STOP", 0x00007188 },
+{ "PHONE_REC_START", 0x0000718a },
+{ "PHONE_REC_STOP", 0x0000718b },
+{ "PHONE_REC_LEVEL", 0x0000718f },
+{ "PHONE_PLAY_START", 0x00007191 },
+{ "PHONE_PLAY_STOP", 0x00007192 },
+{ "PHONE_PLAY_LEVEL", 0x00007195 },
+{ "PHONE_GET_TONE_ON_TIME", 0x0000719e },
+{ "PHONE_GET_TONE_OFF_TIME", 0x0000719f },
+{ "PHONE_GET_TONE_STATE", 0x000071a0 },
+{ "PHONE_BUSY", 0x000071a1 },
+{ "PHONE_RINGBACK", 0x000071a2 },
+{ "PHONE_DIALTONE", 0x000071a3 },
+{ "PHONE_CPT_STOP", 0x000071a4 },
+{ "PHONE_PSTN_GET_STATE", 0x000071a5 },
+{ "PHONE_PSTN_LINETEST", 0x000071a8 },
+{ "IXJCTL_DSP_RESET", 0x000071c0 },
+{ "IXJCTL_DSP_IDLE", 0x000071c5 },
+{ "IXJCTL_TESTRAM", 0x000071c6 },
+{ "IXJCTL_AEC_STOP", 0x000071cc },
+{ "IXJCTL_AEC_GET_LEVEL", 0x000071cd },
+{ "IXJCTL_PSTN_LINETEST", 0x000071d3 },
+{ "IXJCTL_PLAY_CID", 0x000071d7 },
+{ "IXJCTL_DRYBUFFER_CLEAR", 0x000071e7 },
+{ "BR_OK", 0x00007201 },
+{ "BR_DEAD_REPLY", 0x00007205 },
+{ "BR_TRANSACTION_COMPLETE", 0x00007206 },
+{ "BR_NOOP", 0x0000720c },
+{ "BR_SPAWN_LOOPER", 0x0000720d },
+{ "BR_FINISHED", 0x0000720e },
+{ "BR_FAILED_REPLY", 0x00007211 },
+{ "PPPIOCDISCONN", 0x00007439 },
+{ "PPPIOCXFERUNIT", 0x0000744e },
+{ "MEYEIOC_STILLCAPT", 0x000076c4 },
+{ "ASHMEM_GET_SIZE", 0x00007704 },
+{ "ASHMEM_GET_PROT_MASK", 0x00007706 },
+{ "ASHMEM_GET_PIN_STATUS", 0x00007709 },
+{ "ASHMEM_PURGE_ALL_CACHES", 0x0000770a },
+{ "FIOSETOWN", 0x00008901 },
+{ "SIOCSPGRP", 0x00008902 },
+{ "FIOGETOWN", 0x00008903 },
+{ "SIOCGPGRP", 0x00008904 },
+{ "SIOCATMARK", 0x00008905 },
+{ "SIOCGSTAMP", 0x00008906 },
+{ "SIOCGSTAMPNS", 0x00008907 },
+{ "SIOCADDRT", 0x0000890b },
+{ "SIOCDELRT", 0x0000890c },
+{ "SIOCRTMSG", 0x0000890d },
+{ "SIOCGIFNAME", 0x00008910 },
+{ "SIOCSIFLINK", 0x00008911 },
+{ "SIOCGIFCONF", 0x00008912 },
+{ "SIOCGIFFLAGS", 0x00008913 },
+{ "SIOCSIFFLAGS", 0x00008914 },
+{ "SIOCGIFADDR", 0x00008915 },
+{ "SIOCSIFADDR", 0x00008916 },
+{ "SIOCGIFDSTADDR", 0x00008917 },
+{ "SIOCSIFDSTADDR", 0x00008918 },
+{ "SIOCGIFBRDADDR", 0x00008919 },
+{ "SIOCSIFBRDADDR", 0x0000891a },
+{ "SIOCGIFNETMASK", 0x0000891b },
+{ "SIOCSIFNETMASK", 0x0000891c },
+{ "SIOCGIFMETRIC", 0x0000891d },
+{ "SIOCSIFMETRIC", 0x0000891e },
+{ "SIOCGIFMEM", 0x0000891f },
+{ "SIOCSIFMEM", 0x00008920 },
+{ "SIOCGIFMTU", 0x00008921 },
+{ "SIOCSIFMTU", 0x00008922 },
+{ "SIOCSIFNAME", 0x00008923 },
+{ "SIOCSIFHWADDR", 0x00008924 },
+{ "SIOCGIFENCAP", 0x00008925 },
+{ "SIOCSIFENCAP", 0x00008926 },
+{ "SIOCGIFHWADDR", 0x00008927 },
+{ "SIOCGIFSLAVE", 0x00008929 },
+{ "SIOCSIFSLAVE", 0x00008930 },
+{ "SIOCADDMULTI", 0x00008931 },
+{ "SIOCDELMULTI", 0x00008932 },
+{ "SIOCGIFINDEX", 0x00008933 },
+{ "SIOCSIFPFLAGS", 0x00008934 },
+{ "SIOCGIFPFLAGS", 0x00008935 },
+{ "SIOCDIFADDR", 0x00008936 },
+{ "SIOCSIFHWBROADCAST", 0x00008937 },
+{ "SIOCGIFCOUNT", 0x00008938 },
+{ "SIOCGIFBR", 0x00008940 },
+{ "SIOCSIFBR", 0x00008941 },
+{ "SIOCGIFTXQLEN", 0x00008942 },
+{ "SIOCSIFTXQLEN", 0x00008943 },
+{ "SIOCETHTOOL", 0x00008946 },
+{ "SIOCGMIIPHY", 0x00008947 },
+{ "SIOCGMIIREG", 0x00008948 },
+{ "SIOCSMIIREG", 0x00008949 },
+{ "SIOCWANDEV", 0x0000894a },
+{ "SIOCOUTQNSD", 0x0000894b },
+{ "SIOCDARP", 0x00008953 },
+{ "SIOCGARP", 0x00008954 },
+{ "SIOCSARP", 0x00008955 },
+{ "SIOCDRARP", 0x00008960 },
+{ "SIOCGRARP", 0x00008961 },
+{ "SIOCSRARP", 0x00008962 },
+{ "SIOCGIFMAP", 0x00008970 },
+{ "SIOCSIFMAP", 0x00008971 },
+{ "SIOCADDDLCI", 0x00008980 },
+{ "SIOCDELDLCI", 0x00008981 },
+{ "SIOCGIFVLAN", 0x00008982 },
+{ "SIOCSIFVLAN", 0x00008983 },
+{ "SIOCBONDENSLAVE", 0x00008990 },
+{ "SIOCBONDRELEASE", 0x00008991 },
+{ "SIOCBONDSETHWADDR", 0x00008992 },
+{ "SIOCBONDSLAVEINFOQUERY", 0x00008993 },
+{ "SIOCBONDINFOQUERY", 0x00008994 },
+{ "SIOCBONDCHANGEACTIVE", 0x00008995 },
+{ "SIOCBRADDBR", 0x000089a0 },
+{ "SIOCBRDELBR", 0x000089a1 },
+{ "SIOCBRADDIF", 0x000089a2 },
+{ "SIOCBRDELIF", 0x000089a3 },
+{ "SIOCSHWTSTAMP", 0x000089b0 },
+{ "SIOCGHWTSTAMP", 0x000089b1 },
+{ "SIOCPROTOPRIVATE", 0x000089e0 },
+{ "SIOCDEVPRIVATE", 0x000089f0 },
+{ "SIOCIWFIRST", 0x00008b00 },
+{ "SIOCSIWCOMMIT", 0x00008b00 },
+{ "SIOCGIWNAME", 0x00008b01 },
+{ "SIOCSIWNWID", 0x00008b02 },
+{ "SIOCGIWNWID", 0x00008b03 },
+{ "SIOCSIWFREQ", 0x00008b04 },
+{ "SIOCGIWFREQ", 0x00008b05 },
+{ "SIOCSIWMODE", 0x00008b06 },
+{ "SIOCGIWMODE", 0x00008b07 },
+{ "SIOCSIWSENS", 0x00008b08 },
+{ "SIOCGIWSENS", 0x00008b09 },
+{ "SIOCSIWRANGE", 0x00008b0a },
+{ "SIOCGIWRANGE", 0x00008b0b },
+{ "SIOCSIWPRIV", 0x00008b0c },
+{ "SIOCGIWPRIV", 0x00008b0d },
+{ "SIOCSIWSTATS", 0x00008b0e },
+{ "SIOCGIWSTATS", 0x00008b0f },
+{ "SIOCSIWSPY", 0x00008b10 },
+{ "SIOCGIWSPY", 0x00008b11 },
+{ "SIOCSIWTHRSPY", 0x00008b12 },
+{ "SIOCGIWTHRSPY", 0x00008b13 },
+{ "SIOCSIWAP", 0x00008b14 },
+{ "SIOCGIWAP", 0x00008b15 },
+{ "SIOCSIWMLME", 0x00008b16 },
+{ "SIOCGIWAPLIST", 0x00008b17 },
+{ "SIOCSIWSCAN", 0x00008b18 },
+{ "SIOCGIWSCAN", 0x00008b19 },
+{ "SIOCSIWESSID", 0x00008b1a },
+{ "SIOCGIWESSID", 0x00008b1b },
+{ "SIOCSIWNICKN", 0x00008b1c },
+{ "SIOCGIWNICKN", 0x00008b1d },
+{ "SIOCSIWRATE", 0x00008b20 },
+{ "SIOCGIWRATE", 0x00008b21 },
+{ "SIOCSIWRTS", 0x00008b22 },
+{ "SIOCGIWRTS", 0x00008b23 },
+{ "SIOCSIWFRAG", 0x00008b24 },
+{ "SIOCGIWFRAG", 0x00008b25 },
+{ "SIOCSIWTXPOW", 0x00008b26 },
+{ "SIOCGIWTXPOW", 0x00008b27 },
+{ "SIOCSIWRETRY", 0x00008b28 },
+{ "SIOCGIWRETRY", 0x00008b29 },
+{ "SIOCSIWENCODE", 0x00008b2a },
+{ "SIOCGIWENCODE", 0x00008b2b },
+{ "SIOCSIWPOWER", 0x00008b2c },
+{ "SIOCGIWPOWER", 0x00008b2d },
+{ "SIOCSIWGENIE", 0x00008b30 },
+{ "SIOCGIWGENIE", 0x00008b31 },
+{ "SIOCSIWAUTH", 0x00008b32 },
+{ "SIOCGIWAUTH", 0x00008b33 },
+{ "SIOCSIWENCODEEXT", 0x00008b34 },
+{ "SIOCGIWENCODEEXT", 0x00008b35 },
+{ "SIOCSIWPMKSA", 0x00008b36 },
+{ "SIOCIWFIRSTPRIV", 0x00008be0 },
+{ "SIOCIWLASTPRIV", 0x00008bff },
+{ "AUTOFS_IOC_READY", 0x00009360 },
+{ "AUTOFS_IOC_FAIL", 0x00009361 },
+{ "AUTOFS_IOC_CATATONIC", 0x00009362 },
+{ "BTRFS_IOC_TRANS_START", 0x00009406 },
+{ "BTRFS_IOC_TRANS_END", 0x00009407 },
+{ "BTRFS_IOC_SYNC", 0x00009408 },
+{ "BTRFS_IOC_SCRUB_CANCEL", 0x0000941c },
+{ "BTRFS_IOC_QUOTA_RESCAN_WAIT", 0x0000942e },
+{ "NBD_SET_SOCK", 0x0000ab00 },
+{ "NBD_SET_BLKSIZE", 0x0000ab01 },
+{ "NBD_SET_SIZE", 0x0000ab02 },
+{ "NBD_DO_IT", 0x0000ab03 },
+{ "NBD_CLEAR_SOCK", 0x0000ab04 },
+{ "NBD_CLEAR_QUE", 0x0000ab05 },
+{ "NBD_PRINT_DEBUG", 0x0000ab06 },
+{ "NBD_SET_SIZE_BLOCKS", 0x0000ab07 },
+{ "NBD_DISCONNECT", 0x0000ab08 },
+{ "NBD_SET_TIMEOUT", 0x0000ab09 },
+{ "NBD_SET_FLAGS", 0x0000ab0a },
+{ "RAW_SETBIND", 0x0000ac00 },
+{ "RAW_GETBIND", 0x0000ac01 },
+{ "KVM_GET_API_VERSION", 0x0000ae00 },
+{ "KVM_CREATE_VM", 0x0000ae01 },
+{ "KVM_CHECK_EXTENSION", 0x0000ae03 },
+{ "KVM_GET_VCPU_MMAP_SIZE", 0x0000ae04 },
+{ "KVM_S390_ENABLE_SIE", 0x0000ae06 },
+{ "KVM_CREATE_VCPU", 0x0000ae41 },
+{ "KVM_SET_NR_MMU_PAGES", 0x0000ae44 },
+{ "KVM_GET_NR_MMU_PAGES", 0x0000ae45 },
+{ "KVM_SET_TSS_ADDR", 0x0000ae47 },
+{ "KVM_CREATE_IRQCHIP", 0x0000ae60 },
+{ "KVM_CREATE_PIT", 0x0000ae64 },
+{ "KVM_REINJECT_CONTROL", 0x0000ae71 },
+{ "KVM_SET_BOOT_CPU_ID", 0x0000ae78 },
+{ "KVM_RUN", 0x0000ae80 },
+{ "KVM_S390_INITIAL_RESET", 0x0000ae97 },
+{ "KVM_NMI", 0x0000ae9a },
+{ "KVM_SET_TSC_KHZ", 0x0000aea2 },
+{ "KVM_GET_TSC_KHZ", 0x0000aea3 },
+{ "KVM_KVMCLOCK_CTRL", 0x0000aead },
+{ "KVM_SMI", 0x0000aeb7 },
+{ "VHOST_SET_OWNER", 0x0000af01 },
+{ "VHOST_RESET_OWNER", 0x0000af02 },
+{ "PPPOEIOCDFWD", 0x0000b101 },
+{ "IOCTL_EVTCHN_BIND_VIRQ", 0x00044500 },
+{ "IOCTL_EVTCHN_BIND_UNBOUND_PORT", 0x00044502 },
+{ "IOCTL_EVTCHN_UNBIND", 0x00044503 },
+{ "IOCTL_EVTCHN_NOTIFY", 0x00044504 },
+{ "IOCTL_GNTDEV_SET_MAX_GRANTS", 0x00044703 },
+{ "IOCTL_EVTCHN_BIND_INTERDOMAIN", 0x00084501 },
+{ "IOCTL_GNTDEV_GRANT_COPY", 0x00084708 },
+{ "IOCTL_GNTDEV_UNMAP_GRANT_REF", 0x00104701 },
+{ "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", 0x00104707 },
+{ "IOCTL_GNTDEV_MAP_GRANT_REF", 0x00184700 },
+{ "IOCTL_GNTDEV_GET_OFFSET_FOR_VADDR", 0x00184702 },
+{ "MFB_SET_ALPHA", 0x40014d00 },
+{ "MFB_SET_GAMMA", 0x40014d01 },
+{ "MFB_SET_BRIGHTNESS", 0x40014d03 },
+{ "USBTMC488_IOCTL_REN_CONTROL", 0x40015b13 },
+{ "SPI_IOC_WR_MODE", 0x40016b01 },
+{ "SPI_IOC_WR_LSB_FIRST", 0x40016b02 },
+{ "SPI_IOC_WR_BITS_PER_WORD", 0x40016b03 },
+{ "PPWCONTROL", 0x40017084 },
+{ "PPWDATA", 0x40017086 },
+{ "PPWCTLONIRQ", 0x40017092 },
+{ "PHONE_MAXRINGS", 0x40017185 },
+{ "PHONE_PLAY_TONE", 0x4001719b },
+{ "SONYPI_IOCSBRT", 0x40017600 },
+{ "SONYPI_IOCSBLUE", 0x40017609 },
+{ "SONYPI_IOCSFAN", 0x4001760b },
+{ "HFI1_IOCTL_SET_PKEY", 0x40021beb },
+{ "ATM_SETBACKEND", 0x400261f2 },
+{ "ATM_NEWBACKENDIF", 0x400261f3 },
+{ "RIO_MPORT_MAINT_HDID_SET", 0x40026d01 },
+{ "NCP_IOC_GETMOUNTUID", 0x40026e02 },
+{ "AUDIO_SET_ATTRIBUTES", 0x40026f11 },
+{ "DMX_ADD_PID", 0x40026f33 },
+{ "DMX_REMOVE_PID", 0x40026f34 },
+{ "PPFCONTROL", 0x4002708e },
+{ "PHONE_RING_CADENCE", 0x40027186 },
+{ "SET_BITMAP_FILE", 0x4004092b },
+{ "BLKBSZSET", 0x40041271 },
+{ "IB_USER_MAD_UNREGISTER_AGENT", 0x40041b02 },
+{ "HFI1_IOCTL_RECV_CTRL", 0x40041be8 },
+{ "HFI1_IOCTL_POLL_TYPE", 0x40041be9 },
+{ "HFI1_IOCTL_ACK_EVENT", 0x40041bea },
+{ "FW_CDEV_IOC_DEALLOCATE", 0x40042303 },
+{ "FW_CDEV_IOC_INITIATE_BUS_RESET", 0x40042305 },
+{ "FW_CDEV_IOC_REMOVE_DESCRIPTOR", 0x40042307 },
+{ "FW_CDEV_IOC_STOP_ISO", 0x4004230b },
+{ "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", 0x4004230e },
+{ "FW_CDEV_IOC_FLUSH_ISO", 0x40042318 },
+{ "PERF_EVENT_IOC_SET_FILTER", 0x40042406 },
+{ "PERF_EVENT_IOC_SET_BPF", 0x40042408 },
+{ "PERF_EVENT_IOC_PAUSE_OUTPUT", 0x40042409 },
+{ "SNAPSHOT_CREATE_IMAGE", 0x40043311 },
+{ "PTP_ENABLE_PPS", 0x40043d04 },
+{ "FBIO_RADEON_SET_MIRROR", 0x40044004 },
+{ "SNDRV_PCM_IOCTL_TSTAMP", 0x40044102 },
+{ "AGPIOC_SETUP", 0x40044103 },
+{ "SNDRV_PCM_IOCTL_TTSTAMP", 0x40044103 },
+{ "AGPIOC_RESERVE", 0x40044104 },
+{ "AGPIOC_PROTECT", 0x40044105 },
+{ "AGPIOC_DEALLOCATE", 0x40044107 },
+{ "AGPIOC_BIND", 0x40044108 },
+{ "AGPIOC_UNBIND", 0x40044109 },
+{ "SNDRV_PCM_IOCTL_PAUSE", 0x40044145 },
+{ "SNDRV_PCM_IOCTL_REWIND", 0x40044146 },
+{ "SNDRV_PCM_IOCTL_FORWARD", 0x40044149 },
+{ "SNDRV_PCM_IOCTL_LINK", 0x40044160 },
+{ "PMU_IOC_SET_BACKLIGHT", 0x40044202 },
+{ "CCISS_REGNEWDISK", 0x4004420d },
+{ "CS_SET_WAKELINE", 0x40044317 },
+{ "EVIOCRMFF", 0x40044581 },
+{ "EVIOCGRAB", 0x40044590 },
+{ "EVIOCREVOKE", 0x40044591 },
+{ "EVIOCSCLOCKID", 0x400445a0 },
+{ "FBIOPUT_CONTRAST", 0x40044602 },
+{ "FBIPUT_BRIGHTNESS", 0x40044603 },
+{ "FBIPUT_COLOR", 0x40044606 },
+{ "FBIPUT_HSYNC", 0x40044609 },
+{ "FBIPUT_VSYNC", 0x4004460a },
+{ "FBIO_WAITFORVSYNC", 0x40044620 },
+{ "SSTFB_SET_VGAPASS", 0x400446dd },
+{ "IOCTL_MEI_NOTIFY_SET", 0x40044802 },
+{ "HIDIOCSFLAG", 0x4004480f },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", 0x40044820 },
+{ "SNDRV_DM_FM_IOCTL_SET_MODE", 0x40044825 },
+{ "SNDRV_DM_FM_IOCTL_SET_CONNECTION", 0x40044826 },
+{ "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", 0x40044842 },
+{ "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", 0x40044883 },
+{ "SNDRV_EMUX_IOCTL_MEM_AVAIL", 0x40044884 },
+{ "HCIDEVUP", 0x400448c9 },
+{ "HCIDEVDOWN", 0x400448ca },
+{ "HCIDEVRESET", 0x400448cb },
+{ "HCIDEVRESTAT", 0x400448cc },
+{ "HCISETRAW", 0x400448dc },
+{ "HCISETSCAN", 0x400448dd },
+{ "HCISETAUTH", 0x400448de },
+{ "HCISETENCRYPT", 0x400448df },
+{ "HCISETPTYPE", 0x400448e0 },
+{ "HCISETLINKPOL", 0x400448e1 },
+{ "HCISETLINKMODE", 0x400448e2 },
+{ "HCISETACLMTU", 0x400448e3 },
+{ "HCISETSCOMTU", 0x400448e4 },
+{ "HCIBLOCKADDR", 0x400448e6 },
+{ "HCIUNBLOCKADDR", 0x400448e7 },
+{ "MFB_SET_PIXFMT", 0x40044d08 },
+{ "OTPGETREGIONCOUNT", 0x40044d0e },
+{ "UBI_IOCEBER", 0x40044f01 },
+{ "UBI_IOCEBCH", 0x40044f02 },
+{ "UBI_IOCEBUNMAP", 0x40044f04 },
+{ "OMAPFB_MIRROR", 0x40044f1f },
+{ "OMAPFB_SET_UPDATE_MODE", 0x40044f28 },
+{ "OMAPFB_GET_UPDATE_MODE", 0x40044f2b },
+{ "OMAPFB_LCD_TEST", 0x40044f2d },
+{ "OMAPFB_CTRL_TEST", 0x40044f2e },
+{ "SNDCTL_DSP_SETTRIGGER", 0x40045010 },
+{ "SNDCTL_DSP_PROFILE", 0x40045017 },
+{ "SNDCTL_DSP_SETSPDIF", 0x40045042 },
+{ "SNDCTL_SEQ_PERCMODE", 0x40045106 },
+{ "SNDCTL_SEQ_TESTMIDI", 0x40045108 },
+{ "SNDCTL_SEQ_RESETSAMPLES", 0x40045109 },
+{ "SNDCTL_SEQ_THRESHOLD", 0x4004510d },
+{ "SNDCTL_FM_4OP_ENABLE", 0x4004510f },
+{ "RNDADDTOENTCNT", 0x40045201 },
+{ "SAA6588_CMD_CLOSE", 0x40045202 },
+{ "RFCOMMCREATEDEV", 0x400452c8 },
+{ "RFCOMMRELEASEDEV", 0x400452c9 },
+{ "RFCOMMSTEALDLC", 0x400452dc },
+{ "SNDRV_TIMER_IOCTL_TREAD", 0x40045402 },
+{ "SNDCTL_TMR_METRONOME", 0x40045407 },
+{ "SNDCTL_TMR_SELECT", 0x40045408 },
+{ "TIOCSPTLCK", 0x40045431 },
+{ "TIOCSIG", 0x40045436 },
+{ "TUNSETNOCSUM", 0x400454c8 },
+{ "TUNSETDEBUG", 0x400454c9 },
+{ "TUNSETIFF", 0x400454ca },
+{ "TUNSETPERSIST", 0x400454cb },
+{ "TUNSETOWNER", 0x400454cc },
+{ "TUNSETLINK", 0x400454cd },
+{ "TUNSETGROUP", 0x400454ce },
+{ "TUNSETOFFLOAD", 0x400454d0 },
+{ "TUNSETTXFILTER", 0x400454d1 },
+{ "TUNSETSNDBUF", 0x400454d4 },
+{ "TUNSETVNETHDRSZ", 0x400454d8 },
+{ "TUNSETQUEUE", 0x400454d9 },
+{ "TUNSETIFINDEX", 0x400454da },
+{ "TUNSETVNETLE", 0x400454dc },
+{ "TUNSETVNETBE", 0x400454de },
+{ "NCIUARTSETDRIVER", 0x40045500 },
+{ "USBDEVFS_REAPURB", 0x4004550c },
+{ "USBDEVFS_REAPURBNDELAY", 0x4004550d },
+{ "USBDEVFS_DROP_PRIVILEGES", 0x4004551e },
+{ "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", 0x40045532 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", 0x40045542 },
+{ "UI_SET_EVBIT", 0x40045564 },
+{ "UI_SET_KEYBIT", 0x40045565 },
+{ "UI_SET_RELBIT", 0x40045566 },
+{ "UI_SET_ABSBIT", 0x40045567 },
+{ "UI_SET_MSCBIT", 0x40045568 },
+{ "UI_SET_LEDBIT", 0x40045569 },
+{ "UI_SET_SNDBIT", 0x4004556a },
+{ "UI_SET_FFBIT", 0x4004556b },
+{ "UI_SET_PHYS", 0x4004556c },
+{ "UI_SET_SWBIT", 0x4004556d },
+{ "UI_SET_PROPBIT", 0x4004556e },
+{ "VIDIOC_OVERLAY", 0x4004560e },
+{ "VIDIOC_STREAMON", 0x40045612 },
+{ "VIDIOC_STREAMOFF", 0x40045613 },
+{ "VIDIOC_S_PRIORITY", 0x40045644 },
+{ "IVTV_IOC_PASSTHROUGH_MODE", 0x400456c1 },
+{ "VIDIOC_AM437X_CCDC_CFG", 0x400456c1 },
+{ "VPFE_CMD_S_CCDC_RAW_PARAMS", 0x400456c1 },
+{ "SW_SYNC_IOC_INC", 0x40045701 },
+{ "SNDRV_RAWMIDI_IOCTL_DROP", 0x40045730 },
+{ "SNDRV_RAWMIDI_IOCTL_DRAIN", 0x40045731 },
+{ "SONET_SETFRAMING", 0x40046115 },
+{ "ATM_SETSC", 0x400461f1 },
+{ "ATM_DROPPARTY", 0x400461f5 },
+{ "BINDER_SET_MAX_THREADS", 0x40046205 },
+{ "BINDER_SET_IDLE_PRIORITY", 0x40046206 },
+{ "BINDER_SET_CONTEXT_MGR", 0x40046207 },
+{ "BINDER_THREAD_EXIT", 0x40046208 },
+{ "BC_ACQUIRE_RESULT", 0x40046302 },
+{ "CM_IOCSPTS", 0x40046302 },
+{ "BC_INCREFS", 0x40046304 },
+{ "BC_ACQUIRE", 0x40046305 },
+{ "CHIOSPICKER", 0x40046305 },
+{ "BC_RELEASE", 0x40046306 },
+{ "BC_DECREFS", 0x40046307 },
+{ "CM_IOSDBGLVL", 0x400463fa },
+{ "DRM_IOCTL_AUTH_MAGIC", 0x40046411 },
+{ "DRM_IOCTL_AGP_ENABLE", 0x40046432 },
+{ "DRM_IOCTL_I915_IRQ_WAIT", 0x40046445 },
+{ "DRM_IOCTL_MSM_GEM_CPU_FINI", 0x40046445 },
+{ "DRM_IOCTL_RADEON_FULLSCREEN", 0x40046446 },
+{ "DRM_IOCTL_MGA_SET_FENCE", 0x4004644a },
+{ "DRM_IOCTL_I915_DESTROY_HEAP", 0x4004644c },
+{ "DRM_IOCTL_RADEON_STIPPLE", 0x4004644c },
+{ "DRM_IOCTL_I915_SET_VBLANK_PIPE", 0x4004644d },
+{ "DRM_IOCTL_R128_STIPPLE", 0x4004644d },
+{ "DRM_IOCTL_R128_FULLSCREEN", 0x40046450 },
+{ "DRM_IOCTL_RADEON_IRQ_WAIT", 0x40046457 },
+{ "DRM_IOCTL_RADEON_SURF_FREE", 0x4004645b },
+{ "DRM_IOCTL_I915_GEM_SW_FINISH", 0x40046460 },
+{ "VIDIOC_INT_RESET", 0x40046466 },
+{ "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", 0x40046483 },
+{ "FS_IOC32_SETFLAGS", 0x40046602 },
+{ "FS_IOC_SETFLAGS", 0x40046602 },
+{ "HPET_IRQFREQ", 0x40046806 },
+{ "LIRC_SET_SEND_MODE", 0x40046911 },
+{ "LIRC_SET_REC_MODE", 0x40046912 },
+{ "LIRC_SET_SEND_CARRIER", 0x40046913 },
+{ "LIRC_SET_REC_CARRIER", 0x40046914 },
+{ "LIRC_SET_SEND_DUTY_CYCLE", 0x40046915 },
+{ "LIRC_SET_REC_DUTY_CYCLE", 0x40046916 },
+{ "LIRC_SET_TRANSMITTER_MASK", 0x40046917 },
+{ "LIRC_SET_REC_TIMEOUT", 0x40046918 },
+{ "LIRC_SET_REC_TIMEOUT_REPORTS", 0x40046919 },
+{ "LIRC_SET_REC_FILTER_PULSE", 0x4004691a },
+{ "LIRC_SET_REC_FILTER_SPACE", 0x4004691b },
+{ "LIRC_SET_REC_FILTER", 0x4004691c },
+{ "LIRC_SET_MEASURE_CARRIER_MODE", 0x4004691d },
+{ "LIRC_SET_REC_DUTY_CYCLE_RANGE", 0x4004691e },
+{ "IPMICTL_SET_MAINTENANCE_MODE_CMD", 0x4004691f },
+{ "LIRC_SET_REC_CARRIER_RANGE", 0x4004691f },
+{ "LIRC_SET_WIDEBAND_RECEIVER", 0x40046923 },
+{ "SPI_IOC_WR_MAX_SPEED_HZ", 0x40046b04 },
+{ "SPI_IOC_WR_MODE32", 0x40046b05 },
+{ "RIO_MPORT_MAINT_COMPTAG_SET", 0x40046d02 },
+{ "RIO_SET_EVENT_MASK", 0x40046d0d },
+{ "NCP_IOC_GETMOUNTUID2", 0x40046e02 },
+{ "NCP_IOC_SET_SIGN_WANTED", 0x40046e06 },
+{ "NCP_IOC_GETDENTRYTTL", 0x40046e0c },
+{ "MATROXFB_SET_OUTPUT_CONNECTION", 0x40046ef8 },
+{ "MATROXFB_SET_OUTPUT_MODE", 0x40046efa },
+{ "SISFB_SET_AUTOMAXIMIZE_OLD", 0x40046efa },
+{ "UBI_IOCRMVOL", 0x40046f01 },
+{ "DMX_SET_SOURCE", 0x40046f31 },
+{ "UBI_IOCDET", 0x40046f41 },
+{ "PHN_SET_REG", 0x40047001 },
+{ "PHN_SET_REGS", 0x40047003 },
+{ "RTC_IRQP_SET", 0x4004700c },
+{ "RTC_EPOCH_SET", 0x4004700e },
+{ "PPSETMODE", 0x40047080 },
+{ "PPDATADIR", 0x40047090 },
+{ "PPNEGOT", 0x40047091 },
+{ "PPSETPHASE", 0x40047094 },
+{ "PPSETFLAGS", 0x4004709b },
+{ "PPS_SETPARAMS", 0x400470a2 },
+{ "PPS_KC_BIND", 0x400470a5 },
+{ "SPIOCSTYPE", 0x40047101 },
+{ "PHONE_CAPABILITIES_CHECK", 0x40047182 },
+{ "PHONE_RING_START", 0x40047187 },
+{ "PHONE_REC_CODEC", 0x40047189 },
+{ "PHONE_REC_DEPTH", 0x4004718c },
+{ "PHONE_FRAME", 0x4004718d },
+{ "PHONE_REC_VOLUME", 0x4004718e },
+{ "PHONE_PLAY_CODEC", 0x40047190 },
+{ "PHONE_PLAY_DEPTH", 0x40047193 },
+{ "PHONE_PLAY_VOLUME", 0x40047194 },
+{ "PHONE_DTMF_OOB", 0x40047199 },
+{ "PHONE_SET_TONE_ON_TIME", 0x4004719c },
+{ "PHONE_SET_TONE_OFF_TIME", 0x4004719d },
+{ "PHONE_PSTN_SET_STATE", 0x400471a4 },
+{ "PHONE_WINK_DURATION", 0x400471a6 },
+{ "PHONE_VAD", 0x400471a9 },
+{ "PHONE_WINK", 0x400471aa },
+{ "IXJCTL_SET_FILTER", 0x400471c7 },
+{ "IXJCTL_GET_FILTER_HIST", 0x400471c8 },
+{ "IXJCTL_INIT_TONE", 0x400471c9 },
+{ "IXJCTL_TONE_CADENCE", 0x400471ca },
+{ "IXJCTL_AEC_START", 0x400471cb },
+{ "IXJCTL_SET_LED", 0x400471ce },
+{ "IXJCTL_MIXER", 0x400471cf },
+{ "IXJCTL_DAA_COEFF_SET", 0x400471d0 },
+{ "IXJCTL_PORT", 0x400471d1 },
+{ "IXJCTL_DAA_AGAIN", 0x400471d2 },
+{ "IXJCTL_POTS_PSTN", 0x400471d5 },
+{ "IXJCTL_FILTER_CADENCE", 0x400471d6 },
+{ "IXJCTL_CIDCW", 0x400471d9 },
+{ "PHONE_REC_VOLUME_LINEAR", 0x400471db },
+{ "PHONE_PLAY_VOLUME_LINEAR", 0x400471dc },
+{ "IXJCTL_SET_FILTER_RAW", 0x400471dd },
+{ "IXJCTL_HZ", 0x400471e0 },
+{ "IXJCTL_RATE", 0x400471e1 },
+{ "IXJCTL_DTMF_PRESCALE", 0x400471e8 },
+{ "IXJCTL_SIGCTL", 0x400471e9 },
+{ "IXJCTL_SC_RXG", 0x400471ea },
+{ "IXJCTL_SC_TXG", 0x400471eb },
+{ "IXJCTL_INTERCOM_START", 0x400471fd },
+{ "IXJCTL_INTERCOM_STOP", 0x400471fe },
+{ "FAT_IOCTL_SET_ATTRIBUTES", 0x40047211 },
+{ "SCIF_LISTEN", 0x40047302 },
+{ "PPPIOCATTCHAN", 0x40047438 },
+{ "PPPIOCCONNECT", 0x4004743a },
+{ "PPPIOCSMRRU", 0x4004743b },
+{ "PPPIOCDETACH", 0x4004743c },
+{ "PPPIOCATTACH", 0x4004743d },
+{ "PPPIOCSDEBUG", 0x40047440 },
+{ "PPPIOCSMAXCID", 0x40047451 },
+{ "PPPIOCSMRU", 0x40047452 },
+{ "PPPIOCSRASYNCMAP", 0x40047454 },
+{ "PPPIOCSASYNCMAP", 0x40047457 },
+{ "PPPIOCSFLAGS", 0x40047459 },
+{ "PPPIOCBUNDLE", 0x40047481 },
+{ "PPPIOCSMPFLAGS", 0x40047483 },
+{ "PPPIOCSMPMTU", 0x40047484 },
+{ "PPPIOCSMPMRU", 0x40047485 },
+{ "PPPIOCSCOMPRESSOR", 0x40047487 },
+{ "V4L2_SUBDEV_IR_RX_NOTIFY", 0x40047600 },
+{ "V4L2_SUBDEV_IR_TX_NOTIFY", 0x40047601 },
+{ "FS_IOC32_SETVERSION", 0x40047602 },
+{ "FS_IOC_SETVERSION", 0x40047602 },
+{ "MEYEIOC_QBUF_CAPT", 0x400476c2 },
+{ "ASHMEM_SET_SIZE", 0x40047703 },
+{ "ASHMEM_SET_PROT_MASK", 0x40047705 },
+{ "OSIOCSNETADDR", 0x400489e0 },
+{ "SIOCSNETADDR", 0x400489e0 },
+{ "AUTOFS_IOC_EXPIRE_MULTI", 0x40049366 },
+{ "BTRFS_IOC_CLONE", 0x40049409 },
+{ "FICLONE", 0x40049409 },
+{ "BTRFS_IOC_BALANCE_CTL", 0x40049421 },
+{ "KVM_S390_VCPU_FAULT", 0x4004ae52 },
+{ "KVM_INTERRUPT", 0x4004ae86 },
+{ "KVM_SET_SIGNAL_MASK", 0x4004ae8b },
+{ "KVM_S390_STORE_STATUS", 0x4004ae95 },
+{ "KVM_SET_MP_STATE", 0x4004ae99 },
+{ "VHOST_SET_LOG_FD", 0x4004af07 },
+{ "VHOST_SCSI_GET_ABI_VERSION", 0x4004af42 },
+{ "VHOST_SCSI_SET_EVENTS_MISSED", 0x4004af43 },
+{ "VHOST_SCSI_GET_EVENTS_MISSED", 0x4004af44 },
+{ "PPPOEIOCSFWD", 0x4004b100 },
+{ "IOW_WRITE", 0x4004c001 },
+{ "IOW_READ", 0x4004c002 },
+{ "REISERFS_IOC_UNPACK", 0x4004cd01 },
+{ "SISFB_SET_AUTOMAXIMIZE", 0x4004f303 },
+{ "SISFB_SET_TVPOSOFFSET", 0x4004f304 },
+{ "SISFB_SET_LOCK", 0x4004f306 },
+{ "GIGASET_BRKCHARS", 0x40064702 },
+{ "MEYEIOC_S_PARAMS", 0x400676c1 },
+{ "FE_DISEQC_SEND_MASTER_CMD", 0x40076f3f },
+{ "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", 0x40082316 },
+{ "PERF_EVENT_IOC_PERIOD", 0x40082404 },
+{ "STP_SET_OPTIONS", 0x40082502 },
+{ "CCISS_SETINTINFO", 0x40084203 },
+{ "APEI_ERST_CLEAR_RECORD", 0x40084501 },
+{ "EVIOCSREP", 0x40084503 },
+{ "EVIOCSKEYCODE", 0x40084504 },
+{ "SNDRV_SB_CSP_IOCTL_START", 0x40084813 },
+{ "AMDKFD_IOC_DESTROY_EVENT", 0x40084b09 },
+{ "AMDKFD_IOC_SET_EVENT", 0x40084b0a },
+{ "AMDKFD_IOC_RESET_EVENT", 0x40084b0b },
+{ "AMDKFD_IOC_DBG_REGISTER", 0x40084b0d },
+{ "AMDKFD_IOC_DBG_UNREGISTER", 0x40084b0e },
+{ "MEMERASE", 0x40084d02 },
+{ "MFB_SET_AOID", 0x40084d04 },
+{ "MEMLOCK", 0x40084d05 },
+{ "MEMUNLOCK", 0x40084d06 },
+{ "MEMGETBADBLOCK", 0x40084d0b },
+{ "MEMSETBADBLOCK", 0x40084d0c },
+{ "UBI_IOCVOLUP", 0x40084f00 },
+{ "UBI_IOCEBMAP", 0x40084f03 },
+{ "OMAPFB_SETUP_MEM", 0x40084f37 },
+{ "OMAPFB_QUERY_MEM", 0x40084f38 },
+{ "OMAPFB_SET_TEARSYNC", 0x40084f3e },
+{ "SNDCTL_SEQ_OUTOFBAND", 0x40085112 },
+{ "RNDADDENTROPY", 0x40085203 },
+{ "TFD_IOC_SET_TICKS", 0x40085400 },
+{ "TUNATTACHFILTER", 0x400854d5 },
+{ "TUNDETACHFILTER", 0x400854d6 },
+{ "USBDEVFS_CONNECTINFO", 0x40085511 },
+{ "VIDIOC_S_STD", 0x40085618 },
+{ "ATM_GETNAMES", 0x40086183 },
+{ "ATM_ADDPARTY", 0x400861f4 },
+{ "DMA_BUF_IOCTL_SYNC", 0x40086200 },
+{ "BINDER_SET_IDLE_TIMEOUT", 0x40086203 },
+{ "BC_FREE_BUFFER", 0x40086303 },
+{ "CHIOGSTATUS", 0x40086308 },
+{ "BC_ATTEMPT_ACQUIRE", 0x4008630a },
+{ "BC_DEAD_BINDER_DONE", 0x40086310 },
+{ "DRM_IOCTL_MODESET_CTL", 0x40086408 },
+{ "DRM_IOCTL_GEM_CLOSE", 0x40086409 },
+{ "DRM_IOCTL_SET_UNIQUE", 0x40086410 },
+{ "DRM_IOCTL_CONTROL", 0x40086414 },
+{ "DRM_IOCTL_FREE_BUFS", 0x4008641a },
+{ "DRM_IOCTL_SET_SAREA_CTX", 0x4008641c },
+{ "DRM_IOCTL_MOD_CTX", 0x40086422 },
+{ "DRM_IOCTL_SWITCH_CTX", 0x40086424 },
+{ "DRM_IOCTL_NEW_CTX", 0x40086425 },
+{ "DRM_IOCTL_LOCK", 0x4008642a },
+{ "DRM_IOCTL_UNLOCK", 0x4008642b },
+{ "DRM_IOCTL_FINISH", 0x4008642c },
+{ "DRM_IOCTL_AGP_BIND", 0x40086436 },
+{ "DRM_IOCTL_AGP_UNBIND", 0x40086437 },
+{ "DRM_IOCTL_SG_FREE", 0x40086439 },
+{ "DRM_IOCTL_MGA_FLUSH", 0x40086441 },
+{ "DRM_IOCTL_R128_CCE_STOP", 0x40086442 },
+{ "DRM_IOCTL_RADEON_CP_STOP", 0x40086442 },
+{ "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", 0x40086443 },
+{ "DRM_IOCTL_OMAP_GEM_CPU_PREP", 0x40086444 },
+{ "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", 0x40086445 },
+{ "DRM_IOCTL_QXL_CLIENTCAP", 0x40086445 },
+{ "DRM_IOCTL_I915_SETPARAM", 0x40086447 },
+{ "DRM_IOCTL_VIA_CMDBUFFER", 0x40086448 },
+{ "DRM_IOCTL_I915_FREE", 0x40086449 },
+{ "DRM_IOCTL_VIA_PCICMD", 0x4008644a },
+{ "DRM_IOCTL_VIA_BLIT_SYNC", 0x4008644f },
+{ "DRM_IOCTL_RADEON_FREE", 0x40086454 },
+{ "DRM_IOCTL_I915_GEM_UNPIN", 0x40086456 },
+{ "DRM_IOCTL_SIS_FB_INIT", 0x40086456 },
+{ "TUNER_SET_CONFIG", 0x4008645c },
+{ "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", 0x40086464 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", 0x4008646e },
+{ "DRM_IOCTL_I915_GEM_SET_CACHING", 0x4008646f },
+{ "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", 0x40086482 },
+{ "MTIOCTOP", 0x40086d01 },
+{ "RIO_ENABLE_DOORBELL_RANGE", 0x40086d09 },
+{ "RIO_DISABLE_DOORBELL_RANGE", 0x40086d0a },
+{ "RIO_UNMAP_INBOUND", 0x40086d12 },
+{ "RIO_FREE_DMA", 0x40086d14 },
+{ "RIO_WAIT_FOR_ASYNC", 0x40086d16 },
+{ "NILFS_IOCTL_DELETE_CHECKPOINT", 0x40086e81 },
+{ "NILFS_IOCTL_RESIZE", 0x40086e8b },
+{ "AUDIO_SET_MIXER", 0x40086f0e },
+{ "VIDEO_STILLPICTURE", 0x40086f1e },
+{ "VIDEO_SET_SPU", 0x40086f32 },
+{ "VIDEO_SET_SPU_PALETTE", 0x40086f33 },
+{ "FE_SET_PROPERTY", 0x40086f52 },
+{ "CA_SET_PID", 0x40086f87 },
+{ "PHN_SETREG", 0x40087006 },
+{ "PPPIOCSACTIVE", 0x40087446 },
+{ "PPPIOCSPASS", 0x40087447 },
+{ "PPPIOCSNPMODE", 0x4008744b },
+{ "ASHMEM_PIN", 0x40087707 },
+{ "ASHMEM_UNPIN", 0x40087708 },
+{ "BTRFS_IOC_DEFAULT_SUBVOL", 0x40089413 },
+{ "BTRFS_IOC_WAIT_SYNC", 0x40089416 },
+{ "BTRFS_IOC_SUBVOL_SETFLAGS", 0x4008941a },
+{ "KVM_SET_IDENTITY_MAP_ADDR", 0x4008ae48 },
+{ "KVM_IRQ_LINE", 0x4008ae61 },
+{ "KVM_SET_GSI_ROUTING", 0x4008ae6a },
+{ "KVM_ASSIGN_SET_MSIX_NR", 0x4008ae73 },
+{ "KVM_SET_MSRS", 0x4008ae89 },
+{ "KVM_SET_CPUID", 0x4008ae8a },
+{ "KVM_SET_CPUID2", 0x4008ae90 },
+{ "KVM_SET_VAPIC_ADDR", 0x4008ae93 },
+{ "KVM_X86_SETUP_MCE", 0x4008ae9c },
+{ "VHOST_SET_FEATURES", 0x4008af00 },
+{ "VHOST_SET_MEM_TABLE", 0x4008af03 },
+{ "VHOST_SET_LOG_BASE", 0x4008af04 },
+{ "VHOST_SET_VRING_NUM", 0x4008af10 },
+{ "VHOST_SET_VRING_BASE", 0x4008af12 },
+{ "VHOST_SET_VRING_ENDIAN", 0x4008af13 },
+{ "VHOST_GET_VRING_ENDIAN", 0x4008af14 },
+{ "VHOST_SET_VRING_KICK", 0x4008af20 },
+{ "VHOST_SET_VRING_CALL", 0x4008af21 },
+{ "VHOST_SET_VRING_ERR", 0x4008af22 },
+{ "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", 0x4008af23 },
+{ "VHOST_GET_VRING_BUSYLOOP_TIMEOUT", 0x4008af24 },
+{ "VHOST_NET_SET_BACKEND", 0x4008af30 },
+{ "SNDRV_DM_FM_IOCTL_SET_PARAMS", 0x40094824 },
+{ "FDFMTTRK", 0x400c0248 },
+{ "RUN_ARRAY", 0x400c0930 },
+{ "SNAPSHOT_SET_SWAP_AREA", 0x400c330d },
+{ "SNDRV_PCM_IOCTL_WRITEI_FRAMES", 0x400c4150 },
+{ "SNDRV_PCM_IOCTL_WRITEN_FRAMES", 0x400c4152 },
+{ "CAPI_REGISTER", 0x400c4301 },
+{ "HIDIOCGREPORT", 0x400c4807 },
+{ "HIDIOCSREPORT", 0x400c4808 },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_POKE", 0x400c4821 },
+{ "SNDRV_DM_FM_IOCTL_PLAY_NOTE", 0x400c4822 },
+{ "MFB_SET_CHROMA_KEY", 0x400c4d01 },
+{ "OTPGETREGIONINFO", 0x400c4d0f },
+{ "UI_END_FF_ERASE", 0x400c55cb },
+{ "IVTVFB_IOC_DMA_FRAME", 0x400c56c0 },
+{ "IDT77105_GETSTAT", 0x400c6132 },
+{ "IDT77105_GETSTATZ", 0x400c6133 },
+{ "ATM_GETSTAT", 0x400c6150 },
+{ "ATM_GETSTATZ", 0x400c6151 },
+{ "ATM_GETLOOP", 0x400c6152 },
+{ "ATM_SETLOOP", 0x400c6153 },
+{ "ATM_QUERYLOOP", 0x400c6154 },
+{ "ENI_MEMDUMP", 0x400c6160 },
+{ "HE_GET_REG", 0x400c6160 },
+{ "ZATM_GETPOOL", 0x400c6161 },
+{ "NS_SETBUFLEV", 0x400c6162 },
+{ "ZATM_GETPOOLZ", 0x400c6162 },
+{ "ZATM_SETPOOL", 0x400c6163 },
+{ "ENI_SETMULT", 0x400c6167 },
+{ "ATM_GETLINKRATE", 0x400c6181 },
+{ "ATM_GETTYPE", 0x400c6184 },
+{ "ATM_GETESI", 0x400c6185 },
+{ "ATM_GETADDR", 0x400c6186 },
+{ "ATM_RSTADDR", 0x400c6187 },
+{ "ATM_ADDADDR", 0x400c6188 },
+{ "ATM_DELADDR", 0x400c6189 },
+{ "ATM_GETCIRANGE", 0x400c618a },
+{ "ATM_SETCIRANGE", 0x400c618b },
+{ "ATM_SETESI", 0x400c618c },
+{ "ATM_SETESIF", 0x400c618d },
+{ "ATM_ADDLECSADDR", 0x400c618e },
+{ "ATM_DELLECSADDR", 0x400c618f },
+{ "ATM_GETLECSADDR", 0x400c6190 },
+{ "CHIOPOSITION", 0x400c6303 },
+{ "BC_REQUEST_DEATH_NOTIFICATION", 0x400c630e },
+{ "BC_CLEAR_DEATH_NOTIFICATION", 0x400c630f },
+{ "DRM_IOCTL_I810_VERTEX", 0x400c6441 },
+{ "DRM_IOCTL_I810_CLEAR", 0x400c6442 },
+{ "DRM_IOCTL_MGA_VERTEX", 0x400c6445 },
+{ "DRM_IOCTL_I810_COPY", 0x400c6447 },
+{ "DRM_IOCTL_MGA_ILOAD", 0x400c6447 },
+{ "DRM_IOCTL_I915_INIT_HEAP", 0x400c644a },
+{ "DRM_IOCTL_RADEON_INIT_HEAP", 0x400c6455 },
+{ "DRM_IOCTL_RADEON_SURF_ALLOC", 0x400c645a },
+{ "DRM_IOCTL_I915_GEM_SET_DOMAIN", 0x400c645f },
+{ "FS_IOC_GET_ENCRYPTION_POLICY", 0x400c6615 },
+{ "I2OEVTREG", 0x400c690a },
+{ "HSC_SET_RX", 0x400c6b13 },
+{ "HSC_GET_RX", 0x400c6b14 },
+{ "NCP_IOC_GETROOT", 0x400c6e08 },
+{ "UBI_IOCRSVOL", 0x400c6f02 },
+{ "AUDIO_SET_KARAOKE", 0x400c6f12 },
+{ "PPPIOCSCOMPRESS", 0x400c744d },
+{ "KVM_CREATE_SPAPR_TCE", 0x400caea8 },
+{ "MBXFB_IOCS_REG", 0x400cf404 },
+{ "FW_CDEV_IOC_START_ISO", 0x4010230a },
+{ "FW_CDEV_IOC_SET_ISO_CHANNELS", 0x40102317 },
+{ "PTP_EXTTS_REQUEST", 0x40103d02 },
+{ "CCISS_SETNODENAME", 0x40104205 },
+{ "EVIOCSMASK", 0x40104593 },
+{ "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", 0x40104890 },
+{ "AMDKFD_IOC_DBG_ADDRESS_WATCH", 0x40104b0f },
+{ "AMDKFD_IOC_DBG_WAVE_CONTROL", 0x40104b10 },
+{ "MTRRIOC_ADD_ENTRY", 0x40104d00 },
+{ "MTRRIOC_SET_ENTRY", 0x40104d01 },
+{ "MTRRIOC_DEL_ENTRY", 0x40104d02 },
+{ "MTRRIOC_KILL_ENTRY", 0x40104d04 },
+{ "MTRRIOC_ADD_PAGE_ENTRY", 0x40104d05 },
+{ "MTRRIOC_SET_PAGE_ENTRY", 0x40104d06 },
+{ "MTRRIOC_DEL_PAGE_ENTRY", 0x40104d07 },
+{ "MTRRIOC_KILL_PAGE_ENTRY", 0x40104d09 },
+{ "MEMERASE64", 0x40104d14 },
+{ "UBI_IOCSETVOLPROP", 0x40104f06 },
+{ "OMAPFB_SET_COLOR_KEY", 0x40104f32 },
+{ "OMAPFB_GET_COLOR_KEY", 0x40104f33 },
+{ "BC_INCREFS_DONE", 0x40106308 },
+{ "BC_ACQUIRE_DONE", 0x40106309 },
+{ "DRM_IOCTL_SET_CLIENT_CAP", 0x4010640d },
+{ "DRM_IOCTL_AGP_FREE", 0x40106435 },
+{ "DRM_IOCTL_OMAP_SET_PARAM", 0x40106441 },
+{ "DRM_IOCTL_QXL_EXECBUFFER", 0x40106442 },
+{ "DRM_IOCTL_OMAP_GEM_CPU_FINI", 0x40106445 },
+{ "DRM_IOCTL_SIS_FB_FREE", 0x40106445 },
+{ "DRM_IOCTL_VIA_DEC_FUTEX", 0x40106445 },
+{ "DRM_IOCTL_MGA_INDICES", 0x40106446 },
+{ "DRM_IOCTL_R128_VERTEX", 0x40106449 },
+{ "DRM_IOCTL_RADEON_VERTEX", 0x40106449 },
+{ "DRM_IOCTL_RADEON_CMDBUF", 0x40106450 },
+{ "DRM_IOCTL_I915_HWS_ADDR", 0x40106451 },
+{ "DRM_IOCTL_I915_GEM_INIT", 0x40106453 },
+{ "DRM_IOCTL_SIS_AGP_FREE", 0x40106455 },
+{ "DRM_IOCTL_RADEON_SETPARAM", 0x40106459 },
+{ "FS_IOC_GET_ENCRYPTION_PWSALT", 0x40106614 },
+{ "HSC_SET_TX", 0x40106b15 },
+{ "HSC_GET_TX", 0x40106b16 },
+{ "RIO_ENABLE_PORTWRITE_RANGE", 0x40106d0b },
+{ "RIO_DISABLE_PORTWRITE_RANGE", 0x40106d0c },
+{ "MGSL_IOCSGPIO", 0x40106d10 },
+{ "NILFS_IOCTL_CHANGE_CPMODE", 0x40106e80 },
+{ "NILFS_IOCTL_SET_ALLOC_RANGE", 0x40106e8c },
+{ "VIDEO_SET_HIGHLIGHT", 0x40106f27 },
+{ "CA_SET_DESCR", 0x40106f86 },
+{ "PPSETTIME", 0x40107096 },
+{ "IOC_PR_RESERVE", 0x401070c9 },
+{ "IOC_PR_RELEASE", 0x401070ca },
+{ "IOC_PR_CLEAR", 0x401070cd },
+{ "BTRFS_IOC_QGROUP_CREATE", 0x4010942a },
+{ "GENWQE_WRITE_REG64", 0x4010a51f },
+{ "GENWQE_WRITE_REG32", 0x4010a521 },
+{ "GENWQE_WRITE_REG16", 0x4010a523 },
+{ "KVM_GET_DIRTY_LOG", 0x4010ae42 },
+{ "KVM_REGISTER_COALESCED_MMIO", 0x4010ae67 },
+{ "KVM_UNREGISTER_COALESCED_MMIO", 0x4010ae68 },
+{ "KVM_ASSIGN_SET_MSIX_ENTRY", 0x4010ae74 },
+{ "KVM_S390_INTERRUPT", 0x4010ae94 },
+{ "KVM_S390_SET_INITIAL_PSW", 0x4010ae96 },
+{ "KVM_DIRTY_TLB", 0x4010aeaa },
+{ "KVM_ARM_SET_DEVICE_ADDR", 0x4010aeab },
+{ "KVM_GET_ONE_REG", 0x4010aeab },
+{ "KVM_SET_ONE_REG", 0x4010aeac },
+{ "SNDRV_DM_FM_IOCTL_SET_VOICE", 0x40124823 },
+{ "FDSETMAXERRS", 0x4014024c },
+{ "ADD_NEW_DISK", 0x40140921 },
+{ "SNDCTL_COPR_WDATA", 0x40144304 },
+{ "SNDCTL_COPR_WCODE", 0x40144305 },
+{ "OMAPFB_UPDATE_WINDOW_OLD", 0x40144f2f },
+{ "VIDIOC_S_CROP", 0x4014563c },
+{ "CHIOMOVE", 0x40146301 },
+{ "DRM_IOCTL_VIA_FREEMEM", 0x40146441 },
+{ "DRM_IOCTL_MGA_CLEAR", 0x40146444 },
+{ "DRM_IOCTL_R128_CLEAR", 0x40146448 },
+{ "DRM_IOCTL_R128_INDICES", 0x4014644a },
+{ "DRM_IOCTL_RADEON_INDICES", 0x4014644a },
+{ "DRM_IOCTL_I810_MC", 0x4014644c },
+{ "DMX_SET_PES_FILTER", 0x40146f2c },
+{ "FW_CDEV_IOC_SEND_RESPONSE", 0x40182304 },
+{ "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", 0x4018230f },
+{ "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", 0x40182310 },
+{ "HIDIOCSUSAGE", 0x4018480c },
+{ "HIDIOCGCOLLECTIONINDEX", 0x40184810 },
+{ "AMDKFD_IOC_UPDATE_QUEUE", 0x40184b07 },
+{ "DRM_IOCTL_MARK_BUFS", 0x40186417 },
+{ "DRM_IOCTL_RM_MAP", 0x4018641b },
+{ "DRM_IOCTL_UPDATE_DRAW", 0x4018643f },
+{ "DRM_IOCTL_I915_BATCHBUFFER", 0x40186443 },
+{ "DRM_IOCTL_QXL_UPDATE_AREA", 0x40186443 },
+{ "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", 0x40186444 },
+{ "DRM_IOCTL_MSM_GEM_CPU_PREP", 0x40186444 },
+{ "DRM_IOCTL_MSM_WAIT_FENCE", 0x40186447 },
+{ "DRM_IOCTL_RADEON_CLEAR", 0x40186448 },
+{ "DRM_IOCTL_I915_CMDBUFFER", 0x4018644b },
+{ "DRM_IOCTL_R128_BLIT", 0x4018644b },
+{ "DRM_IOCTL_R128_DEPTH", 0x4018644c },
+{ "DRM_IOCTL_RADEON_VERTEX2", 0x4018644f },
+{ "RIO_MPORT_MAINT_WRITE_LOCAL", 0x40186d06 },
+{ "RIO_MPORT_MAINT_WRITE_REMOTE", 0x40186d08 },
+{ "NILFS_IOCTL_SET_SUINFO", 0x40186e8d },
+{ "UBI_IOCATT", 0x40186f40 },
+{ "IOC_PR_REGISTER", 0x401870c8 },
+{ "IOC_PR_PREEMPT", 0x401870cb },
+{ "IOC_PR_PREEMPT_ABORT", 0x401870cc },
+{ "BTRFS_IOC_QGROUP_ASSIGN", 0x40189429 },
+{ "KVM_SET_MEMORY_REGION", 0x4018ae40 },
+{ "KVM_S390_UCAS_MAP", 0x4018ae50 },
+{ "KVM_S390_UCAS_UNMAP", 0x4018ae51 },
+{ "KVM_SET_DEVICE_ATTR", 0x4018aee1 },
+{ "KVM_GET_DEVICE_ATTR", 0x4018aee2 },
+{ "KVM_HAS_DEVICE_ATTR", 0x4018aee3 },
+{ "MBXFB_IOCS_ALPHA", 0x4018f402 },
+{ "FDSETPRM", 0x401c0242 },
+{ "FDDEFPRM", 0x401c0243 },
+{ "UI_ABS_SETUP", 0x401c5504 },
+{ "FS_IOC_FSSETXATTR", 0x401c5820 },
+{ "BR2684_SETFILT", 0x401c6190 },
+{ "CHIOEXCHANGE", 0x401c6302 },
+{ "OSD_SEND_CMD", 0x401c6fa0 },
+{ "RTC_PLL_SET", 0x401c7012 },
+{ "CS_CONFIG_BUFS", 0x4020431f },
+{ "ION_IOC_TEST_DMA_MAPPING", 0x402049f1 },
+{ "ION_IOC_TEST_KERNEL_MAPPING", 0x402049f2 },
+{ "AMDKFD_IOC_SET_MEMORY_POLICY", 0x40204b04 },
+{ "VIDIOC_SUBSCRIBE_EVENT", 0x4020565a },
+{ "VIDIOC_UNSUBSCRIBE_EVENT", 0x4020565b },
+{ "DRM_IOCTL_VIRTGPU_EXECBUFFER", 0x40206442 },
+{ "DRM_IOCTL_AMDGPU_INFO", 0x40206445 },
+{ "DRM_IOCTL_ETNAVIV_WAIT_FENCE", 0x40206447 },
+{ "DRM_IOCTL_ETNAVIV_GEM_WAIT", 0x40206449 },
+{ "DRM_IOCTL_I915_GEM_PREAD", 0x4020645c },
+{ "DRM_IOCTL_I915_GEM_PWRITE", 0x4020645d },
+{ "MGSL_IOCSPARAMS", 0x40206d00 },
+{ "RIO_DEV_ADD", 0x40206d17 },
+{ "RIO_DEV_DEL", 0x40206d18 },
+{ "PPPIOCSXASYNCMAP", 0x4020744f },
+{ "BTRFS_IOC_CLONE_RANGE", 0x4020940d },
+{ "FICLONERANGE", 0x4020940d },
+{ "KVM_SET_MEMORY_ALIAS", 0x4020ae43 },
+{ "KVM_SET_USER_MEMORY_REGION", 0x4020ae46 },
+{ "KVM_IRQFD", 0x4020ae76 },
+{ "KVM_SIGNAL_MSI", 0x4020aea5 },
+{ "KVM_CREATE_SPAPR_TCE_64", 0x4020aea8 },
+{ "KVM_PPC_GET_HTAB_FD", 0x4020aeaa },
+{ "KVM_ARM_VCPU_INIT", 0x4020aeae },
+{ "KVM_S390_SET_IRQ_STATE", 0x4020aeb5 },
+{ "KVM_S390_GET_IRQ_STATE", 0x4020aeb6 },
+{ "SNDRV_COMPRESS_SET_METADATA", 0x40244314 },
+{ "NVM_DEV_REMOVE", 0x40244c23 },
+{ "NVM_DEV_FACTORY", 0x40244c25 },
+{ "DRM_IOCTL_SAVAGE_BCI_CMDBUF", 0x40246441 },
+{ "JSIOCSCORR", 0x40246a21 },
+{ "FE_SET_FRONTEND", 0x40246f4c },
+{ "RTC_ALM_SET", 0x40247007 },
+{ "RTC_SET_TIME", 0x4024700a },
+{ "HFI1_IOCTL_CTXT_INFO", 0x40281be2 },
+{ "FW_CDEV_IOC_SEND_REQUEST", 0x40282301 },
+{ "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", 0x40282312 },
+{ "FW_CDEV_IOC_SEND_STREAM_PACKET", 0x40282313 },
+{ "EVIOCSKEYCODE_V2", 0x40284504 },
+{ "SNDCTL_FM_LOAD_INSTR", 0x40285107 },
+{ "DRM_IOCTL_AMDGPU_GEM_VA", 0x40286448 },
+{ "DRM_IOCTL_VIA_DMA_BLIT", 0x4028644e },
+{ "DRM_IOCTL_I915_GEM_EXECBUFFER", 0x40286454 },
+{ "RIO_UNMAP_OUTBOUND", 0x40286d10 },
+{ "PHN_SETREGS", 0x40287008 },
+{ "RTC_WKALM_SET", 0x4028700f },
+{ "VHOST_SET_VRING_ADDR", 0x4028af11 },
+{ "EVIOCSFF", 0x402c4580 },
+{ "NVM_DEV_INIT", 0x402c4c24 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", 0x402c5342 },
+{ "TCSETS2", 0x402c542b },
+{ "TCSETSW2", 0x402c542c },
+{ "TCSETSF2", 0x402c542d },
+{ "VIDIOC_S_FBUF", 0x402c560b },
+{ "VIDIOC_S_FREQUENCY", 0x402c5639 },
+{ "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", 0x402c6467 },
+{ "NVME_IOCTL_SUBMIT_IO", 0x40304e42 },
+{ "VIDIOC_S_HW_FREQ_SEEK", 0x40305652 },
+{ "CHIOSVOLTAG", 0x40306312 },
+{ "BTRFS_IOC_DEFRAG_RANGE", 0x40309410 },
+{ "BTRFS_IOC_SET_FEATURES", 0x40309439 },
+{ "KVM_SET_CLOCK", 0x4030ae7b },
+{ "GSMIOC_ENABLE_NET", 0x40344702 },
+{ "SNDRV_TIMER_IOCTL_SELECT", 0x40345410 },
+{ "VIDIOC_S_AUDIO", 0x40345622 },
+{ "VIDIOC_S_AUDOUT", 0x40345632 },
+{ "DRM_IOCTL_MGA_BLIT", 0x40346448 },
+{ "PTP_PEROUT_REQUEST", 0x40383d03 },
+{ "VIDIOC_DBG_S_REGISTER", 0x4038564f },
+{ "IVTV_IOC_DMA_FRAME", 0x403856c0 },
+{ "KVM_XEN_HVM_CONFIG", 0x4038ae7a },
+{ "SNDRV_TIMER_IOCTL_GPARAMS", 0x403c5404 },
+{ "DMX_SET_FILTER", 0x403c6f2b },
+{ "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", 0x4040534e },
+{ "SNDRV_CTL_IOCTL_ELEM_LOCK", 0x40405514 },
+{ "SNDRV_CTL_IOCTL_ELEM_UNLOCK", 0x40405515 },
+{ "BC_TRANSACTION", 0x40406300 },
+{ "BC_REPLY", 0x40406301 },
+{ "DRM_IOCTL_I810_INIT", 0x40406440 },
+{ "DRM_IOCTL_I915_GEM_EXECBUFFER2", 0x40406469 },
+{ "JSIOCSAXMAP", 0x40406a31 },
+{ "BTRFS_IOC_QUOTA_RESCAN", 0x4040942c },
+{ "KVM_ASSIGN_DEV_IRQ", 0x4040ae70 },
+{ "KVM_DEASSIGN_PCI_DEVICE", 0x4040ae72 },
+{ "KVM_DEASSIGN_DEV_IRQ", 0x4040ae75 },
+{ "KVM_CREATE_PIT2", 0x4040ae77 },
+{ "KVM_IOEVENTFD", 0x4040ae79 },
+{ "KVM_X86_SET_MCE", 0x4040ae9e },
+{ "KVM_SET_VCPU_EVENTS", 0x4040aea0 },
+{ "KVM_ASSIGN_SET_INTX_MASK", 0x4040aea4 },
+{ "KVM_S390_MEM_OP", 0x4040aeb1 },
+{ "KVM_S390_GET_SKEYS", 0x4040aeb2 },
+{ "KVM_S390_SET_SKEYS", 0x4040aeb3 },
+{ "CXL_IOCTL_START_WORK", 0x4040ca00 },
+{ "CXL_IOCTL_DOWNLOAD_IMAGE", 0x4040ca0a },
+{ "CXL_IOCTL_VALIDATE_IMAGE", 0x4040ca0b },
+{ "OMAPFB_SETUP_PLANE", 0x40444f34 },
+{ "OMAPFB_QUERY_PLANE", 0x40444f35 },
+{ "OMAPFB_UPDATE_WINDOW", 0x40444f36 },
+{ "VIDIOC_S_MODULATOR", 0x40445637 },
+{ "DRM_IOCTL_I915_INIT", 0x40446440 },
+{ "SET_ARRAY_INFO", 0x40480923 },
+{ "SNDRV_EMU10K1_IOCTL_PCM_POKE", 0x40484830 },
+{ "BTRFS_IOC_SEND", 0x40489426 },
+{ "KVM_SET_GUEST_DEBUG", 0x4048ae9b },
+{ "KVM_S390_IRQ", 0x4048aeb4 },
+{ "GSMIOC_SETCONF", 0x404c4701 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", 0x404c534a },
+{ "SNDRV_HWDEP_IOCTL_DSP_LOAD", 0x40504803 },
+{ "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", 0x40505330 },
+{ "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", 0x40505331 },
+{ "SNDRV_TIMER_IOCTL_PARAMS", 0x40505412 },
+{ "DRM_IOCTL_SAVAGE_BCI_INIT", 0x40506440 },
+{ "VIDIOC_S_TUNER", 0x4054561e },
+{ "DRM_IOCTL_RADEON_CP_INIT", 0x40546440 },
+{ "FDSETDRVPRM", 0x40580290 },
+{ "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", 0x4058534c },
+{ "DRM_IOCTL_R128_INIT", 0x40586440 },
+{ "UI_DEV_SETUP", 0x405c5503 },
+{ "DRM_IOCTL_MGA_INIT", 0x405c6440 },
+{ "PTP_PIN_SETFUNC", 0x40603d07 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", 0x40605346 },
+{ "UI_END_FF_UPLOAD", 0x406055c9 },
+{ "KVM_ENABLE_CAP", 0x4068aea3 },
+{ "CHIOGELEM", 0x406c6310 },
+{ "KVM_SET_PIT2", 0x4070aea0 },
+{ "HFI1_IOCTL_USER_INFO", 0x40781be3 },
+{ "NILFS_IOCTL_CLEAN_SEGMENTS", 0x40786e88 },
+{ "NVM_DEV_CREATE", 0x40804c22 },
+{ "UBI_IOCVOLCRBLK", 0x40804f07 },
+{ "KVM_PPC_GET_PVINFO", 0x4080aea1 },
+{ "KVM_SET_DEBUGREGS", 0x4080aea2 },
+{ "KVM_PPC_RTAS_DEFINE_TOKEN", 0x4080aeac },
+{ "SNDRV_COMPRESS_SET_PARAMS", 0x40844312 },
+{ "V4L2_DEVICE_NOTIFY_EVENT", 0x40887602 },
+{ "SNDRV_SEQ_IOCTL_DELETE_QUEUE", 0x408c5333 },
+{ "VIDIOC_S_JPEGCOMP", 0x408c563e },
+{ "KVM_SET_REGS", 0x4090ae82 },
+{ "UBI_IOCMKVOL", 0x40986f00 },
+{ "SNDRV_SEQ_IOCTL_DELETE_PORT", 0x40a45321 },
+{ "SNDRV_SEQ_IOCTL_SET_PORT_INFO", 0x40a45323 },
+{ "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", 0x40bc5311 },
+{ "VHOST_SCSI_SET_ENDPOINT", 0x40e8af40 },
+{ "VHOST_SCSI_CLEAR_ENDPOINT", 0x40e8af41 },
+{ "ASHMEM_SET_NAME", 0x41007701 },
+{ "BTRFS_IOC_SET_FSLABEL", 0x41009432 },
+{ "USBDEVFS_GETDRIVER", 0x41045508 },
+{ "CA_SEND_MSG", 0x410c6f85 },
+{ "KVM_SET_SREGS", 0x4138ae84 },
+{ "KVM_SET_XCRS", 0x4188aea7 },
+{ "SNDRV_EMU10K1_IOCTL_CODE_POKE", 0x418c4811 },
+{ "KVM_SET_FPU", 0x41a0ae8d },
+{ "PTP_SYS_OFFSET", 0x43403d05 },
+{ "JSIOCSBTNMAP", 0x44006a33 },
+{ "KVM_SET_LAPIC", 0x4400ae8f },
+{ "BTRFS_IOC_SNAP_CREATE", 0x50009401 },
+{ "BTRFS_IOC_DEFRAG", 0x50009402 },
+{ "BTRFS_IOC_RESIZE", 0x50009403 },
+{ "BTRFS_IOC_SCAN_DEV", 0x50009404 },
+{ "BTRFS_IOC_ADD_DEV", 0x5000940a },
+{ "BTRFS_IOC_RM_DEV", 0x5000940b },
+{ "BTRFS_IOC_BALANCE", 0x5000940c },
+{ "BTRFS_IOC_SUBVOL_CREATE", 0x5000940e },
+{ "BTRFS_IOC_SNAP_DESTROY", 0x5000940f },
+{ "BTRFS_IOC_SNAP_CREATE_V2", 0x50009417 },
+{ "BTRFS_IOC_SUBVOL_CREATE_V2", 0x50009418 },
+{ "BTRFS_IOC_RM_DEV_V2", 0x5000943a },
+{ "KVM_SET_XSAVE", 0x5000aea5 },
+{ "HIDIOCSUSAGES", 0x501c4814 },
+{ "UBI_IOCRNVOL", 0x51106f03 },
+{ "SNDRV_SB_CSP_IOCTL_LOAD_CODE", 0x70124811 },
+{ "MFB_GET_ALPHA", 0x80014d00 },
+{ "MFB_GET_GAMMA", 0x80014d01 },
+{ "USBTMC488_IOCTL_GET_CAPS", 0x80015b11 },
+{ "USBTMC488_IOCTL_READ_STB", 0x80015b12 },
+{ "GADGET_GET_PRINTER_STATUS", 0x80016721 },
+{ "JSIOCGAXES", 0x80016a11 },
+{ "JSIOCGBUTTONS", 0x80016a12 },
+{ "SPI_IOC_RD_MODE", 0x80016b01 },
+{ "SPI_IOC_RD_LSB_FIRST", 0x80016b02 },
+{ "SPI_IOC_RD_BITS_PER_WORD", 0x80016b03 },
+{ "PPRSTATUS", 0x80017081 },
+{ "PPRCONTROL", 0x80017083 },
+{ "PPRDATA", 0x80017085 },
+{ "SONYPI_IOCGBRT", 0x80017600 },
+{ "SONYPI_IOCGBATFLAGS", 0x80017607 },
+{ "SONYPI_IOCGBLUE", 0x80017608 },
+{ "SONYPI_IOCGFAN", 0x8001760a },
+{ "SONYPI_IOCGTEMP", 0x8001760c },
+{ "CAPI_GET_ERRCODE", 0x80024321 },
+{ "CAPI_INSTALLED", 0x80024322 },
+{ "SNDRV_DM_FM_IOCTL_INFO", 0x80024820 },
+{ "IOCTL_WDM_MAX_COMMAND", 0x800248a0 },
+{ "IPMICTL_REGISTER_FOR_CMD", 0x8002690e },
+{ "IPMICTL_UNREGISTER_FOR_CMD", 0x8002690f },
+{ "FE_READ_SIGNAL_STRENGTH", 0x80026f47 },
+{ "FE_READ_SNR", 0x80026f48 },
+{ "SONYPI_IOCGBAT1CAP", 0x80027602 },
+{ "SONYPI_IOCGBAT1REM", 0x80027603 },
+{ "SONYPI_IOCGBAT2CAP", 0x80027604 },
+{ "SONYPI_IOCGBAT2REM", 0x80027605 },
+{ "MBXFB_IOCS_PLANEORDER", 0x8002f403 },
+{ "BLKBSZGET", 0x80041270 },
+{ "BLKGETSIZE64", 0x80041272 },
+{ "HFI1_IOCTL_GET_VERS", 0x80041bee },
+{ "PERF_EVENT_IOC_ID", 0x80042407 },
+{ "FBIO_RADEON_GET_MIRROR", 0x80044003 },
+{ "AGPIOC_INFO", 0x80044100 },
+{ "SNDRV_PCM_IOCTL_PVERSION", 0x80044100 },
+{ "SNDRV_PCM_IOCTL_DELAY", 0x80044121 },
+{ "PMU_IOC_GET_BACKLIGHT", 0x80044201 },
+{ "PMU_IOC_GET_MODEL", 0x80044203 },
+{ "PMU_IOC_HAS_ADB", 0x80044204 },
+{ "PMU_IOC_CAN_SLEEP", 0x80044205 },
+{ "CCISS_GETHEARTBEAT", 0x80044206 },
+{ "PMU_IOC_GRAB_BACKLIGHT", 0x80044206 },
+{ "CCISS_GETBUSTYPES", 0x80044207 },
+{ "CCISS_GETFIRMVER", 0x80044208 },
+{ "CCISS_GETDRIVVER", 0x80044209 },
+{ "SNDRV_COMPRESS_IOCTL_VERSION", 0x80044300 },
+{ "CS_GET_STATE", 0x80044315 },
+{ "CS_GET_IF_VERSION", 0x8004431e },
+{ "CAPI_GET_FLAGS", 0x80044323 },
+{ "CAPI_SET_FLAGS", 0x80044324 },
+{ "CAPI_CLR_FLAGS", 0x80044325 },
+{ "CAPI_NCCI_OPENCOUNT", 0x80044326 },
+{ "CAPI_NCCI_GETUNIT", 0x80044327 },
+{ "EVIOCGVERSION", 0x80044501 },
+{ "APEI_ERST_GET_RECORD_COUNT", 0x80044502 },
+{ "EVIOCGEFFECTS", 0x80044584 },
+{ "FBIOGET_CONTRAST", 0x80044601 },
+{ "FBIGET_BRIGHTNESS", 0x80044603 },
+{ "FBIGET_COLOR", 0x80044605 },
+{ "FBIO_GETCONTROL2", 0x80044689 },
+{ "SSTFB_GET_VGAPASS", 0x800446dd },
+{ "SNDRV_HWDEP_IOCTL_PVERSION", 0x80044800 },
+{ "HIDIOCGRDESCSIZE", 0x80044801 },
+{ "HIDIOCGVERSION", 0x80044801 },
+{ "IOCTL_MEI_NOTIFY_GET", 0x80044803 },
+{ "HIDIOCGFLAG", 0x8004480e },
+{ "HDA_IOCTL_PVERSION", 0x80044810 },
+{ "SNDRV_EMU10K1_IOCTL_PVERSION", 0x80044840 },
+{ "SNDRV_HDSPM_IOCTL_GET_MIXER", 0x80044844 },
+{ "SNDRV_EMUX_IOCTL_VERSION", 0x80044880 },
+{ "SNDRV_EMU10K1_IOCTL_DBG_READ", 0x80044884 },
+{ "HCIGETDEVLIST", 0x800448d2 },
+{ "HCIGETDEVINFO", 0x800448d3 },
+{ "HCIGETCONNLIST", 0x800448d4 },
+{ "HCIGETCONNINFO", 0x800448d5 },
+{ "HCIGETAUTHINFO", 0x800448d7 },
+{ "HCIINQUIRY", 0x800448f0 },
+{ "ROCCATIOCGREPSIZE", 0x800448f1 },
+{ "IMADDTIMER", 0x80044940 },
+{ "IMDELTIMER", 0x80044941 },
+{ "IMGETVERSION", 0x80044942 },
+{ "IMGETCOUNT", 0x80044943 },
+{ "IMGETDEVINFO", 0x80044944 },
+{ "IMCTRLREQ", 0x80044945 },
+{ "IMCLEAR_L2", 0x80044946 },
+{ "IMHOLD_L1", 0x80044948 },
+{ "MCE_GET_RECORD_LEN", 0x80044d01 },
+{ "MCE_GET_LOG_LEN", 0x80044d02 },
+{ "MCE_GETCLEAR_FLAGS", 0x80044d03 },
+{ "MEMGETREGIONCOUNT", 0x80044d07 },
+{ "MFB_GET_PIXFMT", 0x80044d08 },
+{ "OTPSELECT", 0x80044d0d },
+{ "OSS_GETVERSION", 0x80044d76 },
+{ "UBI_IOCEBISMAP", 0x80044f05 },
+{ "SOUND_PCM_READ_RATE", 0x80045002 },
+{ "SOUND_PCM_READ_BITS", 0x80045005 },
+{ "SOUND_PCM_READ_CHANNELS", 0x80045006 },
+{ "SOUND_PCM_READ_FILTER", 0x80045007 },
+{ "SNDCTL_DSP_GETFMTS", 0x8004500b },
+{ "SNDCTL_DSP_GETCAPS", 0x8004500f },
+{ "SNDCTL_DSP_GETTRIGGER", 0x80045010 },
+{ "SNDCTL_DSP_GETODELAY", 0x80045017 },
+{ "SNDCTL_DSP_GETSPDIF", 0x80045043 },
+{ "SNDCTL_SEQ_GETOUTCOUNT", 0x80045104 },
+{ "SNDCTL_SEQ_GETINCOUNT", 0x80045105 },
+{ "SNDCTL_SEQ_NRSYNTHS", 0x8004510a },
+{ "SNDCTL_SEQ_NRMIDIS", 0x8004510b },
+{ "SNDCTL_SEQ_GETTIME", 0x80045113 },
+{ "RNDGETENTCNT", 0x80045200 },
+{ "SAA6588_CMD_READ", 0x80045203 },
+{ "SAA6588_CMD_POLL", 0x80045204 },
+{ "RFCOMMGETDEVLIST", 0x800452d2 },
+{ "RFCOMMGETDEVINFO", 0x800452d3 },
+{ "SNDRV_SEQ_IOCTL_PVERSION", 0x80045300 },
+{ "SNDRV_SEQ_IOCTL_CLIENT_ID", 0x80045301 },
+{ "SNDRV_TIMER_IOCTL_PVERSION", 0x80045400 },
+{ "TIOCGPTN", 0x80045430 },
+{ "TIOCGDEV", 0x80045432 },
+{ "TIOCGPKT", 0x80045438 },
+{ "TIOCGPTLCK", 0x80045439 },
+{ "TIOCGEXCL", 0x80045440 },
+{ "TUNGETFEATURES", 0x800454cf },
+{ "TUNGETIFF", 0x800454d2 },
+{ "TUNGETSNDBUF", 0x800454d3 },
+{ "TUNGETVNETHDRSZ", 0x800454d7 },
+{ "TUNGETVNETLE", 0x800454dd },
+{ "TUNGETVNETBE", 0x800454df },
+{ "SNDRV_CTL_IOCTL_PVERSION", 0x80045500 },
+{ "USBDEVFS_RESETEP", 0x80045503 },
+{ "USBDEVFS_SETCONFIGURATION", 0x80045505 },
+{ "USBDEVFS_CLAIMINTERFACE", 0x8004550f },
+{ "USBDEVFS_RELEASEINTERFACE", 0x80045510 },
+{ "USBDEVFS_CLEAR_HALT", 0x80045515 },
+{ "USBDEVFS_CLAIM_PORT", 0x80045518 },
+{ "USBDEVFS_RELEASE_PORT", 0x80045519 },
+{ "USBDEVFS_GET_CAPABILITIES", 0x8004551a },
+{ "UI_GET_VERSION", 0x8004552d },
+{ "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", 0x80045530 },
+{ "SNDRV_CTL_IOCTL_POWER_STATE", 0x800455d1 },
+{ "VIDIOC_G_INPUT", 0x80045626 },
+{ "VIDIOC_G_OUTPUT", 0x8004562e },
+{ "VIDIOC_G_PRIORITY", 0x80045643 },
+{ "SNDRV_RAWMIDI_IOCTL_PVERSION", 0x80045700 },
+{ "WDIOC_GETSTATUS", 0x80045701 },
+{ "WDIOC_GETBOOTSTATUS", 0x80045702 },
+{ "WDIOC_GETTEMP", 0x80045703 },
+{ "WDIOC_SETOPTIONS", 0x80045704 },
+{ "WDIOC_KEEPALIVE", 0x80045705 },
+{ "WDIOC_GETTIMEOUT", 0x80045707 },
+{ "WDIOC_GETPRETIMEOUT", 0x80045709 },
+{ "WDIOC_GETTIMELEFT", 0x8004570a },
+{ "SONET_GETDIAG", 0x80046114 },
+{ "SONET_GETFRAMING", 0x80046116 },
+{ "CM_IOCGSTATUS", 0x80046300 },
+{ "KCOV_INIT_TRACE", 0x80046301 },
+{ "CHIOGPICKER", 0x80046304 },
+{ "DRM_IOCTL_GET_MAGIC", 0x80046402 },
+{ "DRM_IOCTL_I915_GET_VBLANK_PIPE", 0x8004644e },
+{ "FS_IOC32_GETFLAGS", 0x80046601 },
+{ "FS_IOC_GETFLAGS", 0x80046601 },
+{ "LIRC_GET_FEATURES", 0x80046900 },
+{ "LIRC_GET_SEND_MODE", 0x80046901 },
+{ "LIRC_GET_REC_MODE", 0x80046902 },
+{ "LIRC_GET_SEND_CARRIER", 0x80046903 },
+{ "LIRC_GET_REC_CARRIER", 0x80046904 },
+{ "LIRC_GET_SEND_DUTY_CYCLE", 0x80046905 },
+{ "LIRC_GET_REC_DUTY_CYCLE", 0x80046906 },
+{ "LIRC_GET_REC_RESOLUTION", 0x80046907 },
+{ "I2OVALIDATE", 0x80046908 },
+{ "LIRC_GET_MIN_TIMEOUT", 0x80046908 },
+{ "LIRC_GET_MAX_TIMEOUT", 0x80046909 },
+{ "LIRC_GET_MIN_FILTER_PULSE", 0x8004690a },
+{ "LIRC_GET_MAX_FILTER_PULSE", 0x8004690b },
+{ "LIRC_GET_MIN_FILTER_SPACE", 0x8004690c },
+{ "LIRC_GET_MAX_FILTER_SPACE", 0x8004690d },
+{ "LIRC_GET_LENGTH", 0x8004690f },
+{ "IPMICTL_SET_GETS_EVENTS_CMD", 0x80046910 },
+{ "IPMICTL_SET_MY_ADDRESS_CMD", 0x80046911 },
+{ "IPMICTL_GET_MY_ADDRESS_CMD", 0x80046912 },
+{ "IPMICTL_SET_MY_LUN_CMD", 0x80046913 },
+{ "IPMICTL_GET_MY_LUN_CMD", 0x80046914 },
+{ "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", 0x80046918 },
+{ "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", 0x80046919 },
+{ "IPMICTL_SET_MY_CHANNEL_LUN_CMD", 0x8004691a },
+{ "IPMICTL_GET_MY_CHANNEL_LUN_CMD", 0x8004691b },
+{ "IPMICTL_GET_MAINTENANCE_MODE_CMD", 0x8004691e },
+{ "I8K_BIOS_VERSION", 0x80046980 },
+{ "I8K_MACHINE_ID", 0x80046981 },
+{ "I8K_POWER_STATUS", 0x80046982 },
+{ "I8K_FN_STATUS", 0x80046983 },
+{ "I8K_GET_TEMP", 0x80046984 },
+{ "IIO_GET_EVENT_FD_IOCTL", 0x80046990 },
+{ "JSIOCGVERSION", 0x80046a01 },
+{ "SPI_IOC_RD_MAX_SPEED_HZ", 0x80046b04 },
+{ "SPI_IOC_RD_MODE32", 0x80046b05 },
+{ "UDF_GETEASIZE", 0x80046c40 },
+{ "UDF_GETEABLOCK", 0x80046c41 },
+{ "UDF_GETVOLIDENT", 0x80046c42 },
+{ "MMTIMER_GETRES", 0x80046d01 },
+{ "MMTIMER_GETFREQ", 0x80046d02 },
+{ "MTIOCPOS", 0x80046d03 },
+{ "RIO_MPORT_MAINT_PORT_IDX_GET", 0x80046d03 },
+{ "MMTIMER_GETCOUNTER", 0x80046d09 },
+{ "RIO_GET_EVENT_MASK", 0x80046d0e },
+{ "NCP_IOC_SIGN_WANTED", 0x80046e06 },
+{ "NCP_IOC_SETDENTRYTTL", 0x80046e0c },
+{ "MATROXFB_GET_OUTPUT_CONNECTION", 0x80046ef8 },
+{ "SISFB_GET_INFO_OLD", 0x80046ef8 },
+{ "MATROXFB_GET_AVAILABLE_OUTPUTS", 0x80046ef9 },
+{ "SISFB_GET_VBRSTATUS_OLD", 0x80046ef9 },
+{ "SISFB_GET_AUTOMAXIMIZE_OLD", 0x80046efa },
+{ "MATROXFB_GET_ALL_OUTPUTS", 0x80046efb },
+{ "AUDIO_GET_CAPABILITIES", 0x80046f0b },
+{ "VIDEO_GET_CAPABILITIES", 0x80046f21 },
+{ "VIDEO_GET_FRAME_RATE", 0x80046f38 },
+{ "FE_READ_STATUS", 0x80046f45 },
+{ "FE_READ_BER", 0x80046f46 },
+{ "FE_READ_UNCORRECTED_BLOCKS", 0x80046f49 },
+{ "RTC_IRQP_READ", 0x8004700b },
+{ "RTC_EPOCH_READ", 0x8004700d },
+{ "RTC_VL_READ", 0x80047013 },
+{ "PPCLRIRQ", 0x80047093 },
+{ "PPGETMODES", 0x80047097 },
+{ "PPGETMODE", 0x80047098 },
+{ "PPGETPHASE", 0x80047099 },
+{ "PPGETFLAGS", 0x8004709a },
+{ "PPS_GETPARAMS", 0x800470a1 },
+{ "PPS_GETCAP", 0x800470a3 },
+{ "PHONE_CAPABILITIES_LIST", 0x80047181 },
+{ "PHONE_DTMF_READY", 0x80047196 },
+{ "PHONE_GET_DTMF", 0x80047197 },
+{ "PHONE_GET_DTMF_ASCII", 0x80047198 },
+{ "PHONE_EXCEPTION", 0x8004719a },
+{ "IXJCTL_CARDTYPE", 0x800471c1 },
+{ "IXJCTL_SERIAL", 0x800471c2 },
+{ "IXJCTL_DSP_TYPE", 0x800471c3 },
+{ "IXJCTL_DSP_VERSION", 0x800471c4 },
+{ "IXJCTL_CID", 0x800471d4 },
+{ "IXJCTL_VMWI", 0x800471d8 },
+{ "IXJCTL_VERSION", 0x800471da },
+{ "IXJCTL_FRAMES_READ", 0x800471e2 },
+{ "IXJCTL_FRAMES_WRITTEN", 0x800471e3 },
+{ "IXJCTL_READ_WAIT", 0x800471e4 },
+{ "IXJCTL_WRITE_WAIT", 0x800471e5 },
+{ "IXJCTL_DRYBUFFER_READ", 0x800471e6 },
+{ "BR_ERROR", 0x80047200 },
+{ "BR_ACQUIRE_RESULT", 0x80047204 },
+{ "FAT_IOCTL_GET_ATTRIBUTES", 0x80047210 },
+{ "FAT_IOCTL_GET_VOLUME_ID", 0x80047213 },
+{ "PPPIOCGCHAN", 0x80047437 },
+{ "PPPIOCGDEBUG", 0x80047441 },
+{ "PPPIOCGMRU", 0x80047453 },
+{ "PPPIOCGRASYNCMAP", 0x80047455 },
+{ "PPPIOCGUNIT", 0x80047456 },
+{ "PPPIOCGASYNCMAP", 0x80047458 },
+{ "PPPIOCGFLAGS", 0x8004745a },
+{ "PPPIOCGMPFLAGS", 0x80047482 },
+{ "FS_IOC32_GETVERSION", 0x80047601 },
+{ "FS_IOC_GETVERSION", 0x80047601 },
+{ "MEYEIOC_STILLJCAPT", 0x800476c5 },
+{ "OSIOCGNETADDR", 0x800489e1 },
+{ "SIOCGNETADDR", 0x800489e1 },
+{ "AUTOFS_IOC_PROTOVER", 0x80049363 },
+{ "AUTOFS_IOC_PROTOSUBVER", 0x80049367 },
+{ "AUTOFS_IOC_ASKUMOUNT", 0x80049370 },
+{ "GENWQE_GET_CARD_STATE", 0x8004a524 },
+{ "KVM_GET_MP_STATE", 0x8004ae98 },
+{ "CXL_IOCTL_GET_PROCESS_ELEMENT", 0x8004ca01 },
+{ "FUSE_DEV_IOC_CLONE", 0x8004e500 },
+{ "SISFB_GET_INFO_SIZE", 0x8004f300 },
+{ "SISFB_GET_VBRSTATUS", 0x8004f302 },
+{ "SISFB_GET_AUTOMAXIMIZE", 0x8004f303 },
+{ "SISFB_GET_TVPOSOFFSET", 0x8004f304 },
+{ "SONET_GETFRSENSE", 0x80066117 },
+{ "MEYEIOC_G_PARAMS", 0x800676c0 },
+{ "SNAPSHOT_GET_IMAGE_SIZE", 0x8008330e },
+{ "SNAPSHOT_AVAIL_SWAP_SIZE", 0x80083313 },
+{ "SNAPSHOT_ALLOC_SWAP_PAGE", 0x80083314 },
+{ "CCISS_GETPCIINFO", 0x80084201 },
+{ "CCISS_GETINTINFO", 0x80084202 },
+{ "EVIOCGID", 0x80084502 },
+{ "EVIOCGREP", 0x80084503 },
+{ "EVIOCGKEYCODE", 0x80084504 },
+{ "HIDIOCGRAWINFO", 0x80084803 },
+{ "SNDRV_HDSP_IOCTL_GET_VERSION", 0x80084843 },
+{ "SNDRV_HDSP_IOCTL_GET_9632_AEB", 0x80084845 },
+{ "AMDKFD_IOC_GET_VERSION", 0x80084b01 },
+{ "MFB_GET_AOID", 0x80084d04 },
+{ "MEMISLOCKED", 0x80084d17 },
+{ "SNDCTL_DSP_MAPINBUF", 0x80085013 },
+{ "SNDCTL_DSP_MAPOUTBUF", 0x80085014 },
+{ "RNDGETPOOL", 0x80085202 },
+{ "TUNGETFILTER", 0x800854db },
+{ "USBDEVFS_SETINTERFACE", 0x80085504 },
+{ "USBDEVFS_DISCSIGNAL", 0x8008550e },
+{ "USBDEVFS_ALLOC_STREAMS", 0x8008551c },
+{ "USBDEVFS_FREE_STREAMS", 0x8008551d },
+{ "VIDIOC_G_STD", 0x80085617 },
+{ "VIDIOC_QUERYSTD", 0x8008563f },
+{ "DRM_IOCTL_I810_OV0INFO", 0x80086449 },
+{ "I2OPASSTHRU", 0x8008690c },
+{ "IPMICTL_SET_TIMING_PARMS_CMD", 0x80086916 },
+{ "IPMICTL_GET_TIMING_PARMS_CMD", 0x80086917 },
+{ "NCP_IOC_SETPRIVATEDATA", 0x80086e0a },
+{ "NILFS_IOCTL_SYNC", 0x80086e8a },
+{ "AUDIO_GET_PTS", 0x80086f13 },
+{ "DMX_GET_CAPS", 0x80086f30 },
+{ "VIDEO_GET_PTS", 0x80086f39 },
+{ "VIDEO_GET_FRAME_COUNT", 0x80086f3a },
+{ "FE_GET_PROPERTY", 0x80086f53 },
+{ "CA_GET_DESCR_INFO", 0x80086f83 },
+{ "OSD_GET_CAPABILITY", 0x80086fa1 },
+{ "BR_DEAD_BINDER", 0x8008720f },
+{ "BR_CLEAR_DEATH_NOTIFICATION_DONE", 0x80087210 },
+{ "BTRFS_IOC_START_SYNC", 0x80089418 },
+{ "BTRFS_IOC_SUBVOL_GETFLAGS", 0x80089419 },
+{ "KVM_X86_GET_MCE_CAP_SUPPORTED", 0x8008ae9d },
+{ "KVM_ALLOCATE_RMA", 0x8008aea9 },
+{ "VHOST_GET_FEATURES", 0x8008af00 },
+{ "FUNCTIONFS_ENDPOINT_DESC", 0x80096782 },
+{ "DMX_GET_PES_PIDS", 0x800a6f2f },
+{ "RAID_VERSION", 0x800c0910 },
+{ "SNDRV_PCM_IOCTL_READI_FRAMES", 0x800c4151 },
+{ "SNDRV_PCM_IOCTL_READN_FRAMES", 0x800c4153 },
+{ "CCISS_GETLUNINFO", 0x800c4211 },
+{ "OTPLOCK", 0x800c4d10 },
+{ "OMAPFB_GET_CAPS", 0x800c4f2a },
+{ "SNDCTL_DSP_GETIPTR", 0x800c5011 },
+{ "SNDCTL_DSP_GETOPTR", 0x800c5012 },
+{ "FS_IOC_SET_ENCRYPTION_POLICY", 0x800c6613 },
+{ "HPET_INFO", 0x800c6803 },
+{ "IPMICTL_REGISTER_FOR_CMD_CHANS", 0x800c691c },
+{ "IPMICTL_UNREGISTER_FOR_CMD_CHANS", 0x800c691d },
+{ "NCP_IOC_NCPREQUEST", 0x800c6e01 },
+{ "NCP_IOC_SETROOT", 0x800c6e08 },
+{ "NCP_IOC_SETOBJECTNAME", 0x800c6e09 },
+{ "VIDEO_GET_SIZE", 0x800c6f37 },
+{ "FE_DISEQC_RECV_SLAVE_REPLY", 0x800c6f40 },
+{ "CA_GET_SLOT_INFO", 0x800c6f82 },
+{ "FDGETDRVTYP", 0x8010020f },
+{ "FW_CDEV_IOC_GET_CYCLE_TIMER", 0x8010230c },
+{ "STP_POLICY_ID_GET", 0x80102501 },
+{ "CCISS_GETNODENAME", 0x80104204 },
+{ "EVIOCGMASK", 0x80104592 },
+{ "SNDRV_HDSPM_IOCTL_GET_LTC", 0x80104846 },
+{ "ECCGETSTATS", 0x80104d12 },
+{ "OMAPFB_MEMORY_READ", 0x80104f3a },
+{ "SNDCTL_DSP_GETOSPACE", 0x8010500c },
+{ "SNDCTL_DSP_GETISPACE", 0x8010500d },
+{ "DRM_IOCTL_I915_GEM_GET_APERTURE", 0x80106463 },
+{ "MGSL_IOCGGPIO", 0x80106d11 },
+{ "CA_GET_CAP", 0x80106f81 },
+{ "PPGETTIME", 0x80107095 },
+{ "BR_INCREFS", 0x80107207 },
+{ "BR_ACQUIRE", 0x80107208 },
+{ "BR_RELEASE", 0x80107209 },
+{ "BR_DECREFS", 0x8010720a },
+{ "PPPIOCGIDLE", 0x8010743f },
+{ "PPPIOCGIFNAME", 0x80107488 },
+{ "GENWQE_READ_REG64", 0x8010a51e },
+{ "GENWQE_READ_REG32", 0x8010a520 },
+{ "GENWQE_READ_REG16", 0x8010a522 },
+{ "UFFDIO_UNREGISTER", 0x8010aa01 },
+{ "UFFDIO_WAKE", 0x8010aa02 },
+{ "FDGETMAXERRS", 0x8014020e },
+{ "GET_DISK_INFO", 0x80140912 },
+{ "SNDRV_COMPRESS_TSTAMP", 0x80144320 },
+{ "CHIOGPARAMS", 0x80146306 },
+{ "IPMICTL_SEND_COMMAND", 0x8014690d },
+{ "NCP_IOC_LOCKUNLOCK", 0x80146e07 },
+{ "VIDEO_GET_STATUS", 0x80146f1b },
+{ "FDWERRORGET", 0x80180217 },
+{ "SNDRV_PCM_IOCTL_CHANNEL_INFO", 0x80184132 },
+{ "SNDRV_HDSPM_IOCTL_GET_CONFIG", 0x80184841 },
+{ "IMSETDEVNAME", 0x80184947 },
+{ "RIO_MPORT_MAINT_READ_LOCAL", 0x80186d05 },
+{ "RIO_MPORT_MAINT_READ_REMOTE", 0x80186d07 },
+{ "NCP_IOC_SIGN_INIT", 0x80186e05 },
+{ "NILFS_IOCTL_GET_CPINFO", 0x80186e82 },
+{ "NILFS_IOCTL_GET_CPSTAT", 0x80186e83 },
+{ "NILFS_IOCTL_GET_SUINFO", 0x80186e84 },
+{ "BR_ATTEMPT_ACQUIRE", 0x8018720b },
+{ "BTRFS_IOC_GET_FEATURES", 0x80189439 },
+{ "MBXFB_IOCG_ALPHA", 0x8018f401 },
+{ "FDGETPRM", 0x801c0204 },
+{ "SNDRV_COMPRESS_AVAIL", 0x801c4321 },
+{ "HIDIOCGDEVINFO", 0x801c4803 },
+{ "FS_IOC_FSGETXATTR", 0x801c581f },
+{ "IPMICTL_SEND_COMMAND_SETTIME", 0x801c6915 },
+{ "MTIOCGET", 0x801c6d02 },
+{ "RTC_PLL_GET", 0x801c7011 },
+{ "FDGETFDCSTAT", 0x80200215 },
+{ "FBIOGET_VBLANK", 0x80204612 },
+{ "SNDRV_HDSPM_IOCTL_GET_STATUS", 0x80204847 },
+{ "SNDRV_FIREWIRE_IOCTL_GET_INFO", 0x802048f8 },
+{ "MEMGETINFO", 0x80204d01 },
+{ "OMAPFB_GET_VRAM_INFO", 0x80204f3d },
+{ "OMAPFB_GET_DISPLAY_INFO", 0x80204f3f },
+{ "DRM_IOCTL_AGP_INFO", 0x80206433 },
+{ "I2OGETIOPS", 0x80206900 },
+{ "MGSL_IOCGPARAMS", 0x80206d01 },
+{ "AUDIO_GET_STATUS", 0x80206f0a },
+{ "VIDEO_GET_EVENT", 0x80206f1c },
+{ "PPPIOCGXASYNCMAP", 0x80207450 },
+{ "PPPIOCGCOMPRESSORS", 0x80207486 },
+{ "KVM_ARM_PREFERRED_TARGET", 0x8020aeaf },
+{ "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", 0x80244841 },
+{ "SNDRV_HDSPM_IOCTL_GET_VERSION", 0x80244848 },
+{ "SONET_GETSTAT", 0x80246110 },
+{ "SONET_GETSTATZ", 0x80246111 },
+{ "JSIOCGCORR", 0x80246a22 },
+{ "FE_GET_FRONTEND", 0x80246f4d },
+{ "RTC_ALM_READ", 0x80247008 },
+{ "RTC_RD_TIME", 0x80247009 },
+{ "EVIOCGKEYCODE_V2", 0x80284504 },
+{ "SNDRV_SB_CSP_IOCTL_INFO", 0x80284810 },
+{ "WDIOC_GETSUPPORT", 0x80285700 },
+{ "FE_GET_EVENT", 0x80286f4e },
+{ "RTC_WKALM_RD", 0x80287010 },
+{ "IOW_GETINFO", 0x8028c003 },
+{ "USBDEVFS_SUBMITURB32", 0x802a550a },
+{ "NCP_IOC_SETCHARSETS", 0x802a6e0b },
+{ "TCGETS2", 0x802c542a },
+{ "USBDEVFS_SUBMITURB", 0x802c550a },
+{ "VIDIOC_G_FBUF", 0x802c560a },
+{ "SOUND_OLD_MIXER_INFO", 0x80304d65 },
+{ "RIO_MPORT_GET_PROPERTIES", 0x80306d04 },
+{ "NILFS_IOCTL_GET_SUSTAT", 0x80306e85 },
+{ "BTRFS_IOC_QGROUP_LIMIT", 0x8030942b },
+{ "KVM_GET_CLOCK", 0x8030ae7c },
+{ "FDGETDRVSTAT", 0x80340212 },
+{ "FDPOLLDRVSTAT", 0x80340213 },
+{ "VIDIOC_G_AUDIO", 0x80345621 },
+{ "VIDIOC_G_AUDOUT", 0x80345631 },
+{ "OMAPFB_GET_OVERLAY_COLORMODE", 0x803c4f3b },
+{ "SNDRV_HWDEP_IOCTL_DSP_STATUS", 0x80404802 },
+{ "JSIOCGAXMAP", 0x80406a32 },
+{ "BR_TRANSACTION", 0x80407202 },
+{ "BR_REPLY", 0x80407203 },
+{ "BTRFS_IOC_QUOTA_RESCAN_STATUS", 0x8040942d },
+{ "KVM_ASSIGN_PCI_DEVICE", 0x8040ae69 },
+{ "KVM_GET_VCPU_EVENTS", 0x8040ae9f },
+{ "CXL_IOCTL_GET_AFU_ID", 0x8040ca02 },
+{ "GPIO_GET_CHIPINFO_IOCTL", 0x8044b401 },
+{ "GET_ARRAY_INFO", 0x80480911 },
+{ "PPPIOCGL2TPSTATS", 0x80487436 },
+{ "BTRFS_IOC_GET_SUPPORTED_FEATURES", 0x80489439 },
+{ "KVM_SET_PIT", 0x8048ae66 },
+{ "GSMIOC_GETCONF", 0x804c4700 },
+{ "PTP_CLOCK_GETCAPS", 0x80503d01 },
+{ "FDGETDRVPRM", 0x80580211 },
+{ "SOUND_MIXER_INFO", 0x805c4d65 },
+{ "SNDRV_TIMER_IOCTL_STATUS", 0x80605414 },
+{ "VIDIOC_QUERYCAP", 0x80685600 },
+{ "I2OEVTGET", 0x8068690b },
+{ "CHIOGVPARAMS", 0x80706313 },
+{ "KVM_GET_PIT2", 0x8070ae9f },
+{ "SNDRV_COMPRESS_GET_PARAMS", 0x80784313 },
+{ "DRM_IOCTL_GET_STATS", 0x807c6406 },
+{ "SNDRV_PCM_IOCTL_STATUS", 0x80804120 },
+{ "USBDEVFS_HUB_PORTINFO", 0x80805513 },
+{ "KVM_GET_DEBUGREGS", 0x8080aea1 },
+{ "VIDIOC_QUERY_DV_TIMINGS", 0x80845663 },
+{ "VIDIOC_SUBDEV_QUERY_DV_TIMINGS", 0x80845663 },
+{ "VIDIOC_DQEVENT", 0x80885659 },
+{ "VIDIOC_G_JPEGCOMP", 0x808c563d },
+{ "KVM_GET_REGS", 0x8090ae81 },
+{ "FE_GET_INFO", 0x80a86f3d },
+{ "MEMGETOOBSEL", 0x80c84d0a },
+{ "SNDRV_HWDEP_IOCTL_INFO", 0x80dc4801 },
+{ "SNDRV_CTL_IOCTL_HWDEP_INFO", 0x80dc5521 },
+{ "SNDRV_TIMER_IOCTL_INFO", 0x80e05411 },
+{ "ASHMEM_GET_NAME", 0x81007702 },
+{ "BTRFS_IOC_GET_FSLABEL", 0x81009431 },
+{ "HIDIOCGSTRING", 0x81044804 },
+{ "USBDEVFS_DISCONNECT_CLAIM", 0x8108551b },
+{ "SNDRV_RAWMIDI_IOCTL_INFO", 0x810c5701 },
+{ "CA_GET_MSG", 0x810c6f84 },
+{ "AUTOFS_IOC_EXPIRE", 0x810c9365 },
+{ "SISFB_GET_INFO", 0x811cf301 },
+{ "SNDRV_PCM_IOCTL_INFO", 0x81204101 },
+{ "KVM_GET_SREGS", 0x8138ae83 },
+{ "ECCGETLAYOUT", 0x81484d11 },
+{ "SNDRV_CTL_IOCTL_CARD_INFO", 0x81785501 },
+{ "KVM_GET_XCRS", 0x8188aea6 },
+{ "AMDKFD_IOC_GET_PROCESS_APERTURES", 0x81904b06 },
+{ "KVM_GET_FPU", 0x81a0ae8c },
+{ "KVM_SET_IRQCHIP", 0x8208ae63 },
+{ "VFAT_IOCTL_READDIR_BOTH", 0x82307201 },
+{ "VFAT_IOCTL_READDIR_SHORT", 0x82307202 },
+{ "KVM_PPC_GET_SMMU_INFO", 0x8250aea6 },
+{ "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", 0x83b04840 },
+{ "JSIOCGBTNMAP", 0x84006a34 },
+{ "BTRFS_IOC_FS_INFO", 0x8400941f },
+{ "BTRFS_IOC_BALANCE_PROGRESS", 0x84009422 },
+{ "KVM_GET_LAPIC", 0x8400ae8e },
+{ "VIDEO_GET_NAVI", 0x84046f34 },
+{ "SNDRV_EMU10K1_IOCTL_INFO", 0x880c4810 },
+{ "VIDIOC_G_ENC_INDEX", 0x8818564c },
+{ "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", 0x89084842 },
+{ "SNDCTL_COPR_RCVMSG", 0x8fa44309 },
+{ "GET_BITMAP_FILE", 0x90000915 },
+{ "SNDRV_HDSP_IOCTL_GET_MIXER", 0x90004844 },
+{ "NVM_GET_DEVICES", 0x90004c21 },
+{ "BTRFS_IOC_DEVICES_READY", 0x90009427 },
+{ "KVM_GET_XSAVE", 0x9000aea4 },
+{ "HIDIOCGRDESC", 0x90044802 },
+{ "GADGET_SET_PRINTER_STATUS", 0xc0016722 },
+{ "AGPIOC_ALLOCATE", 0xc0044106 },
+{ "CAPI_GET_MANUFACTURER", 0xc0044306 },
+{ "CAPI_GET_SERIAL", 0xc0044308 },
+{ "GIGASET_REDIR", 0xc0044700 },
+{ "GIGASET_CONFIG", 0xc0044701 },
+{ "ION_IOC_FREE", 0xc0044901 },
+{ "SOUND_MIXER_AGC", 0xc0044d67 },
+{ "SOUND_MIXER_3DSE", 0xc0044d68 },
+{ "SOUND_MIXER_PRIVATE1", 0xc0044d6f },
+{ "SOUND_MIXER_PRIVATE2", 0xc0044d70 },
+{ "SOUND_MIXER_PRIVATE3", 0xc0044d71 },
+{ "SOUND_MIXER_PRIVATE4", 0xc0044d72 },
+{ "SOUND_MIXER_PRIVATE5", 0xc0044d73 },
+{ "SNDCTL_DSP_SPEED", 0xc0045002 },
+{ "SNDCTL_DSP_STEREO", 0xc0045003 },
+{ "SNDCTL_DSP_GETBLKSIZE", 0xc0045004 },
+{ "SNDCTL_DSP_SETFMT", 0xc0045005 },
+{ "SNDCTL_DSP_CHANNELS", 0xc0045006 },
+{ "SOUND_PCM_WRITE_FILTER", 0xc0045007 },
+{ "SNDCTL_DSP_SUBDIVIDE", 0xc0045009 },
+{ "SNDCTL_DSP_SETFRAGMENT", 0xc004500a },
+{ "SNDCTL_DSP_GETCHANNELMASK", 0xc0045040 },
+{ "SNDCTL_DSP_BIND_CHANNEL", 0xc0045041 },
+{ "SNDCTL_SEQ_CTRLRATE", 0xc0045103 },
+{ "SNDCTL_SYNTH_MEMAVL", 0xc004510e },
+{ "SNDCTL_TMR_TIMEBASE", 0xc0045401 },
+{ "SNDCTL_TMR_TEMPO", 0xc0045405 },
+{ "SNDCTL_TMR_SOURCE", 0xc0045406 },
+{ "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", 0xc0045516 },
+{ "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", 0xc0045520 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", 0xc0045540 },
+{ "SNDRV_CTL_IOCTL_POWER", 0xc00455d0 },
+{ "VIDIOC_S_INPUT", 0xc0045627 },
+{ "VIDIOC_S_OUTPUT", 0xc004562f },
+{ "VIDIOC_OMAP3ISP_STAT_EN", 0xc00456c7 },
+{ "WDIOC_SETTIMEOUT", 0xc0045706 },
+{ "WDIOC_SETPRETIMEOUT", 0xc0045708 },
+{ "FIFREEZE", 0xc0045877 },
+{ "FITHAW", 0xc0045878 },
+{ "SONET_SETDIAG", 0xc0046112 },
+{ "SONET_CLRDIAG", 0xc0046113 },
+{ "BINDER_VERSION", 0xc0046209 },
+{ "CM_IOCGATR", 0xc0046301 },
+{ "CIOC_KERNEL_VERSION", 0xc004630a },
+{ "DRM_IOCTL_BLOCK", 0xc0046412 },
+{ "DRM_IOCTL_UNBLOCK", 0xc0046413 },
+{ "DRM_IOCTL_ADD_DRAW", 0xc0046427 },
+{ "DRM_IOCTL_RM_DRAW", 0xc0046428 },
+{ "DRM_IOCTL_I915_IRQ_EMIT", 0xc0046444 },
+{ "DRM_IOCTL_MGA_WAIT_FENCE", 0xc004644b },
+{ "DRM_IOCTL_RADEON_IRQ_EMIT", 0xc0046456 },
+{ "DRM_IOCTL_MODE_RMFB", 0xc00464af },
+{ "DRM_IOCTL_MODE_DESTROY_DUMB", 0xc00464b4 },
+{ "DRM_IOCTL_MODE_DESTROYPROPBLOB", 0xc00464be },
+{ "I8K_GET_SPEED", 0xc0046985 },
+{ "I8K_GET_FAN", 0xc0046986 },
+{ "I8K_SET_FAN", 0xc0046987 },
+{ "UDF_RELOCATE_BLOCKS", 0xc0046c43 },
+{ "SNDCTL_MIDI_PRETIME", 0xc0046d00 },
+{ "SNDCTL_MIDI_MPUMODE", 0xc0046d01 },
+{ "MGSL_IOCWAITEVENT", 0xc0046d08 },
+{ "MATROXFB_GET_OUTPUT_MODE", 0xc0046efa },
+{ "PHN_GET_REG", 0xc0047000 },
+{ "PHN_GET_REGS", 0xc0047002 },
+{ "PPS_FETCH", 0xc00470a4 },
+{ "PHONE_QUERY_CODEC", 0xc00471a7 },
+{ "MIC_VIRTIO_ADD_DEVICE", 0xc0047301 },
+{ "MIC_VIRTIO_COPY_DESC", 0xc0047302 },
+{ "MIC_VIRTIO_CONFIG_CHANGE", 0xc0047305 },
+{ "SCIF_FENCE_WAIT", 0xc0047310 },
+{ "PPPIOCNEWUNIT", 0xc004743e },
+{ "MEYEIOC_SYNC", 0xc00476c3 },
+{ "AUTOFS_IOC_SETTIMEOUT", 0xc0049364 },
+{ "KVM_GET_MSR_INDEX_LIST", 0xc004ae02 },
+{ "KVM_PPC_ALLOCATE_HTAB", 0xc004aea7 },
+{ "NET_ADD_IF", 0xc0066f34 },
+{ "NET_GET_IF", 0xc0066f36 },
+{ "CAPI_MANUFACTURER_CMD", 0xc0084320 },
+{ "HDA_IOCTL_VERB_WRITE", 0xc0084811 },
+{ "HDA_IOCTL_GET_WCAP", 0xc0084812 },
+{ "ION_IOC_MAP", 0xc0084902 },
+{ "ION_IOC_SHARE", 0xc0084904 },
+{ "ION_IOC_IMPORT", 0xc0084905 },
+{ "ION_IOC_CUSTOM", 0xc0084906 },
+{ "ION_IOC_SYNC", 0xc0084907 },
+{ "AMDKFD_IOC_DESTROY_QUEUE", 0xc0084b03 },
+{ "ND_IOCTL_DIMM_FLAGS", 0xc0084e03 },
+{ "ND_IOCTL_SET_CONFIG_DATA", 0xc0084e06 },
+{ "ND_IOCTL_VENDOR", 0xc0084e09 },
+{ "SNDRV_CTL_IOCTL_TLV_READ", 0xc008551a },
+{ "SNDRV_CTL_IOCTL_TLV_WRITE", 0xc008551b },
+{ "SNDRV_CTL_IOCTL_TLV_COMMAND", 0xc008551c },
+{ "VIDIOC_G_CTRL", 0xc008561b },
+{ "VIDIOC_S_CTRL", 0xc008561c },
+{ "DRM_IOCTL_GET_UNIQUE", 0xc0086401 },
+{ "DRM_IOCTL_GEM_FLINK", 0xc008640a },
+{ "DRM_IOCTL_INFO_BUFS", 0xc0086418 },
+{ "DRM_IOCTL_GET_SAREA_CTX", 0xc008641d },
+{ "DRM_IOCTL_ADD_CTX", 0xc0086420 },
+{ "DRM_IOCTL_RM_CTX", 0xc0086421 },
+{ "DRM_IOCTL_GET_CTX", 0xc0086423 },
+{ "DRM_IOCTL_RES_CTX", 0xc0086426 },
+{ "DRM_IOCTL_SG_ALLOC", 0xc0086438 },
+{ "DRM_IOCTL_QXL_ALLOC", 0xc0086440 },
+{ "DRM_IOCTL_AMDGPU_GEM_MMAP", 0xc0086441 },
+{ "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", 0xc0086442 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_READ", 0xc0086442 },
+{ "DRM_IOCTL_VIA_AGP_INIT", 0xc0086442 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_INCR", 0xc0086443 },
+{ "DRM_IOCTL_VIA_FB_INIT", 0xc0086443 },
+{ "DRM_IOCTL_I915_GETPARAM", 0xc0086446 },
+{ "DRM_IOCTL_VIRTGPU_WAIT", 0xc0086448 },
+{ "DRM_IOCTL_MGA_GETPARAM", 0xc0086449 },
+{ "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", 0xc008644c },
+{ "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", 0xc008644d },
+{ "DRM_IOCTL_RADEON_GETPARAM", 0xc0086451 },
+{ "DRM_IOCTL_R128_GETPARAM", 0xc0086452 },
+{ "DRM_IOCTL_SIS_AGP_INIT", 0xc0086453 },
+{ "DRM_IOCTL_I915_GEM_BUSY", 0xc0086457 },
+{ "DRM_IOCTL_EXYNOS_G2D_GET_VER", 0xc0086460 },
+{ "DRM_IOCTL_EXYNOS_G2D_EXEC", 0xc0086462 },
+{ "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", 0xc0086465 },
+{ "DRM_IOCTL_RADEON_GEM_BUSY", 0xc008646a },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", 0xc008646d },
+{ "DRM_IOCTL_I915_GEM_GET_CACHING", 0xc0086470 },
+{ "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", 0xc0086473 },
+{ "NCP_IOC_GETPRIVATEDATA", 0xc0086e0a },
+{ "PHN_GETREG", 0xc0087005 },
+{ "SCIF_BIND", 0xc0087301 },
+{ "SCIF_CONNECT", 0xc0087303 },
+{ "SCIF_ACCEPTREG", 0xc0087305 },
+{ "PPPIOCGNPMODE", 0xc008744c },
+{ "KVM_GET_SUPPORTED_CPUID", 0xc008ae05 },
+{ "KVM_GET_EMULATED_CPUID", 0xc008ae09 },
+{ "KVM_IRQ_LINE_STATUS", 0xc008ae67 },
+{ "KVM_GET_MSRS", 0xc008ae88 },
+{ "KVM_GET_CPUID2", 0xc008ae91 },
+{ "KVM_GET_REG_LIST", 0xc008aeb0 },
+{ "FSL_HV_IOCTL_PARTITION_RESTART", 0xc008af01 },
+{ "FSL_HV_IOCTL_PARTITION_STOP", 0xc008af04 },
+{ "FSL_HV_IOCTL_DOORBELL", 0xc008af06 },
+{ "VHOST_GET_VRING_BASE", 0xc008af12 },
+{ "MMC_IOC_MULTI_CMD", 0xc008b301 },
+{ "HIDIOCGREPORTINFO", 0xc00c4809 },
+{ "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", 0xc00c4822 },
+{ "MEMWRITEOOB", 0xc00c4d03 },
+{ "MEMREADOOB", 0xc00c4d04 },
+{ "ND_IOCTL_SMART_THRESHOLD", 0xc00c4e02 },
+{ "ND_IOCTL_GET_CONFIG_SIZE", 0xc00c4e04 },
+{ "ND_IOCTL_GET_CONFIG_DATA", 0xc00c4e05 },
+{ "SNDCTL_SYNTH_REMOVESAMPLE", 0xc00c5116 },
+{ "USBDEVFS_IOCTL", 0xc00c5512 },
+{ "UI_BEGIN_FF_ERASE", 0xc00c55ca },
+{ "NS_GETPSTAT", 0xc00c6161 },
+{ "DRM_IOCTL_MAP_BUFS", 0xc00c6419 },
+{ "DRM_IOCTL_PRIME_HANDLE_TO_FD", 0xc00c642d },
+{ "DRM_IOCTL_PRIME_FD_TO_HANDLE", 0xc00c642e },
+{ "DRM_IOCTL_VIA_CMDBUF_SIZE", 0xc00c644b },
+{ "DRM_IOCTL_I915_VBLANK_SWAP", 0xc00c644f },
+{ "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", 0xc00c6463 },
+{ "DRM_IOCTL_I915_GEM_MADVISE", 0xc00c6466 },
+{ "DRM_IOCTL_RADEON_GEM_SET_TILING", 0xc00c6468 },
+{ "DRM_IOCTL_RADEON_GEM_GET_TILING", 0xc00c6469 },
+{ "I2OHRTGET", 0xc00c6901 },
+{ "I2OLCTGET", 0xc00c6902 },
+{ "NCP_IOC_GETOBJECTNAME", 0xc00c6e09 },
+{ "UVCIOC_CTRL_QUERY", 0xc00c7521 },
+{ "KVM_CREATE_DEVICE", 0xc00caee0 },
+{ "FSL_HV_IOCTL_PARTITION_GET_STATUS", 0xc00caf02 },
+{ "MBXFB_IOCX_REG", 0xc00cf405 },
+{ "STP_POLICY_ID_SET", 0xc0102500 },
+{ "CAPI_GET_VERSION", 0xc0104307 },
+{ "GIGASET_VERSION", 0xc0104703 },
+{ "IOCTL_MEI_CONNECT_CLIENT", 0xc0104801 },
+{ "HIDIOCGCOLLECTIONINFO", 0xc0104811 },
+{ "SNDRV_EMUX_IOCTL_LOAD_PATCH", 0xc0104881 },
+{ "SNDRV_EMUX_IOCTL_MISC_MODE", 0xc0104884 },
+{ "MEMGETREGIONINFO", 0xc0104d08 },
+{ "SNDRV_SEQ_IOCTL_RUNNING_MODE", 0xc0105303 },
+{ "USBDEVFS_CONTROL", 0xc0105500 },
+{ "USBDEVFS_BULK", 0xc0105502 },
+{ "DRM_IOCTL_IRQ_BUSID", 0xc0106403 },
+{ "DRM_IOCTL_SET_VERSION", 0xc0106407 },
+{ "DRM_IOCTL_GEM_OPEN", 0xc010640b },
+{ "DRM_IOCTL_GET_CAP", 0xc010640c },
+{ "DRM_IOCTL_AGP_ALLOC", 0xc0106434 },
+{ "DRM_IOCTL_WAIT_VBLANK", 0xc010643a },
+{ "DRM_IOCTL_ETNAVIV_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_EXYNOS_GEM_CREATE", 0xc0106440 },
+{ "DRM_IOCTL_MSM_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_OMAP_GET_PARAM", 0xc0106440 },
+{ "DRM_IOCTL_TEGRA_GEM_CREATE", 0xc0106440 },
+{ "DRM_IOCTL_EXYNOS_GEM_MAP", 0xc0106441 },
+{ "DRM_IOCTL_QXL_MAP", 0xc0106441 },
+{ "DRM_IOCTL_TEGRA_GEM_MMAP", 0xc0106441 },
+{ "DRM_IOCTL_VC4_WAIT_SEQNO", 0xc0106441 },
+{ "DRM_IOCTL_VIRTGPU_MAP", 0xc0106441 },
+{ "DRM_IOCTL_AMDGPU_CTX", 0xc0106442 },
+{ "DRM_IOCTL_ETNAVIV_GEM_NEW", 0xc0106442 },
+{ "DRM_IOCTL_MSM_GEM_NEW", 0xc0106442 },
+{ "DRM_IOCTL_VC4_WAIT_BO", 0xc0106442 },
+{ "DRM_IOCTL_ETNAVIV_GEM_INFO", 0xc0106443 },
+{ "DRM_IOCTL_MSM_GEM_INFO", 0xc0106443 },
+{ "DRM_IOCTL_OMAP_GEM_NEW", 0xc0106443 },
+{ "DRM_IOCTL_VC4_CREATE_BO", 0xc0106443 },
+{ "DRM_IOCTL_VIRTGPU_GETPARAM", 0xc0106443 },
+{ "DRM_IOCTL_EXYNOS_GEM_GET", 0xc0106444 },
+{ "DRM_IOCTL_QXL_GETPARAM", 0xc0106444 },
+{ "DRM_IOCTL_SIS_FB_ALLOC", 0xc0106444 },
+{ "DRM_IOCTL_TEGRA_SYNCPT_WAIT", 0xc0106444 },
+{ "DRM_IOCTL_VC4_MMAP_BO", 0xc0106444 },
+{ "DRM_IOCTL_I810_GETBUF", 0xc0106445 },
+{ "DRM_IOCTL_TEGRA_OPEN_CHANNEL", 0xc0106445 },
+{ "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", 0xc0106445 },
+{ "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", 0xc0106446 },
+{ "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", 0xc0106447 },
+{ "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", 0xc0106447 },
+{ "DRM_IOCTL_TEGRA_GET_SYNCPT", 0xc0106447 },
+{ "DRM_IOCTL_VIA_DMA_INIT", 0xc0106447 },
+{ "DRM_IOCTL_I915_ALLOC", 0xc0106448 },
+{ "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", 0xc0106449 },
+{ "DRM_IOCTL_TEGRA_GEM_SET_TILING", 0xc010644a },
+{ "DRM_IOCTL_TEGRA_GEM_GET_TILING", 0xc010644b },
+{ "DRM_IOCTL_RADEON_INDIRECT", 0xc010644d },
+{ "DRM_IOCTL_VIA_WAIT_IRQ", 0xc010644d },
+{ "DRM_IOCTL_R128_INDIRECT", 0xc010644f },
+{ "DRM_IOCTL_AMDGPU_GEM_OP", 0xc0106450 },
+{ "DRM_IOCTL_RADEON_ALLOC", 0xc0106453 },
+{ "DRM_IOCTL_SIS_AGP_ALLOC", 0xc0106454 },
+{ "DRM_IOCTL_I915_GEM_CREATE", 0xc010645b },
+{ "DRM_IOCTL_I915_GEM_SET_TILING", 0xc0106461 },
+{ "DRM_IOCTL_I915_GEM_GET_TILING", 0xc0106462 },
+{ "DRM_IOCTL_I915_GEM_MMAP_GTT", 0xc0106464 },
+{ "DRM_IOCTL_RADEON_INFO", 0xc0106467 },
+{ "DRM_IOCTL_I915_GEM_WAIT", 0xc010646c },
+{ "DRM_IOCTL_RADEON_GEM_OP", 0xc010646c },
+{ "DRM_IOCTL_I915_REG_READ", 0xc0106471 },
+{ "DRM_IOCTL_MODE_SETPROPERTY", 0xc01064ab },
+{ "DRM_IOCTL_MODE_GETPROPBLOB", 0xc01064ac },
+{ "DRM_IOCTL_MODE_MAP_DUMB", 0xc01064b3 },
+{ "DRM_IOCTL_MODE_GETPLANERESOURCES", 0xc01064b5 },
+{ "DRM_IOCTL_MODE_CREATEPROPBLOB", 0xc01064bd },
+{ "MGSL_IOCWAITGPIO", 0xc0106d12 },
+{ "DMX_GET_STC", 0xc0106f32 },
+{ "SCIF_ACCEPTREQ", 0xc0107304 },
+{ "SCIF_UNREG", 0xc0107309 },
+{ "SCIF_FENCE_MARK", 0xc010730f },
+{ "BTRFS_IOC_SPACE_INFO", 0xc0109414 },
+{ "BTRFS_IOC_QUOTA_CTL", 0xc0109428 },
+{ "FSL_HV_IOCTL_PARTITION_START", 0xc010af03 },
+{ "SNDCTL_COPR_RDATA", 0xc0144302 },
+{ "SNDCTL_COPR_RCODE", 0xc0144303 },
+{ "SNDCTL_COPR_RUN", 0xc0144306 },
+{ "SNDCTL_COPR_HALT", 0xc0144307 },
+{ "ION_IOC_ALLOC", 0xc0144900 },
+{ "SNDRV_TIMER_IOCTL_NEXT_DEVICE", 0xc0145401 },
+{ "VIDIOC_REQBUFS", 0xc0145608 },
+{ "VIDIOC_G_CROP", 0xc014563b },
+{ "DRM_IOCTL_VIA_ALLOCMEM", 0xc0146440 },
+{ "DRM_IOCTL_VIA_MAP_INIT", 0xc0146444 },
+{ "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", 0xc014646a },
+{ "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", 0xc014646b },
+{ "DRM_IOCTL_MODE_GETENCODER", 0xc01464a6 },
+{ "HFI1_IOCTL_TID_UPDATE", 0xc0181be4 },
+{ "HFI1_IOCTL_TID_FREE", 0xc0181be5 },
+{ "HFI1_IOCTL_TID_INVAL_READ", 0xc0181bed },
+{ "FW_CDEV_IOC_ADD_DESCRIPTOR", 0xc0182306 },
+{ "FW_CDEV_IOC_QUEUE_ISO", 0xc0182309 },
+{ "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", 0xc018230d },
+{ "FW_CDEV_IOC_GET_CYCLE_TIMER2", 0xc0182314 },
+{ "FW_CDEV_IOC_SEND_PHY_PACKET", 0xc0182315 },
+{ "HIDIOCGUSAGE", 0xc018480b },
+{ "HIDIOCGUCODE", 0xc018480d },
+{ "AMDKFD_IOC_WAIT_EVENTS", 0xc0184b0c },
+{ "MTRRIOC_GET_ENTRY", 0xc0184d03 },
+{ "MTRRIOC_GET_PAGE_ENTRY", 0xc0184d08 },
+{ "MEMWRITEOOB64", 0xc0184d15 },
+{ "MEMREADOOB64", 0xc0184d16 },
+{ "VIDIOC_G_EXT_CTRLS", 0xc0185647 },
+{ "VIDIOC_S_EXT_CTRLS", 0xc0185648 },
+{ "VIDIOC_TRY_EXT_CTRLS", 0xc0185649 },
+{ "PACKET_CTRL_CMD", 0xc0185801 },
+{ "FITRIM", 0xc0185879 },
+{ "DRM_IOCTL_GET_MAP", 0xc0186404 },
+{ "DRM_IOCTL_GET_CLIENT", 0xc0186405 },
+{ "DRM_IOCTL_ADD_MAP", 0xc0186415 },
+{ "DRM_IOCTL_ADD_BUFS", 0xc0186416 },
+{ "DRM_IOCTL_AMDGPU_BO_LIST", 0xc0186443 },
+{ "DRM_IOCTL_AMDGPU_CS", 0xc0186444 },
+{ "DRM_IOCTL_VC4_CREATE_SHADER_BO", 0xc0186445 },
+{ "DRM_IOCTL_OMAP_GEM_INFO", 0xc0186446 },
+{ "DRM_IOCTL_QXL_ALLOC_SURF", 0xc0186446 },
+{ "DRM_IOCTL_ETNAVIV_GEM_USERPTR", 0xc0186448 },
+{ "DRM_IOCTL_VIRTGPU_GET_CAPS", 0xc0186449 },
+{ "DRM_IOCTL_RADEON_TEXTURE", 0xc018644e },
+{ "DRM_IOCTL_AMDGPU_GEM_USERPTR", 0xc0186451 },
+{ "DRM_IOCTL_I915_GEM_PIN", 0xc0186455 },
+{ "DRM_IOCTL_RADEON_GEM_INFO", 0xc018645c },
+{ "DRM_IOCTL_RADEON_GEM_VA", 0xc018646b },
+{ "DRM_IOCTL_RADEON_GEM_USERPTR", 0xc018646d },
+{ "DRM_IOCTL_I915_GET_RESET_STATS", 0xc0186472 },
+{ "DRM_IOCTL_I915_GEM_USERPTR", 0xc0186473 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", 0xc0186474 },
+{ "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", 0xc0186475 },
+{ "DRM_IOCTL_MODE_PAGE_FLIP", 0xc01864b0 },
+{ "DRM_IOCTL_MODE_DIRTYFB", 0xc01864b1 },
+{ "DRM_IOCTL_MODE_OBJ_SETPROPERTY", 0xc01864ba },
+{ "I2OPARMSET", 0xc0186903 },
+{ "I2OPARMGET", 0xc0186904 },
+{ "IPMICTL_RECEIVE_MSG_TRUNC", 0xc018690b },
+{ "IPMICTL_RECEIVE_MSG", 0xc018690c },
+{ "RIO_ALLOC_DMA", 0xc0186d13 },
+{ "RIO_TRANSFER", 0xc0186d15 },
+{ "NILFS_IOCTL_GET_VINFO", 0xc0186e86 },
+{ "NILFS_IOCTL_GET_BDESCS", 0xc0186e87 },
+{ "SCIF_SEND", 0xc0187306 },
+{ "SCIF_RECV", 0xc0187307 },
+{ "SCIF_GET_NODEIDS", 0xc018730e },
+{ "TOSH_SMM", 0xc0187490 },
+{ "TOSHIBA_ACPI_SCI", 0xc0187491 },
+{ "AUTOFS_DEV_IOCTL_VERSION", 0xc0189371 },
+{ "AUTOFS_DEV_IOCTL_PROTOVER", 0xc0189372 },
+{ "AUTOFS_DEV_IOCTL_PROTOSUBVER", 0xc0189373 },
+{ "AUTOFS_DEV_IOCTL_OPENMOUNT", 0xc0189374 },
+{ "AUTOFS_DEV_IOCTL_CLOSEMOUNT", 0xc0189375 },
+{ "AUTOFS_DEV_IOCTL_READY", 0xc0189376 },
+{ "AUTOFS_DEV_IOCTL_FAIL", 0xc0189377 },
+{ "AUTOFS_DEV_IOCTL_SETPIPEFD", 0xc0189378 },
+{ "AUTOFS_DEV_IOCTL_CATATONIC", 0xc0189379 },
+{ "AUTOFS_DEV_IOCTL_TIMEOUT", 0xc018937a },
+{ "AUTOFS_DEV_IOCTL_REQUESTER", 0xc018937b },
+{ "AUTOFS_DEV_IOCTL_EXPIRE", 0xc018937c },
+{ "AUTOFS_DEV_IOCTL_ASKUMOUNT", 0xc018937d },
+{ "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", 0xc018937e },
+{ "BTRFS_IOC_FILE_EXTENT_SAME", 0xc0189436 },
+{ "FIDEDUPERANGE", 0xc0189436 },
+{ "UFFDIO_API", 0xc018aa3f },
+{ "KVM_TRANSLATE", 0xc018ae85 },
+{ "IB_USER_MAD_REGISTER_AGENT", 0xc01c1b01 },
+{ "HFI1_IOCTL_ASSIGN_CTXT", 0xc01c1be1 },
+{ "SI4713_IOC_MEASURE_RNL", 0xc01c56c0 },
+{ "DRM_IOCTL_MGA_DMA_BOOTSTRAP", 0xc01c644c },
+{ "DRM_IOCTL_MODE_CURSOR", 0xc01c64a3 },
+{ "DRM_IOCTL_MODE_GETFB", 0xc01c64ad },
+{ "DRM_IOCTL_MODE_ADDFB", 0xc01c64ae },
+{ "I2OSWDL", 0xc01c6905 },
+{ "I2OSWUL", 0xc01c6906 },
+{ "I2OSWDEL", 0xc01c6907 },
+{ "I2OHTML", 0xc01c6909 },
+{ "MEDIA_IOC_ENUM_LINKS", 0xc01c7c02 },
+{ "FW_CDEV_IOC_ALLOCATE", 0xc0202302 },
+{ "FW_CDEV_IOC_CREATE_ISO_CONTEXT", 0xc0202308 },
+{ "AMDKFD_IOC_CREATE_EVENT", 0xc0204b08 },
+{ "ND_IOCTL_ARS_CAP", 0xc0204e01 },
+{ "ND_IOCTL_ARS_START", 0xc0204e02 },
+{ "ND_IOCTL_CLEAR_ERROR", 0xc0204e04 },
+{ "VIDIOC_OMAP3ISP_CCDC_CFG", 0xc02056c1 },
+{ "VIDIOC_OMAP3ISP_AEWB_CFG", 0xc02056c3 },
+{ "VIDIOC_OMAP3ISP_STAT_REQ", 0xc02056c6 },
+{ "SNDRV_RAWMIDI_IOCTL_PARAMS", 0xc0205710 },
+{ "X86_IOC_RDMSR_REGS", 0xc02063a0 },
+{ "X86_IOC_WRMSR_REGS", 0xc02063a1 },
+{ "DRM_IOCTL_AMDGPU_GEM_CREATE", 0xc0206440 },
+{ "DRM_IOCTL_MSM_GEM_SUBMIT", 0xc0206446 },
+{ "DRM_IOCTL_AMDGPU_WAIT_CS", 0xc0206449 },
+{ "DRM_IOCTL_RADEON_GEM_CREATE", 0xc020645d },
+{ "DRM_IOCTL_RADEON_GEM_MMAP", 0xc020645e },
+{ "DRM_IOCTL_RADEON_GEM_PREAD", 0xc0206461 },
+{ "DRM_IOCTL_RADEON_GEM_PWRITE", 0xc0206462 },
+{ "DRM_IOCTL_RADEON_CS", 0xc0206466 },
+{ "DRM_IOCTL_MODE_GETGAMMA", 0xc02064a4 },
+{ "DRM_IOCTL_MODE_SETGAMMA", 0xc02064a5 },
+{ "DRM_IOCTL_MODE_CREATE_DUMB", 0xc02064b2 },
+{ "DRM_IOCTL_MODE_GETPLANE", 0xc02064b6 },
+{ "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", 0xc02064b9 },
+{ "FS_IOC_FIEMAP", 0xc020660b },
+{ "GENWQE_PIN_MEM", 0xc020a528 },
+{ "GENWQE_UNPIN_MEM", 0xc020a529 },
+{ "UFFDIO_REGISTER", 0xc020aa00 },
+{ "UFFDIO_ZEROPAGE", 0xc020aa04 },
+{ "SNDCTL_MIDI_MPUCMD", 0xc0216d02 },
+{ "SNDRV_COMPRESS_GET_METADATA", 0xc0244315 },
+{ "VIDIOC_G_EDID", 0xc0245628 },
+{ "VIDIOC_SUBDEV_G_EDID", 0xc0245628 },
+{ "VIDIOC_SUBDEV_S_EDID", 0xc0245629 },
+{ "VIDIOC_S_EDID", 0xc0245629 },
+{ "DRM_IOCTL_VERSION", 0xc0246400 },
+{ "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", 0xc0246446 },
+{ "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", 0xc0246447 },
+{ "DRM_IOCTL_MODE_CURSOR2", 0xc02464bb },
+{ "NCP_IOC_GET_FS_INFO_V2", 0xc0246e04 },
+{ "IB_USER_MAD_REGISTER_AGENT2", 0xc0281b04 },
+{ "FW_CDEV_IOC_GET_INFO", 0xc0282300 },
+{ "AMDKFD_IOC_GET_CLOCK_COUNTERS", 0xc0284b05 },
+{ "VIDIOC_ENCODER_CMD", 0xc028564d },
+{ "VIDIOC_TRY_ENCODER_CMD", 0xc028564e },
+{ "SW_SYNC_IOC_CREATE_FENCE", 0xc0285700 },
+{ "DRM_IOCTL_DMA", 0xc0286429 },
+{ "DRM_IOCTL_I915_GEM_MMAP", 0xc028645e },
+{ "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", 0xc0286461 },
+{ "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", 0xc0286472 },
+{ "DRM_IOCTL_NOUVEAU_GEM_INFO", 0xc0286484 },
+{ "RIO_MAP_OUTBOUND", 0xc0286d0f },
+{ "RIO_MAP_INBOUND", 0xc0286d11 },
+{ "NCP_IOC_GET_FS_INFO", 0xc0286e04 },
+{ "PHN_GETREGS", 0xc0287007 },
+{ "SCIF_REG", 0xc0287308 },
+{ "SCIF_READFROM", 0xc028730a },
+{ "SCIF_WRITETO", 0xc028730b },
+{ "SCIF_VREADFROM", 0xc028730c },
+{ "SCIF_VWRITETO", 0xc028730d },
+{ "SCIF_FENCE_SIGNAL", 0xc0287311 },
+{ "UFFDIO_COPY", 0xc028aa03 },
+{ "KVM_TPR_ACCESS_REPORTING", 0xc028ae92 },
+{ "FSL_HV_IOCTL_MEMCPY", 0xc028af05 },
+{ "FSL_HV_IOCTL_GETPROP", 0xc028af07 },
+{ "FSL_HV_IOCTL_SETPROP", 0xc028af08 },
+{ "NCP_IOC_GETCHARSETS", 0xc02a6e0b },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", 0xc02c5341 },
+{ "VIDIOC_QUERYMENU", 0xc02c5625 },
+{ "VIDIOC_G_FREQUENCY", 0xc02c5638 },
+{ "VIDIOC_CROPCAP", 0xc02c563a },
+{ "VIDIOC_ENUM_FRAMESIZES", 0xc02c564a },
+{ "DRM_IOCTL_I915_OVERLAY_ATTRS", 0xc02c6468 },
+{ "SYNC_IOC_MERGE", 0xc0303e03 },
+{ "MEMWRITE", 0xc0304d18 },
+{ "ND_IOCTL_ARS_STATUS", 0xc0304e03 },
+{ "SNDRV_SEQ_IOCTL_SYSTEM_INFO", 0xc0305302 },
+{ "VIDIOC_SUBDEV_ENUM_MBUS_CODE", 0xc0305602 },
+{ "VIDIOC_SUBDEV_G_FRAME_INTERVAL", 0xc0305615 },
+{ "VIDIOC_SUBDEV_S_FRAME_INTERVAL", 0xc0305616 },
+{ "VIDIOC_OMAP3ISP_HIST_CFG", 0xc03056c4 },
+{ "SNDRV_RAWMIDI_IOCTL_STATUS", 0xc0305720 },
+{ "BINDER_WRITE_READ", 0xc0306201 },
+{ "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", 0xc0306446 },
+{ "DRM_IOCTL_NOUVEAU_GEM_NEW", 0xc0306480 },
+{ "DRM_IOCTL_MODE_SETPLANE", 0xc03064b7 },
+{ "MBXFB_IOCX_OVERLAY", 0xc030f400 },
+{ "VIDIOC_ENUMAUDIO", 0xc0345641 },
+{ "VIDIOC_ENUMAUDOUT", 0xc0345642 },
+{ "VIDIOC_ENUM_FRAMEINTERVALS", 0xc034564b },
+{ "MEDIA_IOC_SETUP_LINK", 0xc0347c03 },
+{ "SYNC_IOC_FILE_INFO", 0xc0383e04 },
+{ "HIDIOCGFIELDINFO", 0xc038480a },
+{ "VIDIOC_SUBDEV_G_CROP", 0xc038563b },
+{ "VIDIOC_SUBDEV_S_CROP", 0xc038563c },
+{ "VIDIOC_DBG_G_REGISTER", 0xc0385650 },
+{ "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", 0xc0386444 },
+{ "DRM_IOCTL_MODE_ATOMIC", 0xc03864bc },
+{ "BTRFS_IOC_INO_PATHS", 0xc0389423 },
+{ "BTRFS_IOC_LOGICAL_INO", 0xc0389424 },
+{ "GENWQE_SLU_UPDATE", 0xc038a550 },
+{ "GENWQE_SLU_READ", 0xc038a551 },
+{ "VIDIOC_OMAP3ISP_PRV_CFG", 0xc03c56c2 },
+{ "PTP_SYS_OFFSET_PRECISE", 0xc0403d08 },
+{ "CAPI_GET_PROFILE", 0xc0404309 },
+{ "ND_IOCTL_CALL", 0xc0404e0a },
+{ "SNDRV_TIMER_IOCTL_GSTATUS", 0xc0405405 },
+{ "SNDRV_CTL_IOCTL_ELEM_REMOVE", 0xc0405519 },
+{ "VIDIOC_ENUM_FMT", 0xc0405602 },
+{ "VIDIOC_EXPBUF", 0xc0405610 },
+{ "VIDIOC_SUBDEV_G_SELECTION", 0xc040563d },
+{ "VIDIOC_SUBDEV_S_SELECTION", 0xc040563e },
+{ "VIDIOC_SUBDEV_ENUM_FRAME_SIZE", 0xc040564a },
+{ "VIDIOC_SUBDEV_ENUM_FRAME_INTERVAL", 0xc040564b },
+{ "VIDIOC_G_SELECTION", 0xc040565e },
+{ "VIDIOC_S_SELECTION", 0xc040565f },
+{ "VIDIOC_ENUM_FREQ_BANDS", 0xc0405665 },
+{ "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", 0xc0406481 },
+{ "DRM_IOCTL_MODE_GETRESOURCES", 0xc04064a0 },
+{ "DRM_IOCTL_MODE_GETPROPERTY", 0xc04064aa },
+{ "VIDIOC_QUERYCTRL", 0xc0445624 },
+{ "VIDIOC_G_MODULATOR", 0xc0445636 },
+{ "BLKTRACESETUP", 0xc0481273 },
+{ "FBIO_CURSOR", 0xc0484608 },
+{ "SNDRV_EMU10K1_IOCTL_PCM_PEEK", 0xc0484831 },
+{ "NVME_IOCTL_ADMIN_CMD", 0xc0484e41 },
+{ "NVME_IOCTL_IO_CMD", 0xc0484e43 },
+{ "SNDRV_CTL_IOCTL_ELEM_LIST", 0xc0485510 },
+{ "VIDIOC_ENUMSTD", 0xc0485619 },
+{ "VIDIOC_ENUMOUTPUT", 0xc0485630 },
+{ "VIDIOC_DECODER_CMD", 0xc0485660 },
+{ "VIDIOC_TRY_DECODER_CMD", 0xc0485661 },
+{ "DRM_IOCTL_MODE_ATTACHMODE", 0xc04864a8 },
+{ "DRM_IOCTL_MODE_DETACHMODE", 0xc04864a9 },
+{ "VIDEO_COMMAND", 0xc0486f3b },
+{ "VIDEO_TRY_COMMAND", 0xc0486f3c },
+{ "MEDIA_IOC_G_TOPOLOGY", 0xc0487c04 },
+{ "KVM_GET_PIT", 0xc048ae65 },
+{ "MMC_IOC_CMD", 0xc048b300 },
+{ "GPIO_GET_LINEINFO_IOCTL", 0xc048b402 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", 0xc04c5349 },
+{ "VIDIOC_OMAP3ISP_AF_CFG", 0xc04c56c5 },
+{ "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", 0xc0505350 },
+{ "VIDIOC_QUERYBUF", 0xc0505609 },
+{ "VIDIOC_QBUF", 0xc050560f },
+{ "VIDIOC_DQBUF", 0xc0505611 },
+{ "VIDIOC_ENUMINPUT", 0xc050561a },
+{ "VIDIOC_PREPARE_BUF", 0xc050565d },
+{ "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", 0xc0506470 },
+{ "DRM_IOCTL_MODE_GETCONNECTOR", 0xc05064a7 },
+{ "CCISS_PASSTHRU", 0xc054420b },
+{ "VIDIOC_G_TUNER", 0xc054561d },
+{ "SISFB_COMMAND", 0xc054f305 },
+{ "CCISS_BIG_PASSTHRU", 0xc0584212 },
+{ "AMDKFD_IOC_CREATE_QUEUE", 0xc0584b02 },
+{ "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", 0xc058534b },
+{ "SNDRV_SEQ_IOCTL_QUERY_SUBS", 0xc058534f },
+{ "VIDIOC_SUBDEV_G_FMT", 0xc0585604 },
+{ "VIDIOC_SUBDEV_S_FMT", 0xc0585605 },
+{ "DRM_IOCTL_TEGRA_SUBMIT", 0xc0586448 },
+{ "UVCIOC_CTRL_MAP", 0xc0587520 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", 0xc05c5340 },
+{ "PTP_PIN_GETFUNC", 0xc0603d06 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", 0xc0605345 },
+{ "UI_BEGIN_FF_UPLOAD", 0xc06055c8 },
+{ "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", 0xc0606471 },
+{ "DK_CXLFLASH_DETACH", 0xc060ca83 },
+{ "SNDRV_PCM_IOCTL_SW_PARAMS", 0xc0684113 },
+{ "DRM_IOCTL_MODE_GETCRTC", 0xc06864a1 },
+{ "DRM_IOCTL_MODE_SETCRTC", 0xc06864a2 },
+{ "DRM_IOCTL_MODE_ADDFB2", 0xc06864b8 },
+{ "DK_CXLFLASH_RELEASE", 0xc068ca82 },
+{ "DK_CXLFLASH_MANAGE_LUN", 0xc068ca86 },
+{ "BTRFS_IOC_TREE_SEARCH_V2", 0xc0709411 },
+{ "DK_CXLFLASH_USER_DIRECT", 0xc070ca81 },
+{ "DK_CXLFLASH_VLUN_CLONE", 0xc070ca89 },
+{ "SNDCTL_MIDI_INFO", 0xc074510c },
+{ "VIDIOC_G_SLICED_VBI_CAP", 0xc0745645 },
+{ "DK_CXLFLASH_RECOVER_AFU", 0xc078ca85 },
+{ "DK_CXLFLASH_USER_VIRTUAL", 0xc078ca87 },
+{ "DK_CXLFLASH_VLUN_RESIZE", 0xc078ca88 },
+{ "SNDRV_PCM_IOCTL_STATUS_EXT", 0xc0804124 },
+{ "SOUND_MIXER_ACCESS", 0xc0804d66 },
+{ "ND_IOCTL_SMART", 0xc0844e01 },
+{ "VIDIOC_SUBDEV_S_DV_TIMINGS", 0xc0845657 },
+{ "VIDIOC_S_DV_TIMINGS", 0xc0845657 },
+{ "VIDIOC_G_DV_TIMINGS", 0xc0845658 },
+{ "VIDIOC_SUBDEV_G_DV_TIMINGS", 0xc0845658 },
+{ "SNDRV_PCM_IOCTL_SYNC_PTR", 0xc0884123 },
+{ "PPPIOCGCALLINFO", 0xc0887480 },
+{ "SNDCTL_SYNTH_INFO", 0xc08c5102 },
+{ "SNDCTL_SYNTH_ID", 0xc08c5114 },
+{ "SNDRV_SEQ_IOCTL_CREATE_QUEUE", 0xc08c5332 },
+{ "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", 0xc08c5334 },
+{ "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", 0xc08c5335 },
+{ "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", 0xc08c5336 },
+{ "VIDIOC_DV_TIMINGS_CAP", 0xc0905664 },
+{ "VIDIOC_SUBDEV_DV_TIMINGS_CAP", 0xc0905664 },
+{ "DK_CXLFLASH_ATTACH", 0xc090ca80 },
+{ "DK_CXLFLASH_VERIFY", 0xc090ca84 },
+{ "VIDIOC_ENUM_DV_TIMINGS", 0xc0945662 },
+{ "VIDIOC_SUBDEV_ENUM_DV_TIMINGS", 0xc0945662 },
+{ "DRM_IOCTL_VC4_SUBMIT_CL", 0xc0a06440 },
+{ "DRM_IOCTL_VC4_GET_HANG_STATE", 0xc0a06446 },
+{ "SOUND_MIXER_GETLEVELS", 0xc0a44d74 },
+{ "SOUND_MIXER_SETLEVELS", 0xc0a44d75 },
+{ "SNDRV_SEQ_IOCTL_CREATE_PORT", 0xc0a45320 },
+{ "SNDRV_SEQ_IOCTL_GET_PORT_INFO", 0xc0a45322 },
+{ "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", 0xc0a45352 },
+{ "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", 0xc0bc5310 },
+{ "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", 0xc0bc5351 },
+{ "SNDRV_COMPRESS_GET_CAPS", 0xc0c44310 },
+{ "VIDIOC_DBG_G_CHIP_INFO", 0xc0c85666 },
+{ "BTRFS_IOC_SET_RECEIVED_SUBVOL", 0xc0c89425 },
+{ "VIDIOC_G_FMT", 0xc0cc5604 },
+{ "VIDIOC_S_FMT", 0xc0cc5605 },
+{ "VIDIOC_G_PARM", 0xc0cc5615 },
+{ "VIDIOC_S_PARM", 0xc0cc5616 },
+{ "VIDIOC_TRY_FMT", 0xc0cc5640 },
+{ "SNDRV_TIMER_IOCTL_GINFO", 0xc0e05403 },
+{ "VIDIOC_QUERY_EXT_CTRL", 0xc0e85667 },
+{ "GENWQE_EXECUTE_DDCB", 0xc0e8a532 },
+{ "GENWQE_EXECUTE_RAW_DDCB", 0xc0e8a533 },
+{ "VIDIOC_CREATE_BUFS", 0xc0f8565c },
+{ "MEDIA_IOC_DEVICE_INFO", 0xc1007c00 },
+{ "MEDIA_IOC_ENUM_ENTITIES", 0xc1007c01 },
+{ "SNDRV_CTL_IOCTL_RAWMIDI_INFO", 0xc10c5541 },
+{ "SNDRV_CTL_IOCTL_ELEM_INFO", 0xc1105511 },
+{ "SNDRV_CTL_IOCTL_ELEM_ADD", 0xc1105517 },
+{ "SNDRV_CTL_IOCTL_ELEM_REPLACE", 0xc1105518 },
+{ "SNDRV_CTL_IOCTL_PCM_INFO", 0xc1205531 },
+{ "DRM_IOCTL_AMDGPU_GEM_METADATA", 0xc1206446 },
+{ "DM_VERSION", 0xc138fd00 },
+{ "DM_REMOVE_ALL", 0xc138fd01 },
+{ "DM_LIST_DEVICES", 0xc138fd02 },
+{ "DM_DEV_CREATE", 0xc138fd03 },
+{ "DM_DEV_REMOVE", 0xc138fd04 },
+{ "DM_DEV_RENAME", 0xc138fd05 },
+{ "DM_DEV_SUSPEND", 0xc138fd06 },
+{ "DM_DEV_STATUS", 0xc138fd07 },
+{ "DM_DEV_WAIT", 0xc138fd08 },
+{ "DM_TABLE_LOAD", 0xc138fd09 },
+{ "DM_TABLE_CLEAR", 0xc138fd0a },
+{ "DM_TABLE_DEPS", 0xc138fd0b },
+{ "DM_TABLE_STATUS", 0xc138fd0c },
+{ "DM_LIST_VERSIONS", 0xc138fd0d },
+{ "DM_TARGET_MSG", 0xc138fd0e },
+{ "DM_DEV_SET_GEOMETRY", 0xc138fd0f },
+{ "SNDRV_EMU10K1_IOCTL_CODE_PEEK", 0xc18c4812 },
+{ "KVM_GET_IRQCHIP", 0xc208ae62 },
+{ "SNDRV_PCM_IOCTL_HW_REFINE", 0xc25c4110 },
+{ "SNDRV_PCM_IOCTL_HW_PARAMS", 0xc25c4111 },
+{ "SNDRV_CTL_IOCTL_ELEM_READ", 0xc2c85512 },
+{ "SNDRV_CTL_IOCTL_ELEM_WRITE", 0xc2c85513 },
+{ "VIDIOC_VSP1_LUT_CONFIG", 0xc40056c1 },
+{ "BTRFS_IOC_SCRUB", 0xc400941b },
+{ "BTRFS_IOC_SCRUB_PROGRESS", 0xc400941d },
+{ "BTRFS_IOC_BALANCE_V2", 0xc4009420 },
+{ "BTRFS_IOC_GET_DEV_STATS", 0xc4089434 },
+{ "BTRFS_IOC_DEV_REPLACE", 0xca289435 },
+{ "SNDCTL_COPR_SENDMSG", 0xcfa44308 },
+{ "SNDCTL_SYNTH_CONTROL", 0xcfa45115 },
+{ "SNDCTL_COPR_LOAD", 0xcfb04301 },
+{ "NVM_INFO", 0xd0004c20 },
+{ "BTRFS_IOC_TREE_SEARCH", 0xd0009411 },
+{ "BTRFS_IOC_INO_LOOKUP", 0xd0009412 },
+{ "BTRFS_IOC_DEV_INFO", 0xd000941e },
+{ "HIDIOCGUSAGES", 0xd01c4813 },
+{ "SNDRV_COMPRESS_GET_CODEC_CAPS", 0xeb884311 },
diff --git a/strace/ioctlsort.c b/strace/ioctlsort.c
new file mode 100644
index 0000000..9c31691
--- /dev/null
+++ b/strace/ioctlsort.c
@@ -0,0 +1,163 @@
+/*
+ * Copyright (c) 2001 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2004-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <linux/ioctl.h>
+
+struct ioctlent {
+	const char *info;
+	const char *name;
+	unsigned int dir;
+	unsigned int type_nr;
+	unsigned int size;
+};
+
+static int
+is_prefix(const char *s1, const char *s2)
+{
+	size_t len = strlen(s1);
+
+	if (len > strlen(s2))
+		return 0;
+	return !memcmp(s1, s2, len);
+}
+
+static int
+compare_name_info(const void* a, const void* b)
+{
+	int rc;
+
+	const char *name1 = ((struct ioctlent *) a)->name;
+	const char *name2 = ((struct ioctlent *) b)->name;
+	const char *info1 = ((struct ioctlent *) a)->info;
+	const char *info2 = ((struct ioctlent *) b)->info;
+
+	rc = strcmp(name1, name2);
+	if (rc)
+		return rc;
+
+	/*
+	 * exception from lexicographical order:
+	 * "asm/" < "asm-generic/"
+	 */
+	if (is_prefix("asm/", info1) &&
+	    is_prefix("asm-generic/", info2))
+		return -1;
+
+	if (is_prefix("asm/", info2) &&
+	    is_prefix("asm-generic/", info1))
+		return 1;
+
+	return strcmp(info1, info2);
+}
+
+static unsigned int
+code(const struct ioctlent *e)
+{
+	return e->type_nr |
+		(e->size << _IOC_SIZESHIFT) |
+		(e->dir << _IOC_DIRSHIFT);
+}
+
+static int
+compare_code_name(const void* a, const void* b)
+{
+	unsigned int code1 = code((struct ioctlent *) a);
+	unsigned int code2 = code((struct ioctlent *) b);
+	const char *name1 = ((struct ioctlent *) a)->name;
+	const char *name2 = ((struct ioctlent *) b)->name;
+	return (code1 > code2) ?
+		1 : (code1 < code2) ? -1 : strcmp(name1, name2);
+}
+
+static void
+ioctlsort(struct ioctlent *ioctls, size_t nioctls)
+{
+	size_t i;
+
+	qsort(ioctls, nioctls, sizeof(ioctls[0]), compare_name_info);
+
+	for (i = 1; i < nioctls; ++i)
+		if (!strcmp(ioctls[i-1].name, ioctls[i].name)) {
+			/*
+			 * If there are multiple definitions for the same
+			 * name, keep the first one and mark all the rest
+			 * for deletion.
+			 */
+			ioctls[i].info = NULL;
+		}
+
+	for (i = 1; i < nioctls; ++i)
+		if (!ioctls[i].info) {
+			/*
+			 * Change ioctl code of marked elements
+			 * to make them sorted to the end of array.
+			 */
+			ioctls[i].dir =
+			ioctls[i].type_nr =
+			ioctls[i].size = 0xffffffffu;
+		}
+
+	qsort(ioctls, nioctls, sizeof(ioctls[0]), compare_code_name);
+
+	puts("/* Generated by ioctlsort. */");
+	for (i = 0; i < nioctls; ++i) {
+		if (!ioctls[i].info) {
+			/*
+			 * We've reached the first element marked for deletion.
+			 */
+			break;
+		}
+		if (i == 0 || code(&ioctls[i-1]) != code(&ioctls[i]) ||
+		    !is_prefix(ioctls[i-1].name, ioctls[i].name))
+			printf("{ \"%s\", %#010x },\n",
+				ioctls[i].name, code(ioctls+i));
+	}
+}
+
+static struct ioctlent ioctls[] = {
+#ifdef IOCTLSORT_INC
+# include IOCTLSORT_INC
+#else
+# include "ioctls_arch.h"
+# include "ioctls_inc.h"
+#endif
+};
+
+int
+main(void)
+{
+	ioctlsort(ioctls, sizeof(ioctls) / sizeof(ioctls[0]));
+	return 0;
+}
diff --git a/strace/ioperm.c b/strace/ioperm.c
new file mode 100644
index 0000000..1a92a26
--- /dev/null
+++ b/strace/ioperm.c
@@ -0,0 +1,9 @@
+#include "defs.h"
+
+SYS_FUNC(ioperm)
+{
+	tprintf("%#lx, %#lx, %d",
+		tcp->u_arg[0], tcp->u_arg[1], (int) tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/iopl.c b/strace/iopl.c
new file mode 100644
index 0000000..0f2bb32
--- /dev/null
+++ b/strace/iopl.c
@@ -0,0 +1,8 @@
+#include "defs.h"
+
+SYS_FUNC(iopl)
+{
+	tprintf("%d", (int) tcp->u_arg[0]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ioprio.c b/strace/ioprio.c
new file mode 100644
index 0000000..0b83be7
--- /dev/null
+++ b/strace/ioprio.c
@@ -0,0 +1,99 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+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)
+#define IOPRIO_PRIO_MASK	((1ul << IOPRIO_CLASS_SHIFT) - 1)
+
+#define IOPRIO_PRIO_CLASS(mask)	((mask) >> IOPRIO_CLASS_SHIFT)
+#define IOPRIO_PRIO_DATA(mask)	((mask) & IOPRIO_PRIO_MASK)
+
+static const char *
+sprint_ioprio(unsigned int ioprio)
+{
+	static char outstr[256];
+	const char *str;
+	unsigned int class, data;
+
+	class = IOPRIO_PRIO_CLASS(ioprio);
+	data = IOPRIO_PRIO_DATA(ioprio);
+	str = xlookup(ioprio_class, class);
+	if (str)
+		sprintf(outstr, "IOPRIO_PRIO_VALUE(%s, %d)", str, data);
+	else
+		sprintf(outstr, "IOPRIO_PRIO_VALUE(%#x /* %s */, %d)",
+			class, "IOPRIO_CLASS_???", data);
+
+	return outstr;
+}
+
+SYS_FUNC(ioprio_get)
+{
+	if (entering(tcp)) {
+		/* int which */
+		printxval(ioprio_who, tcp->u_arg[0], "IOPRIO_WHO_???");
+		/* int who */
+		tprintf(", %d", (int) tcp->u_arg[1]);
+		return 0;
+	} else {
+		if (syserror(tcp))
+			return 0;
+
+		tcp->auxstr = sprint_ioprio(tcp->u_rval);
+		return RVAL_STR;
+	}
+}
+
+SYS_FUNC(ioprio_set)
+{
+	/* int which */
+	printxval(ioprio_who, tcp->u_arg[0], "IOPRIO_WHO_???");
+	/* int who */
+	tprintf(", %d, ", (int) tcp->u_arg[1]);
+	/* int ioprio */
+	tprints(sprint_ioprio(tcp->u_arg[2]));
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ipc.c b/strace/ipc.c
new file mode 100644
index 0000000..00a9d0d
--- /dev/null
+++ b/strace/ipc.c
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/ipccalls.h"
+
+SYS_FUNC(ipc)
+{
+	unsigned int call = tcp->u_arg[0];
+	unsigned int version = call >> 16;
+	call &= 0xffff;
+	const char *str = xlookup(ipccalls, call);
+
+	if (version)
+		tprintf("%u<<16|", version);
+
+	if (str)
+		tprints(str);
+	else
+		tprintf("%u", call);
+
+	unsigned int i;
+	for (i = 1; i < tcp->s_ent->nargs; ++i)
+		tprintf(", %#lx", tcp->u_arg[i]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ipc_defs.h b/strace/ipc_defs.h
new file mode 100644
index 0000000..b6c85c1
--- /dev/null
+++ b/strace/ipc_defs.h
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2003 Roland McGrath <roland@redhat.com>
+ * 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.
+ */
+
+#ifdef HAVE_SYS_IPC_H
+# include <sys/ipc.h>
+#elif defined HAVE_LINUX_IPC_H
+# include <linux/ipc.h>
+/* While glibc uses __key, the kernel uses key. */
+# define __key key
+#endif
+
+#if !defined IPC_64
+# define IPC_64 0x100
+#endif
+
+#define PRINTCTL(flagset, arg, dflt) \
+	if ((arg) & IPC_64) tprints("IPC_64|"); \
+	printxval((flagset), (arg) &~ IPC_64, dflt)
diff --git a/strace/ipc_msg.c b/strace/ipc_msg.c
new file mode 100644
index 0000000..daa0036
--- /dev/null
+++ b/strace/ipc_msg.c
@@ -0,0 +1,134 @@
+/*
+ * Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2006 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "ipc_defs.h"
+
+#ifdef HAVE_SYS_MSG_H
+# include <sys/msg.h>
+#elif defined HAVE_LINUX_MSG_H
+# include <linux/msg.h>
+#endif
+
+#include "xlat/ipc_msg_flags.h"
+#include "xlat/resource_flags.h"
+
+SYS_FUNC(msgget)
+{
+	if (tcp->u_arg[0])
+		tprintf("%#lx, ", tcp->u_arg[0]);
+	else
+		tprints("IPC_PRIVATE, ");
+	if (printflags(resource_flags, tcp->u_arg[1] & ~0777, NULL) != 0)
+		tprints("|");
+	tprintf("%#lo", tcp->u_arg[1] & 0777);
+	return RVAL_DECODED;
+}
+
+static void
+tprint_msgsnd(struct tcb *tcp, const long addr, const unsigned long count,
+	      const unsigned long flags)
+{
+	tprint_msgbuf(tcp, addr, count);
+	printflags(ipc_msg_flags, flags, "MSG_???");
+}
+
+SYS_FUNC(msgsnd)
+{
+	tprintf("%d, ", (int) tcp->u_arg[0]);
+	if (indirect_ipccall(tcp)) {
+		tprint_msgsnd(tcp, tcp->u_arg[3], tcp->u_arg[1],
+			      tcp->u_arg[2]);
+	} else {
+		tprint_msgsnd(tcp, tcp->u_arg[1], tcp->u_arg[2],
+			      tcp->u_arg[3]);
+	}
+	return RVAL_DECODED;
+}
+
+static void
+tprint_msgrcv(struct tcb *tcp, const long addr, const unsigned long count,
+	      const long msgtyp)
+{
+	tprint_msgbuf(tcp, addr, count);
+	tprintf("%ld, ", msgtyp);
+}
+
+static int
+fetch_msgrcv_args(struct tcb *tcp, const long addr, unsigned long *pair)
+{
+	if (current_wordsize == sizeof(*pair)) {
+		if (umoven_or_printaddr(tcp, addr, 2 * sizeof(*pair), pair))
+			return -1;
+	} else {
+		unsigned int tmp[2];
+
+		if (umove_or_printaddr(tcp, addr, &tmp))
+			return -1;
+		pair[0] = tmp[0];
+		pair[1] = tmp[1];
+	}
+	return 0;
+}
+
+SYS_FUNC(msgrcv)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+	} else {
+		if (indirect_ipccall(tcp)) {
+			const bool direct =
+#ifdef SPARC64
+				current_wordsize == 8 ||
+#endif
+				get_tcb_priv_ulong(tcp) != 0;
+			if (direct) {
+				tprint_msgrcv(tcp, tcp->u_arg[3],
+					      tcp->u_arg[1], tcp->u_arg[4]);
+			} else {
+				unsigned long pair[2];
+
+				if (fetch_msgrcv_args(tcp, tcp->u_arg[3], pair))
+					tprintf(", %lu, ", tcp->u_arg[1]);
+				else
+					tprint_msgrcv(tcp, pair[0],
+						      tcp->u_arg[1], pair[1]);
+			}
+			printflags(ipc_msg_flags, tcp->u_arg[2], "MSG_???");
+		} else {
+			tprint_msgrcv(tcp, tcp->u_arg[1],
+				tcp->u_arg[2], tcp->u_arg[3]);
+			printflags(ipc_msg_flags, tcp->u_arg[4], "MSG_???");
+		}
+	}
+	return 0;
+}
diff --git a/strace/ipc_msgctl.c b/strace/ipc_msgctl.c
new file mode 100644
index 0000000..e46f6e2
--- /dev/null
+++ b/strace/ipc_msgctl.c
@@ -0,0 +1,108 @@
+/*
+ * Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2006 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(msqid_ds_t)
+
+#include "ipc_defs.h"
+
+#ifdef HAVE_SYS_MSG_H
+/* The C library generally exports the struct the current kernel expects. */
+# include <sys/msg.h>
+typedef struct msqid_ds msqid_ds_t;
+#elif defined HAVE_LINUX_MSG_H
+/* The linux header might provide the right struct. */
+# include <linux/msg.h>
+typedef struct msqid64_ds msqid_ds_t;
+#endif
+
+#include MPERS_DEFS
+
+#include "xlat/msgctl_flags.h"
+
+static void
+print_msqid_ds(struct tcb *tcp, const long addr, int cmd)
+{
+	/* TODO: We don't properly decode old compat ipc calls. */
+	if (cmd & IPC_64)
+		cmd &= ~IPC_64;
+	msqid_ds_t msqid_ds;
+	switch (cmd) {
+	case IPC_SET:
+	case IPC_STAT:
+		if (umove_or_printaddr(tcp, addr, &msqid_ds))
+			return;
+
+		tprints("{msg_perm={");
+		printuid("uid=", msqid_ds.msg_perm.uid);
+		printuid(", gid=", msqid_ds.msg_perm.gid);
+		tprints(", mode=");
+		tprints(sprintmode(msqid_ds.msg_perm.mode));
+
+		if (cmd != IPC_STAT) {
+			tprints("}, ...}");
+			break;
+		}
+
+		tprintf(", key=%u", (unsigned) msqid_ds.msg_perm.__key);
+		printuid(", cuid=", msqid_ds.msg_perm.cuid);
+		printuid(", cgid=", msqid_ds.msg_perm.cgid);
+		tprints("}");
+		tprintf(", msg_stime=%u", (unsigned) msqid_ds.msg_stime);
+		tprintf(", msg_rtime=%u", (unsigned) msqid_ds.msg_rtime);
+		tprintf(", msg_ctime=%u", (unsigned) msqid_ds.msg_ctime);
+		tprintf(", msg_qnum=%u", (unsigned) msqid_ds.msg_qnum);
+		tprintf(", msg_qbytes=%u", (unsigned) msqid_ds.msg_qbytes);
+		tprintf(", msg_lspid=%u", (unsigned) msqid_ds.msg_lspid);
+		tprintf(", msg_lrpid=%u", (unsigned) msqid_ds.msg_lrpid);
+		tprints("}");
+		break;
+
+	default:
+		printaddr(addr);
+		break;
+	}
+}
+
+SYS_FUNC(msgctl)
+{
+	if (entering(tcp)) {
+		tprintf("%lu, ", tcp->u_arg[0]);
+		PRINTCTL(msgctl_flags, tcp->u_arg[1], "MSG_???");
+		tprints(", ");
+	} else {
+		const long addr = tcp->u_arg[indirect_ipccall(tcp) ? 3 : 2];
+		print_msqid_ds(tcp, addr, tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/ipc_sem.c b/strace/ipc_sem.c
new file mode 100644
index 0000000..ba21b7b
--- /dev/null
+++ b/strace/ipc_sem.c
@@ -0,0 +1,126 @@
+/*
+ * Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2006 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "ipc_defs.h"
+
+#ifdef HAVE_SYS_SEM_H
+# include <sys/sem.h>
+#elif defined HAVE_LINUX_SEM_H
+# include <linux/sem.h>
+#endif
+
+#include "xlat/semctl_flags.h"
+#include "xlat/semop_flags.h"
+
+#if defined HAVE_SYS_SEM_H || defined HAVE_LINUX_SEM_H
+static bool
+print_sembuf(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const struct sembuf *sb = elem_buf;
+
+	tprintf("{%u, %d, ", sb->sem_num, sb->sem_op);
+	printflags(semop_flags, (unsigned short) sb->sem_flg, "SEM_???");
+	tprints("}");
+
+	return true;
+}
+#endif
+
+static void
+tprint_sembuf_array(struct tcb *tcp, const long addr, const unsigned long count)
+{
+#if defined HAVE_SYS_SEM_H || defined HAVE_LINUX_SEM_H
+	struct sembuf sb;
+	print_array(tcp, addr, count, &sb, sizeof(sb),
+		    umoven_or_printaddr, print_sembuf, 0);
+#else
+	printaddr(addr);
+#endif
+	tprintf(", %lu", count);
+}
+
+SYS_FUNC(semop)
+{
+	tprintf("%lu, ", tcp->u_arg[0]);
+	if (indirect_ipccall(tcp)) {
+		tprint_sembuf_array(tcp, tcp->u_arg[3], tcp->u_arg[1]);
+	} else {
+		tprint_sembuf_array(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	}
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(semtimedop)
+{
+	tprintf("%lu, ", tcp->u_arg[0]);
+	if (indirect_ipccall(tcp)) {
+		tprint_sembuf_array(tcp, tcp->u_arg[3], tcp->u_arg[1]);
+		tprints(", ");
+#if defined(S390) || defined(S390X)
+		print_timespec(tcp, tcp->u_arg[2]);
+#else
+		print_timespec(tcp, tcp->u_arg[4]);
+#endif
+	} else {
+		tprint_sembuf_array(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		tprints(", ");
+		print_timespec(tcp, tcp->u_arg[3]);
+	}
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(semget)
+{
+	if (tcp->u_arg[0])
+		tprintf("%#lx", tcp->u_arg[0]);
+	else
+		tprints("IPC_PRIVATE");
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	if (printflags(resource_flags, tcp->u_arg[2] & ~0777, NULL) != 0)
+		tprints("|");
+	tprintf("%#lo", tcp->u_arg[2] & 0777);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(semctl)
+{
+	tprintf("%lu, %lu, ", tcp->u_arg[0], tcp->u_arg[1]);
+	PRINTCTL(semctl_flags, tcp->u_arg[2], "SEM_???");
+	tprints(", ");
+	if (indirect_ipccall(tcp)) {
+		printnum_ptr(tcp, tcp->u_arg[3]);
+	} else {
+		tprintf("%#lx", tcp->u_arg[3]);
+	}
+	return RVAL_DECODED;
+}
diff --git a/strace/ipc_shm.c b/strace/ipc_shm.c
new file mode 100644
index 0000000..c418884
--- /dev/null
+++ b/strace/ipc_shm.c
@@ -0,0 +1,88 @@
+/*
+ * Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2006 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_SYS_SHM_H
+# include <sys/shm.h>
+#elif defined HAVE_LINUX_SHM_H
+# include <linux/shm.h>
+#endif
+
+#include "xlat/shm_resource_flags.h"
+#include "xlat/shm_flags.h"
+
+SYS_FUNC(shmget)
+{
+	if (tcp->u_arg[0])
+		tprintf("%#lx", tcp->u_arg[0]);
+	else
+		tprints("IPC_PRIVATE");
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	if (printflags(shm_resource_flags, tcp->u_arg[2] & ~0777, NULL) != 0)
+		tprints("|");
+	tprintf("%#lo", tcp->u_arg[2] & 0777);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(shmat)
+{
+	if (entering(tcp)) {
+		tprintf("%lu, ", tcp->u_arg[0]);
+		if (indirect_ipccall(tcp)) {
+			printaddr(tcp->u_arg[3]);
+			tprints(", ");
+			printflags(shm_flags, tcp->u_arg[1], "SHM_???");
+		} else {
+			printaddr(tcp->u_arg[1]);
+			tprints(", ");
+			printflags(shm_flags, tcp->u_arg[2], "SHM_???");
+		}
+		return 0;
+	} else {
+		if (syserror(tcp))
+			return 0;
+		if (indirect_ipccall(tcp)) {
+			unsigned long raddr;
+			if (umove(tcp, tcp->u_arg[2], &raddr) < 0)
+				return RVAL_NONE;
+			tcp->u_rval = raddr;
+		}
+		return RVAL_HEX;
+	}
+}
+
+SYS_FUNC(shmdt)
+{
+	printaddr(tcp->u_arg[indirect_ipccall(tcp) ? 3 : 0]);
+	return RVAL_DECODED;
+}
diff --git a/strace/ipc_shmctl.c b/strace/ipc_shmctl.c
new file mode 100644
index 0000000..3498455
--- /dev/null
+++ b/strace/ipc_shmctl.c
@@ -0,0 +1,108 @@
+/*
+ * Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2006 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(shmid_ds_t)
+
+#include "ipc_defs.h"
+
+#ifdef HAVE_SYS_SHM_H
+/* The C library generally exports the struct the current kernel expects. */
+# include <sys/shm.h>
+typedef struct shmid_ds shmid_ds_t;
+#elif defined HAVE_LINUX_SHM_H
+/* The linux header might provide the right struct. */
+# include <linux/shm.h>
+typedef struct shmid64_ds shmid_ds_t;
+#endif
+
+#include MPERS_DEFS
+
+#include "xlat/shmctl_flags.h"
+
+static void
+print_shmid_ds(struct tcb *tcp, const long addr, int cmd)
+{
+	/* TODO: We don't properly decode old compat ipc calls. */
+	if (cmd & IPC_64)
+		cmd &= ~IPC_64;
+	shmid_ds_t shmid_ds;
+	switch (cmd) {
+	case IPC_SET:
+	case IPC_STAT:
+		if (umove_or_printaddr(tcp, addr, &shmid_ds))
+			return;
+
+		tprints("{shm_perm={");
+		printuid("uid=", shmid_ds.shm_perm.uid);
+		printuid(", gid=", shmid_ds.shm_perm.gid);
+		tprints(", mode=");
+		tprints(sprintmode(shmid_ds.shm_perm.mode));
+
+		if (cmd != IPC_STAT) {
+			tprints("}, ...}");
+			break;
+		}
+
+		tprintf(", key=%u", (unsigned) shmid_ds.shm_perm.__key);
+		printuid(", cuid=", shmid_ds.shm_perm.cuid);
+		printuid(", cgid=", shmid_ds.shm_perm.cgid);
+		tprints("}");
+		tprintf(", shm_segsz=%u", (unsigned) shmid_ds.shm_segsz);
+		tprintf(", shm_cpid=%u", (unsigned) shmid_ds.shm_cpid);
+		tprintf(", shm_lpid=%u", (unsigned) shmid_ds.shm_lpid);
+		tprintf(", shm_nattch=%u", (unsigned) shmid_ds.shm_nattch);
+		tprintf(", shm_atime=%u", (unsigned) shmid_ds.shm_atime);
+		tprintf(", shm_dtime=%u", (unsigned) shmid_ds.shm_dtime);
+		tprintf(", shm_ctime=%u", (unsigned) shmid_ds.shm_ctime);
+		tprints("}");
+		break;
+
+	default:
+		printaddr(addr);
+		break;
+	}
+}
+
+SYS_FUNC(shmctl)
+{
+	if (entering(tcp)) {
+		tprintf("%lu, ", tcp->u_arg[0]);
+		PRINTCTL(shmctl_flags, tcp->u_arg[1], "SHM_???");
+		tprints(", ");
+	} else {
+		const long addr = tcp->u_arg[indirect_ipccall(tcp) ? 3 : 2];
+		print_shmid_ds(tcp, addr, tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/kcmp.c b/strace/kcmp.c
new file mode 100644
index 0000000..aec494a
--- /dev/null
+++ b/strace/kcmp.c
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/kcmp_types.h"
+
+SYS_FUNC(kcmp)
+{
+	pid_t pid1 = tcp->u_arg[0];
+	pid_t pid2 = tcp->u_arg[1];
+	int type = tcp->u_arg[2];
+	unsigned long idx1 = tcp->u_arg[3];
+	unsigned long idx2 = tcp->u_arg[4];
+
+	tprintf("%d, %d, ", pid1, pid2);
+	printxval(kcmp_types, type, "KCMP_???");
+
+	switch(type) {
+		case KCMP_FILE:
+			tprintf(", %u, %u", (unsigned) idx1, (unsigned) idx2);
+			break;
+		case KCMP_FILES:
+		case KCMP_FS:
+		case KCMP_IO:
+		case KCMP_SIGHAND:
+		case KCMP_SYSVSEM:
+		case KCMP_VM:
+			break;
+		default:
+			tprintf(", %#lx, %#lx", idx1, idx2);
+	}
+
+	return RVAL_DECODED;
+}
diff --git a/strace/kernel_types.h b/strace/kernel_types.h
new file mode 100644
index 0000000..3dee761
--- /dev/null
+++ b/strace/kernel_types.h
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef STRACE_KERNEL_TYPES_H
+
+# define STRACE_KERNEL_TYPES_H
+
+# if defined HAVE___KERNEL_LONG_T && defined HAVE___KERNEL_ULONG_T
+
+# include <asm/posix_types.h>
+
+typedef __kernel_long_t kernel_long_t;
+typedef __kernel_ulong_t kernel_ulong_t;
+
+# elif defined __x86_64__ && defined __ILP32__
+
+typedef long long kernel_long_t;
+typedef unsigned long long kernel_ulong_t;
+
+# else
+
+typedef long kernel_long_t;
+typedef unsigned long kernel_ulong_t;
+
+# endif
+
+typedef struct {
+	kernel_ulong_t	d_ino;
+	kernel_ulong_t	d_off;
+	unsigned short	d_reclen;
+	char		d_name[1];
+} kernel_dirent;
+
+#endif
diff --git a/strace/kexec.c b/strace/kexec.c
new file mode 100644
index 0000000..128b1df
--- /dev/null
+++ b/strace/kexec.c
@@ -0,0 +1,122 @@
+/*
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/kexec_load_flags.h"
+#include "xlat/kexec_arch_values.h"
+
+#ifndef KEXEC_ARCH_MASK
+# define KEXEC_ARCH_MASK 0xffff0000
+#endif
+#ifndef KEXEC_SEGMENT_MAX
+# define KEXEC_SEGMENT_MAX 16
+#endif
+
+static bool
+print_seg(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const unsigned long *seg;
+	unsigned long seg_buf[4];
+
+        if (elem_size < sizeof(seg_buf)) {
+		unsigned int i;
+
+		for (i = 0; i < ARRAY_SIZE(seg_buf); ++i)
+			seg_buf[i] = ((unsigned int *) elem_buf)[i];
+		seg = seg_buf;
+	} else {
+		seg = elem_buf;
+	}
+
+	tprints("{");
+	printaddr(seg[0]);
+	tprintf(", %lu, ", seg[1]);
+	printaddr(seg[2]);
+	tprintf(", %lu}", seg[3]);
+
+	return true;
+}
+
+static void
+print_kexec_segments(struct tcb *tcp, const unsigned long addr,
+		     const unsigned long len)
+{
+	if (len > KEXEC_SEGMENT_MAX) {
+		printaddr(addr);
+		return;
+	}
+
+	unsigned long seg[4];
+	const size_t sizeof_seg = ARRAY_SIZE(seg) * current_wordsize;
+
+	print_array(tcp, addr, len, seg, sizeof_seg,
+		    umoven_or_printaddr, print_seg, 0);
+}
+
+SYS_FUNC(kexec_load)
+{
+	/* entry, nr_segments */
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, ", tcp->u_arg[1]);
+
+	/* segments */
+	print_kexec_segments(tcp, tcp->u_arg[2], tcp->u_arg[1]);
+	tprints(", ");
+
+	/* flags */
+	unsigned long n = tcp->u_arg[3];
+	printxval_long(kexec_arch_values, n & KEXEC_ARCH_MASK, "KEXEC_ARCH_???");
+	n &= ~KEXEC_ARCH_MASK;
+	if (n) {
+		tprints("|");
+		printflags_long(kexec_load_flags, n, "KEXEC_???");
+	}
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/kexec_file_load_flags.h"
+
+SYS_FUNC(kexec_file_load)
+{
+	/* kernel_fd */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* initrd_fd */
+	printfd(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	/* cmdline_len */
+	tprintf("%lu, ", tcp->u_arg[2]);
+	/* cmdline */
+	printstr(tcp, tcp->u_arg[3], tcp->u_arg[2]);
+	tprints(", ");
+	/* flags */
+	printflags_long(kexec_file_load_flags, tcp->u_arg[4], "KEXEC_FILE_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/keyctl.c b/strace/keyctl.c
new file mode 100644
index 0000000..456649e
--- /dev/null
+++ b/strace/keyctl.c
@@ -0,0 +1,309 @@
+/*
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+typedef int32_t key_serial_t;
+
+#include "xlat/key_spec.h"
+
+static void
+print_keyring_serial_number(key_serial_t id)
+{
+	const char *str = xlookup(key_spec, (unsigned int) id);
+
+	if (str)
+		tprints(str);
+	else
+		tprintf("%d", id);
+}
+
+SYS_FUNC(add_key)
+{
+	/* type */
+	printstr(tcp, tcp->u_arg[0], -1);
+	/* description */
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], -1);
+	/* payload */
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[2], tcp->u_arg[3]);
+	/* payload length */
+	tprintf(", %lu, ", tcp->u_arg[3]);
+	/* keyring serial number */
+	print_keyring_serial_number(tcp->u_arg[4]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(request_key)
+{
+	/* type */
+	printstr(tcp, tcp->u_arg[0], -1);
+	/* description */
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], -1);
+	/* callout_info */
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[2], -1);
+	/* keyring serial number */
+	tprints(", ");
+	print_keyring_serial_number(tcp->u_arg[3]);
+
+	return RVAL_DECODED;
+}
+
+static void
+keyctl_get_keyring_id(struct tcb *tcp, key_serial_t id, int create)
+{
+	print_keyring_serial_number(id);
+	tprintf(", %d", create);
+}
+
+static void
+keyctl_update_key(struct tcb *tcp, key_serial_t id, long addr, long len)
+{
+	print_keyring_serial_number(id);
+	tprints(", ");
+	printstr(tcp, addr, len);
+	tprintf(", %lu", len);
+}
+
+static void
+keyctl_handle_key_key(struct tcb *tcp, key_serial_t id1, key_serial_t id2)
+{
+	print_keyring_serial_number(id1);
+	tprints(", ");
+	print_keyring_serial_number(id2);
+}
+
+static void
+keyctl_read_key(struct tcb *tcp, key_serial_t id, long addr, long len)
+{
+	if (entering(tcp)) {
+		print_keyring_serial_number(id);
+		tprints(", ");
+	} else {
+		if (syserror(tcp))
+			printaddr(addr);
+		else {
+			long rval = tcp->u_rval > len ?
+				    len : (tcp->u_rval ? -1 : 0);
+			printstr(tcp, addr, rval);
+		}
+		tprintf(", %lu", len);
+	}
+}
+
+static void
+keyctl_keyring_search(struct tcb *tcp, key_serial_t id1, long addr1,
+		      long addr2, key_serial_t id2)
+{
+	print_keyring_serial_number(id1);
+	tprints(", ");
+	printstr(tcp, addr1, -1);
+	tprints(", ");
+	printstr(tcp, addr2, -1);
+	tprints(", ");
+	print_keyring_serial_number(id2);
+}
+
+static void
+keyctl_chown_key(struct tcb *tcp, key_serial_t id, int user, int group)
+{
+	print_keyring_serial_number(id);
+	tprintf(", %d, %d", user, group);
+}
+
+static void
+keyctl_instantiate_key(struct tcb *tcp, key_serial_t id1, long addr,
+		       long len, key_serial_t id2)
+{
+	print_keyring_serial_number(id1);
+	tprints(", ");
+	printstr(tcp, addr, len);
+	tprintf(", %lu, ", len);
+	print_keyring_serial_number(id2);
+}
+
+static void
+keyctl_instantiate_key_iov(struct tcb *tcp, key_serial_t id1,
+			   long addr, long len, key_serial_t id2)
+{
+	print_keyring_serial_number(id1);
+	tprints(", ");
+	tprint_iov(tcp, len, addr, IOV_DECODE_STR);
+	tprintf(", %lu, ", len);
+	print_keyring_serial_number(id2);
+}
+
+static void
+keyctl_negate_key(struct tcb *tcp, key_serial_t id1, unsigned timeout,
+		  key_serial_t id2)
+{
+	print_keyring_serial_number(id1);
+	tprintf(", %u, ", timeout);
+	print_keyring_serial_number(id2);
+}
+
+static void
+keyctl_reject_key(struct tcb *tcp, key_serial_t id1, unsigned timeout,
+		  unsigned error, key_serial_t id2)
+{
+	print_keyring_serial_number(id1);
+	tprintf(", %u, %u, ", timeout, error);
+	print_keyring_serial_number(id2);
+}
+
+static void
+keyctl_set_timeout(struct tcb *tcp, key_serial_t id, unsigned timeout)
+{
+	print_keyring_serial_number(id);
+	tprintf(", %u", timeout);
+}
+
+static void
+keyctl_get_persistent(struct tcb *tcp, int uid, key_serial_t id)
+{
+	tprintf("%d, ", uid);
+	print_keyring_serial_number(id);
+}
+
+#include "xlat/key_perms.h"
+
+static void
+keyctl_setperm_key(struct tcb *tcp, key_serial_t id, uint32_t perm)
+{
+	print_keyring_serial_number(id);
+	tprints(", ");
+	printflags(key_perms, perm, "KEY_???");
+}
+
+#include "xlat/key_reqkeys.h"
+#include "xlat/keyctl_commands.h"
+
+SYS_FUNC(keyctl)
+{
+	int cmd = tcp->u_arg[0];
+
+	if (entering(tcp)) {
+		printxval(keyctl_commands, cmd, "KEYCTL_???");
+		tprints(", ");
+	}
+
+	switch (cmd) {
+	case KEYCTL_GET_KEYRING_ID:
+		keyctl_get_keyring_id(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+
+	case KEYCTL_JOIN_SESSION_KEYRING:
+		printstr(tcp, tcp->u_arg[1], -1);
+		break;
+
+	case KEYCTL_UPDATE:
+		keyctl_update_key(tcp, tcp->u_arg[1],
+				  tcp->u_arg[2], tcp->u_arg[3]);
+		break;
+
+	case KEYCTL_REVOKE:
+	case KEYCTL_CLEAR:
+	case KEYCTL_INVALIDATE:
+	case KEYCTL_ASSUME_AUTHORITY:
+		print_keyring_serial_number(tcp->u_arg[1]);
+		break;
+
+	case KEYCTL_LINK:
+	case KEYCTL_UNLINK:
+		keyctl_handle_key_key(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+
+	case KEYCTL_DESCRIBE:
+	case KEYCTL_READ:
+	case KEYCTL_GET_SECURITY:
+		keyctl_read_key(tcp, tcp->u_arg[1],
+				tcp->u_arg[2], tcp->u_arg[3]);
+		return 0;
+
+	case KEYCTL_SEARCH:
+		keyctl_keyring_search(tcp, tcp->u_arg[1], tcp->u_arg[2],
+				      tcp->u_arg[3], tcp->u_arg[4]);
+		break;
+
+	case KEYCTL_CHOWN:
+		keyctl_chown_key(tcp, tcp->u_arg[1],
+				 tcp->u_arg[2], tcp->u_arg[3]);
+		break;
+
+	case KEYCTL_SETPERM:
+		keyctl_setperm_key(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+
+	case KEYCTL_INSTANTIATE:
+		keyctl_instantiate_key(tcp, tcp->u_arg[1], tcp->u_arg[2],
+				       tcp->u_arg[3], tcp->u_arg[4]);
+		break;
+
+	case KEYCTL_NEGATE:
+		keyctl_negate_key(tcp, tcp->u_arg[1],
+				  tcp->u_arg[2], tcp->u_arg[3]);
+		break;
+
+	case KEYCTL_SET_REQKEY_KEYRING:
+		printxval(key_reqkeys, tcp->u_arg[1], "KEY_REQKEY_DEFL_???");
+		break;
+
+	case KEYCTL_SET_TIMEOUT:
+		keyctl_set_timeout(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+
+	case KEYCTL_SESSION_TO_PARENT:
+		break;
+
+	case KEYCTL_REJECT:
+		keyctl_reject_key(tcp, tcp->u_arg[1], tcp->u_arg[2],
+				  tcp->u_arg[3], tcp->u_arg[4]);
+		break;
+
+	case KEYCTL_INSTANTIATE_IOV:
+		keyctl_instantiate_key_iov(tcp, tcp->u_arg[1],
+					   tcp->u_arg[2], tcp->u_arg[3],
+					   tcp->u_arg[4]);
+		break;
+
+	case KEYCTL_GET_PERSISTENT:
+		keyctl_get_persistent(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+
+	default:
+		tprintf("%#lx, %#lx, %#lx, %#lx",
+			tcp->u_arg[1], tcp->u_arg[2],
+			tcp->u_arg[3], tcp->u_arg[4]);
+		break;
+	}
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ldt.c b/strace/ldt.c
new file mode 100644
index 0000000..7d5c7bf
--- /dev/null
+++ b/strace/ldt.c
@@ -0,0 +1,125 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2002-2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2010 Andreas Schwab <schwab@linux-m68k.org>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#if defined I386 || defined X86_64 || defined X32
+
+# include <asm/ldt.h>
+
+void
+print_user_desc(struct tcb *tcp, const long addr)
+{
+	struct user_desc desc;
+
+	if (umove_or_printaddr(tcp, addr, &desc))
+		return;
+
+	tprintf("{entry_number:%d, "
+		"base_addr:%#08x, "
+		"limit:%d, "
+		"seg_32bit:%d, "
+		"contents:%d, "
+		"read_exec_only:%d, "
+		"limit_in_pages:%d, "
+		"seg_not_present:%d, "
+		"useable:%d}",
+		desc.entry_number,
+		desc.base_addr,
+		desc.limit,
+		desc.seg_32bit,
+		desc.contents,
+		desc.read_exec_only,
+		desc.limit_in_pages,
+		desc.seg_not_present,
+		desc.useable);
+}
+
+SYS_FUNC(modify_ldt)
+{
+	tprintf("%ld, ", tcp->u_arg[0]);
+	if (tcp->u_arg[2] != sizeof(struct user_desc))
+		printaddr(tcp->u_arg[1]);
+	else
+		print_user_desc(tcp, tcp->u_arg[1]);
+	tprintf(", %lu", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(set_thread_area)
+{
+	if (entering(tcp)) {
+		print_user_desc(tcp, tcp->u_arg[0]);
+	} else {
+		struct user_desc desc;
+
+		if (!verbose(tcp) || syserror(tcp) ||
+		    umove(tcp, tcp->u_arg[0], &desc) < 0) {
+			/* returned entry_number is not available */
+		} else {
+			static char outstr[32];
+
+			sprintf(outstr, "entry_number:%d", desc.entry_number);
+			tcp->auxstr = outstr;
+			return RVAL_STR;
+		}
+	}
+	return 0;
+}
+
+SYS_FUNC(get_thread_area)
+{
+	if (exiting(tcp))
+		print_user_desc(tcp, tcp->u_arg[0]);
+	return 0;
+}
+
+#endif /* I386 || X86_64 || X32 */
+
+#if defined(M68K) || defined(MIPS)
+SYS_FUNC(set_thread_area)
+{
+	printaddr(tcp->u_arg[0]);
+
+	return RVAL_DECODED;
+
+}
+#endif
+
+#if defined(M68K)
+SYS_FUNC(get_thread_area)
+{
+	return RVAL_DECODED | RVAL_HEX;
+}
+#endif
diff --git a/strace/link.c b/strace/link.c
new file mode 100644
index 0000000..68a1304
--- /dev/null
+++ b/strace/link.c
@@ -0,0 +1,80 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2006 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2006 Bernhard Kaindl <bk@suse.de>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+
+#include "xlat/at_flags.h"
+
+SYS_FUNC(link)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printpath(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(linkat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	print_dirfd(tcp, tcp->u_arg[2]);
+	printpath(tcp, tcp->u_arg[3]);
+	tprints(", ");
+	printflags(at_flags, tcp->u_arg[4], "AT_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(unlinkat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	printflags(at_flags, tcp->u_arg[2], "AT_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(symlinkat)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	print_dirfd(tcp, tcp->u_arg[1]);
+	printpath(tcp, tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/linux/32/ioctls_inc.h b/strace/linux/32/ioctls_inc.h
new file mode 100644
index 0000000..72905b4
--- /dev/null
+++ b/strace/linux/32/ioctls_inc.h
@@ -0,0 +1,6 @@
+#if defined X86_64 || defined X32 \
+ || SIZEOF_STRUCT_I64_I32 < SIZEOF_LONG_LONG * 2
+# include "32/ioctls_inc_align32.h"
+#else
+# include "32/ioctls_inc_align64.h"
+#endif
diff --git a/strace/linux/32/ioctls_inc_align32.h b/strace/linux/32/ioctls_inc_align32.h
new file mode 100644
index 0000000..2222f40
--- /dev/null
+++ b/strace/linux/32/ioctls_inc_align32.h
@@ -0,0 +1,2824 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/include/ tree. */
+{ "acpi/apei.h", "APEI_ERST_CLEAR_RECORD", _IOC_WRITE, 0x4501, 0x08 },
+{ "acpi/apei.h", "APEI_ERST_GET_RECORD_COUNT", _IOC_READ, 0x4502, 0x04 },
+{ "asm-generic/ioctls.h", "FIOASYNC", 0, 0x5452, 0 },
+{ "asm-generic/ioctls.h", "FIOCLEX", 0, 0x5451, 0 },
+{ "asm-generic/ioctls.h", "FIONBIO", 0, 0x5421, 0 },
+{ "asm-generic/ioctls.h", "FIONCLEX", 0, 0x5450, 0 },
+{ "asm-generic/ioctls.h", "FIONREAD", 0, 0x541B, 0 },
+{ "asm-generic/ioctls.h", "FIOQSIZE", 0, 0x5460, 0 },
+{ "asm-generic/ioctls.h", "TCFLSH", 0, 0x540B, 0 },
+{ "asm-generic/ioctls.h", "TCGETA", 0, 0x5405, 0 },
+{ "asm-generic/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm-generic/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm-generic/ioctls.h", "TCGETX", 0, 0x5432, 0 },
+{ "asm-generic/ioctls.h", "TCSBRK", 0, 0x5409, 0 },
+{ "asm-generic/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm-generic/ioctls.h", "TCSETA", 0, 0x5406, 0 },
+{ "asm-generic/ioctls.h", "TCSETAF", 0, 0x5408, 0 },
+{ "asm-generic/ioctls.h", "TCSETAW", 0, 0x5407, 0 },
+{ "asm-generic/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm-generic/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm-generic/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm-generic/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETX", 0, 0x5433, 0 },
+{ "asm-generic/ioctls.h", "TCSETXF", 0, 0x5434, 0 },
+{ "asm-generic/ioctls.h", "TCSETXW", 0, 0x5435, 0 },
+{ "asm-generic/ioctls.h", "TCXONC", 0, 0x540A, 0 },
+{ "asm-generic/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm-generic/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm-generic/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm-generic/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm-generic/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm-generic/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPGRP", 0, 0x540F, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGRS485", 0, 0x542E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSID", 0, 0x5429, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm-generic/ioctls.h", "TIOCGWINSZ", 0, 0x5413, 0 },
+{ "asm-generic/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm-generic/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm-generic/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm-generic/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm-generic/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm-generic/ioctls.h", "TIOCOUTQ", 0, 0x5411, 0 },
+{ "asm-generic/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm-generic/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm-generic/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm-generic/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm-generic/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPGRP", 0, 0x5410, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSRS485", 0, 0x542F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm-generic/ioctls.h", "TIOCSWINSZ", 0, 0x5414, 0 },
+{ "asm-generic/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm-generic/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm-generic/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm-generic/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm-generic/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm-generic/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_BO_LIST", _IOC_READ|_IOC_WRITE, 0x6443, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CS", _IOC_READ|_IOC_WRITE, 0x6444, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CTX", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_METADATA", _IOC_READ|_IOC_WRITE, 0x6446, 0x11c },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x08 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_OP", _IOC_READ|_IOC_WRITE, 0x6450, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6451, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_VA", _IOC_WRITE, 0x6448, 0x28 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_INFO", _IOC_WRITE, 0x6445, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_WAIT_CS", _IOC_READ|_IOC_WRITE, 0x6449, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_BUFS", _IOC_READ|_IOC_WRITE, 0x6416, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_CTX", _IOC_READ|_IOC_WRITE, 0x6420, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_DRAW", _IOC_READ|_IOC_WRITE, 0x6427, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_MAP", _IOC_READ|_IOC_WRITE, 0x6415, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ACQUIRE", _IOC_NONE, 0x6430, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6434, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_BIND", _IOC_WRITE, 0x6436, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ENABLE", _IOC_WRITE, 0x6432, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_FREE", _IOC_WRITE, 0x6435, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_INFO", _IOC_READ, 0x6433, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_RELEASE", _IOC_NONE, 0x6431, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_UNBIND", _IOC_WRITE, 0x6437, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AUTH_MAGIC", _IOC_WRITE, 0x6411, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_BLOCK", _IOC_READ|_IOC_WRITE, 0x6412, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_CONTROL", _IOC_WRITE, 0x6414, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_DMA", _IOC_READ|_IOC_WRITE, 0x6429, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_DROP_MASTER", _IOC_NONE, 0x641f, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_FINISH", _IOC_WRITE, 0x642c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_FREE_BUFS", _IOC_WRITE, 0x641a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_CLOSE", _IOC_WRITE, 0x6409, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_FLINK", _IOC_READ|_IOC_WRITE, 0x640a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_OPEN", _IOC_READ|_IOC_WRITE, 0x640b, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CAP", _IOC_READ|_IOC_WRITE, 0x640c, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CLIENT", _IOC_READ|_IOC_WRITE, 0x6405, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CTX", _IOC_READ|_IOC_WRITE, 0x6423, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAGIC", _IOC_READ, 0x6402, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAP", _IOC_READ|_IOC_WRITE, 0x6404, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_GET_SAREA_CTX", _IOC_READ|_IOC_WRITE, 0x641d, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_STATS", _IOC_READ, 0x6406, 0x7c },
+{ "drm/drm.h", "DRM_IOCTL_GET_UNIQUE", _IOC_READ|_IOC_WRITE, 0x6401, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_INFO_BUFS", _IOC_READ|_IOC_WRITE, 0x6418, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_IRQ_BUSID", _IOC_READ|_IOC_WRITE, 0x6403, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_LOCK", _IOC_WRITE, 0x642a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MAP_BUFS", _IOC_READ|_IOC_WRITE, 0x6419, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_MARK_BUFS", _IOC_WRITE, 0x6417, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODESET_CTL", _IOC_WRITE, 0x6408, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB", _IOC_READ|_IOC_WRITE, 0x64ae, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB2", _IOC_READ|_IOC_WRITE, 0x64b8, 0x64 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATOMIC", _IOC_READ|_IOC_WRITE, 0x64bc, 0x38 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATTACHMODE", _IOC_READ|_IOC_WRITE, 0x64a8, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATEPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64bd, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATE_DUMB", _IOC_READ|_IOC_WRITE, 0x64b2, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR", _IOC_READ|_IOC_WRITE, 0x64a3, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR2", _IOC_READ|_IOC_WRITE, 0x64bb, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROYPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64be, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROY_DUMB", _IOC_READ|_IOC_WRITE, 0x64b4, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DETACHMODE", _IOC_READ|_IOC_WRITE, 0x64a9, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DIRTYFB", _IOC_READ|_IOC_WRITE, 0x64b1, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCONNECTOR", _IOC_READ|_IOC_WRITE, 0x64a7, 0x50 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCRTC", _IOC_READ|_IOC_WRITE, 0x64a1, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETENCODER", _IOC_READ|_IOC_WRITE, 0x64a6, 0x14 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETFB", _IOC_READ|_IOC_WRITE, 0x64ad, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a4, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANE", _IOC_READ|_IOC_WRITE, 0x64b6, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANERESOURCES", _IOC_READ|_IOC_WRITE, 0x64b5, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64ac, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64aa, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETRESOURCES", _IOC_READ|_IOC_WRITE, 0x64a0, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_MAP_DUMB", _IOC_READ|_IOC_WRITE, 0x64b3, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", _IOC_READ|_IOC_WRITE, 0x64b9, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ba, 0x14 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_PAGE_FLIP", _IOC_READ|_IOC_WRITE, 0x64b0, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_RMFB", _IOC_READ|_IOC_WRITE, 0x64af, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETCRTC", _IOC_READ|_IOC_WRITE, 0x64a2, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a5, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPLANE", _IOC_READ|_IOC_WRITE, 0x64b7, 0x30 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ab, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MOD_CTX", _IOC_WRITE, 0x6422, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_NEW_CTX", _IOC_WRITE, 0x6425, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_FD_TO_HANDLE", _IOC_READ|_IOC_WRITE, 0x642e, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_HANDLE_TO_FD", _IOC_READ|_IOC_WRITE, 0x642d, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_RES_CTX", _IOC_READ|_IOC_WRITE, 0x6426, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_CTX", _IOC_READ|_IOC_WRITE, 0x6421, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_DRAW", _IOC_READ|_IOC_WRITE, 0x6428, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_RM_MAP", _IOC_WRITE, 0x641b, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_SET_CLIENT_CAP", _IOC_WRITE, 0x640d, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SET_MASTER", _IOC_NONE, 0x641e, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_SET_SAREA_CTX", _IOC_WRITE, 0x641c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SET_UNIQUE", _IOC_WRITE, 0x6410, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SET_VERSION", _IOC_READ|_IOC_WRITE, 0x6407, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SG_ALLOC", _IOC_READ|_IOC_WRITE, 0x6438, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SG_FREE", _IOC_WRITE, 0x6439, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SWITCH_CTX", _IOC_WRITE, 0x6424, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UNBLOCK", _IOC_READ|_IOC_WRITE, 0x6413, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_UNLOCK", _IOC_WRITE, 0x642b, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UPDATE_DRAW", _IOC_WRITE, 0x643f, 0x14 },
+{ "drm/drm.h", "DRM_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x6400, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_WAIT_VBLANK", _IOC_READ|_IOC_WRITE, 0x643a, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x30 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6448, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_WAIT", _IOC_WRITE, 0x6449, 0x20 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x20 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_EXEC", _IOC_READ|_IOC_WRITE, 0x6462, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_GET_VER", _IOC_READ|_IOC_WRITE, 0x6460, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", _IOC_READ|_IOC_WRITE, 0x6461, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_GET", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", _IOC_READ|_IOC_WRITE, 0x6473, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6470, 0x50 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", _IOC_READ|_IOC_WRITE, 0x6472, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6471, 0x60 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_CLEAR", _IOC_WRITE, 0x6442, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_COPY", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_DOCOPY", _IOC_NONE, 0x6448, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLIP", _IOC_NONE, 0x644e, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLUSH", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FSTATUS", _IOC_NONE, 0x644a, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETAGE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETBUF", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_INIT", _IOC_WRITE, 0x6440, 0x40 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_MC", _IOC_WRITE, 0x644c, 0x14 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0FLIP", _IOC_NONE, 0x644b, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0INFO", _IOC_READ, 0x6449, 0x08 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_RSTATUS", _IOC_NONE, 0x644d, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_SWAP", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_VERTEX", _IOC_WRITE, 0x6441, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_ALLOC", _IOC_READ|_IOC_WRITE, 0x6448, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_BATCHBUFFER", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_CMDBUFFER", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_DESTROY_HEAP", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLIP", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLUSH", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FREE", _IOC_WRITE, 0x6449, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x6457, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", _IOC_READ|_IOC_WRITE, 0x646d, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", _IOC_WRITE, 0x646e, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6474, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", _IOC_READ|_IOC_WRITE, 0x6475, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645b, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_ENTERVT", _IOC_NONE, 0x6459, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER", _IOC_WRITE, 0x6454, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER2", _IOC_WRITE, 0x6469, 0x40 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_APERTURE", _IOC_READ, 0x6463, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_CACHING", _IOC_READ|_IOC_WRITE, 0x6470, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6462, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_INIT", _IOC_WRITE, 0x6453, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_LEAVEVT", _IOC_NONE, 0x645a, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MADVISE", _IOC_READ|_IOC_WRITE, 0x6466, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP_GTT", _IOC_READ|_IOC_WRITE, 0x6464, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PIN", _IOC_READ|_IOC_WRITE, 0x6455, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PREAD", _IOC_WRITE, 0x645c, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PWRITE", _IOC_WRITE, 0x645d, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_CACHING", _IOC_WRITE, 0x646f, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_DOMAIN", _IOC_WRITE, 0x645f, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6461, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SW_FINISH", _IOC_WRITE, 0x6460, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_THROTTLE", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_UNPIN", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6473, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_WAIT", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6446, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", _IOC_READ|_IOC_WRITE, 0x6465, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_RESET_STATS", _IOC_READ|_IOC_WRITE, 0x6472, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646a, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_VBLANK_PIPE", _IOC_READ, 0x644e, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_HWS_ADDR", _IOC_WRITE, 0x6451, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT", _IOC_WRITE, 0x6440, 0x44 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT_HEAP", _IOC_WRITE, 0x644a, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_WAIT", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_ATTRS", _IOC_READ|_IOC_WRITE, 0x6468, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", _IOC_WRITE, 0x6467, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_REG_READ", _IOC_READ|_IOC_WRITE, 0x6471, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SETPARAM", _IOC_WRITE, 0x6447, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646b, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_VBLANK_PIPE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_VBLANK_SWAP", _IOC_READ|_IOC_WRITE, 0x644f, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_BLIT", _IOC_WRITE, 0x6448, 0x34 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_CLEAR", _IOC_WRITE, 0x6444, 0x14 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_DMA_BOOTSTRAP", _IOC_READ|_IOC_WRITE, 0x644c, 0x1c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_FLUSH", _IOC_WRITE, 0x6441, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6449, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_ILOAD", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INDICES", _IOC_WRITE, 0x6446, 0x10 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INIT", _IOC_WRITE, 0x6440, 0x5c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_RESET", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SET_FENCE", _IOC_WRITE, 0x644a, 0x04 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SWAP", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_VERTEX", _IOC_WRITE, 0x6445, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_WAIT_FENCE", _IOC_READ|_IOC_WRITE, 0x644b, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x20 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x18 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", _IOC_WRITE, 0x6483, 0x04 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", _IOC_WRITE, 0x6482, 0x08 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6484, 0x28 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6480, 0x30 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", _IOC_READ|_IOC_WRITE, 0x6481, 0x40 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x08 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_SET_PARAM", _IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC", _IOC_READ|_IOC_WRITE, 0x6440, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC_SURF", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_CLIENTCAP", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_EXECBUFFER", _IOC_WRITE, 0x6442, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_UPDATE_AREA", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_BLIT", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CLEAR", _IOC_WRITE, 0x6448, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_DEPTH", _IOC_WRITE, 0x644c, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FLIP", _IOC_NONE, 0x6453, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FULLSCREEN", _IOC_WRITE, 0x6450, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6452, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644f, 0x10 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INIT", _IOC_WRITE, 0x6440, 0x58 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_RESET", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_STIPPLE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_ALLOC", _IOC_READ|_IOC_WRITE, 0x6453, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CLEAR", _IOC_WRITE, 0x6448, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CMDBUF", _IOC_WRITE, 0x6450, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_INIT", _IOC_WRITE, 0x6440, 0x54 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESUME", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CS", _IOC_READ|_IOC_WRITE, 0x6466, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FLIP", _IOC_NONE, 0x6452, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FREE", _IOC_WRITE, 0x6454, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FULLSCREEN", _IOC_WRITE, 0x6446, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x646a, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645d, 0x1c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6469, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x645c, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_OP", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PREAD", _IOC_READ|_IOC_WRITE, 0x6461, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PWRITE", _IOC_READ|_IOC_WRITE, 0x6462, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", _IOC_READ|_IOC_WRITE, 0x6463, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6468, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x646d, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_VA", _IOC_READ|_IOC_WRITE, 0x646b, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", _IOC_WRITE, 0x6464, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6451, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INFO", _IOC_READ|_IOC_WRITE, 0x6467, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INIT_HEAP", _IOC_WRITE, 0x6455, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6456, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_WAIT", _IOC_WRITE, 0x6457, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_RESET", _IOC_NONE, 0x6445, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SETPARAM", _IOC_WRITE, 0x6459, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_STIPPLE", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_ALLOC", _IOC_WRITE, 0x645a, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_FREE", _IOC_WRITE, 0x645b, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_TEXTURE", _IOC_READ|_IOC_WRITE, 0x644e, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX2", _IOC_WRITE, 0x644f, 0x18 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_CMDBUF", _IOC_WRITE, 0x6441, 0x24 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", _IOC_WRITE, 0x6443, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_INIT", _IOC_WRITE, 0x6440, 0x50 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6454, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_FREE", _IOC_WRITE, 0x6455, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6453, 0x08 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_ALLOC", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_FREE", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_INIT", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6446, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644d, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x644b, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644c, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x644a, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", _IOC_READ|_IOC_WRITE, 0x6449, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_OPEN_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x58 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_INCR", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_READ", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_WAIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_BO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_SHADER_BO", _IOC_READ|_IOC_WRITE, 0x6445, 0x18 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_GET_HANG_STATE", _IOC_READ|_IOC_WRITE, 0x6446, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_MMAP_BO", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_SUBMIT_CL", _IOC_READ|_IOC_WRITE, 0x6440, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_BO", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_SEQNO", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_ALLOCMEM", _IOC_READ|_IOC_WRITE, 0x6440, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_BLIT_SYNC", _IOC_WRITE, 0x644f, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUFFER", _IOC_WRITE, 0x6448, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUF_SIZE", _IOC_READ|_IOC_WRITE, 0x644b, 0x0c },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DEC_FUTEX", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_BLIT", _IOC_WRITE, 0x644e, 0x28 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_INIT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FB_INIT", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FLUSH", _IOC_NONE, 0x6449, 0x00 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FREEMEM", _IOC_WRITE, 0x6441, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_MAP_INIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_PCICMD", _IOC_WRITE, 0x644a, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_WAIT_IRQ", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_EXECBUFFER", _IOC_WRITE, 0x6442, 0x20 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x6449, 0x18 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", _IOC_READ|_IOC_WRITE, 0x6444, 0x38 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", _IOC_READ|_IOC_WRITE, 0x6446, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", _IOC_READ|_IOC_WRITE, 0x6447, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_WAIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_ACQUIRE", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x4106, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_BIND", _IOC_WRITE, 0x4108, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_CHIPSET_FLUSH", _IOC_NONE, 0x410a, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_DEALLOCATE", _IOC_WRITE, 0x4107, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_INFO", _IOC_READ, 0x4100, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_PROTECT", _IOC_WRITE, 0x4105, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_RELEASE", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_RESERVE", _IOC_WRITE, 0x4104, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_SETUP", _IOC_WRITE, 0x4103, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_UNBIND", _IOC_WRITE, 0x4109, 0x04 },
+{ "linux/am437x-vpfe.h", "VIDIOC_AM437X_CCDC_CFG", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE_DONE", _IOC_WRITE, 0x6309, 0x10 },
+{ "linux/android/binder.h", "BC_ACQUIRE_RESULT", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/android/binder.h", "BC_ATTEMPT_ACQUIRE", _IOC_WRITE, 0x630a, 0x08 },
+{ "linux/android/binder.h", "BC_CLEAR_DEATH_NOTIFICATION", _IOC_WRITE, 0x630f, 0x0c },
+{ "linux/android/binder.h", "BC_DEAD_BINDER_DONE", _IOC_WRITE, 0x6310, 0x08 },
+{ "linux/android/binder.h", "BC_DECREFS", _IOC_WRITE, 0x6307, 0x04 },
+{ "linux/android/binder.h", "BC_ENTER_LOOPER", _IOC_NONE, 0x630c, 0x00 },
+{ "linux/android/binder.h", "BC_EXIT_LOOPER", _IOC_NONE, 0x630d, 0x00 },
+{ "linux/android/binder.h", "BC_FREE_BUFFER", _IOC_WRITE, 0x6303, 0x08 },
+{ "linux/android/binder.h", "BC_INCREFS", _IOC_WRITE, 0x6304, 0x04 },
+{ "linux/android/binder.h", "BC_INCREFS_DONE", _IOC_WRITE, 0x6308, 0x10 },
+{ "linux/android/binder.h", "BC_REGISTER_LOOPER", _IOC_NONE, 0x630b, 0x00 },
+{ "linux/android/binder.h", "BC_RELEASE", _IOC_WRITE, 0x6306, 0x04 },
+{ "linux/android/binder.h", "BC_REPLY", _IOC_WRITE, 0x6301, 0x40 },
+{ "linux/android/binder.h", "BC_REQUEST_DEATH_NOTIFICATION", _IOC_WRITE, 0x630e, 0x0c },
+{ "linux/android/binder.h", "BC_TRANSACTION", _IOC_WRITE, 0x6300, 0x40 },
+{ "linux/android/binder.h", "BINDER_SET_CONTEXT_MGR", _IOC_WRITE, 0x6207, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_PRIORITY", _IOC_WRITE, 0x6206, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_TIMEOUT", _IOC_WRITE, 0x6203, 0x08 },
+{ "linux/android/binder.h", "BINDER_SET_MAX_THREADS", _IOC_WRITE, 0x6205, 0x04 },
+{ "linux/android/binder.h", "BINDER_THREAD_EXIT", _IOC_WRITE, 0x6208, 0x04 },
+{ "linux/android/binder.h", "BINDER_VERSION", _IOC_READ|_IOC_WRITE, 0x6209, 0x04 },
+{ "linux/android/binder.h", "BINDER_WRITE_READ", _IOC_READ|_IOC_WRITE, 0x6201, 0x30 },
+{ "linux/android/binder.h", "BR_ACQUIRE", _IOC_READ, 0x7208, 0x10 },
+{ "linux/android/binder.h", "BR_ACQUIRE_RESULT", _IOC_READ, 0x7204, 0x04 },
+{ "linux/android/binder.h", "BR_ATTEMPT_ACQUIRE", _IOC_READ, 0x720b, 0x14 },
+{ "linux/android/binder.h", "BR_CLEAR_DEATH_NOTIFICATION_DONE", _IOC_READ, 0x7210, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_BINDER", _IOC_READ, 0x720f, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_REPLY", _IOC_NONE, 0x7205, 0x00 },
+{ "linux/android/binder.h", "BR_DECREFS", _IOC_READ, 0x720a, 0x10 },
+{ "linux/android/binder.h", "BR_ERROR", _IOC_READ, 0x7200, 0x04 },
+{ "linux/android/binder.h", "BR_FAILED_REPLY", _IOC_NONE, 0x7211, 0x00 },
+{ "linux/android/binder.h", "BR_FINISHED", _IOC_NONE, 0x720e, 0x00 },
+{ "linux/android/binder.h", "BR_INCREFS", _IOC_READ, 0x7207, 0x10 },
+{ "linux/android/binder.h", "BR_NOOP", _IOC_NONE, 0x720c, 0x00 },
+{ "linux/android/binder.h", "BR_OK", _IOC_NONE, 0x7201, 0x00 },
+{ "linux/android/binder.h", "BR_RELEASE", _IOC_READ, 0x7209, 0x10 },
+{ "linux/android/binder.h", "BR_REPLY", _IOC_READ, 0x7203, 0x40 },
+{ "linux/android/binder.h", "BR_SPAWN_LOOPER", _IOC_NONE, 0x720d, 0x00 },
+{ "linux/android/binder.h", "BR_TRANSACTION", _IOC_READ, 0x7202, 0x40 },
+{ "linux/android/binder.h", "BR_TRANSACTION_COMPLETE", _IOC_NONE, 0x7206, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_STANDBY", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_SUSPEND", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/arcfb.h", "FBIO_GETCONTROL2", _IOC_READ, 0x4689, 0x04 },
+{ "linux/arcfb.h", "FBIO_WAITEVENT", _IOC_NONE, 0x4688, 0x00 },
+{ "linux/atm_eni.h", "ENI_MEMDUMP", _IOC_WRITE, 0x6160, 0x0c },
+{ "linux/atm_eni.h", "ENI_SETMULT", _IOC_WRITE, 0x6167, 0x0c },
+{ "linux/atm_he.h", "HE_GET_REG", _IOC_WRITE, 0x6160, 0x0c },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTAT", _IOC_WRITE, 0x6132, 0x0c },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTATZ", _IOC_WRITE, 0x6133, 0x0c },
+{ "linux/atm_nicstar.h", "NS_ADJBUFLEV", _IOC_NONE, 0x6163, 0x00 },
+{ "linux/atm_nicstar.h", "NS_GETPSTAT", _IOC_READ|_IOC_WRITE, 0x6161, 0x0c },
+{ "linux/atm_nicstar.h", "NS_SETBUFLEV", _IOC_WRITE, 0x6162, 0x0c },
+{ "linux/atm_tcp.h", "ATMTCP_CREATE", _IOC_NONE, 0x618e, 0x00 },
+{ "linux/atm_tcp.h", "ATMTCP_REMOVE", _IOC_NONE, 0x618f, 0x00 },
+{ "linux/atm_tcp.h", "SIOCSIFATMTCP", _IOC_NONE, 0x6180, 0x00 },
+{ "linux/atm_zatm.h", "ZATM_GETPOOL", _IOC_WRITE, 0x6161, 0x0c },
+{ "linux/atm_zatm.h", "ZATM_GETPOOLZ", _IOC_WRITE, 0x6162, 0x0c },
+{ "linux/atm_zatm.h", "ZATM_SETPOOL", _IOC_WRITE, 0x6163, 0x0c },
+{ "linux/atmarp.h", "ATMARPD_CTRL", _IOC_NONE, 0x61e1, 0x00 },
+{ "linux/atmarp.h", "ATMARP_ENCAP", _IOC_NONE, 0x61e5, 0x00 },
+{ "linux/atmarp.h", "ATMARP_MKIP", _IOC_NONE, 0x61e2, 0x00 },
+{ "linux/atmarp.h", "ATMARP_SETENTRY", _IOC_NONE, 0x61e3, 0x00 },
+{ "linux/atmbr2684.h", "BR2684_SETFILT", _IOC_WRITE, 0x6190, 0x1c },
+{ "linux/atmclip.h", "SIOCMKCLIP", _IOC_NONE, 0x61e0, 0x00 },
+{ "linux/atmdev.h", "ATM_ADDADDR", _IOC_WRITE, 0x6188, 0x0c },
+{ "linux/atmdev.h", "ATM_ADDLECSADDR", _IOC_WRITE, 0x618e, 0x0c },
+{ "linux/atmdev.h", "ATM_ADDPARTY", _IOC_WRITE, 0x61f4, 0x08 },
+{ "linux/atmdev.h", "ATM_DELADDR", _IOC_WRITE, 0x6189, 0x0c },
+{ "linux/atmdev.h", "ATM_DELLECSADDR", _IOC_WRITE, 0x618f, 0x0c },
+{ "linux/atmdev.h", "ATM_DROPPARTY", _IOC_WRITE, 0x61f5, 0x04 },
+{ "linux/atmdev.h", "ATM_GETADDR", _IOC_WRITE, 0x6186, 0x0c },
+{ "linux/atmdev.h", "ATM_GETCIRANGE", _IOC_WRITE, 0x618a, 0x0c },
+{ "linux/atmdev.h", "ATM_GETESI", _IOC_WRITE, 0x6185, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLECSADDR", _IOC_WRITE, 0x6190, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLINKRATE", _IOC_WRITE, 0x6181, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLOOP", _IOC_WRITE, 0x6152, 0x0c },
+{ "linux/atmdev.h", "ATM_GETNAMES", _IOC_WRITE, 0x6183, 0x08 },
+{ "linux/atmdev.h", "ATM_GETSTAT", _IOC_WRITE, 0x6150, 0x0c },
+{ "linux/atmdev.h", "ATM_GETSTATZ", _IOC_WRITE, 0x6151, 0x0c },
+{ "linux/atmdev.h", "ATM_GETTYPE", _IOC_WRITE, 0x6184, 0x0c },
+{ "linux/atmdev.h", "ATM_NEWBACKENDIF", _IOC_WRITE, 0x61f3, 0x02 },
+{ "linux/atmdev.h", "ATM_QUERYLOOP", _IOC_WRITE, 0x6154, 0x0c },
+{ "linux/atmdev.h", "ATM_RSTADDR", _IOC_WRITE, 0x6187, 0x0c },
+{ "linux/atmdev.h", "ATM_SETBACKEND", _IOC_WRITE, 0x61f2, 0x02 },
+{ "linux/atmdev.h", "ATM_SETCIRANGE", _IOC_WRITE, 0x618b, 0x0c },
+{ "linux/atmdev.h", "ATM_SETESI", _IOC_WRITE, 0x618c, 0x0c },
+{ "linux/atmdev.h", "ATM_SETESIF", _IOC_WRITE, 0x618d, 0x0c },
+{ "linux/atmdev.h", "ATM_SETLOOP", _IOC_WRITE, 0x6153, 0x0c },
+{ "linux/atmdev.h", "ATM_SETSC", _IOC_WRITE, 0x61f1, 0x04 },
+{ "linux/atmlec.h", "ATMLEC_CTRL", _IOC_NONE, 0x61d0, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_DATA", _IOC_NONE, 0x61d1, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_MCAST", _IOC_NONE, 0x61d2, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_CTRL", _IOC_NONE, 0x61d8, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_DATA", _IOC_NONE, 0x61d9, 0x00 },
+{ "linux/atmsvc.h", "ATMSIGD_CTRL", _IOC_NONE, 0x61f0, 0x00 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ASKUMOUNT", _IOC_READ|_IOC_WRITE, 0x937d, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CATATONIC", _IOC_READ|_IOC_WRITE, 0x9379, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CLOSEMOUNT", _IOC_READ|_IOC_WRITE, 0x9375, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_EXPIRE", _IOC_READ|_IOC_WRITE, 0x937c, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_FAIL", _IOC_READ|_IOC_WRITE, 0x9377, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", _IOC_READ|_IOC_WRITE, 0x937e, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_OPENMOUNT", _IOC_READ|_IOC_WRITE, 0x9374, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOSUBVER", _IOC_READ|_IOC_WRITE, 0x9373, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOVER", _IOC_READ|_IOC_WRITE, 0x9372, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_READY", _IOC_READ|_IOC_WRITE, 0x9376, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_REQUESTER", _IOC_READ|_IOC_WRITE, 0x937b, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_SETPIPEFD", _IOC_READ|_IOC_WRITE, 0x9378, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_TIMEOUT", _IOC_READ|_IOC_WRITE, 0x937a, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x9371, 0x18 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_CATATONIC", _IOC_NONE, 0x9362, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_EXPIRE", _IOC_READ, 0x9365, 0x10c },
+{ "linux/auto_fs.h", "AUTOFS_IOC_FAIL", _IOC_NONE, 0x9361, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_PROTOVER", _IOC_READ, 0x9363, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_READY", _IOC_NONE, 0x9360, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT32", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_ASKUMOUNT", _IOC_READ, 0x9370, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_EXPIRE_MULTI", _IOC_WRITE, 0x9366, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_PROTOSUBVER", _IOC_READ, 0x9367, 0x04 },
+{ "linux/blkpg.h", "BLKPG", _IOC_NONE, 0x1269, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_ADD_DEV", _IOC_WRITE, 0x940a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE", _IOC_WRITE, 0x940c, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_CTL", _IOC_WRITE, 0x9421, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_PROGRESS", _IOC_READ, 0x9422, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_V2", _IOC_READ|_IOC_WRITE, 0x9420, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE_RANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFAULT_SUBVOL", _IOC_WRITE, 0x9413, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG", _IOC_WRITE, 0x9402, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG_RANGE", _IOC_WRITE, 0x9410, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEVICES_READY", _IOC_READ, 0x9427, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_INFO", _IOC_READ|_IOC_WRITE, 0x941e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_REPLACE", _IOC_READ|_IOC_WRITE, 0x9435, 0xa24 },
+{ "linux/btrfs.h", "BTRFS_IOC_FILE_EXTENT_SAME", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_FS_INFO", _IOC_READ, 0x941f, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_DEV_STATS", _IOC_READ|_IOC_WRITE, 0x9434, 0x408 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FEATURES", _IOC_READ, 0x9439, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FSLABEL", _IOC_READ, 0x9431, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_SUPPORTED_FEATURES", _IOC_READ, 0x9439, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_LOOKUP", _IOC_READ|_IOC_WRITE, 0x9412, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_PATHS", _IOC_READ|_IOC_WRITE, 0x9423, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_LOGICAL_INO", _IOC_READ|_IOC_WRITE, 0x9424, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_ASSIGN", _IOC_WRITE, 0x9429, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_CREATE", _IOC_WRITE, 0x942a, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_LIMIT", _IOC_READ, 0x942b, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_CTL", _IOC_READ|_IOC_WRITE, 0x9428, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN", _IOC_WRITE, 0x942c, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_STATUS", _IOC_READ, 0x942d, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_WAIT", _IOC_NONE, 0x942e, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_RESIZE", _IOC_WRITE, 0x9403, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV", _IOC_WRITE, 0x940b, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV_V2", _IOC_WRITE, 0x943a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCAN_DEV", _IOC_WRITE, 0x9404, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB", _IOC_READ|_IOC_WRITE, 0x941b, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_CANCEL", _IOC_NONE, 0x941c, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_PROGRESS", _IOC_READ|_IOC_WRITE, 0x941d, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SEND", _IOC_WRITE, 0x9426, 0x44 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FEATURES", _IOC_WRITE, 0x9439, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FSLABEL", _IOC_WRITE, 0x9432, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_RECEIVED_SUBVOL", _IOC_READ|_IOC_WRITE, 0x9425, 0xc0 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE", _IOC_WRITE, 0x9401, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE_V2", _IOC_WRITE, 0x9417, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_DESTROY", _IOC_WRITE, 0x940f, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SPACE_INFO", _IOC_READ|_IOC_WRITE, 0x9414, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_START_SYNC", _IOC_READ, 0x9418, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE", _IOC_WRITE, 0x940e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE_V2", _IOC_WRITE, 0x9418, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_GETFLAGS", _IOC_READ, 0x9419, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_SETFLAGS", _IOC_WRITE, 0x941a, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SYNC", _IOC_NONE, 0x9408, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_END", _IOC_NONE, 0x9407, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_START", _IOC_NONE, 0x9406, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH", _IOC_READ|_IOC_WRITE, 0x9411, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH_V2", _IOC_READ|_IOC_WRITE, 0x9411, 0x70 },
+{ "linux/btrfs.h", "BTRFS_IOC_WAIT_SYNC", _IOC_WRITE, 0x9416, 0x08 },
+{ "linux/capi.h", "CAPI_CLR_FLAGS", _IOC_READ, 0x4325, 0x04 },
+{ "linux/capi.h", "CAPI_GET_ERRCODE", _IOC_READ, 0x4321, 0x02 },
+{ "linux/capi.h", "CAPI_GET_FLAGS", _IOC_READ, 0x4323, 0x04 },
+{ "linux/capi.h", "CAPI_GET_MANUFACTURER", _IOC_READ|_IOC_WRITE, 0x4306, 0x04 },
+{ "linux/capi.h", "CAPI_GET_PROFILE", _IOC_READ|_IOC_WRITE, 0x4309, 0x40 },
+{ "linux/capi.h", "CAPI_GET_SERIAL", _IOC_READ|_IOC_WRITE, 0x4308, 0x04 },
+{ "linux/capi.h", "CAPI_GET_VERSION", _IOC_READ|_IOC_WRITE, 0x4307, 0x10 },
+{ "linux/capi.h", "CAPI_INSTALLED", _IOC_READ, 0x4322, 0x02 },
+{ "linux/capi.h", "CAPI_MANUFACTURER_CMD", _IOC_READ|_IOC_WRITE, 0x4320, 0x08 },
+{ "linux/capi.h", "CAPI_NCCI_GETUNIT", _IOC_READ, 0x4327, 0x04 },
+{ "linux/capi.h", "CAPI_NCCI_OPENCOUNT", _IOC_READ, 0x4326, 0x04 },
+{ "linux/capi.h", "CAPI_REGISTER", _IOC_WRITE, 0x4301, 0x0c },
+{ "linux/capi.h", "CAPI_SET_FLAGS", _IOC_READ, 0x4324, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_BIG_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x4212, 0x58 },
+{ "linux/cciss_ioctl.h", "CCISS_DEREGDISK", _IOC_NONE, 0x420c, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_GETBUSTYPES", _IOC_READ, 0x4207, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETDRIVVER", _IOC_READ, 0x4209, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETFIRMVER", _IOC_READ, 0x4208, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETHEARTBEAT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETINTINFO", _IOC_READ, 0x4202, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_GETLUNINFO", _IOC_READ, 0x4211, 0x0c },
+{ "linux/cciss_ioctl.h", "CCISS_GETNODENAME", _IOC_READ, 0x4204, 0x10 },
+{ "linux/cciss_ioctl.h", "CCISS_GETPCIINFO", _IOC_READ, 0x4201, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x420b, 0x54 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWD", _IOC_NONE, 0x420e, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWDISK", _IOC_WRITE, 0x420d, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_RESCANDISK", _IOC_NONE, 0x4210, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REVALIDVOLS", _IOC_NONE, 0x420a, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_SETINTINFO", _IOC_WRITE, 0x4203, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_SETNODENAME", _IOC_WRITE, 0x4205, 0x10 },
+{ "linux/cdrom.h", "CDROMAUDIOBUFSIZ", 0, 0x5382, 0 },
+{ "linux/cdrom.h", "CDROMCLOSETRAY", 0, 0x5319, 0 },
+{ "linux/cdrom.h", "CDROMEJECT", 0, 0x5309, 0 },
+{ "linux/cdrom.h", "CDROMEJECT_SW", 0, 0x530f, 0 },
+{ "linux/cdrom.h", "CDROMGETSPINDOWN", 0, 0x531d, 0 },
+{ "linux/cdrom.h", "CDROMMULTISESSION", 0, 0x5310, 0 },
+{ "linux/cdrom.h", "CDROMPAUSE", 0, 0x5301, 0 },
+{ "linux/cdrom.h", "CDROMPLAYBLK", 0, 0x5317, 0 },
+{ "linux/cdrom.h", "CDROMPLAYMSF", 0, 0x5303, 0 },
+{ "linux/cdrom.h", "CDROMPLAYTRKIND", 0, 0x5304, 0 },
+{ "linux/cdrom.h", "CDROMREADALL", 0, 0x5318, 0 },
+{ "linux/cdrom.h", "CDROMREADAUDIO", 0, 0x530e, 0 },
+{ "linux/cdrom.h", "CDROMREADCOOKED", 0, 0x5315, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE1", 0, 0x530d, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE2", 0, 0x530c, 0 },
+{ "linux/cdrom.h", "CDROMREADRAW", 0, 0x5314, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCENTRY", 0, 0x5306, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCHDR", 0, 0x5305, 0 },
+{ "linux/cdrom.h", "CDROMRESET", 0, 0x5312, 0 },
+{ "linux/cdrom.h", "CDROMRESUME", 0, 0x5302, 0 },
+{ "linux/cdrom.h", "CDROMSEEK", 0, 0x5316, 0 },
+{ "linux/cdrom.h", "CDROMSETSPINDOWN", 0, 0x531e, 0 },
+{ "linux/cdrom.h", "CDROMSTART", 0, 0x5308, 0 },
+{ "linux/cdrom.h", "CDROMSTOP", 0, 0x5307, 0 },
+{ "linux/cdrom.h", "CDROMSUBCHNL", 0, 0x530b, 0 },
+{ "linux/cdrom.h", "CDROMVOLCTRL", 0, 0x530a, 0 },
+{ "linux/cdrom.h", "CDROMVOLREAD", 0, 0x5313, 0 },
+{ "linux/cdrom.h", "CDROM_CHANGER_NSLOTS", 0, 0x5328, 0 },
+{ "linux/cdrom.h", "CDROM_CLEAR_OPTIONS", 0, 0x5321, 0 },
+{ "linux/cdrom.h", "CDROM_DEBUG", 0, 0x5330, 0 },
+{ "linux/cdrom.h", "CDROM_DISC_STATUS", 0, 0x5327, 0 },
+{ "linux/cdrom.h", "CDROM_DRIVE_STATUS", 0, 0x5326, 0 },
+{ "linux/cdrom.h", "CDROM_GET_CAPABILITY", 0, 0x5331, 0 },
+{ "linux/cdrom.h", "CDROM_GET_MCN", 0, 0x5311, 0 },
+{ "linux/cdrom.h", "CDROM_LAST_WRITTEN", 0, 0x5395, 0 },
+{ "linux/cdrom.h", "CDROM_LOCKDOOR", 0, 0x5329, 0 },
+{ "linux/cdrom.h", "CDROM_MEDIA_CHANGED", 0, 0x5325, 0 },
+{ "linux/cdrom.h", "CDROM_NEXT_WRITABLE", 0, 0x5394, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_DISC", 0, 0x5323, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_SPEED", 0, 0x5322, 0 },
+{ "linux/cdrom.h", "CDROM_SEND_PACKET", 0, 0x5393, 0 },
+{ "linux/cdrom.h", "CDROM_SET_OPTIONS", 0, 0x5320, 0 },
+{ "linux/cdrom.h", "DVD_AUTH", 0, 0x5392, 0 },
+{ "linux/cdrom.h", "DVD_READ_STRUCT", 0, 0x5390, 0 },
+{ "linux/cdrom.h", "DVD_WRITE_STRUCT", 0, 0x5391, 0 },
+{ "linux/chio.h", "CHIOEXCHANGE", _IOC_WRITE, 0x6302, 0x1c },
+{ "linux/chio.h", "CHIOGELEM", _IOC_WRITE, 0x6310, 0x6c },
+{ "linux/chio.h", "CHIOGPARAMS", _IOC_READ, 0x6306, 0x14 },
+{ "linux/chio.h", "CHIOGPICKER", _IOC_READ, 0x6304, 0x04 },
+{ "linux/chio.h", "CHIOGSTATUS", _IOC_WRITE, 0x6308, 0x08 },
+{ "linux/chio.h", "CHIOGVPARAMS", _IOC_READ, 0x6313, 0x70 },
+{ "linux/chio.h", "CHIOINITELEM", _IOC_NONE, 0x6311, 0x00 },
+{ "linux/chio.h", "CHIOMOVE", _IOC_WRITE, 0x6301, 0x14 },
+{ "linux/chio.h", "CHIOPOSITION", _IOC_WRITE, 0x6303, 0x0c },
+{ "linux/chio.h", "CHIOSPICKER", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/chio.h", "CHIOSVOLTAG", _IOC_WRITE, 0x6312, 0x30 },
+{ "linux/cm4000_cs.h", "CM_IOCARDOFF", _IOC_NONE, 0x6304, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOCGATR", _IOC_READ|_IOC_WRITE, 0x6301, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCGSTATUS", _IOC_READ, 0x6300, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCSPTS", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCSRDR", _IOC_NONE, 0x6303, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOSDBGLVL", _IOC_WRITE, 0x63fa, 0x04 },
+{ "linux/coda.h", "CIOC_KERNEL_VERSION", _IOC_READ|_IOC_WRITE, 0x630a, 0x04 },
+{ "linux/dm-ioctl.h", "DM_DEV_CREATE", _IOC_READ|_IOC_WRITE, 0xfd03, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_REMOVE", _IOC_READ|_IOC_WRITE, 0xfd04, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_RENAME", _IOC_READ|_IOC_WRITE, 0xfd05, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SET_GEOMETRY", _IOC_READ|_IOC_WRITE, 0xfd0f, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_STATUS", _IOC_READ|_IOC_WRITE, 0xfd07, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SUSPEND", _IOC_READ|_IOC_WRITE, 0xfd06, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_WAIT", _IOC_READ|_IOC_WRITE, 0xfd08, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_DEVICES", _IOC_READ|_IOC_WRITE, 0xfd02, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_VERSIONS", _IOC_READ|_IOC_WRITE, 0xfd0d, 0x138 },
+{ "linux/dm-ioctl.h", "DM_REMOVE_ALL", _IOC_READ|_IOC_WRITE, 0xfd01, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_CLEAR", _IOC_READ|_IOC_WRITE, 0xfd0a, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_DEPS", _IOC_READ|_IOC_WRITE, 0xfd0b, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_LOAD", _IOC_READ|_IOC_WRITE, 0xfd09, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_STATUS", _IOC_READ|_IOC_WRITE, 0xfd0c, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TARGET_MSG", _IOC_READ|_IOC_WRITE, 0xfd0e, 0x138 },
+{ "linux/dm-ioctl.h", "DM_VERSION", _IOC_READ|_IOC_WRITE, 0xfd00, 0x138 },
+{ "linux/dma-buf.h", "DMA_BUF_IOCTL_SYNC", _IOC_WRITE, 0x6200, 0x08 },
+{ "linux/dn.h", "OSIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "OSIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dn.h", "SIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "SIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dvb/audio.h", "AUDIO_BILINGUAL_CHANNEL_SELECT", _IOC_NONE, 0x6f14, 0x00 },
+{ "linux/dvb/audio.h", "AUDIO_CHANNEL_SELECT", _IOC_NONE, 0x6f09, 0x00 },
+{ "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 },
+{ "linux/dvb/audio.h", "AUDIO_STOP", _IOC_NONE, 0x6f01, 0x00 },
+{ "linux/dvb/ca.h", "CA_GET_CAP", _IOC_READ, 0x6f81, 0x10 },
+{ "linux/dvb/ca.h", "CA_GET_DESCR_INFO", _IOC_READ, 0x6f83, 0x08 },
+{ "linux/dvb/ca.h", "CA_GET_MSG", _IOC_READ, 0x6f84, 0x10c },
+{ "linux/dvb/ca.h", "CA_GET_SLOT_INFO", _IOC_READ, 0x6f82, 0x0c },
+{ "linux/dvb/ca.h", "CA_RESET", _IOC_NONE, 0x6f80, 0x00 },
+{ "linux/dvb/ca.h", "CA_SEND_MSG", _IOC_WRITE, 0x6f85, 0x10c },
+{ "linux/dvb/ca.h", "CA_SET_DESCR", _IOC_WRITE, 0x6f86, 0x10 },
+{ "linux/dvb/ca.h", "CA_SET_PID", _IOC_WRITE, 0x6f87, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_ADD_PID", _IOC_WRITE, 0x6f33, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_GET_CAPS", _IOC_READ, 0x6f30, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_GET_PES_PIDS", _IOC_READ, 0x6f2f, 0x0a },
+{ "linux/dvb/dmx.h", "DMX_GET_STC", _IOC_READ|_IOC_WRITE, 0x6f32, 0x10 },
+{ "linux/dvb/dmx.h", "DMX_REMOVE_PID", _IOC_WRITE, 0x6f34, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_SET_BUFFER_SIZE", _IOC_NONE, 0x6f2d, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_SET_FILTER", _IOC_WRITE, 0x6f2b, 0x3c },
+{ "linux/dvb/dmx.h", "DMX_SET_PES_FILTER", _IOC_WRITE, 0x6f2c, 0x14 },
+{ "linux/dvb/dmx.h", "DMX_SET_SOURCE", _IOC_WRITE, 0x6f31, 0x04 },
+{ "linux/dvb/dmx.h", "DMX_START", _IOC_NONE, 0x6f29, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_STOP", _IOC_NONE, 0x6f2a, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RECV_SLAVE_REPLY", _IOC_READ, 0x6f40, 0x0c },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RESET_OVERLOAD", _IOC_NONE, 0x6f3e, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_BURST", _IOC_NONE, 0x6f41, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_MASTER_CMD", _IOC_WRITE, 0x6f3f, 0x07 },
+{ "linux/dvb/frontend.h", "FE_DISHNETWORK_SEND_LEGACY_CMD", _IOC_NONE, 0x6f50, 0x00 },
+{ "linux/dvb/frontend.h", "FE_ENABLE_HIGH_LNB_VOLTAGE", _IOC_NONE, 0x6f44, 0x00 },
+{ "linux/dvb/frontend.h", "FE_GET_EVENT", _IOC_READ, 0x6f4e, 0x28 },
+{ "linux/dvb/frontend.h", "FE_GET_FRONTEND", _IOC_READ, 0x6f4d, 0x24 },
+{ "linux/dvb/frontend.h", "FE_GET_INFO", _IOC_READ, 0x6f3d, 0xa8 },
+{ "linux/dvb/frontend.h", "FE_GET_PROPERTY", _IOC_READ, 0x6f53, 0x08 },
+{ "linux/dvb/frontend.h", "FE_READ_BER", _IOC_READ, 0x6f46, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_SIGNAL_STRENGTH", _IOC_READ, 0x6f47, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_SNR", _IOC_READ, 0x6f48, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_STATUS", _IOC_READ, 0x6f45, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_UNCORRECTED_BLOCKS", _IOC_READ, 0x6f49, 0x04 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND", _IOC_WRITE, 0x6f4c, 0x24 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND_TUNE_MODE", _IOC_NONE, 0x6f51, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_PROPERTY", _IOC_WRITE, 0x6f52, 0x08 },
+{ "linux/dvb/frontend.h", "FE_SET_TONE", _IOC_NONE, 0x6f42, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_VOLTAGE", _IOC_NONE, 0x6f43, 0x00 },
+{ "linux/dvb/net.h", "NET_ADD_IF", _IOC_READ|_IOC_WRITE, 0x6f34, 0x06 },
+{ "linux/dvb/net.h", "NET_GET_IF", _IOC_READ|_IOC_WRITE, 0x6f36, 0x06 },
+{ "linux/dvb/net.h", "NET_REMOVE_IF", _IOC_NONE, 0x6f35, 0x00 },
+{ "linux/dvb/osd.h", "OSD_GET_CAPABILITY", _IOC_READ, 0x6fa1, 0x08 },
+{ "linux/dvb/osd.h", "OSD_SEND_CMD", _IOC_WRITE, 0x6fa0, 0x1c },
+{ "linux/dvb/video.h", "VIDEO_CLEAR_BUFFER", _IOC_NONE, 0x6f22, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3b, 0x48 },
+{ "linux/dvb/video.h", "VIDEO_CONTINUE", _IOC_NONE, 0x6f18, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FAST_FORWARD", _IOC_NONE, 0x6f1f, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FREEZE", _IOC_NONE, 0x6f17, 0x00 },
+{ "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 },
+{ "linux/dvb/video.h", "VIDEO_TRY_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3c, 0x48 },
+{ "linux/fb.h", "FBIOBLANK", 0, 0x4611, 0 },
+{ "linux/fb.h", "FBIOGETCMAP", 0, 0x4604, 0 },
+{ "linux/fb.h", "FBIOGET_CON2FBMAP", 0, 0x460F, 0 },
+{ "linux/fb.h", "FBIOGET_DISPINFO", 0, 0x4618, 0 },
+{ "linux/fb.h", "FBIOGET_FSCREENINFO", 0, 0x4602, 0 },
+{ "linux/fb.h", "FBIOGET_GLYPH", 0, 0x4615, 0 },
+{ "linux/fb.h", "FBIOGET_HWCINFO", 0, 0x4616, 0 },
+{ "linux/fb.h", "FBIOGET_VBLANK", _IOC_READ, 0x4612, 0x20 },
+{ "linux/fb.h", "FBIOGET_VSCREENINFO", 0, 0x4600, 0 },
+{ "linux/fb.h", "FBIOPAN_DISPLAY", 0, 0x4606, 0 },
+{ "linux/fb.h", "FBIOPUTCMAP", 0, 0x4605, 0 },
+{ "linux/fb.h", "FBIOPUT_CON2FBMAP", 0, 0x4610, 0 },
+{ "linux/fb.h", "FBIOPUT_MODEINFO", 0, 0x4617, 0 },
+{ "linux/fb.h", "FBIOPUT_VSCREENINFO", 0, 0x4601, 0 },
+{ "linux/fb.h", "FBIO_ALLOC", 0, 0x4613, 0 },
+{ "linux/fb.h", "FBIO_CURSOR", _IOC_READ|_IOC_WRITE, 0x4608, 0x48 },
+{ "linux/fb.h", "FBIO_FREE", 0, 0x4614, 0 },
+{ "linux/fb.h", "FBIO_WAITFORVSYNC", _IOC_WRITE, 0x4620, 0x04 },
+{ "linux/fd.h", "FDCLRPRM", _IOC_NONE, 0x0241, 0x00 },
+{ "linux/fd.h", "FDDEFPRM", _IOC_WRITE, 0x0243, 0x1c },
+{ "linux/fd.h", "FDEJECT", _IOC_NONE, 0x025a, 0x00 },
+{ "linux/fd.h", "FDFLUSH", _IOC_NONE, 0x024b, 0x00 },
+{ "linux/fd.h", "FDFMTBEG", _IOC_NONE, 0x0247, 0x00 },
+{ "linux/fd.h", "FDFMTEND", _IOC_NONE, 0x0249, 0x00 },
+{ "linux/fd.h", "FDFMTTRK", _IOC_WRITE, 0x0248, 0x0c },
+{ "linux/fd.h", "FDGETDRVPRM", _IOC_READ, 0x0211, 0x58 },
+{ "linux/fd.h", "FDGETDRVSTAT", _IOC_READ, 0x0212, 0x34 },
+{ "linux/fd.h", "FDGETDRVTYP", _IOC_READ, 0x020f, 0x10 },
+{ "linux/fd.h", "FDGETFDCSTAT", _IOC_READ, 0x0215, 0x20 },
+{ "linux/fd.h", "FDGETMAXERRS", _IOC_READ, 0x020e, 0x14 },
+{ "linux/fd.h", "FDGETPRM", _IOC_READ, 0x0204, 0x1c },
+{ "linux/fd.h", "FDMSGOFF", _IOC_NONE, 0x0246, 0x00 },
+{ "linux/fd.h", "FDMSGON", _IOC_NONE, 0x0245, 0x00 },
+{ "linux/fd.h", "FDPOLLDRVSTAT", _IOC_READ, 0x0213, 0x34 },
+{ "linux/fd.h", "FDRAWCMD", _IOC_NONE, 0x0258, 0x00 },
+{ "linux/fd.h", "FDRESET", _IOC_NONE, 0x0254, 0x00 },
+{ "linux/fd.h", "FDSETDRVPRM", _IOC_WRITE, 0x0290, 0x58 },
+{ "linux/fd.h", "FDSETEMSGTRESH", _IOC_NONE, 0x024a, 0x00 },
+{ "linux/fd.h", "FDSETMAXERRS", _IOC_WRITE, 0x024c, 0x14 },
+{ "linux/fd.h", "FDSETPRM", _IOC_WRITE, 0x0242, 0x1c },
+{ "linux/fd.h", "FDTWADDLE", _IOC_NONE, 0x0259, 0x00 },
+{ "linux/fd.h", "FDWERRORCLR", _IOC_NONE, 0x0256, 0x00 },
+{ "linux/fd.h", "FDWERRORGET", _IOC_READ, 0x0217, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ADD_DESCRIPTOR", _IOC_READ|_IOC_WRITE, 0x2306, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x2302, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", _IOC_READ|_IOC_WRITE, 0x230d, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x230f, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_CREATE_ISO_CONTEXT", _IOC_READ|_IOC_WRITE, 0x2308, 0x1c },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE", _IOC_WRITE, 0x2303, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", _IOC_WRITE, 0x230e, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x2310, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_FLUSH_ISO", _IOC_WRITE, 0x2318, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER", _IOC_READ, 0x230c, 0x0c },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER2", _IOC_READ|_IOC_WRITE, 0x2314, 0x14 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_INFO", _IOC_READ|_IOC_WRITE, 0x2300, 0x24 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_SPEED", _IOC_NONE, 0x2311, 0x00 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_INITIATE_BUS_RESET", _IOC_WRITE, 0x2305, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_QUEUE_ISO", _IOC_READ|_IOC_WRITE, 0x2309, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", _IOC_WRITE, 0x2316, 0x08 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_REMOVE_DESCRIPTOR", _IOC_WRITE, 0x2307, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", _IOC_WRITE, 0x2312, 0x24 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_PHY_PACKET", _IOC_READ|_IOC_WRITE, 0x2315, 0x14 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_REQUEST", _IOC_WRITE, 0x2301, 0x24 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_RESPONSE", _IOC_WRITE, 0x2304, 0x14 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_STREAM_PACKET", _IOC_WRITE, 0x2313, 0x28 },
+{ "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/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
+{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
+{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
+{ "linux/fs.h", "BLKDISCARD", _IOC_NONE, 0x1277, 0x00 },
+{ "linux/fs.h", "BLKDISCARDZEROES", _IOC_NONE, 0x127c, 0x00 },
+{ "linux/fs.h", "BLKFLSBUF", _IOC_NONE, 0x1261, 0x00 },
+{ "linux/fs.h", "BLKFRAGET", _IOC_NONE, 0x1265, 0x00 },
+{ "linux/fs.h", "BLKFRASET", _IOC_NONE, 0x1264, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE", _IOC_NONE, 0x1260, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE64", _IOC_READ, 0x1272, 0x04 },
+{ "linux/fs.h", "BLKIOMIN", _IOC_NONE, 0x1278, 0x00 },
+{ "linux/fs.h", "BLKIOOPT", _IOC_NONE, 0x1279, 0x00 },
+{ "linux/fs.h", "BLKPBSZGET", _IOC_NONE, 0x127b, 0x00 },
+{ "linux/fs.h", "BLKRAGET", _IOC_NONE, 0x1263, 0x00 },
+{ "linux/fs.h", "BLKRASET", _IOC_NONE, 0x1262, 0x00 },
+{ "linux/fs.h", "BLKROGET", _IOC_NONE, 0x125e, 0x00 },
+{ "linux/fs.h", "BLKROSET", _IOC_NONE, 0x125d, 0x00 },
+{ "linux/fs.h", "BLKROTATIONAL", _IOC_NONE, 0x127e, 0x00 },
+{ "linux/fs.h", "BLKRRPART", _IOC_NONE, 0x125f, 0x00 },
+{ "linux/fs.h", "BLKSECDISCARD", _IOC_NONE, 0x127d, 0x00 },
+{ "linux/fs.h", "BLKSECTGET", _IOC_NONE, 0x1267, 0x00 },
+{ "linux/fs.h", "BLKSECTSET", _IOC_NONE, 0x1266, 0x00 },
+{ "linux/fs.h", "BLKSSZGET", _IOC_NONE, 0x1268, 0x00 },
+{ "linux/fs.h", "BLKTRACESETUP", _IOC_READ|_IOC_WRITE, 0x1273, 0x40 },
+{ "linux/fs.h", "BLKTRACESTART", _IOC_NONE, 0x1274, 0x00 },
+{ "linux/fs.h", "BLKTRACESTOP", _IOC_NONE, 0x1275, 0x00 },
+{ "linux/fs.h", "BLKTRACETEARDOWN", _IOC_NONE, 0x1276, 0x00 },
+{ "linux/fs.h", "BLKZEROOUT", _IOC_NONE, 0x127f, 0x00 },
+{ "linux/fs.h", "FIBMAP", _IOC_NONE, 0x0001, 0x00 },
+{ "linux/fs.h", "FICLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/fs.h", "FICLONERANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/fs.h", "FIDEDUPERANGE", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/fs.h", "FIFREEZE", _IOC_READ|_IOC_WRITE, 0x5877, 0x04 },
+{ "linux/fs.h", "FIGETBSZ", _IOC_NONE, 0x0002, 0x00 },
+{ "linux/fs.h", "FITHAW", _IOC_READ|_IOC_WRITE, 0x5878, 0x04 },
+{ "linux/fs.h", "FITRIM", _IOC_READ|_IOC_WRITE, 0x5879, 0x18 },
+{ "linux/fs.h", "FS_IOC32_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_FIEMAP", _IOC_READ|_IOC_WRITE, 0x660b, 0x20 },
+{ "linux/fs.h", "FS_IOC_FSGETXATTR", _IOC_READ, 0x581f, 0x1c },
+{ "linux/fs.h", "FS_IOC_FSSETXATTR", _IOC_WRITE, 0x5820, 0x1c },
+{ "linux/fs.h", "FS_IOC_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_POLICY", _IOC_WRITE, 0x6615, 0x0c },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_PWSALT", _IOC_WRITE, 0x6614, 0x10 },
+{ "linux/fs.h", "FS_IOC_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
+{ "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 },
+{ "linux/fsl-diu-fb.h", "MFB_GET_PIXFMT", _IOC_READ, 0x4d08, 0x04 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_ALPHA", _IOC_WRITE, 0x4d00, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_AOID", _IOC_WRITE, 0x4d04, 0x08 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_BRIGHTNESS", _IOC_WRITE, 0x4d03, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_CHROMA_KEY", _IOC_WRITE, 0x4d01, 0x0c },
+{ "linux/fsl-diu-fb.h", "MFB_SET_GAMMA", _IOC_WRITE, 0x4d01, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_PIXFMT", _IOC_WRITE, 0x4d08, 0x04 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_DOORBELL", _IOC_READ|_IOC_WRITE, 0xaf06, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_GETPROP", _IOC_READ|_IOC_WRITE, 0xaf07, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_MEMCPY", _IOC_READ|_IOC_WRITE, 0xaf05, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_GET_STATUS", _IOC_READ|_IOC_WRITE, 0xaf02, 0x0c },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_RESTART", _IOC_READ|_IOC_WRITE, 0xaf01, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_START", _IOC_READ|_IOC_WRITE, 0xaf03, 0x10 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_STOP", _IOC_READ|_IOC_WRITE, 0xaf04, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_SETPROP", _IOC_READ|_IOC_WRITE, 0xaf08, 0x28 },
+{ "linux/fuse.h", "FUSE_DEV_IOC_CLONE", _IOC_READ, 0xe500, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_DDCB", _IOC_READ|_IOC_WRITE, 0xa532, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_RAW_DDCB", _IOC_READ|_IOC_WRITE, 0xa533, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_GET_CARD_STATE", _IOC_READ, 0xa524, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_PIN_MEM", _IOC_READ|_IOC_WRITE, 0xa528, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG16", _IOC_READ, 0xa522, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG32", _IOC_READ, 0xa520, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG64", _IOC_READ, 0xa51e, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_READ", _IOC_READ|_IOC_WRITE, 0xa551, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_UPDATE", _IOC_READ|_IOC_WRITE, 0xa550, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_UNPIN_MEM", _IOC_READ|_IOC_WRITE, 0xa529, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG16", _IOC_WRITE, 0xa523, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG32", _IOC_WRITE, 0xa521, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG64", _IOC_WRITE, 0xa51f, 0x10 },
+{ "linux/gigaset_dev.h", "GIGASET_BRKCHARS", _IOC_WRITE, 0x4702, 0x06 },
+{ "linux/gigaset_dev.h", "GIGASET_CONFIG", _IOC_READ|_IOC_WRITE, 0x4701, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_REDIR", _IOC_READ|_IOC_WRITE, 0x4700, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_VERSION", _IOC_READ|_IOC_WRITE, 0x4703, 0x10 },
+{ "linux/gpio.h", "GPIO_GET_CHIPINFO_IOCTL", _IOC_READ, 0xb401, 0x44 },
+{ "linux/gpio.h", "GPIO_GET_LINEINFO_IOCTL", _IOC_READ|_IOC_WRITE, 0xb402, 0x48 },
+{ "linux/gsmmux.h", "GSMIOC_DISABLE_NET", _IOC_NONE, 0x4703, 0x00 },
+{ "linux/gsmmux.h", "GSMIOC_ENABLE_NET", _IOC_WRITE, 0x4702, 0x34 },
+{ "linux/gsmmux.h", "GSMIOC_GETCONF", _IOC_READ, 0x4700, 0x4c },
+{ "linux/gsmmux.h", "GSMIOC_SETCONF", _IOC_WRITE, 0x4701, 0x4c },
+{ "linux/hdreg.h", "HDIO_DRIVE_CMD", 0, 0x031f, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_RESET", 0, 0x031c, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASK", 0, 0x031e, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASKFILE", 0, 0x031d, 0 },
+{ "linux/hdreg.h", "HDIO_GETGEO", 0, 0x0301, 0 },
+{ "linux/hdreg.h", "HDIO_GET_32BIT", 0, 0x0309, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ACOUSTIC", 0, 0x030f, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ADDRESS", 0, 0x0310, 0 },
+{ "linux/hdreg.h", "HDIO_GET_BUSSTATE", 0, 0x031a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_DMA", 0, 0x030b, 0 },
+{ "linux/hdreg.h", "HDIO_GET_IDENTITY", 0, 0x030d, 0 },
+{ "linux/hdreg.h", "HDIO_GET_KEEPSETTINGS", 0, 0x0308, 0 },
+{ "linux/hdreg.h", "HDIO_GET_MULTCOUNT", 0, 0x0304, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NICE", 0, 0x030c, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NOWERR", 0, 0x030a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_QDMA", 0, 0x0305, 0 },
+{ "linux/hdreg.h", "HDIO_GET_UNMASKINTR", 0, 0x0302, 0 },
+{ "linux/hdreg.h", "HDIO_GET_WCACHE", 0, 0x030e, 0 },
+{ "linux/hdreg.h", "HDIO_OBSOLETE_IDENTITY", 0, 0x0307, 0 },
+{ "linux/hdreg.h", "HDIO_SCAN_HWIF", 0, 0x0328, 0 },
+{ "linux/hdreg.h", "HDIO_SET_32BIT", 0, 0x0324, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ACOUSTIC", 0, 0x032c, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ADDRESS", 0, 0x032f, 0 },
+{ "linux/hdreg.h", "HDIO_SET_BUSSTATE", 0, 0x032d, 0 },
+{ "linux/hdreg.h", "HDIO_SET_DMA", 0, 0x0326, 0 },
+{ "linux/hdreg.h", "HDIO_SET_KEEPSETTINGS", 0, 0x0323, 0 },
+{ "linux/hdreg.h", "HDIO_SET_MULTCOUNT", 0, 0x0321, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NICE", 0, 0x0329, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NOWERR", 0, 0x0325, 0 },
+{ "linux/hdreg.h", "HDIO_SET_PIO_MODE", 0, 0x0327, 0 },
+{ "linux/hdreg.h", "HDIO_SET_QDMA", 0, 0x032e, 0 },
+{ "linux/hdreg.h", "HDIO_SET_UNMASKINTR", 0, 0x0322, 0 },
+{ "linux/hdreg.h", "HDIO_SET_WCACHE", 0, 0x032b, 0 },
+{ "linux/hdreg.h", "HDIO_SET_XFER", 0, 0x0306, 0 },
+{ "linux/hdreg.h", "HDIO_TRISTATE_HWIF", 0, 0x031b, 0 },
+{ "linux/hdreg.h", "HDIO_UNREGISTER_HWIF", 0, 0x032a, 0 },
+{ "linux/hid-roccat.h", "ROCCATIOCGREPSIZE", _IOC_READ, 0x48f1, 0x04 },
+{ "linux/hiddev.h", "HIDIOCAPPLICATION", _IOC_NONE, 0x4802, 0x00 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINDEX", _IOC_WRITE, 0x4810, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINFO", _IOC_READ|_IOC_WRITE, 0x4811, 0x10 },
+{ "linux/hiddev.h", "HIDIOCGDEVINFO", _IOC_READ, 0x4803, 0x1c },
+{ "linux/hiddev.h", "HIDIOCGFIELDINFO", _IOC_READ|_IOC_WRITE, 0x480a, 0x38 },
+{ "linux/hiddev.h", "HIDIOCGFLAG", _IOC_READ, 0x480e, 0x04 },
+{ "linux/hiddev.h", "HIDIOCGREPORT", _IOC_WRITE, 0x4807, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGREPORTINFO", _IOC_READ|_IOC_WRITE, 0x4809, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGSTRING", _IOC_READ, 0x4804, 0x104 },
+{ "linux/hiddev.h", "HIDIOCGUCODE", _IOC_READ|_IOC_WRITE, 0x480d, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGE", _IOC_READ|_IOC_WRITE, 0x480b, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGES", _IOC_READ|_IOC_WRITE, 0x4813, 0x101c },
+{ "linux/hiddev.h", "HIDIOCGVERSION", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hiddev.h", "HIDIOCINITREPORT", _IOC_NONE, 0x4805, 0x00 },
+{ "linux/hiddev.h", "HIDIOCSFLAG", _IOC_WRITE, 0x480f, 0x04 },
+{ "linux/hiddev.h", "HIDIOCSREPORT", _IOC_WRITE, 0x4808, 0x0c },
+{ "linux/hiddev.h", "HIDIOCSUSAGE", _IOC_WRITE, 0x480c, 0x18 },
+{ "linux/hiddev.h", "HIDIOCSUSAGES", _IOC_WRITE, 0x4814, 0x101c },
+{ "linux/hidraw.h", "HIDIOCGRAWINFO", _IOC_READ, 0x4803, 0x08 },
+{ "linux/hidraw.h", "HIDIOCGRDESC", _IOC_READ, 0x4802, 0x1004 },
+{ "linux/hidraw.h", "HIDIOCGRDESCSIZE", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hpet.h", "HPET_DPI", _IOC_NONE, 0x6805, 0x00 },
+{ "linux/hpet.h", "HPET_EPI", _IOC_NONE, 0x6804, 0x00 },
+{ "linux/hpet.h", "HPET_IE_OFF", _IOC_NONE, 0x6802, 0x00 },
+{ "linux/hpet.h", "HPET_IE_ON", _IOC_NONE, 0x6801, 0x00 },
+{ "linux/hpet.h", "HPET_INFO", _IOC_READ, 0x6803, 0x0c },
+{ "linux/hpet.h", "HPET_IRQFREQ", _IOC_WRITE, 0x6806, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_CONFIG_BUFS", _IOC_WRITE, 0x431f, 0x20 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_IF_VERSION", _IOC_READ, 0x431e, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_STATE", _IOC_READ, 0x4315, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_SET_WAKELINE", _IOC_WRITE, 0x4317, 0x04 },
+{ "linux/hsi/hsi_char.h", "HSC_GET_RX", _IOC_WRITE, 0x6b14, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_GET_TX", _IOC_WRITE, 0x6b16, 0x10 },
+{ "linux/hsi/hsi_char.h", "HSC_RESET", _IOC_NONE, 0x6b10, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SEND_BREAK", _IOC_NONE, 0x6b12, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_PM", _IOC_NONE, 0x6b11, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_RX", _IOC_WRITE, 0x6b13, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_SET_TX", _IOC_WRITE, 0x6b15, 0x10 },
+{ "linux/i2o-dev.h", "I2OEVTGET", _IOC_READ, 0x690b, 0x68 },
+{ "linux/i2o-dev.h", "I2OEVTREG", _IOC_WRITE, 0x690a, 0x0c },
+{ "linux/i2o-dev.h", "I2OGETIOPS", _IOC_READ, 0x6900, 0x20 },
+{ "linux/i2o-dev.h", "I2OHRTGET", _IOC_READ|_IOC_WRITE, 0x6901, 0x0c },
+{ "linux/i2o-dev.h", "I2OHTML", _IOC_READ|_IOC_WRITE, 0x6909, 0x1c },
+{ "linux/i2o-dev.h", "I2OLCTGET", _IOC_READ|_IOC_WRITE, 0x6902, 0x0c },
+{ "linux/i2o-dev.h", "I2OPARMGET", _IOC_READ|_IOC_WRITE, 0x6904, 0x18 },
+{ "linux/i2o-dev.h", "I2OPARMSET", _IOC_READ|_IOC_WRITE, 0x6903, 0x18 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU32", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OSWDEL", _IOC_READ|_IOC_WRITE, 0x6907, 0x1c },
+{ "linux/i2o-dev.h", "I2OSWDL", _IOC_READ|_IOC_WRITE, 0x6905, 0x1c },
+{ "linux/i2o-dev.h", "I2OSWUL", _IOC_READ|_IOC_WRITE, 0x6906, 0x1c },
+{ "linux/i2o-dev.h", "I2OVALIDATE", _IOC_READ, 0x6908, 0x04 },
+{ "linux/i8k.h", "I8K_BIOS_VERSION", _IOC_READ, 0x6980, 0x04 },
+{ "linux/i8k.h", "I8K_FN_STATUS", _IOC_READ, 0x6983, 0x04 },
+{ "linux/i8k.h", "I8K_GET_FAN", _IOC_READ|_IOC_WRITE, 0x6986, 0x04 },
+{ "linux/i8k.h", "I8K_GET_SPEED", _IOC_READ|_IOC_WRITE, 0x6985, 0x04 },
+{ "linux/i8k.h", "I8K_GET_TEMP", _IOC_READ, 0x6984, 0x04 },
+{ "linux/i8k.h", "I8K_MACHINE_ID", _IOC_READ, 0x6981, 0x04 },
+{ "linux/i8k.h", "I8K_POWER_STATUS", _IOC_READ, 0x6982, 0x04 },
+{ "linux/i8k.h", "I8K_SET_FAN", _IOC_READ|_IOC_WRITE, 0x6987, 0x04 },
+{ "linux/if_pppox.h", "PPPOEIOCDFWD", _IOC_NONE, 0xb101, 0x00 },
+{ "linux/if_pppox.h", "PPPOEIOCSFWD", _IOC_WRITE, 0xb100, 0x04 },
+{ "linux/if_tun.h", "TUNATTACHFILTER", _IOC_WRITE, 0x54d5, 0x08 },
+{ "linux/if_tun.h", "TUNDETACHFILTER", _IOC_WRITE, 0x54d6, 0x08 },
+{ "linux/if_tun.h", "TUNGETFEATURES", _IOC_READ, 0x54cf, 0x04 },
+{ "linux/if_tun.h", "TUNGETFILTER", _IOC_READ, 0x54db, 0x08 },
+{ "linux/if_tun.h", "TUNGETIFF", _IOC_READ, 0x54d2, 0x04 },
+{ "linux/if_tun.h", "TUNGETSNDBUF", _IOC_READ, 0x54d3, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETBE", _IOC_READ, 0x54df, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETHDRSZ", _IOC_READ, 0x54d7, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETLE", _IOC_READ, 0x54dd, 0x04 },
+{ "linux/if_tun.h", "TUNSETDEBUG", _IOC_WRITE, 0x54c9, 0x04 },
+{ "linux/if_tun.h", "TUNSETGROUP", _IOC_WRITE, 0x54ce, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFF", _IOC_WRITE, 0x54ca, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFINDEX", _IOC_WRITE, 0x54da, 0x04 },
+{ "linux/if_tun.h", "TUNSETLINK", _IOC_WRITE, 0x54cd, 0x04 },
+{ "linux/if_tun.h", "TUNSETNOCSUM", _IOC_WRITE, 0x54c8, 0x04 },
+{ "linux/if_tun.h", "TUNSETOFFLOAD", _IOC_WRITE, 0x54d0, 0x04 },
+{ "linux/if_tun.h", "TUNSETOWNER", _IOC_WRITE, 0x54cc, 0x04 },
+{ "linux/if_tun.h", "TUNSETPERSIST", _IOC_WRITE, 0x54cb, 0x04 },
+{ "linux/if_tun.h", "TUNSETQUEUE", _IOC_WRITE, 0x54d9, 0x04 },
+{ "linux/if_tun.h", "TUNSETSNDBUF", _IOC_WRITE, 0x54d4, 0x04 },
+{ "linux/if_tun.h", "TUNSETTXFILTER", _IOC_WRITE, 0x54d1, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETBE", _IOC_WRITE, 0x54de, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETHDRSZ", _IOC_WRITE, 0x54d8, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETLE", _IOC_WRITE, 0x54dc, 0x04 },
+{ "linux/iio/events.h", "IIO_GET_EVENT_FD_IOCTL", _IOC_READ, 0x6990, 0x04 },
+{ "linux/input.h", "EVIOCGEFFECTS", _IOC_READ, 0x4584, 0x04 },
+{ "linux/input.h", "EVIOCGID", _IOC_READ, 0x4502, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE", _IOC_READ, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE_V2", _IOC_READ, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCGMASK", _IOC_READ, 0x4592, 0x10 },
+{ "linux/input.h", "EVIOCGRAB", _IOC_WRITE, 0x4590, 0x04 },
+{ "linux/input.h", "EVIOCGREP", _IOC_READ, 0x4503, 0x08 },
+{ "linux/input.h", "EVIOCGVERSION", _IOC_READ, 0x4501, 0x04 },
+{ "linux/input.h", "EVIOCREVOKE", _IOC_WRITE, 0x4591, 0x04 },
+{ "linux/input.h", "EVIOCRMFF", _IOC_WRITE, 0x4581, 0x04 },
+{ "linux/input.h", "EVIOCSCLOCKID", _IOC_WRITE, 0x45a0, 0x04 },
+{ "linux/input.h", "EVIOCSFF", _IOC_WRITE, 0x4580, 0x2c },
+{ "linux/input.h", "EVIOCSKEYCODE", _IOC_WRITE, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCSKEYCODE_V2", _IOC_WRITE, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCSMASK", _IOC_WRITE, 0x4593, 0x10 },
+{ "linux/input.h", "EVIOCSREP", _IOC_WRITE, 0x4503, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_GET_MAINTENANCE_MODE_CMD", _IOC_READ, 0x691e, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_ADDRESS_CMD", _IOC_READ, 0x6912, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6919, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691b, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_LUN_CMD", _IOC_READ, 0x6914, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_TIMING_PARMS_CMD", _IOC_READ, 0x6917, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG", _IOC_READ|_IOC_WRITE, 0x690c, 0x18 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG_TRUNC", _IOC_READ|_IOC_WRITE, 0x690b, 0x18 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD", _IOC_READ, 0x690e, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691c, 0x0c },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND", _IOC_READ, 0x690d, 0x14 },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND_SETTIME", _IOC_READ, 0x6915, 0x1c },
+{ "linux/ipmi.h", "IPMICTL_SET_GETS_EVENTS_CMD", _IOC_READ, 0x6910, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MAINTENANCE_MODE_CMD", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_ADDRESS_CMD", _IOC_READ, 0x6911, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6918, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691a, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_LUN_CMD", _IOC_READ, 0x6913, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_TIMING_PARMS_CMD", _IOC_READ, 0x6916, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD", _IOC_READ, 0x690f, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691d, 0x0c },
+{ "linux/isdn.h", "IIOCDBGVAR", _IOC_NONE, 0x497f, 0x00 },
+{ "linux/isdn.h", "IIOCDRVCTL", _IOC_NONE, 0x4980, 0x00 },
+{ "linux/isdn.h", "IIOCGETCPS", _IOC_NONE, 0x4915, 0x00 },
+{ "linux/isdn.h", "IIOCGETDVR", _IOC_NONE, 0x4916, 0x00 },
+{ "linux/isdn.h", "IIOCGETMAP", _IOC_NONE, 0x4911, 0x00 },
+{ "linux/isdn.h", "IIOCGETPRF", _IOC_NONE, 0x490f, 0x00 },
+{ "linux/isdn.h", "IIOCGETSET", _IOC_NONE, 0x4908, 0x00 },
+{ "linux/isdn.h", "IIOCNETAIF", _IOC_NONE, 0x4901, 0x00 },
+{ "linux/isdn.h", "IIOCNETALN", _IOC_NONE, 0x4920, 0x00 },
+{ "linux/isdn.h", "IIOCNETANM", _IOC_NONE, 0x4905, 0x00 },
+{ "linux/isdn.h", "IIOCNETASL", _IOC_NONE, 0x4913, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIF", _IOC_NONE, 0x4902, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIL", _IOC_NONE, 0x4914, 0x00 },
+{ "linux/isdn.h", "IIOCNETDLN", _IOC_NONE, 0x4921, 0x00 },
+{ "linux/isdn.h", "IIOCNETDNM", _IOC_NONE, 0x4906, 0x00 },
+{ "linux/isdn.h", "IIOCNETDWRSET", _IOC_NONE, 0x4918, 0x00 },
+{ "linux/isdn.h", "IIOCNETGCF", _IOC_NONE, 0x4904, 0x00 },
+{ "linux/isdn.h", "IIOCNETGNM", _IOC_NONE, 0x4907, 0x00 },
+{ "linux/isdn.h", "IIOCNETGPN", _IOC_NONE, 0x4922, 0x00 },
+{ "linux/isdn.h", "IIOCNETHUP", _IOC_NONE, 0x490b, 0x00 },
+{ "linux/isdn.h", "IIOCNETLCR", _IOC_NONE, 0x4917, 0x00 },
+{ "linux/isdn.h", "IIOCNETSCF", _IOC_NONE, 0x4903, 0x00 },
+{ "linux/isdn.h", "IIOCSETBRJ", _IOC_NONE, 0x490d, 0x00 },
+{ "linux/isdn.h", "IIOCSETGST", _IOC_NONE, 0x490c, 0x00 },
+{ "linux/isdn.h", "IIOCSETMAP", _IOC_NONE, 0x4912, 0x00 },
+{ "linux/isdn.h", "IIOCSETPRF", _IOC_NONE, 0x4910, 0x00 },
+{ "linux/isdn.h", "IIOCSETSET", _IOC_NONE, 0x4909, 0x00 },
+{ "linux/isdn.h", "IIOCSETVER", _IOC_NONE, 0x490a, 0x00 },
+{ "linux/isdn.h", "IIOCSIGPRF", _IOC_NONE, 0x490e, 0x00 },
+{ "linux/isdn_ppp.h", "PPPIOCBUNDLE", _IOC_WRITE, 0x7481, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCGCALLINFO", _IOC_READ|_IOC_WRITE, 0x7480, 0x88 },
+{ "linux/isdn_ppp.h", "PPPIOCGCOMPRESSORS", _IOC_READ, 0x7486, 0x20 },
+{ "linux/isdn_ppp.h", "PPPIOCGIFNAME", _IOC_READ, 0x7488, 0x10 },
+{ "linux/isdn_ppp.h", "PPPIOCGMPFLAGS", _IOC_READ, 0x7482, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSCOMPRESSOR", _IOC_WRITE, 0x7487, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPFLAGS", _IOC_WRITE, 0x7483, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMRU", _IOC_WRITE, 0x7485, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMTU", _IOC_WRITE, 0x7484, 0x04 },
+{ "linux/ivtv.h", "IVTV_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x38 },
+{ "linux/ivtv.h", "IVTV_IOC_PASSTHROUGH_MODE", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/ivtvfb.h", "IVTVFB_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x0c },
+{ "linux/ixjuser.h", "IXJCTL_AEC_GET_LEVEL", _IOC_NONE, 0x71cd, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_START", _IOC_WRITE, 0x71cb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_STOP", _IOC_NONE, 0x71cc, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_CARDTYPE", _IOC_READ, 0x71c1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CID", _IOC_READ, 0x71d4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CIDCW", _IOC_WRITE, 0x71d9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_AGAIN", _IOC_WRITE, 0x71d2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_COEFF_SET", _IOC_WRITE, 0x71d0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_CLEAR", _IOC_NONE, 0x71e7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_READ", _IOC_READ, 0x71e6, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_IDLE", _IOC_NONE, 0x71c5, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_RESET", _IOC_NONE, 0x71c0, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_TYPE", _IOC_READ, 0x71c3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_VERSION", _IOC_READ, 0x71c4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DTMF_PRESCALE", _IOC_WRITE, 0x71e8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FILTER_CADENCE", _IOC_WRITE, 0x71d6, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_READ", _IOC_READ, 0x71e2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_WRITTEN", _IOC_READ, 0x71e3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_GET_FILTER_HIST", _IOC_WRITE, 0x71c8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_HZ", _IOC_WRITE, 0x71e0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INIT_TONE", _IOC_WRITE, 0x71c9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_START", _IOC_WRITE, 0x71fd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_STOP", _IOC_WRITE, 0x71fe, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_MIXER", _IOC_WRITE, 0x71cf, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PLAY_CID", _IOC_NONE, 0x71d7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_PORT", _IOC_WRITE, 0x71d1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_POTS_PSTN", _IOC_WRITE, 0x71d5, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PSTN_LINETEST", _IOC_NONE, 0x71d3, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_RATE", _IOC_WRITE, 0x71e1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_READ_WAIT", _IOC_READ, 0x71e4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_RXG", _IOC_WRITE, 0x71ea, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_TXG", _IOC_WRITE, 0x71eb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SERIAL", _IOC_READ, 0x71c2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER", _IOC_WRITE, 0x71c7, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER_RAW", _IOC_WRITE, 0x71dd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_LED", _IOC_WRITE, 0x71ce, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SIGCTL", _IOC_WRITE, 0x71e9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_TESTRAM", _IOC_NONE, 0x71c6, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_TONE_CADENCE", _IOC_WRITE, 0x71ca, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_VERSION", _IOC_READ, 0x71da, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_VMWI", _IOC_READ, 0x71d8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_WRITE_WAIT", _IOC_READ, 0x71e5, 0x04 },
+{ "linux/joystick.h", "JSIOCGAXES", _IOC_READ, 0x6a11, 0x01 },
+{ "linux/joystick.h", "JSIOCGAXMAP", _IOC_READ, 0x6a32, 0x40 },
+{ "linux/joystick.h", "JSIOCGBTNMAP", _IOC_READ, 0x6a34, 0x400 },
+{ "linux/joystick.h", "JSIOCGBUTTONS", _IOC_READ, 0x6a12, 0x01 },
+{ "linux/joystick.h", "JSIOCGCORR", _IOC_READ, 0x6a22, 0x24 },
+{ "linux/joystick.h", "JSIOCGVERSION", _IOC_READ, 0x6a01, 0x04 },
+{ "linux/joystick.h", "JSIOCSAXMAP", _IOC_WRITE, 0x6a31, 0x40 },
+{ "linux/joystick.h", "JSIOCSBTNMAP", _IOC_WRITE, 0x6a33, 0x400 },
+{ "linux/joystick.h", "JSIOCSCORR", _IOC_WRITE, 0x6a21, 0x24 },
+{ "linux/kcov.h", "KCOV_DISABLE", _IOC_NONE, 0x6365, 0x00 },
+{ "linux/kcov.h", "KCOV_ENABLE", _IOC_NONE, 0x6364, 0x00 },
+{ "linux/kcov.h", "KCOV_INIT_TRACE", _IOC_READ, 0x6301, 0x04 },
+{ "linux/kd.h", "GIO_CMAP", 0, 0x4B70, 0 },
+{ "linux/kd.h", "GIO_FONT", 0, 0x4B60, 0 },
+{ "linux/kd.h", "GIO_FONTX", 0, 0x4B6B, 0 },
+{ "linux/kd.h", "GIO_SCRNMAP", 0, 0x4B40, 0 },
+{ "linux/kd.h", "GIO_UNIMAP", 0, 0x4B66, 0 },
+{ "linux/kd.h", "GIO_UNISCRNMAP", 0, 0x4B69, 0 },
+{ "linux/kd.h", "KDADDIO", 0, 0x4B34, 0 },
+{ "linux/kd.h", "KDDELIO", 0, 0x4B35, 0 },
+{ "linux/kd.h", "KDDISABIO", 0, 0x4B37, 0 },
+{ "linux/kd.h", "KDENABIO", 0, 0x4B36, 0 },
+{ "linux/kd.h", "KDFONTOP", 0, 0x4B72, 0 },
+{ "linux/kd.h", "KDGETKEYCODE", 0, 0x4B4C, 0 },
+{ "linux/kd.h", "KDGETLED", 0, 0x4B31, 0 },
+{ "linux/kd.h", "KDGETMODE", 0, 0x4B3B, 0 },
+{ "linux/kd.h", "KDGKBDIACR", 0, 0x4B4A, 0 },
+{ "linux/kd.h", "KDGKBDIACRUC", 0, 0x4BFA, 0 },
+{ "linux/kd.h", "KDGKBENT", 0, 0x4B46, 0 },
+{ "linux/kd.h", "KDGKBLED", 0, 0x4B64, 0 },
+{ "linux/kd.h", "KDGKBMETA", 0, 0x4B62, 0 },
+{ "linux/kd.h", "KDGKBMODE", 0, 0x4B44, 0 },
+{ "linux/kd.h", "KDGKBSENT", 0, 0x4B48, 0 },
+{ "linux/kd.h", "KDGKBTYPE", 0, 0x4B33, 0 },
+{ "linux/kd.h", "KDKBDREP", 0, 0x4B52, 0 },
+{ "linux/kd.h", "KDMAPDISP", 0, 0x4B3C, 0 },
+{ "linux/kd.h", "KDMKTONE", 0, 0x4B30, 0 },
+{ "linux/kd.h", "KDSETKEYCODE", 0, 0x4B4D, 0 },
+{ "linux/kd.h", "KDSETLED", 0, 0x4B32, 0 },
+{ "linux/kd.h", "KDSETMODE", 0, 0x4B3A, 0 },
+{ "linux/kd.h", "KDSIGACCEPT", 0, 0x4B4E, 0 },
+{ "linux/kd.h", "KDSKBDIACR", 0, 0x4B4B, 0 },
+{ "linux/kd.h", "KDSKBDIACRUC", 0, 0x4BFB, 0 },
+{ "linux/kd.h", "KDSKBENT", 0, 0x4B47, 0 },
+{ "linux/kd.h", "KDSKBLED", 0, 0x4B65, 0 },
+{ "linux/kd.h", "KDSKBMETA", 0, 0x4B63, 0 },
+{ "linux/kd.h", "KDSKBMODE", 0, 0x4B45, 0 },
+{ "linux/kd.h", "KDSKBSENT", 0, 0x4B49, 0 },
+{ "linux/kd.h", "KDUNMAPDISP", 0, 0x4B3D, 0 },
+{ "linux/kd.h", "KIOCSOUND", 0, 0x4B2F, 0 },
+{ "linux/kd.h", "PIO_CMAP", 0, 0x4B71, 0 },
+{ "linux/kd.h", "PIO_FONT", 0, 0x4B61, 0 },
+{ "linux/kd.h", "PIO_FONTRESET", 0, 0x4B6D, 0 },
+{ "linux/kd.h", "PIO_FONTX", 0, 0x4B6C, 0 },
+{ "linux/kd.h", "PIO_SCRNMAP", 0, 0x4B41, 0 },
+{ "linux/kd.h", "PIO_UNIMAP", 0, 0x4B67, 0 },
+{ "linux/kd.h", "PIO_UNIMAPCLR", 0, 0x4B68, 0 },
+{ "linux/kd.h", "PIO_UNISCRNMAP", 0, 0x4B6A, 0 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_EVENT", _IOC_READ|_IOC_WRITE, 0x4b08, 0x20 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b02, 0x58 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_ADDRESS_WATCH", _IOC_WRITE, 0x4b0f, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_REGISTER", _IOC_WRITE, 0x4b0d, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_UNREGISTER", _IOC_WRITE, 0x4b0e, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_WAVE_CONTROL", _IOC_WRITE, 0x4b10, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_EVENT", _IOC_WRITE, 0x4b09, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b03, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_CLOCK_COUNTERS", _IOC_READ|_IOC_WRITE, 0x4b05, 0x28 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_PROCESS_APERTURES", _IOC_READ, 0x4b06, 0x190 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
+{ "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_UPDATE_QUEUE", _IOC_WRITE, 0x4b07, 0x18 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_WAIT_EVENTS", _IOC_READ|_IOC_WRITE, 0x4b0c, 0x18 },
+{ "linux/kvm.h", "KVM_ALLOCATE_RMA", _IOC_READ, 0xaea9, 0x08 },
+{ "linux/kvm.h", "KVM_ARM_PREFERRED_TARGET", _IOC_READ, 0xaeaf, 0x20 },
+{ "linux/kvm.h", "KVM_ARM_SET_DEVICE_ADDR", _IOC_WRITE, 0xaeab, 0x10 },
+{ "linux/kvm.h", "KVM_ARM_VCPU_INIT", _IOC_WRITE, 0xaeae, 0x20 },
+{ "linux/kvm.h", "KVM_ASSIGN_DEV_IRQ", _IOC_WRITE, 0xae70, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_PCI_DEVICE", _IOC_READ, 0xae69, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_INTX_MASK", _IOC_WRITE, 0xaea4, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_ENTRY", _IOC_WRITE, 0xae74, 0x10 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_NR", _IOC_WRITE, 0xae73, 0x08 },
+{ "linux/kvm.h", "KVM_CHECK_EXTENSION", _IOC_NONE, 0xae03, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_DEVICE", _IOC_READ|_IOC_WRITE, 0xaee0, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_IRQCHIP", _IOC_NONE, 0xae60, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT", _IOC_NONE, 0xae64, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT2", _IOC_WRITE, 0xae77, 0x40 },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE", _IOC_WRITE, 0xaea8, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE_64", _IOC_WRITE, 0xaea8, 0x20 },
+{ "linux/kvm.h", "KVM_CREATE_VCPU", _IOC_NONE, 0xae41, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_VM", _IOC_NONE, 0xae01, 0x00 },
+{ "linux/kvm.h", "KVM_DEASSIGN_DEV_IRQ", _IOC_WRITE, 0xae75, 0x40 },
+{ "linux/kvm.h", "KVM_DEASSIGN_PCI_DEVICE", _IOC_WRITE, 0xae72, 0x40 },
+{ "linux/kvm.h", "KVM_DIRTY_TLB", _IOC_WRITE, 0xaeaa, 0x0c },
+{ "linux/kvm.h", "KVM_ENABLE_CAP", _IOC_WRITE, 0xaea3, 0x68 },
+{ "linux/kvm.h", "KVM_GET_API_VERSION", _IOC_NONE, 0xae00, 0x00 },
+{ "linux/kvm.h", "KVM_GET_CLOCK", _IOC_READ, 0xae7c, 0x30 },
+{ "linux/kvm.h", "KVM_GET_CPUID2", _IOC_READ|_IOC_WRITE, 0xae91, 0x08 },
+{ "linux/kvm.h", "KVM_GET_DEBUGREGS", _IOC_READ, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_GET_DEVICE_ATTR", _IOC_WRITE, 0xaee2, 0x18 },
+{ "linux/kvm.h", "KVM_GET_DIRTY_LOG", _IOC_WRITE, 0xae42, 0x10 },
+{ "linux/kvm.h", "KVM_GET_EMULATED_CPUID", _IOC_READ|_IOC_WRITE, 0xae09, 0x08 },
+{ "linux/kvm.h", "KVM_GET_FPU", _IOC_READ, 0xae8c, 0x1a0 },
+{ "linux/kvm.h", "KVM_GET_IRQCHIP", _IOC_READ|_IOC_WRITE, 0xae62, 0x208 },
+{ "linux/kvm.h", "KVM_GET_LAPIC", _IOC_READ, 0xae8e, 0x400 },
+{ "linux/kvm.h", "KVM_GET_MP_STATE", _IOC_READ, 0xae98, 0x04 },
+{ "linux/kvm.h", "KVM_GET_MSRS", _IOC_READ|_IOC_WRITE, 0xae88, 0x08 },
+{ "linux/kvm.h", "KVM_GET_MSR_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae02, 0x04 },
+{ "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 },
+{ "linux/kvm.h", "KVM_GET_PIT2", _IOC_READ, 0xae9f, 0x70 },
+{ "linux/kvm.h", "KVM_GET_REGS", _IOC_READ, 0xae81, 0x90 },
+{ "linux/kvm.h", "KVM_GET_REG_LIST", _IOC_READ|_IOC_WRITE, 0xaeb0, 0x08 },
+{ "linux/kvm.h", "KVM_GET_SREGS", _IOC_READ, 0xae83, 0x138 },
+{ "linux/kvm.h", "KVM_GET_SUPPORTED_CPUID", _IOC_READ|_IOC_WRITE, 0xae05, 0x08 },
+{ "linux/kvm.h", "KVM_GET_TSC_KHZ", _IOC_NONE, 0xaea3, 0x00 },
+{ "linux/kvm.h", "KVM_GET_VCPU_EVENTS", _IOC_READ, 0xae9f, 0x40 },
+{ "linux/kvm.h", "KVM_GET_VCPU_MMAP_SIZE", _IOC_NONE, 0xae04, 0x00 },
+{ "linux/kvm.h", "KVM_GET_XCRS", _IOC_READ, 0xaea6, 0x188 },
+{ "linux/kvm.h", "KVM_GET_XSAVE", _IOC_READ, 0xaea4, 0x1000 },
+{ "linux/kvm.h", "KVM_HAS_DEVICE_ATTR", _IOC_WRITE, 0xaee3, 0x18 },
+{ "linux/kvm.h", "KVM_INTERRUPT", _IOC_WRITE, 0xae86, 0x04 },
+{ "linux/kvm.h", "KVM_IOEVENTFD", _IOC_WRITE, 0xae79, 0x40 },
+{ "linux/kvm.h", "KVM_IRQFD", _IOC_WRITE, 0xae76, 0x20 },
+{ "linux/kvm.h", "KVM_IRQ_LINE", _IOC_WRITE, 0xae61, 0x08 },
+{ "linux/kvm.h", "KVM_IRQ_LINE_STATUS", _IOC_READ|_IOC_WRITE, 0xae67, 0x08 },
+{ "linux/kvm.h", "KVM_KVMCLOCK_CTRL", _IOC_NONE, 0xaead, 0x00 },
+{ "linux/kvm.h", "KVM_NMI", _IOC_NONE, 0xae9a, 0x00 },
+{ "linux/kvm.h", "KVM_PPC_ALLOCATE_HTAB", _IOC_READ|_IOC_WRITE, 0xaea7, 0x04 },
+{ "linux/kvm.h", "KVM_PPC_GET_HTAB_FD", _IOC_WRITE, 0xaeaa, 0x20 },
+{ "linux/kvm.h", "KVM_PPC_GET_PVINFO", _IOC_WRITE, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_PPC_GET_SMMU_INFO", _IOC_READ, 0xaea6, 0x250 },
+{ "linux/kvm.h", "KVM_PPC_RTAS_DEFINE_TOKEN", _IOC_WRITE, 0xaeac, 0x80 },
+{ "linux/kvm.h", "KVM_REGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae67, 0x10 },
+{ "linux/kvm.h", "KVM_REINJECT_CONTROL", _IOC_NONE, 0xae71, 0x00 },
+{ "linux/kvm.h", "KVM_RUN", _IOC_NONE, 0xae80, 0x00 },
+{ "linux/kvm.h", "KVM_S390_ENABLE_SIE", _IOC_NONE, 0xae06, 0x00 },
+{ "linux/kvm.h", "KVM_S390_GET_IRQ_STATE", _IOC_WRITE, 0xaeb6, 0x20 },
+{ "linux/kvm.h", "KVM_S390_GET_SKEYS", _IOC_WRITE, 0xaeb2, 0x40 },
+{ "linux/kvm.h", "KVM_S390_INITIAL_RESET", _IOC_NONE, 0xae97, 0x00 },
+{ "linux/kvm.h", "KVM_S390_INTERRUPT", _IOC_WRITE, 0xae94, 0x10 },
+{ "linux/kvm.h", "KVM_S390_IRQ", _IOC_WRITE, 0xaeb4, 0x48 },
+{ "linux/kvm.h", "KVM_S390_MEM_OP", _IOC_WRITE, 0xaeb1, 0x40 },
+{ "linux/kvm.h", "KVM_S390_SET_INITIAL_PSW", _IOC_WRITE, 0xae96, 0x10 },
+{ "linux/kvm.h", "KVM_S390_SET_IRQ_STATE", _IOC_WRITE, 0xaeb5, 0x20 },
+{ "linux/kvm.h", "KVM_S390_SET_SKEYS", _IOC_WRITE, 0xaeb3, 0x40 },
+{ "linux/kvm.h", "KVM_S390_STORE_STATUS", _IOC_WRITE, 0xae95, 0x04 },
+{ "linux/kvm.h", "KVM_S390_UCAS_MAP", _IOC_WRITE, 0xae50, 0x18 },
+{ "linux/kvm.h", "KVM_S390_UCAS_UNMAP", _IOC_WRITE, 0xae51, 0x18 },
+{ "linux/kvm.h", "KVM_S390_VCPU_FAULT", _IOC_WRITE, 0xae52, 0x04 },
+{ "linux/kvm.h", "KVM_SET_BOOT_CPU_ID", _IOC_NONE, 0xae78, 0x00 },
+{ "linux/kvm.h", "KVM_SET_CLOCK", _IOC_WRITE, 0xae7b, 0x30 },
+{ "linux/kvm.h", "KVM_SET_CPUID", _IOC_WRITE, 0xae8a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_CPUID2", _IOC_WRITE, 0xae90, 0x08 },
+{ "linux/kvm.h", "KVM_SET_DEBUGREGS", _IOC_WRITE, 0xaea2, 0x80 },
+{ "linux/kvm.h", "KVM_SET_DEVICE_ATTR", _IOC_WRITE, 0xaee1, 0x18 },
+{ "linux/kvm.h", "KVM_SET_FPU", _IOC_WRITE, 0xae8d, 0x1a0 },
+{ "linux/kvm.h", "KVM_SET_GSI_ROUTING", _IOC_WRITE, 0xae6a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_GUEST_DEBUG", _IOC_WRITE, 0xae9b, 0x48 },
+{ "linux/kvm.h", "KVM_SET_IDENTITY_MAP_ADDR", _IOC_WRITE, 0xae48, 0x08 },
+{ "linux/kvm.h", "KVM_SET_IRQCHIP", _IOC_READ, 0xae63, 0x208 },
+{ "linux/kvm.h", "KVM_SET_LAPIC", _IOC_WRITE, 0xae8f, 0x400 },
+{ "linux/kvm.h", "KVM_SET_MEMORY_ALIAS", _IOC_WRITE, 0xae43, 0x20 },
+{ "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_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 },
+{ "linux/kvm.h", "KVM_SET_PIT2", _IOC_WRITE, 0xaea0, 0x70 },
+{ "linux/kvm.h", "KVM_SET_REGS", _IOC_WRITE, 0xae82, 0x90 },
+{ "linux/kvm.h", "KVM_SET_SIGNAL_MASK", _IOC_WRITE, 0xae8b, 0x04 },
+{ "linux/kvm.h", "KVM_SET_SREGS", _IOC_WRITE, 0xae84, 0x138 },
+{ "linux/kvm.h", "KVM_SET_TSC_KHZ", _IOC_NONE, 0xaea2, 0x00 },
+{ "linux/kvm.h", "KVM_SET_TSS_ADDR", _IOC_NONE, 0xae47, 0x00 },
+{ "linux/kvm.h", "KVM_SET_USER_MEMORY_REGION", _IOC_WRITE, 0xae46, 0x20 },
+{ "linux/kvm.h", "KVM_SET_VAPIC_ADDR", _IOC_WRITE, 0xae93, 0x08 },
+{ "linux/kvm.h", "KVM_SET_VCPU_EVENTS", _IOC_WRITE, 0xaea0, 0x40 },
+{ "linux/kvm.h", "KVM_SET_XCRS", _IOC_WRITE, 0xaea7, 0x188 },
+{ "linux/kvm.h", "KVM_SET_XSAVE", _IOC_WRITE, 0xaea5, 0x1000 },
+{ "linux/kvm.h", "KVM_SIGNAL_MSI", _IOC_WRITE, 0xaea5, 0x20 },
+{ "linux/kvm.h", "KVM_SMI", _IOC_NONE, 0xaeb7, 0x00 },
+{ "linux/kvm.h", "KVM_TPR_ACCESS_REPORTING", _IOC_READ|_IOC_WRITE, 0xae92, 0x28 },
+{ "linux/kvm.h", "KVM_TRANSLATE", _IOC_READ|_IOC_WRITE, 0xae85, 0x18 },
+{ "linux/kvm.h", "KVM_UNREGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae68, 0x10 },
+{ "linux/kvm.h", "KVM_X86_GET_MCE_CAP_SUPPORTED", _IOC_READ, 0xae9d, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SETUP_MCE", _IOC_WRITE, 0xae9c, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SET_MCE", _IOC_WRITE, 0xae9e, 0x40 },
+{ "linux/kvm.h", "KVM_XEN_HVM_CONFIG", _IOC_WRITE, 0xae7a, 0x38 },
+{ "linux/lightnvm.h", "NVM_DEV_CREATE", _IOC_WRITE, 0x4c22, 0x80 },
+{ "linux/lightnvm.h", "NVM_DEV_FACTORY", _IOC_WRITE, 0x4c25, 0x24 },
+{ "linux/lightnvm.h", "NVM_DEV_INIT", _IOC_WRITE, 0x4c24, 0x2c },
+{ "linux/lightnvm.h", "NVM_DEV_REMOVE", _IOC_WRITE, 0x4c23, 0x24 },
+{ "linux/lightnvm.h", "NVM_GET_DEVICES", _IOC_READ, 0x4c21, 0x1000 },
+{ "linux/lightnvm.h", "NVM_INFO", _IOC_READ|_IOC_WRITE, 0x4c20, 0x1000 },
+{ "linux/lirc.h", "LIRC_GET_FEATURES", _IOC_READ, 0x6900, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_LENGTH", _IOC_READ, 0x690f, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_PULSE", _IOC_READ, 0x690b, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_SPACE", _IOC_READ, 0x690d, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_TIMEOUT", _IOC_READ, 0x6909, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_PULSE", _IOC_READ, 0x690a, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_SPACE", _IOC_READ, 0x690c, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_TIMEOUT", _IOC_READ, 0x6908, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_CARRIER", _IOC_READ, 0x6904, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_DUTY_CYCLE", _IOC_READ, 0x6906, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_MODE", _IOC_READ, 0x6902, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_RESOLUTION", _IOC_READ, 0x6907, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_CARRIER", _IOC_READ, 0x6903, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_DUTY_CYCLE", _IOC_READ, 0x6905, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_MODE", _IOC_READ, 0x6901, 0x04 },
+{ "linux/lirc.h", "LIRC_NOTIFY_DECODE", _IOC_NONE, 0x6920, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_END", _IOC_NONE, 0x6922, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_START", _IOC_NONE, 0x6921, 0x00 },
+{ "linux/lirc.h", "LIRC_SET_MEASURE_CARRIER_MODE", _IOC_WRITE, 0x691d, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER", _IOC_WRITE, 0x6914, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER_RANGE", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE", _IOC_WRITE, 0x6916, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE_RANGE", _IOC_WRITE, 0x691e, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER", _IOC_WRITE, 0x691c, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_PULSE", _IOC_WRITE, 0x691a, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_SPACE", _IOC_WRITE, 0x691b, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_MODE", _IOC_WRITE, 0x6912, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT", _IOC_WRITE, 0x6918, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT_REPORTS", _IOC_WRITE, 0x6919, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_CARRIER", _IOC_WRITE, 0x6913, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_DUTY_CYCLE", _IOC_WRITE, 0x6915, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_MODE", _IOC_WRITE, 0x6911, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_TRANSMITTER_MASK", _IOC_WRITE, 0x6917, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_WIDEBAND_RECEIVER", _IOC_WRITE, 0x6923, 0x04 },
+{ "linux/loop.h", "LOOP_CHANGE_FD", 0, 0x4C06, 0 },
+{ "linux/loop.h", "LOOP_CLR_FD", 0, 0x4C01, 0 },
+{ "linux/loop.h", "LOOP_CTL_ADD", 0, 0x4C80, 0 },
+{ "linux/loop.h", "LOOP_CTL_GET_FREE", 0, 0x4C82, 0 },
+{ "linux/loop.h", "LOOP_CTL_REMOVE", 0, 0x4C81, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS", 0, 0x4C03, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS64", 0, 0x4C05, 0 },
+{ "linux/loop.h", "LOOP_SET_CAPACITY", 0, 0x4C07, 0 },
+{ "linux/loop.h", "LOOP_SET_DIRECT_IO", 0, 0x4C08, 0 },
+{ "linux/loop.h", "LOOP_SET_FD", 0, 0x4C00, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS", 0, 0x4C02, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS64", 0, 0x4C04, 0 },
+{ "linux/mISDNif.h", "IMADDTIMER", _IOC_READ, 0x4940, 0x04 },
+{ "linux/mISDNif.h", "IMCLEAR_L2", _IOC_READ, 0x4946, 0x04 },
+{ "linux/mISDNif.h", "IMCTRLREQ", _IOC_READ, 0x4945, 0x04 },
+{ "linux/mISDNif.h", "IMDELTIMER", _IOC_READ, 0x4941, 0x04 },
+{ "linux/mISDNif.h", "IMGETCOUNT", _IOC_READ, 0x4943, 0x04 },
+{ "linux/mISDNif.h", "IMGETDEVINFO", _IOC_READ, 0x4944, 0x04 },
+{ "linux/mISDNif.h", "IMGETVERSION", _IOC_READ, 0x4942, 0x04 },
+{ "linux/mISDNif.h", "IMHOLD_L1", _IOC_READ, 0x4948, 0x04 },
+{ "linux/mISDNif.h", "IMSETDEVNAME", _IOC_READ, 0x4947, 0x18 },
+{ "linux/matroxfb.h", "MATROXFB_GET_ALL_OUTPUTS", _IOC_READ, 0x6efb, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_AVAILABLE_OUTPUTS", _IOC_READ, 0x6ef9, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_CONNECTION", _IOC_READ, 0x6ef8, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_MODE", _IOC_READ|_IOC_WRITE, 0x6efa, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_CONNECTION", _IOC_WRITE, 0x6ef8, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_MODE", _IOC_WRITE, 0x6efa, 0x04 },
+{ "linux/media.h", "MEDIA_IOC_DEVICE_INFO", _IOC_READ|_IOC_WRITE, 0x7c00, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_ENTITIES", _IOC_READ|_IOC_WRITE, 0x7c01, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_LINKS", _IOC_READ|_IOC_WRITE, 0x7c02, 0x1c },
+{ "linux/media.h", "MEDIA_IOC_G_TOPOLOGY", _IOC_READ|_IOC_WRITE, 0x7c04, 0x48 },
+{ "linux/media.h", "MEDIA_IOC_SETUP_LINK", _IOC_READ|_IOC_WRITE, 0x7c03, 0x34 },
+{ "linux/mei.h", "IOCTL_MEI_CONNECT_CLIENT", _IOC_READ|_IOC_WRITE, 0x4801, 0x10 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_GET", _IOC_READ, 0x4803, 0x04 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_SET", _IOC_WRITE, 0x4802, 0x04 },
+{ "linux/meye.h", "MEYEIOC_G_PARAMS", _IOC_READ, 0x76c0, 0x06 },
+{ "linux/meye.h", "MEYEIOC_QBUF_CAPT", _IOC_WRITE, 0x76c2, 0x04 },
+{ "linux/meye.h", "MEYEIOC_STILLCAPT", _IOC_NONE, 0x76c4, 0x00 },
+{ "linux/meye.h", "MEYEIOC_STILLJCAPT", _IOC_READ, 0x76c5, 0x04 },
+{ "linux/meye.h", "MEYEIOC_SYNC", _IOC_READ|_IOC_WRITE, 0x76c3, 0x04 },
+{ "linux/meye.h", "MEYEIOC_S_PARAMS", _IOC_WRITE, 0x76c1, 0x06 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_ADD_DEVICE", _IOC_READ|_IOC_WRITE, 0x7301, 0x04 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_CONFIG_CHANGE", _IOC_READ|_IOC_WRITE, 0x7305, 0x04 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_COPY_DESC", _IOC_READ|_IOC_WRITE, 0x7302, 0x04 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_CMD", _IOC_READ|_IOC_WRITE, 0xb300, 0x48 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_MULTI_CMD", _IOC_READ|_IOC_WRITE, 0xb301, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_GETBITS", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETCOUNTER", _IOC_READ, 0x6d09, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_GETFREQ", _IOC_READ, 0x6d02, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_GETOFFSET", _IOC_NONE, 0x6d00, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETRES", _IOC_READ, 0x6d01, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_MMAPAVAIL", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_ATTRIBUTES", _IOC_READ, 0x7210, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_VOLUME_ID", _IOC_READ, 0x7213, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_SET_ATTRIBUTES", _IOC_WRITE, 0x7211, 0x04 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_BOTH", _IOC_READ, 0x7201, 0x218 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_SHORT", _IOC_READ, 0x7202, 0x218 },
+{ "linux/mtio.h", "MTIOCGET", _IOC_READ, 0x6d02, 0x1c },
+{ "linux/mtio.h", "MTIOCPOS", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/mtio.h", "MTIOCTOP", _IOC_WRITE, 0x6d01, 0x08 },
+{ "linux/nbd.h", "NBD_CLEAR_QUE", _IOC_NONE, 0xab05, 0x00 },
+{ "linux/nbd.h", "NBD_CLEAR_SOCK", _IOC_NONE, 0xab04, 0x00 },
+{ "linux/nbd.h", "NBD_DISCONNECT", _IOC_NONE, 0xab08, 0x00 },
+{ "linux/nbd.h", "NBD_DO_IT", _IOC_NONE, 0xab03, 0x00 },
+{ "linux/nbd.h", "NBD_PRINT_DEBUG", _IOC_NONE, 0xab06, 0x00 },
+{ "linux/nbd.h", "NBD_SET_BLKSIZE", _IOC_NONE, 0xab01, 0x00 },
+{ "linux/nbd.h", "NBD_SET_FLAGS", _IOC_NONE, 0xab0a, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE", _IOC_NONE, 0xab02, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE_BLOCKS", _IOC_NONE, 0xab07, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SOCK", _IOC_NONE, 0xab00, 0x00 },
+{ "linux/nbd.h", "NBD_SET_TIMEOUT", _IOC_NONE, 0xab09, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_CONN_LOGGED_IN", _IOC_NONE, 0x6e03, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETCHARSETS", _IOC_READ|_IOC_WRITE, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_GETDENTRYTTL", _IOC_WRITE, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID", _IOC_WRITE, 0x6e02, 0x02 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID2", _IOC_WRITE, 0x6e02, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETOBJECTNAME", _IOC_READ|_IOC_WRITE, 0x6e09, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GETPRIVATEDATA", _IOC_READ|_IOC_WRITE, 0x6e0a, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETROOT", _IOC_WRITE, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO", _IOC_READ|_IOC_WRITE, 0x6e04, 0x28 },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO_V2", _IOC_READ|_IOC_WRITE, 0x6e04, 0x24 },
+{ "linux/ncp_fs.h", "NCP_IOC_LOCKUNLOCK", _IOC_READ, 0x6e07, 0x14 },
+{ "linux/ncp_fs.h", "NCP_IOC_NCPREQUEST", _IOC_READ, 0x6e01, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SETCHARSETS", _IOC_READ, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_SETDENTRYTTL", _IOC_READ, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETOBJECTNAME", _IOC_READ, 0x6e09, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SETPRIVATEDATA", _IOC_READ, 0x6e0a, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETROOT", _IOC_READ, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SET_SIGN_WANTED", _IOC_WRITE, 0x6e06, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_INIT", _IOC_READ, 0x6e05, 0x18 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_WANTED", _IOC_READ, 0x6e06, 0x04 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_CAP", _IOC_READ|_IOC_WRITE, 0x4e01, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_START", _IOC_READ|_IOC_WRITE, 0x4e02, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_STATUS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x30 },
+{ "linux/ndctl.h", "ND_IOCTL_CALL", _IOC_READ|_IOC_WRITE, 0x4e0a, 0x40 },
+{ "linux/ndctl.h", "ND_IOCTL_CLEAR_ERROR", _IOC_READ|_IOC_WRITE, 0x4e04, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_DIMM_FLAGS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e05, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_SIZE", _IOC_READ|_IOC_WRITE, 0x4e04, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_SET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e06, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART", _IOC_READ|_IOC_WRITE, 0x4e01, 0x84 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART_THRESHOLD", _IOC_READ|_IOC_WRITE, 0x4e02, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_VENDOR", _IOC_READ|_IOC_WRITE, 0x4e09, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CHANGE_CPMODE", _IOC_WRITE, 0x6e80, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CLEAN_SEGMENTS", _IOC_WRITE, 0x6e88, 0x78 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_DELETE_CHECKPOINT", _IOC_WRITE, 0x6e81, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_BDESCS", _IOC_READ|_IOC_WRITE, 0x6e87, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPINFO", _IOC_READ, 0x6e82, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPSTAT", _IOC_READ, 0x6e83, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUINFO", _IOC_READ, 0x6e84, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUSTAT", _IOC_READ, 0x6e85, 0x30 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_VINFO", _IOC_READ|_IOC_WRITE, 0x6e86, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_RESIZE", _IOC_WRITE, 0x6e8b, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_ALLOC_RANGE", _IOC_WRITE, 0x6e8c, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_SUINFO", _IOC_WRITE, 0x6e8d, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SYNC", _IOC_READ, 0x6e8a, 0x08 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ADMIN_CMD", _IOC_READ|_IOC_WRITE, 0x4e41, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ID", _IOC_NONE, 0x4e40, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_IO_CMD", _IOC_READ|_IOC_WRITE, 0x4e43, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESCAN", _IOC_NONE, 0x4e46, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESET", _IOC_NONE, 0x4e44, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBMIT_IO", _IOC_WRITE, 0x4e42, 0x2c },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBSYS_RESET", _IOC_NONE, 0x4e45, 0x00 },
+{ "linux/nvram.h", "NVRAM_INIT", _IOC_NONE, 0x7040, 0x00 },
+{ "linux/nvram.h", "NVRAM_SETCKS", _IOC_NONE, 0x7041, 0x00 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AEWB_CFG", _IOC_READ|_IOC_WRITE, 0x56c3, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AF_CFG", _IOC_READ|_IOC_WRITE, 0x56c5, 0x4c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_CCDC_CFG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_HIST_CFG", _IOC_READ|_IOC_WRITE, 0x56c4, 0x30 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_PRV_CFG", _IOC_READ|_IOC_WRITE, 0x56c2, 0x3c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_EN", _IOC_READ|_IOC_WRITE, 0x56c7, 0x04 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_REQ", _IOC_READ|_IOC_WRITE, 0x56c6, 0x18 },
+{ "linux/omapfb.h", "OMAPFB_CTRL_TEST", _IOC_WRITE, 0x4f2e, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_CAPS", _IOC_READ, 0x4f2a, 0x0c },
+{ "linux/omapfb.h", "OMAPFB_GET_COLOR_KEY", _IOC_WRITE, 0x4f33, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_GET_DISPLAY_INFO", _IOC_READ, 0x4f3f, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_GET_OVERLAY_COLORMODE", _IOC_READ, 0x4f3b, 0x3c },
+{ "linux/omapfb.h", "OMAPFB_GET_UPDATE_MODE", _IOC_WRITE, 0x4f2b, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_VRAM_INFO", _IOC_READ, 0x4f3d, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_LCD_TEST", _IOC_WRITE, 0x4f2d, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_MEMORY_READ", _IOC_READ, 0x4f3a, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_MIRROR", _IOC_WRITE, 0x4f1f, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_MEM", _IOC_WRITE, 0x4f38, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_PLANE", _IOC_WRITE, 0x4f35, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_MEM", _IOC_WRITE, 0x4f37, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_PLANE", _IOC_WRITE, 0x4f34, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SET_COLOR_KEY", _IOC_WRITE, 0x4f32, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_SET_TEARSYNC", _IOC_WRITE, 0x4f3e, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SET_UPDATE_MODE", _IOC_WRITE, 0x4f28, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_SYNC_GFX", _IOC_NONE, 0x4f25, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW", _IOC_WRITE, 0x4f36, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW_OLD", _IOC_WRITE, 0x4f2f, 0x14 },
+{ "linux/omapfb.h", "OMAPFB_VSYNC", _IOC_NONE, 0x4f26, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORGO", _IOC_NONE, 0x4f3c, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ID", _IOC_READ, 0x2407, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PAUSE_OUTPUT", _IOC_WRITE, 0x2409, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PERIOD", _IOC_WRITE, 0x2404, 0x08 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_REFRESH", _IOC_NONE, 0x2402, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_RESET", _IOC_NONE, 0x2403, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_BPF", _IOC_WRITE, 0x2408, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_FILTER", _IOC_WRITE, 0x2406, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_OUTPUT", _IOC_NONE, 0x2405, 0x00 },
+{ "linux/phantom.h", "PHN_GETREG", _IOC_READ|_IOC_WRITE, 0x7005, 0x08 },
+{ "linux/phantom.h", "PHN_GETREGS", _IOC_READ|_IOC_WRITE, 0x7007, 0x28 },
+{ "linux/phantom.h", "PHN_GET_REG", _IOC_READ|_IOC_WRITE, 0x7000, 0x04 },
+{ "linux/phantom.h", "PHN_GET_REGS", _IOC_READ|_IOC_WRITE, 0x7002, 0x04 },
+{ "linux/phantom.h", "PHN_NOT_OH", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/phantom.h", "PHN_SETREG", _IOC_WRITE, 0x7006, 0x08 },
+{ "linux/phantom.h", "PHN_SETREGS", _IOC_WRITE, 0x7008, 0x28 },
+{ "linux/phantom.h", "PHN_SET_REG", _IOC_WRITE, 0x7001, 0x04 },
+{ "linux/phantom.h", "PHN_SET_REGS", _IOC_WRITE, 0x7003, 0x04 },
+{ "linux/pktcdvd.h", "PACKET_CTRL_CMD", _IOC_READ|_IOC_WRITE, 0x5801, 0x18 },
+{ "linux/platform_data/media/si4713.h", "SI4713_IOC_MEASURE_RNL", _IOC_READ|_IOC_WRITE, 0x56c0, 0x1c },
+{ "linux/pmu.h", "PMU_IOC_CAN_SLEEP", _IOC_READ, 0x4205, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GET_BACKLIGHT", _IOC_READ, 0x4201, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GET_MODEL", _IOC_READ, 0x4203, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GRAB_BACKLIGHT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_HAS_ADB", _IOC_READ, 0x4204, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_SET_BACKLIGHT", _IOC_WRITE, 0x4202, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_SLEEP", _IOC_NONE, 0x4200, 0x00 },
+{ "linux/ppdev.h", "PPCLAIM", _IOC_NONE, 0x708b, 0x00 },
+{ "linux/ppdev.h", "PPCLRIRQ", _IOC_READ, 0x7093, 0x04 },
+{ "linux/ppdev.h", "PPDATADIR", _IOC_WRITE, 0x7090, 0x04 },
+{ "linux/ppdev.h", "PPEXCL", _IOC_NONE, 0x708f, 0x00 },
+{ "linux/ppdev.h", "PPFCONTROL", _IOC_WRITE, 0x708e, 0x02 },
+{ "linux/ppdev.h", "PPGETFLAGS", _IOC_READ, 0x709a, 0x04 },
+{ "linux/ppdev.h", "PPGETMODE", _IOC_READ, 0x7098, 0x04 },
+{ "linux/ppdev.h", "PPGETMODES", _IOC_READ, 0x7097, 0x04 },
+{ "linux/ppdev.h", "PPGETPHASE", _IOC_READ, 0x7099, 0x04 },
+{ "linux/ppdev.h", "PPGETTIME", _IOC_READ, 0x7095, 0x08 },
+{ "linux/ppdev.h", "PPNEGOT", _IOC_WRITE, 0x7091, 0x04 },
+{ "linux/ppdev.h", "PPRCONTROL", _IOC_READ, 0x7083, 0x01 },
+{ "linux/ppdev.h", "PPRDATA", _IOC_READ, 0x7085, 0x01 },
+{ "linux/ppdev.h", "PPRELEASE", _IOC_NONE, 0x708c, 0x00 },
+{ "linux/ppdev.h", "PPRSTATUS", _IOC_READ, 0x7081, 0x01 },
+{ "linux/ppdev.h", "PPSETFLAGS", _IOC_WRITE, 0x709b, 0x04 },
+{ "linux/ppdev.h", "PPSETMODE", _IOC_WRITE, 0x7080, 0x04 },
+{ "linux/ppdev.h", "PPSETPHASE", _IOC_WRITE, 0x7094, 0x04 },
+{ "linux/ppdev.h", "PPSETTIME", _IOC_WRITE, 0x7096, 0x08 },
+{ "linux/ppdev.h", "PPWCONTROL", _IOC_WRITE, 0x7084, 0x01 },
+{ "linux/ppdev.h", "PPWCTLONIRQ", _IOC_WRITE, 0x7092, 0x01 },
+{ "linux/ppdev.h", "PPWDATA", _IOC_WRITE, 0x7086, 0x01 },
+{ "linux/ppdev.h", "PPYIELD", _IOC_NONE, 0x708d, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTACH", _IOC_WRITE, 0x743d, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTCHAN", _IOC_WRITE, 0x7438, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCCONNECT", _IOC_WRITE, 0x743a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDETACH", _IOC_WRITE, 0x743c, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDISCONN", _IOC_NONE, 0x7439, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCGASYNCMAP", _IOC_READ, 0x7458, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGCHAN", _IOC_READ, 0x7437, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGDEBUG", _IOC_READ, 0x7441, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGFLAGS", _IOC_READ, 0x745a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGIDLE", _IOC_READ, 0x743f, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCGL2TPSTATS", _IOC_READ, 0x7436, 0x48 },
+{ "linux/ppp-ioctl.h", "PPPIOCGMRU", _IOC_READ, 0x7453, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGNPMODE", _IOC_READ|_IOC_WRITE, 0x744c, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCGRASYNCMAP", _IOC_READ, 0x7455, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGUNIT", _IOC_READ, 0x7456, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGXASYNCMAP", _IOC_READ, 0x7450, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCNEWUNIT", _IOC_READ|_IOC_WRITE, 0x743e, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSACTIVE", _IOC_WRITE, 0x7446, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSASYNCMAP", _IOC_WRITE, 0x7457, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSCOMPRESS", _IOC_WRITE, 0x744d, 0x0c },
+{ "linux/ppp-ioctl.h", "PPPIOCSDEBUG", _IOC_WRITE, 0x7440, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSFLAGS", _IOC_WRITE, 0x7459, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMAXCID", _IOC_WRITE, 0x7451, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRRU", _IOC_WRITE, 0x743b, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRU", _IOC_WRITE, 0x7452, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSNPMODE", _IOC_WRITE, 0x744b, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSPASS", _IOC_WRITE, 0x7447, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSRASYNCMAP", _IOC_WRITE, 0x7454, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSXASYNCMAP", _IOC_WRITE, 0x744f, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCXFERUNIT", _IOC_NONE, 0x744e, 0x00 },
+{ "linux/pps.h", "PPS_FETCH", _IOC_READ|_IOC_WRITE, 0x70a4, 0x04 },
+{ "linux/pps.h", "PPS_GETCAP", _IOC_READ, 0x70a3, 0x04 },
+{ "linux/pps.h", "PPS_GETPARAMS", _IOC_READ, 0x70a1, 0x04 },
+{ "linux/pps.h", "PPS_KC_BIND", _IOC_WRITE, 0x70a5, 0x04 },
+{ "linux/pps.h", "PPS_SETPARAMS", _IOC_WRITE, 0x70a2, 0x04 },
+{ "linux/pr.h", "IOC_PR_CLEAR", _IOC_WRITE, 0x70cd, 0x10 },
+{ "linux/pr.h", "IOC_PR_PREEMPT", _IOC_WRITE, 0x70cb, 0x18 },
+{ "linux/pr.h", "IOC_PR_PREEMPT_ABORT", _IOC_WRITE, 0x70cc, 0x18 },
+{ "linux/pr.h", "IOC_PR_REGISTER", _IOC_WRITE, 0x70c8, 0x18 },
+{ "linux/pr.h", "IOC_PR_RELEASE", _IOC_WRITE, 0x70ca, 0x10 },
+{ "linux/pr.h", "IOC_PR_RESERVE", _IOC_WRITE, 0x70c9, 0x10 },
+{ "linux/ptp_clock.h", "PTP_CLOCK_GETCAPS", _IOC_READ, 0x3d01, 0x50 },
+{ "linux/ptp_clock.h", "PTP_ENABLE_PPS", _IOC_WRITE, 0x3d04, 0x04 },
+{ "linux/ptp_clock.h", "PTP_EXTTS_REQUEST", _IOC_WRITE, 0x3d02, 0x10 },
+{ "linux/ptp_clock.h", "PTP_PEROUT_REQUEST", _IOC_WRITE, 0x3d03, 0x38 },
+{ "linux/ptp_clock.h", "PTP_PIN_GETFUNC", _IOC_READ|_IOC_WRITE, 0x3d06, 0x60 },
+{ "linux/ptp_clock.h", "PTP_PIN_SETFUNC", _IOC_WRITE, 0x3d07, 0x60 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET", _IOC_WRITE, 0x3d05, 0x340 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET_PRECISE", _IOC_READ|_IOC_WRITE, 0x3d08, 0x40 },
+{ "linux/radeonfb.h", "FBIO_RADEON_GET_MIRROR", _IOC_READ, 0x4003, 0x04 },
+{ "linux/radeonfb.h", "FBIO_RADEON_SET_MIRROR", _IOC_WRITE, 0x4004, 0x04 },
+{ "linux/raid/md_u.h", "ADD_NEW_DISK", _IOC_WRITE, 0x0921, 0x14 },
+{ "linux/raid/md_u.h", "CLEAR_ARRAY", _IOC_NONE, 0x0920, 0x00 },
+{ "linux/raid/md_u.h", "CLUSTERED_DISK_NACK", _IOC_NONE, 0x0935, 0x00 },
+{ "linux/raid/md_u.h", "GET_ARRAY_INFO", _IOC_READ, 0x0911, 0x48 },
+{ "linux/raid/md_u.h", "GET_BITMAP_FILE", _IOC_READ, 0x0915, 0x1000 },
+{ "linux/raid/md_u.h", "GET_DISK_INFO", _IOC_READ, 0x0912, 0x14 },
+{ "linux/raid/md_u.h", "HOT_ADD_DISK", _IOC_NONE, 0x0928, 0x00 },
+{ "linux/raid/md_u.h", "HOT_GENERATE_ERROR", _IOC_NONE, 0x092a, 0x00 },
+{ "linux/raid/md_u.h", "HOT_REMOVE_DISK", _IOC_NONE, 0x0922, 0x00 },
+{ "linux/raid/md_u.h", "PROTECT_ARRAY", _IOC_NONE, 0x0927, 0x00 },
+{ "linux/raid/md_u.h", "RAID_AUTORUN", _IOC_NONE, 0x0914, 0x00 },
+{ "linux/raid/md_u.h", "RAID_VERSION", _IOC_READ, 0x0910, 0x0c },
+{ "linux/raid/md_u.h", "RESTART_ARRAY_RW", _IOC_NONE, 0x0934, 0x00 },
+{ "linux/raid/md_u.h", "RUN_ARRAY", _IOC_WRITE, 0x0930, 0x0c },
+{ "linux/raid/md_u.h", "SET_ARRAY_INFO", _IOC_WRITE, 0x0923, 0x48 },
+{ "linux/raid/md_u.h", "SET_BITMAP_FILE", _IOC_WRITE, 0x092b, 0x04 },
+{ "linux/raid/md_u.h", "SET_DISK_FAULTY", _IOC_NONE, 0x0929, 0x00 },
+{ "linux/raid/md_u.h", "SET_DISK_INFO", _IOC_NONE, 0x0924, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY", _IOC_NONE, 0x0932, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY_RO", _IOC_NONE, 0x0933, 0x00 },
+{ "linux/raid/md_u.h", "UNPROTECT_ARRAY", _IOC_NONE, 0x0926, 0x00 },
+{ "linux/raid/md_u.h", "WRITE_RAID_INFO", _IOC_NONE, 0x0925, 0x00 },
+{ "linux/random.h", "RNDADDENTROPY", _IOC_WRITE, 0x5203, 0x08 },
+{ "linux/random.h", "RNDADDTOENTCNT", _IOC_WRITE, 0x5201, 0x04 },
+{ "linux/random.h", "RNDCLEARPOOL", _IOC_NONE, 0x5206, 0x00 },
+{ "linux/random.h", "RNDGETENTCNT", _IOC_READ, 0x5200, 0x04 },
+{ "linux/random.h", "RNDGETPOOL", _IOC_READ, 0x5202, 0x08 },
+{ "linux/random.h", "RNDZAPENTCNT", _IOC_NONE, 0x5204, 0x00 },
+{ "linux/raw.h", "RAW_GETBIND", _IOC_NONE, 0xac01, 0x00 },
+{ "linux/raw.h", "RAW_SETBIND", _IOC_NONE, 0xac00, 0x00 },
+{ "linux/reiserfs_fs.h", "REISERFS_IOC_UNPACK", _IOC_WRITE, 0xcd01, 0x04 },
+{ "linux/rfkill.h", "RFKILL_IOCTL_NOINPUT", _IOC_NONE, 0x5201, 0x00 },
+{ "linux/rio_mport_cdev.h", "RIO_ALLOC_DMA", _IOC_READ|_IOC_WRITE, 0x6d13, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_ADD", _IOC_WRITE, 0x6d17, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_DEL", _IOC_WRITE, 0x6d18, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d0a, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0c, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d09, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0b, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_FREE_DMA", _IOC_WRITE, 0x6d14, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_GET_EVENT_MASK", _IOC_READ, 0x6d0e, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_INBOUND", _IOC_READ|_IOC_WRITE, 0x6d11, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_OUTBOUND", _IOC_READ|_IOC_WRITE, 0x6d0f, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_GET_PROPERTIES", _IOC_READ, 0x6d04, 0x30 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_COMPTAG_SET", _IOC_WRITE, 0x6d02, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_HDID_SET", _IOC_WRITE, 0x6d01, 0x02 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_PORT_IDX_GET", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_LOCAL", _IOC_READ, 0x6d05, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_REMOTE", _IOC_READ, 0x6d07, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_LOCAL", _IOC_WRITE, 0x6d06, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_REMOTE", _IOC_WRITE, 0x6d08, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_SET_EVENT_MASK", _IOC_WRITE, 0x6d0d, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_TRANSFER", _IOC_READ|_IOC_WRITE, 0x6d15, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_INBOUND", _IOC_WRITE, 0x6d12, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_OUTBOUND", _IOC_WRITE, 0x6d10, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_WAIT_FOR_ASYNC", _IOC_WRITE, 0x6d16, 0x08 },
+{ "linux/rtc.h", "RTC_AIE_OFF", _IOC_NONE, 0x7002, 0x00 },
+{ "linux/rtc.h", "RTC_AIE_ON", _IOC_NONE, 0x7001, 0x00 },
+{ "linux/rtc.h", "RTC_ALM_READ", _IOC_READ, 0x7008, 0x24 },
+{ "linux/rtc.h", "RTC_ALM_SET", _IOC_WRITE, 0x7007, 0x24 },
+{ "linux/rtc.h", "RTC_EPOCH_READ", _IOC_READ, 0x700d, 0x04 },
+{ "linux/rtc.h", "RTC_EPOCH_SET", _IOC_WRITE, 0x700e, 0x04 },
+{ "linux/rtc.h", "RTC_IRQP_READ", _IOC_READ, 0x700b, 0x04 },
+{ "linux/rtc.h", "RTC_IRQP_SET", _IOC_WRITE, 0x700c, 0x04 },
+{ "linux/rtc.h", "RTC_PIE_OFF", _IOC_NONE, 0x7006, 0x00 },
+{ "linux/rtc.h", "RTC_PIE_ON", _IOC_NONE, 0x7005, 0x00 },
+{ "linux/rtc.h", "RTC_PLL_GET", _IOC_READ, 0x7011, 0x1c },
+{ "linux/rtc.h", "RTC_PLL_SET", _IOC_WRITE, 0x7012, 0x1c },
+{ "linux/rtc.h", "RTC_RD_TIME", _IOC_READ, 0x7009, 0x24 },
+{ "linux/rtc.h", "RTC_SET_TIME", _IOC_WRITE, 0x700a, 0x24 },
+{ "linux/rtc.h", "RTC_UIE_OFF", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/rtc.h", "RTC_UIE_ON", _IOC_NONE, 0x7003, 0x00 },
+{ "linux/rtc.h", "RTC_VL_CLR", _IOC_NONE, 0x7014, 0x00 },
+{ "linux/rtc.h", "RTC_VL_READ", _IOC_READ, 0x7013, 0x04 },
+{ "linux/rtc.h", "RTC_WIE_OFF", _IOC_NONE, 0x7010, 0x00 },
+{ "linux/rtc.h", "RTC_WIE_ON", _IOC_NONE, 0x700f, 0x00 },
+{ "linux/rtc.h", "RTC_WKALM_RD", _IOC_READ, 0x7010, 0x28 },
+{ "linux/rtc.h", "RTC_WKALM_SET", _IOC_WRITE, 0x700f, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREG", _IOC_READ|_IOC_WRITE, 0x7305, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREQ", _IOC_READ|_IOC_WRITE, 0x7304, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_BIND", _IOC_READ|_IOC_WRITE, 0x7301, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_CONNECT", _IOC_READ|_IOC_WRITE, 0x7303, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_MARK", _IOC_READ|_IOC_WRITE, 0x730f, 0x0c },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_SIGNAL", _IOC_READ|_IOC_WRITE, 0x7311, 0x24 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_WAIT", _IOC_READ|_IOC_WRITE, 0x7310, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_GET_NODEIDS", _IOC_READ|_IOC_WRITE, 0x730e, 0x14 },
+{ "linux/scif_ioctl.h", "SCIF_LISTEN", _IOC_WRITE, 0x7302, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_READFROM", _IOC_READ|_IOC_WRITE, 0x730a, 0x24 },
+{ "linux/scif_ioctl.h", "SCIF_RECV", _IOC_READ|_IOC_WRITE, 0x7307, 0x14 },
+{ "linux/scif_ioctl.h", "SCIF_REG", _IOC_READ|_IOC_WRITE, 0x7308, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_SEND", _IOC_READ|_IOC_WRITE, 0x7306, 0x14 },
+{ "linux/scif_ioctl.h", "SCIF_UNREG", _IOC_READ|_IOC_WRITE, 0x7309, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_VREADFROM", _IOC_READ|_IOC_WRITE, 0x730c, 0x24 },
+{ "linux/scif_ioctl.h", "SCIF_VWRITETO", _IOC_READ|_IOC_WRITE, 0x730d, 0x24 },
+{ "linux/scif_ioctl.h", "SCIF_WRITETO", _IOC_READ|_IOC_WRITE, 0x730b, 0x24 },
+{ "linux/serio.h", "SPIOCSTYPE", _IOC_WRITE, 0x7101, 0x04 },
+{ "linux/sockios.h", "SIOCADDDLCI", 0, 0x8980, 0 },
+{ "linux/sockios.h", "SIOCADDMULTI", 0, 0x8931, 0 },
+{ "linux/sockios.h", "SIOCADDRT", 0, 0x890B, 0 },
+{ "linux/sockios.h", "SIOCBONDCHANGEACTIVE", 0, 0x8995, 0 },
+{ "linux/sockios.h", "SIOCBONDENSLAVE", 0, 0x8990, 0 },
+{ "linux/sockios.h", "SIOCBONDINFOQUERY", 0, 0x8994, 0 },
+{ "linux/sockios.h", "SIOCBONDRELEASE", 0, 0x8991, 0 },
+{ "linux/sockios.h", "SIOCBONDSETHWADDR", 0, 0x8992, 0 },
+{ "linux/sockios.h", "SIOCBONDSLAVEINFOQUERY", 0, 0x8993, 0 },
+{ "linux/sockios.h", "SIOCBRADDBR", 0, 0x89a0, 0 },
+{ "linux/sockios.h", "SIOCBRADDIF", 0, 0x89a2, 0 },
+{ "linux/sockios.h", "SIOCBRDELBR", 0, 0x89a1, 0 },
+{ "linux/sockios.h", "SIOCBRDELIF", 0, 0x89a3, 0 },
+{ "linux/sockios.h", "SIOCDARP", 0, 0x8953, 0 },
+{ "linux/sockios.h", "SIOCDELDLCI", 0, 0x8981, 0 },
+{ "linux/sockios.h", "SIOCDELMULTI", 0, 0x8932, 0 },
+{ "linux/sockios.h", "SIOCDELRT", 0, 0x890C, 0 },
+{ "linux/sockios.h", "SIOCDEVPRIVATE", 0, 0x89F0, 0 },
+{ "linux/sockios.h", "SIOCDIFADDR", 0, 0x8936, 0 },
+{ "linux/sockios.h", "SIOCDRARP", 0, 0x8960, 0 },
+{ "linux/sockios.h", "SIOCETHTOOL", 0, 0x8946, 0 },
+{ "linux/sockios.h", "SIOCGARP", 0, 0x8954, 0 },
+{ "linux/sockios.h", "SIOCGHWTSTAMP", 0, 0x89b1, 0 },
+{ "linux/sockios.h", "SIOCGIFADDR", 0, 0x8915, 0 },
+{ "linux/sockios.h", "SIOCGIFBR", 0, 0x8940, 0 },
+{ "linux/sockios.h", "SIOCGIFBRDADDR", 0, 0x8919, 0 },
+{ "linux/sockios.h", "SIOCGIFCONF", 0, 0x8912, 0 },
+{ "linux/sockios.h", "SIOCGIFCOUNT", 0, 0x8938, 0 },
+{ "linux/sockios.h", "SIOCGIFDSTADDR", 0, 0x8917, 0 },
+{ "linux/sockios.h", "SIOCGIFENCAP", 0, 0x8925, 0 },
+{ "linux/sockios.h", "SIOCGIFFLAGS", 0, 0x8913, 0 },
+{ "linux/sockios.h", "SIOCGIFHWADDR", 0, 0x8927, 0 },
+{ "linux/sockios.h", "SIOCGIFINDEX", 0, 0x8933, 0 },
+{ "linux/sockios.h", "SIOCGIFMAP", 0, 0x8970, 0 },
+{ "linux/sockios.h", "SIOCGIFMEM", 0, 0x891f, 0 },
+{ "linux/sockios.h", "SIOCGIFMETRIC", 0, 0x891d, 0 },
+{ "linux/sockios.h", "SIOCGIFMTU", 0, 0x8921, 0 },
+{ "linux/sockios.h", "SIOCGIFNAME", 0, 0x8910, 0 },
+{ "linux/sockios.h", "SIOCGIFNETMASK", 0, 0x891b, 0 },
+{ "linux/sockios.h", "SIOCGIFPFLAGS", 0, 0x8935, 0 },
+{ "linux/sockios.h", "SIOCGIFSLAVE", 0, 0x8929, 0 },
+{ "linux/sockios.h", "SIOCGIFTXQLEN", 0, 0x8942, 0 },
+{ "linux/sockios.h", "SIOCGIFVLAN", 0, 0x8982, 0 },
+{ "linux/sockios.h", "SIOCGMIIPHY", 0, 0x8947, 0 },
+{ "linux/sockios.h", "SIOCGMIIREG", 0, 0x8948, 0 },
+{ "linux/sockios.h", "SIOCGRARP", 0, 0x8961, 0 },
+{ "linux/sockios.h", "SIOCOUTQNSD", 0, 0x894B, 0 },
+{ "linux/sockios.h", "SIOCPROTOPRIVATE", 0, 0x89E0, 0 },
+{ "linux/sockios.h", "SIOCRTMSG", 0, 0x890D, 0 },
+{ "linux/sockios.h", "SIOCSARP", 0, 0x8955, 0 },
+{ "linux/sockios.h", "SIOCSHWTSTAMP", 0, 0x89b0, 0 },
+{ "linux/sockios.h", "SIOCSIFADDR", 0, 0x8916, 0 },
+{ "linux/sockios.h", "SIOCSIFBR", 0, 0x8941, 0 },
+{ "linux/sockios.h", "SIOCSIFBRDADDR", 0, 0x891a, 0 },
+{ "linux/sockios.h", "SIOCSIFDSTADDR", 0, 0x8918, 0 },
+{ "linux/sockios.h", "SIOCSIFENCAP", 0, 0x8926, 0 },
+{ "linux/sockios.h", "SIOCSIFFLAGS", 0, 0x8914, 0 },
+{ "linux/sockios.h", "SIOCSIFHWADDR", 0, 0x8924, 0 },
+{ "linux/sockios.h", "SIOCSIFHWBROADCAST", 0, 0x8937, 0 },
+{ "linux/sockios.h", "SIOCSIFLINK", 0, 0x8911, 0 },
+{ "linux/sockios.h", "SIOCSIFMAP", 0, 0x8971, 0 },
+{ "linux/sockios.h", "SIOCSIFMEM", 0, 0x8920, 0 },
+{ "linux/sockios.h", "SIOCSIFMETRIC", 0, 0x891e, 0 },
+{ "linux/sockios.h", "SIOCSIFMTU", 0, 0x8922, 0 },
+{ "linux/sockios.h", "SIOCSIFNAME", 0, 0x8923, 0 },
+{ "linux/sockios.h", "SIOCSIFNETMASK", 0, 0x891c, 0 },
+{ "linux/sockios.h", "SIOCSIFPFLAGS", 0, 0x8934, 0 },
+{ "linux/sockios.h", "SIOCSIFSLAVE", 0, 0x8930, 0 },
+{ "linux/sockios.h", "SIOCSIFTXQLEN", 0, 0x8943, 0 },
+{ "linux/sockios.h", "SIOCSIFVLAN", 0, 0x8983, 0 },
+{ "linux/sockios.h", "SIOCSMIIREG", 0, 0x8949, 0 },
+{ "linux/sockios.h", "SIOCSRARP", 0, 0x8962, 0 },
+{ "linux/sockios.h", "SIOCWANDEV", 0, 0x894A, 0 },
+{ "linux/sonet.h", "SONET_CLRDIAG", _IOC_READ|_IOC_WRITE, 0x6113, 0x04 },
+{ "linux/sonet.h", "SONET_GETDIAG", _IOC_READ, 0x6114, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRAMING", _IOC_READ, 0x6116, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRSENSE", _IOC_READ, 0x6117, 0x06 },
+{ "linux/sonet.h", "SONET_GETSTAT", _IOC_READ, 0x6110, 0x24 },
+{ "linux/sonet.h", "SONET_GETSTATZ", _IOC_READ, 0x6111, 0x24 },
+{ "linux/sonet.h", "SONET_SETDIAG", _IOC_READ|_IOC_WRITE, 0x6112, 0x04 },
+{ "linux/sonet.h", "SONET_SETFRAMING", _IOC_WRITE, 0x6115, 0x04 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1CAP", _IOC_READ, 0x7602, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1REM", _IOC_READ, 0x7603, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2CAP", _IOC_READ, 0x7604, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2REM", _IOC_READ, 0x7605, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBATFLAGS", _IOC_READ, 0x7607, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBLUE", _IOC_READ, 0x7608, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBRT", _IOC_READ, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGFAN", _IOC_READ, 0x760a, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGTEMP", _IOC_READ, 0x760c, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBLUE", _IOC_WRITE, 0x7609, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBRT", _IOC_WRITE, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSFAN", _IOC_WRITE, 0x760b, 0x01 },
+{ "linux/soundcard.h", "OSS_GETVERSION", _IOC_READ, 0x4d76, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_COPR_HALT", _IOC_READ|_IOC_WRITE, 0x4307, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_LOAD", _IOC_READ|_IOC_WRITE, 0x4301, 0xfb0 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCODE", _IOC_READ|_IOC_WRITE, 0x4303, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCVMSG", _IOC_READ, 0x4309, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RDATA", _IOC_READ|_IOC_WRITE, 0x4302, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RESET", _IOC_NONE, 0x4300, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RUN", _IOC_READ|_IOC_WRITE, 0x4306, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_SENDMSG", _IOC_READ|_IOC_WRITE, 0x4308, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WCODE", _IOC_WRITE, 0x4305, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WDATA", _IOC_WRITE, 0x4304, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_DSP_BIND_CHANNEL", _IOC_READ|_IOC_WRITE, 0x5041, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_CHANNELS", _IOC_READ|_IOC_WRITE, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETBLKSIZE", _IOC_READ|_IOC_WRITE, 0x5004, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCAPS", _IOC_READ, 0x500f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCHANNELMASK", _IOC_READ|_IOC_WRITE, 0x5040, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETFMTS", _IOC_READ, 0x500b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETIPTR", _IOC_READ, 0x5011, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETISPACE", _IOC_READ, 0x500d, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETODELAY", _IOC_READ, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOPTR", _IOC_READ, 0x5012, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOSPACE", _IOC_READ, 0x500c, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETSPDIF", _IOC_READ, 0x5043, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETTRIGGER", _IOC_READ, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPINBUF", _IOC_READ, 0x5013, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPOUTBUF", _IOC_READ, 0x5014, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_DSP_NONBLOCK", _IOC_NONE, 0x500e, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_POST", _IOC_NONE, 0x5008, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_PROFILE", _IOC_WRITE, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_RESET", _IOC_NONE, 0x5000, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETDUPLEX", _IOC_NONE, 0x5016, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFMT", _IOC_READ|_IOC_WRITE, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFRAGMENT", _IOC_READ|_IOC_WRITE, 0x500a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSPDIF", _IOC_WRITE, 0x5042, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSYNCRO", _IOC_NONE, 0x5015, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETTRIGGER", _IOC_WRITE, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SPEED", _IOC_READ|_IOC_WRITE, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_STEREO", _IOC_READ|_IOC_WRITE, 0x5003, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SUBDIVIDE", _IOC_READ|_IOC_WRITE, 0x5009, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SYNC", _IOC_NONE, 0x5001, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_FM_4OP_ENABLE", _IOC_WRITE, 0x510f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_FM_LOAD_INSTR", _IOC_WRITE, 0x5107, 0x28 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_INFO", _IOC_READ|_IOC_WRITE, 0x510c, 0x74 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUCMD", _IOC_READ|_IOC_WRITE, 0x6d02, 0x21 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUMODE", _IOC_READ|_IOC_WRITE, 0x6d01, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_PRETIME", _IOC_READ|_IOC_WRITE, 0x6d00, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_CTRLRATE", _IOC_READ|_IOC_WRITE, 0x5103, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETINCOUNT", _IOC_READ, 0x5105, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETOUTCOUNT", _IOC_READ, 0x5104, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETTIME", _IOC_READ, 0x5113, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRMIDIS", _IOC_READ, 0x510b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRSYNTHS", _IOC_READ, 0x510a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_OUTOFBAND", _IOC_WRITE, 0x5112, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PANIC", _IOC_NONE, 0x5111, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PERCMODE", _IOC_WRITE, 0x5106, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESET", _IOC_NONE, 0x5100, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESETSAMPLES", _IOC_WRITE, 0x5109, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_SYNC", _IOC_NONE, 0x5101, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_TESTMIDI", _IOC_WRITE, 0x5108, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_THRESHOLD", _IOC_WRITE, 0x510d, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_CONTROL", _IOC_READ|_IOC_WRITE, 0x5115, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_ID", _IOC_READ|_IOC_WRITE, 0x5114, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_INFO", _IOC_READ|_IOC_WRITE, 0x5102, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_MEMAVL", _IOC_READ|_IOC_WRITE, 0x510e, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_REMOVESAMPLE", _IOC_READ|_IOC_WRITE, 0x5116, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_TMR_CONTINUE", _IOC_NONE, 0x5404, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_METRONOME", _IOC_WRITE, 0x5407, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SELECT", _IOC_WRITE, 0x5408, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SOURCE", _IOC_READ|_IOC_WRITE, 0x5406, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_START", _IOC_NONE, 0x5402, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_STOP", _IOC_NONE, 0x5403, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TEMPO", _IOC_READ|_IOC_WRITE, 0x5405, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TIMEBASE", _IOC_READ|_IOC_WRITE, 0x5401, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_3DSE", _IOC_READ|_IOC_WRITE, 0x4d68, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_ACCESS", _IOC_READ|_IOC_WRITE, 0x4d66, 0x80 },
+{ "linux/soundcard.h", "SOUND_MIXER_AGC", _IOC_READ|_IOC_WRITE, 0x4d67, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_GETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d74, 0xa4 },
+{ "linux/soundcard.h", "SOUND_MIXER_INFO", _IOC_READ, 0x4d65, 0x5c },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE1", _IOC_READ|_IOC_WRITE, 0x4d6f, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE2", _IOC_READ|_IOC_WRITE, 0x4d70, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE3", _IOC_READ|_IOC_WRITE, 0x4d71, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE4", _IOC_READ|_IOC_WRITE, 0x4d72, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE5", _IOC_READ|_IOC_WRITE, 0x4d73, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_SETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d75, 0xa4 },
+{ "linux/soundcard.h", "SOUND_OLD_MIXER_INFO", _IOC_READ, 0x4d65, 0x30 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_BITS", _IOC_READ, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_CHANNELS", _IOC_READ, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_FILTER", _IOC_READ, 0x5007, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_RATE", _IOC_READ, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_WRITE_FILTER", _IOC_READ|_IOC_WRITE, 0x5007, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_BITS_PER_WORD", _IOC_READ, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_LSB_FIRST", _IOC_READ, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MAX_SPEED_HZ", _IOC_READ, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE", _IOC_READ, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE32", _IOC_READ, 0x6b05, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_BITS_PER_WORD", _IOC_WRITE, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_LSB_FIRST", _IOC_WRITE, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MAX_SPEED_HZ", _IOC_WRITE, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE", _IOC_WRITE, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE32", _IOC_WRITE, 0x6b05, 0x04 },
+{ "linux/stm.h", "STP_POLICY_ID_GET", _IOC_READ, 0x2501, 0x10 },
+{ "linux/stm.h", "STP_POLICY_ID_SET", _IOC_READ|_IOC_WRITE, 0x2500, 0x10 },
+{ "linux/stm.h", "STP_SET_OPTIONS", _IOC_WRITE, 0x2502, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ALLOC_SWAP_PAGE", _IOC_READ, 0x3314, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ATOMIC_RESTORE", _IOC_NONE, 0x3304, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_AVAIL_SWAP_SIZE", _IOC_READ, 0x3313, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_CREATE_IMAGE", _IOC_WRITE, 0x3311, 0x04 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE", _IOC_NONE, 0x3305, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREEZE", _IOC_NONE, 0x3301, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE_SWAP_PAGES", _IOC_NONE, 0x3309, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_GET_IMAGE_SIZE", _IOC_READ, 0x330e, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PLATFORM_SUPPORT", _IOC_NONE, 0x330f, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_POWER_OFF", _IOC_NONE, 0x3310, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PREF_IMAGE_SIZE", _IOC_NONE, 0x3312, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_S2RAM", _IOC_NONE, 0x330b, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_SET_SWAP_AREA", _IOC_WRITE, 0x330d, 0x0c },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_UNFREEZE", _IOC_NONE, 0x3302, 0x00 },
+{ "linux/sync_file.h", "SYNC_IOC_FILE_INFO", _IOC_READ|_IOC_WRITE, 0x3e04, 0x38 },
+{ "linux/sync_file.h", "SYNC_IOC_MERGE", _IOC_READ|_IOC_WRITE, 0x3e03, 0x30 },
+{ "linux/synclink.h", "MGSL_IOCCLRMODCOUNT", _IOC_NONE, 0x6d0f, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGGPIO", _IOC_READ, 0x6d11, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCGIF", _IOC_NONE, 0x6d0b, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGPARAMS", _IOC_READ, 0x6d01, 0x20 },
+{ "linux/synclink.h", "MGSL_IOCGSTATS", _IOC_NONE, 0x6d07, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGTXIDLE", _IOC_NONE, 0x6d03, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXCTRL", _IOC_NONE, 0x6d16, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXSYNC", _IOC_NONE, 0x6d14, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCLOOPTXDONE", _IOC_NONE, 0x6d09, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCRXENABLE", _IOC_NONE, 0x6d05, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSGPIO", _IOC_WRITE, 0x6d10, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCSIF", _IOC_NONE, 0x6d0a, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSPARAMS", _IOC_WRITE, 0x6d00, 0x20 },
+{ "linux/synclink.h", "MGSL_IOCSTXIDLE", _IOC_NONE, 0x6d02, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXCTRL", _IOC_NONE, 0x6d15, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXSYNC", _IOC_NONE, 0x6d13, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXABORT", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXENABLE", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCWAITEVENT", _IOC_READ|_IOC_WRITE, 0x6d08, 0x04 },
+{ "linux/synclink.h", "MGSL_IOCWAITGPIO", _IOC_READ|_IOC_WRITE, 0x6d12, 0x10 },
+{ "linux/telephony.h", "OLD_PHONE_RING_START", _IOC_NONE, 0x7187, 0x00 },
+{ "linux/telephony.h", "PHONE_BUSY", _IOC_NONE, 0x71a1, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES", _IOC_NONE, 0x7180, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_CHECK", _IOC_WRITE, 0x7182, 0x04 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_LIST", _IOC_READ, 0x7181, 0x04 },
+{ "linux/telephony.h", "PHONE_CPT_STOP", _IOC_NONE, 0x71a4, 0x00 },
+{ "linux/telephony.h", "PHONE_DIALTONE", _IOC_NONE, 0x71a3, 0x00 },
+{ "linux/telephony.h", "PHONE_DTMF_OOB", _IOC_WRITE, 0x7199, 0x04 },
+{ "linux/telephony.h", "PHONE_DTMF_READY", _IOC_READ, 0x7196, 0x04 },
+{ "linux/telephony.h", "PHONE_EXCEPTION", _IOC_READ, 0x719a, 0x04 },
+{ "linux/telephony.h", "PHONE_FRAME", _IOC_WRITE, 0x718d, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF", _IOC_READ, 0x7197, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF_ASCII", _IOC_READ, 0x7198, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_TONE_OFF_TIME", _IOC_NONE, 0x719f, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_ON_TIME", _IOC_NONE, 0x719e, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_STATE", _IOC_NONE, 0x71a0, 0x00 },
+{ "linux/telephony.h", "PHONE_HOOKSTATE", _IOC_NONE, 0x7184, 0x00 },
+{ "linux/telephony.h", "PHONE_MAXRINGS", _IOC_WRITE, 0x7185, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_CODEC", _IOC_WRITE, 0x7190, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_DEPTH", _IOC_WRITE, 0x7193, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_LEVEL", _IOC_NONE, 0x7195, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_START", _IOC_NONE, 0x7191, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_STOP", _IOC_NONE, 0x7192, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_TONE", _IOC_WRITE, 0x719b, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME", _IOC_WRITE, 0x7194, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME_LINEAR", _IOC_WRITE, 0x71dc, 0x04 },
+{ "linux/telephony.h", "PHONE_PSTN_GET_STATE", _IOC_NONE, 0x71a5, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_LINETEST", _IOC_NONE, 0x71a8, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_SET_STATE", _IOC_WRITE, 0x71a4, 0x04 },
+{ "linux/telephony.h", "PHONE_QUERY_CODEC", _IOC_READ|_IOC_WRITE, 0x71a7, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_CODEC", _IOC_WRITE, 0x7189, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_DEPTH", _IOC_WRITE, 0x718c, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_LEVEL", _IOC_NONE, 0x718f, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_START", _IOC_NONE, 0x718a, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_STOP", _IOC_NONE, 0x718b, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME", _IOC_WRITE, 0x718e, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME_LINEAR", _IOC_WRITE, 0x71db, 0x04 },
+{ "linux/telephony.h", "PHONE_RING", _IOC_NONE, 0x7183, 0x00 },
+{ "linux/telephony.h", "PHONE_RINGBACK", _IOC_NONE, 0x71a2, 0x00 },
+{ "linux/telephony.h", "PHONE_RING_CADENCE", _IOC_WRITE, 0x7186, 0x02 },
+{ "linux/telephony.h", "PHONE_RING_START", _IOC_WRITE, 0x7187, 0x04 },
+{ "linux/telephony.h", "PHONE_RING_STOP", _IOC_NONE, 0x7188, 0x00 },
+{ "linux/telephony.h", "PHONE_SET_TONE_OFF_TIME", _IOC_WRITE, 0x719d, 0x04 },
+{ "linux/telephony.h", "PHONE_SET_TONE_ON_TIME", _IOC_WRITE, 0x719c, 0x04 },
+{ "linux/telephony.h", "PHONE_VAD", _IOC_WRITE, 0x71a9, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK", _IOC_WRITE, 0x71aa, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK_DURATION", _IOC_WRITE, 0x71a6, 0x04 },
+{ "linux/timerfd.h", "TFD_IOC_SET_TICKS", _IOC_WRITE, 0x5400, 0x08 },
+{ "linux/toshiba.h", "TOSHIBA_ACPI_SCI", _IOC_READ|_IOC_WRITE, 0x7491, 0x18 },
+{ "linux/toshiba.h", "TOSH_SMM", _IOC_READ|_IOC_WRITE, 0x7490, 0x18 },
+{ "linux/udf_fs_i.h", "UDF_GETEABLOCK", _IOC_READ, 0x6c41, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETEASIZE", _IOC_READ, 0x6c40, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETVOLIDENT", _IOC_READ, 0x6c42, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_RELOCATE_BLOCKS", _IOC_READ|_IOC_WRITE, 0x6c43, 0x04 },
+{ "linux/uinput.h", "UI_ABS_SETUP", _IOC_WRITE, 0x5504, 0x1c },
+{ "linux/uinput.h", "UI_BEGIN_FF_ERASE", _IOC_READ|_IOC_WRITE, 0x55ca, 0x0c },
+{ "linux/uinput.h", "UI_BEGIN_FF_UPLOAD", _IOC_READ|_IOC_WRITE, 0x55c8, 0x60 },
+{ "linux/uinput.h", "UI_DEV_CREATE", _IOC_NONE, 0x5501, 0x00 },
+{ "linux/uinput.h", "UI_DEV_DESTROY", _IOC_NONE, 0x5502, 0x00 },
+{ "linux/uinput.h", "UI_DEV_SETUP", _IOC_WRITE, 0x5503, 0x5c },
+{ "linux/uinput.h", "UI_END_FF_ERASE", _IOC_WRITE, 0x55cb, 0x0c },
+{ "linux/uinput.h", "UI_END_FF_UPLOAD", _IOC_WRITE, 0x55c9, 0x60 },
+{ "linux/uinput.h", "UI_GET_VERSION", _IOC_READ, 0x552d, 0x04 },
+{ "linux/uinput.h", "UI_SET_ABSBIT", _IOC_WRITE, 0x5567, 0x04 },
+{ "linux/uinput.h", "UI_SET_EVBIT", _IOC_WRITE, 0x5564, 0x04 },
+{ "linux/uinput.h", "UI_SET_FFBIT", _IOC_WRITE, 0x556b, 0x04 },
+{ "linux/uinput.h", "UI_SET_KEYBIT", _IOC_WRITE, 0x5565, 0x04 },
+{ "linux/uinput.h", "UI_SET_LEDBIT", _IOC_WRITE, 0x5569, 0x04 },
+{ "linux/uinput.h", "UI_SET_MSCBIT", _IOC_WRITE, 0x5568, 0x04 },
+{ "linux/uinput.h", "UI_SET_PHYS", _IOC_WRITE, 0x556c, 0x04 },
+{ "linux/uinput.h", "UI_SET_PROPBIT", _IOC_WRITE, 0x556e, 0x04 },
+{ "linux/uinput.h", "UI_SET_RELBIT", _IOC_WRITE, 0x5566, 0x04 },
+{ "linux/uinput.h", "UI_SET_SNDBIT", _IOC_WRITE, 0x556a, 0x04 },
+{ "linux/uinput.h", "UI_SET_SWBIT", _IOC_WRITE, 0x556d, 0x04 },
+{ "linux/usb/cdc-wdm.h", "IOCTL_WDM_MAX_COMMAND", _IOC_READ, 0x48a0, 0x02 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_DESC", _IOC_READ, 0x6782, 0x09 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_REVMAP", _IOC_NONE, 0x6781, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
+{ "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/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 },
+{ "linux/usb/iowarrior.h", "IOW_GETINFO", _IOC_READ, 0xc003, 0x28 },
+{ "linux/usb/iowarrior.h", "IOW_READ", _IOC_WRITE, 0xc002, 0x04 },
+{ "linux/usb/iowarrior.h", "IOW_WRITE", _IOC_WRITE, 0xc001, 0x04 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GET_CAPS", _IOC_READ, 0x5b11, 0x01 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GOTO_LOCAL", _IOC_NONE, 0x5b14, 0x00 },
+{ "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", "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_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
+{ "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 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIMINTERFACE", _IOC_READ, 0x550f, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIM_PORT", _IOC_READ, 0x5518, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLEAR_HALT", _IOC_READ, 0x5515, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECT", _IOC_NONE, 0x5517, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECTINFO", _IOC_WRITE, 0x5511, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL32", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCARDURB", _IOC_NONE, 0x550b, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT", _IOC_NONE, 0x5516, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT_CLAIM", _IOC_READ, 0x551b, 0x108 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL32", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DROP_PRIVILEGES", _IOC_WRITE, 0x551e, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_FREE_STREAMS", _IOC_READ, 0x551d, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GETDRIVER", _IOC_WRITE, 0x5508, 0x104 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GET_CAPABILITIES", _IOC_READ, 0x551a, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_HUB_PORTINFO", _IOC_READ, 0x5513, 0x80 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL32", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB32", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY32", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASEINTERFACE", _IOC_READ, 0x5510, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASE_PORT", _IOC_READ, 0x5519, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESET", _IOC_NONE, 0x5514, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESETEP", _IOC_READ, 0x5503, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETCONFIGURATION", _IOC_READ, 0x5505, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETINTERFACE", _IOC_READ, 0x5504, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB", _IOC_READ, 0x550a, 0x2c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB32", _IOC_READ, 0x550a, 0x2a },
+{ "linux/userfaultfd.h", "UFFDIO_API", _IOC_READ|_IOC_WRITE, 0xaa3f, 0x18 },
+{ "linux/userfaultfd.h", "UFFDIO_COPY", _IOC_READ|_IOC_WRITE, 0xaa03, 0x28 },
+{ "linux/userfaultfd.h", "UFFDIO_REGISTER", _IOC_READ|_IOC_WRITE, 0xaa00, 0x20 },
+{ "linux/userfaultfd.h", "UFFDIO_UNREGISTER", _IOC_READ, 0xaa01, 0x10 },
+{ "linux/userfaultfd.h", "UFFDIO_WAKE", _IOC_READ, 0xaa02, 0x10 },
+{ "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 },
+{ "linux/vfio.h", "VFIO_CHECK_EXTENSION", _IOC_NONE, 0x3b65, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_INFO", _IOC_NONE, 0x3b6b, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_IRQ_INFO", _IOC_NONE, 0x3b6d, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_REGION_INFO", _IOC_NONE, 0x3b6c, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_PCI_HOT_RESET", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_RESET", _IOC_NONE, 0x3b6f, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_SET_IRQS", _IOC_NONE, 0x3b6e, 0x00 },
+{ "linux/vfio.h", "VFIO_EEH_PE_OP", _IOC_NONE, 0x3b79, 0x00 },
+{ "linux/vfio.h", "VFIO_GET_API_VERSION", _IOC_NONE, 0x3b64, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_DEVICE_FD", _IOC_NONE, 0x3b6a, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_STATUS", _IOC_NONE, 0x3b67, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_SET_CONTAINER", _IOC_NONE, 0x3b68, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_UNSET_CONTAINER", _IOC_NONE, 0x3b69, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_DISABLE", _IOC_NONE, 0x3b74, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_ENABLE", _IOC_NONE, 0x3b73, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_MAP_DMA", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", _IOC_NONE, 0x3b75, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_CREATE", _IOC_NONE, 0x3b77, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_REMOVE", _IOC_NONE, 0x3b78, 0x00 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_GET_VRING_ENDIAN", _IOC_WRITE, 0xaf14, 0x08 },
+{ "linux/vhost.h", "VHOST_NET_SET_BACKEND", _IOC_WRITE, 0xaf30, 0x08 },
+{ "linux/vhost.h", "VHOST_RESET_OWNER", _IOC_NONE, 0xaf02, 0x00 },
+{ "linux/vhost.h", "VHOST_SCSI_CLEAR_ENDPOINT", _IOC_WRITE, 0xaf41, 0xe8 },
+{ "linux/vhost.h", "VHOST_SCSI_GET_ABI_VERSION", _IOC_WRITE, 0xaf42, 0x04 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_SET_MEM_TABLE", _IOC_WRITE, 0xaf03, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_OWNER", _IOC_NONE, 0xaf01, 0x00 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ADDR", _IOC_WRITE, 0xaf11, 0x28 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BASE", _IOC_WRITE, 0xaf12, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf23, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_CALL", _IOC_WRITE, 0xaf21, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ENDIAN", _IOC_WRITE, 0xaf13, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ERR", _IOC_WRITE, 0xaf22, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_KICK", _IOC_WRITE, 0xaf20, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_NUM", _IOC_WRITE, 0xaf10, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_CREATE_BUFS", _IOC_READ|_IOC_WRITE, 0x565c, 0xf8 },
+{ "linux/videodev2.h", "VIDIOC_CROPCAP", _IOC_READ|_IOC_WRITE, 0x563a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_CHIP_INFO", _IOC_READ|_IOC_WRITE, 0x5666, 0xc8 },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_REGISTER", _IOC_READ|_IOC_WRITE, 0x5650, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DBG_S_REGISTER", _IOC_WRITE, 0x564f, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5660, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_DQBUF", _IOC_READ|_IOC_WRITE, 0x5611, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_DQEVENT", _IOC_READ, 0x5659, 0x78 },
+{ "linux/videodev2.h", "VIDIOC_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
+{ "linux/videodev2.h", "VIDIOC_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564d, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDIO", _IOC_READ|_IOC_WRITE, 0x5641, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDOUT", _IOC_READ|_IOC_WRITE, 0x5642, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMINPUT", _IOC_READ|_IOC_WRITE, 0x561a, 0x4c },
+{ "linux/videodev2.h", "VIDIOC_ENUMOUTPUT", _IOC_READ|_IOC_WRITE, 0x5630, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUMSTD", _IOC_READ|_IOC_WRITE, 0x5619, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FMT", _IOC_READ|_IOC_WRITE, 0x5602, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMEINTERVALS", _IOC_READ|_IOC_WRITE, 0x564b, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMESIZES", _IOC_READ|_IOC_WRITE, 0x564a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FREQ_BANDS", _IOC_READ|_IOC_WRITE, 0x5665, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_EXPBUF", _IOC_READ|_IOC_WRITE, 0x5610, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDIO", _IOC_READ, 0x5621, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDOUT", _IOC_READ, 0x5631, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_G_CTRL", _IOC_READ|_IOC_WRITE, 0x561b, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
+{ "linux/videodev2.h", "VIDIOC_G_ENC_INDEX", _IOC_READ, 0x564c, 0x818 },
+{ "linux/videodev2.h", "VIDIOC_G_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5647, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_G_FBUF", _IOC_READ, 0x560a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_FREQUENCY", _IOC_READ|_IOC_WRITE, 0x5638, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_INPUT", _IOC_READ, 0x5626, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_JPEGCOMP", _IOC_READ, 0x563d, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_G_MODULATOR", _IOC_READ|_IOC_WRITE, 0x5636, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_G_OUTPUT", _IOC_READ, 0x562e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_PARM", _IOC_READ|_IOC_WRITE, 0x5615, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_PRIORITY", _IOC_READ, 0x5643, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x565e, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_SLICED_VBI_CAP", _IOC_READ|_IOC_WRITE, 0x5645, 0x74 },
+{ "linux/videodev2.h", "VIDIOC_G_STD", _IOC_READ, 0x5617, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_TUNER", _IOC_READ|_IOC_WRITE, 0x561d, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_LOG_STATUS", _IOC_NONE, 0x5646, 0x00 },
+{ "linux/videodev2.h", "VIDIOC_OVERLAY", _IOC_WRITE, 0x560e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_PREPARE_BUF", _IOC_READ|_IOC_WRITE, 0x565d, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QBUF", _IOC_READ|_IOC_WRITE, 0x560f, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYBUF", _IOC_READ|_IOC_WRITE, 0x5609, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCAP", _IOC_READ, 0x5600, 0x68 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCTRL", _IOC_READ|_IOC_WRITE, 0x5624, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYMENU", _IOC_READ|_IOC_WRITE, 0x5625, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_QUERYSTD", _IOC_READ, 0x563f, 0x08 },
+{ "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 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDIO", _IOC_WRITE, 0x5622, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDOUT", _IOC_WRITE, 0x5632, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_CROP", _IOC_WRITE, 0x563c, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_S_CTRL", _IOC_READ|_IOC_WRITE, 0x561c, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
+{ "linux/videodev2.h", "VIDIOC_S_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5648, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_S_FBUF", _IOC_WRITE, 0x560b, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_FREQUENCY", _IOC_WRITE, 0x5639, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_HW_FREQ_SEEK", _IOC_WRITE, 0x5652, 0x30 },
+{ "linux/videodev2.h", "VIDIOC_S_INPUT", _IOC_READ|_IOC_WRITE, 0x5627, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_JPEGCOMP", _IOC_WRITE, 0x563e, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_S_MODULATOR", _IOC_WRITE, 0x5637, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_S_OUTPUT", _IOC_READ|_IOC_WRITE, 0x562f, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_PARM", _IOC_READ|_IOC_WRITE, 0x5616, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_PRIORITY", _IOC_WRITE, 0x5644, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x565f, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_S_STD", _IOC_WRITE, 0x5618, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_TUNER", _IOC_WRITE, 0x561e, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_TRY_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5661, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_TRY_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564e, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_TRY_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5649, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_TRY_FMT", _IOC_READ|_IOC_WRITE, 0x5640, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_UNSUBSCRIBE_EVENT", _IOC_WRITE, 0x565b, 0x20 },
+{ "linux/vm_sockets.h", "IOCTL_VM_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_ADD_NOTIFICATION", _IOC_NONE, 0x07af, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_GET_CPT_STATE", _IOC_NONE, 0x07b1, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", _IOC_NONE, 0x07b0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_SET_CPT_STATE", _IOC_NONE, 0x07b2, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_RECEIVE", _IOC_NONE, 0x07ac, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_SEND", _IOC_NONE, 0x07ab, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_GET_CONTEXT_ID", _IOC_NONE, 0x07b3, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_INIT_CONTEXT", _IOC_NONE, 0x07a0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", _IOC_NONE, 0x07a6, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFY_RESOURCE", _IOC_NONE, 0x07a5, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_ALLOC", _IOC_NONE, 0x07a8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_DETACH", _IOC_NONE, 0x07aa, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", _IOC_NONE, 0x07a9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETVA", _IOC_NONE, 0x07a4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SET_NOTIFY", _IOC_NONE, 0x07cb, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", _IOC_NONE, 0x07b8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_VERSION", _IOC_NONE, 0x07b4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION", _IOC_NONE, 0x079f, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION2", _IOC_NONE, 0x07a7, 0x00 },
+{ "linux/vsp1.h", "VIDIOC_VSP1_LUT_CONFIG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x400 },
+{ "linux/vt.h", "VT_ACTIVATE", 0, 0x5606, 0 },
+{ "linux/vt.h", "VT_DISALLOCATE", 0, 0x5608, 0 },
+{ "linux/vt.h", "VT_GETHIFONTMASK", 0, 0x560D, 0 },
+{ "linux/vt.h", "VT_GETMODE", 0, 0x5601, 0 },
+{ "linux/vt.h", "VT_GETSTATE", 0, 0x5603, 0 },
+{ "linux/vt.h", "VT_LOCKSWITCH", 0, 0x560B, 0 },
+{ "linux/vt.h", "VT_OPENQRY", 0, 0x5600, 0 },
+{ "linux/vt.h", "VT_RELDISP", 0, 0x5605, 0 },
+{ "linux/vt.h", "VT_RESIZE", 0, 0x5609, 0 },
+{ "linux/vt.h", "VT_RESIZEX", 0, 0x560A, 0 },
+{ "linux/vt.h", "VT_SENDSIG", 0, 0x5604, 0 },
+{ "linux/vt.h", "VT_SETACTIVATE", 0, 0x560F, 0 },
+{ "linux/vt.h", "VT_SETMODE", 0, 0x5602, 0 },
+{ "linux/vt.h", "VT_UNLOCKSWITCH", 0, 0x560C, 0 },
+{ "linux/vt.h", "VT_WAITACTIVE", 0, 0x5607, 0 },
+{ "linux/vt.h", "VT_WAITEVENT", 0, 0x560E, 0 },
+{ "linux/watchdog.h", "WDIOC_GETBOOTSTATUS", _IOC_READ, 0x5702, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETPRETIMEOUT", _IOC_READ, 0x5709, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSTATUS", _IOC_READ, 0x5701, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSUPPORT", _IOC_READ, 0x5700, 0x28 },
+{ "linux/watchdog.h", "WDIOC_GETTEMP", _IOC_READ, 0x5703, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMELEFT", _IOC_READ, 0x570a, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMEOUT", _IOC_READ, 0x5707, 0x04 },
+{ "linux/watchdog.h", "WDIOC_KEEPALIVE", _IOC_READ, 0x5705, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETOPTIONS", _IOC_READ, 0x5704, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETPRETIMEOUT", _IOC_READ|_IOC_WRITE, 0x5708, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x5706, 0x04 },
+{ "linux/wireless.h", "SIOCGIWAP", 0, 0x8B15, 0 },
+{ "linux/wireless.h", "SIOCGIWAPLIST", 0, 0x8B17, 0 },
+{ "linux/wireless.h", "SIOCGIWAUTH", 0, 0x8B33, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODE", 0, 0x8B2B, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODEEXT", 0, 0x8B35, 0 },
+{ "linux/wireless.h", "SIOCGIWESSID", 0, 0x8B1B, 0 },
+{ "linux/wireless.h", "SIOCGIWFRAG", 0, 0x8B25, 0 },
+{ "linux/wireless.h", "SIOCGIWFREQ", 0, 0x8B05, 0 },
+{ "linux/wireless.h", "SIOCGIWGENIE", 0, 0x8B31, 0 },
+{ "linux/wireless.h", "SIOCGIWMODE", 0, 0x8B07, 0 },
+{ "linux/wireless.h", "SIOCGIWNAME", 0, 0x8B01, 0 },
+{ "linux/wireless.h", "SIOCGIWNICKN", 0, 0x8B1D, 0 },
+{ "linux/wireless.h", "SIOCGIWNWID", 0, 0x8B03, 0 },
+{ "linux/wireless.h", "SIOCGIWPOWER", 0, 0x8B2D, 0 },
+{ "linux/wireless.h", "SIOCGIWPRIV", 0, 0x8B0D, 0 },
+{ "linux/wireless.h", "SIOCGIWRANGE", 0, 0x8B0B, 0 },
+{ "linux/wireless.h", "SIOCGIWRATE", 0, 0x8B21, 0 },
+{ "linux/wireless.h", "SIOCGIWRETRY", 0, 0x8B29, 0 },
+{ "linux/wireless.h", "SIOCGIWRTS", 0, 0x8B23, 0 },
+{ "linux/wireless.h", "SIOCGIWSCAN", 0, 0x8B19, 0 },
+{ "linux/wireless.h", "SIOCGIWSENS", 0, 0x8B09, 0 },
+{ "linux/wireless.h", "SIOCGIWSPY", 0, 0x8B11, 0 },
+{ "linux/wireless.h", "SIOCGIWSTATS", 0, 0x8B0F, 0 },
+{ "linux/wireless.h", "SIOCGIWTHRSPY", 0, 0x8B13, 0 },
+{ "linux/wireless.h", "SIOCGIWTXPOW", 0, 0x8B27, 0 },
+{ "linux/wireless.h", "SIOCIWFIRST", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCIWFIRSTPRIV", 0, 0x8BE0, 0 },
+{ "linux/wireless.h", "SIOCIWLASTPRIV", 0, 0x8BFF, 0 },
+{ "linux/wireless.h", "SIOCSIWAP", 0, 0x8B14, 0 },
+{ "linux/wireless.h", "SIOCSIWAUTH", 0, 0x8B32, 0 },
+{ "linux/wireless.h", "SIOCSIWCOMMIT", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODE", 0, 0x8B2A, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODEEXT", 0, 0x8B34, 0 },
+{ "linux/wireless.h", "SIOCSIWESSID", 0, 0x8B1A, 0 },
+{ "linux/wireless.h", "SIOCSIWFRAG", 0, 0x8B24, 0 },
+{ "linux/wireless.h", "SIOCSIWFREQ", 0, 0x8B04, 0 },
+{ "linux/wireless.h", "SIOCSIWGENIE", 0, 0x8B30, 0 },
+{ "linux/wireless.h", "SIOCSIWMLME", 0, 0x8B16, 0 },
+{ "linux/wireless.h", "SIOCSIWMODE", 0, 0x8B06, 0 },
+{ "linux/wireless.h", "SIOCSIWNICKN", 0, 0x8B1C, 0 },
+{ "linux/wireless.h", "SIOCSIWNWID", 0, 0x8B02, 0 },
+{ "linux/wireless.h", "SIOCSIWPMKSA", 0, 0x8B36, 0 },
+{ "linux/wireless.h", "SIOCSIWPOWER", 0, 0x8B2C, 0 },
+{ "linux/wireless.h", "SIOCSIWPRIV", 0, 0x8B0C, 0 },
+{ "linux/wireless.h", "SIOCSIWRANGE", 0, 0x8B0A, 0 },
+{ "linux/wireless.h", "SIOCSIWRATE", 0, 0x8B20, 0 },
+{ "linux/wireless.h", "SIOCSIWRETRY", 0, 0x8B28, 0 },
+{ "linux/wireless.h", "SIOCSIWRTS", 0, 0x8B22, 0 },
+{ "linux/wireless.h", "SIOCSIWSCAN", 0, 0x8B18, 0 },
+{ "linux/wireless.h", "SIOCSIWSENS", 0, 0x8B08, 0 },
+{ "linux/wireless.h", "SIOCSIWSPY", 0, 0x8B10, 0 },
+{ "linux/wireless.h", "SIOCSIWSTATS", 0, 0x8B0E, 0 },
+{ "linux/wireless.h", "SIOCSIWTHRSPY", 0, 0x8B12, 0 },
+{ "linux/wireless.h", "SIOCSIWTXPOW", 0, 0x8B26, 0 },
+{ "media/davinci/vpfe_capture.h", "VPFE_CMD_S_CCDC_RAW_PARAMS", _IOC_WRITE, 0x56c1, 0x04 },
+{ "media/drv-intf/exynos-fimc.h", "S5P_FIMC_TX_END_NOTIFY", _IOC_NONE, 0x6500, 0x00 },
+{ "media/i2c/adv7842.h", "ADV7842_CMD_RAM_TEST", _IOC_NONE, 0x56c0, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_HIGH", _IOC_NONE, 0x6201, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_LOW", _IOC_NONE, 0x6200, 0x00 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_CLOSE", _IOC_WRITE, 0x5202, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_POLL", _IOC_READ, 0x5204, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_READ", _IOC_READ, 0x5203, 0x04 },
+{ "media/v4l2-common.h", "TUNER_SET_CONFIG", _IOC_WRITE, 0x645c, 0x08 },
+{ "media/v4l2-common.h", "VIDIOC_INT_RESET", _IOC_WRITE, 0x6466, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_DEVICE_NOTIFY_EVENT", _IOC_WRITE, 0x7602, 0x78 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_RX_NOTIFY", _IOC_WRITE, 0x7600, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_TX_NOTIFY", _IOC_WRITE, 0x7601, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_DOWNLOAD_IMAGE", _IOC_WRITE, 0xca0a, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_AFU_ID", _IOC_READ, 0xca02, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_PROCESS_ELEMENT", _IOC_READ, 0xca01, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_START_WORK", _IOC_WRITE, 0xca00, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_VALIDATE_IMAGE", _IOC_WRITE, 0xca0b, 0x40 },
+{ "mtd/mtd-abi.h", "ECCGETLAYOUT", _IOC_READ, 0x4d11, 0x148 },
+{ "mtd/mtd-abi.h", "ECCGETSTATS", _IOC_READ, 0x4d12, 0x10 },
+{ "mtd/mtd-abi.h", "MEMERASE", _IOC_WRITE, 0x4d02, 0x08 },
+{ "mtd/mtd-abi.h", "MEMERASE64", _IOC_WRITE, 0x4d14, 0x10 },
+{ "mtd/mtd-abi.h", "MEMGETBADBLOCK", _IOC_WRITE, 0x4d0b, 0x08 },
+{ "mtd/mtd-abi.h", "MEMGETINFO", _IOC_READ, 0x4d01, 0x20 },
+{ "mtd/mtd-abi.h", "MEMGETOOBSEL", _IOC_READ, 0x4d0a, 0xc8 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONCOUNT", _IOC_READ, 0x4d07, 0x04 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONINFO", _IOC_READ|_IOC_WRITE, 0x4d08, 0x10 },
+{ "mtd/mtd-abi.h", "MEMISLOCKED", _IOC_READ, 0x4d17, 0x08 },
+{ "mtd/mtd-abi.h", "MEMLOCK", _IOC_WRITE, 0x4d05, 0x08 },
+{ "mtd/mtd-abi.h", "MEMREADOOB", _IOC_READ|_IOC_WRITE, 0x4d04, 0x0c },
+{ "mtd/mtd-abi.h", "MEMREADOOB64", _IOC_READ|_IOC_WRITE, 0x4d16, 0x18 },
+{ "mtd/mtd-abi.h", "MEMSETBADBLOCK", _IOC_WRITE, 0x4d0c, 0x08 },
+{ "mtd/mtd-abi.h", "MEMUNLOCK", _IOC_WRITE, 0x4d06, 0x08 },
+{ "mtd/mtd-abi.h", "MEMWRITE", _IOC_READ|_IOC_WRITE, 0x4d18, 0x30 },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB", _IOC_READ|_IOC_WRITE, 0x4d03, 0x0c },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB64", _IOC_READ|_IOC_WRITE, 0x4d15, 0x18 },
+{ "mtd/mtd-abi.h", "MTDFILEMODE", _IOC_NONE, 0x4d13, 0x00 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONCOUNT", _IOC_WRITE, 0x4d0e, 0x04 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONINFO", _IOC_WRITE, 0x4d0f, 0x0c },
+{ "mtd/mtd-abi.h", "OTPLOCK", _IOC_READ, 0x4d10, 0x0c },
+{ "mtd/mtd-abi.h", "OTPSELECT", _IOC_READ, 0x4d0d, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCATT", _IOC_WRITE, 0x6f40, 0x18 },
+{ "mtd/ubi-user.h", "UBI_IOCDET", _IOC_WRITE, 0x6f41, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBCH", _IOC_WRITE, 0x4f02, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBER", _IOC_WRITE, 0x4f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBISMAP", _IOC_READ, 0x4f05, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBMAP", _IOC_WRITE, 0x4f03, 0x08 },
+{ "mtd/ubi-user.h", "UBI_IOCEBUNMAP", _IOC_WRITE, 0x4f04, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCMKVOL", _IOC_WRITE, 0x6f00, 0x98 },
+{ "mtd/ubi-user.h", "UBI_IOCRMVOL", _IOC_WRITE, 0x6f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCRNVOL", _IOC_WRITE, 0x6f03, 0x1110 },
+{ "mtd/ubi-user.h", "UBI_IOCRSVOL", _IOC_WRITE, 0x6f02, 0x0c },
+{ "mtd/ubi-user.h", "UBI_IOCSETVOLPROP", _IOC_WRITE, 0x4f06, 0x10 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLCRBLK", _IOC_WRITE, 0x4f07, 0x80 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLRMBLK", _IOC_NONE, 0x4f08, 0x00 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLUP", _IOC_WRITE, 0x4f00, 0x08 },
+{ "net/bluetooth/hci_sock.h", "HCIBLOCKADDR", _IOC_WRITE, 0x48e6, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVDOWN", _IOC_WRITE, 0x48ca, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESET", _IOC_WRITE, 0x48cb, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESTAT", _IOC_WRITE, 0x48cc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVUP", _IOC_WRITE, 0x48c9, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETAUTHINFO", _IOC_READ, 0x48d7, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNINFO", _IOC_READ, 0x48d5, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNLIST", _IOC_READ, 0x48d4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVINFO", _IOC_READ, 0x48d3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVLIST", _IOC_READ, 0x48d2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIINQUIRY", _IOC_READ, 0x48f0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETACLMTU", _IOC_WRITE, 0x48e3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETAUTH", _IOC_WRITE, 0x48de, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETENCRYPT", _IOC_WRITE, 0x48df, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKMODE", _IOC_WRITE, 0x48e2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKPOL", _IOC_WRITE, 0x48e1, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETPTYPE", _IOC_WRITE, 0x48e0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETRAW", _IOC_WRITE, 0x48dc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCAN", _IOC_WRITE, 0x48dd, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCOMTU", _IOC_WRITE, 0x48e4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIUNBLOCKADDR", _IOC_WRITE, 0x48e7, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMCREATEDEV", _IOC_WRITE, 0x52c8, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVINFO", _IOC_READ, 0x52d3, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVLIST", _IOC_READ, 0x52d2, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMRELEASEDEV", _IOC_WRITE, 0x52c9, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMSTEALDLC", _IOC_WRITE, 0x52dc, 0x04 },
+{ "net/nfc/nci_core.h", "NCIUARTSETDRIVER", _IOC_WRITE, 0x5500, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ACK_EVENT", _IOC_WRITE, 0x1bea, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ASSIGN_CTXT", _IOC_READ|_IOC_WRITE, 0x1be1, 0x1c },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CREDIT_UPD", _IOC_NONE, 0x1be6, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_INFO", _IOC_WRITE, 0x1be2, 0x28 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_RESET", _IOC_NONE, 0x1bec, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_GET_VERS", _IOC_READ, 0x1bee, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_POLL_TYPE", _IOC_WRITE, 0x1be9, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_RECV_CTRL", _IOC_WRITE, 0x1be8, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_SET_PKEY", _IOC_WRITE, 0x1beb, 0x02 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_FREE", _IOC_READ|_IOC_WRITE, 0x1be5, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_INVAL_READ", _IOC_READ|_IOC_WRITE, 0x1bed, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_UPDATE", _IOC_READ|_IOC_WRITE, 0x1be4, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_USER_INFO", _IOC_WRITE, 0x1be3, 0x78 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_ENABLE_PKEY", _IOC_NONE, 0x1b03, 0x00 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT", _IOC_READ|_IOC_WRITE, 0x1b01, 0x1c },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT2", _IOC_READ|_IOC_WRITE, 0x1b04, 0x28 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_UNREGISTER_AGENT", _IOC_WRITE, 0x1b02, 0x04 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_ATTACH", _IOC_READ|_IOC_WRITE, 0xca80, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_DETACH", _IOC_READ|_IOC_WRITE, 0xca83, 0x60 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_MANAGE_LUN", _IOC_READ|_IOC_WRITE, 0xca86, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RECOVER_AFU", _IOC_READ|_IOC_WRITE, 0xca85, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RELEASE", _IOC_READ|_IOC_WRITE, 0xca82, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_DIRECT", _IOC_READ|_IOC_WRITE, 0xca81, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_VIRTUAL", _IOC_READ|_IOC_WRITE, 0xca87, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VERIFY", _IOC_READ|_IOC_WRITE, 0xca84, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_CLONE", _IOC_READ|_IOC_WRITE, 0xca89, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_RESIZE", _IOC_READ|_IOC_WRITE, 0xca88, 0x78 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_BUS_NUMBER", 0, 0x5386, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_IDLUN", 0, 0x5382, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_PCI", 0, 0x5387, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_PROBE_HOST", 0, 0x5385, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORLOCK", 0, 0x5380, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORUNLOCK", 0, 0x5381, 0 },
+{ "scsi/sg.h", "SG_EMULATED_HOST", 0, 0x2203, 0 },
+{ "scsi/sg.h", "SG_GET_ACCESS_COUNT", 0, 0x2289, 0 },
+{ "scsi/sg.h", "SG_GET_COMMAND_Q", 0, 0x2270, 0 },
+{ "scsi/sg.h", "SG_GET_KEEP_ORPHAN", 0, 0x2288, 0 },
+{ "scsi/sg.h", "SG_GET_LOW_DMA", 0, 0x227a, 0 },
+{ "scsi/sg.h", "SG_GET_NUM_WAITING", 0, 0x227d, 0 },
+{ "scsi/sg.h", "SG_GET_PACK_ID", 0, 0x227c, 0 },
+{ "scsi/sg.h", "SG_GET_REQUEST_TABLE", 0, 0x2286, 0 },
+{ "scsi/sg.h", "SG_GET_RESERVED_SIZE", 0, 0x2272, 0 },
+{ "scsi/sg.h", "SG_GET_SCSI_ID", 0, 0x2276, 0 },
+{ "scsi/sg.h", "SG_GET_SG_TABLESIZE", 0, 0x227F, 0 },
+{ "scsi/sg.h", "SG_GET_TIMEOUT", 0, 0x2202, 0 },
+{ "scsi/sg.h", "SG_GET_TRANSFORM", 0, 0x2205, 0 },
+{ "scsi/sg.h", "SG_GET_VERSION_NUM", 0, 0x2282, 0 },
+{ "scsi/sg.h", "SG_IO", 0, 0x2285, 0 },
+{ "scsi/sg.h", "SG_NEXT_CMD_LEN", 0, 0x2283, 0 },
+{ "scsi/sg.h", "SG_SCSI_RESET", 0, 0x2284, 0 },
+{ "scsi/sg.h", "SG_SET_COMMAND_Q", 0, 0x2271, 0 },
+{ "scsi/sg.h", "SG_SET_DEBUG", 0, 0x227e, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_LOW_DMA", 0, 0x2279, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_PACK_ID", 0, 0x227b, 0 },
+{ "scsi/sg.h", "SG_SET_KEEP_ORPHAN", 0, 0x2287, 0 },
+{ "scsi/sg.h", "SG_SET_RESERVED_SIZE", 0, 0x2275, 0 },
+{ "scsi/sg.h", "SG_SET_TIMEOUT", 0, 0x2201, 0 },
+{ "scsi/sg.h", "SG_SET_TRANSFORM", 0, 0x2204, 0 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CLIENT_ID", _IOC_READ, 0x5301, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_PORT", _IOC_READ|_IOC_WRITE, 0x5320, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x5332, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_PORT", _IOC_WRITE, 0x5321, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_QUEUE", _IOC_WRITE, 0x5333, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", _IOC_READ|_IOC_WRITE, 0x5310, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", _IOC_READ|_IOC_WRITE, 0x534b, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", _IOC_READ|_IOC_WRITE, 0x5336, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_PORT_INFO", _IOC_READ|_IOC_WRITE, 0x5322, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", _IOC_READ|_IOC_WRITE, 0x5349, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5334, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", _IOC_READ|_IOC_WRITE, 0x5340, 0x5c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", _IOC_READ|_IOC_WRITE, 0x5341, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", _IOC_READ|_IOC_WRITE, 0x5345, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", _IOC_READ|_IOC_WRITE, 0x5350, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_PVERSION", _IOC_READ, 0x5300, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", _IOC_READ|_IOC_WRITE, 0x5351, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", _IOC_READ|_IOC_WRITE, 0x5352, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_SUBS", _IOC_READ|_IOC_WRITE, 0x534f, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", _IOC_WRITE, 0x534e, 0x40 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_RUNNING_MODE", _IOC_READ|_IOC_WRITE, 0x5303, 0x10 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", _IOC_WRITE, 0x5311, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", _IOC_WRITE, 0x534c, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_PORT_INFO", _IOC_WRITE, 0x5323, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", _IOC_WRITE, 0x534a, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5335, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", _IOC_WRITE, 0x5342, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", _IOC_WRITE, 0x5346, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", _IOC_WRITE, 0x5330, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SYSTEM_INFO", _IOC_READ|_IOC_WRITE, 0x5302, 0x30 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", _IOC_WRITE, 0x5331, 0x50 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_CARD_INFO", _IOC_READ, 0x5501, 0x178 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_ADD", _IOC_READ|_IOC_WRITE, 0x5517, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_INFO", _IOC_READ|_IOC_WRITE, 0x5511, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LIST", _IOC_READ|_IOC_WRITE, 0x5510, 0x48 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LOCK", _IOC_WRITE, 0x5514, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_READ", _IOC_READ|_IOC_WRITE, 0x5512, 0x2c4 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REMOVE", _IOC_READ|_IOC_WRITE, 0x5519, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REPLACE", _IOC_READ|_IOC_WRITE, 0x5518, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_UNLOCK", _IOC_WRITE, 0x5515, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_WRITE", _IOC_READ|_IOC_WRITE, 0x5513, 0x2c4 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_INFO", _IOC_READ, 0x5521, 0xdc },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5520, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_INFO", _IOC_READ|_IOC_WRITE, 0x5531, 0x120 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", _IOC_READ, 0x5530, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", _IOC_WRITE, 0x5532, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER", _IOC_READ|_IOC_WRITE, 0x55d0, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER_STATE", _IOC_READ, 0x55d1, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PVERSION", _IOC_READ, 0x5500, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_INFO", _IOC_READ|_IOC_WRITE, 0x5541, 0x10c },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5540, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", _IOC_WRITE, 0x5542, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", _IOC_READ|_IOC_WRITE, 0x5516, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_COMMAND", _IOC_READ|_IOC_WRITE, 0x551c, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_READ", _IOC_READ|_IOC_WRITE, 0x551a, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_WRITE", _IOC_READ|_IOC_WRITE, 0x551b, 0x08 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_LOAD", _IOC_WRITE, 0x4803, 0x50 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_STATUS", _IOC_READ, 0x4802, 0x40 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_INFO", _IOC_READ, 0x4801, 0xdc },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_PVERSION", _IOC_READ, 0x4800, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_CHANNEL_INFO", _IOC_READ, 0x4132, 0x10 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DELAY", _IOC_READ, 0x4121, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DRAIN", _IOC_NONE, 0x4144, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DROP", _IOC_NONE, 0x4143, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_FORWARD", _IOC_WRITE, 0x4149, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HWSYNC", _IOC_NONE, 0x4122, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_FREE", _IOC_NONE, 0x4112, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4111, 0x25c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_REFINE", _IOC_READ|_IOC_WRITE, 0x4110, 0x25c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_INFO", _IOC_READ, 0x4101, 0x120 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_LINK", _IOC_WRITE, 0x4160, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PAUSE", _IOC_WRITE, 0x4145, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PREPARE", _IOC_NONE, 0x4140, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PVERSION", _IOC_READ, 0x4100, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READI_FRAMES", _IOC_READ, 0x4151, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READN_FRAMES", _IOC_READ, 0x4153, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESET", _IOC_NONE, 0x4141, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESUME", _IOC_NONE, 0x4147, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_REWIND", _IOC_WRITE, 0x4146, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_START", _IOC_NONE, 0x4142, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS", _IOC_READ, 0x4120, 0x6c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS_EXT", _IOC_READ|_IOC_WRITE, 0x4124, 0x6c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4113, 0x68 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SYNC_PTR", _IOC_READ|_IOC_WRITE, 0x4123, 0x84 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TSTAMP", _IOC_WRITE, 0x4102, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TTSTAMP", _IOC_WRITE, 0x4103, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_UNLINK", _IOC_NONE, 0x4161, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEI_FRAMES", _IOC_WRITE, 0x4150, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEN_FRAMES", _IOC_WRITE, 0x4152, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_XRUN", _IOC_NONE, 0x4148, 0x00 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DRAIN", _IOC_WRITE, 0x5731, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DROP", _IOC_WRITE, 0x5730, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_INFO", _IOC_READ, 0x5701, 0x10c },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PARAMS", _IOC_READ|_IOC_WRITE, 0x5710, 0x20 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PVERSION", _IOC_READ, 0x5700, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_STATUS", _IOC_READ|_IOC_WRITE, 0x5720, 0x24 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_CONTINUE", _IOC_NONE, 0x54a2, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GINFO", _IOC_READ|_IOC_WRITE, 0x5403, 0xe0 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GPARAMS", _IOC_WRITE, 0x5404, 0x3c },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GSTATUS", _IOC_READ|_IOC_WRITE, 0x5405, 0x40 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_INFO", _IOC_READ, 0x5411, 0xe0 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5401, 0x14 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PARAMS", _IOC_WRITE, 0x5412, 0x50 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PAUSE", _IOC_NONE, 0x54a3, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PVERSION", _IOC_READ, 0x5400, 0x04 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_SELECT", _IOC_WRITE, 0x5410, 0x34 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_START", _IOC_NONE, 0x54a0, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STATUS", _IOC_READ, 0x5414, 0x58 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STOP", _IOC_NONE, 0x54a1, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_TREAD", _IOC_WRITE, 0x5402, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", _IOC_NONE, 0x4840, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_INFO", _IOC_READ, 0x4820, 0x02 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_PLAY_NOTE", _IOC_WRITE, 0x4822, 0x0c },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_RESET", _IOC_NONE, 0x4821, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_CONNECTION", _IOC_WRITE, 0x4826, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_MODE", _IOC_WRITE, 0x4825, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4824, 0x09 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_VOICE", _IOC_WRITE, 0x4823, 0x12 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_AVAIL", _IOC_READ, 0x4321, 0x1c },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_DRAIN", _IOC_NONE, 0x4334, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x4310, 0xc4 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CODEC_CAPS", _IOC_READ|_IOC_WRITE, 0x4311, 0x2b88 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_METADATA", _IOC_READ|_IOC_WRITE, 0x4315, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_PARAMS", _IOC_READ, 0x4313, 0x78 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_IOCTL_VERSION", _IOC_READ, 0x4300, 0x04 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_NEXT_TRACK", _IOC_NONE, 0x4335, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PARTIAL_DRAIN", _IOC_NONE, 0x4336, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PAUSE", _IOC_NONE, 0x4330, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_RESUME", _IOC_NONE, 0x4331, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_METADATA", _IOC_WRITE, 0x4314, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_PARAMS", _IOC_WRITE, 0x4312, 0x84 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_START", _IOC_NONE, 0x4332, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_STOP", _IOC_NONE, 0x4333, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_TSTAMP", _IOC_READ, 0x4320, 0x14 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_PEEK", _IOC_READ|_IOC_WRITE, 0x4812, 0x18c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_POKE", _IOC_WRITE, 0x4811, 0x18c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CONTINUE", _IOC_NONE, 0x4881, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_DBG_READ", _IOC_READ, 0x4884, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_INFO", _IOC_READ, 0x4810, 0x80c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_PEEK", _IOC_READ|_IOC_WRITE, 0x4831, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_POKE", _IOC_WRITE, 0x4830, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PVERSION", _IOC_READ, 0x4840, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", _IOC_WRITE, 0x4883, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_STOP", _IOC_NONE, 0x4880, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", _IOC_READ|_IOC_WRITE, 0x4822, 0x0c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_POKE", _IOC_WRITE, 0x4821, 0x0c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", _IOC_WRITE, 0x4820, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_GET_INFO", _IOC_READ, 0x48f8, 0x20 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_LOCK", _IOC_NONE, 0x48f9, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_UNLOCK", _IOC_NONE, 0x48fa, 0x00 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_GET_WCAP", _IOC_READ|_IOC_WRITE, 0x4812, 0x08 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_PVERSION", _IOC_READ, 0x4810, 0x04 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_VERB_WRITE", _IOC_READ|_IOC_WRITE, 0x4811, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_9632_AEB", _IOC_READ, 0x4845, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", _IOC_READ, 0x4841, 0x24 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x1000 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4840, 0x3b0 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_VERSION", _IOC_READ, 0x4843, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", _IOC_WRITE, 0x4842, 0x04 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_CONFIG", _IOC_READ, 0x4841, 0x18 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_LTC", _IOC_READ, 0x4846, 0x10 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x04 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4842, 0x908 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_STATUS", _IOC_READ, 0x4847, 0x1c },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_VERSION", _IOC_READ, 0x4848, 0x24 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_INFO", _IOC_READ, 0x4810, 0x28 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_LOAD_CODE", _IOC_WRITE, 0x4811, 0x3012 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_PAUSE", _IOC_NONE, 0x4815, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_RESTART", _IOC_NONE, 0x4816, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_START", _IOC_WRITE, 0x4813, 0x08 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_STOP", _IOC_NONE, 0x4814, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", _IOC_NONE, 0x4812, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_LOAD_PATCH", _IOC_READ|_IOC_WRITE, 0x4881, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MEM_AVAIL", _IOC_WRITE, 0x4884, 0x04 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MISC_MODE", _IOC_READ|_IOC_WRITE, 0x4884, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", _IOC_NONE, 0x4883, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_RESET_SAMPLES", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_VERSION", _IOC_READ, 0x4880, 0x04 },
+{ "sound/usb_stream.h", "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4890, 0x10 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_NAME", _IOC_READ, 0x7702, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PIN_STATUS", _IOC_NONE, 0x7709, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PROT_MASK", _IOC_NONE, 0x7706, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_SIZE", _IOC_NONE, 0x7704, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_PIN", _IOC_WRITE, 0x7707, 0x08 },
+{ "staging/android/ashmem.h", "ASHMEM_PURGE_ALL_CACHES", _IOC_NONE, 0x770a, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_NAME", _IOC_WRITE, 0x7701, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_PROT_MASK", _IOC_WRITE, 0x7705, 0x04 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_SIZE", _IOC_WRITE, 0x7703, 0x04 },
+{ "staging/android/ashmem.h", "ASHMEM_UNPIN", _IOC_WRITE, 0x7708, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_ALLOC", _IOC_READ|_IOC_WRITE, 0x4900, 0x14 },
+{ "staging/android/ion.h", "ION_IOC_CUSTOM", _IOC_READ|_IOC_WRITE, 0x4906, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_FREE", _IOC_READ|_IOC_WRITE, 0x4901, 0x04 },
+{ "staging/android/ion.h", "ION_IOC_IMPORT", _IOC_READ|_IOC_WRITE, 0x4905, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_MAP", _IOC_READ|_IOC_WRITE, 0x4902, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SHARE", _IOC_READ|_IOC_WRITE, 0x4904, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SYNC", _IOC_READ|_IOC_WRITE, 0x4907, 0x08 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_DMA_MAPPING", _IOC_WRITE, 0x49f1, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_KERNEL_MAPPING", _IOC_WRITE, 0x49f2, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_SET_FD", _IOC_NONE, 0x49f0, 0x00 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_CREATE_FENCE", _IOC_READ|_IOC_WRITE, 0x5700, 0x28 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_INC", _IOC_WRITE, 0x5701, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_BRIGHTNESS", _IOC_READ, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_COLOR", _IOC_READ, 0x4605, 0x04 },
+{ "video/da8xx-fb.h", "FBIOGET_CONTRAST", _IOC_READ, 0x4601, 0x04 },
+{ "video/da8xx-fb.h", "FBIOPUT_CONTRAST", _IOC_WRITE, 0x4602, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_BRIGHTNESS", _IOC_WRITE, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_COLOR", _IOC_WRITE, 0x4606, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_HSYNC", _IOC_WRITE, 0x4609, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_VSYNC", _IOC_WRITE, 0x460a, 0x04 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_CREATE", _IOC_NONE, 0x6b00, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_OFFSET", _IOC_NONE, 0x6b04, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", _IOC_NONE, 0x6b01, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_SET_VIDEO_MODE", _IOC_NONE, 0x6b02, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_STRIDE", _IOC_NONE, 0x6b05, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_UVSTRIDE", _IOC_NONE, 0x6b03, 0x00 },
+{ "video/mbxfb.h", "MBXFB_IOCG_ALPHA", _IOC_READ, 0xf401, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_ALPHA", _IOC_WRITE, 0xf402, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_PLANEORDER", _IOC_READ, 0xf403, 0x02 },
+{ "video/mbxfb.h", "MBXFB_IOCS_REG", _IOC_WRITE, 0xf404, 0x0c },
+{ "video/mbxfb.h", "MBXFB_IOCX_OVERLAY", _IOC_READ|_IOC_WRITE, 0xf400, 0x30 },
+{ "video/mbxfb.h", "MBXFB_IOCX_REG", _IOC_READ|_IOC_WRITE, 0xf405, 0x0c },
+{ "video/sisfb.h", "SISFB_COMMAND", _IOC_READ|_IOC_WRITE, 0xf305, 0x54 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE", _IOC_READ, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE_OLD", _IOC_READ, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO", _IOC_READ, 0xf301, 0x11c },
+{ "video/sisfb.h", "SISFB_GET_INFO_OLD", _IOC_READ, 0x6ef8, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO_SIZE", _IOC_READ, 0xf300, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_TVPOSOFFSET", _IOC_READ, 0xf304, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS", _IOC_READ, 0xf302, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS_OLD", _IOC_READ, 0x6ef9, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE", _IOC_WRITE, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE_OLD", _IOC_WRITE, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_LOCK", _IOC_WRITE, 0xf306, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_TVPOSOFFSET", _IOC_WRITE, 0xf304, 0x04 },
+{ "video/sstfb.h", "SSTFB_GET_VGAPASS", _IOC_READ, 0x46dd, 0x04 },
+{ "video/sstfb.h", "SSTFB_SET_VGAPASS", _IOC_WRITE, 0x46dd, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_INTERDOMAIN", _IOC_NONE, 0x4501, 0x08 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_UNBOUND_PORT", _IOC_NONE, 0x4502, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_VIRQ", _IOC_NONE, 0x4500, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_NOTIFY", _IOC_NONE, 0x4504, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
+{ "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 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_MAX_GRANTS", _IOC_NONE, 0x4703, 0x04 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", _IOC_NONE, 0x4707, 0x10 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_UNMAP_GRANT_REF", _IOC_NONE, 0x4701, 0x10 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_EVTCHN", _IOC_NONE, 0x4200, 0x00 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_SETUP", _IOC_NONE, 0x4201, 0x00 },
diff --git a/strace/linux/32/ioctls_inc_align64.h b/strace/linux/32/ioctls_inc_align64.h
new file mode 100644
index 0000000..173cc67
--- /dev/null
+++ b/strace/linux/32/ioctls_inc_align64.h
@@ -0,0 +1,2824 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/include/ tree. */
+{ "acpi/apei.h", "APEI_ERST_CLEAR_RECORD", _IOC_WRITE, 0x4501, 0x08 },
+{ "acpi/apei.h", "APEI_ERST_GET_RECORD_COUNT", _IOC_READ, 0x4502, 0x04 },
+{ "asm-generic/ioctls.h", "FIOASYNC", 0, 0x5452, 0 },
+{ "asm-generic/ioctls.h", "FIOCLEX", 0, 0x5451, 0 },
+{ "asm-generic/ioctls.h", "FIONBIO", 0, 0x5421, 0 },
+{ "asm-generic/ioctls.h", "FIONCLEX", 0, 0x5450, 0 },
+{ "asm-generic/ioctls.h", "FIONREAD", 0, 0x541B, 0 },
+{ "asm-generic/ioctls.h", "FIOQSIZE", 0, 0x5460, 0 },
+{ "asm-generic/ioctls.h", "TCFLSH", 0, 0x540B, 0 },
+{ "asm-generic/ioctls.h", "TCGETA", 0, 0x5405, 0 },
+{ "asm-generic/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm-generic/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm-generic/ioctls.h", "TCGETX", 0, 0x5432, 0 },
+{ "asm-generic/ioctls.h", "TCSBRK", 0, 0x5409, 0 },
+{ "asm-generic/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm-generic/ioctls.h", "TCSETA", 0, 0x5406, 0 },
+{ "asm-generic/ioctls.h", "TCSETAF", 0, 0x5408, 0 },
+{ "asm-generic/ioctls.h", "TCSETAW", 0, 0x5407, 0 },
+{ "asm-generic/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm-generic/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm-generic/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm-generic/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETX", 0, 0x5433, 0 },
+{ "asm-generic/ioctls.h", "TCSETXF", 0, 0x5434, 0 },
+{ "asm-generic/ioctls.h", "TCSETXW", 0, 0x5435, 0 },
+{ "asm-generic/ioctls.h", "TCXONC", 0, 0x540A, 0 },
+{ "asm-generic/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm-generic/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm-generic/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm-generic/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm-generic/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm-generic/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPGRP", 0, 0x540F, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGRS485", 0, 0x542E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSID", 0, 0x5429, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm-generic/ioctls.h", "TIOCGWINSZ", 0, 0x5413, 0 },
+{ "asm-generic/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm-generic/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm-generic/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm-generic/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm-generic/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm-generic/ioctls.h", "TIOCOUTQ", 0, 0x5411, 0 },
+{ "asm-generic/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm-generic/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm-generic/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm-generic/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm-generic/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPGRP", 0, 0x5410, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSRS485", 0, 0x542F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm-generic/ioctls.h", "TIOCSWINSZ", 0, 0x5414, 0 },
+{ "asm-generic/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm-generic/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm-generic/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm-generic/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm-generic/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm-generic/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_BO_LIST", _IOC_READ|_IOC_WRITE, 0x6443, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CS", _IOC_READ|_IOC_WRITE, 0x6444, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CTX", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_METADATA", _IOC_READ|_IOC_WRITE, 0x6446, 0x120 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x08 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_OP", _IOC_READ|_IOC_WRITE, 0x6450, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6451, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_VA", _IOC_WRITE, 0x6448, 0x28 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_INFO", _IOC_WRITE, 0x6445, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_WAIT_CS", _IOC_READ|_IOC_WRITE, 0x6449, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_BUFS", _IOC_READ|_IOC_WRITE, 0x6416, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_CTX", _IOC_READ|_IOC_WRITE, 0x6420, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_DRAW", _IOC_READ|_IOC_WRITE, 0x6427, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_MAP", _IOC_READ|_IOC_WRITE, 0x6415, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ACQUIRE", _IOC_NONE, 0x6430, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6434, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_BIND", _IOC_WRITE, 0x6436, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ENABLE", _IOC_WRITE, 0x6432, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_FREE", _IOC_WRITE, 0x6435, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_INFO", _IOC_READ, 0x6433, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_RELEASE", _IOC_NONE, 0x6431, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_UNBIND", _IOC_WRITE, 0x6437, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AUTH_MAGIC", _IOC_WRITE, 0x6411, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_BLOCK", _IOC_READ|_IOC_WRITE, 0x6412, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_CONTROL", _IOC_WRITE, 0x6414, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_DMA", _IOC_READ|_IOC_WRITE, 0x6429, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_DROP_MASTER", _IOC_NONE, 0x641f, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_FINISH", _IOC_WRITE, 0x642c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_FREE_BUFS", _IOC_WRITE, 0x641a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_CLOSE", _IOC_WRITE, 0x6409, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_FLINK", _IOC_READ|_IOC_WRITE, 0x640a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_OPEN", _IOC_READ|_IOC_WRITE, 0x640b, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CAP", _IOC_READ|_IOC_WRITE, 0x640c, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CLIENT", _IOC_READ|_IOC_WRITE, 0x6405, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CTX", _IOC_READ|_IOC_WRITE, 0x6423, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAGIC", _IOC_READ, 0x6402, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAP", _IOC_READ|_IOC_WRITE, 0x6404, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_GET_SAREA_CTX", _IOC_READ|_IOC_WRITE, 0x641d, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_STATS", _IOC_READ, 0x6406, 0x7c },
+{ "drm/drm.h", "DRM_IOCTL_GET_UNIQUE", _IOC_READ|_IOC_WRITE, 0x6401, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_INFO_BUFS", _IOC_READ|_IOC_WRITE, 0x6418, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_IRQ_BUSID", _IOC_READ|_IOC_WRITE, 0x6403, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_LOCK", _IOC_WRITE, 0x642a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MAP_BUFS", _IOC_READ|_IOC_WRITE, 0x6419, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_MARK_BUFS", _IOC_WRITE, 0x6417, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODESET_CTL", _IOC_WRITE, 0x6408, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB", _IOC_READ|_IOC_WRITE, 0x64ae, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB2", _IOC_READ|_IOC_WRITE, 0x64b8, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATOMIC", _IOC_READ|_IOC_WRITE, 0x64bc, 0x38 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATTACHMODE", _IOC_READ|_IOC_WRITE, 0x64a8, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATEPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64bd, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATE_DUMB", _IOC_READ|_IOC_WRITE, 0x64b2, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR", _IOC_READ|_IOC_WRITE, 0x64a3, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR2", _IOC_READ|_IOC_WRITE, 0x64bb, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROYPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64be, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROY_DUMB", _IOC_READ|_IOC_WRITE, 0x64b4, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DETACHMODE", _IOC_READ|_IOC_WRITE, 0x64a9, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DIRTYFB", _IOC_READ|_IOC_WRITE, 0x64b1, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCONNECTOR", _IOC_READ|_IOC_WRITE, 0x64a7, 0x50 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCRTC", _IOC_READ|_IOC_WRITE, 0x64a1, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETENCODER", _IOC_READ|_IOC_WRITE, 0x64a6, 0x14 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETFB", _IOC_READ|_IOC_WRITE, 0x64ad, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a4, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANE", _IOC_READ|_IOC_WRITE, 0x64b6, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANERESOURCES", _IOC_READ|_IOC_WRITE, 0x64b5, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64ac, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64aa, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETRESOURCES", _IOC_READ|_IOC_WRITE, 0x64a0, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_MAP_DUMB", _IOC_READ|_IOC_WRITE, 0x64b3, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", _IOC_READ|_IOC_WRITE, 0x64b9, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ba, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_PAGE_FLIP", _IOC_READ|_IOC_WRITE, 0x64b0, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_RMFB", _IOC_READ|_IOC_WRITE, 0x64af, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETCRTC", _IOC_READ|_IOC_WRITE, 0x64a2, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a5, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPLANE", _IOC_READ|_IOC_WRITE, 0x64b7, 0x30 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ab, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MOD_CTX", _IOC_WRITE, 0x6422, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_NEW_CTX", _IOC_WRITE, 0x6425, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_FD_TO_HANDLE", _IOC_READ|_IOC_WRITE, 0x642e, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_HANDLE_TO_FD", _IOC_READ|_IOC_WRITE, 0x642d, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_RES_CTX", _IOC_READ|_IOC_WRITE, 0x6426, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_CTX", _IOC_READ|_IOC_WRITE, 0x6421, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_DRAW", _IOC_READ|_IOC_WRITE, 0x6428, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_RM_MAP", _IOC_WRITE, 0x641b, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_SET_CLIENT_CAP", _IOC_WRITE, 0x640d, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SET_MASTER", _IOC_NONE, 0x641e, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_SET_SAREA_CTX", _IOC_WRITE, 0x641c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SET_UNIQUE", _IOC_WRITE, 0x6410, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SET_VERSION", _IOC_READ|_IOC_WRITE, 0x6407, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SG_ALLOC", _IOC_READ|_IOC_WRITE, 0x6438, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SG_FREE", _IOC_WRITE, 0x6439, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SWITCH_CTX", _IOC_WRITE, 0x6424, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UNBLOCK", _IOC_READ|_IOC_WRITE, 0x6413, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_UNLOCK", _IOC_WRITE, 0x642b, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UPDATE_DRAW", _IOC_WRITE, 0x643f, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x6400, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_WAIT_VBLANK", _IOC_READ|_IOC_WRITE, 0x643a, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x30 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6448, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_WAIT", _IOC_WRITE, 0x6449, 0x20 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x20 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_EXEC", _IOC_READ|_IOC_WRITE, 0x6462, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_GET_VER", _IOC_READ|_IOC_WRITE, 0x6460, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", _IOC_READ|_IOC_WRITE, 0x6461, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_GET", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", _IOC_READ|_IOC_WRITE, 0x6473, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6470, 0x50 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", _IOC_READ|_IOC_WRITE, 0x6472, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6471, 0x60 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_CLEAR", _IOC_WRITE, 0x6442, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_COPY", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_DOCOPY", _IOC_NONE, 0x6448, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLIP", _IOC_NONE, 0x644e, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLUSH", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FSTATUS", _IOC_NONE, 0x644a, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETAGE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETBUF", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_INIT", _IOC_WRITE, 0x6440, 0x40 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_MC", _IOC_WRITE, 0x644c, 0x14 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0FLIP", _IOC_NONE, 0x644b, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0INFO", _IOC_READ, 0x6449, 0x08 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_RSTATUS", _IOC_NONE, 0x644d, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_SWAP", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_VERTEX", _IOC_WRITE, 0x6441, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_ALLOC", _IOC_READ|_IOC_WRITE, 0x6448, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_BATCHBUFFER", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_CMDBUFFER", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_DESTROY_HEAP", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLIP", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLUSH", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FREE", _IOC_WRITE, 0x6449, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x6457, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", _IOC_READ|_IOC_WRITE, 0x646d, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", _IOC_WRITE, 0x646e, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6474, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", _IOC_READ|_IOC_WRITE, 0x6475, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645b, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_ENTERVT", _IOC_NONE, 0x6459, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER", _IOC_WRITE, 0x6454, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER2", _IOC_WRITE, 0x6469, 0x40 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_APERTURE", _IOC_READ, 0x6463, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_CACHING", _IOC_READ|_IOC_WRITE, 0x6470, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6462, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_INIT", _IOC_WRITE, 0x6453, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_LEAVEVT", _IOC_NONE, 0x645a, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MADVISE", _IOC_READ|_IOC_WRITE, 0x6466, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP_GTT", _IOC_READ|_IOC_WRITE, 0x6464, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PIN", _IOC_READ|_IOC_WRITE, 0x6455, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PREAD", _IOC_WRITE, 0x645c, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PWRITE", _IOC_WRITE, 0x645d, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_CACHING", _IOC_WRITE, 0x646f, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_DOMAIN", _IOC_WRITE, 0x645f, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6461, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SW_FINISH", _IOC_WRITE, 0x6460, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_THROTTLE", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_UNPIN", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6473, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_WAIT", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6446, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", _IOC_READ|_IOC_WRITE, 0x6465, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_RESET_STATS", _IOC_READ|_IOC_WRITE, 0x6472, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646a, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_VBLANK_PIPE", _IOC_READ, 0x644e, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_HWS_ADDR", _IOC_WRITE, 0x6451, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT", _IOC_WRITE, 0x6440, 0x44 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT_HEAP", _IOC_WRITE, 0x644a, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_WAIT", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_ATTRS", _IOC_READ|_IOC_WRITE, 0x6468, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", _IOC_WRITE, 0x6467, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_REG_READ", _IOC_READ|_IOC_WRITE, 0x6471, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SETPARAM", _IOC_WRITE, 0x6447, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646b, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_VBLANK_PIPE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_VBLANK_SWAP", _IOC_READ|_IOC_WRITE, 0x644f, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_BLIT", _IOC_WRITE, 0x6448, 0x34 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_CLEAR", _IOC_WRITE, 0x6444, 0x14 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_DMA_BOOTSTRAP", _IOC_READ|_IOC_WRITE, 0x644c, 0x1c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_FLUSH", _IOC_WRITE, 0x6441, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6449, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_ILOAD", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INDICES", _IOC_WRITE, 0x6446, 0x10 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INIT", _IOC_WRITE, 0x6440, 0x5c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_RESET", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SET_FENCE", _IOC_WRITE, 0x644a, 0x04 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SWAP", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_VERTEX", _IOC_WRITE, 0x6445, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_WAIT_FENCE", _IOC_READ|_IOC_WRITE, 0x644b, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x20 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x18 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", _IOC_WRITE, 0x6483, 0x04 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", _IOC_WRITE, 0x6482, 0x08 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6484, 0x28 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6480, 0x30 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", _IOC_READ|_IOC_WRITE, 0x6481, 0x40 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x08 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_SET_PARAM", _IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC", _IOC_READ|_IOC_WRITE, 0x6440, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC_SURF", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_CLIENTCAP", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_EXECBUFFER", _IOC_WRITE, 0x6442, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_UPDATE_AREA", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_BLIT", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CLEAR", _IOC_WRITE, 0x6448, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_DEPTH", _IOC_WRITE, 0x644c, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FLIP", _IOC_NONE, 0x6453, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FULLSCREEN", _IOC_WRITE, 0x6450, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6452, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644f, 0x10 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INIT", _IOC_WRITE, 0x6440, 0x58 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_RESET", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_STIPPLE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_ALLOC", _IOC_READ|_IOC_WRITE, 0x6453, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CLEAR", _IOC_WRITE, 0x6448, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CMDBUF", _IOC_WRITE, 0x6450, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_INIT", _IOC_WRITE, 0x6440, 0x54 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESUME", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CS", _IOC_READ|_IOC_WRITE, 0x6466, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FLIP", _IOC_NONE, 0x6452, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FREE", _IOC_WRITE, 0x6454, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FULLSCREEN", _IOC_WRITE, 0x6446, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x646a, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645d, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6469, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x645c, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_OP", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PREAD", _IOC_READ|_IOC_WRITE, 0x6461, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PWRITE", _IOC_READ|_IOC_WRITE, 0x6462, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", _IOC_READ|_IOC_WRITE, 0x6463, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6468, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x646d, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_VA", _IOC_READ|_IOC_WRITE, 0x646b, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", _IOC_WRITE, 0x6464, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6451, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INFO", _IOC_READ|_IOC_WRITE, 0x6467, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INIT_HEAP", _IOC_WRITE, 0x6455, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6456, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_WAIT", _IOC_WRITE, 0x6457, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_RESET", _IOC_NONE, 0x6445, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SETPARAM", _IOC_WRITE, 0x6459, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_STIPPLE", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_ALLOC", _IOC_WRITE, 0x645a, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_FREE", _IOC_WRITE, 0x645b, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_TEXTURE", _IOC_READ|_IOC_WRITE, 0x644e, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX2", _IOC_WRITE, 0x644f, 0x18 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_CMDBUF", _IOC_WRITE, 0x6441, 0x24 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", _IOC_WRITE, 0x6443, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_INIT", _IOC_WRITE, 0x6440, 0x50 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6454, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_FREE", _IOC_WRITE, 0x6455, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6453, 0x08 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_ALLOC", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_FREE", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_INIT", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6446, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644d, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x644b, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644c, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x644a, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", _IOC_READ|_IOC_WRITE, 0x6449, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_OPEN_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x58 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_INCR", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_READ", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_WAIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_BO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_SHADER_BO", _IOC_READ|_IOC_WRITE, 0x6445, 0x18 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_GET_HANG_STATE", _IOC_READ|_IOC_WRITE, 0x6446, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_MMAP_BO", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_SUBMIT_CL", _IOC_READ|_IOC_WRITE, 0x6440, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_BO", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_SEQNO", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_ALLOCMEM", _IOC_READ|_IOC_WRITE, 0x6440, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_BLIT_SYNC", _IOC_WRITE, 0x644f, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUFFER", _IOC_WRITE, 0x6448, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUF_SIZE", _IOC_READ|_IOC_WRITE, 0x644b, 0x0c },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DEC_FUTEX", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_BLIT", _IOC_WRITE, 0x644e, 0x28 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_INIT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FB_INIT", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FLUSH", _IOC_NONE, 0x6449, 0x00 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FREEMEM", _IOC_WRITE, 0x6441, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_MAP_INIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_PCICMD", _IOC_WRITE, 0x644a, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_WAIT_IRQ", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_EXECBUFFER", _IOC_WRITE, 0x6442, 0x20 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x6449, 0x18 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", _IOC_READ|_IOC_WRITE, 0x6444, 0x38 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", _IOC_READ|_IOC_WRITE, 0x6446, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", _IOC_READ|_IOC_WRITE, 0x6447, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_WAIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_ACQUIRE", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x4106, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_BIND", _IOC_WRITE, 0x4108, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_CHIPSET_FLUSH", _IOC_NONE, 0x410a, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_DEALLOCATE", _IOC_WRITE, 0x4107, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_INFO", _IOC_READ, 0x4100, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_PROTECT", _IOC_WRITE, 0x4105, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_RELEASE", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_RESERVE", _IOC_WRITE, 0x4104, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_SETUP", _IOC_WRITE, 0x4103, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_UNBIND", _IOC_WRITE, 0x4109, 0x04 },
+{ "linux/am437x-vpfe.h", "VIDIOC_AM437X_CCDC_CFG", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE_DONE", _IOC_WRITE, 0x6309, 0x10 },
+{ "linux/android/binder.h", "BC_ACQUIRE_RESULT", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/android/binder.h", "BC_ATTEMPT_ACQUIRE", _IOC_WRITE, 0x630a, 0x08 },
+{ "linux/android/binder.h", "BC_CLEAR_DEATH_NOTIFICATION", _IOC_WRITE, 0x630f, 0x0c },
+{ "linux/android/binder.h", "BC_DEAD_BINDER_DONE", _IOC_WRITE, 0x6310, 0x08 },
+{ "linux/android/binder.h", "BC_DECREFS", _IOC_WRITE, 0x6307, 0x04 },
+{ "linux/android/binder.h", "BC_ENTER_LOOPER", _IOC_NONE, 0x630c, 0x00 },
+{ "linux/android/binder.h", "BC_EXIT_LOOPER", _IOC_NONE, 0x630d, 0x00 },
+{ "linux/android/binder.h", "BC_FREE_BUFFER", _IOC_WRITE, 0x6303, 0x08 },
+{ "linux/android/binder.h", "BC_INCREFS", _IOC_WRITE, 0x6304, 0x04 },
+{ "linux/android/binder.h", "BC_INCREFS_DONE", _IOC_WRITE, 0x6308, 0x10 },
+{ "linux/android/binder.h", "BC_REGISTER_LOOPER", _IOC_NONE, 0x630b, 0x00 },
+{ "linux/android/binder.h", "BC_RELEASE", _IOC_WRITE, 0x6306, 0x04 },
+{ "linux/android/binder.h", "BC_REPLY", _IOC_WRITE, 0x6301, 0x40 },
+{ "linux/android/binder.h", "BC_REQUEST_DEATH_NOTIFICATION", _IOC_WRITE, 0x630e, 0x0c },
+{ "linux/android/binder.h", "BC_TRANSACTION", _IOC_WRITE, 0x6300, 0x40 },
+{ "linux/android/binder.h", "BINDER_SET_CONTEXT_MGR", _IOC_WRITE, 0x6207, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_PRIORITY", _IOC_WRITE, 0x6206, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_TIMEOUT", _IOC_WRITE, 0x6203, 0x08 },
+{ "linux/android/binder.h", "BINDER_SET_MAX_THREADS", _IOC_WRITE, 0x6205, 0x04 },
+{ "linux/android/binder.h", "BINDER_THREAD_EXIT", _IOC_WRITE, 0x6208, 0x04 },
+{ "linux/android/binder.h", "BINDER_VERSION", _IOC_READ|_IOC_WRITE, 0x6209, 0x04 },
+{ "linux/android/binder.h", "BINDER_WRITE_READ", _IOC_READ|_IOC_WRITE, 0x6201, 0x30 },
+{ "linux/android/binder.h", "BR_ACQUIRE", _IOC_READ, 0x7208, 0x10 },
+{ "linux/android/binder.h", "BR_ACQUIRE_RESULT", _IOC_READ, 0x7204, 0x04 },
+{ "linux/android/binder.h", "BR_ATTEMPT_ACQUIRE", _IOC_READ, 0x720b, 0x18 },
+{ "linux/android/binder.h", "BR_CLEAR_DEATH_NOTIFICATION_DONE", _IOC_READ, 0x7210, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_BINDER", _IOC_READ, 0x720f, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_REPLY", _IOC_NONE, 0x7205, 0x00 },
+{ "linux/android/binder.h", "BR_DECREFS", _IOC_READ, 0x720a, 0x10 },
+{ "linux/android/binder.h", "BR_ERROR", _IOC_READ, 0x7200, 0x04 },
+{ "linux/android/binder.h", "BR_FAILED_REPLY", _IOC_NONE, 0x7211, 0x00 },
+{ "linux/android/binder.h", "BR_FINISHED", _IOC_NONE, 0x720e, 0x00 },
+{ "linux/android/binder.h", "BR_INCREFS", _IOC_READ, 0x7207, 0x10 },
+{ "linux/android/binder.h", "BR_NOOP", _IOC_NONE, 0x720c, 0x00 },
+{ "linux/android/binder.h", "BR_OK", _IOC_NONE, 0x7201, 0x00 },
+{ "linux/android/binder.h", "BR_RELEASE", _IOC_READ, 0x7209, 0x10 },
+{ "linux/android/binder.h", "BR_REPLY", _IOC_READ, 0x7203, 0x40 },
+{ "linux/android/binder.h", "BR_SPAWN_LOOPER", _IOC_NONE, 0x720d, 0x00 },
+{ "linux/android/binder.h", "BR_TRANSACTION", _IOC_READ, 0x7202, 0x40 },
+{ "linux/android/binder.h", "BR_TRANSACTION_COMPLETE", _IOC_NONE, 0x7206, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_STANDBY", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_SUSPEND", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/arcfb.h", "FBIO_GETCONTROL2", _IOC_READ, 0x4689, 0x04 },
+{ "linux/arcfb.h", "FBIO_WAITEVENT", _IOC_NONE, 0x4688, 0x00 },
+{ "linux/atm_eni.h", "ENI_MEMDUMP", _IOC_WRITE, 0x6160, 0x0c },
+{ "linux/atm_eni.h", "ENI_SETMULT", _IOC_WRITE, 0x6167, 0x0c },
+{ "linux/atm_he.h", "HE_GET_REG", _IOC_WRITE, 0x6160, 0x0c },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTAT", _IOC_WRITE, 0x6132, 0x0c },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTATZ", _IOC_WRITE, 0x6133, 0x0c },
+{ "linux/atm_nicstar.h", "NS_ADJBUFLEV", _IOC_NONE, 0x6163, 0x00 },
+{ "linux/atm_nicstar.h", "NS_GETPSTAT", _IOC_READ|_IOC_WRITE, 0x6161, 0x0c },
+{ "linux/atm_nicstar.h", "NS_SETBUFLEV", _IOC_WRITE, 0x6162, 0x0c },
+{ "linux/atm_tcp.h", "ATMTCP_CREATE", _IOC_NONE, 0x618e, 0x00 },
+{ "linux/atm_tcp.h", "ATMTCP_REMOVE", _IOC_NONE, 0x618f, 0x00 },
+{ "linux/atm_tcp.h", "SIOCSIFATMTCP", _IOC_NONE, 0x6180, 0x00 },
+{ "linux/atm_zatm.h", "ZATM_GETPOOL", _IOC_WRITE, 0x6161, 0x0c },
+{ "linux/atm_zatm.h", "ZATM_GETPOOLZ", _IOC_WRITE, 0x6162, 0x0c },
+{ "linux/atm_zatm.h", "ZATM_SETPOOL", _IOC_WRITE, 0x6163, 0x0c },
+{ "linux/atmarp.h", "ATMARPD_CTRL", _IOC_NONE, 0x61e1, 0x00 },
+{ "linux/atmarp.h", "ATMARP_ENCAP", _IOC_NONE, 0x61e5, 0x00 },
+{ "linux/atmarp.h", "ATMARP_MKIP", _IOC_NONE, 0x61e2, 0x00 },
+{ "linux/atmarp.h", "ATMARP_SETENTRY", _IOC_NONE, 0x61e3, 0x00 },
+{ "linux/atmbr2684.h", "BR2684_SETFILT", _IOC_WRITE, 0x6190, 0x1c },
+{ "linux/atmclip.h", "SIOCMKCLIP", _IOC_NONE, 0x61e0, 0x00 },
+{ "linux/atmdev.h", "ATM_ADDADDR", _IOC_WRITE, 0x6188, 0x0c },
+{ "linux/atmdev.h", "ATM_ADDLECSADDR", _IOC_WRITE, 0x618e, 0x0c },
+{ "linux/atmdev.h", "ATM_ADDPARTY", _IOC_WRITE, 0x61f4, 0x08 },
+{ "linux/atmdev.h", "ATM_DELADDR", _IOC_WRITE, 0x6189, 0x0c },
+{ "linux/atmdev.h", "ATM_DELLECSADDR", _IOC_WRITE, 0x618f, 0x0c },
+{ "linux/atmdev.h", "ATM_DROPPARTY", _IOC_WRITE, 0x61f5, 0x04 },
+{ "linux/atmdev.h", "ATM_GETADDR", _IOC_WRITE, 0x6186, 0x0c },
+{ "linux/atmdev.h", "ATM_GETCIRANGE", _IOC_WRITE, 0x618a, 0x0c },
+{ "linux/atmdev.h", "ATM_GETESI", _IOC_WRITE, 0x6185, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLECSADDR", _IOC_WRITE, 0x6190, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLINKRATE", _IOC_WRITE, 0x6181, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLOOP", _IOC_WRITE, 0x6152, 0x0c },
+{ "linux/atmdev.h", "ATM_GETNAMES", _IOC_WRITE, 0x6183, 0x08 },
+{ "linux/atmdev.h", "ATM_GETSTAT", _IOC_WRITE, 0x6150, 0x0c },
+{ "linux/atmdev.h", "ATM_GETSTATZ", _IOC_WRITE, 0x6151, 0x0c },
+{ "linux/atmdev.h", "ATM_GETTYPE", _IOC_WRITE, 0x6184, 0x0c },
+{ "linux/atmdev.h", "ATM_NEWBACKENDIF", _IOC_WRITE, 0x61f3, 0x02 },
+{ "linux/atmdev.h", "ATM_QUERYLOOP", _IOC_WRITE, 0x6154, 0x0c },
+{ "linux/atmdev.h", "ATM_RSTADDR", _IOC_WRITE, 0x6187, 0x0c },
+{ "linux/atmdev.h", "ATM_SETBACKEND", _IOC_WRITE, 0x61f2, 0x02 },
+{ "linux/atmdev.h", "ATM_SETCIRANGE", _IOC_WRITE, 0x618b, 0x0c },
+{ "linux/atmdev.h", "ATM_SETESI", _IOC_WRITE, 0x618c, 0x0c },
+{ "linux/atmdev.h", "ATM_SETESIF", _IOC_WRITE, 0x618d, 0x0c },
+{ "linux/atmdev.h", "ATM_SETLOOP", _IOC_WRITE, 0x6153, 0x0c },
+{ "linux/atmdev.h", "ATM_SETSC", _IOC_WRITE, 0x61f1, 0x04 },
+{ "linux/atmlec.h", "ATMLEC_CTRL", _IOC_NONE, 0x61d0, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_DATA", _IOC_NONE, 0x61d1, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_MCAST", _IOC_NONE, 0x61d2, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_CTRL", _IOC_NONE, 0x61d8, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_DATA", _IOC_NONE, 0x61d9, 0x00 },
+{ "linux/atmsvc.h", "ATMSIGD_CTRL", _IOC_NONE, 0x61f0, 0x00 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ASKUMOUNT", _IOC_READ|_IOC_WRITE, 0x937d, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CATATONIC", _IOC_READ|_IOC_WRITE, 0x9379, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CLOSEMOUNT", _IOC_READ|_IOC_WRITE, 0x9375, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_EXPIRE", _IOC_READ|_IOC_WRITE, 0x937c, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_FAIL", _IOC_READ|_IOC_WRITE, 0x9377, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", _IOC_READ|_IOC_WRITE, 0x937e, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_OPENMOUNT", _IOC_READ|_IOC_WRITE, 0x9374, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOSUBVER", _IOC_READ|_IOC_WRITE, 0x9373, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOVER", _IOC_READ|_IOC_WRITE, 0x9372, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_READY", _IOC_READ|_IOC_WRITE, 0x9376, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_REQUESTER", _IOC_READ|_IOC_WRITE, 0x937b, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_SETPIPEFD", _IOC_READ|_IOC_WRITE, 0x9378, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_TIMEOUT", _IOC_READ|_IOC_WRITE, 0x937a, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x9371, 0x18 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_CATATONIC", _IOC_NONE, 0x9362, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_EXPIRE", _IOC_READ, 0x9365, 0x10c },
+{ "linux/auto_fs.h", "AUTOFS_IOC_FAIL", _IOC_NONE, 0x9361, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_PROTOVER", _IOC_READ, 0x9363, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_READY", _IOC_NONE, 0x9360, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT32", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_ASKUMOUNT", _IOC_READ, 0x9370, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_EXPIRE_MULTI", _IOC_WRITE, 0x9366, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_PROTOSUBVER", _IOC_READ, 0x9367, 0x04 },
+{ "linux/blkpg.h", "BLKPG", _IOC_NONE, 0x1269, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_ADD_DEV", _IOC_WRITE, 0x940a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE", _IOC_WRITE, 0x940c, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_CTL", _IOC_WRITE, 0x9421, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_PROGRESS", _IOC_READ, 0x9422, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_V2", _IOC_READ|_IOC_WRITE, 0x9420, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE_RANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFAULT_SUBVOL", _IOC_WRITE, 0x9413, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG", _IOC_WRITE, 0x9402, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG_RANGE", _IOC_WRITE, 0x9410, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEVICES_READY", _IOC_READ, 0x9427, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_INFO", _IOC_READ|_IOC_WRITE, 0x941e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_REPLACE", _IOC_READ|_IOC_WRITE, 0x9435, 0xa28 },
+{ "linux/btrfs.h", "BTRFS_IOC_FILE_EXTENT_SAME", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_FS_INFO", _IOC_READ, 0x941f, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_DEV_STATS", _IOC_READ|_IOC_WRITE, 0x9434, 0x408 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FEATURES", _IOC_READ, 0x9439, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FSLABEL", _IOC_READ, 0x9431, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_SUPPORTED_FEATURES", _IOC_READ, 0x9439, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_LOOKUP", _IOC_READ|_IOC_WRITE, 0x9412, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_PATHS", _IOC_READ|_IOC_WRITE, 0x9423, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_LOGICAL_INO", _IOC_READ|_IOC_WRITE, 0x9424, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_ASSIGN", _IOC_WRITE, 0x9429, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_CREATE", _IOC_WRITE, 0x942a, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_LIMIT", _IOC_READ, 0x942b, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_CTL", _IOC_READ|_IOC_WRITE, 0x9428, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN", _IOC_WRITE, 0x942c, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_STATUS", _IOC_READ, 0x942d, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_WAIT", _IOC_NONE, 0x942e, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_RESIZE", _IOC_WRITE, 0x9403, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV", _IOC_WRITE, 0x940b, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV_V2", _IOC_WRITE, 0x943a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCAN_DEV", _IOC_WRITE, 0x9404, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB", _IOC_READ|_IOC_WRITE, 0x941b, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_CANCEL", _IOC_NONE, 0x941c, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_PROGRESS", _IOC_READ|_IOC_WRITE, 0x941d, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SEND", _IOC_WRITE, 0x9426, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FEATURES", _IOC_WRITE, 0x9439, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FSLABEL", _IOC_WRITE, 0x9432, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_RECEIVED_SUBVOL", _IOC_READ|_IOC_WRITE, 0x9425, 0xc8 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE", _IOC_WRITE, 0x9401, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE_V2", _IOC_WRITE, 0x9417, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_DESTROY", _IOC_WRITE, 0x940f, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SPACE_INFO", _IOC_READ|_IOC_WRITE, 0x9414, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_START_SYNC", _IOC_READ, 0x9418, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE", _IOC_WRITE, 0x940e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE_V2", _IOC_WRITE, 0x9418, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_GETFLAGS", _IOC_READ, 0x9419, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_SETFLAGS", _IOC_WRITE, 0x941a, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SYNC", _IOC_NONE, 0x9408, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_END", _IOC_NONE, 0x9407, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_START", _IOC_NONE, 0x9406, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH", _IOC_READ|_IOC_WRITE, 0x9411, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH_V2", _IOC_READ|_IOC_WRITE, 0x9411, 0x70 },
+{ "linux/btrfs.h", "BTRFS_IOC_WAIT_SYNC", _IOC_WRITE, 0x9416, 0x08 },
+{ "linux/capi.h", "CAPI_CLR_FLAGS", _IOC_READ, 0x4325, 0x04 },
+{ "linux/capi.h", "CAPI_GET_ERRCODE", _IOC_READ, 0x4321, 0x02 },
+{ "linux/capi.h", "CAPI_GET_FLAGS", _IOC_READ, 0x4323, 0x04 },
+{ "linux/capi.h", "CAPI_GET_MANUFACTURER", _IOC_READ|_IOC_WRITE, 0x4306, 0x04 },
+{ "linux/capi.h", "CAPI_GET_PROFILE", _IOC_READ|_IOC_WRITE, 0x4309, 0x40 },
+{ "linux/capi.h", "CAPI_GET_SERIAL", _IOC_READ|_IOC_WRITE, 0x4308, 0x04 },
+{ "linux/capi.h", "CAPI_GET_VERSION", _IOC_READ|_IOC_WRITE, 0x4307, 0x10 },
+{ "linux/capi.h", "CAPI_INSTALLED", _IOC_READ, 0x4322, 0x02 },
+{ "linux/capi.h", "CAPI_MANUFACTURER_CMD", _IOC_READ|_IOC_WRITE, 0x4320, 0x08 },
+{ "linux/capi.h", "CAPI_NCCI_GETUNIT", _IOC_READ, 0x4327, 0x04 },
+{ "linux/capi.h", "CAPI_NCCI_OPENCOUNT", _IOC_READ, 0x4326, 0x04 },
+{ "linux/capi.h", "CAPI_REGISTER", _IOC_WRITE, 0x4301, 0x0c },
+{ "linux/capi.h", "CAPI_SET_FLAGS", _IOC_READ, 0x4324, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_BIG_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x4212, 0x58 },
+{ "linux/cciss_ioctl.h", "CCISS_DEREGDISK", _IOC_NONE, 0x420c, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_GETBUSTYPES", _IOC_READ, 0x4207, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETDRIVVER", _IOC_READ, 0x4209, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETFIRMVER", _IOC_READ, 0x4208, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETHEARTBEAT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETINTINFO", _IOC_READ, 0x4202, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_GETLUNINFO", _IOC_READ, 0x4211, 0x0c },
+{ "linux/cciss_ioctl.h", "CCISS_GETNODENAME", _IOC_READ, 0x4204, 0x10 },
+{ "linux/cciss_ioctl.h", "CCISS_GETPCIINFO", _IOC_READ, 0x4201, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x420b, 0x54 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWD", _IOC_NONE, 0x420e, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWDISK", _IOC_WRITE, 0x420d, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_RESCANDISK", _IOC_NONE, 0x4210, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REVALIDVOLS", _IOC_NONE, 0x420a, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_SETINTINFO", _IOC_WRITE, 0x4203, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_SETNODENAME", _IOC_WRITE, 0x4205, 0x10 },
+{ "linux/cdrom.h", "CDROMAUDIOBUFSIZ", 0, 0x5382, 0 },
+{ "linux/cdrom.h", "CDROMCLOSETRAY", 0, 0x5319, 0 },
+{ "linux/cdrom.h", "CDROMEJECT", 0, 0x5309, 0 },
+{ "linux/cdrom.h", "CDROMEJECT_SW", 0, 0x530f, 0 },
+{ "linux/cdrom.h", "CDROMGETSPINDOWN", 0, 0x531d, 0 },
+{ "linux/cdrom.h", "CDROMMULTISESSION", 0, 0x5310, 0 },
+{ "linux/cdrom.h", "CDROMPAUSE", 0, 0x5301, 0 },
+{ "linux/cdrom.h", "CDROMPLAYBLK", 0, 0x5317, 0 },
+{ "linux/cdrom.h", "CDROMPLAYMSF", 0, 0x5303, 0 },
+{ "linux/cdrom.h", "CDROMPLAYTRKIND", 0, 0x5304, 0 },
+{ "linux/cdrom.h", "CDROMREADALL", 0, 0x5318, 0 },
+{ "linux/cdrom.h", "CDROMREADAUDIO", 0, 0x530e, 0 },
+{ "linux/cdrom.h", "CDROMREADCOOKED", 0, 0x5315, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE1", 0, 0x530d, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE2", 0, 0x530c, 0 },
+{ "linux/cdrom.h", "CDROMREADRAW", 0, 0x5314, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCENTRY", 0, 0x5306, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCHDR", 0, 0x5305, 0 },
+{ "linux/cdrom.h", "CDROMRESET", 0, 0x5312, 0 },
+{ "linux/cdrom.h", "CDROMRESUME", 0, 0x5302, 0 },
+{ "linux/cdrom.h", "CDROMSEEK", 0, 0x5316, 0 },
+{ "linux/cdrom.h", "CDROMSETSPINDOWN", 0, 0x531e, 0 },
+{ "linux/cdrom.h", "CDROMSTART", 0, 0x5308, 0 },
+{ "linux/cdrom.h", "CDROMSTOP", 0, 0x5307, 0 },
+{ "linux/cdrom.h", "CDROMSUBCHNL", 0, 0x530b, 0 },
+{ "linux/cdrom.h", "CDROMVOLCTRL", 0, 0x530a, 0 },
+{ "linux/cdrom.h", "CDROMVOLREAD", 0, 0x5313, 0 },
+{ "linux/cdrom.h", "CDROM_CHANGER_NSLOTS", 0, 0x5328, 0 },
+{ "linux/cdrom.h", "CDROM_CLEAR_OPTIONS", 0, 0x5321, 0 },
+{ "linux/cdrom.h", "CDROM_DEBUG", 0, 0x5330, 0 },
+{ "linux/cdrom.h", "CDROM_DISC_STATUS", 0, 0x5327, 0 },
+{ "linux/cdrom.h", "CDROM_DRIVE_STATUS", 0, 0x5326, 0 },
+{ "linux/cdrom.h", "CDROM_GET_CAPABILITY", 0, 0x5331, 0 },
+{ "linux/cdrom.h", "CDROM_GET_MCN", 0, 0x5311, 0 },
+{ "linux/cdrom.h", "CDROM_LAST_WRITTEN", 0, 0x5395, 0 },
+{ "linux/cdrom.h", "CDROM_LOCKDOOR", 0, 0x5329, 0 },
+{ "linux/cdrom.h", "CDROM_MEDIA_CHANGED", 0, 0x5325, 0 },
+{ "linux/cdrom.h", "CDROM_NEXT_WRITABLE", 0, 0x5394, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_DISC", 0, 0x5323, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_SPEED", 0, 0x5322, 0 },
+{ "linux/cdrom.h", "CDROM_SEND_PACKET", 0, 0x5393, 0 },
+{ "linux/cdrom.h", "CDROM_SET_OPTIONS", 0, 0x5320, 0 },
+{ "linux/cdrom.h", "DVD_AUTH", 0, 0x5392, 0 },
+{ "linux/cdrom.h", "DVD_READ_STRUCT", 0, 0x5390, 0 },
+{ "linux/cdrom.h", "DVD_WRITE_STRUCT", 0, 0x5391, 0 },
+{ "linux/chio.h", "CHIOEXCHANGE", _IOC_WRITE, 0x6302, 0x1c },
+{ "linux/chio.h", "CHIOGELEM", _IOC_WRITE, 0x6310, 0x6c },
+{ "linux/chio.h", "CHIOGPARAMS", _IOC_READ, 0x6306, 0x14 },
+{ "linux/chio.h", "CHIOGPICKER", _IOC_READ, 0x6304, 0x04 },
+{ "linux/chio.h", "CHIOGSTATUS", _IOC_WRITE, 0x6308, 0x08 },
+{ "linux/chio.h", "CHIOGVPARAMS", _IOC_READ, 0x6313, 0x70 },
+{ "linux/chio.h", "CHIOINITELEM", _IOC_NONE, 0x6311, 0x00 },
+{ "linux/chio.h", "CHIOMOVE", _IOC_WRITE, 0x6301, 0x14 },
+{ "linux/chio.h", "CHIOPOSITION", _IOC_WRITE, 0x6303, 0x0c },
+{ "linux/chio.h", "CHIOSPICKER", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/chio.h", "CHIOSVOLTAG", _IOC_WRITE, 0x6312, 0x30 },
+{ "linux/cm4000_cs.h", "CM_IOCARDOFF", _IOC_NONE, 0x6304, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOCGATR", _IOC_READ|_IOC_WRITE, 0x6301, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCGSTATUS", _IOC_READ, 0x6300, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCSPTS", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCSRDR", _IOC_NONE, 0x6303, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOSDBGLVL", _IOC_WRITE, 0x63fa, 0x04 },
+{ "linux/coda.h", "CIOC_KERNEL_VERSION", _IOC_READ|_IOC_WRITE, 0x630a, 0x04 },
+{ "linux/dm-ioctl.h", "DM_DEV_CREATE", _IOC_READ|_IOC_WRITE, 0xfd03, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_REMOVE", _IOC_READ|_IOC_WRITE, 0xfd04, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_RENAME", _IOC_READ|_IOC_WRITE, 0xfd05, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SET_GEOMETRY", _IOC_READ|_IOC_WRITE, 0xfd0f, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_STATUS", _IOC_READ|_IOC_WRITE, 0xfd07, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SUSPEND", _IOC_READ|_IOC_WRITE, 0xfd06, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_WAIT", _IOC_READ|_IOC_WRITE, 0xfd08, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_DEVICES", _IOC_READ|_IOC_WRITE, 0xfd02, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_VERSIONS", _IOC_READ|_IOC_WRITE, 0xfd0d, 0x138 },
+{ "linux/dm-ioctl.h", "DM_REMOVE_ALL", _IOC_READ|_IOC_WRITE, 0xfd01, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_CLEAR", _IOC_READ|_IOC_WRITE, 0xfd0a, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_DEPS", _IOC_READ|_IOC_WRITE, 0xfd0b, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_LOAD", _IOC_READ|_IOC_WRITE, 0xfd09, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_STATUS", _IOC_READ|_IOC_WRITE, 0xfd0c, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TARGET_MSG", _IOC_READ|_IOC_WRITE, 0xfd0e, 0x138 },
+{ "linux/dm-ioctl.h", "DM_VERSION", _IOC_READ|_IOC_WRITE, 0xfd00, 0x138 },
+{ "linux/dma-buf.h", "DMA_BUF_IOCTL_SYNC", _IOC_WRITE, 0x6200, 0x08 },
+{ "linux/dn.h", "OSIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "OSIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dn.h", "SIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "SIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dvb/audio.h", "AUDIO_BILINGUAL_CHANNEL_SELECT", _IOC_NONE, 0x6f14, 0x00 },
+{ "linux/dvb/audio.h", "AUDIO_CHANNEL_SELECT", _IOC_NONE, 0x6f09, 0x00 },
+{ "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 },
+{ "linux/dvb/audio.h", "AUDIO_STOP", _IOC_NONE, 0x6f01, 0x00 },
+{ "linux/dvb/ca.h", "CA_GET_CAP", _IOC_READ, 0x6f81, 0x10 },
+{ "linux/dvb/ca.h", "CA_GET_DESCR_INFO", _IOC_READ, 0x6f83, 0x08 },
+{ "linux/dvb/ca.h", "CA_GET_MSG", _IOC_READ, 0x6f84, 0x10c },
+{ "linux/dvb/ca.h", "CA_GET_SLOT_INFO", _IOC_READ, 0x6f82, 0x0c },
+{ "linux/dvb/ca.h", "CA_RESET", _IOC_NONE, 0x6f80, 0x00 },
+{ "linux/dvb/ca.h", "CA_SEND_MSG", _IOC_WRITE, 0x6f85, 0x10c },
+{ "linux/dvb/ca.h", "CA_SET_DESCR", _IOC_WRITE, 0x6f86, 0x10 },
+{ "linux/dvb/ca.h", "CA_SET_PID", _IOC_WRITE, 0x6f87, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_ADD_PID", _IOC_WRITE, 0x6f33, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_GET_CAPS", _IOC_READ, 0x6f30, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_GET_PES_PIDS", _IOC_READ, 0x6f2f, 0x0a },
+{ "linux/dvb/dmx.h", "DMX_GET_STC", _IOC_READ|_IOC_WRITE, 0x6f32, 0x10 },
+{ "linux/dvb/dmx.h", "DMX_REMOVE_PID", _IOC_WRITE, 0x6f34, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_SET_BUFFER_SIZE", _IOC_NONE, 0x6f2d, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_SET_FILTER", _IOC_WRITE, 0x6f2b, 0x3c },
+{ "linux/dvb/dmx.h", "DMX_SET_PES_FILTER", _IOC_WRITE, 0x6f2c, 0x14 },
+{ "linux/dvb/dmx.h", "DMX_SET_SOURCE", _IOC_WRITE, 0x6f31, 0x04 },
+{ "linux/dvb/dmx.h", "DMX_START", _IOC_NONE, 0x6f29, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_STOP", _IOC_NONE, 0x6f2a, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RECV_SLAVE_REPLY", _IOC_READ, 0x6f40, 0x0c },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RESET_OVERLOAD", _IOC_NONE, 0x6f3e, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_BURST", _IOC_NONE, 0x6f41, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_MASTER_CMD", _IOC_WRITE, 0x6f3f, 0x07 },
+{ "linux/dvb/frontend.h", "FE_DISHNETWORK_SEND_LEGACY_CMD", _IOC_NONE, 0x6f50, 0x00 },
+{ "linux/dvb/frontend.h", "FE_ENABLE_HIGH_LNB_VOLTAGE", _IOC_NONE, 0x6f44, 0x00 },
+{ "linux/dvb/frontend.h", "FE_GET_EVENT", _IOC_READ, 0x6f4e, 0x28 },
+{ "linux/dvb/frontend.h", "FE_GET_FRONTEND", _IOC_READ, 0x6f4d, 0x24 },
+{ "linux/dvb/frontend.h", "FE_GET_INFO", _IOC_READ, 0x6f3d, 0xa8 },
+{ "linux/dvb/frontend.h", "FE_GET_PROPERTY", _IOC_READ, 0x6f53, 0x08 },
+{ "linux/dvb/frontend.h", "FE_READ_BER", _IOC_READ, 0x6f46, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_SIGNAL_STRENGTH", _IOC_READ, 0x6f47, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_SNR", _IOC_READ, 0x6f48, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_STATUS", _IOC_READ, 0x6f45, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_UNCORRECTED_BLOCKS", _IOC_READ, 0x6f49, 0x04 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND", _IOC_WRITE, 0x6f4c, 0x24 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND_TUNE_MODE", _IOC_NONE, 0x6f51, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_PROPERTY", _IOC_WRITE, 0x6f52, 0x08 },
+{ "linux/dvb/frontend.h", "FE_SET_TONE", _IOC_NONE, 0x6f42, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_VOLTAGE", _IOC_NONE, 0x6f43, 0x00 },
+{ "linux/dvb/net.h", "NET_ADD_IF", _IOC_READ|_IOC_WRITE, 0x6f34, 0x06 },
+{ "linux/dvb/net.h", "NET_GET_IF", _IOC_READ|_IOC_WRITE, 0x6f36, 0x06 },
+{ "linux/dvb/net.h", "NET_REMOVE_IF", _IOC_NONE, 0x6f35, 0x00 },
+{ "linux/dvb/osd.h", "OSD_GET_CAPABILITY", _IOC_READ, 0x6fa1, 0x08 },
+{ "linux/dvb/osd.h", "OSD_SEND_CMD", _IOC_WRITE, 0x6fa0, 0x1c },
+{ "linux/dvb/video.h", "VIDEO_CLEAR_BUFFER", _IOC_NONE, 0x6f22, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3b, 0x48 },
+{ "linux/dvb/video.h", "VIDEO_CONTINUE", _IOC_NONE, 0x6f18, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FAST_FORWARD", _IOC_NONE, 0x6f1f, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FREEZE", _IOC_NONE, 0x6f17, 0x00 },
+{ "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 },
+{ "linux/dvb/video.h", "VIDEO_TRY_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3c, 0x48 },
+{ "linux/fb.h", "FBIOBLANK", 0, 0x4611, 0 },
+{ "linux/fb.h", "FBIOGETCMAP", 0, 0x4604, 0 },
+{ "linux/fb.h", "FBIOGET_CON2FBMAP", 0, 0x460F, 0 },
+{ "linux/fb.h", "FBIOGET_DISPINFO", 0, 0x4618, 0 },
+{ "linux/fb.h", "FBIOGET_FSCREENINFO", 0, 0x4602, 0 },
+{ "linux/fb.h", "FBIOGET_GLYPH", 0, 0x4615, 0 },
+{ "linux/fb.h", "FBIOGET_HWCINFO", 0, 0x4616, 0 },
+{ "linux/fb.h", "FBIOGET_VBLANK", _IOC_READ, 0x4612, 0x20 },
+{ "linux/fb.h", "FBIOGET_VSCREENINFO", 0, 0x4600, 0 },
+{ "linux/fb.h", "FBIOPAN_DISPLAY", 0, 0x4606, 0 },
+{ "linux/fb.h", "FBIOPUTCMAP", 0, 0x4605, 0 },
+{ "linux/fb.h", "FBIOPUT_CON2FBMAP", 0, 0x4610, 0 },
+{ "linux/fb.h", "FBIOPUT_MODEINFO", 0, 0x4617, 0 },
+{ "linux/fb.h", "FBIOPUT_VSCREENINFO", 0, 0x4601, 0 },
+{ "linux/fb.h", "FBIO_ALLOC", 0, 0x4613, 0 },
+{ "linux/fb.h", "FBIO_CURSOR", _IOC_READ|_IOC_WRITE, 0x4608, 0x48 },
+{ "linux/fb.h", "FBIO_FREE", 0, 0x4614, 0 },
+{ "linux/fb.h", "FBIO_WAITFORVSYNC", _IOC_WRITE, 0x4620, 0x04 },
+{ "linux/fd.h", "FDCLRPRM", _IOC_NONE, 0x0241, 0x00 },
+{ "linux/fd.h", "FDDEFPRM", _IOC_WRITE, 0x0243, 0x1c },
+{ "linux/fd.h", "FDEJECT", _IOC_NONE, 0x025a, 0x00 },
+{ "linux/fd.h", "FDFLUSH", _IOC_NONE, 0x024b, 0x00 },
+{ "linux/fd.h", "FDFMTBEG", _IOC_NONE, 0x0247, 0x00 },
+{ "linux/fd.h", "FDFMTEND", _IOC_NONE, 0x0249, 0x00 },
+{ "linux/fd.h", "FDFMTTRK", _IOC_WRITE, 0x0248, 0x0c },
+{ "linux/fd.h", "FDGETDRVPRM", _IOC_READ, 0x0211, 0x58 },
+{ "linux/fd.h", "FDGETDRVSTAT", _IOC_READ, 0x0212, 0x34 },
+{ "linux/fd.h", "FDGETDRVTYP", _IOC_READ, 0x020f, 0x10 },
+{ "linux/fd.h", "FDGETFDCSTAT", _IOC_READ, 0x0215, 0x20 },
+{ "linux/fd.h", "FDGETMAXERRS", _IOC_READ, 0x020e, 0x14 },
+{ "linux/fd.h", "FDGETPRM", _IOC_READ, 0x0204, 0x1c },
+{ "linux/fd.h", "FDMSGOFF", _IOC_NONE, 0x0246, 0x00 },
+{ "linux/fd.h", "FDMSGON", _IOC_NONE, 0x0245, 0x00 },
+{ "linux/fd.h", "FDPOLLDRVSTAT", _IOC_READ, 0x0213, 0x34 },
+{ "linux/fd.h", "FDRAWCMD", _IOC_NONE, 0x0258, 0x00 },
+{ "linux/fd.h", "FDRESET", _IOC_NONE, 0x0254, 0x00 },
+{ "linux/fd.h", "FDSETDRVPRM", _IOC_WRITE, 0x0290, 0x58 },
+{ "linux/fd.h", "FDSETEMSGTRESH", _IOC_NONE, 0x024a, 0x00 },
+{ "linux/fd.h", "FDSETMAXERRS", _IOC_WRITE, 0x024c, 0x14 },
+{ "linux/fd.h", "FDSETPRM", _IOC_WRITE, 0x0242, 0x1c },
+{ "linux/fd.h", "FDTWADDLE", _IOC_NONE, 0x0259, 0x00 },
+{ "linux/fd.h", "FDWERRORCLR", _IOC_NONE, 0x0256, 0x00 },
+{ "linux/fd.h", "FDWERRORGET", _IOC_READ, 0x0217, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ADD_DESCRIPTOR", _IOC_READ|_IOC_WRITE, 0x2306, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x2302, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", _IOC_READ|_IOC_WRITE, 0x230d, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x230f, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_CREATE_ISO_CONTEXT", _IOC_READ|_IOC_WRITE, 0x2308, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE", _IOC_WRITE, 0x2303, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", _IOC_WRITE, 0x230e, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x2310, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_FLUSH_ISO", _IOC_WRITE, 0x2318, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER", _IOC_READ, 0x230c, 0x10 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER2", _IOC_READ|_IOC_WRITE, 0x2314, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_INFO", _IOC_READ|_IOC_WRITE, 0x2300, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_SPEED", _IOC_NONE, 0x2311, 0x00 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_INITIATE_BUS_RESET", _IOC_WRITE, 0x2305, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_QUEUE_ISO", _IOC_READ|_IOC_WRITE, 0x2309, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", _IOC_WRITE, 0x2316, 0x08 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_REMOVE_DESCRIPTOR", _IOC_WRITE, 0x2307, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", _IOC_WRITE, 0x2312, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_PHY_PACKET", _IOC_READ|_IOC_WRITE, 0x2315, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_REQUEST", _IOC_WRITE, 0x2301, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_RESPONSE", _IOC_WRITE, 0x2304, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_STREAM_PACKET", _IOC_WRITE, 0x2313, 0x28 },
+{ "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/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
+{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
+{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
+{ "linux/fs.h", "BLKDISCARD", _IOC_NONE, 0x1277, 0x00 },
+{ "linux/fs.h", "BLKDISCARDZEROES", _IOC_NONE, 0x127c, 0x00 },
+{ "linux/fs.h", "BLKFLSBUF", _IOC_NONE, 0x1261, 0x00 },
+{ "linux/fs.h", "BLKFRAGET", _IOC_NONE, 0x1265, 0x00 },
+{ "linux/fs.h", "BLKFRASET", _IOC_NONE, 0x1264, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE", _IOC_NONE, 0x1260, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE64", _IOC_READ, 0x1272, 0x04 },
+{ "linux/fs.h", "BLKIOMIN", _IOC_NONE, 0x1278, 0x00 },
+{ "linux/fs.h", "BLKIOOPT", _IOC_NONE, 0x1279, 0x00 },
+{ "linux/fs.h", "BLKPBSZGET", _IOC_NONE, 0x127b, 0x00 },
+{ "linux/fs.h", "BLKRAGET", _IOC_NONE, 0x1263, 0x00 },
+{ "linux/fs.h", "BLKRASET", _IOC_NONE, 0x1262, 0x00 },
+{ "linux/fs.h", "BLKROGET", _IOC_NONE, 0x125e, 0x00 },
+{ "linux/fs.h", "BLKROSET", _IOC_NONE, 0x125d, 0x00 },
+{ "linux/fs.h", "BLKROTATIONAL", _IOC_NONE, 0x127e, 0x00 },
+{ "linux/fs.h", "BLKRRPART", _IOC_NONE, 0x125f, 0x00 },
+{ "linux/fs.h", "BLKSECDISCARD", _IOC_NONE, 0x127d, 0x00 },
+{ "linux/fs.h", "BLKSECTGET", _IOC_NONE, 0x1267, 0x00 },
+{ "linux/fs.h", "BLKSECTSET", _IOC_NONE, 0x1266, 0x00 },
+{ "linux/fs.h", "BLKSSZGET", _IOC_NONE, 0x1268, 0x00 },
+{ "linux/fs.h", "BLKTRACESETUP", _IOC_READ|_IOC_WRITE, 0x1273, 0x48 },
+{ "linux/fs.h", "BLKTRACESTART", _IOC_NONE, 0x1274, 0x00 },
+{ "linux/fs.h", "BLKTRACESTOP", _IOC_NONE, 0x1275, 0x00 },
+{ "linux/fs.h", "BLKTRACETEARDOWN", _IOC_NONE, 0x1276, 0x00 },
+{ "linux/fs.h", "BLKZEROOUT", _IOC_NONE, 0x127f, 0x00 },
+{ "linux/fs.h", "FIBMAP", _IOC_NONE, 0x0001, 0x00 },
+{ "linux/fs.h", "FICLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/fs.h", "FICLONERANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/fs.h", "FIDEDUPERANGE", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/fs.h", "FIFREEZE", _IOC_READ|_IOC_WRITE, 0x5877, 0x04 },
+{ "linux/fs.h", "FIGETBSZ", _IOC_NONE, 0x0002, 0x00 },
+{ "linux/fs.h", "FITHAW", _IOC_READ|_IOC_WRITE, 0x5878, 0x04 },
+{ "linux/fs.h", "FITRIM", _IOC_READ|_IOC_WRITE, 0x5879, 0x18 },
+{ "linux/fs.h", "FS_IOC32_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_FIEMAP", _IOC_READ|_IOC_WRITE, 0x660b, 0x20 },
+{ "linux/fs.h", "FS_IOC_FSGETXATTR", _IOC_READ, 0x581f, 0x1c },
+{ "linux/fs.h", "FS_IOC_FSSETXATTR", _IOC_WRITE, 0x5820, 0x1c },
+{ "linux/fs.h", "FS_IOC_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_POLICY", _IOC_WRITE, 0x6615, 0x0c },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_PWSALT", _IOC_WRITE, 0x6614, 0x10 },
+{ "linux/fs.h", "FS_IOC_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
+{ "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 },
+{ "linux/fsl-diu-fb.h", "MFB_GET_PIXFMT", _IOC_READ, 0x4d08, 0x04 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_ALPHA", _IOC_WRITE, 0x4d00, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_AOID", _IOC_WRITE, 0x4d04, 0x08 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_BRIGHTNESS", _IOC_WRITE, 0x4d03, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_CHROMA_KEY", _IOC_WRITE, 0x4d01, 0x0c },
+{ "linux/fsl-diu-fb.h", "MFB_SET_GAMMA", _IOC_WRITE, 0x4d01, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_PIXFMT", _IOC_WRITE, 0x4d08, 0x04 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_DOORBELL", _IOC_READ|_IOC_WRITE, 0xaf06, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_GETPROP", _IOC_READ|_IOC_WRITE, 0xaf07, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_MEMCPY", _IOC_READ|_IOC_WRITE, 0xaf05, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_GET_STATUS", _IOC_READ|_IOC_WRITE, 0xaf02, 0x0c },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_RESTART", _IOC_READ|_IOC_WRITE, 0xaf01, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_START", _IOC_READ|_IOC_WRITE, 0xaf03, 0x10 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_STOP", _IOC_READ|_IOC_WRITE, 0xaf04, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_SETPROP", _IOC_READ|_IOC_WRITE, 0xaf08, 0x28 },
+{ "linux/fuse.h", "FUSE_DEV_IOC_CLONE", _IOC_READ, 0xe500, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_DDCB", _IOC_READ|_IOC_WRITE, 0xa532, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_RAW_DDCB", _IOC_READ|_IOC_WRITE, 0xa533, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_GET_CARD_STATE", _IOC_READ, 0xa524, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_PIN_MEM", _IOC_READ|_IOC_WRITE, 0xa528, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG16", _IOC_READ, 0xa522, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG32", _IOC_READ, 0xa520, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG64", _IOC_READ, 0xa51e, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_READ", _IOC_READ|_IOC_WRITE, 0xa551, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_UPDATE", _IOC_READ|_IOC_WRITE, 0xa550, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_UNPIN_MEM", _IOC_READ|_IOC_WRITE, 0xa529, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG16", _IOC_WRITE, 0xa523, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG32", _IOC_WRITE, 0xa521, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG64", _IOC_WRITE, 0xa51f, 0x10 },
+{ "linux/gigaset_dev.h", "GIGASET_BRKCHARS", _IOC_WRITE, 0x4702, 0x06 },
+{ "linux/gigaset_dev.h", "GIGASET_CONFIG", _IOC_READ|_IOC_WRITE, 0x4701, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_REDIR", _IOC_READ|_IOC_WRITE, 0x4700, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_VERSION", _IOC_READ|_IOC_WRITE, 0x4703, 0x10 },
+{ "linux/gpio.h", "GPIO_GET_CHIPINFO_IOCTL", _IOC_READ, 0xb401, 0x44 },
+{ "linux/gpio.h", "GPIO_GET_LINEINFO_IOCTL", _IOC_READ|_IOC_WRITE, 0xb402, 0x48 },
+{ "linux/gsmmux.h", "GSMIOC_DISABLE_NET", _IOC_NONE, 0x4703, 0x00 },
+{ "linux/gsmmux.h", "GSMIOC_ENABLE_NET", _IOC_WRITE, 0x4702, 0x34 },
+{ "linux/gsmmux.h", "GSMIOC_GETCONF", _IOC_READ, 0x4700, 0x4c },
+{ "linux/gsmmux.h", "GSMIOC_SETCONF", _IOC_WRITE, 0x4701, 0x4c },
+{ "linux/hdreg.h", "HDIO_DRIVE_CMD", 0, 0x031f, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_RESET", 0, 0x031c, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASK", 0, 0x031e, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASKFILE", 0, 0x031d, 0 },
+{ "linux/hdreg.h", "HDIO_GETGEO", 0, 0x0301, 0 },
+{ "linux/hdreg.h", "HDIO_GET_32BIT", 0, 0x0309, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ACOUSTIC", 0, 0x030f, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ADDRESS", 0, 0x0310, 0 },
+{ "linux/hdreg.h", "HDIO_GET_BUSSTATE", 0, 0x031a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_DMA", 0, 0x030b, 0 },
+{ "linux/hdreg.h", "HDIO_GET_IDENTITY", 0, 0x030d, 0 },
+{ "linux/hdreg.h", "HDIO_GET_KEEPSETTINGS", 0, 0x0308, 0 },
+{ "linux/hdreg.h", "HDIO_GET_MULTCOUNT", 0, 0x0304, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NICE", 0, 0x030c, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NOWERR", 0, 0x030a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_QDMA", 0, 0x0305, 0 },
+{ "linux/hdreg.h", "HDIO_GET_UNMASKINTR", 0, 0x0302, 0 },
+{ "linux/hdreg.h", "HDIO_GET_WCACHE", 0, 0x030e, 0 },
+{ "linux/hdreg.h", "HDIO_OBSOLETE_IDENTITY", 0, 0x0307, 0 },
+{ "linux/hdreg.h", "HDIO_SCAN_HWIF", 0, 0x0328, 0 },
+{ "linux/hdreg.h", "HDIO_SET_32BIT", 0, 0x0324, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ACOUSTIC", 0, 0x032c, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ADDRESS", 0, 0x032f, 0 },
+{ "linux/hdreg.h", "HDIO_SET_BUSSTATE", 0, 0x032d, 0 },
+{ "linux/hdreg.h", "HDIO_SET_DMA", 0, 0x0326, 0 },
+{ "linux/hdreg.h", "HDIO_SET_KEEPSETTINGS", 0, 0x0323, 0 },
+{ "linux/hdreg.h", "HDIO_SET_MULTCOUNT", 0, 0x0321, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NICE", 0, 0x0329, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NOWERR", 0, 0x0325, 0 },
+{ "linux/hdreg.h", "HDIO_SET_PIO_MODE", 0, 0x0327, 0 },
+{ "linux/hdreg.h", "HDIO_SET_QDMA", 0, 0x032e, 0 },
+{ "linux/hdreg.h", "HDIO_SET_UNMASKINTR", 0, 0x0322, 0 },
+{ "linux/hdreg.h", "HDIO_SET_WCACHE", 0, 0x032b, 0 },
+{ "linux/hdreg.h", "HDIO_SET_XFER", 0, 0x0306, 0 },
+{ "linux/hdreg.h", "HDIO_TRISTATE_HWIF", 0, 0x031b, 0 },
+{ "linux/hdreg.h", "HDIO_UNREGISTER_HWIF", 0, 0x032a, 0 },
+{ "linux/hid-roccat.h", "ROCCATIOCGREPSIZE", _IOC_READ, 0x48f1, 0x04 },
+{ "linux/hiddev.h", "HIDIOCAPPLICATION", _IOC_NONE, 0x4802, 0x00 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINDEX", _IOC_WRITE, 0x4810, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINFO", _IOC_READ|_IOC_WRITE, 0x4811, 0x10 },
+{ "linux/hiddev.h", "HIDIOCGDEVINFO", _IOC_READ, 0x4803, 0x1c },
+{ "linux/hiddev.h", "HIDIOCGFIELDINFO", _IOC_READ|_IOC_WRITE, 0x480a, 0x38 },
+{ "linux/hiddev.h", "HIDIOCGFLAG", _IOC_READ, 0x480e, 0x04 },
+{ "linux/hiddev.h", "HIDIOCGREPORT", _IOC_WRITE, 0x4807, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGREPORTINFO", _IOC_READ|_IOC_WRITE, 0x4809, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGSTRING", _IOC_READ, 0x4804, 0x104 },
+{ "linux/hiddev.h", "HIDIOCGUCODE", _IOC_READ|_IOC_WRITE, 0x480d, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGE", _IOC_READ|_IOC_WRITE, 0x480b, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGES", _IOC_READ|_IOC_WRITE, 0x4813, 0x101c },
+{ "linux/hiddev.h", "HIDIOCGVERSION", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hiddev.h", "HIDIOCINITREPORT", _IOC_NONE, 0x4805, 0x00 },
+{ "linux/hiddev.h", "HIDIOCSFLAG", _IOC_WRITE, 0x480f, 0x04 },
+{ "linux/hiddev.h", "HIDIOCSREPORT", _IOC_WRITE, 0x4808, 0x0c },
+{ "linux/hiddev.h", "HIDIOCSUSAGE", _IOC_WRITE, 0x480c, 0x18 },
+{ "linux/hiddev.h", "HIDIOCSUSAGES", _IOC_WRITE, 0x4814, 0x101c },
+{ "linux/hidraw.h", "HIDIOCGRAWINFO", _IOC_READ, 0x4803, 0x08 },
+{ "linux/hidraw.h", "HIDIOCGRDESC", _IOC_READ, 0x4802, 0x1004 },
+{ "linux/hidraw.h", "HIDIOCGRDESCSIZE", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hpet.h", "HPET_DPI", _IOC_NONE, 0x6805, 0x00 },
+{ "linux/hpet.h", "HPET_EPI", _IOC_NONE, 0x6804, 0x00 },
+{ "linux/hpet.h", "HPET_IE_OFF", _IOC_NONE, 0x6802, 0x00 },
+{ "linux/hpet.h", "HPET_IE_ON", _IOC_NONE, 0x6801, 0x00 },
+{ "linux/hpet.h", "HPET_INFO", _IOC_READ, 0x6803, 0x0c },
+{ "linux/hpet.h", "HPET_IRQFREQ", _IOC_WRITE, 0x6806, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_CONFIG_BUFS", _IOC_WRITE, 0x431f, 0x20 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_IF_VERSION", _IOC_READ, 0x431e, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_STATE", _IOC_READ, 0x4315, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_SET_WAKELINE", _IOC_WRITE, 0x4317, 0x04 },
+{ "linux/hsi/hsi_char.h", "HSC_GET_RX", _IOC_WRITE, 0x6b14, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_GET_TX", _IOC_WRITE, 0x6b16, 0x10 },
+{ "linux/hsi/hsi_char.h", "HSC_RESET", _IOC_NONE, 0x6b10, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SEND_BREAK", _IOC_NONE, 0x6b12, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_PM", _IOC_NONE, 0x6b11, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_RX", _IOC_WRITE, 0x6b13, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_SET_TX", _IOC_WRITE, 0x6b15, 0x10 },
+{ "linux/i2o-dev.h", "I2OEVTGET", _IOC_READ, 0x690b, 0x68 },
+{ "linux/i2o-dev.h", "I2OEVTREG", _IOC_WRITE, 0x690a, 0x0c },
+{ "linux/i2o-dev.h", "I2OGETIOPS", _IOC_READ, 0x6900, 0x20 },
+{ "linux/i2o-dev.h", "I2OHRTGET", _IOC_READ|_IOC_WRITE, 0x6901, 0x0c },
+{ "linux/i2o-dev.h", "I2OHTML", _IOC_READ|_IOC_WRITE, 0x6909, 0x1c },
+{ "linux/i2o-dev.h", "I2OLCTGET", _IOC_READ|_IOC_WRITE, 0x6902, 0x0c },
+{ "linux/i2o-dev.h", "I2OPARMGET", _IOC_READ|_IOC_WRITE, 0x6904, 0x18 },
+{ "linux/i2o-dev.h", "I2OPARMSET", _IOC_READ|_IOC_WRITE, 0x6903, 0x18 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU32", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OSWDEL", _IOC_READ|_IOC_WRITE, 0x6907, 0x1c },
+{ "linux/i2o-dev.h", "I2OSWDL", _IOC_READ|_IOC_WRITE, 0x6905, 0x1c },
+{ "linux/i2o-dev.h", "I2OSWUL", _IOC_READ|_IOC_WRITE, 0x6906, 0x1c },
+{ "linux/i2o-dev.h", "I2OVALIDATE", _IOC_READ, 0x6908, 0x04 },
+{ "linux/i8k.h", "I8K_BIOS_VERSION", _IOC_READ, 0x6980, 0x04 },
+{ "linux/i8k.h", "I8K_FN_STATUS", _IOC_READ, 0x6983, 0x04 },
+{ "linux/i8k.h", "I8K_GET_FAN", _IOC_READ|_IOC_WRITE, 0x6986, 0x04 },
+{ "linux/i8k.h", "I8K_GET_SPEED", _IOC_READ|_IOC_WRITE, 0x6985, 0x04 },
+{ "linux/i8k.h", "I8K_GET_TEMP", _IOC_READ, 0x6984, 0x04 },
+{ "linux/i8k.h", "I8K_MACHINE_ID", _IOC_READ, 0x6981, 0x04 },
+{ "linux/i8k.h", "I8K_POWER_STATUS", _IOC_READ, 0x6982, 0x04 },
+{ "linux/i8k.h", "I8K_SET_FAN", _IOC_READ|_IOC_WRITE, 0x6987, 0x04 },
+{ "linux/if_pppox.h", "PPPOEIOCDFWD", _IOC_NONE, 0xb101, 0x00 },
+{ "linux/if_pppox.h", "PPPOEIOCSFWD", _IOC_WRITE, 0xb100, 0x04 },
+{ "linux/if_tun.h", "TUNATTACHFILTER", _IOC_WRITE, 0x54d5, 0x08 },
+{ "linux/if_tun.h", "TUNDETACHFILTER", _IOC_WRITE, 0x54d6, 0x08 },
+{ "linux/if_tun.h", "TUNGETFEATURES", _IOC_READ, 0x54cf, 0x04 },
+{ "linux/if_tun.h", "TUNGETFILTER", _IOC_READ, 0x54db, 0x08 },
+{ "linux/if_tun.h", "TUNGETIFF", _IOC_READ, 0x54d2, 0x04 },
+{ "linux/if_tun.h", "TUNGETSNDBUF", _IOC_READ, 0x54d3, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETBE", _IOC_READ, 0x54df, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETHDRSZ", _IOC_READ, 0x54d7, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETLE", _IOC_READ, 0x54dd, 0x04 },
+{ "linux/if_tun.h", "TUNSETDEBUG", _IOC_WRITE, 0x54c9, 0x04 },
+{ "linux/if_tun.h", "TUNSETGROUP", _IOC_WRITE, 0x54ce, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFF", _IOC_WRITE, 0x54ca, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFINDEX", _IOC_WRITE, 0x54da, 0x04 },
+{ "linux/if_tun.h", "TUNSETLINK", _IOC_WRITE, 0x54cd, 0x04 },
+{ "linux/if_tun.h", "TUNSETNOCSUM", _IOC_WRITE, 0x54c8, 0x04 },
+{ "linux/if_tun.h", "TUNSETOFFLOAD", _IOC_WRITE, 0x54d0, 0x04 },
+{ "linux/if_tun.h", "TUNSETOWNER", _IOC_WRITE, 0x54cc, 0x04 },
+{ "linux/if_tun.h", "TUNSETPERSIST", _IOC_WRITE, 0x54cb, 0x04 },
+{ "linux/if_tun.h", "TUNSETQUEUE", _IOC_WRITE, 0x54d9, 0x04 },
+{ "linux/if_tun.h", "TUNSETSNDBUF", _IOC_WRITE, 0x54d4, 0x04 },
+{ "linux/if_tun.h", "TUNSETTXFILTER", _IOC_WRITE, 0x54d1, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETBE", _IOC_WRITE, 0x54de, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETHDRSZ", _IOC_WRITE, 0x54d8, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETLE", _IOC_WRITE, 0x54dc, 0x04 },
+{ "linux/iio/events.h", "IIO_GET_EVENT_FD_IOCTL", _IOC_READ, 0x6990, 0x04 },
+{ "linux/input.h", "EVIOCGEFFECTS", _IOC_READ, 0x4584, 0x04 },
+{ "linux/input.h", "EVIOCGID", _IOC_READ, 0x4502, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE", _IOC_READ, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE_V2", _IOC_READ, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCGMASK", _IOC_READ, 0x4592, 0x10 },
+{ "linux/input.h", "EVIOCGRAB", _IOC_WRITE, 0x4590, 0x04 },
+{ "linux/input.h", "EVIOCGREP", _IOC_READ, 0x4503, 0x08 },
+{ "linux/input.h", "EVIOCGVERSION", _IOC_READ, 0x4501, 0x04 },
+{ "linux/input.h", "EVIOCREVOKE", _IOC_WRITE, 0x4591, 0x04 },
+{ "linux/input.h", "EVIOCRMFF", _IOC_WRITE, 0x4581, 0x04 },
+{ "linux/input.h", "EVIOCSCLOCKID", _IOC_WRITE, 0x45a0, 0x04 },
+{ "linux/input.h", "EVIOCSFF", _IOC_WRITE, 0x4580, 0x2c },
+{ "linux/input.h", "EVIOCSKEYCODE", _IOC_WRITE, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCSKEYCODE_V2", _IOC_WRITE, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCSMASK", _IOC_WRITE, 0x4593, 0x10 },
+{ "linux/input.h", "EVIOCSREP", _IOC_WRITE, 0x4503, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_GET_MAINTENANCE_MODE_CMD", _IOC_READ, 0x691e, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_ADDRESS_CMD", _IOC_READ, 0x6912, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6919, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691b, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_LUN_CMD", _IOC_READ, 0x6914, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_TIMING_PARMS_CMD", _IOC_READ, 0x6917, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG", _IOC_READ|_IOC_WRITE, 0x690c, 0x18 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG_TRUNC", _IOC_READ|_IOC_WRITE, 0x690b, 0x18 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD", _IOC_READ, 0x690e, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691c, 0x0c },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND", _IOC_READ, 0x690d, 0x14 },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND_SETTIME", _IOC_READ, 0x6915, 0x1c },
+{ "linux/ipmi.h", "IPMICTL_SET_GETS_EVENTS_CMD", _IOC_READ, 0x6910, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MAINTENANCE_MODE_CMD", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_ADDRESS_CMD", _IOC_READ, 0x6911, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6918, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691a, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_LUN_CMD", _IOC_READ, 0x6913, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_TIMING_PARMS_CMD", _IOC_READ, 0x6916, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD", _IOC_READ, 0x690f, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691d, 0x0c },
+{ "linux/isdn.h", "IIOCDBGVAR", _IOC_NONE, 0x497f, 0x00 },
+{ "linux/isdn.h", "IIOCDRVCTL", _IOC_NONE, 0x4980, 0x00 },
+{ "linux/isdn.h", "IIOCGETCPS", _IOC_NONE, 0x4915, 0x00 },
+{ "linux/isdn.h", "IIOCGETDVR", _IOC_NONE, 0x4916, 0x00 },
+{ "linux/isdn.h", "IIOCGETMAP", _IOC_NONE, 0x4911, 0x00 },
+{ "linux/isdn.h", "IIOCGETPRF", _IOC_NONE, 0x490f, 0x00 },
+{ "linux/isdn.h", "IIOCGETSET", _IOC_NONE, 0x4908, 0x00 },
+{ "linux/isdn.h", "IIOCNETAIF", _IOC_NONE, 0x4901, 0x00 },
+{ "linux/isdn.h", "IIOCNETALN", _IOC_NONE, 0x4920, 0x00 },
+{ "linux/isdn.h", "IIOCNETANM", _IOC_NONE, 0x4905, 0x00 },
+{ "linux/isdn.h", "IIOCNETASL", _IOC_NONE, 0x4913, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIF", _IOC_NONE, 0x4902, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIL", _IOC_NONE, 0x4914, 0x00 },
+{ "linux/isdn.h", "IIOCNETDLN", _IOC_NONE, 0x4921, 0x00 },
+{ "linux/isdn.h", "IIOCNETDNM", _IOC_NONE, 0x4906, 0x00 },
+{ "linux/isdn.h", "IIOCNETDWRSET", _IOC_NONE, 0x4918, 0x00 },
+{ "linux/isdn.h", "IIOCNETGCF", _IOC_NONE, 0x4904, 0x00 },
+{ "linux/isdn.h", "IIOCNETGNM", _IOC_NONE, 0x4907, 0x00 },
+{ "linux/isdn.h", "IIOCNETGPN", _IOC_NONE, 0x4922, 0x00 },
+{ "linux/isdn.h", "IIOCNETHUP", _IOC_NONE, 0x490b, 0x00 },
+{ "linux/isdn.h", "IIOCNETLCR", _IOC_NONE, 0x4917, 0x00 },
+{ "linux/isdn.h", "IIOCNETSCF", _IOC_NONE, 0x4903, 0x00 },
+{ "linux/isdn.h", "IIOCSETBRJ", _IOC_NONE, 0x490d, 0x00 },
+{ "linux/isdn.h", "IIOCSETGST", _IOC_NONE, 0x490c, 0x00 },
+{ "linux/isdn.h", "IIOCSETMAP", _IOC_NONE, 0x4912, 0x00 },
+{ "linux/isdn.h", "IIOCSETPRF", _IOC_NONE, 0x4910, 0x00 },
+{ "linux/isdn.h", "IIOCSETSET", _IOC_NONE, 0x4909, 0x00 },
+{ "linux/isdn.h", "IIOCSETVER", _IOC_NONE, 0x490a, 0x00 },
+{ "linux/isdn.h", "IIOCSIGPRF", _IOC_NONE, 0x490e, 0x00 },
+{ "linux/isdn_ppp.h", "PPPIOCBUNDLE", _IOC_WRITE, 0x7481, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCGCALLINFO", _IOC_READ|_IOC_WRITE, 0x7480, 0x88 },
+{ "linux/isdn_ppp.h", "PPPIOCGCOMPRESSORS", _IOC_READ, 0x7486, 0x20 },
+{ "linux/isdn_ppp.h", "PPPIOCGIFNAME", _IOC_READ, 0x7488, 0x10 },
+{ "linux/isdn_ppp.h", "PPPIOCGMPFLAGS", _IOC_READ, 0x7482, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSCOMPRESSOR", _IOC_WRITE, 0x7487, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPFLAGS", _IOC_WRITE, 0x7483, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMRU", _IOC_WRITE, 0x7485, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMTU", _IOC_WRITE, 0x7484, 0x04 },
+{ "linux/ivtv.h", "IVTV_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x38 },
+{ "linux/ivtv.h", "IVTV_IOC_PASSTHROUGH_MODE", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/ivtvfb.h", "IVTVFB_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x0c },
+{ "linux/ixjuser.h", "IXJCTL_AEC_GET_LEVEL", _IOC_NONE, 0x71cd, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_START", _IOC_WRITE, 0x71cb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_STOP", _IOC_NONE, 0x71cc, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_CARDTYPE", _IOC_READ, 0x71c1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CID", _IOC_READ, 0x71d4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CIDCW", _IOC_WRITE, 0x71d9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_AGAIN", _IOC_WRITE, 0x71d2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_COEFF_SET", _IOC_WRITE, 0x71d0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_CLEAR", _IOC_NONE, 0x71e7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_READ", _IOC_READ, 0x71e6, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_IDLE", _IOC_NONE, 0x71c5, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_RESET", _IOC_NONE, 0x71c0, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_TYPE", _IOC_READ, 0x71c3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_VERSION", _IOC_READ, 0x71c4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DTMF_PRESCALE", _IOC_WRITE, 0x71e8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FILTER_CADENCE", _IOC_WRITE, 0x71d6, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_READ", _IOC_READ, 0x71e2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_WRITTEN", _IOC_READ, 0x71e3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_GET_FILTER_HIST", _IOC_WRITE, 0x71c8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_HZ", _IOC_WRITE, 0x71e0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INIT_TONE", _IOC_WRITE, 0x71c9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_START", _IOC_WRITE, 0x71fd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_STOP", _IOC_WRITE, 0x71fe, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_MIXER", _IOC_WRITE, 0x71cf, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PLAY_CID", _IOC_NONE, 0x71d7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_PORT", _IOC_WRITE, 0x71d1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_POTS_PSTN", _IOC_WRITE, 0x71d5, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PSTN_LINETEST", _IOC_NONE, 0x71d3, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_RATE", _IOC_WRITE, 0x71e1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_READ_WAIT", _IOC_READ, 0x71e4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_RXG", _IOC_WRITE, 0x71ea, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_TXG", _IOC_WRITE, 0x71eb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SERIAL", _IOC_READ, 0x71c2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER", _IOC_WRITE, 0x71c7, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER_RAW", _IOC_WRITE, 0x71dd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_LED", _IOC_WRITE, 0x71ce, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SIGCTL", _IOC_WRITE, 0x71e9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_TESTRAM", _IOC_NONE, 0x71c6, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_TONE_CADENCE", _IOC_WRITE, 0x71ca, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_VERSION", _IOC_READ, 0x71da, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_VMWI", _IOC_READ, 0x71d8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_WRITE_WAIT", _IOC_READ, 0x71e5, 0x04 },
+{ "linux/joystick.h", "JSIOCGAXES", _IOC_READ, 0x6a11, 0x01 },
+{ "linux/joystick.h", "JSIOCGAXMAP", _IOC_READ, 0x6a32, 0x40 },
+{ "linux/joystick.h", "JSIOCGBTNMAP", _IOC_READ, 0x6a34, 0x400 },
+{ "linux/joystick.h", "JSIOCGBUTTONS", _IOC_READ, 0x6a12, 0x01 },
+{ "linux/joystick.h", "JSIOCGCORR", _IOC_READ, 0x6a22, 0x24 },
+{ "linux/joystick.h", "JSIOCGVERSION", _IOC_READ, 0x6a01, 0x04 },
+{ "linux/joystick.h", "JSIOCSAXMAP", _IOC_WRITE, 0x6a31, 0x40 },
+{ "linux/joystick.h", "JSIOCSBTNMAP", _IOC_WRITE, 0x6a33, 0x400 },
+{ "linux/joystick.h", "JSIOCSCORR", _IOC_WRITE, 0x6a21, 0x24 },
+{ "linux/kcov.h", "KCOV_DISABLE", _IOC_NONE, 0x6365, 0x00 },
+{ "linux/kcov.h", "KCOV_ENABLE", _IOC_NONE, 0x6364, 0x00 },
+{ "linux/kcov.h", "KCOV_INIT_TRACE", _IOC_READ, 0x6301, 0x04 },
+{ "linux/kd.h", "GIO_CMAP", 0, 0x4B70, 0 },
+{ "linux/kd.h", "GIO_FONT", 0, 0x4B60, 0 },
+{ "linux/kd.h", "GIO_FONTX", 0, 0x4B6B, 0 },
+{ "linux/kd.h", "GIO_SCRNMAP", 0, 0x4B40, 0 },
+{ "linux/kd.h", "GIO_UNIMAP", 0, 0x4B66, 0 },
+{ "linux/kd.h", "GIO_UNISCRNMAP", 0, 0x4B69, 0 },
+{ "linux/kd.h", "KDADDIO", 0, 0x4B34, 0 },
+{ "linux/kd.h", "KDDELIO", 0, 0x4B35, 0 },
+{ "linux/kd.h", "KDDISABIO", 0, 0x4B37, 0 },
+{ "linux/kd.h", "KDENABIO", 0, 0x4B36, 0 },
+{ "linux/kd.h", "KDFONTOP", 0, 0x4B72, 0 },
+{ "linux/kd.h", "KDGETKEYCODE", 0, 0x4B4C, 0 },
+{ "linux/kd.h", "KDGETLED", 0, 0x4B31, 0 },
+{ "linux/kd.h", "KDGETMODE", 0, 0x4B3B, 0 },
+{ "linux/kd.h", "KDGKBDIACR", 0, 0x4B4A, 0 },
+{ "linux/kd.h", "KDGKBDIACRUC", 0, 0x4BFA, 0 },
+{ "linux/kd.h", "KDGKBENT", 0, 0x4B46, 0 },
+{ "linux/kd.h", "KDGKBLED", 0, 0x4B64, 0 },
+{ "linux/kd.h", "KDGKBMETA", 0, 0x4B62, 0 },
+{ "linux/kd.h", "KDGKBMODE", 0, 0x4B44, 0 },
+{ "linux/kd.h", "KDGKBSENT", 0, 0x4B48, 0 },
+{ "linux/kd.h", "KDGKBTYPE", 0, 0x4B33, 0 },
+{ "linux/kd.h", "KDKBDREP", 0, 0x4B52, 0 },
+{ "linux/kd.h", "KDMAPDISP", 0, 0x4B3C, 0 },
+{ "linux/kd.h", "KDMKTONE", 0, 0x4B30, 0 },
+{ "linux/kd.h", "KDSETKEYCODE", 0, 0x4B4D, 0 },
+{ "linux/kd.h", "KDSETLED", 0, 0x4B32, 0 },
+{ "linux/kd.h", "KDSETMODE", 0, 0x4B3A, 0 },
+{ "linux/kd.h", "KDSIGACCEPT", 0, 0x4B4E, 0 },
+{ "linux/kd.h", "KDSKBDIACR", 0, 0x4B4B, 0 },
+{ "linux/kd.h", "KDSKBDIACRUC", 0, 0x4BFB, 0 },
+{ "linux/kd.h", "KDSKBENT", 0, 0x4B47, 0 },
+{ "linux/kd.h", "KDSKBLED", 0, 0x4B65, 0 },
+{ "linux/kd.h", "KDSKBMETA", 0, 0x4B63, 0 },
+{ "linux/kd.h", "KDSKBMODE", 0, 0x4B45, 0 },
+{ "linux/kd.h", "KDSKBSENT", 0, 0x4B49, 0 },
+{ "linux/kd.h", "KDUNMAPDISP", 0, 0x4B3D, 0 },
+{ "linux/kd.h", "KIOCSOUND", 0, 0x4B2F, 0 },
+{ "linux/kd.h", "PIO_CMAP", 0, 0x4B71, 0 },
+{ "linux/kd.h", "PIO_FONT", 0, 0x4B61, 0 },
+{ "linux/kd.h", "PIO_FONTRESET", 0, 0x4B6D, 0 },
+{ "linux/kd.h", "PIO_FONTX", 0, 0x4B6C, 0 },
+{ "linux/kd.h", "PIO_SCRNMAP", 0, 0x4B41, 0 },
+{ "linux/kd.h", "PIO_UNIMAP", 0, 0x4B67, 0 },
+{ "linux/kd.h", "PIO_UNIMAPCLR", 0, 0x4B68, 0 },
+{ "linux/kd.h", "PIO_UNISCRNMAP", 0, 0x4B6A, 0 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_EVENT", _IOC_READ|_IOC_WRITE, 0x4b08, 0x20 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b02, 0x58 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_ADDRESS_WATCH", _IOC_WRITE, 0x4b0f, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_REGISTER", _IOC_WRITE, 0x4b0d, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_UNREGISTER", _IOC_WRITE, 0x4b0e, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_WAVE_CONTROL", _IOC_WRITE, 0x4b10, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_EVENT", _IOC_WRITE, 0x4b09, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b03, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_CLOCK_COUNTERS", _IOC_READ|_IOC_WRITE, 0x4b05, 0x28 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_PROCESS_APERTURES", _IOC_READ, 0x4b06, 0x190 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
+{ "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_UPDATE_QUEUE", _IOC_WRITE, 0x4b07, 0x18 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_WAIT_EVENTS", _IOC_READ|_IOC_WRITE, 0x4b0c, 0x18 },
+{ "linux/kvm.h", "KVM_ALLOCATE_RMA", _IOC_READ, 0xaea9, 0x08 },
+{ "linux/kvm.h", "KVM_ARM_PREFERRED_TARGET", _IOC_READ, 0xaeaf, 0x20 },
+{ "linux/kvm.h", "KVM_ARM_SET_DEVICE_ADDR", _IOC_WRITE, 0xaeab, 0x10 },
+{ "linux/kvm.h", "KVM_ARM_VCPU_INIT", _IOC_WRITE, 0xaeae, 0x20 },
+{ "linux/kvm.h", "KVM_ASSIGN_DEV_IRQ", _IOC_WRITE, 0xae70, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_PCI_DEVICE", _IOC_READ, 0xae69, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_INTX_MASK", _IOC_WRITE, 0xaea4, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_ENTRY", _IOC_WRITE, 0xae74, 0x10 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_NR", _IOC_WRITE, 0xae73, 0x08 },
+{ "linux/kvm.h", "KVM_CHECK_EXTENSION", _IOC_NONE, 0xae03, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_DEVICE", _IOC_READ|_IOC_WRITE, 0xaee0, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_IRQCHIP", _IOC_NONE, 0xae60, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT", _IOC_NONE, 0xae64, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT2", _IOC_WRITE, 0xae77, 0x40 },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE", _IOC_WRITE, 0xaea8, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE_64", _IOC_WRITE, 0xaea8, 0x20 },
+{ "linux/kvm.h", "KVM_CREATE_VCPU", _IOC_NONE, 0xae41, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_VM", _IOC_NONE, 0xae01, 0x00 },
+{ "linux/kvm.h", "KVM_DEASSIGN_DEV_IRQ", _IOC_WRITE, 0xae75, 0x40 },
+{ "linux/kvm.h", "KVM_DEASSIGN_PCI_DEVICE", _IOC_WRITE, 0xae72, 0x40 },
+{ "linux/kvm.h", "KVM_DIRTY_TLB", _IOC_WRITE, 0xaeaa, 0x10 },
+{ "linux/kvm.h", "KVM_ENABLE_CAP", _IOC_WRITE, 0xaea3, 0x68 },
+{ "linux/kvm.h", "KVM_GET_API_VERSION", _IOC_NONE, 0xae00, 0x00 },
+{ "linux/kvm.h", "KVM_GET_CLOCK", _IOC_READ, 0xae7c, 0x30 },
+{ "linux/kvm.h", "KVM_GET_CPUID2", _IOC_READ|_IOC_WRITE, 0xae91, 0x08 },
+{ "linux/kvm.h", "KVM_GET_DEBUGREGS", _IOC_READ, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_GET_DEVICE_ATTR", _IOC_WRITE, 0xaee2, 0x18 },
+{ "linux/kvm.h", "KVM_GET_DIRTY_LOG", _IOC_WRITE, 0xae42, 0x10 },
+{ "linux/kvm.h", "KVM_GET_EMULATED_CPUID", _IOC_READ|_IOC_WRITE, 0xae09, 0x08 },
+{ "linux/kvm.h", "KVM_GET_FPU", _IOC_READ, 0xae8c, 0x00 },
+{ "linux/kvm.h", "KVM_GET_IRQCHIP", _IOC_READ|_IOC_WRITE, 0xae62, 0x208 },
+{ "linux/kvm.h", "KVM_GET_LAPIC", _IOC_READ, 0xae8e, 0x400 },
+{ "linux/kvm.h", "KVM_GET_MP_STATE", _IOC_READ, 0xae98, 0x04 },
+{ "linux/kvm.h", "KVM_GET_MSRS", _IOC_READ|_IOC_WRITE, 0xae88, 0x08 },
+{ "linux/kvm.h", "KVM_GET_MSR_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae02, 0x04 },
+{ "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 },
+{ "linux/kvm.h", "KVM_GET_PIT2", _IOC_READ, 0xae9f, 0x70 },
+{ "linux/kvm.h", "KVM_GET_REGS", _IOC_READ, 0xae81, 0x98 },
+{ "linux/kvm.h", "KVM_GET_REG_LIST", _IOC_READ|_IOC_WRITE, 0xaeb0, 0x08 },
+{ "linux/kvm.h", "KVM_GET_SREGS", _IOC_READ, 0xae83, 0x00 },
+{ "linux/kvm.h", "KVM_GET_SUPPORTED_CPUID", _IOC_READ|_IOC_WRITE, 0xae05, 0x08 },
+{ "linux/kvm.h", "KVM_GET_TSC_KHZ", _IOC_NONE, 0xaea3, 0x00 },
+{ "linux/kvm.h", "KVM_GET_VCPU_EVENTS", _IOC_READ, 0xae9f, 0x40 },
+{ "linux/kvm.h", "KVM_GET_VCPU_MMAP_SIZE", _IOC_NONE, 0xae04, 0x00 },
+{ "linux/kvm.h", "KVM_GET_XCRS", _IOC_READ, 0xaea6, 0x188 },
+{ "linux/kvm.h", "KVM_GET_XSAVE", _IOC_READ, 0xaea4, 0x1000 },
+{ "linux/kvm.h", "KVM_HAS_DEVICE_ATTR", _IOC_WRITE, 0xaee3, 0x18 },
+{ "linux/kvm.h", "KVM_INTERRUPT", _IOC_WRITE, 0xae86, 0x04 },
+{ "linux/kvm.h", "KVM_IOEVENTFD", _IOC_WRITE, 0xae79, 0x40 },
+{ "linux/kvm.h", "KVM_IRQFD", _IOC_WRITE, 0xae76, 0x20 },
+{ "linux/kvm.h", "KVM_IRQ_LINE", _IOC_WRITE, 0xae61, 0x08 },
+{ "linux/kvm.h", "KVM_IRQ_LINE_STATUS", _IOC_READ|_IOC_WRITE, 0xae67, 0x08 },
+{ "linux/kvm.h", "KVM_KVMCLOCK_CTRL", _IOC_NONE, 0xaead, 0x00 },
+{ "linux/kvm.h", "KVM_NMI", _IOC_NONE, 0xae9a, 0x00 },
+{ "linux/kvm.h", "KVM_PPC_ALLOCATE_HTAB", _IOC_READ|_IOC_WRITE, 0xaea7, 0x04 },
+{ "linux/kvm.h", "KVM_PPC_GET_HTAB_FD", _IOC_WRITE, 0xaeaa, 0x20 },
+{ "linux/kvm.h", "KVM_PPC_GET_PVINFO", _IOC_WRITE, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_PPC_GET_SMMU_INFO", _IOC_READ, 0xaea6, 0x250 },
+{ "linux/kvm.h", "KVM_PPC_RTAS_DEFINE_TOKEN", _IOC_WRITE, 0xaeac, 0x80 },
+{ "linux/kvm.h", "KVM_REGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae67, 0x10 },
+{ "linux/kvm.h", "KVM_REINJECT_CONTROL", _IOC_NONE, 0xae71, 0x00 },
+{ "linux/kvm.h", "KVM_RUN", _IOC_NONE, 0xae80, 0x00 },
+{ "linux/kvm.h", "KVM_S390_ENABLE_SIE", _IOC_NONE, 0xae06, 0x00 },
+{ "linux/kvm.h", "KVM_S390_GET_IRQ_STATE", _IOC_WRITE, 0xaeb6, 0x20 },
+{ "linux/kvm.h", "KVM_S390_GET_SKEYS", _IOC_WRITE, 0xaeb2, 0x40 },
+{ "linux/kvm.h", "KVM_S390_INITIAL_RESET", _IOC_NONE, 0xae97, 0x00 },
+{ "linux/kvm.h", "KVM_S390_INTERRUPT", _IOC_WRITE, 0xae94, 0x10 },
+{ "linux/kvm.h", "KVM_S390_IRQ", _IOC_WRITE, 0xaeb4, 0x48 },
+{ "linux/kvm.h", "KVM_S390_MEM_OP", _IOC_WRITE, 0xaeb1, 0x40 },
+{ "linux/kvm.h", "KVM_S390_SET_INITIAL_PSW", _IOC_WRITE, 0xae96, 0x10 },
+{ "linux/kvm.h", "KVM_S390_SET_IRQ_STATE", _IOC_WRITE, 0xaeb5, 0x20 },
+{ "linux/kvm.h", "KVM_S390_SET_SKEYS", _IOC_WRITE, 0xaeb3, 0x40 },
+{ "linux/kvm.h", "KVM_S390_STORE_STATUS", _IOC_WRITE, 0xae95, 0x04 },
+{ "linux/kvm.h", "KVM_S390_UCAS_MAP", _IOC_WRITE, 0xae50, 0x18 },
+{ "linux/kvm.h", "KVM_S390_UCAS_UNMAP", _IOC_WRITE, 0xae51, 0x18 },
+{ "linux/kvm.h", "KVM_S390_VCPU_FAULT", _IOC_WRITE, 0xae52, 0x04 },
+{ "linux/kvm.h", "KVM_SET_BOOT_CPU_ID", _IOC_NONE, 0xae78, 0x00 },
+{ "linux/kvm.h", "KVM_SET_CLOCK", _IOC_WRITE, 0xae7b, 0x30 },
+{ "linux/kvm.h", "KVM_SET_CPUID", _IOC_WRITE, 0xae8a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_CPUID2", _IOC_WRITE, 0xae90, 0x08 },
+{ "linux/kvm.h", "KVM_SET_DEBUGREGS", _IOC_WRITE, 0xaea2, 0x80 },
+{ "linux/kvm.h", "KVM_SET_DEVICE_ATTR", _IOC_WRITE, 0xaee1, 0x18 },
+{ "linux/kvm.h", "KVM_SET_FPU", _IOC_WRITE, 0xae8d, 0x00 },
+{ "linux/kvm.h", "KVM_SET_GSI_ROUTING", _IOC_WRITE, 0xae6a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_GUEST_DEBUG", _IOC_WRITE, 0xae9b, 0x08 },
+{ "linux/kvm.h", "KVM_SET_IDENTITY_MAP_ADDR", _IOC_WRITE, 0xae48, 0x08 },
+{ "linux/kvm.h", "KVM_SET_IRQCHIP", _IOC_READ, 0xae63, 0x208 },
+{ "linux/kvm.h", "KVM_SET_LAPIC", _IOC_WRITE, 0xae8f, 0x400 },
+{ "linux/kvm.h", "KVM_SET_MEMORY_ALIAS", _IOC_WRITE, 0xae43, 0x20 },
+{ "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_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 },
+{ "linux/kvm.h", "KVM_SET_PIT2", _IOC_WRITE, 0xaea0, 0x70 },
+{ "linux/kvm.h", "KVM_SET_REGS", _IOC_WRITE, 0xae82, 0x98 },
+{ "linux/kvm.h", "KVM_SET_SIGNAL_MASK", _IOC_WRITE, 0xae8b, 0x04 },
+{ "linux/kvm.h", "KVM_SET_SREGS", _IOC_WRITE, 0xae84, 0x00 },
+{ "linux/kvm.h", "KVM_SET_TSC_KHZ", _IOC_NONE, 0xaea2, 0x00 },
+{ "linux/kvm.h", "KVM_SET_TSS_ADDR", _IOC_NONE, 0xae47, 0x00 },
+{ "linux/kvm.h", "KVM_SET_USER_MEMORY_REGION", _IOC_WRITE, 0xae46, 0x20 },
+{ "linux/kvm.h", "KVM_SET_VAPIC_ADDR", _IOC_WRITE, 0xae93, 0x08 },
+{ "linux/kvm.h", "KVM_SET_VCPU_EVENTS", _IOC_WRITE, 0xaea0, 0x40 },
+{ "linux/kvm.h", "KVM_SET_XCRS", _IOC_WRITE, 0xaea7, 0x188 },
+{ "linux/kvm.h", "KVM_SET_XSAVE", _IOC_WRITE, 0xaea5, 0x1000 },
+{ "linux/kvm.h", "KVM_SIGNAL_MSI", _IOC_WRITE, 0xaea5, 0x20 },
+{ "linux/kvm.h", "KVM_SMI", _IOC_NONE, 0xaeb7, 0x00 },
+{ "linux/kvm.h", "KVM_TPR_ACCESS_REPORTING", _IOC_READ|_IOC_WRITE, 0xae92, 0x28 },
+{ "linux/kvm.h", "KVM_TRANSLATE", _IOC_READ|_IOC_WRITE, 0xae85, 0x18 },
+{ "linux/kvm.h", "KVM_UNREGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae68, 0x10 },
+{ "linux/kvm.h", "KVM_X86_GET_MCE_CAP_SUPPORTED", _IOC_READ, 0xae9d, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SETUP_MCE", _IOC_WRITE, 0xae9c, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SET_MCE", _IOC_WRITE, 0xae9e, 0x40 },
+{ "linux/kvm.h", "KVM_XEN_HVM_CONFIG", _IOC_WRITE, 0xae7a, 0x38 },
+{ "linux/lightnvm.h", "NVM_DEV_CREATE", _IOC_WRITE, 0x4c22, 0x80 },
+{ "linux/lightnvm.h", "NVM_DEV_FACTORY", _IOC_WRITE, 0x4c25, 0x24 },
+{ "linux/lightnvm.h", "NVM_DEV_INIT", _IOC_WRITE, 0x4c24, 0x2c },
+{ "linux/lightnvm.h", "NVM_DEV_REMOVE", _IOC_WRITE, 0x4c23, 0x24 },
+{ "linux/lightnvm.h", "NVM_GET_DEVICES", _IOC_READ, 0x4c21, 0x1000 },
+{ "linux/lightnvm.h", "NVM_INFO", _IOC_READ|_IOC_WRITE, 0x4c20, 0x1000 },
+{ "linux/lirc.h", "LIRC_GET_FEATURES", _IOC_READ, 0x6900, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_LENGTH", _IOC_READ, 0x690f, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_PULSE", _IOC_READ, 0x690b, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_SPACE", _IOC_READ, 0x690d, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_TIMEOUT", _IOC_READ, 0x6909, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_PULSE", _IOC_READ, 0x690a, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_SPACE", _IOC_READ, 0x690c, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_TIMEOUT", _IOC_READ, 0x6908, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_CARRIER", _IOC_READ, 0x6904, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_DUTY_CYCLE", _IOC_READ, 0x6906, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_MODE", _IOC_READ, 0x6902, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_RESOLUTION", _IOC_READ, 0x6907, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_CARRIER", _IOC_READ, 0x6903, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_DUTY_CYCLE", _IOC_READ, 0x6905, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_MODE", _IOC_READ, 0x6901, 0x04 },
+{ "linux/lirc.h", "LIRC_NOTIFY_DECODE", _IOC_NONE, 0x6920, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_END", _IOC_NONE, 0x6922, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_START", _IOC_NONE, 0x6921, 0x00 },
+{ "linux/lirc.h", "LIRC_SET_MEASURE_CARRIER_MODE", _IOC_WRITE, 0x691d, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER", _IOC_WRITE, 0x6914, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER_RANGE", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE", _IOC_WRITE, 0x6916, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE_RANGE", _IOC_WRITE, 0x691e, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER", _IOC_WRITE, 0x691c, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_PULSE", _IOC_WRITE, 0x691a, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_SPACE", _IOC_WRITE, 0x691b, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_MODE", _IOC_WRITE, 0x6912, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT", _IOC_WRITE, 0x6918, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT_REPORTS", _IOC_WRITE, 0x6919, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_CARRIER", _IOC_WRITE, 0x6913, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_DUTY_CYCLE", _IOC_WRITE, 0x6915, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_MODE", _IOC_WRITE, 0x6911, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_TRANSMITTER_MASK", _IOC_WRITE, 0x6917, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_WIDEBAND_RECEIVER", _IOC_WRITE, 0x6923, 0x04 },
+{ "linux/loop.h", "LOOP_CHANGE_FD", 0, 0x4C06, 0 },
+{ "linux/loop.h", "LOOP_CLR_FD", 0, 0x4C01, 0 },
+{ "linux/loop.h", "LOOP_CTL_ADD", 0, 0x4C80, 0 },
+{ "linux/loop.h", "LOOP_CTL_GET_FREE", 0, 0x4C82, 0 },
+{ "linux/loop.h", "LOOP_CTL_REMOVE", 0, 0x4C81, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS", 0, 0x4C03, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS64", 0, 0x4C05, 0 },
+{ "linux/loop.h", "LOOP_SET_CAPACITY", 0, 0x4C07, 0 },
+{ "linux/loop.h", "LOOP_SET_DIRECT_IO", 0, 0x4C08, 0 },
+{ "linux/loop.h", "LOOP_SET_FD", 0, 0x4C00, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS", 0, 0x4C02, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS64", 0, 0x4C04, 0 },
+{ "linux/mISDNif.h", "IMADDTIMER", _IOC_READ, 0x4940, 0x04 },
+{ "linux/mISDNif.h", "IMCLEAR_L2", _IOC_READ, 0x4946, 0x04 },
+{ "linux/mISDNif.h", "IMCTRLREQ", _IOC_READ, 0x4945, 0x04 },
+{ "linux/mISDNif.h", "IMDELTIMER", _IOC_READ, 0x4941, 0x04 },
+{ "linux/mISDNif.h", "IMGETCOUNT", _IOC_READ, 0x4943, 0x04 },
+{ "linux/mISDNif.h", "IMGETDEVINFO", _IOC_READ, 0x4944, 0x04 },
+{ "linux/mISDNif.h", "IMGETVERSION", _IOC_READ, 0x4942, 0x04 },
+{ "linux/mISDNif.h", "IMHOLD_L1", _IOC_READ, 0x4948, 0x04 },
+{ "linux/mISDNif.h", "IMSETDEVNAME", _IOC_READ, 0x4947, 0x18 },
+{ "linux/matroxfb.h", "MATROXFB_GET_ALL_OUTPUTS", _IOC_READ, 0x6efb, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_AVAILABLE_OUTPUTS", _IOC_READ, 0x6ef9, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_CONNECTION", _IOC_READ, 0x6ef8, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_MODE", _IOC_READ|_IOC_WRITE, 0x6efa, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_CONNECTION", _IOC_WRITE, 0x6ef8, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_MODE", _IOC_WRITE, 0x6efa, 0x04 },
+{ "linux/media.h", "MEDIA_IOC_DEVICE_INFO", _IOC_READ|_IOC_WRITE, 0x7c00, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_ENTITIES", _IOC_READ|_IOC_WRITE, 0x7c01, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_LINKS", _IOC_READ|_IOC_WRITE, 0x7c02, 0x1c },
+{ "linux/media.h", "MEDIA_IOC_G_TOPOLOGY", _IOC_READ|_IOC_WRITE, 0x7c04, 0x48 },
+{ "linux/media.h", "MEDIA_IOC_SETUP_LINK", _IOC_READ|_IOC_WRITE, 0x7c03, 0x34 },
+{ "linux/mei.h", "IOCTL_MEI_CONNECT_CLIENT", _IOC_READ|_IOC_WRITE, 0x4801, 0x10 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_GET", _IOC_READ, 0x4803, 0x04 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_SET", _IOC_WRITE, 0x4802, 0x04 },
+{ "linux/meye.h", "MEYEIOC_G_PARAMS", _IOC_READ, 0x76c0, 0x06 },
+{ "linux/meye.h", "MEYEIOC_QBUF_CAPT", _IOC_WRITE, 0x76c2, 0x04 },
+{ "linux/meye.h", "MEYEIOC_STILLCAPT", _IOC_NONE, 0x76c4, 0x00 },
+{ "linux/meye.h", "MEYEIOC_STILLJCAPT", _IOC_READ, 0x76c5, 0x04 },
+{ "linux/meye.h", "MEYEIOC_SYNC", _IOC_READ|_IOC_WRITE, 0x76c3, 0x04 },
+{ "linux/meye.h", "MEYEIOC_S_PARAMS", _IOC_WRITE, 0x76c1, 0x06 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_ADD_DEVICE", _IOC_READ|_IOC_WRITE, 0x7301, 0x04 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_CONFIG_CHANGE", _IOC_READ|_IOC_WRITE, 0x7305, 0x04 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_COPY_DESC", _IOC_READ|_IOC_WRITE, 0x7302, 0x04 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_CMD", _IOC_READ|_IOC_WRITE, 0xb300, 0x48 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_MULTI_CMD", _IOC_READ|_IOC_WRITE, 0xb301, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_GETBITS", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETCOUNTER", _IOC_READ, 0x6d09, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_GETFREQ", _IOC_READ, 0x6d02, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_GETOFFSET", _IOC_NONE, 0x6d00, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETRES", _IOC_READ, 0x6d01, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_MMAPAVAIL", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_ATTRIBUTES", _IOC_READ, 0x7210, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_VOLUME_ID", _IOC_READ, 0x7213, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_SET_ATTRIBUTES", _IOC_WRITE, 0x7211, 0x04 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_BOTH", _IOC_READ, 0x7201, 0x218 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_SHORT", _IOC_READ, 0x7202, 0x218 },
+{ "linux/mtio.h", "MTIOCGET", _IOC_READ, 0x6d02, 0x1c },
+{ "linux/mtio.h", "MTIOCPOS", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/mtio.h", "MTIOCTOP", _IOC_WRITE, 0x6d01, 0x08 },
+{ "linux/nbd.h", "NBD_CLEAR_QUE", _IOC_NONE, 0xab05, 0x00 },
+{ "linux/nbd.h", "NBD_CLEAR_SOCK", _IOC_NONE, 0xab04, 0x00 },
+{ "linux/nbd.h", "NBD_DISCONNECT", _IOC_NONE, 0xab08, 0x00 },
+{ "linux/nbd.h", "NBD_DO_IT", _IOC_NONE, 0xab03, 0x00 },
+{ "linux/nbd.h", "NBD_PRINT_DEBUG", _IOC_NONE, 0xab06, 0x00 },
+{ "linux/nbd.h", "NBD_SET_BLKSIZE", _IOC_NONE, 0xab01, 0x00 },
+{ "linux/nbd.h", "NBD_SET_FLAGS", _IOC_NONE, 0xab0a, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE", _IOC_NONE, 0xab02, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE_BLOCKS", _IOC_NONE, 0xab07, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SOCK", _IOC_NONE, 0xab00, 0x00 },
+{ "linux/nbd.h", "NBD_SET_TIMEOUT", _IOC_NONE, 0xab09, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_CONN_LOGGED_IN", _IOC_NONE, 0x6e03, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETCHARSETS", _IOC_READ|_IOC_WRITE, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_GETDENTRYTTL", _IOC_WRITE, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID", _IOC_WRITE, 0x6e02, 0x02 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID2", _IOC_WRITE, 0x6e02, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETOBJECTNAME", _IOC_READ|_IOC_WRITE, 0x6e09, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GETPRIVATEDATA", _IOC_READ|_IOC_WRITE, 0x6e0a, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETROOT", _IOC_WRITE, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO", _IOC_READ|_IOC_WRITE, 0x6e04, 0x28 },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO_V2", _IOC_READ|_IOC_WRITE, 0x6e04, 0x24 },
+{ "linux/ncp_fs.h", "NCP_IOC_LOCKUNLOCK", _IOC_READ, 0x6e07, 0x14 },
+{ "linux/ncp_fs.h", "NCP_IOC_NCPREQUEST", _IOC_READ, 0x6e01, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SETCHARSETS", _IOC_READ, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_SETDENTRYTTL", _IOC_READ, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETOBJECTNAME", _IOC_READ, 0x6e09, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SETPRIVATEDATA", _IOC_READ, 0x6e0a, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETROOT", _IOC_READ, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SET_SIGN_WANTED", _IOC_WRITE, 0x6e06, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_INIT", _IOC_READ, 0x6e05, 0x18 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_WANTED", _IOC_READ, 0x6e06, 0x04 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_CAP", _IOC_READ|_IOC_WRITE, 0x4e01, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_START", _IOC_READ|_IOC_WRITE, 0x4e02, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_STATUS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x30 },
+{ "linux/ndctl.h", "ND_IOCTL_CALL", _IOC_READ|_IOC_WRITE, 0x4e0a, 0x40 },
+{ "linux/ndctl.h", "ND_IOCTL_CLEAR_ERROR", _IOC_READ|_IOC_WRITE, 0x4e04, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_DIMM_FLAGS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e05, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_SIZE", _IOC_READ|_IOC_WRITE, 0x4e04, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_SET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e06, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART", _IOC_READ|_IOC_WRITE, 0x4e01, 0x84 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART_THRESHOLD", _IOC_READ|_IOC_WRITE, 0x4e02, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_VENDOR", _IOC_READ|_IOC_WRITE, 0x4e09, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CHANGE_CPMODE", _IOC_WRITE, 0x6e80, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CLEAN_SEGMENTS", _IOC_WRITE, 0x6e88, 0x78 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_DELETE_CHECKPOINT", _IOC_WRITE, 0x6e81, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_BDESCS", _IOC_READ|_IOC_WRITE, 0x6e87, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPINFO", _IOC_READ, 0x6e82, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPSTAT", _IOC_READ, 0x6e83, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUINFO", _IOC_READ, 0x6e84, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUSTAT", _IOC_READ, 0x6e85, 0x30 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_VINFO", _IOC_READ|_IOC_WRITE, 0x6e86, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_RESIZE", _IOC_WRITE, 0x6e8b, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_ALLOC_RANGE", _IOC_WRITE, 0x6e8c, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_SUINFO", _IOC_WRITE, 0x6e8d, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SYNC", _IOC_READ, 0x6e8a, 0x08 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ADMIN_CMD", _IOC_READ|_IOC_WRITE, 0x4e41, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ID", _IOC_NONE, 0x4e40, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_IO_CMD", _IOC_READ|_IOC_WRITE, 0x4e43, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESCAN", _IOC_NONE, 0x4e46, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESET", _IOC_NONE, 0x4e44, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBMIT_IO", _IOC_WRITE, 0x4e42, 0x30 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBSYS_RESET", _IOC_NONE, 0x4e45, 0x00 },
+{ "linux/nvram.h", "NVRAM_INIT", _IOC_NONE, 0x7040, 0x00 },
+{ "linux/nvram.h", "NVRAM_SETCKS", _IOC_NONE, 0x7041, 0x00 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AEWB_CFG", _IOC_READ|_IOC_WRITE, 0x56c3, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AF_CFG", _IOC_READ|_IOC_WRITE, 0x56c5, 0x4c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_CCDC_CFG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_HIST_CFG", _IOC_READ|_IOC_WRITE, 0x56c4, 0x30 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_PRV_CFG", _IOC_READ|_IOC_WRITE, 0x56c2, 0x3c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_EN", _IOC_READ|_IOC_WRITE, 0x56c7, 0x04 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_REQ", _IOC_READ|_IOC_WRITE, 0x56c6, 0x18 },
+{ "linux/omapfb.h", "OMAPFB_CTRL_TEST", _IOC_WRITE, 0x4f2e, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_CAPS", _IOC_READ, 0x4f2a, 0x0c },
+{ "linux/omapfb.h", "OMAPFB_GET_COLOR_KEY", _IOC_WRITE, 0x4f33, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_GET_DISPLAY_INFO", _IOC_READ, 0x4f3f, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_GET_OVERLAY_COLORMODE", _IOC_READ, 0x4f3b, 0x3c },
+{ "linux/omapfb.h", "OMAPFB_GET_UPDATE_MODE", _IOC_WRITE, 0x4f2b, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_VRAM_INFO", _IOC_READ, 0x4f3d, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_LCD_TEST", _IOC_WRITE, 0x4f2d, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_MEMORY_READ", _IOC_READ, 0x4f3a, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_MIRROR", _IOC_WRITE, 0x4f1f, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_MEM", _IOC_WRITE, 0x4f38, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_PLANE", _IOC_WRITE, 0x4f35, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_MEM", _IOC_WRITE, 0x4f37, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_PLANE", _IOC_WRITE, 0x4f34, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SET_COLOR_KEY", _IOC_WRITE, 0x4f32, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_SET_TEARSYNC", _IOC_WRITE, 0x4f3e, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SET_UPDATE_MODE", _IOC_WRITE, 0x4f28, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_SYNC_GFX", _IOC_NONE, 0x4f25, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW", _IOC_WRITE, 0x4f36, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW_OLD", _IOC_WRITE, 0x4f2f, 0x14 },
+{ "linux/omapfb.h", "OMAPFB_VSYNC", _IOC_NONE, 0x4f26, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORGO", _IOC_NONE, 0x4f3c, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ID", _IOC_READ, 0x2407, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PAUSE_OUTPUT", _IOC_WRITE, 0x2409, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PERIOD", _IOC_WRITE, 0x2404, 0x08 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_REFRESH", _IOC_NONE, 0x2402, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_RESET", _IOC_NONE, 0x2403, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_BPF", _IOC_WRITE, 0x2408, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_FILTER", _IOC_WRITE, 0x2406, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_OUTPUT", _IOC_NONE, 0x2405, 0x00 },
+{ "linux/phantom.h", "PHN_GETREG", _IOC_READ|_IOC_WRITE, 0x7005, 0x08 },
+{ "linux/phantom.h", "PHN_GETREGS", _IOC_READ|_IOC_WRITE, 0x7007, 0x28 },
+{ "linux/phantom.h", "PHN_GET_REG", _IOC_READ|_IOC_WRITE, 0x7000, 0x04 },
+{ "linux/phantom.h", "PHN_GET_REGS", _IOC_READ|_IOC_WRITE, 0x7002, 0x04 },
+{ "linux/phantom.h", "PHN_NOT_OH", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/phantom.h", "PHN_SETREG", _IOC_WRITE, 0x7006, 0x08 },
+{ "linux/phantom.h", "PHN_SETREGS", _IOC_WRITE, 0x7008, 0x28 },
+{ "linux/phantom.h", "PHN_SET_REG", _IOC_WRITE, 0x7001, 0x04 },
+{ "linux/phantom.h", "PHN_SET_REGS", _IOC_WRITE, 0x7003, 0x04 },
+{ "linux/pktcdvd.h", "PACKET_CTRL_CMD", _IOC_READ|_IOC_WRITE, 0x5801, 0x18 },
+{ "linux/platform_data/media/si4713.h", "SI4713_IOC_MEASURE_RNL", _IOC_READ|_IOC_WRITE, 0x56c0, 0x1c },
+{ "linux/pmu.h", "PMU_IOC_CAN_SLEEP", _IOC_READ, 0x4205, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GET_BACKLIGHT", _IOC_READ, 0x4201, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GET_MODEL", _IOC_READ, 0x4203, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GRAB_BACKLIGHT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_HAS_ADB", _IOC_READ, 0x4204, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_SET_BACKLIGHT", _IOC_WRITE, 0x4202, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_SLEEP", _IOC_NONE, 0x4200, 0x00 },
+{ "linux/ppdev.h", "PPCLAIM", _IOC_NONE, 0x708b, 0x00 },
+{ "linux/ppdev.h", "PPCLRIRQ", _IOC_READ, 0x7093, 0x04 },
+{ "linux/ppdev.h", "PPDATADIR", _IOC_WRITE, 0x7090, 0x04 },
+{ "linux/ppdev.h", "PPEXCL", _IOC_NONE, 0x708f, 0x00 },
+{ "linux/ppdev.h", "PPFCONTROL", _IOC_WRITE, 0x708e, 0x02 },
+{ "linux/ppdev.h", "PPGETFLAGS", _IOC_READ, 0x709a, 0x04 },
+{ "linux/ppdev.h", "PPGETMODE", _IOC_READ, 0x7098, 0x04 },
+{ "linux/ppdev.h", "PPGETMODES", _IOC_READ, 0x7097, 0x04 },
+{ "linux/ppdev.h", "PPGETPHASE", _IOC_READ, 0x7099, 0x04 },
+{ "linux/ppdev.h", "PPGETTIME", _IOC_READ, 0x7095, 0x08 },
+{ "linux/ppdev.h", "PPNEGOT", _IOC_WRITE, 0x7091, 0x04 },
+{ "linux/ppdev.h", "PPRCONTROL", _IOC_READ, 0x7083, 0x01 },
+{ "linux/ppdev.h", "PPRDATA", _IOC_READ, 0x7085, 0x01 },
+{ "linux/ppdev.h", "PPRELEASE", _IOC_NONE, 0x708c, 0x00 },
+{ "linux/ppdev.h", "PPRSTATUS", _IOC_READ, 0x7081, 0x01 },
+{ "linux/ppdev.h", "PPSETFLAGS", _IOC_WRITE, 0x709b, 0x04 },
+{ "linux/ppdev.h", "PPSETMODE", _IOC_WRITE, 0x7080, 0x04 },
+{ "linux/ppdev.h", "PPSETPHASE", _IOC_WRITE, 0x7094, 0x04 },
+{ "linux/ppdev.h", "PPSETTIME", _IOC_WRITE, 0x7096, 0x08 },
+{ "linux/ppdev.h", "PPWCONTROL", _IOC_WRITE, 0x7084, 0x01 },
+{ "linux/ppdev.h", "PPWCTLONIRQ", _IOC_WRITE, 0x7092, 0x01 },
+{ "linux/ppdev.h", "PPWDATA", _IOC_WRITE, 0x7086, 0x01 },
+{ "linux/ppdev.h", "PPYIELD", _IOC_NONE, 0x708d, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTACH", _IOC_WRITE, 0x743d, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTCHAN", _IOC_WRITE, 0x7438, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCCONNECT", _IOC_WRITE, 0x743a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDETACH", _IOC_WRITE, 0x743c, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDISCONN", _IOC_NONE, 0x7439, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCGASYNCMAP", _IOC_READ, 0x7458, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGCHAN", _IOC_READ, 0x7437, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGDEBUG", _IOC_READ, 0x7441, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGFLAGS", _IOC_READ, 0x745a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGIDLE", _IOC_READ, 0x743f, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCGL2TPSTATS", _IOC_READ, 0x7436, 0x48 },
+{ "linux/ppp-ioctl.h", "PPPIOCGMRU", _IOC_READ, 0x7453, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGNPMODE", _IOC_READ|_IOC_WRITE, 0x744c, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCGRASYNCMAP", _IOC_READ, 0x7455, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGUNIT", _IOC_READ, 0x7456, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGXASYNCMAP", _IOC_READ, 0x7450, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCNEWUNIT", _IOC_READ|_IOC_WRITE, 0x743e, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSACTIVE", _IOC_WRITE, 0x7446, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSASYNCMAP", _IOC_WRITE, 0x7457, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSCOMPRESS", _IOC_WRITE, 0x744d, 0x0c },
+{ "linux/ppp-ioctl.h", "PPPIOCSDEBUG", _IOC_WRITE, 0x7440, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSFLAGS", _IOC_WRITE, 0x7459, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMAXCID", _IOC_WRITE, 0x7451, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRRU", _IOC_WRITE, 0x743b, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRU", _IOC_WRITE, 0x7452, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSNPMODE", _IOC_WRITE, 0x744b, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSPASS", _IOC_WRITE, 0x7447, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSRASYNCMAP", _IOC_WRITE, 0x7454, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSXASYNCMAP", _IOC_WRITE, 0x744f, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCXFERUNIT", _IOC_NONE, 0x744e, 0x00 },
+{ "linux/pps.h", "PPS_FETCH", _IOC_READ|_IOC_WRITE, 0x70a4, 0x04 },
+{ "linux/pps.h", "PPS_GETCAP", _IOC_READ, 0x70a3, 0x04 },
+{ "linux/pps.h", "PPS_GETPARAMS", _IOC_READ, 0x70a1, 0x04 },
+{ "linux/pps.h", "PPS_KC_BIND", _IOC_WRITE, 0x70a5, 0x04 },
+{ "linux/pps.h", "PPS_SETPARAMS", _IOC_WRITE, 0x70a2, 0x04 },
+{ "linux/pr.h", "IOC_PR_CLEAR", _IOC_WRITE, 0x70cd, 0x10 },
+{ "linux/pr.h", "IOC_PR_PREEMPT", _IOC_WRITE, 0x70cb, 0x18 },
+{ "linux/pr.h", "IOC_PR_PREEMPT_ABORT", _IOC_WRITE, 0x70cc, 0x18 },
+{ "linux/pr.h", "IOC_PR_REGISTER", _IOC_WRITE, 0x70c8, 0x18 },
+{ "linux/pr.h", "IOC_PR_RELEASE", _IOC_WRITE, 0x70ca, 0x10 },
+{ "linux/pr.h", "IOC_PR_RESERVE", _IOC_WRITE, 0x70c9, 0x10 },
+{ "linux/ptp_clock.h", "PTP_CLOCK_GETCAPS", _IOC_READ, 0x3d01, 0x50 },
+{ "linux/ptp_clock.h", "PTP_ENABLE_PPS", _IOC_WRITE, 0x3d04, 0x04 },
+{ "linux/ptp_clock.h", "PTP_EXTTS_REQUEST", _IOC_WRITE, 0x3d02, 0x10 },
+{ "linux/ptp_clock.h", "PTP_PEROUT_REQUEST", _IOC_WRITE, 0x3d03, 0x38 },
+{ "linux/ptp_clock.h", "PTP_PIN_GETFUNC", _IOC_READ|_IOC_WRITE, 0x3d06, 0x60 },
+{ "linux/ptp_clock.h", "PTP_PIN_SETFUNC", _IOC_WRITE, 0x3d07, 0x60 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET", _IOC_WRITE, 0x3d05, 0x340 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET_PRECISE", _IOC_READ|_IOC_WRITE, 0x3d08, 0x40 },
+{ "linux/radeonfb.h", "FBIO_RADEON_GET_MIRROR", _IOC_READ, 0x4003, 0x04 },
+{ "linux/radeonfb.h", "FBIO_RADEON_SET_MIRROR", _IOC_WRITE, 0x4004, 0x04 },
+{ "linux/raid/md_u.h", "ADD_NEW_DISK", _IOC_WRITE, 0x0921, 0x14 },
+{ "linux/raid/md_u.h", "CLEAR_ARRAY", _IOC_NONE, 0x0920, 0x00 },
+{ "linux/raid/md_u.h", "CLUSTERED_DISK_NACK", _IOC_NONE, 0x0935, 0x00 },
+{ "linux/raid/md_u.h", "GET_ARRAY_INFO", _IOC_READ, 0x0911, 0x48 },
+{ "linux/raid/md_u.h", "GET_BITMAP_FILE", _IOC_READ, 0x0915, 0x1000 },
+{ "linux/raid/md_u.h", "GET_DISK_INFO", _IOC_READ, 0x0912, 0x14 },
+{ "linux/raid/md_u.h", "HOT_ADD_DISK", _IOC_NONE, 0x0928, 0x00 },
+{ "linux/raid/md_u.h", "HOT_GENERATE_ERROR", _IOC_NONE, 0x092a, 0x00 },
+{ "linux/raid/md_u.h", "HOT_REMOVE_DISK", _IOC_NONE, 0x0922, 0x00 },
+{ "linux/raid/md_u.h", "PROTECT_ARRAY", _IOC_NONE, 0x0927, 0x00 },
+{ "linux/raid/md_u.h", "RAID_AUTORUN", _IOC_NONE, 0x0914, 0x00 },
+{ "linux/raid/md_u.h", "RAID_VERSION", _IOC_READ, 0x0910, 0x0c },
+{ "linux/raid/md_u.h", "RESTART_ARRAY_RW", _IOC_NONE, 0x0934, 0x00 },
+{ "linux/raid/md_u.h", "RUN_ARRAY", _IOC_WRITE, 0x0930, 0x0c },
+{ "linux/raid/md_u.h", "SET_ARRAY_INFO", _IOC_WRITE, 0x0923, 0x48 },
+{ "linux/raid/md_u.h", "SET_BITMAP_FILE", _IOC_WRITE, 0x092b, 0x04 },
+{ "linux/raid/md_u.h", "SET_DISK_FAULTY", _IOC_NONE, 0x0929, 0x00 },
+{ "linux/raid/md_u.h", "SET_DISK_INFO", _IOC_NONE, 0x0924, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY", _IOC_NONE, 0x0932, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY_RO", _IOC_NONE, 0x0933, 0x00 },
+{ "linux/raid/md_u.h", "UNPROTECT_ARRAY", _IOC_NONE, 0x0926, 0x00 },
+{ "linux/raid/md_u.h", "WRITE_RAID_INFO", _IOC_NONE, 0x0925, 0x00 },
+{ "linux/random.h", "RNDADDENTROPY", _IOC_WRITE, 0x5203, 0x08 },
+{ "linux/random.h", "RNDADDTOENTCNT", _IOC_WRITE, 0x5201, 0x04 },
+{ "linux/random.h", "RNDCLEARPOOL", _IOC_NONE, 0x5206, 0x00 },
+{ "linux/random.h", "RNDGETENTCNT", _IOC_READ, 0x5200, 0x04 },
+{ "linux/random.h", "RNDGETPOOL", _IOC_READ, 0x5202, 0x08 },
+{ "linux/random.h", "RNDZAPENTCNT", _IOC_NONE, 0x5204, 0x00 },
+{ "linux/raw.h", "RAW_GETBIND", _IOC_NONE, 0xac01, 0x00 },
+{ "linux/raw.h", "RAW_SETBIND", _IOC_NONE, 0xac00, 0x00 },
+{ "linux/reiserfs_fs.h", "REISERFS_IOC_UNPACK", _IOC_WRITE, 0xcd01, 0x04 },
+{ "linux/rfkill.h", "RFKILL_IOCTL_NOINPUT", _IOC_NONE, 0x5201, 0x00 },
+{ "linux/rio_mport_cdev.h", "RIO_ALLOC_DMA", _IOC_READ|_IOC_WRITE, 0x6d13, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_ADD", _IOC_WRITE, 0x6d17, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_DEL", _IOC_WRITE, 0x6d18, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d0a, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0c, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d09, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0b, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_FREE_DMA", _IOC_WRITE, 0x6d14, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_GET_EVENT_MASK", _IOC_READ, 0x6d0e, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_INBOUND", _IOC_READ|_IOC_WRITE, 0x6d11, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_OUTBOUND", _IOC_READ|_IOC_WRITE, 0x6d0f, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_GET_PROPERTIES", _IOC_READ, 0x6d04, 0x30 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_COMPTAG_SET", _IOC_WRITE, 0x6d02, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_HDID_SET", _IOC_WRITE, 0x6d01, 0x02 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_PORT_IDX_GET", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_LOCAL", _IOC_READ, 0x6d05, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_REMOTE", _IOC_READ, 0x6d07, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_LOCAL", _IOC_WRITE, 0x6d06, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_REMOTE", _IOC_WRITE, 0x6d08, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_SET_EVENT_MASK", _IOC_WRITE, 0x6d0d, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_TRANSFER", _IOC_READ|_IOC_WRITE, 0x6d15, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_INBOUND", _IOC_WRITE, 0x6d12, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_OUTBOUND", _IOC_WRITE, 0x6d10, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_WAIT_FOR_ASYNC", _IOC_WRITE, 0x6d16, 0x08 },
+{ "linux/rtc.h", "RTC_AIE_OFF", _IOC_NONE, 0x7002, 0x00 },
+{ "linux/rtc.h", "RTC_AIE_ON", _IOC_NONE, 0x7001, 0x00 },
+{ "linux/rtc.h", "RTC_ALM_READ", _IOC_READ, 0x7008, 0x24 },
+{ "linux/rtc.h", "RTC_ALM_SET", _IOC_WRITE, 0x7007, 0x24 },
+{ "linux/rtc.h", "RTC_EPOCH_READ", _IOC_READ, 0x700d, 0x04 },
+{ "linux/rtc.h", "RTC_EPOCH_SET", _IOC_WRITE, 0x700e, 0x04 },
+{ "linux/rtc.h", "RTC_IRQP_READ", _IOC_READ, 0x700b, 0x04 },
+{ "linux/rtc.h", "RTC_IRQP_SET", _IOC_WRITE, 0x700c, 0x04 },
+{ "linux/rtc.h", "RTC_PIE_OFF", _IOC_NONE, 0x7006, 0x00 },
+{ "linux/rtc.h", "RTC_PIE_ON", _IOC_NONE, 0x7005, 0x00 },
+{ "linux/rtc.h", "RTC_PLL_GET", _IOC_READ, 0x7011, 0x1c },
+{ "linux/rtc.h", "RTC_PLL_SET", _IOC_WRITE, 0x7012, 0x1c },
+{ "linux/rtc.h", "RTC_RD_TIME", _IOC_READ, 0x7009, 0x24 },
+{ "linux/rtc.h", "RTC_SET_TIME", _IOC_WRITE, 0x700a, 0x24 },
+{ "linux/rtc.h", "RTC_UIE_OFF", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/rtc.h", "RTC_UIE_ON", _IOC_NONE, 0x7003, 0x00 },
+{ "linux/rtc.h", "RTC_VL_CLR", _IOC_NONE, 0x7014, 0x00 },
+{ "linux/rtc.h", "RTC_VL_READ", _IOC_READ, 0x7013, 0x04 },
+{ "linux/rtc.h", "RTC_WIE_OFF", _IOC_NONE, 0x7010, 0x00 },
+{ "linux/rtc.h", "RTC_WIE_ON", _IOC_NONE, 0x700f, 0x00 },
+{ "linux/rtc.h", "RTC_WKALM_RD", _IOC_READ, 0x7010, 0x28 },
+{ "linux/rtc.h", "RTC_WKALM_SET", _IOC_WRITE, 0x700f, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREG", _IOC_READ|_IOC_WRITE, 0x7305, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREQ", _IOC_READ|_IOC_WRITE, 0x7304, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_BIND", _IOC_READ|_IOC_WRITE, 0x7301, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_CONNECT", _IOC_READ|_IOC_WRITE, 0x7303, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_MARK", _IOC_READ|_IOC_WRITE, 0x730f, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_SIGNAL", _IOC_READ|_IOC_WRITE, 0x7311, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_WAIT", _IOC_READ|_IOC_WRITE, 0x7310, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_GET_NODEIDS", _IOC_READ|_IOC_WRITE, 0x730e, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_LISTEN", _IOC_WRITE, 0x7302, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_READFROM", _IOC_READ|_IOC_WRITE, 0x730a, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_RECV", _IOC_READ|_IOC_WRITE, 0x7307, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_REG", _IOC_READ|_IOC_WRITE, 0x7308, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_SEND", _IOC_READ|_IOC_WRITE, 0x7306, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_UNREG", _IOC_READ|_IOC_WRITE, 0x7309, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_VREADFROM", _IOC_READ|_IOC_WRITE, 0x730c, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_VWRITETO", _IOC_READ|_IOC_WRITE, 0x730d, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_WRITETO", _IOC_READ|_IOC_WRITE, 0x730b, 0x28 },
+{ "linux/serio.h", "SPIOCSTYPE", _IOC_WRITE, 0x7101, 0x04 },
+{ "linux/sockios.h", "SIOCADDDLCI", 0, 0x8980, 0 },
+{ "linux/sockios.h", "SIOCADDMULTI", 0, 0x8931, 0 },
+{ "linux/sockios.h", "SIOCADDRT", 0, 0x890B, 0 },
+{ "linux/sockios.h", "SIOCBONDCHANGEACTIVE", 0, 0x8995, 0 },
+{ "linux/sockios.h", "SIOCBONDENSLAVE", 0, 0x8990, 0 },
+{ "linux/sockios.h", "SIOCBONDINFOQUERY", 0, 0x8994, 0 },
+{ "linux/sockios.h", "SIOCBONDRELEASE", 0, 0x8991, 0 },
+{ "linux/sockios.h", "SIOCBONDSETHWADDR", 0, 0x8992, 0 },
+{ "linux/sockios.h", "SIOCBONDSLAVEINFOQUERY", 0, 0x8993, 0 },
+{ "linux/sockios.h", "SIOCBRADDBR", 0, 0x89a0, 0 },
+{ "linux/sockios.h", "SIOCBRADDIF", 0, 0x89a2, 0 },
+{ "linux/sockios.h", "SIOCBRDELBR", 0, 0x89a1, 0 },
+{ "linux/sockios.h", "SIOCBRDELIF", 0, 0x89a3, 0 },
+{ "linux/sockios.h", "SIOCDARP", 0, 0x8953, 0 },
+{ "linux/sockios.h", "SIOCDELDLCI", 0, 0x8981, 0 },
+{ "linux/sockios.h", "SIOCDELMULTI", 0, 0x8932, 0 },
+{ "linux/sockios.h", "SIOCDELRT", 0, 0x890C, 0 },
+{ "linux/sockios.h", "SIOCDEVPRIVATE", 0, 0x89F0, 0 },
+{ "linux/sockios.h", "SIOCDIFADDR", 0, 0x8936, 0 },
+{ "linux/sockios.h", "SIOCDRARP", 0, 0x8960, 0 },
+{ "linux/sockios.h", "SIOCETHTOOL", 0, 0x8946, 0 },
+{ "linux/sockios.h", "SIOCGARP", 0, 0x8954, 0 },
+{ "linux/sockios.h", "SIOCGHWTSTAMP", 0, 0x89b1, 0 },
+{ "linux/sockios.h", "SIOCGIFADDR", 0, 0x8915, 0 },
+{ "linux/sockios.h", "SIOCGIFBR", 0, 0x8940, 0 },
+{ "linux/sockios.h", "SIOCGIFBRDADDR", 0, 0x8919, 0 },
+{ "linux/sockios.h", "SIOCGIFCONF", 0, 0x8912, 0 },
+{ "linux/sockios.h", "SIOCGIFCOUNT", 0, 0x8938, 0 },
+{ "linux/sockios.h", "SIOCGIFDSTADDR", 0, 0x8917, 0 },
+{ "linux/sockios.h", "SIOCGIFENCAP", 0, 0x8925, 0 },
+{ "linux/sockios.h", "SIOCGIFFLAGS", 0, 0x8913, 0 },
+{ "linux/sockios.h", "SIOCGIFHWADDR", 0, 0x8927, 0 },
+{ "linux/sockios.h", "SIOCGIFINDEX", 0, 0x8933, 0 },
+{ "linux/sockios.h", "SIOCGIFMAP", 0, 0x8970, 0 },
+{ "linux/sockios.h", "SIOCGIFMEM", 0, 0x891f, 0 },
+{ "linux/sockios.h", "SIOCGIFMETRIC", 0, 0x891d, 0 },
+{ "linux/sockios.h", "SIOCGIFMTU", 0, 0x8921, 0 },
+{ "linux/sockios.h", "SIOCGIFNAME", 0, 0x8910, 0 },
+{ "linux/sockios.h", "SIOCGIFNETMASK", 0, 0x891b, 0 },
+{ "linux/sockios.h", "SIOCGIFPFLAGS", 0, 0x8935, 0 },
+{ "linux/sockios.h", "SIOCGIFSLAVE", 0, 0x8929, 0 },
+{ "linux/sockios.h", "SIOCGIFTXQLEN", 0, 0x8942, 0 },
+{ "linux/sockios.h", "SIOCGIFVLAN", 0, 0x8982, 0 },
+{ "linux/sockios.h", "SIOCGMIIPHY", 0, 0x8947, 0 },
+{ "linux/sockios.h", "SIOCGMIIREG", 0, 0x8948, 0 },
+{ "linux/sockios.h", "SIOCGRARP", 0, 0x8961, 0 },
+{ "linux/sockios.h", "SIOCOUTQNSD", 0, 0x894B, 0 },
+{ "linux/sockios.h", "SIOCPROTOPRIVATE", 0, 0x89E0, 0 },
+{ "linux/sockios.h", "SIOCRTMSG", 0, 0x890D, 0 },
+{ "linux/sockios.h", "SIOCSARP", 0, 0x8955, 0 },
+{ "linux/sockios.h", "SIOCSHWTSTAMP", 0, 0x89b0, 0 },
+{ "linux/sockios.h", "SIOCSIFADDR", 0, 0x8916, 0 },
+{ "linux/sockios.h", "SIOCSIFBR", 0, 0x8941, 0 },
+{ "linux/sockios.h", "SIOCSIFBRDADDR", 0, 0x891a, 0 },
+{ "linux/sockios.h", "SIOCSIFDSTADDR", 0, 0x8918, 0 },
+{ "linux/sockios.h", "SIOCSIFENCAP", 0, 0x8926, 0 },
+{ "linux/sockios.h", "SIOCSIFFLAGS", 0, 0x8914, 0 },
+{ "linux/sockios.h", "SIOCSIFHWADDR", 0, 0x8924, 0 },
+{ "linux/sockios.h", "SIOCSIFHWBROADCAST", 0, 0x8937, 0 },
+{ "linux/sockios.h", "SIOCSIFLINK", 0, 0x8911, 0 },
+{ "linux/sockios.h", "SIOCSIFMAP", 0, 0x8971, 0 },
+{ "linux/sockios.h", "SIOCSIFMEM", 0, 0x8920, 0 },
+{ "linux/sockios.h", "SIOCSIFMETRIC", 0, 0x891e, 0 },
+{ "linux/sockios.h", "SIOCSIFMTU", 0, 0x8922, 0 },
+{ "linux/sockios.h", "SIOCSIFNAME", 0, 0x8923, 0 },
+{ "linux/sockios.h", "SIOCSIFNETMASK", 0, 0x891c, 0 },
+{ "linux/sockios.h", "SIOCSIFPFLAGS", 0, 0x8934, 0 },
+{ "linux/sockios.h", "SIOCSIFSLAVE", 0, 0x8930, 0 },
+{ "linux/sockios.h", "SIOCSIFTXQLEN", 0, 0x8943, 0 },
+{ "linux/sockios.h", "SIOCSIFVLAN", 0, 0x8983, 0 },
+{ "linux/sockios.h", "SIOCSMIIREG", 0, 0x8949, 0 },
+{ "linux/sockios.h", "SIOCSRARP", 0, 0x8962, 0 },
+{ "linux/sockios.h", "SIOCWANDEV", 0, 0x894A, 0 },
+{ "linux/sonet.h", "SONET_CLRDIAG", _IOC_READ|_IOC_WRITE, 0x6113, 0x04 },
+{ "linux/sonet.h", "SONET_GETDIAG", _IOC_READ, 0x6114, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRAMING", _IOC_READ, 0x6116, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRSENSE", _IOC_READ, 0x6117, 0x06 },
+{ "linux/sonet.h", "SONET_GETSTAT", _IOC_READ, 0x6110, 0x24 },
+{ "linux/sonet.h", "SONET_GETSTATZ", _IOC_READ, 0x6111, 0x24 },
+{ "linux/sonet.h", "SONET_SETDIAG", _IOC_READ|_IOC_WRITE, 0x6112, 0x04 },
+{ "linux/sonet.h", "SONET_SETFRAMING", _IOC_WRITE, 0x6115, 0x04 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1CAP", _IOC_READ, 0x7602, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1REM", _IOC_READ, 0x7603, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2CAP", _IOC_READ, 0x7604, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2REM", _IOC_READ, 0x7605, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBATFLAGS", _IOC_READ, 0x7607, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBLUE", _IOC_READ, 0x7608, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBRT", _IOC_READ, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGFAN", _IOC_READ, 0x760a, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGTEMP", _IOC_READ, 0x760c, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBLUE", _IOC_WRITE, 0x7609, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBRT", _IOC_WRITE, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSFAN", _IOC_WRITE, 0x760b, 0x01 },
+{ "linux/soundcard.h", "OSS_GETVERSION", _IOC_READ, 0x4d76, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_COPR_HALT", _IOC_READ|_IOC_WRITE, 0x4307, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_LOAD", _IOC_READ|_IOC_WRITE, 0x4301, 0xfb0 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCODE", _IOC_READ|_IOC_WRITE, 0x4303, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCVMSG", _IOC_READ, 0x4309, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RDATA", _IOC_READ|_IOC_WRITE, 0x4302, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RESET", _IOC_NONE, 0x4300, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RUN", _IOC_READ|_IOC_WRITE, 0x4306, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_SENDMSG", _IOC_READ|_IOC_WRITE, 0x4308, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WCODE", _IOC_WRITE, 0x4305, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WDATA", _IOC_WRITE, 0x4304, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_DSP_BIND_CHANNEL", _IOC_READ|_IOC_WRITE, 0x5041, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_CHANNELS", _IOC_READ|_IOC_WRITE, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETBLKSIZE", _IOC_READ|_IOC_WRITE, 0x5004, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCAPS", _IOC_READ, 0x500f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCHANNELMASK", _IOC_READ|_IOC_WRITE, 0x5040, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETFMTS", _IOC_READ, 0x500b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETIPTR", _IOC_READ, 0x5011, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETISPACE", _IOC_READ, 0x500d, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETODELAY", _IOC_READ, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOPTR", _IOC_READ, 0x5012, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOSPACE", _IOC_READ, 0x500c, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETSPDIF", _IOC_READ, 0x5043, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETTRIGGER", _IOC_READ, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPINBUF", _IOC_READ, 0x5013, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPOUTBUF", _IOC_READ, 0x5014, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_DSP_NONBLOCK", _IOC_NONE, 0x500e, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_POST", _IOC_NONE, 0x5008, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_PROFILE", _IOC_WRITE, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_RESET", _IOC_NONE, 0x5000, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETDUPLEX", _IOC_NONE, 0x5016, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFMT", _IOC_READ|_IOC_WRITE, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFRAGMENT", _IOC_READ|_IOC_WRITE, 0x500a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSPDIF", _IOC_WRITE, 0x5042, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSYNCRO", _IOC_NONE, 0x5015, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETTRIGGER", _IOC_WRITE, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SPEED", _IOC_READ|_IOC_WRITE, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_STEREO", _IOC_READ|_IOC_WRITE, 0x5003, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SUBDIVIDE", _IOC_READ|_IOC_WRITE, 0x5009, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SYNC", _IOC_NONE, 0x5001, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_FM_4OP_ENABLE", _IOC_WRITE, 0x510f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_FM_LOAD_INSTR", _IOC_WRITE, 0x5107, 0x28 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_INFO", _IOC_READ|_IOC_WRITE, 0x510c, 0x74 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUCMD", _IOC_READ|_IOC_WRITE, 0x6d02, 0x21 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUMODE", _IOC_READ|_IOC_WRITE, 0x6d01, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_PRETIME", _IOC_READ|_IOC_WRITE, 0x6d00, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_CTRLRATE", _IOC_READ|_IOC_WRITE, 0x5103, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETINCOUNT", _IOC_READ, 0x5105, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETOUTCOUNT", _IOC_READ, 0x5104, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETTIME", _IOC_READ, 0x5113, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRMIDIS", _IOC_READ, 0x510b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRSYNTHS", _IOC_READ, 0x510a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_OUTOFBAND", _IOC_WRITE, 0x5112, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PANIC", _IOC_NONE, 0x5111, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PERCMODE", _IOC_WRITE, 0x5106, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESET", _IOC_NONE, 0x5100, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESETSAMPLES", _IOC_WRITE, 0x5109, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_SYNC", _IOC_NONE, 0x5101, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_TESTMIDI", _IOC_WRITE, 0x5108, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_THRESHOLD", _IOC_WRITE, 0x510d, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_CONTROL", _IOC_READ|_IOC_WRITE, 0x5115, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_ID", _IOC_READ|_IOC_WRITE, 0x5114, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_INFO", _IOC_READ|_IOC_WRITE, 0x5102, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_MEMAVL", _IOC_READ|_IOC_WRITE, 0x510e, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_REMOVESAMPLE", _IOC_READ|_IOC_WRITE, 0x5116, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_TMR_CONTINUE", _IOC_NONE, 0x5404, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_METRONOME", _IOC_WRITE, 0x5407, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SELECT", _IOC_WRITE, 0x5408, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SOURCE", _IOC_READ|_IOC_WRITE, 0x5406, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_START", _IOC_NONE, 0x5402, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_STOP", _IOC_NONE, 0x5403, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TEMPO", _IOC_READ|_IOC_WRITE, 0x5405, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TIMEBASE", _IOC_READ|_IOC_WRITE, 0x5401, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_3DSE", _IOC_READ|_IOC_WRITE, 0x4d68, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_ACCESS", _IOC_READ|_IOC_WRITE, 0x4d66, 0x80 },
+{ "linux/soundcard.h", "SOUND_MIXER_AGC", _IOC_READ|_IOC_WRITE, 0x4d67, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_GETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d74, 0xa4 },
+{ "linux/soundcard.h", "SOUND_MIXER_INFO", _IOC_READ, 0x4d65, 0x5c },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE1", _IOC_READ|_IOC_WRITE, 0x4d6f, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE2", _IOC_READ|_IOC_WRITE, 0x4d70, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE3", _IOC_READ|_IOC_WRITE, 0x4d71, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE4", _IOC_READ|_IOC_WRITE, 0x4d72, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE5", _IOC_READ|_IOC_WRITE, 0x4d73, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_SETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d75, 0xa4 },
+{ "linux/soundcard.h", "SOUND_OLD_MIXER_INFO", _IOC_READ, 0x4d65, 0x30 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_BITS", _IOC_READ, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_CHANNELS", _IOC_READ, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_FILTER", _IOC_READ, 0x5007, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_RATE", _IOC_READ, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_WRITE_FILTER", _IOC_READ|_IOC_WRITE, 0x5007, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_BITS_PER_WORD", _IOC_READ, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_LSB_FIRST", _IOC_READ, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MAX_SPEED_HZ", _IOC_READ, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE", _IOC_READ, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE32", _IOC_READ, 0x6b05, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_BITS_PER_WORD", _IOC_WRITE, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_LSB_FIRST", _IOC_WRITE, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MAX_SPEED_HZ", _IOC_WRITE, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE", _IOC_WRITE, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE32", _IOC_WRITE, 0x6b05, 0x04 },
+{ "linux/stm.h", "STP_POLICY_ID_GET", _IOC_READ, 0x2501, 0x10 },
+{ "linux/stm.h", "STP_POLICY_ID_SET", _IOC_READ|_IOC_WRITE, 0x2500, 0x10 },
+{ "linux/stm.h", "STP_SET_OPTIONS", _IOC_WRITE, 0x2502, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ALLOC_SWAP_PAGE", _IOC_READ, 0x3314, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ATOMIC_RESTORE", _IOC_NONE, 0x3304, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_AVAIL_SWAP_SIZE", _IOC_READ, 0x3313, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_CREATE_IMAGE", _IOC_WRITE, 0x3311, 0x04 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE", _IOC_NONE, 0x3305, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREEZE", _IOC_NONE, 0x3301, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE_SWAP_PAGES", _IOC_NONE, 0x3309, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_GET_IMAGE_SIZE", _IOC_READ, 0x330e, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PLATFORM_SUPPORT", _IOC_NONE, 0x330f, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_POWER_OFF", _IOC_NONE, 0x3310, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PREF_IMAGE_SIZE", _IOC_NONE, 0x3312, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_S2RAM", _IOC_NONE, 0x330b, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_SET_SWAP_AREA", _IOC_WRITE, 0x330d, 0x0c },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_UNFREEZE", _IOC_NONE, 0x3302, 0x00 },
+{ "linux/sync_file.h", "SYNC_IOC_FILE_INFO", _IOC_READ|_IOC_WRITE, 0x3e04, 0x38 },
+{ "linux/sync_file.h", "SYNC_IOC_MERGE", _IOC_READ|_IOC_WRITE, 0x3e03, 0x30 },
+{ "linux/synclink.h", "MGSL_IOCCLRMODCOUNT", _IOC_NONE, 0x6d0f, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGGPIO", _IOC_READ, 0x6d11, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCGIF", _IOC_NONE, 0x6d0b, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGPARAMS", _IOC_READ, 0x6d01, 0x20 },
+{ "linux/synclink.h", "MGSL_IOCGSTATS", _IOC_NONE, 0x6d07, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGTXIDLE", _IOC_NONE, 0x6d03, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXCTRL", _IOC_NONE, 0x6d16, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXSYNC", _IOC_NONE, 0x6d14, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCLOOPTXDONE", _IOC_NONE, 0x6d09, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCRXENABLE", _IOC_NONE, 0x6d05, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSGPIO", _IOC_WRITE, 0x6d10, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCSIF", _IOC_NONE, 0x6d0a, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSPARAMS", _IOC_WRITE, 0x6d00, 0x20 },
+{ "linux/synclink.h", "MGSL_IOCSTXIDLE", _IOC_NONE, 0x6d02, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXCTRL", _IOC_NONE, 0x6d15, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXSYNC", _IOC_NONE, 0x6d13, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXABORT", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXENABLE", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCWAITEVENT", _IOC_READ|_IOC_WRITE, 0x6d08, 0x04 },
+{ "linux/synclink.h", "MGSL_IOCWAITGPIO", _IOC_READ|_IOC_WRITE, 0x6d12, 0x10 },
+{ "linux/telephony.h", "OLD_PHONE_RING_START", _IOC_NONE, 0x7187, 0x00 },
+{ "linux/telephony.h", "PHONE_BUSY", _IOC_NONE, 0x71a1, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES", _IOC_NONE, 0x7180, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_CHECK", _IOC_WRITE, 0x7182, 0x04 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_LIST", _IOC_READ, 0x7181, 0x04 },
+{ "linux/telephony.h", "PHONE_CPT_STOP", _IOC_NONE, 0x71a4, 0x00 },
+{ "linux/telephony.h", "PHONE_DIALTONE", _IOC_NONE, 0x71a3, 0x00 },
+{ "linux/telephony.h", "PHONE_DTMF_OOB", _IOC_WRITE, 0x7199, 0x04 },
+{ "linux/telephony.h", "PHONE_DTMF_READY", _IOC_READ, 0x7196, 0x04 },
+{ "linux/telephony.h", "PHONE_EXCEPTION", _IOC_READ, 0x719a, 0x04 },
+{ "linux/telephony.h", "PHONE_FRAME", _IOC_WRITE, 0x718d, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF", _IOC_READ, 0x7197, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF_ASCII", _IOC_READ, 0x7198, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_TONE_OFF_TIME", _IOC_NONE, 0x719f, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_ON_TIME", _IOC_NONE, 0x719e, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_STATE", _IOC_NONE, 0x71a0, 0x00 },
+{ "linux/telephony.h", "PHONE_HOOKSTATE", _IOC_NONE, 0x7184, 0x00 },
+{ "linux/telephony.h", "PHONE_MAXRINGS", _IOC_WRITE, 0x7185, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_CODEC", _IOC_WRITE, 0x7190, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_DEPTH", _IOC_WRITE, 0x7193, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_LEVEL", _IOC_NONE, 0x7195, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_START", _IOC_NONE, 0x7191, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_STOP", _IOC_NONE, 0x7192, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_TONE", _IOC_WRITE, 0x719b, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME", _IOC_WRITE, 0x7194, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME_LINEAR", _IOC_WRITE, 0x71dc, 0x04 },
+{ "linux/telephony.h", "PHONE_PSTN_GET_STATE", _IOC_NONE, 0x71a5, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_LINETEST", _IOC_NONE, 0x71a8, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_SET_STATE", _IOC_WRITE, 0x71a4, 0x04 },
+{ "linux/telephony.h", "PHONE_QUERY_CODEC", _IOC_READ|_IOC_WRITE, 0x71a7, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_CODEC", _IOC_WRITE, 0x7189, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_DEPTH", _IOC_WRITE, 0x718c, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_LEVEL", _IOC_NONE, 0x718f, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_START", _IOC_NONE, 0x718a, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_STOP", _IOC_NONE, 0x718b, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME", _IOC_WRITE, 0x718e, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME_LINEAR", _IOC_WRITE, 0x71db, 0x04 },
+{ "linux/telephony.h", "PHONE_RING", _IOC_NONE, 0x7183, 0x00 },
+{ "linux/telephony.h", "PHONE_RINGBACK", _IOC_NONE, 0x71a2, 0x00 },
+{ "linux/telephony.h", "PHONE_RING_CADENCE", _IOC_WRITE, 0x7186, 0x02 },
+{ "linux/telephony.h", "PHONE_RING_START", _IOC_WRITE, 0x7187, 0x04 },
+{ "linux/telephony.h", "PHONE_RING_STOP", _IOC_NONE, 0x7188, 0x00 },
+{ "linux/telephony.h", "PHONE_SET_TONE_OFF_TIME", _IOC_WRITE, 0x719d, 0x04 },
+{ "linux/telephony.h", "PHONE_SET_TONE_ON_TIME", _IOC_WRITE, 0x719c, 0x04 },
+{ "linux/telephony.h", "PHONE_VAD", _IOC_WRITE, 0x71a9, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK", _IOC_WRITE, 0x71aa, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK_DURATION", _IOC_WRITE, 0x71a6, 0x04 },
+{ "linux/timerfd.h", "TFD_IOC_SET_TICKS", _IOC_WRITE, 0x5400, 0x08 },
+{ "linux/toshiba.h", "TOSHIBA_ACPI_SCI", _IOC_READ|_IOC_WRITE, 0x7491, 0x18 },
+{ "linux/toshiba.h", "TOSH_SMM", _IOC_READ|_IOC_WRITE, 0x7490, 0x18 },
+{ "linux/udf_fs_i.h", "UDF_GETEABLOCK", _IOC_READ, 0x6c41, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETEASIZE", _IOC_READ, 0x6c40, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETVOLIDENT", _IOC_READ, 0x6c42, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_RELOCATE_BLOCKS", _IOC_READ|_IOC_WRITE, 0x6c43, 0x04 },
+{ "linux/uinput.h", "UI_ABS_SETUP", _IOC_WRITE, 0x5504, 0x1c },
+{ "linux/uinput.h", "UI_BEGIN_FF_ERASE", _IOC_READ|_IOC_WRITE, 0x55ca, 0x0c },
+{ "linux/uinput.h", "UI_BEGIN_FF_UPLOAD", _IOC_READ|_IOC_WRITE, 0x55c8, 0x60 },
+{ "linux/uinput.h", "UI_DEV_CREATE", _IOC_NONE, 0x5501, 0x00 },
+{ "linux/uinput.h", "UI_DEV_DESTROY", _IOC_NONE, 0x5502, 0x00 },
+{ "linux/uinput.h", "UI_DEV_SETUP", _IOC_WRITE, 0x5503, 0x5c },
+{ "linux/uinput.h", "UI_END_FF_ERASE", _IOC_WRITE, 0x55cb, 0x0c },
+{ "linux/uinput.h", "UI_END_FF_UPLOAD", _IOC_WRITE, 0x55c9, 0x60 },
+{ "linux/uinput.h", "UI_GET_VERSION", _IOC_READ, 0x552d, 0x04 },
+{ "linux/uinput.h", "UI_SET_ABSBIT", _IOC_WRITE, 0x5567, 0x04 },
+{ "linux/uinput.h", "UI_SET_EVBIT", _IOC_WRITE, 0x5564, 0x04 },
+{ "linux/uinput.h", "UI_SET_FFBIT", _IOC_WRITE, 0x556b, 0x04 },
+{ "linux/uinput.h", "UI_SET_KEYBIT", _IOC_WRITE, 0x5565, 0x04 },
+{ "linux/uinput.h", "UI_SET_LEDBIT", _IOC_WRITE, 0x5569, 0x04 },
+{ "linux/uinput.h", "UI_SET_MSCBIT", _IOC_WRITE, 0x5568, 0x04 },
+{ "linux/uinput.h", "UI_SET_PHYS", _IOC_WRITE, 0x556c, 0x04 },
+{ "linux/uinput.h", "UI_SET_PROPBIT", _IOC_WRITE, 0x556e, 0x04 },
+{ "linux/uinput.h", "UI_SET_RELBIT", _IOC_WRITE, 0x5566, 0x04 },
+{ "linux/uinput.h", "UI_SET_SNDBIT", _IOC_WRITE, 0x556a, 0x04 },
+{ "linux/uinput.h", "UI_SET_SWBIT", _IOC_WRITE, 0x556d, 0x04 },
+{ "linux/usb/cdc-wdm.h", "IOCTL_WDM_MAX_COMMAND", _IOC_READ, 0x48a0, 0x02 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_DESC", _IOC_READ, 0x6782, 0x09 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_REVMAP", _IOC_NONE, 0x6781, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
+{ "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/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 },
+{ "linux/usb/iowarrior.h", "IOW_GETINFO", _IOC_READ, 0xc003, 0x28 },
+{ "linux/usb/iowarrior.h", "IOW_READ", _IOC_WRITE, 0xc002, 0x04 },
+{ "linux/usb/iowarrior.h", "IOW_WRITE", _IOC_WRITE, 0xc001, 0x04 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GET_CAPS", _IOC_READ, 0x5b11, 0x01 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GOTO_LOCAL", _IOC_NONE, 0x5b14, 0x00 },
+{ "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", "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_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
+{ "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 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIMINTERFACE", _IOC_READ, 0x550f, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIM_PORT", _IOC_READ, 0x5518, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLEAR_HALT", _IOC_READ, 0x5515, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECT", _IOC_NONE, 0x5517, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECTINFO", _IOC_WRITE, 0x5511, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL32", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCARDURB", _IOC_NONE, 0x550b, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT", _IOC_NONE, 0x5516, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT_CLAIM", _IOC_READ, 0x551b, 0x108 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL32", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DROP_PRIVILEGES", _IOC_WRITE, 0x551e, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_FREE_STREAMS", _IOC_READ, 0x551d, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GETDRIVER", _IOC_WRITE, 0x5508, 0x104 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GET_CAPABILITIES", _IOC_READ, 0x551a, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_HUB_PORTINFO", _IOC_READ, 0x5513, 0x80 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL32", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB32", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY32", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASEINTERFACE", _IOC_READ, 0x5510, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASE_PORT", _IOC_READ, 0x5519, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESET", _IOC_NONE, 0x5514, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESETEP", _IOC_READ, 0x5503, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETCONFIGURATION", _IOC_READ, 0x5505, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETINTERFACE", _IOC_READ, 0x5504, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB", _IOC_READ, 0x550a, 0x2c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB32", _IOC_READ, 0x550a, 0x2a },
+{ "linux/userfaultfd.h", "UFFDIO_API", _IOC_READ|_IOC_WRITE, 0xaa3f, 0x18 },
+{ "linux/userfaultfd.h", "UFFDIO_COPY", _IOC_READ|_IOC_WRITE, 0xaa03, 0x28 },
+{ "linux/userfaultfd.h", "UFFDIO_REGISTER", _IOC_READ|_IOC_WRITE, 0xaa00, 0x20 },
+{ "linux/userfaultfd.h", "UFFDIO_UNREGISTER", _IOC_READ, 0xaa01, 0x10 },
+{ "linux/userfaultfd.h", "UFFDIO_WAKE", _IOC_READ, 0xaa02, 0x10 },
+{ "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 },
+{ "linux/vfio.h", "VFIO_CHECK_EXTENSION", _IOC_NONE, 0x3b65, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_INFO", _IOC_NONE, 0x3b6b, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_IRQ_INFO", _IOC_NONE, 0x3b6d, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_REGION_INFO", _IOC_NONE, 0x3b6c, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_PCI_HOT_RESET", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_RESET", _IOC_NONE, 0x3b6f, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_SET_IRQS", _IOC_NONE, 0x3b6e, 0x00 },
+{ "linux/vfio.h", "VFIO_EEH_PE_OP", _IOC_NONE, 0x3b79, 0x00 },
+{ "linux/vfio.h", "VFIO_GET_API_VERSION", _IOC_NONE, 0x3b64, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_DEVICE_FD", _IOC_NONE, 0x3b6a, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_STATUS", _IOC_NONE, 0x3b67, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_SET_CONTAINER", _IOC_NONE, 0x3b68, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_UNSET_CONTAINER", _IOC_NONE, 0x3b69, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_DISABLE", _IOC_NONE, 0x3b74, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_ENABLE", _IOC_NONE, 0x3b73, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_MAP_DMA", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", _IOC_NONE, 0x3b75, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_CREATE", _IOC_NONE, 0x3b77, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_REMOVE", _IOC_NONE, 0x3b78, 0x00 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_GET_VRING_ENDIAN", _IOC_WRITE, 0xaf14, 0x08 },
+{ "linux/vhost.h", "VHOST_NET_SET_BACKEND", _IOC_WRITE, 0xaf30, 0x08 },
+{ "linux/vhost.h", "VHOST_RESET_OWNER", _IOC_NONE, 0xaf02, 0x00 },
+{ "linux/vhost.h", "VHOST_SCSI_CLEAR_ENDPOINT", _IOC_WRITE, 0xaf41, 0xe8 },
+{ "linux/vhost.h", "VHOST_SCSI_GET_ABI_VERSION", _IOC_WRITE, 0xaf42, 0x04 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_SET_MEM_TABLE", _IOC_WRITE, 0xaf03, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_OWNER", _IOC_NONE, 0xaf01, 0x00 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ADDR", _IOC_WRITE, 0xaf11, 0x28 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BASE", _IOC_WRITE, 0xaf12, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf23, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_CALL", _IOC_WRITE, 0xaf21, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ENDIAN", _IOC_WRITE, 0xaf13, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ERR", _IOC_WRITE, 0xaf22, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_KICK", _IOC_WRITE, 0xaf20, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_NUM", _IOC_WRITE, 0xaf10, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_CREATE_BUFS", _IOC_READ|_IOC_WRITE, 0x565c, 0xf8 },
+{ "linux/videodev2.h", "VIDIOC_CROPCAP", _IOC_READ|_IOC_WRITE, 0x563a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_CHIP_INFO", _IOC_READ|_IOC_WRITE, 0x5666, 0xc8 },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_REGISTER", _IOC_READ|_IOC_WRITE, 0x5650, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DBG_S_REGISTER", _IOC_WRITE, 0x564f, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5660, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_DQBUF", _IOC_READ|_IOC_WRITE, 0x5611, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_DQEVENT", _IOC_READ, 0x5659, 0x80 },
+{ "linux/videodev2.h", "VIDIOC_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
+{ "linux/videodev2.h", "VIDIOC_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564d, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDIO", _IOC_READ|_IOC_WRITE, 0x5641, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDOUT", _IOC_READ|_IOC_WRITE, 0x5642, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMINPUT", _IOC_READ|_IOC_WRITE, 0x561a, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_ENUMOUTPUT", _IOC_READ|_IOC_WRITE, 0x5630, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUMSTD", _IOC_READ|_IOC_WRITE, 0x5619, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FMT", _IOC_READ|_IOC_WRITE, 0x5602, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMEINTERVALS", _IOC_READ|_IOC_WRITE, 0x564b, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMESIZES", _IOC_READ|_IOC_WRITE, 0x564a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FREQ_BANDS", _IOC_READ|_IOC_WRITE, 0x5665, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_EXPBUF", _IOC_READ|_IOC_WRITE, 0x5610, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDIO", _IOC_READ, 0x5621, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDOUT", _IOC_READ, 0x5631, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_G_CTRL", _IOC_READ|_IOC_WRITE, 0x561b, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
+{ "linux/videodev2.h", "VIDIOC_G_ENC_INDEX", _IOC_READ, 0x564c, 0x818 },
+{ "linux/videodev2.h", "VIDIOC_G_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5647, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_G_FBUF", _IOC_READ, 0x560a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_FREQUENCY", _IOC_READ|_IOC_WRITE, 0x5638, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_INPUT", _IOC_READ, 0x5626, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_JPEGCOMP", _IOC_READ, 0x563d, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_G_MODULATOR", _IOC_READ|_IOC_WRITE, 0x5636, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_G_OUTPUT", _IOC_READ, 0x562e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_PARM", _IOC_READ|_IOC_WRITE, 0x5615, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_PRIORITY", _IOC_READ, 0x5643, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x565e, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_SLICED_VBI_CAP", _IOC_READ|_IOC_WRITE, 0x5645, 0x74 },
+{ "linux/videodev2.h", "VIDIOC_G_STD", _IOC_READ, 0x5617, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_TUNER", _IOC_READ|_IOC_WRITE, 0x561d, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_LOG_STATUS", _IOC_NONE, 0x5646, 0x00 },
+{ "linux/videodev2.h", "VIDIOC_OVERLAY", _IOC_WRITE, 0x560e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_PREPARE_BUF", _IOC_READ|_IOC_WRITE, 0x565d, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QBUF", _IOC_READ|_IOC_WRITE, 0x560f, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYBUF", _IOC_READ|_IOC_WRITE, 0x5609, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCAP", _IOC_READ, 0x5600, 0x68 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCTRL", _IOC_READ|_IOC_WRITE, 0x5624, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYMENU", _IOC_READ|_IOC_WRITE, 0x5625, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_QUERYSTD", _IOC_READ, 0x563f, 0x08 },
+{ "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 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDIO", _IOC_WRITE, 0x5622, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDOUT", _IOC_WRITE, 0x5632, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_CROP", _IOC_WRITE, 0x563c, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_S_CTRL", _IOC_READ|_IOC_WRITE, 0x561c, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
+{ "linux/videodev2.h", "VIDIOC_S_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5648, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_S_FBUF", _IOC_WRITE, 0x560b, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_FREQUENCY", _IOC_WRITE, 0x5639, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_HW_FREQ_SEEK", _IOC_WRITE, 0x5652, 0x30 },
+{ "linux/videodev2.h", "VIDIOC_S_INPUT", _IOC_READ|_IOC_WRITE, 0x5627, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_JPEGCOMP", _IOC_WRITE, 0x563e, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_S_MODULATOR", _IOC_WRITE, 0x5637, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_S_OUTPUT", _IOC_READ|_IOC_WRITE, 0x562f, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_PARM", _IOC_READ|_IOC_WRITE, 0x5616, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_PRIORITY", _IOC_WRITE, 0x5644, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x565f, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_S_STD", _IOC_WRITE, 0x5618, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_TUNER", _IOC_WRITE, 0x561e, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_TRY_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5661, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_TRY_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564e, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_TRY_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5649, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_TRY_FMT", _IOC_READ|_IOC_WRITE, 0x5640, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_UNSUBSCRIBE_EVENT", _IOC_WRITE, 0x565b, 0x20 },
+{ "linux/vm_sockets.h", "IOCTL_VM_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_ADD_NOTIFICATION", _IOC_NONE, 0x07af, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_GET_CPT_STATE", _IOC_NONE, 0x07b1, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", _IOC_NONE, 0x07b0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_SET_CPT_STATE", _IOC_NONE, 0x07b2, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_RECEIVE", _IOC_NONE, 0x07ac, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_SEND", _IOC_NONE, 0x07ab, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_GET_CONTEXT_ID", _IOC_NONE, 0x07b3, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_INIT_CONTEXT", _IOC_NONE, 0x07a0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", _IOC_NONE, 0x07a6, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFY_RESOURCE", _IOC_NONE, 0x07a5, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_ALLOC", _IOC_NONE, 0x07a8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_DETACH", _IOC_NONE, 0x07aa, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", _IOC_NONE, 0x07a9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETVA", _IOC_NONE, 0x07a4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SET_NOTIFY", _IOC_NONE, 0x07cb, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", _IOC_NONE, 0x07b8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_VERSION", _IOC_NONE, 0x07b4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION", _IOC_NONE, 0x079f, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION2", _IOC_NONE, 0x07a7, 0x00 },
+{ "linux/vsp1.h", "VIDIOC_VSP1_LUT_CONFIG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x400 },
+{ "linux/vt.h", "VT_ACTIVATE", 0, 0x5606, 0 },
+{ "linux/vt.h", "VT_DISALLOCATE", 0, 0x5608, 0 },
+{ "linux/vt.h", "VT_GETHIFONTMASK", 0, 0x560D, 0 },
+{ "linux/vt.h", "VT_GETMODE", 0, 0x5601, 0 },
+{ "linux/vt.h", "VT_GETSTATE", 0, 0x5603, 0 },
+{ "linux/vt.h", "VT_LOCKSWITCH", 0, 0x560B, 0 },
+{ "linux/vt.h", "VT_OPENQRY", 0, 0x5600, 0 },
+{ "linux/vt.h", "VT_RELDISP", 0, 0x5605, 0 },
+{ "linux/vt.h", "VT_RESIZE", 0, 0x5609, 0 },
+{ "linux/vt.h", "VT_RESIZEX", 0, 0x560A, 0 },
+{ "linux/vt.h", "VT_SENDSIG", 0, 0x5604, 0 },
+{ "linux/vt.h", "VT_SETACTIVATE", 0, 0x560F, 0 },
+{ "linux/vt.h", "VT_SETMODE", 0, 0x5602, 0 },
+{ "linux/vt.h", "VT_UNLOCKSWITCH", 0, 0x560C, 0 },
+{ "linux/vt.h", "VT_WAITACTIVE", 0, 0x5607, 0 },
+{ "linux/vt.h", "VT_WAITEVENT", 0, 0x560E, 0 },
+{ "linux/watchdog.h", "WDIOC_GETBOOTSTATUS", _IOC_READ, 0x5702, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETPRETIMEOUT", _IOC_READ, 0x5709, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSTATUS", _IOC_READ, 0x5701, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSUPPORT", _IOC_READ, 0x5700, 0x28 },
+{ "linux/watchdog.h", "WDIOC_GETTEMP", _IOC_READ, 0x5703, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMELEFT", _IOC_READ, 0x570a, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMEOUT", _IOC_READ, 0x5707, 0x04 },
+{ "linux/watchdog.h", "WDIOC_KEEPALIVE", _IOC_READ, 0x5705, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETOPTIONS", _IOC_READ, 0x5704, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETPRETIMEOUT", _IOC_READ|_IOC_WRITE, 0x5708, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x5706, 0x04 },
+{ "linux/wireless.h", "SIOCGIWAP", 0, 0x8B15, 0 },
+{ "linux/wireless.h", "SIOCGIWAPLIST", 0, 0x8B17, 0 },
+{ "linux/wireless.h", "SIOCGIWAUTH", 0, 0x8B33, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODE", 0, 0x8B2B, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODEEXT", 0, 0x8B35, 0 },
+{ "linux/wireless.h", "SIOCGIWESSID", 0, 0x8B1B, 0 },
+{ "linux/wireless.h", "SIOCGIWFRAG", 0, 0x8B25, 0 },
+{ "linux/wireless.h", "SIOCGIWFREQ", 0, 0x8B05, 0 },
+{ "linux/wireless.h", "SIOCGIWGENIE", 0, 0x8B31, 0 },
+{ "linux/wireless.h", "SIOCGIWMODE", 0, 0x8B07, 0 },
+{ "linux/wireless.h", "SIOCGIWNAME", 0, 0x8B01, 0 },
+{ "linux/wireless.h", "SIOCGIWNICKN", 0, 0x8B1D, 0 },
+{ "linux/wireless.h", "SIOCGIWNWID", 0, 0x8B03, 0 },
+{ "linux/wireless.h", "SIOCGIWPOWER", 0, 0x8B2D, 0 },
+{ "linux/wireless.h", "SIOCGIWPRIV", 0, 0x8B0D, 0 },
+{ "linux/wireless.h", "SIOCGIWRANGE", 0, 0x8B0B, 0 },
+{ "linux/wireless.h", "SIOCGIWRATE", 0, 0x8B21, 0 },
+{ "linux/wireless.h", "SIOCGIWRETRY", 0, 0x8B29, 0 },
+{ "linux/wireless.h", "SIOCGIWRTS", 0, 0x8B23, 0 },
+{ "linux/wireless.h", "SIOCGIWSCAN", 0, 0x8B19, 0 },
+{ "linux/wireless.h", "SIOCGIWSENS", 0, 0x8B09, 0 },
+{ "linux/wireless.h", "SIOCGIWSPY", 0, 0x8B11, 0 },
+{ "linux/wireless.h", "SIOCGIWSTATS", 0, 0x8B0F, 0 },
+{ "linux/wireless.h", "SIOCGIWTHRSPY", 0, 0x8B13, 0 },
+{ "linux/wireless.h", "SIOCGIWTXPOW", 0, 0x8B27, 0 },
+{ "linux/wireless.h", "SIOCIWFIRST", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCIWFIRSTPRIV", 0, 0x8BE0, 0 },
+{ "linux/wireless.h", "SIOCIWLASTPRIV", 0, 0x8BFF, 0 },
+{ "linux/wireless.h", "SIOCSIWAP", 0, 0x8B14, 0 },
+{ "linux/wireless.h", "SIOCSIWAUTH", 0, 0x8B32, 0 },
+{ "linux/wireless.h", "SIOCSIWCOMMIT", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODE", 0, 0x8B2A, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODEEXT", 0, 0x8B34, 0 },
+{ "linux/wireless.h", "SIOCSIWESSID", 0, 0x8B1A, 0 },
+{ "linux/wireless.h", "SIOCSIWFRAG", 0, 0x8B24, 0 },
+{ "linux/wireless.h", "SIOCSIWFREQ", 0, 0x8B04, 0 },
+{ "linux/wireless.h", "SIOCSIWGENIE", 0, 0x8B30, 0 },
+{ "linux/wireless.h", "SIOCSIWMLME", 0, 0x8B16, 0 },
+{ "linux/wireless.h", "SIOCSIWMODE", 0, 0x8B06, 0 },
+{ "linux/wireless.h", "SIOCSIWNICKN", 0, 0x8B1C, 0 },
+{ "linux/wireless.h", "SIOCSIWNWID", 0, 0x8B02, 0 },
+{ "linux/wireless.h", "SIOCSIWPMKSA", 0, 0x8B36, 0 },
+{ "linux/wireless.h", "SIOCSIWPOWER", 0, 0x8B2C, 0 },
+{ "linux/wireless.h", "SIOCSIWPRIV", 0, 0x8B0C, 0 },
+{ "linux/wireless.h", "SIOCSIWRANGE", 0, 0x8B0A, 0 },
+{ "linux/wireless.h", "SIOCSIWRATE", 0, 0x8B20, 0 },
+{ "linux/wireless.h", "SIOCSIWRETRY", 0, 0x8B28, 0 },
+{ "linux/wireless.h", "SIOCSIWRTS", 0, 0x8B22, 0 },
+{ "linux/wireless.h", "SIOCSIWSCAN", 0, 0x8B18, 0 },
+{ "linux/wireless.h", "SIOCSIWSENS", 0, 0x8B08, 0 },
+{ "linux/wireless.h", "SIOCSIWSPY", 0, 0x8B10, 0 },
+{ "linux/wireless.h", "SIOCSIWSTATS", 0, 0x8B0E, 0 },
+{ "linux/wireless.h", "SIOCSIWTHRSPY", 0, 0x8B12, 0 },
+{ "linux/wireless.h", "SIOCSIWTXPOW", 0, 0x8B26, 0 },
+{ "media/davinci/vpfe_capture.h", "VPFE_CMD_S_CCDC_RAW_PARAMS", _IOC_WRITE, 0x56c1, 0x04 },
+{ "media/drv-intf/exynos-fimc.h", "S5P_FIMC_TX_END_NOTIFY", _IOC_NONE, 0x6500, 0x00 },
+{ "media/i2c/adv7842.h", "ADV7842_CMD_RAM_TEST", _IOC_NONE, 0x56c0, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_HIGH", _IOC_NONE, 0x6201, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_LOW", _IOC_NONE, 0x6200, 0x00 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_CLOSE", _IOC_WRITE, 0x5202, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_POLL", _IOC_READ, 0x5204, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_READ", _IOC_READ, 0x5203, 0x04 },
+{ "media/v4l2-common.h", "TUNER_SET_CONFIG", _IOC_WRITE, 0x645c, 0x08 },
+{ "media/v4l2-common.h", "VIDIOC_INT_RESET", _IOC_WRITE, 0x6466, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_DEVICE_NOTIFY_EVENT", _IOC_WRITE, 0x7602, 0x80 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_RX_NOTIFY", _IOC_WRITE, 0x7600, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_TX_NOTIFY", _IOC_WRITE, 0x7601, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_DOWNLOAD_IMAGE", _IOC_WRITE, 0xca0a, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_AFU_ID", _IOC_READ, 0xca02, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_PROCESS_ELEMENT", _IOC_READ, 0xca01, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_START_WORK", _IOC_WRITE, 0xca00, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_VALIDATE_IMAGE", _IOC_WRITE, 0xca0b, 0x40 },
+{ "mtd/mtd-abi.h", "ECCGETLAYOUT", _IOC_READ, 0x4d11, 0x148 },
+{ "mtd/mtd-abi.h", "ECCGETSTATS", _IOC_READ, 0x4d12, 0x10 },
+{ "mtd/mtd-abi.h", "MEMERASE", _IOC_WRITE, 0x4d02, 0x08 },
+{ "mtd/mtd-abi.h", "MEMERASE64", _IOC_WRITE, 0x4d14, 0x10 },
+{ "mtd/mtd-abi.h", "MEMGETBADBLOCK", _IOC_WRITE, 0x4d0b, 0x08 },
+{ "mtd/mtd-abi.h", "MEMGETINFO", _IOC_READ, 0x4d01, 0x20 },
+{ "mtd/mtd-abi.h", "MEMGETOOBSEL", _IOC_READ, 0x4d0a, 0xc8 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONCOUNT", _IOC_READ, 0x4d07, 0x04 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONINFO", _IOC_READ|_IOC_WRITE, 0x4d08, 0x10 },
+{ "mtd/mtd-abi.h", "MEMISLOCKED", _IOC_READ, 0x4d17, 0x08 },
+{ "mtd/mtd-abi.h", "MEMLOCK", _IOC_WRITE, 0x4d05, 0x08 },
+{ "mtd/mtd-abi.h", "MEMREADOOB", _IOC_READ|_IOC_WRITE, 0x4d04, 0x0c },
+{ "mtd/mtd-abi.h", "MEMREADOOB64", _IOC_READ|_IOC_WRITE, 0x4d16, 0x18 },
+{ "mtd/mtd-abi.h", "MEMSETBADBLOCK", _IOC_WRITE, 0x4d0c, 0x08 },
+{ "mtd/mtd-abi.h", "MEMUNLOCK", _IOC_WRITE, 0x4d06, 0x08 },
+{ "mtd/mtd-abi.h", "MEMWRITE", _IOC_READ|_IOC_WRITE, 0x4d18, 0x30 },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB", _IOC_READ|_IOC_WRITE, 0x4d03, 0x0c },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB64", _IOC_READ|_IOC_WRITE, 0x4d15, 0x18 },
+{ "mtd/mtd-abi.h", "MTDFILEMODE", _IOC_NONE, 0x4d13, 0x00 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONCOUNT", _IOC_WRITE, 0x4d0e, 0x04 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONINFO", _IOC_WRITE, 0x4d0f, 0x0c },
+{ "mtd/mtd-abi.h", "OTPLOCK", _IOC_READ, 0x4d10, 0x0c },
+{ "mtd/mtd-abi.h", "OTPSELECT", _IOC_READ, 0x4d0d, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCATT", _IOC_WRITE, 0x6f40, 0x18 },
+{ "mtd/ubi-user.h", "UBI_IOCDET", _IOC_WRITE, 0x6f41, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBCH", _IOC_WRITE, 0x4f02, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBER", _IOC_WRITE, 0x4f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBISMAP", _IOC_READ, 0x4f05, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBMAP", _IOC_WRITE, 0x4f03, 0x08 },
+{ "mtd/ubi-user.h", "UBI_IOCEBUNMAP", _IOC_WRITE, 0x4f04, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCMKVOL", _IOC_WRITE, 0x6f00, 0x98 },
+{ "mtd/ubi-user.h", "UBI_IOCRMVOL", _IOC_WRITE, 0x6f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCRNVOL", _IOC_WRITE, 0x6f03, 0x1110 },
+{ "mtd/ubi-user.h", "UBI_IOCRSVOL", _IOC_WRITE, 0x6f02, 0x0c },
+{ "mtd/ubi-user.h", "UBI_IOCSETVOLPROP", _IOC_WRITE, 0x4f06, 0x10 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLCRBLK", _IOC_WRITE, 0x4f07, 0x80 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLRMBLK", _IOC_NONE, 0x4f08, 0x00 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLUP", _IOC_WRITE, 0x4f00, 0x08 },
+{ "net/bluetooth/hci_sock.h", "HCIBLOCKADDR", _IOC_WRITE, 0x48e6, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVDOWN", _IOC_WRITE, 0x48ca, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESET", _IOC_WRITE, 0x48cb, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESTAT", _IOC_WRITE, 0x48cc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVUP", _IOC_WRITE, 0x48c9, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETAUTHINFO", _IOC_READ, 0x48d7, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNINFO", _IOC_READ, 0x48d5, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNLIST", _IOC_READ, 0x48d4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVINFO", _IOC_READ, 0x48d3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVLIST", _IOC_READ, 0x48d2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIINQUIRY", _IOC_READ, 0x48f0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETACLMTU", _IOC_WRITE, 0x48e3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETAUTH", _IOC_WRITE, 0x48de, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETENCRYPT", _IOC_WRITE, 0x48df, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKMODE", _IOC_WRITE, 0x48e2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKPOL", _IOC_WRITE, 0x48e1, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETPTYPE", _IOC_WRITE, 0x48e0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETRAW", _IOC_WRITE, 0x48dc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCAN", _IOC_WRITE, 0x48dd, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCOMTU", _IOC_WRITE, 0x48e4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIUNBLOCKADDR", _IOC_WRITE, 0x48e7, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMCREATEDEV", _IOC_WRITE, 0x52c8, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVINFO", _IOC_READ, 0x52d3, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVLIST", _IOC_READ, 0x52d2, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMRELEASEDEV", _IOC_WRITE, 0x52c9, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMSTEALDLC", _IOC_WRITE, 0x52dc, 0x04 },
+{ "net/nfc/nci_core.h", "NCIUARTSETDRIVER", _IOC_WRITE, 0x5500, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ACK_EVENT", _IOC_WRITE, 0x1bea, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ASSIGN_CTXT", _IOC_READ|_IOC_WRITE, 0x1be1, 0x1c },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CREDIT_UPD", _IOC_NONE, 0x1be6, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_INFO", _IOC_WRITE, 0x1be2, 0x28 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_RESET", _IOC_NONE, 0x1bec, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_GET_VERS", _IOC_READ, 0x1bee, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_POLL_TYPE", _IOC_WRITE, 0x1be9, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_RECV_CTRL", _IOC_WRITE, 0x1be8, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_SET_PKEY", _IOC_WRITE, 0x1beb, 0x02 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_FREE", _IOC_READ|_IOC_WRITE, 0x1be5, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_INVAL_READ", _IOC_READ|_IOC_WRITE, 0x1bed, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_UPDATE", _IOC_READ|_IOC_WRITE, 0x1be4, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_USER_INFO", _IOC_WRITE, 0x1be3, 0x78 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_ENABLE_PKEY", _IOC_NONE, 0x1b03, 0x00 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT", _IOC_READ|_IOC_WRITE, 0x1b01, 0x1c },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT2", _IOC_READ|_IOC_WRITE, 0x1b04, 0x28 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_UNREGISTER_AGENT", _IOC_WRITE, 0x1b02, 0x04 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_ATTACH", _IOC_READ|_IOC_WRITE, 0xca80, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_DETACH", _IOC_READ|_IOC_WRITE, 0xca83, 0x60 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_MANAGE_LUN", _IOC_READ|_IOC_WRITE, 0xca86, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RECOVER_AFU", _IOC_READ|_IOC_WRITE, 0xca85, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RELEASE", _IOC_READ|_IOC_WRITE, 0xca82, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_DIRECT", _IOC_READ|_IOC_WRITE, 0xca81, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_VIRTUAL", _IOC_READ|_IOC_WRITE, 0xca87, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VERIFY", _IOC_READ|_IOC_WRITE, 0xca84, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_CLONE", _IOC_READ|_IOC_WRITE, 0xca89, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_RESIZE", _IOC_READ|_IOC_WRITE, 0xca88, 0x78 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_BUS_NUMBER", 0, 0x5386, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_IDLUN", 0, 0x5382, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_PCI", 0, 0x5387, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_PROBE_HOST", 0, 0x5385, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORLOCK", 0, 0x5380, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORUNLOCK", 0, 0x5381, 0 },
+{ "scsi/sg.h", "SG_EMULATED_HOST", 0, 0x2203, 0 },
+{ "scsi/sg.h", "SG_GET_ACCESS_COUNT", 0, 0x2289, 0 },
+{ "scsi/sg.h", "SG_GET_COMMAND_Q", 0, 0x2270, 0 },
+{ "scsi/sg.h", "SG_GET_KEEP_ORPHAN", 0, 0x2288, 0 },
+{ "scsi/sg.h", "SG_GET_LOW_DMA", 0, 0x227a, 0 },
+{ "scsi/sg.h", "SG_GET_NUM_WAITING", 0, 0x227d, 0 },
+{ "scsi/sg.h", "SG_GET_PACK_ID", 0, 0x227c, 0 },
+{ "scsi/sg.h", "SG_GET_REQUEST_TABLE", 0, 0x2286, 0 },
+{ "scsi/sg.h", "SG_GET_RESERVED_SIZE", 0, 0x2272, 0 },
+{ "scsi/sg.h", "SG_GET_SCSI_ID", 0, 0x2276, 0 },
+{ "scsi/sg.h", "SG_GET_SG_TABLESIZE", 0, 0x227F, 0 },
+{ "scsi/sg.h", "SG_GET_TIMEOUT", 0, 0x2202, 0 },
+{ "scsi/sg.h", "SG_GET_TRANSFORM", 0, 0x2205, 0 },
+{ "scsi/sg.h", "SG_GET_VERSION_NUM", 0, 0x2282, 0 },
+{ "scsi/sg.h", "SG_IO", 0, 0x2285, 0 },
+{ "scsi/sg.h", "SG_NEXT_CMD_LEN", 0, 0x2283, 0 },
+{ "scsi/sg.h", "SG_SCSI_RESET", 0, 0x2284, 0 },
+{ "scsi/sg.h", "SG_SET_COMMAND_Q", 0, 0x2271, 0 },
+{ "scsi/sg.h", "SG_SET_DEBUG", 0, 0x227e, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_LOW_DMA", 0, 0x2279, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_PACK_ID", 0, 0x227b, 0 },
+{ "scsi/sg.h", "SG_SET_KEEP_ORPHAN", 0, 0x2287, 0 },
+{ "scsi/sg.h", "SG_SET_RESERVED_SIZE", 0, 0x2275, 0 },
+{ "scsi/sg.h", "SG_SET_TIMEOUT", 0, 0x2201, 0 },
+{ "scsi/sg.h", "SG_SET_TRANSFORM", 0, 0x2204, 0 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CLIENT_ID", _IOC_READ, 0x5301, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_PORT", _IOC_READ|_IOC_WRITE, 0x5320, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x5332, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_PORT", _IOC_WRITE, 0x5321, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_QUEUE", _IOC_WRITE, 0x5333, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", _IOC_READ|_IOC_WRITE, 0x5310, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", _IOC_READ|_IOC_WRITE, 0x534b, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", _IOC_READ|_IOC_WRITE, 0x5336, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_PORT_INFO", _IOC_READ|_IOC_WRITE, 0x5322, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", _IOC_READ|_IOC_WRITE, 0x5349, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5334, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", _IOC_READ|_IOC_WRITE, 0x5340, 0x5c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", _IOC_READ|_IOC_WRITE, 0x5341, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", _IOC_READ|_IOC_WRITE, 0x5345, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", _IOC_READ|_IOC_WRITE, 0x5350, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_PVERSION", _IOC_READ, 0x5300, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", _IOC_READ|_IOC_WRITE, 0x5351, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", _IOC_READ|_IOC_WRITE, 0x5352, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_SUBS", _IOC_READ|_IOC_WRITE, 0x534f, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", _IOC_WRITE, 0x534e, 0x40 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_RUNNING_MODE", _IOC_READ|_IOC_WRITE, 0x5303, 0x10 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", _IOC_WRITE, 0x5311, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", _IOC_WRITE, 0x534c, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_PORT_INFO", _IOC_WRITE, 0x5323, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", _IOC_WRITE, 0x534a, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5335, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", _IOC_WRITE, 0x5342, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", _IOC_WRITE, 0x5346, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", _IOC_WRITE, 0x5330, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SYSTEM_INFO", _IOC_READ|_IOC_WRITE, 0x5302, 0x30 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", _IOC_WRITE, 0x5331, 0x50 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_CARD_INFO", _IOC_READ, 0x5501, 0x178 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_ADD", _IOC_READ|_IOC_WRITE, 0x5517, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_INFO", _IOC_READ|_IOC_WRITE, 0x5511, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LIST", _IOC_READ|_IOC_WRITE, 0x5510, 0x48 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LOCK", _IOC_WRITE, 0x5514, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_READ", _IOC_READ|_IOC_WRITE, 0x5512, 0x2c8 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REMOVE", _IOC_READ|_IOC_WRITE, 0x5519, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REPLACE", _IOC_READ|_IOC_WRITE, 0x5518, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_UNLOCK", _IOC_WRITE, 0x5515, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_WRITE", _IOC_READ|_IOC_WRITE, 0x5513, 0x2c8 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_INFO", _IOC_READ, 0x5521, 0xdc },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5520, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_INFO", _IOC_READ|_IOC_WRITE, 0x5531, 0x120 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", _IOC_READ, 0x5530, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", _IOC_WRITE, 0x5532, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER", _IOC_READ|_IOC_WRITE, 0x55d0, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER_STATE", _IOC_READ, 0x55d1, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PVERSION", _IOC_READ, 0x5500, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_INFO", _IOC_READ|_IOC_WRITE, 0x5541, 0x10c },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5540, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", _IOC_WRITE, 0x5542, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", _IOC_READ|_IOC_WRITE, 0x5516, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_COMMAND", _IOC_READ|_IOC_WRITE, 0x551c, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_READ", _IOC_READ|_IOC_WRITE, 0x551a, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_WRITE", _IOC_READ|_IOC_WRITE, 0x551b, 0x08 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_LOAD", _IOC_WRITE, 0x4803, 0x50 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_STATUS", _IOC_READ, 0x4802, 0x40 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_INFO", _IOC_READ, 0x4801, 0xdc },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_PVERSION", _IOC_READ, 0x4800, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_CHANNEL_INFO", _IOC_READ, 0x4132, 0x10 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DELAY", _IOC_READ, 0x4121, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DRAIN", _IOC_NONE, 0x4144, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DROP", _IOC_NONE, 0x4143, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_FORWARD", _IOC_WRITE, 0x4149, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HWSYNC", _IOC_NONE, 0x4122, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_FREE", _IOC_NONE, 0x4112, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4111, 0x25c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_REFINE", _IOC_READ|_IOC_WRITE, 0x4110, 0x25c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_INFO", _IOC_READ, 0x4101, 0x120 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_LINK", _IOC_WRITE, 0x4160, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PAUSE", _IOC_WRITE, 0x4145, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PREPARE", _IOC_NONE, 0x4140, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PVERSION", _IOC_READ, 0x4100, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READI_FRAMES", _IOC_READ, 0x4151, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READN_FRAMES", _IOC_READ, 0x4153, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESET", _IOC_NONE, 0x4141, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESUME", _IOC_NONE, 0x4147, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_REWIND", _IOC_WRITE, 0x4146, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_START", _IOC_NONE, 0x4142, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS", _IOC_READ, 0x4120, 0x6c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS_EXT", _IOC_READ|_IOC_WRITE, 0x4124, 0x6c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4113, 0x68 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SYNC_PTR", _IOC_READ|_IOC_WRITE, 0x4123, 0x84 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TSTAMP", _IOC_WRITE, 0x4102, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TTSTAMP", _IOC_WRITE, 0x4103, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_UNLINK", _IOC_NONE, 0x4161, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEI_FRAMES", _IOC_WRITE, 0x4150, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEN_FRAMES", _IOC_WRITE, 0x4152, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_XRUN", _IOC_NONE, 0x4148, 0x00 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DRAIN", _IOC_WRITE, 0x5731, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DROP", _IOC_WRITE, 0x5730, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_INFO", _IOC_READ, 0x5701, 0x10c },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PARAMS", _IOC_READ|_IOC_WRITE, 0x5710, 0x20 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PVERSION", _IOC_READ, 0x5700, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_STATUS", _IOC_READ|_IOC_WRITE, 0x5720, 0x24 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_CONTINUE", _IOC_NONE, 0x54a2, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GINFO", _IOC_READ|_IOC_WRITE, 0x5403, 0xe0 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GPARAMS", _IOC_WRITE, 0x5404, 0x3c },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GSTATUS", _IOC_READ|_IOC_WRITE, 0x5405, 0x40 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_INFO", _IOC_READ, 0x5411, 0xe0 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5401, 0x14 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PARAMS", _IOC_WRITE, 0x5412, 0x50 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PAUSE", _IOC_NONE, 0x54a3, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PVERSION", _IOC_READ, 0x5400, 0x04 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_SELECT", _IOC_WRITE, 0x5410, 0x34 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_START", _IOC_NONE, 0x54a0, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STATUS", _IOC_READ, 0x5414, 0x58 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STOP", _IOC_NONE, 0x54a1, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_TREAD", _IOC_WRITE, 0x5402, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", _IOC_NONE, 0x4840, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_INFO", _IOC_READ, 0x4820, 0x02 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_PLAY_NOTE", _IOC_WRITE, 0x4822, 0x0c },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_RESET", _IOC_NONE, 0x4821, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_CONNECTION", _IOC_WRITE, 0x4826, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_MODE", _IOC_WRITE, 0x4825, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4824, 0x09 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_VOICE", _IOC_WRITE, 0x4823, 0x12 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_AVAIL", _IOC_READ, 0x4321, 0x1c },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_DRAIN", _IOC_NONE, 0x4334, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x4310, 0xc4 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CODEC_CAPS", _IOC_READ|_IOC_WRITE, 0x4311, 0x2b88 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_METADATA", _IOC_READ|_IOC_WRITE, 0x4315, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_PARAMS", _IOC_READ, 0x4313, 0x78 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_IOCTL_VERSION", _IOC_READ, 0x4300, 0x04 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_NEXT_TRACK", _IOC_NONE, 0x4335, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PARTIAL_DRAIN", _IOC_NONE, 0x4336, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PAUSE", _IOC_NONE, 0x4330, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_RESUME", _IOC_NONE, 0x4331, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_METADATA", _IOC_WRITE, 0x4314, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_PARAMS", _IOC_WRITE, 0x4312, 0x84 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_START", _IOC_NONE, 0x4332, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_STOP", _IOC_NONE, 0x4333, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_TSTAMP", _IOC_READ, 0x4320, 0x14 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_PEEK", _IOC_READ|_IOC_WRITE, 0x4812, 0x18c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_POKE", _IOC_WRITE, 0x4811, 0x18c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CONTINUE", _IOC_NONE, 0x4881, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_DBG_READ", _IOC_READ, 0x4884, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_INFO", _IOC_READ, 0x4810, 0x80c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_PEEK", _IOC_READ|_IOC_WRITE, 0x4831, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_POKE", _IOC_WRITE, 0x4830, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PVERSION", _IOC_READ, 0x4840, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", _IOC_WRITE, 0x4883, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_STOP", _IOC_NONE, 0x4880, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", _IOC_READ|_IOC_WRITE, 0x4822, 0x0c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_POKE", _IOC_WRITE, 0x4821, 0x0c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", _IOC_WRITE, 0x4820, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_GET_INFO", _IOC_READ, 0x48f8, 0x20 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_LOCK", _IOC_NONE, 0x48f9, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_UNLOCK", _IOC_NONE, 0x48fa, 0x00 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_GET_WCAP", _IOC_READ|_IOC_WRITE, 0x4812, 0x08 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_PVERSION", _IOC_READ, 0x4810, 0x04 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_VERB_WRITE", _IOC_READ|_IOC_WRITE, 0x4811, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_9632_AEB", _IOC_READ, 0x4845, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", _IOC_READ, 0x4841, 0x24 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x1000 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4840, 0x3b0 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_VERSION", _IOC_READ, 0x4843, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", _IOC_WRITE, 0x4842, 0x04 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_CONFIG", _IOC_READ, 0x4841, 0x18 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_LTC", _IOC_READ, 0x4846, 0x10 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x04 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4842, 0x908 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_STATUS", _IOC_READ, 0x4847, 0x20 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_VERSION", _IOC_READ, 0x4848, 0x24 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_INFO", _IOC_READ, 0x4810, 0x28 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_LOAD_CODE", _IOC_WRITE, 0x4811, 0x3012 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_PAUSE", _IOC_NONE, 0x4815, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_RESTART", _IOC_NONE, 0x4816, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_START", _IOC_WRITE, 0x4813, 0x08 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_STOP", _IOC_NONE, 0x4814, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", _IOC_NONE, 0x4812, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_LOAD_PATCH", _IOC_READ|_IOC_WRITE, 0x4881, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MEM_AVAIL", _IOC_WRITE, 0x4884, 0x04 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MISC_MODE", _IOC_READ|_IOC_WRITE, 0x4884, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", _IOC_NONE, 0x4883, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_RESET_SAMPLES", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_VERSION", _IOC_READ, 0x4880, 0x04 },
+{ "sound/usb_stream.h", "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4890, 0x10 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_NAME", _IOC_READ, 0x7702, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PIN_STATUS", _IOC_NONE, 0x7709, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PROT_MASK", _IOC_NONE, 0x7706, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_SIZE", _IOC_NONE, 0x7704, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_PIN", _IOC_WRITE, 0x7707, 0x08 },
+{ "staging/android/ashmem.h", "ASHMEM_PURGE_ALL_CACHES", _IOC_NONE, 0x770a, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_NAME", _IOC_WRITE, 0x7701, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_PROT_MASK", _IOC_WRITE, 0x7705, 0x04 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_SIZE", _IOC_WRITE, 0x7703, 0x04 },
+{ "staging/android/ashmem.h", "ASHMEM_UNPIN", _IOC_WRITE, 0x7708, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_ALLOC", _IOC_READ|_IOC_WRITE, 0x4900, 0x14 },
+{ "staging/android/ion.h", "ION_IOC_CUSTOM", _IOC_READ|_IOC_WRITE, 0x4906, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_FREE", _IOC_READ|_IOC_WRITE, 0x4901, 0x04 },
+{ "staging/android/ion.h", "ION_IOC_IMPORT", _IOC_READ|_IOC_WRITE, 0x4905, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_MAP", _IOC_READ|_IOC_WRITE, 0x4902, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SHARE", _IOC_READ|_IOC_WRITE, 0x4904, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SYNC", _IOC_READ|_IOC_WRITE, 0x4907, 0x08 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_DMA_MAPPING", _IOC_WRITE, 0x49f1, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_KERNEL_MAPPING", _IOC_WRITE, 0x49f2, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_SET_FD", _IOC_NONE, 0x49f0, 0x00 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_CREATE_FENCE", _IOC_READ|_IOC_WRITE, 0x5700, 0x28 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_INC", _IOC_WRITE, 0x5701, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_BRIGHTNESS", _IOC_READ, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_COLOR", _IOC_READ, 0x4605, 0x04 },
+{ "video/da8xx-fb.h", "FBIOGET_CONTRAST", _IOC_READ, 0x4601, 0x04 },
+{ "video/da8xx-fb.h", "FBIOPUT_CONTRAST", _IOC_WRITE, 0x4602, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_BRIGHTNESS", _IOC_WRITE, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_COLOR", _IOC_WRITE, 0x4606, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_HSYNC", _IOC_WRITE, 0x4609, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_VSYNC", _IOC_WRITE, 0x460a, 0x04 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_CREATE", _IOC_NONE, 0x6b00, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_OFFSET", _IOC_NONE, 0x6b04, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", _IOC_NONE, 0x6b01, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_SET_VIDEO_MODE", _IOC_NONE, 0x6b02, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_STRIDE", _IOC_NONE, 0x6b05, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_UVSTRIDE", _IOC_NONE, 0x6b03, 0x00 },
+{ "video/mbxfb.h", "MBXFB_IOCG_ALPHA", _IOC_READ, 0xf401, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_ALPHA", _IOC_WRITE, 0xf402, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_PLANEORDER", _IOC_READ, 0xf403, 0x02 },
+{ "video/mbxfb.h", "MBXFB_IOCS_REG", _IOC_WRITE, 0xf404, 0x0c },
+{ "video/mbxfb.h", "MBXFB_IOCX_OVERLAY", _IOC_READ|_IOC_WRITE, 0xf400, 0x30 },
+{ "video/mbxfb.h", "MBXFB_IOCX_REG", _IOC_READ|_IOC_WRITE, 0xf405, 0x0c },
+{ "video/sisfb.h", "SISFB_COMMAND", _IOC_READ|_IOC_WRITE, 0xf305, 0x54 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE", _IOC_READ, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE_OLD", _IOC_READ, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO", _IOC_READ, 0xf301, 0x11c },
+{ "video/sisfb.h", "SISFB_GET_INFO_OLD", _IOC_READ, 0x6ef8, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO_SIZE", _IOC_READ, 0xf300, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_TVPOSOFFSET", _IOC_READ, 0xf304, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS", _IOC_READ, 0xf302, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS_OLD", _IOC_READ, 0x6ef9, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE", _IOC_WRITE, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE_OLD", _IOC_WRITE, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_LOCK", _IOC_WRITE, 0xf306, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_TVPOSOFFSET", _IOC_WRITE, 0xf304, 0x04 },
+{ "video/sstfb.h", "SSTFB_GET_VGAPASS", _IOC_READ, 0x46dd, 0x04 },
+{ "video/sstfb.h", "SSTFB_SET_VGAPASS", _IOC_WRITE, 0x46dd, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_INTERDOMAIN", _IOC_NONE, 0x4501, 0x08 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_UNBOUND_PORT", _IOC_NONE, 0x4502, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_VIRQ", _IOC_NONE, 0x4500, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_NOTIFY", _IOC_NONE, 0x4504, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
+{ "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 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_MAX_GRANTS", _IOC_NONE, 0x4703, 0x04 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", _IOC_NONE, 0x4707, 0x10 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_UNMAP_GRANT_REF", _IOC_NONE, 0x4701, 0x10 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_EVTCHN", _IOC_NONE, 0x4200, 0x00 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_SETUP", _IOC_NONE, 0x4201, 0x00 },
diff --git a/strace/linux/32/syscallent.h b/strace/linux/32/syscallent.h
new file mode 100644
index 0000000..9c86485
--- /dev/null
+++ b/strace/linux/32/syscallent.h
@@ -0,0 +1,283 @@
+#ifndef sys_ARCH_mmap
+# define sys_ARCH_mmap sys_mmap
+#endif
+[  0] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[  1] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[  2] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[  3] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[  4] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[  5] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[  6] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[  7] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[  8] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[  9] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[ 10] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[ 11] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[ 12] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[ 13] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[ 14] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[ 15] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[ 16] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[ 17] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[ 18] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[ 19] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[ 20] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[ 21] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[ 22] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[ 23] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 24] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[ 25] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[ 26] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[ 27] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[ 28] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[ 29] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 30] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[ 31] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[ 32] = { 2,	TD,		SEN(flock),			"flock"			},
+[ 33] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[ 34] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[ 35] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[ 36] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[ 37] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[ 38] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[ 39] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 40] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 41] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[ 42] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[ 43] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[ 44] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[ 45] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[ 46] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[ 47] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[ 48] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[ 49] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 50] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 51] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 52] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 53] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[ 54] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[ 55] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 56] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[ 57] = { 1,	TD,		SEN(close),			"close"			},
+[ 58] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[ 59] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[ 60] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[ 61] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[ 62] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[ 63] = { 3,	TD,		SEN(read),			"read"			},
+[ 64] = { 3,	TD,		SEN(write),			"write"			},
+[ 65] = { 3,	TD,		SEN(readv),			"readv"			},
+[ 66] = { 3,	TD,		SEN(writev),			"writev"		},
+[ 67] = { 5,	TD,		SEN(pread),			"pread64"		},
+[ 68] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 69] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[ 70] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[ 71] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[ 72] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[ 73] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[ 74] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[ 75] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[ 76] = { 6,	TD,		SEN(splice),			"splice"		},
+[ 77] = { 4,	TD,		SEN(tee),			"tee"			},
+[ 78] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[ 79] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[ 80] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[ 81] = { 0,	0,		SEN(sync),			"sync"			},
+[ 82] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 83] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+#ifdef ARCH_WANT_SYNC_FILE_RANGE2
+[ 84] = { 6,	TD,		SEN(sync_file_range2),		"sync_file_range2"	},
+#else
+[ 84] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+#endif
+[ 85] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[ 86] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[ 87] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[ 88] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[ 89] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 90] = { 2,	0,		SEN(capget),			"capget"		},
+[ 91] = { 2,	0,		SEN(capset),			"capset"		},
+[ 92] = { 1,	NF,		SEN(personality),		"personality"		},
+[ 93] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[ 94] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[ 95] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[ 96] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[ 97] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[ 98] = { 6,	0,		SEN(futex),			"futex"			},
+[ 99] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[100] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[101] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[102] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[103] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[104] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[105] = { 3,	0,		SEN(init_module),		"init_module"		},
+[106] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[107] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[108] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[109] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[110] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[111] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[112] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[113] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[114] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[115] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[116] = { 3,	0,		SEN(syslog),			"syslog"		},
+[117] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[118] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[119] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[120] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[121] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[122] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[123] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[124] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[125] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[126] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[127] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[128] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[129] = { 2,	TS,		SEN(kill),			"kill"			},
+[130] = { 2,	TS,		SEN(kill),			"tkill"			},
+[131] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[132] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[133] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[134] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[135] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[136] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[137] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[138] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[139] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[140] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[141] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[142] = { 4,	0,		SEN(reboot),			"reboot"		},
+[143] = { 2,	0,		SEN(setregid),			"setregid"		},
+[144] = { 1,	0,		SEN(setgid),			"setgid"		},
+[145] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[146] = { 1,	0,		SEN(setuid),			"setuid"		},
+[147] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[148] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[149] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[150] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[151] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[152] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[153] = { 1,	0,		SEN(times),			"times"			},
+[154] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[155] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[156] = { 1,	0,		SEN(getsid),			"getsid"		},
+[157] = { 0,	0,		SEN(setsid),			"setsid"		},
+[158] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[159] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[160] = { 1,	0,		SEN(uname),			"uname"			},
+[161] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[162] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[163] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[164] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[165] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[166] = { 1,	NF,		SEN(umask),			"umask"			},
+[167] = { 5,	0,		SEN(prctl),			"prctl"			},
+[168] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[169] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[170] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[171] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[172] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[173] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[174] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[175] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[176] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[177] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[178] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[179] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[180] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[181] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[182] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[183] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[184] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[185] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[186] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[187] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[188] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[189] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[190] = { 3,	TI,		SEN(semget),			"semget"		},
+[191] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[192] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[193] = { 3,	TI,		SEN(semop),			"semop"			},
+[194] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[195] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[196] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[197] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[198] = { 3,	TN,		SEN(socket),			"socket"		},
+[199] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[200] = { 3,	TN,		SEN(bind),			"bind"			},
+[201] = { 2,	TN,		SEN(listen),			"listen"		},
+[202] = { 3,	TN,		SEN(accept),			"accept"		},
+[203] = { 3,	TN,		SEN(connect),			"connect"		},
+[204] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[205] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[206] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[207] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[208] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[209] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[210] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[211] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[212] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[213] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[214] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[215] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[216] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[217] = { 5,	0,		SEN(add_key),			"add_key"		},
+[218] = { 4,	0,		SEN(request_key),		"request_key"		},
+[219] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[220] = { 5,	TP,		SEN(clone),			"clone"			},
+[221] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[222] = { 6,	TD|TM|SI,	SEN(ARCH_mmap),			"mmap2"			},
+[223] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[224] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[225] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[226] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[227] = { 3,	TM,		SEN(msync),			"msync"			},
+[228] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[229] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[230] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[231] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[232] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[233] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[234] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[235] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[236] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[237] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[238] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[239] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[240] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[241] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[242] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[243] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+/* [244 ... 259] are arch specific */
+[260] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[261] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[262] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[263] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[264] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[265] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[266] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[267] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[268] = { 2,	TD,		SEN(setns),			"setns"			},
+[269] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[270] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[271] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[272] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[273] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[274] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[275] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[276] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[277] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[278] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[279] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[280] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[281] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[282] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[283] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[284] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[285] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[286] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[287] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#undef sys_ARCH_mmap
+#undef ARCH_WANT_SYNC_FILE_RANGE2
diff --git a/strace/linux/64/ioctls_inc.h b/strace/linux/64/ioctls_inc.h
new file mode 100644
index 0000000..69cebac
--- /dev/null
+++ b/strace/linux/64/ioctls_inc.h
@@ -0,0 +1,2824 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/include/ tree. */
+{ "acpi/apei.h", "APEI_ERST_CLEAR_RECORD", _IOC_WRITE, 0x4501, 0x08 },
+{ "acpi/apei.h", "APEI_ERST_GET_RECORD_COUNT", _IOC_READ, 0x4502, 0x04 },
+{ "asm-generic/ioctls.h", "FIOASYNC", 0, 0x5452, 0 },
+{ "asm-generic/ioctls.h", "FIOCLEX", 0, 0x5451, 0 },
+{ "asm-generic/ioctls.h", "FIONBIO", 0, 0x5421, 0 },
+{ "asm-generic/ioctls.h", "FIONCLEX", 0, 0x5450, 0 },
+{ "asm-generic/ioctls.h", "FIONREAD", 0, 0x541B, 0 },
+{ "asm-generic/ioctls.h", "FIOQSIZE", 0, 0x5460, 0 },
+{ "asm-generic/ioctls.h", "TCFLSH", 0, 0x540B, 0 },
+{ "asm-generic/ioctls.h", "TCGETA", 0, 0x5405, 0 },
+{ "asm-generic/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm-generic/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm-generic/ioctls.h", "TCGETX", 0, 0x5432, 0 },
+{ "asm-generic/ioctls.h", "TCSBRK", 0, 0x5409, 0 },
+{ "asm-generic/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm-generic/ioctls.h", "TCSETA", 0, 0x5406, 0 },
+{ "asm-generic/ioctls.h", "TCSETAF", 0, 0x5408, 0 },
+{ "asm-generic/ioctls.h", "TCSETAW", 0, 0x5407, 0 },
+{ "asm-generic/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm-generic/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm-generic/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm-generic/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETX", 0, 0x5433, 0 },
+{ "asm-generic/ioctls.h", "TCSETXF", 0, 0x5434, 0 },
+{ "asm-generic/ioctls.h", "TCSETXW", 0, 0x5435, 0 },
+{ "asm-generic/ioctls.h", "TCXONC", 0, 0x540A, 0 },
+{ "asm-generic/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm-generic/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm-generic/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm-generic/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm-generic/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm-generic/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPGRP", 0, 0x540F, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGRS485", 0, 0x542E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSID", 0, 0x5429, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm-generic/ioctls.h", "TIOCGWINSZ", 0, 0x5413, 0 },
+{ "asm-generic/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm-generic/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm-generic/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm-generic/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm-generic/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm-generic/ioctls.h", "TIOCOUTQ", 0, 0x5411, 0 },
+{ "asm-generic/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm-generic/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm-generic/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm-generic/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm-generic/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPGRP", 0, 0x5410, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSRS485", 0, 0x542F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm-generic/ioctls.h", "TIOCSWINSZ", 0, 0x5414, 0 },
+{ "asm-generic/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm-generic/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm-generic/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm-generic/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm-generic/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm-generic/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_BO_LIST", _IOC_READ|_IOC_WRITE, 0x6443, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CS", _IOC_READ|_IOC_WRITE, 0x6444, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CTX", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_METADATA", _IOC_READ|_IOC_WRITE, 0x6446, 0x120 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x08 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_OP", _IOC_READ|_IOC_WRITE, 0x6450, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6451, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_VA", _IOC_WRITE, 0x6448, 0x28 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_INFO", _IOC_WRITE, 0x6445, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_WAIT_CS", _IOC_READ|_IOC_WRITE, 0x6449, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_BUFS", _IOC_READ|_IOC_WRITE, 0x6416, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_CTX", _IOC_READ|_IOC_WRITE, 0x6420, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_DRAW", _IOC_READ|_IOC_WRITE, 0x6427, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_MAP", _IOC_READ|_IOC_WRITE, 0x6415, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ACQUIRE", _IOC_NONE, 0x6430, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6434, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_BIND", _IOC_WRITE, 0x6436, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ENABLE", _IOC_WRITE, 0x6432, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_FREE", _IOC_WRITE, 0x6435, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_INFO", _IOC_READ, 0x6433, 0x38 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_RELEASE", _IOC_NONE, 0x6431, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_UNBIND", _IOC_WRITE, 0x6437, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AUTH_MAGIC", _IOC_WRITE, 0x6411, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_BLOCK", _IOC_READ|_IOC_WRITE, 0x6412, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_CONTROL", _IOC_WRITE, 0x6414, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_DMA", _IOC_READ|_IOC_WRITE, 0x6429, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_DROP_MASTER", _IOC_NONE, 0x641f, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_FINISH", _IOC_WRITE, 0x642c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_FREE_BUFS", _IOC_WRITE, 0x641a, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_CLOSE", _IOC_WRITE, 0x6409, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_FLINK", _IOC_READ|_IOC_WRITE, 0x640a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_OPEN", _IOC_READ|_IOC_WRITE, 0x640b, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CAP", _IOC_READ|_IOC_WRITE, 0x640c, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CLIENT", _IOC_READ|_IOC_WRITE, 0x6405, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CTX", _IOC_READ|_IOC_WRITE, 0x6423, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAGIC", _IOC_READ, 0x6402, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAP", _IOC_READ|_IOC_WRITE, 0x6404, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_GET_SAREA_CTX", _IOC_READ|_IOC_WRITE, 0x641d, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_STATS", _IOC_READ, 0x6406, 0xf8 },
+{ "drm/drm.h", "DRM_IOCTL_GET_UNIQUE", _IOC_READ|_IOC_WRITE, 0x6401, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_INFO_BUFS", _IOC_READ|_IOC_WRITE, 0x6418, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_IRQ_BUSID", _IOC_READ|_IOC_WRITE, 0x6403, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_LOCK", _IOC_WRITE, 0x642a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MAP_BUFS", _IOC_READ|_IOC_WRITE, 0x6419, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MARK_BUFS", _IOC_WRITE, 0x6417, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODESET_CTL", _IOC_WRITE, 0x6408, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB", _IOC_READ|_IOC_WRITE, 0x64ae, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB2", _IOC_READ|_IOC_WRITE, 0x64b8, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATOMIC", _IOC_READ|_IOC_WRITE, 0x64bc, 0x38 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATTACHMODE", _IOC_READ|_IOC_WRITE, 0x64a8, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATEPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64bd, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATE_DUMB", _IOC_READ|_IOC_WRITE, 0x64b2, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR", _IOC_READ|_IOC_WRITE, 0x64a3, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR2", _IOC_READ|_IOC_WRITE, 0x64bb, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROYPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64be, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROY_DUMB", _IOC_READ|_IOC_WRITE, 0x64b4, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DETACHMODE", _IOC_READ|_IOC_WRITE, 0x64a9, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DIRTYFB", _IOC_READ|_IOC_WRITE, 0x64b1, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCONNECTOR", _IOC_READ|_IOC_WRITE, 0x64a7, 0x50 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCRTC", _IOC_READ|_IOC_WRITE, 0x64a1, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETENCODER", _IOC_READ|_IOC_WRITE, 0x64a6, 0x14 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETFB", _IOC_READ|_IOC_WRITE, 0x64ad, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a4, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANE", _IOC_READ|_IOC_WRITE, 0x64b6, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANERESOURCES", _IOC_READ|_IOC_WRITE, 0x64b5, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64ac, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64aa, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETRESOURCES", _IOC_READ|_IOC_WRITE, 0x64a0, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_MAP_DUMB", _IOC_READ|_IOC_WRITE, 0x64b3, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", _IOC_READ|_IOC_WRITE, 0x64b9, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ba, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_PAGE_FLIP", _IOC_READ|_IOC_WRITE, 0x64b0, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_RMFB", _IOC_READ|_IOC_WRITE, 0x64af, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETCRTC", _IOC_READ|_IOC_WRITE, 0x64a2, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a5, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPLANE", _IOC_READ|_IOC_WRITE, 0x64b7, 0x30 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ab, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MOD_CTX", _IOC_WRITE, 0x6422, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_NEW_CTX", _IOC_WRITE, 0x6425, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_FD_TO_HANDLE", _IOC_READ|_IOC_WRITE, 0x642e, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_HANDLE_TO_FD", _IOC_READ|_IOC_WRITE, 0x642d, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_RES_CTX", _IOC_READ|_IOC_WRITE, 0x6426, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_RM_CTX", _IOC_READ|_IOC_WRITE, 0x6421, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_DRAW", _IOC_READ|_IOC_WRITE, 0x6428, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_RM_MAP", _IOC_WRITE, 0x641b, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_SET_CLIENT_CAP", _IOC_WRITE, 0x640d, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SET_MASTER", _IOC_NONE, 0x641e, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_SET_SAREA_CTX", _IOC_WRITE, 0x641c, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SET_UNIQUE", _IOC_WRITE, 0x6410, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SET_VERSION", _IOC_READ|_IOC_WRITE, 0x6407, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SG_ALLOC", _IOC_READ|_IOC_WRITE, 0x6438, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SG_FREE", _IOC_WRITE, 0x6439, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SWITCH_CTX", _IOC_WRITE, 0x6424, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UNBLOCK", _IOC_READ|_IOC_WRITE, 0x6413, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_UNLOCK", _IOC_WRITE, 0x642b, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UPDATE_DRAW", _IOC_WRITE, 0x643f, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x6400, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_WAIT_VBLANK", _IOC_READ|_IOC_WRITE, 0x643a, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x30 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6448, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_WAIT", _IOC_WRITE, 0x6449, 0x20 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x20 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_EXEC", _IOC_READ|_IOC_WRITE, 0x6462, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_GET_VER", _IOC_READ|_IOC_WRITE, 0x6460, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", _IOC_READ|_IOC_WRITE, 0x6461, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_GET", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", _IOC_READ|_IOC_WRITE, 0x6473, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6470, 0x50 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", _IOC_READ|_IOC_WRITE, 0x6472, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6471, 0x60 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_CLEAR", _IOC_WRITE, 0x6442, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_COPY", _IOC_WRITE, 0x6447, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_DOCOPY", _IOC_NONE, 0x6448, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLIP", _IOC_NONE, 0x644e, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLUSH", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FSTATUS", _IOC_NONE, 0x644a, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETAGE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETBUF", _IOC_READ|_IOC_WRITE, 0x6445, 0x18 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_INIT", _IOC_WRITE, 0x6440, 0x40 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_MC", _IOC_WRITE, 0x644c, 0x20 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0FLIP", _IOC_NONE, 0x644b, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0INFO", _IOC_READ, 0x6449, 0x08 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_RSTATUS", _IOC_NONE, 0x644d, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_SWAP", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_VERTEX", _IOC_WRITE, 0x6441, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_ALLOC", _IOC_READ|_IOC_WRITE, 0x6448, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_BATCHBUFFER", _IOC_WRITE, 0x6443, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_CMDBUFFER", _IOC_WRITE, 0x644b, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_DESTROY_HEAP", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLIP", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLUSH", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FREE", _IOC_WRITE, 0x6449, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x6457, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", _IOC_READ|_IOC_WRITE, 0x646d, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", _IOC_WRITE, 0x646e, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6474, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", _IOC_READ|_IOC_WRITE, 0x6475, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645b, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_ENTERVT", _IOC_NONE, 0x6459, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER", _IOC_WRITE, 0x6454, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER2", _IOC_WRITE, 0x6469, 0x40 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_APERTURE", _IOC_READ, 0x6463, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_CACHING", _IOC_READ|_IOC_WRITE, 0x6470, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6462, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_INIT", _IOC_WRITE, 0x6453, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_LEAVEVT", _IOC_NONE, 0x645a, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MADVISE", _IOC_READ|_IOC_WRITE, 0x6466, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP_GTT", _IOC_READ|_IOC_WRITE, 0x6464, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PIN", _IOC_READ|_IOC_WRITE, 0x6455, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PREAD", _IOC_WRITE, 0x645c, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PWRITE", _IOC_WRITE, 0x645d, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_CACHING", _IOC_WRITE, 0x646f, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_DOMAIN", _IOC_WRITE, 0x645f, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6461, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SW_FINISH", _IOC_WRITE, 0x6460, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_THROTTLE", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_UNPIN", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6473, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_WAIT", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6446, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", _IOC_READ|_IOC_WRITE, 0x6465, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_RESET_STATS", _IOC_READ|_IOC_WRITE, 0x6472, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646a, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_VBLANK_PIPE", _IOC_READ, 0x644e, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_HWS_ADDR", _IOC_WRITE, 0x6451, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT", _IOC_WRITE, 0x6440, 0x44 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT_HEAP", _IOC_WRITE, 0x644a, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_WAIT", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_ATTRS", _IOC_READ|_IOC_WRITE, 0x6468, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", _IOC_WRITE, 0x6467, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_REG_READ", _IOC_READ|_IOC_WRITE, 0x6471, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SETPARAM", _IOC_WRITE, 0x6447, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646b, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_VBLANK_PIPE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_VBLANK_SWAP", _IOC_READ|_IOC_WRITE, 0x644f, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_BLIT", _IOC_WRITE, 0x6448, 0x34 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_CLEAR", _IOC_WRITE, 0x6444, 0x14 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_DMA_BOOTSTRAP", _IOC_READ|_IOC_WRITE, 0x644c, 0x20 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_FLUSH", _IOC_WRITE, 0x6441, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6449, 0x10 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_ILOAD", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INDICES", _IOC_WRITE, 0x6446, 0x10 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INIT", _IOC_WRITE, 0x6440, 0x80 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_RESET", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SET_FENCE", _IOC_WRITE, 0x644a, 0x04 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SWAP", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_VERTEX", _IOC_WRITE, 0x6445, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_WAIT_FENCE", _IOC_READ|_IOC_WRITE, 0x644b, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x20 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x18 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", _IOC_WRITE, 0x6483, 0x04 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", _IOC_WRITE, 0x6482, 0x08 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6484, 0x28 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6480, 0x30 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", _IOC_READ|_IOC_WRITE, 0x6481, 0x40 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x08 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_SET_PARAM", _IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC", _IOC_READ|_IOC_WRITE, 0x6440, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC_SURF", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_CLIENTCAP", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_EXECBUFFER", _IOC_WRITE, 0x6442, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_UPDATE_AREA", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_BLIT", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CLEAR", _IOC_WRITE, 0x6448, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_DEPTH", _IOC_WRITE, 0x644c, 0x28 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FLIP", _IOC_NONE, 0x6453, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FULLSCREEN", _IOC_WRITE, 0x6450, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6452, 0x10 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644f, 0x10 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INIT", _IOC_WRITE, 0x6440, 0x78 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_RESET", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_STIPPLE", _IOC_WRITE, 0x644d, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_ALLOC", _IOC_READ|_IOC_WRITE, 0x6453, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CLEAR", _IOC_WRITE, 0x6448, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CMDBUF", _IOC_WRITE, 0x6450, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_INIT", _IOC_WRITE, 0x6440, 0x78 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESUME", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CS", _IOC_READ|_IOC_WRITE, 0x6466, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FLIP", _IOC_NONE, 0x6452, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FREE", _IOC_WRITE, 0x6454, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FULLSCREEN", _IOC_WRITE, 0x6446, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x646a, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645d, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6469, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x645c, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_OP", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PREAD", _IOC_READ|_IOC_WRITE, 0x6461, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PWRITE", _IOC_READ|_IOC_WRITE, 0x6462, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", _IOC_READ|_IOC_WRITE, 0x6463, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6468, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x646d, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_VA", _IOC_READ|_IOC_WRITE, 0x646b, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", _IOC_WRITE, 0x6464, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6451, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INFO", _IOC_READ|_IOC_WRITE, 0x6467, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INIT_HEAP", _IOC_WRITE, 0x6455, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6456, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_WAIT", _IOC_WRITE, 0x6457, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_RESET", _IOC_NONE, 0x6445, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SETPARAM", _IOC_WRITE, 0x6459, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_STIPPLE", _IOC_WRITE, 0x644c, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_ALLOC", _IOC_WRITE, 0x645a, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_FREE", _IOC_WRITE, 0x645b, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_TEXTURE", _IOC_READ|_IOC_WRITE, 0x644e, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX2", _IOC_WRITE, 0x644f, 0x28 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_CMDBUF", _IOC_WRITE, 0x6441, 0x38 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", _IOC_WRITE, 0x6443, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_INIT", _IOC_WRITE, 0x6440, 0x60 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6454, 0x20 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_FREE", _IOC_WRITE, 0x6455, 0x20 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6453, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_ALLOC", _IOC_READ|_IOC_WRITE, 0x6444, 0x20 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_FREE", _IOC_WRITE, 0x6445, 0x20 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_INIT", _IOC_WRITE, 0x6456, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6446, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644d, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x644b, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644c, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x644a, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", _IOC_READ|_IOC_WRITE, 0x6449, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_OPEN_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x58 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_INCR", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_READ", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_WAIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_BO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_SHADER_BO", _IOC_READ|_IOC_WRITE, 0x6445, 0x18 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_GET_HANG_STATE", _IOC_READ|_IOC_WRITE, 0x6446, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_MMAP_BO", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_SUBMIT_CL", _IOC_READ|_IOC_WRITE, 0x6440, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_BO", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_SEQNO", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_ALLOCMEM", _IOC_READ|_IOC_WRITE, 0x6440, 0x20 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_BLIT_SYNC", _IOC_WRITE, 0x644f, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUFFER", _IOC_WRITE, 0x6448, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUF_SIZE", _IOC_READ|_IOC_WRITE, 0x644b, 0x0c },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DEC_FUTEX", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_BLIT", _IOC_WRITE, 0x644e, 0x30 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_INIT", _IOC_READ|_IOC_WRITE, 0x6447, 0x20 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FB_INIT", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FLUSH", _IOC_NONE, 0x6449, 0x00 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FREEMEM", _IOC_WRITE, 0x6441, 0x20 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_MAP_INIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x28 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_PCICMD", _IOC_WRITE, 0x644a, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_WAIT_IRQ", _IOC_READ|_IOC_WRITE, 0x644d, 0x18 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_EXECBUFFER", _IOC_WRITE, 0x6442, 0x20 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x6449, 0x18 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", _IOC_READ|_IOC_WRITE, 0x6444, 0x38 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", _IOC_READ|_IOC_WRITE, 0x6446, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", _IOC_READ|_IOC_WRITE, 0x6447, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_WAIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_ACQUIRE", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x4106, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_BIND", _IOC_WRITE, 0x4108, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_CHIPSET_FLUSH", _IOC_NONE, 0x410a, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_DEALLOCATE", _IOC_WRITE, 0x4107, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_INFO", _IOC_READ, 0x4100, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_PROTECT", _IOC_WRITE, 0x4105, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_RELEASE", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_RESERVE", _IOC_WRITE, 0x4104, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_SETUP", _IOC_WRITE, 0x4103, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_UNBIND", _IOC_WRITE, 0x4109, 0x08 },
+{ "linux/am437x-vpfe.h", "VIDIOC_AM437X_CCDC_CFG", _IOC_WRITE, 0x56c1, 0x08 },
+{ "linux/android/binder.h", "BC_ACQUIRE", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE_DONE", _IOC_WRITE, 0x6309, 0x10 },
+{ "linux/android/binder.h", "BC_ACQUIRE_RESULT", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/android/binder.h", "BC_ATTEMPT_ACQUIRE", _IOC_WRITE, 0x630a, 0x08 },
+{ "linux/android/binder.h", "BC_CLEAR_DEATH_NOTIFICATION", _IOC_WRITE, 0x630f, 0x0c },
+{ "linux/android/binder.h", "BC_DEAD_BINDER_DONE", _IOC_WRITE, 0x6310, 0x08 },
+{ "linux/android/binder.h", "BC_DECREFS", _IOC_WRITE, 0x6307, 0x04 },
+{ "linux/android/binder.h", "BC_ENTER_LOOPER", _IOC_NONE, 0x630c, 0x00 },
+{ "linux/android/binder.h", "BC_EXIT_LOOPER", _IOC_NONE, 0x630d, 0x00 },
+{ "linux/android/binder.h", "BC_FREE_BUFFER", _IOC_WRITE, 0x6303, 0x08 },
+{ "linux/android/binder.h", "BC_INCREFS", _IOC_WRITE, 0x6304, 0x04 },
+{ "linux/android/binder.h", "BC_INCREFS_DONE", _IOC_WRITE, 0x6308, 0x10 },
+{ "linux/android/binder.h", "BC_REGISTER_LOOPER", _IOC_NONE, 0x630b, 0x00 },
+{ "linux/android/binder.h", "BC_RELEASE", _IOC_WRITE, 0x6306, 0x04 },
+{ "linux/android/binder.h", "BC_REPLY", _IOC_WRITE, 0x6301, 0x40 },
+{ "linux/android/binder.h", "BC_REQUEST_DEATH_NOTIFICATION", _IOC_WRITE, 0x630e, 0x0c },
+{ "linux/android/binder.h", "BC_TRANSACTION", _IOC_WRITE, 0x6300, 0x40 },
+{ "linux/android/binder.h", "BINDER_SET_CONTEXT_MGR", _IOC_WRITE, 0x6207, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_PRIORITY", _IOC_WRITE, 0x6206, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_TIMEOUT", _IOC_WRITE, 0x6203, 0x08 },
+{ "linux/android/binder.h", "BINDER_SET_MAX_THREADS", _IOC_WRITE, 0x6205, 0x04 },
+{ "linux/android/binder.h", "BINDER_THREAD_EXIT", _IOC_WRITE, 0x6208, 0x04 },
+{ "linux/android/binder.h", "BINDER_VERSION", _IOC_READ|_IOC_WRITE, 0x6209, 0x04 },
+{ "linux/android/binder.h", "BINDER_WRITE_READ", _IOC_READ|_IOC_WRITE, 0x6201, 0x30 },
+{ "linux/android/binder.h", "BR_ACQUIRE", _IOC_READ, 0x7208, 0x10 },
+{ "linux/android/binder.h", "BR_ACQUIRE_RESULT", _IOC_READ, 0x7204, 0x04 },
+{ "linux/android/binder.h", "BR_ATTEMPT_ACQUIRE", _IOC_READ, 0x720b, 0x18 },
+{ "linux/android/binder.h", "BR_CLEAR_DEATH_NOTIFICATION_DONE", _IOC_READ, 0x7210, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_BINDER", _IOC_READ, 0x720f, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_REPLY", _IOC_NONE, 0x7205, 0x00 },
+{ "linux/android/binder.h", "BR_DECREFS", _IOC_READ, 0x720a, 0x10 },
+{ "linux/android/binder.h", "BR_ERROR", _IOC_READ, 0x7200, 0x04 },
+{ "linux/android/binder.h", "BR_FAILED_REPLY", _IOC_NONE, 0x7211, 0x00 },
+{ "linux/android/binder.h", "BR_FINISHED", _IOC_NONE, 0x720e, 0x00 },
+{ "linux/android/binder.h", "BR_INCREFS", _IOC_READ, 0x7207, 0x10 },
+{ "linux/android/binder.h", "BR_NOOP", _IOC_NONE, 0x720c, 0x00 },
+{ "linux/android/binder.h", "BR_OK", _IOC_NONE, 0x7201, 0x00 },
+{ "linux/android/binder.h", "BR_RELEASE", _IOC_READ, 0x7209, 0x10 },
+{ "linux/android/binder.h", "BR_REPLY", _IOC_READ, 0x7203, 0x40 },
+{ "linux/android/binder.h", "BR_SPAWN_LOOPER", _IOC_NONE, 0x720d, 0x00 },
+{ "linux/android/binder.h", "BR_TRANSACTION", _IOC_READ, 0x7202, 0x40 },
+{ "linux/android/binder.h", "BR_TRANSACTION_COMPLETE", _IOC_NONE, 0x7206, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_STANDBY", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_SUSPEND", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/arcfb.h", "FBIO_GETCONTROL2", _IOC_READ, 0x4689, 0x08 },
+{ "linux/arcfb.h", "FBIO_WAITEVENT", _IOC_NONE, 0x4688, 0x00 },
+{ "linux/atm_eni.h", "ENI_MEMDUMP", _IOC_WRITE, 0x6160, 0x10 },
+{ "linux/atm_eni.h", "ENI_SETMULT", _IOC_WRITE, 0x6167, 0x10 },
+{ "linux/atm_he.h", "HE_GET_REG", _IOC_WRITE, 0x6160, 0x10 },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTAT", _IOC_WRITE, 0x6132, 0x10 },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTATZ", _IOC_WRITE, 0x6133, 0x10 },
+{ "linux/atm_nicstar.h", "NS_ADJBUFLEV", _IOC_NONE, 0x6163, 0x00 },
+{ "linux/atm_nicstar.h", "NS_GETPSTAT", _IOC_READ|_IOC_WRITE, 0x6161, 0x10 },
+{ "linux/atm_nicstar.h", "NS_SETBUFLEV", _IOC_WRITE, 0x6162, 0x10 },
+{ "linux/atm_tcp.h", "ATMTCP_CREATE", _IOC_NONE, 0x618e, 0x00 },
+{ "linux/atm_tcp.h", "ATMTCP_REMOVE", _IOC_NONE, 0x618f, 0x00 },
+{ "linux/atm_tcp.h", "SIOCSIFATMTCP", _IOC_NONE, 0x6180, 0x00 },
+{ "linux/atm_zatm.h", "ZATM_GETPOOL", _IOC_WRITE, 0x6161, 0x10 },
+{ "linux/atm_zatm.h", "ZATM_GETPOOLZ", _IOC_WRITE, 0x6162, 0x10 },
+{ "linux/atm_zatm.h", "ZATM_SETPOOL", _IOC_WRITE, 0x6163, 0x10 },
+{ "linux/atmarp.h", "ATMARPD_CTRL", _IOC_NONE, 0x61e1, 0x00 },
+{ "linux/atmarp.h", "ATMARP_ENCAP", _IOC_NONE, 0x61e5, 0x00 },
+{ "linux/atmarp.h", "ATMARP_MKIP", _IOC_NONE, 0x61e2, 0x00 },
+{ "linux/atmarp.h", "ATMARP_SETENTRY", _IOC_NONE, 0x61e3, 0x00 },
+{ "linux/atmbr2684.h", "BR2684_SETFILT", _IOC_WRITE, 0x6190, 0x1c },
+{ "linux/atmclip.h", "SIOCMKCLIP", _IOC_NONE, 0x61e0, 0x00 },
+{ "linux/atmdev.h", "ATM_ADDADDR", _IOC_WRITE, 0x6188, 0x10 },
+{ "linux/atmdev.h", "ATM_ADDLECSADDR", _IOC_WRITE, 0x618e, 0x10 },
+{ "linux/atmdev.h", "ATM_ADDPARTY", _IOC_WRITE, 0x61f4, 0x10 },
+{ "linux/atmdev.h", "ATM_DELADDR", _IOC_WRITE, 0x6189, 0x10 },
+{ "linux/atmdev.h", "ATM_DELLECSADDR", _IOC_WRITE, 0x618f, 0x10 },
+{ "linux/atmdev.h", "ATM_DROPPARTY", _IOC_WRITE, 0x61f5, 0x04 },
+{ "linux/atmdev.h", "ATM_GETADDR", _IOC_WRITE, 0x6186, 0x10 },
+{ "linux/atmdev.h", "ATM_GETCIRANGE", _IOC_WRITE, 0x618a, 0x10 },
+{ "linux/atmdev.h", "ATM_GETESI", _IOC_WRITE, 0x6185, 0x10 },
+{ "linux/atmdev.h", "ATM_GETLECSADDR", _IOC_WRITE, 0x6190, 0x10 },
+{ "linux/atmdev.h", "ATM_GETLINKRATE", _IOC_WRITE, 0x6181, 0x10 },
+{ "linux/atmdev.h", "ATM_GETLOOP", _IOC_WRITE, 0x6152, 0x10 },
+{ "linux/atmdev.h", "ATM_GETNAMES", _IOC_WRITE, 0x6183, 0x10 },
+{ "linux/atmdev.h", "ATM_GETSTAT", _IOC_WRITE, 0x6150, 0x10 },
+{ "linux/atmdev.h", "ATM_GETSTATZ", _IOC_WRITE, 0x6151, 0x10 },
+{ "linux/atmdev.h", "ATM_GETTYPE", _IOC_WRITE, 0x6184, 0x10 },
+{ "linux/atmdev.h", "ATM_NEWBACKENDIF", _IOC_WRITE, 0x61f3, 0x02 },
+{ "linux/atmdev.h", "ATM_QUERYLOOP", _IOC_WRITE, 0x6154, 0x10 },
+{ "linux/atmdev.h", "ATM_RSTADDR", _IOC_WRITE, 0x6187, 0x10 },
+{ "linux/atmdev.h", "ATM_SETBACKEND", _IOC_WRITE, 0x61f2, 0x02 },
+{ "linux/atmdev.h", "ATM_SETCIRANGE", _IOC_WRITE, 0x618b, 0x10 },
+{ "linux/atmdev.h", "ATM_SETESI", _IOC_WRITE, 0x618c, 0x10 },
+{ "linux/atmdev.h", "ATM_SETESIF", _IOC_WRITE, 0x618d, 0x10 },
+{ "linux/atmdev.h", "ATM_SETLOOP", _IOC_WRITE, 0x6153, 0x10 },
+{ "linux/atmdev.h", "ATM_SETSC", _IOC_WRITE, 0x61f1, 0x04 },
+{ "linux/atmlec.h", "ATMLEC_CTRL", _IOC_NONE, 0x61d0, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_DATA", _IOC_NONE, 0x61d1, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_MCAST", _IOC_NONE, 0x61d2, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_CTRL", _IOC_NONE, 0x61d8, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_DATA", _IOC_NONE, 0x61d9, 0x00 },
+{ "linux/atmsvc.h", "ATMSIGD_CTRL", _IOC_NONE, 0x61f0, 0x00 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ASKUMOUNT", _IOC_READ|_IOC_WRITE, 0x937d, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CATATONIC", _IOC_READ|_IOC_WRITE, 0x9379, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CLOSEMOUNT", _IOC_READ|_IOC_WRITE, 0x9375, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_EXPIRE", _IOC_READ|_IOC_WRITE, 0x937c, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_FAIL", _IOC_READ|_IOC_WRITE, 0x9377, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", _IOC_READ|_IOC_WRITE, 0x937e, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_OPENMOUNT", _IOC_READ|_IOC_WRITE, 0x9374, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOSUBVER", _IOC_READ|_IOC_WRITE, 0x9373, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOVER", _IOC_READ|_IOC_WRITE, 0x9372, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_READY", _IOC_READ|_IOC_WRITE, 0x9376, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_REQUESTER", _IOC_READ|_IOC_WRITE, 0x937b, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_SETPIPEFD", _IOC_READ|_IOC_WRITE, 0x9378, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_TIMEOUT", _IOC_READ|_IOC_WRITE, 0x937a, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x9371, 0x18 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_CATATONIC", _IOC_NONE, 0x9362, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_EXPIRE", _IOC_READ, 0x9365, 0x10c },
+{ "linux/auto_fs.h", "AUTOFS_IOC_FAIL", _IOC_NONE, 0x9361, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_PROTOVER", _IOC_READ, 0x9363, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_READY", _IOC_NONE, 0x9360, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x9364, 0x08 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT32", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_ASKUMOUNT", _IOC_READ, 0x9370, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_EXPIRE_MULTI", _IOC_WRITE, 0x9366, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_PROTOSUBVER", _IOC_READ, 0x9367, 0x04 },
+{ "linux/blkpg.h", "BLKPG", _IOC_NONE, 0x1269, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_ADD_DEV", _IOC_WRITE, 0x940a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE", _IOC_WRITE, 0x940c, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_CTL", _IOC_WRITE, 0x9421, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_PROGRESS", _IOC_READ, 0x9422, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_V2", _IOC_READ|_IOC_WRITE, 0x9420, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE_RANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFAULT_SUBVOL", _IOC_WRITE, 0x9413, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG", _IOC_WRITE, 0x9402, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG_RANGE", _IOC_WRITE, 0x9410, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEVICES_READY", _IOC_READ, 0x9427, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_INFO", _IOC_READ|_IOC_WRITE, 0x941e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_REPLACE", _IOC_READ|_IOC_WRITE, 0x9435, 0xa28 },
+{ "linux/btrfs.h", "BTRFS_IOC_FILE_EXTENT_SAME", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_FS_INFO", _IOC_READ, 0x941f, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_DEV_STATS", _IOC_READ|_IOC_WRITE, 0x9434, 0x408 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FEATURES", _IOC_READ, 0x9439, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FSLABEL", _IOC_READ, 0x9431, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_SUPPORTED_FEATURES", _IOC_READ, 0x9439, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_LOOKUP", _IOC_READ|_IOC_WRITE, 0x9412, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_PATHS", _IOC_READ|_IOC_WRITE, 0x9423, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_LOGICAL_INO", _IOC_READ|_IOC_WRITE, 0x9424, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_ASSIGN", _IOC_WRITE, 0x9429, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_CREATE", _IOC_WRITE, 0x942a, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_LIMIT", _IOC_READ, 0x942b, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_CTL", _IOC_READ|_IOC_WRITE, 0x9428, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN", _IOC_WRITE, 0x942c, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_STATUS", _IOC_READ, 0x942d, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_WAIT", _IOC_NONE, 0x942e, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_RESIZE", _IOC_WRITE, 0x9403, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV", _IOC_WRITE, 0x940b, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV_V2", _IOC_WRITE, 0x943a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCAN_DEV", _IOC_WRITE, 0x9404, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB", _IOC_READ|_IOC_WRITE, 0x941b, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_CANCEL", _IOC_NONE, 0x941c, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_PROGRESS", _IOC_READ|_IOC_WRITE, 0x941d, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SEND", _IOC_WRITE, 0x9426, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FEATURES", _IOC_WRITE, 0x9439, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FSLABEL", _IOC_WRITE, 0x9432, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_RECEIVED_SUBVOL", _IOC_READ|_IOC_WRITE, 0x9425, 0xc8 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE", _IOC_WRITE, 0x9401, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE_V2", _IOC_WRITE, 0x9417, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_DESTROY", _IOC_WRITE, 0x940f, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SPACE_INFO", _IOC_READ|_IOC_WRITE, 0x9414, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_START_SYNC", _IOC_READ, 0x9418, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE", _IOC_WRITE, 0x940e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE_V2", _IOC_WRITE, 0x9418, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_GETFLAGS", _IOC_READ, 0x9419, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_SETFLAGS", _IOC_WRITE, 0x941a, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SYNC", _IOC_NONE, 0x9408, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_END", _IOC_NONE, 0x9407, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_START", _IOC_NONE, 0x9406, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH", _IOC_READ|_IOC_WRITE, 0x9411, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH_V2", _IOC_READ|_IOC_WRITE, 0x9411, 0x70 },
+{ "linux/btrfs.h", "BTRFS_IOC_WAIT_SYNC", _IOC_WRITE, 0x9416, 0x08 },
+{ "linux/capi.h", "CAPI_CLR_FLAGS", _IOC_READ, 0x4325, 0x04 },
+{ "linux/capi.h", "CAPI_GET_ERRCODE", _IOC_READ, 0x4321, 0x02 },
+{ "linux/capi.h", "CAPI_GET_FLAGS", _IOC_READ, 0x4323, 0x04 },
+{ "linux/capi.h", "CAPI_GET_MANUFACTURER", _IOC_READ|_IOC_WRITE, 0x4306, 0x04 },
+{ "linux/capi.h", "CAPI_GET_PROFILE", _IOC_READ|_IOC_WRITE, 0x4309, 0x40 },
+{ "linux/capi.h", "CAPI_GET_SERIAL", _IOC_READ|_IOC_WRITE, 0x4308, 0x04 },
+{ "linux/capi.h", "CAPI_GET_VERSION", _IOC_READ|_IOC_WRITE, 0x4307, 0x10 },
+{ "linux/capi.h", "CAPI_INSTALLED", _IOC_READ, 0x4322, 0x02 },
+{ "linux/capi.h", "CAPI_MANUFACTURER_CMD", _IOC_READ|_IOC_WRITE, 0x4320, 0x10 },
+{ "linux/capi.h", "CAPI_NCCI_GETUNIT", _IOC_READ, 0x4327, 0x04 },
+{ "linux/capi.h", "CAPI_NCCI_OPENCOUNT", _IOC_READ, 0x4326, 0x04 },
+{ "linux/capi.h", "CAPI_REGISTER", _IOC_WRITE, 0x4301, 0x0c },
+{ "linux/capi.h", "CAPI_SET_FLAGS", _IOC_READ, 0x4324, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_BIG_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x4212, 0x60 },
+{ "linux/cciss_ioctl.h", "CCISS_DEREGDISK", _IOC_NONE, 0x420c, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_GETBUSTYPES", _IOC_READ, 0x4207, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETDRIVVER", _IOC_READ, 0x4209, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETFIRMVER", _IOC_READ, 0x4208, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETHEARTBEAT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETINTINFO", _IOC_READ, 0x4202, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_GETLUNINFO", _IOC_READ, 0x4211, 0x0c },
+{ "linux/cciss_ioctl.h", "CCISS_GETNODENAME", _IOC_READ, 0x4204, 0x10 },
+{ "linux/cciss_ioctl.h", "CCISS_GETPCIINFO", _IOC_READ, 0x4201, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x420b, 0x58 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWD", _IOC_NONE, 0x420e, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWDISK", _IOC_WRITE, 0x420d, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_RESCANDISK", _IOC_NONE, 0x4210, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REVALIDVOLS", _IOC_NONE, 0x420a, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_SETINTINFO", _IOC_WRITE, 0x4203, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_SETNODENAME", _IOC_WRITE, 0x4205, 0x10 },
+{ "linux/cdrom.h", "CDROMAUDIOBUFSIZ", 0, 0x5382, 0 },
+{ "linux/cdrom.h", "CDROMCLOSETRAY", 0, 0x5319, 0 },
+{ "linux/cdrom.h", "CDROMEJECT", 0, 0x5309, 0 },
+{ "linux/cdrom.h", "CDROMEJECT_SW", 0, 0x530f, 0 },
+{ "linux/cdrom.h", "CDROMGETSPINDOWN", 0, 0x531d, 0 },
+{ "linux/cdrom.h", "CDROMMULTISESSION", 0, 0x5310, 0 },
+{ "linux/cdrom.h", "CDROMPAUSE", 0, 0x5301, 0 },
+{ "linux/cdrom.h", "CDROMPLAYBLK", 0, 0x5317, 0 },
+{ "linux/cdrom.h", "CDROMPLAYMSF", 0, 0x5303, 0 },
+{ "linux/cdrom.h", "CDROMPLAYTRKIND", 0, 0x5304, 0 },
+{ "linux/cdrom.h", "CDROMREADALL", 0, 0x5318, 0 },
+{ "linux/cdrom.h", "CDROMREADAUDIO", 0, 0x530e, 0 },
+{ "linux/cdrom.h", "CDROMREADCOOKED", 0, 0x5315, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE1", 0, 0x530d, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE2", 0, 0x530c, 0 },
+{ "linux/cdrom.h", "CDROMREADRAW", 0, 0x5314, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCENTRY", 0, 0x5306, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCHDR", 0, 0x5305, 0 },
+{ "linux/cdrom.h", "CDROMRESET", 0, 0x5312, 0 },
+{ "linux/cdrom.h", "CDROMRESUME", 0, 0x5302, 0 },
+{ "linux/cdrom.h", "CDROMSEEK", 0, 0x5316, 0 },
+{ "linux/cdrom.h", "CDROMSETSPINDOWN", 0, 0x531e, 0 },
+{ "linux/cdrom.h", "CDROMSTART", 0, 0x5308, 0 },
+{ "linux/cdrom.h", "CDROMSTOP", 0, 0x5307, 0 },
+{ "linux/cdrom.h", "CDROMSUBCHNL", 0, 0x530b, 0 },
+{ "linux/cdrom.h", "CDROMVOLCTRL", 0, 0x530a, 0 },
+{ "linux/cdrom.h", "CDROMVOLREAD", 0, 0x5313, 0 },
+{ "linux/cdrom.h", "CDROM_CHANGER_NSLOTS", 0, 0x5328, 0 },
+{ "linux/cdrom.h", "CDROM_CLEAR_OPTIONS", 0, 0x5321, 0 },
+{ "linux/cdrom.h", "CDROM_DEBUG", 0, 0x5330, 0 },
+{ "linux/cdrom.h", "CDROM_DISC_STATUS", 0, 0x5327, 0 },
+{ "linux/cdrom.h", "CDROM_DRIVE_STATUS", 0, 0x5326, 0 },
+{ "linux/cdrom.h", "CDROM_GET_CAPABILITY", 0, 0x5331, 0 },
+{ "linux/cdrom.h", "CDROM_GET_MCN", 0, 0x5311, 0 },
+{ "linux/cdrom.h", "CDROM_LAST_WRITTEN", 0, 0x5395, 0 },
+{ "linux/cdrom.h", "CDROM_LOCKDOOR", 0, 0x5329, 0 },
+{ "linux/cdrom.h", "CDROM_MEDIA_CHANGED", 0, 0x5325, 0 },
+{ "linux/cdrom.h", "CDROM_NEXT_WRITABLE", 0, 0x5394, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_DISC", 0, 0x5323, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_SPEED", 0, 0x5322, 0 },
+{ "linux/cdrom.h", "CDROM_SEND_PACKET", 0, 0x5393, 0 },
+{ "linux/cdrom.h", "CDROM_SET_OPTIONS", 0, 0x5320, 0 },
+{ "linux/cdrom.h", "DVD_AUTH", 0, 0x5392, 0 },
+{ "linux/cdrom.h", "DVD_READ_STRUCT", 0, 0x5390, 0 },
+{ "linux/cdrom.h", "DVD_WRITE_STRUCT", 0, 0x5391, 0 },
+{ "linux/chio.h", "CHIOEXCHANGE", _IOC_WRITE, 0x6302, 0x1c },
+{ "linux/chio.h", "CHIOGELEM", _IOC_WRITE, 0x6310, 0x6c },
+{ "linux/chio.h", "CHIOGPARAMS", _IOC_READ, 0x6306, 0x14 },
+{ "linux/chio.h", "CHIOGPICKER", _IOC_READ, 0x6304, 0x04 },
+{ "linux/chio.h", "CHIOGSTATUS", _IOC_WRITE, 0x6308, 0x10 },
+{ "linux/chio.h", "CHIOGVPARAMS", _IOC_READ, 0x6313, 0x70 },
+{ "linux/chio.h", "CHIOINITELEM", _IOC_NONE, 0x6311, 0x00 },
+{ "linux/chio.h", "CHIOMOVE", _IOC_WRITE, 0x6301, 0x14 },
+{ "linux/chio.h", "CHIOPOSITION", _IOC_WRITE, 0x6303, 0x0c },
+{ "linux/chio.h", "CHIOSPICKER", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/chio.h", "CHIOSVOLTAG", _IOC_WRITE, 0x6312, 0x30 },
+{ "linux/cm4000_cs.h", "CM_IOCARDOFF", _IOC_NONE, 0x6304, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOCGATR", _IOC_READ|_IOC_WRITE, 0x6301, 0x08 },
+{ "linux/cm4000_cs.h", "CM_IOCGSTATUS", _IOC_READ, 0x6300, 0x08 },
+{ "linux/cm4000_cs.h", "CM_IOCSPTS", _IOC_WRITE, 0x6302, 0x08 },
+{ "linux/cm4000_cs.h", "CM_IOCSRDR", _IOC_NONE, 0x6303, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOSDBGLVL", _IOC_WRITE, 0x63fa, 0x08 },
+{ "linux/coda.h", "CIOC_KERNEL_VERSION", _IOC_READ|_IOC_WRITE, 0x630a, 0x08 },
+{ "linux/dm-ioctl.h", "DM_DEV_CREATE", _IOC_READ|_IOC_WRITE, 0xfd03, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_REMOVE", _IOC_READ|_IOC_WRITE, 0xfd04, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_RENAME", _IOC_READ|_IOC_WRITE, 0xfd05, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SET_GEOMETRY", _IOC_READ|_IOC_WRITE, 0xfd0f, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_STATUS", _IOC_READ|_IOC_WRITE, 0xfd07, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SUSPEND", _IOC_READ|_IOC_WRITE, 0xfd06, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_WAIT", _IOC_READ|_IOC_WRITE, 0xfd08, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_DEVICES", _IOC_READ|_IOC_WRITE, 0xfd02, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_VERSIONS", _IOC_READ|_IOC_WRITE, 0xfd0d, 0x138 },
+{ "linux/dm-ioctl.h", "DM_REMOVE_ALL", _IOC_READ|_IOC_WRITE, 0xfd01, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_CLEAR", _IOC_READ|_IOC_WRITE, 0xfd0a, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_DEPS", _IOC_READ|_IOC_WRITE, 0xfd0b, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_LOAD", _IOC_READ|_IOC_WRITE, 0xfd09, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_STATUS", _IOC_READ|_IOC_WRITE, 0xfd0c, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TARGET_MSG", _IOC_READ|_IOC_WRITE, 0xfd0e, 0x138 },
+{ "linux/dm-ioctl.h", "DM_VERSION", _IOC_READ|_IOC_WRITE, 0xfd00, 0x138 },
+{ "linux/dma-buf.h", "DMA_BUF_IOCTL_SYNC", _IOC_WRITE, 0x6200, 0x08 },
+{ "linux/dn.h", "OSIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "OSIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dn.h", "SIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "SIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dvb/audio.h", "AUDIO_BILINGUAL_CHANNEL_SELECT", _IOC_NONE, 0x6f14, 0x00 },
+{ "linux/dvb/audio.h", "AUDIO_CHANNEL_SELECT", _IOC_NONE, 0x6f09, 0x00 },
+{ "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 },
+{ "linux/dvb/audio.h", "AUDIO_STOP", _IOC_NONE, 0x6f01, 0x00 },
+{ "linux/dvb/ca.h", "CA_GET_CAP", _IOC_READ, 0x6f81, 0x10 },
+{ "linux/dvb/ca.h", "CA_GET_DESCR_INFO", _IOC_READ, 0x6f83, 0x08 },
+{ "linux/dvb/ca.h", "CA_GET_MSG", _IOC_READ, 0x6f84, 0x10c },
+{ "linux/dvb/ca.h", "CA_GET_SLOT_INFO", _IOC_READ, 0x6f82, 0x0c },
+{ "linux/dvb/ca.h", "CA_RESET", _IOC_NONE, 0x6f80, 0x00 },
+{ "linux/dvb/ca.h", "CA_SEND_MSG", _IOC_WRITE, 0x6f85, 0x10c },
+{ "linux/dvb/ca.h", "CA_SET_DESCR", _IOC_WRITE, 0x6f86, 0x10 },
+{ "linux/dvb/ca.h", "CA_SET_PID", _IOC_WRITE, 0x6f87, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_ADD_PID", _IOC_WRITE, 0x6f33, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_GET_CAPS", _IOC_READ, 0x6f30, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_GET_PES_PIDS", _IOC_READ, 0x6f2f, 0x0a },
+{ "linux/dvb/dmx.h", "DMX_GET_STC", _IOC_READ|_IOC_WRITE, 0x6f32, 0x10 },
+{ "linux/dvb/dmx.h", "DMX_REMOVE_PID", _IOC_WRITE, 0x6f34, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_SET_BUFFER_SIZE", _IOC_NONE, 0x6f2d, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_SET_FILTER", _IOC_WRITE, 0x6f2b, 0x3c },
+{ "linux/dvb/dmx.h", "DMX_SET_PES_FILTER", _IOC_WRITE, 0x6f2c, 0x14 },
+{ "linux/dvb/dmx.h", "DMX_SET_SOURCE", _IOC_WRITE, 0x6f31, 0x04 },
+{ "linux/dvb/dmx.h", "DMX_START", _IOC_NONE, 0x6f29, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_STOP", _IOC_NONE, 0x6f2a, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RECV_SLAVE_REPLY", _IOC_READ, 0x6f40, 0x0c },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RESET_OVERLOAD", _IOC_NONE, 0x6f3e, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_BURST", _IOC_NONE, 0x6f41, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_MASTER_CMD", _IOC_WRITE, 0x6f3f, 0x07 },
+{ "linux/dvb/frontend.h", "FE_DISHNETWORK_SEND_LEGACY_CMD", _IOC_NONE, 0x6f50, 0x00 },
+{ "linux/dvb/frontend.h", "FE_ENABLE_HIGH_LNB_VOLTAGE", _IOC_NONE, 0x6f44, 0x00 },
+{ "linux/dvb/frontend.h", "FE_GET_EVENT", _IOC_READ, 0x6f4e, 0x28 },
+{ "linux/dvb/frontend.h", "FE_GET_FRONTEND", _IOC_READ, 0x6f4d, 0x24 },
+{ "linux/dvb/frontend.h", "FE_GET_INFO", _IOC_READ, 0x6f3d, 0xa8 },
+{ "linux/dvb/frontend.h", "FE_GET_PROPERTY", _IOC_READ, 0x6f53, 0x10 },
+{ "linux/dvb/frontend.h", "FE_READ_BER", _IOC_READ, 0x6f46, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_SIGNAL_STRENGTH", _IOC_READ, 0x6f47, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_SNR", _IOC_READ, 0x6f48, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_STATUS", _IOC_READ, 0x6f45, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_UNCORRECTED_BLOCKS", _IOC_READ, 0x6f49, 0x04 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND", _IOC_WRITE, 0x6f4c, 0x24 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND_TUNE_MODE", _IOC_NONE, 0x6f51, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_PROPERTY", _IOC_WRITE, 0x6f52, 0x10 },
+{ "linux/dvb/frontend.h", "FE_SET_TONE", _IOC_NONE, 0x6f42, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_VOLTAGE", _IOC_NONE, 0x6f43, 0x00 },
+{ "linux/dvb/net.h", "NET_ADD_IF", _IOC_READ|_IOC_WRITE, 0x6f34, 0x06 },
+{ "linux/dvb/net.h", "NET_GET_IF", _IOC_READ|_IOC_WRITE, 0x6f36, 0x06 },
+{ "linux/dvb/net.h", "NET_REMOVE_IF", _IOC_NONE, 0x6f35, 0x00 },
+{ "linux/dvb/osd.h", "OSD_GET_CAPABILITY", _IOC_READ, 0x6fa1, 0x10 },
+{ "linux/dvb/osd.h", "OSD_SEND_CMD", _IOC_WRITE, 0x6fa0, 0x20 },
+{ "linux/dvb/video.h", "VIDEO_CLEAR_BUFFER", _IOC_NONE, 0x6f22, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3b, 0x48 },
+{ "linux/dvb/video.h", "VIDEO_CONTINUE", _IOC_NONE, 0x6f18, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FAST_FORWARD", _IOC_NONE, 0x6f1f, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FREEZE", _IOC_NONE, 0x6f17, 0x00 },
+{ "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 },
+{ "linux/dvb/video.h", "VIDEO_TRY_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3c, 0x48 },
+{ "linux/fb.h", "FBIOBLANK", 0, 0x4611, 0 },
+{ "linux/fb.h", "FBIOGETCMAP", 0, 0x4604, 0 },
+{ "linux/fb.h", "FBIOGET_CON2FBMAP", 0, 0x460F, 0 },
+{ "linux/fb.h", "FBIOGET_DISPINFO", 0, 0x4618, 0 },
+{ "linux/fb.h", "FBIOGET_FSCREENINFO", 0, 0x4602, 0 },
+{ "linux/fb.h", "FBIOGET_GLYPH", 0, 0x4615, 0 },
+{ "linux/fb.h", "FBIOGET_HWCINFO", 0, 0x4616, 0 },
+{ "linux/fb.h", "FBIOGET_VBLANK", _IOC_READ, 0x4612, 0x20 },
+{ "linux/fb.h", "FBIOGET_VSCREENINFO", 0, 0x4600, 0 },
+{ "linux/fb.h", "FBIOPAN_DISPLAY", 0, 0x4606, 0 },
+{ "linux/fb.h", "FBIOPUTCMAP", 0, 0x4605, 0 },
+{ "linux/fb.h", "FBIOPUT_CON2FBMAP", 0, 0x4610, 0 },
+{ "linux/fb.h", "FBIOPUT_MODEINFO", 0, 0x4617, 0 },
+{ "linux/fb.h", "FBIOPUT_VSCREENINFO", 0, 0x4601, 0 },
+{ "linux/fb.h", "FBIO_ALLOC", 0, 0x4613, 0 },
+{ "linux/fb.h", "FBIO_CURSOR", _IOC_READ|_IOC_WRITE, 0x4608, 0x68 },
+{ "linux/fb.h", "FBIO_FREE", 0, 0x4614, 0 },
+{ "linux/fb.h", "FBIO_WAITFORVSYNC", _IOC_WRITE, 0x4620, 0x04 },
+{ "linux/fd.h", "FDCLRPRM", _IOC_NONE, 0x0241, 0x00 },
+{ "linux/fd.h", "FDDEFPRM", _IOC_WRITE, 0x0243, 0x20 },
+{ "linux/fd.h", "FDEJECT", _IOC_NONE, 0x025a, 0x00 },
+{ "linux/fd.h", "FDFLUSH", _IOC_NONE, 0x024b, 0x00 },
+{ "linux/fd.h", "FDFMTBEG", _IOC_NONE, 0x0247, 0x00 },
+{ "linux/fd.h", "FDFMTEND", _IOC_NONE, 0x0249, 0x00 },
+{ "linux/fd.h", "FDFMTTRK", _IOC_WRITE, 0x0248, 0x0c },
+{ "linux/fd.h", "FDGETDRVPRM", _IOC_READ, 0x0211, 0x80 },
+{ "linux/fd.h", "FDGETDRVSTAT", _IOC_READ, 0x0212, 0x50 },
+{ "linux/fd.h", "FDGETDRVTYP", _IOC_READ, 0x020f, 0x10 },
+{ "linux/fd.h", "FDGETFDCSTAT", _IOC_READ, 0x0215, 0x28 },
+{ "linux/fd.h", "FDGETMAXERRS", _IOC_READ, 0x020e, 0x14 },
+{ "linux/fd.h", "FDGETPRM", _IOC_READ, 0x0204, 0x20 },
+{ "linux/fd.h", "FDMSGOFF", _IOC_NONE, 0x0246, 0x00 },
+{ "linux/fd.h", "FDMSGON", _IOC_NONE, 0x0245, 0x00 },
+{ "linux/fd.h", "FDPOLLDRVSTAT", _IOC_READ, 0x0213, 0x50 },
+{ "linux/fd.h", "FDRAWCMD", _IOC_NONE, 0x0258, 0x00 },
+{ "linux/fd.h", "FDRESET", _IOC_NONE, 0x0254, 0x00 },
+{ "linux/fd.h", "FDSETDRVPRM", _IOC_WRITE, 0x0290, 0x80 },
+{ "linux/fd.h", "FDSETEMSGTRESH", _IOC_NONE, 0x024a, 0x00 },
+{ "linux/fd.h", "FDSETMAXERRS", _IOC_WRITE, 0x024c, 0x14 },
+{ "linux/fd.h", "FDSETPRM", _IOC_WRITE, 0x0242, 0x20 },
+{ "linux/fd.h", "FDTWADDLE", _IOC_NONE, 0x0259, 0x00 },
+{ "linux/fd.h", "FDWERRORCLR", _IOC_NONE, 0x0256, 0x00 },
+{ "linux/fd.h", "FDWERRORGET", _IOC_READ, 0x0217, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ADD_DESCRIPTOR", _IOC_READ|_IOC_WRITE, 0x2306, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x2302, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", _IOC_READ|_IOC_WRITE, 0x230d, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x230f, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_CREATE_ISO_CONTEXT", _IOC_READ|_IOC_WRITE, 0x2308, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE", _IOC_WRITE, 0x2303, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", _IOC_WRITE, 0x230e, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x2310, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_FLUSH_ISO", _IOC_WRITE, 0x2318, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER", _IOC_READ, 0x230c, 0x10 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER2", _IOC_READ|_IOC_WRITE, 0x2314, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_INFO", _IOC_READ|_IOC_WRITE, 0x2300, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_SPEED", _IOC_NONE, 0x2311, 0x00 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_INITIATE_BUS_RESET", _IOC_WRITE, 0x2305, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_QUEUE_ISO", _IOC_READ|_IOC_WRITE, 0x2309, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", _IOC_WRITE, 0x2316, 0x08 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_REMOVE_DESCRIPTOR", _IOC_WRITE, 0x2307, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", _IOC_WRITE, 0x2312, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_PHY_PACKET", _IOC_READ|_IOC_WRITE, 0x2315, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_REQUEST", _IOC_WRITE, 0x2301, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_RESPONSE", _IOC_WRITE, 0x2304, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_STREAM_PACKET", _IOC_WRITE, 0x2313, 0x28 },
+{ "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/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
+{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x08 },
+{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x08 },
+{ "linux/fs.h", "BLKDISCARD", _IOC_NONE, 0x1277, 0x00 },
+{ "linux/fs.h", "BLKDISCARDZEROES", _IOC_NONE, 0x127c, 0x00 },
+{ "linux/fs.h", "BLKFLSBUF", _IOC_NONE, 0x1261, 0x00 },
+{ "linux/fs.h", "BLKFRAGET", _IOC_NONE, 0x1265, 0x00 },
+{ "linux/fs.h", "BLKFRASET", _IOC_NONE, 0x1264, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE", _IOC_NONE, 0x1260, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE64", _IOC_READ, 0x1272, 0x08 },
+{ "linux/fs.h", "BLKIOMIN", _IOC_NONE, 0x1278, 0x00 },
+{ "linux/fs.h", "BLKIOOPT", _IOC_NONE, 0x1279, 0x00 },
+{ "linux/fs.h", "BLKPBSZGET", _IOC_NONE, 0x127b, 0x00 },
+{ "linux/fs.h", "BLKRAGET", _IOC_NONE, 0x1263, 0x00 },
+{ "linux/fs.h", "BLKRASET", _IOC_NONE, 0x1262, 0x00 },
+{ "linux/fs.h", "BLKROGET", _IOC_NONE, 0x125e, 0x00 },
+{ "linux/fs.h", "BLKROSET", _IOC_NONE, 0x125d, 0x00 },
+{ "linux/fs.h", "BLKROTATIONAL", _IOC_NONE, 0x127e, 0x00 },
+{ "linux/fs.h", "BLKRRPART", _IOC_NONE, 0x125f, 0x00 },
+{ "linux/fs.h", "BLKSECDISCARD", _IOC_NONE, 0x127d, 0x00 },
+{ "linux/fs.h", "BLKSECTGET", _IOC_NONE, 0x1267, 0x00 },
+{ "linux/fs.h", "BLKSECTSET", _IOC_NONE, 0x1266, 0x00 },
+{ "linux/fs.h", "BLKSSZGET", _IOC_NONE, 0x1268, 0x00 },
+{ "linux/fs.h", "BLKTRACESETUP", _IOC_READ|_IOC_WRITE, 0x1273, 0x48 },
+{ "linux/fs.h", "BLKTRACESTART", _IOC_NONE, 0x1274, 0x00 },
+{ "linux/fs.h", "BLKTRACESTOP", _IOC_NONE, 0x1275, 0x00 },
+{ "linux/fs.h", "BLKTRACETEARDOWN", _IOC_NONE, 0x1276, 0x00 },
+{ "linux/fs.h", "BLKZEROOUT", _IOC_NONE, 0x127f, 0x00 },
+{ "linux/fs.h", "FIBMAP", _IOC_NONE, 0x0001, 0x00 },
+{ "linux/fs.h", "FICLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/fs.h", "FICLONERANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/fs.h", "FIDEDUPERANGE", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/fs.h", "FIFREEZE", _IOC_READ|_IOC_WRITE, 0x5877, 0x04 },
+{ "linux/fs.h", "FIGETBSZ", _IOC_NONE, 0x0002, 0x00 },
+{ "linux/fs.h", "FITHAW", _IOC_READ|_IOC_WRITE, 0x5878, 0x04 },
+{ "linux/fs.h", "FITRIM", _IOC_READ|_IOC_WRITE, 0x5879, 0x18 },
+{ "linux/fs.h", "FS_IOC32_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_FIEMAP", _IOC_READ|_IOC_WRITE, 0x660b, 0x20 },
+{ "linux/fs.h", "FS_IOC_FSGETXATTR", _IOC_READ, 0x581f, 0x1c },
+{ "linux/fs.h", "FS_IOC_FSSETXATTR", _IOC_WRITE, 0x5820, 0x1c },
+{ "linux/fs.h", "FS_IOC_GETFLAGS", _IOC_READ, 0x6601, 0x08 },
+{ "linux/fs.h", "FS_IOC_GETVERSION", _IOC_READ, 0x7601, 0x08 },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_POLICY", _IOC_WRITE, 0x6615, 0x0c },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_PWSALT", _IOC_WRITE, 0x6614, 0x10 },
+{ "linux/fs.h", "FS_IOC_SETFLAGS", _IOC_WRITE, 0x6602, 0x08 },
+{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x08 },
+{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
+{ "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 },
+{ "linux/fsl-diu-fb.h", "MFB_GET_PIXFMT", _IOC_READ, 0x4d08, 0x04 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_ALPHA", _IOC_WRITE, 0x4d00, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_AOID", _IOC_WRITE, 0x4d04, 0x08 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_BRIGHTNESS", _IOC_WRITE, 0x4d03, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_CHROMA_KEY", _IOC_WRITE, 0x4d01, 0x0c },
+{ "linux/fsl-diu-fb.h", "MFB_SET_GAMMA", _IOC_WRITE, 0x4d01, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_PIXFMT", _IOC_WRITE, 0x4d08, 0x04 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_DOORBELL", _IOC_READ|_IOC_WRITE, 0xaf06, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_GETPROP", _IOC_READ|_IOC_WRITE, 0xaf07, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_MEMCPY", _IOC_READ|_IOC_WRITE, 0xaf05, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_GET_STATUS", _IOC_READ|_IOC_WRITE, 0xaf02, 0x0c },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_RESTART", _IOC_READ|_IOC_WRITE, 0xaf01, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_START", _IOC_READ|_IOC_WRITE, 0xaf03, 0x10 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_STOP", _IOC_READ|_IOC_WRITE, 0xaf04, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_SETPROP", _IOC_READ|_IOC_WRITE, 0xaf08, 0x28 },
+{ "linux/fuse.h", "FUSE_DEV_IOC_CLONE", _IOC_READ, 0xe500, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_DDCB", _IOC_READ|_IOC_WRITE, 0xa532, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_RAW_DDCB", _IOC_READ|_IOC_WRITE, 0xa533, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_GET_CARD_STATE", _IOC_READ, 0xa524, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_PIN_MEM", _IOC_READ|_IOC_WRITE, 0xa528, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG16", _IOC_READ, 0xa522, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG32", _IOC_READ, 0xa520, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG64", _IOC_READ, 0xa51e, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_READ", _IOC_READ|_IOC_WRITE, 0xa551, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_UPDATE", _IOC_READ|_IOC_WRITE, 0xa550, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_UNPIN_MEM", _IOC_READ|_IOC_WRITE, 0xa529, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG16", _IOC_WRITE, 0xa523, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG32", _IOC_WRITE, 0xa521, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG64", _IOC_WRITE, 0xa51f, 0x10 },
+{ "linux/gigaset_dev.h", "GIGASET_BRKCHARS", _IOC_WRITE, 0x4702, 0x06 },
+{ "linux/gigaset_dev.h", "GIGASET_CONFIG", _IOC_READ|_IOC_WRITE, 0x4701, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_REDIR", _IOC_READ|_IOC_WRITE, 0x4700, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_VERSION", _IOC_READ|_IOC_WRITE, 0x4703, 0x10 },
+{ "linux/gpio.h", "GPIO_GET_CHIPINFO_IOCTL", _IOC_READ, 0xb401, 0x44 },
+{ "linux/gpio.h", "GPIO_GET_LINEINFO_IOCTL", _IOC_READ|_IOC_WRITE, 0xb402, 0x48 },
+{ "linux/gsmmux.h", "GSMIOC_DISABLE_NET", _IOC_NONE, 0x4703, 0x00 },
+{ "linux/gsmmux.h", "GSMIOC_ENABLE_NET", _IOC_WRITE, 0x4702, 0x34 },
+{ "linux/gsmmux.h", "GSMIOC_GETCONF", _IOC_READ, 0x4700, 0x4c },
+{ "linux/gsmmux.h", "GSMIOC_SETCONF", _IOC_WRITE, 0x4701, 0x4c },
+{ "linux/hdreg.h", "HDIO_DRIVE_CMD", 0, 0x031f, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_RESET", 0, 0x031c, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASK", 0, 0x031e, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASKFILE", 0, 0x031d, 0 },
+{ "linux/hdreg.h", "HDIO_GETGEO", 0, 0x0301, 0 },
+{ "linux/hdreg.h", "HDIO_GET_32BIT", 0, 0x0309, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ACOUSTIC", 0, 0x030f, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ADDRESS", 0, 0x0310, 0 },
+{ "linux/hdreg.h", "HDIO_GET_BUSSTATE", 0, 0x031a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_DMA", 0, 0x030b, 0 },
+{ "linux/hdreg.h", "HDIO_GET_IDENTITY", 0, 0x030d, 0 },
+{ "linux/hdreg.h", "HDIO_GET_KEEPSETTINGS", 0, 0x0308, 0 },
+{ "linux/hdreg.h", "HDIO_GET_MULTCOUNT", 0, 0x0304, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NICE", 0, 0x030c, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NOWERR", 0, 0x030a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_QDMA", 0, 0x0305, 0 },
+{ "linux/hdreg.h", "HDIO_GET_UNMASKINTR", 0, 0x0302, 0 },
+{ "linux/hdreg.h", "HDIO_GET_WCACHE", 0, 0x030e, 0 },
+{ "linux/hdreg.h", "HDIO_OBSOLETE_IDENTITY", 0, 0x0307, 0 },
+{ "linux/hdreg.h", "HDIO_SCAN_HWIF", 0, 0x0328, 0 },
+{ "linux/hdreg.h", "HDIO_SET_32BIT", 0, 0x0324, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ACOUSTIC", 0, 0x032c, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ADDRESS", 0, 0x032f, 0 },
+{ "linux/hdreg.h", "HDIO_SET_BUSSTATE", 0, 0x032d, 0 },
+{ "linux/hdreg.h", "HDIO_SET_DMA", 0, 0x0326, 0 },
+{ "linux/hdreg.h", "HDIO_SET_KEEPSETTINGS", 0, 0x0323, 0 },
+{ "linux/hdreg.h", "HDIO_SET_MULTCOUNT", 0, 0x0321, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NICE", 0, 0x0329, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NOWERR", 0, 0x0325, 0 },
+{ "linux/hdreg.h", "HDIO_SET_PIO_MODE", 0, 0x0327, 0 },
+{ "linux/hdreg.h", "HDIO_SET_QDMA", 0, 0x032e, 0 },
+{ "linux/hdreg.h", "HDIO_SET_UNMASKINTR", 0, 0x0322, 0 },
+{ "linux/hdreg.h", "HDIO_SET_WCACHE", 0, 0x032b, 0 },
+{ "linux/hdreg.h", "HDIO_SET_XFER", 0, 0x0306, 0 },
+{ "linux/hdreg.h", "HDIO_TRISTATE_HWIF", 0, 0x031b, 0 },
+{ "linux/hdreg.h", "HDIO_UNREGISTER_HWIF", 0, 0x032a, 0 },
+{ "linux/hid-roccat.h", "ROCCATIOCGREPSIZE", _IOC_READ, 0x48f1, 0x04 },
+{ "linux/hiddev.h", "HIDIOCAPPLICATION", _IOC_NONE, 0x4802, 0x00 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINDEX", _IOC_WRITE, 0x4810, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINFO", _IOC_READ|_IOC_WRITE, 0x4811, 0x10 },
+{ "linux/hiddev.h", "HIDIOCGDEVINFO", _IOC_READ, 0x4803, 0x1c },
+{ "linux/hiddev.h", "HIDIOCGFIELDINFO", _IOC_READ|_IOC_WRITE, 0x480a, 0x38 },
+{ "linux/hiddev.h", "HIDIOCGFLAG", _IOC_READ, 0x480e, 0x04 },
+{ "linux/hiddev.h", "HIDIOCGREPORT", _IOC_WRITE, 0x4807, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGREPORTINFO", _IOC_READ|_IOC_WRITE, 0x4809, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGSTRING", _IOC_READ, 0x4804, 0x104 },
+{ "linux/hiddev.h", "HIDIOCGUCODE", _IOC_READ|_IOC_WRITE, 0x480d, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGE", _IOC_READ|_IOC_WRITE, 0x480b, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGES", _IOC_READ|_IOC_WRITE, 0x4813, 0x101c },
+{ "linux/hiddev.h", "HIDIOCGVERSION", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hiddev.h", "HIDIOCINITREPORT", _IOC_NONE, 0x4805, 0x00 },
+{ "linux/hiddev.h", "HIDIOCSFLAG", _IOC_WRITE, 0x480f, 0x04 },
+{ "linux/hiddev.h", "HIDIOCSREPORT", _IOC_WRITE, 0x4808, 0x0c },
+{ "linux/hiddev.h", "HIDIOCSUSAGE", _IOC_WRITE, 0x480c, 0x18 },
+{ "linux/hiddev.h", "HIDIOCSUSAGES", _IOC_WRITE, 0x4814, 0x101c },
+{ "linux/hidraw.h", "HIDIOCGRAWINFO", _IOC_READ, 0x4803, 0x08 },
+{ "linux/hidraw.h", "HIDIOCGRDESC", _IOC_READ, 0x4802, 0x1004 },
+{ "linux/hidraw.h", "HIDIOCGRDESCSIZE", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hpet.h", "HPET_DPI", _IOC_NONE, 0x6805, 0x00 },
+{ "linux/hpet.h", "HPET_EPI", _IOC_NONE, 0x6804, 0x00 },
+{ "linux/hpet.h", "HPET_IE_OFF", _IOC_NONE, 0x6802, 0x00 },
+{ "linux/hpet.h", "HPET_IE_ON", _IOC_NONE, 0x6801, 0x00 },
+{ "linux/hpet.h", "HPET_INFO", _IOC_READ, 0x6803, 0x18 },
+{ "linux/hpet.h", "HPET_IRQFREQ", _IOC_WRITE, 0x6806, 0x08 },
+{ "linux/hsi/cs-protocol.h", "CS_CONFIG_BUFS", _IOC_WRITE, 0x431f, 0x20 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_IF_VERSION", _IOC_READ, 0x431e, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_STATE", _IOC_READ, 0x4315, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_SET_WAKELINE", _IOC_WRITE, 0x4317, 0x04 },
+{ "linux/hsi/hsi_char.h", "HSC_GET_RX", _IOC_WRITE, 0x6b14, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_GET_TX", _IOC_WRITE, 0x6b16, 0x10 },
+{ "linux/hsi/hsi_char.h", "HSC_RESET", _IOC_NONE, 0x6b10, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SEND_BREAK", _IOC_NONE, 0x6b12, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_PM", _IOC_NONE, 0x6b11, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_RX", _IOC_WRITE, 0x6b13, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_SET_TX", _IOC_WRITE, 0x6b15, 0x10 },
+{ "linux/i2o-dev.h", "I2OEVTGET", _IOC_READ, 0x690b, 0x68 },
+{ "linux/i2o-dev.h", "I2OEVTREG", _IOC_WRITE, 0x690a, 0x0c },
+{ "linux/i2o-dev.h", "I2OGETIOPS", _IOC_READ, 0x6900, 0x20 },
+{ "linux/i2o-dev.h", "I2OHRTGET", _IOC_READ|_IOC_WRITE, 0x6901, 0x18 },
+{ "linux/i2o-dev.h", "I2OHTML", _IOC_READ|_IOC_WRITE, 0x6909, 0x30 },
+{ "linux/i2o-dev.h", "I2OLCTGET", _IOC_READ|_IOC_WRITE, 0x6902, 0x18 },
+{ "linux/i2o-dev.h", "I2OPARMGET", _IOC_READ|_IOC_WRITE, 0x6904, 0x28 },
+{ "linux/i2o-dev.h", "I2OPARMSET", _IOC_READ|_IOC_WRITE, 0x6903, 0x28 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU", _IOC_READ, 0x690c, 0x10 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU32", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OSWDEL", _IOC_READ|_IOC_WRITE, 0x6907, 0x30 },
+{ "linux/i2o-dev.h", "I2OSWDL", _IOC_READ|_IOC_WRITE, 0x6905, 0x30 },
+{ "linux/i2o-dev.h", "I2OSWUL", _IOC_READ|_IOC_WRITE, 0x6906, 0x30 },
+{ "linux/i2o-dev.h", "I2OVALIDATE", _IOC_READ, 0x6908, 0x04 },
+{ "linux/i8k.h", "I8K_BIOS_VERSION", _IOC_READ, 0x6980, 0x04 },
+{ "linux/i8k.h", "I8K_FN_STATUS", _IOC_READ, 0x6983, 0x08 },
+{ "linux/i8k.h", "I8K_GET_FAN", _IOC_READ|_IOC_WRITE, 0x6986, 0x08 },
+{ "linux/i8k.h", "I8K_GET_SPEED", _IOC_READ|_IOC_WRITE, 0x6985, 0x08 },
+{ "linux/i8k.h", "I8K_GET_TEMP", _IOC_READ, 0x6984, 0x08 },
+{ "linux/i8k.h", "I8K_MACHINE_ID", _IOC_READ, 0x6981, 0x04 },
+{ "linux/i8k.h", "I8K_POWER_STATUS", _IOC_READ, 0x6982, 0x08 },
+{ "linux/i8k.h", "I8K_SET_FAN", _IOC_READ|_IOC_WRITE, 0x6987, 0x08 },
+{ "linux/if_pppox.h", "PPPOEIOCDFWD", _IOC_NONE, 0xb101, 0x00 },
+{ "linux/if_pppox.h", "PPPOEIOCSFWD", _IOC_WRITE, 0xb100, 0x08 },
+{ "linux/if_tun.h", "TUNATTACHFILTER", _IOC_WRITE, 0x54d5, 0x10 },
+{ "linux/if_tun.h", "TUNDETACHFILTER", _IOC_WRITE, 0x54d6, 0x10 },
+{ "linux/if_tun.h", "TUNGETFEATURES", _IOC_READ, 0x54cf, 0x04 },
+{ "linux/if_tun.h", "TUNGETFILTER", _IOC_READ, 0x54db, 0x10 },
+{ "linux/if_tun.h", "TUNGETIFF", _IOC_READ, 0x54d2, 0x04 },
+{ "linux/if_tun.h", "TUNGETSNDBUF", _IOC_READ, 0x54d3, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETBE", _IOC_READ, 0x54df, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETHDRSZ", _IOC_READ, 0x54d7, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETLE", _IOC_READ, 0x54dd, 0x04 },
+{ "linux/if_tun.h", "TUNSETDEBUG", _IOC_WRITE, 0x54c9, 0x04 },
+{ "linux/if_tun.h", "TUNSETGROUP", _IOC_WRITE, 0x54ce, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFF", _IOC_WRITE, 0x54ca, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFINDEX", _IOC_WRITE, 0x54da, 0x04 },
+{ "linux/if_tun.h", "TUNSETLINK", _IOC_WRITE, 0x54cd, 0x04 },
+{ "linux/if_tun.h", "TUNSETNOCSUM", _IOC_WRITE, 0x54c8, 0x04 },
+{ "linux/if_tun.h", "TUNSETOFFLOAD", _IOC_WRITE, 0x54d0, 0x04 },
+{ "linux/if_tun.h", "TUNSETOWNER", _IOC_WRITE, 0x54cc, 0x04 },
+{ "linux/if_tun.h", "TUNSETPERSIST", _IOC_WRITE, 0x54cb, 0x04 },
+{ "linux/if_tun.h", "TUNSETQUEUE", _IOC_WRITE, 0x54d9, 0x04 },
+{ "linux/if_tun.h", "TUNSETSNDBUF", _IOC_WRITE, 0x54d4, 0x04 },
+{ "linux/if_tun.h", "TUNSETTXFILTER", _IOC_WRITE, 0x54d1, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETBE", _IOC_WRITE, 0x54de, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETHDRSZ", _IOC_WRITE, 0x54d8, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETLE", _IOC_WRITE, 0x54dc, 0x04 },
+{ "linux/iio/events.h", "IIO_GET_EVENT_FD_IOCTL", _IOC_READ, 0x6990, 0x04 },
+{ "linux/input.h", "EVIOCGEFFECTS", _IOC_READ, 0x4584, 0x04 },
+{ "linux/input.h", "EVIOCGID", _IOC_READ, 0x4502, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE", _IOC_READ, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE_V2", _IOC_READ, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCGMASK", _IOC_READ, 0x4592, 0x10 },
+{ "linux/input.h", "EVIOCGRAB", _IOC_WRITE, 0x4590, 0x04 },
+{ "linux/input.h", "EVIOCGREP", _IOC_READ, 0x4503, 0x08 },
+{ "linux/input.h", "EVIOCGVERSION", _IOC_READ, 0x4501, 0x04 },
+{ "linux/input.h", "EVIOCREVOKE", _IOC_WRITE, 0x4591, 0x04 },
+{ "linux/input.h", "EVIOCRMFF", _IOC_WRITE, 0x4581, 0x04 },
+{ "linux/input.h", "EVIOCSCLOCKID", _IOC_WRITE, 0x45a0, 0x04 },
+{ "linux/input.h", "EVIOCSFF", _IOC_WRITE, 0x4580, 0x30 },
+{ "linux/input.h", "EVIOCSKEYCODE", _IOC_WRITE, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCSKEYCODE_V2", _IOC_WRITE, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCSMASK", _IOC_WRITE, 0x4593, 0x10 },
+{ "linux/input.h", "EVIOCSREP", _IOC_WRITE, 0x4503, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_GET_MAINTENANCE_MODE_CMD", _IOC_READ, 0x691e, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_ADDRESS_CMD", _IOC_READ, 0x6912, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6919, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691b, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_LUN_CMD", _IOC_READ, 0x6914, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_TIMING_PARMS_CMD", _IOC_READ, 0x6917, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG", _IOC_READ|_IOC_WRITE, 0x690c, 0x30 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG_TRUNC", _IOC_READ|_IOC_WRITE, 0x690b, 0x30 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD", _IOC_READ, 0x690e, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691c, 0x0c },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND", _IOC_READ, 0x690d, 0x28 },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND_SETTIME", _IOC_READ, 0x6915, 0x30 },
+{ "linux/ipmi.h", "IPMICTL_SET_GETS_EVENTS_CMD", _IOC_READ, 0x6910, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MAINTENANCE_MODE_CMD", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_ADDRESS_CMD", _IOC_READ, 0x6911, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6918, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691a, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_LUN_CMD", _IOC_READ, 0x6913, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_TIMING_PARMS_CMD", _IOC_READ, 0x6916, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD", _IOC_READ, 0x690f, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691d, 0x0c },
+{ "linux/isdn.h", "IIOCDBGVAR", _IOC_NONE, 0x497f, 0x00 },
+{ "linux/isdn.h", "IIOCDRVCTL", _IOC_NONE, 0x4980, 0x00 },
+{ "linux/isdn.h", "IIOCGETCPS", _IOC_NONE, 0x4915, 0x00 },
+{ "linux/isdn.h", "IIOCGETDVR", _IOC_NONE, 0x4916, 0x00 },
+{ "linux/isdn.h", "IIOCGETMAP", _IOC_NONE, 0x4911, 0x00 },
+{ "linux/isdn.h", "IIOCGETPRF", _IOC_NONE, 0x490f, 0x00 },
+{ "linux/isdn.h", "IIOCGETSET", _IOC_NONE, 0x4908, 0x00 },
+{ "linux/isdn.h", "IIOCNETAIF", _IOC_NONE, 0x4901, 0x00 },
+{ "linux/isdn.h", "IIOCNETALN", _IOC_NONE, 0x4920, 0x00 },
+{ "linux/isdn.h", "IIOCNETANM", _IOC_NONE, 0x4905, 0x00 },
+{ "linux/isdn.h", "IIOCNETASL", _IOC_NONE, 0x4913, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIF", _IOC_NONE, 0x4902, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIL", _IOC_NONE, 0x4914, 0x00 },
+{ "linux/isdn.h", "IIOCNETDLN", _IOC_NONE, 0x4921, 0x00 },
+{ "linux/isdn.h", "IIOCNETDNM", _IOC_NONE, 0x4906, 0x00 },
+{ "linux/isdn.h", "IIOCNETDWRSET", _IOC_NONE, 0x4918, 0x00 },
+{ "linux/isdn.h", "IIOCNETGCF", _IOC_NONE, 0x4904, 0x00 },
+{ "linux/isdn.h", "IIOCNETGNM", _IOC_NONE, 0x4907, 0x00 },
+{ "linux/isdn.h", "IIOCNETGPN", _IOC_NONE, 0x4922, 0x00 },
+{ "linux/isdn.h", "IIOCNETHUP", _IOC_NONE, 0x490b, 0x00 },
+{ "linux/isdn.h", "IIOCNETLCR", _IOC_NONE, 0x4917, 0x00 },
+{ "linux/isdn.h", "IIOCNETSCF", _IOC_NONE, 0x4903, 0x00 },
+{ "linux/isdn.h", "IIOCSETBRJ", _IOC_NONE, 0x490d, 0x00 },
+{ "linux/isdn.h", "IIOCSETGST", _IOC_NONE, 0x490c, 0x00 },
+{ "linux/isdn.h", "IIOCSETMAP", _IOC_NONE, 0x4912, 0x00 },
+{ "linux/isdn.h", "IIOCSETPRF", _IOC_NONE, 0x4910, 0x00 },
+{ "linux/isdn.h", "IIOCSETSET", _IOC_NONE, 0x4909, 0x00 },
+{ "linux/isdn.h", "IIOCSETVER", _IOC_NONE, 0x490a, 0x00 },
+{ "linux/isdn.h", "IIOCSIGPRF", _IOC_NONE, 0x490e, 0x00 },
+{ "linux/isdn_ppp.h", "PPPIOCBUNDLE", _IOC_WRITE, 0x7481, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCGCALLINFO", _IOC_READ|_IOC_WRITE, 0x7480, 0x88 },
+{ "linux/isdn_ppp.h", "PPPIOCGCOMPRESSORS", _IOC_READ, 0x7486, 0x40 },
+{ "linux/isdn_ppp.h", "PPPIOCGIFNAME", _IOC_READ, 0x7488, 0x10 },
+{ "linux/isdn_ppp.h", "PPPIOCGMPFLAGS", _IOC_READ, 0x7482, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSCOMPRESSOR", _IOC_WRITE, 0x7487, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPFLAGS", _IOC_WRITE, 0x7483, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMRU", _IOC_WRITE, 0x7485, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMTU", _IOC_WRITE, 0x7484, 0x04 },
+{ "linux/ivtv.h", "IVTV_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x40 },
+{ "linux/ivtv.h", "IVTV_IOC_PASSTHROUGH_MODE", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/ivtvfb.h", "IVTVFB_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x18 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_GET_LEVEL", _IOC_NONE, 0x71cd, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_START", _IOC_WRITE, 0x71cb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_STOP", _IOC_NONE, 0x71cc, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_CARDTYPE", _IOC_READ, 0x71c1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CID", _IOC_READ, 0x71d4, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_CIDCW", _IOC_WRITE, 0x71d9, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_AGAIN", _IOC_WRITE, 0x71d2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_COEFF_SET", _IOC_WRITE, 0x71d0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_CLEAR", _IOC_NONE, 0x71e7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_READ", _IOC_READ, 0x71e6, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_IDLE", _IOC_NONE, 0x71c5, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_RESET", _IOC_NONE, 0x71c0, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_TYPE", _IOC_READ, 0x71c3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_VERSION", _IOC_READ, 0x71c4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DTMF_PRESCALE", _IOC_WRITE, 0x71e8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FILTER_CADENCE", _IOC_WRITE, 0x71d6, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_READ", _IOC_READ, 0x71e2, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_WRITTEN", _IOC_READ, 0x71e3, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_GET_FILTER_HIST", _IOC_WRITE, 0x71c8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_HZ", _IOC_WRITE, 0x71e0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INIT_TONE", _IOC_WRITE, 0x71c9, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_START", _IOC_WRITE, 0x71fd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_STOP", _IOC_WRITE, 0x71fe, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_MIXER", _IOC_WRITE, 0x71cf, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PLAY_CID", _IOC_NONE, 0x71d7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_PORT", _IOC_WRITE, 0x71d1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_POTS_PSTN", _IOC_WRITE, 0x71d5, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PSTN_LINETEST", _IOC_NONE, 0x71d3, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_RATE", _IOC_WRITE, 0x71e1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_READ_WAIT", _IOC_READ, 0x71e4, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_SC_RXG", _IOC_WRITE, 0x71ea, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_TXG", _IOC_WRITE, 0x71eb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SERIAL", _IOC_READ, 0x71c2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER", _IOC_WRITE, 0x71c7, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER_RAW", _IOC_WRITE, 0x71dd, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_SET_LED", _IOC_WRITE, 0x71ce, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SIGCTL", _IOC_WRITE, 0x71e9, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_TESTRAM", _IOC_NONE, 0x71c6, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_TONE_CADENCE", _IOC_WRITE, 0x71ca, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_VERSION", _IOC_READ, 0x71da, 0x08 },
+{ "linux/ixjuser.h", "IXJCTL_VMWI", _IOC_READ, 0x71d8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_WRITE_WAIT", _IOC_READ, 0x71e5, 0x08 },
+{ "linux/joystick.h", "JSIOCGAXES", _IOC_READ, 0x6a11, 0x01 },
+{ "linux/joystick.h", "JSIOCGAXMAP", _IOC_READ, 0x6a32, 0x40 },
+{ "linux/joystick.h", "JSIOCGBTNMAP", _IOC_READ, 0x6a34, 0x400 },
+{ "linux/joystick.h", "JSIOCGBUTTONS", _IOC_READ, 0x6a12, 0x01 },
+{ "linux/joystick.h", "JSIOCGCORR", _IOC_READ, 0x6a22, 0x24 },
+{ "linux/joystick.h", "JSIOCGVERSION", _IOC_READ, 0x6a01, 0x04 },
+{ "linux/joystick.h", "JSIOCSAXMAP", _IOC_WRITE, 0x6a31, 0x40 },
+{ "linux/joystick.h", "JSIOCSBTNMAP", _IOC_WRITE, 0x6a33, 0x400 },
+{ "linux/joystick.h", "JSIOCSCORR", _IOC_WRITE, 0x6a21, 0x24 },
+{ "linux/kcov.h", "KCOV_DISABLE", _IOC_NONE, 0x6365, 0x00 },
+{ "linux/kcov.h", "KCOV_ENABLE", _IOC_NONE, 0x6364, 0x00 },
+{ "linux/kcov.h", "KCOV_INIT_TRACE", _IOC_READ, 0x6301, 0x08 },
+{ "linux/kd.h", "GIO_CMAP", 0, 0x4B70, 0 },
+{ "linux/kd.h", "GIO_FONT", 0, 0x4B60, 0 },
+{ "linux/kd.h", "GIO_FONTX", 0, 0x4B6B, 0 },
+{ "linux/kd.h", "GIO_SCRNMAP", 0, 0x4B40, 0 },
+{ "linux/kd.h", "GIO_UNIMAP", 0, 0x4B66, 0 },
+{ "linux/kd.h", "GIO_UNISCRNMAP", 0, 0x4B69, 0 },
+{ "linux/kd.h", "KDADDIO", 0, 0x4B34, 0 },
+{ "linux/kd.h", "KDDELIO", 0, 0x4B35, 0 },
+{ "linux/kd.h", "KDDISABIO", 0, 0x4B37, 0 },
+{ "linux/kd.h", "KDENABIO", 0, 0x4B36, 0 },
+{ "linux/kd.h", "KDFONTOP", 0, 0x4B72, 0 },
+{ "linux/kd.h", "KDGETKEYCODE", 0, 0x4B4C, 0 },
+{ "linux/kd.h", "KDGETLED", 0, 0x4B31, 0 },
+{ "linux/kd.h", "KDGETMODE", 0, 0x4B3B, 0 },
+{ "linux/kd.h", "KDGKBDIACR", 0, 0x4B4A, 0 },
+{ "linux/kd.h", "KDGKBDIACRUC", 0, 0x4BFA, 0 },
+{ "linux/kd.h", "KDGKBENT", 0, 0x4B46, 0 },
+{ "linux/kd.h", "KDGKBLED", 0, 0x4B64, 0 },
+{ "linux/kd.h", "KDGKBMETA", 0, 0x4B62, 0 },
+{ "linux/kd.h", "KDGKBMODE", 0, 0x4B44, 0 },
+{ "linux/kd.h", "KDGKBSENT", 0, 0x4B48, 0 },
+{ "linux/kd.h", "KDGKBTYPE", 0, 0x4B33, 0 },
+{ "linux/kd.h", "KDKBDREP", 0, 0x4B52, 0 },
+{ "linux/kd.h", "KDMAPDISP", 0, 0x4B3C, 0 },
+{ "linux/kd.h", "KDMKTONE", 0, 0x4B30, 0 },
+{ "linux/kd.h", "KDSETKEYCODE", 0, 0x4B4D, 0 },
+{ "linux/kd.h", "KDSETLED", 0, 0x4B32, 0 },
+{ "linux/kd.h", "KDSETMODE", 0, 0x4B3A, 0 },
+{ "linux/kd.h", "KDSIGACCEPT", 0, 0x4B4E, 0 },
+{ "linux/kd.h", "KDSKBDIACR", 0, 0x4B4B, 0 },
+{ "linux/kd.h", "KDSKBDIACRUC", 0, 0x4BFB, 0 },
+{ "linux/kd.h", "KDSKBENT", 0, 0x4B47, 0 },
+{ "linux/kd.h", "KDSKBLED", 0, 0x4B65, 0 },
+{ "linux/kd.h", "KDSKBMETA", 0, 0x4B63, 0 },
+{ "linux/kd.h", "KDSKBMODE", 0, 0x4B45, 0 },
+{ "linux/kd.h", "KDSKBSENT", 0, 0x4B49, 0 },
+{ "linux/kd.h", "KDUNMAPDISP", 0, 0x4B3D, 0 },
+{ "linux/kd.h", "KIOCSOUND", 0, 0x4B2F, 0 },
+{ "linux/kd.h", "PIO_CMAP", 0, 0x4B71, 0 },
+{ "linux/kd.h", "PIO_FONT", 0, 0x4B61, 0 },
+{ "linux/kd.h", "PIO_FONTRESET", 0, 0x4B6D, 0 },
+{ "linux/kd.h", "PIO_FONTX", 0, 0x4B6C, 0 },
+{ "linux/kd.h", "PIO_SCRNMAP", 0, 0x4B41, 0 },
+{ "linux/kd.h", "PIO_UNIMAP", 0, 0x4B67, 0 },
+{ "linux/kd.h", "PIO_UNIMAPCLR", 0, 0x4B68, 0 },
+{ "linux/kd.h", "PIO_UNISCRNMAP", 0, 0x4B6A, 0 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_EVENT", _IOC_READ|_IOC_WRITE, 0x4b08, 0x20 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b02, 0x58 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_ADDRESS_WATCH", _IOC_WRITE, 0x4b0f, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_REGISTER", _IOC_WRITE, 0x4b0d, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_UNREGISTER", _IOC_WRITE, 0x4b0e, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_WAVE_CONTROL", _IOC_WRITE, 0x4b10, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_EVENT", _IOC_WRITE, 0x4b09, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b03, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_CLOCK_COUNTERS", _IOC_READ|_IOC_WRITE, 0x4b05, 0x28 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_PROCESS_APERTURES", _IOC_READ, 0x4b06, 0x190 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
+{ "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_UPDATE_QUEUE", _IOC_WRITE, 0x4b07, 0x18 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_WAIT_EVENTS", _IOC_READ|_IOC_WRITE, 0x4b0c, 0x18 },
+{ "linux/kvm.h", "KVM_ALLOCATE_RMA", _IOC_READ, 0xaea9, 0x08 },
+{ "linux/kvm.h", "KVM_ARM_PREFERRED_TARGET", _IOC_READ, 0xaeaf, 0x20 },
+{ "linux/kvm.h", "KVM_ARM_SET_DEVICE_ADDR", _IOC_WRITE, 0xaeab, 0x10 },
+{ "linux/kvm.h", "KVM_ARM_VCPU_INIT", _IOC_WRITE, 0xaeae, 0x20 },
+{ "linux/kvm.h", "KVM_ASSIGN_DEV_IRQ", _IOC_WRITE, 0xae70, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_PCI_DEVICE", _IOC_READ, 0xae69, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_INTX_MASK", _IOC_WRITE, 0xaea4, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_ENTRY", _IOC_WRITE, 0xae74, 0x10 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_NR", _IOC_WRITE, 0xae73, 0x08 },
+{ "linux/kvm.h", "KVM_CHECK_EXTENSION", _IOC_NONE, 0xae03, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_DEVICE", _IOC_READ|_IOC_WRITE, 0xaee0, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_IRQCHIP", _IOC_NONE, 0xae60, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT", _IOC_NONE, 0xae64, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT2", _IOC_WRITE, 0xae77, 0x40 },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE", _IOC_WRITE, 0xaea8, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE_64", _IOC_WRITE, 0xaea8, 0x20 },
+{ "linux/kvm.h", "KVM_CREATE_VCPU", _IOC_NONE, 0xae41, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_VM", _IOC_NONE, 0xae01, 0x00 },
+{ "linux/kvm.h", "KVM_DEASSIGN_DEV_IRQ", _IOC_WRITE, 0xae75, 0x40 },
+{ "linux/kvm.h", "KVM_DEASSIGN_PCI_DEVICE", _IOC_WRITE, 0xae72, 0x40 },
+{ "linux/kvm.h", "KVM_DIRTY_TLB", _IOC_WRITE, 0xaeaa, 0x10 },
+{ "linux/kvm.h", "KVM_ENABLE_CAP", _IOC_WRITE, 0xaea3, 0x68 },
+{ "linux/kvm.h", "KVM_GET_API_VERSION", _IOC_NONE, 0xae00, 0x00 },
+{ "linux/kvm.h", "KVM_GET_CLOCK", _IOC_READ, 0xae7c, 0x30 },
+{ "linux/kvm.h", "KVM_GET_CPUID2", _IOC_READ|_IOC_WRITE, 0xae91, 0x08 },
+{ "linux/kvm.h", "KVM_GET_DEBUGREGS", _IOC_READ, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_GET_DEVICE_ATTR", _IOC_WRITE, 0xaee2, 0x18 },
+{ "linux/kvm.h", "KVM_GET_DIRTY_LOG", _IOC_WRITE, 0xae42, 0x10 },
+{ "linux/kvm.h", "KVM_GET_EMULATED_CPUID", _IOC_READ|_IOC_WRITE, 0xae09, 0x08 },
+{ "linux/kvm.h", "KVM_GET_FPU", _IOC_READ, 0xae8c, 0x1a0 },
+{ "linux/kvm.h", "KVM_GET_IRQCHIP", _IOC_READ|_IOC_WRITE, 0xae62, 0x208 },
+{ "linux/kvm.h", "KVM_GET_LAPIC", _IOC_READ, 0xae8e, 0x400 },
+{ "linux/kvm.h", "KVM_GET_MP_STATE", _IOC_READ, 0xae98, 0x04 },
+{ "linux/kvm.h", "KVM_GET_MSRS", _IOC_READ|_IOC_WRITE, 0xae88, 0x08 },
+{ "linux/kvm.h", "KVM_GET_MSR_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae02, 0x04 },
+{ "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 },
+{ "linux/kvm.h", "KVM_GET_PIT2", _IOC_READ, 0xae9f, 0x70 },
+{ "linux/kvm.h", "KVM_GET_REGS", _IOC_READ, 0xae81, 0x90 },
+{ "linux/kvm.h", "KVM_GET_REG_LIST", _IOC_READ|_IOC_WRITE, 0xaeb0, 0x08 },
+{ "linux/kvm.h", "KVM_GET_SREGS", _IOC_READ, 0xae83, 0x138 },
+{ "linux/kvm.h", "KVM_GET_SUPPORTED_CPUID", _IOC_READ|_IOC_WRITE, 0xae05, 0x08 },
+{ "linux/kvm.h", "KVM_GET_TSC_KHZ", _IOC_NONE, 0xaea3, 0x00 },
+{ "linux/kvm.h", "KVM_GET_VCPU_EVENTS", _IOC_READ, 0xae9f, 0x40 },
+{ "linux/kvm.h", "KVM_GET_VCPU_MMAP_SIZE", _IOC_NONE, 0xae04, 0x00 },
+{ "linux/kvm.h", "KVM_GET_XCRS", _IOC_READ, 0xaea6, 0x188 },
+{ "linux/kvm.h", "KVM_GET_XSAVE", _IOC_READ, 0xaea4, 0x1000 },
+{ "linux/kvm.h", "KVM_HAS_DEVICE_ATTR", _IOC_WRITE, 0xaee3, 0x18 },
+{ "linux/kvm.h", "KVM_INTERRUPT", _IOC_WRITE, 0xae86, 0x04 },
+{ "linux/kvm.h", "KVM_IOEVENTFD", _IOC_WRITE, 0xae79, 0x40 },
+{ "linux/kvm.h", "KVM_IRQFD", _IOC_WRITE, 0xae76, 0x20 },
+{ "linux/kvm.h", "KVM_IRQ_LINE", _IOC_WRITE, 0xae61, 0x08 },
+{ "linux/kvm.h", "KVM_IRQ_LINE_STATUS", _IOC_READ|_IOC_WRITE, 0xae67, 0x08 },
+{ "linux/kvm.h", "KVM_KVMCLOCK_CTRL", _IOC_NONE, 0xaead, 0x00 },
+{ "linux/kvm.h", "KVM_NMI", _IOC_NONE, 0xae9a, 0x00 },
+{ "linux/kvm.h", "KVM_PPC_ALLOCATE_HTAB", _IOC_READ|_IOC_WRITE, 0xaea7, 0x04 },
+{ "linux/kvm.h", "KVM_PPC_GET_HTAB_FD", _IOC_WRITE, 0xaeaa, 0x20 },
+{ "linux/kvm.h", "KVM_PPC_GET_PVINFO", _IOC_WRITE, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_PPC_GET_SMMU_INFO", _IOC_READ, 0xaea6, 0x250 },
+{ "linux/kvm.h", "KVM_PPC_RTAS_DEFINE_TOKEN", _IOC_WRITE, 0xaeac, 0x80 },
+{ "linux/kvm.h", "KVM_REGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae67, 0x10 },
+{ "linux/kvm.h", "KVM_REINJECT_CONTROL", _IOC_NONE, 0xae71, 0x00 },
+{ "linux/kvm.h", "KVM_RUN", _IOC_NONE, 0xae80, 0x00 },
+{ "linux/kvm.h", "KVM_S390_ENABLE_SIE", _IOC_NONE, 0xae06, 0x00 },
+{ "linux/kvm.h", "KVM_S390_GET_IRQ_STATE", _IOC_WRITE, 0xaeb6, 0x20 },
+{ "linux/kvm.h", "KVM_S390_GET_SKEYS", _IOC_WRITE, 0xaeb2, 0x40 },
+{ "linux/kvm.h", "KVM_S390_INITIAL_RESET", _IOC_NONE, 0xae97, 0x00 },
+{ "linux/kvm.h", "KVM_S390_INTERRUPT", _IOC_WRITE, 0xae94, 0x10 },
+{ "linux/kvm.h", "KVM_S390_IRQ", _IOC_WRITE, 0xaeb4, 0x48 },
+{ "linux/kvm.h", "KVM_S390_MEM_OP", _IOC_WRITE, 0xaeb1, 0x40 },
+{ "linux/kvm.h", "KVM_S390_SET_INITIAL_PSW", _IOC_WRITE, 0xae96, 0x10 },
+{ "linux/kvm.h", "KVM_S390_SET_IRQ_STATE", _IOC_WRITE, 0xaeb5, 0x20 },
+{ "linux/kvm.h", "KVM_S390_SET_SKEYS", _IOC_WRITE, 0xaeb3, 0x40 },
+{ "linux/kvm.h", "KVM_S390_STORE_STATUS", _IOC_WRITE, 0xae95, 0x08 },
+{ "linux/kvm.h", "KVM_S390_UCAS_MAP", _IOC_WRITE, 0xae50, 0x18 },
+{ "linux/kvm.h", "KVM_S390_UCAS_UNMAP", _IOC_WRITE, 0xae51, 0x18 },
+{ "linux/kvm.h", "KVM_S390_VCPU_FAULT", _IOC_WRITE, 0xae52, 0x08 },
+{ "linux/kvm.h", "KVM_SET_BOOT_CPU_ID", _IOC_NONE, 0xae78, 0x00 },
+{ "linux/kvm.h", "KVM_SET_CLOCK", _IOC_WRITE, 0xae7b, 0x30 },
+{ "linux/kvm.h", "KVM_SET_CPUID", _IOC_WRITE, 0xae8a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_CPUID2", _IOC_WRITE, 0xae90, 0x08 },
+{ "linux/kvm.h", "KVM_SET_DEBUGREGS", _IOC_WRITE, 0xaea2, 0x80 },
+{ "linux/kvm.h", "KVM_SET_DEVICE_ATTR", _IOC_WRITE, 0xaee1, 0x18 },
+{ "linux/kvm.h", "KVM_SET_FPU", _IOC_WRITE, 0xae8d, 0x1a0 },
+{ "linux/kvm.h", "KVM_SET_GSI_ROUTING", _IOC_WRITE, 0xae6a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_GUEST_DEBUG", _IOC_WRITE, 0xae9b, 0x48 },
+{ "linux/kvm.h", "KVM_SET_IDENTITY_MAP_ADDR", _IOC_WRITE, 0xae48, 0x08 },
+{ "linux/kvm.h", "KVM_SET_IRQCHIP", _IOC_READ, 0xae63, 0x208 },
+{ "linux/kvm.h", "KVM_SET_LAPIC", _IOC_WRITE, 0xae8f, 0x400 },
+{ "linux/kvm.h", "KVM_SET_MEMORY_ALIAS", _IOC_WRITE, 0xae43, 0x20 },
+{ "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_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 },
+{ "linux/kvm.h", "KVM_SET_PIT2", _IOC_WRITE, 0xaea0, 0x70 },
+{ "linux/kvm.h", "KVM_SET_REGS", _IOC_WRITE, 0xae82, 0x90 },
+{ "linux/kvm.h", "KVM_SET_SIGNAL_MASK", _IOC_WRITE, 0xae8b, 0x04 },
+{ "linux/kvm.h", "KVM_SET_SREGS", _IOC_WRITE, 0xae84, 0x138 },
+{ "linux/kvm.h", "KVM_SET_TSC_KHZ", _IOC_NONE, 0xaea2, 0x00 },
+{ "linux/kvm.h", "KVM_SET_TSS_ADDR", _IOC_NONE, 0xae47, 0x00 },
+{ "linux/kvm.h", "KVM_SET_USER_MEMORY_REGION", _IOC_WRITE, 0xae46, 0x20 },
+{ "linux/kvm.h", "KVM_SET_VAPIC_ADDR", _IOC_WRITE, 0xae93, 0x08 },
+{ "linux/kvm.h", "KVM_SET_VCPU_EVENTS", _IOC_WRITE, 0xaea0, 0x40 },
+{ "linux/kvm.h", "KVM_SET_XCRS", _IOC_WRITE, 0xaea7, 0x188 },
+{ "linux/kvm.h", "KVM_SET_XSAVE", _IOC_WRITE, 0xaea5, 0x1000 },
+{ "linux/kvm.h", "KVM_SIGNAL_MSI", _IOC_WRITE, 0xaea5, 0x20 },
+{ "linux/kvm.h", "KVM_SMI", _IOC_NONE, 0xaeb7, 0x00 },
+{ "linux/kvm.h", "KVM_TPR_ACCESS_REPORTING", _IOC_READ|_IOC_WRITE, 0xae92, 0x28 },
+{ "linux/kvm.h", "KVM_TRANSLATE", _IOC_READ|_IOC_WRITE, 0xae85, 0x18 },
+{ "linux/kvm.h", "KVM_UNREGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae68, 0x10 },
+{ "linux/kvm.h", "KVM_X86_GET_MCE_CAP_SUPPORTED", _IOC_READ, 0xae9d, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SETUP_MCE", _IOC_WRITE, 0xae9c, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SET_MCE", _IOC_WRITE, 0xae9e, 0x40 },
+{ "linux/kvm.h", "KVM_XEN_HVM_CONFIG", _IOC_WRITE, 0xae7a, 0x38 },
+{ "linux/lightnvm.h", "NVM_DEV_CREATE", _IOC_WRITE, 0x4c22, 0x80 },
+{ "linux/lightnvm.h", "NVM_DEV_FACTORY", _IOC_WRITE, 0x4c25, 0x24 },
+{ "linux/lightnvm.h", "NVM_DEV_INIT", _IOC_WRITE, 0x4c24, 0x2c },
+{ "linux/lightnvm.h", "NVM_DEV_REMOVE", _IOC_WRITE, 0x4c23, 0x24 },
+{ "linux/lightnvm.h", "NVM_GET_DEVICES", _IOC_READ, 0x4c21, 0x1000 },
+{ "linux/lightnvm.h", "NVM_INFO", _IOC_READ|_IOC_WRITE, 0x4c20, 0x1000 },
+{ "linux/lirc.h", "LIRC_GET_FEATURES", _IOC_READ, 0x6900, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_LENGTH", _IOC_READ, 0x690f, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_PULSE", _IOC_READ, 0x690b, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_SPACE", _IOC_READ, 0x690d, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_TIMEOUT", _IOC_READ, 0x6909, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_PULSE", _IOC_READ, 0x690a, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_SPACE", _IOC_READ, 0x690c, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_TIMEOUT", _IOC_READ, 0x6908, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_CARRIER", _IOC_READ, 0x6904, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_DUTY_CYCLE", _IOC_READ, 0x6906, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_MODE", _IOC_READ, 0x6902, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_RESOLUTION", _IOC_READ, 0x6907, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_CARRIER", _IOC_READ, 0x6903, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_DUTY_CYCLE", _IOC_READ, 0x6905, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_MODE", _IOC_READ, 0x6901, 0x04 },
+{ "linux/lirc.h", "LIRC_NOTIFY_DECODE", _IOC_NONE, 0x6920, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_END", _IOC_NONE, 0x6922, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_START", _IOC_NONE, 0x6921, 0x00 },
+{ "linux/lirc.h", "LIRC_SET_MEASURE_CARRIER_MODE", _IOC_WRITE, 0x691d, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER", _IOC_WRITE, 0x6914, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER_RANGE", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE", _IOC_WRITE, 0x6916, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE_RANGE", _IOC_WRITE, 0x691e, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER", _IOC_WRITE, 0x691c, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_PULSE", _IOC_WRITE, 0x691a, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_SPACE", _IOC_WRITE, 0x691b, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_MODE", _IOC_WRITE, 0x6912, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT", _IOC_WRITE, 0x6918, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT_REPORTS", _IOC_WRITE, 0x6919, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_CARRIER", _IOC_WRITE, 0x6913, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_DUTY_CYCLE", _IOC_WRITE, 0x6915, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_MODE", _IOC_WRITE, 0x6911, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_TRANSMITTER_MASK", _IOC_WRITE, 0x6917, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_WIDEBAND_RECEIVER", _IOC_WRITE, 0x6923, 0x04 },
+{ "linux/loop.h", "LOOP_CHANGE_FD", 0, 0x4C06, 0 },
+{ "linux/loop.h", "LOOP_CLR_FD", 0, 0x4C01, 0 },
+{ "linux/loop.h", "LOOP_CTL_ADD", 0, 0x4C80, 0 },
+{ "linux/loop.h", "LOOP_CTL_GET_FREE", 0, 0x4C82, 0 },
+{ "linux/loop.h", "LOOP_CTL_REMOVE", 0, 0x4C81, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS", 0, 0x4C03, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS64", 0, 0x4C05, 0 },
+{ "linux/loop.h", "LOOP_SET_CAPACITY", 0, 0x4C07, 0 },
+{ "linux/loop.h", "LOOP_SET_DIRECT_IO", 0, 0x4C08, 0 },
+{ "linux/loop.h", "LOOP_SET_FD", 0, 0x4C00, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS", 0, 0x4C02, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS64", 0, 0x4C04, 0 },
+{ "linux/mISDNif.h", "IMADDTIMER", _IOC_READ, 0x4940, 0x04 },
+{ "linux/mISDNif.h", "IMCLEAR_L2", _IOC_READ, 0x4946, 0x04 },
+{ "linux/mISDNif.h", "IMCTRLREQ", _IOC_READ, 0x4945, 0x04 },
+{ "linux/mISDNif.h", "IMDELTIMER", _IOC_READ, 0x4941, 0x04 },
+{ "linux/mISDNif.h", "IMGETCOUNT", _IOC_READ, 0x4943, 0x04 },
+{ "linux/mISDNif.h", "IMGETDEVINFO", _IOC_READ, 0x4944, 0x04 },
+{ "linux/mISDNif.h", "IMGETVERSION", _IOC_READ, 0x4942, 0x04 },
+{ "linux/mISDNif.h", "IMHOLD_L1", _IOC_READ, 0x4948, 0x04 },
+{ "linux/mISDNif.h", "IMSETDEVNAME", _IOC_READ, 0x4947, 0x18 },
+{ "linux/matroxfb.h", "MATROXFB_GET_ALL_OUTPUTS", _IOC_READ, 0x6efb, 0x08 },
+{ "linux/matroxfb.h", "MATROXFB_GET_AVAILABLE_OUTPUTS", _IOC_READ, 0x6ef9, 0x08 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_CONNECTION", _IOC_READ, 0x6ef8, 0x08 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_MODE", _IOC_READ|_IOC_WRITE, 0x6efa, 0x08 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_CONNECTION", _IOC_WRITE, 0x6ef8, 0x08 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_MODE", _IOC_WRITE, 0x6efa, 0x08 },
+{ "linux/media.h", "MEDIA_IOC_DEVICE_INFO", _IOC_READ|_IOC_WRITE, 0x7c00, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_ENTITIES", _IOC_READ|_IOC_WRITE, 0x7c01, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_LINKS", _IOC_READ|_IOC_WRITE, 0x7c02, 0x28 },
+{ "linux/media.h", "MEDIA_IOC_G_TOPOLOGY", _IOC_READ|_IOC_WRITE, 0x7c04, 0x48 },
+{ "linux/media.h", "MEDIA_IOC_SETUP_LINK", _IOC_READ|_IOC_WRITE, 0x7c03, 0x34 },
+{ "linux/mei.h", "IOCTL_MEI_CONNECT_CLIENT", _IOC_READ|_IOC_WRITE, 0x4801, 0x10 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_GET", _IOC_READ, 0x4803, 0x04 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_SET", _IOC_WRITE, 0x4802, 0x04 },
+{ "linux/meye.h", "MEYEIOC_G_PARAMS", _IOC_READ, 0x76c0, 0x06 },
+{ "linux/meye.h", "MEYEIOC_QBUF_CAPT", _IOC_WRITE, 0x76c2, 0x04 },
+{ "linux/meye.h", "MEYEIOC_STILLCAPT", _IOC_NONE, 0x76c4, 0x00 },
+{ "linux/meye.h", "MEYEIOC_STILLJCAPT", _IOC_READ, 0x76c5, 0x04 },
+{ "linux/meye.h", "MEYEIOC_SYNC", _IOC_READ|_IOC_WRITE, 0x76c3, 0x04 },
+{ "linux/meye.h", "MEYEIOC_S_PARAMS", _IOC_WRITE, 0x76c1, 0x06 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_ADD_DEVICE", _IOC_READ|_IOC_WRITE, 0x7301, 0x08 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_CONFIG_CHANGE", _IOC_READ|_IOC_WRITE, 0x7305, 0x08 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_COPY_DESC", _IOC_READ|_IOC_WRITE, 0x7302, 0x08 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_CMD", _IOC_READ|_IOC_WRITE, 0xb300, 0x48 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_MULTI_CMD", _IOC_READ|_IOC_WRITE, 0xb301, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_GETBITS", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETCOUNTER", _IOC_READ, 0x6d09, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_GETFREQ", _IOC_READ, 0x6d02, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_GETOFFSET", _IOC_NONE, 0x6d00, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETRES", _IOC_READ, 0x6d01, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_MMAPAVAIL", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_ATTRIBUTES", _IOC_READ, 0x7210, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_VOLUME_ID", _IOC_READ, 0x7213, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_SET_ATTRIBUTES", _IOC_WRITE, 0x7211, 0x04 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_BOTH", _IOC_READ, 0x7201, 0x230 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_SHORT", _IOC_READ, 0x7202, 0x230 },
+{ "linux/mtio.h", "MTIOCGET", _IOC_READ, 0x6d02, 0x30 },
+{ "linux/mtio.h", "MTIOCPOS", _IOC_READ, 0x6d03, 0x08 },
+{ "linux/mtio.h", "MTIOCTOP", _IOC_WRITE, 0x6d01, 0x08 },
+{ "linux/nbd.h", "NBD_CLEAR_QUE", _IOC_NONE, 0xab05, 0x00 },
+{ "linux/nbd.h", "NBD_CLEAR_SOCK", _IOC_NONE, 0xab04, 0x00 },
+{ "linux/nbd.h", "NBD_DISCONNECT", _IOC_NONE, 0xab08, 0x00 },
+{ "linux/nbd.h", "NBD_DO_IT", _IOC_NONE, 0xab03, 0x00 },
+{ "linux/nbd.h", "NBD_PRINT_DEBUG", _IOC_NONE, 0xab06, 0x00 },
+{ "linux/nbd.h", "NBD_SET_BLKSIZE", _IOC_NONE, 0xab01, 0x00 },
+{ "linux/nbd.h", "NBD_SET_FLAGS", _IOC_NONE, 0xab0a, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE", _IOC_NONE, 0xab02, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE_BLOCKS", _IOC_NONE, 0xab07, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SOCK", _IOC_NONE, 0xab00, 0x00 },
+{ "linux/nbd.h", "NBD_SET_TIMEOUT", _IOC_NONE, 0xab09, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_CONN_LOGGED_IN", _IOC_NONE, 0x6e03, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETCHARSETS", _IOC_READ|_IOC_WRITE, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_GETDENTRYTTL", _IOC_WRITE, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID", _IOC_WRITE, 0x6e02, 0x02 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID2", _IOC_WRITE, 0x6e02, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETOBJECTNAME", _IOC_READ|_IOC_WRITE, 0x6e09, 0x18 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETPRIVATEDATA", _IOC_READ|_IOC_WRITE, 0x6e0a, 0x10 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETROOT", _IOC_WRITE, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO", _IOC_READ|_IOC_WRITE, 0x6e04, 0x28 },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO_V2", _IOC_READ|_IOC_WRITE, 0x6e04, 0x30 },
+{ "linux/ncp_fs.h", "NCP_IOC_LOCKUNLOCK", _IOC_READ, 0x6e07, 0x14 },
+{ "linux/ncp_fs.h", "NCP_IOC_NCPREQUEST", _IOC_READ, 0x6e01, 0x10 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETCHARSETS", _IOC_READ, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_SETDENTRYTTL", _IOC_READ, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETOBJECTNAME", _IOC_READ, 0x6e09, 0x18 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETPRIVATEDATA", _IOC_READ, 0x6e0a, 0x10 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETROOT", _IOC_READ, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SET_SIGN_WANTED", _IOC_WRITE, 0x6e06, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_INIT", _IOC_READ, 0x6e05, 0x18 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_WANTED", _IOC_READ, 0x6e06, 0x04 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_CAP", _IOC_READ|_IOC_WRITE, 0x4e01, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_START", _IOC_READ|_IOC_WRITE, 0x4e02, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_STATUS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x30 },
+{ "linux/ndctl.h", "ND_IOCTL_CALL", _IOC_READ|_IOC_WRITE, 0x4e0a, 0x40 },
+{ "linux/ndctl.h", "ND_IOCTL_CLEAR_ERROR", _IOC_READ|_IOC_WRITE, 0x4e04, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_DIMM_FLAGS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e05, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_SIZE", _IOC_READ|_IOC_WRITE, 0x4e04, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_SET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e06, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART", _IOC_READ|_IOC_WRITE, 0x4e01, 0x84 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART_THRESHOLD", _IOC_READ|_IOC_WRITE, 0x4e02, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_VENDOR", _IOC_READ|_IOC_WRITE, 0x4e09, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CHANGE_CPMODE", _IOC_WRITE, 0x6e80, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CLEAN_SEGMENTS", _IOC_WRITE, 0x6e88, 0x78 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_DELETE_CHECKPOINT", _IOC_WRITE, 0x6e81, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_BDESCS", _IOC_READ|_IOC_WRITE, 0x6e87, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPINFO", _IOC_READ, 0x6e82, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPSTAT", _IOC_READ, 0x6e83, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUINFO", _IOC_READ, 0x6e84, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUSTAT", _IOC_READ, 0x6e85, 0x30 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_VINFO", _IOC_READ|_IOC_WRITE, 0x6e86, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_RESIZE", _IOC_WRITE, 0x6e8b, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_ALLOC_RANGE", _IOC_WRITE, 0x6e8c, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_SUINFO", _IOC_WRITE, 0x6e8d, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SYNC", _IOC_READ, 0x6e8a, 0x08 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ADMIN_CMD", _IOC_READ|_IOC_WRITE, 0x4e41, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ID", _IOC_NONE, 0x4e40, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_IO_CMD", _IOC_READ|_IOC_WRITE, 0x4e43, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESCAN", _IOC_NONE, 0x4e46, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESET", _IOC_NONE, 0x4e44, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBMIT_IO", _IOC_WRITE, 0x4e42, 0x30 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBSYS_RESET", _IOC_NONE, 0x4e45, 0x00 },
+{ "linux/nvram.h", "NVRAM_INIT", _IOC_NONE, 0x7040, 0x00 },
+{ "linux/nvram.h", "NVRAM_SETCKS", _IOC_NONE, 0x7041, 0x00 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AEWB_CFG", _IOC_READ|_IOC_WRITE, 0x56c3, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AF_CFG", _IOC_READ|_IOC_WRITE, 0x56c5, 0x4c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_CCDC_CFG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x38 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_HIST_CFG", _IOC_READ|_IOC_WRITE, 0x56c4, 0x30 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_PRV_CFG", _IOC_READ|_IOC_WRITE, 0x56c2, 0x70 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_EN", _IOC_READ|_IOC_WRITE, 0x56c7, 0x08 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_REQ", _IOC_READ|_IOC_WRITE, 0x56c6, 0x28 },
+{ "linux/omapfb.h", "OMAPFB_CTRL_TEST", _IOC_WRITE, 0x4f2e, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_CAPS", _IOC_READ, 0x4f2a, 0x0c },
+{ "linux/omapfb.h", "OMAPFB_GET_COLOR_KEY", _IOC_WRITE, 0x4f33, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_GET_DISPLAY_INFO", _IOC_READ, 0x4f3f, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_GET_OVERLAY_COLORMODE", _IOC_READ, 0x4f3b, 0x3c },
+{ "linux/omapfb.h", "OMAPFB_GET_UPDATE_MODE", _IOC_WRITE, 0x4f2b, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_VRAM_INFO", _IOC_READ, 0x4f3d, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_LCD_TEST", _IOC_WRITE, 0x4f2d, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_MEMORY_READ", _IOC_READ, 0x4f3a, 0x18 },
+{ "linux/omapfb.h", "OMAPFB_MIRROR", _IOC_WRITE, 0x4f1f, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_MEM", _IOC_WRITE, 0x4f38, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_PLANE", _IOC_WRITE, 0x4f35, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_MEM", _IOC_WRITE, 0x4f37, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_PLANE", _IOC_WRITE, 0x4f34, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SET_COLOR_KEY", _IOC_WRITE, 0x4f32, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_SET_TEARSYNC", _IOC_WRITE, 0x4f3e, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SET_UPDATE_MODE", _IOC_WRITE, 0x4f28, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_SYNC_GFX", _IOC_NONE, 0x4f25, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW", _IOC_WRITE, 0x4f36, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW_OLD", _IOC_WRITE, 0x4f2f, 0x14 },
+{ "linux/omapfb.h", "OMAPFB_VSYNC", _IOC_NONE, 0x4f26, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORGO", _IOC_NONE, 0x4f3c, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ID", _IOC_READ, 0x2407, 0x08 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PAUSE_OUTPUT", _IOC_WRITE, 0x2409, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PERIOD", _IOC_WRITE, 0x2404, 0x08 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_REFRESH", _IOC_NONE, 0x2402, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_RESET", _IOC_NONE, 0x2403, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_BPF", _IOC_WRITE, 0x2408, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_FILTER", _IOC_WRITE, 0x2406, 0x08 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_OUTPUT", _IOC_NONE, 0x2405, 0x00 },
+{ "linux/phantom.h", "PHN_GETREG", _IOC_READ|_IOC_WRITE, 0x7005, 0x08 },
+{ "linux/phantom.h", "PHN_GETREGS", _IOC_READ|_IOC_WRITE, 0x7007, 0x28 },
+{ "linux/phantom.h", "PHN_GET_REG", _IOC_READ|_IOC_WRITE, 0x7000, 0x08 },
+{ "linux/phantom.h", "PHN_GET_REGS", _IOC_READ|_IOC_WRITE, 0x7002, 0x08 },
+{ "linux/phantom.h", "PHN_NOT_OH", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/phantom.h", "PHN_SETREG", _IOC_WRITE, 0x7006, 0x08 },
+{ "linux/phantom.h", "PHN_SETREGS", _IOC_WRITE, 0x7008, 0x28 },
+{ "linux/phantom.h", "PHN_SET_REG", _IOC_WRITE, 0x7001, 0x08 },
+{ "linux/phantom.h", "PHN_SET_REGS", _IOC_WRITE, 0x7003, 0x08 },
+{ "linux/pktcdvd.h", "PACKET_CTRL_CMD", _IOC_READ|_IOC_WRITE, 0x5801, 0x18 },
+{ "linux/platform_data/media/si4713.h", "SI4713_IOC_MEASURE_RNL", _IOC_READ|_IOC_WRITE, 0x56c0, 0x1c },
+{ "linux/pmu.h", "PMU_IOC_CAN_SLEEP", _IOC_READ, 0x4205, 0x08 },
+{ "linux/pmu.h", "PMU_IOC_GET_BACKLIGHT", _IOC_READ, 0x4201, 0x08 },
+{ "linux/pmu.h", "PMU_IOC_GET_MODEL", _IOC_READ, 0x4203, 0x08 },
+{ "linux/pmu.h", "PMU_IOC_GRAB_BACKLIGHT", _IOC_READ, 0x4206, 0x08 },
+{ "linux/pmu.h", "PMU_IOC_HAS_ADB", _IOC_READ, 0x4204, 0x08 },
+{ "linux/pmu.h", "PMU_IOC_SET_BACKLIGHT", _IOC_WRITE, 0x4202, 0x08 },
+{ "linux/pmu.h", "PMU_IOC_SLEEP", _IOC_NONE, 0x4200, 0x00 },
+{ "linux/ppdev.h", "PPCLAIM", _IOC_NONE, 0x708b, 0x00 },
+{ "linux/ppdev.h", "PPCLRIRQ", _IOC_READ, 0x7093, 0x04 },
+{ "linux/ppdev.h", "PPDATADIR", _IOC_WRITE, 0x7090, 0x04 },
+{ "linux/ppdev.h", "PPEXCL", _IOC_NONE, 0x708f, 0x00 },
+{ "linux/ppdev.h", "PPFCONTROL", _IOC_WRITE, 0x708e, 0x02 },
+{ "linux/ppdev.h", "PPGETFLAGS", _IOC_READ, 0x709a, 0x04 },
+{ "linux/ppdev.h", "PPGETMODE", _IOC_READ, 0x7098, 0x04 },
+{ "linux/ppdev.h", "PPGETMODES", _IOC_READ, 0x7097, 0x04 },
+{ "linux/ppdev.h", "PPGETPHASE", _IOC_READ, 0x7099, 0x04 },
+{ "linux/ppdev.h", "PPGETTIME", _IOC_READ, 0x7095, 0x10 },
+{ "linux/ppdev.h", "PPNEGOT", _IOC_WRITE, 0x7091, 0x04 },
+{ "linux/ppdev.h", "PPRCONTROL", _IOC_READ, 0x7083, 0x01 },
+{ "linux/ppdev.h", "PPRDATA", _IOC_READ, 0x7085, 0x01 },
+{ "linux/ppdev.h", "PPRELEASE", _IOC_NONE, 0x708c, 0x00 },
+{ "linux/ppdev.h", "PPRSTATUS", _IOC_READ, 0x7081, 0x01 },
+{ "linux/ppdev.h", "PPSETFLAGS", _IOC_WRITE, 0x709b, 0x04 },
+{ "linux/ppdev.h", "PPSETMODE", _IOC_WRITE, 0x7080, 0x04 },
+{ "linux/ppdev.h", "PPSETPHASE", _IOC_WRITE, 0x7094, 0x04 },
+{ "linux/ppdev.h", "PPSETTIME", _IOC_WRITE, 0x7096, 0x10 },
+{ "linux/ppdev.h", "PPWCONTROL", _IOC_WRITE, 0x7084, 0x01 },
+{ "linux/ppdev.h", "PPWCTLONIRQ", _IOC_WRITE, 0x7092, 0x01 },
+{ "linux/ppdev.h", "PPWDATA", _IOC_WRITE, 0x7086, 0x01 },
+{ "linux/ppdev.h", "PPYIELD", _IOC_NONE, 0x708d, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTACH", _IOC_WRITE, 0x743d, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTCHAN", _IOC_WRITE, 0x7438, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCCONNECT", _IOC_WRITE, 0x743a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDETACH", _IOC_WRITE, 0x743c, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDISCONN", _IOC_NONE, 0x7439, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCGASYNCMAP", _IOC_READ, 0x7458, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGCHAN", _IOC_READ, 0x7437, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGDEBUG", _IOC_READ, 0x7441, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGFLAGS", _IOC_READ, 0x745a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGIDLE", _IOC_READ, 0x743f, 0x10 },
+{ "linux/ppp-ioctl.h", "PPPIOCGL2TPSTATS", _IOC_READ, 0x7436, 0x48 },
+{ "linux/ppp-ioctl.h", "PPPIOCGMRU", _IOC_READ, 0x7453, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGNPMODE", _IOC_READ|_IOC_WRITE, 0x744c, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCGRASYNCMAP", _IOC_READ, 0x7455, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGUNIT", _IOC_READ, 0x7456, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGXASYNCMAP", _IOC_READ, 0x7450, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCNEWUNIT", _IOC_READ|_IOC_WRITE, 0x743e, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSACTIVE", _IOC_WRITE, 0x7446, 0x10 },
+{ "linux/ppp-ioctl.h", "PPPIOCSASYNCMAP", _IOC_WRITE, 0x7457, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSCOMPRESS", _IOC_WRITE, 0x744d, 0x10 },
+{ "linux/ppp-ioctl.h", "PPPIOCSDEBUG", _IOC_WRITE, 0x7440, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSFLAGS", _IOC_WRITE, 0x7459, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMAXCID", _IOC_WRITE, 0x7451, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRRU", _IOC_WRITE, 0x743b, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRU", _IOC_WRITE, 0x7452, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSNPMODE", _IOC_WRITE, 0x744b, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSPASS", _IOC_WRITE, 0x7447, 0x10 },
+{ "linux/ppp-ioctl.h", "PPPIOCSRASYNCMAP", _IOC_WRITE, 0x7454, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSXASYNCMAP", _IOC_WRITE, 0x744f, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCXFERUNIT", _IOC_NONE, 0x744e, 0x00 },
+{ "linux/pps.h", "PPS_FETCH", _IOC_READ|_IOC_WRITE, 0x70a4, 0x08 },
+{ "linux/pps.h", "PPS_GETCAP", _IOC_READ, 0x70a3, 0x08 },
+{ "linux/pps.h", "PPS_GETPARAMS", _IOC_READ, 0x70a1, 0x08 },
+{ "linux/pps.h", "PPS_KC_BIND", _IOC_WRITE, 0x70a5, 0x08 },
+{ "linux/pps.h", "PPS_SETPARAMS", _IOC_WRITE, 0x70a2, 0x08 },
+{ "linux/pr.h", "IOC_PR_CLEAR", _IOC_WRITE, 0x70cd, 0x10 },
+{ "linux/pr.h", "IOC_PR_PREEMPT", _IOC_WRITE, 0x70cb, 0x18 },
+{ "linux/pr.h", "IOC_PR_PREEMPT_ABORT", _IOC_WRITE, 0x70cc, 0x18 },
+{ "linux/pr.h", "IOC_PR_REGISTER", _IOC_WRITE, 0x70c8, 0x18 },
+{ "linux/pr.h", "IOC_PR_RELEASE", _IOC_WRITE, 0x70ca, 0x10 },
+{ "linux/pr.h", "IOC_PR_RESERVE", _IOC_WRITE, 0x70c9, 0x10 },
+{ "linux/ptp_clock.h", "PTP_CLOCK_GETCAPS", _IOC_READ, 0x3d01, 0x50 },
+{ "linux/ptp_clock.h", "PTP_ENABLE_PPS", _IOC_WRITE, 0x3d04, 0x04 },
+{ "linux/ptp_clock.h", "PTP_EXTTS_REQUEST", _IOC_WRITE, 0x3d02, 0x10 },
+{ "linux/ptp_clock.h", "PTP_PEROUT_REQUEST", _IOC_WRITE, 0x3d03, 0x38 },
+{ "linux/ptp_clock.h", "PTP_PIN_GETFUNC", _IOC_READ|_IOC_WRITE, 0x3d06, 0x60 },
+{ "linux/ptp_clock.h", "PTP_PIN_SETFUNC", _IOC_WRITE, 0x3d07, 0x60 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET", _IOC_WRITE, 0x3d05, 0x340 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET_PRECISE", _IOC_READ|_IOC_WRITE, 0x3d08, 0x40 },
+{ "linux/radeonfb.h", "FBIO_RADEON_GET_MIRROR", _IOC_READ, 0x4003, 0x08 },
+{ "linux/radeonfb.h", "FBIO_RADEON_SET_MIRROR", _IOC_WRITE, 0x4004, 0x08 },
+{ "linux/raid/md_u.h", "ADD_NEW_DISK", _IOC_WRITE, 0x0921, 0x14 },
+{ "linux/raid/md_u.h", "CLEAR_ARRAY", _IOC_NONE, 0x0920, 0x00 },
+{ "linux/raid/md_u.h", "CLUSTERED_DISK_NACK", _IOC_NONE, 0x0935, 0x00 },
+{ "linux/raid/md_u.h", "GET_ARRAY_INFO", _IOC_READ, 0x0911, 0x48 },
+{ "linux/raid/md_u.h", "GET_BITMAP_FILE", _IOC_READ, 0x0915, 0x1000 },
+{ "linux/raid/md_u.h", "GET_DISK_INFO", _IOC_READ, 0x0912, 0x14 },
+{ "linux/raid/md_u.h", "HOT_ADD_DISK", _IOC_NONE, 0x0928, 0x00 },
+{ "linux/raid/md_u.h", "HOT_GENERATE_ERROR", _IOC_NONE, 0x092a, 0x00 },
+{ "linux/raid/md_u.h", "HOT_REMOVE_DISK", _IOC_NONE, 0x0922, 0x00 },
+{ "linux/raid/md_u.h", "PROTECT_ARRAY", _IOC_NONE, 0x0927, 0x00 },
+{ "linux/raid/md_u.h", "RAID_AUTORUN", _IOC_NONE, 0x0914, 0x00 },
+{ "linux/raid/md_u.h", "RAID_VERSION", _IOC_READ, 0x0910, 0x0c },
+{ "linux/raid/md_u.h", "RESTART_ARRAY_RW", _IOC_NONE, 0x0934, 0x00 },
+{ "linux/raid/md_u.h", "RUN_ARRAY", _IOC_WRITE, 0x0930, 0x0c },
+{ "linux/raid/md_u.h", "SET_ARRAY_INFO", _IOC_WRITE, 0x0923, 0x48 },
+{ "linux/raid/md_u.h", "SET_BITMAP_FILE", _IOC_WRITE, 0x092b, 0x04 },
+{ "linux/raid/md_u.h", "SET_DISK_FAULTY", _IOC_NONE, 0x0929, 0x00 },
+{ "linux/raid/md_u.h", "SET_DISK_INFO", _IOC_NONE, 0x0924, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY", _IOC_NONE, 0x0932, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY_RO", _IOC_NONE, 0x0933, 0x00 },
+{ "linux/raid/md_u.h", "UNPROTECT_ARRAY", _IOC_NONE, 0x0926, 0x00 },
+{ "linux/raid/md_u.h", "WRITE_RAID_INFO", _IOC_NONE, 0x0925, 0x00 },
+{ "linux/random.h", "RNDADDENTROPY", _IOC_WRITE, 0x5203, 0x08 },
+{ "linux/random.h", "RNDADDTOENTCNT", _IOC_WRITE, 0x5201, 0x04 },
+{ "linux/random.h", "RNDCLEARPOOL", _IOC_NONE, 0x5206, 0x00 },
+{ "linux/random.h", "RNDGETENTCNT", _IOC_READ, 0x5200, 0x04 },
+{ "linux/random.h", "RNDGETPOOL", _IOC_READ, 0x5202, 0x08 },
+{ "linux/random.h", "RNDZAPENTCNT", _IOC_NONE, 0x5204, 0x00 },
+{ "linux/raw.h", "RAW_GETBIND", _IOC_NONE, 0xac01, 0x00 },
+{ "linux/raw.h", "RAW_SETBIND", _IOC_NONE, 0xac00, 0x00 },
+{ "linux/reiserfs_fs.h", "REISERFS_IOC_UNPACK", _IOC_WRITE, 0xcd01, 0x08 },
+{ "linux/rfkill.h", "RFKILL_IOCTL_NOINPUT", _IOC_NONE, 0x5201, 0x00 },
+{ "linux/rio_mport_cdev.h", "RIO_ALLOC_DMA", _IOC_READ|_IOC_WRITE, 0x6d13, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_ADD", _IOC_WRITE, 0x6d17, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_DEL", _IOC_WRITE, 0x6d18, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d0a, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0c, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d09, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0b, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_FREE_DMA", _IOC_WRITE, 0x6d14, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_GET_EVENT_MASK", _IOC_READ, 0x6d0e, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_INBOUND", _IOC_READ|_IOC_WRITE, 0x6d11, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_OUTBOUND", _IOC_READ|_IOC_WRITE, 0x6d0f, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_GET_PROPERTIES", _IOC_READ, 0x6d04, 0x30 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_COMPTAG_SET", _IOC_WRITE, 0x6d02, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_HDID_SET", _IOC_WRITE, 0x6d01, 0x02 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_PORT_IDX_GET", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_LOCAL", _IOC_READ, 0x6d05, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_REMOTE", _IOC_READ, 0x6d07, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_LOCAL", _IOC_WRITE, 0x6d06, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_REMOTE", _IOC_WRITE, 0x6d08, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_SET_EVENT_MASK", _IOC_WRITE, 0x6d0d, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_TRANSFER", _IOC_READ|_IOC_WRITE, 0x6d15, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_INBOUND", _IOC_WRITE, 0x6d12, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_OUTBOUND", _IOC_WRITE, 0x6d10, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_WAIT_FOR_ASYNC", _IOC_WRITE, 0x6d16, 0x08 },
+{ "linux/rtc.h", "RTC_AIE_OFF", _IOC_NONE, 0x7002, 0x00 },
+{ "linux/rtc.h", "RTC_AIE_ON", _IOC_NONE, 0x7001, 0x00 },
+{ "linux/rtc.h", "RTC_ALM_READ", _IOC_READ, 0x7008, 0x24 },
+{ "linux/rtc.h", "RTC_ALM_SET", _IOC_WRITE, 0x7007, 0x24 },
+{ "linux/rtc.h", "RTC_EPOCH_READ", _IOC_READ, 0x700d, 0x08 },
+{ "linux/rtc.h", "RTC_EPOCH_SET", _IOC_WRITE, 0x700e, 0x08 },
+{ "linux/rtc.h", "RTC_IRQP_READ", _IOC_READ, 0x700b, 0x08 },
+{ "linux/rtc.h", "RTC_IRQP_SET", _IOC_WRITE, 0x700c, 0x08 },
+{ "linux/rtc.h", "RTC_PIE_OFF", _IOC_NONE, 0x7006, 0x00 },
+{ "linux/rtc.h", "RTC_PIE_ON", _IOC_NONE, 0x7005, 0x00 },
+{ "linux/rtc.h", "RTC_PLL_GET", _IOC_READ, 0x7011, 0x20 },
+{ "linux/rtc.h", "RTC_PLL_SET", _IOC_WRITE, 0x7012, 0x20 },
+{ "linux/rtc.h", "RTC_RD_TIME", _IOC_READ, 0x7009, 0x24 },
+{ "linux/rtc.h", "RTC_SET_TIME", _IOC_WRITE, 0x700a, 0x24 },
+{ "linux/rtc.h", "RTC_UIE_OFF", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/rtc.h", "RTC_UIE_ON", _IOC_NONE, 0x7003, 0x00 },
+{ "linux/rtc.h", "RTC_VL_CLR", _IOC_NONE, 0x7014, 0x00 },
+{ "linux/rtc.h", "RTC_VL_READ", _IOC_READ, 0x7013, 0x04 },
+{ "linux/rtc.h", "RTC_WIE_OFF", _IOC_NONE, 0x7010, 0x00 },
+{ "linux/rtc.h", "RTC_WIE_ON", _IOC_NONE, 0x700f, 0x00 },
+{ "linux/rtc.h", "RTC_WKALM_RD", _IOC_READ, 0x7010, 0x28 },
+{ "linux/rtc.h", "RTC_WKALM_SET", _IOC_WRITE, 0x700f, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREG", _IOC_READ|_IOC_WRITE, 0x7305, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREQ", _IOC_READ|_IOC_WRITE, 0x7304, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_BIND", _IOC_READ|_IOC_WRITE, 0x7301, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_CONNECT", _IOC_READ|_IOC_WRITE, 0x7303, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_MARK", _IOC_READ|_IOC_WRITE, 0x730f, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_SIGNAL", _IOC_READ|_IOC_WRITE, 0x7311, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_WAIT", _IOC_READ|_IOC_WRITE, 0x7310, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_GET_NODEIDS", _IOC_READ|_IOC_WRITE, 0x730e, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_LISTEN", _IOC_WRITE, 0x7302, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_READFROM", _IOC_READ|_IOC_WRITE, 0x730a, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_RECV", _IOC_READ|_IOC_WRITE, 0x7307, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_REG", _IOC_READ|_IOC_WRITE, 0x7308, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_SEND", _IOC_READ|_IOC_WRITE, 0x7306, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_UNREG", _IOC_READ|_IOC_WRITE, 0x7309, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_VREADFROM", _IOC_READ|_IOC_WRITE, 0x730c, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_VWRITETO", _IOC_READ|_IOC_WRITE, 0x730d, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_WRITETO", _IOC_READ|_IOC_WRITE, 0x730b, 0x28 },
+{ "linux/serio.h", "SPIOCSTYPE", _IOC_WRITE, 0x7101, 0x08 },
+{ "linux/sockios.h", "SIOCADDDLCI", 0, 0x8980, 0 },
+{ "linux/sockios.h", "SIOCADDMULTI", 0, 0x8931, 0 },
+{ "linux/sockios.h", "SIOCADDRT", 0, 0x890B, 0 },
+{ "linux/sockios.h", "SIOCBONDCHANGEACTIVE", 0, 0x8995, 0 },
+{ "linux/sockios.h", "SIOCBONDENSLAVE", 0, 0x8990, 0 },
+{ "linux/sockios.h", "SIOCBONDINFOQUERY", 0, 0x8994, 0 },
+{ "linux/sockios.h", "SIOCBONDRELEASE", 0, 0x8991, 0 },
+{ "linux/sockios.h", "SIOCBONDSETHWADDR", 0, 0x8992, 0 },
+{ "linux/sockios.h", "SIOCBONDSLAVEINFOQUERY", 0, 0x8993, 0 },
+{ "linux/sockios.h", "SIOCBRADDBR", 0, 0x89a0, 0 },
+{ "linux/sockios.h", "SIOCBRADDIF", 0, 0x89a2, 0 },
+{ "linux/sockios.h", "SIOCBRDELBR", 0, 0x89a1, 0 },
+{ "linux/sockios.h", "SIOCBRDELIF", 0, 0x89a3, 0 },
+{ "linux/sockios.h", "SIOCDARP", 0, 0x8953, 0 },
+{ "linux/sockios.h", "SIOCDELDLCI", 0, 0x8981, 0 },
+{ "linux/sockios.h", "SIOCDELMULTI", 0, 0x8932, 0 },
+{ "linux/sockios.h", "SIOCDELRT", 0, 0x890C, 0 },
+{ "linux/sockios.h", "SIOCDEVPRIVATE", 0, 0x89F0, 0 },
+{ "linux/sockios.h", "SIOCDIFADDR", 0, 0x8936, 0 },
+{ "linux/sockios.h", "SIOCDRARP", 0, 0x8960, 0 },
+{ "linux/sockios.h", "SIOCETHTOOL", 0, 0x8946, 0 },
+{ "linux/sockios.h", "SIOCGARP", 0, 0x8954, 0 },
+{ "linux/sockios.h", "SIOCGHWTSTAMP", 0, 0x89b1, 0 },
+{ "linux/sockios.h", "SIOCGIFADDR", 0, 0x8915, 0 },
+{ "linux/sockios.h", "SIOCGIFBR", 0, 0x8940, 0 },
+{ "linux/sockios.h", "SIOCGIFBRDADDR", 0, 0x8919, 0 },
+{ "linux/sockios.h", "SIOCGIFCONF", 0, 0x8912, 0 },
+{ "linux/sockios.h", "SIOCGIFCOUNT", 0, 0x8938, 0 },
+{ "linux/sockios.h", "SIOCGIFDSTADDR", 0, 0x8917, 0 },
+{ "linux/sockios.h", "SIOCGIFENCAP", 0, 0x8925, 0 },
+{ "linux/sockios.h", "SIOCGIFFLAGS", 0, 0x8913, 0 },
+{ "linux/sockios.h", "SIOCGIFHWADDR", 0, 0x8927, 0 },
+{ "linux/sockios.h", "SIOCGIFINDEX", 0, 0x8933, 0 },
+{ "linux/sockios.h", "SIOCGIFMAP", 0, 0x8970, 0 },
+{ "linux/sockios.h", "SIOCGIFMEM", 0, 0x891f, 0 },
+{ "linux/sockios.h", "SIOCGIFMETRIC", 0, 0x891d, 0 },
+{ "linux/sockios.h", "SIOCGIFMTU", 0, 0x8921, 0 },
+{ "linux/sockios.h", "SIOCGIFNAME", 0, 0x8910, 0 },
+{ "linux/sockios.h", "SIOCGIFNETMASK", 0, 0x891b, 0 },
+{ "linux/sockios.h", "SIOCGIFPFLAGS", 0, 0x8935, 0 },
+{ "linux/sockios.h", "SIOCGIFSLAVE", 0, 0x8929, 0 },
+{ "linux/sockios.h", "SIOCGIFTXQLEN", 0, 0x8942, 0 },
+{ "linux/sockios.h", "SIOCGIFVLAN", 0, 0x8982, 0 },
+{ "linux/sockios.h", "SIOCGMIIPHY", 0, 0x8947, 0 },
+{ "linux/sockios.h", "SIOCGMIIREG", 0, 0x8948, 0 },
+{ "linux/sockios.h", "SIOCGRARP", 0, 0x8961, 0 },
+{ "linux/sockios.h", "SIOCOUTQNSD", 0, 0x894B, 0 },
+{ "linux/sockios.h", "SIOCPROTOPRIVATE", 0, 0x89E0, 0 },
+{ "linux/sockios.h", "SIOCRTMSG", 0, 0x890D, 0 },
+{ "linux/sockios.h", "SIOCSARP", 0, 0x8955, 0 },
+{ "linux/sockios.h", "SIOCSHWTSTAMP", 0, 0x89b0, 0 },
+{ "linux/sockios.h", "SIOCSIFADDR", 0, 0x8916, 0 },
+{ "linux/sockios.h", "SIOCSIFBR", 0, 0x8941, 0 },
+{ "linux/sockios.h", "SIOCSIFBRDADDR", 0, 0x891a, 0 },
+{ "linux/sockios.h", "SIOCSIFDSTADDR", 0, 0x8918, 0 },
+{ "linux/sockios.h", "SIOCSIFENCAP", 0, 0x8926, 0 },
+{ "linux/sockios.h", "SIOCSIFFLAGS", 0, 0x8914, 0 },
+{ "linux/sockios.h", "SIOCSIFHWADDR", 0, 0x8924, 0 },
+{ "linux/sockios.h", "SIOCSIFHWBROADCAST", 0, 0x8937, 0 },
+{ "linux/sockios.h", "SIOCSIFLINK", 0, 0x8911, 0 },
+{ "linux/sockios.h", "SIOCSIFMAP", 0, 0x8971, 0 },
+{ "linux/sockios.h", "SIOCSIFMEM", 0, 0x8920, 0 },
+{ "linux/sockios.h", "SIOCSIFMETRIC", 0, 0x891e, 0 },
+{ "linux/sockios.h", "SIOCSIFMTU", 0, 0x8922, 0 },
+{ "linux/sockios.h", "SIOCSIFNAME", 0, 0x8923, 0 },
+{ "linux/sockios.h", "SIOCSIFNETMASK", 0, 0x891c, 0 },
+{ "linux/sockios.h", "SIOCSIFPFLAGS", 0, 0x8934, 0 },
+{ "linux/sockios.h", "SIOCSIFSLAVE", 0, 0x8930, 0 },
+{ "linux/sockios.h", "SIOCSIFTXQLEN", 0, 0x8943, 0 },
+{ "linux/sockios.h", "SIOCSIFVLAN", 0, 0x8983, 0 },
+{ "linux/sockios.h", "SIOCSMIIREG", 0, 0x8949, 0 },
+{ "linux/sockios.h", "SIOCSRARP", 0, 0x8962, 0 },
+{ "linux/sockios.h", "SIOCWANDEV", 0, 0x894A, 0 },
+{ "linux/sonet.h", "SONET_CLRDIAG", _IOC_READ|_IOC_WRITE, 0x6113, 0x04 },
+{ "linux/sonet.h", "SONET_GETDIAG", _IOC_READ, 0x6114, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRAMING", _IOC_READ, 0x6116, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRSENSE", _IOC_READ, 0x6117, 0x06 },
+{ "linux/sonet.h", "SONET_GETSTAT", _IOC_READ, 0x6110, 0x24 },
+{ "linux/sonet.h", "SONET_GETSTATZ", _IOC_READ, 0x6111, 0x24 },
+{ "linux/sonet.h", "SONET_SETDIAG", _IOC_READ|_IOC_WRITE, 0x6112, 0x04 },
+{ "linux/sonet.h", "SONET_SETFRAMING", _IOC_WRITE, 0x6115, 0x04 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1CAP", _IOC_READ, 0x7602, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1REM", _IOC_READ, 0x7603, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2CAP", _IOC_READ, 0x7604, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2REM", _IOC_READ, 0x7605, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBATFLAGS", _IOC_READ, 0x7607, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBLUE", _IOC_READ, 0x7608, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBRT", _IOC_READ, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGFAN", _IOC_READ, 0x760a, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGTEMP", _IOC_READ, 0x760c, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBLUE", _IOC_WRITE, 0x7609, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBRT", _IOC_WRITE, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSFAN", _IOC_WRITE, 0x760b, 0x01 },
+{ "linux/soundcard.h", "OSS_GETVERSION", _IOC_READ, 0x4d76, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_COPR_HALT", _IOC_READ|_IOC_WRITE, 0x4307, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_LOAD", _IOC_READ|_IOC_WRITE, 0x4301, 0xfb0 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCODE", _IOC_READ|_IOC_WRITE, 0x4303, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCVMSG", _IOC_READ, 0x4309, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RDATA", _IOC_READ|_IOC_WRITE, 0x4302, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RESET", _IOC_NONE, 0x4300, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RUN", _IOC_READ|_IOC_WRITE, 0x4306, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_SENDMSG", _IOC_READ|_IOC_WRITE, 0x4308, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WCODE", _IOC_WRITE, 0x4305, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WDATA", _IOC_WRITE, 0x4304, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_DSP_BIND_CHANNEL", _IOC_READ|_IOC_WRITE, 0x5041, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_CHANNELS", _IOC_READ|_IOC_WRITE, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETBLKSIZE", _IOC_READ|_IOC_WRITE, 0x5004, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCAPS", _IOC_READ, 0x500f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCHANNELMASK", _IOC_READ|_IOC_WRITE, 0x5040, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETFMTS", _IOC_READ, 0x500b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETIPTR", _IOC_READ, 0x5011, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETISPACE", _IOC_READ, 0x500d, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETODELAY", _IOC_READ, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOPTR", _IOC_READ, 0x5012, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOSPACE", _IOC_READ, 0x500c, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETSPDIF", _IOC_READ, 0x5043, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETTRIGGER", _IOC_READ, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPINBUF", _IOC_READ, 0x5013, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPOUTBUF", _IOC_READ, 0x5014, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_NONBLOCK", _IOC_NONE, 0x500e, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_POST", _IOC_NONE, 0x5008, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_PROFILE", _IOC_WRITE, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_RESET", _IOC_NONE, 0x5000, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETDUPLEX", _IOC_NONE, 0x5016, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFMT", _IOC_READ|_IOC_WRITE, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFRAGMENT", _IOC_READ|_IOC_WRITE, 0x500a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSPDIF", _IOC_WRITE, 0x5042, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSYNCRO", _IOC_NONE, 0x5015, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETTRIGGER", _IOC_WRITE, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SPEED", _IOC_READ|_IOC_WRITE, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_STEREO", _IOC_READ|_IOC_WRITE, 0x5003, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SUBDIVIDE", _IOC_READ|_IOC_WRITE, 0x5009, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SYNC", _IOC_NONE, 0x5001, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_FM_4OP_ENABLE", _IOC_WRITE, 0x510f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_FM_LOAD_INSTR", _IOC_WRITE, 0x5107, 0x28 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_INFO", _IOC_READ|_IOC_WRITE, 0x510c, 0x74 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUCMD", _IOC_READ|_IOC_WRITE, 0x6d02, 0x21 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUMODE", _IOC_READ|_IOC_WRITE, 0x6d01, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_PRETIME", _IOC_READ|_IOC_WRITE, 0x6d00, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_CTRLRATE", _IOC_READ|_IOC_WRITE, 0x5103, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETINCOUNT", _IOC_READ, 0x5105, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETOUTCOUNT", _IOC_READ, 0x5104, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETTIME", _IOC_READ, 0x5113, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRMIDIS", _IOC_READ, 0x510b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRSYNTHS", _IOC_READ, 0x510a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_OUTOFBAND", _IOC_WRITE, 0x5112, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PANIC", _IOC_NONE, 0x5111, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PERCMODE", _IOC_WRITE, 0x5106, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESET", _IOC_NONE, 0x5100, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESETSAMPLES", _IOC_WRITE, 0x5109, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_SYNC", _IOC_NONE, 0x5101, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_TESTMIDI", _IOC_WRITE, 0x5108, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_THRESHOLD", _IOC_WRITE, 0x510d, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_CONTROL", _IOC_READ|_IOC_WRITE, 0x5115, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_ID", _IOC_READ|_IOC_WRITE, 0x5114, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_INFO", _IOC_READ|_IOC_WRITE, 0x5102, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_MEMAVL", _IOC_READ|_IOC_WRITE, 0x510e, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_REMOVESAMPLE", _IOC_READ|_IOC_WRITE, 0x5116, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_TMR_CONTINUE", _IOC_NONE, 0x5404, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_METRONOME", _IOC_WRITE, 0x5407, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SELECT", _IOC_WRITE, 0x5408, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SOURCE", _IOC_READ|_IOC_WRITE, 0x5406, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_START", _IOC_NONE, 0x5402, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_STOP", _IOC_NONE, 0x5403, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TEMPO", _IOC_READ|_IOC_WRITE, 0x5405, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TIMEBASE", _IOC_READ|_IOC_WRITE, 0x5401, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_3DSE", _IOC_READ|_IOC_WRITE, 0x4d68, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_ACCESS", _IOC_READ|_IOC_WRITE, 0x4d66, 0x80 },
+{ "linux/soundcard.h", "SOUND_MIXER_AGC", _IOC_READ|_IOC_WRITE, 0x4d67, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_GETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d74, 0xa4 },
+{ "linux/soundcard.h", "SOUND_MIXER_INFO", _IOC_READ, 0x4d65, 0x5c },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE1", _IOC_READ|_IOC_WRITE, 0x4d6f, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE2", _IOC_READ|_IOC_WRITE, 0x4d70, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE3", _IOC_READ|_IOC_WRITE, 0x4d71, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE4", _IOC_READ|_IOC_WRITE, 0x4d72, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE5", _IOC_READ|_IOC_WRITE, 0x4d73, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_SETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d75, 0xa4 },
+{ "linux/soundcard.h", "SOUND_OLD_MIXER_INFO", _IOC_READ, 0x4d65, 0x30 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_BITS", _IOC_READ, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_CHANNELS", _IOC_READ, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_FILTER", _IOC_READ, 0x5007, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_RATE", _IOC_READ, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_WRITE_FILTER", _IOC_READ|_IOC_WRITE, 0x5007, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_BITS_PER_WORD", _IOC_READ, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_LSB_FIRST", _IOC_READ, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MAX_SPEED_HZ", _IOC_READ, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE", _IOC_READ, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE32", _IOC_READ, 0x6b05, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_BITS_PER_WORD", _IOC_WRITE, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_LSB_FIRST", _IOC_WRITE, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MAX_SPEED_HZ", _IOC_WRITE, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE", _IOC_WRITE, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE32", _IOC_WRITE, 0x6b05, 0x04 },
+{ "linux/stm.h", "STP_POLICY_ID_GET", _IOC_READ, 0x2501, 0x10 },
+{ "linux/stm.h", "STP_POLICY_ID_SET", _IOC_READ|_IOC_WRITE, 0x2500, 0x10 },
+{ "linux/stm.h", "STP_SET_OPTIONS", _IOC_WRITE, 0x2502, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ALLOC_SWAP_PAGE", _IOC_READ, 0x3314, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ATOMIC_RESTORE", _IOC_NONE, 0x3304, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_AVAIL_SWAP_SIZE", _IOC_READ, 0x3313, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_CREATE_IMAGE", _IOC_WRITE, 0x3311, 0x04 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE", _IOC_NONE, 0x3305, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREEZE", _IOC_NONE, 0x3301, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE_SWAP_PAGES", _IOC_NONE, 0x3309, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_GET_IMAGE_SIZE", _IOC_READ, 0x330e, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PLATFORM_SUPPORT", _IOC_NONE, 0x330f, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_POWER_OFF", _IOC_NONE, 0x3310, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PREF_IMAGE_SIZE", _IOC_NONE, 0x3312, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_S2RAM", _IOC_NONE, 0x330b, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_SET_SWAP_AREA", _IOC_WRITE, 0x330d, 0x0c },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_UNFREEZE", _IOC_NONE, 0x3302, 0x00 },
+{ "linux/sync_file.h", "SYNC_IOC_FILE_INFO", _IOC_READ|_IOC_WRITE, 0x3e04, 0x38 },
+{ "linux/sync_file.h", "SYNC_IOC_MERGE", _IOC_READ|_IOC_WRITE, 0x3e03, 0x30 },
+{ "linux/synclink.h", "MGSL_IOCCLRMODCOUNT", _IOC_NONE, 0x6d0f, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGGPIO", _IOC_READ, 0x6d11, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCGIF", _IOC_NONE, 0x6d0b, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGPARAMS", _IOC_READ, 0x6d01, 0x30 },
+{ "linux/synclink.h", "MGSL_IOCGSTATS", _IOC_NONE, 0x6d07, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGTXIDLE", _IOC_NONE, 0x6d03, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXCTRL", _IOC_NONE, 0x6d16, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXSYNC", _IOC_NONE, 0x6d14, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCLOOPTXDONE", _IOC_NONE, 0x6d09, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCRXENABLE", _IOC_NONE, 0x6d05, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSGPIO", _IOC_WRITE, 0x6d10, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCSIF", _IOC_NONE, 0x6d0a, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSPARAMS", _IOC_WRITE, 0x6d00, 0x30 },
+{ "linux/synclink.h", "MGSL_IOCSTXIDLE", _IOC_NONE, 0x6d02, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXCTRL", _IOC_NONE, 0x6d15, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXSYNC", _IOC_NONE, 0x6d13, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXABORT", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXENABLE", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCWAITEVENT", _IOC_READ|_IOC_WRITE, 0x6d08, 0x04 },
+{ "linux/synclink.h", "MGSL_IOCWAITGPIO", _IOC_READ|_IOC_WRITE, 0x6d12, 0x10 },
+{ "linux/telephony.h", "OLD_PHONE_RING_START", _IOC_NONE, 0x7187, 0x00 },
+{ "linux/telephony.h", "PHONE_BUSY", _IOC_NONE, 0x71a1, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES", _IOC_NONE, 0x7180, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_CHECK", _IOC_WRITE, 0x7182, 0x08 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_LIST", _IOC_READ, 0x7181, 0x08 },
+{ "linux/telephony.h", "PHONE_CPT_STOP", _IOC_NONE, 0x71a4, 0x00 },
+{ "linux/telephony.h", "PHONE_DIALTONE", _IOC_NONE, 0x71a3, 0x00 },
+{ "linux/telephony.h", "PHONE_DTMF_OOB", _IOC_WRITE, 0x7199, 0x04 },
+{ "linux/telephony.h", "PHONE_DTMF_READY", _IOC_READ, 0x7196, 0x04 },
+{ "linux/telephony.h", "PHONE_EXCEPTION", _IOC_READ, 0x719a, 0x04 },
+{ "linux/telephony.h", "PHONE_FRAME", _IOC_WRITE, 0x718d, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF", _IOC_READ, 0x7197, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF_ASCII", _IOC_READ, 0x7198, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_TONE_OFF_TIME", _IOC_NONE, 0x719f, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_ON_TIME", _IOC_NONE, 0x719e, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_STATE", _IOC_NONE, 0x71a0, 0x00 },
+{ "linux/telephony.h", "PHONE_HOOKSTATE", _IOC_NONE, 0x7184, 0x00 },
+{ "linux/telephony.h", "PHONE_MAXRINGS", _IOC_WRITE, 0x7185, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_CODEC", _IOC_WRITE, 0x7190, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_DEPTH", _IOC_WRITE, 0x7193, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_LEVEL", _IOC_NONE, 0x7195, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_START", _IOC_NONE, 0x7191, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_STOP", _IOC_NONE, 0x7192, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_TONE", _IOC_WRITE, 0x719b, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME", _IOC_WRITE, 0x7194, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME_LINEAR", _IOC_WRITE, 0x71dc, 0x04 },
+{ "linux/telephony.h", "PHONE_PSTN_GET_STATE", _IOC_NONE, 0x71a5, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_LINETEST", _IOC_NONE, 0x71a8, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_SET_STATE", _IOC_WRITE, 0x71a4, 0x04 },
+{ "linux/telephony.h", "PHONE_QUERY_CODEC", _IOC_READ|_IOC_WRITE, 0x71a7, 0x08 },
+{ "linux/telephony.h", "PHONE_REC_CODEC", _IOC_WRITE, 0x7189, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_DEPTH", _IOC_WRITE, 0x718c, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_LEVEL", _IOC_NONE, 0x718f, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_START", _IOC_NONE, 0x718a, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_STOP", _IOC_NONE, 0x718b, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME", _IOC_WRITE, 0x718e, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME_LINEAR", _IOC_WRITE, 0x71db, 0x04 },
+{ "linux/telephony.h", "PHONE_RING", _IOC_NONE, 0x7183, 0x00 },
+{ "linux/telephony.h", "PHONE_RINGBACK", _IOC_NONE, 0x71a2, 0x00 },
+{ "linux/telephony.h", "PHONE_RING_CADENCE", _IOC_WRITE, 0x7186, 0x02 },
+{ "linux/telephony.h", "PHONE_RING_START", _IOC_WRITE, 0x7187, 0x08 },
+{ "linux/telephony.h", "PHONE_RING_STOP", _IOC_NONE, 0x7188, 0x00 },
+{ "linux/telephony.h", "PHONE_SET_TONE_OFF_TIME", _IOC_WRITE, 0x719d, 0x04 },
+{ "linux/telephony.h", "PHONE_SET_TONE_ON_TIME", _IOC_WRITE, 0x719c, 0x04 },
+{ "linux/telephony.h", "PHONE_VAD", _IOC_WRITE, 0x71a9, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK", _IOC_WRITE, 0x71aa, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK_DURATION", _IOC_WRITE, 0x71a6, 0x04 },
+{ "linux/timerfd.h", "TFD_IOC_SET_TICKS", _IOC_WRITE, 0x5400, 0x08 },
+{ "linux/toshiba.h", "TOSHIBA_ACPI_SCI", _IOC_READ|_IOC_WRITE, 0x7491, 0x18 },
+{ "linux/toshiba.h", "TOSH_SMM", _IOC_READ|_IOC_WRITE, 0x7490, 0x18 },
+{ "linux/udf_fs_i.h", "UDF_GETEABLOCK", _IOC_READ, 0x6c41, 0x08 },
+{ "linux/udf_fs_i.h", "UDF_GETEASIZE", _IOC_READ, 0x6c40, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETVOLIDENT", _IOC_READ, 0x6c42, 0x08 },
+{ "linux/udf_fs_i.h", "UDF_RELOCATE_BLOCKS", _IOC_READ|_IOC_WRITE, 0x6c43, 0x08 },
+{ "linux/uinput.h", "UI_ABS_SETUP", _IOC_WRITE, 0x5504, 0x1c },
+{ "linux/uinput.h", "UI_BEGIN_FF_ERASE", _IOC_READ|_IOC_WRITE, 0x55ca, 0x0c },
+{ "linux/uinput.h", "UI_BEGIN_FF_UPLOAD", _IOC_READ|_IOC_WRITE, 0x55c8, 0x68 },
+{ "linux/uinput.h", "UI_DEV_CREATE", _IOC_NONE, 0x5501, 0x00 },
+{ "linux/uinput.h", "UI_DEV_DESTROY", _IOC_NONE, 0x5502, 0x00 },
+{ "linux/uinput.h", "UI_DEV_SETUP", _IOC_WRITE, 0x5503, 0x5c },
+{ "linux/uinput.h", "UI_END_FF_ERASE", _IOC_WRITE, 0x55cb, 0x0c },
+{ "linux/uinput.h", "UI_END_FF_UPLOAD", _IOC_WRITE, 0x55c9, 0x68 },
+{ "linux/uinput.h", "UI_GET_VERSION", _IOC_READ, 0x552d, 0x04 },
+{ "linux/uinput.h", "UI_SET_ABSBIT", _IOC_WRITE, 0x5567, 0x04 },
+{ "linux/uinput.h", "UI_SET_EVBIT", _IOC_WRITE, 0x5564, 0x04 },
+{ "linux/uinput.h", "UI_SET_FFBIT", _IOC_WRITE, 0x556b, 0x04 },
+{ "linux/uinput.h", "UI_SET_KEYBIT", _IOC_WRITE, 0x5565, 0x04 },
+{ "linux/uinput.h", "UI_SET_LEDBIT", _IOC_WRITE, 0x5569, 0x04 },
+{ "linux/uinput.h", "UI_SET_MSCBIT", _IOC_WRITE, 0x5568, 0x04 },
+{ "linux/uinput.h", "UI_SET_PHYS", _IOC_WRITE, 0x556c, 0x08 },
+{ "linux/uinput.h", "UI_SET_PROPBIT", _IOC_WRITE, 0x556e, 0x04 },
+{ "linux/uinput.h", "UI_SET_RELBIT", _IOC_WRITE, 0x5566, 0x04 },
+{ "linux/uinput.h", "UI_SET_SNDBIT", _IOC_WRITE, 0x556a, 0x04 },
+{ "linux/uinput.h", "UI_SET_SWBIT", _IOC_WRITE, 0x556d, 0x04 },
+{ "linux/usb/cdc-wdm.h", "IOCTL_WDM_MAX_COMMAND", _IOC_READ, 0x48a0, 0x02 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_DESC", _IOC_READ, 0x6782, 0x09 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_REVMAP", _IOC_NONE, 0x6781, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
+{ "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/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 },
+{ "linux/usb/iowarrior.h", "IOW_GETINFO", _IOC_READ, 0xc003, 0x28 },
+{ "linux/usb/iowarrior.h", "IOW_READ", _IOC_WRITE, 0xc002, 0x08 },
+{ "linux/usb/iowarrior.h", "IOW_WRITE", _IOC_WRITE, 0xc001, 0x08 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GET_CAPS", _IOC_READ, 0x5b11, 0x01 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GOTO_LOCAL", _IOC_NONE, 0x5b14, 0x00 },
+{ "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", "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_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
+{ "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 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIMINTERFACE", _IOC_READ, 0x550f, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIM_PORT", _IOC_READ, 0x5518, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLEAR_HALT", _IOC_READ, 0x5515, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECT", _IOC_NONE, 0x5517, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECTINFO", _IOC_WRITE, 0x5511, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL", _IOC_READ|_IOC_WRITE, 0x5500, 0x18 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL32", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCARDURB", _IOC_NONE, 0x550b, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT", _IOC_NONE, 0x5516, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT_CLAIM", _IOC_READ, 0x551b, 0x108 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL", _IOC_READ, 0x550e, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL32", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DROP_PRIVILEGES", _IOC_WRITE, 0x551e, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_FREE_STREAMS", _IOC_READ, 0x551d, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GETDRIVER", _IOC_WRITE, 0x5508, 0x104 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GET_CAPABILITIES", _IOC_READ, 0x551a, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_HUB_PORTINFO", _IOC_READ, 0x5513, 0x80 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL", _IOC_READ|_IOC_WRITE, 0x5512, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL32", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB", _IOC_WRITE, 0x550c, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB32", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY", _IOC_WRITE, 0x550d, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY32", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASEINTERFACE", _IOC_READ, 0x5510, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASE_PORT", _IOC_READ, 0x5519, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESET", _IOC_NONE, 0x5514, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESETEP", _IOC_READ, 0x5503, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETCONFIGURATION", _IOC_READ, 0x5505, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETINTERFACE", _IOC_READ, 0x5504, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB", _IOC_READ, 0x550a, 0x38 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB32", _IOC_READ, 0x550a, 0x2a },
+{ "linux/userfaultfd.h", "UFFDIO_API", _IOC_READ|_IOC_WRITE, 0xaa3f, 0x18 },
+{ "linux/userfaultfd.h", "UFFDIO_COPY", _IOC_READ|_IOC_WRITE, 0xaa03, 0x28 },
+{ "linux/userfaultfd.h", "UFFDIO_REGISTER", _IOC_READ|_IOC_WRITE, 0xaa00, 0x20 },
+{ "linux/userfaultfd.h", "UFFDIO_UNREGISTER", _IOC_READ, 0xaa01, 0x10 },
+{ "linux/userfaultfd.h", "UFFDIO_WAKE", _IOC_READ, 0xaa02, 0x10 },
+{ "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 },
+{ "linux/vfio.h", "VFIO_CHECK_EXTENSION", _IOC_NONE, 0x3b65, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_INFO", _IOC_NONE, 0x3b6b, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_IRQ_INFO", _IOC_NONE, 0x3b6d, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_REGION_INFO", _IOC_NONE, 0x3b6c, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_PCI_HOT_RESET", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_RESET", _IOC_NONE, 0x3b6f, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_SET_IRQS", _IOC_NONE, 0x3b6e, 0x00 },
+{ "linux/vfio.h", "VFIO_EEH_PE_OP", _IOC_NONE, 0x3b79, 0x00 },
+{ "linux/vfio.h", "VFIO_GET_API_VERSION", _IOC_NONE, 0x3b64, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_DEVICE_FD", _IOC_NONE, 0x3b6a, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_STATUS", _IOC_NONE, 0x3b67, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_SET_CONTAINER", _IOC_NONE, 0x3b68, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_UNSET_CONTAINER", _IOC_NONE, 0x3b69, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_DISABLE", _IOC_NONE, 0x3b74, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_ENABLE", _IOC_NONE, 0x3b73, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_MAP_DMA", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", _IOC_NONE, 0x3b75, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_CREATE", _IOC_NONE, 0x3b77, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_REMOVE", _IOC_NONE, 0x3b78, 0x00 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_GET_VRING_ENDIAN", _IOC_WRITE, 0xaf14, 0x08 },
+{ "linux/vhost.h", "VHOST_NET_SET_BACKEND", _IOC_WRITE, 0xaf30, 0x08 },
+{ "linux/vhost.h", "VHOST_RESET_OWNER", _IOC_NONE, 0xaf02, 0x00 },
+{ "linux/vhost.h", "VHOST_SCSI_CLEAR_ENDPOINT", _IOC_WRITE, 0xaf41, 0xe8 },
+{ "linux/vhost.h", "VHOST_SCSI_GET_ABI_VERSION", _IOC_WRITE, 0xaf42, 0x04 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_SET_MEM_TABLE", _IOC_WRITE, 0xaf03, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_OWNER", _IOC_NONE, 0xaf01, 0x00 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ADDR", _IOC_WRITE, 0xaf11, 0x28 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BASE", _IOC_WRITE, 0xaf12, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf23, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_CALL", _IOC_WRITE, 0xaf21, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ENDIAN", _IOC_WRITE, 0xaf13, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ERR", _IOC_WRITE, 0xaf22, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_KICK", _IOC_WRITE, 0xaf20, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_NUM", _IOC_WRITE, 0xaf10, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_CREATE_BUFS", _IOC_READ|_IOC_WRITE, 0x565c, 0x100 },
+{ "linux/videodev2.h", "VIDIOC_CROPCAP", _IOC_READ|_IOC_WRITE, 0x563a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_CHIP_INFO", _IOC_READ|_IOC_WRITE, 0x5666, 0xc8 },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_REGISTER", _IOC_READ|_IOC_WRITE, 0x5650, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DBG_S_REGISTER", _IOC_WRITE, 0x564f, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5660, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_DQBUF", _IOC_READ|_IOC_WRITE, 0x5611, 0x58 },
+{ "linux/videodev2.h", "VIDIOC_DQEVENT", _IOC_READ, 0x5659, 0x88 },
+{ "linux/videodev2.h", "VIDIOC_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
+{ "linux/videodev2.h", "VIDIOC_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564d, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDIO", _IOC_READ|_IOC_WRITE, 0x5641, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDOUT", _IOC_READ|_IOC_WRITE, 0x5642, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMINPUT", _IOC_READ|_IOC_WRITE, 0x561a, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_ENUMOUTPUT", _IOC_READ|_IOC_WRITE, 0x5630, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUMSTD", _IOC_READ|_IOC_WRITE, 0x5619, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FMT", _IOC_READ|_IOC_WRITE, 0x5602, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMEINTERVALS", _IOC_READ|_IOC_WRITE, 0x564b, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMESIZES", _IOC_READ|_IOC_WRITE, 0x564a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FREQ_BANDS", _IOC_READ|_IOC_WRITE, 0x5665, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_EXPBUF", _IOC_READ|_IOC_WRITE, 0x5610, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDIO", _IOC_READ, 0x5621, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDOUT", _IOC_READ, 0x5631, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_G_CTRL", _IOC_READ|_IOC_WRITE, 0x561b, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_G_ENC_INDEX", _IOC_READ, 0x564c, 0x818 },
+{ "linux/videodev2.h", "VIDIOC_G_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5647, 0x20 },
+{ "linux/videodev2.h", "VIDIOC_G_FBUF", _IOC_READ, 0x560a, 0x30 },
+{ "linux/videodev2.h", "VIDIOC_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0xd0 },
+{ "linux/videodev2.h", "VIDIOC_G_FREQUENCY", _IOC_READ|_IOC_WRITE, 0x5638, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_INPUT", _IOC_READ, 0x5626, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_JPEGCOMP", _IOC_READ, 0x563d, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_G_MODULATOR", _IOC_READ|_IOC_WRITE, 0x5636, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_G_OUTPUT", _IOC_READ, 0x562e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_PARM", _IOC_READ|_IOC_WRITE, 0x5615, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_PRIORITY", _IOC_READ, 0x5643, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x565e, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_SLICED_VBI_CAP", _IOC_READ|_IOC_WRITE, 0x5645, 0x74 },
+{ "linux/videodev2.h", "VIDIOC_G_STD", _IOC_READ, 0x5617, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_TUNER", _IOC_READ|_IOC_WRITE, 0x561d, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_LOG_STATUS", _IOC_NONE, 0x5646, 0x00 },
+{ "linux/videodev2.h", "VIDIOC_OVERLAY", _IOC_WRITE, 0x560e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_PREPARE_BUF", _IOC_READ|_IOC_WRITE, 0x565d, 0x58 },
+{ "linux/videodev2.h", "VIDIOC_QBUF", _IOC_READ|_IOC_WRITE, 0x560f, 0x58 },
+{ "linux/videodev2.h", "VIDIOC_QUERYBUF", _IOC_READ|_IOC_WRITE, 0x5609, 0x58 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCAP", _IOC_READ, 0x5600, 0x68 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCTRL", _IOC_READ|_IOC_WRITE, 0x5624, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYMENU", _IOC_READ|_IOC_WRITE, 0x5625, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_QUERYSTD", _IOC_READ, 0x563f, 0x08 },
+{ "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 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDIO", _IOC_WRITE, 0x5622, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDOUT", _IOC_WRITE, 0x5632, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_CROP", _IOC_WRITE, 0x563c, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_S_CTRL", _IOC_READ|_IOC_WRITE, 0x561c, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_S_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5648, 0x20 },
+{ "linux/videodev2.h", "VIDIOC_S_FBUF", _IOC_WRITE, 0x560b, 0x30 },
+{ "linux/videodev2.h", "VIDIOC_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0xd0 },
+{ "linux/videodev2.h", "VIDIOC_S_FREQUENCY", _IOC_WRITE, 0x5639, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_HW_FREQ_SEEK", _IOC_WRITE, 0x5652, 0x30 },
+{ "linux/videodev2.h", "VIDIOC_S_INPUT", _IOC_READ|_IOC_WRITE, 0x5627, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_JPEGCOMP", _IOC_WRITE, 0x563e, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_S_MODULATOR", _IOC_WRITE, 0x5637, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_S_OUTPUT", _IOC_READ|_IOC_WRITE, 0x562f, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_PARM", _IOC_READ|_IOC_WRITE, 0x5616, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_PRIORITY", _IOC_WRITE, 0x5644, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x565f, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_S_STD", _IOC_WRITE, 0x5618, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_TUNER", _IOC_WRITE, 0x561e, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_TRY_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5661, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_TRY_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564e, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_TRY_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5649, 0x20 },
+{ "linux/videodev2.h", "VIDIOC_TRY_FMT", _IOC_READ|_IOC_WRITE, 0x5640, 0xd0 },
+{ "linux/videodev2.h", "VIDIOC_UNSUBSCRIBE_EVENT", _IOC_WRITE, 0x565b, 0x20 },
+{ "linux/vm_sockets.h", "IOCTL_VM_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_ADD_NOTIFICATION", _IOC_NONE, 0x07af, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_GET_CPT_STATE", _IOC_NONE, 0x07b1, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", _IOC_NONE, 0x07b0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_SET_CPT_STATE", _IOC_NONE, 0x07b2, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_RECEIVE", _IOC_NONE, 0x07ac, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_SEND", _IOC_NONE, 0x07ab, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_GET_CONTEXT_ID", _IOC_NONE, 0x07b3, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_INIT_CONTEXT", _IOC_NONE, 0x07a0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", _IOC_NONE, 0x07a6, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFY_RESOURCE", _IOC_NONE, 0x07a5, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_ALLOC", _IOC_NONE, 0x07a8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_DETACH", _IOC_NONE, 0x07aa, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", _IOC_NONE, 0x07a9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETVA", _IOC_NONE, 0x07a4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SET_NOTIFY", _IOC_NONE, 0x07cb, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", _IOC_NONE, 0x07b8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_VERSION", _IOC_NONE, 0x07b4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION", _IOC_NONE, 0x079f, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION2", _IOC_NONE, 0x07a7, 0x00 },
+{ "linux/vsp1.h", "VIDIOC_VSP1_LUT_CONFIG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x400 },
+{ "linux/vt.h", "VT_ACTIVATE", 0, 0x5606, 0 },
+{ "linux/vt.h", "VT_DISALLOCATE", 0, 0x5608, 0 },
+{ "linux/vt.h", "VT_GETHIFONTMASK", 0, 0x560D, 0 },
+{ "linux/vt.h", "VT_GETMODE", 0, 0x5601, 0 },
+{ "linux/vt.h", "VT_GETSTATE", 0, 0x5603, 0 },
+{ "linux/vt.h", "VT_LOCKSWITCH", 0, 0x560B, 0 },
+{ "linux/vt.h", "VT_OPENQRY", 0, 0x5600, 0 },
+{ "linux/vt.h", "VT_RELDISP", 0, 0x5605, 0 },
+{ "linux/vt.h", "VT_RESIZE", 0, 0x5609, 0 },
+{ "linux/vt.h", "VT_RESIZEX", 0, 0x560A, 0 },
+{ "linux/vt.h", "VT_SENDSIG", 0, 0x5604, 0 },
+{ "linux/vt.h", "VT_SETACTIVATE", 0, 0x560F, 0 },
+{ "linux/vt.h", "VT_SETMODE", 0, 0x5602, 0 },
+{ "linux/vt.h", "VT_UNLOCKSWITCH", 0, 0x560C, 0 },
+{ "linux/vt.h", "VT_WAITACTIVE", 0, 0x5607, 0 },
+{ "linux/vt.h", "VT_WAITEVENT", 0, 0x560E, 0 },
+{ "linux/watchdog.h", "WDIOC_GETBOOTSTATUS", _IOC_READ, 0x5702, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETPRETIMEOUT", _IOC_READ, 0x5709, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSTATUS", _IOC_READ, 0x5701, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSUPPORT", _IOC_READ, 0x5700, 0x28 },
+{ "linux/watchdog.h", "WDIOC_GETTEMP", _IOC_READ, 0x5703, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMELEFT", _IOC_READ, 0x570a, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMEOUT", _IOC_READ, 0x5707, 0x04 },
+{ "linux/watchdog.h", "WDIOC_KEEPALIVE", _IOC_READ, 0x5705, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETOPTIONS", _IOC_READ, 0x5704, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETPRETIMEOUT", _IOC_READ|_IOC_WRITE, 0x5708, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x5706, 0x04 },
+{ "linux/wireless.h", "SIOCGIWAP", 0, 0x8B15, 0 },
+{ "linux/wireless.h", "SIOCGIWAPLIST", 0, 0x8B17, 0 },
+{ "linux/wireless.h", "SIOCGIWAUTH", 0, 0x8B33, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODE", 0, 0x8B2B, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODEEXT", 0, 0x8B35, 0 },
+{ "linux/wireless.h", "SIOCGIWESSID", 0, 0x8B1B, 0 },
+{ "linux/wireless.h", "SIOCGIWFRAG", 0, 0x8B25, 0 },
+{ "linux/wireless.h", "SIOCGIWFREQ", 0, 0x8B05, 0 },
+{ "linux/wireless.h", "SIOCGIWGENIE", 0, 0x8B31, 0 },
+{ "linux/wireless.h", "SIOCGIWMODE", 0, 0x8B07, 0 },
+{ "linux/wireless.h", "SIOCGIWNAME", 0, 0x8B01, 0 },
+{ "linux/wireless.h", "SIOCGIWNICKN", 0, 0x8B1D, 0 },
+{ "linux/wireless.h", "SIOCGIWNWID", 0, 0x8B03, 0 },
+{ "linux/wireless.h", "SIOCGIWPOWER", 0, 0x8B2D, 0 },
+{ "linux/wireless.h", "SIOCGIWPRIV", 0, 0x8B0D, 0 },
+{ "linux/wireless.h", "SIOCGIWRANGE", 0, 0x8B0B, 0 },
+{ "linux/wireless.h", "SIOCGIWRATE", 0, 0x8B21, 0 },
+{ "linux/wireless.h", "SIOCGIWRETRY", 0, 0x8B29, 0 },
+{ "linux/wireless.h", "SIOCGIWRTS", 0, 0x8B23, 0 },
+{ "linux/wireless.h", "SIOCGIWSCAN", 0, 0x8B19, 0 },
+{ "linux/wireless.h", "SIOCGIWSENS", 0, 0x8B09, 0 },
+{ "linux/wireless.h", "SIOCGIWSPY", 0, 0x8B11, 0 },
+{ "linux/wireless.h", "SIOCGIWSTATS", 0, 0x8B0F, 0 },
+{ "linux/wireless.h", "SIOCGIWTHRSPY", 0, 0x8B13, 0 },
+{ "linux/wireless.h", "SIOCGIWTXPOW", 0, 0x8B27, 0 },
+{ "linux/wireless.h", "SIOCIWFIRST", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCIWFIRSTPRIV", 0, 0x8BE0, 0 },
+{ "linux/wireless.h", "SIOCIWLASTPRIV", 0, 0x8BFF, 0 },
+{ "linux/wireless.h", "SIOCSIWAP", 0, 0x8B14, 0 },
+{ "linux/wireless.h", "SIOCSIWAUTH", 0, 0x8B32, 0 },
+{ "linux/wireless.h", "SIOCSIWCOMMIT", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODE", 0, 0x8B2A, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODEEXT", 0, 0x8B34, 0 },
+{ "linux/wireless.h", "SIOCSIWESSID", 0, 0x8B1A, 0 },
+{ "linux/wireless.h", "SIOCSIWFRAG", 0, 0x8B24, 0 },
+{ "linux/wireless.h", "SIOCSIWFREQ", 0, 0x8B04, 0 },
+{ "linux/wireless.h", "SIOCSIWGENIE", 0, 0x8B30, 0 },
+{ "linux/wireless.h", "SIOCSIWMLME", 0, 0x8B16, 0 },
+{ "linux/wireless.h", "SIOCSIWMODE", 0, 0x8B06, 0 },
+{ "linux/wireless.h", "SIOCSIWNICKN", 0, 0x8B1C, 0 },
+{ "linux/wireless.h", "SIOCSIWNWID", 0, 0x8B02, 0 },
+{ "linux/wireless.h", "SIOCSIWPMKSA", 0, 0x8B36, 0 },
+{ "linux/wireless.h", "SIOCSIWPOWER", 0, 0x8B2C, 0 },
+{ "linux/wireless.h", "SIOCSIWPRIV", 0, 0x8B0C, 0 },
+{ "linux/wireless.h", "SIOCSIWRANGE", 0, 0x8B0A, 0 },
+{ "linux/wireless.h", "SIOCSIWRATE", 0, 0x8B20, 0 },
+{ "linux/wireless.h", "SIOCSIWRETRY", 0, 0x8B28, 0 },
+{ "linux/wireless.h", "SIOCSIWRTS", 0, 0x8B22, 0 },
+{ "linux/wireless.h", "SIOCSIWSCAN", 0, 0x8B18, 0 },
+{ "linux/wireless.h", "SIOCSIWSENS", 0, 0x8B08, 0 },
+{ "linux/wireless.h", "SIOCSIWSPY", 0, 0x8B10, 0 },
+{ "linux/wireless.h", "SIOCSIWSTATS", 0, 0x8B0E, 0 },
+{ "linux/wireless.h", "SIOCSIWTHRSPY", 0, 0x8B12, 0 },
+{ "linux/wireless.h", "SIOCSIWTXPOW", 0, 0x8B26, 0 },
+{ "media/davinci/vpfe_capture.h", "VPFE_CMD_S_CCDC_RAW_PARAMS", _IOC_WRITE, 0x56c1, 0x08 },
+{ "media/drv-intf/exynos-fimc.h", "S5P_FIMC_TX_END_NOTIFY", _IOC_NONE, 0x6500, 0x00 },
+{ "media/i2c/adv7842.h", "ADV7842_CMD_RAM_TEST", _IOC_NONE, 0x56c0, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_HIGH", _IOC_NONE, 0x6201, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_LOW", _IOC_NONE, 0x6200, 0x00 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_CLOSE", _IOC_WRITE, 0x5202, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_POLL", _IOC_READ, 0x5204, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_READ", _IOC_READ, 0x5203, 0x04 },
+{ "media/v4l2-common.h", "TUNER_SET_CONFIG", _IOC_WRITE, 0x645c, 0x10 },
+{ "media/v4l2-common.h", "VIDIOC_INT_RESET", _IOC_WRITE, 0x6466, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_DEVICE_NOTIFY_EVENT", _IOC_WRITE, 0x7602, 0x88 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_RX_NOTIFY", _IOC_WRITE, 0x7600, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_TX_NOTIFY", _IOC_WRITE, 0x7601, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_DOWNLOAD_IMAGE", _IOC_WRITE, 0xca0a, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_AFU_ID", _IOC_READ, 0xca02, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_PROCESS_ELEMENT", _IOC_READ, 0xca01, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_START_WORK", _IOC_WRITE, 0xca00, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_VALIDATE_IMAGE", _IOC_WRITE, 0xca0b, 0x40 },
+{ "mtd/mtd-abi.h", "ECCGETLAYOUT", _IOC_READ, 0x4d11, 0x148 },
+{ "mtd/mtd-abi.h", "ECCGETSTATS", _IOC_READ, 0x4d12, 0x10 },
+{ "mtd/mtd-abi.h", "MEMERASE", _IOC_WRITE, 0x4d02, 0x08 },
+{ "mtd/mtd-abi.h", "MEMERASE64", _IOC_WRITE, 0x4d14, 0x10 },
+{ "mtd/mtd-abi.h", "MEMGETBADBLOCK", _IOC_WRITE, 0x4d0b, 0x08 },
+{ "mtd/mtd-abi.h", "MEMGETINFO", _IOC_READ, 0x4d01, 0x20 },
+{ "mtd/mtd-abi.h", "MEMGETOOBSEL", _IOC_READ, 0x4d0a, 0xc8 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONCOUNT", _IOC_READ, 0x4d07, 0x04 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONINFO", _IOC_READ|_IOC_WRITE, 0x4d08, 0x10 },
+{ "mtd/mtd-abi.h", "MEMISLOCKED", _IOC_READ, 0x4d17, 0x08 },
+{ "mtd/mtd-abi.h", "MEMLOCK", _IOC_WRITE, 0x4d05, 0x08 },
+{ "mtd/mtd-abi.h", "MEMREADOOB", _IOC_READ|_IOC_WRITE, 0x4d04, 0x10 },
+{ "mtd/mtd-abi.h", "MEMREADOOB64", _IOC_READ|_IOC_WRITE, 0x4d16, 0x18 },
+{ "mtd/mtd-abi.h", "MEMSETBADBLOCK", _IOC_WRITE, 0x4d0c, 0x08 },
+{ "mtd/mtd-abi.h", "MEMUNLOCK", _IOC_WRITE, 0x4d06, 0x08 },
+{ "mtd/mtd-abi.h", "MEMWRITE", _IOC_READ|_IOC_WRITE, 0x4d18, 0x30 },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB", _IOC_READ|_IOC_WRITE, 0x4d03, 0x10 },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB64", _IOC_READ|_IOC_WRITE, 0x4d15, 0x18 },
+{ "mtd/mtd-abi.h", "MTDFILEMODE", _IOC_NONE, 0x4d13, 0x00 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONCOUNT", _IOC_WRITE, 0x4d0e, 0x04 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONINFO", _IOC_WRITE, 0x4d0f, 0x0c },
+{ "mtd/mtd-abi.h", "OTPLOCK", _IOC_READ, 0x4d10, 0x0c },
+{ "mtd/mtd-abi.h", "OTPSELECT", _IOC_READ, 0x4d0d, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCATT", _IOC_WRITE, 0x6f40, 0x18 },
+{ "mtd/ubi-user.h", "UBI_IOCDET", _IOC_WRITE, 0x6f41, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBCH", _IOC_WRITE, 0x4f02, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBER", _IOC_WRITE, 0x4f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBISMAP", _IOC_READ, 0x4f05, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBMAP", _IOC_WRITE, 0x4f03, 0x08 },
+{ "mtd/ubi-user.h", "UBI_IOCEBUNMAP", _IOC_WRITE, 0x4f04, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCMKVOL", _IOC_WRITE, 0x6f00, 0x98 },
+{ "mtd/ubi-user.h", "UBI_IOCRMVOL", _IOC_WRITE, 0x6f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCRNVOL", _IOC_WRITE, 0x6f03, 0x1110 },
+{ "mtd/ubi-user.h", "UBI_IOCRSVOL", _IOC_WRITE, 0x6f02, 0x0c },
+{ "mtd/ubi-user.h", "UBI_IOCSETVOLPROP", _IOC_WRITE, 0x4f06, 0x10 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLCRBLK", _IOC_WRITE, 0x4f07, 0x80 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLRMBLK", _IOC_NONE, 0x4f08, 0x00 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLUP", _IOC_WRITE, 0x4f00, 0x08 },
+{ "net/bluetooth/hci_sock.h", "HCIBLOCKADDR", _IOC_WRITE, 0x48e6, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVDOWN", _IOC_WRITE, 0x48ca, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESET", _IOC_WRITE, 0x48cb, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESTAT", _IOC_WRITE, 0x48cc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVUP", _IOC_WRITE, 0x48c9, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETAUTHINFO", _IOC_READ, 0x48d7, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNINFO", _IOC_READ, 0x48d5, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNLIST", _IOC_READ, 0x48d4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVINFO", _IOC_READ, 0x48d3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVLIST", _IOC_READ, 0x48d2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIINQUIRY", _IOC_READ, 0x48f0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETACLMTU", _IOC_WRITE, 0x48e3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETAUTH", _IOC_WRITE, 0x48de, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETENCRYPT", _IOC_WRITE, 0x48df, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKMODE", _IOC_WRITE, 0x48e2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKPOL", _IOC_WRITE, 0x48e1, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETPTYPE", _IOC_WRITE, 0x48e0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETRAW", _IOC_WRITE, 0x48dc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCAN", _IOC_WRITE, 0x48dd, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCOMTU", _IOC_WRITE, 0x48e4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIUNBLOCKADDR", _IOC_WRITE, 0x48e7, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMCREATEDEV", _IOC_WRITE, 0x52c8, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVINFO", _IOC_READ, 0x52d3, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVLIST", _IOC_READ, 0x52d2, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMRELEASEDEV", _IOC_WRITE, 0x52c9, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMSTEALDLC", _IOC_WRITE, 0x52dc, 0x04 },
+{ "net/nfc/nci_core.h", "NCIUARTSETDRIVER", _IOC_WRITE, 0x5500, 0x08 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ACK_EVENT", _IOC_WRITE, 0x1bea, 0x08 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ASSIGN_CTXT", _IOC_READ|_IOC_WRITE, 0x1be1, 0x1c },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CREDIT_UPD", _IOC_NONE, 0x1be6, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_INFO", _IOC_WRITE, 0x1be2, 0x28 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_RESET", _IOC_NONE, 0x1bec, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_GET_VERS", _IOC_READ, 0x1bee, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_POLL_TYPE", _IOC_WRITE, 0x1be9, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_RECV_CTRL", _IOC_WRITE, 0x1be8, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_SET_PKEY", _IOC_WRITE, 0x1beb, 0x02 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_FREE", _IOC_READ|_IOC_WRITE, 0x1be5, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_INVAL_READ", _IOC_READ|_IOC_WRITE, 0x1bed, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_UPDATE", _IOC_READ|_IOC_WRITE, 0x1be4, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_USER_INFO", _IOC_WRITE, 0x1be3, 0x78 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_ENABLE_PKEY", _IOC_NONE, 0x1b03, 0x00 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT", _IOC_READ|_IOC_WRITE, 0x1b01, 0x1c },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT2", _IOC_READ|_IOC_WRITE, 0x1b04, 0x28 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_UNREGISTER_AGENT", _IOC_WRITE, 0x1b02, 0x04 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_ATTACH", _IOC_READ|_IOC_WRITE, 0xca80, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_DETACH", _IOC_READ|_IOC_WRITE, 0xca83, 0x60 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_MANAGE_LUN", _IOC_READ|_IOC_WRITE, 0xca86, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RECOVER_AFU", _IOC_READ|_IOC_WRITE, 0xca85, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RELEASE", _IOC_READ|_IOC_WRITE, 0xca82, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_DIRECT", _IOC_READ|_IOC_WRITE, 0xca81, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_VIRTUAL", _IOC_READ|_IOC_WRITE, 0xca87, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VERIFY", _IOC_READ|_IOC_WRITE, 0xca84, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_CLONE", _IOC_READ|_IOC_WRITE, 0xca89, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_RESIZE", _IOC_READ|_IOC_WRITE, 0xca88, 0x78 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_BUS_NUMBER", 0, 0x5386, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_IDLUN", 0, 0x5382, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_PCI", 0, 0x5387, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_PROBE_HOST", 0, 0x5385, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORLOCK", 0, 0x5380, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORUNLOCK", 0, 0x5381, 0 },
+{ "scsi/sg.h", "SG_EMULATED_HOST", 0, 0x2203, 0 },
+{ "scsi/sg.h", "SG_GET_ACCESS_COUNT", 0, 0x2289, 0 },
+{ "scsi/sg.h", "SG_GET_COMMAND_Q", 0, 0x2270, 0 },
+{ "scsi/sg.h", "SG_GET_KEEP_ORPHAN", 0, 0x2288, 0 },
+{ "scsi/sg.h", "SG_GET_LOW_DMA", 0, 0x227a, 0 },
+{ "scsi/sg.h", "SG_GET_NUM_WAITING", 0, 0x227d, 0 },
+{ "scsi/sg.h", "SG_GET_PACK_ID", 0, 0x227c, 0 },
+{ "scsi/sg.h", "SG_GET_REQUEST_TABLE", 0, 0x2286, 0 },
+{ "scsi/sg.h", "SG_GET_RESERVED_SIZE", 0, 0x2272, 0 },
+{ "scsi/sg.h", "SG_GET_SCSI_ID", 0, 0x2276, 0 },
+{ "scsi/sg.h", "SG_GET_SG_TABLESIZE", 0, 0x227F, 0 },
+{ "scsi/sg.h", "SG_GET_TIMEOUT", 0, 0x2202, 0 },
+{ "scsi/sg.h", "SG_GET_TRANSFORM", 0, 0x2205, 0 },
+{ "scsi/sg.h", "SG_GET_VERSION_NUM", 0, 0x2282, 0 },
+{ "scsi/sg.h", "SG_IO", 0, 0x2285, 0 },
+{ "scsi/sg.h", "SG_NEXT_CMD_LEN", 0, 0x2283, 0 },
+{ "scsi/sg.h", "SG_SCSI_RESET", 0, 0x2284, 0 },
+{ "scsi/sg.h", "SG_SET_COMMAND_Q", 0, 0x2271, 0 },
+{ "scsi/sg.h", "SG_SET_DEBUG", 0, 0x227e, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_LOW_DMA", 0, 0x2279, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_PACK_ID", 0, 0x227b, 0 },
+{ "scsi/sg.h", "SG_SET_KEEP_ORPHAN", 0, 0x2287, 0 },
+{ "scsi/sg.h", "SG_SET_RESERVED_SIZE", 0, 0x2275, 0 },
+{ "scsi/sg.h", "SG_SET_TIMEOUT", 0, 0x2201, 0 },
+{ "scsi/sg.h", "SG_SET_TRANSFORM", 0, 0x2204, 0 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CLIENT_ID", _IOC_READ, 0x5301, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_PORT", _IOC_READ|_IOC_WRITE, 0x5320, 0xa8 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x5332, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_PORT", _IOC_WRITE, 0x5321, 0xa8 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_QUEUE", _IOC_WRITE, 0x5333, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", _IOC_READ|_IOC_WRITE, 0x5310, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", _IOC_READ|_IOC_WRITE, 0x534b, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", _IOC_READ|_IOC_WRITE, 0x5336, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_PORT_INFO", _IOC_READ|_IOC_WRITE, 0x5322, 0xa8 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", _IOC_READ|_IOC_WRITE, 0x5349, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5334, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", _IOC_READ|_IOC_WRITE, 0x5340, 0x5c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", _IOC_READ|_IOC_WRITE, 0x5341, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", _IOC_READ|_IOC_WRITE, 0x5345, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", _IOC_READ|_IOC_WRITE, 0x5350, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_PVERSION", _IOC_READ, 0x5300, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", _IOC_READ|_IOC_WRITE, 0x5351, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", _IOC_READ|_IOC_WRITE, 0x5352, 0xa8 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_SUBS", _IOC_READ|_IOC_WRITE, 0x534f, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", _IOC_WRITE, 0x534e, 0x40 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_RUNNING_MODE", _IOC_READ|_IOC_WRITE, 0x5303, 0x10 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", _IOC_WRITE, 0x5311, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", _IOC_WRITE, 0x534c, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_PORT_INFO", _IOC_WRITE, 0x5323, 0xa8 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", _IOC_WRITE, 0x534a, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5335, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", _IOC_WRITE, 0x5342, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", _IOC_WRITE, 0x5346, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", _IOC_WRITE, 0x5330, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SYSTEM_INFO", _IOC_READ|_IOC_WRITE, 0x5302, 0x30 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", _IOC_WRITE, 0x5331, 0x50 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_CARD_INFO", _IOC_READ, 0x5501, 0x178 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_ADD", _IOC_READ|_IOC_WRITE, 0x5517, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_INFO", _IOC_READ|_IOC_WRITE, 0x5511, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LIST", _IOC_READ|_IOC_WRITE, 0x5510, 0x50 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LOCK", _IOC_WRITE, 0x5514, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_READ", _IOC_READ|_IOC_WRITE, 0x5512, 0x4c8 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REMOVE", _IOC_READ|_IOC_WRITE, 0x5519, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REPLACE", _IOC_READ|_IOC_WRITE, 0x5518, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_UNLOCK", _IOC_WRITE, 0x5515, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_WRITE", _IOC_READ|_IOC_WRITE, 0x5513, 0x4c8 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_INFO", _IOC_READ, 0x5521, 0xdc },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5520, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_INFO", _IOC_READ|_IOC_WRITE, 0x5531, 0x120 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", _IOC_READ, 0x5530, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", _IOC_WRITE, 0x5532, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER", _IOC_READ|_IOC_WRITE, 0x55d0, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER_STATE", _IOC_READ, 0x55d1, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PVERSION", _IOC_READ, 0x5500, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_INFO", _IOC_READ|_IOC_WRITE, 0x5541, 0x10c },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5540, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", _IOC_WRITE, 0x5542, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", _IOC_READ|_IOC_WRITE, 0x5516, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_COMMAND", _IOC_READ|_IOC_WRITE, 0x551c, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_READ", _IOC_READ|_IOC_WRITE, 0x551a, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_WRITE", _IOC_READ|_IOC_WRITE, 0x551b, 0x08 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_LOAD", _IOC_WRITE, 0x4803, 0x60 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_STATUS", _IOC_READ, 0x4802, 0x40 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_INFO", _IOC_READ, 0x4801, 0xdc },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_PVERSION", _IOC_READ, 0x4800, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_CHANNEL_INFO", _IOC_READ, 0x4132, 0x18 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DELAY", _IOC_READ, 0x4121, 0x08 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DRAIN", _IOC_NONE, 0x4144, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DROP", _IOC_NONE, 0x4143, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_FORWARD", _IOC_WRITE, 0x4149, 0x08 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HWSYNC", _IOC_NONE, 0x4122, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_FREE", _IOC_NONE, 0x4112, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4111, 0x260 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_REFINE", _IOC_READ|_IOC_WRITE, 0x4110, 0x260 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_INFO", _IOC_READ, 0x4101, 0x120 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_LINK", _IOC_WRITE, 0x4160, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PAUSE", _IOC_WRITE, 0x4145, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PREPARE", _IOC_NONE, 0x4140, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PVERSION", _IOC_READ, 0x4100, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READI_FRAMES", _IOC_READ, 0x4151, 0x18 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READN_FRAMES", _IOC_READ, 0x4153, 0x18 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESET", _IOC_NONE, 0x4141, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESUME", _IOC_NONE, 0x4147, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_REWIND", _IOC_WRITE, 0x4146, 0x08 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_START", _IOC_NONE, 0x4142, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS", _IOC_READ, 0x4120, 0x98 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS_EXT", _IOC_READ|_IOC_WRITE, 0x4124, 0x98 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4113, 0x88 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SYNC_PTR", _IOC_READ|_IOC_WRITE, 0x4123, 0x88 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TSTAMP", _IOC_WRITE, 0x4102, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TTSTAMP", _IOC_WRITE, 0x4103, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_UNLINK", _IOC_NONE, 0x4161, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEI_FRAMES", _IOC_WRITE, 0x4150, 0x18 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEN_FRAMES", _IOC_WRITE, 0x4152, 0x18 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_XRUN", _IOC_NONE, 0x4148, 0x00 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DRAIN", _IOC_WRITE, 0x5731, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DROP", _IOC_WRITE, 0x5730, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_INFO", _IOC_READ, 0x5701, 0x10c },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PARAMS", _IOC_READ|_IOC_WRITE, 0x5710, 0x30 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PVERSION", _IOC_READ, 0x5700, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_STATUS", _IOC_READ|_IOC_WRITE, 0x5720, 0x38 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_CONTINUE", _IOC_NONE, 0x54a2, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GINFO", _IOC_READ|_IOC_WRITE, 0x5403, 0xf8 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GPARAMS", _IOC_WRITE, 0x5404, 0x48 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GSTATUS", _IOC_READ|_IOC_WRITE, 0x5405, 0x50 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_INFO", _IOC_READ, 0x5411, 0xe8 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5401, 0x14 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PARAMS", _IOC_WRITE, 0x5412, 0x50 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PAUSE", _IOC_NONE, 0x54a3, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PVERSION", _IOC_READ, 0x5400, 0x04 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_SELECT", _IOC_WRITE, 0x5410, 0x34 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_START", _IOC_NONE, 0x54a0, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STATUS", _IOC_READ, 0x5414, 0x60 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STOP", _IOC_NONE, 0x54a1, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_TREAD", _IOC_WRITE, 0x5402, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", _IOC_NONE, 0x4840, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_INFO", _IOC_READ, 0x4820, 0x02 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_PLAY_NOTE", _IOC_WRITE, 0x4822, 0x0c },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_RESET", _IOC_NONE, 0x4821, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_CONNECTION", _IOC_WRITE, 0x4826, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_MODE", _IOC_WRITE, 0x4825, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4824, 0x09 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_VOICE", _IOC_WRITE, 0x4823, 0x12 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_AVAIL", _IOC_READ, 0x4321, 0x1c },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_DRAIN", _IOC_NONE, 0x4334, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x4310, 0xc4 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CODEC_CAPS", _IOC_READ|_IOC_WRITE, 0x4311, 0x2b88 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_METADATA", _IOC_READ|_IOC_WRITE, 0x4315, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_PARAMS", _IOC_READ, 0x4313, 0x78 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_IOCTL_VERSION", _IOC_READ, 0x4300, 0x04 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_NEXT_TRACK", _IOC_NONE, 0x4335, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PARTIAL_DRAIN", _IOC_NONE, 0x4336, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PAUSE", _IOC_NONE, 0x4330, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_RESUME", _IOC_NONE, 0x4331, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_METADATA", _IOC_WRITE, 0x4314, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_PARAMS", _IOC_WRITE, 0x4312, 0x84 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_START", _IOC_NONE, 0x4332, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_STOP", _IOC_NONE, 0x4333, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_TSTAMP", _IOC_READ, 0x4320, 0x14 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_PEEK", _IOC_READ|_IOC_WRITE, 0x4812, 0x1b0 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_POKE", _IOC_WRITE, 0x4811, 0x1b0 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CONTINUE", _IOC_NONE, 0x4881, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_DBG_READ", _IOC_READ, 0x4884, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_INFO", _IOC_READ, 0x4810, 0x80c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_PEEK", _IOC_READ|_IOC_WRITE, 0x4831, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_POKE", _IOC_WRITE, 0x4830, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PVERSION", _IOC_READ, 0x4840, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", _IOC_WRITE, 0x4883, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_STOP", _IOC_NONE, 0x4880, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", _IOC_READ|_IOC_WRITE, 0x4822, 0x10 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_POKE", _IOC_WRITE, 0x4821, 0x10 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", _IOC_WRITE, 0x4820, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_GET_INFO", _IOC_READ, 0x48f8, 0x20 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_LOCK", _IOC_NONE, 0x48f9, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_UNLOCK", _IOC_NONE, 0x48fa, 0x00 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_GET_WCAP", _IOC_READ|_IOC_WRITE, 0x4812, 0x08 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_PVERSION", _IOC_READ, 0x4810, 0x04 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_VERB_WRITE", _IOC_READ|_IOC_WRITE, 0x4811, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_9632_AEB", _IOC_READ, 0x4845, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", _IOC_READ, 0x4841, 0x24 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x1000 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4840, 0x3b0 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_VERSION", _IOC_READ, 0x4843, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", _IOC_WRITE, 0x4842, 0x08 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_CONFIG", _IOC_READ, 0x4841, 0x18 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_LTC", _IOC_READ, 0x4846, 0x10 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x08 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4842, 0x908 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_STATUS", _IOC_READ, 0x4847, 0x20 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_VERSION", _IOC_READ, 0x4848, 0x24 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_INFO", _IOC_READ, 0x4810, 0x28 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_LOAD_CODE", _IOC_WRITE, 0x4811, 0x3012 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_PAUSE", _IOC_NONE, 0x4815, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_RESTART", _IOC_NONE, 0x4816, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_START", _IOC_WRITE, 0x4813, 0x08 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_STOP", _IOC_NONE, 0x4814, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", _IOC_NONE, 0x4812, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_LOAD_PATCH", _IOC_READ|_IOC_WRITE, 0x4881, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MEM_AVAIL", _IOC_WRITE, 0x4884, 0x04 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MISC_MODE", _IOC_READ|_IOC_WRITE, 0x4884, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", _IOC_NONE, 0x4883, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_RESET_SAMPLES", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_VERSION", _IOC_READ, 0x4880, 0x04 },
+{ "sound/usb_stream.h", "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4890, 0x10 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_NAME", _IOC_READ, 0x7702, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PIN_STATUS", _IOC_NONE, 0x7709, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PROT_MASK", _IOC_NONE, 0x7706, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_SIZE", _IOC_NONE, 0x7704, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_PIN", _IOC_WRITE, 0x7707, 0x08 },
+{ "staging/android/ashmem.h", "ASHMEM_PURGE_ALL_CACHES", _IOC_NONE, 0x770a, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_NAME", _IOC_WRITE, 0x7701, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_PROT_MASK", _IOC_WRITE, 0x7705, 0x08 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_SIZE", _IOC_WRITE, 0x7703, 0x08 },
+{ "staging/android/ashmem.h", "ASHMEM_UNPIN", _IOC_WRITE, 0x7708, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_ALLOC", _IOC_READ|_IOC_WRITE, 0x4900, 0x20 },
+{ "staging/android/ion.h", "ION_IOC_CUSTOM", _IOC_READ|_IOC_WRITE, 0x4906, 0x10 },
+{ "staging/android/ion.h", "ION_IOC_FREE", _IOC_READ|_IOC_WRITE, 0x4901, 0x04 },
+{ "staging/android/ion.h", "ION_IOC_IMPORT", _IOC_READ|_IOC_WRITE, 0x4905, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_MAP", _IOC_READ|_IOC_WRITE, 0x4902, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SHARE", _IOC_READ|_IOC_WRITE, 0x4904, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SYNC", _IOC_READ|_IOC_WRITE, 0x4907, 0x08 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_DMA_MAPPING", _IOC_WRITE, 0x49f1, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_KERNEL_MAPPING", _IOC_WRITE, 0x49f2, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_SET_FD", _IOC_NONE, 0x49f0, 0x00 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_CREATE_FENCE", _IOC_READ|_IOC_WRITE, 0x5700, 0x28 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_INC", _IOC_WRITE, 0x5701, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_BRIGHTNESS", _IOC_READ, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_COLOR", _IOC_READ, 0x4605, 0x04 },
+{ "video/da8xx-fb.h", "FBIOGET_CONTRAST", _IOC_READ, 0x4601, 0x04 },
+{ "video/da8xx-fb.h", "FBIOPUT_CONTRAST", _IOC_WRITE, 0x4602, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_BRIGHTNESS", _IOC_WRITE, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_COLOR", _IOC_WRITE, 0x4606, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_HSYNC", _IOC_WRITE, 0x4609, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_VSYNC", _IOC_WRITE, 0x460a, 0x04 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_CREATE", _IOC_NONE, 0x6b00, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_OFFSET", _IOC_NONE, 0x6b04, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", _IOC_NONE, 0x6b01, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_SET_VIDEO_MODE", _IOC_NONE, 0x6b02, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_STRIDE", _IOC_NONE, 0x6b05, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_UVSTRIDE", _IOC_NONE, 0x6b03, 0x00 },
+{ "video/mbxfb.h", "MBXFB_IOCG_ALPHA", _IOC_READ, 0xf401, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_ALPHA", _IOC_WRITE, 0xf402, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_PLANEORDER", _IOC_READ, 0xf403, 0x02 },
+{ "video/mbxfb.h", "MBXFB_IOCS_REG", _IOC_WRITE, 0xf404, 0x0c },
+{ "video/mbxfb.h", "MBXFB_IOCX_OVERLAY", _IOC_READ|_IOC_WRITE, 0xf400, 0x30 },
+{ "video/mbxfb.h", "MBXFB_IOCX_REG", _IOC_READ|_IOC_WRITE, 0xf405, 0x0c },
+{ "video/sisfb.h", "SISFB_COMMAND", _IOC_READ|_IOC_WRITE, 0xf305, 0x54 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE", _IOC_READ, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE_OLD", _IOC_READ, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO", _IOC_READ, 0xf301, 0x11c },
+{ "video/sisfb.h", "SISFB_GET_INFO_OLD", _IOC_READ, 0x6ef8, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO_SIZE", _IOC_READ, 0xf300, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_TVPOSOFFSET", _IOC_READ, 0xf304, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS", _IOC_READ, 0xf302, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS_OLD", _IOC_READ, 0x6ef9, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE", _IOC_WRITE, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE_OLD", _IOC_WRITE, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_LOCK", _IOC_WRITE, 0xf306, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_TVPOSOFFSET", _IOC_WRITE, 0xf304, 0x04 },
+{ "video/sstfb.h", "SSTFB_GET_VGAPASS", _IOC_READ, 0x46dd, 0x04 },
+{ "video/sstfb.h", "SSTFB_SET_VGAPASS", _IOC_WRITE, 0x46dd, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_INTERDOMAIN", _IOC_NONE, 0x4501, 0x08 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_UNBOUND_PORT", _IOC_NONE, 0x4502, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_VIRQ", _IOC_NONE, 0x4500, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_NOTIFY", _IOC_NONE, 0x4504, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
+{ "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 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_MAX_GRANTS", _IOC_NONE, 0x4703, 0x04 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", _IOC_NONE, 0x4707, 0x10 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_UNMAP_GRANT_REF", _IOC_NONE, 0x4701, 0x10 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_EVTCHN", _IOC_NONE, 0x4200, 0x00 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_SETUP", _IOC_NONE, 0x4201, 0x00 },
diff --git a/strace/linux/64/syscallent.h b/strace/linux/64/syscallent.h
new file mode 100644
index 0000000..55c011c
--- /dev/null
+++ b/strace/linux/64/syscallent.h
@@ -0,0 +1,273 @@
+[  0] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[  1] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[  2] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[  3] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[  4] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[  5] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[  6] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[  7] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[  8] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[  9] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[ 10] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[ 11] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[ 12] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[ 13] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[ 14] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[ 15] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[ 16] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[ 17] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[ 18] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[ 19] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[ 20] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[ 21] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[ 22] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[ 23] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 24] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[ 25] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 26] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[ 27] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[ 28] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[ 29] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 30] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[ 31] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[ 32] = { 2,	TD,		SEN(flock),			"flock"			},
+[ 33] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[ 34] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[ 35] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[ 36] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[ 37] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[ 38] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[ 39] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 40] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 41] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[ 42] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[ 43] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[ 44] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[ 45] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 46] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 47] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[ 48] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[ 49] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 50] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 51] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 52] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 53] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[ 54] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[ 55] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 56] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[ 57] = { 1,	TD,		SEN(close),			"close"			},
+[ 58] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[ 59] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[ 60] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[ 61] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[ 62] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 63] = { 3,	TD,		SEN(read),			"read"			},
+[ 64] = { 3,	TD,		SEN(write),			"write"			},
+[ 65] = { 3,	TD,		SEN(readv),			"readv"			},
+[ 66] = { 3,	TD,		SEN(writev),			"writev"		},
+[ 67] = { 4,	TD,		SEN(pread),			"pread64"		},
+[ 68] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 69] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[ 70] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[ 71] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile"		},
+[ 72] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[ 73] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[ 74] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[ 75] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[ 76] = { 6,	TD,		SEN(splice),			"splice"		},
+[ 77] = { 4,	TD,		SEN(tee),			"tee"			},
+[ 78] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[ 79] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[ 80] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 81] = { 0,	0,		SEN(sync),			"sync"			},
+[ 82] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 83] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[ 84] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[ 85] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[ 86] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[ 87] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[ 88] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[ 89] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 90] = { 2,	0,		SEN(capget),			"capget"		},
+[ 91] = { 2,	0,		SEN(capset),			"capset"		},
+[ 92] = { 1,	NF,		SEN(personality),		"personality"		},
+[ 93] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[ 94] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[ 95] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[ 96] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[ 97] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[ 98] = { 6,	0,		SEN(futex),			"futex"			},
+[ 99] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[100] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[101] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[102] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[103] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[104] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[105] = { 3,	0,		SEN(init_module),		"init_module"		},
+[106] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[107] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[108] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[109] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[110] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[111] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[112] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[113] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[114] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[115] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[116] = { 3,	0,		SEN(syslog),			"syslog"		},
+[117] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[118] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[119] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[120] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[121] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[122] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[123] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[124] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[125] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[126] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[127] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[128] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[129] = { 2,	TS,		SEN(kill),			"kill"			},
+[130] = { 2,	TS,		SEN(kill),			"tkill"			},
+[131] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[132] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[133] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[134] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[135] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[136] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[137] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[138] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[139] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[140] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[141] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[142] = { 4,	0,		SEN(reboot),			"reboot"		},
+[143] = { 2,	0,		SEN(setregid),			"setregid"		},
+[144] = { 1,	0,		SEN(setgid),			"setgid"		},
+[145] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[146] = { 1,	0,		SEN(setuid),			"setuid"		},
+[147] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[148] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[149] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[150] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[151] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[152] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[153] = { 1,	0,		SEN(times),			"times"			},
+[154] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[155] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[156] = { 1,	0,		SEN(getsid),			"getsid"		},
+[157] = { 0,	0,		SEN(setsid),			"setsid"		},
+[158] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[159] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[160] = { 1,	0,		SEN(uname),			"uname"			},
+[161] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[162] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[163] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[164] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[165] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[166] = { 1,	NF,		SEN(umask),			"umask"			},
+[167] = { 5,	0,		SEN(prctl),			"prctl"			},
+[168] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[169] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[170] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[171] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[172] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[173] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[174] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[175] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[176] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[177] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[178] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[179] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[180] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[181] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[182] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[183] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[184] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[185] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[186] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[187] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[188] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[189] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[190] = { 3,	TI,		SEN(semget),			"semget"		},
+[191] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[192] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[193] = { 3,	TI,		SEN(semop),			"semop"			},
+[194] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[195] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[196] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[197] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[198] = { 3,	TN,		SEN(socket),			"socket"		},
+[199] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[200] = { 3,	TN,		SEN(bind),			"bind"			},
+[201] = { 2,	TN,		SEN(listen),			"listen"		},
+[202] = { 3,	TN,		SEN(accept),			"accept"		},
+[203] = { 3,	TN,		SEN(connect),			"connect"		},
+[204] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[205] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[206] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[207] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[208] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[209] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[210] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[211] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[212] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[213] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[214] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[215] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[216] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[217] = { 5,	0,		SEN(add_key),			"add_key"		},
+[218] = { 4,	0,		SEN(request_key),		"request_key"		},
+[219] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[220] = { 5,	TP,		SEN(clone),			"clone"			},
+[221] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[222] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[223] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[224] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[225] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[226] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[227] = { 3,	TM,		SEN(msync),			"msync"			},
+[228] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[229] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[230] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[231] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[232] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[233] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[234] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[235] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[236] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[237] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[238] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[239] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[240] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[241] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[242] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[243] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+/* [244 ... 259] are arch specific */
+[260] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[261] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[262] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[263] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[264] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[265] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[266] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[267] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[268] = { 2,	TD,		SEN(setns),			"setns"			},
+[269] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[270] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[271] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[272] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[273] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[274] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[275] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[276] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[277] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[278] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[279] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[280] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[281] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[282] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[283] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[284] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[285] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[286] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[287] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
diff --git a/strace/linux/aarch64/arch_regs.c b/strace/linux/aarch64/arch_regs.c
new file mode 100644
index 0000000..8e18a71
--- /dev/null
+++ b/strace/linux/aarch64/arch_regs.c
@@ -0,0 +1,38 @@
+struct arm_pt_regs {
+        uint32_t uregs[18];
+};
+#define ARM_cpsr       uregs[16]
+#define ARM_pc         uregs[15]
+#define ARM_lr         uregs[14]
+#define ARM_sp         uregs[13]
+#define ARM_ip         uregs[12]
+#define ARM_fp         uregs[11]
+#define ARM_r10        uregs[10]
+#define ARM_r9         uregs[9]
+#define ARM_r8         uregs[8]
+#define ARM_r7         uregs[7]
+#define ARM_r6         uregs[6]
+#define ARM_r5         uregs[5]
+#define ARM_r4         uregs[4]
+#define ARM_r3         uregs[3]
+#define ARM_r2         uregs[2]
+#define ARM_r1         uregs[1]
+#define ARM_r0         uregs[0]
+#define ARM_ORIG_r0    uregs[17]
+
+static union {
+	struct user_pt_regs aarch64_r;
+	struct arm_pt_regs  arm_r;
+} arm_regs_union;
+#define aarch64_regs arm_regs_union.aarch64_r
+#define arm_regs     arm_regs_union.arm_r
+
+uint64_t *const aarch64_sp_ptr = (uint64_t *) &aarch64_regs.sp;
+uint32_t *const arm_sp_ptr = (uint32_t *) &arm_regs.ARM_sp;
+static struct iovec aarch64_io = {
+	.iov_base = &arm_regs_union
+};
+
+#define ARCH_REGS_FOR_GETREGSET arm_regs_union
+#define ARCH_IOVEC_FOR_GETREGSET aarch64_io
+#define ARCH_PC_REG ((aarch64_io.iov_len == sizeof(arm_regs)) ? arm_regs.ARM_pc : aarch64_regs.pc)
diff --git a/strace/linux/aarch64/arch_regs.h b/strace/linux/aarch64/arch_regs.h
new file mode 100644
index 0000000..9a5e33e
--- /dev/null
+++ b/strace/linux/aarch64/arch_regs.h
@@ -0,0 +1,2 @@
+extern uint64_t *const aarch64_sp_ptr;
+extern uint32_t *const arm_sp_ptr;
diff --git a/strace/linux/aarch64/arch_sigreturn.c b/strace/linux/aarch64/arch_sigreturn.c
new file mode 100644
index 0000000..f0e29c2
--- /dev/null
+++ b/strace/linux/aarch64/arch_sigreturn.c
@@ -0,0 +1 @@
+#include "arm/arch_sigreturn.c"
diff --git a/strace/linux/aarch64/errnoent1.h b/strace/linux/aarch64/errnoent1.h
new file mode 100644
index 0000000..a0394d4
--- /dev/null
+++ b/strace/linux/aarch64/errnoent1.h
@@ -0,0 +1,2 @@
+/* ARM personality */
+#include "errnoent.h"
diff --git a/strace/linux/aarch64/get_error.c b/strace/linux/aarch64/get_error.c
new file mode 100644
index 0000000..a3aa127
--- /dev/null
+++ b/strace/linux/aarch64/get_error.c
@@ -0,0 +1,19 @@
+#define get_error arm_get_error
+#include "arm/get_error.c"
+#undef get_error
+
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (tcp->currpers == 1) {
+		arm_get_error(tcp, check_errno);
+		return;
+	}
+
+	if (check_errno && is_negated_errno(aarch64_regs.regs[0])) {
+		tcp->u_rval = -1;
+		tcp->u_error = -aarch64_regs.regs[0];
+	} else {
+		tcp->u_rval = aarch64_regs.regs[0];
+	}
+}
diff --git a/strace/linux/aarch64/get_scno.c b/strace/linux/aarch64/get_scno.c
new file mode 100644
index 0000000..c0fd482
--- /dev/null
+++ b/strace/linux/aarch64/get_scno.c
@@ -0,0 +1,24 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	long scno = 0;
+
+	switch (aarch64_io.iov_len) {
+		case sizeof(aarch64_regs):
+			/* We are in 64-bit mode */
+			scno = aarch64_regs.regs[8];
+			update_personality(tcp, 0);
+			break;
+		case sizeof(arm_regs):
+			/* We are in 32-bit mode */
+			/* Note: we don't support OABI, unlike 32-bit ARM build */
+			scno = arm_regs.ARM_r7;
+			scno = shuffle_scno(scno);
+			update_personality(tcp, 1);
+			break;
+	}
+
+	tcp->scno = scno;
+	return 1;
+}
diff --git a/strace/linux/aarch64/get_syscall_args.c b/strace/linux/aarch64/get_syscall_args.c
new file mode 100644
index 0000000..ea6e497
--- /dev/null
+++ b/strace/linux/aarch64/get_syscall_args.c
@@ -0,0 +1,18 @@
+#define get_syscall_args arm_get_syscall_args
+#include "arm/get_syscall_args.c"
+#undef get_syscall_args
+
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	if (tcp->currpers == 1)
+		return arm_get_syscall_args(tcp);
+	tcp->u_arg[0] = aarch64_regs.regs[0];
+	tcp->u_arg[1] = aarch64_regs.regs[1];
+	tcp->u_arg[2] = aarch64_regs.regs[2];
+	tcp->u_arg[3] = aarch64_regs.regs[3];
+	tcp->u_arg[4] = aarch64_regs.regs[4];
+	tcp->u_arg[5] = aarch64_regs.regs[5];
+	return 1;
+}
diff --git a/strace/linux/aarch64/ioctls_arch0.h b/strace/linux/aarch64/ioctls_arch0.h
new file mode 100644
index 0000000..6a674cc
--- /dev/null
+++ b/strace/linux/aarch64/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/arm64/include/ tree. */
diff --git a/strace/linux/aarch64/ioctls_arch1.h b/strace/linux/aarch64/ioctls_arch1.h
new file mode 100644
index 0000000..b722d22
--- /dev/null
+++ b/strace/linux/aarch64/ioctls_arch1.h
@@ -0,0 +1 @@
+#include "arm/ioctls_arch0.h"
diff --git a/strace/linux/aarch64/ioctls_inc0.h b/strace/linux/aarch64/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/aarch64/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/aarch64/ioctls_inc1.h b/strace/linux/aarch64/ioctls_inc1.h
new file mode 100644
index 0000000..46c11b1
--- /dev/null
+++ b/strace/linux/aarch64/ioctls_inc1.h
@@ -0,0 +1 @@
+#include "arm/ioctls_inc0.h"
diff --git a/strace/linux/aarch64/signalent1.h b/strace/linux/aarch64/signalent1.h
new file mode 100644
index 0000000..093cba7
--- /dev/null
+++ b/strace/linux/aarch64/signalent1.h
@@ -0,0 +1 @@
+#include "signalent.h"
diff --git a/strace/linux/aarch64/syscallent.h b/strace/linux/aarch64/syscallent.h
new file mode 100644
index 0000000..6b23f8c
--- /dev/null
+++ b/strace/linux/aarch64/syscallent.h
@@ -0,0 +1,71 @@
+#include "64/syscallent.h"
+
+/* Arch-specific block, not used on AArch64 */
+[244 ... 259] = { },
+
+/* Quote from asm-generic/unistd.h:
+ *
+ * All syscalls below here should go away really,
+ * these are provided for both review and as a porting
+ * help for the C library version.
+ *
+ * Last chance: are any of these important enough to
+ * enable by default?
+ */
+
+[1024] = { 3,	TD|TF,		SEN(open),		"open"		},
+[1025] = { 2,	TF,		SEN(link),		"link"		},
+[1026] = { 1,	TF,		SEN(unlink),		"unlink"	},
+[1027] = { 3,	TF,		SEN(mknod),		"mknod"		},
+[1028] = { 2,	TF,		SEN(chmod),		"chmod"		},
+[1029] = { 3,	TF,		SEN(chown),		"chown"		},
+[1030] = { 2,	TF,		SEN(mkdir),		"mkdir"		},
+[1031] = { 1,	TF,		SEN(rmdir),		"rmdir"		},
+[1032] = { 3,	TF,		SEN(chown),		"lchown"	},
+[1033] = { 2,	TF,		SEN(access),		"access"	},
+[1034] = { 2,	TF,		SEN(rename),		"rename"	},
+[1035] = { 3,	TF,		SEN(readlink),		"readlink"	},
+[1036] = { 2,	TF,		SEN(symlink),		"symlink"	},
+[1037] = { 2,	TF,		SEN(utimes),		"utimes"	},
+[1038] = { 2,	TF,		SEN(stat),		"stat"		},
+[1039] = { 2,	TF,		SEN(lstat),		"lstat"		},
+[1040] = { 1,	TD,		SEN(pipe),		"pipe"		},
+[1041] = { 2,	TD,		SEN(dup2),		"dup2"		},
+[1042] = { 1,	TD,		SEN(epoll_create),	"epoll_create"	},
+[1043] = { 0,	TD,		SEN(inotify_init),	"inotify_init"	},
+[1044] = { 1,	TD,		SEN(eventfd),		"eventfd"	},
+[1045] = { 3,	TD|TS,		SEN(signalfd),		"signalfd"	},
+[1046] = { 4,	TD|TN,		SEN(sendfile64),	"sendfile"	},
+[1047] = { 2,	TD,		SEN(ftruncate),		"ftruncate"	},
+[1048] = { 2,	TF,		SEN(truncate),		"truncate"	},
+[1049] = { 2,	TF,		SEN(stat),		"stat"		},
+[1050] = { 2,	TF,		SEN(lstat),		"lstat"		},
+[1051] = { 2,	TD,		SEN(fstat),		"fstat"		},
+[1052] = { 3,	TD,		SEN(fcntl),		"fcntl"		},
+[1053] = { 4,	TD,		SEN(fadvise64),		"fadvise64"	},
+[1054] = { 4,	TD|TF,		SEN(newfstatat),	"newfstatat"	},
+[1055] = { 2,	TD,		SEN(fstatfs),		"fstatfs"	},
+[1056] = { 2,	TF,		SEN(statfs),		"statfs"	},
+[1057] = { 3,	TD,		SEN(lseek),		"lseek"		},
+[1058] = { 6,	TD|TM|SI,	SEN(mmap),		"mmap"		},
+[1059] = { 1,	0,		SEN(alarm),		"alarm"		},
+[1060] = { 0,	0,		SEN(getpgrp),		"getpgrp"	},
+[1061] = { 0,	TS,		SEN(pause),		"pause"		},
+[1062] = { 1,	0,		SEN(time),		"time"		},
+[1063] = { 2,	TF,		SEN(utime),		"utime"		},
+[1064] = { 2,	TD|TF,		SEN(creat),		"creat"		},
+[1065] = { 3,	TD,		SEN(getdents),		"getdents"	},
+[1066] = { 3,	TD|TF,		SEN(futimesat),		"futimesat"	},
+[1067] = { 5,	TD,		SEN(select),		"select"	},
+[1068] = { 3,	TD,		SEN(poll),		"poll"		},
+[1069] = { 4,	TD,		SEN(epoll_wait),	"epoll_wait"	},
+[1070] = { 2,	0,		SEN(ustat),		"ustat"		},
+[1071] = { 0,	TP,		SEN(vfork),		"vfork"		},
+[1072] = { 4,	TP,		SEN(wait4),		"wait4"		},
+[1073] = { 4,	TN,		SEN(recv),		"recv"		},
+[1074] = { 4,	TN,		SEN(send),		"send"		},
+[1075] = { 2,	0,		SEN(bdflush),		"bdflush"	},
+[1076] = { 1,	TF,		SEN(umount),		"umount"	},
+[1077] = { 1,	TF,		SEN(uselib),		"uselib"	},
+[1078] = { 1,	0,		SEN(sysctl),		"sysctl"	},
+[1079] = { 0,	TP,		SEN(fork),		"fork"		},
diff --git a/strace/linux/aarch64/syscallent1.h b/strace/linux/aarch64/syscallent1.h
new file mode 100644
index 0000000..1b892be
--- /dev/null
+++ b/strace/linux/aarch64/syscallent1.h
@@ -0,0 +1 @@
+#include "../arm/syscallent.h"
diff --git a/strace/linux/alpha/arch_getrval2.c b/strace/linux/alpha/arch_getrval2.c
new file mode 100644
index 0000000..90ee392
--- /dev/null
+++ b/strace/linux/alpha/arch_getrval2.c
@@ -0,0 +1,8 @@
+long
+getrval2(struct tcb *tcp)
+{
+	long r20;
+	if (upeek(tcp->pid, 20, &r20) < 0)
+		return -1;
+	return r20;
+}
diff --git a/strace/linux/alpha/arch_regs.c b/strace/linux/alpha/arch_regs.c
new file mode 100644
index 0000000..df1878e
--- /dev/null
+++ b/strace/linux/alpha/arch_regs.c
@@ -0,0 +1,3 @@
+static long alpha_r0;
+static long alpha_a3;
+#define ARCH_PC_PEEK_ADDR REG_PC
diff --git a/strace/linux/alpha/arch_regs.h b/strace/linux/alpha/arch_regs.h
new file mode 100644
index 0000000..66277fd
--- /dev/null
+++ b/strace/linux/alpha/arch_regs.h
@@ -0,0 +1,5 @@
+#define REG_R0 0
+#define REG_A0 16
+#define REG_A3 19
+#define REG_FP 30
+#define REG_PC 64
diff --git a/strace/linux/alpha/arch_sigreturn.c b/strace/linux/alpha/arch_sigreturn.c
new file mode 100644
index 0000000..71a84ef
--- /dev/null
+++ b/strace/linux/alpha/arch_sigreturn.c
@@ -0,0 +1,13 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	long addr;
+
+	if (upeek(tcp->pid, REG_FP, &addr) < 0)
+		return;
+	addr += offsetof(struct sigcontext, sc_mask);
+
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/alpha/errnoent.h b/strace/linux/alpha/errnoent.h
new file mode 100644
index 0000000..b9157cf
--- /dev/null
+++ b/strace/linux/alpha/errnoent.h
@@ -0,0 +1,148 @@
+[  1] = "EPERM",
+[  2] = "ENOENT",
+[  3] = "ESRCH",
+[  4] = "EINTR",
+[  5] = "EIO",
+[  6] = "ENXIO",
+[  7] = "E2BIG",
+[  8] = "ENOEXEC",
+[  9] = "EBADF",
+[ 10] = "ECHILD",
+[ 11] = "EDEADLK",
+[ 12] = "ENOMEM",
+[ 13] = "EACCES",
+[ 14] = "EFAULT",
+[ 15] = "ENOTBLK",
+[ 16] = "EBUSY",
+[ 17] = "EEXIST",
+[ 18] = "EXDEV",
+[ 19] = "ENODEV",
+[ 20] = "ENOTDIR",
+[ 21] = "EISDIR",
+[ 22] = "EINVAL",
+[ 23] = "ENFILE",
+[ 24] = "EMFILE",
+[ 25] = "ENOTTY",
+[ 26] = "ETXTBSY",
+[ 27] = "EFBIG",
+[ 28] = "ENOSPC",
+[ 29] = "ESPIPE",
+[ 30] = "EROFS",
+[ 31] = "EMLINK",
+[ 32] = "EPIPE",
+[ 33] = "EDOM",
+[ 34] = "ERANGE",
+[ 35] = "EAGAIN",
+[ 36] = "EINPROGRESS",
+[ 37] = "EALREADY",
+[ 38] = "ENOTSOCK",
+[ 39] = "EDESTADDRREQ",
+[ 40] = "EMSGSIZE",
+[ 41] = "EPROTOTYPE",
+[ 42] = "ENOPROTOOPT",
+[ 43] = "EPROTONOSUPPORT",
+[ 44] = "ESOCKTNOSUPPORT",
+[ 45] = "EOPNOTSUPP",
+[ 46] = "EPFNOSUPPORT",
+[ 47] = "EAFNOSUPPORT",
+[ 48] = "EADDRINUSE",
+[ 49] = "EADDRNOTAVAIL",
+[ 50] = "ENETDOWN",
+[ 51] = "ENETUNREACH",
+[ 52] = "ENETRESET",
+[ 53] = "ECONNABORTED",
+[ 54] = "ECONNRESET",
+[ 55] = "ENOBUFS",
+[ 56] = "EISCONN",
+[ 57] = "ENOTCONN",
+[ 58] = "ESHUTDOWN",
+[ 59] = "ETOOMANYREFS",
+[ 60] = "ETIMEDOUT",
+[ 61] = "ECONNREFUSED",
+[ 62] = "ELOOP",
+[ 63] = "ENAMETOOLONG",
+[ 64] = "EHOSTDOWN",
+[ 65] = "EHOSTUNREACH",
+[ 66] = "ENOTEMPTY",
+[ 68] = "EUSERS",
+[ 69] = "EDQUOT",
+[ 70] = "ESTALE",
+[ 71] = "EREMOTE",
+[ 77] = "ENOLCK",
+[ 78] = "ENOSYS",
+[ 80] = "ENOMSG",
+[ 81] = "EIDRM",
+[ 82] = "ENOSR",
+[ 83] = "ETIME",
+[ 84] = "EBADMSG",
+[ 85] = "EPROTO",
+[ 86] = "ENODATA",
+[ 87] = "ENOSTR",
+[ 88] = "ECHRNG",
+[ 89] = "EL2NSYNC",
+[ 90] = "EL3HLT",
+[ 91] = "EL3RST",
+[ 92] = "ENOPKG",
+[ 93] = "ELNRNG",
+[ 94] = "EUNATCH",
+[ 95] = "ENOCSI",
+[ 96] = "EL2HLT",
+[ 97] = "EBADE",
+[ 98] = "EBADR",
+[ 99] = "EXFULL",
+[100] = "ENOANO",
+[101] = "EBADRQC",
+[102] = "EBADSLT",
+[103] = "EDEADLOCK",
+[104] = "EBFONT",
+[105] = "ENONET",
+[106] = "ENOLINK",
+[107] = "EADV",
+[108] = "ESRMNT",
+[109] = "ECOMM",
+[110] = "EMULTIHOP",
+[111] = "EDOTDOT",
+[112] = "EOVERFLOW",
+[113] = "ENOTUNIQ",
+[114] = "EBADFD",
+[115] = "EREMCHG",
+[116] = "EILSEQ",
+[117] = "EUCLEAN",
+[118] = "ENOTNAM",
+[119] = "ENAVAIL",
+[120] = "EISNAM",
+[121] = "EREMOTEIO",
+[122] = "ELIBACC",
+[123] = "ELIBBAD",
+[124] = "ELIBSCN",
+[125] = "ELIBMAX",
+[126] = "ELIBEXEC",
+[127] = "ERESTART",
+[128] = "ESTRPIPE",
+[129] = "ENOMEDIUM",
+[130] = "EMEDIUMTYPE",
+[131] = "ECANCELED",
+[132] = "ENOKEY",
+[133] = "EKEYEXPIRED",
+[134] = "EKEYREVOKED",
+[135] = "EKEYREJECTED",
+[136] = "EOWNERDEAD",
+[137] = "ENOTRECOVERABLE",
+[138] = "ERFKILL",
+[139] = "EHWPOISON",
+[512] = "ERESTARTSYS",
+[513] = "ERESTARTNOINTR",
+[514] = "ERESTARTNOHAND",
+[515] = "ENOIOCTLCMD",
+[516] = "ERESTART_RESTARTBLOCK",
+[517] = "EPROBE_DEFER",
+[518] = "EOPENSTALE",
+[521] = "EBADHANDLE",
+[522] = "ENOTSYNC",
+[523] = "EBADCOOKIE",
+[524] = "ENOTSUPP",
+[525] = "ETOOSMALL",
+[526] = "ESERVERFAULT",
+[527] = "EBADTYPE",
+[528] = "EJUKEBOX",
+[529] = "EIOCBQUEUED",
diff --git a/strace/linux/alpha/get_error.c b/strace/linux/alpha/get_error.c
new file mode 100644
index 0000000..d4928d4
--- /dev/null
+++ b/strace/linux/alpha/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (alpha_a3) {
+		tcp->u_rval = -1;
+		tcp->u_error = alpha_r0;
+	} else {
+		tcp->u_rval = alpha_r0;
+	}
+}
diff --git a/strace/linux/alpha/get_scno.c b/strace/linux/alpha/get_scno.c
new file mode 100644
index 0000000..fc09921
--- /dev/null
+++ b/strace/linux/alpha/get_scno.c
@@ -0,0 +1,26 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	long scno = 0;
+
+	if (upeek(tcp->pid, REG_A3, &alpha_a3) < 0)
+		return -1;
+	if (upeek(tcp->pid, REG_R0, &scno) < 0)
+		return -1;
+
+	/*
+	 * Do some sanity checks to figure out if it's
+	 * really a syscall entry
+	 */
+	if (!SCNO_IN_RANGE(scno)) {
+		if (alpha_a3 == 0 || alpha_a3 == -1) {
+			if (debug_flag)
+				error_msg("stray syscall exit: r0 = %ld", scno);
+			return 0;
+		}
+	}
+
+	tcp->scno = scno;
+	return 1;
+}
diff --git a/strace/linux/alpha/get_syscall_args.c b/strace/linux/alpha/get_syscall_args.c
new file mode 100644
index 0000000..a385726
--- /dev/null
+++ b/strace/linux/alpha/get_syscall_args.c
@@ -0,0 +1,11 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, REG_A0+i, &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/alpha/get_syscall_result.c b/strace/linux/alpha/get_syscall_result.c
new file mode 100644
index 0000000..f4c504f
--- /dev/null
+++ b/strace/linux/alpha/get_syscall_result.c
@@ -0,0 +1,6 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return (upeek(tcp->pid, REG_A3, &alpha_a3) < 0 ||
+		upeek(tcp->pid, REG_R0, &alpha_r0) < 0) ? -1 : 0;
+}
diff --git a/strace/linux/alpha/ioctls_arch0.h b/strace/linux/alpha/ioctls_arch0.h
new file mode 100644
index 0000000..526f3fe
--- /dev/null
+++ b/strace/linux/alpha/ioctls_arch0.h
@@ -0,0 +1,82 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/alpha/include/ tree. */
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x741f, 0x00 },
+{ "asm/ioctls.h", "TCGETA", _IOC_READ, 0x7417, 0x12 },
+{ "asm/ioctls.h", "TCGETS", _IOC_READ, 0x7413, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x741d, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm/ioctls.h", "TCSETA", _IOC_WRITE, 0x7418, 0x12 },
+{ "asm/ioctls.h", "TCSETAF", _IOC_WRITE, 0x741c, 0x12 },
+{ "asm/ioctls.h", "TCSETAW", _IOC_WRITE, 0x7419, 0x12 },
+{ "asm/ioctls.h", "TCSETS", _IOC_WRITE, 0x7414, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", _IOC_WRITE, 0x7416, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", _IOC_WRITE, 0x7415, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x741e, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETC", _IOC_READ, 0x7412, 0x06 },
+{ "asm/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm/ioctls.h", "TIOCGETP", _IOC_READ, 0x7408, 0x06 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGLTC", _IOC_READ, 0x7474, 0x06 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7477, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x542e, 0x20 },
+{ "asm/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm/ioctls.h", "TIOCGSID", 0, 0x5429, 0 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm/ioctls.h", "TIOCGWINSZ", _IOC_READ, 0x7468, 0x08 },
+{ "asm/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm/ioctls.h", "TIOCSETC", _IOC_WRITE, 0x7411, 0x06 },
+{ "asm/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm/ioctls.h", "TIOCSETN", _IOC_WRITE, 0x740a, 0x06 },
+{ "asm/ioctls.h", "TIOCSETP", _IOC_WRITE, 0x7409, 0x06 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSLTC", _IOC_WRITE, 0x7475, 0x06 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7476, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x542f, 0x20 },
+{ "asm/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCSWINSZ", _IOC_WRITE, 0x7467, 0x08 },
+{ "asm/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm/sockios.h", "FIOGETOWN", _IOC_READ, 0x667b, 0x04 },
+{ "asm/sockios.h", "FIOSETOWN", _IOC_WRITE, 0x667c, 0x04 },
+{ "asm/sockios.h", "SIOCATMARK", _IOC_READ, 0x7307, 0x04 },
+{ "asm/sockios.h", "SIOCGPGRP", _IOC_READ, 0x7309, 0x04 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", _IOC_WRITE, 0x7308, 0x04 },
diff --git a/strace/linux/alpha/ioctls_inc0.h b/strace/linux/alpha/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/alpha/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/alpha/signalent.h b/strace/linux/alpha/signalent.h
new file mode 100644
index 0000000..174b17b
--- /dev/null
+++ b/strace/linux/alpha/signalent.h
@@ -0,0 +1,33 @@
+	"SIG_0",	/* 0 */
+	"SIGHUP",	/* 1 */
+	"SIGINT",	/* 2 */
+	"SIGQUIT",	/* 3 */
+	"SIGILL",	/* 4 */
+	"SIGTRAP",	/* 5 */
+	"SIGABRT",	/* 6 */
+	"SIGEMT",	/* 7 */
+	"SIGFPE",	/* 8 */
+	"SIGKILL",	/* 9 */
+	"SIGBUS",	/* 10 */
+	"SIGSEGV",	/* 11 */
+	"SIGSYS",	/* 12 */
+	"SIGPIPE",	/* 13 */
+	"SIGALRM",	/* 14 */
+	"SIGTERM",	/* 15 */
+	"SIGURG",	/* 16 */
+	"SIGSTOP",	/* 17 */
+	"SIGTSTP",	/* 18 */
+	"SIGCONT",	/* 19 */
+	"SIGCHLD",	/* 20 */
+	"SIGTTIN",	/* 21 */
+	"SIGTTOU",	/* 22 */
+	"SIGIO",	/* 23 */
+	"SIGXCPU",	/* 24 */
+	"SIGXFSZ",	/* 25 */
+	"SIGVTALRM",	/* 26 */
+	"SIGPROF",	/* 27 */
+	"SIGWINCH",	/* 28 */
+	"SIGINFO",	/* 29 */
+	"SIGUSR1",	/* 30 */
+	"SIGUSR2",	/* 31 */
+	"SIGRTMIN",	/* 32 */
diff --git a/strace/linux/alpha/syscallent.h b/strace/linux/alpha/syscallent.h
new file mode 100644
index 0000000..eaa316f
--- /dev/null
+++ b/strace/linux/alpha/syscallent.h
@@ -0,0 +1,478 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 6,	0,		SEN(printargs),			"osf_syscall"		}, /*not implemented */
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 5,	0,		SEN(printargs),			"osf_old_open"		}, /*not implemented */
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 4,	TP,		SEN(osf_wait4),			"osf_wait4"		},
+[  8] = { 5,	0,		SEN(printargs),			"osf_old_creat"		}, /*not implemented */
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 5,	0,		SEN(printargs),			"osf_execve"		}, /*not implemented */
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown),			"chown"			},
+[ 17] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 18] = { 5,	0,		SEN(printargs),			"osf_getfsstat"		}, /*not implemented */
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getxpid),			"getxpid"		},
+[ 21] = { 4,	0,		SEN(printargs),			"osf_mount"		},
+[ 22] = { 2,	TF,		SEN(umount2),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getxuid),			"getxuid"		},
+[ 25] = { 5,	0,		SEN(printargs),			"exec_with_loader"	}, /*not implemented */
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 5,	0,		SEN(printargs),			"osf_nrecvmsg"		}, /*not implemented */
+[ 28] = { 5,	0,		SEN(printargs),			"osf_nsendmsg"		}, /*not implemented */
+[ 29] = { 5,	0,		SEN(printargs),			"osf_nrecvfrom"		}, /*not implemented */
+[ 30] = { 5,	0,		SEN(printargs),			"osf_naccept"		}, /*not implemented */
+[ 31] = { 5,	0,		SEN(printargs),			"osf_ngetpeername"	}, /*not implemented */
+[ 32] = { 5,	0,		SEN(printargs),			"osf_ngetsockname"	}, /*not implemented */
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 5,	0,		SEN(printargs),			"osf_chflags"		}, /*not implemented */
+[ 35] = { 5,	0,		SEN(printargs),			"osf_fchflags"		}, /*not implemented */
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 5,	0,		SEN(printargs),			"osf_old_stat"		}, /*not implemented */
+[ 39] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 40] = { 5,	0,		SEN(printargs),			"osf_old_lstat"		}, /*not implemented */
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 4,	0,		SEN(printargs),			"osf_set_program_attributes"	},
+[ 44] = { 5,	0,		SEN(printargs),			"osf_profil"		}, /*not implemented */
+[ 45] = { 3,	TD|TF,		SEN(open),			"open"			},
+[ 46] = { 5,	0,		SEN(printargs),			"osf_old_sigaction"	}, /*not implemented */
+[ 47] = { 1,	NF,		SEN(getxgid),			"getxgid"		},
+[ 48] = { 2,	TS,		SEN(sigprocmask),		"osf_sigprocmask"	},
+[ 49] = { 5,	0,		SEN(printargs),			"osf_getlogin"		}, /*not implemented */
+[ 50] = { 5,	0,		SEN(printargs),			"osf_setlogin"		}, /*not implemented */
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 53] = { },
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 5,	0,		SEN(printargs),			"osf_reboot"		}, /*not implemented */
+[ 56] = { 5,	0,		SEN(printargs),			"osf_revoke"		}, /*not implemented */
+[ 57] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 58] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 59] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 5,	0,		SEN(printargs),			"osf_old_fstat"		}, /*not implemented */
+[ 63] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 64] = { 0,	0,		SEN(getpagesize),		"getpagesize"		},
+[ 65] = { 5,	TM,		SEN(printargs),			"osf_mremap"		}, /*not implemented */
+[ 66] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[ 67] = { 2,	TF,		SEN(stat),			"stat"			},
+[ 68] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[ 69] = { 5,	TM,		SEN(printargs),			"osf_sbrk"		}, /*not implemented */
+[ 70] = { 5,	0,		SEN(printargs),			"osf_sstk"		}, /*not implemented */
+[ 71] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 72] = { 5,	0,		SEN(printargs),			"osf_old_vadvise"	}, /*not implemented */
+[ 73] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 74] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[ 75] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[ 76] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[ 77] = { 5,	0,		SEN(printargs),			"osf_kmodcall"		}, /*not implemented */
+[ 78] = { 5,	TM,		SEN(printargs),			"osf_mincore"		}, /*not implemented */
+[ 79] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[ 80] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[ 81] = { 5,	0,		SEN(printargs),			"osf_old_getpgrp"	}, /*not implemented */
+[ 82] = { 2,	0,		SEN(setpgrp),			"setpgrp"		},
+[ 83] = { 3,	0,		SEN(osf_setitimer),		"osf_setitimer"		},
+[ 84] = { 5,	0,		SEN(printargs),			"osf_old_wait"		}, /*not implemented */
+[ 85] = { 5,	0,		SEN(printargs),			"osf_table"		}, /*not implemented */
+[ 86] = { 2,	0,		SEN(osf_getitimer),		"osf_getitimer"		},
+[ 87] = { 2,	0,		SEN(gethostname),		"gethostname"		},
+[ 88] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 89] = { 0,	0,		SEN(getdtablesize),		"getdtablesize"		},
+[ 90] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 91] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 92] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 93] = { 5,	0,		SEN(osf_select),		"osf_select"		},
+[ 94] = { 3,	TD,		SEN(poll),			"poll"			},
+[ 95] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 96] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 97] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 98] = { 3,	TN,		SEN(connect),			"connect"		},
+[ 99] = { 3,	TN,		SEN(accept),			"accept"		},
+[100] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[101] = { 4,	TN,		SEN(send),			"send"			},
+[102] = { 4,	TN,		SEN(recv),			"recv"			},
+[103] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[104] = { 3,	TN,		SEN(bind),			"bind"			},
+[105] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[106] = { 2,	TN,		SEN(listen),			"listen"		},
+[107] = { 5,	0,		SEN(printargs),			"osf_plock"		}, /*not implemented */
+[108] = { 5,	0,		SEN(printargs),			"osf_old_sigvec"	}, /*not implemented */
+[109] = { 5,	0,		SEN(printargs),			"osf_old_sigblock"	}, /*not implemented */
+[110] = { 5,	0,		SEN(printargs),			"osf_old_sigsetmask"	}, /*not implemented */
+[111] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[112] = { 2,	0,		SEN(printargs),			"osf_sigstack"		},
+[113] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[114] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[115] = { 5,	0,		SEN(printargs),			"osf_old_vtrace"	}, /*not implemented */
+[116] = { 2,	0,		SEN(osf_gettimeofday),		"osf_gettimeofday"	},
+[117] = { 2,	0,		SEN(osf_getrusage),		"osf_getrusage"		},
+[118] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[119] = { },
+[120] = { 3,	TD,		SEN(readv),			"readv"			},
+[121] = { 3,	TD,		SEN(writev),			"writev"		},
+[122] = { 2,	0,		SEN(osf_settimeofday),		"osf_settimeofday"	},
+[123] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[124] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[125] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[126] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[127] = { 2,	0,		SEN(setregid),			"setregid"		},
+[128] = { 2,	TF,		SEN(rename),			"rename"		},
+[129] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[130] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[131] = { 2,	TD,		SEN(flock),			"flock"			},
+[132] = { 1,	0,		SEN(setgid),			"setgid"		},
+[133] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[134] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[135] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[136] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[137] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[138] = { 2,	0,		SEN(osf_utimes),		"osf_utimes"		},
+[139] = { 5,	0,		SEN(printargs),			"osf_old_sigreturn"	},
+[140] = { 5,	0,		SEN(printargs),			"osf_adjtime"		}, /*not implemented */
+[141] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[142] = { 5,	0,		SEN(printargs),			"osf_gethostid"		}, /*not implemented */
+[143] = { 5,	0,		SEN(printargs),			"osf_sethostid"		}, /*not implemented */
+[144] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[145] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[146] = { 5,	0,		SEN(printargs),			"osf_old_killpg"	}, /*not implemented */
+[147] = { 0,	0,		SEN(setsid),			"setsid"		},
+[148] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[149] = { 5,	0,		SEN(printargs),			"osf_oldquota"		}, /*not implemented */
+[150] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[151 ... 152] = { },
+[153] = { 5,	0,		SEN(printargs),			"osf_pid_block"		}, /*not implemented */
+[154] = { 5,	0,		SEN(printargs),			"osf_pid_unblock"	}, /*not implemented */
+[155] = { },
+[156] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[157] = { 5,	0,		SEN(printargs),			"osf_sigwaitprim"	}, /*not implemented */
+[158] = { 5,	0,		SEN(printargs),			"osf_nfssvc"		}, /*not implemented */
+[159] = { 4,	0,		SEN(printargs),			"osf_getdirentries"	},
+[160] = { 3,	0,		SEN(osf_statfs),		"osf_statfs"		},
+[161] = { 3,	0,		SEN(osf_fstatfs),		"osf_fstatfs"		},
+[162] = { },
+[163] = { 5,	0,		SEN(printargs),			"osf_asynch_daemon"	}, /*not implemented */
+[164] = { 5,	0,		SEN(printargs),			"osf_getfh"		}, /*not implemented */
+[165] = { 2,	0,		SEN(printargs),			"osf_getdomainname"	},
+[166] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[167 ... 168] = { },
+[169] = { 5,	0,		SEN(printargs),			"osf_exportfs"		}, /*not implemented */
+[170 ... 180] = { },
+[181] = { 5,	0,		SEN(printargs),			"osf_alt_plock"		}, /*not implemented */
+[182 ... 183] = { },
+[184] = { 5,	0,		SEN(printargs),			"osf_getmnt"		}, /*not implemented */
+[185 ... 186] = { },
+[187] = { 5,	0,		SEN(printargs),			"osf_alt_sigpending"	}, /*not implemented */
+[188] = { 5,	0,		SEN(printargs),			"osf_alt_setsid"	}, /*not implemented */
+[189 ... 198] = { },
+[199] = { 4,	0,		SEN(printargs),			"osf_swapon"		},
+[200] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[201] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[202] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[203] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[204] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[205] = { 3,	TI,		SEN(semget),			"semget"		},
+[206] = { 3,	TI,		SEN(semop),			"semop"			},
+[207] = { 1,	0,		SEN(printargs),			"osf_utsname"		},
+[208] = { 3,	TF,		SEN(chown),			"lchown"		},
+[209] = { 3,	TI|TM|SI,	SEN(shmat),			"osf_shmat"		},
+[210] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[211] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[212] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[213] = { 5,	0,		SEN(printargs),			"osf_mvalid"		}, /*not implemented */
+[214] = { 5,	0,		SEN(printargs),			"osf_getaddressconf"	}, /*not implemented */
+[215] = { 5,	0,		SEN(printargs),			"osf_msleep"		}, /*not implemented */
+[216] = { 5,	0,		SEN(printargs),			"osf_mwakeup"		}, /*not implemented */
+[217] = { 3,	TM,		SEN(msync),			"msync"			},
+[218] = { 5,	0,		SEN(printargs),			"osf_signal"		}, /*not implemented */
+[219] = { 5,	0,		SEN(printargs),			"osf_utc_gettime"	}, /*not implemented */
+[220] = { 5,	0,		SEN(printargs),			"osf_utc_adjtime"	}, /*not implemented */
+[221] = { },
+[222] = { 5,	0,		SEN(printargs),			"osf_security"		}, /*not implemented */
+[223] = { 5,	0,		SEN(printargs),			"osf_kloadcall"		}, /*not implemented */
+[224] = { 5,	0,		SEN(printargs),			"osf_stat"		}, /*not implemented */
+[225] = { 5,	0,		SEN(printargs),			"osf_lstat"		}, /*not implemented */
+[226] = { 5,	0,		SEN(printargs),			"osf_fstat"		}, /*not implemented */
+[227] = { 3,	0,		SEN(osf_statfs),		"osf_statfs64"		}, /*not implemented */
+[228] = { 3,	0,		SEN(osf_fstatfs),		"osf_fstatfs64"		}, /*not implemented */
+[229 ... 232] = { },
+[233] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[234] = { 1,	0,		SEN(getsid),			"getsid"		},
+[235] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[236] = { 5,	0,		SEN(printargs),			"osf_waitid"		}, /*not implemented */
+[237] = { 5,	0,		SEN(printargs),			"osf_priocntlset"	}, /*not implemented */
+[238] = { 5,	0,		SEN(printargs),			"osf_sigsendset"	}, /*not implemented */
+[239] = { 5,	0,		SEN(printargs),			"osf_set_speculative"	}, /*not implemented */
+[240] = { 5,	0,		SEN(printargs),			"osf_msfs_syscall"	}, /*not implemented */
+[241] = { 5,	0,		SEN(printargs),			"osf_sysinfo"		},
+[242] = { 5,	0,		SEN(printargs),			"osf_uadmin"		}, /*not implemented */
+[243] = { 5,	0,		SEN(printargs),			"osf_fuser"		}, /*not implemented */
+[244] = { 2,	0,		SEN(printargs),			"osf_proplist_syscall"	},
+[245] = { 5,	0,		SEN(printargs),			"osf_ntp_adjtime"	}, /*not implemented */
+[246] = { 5,	0,		SEN(printargs),			"osf_ntp_gettime"	}, /*not implemented */
+[247] = { 5,	0,		SEN(printargs),			"osf_pathconf"		}, /*not implemented */
+[248] = { 5,	0,		SEN(printargs),			"osf_fpathconf"		}, /*not implemented */
+[249] = { },
+[250] = { 5,	0,		SEN(printargs),			"osf_uswitch"		}, /*not implemented */
+[251] = { 2,	0,		SEN(printargs),			"osf_usleep_thread"	},
+[252] = { 5,	0,		SEN(printargs),			"osf_audcntl"		}, /*not implemented */
+[253] = { 5,	0,		SEN(printargs),			"osf_audgen"		}, /*not implemented */
+[254] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[255] = { 5,	0,		SEN(printargs),			"osf_subsys_info"	}, /*not implemented */
+[256] = { 5,	0,		SEN(printargs),			"osf_getsysinfo"	},
+[257] = { 5,	0,		SEN(printargs),			"osf_setsysinfo"	},
+[258] = { 5,	0,		SEN(printargs),			"osf_afs_syscall"	}, /*not implemented */
+[259] = { 5,	0,		SEN(printargs),			"osf_swapctl"		}, /*not implemented */
+[260] = { 5,	0,		SEN(printargs),			"osf_memcntl"		}, /*not implemented */
+[261] = { 5,	0,		SEN(printargs),			"osf_fdatasync"		}, /*not implemented */
+[262 ... 299] = { },
+[300] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[301] = { 3,	0,		SEN(printargs),			"sethae"		},
+[302] = { 5,	TF,		SEN(mount),			"mount"			},
+[303] = { 1,	0,		SEN(adjtimex),			"old_adjtimex"		},
+[304] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[305] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[306] = { 2,	0,		SEN(create_module),		"create_module"		},
+[307] = { 3,	0,		SEN(init_module),		"init_module"		},
+[308] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[309] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[310] = { 3,	0,		SEN(syslog),			"syslog"		},
+[311] = { 4,	0,		SEN(reboot),			"reboot"		},
+[312] = { 5,	TP,		SEN(clone),			"clone"			},
+[313] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[314] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[315] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[316] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[317] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[318] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[319] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[320] = { },
+[321] = { 1,	TF,		SEN(umount),			"oldumount"		},
+[322] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[323] = { 1,	0,		SEN(times),			"times"			},
+[324] = { 1,	NF,		SEN(personality),		"personality"		},
+[325] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[326] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[327] = { 2,	0,		SEN(ustat),			"ustat"			},
+[328] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[329] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[330] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[331] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[332] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[333] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[334] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[335] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[336] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[337] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[338] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[339] = { 1,	0,		SEN(uname),			"uname"			},
+[340] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[341] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[342] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[343] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[344] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[345] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[346] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[347] = { 5,	0,		SEN(query_module),		"query_module"		},
+[348] = { 5,	0,		SEN(prctl),			"prctl"			},
+[349] = { 4,	TD,		SEN(pread),			"pread64"		},
+[350] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[351] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[352] = { 5,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[353] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[354] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[355] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[356] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[357] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[358] = { 5,	TD,		SEN(select),			"select"		},
+[359] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[360] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[361] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[362] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[363] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[364] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[365] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[366] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[367] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[368] = { 2,	0,		SEN(capget),			"capget"		},
+[369] = { 2,	0,		SEN(capset),			"capset"		},
+[370] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[371] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[372] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[373] = { 4,	0,		SEN(printargs),			"dipc"			}, /*not implemented */
+[374] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[375] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[376] = { 3,	0,		SEN(printargs),			"pciconfig_iobase"	},
+[377] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[378] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[379] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[380] = { },
+[381] = { 2,	TS,		SEN(kill),			"tkill"			},
+[382] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[383] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[384] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[385] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[386] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[387] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[388] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[389] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[390] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[391] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[392] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[393] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[394] = { 6,	0,		SEN(futex),			"futex"			},
+[395] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[396] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[397] = { 5,	0,		SEN(tuxcall),			"tuxcall"		},
+[398] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[399] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[400] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[401] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[402] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[403 ... 404] = { },
+[405] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[406] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[407] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[408] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[409] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[410] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[411] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[412] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[413] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[414] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[415] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[416] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[417] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[418] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[419] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[420] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[421] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[422] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[423] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[424] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[425] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[426] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[427] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[428] = { 5,	0,		SEN(vserver),			"vserver"		},
+[429] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[430] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[431] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[432] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[433] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[434] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[435] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[436] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[437] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[438] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[439] = { 5,	0,		SEN(add_key),			"add_key"		},
+[440] = { 4,	0,		SEN(request_key),		"request_key"		},
+[441] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[442] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[443] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[444] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[445] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[446] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[447] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[448] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[449] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[450] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[451] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[452] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[453] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[454] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[455] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[456] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[457] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[458] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[459] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[460] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[461] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[462] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[463] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[464] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[465] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[466] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[467] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[468] = { 6,	TD,		SEN(splice),			"splice"		},
+[469] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[470] = { 4,	TD,		SEN(tee),			"tee"			},
+[471] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[472] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[473] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[474] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[475] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[476] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[477] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[478] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[479] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[480] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[481] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[482] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[483] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[484] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[485] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[486] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[487] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[488] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[489] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[490] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[491] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[492] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[493] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[494] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[495] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[496] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[497] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[498] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[499] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[500] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[501] = { 2,	TD,		SEN(setns),			"setns"			},
+[502] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[503] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[504] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[505] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[506] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[507] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[508] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[509] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[510] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[511] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[512] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[513] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
diff --git a/strace/linux/alpha/userent.h b/strace/linux/alpha/userent.h
new file mode 100644
index 0000000..3a043b5
--- /dev/null
+++ b/strace/linux/alpha/userent.h
@@ -0,0 +1,67 @@
+{ 0,			"r0" },
+{ 1,			"r1" },
+{ 2,			"r2" },
+{ 3,			"r3" },
+{ 4,			"r4" },
+{ 5,			"r5" },
+{ 6,			"r6" },
+{ 7,			"r7" },
+{ 8,			"r8" },
+{ 9,			"r9" },
+{ 10,			"r10" },
+{ 11,			"r11" },
+{ 12,			"r12" },
+{ 13,			"r13" },
+{ 14,			"r14" },
+{ 15,			"r15" },
+{ 16,			"r16" },
+{ 17,			"r17" },
+{ 18,			"r18" },
+{ 19,			"r19" },
+{ 20,			"r20" },
+{ 21,			"r21" },
+{ 22,			"r22" },
+{ 23,			"r23" },
+{ 24,			"r24" },
+{ 25,			"r25" },
+{ 26,			"r26" },
+{ 27,			"r27" },
+{ 28,			"r28" },
+{ 29,			"gp" },
+{ 30,			"fp" },
+{ 31,			"zero" },
+{ 32,			"fp0" },
+{ 33,			"fp" },
+{ 34,			"fp2" },
+{ 35,			"fp3" },
+{ 36,			"fp4" },
+{ 37,			"fp5" },
+{ 38,			"fp6" },
+{ 39,			"fp7" },
+{ 40,			"fp8" },
+{ 41,			"fp9" },
+{ 42,			"fp10" },
+{ 43,			"fp11" },
+{ 44,			"fp12" },
+{ 45,			"fp13" },
+{ 46,			"fp14" },
+{ 47,			"fp15" },
+{ 48,			"fp16" },
+{ 49,			"fp17" },
+{ 50,			"fp18" },
+{ 51,			"fp19" },
+{ 52,			"fp20" },
+{ 53,			"fp21" },
+{ 54,			"fp22" },
+{ 55,			"fp23" },
+{ 56,			"fp24" },
+{ 57,			"fp25" },
+{ 58,			"fp26" },
+{ 59,			"fp27" },
+{ 60,			"fp28" },
+{ 61,			"fp29" },
+{ 62,			"fp30" },
+{ 63,			"fp31" },
+{ 64,			"pc" },
+/* Other fields in "struct user" */
+#include "../userent0.h"
diff --git a/strace/linux/arc/arch_regs.c b/strace/linux/arc/arch_regs.c
new file mode 100644
index 0000000..1846008
--- /dev/null
+++ b/strace/linux/arc/arch_regs.c
@@ -0,0 +1,3 @@
+static struct user_regs_struct arc_regs;
+#define ARCH_REGS_FOR_GETREGSET arc_regs
+#define ARCH_PC_REG arc_regs.efa
diff --git a/strace/linux/arc/get_error.c b/strace/linux/arc/get_error.c
new file mode 100644
index 0000000..e19debc
--- /dev/null
+++ b/strace/linux/arc/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(arc_regs.scratch.r0)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -arc_regs.scratch.r0;
+	} else {
+		tcp->u_rval = arc_regs.scratch.r0;
+	}
+}
diff --git a/strace/linux/arc/get_scno.c b/strace/linux/arc/get_scno.c
new file mode 100644
index 0000000..d2046b2
--- /dev/null
+++ b/strace/linux/arc/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = arc_regs.scratch.r8;
+	return 1;
+}
diff --git a/strace/linux/arc/get_syscall_args.c b/strace/linux/arc/get_syscall_args.c
new file mode 100644
index 0000000..4d6ace5
--- /dev/null
+++ b/strace/linux/arc/get_syscall_args.c
@@ -0,0 +1,11 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	long *arc_args = &arc_regs.scratch.r0;
+	unsigned int i;
+
+	for (i = 0; i < MAX_ARGS; ++i)
+		tcp->u_arg[i] = *arc_args--;
+	return 1;
+}
diff --git a/strace/linux/arc/ioctls_arch0.h b/strace/linux/arc/ioctls_arch0.h
new file mode 100644
index 0000000..2103d5b
--- /dev/null
+++ b/strace/linux/arc/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/arc/include/ tree. */
diff --git a/strace/linux/arc/ioctls_inc0.h b/strace/linux/arc/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/arc/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/arc/syscallent.h b/strace/linux/arc/syscallent.h
new file mode 100644
index 0000000..c2db91a
--- /dev/null
+++ b/strace/linux/arc/syscallent.h
@@ -0,0 +1,6 @@
+#define sys_ARCH_mmap sys_mmap_pgoff
+#include "32/syscallent.h"
+/* [244 ... 259] are arch specific */
+[244] = { 3,	0,	SEN(printargs),	"arc_cacheflush"},
+[245] = { 1,	0,	SEN(printargs),	"arc_settls"	},
+[246] = { 0,	0,	SEN(printargs),	"arc_gettls"	},
diff --git a/strace/linux/arch_regs.h b/strace/linux/arch_regs.h
new file mode 100644
index 0000000..da84fa5
--- /dev/null
+++ b/strace/linux/arch_regs.h
@@ -0,0 +1 @@
+/* nothing */
diff --git a/strace/linux/arch_sigreturn.c b/strace/linux/arch_sigreturn.c
new file mode 100644
index 0000000..73a2b10
--- /dev/null
+++ b/strace/linux/arch_sigreturn.c
@@ -0,0 +1,6 @@
+#warning sigreturn/rt_sigreturn signal mask decoding is not implemented for this architecture
+
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+}
diff --git a/strace/linux/arm/arch_regs.c b/strace/linux/arm/arch_regs.c
new file mode 100644
index 0000000..f5c02f0
--- /dev/null
+++ b/strace/linux/arm/arch_regs.c
@@ -0,0 +1,5 @@
+static struct pt_regs arm_regs;
+long *const arm_sp_ptr = &arm_regs.ARM_sp;
+
+#define ARCH_REGS_FOR_GETREGS arm_regs
+#define ARCH_PC_REG arm_regs.ARM_pc
diff --git a/strace/linux/arm/arch_regs.h b/strace/linux/arm/arch_regs.h
new file mode 100644
index 0000000..bdbc8e9
--- /dev/null
+++ b/strace/linux/arm/arch_regs.h
@@ -0,0 +1 @@
+extern long *const arm_sp_ptr;
diff --git a/strace/linux/arm/arch_sigreturn.c b/strace/linux/arm/arch_sigreturn.c
new file mode 100644
index 0000000..28726a2
--- /dev/null
+++ b/strace/linux/arm/arch_sigreturn.c
@@ -0,0 +1,19 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+#define SIZEOF_STRUCT_SIGINFO 128
+#define SIZEOF_STRUCT_SIGCONTEXT (21 * 4)
+#define OFFSETOF_STRUCT_UCONTEXT_UC_SIGMASK (5 * 4 + SIZEOF_STRUCT_SIGCONTEXT)
+
+	const long addr =
+#ifdef AARCH64
+		tcp->currpers == 0 ?
+			(*aarch64_sp_ptr + SIZEOF_STRUCT_SIGINFO +
+			 offsetof(struct ucontext, uc_sigmask)) :
+#endif
+			(*arm_sp_ptr +
+			 OFFSETOF_STRUCT_UCONTEXT_UC_SIGMASK);
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/arm/get_error.c b/strace/linux/arm/get_error.c
new file mode 100644
index 0000000..fa81dd7
--- /dev/null
+++ b/strace/linux/arm/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(arm_regs.ARM_r0)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -arm_regs.ARM_r0;
+	} else {
+		tcp->u_rval = arm_regs.ARM_r0;
+	}
+}
diff --git a/strace/linux/arm/get_scno.c b/strace/linux/arm/get_scno.c
new file mode 100644
index 0000000..23a167c
--- /dev/null
+++ b/strace/linux/arm/get_scno.c
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2003 Russell King <rmk@arm.linux.org.uk>
+ * Copyright (c) 2011-2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2011-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	long scno = 0;
+
+	/* Note: we support only 32-bit CPUs, not 26-bit */
+
+#if !defined(__ARM_EABI__) || ENABLE_ARM_OABI
+	if (arm_regs.ARM_cpsr & 0x20) {
+		/* Thumb mode */
+		goto scno_in_r7;
+	}
+	/* ARM mode */
+	/* Check EABI/OABI by examining SVC insn's low 24 bits */
+	errno = 0;
+	scno = ptrace(PTRACE_PEEKTEXT, tcp->pid, (void *)(arm_regs.ARM_pc - 4), NULL);
+	if (errno)
+		return -1;
+	/* EABI syscall convention? */
+	if ((unsigned long) scno != 0xef000000) {
+		/* No, it's OABI */
+		if ((scno & 0x0ff00000) != 0x0f900000) {
+			error_msg("pid %d unknown syscall trap 0x%08lx",
+				tcp->pid, scno);
+			return -1;
+		}
+		/* Fixup the syscall number */
+		scno &= 0x000fffff;
+	} else {
+	scno_in_r7:
+		scno = arm_regs.ARM_r7;
+	}
+#else /* __ARM_EABI__ || !ENABLE_ARM_OABI */
+
+	scno = arm_regs.ARM_r7;
+
+#endif
+
+	scno = shuffle_scno(scno);
+
+	/*
+	 * Do some sanity checks to figure out
+	 * whether it's really a syscall entry.
+	 */
+	if (arm_regs.ARM_ip && !SCNO_IN_RANGE(scno)) {
+		if (debug_flag)
+			error_msg("pid %d stray syscall exit:"
+				  " ARM_ip = %ld, scno = %ld",
+				  tcp->pid, arm_regs.ARM_ip,
+				  shuffle_scno(scno));
+		return 0;
+	}
+
+	tcp->scno = scno;
+	return 1;
+}
diff --git a/strace/linux/arm/get_syscall_args.c b/strace/linux/arm/get_syscall_args.c
new file mode 100644
index 0000000..6be1750
--- /dev/null
+++ b/strace/linux/arm/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = arm_regs.uregs[0];
+	tcp->u_arg[1] = arm_regs.uregs[1];
+	tcp->u_arg[2] = arm_regs.uregs[2];
+	tcp->u_arg[3] = arm_regs.uregs[3];
+	tcp->u_arg[4] = arm_regs.uregs[4];
+	tcp->u_arg[5] = arm_regs.uregs[5];
+	return 1;
+}
diff --git a/strace/linux/arm/ioctls_arch0.h b/strace/linux/arm/ioctls_arch0.h
new file mode 100644
index 0000000..f3cce0f
--- /dev/null
+++ b/strace/linux/arm/ioctls_arch0.h
@@ -0,0 +1,2 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/arm/include/ tree. */
+{ "asm/ioctls.h", "FIOQSIZE", 0, 0x545E, 0 },
diff --git a/strace/linux/arm/ioctls_inc0.h b/strace/linux/arm/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/arm/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/arm/syscallent.h b/strace/linux/arm/syscallent.h
new file mode 100644
index 0000000..18910e4
--- /dev/null
+++ b/strace/linux/arm/syscallent.h
@@ -0,0 +1,447 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 1,	TD|TM|SI,	SEN(old_mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 5,	0,		SEN(printargs),			"syscall"		},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 3,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { 5,	0,		SEN(vm86),			"vm86"			},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 6,	TD,		SEN(pread),			"pread64"		},
+[181] = { 6,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"chown"			},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[193] = { 4,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 4,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(geteuid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"chown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[218] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[219] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[220] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[221] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[222 ... 223] = { },
+[224] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[225] = { 5,	TD,		SEN(readahead),			"readahead"		},
+[226] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[227] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[228] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[229] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[230] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[231] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[232] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[233] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[234] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[235] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[236] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[237] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[238] = { 2,	TS,		SEN(kill),			"tkill"			},
+[239] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[240] = { 6,	0,		SEN(futex),			"futex"			},
+[241] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[242] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[243] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[244] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[245] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[246] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[247] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[248] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[249] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[250] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[251] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[252] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[253] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[254 ... 255] = { },
+[256] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[257] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[258] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[259] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[260] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[261] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[262] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[263] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[264] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[265] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[266] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[267] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[268] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[269] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[270] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[271] = { 3,	0,		SEN(printargs),			"pciconfig_iobase"	},
+[272] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[273] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[274] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[275] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[276] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[277] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[278] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[279] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[280] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[281] = { 3,	TN,		SEN(socket),			"socket"		},
+[282] = { 3,	TN,		SEN(bind),			"bind"			},
+[283] = { 3,	TN,		SEN(connect),			"connect"		},
+[284] = { 2,	TN,		SEN(listen),			"listen"		},
+[285] = { 3,	TN,		SEN(accept),			"accept"		},
+[286] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[287] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[288] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[289] = { 4,	TN,		SEN(send),			"send"			},
+[290] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[291] = { 4,	TN,		SEN(recv),			"recv"			},
+[292] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[293] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[294] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[295] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[296] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[297] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[298] = { 3,	TI,		SEN(semop),			"semop"			},
+[299] = { 3,	TI,		SEN(semget),			"semget"		},
+[300] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[301] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[302] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[303] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[304] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[305] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[306] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[307] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[308] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[309] = { 5,	0,		SEN(add_key),			"add_key"		},
+[310] = { 4,	0,		SEN(request_key),		"request_key"		},
+[311] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[312] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[313] = { 5,	0,		SEN(vserver),			"vserver"		},
+[314] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[315] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[316] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[317] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[318] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[319] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[320] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[321] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[322] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[323] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[324] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[325] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[326] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[327] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[328] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[329] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[330] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[331] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[332] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[333] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[334] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[335] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[336] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[337] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[338] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[339] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[340] = { 6,	TD,		SEN(splice),			"splice"		},
+[341] = { 6,	TD,		SEN(sync_file_range2),		"sync_file_range2"	},
+[342] = { 4,	TD,		SEN(tee),			"tee"			},
+[343] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[344] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[345] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[346] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[347] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[348] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[349] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[350] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[351] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[352] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[353] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[354] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[355] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[356] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[357] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[358] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[359] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[360] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[361] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[362] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[363] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[364] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[365] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[366] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[367] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[368] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[369] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[370] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[371] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[372] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[373] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[374] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[375] = { 2,	TD,		SEN(setns),			"setns"			},
+[376] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[377] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[378] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[379] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[380] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[381] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[382] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[383] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[384] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[385] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[386] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[387] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[388] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[389] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[390] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[391] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[392] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[393] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#ifdef __ARM_EABI__
+# define ARM_FIRST_SHUFFLED_SYSCALL 400
+#else
+# define SYS_socket_subcall	400
+# include "subcall.h"
+# define ARM_FIRST_SHUFFLED_SYSCALL (SYS_ipc_subcall + SYS_ipc_nsubcalls)
+#endif /* !__ARM_EABI__ */
+
+/*
+ * __ARM_NR_cmpxchg (0x000ffff0).
+ * Remapped by shuffle_scno() to be directly after ordinary syscalls
+ * in this table.
+ */
+[ARM_FIRST_SHUFFLED_SYSCALL    ] = { 5,	0,	SEN(printargs),	"cmpxchg"		},
+
+/*
+ * ARM specific syscalls. Encoded with scno 0x000f00xx.
+ * Remapped by shuffle_scno() to be directly after __ARM_NR_cmpxchg.
+ */
+[ARM_FIRST_SHUFFLED_SYSCALL+1+0] = { },
+[ARM_FIRST_SHUFFLED_SYSCALL+1+1] = { 5,	0,	SEN(printargs),	"breakpoint"		},
+[ARM_FIRST_SHUFFLED_SYSCALL+1+2] = { 5,	0,	SEN(printargs),	"cacheflush"		},
+[ARM_FIRST_SHUFFLED_SYSCALL+1+3] = { 5,	0,	SEN(printargs),	"usr26"			},
+[ARM_FIRST_SHUFFLED_SYSCALL+1+4] = { 5,	0,	SEN(printargs),	"usr32"			},
+[ARM_FIRST_SHUFFLED_SYSCALL+1+5] = { 5,	0,	SEN(printargs),	"set_tls"		},
+#define ARM_LAST_SPECIAL_SYSCALL 5
diff --git a/strace/linux/arm/userent.h b/strace/linux/arm/userent.h
new file mode 100644
index 0000000..bd36a6f
--- /dev/null
+++ b/strace/linux/arm/userent.h
@@ -0,0 +1,30 @@
+{ uoff(regs.ARM_r0),	"r0" },
+{ uoff(regs.ARM_r1),	"r1" },
+{ uoff(regs.ARM_r2),	"r2" },
+{ uoff(regs.ARM_r3),	"r3" },
+{ uoff(regs.ARM_r4),	"r4" },
+{ uoff(regs.ARM_r5),	"r5" },
+{ uoff(regs.ARM_r6),	"r6" },
+{ uoff(regs.ARM_r7),	"r7" },
+{ uoff(regs.ARM_r8),	"r8" },
+{ uoff(regs.ARM_r9),	"r9" },
+{ uoff(regs.ARM_r10),	"r10" },
+{ uoff(regs.ARM_fp),	"fp" },
+{ uoff(regs.ARM_ip),	"ip" },
+{ uoff(regs.ARM_sp),	"sp" },
+{ uoff(regs.ARM_lr),	"lr" },
+{ uoff(regs.ARM_pc),	"pc" },
+{ uoff(regs.ARM_cpsr),	"cpsr" },
+/* Other fields in "struct user" */
+XLAT_UOFF(u_fpvalid),
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(reserved),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/asm_stat.h b/strace/linux/asm_stat.h
new file mode 100644
index 0000000..c941f22
--- /dev/null
+++ b/strace/linux/asm_stat.h
@@ -0,0 +1,2 @@
+#include "kernel_types.h"
+#include <asm/stat.h>
diff --git a/strace/linux/avr32/arch_regs.c b/strace/linux/avr32/arch_regs.c
new file mode 100644
index 0000000..8b52a8d
--- /dev/null
+++ b/strace/linux/avr32/arch_regs.c
@@ -0,0 +1,3 @@
+static struct pt_regs avr32_regs;
+#define ARCH_REGS_FOR_GETREGS avr32_regs
+#define ARCH_PC_REG avr32_regs.pc
diff --git a/strace/linux/avr32/get_error.c b/strace/linux/avr32/get_error.c
new file mode 100644
index 0000000..75e7f67
--- /dev/null
+++ b/strace/linux/avr32/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(avr32_regs.r12)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -avr32_regs.r12;
+	} else {
+		tcp->u_rval = avr32_regs.r12;
+	}
+}
diff --git a/strace/linux/avr32/get_scno.c b/strace/linux/avr32/get_scno.c
new file mode 100644
index 0000000..092dad3
--- /dev/null
+++ b/strace/linux/avr32/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = avr32_regs.r8;
+	return 1;
+}
diff --git a/strace/linux/avr32/get_syscall_args.c b/strace/linux/avr32/get_syscall_args.c
new file mode 100644
index 0000000..e8c4119
--- /dev/null
+++ b/strace/linux/avr32/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = avr32_regs.r12;
+	tcp->u_arg[1] = avr32_regs.r11;
+	tcp->u_arg[2] = avr32_regs.r10;
+	tcp->u_arg[3] = avr32_regs.r9;
+	tcp->u_arg[4] = avr32_regs.r5;
+	tcp->u_arg[5] = avr32_regs.r3;
+	return 1;
+}
diff --git a/strace/linux/avr32/ioctls_arch0.h b/strace/linux/avr32/ioctls_arch0.h
new file mode 100644
index 0000000..c50a25c
--- /dev/null
+++ b/strace/linux/avr32/ioctls_arch0.h
@@ -0,0 +1,8 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/avr32/include/ tree. */
+{ "asm/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
diff --git a/strace/linux/avr32/ioctls_inc0.h b/strace/linux/avr32/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/avr32/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/avr32/syscallent.h b/strace/linux/avr32/syscallent.h
new file mode 100644
index 0000000..0b4ceac
--- /dev/null
+++ b/strace/linux/avr32/syscallent.h
@@ -0,0 +1,353 @@
+/*
+ * Copyright (c) 2004-2009 Atmel Corporation
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 1,	NF,		SEN(umask),			"umask"			},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown),			"chown"			},
+[ 17] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 18] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 19] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount2),			"umount2"		},
+[ 23] = { 1,	0,		SEN(setuid),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 29] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 30] = { 2,	TF,		SEN(stat),			"stat"			},
+[ 31] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 32] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 35] = { 0,	0,		SEN(sync),			"sync"			},
+[ 36] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 5,	TP,		SEN(clone),			"clone"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[ 48] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[ 49] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[ 53] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 57] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[ 58] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[ 59] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[ 60] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[ 61] = { 2,	0,		SEN(setregid),			"setregid"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[ 68] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[ 69] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[ 70] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[ 71] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[ 72] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[ 73] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[ 82] = { 5,	TD,		SEN(select),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 5,	TD,		SEN(pread),			"pread"			},
+[ 87] = { 5,	TD,		SEN(pwrite),			"pwrite"		},
+[ 88] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 89] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[102] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[107] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[108] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[109] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[110] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[111] = { 1,	0,		SEN(uname),			"uname"			},
+[112] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[113] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[114] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[115] = { 3,	0,		SEN(init_module),		"init_module"		},
+[116] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[117] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[118] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[119] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[120] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[121] = { 1,	NF,		SEN(personality),		"personality"		},
+[122] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[123] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[124] = { 2,	TD,		SEN(flock),			"flock"			},
+[125] = { 3,	TM,		SEN(msync),			"msync"			},
+[126] = { 3,	TD,		SEN(readv),			"readv"			},
+[127] = { 3,	TD,		SEN(writev),			"writev"		},
+[128] = { 1,	0,		SEN(getsid),			"getsid"		},
+[129] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[130] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[131] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[132] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[133] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[134] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[135] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[136] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[137] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[138] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[139] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[140] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[141] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[142] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[143] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[144] = { 3,	TD,		SEN(poll),			"poll"			},
+[145] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[146] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[147] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[148] = { 5,	0,		SEN(prctl),			"prctl"			},
+[149] = { 3,	TN,		SEN(socket),			"socket"		},
+[150] = { 3,	TN,		SEN(bind),			"bind"			},
+[151] = { 3,	TN,		SEN(connect),			"connect"		},
+[152] = { 2,	TN,		SEN(listen),			"listen"		},
+[153] = { 3,	TN,		SEN(accept),			"accept"		},
+[154] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[155] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[156] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[157] = { 4,	TN,		SEN(send),			"send"			},
+[158] = { 4,	TN,		SEN(recv),			"recv"			},
+[159] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[160] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[161] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[162] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[163] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[164] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[165] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[166] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[167] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[168] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[169] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[170] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[171] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[172] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[173] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[174] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[175] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[176] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[177] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[178] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[179] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[180] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[181] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[182] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[183] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[184] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[185] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[186] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[187] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[188] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[189] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[190] = { 2,	TS,		SEN(kill),			"tkill"			},
+[191] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[192] = { 6,	0,		SEN(futex),			"futex"			},
+[193] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[194] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[195] = { 2,	0,		SEN(capget),			"capget"		},
+[196] = { 2,	0,		SEN(capset),			"capset"		},
+[197] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[198] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[199] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[200] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[201] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[202] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[203] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[204] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[205] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[206] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[207] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[208] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[209] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[210] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[211] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[212] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[213] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[214] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[215] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[216] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[217] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[218] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[219] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[220] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[221] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[222] = { },
+[223] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[224] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[225] = { 3,	0,		SEN(printargs),			"cacheflush"		},
+[226] = { 5,	0,		SEN(vserver),			"vserver"		},
+[227] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[228] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[229] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[230] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[231] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[232] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[233] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[234] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[235] = { 5,	0,		SEN(add_key),			"add_key"		},
+[236] = { 4,	0,		SEN(request_key),		"request_key"		},
+[237] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[238] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[239] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[240] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[241] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[242] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[243] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[244] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[245] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[246] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[247] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[248] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[249] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[250] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[251] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[252] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[253] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[254] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[255] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[256] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[257] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[258] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[259] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[260] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[261] = { 6,	TD,		SEN(splice),			"splice"		},
+[262] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[263] = { 4,	TD,		SEN(tee),			"tee"			},
+[264] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[265] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[266] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[267] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[268] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[269] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[270] = { 3,	TI,		SEN(semget),			"semget"		},
+[271] = { 3,	TI,		SEN(semop),			"semop"			},
+[272] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[273] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[274] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[275] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[276] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[277] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[278] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[279] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[280] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[281] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[282] = { },
+[283] = { 2,	TD,		SEN(setns),			"setns"			},
+[284] = { 5,	TD,		SEN(pread),			"pread64"		},
+[285] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[286] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[287] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[288] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[289] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[290] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[291] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[292] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[293] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[294] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[295] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[296] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[297] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[298] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[299] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[300] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[301] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[302] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[303] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[304] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[305] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[306] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[307] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[308] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[309] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[310] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[311] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[312] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[313] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[314] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[315] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[316] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[317] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[318] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[319] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[320] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[321] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[322] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[323] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[324] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[325] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
diff --git a/strace/linux/avr32/userent.h b/strace/linux/avr32/userent.h
new file mode 100644
index 0000000..4fbfc14
--- /dev/null
+++ b/strace/linux/avr32/userent.h
@@ -0,0 +1,30 @@
+{ uoff(regs.sr),	"sr" },
+{ uoff(regs.pc),	"pc" },
+{ uoff(regs.lr),	"lr" },
+{ uoff(regs.sp),	"sp" },
+{ uoff(regs.r12),	"r12" },
+{ uoff(regs.r11),	"r11" },
+{ uoff(regs.r10),	"r10" },
+{ uoff(regs.r9),	"r9" },
+{ uoff(regs.r8),	"r8" },
+{ uoff(regs.r7),	"r7" },
+{ uoff(regs.r6),	"r6" },
+{ uoff(regs.r5),	"r5" },
+{ uoff(regs.r4),	"r4" },
+{ uoff(regs.r3),	"r3" },
+{ uoff(regs.r2),	"r2" },
+{ uoff(regs.r1),	"r1" },
+{ uoff(regs.r0),	"r0" },
+{ uoff(regs.r12_orig),	"orig_r12" },
+/* Other fields in "struct user" */
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(start_data),
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/bfin/arch_regs.c b/strace/linux/bfin/arch_regs.c
new file mode 100644
index 0000000..e1aa15e
--- /dev/null
+++ b/strace/linux/bfin/arch_regs.c
@@ -0,0 +1,2 @@
+static long bfin_r0;
+#define ARCH_PC_PEEK_ADDR PT_PC
diff --git a/strace/linux/bfin/get_error.c b/strace/linux/bfin/get_error.c
new file mode 100644
index 0000000..80aeb37
--- /dev/null
+++ b/strace/linux/bfin/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(bfin_r0)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -bfin_r0;
+	} else {
+		tcp->u_rval = bfin_r0;
+	}
+}
diff --git a/strace/linux/bfin/get_scno.c b/strace/linux/bfin/get_scno.c
new file mode 100644
index 0000000..8c3a7d2
--- /dev/null
+++ b/strace/linux/bfin/get_scno.c
@@ -0,0 +1,6 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	return upeek(tcp->pid, PT_ORIG_P0, &tcp->scno) < 0 ? -1 : 1;
+}
diff --git a/strace/linux/bfin/get_syscall_args.c b/strace/linux/bfin/get_syscall_args.c
new file mode 100644
index 0000000..13d58bd
--- /dev/null
+++ b/strace/linux/bfin/get_syscall_args.c
@@ -0,0 +1,13 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	static const int argreg[MAX_ARGS] =
+		{ PT_R0, PT_R1, PT_R2, PT_R3, PT_R4, PT_R5 };
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, argreg[i], &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/bfin/get_syscall_result.c b/strace/linux/bfin/get_syscall_result.c
new file mode 100644
index 0000000..c189a5f
--- /dev/null
+++ b/strace/linux/bfin/get_syscall_result.c
@@ -0,0 +1,5 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return upeek(tcp->pid, PT_R0, &bfin_r0) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/bfin/ioctls_arch0.h b/strace/linux/bfin/ioctls_arch0.h
new file mode 100644
index 0000000..7d9804d
--- /dev/null
+++ b/strace/linux/bfin/ioctls_arch0.h
@@ -0,0 +1,12 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/blackfin/include/ tree. */
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_READ", _IOC_NONE, 0x740a, 0x00 },
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_READ_COUNTER", _IOC_NONE, 0x740b, 0x00 },
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_SET_MODE", _IOC_NONE, 0x7404, 0x00 },
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_SET_PERIOD", _IOC_NONE, 0x7402, 0x00 },
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_SET_WIDTH", _IOC_NONE, 0x7403, 0x00 },
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_START", _IOC_NONE, 0x7406, 0x00 },
+{ "asm/bfin_simple_timer.h", "BFIN_SIMPLE_TIMER_STOP", _IOC_NONE, 0x7408, 0x00 },
+{ "asm/bfin_sport.h", "SPORT_IOC_CONFIG", _IOC_READ|_IOC_WRITE, 0x5001, 0x24 },
+{ "asm/bfin_sport.h", "SPORT_IOC_GET_SYSTEMCLOCK", _IOC_READ, 0x5002, 0x04 },
+{ "asm/bfin_sport.h", "SPORT_IOC_SET_BAUDRATE", _IOC_WRITE, 0x5003, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", 0, 0x545E, 0 },
diff --git a/strace/linux/bfin/ioctls_inc0.h b/strace/linux/bfin/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/bfin/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/bfin/syscallent.h b/strace/linux/bfin/syscallent.h
new file mode 100644
index 0000000..dd99fa6
--- /dev/null
+++ b/strace/linux/bfin/syscallent.h
@@ -0,0 +1,420 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"chown"			},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"old_getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(printargs),			"mmap"			}, /*not implemented in kernel */
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 1,	0,		SEN(vm86old),			"vm86old"		},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 3,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { 5,	0,		SEN(vm86),			"vm86"			},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 5,	TD,		SEN(pread),			"pread"			},
+[181] = { 5,	TD,		SEN(pwrite),			"pwrite"		},
+[182] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[193] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"chown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(geteuid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[222 ... 223] = { },
+[224] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[225] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[226] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[227] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[228] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[229] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[230] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[231] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[232] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[233] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[234] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[235] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[236] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[237] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[238] = { 2,	TS,		SEN(kill),			"tkill"			},
+[239] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[240] = { 6,	0,		SEN(futex),			"futex"			},
+[241] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[242] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[243] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[244] = { 1,	0,		SEN(get_thread_area),		"get_thread_area"	},
+[245] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[246] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[247] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[248] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[249] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[250] = { 5,	0,		SEN(printargs),			"alloc_hugepages"	},
+[251] = { 1,	0,		SEN(printargs),			"free_hugepages"	},
+[252] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[253] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[254] = { 1,	0,		SEN(printargs),			"bfin_spinlock"		},
+[255] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[256] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[257] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[258] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[259] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[260] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[261] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[262] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[263] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[264] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[265] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[266] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[267] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[268] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[269] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[270] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[271] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[272] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[273] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[274] = { 5,	0,		SEN(vserver),			"vserver"		},
+[275] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[276] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[277] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[278] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[279] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[280] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[281] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[282] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[283] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[284] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[285] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[286] = { 5,	0,		SEN(add_key),			"add_key"		},
+[287] = { 4,	0,		SEN(request_key),		"request_key"		},
+[288] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[289] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[290] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[291] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[292] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[293] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[294] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[295] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[296] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[297] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[298] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[299] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[300] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[301] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[302] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[303] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[304] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[305] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[306] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[307] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[308] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[309] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[310] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[311] = { 2,	0,		SEN(sram_alloc),		"sram_alloc"		},
+[312] = { 1,	0,		SEN(printargs),			"sram_free"		},
+[313] = { 3,	0,		SEN(printargs),			"dma_memcpy"		},
+[314] = { 3,	TN,		SEN(accept),			"accept"		},
+[315] = { 3,	TN,		SEN(bind),			"bind"			},
+[316] = { 3,	TN,		SEN(connect),			"connect"		},
+[317] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[318] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[319] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[320] = { 2,	TN,		SEN(listen),			"listen"		},
+[321] = { 4,	TN,		SEN(recv),			"recv"			},
+[322] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[323] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[324] = { 4,	TN,		SEN(send),			"send"			},
+[325] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[326] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[327] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[328] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[329] = { 3,	TN,		SEN(socket),			"socket"		},
+[330] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[331] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[332] = { 3,	TI,		SEN(semget),			"semget"		},
+[333] = { 3,	TI,		SEN(semop),			"semop"			},
+[334] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[335] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[336] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[337] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[338] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[339] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[340] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[341] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[342] = { 6,	TD,		SEN(splice),			"splice"		},
+[343] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[344] = { 4,	TD,		SEN(tee),			"tee"			},
+[345] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[346] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[347] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[348] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[349] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[350] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[351] = { 5,	TD,		SEN(pread),			"pread64"		},
+[352] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[353] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[354] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[355] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[356] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[357] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[358] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[359] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[360] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[361] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[362] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[363] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[364] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[365] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[366] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[367] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[368] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[369] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[370] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[371] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[372] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[373] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[374] = { 3,	0,		SEN(cacheflush),		"cacheflush"		},
+[375] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[376] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[377] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[378] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[379] = { 2,	TD,		SEN(setns),			"setns"			},
+[380] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[381] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[382] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[383] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[384] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[385] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[386] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[387] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[388] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[389] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[390] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[391] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[392] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
diff --git a/strace/linux/bfin/userent.h b/strace/linux/bfin/userent.h
new file mode 100644
index 0000000..f7a7ca6
--- /dev/null
+++ b/strace/linux/bfin/userent.h
@@ -0,0 +1,9 @@
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(signal),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/crisv10/arch_regs.c b/strace/linux/crisv10/arch_regs.c
new file mode 100644
index 0000000..8f69b87
--- /dev/null
+++ b/strace/linux/crisv10/arch_regs.c
@@ -0,0 +1,2 @@
+static long cris_r10;
+#define ARCH_PC_PEEK_ADDR (4 * PT_IRP)
diff --git a/strace/linux/crisv10/arch_sigreturn.c b/strace/linux/crisv10/arch_sigreturn.c
new file mode 100644
index 0000000..9086d53
--- /dev/null
+++ b/strace/linux/crisv10/arch_sigreturn.c
@@ -0,0 +1,15 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	long regs[PT_MAX + 1];
+
+	if (ptrace(PTRACE_GETREGS, tcp->pid, NULL, (long)regs) < 0) {
+		perror_msg("sigreturn: PTRACE_GETREGS");
+		return;
+	}
+	const long addr = regs[PT_USP] + offsetof(struct sigcontext, oldmask);
+
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/crisv10/get_error.c b/strace/linux/crisv10/get_error.c
new file mode 100644
index 0000000..b9da923
--- /dev/null
+++ b/strace/linux/crisv10/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(cris_r10)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -cris_r10;
+	} else {
+		tcp->u_rval = cris_r10;
+	}
+}
diff --git a/strace/linux/crisv10/get_scno.c b/strace/linux/crisv10/get_scno.c
new file mode 100644
index 0000000..14ff338
--- /dev/null
+++ b/strace/linux/crisv10/get_scno.c
@@ -0,0 +1,6 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	return upeek(tcp->pid, 4 * PT_R9, &tcp->scno) < 0 ? -1 : 1;
+}
diff --git a/strace/linux/crisv10/get_syscall_args.c b/strace/linux/crisv10/get_syscall_args.c
new file mode 100644
index 0000000..bdd0574
--- /dev/null
+++ b/strace/linux/crisv10/get_syscall_args.c
@@ -0,0 +1,15 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	static const int crisregs[MAX_ARGS] = {
+		4*PT_ORIG_R10, 4*PT_R11, 4*PT_R12,
+		4*PT_R13     , 4*PT_MOF, 4*PT_SRP
+	};
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, crisregs[i], &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/crisv10/get_syscall_result.c b/strace/linux/crisv10/get_syscall_result.c
new file mode 100644
index 0000000..6b3679c
--- /dev/null
+++ b/strace/linux/crisv10/get_syscall_result.c
@@ -0,0 +1,5 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return upeek(tcp->pid, 4 * PT_R10, &cris_r10) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/crisv10/userent.h b/strace/linux/crisv10/userent.h
new file mode 100644
index 0000000..bea16ae
--- /dev/null
+++ b/strace/linux/crisv10/userent.h
@@ -0,0 +1,26 @@
+XLAT(4*PT_FRAMETYPE),
+XLAT(4*PT_ORIG_R10),
+XLAT(4*PT_R13),
+XLAT(4*PT_R12),
+XLAT(4*PT_R11),
+XLAT(4*PT_R10),
+XLAT(4*PT_R9),
+XLAT(4*PT_R8),
+XLAT(4*PT_R7),
+XLAT(4*PT_R6),
+XLAT(4*PT_R5),
+XLAT(4*PT_R4),
+XLAT(4*PT_R3),
+XLAT(4*PT_R2),
+XLAT(4*PT_R1),
+XLAT(4*PT_R0),
+XLAT(4*PT_MOF),
+XLAT(4*PT_DCCR),
+XLAT(4*PT_SRP),
+XLAT(4*PT_IRP),
+XLAT(4*PT_CSRINSTR),
+XLAT(4*PT_CSRADDR),
+XLAT(4*PT_CSRDATA),
+XLAT(4*PT_USP),
+/* Other fields in "struct user" */
+#include "../userent0.h"
diff --git a/strace/linux/crisv32/arch_regs.c b/strace/linux/crisv32/arch_regs.c
new file mode 100644
index 0000000..8e59c15
--- /dev/null
+++ b/strace/linux/crisv32/arch_regs.c
@@ -0,0 +1,2 @@
+#include "crisv10/arch_regs.c"
+#define ARCH_PC_PEEK_ADDR (4 * PT_ERP)
diff --git a/strace/linux/crisv32/arch_sigreturn.c b/strace/linux/crisv32/arch_sigreturn.c
new file mode 100644
index 0000000..6c0fc03
--- /dev/null
+++ b/strace/linux/crisv32/arch_sigreturn.c
@@ -0,0 +1 @@
+#include "crisv10/arch_sigreturn.c"
diff --git a/strace/linux/crisv32/get_error.c b/strace/linux/crisv32/get_error.c
new file mode 100644
index 0000000..f7bb1e0
--- /dev/null
+++ b/strace/linux/crisv32/get_error.c
@@ -0,0 +1 @@
+#include "crisv10/get_error.c"
diff --git a/strace/linux/crisv32/get_scno.c b/strace/linux/crisv32/get_scno.c
new file mode 100644
index 0000000..edfd60f
--- /dev/null
+++ b/strace/linux/crisv32/get_scno.c
@@ -0,0 +1 @@
+#include "crisv10/get_scno.c"
diff --git a/strace/linux/crisv32/get_syscall_args.c b/strace/linux/crisv32/get_syscall_args.c
new file mode 100644
index 0000000..4d98465
--- /dev/null
+++ b/strace/linux/crisv32/get_syscall_args.c
@@ -0,0 +1 @@
+#include "crisv10/get_syscall_args.c"
diff --git a/strace/linux/crisv32/get_syscall_result.c b/strace/linux/crisv32/get_syscall_result.c
new file mode 100644
index 0000000..ebefdb2
--- /dev/null
+++ b/strace/linux/crisv32/get_syscall_result.c
@@ -0,0 +1 @@
+#include "crisv10/get_syscall_result.c"
diff --git a/strace/linux/crisv32/userent.h b/strace/linux/crisv32/userent.h
new file mode 100644
index 0000000..3c5949e
--- /dev/null
+++ b/strace/linux/crisv32/userent.h
@@ -0,0 +1,43 @@
+XLAT(4*PT_ORIG_R10),
+XLAT(4*PT_R0),
+XLAT(4*PT_R1),
+XLAT(4*PT_R2),
+XLAT(4*PT_R3),
+XLAT(4*PT_R4),
+XLAT(4*PT_R5),
+XLAT(4*PT_R6),
+XLAT(4*PT_R7),
+XLAT(4*PT_R8),
+XLAT(4*PT_R9),
+XLAT(4*PT_R10),
+XLAT(4*PT_R11),
+XLAT(4*PT_R12),
+XLAT(4*PT_R13),
+XLAT(4*PT_ACR),
+XLAT(4*PT_SRS),
+XLAT(4*PT_MOF),
+XLAT(4*PT_SPC),
+XLAT(4*PT_CCS),
+XLAT(4*PT_SRP),
+XLAT(4*PT_ERP),
+XLAT(4*PT_EXS),
+XLAT(4*PT_EDA),
+XLAT(4*PT_USP),
+XLAT(4*PT_PPC),
+XLAT(4*PT_BP_CTRL),
+XLAT(4*PT_BP+4),
+XLAT(4*PT_BP+8),
+XLAT(4*PT_BP+12),
+XLAT(4*PT_BP+16),
+XLAT(4*PT_BP+20),
+XLAT(4*PT_BP+24),
+XLAT(4*PT_BP+28),
+XLAT(4*PT_BP+32),
+XLAT(4*PT_BP+36),
+XLAT(4*PT_BP+40),
+XLAT(4*PT_BP+44),
+XLAT(4*PT_BP+48),
+XLAT(4*PT_BP+52),
+XLAT(4*PT_BP+56),
+/* Other fields in "struct user" */
+#include "../userent0.h"
diff --git a/strace/linux/dummy.h b/strace/linux/dummy.h
new file mode 100644
index 0000000..587163c
--- /dev/null
+++ b/strace/linux/dummy.h
@@ -0,0 +1,158 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+#ifndef HAVE_STRUCT___OLD_KERNEL_STAT
+#define	sys_oldfstat		printargs
+#define	sys_oldstat		printargs
+#endif
+
+/* still unfinished */
+#define	sys_vm86		printargs
+#define	sys_vm86old		printargs
+
+/* machine-specific */
+#if !(defined I386 || defined X86_64 || defined X32)
+# define	sys_modify_ldt		printargs
+# ifndef M68K
+#  define	sys_get_thread_area	printargs
+#  ifndef MIPS
+#   define	sys_set_thread_area	printargs
+#  endif
+# endif
+#endif
+#ifdef ALPHA
+# define	sys_getdtablesize	printargs
+#endif
+
+/* like another call */
+#define	sys_acct		sys_chdir
+#define	sys_chroot		sys_chdir
+#define	sys_clock_getres	sys_clock_gettime
+#define	sys_connect		sys_bind
+#define	sys_fchdir		sys_close
+#define	sys_fdatasync		sys_close
+#define	sys_fsync		sys_close
+#define	sys_getegid		sys_getuid
+#define	sys_getegid16		sys_geteuid16
+#define	sys_geteuid		sys_getuid
+#define	sys_geteuid16		sys_getuid16
+#define	sys_getgid		sys_getuid
+#define	sys_getgid16		sys_getuid16
+#define	sys_getpeername		sys_getsockname
+#define	sys_getresgid		sys_getresuid
+#define	sys_getresgid16		sys_getresuid16
+#define	sys_lstat		sys_stat
+#define	sys_lstat64		sys_stat64
+#define	sys_mkdir		sys_chmod
+#define	sys_mkdirat		sys_fchmodat
+#define	sys_mlock		sys_munmap
+#define	sys_mq_unlink		sys_chdir
+#define	sys_munlock		sys_munmap
+#define	sys_oldlstat		sys_oldstat
+#define	sys_pivotroot		sys_link
+#define	sys_rename		sys_link
+#define	sys_rmdir		sys_chdir
+#define	sys_sched_get_priority_max	sys_sched_get_priority_min
+#define	sys_set_robust_list	sys_munmap
+#define	sys_setdomainname	sys_sethostname
+#define	sys_setfsgid		sys_setfsuid
+#define	sys_setfsgid16		sys_setfsuid16
+#define	sys_setgid		sys_setuid
+#define	sys_setgid16		sys_setuid16
+#define	sys_setregid		sys_setreuid
+#define	sys_setregid16		sys_setreuid16
+#define	sys_setresgid		sys_setresuid
+#define	sys_setresgid16		sys_setresuid16
+#define	sys_stime		sys_time
+#define	sys_swapoff		sys_chdir
+#define	sys_symlink		sys_link
+#define	sys_syncfs		sys_close
+#define	sys_umount		sys_chdir
+#define	sys_unlink		sys_chdir
+#define	sys_uselib		sys_chdir
+#define	sys_vfork		sys_fork
+
+/* printargs does the right thing */
+#define	sys_getpgrp		printargs
+#define	sys_getpid		printargs
+#define	sys_getppid		printargs
+#define	sys_gettid		printargs
+#define	sys_idle		printargs
+#define	sys_inotify_init	printargs
+#define	sys_munlockall		printargs
+#define	sys_pause		printargs
+#define	sys_printargs		printargs
+#define	sys_rt_sigreturn	printargs
+#define	sys_sched_yield		printargs
+#define	sys_setsid		printargs
+#define	sys_set_tid_address	printargs
+#define	sys_setup		printargs
+#define	sys_sync		printargs
+#define	sys_syscall		printargs
+#define	sys_vhangup		printargs
+
+/* printargs_u does the right thing */
+#define	sys_alarm		printargs_u
+
+/* printargs_d does the right thing */
+#define	sys_getpgid		printargs_d
+#define	sys_getsid		printargs_d
+#define	sys_nice		printargs_d
+#define	sys_setpgid		printargs_d
+#define	sys_setpgrp		printargs_d
+#define	sys_timer_delete	printargs_d
+#define	sys_timer_getoverrun	printargs_d
+
+/* unimplemented */
+#define	sys_afs_syscall		printargs
+#define	sys_break		printargs
+#define	sys_ftime		printargs
+#define	sys_get_kernel_syms	printargs
+#define	sys_getpmsg		printargs
+#define	sys_gtty		printargs
+#define	sys_lock		printargs
+#define	sys_mpx			printargs
+#define	sys_nfsservctl		printargs
+#define	sys_phys		printargs
+#define	sys_prof		printargs
+#define	sys_profil		printargs
+#define	sys_putpmsg		printargs
+#define	sys_query_module	printargs
+#define	sys_security		printargs
+#define	sys_stty		printargs
+#define	sys_timerfd		printargs
+#define	sys_tuxcall		printargs
+#define	sys_ulimit		printargs
+#define	sys_ustat		printargs
+#define	sys_vserver		printargs
+
+/* deprecated */
+#define	sys_bdflush		printargs
+#define	sys_oldolduname		printargs
+#define	sys_olduname		printargs
+#define	sys_sysfs		printargs
diff --git a/strace/linux/errnoent.h b/strace/linux/errnoent.h
new file mode 100644
index 0000000..012f099
--- /dev/null
+++ b/strace/linux/errnoent.h
@@ -0,0 +1,147 @@
+[  1] = "EPERM",
+[  2] = "ENOENT",
+[  3] = "ESRCH",
+[  4] = "EINTR",
+[  5] = "EIO",
+[  6] = "ENXIO",
+[  7] = "E2BIG",
+[  8] = "ENOEXEC",
+[  9] = "EBADF",
+[ 10] = "ECHILD",
+[ 11] = "EAGAIN",
+[ 12] = "ENOMEM",
+[ 13] = "EACCES",
+[ 14] = "EFAULT",
+[ 15] = "ENOTBLK",
+[ 16] = "EBUSY",
+[ 17] = "EEXIST",
+[ 18] = "EXDEV",
+[ 19] = "ENODEV",
+[ 20] = "ENOTDIR",
+[ 21] = "EISDIR",
+[ 22] = "EINVAL",
+[ 23] = "ENFILE",
+[ 24] = "EMFILE",
+[ 25] = "ENOTTY",
+[ 26] = "ETXTBSY",
+[ 27] = "EFBIG",
+[ 28] = "ENOSPC",
+[ 29] = "ESPIPE",
+[ 30] = "EROFS",
+[ 31] = "EMLINK",
+[ 32] = "EPIPE",
+[ 33] = "EDOM",
+[ 34] = "ERANGE",
+[ 35] = "EDEADLK",
+[ 36] = "ENAMETOOLONG",
+[ 37] = "ENOLCK",
+[ 38] = "ENOSYS",
+[ 39] = "ENOTEMPTY",
+[ 40] = "ELOOP",
+[ 42] = "ENOMSG",
+[ 43] = "EIDRM",
+[ 44] = "ECHRNG",
+[ 45] = "EL2NSYNC",
+[ 46] = "EL3HLT",
+[ 47] = "EL3RST",
+[ 48] = "ELNRNG",
+[ 49] = "EUNATCH",
+[ 50] = "ENOCSI",
+[ 51] = "EL2HLT",
+[ 52] = "EBADE",
+[ 53] = "EBADR",
+[ 54] = "EXFULL",
+[ 55] = "ENOANO",
+[ 56] = "EBADRQC",
+[ 57] = "EBADSLT",
+[ 59] = "EBFONT",
+[ 60] = "ENOSTR",
+[ 61] = "ENODATA",
+[ 62] = "ETIME",
+[ 63] = "ENOSR",
+[ 64] = "ENONET",
+[ 65] = "ENOPKG",
+[ 66] = "EREMOTE",
+[ 67] = "ENOLINK",
+[ 68] = "EADV",
+[ 69] = "ESRMNT",
+[ 70] = "ECOMM",
+[ 71] = "EPROTO",
+[ 72] = "EMULTIHOP",
+[ 73] = "EDOTDOT",
+[ 74] = "EBADMSG",
+[ 75] = "EOVERFLOW",
+[ 76] = "ENOTUNIQ",
+[ 77] = "EBADFD",
+[ 78] = "EREMCHG",
+[ 79] = "ELIBACC",
+[ 80] = "ELIBBAD",
+[ 81] = "ELIBSCN",
+[ 82] = "ELIBMAX",
+[ 83] = "ELIBEXEC",
+[ 84] = "EILSEQ",
+[ 85] = "ERESTART",
+[ 86] = "ESTRPIPE",
+[ 87] = "EUSERS",
+[ 88] = "ENOTSOCK",
+[ 89] = "EDESTADDRREQ",
+[ 90] = "EMSGSIZE",
+[ 91] = "EPROTOTYPE",
+[ 92] = "ENOPROTOOPT",
+[ 93] = "EPROTONOSUPPORT",
+[ 94] = "ESOCKTNOSUPPORT",
+[ 95] = "EOPNOTSUPP",
+[ 96] = "EPFNOSUPPORT",
+[ 97] = "EAFNOSUPPORT",
+[ 98] = "EADDRINUSE",
+[ 99] = "EADDRNOTAVAIL",
+[100] = "ENETDOWN",
+[101] = "ENETUNREACH",
+[102] = "ENETRESET",
+[103] = "ECONNABORTED",
+[104] = "ECONNRESET",
+[105] = "ENOBUFS",
+[106] = "EISCONN",
+[107] = "ENOTCONN",
+[108] = "ESHUTDOWN",
+[109] = "ETOOMANYREFS",
+[110] = "ETIMEDOUT",
+[111] = "ECONNREFUSED",
+[112] = "EHOSTDOWN",
+[113] = "EHOSTUNREACH",
+[114] = "EALREADY",
+[115] = "EINPROGRESS",
+[116] = "ESTALE",
+[117] = "EUCLEAN",
+[118] = "ENOTNAM",
+[119] = "ENAVAIL",
+[120] = "EISNAM",
+[121] = "EREMOTEIO",
+[122] = "EDQUOT",
+[123] = "ENOMEDIUM",
+[124] = "EMEDIUMTYPE",
+[125] = "ECANCELED",
+[126] = "ENOKEY",
+[127] = "EKEYEXPIRED",
+[128] = "EKEYREVOKED",
+[129] = "EKEYREJECTED",
+[130] = "EOWNERDEAD",
+[131] = "ENOTRECOVERABLE",
+[132] = "ERFKILL",
+[133] = "EHWPOISON",
+[512] = "ERESTARTSYS",
+[513] = "ERESTARTNOINTR",
+[514] = "ERESTARTNOHAND",
+[515] = "ENOIOCTLCMD",
+[516] = "ERESTART_RESTARTBLOCK",
+[517] = "EPROBE_DEFER",
+[518] = "EOPENSTALE",
+[521] = "EBADHANDLE",
+[522] = "ENOTSYNC",
+[523] = "EBADCOOKIE",
+[524] = "ENOTSUPP",
+[525] = "ETOOSMALL",
+[526] = "ESERVERFAULT",
+[527] = "EBADTYPE",
+[528] = "EJUKEBOX",
+[529] = "EIOCBQUEUED",
diff --git a/strace/linux/hppa/arch_regs.c b/strace/linux/hppa/arch_regs.c
new file mode 100644
index 0000000..65432ab
--- /dev/null
+++ b/strace/linux/hppa/arch_regs.c
@@ -0,0 +1,2 @@
+static long hppa_r28;
+#define ARCH_PC_PEEK_ADDR PT_IAOQ0
diff --git a/strace/linux/hppa/arch_regs.h b/strace/linux/hppa/arch_regs.h
new file mode 100644
index 0000000..d42fc14
--- /dev/null
+++ b/strace/linux/hppa/arch_regs.h
@@ -0,0 +1,5 @@
+#define PT_GR20 (20*4)
+#define PT_GR26 (26*4)
+#define PT_GR28 (28*4)
+#define PT_IAOQ0 (106*4)
+#define PT_IAOQ1 (107*4)
diff --git a/strace/linux/hppa/errnoent.h b/strace/linux/hppa/errnoent.h
new file mode 100644
index 0000000..896980b
--- /dev/null
+++ b/strace/linux/hppa/errnoent.h
@@ -0,0 +1,151 @@
+[  1] = "EPERM",
+[  2] = "ENOENT",
+[  3] = "ESRCH",
+[  4] = "EINTR",
+[  5] = "EIO",
+[  6] = "ENXIO",
+[  7] = "E2BIG",
+[  8] = "ENOEXEC",
+[  9] = "EBADF",
+[ 10] = "ECHILD",
+[ 11] = "EAGAIN",
+[ 12] = "ENOMEM",
+[ 13] = "EACCES",
+[ 14] = "EFAULT",
+[ 15] = "ENOTBLK",
+[ 16] = "EBUSY",
+[ 17] = "EEXIST",
+[ 18] = "EXDEV",
+[ 19] = "ENODEV",
+[ 20] = "ENOTDIR",
+[ 21] = "EISDIR",
+[ 22] = "EINVAL",
+[ 23] = "ENFILE",
+[ 24] = "EMFILE",
+[ 25] = "ENOTTY",
+[ 26] = "ETXTBSY",
+[ 27] = "EFBIG",
+[ 28] = "ENOSPC",
+[ 29] = "ESPIPE",
+[ 30] = "EROFS",
+[ 31] = "EMLINK",
+[ 32] = "EPIPE",
+[ 33] = "EDOM",
+[ 34] = "ERANGE",
+[ 35] = "ENOMSG",
+[ 36] = "EIDRM",
+[ 37] = "ECHRNG",
+[ 38] = "EL2NSYNC",
+[ 39] = "EL3HLT",
+[ 40] = "EL3RST",
+[ 41] = "ELNRNG",
+[ 42] = "EUNATCH",
+[ 43] = "ENOCSI",
+[ 44] = "EL2HLT",
+[ 45] = "EDEADLK",
+[ 46] = "ENOLCK",
+[ 47] = "EILSEQ",
+[ 50] = "ENONET",
+[ 51] = "ENODATA",
+[ 52] = "ETIME",
+[ 53] = "ENOSR",
+[ 54] = "ENOSTR",
+[ 55] = "ENOPKG",
+[ 57] = "ENOLINK",
+[ 58] = "EADV",
+[ 59] = "ESRMNT",
+[ 60] = "ECOMM",
+[ 61] = "EPROTO",
+[ 64] = "EMULTIHOP",
+[ 66] = "EDOTDOT",
+[ 67] = "EBADMSG",
+[ 68] = "EUSERS",
+[ 69] = "EDQUOT",
+[ 70] = "ESTALE",
+[ 71] = "EREMOTE",
+[ 72] = "EOVERFLOW",
+[160] = "EBADE",
+[161] = "EBADR",
+[162] = "EXFULL",
+[163] = "ENOANO",
+[164] = "EBADRQC",
+[165] = "EBADSLT",
+[166] = "EBFONT",
+[167] = "ENOTUNIQ",
+[168] = "EBADFD",
+[169] = "EREMCHG",
+[170] = "ELIBACC",
+[171] = "ELIBBAD",
+[172] = "ELIBSCN",
+[173] = "ELIBMAX",
+[174] = "ELIBEXEC",
+[175] = "ERESTART",
+[176] = "ESTRPIPE",
+[177] = "EUCLEAN",
+[178] = "ENOTNAM",
+[179] = "ENAVAIL",
+[180] = "EISNAM",
+[181] = "EREMOTEIO",
+[182] = "ENOMEDIUM",
+[183] = "EMEDIUMTYPE",
+[184] = "ENOKEY",
+[185] = "EKEYEXPIRED",
+[186] = "EKEYREVOKED",
+[187] = "EKEYREJECTED",
+[215] = "ENOSYM",
+[216] = "ENOTSOCK",
+[217] = "EDESTADDRREQ",
+[218] = "EMSGSIZE",
+[219] = "EPROTOTYPE",
+[220] = "ENOPROTOOPT",
+[221] = "EPROTONOSUPPORT",
+[222] = "ESOCKTNOSUPPORT",
+[223] = "EOPNOTSUPP",
+[224] = "EPFNOSUPPORT",
+[225] = "EAFNOSUPPORT",
+[226] = "EADDRINUSE",
+[227] = "EADDRNOTAVAIL",
+[228] = "ENETDOWN",
+[229] = "ENETUNREACH",
+[230] = "ENETRESET",
+[231] = "ECONNABORTED",
+[232] = "ECONNRESET",
+[233] = "ENOBUFS",
+[234] = "EISCONN",
+[235] = "ENOTCONN",
+[236] = "ESHUTDOWN",
+[237] = "ETOOMANYREFS",
+[238] = "ETIMEDOUT",
+[239] = "ECONNREFUSED",
+[240] = "EREMOTERELEASE",
+[241] = "EHOSTDOWN",
+[242] = "EHOSTUNREACH",
+[244] = "EALREADY",
+[245] = "EINPROGRESS",
+[246] = "EWOULDBLOCK",
+[247] = "ENOTEMPTY",
+[248] = "ENAMETOOLONG",
+[249] = "ELOOP",
+[251] = "ENOSYS",
+[252] = "ENOTSUP",
+[253] = "ECANCELED",
+[254] = "EOWNERDEAD",
+[255] = "ENOTRECOVERABLE",
+[256] = "ERFKILL",
+[257] = "EHWPOISON",
+[512] = "ERESTARTSYS",
+[513] = "ERESTARTNOINTR",
+[514] = "ERESTARTNOHAND",
+[515] = "ENOIOCTLCMD",
+[516] = "ERESTART_RESTARTBLOCK",
+[517] = "EPROBE_DEFER",
+[518] = "EOPENSTALE",
+[521] = "EBADHANDLE",
+[522] = "ENOTSYNC",
+[523] = "EBADCOOKIE",
+[524] = "ENOTSUPP",
+[525] = "ETOOSMALL",
+[526] = "ESERVERFAULT",
+[527] = "EBADTYPE",
+[528] = "EJUKEBOX",
+[529] = "EIOCBQUEUED",
diff --git a/strace/linux/hppa/get_error.c b/strace/linux/hppa/get_error.c
new file mode 100644
index 0000000..a2a7c0e
--- /dev/null
+++ b/strace/linux/hppa/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(hppa_r28)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -hppa_r28;
+	} else {
+		tcp->u_rval = hppa_r28;
+	}
+}
diff --git a/strace/linux/hppa/get_scno.c b/strace/linux/hppa/get_scno.c
new file mode 100644
index 0000000..7da2fc4
--- /dev/null
+++ b/strace/linux/hppa/get_scno.c
@@ -0,0 +1,6 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	return upeek(tcp->pid, PT_GR20, &tcp->scno) < 0 ? -1 : 1;
+}
diff --git a/strace/linux/hppa/get_syscall_args.c b/strace/linux/hppa/get_syscall_args.c
new file mode 100644
index 0000000..2258ea8
--- /dev/null
+++ b/strace/linux/hppa/get_syscall_args.c
@@ -0,0 +1,11 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, PT_GR26-4*i, &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/hppa/get_syscall_result.c b/strace/linux/hppa/get_syscall_result.c
new file mode 100644
index 0000000..0d15d4d
--- /dev/null
+++ b/strace/linux/hppa/get_syscall_result.c
@@ -0,0 +1,5 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return upeek(tcp->pid, PT_GR28, &hppa_r28) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/hppa/ioctls_arch0.h b/strace/linux/hppa/ioctls_arch0.h
new file mode 100644
index 0000000..ba93971
--- /dev/null
+++ b/strace/linux/hppa/ioctls_arch0.h
@@ -0,0 +1,101 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/parisc/include/ tree. */
+{ "asm/grfioctl.h", "GCAOFF", _IOC_NONE, 0x4704, 0x00 },
+{ "asm/grfioctl.h", "GCAON", _IOC_NONE, 0x4703, 0x00 },
+{ "asm/grfioctl.h", "GCDESCRIBE", _IOC_READ, 0x4715, 0x70 },
+{ "asm/grfioctl.h", "GCFASTLOCK", _IOC_NONE, 0x471a, 0x00 },
+{ "asm/grfioctl.h", "GCID", _IOC_READ, 0x4700, 0x04 },
+{ "asm/grfioctl.h", "GCLOCK", _IOC_NONE, 0x4707, 0x00 },
+{ "asm/grfioctl.h", "GCLOCK_MINIMUM", _IOC_NONE, 0x4709, 0x00 },
+{ "asm/grfioctl.h", "GCMAP", _IOC_READ|_IOC_WRITE, 0x4705, 0x04 },
+{ "asm/grfioctl.h", "GCMAP_HPUX", _IOC_NONE, 0x4705, 0x00 },
+{ "asm/grfioctl.h", "GCOFF", _IOC_NONE, 0x4702, 0x00 },
+{ "asm/grfioctl.h", "GCON", _IOC_NONE, 0x4701, 0x00 },
+{ "asm/grfioctl.h", "GCSTATIC_CMAP", _IOC_NONE, 0x470b, 0x00 },
+{ "asm/grfioctl.h", "GCTERM", _IOC_READ|_IOC_WRITE, 0x4714, 0x04 },
+{ "asm/grfioctl.h", "GCUNLOCK", _IOC_NONE, 0x4708, 0x00 },
+{ "asm/grfioctl.h", "GCUNLOCK_MINIMUM", _IOC_NONE, 0x470a, 0x00 },
+{ "asm/grfioctl.h", "GCUNMAP", _IOC_READ|_IOC_WRITE, 0x4706, 0x04 },
+{ "asm/grfioctl.h", "GCUNMAP_HPUX", _IOC_NONE, 0x4706, 0x00 },
+{ "asm/grfioctl.h", "GCVARIABLE_CMAP", _IOC_NONE, 0x470c, 0x00 },
+{ "asm/ioctls.h", "FIOASYNC", 0, 0x5452, 0 },
+{ "asm/ioctls.h", "FIOCLEX", 0, 0x5451, 0 },
+{ "asm/ioctls.h", "FIONBIO", 0, 0x5421, 0 },
+{ "asm/ioctls.h", "FIONCLEX", 0, 0x5450, 0 },
+{ "asm/ioctls.h", "FIONREAD", 0, 0x541B, 0 },
+{ "asm/ioctls.h", "FIOQSIZE", 0, 0x5460, 0 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x5407, 0x00 },
+{ "asm/ioctls.h", "TCGETA", _IOC_READ, 0x5401, 0x12 },
+{ "asm/ioctls.h", "TCGETS", _IOC_READ, 0x5410, 0x24 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x5405, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm/ioctls.h", "TCSETA", _IOC_WRITE, 0x5402, 0x12 },
+{ "asm/ioctls.h", "TCSETAF", _IOC_WRITE, 0x5404, 0x12 },
+{ "asm/ioctls.h", "TCSETAW", _IOC_WRITE, 0x5403, 0x12 },
+{ "asm/ioctls.h", "TCSETS", _IOC_WRITE, 0x5411, 0x24 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", _IOC_WRITE, 0x5413, 0x24 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", _IOC_WRITE, 0x5412, 0x24 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x5406, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x541e, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x542e, 0x20 },
+{ "asm/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm/ioctls.h", "TIOCGSID", _IOC_READ, 0x5414, 0x04 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm/ioctls.h", "TIOCGWINSZ", 0, 0x5413, 0 },
+{ "asm/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm/ioctls.h", "TIOCOUTQ", 0, 0x5411, 0 },
+{ "asm/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSLTC", 0, 0x5462, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x541d, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x542f, 0x20 },
+{ "asm/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm/ioctls.h", "TIOCSTART", 0, 0x5461, 0 },
+{ "asm/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm/ioctls.h", "TIOCSTOP", 0, 0x5462, 0 },
+{ "asm/ioctls.h", "TIOCSWINSZ", 0, 0x5414, 0 },
+{ "asm/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm/perf.h", "PA_PERF_OFF", _IOC_READ, 0x7002, 0x04 },
+{ "asm/perf.h", "PA_PERF_ON", _IOC_NONE, 0x7001, 0x00 },
+{ "asm/perf.h", "PA_PERF_VERSION", _IOC_READ, 0x7003, 0x04 },
+{ "asm/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
diff --git a/strace/linux/hppa/ioctls_inc0.h b/strace/linux/hppa/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/hppa/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/hppa/signalent.h b/strace/linux/hppa/signalent.h
new file mode 100644
index 0000000..6d69987
--- /dev/null
+++ b/strace/linux/hppa/signalent.h
@@ -0,0 +1,33 @@
+	"SIG_0",	/* 0 */
+	"SIGHUP",	/* 1 */
+	"SIGINT",	/* 2 */
+	"SIGQUIT",	/* 3 */
+	"SIGILL",	/* 4 */
+	"SIGTRAP",	/* 5 */
+	"SIGABRT",	/* 6 */
+	"SIGSTKFLT",	/* 7 */
+	"SIGFPE",	/* 8 */
+	"SIGKILL",	/* 9 */
+	"SIGBUS",	/* 10 */
+	"SIGSEGV",	/* 11 */
+	"SIGXCPU",	/* 12 */
+	"SIGPIPE",	/* 13 */
+	"SIGALRM",	/* 14 */
+	"SIGTERM",	/* 15 */
+	"SIGUSR1",	/* 16 */
+	"SIGUSR2",	/* 17 */
+	"SIGCHLD",	/* 18 */
+	"SIGPWR",	/* 19 */
+	"SIGVTALRM",	/* 20 */
+	"SIGPROF",	/* 21 */
+	"SIGIO",	/* 22 */
+	"SIGWINCH",	/* 23 */
+	"SIGSTOP",	/* 24 */
+	"SIGTSTP",	/* 25 */
+	"SIGCONT",	/* 26 */
+	"SIGTTIN",	/* 27 */
+	"SIGTTOU",	/* 28 */
+	"SIGURG",	/* 29 */
+	"SIGXFSZ",	/* 30 */
+	"SIGSYS",	/* 31 */
+	"SIGRTMIN",	/* 32 */
diff --git a/strace/linux/hppa/syscallent.h b/strace/linux/hppa/syscallent.h
new file mode 100644
index 0000000..4928047
--- /dev/null
+++ b/strace/linux/hppa/syscallent.h
@@ -0,0 +1,353 @@
+/*
+ * Copyright (c) 2001 Hewlett-Packard, Matthew Wilcox
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 17] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 18] = { 2,	TF,		SEN(stat),			"stat"			},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 3,	TN,		SEN(bind),			"bind"			},
+[ 23] = { 1,	0,		SEN(setuid),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 3,	TN,		SEN(connect),			"connect"		},
+[ 32] = { 2,	TN,		SEN(listen),			"listen"		},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 3,	TN,		SEN(accept),			"accept"		},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 4,	TN,		SEN(send),			"send"			},
+[ 59] = { 1,	0,		SEN(uname),			"uname"			},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid),			"setregid"		},
+[ 72] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[ 82] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	TN,		SEN(recv),			"recv"			},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[102] = { },
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	0,		SEN(capget),			"capget"		},
+[107] = { 2,	0,		SEN(capset),			"capset"		},
+[108] = { 5,	TD,		SEN(pread),			"pread64"		},
+[109] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[110] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[113] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[123] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[166] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 3,	TF,		SEN(chown),			"chown"			},
+[181] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[182] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[183] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[184] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[185] = { 3,	TI,		SEN(semop),			"semop"			},
+[186] = { 3,	TI,		SEN(semget),			"semget"		},
+[187] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[188] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[189] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[190] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[191] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[192] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[193] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[194] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[195] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[196] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[197] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[198] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[199] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[200] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[201] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[202] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[203] = { 5,	0,		SEN(printargs),			"attrctl"		},
+[204] = { 5,	0,		SEN(printargs),			"acl_get"		},
+[205] = { 5,	0,		SEN(printargs),			"acl_set"		},
+[206] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[207] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[208] = { 2,	TS,		SEN(kill),			"tkill"			},
+[209] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[210] = { 6,	0,		SEN(futex),			"futex"			},
+[211] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[212] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[213] = { 5,	0,		SEN(printargs),			"set_thread_area"	},
+[214] = { 5,	0,		SEN(printargs),			"get_thread_area"	},
+[215] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[216] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[217] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[218] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[219] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[220] = { 5,	0,		SEN(printargs),			"alloc_hugepages"	},
+[221] = { 1,	0,		SEN(printargs),			"free_hugepages"	},
+[222] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[223] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[224] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[225] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[226] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[227] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[228] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[229] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[230] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[231] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[232] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[233] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[234] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[235] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[236] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[237] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[238] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[239] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[240] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[241] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[242] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[243] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[244] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[245] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[246] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[247] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[248] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[249] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[250] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[251] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[252] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[253] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[254] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[255] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[256] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[257] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[258] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[259] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[260] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[261] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[262] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[263] = { 5,	0,		SEN(vserver),			"vserver"		},
+[264] = { 5,	0,		SEN(add_key),			"add_key"		},
+[265] = { 4,	0,		SEN(request_key),		"request_key"		},
+[266] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[267] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[268] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[269] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[270] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[271] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[272] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[273] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[274] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[275] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[276] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[277] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[278] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[279] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[280] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[281] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[282] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[283] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[284] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[285] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[286] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[287] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[288] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[289] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[290] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[291] = { 6,	TD,		SEN(splice),			"splice"		},
+[292] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[293] = { 4,	TD,		SEN(tee),			"tee"			},
+[294] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[295] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[296] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[297] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[298] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[299] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[300] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[301] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[302] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[303] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[304] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[305] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[306] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[307] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[308] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[309] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[310] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[311] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[312] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[313] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[314] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[315] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[316] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[317] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[318] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[319] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[320] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[321] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[322] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[323] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[324] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[325] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[326] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[327] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[328] = { 2,	TD,		SEN(setns),			"setns"			},
+[329] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[330] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[331] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[332] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[333] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[334] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[335] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[336] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[337] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[338] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[339] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[340] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[341] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[342] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[343] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[344] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[345] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[346] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[347] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[348] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
diff --git a/strace/linux/i386/arch_regs.c b/strace/linux/i386/arch_regs.c
new file mode 100644
index 0000000..ef30046
--- /dev/null
+++ b/strace/linux/i386/arch_regs.c
@@ -0,0 +1,5 @@
+static struct user_regs_struct i386_regs;
+long *const i386_esp_ptr = &i386_regs.esp;
+
+#define ARCH_REGS_FOR_GETREGS i386_regs
+#define ARCH_PC_REG i386_regs.eip
diff --git a/strace/linux/i386/arch_regs.h b/strace/linux/i386/arch_regs.h
new file mode 100644
index 0000000..77984ff
--- /dev/null
+++ b/strace/linux/i386/arch_regs.h
@@ -0,0 +1 @@
+extern long *const i386_esp_ptr;
diff --git a/strace/linux/i386/arch_sigreturn.c b/strace/linux/i386/arch_sigreturn.c
new file mode 100644
index 0000000..9446994
--- /dev/null
+++ b/strace/linux/i386/arch_sigreturn.c
@@ -0,0 +1,24 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	/*
+	 * On i386, sigcontext is followed on stack by struct fpstate
+	 * and after it an additional u32 extramask which holds
+	 * upper half of the mask.
+	 */
+	struct {
+		uint32_t struct_sigcontext_padding1[20];
+		uint32_t oldmask;
+		uint32_t struct_sigcontext_padding2;
+		uint32_t struct_fpstate_padding[156];
+		uint32_t extramask;
+	} frame;
+
+	if (umove(tcp, *i386_esp_ptr, &frame) < 0) {
+		tprintf("{mask=%#lx}", (unsigned long) *i386_esp_ptr);
+	} else {
+		uint32_t mask[2] = { frame.oldmask, frame.extramask };
+		tprintsigmask_addr("{mask=", mask);
+		tprints("}");
+	}
+}
diff --git a/strace/linux/i386/get_error.c b/strace/linux/i386/get_error.c
new file mode 100644
index 0000000..1f63605
--- /dev/null
+++ b/strace/linux/i386/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(i386_regs.eax)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -i386_regs.eax;
+	} else {
+		tcp->u_rval = i386_regs.eax;
+	}
+}
diff --git a/strace/linux/i386/get_scno.c b/strace/linux/i386/get_scno.c
new file mode 100644
index 0000000..c2e5551
--- /dev/null
+++ b/strace/linux/i386/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = i386_regs.orig_eax;
+	return 1;
+}
diff --git a/strace/linux/i386/get_syscall_args.c b/strace/linux/i386/get_syscall_args.c
new file mode 100644
index 0000000..d5de1d9
--- /dev/null
+++ b/strace/linux/i386/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = i386_regs.ebx;
+	tcp->u_arg[1] = i386_regs.ecx;
+	tcp->u_arg[2] = i386_regs.edx;
+	tcp->u_arg[3] = i386_regs.esi;
+	tcp->u_arg[4] = i386_regs.edi;
+	tcp->u_arg[5] = i386_regs.ebp;
+	return 1;
+}
diff --git a/strace/linux/i386/ioctls_arch0.h b/strace/linux/i386/ioctls_arch0.h
new file mode 100644
index 0000000..0a35935
--- /dev/null
+++ b/strace/linux/i386/ioctls_arch0.h
@@ -0,0 +1,16 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/x86/include/ tree. */
+{ "asm/mce.h", "MCE_GETCLEAR_FLAGS", _IOC_READ, 0x4d03, 0x04 },
+{ "asm/mce.h", "MCE_GET_LOG_LEN", _IOC_READ, 0x4d02, 0x04 },
+{ "asm/mce.h", "MCE_GET_RECORD_LEN", _IOC_READ, 0x4d01, 0x04 },
+{ "asm/msr.h", "X86_IOC_RDMSR_REGS", _IOC_READ|_IOC_WRITE, 0x63a0, 0x20 },
+{ "asm/msr.h", "X86_IOC_WRMSR_REGS", _IOC_READ|_IOC_WRITE, 0x63a1, 0x20 },
+{ "asm/mtrr.h", "MTRRIOC_ADD_ENTRY", _IOC_WRITE, 0x4d00, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_ADD_PAGE_ENTRY", _IOC_WRITE, 0x4d05, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_DEL_ENTRY", _IOC_WRITE, 0x4d02, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_DEL_PAGE_ENTRY", _IOC_WRITE, 0x4d07, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_GET_ENTRY", _IOC_READ|_IOC_WRITE, 0x4d03, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_GET_PAGE_ENTRY", _IOC_READ|_IOC_WRITE, 0x4d08, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_KILL_ENTRY", _IOC_WRITE, 0x4d04, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_KILL_PAGE_ENTRY", _IOC_WRITE, 0x4d09, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_SET_ENTRY", _IOC_WRITE, 0x4d01, 0x0c },
+{ "asm/mtrr.h", "MTRRIOC_SET_PAGE_ENTRY", _IOC_WRITE, 0x4d06, 0x0c },
diff --git a/strace/linux/i386/ioctls_inc0.h b/strace/linux/i386/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/i386/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/i386/syscallent.h b/strace/linux/i386/syscallent.h
new file mode 100644
index 0000000..d6175fa
--- /dev/null
+++ b/strace/linux/i386/syscallent.h
@@ -0,0 +1,410 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 1,	TD|TM|SI,	SEN(old_mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 1,	0,		SEN(vm86old),			"vm86old"		},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 3,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { 5,	0,		SEN(vm86),			"vm86"			},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 5,	TD,		SEN(pread),			"pread64"		},
+[181] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"chown"			},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[193] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(getegid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"chown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[222 ... 223] = { },
+[224] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[225] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[226] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[227] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[228] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[229] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[230] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[231] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[232] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[233] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[234] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[235] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[236] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[237] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[238] = { 2,	TS,		SEN(kill),			"tkill"			},
+[239] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[240] = { 6,	0,		SEN(futex),			"futex"			},
+[241] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[242] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[243] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[244] = { 1,	0,		SEN(get_thread_area),		"get_thread_area"	},
+[245] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[246] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[247] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[248] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[249] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[250] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[251] = { }, /* sys_set_zone_reclaim */
+[252] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[253] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[254] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[255] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[256] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[257] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[258] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[259] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[260] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[261] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[262] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[263] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[264] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[265] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[266] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[267] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[268] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[269] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[270] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[271] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[272] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[273] = { 5,	0,		SEN(vserver),			"vserver"		},
+[274] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[275] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[276] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[277] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[278] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[279] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[280] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[281] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[282] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[283] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[284] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[285] = { }, /* sys_setaltroot */
+[286] = { 5,	0,		SEN(add_key),			"add_key"		},
+[287] = { 4,	0,		SEN(request_key),		"request_key"		},
+[288] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[289] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[290] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[291] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[292] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[293] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[294] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[295] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[296] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[297] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[298] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[299] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[300] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[301] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[302] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[303] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[304] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[305] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[306] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[307] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[308] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[309] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[310] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[311] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[312] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[313] = { 6,	TD,		SEN(splice),			"splice"		},
+[314] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[315] = { 4,	TD,		SEN(tee),			"tee"			},
+[316] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[317] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[318] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[319] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[320] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[321] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[322] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[323] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[324] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[325] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[326] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[327] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[328] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[329] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[330] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[331] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[332] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[333] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[334] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[335] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[336] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[337] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[338] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[339] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[340] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[341] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[342] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[343] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[344] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[345] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[346] = { 2,	TD,		SEN(setns),			"setns"			},
+[347] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[348] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[349] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[350] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[351] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[352] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[353] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[354] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[355] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[356] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[357] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[358] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[359] = { 3,	TN,		SEN(socket),			"socket"		},
+[360] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[361] = { 3,	TN,		SEN(bind),			"bind"			},
+[362] = { 3,	TN,		SEN(connect),			"connect"		},
+[363] = { 2,	TN,		SEN(listen),			"listen"		},
+[364] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[365] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[366] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[367] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[368] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[369] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[370] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[371] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[372] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[373] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[374] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[375] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[376] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[377] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[378] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[379] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/i386/userent.h b/strace/linux/i386/userent.h
new file mode 100644
index 0000000..a8abd11
--- /dev/null
+++ b/strace/linux/i386/userent.h
@@ -0,0 +1,19 @@
+XLAT(4*EBX),
+XLAT(4*ECX),
+XLAT(4*EDX),
+XLAT(4*ESI),
+XLAT(4*EDI),
+XLAT(4*EBP),
+XLAT(4*EAX),
+XLAT(4*DS),
+XLAT(4*ES),
+XLAT(4*FS),
+XLAT(4*GS),
+XLAT(4*ORIG_EAX),
+XLAT(4*EIP),
+XLAT(4*CS),
+XLAT(4*EFL),
+XLAT(4*UESP),
+XLAT(4*SS),
+/* Other fields in "struct user" */
+#include "userent0.h"
diff --git a/strace/linux/i386/userent0.h b/strace/linux/i386/userent0.h
new file mode 100644
index 0000000..d2728ff
--- /dev/null
+++ b/strace/linux/i386/userent0.h
@@ -0,0 +1,15 @@
+XLAT_UOFF(u_fpvalid),
+XLAT_UOFF(i387),
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(reserved),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(u_fpstate),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+XLAT_UOFF(u_debugreg),
+#include "../userent0.h"
diff --git a/strace/linux/ia64/arch_getrval2.c b/strace/linux/ia64/arch_getrval2.c
new file mode 100644
index 0000000..7a6875f
--- /dev/null
+++ b/strace/linux/ia64/arch_getrval2.c
@@ -0,0 +1,5 @@
+long
+getrval2(struct tcb *tcp)
+{
+	return ia64_regs.gr[9];
+}
diff --git a/strace/linux/ia64/arch_regs.c b/strace/linux/ia64/arch_regs.c
new file mode 100644
index 0000000..14fffd5
--- /dev/null
+++ b/strace/linux/ia64/arch_regs.c
@@ -0,0 +1,8 @@
+static struct pt_all_user_regs ia64_regs;
+unsigned long *const ia64_frame_ptr = &ia64_regs.gr[12];
+
+#define IA64_PSR_IS	((long)1 << 34)
+#define ia64_ia32mode	(ia64_regs.cr_ipsr & IA64_PSR_IS)
+
+#define ARCH_REGS_FOR_GETREGS ia64_regs
+#define ARCH_PC_REG ia64_regs.br[0]
diff --git a/strace/linux/ia64/arch_regs.h b/strace/linux/ia64/arch_regs.h
new file mode 100644
index 0000000..7ad969c
--- /dev/null
+++ b/strace/linux/ia64/arch_regs.h
@@ -0,0 +1,2 @@
+#include <asm/ptrace_offsets.h>
+extern unsigned long *const ia64_frame_ptr;
diff --git a/strace/linux/ia64/arch_sigreturn.c b/strace/linux/ia64/arch_sigreturn.c
new file mode 100644
index 0000000..8b54d6c
--- /dev/null
+++ b/strace/linux/ia64/arch_sigreturn.c
@@ -0,0 +1,12 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	/* offsetof(struct sigframe, sc) */
+#define OFFSETOF_STRUCT_SIGFRAME_SC	0xA0
+	const long addr = *ia64_frame_ptr + 16 +
+			  OFFSETOF_STRUCT_SIGFRAME_SC +
+			  offsetof(struct sigcontext, sc_mask);
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/ia64/get_error.c b/strace/linux/ia64/get_error.c
new file mode 100644
index 0000000..52daa7f
--- /dev/null
+++ b/strace/linux/ia64/get_error.c
@@ -0,0 +1,20 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (ia64_ia32mode) {
+		int err = ia64_regs.gr[8];
+		if (check_errno && is_negated_errno(err)) {
+			tcp->u_rval = -1;
+			tcp->u_error = -err;
+		} else {
+			tcp->u_rval = err;
+		}
+	} else {
+		if (ia64_regs.gr[10]) {
+			tcp->u_rval = -1;
+			tcp->u_error = ia64_regs.gr[8];
+		} else {
+			tcp->u_rval = ia64_regs.gr[8];
+		}
+	}
+}
diff --git a/strace/linux/ia64/get_scno.c b/strace/linux/ia64/get_scno.c
new file mode 100644
index 0000000..0ddc17a
--- /dev/null
+++ b/strace/linux/ia64/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = ia64_ia32mode ? ia64_regs.gr[0] : ia64_regs.gr[15];
+	return 1;
+}
diff --git a/strace/linux/ia64/get_syscall_args.c b/strace/linux/ia64/get_syscall_args.c
new file mode 100644
index 0000000..2295d08
--- /dev/null
+++ b/strace/linux/ia64/get_syscall_args.c
@@ -0,0 +1,29 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	if (!ia64_ia32mode) {
+		unsigned long *rbs_end =
+			(unsigned long *) ia64_regs.ar[PT_AUR_BSP];
+		unsigned long sof = (ia64_regs.cfm >> 0) & 0x7f;
+		unsigned long sol = (ia64_regs.cfm >> 7) & 0x7f;
+		unsigned long *out0 = ia64_rse_skip_regs(rbs_end, -sof + sol);
+		unsigned int i;
+
+		for (i = 0; i < tcp->s_ent->nargs; ++i) {
+			if (umoven(tcp,
+				   (unsigned long) ia64_rse_skip_regs(out0, i),
+				   sizeof(long), &tcp->u_arg[i]) < 0)
+				return -1;
+		}
+	} else {
+		/* truncate away IVE sign-extension */
+		tcp->u_arg[0] = 0xffffffff & ia64_regs.gr[11]; /* EBX */
+		tcp->u_arg[1] = 0xffffffff & ia64_regs.gr[ 9]; /* ECX */
+		tcp->u_arg[2] = 0xffffffff & ia64_regs.gr[10]; /* EDX */
+		tcp->u_arg[3] = 0xffffffff & ia64_regs.gr[14]; /* ESI */
+		tcp->u_arg[4] = 0xffffffff & ia64_regs.gr[15]; /* EDI */
+		tcp->u_arg[5] = 0xffffffff & ia64_regs.gr[13]; /* EBP */
+	}
+	return 1;
+}
diff --git a/strace/linux/ia64/ioctls_arch0.h b/strace/linux/ia64/ioctls_arch0.h
new file mode 100644
index 0000000..6a6e400
--- /dev/null
+++ b/strace/linux/ia64/ioctls_arch0.h
@@ -0,0 +1,8 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/ia64/include/ tree. */
+{ "asm/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
diff --git a/strace/linux/ia64/ioctls_inc0.h b/strace/linux/ia64/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/ia64/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/ia64/syscallent.h b/strace/linux/ia64/syscallent.h
new file mode 100644
index 0000000..713cab8
--- /dev/null
+++ b/strace/linux/ia64/syscallent.h
@@ -0,0 +1,368 @@
+/*
+ * Copyright (c) 1999, 2001 Hewlett-Packard Co
+ *	David Mosberger-Tang <davidm@hpl.hp.com>
+ * 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.
+ */
+
+/*
+ * IA-32 syscalls that have pointer arguments which are incompatible
+ * with 64-bit layout get redirected to printargs.
+ */
+#undef SYS_FUNC_NAME
+#define SYS_FUNC_NAME(syscall_name) printargs
+#include "../i386/syscallent.h"
+#undef SYS_FUNC_NAME
+#define SYS_FUNC_NAME(syscall_name) MPERS_FUNC_NAME(syscall_name)
+
+/* You must be careful to check ../i386/syscallent.h so that this table
+   starts where that one leaves off.
+*/
+[(SYS_ipc_subcall + SYS_ipc_nsubcalls) ... 1023] = { },
+[1024] = { 0,	0,		SEN(printargs),			"ni_syscall"		},
+[1025] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[1026] = { 3,	TD,		SEN(read),			"read"			},
+[1027] = { 3,	TD,		SEN(write),			"write"			},
+[1028] = { 3,	TD|TF,		SEN(open),			"open"			},
+[1029] = { 1,	TD,		SEN(close),			"close"			},
+[1030] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[1031] = { 2,	TF,		SEN(link),			"link"			},
+[1032] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[1033] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[1034] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[1035] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[1036] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[1037] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[1038] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[1039] = { 3,	TF,		SEN(chown),			"chown"			},
+[1040] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[1041] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[1042] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[1043] = { 5,	TF,		SEN(mount),			"mount"			},
+[1044] = { 2,	TF,		SEN(umount2),			"umount"		},
+[1045] = { 1,	0,		SEN(setuid),			"setuid"		},
+[1046] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[1047] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[1048] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[1049] = { 2,	TF,		SEN(access),			"access"		},
+[1050] = { 0,	0,		SEN(sync),			"sync"			},
+[1051] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[1052] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[1053] = { 2,	TS,		SEN(kill),			"kill"			},
+[1054] = { 2,	TF,		SEN(rename),			"rename"		},
+[1055] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[1056] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[1057] = { 1,	TD,		SEN(dup),			"dup"			},
+[1058] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[1059] = { 1,	0,		SEN(times),			"times"			},
+[1060] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[1061] = { 1,	0,		SEN(setgid),			"setgid"		},
+[1062] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[1063] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[1064] = { 1,	TF,		SEN(acct),			"acct"			},
+[1065] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[1066] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[1067] = { 1,	NF,		SEN(umask),			"umask"			},
+[1068] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[1069] = { 2,	0,		SEN(ustat),			"ustat"			},
+[1070] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[1071] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[1072] = { 2,	0,		SEN(setregid),			"setregid"		},
+[1073] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[1074] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[1075] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[1076] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[1077] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[1078] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[1079] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[1080] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[1081] = { 0,	0,		SEN(setsid),			"setsid"		},
+[1082] = { 1,	0,		SEN(getsid),			"getsid"		},
+[1083] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[1084] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[1085] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[1086] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[1087] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[1088] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[1089] = { 5,	TD,		SEN(select),			"select"		},
+[1090] = { 3,	TD,		SEN(poll),			"poll"			},
+[1091] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[1092] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[1093] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[1094] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[1095] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[1096] = { 4,	0,		SEN(reboot),			"reboot"		},
+[1097] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[1098] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[1099] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[1100] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[1101] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[1102] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[1103] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[1104] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[1105] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[1106] = { 3,	TI,		SEN(semget),			"semget"		},
+[1107] = { 3,	TI,		SEN(semop),			"semop"			},
+[1108] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[1109] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[1110] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[1111] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[1112] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[1113] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[1114] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[1115] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[1116] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[1117] = { 3,	0,		SEN(syslog),			"syslog"		},
+[1118] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[1119] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[1120] = { 2,	TF,		SEN(stat),			"stat"			},
+[1121] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[1122] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[1123] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[1124] = { 3,	TF,		SEN(chown),			"lchown"		},
+[1125] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[1126] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[1127] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[1128] = { 5,	TP,		SEN(clone),			"clone"			},
+[1129] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[1130] = { 1,	0,		SEN(uname),			"uname"			},
+[1131] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[1132] = { 2,	0,		SEN(create_module),		"create_module"		},
+[1133] = { 3,	0,		SEN(init_module),		"init_module"		},
+[1134] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[1135] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[1136] = { 5,	0,		SEN(query_module),		"query_module"		},
+[1137] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[1138] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[1139] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[1140] = { 1,	NF,		SEN(personality),		"personality"		},
+[1141] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[1142] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[1143] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[1144] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[1145] = { 2,	TD,		SEN(flock),			"flock"			},
+[1146] = { 3,	TD,		SEN(readv),			"readv"			},
+[1147] = { 3,	TD,		SEN(writev),			"writev"		},
+[1148] = { 4,	TD,		SEN(pread),			"pread64"		},
+[1149] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[1150] = { 1,	0,		SEN(printargs),			"_sysctl"		},
+[1151] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[1152] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[1153] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[1154] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[1155] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[1156] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[1157] = { 3,	TM,		SEN(msync),			"msync"			},
+[1158] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[1159] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[1160] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[1161] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[1162] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[1163] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[1164] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[1165] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[1166] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[1167] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[1168] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[1169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[1170] = { 5,	0,		SEN(prctl),			"prctl"			},
+[1171] = { 0,	0,		SEN(getpagesize),		"getpagesize"		},
+[1172] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[1173] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[1174] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[1175] = { MA,	0,		SEN(printargs),			"perfmonctl"		},
+[1176] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[1177] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[1178] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[1179] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[1180] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[1181] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[1182] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[1183] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[1184] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[1185] = { 2,	0,		SEN(capget),			"capget"		},
+[1186] = { 2,	0,		SEN(capset),			"capset"		},
+[1187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[1188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[1189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[1190] = { 3,	TN,		SEN(socket),			"socket"		},
+[1191] = { 3,	TN,		SEN(bind),			"bind"			},
+[1192] = { 3,	TN,		SEN(connect),			"connect"		},
+[1193] = { 2,	TN,		SEN(listen),			"listen"		},
+[1194] = { 3,	TN,		SEN(accept),			"accept"		},
+[1195] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[1196] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[1197] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[1198] = { 4,	TN,		SEN(send),			"send"			},
+[1199] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[1200] = { 4,	TN,		SEN(recv),			"recv"			},
+[1201] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[1202] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[1203] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[1204] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[1205] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[1206] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[1207] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[1208] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[1209] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[1210] = { 2,	TF,		SEN(stat),			"stat"			},
+[1211] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[1212] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[1213] = { 6,	TP,		SEN(clone),			"clone2"		},
+[1214] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[1215] = { 2,	0,		SEN(printargs),			"getunwind"		},
+[1216] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[1217] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[1218] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[1219] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[1220] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[1221] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[1222] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[1223] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[1224] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[1225] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[1226] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[1227] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[1228] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[1229] = { 2,	TS,		SEN(kill),			"tkill"			},
+[1230] = { 6,	0,		SEN(futex),			"futex"			},
+[1231] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[1232] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[1233] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[1234] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[1235] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[1236] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[1237] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[1238] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[1239] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[1240] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[1241] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[1242] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[1243] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[1244] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[1245] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[1246] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[1247] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[1248] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[1249] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[1250] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[1251] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[1252] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[1253] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[1254] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[1255] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[1256] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[1257] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[1258] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[1259] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[1260] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[1261] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[1262] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[1263] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[1264] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[1265] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[1266] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[1267] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[1268] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[1269] = { 5,	0,		SEN(vserver),			"vserver"		},
+[1270] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[1271] = { 5,	0,		SEN(add_key),			"add_key"		},
+[1272] = { 4,	0,		SEN(request_key),		"request_key"		},
+[1273] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[1274] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[1275] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[1276] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[1277] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[1278] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[1279] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[1280] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[1281] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[1282] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[1283] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[1284] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[1285] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[1286] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[1287] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[1288] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[1289] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[1290] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[1291] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[1292] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[1293] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[1294] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[1295] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[1296] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[1297] = { 6,	TD,		SEN(splice),			"splice"		},
+[1298] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[1299] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[1300] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[1301] = { 4,	TD,		SEN(tee),			"tee"			},
+[1302] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[1303] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[1304] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[1305] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[1306] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[1307] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[1308] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[1309] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[1310] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[1311] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[1312] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[1313] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[1314] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[1315] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[1316] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[1317] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[1318] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[1319] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[1320] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[1321] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[1322] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[1323] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[1324] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[1325] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[1326] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[1327] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[1328] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[1329] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[1330] = { 2,	TD,		SEN(setns),			"setns"			},
+[1331] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[1332] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[1333] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[1334] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[1335] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[1336] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[1337] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[1338] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[1339] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[1340] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[1341] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[1342] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[1343] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[1344] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[1345] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[1346] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[1347] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[1348] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[1349] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
diff --git a/strace/linux/ia64/userent.h b/strace/linux/ia64/userent.h
new file mode 100644
index 0000000..d2ffae6
--- /dev/null
+++ b/strace/linux/ia64/userent.h
@@ -0,0 +1,73 @@
+{ PT_F32, "f32" }, { PT_F33, "f33" }, { PT_F34, "f34" },
+{ PT_F35, "f35" }, { PT_F36, "f36" }, { PT_F37, "f37" },
+{ PT_F38, "f38" }, { PT_F39, "f39" }, { PT_F40, "f40" },
+{ PT_F41, "f41" }, { PT_F42, "f42" }, { PT_F43, "f43" },
+{ PT_F44, "f44" }, { PT_F45, "f45" }, { PT_F46, "f46" },
+{ PT_F47, "f47" }, { PT_F48, "f48" }, { PT_F49, "f49" },
+{ PT_F50, "f50" }, { PT_F51, "f51" }, { PT_F52, "f52" },
+{ PT_F53, "f53" }, { PT_F54, "f54" }, { PT_F55, "f55" },
+{ PT_F56, "f56" }, { PT_F57, "f57" }, { PT_F58, "f58" },
+{ PT_F59, "f59" }, { PT_F60, "f60" }, { PT_F61, "f61" },
+{ PT_F62, "f62" }, { PT_F63, "f63" }, { PT_F64, "f64" },
+{ PT_F65, "f65" }, { PT_F66, "f66" }, { PT_F67, "f67" },
+{ PT_F68, "f68" }, { PT_F69, "f69" }, { PT_F70, "f70" },
+{ PT_F71, "f71" }, { PT_F72, "f72" }, { PT_F73, "f73" },
+{ PT_F74, "f74" }, { PT_F75, "f75" }, { PT_F76, "f76" },
+{ PT_F77, "f77" }, { PT_F78, "f78" }, { PT_F79, "f79" },
+{ PT_F80, "f80" }, { PT_F81, "f81" }, { PT_F82, "f82" },
+{ PT_F83, "f83" }, { PT_F84, "f84" }, { PT_F85, "f85" },
+{ PT_F86, "f86" }, { PT_F87, "f87" }, { PT_F88, "f88" },
+{ PT_F89, "f89" }, { PT_F90, "f90" }, { PT_F91, "f91" },
+{ PT_F92, "f92" }, { PT_F93, "f93" }, { PT_F94, "f94" },
+{ PT_F95, "f95" }, { PT_F96, "f96" }, { PT_F97, "f97" },
+{ PT_F98, "f98" }, { PT_F99, "f99" }, { PT_F100, "f100" },
+{ PT_F101, "f101" }, { PT_F102, "f102" }, { PT_F103, "f103" },
+{ PT_F104, "f104" }, { PT_F105, "f105" }, { PT_F106, "f106" },
+{ PT_F107, "f107" }, { PT_F108, "f108" }, { PT_F109, "f109" },
+{ PT_F110, "f110" }, { PT_F111, "f111" }, { PT_F112, "f112" },
+{ PT_F113, "f113" }, { PT_F114, "f114" }, { PT_F115, "f115" },
+{ PT_F116, "f116" }, { PT_F117, "f117" }, { PT_F118, "f118" },
+{ PT_F119, "f119" }, { PT_F120, "f120" }, { PT_F121, "f121" },
+{ PT_F122, "f122" }, { PT_F123, "f123" }, { PT_F124, "f124" },
+{ PT_F125, "f125" }, { PT_F126, "f126" }, { PT_F127, "f127" },
+/* switch stack: */
+{ PT_F2, "f2" }, { PT_F3, "f3" }, { PT_F4, "f4" },
+{ PT_F5, "f5" }, { PT_F10, "f10" }, { PT_F11, "f11" },
+{ PT_F12, "f12" }, { PT_F13, "f13" }, { PT_F14, "f14" },
+{ PT_F15, "f15" }, { PT_F16, "f16" }, { PT_F17, "f17" },
+{ PT_F18, "f18" }, { PT_F19, "f19" }, { PT_F20, "f20" },
+{ PT_F21, "f21" }, { PT_F22, "f22" }, { PT_F23, "f23" },
+{ PT_F24, "f24" }, { PT_F25, "f25" }, { PT_F26, "f26" },
+{ PT_F27, "f27" }, { PT_F28, "f28" }, { PT_F29, "f29" },
+{ PT_F30, "f30" }, { PT_F31, "f31" }, { PT_R4, "r4" },
+{ PT_R5, "r5" }, { PT_R6, "r6" }, { PT_R7, "r7" },
+{ PT_B1, "b1" }, { PT_B2, "b2" }, { PT_B3, "b3" },
+{ PT_B4, "b4" }, { PT_B5, "b5" },
+{ PT_AR_EC, "ar.ec" }, { PT_AR_LC, "ar.lc" },
+/* pt_regs */
+{ PT_CR_IPSR, "psr" }, { PT_CR_IIP, "ip" },
+{ PT_CFM, "cfm" }, { PT_AR_UNAT, "ar.unat" },
+{ PT_AR_PFS, "ar.pfs" }, { PT_AR_RSC, "ar.rsc" },
+{ PT_AR_RNAT, "ar.rnat" }, { PT_AR_BSPSTORE, "ar.bspstore" },
+{ PT_PR, "pr" }, { PT_B6, "b6" }, { PT_AR_BSP, "ar.bsp" },
+{ PT_R1, "r1" }, { PT_R2, "r2" }, { PT_R3, "r3" },
+{ PT_R12, "r12" }, { PT_R13, "r13" }, { PT_R14, "r14" },
+{ PT_R15, "r15" }, { PT_R8, "r8" }, { PT_R9, "r9" },
+{ PT_R10, "r10" }, { PT_R11, "r11" }, { PT_R16, "r16" },
+{ PT_R17, "r17" }, { PT_R18, "r18" }, { PT_R19, "r19" },
+{ PT_R20, "r20" }, { PT_R21, "r21" }, { PT_R22, "r22" },
+{ PT_R23, "r23" }, { PT_R24, "r24" }, { PT_R25, "r25" },
+{ PT_R26, "r26" }, { PT_R27, "r27" }, { PT_R28, "r28" },
+{ PT_R29, "r29" }, { PT_R30, "r30" }, { PT_R31, "r31" },
+{ PT_AR_CCV, "ar.ccv" }, { PT_AR_FPSR, "ar.fpsr" },
+{ PT_B0, "b0" }, { PT_B7, "b7" }, { PT_F6, "f6" },
+{ PT_F7, "f7" }, { PT_F8, "f8" }, { PT_F9, "f9" },
+#ifdef PT_AR_CSD
+{ PT_AR_CSD, "ar.csd" },
+#endif
+#ifdef PT_AR_SSD
+{ PT_AR_SSD, "ar.ssd" },
+#endif
+{ PT_DBR, "dbr" }, { PT_IBR, "ibr" }, { PT_PMD, "pmd" },
+/* Other fields in "struct user" */
+#include "../userent0.h"
diff --git a/strace/linux/inet_diag.h b/strace/linux/inet_diag.h
new file mode 100644
index 0000000..723a1b1
--- /dev/null
+++ b/strace/linux/inet_diag.h
@@ -0,0 +1,38 @@
+#define TCPDIAG_GETSOCK 18
+#define DCCPDIAG_GETSOCK 19
+
+/* Socket identity */
+struct inet_diag_sockid {
+	uint16_t idiag_sport;
+	uint16_t idiag_dport;
+	uint32_t idiag_src[4];
+	uint32_t idiag_dst[4];
+	uint32_t idiag_if;
+	uint32_t idiag_cookie[2];
+};
+
+/* Request structure */
+struct inet_diag_req_v2 {
+	uint8_t sdiag_family;
+	uint8_t sdiag_protocol;
+	uint8_t idiag_ext;
+	uint8_t pad;
+	uint32_t idiag_states;
+	struct inet_diag_sockid id;
+};
+
+/* Info structure */
+struct inet_diag_msg {
+	uint8_t idiag_family;
+	uint8_t idiag_state;
+	uint8_t idiag_timer;
+	uint8_t idiag_retrans;
+
+	struct inet_diag_sockid id;
+
+	uint32_t idiag_expires;
+	uint32_t idiag_rqueue;
+	uint32_t idiag_wqueue;
+	uint32_t idiag_uid;
+	uint32_t idiag_inode;
+};
diff --git a/strace/linux/m68k/arch_regs.c b/strace/linux/m68k/arch_regs.c
new file mode 100644
index 0000000..8f0ab79
--- /dev/null
+++ b/strace/linux/m68k/arch_regs.c
@@ -0,0 +1,2 @@
+static long m68k_d0;
+#define ARCH_PC_PEEK_ADDR (4 * PT_PC)
diff --git a/strace/linux/m68k/arch_sigreturn.c b/strace/linux/m68k/arch_sigreturn.c
new file mode 100644
index 0000000..0011c17
--- /dev/null
+++ b/strace/linux/m68k/arch_sigreturn.c
@@ -0,0 +1,24 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	long addr;
+
+	if (upeek(tcp->pid, 4*PT_USP, &addr) < 0)
+		return;
+	/* Fetch pointer to struct sigcontext.  */
+	if (umove(tcp, addr + 2 * sizeof(int), &addr) < 0)
+		return;
+
+	unsigned long mask[NSIG / 8 / sizeof(long)];
+	/* Fetch first word of signal mask.  */
+	if (umove(tcp, addr, &mask[0]) < 0)
+		return;
+
+	/* Fetch remaining words of signal mask, located immediately before.  */
+	addr -= sizeof(mask) - sizeof(long);
+	if (umoven(tcp, addr, sizeof(mask) - sizeof(long), &mask[1]) < 0)
+		return;
+
+	tprintsigmask_addr("{mask=", mask);
+	tprints("}");
+}
diff --git a/strace/linux/m68k/get_error.c b/strace/linux/m68k/get_error.c
new file mode 100644
index 0000000..a792835
--- /dev/null
+++ b/strace/linux/m68k/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(m68k_d0)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -m68k_d0;
+	} else {
+		tcp->u_rval = m68k_d0;
+	}
+}
diff --git a/strace/linux/m68k/get_scno.c b/strace/linux/m68k/get_scno.c
new file mode 100644
index 0000000..716a761
--- /dev/null
+++ b/strace/linux/m68k/get_scno.c
@@ -0,0 +1,6 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	return upeek(tcp->pid, 4 * PT_ORIG_D0, &tcp->scno) < 0 ? -1 : 1;
+}
diff --git a/strace/linux/m68k/get_syscall_args.c b/strace/linux/m68k/get_syscall_args.c
new file mode 100644
index 0000000..bc69a19
--- /dev/null
+++ b/strace/linux/m68k/get_syscall_args.c
@@ -0,0 +1,11 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, (i < 5 ? i : i + 2)*4, &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/m68k/get_syscall_result.c b/strace/linux/m68k/get_syscall_result.c
new file mode 100644
index 0000000..005cf60
--- /dev/null
+++ b/strace/linux/m68k/get_syscall_result.c
@@ -0,0 +1,5 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return upeek(tcp->pid, 4 * PT_D0, &m68k_d0) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/m68k/ioctls_arch0.h b/strace/linux/m68k/ioctls_arch0.h
new file mode 100644
index 0000000..c8636ab
--- /dev/null
+++ b/strace/linux/m68k/ioctls_arch0.h
@@ -0,0 +1,24 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/m68k/include/ tree. */
+{ "asm/fbio.h", "FBIOGATTR", _IOC_READ, 0x4606, 0x58 },
+{ "asm/fbio.h", "FBIOGCURMAX", _IOC_READ, 0x461c, 0x04 },
+{ "asm/fbio.h", "FBIOGCURPOS", _IOC_WRITE, 0x461b, 0x04 },
+{ "asm/fbio.h", "FBIOGCURSOR", _IOC_READ|_IOC_WRITE, 0x4619, 0x2c },
+{ "asm/fbio.h", "FBIOGETCMAP", _IOC_WRITE, 0x4604, 0x14 },
+{ "asm/fbio.h", "FBIOGTYPE", _IOC_READ, 0x4600, 0x18 },
+{ "asm/fbio.h", "FBIOGVIDEO", _IOC_READ, 0x4608, 0x04 },
+{ "asm/fbio.h", "FBIOPUTCMAP", _IOC_WRITE, 0x4603, 0x14 },
+{ "asm/fbio.h", "FBIOSATTR", _IOC_WRITE, 0x4605, 0x58 },
+{ "asm/fbio.h", "FBIOSCURPOS", _IOC_WRITE, 0x461a, 0x04 },
+{ "asm/fbio.h", "FBIOSCURSOR", _IOC_WRITE, 0x4618, 0x2c },
+{ "asm/fbio.h", "FBIOSVIDEO", _IOC_WRITE, 0x4607, 0x04 },
+{ "asm/fbio.h", "FBIO_WID_ALLOC", _IOC_READ|_IOC_WRITE, 0x461e, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_FREE", _IOC_WRITE, 0x461f, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_GET", _IOC_READ|_IOC_WRITE, 0x4621, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_PUT", _IOC_WRITE, 0x4620, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTALLOC", _IOC_READ|_IOC_WRITE, 0x4c35, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTFREE", _IOC_WRITE, 0x4c36, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTPOST", _IOC_WRITE, 0x4c38, 0x1c },
+{ "asm/fbio.h", "LEO_CLUTREAD", _IOC_WRITE, 0x4c37, 0x1c },
+{ "asm/fbio.h", "LEO_GETGAMMA", _IOC_READ, 0x4c45, 0x04 },
+{ "asm/fbio.h", "LEO_SETGAMMA", _IOC_WRITE, 0x4c44, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", 0, 0x545E, 0 },
diff --git a/strace/linux/m68k/ioctls_inc0.h b/strace/linux/m68k/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/m68k/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/m68k/syscallent.h b/strace/linux/m68k/syscallent.h
new file mode 100644
index 0000000..0f4895c
--- /dev/null
+++ b/strace/linux/m68k/syscallent.h
@@ -0,0 +1,409 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"chown"			},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 1,	TD|TM|SI,	SEN(old_mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 1,	0,		SEN(vm86old),			"vm86old"		},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 4,	0,		SEN(cacheflush),		"cacheflush"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { 0,	0,		SEN(getpagesize),		"getpagesize"		},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 5,	TD,		SEN(pread),			"pread64"		},
+[181] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[193] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"chown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(geteuid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218 ... 219] = { },
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[222] = { 2,	TS,		SEN(kill),			"tkill"			},
+[223] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[224] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[225] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[226] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[227] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[228] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[229] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[230] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[231] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[232] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[233] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[234] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[235] = { 6,	0,		SEN(futex),			"futex"			},
+[236] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[237] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[238] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[239] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[240] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[241] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[242] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[243] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[244] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[245] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[246] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[247] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[248] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[249] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[250] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[251] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[252] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[253] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[254] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[255] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[256] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[257] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[258] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[259] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[260] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[261] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[262] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[263] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[264] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[265] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[266] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[267] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[268] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[269] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[270] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[271] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[272] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[273] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[274] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[275] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[276] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[277] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[278] = { 5,	0,		SEN(vserver),			"vserver"		},
+[279] = { 5,	0,		SEN(add_key),			"add_key"		},
+[280] = { 4,	0,		SEN(request_key),		"request_key"		},
+[281] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[282] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[283] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[284] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[285] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[286] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[287] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[288] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[289] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[290] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[291] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[292] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[293] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[294] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[295] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[296] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[297] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[298] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[299] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[300] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[301] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[302] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[303] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[304] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[305] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[306] = { 6,	TD,		SEN(splice),			"splice"		},
+[307] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[308] = { 4,	TD,		SEN(tee),			"tee"			},
+[309] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[310] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[311] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[312] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[313] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[314] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[315] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[316] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[317] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[318] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[319] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[320] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[321] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[322] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[323] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[324] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[325] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[326] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[327] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[328] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[329] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[330] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[331] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[332] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[333] = { 0,	0,		SEN(get_thread_area),		"get_thread_area"	},
+[334] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[335] = { 6,	0,		SEN(printargs),			"atomic_cmpxchg_32"	},
+[336] = { 0,	0,		SEN(printargs),			"atomic_barrier"	},
+[337] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[338] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[339] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[340] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[341] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[342] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[343] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[344] = { 2,	TD,		SEN(setns),			"setns"			},
+[345] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[346] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[347] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[348] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[349] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[350] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[351] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[352] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[353] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[354] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[355] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[356] = { 3,	TN,		SEN(socket),			"socket"		},
+[357] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[358] = { 3,	TN,		SEN(bind),			"bind"			},
+[359] = { 3,	TN,		SEN(connect),			"connect"		},
+[360] = { 2,	TN,		SEN(listen),			"listen"		},
+[361] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[362] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[363] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[364] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[365] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[366] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[367] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[368] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[369] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[370] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[371] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[372] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[373] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[374] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[375] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[376] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[377] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[378] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/m68k/userent.h b/strace/linux/m68k/userent.h
new file mode 100644
index 0000000..a17807e
--- /dev/null
+++ b/strace/linux/m68k/userent.h
@@ -0,0 +1,34 @@
+XLAT(4*PT_D1),
+XLAT(4*PT_D2),
+XLAT(4*PT_D3),
+XLAT(4*PT_D4),
+XLAT(4*PT_D5),
+XLAT(4*PT_D6),
+XLAT(4*PT_D7),
+XLAT(4*PT_A0),
+XLAT(4*PT_A1),
+XLAT(4*PT_A2),
+XLAT(4*PT_A3),
+XLAT(4*PT_A4),
+XLAT(4*PT_A5),
+XLAT(4*PT_A6),
+XLAT(4*PT_D0),
+XLAT(4*PT_USP),
+XLAT(4*PT_ORIG_D0),
+XLAT(4*PT_SR),
+XLAT(4*PT_PC),
+/* Other fields in "struct user" */
+XLAT_UOFF(u_fpvalid),
+XLAT_UOFF(m68kfp),
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(reserved),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(u_fpstate),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/metag/arch_regs.c b/strace/linux/metag/arch_regs.c
new file mode 100644
index 0000000..e9f0d78
--- /dev/null
+++ b/strace/linux/metag/arch_regs.c
@@ -0,0 +1,3 @@
+static struct user_gp_regs metag_regs;
+#define ARCH_REGS_FOR_GETREGSET metag_regs
+#define ARCH_PC_REG metag_regs.pc
diff --git a/strace/linux/metag/get_error.c b/strace/linux/metag/get_error.c
new file mode 100644
index 0000000..b7d287f
--- /dev/null
+++ b/strace/linux/metag/get_error.c
@@ -0,0 +1,11 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	/* result pointer in D0Re0 (D0.0) */
+	if (check_errno && is_negated_errno(metag_regs.dx[0][0])) {
+		tcp->u_rval = -1;
+		tcp->u_error = -metag_regs.dx[0][0];
+	} else {
+		tcp->u_rval = metag_regs.dx[0][0];
+	}
+}
diff --git a/strace/linux/metag/get_scno.c b/strace/linux/metag/get_scno.c
new file mode 100644
index 0000000..6dc2ab4
--- /dev/null
+++ b/strace/linux/metag/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = metag_regs.dx[0][1];  /* syscall number in D1Re0 (D1.0) */
+	return 1;
+}
diff --git a/strace/linux/metag/get_syscall_args.c b/strace/linux/metag/get_syscall_args.c
new file mode 100644
index 0000000..b7c10f4
--- /dev/null
+++ b/strace/linux/metag/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	unsigned int i;
+
+	for (i = 0; i < MAX_ARGS; i++) {
+		/* arguments go backwards from D1Ar1 (D1.3) */
+		tcp->u_arg[i] = ((unsigned long *)&metag_regs.dx[3][1])[-i];
+	}
+	return 1;
+}
diff --git a/strace/linux/metag/ioctls_arch0.h b/strace/linux/metag/ioctls_arch0.h
new file mode 100644
index 0000000..191bb36
--- /dev/null
+++ b/strace/linux/metag/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/metag/include/ tree. */
diff --git a/strace/linux/metag/ioctls_inc0.h b/strace/linux/metag/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/metag/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/metag/syscallent.h b/strace/linux/metag/syscallent.h
new file mode 100644
index 0000000..82ad55b
--- /dev/null
+++ b/strace/linux/metag/syscallent.h
@@ -0,0 +1,6 @@
+#include "32/syscallent.h"
+/* [244 ... 259] are arch specific */
+[245] = { 2,	0,	SEN(printargs),	"metag_setglobalbit"	},
+[246] = { 1,	0,	SEN(printargs),	"metag_set_fpu_flags"	},
+[247] = { 1,	0,	SEN(printargs),	"metag_set_tls"		},
+[248] = { 0,	NF,	SEN(printargs),	"metag_get_tls"		},
diff --git a/strace/linux/microblaze/arch_regs.c b/strace/linux/microblaze/arch_regs.c
new file mode 100644
index 0000000..c7bafab
--- /dev/null
+++ b/strace/linux/microblaze/arch_regs.c
@@ -0,0 +1,2 @@
+static long microblaze_r3;
+#define ARCH_PC_PEEK_ADDR PT_PC
diff --git a/strace/linux/microblaze/arch_sigreturn.c b/strace/linux/microblaze/arch_sigreturn.c
new file mode 100644
index 0000000..839c805
--- /dev/null
+++ b/strace/linux/microblaze/arch_sigreturn.c
@@ -0,0 +1,16 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	/* TODO: Verify that this is correct...  */
+
+	long addr;
+
+	/* Read r1, the stack pointer.  */
+	if (upeek(tcp->pid, 1 * 4, &addr) < 0)
+		return;
+	addr += offsetof(struct sigcontext, oldmask);
+
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/microblaze/get_error.c b/strace/linux/microblaze/get_error.c
new file mode 100644
index 0000000..878e24f
--- /dev/null
+++ b/strace/linux/microblaze/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(microblaze_r3)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -microblaze_r3;
+	} else {
+		tcp->u_rval = microblaze_r3;
+	}
+}
diff --git a/strace/linux/microblaze/get_scno.c b/strace/linux/microblaze/get_scno.c
new file mode 100644
index 0000000..6f98f83
--- /dev/null
+++ b/strace/linux/microblaze/get_scno.c
@@ -0,0 +1,6 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	return upeek(tcp->pid, 0, &tcp->scno) < 0 ? -1 : 1;
+}
diff --git a/strace/linux/microblaze/get_syscall_args.c b/strace/linux/microblaze/get_syscall_args.c
new file mode 100644
index 0000000..830c8c3
--- /dev/null
+++ b/strace/linux/microblaze/get_syscall_args.c
@@ -0,0 +1,11 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, (5 + i) * 4, &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/microblaze/get_syscall_result.c b/strace/linux/microblaze/get_syscall_result.c
new file mode 100644
index 0000000..9ece53e
--- /dev/null
+++ b/strace/linux/microblaze/get_syscall_result.c
@@ -0,0 +1,5 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return upeek(tcp->pid, 3 * 4, &microblaze_r3) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/microblaze/ioctls_arch0.h b/strace/linux/microblaze/ioctls_arch0.h
new file mode 100644
index 0000000..e310f8e
--- /dev/null
+++ b/strace/linux/microblaze/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/microblaze/include/ tree. */
diff --git a/strace/linux/microblaze/ioctls_inc0.h b/strace/linux/microblaze/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/microblaze/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/microblaze/syscallent.h b/strace/linux/microblaze/syscallent.h
new file mode 100644
index 0000000..482e275
--- /dev/null
+++ b/strace/linux/microblaze/syscallent.h
@@ -0,0 +1,419 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 1,	0,		SEN(vm86old),			"vm86old"		},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 6,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 3,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { 5,	0,		SEN(vm86),			"vm86"			},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 5,	TD,		SEN(pread),			"pread64"		},
+[181] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"chown"			},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[193] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(geteuid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"chown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[222 ... 223] = { },
+[224] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[225] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[226] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[227] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[228] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[229] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[230] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[231] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[232] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[233] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[234] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[235] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[236] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[237] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[238] = { 2,	TS,		SEN(kill),			"tkill"			},
+[239] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[240] = { 6,	0,		SEN(futex),			"futex"			},
+[241] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[242] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[243] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[244] = { 1,	0,		SEN(get_thread_area),		"get_thread_area"	},
+[245] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[246] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[247] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[248] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[249] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[250] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[251] = { },
+[252] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[253] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[254] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[255] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[256] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[257] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[258] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[259] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[260] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[261] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[262] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[263] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[264] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[265] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[266] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[267] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[268] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[269] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[270] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[271] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[272] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[273] = { 5,	0,		SEN(vserver),			"vserver"		},
+[274] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[275] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[276] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[277] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[278] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[279] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[280] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[281] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[282] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[283] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[284] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[285] = { },
+[286] = { 5,	0,		SEN(add_key),			"add_key"		},
+[287] = { 4,	0,		SEN(request_key),		"request_key"		},
+[288] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[289] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[290] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[291] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[292] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[293] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[294] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[295] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[296] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[297] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[298] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[299] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[300] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[301] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[302] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[303] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[304] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[305] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[306] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[307] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[308] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[309] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[310] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[311] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[312] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[313] = { 6,	TD,		SEN(splice),			"splice"		},
+[314] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[315] = { 4,	TD,		SEN(tee),			"tee"			},
+[316] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[317] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[318] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[319] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[320] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[321] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[322] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[323] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[324] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[325] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[326] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[327] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[328] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[329] = { 3,	TI,		SEN(semget),			"semget"		},
+[330] = { 3,	TI,		SEN(semop),			"semop"			},
+[331] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[332] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[333] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[334] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[335] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[336] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[337] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[338] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[339] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[340] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[341] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[342] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[343] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[344] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[345] = { 3,	TN,		SEN(socket),			"socket"		},
+[346] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[347] = { 3,	TN,		SEN(bind),			"bind"			},
+[348] = { 2,	TN,		SEN(listen),			"listen"		},
+[349] = { 3,	TN,		SEN(accept),			"accept"		},
+[350] = { 3,	TN,		SEN(connect),			"connect"		},
+[351] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[352] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[353] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[354] = { 4,	TN,		SEN(send),			"send"			},
+[355] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[356] = { 4,	TN,		SEN(recv),			"recv"			},
+[357] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[358] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[359] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[360] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[361] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[362] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[363] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[364] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[365] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[366] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[367] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[368] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[369] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[370] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[371] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[372] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[373] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[374] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[375] = { 2,	TD,		SEN(setns),			"setns"			},
+[376] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[377] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[378] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[379] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[380] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[381] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[382] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[383] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[384] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[385] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[386] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[387] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[388] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[389] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[390] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[391] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
diff --git a/strace/linux/microblaze/userent.h b/strace/linux/microblaze/userent.h
new file mode 100644
index 0000000..5b378d2
--- /dev/null
+++ b/strace/linux/microblaze/userent.h
@@ -0,0 +1,40 @@
+{ PT_GPR(0),		"r0" },
+{ PT_GPR(1),		"r1" },
+{ PT_GPR(2),		"r2" },
+{ PT_GPR(3),		"r3" },
+{ PT_GPR(4),		"r4" },
+{ PT_GPR(5),		"r5" },
+{ PT_GPR(6),		"r6" },
+{ PT_GPR(7),		"r7" },
+{ PT_GPR(8),		"r8" },
+{ PT_GPR(9),		"r9" },
+{ PT_GPR(10),		"r10" },
+{ PT_GPR(11),		"r11" },
+{ PT_GPR(12),		"r12" },
+{ PT_GPR(13),		"r13" },
+{ PT_GPR(14),		"r14" },
+{ PT_GPR(15),		"r15" },
+{ PT_GPR(16),		"r16" },
+{ PT_GPR(17),		"r17" },
+{ PT_GPR(18),		"r18" },
+{ PT_GPR(19),		"r19" },
+{ PT_GPR(20),		"r20" },
+{ PT_GPR(21),		"r21" },
+{ PT_GPR(22),		"r22" },
+{ PT_GPR(23),		"r23" },
+{ PT_GPR(24),		"r24" },
+{ PT_GPR(25),		"r25" },
+{ PT_GPR(26),		"r26" },
+{ PT_GPR(27),		"r27" },
+{ PT_GPR(28),		"r28" },
+{ PT_GPR(29),		"r29" },
+{ PT_GPR(30),		"r30" },
+{ PT_GPR(31),		"r31" },
+{ PT_PC,		"rpc", },
+{ PT_MSR,		"rmsr", },
+{ PT_EAR,		"rear", },
+{ PT_ESR,		"resr", },
+{ PT_FSR,		"rfsr", },
+{ PT_KERNEL_MODE,	"kernel_mode", },
+/* Other fields in "struct user" */
+#include "../userent0.h"
diff --git a/strace/linux/mips/arch_getrval2.c b/strace/linux/mips/arch_getrval2.c
new file mode 100644
index 0000000..332f270
--- /dev/null
+++ b/strace/linux/mips/arch_getrval2.c
@@ -0,0 +1,5 @@
+long
+getrval2(struct tcb *tcp)
+{
+	return mips_regs.uregs[3];
+}
diff --git a/strace/linux/mips/arch_regs.c b/strace/linux/mips/arch_regs.c
new file mode 100644
index 0000000..44f6bd5
--- /dev/null
+++ b/strace/linux/mips/arch_regs.c
@@ -0,0 +1,4 @@
+struct mips_regs mips_regs; /* not static */
+/* PTRACE_GETREGS on MIPS is available since linux v2.6.15. */
+#define ARCH_REGS_FOR_GETREGS mips_regs
+#define ARCH_PC_REG mips_REG_EPC
diff --git a/strace/linux/mips/arch_regs.h b/strace/linux/mips/arch_regs.h
new file mode 100644
index 0000000..6372bad
--- /dev/null
+++ b/strace/linux/mips/arch_regs.h
@@ -0,0 +1,18 @@
+struct mips_regs {
+	uint64_t uregs[38];
+};
+
+extern struct mips_regs mips_regs;
+
+#define REG_V0 2
+#define REG_A0 4
+
+#define mips_REG_V0 mips_regs.uregs[REG_V0]
+#define mips_REG_A0 mips_regs.uregs[REG_A0 + 0]
+#define mips_REG_A1 mips_regs.uregs[REG_A0 + 1]
+#define mips_REG_A2 mips_regs.uregs[REG_A0 + 2]
+#define mips_REG_A3 mips_regs.uregs[REG_A0 + 3]
+#define mips_REG_A4 mips_regs.uregs[REG_A0 + 4]
+#define mips_REG_A5 mips_regs.uregs[REG_A0 + 5]
+#define mips_REG_SP mips_regs.uregs[29]
+#define mips_REG_EPC mips_regs.uregs[34]
diff --git a/strace/linux/mips/arch_sigreturn.c b/strace/linux/mips/arch_sigreturn.c
new file mode 100644
index 0000000..3095fe5
--- /dev/null
+++ b/strace/linux/mips/arch_sigreturn.c
@@ -0,0 +1,26 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+#if defined LINUX_MIPSO32
+	/*
+	 * offsetof(struct sigframe, sf_mask) ==
+	 * sizeof(sf_ass) + sizeof(sf_pad) + sizeof(struct sigcontext)
+	 */
+	const long addr = mips_REG_SP + 6 * 4 +
+			  sizeof(struct sigcontext);
+#else
+	/*
+	 * This decodes rt_sigreturn.
+	 * The 64-bit ABIs do not have sigreturn.
+	 *
+	 * offsetof(struct rt_sigframe, rs_uc) ==
+	 * sizeof(sf_ass) + sizeof(sf_pad) + sizeof(struct siginfo)
+	 */
+	const long addr = mips_REG_SP + 6 * 4 + 128 +
+			  offsetof(struct ucontext, uc_sigmask);
+#endif
+
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/mips/errnoent.h b/strace/linux/mips/errnoent.h
new file mode 100644
index 0000000..a82f9c6
--- /dev/null
+++ b/strace/linux/mips/errnoent.h
@@ -0,0 +1,150 @@
+[  1] = "EPERM",
+[  2] = "ENOENT",
+[  3] = "ESRCH",
+[  4] = "EINTR",
+[  5] = "EIO",
+[  6] = "ENXIO",
+[  7] = "E2BIG",
+[  8] = "ENOEXEC",
+[  9] = "EBADF",
+[ 10] = "ECHILD",
+[ 11] = "EAGAIN",
+[ 12] = "ENOMEM",
+[ 13] = "EACCES",
+[ 14] = "EFAULT",
+[ 15] = "ENOTBLK",
+[ 16] = "EBUSY",
+[ 17] = "EEXIST",
+[ 18] = "EXDEV",
+[ 19] = "ENODEV",
+[ 20] = "ENOTDIR",
+[ 21] = "EISDIR",
+[ 22] = "EINVAL",
+[ 23] = "ENFILE",
+[ 24] = "EMFILE",
+[ 25] = "ENOTTY",
+[ 26] = "ETXTBSY",
+[ 27] = "EFBIG",
+[ 28] = "ENOSPC",
+[ 29] = "ESPIPE",
+[ 30] = "EROFS",
+[ 31] = "EMLINK",
+[ 32] = "EPIPE",
+[ 33] = "EDOM",
+[ 34] = "ERANGE",
+[ 35] = "ENOMSG",
+[ 36] = "EIDRM",
+[ 37] = "ECHRNG",
+[ 38] = "EL2NSYNC",
+[ 39] = "EL3HLT",
+[ 40] = "EL3RST",
+[ 41] = "ELNRNG",
+[ 42] = "EUNATCH",
+[ 43] = "ENOCSI",
+[ 44] = "EL2HLT",
+[ 45] = "EDEADLK",
+[ 46] = "ENOLCK",
+[ 50] = "EBADE",
+[ 51] = "EBADR",
+[ 52] = "EXFULL",
+[ 53] = "ENOANO",
+[ 54] = "EBADRQC",
+[ 55] = "EBADSLT",
+[ 56] = "EDEADLOCK",
+[ 59] = "EBFONT",
+[ 60] = "ENOSTR",
+[ 61] = "ENODATA",
+[ 62] = "ETIME",
+[ 63] = "ENOSR",
+[ 64] = "ENONET",
+[ 65] = "ENOPKG",
+[ 66] = "EREMOTE",
+[ 67] = "ENOLINK",
+[ 68] = "EADV",
+[ 69] = "ESRMNT",
+[ 70] = "ECOMM",
+[ 71] = "EPROTO",
+[ 73] = "EDOTDOT",
+[ 74] = "EMULTIHOP",
+[ 77] = "EBADMSG",
+[ 78] = "ENAMETOOLONG",
+[ 79] = "EOVERFLOW",
+[ 80] = "ENOTUNIQ",
+[ 81] = "EBADFD",
+[ 82] = "EREMCHG",
+[ 83] = "ELIBACC",
+[ 84] = "ELIBBAD",
+[ 85] = "ELIBSCN",
+[ 86] = "ELIBMAX",
+[ 87] = "ELIBEXEC",
+[ 88] = "EILSEQ",
+[ 89] = "ENOSYS",
+[ 90] = "ELOOP",
+[ 91] = "ERESTART",
+[ 92] = "ESTRPIPE",
+[ 93] = "ENOTEMPTY",
+[ 94] = "EUSERS",
+[ 95] = "ENOTSOCK",
+[ 96] = "EDESTADDRREQ",
+[ 97] = "EMSGSIZE",
+[ 98] = "EPROTOTYPE",
+[ 99] = "ENOPROTOOPT",
+[120] = "EPROTONOSUPPORT",
+[121] = "ESOCKTNOSUPPORT",
+[122] = "EOPNOTSUPP",
+[123] = "EPFNOSUPPORT",
+[124] = "EAFNOSUPPORT",
+[125] = "EADDRINUSE",
+[126] = "EADDRNOTAVAIL",
+[127] = "ENETDOWN",
+[128] = "ENETUNREACH",
+[129] = "ENETRESET",
+[130] = "ECONNABORTED",
+[131] = "ECONNRESET",
+[132] = "ENOBUFS",
+[133] = "EISCONN",
+[134] = "ENOTCONN",
+[135] = "EUCLEAN",
+[137] = "ENOTNAM",
+[138] = "ENAVAIL",
+[139] = "EISNAM",
+[140] = "EREMOTEIO",
+[141] = "EINIT",
+[142] = "EREMDEV",
+[143] = "ESHUTDOWN",
+[144] = "ETOOMANYREFS",
+[145] = "ETIMEDOUT",
+[146] = "ECONNREFUSED",
+[147] = "EHOSTDOWN",
+[148] = "EHOSTUNREACH",
+[149] = "EALREADY",
+[150] = "EINPROGRESS",
+[151] = "ESTALE",
+[158] = "ECANCELED",
+[159] = "ENOMEDIUM",
+[160] = "EMEDIUMTYPE",
+[161] = "ENOKEY",
+[162] = "EKEYEXPIRED",
+[163] = "EKEYREVOKED",
+[164] = "EKEYREJECTED",
+[165] = "EOWNERDEAD",
+[166] = "ENOTRECOVERABLE",
+[167] = "ERFKILL",
+[168] = "EHWPOISON",
+[512] = "ERESTARTSYS",
+[513] = "ERESTARTNOINTR",
+[514] = "ERESTARTNOHAND",
+[515] = "ENOIOCTLCMD",
+[516] = "ERESTART_RESTARTBLOCK",
+[517] = "EPROBE_DEFER",
+[518] = "EOPENSTALE",
+[521] = "EBADHANDLE",
+[522] = "ENOTSYNC",
+[523] = "EBADCOOKIE",
+[524] = "ENOTSUPP",
+[525] = "ETOOSMALL",
+[526] = "ESERVERFAULT",
+[527] = "EBADTYPE",
+[528] = "EJUKEBOX",
+[529] = "EIOCBQUEUED",
+[1133] = "EDQUOT",
diff --git a/strace/linux/mips/genstub.sh b/strace/linux/mips/genstub.sh
new file mode 100755
index 0000000..5ebb1d4
--- /dev/null
+++ b/strace/linux/mips/genstub.sh
@@ -0,0 +1,10 @@
+#!/bin/sh -e
+
+srcdir="${0%/*}"
+dstdir="$1"; shift
+
+for n in n32 n64 o32; do
+	in="$srcdir/syscallent-$n.h"
+	out="$dstdir/syscallent-$n-stub.h"
+	sed -n '/^#if/,/^#else/ {s/^\([^{]*{[^,]*,[^,]*,[[:space:]]*\)[^,[:space:]]\+,[[:space:]]*"\([^"]\+".*\)/\1SEN(printargs), "'$n'_\2/; s/^\[.*/&/p}' < "$in" > "$out"
+done
diff --git a/strace/linux/mips/get_error.c b/strace/linux/mips/get_error.c
new file mode 100644
index 0000000..42a282b
--- /dev/null
+++ b/strace/linux/mips/get_error.c
@@ -0,0 +1,14 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (mips_REG_A3) {
+		tcp->u_rval = -1;
+		tcp->u_error = mips_REG_V0;
+	} else {
+		tcp->u_rval = mips_REG_V0;
+#ifdef LINUX_MIPSN32
+		/* tcp->u_rval contains a truncated value */
+		tcp->u_lrval = mips_REG_V0;
+#endif
+	}
+}
diff --git a/strace/linux/mips/get_scno.c b/strace/linux/mips/get_scno.c
new file mode 100644
index 0000000..f9b5e7d
--- /dev/null
+++ b/strace/linux/mips/get_scno.c
@@ -0,0 +1,17 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = mips_REG_V0;
+
+	if (!SCNO_IN_RANGE(tcp->scno)) {
+		if (mips_REG_A3 == 0 || mips_REG_A3 == (uint64_t) -1) {
+			if (debug_flag)
+				error_msg("stray syscall exit: v0 = %ld",
+					  tcp->scno);
+			return 0;
+		}
+	}
+
+	return 1;
+}
diff --git a/strace/linux/mips/get_syscall_args.c b/strace/linux/mips/get_syscall_args.c
new file mode 100644
index 0000000..a20be8d
--- /dev/null
+++ b/strace/linux/mips/get_syscall_args.c
@@ -0,0 +1,34 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+#if defined LINUX_MIPSN64
+	tcp->u_arg[0] = mips_REG_A0;
+	tcp->u_arg[1] = mips_REG_A1;
+	tcp->u_arg[2] = mips_REG_A2;
+	tcp->u_arg[3] = mips_REG_A3;
+	tcp->u_arg[4] = mips_REG_A4;
+	tcp->u_arg[5] = mips_REG_A5;
+#elif defined LINUX_MIPSN32
+	tcp->u_arg[0] = tcp->ext_arg[0] = mips_REG_A0;
+	tcp->u_arg[1] = tcp->ext_arg[1] = mips_REG_A1;
+	tcp->u_arg[2] = tcp->ext_arg[2] = mips_REG_A2;
+	tcp->u_arg[3] = tcp->ext_arg[3] = mips_REG_A3;
+	tcp->u_arg[4] = tcp->ext_arg[4] = mips_REG_A4;
+	tcp->u_arg[5] = tcp->ext_arg[5] = mips_REG_A5;
+#elif defined LINUX_MIPSO32
+	tcp->u_arg[0] = mips_REG_A0;
+	tcp->u_arg[1] = mips_REG_A1;
+	tcp->u_arg[2] = mips_REG_A2;
+	tcp->u_arg[3] = mips_REG_A3;
+	if (tcp->s_ent->nargs > 4) {
+		if (umoven(tcp, mips_REG_SP + 4 * 4,
+			   (tcp->s_ent->nargs - 4) * sizeof(tcp->u_arg[0]),
+			   &tcp->u_arg[4]) < 0)
+			return -1;
+	}
+#else
+# error unsupported mips abi
+#endif
+	return 1;
+}
diff --git a/strace/linux/mips/ioctls_arch0.h b/strace/linux/mips/ioctls_arch0.h
new file mode 100644
index 0000000..966e9ae
--- /dev/null
+++ b/strace/linux/mips/ioctls_arch0.h
@@ -0,0 +1,82 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/mips/include/ tree. */
+{ "asm/ioctls.h", "FIOASYNC", 0, 0x667d, 0 },
+{ "asm/ioctls.h", "FIOCLEX", 0, 0x6601, 0 },
+{ "asm/ioctls.h", "FIONBIO", 0, 0x667e, 0 },
+{ "asm/ioctls.h", "FIONCLEX", 0, 0x6602, 0 },
+{ "asm/ioctls.h", "FIONREAD", 0, 0x467f, 0 },
+{ "asm/ioctls.h", "FIOQSIZE", 0, 0x667f, 0 },
+{ "asm/ioctls.h", "TCFLSH", 0, 0x5407, 0 },
+{ "asm/ioctls.h", "TCGETA", 0, 0x5401, 0 },
+{ "asm/ioctls.h", "TCGETS", 0, 0x540d, 0 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x30 },
+{ "asm/ioctls.h", "TCSBRK", 0, 0x5405, 0 },
+{ "asm/ioctls.h", "TCSBRKP", 0, 0x5486, 0 },
+{ "asm/ioctls.h", "TCSETA", 0, 0x5402, 0 },
+{ "asm/ioctls.h", "TCSETAF", 0, 0x5404, 0 },
+{ "asm/ioctls.h", "TCSETAW", 0, 0x5403, 0 },
+{ "asm/ioctls.h", "TCSETS", 0, 0x540e, 0 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x30 },
+{ "asm/ioctls.h", "TCSETSF", 0, 0x5410, 0 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x30 },
+{ "asm/ioctls.h", "TCSETSW", 0, 0x540f, 0 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x30 },
+{ "asm/ioctls.h", "TCXONC", 0, 0x5406, 0 },
+{ "asm/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm/ioctls.h", "TIOCCONS", _IOC_WRITE, 0x7478, 0x04 },
+{ "asm/ioctls.h", "TIOCEXCL", 0, 0x740d, 0 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", 0, 0x7400, 0 },
+{ "asm/ioctls.h", "TIOCGETP", 0, 0x7408, 0 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x5492, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x548b, 0 },
+{ "asm/ioctls.h", "TIOCGLTC", 0, 0x7474, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7477, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x542e, 0x20 },
+{ "asm/ioctls.h", "TIOCGSERIAL", 0, 0x5484, 0 },
+{ "asm/ioctls.h", "TIOCGSID", 0, 0x7416, 0 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", 0, 0x5481, 0 },
+{ "asm/ioctls.h", "TIOCGWINSZ", _IOC_READ, 0x7468, 0x08 },
+{ "asm/ioctls.h", "TIOCLINUX", 0, 0x5483, 0 },
+{ "asm/ioctls.h", "TIOCMBIC", 0, 0x741c, 0 },
+{ "asm/ioctls.h", "TIOCMBIS", 0, 0x741b, 0 },
+{ "asm/ioctls.h", "TIOCMGET", 0, 0x741d, 0 },
+{ "asm/ioctls.h", "TIOCMIWAIT", 0, 0x5491, 0 },
+{ "asm/ioctls.h", "TIOCMSET", 0, 0x741a, 0 },
+{ "asm/ioctls.h", "TIOCNOTTY", 0, 0x5471, 0 },
+{ "asm/ioctls.h", "TIOCNXCL", 0, 0x740e, 0 },
+{ "asm/ioctls.h", "TIOCOUTQ", 0, 0x7472, 0 },
+{ "asm/ioctls.h", "TIOCPKT", 0, 0x5470, 0 },
+{ "asm/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm/ioctls.h", "TIOCSCTTY", 0, 0x5480, 0 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", 0, 0x5488, 0 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", 0, 0x548e, 0 },
+{ "asm/ioctls.h", "TIOCSERGETMULTI", 0, 0x548f, 0 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x548d, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", 0, 0x5489, 0 },
+{ "asm/ioctls.h", "TIOCSERSETMULTI", 0, 0x5490, 0 },
+{ "asm/ioctls.h", "TIOCSERSWILD", 0, 0x548a, 0 },
+{ "asm/ioctls.h", "TIOCSETD", 0, 0x7401, 0 },
+{ "asm/ioctls.h", "TIOCSETN", 0, 0x740a, 0 },
+{ "asm/ioctls.h", "TIOCSETP", 0, 0x7409, 0 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x548c, 0 },
+{ "asm/ioctls.h", "TIOCSLTC", 0, 0x7475, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7476, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x542f, 0x20 },
+{ "asm/ioctls.h", "TIOCSSERIAL", 0, 0x5485, 0 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", 0, 0x5482, 0 },
+{ "asm/ioctls.h", "TIOCSTI", 0, 0x5472, 0 },
+{ "asm/ioctls.h", "TIOCSWINSZ", _IOC_WRITE, 0x7467, 0x08 },
+{ "asm/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm/sockios.h", "FIOGETOWN", _IOC_READ, 0x667b, 0x04 },
+{ "asm/sockios.h", "FIOSETOWN", _IOC_WRITE, 0x667c, 0x04 },
+{ "asm/sockios.h", "SIOCATMARK", _IOC_READ, 0x7307, 0x04 },
+{ "asm/sockios.h", "SIOCGPGRP", _IOC_READ, 0x7309, 0x04 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", _IOC_WRITE, 0x7308, 0x04 },
diff --git a/strace/linux/mips/ioctls_inc0.h b/strace/linux/mips/ioctls_inc0.h
new file mode 100644
index 0000000..c00687f
--- /dev/null
+++ b/strace/linux/mips/ioctls_inc0.h
@@ -0,0 +1,5 @@
+#ifdef LINUX_MIPSN64
+# include "64/ioctls_inc.h"
+#else
+# include "32/ioctls_inc.h"
+#endif
diff --git a/strace/linux/mips/signalent.h b/strace/linux/mips/signalent.h
new file mode 100644
index 0000000..d18e510
--- /dev/null
+++ b/strace/linux/mips/signalent.h
@@ -0,0 +1,33 @@
+	"SIG_0",	/* 0 */
+	"SIGHUP",	/* 1 */
+	"SIGINT",	/* 2 */
+	"SIGQUIT",	/* 3 */
+	"SIGILL",	/* 4 */
+	"SIGTRAP",	/* 5 */
+	"SIGIOT",	/* 6 */
+	"SIGEMT",	/* 7 */
+	"SIGFPE",	/* 8 */
+	"SIGKILL",	/* 9 */
+	"SIGBUS",	/* 10 */
+	"SIGSEGV",	/* 11 */
+	"SIGSYS",	/* 12 */
+	"SIGPIPE",	/* 13 */
+	"SIGALRM",	/* 14 */
+	"SIGTERM",	/* 15 */
+	"SIGUSR1",	/* 16 */
+	"SIGUSR2",	/* 17 */
+	"SIGCHLD",	/* 18 */
+	"SIGPWR",	/* 19 */
+	"SIGWINCH",	/* 20 */
+	"SIGURG",	/* 21 */
+	"SIGIO",	/* 22 */
+	"SIGSTOP",	/* 23 */
+	"SIGTSTP",	/* 24 */
+	"SIGCONT",	/* 25 */
+	"SIGTTIN",	/* 26 */
+	"SIGTTOU",	/* 27 */
+	"SIGVTALRM",	/* 28 */
+	"SIGPROF",	/* 29 */
+	"SIGXCPU",	/* 30 */
+	"SIGXFSZ",	/* 31 */
+	"SIGRTMIN",	/* 32 */
diff --git a/strace/linux/mips/syscallent-compat.h b/strace/linux/mips/syscallent-compat.h
new file mode 100644
index 0000000..82a373b
--- /dev/null
+++ b/strace/linux/mips/syscallent-compat.h
@@ -0,0 +1,700 @@
+[   0] = { 0,	0,	SEN(printargs),		"svr4_syscall"	},
+[   1] = { 0,	0,	SEN(printargs),		"svr4_exit"	},
+[   2] = { 0,	0,	SEN(printargs),		"svr4_fork"	},
+[   3] = { 0,	0,	SEN(printargs),		"svr4_read"	},
+[   4] = { 0,	0,	SEN(printargs),		"svr4_write"	},
+[   5] = { 0,	0,	SEN(printargs),		"svr4_open"	},
+[   6] = { 0,	0,	SEN(printargs),		"svr4_close"	},
+[   7] = { 0,	0,	SEN(printargs),		"svr4_wait"	},
+[   8] = { 0,	0,	SEN(printargs),		"svr4_creat"	},
+[   9] = { 0,	0,	SEN(printargs),		"svr4_link"	},
+[  10] = { 0,	0,	SEN(printargs),		"svr4_unlink"	},
+[  11] = { 0,	0,	SEN(printargs),		"svr4_exec"	},
+[  12] = { 0,	0,	SEN(printargs),		"svr4_chdir"	},
+[  13] = { 0,	0,	SEN(printargs),		"svr4_gtime"	},
+[  14] = { 0,	0,	SEN(printargs),		"svr4_mknod"	},
+[  15] = { 0,	0,	SEN(printargs),		"svr4_chmod"	},
+[  16] = { 0,	0,	SEN(printargs),		"svr4_chown"	},
+[  17] = { 0,	TM,	SEN(printargs),		"svr4_sbreak"	},
+[  18] = { 0,	0,	SEN(printargs),		"svr4_stat"	},
+[  19] = { 0,	0,	SEN(printargs),		"svr4_lseek"	},
+[  20] = { 0,	0,	SEN(printargs),		"svr4_getpid"	},
+[  21] = { 0,	0,	SEN(printargs),		"svr4_mount"	},
+[  22] = { 0,	0,	SEN(printargs),		"svr4_umount"	},
+[  23] = { 0,	0,	SEN(printargs),		"svr4_setuid"	},
+[  24] = { 0,	0,	SEN(printargs),		"svr4_getuid"	},
+[  25] = { 0,	0,	SEN(printargs),		"svr4_stime"	},
+[  26] = { 0,	0,	SEN(printargs),		"svr4_ptrace"	},
+[  27] = { 0,	0,	SEN(printargs),		"svr4_alarm"	},
+[  28] = { 0,	0,	SEN(printargs),		"svr4_fstat"	},
+[  29] = { 0,	0,	SEN(printargs),		"svr4_pause"	},
+[  30] = { 0,	0,	SEN(printargs),		"svr4_utime"	},
+[  31] = { 0,	0,	SEN(printargs),		"svr4_stty"	},
+[  32] = { 0,	0,	SEN(printargs),		"svr4_gtty"	},
+[  33] = { 0,	0,	SEN(printargs),		"svr4_access"	},
+[  34] = { 0,	0,	SEN(printargs),		"svr4_nice"	},
+[  35] = { 0,	0,	SEN(printargs),		"svr4_statfs"	},
+[  36] = { 0,	0,	SEN(printargs),		"svr4_sync"	},
+[  37] = { 0,	0,	SEN(printargs),		"svr4_kill"	},
+[  38] = { 0,	0,	SEN(printargs),		"svr4_fstatfs"	},
+[  39] = { 0,	0,	SEN(printargs),		"svr4_setpgrp"	},
+[  40] = { 0,	0,	SEN(printargs),		"svr4_cxenix"	},
+[  41] = { 0,	0,	SEN(printargs),		"svr4_dup"	},
+[  42] = { 0,	0,	SEN(printargs),		"svr4_pipe"	},
+[  43] = { 0,	0,	SEN(printargs),		"svr4_times"	},
+[  44] = { 0,	0,	SEN(printargs),		"svr4_profil"	},
+[  45] = { 0,	0,	SEN(printargs),		"svr4_plock"	},
+[  46] = { 0,	0,	SEN(printargs),		"svr4_setgid"	},
+[  47] = { 0,	0,	SEN(printargs),		"svr4_getgid"	},
+[  48] = { 0,	0,	SEN(printargs),		"svr4_sig"	},
+[  49] = { 0,	0,	SEN(printargs),		"svr4_msgsys"	},
+[  50] = { 0,	0,	SEN(printargs),		"svr4_sysmips"	},
+[  51] = { 0,	0,	SEN(printargs),		"svr4_sysacct"	},
+[  52] = { 0,	0,	SEN(printargs),		"svr4_shmsys"	},
+[  53] = { 0,	0,	SEN(printargs),		"svr4_semsys"	},
+[  54] = { 0,	0,	SEN(printargs),		"svr4_ioctl"	},
+[  55] = { 0,	0,	SEN(printargs),		"svr4_uadmin"	},
+[  56] = { 0,	0,	SEN(printargs),		"svr4_exch"	},
+[  57] = { 0,	0,	SEN(printargs),		"svr4_utssys"	},
+[  58] = { 0,	0,	SEN(printargs),		"svr4_fsync"	},
+[  59] = { 0,	0,	SEN(printargs),		"svr4_exece"	},
+[  60] = { 0,	0,	SEN(printargs),		"svr4_umask"	},
+[  61] = { 0,	0,	SEN(printargs),		"svr4_chroot"	},
+[  62] = { 0,	0,	SEN(printargs),		"svr4_fcntl"	},
+[  63] = { 0,	0,	SEN(printargs),		"svr4_ulimit"	},
+[64 ... 69] = { },
+[  70] = { 0,	0,	SEN(printargs),		"svr4_advfs"	},
+[  71] = { 0,	0,	SEN(printargs),		"svr4_unadvfs"	},
+[  72] = { },
+[  73] = { },
+[  74] = { 0,	0,	SEN(printargs),		"svr4_rfstart"	},
+[  75] = { },
+[  76] = { 0,	0,	SEN(printargs),		"svr4_rdebug"	},
+[  77] = { 0,	0,	SEN(printargs),		"svr4_rfstop"	},
+[  78] = { 0,	0,	SEN(printargs),		"svr4_rfsys"	},
+[  79] = { 0,	0,	SEN(printargs),		"svr4_rmdir"	},
+[  80] = { 0,	0,	SEN(printargs),		"svr4_mkdir"	},
+[  81] = { 0,	0,	SEN(printargs),		"svr4_getdents"	},
+[  82] = { 0,	0,	SEN(printargs),		"svr4_libattach"	},
+[  83] = { 0,	0,	SEN(printargs),		"svr4_libdetach"	},
+[  84] = { 0,	0,	SEN(printargs),		"svr4_sysfs"	},
+[  85] = { 0,	0,	SEN(printargs),		"svr4_getmsg"	},
+[  86] = { 0,	0,	SEN(printargs),		"svr4_putmsg"	},
+[  87] = { 0,	0,	SEN(printargs),		"svr4_poll"	},
+[  88] = { 0,	0,	SEN(printargs),		"svr4_lstat"	},
+[  89] = { 0,	0,	SEN(printargs),		"svr4_symlink"	},
+[  90] = { 0,	0,	SEN(printargs),		"svr4_readlink"	},
+[  91] = { 0,	0,	SEN(printargs),		"svr4_setgroups"	},
+[  92] = { 0,	0,	SEN(printargs),		"svr4_getgroups"	},
+[  93] = { 0,	0,	SEN(printargs),		"svr4_fchmod"	},
+[  94] = { 0,	0,	SEN(printargs),		"svr4_fchown"	},
+[  95] = { 0,	0,	SEN(printargs),		"svr4_sigprocmask"	},
+[  96] = { 0,	0,	SEN(printargs),		"svr4_sigsuspend"	},
+[  97] = { 0,	0,	SEN(printargs),		"svr4_sigaltstack"	},
+[  98] = { 0,	0,	SEN(printargs),		"svr4_sigaction"	},
+[  99] = { 0,	0,	SEN(printargs),		"svr4_sigpending"	},
+[ 100] = { 0,	0,	SEN(printargs),		"svr4_setcontext"	},
+[ 101] = { 0,	0,	SEN(printargs),		"svr4_evsys"	},
+[ 102] = { 0,	0,	SEN(printargs),		"svr4_evtrapret"	},
+[ 103] = { 0,	0,	SEN(printargs),		"svr4_statvfs"	},
+[ 104] = { 0,	0,	SEN(printargs),		"svr4_fstatvfs"	},
+[ 105] = { },
+[ 106] = { 0,	0,	SEN(printargs),		"svr4_nfssys"	},
+[ 107] = { 0,	0,	SEN(printargs),		"svr4_waitid"	},
+[ 108] = { 0,	0,	SEN(printargs),		"svr4_sigsendset"	},
+[ 109] = { 0,	0,	SEN(printargs),		"svr4_hrtsys"	},
+[ 110] = { 0,	0,	SEN(printargs),		"svr4_acancel"	},
+[ 111] = { 0,	0,	SEN(printargs),		"svr4_async"	},
+[ 112] = { 0,	0,	SEN(printargs),		"svr4_priocntlset"	},
+[ 113] = { 0,	0,	SEN(printargs),		"svr4_pathconf"	},
+[ 114] = { 0,	TM,	SEN(printargs),		"svr4_mincore"	},
+[ 115] = { 0,	TD|TM|SI,	SEN(printargs),		"svr4_mmap"	},
+[ 116] = { 0,	TM|SI,	SEN(printargs),		"svr4_mprotect"	},
+[ 117] = { 0,	TM|SI,	SEN(printargs),		"svr4_munmap"	},
+[ 118] = { 0,	0,	SEN(printargs),		"svr4_fpathconf"	},
+[ 119] = { 0,	0,	SEN(printargs),		"svr4_vfork"	},
+[ 120] = { 0,	0,	SEN(printargs),		"svr4_fchdir"	},
+[ 121] = { 0,	0,	SEN(printargs),		"svr4_readv"	},
+[ 122] = { 0,	0,	SEN(printargs),		"svr4_writev"	},
+[ 123] = { 0,	0,	SEN(printargs),		"svr4_xstat"	},
+[ 124] = { 0,	0,	SEN(printargs),		"svr4_lxstat"	},
+[ 125] = { 0,	0,	SEN(printargs),		"svr4_fxstat"	},
+[ 126] = { 0,	0,	SEN(printargs),		"svr4_xmknod"	},
+[ 127] = { 0,	0,	SEN(printargs),		"svr4_clocal"	},
+[ 128] = { 0,	0,	SEN(printargs),		"svr4_setrlimit"	},
+[ 129] = { 0,	0,	SEN(printargs),		"svr4_getrlimit"	},
+[ 130] = { 0,	0,	SEN(printargs),		"svr4_lchown"	},
+[ 131] = { 0,	0,	SEN(printargs),		"svr4_memcntl"	},
+[ 132] = { 0,	0,	SEN(printargs),		"svr4_getpmsg"	},
+[ 133] = { 0,	0,	SEN(printargs),		"svr4_putpmsg"	},
+[ 134] = { 0,	0,	SEN(printargs),		"svr4_rename"	},
+[ 135] = { 0,	0,	SEN(printargs),		"svr4_nuname"	},
+[ 136] = { 0,	0,	SEN(printargs),		"svr4_setegid"	},
+[ 137] = { 0,	0,	SEN(printargs),		"svr4_sysconf"	},
+[ 138] = { 0,	0,	SEN(printargs),		"svr4_adjtime"	},
+[ 139] = { 0,	0,	SEN(printargs),		"svr4_sysinfo"	},
+[ 140] = { },
+[ 141] = { 0,	0,	SEN(printargs),		"svr4_seteuid"	},
+[ 142] = { 0,	0,	SEN(printargs),		"svr4_PYRAMID_statis"	},
+[ 143] = { 0,	0,	SEN(printargs),		"svr4_PYRAMID_tuning"	},
+[ 144] = { 0,	0,	SEN(printargs),		"svr4_PYRAMID_forcerr"	},
+[ 145] = { 0,	0,	SEN(printargs),		"svr4_PYRAMID_mpcntl"	},
+[146 ... 200] = { },
+[ 201] = { 0,	0,	SEN(printargs),		"svr4_aread"	},
+[ 202] = { 0,	0,	SEN(printargs),		"svr4_awrite"	},
+[ 203] = { 0,	0,	SEN(printargs),		"svr4_listio"	},
+[ 204] = { 0,	0,	SEN(printargs),		"svr4_mips_acancel"	},
+[ 205] = { 0,	0,	SEN(printargs),		"svr4_astatus"	},
+[ 206] = { 0,	0,	SEN(printargs),		"svr4_await"	},
+[ 207] = { 0,	0,	SEN(printargs),		"svr4_areadv"	},
+[ 208] = { 0,	0,	SEN(printargs),		"svr4_awritev"	},
+
+[1000] = { 0,	0,	SEN(printargs),		"sysv_syscall"	}, /* start of SYSV */
+[1001] = { 0,	0,	SEN(printargs),		"sysv_exit"	},
+[1002] = { 0,	0,	SEN(printargs),		"sysv_fork"	},
+[1003] = { 0,	0,	SEN(printargs),		"sysv_read"	},
+[1004] = { 0,	0,	SEN(printargs),		"sysv_write"	},
+[1005] = { 0,	0,	SEN(printargs),		"sysv_open"	},
+[1006] = { 0,	0,	SEN(printargs),		"sysv_close"	},
+[1007] = { 0,	0,	SEN(printargs),		"sysv_wait"	},
+[1008] = { 0,	0,	SEN(printargs),		"sysv_creat"	},
+[1009] = { 0,	0,	SEN(printargs),		"sysv_link"	},
+[1010] = { 0,	0,	SEN(printargs),		"sysv_unlink"	},
+[1011] = { 0,	0,	SEN(printargs),		"sysv_execv"	},
+[1012] = { 0,	0,	SEN(printargs),		"sysv_chdir"	},
+[1013] = { 0,	0,	SEN(printargs),		"sysv_time"	},
+[1014] = { 0,	0,	SEN(printargs),		"sysv_mknod"	},
+[1015] = { 0,	0,	SEN(printargs),		"sysv_chmod"	},
+[1016] = { 0,	0,	SEN(printargs),		"sysv_chown"	},
+[1017] = { 0,	TM|SI,	SEN(printargs),		"sysv_brk"	},
+[1018] = { 0,	0,	SEN(printargs),		"sysv_stat"	},
+[1019] = { 0,	0,	SEN(printargs),		"sysv_lseek"	},
+[1020] = { 0,	0,	SEN(printargs),		"sysv_getpid"	},
+[1021] = { 0,	0,	SEN(printargs),		"sysv_mount"	},
+[1022] = { 0,	0,	SEN(printargs),		"sysv_umount"	},
+[1023] = { 0,	0,	SEN(printargs),		"sysv_setuid"	},
+[1024] = { 0,	0,	SEN(printargs),		"sysv_getuid"	},
+[1025] = { 0,	0,	SEN(printargs),		"sysv_stime"	},
+[1026] = { 0,	0,	SEN(printargs),		"sysv_ptrace"	},
+[1027] = { 0,	0,	SEN(printargs),		"sysv_alarm"	},
+[1028] = { 0,	0,	SEN(printargs),		"sysv_fstat"	},
+[1029] = { 0,	0,	SEN(printargs),		"sysv_pause"	},
+[1030] = { 0,	0,	SEN(printargs),		"sysv_utime"	},
+[1031] = { 0,	0,	SEN(printargs),		"sysv_stty"	},
+[1032] = { 0,	0,	SEN(printargs),		"sysv_gtty"	},
+[1033] = { 0,	0,	SEN(printargs),		"sysv_access"	},
+[1034] = { 0,	0,	SEN(printargs),		"sysv_nice"	},
+[1035] = { 0,	0,	SEN(printargs),		"sysv_statfs"	},
+[1036] = { 0,	0,	SEN(printargs),		"sysv_sync"	},
+[1037] = { 0,	0,	SEN(printargs),		"sysv_kill"	},
+[1038] = { 0,	0,	SEN(printargs),		"sysv_fstatfs"	},
+[1039] = { 0,	0,	SEN(printargs),		"sysv_setpgrp"	},
+[1040] = { 0,	0,	SEN(printargs),		"sysv_syssgi"	},
+[1041] = { 0,	0,	SEN(printargs),		"sysv_dup"	},
+[1042] = { 0,	0,	SEN(printargs),		"sysv_pipe"	},
+[1043] = { 0,	0,	SEN(printargs),		"sysv_times"	},
+[1044] = { 0,	0,	SEN(printargs),		"sysv_profil"	},
+[1045] = { 0,	0,	SEN(printargs),		"sysv_plock"	},
+[1046] = { 0,	0,	SEN(printargs),		"sysv_setgid"	},
+[1047] = { 0,	0,	SEN(printargs),		"sysv_getgid"	},
+[1048] = { 0,	0,	SEN(printargs),		"sysv_sig"	},
+[1049] = { 0,	0,	SEN(printargs),		"sysv_msgsys"	},
+[1050] = { 0,	0,	SEN(printargs),		"sysv_sysmips"	},
+[1051] = { 0,	0,	SEN(printargs),		"sysv_acct"	},
+[1052] = { 0,	0,	SEN(printargs),		"sysv_shmsys"	},
+[1053] = { 0,	0,	SEN(printargs),		"sysv_semsys"	},
+[1054] = { 0,	0,	SEN(printargs),		"sysv_ioctl"	},
+[1055] = { 0,	0,	SEN(printargs),		"sysv_uadmin"	},
+[1056] = { 0,	0,	SEN(printargs),		"sysv_sysmp"	},
+[1057] = { 0,	0,	SEN(printargs),		"sysv_utssys"	},
+[1058] = { },
+[1059] = { 0,	0,	SEN(printargs),		"sysv_execve"	},
+[1060] = { 0,	0,	SEN(printargs),		"sysv_umask"	},
+[1061] = { 0,	0,	SEN(printargs),		"sysv_chroot"	},
+[1062] = { 0,	0,	SEN(printargs),		"sysv_fcntl"	},
+[1063] = { 0,	0,	SEN(printargs),		"sysv_ulimit"	},
+[1064 ... 1069] = { },
+[1070] = { 0,	0,	SEN(printargs),		"sysv_advfs"	},
+[1071] = { 0,	0,	SEN(printargs),		"sysv_unadvfs"	},
+[1072] = { 0,	0,	SEN(printargs),		"sysv_rmount"	},
+[1073] = { 0,	0,	SEN(printargs),		"sysv_rumount"	},
+[1074] = { 0,	0,	SEN(printargs),		"sysv_rfstart"	},
+[1075] = { 0,	0,	SEN(printargs),		"sysv_getrlimit64"	},
+[1076] = { 0,	0,	SEN(printargs),		"sysv_setrlimit64"	},
+[1077] = { 0,	0,	SEN(printargs),		"sysv_nanosleep"	},
+[1078] = { 0,	0,	SEN(printargs),		"sysv_lseek64"	},
+[1079] = { 0,	0,	SEN(printargs),		"sysv_rmdir"	},
+[1080] = { 0,	0,	SEN(printargs),		"sysv_mkdir"	},
+[1081] = { 0,	0,	SEN(printargs),		"sysv_getdents"	},
+[1082] = { 0,	0,	SEN(printargs),		"sysv_sginap"	},
+[1083] = { 0,	0,	SEN(printargs),		"sysv_sgikopt"	},
+[1084] = { 0,	0,	SEN(printargs),		"sysv_sysfs"	},
+[1085] = { 0,	0,	SEN(printargs),		"sysv_getmsg"	},
+[1086] = { 0,	0,	SEN(printargs),		"sysv_putmsg"	},
+[1087] = { 0,	0,	SEN(printargs),		"sysv_poll"	},
+[1088] = { 0,	0,	SEN(printargs),		"sysv_sigreturn"	},
+[1089] = { 0,	0,	SEN(printargs),		"sysv_accept"	},
+[1090] = { 0,	0,	SEN(printargs),		"sysv_bind"	},
+[1091] = { 0,	0,	SEN(printargs),		"sysv_connect"	},
+[1092] = { 0,	0,	SEN(printargs),		"sysv_gethostid"	},
+[1093] = { 0,	0,	SEN(printargs),		"sysv_getpeername"	},
+[1094] = { 0,	0,	SEN(printargs),		"sysv_getsockname"	},
+[1095] = { 0,	0,	SEN(printargs),		"sysv_getsockopt"	},
+[1096] = { 0,	0,	SEN(printargs),		"sysv_listen"	},
+[1097] = { 0,	0,	SEN(printargs),		"sysv_recv"	},
+[1098] = { 0,	0,	SEN(printargs),		"sysv_recvfrom"	},
+[1099] = { 0,	0,	SEN(printargs),		"sysv_recvmsg"	},
+[1100] = { 0,	0,	SEN(printargs),		"sysv_select"	},
+[1101] = { 0,	0,	SEN(printargs),		"sysv_send"	},
+[1102] = { 0,	0,	SEN(printargs),		"sysv_sendmsg"	},
+[1103] = { 0,	0,	SEN(printargs),		"sysv_sendto"	},
+[1104] = { 0,	0,	SEN(printargs),		"sysv_sethostid"	},
+[1105] = { 0,	0,	SEN(printargs),		"sysv_setsockopt"	},
+[1106] = { 0,	0,	SEN(printargs),		"sysv_shutdown"	},
+[1107] = { 0,	0,	SEN(printargs),		"sysv_socket"	},
+[1108] = { 0,	0,	SEN(printargs),		"sysv_gethostname"	},
+[1109] = { 0,	0,	SEN(printargs),		"sysv_sethostname"	},
+[1110] = { 0,	0,	SEN(printargs),		"sysv_getdomainname"	},
+[1111] = { 0,	0,	SEN(printargs),		"sysv_setdomainname"	},
+[1112] = { 0,	0,	SEN(printargs),		"sysv_truncate"	},
+[1113] = { 0,	0,	SEN(printargs),		"sysv_ftruncate"	},
+[1114] = { 0,	0,	SEN(printargs),		"sysv_rename"	},
+[1115] = { 0,	0,	SEN(printargs),		"sysv_symlink"	},
+[1116] = { 0,	0,	SEN(printargs),		"sysv_readlink"	},
+[1117] = { 0,	0,	SEN(printargs),		"sysv_lstat"	},
+[1118] = { 0,	0,	SEN(printargs),		"sysv_nfsmount"	},
+[1119] = { 0,	0,	SEN(printargs),		"sysv_nfssvc"	},
+[1120] = { 0,	0,	SEN(printargs),		"sysv_getfh"	},
+[1121] = { 0,	0,	SEN(printargs),		"sysv_async_daemon"	},
+[1122] = { 0,	0,	SEN(printargs),		"sysv_exportfs"	},
+[1123] = { 0,	0,	SEN(printargs),		"sysv_setregid"	},
+[1124] = { 0,	0,	SEN(printargs),		"sysv_setreuid"	},
+[1125] = { 0,	0,	SEN(printargs),		"sysv_getitimer"	},
+[1126] = { 0,	0,	SEN(printargs),		"sysv_setitimer"	},
+[1127] = { 0,	0,	SEN(printargs),		"sysv_adjtime"	},
+[1128] = { 0,	0,	SEN(printargs),		"sysv_BSD_getime"	},
+[1129] = { 0,	0,	SEN(printargs),		"sysv_sproc"	},
+[1130] = { 0,	0,	SEN(printargs),		"sysv_prctl"	},
+[1131] = { 0,	0,	SEN(printargs),		"sysv_procblk"	},
+[1132] = { 0,	0,	SEN(printargs),		"sysv_sprocsp"	},
+[1133] = { 0,	0,	SEN(printargs),		"sysv_sgigsc"	},
+[1134] = { 0,	TD|TM|SI,	SEN(printargs),		"sysv_mmap"	},
+[1135] = { 0,	TM|SI,	SEN(printargs),		"sysv_munmap"	},
+[1136] = { 0,	TM|SI,	SEN(printargs),		"sysv_mprotect"	},
+[1137] = { 0,	TM,	SEN(printargs),		"sysv_msync"	},
+[1138] = { 0,	TM,	SEN(printargs),		"sysv_madvise"	},
+[1139] = { 0,	0,	SEN(printargs),		"sysv_pagelock"	},
+[1140] = { 0,	0,	SEN(printargs),		"sysv_getpagesize"	},
+[1141] = { 0,	TF,	SEN(printargs),		"sysv_quotactl"	},
+[1142] = { 0,	0,	SEN(printargs),		"sysv_libdetach"	},
+[1143] = { 0,	0,	SEN(printargs),		"sysv_BSDgetpgrp"	},
+[1144] = { 0,	0,	SEN(printargs),		"sysv_BSDsetpgrp"	},
+[1145] = { 0,	0,	SEN(printargs),		"sysv_vhangup"	},
+[1146] = { 0,	0,	SEN(printargs),		"sysv_fsync"	},
+[1147] = { 0,	0,	SEN(printargs),		"sysv_fchdir"	},
+[1148] = { 0,	0,	SEN(printargs),		"sysv_getrlimit"	},
+[1149] = { 0,	0,	SEN(printargs),		"sysv_setrlimit"	},
+[1150] = { 0,	0,	SEN(printargs),		"sysv_cacheflush"	},
+[1151] = { 0,	0,	SEN(printargs),		"sysv_cachectl"	},
+[1152] = { 0,	0,	SEN(printargs),		"sysv_fchown"	},
+[1153] = { 0,	0,	SEN(printargs),		"sysv_fchmod"	},
+[1154] = { 0,	0,	SEN(printargs),		"sysv_wait3"	},
+[1155] = { 0,	0,	SEN(printargs),		"sysv_socketpair"	},
+[1156] = { 0,	0,	SEN(printargs),		"sysv_sysinfo"	},
+[1157] = { 0,	0,	SEN(printargs),		"sysv_nuname"	},
+[1158] = { 0,	0,	SEN(printargs),		"sysv_xstat"	},
+[1159] = { 0,	0,	SEN(printargs),		"sysv_lxstat"	},
+[1160] = { 0,	0,	SEN(printargs),		"sysv_fxstat"	},
+[1161] = { 0,	0,	SEN(printargs),		"sysv_xmknod"	},
+[1162] = { 0,	0,	SEN(printargs),		"sysv_ksigaction"	},
+[1163] = { 0,	0,	SEN(printargs),		"sysv_sigpending"	},
+[1164] = { 0,	0,	SEN(printargs),		"sysv_sigprocmask"	},
+[1165] = { 0,	0,	SEN(printargs),		"sysv_sigsuspend"	},
+[1166] = { 0,	0,	SEN(printargs),		"sysv_sigpoll"	},
+[1167] = { 0,	0,	SEN(printargs),		"sysv_swapctl"	},
+[1168] = { 0,	0,	SEN(printargs),		"sysv_getcontext"	},
+[1169] = { 0,	0,	SEN(printargs),		"sysv_setcontext"	},
+[1170] = { 0,	0,	SEN(printargs),		"sysv_waitsys"	},
+[1171] = { 0,	0,	SEN(printargs),		"sysv_sigstack"	},
+[1172] = { 0,	0,	SEN(printargs),		"sysv_sigaltstack"	},
+[1173] = { 0,	0,	SEN(printargs),		"sysv_sigsendset"	},
+[1174] = { 0,	0,	SEN(printargs),		"sysv_statvfs"	},
+[1175] = { 0,	0,	SEN(printargs),		"sysv_fstatvfs"	},
+[1176] = { 0,	0,	SEN(printargs),		"sysv_getpmsg"	},
+[1177] = { 0,	0,	SEN(printargs),		"sysv_putpmsg"	},
+[1178] = { 0,	0,	SEN(printargs),		"sysv_lchown"	},
+[1179] = { 0,	0,	SEN(printargs),		"sysv_priocntl"	},
+[1180] = { 0,	0,	SEN(printargs),		"sysv_ksigqueue"	},
+[1181] = { 0,	0,	SEN(printargs),		"sysv_readv"	},
+[1182] = { 0,	0,	SEN(printargs),		"sysv_writev"	},
+[1183] = { 0,	0,	SEN(printargs),		"sysv_truncate64"	},
+[1184] = { 0,	0,	SEN(printargs),		"sysv_ftruncate64"	},
+[1185] = { 0,	TD|TM|SI,	SEN(printargs),		"sysv_mmap64"	},
+[1186] = { 0,	0,	SEN(printargs),		"sysv_dmi"	},
+[1187] = { 0,	0,	SEN(printargs),		"sysv_pread"	},
+[1188] = { 0,	0,	SEN(printargs),		"sysv_pwrite"	},
+
+[2000] = { 0,	0,	SEN(printargs),		"bsd43_syscall"	}, /* start of BSD 4.3 */
+[2001] = { 0,	0,	SEN(printargs),		"bsd43_exit"	},
+[2002] = { 0,	0,	SEN(printargs),		"bsd43_fork"	},
+[2003] = { 0,	0,	SEN(printargs),		"bsd43_read"	},
+[2004] = { 0,	0,	SEN(printargs),		"bsd43_write"	},
+[2005] = { 0,	0,	SEN(printargs),		"bsd43_open"	},
+[2006] = { 0,	0,	SEN(printargs),		"bsd43_close"	},
+[2007] = { 0,	0,	SEN(printargs),		"bsd43_wait"	},
+[2008] = { 0,	0,	SEN(printargs),		"bsd43_creat"	},
+[2009] = { 0,	0,	SEN(printargs),		"bsd43_link"	},
+[2010] = { 0,	0,	SEN(printargs),		"bsd43_unlink"	},
+[2011] = { 0,	0,	SEN(printargs),		"bsd43_exec"	},
+[2012] = { 0,	0,	SEN(printargs),		"bsd43_chdir"	},
+[2013] = { 0,	0,	SEN(printargs),		"bsd43_time"	},
+[2014] = { 0,	0,	SEN(printargs),		"bsd43_mknod"	},
+[2015] = { 0,	0,	SEN(printargs),		"bsd43_chmod"	},
+[2016] = { 0,	0,	SEN(printargs),		"bsd43_chown"	},
+[2017] = { 0,	TM,	SEN(printargs),		"bsd43_sbreak"	},
+[2018] = { 0,	0,	SEN(printargs),		"bsd43_oldstat"	},
+[2019] = { 0,	0,	SEN(printargs),		"bsd43_lseek"	},
+[2020] = { 0,	0,	SEN(printargs),		"bsd43_getpid"	},
+[2021] = { 0,	0,	SEN(printargs),		"bsd43_oldmount"	},
+[2022] = { 0,	0,	SEN(printargs),		"bsd43_umount"	},
+[2023] = { 0,	0,	SEN(printargs),		"bsd43_setuid"	},
+[2024] = { 0,	0,	SEN(printargs),		"bsd43_getuid"	},
+[2025] = { 0,	0,	SEN(printargs),		"bsd43_stime"	},
+[2026] = { 0,	0,	SEN(printargs),		"bsd43_ptrace"	},
+[2027] = { 0,	0,	SEN(printargs),		"bsd43_alarm"	},
+[2028] = { 0,	0,	SEN(printargs),		"bsd43_oldfstat"	},
+[2029] = { 0,	0,	SEN(printargs),		"bsd43_pause"	},
+[2030] = { 0,	0,	SEN(printargs),		"bsd43_utime"	},
+[2031] = { 0,	0,	SEN(printargs),		"bsd43_stty"	},
+[2032] = { 0,	0,	SEN(printargs),		"bsd43_gtty"	},
+[2033] = { 0,	0,	SEN(printargs),		"bsd43_access"	},
+[2034] = { 0,	0,	SEN(printargs),		"bsd43_nice"	},
+[2035] = { 0,	0,	SEN(printargs),		"bsd43_ftime"	},
+[2036] = { 0,	0,	SEN(printargs),		"bsd43_sync"	},
+[2037] = { 0,	0,	SEN(printargs),		"bsd43_kill"	},
+[2038] = { 0,	0,	SEN(printargs),		"bsd43_stat"	},
+[2039] = { 0,	0,	SEN(printargs),		"bsd43_oldsetpgrp"	},
+[2040] = { 0,	0,	SEN(printargs),		"bsd43_lstat"	},
+[2041] = { 0,	0,	SEN(printargs),		"bsd43_dup"	},
+[2042] = { 0,	0,	SEN(printargs),		"bsd43_pipe"	},
+[2043] = { 0,	0,	SEN(printargs),		"bsd43_times"	},
+[2044] = { 0,	0,	SEN(printargs),		"bsd43_profil"	},
+[2045] = { 0,	0,	SEN(printargs),		"bsd43_msgsys"	},
+[2046] = { 0,	0,	SEN(printargs),		"bsd43_setgid"	},
+[2047] = { 0,	0,	SEN(printargs),		"bsd43_getgid"	},
+[2048] = { 0,	0,	SEN(printargs),		"bsd43_ssig"	},
+[2049] = { },
+[2050] = { },
+[2051] = { 0,	0,	SEN(printargs),		"bsd43_sysacct"	},
+[2052] = { 0,	0,	SEN(printargs),		"bsd43_phys"	},
+[2053] = { 0,	0,	SEN(printargs),		"bsd43_lock"	},
+[2054] = { 0,	0,	SEN(printargs),		"bsd43_ioctl"	},
+[2055] = { 0,	0,	SEN(printargs),		"bsd43_reboot"	},
+[2056] = { 0,	0,	SEN(printargs),		"bsd43_mpxchan"	},
+[2057] = { 0,	0,	SEN(printargs),		"bsd43_symlink"	},
+[2058] = { 0,	0,	SEN(printargs),		"bsd43_readlink"	},
+[2059] = { 0,	0,	SEN(printargs),		"bsd43_execve"	},
+[2060] = { 0,	0,	SEN(printargs),		"bsd43_umask"	},
+[2061] = { 0,	0,	SEN(printargs),		"bsd43_chroot"	},
+[2062] = { 0,	0,	SEN(printargs),		"bsd43_fstat"	},
+[2063] = { },
+[2064] = { 0,	0,	SEN(printargs),		"bsd43_getpagesize"	},
+[2065] = { 0,	TM|SI,	SEN(printargs),		"bsd43_mremap"	},
+[2066] = { 0,	0,	SEN(printargs),		"bsd43_vfork"	},
+[2067] = { 0,	0,	SEN(printargs),		"bsd43_vread"	},
+[2068] = { 0,	0,	SEN(printargs),		"bsd43_vwrite"	},
+[2069] = { 0,	TM|SI,	SEN(printargs),		"bsd43_sbrk"	},
+[2070] = { 0,	0,	SEN(printargs),		"bsd43_sstk"	},
+[2071] = { 0,	TD|TM|SI,	SEN(printargs),		"bsd43_mmap"	},
+[2072] = { 0,	0,	SEN(printargs),		"bsd43_vadvise"	},
+[2073] = { 0,	TM|SI,	SEN(printargs),		"bsd43_munmap"	},
+[2074] = { 0,	TM|SI,	SEN(printargs),		"bsd43_mprotect"	},
+[2075] = { 0,	TM,	SEN(printargs),		"bsd43_madvise"	},
+[2076] = { 0,	0,	SEN(printargs),		"bsd43_vhangup"	},
+[2077] = { 0,	0,	SEN(printargs),		"bsd43_vlimit"	},
+[2078] = { 0,	TM,	SEN(printargs),		"bsd43_mincore"	},
+[2079] = { 0,	0,	SEN(printargs),		"bsd43_getgroups"	},
+[2080] = { 0,	0,	SEN(printargs),		"bsd43_setgroups"	},
+[2081] = { 0,	0,	SEN(printargs),		"bsd43_getpgrp"	},
+[2082] = { 0,	0,	SEN(printargs),		"bsd43_setpgrp"	},
+[2083] = { 0,	0,	SEN(printargs),		"bsd43_setitimer"	},
+[2084] = { 0,	0,	SEN(printargs),		"bsd43_wait3"	},
+[2085] = { 0,	0,	SEN(printargs),		"bsd43_swapon"	},
+[2086] = { 0,	0,	SEN(printargs),		"bsd43_getitimer"	},
+[2087] = { 0,	0,	SEN(printargs),		"bsd43_gethostname"	},
+[2088] = { 0,	0,	SEN(printargs),		"bsd43_sethostname"	},
+[2089] = { 0,	0,	SEN(printargs),		"bsd43_getdtablesize"	},
+[2090] = { 0,	0,	SEN(printargs),		"bsd43_dup2"	},
+[2091] = { 0,	0,	SEN(printargs),		"bsd43_getdopt"	},
+[2092] = { 0,	0,	SEN(printargs),		"bsd43_fcntl"	},
+[2093] = { 0,	0,	SEN(printargs),		"bsd43_select"	},
+[2094] = { 0,	0,	SEN(printargs),		"bsd43_setdopt"	},
+[2095] = { 0,	0,	SEN(printargs),		"bsd43_fsync"	},
+[2096] = { 0,	0,	SEN(printargs),		"bsd43_setpriority"	},
+[2097] = { 0,	0,	SEN(printargs),		"bsd43_socket"	},
+[2098] = { 0,	0,	SEN(printargs),		"bsd43_connect"	},
+[2099] = { 0,	0,	SEN(printargs),		"bsd43_oldaccept"	},
+[2100] = { 0,	0,	SEN(printargs),		"bsd43_getpriority"	},
+[2101] = { 0,	0,	SEN(printargs),		"bsd43_send"	},
+[2102] = { 0,	0,	SEN(printargs),		"bsd43_recv"	},
+[2103] = { 0,	0,	SEN(printargs),		"bsd43_sigreturn"	},
+[2104] = { 0,	0,	SEN(printargs),		"bsd43_bind"	},
+[2105] = { 0,	0,	SEN(printargs),		"bsd43_setsockopt"	},
+[2106] = { 0,	0,	SEN(printargs),		"bsd43_listen"	},
+[2107] = { 0,	0,	SEN(printargs),		"bsd43_vtimes"	},
+[2108] = { 0,	0,	SEN(printargs),		"bsd43_sigvec"	},
+[2109] = { 0,	0,	SEN(printargs),		"bsd43_sigblock"	},
+[2110] = { 0,	0,	SEN(printargs),		"bsd43_sigsetmask"	},
+[2111] = { 0,	0,	SEN(printargs),		"bsd43_sigpause"	},
+[2112] = { 0,	0,	SEN(printargs),		"bsd43_sigstack"	},
+[2113] = { 0,	0,	SEN(printargs),		"bsd43_oldrecvmsg"	},
+[2114] = { 0,	0,	SEN(printargs),		"bsd43_oldsendmsg"	},
+[2115] = { 0,	0,	SEN(printargs),		"bsd43_vtrace"	},
+[2116] = { 0,	0,	SEN(printargs),		"bsd43_gettimeofday"	},
+[2117] = { 0,	0,	SEN(printargs),		"bsd43_getrusage"	},
+[2118] = { 0,	0,	SEN(printargs),		"bsd43_getsockopt"	},
+[2119] = { },
+[2120] = { 0,	0,	SEN(printargs),		"bsd43_readv"	},
+[2121] = { 0,	0,	SEN(printargs),		"bsd43_writev"	},
+[2122] = { 0,	0,	SEN(printargs),		"bsd43_settimeofday"	},
+[2123] = { 0,	0,	SEN(printargs),		"bsd43_fchown"	},
+[2124] = { 0,	0,	SEN(printargs),		"bsd43_fchmod"	},
+[2125] = { 0,	0,	SEN(printargs),		"bsd43_oldrecvfrom"	},
+[2126] = { 0,	0,	SEN(printargs),		"bsd43_setreuid"	},
+[2127] = { 0,	0,	SEN(printargs),		"bsd43_setregid"	},
+[2128] = { 0,	0,	SEN(printargs),		"bsd43_rename"	},
+[2129] = { 0,	0,	SEN(printargs),		"bsd43_truncate"	},
+[2130] = { 0,	0,	SEN(printargs),		"bsd43_ftruncate"	},
+[2131] = { 0,	0,	SEN(printargs),		"bsd43_flock"	},
+[2132] = { 0,	0,	SEN(printargs),		"bsd43_semsys"	},
+[2133] = { 0,	0,	SEN(printargs),		"bsd43_sendto"	},
+[2134] = { 0,	0,	SEN(printargs),		"bsd43_shutdown"	},
+[2135] = { 0,	0,	SEN(printargs),		"bsd43_socketpair"	},
+[2136] = { 0,	0,	SEN(printargs),		"bsd43_mkdir"	},
+[2137] = { 0,	0,	SEN(printargs),		"bsd43_rmdir"	},
+[2138] = { 0,	0,	SEN(printargs),		"bsd43_utimes"	},
+[2139] = { 0,	0,	SEN(printargs),		"bsd43_sigcleanup"	},
+[2140] = { 0,	0,	SEN(printargs),		"bsd43_adjtime"	},
+[2141] = { 0,	0,	SEN(printargs),		"bsd43_oldgetpeername"	},
+[2142] = { 0,	0,	SEN(printargs),		"bsd43_gethostid"	},
+[2143] = { 0,	0,	SEN(printargs),		"bsd43_sethostid"	},
+[2144] = { 0,	0,	SEN(printargs),		"bsd43_getrlimit"	},
+[2145] = { 0,	0,	SEN(printargs),		"bsd43_setrlimit"	},
+[2146] = { 0,	0,	SEN(printargs),		"bsd43_killpg"	},
+[2147] = { 0,	0,	SEN(printargs),		"bsd43_shmsys"	},
+[2148] = { 0,	0,	SEN(printargs),		"bsd43_quota"	},
+[2149] = { 0,	0,	SEN(printargs),		"bsd43_qquota"	},
+[2150] = { 0,	0,	SEN(printargs),		"bsd43_oldgetsockname"	},
+[2151] = { 0,	0,	SEN(printargs),		"bsd43_sysmips"	},
+[2152] = { 0,	0,	SEN(printargs),		"bsd43_cacheflush"	},
+[2153] = { 0,	0,	SEN(printargs),		"bsd43_cachectl"	},
+[2154] = { 0,	0,	SEN(printargs),		"bsd43_debug"	},
+[2155] = { },
+[2156] = { },
+[2157] = { 0,	0,	SEN(printargs),		"bsd43_nfs_mount"	},
+[2158] = { 0,	0,	SEN(printargs),		"bsd43_nfs_svc"	},
+[2159] = { 0,	0,	SEN(printargs),		"bsd43_getdirentries"	},
+[2160] = { 0,	0,	SEN(printargs),		"bsd43_statfs"	},
+[2161] = { 0,	0,	SEN(printargs),		"bsd43_fstatfs"	},
+[2162] = { 0,	0,	SEN(printargs),		"bsd43_unmount"	},
+[2163] = { 0,	0,	SEN(printargs),		"bsd43_async_daemon"	},
+[2164] = { 0,	0,	SEN(printargs),		"bsd43_nfs_getfh"	},
+[2165] = { 0,	0,	SEN(printargs),		"bsd43_getdomainname"	},
+[2166] = { 0,	0,	SEN(printargs),		"bsd43_setdomainname"	},
+[2167] = { 0,	0,	SEN(printargs),		"bsd43_pcfs_mount"	},
+[2168] = { 0,	TF,	SEN(printargs),		"bsd43_quotactl"	},
+[2169] = { 0,	0,	SEN(printargs),		"bsd43_oldexportfs"	},
+[2170] = { 0,	0,	SEN(printargs),		"bsd43_smount"	},
+[2171] = { 0,	0,	SEN(printargs),		"bsd43_mipshwconf"	},
+[2172] = { 0,	0,	SEN(printargs),		"bsd43_exportfs"	},
+[2173] = { 0,	0,	SEN(printargs),		"bsd43_nfsfh_open"	},
+[2174] = { 0,	0,	SEN(printargs),		"bsd43_libattach"	},
+[2175] = { 0,	0,	SEN(printargs),		"bsd43_libdetach"	},
+[2176] = { 0,	0,	SEN(printargs),		"bsd43_accept"	},
+[2177] = { },
+[2178] = { },
+[2179] = { 0,	0,	SEN(printargs),		"bsd43_recvmsg"	},
+[2180] = { 0,	0,	SEN(printargs),		"bsd43_recvfrom"	},
+[2181] = { 0,	0,	SEN(printargs),		"bsd43_sendmsg"	},
+[2182] = { 0,	0,	SEN(printargs),		"bsd43_getpeername"	},
+[2183] = { 0,	0,	SEN(printargs),		"bsd43_getsockname"	},
+[2184] = { 0,	0,	SEN(printargs),		"bsd43_aread"	},
+[2185] = { 0,	0,	SEN(printargs),		"bsd43_awrite"	},
+[2186] = { 0,	0,	SEN(printargs),		"bsd43_listio"	},
+[2187] = { 0,	0,	SEN(printargs),		"bsd43_acancel"	},
+[2188] = { 0,	0,	SEN(printargs),		"bsd43_astatus"	},
+[2189] = { 0,	0,	SEN(printargs),		"bsd43_await"	},
+[2190] = { 0,	0,	SEN(printargs),		"bsd43_areadv"	},
+[2191] = { 0,	0,	SEN(printargs),		"bsd43_awritev"	},
+
+[3000] = { 0,	0,	SEN(printargs),		"posix_syscall"	}, /* start of POSIX */
+[3001] = { 0,	0,	SEN(printargs),		"posix_exit"	},
+[3002] = { 0,	0,	SEN(printargs),		"posix_fork"	},
+[3003] = { 0,	0,	SEN(printargs),		"posix_read"	},
+[3004] = { 0,	0,	SEN(printargs),		"posix_write"	},
+[3005] = { 0,	0,	SEN(printargs),		"posix_open"	},
+[3006] = { 0,	0,	SEN(printargs),		"posix_close"	},
+[3007] = { 0,	0,	SEN(printargs),		"posix_wait"	},
+[3008] = { 0,	0,	SEN(printargs),		"posix_creat"	},
+[3009] = { 0,	0,	SEN(printargs),		"posix_link"	},
+[3010] = { 0,	0,	SEN(printargs),		"posix_unlink"	},
+[3011] = { 0,	0,	SEN(printargs),		"posix_exec"	},
+[3012] = { 0,	0,	SEN(printargs),		"posix_chdir"	},
+[3013] = { 0,	0,	SEN(printargs),		"posix_gtime"	},
+[3014] = { 0,	0,	SEN(printargs),		"posix_mknod"	},
+[3015] = { 0,	0,	SEN(printargs),		"posix_chmod"	},
+[3016] = { 0,	0,	SEN(printargs),		"posix_chown"	},
+[3017] = { 0,	TM,	SEN(printargs),		"posix_sbreak"	},
+[3018] = { 0,	0,	SEN(printargs),		"posix_stat"	},
+[3019] = { 0,	0,	SEN(printargs),		"posix_lseek"	},
+[3020] = { 0,	0,	SEN(printargs),		"posix_getpid"	},
+[3021] = { 0,	0,	SEN(printargs),		"posix_mount"	},
+[3022] = { 0,	0,	SEN(printargs),		"posix_umount"	},
+[3023] = { 0,	0,	SEN(printargs),		"posix_setuid"	},
+[3024] = { 0,	0,	SEN(printargs),		"posix_getuid"	},
+[3025] = { 0,	0,	SEN(printargs),		"posix_stime"	},
+[3026] = { 0,	0,	SEN(printargs),		"posix_ptrace"	},
+[3027] = { 0,	0,	SEN(printargs),		"posix_alarm"	},
+[3028] = { 0,	0,	SEN(printargs),		"posix_fstat"	},
+[3029] = { 0,	0,	SEN(printargs),		"posix_pause"	},
+[3030] = { 0,	0,	SEN(printargs),		"posix_utime"	},
+[3031] = { 0,	0,	SEN(printargs),		"posix_stty"	},
+[3032] = { 0,	0,	SEN(printargs),		"posix_gtty"	},
+[3033] = { 0,	0,	SEN(printargs),		"posix_access"	},
+[3034] = { 0,	0,	SEN(printargs),		"posix_nice"	},
+[3035] = { 0,	0,	SEN(printargs),		"posix_statfs"	},
+[3036] = { 0,	0,	SEN(printargs),		"posix_sync"	},
+[3037] = { 0,	0,	SEN(printargs),		"posix_kill"	},
+[3038] = { 0,	0,	SEN(printargs),		"posix_fstatfs"	},
+[3039] = { 0,	0,	SEN(printargs),		"posix_getpgrp"	},
+[3040] = { 0,	0,	SEN(printargs),		"posix_syssgi"	},
+[3041] = { 0,	0,	SEN(printargs),		"posix_dup"	},
+[3042] = { 0,	0,	SEN(printargs),		"posix_pipe"	},
+[3043] = { 0,	0,	SEN(printargs),		"posix_times"	},
+[3044] = { 0,	0,	SEN(printargs),		"posix_profil"	},
+[3045] = { 0,	0,	SEN(printargs),		"posix_lock"	},
+[3046] = { 0,	0,	SEN(printargs),		"posix_setgid"	},
+[3047] = { 0,	0,	SEN(printargs),		"posix_getgid"	},
+[3048] = { 0,	0,	SEN(printargs),		"posix_sig"	},
+[3049] = { 0,	0,	SEN(printargs),		"posix_msgsys"	},
+[3050] = { 0,	0,	SEN(printargs),		"posix_sysmips"	},
+[3051] = { 0,	0,	SEN(printargs),		"posix_sysacct"	},
+[3052] = { 0,	0,	SEN(printargs),		"posix_shmsys"	},
+[3053] = { 0,	0,	SEN(printargs),		"posix_semsys"	},
+[3054] = { 0,	0,	SEN(printargs),		"posix_ioctl"	},
+[3055] = { 0,	0,	SEN(printargs),		"posix_uadmin"	},
+[3056] = { 0,	0,	SEN(printargs),		"posix_exch"	},
+[3057] = { 0,	0,	SEN(printargs),		"posix_utssys"	},
+[3058] = { },
+[3059] = { 0,	0,	SEN(printargs),		"posix_exece"	},
+[3060] = { 0,	0,	SEN(printargs),		"posix_umask"	},
+[3061] = { 0,	0,	SEN(printargs),		"posix_chroot"	},
+[3062] = { 0,	0,	SEN(printargs),		"posix_fcntl"	},
+[3063] = { 0,	0,	SEN(printargs),		"posix_ulimit"	},
+[3064 ... 3069] = { },
+[3070] = { 0,	0,	SEN(printargs),		"posix_advfs"	},
+[3071] = { 0,	0,	SEN(printargs),		"posix_unadvfs"	},
+[3072] = { 0,	0,	SEN(printargs),		"posix_rmount"	},
+[3073] = { 0,	0,	SEN(printargs),		"posix_rumount"	},
+[3074] = { 0,	0,	SEN(printargs),		"posix_rfstart"	},
+[3075] = { },
+[3076] = { 0,	0,	SEN(printargs),		"posix_rdebug"	},
+[3077] = { 0,	0,	SEN(printargs),		"posix_rfstop"	},
+[3078] = { 0,	0,	SEN(printargs),		"posix_rfsys"	},
+[3079] = { 0,	0,	SEN(printargs),		"posix_rmdir"	},
+[3080] = { 0,	0,	SEN(printargs),		"posix_mkdir"	},
+[3081] = { 0,	0,	SEN(printargs),		"posix_getdents"	},
+[3082] = { 0,	0,	SEN(printargs),		"posix_sginap"	},
+[3083] = { 0,	0,	SEN(printargs),		"posix_sgikopt"	},
+[3084] = { 0,	0,	SEN(printargs),		"posix_sysfs"	},
+[3085] = { 0,	0,	SEN(printargs),		"posix_getmsg"	},
+[3086] = { 0,	0,	SEN(printargs),		"posix_putmsg"	},
+[3087] = { 0,	0,	SEN(printargs),		"posix_poll"	},
+[3088] = { 0,	0,	SEN(printargs),		"posix_sigreturn"	},
+[3089] = { 0,	0,	SEN(printargs),		"posix_accept"	},
+[3090] = { 0,	0,	SEN(printargs),		"posix_bind"	},
+[3091] = { 0,	0,	SEN(printargs),		"posix_connect"	},
+[3092] = { 0,	0,	SEN(printargs),		"posix_gethostid"	},
+[3093] = { 0,	0,	SEN(printargs),		"posix_getpeername"	},
+[3094] = { 0,	0,	SEN(printargs),		"posix_getsockname"	},
+[3095] = { 0,	0,	SEN(printargs),		"posix_getsockopt"	},
+[3096] = { 0,	0,	SEN(printargs),		"posix_listen"	},
+[3097] = { 0,	0,	SEN(printargs),		"posix_recv"	},
+[3098] = { 0,	0,	SEN(printargs),		"posix_recvfrom"	},
+[3099] = { 0,	0,	SEN(printargs),		"posix_recvmsg"	},
+[3100] = { 0,	0,	SEN(printargs),		"posix_select"	},
+[3101] = { 0,	0,	SEN(printargs),		"posix_send"	},
+[3102] = { 0,	0,	SEN(printargs),		"posix_sendmsg"	},
+[3103] = { 0,	0,	SEN(printargs),		"posix_sendto"	},
+[3104] = { 0,	0,	SEN(printargs),		"posix_sethostid"	},
+[3105] = { 0,	0,	SEN(printargs),		"posix_setsockopt"	},
+[3106] = { 0,	0,	SEN(printargs),		"posix_shutdown"	},
+[3107] = { 0,	0,	SEN(printargs),		"posix_socket"	},
+[3108] = { 0,	0,	SEN(printargs),		"posix_gethostname"	},
+[3109] = { 0,	0,	SEN(printargs),		"posix_sethostname"	},
+[3110] = { 0,	0,	SEN(printargs),		"posix_getdomainname"	},
+[3111] = { 0,	0,	SEN(printargs),		"posix_setdomainname"	},
+[3112] = { 0,	0,	SEN(printargs),		"posix_truncate"	},
+[3113] = { 0,	0,	SEN(printargs),		"posix_ftruncate"	},
+[3114] = { 0,	0,	SEN(printargs),		"posix_rename"	},
+[3115] = { 0,	0,	SEN(printargs),		"posix_symlink"	},
+[3116] = { 0,	0,	SEN(printargs),		"posix_readlink"	},
+[3117] = { 0,	0,	SEN(printargs),		"posix_lstat"	},
+[3118] = { 0,	0,	SEN(printargs),		"posix_nfs_mount"	},
+[3119] = { 0,	0,	SEN(printargs),		"posix_nfs_svc"	},
+[3120] = { 0,	0,	SEN(printargs),		"posix_nfs_getfh"	},
+[3121] = { 0,	0,	SEN(printargs),		"posix_async_daemon"	},
+[3122] = { 0,	0,	SEN(printargs),		"posix_exportfs"	},
+[3123] = { 0,	0,	SEN(printargs),		"posix_SGI_setregid"	},
+[3124] = { 0,	0,	SEN(printargs),		"posix_SGI_setreuid"	},
+[3125] = { 0,	0,	SEN(printargs),		"posix_getitimer"	},
+[3126] = { 0,	0,	SEN(printargs),		"posix_setitimer"	},
+[3127] = { 0,	0,	SEN(printargs),		"posix_adjtime"	},
+[3128] = { 0,	0,	SEN(printargs),		"posix_SGI_bsdgettime"	},
+[3129] = { 0,	0,	SEN(printargs),		"posix_SGI_sproc"	},
+[3130] = { 0,	0,	SEN(printargs),		"posix_SGI_prctl"	},
+[3131] = { 0,	0,	SEN(printargs),		"posix_SGI_blkproc"	},
+[3132] = { },
+[3133] = { 0,	0,	SEN(printargs),		"posix_SGI_sgigsc"	},
+[3134] = { 0,	TD|TM|SI,	SEN(printargs),		"posix_SGI_mmap"	},
+[3135] = { 0,	TM|SI,	SEN(printargs),		"posix_SGI_munmap"	},
+[3136] = { 0,	TM|SI,	SEN(printargs),		"posix_SGI_mprotect"	},
+[3137] = { 0,	TM,	SEN(printargs),		"posix_SGI_msync"	},
+[3138] = { 0,	TM,	SEN(printargs),		"posix_SGI_madvise"	},
+[3139] = { 0,	0,	SEN(printargs),		"posix_SGI_mpin"	},
+[3140] = { 0,	0,	SEN(printargs),		"posix_SGI_getpagesize"	},
+[3141] = { 0,	0,	SEN(printargs),		"posix_SGI_libattach"	},
+[3142] = { 0,	0,	SEN(printargs),		"posix_SGI_libdetach"	},
+[3143] = { 0,	0,	SEN(printargs),		"posix_SGI_getpgrp"	},
+[3144] = { 0,	0,	SEN(printargs),		"posix_SGI_setpgrp"	},
+[3145 ... 3149] = { },
+[3150] = { 0,	0,	SEN(printargs),		"posix_cacheflush"	},
+[3151] = { 0,	0,	SEN(printargs),		"posix_cachectl"	},
+[3152] = { 0,	0,	SEN(printargs),		"posix_fchown"	},
+[3153] = { 0,	0,	SEN(printargs),		"posix_fchmod"	},
+[3154] = { 0,	0,	SEN(printargs),		"posix_wait3"	},
+[3155] = { 0,	TD|TM|SI,	SEN(printargs),		"posix_mmap"	},
+[3156] = { 0,	TM|SI,	SEN(printargs),		"posix_munmap"	},
+[3157] = { 0,	TM,	SEN(printargs),		"posix_madvise"	},
+[3158] = { 0,	0,	SEN(printargs),		"posix_BSD_getpagesize"	},
+[3159] = { 0,	0,	SEN(printargs),		"posix_setreuid"	},
+[3160] = { 0,	0,	SEN(printargs),		"posix_setregid"	},
+[3161] = { 0,	0,	SEN(printargs),		"posix_setpgid"	},
+[3162] = { 0,	0,	SEN(printargs),		"posix_getgroups"	},
+[3163] = { 0,	0,	SEN(printargs),		"posix_setgroups"	},
+[3164] = { 0,	0,	SEN(printargs),		"posix_gettimeofday"	},
+[3165] = { 0,	0,	SEN(printargs),		"posix_getrusage"	},
+[3166] = { 0,	0,	SEN(printargs),		"posix_getrlimit"	},
+[3167] = { 0,	0,	SEN(printargs),		"posix_setrlimit"	},
+[3168] = { 0,	0,	SEN(printargs),		"posix_waitpid"	},
+[3169] = { 0,	0,	SEN(printargs),		"posix_dup2"	},
+[3170 ... 3259] = { },
+[3260] = { 0,	0,	SEN(printargs),		"posix_netboot"	},
+[3261] = { 0,	0,	SEN(printargs),		"posix_netunboot"	},
+[3262] = { 0,	0,	SEN(printargs),		"posix_rdump"	},
+[3263] = { 0,	0,	SEN(printargs),		"posix_setsid"	},
+[3264] = { 0,	0,	SEN(printargs),		"posix_getmaxsig"	},
+[3265] = { 0,	0,	SEN(printargs),		"posix_sigpending"	},
+[3266] = { 0,	0,	SEN(printargs),		"posix_sigprocmask"	},
+[3267] = { 0,	0,	SEN(printargs),		"posix_sigsuspend"	},
+[3268] = { 0,	0,	SEN(printargs),		"posix_sigaction"	},
diff --git a/strace/linux/mips/syscallent-n32-stub.h b/strace/linux/mips/syscallent-n32-stub.h
new file mode 100644
index 0000000..184b19d
--- /dev/null
+++ b/strace/linux/mips/syscallent-n32-stub.h
@@ -0,0 +1,322 @@
+[6000] = { 3,	TD,		SEN(printargs), "n32_read"			}, /* start of Linux N32 */
+[6001] = { 3,	TD,		SEN(printargs), "n32_write"			},
+[6002] = { 3,	TD|TF,		SEN(printargs), "n32_open"			},
+[6003] = { 1,	TD,		SEN(printargs), "n32_close"			},
+[6004] = { 2,	TF,		SEN(printargs), "n32_stat"			},
+[6005] = { 2,	TD,		SEN(printargs), "n32_fstat"			},
+[6006] = { 2,	TF,		SEN(printargs), "n32_lstat"			},
+[6007] = { 3,	TD,		SEN(printargs), "n32_poll"			},
+[6008] = { 3,	TD,		SEN(printargs), "n32_lseek"			},
+[6009] = { 6,	TD|TM|SI,	SEN(printargs), "n32_mmap"			},
+[6010] = { 3,	TM|SI,		SEN(printargs), "n32_mprotect"		},
+[6011] = { 2,	TM|SI,		SEN(printargs), "n32_munmap"		},
+[6012] = { 1,	TM|SI,		SEN(printargs), "n32_brk"			},
+[6013] = { 4,	TS,		SEN(printargs), "n32_rt_sigaction"		},
+[6014] = { 4,	TS,		SEN(printargs), "n32_rt_sigprocmask"	},
+[6015] = { 3,	TD,		SEN(printargs), "n32_ioctl"			},
+[6016] = { 4,	TD,		SEN(printargs), "n32_pread64"		},
+[6017] = { 4,	TD,		SEN(printargs), "n32_pwrite64"		},
+[6018] = { 3,	TD,		SEN(printargs), "n32_readv"			},
+[6019] = { 3,	TD,		SEN(printargs), "n32_writev"		},
+[6020] = { 2,	TF,		SEN(printargs), "n32_access"		},
+[6021] = { 1,	TD,		SEN(printargs), "n32_pipe"			},
+[6022] = { 5,	TD,		SEN(printargs), "n32_select"		},
+[6023] = { 0,	0,		SEN(printargs), "n32_sched_yield"		},
+[6024] = { 5,	TM|SI,		SEN(printargs), "n32_mremap"		},
+[6025] = { 3,	TM,		SEN(printargs), "n32_msync"			},
+[6026] = { 3,	TM,		SEN(printargs), "n32_mincore"		},
+[6027] = { 3,	TM,		SEN(printargs), "n32_madvise"		},
+[6028] = { 3,	TI,		SEN(printargs), "n32_shmget"		},
+[6029] = { 3,	TI|TM|SI,	SEN(printargs), "n32_shmat"			},
+[6030] = { 3,	TI,		SEN(printargs), "n32_shmctl"		},
+[6031] = { 1,	TD,		SEN(printargs), "n32_dup"			},
+[6032] = { 2,	TD,		SEN(printargs), "n32_dup2"			},
+[6033] = { 0,	TS,		SEN(printargs), "n32_pause"			},
+[6034] = { 2,	0,		SEN(printargs), "n32_nanosleep"		},
+[6035] = { 2,	0,		SEN(printargs), "n32_getitimer"		},
+[6036] = { 3,	0,		SEN(printargs), "n32_setitimer"		},
+[6037] = { 1,	0,		SEN(printargs), "n32_alarm"			},
+[6038] = { 0,	0,		SEN(printargs), "n32_getpid"		},
+[6039] = { 4,	TD|TN,		SEN(printargs), "n32_sendfile"		},
+[6040] = { 3,	TN,		SEN(printargs), "n32_socket"		},
+[6041] = { 3,	TN,		SEN(printargs), "n32_connect"		},
+[6042] = { 3,	TN,		SEN(printargs), "n32_accept"		},
+[6043] = { 6,	TN,		SEN(printargs), "n32_sendto"		},
+[6044] = { 6,	TN,		SEN(printargs), "n32_recvfrom"		},
+[6045] = { 3,	TN,		SEN(printargs), "n32_sendmsg"		},
+[6046] = { 3,	TN,		SEN(printargs), "n32_recvmsg"		},
+[6047] = { 2,	TN,		SEN(printargs), "n32_shutdown"		},
+[6048] = { 3,	TN,		SEN(printargs), "n32_bind"			},
+[6049] = { 2,	TN,		SEN(printargs), "n32_listen"		},
+[6050] = { 3,	TN,		SEN(printargs), "n32_getsockname"		},
+[6051] = { 3,	TN,		SEN(printargs), "n32_getpeername"		},
+[6052] = { 4,	TN,		SEN(printargs), "n32_socketpair"		},
+[6053] = { 5,	TN,		SEN(printargs), "n32_setsockopt"		},
+[6054] = { 5,	TN,		SEN(printargs), "n32_getsockopt"		},
+[6055] = { 5,	TP,		SEN(printargs), "n32_clone"			},
+[6056] = { 0,	TP,		SEN(printargs), "n32_fork"			},
+[6057] = { 3,	TF|TP|SE|SI,	SEN(printargs), "n32_execve"		},
+[6058] = { 1,	TP|SE,		SEN(printargs), "n32_exit"			},
+[6059] = { 4,	TP,		SEN(printargs), "n32_wait4"			},
+[6060] = { 2,	TS,		SEN(printargs), "n32_kill"			},
+[6061] = { 1,	0,		SEN(printargs), "n32_uname"			},
+[6062] = { 3,	TI,		SEN(printargs), "n32_semget"		},
+[6063] = { 3,	TI,		SEN(printargs), "n32_semop"			},
+[6064] = { 4,	TI,		SEN(printargs), "n32_semctl"		},
+[6065] = { 1,	TI|TM|SI,	SEN(printargs), "n32_shmdt"			},
+[6066] = { 2,	TI,		SEN(printargs), "n32_msgget"		},
+[6067] = { 4,	TI,		SEN(printargs), "n32_msgsnd"		},
+[6068] = { 5,	TI,		SEN(printargs), "n32_msgrcv"		},
+[6069] = { 3,	TI,		SEN(printargs), "n32_msgctl"		},
+[6070] = { 3,	TD,		SEN(printargs), "n32_fcntl"			},
+[6071] = { 2,	TD,		SEN(printargs), "n32_flock"			},
+[6072] = { 1,	TD,		SEN(printargs), "n32_fsync"			},
+[6073] = { 1,	TD,		SEN(printargs), "n32_fdatasync"		},
+[6074] = { 2,	TF,		SEN(printargs), "n32_truncate"		},
+[6075] = { 2,	TD,		SEN(printargs), "n32_ftruncate"		},
+[6076] = { 3,	TD,		SEN(printargs), "n32_getdents"		},
+[6077] = { 2,	TF,		SEN(printargs), "n32_getcwd"		},
+[6078] = { 1,	TF,		SEN(printargs), "n32_chdir"			},
+[6079] = { 1,	TD,		SEN(printargs), "n32_fchdir"		},
+[6080] = { 2,	TF,		SEN(printargs), "n32_rename"		},
+[6081] = { 2,	TF,		SEN(printargs), "n32_mkdir"			},
+[6082] = { 1,	TF,		SEN(printargs), "n32_rmdir"			},
+[6083] = { 2,	TD|TF,		SEN(printargs), "n32_creat"			},
+[6084] = { 2,	TF,		SEN(printargs), "n32_link"			},
+[6085] = { 1,	TF,		SEN(printargs), "n32_unlink"		},
+[6086] = { 2,	TF,		SEN(printargs), "n32_symlink"		},
+[6087] = { 3,	TF,		SEN(printargs), "n32_readlink"		},
+[6088] = { 2,	TF,		SEN(printargs), "n32_chmod"			},
+[6089] = { 2,	TD,		SEN(printargs), "n32_fchmod"		},
+[6090] = { 3,	TF,		SEN(printargs), "n32_chown"			},
+[6091] = { 3,	TD,		SEN(printargs), "n32_fchown"		},
+[6092] = { 3,	TF,		SEN(printargs), "n32_lchown"		},
+[6093] = { 1,	0,		SEN(printargs), "n32_umask"			},
+[6094] = { 2,	0,		SEN(printargs), "n32_gettimeofday"		},
+[6095] = { 2,	0,		SEN(printargs), "n32_getrlimit"		},
+[6096] = { 2,	0,		SEN(printargs), "n32_getrusage"		},
+[6097] = { 1,	0,		SEN(printargs), "n32_sysinfo"		},
+[6098] = { 1,	0,		SEN(printargs), "n32_times"			},
+[6099] = { 4,	0,		SEN(printargs), "n32_ptrace"		},
+[6100] = { 0,	NF,		SEN(printargs), "n32_getuid"		},
+[6101] = { 3,	0,		SEN(printargs), "n32_syslog"		},
+[6102] = { 0,	NF,		SEN(printargs), "n32_getgid"		},
+[6103] = { 1,	0,		SEN(printargs), "n32_setuid"		},
+[6104] = { 1,	0,		SEN(printargs), "n32_setgid"		},
+[6105] = { 0,	NF,		SEN(printargs), "n32_geteuid"		},
+[6106] = { 0,	NF,		SEN(printargs), "n32_getegid"		},
+[6107] = { 2,	0,		SEN(printargs), "n32_setpgid"		},
+[6108] = { 0,	0,		SEN(printargs), "n32_getppid"		},
+[6109] = { 0,	0,		SEN(printargs), "n32_getpgrp"		},
+[6110] = { 0,	0,		SEN(printargs), "n32_setsid"		},
+[6111] = { 2,	0,		SEN(printargs), "n32_setreuid"		},
+[6112] = { 2,	0,		SEN(printargs), "n32_setregid"		},
+[6113] = { 2,	0,		SEN(printargs), "n32_getgroups"		},
+[6114] = { 2,	0,		SEN(printargs), "n32_setgroups"		},
+[6115] = { 3,	0,		SEN(printargs), "n32_setresuid"		},
+[6116] = { 3,	0,		SEN(printargs), "n32_getresuid"		},
+[6117] = { 3,	0,		SEN(printargs), "n32_setresgid"		},
+[6118] = { 3,	0,		SEN(printargs), "n32_getresgid"		},
+[6119] = { 0,	0,		SEN(printargs), "n32_getpgid"		},
+[6120] = { 1,	NF,		SEN(printargs), "n32_setfsuid"		},
+[6121] = { 1,	NF,		SEN(printargs), "n32_setfsgid"		},
+[6122] = { 1,	0,		SEN(printargs), "n32_getsid"		},
+[6123] = { 2,	0,		SEN(printargs), "n32_capget"		},
+[6124] = { 2,	0,		SEN(printargs), "n32_capset"		},
+[6125] = { 2,	TS,		SEN(printargs), "n32_rt_sigpending"		},
+[6126] = { 4,	TS,		SEN(printargs), "n32_rt_sigtimedwait"	},
+[6127] = { 3,	TS,		SEN(printargs), "n32_rt_sigqueueinfo"	},
+[6128] = { 2,	TS,		SEN(printargs), "n32_rt_sigsuspend"		},
+[6129] = { 2,	TS,		SEN(printargs), "n32_sigaltstack"		},
+[6130] = { 2,	TF,		SEN(printargs), "n32_utime"			},
+[6131] = { 3,	TF,		SEN(printargs), "n32_mknod"			},
+[6132] = { 1,	0,		SEN(printargs), "n32_personality"		},
+[6133] = { 2,	0,		SEN(printargs), "n32_ustat"			},
+[6134] = { 3,	TF,		SEN(printargs), "n32_statfs"		},
+[6135] = { 3,	TD,		SEN(printargs), "n32_fstatfs"		},
+[6136] = { 5,	0,		SEN(printargs), "n32_sysfs"			},
+[6137] = { 2,	0,		SEN(printargs), "n32_getpriority"		},
+[6138] = { 3,	0,		SEN(printargs), "n32_setpriority"		},
+[6139] = { 2,	0,		SEN(printargs), "n32_sched_setparam"	},
+[6140] = { 2,	0,		SEN(printargs), "n32_sched_getparam"	},
+[6141] = { 3,	0,		SEN(printargs), "n32_sched_setscheduler"	},
+[6142] = { 1,	0,		SEN(printargs), "n32_sched_getscheduler"	},
+[6143] = { 1,	0,		SEN(printargs), "n32_sched_get_priority_max"},
+[6144] = { 1,	0,		SEN(printargs), "n32_sched_get_priority_min"},
+[6145] = { 2,	0,		SEN(printargs), "n32_sched_rr_get_interval"	},
+[6146] = { 2,	TM,		SEN(printargs), "n32_mlock"			},
+[6147] = { 2,	TM,		SEN(printargs), "n32_munlock"		},
+[6148] = { 1,	TM,		SEN(printargs), "n32_mlockall"		},
+[6149] = { 0,	TM,		SEN(printargs), "n32_munlockall"		},
+[6150] = { 0,	0,		SEN(printargs), "n32_vhangup"		},
+[6151] = { 2,	TF,		SEN(printargs), "n32_pivot_root"		},
+[6152] = { 1,	0,		SEN(printargs), "n32__sysctl"		},
+[6153] = { 5,	0,		SEN(printargs), "n32_prctl"			},
+[6154] = { 1,	0,		SEN(printargs), "n32_adjtimex"		},
+[6155] = { 2,	0,		SEN(printargs), "n32_setrlimit"		},
+[6156] = { 1,	TF,		SEN(printargs), "n32_chroot"		},
+[6157] = { 0,	0,		SEN(printargs), "n32_sync"			},
+[6158] = { 1,	TF,		SEN(printargs), "n32_acct"			},
+[6159] = { 2,	0,		SEN(printargs), "n32_settimeofday"		},
+[6160] = { 5,	TF,		SEN(printargs), "n32_mount"			},
+[6161] = { 2,	TF,		SEN(printargs), "n32_umount2"		},
+[6162] = { 2,	TF,		SEN(printargs), "n32_swapon"		},
+[6163] = { 1,	TF,		SEN(printargs), "n32_swapoff"		},
+[6164] = { 4,	0,		SEN(printargs), "n32_reboot"		},
+[6165] = { 2,	0,		SEN(printargs), "n32_sethostname"		},
+[6166] = { 2,	0,		SEN(printargs), "n32_setdomainname"		},
+[6167] = { 2,	0,		SEN(printargs), "n32_create_module"		},
+[6168] = { 4,	0,		SEN(printargs), "n32_init_module"		},
+[6169] = { 1,	0,		SEN(printargs), "n32_delete_module"		},
+[6170] = { 1,	0,		SEN(printargs), "n32_get_kernel_syms"	},
+[6171] = { 5,	0,		SEN(printargs), "n32_query_module"		},
+[6172] = { 4,	TF,		SEN(printargs), "n32_quotactl"		},
+[6173] = { 3,	0,		SEN(printargs), "n32_nfsservctl"		},
+[6174] = { 5,	TN,		SEN(printargs), "n32_getpmsg"		},
+[6175] = { 5,	TN,		SEN(printargs), "n32_putpmsg"		},
+[6176] = { 0,	0,		SEN(printargs), "n32_afs_syscall"		},
+[6177] = { 0,	0,		SEN(printargs), "n32_reserved177"		},
+[6178] = { 0,	0,		SEN(printargs), "n32_gettid"		},
+[6179] = { 3,	TD,		SEN(printargs), "n32_readahead"		},
+[6180] = { 5,	TF,		SEN(printargs), "n32_setxattr"		},
+[6181] = { 5,	TF,		SEN(printargs), "n32_lsetxattr"		},
+[6182] = { 5,	TD,		SEN(printargs), "n32_fsetxattr"		},
+[6183] = { 4,	TF,		SEN(printargs), "n32_getxattr"		},
+[6184] = { 4,	TF,		SEN(printargs), "n32_lgetxattr"		},
+[6185] = { 4,	TD,		SEN(printargs), "n32_fgetxattr"		},
+[6186] = { 3,	TF,		SEN(printargs), "n32_listxattr"		},
+[6187] = { 3,	TF,		SEN(printargs), "n32_llistxattr"		},
+[6188] = { 3,	TD,		SEN(printargs), "n32_flistxattr"		},
+[6189] = { 2,	TF,		SEN(printargs), "n32_removexattr"		},
+[6190] = { 2,	TF,		SEN(printargs), "n32_lremovexattr"		},
+[6191] = { 2,	TD,		SEN(printargs), "n32_fremovexattr"		},
+[6192] = { 2,	TS,		SEN(printargs), "n32_tkill"			},
+[6193] = { 1,	0,		SEN(printargs), "n32_time"			},
+[6194] = { 6,	0,		SEN(printargs), "n32_futex"			},
+[6195] = { 3,	0,		SEN(printargs), "n32_sched_setaffinity"	},
+[6196] = { 3,	0,		SEN(printargs), "n32_sched_getaffinity"	},
+[6197] = { 3,	0,		SEN(printargs), "n32_cacheflush"		},
+[6198] = { 3,	0,		SEN(printargs), "n32_cachectl"		},
+[6199] = { 4,	0,		SEN(printargs), "n32_sysmips"		},
+[6200] = { 2,	0,		SEN(printargs), "n32_io_setup"		},
+[6201] = { 1,	0,		SEN(printargs), "n32_io_destroy"		},
+[6202] = { 5,	0,		SEN(printargs), "n32_io_getevents"		},
+[6203] = { 3,	0,		SEN(printargs), "n32_io_submit"		},
+[6204] = { 3,	0,		SEN(printargs), "n32_io_cancel"		},
+[6205] = { 1,	TP|SE,		SEN(printargs), "n32_exit_group"		},
+[6206] = { 3,	0,		SEN(printargs), "n32_lookup_dcookie"	},
+[6207] = { 1,	TD,		SEN(printargs), "n32_epoll_create"		},
+[6208] = { 4,	TD,		SEN(printargs), "n32_epoll_ctl"		},
+[6209] = { 4,	TD,		SEN(printargs), "n32_epoll_wait"		},
+[6210] = { 5,	TM|SI,		SEN(printargs), "n32_remap_file_pages"	},
+[6211] = { 0,	TS,		SEN(printargs), "n32_rt_sigreturn"		},
+[6212] = { 3,	TD,		SEN(printargs), "n32_fcntl64"		},
+[6213] = { 1,	0,		SEN(printargs), "n32_set_tid_address"	},
+[6214] = { 0,	0,		SEN(printargs), "n32_restart_syscall"	},
+[6215] = { 4,	TI,		SEN(printargs), "n32_semtimedop"		},
+[6216] = { 4,	TD,		SEN(printargs), "n32_fadvise64"		},
+[6217] = { 3,	TF,		SEN(printargs), "n32_statfs64"		},
+[6218] = { 3,	TD,		SEN(printargs), "n32_fstatfs64"		},
+[6219] = { 4,	TD|TN,		SEN(printargs), "n32_sendfile64"		},
+[6220] = { 3,	0,		SEN(printargs), "n32_timer_create"		},
+[6221] = { 4,	0,		SEN(printargs), "n32_timer_settime"		},
+[6222] = { 2,	0,		SEN(printargs), "n32_timer_gettime"		},
+[6223] = { 1,	0,		SEN(printargs), "n32_timer_getoverrun"	},
+[6224] = { 1,	0,		SEN(printargs), "n32_timer_delete"		},
+[6225] = { 2,	0,		SEN(printargs), "n32_clock_settime"		},
+[6226] = { 2,	0,		SEN(printargs), "n32_clock_gettime"		},
+[6227] = { 2,	0,		SEN(printargs), "n32_clock_getres"		},
+[6228] = { 4,	0,		SEN(printargs), "n32_clock_nanosleep"	},
+[6229] = { 3,	TS,		SEN(printargs), "n32_tgkill"		},
+[6230] = { 2,	TF,		SEN(printargs), "n32_utimes"		},
+[6231] = { 6,	TM,		SEN(printargs), "n32_mbind"			},
+[6232] = { 5,	TM,		SEN(printargs), "n32_get_mempolicy"		},
+[6233] = { 3,	TM,		SEN(printargs), "n32_set_mempolicy"		},
+[6234] = { 4,	0,		SEN(printargs), "n32_mq_open"		},
+[6235] = { 1,	0,		SEN(printargs), "n32_mq_unlink"		},
+[6236] = { 5,	0,		SEN(printargs), "n32_mq_timedsend"		},
+[6237] = { 5,	0,		SEN(printargs), "n32_mq_timedreceive"	},
+[6238] = { 2,	0,		SEN(printargs), "n32_mq_notify"		},
+[6239] = { 3,	0,		SEN(printargs), "n32_mq_getsetattr"		},
+[6240] = { 5,	0,		SEN(printargs), "n32_vserver"		},
+[6241] = { 5,	TP,		SEN(printargs), "n32_waitid"		},
+[6242] = { },
+[6243] = { 5,	0,		SEN(printargs), "n32_add_key"		},
+[6244] = { 4,	0,		SEN(printargs), "n32_request_key"		},
+[6245] = { 5,	0,		SEN(printargs), "n32_keyctl"		},
+[6246] = { 1,	0,		SEN(printargs), "n32_set_thread_area"	},
+[6247] = { 0,	TD,		SEN(printargs), "n32_inotify_init"		},
+[6248] = { 3,	TD,		SEN(printargs), "n32_inotify_add_watch"	},
+[6249] = { 2,	TD,		SEN(printargs), "n32_inotify_rm_watch"	},
+[6250] = { 4,	TM,		SEN(printargs), "n32_migrate_pages"		},
+[6251] = { 4,	TD|TF,		SEN(printargs), "n32_openat"		},
+[6252] = { 3,	TD|TF,		SEN(printargs), "n32_mkdirat"		},
+[6253] = { 4,	TD|TF,		SEN(printargs), "n32_mknodat"		},
+[6254] = { 5,	TD|TF,		SEN(printargs), "n32_fchownat"		},
+[6255] = { 3,	TD|TF,		SEN(printargs), "n32_futimesat"		},
+[6256] = { 4,	TD|TF,		SEN(printargs), "n32_newfstatat"		},
+[6257] = { 3,	TD|TF,		SEN(printargs), "n32_unlinkat"		},
+[6258] = { 4,	TD|TF,		SEN(printargs), "n32_renameat"		},
+[6259] = { 5,	TD|TF,		SEN(printargs), "n32_linkat"		},
+[6260] = { 3,	TD|TF,		SEN(printargs), "n32_symlinkat"		},
+[6261] = { 4,	TD|TF,		SEN(printargs), "n32_readlinkat"		},
+[6262] = { 3,	TD|TF,		SEN(printargs), "n32_fchmodat"		},
+[6263] = { 3,	TD|TF,		SEN(printargs), "n32_faccessat"		},
+[6264] = { 6,	TD,		SEN(printargs), "n32_pselect6"		},
+[6265] = { 5,	TD,		SEN(printargs), "n32_ppoll"			},
+[6266] = { 1,	TP,		SEN(printargs), "n32_unshare"		},
+[6267] = { 6,	TD,		SEN(printargs), "n32_splice"		},
+[6268] = { 4,	TD,		SEN(printargs), "n32_sync_file_range"	},
+[6269] = { 4,	TD,		SEN(printargs), "n32_tee"			},
+[6270] = { 4,	TD,		SEN(printargs), "n32_vmsplice"		},
+[6271] = { 6,	TM,		SEN(printargs), "n32_move_pages"		},
+[6272] = { 2,	0,		SEN(printargs), "n32_set_robust_list"	},
+[6273] = { 3,	0,		SEN(printargs), "n32_get_robust_list"	},
+[6274] = { 4,	0,		SEN(printargs), "n32_kexec_load"		},
+[6275] = { 3,	0,		SEN(printargs), "n32_getcpu"		},
+[6276] = { 6,	TD,		SEN(printargs), "n32_epoll_pwait"		},
+[6277] = { 3,	0,		SEN(printargs), "n32_ioprio_set"		},
+[6278] = { 2,	0,		SEN(printargs), "n32_ioprio_get"		},
+[6279] = { 4,	TD|TF,		SEN(printargs), "n32_utimensat"		},
+[6280] = { 3,	TD|TS,		SEN(printargs), "n32_signalfd"		},
+[6281] = { 4,	TD,		SEN(printargs), "n32_timerfd"		},
+[6282] = { 1,	TD,		SEN(printargs), "n32_eventfd"		},
+[6283] = { 4,	TD,		SEN(printargs), "n32_fallocate"		},
+[6284] = { 2,	TD,		SEN(printargs), "n32_timerfd_create"	},
+[6285] = { 2,	TD,		SEN(printargs), "n32_timerfd_gettime"	},
+[6286] = { 4,	TD,		SEN(printargs), "n32_timerfd_settime"	},
+[6287] = { 4,	TD|TS,		SEN(printargs), "n32_signalfd4"		},
+[6288] = { 2,	TD,		SEN(printargs), "n32_eventfd2"		},
+[6289] = { 1,	TD,		SEN(printargs), "n32_epoll_create1"		},
+[6290] = { 3,	TD,		SEN(printargs), "n32_dup3"			},
+[6291] = { 2,	TD,		SEN(printargs), "n32_pipe2"			},
+[6292] = { 1,	TD,		SEN(printargs), "n32_inotify_init1"		},
+[6293] = { 4,	TD,		SEN(printargs), "n32_preadv"		},
+[6294] = { 4,	TD,		SEN(printargs), "n32_pwritev"		},
+[6295] = { 4,	TP|TS,		SEN(printargs), "n32_rt_tgsigqueueinfo"	},
+[6296] = { 5,	TD,		SEN(printargs), "n32_perf_event_open"	},
+[6297] = { 4,	TN,		SEN(printargs), "n32_accept4"		},
+[6298] = { 5,	TN,		SEN(printargs), "n32_recvmmsg"		},
+[6299] = { 3,	TD,		SEN(printargs), "n32_getdents64"		},
+[6300] = { 2,	TD,		SEN(printargs), "n32_fanotify_init"		},
+[6301] = { 5,	TD|TF,		SEN(printargs), "n32_fanotify_mark"		},
+[6302] = { 4,	0,		SEN(printargs), "n32_prlimit64"		},
+[6303] = { 5,	TD|TF,		SEN(printargs), "n32_name_to_handle_at"	},
+[6304] = { 3,	TD,		SEN(printargs), "n32_open_by_handle_at"	},
+[6305] = { 2,	0,		SEN(printargs), "n32_clock_adjtime"		},
+[6306] = { 1,	TD,		SEN(printargs), "n32_syncfs"		},
+[6307] = { 4,	TN,		SEN(printargs), "n32_sendmmsg"		},
+[6308] = { 2,	TD,		SEN(printargs), "n32_setns"			},
+[6309] = { 6,	0,		SEN(printargs), "n32_process_vm_readv"	},
+[6310] = { 6,	0,		SEN(printargs), "n32_process_vm_writev"	},
+[6311] = { 5,	0,		SEN(printargs), "n32_kcmp"			},
+[6312] = { 3,	TD,		SEN(printargs), "n32_finit_module"		},
+[6313] = { 3,	0,		SEN(printargs), "n32_sched_setattr"		},
+[6314] = { 4,	0,		SEN(printargs), "n32_sched_getattr"		},
+[6315] = { 5,	TD|TF,		SEN(printargs), "n32_renameat2"		},
+[6316] = { 3,	0,		SEN(printargs), "n32_seccomp",		},
+[6317] = { 3,	0,		SEN(printargs), "n32_getrandom",		},
+[6318] = { 2,	TD,		SEN(printargs), "n32_memfd_create",		},
+[6319] = { 3,	TD,		SEN(printargs), "n32_bpf",			},
+[6320] = { 5,	TD|TF|TP|SE|SI,	SEN(printargs), "n32_execveat",		},
+[6321 ... 6399] = { },
diff --git a/strace/linux/mips/syscallent-n32.h b/strace/linux/mips/syscallent-n32.h
new file mode 100644
index 0000000..398b12c
--- /dev/null
+++ b/strace/linux/mips/syscallent-n32.h
@@ -0,0 +1,338 @@
+#if defined LINUX_MIPSN32
+/* For an N32 strace decode the N32 64-bit syscalls. */
+[6000] = { 3,	TD,		SEN(read),			"read"			}, /* start of Linux N32 */
+[6001] = { 3,	TD,		SEN(write),			"write"			},
+[6002] = { 3,	TD|TF,		SEN(open),			"open"			},
+[6003] = { 1,	TD,		SEN(close),			"close"			},
+[6004] = { 2,	TF,		SEN(stat64),			"stat"			},
+[6005] = { 2,	TD,		SEN(fstat64),			"fstat"			},
+[6006] = { 2,	TF,		SEN(lstat64),			"lstat"			},
+[6007] = { 3,	TD,		SEN(poll),			"poll"			},
+[6008] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[6009] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[6010] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[6011] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[6012] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[6013] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[6014] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[6015] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[6016] = { 4,	TD,		SEN(pread),			"pread64"		},
+[6017] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[6018] = { 3,	TD,		SEN(readv),			"readv"			},
+[6019] = { 3,	TD,		SEN(writev),			"writev"		},
+[6020] = { 2,	TF,		SEN(access),			"access"		},
+[6021] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[6022] = { 5,	TD,		SEN(select),			"_newselect"		},
+[6023] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[6024] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[6025] = { 3,	TM,		SEN(msync),			"msync"			},
+[6026] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[6027] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[6028] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[6029] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[6030] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[6031] = { 1,	TD,		SEN(dup),			"dup"			},
+[6032] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[6033] = { 0,	TS,		SEN(pause),			"pause"			},
+[6034] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[6035] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[6036] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[6037] = { 1,	0,		SEN(alarm),			"alarm"			},
+[6038] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[6039] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[6040] = { 3,	TN,		SEN(socket),			"socket"		},
+[6041] = { 3,	TN,		SEN(connect),			"connect"		},
+[6042] = { 3,	TN,		SEN(accept),			"accept"		},
+[6043] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[6044] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[6045] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[6046] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[6047] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[6048] = { 3,	TN,		SEN(bind),			"bind"			},
+[6049] = { 2,	TN,		SEN(listen),			"listen"		},
+[6050] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[6051] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[6052] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[6053] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[6054] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[6055] = { 5,	TP,		SEN(clone),			"clone"			},
+[6056] = { 0,	TP,		SEN(fork),			"fork"			},
+[6057] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[6058] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[6059] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[6060] = { 2,	TS,		SEN(kill),			"kill"			},
+[6061] = { 1,	0,		SEN(uname),			"uname"			},
+[6062] = { 3,	TI,		SEN(semget),			"semget"		},
+[6063] = { 3,	TI,		SEN(semop),			"semop"			},
+[6064] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[6065] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[6066] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[6067] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[6068] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[6069] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[6070] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[6071] = { 2,	TD,		SEN(flock),			"flock"			},
+[6072] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[6073] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[6074] = { 2,	TF,		SEN(truncate64),		"truncate"		},
+[6075] = { 2,	TD,		SEN(ftruncate64),		"ftruncate"		},
+[6076] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[6077] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[6078] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[6079] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[6080] = { 2,	TF,		SEN(rename),			"rename"		},
+[6081] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[6082] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[6083] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[6084] = { 2,	TF,		SEN(link),			"link"			},
+[6085] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[6086] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[6087] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[6088] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[6089] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[6090] = { 3,	TF,		SEN(chown),			"chown"			},
+[6091] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[6092] = { 3,	TF,		SEN(chown),			"lchown"		},
+[6093] = { 1,	NF,		SEN(umask),			"umask"			},
+[6094] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[6095] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[6096] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[6097] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[6098] = { 1,	0,		SEN(times),			"times"			},
+[6099] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[6100] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[6101] = { 3,	0,		SEN(syslog),			"syslog"		},
+[6102] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[6103] = { 1,	0,		SEN(setuid),			"setuid"		},
+[6104] = { 1,	0,		SEN(setgid),			"setgid"		},
+[6105] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[6106] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[6107] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[6108] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[6109] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[6110] = { 0,	0,		SEN(setsid),			"setsid"		},
+[6111] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[6112] = { 2,	0,		SEN(setregid),			"setregid"		},
+[6113] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[6114] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[6115] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[6116] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[6117] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[6118] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[6119] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[6120] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[6121] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[6122] = { 1,	0,		SEN(getsid),			"getsid"		},
+[6123] = { 2,	0,		SEN(capget),			"capget"		},
+[6124] = { 2,	0,		SEN(capset),			"capset"		},
+[6125] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[6126] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[6127] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[6128] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[6129] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[6130] = { 2,	TF,		SEN(utime),			"utime"			},
+[6131] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[6132] = { 1,	NF,		SEN(personality),		"personality"		},
+[6133] = { 2,	0,		SEN(ustat),			"ustat"			},
+[6134] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[6135] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[6136] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[6137] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[6138] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[6139] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[6140] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[6141] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[6142] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[6143] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[6144] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[6145] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[6146] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[6147] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[6148] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[6149] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[6150] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[6151] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[6152] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[6153] = { 5,	0,		SEN(prctl),			"prctl"			},
+[6154] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[6155] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[6156] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[6157] = { 0,	0,		SEN(sync),			"sync"			},
+[6158] = { 1,	TF,		SEN(acct),			"acct"			},
+[6159] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[6160] = { 5,	TF,		SEN(mount),			"mount"			},
+[6161] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[6162] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[6163] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[6164] = { 4,	0,		SEN(reboot),			"reboot"		},
+[6165] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[6166] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[6167] = { 2,	0,		SEN(create_module),		"create_module"		},
+[6168] = { 3,	0,		SEN(init_module),		"init_module"		},
+[6169] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[6170] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[6171] = { 5,	0,		SEN(query_module),		"query_module"		},
+[6172] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[6173] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[6174] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[6175] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[6176] = { 0,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[6177] = { 0,	0,		SEN(printargs),			"reserved177"		},
+[6178] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[6179] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[6180] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[6181] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[6182] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[6183] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[6184] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[6185] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[6186] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[6187] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[6188] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[6189] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[6190] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[6191] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[6192] = { 2,	TS,		SEN(kill),			"tkill"			},
+[6193] = { 1,	0,		SEN(time),			"time"			},
+[6194] = { 6,	0,		SEN(futex),			"futex"			},
+[6195] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[6196] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[6197] = { 3,	0,		SEN(printargs),			"cacheflush"		},
+[6198] = { 3,	0,		SEN(printargs),			"cachectl"		},
+[6199] = { 4,	0,		SEN(sysmips),			"sysmips"		},
+[6200] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[6201] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[6202] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[6203] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[6204] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[6205] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[6206] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[6207] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[6208] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[6209] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[6210] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[6211] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[6212] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[6213] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[6214] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[6215] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[6216] = { 4,	TD,		SEN(fadvise64_64),		"fadvise64"		},
+[6217] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[6218] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[6219] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[6220] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[6221] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[6222] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[6223] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[6224] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[6225] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[6226] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[6227] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[6228] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[6229] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[6230] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[6231] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[6232] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[6233] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[6234] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[6235] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[6236] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[6237] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[6238] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[6239] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[6240] = { 5,	0,		SEN(vserver),			"vserver"		},
+[6241] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[6242] = { },
+[6243] = { 5,	0,		SEN(add_key),			"add_key"		},
+[6244] = { 4,	0,		SEN(request_key),		"request_key"		},
+[6245] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[6246] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[6247] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[6248] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[6249] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[6250] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[6251] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[6252] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[6253] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[6254] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[6255] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[6256] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[6257] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[6258] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[6259] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[6260] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[6261] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[6262] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[6263] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[6264] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[6265] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[6266] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[6267] = { 6,	TD,		SEN(splice),			"splice"		},
+[6268] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[6269] = { 4,	TD,		SEN(tee),			"tee"			},
+[6270] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[6271] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[6272] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[6273] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[6274] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[6275] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[6276] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[6277] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[6278] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[6279] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[6280] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[6281] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[6282] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[6283] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[6284] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[6285] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[6286] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[6287] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[6288] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[6289] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[6290] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[6291] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[6292] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[6293] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[6294] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[6295] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[6296] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[6297] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[6298] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[6299] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[6300] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[6301] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[6302] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[6303] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[6304] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[6305] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[6306] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[6307] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[6308] = { 2,	TD,		SEN(setns),			"setns"			},
+[6309] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[6310] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[6311] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[6312] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[6313] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[6314] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[6315] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[6316] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[6317] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[6318] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[6319] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[6320] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[6321] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[6322] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[6323] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[6324] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[6325] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[6326] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+# define SYS_socket_subcall      6400
+# include "subcall.h"
+
+#else
+
+# include "syscallent-n32-stub.h"
+
+#endif
diff --git a/strace/linux/mips/syscallent-n64-stub.h b/strace/linux/mips/syscallent-n64-stub.h
new file mode 100644
index 0000000..0e923f1
--- /dev/null
+++ b/strace/linux/mips/syscallent-n64-stub.h
@@ -0,0 +1,318 @@
+[5000] = { 3,	TD,		SEN(printargs), "n64_read"			}, /* start of Linux N64 */
+[5001] = { 3,	TD,		SEN(printargs), "n64_write"			},
+[5002] = { 3,	TD|TF,		SEN(printargs), "n64_open"			},
+[5003] = { 1,	TD,		SEN(printargs), "n64_close"			},
+[5004] = { 2,	TF,		SEN(printargs), "n64_stat"			},
+[5005] = { 2,	TD,		SEN(printargs), "n64_fstat"			},
+[5006] = { 2,	TF,		SEN(printargs), "n64_lstat"			},
+[5007] = { 3,	TD,		SEN(printargs), "n64_poll"			},
+[5008] = { 3,	TD,		SEN(printargs), "n64_lseek"			},
+[5009] = { 6,	TD|TM|SI,	SEN(printargs), "n64_mmap"			},
+[5010] = { 3,	TM|SI,		SEN(printargs), "n64_mprotect"		},
+[5011] = { 2,	TM|SI,		SEN(printargs), "n64_munmap"		},
+[5012] = { 1,	TM|SI,		SEN(printargs), "n64_brk"			},
+[5013] = { 4,	TS,		SEN(printargs), "n64_rt_sigaction"		},
+[5014] = { 4,	TS,		SEN(printargs), "n64_rt_sigprocmask"	},
+[5015] = { 3,	TD,		SEN(printargs), "n64_ioctl"			},
+[5016] = { 4,	TD,		SEN(printargs), "n64_pread64"		},
+[5017] = { 4,	TD,		SEN(printargs), "n64_pwrite64"		},
+[5018] = { 3,	TD,		SEN(printargs), "n64_readv"			},
+[5019] = { 3,	TD,		SEN(printargs), "n64_writev"		},
+[5020] = { 2,	TF,		SEN(printargs), "n64_access"		},
+[5021] = { 1,	TD,		SEN(printargs), "n64_pipe"			},
+[5022] = { 5,	TD,		SEN(printargs), "n64_select"		},
+[5023] = { 0,	0,		SEN(printargs), "n64_sched_yield"		},
+[5024] = { 5,	TM|SI,		SEN(printargs), "n64_mremap"		},
+[5025] = { 3,	TM,		SEN(printargs), "n64_msync"			},
+[5026] = { 3,	TM,		SEN(printargs), "n64_mincore"		},
+[5027] = { 3,	TM,		SEN(printargs), "n64_madvise"		},
+[5028] = { 3,	TI,		SEN(printargs), "n64_shmget"		},
+[5029] = { 3,	TI|TM|SI,	SEN(printargs), "n64_shmat"			},
+[5030] = { 3,	TI,		SEN(printargs), "n64_shmctl"		},
+[5031] = { 1,	TD,		SEN(printargs), "n64_dup"			},
+[5032] = { 2,	TD,		SEN(printargs), "n64_dup2"			},
+[5033] = { 0,	TS,		SEN(printargs), "n64_pause"			},
+[5034] = { 2,	0,		SEN(printargs), "n64_nanosleep"		},
+[5035] = { 2,	0,		SEN(printargs), "n64_getitimer"		},
+[5036] = { 3,	0,		SEN(printargs), "n64_setitimer"		},
+[5037] = { 1,	0,		SEN(printargs), "n64_alarm"			},
+[5038] = { 0,	0,		SEN(printargs), "n64_getpid"		},
+[5039] = { 4,	TD|TN,		SEN(printargs), "n64_sendfile"		},
+[5040] = { 3,	TN,		SEN(printargs), "n64_socket"		},
+[5041] = { 3,	TN,		SEN(printargs), "n64_connect"		},
+[5042] = { 3,	TN,		SEN(printargs), "n64_accept"		},
+[5043] = { 6,	TN,		SEN(printargs), "n64_sendto"		},
+[5044] = { 6,	TN,		SEN(printargs), "n64_recvfrom"		},
+[5045] = { 3,	TN,		SEN(printargs), "n64_sendmsg"		},
+[5046] = { 3,	TN,		SEN(printargs), "n64_recvmsg"		},
+[5047] = { 2,	TN,		SEN(printargs), "n64_shutdown"		},
+[5048] = { 3,	TN,		SEN(printargs), "n64_bind"			},
+[5049] = { 2,	TN,		SEN(printargs), "n64_listen"		},
+[5050] = { 3,	TN,		SEN(printargs), "n64_getsockname"		},
+[5051] = { 3,	TN,		SEN(printargs), "n64_getpeername"		},
+[5052] = { 4,	TN,		SEN(printargs), "n64_socketpair"		},
+[5053] = { 5,	TN,		SEN(printargs), "n64_setsockopt"		},
+[5054] = { 5,	TN,		SEN(printargs), "n64_getsockopt"		},
+[5055] = { 5,	TP,		SEN(printargs), "n64_clone"			},
+[5056] = { 0,	TP,		SEN(printargs), "n64_fork"			},
+[5057] = { 3,	TF|TP|SE|SI,	SEN(printargs), "n64_execve"		},
+[5058] = { 1,	TP|SE,		SEN(printargs), "n64_exit"			},
+[5059] = { 4,	TP,		SEN(printargs), "n64_wait4"			},
+[5060] = { 2,	TS,		SEN(printargs), "n64_kill"			},
+[5061] = { 1,	0,		SEN(printargs), "n64_uname"			},
+[5062] = { 3,	TI,		SEN(printargs), "n64_semget"		},
+[5063] = { 3,	TI,		SEN(printargs), "n64_semop"			},
+[5064] = { 4,	TI,		SEN(printargs), "n64_semctl"		},
+[5065] = { 1,	TI|TM|SI,	SEN(printargs), "n64_shmdt"			},
+[5066] = { 2,	TI,		SEN(printargs), "n64_msgget"		},
+[5067] = { 4,	TI,		SEN(printargs), "n64_msgsnd"		},
+[5068] = { 5,	TI,		SEN(printargs), "n64_msgrcv"		},
+[5069] = { 3,	TI,		SEN(printargs), "n64_msgctl"		},
+[5070] = { 3,	TD,		SEN(printargs), "n64_fcntl"			},
+[5071] = { 2,	TD,		SEN(printargs), "n64_flock"			},
+[5072] = { 1,	TD,		SEN(printargs), "n64_fsync"			},
+[5073] = { 1,	TD,		SEN(printargs), "n64_fdatasync"		},
+[5074] = { 2,	TF,		SEN(printargs), "n64_truncate"		},
+[5075] = { 2,	TD,		SEN(printargs), "n64_ftruncate"		},
+[5076] = { 3,	TD,		SEN(printargs), "n64_getdents"		},
+[5077] = { 2,	TF,		SEN(printargs), "n64_getcwd"		},
+[5078] = { 1,	TF,		SEN(printargs), "n64_chdir"			},
+[5079] = { 1,	TD,		SEN(printargs), "n64_fchdir"		},
+[5080] = { 2,	TF,		SEN(printargs), "n64_rename"		},
+[5081] = { 2,	TF,		SEN(printargs), "n64_mkdir"			},
+[5082] = { 1,	TF,		SEN(printargs), "n64_rmdir"			},
+[5083] = { 2,	TD|TF,		SEN(printargs), "n64_creat"			},
+[5084] = { 2,	TF,		SEN(printargs), "n64_link"			},
+[5085] = { 1,	TF,		SEN(printargs), "n64_unlink"		},
+[5086] = { 2,	TF,		SEN(printargs), "n64_symlink"		},
+[5087] = { 3,	TF,		SEN(printargs), "n64_readlink"		},
+[5088] = { 2,	TF,		SEN(printargs), "n64_chmod"			},
+[5089] = { 2,	TD,		SEN(printargs), "n64_fchmod"		},
+[5090] = { 3,	TF,		SEN(printargs), "n64_chown"			},
+[5091] = { 3,	TD,		SEN(printargs), "n64_fchown"		},
+[5092] = { 3,	TF,		SEN(printargs), "n64_lchown"		},
+[5093] = { 1,	0,		SEN(printargs), "n64_umask"			},
+[5094] = { 2,	0,		SEN(printargs), "n64_gettimeofday"		},
+[5095] = { 2,	0,		SEN(printargs), "n64_getrlimit"		},
+[5096] = { 2,	0,		SEN(printargs), "n64_getrusage"		},
+[5097] = { 1,	0,		SEN(printargs), "n64_sysinfo"		},
+[5098] = { 1,	0,		SEN(printargs), "n64_times"			},
+[5099] = { 4,	0,		SEN(printargs), "n64_ptrace"		},
+[5100] = { 0,	NF,		SEN(printargs), "n64_getuid"		},
+[5101] = { 3,	0,		SEN(printargs), "n64_syslog"		},
+[5102] = { 0,	NF,		SEN(printargs), "n64_getgid"		},
+[5103] = { 1,	0,		SEN(printargs), "n64_setuid"		},
+[5104] = { 1,	0,		SEN(printargs), "n64_setgid"		},
+[5105] = { 0,	NF,		SEN(printargs), "n64_geteuid"		},
+[5106] = { 0,	NF,		SEN(printargs), "n64_getegid"		},
+[5107] = { 2,	0,		SEN(printargs), "n64_setpgid"		},
+[5108] = { 0,	0,		SEN(printargs), "n64_getppid"		},
+[5109] = { 0,	0,		SEN(printargs), "n64_getpgrp"		},
+[5110] = { 0,	0,		SEN(printargs), "n64_setsid"		},
+[5111] = { 2,	0,		SEN(printargs), "n64_setreuid"		},
+[5112] = { 2,	0,		SEN(printargs), "n64_setregid"		},
+[5113] = { 2,	0,		SEN(printargs), "n64_getgroups"		},
+[5114] = { 2,	0,		SEN(printargs), "n64_setgroups"		},
+[5115] = { 3,	0,		SEN(printargs), "n64_setresuid"		},
+[5116] = { 3,	0,		SEN(printargs), "n64_getresuid"		},
+[5117] = { 3,	0,		SEN(printargs), "n64_setresgid"		},
+[5118] = { 3,	0,		SEN(printargs), "n64_getresgid"		},
+[5119] = { 0,	0,		SEN(printargs), "n64_getpgid"		},
+[5120] = { 1,	NF,		SEN(printargs), "n64_setfsuid"		},
+[5121] = { 1,	NF,		SEN(printargs), "n64_setfsgid"		},
+[5122] = { 1,	0,		SEN(printargs), "n64_getsid"		},
+[5123] = { 2,	0,		SEN(printargs), "n64_capget"		},
+[5124] = { 2,	0,		SEN(printargs), "n64_capset"		},
+[5125] = { 2,	TS,		SEN(printargs), "n64_rt_sigpending"		},
+[5126] = { 4,	TS,		SEN(printargs), "n64_rt_sigtimedwait"	},
+[5127] = { 3,	TS,		SEN(printargs), "n64_rt_sigqueueinfo"	},
+[5128] = { 2,	TS,		SEN(printargs), "n64_rt_sigsuspend"		},
+[5129] = { 2,	TS,		SEN(printargs), "n64_sigaltstack"		},
+[5130] = { 2,	TF,		SEN(printargs), "n64_utime"			},
+[5131] = { 3,	TF,		SEN(printargs), "n64_mknod"			},
+[5132] = { 1,	0,		SEN(printargs), "n64_personality"		},
+[5133] = { 2,	0,		SEN(printargs), "n64_ustat"			},
+[5134] = { 3,	TF,		SEN(printargs), "n64_statfs"		},
+[5135] = { 3,	TD,		SEN(printargs), "n64_fstatfs"		},
+[5136] = { 5,	0,		SEN(printargs), "n64_sysfs"			},
+[5137] = { 2,	0,		SEN(printargs), "n64_getpriority"		},
+[5138] = { 3,	0,		SEN(printargs), "n64_setpriority"		},
+[5139] = { 2,	0,		SEN(printargs), "n64_sched_setparam"	},
+[5140] = { 2,	0,		SEN(printargs), "n64_sched_getparam"	},
+[5141] = { 3,	0,		SEN(printargs), "n64_sched_setscheduler"	},
+[5142] = { 1,	0,		SEN(printargs), "n64_sched_getscheduler"	},
+[5143] = { 1,	0,		SEN(printargs), "n64_sched_get_priority_max"},
+[5144] = { 1,	0,		SEN(printargs), "n64_sched_get_priority_min"},
+[5145] = { 2,	0,		SEN(printargs), "n64_sched_rr_get_interval"	},
+[5146] = { 2,	TM,		SEN(printargs), "n64_mlock"			},
+[5147] = { 2,	TM,		SEN(printargs), "n64_munlock"		},
+[5148] = { 1,	TM,		SEN(printargs), "n64_mlockall"		},
+[5149] = { 0,	TM,		SEN(printargs), "n64_munlockall"		},
+[5150] = { 0,	0,		SEN(printargs), "n64_vhangup"		},
+[5151] = { 2,	TF,		SEN(printargs), "n64_pivot_root"		},
+[5152] = { 1,	0,		SEN(printargs), "n64__sysctl"		},
+[5153] = { 5,	0,		SEN(printargs), "n64_prctl"			},
+[5154] = { 1,	0,		SEN(printargs), "n64_adjtimex"		},
+[5155] = { 2,	0,		SEN(printargs), "n64_setrlimit"		},
+[5156] = { 1,	TF,		SEN(printargs), "n64_chroot"		},
+[5157] = { 0,	0,		SEN(printargs), "n64_sync"			},
+[5158] = { 1,	TF,		SEN(printargs), "n64_acct"			},
+[5159] = { 2,	0,		SEN(printargs), "n64_settimeofday"		},
+[5160] = { 5,	TF,		SEN(printargs), "n64_mount"			},
+[5161] = { 2,	TF,		SEN(printargs), "n64_umount2"		},
+[5162] = { 2,	TF,		SEN(printargs), "n64_swapon"		},
+[5163] = { 1,	TF,		SEN(printargs), "n64_swapoff"		},
+[5164] = { 4,	0,		SEN(printargs), "n64_reboot"		},
+[5165] = { 2,	0,		SEN(printargs), "n64_sethostname"		},
+[5166] = { 2,	0,		SEN(printargs), "n64_setdomainname"		},
+[5167] = { 2,	0,		SEN(printargs), "n64_create_module"		},
+[5168] = { 4,	0,		SEN(printargs), "n64_init_module"		},
+[5169] = { 1,	0,		SEN(printargs), "n64_delete_module"		},
+[5170] = { 1,	0,		SEN(printargs), "n64_get_kernel_syms"	},
+[5171] = { 5,	0,		SEN(printargs), "n64_query_module"		},
+[5172] = { 4,	TF,		SEN(printargs), "n64_quotactl"		},
+[5173] = { 3,	0,		SEN(printargs), "n64_nfsservctl"		},
+[5174] = { 5,	TN,		SEN(printargs), "n64_getpmsg"		},
+[5175] = { 5,	TN,		SEN(printargs), "n64_putpmsg"		},
+[5176] = { 0,	0,		SEN(printargs), "n64_afs_syscall"		},
+[5177] = { 0,	0,		SEN(printargs), "n64_reserved177"		},
+[5178] = { 0,	0,		SEN(printargs), "n64_gettid"		},
+[5179] = { 3,	TD,		SEN(printargs), "n64_readahead"		},
+[5180] = { 5,	TF,		SEN(printargs), "n64_setxattr"		},
+[5181] = { 5,	TF,		SEN(printargs), "n64_lsetxattr"		},
+[5182] = { 5,	TD,		SEN(printargs), "n64_fsetxattr"		},
+[5183] = { 4,	TF,		SEN(printargs), "n64_getxattr"		},
+[5184] = { 4,	TF,		SEN(printargs), "n64_lgetxattr"		},
+[5185] = { 4,	TD,		SEN(printargs), "n64_fgetxattr"		},
+[5186] = { 3,	TF,		SEN(printargs), "n64_listxattr"		},
+[5187] = { 3,	TF,		SEN(printargs), "n64_llistxattr"		},
+[5188] = { 3,	TD,		SEN(printargs), "n64_flistxattr"		},
+[5189] = { 2,	TF,		SEN(printargs), "n64_removexattr"		},
+[5190] = { 2,	TF,		SEN(printargs), "n64_lremovexattr"		},
+[5191] = { 2,	TD,		SEN(printargs), "n64_fremovexattr"		},
+[5192] = { 2,	TS,		SEN(printargs), "n64_tkill"			},
+[5193] = { 1,	0,		SEN(printargs), "n64_time"			},
+[5194] = { 6,	0,		SEN(printargs), "n64_futex"			},
+[5195] = { 3,	0,		SEN(printargs), "n64_sched_setaffinity"	},
+[5196] = { 3,	0,		SEN(printargs), "n64_sched_getaffinity"	},
+[5197] = { 3,	0,		SEN(printargs), "n64_cacheflush"		},
+[5198] = { 3,	0,		SEN(printargs), "n64_cachectl"		},
+[5199] = { 4,	0,		SEN(printargs), "n64_sysmips"		},
+[5200] = { 2,	0,		SEN(printargs), "n64_io_setup"		},
+[5201] = { 1,	0,		SEN(printargs), "n64_io_destroy"		},
+[5202] = { 5,	0,		SEN(printargs), "n64_io_getevents"		},
+[5203] = { 3,	0,		SEN(printargs), "n64_io_submit"		},
+[5204] = { 3,	0,		SEN(printargs), "n64_io_cancel"		},
+[5205] = { 1,	TP|SE,		SEN(printargs), "n64_exit_group"		},
+[5206] = { 3,	0,		SEN(printargs), "n64_lookup_dcookie"	},
+[5207] = { 1,	TD,		SEN(printargs), "n64_epoll_create"		},
+[5208] = { 4,	TD,		SEN(printargs), "n64_epoll_ctl"		},
+[5209] = { 4,	TD,		SEN(printargs), "n64_epoll_wait"		},
+[5210] = { 5,	TM|SI,		SEN(printargs), "n64_remap_file_pages"	},
+[5211] = { 0,	TS,		SEN(printargs), "n64_rt_sigreturn"		},
+[5212] = { 1,	0,		SEN(printargs), "n64_set_tid_address"	},
+[5213] = { 0,	0,		SEN(printargs), "n64_restart_syscall"	},
+[5214] = { 4,	TI,		SEN(printargs), "n64_semtimedop"		},
+[5215] = { 4,	TD,		SEN(printargs), "n64_fadvise64_64"		},
+[5216] = { 3,	0,		SEN(printargs), "n64_timer_create"		},
+[5217] = { 4,	0,		SEN(printargs), "n64_timer_settime"		},
+[5218] = { 2,	0,		SEN(printargs), "n64_timer_gettime"		},
+[5219] = { 1,	0,		SEN(printargs), "n64_timer_getoverrun"	},
+[5220] = { 1,	0,		SEN(printargs), "n64_timer_delete"		},
+[5221] = { 2,	0,		SEN(printargs), "n64_clock_settime"		},
+[5222] = { 2,	0,		SEN(printargs), "n64_clock_gettime"		},
+[5223] = { 2,	0,		SEN(printargs), "n64_clock_getres"		},
+[5224] = { 4,	0,		SEN(printargs), "n64_clock_nanosleep"	},
+[5225] = { 3,	TS,		SEN(printargs), "n64_tgkill"		},
+[5226] = { 2,	TF,		SEN(printargs), "n64_utimes"		},
+[5227] = { 6,	TM,		SEN(printargs), "n64_mbind"			},
+[5228] = { 5,	TM,		SEN(printargs), "n64_get_mempolicy"		},
+[5229] = { 3,	TM,		SEN(printargs), "n64_set_mempolicy"		},
+[5230] = { 4,	0,		SEN(printargs), "n64_mq_open"		},
+[5231] = { 1,	0,		SEN(printargs), "n64_mq_unlink"		},
+[5232] = { 5,	0,		SEN(printargs), "n64_mq_timedsend"		},
+[5233] = { 5,	0,		SEN(printargs), "n64_mq_timedreceive"	},
+[5234] = { 2,	0,		SEN(printargs), "n64_mq_notify"		},
+[5235] = { 3,	0,		SEN(printargs), "n64_mq_getsetattr"		},
+[5236] = { 5,	0,		SEN(printargs), "n64_vserver"		},
+[5237] = { 5,	TP,		SEN(printargs), "n64_waitid"		},
+[5238] = { },
+[5239] = { 5,	0,		SEN(printargs), "n64_add_key"		},
+[5240] = { 4,	0,		SEN(printargs), "n64_request_key"		},
+[5241] = { 5,	0,		SEN(printargs), "n64_keyctl"		},
+[5242] = { 1,	0,		SEN(printargs), "n64_set_thread_area"	},
+[5243] = { 0,	TD,		SEN(printargs), "n64_inotify_init"		},
+[5244] = { 3,	TD,		SEN(printargs), "n64_inotify_add_watch"	},
+[5245] = { 2,	TD,		SEN(printargs), "n64_inotify_rm_watch"	},
+[5246] = { 4,	TM,		SEN(printargs), "n64_migrate_pages"		},
+[5247] = { 4,	TD|TF,		SEN(printargs), "n64_openat"		},
+[5248] = { 3,	TD|TF,		SEN(printargs), "n64_mkdirat"		},
+[5249] = { 4,	TD|TF,		SEN(printargs), "n64_mknodat"		},
+[5250] = { 5,	TD|TF,		SEN(printargs), "n64_fchownat"		},
+[5251] = { 3,	TD|TF,		SEN(printargs), "n64_futimesat"		},
+[5252] = { 4,	TD|TF,		SEN(printargs), "n64_newfstatat"		},
+[5253] = { 3,	TD|TF,		SEN(printargs), "n64_unlinkat"		},
+[5254] = { 4,	TD|TF,		SEN(printargs), "n64_renameat"		},
+[5255] = { 5,	TD|TF,		SEN(printargs), "n64_linkat"		},
+[5256] = { 3,	TD|TF,		SEN(printargs), "n64_symlinkat"		},
+[5257] = { 4,	TD|TF,		SEN(printargs), "n64_readlinkat"		},
+[5258] = { 3,	TD|TF,		SEN(printargs), "n64_fchmodat"		},
+[5259] = { 3,	TD|TF,		SEN(printargs), "n64_faccessat"		},
+[5260] = { 6,	TD,		SEN(printargs), "n64_pselect6"		},
+[5261] = { 5,	TD,		SEN(printargs), "n64_ppoll"			},
+[5262] = { 1,	TP,		SEN(printargs), "n64_unshare"		},
+[5263] = { 6,	TD,		SEN(printargs), "n64_splice"		},
+[5264] = { 4,	TD,		SEN(printargs), "n64_sync_file_range"	},
+[5265] = { 4,	TD,		SEN(printargs), "n64_tee"			},
+[5266] = { 4,	TD,		SEN(printargs), "n64_vmsplice"		},
+[5267] = { 6,	TM,		SEN(printargs), "n64_move_pages"		},
+[5268] = { 2,	0,		SEN(printargs), "n64_set_robust_list"	},
+[5269] = { 3,	0,		SEN(printargs), "n64_get_robust_list"	},
+[5270] = { 4,	0,		SEN(printargs), "n64_kexec_load"		},
+[5271] = { 3,	0,		SEN(printargs), "n64_getcpu"		},
+[5272] = { 6,	TD,		SEN(printargs), "n64_epoll_pwait"		},
+[5273] = { 3,	0,		SEN(printargs), "n64_ioprio_set"		},
+[5274] = { 2,	0,		SEN(printargs), "n64_ioprio_get"		},
+[5275] = { 4,	TD|TF,		SEN(printargs), "n64_utimensat"		},
+[5276] = { 3,	TD|TS,		SEN(printargs), "n64_signalfd"		},
+[5277] = { 4,	TD,		SEN(printargs), "n64_timerfd"		},
+[5278] = { 1,	TD,		SEN(printargs), "n64_eventfd"		},
+[5279] = { 4,	TD,		SEN(printargs), "n64_fallocate"		},
+[5280] = { 2,	TD,		SEN(printargs), "n64_timerfd_create"	},
+[5281] = { 2,	TD,		SEN(printargs), "n64_timerfd_gettime"	},
+[5282] = { 4,	TD,		SEN(printargs), "n64_timerfd_settime"	},
+[5283] = { 4,	TD|TS,		SEN(printargs), "n64_signalfd4"		},
+[5284] = { 2,	TD,		SEN(printargs), "n64_eventfd2"		},
+[5285] = { 1,	TD,		SEN(printargs), "n64_epoll_create1"		},
+[5286] = { 3,	TD,		SEN(printargs), "n64_dup3"			},
+[5287] = { 2,	TD,		SEN(printargs), "n64_pipe2"			},
+[5288] = { 1,	TD,		SEN(printargs), "n64_inotify_init1"		},
+[5289] = { 4,	TD,		SEN(printargs), "n64_preadv"		},
+[5290] = { 4,	TD,		SEN(printargs), "n64_pwritev"		},
+[5291] = { 4,	TP|TS,		SEN(printargs), "n64_rt_tgsigqueueinfo"	},
+[5292] = { 5,	TD,		SEN(printargs), "n64_perf_event_open"	},
+[5293] = { 4,	TN,		SEN(printargs), "n64_accept4"		},
+[5294] = { 5,	TN,		SEN(printargs), "n64_recvmmsg"		},
+[5295] = { 2,	TD,		SEN(printargs), "n64_fanotify_init"		},
+[5296] = { 5,	TD|TF,		SEN(printargs), "n64_fanotify_mark"		},
+[5297] = { 4,	0,		SEN(printargs), "n64_prlimit64"		},
+[5298] = { 5,	TD|TF,		SEN(printargs), "n64_name_to_handle_at"	},
+[5299] = { 3,	TD,		SEN(printargs), "n64_open_by_handle_at"	},
+[5300] = { 2,	0,		SEN(printargs), "n64_clock_adjtime"		},
+[5301] = { 1,	TD,		SEN(printargs), "n64_syncfs"		},
+[5302] = { 4,	TN,		SEN(printargs), "n64_sendmmsg"		},
+[5303] = { 2,	TD,		SEN(printargs), "n64_setns"			},
+[5304] = { 6,	0,		SEN(printargs), "n64_process_vm_readv"	},
+[5305] = { 6,	0,		SEN(printargs), "n64_process_vm_writev"	},
+[5306] = { 5,	0,		SEN(printargs), "n64_kcmp"			},
+[5307] = { 3,	TD,		SEN(printargs), "n64_finit_module"		},
+[5308] = { 3,	TD,		SEN(printargs), "n64_getdents64"		},
+[5309] = { 3,	0,		SEN(printargs), "n64_sched_setattr"		},
+[5310] = { 4,	0,		SEN(printargs), "n64_sched_getattr"		},
+[5311] = { 5,	TD|TF,		SEN(printargs), "n64_renameat2"		},
+[5312] = { 3,	0,		SEN(printargs), "n64_seccomp",		},
+[5313] = { 3,	0,		SEN(printargs), "n64_getrandom",		},
+[5314] = { 2,	TD,		SEN(printargs), "n64_memfd_create",		},
+[5315] = { 3,	TD,		SEN(printargs), "n64_bpf",			},
+[5316] = { 5,	TD|TF|TP|SE|SI,	SEN(printargs), "n64_execveat",		},
+[5317 ... 5399] = { },
diff --git a/strace/linux/mips/syscallent-n64.h b/strace/linux/mips/syscallent-n64.h
new file mode 100644
index 0000000..7321f0e
--- /dev/null
+++ b/strace/linux/mips/syscallent-n64.h
@@ -0,0 +1,334 @@
+#if defined LINUX_MIPSN64
+/* For an N64 strace decode the N64 64-bit syscalls. */
+[5000] = { 3,	TD,		SEN(read),			"read"			}, /* start of Linux N64 */
+[5001] = { 3,	TD,		SEN(write),			"write"			},
+[5002] = { 3,	TD|TF,		SEN(open),			"open"			},
+[5003] = { 1,	TD,		SEN(close),			"close"			},
+[5004] = { 2,	TF,		SEN(stat),			"stat"			},
+[5005] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[5006] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[5007] = { 3,	TD,		SEN(poll),			"poll"			},
+[5008] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[5009] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[5010] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[5011] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[5012] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[5013] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[5014] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[5015] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[5016] = { 4,	TD,		SEN(pread),			"pread64"		},
+[5017] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[5018] = { 3,	TD,		SEN(readv),			"readv"			},
+[5019] = { 3,	TD,		SEN(writev),			"writev"		},
+[5020] = { 2,	TF,		SEN(access),			"access"		},
+[5021] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[5022] = { 5,	TD,		SEN(select),			"_newselect"		},
+[5023] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[5024] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[5025] = { 3,	TM,		SEN(msync),			"msync"			},
+[5026] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[5027] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[5028] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[5029] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[5030] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[5031] = { 1,	TD,		SEN(dup),			"dup"			},
+[5032] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[5033] = { 0,	TS,		SEN(pause),			"pause"			},
+[5034] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[5035] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[5036] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[5037] = { 1,	0,		SEN(alarm),			"alarm"			},
+[5038] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[5039] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[5040] = { 3,	TN,		SEN(socket),			"socket"		},
+[5041] = { 3,	TN,		SEN(connect),			"connect"		},
+[5042] = { 3,	TN,		SEN(accept),			"accept"		},
+[5043] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[5044] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[5045] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[5046] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[5047] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[5048] = { 3,	TN,		SEN(bind),			"bind"			},
+[5049] = { 2,	TN,		SEN(listen),			"listen"		},
+[5050] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[5051] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[5052] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[5053] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[5054] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[5055] = { 5,	TP,		SEN(clone),			"clone"			},
+[5056] = { 0,	TP,		SEN(fork),			"fork"			},
+[5057] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[5058] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[5059] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[5060] = { 2,	TS,		SEN(kill),			"kill"			},
+[5061] = { 1,	0,		SEN(uname),			"uname"			},
+[5062] = { 3,	TI,		SEN(semget),			"semget"		},
+[5063] = { 3,	TI,		SEN(semop),			"semop"			},
+[5064] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[5065] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[5066] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[5067] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[5068] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[5069] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[5070] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[5071] = { 2,	TD,		SEN(flock),			"flock"			},
+[5072] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[5073] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[5074] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[5075] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[5076] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[5077] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[5078] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[5079] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[5080] = { 2,	TF,		SEN(rename),			"rename"		},
+[5081] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[5082] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[5083] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[5084] = { 2,	TF,		SEN(link),			"link"			},
+[5085] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[5086] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[5087] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[5088] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[5089] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[5090] = { 3,	TF,		SEN(chown),			"chown"			},
+[5091] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[5092] = { 3,	TF,		SEN(chown),			"lchown"		},
+[5093] = { 1,	NF,		SEN(umask),			"umask"			},
+[5094] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[5095] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[5096] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[5097] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[5098] = { 1,	0,		SEN(times),			"times"			},
+[5099] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[5100] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[5101] = { 3,	0,		SEN(syslog),			"syslog"		},
+[5102] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[5103] = { 1,	0,		SEN(setuid),			"setuid"		},
+[5104] = { 1,	0,		SEN(setgid),			"setgid"		},
+[5105] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[5106] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[5107] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[5108] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[5109] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[5110] = { 0,	0,		SEN(setsid),			"setsid"		},
+[5111] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[5112] = { 2,	0,		SEN(setregid),			"setregid"		},
+[5113] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[5114] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[5115] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[5116] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[5117] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[5118] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[5119] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[5120] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[5121] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[5122] = { 1,	0,		SEN(getsid),			"getsid"		},
+[5123] = { 2,	0,		SEN(capget),			"capget"		},
+[5124] = { 2,	0,		SEN(capset),			"capset"		},
+[5125] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[5126] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[5127] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[5128] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[5129] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[5130] = { 2,	TF,		SEN(utime),			"utime"			},
+[5131] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[5132] = { 1,	NF,		SEN(personality),		"personality"		},
+[5133] = { 2,	0,		SEN(ustat),			"ustat"			},
+[5134] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[5135] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[5136] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[5137] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[5138] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[5139] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[5140] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[5141] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[5142] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[5143] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[5144] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[5145] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[5146] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[5147] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[5148] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[5149] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[5150] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[5151] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[5152] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[5153] = { 5,	0,		SEN(prctl),			"prctl"			},
+[5154] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[5155] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[5156] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[5157] = { 0,	0,		SEN(sync),			"sync"			},
+[5158] = { 1,	TF,		SEN(acct),			"acct"			},
+[5159] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[5160] = { 5,	TF,		SEN(mount),			"mount"			},
+[5161] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[5162] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[5163] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[5164] = { 4,	0,		SEN(reboot),			"reboot"		},
+[5165] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[5166] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[5167] = { 2,	0,		SEN(create_module),		"create_module"		},
+[5168] = { 3,	0,		SEN(init_module),		"init_module"		},
+[5169] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[5170] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[5171] = { 5,	0,		SEN(query_module),		"query_module"		},
+[5172] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[5173] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[5174] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[5175] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[5176] = { 0,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[5177] = { 0,	0,		SEN(printargs),			"reserved177"		},
+[5178] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[5179] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[5180] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[5181] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[5182] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[5183] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[5184] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[5185] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[5186] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[5187] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[5188] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[5189] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[5190] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[5191] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[5192] = { 2,	TS,		SEN(kill),			"tkill"			},
+[5193] = { 1,	0,		SEN(time),			"time"			},
+[5194] = { 6,	0,		SEN(futex),			"futex"			},
+[5195] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[5196] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[5197] = { 3,	0,		SEN(printargs),			"cacheflush"		},
+[5198] = { 3,	0,		SEN(printargs),			"cachectl"		},
+[5199] = { 4,	0,		SEN(sysmips),			"sysmips"		},
+[5200] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[5201] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[5202] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[5203] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[5204] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[5205] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[5206] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[5207] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[5208] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[5209] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[5210] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[5211] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[5212] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[5213] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[5214] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[5215] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[5216] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[5217] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[5218] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[5219] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[5220] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[5221] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[5222] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[5223] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[5224] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[5225] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[5226] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[5227] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[5228] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[5229] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[5230] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[5231] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[5232] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[5233] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[5234] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[5235] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[5236] = { 5,	0,		SEN(vserver),			"vserver"		},
+[5237] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[5238] = { },
+[5239] = { 5,	0,		SEN(add_key),			"add_key"		},
+[5240] = { 4,	0,		SEN(request_key),		"request_key"		},
+[5241] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[5242] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[5243] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[5244] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[5245] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[5246] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[5247] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[5248] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[5249] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[5250] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[5251] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[5252] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[5253] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[5254] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[5255] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[5256] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[5257] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[5258] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[5259] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[5260] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[5261] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[5262] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[5263] = { 6,	TD,		SEN(splice),			"splice"		},
+[5264] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[5265] = { 4,	TD,		SEN(tee),			"tee"			},
+[5266] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[5267] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[5268] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[5269] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[5270] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[5271] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[5272] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[5273] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[5274] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[5275] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[5276] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[5277] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[5278] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[5279] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[5280] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[5281] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[5282] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[5283] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[5284] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[5285] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[5286] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[5287] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[5288] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[5289] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[5290] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[5291] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[5292] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[5293] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[5294] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[5295] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[5296] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[5297] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[5298] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[5299] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[5300] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[5301] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[5302] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[5303] = { 2,	TD,		SEN(setns),			"setns"			},
+[5304] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[5305] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[5306] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[5307] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[5308] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[5309] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[5310] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[5311] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[5312] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[5313] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[5314] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[5315] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[5316] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[5317] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[5318] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[5319] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[5320] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[5321] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[5322] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+# define SYS_socket_subcall      5400
+# include "subcall.h"
+
+#else
+
+# include "syscallent-n64-stub.h"
+
+#endif
diff --git a/strace/linux/mips/syscallent-o32-stub.h b/strace/linux/mips/syscallent-o32-stub.h
new file mode 100644
index 0000000..1409fed
--- /dev/null
+++ b/strace/linux/mips/syscallent-o32-stub.h
@@ -0,0 +1,358 @@
+[4000] = { MA,	0,		SEN(printargs), "o32_syscall"		}, /* start of Linux o32 */
+[4001] = { 1,	TP|SE,		SEN(printargs), "o32_exit"			},
+[4002] = { 0,	TP,		SEN(printargs), "o32_fork"			},
+[4003] = { 3,	TD,		SEN(printargs), "o32_read"			},
+[4004] = { 3,	TD,		SEN(printargs), "o32_write"			},
+[4005] = { 3,	TD|TF,		SEN(printargs), "o32_open"			},
+[4006] = { 1,	TD,		SEN(printargs), "o32_close"			},
+[4007] = { 3,	TP,		SEN(printargs), "o32_waitpid"		},
+[4008] = { 2,	TD|TF,		SEN(printargs), "o32_creat"			},
+[4009] = { 2,	TF,		SEN(printargs), "o32_link"			},
+[4010] = { 1,	TF,		SEN(printargs), "o32_unlink"		},
+[4011] = { 3,	TF|TP|SE|SI,	SEN(printargs), "o32_execve"		},
+[4012] = { 1,	TF,		SEN(printargs), "o32_chdir"			},
+[4013] = { 1,	0,		SEN(printargs), "o32_time"			},
+[4014] = { 3,	TF,		SEN(printargs), "o32_mknod"			},
+[4015] = { 2,	TF,		SEN(printargs), "o32_chmod"			},
+[4016] = { 3,	TF,		SEN(printargs), "o32_lchown"		},
+[4017] = { 0,	TM,		SEN(printargs), "o32_break"			},
+[4018] = { 2,	TF,		SEN(printargs), "o32_oldstat"		},
+[4019] = { 3,	TD,		SEN(printargs), "o32_lseek"			},
+[4020] = { 0,	0,		SEN(printargs), "o32_getpid"		},
+[4021] = { 5,	TF,		SEN(printargs), "o32_mount"			},
+[4022] = { 1,	TF,		SEN(printargs), "o32_umount"		},
+[4023] = { 1,	0,		SEN(printargs), "o32_setuid"		},
+[4024] = { 0,	NF,		SEN(printargs), "o32_getuid"		},
+[4025] = { 1,	0,		SEN(printargs), "o32_stime"			},
+[4026] = { 4,	0,		SEN(printargs), "o32_ptrace"		},
+[4027] = { 1,	0,		SEN(printargs), "o32_alarm"			},
+[4028] = { 2,	TD,		SEN(printargs), "o32_oldfstat"		},
+[4029] = { 0,	TS,		SEN(printargs), "o32_pause"			},
+[4030] = { 2,	TF,		SEN(printargs), "o32_utime"			},
+[4031] = { 0,	0,		SEN(printargs), "o32_stty"			},
+[4032] = { 0,	0,		SEN(printargs), "o32_gtty"			},
+[4033] = { 2,	TF,		SEN(printargs), "o32_access"		},
+[4034] = { 1,	0,		SEN(printargs), "o32_nice"			},
+[4035] = { 1,	0,		SEN(printargs), "o32_ftime"			},
+[4036] = { 0,	0,		SEN(printargs), "o32_sync"			},
+[4037] = { 2,	TS,		SEN(printargs), "o32_kill"			},
+[4038] = { 2,	TF,		SEN(printargs), "o32_rename"		},
+[4039] = { 2,	TF,		SEN(printargs), "o32_mkdir"			},
+[4040] = { 1,	TF,		SEN(printargs), "o32_rmdir"			},
+[4041] = { 1,	TD,		SEN(printargs), "o32_dup"			},
+[4042] = { 1,	TD,		SEN(printargs), "o32_pipe"			},
+[4043] = { 1,	0,		SEN(printargs), "o32_times"			},
+[4044] = { 0,	0,		SEN(printargs), "o32_prof"			},
+[4045] = { 1,	TM|SI,		SEN(printargs), "o32_brk"			},
+[4046] = { 1,	0,		SEN(printargs), "o32_setgid"		},
+[4047] = { 0,	NF,		SEN(printargs), "o32_getgid"		},
+[4048] = { 1,	TS,		SEN(printargs), "o32_signal"		},
+[4049] = { 0,	NF,		SEN(printargs), "o32_geteuid"		},
+[4050] = { 0,	NF,		SEN(printargs), "o32_getegid"		},
+[4051] = { 1,	TF,		SEN(printargs), "o32_acct"			},
+[4052] = { 2,	TF,		SEN(printargs), "o32_umount2"		},
+[4053] = { 0,	0,		SEN(printargs), "o32_lock"			},
+[4054] = { 3,	TD,		SEN(printargs), "o32_ioctl"			},
+[4055] = { 3,	TD,		SEN(printargs), "o32_fcntl"			},
+[4056] = { 0,	0,		SEN(printargs), "o32_mpx"			},
+[4057] = { 2,	0,		SEN(printargs), "o32_setpgid"		},
+[4058] = { 0,	0,		SEN(printargs), "o32_ulimit"		},
+[4059] = { 1,	0,		SEN(printargs), "o32_oldolduname"		},
+[4060] = { 1,	0,		SEN(printargs), "o32_umask"			},
+[4061] = { 1,	TF,		SEN(printargs), "o32_chroot"		},
+[4062] = { 2,	0,		SEN(printargs), "o32_ustat"			},
+[4063] = { 2,	TD,		SEN(printargs), "o32_dup2"			},
+[4064] = { 0,	0,		SEN(printargs), "o32_getppid"		},
+[4065] = { 0,	0,		SEN(printargs), "o32_getpgrp"		},
+[4066] = { 0,	0,		SEN(printargs), "o32_setsid"		},
+[4067] = { 3,	TS,		SEN(printargs), "o32_sigaction"		},
+[4068] = { 0,	TS,		SEN(printargs), "o32_sgetmask"		},
+[4069] = { 1,	TS,		SEN(printargs), "o32_ssetmask"		},
+[4070] = { 2,	0,		SEN(printargs), "o32_setreuid"		},
+[4071] = { 2,	0,		SEN(printargs), "o32_setregid"		},
+[4072] = { 3,	TS,		SEN(printargs), "o32_sigsuspend"		},
+[4073] = { 1,	TS,		SEN(printargs), "o32_sigpending"		},
+[4074] = { 2,	0,		SEN(printargs), "o32_sethostname"		},
+[4075] = { 2,	0,		SEN(printargs), "o32_setrlimit"		},
+[4076] = { 2,	0,		SEN(printargs), "o32_getrlimit"		},
+[4077] = { 2,	0,		SEN(printargs), "o32_getrusage"		},
+[4078] = { 2,	0,		SEN(printargs), "o32_gettimeofday"		},
+[4079] = { 2,	0,		SEN(printargs), "o32_settimeofday"		},
+[4080] = { 2,	0,		SEN(printargs), "o32_getgroups"		},
+[4081] = { 2,	0,		SEN(printargs), "o32_setgroups"		},
+[4082] = { 0,	0,		SEN(printargs), "o32_reserved82"		},
+[4083] = { 2,	TF,		SEN(printargs), "o32_symlink"		},
+[4084] = { 2,	TF,		SEN(printargs), "o32_oldlstat"		},
+[4085] = { 3,	TF,		SEN(printargs), "o32_readlink"		},
+[4086] = { 1,	TF,		SEN(printargs), "o32_uselib"		},
+[4087] = { 2,	TF,		SEN(printargs), "o32_swapon"		},
+[4088] = { 4,	0,		SEN(printargs), "o32_reboot"		},
+[4089] = { 3,	TD,		SEN(printargs), "o32_readdir"		},
+[4090] = { 6,	TD|TM|SI,	SEN(printargs), "o32_mmap"			},
+[4091] = { 2,	TM|SI,		SEN(printargs), "o32_munmap"		},
+[4092] = { 2,	TF,		SEN(printargs), "o32_truncate"		},
+[4093] = { 2,	TD,		SEN(printargs), "o32_ftruncate"		},
+[4094] = { 2,	TD,		SEN(printargs), "o32_fchmod"		},
+[4095] = { 3,	TD,		SEN(printargs), "o32_fchown"		},
+[4096] = { 2,	0,		SEN(printargs), "o32_getpriority"		},
+[4097] = { 3,	0,		SEN(printargs), "o32_setpriority"		},
+[4098] = { 0,	0,		SEN(printargs), "o32_profil"		},
+[4099] = { 3,	TF,		SEN(printargs), "o32_statfs"		},
+[4100] = { 3,	TD,		SEN(printargs), "o32_fstatfs"		},
+[4101] = { 0,	0,		SEN(printargs), "o32_ioperm"		},
+[4102] = { 2,	TD,		SEN(printargs), "o32_socketcall"		},
+[4103] = { 3,	0,		SEN(printargs), "o32_syslog"		},
+[4104] = { 3,	0,		SEN(printargs), "o32_setitimer"		},
+[4105] = { 2,	0,		SEN(printargs), "o32_getitimer"		},
+[4106] = { 2,	TF,		SEN(printargs), "o32_stat"			},
+[4107] = { 2,	TF,		SEN(printargs), "o32_lstat"			},
+[4108] = { 2,	TD,		SEN(printargs), "o32_fstat"			},
+[4109] = { 1,	0,		SEN(printargs), "o32_olduname"		},
+[4110] = { 0,	0,		SEN(printargs), "o32_iopl"			},
+[4111] = { 0,	0,		SEN(printargs), "o32_vhangup"		},
+[4112] = { 0,	0,		SEN(printargs), "o32_idle"			},
+[4113] = { 5,	0,		SEN(printargs), "o32_vm86"			},
+[4114] = { 4,	TP,		SEN(printargs), "o32_wait4"			},
+[4115] = { 1,	TF,		SEN(printargs), "o32_swapoff"		},
+[4116] = { 1,	0,		SEN(printargs), "o32_sysinfo"		},
+[4117] = { 6,	TI,		SEN(printargs), "o32_ipc"			},
+[4118] = { 1,	TD,		SEN(printargs), "o32_fsync"			},
+[4119] = { 0,	TS,		SEN(printargs), "o32_sigreturn"		},
+[4120] = { 5,	TP,		SEN(printargs), "o32_clone"			},
+[4121] = { 2,	0,		SEN(printargs), "o32_setdomainname"		},
+[4122] = { 1,	0,		SEN(printargs), "o32_uname"			},
+[4123] = { 0,	0,		SEN(printargs), "o32_modify_ldt"		},
+[4124] = { 1,	0,		SEN(printargs), "o32_adjtimex"		},
+[4125] = { 3,	TM|SI,		SEN(printargs), "o32_mprotect"		},
+[4126] = { 3,	TS,		SEN(printargs), "o32_sigprocmask"		},
+[4127] = { 2,	0,		SEN(printargs), "o32_create_module"		},
+[4128] = { 3,	0,		SEN(printargs), "o32_init_module"		},
+[4129] = { 2,	0,		SEN(printargs), "o32_delete_module"		},
+[4130] = { 1,	0,		SEN(printargs), "o32_get_kernel_syms"	},
+[4131] = { 4,	TF,		SEN(printargs), "o32_quotactl"		},
+[4132] = { 1,	0,		SEN(printargs), "o32_getpgid"		},
+[4133] = { 1,	TD,		SEN(printargs), "o32_fchdir"		},
+[4134] = { 2,	0,		SEN(printargs), "o32_bdflush"		},
+[4135] = { 3,	0,		SEN(printargs), "o32_sysfs"			},
+[4136] = { 1,	0,		SEN(printargs), "o32_personality"		},
+[4137] = { 0,	0,		SEN(printargs), "o32_afs_syscall"		},
+[4138] = { 1,	NF,		SEN(printargs), "o32_setfsuid"		},
+[4139] = { 1,	NF,		SEN(printargs), "o32_setfsgid"		},
+[4140] = { 5,	TD,		SEN(printargs), "o32__llseek"		},
+[4141] = { 3,	TD,		SEN(printargs), "o32_getdents"		},
+[4142] = { 5,	TD,		SEN(printargs), "o32_select"		},
+[4143] = { 2,	TD,		SEN(printargs), "o32_flock"			},
+[4144] = { 3,	TM,		SEN(printargs), "o32_msync"			},
+[4145] = { 3,	TD,		SEN(printargs), "o32_readv"			},
+[4146] = { 3,	TD,		SEN(printargs), "o32_writev"		},
+[4147] = { 3,	0,		SEN(printargs), "o32_cacheflush"		},
+[4148] = { 3,	0,		SEN(printargs), "o32_cachectl"		},
+[4149] = { 4,	0,		SEN(printargs), "o32_sysmips"		},
+[4150] = { 0,	0,		SEN(printargs), "o32_setup"			},
+[4151] = { 1,	0,		SEN(printargs), "o32_getsid"		},
+[4152] = { 1,	TD,		SEN(printargs), "o32_fdatasync"		},
+[4153] = { 1,	0,		SEN(printargs), "o32__sysctl"		},
+[4154] = { 2,	TM,		SEN(printargs), "o32_mlock"			},
+[4155] = { 2,	TM,		SEN(printargs), "o32_munlock"		},
+[4156] = { 1,	TM,		SEN(printargs), "o32_mlockall"		},
+[4157] = { 0,	TM,		SEN(printargs), "o32_munlockall"		},
+[4158] = { 2,	0,		SEN(printargs), "o32_sched_setparam"	},
+[4159] = { 2,	0,		SEN(printargs), "o32_sched_getparam"	},
+[4160] = { 3,	0,		SEN(printargs), "o32_sched_setscheduler"	},
+[4161] = { 1,	0,		SEN(printargs), "o32_sched_getscheduler"	},
+[4162] = { 0,	0,		SEN(printargs), "o32_sched_yield"		},
+[4163] = { 1,	0,		SEN(printargs), "o32_sched_get_priority_max"},
+[4164] = { 1,	0,		SEN(printargs), "o32_sched_get_priority_min"},
+[4165] = { 2,	0,		SEN(printargs), "o32_sched_rr_get_interval"	},
+[4166] = { 2,	0,		SEN(printargs), "o32_nanosleep"		},
+[4167] = { 5,	TM|SI,		SEN(printargs), "o32_mremap"		},
+[4168] = { 3,	TN,		SEN(printargs), "o32_accept"		},
+[4169] = { 3,	TN,		SEN(printargs), "o32_bind"			},
+[4170] = { 3,	TN,		SEN(printargs), "o32_connect"		},
+[4171] = { 3,	TN,		SEN(printargs), "o32_getpeername"		},
+[4172] = { 3,	TN,		SEN(printargs), "o32_getsockname"		},
+[4173] = { 5,	TN,		SEN(printargs), "o32_getsockopt"		},
+[4174] = { 2,	TN,		SEN(printargs), "o32_listen"		},
+[4175] = { 4,	TN,		SEN(printargs), "o32_recv"			},
+[4176] = { 6,	TN,		SEN(printargs), "o32_recvfrom"		},
+[4177] = { 3,	TN,		SEN(printargs), "o32_recvmsg"		},
+[4178] = { 4,	TN,		SEN(printargs), "o32_send"			},
+[4179] = { 3,	TN,		SEN(printargs), "o32_sendmsg"		},
+[4180] = { 6,	TN,		SEN(printargs), "o32_sendto"		},
+[4181] = { 5,	TN,		SEN(printargs), "o32_setsockopt"		},
+[4182] = { 2,	TN,		SEN(printargs), "o32_shutdown"		},
+[4183] = { 3,	TN,		SEN(printargs), "o32_socket"		},
+[4184] = { 4,	TN,		SEN(printargs), "o32_socketpair"		},
+[4185] = { 3,	0,		SEN(printargs), "o32_setresuid"		},
+[4186] = { 3,	0,		SEN(printargs), "o32_getresuid"		},
+[4187] = { 5,	0,		SEN(printargs), "o32_query_module"		},
+[4188] = { 3,	TD,		SEN(printargs), "o32_poll"			},
+[4189] = { 3,	0,		SEN(printargs), "o32_nfsservctl"		},
+[4190] = { 3,	0,		SEN(printargs), "o32_setresgid"		},
+[4191] = { 3,	0,		SEN(printargs), "o32_getresgid"		},
+[4192] = { 5,	0,		SEN(printargs), "o32_prctl"			},
+[4193] = { 0,	TS,		SEN(printargs), "o32_rt_sigreturn"		},
+[4194] = { 4,	TS,		SEN(printargs), "o32_rt_sigaction"		},
+[4195] = { 4,	TS,		SEN(printargs), "o32_rt_sigprocmask"	},
+[4196] = { 2,	TS,		SEN(printargs), "o32_rt_sigpending"		},
+[4197] = { 4,	TS,		SEN(printargs), "o32_rt_sigtimedwait"	},
+[4198] = { 3,	TS,		SEN(printargs), "o32_rt_sigqueueinfo"	},
+[4199] = { 2,	TS,		SEN(printargs), "o32_rt_sigsuspend"		},
+[4200] = { 6,	TD,		SEN(printargs), "o32_pread64"		},
+[4201] = { 6,	TD,		SEN(printargs), "o32_pwrite64"		},
+[4202] = { 3,	TF,		SEN(printargs), "o32_chown"			},
+[4203] = { 2,	TF,		SEN(printargs), "o32_getcwd"		},
+[4204] = { 2,	0,		SEN(printargs), "o32_capget"		},
+[4205] = { 2,	0,		SEN(printargs), "o32_capset"		},
+[4206] = { 2,	TS,		SEN(printargs), "o32_sigaltstack"		},
+[4207] = { 4,	TD|TN,		SEN(printargs), "o32_sendfile"		},
+[4208] = { 5,	TN,		SEN(printargs), "o32_getpmsg"		},
+[4209] = { 5,	TN,		SEN(printargs), "o32_putpmsg"		},
+[4210] = { 6,	TD|TM|SI,	SEN(printargs), "o32_mmap2"			},
+[4211] = { 4,	TF,		SEN(printargs), "o32_truncate64"		},
+[4212] = { 4,	TD,		SEN(printargs), "o32_ftruncate64"		},
+[4213] = { 2,	TF,		SEN(printargs), "o32_stat64"		},
+[4214] = { 2,	TF,		SEN(printargs), "o32_lstat64"		},
+[4215] = { 2,	TD,		SEN(printargs), "o32_fstat64"		},
+[4216] = { 2,	TF,		SEN(printargs), "o32_pivot_root"		},
+[4217] = { 3,	TM,		SEN(printargs), "o32_mincore"		},
+[4218] = { 3,	TM,		SEN(printargs), "o32_madvise"		},
+[4219] = { 3,	TD,		SEN(printargs), "o32_getdents64"		},
+[4220] = { 3,	TD,		SEN(printargs), "o32_fcntl64"		},
+[4221] = { },
+[4222] = { 0,	0,		SEN(printargs), "o32_gettid"		},
+[4223] = { 5,	TD,		SEN(printargs), "o32_readahead"		},
+[4224] = { 5,	TF,		SEN(printargs), "o32_setxattr"		},
+[4225] = { 5,	TF,		SEN(printargs), "o32_lsetxattr"		},
+[4226] = { 5,	TD,		SEN(printargs), "o32_fsetxattr"		},
+[4227] = { 4,	TF,		SEN(printargs), "o32_getxattr"		},
+[4228] = { 4,	TF,		SEN(printargs), "o32_lgetxattr"		},
+[4229] = { 4,	TD,		SEN(printargs), "o32_fgetxattr"		},
+[4230] = { 3,	TF,		SEN(printargs), "o32_listxattr"		},
+[4231] = { 3,	TF,		SEN(printargs), "o32_llistxattr"		},
+[4232] = { 3,	TD,		SEN(printargs), "o32_flistxattr"		},
+[4233] = { 2,	TF,		SEN(printargs), "o32_removexattr"		},
+[4234] = { 2,	TF,		SEN(printargs), "o32_lremovexattr"		},
+[4235] = { 2,	TD,		SEN(printargs), "o32_fremovexattr"		},
+[4236] = { 2,	TS,		SEN(printargs), "o32_tkill"			},
+[4237] = { 4,	TD|TN,		SEN(printargs), "o32_sendfile64"		},
+[4238] = { 6,	0,		SEN(printargs), "o32_futex"			},
+[4239] = { 3,	0,		SEN(printargs), "o32_sched_setaffinity"	},
+[4240] = { 3,	0,		SEN(printargs), "o32_sched_getaffinity"	},
+[4241] = { 2,	0,		SEN(printargs), "o32_io_setup"		},
+[4242] = { 1,	0,		SEN(printargs), "o32_io_destroy"		},
+[4243] = { 5,	0,		SEN(printargs), "o32_io_getevents"		},
+[4244] = { 3,	0,		SEN(printargs), "o32_io_submit"		},
+[4245] = { 3,	0,		SEN(printargs), "o32_io_cancel"		},
+[4246] = { 1,	TP|SE,		SEN(printargs), "o32_exit_group"		},
+[4247] = { 4,	0,		SEN(printargs), "o32_lookup_dcookie"	},
+[4248] = { 1,	TD,		SEN(printargs), "o32_epoll_create"		},
+[4249] = { 4,	TD,		SEN(printargs), "o32_epoll_ctl"		},
+[4250] = { 4,	TD,		SEN(printargs), "o32_epoll_wait"		},
+[4251] = { 5,	TM|SI,		SEN(printargs), "o32_remap_file_pages"	},
+[4252] = { 1,	0,		SEN(printargs), "o32_set_tid_address"	},
+[4253] = { 0,	0,		SEN(printargs), "o32_restart_syscall"	},
+[4254] = { 7,	TD,		SEN(printargs), "o32_fadvise64_64"		},
+[4255] = { 3,	TF,		SEN(printargs), "o32_statfs64"		},
+[4256] = { 2,	TD,		SEN(printargs), "o32_fstatfs64"		},
+[4257] = { 3,	0,		SEN(printargs), "o32_timer_create"		},
+[4258] = { 4,	0,		SEN(printargs), "o32_timer_settime"		},
+[4259] = { 2,	0,		SEN(printargs), "o32_timer_gettime"		},
+[4260] = { 1,	0,		SEN(printargs), "o32_timer_getoverrun"	},
+[4261] = { 1,	0,		SEN(printargs), "o32_timer_delete"		},
+[4262] = { 2,	0,		SEN(printargs), "o32_clock_settime"		},
+[4263] = { 2,	0,		SEN(printargs), "o32_clock_gettime"		},
+[4264] = { 2,	0,		SEN(printargs), "o32_clock_getres"		},
+[4265] = { 4,	0,		SEN(printargs), "o32_clock_nanosleep"	},
+[4266] = { 3,	TS,		SEN(printargs), "o32_tgkill"		},
+[4267] = { 2,	TF,		SEN(printargs), "o32_utimes"		},
+[4268] = { 6,	TM,		SEN(printargs), "o32_mbind"			},
+[4269] = { 5,	TM,		SEN(printargs), "o32_get_mempolicy"		},
+[4270] = { 3,	TM,		SEN(printargs), "o32_set_mempolicy"		},
+[4271] = { 4,	0,		SEN(printargs), "o32_mq_open"		},
+[4272] = { 1,	0,		SEN(printargs), "o32_mq_unlink"		},
+[4273] = { 5,	0,		SEN(printargs), "o32_mq_timedsend"		},
+[4274] = { 5,	0,		SEN(printargs), "o32_mq_timedreceive"	},
+[4275] = { 2,	0,		SEN(printargs), "o32_mq_notify"		},
+[4276] = { 3,	0,		SEN(printargs), "o32_mq_getsetattr"		},
+[4277] = { 5,	0,		SEN(printargs), "o32_vserver"		},
+[4278] = { 5,	TP,		SEN(printargs), "o32_waitid"		},
+[4279] = { },
+[4280] = { 5,	0,		SEN(printargs), "o32_add_key"		},
+[4281] = { 4,	0,		SEN(printargs), "o32_request_key"		},
+[4282] = { 5,	0,		SEN(printargs), "o32_keyctl"		},
+[4283] = { 1,	0,		SEN(printargs), "o32_set_thread_area"	},
+[4284] = { 0,	TD,		SEN(printargs), "o32_inotify_init"		},
+[4285] = { 3,	TD,		SEN(printargs), "o32_inotify_add_watch"	},
+[4286] = { 2,	TD,		SEN(printargs), "o32_inotify_rm_watch"	},
+[4287] = { 4,	TM,		SEN(printargs), "o32_migrate_pages"		},
+[4288] = { 4,	TD|TF,		SEN(printargs), "o32_openat"		},
+[4289] = { 3,	TD|TF,		SEN(printargs), "o32_mkdirat"		},
+[4290] = { 4,	TD|TF,		SEN(printargs), "o32_mknodat"		},
+[4291] = { 5,	TD|TF,		SEN(printargs), "o32_fchownat"		},
+[4292] = { 3,	TD|TF,		SEN(printargs), "o32_futimesat"		},
+[4293] = { 4,	TD|TF,		SEN(printargs), "o32_fstatat64"		},
+[4294] = { 3,	TD|TF,		SEN(printargs), "o32_unlinkat"		},
+[4295] = { 4,	TD|TF,		SEN(printargs), "o32_renameat"		},
+[4296] = { 5,	TD|TF,		SEN(printargs), "o32_linkat"		},
+[4297] = { 3,	TD|TF,		SEN(printargs), "o32_symlinkat"		},
+[4298] = { 4,	TD|TF,		SEN(printargs), "o32_readlinkat"		},
+[4299] = { 3,	TD|TF,		SEN(printargs), "o32_fchmodat"		},
+[4300] = { 3,	TD|TF,		SEN(printargs), "o32_faccessat"		},
+[4301] = { 6,	TD,		SEN(printargs), "o32_pselect6"		},
+[4302] = { 5,	TD,		SEN(printargs), "o32_ppoll"			},
+[4303] = { 1,	TP,		SEN(printargs), "o32_unshare"		},
+[4304] = { 6,	TD,		SEN(printargs), "o32_splice"		},
+[4305] = { 7,	TD,		SEN(printargs), "o32_sync_file_range"	},
+[4306] = { 4,	TD,		SEN(printargs), "o32_tee"			},
+[4307] = { 4,	TD,		SEN(printargs), "o32_vmsplice"		},
+[4308] = { 6,	TM,		SEN(printargs), "o32_move_pages"		},
+[4309] = { 2,	0,		SEN(printargs), "o32_set_robust_list"	},
+[4310] = { 3,	0,		SEN(printargs), "o32_get_robust_list"	},
+[4311] = { 4,	0,		SEN(printargs), "o32_kexec_load"		},
+[4312] = { 3,	0,		SEN(printargs), "o32_getcpu"		},
+[4313] = { 6,	TD,		SEN(printargs), "o32_epoll_pwait"		},
+[4314] = { 3,	0,		SEN(printargs), "o32_ioprio_set"		},
+[4315] = { 2,	0,		SEN(printargs), "o32_ioprio_get"		},
+[4316] = { 4,	TD|TF,		SEN(printargs), "o32_utimensat"		},
+[4317] = { 3,	TD|TS,		SEN(printargs), "o32_signalfd"		},
+[4318] = { 4,	TD,		SEN(printargs), "o32_timerfd"		},
+[4319] = { 1,	TD,		SEN(printargs), "o32_eventfd"		},
+[4320] = { 6,	TD,		SEN(printargs), "o32_fallocate"		},
+[4321] = { 2,	TD,		SEN(printargs), "o32_timerfd_create"	},
+[4322] = { 2,	TD,		SEN(printargs), "o32_timerfd_gettime"	},
+[4323] = { 4,	TD,		SEN(printargs), "o32_timerfd_settime"	},
+[4324] = { 4,	TD|TS,		SEN(printargs), "o32_signalfd4"		},
+[4325] = { 2,	TD,		SEN(printargs), "o32_eventfd2"		},
+[4326] = { 1,	TD,		SEN(printargs), "o32_epoll_create1"		},
+[4327] = { 3,	TD,		SEN(printargs), "o32_dup3"			},
+[4328] = { 2,	TD,		SEN(printargs), "o32_pipe2"			},
+[4329] = { 1,	TD,		SEN(printargs), "o32_inotify_init1"		},
+[4330] = { 5,	TD,		SEN(printargs), "o32_preadv"		},
+[4331] = { 5,	TD,		SEN(printargs), "o32_pwritev"		},
+[4332] = { 4,	TP|TS,		SEN(printargs), "o32_rt_tgsigqueueinfo"	},
+[4333] = { 5,	TD,		SEN(printargs), "o32_perf_event_open"	},
+[4334] = { 4,	TN,		SEN(printargs), "o32_accept4"		},
+[4335] = { 5,	TN,		SEN(printargs), "o32_recvmmsg"		},
+[4336] = { 2,	TD,		SEN(printargs), "o32_fanotify_init"		},
+[4337] = { 6,	TD|TF,		SEN(printargs), "o32_fanotify_mark"		},
+[4338] = { 4,	0,		SEN(printargs), "o32_prlimit64"		},
+[4339] = { 5,	TD|TF,		SEN(printargs), "o32_name_to_handle_at"	},
+[4340] = { 3,	TD,		SEN(printargs), "o32_open_by_handle_at"	},
+[4341] = { 2,	0,		SEN(printargs), "o32_clock_adjtime"		},
+[4342] = { 1,	TD,		SEN(printargs), "o32_syncfs"		},
+[4343] = { 4,	TN,		SEN(printargs), "o32_sendmmsg"		},
+[4344] = { 2,	TD,		SEN(printargs), "o32_setns"			},
+[4345] = { 6,	0,		SEN(printargs), "o32_process_vm_readv"	},
+[4346] = { 6,	0,		SEN(printargs), "o32_process_vm_writev"	},
+[4347] = { 5,	0,		SEN(printargs), "o32_kcmp"			},
+[4348] = { 3,	TD,		SEN(printargs), "o32_finit_module"		},
+[4349] = { 3,	0,		SEN(printargs), "o32_sched_setattr"		},
+[4350] = { 4,	0,		SEN(printargs), "o32_sched_getattr"		},
+[4351] = { 5,	TD|TF,		SEN(printargs), "o32_renameat2"		},
+[4352] = { 3,	0,		SEN(printargs), "o32_seccomp",		},
+[4353] = { 3,	0,		SEN(printargs), "o32_getrandom",		},
+[4354] = { 2,	TD,		SEN(printargs), "o32_memfd_create",		},
+[4355] = { 3,	TD,		SEN(printargs), "o32_bpf",			},
+[4356] = { 5,	TD|TF|TP|SE|SI,	SEN(printargs), "o32_execveat",		},
+[4357 ... 4399] = { },
diff --git a/strace/linux/mips/syscallent-o32.h b/strace/linux/mips/syscallent-o32.h
new file mode 100644
index 0000000..cb8afb9
--- /dev/null
+++ b/strace/linux/mips/syscallent-o32.h
@@ -0,0 +1,374 @@
+#if defined LINUX_MIPSO32
+/* For an O32 strace, decode the o32 syscalls.  */
+[4000] = { MA,	0,		SEN(syscall),			"syscall"		}, /* start of Linux o32 */
+[4001] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[4002] = { 0,	TP,		SEN(fork),			"fork"			},
+[4003] = { 3,	TD,		SEN(read),			"read"			},
+[4004] = { 3,	TD,		SEN(write),			"write"			},
+[4005] = { 3,	TD|TF,		SEN(open),			"open"			},
+[4006] = { 1,	TD,		SEN(close),			"close"			},
+[4007] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[4008] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[4009] = { 2,	TF,		SEN(link),			"link"			},
+[4010] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[4011] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[4012] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[4013] = { 1,	0,		SEN(time),			"time"			},
+[4014] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[4015] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[4016] = { 3,	TF,		SEN(chown),			"lchown"		},
+[4017] = { 0,	TM,		SEN(break),			"break"			},
+[4018] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[4019] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[4020] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[4021] = { 5,	TF,		SEN(mount),			"mount"			},
+[4022] = { 1,	TF,		SEN(umount),			"umount"		},
+[4023] = { 1,	0,		SEN(setuid),			"setuid"		},
+[4024] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[4025] = { 1,	0,		SEN(stime),			"stime"			},
+[4026] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[4027] = { 1,	0,		SEN(alarm),			"alarm"			},
+[4028] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[4029] = { 0,	TS,		SEN(pause),			"pause"			},
+[4030] = { 2,	TF,		SEN(utime),			"utime"			},
+[4031] = { 0,	0,		SEN(stty),			"stty"			},
+[4032] = { 0,	0,		SEN(gtty),			"gtty"			},
+[4033] = { 2,	TF,		SEN(access),			"access"		},
+[4034] = { 1,	0,		SEN(nice),			"nice"			},
+[4035] = { 1,	0,		SEN(ftime),			"ftime"			},
+[4036] = { 0,	0,		SEN(sync),			"sync"			},
+[4037] = { 2,	TS,		SEN(kill),			"kill"			},
+[4038] = { 2,	TF,		SEN(rename),			"rename"		},
+[4039] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[4040] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[4041] = { 1,	TD,		SEN(dup),			"dup"			},
+[4042] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[4043] = { 1,	0,		SEN(times),			"times"			},
+[4044] = { 0,	0,		SEN(prof),			"prof"			},
+[4045] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[4046] = { 1,	0,		SEN(setgid),			"setgid"		},
+[4047] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[4048] = { 2,	TS,		SEN(signal),			"signal"		},
+[4049] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[4050] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[4051] = { 1,	TF,		SEN(acct),			"acct"			},
+[4052] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[4053] = { 0,	0,		SEN(lock),			"lock"			},
+[4054] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[4055] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[4056] = { 0,	0,		SEN(mpx),			"mpx"			},
+[4057] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[4058] = { 0,	0,		SEN(ulimit),			"ulimit"		},
+[4059] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[4060] = { 1,	NF,		SEN(umask),			"umask"			},
+[4061] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[4062] = { 2,	0,		SEN(ustat),			"ustat"			},
+[4063] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[4064] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[4065] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[4066] = { 0,	0,		SEN(setsid),			"setsid"		},
+[4067] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[4068] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[4069] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[4070] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[4071] = { 2,	0,		SEN(setregid),			"setregid"		},
+[4072] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[4073] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[4074] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[4075] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[4076] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[4077] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[4078] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[4079] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[4080] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[4081] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[4082] = { 0,	0,		SEN(printargs),			"reserved82"		},
+[4083] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[4084] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[4085] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[4086] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[4087] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[4088] = { 4,	0,		SEN(reboot),			"reboot"		},
+[4089] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[4090] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[4091] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[4092] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[4093] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[4094] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[4095] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[4096] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[4097] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[4098] = { 0,	0,		SEN(profil),			"profil"		},
+[4099] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[4100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[4101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[4102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[4103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[4104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[4105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[4106] = { 2,	TF,		SEN(stat),			"stat"			},
+[4107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[4108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[4109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[4110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[4111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[4112] = { 0,	0,		SEN(idle),			"idle"			},
+[4113] = { 5,	0,		SEN(vm86old),			"vm86"			},
+[4114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[4115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[4116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[4117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[4118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[4119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[4120] = { 5,	TP,		SEN(clone),			"clone"			},
+[4121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[4122] = { 1,	0,		SEN(uname),			"uname"			},
+[4123] = { 0,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[4124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[4125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[4126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[4127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[4128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[4129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[4130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[4131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[4132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[4133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[4134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[4135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[4136] = { 1,	NF,		SEN(personality),		"personality"		},
+[4137] = { 0,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[4138] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[4139] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[4140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[4141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[4142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[4143] = { 2,	TD,		SEN(flock),			"flock"			},
+[4144] = { 3,	TM,		SEN(msync),			"msync"			},
+[4145] = { 3,	TD,		SEN(readv),			"readv"			},
+[4146] = { 3,	TD,		SEN(writev),			"writev"		},
+[4147] = { 3,	0,		SEN(printargs),			"cacheflush"		},
+[4148] = { 3,	0,		SEN(printargs),			"cachectl"		},
+[4149] = { 4,	0,		SEN(sysmips),			"sysmips"		},
+[4150] = { 0,	0,		SEN(setup),			"setup"			},
+[4151] = { 1,	0,		SEN(getsid),			"getsid"		},
+[4152] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[4153] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[4154] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[4155] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[4156] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[4157] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[4158] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[4159] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[4160] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[4161] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[4162] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[4163] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[4164] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[4165] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[4166] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[4167] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[4168] = { 3,	TN,		SEN(accept),			"accept"		},
+[4169] = { 3,	TN,		SEN(bind),			"bind"			},
+[4170] = { 3,	TN,		SEN(connect),			"connect"		},
+[4171] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[4172] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[4173] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[4174] = { 2,	TN,		SEN(listen),			"listen"		},
+[4175] = { 4,	TN,		SEN(recv),			"recv"			},
+[4176] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[4177] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[4178] = { 4,	TN,		SEN(send),			"send"			},
+[4179] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[4180] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[4181] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[4182] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[4183] = { 3,	TN,		SEN(socket),			"socket"		},
+[4184] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[4185] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[4186] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[4187] = { 5,	0,		SEN(query_module),		"query_module"		},
+[4188] = { 3,	TD,		SEN(poll),			"poll"			},
+[4189] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[4190] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[4191] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[4192] = { 5,	0,		SEN(prctl),			"prctl"			},
+[4193] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[4194] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[4195] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[4196] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[4197] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[4198] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[4199] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[4200] = { 6,	TD,		SEN(pread),			"pread64"		},
+[4201] = { 6,	TD,		SEN(pwrite),			"pwrite64"		},
+[4202] = { 3,	TF,		SEN(chown),			"chown"			},
+[4203] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[4204] = { 2,	0,		SEN(capget),			"capget"		},
+[4205] = { 2,	0,		SEN(capset),			"capset"		},
+[4206] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[4207] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[4208] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[4209] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[4210] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[4211] = { 4,	TF,		SEN(truncate64),		"truncate64"		},
+[4212] = { 4,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[4213] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[4214] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[4215] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[4216] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[4217] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[4218] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[4219] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[4220] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[4221] = { },
+[4222] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[4223] = { 5,	TD,		SEN(readahead),			"readahead"		},
+[4224] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[4225] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[4226] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[4227] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[4228] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[4229] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[4230] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[4231] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[4232] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[4233] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[4234] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[4235] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[4236] = { 2,	TS,		SEN(kill),			"tkill"			},
+[4237] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[4238] = { 6,	0,		SEN(futex),			"futex"			},
+[4239] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[4240] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[4241] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[4242] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[4243] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[4244] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[4245] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[4246] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[4247] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[4248] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[4249] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[4250] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[4251] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[4252] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[4253] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[4254] = { 7,	TD,		SEN(fadvise64_64),		"fadvise64"		},
+[4255] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[4256] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[4257] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[4258] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[4259] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[4260] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[4261] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[4262] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[4263] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[4264] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[4265] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[4266] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[4267] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[4268] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[4269] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[4270] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[4271] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[4272] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[4273] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[4274] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[4275] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[4276] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[4277] = { 5,	0,		SEN(vserver),			"vserver"		},
+[4278] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[4279] = { },
+[4280] = { 5,	0,		SEN(add_key),			"add_key"		},
+[4281] = { 4,	0,		SEN(request_key),		"request_key"		},
+[4282] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[4283] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[4284] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[4285] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[4286] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[4287] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[4288] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[4289] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[4290] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[4291] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[4292] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[4293] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[4294] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[4295] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[4296] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[4297] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[4298] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[4299] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[4300] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[4301] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[4302] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[4303] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[4304] = { 6,	TD,		SEN(splice),			"splice"		},
+[4305] = { 7,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[4306] = { 4,	TD,		SEN(tee),			"tee"			},
+[4307] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[4308] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[4309] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[4310] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[4311] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[4312] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[4313] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[4314] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[4315] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[4316] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[4317] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[4318] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[4319] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[4320] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[4321] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[4322] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[4323] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[4324] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[4325] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[4326] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[4327] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[4328] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[4329] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[4330] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[4331] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[4332] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[4333] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[4334] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[4335] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[4336] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[4337] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[4338] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[4339] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[4340] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[4341] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[4342] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[4343] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[4344] = { 2,	TD,		SEN(setns),			"setns"			},
+[4345] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[4346] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[4347] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[4348] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[4349] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[4350] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[4351] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[4352] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[4353] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[4354] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[4355] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[4356] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[4357] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[4358] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[4359] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[4360] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[4361] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[4362] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+# define SYS_socket_subcall      4400
+# include "subcall.h"
+
+#else
+
+# include "syscallent-o32-stub.h"
+
+#endif
diff --git a/strace/linux/mips/syscallent.h b/strace/linux/mips/syscallent.h
new file mode 100644
index 0000000..61430d2
--- /dev/null
+++ b/strace/linux/mips/syscallent.h
@@ -0,0 +1,5 @@
+#include "../dummy.h"
+#include "syscallent-compat.h"
+#include "syscallent-o32.h"
+#include "syscallent-n64.h"
+#include "syscallent-n32.h"
diff --git a/strace/linux/mips/userent.h b/strace/linux/mips/userent.h
new file mode 100644
index 0000000..1399142
--- /dev/null
+++ b/strace/linux/mips/userent.h
@@ -0,0 +1,83 @@
+{ 0,			"r0" },
+{ 1,			"r1" },
+{ 2,			"r2" },
+{ 3,			"r3" },
+{ 4,			"r4" },
+{ 5,			"r5" },
+{ 6,			"r6" },
+{ 7,			"r7" },
+{ 8,			"r8" },
+{ 9,			"r9" },
+{ 10,			"r10" },
+{ 11,			"r11" },
+{ 12,			"r12" },
+{ 13,			"r13" },
+{ 14,			"r14" },
+{ 15,			"r15" },
+{ 16,			"r16" },
+{ 17,			"r17" },
+{ 18,			"r18" },
+{ 19,			"r19" },
+{ 20,			"r20" },
+{ 21,			"r21" },
+{ 22,			"r22" },
+{ 23,			"r23" },
+{ 24,			"r24" },
+{ 25,			"r25" },
+{ 26,			"r26" },
+{ 27,			"r27" },
+{ 28,			"r28" },
+{ 29,			"r29" },
+{ 30,			"r30" },
+{ 31,			"r31" },
+{ 32,			"f0" },
+{ 33,			"f1" },
+{ 34,			"f2" },
+{ 35,			"f3" },
+{ 36,			"f4" },
+{ 37,			"f5" },
+{ 38,			"f6" },
+{ 39,			"f7" },
+{ 40,			"f8" },
+{ 41,			"f9" },
+{ 42,			"f10" },
+{ 43,			"f11" },
+{ 44,			"f12" },
+{ 45,			"f13" },
+{ 46,			"f14" },
+{ 47,			"f15" },
+{ 48,			"f16" },
+{ 49,			"f17" },
+{ 50,			"f18" },
+{ 51,			"f19" },
+{ 52,			"f20" },
+{ 53,			"f21" },
+{ 54,			"f22" },
+{ 55,			"f23" },
+{ 56,			"f24" },
+{ 57,			"f25" },
+{ 58,			"f26" },
+{ 59,			"f27" },
+{ 60,			"f28" },
+{ 61,			"f29" },
+{ 62,			"f30" },
+{ 63,			"f31" },
+{ 64,			"pc" },
+{ 65,			"cause" },
+{ 66,			"badvaddr" },
+{ 67,			"mmhi" },
+{ 68,			"mmlo" },
+{ 69,			"fpcsr" },
+{ 70,			"fpeir" },
+/* Other fields in "struct user" */
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(start_data),
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/mtd-abi.h b/strace/linux/mtd-abi.h
new file mode 100644
index 0000000..b197861
--- /dev/null
+++ b/strace/linux/mtd-abi.h
@@ -0,0 +1,278 @@
+/*
+ * Copyright © 1999-2010 David Woodhouse <dwmw2@infradead.org> et al.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+ *
+ */
+
+#ifndef __MTD_ABI_H__
+#define __MTD_ABI_H__
+
+#include <linux/types.h>
+
+struct erase_info_user {
+	__u32 start;
+	__u32 length;
+};
+
+struct erase_info_user64 {
+	__u64 start;
+	__u64 length;
+};
+
+struct mtd_oob_buf {
+	__u32 start;
+	__u32 length;
+	unsigned char *ptr;
+};
+
+struct mtd_oob_buf64 {
+	__u64 start;
+	__u32 pad;
+	__u32 length;
+	__u64 usr_ptr;
+};
+
+/**
+ * MTD operation modes
+ *
+ * @MTD_OPS_PLACE_OOB:	OOB data are placed at the given offset (default)
+ * @MTD_OPS_AUTO_OOB:	OOB data are automatically placed at the free areas
+ *			which are defined by the internal ecclayout
+ * @MTD_OPS_RAW:	data are transferred as-is, with no error correction;
+ *			this mode implies %MTD_OPS_PLACE_OOB
+ *
+ * These modes can be passed to ioctl(MEMWRITE) and are also used internally.
+ * See notes on "MTD file modes" for discussion on %MTD_OPS_RAW vs.
+ * %MTD_FILE_MODE_RAW.
+ */
+enum {
+	MTD_OPS_PLACE_OOB = 0,
+	MTD_OPS_AUTO_OOB = 1,
+	MTD_OPS_RAW = 2,
+};
+
+/**
+ * struct mtd_write_req - data structure for requesting a write operation
+ *
+ * @start:	start address
+ * @len:	length of data buffer
+ * @ooblen:	length of OOB buffer
+ * @usr_data:	user-provided data buffer
+ * @usr_oob:	user-provided OOB buffer
+ * @mode:	MTD mode (see "MTD operation modes")
+ * @padding:	reserved, must be set to 0
+ *
+ * This structure supports ioctl(MEMWRITE) operations, allowing data and/or OOB
+ * writes in various modes. To write to OOB-only, set @usr_data == NULL, and to
+ * write data-only, set @usr_oob == NULL. However, setting both @usr_data and
+ * @usr_oob to NULL is not allowed.
+ */
+struct mtd_write_req {
+	__u64 start;
+	__u64 len;
+	__u64 ooblen;
+	__u64 usr_data;
+	__u64 usr_oob;
+	__u8 mode;
+	__u8 padding[7];
+};
+
+#define MTD_ABSENT		0
+#define MTD_RAM			1
+#define MTD_ROM			2
+#define MTD_NORFLASH		3
+#define MTD_NANDFLASH		4
+#define MTD_DATAFLASH		6
+#define MTD_UBIVOLUME		7
+#define MTD_MLCNANDFLASH	8
+
+#define MTD_WRITEABLE		0x400	/* Device is writeable */
+#define MTD_BIT_WRITEABLE	0x800	/* Single bits can be flipped */
+#define MTD_NO_ERASE		0x1000	/* No erase necessary */
+#define MTD_POWERUP_LOCK	0x2000	/* Always locked after reset */
+
+/* Some common devices / combinations of capabilities */
+#define MTD_CAP_ROM		0
+#define MTD_CAP_RAM		(MTD_WRITEABLE | MTD_BIT_WRITEABLE | MTD_NO_ERASE)
+#define MTD_CAP_NORFLASH	(MTD_WRITEABLE | MTD_BIT_WRITEABLE)
+#define MTD_CAP_NANDFLASH	(MTD_WRITEABLE)
+
+/* Obsolete ECC byte placement modes (used with obsolete MEMGETOOBSEL) */
+#define MTD_NANDECC_OFF		0	// Switch off ECC (Not recommended)
+#define MTD_NANDECC_PLACE	1	// Use the given placement in the structure (YAFFS1 legacy mode)
+#define MTD_NANDECC_AUTOPLACE	2	// Use the default placement scheme
+#define MTD_NANDECC_PLACEONLY	3	// Use the given placement in the structure (Do not store ecc result on read)
+#define MTD_NANDECC_AUTOPL_USR	4	// Use the given autoplacement scheme rather than using the default
+
+/* OTP mode selection */
+#define MTD_OTP_OFF		0
+#define MTD_OTP_FACTORY		1
+#define MTD_OTP_USER		2
+
+struct mtd_info_user {
+	__u8 type;
+	__u32 flags;
+	__u32 size;	/* Total size of the MTD */
+	__u32 erasesize;
+	__u32 writesize;
+	__u32 oobsize;	/* Amount of OOB data per block (e.g. 16) */
+	__u64 padding;	/* Old obsolete field; do not use */
+};
+
+struct region_info_user {
+	__u32 offset;		/* At which this region starts,
+				 * from the beginning of the MTD */
+	__u32 erasesize;	/* For this region */
+	__u32 numblocks;	/* Number of blocks in this region */
+	__u32 regionindex;
+};
+
+struct otp_info {
+	__u32 start;
+	__u32 length;
+	__u32 locked;
+};
+
+/*
+ * Note, the following ioctl existed in the past and was removed:
+ * #define MEMSETOOBSEL           _IOW('M', 9, struct nand_oobinfo)
+ * Try to avoid adding a new ioctl with the same ioctl number.
+ */
+
+/* Get basic MTD characteristics info (better to use sysfs) */
+#define MEMGETINFO		_IOR('M', 1, struct mtd_info_user)
+/* Erase segment of MTD */
+#define MEMERASE		_IOW('M', 2, struct erase_info_user)
+/* Write out-of-band data from MTD */
+#define MEMWRITEOOB		_IOWR('M', 3, struct mtd_oob_buf)
+/* Read out-of-band data from MTD */
+#define MEMREADOOB		_IOWR('M', 4, struct mtd_oob_buf)
+/* Lock a chip (for MTD that supports it) */
+#define MEMLOCK			_IOW('M', 5, struct erase_info_user)
+/* Unlock a chip (for MTD that supports it) */
+#define MEMUNLOCK		_IOW('M', 6, struct erase_info_user)
+/* Get the number of different erase regions */
+#define MEMGETREGIONCOUNT	_IOR('M', 7, int)
+/* Get information about the erase region for a specific index */
+#define MEMGETREGIONINFO	_IOWR('M', 8, struct region_info_user)
+/* Get info about OOB modes (e.g., RAW, PLACE, AUTO) - legacy interface */
+#define MEMGETOOBSEL		_IOR('M', 10, struct nand_oobinfo)
+/* Check if an eraseblock is bad */
+#define MEMGETBADBLOCK		_IOW('M', 11, __kernel_loff_t)
+/* Mark an eraseblock as bad */
+#define MEMSETBADBLOCK		_IOW('M', 12, __kernel_loff_t)
+/* Set OTP (One-Time Programmable) mode (factory vs. user) */
+#define OTPSELECT		_IOR('M', 13, int)
+/* Get number of OTP (One-Time Programmable) regions */
+#define OTPGETREGIONCOUNT	_IOW('M', 14, int)
+/* Get all OTP (One-Time Programmable) info about MTD */
+#define OTPGETREGIONINFO	_IOW('M', 15, struct otp_info)
+/* Lock a given range of user data (must be in mode %MTD_FILE_MODE_OTP_USER) */
+#define OTPLOCK			_IOR('M', 16, struct otp_info)
+/* Get ECC layout (deprecated) */
+#define ECCGETLAYOUT		_IOR('M', 17, struct nand_ecclayout_user)
+/* Get statistics about corrected/uncorrected errors */
+#define ECCGETSTATS		_IOR('M', 18, struct mtd_ecc_stats)
+/* Set MTD mode on a per-file-descriptor basis (see "MTD file modes") */
+#define MTDFILEMODE		_IO('M', 19)
+/* Erase segment of MTD (supports 64-bit address) */
+#define MEMERASE64		_IOW('M', 20, struct erase_info_user64)
+/* Write data to OOB (64-bit version) */
+#define MEMWRITEOOB64		_IOWR('M', 21, struct mtd_oob_buf64)
+/* Read data from OOB (64-bit version) */
+#define MEMREADOOB64		_IOWR('M', 22, struct mtd_oob_buf64)
+/* Check if chip is locked (for MTD that supports it) */
+#define MEMISLOCKED		_IOR('M', 23, struct erase_info_user)
+/*
+ * Most generic write interface; can write in-band and/or out-of-band in various
+ * modes (see "struct mtd_write_req"). This ioctl is not supported for flashes
+ * without OOB, e.g., NOR flash.
+ */
+#define MEMWRITE		_IOWR('M', 24, struct mtd_write_req)
+
+/*
+ * Obsolete legacy interface. Keep it in order not to break userspace
+ * interfaces
+ */
+struct nand_oobinfo {
+	__u32 useecc;
+	__u32 eccbytes;
+	__u32 oobfree[8][2];
+	__u32 eccpos[32];
+};
+
+struct nand_oobfree {
+	__u32 offset;
+	__u32 length;
+};
+
+#define MTD_MAX_OOBFREE_ENTRIES	8
+#define MTD_MAX_ECCPOS_ENTRIES	64
+/*
+ * OBSOLETE: ECC layout control structure. Exported to user-space via ioctl
+ * ECCGETLAYOUT for backwards compatbility and should not be mistaken as a
+ * complete set of ECC information. The ioctl truncates the larger internal
+ * structure to retain binary compatibility with the static declaration of the
+ * ioctl. Note that the "MTD_MAX_..._ENTRIES" macros represent the max size of
+ * the user struct, not the MAX size of the internal struct nand_ecclayout.
+ */
+struct nand_ecclayout_user {
+	__u32 eccbytes;
+	__u32 eccpos[MTD_MAX_ECCPOS_ENTRIES];
+	__u32 oobavail;
+	struct nand_oobfree oobfree[MTD_MAX_OOBFREE_ENTRIES];
+};
+
+/**
+ * struct mtd_ecc_stats - error correction stats
+ *
+ * @corrected:	number of corrected bits
+ * @failed:	number of uncorrectable errors
+ * @badblocks:	number of bad blocks in this partition
+ * @bbtblocks:	number of blocks reserved for bad block tables
+ */
+struct mtd_ecc_stats {
+	__u32 corrected;
+	__u32 failed;
+	__u32 badblocks;
+	__u32 bbtblocks;
+};
+
+/*
+ * MTD file modes - for read/write access to MTD
+ *
+ * @MTD_FILE_MODE_NORMAL:	OTP disabled, ECC enabled
+ * @MTD_FILE_MODE_OTP_FACTORY:	OTP enabled in factory mode
+ * @MTD_FILE_MODE_OTP_USER:	OTP enabled in user mode
+ * @MTD_FILE_MODE_RAW:		OTP disabled, ECC disabled
+ *
+ * These modes can be set via ioctl(MTDFILEMODE). The mode mode will be retained
+ * separately for each open file descriptor.
+ *
+ * Note: %MTD_FILE_MODE_RAW provides the same functionality as %MTD_OPS_RAW -
+ * raw access to the flash, without error correction or autoplacement schemes.
+ * Wherever possible, the MTD_OPS_* mode will override the MTD_FILE_MODE_* mode
+ * (e.g., when using ioctl(MEMWRITE)), but in some cases, the MTD_FILE_MODE is
+ * used out of necessity (e.g., `write()', ioctl(MEMWRITEOOB64)).
+ */
+enum mtd_file_modes {
+	MTD_FILE_MODE_NORMAL = MTD_OTP_OFF,
+	MTD_FILE_MODE_OTP_FACTORY = MTD_OTP_FACTORY,
+	MTD_FILE_MODE_OTP_USER = MTD_OTP_USER,
+	MTD_FILE_MODE_RAW,
+};
+
+#endif /* __MTD_ABI_H__ */
diff --git a/strace/linux/netlink_diag.h b/strace/linux/netlink_diag.h
new file mode 100644
index 0000000..276baa7
--- /dev/null
+++ b/strace/linux/netlink_diag.h
@@ -0,0 +1,24 @@
+struct netlink_diag_req {
+	uint8_t sdiag_family;
+	uint8_t sdiag_protocol;
+	uint16_t pad;
+	uint32_t ndiag_ino;
+	uint32_t ndiag_show;
+	uint32_t ndiag_cookie[2];
+};
+
+struct netlink_diag_msg {
+	uint8_t ndiag_family;
+	uint8_t ndiag_type;
+	uint8_t ndiag_protocol;
+	uint8_t ndiag_state;
+
+	uint32_t ndiag_portid;
+	uint32_t ndiag_dst_portid;
+	uint32_t ndiag_dst_group;
+	uint32_t ndiag_ino;
+	uint32_t ndiag_cookie[2];
+};
+
+#define NDIAG_SHOW_MEMINFO           0x00000001
+#define NDIAG_PROTO_ALL              ((uint8_t) ~0)
diff --git a/strace/linux/nios2/arch_regs.c b/strace/linux/nios2/arch_regs.c
new file mode 100644
index 0000000..2c30321
--- /dev/null
+++ b/strace/linux/nios2/arch_regs.c
@@ -0,0 +1,3 @@
+static struct user_pt_regs nios2_regs;
+# define ARCH_REGS_FOR_GETREGSET nios2_regs
+#define ARCH_PC_REG nios2_regs.regs[PTR_EA]
diff --git a/strace/linux/nios2/get_error.c b/strace/linux/nios2/get_error.c
new file mode 100644
index 0000000..1c91c0a
--- /dev/null
+++ b/strace/linux/nios2/get_error.c
@@ -0,0 +1,17 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	/*
+	 * The system call convention specifies that r2 contains the return
+	 * value on success or a positive error number on failure.  A flag
+	 * indicating successful completion is written to r7; r7=0 indicates
+	 * the system call success, r7=1 indicates an error.  The positive
+	 * errno value written in r2.
+	 */
+	if (nios2_regs.regs[7]) {
+		tcp->u_rval = -1;
+		tcp->u_error = nios2_regs.regs[2];
+	} else {
+		tcp->u_rval = nios2_regs.regs[2];
+	}
+}
diff --git a/strace/linux/nios2/get_scno.c b/strace/linux/nios2/get_scno.c
new file mode 100644
index 0000000..f4db85e
--- /dev/null
+++ b/strace/linux/nios2/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = nios2_regs.regs[2];
+	return 1;
+}
diff --git a/strace/linux/nios2/get_syscall_args.c b/strace/linux/nios2/get_syscall_args.c
new file mode 100644
index 0000000..707f594
--- /dev/null
+++ b/strace/linux/nios2/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = nios2_regs.regs[4];
+	tcp->u_arg[1] = nios2_regs.regs[5];
+	tcp->u_arg[2] = nios2_regs.regs[6];
+	tcp->u_arg[3] = nios2_regs.regs[7];
+	tcp->u_arg[4] = nios2_regs.regs[8];
+	tcp->u_arg[5] = nios2_regs.regs[9];
+	return 1;
+}
diff --git a/strace/linux/nios2/ioctls_arch0.h b/strace/linux/nios2/ioctls_arch0.h
new file mode 100644
index 0000000..f015def
--- /dev/null
+++ b/strace/linux/nios2/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/nios2/include/ tree. */
diff --git a/strace/linux/nios2/ioctls_inc0.h b/strace/linux/nios2/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/nios2/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/nios2/syscallent.h b/strace/linux/nios2/syscallent.h
new file mode 100644
index 0000000..301fd0e
--- /dev/null
+++ b/strace/linux/nios2/syscallent.h
@@ -0,0 +1,4 @@
+#define sys_ARCH_mmap sys_mmap_pgoff
+#include "32/syscallent.h"
+/* [244 ... 259] are arch specific */
+[244] = {4,    0,	SEN(cacheflush), "cacheflush"},
diff --git a/strace/linux/or1k/arch_regs.c b/strace/linux/or1k/arch_regs.c
new file mode 100644
index 0000000..78693e5
--- /dev/null
+++ b/strace/linux/or1k/arch_regs.c
@@ -0,0 +1,3 @@
+static struct user_regs_struct or1k_regs;
+#define ARCH_REGS_FOR_GETREGSET or1k_regs
+#define ARCH_PC_REG or1k_regs.pc
diff --git a/strace/linux/or1k/get_error.c b/strace/linux/or1k/get_error.c
new file mode 100644
index 0000000..40e00bf
--- /dev/null
+++ b/strace/linux/or1k/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(or1k_regs.gpr[11])) {
+		tcp->u_rval = -1;
+		tcp->u_error = -or1k_regs.gpr[11];
+	} else {
+		tcp->u_rval = or1k_regs.gpr[11];
+	}
+}
diff --git a/strace/linux/or1k/get_scno.c b/strace/linux/or1k/get_scno.c
new file mode 100644
index 0000000..f446c90
--- /dev/null
+++ b/strace/linux/or1k/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = or1k_regs.gpr[11];
+	return 1;
+}
diff --git a/strace/linux/or1k/get_syscall_args.c b/strace/linux/or1k/get_syscall_args.c
new file mode 100644
index 0000000..b72e01f
--- /dev/null
+++ b/strace/linux/or1k/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = or1k_regs.gpr[3 + 0];
+	tcp->u_arg[1] = or1k_regs.gpr[3 + 1];
+	tcp->u_arg[2] = or1k_regs.gpr[3 + 2];
+	tcp->u_arg[3] = or1k_regs.gpr[3 + 3];
+	tcp->u_arg[4] = or1k_regs.gpr[3 + 4];
+	tcp->u_arg[5] = or1k_regs.gpr[3 + 5];
+	return 1;
+}
diff --git a/strace/linux/or1k/ioctls_arch0.h b/strace/linux/or1k/ioctls_arch0.h
new file mode 100644
index 0000000..5950cbe
--- /dev/null
+++ b/strace/linux/or1k/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/openrisc/include/ tree. */
diff --git a/strace/linux/or1k/ioctls_inc0.h b/strace/linux/or1k/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/or1k/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/or1k/syscallent.h b/strace/linux/or1k/syscallent.h
new file mode 100644
index 0000000..10af205
--- /dev/null
+++ b/strace/linux/or1k/syscallent.h
@@ -0,0 +1,4 @@
+#define sys_ARCH_mmap sys_mmap_pgoff
+#include "32/syscallent.h"
+/* [244 ... 259] are arch specific */
+[244] = { 3,	NF,	SEN(or1k_atomic),	"or1k_atomic"	},
diff --git a/strace/linux/or1k/userent.h b/strace/linux/or1k/userent.h
new file mode 100644
index 0000000..c6fd7d3
--- /dev/null
+++ b/strace/linux/or1k/userent.h
@@ -0,0 +1,34 @@
+{ 4*0,  "r0" },
+{ 4*1,  "r1" },
+{ 4*2,  "r2" },
+{ 4*3,  "r3" },
+{ 4*4,  "r4" },
+{ 4*5,  "r5" },
+{ 4*6,  "r6" },
+{ 4*7,  "r7" },
+{ 4*8,  "r8" },
+{ 4*9,  "r9" },
+{ 4*10, "r10" },
+{ 4*11, "r11" },
+{ 4*12, "r12" },
+{ 4*13, "r13" },
+{ 4*14, "r14" },
+{ 4*15, "r15" },
+{ 4*16, "r16" },
+{ 4*17, "r17" },
+{ 4*18, "r18" },
+{ 4*19, "r19" },
+{ 4*20, "r20" },
+{ 4*21, "r21" },
+{ 4*22, "r22" },
+{ 4*23, "r23" },
+{ 4*24, "r24" },
+{ 4*25, "r25" },
+{ 4*26, "r26" },
+{ 4*27, "r27" },
+{ 4*28, "r28" },
+{ 4*29, "r29" },
+{ 4*30, "r30" },
+{ 4*31, "r31" },
+{ 4*32, "pc" },
+{ 4*33, "sr" },
diff --git a/strace/linux/personality.h b/strace/linux/personality.h
new file mode 100644
index 0000000..9971703
--- /dev/null
+++ b/strace/linux/personality.h
@@ -0,0 +1,69 @@
+#ifndef _LINUX_PERSONALITY_H
+#define _LINUX_PERSONALITY_H
+
+
+/*
+ * Flags for bug emulation.
+ *
+ * These occupy the top three bytes.
+ */
+enum {
+	UNAME26	=               0x0020000,
+	ADDR_NO_RANDOMIZE = 	0x0040000,	/* disable randomization of VA space */
+	FDPIC_FUNCPTRS =	0x0080000,	/* userspace function ptrs point to descriptors
+						 * (signal handling)
+						 */
+	MMAP_PAGE_ZERO =	0x0100000,
+	ADDR_COMPAT_LAYOUT =	0x0200000,
+	READ_IMPLIES_EXEC =	0x0400000,
+	ADDR_LIMIT_32BIT =	0x0800000,
+	SHORT_INODE =		0x1000000,
+	WHOLE_SECONDS =		0x2000000,
+	STICKY_TIMEOUTS	=	0x4000000,
+	ADDR_LIMIT_3GB = 	0x8000000,
+};
+
+/*
+ * Security-relevant compatibility flags that must be
+ * cleared upon setuid or setgid exec:
+ */
+#define PER_CLEAR_ON_SETID (READ_IMPLIES_EXEC  | \
+			    ADDR_NO_RANDOMIZE  | \
+			    ADDR_COMPAT_LAYOUT | \
+			    MMAP_PAGE_ZERO)
+
+/*
+ * Personality types.
+ *
+ * These go in the low byte.  Avoid using the top bit, it will
+ * conflict with error returns.
+ */
+enum {
+	PER_LINUX =		0x0000,
+	PER_LINUX_32BIT =	0x0000 | ADDR_LIMIT_32BIT,
+	PER_LINUX_FDPIC =	0x0000 | FDPIC_FUNCPTRS,
+	PER_SVR4 =		0x0001 | STICKY_TIMEOUTS | MMAP_PAGE_ZERO,
+	PER_SVR3 =		0x0002 | STICKY_TIMEOUTS | SHORT_INODE,
+	PER_SCOSVR3 =		0x0003 | STICKY_TIMEOUTS |
+					 WHOLE_SECONDS | SHORT_INODE,
+	PER_OSR5 =		0x0003 | STICKY_TIMEOUTS | WHOLE_SECONDS,
+	PER_WYSEV386 =		0x0004 | STICKY_TIMEOUTS | SHORT_INODE,
+	PER_ISCR4 =		0x0005 | STICKY_TIMEOUTS,
+	PER_BSD =		0x0006,
+	PER_SUNOS =		0x0006 | STICKY_TIMEOUTS,
+	PER_XENIX =		0x0007 | STICKY_TIMEOUTS | SHORT_INODE,
+	PER_LINUX32 =		0x0008,
+	PER_LINUX32_3GB =	0x0008 | ADDR_LIMIT_3GB,
+	PER_IRIX32 =		0x0009 | STICKY_TIMEOUTS,/* IRIX5 32-bit */
+	PER_IRIXN32 =		0x000a | STICKY_TIMEOUTS,/* IRIX6 new 32-bit */
+	PER_IRIX64 =		0x000b | STICKY_TIMEOUTS,/* IRIX6 64-bit */
+	PER_RISCOS =		0x000c,
+	PER_SOLARIS =		0x000d | STICKY_TIMEOUTS,
+	PER_UW7 =		0x000e | STICKY_TIMEOUTS | MMAP_PAGE_ZERO,
+	PER_OSF4 =		0x000f,			 /* OSF/1 v4 */
+	PER_HPUX =		0x0010,
+	PER_MASK =		0x00ff,
+};
+
+
+#endif /* _LINUX_PERSONALITY_H */
diff --git a/strace/linux/powerpc/arch_regs.c b/strace/linux/powerpc/arch_regs.c
new file mode 100644
index 0000000..dd573f7
--- /dev/null
+++ b/strace/linux/powerpc/arch_regs.c
@@ -0,0 +1,4 @@
+struct pt_regs ppc_regs; /* not static */
+
+#define ARCH_REGS_FOR_GETREGS ppc_regs
+#define ARCH_PC_REG ppc_regs.nip
diff --git a/strace/linux/powerpc/arch_regs.h b/strace/linux/powerpc/arch_regs.h
new file mode 100644
index 0000000..1296e83
--- /dev/null
+++ b/strace/linux/powerpc/arch_regs.h
@@ -0,0 +1 @@
+extern struct pt_regs ppc_regs;
diff --git a/strace/linux/powerpc/arch_sigreturn.c b/strace/linux/powerpc/arch_sigreturn.c
new file mode 100644
index 0000000..c28a196
--- /dev/null
+++ b/strace/linux/powerpc/arch_sigreturn.c
@@ -0,0 +1,28 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	long esp = ppc_regs.gpr[1];
+	struct sigcontext sc;
+
+	/* Skip dummy stack frame. */
+#ifdef POWERPC64
+	if (current_personality == 0)
+		esp += 128;
+	else
+#endif
+		esp += 64;
+
+	if (umove(tcp, esp, &sc) < 0) {
+		tprintf("{mask=%#lx}", esp);
+	} else {
+		unsigned long mask[NSIG / 8 / sizeof(long)];
+#ifdef POWERPC64
+		mask[0] = sc.oldmask | (sc._unused[3] << 32);
+#else
+		mask[0] = sc.oldmask;
+		mask[1] = sc._unused[3];
+#endif
+		tprintsigmask_addr("{mask=", mask);
+		tprints("}");
+	}
+}
diff --git a/strace/linux/powerpc/errnoent.h b/strace/linux/powerpc/errnoent.h
new file mode 100644
index 0000000..b118c8e
--- /dev/null
+++ b/strace/linux/powerpc/errnoent.h
@@ -0,0 +1,2 @@
+#include "../errnoent.h"
+[ 58] = "EDEADLOCK",
diff --git a/strace/linux/powerpc/get_error.c b/strace/linux/powerpc/get_error.c
new file mode 100644
index 0000000..8f10612
--- /dev/null
+++ b/strace/linux/powerpc/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (ppc_regs.ccr & 0x10000000) {
+		tcp->u_rval = -1;
+		tcp->u_error = ppc_regs.gpr[3];
+	} else {
+		tcp->u_rval = ppc_regs.gpr[3];
+	}
+}
diff --git a/strace/linux/powerpc/get_scno.c b/strace/linux/powerpc/get_scno.c
new file mode 100644
index 0000000..ef06656
--- /dev/null
+++ b/strace/linux/powerpc/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = ppc_regs.gpr[0];
+	return 1;
+}
diff --git a/strace/linux/powerpc/get_syscall_args.c b/strace/linux/powerpc/get_syscall_args.c
new file mode 100644
index 0000000..66bcae3
--- /dev/null
+++ b/strace/linux/powerpc/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = ppc_regs.orig_gpr3;
+	tcp->u_arg[1] = ppc_regs.gpr[4];
+	tcp->u_arg[2] = ppc_regs.gpr[5];
+	tcp->u_arg[3] = ppc_regs.gpr[6];
+	tcp->u_arg[4] = ppc_regs.gpr[7];
+	tcp->u_arg[5] = ppc_regs.gpr[8];
+	return 1;
+}
diff --git a/strace/linux/powerpc/getregs_old.c b/strace/linux/powerpc/getregs_old.c
new file mode 100644
index 0000000..22167cb
--- /dev/null
+++ b/strace/linux/powerpc/getregs_old.c
@@ -0,0 +1,35 @@
+/*
+ * PTRACE_GETREGS was added to the PowerPC kernel in v2.6.23,
+ * we provide a slow fallback for old kernels.
+ */
+static int
+getregs_old(pid_t pid)
+{
+	int i;
+	long r;
+
+	if (iflag) {
+		r = upeek(pid, sizeof(long) * PT_NIP, (long *)&ppc_regs.nip);
+		if (r)
+			goto out;
+	}
+#ifdef POWERPC64 /* else we never use it */
+	r = upeek(pid, sizeof(long) * PT_MSR, (long *)&ppc_regs.msr);
+	if (r)
+		goto out;
+#endif
+	r = upeek(pid, sizeof(long) * PT_CCR, (long *)&ppc_regs.ccr);
+	if (r)
+		goto out;
+	r = upeek(pid, sizeof(long) * PT_ORIG_R3, (long *)&ppc_regs.orig_gpr3);
+	if (r)
+		goto out;
+	for (i = 0; i <= 8; i++) {
+		r = upeek(pid, sizeof(long) * (PT_R0 + i),
+			  (long *)&ppc_regs.gpr[i]);
+		if (r)
+			goto out;
+	}
+ out:
+	return r;
+}
diff --git a/strace/linux/powerpc/ioctls_arch0.h b/strace/linux/powerpc/ioctls_arch0.h
new file mode 100644
index 0000000..9b00dc3
--- /dev/null
+++ b/strace/linux/powerpc/ioctls_arch0.h
@@ -0,0 +1,92 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/powerpc/include/ tree. */
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x741f, 0x00 },
+{ "asm/ioctls.h", "TCGETA", _IOC_READ, 0x7417, 0x14 },
+{ "asm/ioctls.h", "TCGETS", _IOC_READ, 0x7413, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x741d, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm/ioctls.h", "TCSETA", _IOC_WRITE, 0x7418, 0x14 },
+{ "asm/ioctls.h", "TCSETAF", _IOC_WRITE, 0x741c, 0x14 },
+{ "asm/ioctls.h", "TCSETAW", _IOC_WRITE, 0x7419, 0x14 },
+{ "asm/ioctls.h", "TCSETS", _IOC_WRITE, 0x7414, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", _IOC_WRITE, 0x7416, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", _IOC_WRITE, 0x7415, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x741e, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETC", _IOC_READ, 0x7412, 0x06 },
+{ "asm/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm/ioctls.h", "TIOCGETP", _IOC_READ, 0x7408, 0x06 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGLTC", _IOC_READ, 0x7474, 0x06 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7477, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", 0, 0x542e, 0 },
+{ "asm/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm/ioctls.h", "TIOCGSID", 0, 0x5429, 0 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm/ioctls.h", "TIOCGWINSZ", _IOC_READ, 0x7468, 0x08 },
+{ "asm/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm/ioctls.h", "TIOCSETC", _IOC_WRITE, 0x7411, 0x06 },
+{ "asm/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm/ioctls.h", "TIOCSETN", _IOC_WRITE, 0x740a, 0x06 },
+{ "asm/ioctls.h", "TIOCSETP", _IOC_WRITE, 0x7409, 0x06 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSLTC", _IOC_WRITE, 0x7475, 0x06 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7476, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", 0, 0x542f, 0 },
+{ "asm/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCSWINSZ", _IOC_WRITE, 0x7467, 0x08 },
+{ "asm/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm/nvram.h", "IOC_NVRAM_GET_OFFSET", _IOC_READ|_IOC_WRITE, 0x7042, 0x04 },
+{ "asm/nvram.h", "IOC_NVRAM_SYNC", _IOC_NONE, 0x7043, 0x00 },
+{ "asm/nvram.h", "OBSOLETE_PMAC_NVRAM_GET_OFFSET", _IOC_READ|_IOC_WRITE, 0x7040, 0x04 },
+{ "asm/ps3fb.h", "FBIO_WAITFORVSYNC", _IOC_WRITE, 0x4620, 0x04 },
+{ "asm/ps3fb.h", "PS3FB_IOCTL_FSEL", _IOC_WRITE, 0x7206, 0x04 },
+{ "asm/ps3fb.h", "PS3FB_IOCTL_GETMODE", _IOC_READ, 0x7202, 0x04 },
+{ "asm/ps3fb.h", "PS3FB_IOCTL_OFF", _IOC_NONE, 0x7205, 0x00 },
+{ "asm/ps3fb.h", "PS3FB_IOCTL_ON", _IOC_NONE, 0x7204, 0x00 },
+{ "asm/ps3fb.h", "PS3FB_IOCTL_SCREENINFO", _IOC_READ, 0x7203, 0x04 },
+{ "asm/ps3fb.h", "PS3FB_IOCTL_SETMODE", _IOC_WRITE, 0x7201, 0x04 },
+{ "asm/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
diff --git a/strace/linux/powerpc/ioctls_inc0.h b/strace/linux/powerpc/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/powerpc/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/powerpc/syscallent.h b/strace/linux/powerpc/syscallent.h
new file mode 100644
index 0000000..b6dfb85
--- /dev/null
+++ b/strace/linux/powerpc/syscallent.h
@@ -0,0 +1,413 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid),			"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 5,	0,		SEN(vm86),			"vm86"			},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 5,	0,		SEN(printargs),			"modify_ldt"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[166] = { 5,	0,		SEN(query_module),		"query_module"		},
+[167] = { 3,	TD,		SEN(poll),			"poll"			},
+[168] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[169] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[170] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[171] = { 5,	0,		SEN(prctl),			"prctl"			},
+[172] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[173] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[174] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[175] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[176] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[177] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[178] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[179] = { 6,	TD,		SEN(pread),			"pread64"		},
+[180] = { 6,	TD,		SEN(pwrite),			"pwrite64"		},
+[181] = { 3,	TF,		SEN(chown),			"chown"			},
+[182] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[183] = { 2,	0,		SEN(capget),			"capget"		},
+[184] = { 2,	0,		SEN(capset),			"capset"		},
+[185] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[186] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[187] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[188] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[189] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[190] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[191] = { 5,	TD,		SEN(readahead),			"readahead"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[193] = { 4,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 4,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[199] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[200] = { 3,	0,		SEN(printargs),			"pciconfig_iobase"	},
+[201] = { 6,	0,		SEN(printargs),			"multiplexer"		},
+[202] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[203] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[204] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[205] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[206] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[207] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[208] = { 2,	TS,		SEN(kill),			"tkill"			},
+[209] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[210] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[211] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[212] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[213] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[214] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[215] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[216] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[217] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[218] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[219] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[220] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[221] = { 6,	0,		SEN(futex),			"futex"			},
+[222] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[223] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[224] = { },
+[225] = { 5,	0,		SEN(printargs),			"tuxcall"		},
+[226] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[227] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[228] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[229] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[230] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[231] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[232] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[233] = { 6,	TD,		SEN(fadvise64),			"fadvise64"		},
+[234] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[235] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[236] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[237] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[238] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[239] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[240] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[241] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[242] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[243] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[244] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[245] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[246] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[247] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[248] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[249] = { 2,	0,		SEN(printargs),			"swapcontext"		},
+[250] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[251] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[252] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[253] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[254] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[255] = { 1,	0,		SEN(printargs),			"rtas"			},
+[256] = { 5,	0,		SEN(printargs),			"sys_debug_setcontext"	},
+[257] = { 5,	0,		SEN(vserver),			"vserver"		},
+[258] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[259] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[260] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[261] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[262] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[263] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[264] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[265] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[266] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[267] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[268] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[269] = { 5,	0,		SEN(add_key),			"add_key"		},
+[270] = { 4,	0,		SEN(request_key),		"request_key"		},
+[271] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[272] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[273] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[274] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[275] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[276] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[277] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[278] = { 3,	0,		SEN(printargs),			"spu_run"		},
+[279] = { 4,	0,		SEN(printargs),			"spu_create"		},
+[280] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[281] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[282] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[283] = { 6,	TD,		SEN(splice),			"splice"		},
+[284] = { 4,	TD,		SEN(tee),			"tee"			},
+[285] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[286] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[287] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[288] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[289] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[290] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[291] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[292] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[293] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[294] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[295] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[296] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[297] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[298] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[299] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[300] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[301] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[302] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[303] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[304] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[305] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[306] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[307] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[308] = { 6,	TD,		SEN(sync_file_range2),		"sync_file_range2"	},
+[309] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[310] = { 3,	0,		SEN(subpage_prot),		"subpage_prot"		},
+[311] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[312] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[313] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[314] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[315] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[316] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[317] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[318] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[319] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[320] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[321] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[322] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[323] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[324] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[325] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[326] = { 3,	TN,		SEN(socket),			"socket"		},
+[327] = { 3,	TN,		SEN(bind),			"bind"			},
+[328] = { 3,	TN,		SEN(connect),			"connect"		},
+[329] = { 2,	TN,		SEN(listen),			"listen"		},
+[330] = { 3,	TN,		SEN(accept),			"accept"		},
+[331] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[332] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[333] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[334] = { 4,	TN,		SEN(send),			"send"			},
+[335] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[336] = { 4,	TN,		SEN(recv),			"recv"			},
+[337] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[338] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[339] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[340] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[341] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[342] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[343] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[344] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[345] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[346] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[347] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[348] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[349] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[350] = { 2,	TD,		SEN(setns),			"setns"			},
+[351] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[352] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[353] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[354] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[355] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[356] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[357] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[358] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[359] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[360] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[361] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[362] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[363] = { 0,	0,		SEN(printargs),			"switch_endian"		},
+[364] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[365] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[366] = { 3,	TI,		SEN(semop),			"semop"			},
+[367] = { 3,	TI,		SEN(semget),			"semget"		},
+[368] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[369] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[370] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[371] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[372] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[373] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[374] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[375] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[376] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[377] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[378] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[379] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[380] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[381] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/powerpc/userent.h b/strace/linux/powerpc/userent.h
new file mode 100644
index 0000000..e2094c2
--- /dev/null
+++ b/strace/linux/powerpc/userent.h
@@ -0,0 +1,47 @@
+#ifndef PT_ORIG_R3
+# define PT_ORIG_R3 34
+#endif
+#define REGSIZE (sizeof(unsigned long))
+{ REGSIZE*PT_R0,		"r0" },
+{ REGSIZE*PT_R1,		"r1" },
+{ REGSIZE*PT_R2,		"r2" },
+{ REGSIZE*PT_R3,		"r3" },
+{ REGSIZE*PT_R4,		"r4" },
+{ REGSIZE*PT_R5,		"r5" },
+{ REGSIZE*PT_R6,		"r6" },
+{ REGSIZE*PT_R7,		"r7" },
+{ REGSIZE*PT_R8,		"r8" },
+{ REGSIZE*PT_R9,		"r9" },
+{ REGSIZE*PT_R10,		"r10" },
+{ REGSIZE*PT_R11,		"r11" },
+{ REGSIZE*PT_R12,		"r12" },
+{ REGSIZE*PT_R13,		"r13" },
+{ REGSIZE*PT_R14,		"r14" },
+{ REGSIZE*PT_R15,		"r15" },
+{ REGSIZE*PT_R16,		"r16" },
+{ REGSIZE*PT_R17,		"r17" },
+{ REGSIZE*PT_R18,		"r18" },
+{ REGSIZE*PT_R19,		"r19" },
+{ REGSIZE*PT_R20,		"r20" },
+{ REGSIZE*PT_R21,		"r21" },
+{ REGSIZE*PT_R22,		"r22" },
+{ REGSIZE*PT_R23,		"r23" },
+{ REGSIZE*PT_R24,		"r24" },
+{ REGSIZE*PT_R25,		"r25" },
+{ REGSIZE*PT_R26,		"r26" },
+{ REGSIZE*PT_R27,		"r27" },
+{ REGSIZE*PT_R28,		"r28" },
+{ REGSIZE*PT_R29,		"r29" },
+{ REGSIZE*PT_R30,		"r30" },
+{ REGSIZE*PT_R31,		"r31" },
+{ REGSIZE*PT_NIP,		"NIP" },
+{ REGSIZE*PT_MSR,		"MSR" },
+{ REGSIZE*PT_ORIG_R3,		"ORIG_R3" },
+{ REGSIZE*PT_CTR,		"CTR" },
+{ REGSIZE*PT_LNK,		"LNK" },
+{ REGSIZE*PT_XER,		"XER" },
+{ REGSIZE*PT_CCR,		"CCR" },
+{ REGSIZE*PT_FPR0,		"FPR0" },
+#undef REGSIZE
+/* Other fields in "struct user" */
+#include "../userent0.h"
diff --git a/strace/linux/powerpc64/arch_regs.c b/strace/linux/powerpc64/arch_regs.c
new file mode 100644
index 0000000..9064651
--- /dev/null
+++ b/strace/linux/powerpc64/arch_regs.c
@@ -0,0 +1,2 @@
+#include "powerpc/arch_regs.c"
+#define ARCH_PC_REG ppc_regs.nip
diff --git a/strace/linux/powerpc64/arch_regs.h b/strace/linux/powerpc64/arch_regs.h
new file mode 100644
index 0000000..05e4fe1
--- /dev/null
+++ b/strace/linux/powerpc64/arch_regs.h
@@ -0,0 +1 @@
+#include "powerpc/arch_regs.h"
diff --git a/strace/linux/powerpc64/arch_sigreturn.c b/strace/linux/powerpc64/arch_sigreturn.c
new file mode 100644
index 0000000..316022f
--- /dev/null
+++ b/strace/linux/powerpc64/arch_sigreturn.c
@@ -0,0 +1 @@
+#include "powerpc/arch_sigreturn.c"
diff --git a/strace/linux/powerpc64/errnoent.h b/strace/linux/powerpc64/errnoent.h
new file mode 100644
index 0000000..30f6425
--- /dev/null
+++ b/strace/linux/powerpc64/errnoent.h
@@ -0,0 +1 @@
+#include "powerpc/errnoent.h"
diff --git a/strace/linux/powerpc64/errnoent1.h b/strace/linux/powerpc64/errnoent1.h
new file mode 100644
index 0000000..c0f7787
--- /dev/null
+++ b/strace/linux/powerpc64/errnoent1.h
@@ -0,0 +1 @@
+#include "errnoent.h"
diff --git a/strace/linux/powerpc64/get_error.c b/strace/linux/powerpc64/get_error.c
new file mode 100644
index 0000000..209bfd8
--- /dev/null
+++ b/strace/linux/powerpc64/get_error.c
@@ -0,0 +1 @@
+#include "powerpc/get_error.c"
diff --git a/strace/linux/powerpc64/get_scno.c b/strace/linux/powerpc64/get_scno.c
new file mode 100644
index 0000000..8a943e8
--- /dev/null
+++ b/strace/linux/powerpc64/get_scno.c
@@ -0,0 +1,15 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = ppc_regs.gpr[0];
+	/*
+	 * Check for 64/32 bit mode.
+	 * Embedded implementations covered by Book E extension of PPC use
+	 * bit 0 (CM) of 32-bit Machine state register (MSR).
+	 * Other implementations use bit 0 (SF) of 64-bit MSR.
+	 */
+	unsigned int currpers = (ppc_regs.msr & 0x8000000080000000) ? 0 : 1;
+	update_personality(tcp, currpers);
+	return 1;
+}
diff --git a/strace/linux/powerpc64/get_syscall_args.c b/strace/linux/powerpc64/get_syscall_args.c
new file mode 100644
index 0000000..5561a55
--- /dev/null
+++ b/strace/linux/powerpc64/get_syscall_args.c
@@ -0,0 +1 @@
+#include "powerpc/get_syscall_args.c"
diff --git a/strace/linux/powerpc64/getregs_old.c b/strace/linux/powerpc64/getregs_old.c
new file mode 100644
index 0000000..177ff74
--- /dev/null
+++ b/strace/linux/powerpc64/getregs_old.c
@@ -0,0 +1 @@
+#include "powerpc/getregs_old.c"
diff --git a/strace/linux/powerpc64/ioctls_arch0.h b/strace/linux/powerpc64/ioctls_arch0.h
new file mode 100644
index 0000000..bf6962c
--- /dev/null
+++ b/strace/linux/powerpc64/ioctls_arch0.h
@@ -0,0 +1 @@
+#include "powerpc/ioctls_arch0.h"
diff --git a/strace/linux/powerpc64/ioctls_arch1.h b/strace/linux/powerpc64/ioctls_arch1.h
new file mode 100644
index 0000000..bf6962c
--- /dev/null
+++ b/strace/linux/powerpc64/ioctls_arch1.h
@@ -0,0 +1 @@
+#include "powerpc/ioctls_arch0.h"
diff --git a/strace/linux/powerpc64/ioctls_inc0.h b/strace/linux/powerpc64/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/powerpc64/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/powerpc64/ioctls_inc1.h b/strace/linux/powerpc64/ioctls_inc1.h
new file mode 100644
index 0000000..2e5b2de
--- /dev/null
+++ b/strace/linux/powerpc64/ioctls_inc1.h
@@ -0,0 +1 @@
+#include "powerpc/ioctls_inc0.h"
diff --git a/strace/linux/powerpc64/signalent1.h b/strace/linux/powerpc64/signalent1.h
new file mode 100644
index 0000000..093cba7
--- /dev/null
+++ b/strace/linux/powerpc64/signalent1.h
@@ -0,0 +1 @@
+#include "signalent.h"
diff --git a/strace/linux/powerpc64/syscallent.h b/strace/linux/powerpc64/syscallent.h
new file mode 100644
index 0000000..e0c18af
--- /dev/null
+++ b/strace/linux/powerpc64/syscallent.h
@@ -0,0 +1,408 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid),			"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 5,	0,		SEN(vm86),			"vm86"			},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 5,	0,		SEN(printargs),			"modify_ldt"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[166] = { 5,	0,		SEN(query_module),		"query_module"		},
+[167] = { 3,	TD,		SEN(poll),			"poll"			},
+[168] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[169] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[170] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[171] = { 5,	0,		SEN(prctl),			"prctl"			},
+[172] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[173] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[174] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[175] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[176] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[177] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[178] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[179] = { 4,	TD,		SEN(pread),			"pread64"		},
+[180] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[181] = { 3,	TF,		SEN(chown),			"chown"			},
+[182] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[183] = { 2,	0,		SEN(capget),			"capget"		},
+[184] = { 2,	0,		SEN(capset),			"capset"		},
+[185] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[186] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[187] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[188] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[189] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[190] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[191] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[192 ... 197] = { },
+[198] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[199] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[200] = { 3,	0,		SEN(printargs),			"pciconfig_iobase"	},
+[201] = { 6,	0,		SEN(printargs),			"multiplexer"		},
+[202] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[203] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[204] = { },
+[205] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[206] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[207] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[208] = { 2,	TS,		SEN(kill),			"tkill"			},
+[209] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[210] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[211] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[212] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[213] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[214] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[215] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[216] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[217] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[218] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[219] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[220] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[221] = { 6,	0,		SEN(futex),			"futex"			},
+[222] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[223] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[224] = { },
+[225] = { 5,	0,		SEN(printargs),			"tuxcall"		},
+[226] = { },
+[227] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[228] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[229] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[230] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[231] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[232] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[233] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[234] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[235] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[236] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[237] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[238] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[239] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[240] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[241] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[242] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[243] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[244] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[245] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[246] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[247] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[248] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[249] = { 2,	0,		SEN(printargs),			"swapcontext"		},
+[250] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[251] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[252] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[253] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[254] = { },
+[255] = { 1,	0,		SEN(printargs),			"rtas"			},
+[256] = { 5,	0,		SEN(printargs),			"sys_debug_setcontext"	},
+[257] = { 5,	0,		SEN(vserver),			"vserver"		},
+[258] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[259] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[260] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[261] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[262] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[263] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[264] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[265] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[266] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[267] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[268] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[269] = { 5,	0,		SEN(add_key),			"add_key"		},
+[270] = { 4,	0,		SEN(request_key),		"request_key"		},
+[271] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[272] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[273] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[274] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[275] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[276] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[277] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[278] = { 3,	0,		SEN(printargs),			"spu_run"		},
+[279] = { 4,	0,		SEN(printargs),			"spu_create"		},
+[280] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[281] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[282] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[283] = { 6,	TD,		SEN(splice),			"splice"		},
+[284] = { 4,	TD,		SEN(tee),			"tee"			},
+[285] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[286] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[287] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[288] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[289] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[290] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[291] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[292] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[293] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[294] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[295] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[296] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[297] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[298] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[299] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[300] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[301] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[302] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[303] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[304] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[305] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[306] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[307] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[308] = { 4,	TD,		SEN(sync_file_range2),		"sync_file_range2"	},
+[309] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[310] = { 3,	0,		SEN(subpage_prot),		"subpage_prot"		},
+[311] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[312] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[313] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[314] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[315] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[316] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[317] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[318] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[319] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[320] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[321] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[322] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[323] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[324] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[325] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[326] = { 3,	TN,		SEN(socket),			"socket"		},
+[327] = { 3,	TN,		SEN(bind),			"bind"			},
+[328] = { 3,	TN,		SEN(connect),			"connect"		},
+[329] = { 2,	TN,		SEN(listen),			"listen"		},
+[330] = { 3,	TN,		SEN(accept),			"accept"		},
+[331] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[332] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[333] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[334] = { 4,	TN,		SEN(send),			"send"			},
+[335] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[336] = { 4,	TN,		SEN(recv),			"recv"			},
+[337] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[338] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[339] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[340] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[341] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[342] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[343] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[344] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[345] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[346] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[347] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[348] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[349] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[350] = { 2,	TD,		SEN(setns),			"setns"			},
+[351] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[352] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[353] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[354] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[355] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[356] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[357] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[358] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[359] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[360] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[361] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[362] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[363] = { 0,	0,		SEN(printargs),			"switch_endian"		},
+[364] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[365] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[366] = { 3,	TI,		SEN(semop),			"semop"			},
+[367] = { 3,	TI,		SEN(semget),			"semget"		},
+[368] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[369] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[370] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[371] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[372] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[373] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[374] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[375] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[376] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[377] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[378] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[379] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[380] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[381] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/powerpc64/syscallent1.h b/strace/linux/powerpc64/syscallent1.h
new file mode 100644
index 0000000..64a9f01
--- /dev/null
+++ b/strace/linux/powerpc64/syscallent1.h
@@ -0,0 +1 @@
+#include "powerpc/syscallent.h"
diff --git a/strace/linux/powerpc64/userent.h b/strace/linux/powerpc64/userent.h
new file mode 100644
index 0000000..27c240b
--- /dev/null
+++ b/strace/linux/powerpc64/userent.h
@@ -0,0 +1 @@
+#include "powerpc/userent.h"
diff --git a/strace/linux/ptp_clock.h b/strace/linux/ptp_clock.h
new file mode 100644
index 0000000..b65c834
--- /dev/null
+++ b/strace/linux/ptp_clock.h
@@ -0,0 +1,98 @@
+/*
+ * PTP 1588 clock support - user space interface
+ *
+ * Copyright (C) 2010 OMICRON electronics GmbH
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+#ifndef _PTP_CLOCK_H_
+#define _PTP_CLOCK_H_
+
+#include <linux/ioctl.h>
+#include <linux/types.h>
+
+/* PTP_xxx bits, for the flags field within the request structures. */
+#define PTP_ENABLE_FEATURE (1<<0)
+#define PTP_RISING_EDGE    (1<<1)
+#define PTP_FALLING_EDGE   (1<<2)
+
+/*
+ * struct ptp_clock_time - represents a time value
+ *
+ * The sign of the seconds field applies to the whole value. The
+ * nanoseconds field is always unsigned. The reserved field is
+ * included for sub-nanosecond resolution, should the demand for
+ * this ever appear.
+ *
+ */
+struct ptp_clock_time {
+	__s64 sec;  /* seconds */
+	__u32 nsec; /* nanoseconds */
+	__u32 reserved;
+};
+
+struct ptp_clock_caps {
+	int max_adj;   /* Maximum frequency adjustment in parts per billon. */
+	int n_alarm;   /* Number of programmable alarms. */
+	int n_ext_ts;  /* Number of external time stamp channels. */
+	int n_per_out; /* Number of programmable periodic signals. */
+	int pps;       /* Whether the clock supports a PPS callback. */
+	int rsv[15];   /* Reserved for future use. */
+};
+
+struct ptp_extts_request {
+	unsigned int index;  /* Which channel to configure. */
+	unsigned int flags;  /* Bit field for PTP_xxx flags. */
+	unsigned int rsv[2]; /* Reserved for future use. */
+};
+
+struct ptp_perout_request {
+	struct ptp_clock_time start;  /* Absolute start time. */
+	struct ptp_clock_time period; /* Desired period, zero means disable. */
+	unsigned int index;           /* Which channel to configure. */
+	unsigned int flags;           /* Reserved for future use. */
+	unsigned int rsv[4];          /* Reserved for future use. */
+};
+
+#define PTP_MAX_SAMPLES 25 /* Maximum allowed offset measurement samples. */
+
+struct ptp_sys_offset {
+	unsigned int n_samples; /* Desired number of measurements. */
+	unsigned int rsv[3];    /* Reserved for future use. */
+	/*
+	 * Array of interleaved system/phc time stamps. The kernel
+	 * will provide 2*n_samples + 1 time stamps, with the last
+	 * one as a system time stamp.
+	 */
+	struct ptp_clock_time ts[2 * PTP_MAX_SAMPLES + 1];
+};
+
+#define PTP_CLK_MAGIC '='
+
+#define PTP_CLOCK_GETCAPS  _IOR(PTP_CLK_MAGIC, 1, struct ptp_clock_caps)
+#define PTP_EXTTS_REQUEST  _IOW(PTP_CLK_MAGIC, 2, struct ptp_extts_request)
+#define PTP_PEROUT_REQUEST _IOW(PTP_CLK_MAGIC, 3, struct ptp_perout_request)
+#define PTP_ENABLE_PPS     _IOW(PTP_CLK_MAGIC, 4, int)
+#define PTP_SYS_OFFSET     _IOW(PTP_CLK_MAGIC, 5, struct ptp_sys_offset)
+
+struct ptp_extts_event {
+	struct ptp_clock_time t; /* Time event occured. */
+	unsigned int index;      /* Which channel produced the event. */
+	unsigned int flags;      /* Reserved for future use. */
+	unsigned int rsv[2];     /* Reserved for future use. */
+};
+
+#endif
diff --git a/strace/linux/s390/arch_regs.c b/strace/linux/s390/arch_regs.c
new file mode 100644
index 0000000..fefb763
--- /dev/null
+++ b/strace/linux/s390/arch_regs.c
@@ -0,0 +1,5 @@
+/* PTRACE_GETREGSET on S390 is available since linux v2.6.27. */
+static struct user_regs_struct s390_regset;
+unsigned long *const s390_frame_ptr = &s390_regset.gprs[15];
+#define ARCH_REGS_FOR_GETREGSET s390_regset
+#define ARCH_PC_REG s390_regset.psw.addr
diff --git a/strace/linux/s390/arch_regs.h b/strace/linux/s390/arch_regs.h
new file mode 100644
index 0000000..586326f
--- /dev/null
+++ b/strace/linux/s390/arch_regs.h
@@ -0,0 +1 @@
+extern unsigned long *const s390_frame_ptr;
diff --git a/strace/linux/s390/arch_sigreturn.c b/strace/linux/s390/arch_sigreturn.c
new file mode 100644
index 0000000..00549ba
--- /dev/null
+++ b/strace/linux/s390/arch_sigreturn.c
@@ -0,0 +1,13 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	long mask[NSIG / 8 / sizeof(long)];
+	const long addr = *s390_frame_ptr + __SIGNAL_FRAMESIZE;
+
+	if (umove(tcp, addr, &mask) < 0) {
+		tprintf("{mask=%#lx}", addr);
+	} else {
+		tprintsigmask_addr("{mask=", mask);
+		tprints("}");
+	}
+}
diff --git a/strace/linux/s390/get_error.c b/strace/linux/s390/get_error.c
new file mode 100644
index 0000000..f491962
--- /dev/null
+++ b/strace/linux/s390/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(s390_regset.gprs[2])) {
+		tcp->u_rval = -1;
+		tcp->u_error = -s390_regset.gprs[2];
+	} else {
+		tcp->u_rval = s390_regset.gprs[2];
+	}
+}
diff --git a/strace/linux/s390/get_scno.c b/strace/linux/s390/get_scno.c
new file mode 100644
index 0000000..d323860
--- /dev/null
+++ b/strace/linux/s390/get_scno.c
@@ -0,0 +1,8 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = s390_regset.gprs[2] ?
+		    s390_regset.gprs[2] : s390_regset.gprs[1];
+	return 1;
+}
diff --git a/strace/linux/s390/get_syscall_args.c b/strace/linux/s390/get_syscall_args.c
new file mode 100644
index 0000000..ebf6c6c
--- /dev/null
+++ b/strace/linux/s390/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = s390_regset.orig_gpr2;
+	tcp->u_arg[1] = s390_regset.gprs[3];
+	tcp->u_arg[2] = s390_regset.gprs[4];
+	tcp->u_arg[3] = s390_regset.gprs[5];
+	tcp->u_arg[4] = s390_regset.gprs[6];
+	tcp->u_arg[5] = s390_regset.gprs[7];
+	return 1;
+}
diff --git a/strace/linux/s390/ioctls_arch0.h b/strace/linux/s390/ioctls_arch0.h
new file mode 100644
index 0000000..4228f96
--- /dev/null
+++ b/strace/linux/s390/ioctls_arch0.h
@@ -0,0 +1,59 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/s390/include/ tree. */
+{ "asm/chsc.h", "CHSC_INFO_CCL", _IOC_READ|_IOC_WRITE, 0x6386, 0x1014 },
+{ "asm/chsc.h", "CHSC_INFO_CHANNEL_PATH", _IOC_READ|_IOC_WRITE, 0x6382, 0x100c },
+{ "asm/chsc.h", "CHSC_INFO_CI", _IOC_READ|_IOC_WRITE, 0x6385, 0x100c },
+{ "asm/chsc.h", "CHSC_INFO_CPD", _IOC_READ|_IOC_WRITE, 0x6387, 0x1014 },
+{ "asm/chsc.h", "CHSC_INFO_CU", _IOC_READ|_IOC_WRITE, 0x6383, 0x100c },
+{ "asm/chsc.h", "CHSC_INFO_DCAL", _IOC_READ|_IOC_WRITE, 0x6388, 0x1010 },
+{ "asm/chsc.h", "CHSC_INFO_SCH_CU", _IOC_READ|_IOC_WRITE, 0x6384, 0x1008 },
+{ "asm/chsc.h", "CHSC_ON_CLOSE_REMOVE", _IOC_NONE, 0x638b, 0x00 },
+{ "asm/chsc.h", "CHSC_ON_CLOSE_SET", _IOC_READ|_IOC_WRITE, 0x638a, 0x1000 },
+{ "asm/chsc.h", "CHSC_START", _IOC_READ|_IOC_WRITE, 0x6381, 0x1000 },
+{ "asm/chsc.h", "CHSC_START_SYNC", _IOC_READ|_IOC_WRITE, 0x6389, 0x1000 },
+{ "asm/cmb.h", "BIODASDCMFDISABLE", _IOC_NONE, 0x4421, 0x00 },
+{ "asm/cmb.h", "BIODASDCMFENABLE", _IOC_NONE, 0x4420, 0x00 },
+{ "asm/cmb.h", "BIODASDREADALLCMB", _IOC_READ|_IOC_WRITE, 0x4421, 0x58 },
+{ "asm/dasd.h", "BIODASDABORTIO", _IOC_NONE, 0x44f0, 0x00 },
+{ "asm/dasd.h", "BIODASDALLOWIO", _IOC_NONE, 0x44f1, 0x00 },
+{ "asm/dasd.h", "BIODASDDISABLE", _IOC_NONE, 0x4400, 0x00 },
+{ "asm/dasd.h", "BIODASDENABLE", _IOC_NONE, 0x4401, 0x00 },
+{ "asm/dasd.h", "BIODASDFMT", _IOC_WRITE, 0x4401, 0x10 },
+{ "asm/dasd.h", "BIODASDGATTR", _IOC_READ, 0x4405, 0x20 },
+{ "asm/dasd.h", "BIODASDINFO", _IOC_READ, 0x4401, 0x178 },
+{ "asm/dasd.h", "BIODASDINFO2", _IOC_READ, 0x4403, 0x1a0 },
+{ "asm/dasd.h", "BIODASDPRRD", _IOC_READ, 0x4402, 0x408 },
+{ "asm/dasd.h", "BIODASDPRRST", _IOC_NONE, 0x4405, 0x00 },
+{ "asm/dasd.h", "BIODASDPSRD", _IOC_READ, 0x4404, 0xc0 },
+{ "asm/dasd.h", "BIODASDQUIESCE", _IOC_NONE, 0x4406, 0x00 },
+{ "asm/dasd.h", "BIODASDRESUME", _IOC_NONE, 0x4407, 0x00 },
+{ "asm/dasd.h", "BIODASDRLSE", _IOC_NONE, 0x4403, 0x00 },
+{ "asm/dasd.h", "BIODASDRSRV", _IOC_NONE, 0x4402, 0x00 },
+{ "asm/dasd.h", "BIODASDSATTR", _IOC_WRITE, 0x4402, 0x20 },
+{ "asm/dasd.h", "BIODASDSLCK", _IOC_NONE, 0x4404, 0x00 },
+{ "asm/dasd.h", "BIODASDSNID", _IOC_READ|_IOC_WRITE, 0x4401, 0x0d },
+{ "asm/dasd.h", "BIODASDSYMMIO", _IOC_READ|_IOC_WRITE, 0x44f0, 0x20 },
+{ "asm/dasd.h", "DASDAPIVER", _IOC_READ, 0x4400, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", 0, 0x545E, 0 },
+{ "asm/tape390.h", "TAPE390_CRYPT_QUERY", _IOC_READ, 0x6403, 0x03 },
+{ "asm/tape390.h", "TAPE390_CRYPT_SET", _IOC_WRITE, 0x6402, 0x03 },
+{ "asm/tape390.h", "TAPE390_DISPLAY", _IOC_WRITE, 0x6401, 0x11 },
+{ "asm/tape390.h", "TAPE390_KEKL_QUERY", _IOC_READ, 0x6405, 0x86 },
+{ "asm/tape390.h", "TAPE390_KEKL_SET", _IOC_WRITE, 0x6404, 0x86 },
+{ "asm/zcrypt.h", "ICARSACRT", _IOC_READ|_IOC_WRITE, 0x7a06, 0x00 },
+{ "asm/zcrypt.h", "ICARSAMODEXPO", _IOC_READ|_IOC_WRITE, 0x7a05, 0x00 },
+{ "asm/zcrypt.h", "Z90STAT_CEX2ACOUNT", _IOC_READ, 0x7a4e, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_CEX2CCOUNT", _IOC_READ, 0x7a4d, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_DOMAIN_INDEX", _IOC_READ, 0x7a47, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_PCICACOUNT", _IOC_READ, 0x7a41, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_PCICCCOUNT", _IOC_READ, 0x7a42, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_PCIXCCMCL2COUNT", _IOC_READ, 0x7a4b, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_PCIXCCMCL3COUNT", _IOC_READ, 0x7a4c, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_PENDINGQ_COUNT", _IOC_READ, 0x7a45, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_PERDEV_REQCNT", _IOC_READ, 0x7a4a, 0x100 },
+{ "asm/zcrypt.h", "Z90STAT_QDEPTH_MASK", _IOC_READ, 0x7a49, 0x40 },
+{ "asm/zcrypt.h", "Z90STAT_REQUESTQ_COUNT", _IOC_READ, 0x7a44, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_STATUS_MASK", _IOC_READ, 0x7a48, 0x40 },
+{ "asm/zcrypt.h", "Z90STAT_TOTALCOUNT", _IOC_READ, 0x7a40, 0x04 },
+{ "asm/zcrypt.h", "Z90STAT_TOTALOPEN_COUNT", _IOC_READ, 0x7a46, 0x04 },
+{ "asm/zcrypt.h", "ZSECSENDCPRB", _IOC_READ|_IOC_WRITE, 0x7a81, 0x00 },
+{ "asm/zcrypt.h", "ZSENDEP11CPRB", _IOC_READ|_IOC_WRITE, 0x7a04, 0x00 },
diff --git a/strace/linux/s390/ioctls_inc0.h b/strace/linux/s390/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/s390/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/s390/syscallent.h b/strace/linux/s390/syscallent.h
new file mode 100644
index 0000000..fb5ddc1
--- /dev/null
+++ b/strace/linux/s390/syscallent.h
@@ -0,0 +1,411 @@
+/*
+ * Copyright (c) 2000 IBM Deutschland Entwicklung GmbH, IBM Coporation
+ * Authors: Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
+ *          D.J. Barrow  <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * 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.
+ *
+ */
+
+[  0] = {MA,	0,		SEN(setup),			"setup"			},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { },
+[ 18] = { },
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { },
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { },
+[ 32] = { },
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { },
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { },
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { },
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { },
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { },
+[ 59] = { },
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { },
+[ 69] = { },
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { },
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { },
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 1,	TD|TM|SI,	SEN(old_mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { },
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { },
+[110] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { },
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 5,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { },
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { },
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 5,	TD,		SEN(pread),			"pread64"		},
+[181] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"chown"			},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 1,	TD|TM|SI,	SEN(old_mmap_pgoff),		"mmap2"			},
+[193] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(getegid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"chown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[222] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[223] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[224] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[225] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[226] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[227] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[228] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[229] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[230] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[231] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[232] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[233] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[234] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[235] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[236] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[237] = { 2,	TS,		SEN(kill),			"tkill"			},
+[238] = { 6,	0,		SEN(futex),			"futex"			},
+[239] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[240] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[241] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[242] = { },
+[243] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[244] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[245] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[246] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[247] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[248] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[249] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[250] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[251] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[252] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[253] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[254] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[255] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[256] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[257] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[258] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[259] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[260] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[261] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[262] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[263] = { 5,	0,		SEN(vserver),			"vserver"		},
+[264] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[265] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[266] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[267] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[268] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[269] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[270] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[271] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[272] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[273] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[274] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[275] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[276] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[277] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[278] = { 5,	0,		SEN(add_key),			"add_key"		},
+[279] = { 4,	0,		SEN(request_key),		"request_key"		},
+[280] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[281] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[282] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[283] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[284] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[285] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[286] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[287] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[288] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[289] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[290] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[291] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[292] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[293] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[294] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[295] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[296] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[297] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[298] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[299] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[300] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[301] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[302] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[303] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[304] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[305] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[306] = { 6,	TD,		SEN(splice),			"splice"		},
+[307] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[308] = { 4,	TD,		SEN(tee),			"tee"			},
+[309] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[310] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[311] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[312] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[313] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[314] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[315] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[316] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[317] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[318] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[319] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[320] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[321] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[322] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[323] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[324] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[325] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[326] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[327] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[328] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[329] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[330] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[331] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[332] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[333] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[334] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[335] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[336] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[337] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[338] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[339] = { 2,	TD,		SEN(setns),			"setns"			},
+[340] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[341] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[342] = { 2,	0,		SEN(printargs),			"s390_runtime_instr"	},
+[343] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[344] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[345] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[346] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[347] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[348] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[349] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[350] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[351] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[352] = { 3,	0,		SEN(printargs),			"s390_pci_mmio_write",	},
+[353] = { 3,	0,		SEN(printargs),			"s390_pci_mmio_read",	},
+[354] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[355] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[356] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[357] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[358] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[359] = { 3,	TN,		SEN(socket),			"socket"		},
+[360] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[361] = { 3,	TN,		SEN(bind),			"bind"			},
+[362] = { 3,	TN,		SEN(connect),			"connect"		},
+[363] = { 2,	TN,		SEN(listen),			"listen"		},
+[364] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[365] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[366] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[367] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[368] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[369] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[370] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[371] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[372] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[373] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[374] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[375] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[376] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[377] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/s390/userent.h b/strace/linux/s390/userent.h
new file mode 100644
index 0000000..f9c71d8
--- /dev/null
+++ b/strace/linux/s390/userent.h
@@ -0,0 +1,35 @@
+#include "userent0.h"
+{ PT_FPR0_HI,		"fpr0.hi" },
+{ PT_FPR0_LO,		"fpr0.lo" },
+{ PT_FPR1_HI,		"fpr1.hi" },
+{ PT_FPR1_LO,		"fpr1.lo" },
+{ PT_FPR2_HI,		"fpr2.hi" },
+{ PT_FPR2_LO,		"fpr2.lo" },
+{ PT_FPR3_HI,		"fpr3.hi" },
+{ PT_FPR3_LO,		"fpr3.lo" },
+{ PT_FPR4_HI,		"fpr4.hi" },
+{ PT_FPR4_LO,		"fpr4.lo" },
+{ PT_FPR5_HI,		"fpr5.hi" },
+{ PT_FPR5_LO,		"fpr5.lo" },
+{ PT_FPR6_HI,		"fpr6.hi" },
+{ PT_FPR6_LO,		"fpr6.lo" },
+{ PT_FPR7_HI,		"fpr7.hi" },
+{ PT_FPR7_LO,		"fpr7.lo" },
+{ PT_FPR8_HI,		"fpr8.hi" },
+{ PT_FPR8_LO,		"fpr8.lo" },
+{ PT_FPR9_HI,		"fpr9.hi" },
+{ PT_FPR9_LO,		"fpr9.lo" },
+{ PT_FPR10_HI,		"fpr10.hi" },
+{ PT_FPR10_LO,		"fpr10.lo" },
+{ PT_FPR11_HI,		"fpr11.hi" },
+{ PT_FPR11_LO,		"fpr11.lo" },
+{ PT_FPR12_HI,		"fpr12.hi" },
+{ PT_FPR12_LO,		"fpr12.lo" },
+{ PT_FPR13_HI,		"fpr13.hi" },
+{ PT_FPR13_LO,		"fpr13.lo" },
+{ PT_FPR14_HI,		"fpr14.hi" },
+{ PT_FPR14_LO,		"fpr14.lo" },
+{ PT_FPR15_HI,		"fpr15.hi" },
+{ PT_FPR15_LO,		"fpr15.lo" },
+/* Other fields in "struct user" */
+#include "userent1.h"
diff --git a/strace/linux/s390/userent0.h b/strace/linux/s390/userent0.h
new file mode 100644
index 0000000..71fae74
--- /dev/null
+++ b/strace/linux/s390/userent0.h
@@ -0,0 +1,41 @@
+{ PT_PSWMASK,		"psw_mask" },
+{ PT_PSWADDR,		"psw_addr" },
+{ PT_GPR0,		"gpr0" },
+{ PT_GPR1,		"gpr1" },
+{ PT_GPR2,		"gpr2" },
+{ PT_GPR3,		"gpr3" },
+{ PT_GPR4,		"gpr4" },
+{ PT_GPR5,		"gpr5" },
+{ PT_GPR6,		"gpr6" },
+{ PT_GPR7,		"gpr7" },
+{ PT_GPR8,		"gpr8" },
+{ PT_GPR9,		"gpr9" },
+{ PT_GPR10,		"gpr10" },
+{ PT_GPR11,		"gpr11" },
+{ PT_GPR12,		"gpr12" },
+{ PT_GPR13,		"gpr13" },
+{ PT_GPR14,		"gpr14" },
+{ PT_GPR15,		"gpr15" },
+{ PT_ACR0,		"acr0" },
+{ PT_ACR1,		"acr1" },
+{ PT_ACR2,		"acr2" },
+{ PT_ACR3,		"acr3" },
+{ PT_ACR4,		"acr4" },
+{ PT_ACR5,		"acr5" },
+{ PT_ACR6,		"acr6" },
+{ PT_ACR7,		"acr7" },
+{ PT_ACR8,		"acr8" },
+{ PT_ACR9,		"acr9" },
+{ PT_ACR10,		"acr10" },
+{ PT_ACR11,		"acr11" },
+{ PT_ACR12,		"acr12" },
+{ PT_ACR13,		"acr13" },
+{ PT_ACR14,		"acr14" },
+{ PT_ACR15,		"acr15" },
+{ PT_ORIGGPR2,		"orig_gpr2" },
+{ PT_FPC,		"fpc" },
+/* PT_FPR* differ between s390 and s390x */
+{ PT_CR_9,		"cr9" },
+{ PT_CR_10,		"cr10" },
+{ PT_CR_11,		"cr11" },
+{ PT_IEEE_IP,		"ieee_exception_ip" },
diff --git a/strace/linux/s390/userent1.h b/strace/linux/s390/userent1.h
new file mode 100644
index 0000000..3ff99b9
--- /dev/null
+++ b/strace/linux/s390/userent1.h
@@ -0,0 +1,11 @@
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+/* S390[X] has no start_data */
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/s390x/arch_regs.c b/strace/linux/s390x/arch_regs.c
new file mode 100644
index 0000000..74aaaf6
--- /dev/null
+++ b/strace/linux/s390x/arch_regs.c
@@ -0,0 +1,2 @@
+#include "s390/arch_regs.c"
+#define ARCH_PC_REG s390_regset.psw.addr
diff --git a/strace/linux/s390x/arch_regs.h b/strace/linux/s390x/arch_regs.h
new file mode 100644
index 0000000..14fced4
--- /dev/null
+++ b/strace/linux/s390x/arch_regs.h
@@ -0,0 +1 @@
+#include "s390/arch_regs.h"
diff --git a/strace/linux/s390x/arch_sigreturn.c b/strace/linux/s390x/arch_sigreturn.c
new file mode 100644
index 0000000..679a395
--- /dev/null
+++ b/strace/linux/s390x/arch_sigreturn.c
@@ -0,0 +1 @@
+#include "s390/arch_sigreturn.c"
diff --git a/strace/linux/s390x/get_error.c b/strace/linux/s390x/get_error.c
new file mode 100644
index 0000000..8e3944c
--- /dev/null
+++ b/strace/linux/s390x/get_error.c
@@ -0,0 +1 @@
+#include "s390/get_error.c"
diff --git a/strace/linux/s390x/get_scno.c b/strace/linux/s390x/get_scno.c
new file mode 100644
index 0000000..71816fb
--- /dev/null
+++ b/strace/linux/s390x/get_scno.c
@@ -0,0 +1 @@
+#include "s390/get_scno.c"
diff --git a/strace/linux/s390x/get_syscall_args.c b/strace/linux/s390x/get_syscall_args.c
new file mode 100644
index 0000000..4ded41d
--- /dev/null
+++ b/strace/linux/s390x/get_syscall_args.c
@@ -0,0 +1 @@
+#include "s390/get_syscall_args.c"
diff --git a/strace/linux/s390x/ioctls_arch0.h b/strace/linux/s390x/ioctls_arch0.h
new file mode 100644
index 0000000..4a16cb5
--- /dev/null
+++ b/strace/linux/s390x/ioctls_arch0.h
@@ -0,0 +1 @@
+#include "s390/ioctls_arch0.h"
diff --git a/strace/linux/s390x/ioctls_inc0.h b/strace/linux/s390x/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/s390x/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/s390x/syscallent.h b/strace/linux/s390x/syscallent.h
new file mode 100644
index 0000000..bf9c9fa
--- /dev/null
+++ b/strace/linux/s390x/syscallent.h
@@ -0,0 +1,395 @@
+/*
+ * Copyright (c) 2000 IBM Deutschland Entwicklung GmbH, IBM Coporation
+ * Author: Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
+ * 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.
+ *
+ */
+
+[  0] = {MA,	0,		SEN(setup),			"setup"			},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { },
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { },
+[ 17] = { },
+[ 18] = { },
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { },
+[ 24] = { },
+[ 25] = { },
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { },
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { },
+[ 32] = { },
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { },
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { },
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { },
+[ 47] = { },
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { },
+[ 50] = { },
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { },
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { },
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { },
+[ 59] = { },
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68 ... 71] = { },
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { },
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80 ... 82] = { },
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { },
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 1,	TD|TM|SI,	SEN(old_mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { },
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { },
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { },
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { },
+[110] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { },
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 5,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { },
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138 ... 140] = { },
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"select"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164 ... 166] = { },
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170 ... 171] = { },
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 4,	TD,		SEN(pread),			"pread64"		},
+[181] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { },
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[189] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[196 ... 197] = { },
+[198] = { 3,	TF,		SEN(chown),			"lchown"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[202] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[212] = { 3,	TF,		SEN(chown),			"chown"			},
+[213] = { 1,	0,		SEN(setuid),			"setuid"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { },
+[222] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[223] = { },
+[224] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[225] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[226] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[227] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[228] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[229] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[230] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[231] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[232] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[233] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[234] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[235] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[236] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[237] = { 2,	TS,		SEN(kill),			"tkill"			},
+[238] = { 6,	0,		SEN(futex),			"futex"			},
+[239] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[240] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[241] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[242] = { },
+[243] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[244] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[245] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[246] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[247] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[248] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[249] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[250] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[251] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[252] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[253] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[254] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[255] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[256] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[257] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[258] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[259] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[260] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[261] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[262] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[263] = { 5,	0,		SEN(vserver),			"vserver"		},
+[264] = { },
+[265] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[266] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[267] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[268] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[269] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[270] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[271] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[272] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[273] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[274] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[275] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[276] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[277] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[278] = { 5,	0,		SEN(add_key),			"add_key"		},
+[279] = { 4,	0,		SEN(request_key),		"request_key"		},
+[280] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[281] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[282] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[283] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[284] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[285] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[286] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[287] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[288] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[289] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[290] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[291] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[292] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[293] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[294] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[295] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[296] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[297] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[298] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[299] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[300] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[301] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[302] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[303] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[304] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[305] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[306] = { 6,	TD,		SEN(splice),			"splice"		},
+[307] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[308] = { 4,	TD,		SEN(tee),			"tee"			},
+[309] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[310] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[311] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[312] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[313] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[314] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[315] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[316] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[317] = { 4,	TD,		SEN(timerfd),			"timerfd"		},
+[318] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[319] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[320] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[321] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[322] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[323] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[324] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[325] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[326] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[327] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[328] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[329] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[330] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[331] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[332] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[333] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[334] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[335] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[336] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[337] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[338] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[339] = { 2,	TD,		SEN(setns),			"setns"			},
+[340] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[341] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[342] = { 2,	0,		SEN(printargs),			"s390_runtime_instr"	},
+[343] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[344] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[345] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[346] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[347] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[348] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[349] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[350] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[351] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[352] = { 3,	0,		SEN(printargs),			"s390_pci_mmio_write",	},
+[353] = { 3,	0,		SEN(printargs),			"s390_pci_mmio_read",	},
+[354] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[355] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[356] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[357] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[358] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[359] = { 3,	TN,		SEN(socket),			"socket"		},
+[360] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[361] = { 3,	TN,		SEN(bind),			"bind"			},
+[362] = { 3,	TN,		SEN(connect),			"connect"		},
+[363] = { 2,	TN,		SEN(listen),			"listen"		},
+[364] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[365] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[366] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[367] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[368] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[369] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[370] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[371] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[372] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[373] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[374] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[375] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[376] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[377] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/s390x/userent.h b/strace/linux/s390x/userent.h
new file mode 100644
index 0000000..d14488f
--- /dev/null
+++ b/strace/linux/s390x/userent.h
@@ -0,0 +1,19 @@
+#include "../s390/userent0.h"
+{ PT_FPR0,		"fpr0" },
+{ PT_FPR1,		"fpr1" },
+{ PT_FPR2,		"fpr2" },
+{ PT_FPR3,		"fpr3" },
+{ PT_FPR4,		"fpr4" },
+{ PT_FPR5,		"fpr5" },
+{ PT_FPR6,		"fpr6" },
+{ PT_FPR7,		"fpr7" },
+{ PT_FPR8,		"fpr8" },
+{ PT_FPR9,		"fpr9" },
+{ PT_FPR10,		"fpr10" },
+{ PT_FPR11,		"fpr11" },
+{ PT_FPR12,		"fpr12" },
+{ PT_FPR13,		"fpr13" },
+{ PT_FPR14,		"fpr14" },
+{ PT_FPR15,		"fpr15" },
+/* Other fields in "struct user" */
+#include "../s390/userent1.h"
diff --git a/strace/linux/sh/arch_getrval2.c b/strace/linux/sh/arch_getrval2.c
new file mode 100644
index 0000000..8f60de7
--- /dev/null
+++ b/strace/linux/sh/arch_getrval2.c
@@ -0,0 +1,8 @@
+long
+getrval2(struct tcb *tcp)
+{
+	long val;
+	if (upeek(tcp->pid, 4*(REG_REG0+1), &val) < 0)
+		return -1;
+	return val;
+}
diff --git a/strace/linux/sh/arch_regs.c b/strace/linux/sh/arch_regs.c
new file mode 100644
index 0000000..0ce8184
--- /dev/null
+++ b/strace/linux/sh/arch_regs.c
@@ -0,0 +1,2 @@
+static long sh_r0;
+#define ARCH_PC_PEEK_ADDR (4 * REG_PC)
diff --git a/strace/linux/sh/get_error.c b/strace/linux/sh/get_error.c
new file mode 100644
index 0000000..158ff9e
--- /dev/null
+++ b/strace/linux/sh/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(sh_r0)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -sh_r0;
+	} else {
+		tcp->u_rval = sh_r0;
+	}
+}
diff --git a/strace/linux/sh/get_scno.c b/strace/linux/sh/get_scno.c
new file mode 100644
index 0000000..a9bc5d8
--- /dev/null
+++ b/strace/linux/sh/get_scno.c
@@ -0,0 +1,27 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	long scno = 0;
+
+	/*
+	 * In the new syscall ABI, the system call number is in R3.
+	 */
+	if (upeek(tcp->pid, 4*(REG_REG0+3), &scno) < 0)
+		return -1;
+
+	if (scno < 0) {
+		/* Odd as it may seem, a glibc bug has been known to cause
+		   glibc to issue bogus negative syscall numbers.  So for
+		   our purposes, make strace print what it *should* have been */
+		long correct_scno = (scno & 0xff);
+		if (debug_flag)
+			error_msg("Detected glibc bug: bogus system call"
+				  " number = %ld, correcting to %ld",
+				  scno, correct_scno);
+		scno = correct_scno;
+	}
+
+	tcp->scno = scno;
+	return 1;
+}
diff --git a/strace/linux/sh/get_syscall_args.c b/strace/linux/sh/get_syscall_args.c
new file mode 100644
index 0000000..0b6c881
--- /dev/null
+++ b/strace/linux/sh/get_syscall_args.c
@@ -0,0 +1,19 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	static const int syscall_regs[MAX_ARGS] = {
+		4 * (REG_REG0+4),
+		4 * (REG_REG0+5),
+		4 * (REG_REG0+6),
+		4 * (REG_REG0+7),
+		4 * (REG_REG0  ),
+		4 * (REG_REG0+1)
+	};
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, syscall_regs[i], &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/sh/get_syscall_result.c b/strace/linux/sh/get_syscall_result.c
new file mode 100644
index 0000000..5db3025
--- /dev/null
+++ b/strace/linux/sh/get_syscall_result.c
@@ -0,0 +1,6 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	/* new syscall ABI returns result in R0 */
+	return upeek(tcp->pid, 4 * REG_REG0, (long *)&sh_r0) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/sh/ioctls_arch0.h b/strace/linux/sh/ioctls_arch0.h
new file mode 100644
index 0000000..4cf49ce
--- /dev/null
+++ b/strace/linux/sh/ioctls_arch0.h
@@ -0,0 +1,77 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/sh/include/ tree. */
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x741f, 0x00 },
+{ "asm/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x741d, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", _IOC_WRITE, 0x5425, 0x04 },
+{ "asm/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x741e, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", _IOC_NONE, 0x5428, 0x00 },
+{ "asm/ioctls.h", "TIOCCONS", _IOC_NONE, 0x541d, 0x00 },
+{ "asm/ioctls.h", "TIOCEXCL", _IOC_NONE, 0x540c, 0x00 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", _IOC_READ, 0x5424, 0x04 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7477, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x542e, 0x20 },
+{ "asm/ioctls.h", "TIOCGSID", _IOC_READ, 0x5429, 0x04 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", _IOC_READ, 0x5419, 0x04 },
+{ "asm/ioctls.h", "TIOCLINUX", _IOC_WRITE, 0x541c, 0x01 },
+{ "asm/ioctls.h", "TIOCMBIC", _IOC_WRITE, 0x5417, 0x04 },
+{ "asm/ioctls.h", "TIOCMBIS", _IOC_WRITE, 0x5416, 0x04 },
+{ "asm/ioctls.h", "TIOCMGET", _IOC_READ, 0x5415, 0x04 },
+{ "asm/ioctls.h", "TIOCMIWAIT", _IOC_NONE, 0x545c, 0x00 },
+{ "asm/ioctls.h", "TIOCMSET", _IOC_WRITE, 0x5418, 0x04 },
+{ "asm/ioctls.h", "TIOCNOTTY", _IOC_NONE, 0x5422, 0x00 },
+{ "asm/ioctls.h", "TIOCNXCL", _IOC_NONE, 0x540d, 0x00 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", _IOC_WRITE, 0x5420, 0x04 },
+{ "asm/ioctls.h", "TIOCSBRK", _IOC_NONE, 0x5427, 0x00 },
+{ "asm/ioctls.h", "TIOCSCTTY", _IOC_NONE, 0x540e, 0x00 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", _IOC_NONE, 0x5453, 0x00 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", _IOC_READ, 0x5459, 0x04 },
+{ "asm/ioctls.h", "TIOCSERGWILD", _IOC_READ, 0x5454, 0x04 },
+{ "asm/ioctls.h", "TIOCSERSWILD", _IOC_WRITE, 0x5455, 0x04 },
+{ "asm/ioctls.h", "TIOCSETD", _IOC_WRITE, 0x5423, 0x04 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7476, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x542f, 0x20 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", _IOC_WRITE, 0x541a, 0x04 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", _IOC_WRITE, 0x5412, 0x01 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCVHANGUP", _IOC_NONE, 0x5437, 0x00 },
+{ "asm/sockios.h", "FIOGETOWN", _IOC_READ, 0x667b, 0x04 },
+{ "asm/sockios.h", "FIOSETOWN", _IOC_WRITE, 0x667c, 0x04 },
+{ "asm/sockios.h", "SIOCATMARK", _IOC_READ, 0x7307, 0x04 },
+{ "asm/sockios.h", "SIOCGPGRP", _IOC_READ, 0x7309, 0x04 },
+{ "asm/sockios.h", "SIOCGSTAMP", _IOC_READ, 0x7364, 0x08 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", _IOC_READ, 0x7365, 0x08 },
+{ "asm/sockios.h", "SIOCSPGRP", _IOC_WRITE, 0x7308, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCGGIODATA1", _IOC_READ, 0x6b02, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCGGIODATA2", _IOC_READ, 0x6b04, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCGGIODATA4", _IOC_READ, 0x6b06, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCHARDRESET", _IOC_NONE, 0x6b08, 0x00 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCRESET", _IOC_NONE, 0x6b00, 0x00 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIODATA1", _IOC_WRITE, 0x6b01, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIODATA2", _IOC_WRITE, 0x6b03, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIODATA4", _IOC_WRITE, 0x6b05, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIOSETADDR", _IOC_WRITE, 0x6b07, 0x04 },
diff --git a/strace/linux/sh/ioctls_inc0.h b/strace/linux/sh/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/sh/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/sh/syscallent.h b/strace/linux/sh/syscallent.h
new file mode 100644
index 0000000..d2b462d
--- /dev/null
+++ b/strace/linux/sh/syscallent.h
@@ -0,0 +1,399 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 2000 PocketPenguins Inc.  Linux for Hitachi SuperH
+ *                    port by Greg Banks <gbanks@pocketpenguins.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { 1,	TD,		SEN(oldselect),			"select"		},
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { 1,	0,		SEN(vm86old),			"vm86old"		},
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 3,	0,		SEN(cacheflush),		"cacheflush"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { 5,	0,		SEN(vm86),			"vm86"			},
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 6,	TD,		SEN(pread),			"pread64"		},
+[181] = { 6,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"chown"			},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188 ... 189] = { },
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[193] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[194] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(getegid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"chown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[221] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[222 ... 223] = { },
+[224] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[225] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[226] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[227] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[228] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[229] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[230] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[231] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[232] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[233] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[234] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[235] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[236] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[237] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[238] = { 2,	TS,		SEN(kill),			"tkill"			},
+[239] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[240] = { 6,	0,		SEN(futex),			"futex"			},
+[241] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[242] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[243 ... 244] = { },
+[245] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[246] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[247] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[248] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[249] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[250] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[251] = { },
+[252] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[253] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[254] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[255] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[256] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[257] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[258] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[259] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[260] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[261] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[262] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[263] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[264] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[265] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[266] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[267] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[268] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[269] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[270] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[271] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[272] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[273] = { },
+[274] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[275] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[276] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[277] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[278] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[279] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[280] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[281] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[282] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[283] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[284] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[285] = { 5,	0,		SEN(add_key),			"add_key"		},
+[286] = { 4,	0,		SEN(request_key),		"request_key"		},
+[287] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[288] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[289] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[290] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[291] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[292] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[293] = { },
+[294] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[295] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[296] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[297] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[298] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[299] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[300] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[301] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[302] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[303] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[304] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[305] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[306] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[307] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[308] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[309] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[310] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[311] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[312] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[313] = { 6,	TD,		SEN(splice),			"splice"		},
+[314] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[315] = { 4,	TD,		SEN(tee),			"tee"			},
+[316] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[317] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[318] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[319] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[320] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[321] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[322] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[323] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[324] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[325] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[326] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[327] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[328] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[329] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[330] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[331] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[332] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[333] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[334] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[335] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[336] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[337] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[338] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[339] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[340] = { 3,	TN,		SEN(socket),			"socket"		},
+[341] = { 3,	TN,		SEN(bind),			"bind"			},
+[342] = { 3,	TN,		SEN(connect),			"connect"		},
+[343] = { 2,	TN,		SEN(listen),			"listen"		},
+[344] = { 3,	TN,		SEN(accept),			"accept"		},
+[345] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[346] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[347] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[348] = { 4,	TN,		SEN(send),			"send"			},
+[349] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[350] = { 4,	TN,		SEN(recv),			"recv"			},
+[351] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[352] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[353] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[354] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[355] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[356] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[357] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[358] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[359] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[360] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[361] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[362] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[363] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[364] = { 2,	TD,		SEN(setns),			"setns"			},
+[365] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[366] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[367] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[368] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/sh/userent.h b/strace/linux/sh/userent.h
new file mode 100644
index 0000000..116861a
--- /dev/null
+++ b/strace/linux/sh/userent.h
@@ -0,0 +1,53 @@
+XLAT(4*REG_REG0),
+{ 4*(REG_REG0+1),	"4*REG_REG1" },
+{ 4*(REG_REG0+2),	"4*REG_REG2" },
+{ 4*(REG_REG0+3),	"4*REG_REG3" },
+{ 4*(REG_REG0+4),	"4*REG_REG4" },
+{ 4*(REG_REG0+5),	"4*REG_REG5" },
+{ 4*(REG_REG0+6),	"4*REG_REG6" },
+{ 4*(REG_REG0+7),	"4*REG_REG7" },
+{ 4*(REG_REG0+8),	"4*REG_REG8" },
+{ 4*(REG_REG0+9),	"4*REG_REG9" },
+{ 4*(REG_REG0+10),	"4*REG_REG10" },
+{ 4*(REG_REG0+11),	"4*REG_REG11" },
+{ 4*(REG_REG0+12),	"4*REG_REG12" },
+{ 4*(REG_REG0+13),	"4*REG_REG13" },
+{ 4*(REG_REG0+14),	"4*REG_REG14" },
+XLAT(4*REG_REG15),
+XLAT(4*REG_PC),
+XLAT(4*REG_PR),
+XLAT(4*REG_SR),
+XLAT(4*REG_GBR),
+XLAT(4*REG_MACH),
+XLAT(4*REG_MACL),
+XLAT(4*REG_SYSCALL),
+XLAT(4*REG_FPUL),
+XLAT(4*REG_FPREG0),
+{ 4*(REG_FPREG0+1),	"4*REG_FPREG1" },
+{ 4*(REG_FPREG0+2),	"4*REG_FPREG2" },
+{ 4*(REG_FPREG0+3),	"4*REG_FPREG3" },
+{ 4*(REG_FPREG0+4),	"4*REG_FPREG4" },
+{ 4*(REG_FPREG0+5),	"4*REG_FPREG5" },
+{ 4*(REG_FPREG0+6),	"4*REG_FPREG6" },
+{ 4*(REG_FPREG0+7),	"4*REG_FPREG7" },
+{ 4*(REG_FPREG0+8),	"4*REG_FPREG8" },
+{ 4*(REG_FPREG0+9),	"4*REG_FPREG9" },
+{ 4*(REG_FPREG0+10),	"4*REG_FPREG10" },
+{ 4*(REG_FPREG0+11),	"4*REG_FPREG11" },
+{ 4*(REG_FPREG0+12),	"4*REG_FPREG12" },
+{ 4*(REG_FPREG0+13),	"4*REG_FPREG13" },
+{ 4*(REG_FPREG0+14),	"4*REG_FPREG14" },
+XLAT(4*REG_FPREG15),
+#ifdef REG_XDREG0
+XLAT(4*REG_XDREG0),
+{ 4*(REG_XDREG0+2),	"4*REG_XDREG2" },
+{ 4*(REG_XDREG0+4),	"4*REG_XDREG4" },
+{ 4*(REG_XDREG0+6),	"4*REG_XDREG6" },
+{ 4*(REG_XDREG0+8),	"4*REG_XDREG8" },
+{ 4*(REG_XDREG0+10),	"4*REG_XDREG10" },
+{ 4*(REG_XDREG0+12),	"4*REG_XDREG12" },
+XLAT(4*REG_XDREG14),
+#endif
+XLAT(4*REG_FPSCR),
+/* Other fields in "struct user" */
+#include "userent0.h"
diff --git a/strace/linux/sh/userent0.h b/strace/linux/sh/userent0.h
new file mode 100644
index 0000000..918805a
--- /dev/null
+++ b/strace/linux/sh/userent0.h
@@ -0,0 +1,13 @@
+XLAT_UOFF(u_fpvalid),
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(start_code),
+XLAT_UOFF(start_data),
+XLAT_UOFF(start_stack),
+XLAT_UOFF(signal),
+XLAT_UOFF(u_ar0),
+XLAT_UOFF(u_fpstate),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/sh64/arch_regs.c b/strace/linux/sh64/arch_regs.c
new file mode 100644
index 0000000..eb6701b
--- /dev/null
+++ b/strace/linux/sh64/arch_regs.c
@@ -0,0 +1,2 @@
+static long sh64_r9;
+#define ARCH_PC_PEEK_ADDR REG_PC
diff --git a/strace/linux/sh64/arch_regs.h b/strace/linux/sh64/arch_regs.h
new file mode 100644
index 0000000..7f64b49
--- /dev/null
+++ b/strace/linux/sh64/arch_regs.h
@@ -0,0 +1,15 @@
+/* SH64 Linux - this code assumes the following kernel API for system calls:
+        PC           Offset 0
+        System Call  Offset 16 (actually, (syscall no.) | (0x1n << 16),
+                     where n = no. of parameters.
+        Other regs   Offset 24+
+
+        On entry:    R2-7 = parameters 1-6 (as many as necessary)
+        On return:   R9   = result.
+*/
+
+/* Offset for peeks of registers */
+#define REG_OFFSET         (24)
+#define REG_GENERAL(x)     (8*(x)+REG_OFFSET)
+#define REG_PC             (0*8)
+#define REG_SYSCALL        (2*8)
diff --git a/strace/linux/sh64/get_error.c b/strace/linux/sh64/get_error.c
new file mode 100644
index 0000000..7858df7
--- /dev/null
+++ b/strace/linux/sh64/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(sh64_r9)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -sh64_r9;
+	} else {
+		tcp->u_rval = sh64_r9;
+	}
+}
diff --git a/strace/linux/sh64/get_scno.c b/strace/linux/sh64/get_scno.c
new file mode 100644
index 0000000..50a5223
--- /dev/null
+++ b/strace/linux/sh64/get_scno.c
@@ -0,0 +1,9 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	if (upeek(tcp->pid, REG_SYSCALL, &tcp->scno) < 0)
+		return -1;
+	tcp->scno &= 0xffff;
+	return 1;
+}
diff --git a/strace/linux/sh64/get_syscall_args.c b/strace/linux/sh64/get_syscall_args.c
new file mode 100644
index 0000000..3970df8
--- /dev/null
+++ b/strace/linux/sh64/get_syscall_args.c
@@ -0,0 +1,14 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	/* Registers used by SH5 Linux system calls for parameters */
+	static const int syscall_regs[MAX_ARGS] = { 2, 3, 4, 5, 6, 7 };
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, REG_GENERAL(syscall_regs[i]),
+			  &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/sh64/get_syscall_result.c b/strace/linux/sh64/get_syscall_result.c
new file mode 100644
index 0000000..93faf3d
--- /dev/null
+++ b/strace/linux/sh64/get_syscall_result.c
@@ -0,0 +1,6 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	/* ABI defines result returned in r9 */
+	return upeek(tcp->pid, REG_GENERAL(9), (long *)&sh64_r9) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/sh64/ioctls_arch0.h b/strace/linux/sh64/ioctls_arch0.h
new file mode 100644
index 0000000..36e5aa2
--- /dev/null
+++ b/strace/linux/sh64/ioctls_arch0.h
@@ -0,0 +1,77 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/sh/include/ tree. */
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x741f, 0x00 },
+{ "asm/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x741d, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", _IOC_WRITE, 0x5425, 0x04 },
+{ "asm/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x741e, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", _IOC_NONE, 0x5428, 0x00 },
+{ "asm/ioctls.h", "TIOCCONS", _IOC_NONE, 0x541d, 0x00 },
+{ "asm/ioctls.h", "TIOCEXCL", _IOC_NONE, 0x540c, 0x00 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", _IOC_READ, 0x5424, 0x04 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7477, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x542e, 0x20 },
+{ "asm/ioctls.h", "TIOCGSID", _IOC_READ, 0x5429, 0x04 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", _IOC_READ, 0x5419, 0x04 },
+{ "asm/ioctls.h", "TIOCLINUX", _IOC_WRITE, 0x541c, 0x01 },
+{ "asm/ioctls.h", "TIOCMBIC", _IOC_WRITE, 0x5417, 0x04 },
+{ "asm/ioctls.h", "TIOCMBIS", _IOC_WRITE, 0x5416, 0x04 },
+{ "asm/ioctls.h", "TIOCMGET", _IOC_READ, 0x5415, 0x04 },
+{ "asm/ioctls.h", "TIOCMIWAIT", _IOC_NONE, 0x545c, 0x00 },
+{ "asm/ioctls.h", "TIOCMSET", _IOC_WRITE, 0x5418, 0x04 },
+{ "asm/ioctls.h", "TIOCNOTTY", _IOC_NONE, 0x5422, 0x00 },
+{ "asm/ioctls.h", "TIOCNXCL", _IOC_NONE, 0x540d, 0x00 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", _IOC_WRITE, 0x5420, 0x04 },
+{ "asm/ioctls.h", "TIOCSBRK", _IOC_NONE, 0x5427, 0x00 },
+{ "asm/ioctls.h", "TIOCSCTTY", _IOC_NONE, 0x540e, 0x00 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", _IOC_NONE, 0x5453, 0x00 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", _IOC_READ, 0x5459, 0x04 },
+{ "asm/ioctls.h", "TIOCSERGWILD", _IOC_READ, 0x5454, 0x04 },
+{ "asm/ioctls.h", "TIOCSERSWILD", _IOC_WRITE, 0x5455, 0x04 },
+{ "asm/ioctls.h", "TIOCSETD", _IOC_WRITE, 0x5423, 0x04 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7476, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x542f, 0x20 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", _IOC_WRITE, 0x541a, 0x04 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", _IOC_WRITE, 0x5412, 0x01 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCVHANGUP", _IOC_NONE, 0x5437, 0x00 },
+{ "asm/sockios.h", "FIOGETOWN", _IOC_READ, 0x667b, 0x04 },
+{ "asm/sockios.h", "FIOSETOWN", _IOC_WRITE, 0x667c, 0x04 },
+{ "asm/sockios.h", "SIOCATMARK", _IOC_READ, 0x7307, 0x04 },
+{ "asm/sockios.h", "SIOCGPGRP", _IOC_READ, 0x7309, 0x04 },
+{ "asm/sockios.h", "SIOCGSTAMP", _IOC_READ, 0x7364, 0x10 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", _IOC_READ, 0x7365, 0x10 },
+{ "asm/sockios.h", "SIOCSPGRP", _IOC_WRITE, 0x7308, 0x04 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCGGIODATA1", _IOC_READ, 0x6b02, 0x08 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCGGIODATA2", _IOC_READ, 0x6b04, 0x08 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCGGIODATA4", _IOC_READ, 0x6b06, 0x08 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCHARDRESET", _IOC_NONE, 0x6b08, 0x00 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCRESET", _IOC_NONE, 0x6b00, 0x00 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIODATA1", _IOC_WRITE, 0x6b01, 0x08 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIODATA2", _IOC_WRITE, 0x6b03, 0x08 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIODATA4", _IOC_WRITE, 0x6b05, 0x08 },
+{ "mach-landisk/mach/gio.h", "GIODRV_IOCSGIOSETADDR", _IOC_WRITE, 0x6b07, 0x08 },
diff --git a/strace/linux/sh64/ioctls_inc0.h b/strace/linux/sh64/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/sh64/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/sh64/syscallent.h b/strace/linux/sh64/syscallent.h
new file mode 100644
index 0000000..3504881
--- /dev/null
+++ b/strace/linux/sh64/syscallent.h
@@ -0,0 +1,408 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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.
+ */
+
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 1,	0,		SEN(time),			"time"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 0,	TM,		SEN(break),			"break"			},
+[ 18] = { 2,	TF,		SEN(oldstat),			"oldstat"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 5,	TF,		SEN(mount),			"mount"			},
+[ 22] = { 1,	TF,		SEN(umount),			"umount"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 1,	0,		SEN(stime),			"stime"			},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TD,		SEN(oldfstat),			"oldfstat"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 2,	0,		SEN(stty),			"stty"			},
+[ 32] = { 2,	0,		SEN(gtty),			"gtty"			},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 0,	0,		SEN(ftime),			"ftime"			},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 39] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 40] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	0,		SEN(prof),			"prof"			},
+[ 45] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 53] = { 0,	0,		SEN(lock),			"lock"			},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 56] = { 0,	0,		SEN(mpx),			"mpx"			},
+[ 57] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[ 58] = { 2,	0,		SEN(ulimit),			"ulimit"		},
+[ 59] = { 1,	0,		SEN(oldolduname),		"oldolduname"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	0,		SEN(ustat),			"ustat"			},
+[ 63] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 64] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[ 65] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 66] = { 0,	0,		SEN(setsid),			"setsid"		},
+[ 67] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[ 68] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[ 69] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[ 70] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[ 71] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[ 72] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[ 73] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[ 74] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 75] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[ 76] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 77] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 78] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 79] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[ 80] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 81] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 82] = { },
+[ 83] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 84] = { 2,	TF,		SEN(oldlstat),			"oldlstat"		},
+[ 85] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 86] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[ 87] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 88] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 89] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[ 90] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 91] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 92] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 93] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 94] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 95] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[ 96] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[ 97] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 98] = { 4,	0,		SEN(profil),			"profil"		},
+[ 99] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[100] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[101] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[102] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[105] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[106] = { 2,	TF,		SEN(stat),			"stat"			},
+[107] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[108] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[109] = { 1,	0,		SEN(olduname),			"olduname"		},
+[110] = { 1,	0,		SEN(iopl),			"iopl"			},
+[111] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[112] = { 0,	0,		SEN(idle),			"idle"			},
+[113] = { },
+[114] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[115] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[116] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[117] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[118] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[119] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[120] = { 5,	TP,		SEN(clone),			"clone"			},
+[121] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[122] = { 1,	0,		SEN(uname),			"uname"			},
+[123] = { 3,	0,		SEN(printargs),			"cacheflush"		},
+[124] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[125] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[126] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[127] = { 2,	0,		SEN(create_module),		"create_module"		},
+[128] = { 3,	0,		SEN(init_module),		"init_module"		},
+[129] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[130] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[131] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[132] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[133] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[134] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[135] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[136] = { 1,	NF,		SEN(personality),		"personality"		},
+[137] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[138] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[139] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[140] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[141] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[142] = { 5,	TD,		SEN(select),			"_newselect"		},
+[143] = { 2,	TD,		SEN(flock),			"flock"			},
+[144] = { 3,	TM,		SEN(msync),			"msync"			},
+[145] = { 3,	TD,		SEN(readv),			"readv"			},
+[146] = { 3,	TD,		SEN(writev),			"writev"		},
+[147] = { 1,	0,		SEN(getsid),			"getsid"		},
+[148] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[149] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[150] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[151] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[152] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[153] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[154] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[155] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[156] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[157] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[158] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[159] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[160] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[161] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[162] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[163] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[164] = { 3,	0,		SEN(setresuid16),		"setresuid"		},
+[165] = { 3,	0,		SEN(getresuid16),		"getresuid"		},
+[166] = { },
+[167] = { 5,	0,		SEN(query_module),		"query_module"		},
+[168] = { 3,	TD,		SEN(poll),			"poll"			},
+[169] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[170] = { 3,	0,		SEN(setresgid16),		"setresgid"		},
+[171] = { 3,	0,		SEN(getresgid16),		"getresgid"		},
+[172] = { 5,	0,		SEN(prctl),			"prctl"			},
+[173] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[174] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[175] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[176] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[177] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[178] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[179] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[180] = { 4,	TD,		SEN(pread),			"pread64"		},
+[181] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[182] = { 3,	TF,		SEN(chown16),			"chown"			},
+[183] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[184] = { 2,	0,		SEN(capget),			"capget"		},
+[185] = { 2,	0,		SEN(capset),			"capset"		},
+[186] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[187] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[188 ... 189] = { },
+[190] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[191] = { 2,	0,		SEN(getrlimit),			"ugetrlimit"		},
+[192] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[193] = { 2,	TF,		SEN(truncate),			"truncate64"		},
+[194] = { 2,	TD,		SEN(ftruncate),			"ftruncate64"		},
+[195] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[196] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[197] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[198] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[199] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[200] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[201] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[202] = { 0,	NF,		SEN(getegid),			"getegid32"		},
+[203] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[204] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[205] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[206] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[207] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[208] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[209] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[210] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[211] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[212] = { 3,	TF,		SEN(chown),			"chown32"		},
+[213] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[214] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[215] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[216] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[217] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[218] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[219] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[220] = { 3,	TN,		SEN(socket),			"socket"		},
+[221] = { 3,	TN,		SEN(bind),			"bind"			},
+[222] = { 3,	TN,		SEN(connect),			"connect"		},
+[223] = { 2,	TN,		SEN(listen),			"listen"		},
+[224] = { 3,	TN,		SEN(accept),			"accept"		},
+[225] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[226] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[227] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[228] = { 4,	TN,		SEN(send),			"send"			},
+[229] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[230] = { 4,	TN,		SEN(recv),			"recv"			},
+[231] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[232] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[233] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[234] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[235] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[236] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[237] = { 3,	TI,		SEN(semop),			"semop"			},
+[238] = { 3,	TI,		SEN(semget),			"semget"		},
+[239] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[240] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[241] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[242] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[243] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[244] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[245] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[246] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[247] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[248] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[249] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[250 ... 251] = { },
+[252] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[253] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[254] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[255] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[256] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[257] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[258] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[259] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[260] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[261] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[262] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[263] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[264] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[265] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[266] = { 2,	TS,		SEN(kill),			"tkill"			},
+[267] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[268] = { 6,	0,		SEN(futex),			"futex"			},
+[269] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[270] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[271 ... 272] = { },
+[273] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[274] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[275] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[276] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[277] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[278] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[279] = { },
+[280] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[281] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[282] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[283] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[284] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[285] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[286] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[287] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[288] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[289] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[290] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[291] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[292] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[293] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[294] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[295] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[296] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[297] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[298] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[299] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[300] = { 4,	TD,		SEN(fadvise64),			"fadvise64_64"		},
+[301] = { },
+[302] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[303] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[304] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[305] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[306] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[307] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[308] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[309] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[310] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[311] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[312] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[313] = { 5,	0,		SEN(add_key),			"add_key"		},
+[314] = { 4,	0,		SEN(request_key),		"request_key"		},
+[315] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[316] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[317] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[318] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[319] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[320] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[321] = { },
+[322] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[323] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[324] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[325] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[326] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[327] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[328] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[329] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[330] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[331] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[332] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[333] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[334] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[335] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[336] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[337] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[338] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[339] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[340] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[341] = { 6,	TD,		SEN(splice),			"splice"		},
+[342] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[343] = { 4,	TD,		SEN(tee),			"tee"			},
+[344] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[345] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[346] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[347] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[348] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[349] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[350] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[351] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[352] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[353] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[354] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[355] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[356] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[357] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[358] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[359] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[360] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[361] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[362] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[363] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[364] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[365] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[366] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[367] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[368] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[369] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[370] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[371] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[372] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[373] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[374] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[375] = { 2,	TD,		SEN(setns),			"setns"			},
+[376] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[377] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[378] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[379] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/sh64/userent.h b/strace/linux/sh64/userent.h
new file mode 100644
index 0000000..e8810d2
--- /dev/null
+++ b/strace/linux/sh64/userent.h
@@ -0,0 +1,154 @@
+{ 0,			"PC(L)" },
+{ 4,			"PC(U)" },
+{ 8,			"SR(L)" },
+{ 12,			"SR(U)" },
+{ 16,			"syscall no.(L)" },
+{ 20,			"syscall_no.(U)" },
+{ 24,			"R0(L)" },
+{ 28,			"R0(U)" },
+{ 32,			"R1(L)" },
+{ 36,			"R1(U)" },
+{ 40,			"R2(L)" },
+{ 44,			"R2(U)" },
+{ 48,			"R3(L)" },
+{ 52,			"R3(U)" },
+{ 56,			"R4(L)" },
+{ 60,			"R4(U)" },
+{ 64,			"R5(L)" },
+{ 68,			"R5(U)" },
+{ 72,			"R6(L)" },
+{ 76,			"R6(U)" },
+{ 80,			"R7(L)" },
+{ 84,			"R7(U)" },
+{ 88,			"R8(L)" },
+{ 92,			"R8(U)" },
+{ 96,			"R9(L)" },
+{ 100,			"R9(U)" },
+{ 104,			"R10(L)" },
+{ 108,			"R10(U)" },
+{ 112,			"R11(L)" },
+{ 116,			"R11(U)" },
+{ 120,			"R12(L)" },
+{ 124,			"R12(U)" },
+{ 128,			"R13(L)" },
+{ 132,			"R13(U)" },
+{ 136,			"R14(L)" },
+{ 140,			"R14(U)" },
+{ 144,			"R15(L)" },
+{ 148,			"R15(U)" },
+{ 152,			"R16(L)" },
+{ 156,			"R16(U)" },
+{ 160,			"R17(L)" },
+{ 164,			"R17(U)" },
+{ 168,			"R18(L)" },
+{ 172,			"R18(U)" },
+{ 176,			"R19(L)" },
+{ 180,			"R19(U)" },
+{ 184,			"R20(L)" },
+{ 188,			"R20(U)" },
+{ 192,			"R21(L)" },
+{ 196,			"R21(U)" },
+{ 200,			"R22(L)" },
+{ 204,			"R22(U)" },
+{ 208,			"R23(L)" },
+{ 212,			"R23(U)" },
+{ 216,			"R24(L)" },
+{ 220,			"R24(U)" },
+{ 224,			"R25(L)" },
+{ 228,			"R25(U)" },
+{ 232,			"R26(L)" },
+{ 236,			"R26(U)" },
+{ 240,			"R27(L)" },
+{ 244,			"R27(U)" },
+{ 248,			"R28(L)" },
+{ 252,			"R28(U)" },
+{ 256,			"R29(L)" },
+{ 260,			"R29(U)" },
+{ 264,			"R30(L)" },
+{ 268,			"R30(U)" },
+{ 272,			"R31(L)" },
+{ 276,			"R31(U)" },
+{ 280,			"R32(L)" },
+{ 284,			"R32(U)" },
+{ 288,			"R33(L)" },
+{ 292,			"R33(U)" },
+{ 296,			"R34(L)" },
+{ 300,			"R34(U)" },
+{ 304,			"R35(L)" },
+{ 308,			"R35(U)" },
+{ 312,			"R36(L)" },
+{ 316,			"R36(U)" },
+{ 320,			"R37(L)" },
+{ 324,			"R37(U)" },
+{ 328,			"R38(L)" },
+{ 332,			"R38(U)" },
+{ 336,			"R39(L)" },
+{ 340,			"R39(U)" },
+{ 344,			"R40(L)" },
+{ 348,			"R40(U)" },
+{ 352,			"R41(L)" },
+{ 356,			"R41(U)" },
+{ 360,			"R42(L)" },
+{ 364,			"R42(U)" },
+{ 368,			"R43(L)" },
+{ 372,			"R43(U)" },
+{ 376,			"R44(L)" },
+{ 380,			"R44(U)" },
+{ 384,			"R45(L)" },
+{ 388,			"R45(U)" },
+{ 392,			"R46(L)" },
+{ 396,			"R46(U)" },
+{ 400,			"R47(L)" },
+{ 404,			"R47(U)" },
+{ 408,			"R48(L)" },
+{ 412,			"R48(U)" },
+{ 416,			"R49(L)" },
+{ 420,			"R49(U)" },
+{ 424,			"R50(L)" },
+{ 428,			"R50(U)" },
+{ 432,			"R51(L)" },
+{ 436,			"R51(U)" },
+{ 440,			"R52(L)" },
+{ 444,			"R52(U)" },
+{ 448,			"R53(L)" },
+{ 452,			"R53(U)" },
+{ 456,			"R54(L)" },
+{ 460,			"R54(U)" },
+{ 464,			"R55(L)" },
+{ 468,			"R55(U)" },
+{ 472,			"R56(L)" },
+{ 476,			"R56(U)" },
+{ 480,			"R57(L)" },
+{ 484,			"R57(U)" },
+{ 488,			"R58(L)" },
+{ 492,			"R58(U)" },
+{ 496,			"R59(L)" },
+{ 500,			"R59(U)" },
+{ 504,			"R60(L)" },
+{ 508,			"R60(U)" },
+{ 512,			"R61(L)" },
+{ 516,			"R61(U)" },
+{ 520,			"R62(L)" },
+{ 524,			"R62(U)" },
+{ 528,			"TR0(L)" },
+{ 532,			"TR0(U)" },
+{ 536,			"TR1(L)" },
+{ 540,			"TR1(U)" },
+{ 544,			"TR2(L)" },
+{ 548,			"TR2(U)" },
+{ 552,			"TR3(L)" },
+{ 556,			"TR3(U)" },
+{ 560,			"TR4(L)" },
+{ 564,			"TR4(U)" },
+{ 568,			"TR5(L)" },
+{ 572,			"TR5(U)" },
+{ 576,			"TR6(L)" },
+{ 580,			"TR6(U)" },
+{ 584,			"TR7(L)" },
+{ 588,			"TR7(U)" },
+/* Other fields in "struct user" */
+/* This entry is in case pt_regs contains dregs (depends on
+the kernel build options). */
+XLAT_UOFF(regs),
+XLAT_UOFF(fpu),
+#include "../sh/userent0.h"
diff --git a/strace/linux/signalent.h b/strace/linux/signalent.h
new file mode 100644
index 0000000..112f746
--- /dev/null
+++ b/strace/linux/signalent.h
@@ -0,0 +1,33 @@
+	"SIG_0",	/* 0 */
+	"SIGHUP",	/* 1 */
+	"SIGINT",	/* 2 */
+	"SIGQUIT",	/* 3 */
+	"SIGILL",	/* 4 */
+	"SIGTRAP",	/* 5 */
+	"SIGABRT",	/* 6 */
+	"SIGBUS",	/* 7 */
+	"SIGFPE",	/* 8 */
+	"SIGKILL",	/* 9 */
+	"SIGUSR1",	/* 10 */
+	"SIGSEGV",	/* 11 */
+	"SIGUSR2",	/* 12 */
+	"SIGPIPE",	/* 13 */
+	"SIGALRM",	/* 14 */
+	"SIGTERM",	/* 15 */
+	"SIGSTKFLT",	/* 16 */
+	"SIGCHLD",	/* 17 */
+	"SIGCONT",	/* 18 */
+	"SIGSTOP",	/* 19 */
+	"SIGTSTP",	/* 20 */
+	"SIGTTIN",	/* 21 */
+	"SIGTTOU",	/* 22 */
+	"SIGURG",	/* 23 */
+	"SIGXCPU",	/* 24 */
+	"SIGXFSZ",	/* 25 */
+	"SIGVTALRM",	/* 26 */
+	"SIGPROF",	/* 27 */
+	"SIGWINCH",	/* 28 */
+	"SIGIO",	/* 29 */
+	"SIGPWR",	/* 30 */
+	"SIGSYS",	/* 31 */
+	"SIGRTMIN",	/* 32 */
diff --git a/strace/linux/sock_diag.h b/strace/linux/sock_diag.h
new file mode 100644
index 0000000..e5dd066
--- /dev/null
+++ b/strace/linux/sock_diag.h
@@ -0,0 +1,6 @@
+#define SOCK_DIAG_BY_FAMILY 20
+
+struct sock_diag_req {
+	uint8_t	sdiag_family;
+	uint8_t	sdiag_protocol;
+};
diff --git a/strace/linux/sparc/arch_getrval2.c b/strace/linux/sparc/arch_getrval2.c
new file mode 100644
index 0000000..9079482
--- /dev/null
+++ b/strace/linux/sparc/arch_getrval2.c
@@ -0,0 +1,5 @@
+long
+getrval2(struct tcb *tcp)
+{
+	return sparc_regs.u_regs[U_REG_O1];
+}
diff --git a/strace/linux/sparc/arch_regs.c b/strace/linux/sparc/arch_regs.c
new file mode 100644
index 0000000..c0f22e6
--- /dev/null
+++ b/strace/linux/sparc/arch_regs.c
@@ -0,0 +1,3 @@
+struct pt_regs sparc_regs; /* not static */
+#define ARCH_REGS_FOR_GETREGS sparc_regs
+#define ARCH_PC_REG sparc_regs.pc
diff --git a/strace/linux/sparc/arch_regs.h b/strace/linux/sparc/arch_regs.h
new file mode 100644
index 0000000..ac11a1d
--- /dev/null
+++ b/strace/linux/sparc/arch_regs.h
@@ -0,0 +1,7 @@
+extern struct pt_regs sparc_regs;
+/* Indexes into the pt_regs.u_reg[] array -- UREG_XX from kernel are all off
+ * by 1 and use Ix instead of Ox.  These work for both 32 and 64 bit Linux. */
+#define U_REG_G1 0
+#define U_REG_O0 7
+#define U_REG_O1 8
+#define U_REG_FP 13
diff --git a/strace/linux/sparc/arch_sigreturn.c b/strace/linux/sparc/arch_sigreturn.c
new file mode 100644
index 0000000..9e86efa
--- /dev/null
+++ b/strace/linux/sparc/arch_sigreturn.c
@@ -0,0 +1,23 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	long fp = sparc_regs.u_regs[U_REG_FP] + sizeof(struct sparc_stackf);
+	struct {
+		struct pt_regs si_regs;
+		int si_mask;
+		void *fpu_save;
+		long insns[2] ATTRIBUTE_ALIGNED(8);
+		unsigned int extramask[NSIG / 8 / sizeof(int) - 1];
+	} frame;
+
+	if (umove(tcp, fp, &frame) < 0) {
+		tprintf("{mask=%#lx}", fp);
+	} else {
+		unsigned int mask[NSIG / 8 / sizeof(int)];
+
+		mask[0] = frame.si_mask;
+		memcpy(mask + 1, frame.extramask, sizeof(frame.extramask));
+		tprintsigmask_addr("{mask=", mask);
+		tprints("}");
+	}
+}
diff --git a/strace/linux/sparc/errnoent.h b/strace/linux/sparc/errnoent.h
new file mode 100644
index 0000000..fe5ff07
--- /dev/null
+++ b/strace/linux/sparc/errnoent.h
@@ -0,0 +1,151 @@
+[  1] = "EPERM",
+[  2] = "ENOENT",
+[  3] = "ESRCH",
+[  4] = "EINTR",
+[  5] = "EIO",
+[  6] = "ENXIO",
+[  7] = "E2BIG",
+[  8] = "ENOEXEC",
+[  9] = "EBADF",
+[ 10] = "ECHILD",
+[ 11] = "EAGAIN",
+[ 12] = "ENOMEM",
+[ 13] = "EACCES",
+[ 14] = "EFAULT",
+[ 15] = "ENOTBLK",
+[ 16] = "EBUSY",
+[ 17] = "EEXIST",
+[ 18] = "EXDEV",
+[ 19] = "ENODEV",
+[ 20] = "ENOTDIR",
+[ 21] = "EISDIR",
+[ 22] = "EINVAL",
+[ 23] = "ENFILE",
+[ 24] = "EMFILE",
+[ 25] = "ENOTTY",
+[ 26] = "ETXTBSY",
+[ 27] = "EFBIG",
+[ 28] = "ENOSPC",
+[ 29] = "ESPIPE",
+[ 30] = "EROFS",
+[ 31] = "EMLINK",
+[ 32] = "EPIPE",
+[ 33] = "EDOM",
+[ 34] = "ERANGE",
+[ 35] = "EWOULDBLOCK",
+[ 36] = "EINPROGRESS",
+[ 37] = "EALREADY",
+[ 38] = "ENOTSOCK",
+[ 39] = "EDESTADDRREQ",
+[ 40] = "EMSGSIZE",
+[ 41] = "EPROTOTYPE",
+[ 42] = "ENOPROTOOPT",
+[ 43] = "EPROTONOSUPPORT",
+[ 44] = "ESOCKTNOSUPPORT",
+[ 45] = "EOPNOTSUPP",
+[ 46] = "EPFNOSUPPORT",
+[ 47] = "EAFNOSUPPORT",
+[ 48] = "EADDRINUSE",
+[ 49] = "EADDRNOTAVAIL",
+[ 50] = "ENETDOWN",
+[ 51] = "ENETUNREACH",
+[ 52] = "ENETRESET",
+[ 53] = "ECONNABORTED",
+[ 54] = "ECONNRESET",
+[ 55] = "ENOBUFS",
+[ 56] = "EISCONN",
+[ 57] = "ENOTCONN",
+[ 58] = "ESHUTDOWN",
+[ 59] = "ETOOMANYREFS",
+[ 60] = "ETIMEDOUT",
+[ 61] = "ECONNREFUSED",
+[ 62] = "ELOOP",
+[ 63] = "ENAMETOOLONG",
+[ 64] = "EHOSTDOWN",
+[ 65] = "EHOSTUNREACH",
+[ 66] = "ENOTEMPTY",
+[ 67] = "EPROCLIM",
+[ 68] = "EUSERS",
+[ 69] = "EDQUOT",
+[ 70] = "ESTALE",
+[ 71] = "EREMOTE",
+[ 72] = "ENOSTR",
+[ 73] = "ETIME",
+[ 74] = "ENOSR",
+[ 75] = "ENOMSG",
+[ 76] = "EBADMSG",
+[ 77] = "EIDRM",
+[ 78] = "EDEADLK",
+[ 79] = "ENOLCK",
+[ 80] = "ENONET",
+[ 81] = "ERREMOTE",
+[ 82] = "ENOLINK",
+[ 83] = "EADV",
+[ 84] = "ESRMNT",
+[ 85] = "ECOMM",
+[ 86] = "EPROTO",
+[ 87] = "EMULTIHOP",
+[ 88] = "EDOTDOT",
+[ 89] = "EREMCHG",
+[ 90] = "ENOSYS",
+[ 91] = "ESTRPIPE",
+[ 92] = "EOVERFLOW",
+[ 93] = "EBADFD",
+[ 94] = "ECHRNG",
+[ 95] = "EL2NSYNC",
+[ 96] = "EL3HLT",
+[ 97] = "EL3RST",
+[ 98] = "ELNRNG",
+[ 99] = "EUNATCH",
+[100] = "ENOCSI",
+[101] = "EL2HLT",
+[102] = "EBADE",
+[103] = "EBADR",
+[104] = "EXFULL",
+[105] = "ENOANO",
+[106] = "EBADRQC",
+[107] = "EBADSLT",
+[108] = "EDEADLOCK",
+[109] = "EBFONT",
+[110] = "ELIBEXEC",
+[111] = "ENODATA",
+[112] = "ELIBBAD",
+[113] = "ENOPKG",
+[114] = "ELIBACC",
+[115] = "ENOTUNIQ",
+[116] = "ERESTART",
+[117] = "EUCLEAN",
+[118] = "ENOTNAM",
+[119] = "ENAVAIL",
+[120] = "EISNAM",
+[121] = "EREMOTEIO",
+[122] = "EILSEQ",
+[123] = "ELIBMAX",
+[124] = "ELIBSCN",
+[125] = "ENOMEDIUM",
+[126] = "EMEDIUMTYPE",
+[127] = "ECANCELED",
+[128] = "ENOKEY",
+[129] = "EKEYEXPIRED",
+[130] = "EKEYREVOKED",
+[131] = "EKEYREJECTED",
+[132] = "EOWNERDEAD",
+[133] = "ENOTRECOVERABLE",
+[134] = "ERFKILL",
+[135] = "EHWPOISON",
+[512] = "ERESTARTSYS",
+[513] = "ERESTARTNOINTR",
+[514] = "ERESTARTNOHAND",
+[515] = "ENOIOCTLCMD",
+[516] = "ERESTART_RESTARTBLOCK",
+[517] = "EPROBE_DEFER",
+[518] = "EOPENSTALE",
+[521] = "EBADHANDLE",
+[522] = "ENOTSYNC",
+[523] = "EBADCOOKIE",
+[524] = "ENOTSUPP",
+[525] = "ETOOSMALL",
+[526] = "ESERVERFAULT",
+[527] = "EBADTYPE",
+[528] = "EJUKEBOX",
+[529] = "EIOCBQUEUED",
diff --git a/strace/linux/sparc/gen.pl b/strace/linux/sparc/gen.pl
new file mode 100644
index 0000000..8c2f75b
--- /dev/null
+++ b/strace/linux/sparc/gen.pl
@@ -0,0 +1,37 @@
+open SPARC, "syscallent.h" || die "no puedo abrir el de la sparc";
+open ALPHA, "../alpha/syscallent.h" || die "no puedo abrir el de la alpha";
+open PC, "../i386/syscallent.h" || die "no puedo abrir PC\n";
+
+while (<SPARC>) {
+    chop;
+    ($i1, $i2, $i3, $syscall, $syscall_name) = split;
+    $strn[$index]   = $syscall_name;
+    $name[$index++] = $syscall;
+}
+
+while (<ALPHA>){
+    if (/\{/) {
+	($i1, $n, $pr, $syscall) = split;
+	$par{$syscall} = $n;
+	$prr{$syscall} = $pr;
+    }
+}
+
+while (<PC>){
+    if (/\{/) {
+	($i1, $n, $pr, $syscall) = split;
+	$par{$syscall} = $n;
+	$prr{$syscall} = $pr;
+    }
+}
+
+print "missing \n";
+
+for ($i = 0; $i < $index; $i++){
+    $x = $name[$i];
+    $y = $strn[$i];
+    $n = $par{$x};
+    $p = $prr{$x};
+    $j++;
+    print "\t{ $n\t$p\t$x\t$y },\t /* $j */\n";
+}
diff --git a/strace/linux/sparc/get_error.c b/strace/linux/sparc/get_error.c
new file mode 100644
index 0000000..1b960ac
--- /dev/null
+++ b/strace/linux/sparc/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (sparc_regs.psr & PSR_C) {
+		tcp->u_rval = -1;
+		tcp->u_error = sparc_regs.u_regs[U_REG_O0];
+	} else {
+		tcp->u_rval = sparc_regs.u_regs[U_REG_O0];
+	}
+}
diff --git a/strace/linux/sparc/get_scno.c b/strace/linux/sparc/get_scno.c
new file mode 100644
index 0000000..f041259
--- /dev/null
+++ b/strace/linux/sparc/get_scno.c
@@ -0,0 +1,7 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	tcp->scno = sparc_regs.u_regs[U_REG_G1];
+	return 1;
+}
diff --git a/strace/linux/sparc/get_syscall_args.c b/strace/linux/sparc/get_syscall_args.c
new file mode 100644
index 0000000..57b5488
--- /dev/null
+++ b/strace/linux/sparc/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = sparc_regs.u_regs[U_REG_O0 + 0];
+	tcp->u_arg[1] = sparc_regs.u_regs[U_REG_O0 + 1];
+	tcp->u_arg[2] = sparc_regs.u_regs[U_REG_O0 + 2];
+	tcp->u_arg[3] = sparc_regs.u_regs[U_REG_O0 + 3];
+	tcp->u_arg[4] = sparc_regs.u_regs[U_REG_O0 + 4];
+	tcp->u_arg[5] = sparc_regs.u_regs[U_REG_O0 + 5];
+	return 1;
+}
diff --git a/strace/linux/sparc/ioctls_arch0.h b/strace/linux/sparc/ioctls_arch0.h
new file mode 100644
index 0000000..07dccdd
--- /dev/null
+++ b/strace/linux/sparc/ioctls_arch0.h
@@ -0,0 +1,129 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/sparc/include/ tree. */
+{ "asm/apc.h", "APCIOCGBPORT", _IOC_READ, 0x4104, 0x04 },
+{ "asm/apc.h", "APCIOCGCPWR", _IOC_READ, 0x4102, 0x04 },
+{ "asm/apc.h", "APCIOCGFANCTL", _IOC_READ, 0x4100, 0x04 },
+{ "asm/apc.h", "APCIOCSBPORT", _IOC_WRITE, 0x4105, 0x04 },
+{ "asm/apc.h", "APCIOCSCPWR", _IOC_WRITE, 0x4103, 0x04 },
+{ "asm/apc.h", "APCIOCSFANCTL", _IOC_WRITE, 0x4101, 0x04 },
+{ "asm/display7seg.h", "D7SIOCRD", _IOC_READ, 0x7045, 0x04 },
+{ "asm/display7seg.h", "D7SIOCTM", _IOC_NONE, 0x7047, 0x00 },
+{ "asm/display7seg.h", "D7SIOCWR", _IOC_WRITE, 0x7046, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_CPU_TEMPERATURE", _IOC_READ, 0x7040, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_CPU_VOLTAGE", _IOC_READ, 0x7041, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_ETHERNET_TEMPERATURE", _IOC_READ, 0x7047, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_FAN_STATUS", _IOC_READ, 0x7042, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_GLOBALADDRESS", _IOC_READ, 0x7049, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_MTHRBD_TEMPERATURE", _IOC_READ, 0x7048, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_SCSI_TEMPERATURE", _IOC_READ, 0x7046, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_SHUTDOWN_TEMPERATURE", _IOC_READ, 0x7044, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_VOLTAGE_STATUS", _IOC_READ, 0x7045, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_WARNING_TEMPERATURE", _IOC_READ, 0x7043, 0x04 },
+{ "asm/fbio.h", "FBIOGATTR", _IOC_READ, 0x4606, 0x58 },
+{ "asm/fbio.h", "FBIOGCURMAX", _IOC_READ, 0x461c, 0x04 },
+{ "asm/fbio.h", "FBIOGCURPOS", _IOC_WRITE, 0x461b, 0x04 },
+{ "asm/fbio.h", "FBIOGCURSOR", _IOC_READ|_IOC_WRITE, 0x4619, 0x2c },
+{ "asm/fbio.h", "FBIOGETCMAP", _IOC_WRITE, 0x4604, 0x14 },
+{ "asm/fbio.h", "FBIOGTYPE", _IOC_READ, 0x4600, 0x18 },
+{ "asm/fbio.h", "FBIOGVIDEO", _IOC_READ, 0x4608, 0x04 },
+{ "asm/fbio.h", "FBIOPUTCMAP", _IOC_WRITE, 0x4603, 0x14 },
+{ "asm/fbio.h", "FBIOSATTR", _IOC_WRITE, 0x4605, 0x58 },
+{ "asm/fbio.h", "FBIOSCURPOS", _IOC_WRITE, 0x461a, 0x04 },
+{ "asm/fbio.h", "FBIOSCURSOR", _IOC_WRITE, 0x4618, 0x2c },
+{ "asm/fbio.h", "FBIOSVIDEO", _IOC_WRITE, 0x4607, 0x04 },
+{ "asm/fbio.h", "FBIO_WID_ALLOC", _IOC_READ|_IOC_WRITE, 0x461e, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_FREE", _IOC_WRITE, 0x461f, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_GET", _IOC_READ|_IOC_WRITE, 0x4621, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_PUT", _IOC_WRITE, 0x4620, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTALLOC", _IOC_READ|_IOC_WRITE, 0x4c35, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTFREE", _IOC_WRITE, 0x4c36, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTPOST", _IOC_WRITE, 0x4c38, 0x1c },
+{ "asm/fbio.h", "LEO_CLUTREAD", _IOC_WRITE, 0x4c37, 0x1c },
+{ "asm/fbio.h", "LEO_GETGAMMA", _IOC_READ, 0x4c45, 0x04 },
+{ "asm/fbio.h", "LEO_SETGAMMA", _IOC_WRITE, 0x4c44, 0x04 },
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x5407, 0x00 },
+{ "asm/ioctls.h", "TCGETA", _IOC_READ, 0x5401, 0x12 },
+{ "asm/ioctls.h", "TCGETS", _IOC_READ, 0x5408, 0x24 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x540c, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x5405, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm/ioctls.h", "TCSETA", _IOC_WRITE, 0x5402, 0x12 },
+{ "asm/ioctls.h", "TCSETAF", _IOC_WRITE, 0x5404, 0x12 },
+{ "asm/ioctls.h", "TCSETAW", _IOC_WRITE, 0x5403, 0x12 },
+{ "asm/ioctls.h", "TCSETS", _IOC_WRITE, 0x5409, 0x24 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x540d, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", _IOC_WRITE, 0x540b, 0x24 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x540f, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", _IOC_WRITE, 0x540a, 0x24 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x540e, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x5406, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", _IOC_NONE, 0x747a, 0x00 },
+{ "asm/ioctls.h", "TIOCCONS", _IOC_NONE, 0x7424, 0x00 },
+{ "asm/ioctls.h", "TIOCEXCL", _IOC_NONE, 0x740d, 0x00 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", _IOC_READ, 0x7400, 0x04 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7483, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x7486, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x5441, 0x20 },
+{ "asm/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm/ioctls.h", "TIOCGSID", _IOC_READ, 0x7485, 0x04 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", _IOC_READ, 0x7464, 0x04 },
+{ "asm/ioctls.h", "TIOCGWINSZ", _IOC_READ, 0x7468, 0x08 },
+{ "asm/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm/ioctls.h", "TIOCMBIC", _IOC_WRITE, 0x746b, 0x04 },
+{ "asm/ioctls.h", "TIOCMBIS", _IOC_WRITE, 0x746c, 0x04 },
+{ "asm/ioctls.h", "TIOCMGET", _IOC_READ, 0x746a, 0x04 },
+{ "asm/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm/ioctls.h", "TIOCMSET", _IOC_WRITE, 0x746d, 0x04 },
+{ "asm/ioctls.h", "TIOCNOTTY", _IOC_NONE, 0x7471, 0x00 },
+{ "asm/ioctls.h", "TIOCNXCL", _IOC_NONE, 0x740e, 0x00 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", _IOC_WRITE, 0x7470, 0x04 },
+{ "asm/ioctls.h", "TIOCSBRK", _IOC_NONE, 0x747b, 0x00 },
+{ "asm/ioctls.h", "TIOCSCTTY", _IOC_NONE, 0x7484, 0x00 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm/ioctls.h", "TIOCSETD", _IOC_WRITE, 0x7401, 0x04 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x7488, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7482, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x7487, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x5442, 0x20 },
+{ "asm/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", _IOC_WRITE, 0x7465, 0x04 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", _IOC_WRITE, 0x7472, 0x01 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCSWINSZ", _IOC_WRITE, 0x7467, 0x08 },
+{ "asm/ioctls.h", "TIOCVHANGUP", _IOC_NONE, 0x5437, 0x00 },
+{ "asm/openpromio.h", "OPIOCGET", _IOC_READ|_IOC_WRITE, 0x4f01, 0x14 },
+{ "asm/openpromio.h", "OPIOCGETCHILD", _IOC_READ|_IOC_WRITE, 0x4f06, 0x04 },
+{ "asm/openpromio.h", "OPIOCGETNEXT", _IOC_READ|_IOC_WRITE, 0x4f05, 0x04 },
+{ "asm/openpromio.h", "OPIOCGETOPTNODE", _IOC_READ, 0x4f04, 0x04 },
+{ "asm/openpromio.h", "OPIOCNEXTPROP", _IOC_READ|_IOC_WRITE, 0x4f03, 0x14 },
+{ "asm/openpromio.h", "OPIOCSET", _IOC_WRITE, 0x4f02, 0x14 },
+{ "asm/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
+{ "asm/watchdog.h", "WIOCGSTAT", _IOC_READ, 0x570c, 0x04 },
+{ "asm/watchdog.h", "WIOCSTART", _IOC_NONE, 0x570a, 0x00 },
+{ "asm/watchdog.h", "WIOCSTOP", _IOC_NONE, 0x570b, 0x00 },
diff --git a/strace/linux/sparc/ioctls_inc0.h b/strace/linux/sparc/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/sparc/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/sparc/signalent.h b/strace/linux/sparc/signalent.h
new file mode 100644
index 0000000..83ca9ca
--- /dev/null
+++ b/strace/linux/sparc/signalent.h
@@ -0,0 +1,33 @@
+	"SIG_0",	/* 0 */
+	"SIGHUP",	/* 1 */
+	"SIGINT",	/* 2 */
+	"SIGQUIT",	/* 3 */
+	"SIGILL",	/* 4 */
+	"SIGTRAP",	/* 5 */
+	"SIGABRT",	/* 6 */
+	"SIGEMT",	/* 7 */
+	"SIGFPE",	/* 8 */
+	"SIGKILL",	/* 9 */
+	"SIGBUS",	/* 10 */
+	"SIGSEGV",	/* 11 */
+	"SIGSYS",	/* 12 */
+	"SIGPIPE",	/* 13 */
+	"SIGALRM",	/* 14 */
+	"SIGTERM",	/* 15 */
+	"SIGURG",	/* 16 */
+	"SIGSTOP",	/* 17 */
+	"SIGTSTP",	/* 18 */
+	"SIGCONT",	/* 19 */
+	"SIGCHLD",	/* 20 */
+	"SIGTTIN",	/* 21 */
+	"SIGTTOU",	/* 22 */
+	"SIGIO",	/* 23 */
+	"SIGXCPU",	/* 24 */
+	"SIGXFSZ",	/* 25 */
+	"SIGVTALRM",	/* 26 */
+	"SIGPROF",	/* 27 */
+	"SIGWINCH",	/* 28 */
+	"SIGLOST",	/* 29 */
+	"SIGUSR1",	/* 30 */
+	"SIGUSR2",	/* 31 */
+	"SIGRTMIN",	/* 32 */
diff --git a/strace/linux/sparc/syscallent.h b/strace/linux/sparc/syscallent.h
new file mode 100644
index 0000000..ec86f7e
--- /dev/null
+++ b/strace/linux/sparc/syscallent.h
@@ -0,0 +1,363 @@
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 2,	TF|TP|SE|SI,	SEN(execv),			"execv"			},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 3,	TF,		SEN(chown16),			"chown"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 18] = { 4,	0,		SEN(printargs),			"perfctr"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 2,	0,		SEN(capget),			"capget"		},
+[ 22] = { 2,	0,		SEN(capset),			"capset"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31] = { 3,	TF,		SEN(chown),			"lchown32"		},
+[ 32] = { 3,	TD,		SEN(fchown),			"fchown32"		},
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { 3,	TF,		SEN(chown),			"chown32"		},
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(stat),			"stat"			},
+[ 39] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[ 40] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { 0,	NF,		SEN(getuid),			"getuid32"		},
+[ 45] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { },
+[ 53] = { 0,	NF,		SEN(getgid),			"getgid32"		},
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 56] = { 6,	TD|TM|SI,	SEN(mmap_4koff),		"mmap2"			},
+[ 57] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 58] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 59] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 63] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[ 64] = { 0,	0,		SEN(getpagesize),		"getpagesize"		},
+[ 65] = { 3,	TM,		SEN(msync),			"msync"			},
+[ 66] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[ 67] = { 5,	TD,		SEN(pread),			"pread64"		},
+[ 68] = { 5,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 69] = { 0,	NF,		SEN(geteuid),			"geteuid32"		},
+[ 70] = { 0,	NF,		SEN(getegid),			"getegid32"		},
+[ 71] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 72] = { 2,	0,		SEN(setreuid),			"setreuid32"		},
+[ 73] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 74] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[ 75] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[ 76] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[ 77] = { 3,	TF,		SEN(truncate64),		"truncate64"		},
+[ 78] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[ 79] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 80] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 81] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 82] = { 2,	0,		SEN(setgroups),			"setgroups32"		},
+[ 83] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[ 84] = { 3,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[ 85] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 86] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[ 87] = { 1,	0,		SEN(setuid),			"setuid32"		},
+[ 88] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 89] = { 1,	0,		SEN(setgid),			"setgid32"		},
+[ 90] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 91] = { 1,	NF,		SEN(setfsuid),			"setfsuid32"		},
+[ 92] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 93] = { 5,	TD,		SEN(select),			"select"		},
+[ 94] = { 1,	NF,		SEN(setfsgid),			"setfsgid32"		},
+[ 95] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 96] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 97] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 98] = { 3,	TN,		SEN(connect),			"connect"		},
+[ 99] = { 3,	TN,		SEN(accept),			"accept"		},
+[100] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[101] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[102] = { 5,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[103] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[104] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[105] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[106] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[107] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[108] = { 3,	0,		SEN(setresuid),			"setresuid32"		},
+[109] = { 3,	0,		SEN(getresuid),			"getresuid32"		},
+[110] = { 3,	0,		SEN(setresgid),			"setresgid32"		},
+[111] = { 3,	0,		SEN(getresgid),			"getresgid32"		},
+[112] = { 2,	0,		SEN(setregid),			"setregid32"		},
+[113] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[114] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[115] = { 2,	0,		SEN(getgroups),			"getgroups32"		},
+[116] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[117] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[118] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[119] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[120] = { 3,	TD,		SEN(readv),			"readv"			},
+[121] = { 3,	TD,		SEN(writev),			"writev"		},
+[122] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[123] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[124] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[125] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[126] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[127] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[128] = { 2,	TF,		SEN(rename),			"rename"		},
+[129] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[130] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[131] = { 2,	TD,		SEN(flock),			"flock"			},
+[132] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[133] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[134] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[135] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[136] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[137] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[138] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[139] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[140] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[141] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[142] = { 6,	0,		SEN(futex),			"futex"			},
+[143] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[144] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[145] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[146] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[147] = { 5,	0,		SEN(prctl),			"prctl"			},
+[148] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[149] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[150] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[151] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[152] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[153] = { 3,	TD,		SEN(poll),			"poll"			},
+[154] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[155] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[156] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[157] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[158] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[159] = { 1,	TF,		SEN(umount),			"umount"		},
+[160] = { 3,	0,		SEN(sched_setaffinity),		"sched_set_affinity"	},
+[161] = { 3,	0,		SEN(sched_getaffinity),		"sched_get_affinity"	},
+[162] = { 2,	0,		SEN(printargs),			"getdomainname"		},
+[163] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[164] = { },
+[165] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[166] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[167] = { 5,	TF,		SEN(mount),			"mount"			},
+[168] = { 2,	0,		SEN(ustat),			"ustat"			},
+[169] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[170] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[171] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[172] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[173] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[174] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[175] = { 0,	0,		SEN(setsid),			"setsid"		},
+[176] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[177] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[178] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[179] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[180] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[181] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[182] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[183] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[184] = { 5,	0,		SEN(query_module),		"query_module"		},
+[185] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[186] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[187] = { 2,	TS,		SEN(kill),			"tkill"			},
+[188] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[189] = { 1,	0,		SEN(uname),			"uname"			},
+[190] = { 3,	0,		SEN(init_module),		"init_module"		},
+[191] = { 1,	NF,		SEN(personality),		"personality"		},
+[192] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[193] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[194] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[195] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[196] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[197] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[198] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[199] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[200] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[201] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[202] = { 2,	TF,		SEN(lstat),			"oldlstat"		},
+[203] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[204] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[205] = { 4,	TD,		SEN(readahead),			"readahead"		},
+[206] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[207] = { 3,	0,		SEN(syslog),			"syslog"		},
+[208] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[209] = { 5,	TD,		SEN(fadvise64),			"fadvise64"		},
+[210] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[211] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[212] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[213] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[214] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[215] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[216] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[217] = { 5,	TP,		SEN(clone),			"clone"			},
+[218] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[219] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[220] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[221] = { 2,	0,		SEN(create_module),		"create_module"		},
+[222] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[223] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[224] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[225] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[226] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[227] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[228] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[229] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[230] = { 5,	TD,		SEN(select),			"_newselect"		},
+[231] = { 1,	0,		SEN(time),			"time"			},
+[232] = { 6,	TD,		SEN(splice),			"splice"		},
+[233] = { 1,	0,		SEN(stime),			"stime"			},
+[234] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[235] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[236] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[237] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[238] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[239] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[240] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[241] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[242] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[243] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[244] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[245] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[246] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[247] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[248] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[249] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[250] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[251] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[252] = { 1,	0,		SEN(getsid),			"getsid"		},
+[253] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[254] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[255] = { 6,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[256] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[257] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[258] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[259] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[260] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[261] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[262] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[263] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[264] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[265] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[266] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[267] = { },
+[268] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[269] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[270] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[271] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[272] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[273] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[274] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[275] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[276] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[277] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[278] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[279] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[280] = { 4,	TD,		SEN(tee),			"tee"			},
+[281] = { 5,	0,		SEN(add_key),			"add_key"		},
+[282] = { 4,	0,		SEN(request_key),		"request_key"		},
+[283] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[284] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[285] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[286] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[287] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[288] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[289] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[290] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[291] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[292] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[293] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[294] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[295] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[296] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[297] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[298] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[299] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[300] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[301] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[302] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[303] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[304] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[305] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[306] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[307] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[308] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[309] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[310] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[311] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[312] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[313] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[314] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[315] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[316] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[317] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[318] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[319] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[320] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[321] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[322] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[323] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[324] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[325] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[326] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[327] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[328] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[329] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[330] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[331] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[332] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[333] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[334] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[335] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[336] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[337] = { 2,	TD,		SEN(setns),			"setns"			},
+[338] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[339] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[340] = { 0,	NF,		SEN(printargs),			"kern_features"		},
+[341] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[342] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[343] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[344] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[345] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[346] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[347] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[348] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[349] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[350] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[351] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[352] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[353] = { 3,	TN,		SEN(bind),			"bind"			},
+[354] = { 2,	TN,		SEN(listen),			"listen"		},
+[355] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[356] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[357] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[358] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[359] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/sparc/userent.h b/strace/linux/sparc/userent.h
new file mode 100644
index 0000000..f842946
--- /dev/null
+++ b/strace/linux/sparc/userent.h
@@ -0,0 +1 @@
+#include "../userent0.h"
diff --git a/strace/linux/sparc64/arch_getrval2.c b/strace/linux/sparc64/arch_getrval2.c
new file mode 100644
index 0000000..81f1556
--- /dev/null
+++ b/strace/linux/sparc64/arch_getrval2.c
@@ -0,0 +1 @@
+#include "sparc/arch_getrval2.c"
diff --git a/strace/linux/sparc64/arch_regs.c b/strace/linux/sparc64/arch_regs.c
new file mode 100644
index 0000000..072a355
--- /dev/null
+++ b/strace/linux/sparc64/arch_regs.c
@@ -0,0 +1,2 @@
+#include "sparc/arch_regs.c"
+#define ARCH_PC_REG sparc_regs.tpc
diff --git a/strace/linux/sparc64/arch_regs.h b/strace/linux/sparc64/arch_regs.h
new file mode 100644
index 0000000..a49ad53
--- /dev/null
+++ b/strace/linux/sparc64/arch_regs.h
@@ -0,0 +1 @@
+#include "sparc/arch_regs.h"
diff --git a/strace/linux/sparc64/arch_sigreturn.c b/strace/linux/sparc64/arch_sigreturn.c
new file mode 100644
index 0000000..aeec981
--- /dev/null
+++ b/strace/linux/sparc64/arch_sigreturn.c
@@ -0,0 +1 @@
+#include "sparc/arch_sigreturn.c"
diff --git a/strace/linux/sparc64/errnoent.h b/strace/linux/sparc64/errnoent.h
new file mode 100644
index 0000000..4ac2b73
--- /dev/null
+++ b/strace/linux/sparc64/errnoent.h
@@ -0,0 +1 @@
+#include "sparc/errnoent.h"
diff --git a/strace/linux/sparc64/errnoent1.h b/strace/linux/sparc64/errnoent1.h
new file mode 100644
index 0000000..c0f7787
--- /dev/null
+++ b/strace/linux/sparc64/errnoent1.h
@@ -0,0 +1 @@
+#include "errnoent.h"
diff --git a/strace/linux/sparc64/get_error.c b/strace/linux/sparc64/get_error.c
new file mode 100644
index 0000000..8f8978b
--- /dev/null
+++ b/strace/linux/sparc64/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (sparc_regs.tstate & 0x1100000000UL) {
+		tcp->u_rval = -1;
+		tcp->u_error = sparc_regs.u_regs[U_REG_O0];
+	} else {
+		tcp->u_rval = sparc_regs.u_regs[U_REG_O0];
+	}
+}
diff --git a/strace/linux/sparc64/get_scno.c b/strace/linux/sparc64/get_scno.c
new file mode 100644
index 0000000..68d5917
--- /dev/null
+++ b/strace/linux/sparc64/get_scno.c
@@ -0,0 +1,25 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	/* Retrieve the syscall trap instruction. */
+	unsigned long trap;
+	errno = 0;
+	trap = ptrace(PTRACE_PEEKTEXT, tcp->pid, (void *) sparc_regs.tpc, 0);
+	if (errno)
+		return -1;
+	trap >>= 32;
+	switch (trap) {
+	case 0x91d02010:
+		/* Linux/SPARC syscall trap. */
+		update_personality(tcp, 0);
+		break;
+	case 0x91d0206d:
+		/* Linux/SPARC64 syscall trap. */
+		update_personality(tcp, 1);
+		break;
+	}
+
+	tcp->scno = sparc_regs.u_regs[U_REG_G1];
+	return 1;
+}
diff --git a/strace/linux/sparc64/get_syscall_args.c b/strace/linux/sparc64/get_syscall_args.c
new file mode 100644
index 0000000..821c331
--- /dev/null
+++ b/strace/linux/sparc64/get_syscall_args.c
@@ -0,0 +1 @@
+#include "sparc/get_syscall_args.c"
diff --git a/strace/linux/sparc64/ioctls_arch0.h b/strace/linux/sparc64/ioctls_arch0.h
new file mode 100644
index 0000000..96bd895
--- /dev/null
+++ b/strace/linux/sparc64/ioctls_arch0.h
@@ -0,0 +1 @@
+#include "sparc/ioctls_arch0.h"
diff --git a/strace/linux/sparc64/ioctls_arch1.h b/strace/linux/sparc64/ioctls_arch1.h
new file mode 100644
index 0000000..6128dc9
--- /dev/null
+++ b/strace/linux/sparc64/ioctls_arch1.h
@@ -0,0 +1,129 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/sparc/include/ tree. */
+{ "asm/apc.h", "APCIOCGBPORT", _IOC_READ, 0x4104, 0x04 },
+{ "asm/apc.h", "APCIOCGCPWR", _IOC_READ, 0x4102, 0x04 },
+{ "asm/apc.h", "APCIOCGFANCTL", _IOC_READ, 0x4100, 0x04 },
+{ "asm/apc.h", "APCIOCSBPORT", _IOC_WRITE, 0x4105, 0x04 },
+{ "asm/apc.h", "APCIOCSCPWR", _IOC_WRITE, 0x4103, 0x04 },
+{ "asm/apc.h", "APCIOCSFANCTL", _IOC_WRITE, 0x4101, 0x04 },
+{ "asm/display7seg.h", "D7SIOCRD", _IOC_READ, 0x7045, 0x04 },
+{ "asm/display7seg.h", "D7SIOCTM", _IOC_NONE, 0x7047, 0x00 },
+{ "asm/display7seg.h", "D7SIOCWR", _IOC_WRITE, 0x7046, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_CPU_TEMPERATURE", _IOC_READ, 0x7040, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_CPU_VOLTAGE", _IOC_READ, 0x7041, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_ETHERNET_TEMPERATURE", _IOC_READ, 0x7047, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_FAN_STATUS", _IOC_READ, 0x7042, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_GLOBALADDRESS", _IOC_READ, 0x7049, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_MTHRBD_TEMPERATURE", _IOC_READ, 0x7048, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_SCSI_TEMPERATURE", _IOC_READ, 0x7046, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_SHUTDOWN_TEMPERATURE", _IOC_READ, 0x7044, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_VOLTAGE_STATUS", _IOC_READ, 0x7045, 0x04 },
+{ "asm/envctrl.h", "ENVCTRL_RD_WARNING_TEMPERATURE", _IOC_READ, 0x7043, 0x04 },
+{ "asm/fbio.h", "FBIOGATTR", _IOC_READ, 0x4606, 0x58 },
+{ "asm/fbio.h", "FBIOGCURMAX", _IOC_READ, 0x461c, 0x04 },
+{ "asm/fbio.h", "FBIOGCURPOS", _IOC_WRITE, 0x461b, 0x04 },
+{ "asm/fbio.h", "FBIOGCURSOR", _IOC_READ|_IOC_WRITE, 0x4619, 0x48 },
+{ "asm/fbio.h", "FBIOGETCMAP", _IOC_WRITE, 0x4604, 0x20 },
+{ "asm/fbio.h", "FBIOGTYPE", _IOC_READ, 0x4600, 0x18 },
+{ "asm/fbio.h", "FBIOGVIDEO", _IOC_READ, 0x4608, 0x04 },
+{ "asm/fbio.h", "FBIOPUTCMAP", _IOC_WRITE, 0x4603, 0x20 },
+{ "asm/fbio.h", "FBIOSATTR", _IOC_WRITE, 0x4605, 0x58 },
+{ "asm/fbio.h", "FBIOSCURPOS", _IOC_WRITE, 0x461a, 0x04 },
+{ "asm/fbio.h", "FBIOSCURSOR", _IOC_WRITE, 0x4618, 0x48 },
+{ "asm/fbio.h", "FBIOSVIDEO", _IOC_WRITE, 0x4607, 0x04 },
+{ "asm/fbio.h", "FBIO_WID_ALLOC", _IOC_READ|_IOC_WRITE, 0x461e, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_FREE", _IOC_WRITE, 0x461f, 0x0c },
+{ "asm/fbio.h", "FBIO_WID_GET", _IOC_READ|_IOC_WRITE, 0x4621, 0x10 },
+{ "asm/fbio.h", "FBIO_WID_PUT", _IOC_WRITE, 0x4620, 0x10 },
+{ "asm/fbio.h", "LEO_CLUTALLOC", _IOC_READ|_IOC_WRITE, 0x4c35, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTFREE", _IOC_WRITE, 0x4c36, 0x0c },
+{ "asm/fbio.h", "LEO_CLUTPOST", _IOC_WRITE, 0x4c38, 0x28 },
+{ "asm/fbio.h", "LEO_CLUTREAD", _IOC_WRITE, 0x4c37, 0x28 },
+{ "asm/fbio.h", "LEO_GETGAMMA", _IOC_READ, 0x4c45, 0x04 },
+{ "asm/fbio.h", "LEO_SETGAMMA", _IOC_WRITE, 0x4c44, 0x04 },
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x5407, 0x00 },
+{ "asm/ioctls.h", "TCGETA", _IOC_READ, 0x5401, 0x12 },
+{ "asm/ioctls.h", "TCGETS", _IOC_READ, 0x5408, 0x38 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x540c, 0x40 },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x5405, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm/ioctls.h", "TCSETA", _IOC_WRITE, 0x5402, 0x12 },
+{ "asm/ioctls.h", "TCSETAF", _IOC_WRITE, 0x5404, 0x12 },
+{ "asm/ioctls.h", "TCSETAW", _IOC_WRITE, 0x5403, 0x12 },
+{ "asm/ioctls.h", "TCSETS", _IOC_WRITE, 0x5409, 0x38 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x540d, 0x40 },
+{ "asm/ioctls.h", "TCSETSF", _IOC_WRITE, 0x540b, 0x38 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x540f, 0x40 },
+{ "asm/ioctls.h", "TCSETSW", _IOC_WRITE, 0x540a, 0x38 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x540e, 0x40 },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x5406, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", _IOC_NONE, 0x747a, 0x00 },
+{ "asm/ioctls.h", "TIOCCONS", _IOC_NONE, 0x7424, 0x00 },
+{ "asm/ioctls.h", "TIOCEXCL", _IOC_NONE, 0x740d, 0x00 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", _IOC_READ, 0x7400, 0x04 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7483, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x7486, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x5441, 0x20 },
+{ "asm/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm/ioctls.h", "TIOCGSID", _IOC_READ, 0x7485, 0x04 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", _IOC_READ, 0x7464, 0x04 },
+{ "asm/ioctls.h", "TIOCGWINSZ", _IOC_READ, 0x7468, 0x08 },
+{ "asm/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm/ioctls.h", "TIOCMBIC", _IOC_WRITE, 0x746b, 0x04 },
+{ "asm/ioctls.h", "TIOCMBIS", _IOC_WRITE, 0x746c, 0x04 },
+{ "asm/ioctls.h", "TIOCMGET", _IOC_READ, 0x746a, 0x04 },
+{ "asm/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm/ioctls.h", "TIOCMSET", _IOC_WRITE, 0x746d, 0x04 },
+{ "asm/ioctls.h", "TIOCNOTTY", _IOC_NONE, 0x7471, 0x00 },
+{ "asm/ioctls.h", "TIOCNXCL", _IOC_NONE, 0x740e, 0x00 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", _IOC_WRITE, 0x7470, 0x04 },
+{ "asm/ioctls.h", "TIOCSBRK", _IOC_NONE, 0x747b, 0x00 },
+{ "asm/ioctls.h", "TIOCSCTTY", _IOC_NONE, 0x7484, 0x00 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm/ioctls.h", "TIOCSETD", _IOC_WRITE, 0x7401, 0x04 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x7488, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7482, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x7487, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x5442, 0x20 },
+{ "asm/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", _IOC_WRITE, 0x7465, 0x04 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", _IOC_WRITE, 0x7472, 0x01 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCSWINSZ", _IOC_WRITE, 0x7467, 0x08 },
+{ "asm/ioctls.h", "TIOCVHANGUP", _IOC_NONE, 0x5437, 0x00 },
+{ "asm/openpromio.h", "OPIOCGET", _IOC_READ|_IOC_WRITE, 0x4f01, 0x20 },
+{ "asm/openpromio.h", "OPIOCGETCHILD", _IOC_READ|_IOC_WRITE, 0x4f06, 0x04 },
+{ "asm/openpromio.h", "OPIOCGETNEXT", _IOC_READ|_IOC_WRITE, 0x4f05, 0x04 },
+{ "asm/openpromio.h", "OPIOCGETOPTNODE", _IOC_READ, 0x4f04, 0x04 },
+{ "asm/openpromio.h", "OPIOCNEXTPROP", _IOC_READ|_IOC_WRITE, 0x4f03, 0x20 },
+{ "asm/openpromio.h", "OPIOCSET", _IOC_WRITE, 0x4f02, 0x20 },
+{ "asm/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
+{ "asm/watchdog.h", "WIOCGSTAT", _IOC_READ, 0x570c, 0x04 },
+{ "asm/watchdog.h", "WIOCSTART", _IOC_NONE, 0x570a, 0x00 },
+{ "asm/watchdog.h", "WIOCSTOP", _IOC_NONE, 0x570b, 0x00 },
diff --git a/strace/linux/sparc64/ioctls_inc0.h b/strace/linux/sparc64/ioctls_inc0.h
new file mode 100644
index 0000000..63b70e4
--- /dev/null
+++ b/strace/linux/sparc64/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "sparc/ioctls_inc0.h"
diff --git a/strace/linux/sparc64/ioctls_inc1.h b/strace/linux/sparc64/ioctls_inc1.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/sparc64/ioctls_inc1.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/sparc64/signalent.h b/strace/linux/sparc64/signalent.h
new file mode 100644
index 0000000..b4c6c15
--- /dev/null
+++ b/strace/linux/sparc64/signalent.h
@@ -0,0 +1 @@
+#include "sparc/signalent.h"
diff --git a/strace/linux/sparc64/signalent1.h b/strace/linux/sparc64/signalent1.h
new file mode 100644
index 0000000..093cba7
--- /dev/null
+++ b/strace/linux/sparc64/signalent1.h
@@ -0,0 +1 @@
+#include "signalent.h"
diff --git a/strace/linux/sparc64/syscallent.h b/strace/linux/sparc64/syscallent.h
new file mode 100644
index 0000000..8bf5c3a
--- /dev/null
+++ b/strace/linux/sparc64/syscallent.h
@@ -0,0 +1,361 @@
+[  0] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[  1] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[  2] = { 0,	TP,		SEN(fork),			"fork"			},
+[  3] = { 3,	TD,		SEN(read),			"read"			},
+[  4] = { 3,	TD,		SEN(write),			"write"			},
+[  5] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  6] = { 1,	TD,		SEN(close),			"close"			},
+[  7] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[  8] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[  9] = { 2,	TF,		SEN(link),			"link"			},
+[ 10] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 11] = { 2,	TF|TP|SE|SI,	SEN(execv),			"execv"			},
+[ 12] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 13] = { 3,	TF,		SEN(chown16),			"chown"			},
+[ 14] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 15] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 16] = { 3,	TF,		SEN(chown16),			"lchown"		},
+[ 17] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 18] = { 4,	0,		SEN(printargs),			"perfctr"		},
+[ 19] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 20] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 21] = { 2,	0,		SEN(capget),			"capget"		},
+[ 22] = { 2,	0,		SEN(capset),			"capset"		},
+[ 23] = { 1,	0,		SEN(setuid16),			"setuid"		},
+[ 24] = { 0,	NF,		SEN(getuid16),			"getuid"		},
+[ 25] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[ 26] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[ 27] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 28] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[ 29] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 30] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 31 ... 32] = { },
+[ 33] = { 2,	TF,		SEN(access),			"access"		},
+[ 34] = { 1,	0,		SEN(nice),			"nice"			},
+[ 35] = { },
+[ 36] = { 0,	0,		SEN(sync),			"sync"			},
+[ 37] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 38] = { 2,	TF,		SEN(stat),			"stat"			},
+[ 39] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[ 40] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[ 41] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 42] = { 0,	TD,		SEN(pipe),			"pipe"			},
+[ 43] = { 1,	0,		SEN(times),			"times"			},
+[ 44] = { },
+[ 45] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[ 46] = { 1,	0,		SEN(setgid16),			"setgid"		},
+[ 47] = { 0,	NF,		SEN(getgid16),			"getgid"		},
+[ 48] = { 2,	TS,		SEN(signal),			"signal"		},
+[ 49] = { 0,	NF,		SEN(geteuid16),			"geteuid"		},
+[ 50] = { 0,	NF,		SEN(getegid16),			"getegid"		},
+[ 51] = { 1,	TF,		SEN(acct),			"acct"			},
+[ 52] = { 2,	0,		SEN(printargs),			"memory_ordering"	},
+[ 53] = { },
+[ 54] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 55] = { 4,	0,		SEN(reboot),			"reboot"		},
+[ 56] = { },
+[ 57] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 58] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 59] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 60] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 61] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[ 62] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 63] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[ 64] = { 0,	0,		SEN(getpagesize),		"getpagesize"		},
+[ 65] = { 3,	TM,		SEN(msync),			"msync"			},
+[ 66] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[ 67] = { 4,	TD,		SEN(pread),			"pread64"		},
+[ 68] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 69 ... 70] = { },
+[ 71] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 72] = { },
+[ 73] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 74] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[ 75] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[ 76] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[ 77] = { },
+[ 78] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[ 79] = { 2,	0,		SEN(getgroups16),		"getgroups"		},
+[ 80] = { 2,	0,		SEN(setgroups16),		"setgroups"		},
+[ 81] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[ 82] = { },
+[ 83] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[ 84] = { },
+[ 85] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[ 86] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[ 87] = { },
+[ 88] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[ 89] = { },
+[ 90] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 91] = { },
+[ 92] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 93] = { 5,	TD,		SEN(select),			"select"		},
+[ 94] = { },
+[ 95] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 96] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[ 97] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 98] = { 3,	TN,		SEN(connect),			"connect"		},
+[ 99] = { 3,	TN,		SEN(accept),			"accept"		},
+[100] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[101] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[102] = { 5,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[103] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[104] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[105] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[106] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[107] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[108] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[109] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[110] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[111] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[112] = { },
+[113] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[114] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[115] = { },
+[116] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[117] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[118] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[119] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[120] = { 3,	TD,		SEN(readv),			"readv"			},
+[121] = { 3,	TD,		SEN(writev),			"writev"		},
+[122] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[123] = { 3,	TD,		SEN(fchown16),			"fchown"		},
+[124] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[125] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[126] = { 2,	0,		SEN(setreuid16),		"setreuid"		},
+[127] = { 2,	0,		SEN(setregid16),		"setregid"		},
+[128] = { 2,	TF,		SEN(rename),			"rename"		},
+[129] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[130] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[131] = { 2,	TD,		SEN(flock),			"flock"			},
+[132] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[133] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[134] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[135] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[136] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[137] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[138] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[139] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[140] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[141] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[142] = { 6,	0,		SEN(futex),			"futex"			},
+[143] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[144] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[145] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[146] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[147] = { 5,	0,		SEN(prctl),			"prctl"			},
+[148] = { 5,	0,		SEN(printargs),			"pciconfig_read"	},
+[149] = { 5,	0,		SEN(printargs),			"pciconfig_write"	},
+[150] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[151] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[152] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[153] = { 3,	TD,		SEN(poll),			"poll"			},
+[154] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[155] = { },
+[156] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[157] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[158] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[159] = { 1,	TF,		SEN(umount),			"umount"		},
+[160] = { 3,	0,		SEN(sched_setaffinity),		"sched_set_affinity"	},
+[161] = { 3,	0,		SEN(sched_getaffinity),		"sched_get_affinity"	},
+[162] = { 2,	0,		SEN(printargs),			"getdomainname"		},
+[163] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[164] = { 5,	0,		SEN(printargs),			"utrap_install"		},
+[165] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[166] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[167] = { 5,	TF,		SEN(mount),			"mount"			},
+[168] = { 2,	0,		SEN(ustat),			"ustat"			},
+[169] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[170] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[171] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[172] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[173] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[174] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[175] = { 0,	0,		SEN(setsid),			"setsid"		},
+[176] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[177] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[178] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[179] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[180] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[181] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[182] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[183] = { 1,	TS,		SEN(sigpending),		"sigpending"		},
+[184] = { 5,	0,		SEN(query_module),		"query_module"		},
+[185] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[186] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[187] = { 2,	TS,		SEN(kill),			"tkill"			},
+[188] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[189] = { 1,	0,		SEN(uname),			"uname"			},
+[190] = { 3,	0,		SEN(init_module),		"init_module"		},
+[191] = { 1,	NF,		SEN(personality),		"personality"		},
+[192] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[193] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[194] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[195] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[196] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[197] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[198] = { 3,	TS,		SEN(sigaction),			"sigaction"		},
+[199] = { 0,	TS,		SEN(siggetmask),		"sgetmask"		},
+[200] = { 1,	TS,		SEN(sigsetmask),		"ssetmask"		},
+[201] = { 3,	TS,		SEN(sigsuspend),		"sigsuspend"		},
+[202] = { 2,	TF,		SEN(lstat),			"oldlstat"		},
+[203] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[204] = { 3,	TD,		SEN(readdir),			"readdir"		},
+[205] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[206] = { 2,	TD,		SEN(socketcall),		"socketcall"		},
+[207] = { 3,	0,		SEN(syslog),			"syslog"		},
+[208] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[209] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[210] = { 4,	TD,		SEN(fadvise64),			"fadvise64_64"		},
+[211] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[212] = { 3,	TP,		SEN(waitpid),			"waitpid"		},
+[213] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[214] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[215] = { 6,	TI,		SEN(ipc),			"ipc"			},
+[216] = { 0,	TS,		SEN(sigreturn),			"sigreturn"		},
+[217] = { 5,	TP,		SEN(clone),			"clone"			},
+[218] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[219] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[220] = { 3,	TS,		SEN(sigprocmask),		"sigprocmask"		},
+[221] = { 2,	0,		SEN(create_module),		"create_module"		},
+[222] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[223] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[224] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[225] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[226] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[227] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[228] = { 1,	NF,		SEN(setfsuid16),		"setfsuid"		},
+[229] = { 1,	NF,		SEN(setfsgid16),		"setfsgid"		},
+[230] = { 5,	TD,		SEN(select),			"_newselect"		},
+[231] = { },
+[232] = { 6,	TD,		SEN(splice),			"splice"		},
+[233] = { 1,	0,		SEN(stime),			"stime"			},
+[234] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[235] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[236] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[237] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[238] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[239] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[240] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[241] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[242] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[243] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[244] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[245] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[246] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[247] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[248] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[249] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[250] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[251] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[252] = { 1,	0,		SEN(getsid),			"getsid"		},
+[253] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[254] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[255] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[256] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[257] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[258] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[259] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[260] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[261] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[262] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[263] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[264] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[265] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[266] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[267] = { },
+[268] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[269] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[270] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[271] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[272] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[273] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[274] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[275] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[276] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[277] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[278] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[279] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[280] = { 4,	TD,		SEN(tee),			"tee"			},
+[281] = { 5,	0,		SEN(add_key),			"add_key"		},
+[282] = { 4,	0,		SEN(request_key),		"request_key"		},
+[283] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[284] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[285] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[286] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[287] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[288] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[289] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[290] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[291] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[292] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[293] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[294] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[295] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[296] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[297] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[298] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[299] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[300] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[301] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[302] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[303] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[304] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[305] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[306] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[307] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[308] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[309] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[310] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[311] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[312] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[313] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[314] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[315] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[316] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[317] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[318] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[319] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[320] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[321] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[322] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[323] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[324] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[325] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[326] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[327] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[328] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[329] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[330] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[331] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[332] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[333] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[334] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[335] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[336] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[337] = { 2,	TD,		SEN(setns),			"setns"			},
+[338] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[339] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[340] = { 0,	NF,		SEN(printargs),			"kern_features"		},
+[341] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[342] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[343] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[344] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[345] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[346] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[347] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[348] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[349] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[350] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[351] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[352] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[353] = { 3,	TN,		SEN(bind),			"bind"			},
+[354] = { 2,	TN,		SEN(listen),			"listen"		},
+[355] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[356] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[357] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[358] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[359] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
+
+#define SYS_socket_subcall	400
+#include "subcall.h"
diff --git a/strace/linux/sparc64/syscallent1.h b/strace/linux/sparc64/syscallent1.h
new file mode 100644
index 0000000..5f73f3c
--- /dev/null
+++ b/strace/linux/sparc64/syscallent1.h
@@ -0,0 +1,3 @@
+#define sys_mmap_4koff sys_mmap_pgoff
+#include "../sparc/syscallent.h"
+#undef sys_mmap_4koff
diff --git a/strace/linux/sparc64/userent.h b/strace/linux/sparc64/userent.h
new file mode 100644
index 0000000..9387e25
--- /dev/null
+++ b/strace/linux/sparc64/userent.h
@@ -0,0 +1,7 @@
+XLAT_UOFF(u_tsize),
+XLAT_UOFF(u_dsize),
+XLAT_UOFF(u_ssize),
+XLAT_UOFF(signal),
+XLAT_UOFF(magic),
+XLAT_UOFF(u_comm),
+#include "../userent0.h"
diff --git a/strace/linux/subcall.h b/strace/linux/subcall.h
new file mode 100644
index 0000000..6d86751
--- /dev/null
+++ b/strace/linux/subcall.h
@@ -0,0 +1,87 @@
+/*
+ * Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef SYS_socket_subcall
+# error SYS_socket_subcall is not defined
+#endif
+
+#define IS	TRACE_INDIRECT_SUBCALL
+
+[SYS_socket_subcall +  0] = { 6,	0,	SEN(printargs),		"socket_subcall"	},
+[SYS_socket_subcall +  1] = { 3,	IS|TN,	SEN(socket),		"socket"		},
+[SYS_socket_subcall +  2] = { 3,	IS|TN,	SEN(bind),		"bind"			},
+[SYS_socket_subcall +  3] = { 3,	IS|TN,	SEN(connect),		"connect"		},
+[SYS_socket_subcall +  4] = { 2,	IS|TN,	SEN(listen),		"listen"		},
+[SYS_socket_subcall +  5] = { 3,	IS|TN,	SEN(accept),		"accept"		},
+[SYS_socket_subcall +  6] = { 3,	IS|TN,	SEN(getsockname),	"getsockname"		},
+[SYS_socket_subcall +  7] = { 3,	IS|TN,	SEN(getpeername),	"getpeername"		},
+[SYS_socket_subcall +  8] = { 4,	IS|TN,	SEN(socketpair),	"socketpair"		},
+[SYS_socket_subcall +  9] = { 4,	IS|TN,	SEN(send),		"send"			},
+[SYS_socket_subcall + 10] = { 4,	IS|TN,	SEN(recv),		"recv"			},
+[SYS_socket_subcall + 11] = { 6,	IS|TN,	SEN(sendto),		"sendto"		},
+[SYS_socket_subcall + 12] = { 6,	IS|TN,	SEN(recvfrom),		"recvfrom"		},
+[SYS_socket_subcall + 13] = { 2,	IS|TN,	SEN(shutdown),		"shutdown"		},
+[SYS_socket_subcall + 14] = { 5,	IS|TN,	SEN(setsockopt),	"setsockopt"		},
+[SYS_socket_subcall + 15] = { 5,	IS|TN,	SEN(getsockopt),	"getsockopt"		},
+[SYS_socket_subcall + 16] = { 3,	IS|TN,	SEN(sendmsg),		"sendmsg"		},
+[SYS_socket_subcall + 17] = { 3,	IS|TN,	SEN(recvmsg),		"recvmsg"		},
+[SYS_socket_subcall + 18] = { 4,	IS|TN,	SEN(accept4),		"accept4"		},
+[SYS_socket_subcall + 19] = { 5,	IS|TN,	SEN(recvmmsg),		"recvmmsg"		},
+[SYS_socket_subcall + 20] = { 4,	IS|TN,	SEN(sendmmsg),		"sendmmsg"		},
+
+#define SYS_socket_nsubcalls	21
+#define SYS_ipc_subcall	((SYS_socket_subcall) + (SYS_socket_nsubcalls))
+
+[SYS_ipc_subcall +  0] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall +  1] = { 4,	IS|TI,		SEN(semop),		"semop"			},
+[SYS_ipc_subcall +  2] = { 3,	IS|TI,		SEN(semget),		"semget"		},
+[SYS_ipc_subcall +  3] = { 4,	IS|TI,		SEN(semctl),		"semctl"		},
+[SYS_ipc_subcall +  4] = { 5,	IS|TI,		SEN(semtimedop),	"semtimedop"		},
+[SYS_ipc_subcall +  5] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall +  6] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall +  7] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall +  8] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall +  9] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 10] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 11] = { 4,	IS|TI,		SEN(msgsnd),		"msgsnd"		},
+[SYS_ipc_subcall + 12] = { 5,	IS|TI,		SEN(msgrcv),		"msgrcv"		},
+[SYS_ipc_subcall + 13] = { 2,	IS|TI,		SEN(msgget),		"msgget"		},
+[SYS_ipc_subcall + 14] = { 4,	IS|TI,		SEN(msgctl),		"msgctl"		},
+[SYS_ipc_subcall + 15] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 16] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 17] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 18] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 19] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 20] = { 6,	0,		SEN(printargs),		"ipc_subcall"		},
+[SYS_ipc_subcall + 21] = { 4,	IS|TI|TM|SI,	SEN(shmat),		"shmat"			},
+[SYS_ipc_subcall + 22] = { 4,	IS|TI|TM|SI,	SEN(shmdt),		"shmdt"			},
+[SYS_ipc_subcall + 23] = { 3,	IS|TI,		SEN(shmget),		"shmget"		},
+[SYS_ipc_subcall + 24] = { 4,	IS|TI,		SEN(shmctl),		"shmctl"		},
+
+#define SYS_ipc_nsubcalls	25
+
+#undef IS
diff --git a/strace/linux/syscall.h b/strace/linux/syscall.h
new file mode 100644
index 0000000..1b7cbc5
--- /dev/null
+++ b/strace/linux/syscall.h
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+ * 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 "dummy.h"
+#include "sys_func.h"
+#include "sen.h"
+
+#if NEED_UID16_PARSERS
+extern SYS_FUNC(chown16);
+extern SYS_FUNC(fchown16);
+extern SYS_FUNC(getgroups16);
+extern SYS_FUNC(getresuid16);
+extern SYS_FUNC(getuid16);
+extern SYS_FUNC(setfsuid16);
+extern SYS_FUNC(setgroups16);
+extern SYS_FUNC(setresuid16);
+extern SYS_FUNC(setreuid16);
+extern SYS_FUNC(setuid16);
+#endif
diff --git a/strace/linux/tile/arch_regs.c b/strace/linux/tile/arch_regs.c
new file mode 100644
index 0000000..6a7309d
--- /dev/null
+++ b/strace/linux/tile/arch_regs.c
@@ -0,0 +1,3 @@
+struct pt_regs tile_regs; /* not static */
+#define ARCH_REGS_FOR_GETREGS tile_regs
+#define ARCH_PC_REG tile_regs.pc
diff --git a/strace/linux/tile/arch_regs.h b/strace/linux/tile/arch_regs.h
new file mode 100644
index 0000000..cd3f72b
--- /dev/null
+++ b/strace/linux/tile/arch_regs.h
@@ -0,0 +1 @@
+extern struct pt_regs tile_regs;
diff --git a/strace/linux/tile/arch_sigreturn.c b/strace/linux/tile/arch_sigreturn.c
new file mode 100644
index 0000000..b1182fc
--- /dev/null
+++ b/strace/linux/tile/arch_sigreturn.c
@@ -0,0 +1,12 @@
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	/* offset of ucontext in the kernel's sigframe structure */
+#define SIGFRAME_UC_OFFSET C_ABI_SAVE_AREA_SIZE + sizeof(siginfo_t)
+	const long addr = tile_regs.sp + SIGFRAME_UC_OFFSET +
+			  offsetof(struct ucontext, uc_sigmask);
+
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/tile/errnoent1.h b/strace/linux/tile/errnoent1.h
new file mode 100644
index 0000000..091df78
--- /dev/null
+++ b/strace/linux/tile/errnoent1.h
@@ -0,0 +1,2 @@
+/* tilegx32/tilepro */
+#include "errnoent.h"
diff --git a/strace/linux/tile/get_error.c b/strace/linux/tile/get_error.c
new file mode 100644
index 0000000..9949af4
--- /dev/null
+++ b/strace/linux/tile/get_error.c
@@ -0,0 +1,16 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	/*
+	 * The standard tile calling convention returns the value
+	 * (or negative errno) in r0, and zero (or positive errno) in r1.
+	 * Until at least kernel 3.8, however, the r1 value is not
+	 * reflected in ptregs at this point, so we use r0 here.
+	 */
+	if (check_errno && is_negated_errno(tile_regs.regs[0])) {
+		tcp->u_rval = -1;
+		tcp->u_error = -tile_regs.regs[0];
+	} else {
+		tcp->u_rval = tile_regs.regs[0];
+	}
+}
diff --git a/strace/linux/tile/get_scno.c b/strace/linux/tile/get_scno.c
new file mode 100644
index 0000000..e8403d9
--- /dev/null
+++ b/strace/linux/tile/get_scno.c
@@ -0,0 +1,22 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	unsigned int currpers;
+
+#ifdef __tilepro__
+	currpers = 1;
+#else
+# ifndef PT_FLAGS_COMPAT
+#  define PT_FLAGS_COMPAT 0x10000  /* from Linux 3.8 on */
+# endif
+	if (tile_regs.flags & PT_FLAGS_COMPAT)
+		currpers = 1;
+	else
+		currpers = 0;
+#endif
+	update_personality(tcp, currpers);
+	tcp->scno = tile_regs.regs[10];
+
+	return 1;
+}
diff --git a/strace/linux/tile/get_syscall_args.c b/strace/linux/tile/get_syscall_args.c
new file mode 100644
index 0000000..b2043d3
--- /dev/null
+++ b/strace/linux/tile/get_syscall_args.c
@@ -0,0 +1,12 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	tcp->u_arg[0] = tile_regs.regs[0];
+	tcp->u_arg[1] = tile_regs.regs[1];
+	tcp->u_arg[2] = tile_regs.regs[2];
+	tcp->u_arg[3] = tile_regs.regs[3];
+	tcp->u_arg[4] = tile_regs.regs[4];
+	tcp->u_arg[5] = tile_regs.regs[5];
+	return 1;
+}
diff --git a/strace/linux/tile/ioctls_arch0.h b/strace/linux/tile/ioctls_arch0.h
new file mode 100644
index 0000000..0563585
--- /dev/null
+++ b/strace/linux/tile/ioctls_arch0.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/tile/include/ tree. */
diff --git a/strace/linux/tile/ioctls_arch1.h b/strace/linux/tile/ioctls_arch1.h
new file mode 100644
index 0000000..0563585
--- /dev/null
+++ b/strace/linux/tile/ioctls_arch1.h
@@ -0,0 +1 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/tile/include/ tree. */
diff --git a/strace/linux/tile/ioctls_inc0.h b/strace/linux/tile/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/tile/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/tile/ioctls_inc1.h b/strace/linux/tile/ioctls_inc1.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/tile/ioctls_inc1.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/tile/signalent1.h b/strace/linux/tile/signalent1.h
new file mode 100644
index 0000000..62f1193
--- /dev/null
+++ b/strace/linux/tile/signalent1.h
@@ -0,0 +1,2 @@
+/* tilegx32/tilepro */
+#include "signalent.h"
diff --git a/strace/linux/tile/syscallent.h b/strace/linux/tile/syscallent.h
new file mode 100644
index 0000000..eb518fb
--- /dev/null
+++ b/strace/linux/tile/syscallent.h
@@ -0,0 +1,4 @@
+#include "64/syscallent.h"
+/* [244 ... 259] are arch specific */
+[244] = { 1,	0,	SEN(printargs),	"cmpxchg_badaddr"	},
+[245] = { 3,	0,	SEN(printargs),	"cacheflush"		},
diff --git a/strace/linux/tile/syscallent1.h b/strace/linux/tile/syscallent1.h
new file mode 100644
index 0000000..b305f06
--- /dev/null
+++ b/strace/linux/tile/syscallent1.h
@@ -0,0 +1,6 @@
+#define sys_ARCH_mmap sys_mmap_4koff
+#define ARCH_WANT_SYNC_FILE_RANGE2 1
+#include "32/syscallent.h"
+/* [244 ... 259] are arch specific */
+[244] = { 1,	0,	SEN(printargs),	"cmpxchg_badaddr"	},
+[245] = { 3,	0,	SEN(printargs),	"cacheflush"		},
diff --git a/strace/linux/tile/userent.h b/strace/linux/tile/userent.h
new file mode 100644
index 0000000..915f4a5
--- /dev/null
+++ b/strace/linux/tile/userent.h
@@ -0,0 +1,61 @@
+{ PTREGS_OFFSET_REG(0),  "r0" },
+{ PTREGS_OFFSET_REG(1),  "r1" },
+{ PTREGS_OFFSET_REG(2),  "r2" },
+{ PTREGS_OFFSET_REG(3),  "r3" },
+{ PTREGS_OFFSET_REG(4),  "r4" },
+{ PTREGS_OFFSET_REG(5),  "r5" },
+{ PTREGS_OFFSET_REG(6),  "r6" },
+{ PTREGS_OFFSET_REG(7),  "r7" },
+{ PTREGS_OFFSET_REG(8),  "r8" },
+{ PTREGS_OFFSET_REG(9),  "r9" },
+{ PTREGS_OFFSET_REG(10), "r10" },
+{ PTREGS_OFFSET_REG(11), "r11" },
+{ PTREGS_OFFSET_REG(12), "r12" },
+{ PTREGS_OFFSET_REG(13), "r13" },
+{ PTREGS_OFFSET_REG(14), "r14" },
+{ PTREGS_OFFSET_REG(15), "r15" },
+{ PTREGS_OFFSET_REG(16), "r16" },
+{ PTREGS_OFFSET_REG(17), "r17" },
+{ PTREGS_OFFSET_REG(18), "r18" },
+{ PTREGS_OFFSET_REG(19), "r19" },
+{ PTREGS_OFFSET_REG(20), "r20" },
+{ PTREGS_OFFSET_REG(21), "r21" },
+{ PTREGS_OFFSET_REG(22), "r22" },
+{ PTREGS_OFFSET_REG(23), "r23" },
+{ PTREGS_OFFSET_REG(24), "r24" },
+{ PTREGS_OFFSET_REG(25), "r25" },
+{ PTREGS_OFFSET_REG(26), "r26" },
+{ PTREGS_OFFSET_REG(27), "r27" },
+{ PTREGS_OFFSET_REG(28), "r28" },
+{ PTREGS_OFFSET_REG(29), "r29" },
+{ PTREGS_OFFSET_REG(30), "r30" },
+{ PTREGS_OFFSET_REG(31), "r31" },
+{ PTREGS_OFFSET_REG(32), "r32" },
+{ PTREGS_OFFSET_REG(33), "r33" },
+{ PTREGS_OFFSET_REG(34), "r34" },
+{ PTREGS_OFFSET_REG(35), "r35" },
+{ PTREGS_OFFSET_REG(36), "r36" },
+{ PTREGS_OFFSET_REG(37), "r37" },
+{ PTREGS_OFFSET_REG(38), "r38" },
+{ PTREGS_OFFSET_REG(39), "r39" },
+{ PTREGS_OFFSET_REG(40), "r40" },
+{ PTREGS_OFFSET_REG(41), "r41" },
+{ PTREGS_OFFSET_REG(42), "r42" },
+{ PTREGS_OFFSET_REG(43), "r43" },
+{ PTREGS_OFFSET_REG(44), "r44" },
+{ PTREGS_OFFSET_REG(45), "r45" },
+{ PTREGS_OFFSET_REG(46), "r46" },
+{ PTREGS_OFFSET_REG(47), "r47" },
+{ PTREGS_OFFSET_REG(48), "r48" },
+{ PTREGS_OFFSET_REG(49), "r49" },
+{ PTREGS_OFFSET_REG(50), "r50" },
+{ PTREGS_OFFSET_REG(51), "r51" },
+{ PTREGS_OFFSET_REG(52), "r52" },
+{ PTREGS_OFFSET_TP, "tp" },
+{ PTREGS_OFFSET_SP, "sp" },
+{ PTREGS_OFFSET_LR, "lr" },
+{ PTREGS_OFFSET_PC, "pc" },
+{ PTREGS_OFFSET_EX1, "ex1" },
+{ PTREGS_OFFSET_FAULTNUM, "faultnum" },
+{ PTREGS_OFFSET_ORIG_R0, "orig_r0" },
+{ PTREGS_OFFSET_FLAGS, "flags" },
diff --git a/strace/linux/ubi-user.h b/strace/linux/ubi-user.h
new file mode 100644
index 0000000..e9e56b3
--- /dev/null
+++ b/strace/linux/ubi-user.h
@@ -0,0 +1,420 @@
+/*
+ * Copyright © International Business Machines Corp., 2006
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
+ * the GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Author: Artem Bityutskiy (Битюцкий Артём)
+ */
+
+#ifndef __UBI_USER_H__
+#define __UBI_USER_H__
+
+#include <linux/types.h>
+
+/*
+ * UBI device creation (the same as MTD device attachment)
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * MTD devices may be attached using %UBI_IOCATT ioctl command of the UBI
+ * control device. The caller has to properly fill and pass
+ * &struct ubi_attach_req object - UBI will attach the MTD device specified in
+ * the request and return the newly created UBI device number as the ioctl
+ * return value.
+ *
+ * UBI device deletion (the same as MTD device detachment)
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * An UBI device maybe deleted with %UBI_IOCDET ioctl command of the UBI
+ * control device.
+ *
+ * UBI volume creation
+ * ~~~~~~~~~~~~~~~~~~~
+ *
+ * UBI volumes are created via the %UBI_IOCMKVOL ioctl command of UBI character
+ * device. A &struct ubi_mkvol_req object has to be properly filled and a
+ * pointer to it has to be passed to the ioctl.
+ *
+ * UBI volume deletion
+ * ~~~~~~~~~~~~~~~~~~~
+ *
+ * To delete a volume, the %UBI_IOCRMVOL ioctl command of the UBI character
+ * device should be used. A pointer to the 32-bit volume ID hast to be passed
+ * to the ioctl.
+ *
+ * UBI volume re-size
+ * ~~~~~~~~~~~~~~~~~~
+ *
+ * To re-size a volume, the %UBI_IOCRSVOL ioctl command of the UBI character
+ * device should be used. A &struct ubi_rsvol_req object has to be properly
+ * filled and a pointer to it has to be passed to the ioctl.
+ *
+ * UBI volumes re-name
+ * ~~~~~~~~~~~~~~~~~~~
+ *
+ * To re-name several volumes atomically at one go, the %UBI_IOCRNVOL command
+ * of the UBI character device should be used. A &struct ubi_rnvol_req object
+ * has to be properly filled and a pointer to it has to be passed to the ioctl.
+ *
+ * UBI volume update
+ * ~~~~~~~~~~~~~~~~~
+ *
+ * Volume update should be done via the %UBI_IOCVOLUP ioctl command of the
+ * corresponding UBI volume character device. A pointer to a 64-bit update
+ * size should be passed to the ioctl. After this, UBI expects user to write
+ * this number of bytes to the volume character device. The update is finished
+ * when the claimed number of bytes is passed. So, the volume update sequence
+ * is something like:
+ *
+ * fd = open("/dev/my_volume");
+ * ioctl(fd, UBI_IOCVOLUP, &image_size);
+ * write(fd, buf, image_size);
+ * close(fd);
+ *
+ * Logical eraseblock erase
+ * ~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * To erase a logical eraseblock, the %UBI_IOCEBER ioctl command of the
+ * corresponding UBI volume character device should be used. This command
+ * unmaps the requested logical eraseblock, makes sure the corresponding
+ * physical eraseblock is successfully erased, and returns.
+ *
+ * Atomic logical eraseblock change
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * Atomic logical eraseblock change operation is called using the %UBI_IOCEBCH
+ * ioctl command of the corresponding UBI volume character device. A pointer to
+ * a &struct ubi_leb_change_req object has to be passed to the ioctl. Then the
+ * user is expected to write the requested amount of bytes (similarly to what
+ * should be done in case of the "volume update" ioctl).
+ *
+ * Logical eraseblock map
+ * ~~~~~~~~~~~~~~~~~~~~~
+ *
+ * To map a logical eraseblock to a physical eraseblock, the %UBI_IOCEBMAP
+ * ioctl command should be used. A pointer to a &struct ubi_map_req object is
+ * expected to be passed. The ioctl maps the requested logical eraseblock to
+ * a physical eraseblock and returns.  Only non-mapped logical eraseblocks can
+ * be mapped. If the logical eraseblock specified in the request is already
+ * mapped to a physical eraseblock, the ioctl fails and returns error.
+ *
+ * Logical eraseblock unmap
+ * ~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * To unmap a logical eraseblock to a physical eraseblock, the %UBI_IOCEBUNMAP
+ * ioctl command should be used. The ioctl unmaps the logical eraseblocks,
+ * schedules corresponding physical eraseblock for erasure, and returns. Unlike
+ * the "LEB erase" command, it does not wait for the physical eraseblock being
+ * erased. Note, the side effect of this is that if an unclean reboot happens
+ * after the unmap ioctl returns, you may find the LEB mapped again to the same
+ * physical eraseblock after the UBI is run again.
+ *
+ * Check if logical eraseblock is mapped
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * To check if a logical eraseblock is mapped to a physical eraseblock, the
+ * %UBI_IOCEBISMAP ioctl command should be used. It returns %0 if the LEB is
+ * not mapped, and %1 if it is mapped.
+ *
+ * Set an UBI volume property
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * To set an UBI volume property the %UBI_IOCSETPROP ioctl command should be
+ * used. A pointer to a &struct ubi_set_vol_prop_req object is expected to be
+ * passed. The object describes which property should be set, and to which value
+ * it should be set.
+ */
+
+/*
+ * When a new UBI volume or UBI device is created, users may either specify the
+ * volume/device number they want to create or to let UBI automatically assign
+ * the number using these constants.
+ */
+#define UBI_VOL_NUM_AUTO (-1)
+#define UBI_DEV_NUM_AUTO (-1)
+
+/* Maximum volume name length */
+#define UBI_MAX_VOLUME_NAME 127
+
+/* ioctl commands of UBI character devices */
+
+#define UBI_IOC_MAGIC 'o'
+
+/* Create an UBI volume */
+#define UBI_IOCMKVOL _IOW(UBI_IOC_MAGIC, 0, struct ubi_mkvol_req)
+/* Remove an UBI volume */
+#define UBI_IOCRMVOL _IOW(UBI_IOC_MAGIC, 1, __s32)
+/* Re-size an UBI volume */
+#define UBI_IOCRSVOL _IOW(UBI_IOC_MAGIC, 2, struct ubi_rsvol_req)
+/* Re-name volumes */
+#define UBI_IOCRNVOL _IOW(UBI_IOC_MAGIC, 3, struct ubi_rnvol_req)
+
+/* ioctl commands of the UBI control character device */
+
+#define UBI_CTRL_IOC_MAGIC 'o'
+
+/* Attach an MTD device */
+#define UBI_IOCATT _IOW(UBI_CTRL_IOC_MAGIC, 64, struct ubi_attach_req)
+/* Detach an MTD device */
+#define UBI_IOCDET _IOW(UBI_CTRL_IOC_MAGIC, 65, __s32)
+
+/* ioctl commands of UBI volume character devices */
+
+#define UBI_VOL_IOC_MAGIC 'O'
+
+/* Start UBI volume update */
+#define UBI_IOCVOLUP _IOW(UBI_VOL_IOC_MAGIC, 0, __s64)
+/* LEB erasure command, used for debugging, disabled by default */
+#define UBI_IOCEBER _IOW(UBI_VOL_IOC_MAGIC, 1, __s32)
+/* Atomic LEB change command */
+#define UBI_IOCEBCH _IOW(UBI_VOL_IOC_MAGIC, 2, __s32)
+/* Map LEB command */
+#define UBI_IOCEBMAP _IOW(UBI_VOL_IOC_MAGIC, 3, struct ubi_map_req)
+/* Unmap LEB command */
+#define UBI_IOCEBUNMAP _IOW(UBI_VOL_IOC_MAGIC, 4, __s32)
+/* Check if LEB is mapped command */
+#define UBI_IOCEBISMAP _IOR(UBI_VOL_IOC_MAGIC, 5, __s32)
+/* Set an UBI volume property */
+#define UBI_IOCSETVOLPROP _IOW(UBI_VOL_IOC_MAGIC, 6, \
+			       struct ubi_set_vol_prop_req)
+
+/* Maximum MTD device name length supported by UBI */
+#define MAX_UBI_MTD_NAME_LEN 127
+
+/* Maximum amount of UBI volumes that can be re-named at one go */
+#define UBI_MAX_RNVOL 32
+
+/*
+ * UBI volume type constants.
+ *
+ * @UBI_DYNAMIC_VOLUME: dynamic volume
+ * @UBI_STATIC_VOLUME:  static volume
+ */
+enum {
+	UBI_DYNAMIC_VOLUME = 3,
+	UBI_STATIC_VOLUME  = 4,
+};
+
+/*
+ * UBI set volume property ioctl constants.
+ *
+ * @UBI_VOL_PROP_DIRECT_WRITE: allow (any non-zero value) or disallow (value 0)
+ *                             user to directly write and erase individual
+ *                             eraseblocks on dynamic volumes
+ */
+enum {
+	UBI_VOL_PROP_DIRECT_WRITE = 1,
+};
+
+/**
+ * struct ubi_attach_req - attach MTD device request.
+ * @ubi_num: UBI device number to create
+ * @mtd_num: MTD device number to attach
+ * @vid_hdr_offset: VID header offset (use defaults if %0)
+ * @max_beb_per1024: maximum expected number of bad PEB per 1024 PEBs
+ * @padding: reserved for future, not used, has to be zeroed
+ *
+ * This data structure is used to specify MTD device UBI has to attach and the
+ * parameters it has to use. The number which should be assigned to the new UBI
+ * device is passed in @ubi_num. UBI may automatically assign the number if
+ * @UBI_DEV_NUM_AUTO is passed. In this case, the device number is returned in
+ * @ubi_num.
+ *
+ * Most applications should pass %0 in @vid_hdr_offset to make UBI use default
+ * offset of the VID header within physical eraseblocks. The default offset is
+ * the next min. I/O unit after the EC header. For example, it will be offset
+ * 512 in case of a 512 bytes page NAND flash with no sub-page support. Or
+ * it will be 512 in case of a 2KiB page NAND flash with 4 512-byte sub-pages.
+ *
+ * But in rare cases, if this optimizes things, the VID header may be placed to
+ * a different offset. For example, the boot-loader might do things faster if
+ * the VID header sits at the end of the first 2KiB NAND page with 4 sub-pages.
+ * As the boot-loader would not normally need to read EC headers (unless it
+ * needs UBI in RW mode), it might be faster to calculate ECC. This is weird
+ * example, but it real-life example. So, in this example, @vid_hdr_offer would
+ * be 2KiB-64 bytes = 1984. Note, that this position is not even 512-bytes
+ * aligned, which is OK, as UBI is clever enough to realize this is 4th
+ * sub-page of the first page and add needed padding.
+ *
+ * The @max_beb_per1024 is the maximum amount of bad PEBs UBI expects on the
+ * UBI device per 1024 eraseblocks.  This value is often given in an other form
+ * in the NAND datasheet (min NVB i.e. minimal number of valid blocks). The
+ * maximum expected bad eraseblocks per 1024 is then:
+ *    1024 * (1 - MinNVB / MaxNVB)
+ * Which gives 20 for most NAND devices.  This limit is used in order to derive
+ * amount of eraseblock UBI reserves for handling new bad blocks. If the device
+ * has more bad eraseblocks than this limit, UBI does not reserve any physical
+ * eraseblocks for new bad eraseblocks, but attempts to use available
+ * eraseblocks (if any). The accepted range is 0-768. If 0 is given, the
+ * default kernel value of %CONFIG_MTD_UBI_BEB_LIMIT will be used.
+ */
+struct ubi_attach_req {
+	__s32 ubi_num;
+	__s32 mtd_num;
+	__s32 vid_hdr_offset;
+	__s16 max_beb_per1024;
+	__s8 padding[10];
+};
+
+/**
+ * struct ubi_mkvol_req - volume description data structure used in
+ *                        volume creation requests.
+ * @vol_id: volume number
+ * @alignment: volume alignment
+ * @bytes: volume size in bytes
+ * @vol_type: volume type (%UBI_DYNAMIC_VOLUME or %UBI_STATIC_VOLUME)
+ * @padding1: reserved for future, not used, has to be zeroed
+ * @name_len: volume name length
+ * @padding2: reserved for future, not used, has to be zeroed
+ * @name: volume name
+ *
+ * This structure is used by user-space programs when creating new volumes. The
+ * @used_bytes field is only necessary when creating static volumes.
+ *
+ * The @alignment field specifies the required alignment of the volume logical
+ * eraseblock. This means, that the size of logical eraseblocks will be aligned
+ * to this number, i.e.,
+ *	(UBI device logical eraseblock size) mod (@alignment) = 0.
+ *
+ * To put it differently, the logical eraseblock of this volume may be slightly
+ * shortened in order to make it properly aligned. The alignment has to be
+ * multiple of the flash minimal input/output unit, or %1 to utilize the entire
+ * available space of logical eraseblocks.
+ *
+ * The @alignment field may be useful, for example, when one wants to maintain
+ * a block device on top of an UBI volume. In this case, it is desirable to fit
+ * an integer number of blocks in logical eraseblocks of this UBI volume. With
+ * alignment it is possible to update this volume using plane UBI volume image
+ * BLOBs, without caring about how to properly align them.
+ */
+struct ubi_mkvol_req {
+	__s32 vol_id;
+	__s32 alignment;
+	__s64 bytes;
+	__s8 vol_type;
+	__s8 padding1;
+	__s16 name_len;
+	__s8 padding2[4];
+	char name[UBI_MAX_VOLUME_NAME + 1];
+} ATTRIBUTE_PACKED;
+
+/**
+ * struct ubi_rsvol_req - a data structure used in volume re-size requests.
+ * @vol_id: ID of the volume to re-size
+ * @bytes: new size of the volume in bytes
+ *
+ * Re-sizing is possible for both dynamic and static volumes. But while dynamic
+ * volumes may be re-sized arbitrarily, static volumes cannot be made to be
+ * smaller than the number of bytes they bear. To arbitrarily shrink a static
+ * volume, it must be wiped out first (by means of volume update operation with
+ * zero number of bytes).
+ */
+struct ubi_rsvol_req {
+	__s64 bytes;
+	__s32 vol_id;
+} ATTRIBUTE_PACKED;
+
+/**
+ * struct ubi_rnvol_req - volumes re-name request.
+ * @count: count of volumes to re-name
+ * @padding1:  reserved for future, not used, has to be zeroed
+ * @vol_id: ID of the volume to re-name
+ * @name_len: name length
+ * @padding2:  reserved for future, not used, has to be zeroed
+ * @name: new volume name
+ *
+ * UBI allows to re-name up to %32 volumes at one go. The count of volumes to
+ * re-name is specified in the @count field. The ID of the volumes to re-name
+ * and the new names are specified in the @vol_id and @name fields.
+ *
+ * The UBI volume re-name operation is atomic, which means that should power cut
+ * happen, the volumes will have either old name or new name. So the possible
+ * use-cases of this command is atomic upgrade. Indeed, to upgrade, say, volumes
+ * A and B one may create temporary volumes %A1 and %B1 with the new contents,
+ * then atomically re-name A1->A and B1->B, in which case old %A and %B will
+ * be removed.
+ *
+ * If it is not desirable to remove old A and B, the re-name request has to
+ * contain 4 entries: A1->A, A->A1, B1->B, B->B1, in which case old A1 and B1
+ * become A and B, and old A and B will become A1 and B1.
+ *
+ * It is also OK to request: A1->A, A1->X, B1->B, B->Y, in which case old A1
+ * and B1 become A and B, and old A and B become X and Y.
+ *
+ * In other words, in case of re-naming into an existing volume name, the
+ * existing volume is removed, unless it is re-named as well at the same
+ * re-name request.
+ */
+struct ubi_rnvol_req {
+	__s32 count;
+	__s8 padding1[12];
+	struct {
+		__s32 vol_id;
+		__s16 name_len;
+		__s8  padding2[2];
+		char    name[UBI_MAX_VOLUME_NAME + 1];
+	} ents[UBI_MAX_RNVOL];
+} ATTRIBUTE_PACKED;
+
+/**
+ * struct ubi_leb_change_req - a data structure used in atomic LEB change
+ *                             requests.
+ * @lnum: logical eraseblock number to change
+ * @bytes: how many bytes will be written to the logical eraseblock
+ * @dtype: pass "3" for better compatibility with old kernels
+ * @padding: reserved for future, not used, has to be zeroed
+ *
+ * The @dtype field used to inform UBI about what kind of data will be written
+ * to the LEB: long term (value 1), short term (value 2), unknown (value 3).
+ * UBI tried to pick a PEB with lower erase counter for short term data and a
+ * PEB with higher erase counter for long term data. But this was not really
+ * used because users usually do not know this and could easily mislead UBI. We
+ * removed this feature in May 2012. UBI currently just ignores the @dtype
+ * field. But for better compatibility with older kernels it is recommended to
+ * set @dtype to 3 (unknown).
+ */
+struct ubi_leb_change_req {
+	__s32 lnum;
+	__s32 bytes;
+	__s8  dtype; /* obsolete, do not use! */
+	__s8  padding[7];
+} ATTRIBUTE_PACKED;
+
+/**
+ * struct ubi_map_req - a data structure used in map LEB requests.
+ * @dtype: pass "3" for better compatibility with old kernels
+ * @lnum: logical eraseblock number to unmap
+ * @padding: reserved for future, not used, has to be zeroed
+ */
+struct ubi_map_req {
+	__s32 lnum;
+	__s8  dtype; /* obsolete, do not use! */
+	__s8  padding[3];
+} ATTRIBUTE_PACKED;
+
+
+/**
+ * struct ubi_set_vol_prop_req - a data structure used to set an UBI volume
+ *                               property.
+ * @property: property to set (%UBI_VOL_PROP_DIRECT_WRITE)
+ * @padding: reserved for future, not used, has to be zeroed
+ * @value: value to set
+ */
+struct ubi_set_vol_prop_req {
+	__u8  property;
+	__u8  padding[7];
+	__u64 value;
+}  ATTRIBUTE_PACKED;
+
+#endif /* __UBI_USER_H__ */
diff --git a/strace/linux/unix_diag.h b/strace/linux/unix_diag.h
new file mode 100644
index 0000000..b37d465
--- /dev/null
+++ b/strace/linux/unix_diag.h
@@ -0,0 +1,24 @@
+struct unix_diag_req {
+	uint8_t	 sdiag_family;
+	uint8_t	 sdiag_protocol;
+	uint16_t pad;
+	uint32_t udiag_states;
+	uint32_t udiag_ino;
+	uint32_t udiag_show;
+	uint32_t udiag_cookie[2];
+};
+
+#define UDIAG_SHOW_NAME		0x01
+#define UDIAG_SHOW_PEER		0x04
+
+struct unix_diag_msg {
+	uint8_t	 udiag_family;
+	uint8_t	 udiag_type;
+	uint8_t	 udiag_state;
+	uint8_t	 pad;
+	uint32_t udiag_ino;
+	uint32_t udiag_cookie[2];
+};
+
+#define UNIX_DIAG_NAME 0
+#define UNIX_DIAG_PEER 2
diff --git a/strace/linux/userent.h b/strace/linux/userent.h
new file mode 100644
index 0000000..da84fa5
--- /dev/null
+++ b/strace/linux/userent.h
@@ -0,0 +1 @@
+/* nothing */
diff --git a/strace/linux/userent0.h b/strace/linux/userent0.h
new file mode 100644
index 0000000..b3c5ebc
--- /dev/null
+++ b/strace/linux/userent0.h
@@ -0,0 +1 @@
+{ sizeof(struct user),	"sizeof(struct user)" },
diff --git a/strace/linux/x32/arch_regs.c b/strace/linux/x32/arch_regs.c
new file mode 100644
index 0000000..8140bc0
--- /dev/null
+++ b/strace/linux/x32/arch_regs.c
@@ -0,0 +1,2 @@
+#include "x86_64/arch_regs.c"
+#define ARCH_PC_REG (x86_io.iov_len == sizeof(i386_regs) ? i386_regs.eip : x86_64_regs.rip)
diff --git a/strace/linux/x32/arch_regs.h b/strace/linux/x32/arch_regs.h
new file mode 100644
index 0000000..9064ca6
--- /dev/null
+++ b/strace/linux/x32/arch_regs.h
@@ -0,0 +1 @@
+#include "x86_64/arch_regs.h"
diff --git a/strace/linux/x32/arch_sigreturn.c b/strace/linux/x32/arch_sigreturn.c
new file mode 100644
index 0000000..9a778fc
--- /dev/null
+++ b/strace/linux/x32/arch_sigreturn.c
@@ -0,0 +1 @@
+#include "x86_64/arch_sigreturn.c"
diff --git a/strace/linux/x32/asm_stat.h b/strace/linux/x32/asm_stat.h
new file mode 100644
index 0000000..6713ac4
--- /dev/null
+++ b/strace/linux/x32/asm_stat.h
@@ -0,0 +1,47 @@
+/*
+ * This is a replacement for x32 <asm/stat.h> which
+ * appears to be wrong in older kernel headers.
+ */
+
+#ifndef STRACE_ASM_STAT_H
+
+# define STRACE_ASM_STAT_H
+
+# include "kernel_types.h"
+
+struct stat {
+	kernel_ulong_t	st_dev;
+	kernel_ulong_t	st_ino;
+	kernel_ulong_t	st_nlink;
+	unsigned int	st_mode;
+	unsigned int	st_uid;
+	unsigned int	st_gid;
+	unsigned int	pad0__;
+	kernel_ulong_t	st_rdev;
+	kernel_long_t	st_size;
+	kernel_long_t	st_blksize;
+	kernel_long_t	st_blocks;
+	kernel_ulong_t	st_atime;
+	kernel_ulong_t	st_atime_nsec;
+	kernel_ulong_t	st_mtime;
+	kernel_ulong_t	st_mtime_nsec;
+	kernel_ulong_t	st_ctime;
+	kernel_ulong_t	st_ctime_nsec;
+	kernel_long_t	pad1__[3];
+};
+
+struct __old_kernel_stat {
+	unsigned short st_dev;
+	unsigned short st_ino;
+	unsigned short st_mode;
+	unsigned short st_nlink;
+	unsigned short st_uid;
+	unsigned short st_gid;
+	unsigned short st_rdev;
+	unsigned int  st_size;
+	unsigned int  st_atime;
+	unsigned int  st_mtime;
+	unsigned int  st_ctime;
+};
+
+#endif /* !STRACE_ASM_STAT_H */
diff --git a/strace/linux/x32/errnoent1.h b/strace/linux/x32/errnoent1.h
new file mode 100644
index 0000000..d32435a
--- /dev/null
+++ b/strace/linux/x32/errnoent1.h
@@ -0,0 +1,2 @@
+/* i386 personality */
+#include "errnoent.h"
diff --git a/strace/linux/x32/get_error.c b/strace/linux/x32/get_error.c
new file mode 100644
index 0000000..6c6fbaf
--- /dev/null
+++ b/strace/linux/x32/get_error.c
@@ -0,0 +1 @@
+#include "x86_64/get_error.c"
diff --git a/strace/linux/x32/get_scno.c b/strace/linux/x32/get_scno.c
new file mode 100644
index 0000000..492863f
--- /dev/null
+++ b/strace/linux/x32/get_scno.c
@@ -0,0 +1 @@
+#include "x86_64/get_scno.c"
diff --git a/strace/linux/x32/get_syscall_args.c b/strace/linux/x32/get_syscall_args.c
new file mode 100644
index 0000000..6cdb465
--- /dev/null
+++ b/strace/linux/x32/get_syscall_args.c
@@ -0,0 +1 @@
+#include "x86_64/get_syscall_args.c"
diff --git a/strace/linux/x32/ioctls_arch0.h b/strace/linux/x32/ioctls_arch0.h
new file mode 100644
index 0000000..7070560
--- /dev/null
+++ b/strace/linux/x32/ioctls_arch0.h
@@ -0,0 +1 @@
+#include "x86_64/ioctls_arch0.h"
diff --git a/strace/linux/x32/ioctls_arch1.h b/strace/linux/x32/ioctls_arch1.h
new file mode 100644
index 0000000..58a5706
--- /dev/null
+++ b/strace/linux/x32/ioctls_arch1.h
@@ -0,0 +1 @@
+#include "i386/ioctls_arch0.h"
diff --git a/strace/linux/x32/ioctls_inc0.h b/strace/linux/x32/ioctls_inc0.h
new file mode 100644
index 0000000..0c36e25
--- /dev/null
+++ b/strace/linux/x32/ioctls_inc0.h
@@ -0,0 +1,2824 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/include/ tree. */
+{ "acpi/apei.h", "APEI_ERST_CLEAR_RECORD", _IOC_WRITE, 0x4501, 0x08 },
+{ "acpi/apei.h", "APEI_ERST_GET_RECORD_COUNT", _IOC_READ, 0x4502, 0x04 },
+{ "asm-generic/ioctls.h", "FIOASYNC", 0, 0x5452, 0 },
+{ "asm-generic/ioctls.h", "FIOCLEX", 0, 0x5451, 0 },
+{ "asm-generic/ioctls.h", "FIONBIO", 0, 0x5421, 0 },
+{ "asm-generic/ioctls.h", "FIONCLEX", 0, 0x5450, 0 },
+{ "asm-generic/ioctls.h", "FIONREAD", 0, 0x541B, 0 },
+{ "asm-generic/ioctls.h", "FIOQSIZE", 0, 0x5460, 0 },
+{ "asm-generic/ioctls.h", "TCFLSH", 0, 0x540B, 0 },
+{ "asm-generic/ioctls.h", "TCGETA", 0, 0x5405, 0 },
+{ "asm-generic/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm-generic/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm-generic/ioctls.h", "TCGETX", 0, 0x5432, 0 },
+{ "asm-generic/ioctls.h", "TCSBRK", 0, 0x5409, 0 },
+{ "asm-generic/ioctls.h", "TCSBRKP", 0, 0x5425, 0 },
+{ "asm-generic/ioctls.h", "TCSETA", 0, 0x5406, 0 },
+{ "asm-generic/ioctls.h", "TCSETAF", 0, 0x5408, 0 },
+{ "asm-generic/ioctls.h", "TCSETAW", 0, 0x5407, 0 },
+{ "asm-generic/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm-generic/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm-generic/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm-generic/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm-generic/ioctls.h", "TCSETX", 0, 0x5433, 0 },
+{ "asm-generic/ioctls.h", "TCSETXF", 0, 0x5434, 0 },
+{ "asm-generic/ioctls.h", "TCSETXW", 0, 0x5435, 0 },
+{ "asm-generic/ioctls.h", "TCXONC", 0, 0x540A, 0 },
+{ "asm-generic/ioctls.h", "TIOCCBRK", 0, 0x5428, 0 },
+{ "asm-generic/ioctls.h", "TIOCCONS", 0, 0x541D, 0 },
+{ "asm-generic/ioctls.h", "TIOCEXCL", 0, 0x540C, 0 },
+{ "asm-generic/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGETD", 0, 0x5424, 0 },
+{ "asm-generic/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm-generic/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPGRP", 0, 0x540F, 0 },
+{ "asm-generic/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCGRS485", 0, 0x542E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSERIAL", 0, 0x541E, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSID", 0, 0x5429, 0 },
+{ "asm-generic/ioctls.h", "TIOCGSOFTCAR", 0, 0x5419, 0 },
+{ "asm-generic/ioctls.h", "TIOCGWINSZ", 0, 0x5413, 0 },
+{ "asm-generic/ioctls.h", "TIOCLINUX", 0, 0x541C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIC", 0, 0x5417, 0 },
+{ "asm-generic/ioctls.h", "TIOCMBIS", 0, 0x5416, 0 },
+{ "asm-generic/ioctls.h", "TIOCMGET", 0, 0x5415, 0 },
+{ "asm-generic/ioctls.h", "TIOCMIWAIT", 0, 0x545C, 0 },
+{ "asm-generic/ioctls.h", "TIOCMSET", 0, 0x5418, 0 },
+{ "asm-generic/ioctls.h", "TIOCNOTTY", 0, 0x5422, 0 },
+{ "asm-generic/ioctls.h", "TIOCNXCL", 0, 0x540D, 0 },
+{ "asm-generic/ioctls.h", "TIOCOUTQ", 0, 0x5411, 0 },
+{ "asm-generic/ioctls.h", "TIOCPKT", 0, 0x5420, 0 },
+{ "asm-generic/ioctls.h", "TIOCSBRK", 0, 0x5427, 0 },
+{ "asm-generic/ioctls.h", "TIOCSCTTY", 0, 0x540E, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERCONFIG", 0, 0x5453, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETLSR", 0, 0x5459, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGETMULTI", 0, 0x545A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERGWILD", 0, 0x5454, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSETMULTI", 0, 0x545B, 0 },
+{ "asm-generic/ioctls.h", "TIOCSERSWILD", 0, 0x5455, 0 },
+{ "asm-generic/ioctls.h", "TIOCSETD", 0, 0x5423, 0 },
+{ "asm-generic/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPGRP", 0, 0x5410, 0 },
+{ "asm-generic/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm-generic/ioctls.h", "TIOCSRS485", 0, 0x542F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSERIAL", 0, 0x541F, 0 },
+{ "asm-generic/ioctls.h", "TIOCSSOFTCAR", 0, 0x541A, 0 },
+{ "asm-generic/ioctls.h", "TIOCSTI", 0, 0x5412, 0 },
+{ "asm-generic/ioctls.h", "TIOCSWINSZ", 0, 0x5414, 0 },
+{ "asm-generic/ioctls.h", "TIOCVHANGUP", 0, 0x5437, 0 },
+{ "asm-generic/sockios.h", "FIOGETOWN", 0, 0x8903, 0 },
+{ "asm-generic/sockios.h", "FIOSETOWN", 0, 0x8901, 0 },
+{ "asm-generic/sockios.h", "SIOCATMARK", 0, 0x8905, 0 },
+{ "asm-generic/sockios.h", "SIOCGPGRP", 0, 0x8904, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm-generic/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm-generic/sockios.h", "SIOCSPGRP", 0, 0x8902, 0 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_BO_LIST", _IOC_READ|_IOC_WRITE, 0x6443, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CS", _IOC_READ|_IOC_WRITE, 0x6444, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_CTX", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_METADATA", _IOC_READ|_IOC_WRITE, 0x6446, 0x120 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x08 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_OP", _IOC_READ|_IOC_WRITE, 0x6450, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6451, 0x18 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_VA", _IOC_WRITE, 0x6448, 0x28 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_GEM_WAIT_IDLE", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_INFO", _IOC_WRITE, 0x6445, 0x20 },
+{ "drm/amdgpu_drm.h", "DRM_IOCTL_AMDGPU_WAIT_CS", _IOC_READ|_IOC_WRITE, 0x6449, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_BUFS", _IOC_READ|_IOC_WRITE, 0x6416, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_CTX", _IOC_READ|_IOC_WRITE, 0x6420, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_DRAW", _IOC_READ|_IOC_WRITE, 0x6427, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_ADD_MAP", _IOC_READ|_IOC_WRITE, 0x6415, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ACQUIRE", _IOC_NONE, 0x6430, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6434, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_BIND", _IOC_WRITE, 0x6436, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_ENABLE", _IOC_WRITE, 0x6432, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_FREE", _IOC_WRITE, 0x6435, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_INFO", _IOC_READ, 0x6433, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_RELEASE", _IOC_NONE, 0x6431, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_AGP_UNBIND", _IOC_WRITE, 0x6437, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_AUTH_MAGIC", _IOC_WRITE, 0x6411, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_BLOCK", _IOC_READ|_IOC_WRITE, 0x6412, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_CONTROL", _IOC_WRITE, 0x6414, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_DMA", _IOC_READ|_IOC_WRITE, 0x6429, 0x28 },
+{ "drm/drm.h", "DRM_IOCTL_DROP_MASTER", _IOC_NONE, 0x641f, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_FINISH", _IOC_WRITE, 0x642c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_FREE_BUFS", _IOC_WRITE, 0x641a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_CLOSE", _IOC_WRITE, 0x6409, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_FLINK", _IOC_READ|_IOC_WRITE, 0x640a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GEM_OPEN", _IOC_READ|_IOC_WRITE, 0x640b, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CAP", _IOC_READ|_IOC_WRITE, 0x640c, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CLIENT", _IOC_READ|_IOC_WRITE, 0x6405, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_GET_CTX", _IOC_READ|_IOC_WRITE, 0x6423, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAGIC", _IOC_READ, 0x6402, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_GET_MAP", _IOC_READ|_IOC_WRITE, 0x6404, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_GET_SAREA_CTX", _IOC_READ|_IOC_WRITE, 0x641d, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_GET_STATS", _IOC_READ, 0x6406, 0x7c },
+{ "drm/drm.h", "DRM_IOCTL_GET_UNIQUE", _IOC_READ|_IOC_WRITE, 0x6401, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_INFO_BUFS", _IOC_READ|_IOC_WRITE, 0x6418, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_IRQ_BUSID", _IOC_READ|_IOC_WRITE, 0x6403, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_LOCK", _IOC_WRITE, 0x642a, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MAP_BUFS", _IOC_READ|_IOC_WRITE, 0x6419, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_MARK_BUFS", _IOC_WRITE, 0x6417, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODESET_CTL", _IOC_WRITE, 0x6408, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB", _IOC_READ|_IOC_WRITE, 0x64ae, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ADDFB2", _IOC_READ|_IOC_WRITE, 0x64b8, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATOMIC", _IOC_READ|_IOC_WRITE, 0x64bc, 0x38 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_ATTACHMODE", _IOC_READ|_IOC_WRITE, 0x64a8, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATEPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64bd, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CREATE_DUMB", _IOC_READ|_IOC_WRITE, 0x64b2, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR", _IOC_READ|_IOC_WRITE, 0x64a3, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_CURSOR2", _IOC_READ|_IOC_WRITE, 0x64bb, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROYPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64be, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DESTROY_DUMB", _IOC_READ|_IOC_WRITE, 0x64b4, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DETACHMODE", _IOC_READ|_IOC_WRITE, 0x64a9, 0x48 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_DIRTYFB", _IOC_READ|_IOC_WRITE, 0x64b1, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCONNECTOR", _IOC_READ|_IOC_WRITE, 0x64a7, 0x50 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETCRTC", _IOC_READ|_IOC_WRITE, 0x64a1, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETENCODER", _IOC_READ|_IOC_WRITE, 0x64a6, 0x14 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETFB", _IOC_READ|_IOC_WRITE, 0x64ad, 0x1c },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a4, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANE", _IOC_READ|_IOC_WRITE, 0x64b6, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPLANERESOURCES", _IOC_READ|_IOC_WRITE, 0x64b5, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPBLOB", _IOC_READ|_IOC_WRITE, 0x64ac, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64aa, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_GETRESOURCES", _IOC_READ|_IOC_WRITE, 0x64a0, 0x40 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_MAP_DUMB", _IOC_READ|_IOC_WRITE, 0x64b3, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_GETPROPERTIES", _IOC_READ|_IOC_WRITE, 0x64b9, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_OBJ_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ba, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_PAGE_FLIP", _IOC_READ|_IOC_WRITE, 0x64b0, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_RMFB", _IOC_READ|_IOC_WRITE, 0x64af, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETCRTC", _IOC_READ|_IOC_WRITE, 0x64a2, 0x68 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETGAMMA", _IOC_READ|_IOC_WRITE, 0x64a5, 0x20 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPLANE", _IOC_READ|_IOC_WRITE, 0x64b7, 0x30 },
+{ "drm/drm.h", "DRM_IOCTL_MODE_SETPROPERTY", _IOC_READ|_IOC_WRITE, 0x64ab, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_MOD_CTX", _IOC_WRITE, 0x6422, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_NEW_CTX", _IOC_WRITE, 0x6425, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_FD_TO_HANDLE", _IOC_READ|_IOC_WRITE, 0x642e, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_PRIME_HANDLE_TO_FD", _IOC_READ|_IOC_WRITE, 0x642d, 0x0c },
+{ "drm/drm.h", "DRM_IOCTL_RES_CTX", _IOC_READ|_IOC_WRITE, 0x6426, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_CTX", _IOC_READ|_IOC_WRITE, 0x6421, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_RM_DRAW", _IOC_READ|_IOC_WRITE, 0x6428, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_RM_MAP", _IOC_WRITE, 0x641b, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_SET_CLIENT_CAP", _IOC_WRITE, 0x640d, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SET_MASTER", _IOC_NONE, 0x641e, 0x00 },
+{ "drm/drm.h", "DRM_IOCTL_SET_SAREA_CTX", _IOC_WRITE, 0x641c, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SET_UNIQUE", _IOC_WRITE, 0x6410, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SET_VERSION", _IOC_READ|_IOC_WRITE, 0x6407, 0x10 },
+{ "drm/drm.h", "DRM_IOCTL_SG_ALLOC", _IOC_READ|_IOC_WRITE, 0x6438, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SG_FREE", _IOC_WRITE, 0x6439, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_SWITCH_CTX", _IOC_WRITE, 0x6424, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UNBLOCK", _IOC_READ|_IOC_WRITE, 0x6413, 0x04 },
+{ "drm/drm.h", "DRM_IOCTL_UNLOCK", _IOC_WRITE, 0x642b, 0x08 },
+{ "drm/drm.h", "DRM_IOCTL_UPDATE_DRAW", _IOC_WRITE, 0x643f, 0x18 },
+{ "drm/drm.h", "DRM_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x6400, 0x24 },
+{ "drm/drm.h", "DRM_IOCTL_WAIT_VBLANK", _IOC_READ|_IOC_WRITE, 0x643a, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x30 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6448, 0x18 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GEM_WAIT", _IOC_WRITE, 0x6449, 0x20 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/etnaviv_drm.h", "DRM_IOCTL_ETNAVIV_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x20 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_EXEC", _IOC_READ|_IOC_WRITE, 0x6462, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_GET_VER", _IOC_READ|_IOC_WRITE, 0x6460, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_G2D_SET_CMDLIST", _IOC_READ|_IOC_WRITE, 0x6461, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_GET", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_GEM_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_CMD_CTRL", _IOC_READ|_IOC_WRITE, 0x6473, 0x08 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_GET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6470, 0x50 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_QUEUE_BUF", _IOC_READ|_IOC_WRITE, 0x6472, 0x28 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_IPP_SET_PROPERTY", _IOC_READ|_IOC_WRITE, 0x6471, 0x60 },
+{ "drm/exynos_drm.h", "DRM_IOCTL_EXYNOS_VIDI_CONNECTION", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_CLEAR", _IOC_WRITE, 0x6442, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_COPY", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_DOCOPY", _IOC_NONE, 0x6448, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLIP", _IOC_NONE, 0x644e, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FLUSH", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_FSTATUS", _IOC_NONE, 0x644a, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETAGE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_GETBUF", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_INIT", _IOC_WRITE, 0x6440, 0x40 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_MC", _IOC_WRITE, 0x644c, 0x14 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0FLIP", _IOC_NONE, 0x644b, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_OV0INFO", _IOC_READ, 0x6449, 0x08 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_RSTATUS", _IOC_NONE, 0x644d, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_SWAP", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/i810_drm.h", "DRM_IOCTL_I810_VERTEX", _IOC_WRITE, 0x6441, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_ALLOC", _IOC_READ|_IOC_WRITE, 0x6448, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_BATCHBUFFER", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_CMDBUFFER", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_DESTROY_HEAP", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLIP", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FLUSH", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_FREE", _IOC_WRITE, 0x6449, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x6457, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_CREATE", _IOC_READ|_IOC_WRITE, 0x646d, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_DESTROY", _IOC_WRITE, 0x646e, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6474, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM", _IOC_READ|_IOC_WRITE, 0x6475, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645b, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_ENTERVT", _IOC_NONE, 0x6459, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER", _IOC_WRITE, 0x6454, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_EXECBUFFER2", _IOC_WRITE, 0x6469, 0x40 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_APERTURE", _IOC_READ, 0x6463, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_CACHING", _IOC_READ|_IOC_WRITE, 0x6470, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6462, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_INIT", _IOC_WRITE, 0x6453, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_LEAVEVT", _IOC_NONE, 0x645a, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MADVISE", _IOC_READ|_IOC_WRITE, 0x6466, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x28 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_MMAP_GTT", _IOC_READ|_IOC_WRITE, 0x6464, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PIN", _IOC_READ|_IOC_WRITE, 0x6455, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PREAD", _IOC_WRITE, 0x645c, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_PWRITE", _IOC_WRITE, 0x645d, 0x20 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_CACHING", _IOC_WRITE, 0x646f, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_DOMAIN", _IOC_WRITE, 0x645f, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6461, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_SW_FINISH", _IOC_WRITE, 0x6460, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_THROTTLE", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_UNPIN", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x6473, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GEM_WAIT", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6446, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_PIPE_FROM_CRTC_ID", _IOC_READ|_IOC_WRITE, 0x6465, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_RESET_STATS", _IOC_READ|_IOC_WRITE, 0x6472, 0x18 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646a, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_GET_VBLANK_PIPE", _IOC_READ, 0x644e, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_HWS_ADDR", _IOC_WRITE, 0x6451, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT", _IOC_WRITE, 0x6440, 0x44 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_INIT_HEAP", _IOC_WRITE, 0x644a, 0x0c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_IRQ_WAIT", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_ATTRS", _IOC_READ|_IOC_WRITE, 0x6468, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_OVERLAY_PUT_IMAGE", _IOC_WRITE, 0x6467, 0x2c },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_REG_READ", _IOC_READ|_IOC_WRITE, 0x6471, 0x10 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SETPARAM", _IOC_WRITE, 0x6447, 0x08 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_SPRITE_COLORKEY", _IOC_READ|_IOC_WRITE, 0x646b, 0x14 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_SET_VBLANK_PIPE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/i915_drm.h", "DRM_IOCTL_I915_VBLANK_SWAP", _IOC_READ|_IOC_WRITE, 0x644f, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_BLIT", _IOC_WRITE, 0x6448, 0x34 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_CLEAR", _IOC_WRITE, 0x6444, 0x14 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_DMA_BOOTSTRAP", _IOC_READ|_IOC_WRITE, 0x644c, 0x1c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_FLUSH", _IOC_WRITE, 0x6441, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6449, 0x08 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_ILOAD", _IOC_WRITE, 0x6447, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INDICES", _IOC_WRITE, 0x6446, 0x10 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_INIT", _IOC_WRITE, 0x6440, 0x5c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_RESET", _IOC_NONE, 0x6442, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SET_FENCE", _IOC_WRITE, 0x644a, 0x04 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_SWAP", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_VERTEX", _IOC_WRITE, 0x6445, 0x0c },
+{ "drm/mga_drm.h", "DRM_IOCTL_MGA_WAIT_FENCE", _IOC_READ|_IOC_WRITE, 0x644b, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x04 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x18 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GEM_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6446, 0x20 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/msm_drm.h", "DRM_IOCTL_MSM_WAIT_FENCE", _IOC_WRITE, 0x6447, 0x18 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_FINI", _IOC_WRITE, 0x6483, 0x04 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_CPU_PREP", _IOC_WRITE, 0x6482, 0x08 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6484, 0x28 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6480, 0x30 },
+{ "drm/nouveau_drm.h", "DRM_IOCTL_NOUVEAU_GEM_PUSHBUF", _IOC_READ|_IOC_WRITE, 0x6481, 0x40 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_FINI", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_CPU_PREP", _IOC_WRITE, 0x6444, 0x08 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GEM_NEW", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_GET_PARAM", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/omap_drm.h", "DRM_IOCTL_OMAP_SET_PARAM", _IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC", _IOC_READ|_IOC_WRITE, 0x6440, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_ALLOC_SURF", _IOC_READ|_IOC_WRITE, 0x6446, 0x18 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_CLIENTCAP", _IOC_WRITE, 0x6445, 0x08 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_EXECBUFFER", _IOC_WRITE, 0x6442, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/qxl_drm.h", "DRM_IOCTL_QXL_UPDATE_AREA", _IOC_WRITE, 0x6443, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_BLIT", _IOC_WRITE, 0x644b, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CCE_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_CLEAR", _IOC_WRITE, 0x6448, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_DEPTH", _IOC_WRITE, 0x644c, 0x18 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FLIP", _IOC_NONE, 0x6453, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_FULLSCREEN", _IOC_WRITE, 0x6450, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6452, 0x08 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644f, 0x10 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_INIT", _IOC_WRITE, 0x6440, 0x58 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_RESET", _IOC_NONE, 0x6446, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_STIPPLE", _IOC_WRITE, 0x644d, 0x04 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/r128_drm.h", "DRM_IOCTL_R128_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_ALLOC", _IOC_READ|_IOC_WRITE, 0x6453, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CLEAR", _IOC_WRITE, 0x6448, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CMDBUF", _IOC_WRITE, 0x6450, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_IDLE", _IOC_NONE, 0x6444, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_INIT", _IOC_WRITE, 0x6440, 0x54 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESET", _IOC_NONE, 0x6443, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_RESUME", _IOC_NONE, 0x6458, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_START", _IOC_NONE, 0x6441, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CP_STOP", _IOC_WRITE, 0x6442, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_CS", _IOC_READ|_IOC_WRITE, 0x6466, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FLIP", _IOC_NONE, 0x6452, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FREE", _IOC_WRITE, 0x6454, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_FULLSCREEN", _IOC_WRITE, 0x6446, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_BUSY", _IOC_READ|_IOC_WRITE, 0x646a, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x645d, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x6469, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_INFO", _IOC_READ|_IOC_WRITE, 0x645c, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x645e, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_OP", _IOC_READ|_IOC_WRITE, 0x646c, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PREAD", _IOC_READ|_IOC_WRITE, 0x6461, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_PWRITE", _IOC_READ|_IOC_WRITE, 0x6462, 0x20 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_DOMAIN", _IOC_READ|_IOC_WRITE, 0x6463, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x6468, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_USERPTR", _IOC_READ|_IOC_WRITE, 0x646d, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_VA", _IOC_READ|_IOC_WRITE, 0x646b, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GEM_WAIT_IDLE", _IOC_WRITE, 0x6464, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6451, 0x08 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDICES", _IOC_WRITE, 0x644a, 0x14 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INDIRECT", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INFO", _IOC_READ|_IOC_WRITE, 0x6467, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_INIT_HEAP", _IOC_WRITE, 0x6455, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_EMIT", _IOC_READ|_IOC_WRITE, 0x6456, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_IRQ_WAIT", _IOC_WRITE, 0x6457, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_RESET", _IOC_NONE, 0x6445, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SETPARAM", _IOC_WRITE, 0x6459, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_STIPPLE", _IOC_WRITE, 0x644c, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_ALLOC", _IOC_WRITE, 0x645a, 0x0c },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SURF_FREE", _IOC_WRITE, 0x645b, 0x04 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_SWAP", _IOC_NONE, 0x6447, 0x00 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_TEXTURE", _IOC_READ|_IOC_WRITE, 0x644e, 0x18 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX", _IOC_WRITE, 0x6449, 0x10 },
+{ "drm/radeon_drm.h", "DRM_IOCTL_RADEON_VERTEX2", _IOC_WRITE, 0x644f, 0x18 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_CMDBUF", _IOC_WRITE, 0x6441, 0x24 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_EMIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_EVENT_WAIT", _IOC_WRITE, 0x6443, 0x08 },
+{ "drm/savage_drm.h", "DRM_IOCTL_SAVAGE_BCI_INIT", _IOC_WRITE, 0x6440, 0x50 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_ALLOC", _IOC_READ|_IOC_WRITE, 0x6454, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_FREE", _IOC_WRITE, 0x6455, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6453, 0x08 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_ALLOC", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_FREE", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/sis_drm.h", "DRM_IOCTL_SIS_FB_INIT", _IOC_WRITE, 0x6456, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_CLOSE_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6446, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_CREATE", _IOC_READ|_IOC_WRITE, 0x6440, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644d, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_GET_TILING", _IOC_READ|_IOC_WRITE, 0x644b, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_MMAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_FLAGS", _IOC_READ|_IOC_WRITE, 0x644c, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GEM_SET_TILING", _IOC_READ|_IOC_WRITE, 0x644a, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_GET_SYNCPT_BASE", _IOC_READ|_IOC_WRITE, 0x6449, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_OPEN_CHANNEL", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SUBMIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x58 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_INCR", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_READ", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/tegra_drm.h", "DRM_IOCTL_TEGRA_SYNCPT_WAIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_BO", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_CREATE_SHADER_BO", _IOC_READ|_IOC_WRITE, 0x6445, 0x18 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_GET_HANG_STATE", _IOC_READ|_IOC_WRITE, 0x6446, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_MMAP_BO", _IOC_READ|_IOC_WRITE, 0x6444, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_SUBMIT_CL", _IOC_READ|_IOC_WRITE, 0x6440, 0xa0 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_BO", _IOC_READ|_IOC_WRITE, 0x6442, 0x10 },
+{ "drm/vc4_drm.h", "DRM_IOCTL_VC4_WAIT_SEQNO", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_AGP_INIT", _IOC_READ|_IOC_WRITE, 0x6442, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_ALLOCMEM", _IOC_READ|_IOC_WRITE, 0x6440, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_BLIT_SYNC", _IOC_WRITE, 0x644f, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUFFER", _IOC_WRITE, 0x6448, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_CMDBUF_SIZE", _IOC_READ|_IOC_WRITE, 0x644b, 0x0c },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DEC_FUTEX", _IOC_WRITE, 0x6445, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_BLIT", _IOC_WRITE, 0x644e, 0x28 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_DMA_INIT", _IOC_READ|_IOC_WRITE, 0x6447, 0x10 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FB_INIT", _IOC_READ|_IOC_WRITE, 0x6443, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FLUSH", _IOC_NONE, 0x6449, 0x00 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_FREEMEM", _IOC_WRITE, 0x6441, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_MAP_INIT", _IOC_READ|_IOC_WRITE, 0x6444, 0x14 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_PCICMD", _IOC_WRITE, 0x644a, 0x08 },
+{ "drm/via_drm.h", "DRM_IOCTL_VIA_WAIT_IRQ", _IOC_READ|_IOC_WRITE, 0x644d, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_EXECBUFFER", _IOC_WRITE, 0x6442, 0x20 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GETPARAM", _IOC_READ|_IOC_WRITE, 0x6443, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x6449, 0x18 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_MAP", _IOC_READ|_IOC_WRITE, 0x6441, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_CREATE", _IOC_READ|_IOC_WRITE, 0x6444, 0x38 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_RESOURCE_INFO", _IOC_READ|_IOC_WRITE, 0x6445, 0x10 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_FROM_HOST", _IOC_READ|_IOC_WRITE, 0x6446, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_TRANSFER_TO_HOST", _IOC_READ|_IOC_WRITE, 0x6447, 0x24 },
+{ "drm/virtgpu_drm.h", "DRM_IOCTL_VIRTGPU_WAIT", _IOC_READ|_IOC_WRITE, 0x6448, 0x08 },
+{ "linux/agpgart.h", "AGPIOC_ACQUIRE", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x4106, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_BIND", _IOC_WRITE, 0x4108, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_CHIPSET_FLUSH", _IOC_NONE, 0x410a, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_DEALLOCATE", _IOC_WRITE, 0x4107, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_INFO", _IOC_READ, 0x4100, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_PROTECT", _IOC_WRITE, 0x4105, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_RELEASE", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/agpgart.h", "AGPIOC_RESERVE", _IOC_WRITE, 0x4104, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_SETUP", _IOC_WRITE, 0x4103, 0x04 },
+{ "linux/agpgart.h", "AGPIOC_UNBIND", _IOC_WRITE, 0x4109, 0x04 },
+{ "linux/am437x-vpfe.h", "VIDIOC_AM437X_CCDC_CFG", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/android/binder.h", "BC_ACQUIRE_DONE", _IOC_WRITE, 0x6309, 0x10 },
+{ "linux/android/binder.h", "BC_ACQUIRE_RESULT", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/android/binder.h", "BC_ATTEMPT_ACQUIRE", _IOC_WRITE, 0x630a, 0x08 },
+{ "linux/android/binder.h", "BC_CLEAR_DEATH_NOTIFICATION", _IOC_WRITE, 0x630f, 0x0c },
+{ "linux/android/binder.h", "BC_DEAD_BINDER_DONE", _IOC_WRITE, 0x6310, 0x08 },
+{ "linux/android/binder.h", "BC_DECREFS", _IOC_WRITE, 0x6307, 0x04 },
+{ "linux/android/binder.h", "BC_ENTER_LOOPER", _IOC_NONE, 0x630c, 0x00 },
+{ "linux/android/binder.h", "BC_EXIT_LOOPER", _IOC_NONE, 0x630d, 0x00 },
+{ "linux/android/binder.h", "BC_FREE_BUFFER", _IOC_WRITE, 0x6303, 0x08 },
+{ "linux/android/binder.h", "BC_INCREFS", _IOC_WRITE, 0x6304, 0x04 },
+{ "linux/android/binder.h", "BC_INCREFS_DONE", _IOC_WRITE, 0x6308, 0x10 },
+{ "linux/android/binder.h", "BC_REGISTER_LOOPER", _IOC_NONE, 0x630b, 0x00 },
+{ "linux/android/binder.h", "BC_RELEASE", _IOC_WRITE, 0x6306, 0x04 },
+{ "linux/android/binder.h", "BC_REPLY", _IOC_WRITE, 0x6301, 0x40 },
+{ "linux/android/binder.h", "BC_REQUEST_DEATH_NOTIFICATION", _IOC_WRITE, 0x630e, 0x0c },
+{ "linux/android/binder.h", "BC_TRANSACTION", _IOC_WRITE, 0x6300, 0x40 },
+{ "linux/android/binder.h", "BINDER_SET_CONTEXT_MGR", _IOC_WRITE, 0x6207, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_PRIORITY", _IOC_WRITE, 0x6206, 0x04 },
+{ "linux/android/binder.h", "BINDER_SET_IDLE_TIMEOUT", _IOC_WRITE, 0x6203, 0x08 },
+{ "linux/android/binder.h", "BINDER_SET_MAX_THREADS", _IOC_WRITE, 0x6205, 0x04 },
+{ "linux/android/binder.h", "BINDER_THREAD_EXIT", _IOC_WRITE, 0x6208, 0x04 },
+{ "linux/android/binder.h", "BINDER_VERSION", _IOC_READ|_IOC_WRITE, 0x6209, 0x04 },
+{ "linux/android/binder.h", "BINDER_WRITE_READ", _IOC_READ|_IOC_WRITE, 0x6201, 0x30 },
+{ "linux/android/binder.h", "BR_ACQUIRE", _IOC_READ, 0x7208, 0x10 },
+{ "linux/android/binder.h", "BR_ACQUIRE_RESULT", _IOC_READ, 0x7204, 0x04 },
+{ "linux/android/binder.h", "BR_ATTEMPT_ACQUIRE", _IOC_READ, 0x720b, 0x18 },
+{ "linux/android/binder.h", "BR_CLEAR_DEATH_NOTIFICATION_DONE", _IOC_READ, 0x7210, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_BINDER", _IOC_READ, 0x720f, 0x08 },
+{ "linux/android/binder.h", "BR_DEAD_REPLY", _IOC_NONE, 0x7205, 0x00 },
+{ "linux/android/binder.h", "BR_DECREFS", _IOC_READ, 0x720a, 0x10 },
+{ "linux/android/binder.h", "BR_ERROR", _IOC_READ, 0x7200, 0x04 },
+{ "linux/android/binder.h", "BR_FAILED_REPLY", _IOC_NONE, 0x7211, 0x00 },
+{ "linux/android/binder.h", "BR_FINISHED", _IOC_NONE, 0x720e, 0x00 },
+{ "linux/android/binder.h", "BR_INCREFS", _IOC_READ, 0x7207, 0x10 },
+{ "linux/android/binder.h", "BR_NOOP", _IOC_NONE, 0x720c, 0x00 },
+{ "linux/android/binder.h", "BR_OK", _IOC_NONE, 0x7201, 0x00 },
+{ "linux/android/binder.h", "BR_RELEASE", _IOC_READ, 0x7209, 0x10 },
+{ "linux/android/binder.h", "BR_REPLY", _IOC_READ, 0x7203, 0x40 },
+{ "linux/android/binder.h", "BR_SPAWN_LOOPER", _IOC_NONE, 0x720d, 0x00 },
+{ "linux/android/binder.h", "BR_TRANSACTION", _IOC_READ, 0x7202, 0x40 },
+{ "linux/android/binder.h", "BR_TRANSACTION_COMPLETE", _IOC_NONE, 0x7206, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_STANDBY", _IOC_NONE, 0x4101, 0x00 },
+{ "linux/apm_bios.h", "APM_IOC_SUSPEND", _IOC_NONE, 0x4102, 0x00 },
+{ "linux/arcfb.h", "FBIO_GETCONTROL2", _IOC_READ, 0x4689, 0x04 },
+{ "linux/arcfb.h", "FBIO_WAITEVENT", _IOC_NONE, 0x4688, 0x00 },
+{ "linux/atm_eni.h", "ENI_MEMDUMP", _IOC_WRITE, 0x6160, 0x0c },
+{ "linux/atm_eni.h", "ENI_SETMULT", _IOC_WRITE, 0x6167, 0x0c },
+{ "linux/atm_he.h", "HE_GET_REG", _IOC_WRITE, 0x6160, 0x0c },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTAT", _IOC_WRITE, 0x6132, 0x0c },
+{ "linux/atm_idt77105.h", "IDT77105_GETSTATZ", _IOC_WRITE, 0x6133, 0x0c },
+{ "linux/atm_nicstar.h", "NS_ADJBUFLEV", _IOC_NONE, 0x6163, 0x00 },
+{ "linux/atm_nicstar.h", "NS_GETPSTAT", _IOC_READ|_IOC_WRITE, 0x6161, 0x0c },
+{ "linux/atm_nicstar.h", "NS_SETBUFLEV", _IOC_WRITE, 0x6162, 0x0c },
+{ "linux/atm_tcp.h", "ATMTCP_CREATE", _IOC_NONE, 0x618e, 0x00 },
+{ "linux/atm_tcp.h", "ATMTCP_REMOVE", _IOC_NONE, 0x618f, 0x00 },
+{ "linux/atm_tcp.h", "SIOCSIFATMTCP", _IOC_NONE, 0x6180, 0x00 },
+{ "linux/atm_zatm.h", "ZATM_GETPOOL", _IOC_WRITE, 0x6161, 0x0c },
+{ "linux/atm_zatm.h", "ZATM_GETPOOLZ", _IOC_WRITE, 0x6162, 0x0c },
+{ "linux/atm_zatm.h", "ZATM_SETPOOL", _IOC_WRITE, 0x6163, 0x0c },
+{ "linux/atmarp.h", "ATMARPD_CTRL", _IOC_NONE, 0x61e1, 0x00 },
+{ "linux/atmarp.h", "ATMARP_ENCAP", _IOC_NONE, 0x61e5, 0x00 },
+{ "linux/atmarp.h", "ATMARP_MKIP", _IOC_NONE, 0x61e2, 0x00 },
+{ "linux/atmarp.h", "ATMARP_SETENTRY", _IOC_NONE, 0x61e3, 0x00 },
+{ "linux/atmbr2684.h", "BR2684_SETFILT", _IOC_WRITE, 0x6190, 0x1c },
+{ "linux/atmclip.h", "SIOCMKCLIP", _IOC_NONE, 0x61e0, 0x00 },
+{ "linux/atmdev.h", "ATM_ADDADDR", _IOC_WRITE, 0x6188, 0x0c },
+{ "linux/atmdev.h", "ATM_ADDLECSADDR", _IOC_WRITE, 0x618e, 0x0c },
+{ "linux/atmdev.h", "ATM_ADDPARTY", _IOC_WRITE, 0x61f4, 0x08 },
+{ "linux/atmdev.h", "ATM_DELADDR", _IOC_WRITE, 0x6189, 0x0c },
+{ "linux/atmdev.h", "ATM_DELLECSADDR", _IOC_WRITE, 0x618f, 0x0c },
+{ "linux/atmdev.h", "ATM_DROPPARTY", _IOC_WRITE, 0x61f5, 0x04 },
+{ "linux/atmdev.h", "ATM_GETADDR", _IOC_WRITE, 0x6186, 0x0c },
+{ "linux/atmdev.h", "ATM_GETCIRANGE", _IOC_WRITE, 0x618a, 0x0c },
+{ "linux/atmdev.h", "ATM_GETESI", _IOC_WRITE, 0x6185, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLECSADDR", _IOC_WRITE, 0x6190, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLINKRATE", _IOC_WRITE, 0x6181, 0x0c },
+{ "linux/atmdev.h", "ATM_GETLOOP", _IOC_WRITE, 0x6152, 0x0c },
+{ "linux/atmdev.h", "ATM_GETNAMES", _IOC_WRITE, 0x6183, 0x08 },
+{ "linux/atmdev.h", "ATM_GETSTAT", _IOC_WRITE, 0x6150, 0x0c },
+{ "linux/atmdev.h", "ATM_GETSTATZ", _IOC_WRITE, 0x6151, 0x0c },
+{ "linux/atmdev.h", "ATM_GETTYPE", _IOC_WRITE, 0x6184, 0x0c },
+{ "linux/atmdev.h", "ATM_NEWBACKENDIF", _IOC_WRITE, 0x61f3, 0x02 },
+{ "linux/atmdev.h", "ATM_QUERYLOOP", _IOC_WRITE, 0x6154, 0x0c },
+{ "linux/atmdev.h", "ATM_RSTADDR", _IOC_WRITE, 0x6187, 0x0c },
+{ "linux/atmdev.h", "ATM_SETBACKEND", _IOC_WRITE, 0x61f2, 0x02 },
+{ "linux/atmdev.h", "ATM_SETCIRANGE", _IOC_WRITE, 0x618b, 0x0c },
+{ "linux/atmdev.h", "ATM_SETESI", _IOC_WRITE, 0x618c, 0x0c },
+{ "linux/atmdev.h", "ATM_SETESIF", _IOC_WRITE, 0x618d, 0x0c },
+{ "linux/atmdev.h", "ATM_SETLOOP", _IOC_WRITE, 0x6153, 0x0c },
+{ "linux/atmdev.h", "ATM_SETSC", _IOC_WRITE, 0x61f1, 0x04 },
+{ "linux/atmlec.h", "ATMLEC_CTRL", _IOC_NONE, 0x61d0, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_DATA", _IOC_NONE, 0x61d1, 0x00 },
+{ "linux/atmlec.h", "ATMLEC_MCAST", _IOC_NONE, 0x61d2, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_CTRL", _IOC_NONE, 0x61d8, 0x00 },
+{ "linux/atmmpc.h", "ATMMPC_DATA", _IOC_NONE, 0x61d9, 0x00 },
+{ "linux/atmsvc.h", "ATMSIGD_CTRL", _IOC_NONE, 0x61f0, 0x00 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ASKUMOUNT", _IOC_READ|_IOC_WRITE, 0x937d, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CATATONIC", _IOC_READ|_IOC_WRITE, 0x9379, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_CLOSEMOUNT", _IOC_READ|_IOC_WRITE, 0x9375, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_EXPIRE", _IOC_READ|_IOC_WRITE, 0x937c, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_FAIL", _IOC_READ|_IOC_WRITE, 0x9377, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_ISMOUNTPOINT", _IOC_READ|_IOC_WRITE, 0x937e, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_OPENMOUNT", _IOC_READ|_IOC_WRITE, 0x9374, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOSUBVER", _IOC_READ|_IOC_WRITE, 0x9373, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_PROTOVER", _IOC_READ|_IOC_WRITE, 0x9372, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_READY", _IOC_READ|_IOC_WRITE, 0x9376, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_REQUESTER", _IOC_READ|_IOC_WRITE, 0x937b, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_SETPIPEFD", _IOC_READ|_IOC_WRITE, 0x9378, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_TIMEOUT", _IOC_READ|_IOC_WRITE, 0x937a, 0x18 },
+{ "linux/auto_dev-ioctl.h", "AUTOFS_DEV_IOCTL_VERSION", _IOC_READ|_IOC_WRITE, 0x9371, 0x18 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_CATATONIC", _IOC_NONE, 0x9362, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_EXPIRE", _IOC_READ, 0x9365, 0x10c },
+{ "linux/auto_fs.h", "AUTOFS_IOC_FAIL", _IOC_NONE, 0x9361, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_PROTOVER", _IOC_READ, 0x9363, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_READY", _IOC_NONE, 0x9360, 0x00 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs.h", "AUTOFS_IOC_SETTIMEOUT32", _IOC_READ|_IOC_WRITE, 0x9364, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_ASKUMOUNT", _IOC_READ, 0x9370, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_EXPIRE_MULTI", _IOC_WRITE, 0x9366, 0x04 },
+{ "linux/auto_fs4.h", "AUTOFS_IOC_PROTOSUBVER", _IOC_READ, 0x9367, 0x04 },
+{ "linux/blkpg.h", "BLKPG", _IOC_NONE, 0x1269, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_ADD_DEV", _IOC_WRITE, 0x940a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE", _IOC_WRITE, 0x940c, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_CTL", _IOC_WRITE, 0x9421, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_PROGRESS", _IOC_READ, 0x9422, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_BALANCE_V2", _IOC_READ|_IOC_WRITE, 0x9420, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/btrfs.h", "BTRFS_IOC_CLONE_RANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFAULT_SUBVOL", _IOC_WRITE, 0x9413, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG", _IOC_WRITE, 0x9402, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEFRAG_RANGE", _IOC_WRITE, 0x9410, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEVICES_READY", _IOC_READ, 0x9427, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_INFO", _IOC_READ|_IOC_WRITE, 0x941e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_DEV_REPLACE", _IOC_READ|_IOC_WRITE, 0x9435, 0xa28 },
+{ "linux/btrfs.h", "BTRFS_IOC_FILE_EXTENT_SAME", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_FS_INFO", _IOC_READ, 0x941f, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_DEV_STATS", _IOC_READ|_IOC_WRITE, 0x9434, 0x408 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FEATURES", _IOC_READ, 0x9439, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_FSLABEL", _IOC_READ, 0x9431, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_GET_SUPPORTED_FEATURES", _IOC_READ, 0x9439, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_LOOKUP", _IOC_READ|_IOC_WRITE, 0x9412, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_INO_PATHS", _IOC_READ|_IOC_WRITE, 0x9423, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_LOGICAL_INO", _IOC_READ|_IOC_WRITE, 0x9424, 0x38 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_ASSIGN", _IOC_WRITE, 0x9429, 0x18 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_CREATE", _IOC_WRITE, 0x942a, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QGROUP_LIMIT", _IOC_READ, 0x942b, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_CTL", _IOC_READ|_IOC_WRITE, 0x9428, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN", _IOC_WRITE, 0x942c, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_STATUS", _IOC_READ, 0x942d, 0x40 },
+{ "linux/btrfs.h", "BTRFS_IOC_QUOTA_RESCAN_WAIT", _IOC_NONE, 0x942e, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_RESIZE", _IOC_WRITE, 0x9403, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV", _IOC_WRITE, 0x940b, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_RM_DEV_V2", _IOC_WRITE, 0x943a, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCAN_DEV", _IOC_WRITE, 0x9404, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB", _IOC_READ|_IOC_WRITE, 0x941b, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_CANCEL", _IOC_NONE, 0x941c, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_SCRUB_PROGRESS", _IOC_READ|_IOC_WRITE, 0x941d, 0x400 },
+{ "linux/btrfs.h", "BTRFS_IOC_SEND", _IOC_WRITE, 0x9426, 0x48 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FEATURES", _IOC_WRITE, 0x9439, 0x30 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_FSLABEL", _IOC_WRITE, 0x9432, 0x100 },
+{ "linux/btrfs.h", "BTRFS_IOC_SET_RECEIVED_SUBVOL", _IOC_READ|_IOC_WRITE, 0x9425, 0xc8 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE", _IOC_WRITE, 0x9401, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_CREATE_V2", _IOC_WRITE, 0x9417, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SNAP_DESTROY", _IOC_WRITE, 0x940f, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SPACE_INFO", _IOC_READ|_IOC_WRITE, 0x9414, 0x10 },
+{ "linux/btrfs.h", "BTRFS_IOC_START_SYNC", _IOC_READ, 0x9418, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE", _IOC_WRITE, 0x940e, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_CREATE_V2", _IOC_WRITE, 0x9418, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_GETFLAGS", _IOC_READ, 0x9419, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SUBVOL_SETFLAGS", _IOC_WRITE, 0x941a, 0x08 },
+{ "linux/btrfs.h", "BTRFS_IOC_SYNC", _IOC_NONE, 0x9408, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_END", _IOC_NONE, 0x9407, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TRANS_START", _IOC_NONE, 0x9406, 0x00 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH", _IOC_READ|_IOC_WRITE, 0x9411, 0x1000 },
+{ "linux/btrfs.h", "BTRFS_IOC_TREE_SEARCH_V2", _IOC_READ|_IOC_WRITE, 0x9411, 0x70 },
+{ "linux/btrfs.h", "BTRFS_IOC_WAIT_SYNC", _IOC_WRITE, 0x9416, 0x08 },
+{ "linux/capi.h", "CAPI_CLR_FLAGS", _IOC_READ, 0x4325, 0x04 },
+{ "linux/capi.h", "CAPI_GET_ERRCODE", _IOC_READ, 0x4321, 0x02 },
+{ "linux/capi.h", "CAPI_GET_FLAGS", _IOC_READ, 0x4323, 0x04 },
+{ "linux/capi.h", "CAPI_GET_MANUFACTURER", _IOC_READ|_IOC_WRITE, 0x4306, 0x04 },
+{ "linux/capi.h", "CAPI_GET_PROFILE", _IOC_READ|_IOC_WRITE, 0x4309, 0x40 },
+{ "linux/capi.h", "CAPI_GET_SERIAL", _IOC_READ|_IOC_WRITE, 0x4308, 0x04 },
+{ "linux/capi.h", "CAPI_GET_VERSION", _IOC_READ|_IOC_WRITE, 0x4307, 0x10 },
+{ "linux/capi.h", "CAPI_INSTALLED", _IOC_READ, 0x4322, 0x02 },
+{ "linux/capi.h", "CAPI_MANUFACTURER_CMD", _IOC_READ|_IOC_WRITE, 0x4320, 0x08 },
+{ "linux/capi.h", "CAPI_NCCI_GETUNIT", _IOC_READ, 0x4327, 0x04 },
+{ "linux/capi.h", "CAPI_NCCI_OPENCOUNT", _IOC_READ, 0x4326, 0x04 },
+{ "linux/capi.h", "CAPI_REGISTER", _IOC_WRITE, 0x4301, 0x0c },
+{ "linux/capi.h", "CAPI_SET_FLAGS", _IOC_READ, 0x4324, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_BIG_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x4212, 0x58 },
+{ "linux/cciss_ioctl.h", "CCISS_DEREGDISK", _IOC_NONE, 0x420c, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_GETBUSTYPES", _IOC_READ, 0x4207, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETDRIVVER", _IOC_READ, 0x4209, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETFIRMVER", _IOC_READ, 0x4208, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETHEARTBEAT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_GETINTINFO", _IOC_READ, 0x4202, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_GETLUNINFO", _IOC_READ, 0x4211, 0x0c },
+{ "linux/cciss_ioctl.h", "CCISS_GETNODENAME", _IOC_READ, 0x4204, 0x10 },
+{ "linux/cciss_ioctl.h", "CCISS_GETPCIINFO", _IOC_READ, 0x4201, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_PASSTHRU", _IOC_READ|_IOC_WRITE, 0x420b, 0x54 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWD", _IOC_NONE, 0x420e, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REGNEWDISK", _IOC_WRITE, 0x420d, 0x04 },
+{ "linux/cciss_ioctl.h", "CCISS_RESCANDISK", _IOC_NONE, 0x4210, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_REVALIDVOLS", _IOC_NONE, 0x420a, 0x00 },
+{ "linux/cciss_ioctl.h", "CCISS_SETINTINFO", _IOC_WRITE, 0x4203, 0x08 },
+{ "linux/cciss_ioctl.h", "CCISS_SETNODENAME", _IOC_WRITE, 0x4205, 0x10 },
+{ "linux/cdrom.h", "CDROMAUDIOBUFSIZ", 0, 0x5382, 0 },
+{ "linux/cdrom.h", "CDROMCLOSETRAY", 0, 0x5319, 0 },
+{ "linux/cdrom.h", "CDROMEJECT", 0, 0x5309, 0 },
+{ "linux/cdrom.h", "CDROMEJECT_SW", 0, 0x530f, 0 },
+{ "linux/cdrom.h", "CDROMGETSPINDOWN", 0, 0x531d, 0 },
+{ "linux/cdrom.h", "CDROMMULTISESSION", 0, 0x5310, 0 },
+{ "linux/cdrom.h", "CDROMPAUSE", 0, 0x5301, 0 },
+{ "linux/cdrom.h", "CDROMPLAYBLK", 0, 0x5317, 0 },
+{ "linux/cdrom.h", "CDROMPLAYMSF", 0, 0x5303, 0 },
+{ "linux/cdrom.h", "CDROMPLAYTRKIND", 0, 0x5304, 0 },
+{ "linux/cdrom.h", "CDROMREADALL", 0, 0x5318, 0 },
+{ "linux/cdrom.h", "CDROMREADAUDIO", 0, 0x530e, 0 },
+{ "linux/cdrom.h", "CDROMREADCOOKED", 0, 0x5315, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE1", 0, 0x530d, 0 },
+{ "linux/cdrom.h", "CDROMREADMODE2", 0, 0x530c, 0 },
+{ "linux/cdrom.h", "CDROMREADRAW", 0, 0x5314, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCENTRY", 0, 0x5306, 0 },
+{ "linux/cdrom.h", "CDROMREADTOCHDR", 0, 0x5305, 0 },
+{ "linux/cdrom.h", "CDROMRESET", 0, 0x5312, 0 },
+{ "linux/cdrom.h", "CDROMRESUME", 0, 0x5302, 0 },
+{ "linux/cdrom.h", "CDROMSEEK", 0, 0x5316, 0 },
+{ "linux/cdrom.h", "CDROMSETSPINDOWN", 0, 0x531e, 0 },
+{ "linux/cdrom.h", "CDROMSTART", 0, 0x5308, 0 },
+{ "linux/cdrom.h", "CDROMSTOP", 0, 0x5307, 0 },
+{ "linux/cdrom.h", "CDROMSUBCHNL", 0, 0x530b, 0 },
+{ "linux/cdrom.h", "CDROMVOLCTRL", 0, 0x530a, 0 },
+{ "linux/cdrom.h", "CDROMVOLREAD", 0, 0x5313, 0 },
+{ "linux/cdrom.h", "CDROM_CHANGER_NSLOTS", 0, 0x5328, 0 },
+{ "linux/cdrom.h", "CDROM_CLEAR_OPTIONS", 0, 0x5321, 0 },
+{ "linux/cdrom.h", "CDROM_DEBUG", 0, 0x5330, 0 },
+{ "linux/cdrom.h", "CDROM_DISC_STATUS", 0, 0x5327, 0 },
+{ "linux/cdrom.h", "CDROM_DRIVE_STATUS", 0, 0x5326, 0 },
+{ "linux/cdrom.h", "CDROM_GET_CAPABILITY", 0, 0x5331, 0 },
+{ "linux/cdrom.h", "CDROM_GET_MCN", 0, 0x5311, 0 },
+{ "linux/cdrom.h", "CDROM_LAST_WRITTEN", 0, 0x5395, 0 },
+{ "linux/cdrom.h", "CDROM_LOCKDOOR", 0, 0x5329, 0 },
+{ "linux/cdrom.h", "CDROM_MEDIA_CHANGED", 0, 0x5325, 0 },
+{ "linux/cdrom.h", "CDROM_NEXT_WRITABLE", 0, 0x5394, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_DISC", 0, 0x5323, 0 },
+{ "linux/cdrom.h", "CDROM_SELECT_SPEED", 0, 0x5322, 0 },
+{ "linux/cdrom.h", "CDROM_SEND_PACKET", 0, 0x5393, 0 },
+{ "linux/cdrom.h", "CDROM_SET_OPTIONS", 0, 0x5320, 0 },
+{ "linux/cdrom.h", "DVD_AUTH", 0, 0x5392, 0 },
+{ "linux/cdrom.h", "DVD_READ_STRUCT", 0, 0x5390, 0 },
+{ "linux/cdrom.h", "DVD_WRITE_STRUCT", 0, 0x5391, 0 },
+{ "linux/chio.h", "CHIOEXCHANGE", _IOC_WRITE, 0x6302, 0x1c },
+{ "linux/chio.h", "CHIOGELEM", _IOC_WRITE, 0x6310, 0x6c },
+{ "linux/chio.h", "CHIOGPARAMS", _IOC_READ, 0x6306, 0x14 },
+{ "linux/chio.h", "CHIOGPICKER", _IOC_READ, 0x6304, 0x04 },
+{ "linux/chio.h", "CHIOGSTATUS", _IOC_WRITE, 0x6308, 0x08 },
+{ "linux/chio.h", "CHIOGVPARAMS", _IOC_READ, 0x6313, 0x70 },
+{ "linux/chio.h", "CHIOINITELEM", _IOC_NONE, 0x6311, 0x00 },
+{ "linux/chio.h", "CHIOMOVE", _IOC_WRITE, 0x6301, 0x14 },
+{ "linux/chio.h", "CHIOPOSITION", _IOC_WRITE, 0x6303, 0x0c },
+{ "linux/chio.h", "CHIOSPICKER", _IOC_WRITE, 0x6305, 0x04 },
+{ "linux/chio.h", "CHIOSVOLTAG", _IOC_WRITE, 0x6312, 0x30 },
+{ "linux/cm4000_cs.h", "CM_IOCARDOFF", _IOC_NONE, 0x6304, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOCGATR", _IOC_READ|_IOC_WRITE, 0x6301, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCGSTATUS", _IOC_READ, 0x6300, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCSPTS", _IOC_WRITE, 0x6302, 0x04 },
+{ "linux/cm4000_cs.h", "CM_IOCSRDR", _IOC_NONE, 0x6303, 0x00 },
+{ "linux/cm4000_cs.h", "CM_IOSDBGLVL", _IOC_WRITE, 0x63fa, 0x04 },
+{ "linux/coda.h", "CIOC_KERNEL_VERSION", _IOC_READ|_IOC_WRITE, 0x630a, 0x04 },
+{ "linux/dm-ioctl.h", "DM_DEV_CREATE", _IOC_READ|_IOC_WRITE, 0xfd03, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_REMOVE", _IOC_READ|_IOC_WRITE, 0xfd04, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_RENAME", _IOC_READ|_IOC_WRITE, 0xfd05, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SET_GEOMETRY", _IOC_READ|_IOC_WRITE, 0xfd0f, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_STATUS", _IOC_READ|_IOC_WRITE, 0xfd07, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_SUSPEND", _IOC_READ|_IOC_WRITE, 0xfd06, 0x138 },
+{ "linux/dm-ioctl.h", "DM_DEV_WAIT", _IOC_READ|_IOC_WRITE, 0xfd08, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_DEVICES", _IOC_READ|_IOC_WRITE, 0xfd02, 0x138 },
+{ "linux/dm-ioctl.h", "DM_LIST_VERSIONS", _IOC_READ|_IOC_WRITE, 0xfd0d, 0x138 },
+{ "linux/dm-ioctl.h", "DM_REMOVE_ALL", _IOC_READ|_IOC_WRITE, 0xfd01, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_CLEAR", _IOC_READ|_IOC_WRITE, 0xfd0a, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_DEPS", _IOC_READ|_IOC_WRITE, 0xfd0b, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_LOAD", _IOC_READ|_IOC_WRITE, 0xfd09, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TABLE_STATUS", _IOC_READ|_IOC_WRITE, 0xfd0c, 0x138 },
+{ "linux/dm-ioctl.h", "DM_TARGET_MSG", _IOC_READ|_IOC_WRITE, 0xfd0e, 0x138 },
+{ "linux/dm-ioctl.h", "DM_VERSION", _IOC_READ|_IOC_WRITE, 0xfd00, 0x138 },
+{ "linux/dma-buf.h", "DMA_BUF_IOCTL_SYNC", _IOC_WRITE, 0x6200, 0x08 },
+{ "linux/dn.h", "OSIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "OSIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dn.h", "SIOCGNETADDR", _IOC_READ, 0x89e1, 0x04 },
+{ "linux/dn.h", "SIOCSNETADDR", _IOC_WRITE, 0x89e0, 0x04 },
+{ "linux/dvb/audio.h", "AUDIO_BILINGUAL_CHANNEL_SELECT", _IOC_NONE, 0x6f14, 0x00 },
+{ "linux/dvb/audio.h", "AUDIO_CHANNEL_SELECT", _IOC_NONE, 0x6f09, 0x00 },
+{ "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 },
+{ "linux/dvb/audio.h", "AUDIO_STOP", _IOC_NONE, 0x6f01, 0x00 },
+{ "linux/dvb/ca.h", "CA_GET_CAP", _IOC_READ, 0x6f81, 0x10 },
+{ "linux/dvb/ca.h", "CA_GET_DESCR_INFO", _IOC_READ, 0x6f83, 0x08 },
+{ "linux/dvb/ca.h", "CA_GET_MSG", _IOC_READ, 0x6f84, 0x10c },
+{ "linux/dvb/ca.h", "CA_GET_SLOT_INFO", _IOC_READ, 0x6f82, 0x0c },
+{ "linux/dvb/ca.h", "CA_RESET", _IOC_NONE, 0x6f80, 0x00 },
+{ "linux/dvb/ca.h", "CA_SEND_MSG", _IOC_WRITE, 0x6f85, 0x10c },
+{ "linux/dvb/ca.h", "CA_SET_DESCR", _IOC_WRITE, 0x6f86, 0x10 },
+{ "linux/dvb/ca.h", "CA_SET_PID", _IOC_WRITE, 0x6f87, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_ADD_PID", _IOC_WRITE, 0x6f33, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_GET_CAPS", _IOC_READ, 0x6f30, 0x08 },
+{ "linux/dvb/dmx.h", "DMX_GET_PES_PIDS", _IOC_READ, 0x6f2f, 0x0a },
+{ "linux/dvb/dmx.h", "DMX_GET_STC", _IOC_READ|_IOC_WRITE, 0x6f32, 0x10 },
+{ "linux/dvb/dmx.h", "DMX_REMOVE_PID", _IOC_WRITE, 0x6f34, 0x02 },
+{ "linux/dvb/dmx.h", "DMX_SET_BUFFER_SIZE", _IOC_NONE, 0x6f2d, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_SET_FILTER", _IOC_WRITE, 0x6f2b, 0x3c },
+{ "linux/dvb/dmx.h", "DMX_SET_PES_FILTER", _IOC_WRITE, 0x6f2c, 0x14 },
+{ "linux/dvb/dmx.h", "DMX_SET_SOURCE", _IOC_WRITE, 0x6f31, 0x04 },
+{ "linux/dvb/dmx.h", "DMX_START", _IOC_NONE, 0x6f29, 0x00 },
+{ "linux/dvb/dmx.h", "DMX_STOP", _IOC_NONE, 0x6f2a, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RECV_SLAVE_REPLY", _IOC_READ, 0x6f40, 0x0c },
+{ "linux/dvb/frontend.h", "FE_DISEQC_RESET_OVERLOAD", _IOC_NONE, 0x6f3e, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_BURST", _IOC_NONE, 0x6f41, 0x00 },
+{ "linux/dvb/frontend.h", "FE_DISEQC_SEND_MASTER_CMD", _IOC_WRITE, 0x6f3f, 0x07 },
+{ "linux/dvb/frontend.h", "FE_DISHNETWORK_SEND_LEGACY_CMD", _IOC_NONE, 0x6f50, 0x00 },
+{ "linux/dvb/frontend.h", "FE_ENABLE_HIGH_LNB_VOLTAGE", _IOC_NONE, 0x6f44, 0x00 },
+{ "linux/dvb/frontend.h", "FE_GET_EVENT", _IOC_READ, 0x6f4e, 0x28 },
+{ "linux/dvb/frontend.h", "FE_GET_FRONTEND", _IOC_READ, 0x6f4d, 0x24 },
+{ "linux/dvb/frontend.h", "FE_GET_INFO", _IOC_READ, 0x6f3d, 0xa8 },
+{ "linux/dvb/frontend.h", "FE_GET_PROPERTY", _IOC_READ, 0x6f53, 0x08 },
+{ "linux/dvb/frontend.h", "FE_READ_BER", _IOC_READ, 0x6f46, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_SIGNAL_STRENGTH", _IOC_READ, 0x6f47, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_SNR", _IOC_READ, 0x6f48, 0x02 },
+{ "linux/dvb/frontend.h", "FE_READ_STATUS", _IOC_READ, 0x6f45, 0x04 },
+{ "linux/dvb/frontend.h", "FE_READ_UNCORRECTED_BLOCKS", _IOC_READ, 0x6f49, 0x04 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND", _IOC_WRITE, 0x6f4c, 0x24 },
+{ "linux/dvb/frontend.h", "FE_SET_FRONTEND_TUNE_MODE", _IOC_NONE, 0x6f51, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_PROPERTY", _IOC_WRITE, 0x6f52, 0x08 },
+{ "linux/dvb/frontend.h", "FE_SET_TONE", _IOC_NONE, 0x6f42, 0x00 },
+{ "linux/dvb/frontend.h", "FE_SET_VOLTAGE", _IOC_NONE, 0x6f43, 0x00 },
+{ "linux/dvb/net.h", "NET_ADD_IF", _IOC_READ|_IOC_WRITE, 0x6f34, 0x06 },
+{ "linux/dvb/net.h", "NET_GET_IF", _IOC_READ|_IOC_WRITE, 0x6f36, 0x06 },
+{ "linux/dvb/net.h", "NET_REMOVE_IF", _IOC_NONE, 0x6f35, 0x00 },
+{ "linux/dvb/osd.h", "OSD_GET_CAPABILITY", _IOC_READ, 0x6fa1, 0x08 },
+{ "linux/dvb/osd.h", "OSD_SEND_CMD", _IOC_WRITE, 0x6fa0, 0x1c },
+{ "linux/dvb/video.h", "VIDEO_CLEAR_BUFFER", _IOC_NONE, 0x6f22, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3b, 0x48 },
+{ "linux/dvb/video.h", "VIDEO_CONTINUE", _IOC_NONE, 0x6f18, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FAST_FORWARD", _IOC_NONE, 0x6f1f, 0x00 },
+{ "linux/dvb/video.h", "VIDEO_FREEZE", _IOC_NONE, 0x6f17, 0x00 },
+{ "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, 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 },
+{ "linux/dvb/video.h", "VIDEO_TRY_COMMAND", _IOC_READ|_IOC_WRITE, 0x6f3c, 0x48 },
+{ "linux/fb.h", "FBIOBLANK", 0, 0x4611, 0 },
+{ "linux/fb.h", "FBIOGETCMAP", 0, 0x4604, 0 },
+{ "linux/fb.h", "FBIOGET_CON2FBMAP", 0, 0x460F, 0 },
+{ "linux/fb.h", "FBIOGET_DISPINFO", 0, 0x4618, 0 },
+{ "linux/fb.h", "FBIOGET_FSCREENINFO", 0, 0x4602, 0 },
+{ "linux/fb.h", "FBIOGET_GLYPH", 0, 0x4615, 0 },
+{ "linux/fb.h", "FBIOGET_HWCINFO", 0, 0x4616, 0 },
+{ "linux/fb.h", "FBIOGET_VBLANK", _IOC_READ, 0x4612, 0x20 },
+{ "linux/fb.h", "FBIOGET_VSCREENINFO", 0, 0x4600, 0 },
+{ "linux/fb.h", "FBIOPAN_DISPLAY", 0, 0x4606, 0 },
+{ "linux/fb.h", "FBIOPUTCMAP", 0, 0x4605, 0 },
+{ "linux/fb.h", "FBIOPUT_CON2FBMAP", 0, 0x4610, 0 },
+{ "linux/fb.h", "FBIOPUT_MODEINFO", 0, 0x4617, 0 },
+{ "linux/fb.h", "FBIOPUT_VSCREENINFO", 0, 0x4601, 0 },
+{ "linux/fb.h", "FBIO_ALLOC", 0, 0x4613, 0 },
+{ "linux/fb.h", "FBIO_CURSOR", _IOC_READ|_IOC_WRITE, 0x4608, 0x48 },
+{ "linux/fb.h", "FBIO_FREE", 0, 0x4614, 0 },
+{ "linux/fb.h", "FBIO_WAITFORVSYNC", _IOC_WRITE, 0x4620, 0x04 },
+{ "linux/fd.h", "FDCLRPRM", _IOC_NONE, 0x0241, 0x00 },
+{ "linux/fd.h", "FDDEFPRM", _IOC_WRITE, 0x0243, 0x1c },
+{ "linux/fd.h", "FDEJECT", _IOC_NONE, 0x025a, 0x00 },
+{ "linux/fd.h", "FDFLUSH", _IOC_NONE, 0x024b, 0x00 },
+{ "linux/fd.h", "FDFMTBEG", _IOC_NONE, 0x0247, 0x00 },
+{ "linux/fd.h", "FDFMTEND", _IOC_NONE, 0x0249, 0x00 },
+{ "linux/fd.h", "FDFMTTRK", _IOC_WRITE, 0x0248, 0x0c },
+{ "linux/fd.h", "FDGETDRVPRM", _IOC_READ, 0x0211, 0x58 },
+{ "linux/fd.h", "FDGETDRVSTAT", _IOC_READ, 0x0212, 0x34 },
+{ "linux/fd.h", "FDGETDRVTYP", _IOC_READ, 0x020f, 0x10 },
+{ "linux/fd.h", "FDGETFDCSTAT", _IOC_READ, 0x0215, 0x20 },
+{ "linux/fd.h", "FDGETMAXERRS", _IOC_READ, 0x020e, 0x14 },
+{ "linux/fd.h", "FDGETPRM", _IOC_READ, 0x0204, 0x1c },
+{ "linux/fd.h", "FDMSGOFF", _IOC_NONE, 0x0246, 0x00 },
+{ "linux/fd.h", "FDMSGON", _IOC_NONE, 0x0245, 0x00 },
+{ "linux/fd.h", "FDPOLLDRVSTAT", _IOC_READ, 0x0213, 0x34 },
+{ "linux/fd.h", "FDRAWCMD", _IOC_NONE, 0x0258, 0x00 },
+{ "linux/fd.h", "FDRESET", _IOC_NONE, 0x0254, 0x00 },
+{ "linux/fd.h", "FDSETDRVPRM", _IOC_WRITE, 0x0290, 0x58 },
+{ "linux/fd.h", "FDSETEMSGTRESH", _IOC_NONE, 0x024a, 0x00 },
+{ "linux/fd.h", "FDSETMAXERRS", _IOC_WRITE, 0x024c, 0x14 },
+{ "linux/fd.h", "FDSETPRM", _IOC_WRITE, 0x0242, 0x1c },
+{ "linux/fd.h", "FDTWADDLE", _IOC_NONE, 0x0259, 0x00 },
+{ "linux/fd.h", "FDWERRORCLR", _IOC_NONE, 0x0256, 0x00 },
+{ "linux/fd.h", "FDWERRORGET", _IOC_READ, 0x0217, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ADD_DESCRIPTOR", _IOC_READ|_IOC_WRITE, 0x2306, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE", _IOC_READ|_IOC_WRITE, 0x2302, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE", _IOC_READ|_IOC_WRITE, 0x230d, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x230f, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_CREATE_ISO_CONTEXT", _IOC_READ|_IOC_WRITE, 0x2308, 0x20 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE", _IOC_WRITE, 0x2303, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE", _IOC_WRITE, 0x230e, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE", _IOC_WRITE, 0x2310, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_FLUSH_ISO", _IOC_WRITE, 0x2318, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER", _IOC_READ, 0x230c, 0x10 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_CYCLE_TIMER2", _IOC_READ|_IOC_WRITE, 0x2314, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_INFO", _IOC_READ|_IOC_WRITE, 0x2300, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_GET_SPEED", _IOC_NONE, 0x2311, 0x00 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_INITIATE_BUS_RESET", _IOC_WRITE, 0x2305, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_QUEUE_ISO", _IOC_READ|_IOC_WRITE, 0x2309, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_RECEIVE_PHY_PACKETS", _IOC_WRITE, 0x2316, 0x08 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_REMOVE_DESCRIPTOR", _IOC_WRITE, 0x2307, 0x04 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_BROADCAST_REQUEST", _IOC_WRITE, 0x2312, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_PHY_PACKET", _IOC_READ|_IOC_WRITE, 0x2315, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_REQUEST", _IOC_WRITE, 0x2301, 0x28 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_RESPONSE", _IOC_WRITE, 0x2304, 0x18 },
+{ "linux/firewire-cdev.h", "FW_CDEV_IOC_SEND_STREAM_PACKET", _IOC_WRITE, 0x2313, 0x28 },
+{ "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/fs.h", "BLKALIGNOFF", _IOC_NONE, 0x127a, 0x00 },
+{ "linux/fs.h", "BLKBSZGET", _IOC_READ, 0x1270, 0x04 },
+{ "linux/fs.h", "BLKBSZSET", _IOC_WRITE, 0x1271, 0x04 },
+{ "linux/fs.h", "BLKDISCARD", _IOC_NONE, 0x1277, 0x00 },
+{ "linux/fs.h", "BLKDISCARDZEROES", _IOC_NONE, 0x127c, 0x00 },
+{ "linux/fs.h", "BLKFLSBUF", _IOC_NONE, 0x1261, 0x00 },
+{ "linux/fs.h", "BLKFRAGET", _IOC_NONE, 0x1265, 0x00 },
+{ "linux/fs.h", "BLKFRASET", _IOC_NONE, 0x1264, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE", _IOC_NONE, 0x1260, 0x00 },
+{ "linux/fs.h", "BLKGETSIZE64", _IOC_READ, 0x1272, 0x04 },
+{ "linux/fs.h", "BLKIOMIN", _IOC_NONE, 0x1278, 0x00 },
+{ "linux/fs.h", "BLKIOOPT", _IOC_NONE, 0x1279, 0x00 },
+{ "linux/fs.h", "BLKPBSZGET", _IOC_NONE, 0x127b, 0x00 },
+{ "linux/fs.h", "BLKRAGET", _IOC_NONE, 0x1263, 0x00 },
+{ "linux/fs.h", "BLKRASET", _IOC_NONE, 0x1262, 0x00 },
+{ "linux/fs.h", "BLKROGET", _IOC_NONE, 0x125e, 0x00 },
+{ "linux/fs.h", "BLKROSET", _IOC_NONE, 0x125d, 0x00 },
+{ "linux/fs.h", "BLKROTATIONAL", _IOC_NONE, 0x127e, 0x00 },
+{ "linux/fs.h", "BLKRRPART", _IOC_NONE, 0x125f, 0x00 },
+{ "linux/fs.h", "BLKSECDISCARD", _IOC_NONE, 0x127d, 0x00 },
+{ "linux/fs.h", "BLKSECTGET", _IOC_NONE, 0x1267, 0x00 },
+{ "linux/fs.h", "BLKSECTSET", _IOC_NONE, 0x1266, 0x00 },
+{ "linux/fs.h", "BLKSSZGET", _IOC_NONE, 0x1268, 0x00 },
+{ "linux/fs.h", "BLKTRACESETUP", _IOC_READ|_IOC_WRITE, 0x1273, 0x48 },
+{ "linux/fs.h", "BLKTRACESTART", _IOC_NONE, 0x1274, 0x00 },
+{ "linux/fs.h", "BLKTRACESTOP", _IOC_NONE, 0x1275, 0x00 },
+{ "linux/fs.h", "BLKTRACETEARDOWN", _IOC_NONE, 0x1276, 0x00 },
+{ "linux/fs.h", "BLKZEROOUT", _IOC_NONE, 0x127f, 0x00 },
+{ "linux/fs.h", "FIBMAP", _IOC_NONE, 0x0001, 0x00 },
+{ "linux/fs.h", "FICLONE", _IOC_WRITE, 0x9409, 0x04 },
+{ "linux/fs.h", "FICLONERANGE", _IOC_WRITE, 0x940d, 0x20 },
+{ "linux/fs.h", "FIDEDUPERANGE", _IOC_READ|_IOC_WRITE, 0x9436, 0x18 },
+{ "linux/fs.h", "FIFREEZE", _IOC_READ|_IOC_WRITE, 0x5877, 0x04 },
+{ "linux/fs.h", "FIGETBSZ", _IOC_NONE, 0x0002, 0x00 },
+{ "linux/fs.h", "FITHAW", _IOC_READ|_IOC_WRITE, 0x5878, 0x04 },
+{ "linux/fs.h", "FITRIM", _IOC_READ|_IOC_WRITE, 0x5879, 0x18 },
+{ "linux/fs.h", "FS_IOC32_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC32_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_FIEMAP", _IOC_READ|_IOC_WRITE, 0x660b, 0x20 },
+{ "linux/fs.h", "FS_IOC_FSGETXATTR", _IOC_READ, 0x581f, 0x1c },
+{ "linux/fs.h", "FS_IOC_FSSETXATTR", _IOC_WRITE, 0x5820, 0x1c },
+{ "linux/fs.h", "FS_IOC_GETFLAGS", _IOC_READ, 0x6601, 0x04 },
+{ "linux/fs.h", "FS_IOC_GETVERSION", _IOC_READ, 0x7601, 0x04 },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_POLICY", _IOC_WRITE, 0x6615, 0x0c },
+{ "linux/fs.h", "FS_IOC_GET_ENCRYPTION_PWSALT", _IOC_WRITE, 0x6614, 0x10 },
+{ "linux/fs.h", "FS_IOC_SETFLAGS", _IOC_WRITE, 0x6602, 0x04 },
+{ "linux/fs.h", "FS_IOC_SETVERSION", _IOC_WRITE, 0x7602, 0x04 },
+{ "linux/fs.h", "FS_IOC_SET_ENCRYPTION_POLICY", _IOC_READ, 0x6613, 0x0c },
+{ "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 },
+{ "linux/fsl-diu-fb.h", "MFB_GET_PIXFMT", _IOC_READ, 0x4d08, 0x04 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_ALPHA", _IOC_WRITE, 0x4d00, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_AOID", _IOC_WRITE, 0x4d04, 0x08 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_BRIGHTNESS", _IOC_WRITE, 0x4d03, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_CHROMA_KEY", _IOC_WRITE, 0x4d01, 0x0c },
+{ "linux/fsl-diu-fb.h", "MFB_SET_GAMMA", _IOC_WRITE, 0x4d01, 0x01 },
+{ "linux/fsl-diu-fb.h", "MFB_SET_PIXFMT", _IOC_WRITE, 0x4d08, 0x04 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_DOORBELL", _IOC_READ|_IOC_WRITE, 0xaf06, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_GETPROP", _IOC_READ|_IOC_WRITE, 0xaf07, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_MEMCPY", _IOC_READ|_IOC_WRITE, 0xaf05, 0x28 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_GET_STATUS", _IOC_READ|_IOC_WRITE, 0xaf02, 0x0c },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_RESTART", _IOC_READ|_IOC_WRITE, 0xaf01, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_START", _IOC_READ|_IOC_WRITE, 0xaf03, 0x10 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_PARTITION_STOP", _IOC_READ|_IOC_WRITE, 0xaf04, 0x08 },
+{ "linux/fsl_hypervisor.h", "FSL_HV_IOCTL_SETPROP", _IOC_READ|_IOC_WRITE, 0xaf08, 0x28 },
+{ "linux/fuse.h", "FUSE_DEV_IOC_CLONE", _IOC_READ, 0xe500, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_DDCB", _IOC_READ|_IOC_WRITE, 0xa532, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_EXECUTE_RAW_DDCB", _IOC_READ|_IOC_WRITE, 0xa533, 0xe8 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_GET_CARD_STATE", _IOC_READ, 0xa524, 0x04 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_PIN_MEM", _IOC_READ|_IOC_WRITE, 0xa528, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG16", _IOC_READ, 0xa522, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG32", _IOC_READ, 0xa520, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_READ_REG64", _IOC_READ, 0xa51e, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_READ", _IOC_READ|_IOC_WRITE, 0xa551, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_SLU_UPDATE", _IOC_READ|_IOC_WRITE, 0xa550, 0x38 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_UNPIN_MEM", _IOC_READ|_IOC_WRITE, 0xa529, 0x20 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG16", _IOC_WRITE, 0xa523, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG32", _IOC_WRITE, 0xa521, 0x10 },
+{ "linux/genwqe/genwqe_card.h", "GENWQE_WRITE_REG64", _IOC_WRITE, 0xa51f, 0x10 },
+{ "linux/gigaset_dev.h", "GIGASET_BRKCHARS", _IOC_WRITE, 0x4702, 0x06 },
+{ "linux/gigaset_dev.h", "GIGASET_CONFIG", _IOC_READ|_IOC_WRITE, 0x4701, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_REDIR", _IOC_READ|_IOC_WRITE, 0x4700, 0x04 },
+{ "linux/gigaset_dev.h", "GIGASET_VERSION", _IOC_READ|_IOC_WRITE, 0x4703, 0x10 },
+{ "linux/gpio.h", "GPIO_GET_CHIPINFO_IOCTL", _IOC_READ, 0xb401, 0x44 },
+{ "linux/gpio.h", "GPIO_GET_LINEINFO_IOCTL", _IOC_READ|_IOC_WRITE, 0xb402, 0x48 },
+{ "linux/gsmmux.h", "GSMIOC_DISABLE_NET", _IOC_NONE, 0x4703, 0x00 },
+{ "linux/gsmmux.h", "GSMIOC_ENABLE_NET", _IOC_WRITE, 0x4702, 0x34 },
+{ "linux/gsmmux.h", "GSMIOC_GETCONF", _IOC_READ, 0x4700, 0x4c },
+{ "linux/gsmmux.h", "GSMIOC_SETCONF", _IOC_WRITE, 0x4701, 0x4c },
+{ "linux/hdreg.h", "HDIO_DRIVE_CMD", 0, 0x031f, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_RESET", 0, 0x031c, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASK", 0, 0x031e, 0 },
+{ "linux/hdreg.h", "HDIO_DRIVE_TASKFILE", 0, 0x031d, 0 },
+{ "linux/hdreg.h", "HDIO_GETGEO", 0, 0x0301, 0 },
+{ "linux/hdreg.h", "HDIO_GET_32BIT", 0, 0x0309, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ACOUSTIC", 0, 0x030f, 0 },
+{ "linux/hdreg.h", "HDIO_GET_ADDRESS", 0, 0x0310, 0 },
+{ "linux/hdreg.h", "HDIO_GET_BUSSTATE", 0, 0x031a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_DMA", 0, 0x030b, 0 },
+{ "linux/hdreg.h", "HDIO_GET_IDENTITY", 0, 0x030d, 0 },
+{ "linux/hdreg.h", "HDIO_GET_KEEPSETTINGS", 0, 0x0308, 0 },
+{ "linux/hdreg.h", "HDIO_GET_MULTCOUNT", 0, 0x0304, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NICE", 0, 0x030c, 0 },
+{ "linux/hdreg.h", "HDIO_GET_NOWERR", 0, 0x030a, 0 },
+{ "linux/hdreg.h", "HDIO_GET_QDMA", 0, 0x0305, 0 },
+{ "linux/hdreg.h", "HDIO_GET_UNMASKINTR", 0, 0x0302, 0 },
+{ "linux/hdreg.h", "HDIO_GET_WCACHE", 0, 0x030e, 0 },
+{ "linux/hdreg.h", "HDIO_OBSOLETE_IDENTITY", 0, 0x0307, 0 },
+{ "linux/hdreg.h", "HDIO_SCAN_HWIF", 0, 0x0328, 0 },
+{ "linux/hdreg.h", "HDIO_SET_32BIT", 0, 0x0324, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ACOUSTIC", 0, 0x032c, 0 },
+{ "linux/hdreg.h", "HDIO_SET_ADDRESS", 0, 0x032f, 0 },
+{ "linux/hdreg.h", "HDIO_SET_BUSSTATE", 0, 0x032d, 0 },
+{ "linux/hdreg.h", "HDIO_SET_DMA", 0, 0x0326, 0 },
+{ "linux/hdreg.h", "HDIO_SET_KEEPSETTINGS", 0, 0x0323, 0 },
+{ "linux/hdreg.h", "HDIO_SET_MULTCOUNT", 0, 0x0321, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NICE", 0, 0x0329, 0 },
+{ "linux/hdreg.h", "HDIO_SET_NOWERR", 0, 0x0325, 0 },
+{ "linux/hdreg.h", "HDIO_SET_PIO_MODE", 0, 0x0327, 0 },
+{ "linux/hdreg.h", "HDIO_SET_QDMA", 0, 0x032e, 0 },
+{ "linux/hdreg.h", "HDIO_SET_UNMASKINTR", 0, 0x0322, 0 },
+{ "linux/hdreg.h", "HDIO_SET_WCACHE", 0, 0x032b, 0 },
+{ "linux/hdreg.h", "HDIO_SET_XFER", 0, 0x0306, 0 },
+{ "linux/hdreg.h", "HDIO_TRISTATE_HWIF", 0, 0x031b, 0 },
+{ "linux/hdreg.h", "HDIO_UNREGISTER_HWIF", 0, 0x032a, 0 },
+{ "linux/hid-roccat.h", "ROCCATIOCGREPSIZE", _IOC_READ, 0x48f1, 0x04 },
+{ "linux/hiddev.h", "HIDIOCAPPLICATION", _IOC_NONE, 0x4802, 0x00 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINDEX", _IOC_WRITE, 0x4810, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGCOLLECTIONINFO", _IOC_READ|_IOC_WRITE, 0x4811, 0x10 },
+{ "linux/hiddev.h", "HIDIOCGDEVINFO", _IOC_READ, 0x4803, 0x1c },
+{ "linux/hiddev.h", "HIDIOCGFIELDINFO", _IOC_READ|_IOC_WRITE, 0x480a, 0x38 },
+{ "linux/hiddev.h", "HIDIOCGFLAG", _IOC_READ, 0x480e, 0x04 },
+{ "linux/hiddev.h", "HIDIOCGREPORT", _IOC_WRITE, 0x4807, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGREPORTINFO", _IOC_READ|_IOC_WRITE, 0x4809, 0x0c },
+{ "linux/hiddev.h", "HIDIOCGSTRING", _IOC_READ, 0x4804, 0x104 },
+{ "linux/hiddev.h", "HIDIOCGUCODE", _IOC_READ|_IOC_WRITE, 0x480d, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGE", _IOC_READ|_IOC_WRITE, 0x480b, 0x18 },
+{ "linux/hiddev.h", "HIDIOCGUSAGES", _IOC_READ|_IOC_WRITE, 0x4813, 0x101c },
+{ "linux/hiddev.h", "HIDIOCGVERSION", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hiddev.h", "HIDIOCINITREPORT", _IOC_NONE, 0x4805, 0x00 },
+{ "linux/hiddev.h", "HIDIOCSFLAG", _IOC_WRITE, 0x480f, 0x04 },
+{ "linux/hiddev.h", "HIDIOCSREPORT", _IOC_WRITE, 0x4808, 0x0c },
+{ "linux/hiddev.h", "HIDIOCSUSAGE", _IOC_WRITE, 0x480c, 0x18 },
+{ "linux/hiddev.h", "HIDIOCSUSAGES", _IOC_WRITE, 0x4814, 0x101c },
+{ "linux/hidraw.h", "HIDIOCGRAWINFO", _IOC_READ, 0x4803, 0x08 },
+{ "linux/hidraw.h", "HIDIOCGRDESC", _IOC_READ, 0x4802, 0x1004 },
+{ "linux/hidraw.h", "HIDIOCGRDESCSIZE", _IOC_READ, 0x4801, 0x04 },
+{ "linux/hpet.h", "HPET_DPI", _IOC_NONE, 0x6805, 0x00 },
+{ "linux/hpet.h", "HPET_EPI", _IOC_NONE, 0x6804, 0x00 },
+{ "linux/hpet.h", "HPET_IE_OFF", _IOC_NONE, 0x6802, 0x00 },
+{ "linux/hpet.h", "HPET_IE_ON", _IOC_NONE, 0x6801, 0x00 },
+{ "linux/hpet.h", "HPET_INFO", _IOC_READ, 0x6803, 0x0c },
+{ "linux/hpet.h", "HPET_IRQFREQ", _IOC_WRITE, 0x6806, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_CONFIG_BUFS", _IOC_WRITE, 0x431f, 0x20 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_IF_VERSION", _IOC_READ, 0x431e, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_GET_STATE", _IOC_READ, 0x4315, 0x04 },
+{ "linux/hsi/cs-protocol.h", "CS_SET_WAKELINE", _IOC_WRITE, 0x4317, 0x04 },
+{ "linux/hsi/hsi_char.h", "HSC_GET_RX", _IOC_WRITE, 0x6b14, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_GET_TX", _IOC_WRITE, 0x6b16, 0x10 },
+{ "linux/hsi/hsi_char.h", "HSC_RESET", _IOC_NONE, 0x6b10, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SEND_BREAK", _IOC_NONE, 0x6b12, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_PM", _IOC_NONE, 0x6b11, 0x00 },
+{ "linux/hsi/hsi_char.h", "HSC_SET_RX", _IOC_WRITE, 0x6b13, 0x0c },
+{ "linux/hsi/hsi_char.h", "HSC_SET_TX", _IOC_WRITE, 0x6b15, 0x10 },
+{ "linux/i2o-dev.h", "I2OEVTGET", _IOC_READ, 0x690b, 0x68 },
+{ "linux/i2o-dev.h", "I2OEVTREG", _IOC_WRITE, 0x690a, 0x0c },
+{ "linux/i2o-dev.h", "I2OGETIOPS", _IOC_READ, 0x6900, 0x20 },
+{ "linux/i2o-dev.h", "I2OHRTGET", _IOC_READ|_IOC_WRITE, 0x6901, 0x0c },
+{ "linux/i2o-dev.h", "I2OHTML", _IOC_READ|_IOC_WRITE, 0x6909, 0x1c },
+{ "linux/i2o-dev.h", "I2OLCTGET", _IOC_READ|_IOC_WRITE, 0x6902, 0x0c },
+{ "linux/i2o-dev.h", "I2OPARMGET", _IOC_READ|_IOC_WRITE, 0x6904, 0x18 },
+{ "linux/i2o-dev.h", "I2OPARMSET", _IOC_READ|_IOC_WRITE, 0x6903, 0x18 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OPASSTHRU32", _IOC_READ, 0x690c, 0x08 },
+{ "linux/i2o-dev.h", "I2OSWDEL", _IOC_READ|_IOC_WRITE, 0x6907, 0x1c },
+{ "linux/i2o-dev.h", "I2OSWDL", _IOC_READ|_IOC_WRITE, 0x6905, 0x1c },
+{ "linux/i2o-dev.h", "I2OSWUL", _IOC_READ|_IOC_WRITE, 0x6906, 0x1c },
+{ "linux/i2o-dev.h", "I2OVALIDATE", _IOC_READ, 0x6908, 0x04 },
+{ "linux/i8k.h", "I8K_BIOS_VERSION", _IOC_READ, 0x6980, 0x04 },
+{ "linux/i8k.h", "I8K_FN_STATUS", _IOC_READ, 0x6983, 0x04 },
+{ "linux/i8k.h", "I8K_GET_FAN", _IOC_READ|_IOC_WRITE, 0x6986, 0x04 },
+{ "linux/i8k.h", "I8K_GET_SPEED", _IOC_READ|_IOC_WRITE, 0x6985, 0x04 },
+{ "linux/i8k.h", "I8K_GET_TEMP", _IOC_READ, 0x6984, 0x04 },
+{ "linux/i8k.h", "I8K_MACHINE_ID", _IOC_READ, 0x6981, 0x04 },
+{ "linux/i8k.h", "I8K_POWER_STATUS", _IOC_READ, 0x6982, 0x04 },
+{ "linux/i8k.h", "I8K_SET_FAN", _IOC_READ|_IOC_WRITE, 0x6987, 0x04 },
+{ "linux/if_pppox.h", "PPPOEIOCDFWD", _IOC_NONE, 0xb101, 0x00 },
+{ "linux/if_pppox.h", "PPPOEIOCSFWD", _IOC_WRITE, 0xb100, 0x04 },
+{ "linux/if_tun.h", "TUNATTACHFILTER", _IOC_WRITE, 0x54d5, 0x08 },
+{ "linux/if_tun.h", "TUNDETACHFILTER", _IOC_WRITE, 0x54d6, 0x08 },
+{ "linux/if_tun.h", "TUNGETFEATURES", _IOC_READ, 0x54cf, 0x04 },
+{ "linux/if_tun.h", "TUNGETFILTER", _IOC_READ, 0x54db, 0x08 },
+{ "linux/if_tun.h", "TUNGETIFF", _IOC_READ, 0x54d2, 0x04 },
+{ "linux/if_tun.h", "TUNGETSNDBUF", _IOC_READ, 0x54d3, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETBE", _IOC_READ, 0x54df, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETHDRSZ", _IOC_READ, 0x54d7, 0x04 },
+{ "linux/if_tun.h", "TUNGETVNETLE", _IOC_READ, 0x54dd, 0x04 },
+{ "linux/if_tun.h", "TUNSETDEBUG", _IOC_WRITE, 0x54c9, 0x04 },
+{ "linux/if_tun.h", "TUNSETGROUP", _IOC_WRITE, 0x54ce, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFF", _IOC_WRITE, 0x54ca, 0x04 },
+{ "linux/if_tun.h", "TUNSETIFINDEX", _IOC_WRITE, 0x54da, 0x04 },
+{ "linux/if_tun.h", "TUNSETLINK", _IOC_WRITE, 0x54cd, 0x04 },
+{ "linux/if_tun.h", "TUNSETNOCSUM", _IOC_WRITE, 0x54c8, 0x04 },
+{ "linux/if_tun.h", "TUNSETOFFLOAD", _IOC_WRITE, 0x54d0, 0x04 },
+{ "linux/if_tun.h", "TUNSETOWNER", _IOC_WRITE, 0x54cc, 0x04 },
+{ "linux/if_tun.h", "TUNSETPERSIST", _IOC_WRITE, 0x54cb, 0x04 },
+{ "linux/if_tun.h", "TUNSETQUEUE", _IOC_WRITE, 0x54d9, 0x04 },
+{ "linux/if_tun.h", "TUNSETSNDBUF", _IOC_WRITE, 0x54d4, 0x04 },
+{ "linux/if_tun.h", "TUNSETTXFILTER", _IOC_WRITE, 0x54d1, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETBE", _IOC_WRITE, 0x54de, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETHDRSZ", _IOC_WRITE, 0x54d8, 0x04 },
+{ "linux/if_tun.h", "TUNSETVNETLE", _IOC_WRITE, 0x54dc, 0x04 },
+{ "linux/iio/events.h", "IIO_GET_EVENT_FD_IOCTL", _IOC_READ, 0x6990, 0x04 },
+{ "linux/input.h", "EVIOCGEFFECTS", _IOC_READ, 0x4584, 0x04 },
+{ "linux/input.h", "EVIOCGID", _IOC_READ, 0x4502, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE", _IOC_READ, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCGKEYCODE_V2", _IOC_READ, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCGMASK", _IOC_READ, 0x4592, 0x10 },
+{ "linux/input.h", "EVIOCGRAB", _IOC_WRITE, 0x4590, 0x04 },
+{ "linux/input.h", "EVIOCGREP", _IOC_READ, 0x4503, 0x08 },
+{ "linux/input.h", "EVIOCGVERSION", _IOC_READ, 0x4501, 0x04 },
+{ "linux/input.h", "EVIOCREVOKE", _IOC_WRITE, 0x4591, 0x04 },
+{ "linux/input.h", "EVIOCRMFF", _IOC_WRITE, 0x4581, 0x04 },
+{ "linux/input.h", "EVIOCSCLOCKID", _IOC_WRITE, 0x45a0, 0x04 },
+{ "linux/input.h", "EVIOCSFF", _IOC_WRITE, 0x4580, 0x2c },
+{ "linux/input.h", "EVIOCSKEYCODE", _IOC_WRITE, 0x4504, 0x08 },
+{ "linux/input.h", "EVIOCSKEYCODE_V2", _IOC_WRITE, 0x4504, 0x28 },
+{ "linux/input.h", "EVIOCSMASK", _IOC_WRITE, 0x4593, 0x10 },
+{ "linux/input.h", "EVIOCSREP", _IOC_WRITE, 0x4503, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_GET_MAINTENANCE_MODE_CMD", _IOC_READ, 0x691e, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_ADDRESS_CMD", _IOC_READ, 0x6912, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6919, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691b, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_MY_LUN_CMD", _IOC_READ, 0x6914, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_GET_TIMING_PARMS_CMD", _IOC_READ, 0x6917, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG", _IOC_READ|_IOC_WRITE, 0x690c, 0x18 },
+{ "linux/ipmi.h", "IPMICTL_RECEIVE_MSG_TRUNC", _IOC_READ|_IOC_WRITE, 0x690b, 0x18 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD", _IOC_READ, 0x690e, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_REGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691c, 0x0c },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND", _IOC_READ, 0x690d, 0x14 },
+{ "linux/ipmi.h", "IPMICTL_SEND_COMMAND_SETTIME", _IOC_READ, 0x6915, 0x1c },
+{ "linux/ipmi.h", "IPMICTL_SET_GETS_EVENTS_CMD", _IOC_READ, 0x6910, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MAINTENANCE_MODE_CMD", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_ADDRESS_CMD", _IOC_READ, 0x6911, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_ADDRESS_CMD", _IOC_READ, 0x6918, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_CHANNEL_LUN_CMD", _IOC_READ, 0x691a, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_MY_LUN_CMD", _IOC_READ, 0x6913, 0x04 },
+{ "linux/ipmi.h", "IPMICTL_SET_TIMING_PARMS_CMD", _IOC_READ, 0x6916, 0x08 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD", _IOC_READ, 0x690f, 0x02 },
+{ "linux/ipmi.h", "IPMICTL_UNREGISTER_FOR_CMD_CHANS", _IOC_READ, 0x691d, 0x0c },
+{ "linux/isdn.h", "IIOCDBGVAR", _IOC_NONE, 0x497f, 0x00 },
+{ "linux/isdn.h", "IIOCDRVCTL", _IOC_NONE, 0x4980, 0x00 },
+{ "linux/isdn.h", "IIOCGETCPS", _IOC_NONE, 0x4915, 0x00 },
+{ "linux/isdn.h", "IIOCGETDVR", _IOC_NONE, 0x4916, 0x00 },
+{ "linux/isdn.h", "IIOCGETMAP", _IOC_NONE, 0x4911, 0x00 },
+{ "linux/isdn.h", "IIOCGETPRF", _IOC_NONE, 0x490f, 0x00 },
+{ "linux/isdn.h", "IIOCGETSET", _IOC_NONE, 0x4908, 0x00 },
+{ "linux/isdn.h", "IIOCNETAIF", _IOC_NONE, 0x4901, 0x00 },
+{ "linux/isdn.h", "IIOCNETALN", _IOC_NONE, 0x4920, 0x00 },
+{ "linux/isdn.h", "IIOCNETANM", _IOC_NONE, 0x4905, 0x00 },
+{ "linux/isdn.h", "IIOCNETASL", _IOC_NONE, 0x4913, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIF", _IOC_NONE, 0x4902, 0x00 },
+{ "linux/isdn.h", "IIOCNETDIL", _IOC_NONE, 0x4914, 0x00 },
+{ "linux/isdn.h", "IIOCNETDLN", _IOC_NONE, 0x4921, 0x00 },
+{ "linux/isdn.h", "IIOCNETDNM", _IOC_NONE, 0x4906, 0x00 },
+{ "linux/isdn.h", "IIOCNETDWRSET", _IOC_NONE, 0x4918, 0x00 },
+{ "linux/isdn.h", "IIOCNETGCF", _IOC_NONE, 0x4904, 0x00 },
+{ "linux/isdn.h", "IIOCNETGNM", _IOC_NONE, 0x4907, 0x00 },
+{ "linux/isdn.h", "IIOCNETGPN", _IOC_NONE, 0x4922, 0x00 },
+{ "linux/isdn.h", "IIOCNETHUP", _IOC_NONE, 0x490b, 0x00 },
+{ "linux/isdn.h", "IIOCNETLCR", _IOC_NONE, 0x4917, 0x00 },
+{ "linux/isdn.h", "IIOCNETSCF", _IOC_NONE, 0x4903, 0x00 },
+{ "linux/isdn.h", "IIOCSETBRJ", _IOC_NONE, 0x490d, 0x00 },
+{ "linux/isdn.h", "IIOCSETGST", _IOC_NONE, 0x490c, 0x00 },
+{ "linux/isdn.h", "IIOCSETMAP", _IOC_NONE, 0x4912, 0x00 },
+{ "linux/isdn.h", "IIOCSETPRF", _IOC_NONE, 0x4910, 0x00 },
+{ "linux/isdn.h", "IIOCSETSET", _IOC_NONE, 0x4909, 0x00 },
+{ "linux/isdn.h", "IIOCSETVER", _IOC_NONE, 0x490a, 0x00 },
+{ "linux/isdn.h", "IIOCSIGPRF", _IOC_NONE, 0x490e, 0x00 },
+{ "linux/isdn_ppp.h", "PPPIOCBUNDLE", _IOC_WRITE, 0x7481, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCGCALLINFO", _IOC_READ|_IOC_WRITE, 0x7480, 0x88 },
+{ "linux/isdn_ppp.h", "PPPIOCGCOMPRESSORS", _IOC_READ, 0x7486, 0x20 },
+{ "linux/isdn_ppp.h", "PPPIOCGIFNAME", _IOC_READ, 0x7488, 0x10 },
+{ "linux/isdn_ppp.h", "PPPIOCGMPFLAGS", _IOC_READ, 0x7482, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSCOMPRESSOR", _IOC_WRITE, 0x7487, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPFLAGS", _IOC_WRITE, 0x7483, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMRU", _IOC_WRITE, 0x7485, 0x04 },
+{ "linux/isdn_ppp.h", "PPPIOCSMPMTU", _IOC_WRITE, 0x7484, 0x04 },
+{ "linux/ivtv.h", "IVTV_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x38 },
+{ "linux/ivtv.h", "IVTV_IOC_PASSTHROUGH_MODE", _IOC_WRITE, 0x56c1, 0x04 },
+{ "linux/ivtvfb.h", "IVTVFB_IOC_DMA_FRAME", _IOC_WRITE, 0x56c0, 0x0c },
+{ "linux/ixjuser.h", "IXJCTL_AEC_GET_LEVEL", _IOC_NONE, 0x71cd, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_START", _IOC_WRITE, 0x71cb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_AEC_STOP", _IOC_NONE, 0x71cc, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_CARDTYPE", _IOC_READ, 0x71c1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CID", _IOC_READ, 0x71d4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_CIDCW", _IOC_WRITE, 0x71d9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_AGAIN", _IOC_WRITE, 0x71d2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DAA_COEFF_SET", _IOC_WRITE, 0x71d0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_CLEAR", _IOC_NONE, 0x71e7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DRYBUFFER_READ", _IOC_READ, 0x71e6, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_IDLE", _IOC_NONE, 0x71c5, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_RESET", _IOC_NONE, 0x71c0, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_TYPE", _IOC_READ, 0x71c3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DSP_VERSION", _IOC_READ, 0x71c4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_DTMF_PRESCALE", _IOC_WRITE, 0x71e8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FILTER_CADENCE", _IOC_WRITE, 0x71d6, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_READ", _IOC_READ, 0x71e2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_FRAMES_WRITTEN", _IOC_READ, 0x71e3, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_GET_FILTER_HIST", _IOC_WRITE, 0x71c8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_HZ", _IOC_WRITE, 0x71e0, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INIT_TONE", _IOC_WRITE, 0x71c9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_START", _IOC_WRITE, 0x71fd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_INTERCOM_STOP", _IOC_WRITE, 0x71fe, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_MIXER", _IOC_WRITE, 0x71cf, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PLAY_CID", _IOC_NONE, 0x71d7, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_PORT", _IOC_WRITE, 0x71d1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_POTS_PSTN", _IOC_WRITE, 0x71d5, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_PSTN_LINETEST", _IOC_NONE, 0x71d3, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_RATE", _IOC_WRITE, 0x71e1, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_READ_WAIT", _IOC_READ, 0x71e4, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_RXG", _IOC_WRITE, 0x71ea, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SC_TXG", _IOC_WRITE, 0x71eb, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SERIAL", _IOC_READ, 0x71c2, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER", _IOC_WRITE, 0x71c7, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_FILTER_RAW", _IOC_WRITE, 0x71dd, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SET_LED", _IOC_WRITE, 0x71ce, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_SIGCTL", _IOC_WRITE, 0x71e9, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_TESTRAM", _IOC_NONE, 0x71c6, 0x00 },
+{ "linux/ixjuser.h", "IXJCTL_TONE_CADENCE", _IOC_WRITE, 0x71ca, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_VERSION", _IOC_READ, 0x71da, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_VMWI", _IOC_READ, 0x71d8, 0x04 },
+{ "linux/ixjuser.h", "IXJCTL_WRITE_WAIT", _IOC_READ, 0x71e5, 0x04 },
+{ "linux/joystick.h", "JSIOCGAXES", _IOC_READ, 0x6a11, 0x01 },
+{ "linux/joystick.h", "JSIOCGAXMAP", _IOC_READ, 0x6a32, 0x40 },
+{ "linux/joystick.h", "JSIOCGBTNMAP", _IOC_READ, 0x6a34, 0x400 },
+{ "linux/joystick.h", "JSIOCGBUTTONS", _IOC_READ, 0x6a12, 0x01 },
+{ "linux/joystick.h", "JSIOCGCORR", _IOC_READ, 0x6a22, 0x24 },
+{ "linux/joystick.h", "JSIOCGVERSION", _IOC_READ, 0x6a01, 0x04 },
+{ "linux/joystick.h", "JSIOCSAXMAP", _IOC_WRITE, 0x6a31, 0x40 },
+{ "linux/joystick.h", "JSIOCSBTNMAP", _IOC_WRITE, 0x6a33, 0x400 },
+{ "linux/joystick.h", "JSIOCSCORR", _IOC_WRITE, 0x6a21, 0x24 },
+{ "linux/kcov.h", "KCOV_DISABLE", _IOC_NONE, 0x6365, 0x00 },
+{ "linux/kcov.h", "KCOV_ENABLE", _IOC_NONE, 0x6364, 0x00 },
+{ "linux/kcov.h", "KCOV_INIT_TRACE", _IOC_READ, 0x6301, 0x04 },
+{ "linux/kd.h", "GIO_CMAP", 0, 0x4B70, 0 },
+{ "linux/kd.h", "GIO_FONT", 0, 0x4B60, 0 },
+{ "linux/kd.h", "GIO_FONTX", 0, 0x4B6B, 0 },
+{ "linux/kd.h", "GIO_SCRNMAP", 0, 0x4B40, 0 },
+{ "linux/kd.h", "GIO_UNIMAP", 0, 0x4B66, 0 },
+{ "linux/kd.h", "GIO_UNISCRNMAP", 0, 0x4B69, 0 },
+{ "linux/kd.h", "KDADDIO", 0, 0x4B34, 0 },
+{ "linux/kd.h", "KDDELIO", 0, 0x4B35, 0 },
+{ "linux/kd.h", "KDDISABIO", 0, 0x4B37, 0 },
+{ "linux/kd.h", "KDENABIO", 0, 0x4B36, 0 },
+{ "linux/kd.h", "KDFONTOP", 0, 0x4B72, 0 },
+{ "linux/kd.h", "KDGETKEYCODE", 0, 0x4B4C, 0 },
+{ "linux/kd.h", "KDGETLED", 0, 0x4B31, 0 },
+{ "linux/kd.h", "KDGETMODE", 0, 0x4B3B, 0 },
+{ "linux/kd.h", "KDGKBDIACR", 0, 0x4B4A, 0 },
+{ "linux/kd.h", "KDGKBDIACRUC", 0, 0x4BFA, 0 },
+{ "linux/kd.h", "KDGKBENT", 0, 0x4B46, 0 },
+{ "linux/kd.h", "KDGKBLED", 0, 0x4B64, 0 },
+{ "linux/kd.h", "KDGKBMETA", 0, 0x4B62, 0 },
+{ "linux/kd.h", "KDGKBMODE", 0, 0x4B44, 0 },
+{ "linux/kd.h", "KDGKBSENT", 0, 0x4B48, 0 },
+{ "linux/kd.h", "KDGKBTYPE", 0, 0x4B33, 0 },
+{ "linux/kd.h", "KDKBDREP", 0, 0x4B52, 0 },
+{ "linux/kd.h", "KDMAPDISP", 0, 0x4B3C, 0 },
+{ "linux/kd.h", "KDMKTONE", 0, 0x4B30, 0 },
+{ "linux/kd.h", "KDSETKEYCODE", 0, 0x4B4D, 0 },
+{ "linux/kd.h", "KDSETLED", 0, 0x4B32, 0 },
+{ "linux/kd.h", "KDSETMODE", 0, 0x4B3A, 0 },
+{ "linux/kd.h", "KDSIGACCEPT", 0, 0x4B4E, 0 },
+{ "linux/kd.h", "KDSKBDIACR", 0, 0x4B4B, 0 },
+{ "linux/kd.h", "KDSKBDIACRUC", 0, 0x4BFB, 0 },
+{ "linux/kd.h", "KDSKBENT", 0, 0x4B47, 0 },
+{ "linux/kd.h", "KDSKBLED", 0, 0x4B65, 0 },
+{ "linux/kd.h", "KDSKBMETA", 0, 0x4B63, 0 },
+{ "linux/kd.h", "KDSKBMODE", 0, 0x4B45, 0 },
+{ "linux/kd.h", "KDSKBSENT", 0, 0x4B49, 0 },
+{ "linux/kd.h", "KDUNMAPDISP", 0, 0x4B3D, 0 },
+{ "linux/kd.h", "KIOCSOUND", 0, 0x4B2F, 0 },
+{ "linux/kd.h", "PIO_CMAP", 0, 0x4B71, 0 },
+{ "linux/kd.h", "PIO_FONT", 0, 0x4B61, 0 },
+{ "linux/kd.h", "PIO_FONTRESET", 0, 0x4B6D, 0 },
+{ "linux/kd.h", "PIO_FONTX", 0, 0x4B6C, 0 },
+{ "linux/kd.h", "PIO_SCRNMAP", 0, 0x4B41, 0 },
+{ "linux/kd.h", "PIO_UNIMAP", 0, 0x4B67, 0 },
+{ "linux/kd.h", "PIO_UNIMAPCLR", 0, 0x4B68, 0 },
+{ "linux/kd.h", "PIO_UNISCRNMAP", 0, 0x4B6A, 0 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_EVENT", _IOC_READ|_IOC_WRITE, 0x4b08, 0x20 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b02, 0x58 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_ADDRESS_WATCH", _IOC_WRITE, 0x4b0f, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_REGISTER", _IOC_WRITE, 0x4b0d, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_UNREGISTER", _IOC_WRITE, 0x4b0e, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DBG_WAVE_CONTROL", _IOC_WRITE, 0x4b10, 0x10 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_EVENT", _IOC_WRITE, 0x4b09, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_DESTROY_QUEUE", _IOC_READ|_IOC_WRITE, 0x4b03, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_CLOCK_COUNTERS", _IOC_READ|_IOC_WRITE, 0x4b05, 0x28 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_PROCESS_APERTURES", _IOC_READ, 0x4b06, 0x190 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_GET_VERSION", _IOC_READ, 0x4b01, 0x08 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_RESET_EVENT", _IOC_WRITE, 0x4b0b, 0x08 },
+{ "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_UPDATE_QUEUE", _IOC_WRITE, 0x4b07, 0x18 },
+{ "linux/kfd_ioctl.h", "AMDKFD_IOC_WAIT_EVENTS", _IOC_READ|_IOC_WRITE, 0x4b0c, 0x18 },
+{ "linux/kvm.h", "KVM_ALLOCATE_RMA", _IOC_READ, 0xaea9, 0x08 },
+{ "linux/kvm.h", "KVM_ARM_PREFERRED_TARGET", _IOC_READ, 0xaeaf, 0x20 },
+{ "linux/kvm.h", "KVM_ARM_SET_DEVICE_ADDR", _IOC_WRITE, 0xaeab, 0x10 },
+{ "linux/kvm.h", "KVM_ARM_VCPU_INIT", _IOC_WRITE, 0xaeae, 0x20 },
+{ "linux/kvm.h", "KVM_ASSIGN_DEV_IRQ", _IOC_WRITE, 0xae70, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_PCI_DEVICE", _IOC_READ, 0xae69, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_INTX_MASK", _IOC_WRITE, 0xaea4, 0x40 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_ENTRY", _IOC_WRITE, 0xae74, 0x10 },
+{ "linux/kvm.h", "KVM_ASSIGN_SET_MSIX_NR", _IOC_WRITE, 0xae73, 0x08 },
+{ "linux/kvm.h", "KVM_CHECK_EXTENSION", _IOC_NONE, 0xae03, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_DEVICE", _IOC_READ|_IOC_WRITE, 0xaee0, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_IRQCHIP", _IOC_NONE, 0xae60, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT", _IOC_NONE, 0xae64, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_PIT2", _IOC_WRITE, 0xae77, 0x40 },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE", _IOC_WRITE, 0xaea8, 0x0c },
+{ "linux/kvm.h", "KVM_CREATE_SPAPR_TCE_64", _IOC_WRITE, 0xaea8, 0x20 },
+{ "linux/kvm.h", "KVM_CREATE_VCPU", _IOC_NONE, 0xae41, 0x00 },
+{ "linux/kvm.h", "KVM_CREATE_VM", _IOC_NONE, 0xae01, 0x00 },
+{ "linux/kvm.h", "KVM_DEASSIGN_DEV_IRQ", _IOC_WRITE, 0xae75, 0x40 },
+{ "linux/kvm.h", "KVM_DEASSIGN_PCI_DEVICE", _IOC_WRITE, 0xae72, 0x40 },
+{ "linux/kvm.h", "KVM_DIRTY_TLB", _IOC_WRITE, 0xaeaa, 0x10 },
+{ "linux/kvm.h", "KVM_ENABLE_CAP", _IOC_WRITE, 0xaea3, 0x68 },
+{ "linux/kvm.h", "KVM_GET_API_VERSION", _IOC_NONE, 0xae00, 0x00 },
+{ "linux/kvm.h", "KVM_GET_CLOCK", _IOC_READ, 0xae7c, 0x30 },
+{ "linux/kvm.h", "KVM_GET_CPUID2", _IOC_READ|_IOC_WRITE, 0xae91, 0x08 },
+{ "linux/kvm.h", "KVM_GET_DEBUGREGS", _IOC_READ, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_GET_DEVICE_ATTR", _IOC_WRITE, 0xaee2, 0x18 },
+{ "linux/kvm.h", "KVM_GET_DIRTY_LOG", _IOC_WRITE, 0xae42, 0x10 },
+{ "linux/kvm.h", "KVM_GET_EMULATED_CPUID", _IOC_READ|_IOC_WRITE, 0xae09, 0x08 },
+{ "linux/kvm.h", "KVM_GET_FPU", _IOC_READ, 0xae8c, 0x1a0 },
+{ "linux/kvm.h", "KVM_GET_IRQCHIP", _IOC_READ|_IOC_WRITE, 0xae62, 0x208 },
+{ "linux/kvm.h", "KVM_GET_LAPIC", _IOC_READ, 0xae8e, 0x400 },
+{ "linux/kvm.h", "KVM_GET_MP_STATE", _IOC_READ, 0xae98, 0x04 },
+{ "linux/kvm.h", "KVM_GET_MSRS", _IOC_READ|_IOC_WRITE, 0xae88, 0x08 },
+{ "linux/kvm.h", "KVM_GET_MSR_INDEX_LIST", _IOC_READ|_IOC_WRITE, 0xae02, 0x04 },
+{ "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 },
+{ "linux/kvm.h", "KVM_GET_PIT2", _IOC_READ, 0xae9f, 0x70 },
+{ "linux/kvm.h", "KVM_GET_REGS", _IOC_READ, 0xae81, 0x90 },
+{ "linux/kvm.h", "KVM_GET_REG_LIST", _IOC_READ|_IOC_WRITE, 0xaeb0, 0x08 },
+{ "linux/kvm.h", "KVM_GET_SREGS", _IOC_READ, 0xae83, 0x138 },
+{ "linux/kvm.h", "KVM_GET_SUPPORTED_CPUID", _IOC_READ|_IOC_WRITE, 0xae05, 0x08 },
+{ "linux/kvm.h", "KVM_GET_TSC_KHZ", _IOC_NONE, 0xaea3, 0x00 },
+{ "linux/kvm.h", "KVM_GET_VCPU_EVENTS", _IOC_READ, 0xae9f, 0x40 },
+{ "linux/kvm.h", "KVM_GET_VCPU_MMAP_SIZE", _IOC_NONE, 0xae04, 0x00 },
+{ "linux/kvm.h", "KVM_GET_XCRS", _IOC_READ, 0xaea6, 0x188 },
+{ "linux/kvm.h", "KVM_GET_XSAVE", _IOC_READ, 0xaea4, 0x1000 },
+{ "linux/kvm.h", "KVM_HAS_DEVICE_ATTR", _IOC_WRITE, 0xaee3, 0x18 },
+{ "linux/kvm.h", "KVM_INTERRUPT", _IOC_WRITE, 0xae86, 0x04 },
+{ "linux/kvm.h", "KVM_IOEVENTFD", _IOC_WRITE, 0xae79, 0x40 },
+{ "linux/kvm.h", "KVM_IRQFD", _IOC_WRITE, 0xae76, 0x20 },
+{ "linux/kvm.h", "KVM_IRQ_LINE", _IOC_WRITE, 0xae61, 0x08 },
+{ "linux/kvm.h", "KVM_IRQ_LINE_STATUS", _IOC_READ|_IOC_WRITE, 0xae67, 0x08 },
+{ "linux/kvm.h", "KVM_KVMCLOCK_CTRL", _IOC_NONE, 0xaead, 0x00 },
+{ "linux/kvm.h", "KVM_NMI", _IOC_NONE, 0xae9a, 0x00 },
+{ "linux/kvm.h", "KVM_PPC_ALLOCATE_HTAB", _IOC_READ|_IOC_WRITE, 0xaea7, 0x04 },
+{ "linux/kvm.h", "KVM_PPC_GET_HTAB_FD", _IOC_WRITE, 0xaeaa, 0x20 },
+{ "linux/kvm.h", "KVM_PPC_GET_PVINFO", _IOC_WRITE, 0xaea1, 0x80 },
+{ "linux/kvm.h", "KVM_PPC_GET_SMMU_INFO", _IOC_READ, 0xaea6, 0x250 },
+{ "linux/kvm.h", "KVM_PPC_RTAS_DEFINE_TOKEN", _IOC_WRITE, 0xaeac, 0x80 },
+{ "linux/kvm.h", "KVM_REGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae67, 0x10 },
+{ "linux/kvm.h", "KVM_REINJECT_CONTROL", _IOC_NONE, 0xae71, 0x00 },
+{ "linux/kvm.h", "KVM_RUN", _IOC_NONE, 0xae80, 0x00 },
+{ "linux/kvm.h", "KVM_S390_ENABLE_SIE", _IOC_NONE, 0xae06, 0x00 },
+{ "linux/kvm.h", "KVM_S390_GET_IRQ_STATE", _IOC_WRITE, 0xaeb6, 0x20 },
+{ "linux/kvm.h", "KVM_S390_GET_SKEYS", _IOC_WRITE, 0xaeb2, 0x40 },
+{ "linux/kvm.h", "KVM_S390_INITIAL_RESET", _IOC_NONE, 0xae97, 0x00 },
+{ "linux/kvm.h", "KVM_S390_INTERRUPT", _IOC_WRITE, 0xae94, 0x10 },
+{ "linux/kvm.h", "KVM_S390_IRQ", _IOC_WRITE, 0xaeb4, 0x48 },
+{ "linux/kvm.h", "KVM_S390_MEM_OP", _IOC_WRITE, 0xaeb1, 0x40 },
+{ "linux/kvm.h", "KVM_S390_SET_INITIAL_PSW", _IOC_WRITE, 0xae96, 0x10 },
+{ "linux/kvm.h", "KVM_S390_SET_IRQ_STATE", _IOC_WRITE, 0xaeb5, 0x20 },
+{ "linux/kvm.h", "KVM_S390_SET_SKEYS", _IOC_WRITE, 0xaeb3, 0x40 },
+{ "linux/kvm.h", "KVM_S390_STORE_STATUS", _IOC_WRITE, 0xae95, 0x04 },
+{ "linux/kvm.h", "KVM_S390_UCAS_MAP", _IOC_WRITE, 0xae50, 0x18 },
+{ "linux/kvm.h", "KVM_S390_UCAS_UNMAP", _IOC_WRITE, 0xae51, 0x18 },
+{ "linux/kvm.h", "KVM_S390_VCPU_FAULT", _IOC_WRITE, 0xae52, 0x04 },
+{ "linux/kvm.h", "KVM_SET_BOOT_CPU_ID", _IOC_NONE, 0xae78, 0x00 },
+{ "linux/kvm.h", "KVM_SET_CLOCK", _IOC_WRITE, 0xae7b, 0x30 },
+{ "linux/kvm.h", "KVM_SET_CPUID", _IOC_WRITE, 0xae8a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_CPUID2", _IOC_WRITE, 0xae90, 0x08 },
+{ "linux/kvm.h", "KVM_SET_DEBUGREGS", _IOC_WRITE, 0xaea2, 0x80 },
+{ "linux/kvm.h", "KVM_SET_DEVICE_ATTR", _IOC_WRITE, 0xaee1, 0x18 },
+{ "linux/kvm.h", "KVM_SET_FPU", _IOC_WRITE, 0xae8d, 0x1a0 },
+{ "linux/kvm.h", "KVM_SET_GSI_ROUTING", _IOC_WRITE, 0xae6a, 0x08 },
+{ "linux/kvm.h", "KVM_SET_GUEST_DEBUG", _IOC_WRITE, 0xae9b, 0x48 },
+{ "linux/kvm.h", "KVM_SET_IDENTITY_MAP_ADDR", _IOC_WRITE, 0xae48, 0x08 },
+{ "linux/kvm.h", "KVM_SET_IRQCHIP", _IOC_READ, 0xae63, 0x208 },
+{ "linux/kvm.h", "KVM_SET_LAPIC", _IOC_WRITE, 0xae8f, 0x400 },
+{ "linux/kvm.h", "KVM_SET_MEMORY_ALIAS", _IOC_WRITE, 0xae43, 0x20 },
+{ "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_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 },
+{ "linux/kvm.h", "KVM_SET_PIT2", _IOC_WRITE, 0xaea0, 0x70 },
+{ "linux/kvm.h", "KVM_SET_REGS", _IOC_WRITE, 0xae82, 0x90 },
+{ "linux/kvm.h", "KVM_SET_SIGNAL_MASK", _IOC_WRITE, 0xae8b, 0x04 },
+{ "linux/kvm.h", "KVM_SET_SREGS", _IOC_WRITE, 0xae84, 0x138 },
+{ "linux/kvm.h", "KVM_SET_TSC_KHZ", _IOC_NONE, 0xaea2, 0x00 },
+{ "linux/kvm.h", "KVM_SET_TSS_ADDR", _IOC_NONE, 0xae47, 0x00 },
+{ "linux/kvm.h", "KVM_SET_USER_MEMORY_REGION", _IOC_WRITE, 0xae46, 0x20 },
+{ "linux/kvm.h", "KVM_SET_VAPIC_ADDR", _IOC_WRITE, 0xae93, 0x08 },
+{ "linux/kvm.h", "KVM_SET_VCPU_EVENTS", _IOC_WRITE, 0xaea0, 0x40 },
+{ "linux/kvm.h", "KVM_SET_XCRS", _IOC_WRITE, 0xaea7, 0x188 },
+{ "linux/kvm.h", "KVM_SET_XSAVE", _IOC_WRITE, 0xaea5, 0x1000 },
+{ "linux/kvm.h", "KVM_SIGNAL_MSI", _IOC_WRITE, 0xaea5, 0x20 },
+{ "linux/kvm.h", "KVM_SMI", _IOC_NONE, 0xaeb7, 0x00 },
+{ "linux/kvm.h", "KVM_TPR_ACCESS_REPORTING", _IOC_READ|_IOC_WRITE, 0xae92, 0x28 },
+{ "linux/kvm.h", "KVM_TRANSLATE", _IOC_READ|_IOC_WRITE, 0xae85, 0x18 },
+{ "linux/kvm.h", "KVM_UNREGISTER_COALESCED_MMIO", _IOC_WRITE, 0xae68, 0x10 },
+{ "linux/kvm.h", "KVM_X86_GET_MCE_CAP_SUPPORTED", _IOC_READ, 0xae9d, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SETUP_MCE", _IOC_WRITE, 0xae9c, 0x08 },
+{ "linux/kvm.h", "KVM_X86_SET_MCE", _IOC_WRITE, 0xae9e, 0x40 },
+{ "linux/kvm.h", "KVM_XEN_HVM_CONFIG", _IOC_WRITE, 0xae7a, 0x38 },
+{ "linux/lightnvm.h", "NVM_DEV_CREATE", _IOC_WRITE, 0x4c22, 0x80 },
+{ "linux/lightnvm.h", "NVM_DEV_FACTORY", _IOC_WRITE, 0x4c25, 0x24 },
+{ "linux/lightnvm.h", "NVM_DEV_INIT", _IOC_WRITE, 0x4c24, 0x2c },
+{ "linux/lightnvm.h", "NVM_DEV_REMOVE", _IOC_WRITE, 0x4c23, 0x24 },
+{ "linux/lightnvm.h", "NVM_GET_DEVICES", _IOC_READ, 0x4c21, 0x1000 },
+{ "linux/lightnvm.h", "NVM_INFO", _IOC_READ|_IOC_WRITE, 0x4c20, 0x1000 },
+{ "linux/lirc.h", "LIRC_GET_FEATURES", _IOC_READ, 0x6900, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_LENGTH", _IOC_READ, 0x690f, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_PULSE", _IOC_READ, 0x690b, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_FILTER_SPACE", _IOC_READ, 0x690d, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MAX_TIMEOUT", _IOC_READ, 0x6909, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_PULSE", _IOC_READ, 0x690a, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_FILTER_SPACE", _IOC_READ, 0x690c, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_MIN_TIMEOUT", _IOC_READ, 0x6908, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_CARRIER", _IOC_READ, 0x6904, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_DUTY_CYCLE", _IOC_READ, 0x6906, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_MODE", _IOC_READ, 0x6902, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_REC_RESOLUTION", _IOC_READ, 0x6907, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_CARRIER", _IOC_READ, 0x6903, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_DUTY_CYCLE", _IOC_READ, 0x6905, 0x04 },
+{ "linux/lirc.h", "LIRC_GET_SEND_MODE", _IOC_READ, 0x6901, 0x04 },
+{ "linux/lirc.h", "LIRC_NOTIFY_DECODE", _IOC_NONE, 0x6920, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_END", _IOC_NONE, 0x6922, 0x00 },
+{ "linux/lirc.h", "LIRC_SETUP_START", _IOC_NONE, 0x6921, 0x00 },
+{ "linux/lirc.h", "LIRC_SET_MEASURE_CARRIER_MODE", _IOC_WRITE, 0x691d, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER", _IOC_WRITE, 0x6914, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_CARRIER_RANGE", _IOC_WRITE, 0x691f, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE", _IOC_WRITE, 0x6916, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_DUTY_CYCLE_RANGE", _IOC_WRITE, 0x691e, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER", _IOC_WRITE, 0x691c, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_PULSE", _IOC_WRITE, 0x691a, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_FILTER_SPACE", _IOC_WRITE, 0x691b, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_MODE", _IOC_WRITE, 0x6912, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT", _IOC_WRITE, 0x6918, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_REC_TIMEOUT_REPORTS", _IOC_WRITE, 0x6919, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_CARRIER", _IOC_WRITE, 0x6913, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_DUTY_CYCLE", _IOC_WRITE, 0x6915, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_SEND_MODE", _IOC_WRITE, 0x6911, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_TRANSMITTER_MASK", _IOC_WRITE, 0x6917, 0x04 },
+{ "linux/lirc.h", "LIRC_SET_WIDEBAND_RECEIVER", _IOC_WRITE, 0x6923, 0x04 },
+{ "linux/loop.h", "LOOP_CHANGE_FD", 0, 0x4C06, 0 },
+{ "linux/loop.h", "LOOP_CLR_FD", 0, 0x4C01, 0 },
+{ "linux/loop.h", "LOOP_CTL_ADD", 0, 0x4C80, 0 },
+{ "linux/loop.h", "LOOP_CTL_GET_FREE", 0, 0x4C82, 0 },
+{ "linux/loop.h", "LOOP_CTL_REMOVE", 0, 0x4C81, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS", 0, 0x4C03, 0 },
+{ "linux/loop.h", "LOOP_GET_STATUS64", 0, 0x4C05, 0 },
+{ "linux/loop.h", "LOOP_SET_CAPACITY", 0, 0x4C07, 0 },
+{ "linux/loop.h", "LOOP_SET_DIRECT_IO", 0, 0x4C08, 0 },
+{ "linux/loop.h", "LOOP_SET_FD", 0, 0x4C00, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS", 0, 0x4C02, 0 },
+{ "linux/loop.h", "LOOP_SET_STATUS64", 0, 0x4C04, 0 },
+{ "linux/mISDNif.h", "IMADDTIMER", _IOC_READ, 0x4940, 0x04 },
+{ "linux/mISDNif.h", "IMCLEAR_L2", _IOC_READ, 0x4946, 0x04 },
+{ "linux/mISDNif.h", "IMCTRLREQ", _IOC_READ, 0x4945, 0x04 },
+{ "linux/mISDNif.h", "IMDELTIMER", _IOC_READ, 0x4941, 0x04 },
+{ "linux/mISDNif.h", "IMGETCOUNT", _IOC_READ, 0x4943, 0x04 },
+{ "linux/mISDNif.h", "IMGETDEVINFO", _IOC_READ, 0x4944, 0x04 },
+{ "linux/mISDNif.h", "IMGETVERSION", _IOC_READ, 0x4942, 0x04 },
+{ "linux/mISDNif.h", "IMHOLD_L1", _IOC_READ, 0x4948, 0x04 },
+{ "linux/mISDNif.h", "IMSETDEVNAME", _IOC_READ, 0x4947, 0x18 },
+{ "linux/matroxfb.h", "MATROXFB_GET_ALL_OUTPUTS", _IOC_READ, 0x6efb, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_AVAILABLE_OUTPUTS", _IOC_READ, 0x6ef9, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_CONNECTION", _IOC_READ, 0x6ef8, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_GET_OUTPUT_MODE", _IOC_READ|_IOC_WRITE, 0x6efa, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_CONNECTION", _IOC_WRITE, 0x6ef8, 0x04 },
+{ "linux/matroxfb.h", "MATROXFB_SET_OUTPUT_MODE", _IOC_WRITE, 0x6efa, 0x04 },
+{ "linux/media.h", "MEDIA_IOC_DEVICE_INFO", _IOC_READ|_IOC_WRITE, 0x7c00, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_ENTITIES", _IOC_READ|_IOC_WRITE, 0x7c01, 0x100 },
+{ "linux/media.h", "MEDIA_IOC_ENUM_LINKS", _IOC_READ|_IOC_WRITE, 0x7c02, 0x1c },
+{ "linux/media.h", "MEDIA_IOC_G_TOPOLOGY", _IOC_READ|_IOC_WRITE, 0x7c04, 0x48 },
+{ "linux/media.h", "MEDIA_IOC_SETUP_LINK", _IOC_READ|_IOC_WRITE, 0x7c03, 0x34 },
+{ "linux/mei.h", "IOCTL_MEI_CONNECT_CLIENT", _IOC_READ|_IOC_WRITE, 0x4801, 0x10 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_GET", _IOC_READ, 0x4803, 0x04 },
+{ "linux/mei.h", "IOCTL_MEI_NOTIFY_SET", _IOC_WRITE, 0x4802, 0x04 },
+{ "linux/meye.h", "MEYEIOC_G_PARAMS", _IOC_READ, 0x76c0, 0x06 },
+{ "linux/meye.h", "MEYEIOC_QBUF_CAPT", _IOC_WRITE, 0x76c2, 0x04 },
+{ "linux/meye.h", "MEYEIOC_STILLCAPT", _IOC_NONE, 0x76c4, 0x00 },
+{ "linux/meye.h", "MEYEIOC_STILLJCAPT", _IOC_READ, 0x76c5, 0x04 },
+{ "linux/meye.h", "MEYEIOC_SYNC", _IOC_READ|_IOC_WRITE, 0x76c3, 0x04 },
+{ "linux/meye.h", "MEYEIOC_S_PARAMS", _IOC_WRITE, 0x76c1, 0x06 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_ADD_DEVICE", _IOC_READ|_IOC_WRITE, 0x7301, 0x04 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_CONFIG_CHANGE", _IOC_READ|_IOC_WRITE, 0x7305, 0x04 },
+{ "linux/mic_ioctl.h", "MIC_VIRTIO_COPY_DESC", _IOC_READ|_IOC_WRITE, 0x7302, 0x04 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_CMD", _IOC_READ|_IOC_WRITE, 0xb300, 0x48 },
+{ "linux/mmc/ioctl.h", "MMC_IOC_MULTI_CMD", _IOC_READ|_IOC_WRITE, 0xb301, 0x08 },
+{ "linux/mmtimer.h", "MMTIMER_GETBITS", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETCOUNTER", _IOC_READ, 0x6d09, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_GETFREQ", _IOC_READ, 0x6d02, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_GETOFFSET", _IOC_NONE, 0x6d00, 0x00 },
+{ "linux/mmtimer.h", "MMTIMER_GETRES", _IOC_READ, 0x6d01, 0x04 },
+{ "linux/mmtimer.h", "MMTIMER_MMAPAVAIL", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_ATTRIBUTES", _IOC_READ, 0x7210, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_GET_VOLUME_ID", _IOC_READ, 0x7213, 0x04 },
+{ "linux/msdos_fs.h", "FAT_IOCTL_SET_ATTRIBUTES", _IOC_WRITE, 0x7211, 0x04 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_BOTH", _IOC_READ, 0x7201, 0x230 },
+{ "linux/msdos_fs.h", "VFAT_IOCTL_READDIR_SHORT", _IOC_READ, 0x7202, 0x230 },
+{ "linux/mtio.h", "MTIOCGET", _IOC_READ, 0x6d02, 0x1c },
+{ "linux/mtio.h", "MTIOCPOS", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/mtio.h", "MTIOCTOP", _IOC_WRITE, 0x6d01, 0x08 },
+{ "linux/nbd.h", "NBD_CLEAR_QUE", _IOC_NONE, 0xab05, 0x00 },
+{ "linux/nbd.h", "NBD_CLEAR_SOCK", _IOC_NONE, 0xab04, 0x00 },
+{ "linux/nbd.h", "NBD_DISCONNECT", _IOC_NONE, 0xab08, 0x00 },
+{ "linux/nbd.h", "NBD_DO_IT", _IOC_NONE, 0xab03, 0x00 },
+{ "linux/nbd.h", "NBD_PRINT_DEBUG", _IOC_NONE, 0xab06, 0x00 },
+{ "linux/nbd.h", "NBD_SET_BLKSIZE", _IOC_NONE, 0xab01, 0x00 },
+{ "linux/nbd.h", "NBD_SET_FLAGS", _IOC_NONE, 0xab0a, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE", _IOC_NONE, 0xab02, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SIZE_BLOCKS", _IOC_NONE, 0xab07, 0x00 },
+{ "linux/nbd.h", "NBD_SET_SOCK", _IOC_NONE, 0xab00, 0x00 },
+{ "linux/nbd.h", "NBD_SET_TIMEOUT", _IOC_NONE, 0xab09, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_CONN_LOGGED_IN", _IOC_NONE, 0x6e03, 0x00 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETCHARSETS", _IOC_READ|_IOC_WRITE, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_GETDENTRYTTL", _IOC_WRITE, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID", _IOC_WRITE, 0x6e02, 0x02 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETMOUNTUID2", _IOC_WRITE, 0x6e02, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETOBJECTNAME", _IOC_READ|_IOC_WRITE, 0x6e09, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GETPRIVATEDATA", _IOC_READ|_IOC_WRITE, 0x6e0a, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_GETROOT", _IOC_WRITE, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO", _IOC_READ|_IOC_WRITE, 0x6e04, 0x28 },
+{ "linux/ncp_fs.h", "NCP_IOC_GET_FS_INFO_V2", _IOC_READ|_IOC_WRITE, 0x6e04, 0x24 },
+{ "linux/ncp_fs.h", "NCP_IOC_LOCKUNLOCK", _IOC_READ, 0x6e07, 0x14 },
+{ "linux/ncp_fs.h", "NCP_IOC_NCPREQUEST", _IOC_READ, 0x6e01, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SETCHARSETS", _IOC_READ, 0x6e0b, 0x2a },
+{ "linux/ncp_fs.h", "NCP_IOC_SETDENTRYTTL", _IOC_READ, 0x6e0c, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETOBJECTNAME", _IOC_READ, 0x6e09, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SETPRIVATEDATA", _IOC_READ, 0x6e0a, 0x08 },
+{ "linux/ncp_fs.h", "NCP_IOC_SETROOT", _IOC_READ, 0x6e08, 0x0c },
+{ "linux/ncp_fs.h", "NCP_IOC_SET_SIGN_WANTED", _IOC_WRITE, 0x6e06, 0x04 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_INIT", _IOC_READ, 0x6e05, 0x18 },
+{ "linux/ncp_fs.h", "NCP_IOC_SIGN_WANTED", _IOC_READ, 0x6e06, 0x04 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_CAP", _IOC_READ|_IOC_WRITE, 0x4e01, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_START", _IOC_READ|_IOC_WRITE, 0x4e02, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_ARS_STATUS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x30 },
+{ "linux/ndctl.h", "ND_IOCTL_CALL", _IOC_READ|_IOC_WRITE, 0x4e0a, 0x40 },
+{ "linux/ndctl.h", "ND_IOCTL_CLEAR_ERROR", _IOC_READ|_IOC_WRITE, 0x4e04, 0x20 },
+{ "linux/ndctl.h", "ND_IOCTL_DIMM_FLAGS", _IOC_READ|_IOC_WRITE, 0x4e03, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e05, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_GET_CONFIG_SIZE", _IOC_READ|_IOC_WRITE, 0x4e04, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_SET_CONFIG_DATA", _IOC_READ|_IOC_WRITE, 0x4e06, 0x08 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART", _IOC_READ|_IOC_WRITE, 0x4e01, 0x84 },
+{ "linux/ndctl.h", "ND_IOCTL_SMART_THRESHOLD", _IOC_READ|_IOC_WRITE, 0x4e02, 0x0c },
+{ "linux/ndctl.h", "ND_IOCTL_VENDOR", _IOC_READ|_IOC_WRITE, 0x4e09, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CHANGE_CPMODE", _IOC_WRITE, 0x6e80, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_CLEAN_SEGMENTS", _IOC_WRITE, 0x6e88, 0x78 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_DELETE_CHECKPOINT", _IOC_WRITE, 0x6e81, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_BDESCS", _IOC_READ|_IOC_WRITE, 0x6e87, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPINFO", _IOC_READ, 0x6e82, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_CPSTAT", _IOC_READ, 0x6e83, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUINFO", _IOC_READ, 0x6e84, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_SUSTAT", _IOC_READ, 0x6e85, 0x30 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_GET_VINFO", _IOC_READ|_IOC_WRITE, 0x6e86, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_RESIZE", _IOC_WRITE, 0x6e8b, 0x08 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_ALLOC_RANGE", _IOC_WRITE, 0x6e8c, 0x10 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SET_SUINFO", _IOC_WRITE, 0x6e8d, 0x18 },
+{ "linux/nilfs2_fs.h", "NILFS_IOCTL_SYNC", _IOC_READ, 0x6e8a, 0x08 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ADMIN_CMD", _IOC_READ|_IOC_WRITE, 0x4e41, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_ID", _IOC_NONE, 0x4e40, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_IO_CMD", _IOC_READ|_IOC_WRITE, 0x4e43, 0x48 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESCAN", _IOC_NONE, 0x4e46, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_RESET", _IOC_NONE, 0x4e44, 0x00 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBMIT_IO", _IOC_WRITE, 0x4e42, 0x30 },
+{ "linux/nvme_ioctl.h", "NVME_IOCTL_SUBSYS_RESET", _IOC_NONE, 0x4e45, 0x00 },
+{ "linux/nvram.h", "NVRAM_INIT", _IOC_NONE, 0x7040, 0x00 },
+{ "linux/nvram.h", "NVRAM_SETCKS", _IOC_NONE, 0x7041, 0x00 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AEWB_CFG", _IOC_READ|_IOC_WRITE, 0x56c3, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_AF_CFG", _IOC_READ|_IOC_WRITE, 0x56c5, 0x4c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_CCDC_CFG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x20 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_HIST_CFG", _IOC_READ|_IOC_WRITE, 0x56c4, 0x30 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_PRV_CFG", _IOC_READ|_IOC_WRITE, 0x56c2, 0x3c },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_EN", _IOC_READ|_IOC_WRITE, 0x56c7, 0x04 },
+{ "linux/omap3isp.h", "VIDIOC_OMAP3ISP_STAT_REQ", _IOC_READ|_IOC_WRITE, 0x56c6, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_CTRL_TEST", _IOC_WRITE, 0x4f2e, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_CAPS", _IOC_READ, 0x4f2a, 0x0c },
+{ "linux/omapfb.h", "OMAPFB_GET_COLOR_KEY", _IOC_WRITE, 0x4f33, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_GET_DISPLAY_INFO", _IOC_READ, 0x4f3f, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_GET_OVERLAY_COLORMODE", _IOC_READ, 0x4f3b, 0x3c },
+{ "linux/omapfb.h", "OMAPFB_GET_UPDATE_MODE", _IOC_WRITE, 0x4f2b, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_GET_VRAM_INFO", _IOC_READ, 0x4f3d, 0x20 },
+{ "linux/omapfb.h", "OMAPFB_LCD_TEST", _IOC_WRITE, 0x4f2d, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_MEMORY_READ", _IOC_READ, 0x4f3a, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_MIRROR", _IOC_WRITE, 0x4f1f, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_MEM", _IOC_WRITE, 0x4f38, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_QUERY_PLANE", _IOC_WRITE, 0x4f35, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_MEM", _IOC_WRITE, 0x4f37, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SETUP_PLANE", _IOC_WRITE, 0x4f34, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_SET_COLOR_KEY", _IOC_WRITE, 0x4f32, 0x10 },
+{ "linux/omapfb.h", "OMAPFB_SET_TEARSYNC", _IOC_WRITE, 0x4f3e, 0x08 },
+{ "linux/omapfb.h", "OMAPFB_SET_UPDATE_MODE", _IOC_WRITE, 0x4f28, 0x04 },
+{ "linux/omapfb.h", "OMAPFB_SYNC_GFX", _IOC_NONE, 0x4f25, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW", _IOC_WRITE, 0x4f36, 0x44 },
+{ "linux/omapfb.h", "OMAPFB_UPDATE_WINDOW_OLD", _IOC_WRITE, 0x4f2f, 0x14 },
+{ "linux/omapfb.h", "OMAPFB_VSYNC", _IOC_NONE, 0x4f26, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORGO", _IOC_NONE, 0x4f3c, 0x00 },
+{ "linux/omapfb.h", "OMAPFB_WAITFORVSYNC", _IOC_NONE, 0x4f39, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_DISABLE", _IOC_NONE, 0x2401, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ENABLE", _IOC_NONE, 0x2400, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_ID", _IOC_READ, 0x2407, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PAUSE_OUTPUT", _IOC_WRITE, 0x2409, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_PERIOD", _IOC_WRITE, 0x2404, 0x08 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_REFRESH", _IOC_NONE, 0x2402, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_RESET", _IOC_NONE, 0x2403, 0x00 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_BPF", _IOC_WRITE, 0x2408, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_FILTER", _IOC_WRITE, 0x2406, 0x04 },
+{ "linux/perf_event.h", "PERF_EVENT_IOC_SET_OUTPUT", _IOC_NONE, 0x2405, 0x00 },
+{ "linux/phantom.h", "PHN_GETREG", _IOC_READ|_IOC_WRITE, 0x7005, 0x08 },
+{ "linux/phantom.h", "PHN_GETREGS", _IOC_READ|_IOC_WRITE, 0x7007, 0x28 },
+{ "linux/phantom.h", "PHN_GET_REG", _IOC_READ|_IOC_WRITE, 0x7000, 0x04 },
+{ "linux/phantom.h", "PHN_GET_REGS", _IOC_READ|_IOC_WRITE, 0x7002, 0x04 },
+{ "linux/phantom.h", "PHN_NOT_OH", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/phantom.h", "PHN_SETREG", _IOC_WRITE, 0x7006, 0x08 },
+{ "linux/phantom.h", "PHN_SETREGS", _IOC_WRITE, 0x7008, 0x28 },
+{ "linux/phantom.h", "PHN_SET_REG", _IOC_WRITE, 0x7001, 0x04 },
+{ "linux/phantom.h", "PHN_SET_REGS", _IOC_WRITE, 0x7003, 0x04 },
+{ "linux/pktcdvd.h", "PACKET_CTRL_CMD", _IOC_READ|_IOC_WRITE, 0x5801, 0x18 },
+{ "linux/platform_data/media/si4713.h", "SI4713_IOC_MEASURE_RNL", _IOC_READ|_IOC_WRITE, 0x56c0, 0x1c },
+{ "linux/pmu.h", "PMU_IOC_CAN_SLEEP", _IOC_READ, 0x4205, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GET_BACKLIGHT", _IOC_READ, 0x4201, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GET_MODEL", _IOC_READ, 0x4203, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_GRAB_BACKLIGHT", _IOC_READ, 0x4206, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_HAS_ADB", _IOC_READ, 0x4204, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_SET_BACKLIGHT", _IOC_WRITE, 0x4202, 0x04 },
+{ "linux/pmu.h", "PMU_IOC_SLEEP", _IOC_NONE, 0x4200, 0x00 },
+{ "linux/ppdev.h", "PPCLAIM", _IOC_NONE, 0x708b, 0x00 },
+{ "linux/ppdev.h", "PPCLRIRQ", _IOC_READ, 0x7093, 0x04 },
+{ "linux/ppdev.h", "PPDATADIR", _IOC_WRITE, 0x7090, 0x04 },
+{ "linux/ppdev.h", "PPEXCL", _IOC_NONE, 0x708f, 0x00 },
+{ "linux/ppdev.h", "PPFCONTROL", _IOC_WRITE, 0x708e, 0x02 },
+{ "linux/ppdev.h", "PPGETFLAGS", _IOC_READ, 0x709a, 0x04 },
+{ "linux/ppdev.h", "PPGETMODE", _IOC_READ, 0x7098, 0x04 },
+{ "linux/ppdev.h", "PPGETMODES", _IOC_READ, 0x7097, 0x04 },
+{ "linux/ppdev.h", "PPGETPHASE", _IOC_READ, 0x7099, 0x04 },
+{ "linux/ppdev.h", "PPGETTIME", _IOC_READ, 0x7095, 0x10 },
+{ "linux/ppdev.h", "PPNEGOT", _IOC_WRITE, 0x7091, 0x04 },
+{ "linux/ppdev.h", "PPRCONTROL", _IOC_READ, 0x7083, 0x01 },
+{ "linux/ppdev.h", "PPRDATA", _IOC_READ, 0x7085, 0x01 },
+{ "linux/ppdev.h", "PPRELEASE", _IOC_NONE, 0x708c, 0x00 },
+{ "linux/ppdev.h", "PPRSTATUS", _IOC_READ, 0x7081, 0x01 },
+{ "linux/ppdev.h", "PPSETFLAGS", _IOC_WRITE, 0x709b, 0x04 },
+{ "linux/ppdev.h", "PPSETMODE", _IOC_WRITE, 0x7080, 0x04 },
+{ "linux/ppdev.h", "PPSETPHASE", _IOC_WRITE, 0x7094, 0x04 },
+{ "linux/ppdev.h", "PPSETTIME", _IOC_WRITE, 0x7096, 0x10 },
+{ "linux/ppdev.h", "PPWCONTROL", _IOC_WRITE, 0x7084, 0x01 },
+{ "linux/ppdev.h", "PPWCTLONIRQ", _IOC_WRITE, 0x7092, 0x01 },
+{ "linux/ppdev.h", "PPWDATA", _IOC_WRITE, 0x7086, 0x01 },
+{ "linux/ppdev.h", "PPYIELD", _IOC_NONE, 0x708d, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTACH", _IOC_WRITE, 0x743d, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCATTCHAN", _IOC_WRITE, 0x7438, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCCONNECT", _IOC_WRITE, 0x743a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDETACH", _IOC_WRITE, 0x743c, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCDISCONN", _IOC_NONE, 0x7439, 0x00 },
+{ "linux/ppp-ioctl.h", "PPPIOCGASYNCMAP", _IOC_READ, 0x7458, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGCHAN", _IOC_READ, 0x7437, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGDEBUG", _IOC_READ, 0x7441, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGFLAGS", _IOC_READ, 0x745a, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGIDLE", _IOC_READ, 0x743f, 0x10 },
+{ "linux/ppp-ioctl.h", "PPPIOCGL2TPSTATS", _IOC_READ, 0x7436, 0x48 },
+{ "linux/ppp-ioctl.h", "PPPIOCGMRU", _IOC_READ, 0x7453, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGNPMODE", _IOC_READ|_IOC_WRITE, 0x744c, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCGRASYNCMAP", _IOC_READ, 0x7455, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGUNIT", _IOC_READ, 0x7456, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCGXASYNCMAP", _IOC_READ, 0x7450, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCNEWUNIT", _IOC_READ|_IOC_WRITE, 0x743e, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSACTIVE", _IOC_WRITE, 0x7446, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSASYNCMAP", _IOC_WRITE, 0x7457, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSCOMPRESS", _IOC_WRITE, 0x744d, 0x0c },
+{ "linux/ppp-ioctl.h", "PPPIOCSDEBUG", _IOC_WRITE, 0x7440, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSFLAGS", _IOC_WRITE, 0x7459, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMAXCID", _IOC_WRITE, 0x7451, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRRU", _IOC_WRITE, 0x743b, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSMRU", _IOC_WRITE, 0x7452, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSNPMODE", _IOC_WRITE, 0x744b, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSPASS", _IOC_WRITE, 0x7447, 0x08 },
+{ "linux/ppp-ioctl.h", "PPPIOCSRASYNCMAP", _IOC_WRITE, 0x7454, 0x04 },
+{ "linux/ppp-ioctl.h", "PPPIOCSXASYNCMAP", _IOC_WRITE, 0x744f, 0x20 },
+{ "linux/ppp-ioctl.h", "PPPIOCXFERUNIT", _IOC_NONE, 0x744e, 0x00 },
+{ "linux/pps.h", "PPS_FETCH", _IOC_READ|_IOC_WRITE, 0x70a4, 0x04 },
+{ "linux/pps.h", "PPS_GETCAP", _IOC_READ, 0x70a3, 0x04 },
+{ "linux/pps.h", "PPS_GETPARAMS", _IOC_READ, 0x70a1, 0x04 },
+{ "linux/pps.h", "PPS_KC_BIND", _IOC_WRITE, 0x70a5, 0x04 },
+{ "linux/pps.h", "PPS_SETPARAMS", _IOC_WRITE, 0x70a2, 0x04 },
+{ "linux/pr.h", "IOC_PR_CLEAR", _IOC_WRITE, 0x70cd, 0x10 },
+{ "linux/pr.h", "IOC_PR_PREEMPT", _IOC_WRITE, 0x70cb, 0x18 },
+{ "linux/pr.h", "IOC_PR_PREEMPT_ABORT", _IOC_WRITE, 0x70cc, 0x18 },
+{ "linux/pr.h", "IOC_PR_REGISTER", _IOC_WRITE, 0x70c8, 0x18 },
+{ "linux/pr.h", "IOC_PR_RELEASE", _IOC_WRITE, 0x70ca, 0x10 },
+{ "linux/pr.h", "IOC_PR_RESERVE", _IOC_WRITE, 0x70c9, 0x10 },
+{ "linux/ptp_clock.h", "PTP_CLOCK_GETCAPS", _IOC_READ, 0x3d01, 0x50 },
+{ "linux/ptp_clock.h", "PTP_ENABLE_PPS", _IOC_WRITE, 0x3d04, 0x04 },
+{ "linux/ptp_clock.h", "PTP_EXTTS_REQUEST", _IOC_WRITE, 0x3d02, 0x10 },
+{ "linux/ptp_clock.h", "PTP_PEROUT_REQUEST", _IOC_WRITE, 0x3d03, 0x38 },
+{ "linux/ptp_clock.h", "PTP_PIN_GETFUNC", _IOC_READ|_IOC_WRITE, 0x3d06, 0x60 },
+{ "linux/ptp_clock.h", "PTP_PIN_SETFUNC", _IOC_WRITE, 0x3d07, 0x60 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET", _IOC_WRITE, 0x3d05, 0x340 },
+{ "linux/ptp_clock.h", "PTP_SYS_OFFSET_PRECISE", _IOC_READ|_IOC_WRITE, 0x3d08, 0x40 },
+{ "linux/radeonfb.h", "FBIO_RADEON_GET_MIRROR", _IOC_READ, 0x4003, 0x04 },
+{ "linux/radeonfb.h", "FBIO_RADEON_SET_MIRROR", _IOC_WRITE, 0x4004, 0x04 },
+{ "linux/raid/md_u.h", "ADD_NEW_DISK", _IOC_WRITE, 0x0921, 0x14 },
+{ "linux/raid/md_u.h", "CLEAR_ARRAY", _IOC_NONE, 0x0920, 0x00 },
+{ "linux/raid/md_u.h", "CLUSTERED_DISK_NACK", _IOC_NONE, 0x0935, 0x00 },
+{ "linux/raid/md_u.h", "GET_ARRAY_INFO", _IOC_READ, 0x0911, 0x48 },
+{ "linux/raid/md_u.h", "GET_BITMAP_FILE", _IOC_READ, 0x0915, 0x1000 },
+{ "linux/raid/md_u.h", "GET_DISK_INFO", _IOC_READ, 0x0912, 0x14 },
+{ "linux/raid/md_u.h", "HOT_ADD_DISK", _IOC_NONE, 0x0928, 0x00 },
+{ "linux/raid/md_u.h", "HOT_GENERATE_ERROR", _IOC_NONE, 0x092a, 0x00 },
+{ "linux/raid/md_u.h", "HOT_REMOVE_DISK", _IOC_NONE, 0x0922, 0x00 },
+{ "linux/raid/md_u.h", "PROTECT_ARRAY", _IOC_NONE, 0x0927, 0x00 },
+{ "linux/raid/md_u.h", "RAID_AUTORUN", _IOC_NONE, 0x0914, 0x00 },
+{ "linux/raid/md_u.h", "RAID_VERSION", _IOC_READ, 0x0910, 0x0c },
+{ "linux/raid/md_u.h", "RESTART_ARRAY_RW", _IOC_NONE, 0x0934, 0x00 },
+{ "linux/raid/md_u.h", "RUN_ARRAY", _IOC_WRITE, 0x0930, 0x0c },
+{ "linux/raid/md_u.h", "SET_ARRAY_INFO", _IOC_WRITE, 0x0923, 0x48 },
+{ "linux/raid/md_u.h", "SET_BITMAP_FILE", _IOC_WRITE, 0x092b, 0x04 },
+{ "linux/raid/md_u.h", "SET_DISK_FAULTY", _IOC_NONE, 0x0929, 0x00 },
+{ "linux/raid/md_u.h", "SET_DISK_INFO", _IOC_NONE, 0x0924, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY", _IOC_NONE, 0x0932, 0x00 },
+{ "linux/raid/md_u.h", "STOP_ARRAY_RO", _IOC_NONE, 0x0933, 0x00 },
+{ "linux/raid/md_u.h", "UNPROTECT_ARRAY", _IOC_NONE, 0x0926, 0x00 },
+{ "linux/raid/md_u.h", "WRITE_RAID_INFO", _IOC_NONE, 0x0925, 0x00 },
+{ "linux/random.h", "RNDADDENTROPY", _IOC_WRITE, 0x5203, 0x08 },
+{ "linux/random.h", "RNDADDTOENTCNT", _IOC_WRITE, 0x5201, 0x04 },
+{ "linux/random.h", "RNDCLEARPOOL", _IOC_NONE, 0x5206, 0x00 },
+{ "linux/random.h", "RNDGETENTCNT", _IOC_READ, 0x5200, 0x04 },
+{ "linux/random.h", "RNDGETPOOL", _IOC_READ, 0x5202, 0x08 },
+{ "linux/random.h", "RNDZAPENTCNT", _IOC_NONE, 0x5204, 0x00 },
+{ "linux/raw.h", "RAW_GETBIND", _IOC_NONE, 0xac01, 0x00 },
+{ "linux/raw.h", "RAW_SETBIND", _IOC_NONE, 0xac00, 0x00 },
+{ "linux/reiserfs_fs.h", "REISERFS_IOC_UNPACK", _IOC_WRITE, 0xcd01, 0x04 },
+{ "linux/rfkill.h", "RFKILL_IOCTL_NOINPUT", _IOC_NONE, 0x5201, 0x00 },
+{ "linux/rio_mport_cdev.h", "RIO_ALLOC_DMA", _IOC_READ|_IOC_WRITE, 0x6d13, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_ADD", _IOC_WRITE, 0x6d17, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DEV_DEL", _IOC_WRITE, 0x6d18, 0x20 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d0a, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_DISABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0c, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_DOORBELL_RANGE", _IOC_WRITE, 0x6d09, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_ENABLE_PORTWRITE_RANGE", _IOC_WRITE, 0x6d0b, 0x10 },
+{ "linux/rio_mport_cdev.h", "RIO_FREE_DMA", _IOC_WRITE, 0x6d14, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_GET_EVENT_MASK", _IOC_READ, 0x6d0e, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_INBOUND", _IOC_READ|_IOC_WRITE, 0x6d11, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MAP_OUTBOUND", _IOC_READ|_IOC_WRITE, 0x6d0f, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_GET_PROPERTIES", _IOC_READ, 0x6d04, 0x30 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_COMPTAG_SET", _IOC_WRITE, 0x6d02, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_HDID_SET", _IOC_WRITE, 0x6d01, 0x02 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_PORT_IDX_GET", _IOC_READ, 0x6d03, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_LOCAL", _IOC_READ, 0x6d05, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_READ_REMOTE", _IOC_READ, 0x6d07, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_LOCAL", _IOC_WRITE, 0x6d06, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_MPORT_MAINT_WRITE_REMOTE", _IOC_WRITE, 0x6d08, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_SET_EVENT_MASK", _IOC_WRITE, 0x6d0d, 0x04 },
+{ "linux/rio_mport_cdev.h", "RIO_TRANSFER", _IOC_READ|_IOC_WRITE, 0x6d15, 0x18 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_INBOUND", _IOC_WRITE, 0x6d12, 0x08 },
+{ "linux/rio_mport_cdev.h", "RIO_UNMAP_OUTBOUND", _IOC_WRITE, 0x6d10, 0x28 },
+{ "linux/rio_mport_cdev.h", "RIO_WAIT_FOR_ASYNC", _IOC_WRITE, 0x6d16, 0x08 },
+{ "linux/rtc.h", "RTC_AIE_OFF", _IOC_NONE, 0x7002, 0x00 },
+{ "linux/rtc.h", "RTC_AIE_ON", _IOC_NONE, 0x7001, 0x00 },
+{ "linux/rtc.h", "RTC_ALM_READ", _IOC_READ, 0x7008, 0x24 },
+{ "linux/rtc.h", "RTC_ALM_SET", _IOC_WRITE, 0x7007, 0x24 },
+{ "linux/rtc.h", "RTC_EPOCH_READ", _IOC_READ, 0x700d, 0x04 },
+{ "linux/rtc.h", "RTC_EPOCH_SET", _IOC_WRITE, 0x700e, 0x04 },
+{ "linux/rtc.h", "RTC_IRQP_READ", _IOC_READ, 0x700b, 0x04 },
+{ "linux/rtc.h", "RTC_IRQP_SET", _IOC_WRITE, 0x700c, 0x04 },
+{ "linux/rtc.h", "RTC_PIE_OFF", _IOC_NONE, 0x7006, 0x00 },
+{ "linux/rtc.h", "RTC_PIE_ON", _IOC_NONE, 0x7005, 0x00 },
+{ "linux/rtc.h", "RTC_PLL_GET", _IOC_READ, 0x7011, 0x1c },
+{ "linux/rtc.h", "RTC_PLL_SET", _IOC_WRITE, 0x7012, 0x1c },
+{ "linux/rtc.h", "RTC_RD_TIME", _IOC_READ, 0x7009, 0x24 },
+{ "linux/rtc.h", "RTC_SET_TIME", _IOC_WRITE, 0x700a, 0x24 },
+{ "linux/rtc.h", "RTC_UIE_OFF", _IOC_NONE, 0x7004, 0x00 },
+{ "linux/rtc.h", "RTC_UIE_ON", _IOC_NONE, 0x7003, 0x00 },
+{ "linux/rtc.h", "RTC_VL_CLR", _IOC_NONE, 0x7014, 0x00 },
+{ "linux/rtc.h", "RTC_VL_READ", _IOC_READ, 0x7013, 0x04 },
+{ "linux/rtc.h", "RTC_WIE_OFF", _IOC_NONE, 0x7010, 0x00 },
+{ "linux/rtc.h", "RTC_WIE_ON", _IOC_NONE, 0x700f, 0x00 },
+{ "linux/rtc.h", "RTC_WKALM_RD", _IOC_READ, 0x7010, 0x28 },
+{ "linux/rtc.h", "RTC_WKALM_SET", _IOC_WRITE, 0x700f, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREG", _IOC_READ|_IOC_WRITE, 0x7305, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_ACCEPTREQ", _IOC_READ|_IOC_WRITE, 0x7304, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_BIND", _IOC_READ|_IOC_WRITE, 0x7301, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_CONNECT", _IOC_READ|_IOC_WRITE, 0x7303, 0x08 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_MARK", _IOC_READ|_IOC_WRITE, 0x730f, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_SIGNAL", _IOC_READ|_IOC_WRITE, 0x7311, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_FENCE_WAIT", _IOC_READ|_IOC_WRITE, 0x7310, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_GET_NODEIDS", _IOC_READ|_IOC_WRITE, 0x730e, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_LISTEN", _IOC_WRITE, 0x7302, 0x04 },
+{ "linux/scif_ioctl.h", "SCIF_READFROM", _IOC_READ|_IOC_WRITE, 0x730a, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_RECV", _IOC_READ|_IOC_WRITE, 0x7307, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_REG", _IOC_READ|_IOC_WRITE, 0x7308, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_SEND", _IOC_READ|_IOC_WRITE, 0x7306, 0x18 },
+{ "linux/scif_ioctl.h", "SCIF_UNREG", _IOC_READ|_IOC_WRITE, 0x7309, 0x10 },
+{ "linux/scif_ioctl.h", "SCIF_VREADFROM", _IOC_READ|_IOC_WRITE, 0x730c, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_VWRITETO", _IOC_READ|_IOC_WRITE, 0x730d, 0x28 },
+{ "linux/scif_ioctl.h", "SCIF_WRITETO", _IOC_READ|_IOC_WRITE, 0x730b, 0x28 },
+{ "linux/serio.h", "SPIOCSTYPE", _IOC_WRITE, 0x7101, 0x04 },
+{ "linux/sockios.h", "SIOCADDDLCI", 0, 0x8980, 0 },
+{ "linux/sockios.h", "SIOCADDMULTI", 0, 0x8931, 0 },
+{ "linux/sockios.h", "SIOCADDRT", 0, 0x890B, 0 },
+{ "linux/sockios.h", "SIOCBONDCHANGEACTIVE", 0, 0x8995, 0 },
+{ "linux/sockios.h", "SIOCBONDENSLAVE", 0, 0x8990, 0 },
+{ "linux/sockios.h", "SIOCBONDINFOQUERY", 0, 0x8994, 0 },
+{ "linux/sockios.h", "SIOCBONDRELEASE", 0, 0x8991, 0 },
+{ "linux/sockios.h", "SIOCBONDSETHWADDR", 0, 0x8992, 0 },
+{ "linux/sockios.h", "SIOCBONDSLAVEINFOQUERY", 0, 0x8993, 0 },
+{ "linux/sockios.h", "SIOCBRADDBR", 0, 0x89a0, 0 },
+{ "linux/sockios.h", "SIOCBRADDIF", 0, 0x89a2, 0 },
+{ "linux/sockios.h", "SIOCBRDELBR", 0, 0x89a1, 0 },
+{ "linux/sockios.h", "SIOCBRDELIF", 0, 0x89a3, 0 },
+{ "linux/sockios.h", "SIOCDARP", 0, 0x8953, 0 },
+{ "linux/sockios.h", "SIOCDELDLCI", 0, 0x8981, 0 },
+{ "linux/sockios.h", "SIOCDELMULTI", 0, 0x8932, 0 },
+{ "linux/sockios.h", "SIOCDELRT", 0, 0x890C, 0 },
+{ "linux/sockios.h", "SIOCDEVPRIVATE", 0, 0x89F0, 0 },
+{ "linux/sockios.h", "SIOCDIFADDR", 0, 0x8936, 0 },
+{ "linux/sockios.h", "SIOCDRARP", 0, 0x8960, 0 },
+{ "linux/sockios.h", "SIOCETHTOOL", 0, 0x8946, 0 },
+{ "linux/sockios.h", "SIOCGARP", 0, 0x8954, 0 },
+{ "linux/sockios.h", "SIOCGHWTSTAMP", 0, 0x89b1, 0 },
+{ "linux/sockios.h", "SIOCGIFADDR", 0, 0x8915, 0 },
+{ "linux/sockios.h", "SIOCGIFBR", 0, 0x8940, 0 },
+{ "linux/sockios.h", "SIOCGIFBRDADDR", 0, 0x8919, 0 },
+{ "linux/sockios.h", "SIOCGIFCONF", 0, 0x8912, 0 },
+{ "linux/sockios.h", "SIOCGIFCOUNT", 0, 0x8938, 0 },
+{ "linux/sockios.h", "SIOCGIFDSTADDR", 0, 0x8917, 0 },
+{ "linux/sockios.h", "SIOCGIFENCAP", 0, 0x8925, 0 },
+{ "linux/sockios.h", "SIOCGIFFLAGS", 0, 0x8913, 0 },
+{ "linux/sockios.h", "SIOCGIFHWADDR", 0, 0x8927, 0 },
+{ "linux/sockios.h", "SIOCGIFINDEX", 0, 0x8933, 0 },
+{ "linux/sockios.h", "SIOCGIFMAP", 0, 0x8970, 0 },
+{ "linux/sockios.h", "SIOCGIFMEM", 0, 0x891f, 0 },
+{ "linux/sockios.h", "SIOCGIFMETRIC", 0, 0x891d, 0 },
+{ "linux/sockios.h", "SIOCGIFMTU", 0, 0x8921, 0 },
+{ "linux/sockios.h", "SIOCGIFNAME", 0, 0x8910, 0 },
+{ "linux/sockios.h", "SIOCGIFNETMASK", 0, 0x891b, 0 },
+{ "linux/sockios.h", "SIOCGIFPFLAGS", 0, 0x8935, 0 },
+{ "linux/sockios.h", "SIOCGIFSLAVE", 0, 0x8929, 0 },
+{ "linux/sockios.h", "SIOCGIFTXQLEN", 0, 0x8942, 0 },
+{ "linux/sockios.h", "SIOCGIFVLAN", 0, 0x8982, 0 },
+{ "linux/sockios.h", "SIOCGMIIPHY", 0, 0x8947, 0 },
+{ "linux/sockios.h", "SIOCGMIIREG", 0, 0x8948, 0 },
+{ "linux/sockios.h", "SIOCGRARP", 0, 0x8961, 0 },
+{ "linux/sockios.h", "SIOCOUTQNSD", 0, 0x894B, 0 },
+{ "linux/sockios.h", "SIOCPROTOPRIVATE", 0, 0x89E0, 0 },
+{ "linux/sockios.h", "SIOCRTMSG", 0, 0x890D, 0 },
+{ "linux/sockios.h", "SIOCSARP", 0, 0x8955, 0 },
+{ "linux/sockios.h", "SIOCSHWTSTAMP", 0, 0x89b0, 0 },
+{ "linux/sockios.h", "SIOCSIFADDR", 0, 0x8916, 0 },
+{ "linux/sockios.h", "SIOCSIFBR", 0, 0x8941, 0 },
+{ "linux/sockios.h", "SIOCSIFBRDADDR", 0, 0x891a, 0 },
+{ "linux/sockios.h", "SIOCSIFDSTADDR", 0, 0x8918, 0 },
+{ "linux/sockios.h", "SIOCSIFENCAP", 0, 0x8926, 0 },
+{ "linux/sockios.h", "SIOCSIFFLAGS", 0, 0x8914, 0 },
+{ "linux/sockios.h", "SIOCSIFHWADDR", 0, 0x8924, 0 },
+{ "linux/sockios.h", "SIOCSIFHWBROADCAST", 0, 0x8937, 0 },
+{ "linux/sockios.h", "SIOCSIFLINK", 0, 0x8911, 0 },
+{ "linux/sockios.h", "SIOCSIFMAP", 0, 0x8971, 0 },
+{ "linux/sockios.h", "SIOCSIFMEM", 0, 0x8920, 0 },
+{ "linux/sockios.h", "SIOCSIFMETRIC", 0, 0x891e, 0 },
+{ "linux/sockios.h", "SIOCSIFMTU", 0, 0x8922, 0 },
+{ "linux/sockios.h", "SIOCSIFNAME", 0, 0x8923, 0 },
+{ "linux/sockios.h", "SIOCSIFNETMASK", 0, 0x891c, 0 },
+{ "linux/sockios.h", "SIOCSIFPFLAGS", 0, 0x8934, 0 },
+{ "linux/sockios.h", "SIOCSIFSLAVE", 0, 0x8930, 0 },
+{ "linux/sockios.h", "SIOCSIFTXQLEN", 0, 0x8943, 0 },
+{ "linux/sockios.h", "SIOCSIFVLAN", 0, 0x8983, 0 },
+{ "linux/sockios.h", "SIOCSMIIREG", 0, 0x8949, 0 },
+{ "linux/sockios.h", "SIOCSRARP", 0, 0x8962, 0 },
+{ "linux/sockios.h", "SIOCWANDEV", 0, 0x894A, 0 },
+{ "linux/sonet.h", "SONET_CLRDIAG", _IOC_READ|_IOC_WRITE, 0x6113, 0x04 },
+{ "linux/sonet.h", "SONET_GETDIAG", _IOC_READ, 0x6114, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRAMING", _IOC_READ, 0x6116, 0x04 },
+{ "linux/sonet.h", "SONET_GETFRSENSE", _IOC_READ, 0x6117, 0x06 },
+{ "linux/sonet.h", "SONET_GETSTAT", _IOC_READ, 0x6110, 0x24 },
+{ "linux/sonet.h", "SONET_GETSTATZ", _IOC_READ, 0x6111, 0x24 },
+{ "linux/sonet.h", "SONET_SETDIAG", _IOC_READ|_IOC_WRITE, 0x6112, 0x04 },
+{ "linux/sonet.h", "SONET_SETFRAMING", _IOC_WRITE, 0x6115, 0x04 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1CAP", _IOC_READ, 0x7602, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT1REM", _IOC_READ, 0x7603, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2CAP", _IOC_READ, 0x7604, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBAT2REM", _IOC_READ, 0x7605, 0x02 },
+{ "linux/sonypi.h", "SONYPI_IOCGBATFLAGS", _IOC_READ, 0x7607, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBLUE", _IOC_READ, 0x7608, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGBRT", _IOC_READ, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGFAN", _IOC_READ, 0x760a, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCGTEMP", _IOC_READ, 0x760c, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBLUE", _IOC_WRITE, 0x7609, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSBRT", _IOC_WRITE, 0x7600, 0x01 },
+{ "linux/sonypi.h", "SONYPI_IOCSFAN", _IOC_WRITE, 0x760b, 0x01 },
+{ "linux/soundcard.h", "OSS_GETVERSION", _IOC_READ, 0x4d76, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_COPR_HALT", _IOC_READ|_IOC_WRITE, 0x4307, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_LOAD", _IOC_READ|_IOC_WRITE, 0x4301, 0xfb0 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCODE", _IOC_READ|_IOC_WRITE, 0x4303, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RCVMSG", _IOC_READ, 0x4309, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RDATA", _IOC_READ|_IOC_WRITE, 0x4302, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RESET", _IOC_NONE, 0x4300, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_COPR_RUN", _IOC_READ|_IOC_WRITE, 0x4306, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_SENDMSG", _IOC_READ|_IOC_WRITE, 0x4308, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WCODE", _IOC_WRITE, 0x4305, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_COPR_WDATA", _IOC_WRITE, 0x4304, 0x14 },
+{ "linux/soundcard.h", "SNDCTL_DSP_BIND_CHANNEL", _IOC_READ|_IOC_WRITE, 0x5041, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_CHANNELS", _IOC_READ|_IOC_WRITE, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETBLKSIZE", _IOC_READ|_IOC_WRITE, 0x5004, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCAPS", _IOC_READ, 0x500f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETCHANNELMASK", _IOC_READ|_IOC_WRITE, 0x5040, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETFMTS", _IOC_READ, 0x500b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETIPTR", _IOC_READ, 0x5011, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETISPACE", _IOC_READ, 0x500d, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETODELAY", _IOC_READ, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOPTR", _IOC_READ, 0x5012, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETOSPACE", _IOC_READ, 0x500c, 0x10 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETSPDIF", _IOC_READ, 0x5043, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_GETTRIGGER", _IOC_READ, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPINBUF", _IOC_READ, 0x5013, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_DSP_MAPOUTBUF", _IOC_READ, 0x5014, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_DSP_NONBLOCK", _IOC_NONE, 0x500e, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_POST", _IOC_NONE, 0x5008, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_PROFILE", _IOC_WRITE, 0x5017, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_RESET", _IOC_NONE, 0x5000, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETDUPLEX", _IOC_NONE, 0x5016, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFMT", _IOC_READ|_IOC_WRITE, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETFRAGMENT", _IOC_READ|_IOC_WRITE, 0x500a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSPDIF", _IOC_WRITE, 0x5042, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETSYNCRO", _IOC_NONE, 0x5015, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SETTRIGGER", _IOC_WRITE, 0x5010, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SPEED", _IOC_READ|_IOC_WRITE, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_STEREO", _IOC_READ|_IOC_WRITE, 0x5003, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SUBDIVIDE", _IOC_READ|_IOC_WRITE, 0x5009, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_DSP_SYNC", _IOC_NONE, 0x5001, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_FM_4OP_ENABLE", _IOC_WRITE, 0x510f, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_FM_LOAD_INSTR", _IOC_WRITE, 0x5107, 0x28 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_INFO", _IOC_READ|_IOC_WRITE, 0x510c, 0x74 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUCMD", _IOC_READ|_IOC_WRITE, 0x6d02, 0x21 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_MPUMODE", _IOC_READ|_IOC_WRITE, 0x6d01, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_MIDI_PRETIME", _IOC_READ|_IOC_WRITE, 0x6d00, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_CTRLRATE", _IOC_READ|_IOC_WRITE, 0x5103, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETINCOUNT", _IOC_READ, 0x5105, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETOUTCOUNT", _IOC_READ, 0x5104, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_GETTIME", _IOC_READ, 0x5113, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRMIDIS", _IOC_READ, 0x510b, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_NRSYNTHS", _IOC_READ, 0x510a, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_OUTOFBAND", _IOC_WRITE, 0x5112, 0x08 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PANIC", _IOC_NONE, 0x5111, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_PERCMODE", _IOC_WRITE, 0x5106, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESET", _IOC_NONE, 0x5100, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_RESETSAMPLES", _IOC_WRITE, 0x5109, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_SYNC", _IOC_NONE, 0x5101, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_TESTMIDI", _IOC_WRITE, 0x5108, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SEQ_THRESHOLD", _IOC_WRITE, 0x510d, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_CONTROL", _IOC_READ|_IOC_WRITE, 0x5115, 0xfa4 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_ID", _IOC_READ|_IOC_WRITE, 0x5114, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_INFO", _IOC_READ|_IOC_WRITE, 0x5102, 0x8c },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_MEMAVL", _IOC_READ|_IOC_WRITE, 0x510e, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_SYNTH_REMOVESAMPLE", _IOC_READ|_IOC_WRITE, 0x5116, 0x0c },
+{ "linux/soundcard.h", "SNDCTL_TMR_CONTINUE", _IOC_NONE, 0x5404, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_METRONOME", _IOC_WRITE, 0x5407, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SELECT", _IOC_WRITE, 0x5408, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_SOURCE", _IOC_READ|_IOC_WRITE, 0x5406, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_START", _IOC_NONE, 0x5402, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_STOP", _IOC_NONE, 0x5403, 0x00 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TEMPO", _IOC_READ|_IOC_WRITE, 0x5405, 0x04 },
+{ "linux/soundcard.h", "SNDCTL_TMR_TIMEBASE", _IOC_READ|_IOC_WRITE, 0x5401, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_3DSE", _IOC_READ|_IOC_WRITE, 0x4d68, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_ACCESS", _IOC_READ|_IOC_WRITE, 0x4d66, 0x80 },
+{ "linux/soundcard.h", "SOUND_MIXER_AGC", _IOC_READ|_IOC_WRITE, 0x4d67, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_GETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d74, 0xa4 },
+{ "linux/soundcard.h", "SOUND_MIXER_INFO", _IOC_READ, 0x4d65, 0x5c },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE1", _IOC_READ|_IOC_WRITE, 0x4d6f, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE2", _IOC_READ|_IOC_WRITE, 0x4d70, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE3", _IOC_READ|_IOC_WRITE, 0x4d71, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE4", _IOC_READ|_IOC_WRITE, 0x4d72, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_PRIVATE5", _IOC_READ|_IOC_WRITE, 0x4d73, 0x04 },
+{ "linux/soundcard.h", "SOUND_MIXER_SETLEVELS", _IOC_READ|_IOC_WRITE, 0x4d75, 0xa4 },
+{ "linux/soundcard.h", "SOUND_OLD_MIXER_INFO", _IOC_READ, 0x4d65, 0x30 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_BITS", _IOC_READ, 0x5005, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_CHANNELS", _IOC_READ, 0x5006, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_FILTER", _IOC_READ, 0x5007, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_READ_RATE", _IOC_READ, 0x5002, 0x04 },
+{ "linux/soundcard.h", "SOUND_PCM_WRITE_FILTER", _IOC_READ|_IOC_WRITE, 0x5007, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_BITS_PER_WORD", _IOC_READ, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_LSB_FIRST", _IOC_READ, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MAX_SPEED_HZ", _IOC_READ, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE", _IOC_READ, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_RD_MODE32", _IOC_READ, 0x6b05, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_BITS_PER_WORD", _IOC_WRITE, 0x6b03, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_LSB_FIRST", _IOC_WRITE, 0x6b02, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MAX_SPEED_HZ", _IOC_WRITE, 0x6b04, 0x04 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE", _IOC_WRITE, 0x6b01, 0x01 },
+{ "linux/spi/spidev.h", "SPI_IOC_WR_MODE32", _IOC_WRITE, 0x6b05, 0x04 },
+{ "linux/stm.h", "STP_POLICY_ID_GET", _IOC_READ, 0x2501, 0x10 },
+{ "linux/stm.h", "STP_POLICY_ID_SET", _IOC_READ|_IOC_WRITE, 0x2500, 0x10 },
+{ "linux/stm.h", "STP_SET_OPTIONS", _IOC_WRITE, 0x2502, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ALLOC_SWAP_PAGE", _IOC_READ, 0x3314, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_ATOMIC_RESTORE", _IOC_NONE, 0x3304, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_AVAIL_SWAP_SIZE", _IOC_READ, 0x3313, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_CREATE_IMAGE", _IOC_WRITE, 0x3311, 0x04 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE", _IOC_NONE, 0x3305, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREEZE", _IOC_NONE, 0x3301, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_FREE_SWAP_PAGES", _IOC_NONE, 0x3309, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_GET_IMAGE_SIZE", _IOC_READ, 0x330e, 0x08 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PLATFORM_SUPPORT", _IOC_NONE, 0x330f, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_POWER_OFF", _IOC_NONE, 0x3310, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_PREF_IMAGE_SIZE", _IOC_NONE, 0x3312, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_S2RAM", _IOC_NONE, 0x330b, 0x00 },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_SET_SWAP_AREA", _IOC_WRITE, 0x330d, 0x0c },
+{ "linux/suspend_ioctls.h", "SNAPSHOT_UNFREEZE", _IOC_NONE, 0x3302, 0x00 },
+{ "linux/sync_file.h", "SYNC_IOC_FILE_INFO", _IOC_READ|_IOC_WRITE, 0x3e04, 0x38 },
+{ "linux/sync_file.h", "SYNC_IOC_MERGE", _IOC_READ|_IOC_WRITE, 0x3e03, 0x30 },
+{ "linux/synclink.h", "MGSL_IOCCLRMODCOUNT", _IOC_NONE, 0x6d0f, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGGPIO", _IOC_READ, 0x6d11, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCGIF", _IOC_NONE, 0x6d0b, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGPARAMS", _IOC_READ, 0x6d01, 0x20 },
+{ "linux/synclink.h", "MGSL_IOCGSTATS", _IOC_NONE, 0x6d07, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGTXIDLE", _IOC_NONE, 0x6d03, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXCTRL", _IOC_NONE, 0x6d16, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCGXSYNC", _IOC_NONE, 0x6d14, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCLOOPTXDONE", _IOC_NONE, 0x6d09, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCRXENABLE", _IOC_NONE, 0x6d05, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSGPIO", _IOC_WRITE, 0x6d10, 0x10 },
+{ "linux/synclink.h", "MGSL_IOCSIF", _IOC_NONE, 0x6d0a, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSPARAMS", _IOC_WRITE, 0x6d00, 0x20 },
+{ "linux/synclink.h", "MGSL_IOCSTXIDLE", _IOC_NONE, 0x6d02, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXCTRL", _IOC_NONE, 0x6d15, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCSXSYNC", _IOC_NONE, 0x6d13, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXABORT", _IOC_NONE, 0x6d06, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCTXENABLE", _IOC_NONE, 0x6d04, 0x00 },
+{ "linux/synclink.h", "MGSL_IOCWAITEVENT", _IOC_READ|_IOC_WRITE, 0x6d08, 0x04 },
+{ "linux/synclink.h", "MGSL_IOCWAITGPIO", _IOC_READ|_IOC_WRITE, 0x6d12, 0x10 },
+{ "linux/telephony.h", "OLD_PHONE_RING_START", _IOC_NONE, 0x7187, 0x00 },
+{ "linux/telephony.h", "PHONE_BUSY", _IOC_NONE, 0x71a1, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES", _IOC_NONE, 0x7180, 0x00 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_CHECK", _IOC_WRITE, 0x7182, 0x04 },
+{ "linux/telephony.h", "PHONE_CAPABILITIES_LIST", _IOC_READ, 0x7181, 0x04 },
+{ "linux/telephony.h", "PHONE_CPT_STOP", _IOC_NONE, 0x71a4, 0x00 },
+{ "linux/telephony.h", "PHONE_DIALTONE", _IOC_NONE, 0x71a3, 0x00 },
+{ "linux/telephony.h", "PHONE_DTMF_OOB", _IOC_WRITE, 0x7199, 0x04 },
+{ "linux/telephony.h", "PHONE_DTMF_READY", _IOC_READ, 0x7196, 0x04 },
+{ "linux/telephony.h", "PHONE_EXCEPTION", _IOC_READ, 0x719a, 0x04 },
+{ "linux/telephony.h", "PHONE_FRAME", _IOC_WRITE, 0x718d, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF", _IOC_READ, 0x7197, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_DTMF_ASCII", _IOC_READ, 0x7198, 0x04 },
+{ "linux/telephony.h", "PHONE_GET_TONE_OFF_TIME", _IOC_NONE, 0x719f, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_ON_TIME", _IOC_NONE, 0x719e, 0x00 },
+{ "linux/telephony.h", "PHONE_GET_TONE_STATE", _IOC_NONE, 0x71a0, 0x00 },
+{ "linux/telephony.h", "PHONE_HOOKSTATE", _IOC_NONE, 0x7184, 0x00 },
+{ "linux/telephony.h", "PHONE_MAXRINGS", _IOC_WRITE, 0x7185, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_CODEC", _IOC_WRITE, 0x7190, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_DEPTH", _IOC_WRITE, 0x7193, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_LEVEL", _IOC_NONE, 0x7195, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_START", _IOC_NONE, 0x7191, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_STOP", _IOC_NONE, 0x7192, 0x00 },
+{ "linux/telephony.h", "PHONE_PLAY_TONE", _IOC_WRITE, 0x719b, 0x01 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME", _IOC_WRITE, 0x7194, 0x04 },
+{ "linux/telephony.h", "PHONE_PLAY_VOLUME_LINEAR", _IOC_WRITE, 0x71dc, 0x04 },
+{ "linux/telephony.h", "PHONE_PSTN_GET_STATE", _IOC_NONE, 0x71a5, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_LINETEST", _IOC_NONE, 0x71a8, 0x00 },
+{ "linux/telephony.h", "PHONE_PSTN_SET_STATE", _IOC_WRITE, 0x71a4, 0x04 },
+{ "linux/telephony.h", "PHONE_QUERY_CODEC", _IOC_READ|_IOC_WRITE, 0x71a7, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_CODEC", _IOC_WRITE, 0x7189, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_DEPTH", _IOC_WRITE, 0x718c, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_LEVEL", _IOC_NONE, 0x718f, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_START", _IOC_NONE, 0x718a, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_STOP", _IOC_NONE, 0x718b, 0x00 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME", _IOC_WRITE, 0x718e, 0x04 },
+{ "linux/telephony.h", "PHONE_REC_VOLUME_LINEAR", _IOC_WRITE, 0x71db, 0x04 },
+{ "linux/telephony.h", "PHONE_RING", _IOC_NONE, 0x7183, 0x00 },
+{ "linux/telephony.h", "PHONE_RINGBACK", _IOC_NONE, 0x71a2, 0x00 },
+{ "linux/telephony.h", "PHONE_RING_CADENCE", _IOC_WRITE, 0x7186, 0x02 },
+{ "linux/telephony.h", "PHONE_RING_START", _IOC_WRITE, 0x7187, 0x04 },
+{ "linux/telephony.h", "PHONE_RING_STOP", _IOC_NONE, 0x7188, 0x00 },
+{ "linux/telephony.h", "PHONE_SET_TONE_OFF_TIME", _IOC_WRITE, 0x719d, 0x04 },
+{ "linux/telephony.h", "PHONE_SET_TONE_ON_TIME", _IOC_WRITE, 0x719c, 0x04 },
+{ "linux/telephony.h", "PHONE_VAD", _IOC_WRITE, 0x71a9, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK", _IOC_WRITE, 0x71aa, 0x04 },
+{ "linux/telephony.h", "PHONE_WINK_DURATION", _IOC_WRITE, 0x71a6, 0x04 },
+{ "linux/timerfd.h", "TFD_IOC_SET_TICKS", _IOC_WRITE, 0x5400, 0x08 },
+{ "linux/toshiba.h", "TOSHIBA_ACPI_SCI", _IOC_READ|_IOC_WRITE, 0x7491, 0x18 },
+{ "linux/toshiba.h", "TOSH_SMM", _IOC_READ|_IOC_WRITE, 0x7490, 0x18 },
+{ "linux/udf_fs_i.h", "UDF_GETEABLOCK", _IOC_READ, 0x6c41, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETEASIZE", _IOC_READ, 0x6c40, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_GETVOLIDENT", _IOC_READ, 0x6c42, 0x04 },
+{ "linux/udf_fs_i.h", "UDF_RELOCATE_BLOCKS", _IOC_READ|_IOC_WRITE, 0x6c43, 0x04 },
+{ "linux/uinput.h", "UI_ABS_SETUP", _IOC_WRITE, 0x5504, 0x1c },
+{ "linux/uinput.h", "UI_BEGIN_FF_ERASE", _IOC_READ|_IOC_WRITE, 0x55ca, 0x0c },
+{ "linux/uinput.h", "UI_BEGIN_FF_UPLOAD", _IOC_READ|_IOC_WRITE, 0x55c8, 0x60 },
+{ "linux/uinput.h", "UI_DEV_CREATE", _IOC_NONE, 0x5501, 0x00 },
+{ "linux/uinput.h", "UI_DEV_DESTROY", _IOC_NONE, 0x5502, 0x00 },
+{ "linux/uinput.h", "UI_DEV_SETUP", _IOC_WRITE, 0x5503, 0x5c },
+{ "linux/uinput.h", "UI_END_FF_ERASE", _IOC_WRITE, 0x55cb, 0x0c },
+{ "linux/uinput.h", "UI_END_FF_UPLOAD", _IOC_WRITE, 0x55c9, 0x60 },
+{ "linux/uinput.h", "UI_GET_VERSION", _IOC_READ, 0x552d, 0x04 },
+{ "linux/uinput.h", "UI_SET_ABSBIT", _IOC_WRITE, 0x5567, 0x04 },
+{ "linux/uinput.h", "UI_SET_EVBIT", _IOC_WRITE, 0x5564, 0x04 },
+{ "linux/uinput.h", "UI_SET_FFBIT", _IOC_WRITE, 0x556b, 0x04 },
+{ "linux/uinput.h", "UI_SET_KEYBIT", _IOC_WRITE, 0x5565, 0x04 },
+{ "linux/uinput.h", "UI_SET_LEDBIT", _IOC_WRITE, 0x5569, 0x04 },
+{ "linux/uinput.h", "UI_SET_MSCBIT", _IOC_WRITE, 0x5568, 0x04 },
+{ "linux/uinput.h", "UI_SET_PHYS", _IOC_WRITE, 0x556c, 0x04 },
+{ "linux/uinput.h", "UI_SET_PROPBIT", _IOC_WRITE, 0x556e, 0x04 },
+{ "linux/uinput.h", "UI_SET_RELBIT", _IOC_WRITE, 0x5566, 0x04 },
+{ "linux/uinput.h", "UI_SET_SNDBIT", _IOC_WRITE, 0x556a, 0x04 },
+{ "linux/uinput.h", "UI_SET_SWBIT", _IOC_WRITE, 0x556d, 0x04 },
+{ "linux/usb/cdc-wdm.h", "IOCTL_WDM_MAX_COMMAND", _IOC_READ, 0x48a0, 0x02 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_CLEAR_HALT", _IOC_NONE, 0x6703, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_DESC", _IOC_READ, 0x6782, 0x09 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_ENDPOINT_REVMAP", _IOC_NONE, 0x6781, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_FLUSH", _IOC_NONE, 0x6702, 0x00 },
+{ "linux/usb/functionfs.h", "FUNCTIONFS_FIFO_STATUS", _IOC_NONE, 0x6701, 0x00 },
+{ "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/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 },
+{ "linux/usb/iowarrior.h", "IOW_GETINFO", _IOC_READ, 0xc003, 0x28 },
+{ "linux/usb/iowarrior.h", "IOW_READ", _IOC_WRITE, 0xc002, 0x04 },
+{ "linux/usb/iowarrior.h", "IOW_WRITE", _IOC_WRITE, 0xc001, 0x04 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GET_CAPS", _IOC_READ, 0x5b11, 0x01 },
+{ "linux/usb/tmc.h", "USBTMC488_IOCTL_GOTO_LOCAL", _IOC_NONE, 0x5b14, 0x00 },
+{ "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", "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_INDICATOR_PULSE", _IOC_NONE, 0x5b01, 0x00 },
+{ "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 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIMINTERFACE", _IOC_READ, 0x550f, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLAIM_PORT", _IOC_READ, 0x5518, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CLEAR_HALT", _IOC_READ, 0x5515, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECT", _IOC_NONE, 0x5517, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONNECTINFO", _IOC_WRITE, 0x5511, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_CONTROL32", _IOC_READ|_IOC_WRITE, 0x5500, 0x10 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCARDURB", _IOC_NONE, 0x550b, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT", _IOC_NONE, 0x5516, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCONNECT_CLAIM", _IOC_READ, 0x551b, 0x108 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DISCSIGNAL32", _IOC_READ, 0x550e, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_DROP_PRIVILEGES", _IOC_WRITE, 0x551e, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_FREE_STREAMS", _IOC_READ, 0x551d, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GETDRIVER", _IOC_WRITE, 0x5508, 0x104 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_GET_CAPABILITIES", _IOC_READ, 0x551a, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_HUB_PORTINFO", _IOC_READ, 0x5513, 0x80 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_IOCTL32", _IOC_READ|_IOC_WRITE, 0x5512, 0x0c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURB32", _IOC_WRITE, 0x550c, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_REAPURBNDELAY32", _IOC_WRITE, 0x550d, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASEINTERFACE", _IOC_READ, 0x5510, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RELEASE_PORT", _IOC_READ, 0x5519, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESET", _IOC_NONE, 0x5514, 0x00 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_RESETEP", _IOC_READ, 0x5503, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETCONFIGURATION", _IOC_READ, 0x5505, 0x04 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SETINTERFACE", _IOC_READ, 0x5504, 0x08 },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB", _IOC_READ, 0x550a, 0x2c },
+{ "linux/usbdevice_fs.h", "USBDEVFS_SUBMITURB32", _IOC_READ, 0x550a, 0x2a },
+{ "linux/userfaultfd.h", "UFFDIO_API", _IOC_READ|_IOC_WRITE, 0xaa3f, 0x18 },
+{ "linux/userfaultfd.h", "UFFDIO_COPY", _IOC_READ|_IOC_WRITE, 0xaa03, 0x28 },
+{ "linux/userfaultfd.h", "UFFDIO_REGISTER", _IOC_READ|_IOC_WRITE, 0xaa00, 0x20 },
+{ "linux/userfaultfd.h", "UFFDIO_UNREGISTER", _IOC_READ, 0xaa01, 0x10 },
+{ "linux/userfaultfd.h", "UFFDIO_WAKE", _IOC_READ, 0xaa02, 0x10 },
+{ "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 },
+{ "linux/vfio.h", "VFIO_CHECK_EXTENSION", _IOC_NONE, 0x3b65, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_INFO", _IOC_NONE, 0x3b6b, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_IRQ_INFO", _IOC_NONE, 0x3b6d, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_PCI_HOT_RESET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_GET_REGION_INFO", _IOC_NONE, 0x3b6c, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_PCI_HOT_RESET", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_RESET", _IOC_NONE, 0x3b6f, 0x00 },
+{ "linux/vfio.h", "VFIO_DEVICE_SET_IRQS", _IOC_NONE, 0x3b6e, 0x00 },
+{ "linux/vfio.h", "VFIO_EEH_PE_OP", _IOC_NONE, 0x3b79, 0x00 },
+{ "linux/vfio.h", "VFIO_GET_API_VERSION", _IOC_NONE, 0x3b64, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_DEVICE_FD", _IOC_NONE, 0x3b6a, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_GET_STATUS", _IOC_NONE, 0x3b67, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_SET_CONTAINER", _IOC_NONE, 0x3b68, 0x00 },
+{ "linux/vfio.h", "VFIO_GROUP_UNSET_CONTAINER", _IOC_NONE, 0x3b69, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_DISABLE", _IOC_NONE, 0x3b74, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_ENABLE", _IOC_NONE, 0x3b73, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_MAP_DMA", _IOC_NONE, 0x3b71, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_REGISTER_MEMORY", _IOC_NONE, 0x3b75, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_CREATE", _IOC_NONE, 0x3b77, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_GET_INFO", _IOC_NONE, 0x3b70, 0x00 },
+{ "linux/vfio.h", "VFIO_IOMMU_SPAPR_TCE_REMOVE", _IOC_NONE, 0x3b78, 0x00 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_GET_VRING_ENDIAN", _IOC_WRITE, 0xaf14, 0x08 },
+{ "linux/vhost.h", "VHOST_NET_SET_BACKEND", _IOC_WRITE, 0xaf30, 0x08 },
+{ "linux/vhost.h", "VHOST_RESET_OWNER", _IOC_NONE, 0xaf02, 0x00 },
+{ "linux/vhost.h", "VHOST_SCSI_CLEAR_ENDPOINT", _IOC_WRITE, 0xaf41, 0xe8 },
+{ "linux/vhost.h", "VHOST_SCSI_GET_ABI_VERSION", _IOC_WRITE, 0xaf42, 0x04 },
+{ "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_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 },
+{ "linux/vhost.h", "VHOST_SET_MEM_TABLE", _IOC_WRITE, 0xaf03, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_OWNER", _IOC_NONE, 0xaf01, 0x00 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ADDR", _IOC_WRITE, 0xaf11, 0x28 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BASE", _IOC_WRITE, 0xaf12, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_BUSYLOOP_TIMEOUT", _IOC_WRITE, 0xaf23, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_CALL", _IOC_WRITE, 0xaf21, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ENDIAN", _IOC_WRITE, 0xaf13, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_ERR", _IOC_WRITE, 0xaf22, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_KICK", _IOC_WRITE, 0xaf20, 0x08 },
+{ "linux/vhost.h", "VHOST_SET_VRING_NUM", _IOC_WRITE, 0xaf10, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_CREATE_BUFS", _IOC_READ|_IOC_WRITE, 0x565c, 0xf8 },
+{ "linux/videodev2.h", "VIDIOC_CROPCAP", _IOC_READ|_IOC_WRITE, 0x563a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_CHIP_INFO", _IOC_READ|_IOC_WRITE, 0x5666, 0xc8 },
+{ "linux/videodev2.h", "VIDIOC_DBG_G_REGISTER", _IOC_READ|_IOC_WRITE, 0x5650, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DBG_S_REGISTER", _IOC_WRITE, 0x564f, 0x38 },
+{ "linux/videodev2.h", "VIDIOC_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5660, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_DQBUF", _IOC_READ|_IOC_WRITE, 0x5611, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_DQEVENT", _IOC_READ, 0x5659, 0x88 },
+{ "linux/videodev2.h", "VIDIOC_DV_TIMINGS_CAP", _IOC_READ|_IOC_WRITE, 0x5664, 0x90 },
+{ "linux/videodev2.h", "VIDIOC_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564d, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDIO", _IOC_READ|_IOC_WRITE, 0x5641, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMAUDOUT", _IOC_READ|_IOC_WRITE, 0x5642, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUMINPUT", _IOC_READ|_IOC_WRITE, 0x561a, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_ENUMOUTPUT", _IOC_READ|_IOC_WRITE, 0x5630, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUMSTD", _IOC_READ|_IOC_WRITE, 0x5619, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5662, 0x94 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FMT", _IOC_READ|_IOC_WRITE, 0x5602, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMEINTERVALS", _IOC_READ|_IOC_WRITE, 0x564b, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FRAMESIZES", _IOC_READ|_IOC_WRITE, 0x564a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_ENUM_FREQ_BANDS", _IOC_READ|_IOC_WRITE, 0x5665, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_EXPBUF", _IOC_READ|_IOC_WRITE, 0x5610, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDIO", _IOC_READ, 0x5621, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_AUDOUT", _IOC_READ, 0x5631, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_G_CROP", _IOC_READ|_IOC_WRITE, 0x563b, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_G_CTRL", _IOC_READ|_IOC_WRITE, 0x561b, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5658, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_G_EDID", _IOC_READ|_IOC_WRITE, 0x5628, 0x24 },
+{ "linux/videodev2.h", "VIDIOC_G_ENC_INDEX", _IOC_READ, 0x564c, 0x818 },
+{ "linux/videodev2.h", "VIDIOC_G_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5647, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_G_FBUF", _IOC_READ, 0x560a, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_FMT", _IOC_READ|_IOC_WRITE, 0x5604, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_FREQUENCY", _IOC_READ|_IOC_WRITE, 0x5638, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_G_INPUT", _IOC_READ, 0x5626, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_JPEGCOMP", _IOC_READ, 0x563d, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_G_MODULATOR", _IOC_READ|_IOC_WRITE, 0x5636, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_G_OUTPUT", _IOC_READ, 0x562e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_PARM", _IOC_READ|_IOC_WRITE, 0x5615, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_G_PRIORITY", _IOC_READ, 0x5643, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_G_SELECTION", _IOC_READ|_IOC_WRITE, 0x565e, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_G_SLICED_VBI_CAP", _IOC_READ|_IOC_WRITE, 0x5645, 0x74 },
+{ "linux/videodev2.h", "VIDIOC_G_STD", _IOC_READ, 0x5617, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_G_TUNER", _IOC_READ|_IOC_WRITE, 0x561d, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_LOG_STATUS", _IOC_NONE, 0x5646, 0x00 },
+{ "linux/videodev2.h", "VIDIOC_OVERLAY", _IOC_WRITE, 0x560e, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_PREPARE_BUF", _IOC_READ|_IOC_WRITE, 0x565d, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_QBUF", _IOC_READ|_IOC_WRITE, 0x560f, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_QUERYBUF", _IOC_READ|_IOC_WRITE, 0x5609, 0x50 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCAP", _IOC_READ, 0x5600, 0x68 },
+{ "linux/videodev2.h", "VIDIOC_QUERYCTRL", _IOC_READ|_IOC_WRITE, 0x5624, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_QUERYMENU", _IOC_READ|_IOC_WRITE, 0x5625, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_QUERYSTD", _IOC_READ, 0x563f, 0x08 },
+{ "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 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDIO", _IOC_WRITE, 0x5622, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_AUDOUT", _IOC_WRITE, 0x5632, 0x34 },
+{ "linux/videodev2.h", "VIDIOC_S_CROP", _IOC_WRITE, 0x563c, 0x14 },
+{ "linux/videodev2.h", "VIDIOC_S_CTRL", _IOC_READ|_IOC_WRITE, 0x561c, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_DV_TIMINGS", _IOC_READ|_IOC_WRITE, 0x5657, 0x84 },
+{ "linux/videodev2.h", "VIDIOC_S_EDID", _IOC_READ|_IOC_WRITE, 0x5629, 0x24 },
+{ "linux/videodev2.h", "VIDIOC_S_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5648, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_S_FBUF", _IOC_WRITE, 0x560b, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_FMT", _IOC_READ|_IOC_WRITE, 0x5605, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_FREQUENCY", _IOC_WRITE, 0x5639, 0x2c },
+{ "linux/videodev2.h", "VIDIOC_S_HW_FREQ_SEEK", _IOC_WRITE, 0x5652, 0x30 },
+{ "linux/videodev2.h", "VIDIOC_S_INPUT", _IOC_READ|_IOC_WRITE, 0x5627, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_JPEGCOMP", _IOC_WRITE, 0x563e, 0x8c },
+{ "linux/videodev2.h", "VIDIOC_S_MODULATOR", _IOC_WRITE, 0x5637, 0x44 },
+{ "linux/videodev2.h", "VIDIOC_S_OUTPUT", _IOC_READ|_IOC_WRITE, 0x562f, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_PARM", _IOC_READ|_IOC_WRITE, 0x5616, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_S_PRIORITY", _IOC_WRITE, 0x5644, 0x04 },
+{ "linux/videodev2.h", "VIDIOC_S_SELECTION", _IOC_READ|_IOC_WRITE, 0x565f, 0x40 },
+{ "linux/videodev2.h", "VIDIOC_S_STD", _IOC_WRITE, 0x5618, 0x08 },
+{ "linux/videodev2.h", "VIDIOC_S_TUNER", _IOC_WRITE, 0x561e, 0x54 },
+{ "linux/videodev2.h", "VIDIOC_TRY_DECODER_CMD", _IOC_READ|_IOC_WRITE, 0x5661, 0x48 },
+{ "linux/videodev2.h", "VIDIOC_TRY_ENCODER_CMD", _IOC_READ|_IOC_WRITE, 0x564e, 0x28 },
+{ "linux/videodev2.h", "VIDIOC_TRY_EXT_CTRLS", _IOC_READ|_IOC_WRITE, 0x5649, 0x18 },
+{ "linux/videodev2.h", "VIDIOC_TRY_FMT", _IOC_READ|_IOC_WRITE, 0x5640, 0xcc },
+{ "linux/videodev2.h", "VIDIOC_UNSUBSCRIBE_EVENT", _IOC_WRITE, 0x565b, 0x20 },
+{ "linux/vm_sockets.h", "IOCTL_VM_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_ADD_NOTIFICATION", _IOC_NONE, 0x07af, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_GET_CPT_STATE", _IOC_NONE, 0x07b1, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_REMOVE_NOTIFICATION", _IOC_NONE, 0x07b0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_CTX_SET_CPT_STATE", _IOC_NONE, 0x07b2, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_RECEIVE", _IOC_NONE, 0x07ac, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_DATAGRAM_SEND", _IOC_NONE, 0x07ab, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_GET_CONTEXT_ID", _IOC_NONE, 0x07b3, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_INIT_CONTEXT", _IOC_NONE, 0x07a0, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFICATIONS_RECEIVE", _IOC_NONE, 0x07a6, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_NOTIFY_RESOURCE", _IOC_NONE, 0x07a5, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_ALLOC", _IOC_NONE, 0x07a8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_DETACH", _IOC_NONE, 0x07aa, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETPAGEFILE", _IOC_NONE, 0x07a9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_QUEUEPAIR_SETVA", _IOC_NONE, 0x07a4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SET_NOTIFY", _IOC_NONE, 0x07cb, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_AF_VALUE", _IOC_NONE, 0x07b8, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_GET_LOCAL_CID", _IOC_NONE, 0x07b9, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_SOCKETS_VERSION", _IOC_NONE, 0x07b4, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION", _IOC_NONE, 0x079f, 0x00 },
+{ "linux/vmw_vmci_defs.h", "IOCTL_VMCI_VERSION2", _IOC_NONE, 0x07a7, 0x00 },
+{ "linux/vsp1.h", "VIDIOC_VSP1_LUT_CONFIG", _IOC_READ|_IOC_WRITE, 0x56c1, 0x400 },
+{ "linux/vt.h", "VT_ACTIVATE", 0, 0x5606, 0 },
+{ "linux/vt.h", "VT_DISALLOCATE", 0, 0x5608, 0 },
+{ "linux/vt.h", "VT_GETHIFONTMASK", 0, 0x560D, 0 },
+{ "linux/vt.h", "VT_GETMODE", 0, 0x5601, 0 },
+{ "linux/vt.h", "VT_GETSTATE", 0, 0x5603, 0 },
+{ "linux/vt.h", "VT_LOCKSWITCH", 0, 0x560B, 0 },
+{ "linux/vt.h", "VT_OPENQRY", 0, 0x5600, 0 },
+{ "linux/vt.h", "VT_RELDISP", 0, 0x5605, 0 },
+{ "linux/vt.h", "VT_RESIZE", 0, 0x5609, 0 },
+{ "linux/vt.h", "VT_RESIZEX", 0, 0x560A, 0 },
+{ "linux/vt.h", "VT_SENDSIG", 0, 0x5604, 0 },
+{ "linux/vt.h", "VT_SETACTIVATE", 0, 0x560F, 0 },
+{ "linux/vt.h", "VT_SETMODE", 0, 0x5602, 0 },
+{ "linux/vt.h", "VT_UNLOCKSWITCH", 0, 0x560C, 0 },
+{ "linux/vt.h", "VT_WAITACTIVE", 0, 0x5607, 0 },
+{ "linux/vt.h", "VT_WAITEVENT", 0, 0x560E, 0 },
+{ "linux/watchdog.h", "WDIOC_GETBOOTSTATUS", _IOC_READ, 0x5702, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETPRETIMEOUT", _IOC_READ, 0x5709, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSTATUS", _IOC_READ, 0x5701, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETSUPPORT", _IOC_READ, 0x5700, 0x28 },
+{ "linux/watchdog.h", "WDIOC_GETTEMP", _IOC_READ, 0x5703, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMELEFT", _IOC_READ, 0x570a, 0x04 },
+{ "linux/watchdog.h", "WDIOC_GETTIMEOUT", _IOC_READ, 0x5707, 0x04 },
+{ "linux/watchdog.h", "WDIOC_KEEPALIVE", _IOC_READ, 0x5705, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETOPTIONS", _IOC_READ, 0x5704, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETPRETIMEOUT", _IOC_READ|_IOC_WRITE, 0x5708, 0x04 },
+{ "linux/watchdog.h", "WDIOC_SETTIMEOUT", _IOC_READ|_IOC_WRITE, 0x5706, 0x04 },
+{ "linux/wireless.h", "SIOCGIWAP", 0, 0x8B15, 0 },
+{ "linux/wireless.h", "SIOCGIWAPLIST", 0, 0x8B17, 0 },
+{ "linux/wireless.h", "SIOCGIWAUTH", 0, 0x8B33, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODE", 0, 0x8B2B, 0 },
+{ "linux/wireless.h", "SIOCGIWENCODEEXT", 0, 0x8B35, 0 },
+{ "linux/wireless.h", "SIOCGIWESSID", 0, 0x8B1B, 0 },
+{ "linux/wireless.h", "SIOCGIWFRAG", 0, 0x8B25, 0 },
+{ "linux/wireless.h", "SIOCGIWFREQ", 0, 0x8B05, 0 },
+{ "linux/wireless.h", "SIOCGIWGENIE", 0, 0x8B31, 0 },
+{ "linux/wireless.h", "SIOCGIWMODE", 0, 0x8B07, 0 },
+{ "linux/wireless.h", "SIOCGIWNAME", 0, 0x8B01, 0 },
+{ "linux/wireless.h", "SIOCGIWNICKN", 0, 0x8B1D, 0 },
+{ "linux/wireless.h", "SIOCGIWNWID", 0, 0x8B03, 0 },
+{ "linux/wireless.h", "SIOCGIWPOWER", 0, 0x8B2D, 0 },
+{ "linux/wireless.h", "SIOCGIWPRIV", 0, 0x8B0D, 0 },
+{ "linux/wireless.h", "SIOCGIWRANGE", 0, 0x8B0B, 0 },
+{ "linux/wireless.h", "SIOCGIWRATE", 0, 0x8B21, 0 },
+{ "linux/wireless.h", "SIOCGIWRETRY", 0, 0x8B29, 0 },
+{ "linux/wireless.h", "SIOCGIWRTS", 0, 0x8B23, 0 },
+{ "linux/wireless.h", "SIOCGIWSCAN", 0, 0x8B19, 0 },
+{ "linux/wireless.h", "SIOCGIWSENS", 0, 0x8B09, 0 },
+{ "linux/wireless.h", "SIOCGIWSPY", 0, 0x8B11, 0 },
+{ "linux/wireless.h", "SIOCGIWSTATS", 0, 0x8B0F, 0 },
+{ "linux/wireless.h", "SIOCGIWTHRSPY", 0, 0x8B13, 0 },
+{ "linux/wireless.h", "SIOCGIWTXPOW", 0, 0x8B27, 0 },
+{ "linux/wireless.h", "SIOCIWFIRST", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCIWFIRSTPRIV", 0, 0x8BE0, 0 },
+{ "linux/wireless.h", "SIOCIWLASTPRIV", 0, 0x8BFF, 0 },
+{ "linux/wireless.h", "SIOCSIWAP", 0, 0x8B14, 0 },
+{ "linux/wireless.h", "SIOCSIWAUTH", 0, 0x8B32, 0 },
+{ "linux/wireless.h", "SIOCSIWCOMMIT", 0, 0x8B00, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODE", 0, 0x8B2A, 0 },
+{ "linux/wireless.h", "SIOCSIWENCODEEXT", 0, 0x8B34, 0 },
+{ "linux/wireless.h", "SIOCSIWESSID", 0, 0x8B1A, 0 },
+{ "linux/wireless.h", "SIOCSIWFRAG", 0, 0x8B24, 0 },
+{ "linux/wireless.h", "SIOCSIWFREQ", 0, 0x8B04, 0 },
+{ "linux/wireless.h", "SIOCSIWGENIE", 0, 0x8B30, 0 },
+{ "linux/wireless.h", "SIOCSIWMLME", 0, 0x8B16, 0 },
+{ "linux/wireless.h", "SIOCSIWMODE", 0, 0x8B06, 0 },
+{ "linux/wireless.h", "SIOCSIWNICKN", 0, 0x8B1C, 0 },
+{ "linux/wireless.h", "SIOCSIWNWID", 0, 0x8B02, 0 },
+{ "linux/wireless.h", "SIOCSIWPMKSA", 0, 0x8B36, 0 },
+{ "linux/wireless.h", "SIOCSIWPOWER", 0, 0x8B2C, 0 },
+{ "linux/wireless.h", "SIOCSIWPRIV", 0, 0x8B0C, 0 },
+{ "linux/wireless.h", "SIOCSIWRANGE", 0, 0x8B0A, 0 },
+{ "linux/wireless.h", "SIOCSIWRATE", 0, 0x8B20, 0 },
+{ "linux/wireless.h", "SIOCSIWRETRY", 0, 0x8B28, 0 },
+{ "linux/wireless.h", "SIOCSIWRTS", 0, 0x8B22, 0 },
+{ "linux/wireless.h", "SIOCSIWSCAN", 0, 0x8B18, 0 },
+{ "linux/wireless.h", "SIOCSIWSENS", 0, 0x8B08, 0 },
+{ "linux/wireless.h", "SIOCSIWSPY", 0, 0x8B10, 0 },
+{ "linux/wireless.h", "SIOCSIWSTATS", 0, 0x8B0E, 0 },
+{ "linux/wireless.h", "SIOCSIWTHRSPY", 0, 0x8B12, 0 },
+{ "linux/wireless.h", "SIOCSIWTXPOW", 0, 0x8B26, 0 },
+{ "media/davinci/vpfe_capture.h", "VPFE_CMD_S_CCDC_RAW_PARAMS", _IOC_WRITE, 0x56c1, 0x04 },
+{ "media/drv-intf/exynos-fimc.h", "S5P_FIMC_TX_END_NOTIFY", _IOC_NONE, 0x6500, 0x00 },
+{ "media/i2c/adv7842.h", "ADV7842_CMD_RAM_TEST", _IOC_NONE, 0x56c0, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_HIGH", _IOC_NONE, 0x6201, 0x00 },
+{ "media/i2c/bt819.h", "BT819_FIFO_RESET_LOW", _IOC_NONE, 0x6200, 0x00 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_CLOSE", _IOC_WRITE, 0x5202, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_POLL", _IOC_READ, 0x5204, 0x04 },
+{ "media/i2c/saa6588.h", "SAA6588_CMD_READ", _IOC_READ, 0x5203, 0x04 },
+{ "media/v4l2-common.h", "TUNER_SET_CONFIG", _IOC_WRITE, 0x645c, 0x08 },
+{ "media/v4l2-common.h", "VIDIOC_INT_RESET", _IOC_WRITE, 0x6466, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_DEVICE_NOTIFY_EVENT", _IOC_WRITE, 0x7602, 0x88 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_RX_NOTIFY", _IOC_WRITE, 0x7600, 0x04 },
+{ "media/v4l2-subdev.h", "V4L2_SUBDEV_IR_TX_NOTIFY", _IOC_WRITE, 0x7601, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_DOWNLOAD_IMAGE", _IOC_WRITE, 0xca0a, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_AFU_ID", _IOC_READ, 0xca02, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_GET_PROCESS_ELEMENT", _IOC_READ, 0xca01, 0x04 },
+{ "misc/cxl.h", "CXL_IOCTL_START_WORK", _IOC_WRITE, 0xca00, 0x40 },
+{ "misc/cxl.h", "CXL_IOCTL_VALIDATE_IMAGE", _IOC_WRITE, 0xca0b, 0x40 },
+{ "mtd/mtd-abi.h", "ECCGETLAYOUT", _IOC_READ, 0x4d11, 0x148 },
+{ "mtd/mtd-abi.h", "ECCGETSTATS", _IOC_READ, 0x4d12, 0x10 },
+{ "mtd/mtd-abi.h", "MEMERASE", _IOC_WRITE, 0x4d02, 0x08 },
+{ "mtd/mtd-abi.h", "MEMERASE64", _IOC_WRITE, 0x4d14, 0x10 },
+{ "mtd/mtd-abi.h", "MEMGETBADBLOCK", _IOC_WRITE, 0x4d0b, 0x08 },
+{ "mtd/mtd-abi.h", "MEMGETINFO", _IOC_READ, 0x4d01, 0x20 },
+{ "mtd/mtd-abi.h", "MEMGETOOBSEL", _IOC_READ, 0x4d0a, 0xc8 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONCOUNT", _IOC_READ, 0x4d07, 0x04 },
+{ "mtd/mtd-abi.h", "MEMGETREGIONINFO", _IOC_READ|_IOC_WRITE, 0x4d08, 0x10 },
+{ "mtd/mtd-abi.h", "MEMISLOCKED", _IOC_READ, 0x4d17, 0x08 },
+{ "mtd/mtd-abi.h", "MEMLOCK", _IOC_WRITE, 0x4d05, 0x08 },
+{ "mtd/mtd-abi.h", "MEMREADOOB", _IOC_READ|_IOC_WRITE, 0x4d04, 0x0c },
+{ "mtd/mtd-abi.h", "MEMREADOOB64", _IOC_READ|_IOC_WRITE, 0x4d16, 0x18 },
+{ "mtd/mtd-abi.h", "MEMSETBADBLOCK", _IOC_WRITE, 0x4d0c, 0x08 },
+{ "mtd/mtd-abi.h", "MEMUNLOCK", _IOC_WRITE, 0x4d06, 0x08 },
+{ "mtd/mtd-abi.h", "MEMWRITE", _IOC_READ|_IOC_WRITE, 0x4d18, 0x30 },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB", _IOC_READ|_IOC_WRITE, 0x4d03, 0x0c },
+{ "mtd/mtd-abi.h", "MEMWRITEOOB64", _IOC_READ|_IOC_WRITE, 0x4d15, 0x18 },
+{ "mtd/mtd-abi.h", "MTDFILEMODE", _IOC_NONE, 0x4d13, 0x00 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONCOUNT", _IOC_WRITE, 0x4d0e, 0x04 },
+{ "mtd/mtd-abi.h", "OTPGETREGIONINFO", _IOC_WRITE, 0x4d0f, 0x0c },
+{ "mtd/mtd-abi.h", "OTPLOCK", _IOC_READ, 0x4d10, 0x0c },
+{ "mtd/mtd-abi.h", "OTPSELECT", _IOC_READ, 0x4d0d, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCATT", _IOC_WRITE, 0x6f40, 0x18 },
+{ "mtd/ubi-user.h", "UBI_IOCDET", _IOC_WRITE, 0x6f41, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBCH", _IOC_WRITE, 0x4f02, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBER", _IOC_WRITE, 0x4f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBISMAP", _IOC_READ, 0x4f05, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCEBMAP", _IOC_WRITE, 0x4f03, 0x08 },
+{ "mtd/ubi-user.h", "UBI_IOCEBUNMAP", _IOC_WRITE, 0x4f04, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCMKVOL", _IOC_WRITE, 0x6f00, 0x98 },
+{ "mtd/ubi-user.h", "UBI_IOCRMVOL", _IOC_WRITE, 0x6f01, 0x04 },
+{ "mtd/ubi-user.h", "UBI_IOCRNVOL", _IOC_WRITE, 0x6f03, 0x1110 },
+{ "mtd/ubi-user.h", "UBI_IOCRSVOL", _IOC_WRITE, 0x6f02, 0x0c },
+{ "mtd/ubi-user.h", "UBI_IOCSETVOLPROP", _IOC_WRITE, 0x4f06, 0x10 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLCRBLK", _IOC_WRITE, 0x4f07, 0x80 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLRMBLK", _IOC_NONE, 0x4f08, 0x00 },
+{ "mtd/ubi-user.h", "UBI_IOCVOLUP", _IOC_WRITE, 0x4f00, 0x08 },
+{ "net/bluetooth/hci_sock.h", "HCIBLOCKADDR", _IOC_WRITE, 0x48e6, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVDOWN", _IOC_WRITE, 0x48ca, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESET", _IOC_WRITE, 0x48cb, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVRESTAT", _IOC_WRITE, 0x48cc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIDEVUP", _IOC_WRITE, 0x48c9, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETAUTHINFO", _IOC_READ, 0x48d7, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNINFO", _IOC_READ, 0x48d5, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETCONNLIST", _IOC_READ, 0x48d4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVINFO", _IOC_READ, 0x48d3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIGETDEVLIST", _IOC_READ, 0x48d2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIINQUIRY", _IOC_READ, 0x48f0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETACLMTU", _IOC_WRITE, 0x48e3, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETAUTH", _IOC_WRITE, 0x48de, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETENCRYPT", _IOC_WRITE, 0x48df, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKMODE", _IOC_WRITE, 0x48e2, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETLINKPOL", _IOC_WRITE, 0x48e1, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETPTYPE", _IOC_WRITE, 0x48e0, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETRAW", _IOC_WRITE, 0x48dc, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCAN", _IOC_WRITE, 0x48dd, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCISETSCOMTU", _IOC_WRITE, 0x48e4, 0x04 },
+{ "net/bluetooth/hci_sock.h", "HCIUNBLOCKADDR", _IOC_WRITE, 0x48e7, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMCREATEDEV", _IOC_WRITE, 0x52c8, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVINFO", _IOC_READ, 0x52d3, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMGETDEVLIST", _IOC_READ, 0x52d2, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMRELEASEDEV", _IOC_WRITE, 0x52c9, 0x04 },
+{ "net/bluetooth/rfcomm.h", "RFCOMMSTEALDLC", _IOC_WRITE, 0x52dc, 0x04 },
+{ "net/nfc/nci_core.h", "NCIUARTSETDRIVER", _IOC_WRITE, 0x5500, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ACK_EVENT", _IOC_WRITE, 0x1bea, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_ASSIGN_CTXT", _IOC_READ|_IOC_WRITE, 0x1be1, 0x1c },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CREDIT_UPD", _IOC_NONE, 0x1be6, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_INFO", _IOC_WRITE, 0x1be2, 0x28 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_CTXT_RESET", _IOC_NONE, 0x1bec, 0x00 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_GET_VERS", _IOC_READ, 0x1bee, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_POLL_TYPE", _IOC_WRITE, 0x1be9, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_RECV_CTRL", _IOC_WRITE, 0x1be8, 0x04 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_SET_PKEY", _IOC_WRITE, 0x1beb, 0x02 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_FREE", _IOC_READ|_IOC_WRITE, 0x1be5, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_INVAL_READ", _IOC_READ|_IOC_WRITE, 0x1bed, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_TID_UPDATE", _IOC_READ|_IOC_WRITE, 0x1be4, 0x18 },
+{ "rdma/hfi/hfi1_user.h", "HFI1_IOCTL_USER_INFO", _IOC_WRITE, 0x1be3, 0x78 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_ENABLE_PKEY", _IOC_NONE, 0x1b03, 0x00 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT", _IOC_READ|_IOC_WRITE, 0x1b01, 0x1c },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_REGISTER_AGENT2", _IOC_READ|_IOC_WRITE, 0x1b04, 0x28 },
+{ "rdma/ib_user_mad.h", "IB_USER_MAD_UNREGISTER_AGENT", _IOC_WRITE, 0x1b02, 0x04 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_ATTACH", _IOC_READ|_IOC_WRITE, 0xca80, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_DETACH", _IOC_READ|_IOC_WRITE, 0xca83, 0x60 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_MANAGE_LUN", _IOC_READ|_IOC_WRITE, 0xca86, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RECOVER_AFU", _IOC_READ|_IOC_WRITE, 0xca85, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_RELEASE", _IOC_READ|_IOC_WRITE, 0xca82, 0x68 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_DIRECT", _IOC_READ|_IOC_WRITE, 0xca81, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_USER_VIRTUAL", _IOC_READ|_IOC_WRITE, 0xca87, 0x78 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VERIFY", _IOC_READ|_IOC_WRITE, 0xca84, 0x90 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_CLONE", _IOC_READ|_IOC_WRITE, 0xca89, 0x70 },
+{ "scsi/cxlflash_ioctl.h", "DK_CXLFLASH_VLUN_RESIZE", _IOC_READ|_IOC_WRITE, 0xca88, 0x78 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_BUS_NUMBER", 0, 0x5386, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_IDLUN", 0, 0x5382, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_GET_PCI", 0, 0x5387, 0 },
+{ "scsi/scsi.h", "SCSI_IOCTL_PROBE_HOST", 0, 0x5385, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORLOCK", 0, 0x5380, 0 },
+{ "scsi/scsi_ioctl.h", "SCSI_IOCTL_DOORUNLOCK", 0, 0x5381, 0 },
+{ "scsi/sg.h", "SG_EMULATED_HOST", 0, 0x2203, 0 },
+{ "scsi/sg.h", "SG_GET_ACCESS_COUNT", 0, 0x2289, 0 },
+{ "scsi/sg.h", "SG_GET_COMMAND_Q", 0, 0x2270, 0 },
+{ "scsi/sg.h", "SG_GET_KEEP_ORPHAN", 0, 0x2288, 0 },
+{ "scsi/sg.h", "SG_GET_LOW_DMA", 0, 0x227a, 0 },
+{ "scsi/sg.h", "SG_GET_NUM_WAITING", 0, 0x227d, 0 },
+{ "scsi/sg.h", "SG_GET_PACK_ID", 0, 0x227c, 0 },
+{ "scsi/sg.h", "SG_GET_REQUEST_TABLE", 0, 0x2286, 0 },
+{ "scsi/sg.h", "SG_GET_RESERVED_SIZE", 0, 0x2272, 0 },
+{ "scsi/sg.h", "SG_GET_SCSI_ID", 0, 0x2276, 0 },
+{ "scsi/sg.h", "SG_GET_SG_TABLESIZE", 0, 0x227F, 0 },
+{ "scsi/sg.h", "SG_GET_TIMEOUT", 0, 0x2202, 0 },
+{ "scsi/sg.h", "SG_GET_TRANSFORM", 0, 0x2205, 0 },
+{ "scsi/sg.h", "SG_GET_VERSION_NUM", 0, 0x2282, 0 },
+{ "scsi/sg.h", "SG_IO", 0, 0x2285, 0 },
+{ "scsi/sg.h", "SG_NEXT_CMD_LEN", 0, 0x2283, 0 },
+{ "scsi/sg.h", "SG_SCSI_RESET", 0, 0x2284, 0 },
+{ "scsi/sg.h", "SG_SET_COMMAND_Q", 0, 0x2271, 0 },
+{ "scsi/sg.h", "SG_SET_DEBUG", 0, 0x227e, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_LOW_DMA", 0, 0x2279, 0 },
+{ "scsi/sg.h", "SG_SET_FORCE_PACK_ID", 0, 0x227b, 0 },
+{ "scsi/sg.h", "SG_SET_KEEP_ORPHAN", 0, 0x2287, 0 },
+{ "scsi/sg.h", "SG_SET_RESERVED_SIZE", 0, 0x2275, 0 },
+{ "scsi/sg.h", "SG_SET_TIMEOUT", 0, 0x2201, 0 },
+{ "scsi/sg.h", "SG_SET_TRANSFORM", 0, 0x2204, 0 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CLIENT_ID", _IOC_READ, 0x5301, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_PORT", _IOC_READ|_IOC_WRITE, 0x5320, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_CREATE_QUEUE", _IOC_READ|_IOC_WRITE, 0x5332, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_PORT", _IOC_WRITE, 0x5321, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_DELETE_QUEUE", _IOC_WRITE, 0x5333, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_INFO", _IOC_READ|_IOC_WRITE, 0x5310, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_CLIENT_POOL", _IOC_READ|_IOC_WRITE, 0x534b, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_NAMED_QUEUE", _IOC_READ|_IOC_WRITE, 0x5336, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_PORT_INFO", _IOC_READ|_IOC_WRITE, 0x5322, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_CLIENT", _IOC_READ|_IOC_WRITE, 0x5349, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5334, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_STATUS", _IOC_READ|_IOC_WRITE, 0x5340, 0x5c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TEMPO", _IOC_READ|_IOC_WRITE, 0x5341, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_QUEUE_TIMER", _IOC_READ|_IOC_WRITE, 0x5345, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_GET_SUBSCRIPTION", _IOC_READ|_IOC_WRITE, 0x5350, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_PVERSION", _IOC_READ, 0x5300, 0x04 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_CLIENT", _IOC_READ|_IOC_WRITE, 0x5351, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_NEXT_PORT", _IOC_READ|_IOC_WRITE, 0x5352, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_QUERY_SUBS", _IOC_READ|_IOC_WRITE, 0x534f, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_REMOVE_EVENTS", _IOC_WRITE, 0x534e, 0x40 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_RUNNING_MODE", _IOC_READ|_IOC_WRITE, 0x5303, 0x10 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_INFO", _IOC_WRITE, 0x5311, 0xbc },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_CLIENT_POOL", _IOC_WRITE, 0x534c, 0x58 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_PORT_INFO", _IOC_WRITE, 0x5323, 0xa4 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_CLIENT", _IOC_WRITE, 0x534a, 0x4c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_INFO", _IOC_READ|_IOC_WRITE, 0x5335, 0x8c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TEMPO", _IOC_WRITE, 0x5342, 0x2c },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SET_QUEUE_TIMER", _IOC_WRITE, 0x5346, 0x60 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SUBSCRIBE_PORT", _IOC_WRITE, 0x5330, 0x50 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_SYSTEM_INFO", _IOC_READ|_IOC_WRITE, 0x5302, 0x30 },
+{ "sound/asequencer.h", "SNDRV_SEQ_IOCTL_UNSUBSCRIBE_PORT", _IOC_WRITE, 0x5331, 0x50 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_CARD_INFO", _IOC_READ, 0x5501, 0x178 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_ADD", _IOC_READ|_IOC_WRITE, 0x5517, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_INFO", _IOC_READ|_IOC_WRITE, 0x5511, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LIST", _IOC_READ|_IOC_WRITE, 0x5510, 0x48 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_LOCK", _IOC_WRITE, 0x5514, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_READ", _IOC_READ|_IOC_WRITE, 0x5512, 0x2c8 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REMOVE", _IOC_READ|_IOC_WRITE, 0x5519, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_REPLACE", _IOC_READ|_IOC_WRITE, 0x5518, 0x110 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_UNLOCK", _IOC_WRITE, 0x5515, 0x40 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_ELEM_WRITE", _IOC_READ|_IOC_WRITE, 0x5513, 0x2c8 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_INFO", _IOC_READ, 0x5521, 0xdc },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_HWDEP_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5520, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_INFO", _IOC_READ|_IOC_WRITE, 0x5531, 0x120 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE", _IOC_READ, 0x5530, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE", _IOC_WRITE, 0x5532, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER", _IOC_READ|_IOC_WRITE, 0x55d0, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_POWER_STATE", _IOC_READ, 0x55d1, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_PVERSION", _IOC_READ, 0x5500, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_INFO", _IOC_READ|_IOC_WRITE, 0x5541, 0x10c },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5540, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_RAWMIDI_PREFER_SUBDEVICE", _IOC_WRITE, 0x5542, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_SUBSCRIBE_EVENTS", _IOC_READ|_IOC_WRITE, 0x5516, 0x04 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_COMMAND", _IOC_READ|_IOC_WRITE, 0x551c, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_READ", _IOC_READ|_IOC_WRITE, 0x551a, 0x08 },
+{ "sound/asound.h", "SNDRV_CTL_IOCTL_TLV_WRITE", _IOC_READ|_IOC_WRITE, 0x551b, 0x08 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_LOAD", _IOC_WRITE, 0x4803, 0x50 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_DSP_STATUS", _IOC_READ, 0x4802, 0x40 },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_INFO", _IOC_READ, 0x4801, 0xdc },
+{ "sound/asound.h", "SNDRV_HWDEP_IOCTL_PVERSION", _IOC_READ, 0x4800, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_CHANNEL_INFO", _IOC_READ, 0x4132, 0x18 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DELAY", _IOC_READ, 0x4121, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DRAIN", _IOC_NONE, 0x4144, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_DROP", _IOC_NONE, 0x4143, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_FORWARD", _IOC_WRITE, 0x4149, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HWSYNC", _IOC_NONE, 0x4122, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_FREE", _IOC_NONE, 0x4112, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4111, 0x25c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_HW_REFINE", _IOC_READ|_IOC_WRITE, 0x4110, 0x25c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_INFO", _IOC_READ, 0x4101, 0x120 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_LINK", _IOC_WRITE, 0x4160, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PAUSE", _IOC_WRITE, 0x4145, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PREPARE", _IOC_NONE, 0x4140, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_PVERSION", _IOC_READ, 0x4100, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READI_FRAMES", _IOC_READ, 0x4151, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_READN_FRAMES", _IOC_READ, 0x4153, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESET", _IOC_NONE, 0x4141, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_RESUME", _IOC_NONE, 0x4147, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_REWIND", _IOC_WRITE, 0x4146, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_START", _IOC_NONE, 0x4142, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS", _IOC_READ, 0x4120, 0x80 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_STATUS_EXT", _IOC_READ|_IOC_WRITE, 0x4124, 0x80 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SW_PARAMS", _IOC_READ|_IOC_WRITE, 0x4113, 0x68 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_SYNC_PTR", _IOC_READ|_IOC_WRITE, 0x4123, 0x88 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TSTAMP", _IOC_WRITE, 0x4102, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_TTSTAMP", _IOC_WRITE, 0x4103, 0x04 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_UNLINK", _IOC_NONE, 0x4161, 0x00 },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEI_FRAMES", _IOC_WRITE, 0x4150, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_WRITEN_FRAMES", _IOC_WRITE, 0x4152, 0x0c },
+{ "sound/asound.h", "SNDRV_PCM_IOCTL_XRUN", _IOC_NONE, 0x4148, 0x00 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DRAIN", _IOC_WRITE, 0x5731, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_DROP", _IOC_WRITE, 0x5730, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_INFO", _IOC_READ, 0x5701, 0x10c },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PARAMS", _IOC_READ|_IOC_WRITE, 0x5710, 0x20 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_PVERSION", _IOC_READ, 0x5700, 0x04 },
+{ "sound/asound.h", "SNDRV_RAWMIDI_IOCTL_STATUS", _IOC_READ|_IOC_WRITE, 0x5720, 0x30 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_CONTINUE", _IOC_NONE, 0x54a2, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GINFO", _IOC_READ|_IOC_WRITE, 0x5403, 0xe0 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GPARAMS", _IOC_WRITE, 0x5404, 0x3c },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_GSTATUS", _IOC_READ|_IOC_WRITE, 0x5405, 0x40 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_INFO", _IOC_READ, 0x5411, 0xe0 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_NEXT_DEVICE", _IOC_READ|_IOC_WRITE, 0x5401, 0x14 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PARAMS", _IOC_WRITE, 0x5412, 0x50 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PAUSE", _IOC_NONE, 0x54a3, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_PVERSION", _IOC_READ, 0x5400, 0x04 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_SELECT", _IOC_WRITE, 0x5410, 0x34 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_START", _IOC_NONE, 0x54a0, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STATUS", _IOC_READ, 0x5414, 0x60 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_STOP", _IOC_NONE, 0x54a1, 0x00 },
+{ "sound/asound.h", "SNDRV_TIMER_IOCTL_TREAD", _IOC_WRITE, 0x5402, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_CLEAR_PATCHES", _IOC_NONE, 0x4840, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_INFO", _IOC_READ, 0x4820, 0x02 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_PLAY_NOTE", _IOC_WRITE, 0x4822, 0x0c },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_RESET", _IOC_NONE, 0x4821, 0x00 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_CONNECTION", _IOC_WRITE, 0x4826, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_MODE", _IOC_WRITE, 0x4825, 0x04 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4824, 0x09 },
+{ "sound/asound_fm.h", "SNDRV_DM_FM_IOCTL_SET_VOICE", _IOC_WRITE, 0x4823, 0x12 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_AVAIL", _IOC_READ, 0x4321, 0x1c },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_DRAIN", _IOC_NONE, 0x4334, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CAPS", _IOC_READ|_IOC_WRITE, 0x4310, 0xc4 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_CODEC_CAPS", _IOC_READ|_IOC_WRITE, 0x4311, 0x2b88 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_METADATA", _IOC_READ|_IOC_WRITE, 0x4315, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_GET_PARAMS", _IOC_READ, 0x4313, 0x78 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_IOCTL_VERSION", _IOC_READ, 0x4300, 0x04 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_NEXT_TRACK", _IOC_NONE, 0x4335, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PARTIAL_DRAIN", _IOC_NONE, 0x4336, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_PAUSE", _IOC_NONE, 0x4330, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_RESUME", _IOC_NONE, 0x4331, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_METADATA", _IOC_WRITE, 0x4314, 0x24 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_SET_PARAMS", _IOC_WRITE, 0x4312, 0x84 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_START", _IOC_NONE, 0x4332, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_STOP", _IOC_NONE, 0x4333, 0x00 },
+{ "sound/compress_offload.h", "SNDRV_COMPRESS_TSTAMP", _IOC_READ, 0x4320, 0x14 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_PEEK", _IOC_READ|_IOC_WRITE, 0x4812, 0x18c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CODE_POKE", _IOC_WRITE, 0x4811, 0x18c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_CONTINUE", _IOC_NONE, 0x4881, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_DBG_READ", _IOC_READ, 0x4884, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_INFO", _IOC_READ, 0x4810, 0x80c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_PEEK", _IOC_READ|_IOC_WRITE, 0x4831, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PCM_POKE", _IOC_WRITE, 0x4830, 0x48 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_PVERSION", _IOC_READ, 0x4840, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_SINGLE_STEP", _IOC_WRITE, 0x4883, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_STOP", _IOC_NONE, 0x4880, 0x00 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_PEEK", _IOC_READ|_IOC_WRITE, 0x4822, 0x0c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_POKE", _IOC_WRITE, 0x4821, 0x0c },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_TRAM_SETUP", _IOC_WRITE, 0x4820, 0x04 },
+{ "sound/emu10k1.h", "SNDRV_EMU10K1_IOCTL_ZERO_TRAM_COUNTER", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_GET_INFO", _IOC_READ, 0x48f8, 0x20 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_LOCK", _IOC_NONE, 0x48f9, 0x00 },
+{ "sound/firewire.h", "SNDRV_FIREWIRE_IOCTL_UNLOCK", _IOC_NONE, 0x48fa, 0x00 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_GET_WCAP", _IOC_READ|_IOC_WRITE, 0x4812, 0x08 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_PVERSION", _IOC_READ, 0x4810, 0x04 },
+{ "sound/hda_hwdep.h", "HDA_IOCTL_VERB_WRITE", _IOC_READ|_IOC_WRITE, 0x4811, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_9632_AEB", _IOC_READ, 0x4845, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_CONFIG_INFO", _IOC_READ, 0x4841, 0x24 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x1000 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4840, 0x3b0 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_GET_VERSION", _IOC_READ, 0x4843, 0x08 },
+{ "sound/hdsp.h", "SNDRV_HDSP_IOCTL_UPLOAD_FIRMWARE", _IOC_WRITE, 0x4842, 0x04 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_CONFIG", _IOC_READ, 0x4841, 0x18 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_LTC", _IOC_READ, 0x4846, 0x10 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_MIXER", _IOC_READ, 0x4844, 0x04 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_PEAK_RMS", _IOC_READ, 0x4842, 0x908 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_STATUS", _IOC_READ, 0x4847, 0x20 },
+{ "sound/hdspm.h", "SNDRV_HDSPM_IOCTL_GET_VERSION", _IOC_READ, 0x4848, 0x24 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_INFO", _IOC_READ, 0x4810, 0x28 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_LOAD_CODE", _IOC_WRITE, 0x4811, 0x3012 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_PAUSE", _IOC_NONE, 0x4815, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_RESTART", _IOC_NONE, 0x4816, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_START", _IOC_WRITE, 0x4813, 0x08 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_STOP", _IOC_NONE, 0x4814, 0x00 },
+{ "sound/sb16_csp.h", "SNDRV_SB_CSP_IOCTL_UNLOAD_CODE", _IOC_NONE, 0x4812, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_LOAD_PATCH", _IOC_READ|_IOC_WRITE, 0x4881, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MEM_AVAIL", _IOC_WRITE, 0x4884, 0x04 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_MISC_MODE", _IOC_READ|_IOC_WRITE, 0x4884, 0x10 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_REMOVE_LAST_SAMPLES", _IOC_NONE, 0x4883, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_RESET_SAMPLES", _IOC_NONE, 0x4882, 0x00 },
+{ "sound/sfnt_info.h", "SNDRV_EMUX_IOCTL_VERSION", _IOC_READ, 0x4880, 0x04 },
+{ "sound/usb_stream.h", "SNDRV_USB_STREAM_IOCTL_SET_PARAMS", _IOC_WRITE, 0x4890, 0x10 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_NAME", _IOC_READ, 0x7702, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PIN_STATUS", _IOC_NONE, 0x7709, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_PROT_MASK", _IOC_NONE, 0x7706, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_GET_SIZE", _IOC_NONE, 0x7704, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_PIN", _IOC_WRITE, 0x7707, 0x08 },
+{ "staging/android/ashmem.h", "ASHMEM_PURGE_ALL_CACHES", _IOC_NONE, 0x770a, 0x00 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_NAME", _IOC_WRITE, 0x7701, 0x100 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_PROT_MASK", _IOC_WRITE, 0x7705, 0x04 },
+{ "staging/android/ashmem.h", "ASHMEM_SET_SIZE", _IOC_WRITE, 0x7703, 0x04 },
+{ "staging/android/ashmem.h", "ASHMEM_UNPIN", _IOC_WRITE, 0x7708, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_ALLOC", _IOC_READ|_IOC_WRITE, 0x4900, 0x14 },
+{ "staging/android/ion.h", "ION_IOC_CUSTOM", _IOC_READ|_IOC_WRITE, 0x4906, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_FREE", _IOC_READ|_IOC_WRITE, 0x4901, 0x04 },
+{ "staging/android/ion.h", "ION_IOC_IMPORT", _IOC_READ|_IOC_WRITE, 0x4905, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_MAP", _IOC_READ|_IOC_WRITE, 0x4902, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SHARE", _IOC_READ|_IOC_WRITE, 0x4904, 0x08 },
+{ "staging/android/ion.h", "ION_IOC_SYNC", _IOC_READ|_IOC_WRITE, 0x4907, 0x08 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_DMA_MAPPING", _IOC_WRITE, 0x49f1, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_KERNEL_MAPPING", _IOC_WRITE, 0x49f2, 0x20 },
+{ "staging/android/ion_test.h", "ION_IOC_TEST_SET_FD", _IOC_NONE, 0x49f0, 0x00 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_CREATE_FENCE", _IOC_READ|_IOC_WRITE, 0x5700, 0x28 },
+{ "staging/android/sw_sync.h", "SW_SYNC_IOC_INC", _IOC_WRITE, 0x5701, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_BRIGHTNESS", _IOC_READ, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIGET_COLOR", _IOC_READ, 0x4605, 0x04 },
+{ "video/da8xx-fb.h", "FBIOGET_CONTRAST", _IOC_READ, 0x4601, 0x04 },
+{ "video/da8xx-fb.h", "FBIOPUT_CONTRAST", _IOC_WRITE, 0x4602, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_BRIGHTNESS", _IOC_WRITE, 0x4603, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_COLOR", _IOC_WRITE, 0x4606, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_HSYNC", _IOC_WRITE, 0x4609, 0x04 },
+{ "video/da8xx-fb.h", "FBIPUT_VSYNC", _IOC_WRITE, 0x460a, 0x04 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_CREATE", _IOC_NONE, 0x6b00, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_OFFSET", _IOC_NONE, 0x6b04, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_OVERLAY_VIEWPORT_SET", _IOC_NONE, 0x6b01, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_SET_VIDEO_MODE", _IOC_NONE, 0x6b02, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_STRIDE", _IOC_NONE, 0x6b05, 0x00 },
+{ "video/kyro.h", "KYRO_IOCTL_UVSTRIDE", _IOC_NONE, 0x6b03, 0x00 },
+{ "video/mbxfb.h", "MBXFB_IOCG_ALPHA", _IOC_READ, 0xf401, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_ALPHA", _IOC_WRITE, 0xf402, 0x18 },
+{ "video/mbxfb.h", "MBXFB_IOCS_PLANEORDER", _IOC_READ, 0xf403, 0x02 },
+{ "video/mbxfb.h", "MBXFB_IOCS_REG", _IOC_WRITE, 0xf404, 0x0c },
+{ "video/mbxfb.h", "MBXFB_IOCX_OVERLAY", _IOC_READ|_IOC_WRITE, 0xf400, 0x30 },
+{ "video/mbxfb.h", "MBXFB_IOCX_REG", _IOC_READ|_IOC_WRITE, 0xf405, 0x0c },
+{ "video/sisfb.h", "SISFB_COMMAND", _IOC_READ|_IOC_WRITE, 0xf305, 0x54 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE", _IOC_READ, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_AUTOMAXIMIZE_OLD", _IOC_READ, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO", _IOC_READ, 0xf301, 0x11c },
+{ "video/sisfb.h", "SISFB_GET_INFO_OLD", _IOC_READ, 0x6ef8, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_INFO_SIZE", _IOC_READ, 0xf300, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_TVPOSOFFSET", _IOC_READ, 0xf304, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS", _IOC_READ, 0xf302, 0x04 },
+{ "video/sisfb.h", "SISFB_GET_VBRSTATUS_OLD", _IOC_READ, 0x6ef9, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE", _IOC_WRITE, 0xf303, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_AUTOMAXIMIZE_OLD", _IOC_WRITE, 0x6efa, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_LOCK", _IOC_WRITE, 0xf306, 0x04 },
+{ "video/sisfb.h", "SISFB_SET_TVPOSOFFSET", _IOC_WRITE, 0xf304, 0x04 },
+{ "video/sstfb.h", "SSTFB_GET_VGAPASS", _IOC_READ, 0x46dd, 0x04 },
+{ "video/sstfb.h", "SSTFB_SET_VGAPASS", _IOC_WRITE, 0x46dd, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_INTERDOMAIN", _IOC_NONE, 0x4501, 0x08 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_UNBOUND_PORT", _IOC_NONE, 0x4502, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_BIND_VIRQ", _IOC_NONE, 0x4500, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_NOTIFY", _IOC_NONE, 0x4504, 0x04 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_RESET", _IOC_NONE, 0x4505, 0x00 },
+{ "xen/evtchn.h", "IOCTL_EVTCHN_UNBIND", _IOC_NONE, 0x4503, 0x04 },
+{ "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 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_MAX_GRANTS", _IOC_NONE, 0x4703, 0x04 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_SET_UNMAP_NOTIFY", _IOC_NONE, 0x4707, 0x10 },
+{ "xen/gntdev.h", "IOCTL_GNTDEV_UNMAP_GRANT_REF", _IOC_NONE, 0x4701, 0x10 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_EVTCHN", _IOC_NONE, 0x4200, 0x00 },
+{ "xen/xenbus_dev.h", "IOCTL_XENBUS_BACKEND_SETUP", _IOC_NONE, 0x4201, 0x00 },
diff --git a/strace/linux/x32/ioctls_inc1.h b/strace/linux/x32/ioctls_inc1.h
new file mode 100644
index 0000000..c9fcdf8
--- /dev/null
+++ b/strace/linux/x32/ioctls_inc1.h
@@ -0,0 +1 @@
+#include "i386/ioctls_inc0.h"
diff --git a/strace/linux/x32/signalent1.h b/strace/linux/x32/signalent1.h
new file mode 100644
index 0000000..fdae15f
--- /dev/null
+++ b/strace/linux/x32/signalent1.h
@@ -0,0 +1,2 @@
+/* i386 personality */
+#include "signalent.h"
diff --git a/strace/linux/x32/syscallent.h b/strace/linux/x32/syscallent.h
new file mode 100644
index 0000000..d07ff1c
--- /dev/null
+++ b/strace/linux/x32/syscallent.h
@@ -0,0 +1,368 @@
+[  0] = { 3,	TD,		SEN(read),			"read"			},
+[  1] = { 3,	TD,		SEN(write),			"write"			},
+[  2] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  3] = { 1,	TD,		SEN(close),			"close"			},
+[  4] = { 2,	TF,		SEN(stat),			"stat"			},
+[  5] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[  6] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[  7] = { 3,	TD,		SEN(poll),			"poll"			},
+[  8] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[  9] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 10] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[ 11] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 12] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 13] = { 4,	TS,		SEN(printargs),			"64:rt_sigaction"	},
+[ 14] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[ 15] = { 0,	TS,		SEN(printargs),			"64:rt_sigreturn"	},
+[ 16] = { 3,	TD,		SEN(printargs),			"64:ioctl"		},
+[ 17] = { 4,	TD,		SEN(pread),			"pread64"		},
+[ 18] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 19] = { 3,	TD,		SEN(printargs),			"64:readv"		},
+[ 20] = { 3,	TD,		SEN(printargs),			"64:writev"		},
+[ 21] = { 2,	TF,		SEN(access),			"access"		},
+[ 22] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 23] = { 5,	TD,		SEN(select),			"select"		},
+[ 24] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[ 25] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[ 26] = { 3,	TM,		SEN(msync),			"msync"			},
+[ 27] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[ 28] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[ 29] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[ 30] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[ 31] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[ 32] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 33] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 34] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 35] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[ 36] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[ 37] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 38] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[ 39] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 40] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile"		},
+[ 41] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 42] = { 3,	TN,		SEN(connect),			"connect"		},
+[ 43] = { 3,	TN,		SEN(accept),			"accept"		},
+[ 44] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[ 45] = { 6,	TN,		SEN(printargs),			"64:recvfrom"		},
+[ 46] = { 3,	TN,		SEN(printargs),			"64:sendmsg"		},
+[ 47] = { 3,	TN,		SEN(printargs),			"64:recvmsg"		},
+[ 48] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[ 49] = { 3,	TN,		SEN(bind),			"bind"			},
+[ 50] = { 2,	TN,		SEN(listen),			"listen"		},
+[ 51] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[ 52] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[ 53] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[ 54] = { 5,	TN,		SEN(printargs),			"64:setsockopt"		},
+[ 55] = { 5,	TN,		SEN(printargs),			"64:getsockopt"		},
+[ 56] = { 5,	TP,		SEN(clone),			"clone"			},
+[ 57] = { 0,	TP,		SEN(fork),			"fork"			},
+[ 58] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[ 59] = { 3,	TF|TP|SE|SI,	SEN(printargs),			"64:execve"		},
+[ 60] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[ 61] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[ 62] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 63] = { 1,	0,		SEN(uname),			"uname"			},
+[ 64] = { 3,	TI,		SEN(semget),			"semget"		},
+[ 65] = { 3,	TI,		SEN(semop),			"semop"			},
+[ 66] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[ 67] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[ 68] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[ 69] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[ 70] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[ 71] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[ 72] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 73] = { 2,	TD,		SEN(flock),			"flock"			},
+[ 74] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 75] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[ 76] = { 2,	TF,		SEN(truncate64),		"truncate"		},
+[ 77] = { 2,	TD,		SEN(ftruncate64),		"ftruncate"		},
+[ 78] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[ 79] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[ 80] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 81] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 82] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 83] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 84] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 85] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[ 86] = { 2,	TF,		SEN(link),			"link"			},
+[ 87] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 88] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 89] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 90] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 91] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 92] = { 3,	TF,		SEN(chown),			"chown"			},
+[ 93] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 94] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 95] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 96] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 97] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 98] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 99] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[100] = { 1,	0,		SEN(times),			"times"			},
+[101] = { 4,	0,		SEN(printargs),			"64:ptrace"		},
+[102] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[105] = { 1,	0,		SEN(setuid),			"setuid"		},
+[106] = { 1,	0,		SEN(setgid),			"setgid"		},
+[107] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[108] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[109] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[110] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[111] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[112] = { 0,	0,		SEN(setsid),			"setsid"		},
+[113] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[114] = { 2,	0,		SEN(setregid),			"setregid"		},
+[115] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[116] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[117] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[118] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[119] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[120] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[121] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[122] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[123] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[124] = { 1,	0,		SEN(getsid),			"getsid"		},
+[125] = { 2,	0,		SEN(capget),			"capget"		},
+[126] = { 2,	0,		SEN(capset),			"capset"		},
+[127] = { 2,	TS,		SEN(printargs),			"64:rt_sigpending"	},
+[128] = { 4,	TS,		SEN(printargs),			"64:rt_sigtimedwait"	},
+[129] = { 3,	TS,		SEN(printargs),			"64:rt_sigqueueinfo"	},
+[130] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[131] = { 2,	TS,		SEN(printargs),			"64:sigaltstack"	},
+[132] = { 2,	TF,		SEN(utime),			"utime"			},
+[133] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[134] = { 1,	TF,		SEN(printargs),			"64:uselib"		},
+[135] = { 1,	NF,		SEN(personality),		"personality"		},
+[136] = { 2,	0,		SEN(ustat),			"ustat"			},
+[137] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[138] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[139] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[140] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[141] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[142] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[143] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[144] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[145] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[146] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[147] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[148] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[149] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[150] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[151] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[152] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[153] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[154] = { 3,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[155] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[156] = { 1,	0,		SEN(printargs),			"64:_sysctl"		},
+[157] = { 5,	0,		SEN(prctl),			"prctl"			},
+[158] = { 2,	TP,		SEN(arch_prctl),		"arch_prctl"		},
+[159] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[160] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[161] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[162] = { 0,	0,		SEN(sync),			"sync"			},
+[163] = { 1,	TF,		SEN(acct),			"acct"			},
+[164] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[165] = { 5,	TF,		SEN(mount),			"mount"			},
+[166] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[167] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[168] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[169] = { 4,	0,		SEN(reboot),			"reboot"		},
+[170] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[171] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[172] = { 1,	0,		SEN(iopl),			"iopl"			},
+[173] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[174] = { 2,	0,		SEN(printargs),			"64:create_module"	},
+[175] = { 3,	0,		SEN(init_module),		"init_module"		},
+[176] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[177] = { 1,	0,		SEN(printargs),			"64:get_kernel_syms"	},
+[178] = { 5,	0,		SEN(printargs),			"64:query_module"	},
+[179] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[180] = { 3,	0,		SEN(printargs),			"64:nfsservctl"		},
+[181] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[182] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[183] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[184] = { 3,	0,		SEN(tuxcall),			"tuxcall"		},
+[185] = { 3,	0,		SEN(security),			"security"		},
+[186] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[187] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[188] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[189] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[190] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[191] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[192] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[193] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[194] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[195] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[196] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[197] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[198] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[199] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[200] = { 2,	TS,		SEN(kill),			"tkill"			},
+[201] = { 1,	0,		SEN(time),			"time"			},
+[202] = { 6,	0,		SEN(futex),			"futex"			},
+[203] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[204] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[205] = { 1,	0,		SEN(printargs),			"64:set_thread_area"	},
+[206] = { 2,	0,		SEN(printargs),			"64:io_setup"		},
+[207] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[208] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[209] = { 3,	0,		SEN(printargs),			"64:io_submit"		},
+[210] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[211] = { 1,	0,		SEN(printargs),			"64:get_thread_area"	},
+[212] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[213] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[214] = { 4,	0,		SEN(printargs),			"64:epoll_ctl_old"	},
+[215] = { 4,	0,		SEN(printargs),			"64:epoll_wait_old"	},
+[216] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[217] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[218] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[219] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[220] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[221] = { 4,	TD,		SEN(fadvise64_64),		"fadvise64"		},
+[222] = { 3,	0,		SEN(printargs),			"64:timer_create"	},
+[223] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[224] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[225] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[226] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[227] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[228] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[229] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[230] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[231] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[232] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[233] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[234] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[235] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[236] = { 5,	0,		SEN(printargs),			"64:vserver"		},
+[237] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[238] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[239] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[240] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[241] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[242] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[243] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[244] = { 2,	0,		SEN(printargs),			"64:mq_notify"		},
+[245] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[246] = { 4,	0,		SEN(printargs),			"64:kexec_load"		},
+[247] = { 5,	TP,		SEN(printargs),			"64:waitid"		},
+[248] = { 5,	0,		SEN(add_key),			"add_key"		},
+[249] = { 4,	0,		SEN(request_key),		"request_key"		},
+[250] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[251] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[252] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[253] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[254] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[255] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[256] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[257] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[258] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[259] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[260] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[261] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[262] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[263] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[264] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[265] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[266] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[267] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[268] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[269] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[270] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[271] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[272] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[273] = { 2,	0,		SEN(printargs),			"64:set_robust_list"	},
+[274] = { 3,	0,		SEN(printargs),			"64:get_robust_list"	},
+[275] = { 6,	TD,		SEN(splice),			"splice"		},
+[276] = { 4,	TD,		SEN(tee),			"tee"			},
+[277] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[278] = { 4,	TD,		SEN(printargs),			"64:vmsplice"		},
+[279] = { 6,	TM,		SEN(printargs),			"64:move_pages"		},
+[280] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[281] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[282] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[283] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[284] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[285] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[286] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[287] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[288] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[289] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[290] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[291] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[292] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[293] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[294] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[295] = { 4,	TD,		SEN(printargs),			"64:preadv"		},
+[296] = { 4,	TD,		SEN(printargs),			"64:pwritev"		},
+[297] = { 4,	TP|TS,		SEN(printargs),			"64:rt_tgsigqueueinfo"	},
+[298] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[299] = { 5,	TN,		SEN(printargs),			"64:recvmmsg"		},
+[300] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[301] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[302] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[303] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[304] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[305] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[306] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[307] = { 4,	TN,		SEN(printargs),			"64:sendmmsg"		},
+[308] = { 2,	TD,		SEN(setns),			"setns"			},
+[309] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[310] = { 6,	0,		SEN(printargs),			"64:process_vm_readv"	},
+[311] = { 6,	0,		SEN(printargs),			"64:process_vm_writev"	},
+[312] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[313] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[314] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[315] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[316] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[317] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[318] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[319] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[320] = { 5,	TD,		SEN(kexec_file_load),		"kexec_file_load",	},
+[321] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[322] = { 5,	TD|TF|TP|SE|SI,	SEN(printargs),			"64:execveat",		},
+[323] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[324] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[325] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[326] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[327] = { 6,	TD,		SEN(printargs),			"64:preadv2"		},
+[328] = { 6,	TD,		SEN(printargs),			"64:pwritev2"		},
+[327 ... 511] = { },
+/*
+ * x32-specific system call numbers start at 512 to avoid cache impact
+ * for native 64-bit operation.
+ */
+[512] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[513] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[514] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[515] = { 3,	TD,		SEN(readv),			"readv"			},
+[516] = { 3,	TD,		SEN(writev),			"writev"		},
+[517] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[518] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[519] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[520] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[521] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[522] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[523] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[524] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[525] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[526] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[527] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[528] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[529] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[530] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[531] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[532] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[533] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[534] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[535] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[536] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[537] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[538] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[539] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[540] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[541] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[542] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[543] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[544] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[545] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
diff --git a/strace/linux/x32/syscallent1.h b/strace/linux/x32/syscallent1.h
new file mode 100644
index 0000000..c9100de
--- /dev/null
+++ b/strace/linux/x32/syscallent1.h
@@ -0,0 +1,3 @@
+/* Our second set comes from the i386 files.  */
+
+#include "../i386/syscallent.h"
diff --git a/strace/linux/x32/userent.h b/strace/linux/x32/userent.h
new file mode 100644
index 0000000..ae69a3f
--- /dev/null
+++ b/strace/linux/x32/userent.h
@@ -0,0 +1 @@
+#include "../x86_64/userent.h"
diff --git a/strace/linux/x86_64/arch_regs.c b/strace/linux/x86_64/arch_regs.c
new file mode 100644
index 0000000..daee69f
--- /dev/null
+++ b/strace/linux/x86_64/arch_regs.c
@@ -0,0 +1,41 @@
+/*
+ * On i386, pt_regs and user_regs_struct are the same,
+ * but on 64 bit x86, user_regs_struct has six more fields:
+ * fs_base, gs_base, ds, es, fs, gs.
+ * PTRACE_GETREGS fills them too, so struct pt_regs would overflow.
+ */
+struct i386_user_regs_struct {
+	uint32_t ebx;
+	uint32_t ecx;
+	uint32_t edx;
+	uint32_t esi;
+	uint32_t edi;
+	uint32_t ebp;
+	uint32_t eax;
+	uint32_t xds;
+	uint32_t xes;
+	uint32_t xfs;
+	uint32_t xgs;
+	uint32_t orig_eax;
+	uint32_t eip;
+	uint32_t xcs;
+	uint32_t eflags;
+	uint32_t esp;
+	uint32_t xss;
+};
+static union {
+	struct user_regs_struct      x86_64_r;
+	struct i386_user_regs_struct i386_r;
+} x86_regs_union;
+#define x86_64_regs x86_regs_union.x86_64_r
+#define i386_regs   x86_regs_union.i386_r
+
+uint32_t *const i386_esp_ptr = &i386_regs.esp;
+uint64_t *const x86_64_rsp_ptr = (uint64_t *) &x86_64_regs.rsp;
+static struct iovec x86_io = {
+	.iov_base = &x86_regs_union
+};
+
+#define ARCH_REGS_FOR_GETREGSET x86_regs_union
+#define ARCH_IOVEC_FOR_GETREGSET x86_io
+#define ARCH_PC_REG (x86_io.iov_len == sizeof(i386_regs) ? i386_regs.eip : x86_64_regs.rip)
diff --git a/strace/linux/x86_64/arch_regs.h b/strace/linux/x86_64/arch_regs.h
new file mode 100644
index 0000000..c2ccee6
--- /dev/null
+++ b/strace/linux/x86_64/arch_regs.h
@@ -0,0 +1,2 @@
+extern uint32_t *const i386_esp_ptr;
+extern uint64_t *const x86_64_rsp_ptr;
diff --git a/strace/linux/x86_64/arch_sigreturn.c b/strace/linux/x86_64/arch_sigreturn.c
new file mode 100644
index 0000000..1de0a0a
--- /dev/null
+++ b/strace/linux/x86_64/arch_sigreturn.c
@@ -0,0 +1,32 @@
+#define	arch_sigreturn	i386_arch_sigreturn
+#include "i386/arch_sigreturn.c"
+#undef arch_sigreturn
+
+static void
+arch_sigreturn(struct tcb *tcp)
+{
+	if (current_personality == 1) {
+		i386_arch_sigreturn(tcp);
+		return;
+	}
+
+	typedef struct {
+		uint32_t flags, link, stack[3], pad;
+		struct sigcontext mcontext;
+	} ucontext_x32_header;
+
+#define	X86_64_SIGMASK_OFFSET	offsetof(struct ucontext, uc_sigmask)
+#define	X32_SIGMASK_OFFSET	sizeof(ucontext_x32_header)
+
+	const unsigned long offset =
+#ifdef X32
+		X32_SIGMASK_OFFSET;
+#else
+		current_personality == 2 ? X32_SIGMASK_OFFSET :
+					   X86_64_SIGMASK_OFFSET;
+#endif
+	const unsigned long addr = (unsigned long) *x86_64_rsp_ptr + offset;
+	tprints("{mask=");
+	print_sigset_addr_len(tcp, addr, NSIG / 8);
+	tprints("}");
+}
diff --git a/strace/linux/x86_64/errnoent1.h b/strace/linux/x86_64/errnoent1.h
new file mode 100644
index 0000000..d32435a
--- /dev/null
+++ b/strace/linux/x86_64/errnoent1.h
@@ -0,0 +1,2 @@
+/* i386 personality */
+#include "errnoent.h"
diff --git a/strace/linux/x86_64/errnoent2.h b/strace/linux/x86_64/errnoent2.h
new file mode 100644
index 0000000..2192ec8
--- /dev/null
+++ b/strace/linux/x86_64/errnoent2.h
@@ -0,0 +1,2 @@
+/* x32 personality */
+#include "errnoent.h"
diff --git a/strace/linux/x86_64/gentab.pl b/strace/linux/x86_64/gentab.pl
new file mode 100644
index 0000000..52f7aa9
--- /dev/null
+++ b/strace/linux/x86_64/gentab.pl
@@ -0,0 +1,73 @@
+#!/usr/bin/perl -w
+#generate syscall table from a template file (usually the master i386 syscall
+#ent.h) and the x86_64 unistd.h
+%conv =  (
+	"exit" => "_exit",
+);
+
+%known = (
+	"mmap" => "sys_mmap",
+	"sched_yield" => "printargs",
+);
+
+# only used when the template file has no entry
+%args = (
+	"arch_prctl" => 2,
+	"tkill" => 2,
+	"gettid" => 0,
+	"readahead" => 3,
+	# should decode all these:
+	"setxattr" => 5,
+	"lsetxattr" => 5,
+	"fsetxattr" => 5,
+	"getxattr" => 4,
+	"lgetxattr" => 4,
+	"fgetxattr" => 4,
+	"listxattr" => 3,
+	"llistxattr" => 3,
+	"flistxattr" => 3,
+	"removexattr" => 2,
+	"lremovexattr" => 2,
+	"fremovexattr" => 2,
+	"mmap" => 6,
+	"sched_yield" => 0,
+);
+
+open(F,$ARGV[0]) || die "cannot open template file $ARGV[0]\n";
+
+while (<F>) {
+	next unless /{/;
+	s/\/\*.*\*\///;
+	($name) = /"([^"]+)"/;
+	chomp;
+	$call{$name} = $_;
+}
+
+open(SL, ">syscallnum.h") || die "cannot create syscallnum.h\n";
+
+open(S,$ARGV[1]) || die "cannot open syscall file $ARGV[1]\n";
+while (<S>) {
+	$name = "";
+	next unless  (($name, $num) = /define\s+__NR_(\S+)\s+(\d+)/);
+	next if $name eq "";
+
+	$name = $conv{$name} if defined($conv{$name});
+
+	if (!defined($call{$name})) {
+		unless (defined($args{$name})) {
+			print STDERR "unknown call $name $num\n";
+			$na = 3;
+		} else {
+			$na = $args{$name};
+		}
+		if (defined($known{$name})) {
+			$func = $known{$name};
+		} else {
+			$func = "printargs";
+		}
+		print "\t{ $na,\t0,\t$func,\t\"$name\" }, /* $num */\n";
+	} else {
+		print "$call{$name} /* $num */\n";
+	}
+	print SL "#define SYS_$name $num\n"
+}
diff --git a/strace/linux/x86_64/get_error.c b/strace/linux/x86_64/get_error.c
new file mode 100644
index 0000000..ddf78b7
--- /dev/null
+++ b/strace/linux/x86_64/get_error.c
@@ -0,0 +1,27 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	/*
+	 * In X32, return value is 64-bit (llseek uses one).
+	 * Using merely "long rax" would not work.
+	 */
+	long long rax;
+
+	if (x86_io.iov_len == sizeof(i386_regs)) {
+		/* Sign extend from 32 bits */
+		rax = (int32_t) i386_regs.eax;
+	} else {
+		rax = x86_64_regs.rax;
+	}
+
+	if (check_errno && is_negated_errno(rax)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -rax;
+	} else {
+		tcp->u_rval = rax;
+#ifdef X32
+		/* tcp->u_rval contains a truncated value */
+		tcp->u_lrval = rax;
+#endif
+	}
+}
diff --git a/strace/linux/x86_64/get_scno.c b/strace/linux/x86_64/get_scno.c
new file mode 100644
index 0000000..af3329a
--- /dev/null
+++ b/strace/linux/x86_64/get_scno.c
@@ -0,0 +1,148 @@
+/*
+ * Copyright (c) 2002 Andi Kleen <ak@suse.de>
+ * Copyright (c) 2002 Michal Ludvig <mludvig@suse.cz>
+ * Copyright (c) 2002 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2008-2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2012 H.J. Lu <hongjiu.lu@intel.com>
+ * Copyright (c) 2010-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	long scno = 0;
+	unsigned int currpers;
+
+#ifndef __X32_SYSCALL_BIT
+# define __X32_SYSCALL_BIT	0x40000000
+#endif
+
+#if 1
+	/*
+	 * GETREGSET of NT_PRSTATUS tells us regset size,
+	 * which unambiguously detects i386.
+	 *
+	 * Linux kernel distinguishes x86-64 and x32 processes
+	 * solely by looking at __X32_SYSCALL_BIT:
+	 * arch/x86/include/asm/compat.h::is_x32_task():
+	 * if (task_pt_regs(current)->orig_ax & __X32_SYSCALL_BIT)
+	 *         return true;
+	 */
+	if (x86_io.iov_len == sizeof(i386_regs)) {
+		scno = i386_regs.orig_eax;
+		currpers = 1;
+	} else {
+		scno = x86_64_regs.orig_rax;
+		currpers = 0;
+		if (scno & __X32_SYSCALL_BIT) {
+			/*
+			 * Syscall number -1 requires special treatment:
+			 * it might be a side effect of SECCOMP_RET_ERRNO
+			 * filtering that sets orig_rax to -1
+			 * in some versions of linux kernel.
+			 * If that is the case, then
+			 * __X32_SYSCALL_BIT logic does not apply.
+			 */
+			if ((long long) x86_64_regs.orig_rax != -1) {
+				scno -= __X32_SYSCALL_BIT;
+				currpers = 2;
+			} else {
+# ifdef X32
+				currpers = 2;
+# endif
+			}
+		}
+	}
+
+#elif 0
+	/*
+	 * cs = 0x33 for long mode (native 64 bit and x32)
+	 * cs = 0x23 for compatibility mode (32 bit)
+	 * ds = 0x2b for x32 mode (x86-64 in 32 bit)
+	 */
+	scno = x86_64_regs.orig_rax;
+	switch (x86_64_regs.cs) {
+		case 0x23: currpers = 1; break;
+		case 0x33:
+			if (x86_64_regs.ds == 0x2b) {
+				currpers = 2;
+				scno &= ~__X32_SYSCALL_BIT;
+			} else
+				currpers = 0;
+			break;
+		default:
+			error_msg("Unknown value CS=0x%08X while "
+				  "detecting personality of process PID=%d",
+				  (int)x86_64_regs.cs, tcp->pid);
+			currpers = current_personality;
+			break;
+	}
+#elif 0
+	/*
+	 * This version analyzes the opcode of a syscall instruction.
+	 * (int 0x80 on i386 vs. syscall on x86-64)
+	 * It works, but is too complicated, and strictly speaking, unreliable.
+	 */
+	unsigned long call, rip = x86_64_regs.rip;
+	/* sizeof(syscall) == sizeof(int 0x80) == 2 */
+	rip -= 2;
+	errno = 0;
+	call = ptrace(PTRACE_PEEKTEXT, tcp->pid, (char *)rip, (char *)0);
+	if (errno)
+		perror_msg("ptrace_peektext failed");
+	switch (call & 0xffff) {
+		/* x86-64: syscall = 0x0f 0x05 */
+		case 0x050f: currpers = 0; break;
+		/* i386: int 0x80 = 0xcd 0x80 */
+		case 0x80cd: currpers = 1; break;
+		default:
+			currpers = current_personality;
+			error_msg("Unknown syscall opcode (0x%04X) while "
+				  "detecting personality of process PID=%d",
+				  (int)call, tcp->pid);
+			break;
+	}
+#endif
+
+#ifdef X32
+	/*
+	 * If we are built for a x32 system, then personality 0 is x32
+	 * (not x86_64), and stracing of x86_64 apps is not supported.
+	 * Stracing of i386 apps is still supported.
+	 */
+	if (currpers == 0) {
+		error_msg("syscall_%lu(...) in unsupported "
+			  "64-bit mode of process PID=%d", scno, tcp->pid);
+		return 0;
+	}
+	currpers &= ~2; /* map 2,1 to 0,1 */
+#endif /* X32 */
+
+	update_personality(tcp, currpers);
+	tcp->scno = scno;
+	return 1;
+}
diff --git a/strace/linux/x86_64/get_syscall_args.c b/strace/linux/x86_64/get_syscall_args.c
new file mode 100644
index 0000000..fa591fb
--- /dev/null
+++ b/strace/linux/x86_64/get_syscall_args.c
@@ -0,0 +1,35 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	if (x86_io.iov_len != sizeof(i386_regs)) {
+		/* x86-64 or x32 ABI */
+		tcp->u_arg[0] = x86_64_regs.rdi;
+		tcp->u_arg[1] = x86_64_regs.rsi;
+		tcp->u_arg[2] = x86_64_regs.rdx;
+		tcp->u_arg[3] = x86_64_regs.r10;
+		tcp->u_arg[4] = x86_64_regs.r8;
+		tcp->u_arg[5] = x86_64_regs.r9;
+#ifdef X32
+		tcp->ext_arg[0] = x86_64_regs.rdi;
+		tcp->ext_arg[1] = x86_64_regs.rsi;
+		tcp->ext_arg[2] = x86_64_regs.rdx;
+		tcp->ext_arg[3] = x86_64_regs.r10;
+		tcp->ext_arg[4] = x86_64_regs.r8;
+		tcp->ext_arg[5] = x86_64_regs.r9;
+#endif
+	} else {
+		/* i386 ABI */
+		/* Zero-extend from 32 bits */
+		/* Use widen_to_long(tcp->u_arg[N]) in syscall handlers
+		 * if you need to use *sign-extended* parameter.
+		 */
+		tcp->u_arg[0] = (long)(uint32_t)i386_regs.ebx;
+		tcp->u_arg[1] = (long)(uint32_t)i386_regs.ecx;
+		tcp->u_arg[2] = (long)(uint32_t)i386_regs.edx;
+		tcp->u_arg[3] = (long)(uint32_t)i386_regs.esi;
+		tcp->u_arg[4] = (long)(uint32_t)i386_regs.edi;
+		tcp->u_arg[5] = (long)(uint32_t)i386_regs.ebp;
+	}
+	return 1;
+}
diff --git a/strace/linux/x86_64/getregs_old.c b/strace/linux/x86_64/getregs_old.c
new file mode 100644
index 0000000..9f7c248
--- /dev/null
+++ b/strace/linux/x86_64/getregs_old.c
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+/*
+ * PTRACE_GETREGSET was added to the kernel in v2.6.25,
+ * a PTRACE_GETREGS based fallback is provided for old kernels.
+ */
+static int
+getregs_old(pid_t pid)
+{
+	/* Use old method, with unreliable heuristical detection of 32-bitness. */
+	long r = ptrace(PTRACE_GETREGS, pid, NULL, &x86_64_regs);
+	if (r)
+		return r;
+
+	if (x86_64_regs.cs == 0x23) {
+		x86_io.iov_len = sizeof(i386_regs);
+		/*
+		 * The order is important: i386_regs and x86_64_regs
+		 * are overlaid in memory!
+		 */
+		i386_regs.ebx = x86_64_regs.rbx;
+		i386_regs.ecx = x86_64_regs.rcx;
+		i386_regs.edx = x86_64_regs.rdx;
+		i386_regs.esi = x86_64_regs.rsi;
+		i386_regs.edi = x86_64_regs.rdi;
+		i386_regs.ebp = x86_64_regs.rbp;
+		i386_regs.eax = x86_64_regs.rax;
+		/* i386_regs.xds = x86_64_regs.ds; unused by strace */
+		/* i386_regs.xes = x86_64_regs.es; ditto... */
+		/* i386_regs.xfs = x86_64_regs.fs; */
+		/* i386_regs.xgs = x86_64_regs.gs; */
+		i386_regs.orig_eax = x86_64_regs.orig_rax;
+		i386_regs.eip = x86_64_regs.rip;
+		/* i386_regs.xcs = x86_64_regs.cs; */
+		/* i386_regs.eflags = x86_64_regs.eflags; */
+		i386_regs.esp = x86_64_regs.rsp;
+		/* i386_regs.xss = x86_64_regs.ss; */
+	} else {
+		x86_io.iov_len = sizeof(x86_64_regs);
+	}
+	return 0;
+}
diff --git a/strace/linux/x86_64/ioctls_arch0.h b/strace/linux/x86_64/ioctls_arch0.h
new file mode 100644
index 0000000..3a978f0
--- /dev/null
+++ b/strace/linux/x86_64/ioctls_arch0.h
@@ -0,0 +1,16 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/x86/include/ tree. */
+{ "asm/mce.h", "MCE_GETCLEAR_FLAGS", _IOC_READ, 0x4d03, 0x04 },
+{ "asm/mce.h", "MCE_GET_LOG_LEN", _IOC_READ, 0x4d02, 0x04 },
+{ "asm/mce.h", "MCE_GET_RECORD_LEN", _IOC_READ, 0x4d01, 0x04 },
+{ "asm/msr.h", "X86_IOC_RDMSR_REGS", _IOC_READ|_IOC_WRITE, 0x63a0, 0x20 },
+{ "asm/msr.h", "X86_IOC_WRMSR_REGS", _IOC_READ|_IOC_WRITE, 0x63a1, 0x20 },
+{ "asm/mtrr.h", "MTRRIOC_ADD_ENTRY", _IOC_WRITE, 0x4d00, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_ADD_PAGE_ENTRY", _IOC_WRITE, 0x4d05, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_DEL_ENTRY", _IOC_WRITE, 0x4d02, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_DEL_PAGE_ENTRY", _IOC_WRITE, 0x4d07, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_GET_ENTRY", _IOC_READ|_IOC_WRITE, 0x4d03, 0x18 },
+{ "asm/mtrr.h", "MTRRIOC_GET_PAGE_ENTRY", _IOC_READ|_IOC_WRITE, 0x4d08, 0x18 },
+{ "asm/mtrr.h", "MTRRIOC_KILL_ENTRY", _IOC_WRITE, 0x4d04, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_KILL_PAGE_ENTRY", _IOC_WRITE, 0x4d09, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_SET_ENTRY", _IOC_WRITE, 0x4d01, 0x10 },
+{ "asm/mtrr.h", "MTRRIOC_SET_PAGE_ENTRY", _IOC_WRITE, 0x4d06, 0x10 },
diff --git a/strace/linux/x86_64/ioctls_arch1.h b/strace/linux/x86_64/ioctls_arch1.h
new file mode 100644
index 0000000..58a5706
--- /dev/null
+++ b/strace/linux/x86_64/ioctls_arch1.h
@@ -0,0 +1 @@
+#include "i386/ioctls_arch0.h"
diff --git a/strace/linux/x86_64/ioctls_arch2.h b/strace/linux/x86_64/ioctls_arch2.h
new file mode 100644
index 0000000..41d00f9
--- /dev/null
+++ b/strace/linux/x86_64/ioctls_arch2.h
@@ -0,0 +1 @@
+#include "ioctls_arch0.h"
diff --git a/strace/linux/x86_64/ioctls_inc0.h b/strace/linux/x86_64/ioctls_inc0.h
new file mode 100644
index 0000000..f9939fa
--- /dev/null
+++ b/strace/linux/x86_64/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "64/ioctls_inc.h"
diff --git a/strace/linux/x86_64/ioctls_inc1.h b/strace/linux/x86_64/ioctls_inc1.h
new file mode 100644
index 0000000..c9fcdf8
--- /dev/null
+++ b/strace/linux/x86_64/ioctls_inc1.h
@@ -0,0 +1 @@
+#include "i386/ioctls_inc0.h"
diff --git a/strace/linux/x86_64/ioctls_inc2.h b/strace/linux/x86_64/ioctls_inc2.h
new file mode 100644
index 0000000..9749664
--- /dev/null
+++ b/strace/linux/x86_64/ioctls_inc2.h
@@ -0,0 +1 @@
+#include "x32/ioctls_inc0.h"
diff --git a/strace/linux/x86_64/signalent1.h b/strace/linux/x86_64/signalent1.h
new file mode 100644
index 0000000..fdae15f
--- /dev/null
+++ b/strace/linux/x86_64/signalent1.h
@@ -0,0 +1,2 @@
+/* i386 personality */
+#include "signalent.h"
diff --git a/strace/linux/x86_64/signalent2.h b/strace/linux/x86_64/signalent2.h
new file mode 100644
index 0000000..6b32d62
--- /dev/null
+++ b/strace/linux/x86_64/signalent2.h
@@ -0,0 +1,2 @@
+/* x32 personality */
+#include "signalent.h"
diff --git a/strace/linux/x86_64/syscallent.h b/strace/linux/x86_64/syscallent.h
new file mode 100644
index 0000000..265d55f
--- /dev/null
+++ b/strace/linux/x86_64/syscallent.h
@@ -0,0 +1,329 @@
+[  0] = { 3,	TD,		SEN(read),			"read"			},
+[  1] = { 3,	TD,		SEN(write),			"write"			},
+[  2] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  3] = { 1,	TD,		SEN(close),			"close"			},
+[  4] = { 2,	TF,		SEN(stat),			"stat"			},
+[  5] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[  6] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[  7] = { 3,	TD,		SEN(poll),			"poll"			},
+[  8] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[  9] = { 6,	TD|TM|SI,	SEN(mmap),			"mmap"			},
+[ 10] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[ 11] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 12] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 13] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[ 14] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[ 15] = { 0,	TS,		SEN(sigreturn),			"rt_sigreturn"		},
+[ 16] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 17] = { 4,	TD,		SEN(pread),			"pread64"		},
+[ 18] = { 4,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 19] = { 3,	TD,		SEN(readv),			"readv"			},
+[ 20] = { 3,	TD,		SEN(writev),			"writev"		},
+[ 21] = { 2,	TF,		SEN(access),			"access"		},
+[ 22] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 23] = { 5,	TD,		SEN(select),			"select"		},
+[ 24] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[ 25] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[ 26] = { 3,	TM,		SEN(msync),			"msync"			},
+[ 27] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[ 28] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[ 29] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[ 30] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[ 31] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[ 32] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 33] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 34] = { 0,	TS,		SEN(pause),			"pause"			},
+[ 35] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[ 36] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[ 37] = { 1,	0,		SEN(alarm),			"alarm"			},
+[ 38] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[ 39] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[ 40] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile"		},
+[ 41] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 42] = { 3,	TN,		SEN(connect),			"connect"		},
+[ 43] = { 3,	TN,		SEN(accept),			"accept"		},
+[ 44] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[ 45] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[ 46] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[ 47] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[ 48] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[ 49] = { 3,	TN,		SEN(bind),			"bind"			},
+[ 50] = { 2,	TN,		SEN(listen),			"listen"		},
+[ 51] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[ 52] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[ 53] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[ 54] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[ 55] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[ 56] = { 5,	TP,		SEN(clone),			"clone"			},
+[ 57] = { 0,	TP,		SEN(fork),			"fork"			},
+[ 58] = { 0,	TP,		SEN(vfork),			"vfork"			},
+[ 59] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[ 60] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[ 61] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[ 62] = { 2,	TS,		SEN(kill),			"kill"			},
+[ 63] = { 1,	0,		SEN(uname),			"uname"			},
+[ 64] = { 3,	TI,		SEN(semget),			"semget"		},
+[ 65] = { 3,	TI,		SEN(semop),			"semop"			},
+[ 66] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[ 67] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[ 68] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[ 69] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[ 70] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[ 71] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[ 72] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 73] = { 2,	TD,		SEN(flock),			"flock"			},
+[ 74] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 75] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[ 76] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 77] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 78] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[ 79] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[ 80] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 81] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 82] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 83] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 84] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 85] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[ 86] = { 2,	TF,		SEN(link),			"link"			},
+[ 87] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 88] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 89] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 90] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 91] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 92] = { 3,	TF,		SEN(chown),			"chown"			},
+[ 93] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 94] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 95] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 96] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[ 97] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[ 98] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[ 99] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[100] = { 1,	0,		SEN(times),			"times"			},
+[101] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[102] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[103] = { 3,	0,		SEN(syslog),			"syslog"		},
+[104] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[105] = { 1,	0,		SEN(setuid),			"setuid"		},
+[106] = { 1,	0,		SEN(setgid),			"setgid"		},
+[107] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[108] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[109] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[110] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[111] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[112] = { 0,	0,		SEN(setsid),			"setsid"		},
+[113] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[114] = { 2,	0,		SEN(setregid),			"setregid"		},
+[115] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[116] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[117] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[118] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[119] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[120] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[121] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[122] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[123] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[124] = { 1,	0,		SEN(getsid),			"getsid"		},
+[125] = { 2,	0,		SEN(capget),			"capget"		},
+[126] = { 2,	0,		SEN(capset),			"capset"		},
+[127] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[128] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[129] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[130] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[131] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[132] = { 2,	TF,		SEN(utime),			"utime"			},
+[133] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[134] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[135] = { 1,	NF,		SEN(personality),		"personality"		},
+[136] = { 2,	0,		SEN(ustat),			"ustat"			},
+[137] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[138] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[139] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[140] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[141] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[142] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[143] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[144] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[145] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[146] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[147] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[148] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[149] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[150] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[151] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[152] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[153] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[154] = { 3,	0,		SEN(modify_ldt),		"modify_ldt"		},
+[155] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[156] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[157] = { 5,	0,		SEN(prctl),			"prctl"			},
+[158] = { 2,	TP,		SEN(arch_prctl),		"arch_prctl"		},
+[159] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[160] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[161] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[162] = { 0,	0,		SEN(sync),			"sync"			},
+[163] = { 1,	TF,		SEN(acct),			"acct"			},
+[164] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[165] = { 5,	TF,		SEN(mount),			"mount"			},
+[166] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[167] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[168] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[169] = { 4,	0,		SEN(reboot),			"reboot"		},
+[170] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[171] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[172] = { 1,	0,		SEN(iopl),			"iopl"			},
+[173] = { 3,	0,		SEN(ioperm),			"ioperm"		},
+[174] = { 2,	0,		SEN(create_module),		"create_module"		},
+[175] = { 3,	0,		SEN(init_module),		"init_module"		},
+[176] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[177] = { 1,	0,		SEN(get_kernel_syms),		"get_kernel_syms"	},
+[178] = { 5,	0,		SEN(query_module),		"query_module"		},
+[179] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[180] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[181] = { 5,	TN,		SEN(getpmsg),			"getpmsg"		},
+[182] = { 5,	TN,		SEN(putpmsg),			"putpmsg"		},
+[183] = { 5,	0,		SEN(afs_syscall),		"afs_syscall"		},
+[184] = { 3,	0,		SEN(tuxcall),			"tuxcall"		},
+[185] = { 3,	0,		SEN(security),			"security"		},
+[186] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[187] = { 3,	TD,		SEN(readahead),			"readahead"		},
+[188] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[189] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[190] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[191] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[192] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[193] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[194] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[195] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[196] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[197] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[198] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[199] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[200] = { 2,	TS,		SEN(kill),			"tkill"			},
+[201] = { 1,	0,		SEN(time),			"time"			},
+[202] = { 6,	0,		SEN(futex),			"futex"			},
+[203] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[204] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[205] = { 1,	0,		SEN(set_thread_area),		"set_thread_area"	},
+[206] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[207] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[208] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[209] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[210] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[211] = { 1,	0,		SEN(get_thread_area),		"get_thread_area"	},
+[212] = { 3,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[213] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[214] = { 4,	0,		SEN(printargs),			"epoll_ctl_old"		},
+[215] = { 4,	0,		SEN(printargs),			"epoll_wait_old"	},
+[216] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[217] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[218] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[219] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[220] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[221] = { 4,	TD,		SEN(fadvise64),			"fadvise64"		},
+[222] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[223] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[224] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[225] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[226] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[227] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[228] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[229] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[230] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[231] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[232] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[233] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[234] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[235] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[236] = { 5,	0,		SEN(vserver),			"vserver"		},
+[237] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[238] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[239] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[240] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[241] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[242] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[243] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[244] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[245] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[246] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[247] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[248] = { 5,	0,		SEN(add_key),			"add_key"		},
+[249] = { 4,	0,		SEN(request_key),		"request_key"		},
+[250] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[251] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[252] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[253] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[254] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[255] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[256] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[257] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[258] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[259] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[260] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[261] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[262] = { 4,	TD|TF,		SEN(newfstatat),		"newfstatat"		},
+[263] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[264] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[265] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[266] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[267] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[268] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[269] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[270] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[271] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[272] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[273] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[274] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[275] = { 6,	TD,		SEN(splice),			"splice"		},
+[276] = { 4,	TD,		SEN(tee),			"tee"			},
+[277] = { 4,	TD,		SEN(sync_file_range),		"sync_file_range"	},
+[278] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[279] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[280] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[281] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[282] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[283] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[284] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[285] = { 4,	TD,		SEN(fallocate),			"fallocate"		},
+[286] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[287] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[288] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[289] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[290] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[291] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[292] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[293] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[294] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[295] = { 4,	TD,		SEN(preadv),			"preadv"		},
+[296] = { 4,	TD,		SEN(pwritev),			"pwritev"		},
+[297] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[298] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[299] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[300] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[301] = { 5,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[302] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[303] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[304] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[305] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[306] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[307] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[308] = { 2,	TD,		SEN(setns),			"setns"			},
+[309] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[310] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[311] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[312] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[313] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[314] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[315] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[316] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[317] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[318] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[319] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[320] = { 5,	TD,		SEN(kexec_file_load),		"kexec_file_load",	},
+[321] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[322] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
+[323] = { 1,	TD,		SEN(userfaultfd),		"userfaultfd",		},
+[324] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+[325] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+[326] = { 6,	TD,		SEN(copy_file_range),		"copy_file_range"	},
+[327] = { 6,	TD,		SEN(preadv2),			"preadv2"		},
+[328] = { 6,	TD,		SEN(pwritev2),			"pwritev2"		},
diff --git a/strace/linux/x86_64/syscallent1.h b/strace/linux/x86_64/syscallent1.h
new file mode 100644
index 0000000..c9100de
--- /dev/null
+++ b/strace/linux/x86_64/syscallent1.h
@@ -0,0 +1,3 @@
+/* Our second set comes from the i386 files.  */
+
+#include "../i386/syscallent.h"
diff --git a/strace/linux/x86_64/syscallent2.h b/strace/linux/x86_64/syscallent2.h
new file mode 100644
index 0000000..5e0df53
--- /dev/null
+++ b/strace/linux/x86_64/syscallent2.h
@@ -0,0 +1,2 @@
+/* x32 personality */
+#include "../x32/syscallent.h"
diff --git a/strace/linux/x86_64/userent.h b/strace/linux/x86_64/userent.h
new file mode 100644
index 0000000..c5c084e
--- /dev/null
+++ b/strace/linux/x86_64/userent.h
@@ -0,0 +1,23 @@
+XLAT(8*R15),
+XLAT(8*R14),
+XLAT(8*R13),
+XLAT(8*R12),
+XLAT(8*RBP),
+XLAT(8*RBX),
+XLAT(8*R11),
+XLAT(8*R10),
+XLAT(8*R9),
+XLAT(8*R8),
+XLAT(8*RAX),
+XLAT(8*RCX),
+XLAT(8*RDX),
+XLAT(8*RSI),
+XLAT(8*RDI),
+XLAT(8*ORIG_RAX),
+XLAT(8*RIP),
+XLAT(8*CS),
+{ 8*EFLAGS, "8*EFL" },
+XLAT(8*RSP),
+XLAT(8*SS),
+/* Other fields in "struct user" */
+#include "../i386/userent0.h"
diff --git a/strace/linux/xtensa/arch_regs.c b/strace/linux/xtensa/arch_regs.c
new file mode 100644
index 0000000..d36f56a
--- /dev/null
+++ b/strace/linux/xtensa/arch_regs.c
@@ -0,0 +1,2 @@
+static long xtensa_a2;
+#define ARCH_PC_PEEK_ADDR REG_PC
diff --git a/strace/linux/xtensa/get_error.c b/strace/linux/xtensa/get_error.c
new file mode 100644
index 0000000..51ccd3b
--- /dev/null
+++ b/strace/linux/xtensa/get_error.c
@@ -0,0 +1,10 @@
+static void
+get_error(struct tcb *tcp, const bool check_errno)
+{
+	if (check_errno && is_negated_errno(xtensa_a2)) {
+		tcp->u_rval = -1;
+		tcp->u_error = -xtensa_a2;
+	} else {
+		tcp->u_rval = xtensa_a2;
+	}
+}
diff --git a/strace/linux/xtensa/get_scno.c b/strace/linux/xtensa/get_scno.c
new file mode 100644
index 0000000..d230f73
--- /dev/null
+++ b/strace/linux/xtensa/get_scno.c
@@ -0,0 +1,6 @@
+/* Return codes: 1 - ok, 0 - ignore, other - error. */
+static int
+arch_get_scno(struct tcb *tcp)
+{
+	return upeek(tcp->pid, SYSCALL_NR, &tcp->scno) < 0 ? -1 : 1;
+}
diff --git a/strace/linux/xtensa/get_syscall_args.c b/strace/linux/xtensa/get_syscall_args.c
new file mode 100644
index 0000000..a9c933a
--- /dev/null
+++ b/strace/linux/xtensa/get_syscall_args.c
@@ -0,0 +1,20 @@
+/* Return -1 on error or 1 on success (never 0!). */
+static int
+get_syscall_args(struct tcb *tcp)
+{
+	/* arg0: a6, arg1: a3, arg2: a4, arg3: a5, arg4: a8, arg5: a9 */
+	static const int xtensaregs[MAX_ARGS] = {
+		REG_A_BASE + 6,
+		REG_A_BASE + 3,
+		REG_A_BASE + 4,
+		REG_A_BASE + 5,
+		REG_A_BASE + 8,
+		REG_A_BASE + 9
+	};
+	unsigned int i;
+
+	for (i = 0; i < tcp->s_ent->nargs; ++i)
+		if (upeek(tcp->pid, xtensaregs[i], &tcp->u_arg[i]) < 0)
+			return -1;
+	return 1;
+}
diff --git a/strace/linux/xtensa/get_syscall_result.c b/strace/linux/xtensa/get_syscall_result.c
new file mode 100644
index 0000000..51ad6de
--- /dev/null
+++ b/strace/linux/xtensa/get_syscall_result.c
@@ -0,0 +1,5 @@
+static int
+get_syscall_result_regs(struct tcb *tcp)
+{
+	return upeek(tcp->pid, REG_A_BASE + 2, &xtensa_a2) < 0 ? -1 : 0;
+}
diff --git a/strace/linux/xtensa/ioctls_arch0.h b/strace/linux/xtensa/ioctls_arch0.h
new file mode 100644
index 0000000..054048a
--- /dev/null
+++ b/strace/linux/xtensa/ioctls_arch0.h
@@ -0,0 +1,69 @@
+/* Generated by ioctls_gen.sh from definitions found in $linux/arch/xtensa/include/ tree. */
+{ "asm/ioctls.h", "FIOASYNC", _IOC_WRITE, 0x667d, 0x04 },
+{ "asm/ioctls.h", "FIOCLEX", _IOC_NONE, 0x6601, 0x00 },
+{ "asm/ioctls.h", "FIONBIO", _IOC_WRITE, 0x667e, 0x04 },
+{ "asm/ioctls.h", "FIONCLEX", _IOC_NONE, 0x6602, 0x00 },
+{ "asm/ioctls.h", "FIONREAD", _IOC_READ, 0x667f, 0x04 },
+{ "asm/ioctls.h", "FIOQSIZE", _IOC_READ, 0x6680, 0x08 },
+{ "asm/ioctls.h", "TCFLSH", _IOC_NONE, 0x741f, 0x00 },
+{ "asm/ioctls.h", "TCGETS", 0, 0x5401, 0 },
+{ "asm/ioctls.h", "TCGETS2", _IOC_READ, 0x542a, 0x2c },
+{ "asm/ioctls.h", "TCSBRK", _IOC_NONE, 0x741d, 0x00 },
+{ "asm/ioctls.h", "TCSBRKP", _IOC_WRITE, 0x5425, 0x04 },
+{ "asm/ioctls.h", "TCSETS", 0, 0x5402, 0 },
+{ "asm/ioctls.h", "TCSETS2", _IOC_WRITE, 0x542b, 0x2c },
+{ "asm/ioctls.h", "TCSETSF", 0, 0x5404, 0 },
+{ "asm/ioctls.h", "TCSETSF2", _IOC_WRITE, 0x542d, 0x2c },
+{ "asm/ioctls.h", "TCSETSW", 0, 0x5403, 0 },
+{ "asm/ioctls.h", "TCSETSW2", _IOC_WRITE, 0x542c, 0x2c },
+{ "asm/ioctls.h", "TCXONC", _IOC_NONE, 0x741e, 0x00 },
+{ "asm/ioctls.h", "TIOCCBRK", _IOC_NONE, 0x5428, 0x00 },
+{ "asm/ioctls.h", "TIOCCONS", _IOC_NONE, 0x541d, 0x00 },
+{ "asm/ioctls.h", "TIOCEXCL", _IOC_NONE, 0x540c, 0x00 },
+{ "asm/ioctls.h", "TIOCGDEV", _IOC_READ, 0x5432, 0x04 },
+{ "asm/ioctls.h", "TIOCGETD", _IOC_READ, 0x5424, 0x04 },
+{ "asm/ioctls.h", "TIOCGEXCL", _IOC_READ, 0x5440, 0x04 },
+{ "asm/ioctls.h", "TIOCGICOUNT", 0, 0x545D, 0 },
+{ "asm/ioctls.h", "TIOCGLCKTRMIOS", 0, 0x5456, 0 },
+{ "asm/ioctls.h", "TIOCGPGRP", _IOC_READ, 0x7477, 0x04 },
+{ "asm/ioctls.h", "TIOCGPKT", _IOC_READ, 0x5438, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTLCK", _IOC_READ, 0x5439, 0x04 },
+{ "asm/ioctls.h", "TIOCGPTN", _IOC_READ, 0x5430, 0x04 },
+{ "asm/ioctls.h", "TIOCGRS485", _IOC_READ, 0x542e, 0x20 },
+{ "asm/ioctls.h", "TIOCGSID", _IOC_READ, 0x5429, 0x04 },
+{ "asm/ioctls.h", "TIOCGSOFTCAR", _IOC_READ, 0x5419, 0x04 },
+{ "asm/ioctls.h", "TIOCLINUX", _IOC_WRITE, 0x541c, 0x01 },
+{ "asm/ioctls.h", "TIOCMBIC", _IOC_WRITE, 0x5417, 0x04 },
+{ "asm/ioctls.h", "TIOCMBIS", _IOC_WRITE, 0x5416, 0x04 },
+{ "asm/ioctls.h", "TIOCMGET", _IOC_READ, 0x5415, 0x04 },
+{ "asm/ioctls.h", "TIOCMIWAIT", _IOC_NONE, 0x545c, 0x00 },
+{ "asm/ioctls.h", "TIOCMSET", _IOC_WRITE, 0x5418, 0x04 },
+{ "asm/ioctls.h", "TIOCNOTTY", _IOC_NONE, 0x5422, 0x00 },
+{ "asm/ioctls.h", "TIOCNXCL", _IOC_NONE, 0x540d, 0x00 },
+{ "asm/ioctls.h", "TIOCOUTQ", _IOC_READ, 0x7473, 0x04 },
+{ "asm/ioctls.h", "TIOCPKT", _IOC_WRITE, 0x5420, 0x04 },
+{ "asm/ioctls.h", "TIOCSBRK", _IOC_NONE, 0x5427, 0x00 },
+{ "asm/ioctls.h", "TIOCSCTTY", _IOC_NONE, 0x540e, 0x00 },
+{ "asm/ioctls.h", "TIOCSERCONFIG", _IOC_NONE, 0x5453, 0x00 },
+{ "asm/ioctls.h", "TIOCSERGETLSR", _IOC_READ, 0x5459, 0x04 },
+{ "asm/ioctls.h", "TIOCSERGSTRUCT", 0, 0x5458, 0 },
+{ "asm/ioctls.h", "TIOCSERGWILD", _IOC_READ, 0x5454, 0x04 },
+{ "asm/ioctls.h", "TIOCSERSWILD", _IOC_WRITE, 0x5455, 0x04 },
+{ "asm/ioctls.h", "TIOCSETD", _IOC_WRITE, 0x5423, 0x04 },
+{ "asm/ioctls.h", "TIOCSIG", _IOC_WRITE, 0x5436, 0x04 },
+{ "asm/ioctls.h", "TIOCSLCKTRMIOS", 0, 0x5457, 0 },
+{ "asm/ioctls.h", "TIOCSPGRP", _IOC_WRITE, 0x7476, 0x04 },
+{ "asm/ioctls.h", "TIOCSPTLCK", _IOC_WRITE, 0x5431, 0x04 },
+{ "asm/ioctls.h", "TIOCSRS485", _IOC_READ|_IOC_WRITE, 0x542f, 0x20 },
+{ "asm/ioctls.h", "TIOCSSOFTCAR", _IOC_WRITE, 0x541a, 0x04 },
+{ "asm/ioctls.h", "TIOCSTART", _IOC_NONE, 0x746e, 0x00 },
+{ "asm/ioctls.h", "TIOCSTI", _IOC_WRITE, 0x5412, 0x01 },
+{ "asm/ioctls.h", "TIOCSTOP", _IOC_NONE, 0x746f, 0x00 },
+{ "asm/ioctls.h", "TIOCVHANGUP", _IOC_NONE, 0x5437, 0x00 },
+{ "asm/sockios.h", "FIOGETOWN", _IOC_READ, 0x667b, 0x04 },
+{ "asm/sockios.h", "FIOSETOWN", _IOC_WRITE, 0x667c, 0x04 },
+{ "asm/sockios.h", "SIOCATMARK", _IOC_READ, 0x7307, 0x04 },
+{ "asm/sockios.h", "SIOCGPGRP", _IOC_READ, 0x7309, 0x04 },
+{ "asm/sockios.h", "SIOCGSTAMP", 0, 0x8906, 0 },
+{ "asm/sockios.h", "SIOCGSTAMPNS", 0, 0x8907, 0 },
+{ "asm/sockios.h", "SIOCSPGRP", _IOC_WRITE, 0x7308, 0x04 },
diff --git a/strace/linux/xtensa/ioctls_inc0.h b/strace/linux/xtensa/ioctls_inc0.h
new file mode 100644
index 0000000..4aecf98
--- /dev/null
+++ b/strace/linux/xtensa/ioctls_inc0.h
@@ -0,0 +1 @@
+#include "32/ioctls_inc.h"
diff --git a/strace/linux/xtensa/syscallent.h b/strace/linux/xtensa/syscallent.h
new file mode 100644
index 0000000..ffb7d43
--- /dev/null
+++ b/strace/linux/xtensa/syscallent.h
@@ -0,0 +1,332 @@
+[  0] = { 0,	0,		SEN(printargs),			"spill"			},
+[  1] = { 0,	0,		SEN(printargs),			"xtensa"		},
+[  2 ... 7] = { },
+[  8] = { 3,	TD|TF,		SEN(open),			"open"			},
+[  9] = { 1,	TD,		SEN(close),			"close"			},
+[ 10] = { 1,	TD,		SEN(dup),			"dup"			},
+[ 11] = { 2,	TD,		SEN(dup2),			"dup2"			},
+[ 12] = { 3,	TD,		SEN(read),			"read"			},
+[ 13] = { 3,	TD,		SEN(write),			"write"			},
+[ 14] = { 5,	TD,		SEN(select),			"select"		},
+[ 15] = { 3,	TD,		SEN(lseek),			"lseek"			},
+[ 16] = { 3,	TD,		SEN(poll),			"poll"			},
+[ 17] = { 5,	TD,		SEN(llseek),			"_llseek"		},
+[ 18] = { 4,	TD,		SEN(epoll_wait),		"epoll_wait"		},
+[ 19] = { 4,	TD,		SEN(epoll_ctl),			"epoll_ctl"		},
+[ 20] = { 1,	TD,		SEN(epoll_create),		"epoll_create"		},
+[ 21] = { 2,	TD|TF,		SEN(creat),			"creat"			},
+[ 22] = { 2,	TF,		SEN(truncate),			"truncate"		},
+[ 23] = { 2,	TD,		SEN(ftruncate),			"ftruncate"		},
+[ 24] = { 3,	TD,		SEN(readv),			"readv"			},
+[ 25] = { 3,	TD,		SEN(writev),			"writev"		},
+[ 26] = { 1,	TD,		SEN(fsync),			"fsync"			},
+[ 27] = { 1,	TD,		SEN(fdatasync),			"fdatasync"		},
+[ 28] = { 4,	TF,		SEN(truncate64),		"truncate64"		},
+[ 29] = { 4,	TD,		SEN(ftruncate64),		"ftruncate64"		},
+[ 30] = { 6,	TD,		SEN(pread),			"pread64"		},
+[ 31] = { 6,	TD,		SEN(pwrite),			"pwrite64"		},
+[ 32] = { 2,	TF,		SEN(link),			"link"			},
+[ 33] = { 2,	TF,		SEN(rename),			"rename"		},
+[ 34] = { 2,	TF,		SEN(symlink),			"symlink"		},
+[ 35] = { 3,	TF,		SEN(readlink),			"readlink"		},
+[ 36] = { 3,	TF,		SEN(mknod),			"mknod"			},
+[ 37] = { 1,	TD,		SEN(pipe),			"pipe"			},
+[ 38] = { 1,	TF,		SEN(unlink),			"unlink"		},
+[ 39] = { 1,	TF,		SEN(rmdir),			"rmdir"			},
+[ 40] = { 2,	TF,		SEN(mkdir),			"mkdir"			},
+[ 41] = { 1,	TF,		SEN(chdir),			"chdir"			},
+[ 42] = { 1,	TD,		SEN(fchdir),			"fchdir"		},
+[ 43] = { 2,	TF,		SEN(getcwd),			"getcwd"		},
+[ 44] = { 2,	TF,		SEN(chmod),			"chmod"			},
+[ 45] = { 3,	TF,		SEN(chown),			"chown"			},
+[ 46] = { 2,	TF,		SEN(stat),			"stat"			},
+[ 47] = { 2,	TF,		SEN(stat64),			"stat64"		},
+[ 48] = { 3,	TF,		SEN(chown),			"lchown"		},
+[ 49] = { 2,	TF,		SEN(lstat),			"lstat"			},
+[ 50] = { 2,	TF,		SEN(lstat64),			"lstat64"		},
+[ 51] = { },
+[ 52] = { 2,	TD,		SEN(fchmod),			"fchmod"		},
+[ 53] = { 3,	TD,		SEN(fchown),			"fchown"		},
+[ 54] = { 2,	TD,		SEN(fstat),			"fstat"			},
+[ 55] = { 2,	TD,		SEN(fstat64),			"fstat64"		},
+[ 56] = { 2,	TD,		SEN(flock),			"flock"			},
+[ 57] = { 2,	TF,		SEN(access),			"access"		},
+[ 58] = { 1,	NF,		SEN(umask),			"umask"			},
+[ 59] = { 3,	TD,		SEN(getdents),			"getdents"		},
+[ 60] = { 3,	TD,		SEN(getdents64),		"getdents64"		},
+[ 61] = { 3,	TD,		SEN(fcntl64),			"fcntl64"		},
+[ 62] = { 6,	TD,		SEN(fallocate),			"fallocate"		},
+[ 63] = { 6,	TD,		SEN(fadvise64_64),		"fadvise64_64"		},
+[ 64] = { 2,	TF,		SEN(utime),			"utime"			},
+[ 65] = { 2,	TF,		SEN(utimes),			"utimes"		},
+[ 66] = { 3,	TD,		SEN(ioctl),			"ioctl"			},
+[ 67] = { 3,	TD,		SEN(fcntl),			"fcntl"			},
+[ 68] = { 5,	TF,		SEN(setxattr),			"setxattr"		},
+[ 69] = { 4,	TF,		SEN(getxattr),			"getxattr"		},
+[ 70] = { 3,	TF,		SEN(listxattr),			"listxattr"		},
+[ 71] = { 2,	TF,		SEN(removexattr),		"removexattr"		},
+[ 72] = { 5,	TF,		SEN(setxattr),			"lsetxattr"		},
+[ 73] = { 4,	TF,		SEN(getxattr),			"lgetxattr"		},
+[ 74] = { 3,	TF,		SEN(listxattr),			"llistxattr"		},
+[ 75] = { 2,	TF,		SEN(removexattr),		"lremovexattr"		},
+[ 76] = { 5,	TD,		SEN(fsetxattr),			"fsetxattr"		},
+[ 77] = { 4,	TD,		SEN(fgetxattr),			"fgetxattr"		},
+[ 78] = { 3,	TD,		SEN(flistxattr),		"flistxattr"		},
+[ 79] = { 2,	TD,		SEN(fremovexattr),		"fremovexattr"		},
+[ 80] = { 6,	TD|TM|SI,	SEN(mmap_pgoff),		"mmap2"			},
+[ 81] = { 2,	TM|SI,		SEN(munmap),			"munmap"		},
+[ 82] = { 3,	TM|SI,		SEN(mprotect),			"mprotect"		},
+[ 83] = { 1,	TM|SI,		SEN(brk),			"brk"			},
+[ 84] = { 2,	TM,		SEN(mlock),			"mlock"			},
+[ 85] = { 2,	TM,		SEN(munlock),			"munlock"		},
+[ 86] = { 1,	TM,		SEN(mlockall),			"mlockall"		},
+[ 87] = { 0,	TM,		SEN(munlockall),		"munlockall"		},
+[ 88] = { 5,	TM|SI,		SEN(mremap),			"mremap"		},
+[ 89] = { 3,	TM,		SEN(msync),			"msync"			},
+[ 90] = { 3,	TM,		SEN(mincore),			"mincore"		},
+[ 91] = { 3,	TM,		SEN(madvise),			"madvise"		},
+[ 92] = { 3,	TI,		SEN(shmget),			"shmget"		},
+[ 93] = { 3,	TI|TM|SI,	SEN(shmat),			"shmat"			},
+[ 94] = { 3,	TI,		SEN(shmctl),			"shmctl"		},
+[ 95] = { 1,	TI|TM|SI,	SEN(shmdt),			"shmdt"			},
+[ 96] = { 3,	TN,		SEN(socket),			"socket"		},
+[ 97] = { 5,	TN,		SEN(setsockopt),		"setsockopt"		},
+[ 98] = { 5,	TN,		SEN(getsockopt),		"getsockopt"		},
+[ 99] = { 2,	TN,		SEN(shutdown),			"shutdown"		},
+[100] = { 3,	TN,		SEN(bind),			"bind"			},
+[101] = { 3,	TN,		SEN(connect),			"connect"		},
+[102] = { 2,	TN,		SEN(listen),			"listen"		},
+[103] = { 3,	TN,		SEN(accept),			"accept"		},
+[104] = { 3,	TN,		SEN(getsockname),		"getsockname"		},
+[105] = { 3,	TN,		SEN(getpeername),		"getpeername"		},
+[106] = { 3,	TN,		SEN(sendmsg),			"sendmsg"		},
+[107] = { 3,	TN,		SEN(recvmsg),			"recvmsg"		},
+[108] = { 4,	TN,		SEN(send),			"send"			},
+[109] = { 4,	TN,		SEN(recv),			"recv"			},
+[110] = { 6,	TN,		SEN(sendto),			"sendto"		},
+[111] = { 6,	TN,		SEN(recvfrom),			"recvfrom"		},
+[112] = { 4,	TN,		SEN(socketpair),		"socketpair"		},
+[113] = { 4,	TD|TN,		SEN(sendfile),			"sendfile"		},
+[114] = { 4,	TD|TN,		SEN(sendfile64),		"sendfile64"		},
+[115] = { 4,	TN,		SEN(sendmmsg),			"sendmmsg"		},
+[116] = { 5,	TP,		SEN(clone),			"clone"			},
+[117] = { 3,	TF|TP|SE|SI,	SEN(execve),			"execve"		},
+[118] = { 1,	TP|SE,		SEN(exit),			"exit"			},
+[119] = { 1,	TP|SE,		SEN(exit),			"exit_group"		},
+[120] = { 0,	NF,		SEN(getpid),			"getpid"		},
+[121] = { 4,	TP,		SEN(wait4),			"wait4"			},
+[122] = { 5,	TP,		SEN(waitid),			"waitid"		},
+[123] = { 2,	TS,		SEN(kill),			"kill"			},
+[124] = { 2,	TS,		SEN(kill),			"tkill"			},
+[125] = { 3,	TS,		SEN(tgkill),			"tgkill"		},
+[126] = { 1,	0,		SEN(set_tid_address),		"set_tid_address"	},
+[127] = { 0,	NF,		SEN(gettid),			"gettid"		},
+[128] = { 0,	0,		SEN(setsid),			"setsid"		},
+[129] = { 1,	0,		SEN(getsid),			"getsid"		},
+[130] = { 5,	0,		SEN(prctl),			"prctl"			},
+[131] = { 1,	NF,		SEN(personality),		"personality"		},
+[132] = { 2,	0,		SEN(getpriority),		"getpriority"		},
+[133] = { 3,	0,		SEN(setpriority),		"setpriority"		},
+[134] = { 3,	0,		SEN(setitimer),			"setitimer"		},
+[135] = { 2,	0,		SEN(getitimer),			"getitimer"		},
+[136] = { 1,	0,		SEN(setuid),			"setuid"		},
+[137] = { 0,	NF,		SEN(getuid),			"getuid"		},
+[138] = { 1,	0,		SEN(setgid),			"setgid"		},
+[139] = { 0,	NF,		SEN(getgid),			"getgid"		},
+[140] = { 0,	NF,		SEN(geteuid),			"geteuid"		},
+[141] = { 0,	NF,		SEN(getegid),			"getegid"		},
+[142] = { 2,	0,		SEN(setreuid),			"setreuid"		},
+[143] = { 2,	0,		SEN(setregid),			"setregid"		},
+[144] = { 3,	0,		SEN(setresuid),			"setresuid"		},
+[145] = { 3,	0,		SEN(getresuid),			"getresuid"		},
+[146] = { 3,	0,		SEN(setresgid),			"setresgid"		},
+[147] = { 3,	0,		SEN(getresgid),			"getresgid"		},
+[148] = { 2,	0,		SEN(setpgid),			"setpgid"		},
+[149] = { 1,	0,		SEN(getpgid),			"getpgid"		},
+[150] = { 0,	NF,		SEN(getppid),			"getppid"		},
+[151] = { 0,	0,		SEN(getpgrp),			"getpgrp"		},
+[152 ... 153] = { },
+[154] = { 1,	0,		SEN(times),			"times"			},
+[155] = { 1,	TF,		SEN(acct),			"acct"			},
+[156] = { 3,	0,		SEN(sched_setaffinity),		"sched_setaffinity"	},
+[157] = { 3,	0,		SEN(sched_getaffinity),		"sched_getaffinity"	},
+[158] = { 2,	0,		SEN(capget),			"capget"		},
+[159] = { 2,	0,		SEN(capset),			"capset"		},
+[160] = { 4,	0,		SEN(ptrace),			"ptrace"		},
+[161] = { 4,	TI,		SEN(semtimedop),		"semtimedop"		},
+[162] = { 3,	TI,		SEN(semget),			"semget"		},
+[163] = { 3,	TI,		SEN(semop),			"semop"			},
+[164] = { 4,	TI,		SEN(semctl),			"semctl"		},
+[165] = { },
+[166] = { 2,	TI,		SEN(msgget),			"msgget"		},
+[167] = { 4,	TI,		SEN(msgsnd),			"msgsnd"		},
+[168] = { 5,	TI,		SEN(msgrcv),			"msgrcv"		},
+[169] = { 3,	TI,		SEN(msgctl),			"msgctl"		},
+[170] = { },
+[171] = { 2,	TF,		SEN(umount2),			"umount2"		},
+[172] = { 5,	TF,		SEN(mount),			"mount"			},
+[173] = { 2,	TF,		SEN(swapon),			"swapon"		},
+[174] = { 1,	TF,		SEN(chroot),			"chroot"		},
+[175] = { 2,	TF,		SEN(pivotroot),			"pivot_root"		},
+[176] = { 1,	TF,		SEN(umount),			"umount"		},
+[177] = { 1,	TF,		SEN(swapoff),			"swapoff"		},
+[178] = { 0,	0,		SEN(sync),			"sync"			},
+[179] = { 1,	TD,		SEN(syncfs),			"syncfs"		},
+[180] = { 1,	NF,		SEN(setfsuid),			"setfsuid"		},
+[181] = { 1,	NF,		SEN(setfsgid),			"setfsgid"		},
+[182] = { 3,	0,		SEN(sysfs),			"sysfs"			},
+[183] = { 2,	0,		SEN(ustat),			"ustat"			},
+[184] = { 2,	TF,		SEN(statfs),			"statfs"		},
+[185] = { 2,	TD,		SEN(fstatfs),			"fstatfs"		},
+[186] = { 3,	TF,		SEN(statfs64),			"statfs64"		},
+[187] = { 3,	TD,		SEN(fstatfs64),			"fstatfs64"		},
+[188] = { 2,	0,		SEN(setrlimit),			"setrlimit"		},
+[189] = { 2,	0,		SEN(getrlimit),			"getrlimit"		},
+[190] = { 2,	0,		SEN(getrusage),			"getrusage"		},
+[191] = { 6,	0,		SEN(futex),			"futex"			},
+[192] = { 2,	0,		SEN(gettimeofday),		"gettimeofday"		},
+[193] = { 2,	0,		SEN(settimeofday),		"settimeofday"		},
+[194] = { 1,	0,		SEN(adjtimex),			"adjtimex"		},
+[195] = { 2,	0,		SEN(nanosleep),			"nanosleep"		},
+[196] = { 2,	0,		SEN(getgroups),			"getgroups"		},
+[197] = { 2,	0,		SEN(setgroups),			"setgroups"		},
+[198] = { 2,	0,		SEN(sethostname),		"sethostname"		},
+[199] = { 2,	0,		SEN(setdomainname),		"setdomainname"		},
+[200] = { 3,	0,		SEN(syslog),			"syslog"		},
+[201] = { 0,	0,		SEN(vhangup),			"vhangup"		},
+[202] = { 1,	TF,		SEN(uselib),			"uselib"		},
+[203] = { 4,	0,		SEN(reboot),			"reboot"		},
+[204] = { 4,	TF,		SEN(quotactl),			"quotactl"		},
+[205] = { 3,	0,		SEN(nfsservctl),		"nfsservctl"		},
+[206] = { 1,	0,		SEN(sysctl),			"_sysctl"		},
+[207] = { 2,	0,		SEN(bdflush),			"bdflush"		},
+[208] = { 1,	0,		SEN(uname),			"uname"			},
+[209] = { 1,	0,		SEN(sysinfo),			"sysinfo"		},
+[210] = { 3,	0,		SEN(init_module),		"init_module"		},
+[211] = { 2,	0,		SEN(delete_module),		"delete_module"		},
+[212] = { 2,	0,		SEN(sched_setparam),		"sched_setparam"	},
+[213] = { 2,	0,		SEN(sched_getparam),		"sched_getparam"	},
+[214] = { 3,	0,		SEN(sched_setscheduler),	"sched_setscheduler"	},
+[215] = { 1,	0,		SEN(sched_getscheduler),	"sched_getscheduler"	},
+[216] = { 1,	0,		SEN(sched_get_priority_max),	"sched_get_priority_max"},
+[217] = { 1,	0,		SEN(sched_get_priority_min),	"sched_get_priority_min"},
+[218] = { 2,	0,		SEN(sched_rr_get_interval),	"sched_rr_get_interval"	},
+[219] = { 0,	0,		SEN(sched_yield),		"sched_yield"		},
+[220 ... 222] = { },
+[223] = { 0,	0,		SEN(restart_syscall),		"restart_syscall"	},
+[224] = { 2,	TS,		SEN(sigaltstack),		"sigaltstack"		},
+[225] = { 0,	TS,		SEN(rt_sigreturn),		"rt_sigreturn"		},
+[226] = { 4,	TS,		SEN(rt_sigaction),		"rt_sigaction"		},
+[227] = { 4,	TS,		SEN(rt_sigprocmask),		"rt_sigprocmask"	},
+[228] = { 2,	TS,		SEN(rt_sigpending),		"rt_sigpending"		},
+[229] = { 4,	TS,		SEN(rt_sigtimedwait),		"rt_sigtimedwait"	},
+[230] = { 3,	TS,		SEN(rt_sigqueueinfo),		"rt_sigqueueinfo"	},
+[231] = { 2,	TS,		SEN(rt_sigsuspend),		"rt_sigsuspend"		},
+[232] = { 4,	0,		SEN(mq_open),			"mq_open"		},
+[233] = { 1,	0,		SEN(mq_unlink),			"mq_unlink"		},
+[234] = { 5,	0,		SEN(mq_timedsend),		"mq_timedsend"		},
+[235] = { 5,	0,		SEN(mq_timedreceive),		"mq_timedreceive"	},
+[236] = { 2,	0,		SEN(mq_notify),			"mq_notify"		},
+[237] = { 3,	0,		SEN(mq_getsetattr),		"mq_getsetattr"		},
+[238] = { },
+[239] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+[240] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+[241] = { 3,	0,		SEN(io_submit),			"io_submit"		},
+[242] = { 5,	0,		SEN(io_getevents),		"io_getevents"		},
+[243] = { 3,	0,		SEN(io_cancel),			"io_cancel"		},
+[244] = { 2,	0,		SEN(clock_settime),		"clock_settime"		},
+[245] = { 2,	0,		SEN(clock_gettime),		"clock_gettime"		},
+[246] = { 2,	0,		SEN(clock_getres),		"clock_getres"		},
+[247] = { 4,	0,		SEN(clock_nanosleep),		"clock_nanosleep"	},
+[248] = { 3,	0,		SEN(timer_create),		"timer_create"		},
+[249] = { 1,	0,		SEN(timer_delete),		"timer_delete"		},
+[250] = { 4,	0,		SEN(timer_settime),		"timer_settime"		},
+[251] = { 2,	0,		SEN(timer_gettime),		"timer_gettime"		},
+[252] = { 1,	0,		SEN(timer_getoverrun),		"timer_getoverrun"	},
+[253] = { },
+[254] = { 4,	0,		SEN(lookup_dcookie),		"lookup_dcookie"	},
+[255] = { },
+[256] = { 5,	0,		SEN(add_key),			"add_key"		},
+[257] = { 4,	0,		SEN(request_key),		"request_key"		},
+[258] = { 5,	0,		SEN(keyctl),			"keyctl"		},
+[259] = { },
+[260] = { 5,	TD,		SEN(readahead),			"readahead"		},
+[261] = { 5,	TM|SI,		SEN(remap_file_pages),		"remap_file_pages"	},
+[262] = { 4,	TM,		SEN(migrate_pages),		"migrate_pages"		},
+[263] = { 6,	TM,		SEN(mbind),			"mbind"			},
+[264] = { 5,	TM,		SEN(get_mempolicy),		"get_mempolicy"		},
+[265] = { 3,	TM,		SEN(set_mempolicy),		"set_mempolicy"		},
+[266] = { 1,	TP,		SEN(unshare),			"unshare"		},
+[267] = { 6,	TM,		SEN(move_pages),		"move_pages"		},
+[268] = { 6,	TD,		SEN(splice),			"splice"		},
+[269] = { 4,	TD,		SEN(tee),			"tee"			},
+[270] = { 4,	TD,		SEN(vmsplice),			"vmsplice"		},
+[271] = { },
+[272] = { 6,	TD,		SEN(pselect6),			"pselect6"		},
+[273] = { 5,	TD,		SEN(ppoll),			"ppoll"			},
+[274] = { 6,	TD,		SEN(epoll_pwait),		"epoll_pwait"		},
+[275] = { 1,	TD,		SEN(epoll_create1),		"epoll_create1"		},
+[276] = { 0,	TD,		SEN(inotify_init),		"inotify_init"		},
+[277] = { 3,	TD,		SEN(inotify_add_watch),		"inotify_add_watch"	},
+[278] = { 2,	TD,		SEN(inotify_rm_watch),		"inotify_rm_watch"	},
+[279] = { 1,	TD,		SEN(inotify_init1),		"inotify_init1"		},
+[280] = { 3,	0,		SEN(getcpu),			"getcpu"		},
+[281] = { 4,	0,		SEN(kexec_load),		"kexec_load"		},
+[282] = { 3,	0,		SEN(ioprio_set),		"ioprio_set"		},
+[283] = { 2,	0,		SEN(ioprio_get),		"ioprio_get"		},
+[284] = { 2,	0,		SEN(set_robust_list),		"set_robust_list"	},
+[285] = { 3,	0,		SEN(get_robust_list),		"get_robust_list"	},
+[286 ... 287] = { },
+[288] = { 4,	TD|TF,		SEN(openat),			"openat"		},
+[289] = { 3,	TD|TF,		SEN(mkdirat),			"mkdirat"		},
+[290] = { 4,	TD|TF,		SEN(mknodat),			"mknodat"		},
+[291] = { 3,	TD|TF,		SEN(unlinkat),			"unlinkat"		},
+[292] = { 4,	TD|TF,		SEN(renameat),			"renameat"		},
+[293] = { 5,	TD|TF,		SEN(linkat),			"linkat"		},
+[294] = { 3,	TD|TF,		SEN(symlinkat),			"symlinkat"		},
+[295] = { 4,	TD|TF,		SEN(readlinkat),		"readlinkat"		},
+[296] = { 4,	TD|TF,		SEN(utimensat),			"utimensat"		},
+[297] = { 5,	TD|TF,		SEN(fchownat),			"fchownat"		},
+[298] = { 3,	TD|TF,		SEN(futimesat),			"futimesat"		},
+[299] = { 4,	TD|TF,		SEN(newfstatat),		"fstatat64"		},
+[300] = { 3,	TD|TF,		SEN(fchmodat),			"fchmodat"		},
+[301] = { 3,	TD|TF,		SEN(faccessat),			"faccessat"		},
+[302 ... 303] = { },
+[304] = { 3,	TD|TS,		SEN(signalfd),			"signalfd"		},
+[305] = { },
+[306] = { 1,	TD,		SEN(eventfd),			"eventfd"		},
+[307] = { 5,	TN,		SEN(recvmmsg),			"recvmmsg"		},
+[308] = { 2,	TD,		SEN(setns),			"setns"			},
+[309] = { 4,	TD|TS,		SEN(signalfd4),			"signalfd4"		},
+[310] = { 3,	TD,		SEN(dup3),			"dup3"			},
+[311] = { 2,	TD,		SEN(pipe2),			"pipe2"			},
+[312] = { 2,	TD,		SEN(timerfd_create),		"timerfd_create"	},
+[313] = { 4,	TD,		SEN(timerfd_settime),		"timerfd_settime"	},
+[314] = { 2,	TD,		SEN(timerfd_gettime),		"timerfd_gettime"	},
+[315] = { },
+[316] = { 2,	TD,		SEN(eventfd2),			"eventfd2"		},
+[317] = { 5,	TD,		SEN(preadv),			"preadv"		},
+[318] = { 5,	TD,		SEN(pwritev),			"pwritev"		},
+[319] = { },
+[320] = { 2,	TD,		SEN(fanotify_init),		"fanotify_init"		},
+[321] = { 6,	TD|TF,		SEN(fanotify_mark),		"fanotify_mark"		},
+[322] = { 6,	0,		SEN(process_vm_readv),		"process_vm_readv"	},
+[323] = { 6,	0,		SEN(process_vm_writev),		"process_vm_writev"	},
+[324] = { 5,	TD|TF,		SEN(name_to_handle_at),		"name_to_handle_at"	},
+[325] = { 3,	TD,		SEN(open_by_handle_at),		"open_by_handle_at"	},
+[326] = { 6,	TD,		SEN(sync_file_range2),		"sync_file_range2"	},
+[327] = { 5,	TD,		SEN(perf_event_open),		"perf_event_open"	},
+[328] = { 4,	TP|TS,		SEN(rt_tgsigqueueinfo),		"rt_tgsigqueueinfo"	},
+[329] = { 2,	0,		SEN(clock_adjtime),		"clock_adjtime"		},
+[330] = { 4,	0,		SEN(prlimit64),			"prlimit64"		},
+[331] = { 5,	0,		SEN(kcmp),			"kcmp"			},
+[332] = { 3,	TD,		SEN(finit_module),		"finit_module"		},
+[333] = { 4,	TN,		SEN(accept4),			"accept4"		},
+[334] = { 3,	0,		SEN(sched_setattr),		"sched_setattr"		},
+[335] = { 4,	0,		SEN(sched_getattr),		"sched_getattr"		},
+[336] = { 5,	TD|TF,		SEN(renameat2),			"renameat2"		},
+[337] = { 3,	0,		SEN(seccomp),			"seccomp",		},
+[338] = { 3,	0,		SEN(getrandom),			"getrandom",		},
+[339] = { 2,	TD,		SEN(memfd_create),		"memfd_create",		},
+[340] = { 3,	TD,		SEN(bpf),			"bpf",			},
+[341] = { 5,	TD|TF|TP|SE|SI,	SEN(execveat),			"execveat",		},
diff --git a/strace/linux/xtensa/userent.h b/strace/linux/xtensa/userent.h
new file mode 100644
index 0000000..0bee717
--- /dev/null
+++ b/strace/linux/xtensa/userent.h
@@ -0,0 +1,89 @@
+{ REG_A_BASE,		"a0" },
+{ REG_A_BASE+1,		"a1" },
+{ REG_A_BASE+2,		"a2" },
+{ REG_A_BASE+3,		"a3" },
+{ REG_A_BASE+4,		"a4" },
+{ REG_A_BASE+5,		"a5" },
+{ REG_A_BASE+6,		"a6" },
+{ REG_A_BASE+7,		"a7" },
+{ REG_A_BASE+8,		"a8" },
+{ REG_A_BASE+9,		"a9" },
+{ REG_A_BASE+10,	"a10" },
+{ REG_A_BASE+11,	"a11" },
+{ REG_A_BASE+12,	"a12" },
+{ REG_A_BASE+13,	"a13" },
+{ REG_A_BASE+14,	"a14" },
+{ REG_A_BASE+15,	"a15" },
+{ REG_PC,		"pc" },
+{ SYSCALL_NR,		"syscall_nr" },
+{ REG_AR_BASE,		"ar0" },
+{ REG_AR_BASE+1,	"ar1" },
+{ REG_AR_BASE+2,	"ar2" },
+{ REG_AR_BASE+3,	"ar3" },
+{ REG_AR_BASE+4,	"ar4" },
+{ REG_AR_BASE+5,	"ar5" },
+{ REG_AR_BASE+6,	"ar6" },
+{ REG_AR_BASE+7,	"ar7" },
+{ REG_AR_BASE+8,	"ar8" },
+{ REG_AR_BASE+9,	"ar9" },
+{ REG_AR_BASE+10,	"ar10" },
+{ REG_AR_BASE+11,	"ar11" },
+{ REG_AR_BASE+12,	"ar12" },
+{ REG_AR_BASE+13,	"ar13" },
+{ REG_AR_BASE+14,	"ar14" },
+{ REG_AR_BASE+15,	"ar15" },
+{ REG_AR_BASE+16,	"ar16" },
+{ REG_AR_BASE+17,	"ar17" },
+{ REG_AR_BASE+18,	"ar18" },
+{ REG_AR_BASE+19,	"ar19" },
+{ REG_AR_BASE+20,	"ar20" },
+{ REG_AR_BASE+21,	"ar21" },
+{ REG_AR_BASE+22,	"ar22" },
+{ REG_AR_BASE+23,	"ar23" },
+{ REG_AR_BASE+24,	"ar24" },
+{ REG_AR_BASE+25,	"ar25" },
+{ REG_AR_BASE+26,	"ar26" },
+{ REG_AR_BASE+27,	"ar27" },
+{ REG_AR_BASE+28,	"ar28" },
+{ REG_AR_BASE+29,	"ar29" },
+{ REG_AR_BASE+30,	"ar30" },
+{ REG_AR_BASE+31,	"ar31" },
+{ REG_AR_BASE+32,	"ar32" },
+{ REG_AR_BASE+33,	"ar33" },
+{ REG_AR_BASE+34,	"ar34" },
+{ REG_AR_BASE+35,	"ar35" },
+{ REG_AR_BASE+36,	"ar36" },
+{ REG_AR_BASE+37,	"ar37" },
+{ REG_AR_BASE+38,	"ar38" },
+{ REG_AR_BASE+39,	"ar39" },
+{ REG_AR_BASE+40,	"ar40" },
+{ REG_AR_BASE+41,	"ar41" },
+{ REG_AR_BASE+42,	"ar42" },
+{ REG_AR_BASE+43,	"ar43" },
+{ REG_AR_BASE+44,	"ar44" },
+{ REG_AR_BASE+45,	"ar45" },
+{ REG_AR_BASE+46,	"ar46" },
+{ REG_AR_BASE+47,	"ar47" },
+{ REG_AR_BASE+48,	"ar48" },
+{ REG_AR_BASE+49,	"ar49" },
+{ REG_AR_BASE+50,	"ar50" },
+{ REG_AR_BASE+51,	"ar51" },
+{ REG_AR_BASE+52,	"ar52" },
+{ REG_AR_BASE+53,	"ar53" },
+{ REG_AR_BASE+54,	"ar54" },
+{ REG_AR_BASE+55,	"ar55" },
+{ REG_AR_BASE+56,	"ar56" },
+{ REG_AR_BASE+57,	"ar57" },
+{ REG_AR_BASE+58,	"ar58" },
+{ REG_AR_BASE+59,	"ar59" },
+{ REG_AR_BASE+60,	"ar60" },
+{ REG_AR_BASE+61,	"ar61" },
+{ REG_AR_BASE+62,	"ar62" },
+{ REG_AR_BASE+63,	"ar63" },
+{ REG_LBEG,		"lbeg" },
+{ REG_LEND,		"lend" },
+{ REG_LCOUNT,		"lcount" },
+{ REG_SAR,		"sar" },
+{ REG_WB,		"wb" },
+{ REG_WS,		"ws" },
+{ REG_PS,		"ps" },
diff --git a/strace/lookup_dcookie.c b/strace/lookup_dcookie.c
new file mode 100644
index 0000000..c95e593
--- /dev/null
+++ b/strace/lookup_dcookie.c
@@ -0,0 +1,49 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+SYS_FUNC(lookup_dcookie)
+{
+	if (entering(tcp))
+		return 0;
+
+	/* cookie */
+	int argn = printllval(tcp, "%llu", 0);
+	tprints(", ");
+
+	/* buffer */
+	if (syserror(tcp))
+		printaddr(tcp->u_arg[argn]);
+	else
+		printstr(tcp, tcp->u_arg[argn], tcp->u_rval);
+
+	/* len */
+	tprintf(", %lu", tcp->u_arg[argn + 1]);
+
+	return 0;
+}
diff --git a/strace/loop.c b/strace/loop.c
new file mode 100644
index 0000000..2de33c5
--- /dev/null
+++ b/strace/loop.c
@@ -0,0 +1,201 @@
+/*
+ * Copyright (c) 2012 The Chromium OS Authors.
+ * Written by Mike Frysinger <vapier@gentoo.org>.
+ *
+ * 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 <linux/ioctl.h>
+#include <linux/loop.h>
+
+#include "xlat/loop_flags_options.h"
+#include "xlat/loop_crypt_type_options.h"
+
+static void
+decode_loop_info(struct tcb *tcp, const long addr)
+{
+	struct loop_info info;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &info))
+		return;
+
+	tprintf("{lo_number=%d", info.lo_number);
+
+	if (!abbrev(tcp)) {
+		tprintf(", lo_device=%#lx, lo_inode=%lu, lo_rdevice=%#lx",
+			(unsigned long) info.lo_device,
+			info.lo_inode,
+			(unsigned long) info.lo_rdevice);
+	}
+
+	tprintf(", lo_offset=%#x", info.lo_offset);
+
+	if (!abbrev(tcp) || info.lo_encrypt_type != LO_CRYPT_NONE) {
+		tprints(", lo_encrypt_type=");
+		printxval(loop_crypt_type_options, info.lo_encrypt_type,
+			"LO_CRYPT_???");
+		tprintf(", lo_encrypt_key_size=%d", info.lo_encrypt_key_size);
+	}
+
+	tprints(", lo_flags=");
+	printflags(loop_flags_options, info.lo_flags, "LO_FLAGS_???");
+
+	tprints(", lo_name=");
+	print_quoted_string(info.lo_name, LO_NAME_SIZE,
+			    QUOTE_0_TERMINATED);
+
+	if (!abbrev(tcp) || info.lo_encrypt_type != LO_CRYPT_NONE) {
+		tprints(", lo_encrypt_key=");
+		print_quoted_string((void *) info.lo_encrypt_key,
+				    LO_KEY_SIZE, 0);
+	}
+
+	if (!abbrev(tcp))
+		tprintf(", lo_init=[%#lx, %#lx]"
+			", reserved=[%#x, %#x, %#x, %#x]}",
+			info.lo_init[0], info.lo_init[1],
+			info.reserved[0], info.reserved[1],
+			info.reserved[2], info.reserved[3]);
+	else
+		tprints(", ...}");
+}
+
+static void
+decode_loop_info64(struct tcb *tcp, const long addr)
+{
+	struct loop_info64 info64;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &info64))
+		return;
+
+	if (!abbrev(tcp)) {
+		tprintf("{lo_device=%" PRIu64 ", lo_inode=%" PRIu64
+			", lo_rdevice=%" PRIu64 ", lo_offset=%#" PRIx64
+			", lo_sizelimit=%" PRIu64 ", lo_number=%" PRIu32,
+			(uint64_t) info64.lo_device,
+			(uint64_t) info64.lo_inode,
+			(uint64_t) info64.lo_rdevice,
+			(uint64_t) info64.lo_offset,
+			(uint64_t) info64.lo_sizelimit,
+			(uint32_t) info64.lo_number);
+	} else {
+		tprintf("{lo_offset=%#" PRIx64 ", lo_number=%" PRIu32,
+			(uint64_t) info64.lo_offset,
+			(uint32_t) info64.lo_number);
+	}
+
+	if (!abbrev(tcp) || info64.lo_encrypt_type != LO_CRYPT_NONE) {
+		tprints(", lo_encrypt_type=");
+		printxval(loop_crypt_type_options, info64.lo_encrypt_type,
+			"LO_CRYPT_???");
+		tprintf(", lo_encrypt_key_size=%" PRIu32,
+			info64.lo_encrypt_key_size);
+	}
+
+	tprints(", lo_flags=");
+	printflags(loop_flags_options, info64.lo_flags, "LO_FLAGS_???");
+
+	tprints(", lo_file_name=");
+	print_quoted_string((void *) info64.lo_file_name,
+			    LO_NAME_SIZE, QUOTE_0_TERMINATED);
+
+	if (!abbrev(tcp) || info64.lo_encrypt_type != LO_CRYPT_NONE) {
+		tprints(", lo_crypt_name=");
+		print_quoted_string((void *) info64.lo_crypt_name,
+				    LO_NAME_SIZE, QUOTE_0_TERMINATED);
+		tprints(", lo_encrypt_key=");
+		print_quoted_string((void *) info64.lo_encrypt_key,
+				    LO_KEY_SIZE, 0);
+	}
+
+	if (!abbrev(tcp))
+		tprintf(", lo_init=[%#" PRIx64 ", %#" PRIx64 "]}",
+			(uint64_t) info64.lo_init[0],
+			(uint64_t) info64.lo_init[1]);
+	else
+		tprints(", ...}");
+}
+
+int
+loop_ioctl(struct tcb *tcp, const unsigned int code, long arg)
+{
+	if (!verbose(tcp))
+		return RVAL_DECODED;
+
+	switch (code) {
+	case LOOP_GET_STATUS:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case LOOP_SET_STATUS:
+		decode_loop_info(tcp, arg);
+		break;
+
+	case LOOP_GET_STATUS64:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case LOOP_SET_STATUS64:
+		decode_loop_info64(tcp, arg);
+		break;
+
+	case LOOP_CLR_FD:
+#ifdef LOOP_SET_CAPACITY
+	case LOOP_SET_CAPACITY:
+#endif
+#ifdef LOOP_CTL_GET_FREE
+	/* newer loop-control stuff */
+	case LOOP_CTL_GET_FREE:
+#endif
+		/* Takes no arguments */
+		break;
+
+	case LOOP_SET_FD:
+	case LOOP_CHANGE_FD:
+		tprints(", ");
+		printfd(tcp, arg);
+		break;
+
+#ifdef LOOP_CTL_ADD
+	/* newer loop-control stuff */
+	case LOOP_CTL_ADD:
+	case LOOP_CTL_REMOVE:
+		tprintf(", %d", (int) arg);
+		break;
+#endif
+
+#ifdef LOOP_SET_DIRECT_IO
+	case LOOP_SET_DIRECT_IO:
+		tprintf(", %lu", arg);
+		break;
+#endif
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/lseek.c b/strace/lseek.c
new file mode 100644
index 0000000..8d05dc1
--- /dev/null
+++ b/strace/lseek.c
@@ -0,0 +1,121 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2002-2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2009 Andreas Schwab <schwab@redhat.com>
+ * Copyright (c) 2012 H.J. Lu <hongjiu.lu@intel.com>
+ * Copyright (c) 2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/whence_codes.h"
+
+/* Linux kernel has exactly one version of lseek:
+ * fs/read_write.c::SYSCALL_DEFINE3(lseek, unsigned, fd, off_t, offset, unsigned, origin)
+ * In kernel, off_t is always the same as (kernel's) long
+ * (see include/uapi/asm-generic/posix_types.h),
+ * which means that on x32 we need to use tcp->ext_arg[N] to get offset argument.
+ * Use test/x32_lseek.c to test lseek decoding.
+ */
+#if HAVE_STRUCT_TCB_EXT_ARG
+SYS_FUNC(lseek)
+{
+	printfd(tcp, tcp->u_arg[0]);
+
+	long long offset;
+# if SUPPORTED_PERSONALITIES > 1
+	/* tcp->ext_arg is not initialized for compat personality */
+	if (current_personality == 1) {
+		offset = tcp->u_arg[1];
+	} else
+# endif
+	{
+		offset = tcp->ext_arg[1];
+	}
+	int whence = tcp->u_arg[2];
+
+	tprintf(", %lld, ", offset);
+	printxval(whence_codes, whence, "SEEK_???");
+
+	return RVAL_DECODED | RVAL_LUDECIMAL;
+}
+#else
+SYS_FUNC(lseek)
+{
+	printfd(tcp, tcp->u_arg[0]);
+
+	long offset =
+# if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+#  ifdef X86_64
+		current_personality == 1 ?
+			(long)(int) tcp->u_arg[1] : tcp->u_arg[1];
+#  else
+		current_wordsize == 4 ?
+			(long)(int) tcp->u_arg[1] : tcp->u_arg[1];
+#  endif
+# else
+		tcp->u_arg[1];
+# endif
+	int whence = tcp->u_arg[2];
+
+	tprintf(", %ld, ", offset);
+	printxval(whence_codes, whence, "SEEK_???");
+
+	return RVAL_DECODED | RVAL_UDECIMAL;
+}
+#endif
+
+/* llseek syscall takes explicitly two ulong arguments hi, lo,
+ * rather than one 64-bit argument for which LONG_LONG works
+ * appropriate for the native byte order.
+ *
+ * See kernel's fs/read_write.c::SYSCALL_DEFINE5(llseek, ...)
+ *
+ * hi,lo are "unsigned longs" and combined exactly this way in kernel:
+ * ((loff_t) hi << 32) | lo
+ * Note that for architectures with kernel's long wider than userspace long
+ * (such as x32), combining code will use *kernel's*, i.e. *wide* longs
+ * for hi and lo. We would need to use tcp->ext_arg[N] on x32...
+ * ...however, x32 (and x86_64) does not _have_ llseek syscall as such.
+ */
+SYS_FUNC(llseek)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprintf(", %lld, ",
+			(widen_to_ull(tcp->u_arg[1]) << 32)
+			| widen_to_ull(tcp->u_arg[2]));
+	} else {
+		printnum_int64(tcp, tcp->u_arg[3], "%" PRIu64);
+		tprints(", ");
+		printxval(whence_codes, tcp->u_arg[4], "SEEK_???");
+	}
+	return 0;
+}
diff --git a/strace/m32_funcs.h b/strace/m32_funcs.h
new file mode 100644
index 0000000..f4b8672
--- /dev/null
+++ b/strace/m32_funcs.h
@@ -0,0 +1,19 @@
+#undef sys_readdir
+#define sys_readdir m32_sys_readdir
+#undef sys_getdents
+#define sys_getdents m32_sys_getdents
+#undef sys_msgctl
+#define sys_msgctl m32_sys_msgctl
+#undef sys_shmctl
+#define sys_shmctl m32_sys_shmctl
+#undef sys_time
+#define sys_time m32_sys_time
+#undef sys_sigaltstack
+#define sys_sigaltstack m32_sys_sigaltstack
+#undef sys_sysinfo
+#define sys_sysinfo m32_sys_sysinfo
+#undef sys_times
+#define sys_times m32_sys_times
+#undef sys_utime
+#define sys_utime m32_sys_utime
+#include "sys_func.h"
diff --git a/strace/m32_printer_decls.h b/strace/m32_printer_decls.h
new file mode 100644
index 0000000..c1b4177
--- /dev/null
+++ b/strace/m32_printer_decls.h
@@ -0,0 +1,31 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+extern int m32_block_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int m32_btrfs_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int m32_evdev_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern _Bool m32_fetch_seccomp_fprog(struct tcb *tcp, const long addr, void *p);
+extern _Bool m32_fetch_struct_flock(struct tcb *tcp, const long addr, void *p);
+extern _Bool m32_fetch_struct_flock64(struct tcb *tcp, const long addr, void *p);
+extern int m32_fetch_struct_mmsghdr(struct tcb *tcp, const unsigned long addr, void *p);
+extern unsigned int m32_sizeof_struct_mmsghdr(void);
+extern int m32_fetch_struct_msghdr(struct tcb *tcp, const unsigned long addr, void *p);
+extern _Bool m32_fetch_struct_statfs(struct tcb *tcp, const long addr, struct strace_statfs *p);
+extern _Bool m32_fetch_struct_statfs64(struct tcb *tcp, const long addr, const unsigned long size, struct strace_statfs *p);
+extern int m32_hdio_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int m32_mtd_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern void m32_printmqattr(struct tcb *tcp, const long addr);
+extern void m32_tprint_msgbuf(struct tcb *tcp, const long addr, const unsigned long count);
+extern void m32_print_sigevent(struct tcb *tcp, const long addr);
+extern void m32_print_timespec(struct tcb *tcp, const long addr);
+extern const char * m32_sprint_timespec(struct tcb *tcp, const long addr);
+extern void m32_print_timespec_utime_pair(struct tcb *tcp, const long addr);
+extern void m32_print_itimerspec(struct tcb *tcp, const long addr);
+extern void m32_print_timeval(struct tcb *tcp, const long addr);
+extern void m32_print_timeval_pair(struct tcb *tcp, const long addr);
+extern const char * m32_sprint_timeval(struct tcb *tcp, const long addr);
+extern void m32_print_itimerval(struct tcb *tcp, const long addr);
+extern int m32_print_timex(struct tcb *tcp, const long addr);
+extern void m32_printrusage(struct tcb *tcp, long addr);
+extern void m32_printsiginfo_at(struct tcb *tcp, long addr);
+extern void m32_print_siginfo_array(struct tcb *tcp, unsigned long addr, unsigned long len);
+extern int m32_rtc_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int m32_v4l2_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
diff --git a/strace/m32_printer_defs.h b/strace/m32_printer_defs.h
new file mode 100644
index 0000000..2ca15f4
--- /dev/null
+++ b/strace/m32_printer_defs.h
@@ -0,0 +1,31 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+.block_ioctl = m32_block_ioctl,
+.btrfs_ioctl = m32_btrfs_ioctl,
+.evdev_ioctl = m32_evdev_ioctl,
+.fetch_seccomp_fprog = m32_fetch_seccomp_fprog,
+.fetch_struct_flock = m32_fetch_struct_flock,
+.fetch_struct_flock64 = m32_fetch_struct_flock64,
+.fetch_struct_mmsghdr = m32_fetch_struct_mmsghdr,
+.sizeof_struct_mmsghdr = m32_sizeof_struct_mmsghdr,
+.fetch_struct_msghdr = m32_fetch_struct_msghdr,
+.fetch_struct_statfs = m32_fetch_struct_statfs,
+.fetch_struct_statfs64 = m32_fetch_struct_statfs64,
+.hdio_ioctl = m32_hdio_ioctl,
+.mtd_ioctl = m32_mtd_ioctl,
+.printmqattr = m32_printmqattr,
+.tprint_msgbuf = m32_tprint_msgbuf,
+.print_sigevent = m32_print_sigevent,
+.print_timespec = m32_print_timespec,
+.sprint_timespec = m32_sprint_timespec,
+.print_timespec_utime_pair = m32_print_timespec_utime_pair,
+.print_itimerspec = m32_print_itimerspec,
+.print_timeval = m32_print_timeval,
+.print_timeval_pair = m32_print_timeval_pair,
+.sprint_timeval = m32_sprint_timeval,
+.print_itimerval = m32_print_itimerval,
+.print_timex = m32_print_timex,
+.printrusage = m32_printrusage,
+.printsiginfo_at = m32_printsiginfo_at,
+.print_siginfo_array = m32_print_siginfo_array,
+.rtc_ioctl = m32_rtc_ioctl,
+.v4l2_ioctl = m32_v4l2_ioctl,
diff --git a/strace/m32_type_defs.h b/strace/m32_type_defs.h
new file mode 100644
index 0000000..0d7b17e
--- /dev/null
+++ b/strace/m32_type_defs.h
@@ -0,0 +1,127 @@
+#ifdef MPERS_m32_struct_blk_user_trace_setup
+# define struct_blk_user_trace_setup MPERS_m32_struct_blk_user_trace_setup
+#endif
+#ifdef MPERS_m32_struct_blkpg_ioctl_arg
+# define struct_blkpg_ioctl_arg MPERS_m32_struct_blkpg_ioctl_arg
+#endif
+#ifdef MPERS_m32_struct_blkpg_partition
+# define struct_blkpg_partition MPERS_m32_struct_blkpg_partition
+#endif
+#ifdef MPERS_m32_struct_btrfs_ioctl_dev_replace_args
+# define struct_btrfs_ioctl_dev_replace_args MPERS_m32_struct_btrfs_ioctl_dev_replace_args
+#endif
+#ifdef MPERS_m32_struct_btrfs_ioctl_send_args
+# define struct_btrfs_ioctl_send_args MPERS_m32_struct_btrfs_ioctl_send_args
+#endif
+#ifdef MPERS_m32_struct_btrfs_ioctl_received_subvol_args
+# define struct_btrfs_ioctl_received_subvol_args MPERS_m32_struct_btrfs_ioctl_received_subvol_args
+#endif
+#ifdef MPERS_m32_kernel_dirent
+# define kernel_dirent MPERS_m32_kernel_dirent
+#endif
+#ifdef MPERS_m32_struct_ff_effect
+# define struct_ff_effect MPERS_m32_struct_ff_effect
+#endif
+#ifdef MPERS_m32_seccomp_fprog_t
+# define seccomp_fprog_t MPERS_m32_seccomp_fprog_t
+#endif
+#ifdef MPERS_m32_struct_flock
+# define struct_flock MPERS_m32_struct_flock
+#endif
+#ifdef MPERS_m32_struct_flock64
+# define struct_flock64 MPERS_m32_struct_flock64
+#endif
+#ifdef MPERS_m32_struct_mmsghdr
+# define struct_mmsghdr MPERS_m32_struct_mmsghdr
+#endif
+#ifdef MPERS_m32_struct_msghdr
+# define struct_msghdr MPERS_m32_struct_msghdr
+#endif
+#ifdef MPERS_m32_struct_statfs
+# define struct_statfs MPERS_m32_struct_statfs
+#endif
+#ifdef MPERS_m32_struct_statfs64
+# define struct_statfs64 MPERS_m32_struct_statfs64
+#endif
+#ifdef MPERS_m32_struct_hd_geometry
+# define struct_hd_geometry MPERS_m32_struct_hd_geometry
+#endif
+#ifdef MPERS_m32_msqid_ds_t
+# define msqid_ds_t MPERS_m32_msqid_ds_t
+#endif
+#ifdef MPERS_m32_shmid_ds_t
+# define shmid_ds_t MPERS_m32_shmid_ds_t
+#endif
+#ifdef MPERS_m32_struct_mtd_oob_buf
+# define struct_mtd_oob_buf MPERS_m32_struct_mtd_oob_buf
+#endif
+#ifdef MPERS_m32_mq_attr_t
+# define mq_attr_t MPERS_m32_mq_attr_t
+#endif
+#ifdef MPERS_m32_msgbuf_t
+# define msgbuf_t MPERS_m32_msgbuf_t
+#endif
+#ifdef MPERS_m32_struct_sigevent
+# define struct_sigevent MPERS_m32_struct_sigevent
+#endif
+#ifdef MPERS_m32_time_t
+# define time_t MPERS_m32_time_t
+#endif
+#ifdef MPERS_m32_timespec_t
+# define timespec_t MPERS_m32_timespec_t
+#endif
+#ifdef MPERS_m32_timeval_t
+# define timeval_t MPERS_m32_timeval_t
+#endif
+#ifdef MPERS_m32_struct_timex
+# define struct_timex MPERS_m32_struct_timex
+#endif
+#ifdef MPERS_m32_rusage_t
+# define rusage_t MPERS_m32_rusage_t
+#endif
+#ifdef MPERS_m32_siginfo_t
+# define siginfo_t MPERS_m32_siginfo_t
+#endif
+#ifdef MPERS_m32_struct_rtc_pll_info
+# define struct_rtc_pll_info MPERS_m32_struct_rtc_pll_info
+#endif
+#ifdef MPERS_m32_stack_t
+# define stack_t MPERS_m32_stack_t
+#endif
+#ifdef MPERS_m32_sysinfo_t
+# define sysinfo_t MPERS_m32_sysinfo_t
+#endif
+#ifdef MPERS_m32_tms_t
+# define tms_t MPERS_m32_tms_t
+#endif
+#ifdef MPERS_m32_utimbuf_t
+# define utimbuf_t MPERS_m32_utimbuf_t
+#endif
+#ifdef MPERS_m32_struct_v4l2_buffer
+# define struct_v4l2_buffer MPERS_m32_struct_v4l2_buffer
+#endif
+#ifdef MPERS_m32_struct_v4l2_create_buffers
+# define struct_v4l2_create_buffers MPERS_m32_struct_v4l2_create_buffers
+#endif
+#ifdef MPERS_m32_struct_v4l2_ext_control
+# define struct_v4l2_ext_control MPERS_m32_struct_v4l2_ext_control
+#endif
+#ifdef MPERS_m32_struct_v4l2_ext_controls
+# define struct_v4l2_ext_controls MPERS_m32_struct_v4l2_ext_controls
+#endif
+#ifdef MPERS_m32_struct_v4l2_format
+# define struct_v4l2_format MPERS_m32_struct_v4l2_format
+#endif
+#ifdef MPERS_m32_struct_v4l2_framebuffer
+# define struct_v4l2_framebuffer MPERS_m32_struct_v4l2_framebuffer
+#endif
+#ifdef MPERS_m32_struct_v4l2_input
+# define struct_v4l2_input MPERS_m32_struct_v4l2_input
+#endif
+#ifdef MPERS_m32_struct_v4l2_standard
+# define struct_v4l2_standard MPERS_m32_struct_v4l2_standard
+#endif
+#undef MPERS_PRINTER_NAME
+#define MPERS_PRINTER_NAME(printer_name) printer_name
+#include "m32_printer_decls.h"
+#include MPERS_m32_IOCTL_MACROS
diff --git a/strace/m4/ax_code_coverage.m4 b/strace/m4/ax_code_coverage.m4
new file mode 100644
index 0000000..93dfce3
--- /dev/null
+++ b/strace/m4/ax_code_coverage.m4
@@ -0,0 +1,274 @@
+# ===========================================================================
+#     http://www.gnu.org/software/autoconf-archive/ax_code_coverage.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+#   AX_CODE_COVERAGE()
+#
+# DESCRIPTION
+#
+#   Defines CODE_COVERAGE_CPPFLAGS, CODE_COVERAGE_CFLAGS,
+#   CODE_COVERAGE_CXXFLAGS and CODE_COVERAGE_LDFLAGS which should be
+#   included in the CPPFLAGS, CFLAGS CXXFLAGS and LIBS/LDFLAGS variables of
+#   every build target (program or library) which should be built with code
+#   coverage support. Also defines CODE_COVERAGE_RULES which should be
+#   substituted in your Makefile; and $enable_code_coverage which can be
+#   used in subsequent configure output. CODE_COVERAGE_ENABLED is defined
+#   and substituted, and corresponds to the value of the
+#   --enable-code-coverage option, which defaults to being disabled.
+#
+#   Test also for gcov program and create GCOV variable that could be
+#   substituted.
+#
+#   Note that all optimisation flags in CFLAGS must be disabled when code
+#   coverage is enabled.
+#
+#   Usage example:
+#
+#   configure.ac:
+#
+#     AX_CODE_COVERAGE
+#
+#   Makefile.am:
+#
+#     @CODE_COVERAGE_RULES@
+#     my_program_LIBS = ... $(CODE_COVERAGE_LDFLAGS) ...
+#     my_program_CPPFLAGS = ... $(CODE_COVERAGE_CPPFLAGS) ...
+#     my_program_CFLAGS = ... $(CODE_COVERAGE_CFLAGS) ...
+#     my_program_CXXFLAGS = ... $(CODE_COVERAGE_CXXFLAGS) ...
+#
+#   This results in a "check-code-coverage" rule being added to any
+#   Makefile.am which includes "@CODE_COVERAGE_RULES@" (assuming the module
+#   has been configured with --enable-code-coverage). Running `make
+#   check-code-coverage` in that directory will run the module's test suite
+#   (`make check`) and build a code coverage report detailing the code which
+#   was touched, then print the URI for the report.
+#
+#   This code was derived from Makefile.decl in GLib, originally licenced
+#   under LGPLv2.1+.
+#
+# LICENSE
+#
+#   Copyright (c) 2012, 2016 Philip Withnall
+#   Copyright (c) 2012 Xan Lopez
+#   Copyright (c) 2012 Christian Persch
+#   Copyright (c) 2012 Paolo Borelli
+#   Copyright (c) 2012 Dan Winship
+#   Copyright (c) 2015 Bastien ROUCARIES
+#
+#   This library is free software; you can redistribute it and/or modify it
+#   under the terms of the GNU Lesser General Public License as published by
+#   the Free Software Foundation; either version 2.1 of the License, or (at
+#   your option) any later version.
+#
+#   This library is distributed in the hope that it will be useful, but
+#   WITHOUT ANY WARRANTY; without even the implied warranty of
+#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser
+#   General Public License for more details.
+#
+#   You should have received a copy of the GNU Lesser General Public License
+#   along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+#serial 16
+
+AC_DEFUN([AX_CODE_COVERAGE],[
+	dnl Check for --enable-code-coverage
+	AC_REQUIRE([AC_PROG_SED])
+
+	# allow to override gcov location
+	AC_ARG_WITH([gcov],
+	  [AS_HELP_STRING([--with-gcov[=GCOV]], [use given GCOV for coverage (GCOV=gcov).])],
+	  [_AX_CODE_COVERAGE_GCOV_PROG_WITH=$with_gcov],
+	  [_AX_CODE_COVERAGE_GCOV_PROG_WITH=gcov])
+
+	AC_MSG_CHECKING([whether to build with code coverage support])
+	AC_ARG_ENABLE([code-coverage],
+	  AS_HELP_STRING([--enable-code-coverage],
+	  [Whether to enable code coverage support]),,
+	  enable_code_coverage=no)
+
+	AM_CONDITIONAL([CODE_COVERAGE_ENABLED], [test x$enable_code_coverage = xyes])
+	AC_SUBST([CODE_COVERAGE_ENABLED], [$enable_code_coverage])
+	AC_MSG_RESULT($enable_code_coverage)
+
+	AS_IF([ test "$enable_code_coverage" = "yes" ], [
+		# check for gcov
+		AC_CHECK_TOOL([GCOV],
+		  [$_AX_CODE_COVERAGE_GCOV_PROG_WITH],
+		  [:])
+		AS_IF([test "X$GCOV" = "X:"],
+		  [AC_MSG_ERROR([gcov is needed to do coverage])])
+		AC_SUBST([GCOV])
+
+		dnl Check if gcc is being used
+		AS_IF([ test "$GCC" = "no" ], [
+			AC_MSG_ERROR([not compiling with gcc, which is required for gcov code coverage])
+		])
+
+		# List of supported lcov versions.
+		lcov_version_list="1.6 1.7 1.8 1.9 1.10 1.11 1.12"
+
+		AC_CHECK_PROG([LCOV], [lcov], [lcov])
+		AC_CHECK_PROG([GENHTML], [genhtml], [genhtml])
+
+		AS_IF([ test "$LCOV" ], [
+			AC_CACHE_CHECK([for lcov version], ax_cv_lcov_version, [
+				ax_cv_lcov_version=invalid
+				lcov_version=`$LCOV -v 2>/dev/null | $SED -e 's/^.* //'`
+				for lcov_check_version in $lcov_version_list; do
+					if test "$lcov_version" = "$lcov_check_version"; then
+						ax_cv_lcov_version="$lcov_check_version (ok)"
+					fi
+				done
+			])
+		], [
+			lcov_msg="To enable code coverage reporting you must have one of the following lcov versions installed: $lcov_version_list"
+			AC_MSG_ERROR([$lcov_msg])
+		])
+
+		case $ax_cv_lcov_version in
+			""|invalid[)]
+				lcov_msg="You must have one of the following versions of lcov: $lcov_version_list (found: $lcov_version)."
+				AC_MSG_ERROR([$lcov_msg])
+				LCOV="exit 0;"
+			;;
+		esac
+
+		AS_IF([ test -z "$GENHTML" ], [
+			AC_MSG_ERROR([Could not find genhtml from the lcov package])
+		])
+
+		dnl Build the code coverage flags
+		CODE_COVERAGE_CPPFLAGS="-DNDEBUG"
+		CODE_COVERAGE_CFLAGS="-O0 -g -fprofile-arcs -ftest-coverage"
+		CODE_COVERAGE_CXXFLAGS="-O0 -g -fprofile-arcs -ftest-coverage"
+		CODE_COVERAGE_LDFLAGS="-lgcov"
+
+		AC_SUBST([CODE_COVERAGE_CPPFLAGS])
+		AC_SUBST([CODE_COVERAGE_CFLAGS])
+		AC_SUBST([CODE_COVERAGE_CXXFLAGS])
+		AC_SUBST([CODE_COVERAGE_LDFLAGS])
+	])
+
+[CODE_COVERAGE_RULES='
+# Code coverage
+#
+# Optional:
+#  - CODE_COVERAGE_DIRECTORY: Top-level directory for code coverage reporting.
+#    Multiple directories may be specified, separated by whitespace.
+#    (Default: $(top_builddir))
+#  - CODE_COVERAGE_OUTPUT_FILE: Filename and path for the .info file generated
+#    by lcov for code coverage. (Default:
+#    $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage.info)
+#  - CODE_COVERAGE_OUTPUT_DIRECTORY: Directory for generated code coverage
+#    reports to be created. (Default:
+#    $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage)
+#  - CODE_COVERAGE_BRANCH_COVERAGE: Set to 1 to enforce branch coverage,
+#    set to 0 to disable it and leave empty to stay with the default.
+#    (Default: empty)
+#  - CODE_COVERAGE_LCOV_SHOPTS_DEFAULT: Extra options shared between both lcov
+#    instances. (Default: based on $CODE_COVERAGE_BRANCH_COVERAGE)
+#  - CODE_COVERAGE_LCOV_SHOPTS: Extra options to shared between both lcov
+#    instances. (Default: $CODE_COVERAGE_LCOV_SHOPTS_DEFAULT)
+#  - CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH: --gcov-tool pathtogcov
+#  - CODE_COVERAGE_LCOV_OPTIONS_DEFAULT: Extra options to pass to the
+#    collecting lcov instance. (Default: $CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH)
+#  - CODE_COVERAGE_LCOV_OPTIONS: Extra options to pass to the collecting lcov
+#    instance. (Default: $CODE_COVERAGE_LCOV_OPTIONS_DEFAULT)
+#  - CODE_COVERAGE_LCOV_RMOPTS_DEFAULT: Extra options to pass to the filtering
+#    lcov instance. (Default: empty)
+#  - CODE_COVERAGE_LCOV_RMOPTS: Extra options to pass to the filtering lcov
+#    instance. (Default: $CODE_COVERAGE_LCOV_RMOPTS_DEFAULT)
+#  - CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT: Extra options to pass to the
+#    genhtml instance. (Default: based on $CODE_COVERAGE_BRANCH_COVERAGE)
+#  - CODE_COVERAGE_GENHTML_OPTIONS: Extra options to pass to the genhtml
+#    instance. (Default: $CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT)
+#  - CODE_COVERAGE_IGNORE_PATTERN: Extra glob pattern of files to ignore
+#
+# The generated report will be titled using the $(PACKAGE_NAME) and
+# $(PACKAGE_VERSION). In order to add the current git hash to the title,
+# use the git-version-gen script, available online.
+
+# Optional variables
+CODE_COVERAGE_DIRECTORY ?= $(top_builddir)
+CODE_COVERAGE_OUTPUT_FILE ?= $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage.info
+CODE_COVERAGE_OUTPUT_DIRECTORY ?= $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage
+CODE_COVERAGE_BRANCH_COVERAGE ?=
+CODE_COVERAGE_LCOV_SHOPTS_DEFAULT ?= $(if $(CODE_COVERAGE_BRANCH_COVERAGE),\
+--rc lcov_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE))
+CODE_COVERAGE_LCOV_SHOPTS ?= $(CODE_COVERAGE_LCOV_SHOPTS_DEFAULT)
+CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH ?= --gcov-tool "$(GCOV)"
+CODE_COVERAGE_LCOV_OPTIONS_DEFAULT ?= $(CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH)
+CODE_COVERAGE_LCOV_OPTIONS ?= $(CODE_COVERAGE_LCOV_OPTIONS_DEFAULT)
+CODE_COVERAGE_LCOV_RMOPTS_DEFAULT ?=
+CODE_COVERAGE_LCOV_RMOPTS ?= $(CODE_COVERAGE_LCOV_RMOPTS_DEFAULT)
+CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT ?=\
+$(if $(CODE_COVERAGE_BRANCH_COVERAGE),\
+--rc genhtml_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE))
+CODE_COVERAGE_GENHTML_OPTIONS ?= $(CODE_COVERAGE_GENHTML_OPTIONS_DEFAULTS)
+CODE_COVERAGE_IGNORE_PATTERN ?=
+
+code_coverage_v_lcov_cap = $(code_coverage_v_lcov_cap_$(V))
+code_coverage_v_lcov_cap_ = $(code_coverage_v_lcov_cap_$(AM_DEFAULT_VERBOSITY))
+code_coverage_v_lcov_cap_0 = @echo "  LCOV   --capture"\
+ $(CODE_COVERAGE_OUTPUT_FILE);
+code_coverage_v_lcov_ign = $(code_coverage_v_lcov_ign_$(V))
+code_coverage_v_lcov_ign_ = $(code_coverage_v_lcov_ign_$(AM_DEFAULT_VERBOSITY))
+code_coverage_v_lcov_ign_0 = @echo "  LCOV   --remove /tmp/*"\
+ $(CODE_COVERAGE_IGNORE_PATTERN);
+code_coverage_v_genhtml = $(code_coverage_v_genhtml_$(V))
+code_coverage_v_genhtml_ = $(code_coverage_v_genhtml_$(AM_DEFAULT_VERBOSITY))
+code_coverage_v_genhtml_0 = @echo "  GEN   " $(CODE_COVERAGE_OUTPUT_DIRECTORY);
+code_coverage_quiet = $(code_coverage_quiet_$(V))
+code_coverage_quiet_ = $(code_coverage_quiet_$(AM_DEFAULT_VERBOSITY))
+code_coverage_quiet_0 = --quiet
+
+# sanitizes the test-name: replaces with underscores: dashes and dots
+code_coverage_sanitize = $(subst -,_,$(subst .,_,$(1)))
+
+# Use recursive makes in order to ignore errors during check
+check-code-coverage:
+ifeq ($(CODE_COVERAGE_ENABLED),yes)
+	-$(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) -k check
+	$(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) code-coverage-capture
+else
+	@echo "Need to reconfigure with --enable-code-coverage"
+endif
+
+# Capture code coverage data
+code-coverage-capture: code-coverage-capture-hook
+ifeq ($(CODE_COVERAGE_ENABLED),yes)
+	$(code_coverage_v_lcov_cap)$(LCOV) $(code_coverage_quiet) $(addprefix --directory ,$(CODE_COVERAGE_DIRECTORY)) --capture --output-file "$(CODE_COVERAGE_OUTPUT_FILE).tmp" --test-name "$(call code_coverage_sanitize,$(PACKAGE_NAME)-$(PACKAGE_VERSION))" --no-checksum --compat-libtool $(CODE_COVERAGE_LCOV_SHOPTS) $(CODE_COVERAGE_LCOV_OPTIONS)
+	$(code_coverage_v_lcov_ign)$(LCOV) $(code_coverage_quiet) $(addprefix --directory ,$(CODE_COVERAGE_DIRECTORY)) --remove "$(CODE_COVERAGE_OUTPUT_FILE).tmp" "/tmp/*" $(CODE_COVERAGE_IGNORE_PATTERN) --output-file "$(CODE_COVERAGE_OUTPUT_FILE)" $(CODE_COVERAGE_LCOV_SHOPTS) $(CODE_COVERAGE_LCOV_RMOPTS)
+	-@rm -f $(CODE_COVERAGE_OUTPUT_FILE).tmp
+	$(code_coverage_v_genhtml)LANG=C $(GENHTML) $(code_coverage_quiet) $(addprefix --prefix ,$(CODE_COVERAGE_DIRECTORY)) --output-directory "$(CODE_COVERAGE_OUTPUT_DIRECTORY)" --title "$(PACKAGE_NAME)-$(PACKAGE_VERSION) Code Coverage" --legend --show-details "$(CODE_COVERAGE_OUTPUT_FILE)" $(CODE_COVERAGE_GENHTML_OPTIONS)
+	@echo "file://$(abs_builddir)/$(CODE_COVERAGE_OUTPUT_DIRECTORY)/index.html"
+else
+	@echo "Need to reconfigure with --enable-code-coverage"
+endif
+
+# Hook rule executed before code-coverage-capture, overridable by the user
+code-coverage-capture-hook:
+
+ifeq ($(CODE_COVERAGE_ENABLED),yes)
+clean: code-coverage-clean
+distclean: code-coverage-clean
+code-coverage-clean:
+	-$(LCOV) --directory $(top_builddir) -z
+	-rm -rf $(CODE_COVERAGE_OUTPUT_FILE) $(CODE_COVERAGE_OUTPUT_FILE).tmp $(CODE_COVERAGE_OUTPUT_DIRECTORY)
+	-find . \( -name "*.gcda" -o -name "*.gcno" -o -name "*.gcov" \) -delete
+endif
+
+GITIGNOREFILES ?=
+GITIGNOREFILES += $(CODE_COVERAGE_OUTPUT_FILE) $(CODE_COVERAGE_OUTPUT_DIRECTORY)
+
+A''M_DISTCHECK_CONFIGURE_FLAGS ?=
+A''M_DISTCHECK_CONFIGURE_FLAGS += --disable-code-coverage
+
+.PHONY: check-code-coverage code-coverage-capture code-coverage-capture-hook code-coverage-clean
+']
+
+	AC_SUBST([CODE_COVERAGE_RULES])
+	m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([CODE_COVERAGE_RULES])])
+])
diff --git a/strace/m4/ax_prog_cc_for_build.m4 b/strace/m4/ax_prog_cc_for_build.m4
new file mode 100644
index 0000000..77fd346
--- /dev/null
+++ b/strace/m4/ax_prog_cc_for_build.m4
@@ -0,0 +1,125 @@
+# ===========================================================================
+#   http://www.gnu.org/software/autoconf-archive/ax_prog_cc_for_build.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+#   AX_PROG_CC_FOR_BUILD
+#
+# DESCRIPTION
+#
+#   This macro searches for a C compiler that generates native executables,
+#   that is a C compiler that surely is not a cross-compiler. This can be
+#   useful if you have to generate source code at compile-time like for
+#   example GCC does.
+#
+#   The macro sets the CC_FOR_BUILD and CPP_FOR_BUILD macros to anything
+#   needed to compile or link (CC_FOR_BUILD) and preprocess (CPP_FOR_BUILD).
+#   The value of these variables can be overridden by the user by specifying
+#   a compiler with an environment variable (like you do for standard CC).
+#
+#   It also sets BUILD_EXEEXT and BUILD_OBJEXT to the executable and object
+#   file extensions for the build platform, and GCC_FOR_BUILD to `yes' if
+#   the compiler we found is GCC. All these variables but GCC_FOR_BUILD are
+#   substituted in the Makefile.
+#
+# LICENSE
+#
+#   Copyright (c) 2008 Paolo Bonzini <bonzini@gnu.org>
+#
+#   Copying and distribution of this file, with or without modification, are
+#   permitted in any medium without royalty provided the copyright notice
+#   and this notice are preserved. This file is offered as-is, without any
+#   warranty.
+
+#serial 8
+
+AU_ALIAS([AC_PROG_CC_FOR_BUILD], [AX_PROG_CC_FOR_BUILD])
+AC_DEFUN([AX_PROG_CC_FOR_BUILD], [dnl
+AC_REQUIRE([AC_PROG_CC])dnl
+AC_REQUIRE([AC_PROG_CPP])dnl
+AC_REQUIRE([AC_EXEEXT])dnl
+AC_REQUIRE([AC_CANONICAL_HOST])dnl
+
+dnl Use the standard macros, but make them use other variable names
+dnl
+pushdef([ac_cv_prog_CPP], ac_cv_build_prog_CPP)dnl
+pushdef([ac_cv_prog_gcc], ac_cv_build_prog_gcc)dnl
+pushdef([ac_cv_prog_cc_works], ac_cv_build_prog_cc_works)dnl
+pushdef([ac_cv_prog_cc_cross], ac_cv_build_prog_cc_cross)dnl
+pushdef([ac_cv_prog_cc_g], ac_cv_build_prog_cc_g)dnl
+pushdef([ac_cv_exeext], ac_cv_build_exeext)dnl
+pushdef([ac_cv_objext], ac_cv_build_objext)dnl
+pushdef([ac_exeext], ac_build_exeext)dnl
+pushdef([ac_objext], ac_build_objext)dnl
+pushdef([CC], CC_FOR_BUILD)dnl
+pushdef([CPP], CPP_FOR_BUILD)dnl
+pushdef([CFLAGS], CFLAGS_FOR_BUILD)dnl
+pushdef([CPPFLAGS], CPPFLAGS_FOR_BUILD)dnl
+pushdef([LDFLAGS], LDFLAGS_FOR_BUILD)dnl
+pushdef([host], build)dnl
+pushdef([host_alias], build_alias)dnl
+pushdef([host_cpu], build_cpu)dnl
+pushdef([host_vendor], build_vendor)dnl
+pushdef([host_os], build_os)dnl
+pushdef([ac_cv_host], ac_cv_build)dnl
+pushdef([ac_cv_host_alias], ac_cv_build_alias)dnl
+pushdef([ac_cv_host_cpu], ac_cv_build_cpu)dnl
+pushdef([ac_cv_host_vendor], ac_cv_build_vendor)dnl
+pushdef([ac_cv_host_os], ac_cv_build_os)dnl
+pushdef([ac_cpp], ac_build_cpp)dnl
+pushdef([ac_compile], ac_build_compile)dnl
+pushdef([ac_link], ac_build_link)dnl
+
+save_cross_compiling=$cross_compiling
+save_ac_tool_prefix=$ac_tool_prefix
+cross_compiling=no
+ac_tool_prefix=
+
+AC_PROG_CC
+AC_PROG_CPP
+AC_EXEEXT
+
+ac_tool_prefix=$save_ac_tool_prefix
+cross_compiling=$save_cross_compiling
+
+dnl Restore the old definitions
+dnl
+popdef([ac_link])dnl
+popdef([ac_compile])dnl
+popdef([ac_cpp])dnl
+popdef([ac_cv_host_os])dnl
+popdef([ac_cv_host_vendor])dnl
+popdef([ac_cv_host_cpu])dnl
+popdef([ac_cv_host_alias])dnl
+popdef([ac_cv_host])dnl
+popdef([host_os])dnl
+popdef([host_vendor])dnl
+popdef([host_cpu])dnl
+popdef([host_alias])dnl
+popdef([host])dnl
+popdef([LDFLAGS])dnl
+popdef([CPPFLAGS])dnl
+popdef([CFLAGS])dnl
+popdef([CPP])dnl
+popdef([CC])dnl
+popdef([ac_objext])dnl
+popdef([ac_exeext])dnl
+popdef([ac_cv_objext])dnl
+popdef([ac_cv_exeext])dnl
+popdef([ac_cv_prog_cc_g])dnl
+popdef([ac_cv_prog_cc_cross])dnl
+popdef([ac_cv_prog_cc_works])dnl
+popdef([ac_cv_prog_gcc])dnl
+popdef([ac_cv_prog_CPP])dnl
+
+dnl Finally, set Makefile variables
+dnl
+BUILD_EXEEXT=$ac_build_exeext
+BUILD_OBJEXT=$ac_build_objext
+AC_SUBST(BUILD_EXEEXT)dnl
+AC_SUBST(BUILD_OBJEXT)dnl
+AC_SUBST([CFLAGS_FOR_BUILD])dnl
+AC_SUBST([CPPFLAGS_FOR_BUILD])dnl
+AC_SUBST([LDFLAGS_FOR_BUILD])dnl
+])
diff --git a/strace/m4/mpers.m4 b/strace/m4/mpers.m4
new file mode 100644
index 0000000..1fe8a8e
--- /dev/null
+++ b/strace/m4/mpers.m4
@@ -0,0 +1,98 @@
+#!/usr/bin/m4
+#
+# Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+# Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+# 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.
+
+AC_DEFUN([st_MPERS],[
+
+pushdef([MPERS_NAME], translit([$1], [a-z], [A-Z]))
+pushdef([HAVE_MPERS], [HAVE_]MPERS_NAME[_MPERS])
+pushdef([HAVE_RUNTIME], [HAVE_]MPERS_NAME[_RUNTIME])
+pushdef([CFLAG], [-$1])
+pushdef([st_cv_cc], [st_cv_$1_cc])
+pushdef([st_cv_runtime], [st_cv_$1_runtime])
+pushdef([st_cv_mpers], [st_cv_$1_mpers])
+
+case "$arch" in
+	[$2])
+	AH_TEMPLATE([HAVE_GNU_STUBS_32_H],
+		    [Define to 1 if you have the <gnu/stubs-32.h> header file.])
+	AH_TEMPLATE([HAVE_GNU_STUBS_X32_H],
+		    [Define to 1 if you have the <gnu/stubs-x32.h> header file.])
+	pushdef([gnu_stubs], [gnu/stubs-][m4_substr([$1], 1)][.h])
+	AC_CHECK_HEADERS([gnu_stubs], [IFLAG=],
+			 [mkdir -p gnu
+			  : > gnu_stubs
+			  AC_MSG_NOTICE([Created empty gnu_stubs])
+			  IFLAG=-I.])
+	popdef([gnu_stubs])
+	saved_CFLAGS="$CFLAGS"
+	CFLAGS="$CFLAGS CFLAG $IFLAG"
+	AC_CACHE_CHECK([for CFLAG compile support], [st_cv_cc],
+		[AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#include <stdint.h>
+						     int main(){return 0;}]])],
+				   [st_cv_cc=yes],
+				   [st_cv_cc=no])])
+	if test $st_cv_cc = yes; then
+		AC_CACHE_CHECK([for CFLAG runtime support], [st_cv_runtime],
+			[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdint.h>
+							 int main(){return 0;}]])],
+				       [st_cv_runtime=yes],
+				       [st_cv_runtime=no],
+				       [st_cv_runtime=no])])
+		AC_CACHE_CHECK([whether mpers.sh CFLAG works], [st_cv_mpers],
+			[if CC="$CC" CPP="$CPP" CPPFLAGS="$CPPFLAGS" \
+			    $srcdir/mpers_test.sh [$1]; then
+				st_cv_mpers=yes
+			 else
+				st_cv_mpers=no
+			 fi])
+		if test $st_cv_mpers = yes; then
+			AC_DEFINE(HAVE_MPERS, [1],
+				  [Define to 1 if you have CFLAG mpers support])
+		fi
+	fi
+	CFLAGS="$saved_CFLAGS"
+	;;
+
+	*)
+	st_cv_runtime=no
+	st_cv_mpers=no
+	;;
+esac
+
+AM_CONDITIONAL(HAVE_RUNTIME, [test "$st_cv_runtime" = yes])
+AM_CONDITIONAL(HAVE_MPERS, [test "$st_cv_mpers" = yes])
+
+popdef([st_cv_mpers])
+popdef([st_cv_runtime])
+popdef([st_cv_cc])
+popdef([CFLAG])
+popdef([HAVE_RUNTIME])
+popdef([HAVE_MPERS])
+popdef([MPERS_NAME])
+
+])
diff --git a/strace/m4/warnings.m4 b/strace/m4/warnings.m4
new file mode 100644
index 0000000..e3d239b
--- /dev/null
+++ b/strace/m4/warnings.m4
@@ -0,0 +1,79 @@
+# warnings.m4 serial 11
+dnl Copyright (C) 2008-2013 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+
+dnl From Simon Josefsson
+
+# gl_AS_VAR_APPEND(VAR, VALUE)
+# ----------------------------
+# Provide the functionality of AS_VAR_APPEND if Autoconf does not have it.
+m4_ifdef([AS_VAR_APPEND],
+[m4_copy([AS_VAR_APPEND], [gl_AS_VAR_APPEND])],
+[m4_define([gl_AS_VAR_APPEND],
+[AS_VAR_SET([$1], [AS_VAR_GET([$1])$2])])])
+
+
+# gl_COMPILER_OPTION_IF(OPTION, [IF-SUPPORTED], [IF-NOT-SUPPORTED],
+#                       [PROGRAM = AC_LANG_PROGRAM()])
+# -----------------------------------------------------------------
+# Check if the compiler supports OPTION when compiling PROGRAM.
+#
+# FIXME: gl_Warn must be used unquoted until we can assume Autoconf
+# 2.64 or newer.
+AC_DEFUN([gl_COMPILER_OPTION_IF],
+[AS_VAR_PUSHDEF([gl_Warn], [gl_cv_warn_[]_AC_LANG_ABBREV[]_$1])dnl
+AS_VAR_PUSHDEF([gl_Flags], [_AC_LANG_PREFIX[]FLAGS])dnl
+AS_LITERAL_IF([$1],
+  [m4_pushdef([gl_Positive], m4_bpatsubst([$1], [^-Wno-], [-W]))],
+  [gl_positive="$1"
+case $gl_positive in
+  -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;;
+esac
+m4_pushdef([gl_Positive], [$gl_positive])])dnl
+AC_CACHE_CHECK([whether _AC_LANG compiler handles $1], m4_defn([gl_Warn]), [
+  gl_save_compiler_FLAGS="$gl_Flags"
+  gl_AS_VAR_APPEND(m4_defn([gl_Flags]),
+    [" $gl_unknown_warnings_are_errors ]m4_defn([gl_Positive])["])
+  AC_LINK_IFELSE([m4_default([$4], [AC_LANG_PROGRAM([])])],
+                 [AS_VAR_SET(gl_Warn, [yes])],
+                 [AS_VAR_SET(gl_Warn, [no])])
+  gl_Flags="$gl_save_compiler_FLAGS"
+])
+AS_VAR_IF(gl_Warn, [yes], [$2], [$3])
+m4_popdef([gl_Positive])dnl
+AS_VAR_POPDEF([gl_Flags])dnl
+AS_VAR_POPDEF([gl_Warn])dnl
+])
+
+# gl_UNKNOWN_WARNINGS_ARE_ERRORS
+# ------------------------------
+# Clang doesn't complain about unknown warning options unless one also
+# specifies -Wunknown-warning-option -Werror.  Detect this.
+AC_DEFUN([gl_UNKNOWN_WARNINGS_ARE_ERRORS],
+[gl_COMPILER_OPTION_IF([-Werror -Wunknown-warning-option],
+   [gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'],
+   [gl_unknown_warnings_are_errors=])])
+
+# gl_WARN_ADD(OPTION, [VARIABLE = WARN_CFLAGS],
+#             [PROGRAM = AC_LANG_PROGRAM()])
+# ---------------------------------------------
+# Adds parameter to WARN_CFLAGS if the compiler supports it when
+# compiling PROGRAM.  For example, gl_WARN_ADD([-Wparentheses]).
+#
+# If VARIABLE is a variable name, AC_SUBST it.
+AC_DEFUN([gl_WARN_ADD],
+[AC_REQUIRE([gl_UNKNOWN_WARNINGS_ARE_ERRORS])
+gl_COMPILER_OPTION_IF([$1],
+  [gl_AS_VAR_APPEND(m4_if([$2], [], [[WARN_CFLAGS]], [[$2]]), [" $1"])],
+  [],
+  [$3])
+m4_ifval([$2],
+         [AS_LITERAL_IF([$2], [AC_SUBST([$2])])],
+         [AC_SUBST([WARN_CFLAGS])])dnl
+])
+
+# Local Variables:
+# mode: autoconf
+# End:
diff --git a/strace/maint/ioctls_gen.sh b/strace/maint/ioctls_gen.sh
new file mode 100755
index 0000000..90d7c1f
--- /dev/null
+++ b/strace/maint/ioctls_gen.sh
@@ -0,0 +1,114 @@
+#!/bin/sh
+# Copyright (c) 2004-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+set -efu
+
+me="${0##*/}"
+mydir="${0%/*}"
+msg()
+{
+	printf >&2 '%s\n' "$me: $*"
+}
+
+case $# in
+	1)
+		inc_dir="$1"
+		arch_dir=
+		;;
+	2)
+		inc_dir="$1"
+		arch_dir="$2"
+		;;
+	*)
+	        echo >&2 "usage: $me include-directory [arch-include-directory]"
+	        exit 1
+		;;
+esac
+
+# Check and canonicalize include-directory and arch-include-directory.
+abs_inc_dir="$(cd "$inc_dir" && pwd -P)"
+[ -z "$arch_dir" ] ||
+	abs_arch_dir="$(cd "$arch_dir" && pwd -P)"
+
+cleanup()
+{
+	trap - EXIT
+	rm -f ioctls_hex.h ioctls_sym.h
+	exit "$@"
+}
+trap 'cleanup $?' EXIT
+trap 'cleanup 1' HUP PIPE INT QUIT TERM
+
+# Fetch ioctl commands defined in hex form.
+{
+	"$mydir"/ioctls_hex.sh "$inc_dir" 03 linux/hdreg.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 22 scsi/sg.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 46 linux/fb.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 4B linux/kd.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 4C linux/loop.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 53 linux/cdrom.h scsi/scsi.h scsi/scsi_ioctl.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" '\(46\|54\|66\|74\)' asm/ioctls.h asm-generic/ioctls.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 56 linux/vt.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" '7[12]' linux/videotext.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 89 asm/sockios.h asm-generic/sockios.h linux/sockios.h
+	"$mydir"/ioctls_hex.sh "$inc_dir" 8B linux/wireless.h
+} > ioctls_hex.h
+msg "generated $(grep -c '^{' ioctls_hex.h) hex ioctls from $inc_dir"
+
+# Fetch ioctl commands defined in symbolic form.
+"$mydir"/ioctls_sym.sh "$inc_dir" > ioctls_sym.h
+
+# Part of android ioctl commands are defined elsewhere.
+android_dir="$inc_dir/../drivers/staging/android"
+if [ -d "$android_dir/uapi" ]; then
+	"$mydir"/ioctls_sym.sh "$android_dir" staging/android >> ioctls_sym.h
+fi
+msg "generated $(grep -c '^{' ioctls_sym.h) symbolic ioctls from $inc_dir"
+
+# Output all ioctl definitions fetched from include-directory.
+echo "/* Generated by $me from definitions found in ${inc_dir%%/}/ tree. */" > ioctls_inc.h
+LC_COLLATE=C sort -u ioctls_hex.h ioctls_sym.h >> ioctls_inc.h
+msg "generated $(grep -c '^{' ioctls_inc.h) ioctls from $inc_dir"
+
+[ -n "$arch_dir" ] || exit 0
+
+# Fetch ioctl commands defined in hex form.
+{
+	"$mydir"/ioctls_hex.sh "$arch_dir" 54 asm/ioctls.h
+	"$mydir"/ioctls_hex.sh "$arch_dir" '\(46\|54\|66\|74\)' asm/ioctls.h
+	"$mydir"/ioctls_hex.sh "$arch_dir" 89 asm/sockios.h
+} > ioctls_hex.h
+msg "generated $(grep -c '^{' ioctls_hex.h) hex ioctls from $arch_dir"
+
+# Fetch ioctl commands defined in symbolic form.
+INCLUDES="-I$abs_inc_dir/uapi -I$abs_inc_dir ${INCLUDES-}" \
+	"${0%/*}"/ioctls_sym.sh "$arch_dir" > ioctls_sym.h
+msg "generated $(grep -c '^{' ioctls_sym.h) symbolic ioctls from $arch_dir"
+
+# Output all ioctl definitions fetched from arch-include-directory.
+echo "/* Generated by $me from definitions found in ${arch_dir%%/}/ tree. */" > ioctls_arch.h
+LC_COLLATE=C sort -u ioctls_hex.h ioctls_sym.h >> ioctls_arch.h
+msg "generated $(grep -c '^{' ioctls_arch.h) ioctls from $arch_dir"
diff --git a/strace/maint/ioctls_hex.sh b/strace/maint/ioctls_hex.sh
new file mode 100755
index 0000000..a798733
--- /dev/null
+++ b/strace/maint/ioctls_hex.sh
@@ -0,0 +1,49 @@
+#!/bin/sh
+# Copyright (c) 2001 Wichert Akkerman <wichert@cistron.nl>
+# Copyright (c) 2004-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+set -efu
+
+me="${0##*/}"
+
+[ $# -ge 2 ] || {
+	echo >&2 "usage: $me include-directory type [files...]"
+	exit 1
+}
+
+dir="$1"; shift # dir must exist
+type="$1"; shift # type might be a regexp
+
+cd "$dir"
+
+regexp='[[:space:]]*#[[:space:]]*define[[:space:]]\+\([A-Z][A-Z0-9_]*\)[[:space:]]\+\(0x'"$type"'..\)\>'
+
+for f; do
+	grep "^$regexp" "$f" "uapi/$f" 2>/dev/null ||:;
+done |
+	sed 's|^uapi/||' |
+	sed -n 's/^\([^:]*\):'"$regexp"'.*/{ "\1", "\2", 0, \3, 0 },/p' |
+	LC_COLLATE=C sort -u
diff --git a/strace/maint/ioctls_sym.sh b/strace/maint/ioctls_sym.sh
new file mode 100755
index 0000000..20b1730
--- /dev/null
+++ b/strace/maint/ioctls_sym.sh
@@ -0,0 +1,423 @@
+#!/bin/sh
+# Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+set -efu
+
+# This script processes header files containing ioctl command definitions in
+# symbolic form, assuming that these definitions match the following regular
+# expressions:
+
+r_define='^[[:space:]]*#[[:space:]]*define[[:space:]]\+'
+r_cmd_name='[A-Z][A-Z0-9_]*'
+r_io='\([A-Z]\+\)\?_S\?\(IO\|IOW\|IOR\|IOWR\|IOC\)'
+r_value='[[:space:]]\+'"$r_io"'[[:space:]]*([^)]'
+regexp="${r_define}${r_cmd_name}${r_value}"
+
+me="${0##*/}"
+msg()
+{
+	printf >&2 '%s\n' "$me: $*"
+}
+
+prefix=
+case $# in
+	1)	inc_dir="$1"; shift
+		;;
+	2)	inc_dir="$1"; shift
+		prefix="$1"; shift
+		;;
+	*)	echo >&2 "usage: $me include-directory [prefix]"
+		exit 1
+		;;
+esac
+
+[ -z "$prefix" ] ||
+	prefix="${prefix%%/}/"
+
+tmpdir=
+cleanup()
+{
+	trap - EXIT
+	[ -z "$tmpdir" ] ||
+		rm -rf -- "$tmpdir"
+	exit "$@"
+}
+
+trap 'cleanup $?' EXIT
+trap 'cleanup 1' HUP PIPE INT QUIT TERM
+tmpdir="$(mktemp -dt "$me.XXXXXX")"
+
+# list interesting files in $inc_dir.
+cd "$inc_dir"
+inc_dir="$(pwd -P)"
+find . -type f -name '*.h' -print0 |
+	xargs -r0 grep -l "$r_value" -- > "$tmpdir"/headers1.list ||
+		exit 0
+cd - > /dev/null
+sed 's|^\./\(uapi/\)\?||' < "$tmpdir"/headers1.list > "$tmpdir"/headers.list
+LC_COLLATE=C sort -u -o "$tmpdir"/headers.list "$tmpdir"/headers.list
+
+msg "processing $(wc -l < "$tmpdir"/headers.list) header files from $inc_dir"
+failed=0
+
+CC="${CC:-gcc}"
+CPP="${CPP:-cpp}"
+CPPFLAGS="${CPPFLAGS-} -D__EXPORTED_HEADERS__"
+CFLAGS="${CFLAGS:--Wall -O2} -D__EXPORTED_HEADERS__"
+LDFLAGS="${LDFLAGS-}"
+INCLUDES="-I$inc_dir/uapi -I$inc_dir ${INCLUDES-}"
+
+$CC $INCLUDES $CFLAGS -c -o "$tmpdir"/print_ioctlent.o "${0%/*}"/print_ioctlent.c
+
+# Hook onto <asm-generic/ioctl.h> and <asm/ioctl.h>
+for d in asm-generic asm; do
+	mkdir "$tmpdir/$d"
+	cat > "$tmpdir/$d"/ioctl.h <<__EOF__
+#include_next <$d/ioctl.h>
+#undef _IOC
+#define _IOC(dir,type,nr,size) dir, type, nr, size
+__EOF__
+done
+
+INCLUDES="-I$tmpdir $INCLUDES"
+
+process_file()
+{
+	local f="$1"; shift
+
+	# Common code for every processed file.
+	cat > "$tmpdir"/printents.c <<__EOF__
+#include <asm/termbits.h>
+#include <asm/ioctl.h>
+#include <linux/types.h>
+#include <linux/limits.h>
+#include <linux/major.h>
+
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <stdint.h>
+#include <stdbool.h>
+
+#ifndef NULL
+# define NULL ((void*)0)
+#endif
+#ifndef __user
+# define __user
+#endif
+#ifndef __iomem
+# define __iomem
+#endif
+#ifndef __noreturn
+# define __noreturn __attribute__((noreturn))
+#endif
+#ifndef __packed
+# define __packed __attribute__((packed))
+#endif
+
+typedef signed char s8;
+typedef unsigned char u8;
+typedef signed short s16;
+typedef unsigned short u16;
+typedef signed int s32;
+typedef unsigned int u32;
+typedef signed long long s64;
+typedef unsigned long long u64;
+
+#include "fixes.h"
+
+#include <asm/bitsperlong.h>
+#ifndef BITS_PER_LONG
+# define BITS_PER_LONG __BITS_PER_LONG
+#endif
+
+#include "$f"
+
+void print_ioctlent(const char *, const char *, unsigned short, unsigned short, unsigned short, unsigned short);
+
+int main(void)
+{
+
+#include "defs.h"
+
+return 0;
+}
+__EOF__
+
+	# Soft workarounds for some processed files.  Fragile.
+	case "$f" in
+		*asm/cmb.h)
+			echo '#include <asm/dasd.h>'
+			;;
+		*asm/ioctls.h)
+			cat <<'__EOF__'
+#include <asm/termios.h>
+#include <linux/serial.h>
+__EOF__
+			;;
+		drm/sis_drm.h)
+			echo '#include <drm/drm.h>'
+			;;
+		*drm/*_drm.h)
+			echo '#include <drm/drm.h>' > "$tmpdir/drm.h"
+			;;
+		fbio.h|*/fbio.h)
+			cat <<'__EOF__'
+#include <linux/fb.h>
+#undef FBIOGETCMAP
+#undef FBIOPUTCMAP
+__EOF__
+			;;
+		*linux/atm?*.h)
+			echo '#include <linux/atm.h>'
+			;;
+		*linux/auto_fs*.h)
+			echo 'typedef u32 compat_ulong_t;'
+			;;
+		*linux/coda.h|*android_alarm.h)
+			cat <<'__EOF__'
+#ifndef _LINUX_TIME_H
+# define _LINUX_TIME_H
+#endif
+#ifndef _UAPI_LINUX_TIME_H
+# define _UAPI_LINUX_TIME_H
+#endif
+__EOF__
+			;;
+		*linux/fs.h|*linux/ncp_fs.h)
+			cat <<'__EOF__'
+#include <linux/blktrace_api.h>
+#include <linux/fiemap.h>
+__EOF__
+			;;
+		*linux/if_pppox.h)
+			cat <<'__EOF__'
+#include <linux/if.h>
+#include <linux/in.h>
+#include <linux/in6.h>
+__EOF__
+			;;
+		*linux/if_tun.h|*linux/ppp-ioctl.h)
+			echo '#include <linux/filter.h>'
+			;;
+		*linux/isdn_ppp.h|*linux/gsmmux.h)
+			echo '#include <linux/if.h>'
+			;;
+		*media*/saa6588.h)
+			echo 'typedef struct poll_table_struct poll_table;'
+			;;
+		*linux/ivtvfb.h|*linux/meye.h|*media/*.h)
+			echo '#include <linux/videodev2.h>'
+			;;
+		*linux/kvm.h)
+			cat <<'__EOF__'
+#if !(defined __powerpc__)
+struct kvm_allocate_rma { __u32 unused[2]; };
+struct kvm_create_spapr_tce { __u32 unused[3]; };
+struct kvm_create_spapr_tce_64 { __u32 unused[8]; };
+struct kvm_get_htab_fd { __u32 unused[8]; };
+struct kvm_rtas_token_args { __u8 unused[128]; };
+#endif
+
+#if !(defined __arm64__ || defined __arm__)
+struct kvm_vcpu_init { __u32 unused[8]; };
+#endif
+
+#if !(defined __x86_64__ || defined __i386__)
+struct kvm_cpuid { __u32 unused[2]; };
+struct kvm_cpuid2 { __u32 unused[2]; };
+struct kvm_debugregs { __u32 unused[32]; };
+struct kvm_lapic_state { __u32 unused[256]; };
+struct kvm_memory_alias { __u32 unused[8]; };
+struct kvm_msr_list { __u32 unused[1]; };
+struct kvm_msrs { __u32 unused[2]; };
+struct kvm_pit_state { __u32 unused[18]; };
+struct kvm_pit_state2 { __u32 unused[28]; };
+struct kvm_vcpu_events { __u32 unused[16]; };
+struct kvm_x86_mce { __u32 unused[16]; };
+struct kvm_xcrs { __u32 unused[98]; };
+struct kvm_xen_hvm_config { __u32 unused[14]; };
+struct kvm_xsave { __u32 unused[1024]; };
+#endif
+__EOF__
+			;;
+		*linux/sonet.h)
+			echo '#include <linux/atmioc.h>'
+			;;
+		*linux/usbdevice_fs.h)
+			cat <<'__EOF__'
+struct usbdevfs_ctrltransfer32 { __u32 unused[4]; };
+struct usbdevfs_bulktransfer32 { __u32 unused[4]; };
+struct usbdevfs_disconnectsignal32 { __u32 unused[2]; };
+struct usbdevfs_urb32 { __u8 unused[42]; };
+struct usbdevfs_ioctl32 { __u32 unused[3]; };
+__EOF__
+			;;
+		logger.h|*/logger.h)
+			echo 'typedef __u32 kuid_t;'
+			;;
+		*sound/asequencer.h)
+			cat <<'__EOF__'
+#include <sound/asound.h>
+struct snd_seq_queue_owner { __u32 unused[0]; };
+__EOF__
+			;;
+		*sound/emu10k1.h)
+			cat <<'__EOF__'
+#include <sound/asound.h>
+#ifndef DECLARE_BITMAP
+# define DIV_ROUND_UP(x,y) (((x) + ((y) - 1)) / (y))
+# define BITS_TO_LONGS(nr) DIV_ROUND_UP(nr, 8 * sizeof(long))
+# define DECLARE_BITMAP(name,bits) unsigned long name[BITS_TO_LONGS(bits)]
+#endif
+__EOF__
+			;;
+		*video/sstfb.h)
+			echo 'struct fb_info;'
+			;;
+		*xen/gntdev.h)
+			cat <<'__EOF__'
+typedef uint32_t grant_ref_t;
+typedef uint16_t domid_t;
+__EOF__
+			;;
+		*xen/interface/*.h)
+			return 0 # false positives
+			;;
+		*xen/privcmd.h)
+			return 0 # too much work to make it compileable
+			;;
+	esac > "$tmpdir"/fixes.h
+
+	cat > "$tmpdir"/header.in <<__EOF__
+#include <asm/bitsperlong.h>
+#ifndef BITS_PER_LONG
+# define BITS_PER_LONG __BITS_PER_LONG
+#endif
+#include "$f"
+__EOF__
+
+	if [ -f "$inc_dir/uapi/$f" ]; then
+		s="$inc_dir/uapi/$f"
+	elif [ -f "$inc_dir/$f" ]; then
+		s="$inc_dir/$f"
+	else
+		msg "$f: file not found"
+		return 1
+	fi
+
+	[ -n "${f##*/*}" ] ||
+		mkdir -p "$tmpdir/${f%/*}"
+	# Hard workarounds for some processed files.  Very fragile.
+	case "$f" in
+		*acpi/*|*linux/i2o.h|*media*/exynos-fimc.h|*media/v4l2-subdev.h|*net/bluetooth/*|net/nfc/nci_core.h)
+			# Fetch macros only.
+			grep "${r_define}${r_cmd_name}" < "$s" > "$tmpdir/$f"
+			;;
+		binder.h|*/binder.h)
+			# Convert enums to macros.
+			sed '/^enum binder/,/^};/d' < "$s" > "$tmpdir/$f"
+			sed -n '/^enum binder/,/^};/ s/^[[:space:]].*/&/p' < "$s" |
+			sed -e '
+s/^[[:space:]]*\([A-Z][A-Z_0-9]*\)[[:space:]]*=[[:space:]]*_\(IO\|IOW\|IOR\|IOWR\|IOC\)[[:space:]]*(/#define \1 _\2(/
+s/^\(#define .*)\),$/\1/
+s/^\(#define .*,\)$/\1 \\/
+s/^\([[:space:]]\+[^),]\+)\),$/\1/' >> "$tmpdir/$f"
+			;;
+		*drm/r128_drm.h)
+			# Filter out the code that references unknown types.
+			sed '/drm_r128_clear2_t/d' < "$s" > "$tmpdir/$f"
+			;;
+		*drm/sis_drm.h)
+			# Filter out the code that references unknown types.
+			sed '/^struct sis_file_private/,/^}/d' < "$s" > "$tmpdir/$f"
+			;;
+		*drm/via_drm.h)
+			# Create the file it attempts to include.
+			touch "$tmpdir/via_drmclient.h"
+			# Filter out the code that references unknown types.
+			sed '/^struct via_file_private/,/^}/d' < "$s" > "$tmpdir/$f"
+			;;
+		*linux/vmw_vmci_defs.h)
+			# Fetch ioctl macros only.
+			grep "${r_define}I" < "$s" > "$tmpdir/$f"
+			;;
+		*media/v4l2-common.h)
+			# Fetch one piece of code containing ioctls definitions.
+			sed -n '/ remaining ioctls/,/ ---/p' < "$s" > "$tmpdir/$f"
+			;;
+		*linux/nilfs2_fs.h)
+			# Create the file it attempts to include.
+			touch "$tmpdir/asm/bug.h"
+			;;
+		openpromio.h|*/openpromio.h|fbio.h|*/fbio.h)
+			# Create the file it attempts to include.
+			mkdir -p "$tmpdir/linux"
+			touch "$tmpdir/linux/compiler.h"
+	esac
+	if [ -f "$tmpdir/$f" ]; then
+		s="$tmpdir/$f"
+	fi
+
+	# This may fail if the file includes unavailable headers.
+	# In case of success it outputs both the #define directives
+	# and the result of preprocessing.
+	$CPP $CPPFLAGS -dD $INCLUDES < "$tmpdir"/header.in > "$tmpdir"/header.out
+
+	# Need to exclude ioctl commands defined elsewhere.
+	local_defines='^[[:space:]]*#[[:space:]]*define[[:space:]]\+\('"$r_cmd_name"'\)[[:space:]]'
+	sed -n 's/'"$local_defines"'.*/\1\\/p' "$s" > "$tmpdir"/local_names
+	r_local_names="$(tr '\n' '|' < "$tmpdir"/local_names)"
+	r_local_names="${r_local_names%%|}"
+	r_local_names="${r_local_names%%\\}"
+
+	# Keep this in sync with $regexp by replacing $r_cmd_name with $r_local_names.
+	defs_regexp="${r_define}\($r_local_names\)${r_value}"
+
+	qf="$(echo "$prefix$f" | sed 's/[&\/]/\\&/g')"
+	# This outputs lines in the following format:
+	# print_ioctlent("filename.h", "IOCTL_CMD_NAME", IOCTL_CMD_NAME);
+	sed -n 's/'"$defs_regexp"'.*/print_ioctlent("'"$qf"'", "\1", \1);/p' \
+		< "$tmpdir"/header.out > "$tmpdir"/defs.h
+
+	# If something is wrong with the file, this will fail.
+	$CC $INCLUDES $CFLAGS -c -o "$tmpdir"/printents.o "$tmpdir"/printents.c
+	$CC $LDFLAGS -o "$tmpdir"/print_ioctlents \
+		"$tmpdir"/printents.o "$tmpdir"/print_ioctlent.o
+	"$tmpdir"/print_ioctlents > "$tmpdir"/ioctlents
+	cat "$tmpdir"/ioctlents
+	msg "$f: fetched $(grep -c '^{' "$tmpdir"/ioctlents) ioctl entries"
+}
+
+while read f; do
+	(process_file "$f" < /dev/null)
+	[ $? -eq 0 ] || {
+		msg "$f: failed to process"
+		failed=$((1 + $failed))
+	}
+done < "$tmpdir"/headers.list
+
+[ $failed -eq 0 ] ||
+	msg "failed to process $failed file(s)"
diff --git a/strace/maint/print_ioctlent.c b/strace/maint/print_ioctlent.c
new file mode 100644
index 0000000..d15aa35
--- /dev/null
+++ b/strace/maint/print_ioctlent.c
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <stdio.h>
+#include <asm/ioctl.h>
+
+typedef unsigned short u16;
+
+static const char *
+dir2str(const char *name, u16 dir)
+{
+	switch (dir) {
+#define CASE(x) case x: return #x
+		CASE(_IOC_NONE);
+		CASE(_IOC_READ);
+		CASE(_IOC_WRITE);
+		CASE(_IOC_READ|_IOC_WRITE);
+	}
+
+	static char buf[3 + sizeof(dir) * 2];
+	fprintf(stderr,
+		"print_ioctlents: WARNING: invalid dir 0x%02x in %s\n",
+		dir, name);
+	snprintf(buf, sizeof(buf), "0x%02x", dir);
+	return buf;
+}
+
+void
+print_ioctlent(const char *info, const char *name,
+	       u16 dir, u16 type, u16 nr, u16 size)
+{
+	unsigned int type_nr =
+		((unsigned) type << _IOC_TYPESHIFT) |
+		((unsigned) nr << _IOC_NRSHIFT);
+
+	if (dir & ~_IOC_DIRMASK)
+		fprintf(stderr,
+			"print_ioctlents: WARNING: dir 0x%02x is out of mask 0x%02x in %s\n",
+			dir, _IOC_DIRMASK, name);
+	if (type & ~_IOC_TYPEMASK)
+		fprintf(stderr,
+			"print_ioctlents: WARNING: type 0x%02x is out of mask 0x%02x in %s\n",
+			type, _IOC_TYPEMASK, name);
+	if (nr & ~_IOC_NRMASK)
+		fprintf(stderr,
+			"print_ioctlents: WARNING: nr 0x%02x is out of mask 0x%02x in %s\n",
+			nr, _IOC_NRMASK, name);
+	if (size & ~_IOC_SIZEMASK)
+		fprintf(stderr,
+			"print_ioctlents: WARNING: size 0x%02x is out of mask 0x%02x in %s\n",
+			size, _IOC_SIZEMASK, name);
+
+	printf("{ \"%s\", \"%s\", %s, 0x%04x, 0x%02x },\n",
+		info, name, dir2str(name, dir), type_nr, size);
+}
diff --git a/strace/make-dist b/strace/make-dist
new file mode 100755
index 0000000..9accae7
--- /dev/null
+++ b/strace/make-dist
@@ -0,0 +1,35 @@
+#!/bin/sh -e
+
+tag="${1:-master}"
+
+j=-j`getconf _NPROCESSORS_ONLN 2> /dev/null` || j=
+
+distdir=strace-dist-$$
+abs_distdir="`pwd`/$distdir"
+trap 'chmod -Rf u+w $abs_distdir; rm -rf $abs_distdir' 1 2 15 0
+
+set -x
+git clone -q -n -s .git "$distdir"
+
+cd $distdir
+git checkout -f "$tag"
+
+./git-set-file-times
+
+./bootstrap
+
+./configure --enable-maintainer-mode
+
+make -s $j distcheck
+
+if git describe --exact-match --match='v*' >/dev/null; then
+	make -s $j news-check
+else
+	echo 'SKIP: make news-check'
+fi
+
+./make-dsc strace-*.tar.gz > ../strace.dsc
+
+cat strace.spec > ../strace.spec
+
+mv -f strace-*.tar.[gx]z ..
diff --git a/strace/make-dsc b/strace/make-dsc
new file mode 100755
index 0000000..951c5a9
--- /dev/null
+++ b/strace/make-dsc
@@ -0,0 +1,49 @@
+#!/bin/sh -e
+
+exec < /dev/null
+
+cat <<__EOF__
+Format: 1.0
+$(sed '/^Source:[[:space:]]*/!d;q' debian/control)
+Binary: $(sed '/^Package:[[:space:]]*/!d;s///' debian/control |
+	tr '\n' ' ' | sed 's/ ./,&/g')
+$(sed '/^Architecture:[[:space:]]*/!d;q' debian/control)
+Version: $(sed -n '1s/^[^(]*(\([^)]\+\)).*/\1/p' debian/changelog)
+$(sed '/^Maintainer:[[:space:]]*/!d;q' debian/control)
+$(sed '/^Homepage:[[:space:]]*/!d;q' debian/control)
+$(sed '/^Standards-Version:[[:space:]]*/!d;q' debian/control)
+$(sed '/^Build-Depends:[[:space:]]*/!d;q' debian/control)
+Package-List:
+ strace deb $(
+	sed '/^Section:[[:space:]]*/!d;s///;q' debian/control) $(
+	sed '/^Priority:[[:space:]]*/!d;s///;q' debian/control) arch=$(
+	sed -n "/^Package:[[:space:]]*strace\$/,/^\$/p" debian/control |
+		sed -e '/^Architecture:[[:space:]]*/!d;s///' -e 's/ /,/g')
+ strace64 deb $(sed '/^Section:[[:space:]]*/!d;s///;q' debian/control) $(
+	sed -n "/^Package:[[:space:]]*strace64\$/,/^\$/p" debian/control |
+		sed '/^Priority:[[:space:]]*/!d;s///;q') arch=$(
+	sed -n "/^Package:[[:space:]]*strace64\$/,/^\$/p" debian/control |
+		sed -e '/^Architecture:[[:space:]]*/!d;s///' -e 's/ /,/g')
+ strace-udeb udeb $(
+	sed -n "/^Package:[[:space:]]*strace-udeb\$/,/^\$/p" debian/control |
+		sed '/^Section:[[:space:]]*/!d;s///;q') $(
+	sed -n "/^Package:[[:space:]]*strace-udeb\$/,/^\$/p" debian/control |
+		sed '/^Priority:[[:space:]]*/!d;s///;q') arch=$(
+	sed -n "/^Package:[[:space:]]*strace-udeb\$/,/^\$/p" debian/control |
+		sed -e '/^Architecture:[[:space:]]*/!d;s///' -e 's/ /,/g')
+Checksums-Sha1:
+$(for f; do echo " $(
+	sha1sum -- "$f" | sed 's/ .*//') $(
+	stat -c %s -- "$f") $(
+	echo $f | sed 's/-/_/;s/\.tar/.orig&/')"; done)
+Checksums-Sha256:
+$(for f; do echo " $(
+	sha256sum -- "$f" | sed 's/ .*//') $(
+	stat -c %s -- "$f") $(
+	echo $f | sed 's/-/_/;s/\.tar/.orig&/')"; done)
+Files:
+$(for f; do echo " $(
+	md5sum -- "$f" | sed 's/ .*//') $(
+	stat -c %s -- "$f") $(
+	echo $f | sed 's/-/_/;s/\.tar/.orig&/')"; done)
+__EOF__
diff --git a/strace/mem.c b/strace/mem.c
new file mode 100644
index 0000000..affc935
--- /dev/null
+++ b/strace/mem.c
@@ -0,0 +1,344 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2000 PocketPenguins Inc.  Linux for Hitachi SuperH
+ *                    port by Greg Banks <gbanks@pocketpenguins.com>
+ * 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 <asm/mman.h>
+#include <sys/mman.h>
+
+unsigned long
+get_pagesize(void)
+{
+	static unsigned long pagesize;
+
+	if (!pagesize)
+		pagesize = sysconf(_SC_PAGESIZE);
+	return pagesize;
+}
+
+SYS_FUNC(brk)
+{
+	printaddr(tcp->u_arg[0]);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+#include "xlat/mmap_prot.h"
+#include "xlat/mmap_flags.h"
+
+static void
+print_mmap(struct tcb *tcp, long *u_arg, unsigned long long offset)
+{
+	const unsigned long addr = u_arg[0];
+	const unsigned long len = u_arg[1];
+	const unsigned long prot = u_arg[2];
+	const unsigned long flags = u_arg[3];
+	const int fd = u_arg[4];
+
+	printaddr(addr);
+	tprintf(", %lu, ", len);
+	printflags_long(mmap_prot, prot, "PROT_???");
+	tprints(", ");
+#ifdef MAP_TYPE
+	printxval_long(mmap_flags, flags & MAP_TYPE, "MAP_???");
+	addflags(mmap_flags, flags & ~MAP_TYPE);
+#else
+	printflags_long(mmap_flags, flags, "MAP_???");
+#endif
+	tprints(", ");
+	printfd(tcp, fd);
+	tprintf(", %#llx", offset);
+}
+
+/* Syscall name<->function correspondence is messed up on many arches.
+ * For example:
+ * i386 has __NR_mmap == 90, and it is "old mmap", and
+ * also it has __NR_mmap2 == 192, which is a "new mmap with page offsets".
+ * But x86_64 has just one __NR_mmap == 9, a "new mmap with byte offsets".
+ * Confused? Me too!
+ */
+
+#if defined AARCH64 || defined ARM \
+ || defined I386 || defined X86_64 || defined X32 \
+ || defined M68K \
+ || defined S390 || defined S390X
+/* Params are pointed to by u_arg[0], offset is in bytes */
+SYS_FUNC(old_mmap)
+{
+	long u_arg[6];
+# if defined AARCH64 || defined X86_64
+	/* We are here only in a 32-bit personality. */
+	unsigned int narrow_arg[6];
+	if (umove_or_printaddr(tcp, tcp->u_arg[0], &narrow_arg))
+		return RVAL_DECODED | RVAL_HEX;
+	unsigned int i;
+	for (i = 0; i < 6; i++)
+		u_arg[i] = narrow_arg[i];
+# else
+	if (umove_or_printaddr(tcp, tcp->u_arg[0], &u_arg))
+		return RVAL_DECODED | RVAL_HEX;
+# endif
+	print_mmap(tcp, u_arg, (unsigned long) u_arg[5]);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+#endif /* old_mmap architectures */
+
+#if defined(S390)
+/* Params are pointed to by u_arg[0], offset is in pages */
+SYS_FUNC(old_mmap_pgoff)
+{
+	long u_arg[5];
+	int i;
+	unsigned narrow_arg[6];
+	unsigned long long offset;
+	if (umoven(tcp, tcp->u_arg[0], sizeof(narrow_arg), narrow_arg) == -1)
+		return 0;
+	for (i = 0; i < 5; i++)
+		u_arg[i] = (unsigned long) narrow_arg[i];
+	offset = narrow_arg[5];
+	offset *= get_pagesize();
+	print_mmap(tcp, u_arg, offset);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+#endif
+
+/* Params are passed directly, offset is in bytes */
+SYS_FUNC(mmap)
+{
+	unsigned long long offset =
+#if HAVE_STRUCT_TCB_EXT_ARG
+		tcp->ext_arg[5];	/* try test/x32_mmap.c */
+#else
+		(unsigned long) tcp->u_arg[5];
+#endif
+	/* Example of kernel-side handling of this variety of mmap:
+	 * arch/x86/kernel/sys_x86_64.c::SYSCALL_DEFINE6(mmap, ...) calls
+	 * sys_mmap_pgoff(..., off >> PAGE_SHIFT); i.e. off is in bytes,
+	 * since the above code converts off to pages.
+	 */
+	print_mmap(tcp, tcp->u_arg, offset);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+/* Params are passed directly, offset is in pages */
+SYS_FUNC(mmap_pgoff)
+{
+	/* Try test/mmap_offset_decode.c */
+	unsigned long long offset;
+	offset = (unsigned long) tcp->u_arg[5];
+	offset *= get_pagesize();
+	print_mmap(tcp, tcp->u_arg, offset);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+/* Params are passed directly, offset is in 4k units */
+SYS_FUNC(mmap_4koff)
+{
+	unsigned long long offset;
+	offset = (unsigned long) tcp->u_arg[5];
+	offset <<= 12;
+	print_mmap(tcp, tcp->u_arg, offset);
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+SYS_FUNC(munmap)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(mprotect)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	printflags_long(mmap_prot, tcp->u_arg[2], "PROT_???");
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/mremap_flags.h"
+
+SYS_FUNC(mremap)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, %lu, ", tcp->u_arg[1], tcp->u_arg[2]);
+	printflags_long(mremap_flags, tcp->u_arg[3], "MREMAP_???");
+#ifdef MREMAP_FIXED
+	if ((tcp->u_arg[3] & (MREMAP_MAYMOVE | MREMAP_FIXED)) ==
+	    (MREMAP_MAYMOVE | MREMAP_FIXED)) {
+		tprints(", ");
+		printaddr(tcp->u_arg[4]);
+	}
+#endif
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+#include "xlat/madvise_cmds.h"
+
+SYS_FUNC(madvise)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	printxval(madvise_cmds, tcp->u_arg[2], "MADV_???");
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/mlockall_flags.h"
+
+SYS_FUNC(mlockall)
+{
+	printflags(mlockall_flags, tcp->u_arg[0], "MCL_???");
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/mctl_sync.h"
+
+SYS_FUNC(msync)
+{
+	/* addr */
+	printaddr(tcp->u_arg[0]);
+	/* len */
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	/* flags */
+	printflags(mctl_sync, tcp->u_arg[2], "MS_???");
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/mlock_flags.h"
+
+SYS_FUNC(mlock2)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	printflags(mlock_flags, tcp->u_arg[2], "MLOCK_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(mincore)
+{
+	if (entering(tcp)) {
+		printaddr(tcp->u_arg[0]);
+		tprintf(", %lu, ", tcp->u_arg[1]);
+	} else {
+		const unsigned long page_size = get_pagesize();
+		const unsigned long page_mask = page_size - 1;
+		unsigned long len = tcp->u_arg[1];
+		unsigned char *vec = NULL;
+
+		len = len / page_size + (len & page_mask ? 1 : 0);
+		if (syserror(tcp) || !verbose(tcp) ||
+		    !tcp->u_arg[2] || !(vec = malloc(len)) ||
+		    umoven(tcp, tcp->u_arg[2], len, vec) < 0)
+			printaddr(tcp->u_arg[2]);
+		else {
+			unsigned long i;
+			tprints("[");
+			for (i = 0; i < len; i++) {
+				if (abbrev(tcp) && i >= max_strlen) {
+					tprints("...");
+					break;
+				}
+				tprints((vec[i] & 1) ? "1" : "0");
+			}
+			tprints("]");
+		}
+		free(vec);
+	}
+	return 0;
+}
+
+#if defined ALPHA || defined IA64 || defined M68K \
+ || defined SPARC || defined SPARC64
+SYS_FUNC(getpagesize)
+{
+	return RVAL_DECODED | RVAL_HEX;
+}
+#endif
+
+SYS_FUNC(remap_file_pages)
+{
+	const unsigned long addr = tcp->u_arg[0];
+	const unsigned long size = tcp->u_arg[1];
+	const unsigned long prot = tcp->u_arg[2];
+	const unsigned long pgoff = tcp->u_arg[3];
+	const unsigned long flags = tcp->u_arg[4];
+
+	printaddr(addr);
+	tprintf(", %lu, ", size);
+	printflags_long(mmap_prot, prot, "PROT_???");
+	tprintf(", %lu, ", pgoff);
+#ifdef MAP_TYPE
+	printxval_long(mmap_flags, flags & MAP_TYPE, "MAP_???");
+	addflags(mmap_flags, flags & ~MAP_TYPE);
+#else
+	printflags_long(mmap_flags, flags, "MAP_???");
+#endif
+
+	return RVAL_DECODED;
+}
+
+#if defined(POWERPC)
+static bool
+print_protmap_entry(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	tprintf("%#08x", * (unsigned int *) elem_buf);
+
+	return true;
+}
+
+SYS_FUNC(subpage_prot)
+{
+	unsigned long addr = tcp->u_arg[0];
+	unsigned long len = tcp->u_arg[1];
+	unsigned long nmemb = len >> 16;
+	unsigned long map = tcp->u_arg[2];
+
+	printaddr(addr);
+	tprintf(", %lu, ", len);
+
+	unsigned int entry;
+	print_array(tcp, map, nmemb, &entry, sizeof(entry),
+		    umoven_or_printaddr, print_protmap_entry, 0);
+
+	return RVAL_DECODED;
+}
+#endif
diff --git a/strace/membarrier.c b/strace/membarrier.c
new file mode 100644
index 0000000..3bc5764
--- /dev/null
+++ b/strace/membarrier.c
@@ -0,0 +1,49 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/membarrier_cmds.h"
+
+SYS_FUNC(membarrier)
+{
+	if (entering(tcp)) {
+		int cmd = tcp->u_arg[0], flags = tcp->u_arg[1];
+
+		printxval(membarrier_cmds, cmd, "MEMBARRIER_CMD_???");
+		tprintf(", %d", flags);
+
+		return cmd ? RVAL_DECODED : 0;
+	}
+
+	if (syserror(tcp) || !tcp->u_rval)
+		return 0;
+
+	tcp->auxstr = sprintflags("", membarrier_cmds,
+				  (unsigned long) tcp->u_rval);
+	return RVAL_HEX | RVAL_STR;
+}
diff --git a/strace/memfd_create.c b/strace/memfd_create.c
new file mode 100644
index 0000000..7c14077
--- /dev/null
+++ b/strace/memfd_create.c
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/memfd_create_flags.h"
+
+SYS_FUNC(memfd_create)
+{
+	printstr(tcp, tcp->u_arg[0], -1);
+	tprints(", ");
+	printflags(memfd_create_flags, tcp->u_arg[1], "MFD_???");
+
+	return RVAL_DECODED | RVAL_FD;
+}
diff --git a/strace/mknod.c b/strace/mknod.c
new file mode 100644
index 0000000..d78fa07
--- /dev/null
+++ b/strace/mknod.c
@@ -0,0 +1,77 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2006 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2006 Bernhard Kaindl <bk@suse.de>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+#include <sys/stat.h>
+
+#ifdef MAJOR_IN_SYSMACROS
+# include <sys/sysmacros.h>
+#endif
+
+#ifdef MAJOR_IN_MKDEV
+# include <sys/mkdev.h>
+#endif
+
+static void
+decode_mknod(struct tcb *tcp, int offset)
+{
+	int mode = tcp->u_arg[offset + 1];
+	unsigned int dev;
+
+	printpath(tcp, tcp->u_arg[offset]);
+	tprintf(", %s", sprintmode(mode));
+	switch (mode & S_IFMT) {
+	case S_IFCHR:
+	case S_IFBLK:
+		dev = tcp->u_arg[offset + 2];
+		tprintf(", makedev(%u, %u)", major(dev), minor(dev));
+		break;
+	}
+}
+
+SYS_FUNC(mknod)
+{
+	decode_mknod(tcp, 0);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(mknodat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	decode_mknod(tcp, 1);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/mmsghdr.c b/strace/mmsghdr.c
new file mode 100644
index 0000000..93e3889
--- /dev/null
+++ b/strace/mmsghdr.c
@@ -0,0 +1,246 @@
+/*
+ * Copyright (c) 2010 Andreas Schwab <schwab@linux-m68k.org>
+ * Copyright (c) 2012-2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+ * Copyright (c) 2010-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "msghdr.h"
+#include <limits.h>
+
+static int
+fetch_struct_mmsghdr_or_printaddr(struct tcb *tcp, const long addr,
+				  const unsigned int len, void *const mh)
+{
+	if ((entering(tcp) || !syserror(tcp))
+	    && fetch_struct_mmsghdr(tcp, addr, mh)) {
+		return 0;
+	} else {
+		printaddr(addr);
+		return -1;
+	}
+}
+
+struct print_struct_mmsghdr_config {
+	const int *p_user_msg_namelen;
+	unsigned int msg_len_vlen;
+	unsigned int count;
+	bool use_msg_len;
+};
+
+static bool
+print_struct_mmsghdr(struct tcb *tcp, void *elem_buf,
+		     size_t elem_size, void *data)
+{
+	const struct mmsghdr *const mmsg = elem_buf;
+	struct print_struct_mmsghdr_config *const c = data;
+
+	if (!c->count) {
+		tprints("...");
+		return false;
+	}
+	--c->count;
+
+	tprints("{msg_hdr=");
+	print_struct_msghdr(tcp, &mmsg->msg_hdr, c->p_user_msg_namelen,
+			    c->use_msg_len ? mmsg->msg_len : -1UL);
+	if (c->msg_len_vlen) {
+		tprintf(", msg_len=%u", mmsg->msg_len);
+		--c->msg_len_vlen;
+	}
+	tprints("}");
+
+	if (c->p_user_msg_namelen)
+		++c->p_user_msg_namelen;
+
+	return true;
+}
+
+static void
+free_mmsgvec_data(void *ptr)
+{
+	char **pstr = ptr;
+	free(*pstr);
+	*pstr = 0;
+
+	free(ptr);
+}
+
+struct mmsgvec_data {
+	char *timeout;
+	unsigned int count;
+	int namelen[IOV_MAX];
+};
+
+static void
+save_mmsgvec_namelen(struct tcb *tcp, unsigned long addr,
+		     unsigned int len, const char *const timeout)
+{
+	if (len > IOV_MAX)
+		len = IOV_MAX;
+
+	const size_t data_size = offsetof(struct mmsgvec_data, namelen)
+				 + sizeof(int) * len;
+	struct mmsgvec_data *const data = xmalloc(data_size);
+	data->timeout = xstrdup(timeout);
+
+	unsigned int i, fetched;
+
+	for (i = 0; i < len; ++i, addr += fetched) {
+		struct mmsghdr mh;
+
+		fetched = fetch_struct_mmsghdr(tcp, addr, &mh);
+		if (!fetched)
+			break;
+		data->namelen[i] = mh.msg_hdr.msg_namelen;
+	}
+	data->count = i;
+
+	set_tcb_priv_data(tcp, data, free_mmsgvec_data);
+}
+
+static void
+decode_mmsgvec(struct tcb *tcp, const unsigned long addr,
+	       const unsigned int vlen, const unsigned int msg_len_vlen,
+	       const bool use_msg_len)
+{
+	struct mmsghdr mmsg;
+	struct print_struct_mmsghdr_config c = {
+		.msg_len_vlen = msg_len_vlen,
+		.count = IOV_MAX,
+		.use_msg_len = use_msg_len
+	};
+	const struct mmsgvec_data *const data = get_tcb_priv_data(tcp);
+
+	if (data) {
+		if (data->count < c.count)
+			c.count = data->count;
+		c.p_user_msg_namelen = data->namelen;
+	}
+
+	print_array(tcp, addr, vlen, &mmsg, sizeof_struct_mmsghdr(),
+		    fetch_struct_mmsghdr_or_printaddr,
+		    print_struct_mmsghdr, &c);
+}
+
+void
+dumpiov_in_mmsghdr(struct tcb *tcp, long addr)
+{
+	unsigned int len = tcp->u_rval;
+	unsigned int i, fetched;
+	struct mmsghdr mmsg;
+
+	for (i = 0; i < len; ++i, addr += fetched) {
+		fetched = fetch_struct_mmsghdr(tcp, addr, &mmsg);
+		if (!fetched)
+			break;
+		tprintf(" = %lu buffers in vector %u\n",
+			(unsigned long) mmsg.msg_hdr.msg_iovlen, i);
+		dumpiov_upto(tcp, mmsg.msg_hdr.msg_iovlen,
+			(long) mmsg.msg_hdr.msg_iov, mmsg.msg_len);
+	}
+}
+
+SYS_FUNC(sendmmsg)
+{
+	if (entering(tcp)) {
+		/* sockfd */
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		if (!verbose(tcp)) {
+			/* msgvec */
+			printaddr(tcp->u_arg[1]);
+			/* vlen */
+			tprintf(", %u, ", (unsigned int) tcp->u_arg[2]);
+			/* flags */
+			printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+			return RVAL_DECODED;
+		}
+	} else {
+		const unsigned int msg_len_vlen =
+			syserror(tcp) ? 0 : tcp->u_rval;
+		/* msgvec */
+		temporarily_clear_syserror(tcp);
+		decode_mmsgvec(tcp, tcp->u_arg[1], tcp->u_arg[2],
+			       msg_len_vlen, false);
+		restore_cleared_syserror(tcp);
+		/* vlen */
+		tprintf(", %u, ", (unsigned int) tcp->u_arg[2]);
+		/* flags */
+		printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+	}
+	return 0;
+}
+
+SYS_FUNC(recvmmsg)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		if (verbose(tcp)) {
+			save_mmsgvec_namelen(tcp, tcp->u_arg[1], tcp->u_arg[2],
+					     sprint_timespec(tcp, tcp->u_arg[4]));
+		} else {
+			/* msgvec */
+			printaddr(tcp->u_arg[1]);
+			/* vlen */
+			tprintf(", %u, ", (unsigned int) tcp->u_arg[2]);
+			/* flags */
+			printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+			tprints(", ");
+			print_timespec(tcp, tcp->u_arg[4]);
+		}
+		return 0;
+	} else {
+		if (verbose(tcp)) {
+			/* msgvec */
+			decode_mmsgvec(tcp, tcp->u_arg[1], tcp->u_rval,
+				       tcp->u_rval, true);
+			/* vlen */
+			tprintf(", %u, ", (unsigned int) tcp->u_arg[2]);
+			/* flags */
+			printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+			tprints(", ");
+			/* timeout on entrance */
+			tprints(*(const char **) get_tcb_priv_data(tcp));
+		}
+		if (syserror(tcp))
+			return 0;
+		if (tcp->u_rval == 0) {
+			tcp->auxstr = "Timeout";
+			return RVAL_STR;
+		}
+		if (!verbose(tcp) || !tcp->u_arg[4])
+			return 0;
+		/* timeout on exit */
+		static char str[sizeof("left") + TIMESPEC_TEXT_BUFSIZE];
+		snprintf(str, sizeof(str), "left %s",
+			 sprint_timespec(tcp, tcp->u_arg[4]));
+		tcp->auxstr = str;
+		return RVAL_STR;
+	}
+}
diff --git a/strace/mount.c b/strace/mount.c
new file mode 100644
index 0000000..1ae445d
--- /dev/null
+++ b/strace/mount.c
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2007-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#define MS_MGC_VAL	0xc0ed0000	/* old magic mount flag number */
+#define MS_MGC_MSK	0xffff0000	/* old magic mount flag mask */
+
+#include "xlat/mount_flags.h"
+
+SYS_FUNC(mount)
+{
+	bool ignore_type = false;
+	bool ignore_data = false;
+	bool old_magic = false;
+	unsigned long flags = tcp->u_arg[3];
+
+	/* Discard magic */
+	if ((flags & MS_MGC_MSK) == MS_MGC_VAL) {
+		flags &= ~MS_MGC_MSK;
+		old_magic = true;
+	}
+
+	if (flags & MS_REMOUNT)
+		ignore_type = true;
+	else if (flags & (MS_BIND | MS_MOVE | MS_SHARED
+			  | MS_PRIVATE | MS_SLAVE | MS_UNBINDABLE))
+		ignore_type = ignore_data = true;
+
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+
+	if (ignore_type)
+		printaddr(tcp->u_arg[2]);
+	else
+		printstr(tcp, tcp->u_arg[2], -1);
+	tprints(", ");
+
+	if (old_magic) {
+		tprints("MS_MGC_VAL");
+		if (flags)
+			tprints("|");
+	}
+	if (flags || !old_magic)
+		printflags_long(mount_flags, flags, "MS_???");
+	tprints(", ");
+
+	if (ignore_data)
+		printaddr(tcp->u_arg[4]);
+	else
+		printstr(tcp, tcp->u_arg[4], -1);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/mpers.awk b/strace/mpers.awk
new file mode 100644
index 0000000..809acf8
--- /dev/null
+++ b/strace/mpers.awk
@@ -0,0 +1,248 @@
+#!/bin/gawk
+#
+# Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+# Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+function compare_indices(i1, v1, i2, v2) {
+	c1 = strtonum(sprintf("%s", i1))
+	c2 = strtonum(sprintf("%s", i2))
+	if (c1 < c2)
+		return -1
+	return (c1 != c2)
+}
+function array_get(array_idx, array_member, array_return)
+{
+	array_return = array[array_idx][array_member]
+	if ("" == array_return) {
+		printf("%s: index [%s] without %s\n",
+		       FILENAME, array_idx, array_member) > "/dev/stderr"
+		exit 1
+	}
+	return array_return
+}
+function array_seq(array_idx)
+{
+	if ("seq" in array[array_idx])
+		return array[array_idx]["seq"]
+	index_seq++
+	array[array_idx]["seq"] = index_seq
+	return index_seq
+}
+function enter(array_idx)
+{
+	if (array_idx in called) {
+		printf("%s: index loop detected:", FILENAME) > "/dev/stderr"
+		for (item in called)
+			printf(" %s", item) > "/dev/stderr"
+		print "" > "/dev/stderr"
+		exit 1
+	}
+	called[array_idx] = 1
+}
+function leave(array_idx, to_return)
+{
+	delete called[array_idx]
+	return to_return
+}
+function what_is(what_idx, type_idx, special, item, \
+		 location, prev_location, prev_returned_size)
+{
+	enter(what_idx)
+	special = array_get(what_idx, "special")
+	switch (special) {
+	case "base_type":
+		switch (array_get(what_idx, "encoding")) {
+		case 5: # signed
+			printf("int%s_t ",
+			       8 * array_get(what_idx, "byte_size"))
+			break
+		case 7: # unsigned
+			printf("uint%s_t ",
+			       8 * array_get(what_idx, "byte_size"))
+			break
+		default: # float, signed/unsigned char
+			printf("%s ", array_get(what_idx, "name"))
+			break
+		}
+		returned_size = array_get(what_idx, "byte_size")
+		break
+	case "enumeration_type":
+		returned_size = array_get(what_idx, "byte_size")
+		printf("uint%s_t ", 8 * returned_size)
+		break
+	case "pointer_type":
+		printf("mpers_ptr_t ")
+		returned_size = array_get(what_idx, "byte_size")
+		break
+	case "array_type":
+		type_idx = array_get(what_idx, "type")
+		what_is(type_idx)
+		to_return = array[what_idx]["upper_bound"]
+		if ("" == to_return)
+			to_return = 0
+		returned_size = to_return * returned_size
+		return leave(what_idx, to_return)
+		break
+	case "structure_type":
+		print "struct {"
+		prev_location = 0
+		location = 0
+		returned_size = 0
+		prev_returned_size = 0
+		for (item in array) {
+			if ("parent" in array[item] && \
+				array_get(item, "parent") == what_idx) {
+				location = array_get(item, "location")
+				loc_diff = location - prev_location - \
+					prev_returned_size
+				if (loc_diff != 0) {
+					printf("unsigned char mpers_%s_%s[%s];\n",
+					       "filler", array_seq(item), loc_diff)
+				}
+				prev_location = location
+				returned = what_is(item)
+				prev_returned_size = returned_size
+				printf("%s", array[item]["name"])
+				if ("" != returned) {
+					printf("[%s]", returned)
+				}
+				print ";"
+			}
+		}
+		returned_size = array_get(what_idx, "byte_size")
+		loc_diff = returned_size - prev_location - prev_returned_size
+		if (loc_diff != 0) {
+			printf("unsigned char mpers_%s_%s[%s];\n",
+			       "end_filler", array_seq(item), loc_diff)
+		}
+		printf("} ATTRIBUTE_PACKED ")
+		break
+	case "union_type":
+		print "union {"
+		for (item in array) {
+			if ("parent" in array[item] && \
+				array_get(item, "parent") == what_idx) {
+				returned = what_is(item)
+				printf("%s", array_get(item, "name"))
+				if ("" != returned) {
+					printf("[%s]", returned)
+				}
+				print ";"
+			}
+		}
+		printf("} ")
+		returned_size = array_get(what_idx, "byte_size")
+		break
+	case "typedef":
+		type_idx = array_get(what_idx, "type")
+		return leave(what_idx, what_is(type_idx))
+		break
+	case "member":
+		type_idx = array_get(what_idx, "type")
+		return leave(what_idx, what_is(type_idx))
+		break
+	default:
+		type_idx = array_get(what_idx, "type")
+		what_is(type_idx)
+		break
+	}
+	return leave(what_idx, "")
+}
+BEGIN {
+	match(ARCH_FLAG, /[[:digit:]]+/, temparray)
+	default_pointer_size = temparray[0] / 8
+	print "#include <inttypes.h>"
+}
+/^<[[:xdigit:]]+>/ {
+	match($0, /([[:alnum:]]+)><([[:alnum:]]+)/, matches)
+	level = matches[1]
+	idx = "0x" matches[2]
+	array[idx]["idx"] = idx
+	parent[level] = idx
+}
+/^DW_AT_data_member_location/ {
+	if (!match($0, /\(DW_OP_plus_uconst:[[:space:]]+([[:digit:]]+)\)/, temparray))
+		match($0, /([[:digit:]]+)/, temparray)
+	array[idx]["location"] = temparray[1]
+}
+/^DW_AT_name/ {
+	match($0, /:[[:space:]]+([[:alpha:]_][[:alnum:]_[:space:]]*)/, \
+		temparray)
+	array[idx]["name"] = temparray[1]
+}
+/^DW_AT_byte_size/ {
+	match($0, /[[:digit:]]+/, temparray)
+	array[idx]["byte_size"] = temparray[0]
+}
+/^DW_AT_encoding/ {
+	match($0, /[[:digit:]]+/, temparray)
+	array[idx]["encoding"] = temparray[0]
+}
+/^DW_AT_type/ {
+	match($0, /:[[:space:]]+<(0x[[:xdigit:]]*)>$/, temparray)
+	array[idx]["type"] = temparray[1]
+}
+/^DW_AT_upper_bound/ {
+	match($0, /[[:digit:]]+/, temparray)
+	array[parent[level-1]]["upper_bound"] = temparray[0] + 1
+}
+/^DW_AT_count/ {
+	match($0, /[[:digit:]]+/, temparray)
+	array[parent[level-1]]["upper_bound"] = temparray[0]
+}
+/^Abbrev Number:[^(]+\(DW_TAG_/ {
+	if (match($0, /typedef|union_type|structure_type|pointer_type\
+|enumeration_type|array_type|base_type|member/, temparray)) {
+		array[idx]["special"] = temparray[0]
+		if ("pointer_type" == temparray[0])
+			array[idx]["byte_size"] = default_pointer_size
+		if (level > 1 && "member" == temparray[0])
+			array[idx]["parent"] = parent[level-1]
+	}
+}
+END {
+	PROCINFO["sorted_in"] = "compare_indices"
+	for (item in array) {
+		if (array[item]["special"] == "pointer_type") {
+			print "typedef uint" \
+				8 * array_get(item, "byte_size") "_t mpers_ptr_t;"
+			break
+		}
+	}
+	for (item in array) {
+		if (array[item]["name"] == VAR_NAME) {
+			type = array_get(item, "type")
+			print "typedef"
+			what_is(type)
+			name = array_get(type, "name")
+			print ARCH_FLAG "_" name ";"
+			print "#define MPERS_" \
+				ARCH_FLAG "_" name " " \
+				ARCH_FLAG "_" name
+			break
+		}
+	}
+}
diff --git a/strace/mpers.sh b/strace/mpers.sh
new file mode 100755
index 0000000..559d1f4
--- /dev/null
+++ b/strace/mpers.sh
@@ -0,0 +1,74 @@
+#!/bin/sh -e
+#
+# Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+# 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.
+
+export LC_ALL=C
+
+MPERS_AWK="${0%/*}/mpers.awk"
+ARCH_FLAG=$1
+PARSER_FILE=$2
+
+CC="${CC-gcc}"
+CFLAGS="$CFLAGS -gdwarf-2 -c"
+CPP="${CPP-$CC -E}"
+CPPFLAGS="$CPPFLAGS -MM -MG"
+
+VAR_NAME='mpers_target_var'
+BITS_DIR="mpers${ARCH_FLAG}"
+
+mkdir -p ${BITS_DIR}
+set -- $(sed -n \
+	's/^#[[:space:]]*include[[:space:]]\+DEF_MPERS_TYPE(\([^)[:space:]]*\))$/\1/p' \
+		"${PARSER_FILE}")
+for m_type; do
+	f_h="${BITS_DIR}/${m_type}.h"
+	f_c="${BITS_DIR}/${m_type}.c"
+	f_i="${BITS_DIR}/${m_type}.i"
+	f_o="${BITS_DIR}/${m_type}.o"
+	f_d1="${BITS_DIR}/${m_type}.d1"
+	f_d2="${BITS_DIR}/${m_type}.d2"
+	sed -e '
+		/DEF_MPERS_TYPE('"${m_type}"')$/n
+		/DEF_MPERS_TYPE/d
+		/^[[:space:]]*#[[:space:]]*include[[:space:]]\+\"xlat\//d
+		/^#[[:space:]]*include[[:space:]]\+MPERS_DEFS$/ {s//'"${m_type} ${VAR_NAME}"';/;q}
+		' "${PARSER_FILE}" > "${f_c}"
+	$CPP $CPPFLAGS "${f_c}" > "${f_i}"
+	grep -F -q "${m_type}.h" "${f_i}" ||
+		continue
+	sed -i -e '/DEF_MPERS_TYPE/d' "${f_c}"
+	$CC $CFLAGS $ARCH_FLAG "${f_c}" -o "${f_o}"
+	readelf --debug-dump=info "${f_o}" > "${f_d1}"
+	sed -n '
+		/^[[:space:]]*<1>/,/^[[:space:]]*<1><[^>]\+>: Abbrev Number: 0/!d
+		/^[[:space:]]*<[^>]\+><[^>]\+>: Abbrev Number: 0/d
+		s/^[[:space:]]*<[[:xdigit:]]\+>[[:space:]]\+//
+		s/^[[:space:]]*\(\(<[[:xdigit:]]\+>\)\{2\}\):[[:space:]]\+/\1\n/
+		s/[[:space:]]\+$//
+		p' "${f_d1}" > "${f_d2}"
+	gawk -v VAR_NAME="$VAR_NAME" -v ARCH_FLAG="${ARCH_FLAG#-}" \
+		-f "$MPERS_AWK" "${f_d2}" > "${f_h}"
+done
diff --git a/strace/mpers_test.sh b/strace/mpers_test.sh
new file mode 100755
index 0000000..72b5f5d
--- /dev/null
+++ b/strace/mpers_test.sh
@@ -0,0 +1,127 @@
+#!/bin/sh -efu
+#
+# Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+# Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+mpers_name="$1"; shift
+size="$(printf %s "$mpers_name" |tr -cd '[0-9]')"
+[ "$size" -gt 0 ]
+
+srcdir=${0%/*}
+mpers_sh="${srcdir}/mpers.sh"
+
+mpers_dir="mpers-$mpers_name"
+mkdir -p "$mpers_dir"
+
+sample="$mpers_dir/sample.c"
+cat > "$sample" <<EOF
+#include "mpers_type.h"
+#include DEF_MPERS_TYPE(sample_struct)
+typedef struct {
+	struct {
+		void *p;
+		char sc;
+		/* unsigned char mpers_filler_1[1]; */
+		short ss;
+		unsigned char uc;
+		/* unsigned char mpers_filler_2[3]; */
+		int si;
+		unsigned ui;
+		long sl;
+		unsigned short us;
+		/* unsigned char mpers_filler_3[6]; */
+		long long sll __attribute__((__aligned__(8)));
+		unsigned long long ull;
+		unsigned long ul;
+		long asl[3];
+		char f;
+		/* unsigned char mpers_end_filler_4[7]; */
+	} s;
+	union {
+		long long sll;
+		unsigned long long ull;
+		void *p;
+		long sl;
+		unsigned long ul;
+		int si;
+		unsigned ui;
+		short ss;
+		unsigned short us;
+		char sc;
+		unsigned char uc;
+	} u[3];
+	short f[0];
+} sample_struct;
+#include MPERS_DEFS
+EOF
+
+expected="$mpers_dir/sample.expected"
+cat > "$expected" <<EOF
+#include <inttypes.h>
+typedef uint${size}_t mpers_ptr_t;
+typedef
+struct {
+struct {
+mpers_ptr_t p;
+char sc;
+unsigned char mpers_filler_1[1];
+int16_t ss;
+unsigned char uc;
+unsigned char mpers_filler_2[3];
+int32_t si;
+uint32_t ui;
+int${size}_t sl;
+uint16_t us;
+unsigned char mpers_filler_3[6];
+int64_t sll;
+uint64_t ull;
+uint${size}_t ul;
+int${size}_t asl[3];
+char f;
+unsigned char mpers_end_filler_4[7];
+} ATTRIBUTE_PACKED s;
+union {
+int64_t sll;
+uint64_t ull;
+mpers_ptr_t p;
+int${size}_t sl;
+uint${size}_t ul;
+int32_t si;
+uint32_t ui;
+int16_t ss;
+uint16_t us;
+char sc;
+unsigned char uc;
+} u[3];
+int16_t f[0];
+} ATTRIBUTE_PACKED ${mpers_name}_sample_struct;
+#define MPERS_${mpers_name}_sample_struct ${mpers_name}_sample_struct
+EOF
+
+CFLAGS="$CPPFLAGS -I${srcdir}" \
+CPPFLAGS="$CPPFLAGS -I${srcdir} -DIN_MPERS -DMPERS_IS_${mpers_name}" \
+"$mpers_sh" "-$mpers_name" "$sample"
+cmp "$expected" "$mpers_dir"/sample_struct.h > /dev/null
diff --git a/strace/mpers_type.h b/strace/mpers_type.h
new file mode 100644
index 0000000..4ce569b
--- /dev/null
+++ b/strace/mpers_type.h
@@ -0,0 +1,47 @@
+/*
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifdef IN_MPERS
+# define STRINGIFY(a) #a
+# define DEF_MPERS_TYPE(args) STRINGIFY(args.h)
+# ifdef MPERS_IS_m32
+#  define MPERS_PREFIX m32_
+#  define MPERS_DEFS "m32_type_defs.h"
+# elif defined MPERS_IS_mx32
+#  define MPERS_PREFIX mx32_
+#  define MPERS_DEFS "mx32_type_defs.h"
+# endif
+#else
+# define MPERS_PREFIX
+# define DEF_MPERS_TYPE(args) "empty.h"
+# if IN_MPERS_BOOTSTRAP
+#  define MPERS_DEFS "empty.h"
+# else
+#  define MPERS_DEFS "native_defs.h"
+# endif
+#endif
diff --git a/strace/mpers_xlat.h b/strace/mpers_xlat.h
new file mode 100644
index 0000000..266faec
--- /dev/null
+++ b/strace/mpers_xlat.h
@@ -0,0 +1,77 @@
+extern const struct xlat blkpg_ops[];
+extern const struct xlat btrfs_balance_args[];
+extern const struct xlat btrfs_balance_ctl_cmds[];
+extern const struct xlat btrfs_balance_flags[];
+extern const struct xlat btrfs_balance_state[];
+extern const struct xlat btrfs_compress_types[];
+extern const struct xlat btrfs_defrag_flags[];
+extern const struct xlat btrfs_dev_replace_cmds[];
+extern const struct xlat btrfs_dev_replace_results[];
+extern const struct xlat btrfs_dev_replace_state[];
+extern const struct xlat btrfs_dev_stats_flags[];
+extern const struct xlat btrfs_dev_stats_values[];
+extern const struct xlat btrfs_features_compat[];
+extern const struct xlat btrfs_features_compat_ro[];
+extern const struct xlat btrfs_features_incompat[];
+extern const struct xlat btrfs_key_types[];
+extern const struct xlat btrfs_qgroup_ctl_cmds[];
+extern const struct xlat btrfs_qgroup_inherit_flags[];
+extern const struct xlat btrfs_qgroup_limit_flags[];
+extern const struct xlat btrfs_qgroup_status_flags[];
+extern const struct xlat btrfs_scrub_flags[];
+extern const struct xlat btrfs_send_flags[];
+extern const struct xlat btrfs_snap_flags_v2[];
+extern const struct xlat btrfs_space_info_flags[];
+extern const struct xlat btrfs_tree_objectids[];
+extern const struct xlat evdev_autorepeat[];
+extern const struct xlat evdev_ff_status[];
+extern const struct xlat evdev_ff_types[];
+extern const struct xlat evdev_keycode[];
+extern const struct xlat evdev_leds[];
+extern const struct xlat evdev_misc[];
+extern const struct xlat evdev_mtslots[];
+extern const struct xlat evdev_prop[];
+extern const struct xlat evdev_relative_axes[];
+extern const struct xlat evdev_snd[];
+extern const struct xlat evdev_switch[];
+extern const struct xlat evdev_sync[];
+extern const struct xlat msgctl_flags[];
+extern const struct xlat shmctl_flags[];
+extern const struct xlat mtd_mode_options[];
+extern const struct xlat mtd_file_mode_options[];
+extern const struct xlat mtd_type_options[];
+extern const struct xlat mtd_flags_options[];
+extern const struct xlat mtd_otp_options[];
+extern const struct xlat mtd_nandecc_options[];
+extern const struct xlat sigev_value[];
+extern const struct xlat adjtimex_modes[];
+extern const struct xlat adjtimex_status[];
+extern const struct xlat audit_arch[];
+extern const struct xlat sigbus_codes[];
+extern const struct xlat sigchld_codes[];
+extern const struct xlat sigfpe_codes[];
+extern const struct xlat sigill_codes[];
+extern const struct xlat siginfo_codes[];
+extern const struct xlat sigpoll_codes[];
+extern const struct xlat sigprof_codes[];
+extern const struct xlat sigsegv_codes[];
+extern const struct xlat sigsys_codes[];
+extern const struct xlat sigtrap_codes[];
+extern const struct xlat sigemt_codes[];
+extern const struct xlat sigaltstack_flags[];
+extern const struct xlat v4l2_device_capabilities_flags[];
+extern const struct xlat v4l2_buf_types[];
+extern const struct xlat v4l2_format_description_flags[];
+extern const struct xlat v4l2_fields[];
+extern const struct xlat v4l2_colorspaces[];
+extern const struct xlat v4l2_memories[];
+extern const struct xlat v4l2_buf_flags[];
+extern const struct xlat v4l2_streaming_capabilities[];
+extern const struct xlat v4l2_capture_modes[];
+extern const struct xlat v4l2_input_types[];
+extern const struct xlat v4l2_control_ids[];
+extern const struct xlat v4l2_control_types[];
+extern const struct xlat v4l2_control_flags[];
+extern const struct xlat v4l2_control_classes[];
+extern const struct xlat v4l2_framesize_types[];
+extern const struct xlat v4l2_frameinterval_types[];
diff --git a/strace/mq.c b/strace/mq.c
new file mode 100644
index 0000000..e12eef7
--- /dev/null
+++ b/strace/mq.c
@@ -0,0 +1,90 @@
+/*
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+
+SYS_FUNC(mq_open)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	/* flags */
+	tprint_open_modes(tcp->u_arg[1]);
+	if (tcp->u_arg[1] & O_CREAT) {
+		/* mode */
+		tprintf(", %#lo, ", tcp->u_arg[2]);
+		printmqattr(tcp, tcp->u_arg[3]);
+	}
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(mq_timedsend)
+{
+	tprintf("%ld, ", tcp->u_arg[0]);
+	printstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu, %ld, ", tcp->u_arg[2], tcp->u_arg[3]);
+	print_timespec(tcp, tcp->u_arg[4]);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(mq_timedreceive)
+{
+	if (entering(tcp))
+		tprintf("%ld, ", tcp->u_arg[0]);
+	else {
+		printstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		tprintf(", %lu, %ld, ", tcp->u_arg[2], tcp->u_arg[3]);
+		/*
+		 * Since the timeout parameter is read by the kernel
+		 * on entering syscall, it has to be decoded the same way
+		 * whether the syscall has failed or not.
+		 */
+		temporarily_clear_syserror(tcp);
+		print_timespec(tcp, tcp->u_arg[4]);
+		restore_cleared_syserror(tcp);
+	}
+	return 0;
+}
+
+SYS_FUNC(mq_notify)
+{
+	tprintf("%ld, ", tcp->u_arg[0]);
+	print_sigevent(tcp, tcp->u_arg[1]);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(mq_getsetattr)
+{
+	if (entering(tcp)) {
+		tprintf("%ld, ", tcp->u_arg[0]);
+		printmqattr(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else
+		printmqattr(tcp, tcp->u_arg[2]);
+	return 0;
+}
diff --git a/strace/msghdr.c b/strace/msghdr.c
new file mode 100644
index 0000000..63f5171
--- /dev/null
+++ b/strace/msghdr.c
@@ -0,0 +1,440 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-2000 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "msghdr.h"
+#include <limits.h>
+#include <arpa/inet.h>
+#include <netinet/in.h>
+
+#include "xlat/msg_flags.h"
+#include "xlat/scmvals.h"
+#include "xlat/ip_cmsg_types.h"
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+struct cmsghdr32 {
+	uint32_t cmsg_len;
+	int cmsg_level;
+	int cmsg_type;
+};
+#endif
+
+typedef union {
+	char *ptr;
+	struct cmsghdr *cmsg;
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+	struct cmsghdr32 *cmsg32;
+#endif
+} union_cmsghdr;
+
+static void
+print_scm_rights(struct tcb *tcp, const void *cmsg_data, const size_t data_len)
+{
+	const int *fds = cmsg_data;
+	const size_t nfds = data_len / sizeof(*fds);
+	size_t i;
+
+	tprints("[");
+
+	for (i = 0; i < nfds; ++i) {
+		if (i)
+			tprints(", ");
+		if (abbrev(tcp) && i >= max_strlen) {
+			tprints("...");
+			break;
+		}
+		printfd(tcp, fds[i]);
+	}
+
+	tprints("]");
+}
+
+static void
+print_scm_creds(struct tcb *tcp, const void *cmsg_data, const size_t data_len)
+{
+	const struct ucred *uc = cmsg_data;
+
+	tprintf("{pid=%u, uid=%u, gid=%u}",
+		(unsigned) uc->pid, (unsigned) uc->uid, (unsigned) uc->gid);
+}
+
+static void
+print_scm_security(struct tcb *tcp, const void *cmsg_data,
+		   const size_t data_len)
+{
+	print_quoted_string(cmsg_data, data_len, 0);
+}
+
+static void
+print_cmsg_ip_pktinfo(struct tcb *tcp, const void *cmsg_data,
+		      const size_t data_len)
+{
+	const struct in_pktinfo *info = cmsg_data;
+
+	tprints("{ipi_ifindex=");
+	print_ifindex(info->ipi_ifindex);
+	tprintf(", ipi_spec_dst=inet_addr(\"%s\")",
+		inet_ntoa(info->ipi_spec_dst));
+	tprintf(", ipi_addr=inet_addr(\"%s\")}",
+		inet_ntoa(info->ipi_addr));
+}
+
+static void
+print_cmsg_uint(struct tcb *tcp, const void *cmsg_data, const size_t data_len)
+{
+	const unsigned int *p = cmsg_data;
+
+	tprintf("[%u]", *p);
+}
+
+static void
+print_cmsg_uint8_t(struct tcb *tcp, const void *cmsg_data,
+		   const size_t data_len)
+{
+	const uint8_t *p = cmsg_data;
+
+	tprintf("[%#x]", *p);
+}
+
+static void
+print_cmsg_ip_opts(struct tcb *tcp, const void *cmsg_data,
+		   const size_t data_len)
+{
+	const unsigned char *opts = cmsg_data;
+	size_t i;
+
+	tprints("[");
+	for (i = 0; i < data_len; ++i) {
+		if (i)
+			tprints(", ");
+		if (abbrev(tcp) && i >= max_strlen) {
+			tprints("...");
+			break;
+		}
+		tprintf("0x%02x", opts[i]);
+	}
+	tprints("]");
+}
+
+struct sock_ee {
+	uint32_t ee_errno;
+	uint8_t  ee_origin;
+	uint8_t  ee_type;
+	uint8_t  ee_code;
+	uint8_t  ee_pad;
+	uint32_t ee_info;
+	uint32_t ee_data;
+	struct sockaddr_in offender;
+};
+
+static void
+print_cmsg_ip_recverr(struct tcb *tcp, const void *cmsg_data,
+		      const size_t data_len)
+{
+	const struct sock_ee *const err = cmsg_data;
+
+	tprintf("{ee_errno=%u, ee_origin=%u, ee_type=%u, ee_code=%u"
+		", ee_info=%u, ee_data=%u, offender=",
+		err->ee_errno, err->ee_origin, err->ee_type,
+		err->ee_code, err->ee_info, err->ee_data);
+	print_sockaddr(tcp, &err->offender, sizeof(err->offender));
+	tprints("}");
+}
+
+static void
+print_cmsg_ip_origdstaddr(struct tcb *tcp, const void *cmsg_data,
+			  const size_t data_len)
+{
+	const int addr_len =
+		data_len > sizeof(struct sockaddr_storage)
+		? sizeof(struct sockaddr_storage) : data_len;
+
+	print_sockaddr(tcp, cmsg_data, addr_len);
+}
+
+typedef void (* const cmsg_printer)(struct tcb *, const void *, size_t);
+
+static const struct {
+	const cmsg_printer printer;
+	const size_t min_len;
+} cmsg_socket_printers[] = {
+	[SCM_RIGHTS] = { print_scm_rights, sizeof(int) },
+	[SCM_CREDENTIALS] = { print_scm_creds, sizeof(struct ucred) },
+	[SCM_SECURITY] = { print_scm_security, 1 }
+}, cmsg_ip_printers[] = {
+	[IP_PKTINFO] = { print_cmsg_ip_pktinfo, sizeof(struct in_pktinfo) },
+	[IP_TTL] = { print_cmsg_uint, sizeof(unsigned int) },
+	[IP_TOS] = { print_cmsg_uint8_t, 1 },
+	[IP_RECVOPTS] = { print_cmsg_ip_opts, 1 },
+	[IP_RETOPTS] = { print_cmsg_ip_opts, 1 },
+	[IP_RECVERR] = { print_cmsg_ip_recverr, sizeof(struct sock_ee) },
+	[IP_ORIGDSTADDR] = { print_cmsg_ip_origdstaddr, sizeof(struct sockaddr_in) },
+	[IP_CHECKSUM] = { print_cmsg_uint, sizeof(unsigned int) },
+	[SCM_SECURITY] = { print_scm_security, 1 }
+};
+
+static void
+print_cmsg_type_data(struct tcb *tcp, const int cmsg_level, const int cmsg_type,
+		     const void *cmsg_data, const size_t data_len)
+{
+	const unsigned int utype = cmsg_type;
+	switch (cmsg_level) {
+	case SOL_SOCKET:
+		printxval(scmvals, cmsg_type, "SCM_???");
+		if (utype < ARRAY_SIZE(cmsg_socket_printers)
+		    && cmsg_socket_printers[utype].printer
+		    && data_len >= cmsg_socket_printers[utype].min_len) {
+			tprints(", cmsg_data=");
+			cmsg_socket_printers[utype].printer(tcp, cmsg_data, data_len);
+		}
+		break;
+	case SOL_IP:
+		printxval(ip_cmsg_types, cmsg_type, "IP_???");
+		if (utype < ARRAY_SIZE(cmsg_ip_printers)
+		    && cmsg_ip_printers[utype].printer
+		    && data_len >= cmsg_ip_printers[utype].min_len) {
+			tprints(", cmsg_data=");
+			cmsg_ip_printers[utype].printer(tcp, cmsg_data, data_len);
+		}
+		break;
+	default:
+		tprintf("%#x", cmsg_type);
+	}
+}
+
+static unsigned int
+get_optmem_max(void)
+{
+	static int optmem_max;
+
+	if (!optmem_max) {
+		if (read_int_from_file("/proc/sys/net/core/optmem_max",
+				       &optmem_max) || optmem_max <= 0) {
+			optmem_max = sizeof(long long) * (2 * IOV_MAX + 512);
+		} else {
+			optmem_max = (optmem_max + sizeof(long long) - 1)
+				     & ~(sizeof(long long) - 1);
+		}
+	}
+
+	return optmem_max;
+}
+
+static void
+decode_msg_control(struct tcb *tcp, unsigned long addr,
+		   const size_t in_control_len)
+{
+	if (!in_control_len)
+		return;
+	tprints(", msg_control=");
+
+	const size_t cmsg_size =
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+		(current_wordsize < sizeof(long)) ? sizeof(struct cmsghdr32) :
+#endif
+			sizeof(struct cmsghdr);
+
+	size_t control_len =
+		in_control_len > get_optmem_max()
+		? get_optmem_max() : in_control_len;
+	size_t buf_len = control_len;
+	char *buf = buf_len < cmsg_size ? NULL : malloc(buf_len);
+	if (!buf || umoven(tcp, addr, buf_len, buf) < 0) {
+		printaddr(addr);
+		free(buf);
+		return;
+	}
+
+	union_cmsghdr u = { .ptr = buf };
+
+	tprints("[");
+	while (buf_len >= cmsg_size) {
+		const size_t cmsg_len =
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+			(current_wordsize < sizeof(long)) ? u.cmsg32->cmsg_len :
+#endif
+				u.cmsg->cmsg_len;
+		const int cmsg_level =
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+			(current_wordsize < sizeof(long)) ? u.cmsg32->cmsg_level :
+#endif
+				u.cmsg->cmsg_level;
+		const int cmsg_type =
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+			(current_wordsize < sizeof(long)) ? u.cmsg32->cmsg_type :
+#endif
+				u.cmsg->cmsg_type;
+
+		if (u.ptr != buf)
+			tprints(", ");
+		tprintf("{cmsg_len=%lu, cmsg_level=", (unsigned long) cmsg_len);
+		printxval(socketlayers, cmsg_level, "SOL_???");
+		tprints(", cmsg_type=");
+
+		size_t len = cmsg_len > buf_len ? buf_len : cmsg_len;
+
+		print_cmsg_type_data(tcp, cmsg_level, cmsg_type,
+				     (const void *) (u.ptr + cmsg_size),
+				     len > cmsg_size ? len - cmsg_size: 0);
+		tprints("}");
+
+		if (len < cmsg_size) {
+			buf_len -= cmsg_size;
+			break;
+		}
+		len = (cmsg_len + current_wordsize - 1) &
+			(size_t) ~(current_wordsize - 1);
+		if (len >= buf_len) {
+			buf_len = 0;
+			break;
+		}
+		u.ptr += len;
+		buf_len -= len;
+	}
+	if (buf_len) {
+		tprints(", ");
+		printaddr(addr + (control_len - buf_len));
+	} else if (control_len < in_control_len) {
+		tprints(", ...");
+	}
+	tprints("]");
+	free(buf);
+}
+
+void
+print_struct_msghdr(struct tcb *tcp, const struct msghdr *msg,
+		    const int *const p_user_msg_namelen,
+		    const unsigned long data_size)
+{
+	const int msg_namelen =
+		p_user_msg_namelen && (int) msg->msg_namelen > *p_user_msg_namelen
+		? *p_user_msg_namelen : (int) msg->msg_namelen;
+
+	tprints("{msg_name=");
+	const int family =
+		decode_sockaddr(tcp, (long) msg->msg_name, msg_namelen);
+	const enum iov_decode decode =
+		(family == AF_NETLINK) ? IOV_DECODE_NETLINK : IOV_DECODE_STR;
+
+	tprints(", msg_namelen=");
+	if (p_user_msg_namelen && *p_user_msg_namelen != (int) msg->msg_namelen)
+		tprintf("%d->", *p_user_msg_namelen);
+	tprintf("%d", msg->msg_namelen);
+
+	tprints(", msg_iov=");
+
+	tprint_iov_upto(tcp, (unsigned long) msg->msg_iovlen,
+			(unsigned long) msg->msg_iov, decode, data_size);
+	tprintf(", msg_iovlen=%lu", (unsigned long) msg->msg_iovlen);
+
+	decode_msg_control(tcp, (unsigned long) msg->msg_control,
+			   msg->msg_controllen);
+	tprintf(", msg_controllen=%lu", (unsigned long) msg->msg_controllen);
+
+	tprints(", msg_flags=");
+	printflags(msg_flags, msg->msg_flags, "MSG_???");
+	tprints("}");
+}
+
+static bool
+fetch_msghdr_namelen(struct tcb *tcp, const long addr, int *const p_msg_namelen)
+{
+	struct msghdr msg;
+
+	if (addr && verbose(tcp) && fetch_struct_msghdr(tcp, addr, &msg)) {
+		*p_msg_namelen = msg.msg_namelen;
+		return true;
+	} else {
+		return false;
+	}
+}
+
+static void
+decode_msghdr(struct tcb *tcp, const int *const p_user_msg_namelen,
+	      const long addr, const unsigned long data_size)
+{
+	struct msghdr msg;
+
+	if (addr && verbose(tcp) && fetch_struct_msghdr(tcp, addr, &msg))
+		print_struct_msghdr(tcp, &msg, p_user_msg_namelen, data_size);
+	else
+		printaddr(addr);
+}
+
+void
+dumpiov_in_msghdr(struct tcb *tcp, long addr, unsigned long data_size)
+{
+	struct msghdr msg;
+
+	if (fetch_struct_msghdr(tcp, addr, &msg))
+		dumpiov_upto(tcp, msg.msg_iovlen, (long)msg.msg_iov, data_size);
+}
+
+SYS_FUNC(sendmsg)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	decode_msghdr(tcp, 0, tcp->u_arg[1], (unsigned long) -1L);
+	/* flags */
+	tprints(", ");
+	printflags(msg_flags, tcp->u_arg[2], "MSG_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(recvmsg)
+{
+	int msg_namelen;
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		if (fetch_msghdr_namelen(tcp, tcp->u_arg[1], &msg_namelen)) {
+			set_tcb_priv_ulong(tcp, msg_namelen);
+			return 0;
+		}
+		printaddr(tcp->u_arg[1]);
+	} else {
+		msg_namelen = get_tcb_priv_ulong(tcp);
+
+		if (syserror(tcp))
+			tprintf("{msg_namelen=%d}", msg_namelen);
+		else
+			decode_msghdr(tcp, &msg_namelen, tcp->u_arg[1],
+				      tcp->u_rval);
+	}
+
+	/* flags */
+	tprints(", ");
+	printflags(msg_flags, tcp->u_arg[2], "MSG_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/msghdr.h b/strace/msghdr.h
new file mode 100644
index 0000000..41a07d7
--- /dev/null
+++ b/strace/msghdr.h
@@ -0,0 +1,17 @@
+#ifndef MSGHDR_H_
+# define MSGHDR_H_
+
+/* For definitions of struct msghdr and struct mmsghdr. */
+# include <sys/socket.h>
+
+# ifndef HAVE_STRUCT_MMSGHDR
+struct mmsghdr {
+	struct msghdr msg_hdr;
+	unsigned msg_len;
+};
+# endif
+
+struct tcb;
+extern void print_struct_msghdr(struct tcb *, const struct msghdr *, const int *, unsigned long);
+
+#endif /* MSGHDR_H_ */
diff --git a/strace/mtd.c b/strace/mtd.c
new file mode 100644
index 0000000..4442b1c
--- /dev/null
+++ b/strace/mtd.c
@@ -0,0 +1,363 @@
+/*
+ * Copyright (c) 2012 Mike Frysinger <vapier@gentoo.org>
+ *
+ * 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 DEF_MPERS_TYPE(struct_mtd_oob_buf)
+
+#include <linux/ioctl.h>
+
+/* The mtd api changes quickly, so we have to keep a local copy */
+#include <linux/version.h>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 3, 0)
+# include "mtd-abi.h"
+#else
+# include <mtd/mtd-abi.h>
+#endif
+
+typedef struct mtd_oob_buf struct_mtd_oob_buf;
+
+#include MPERS_DEFS
+
+#include "xlat/mtd_mode_options.h"
+#include "xlat/mtd_file_mode_options.h"
+#include "xlat/mtd_type_options.h"
+#include "xlat/mtd_flags_options.h"
+#include "xlat/mtd_otp_options.h"
+#include "xlat/mtd_nandecc_options.h"
+
+static void
+decode_erase_info_user(struct tcb *tcp, const long addr)
+{
+	struct erase_info_user einfo;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &einfo))
+		return;
+
+	tprintf("{start=%#x, length=%#x}", einfo.start, einfo.length);
+}
+
+static void
+decode_erase_info_user64(struct tcb *tcp, const long addr)
+{
+	struct erase_info_user64 einfo64;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &einfo64))
+		return;
+
+	tprintf("{start=%#" PRIx64 ", length=%#" PRIx64 "}",
+		(uint64_t) einfo64.start, (uint64_t) einfo64.length);
+}
+
+static void
+decode_mtd_oob_buf(struct tcb *tcp, const long addr)
+{
+	struct_mtd_oob_buf mbuf;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &mbuf))
+		return;
+
+	tprintf("{start=%#x, length=%#x, ptr=", mbuf.start, mbuf.length);
+	printaddr((unsigned long) mbuf.ptr);
+	tprints("}");
+}
+
+static void
+decode_mtd_oob_buf64(struct tcb *tcp, const long addr)
+{
+	struct mtd_oob_buf64 mbuf64;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &mbuf64))
+		return;
+
+	tprintf("{start=%#" PRIx64 ", length=%#x, usr_ptr=%#" PRIx64 "}",
+		(uint64_t) mbuf64.start, mbuf64.length,
+		(uint64_t) mbuf64.usr_ptr);
+}
+
+static void
+decode_otp_info(struct tcb *tcp, const long addr)
+{
+	struct otp_info oinfo;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &oinfo))
+		return;
+
+	tprintf("{start=%#x, length=%#x, locked=%u}",
+		oinfo.start, oinfo.length, oinfo.locked);
+}
+
+static void
+decode_otp_select(struct tcb *tcp, const long addr)
+{
+	unsigned int i;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &i))
+		return;
+
+	tprints("[");
+	printxval(mtd_otp_options, i, "MTD_OTP_???");
+	tprints("]");
+}
+
+static void
+decode_mtd_write_req(struct tcb *tcp, const long addr)
+{
+	struct mtd_write_req mreq;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &mreq))
+		return;
+
+	tprintf("{start=%#" PRIx64 ", len=%#" PRIx64
+		", ooblen=%#" PRIx64 ", usr_data=%#" PRIx64
+		", usr_oob=%#" PRIx64 ", mode=",
+		(uint64_t) mreq.start, (uint64_t) mreq.len,
+		(uint64_t) mreq.ooblen, (uint64_t) mreq.usr_data,
+		(uint64_t) mreq.usr_oob);
+	printxval(mtd_mode_options, mreq.mode, "MTD_OPS_???");
+	tprints("}");
+}
+
+static void
+decode_mtd_info_user(struct tcb *tcp, const long addr)
+{
+	struct mtd_info_user minfo;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &minfo))
+		return;
+
+	tprints("{type=");
+	printxval(mtd_type_options, minfo.type, "MTD_???");
+	tprints(", flags=");
+	printflags(mtd_flags_options, minfo.flags, "MTD_???");
+	tprintf(", size=%#x, erasesize=%#x, writesize=%#x, oobsize=%#x"
+		", padding=%#" PRIx64 "}",
+		minfo.size, minfo.erasesize, minfo.writesize, minfo.oobsize,
+		(uint64_t) minfo.padding);
+}
+
+static void
+decode_nand_oobinfo(struct tcb *tcp, const long addr)
+{
+	struct nand_oobinfo ninfo;
+	unsigned int i, j;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &ninfo))
+		return;
+
+	tprints("{useecc=");
+	printxval(mtd_nandecc_options, ninfo.useecc, "MTD_NANDECC_???");
+	tprintf(", eccbytes=%#x", ninfo.eccbytes);
+
+	tprints(", oobfree={");
+	for (i = 0; i < ARRAY_SIZE(ninfo.oobfree); ++i) {
+		if (i)
+			tprints("}, ");
+		tprints("{");
+		for (j = 0; j < ARRAY_SIZE(ninfo.oobfree[0]); ++j) {
+			if (j)
+				tprints(", ");
+			tprintf("%#x", ninfo.oobfree[i][j]);
+		}
+	}
+
+	tprints("}}, eccpos={");
+	for (i = 0; i < ARRAY_SIZE(ninfo.eccpos); ++i) {
+		if (i)
+			tprints(", ");
+		tprintf("%#x", ninfo.eccpos[i]);
+	}
+
+	tprints("}");
+}
+
+static void
+decode_nand_ecclayout_user(struct tcb *tcp, const long addr)
+{
+	struct nand_ecclayout_user nlay;
+	unsigned int i;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &nlay))
+		return;
+
+	tprintf("{eccbytes=%#x, eccpos={", nlay.eccbytes);
+	for (i = 0; i < ARRAY_SIZE(nlay.eccpos); ++i) {
+		if (i)
+			tprints(", ");
+		tprintf("%#x", nlay.eccpos[i]);
+	}
+	tprintf("}, oobavail=%#x, oobfree={", nlay.oobavail);
+	for (i = 0; i < ARRAY_SIZE(nlay.oobfree); ++i) {
+		if (i)
+			tprints(", ");
+		tprintf("{offset=%#x, length=%#x}",
+			nlay.oobfree[i].offset, nlay.oobfree[i].length);
+	}
+	tprints("}");
+}
+
+static void
+decode_mtd_ecc_stats(struct tcb *tcp, const long addr)
+{
+	struct mtd_ecc_stats es;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &es))
+		return;
+
+	tprintf("{corrected=%#x, failed=%#x, badblocks=%#x, bbtblocks=%#x}",
+		es.corrected, es.failed, es.badblocks, es.bbtblocks);
+}
+
+MPERS_PRINTER_DECL(int, mtd_ioctl, struct tcb *tcp,
+		   const unsigned int code, const long arg)
+{
+	switch (code) {
+	case MEMERASE:
+	case MEMLOCK:
+	case MEMUNLOCK:
+	case MEMISLOCKED:
+		decode_erase_info_user(tcp, arg);
+		break;
+
+	case MEMERASE64:
+		decode_erase_info_user64(tcp, arg);
+		break;
+
+	case MEMWRITEOOB:
+	case MEMREADOOB:
+		decode_mtd_oob_buf(tcp, arg);
+		break;
+
+	case MEMWRITEOOB64:
+	case MEMREADOOB64:
+		decode_mtd_oob_buf64(tcp, arg);
+		break;
+
+	case MEMWRITE:
+		decode_mtd_write_req(tcp, arg);
+		break;
+
+	case OTPGETREGIONINFO:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case OTPLOCK:
+		decode_otp_info(tcp, arg);
+		break;
+
+	case OTPSELECT:
+		decode_otp_select(tcp, arg);
+		break;
+
+	case MTDFILEMODE:
+		tprints(", ");
+		printxval_long(mtd_file_mode_options, arg, "MTD_FILE_MODE_???");
+		break;
+
+	case MEMGETBADBLOCK:
+	case MEMSETBADBLOCK:
+		tprints(", ");
+		printnum_int64(tcp, arg, "%" PRIu64);
+		break;
+
+	case MEMGETINFO:
+		if (entering(tcp))
+			return 0;
+		decode_mtd_info_user(tcp, arg);
+		break;
+
+	case MEMGETOOBSEL:
+		if (entering(tcp))
+			return 0;
+		decode_nand_oobinfo(tcp, arg);
+		break;
+
+	case ECCGETLAYOUT:
+		if (entering(tcp))
+			return 0;
+		decode_nand_ecclayout_user(tcp, arg);
+		break;
+
+	case ECCGETSTATS:
+		if (entering(tcp))
+			return 0;
+		decode_mtd_ecc_stats(tcp, arg);
+		break;
+
+	case OTPGETREGIONCOUNT:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_int(tcp, arg, "%u");
+		break;
+
+	case MEMGETREGIONCOUNT:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+
+	case MEMGETREGIONINFO:
+		if (entering(tcp)) {
+			struct region_info_user rinfo;
+
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &rinfo))
+				break;
+			tprintf("{regionindex=%#x", rinfo.regionindex);
+			return 0;
+		} else {
+			struct region_info_user rinfo;
+
+			if (!syserror(tcp) && !umove(tcp, arg, &rinfo))
+				tprintf(", offset=%#x"
+					", erasesize=%#x"
+					", numblocks=%#x}",
+					rinfo.offset,
+					rinfo.erasesize,
+					rinfo.numblocks);
+			tprints("}");
+			break;
+		}
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/mx32_funcs.h b/strace/mx32_funcs.h
new file mode 100644
index 0000000..9cea9ad
--- /dev/null
+++ b/strace/mx32_funcs.h
@@ -0,0 +1,19 @@
+#undef sys_readdir
+#define sys_readdir mx32_sys_readdir
+#undef sys_getdents
+#define sys_getdents mx32_sys_getdents
+#undef sys_msgctl
+#define sys_msgctl mx32_sys_msgctl
+#undef sys_shmctl
+#define sys_shmctl mx32_sys_shmctl
+#undef sys_time
+#define sys_time mx32_sys_time
+#undef sys_sigaltstack
+#define sys_sigaltstack mx32_sys_sigaltstack
+#undef sys_sysinfo
+#define sys_sysinfo mx32_sys_sysinfo
+#undef sys_times
+#define sys_times mx32_sys_times
+#undef sys_utime
+#define sys_utime mx32_sys_utime
+#include "sys_func.h"
diff --git a/strace/mx32_printer_decls.h b/strace/mx32_printer_decls.h
new file mode 100644
index 0000000..7463ec8
--- /dev/null
+++ b/strace/mx32_printer_decls.h
@@ -0,0 +1,31 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+extern int mx32_block_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int mx32_btrfs_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int mx32_evdev_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern _Bool mx32_fetch_seccomp_fprog(struct tcb *tcp, const long addr, void *p);
+extern _Bool mx32_fetch_struct_flock(struct tcb *tcp, const long addr, void *p);
+extern _Bool mx32_fetch_struct_flock64(struct tcb *tcp, const long addr, void *p);
+extern int mx32_fetch_struct_mmsghdr(struct tcb *tcp, const unsigned long addr, void *p);
+extern unsigned int mx32_sizeof_struct_mmsghdr(void);
+extern int mx32_fetch_struct_msghdr(struct tcb *tcp, const unsigned long addr, void *p);
+extern _Bool mx32_fetch_struct_statfs(struct tcb *tcp, const long addr, struct strace_statfs *p);
+extern _Bool mx32_fetch_struct_statfs64(struct tcb *tcp, const long addr, const unsigned long size, struct strace_statfs *p);
+extern int mx32_hdio_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int mx32_mtd_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern void mx32_printmqattr(struct tcb *tcp, const long addr);
+extern void mx32_tprint_msgbuf(struct tcb *tcp, const long addr, const unsigned long count);
+extern void mx32_print_sigevent(struct tcb *tcp, const long addr);
+extern void mx32_print_timespec(struct tcb *tcp, const long addr);
+extern const char * mx32_sprint_timespec(struct tcb *tcp, const long addr);
+extern void mx32_print_timespec_utime_pair(struct tcb *tcp, const long addr);
+extern void mx32_print_itimerspec(struct tcb *tcp, const long addr);
+extern void mx32_print_timeval(struct tcb *tcp, const long addr);
+extern void mx32_print_timeval_pair(struct tcb *tcp, const long addr);
+extern const char * mx32_sprint_timeval(struct tcb *tcp, const long addr);
+extern void mx32_print_itimerval(struct tcb *tcp, const long addr);
+extern int mx32_print_timex(struct tcb *tcp, const long addr);
+extern void mx32_printrusage(struct tcb *tcp, long addr);
+extern void mx32_printsiginfo_at(struct tcb *tcp, long addr);
+extern void mx32_print_siginfo_array(struct tcb *tcp, unsigned long addr, unsigned long len);
+extern int mx32_rtc_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int mx32_v4l2_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
diff --git a/strace/mx32_printer_defs.h b/strace/mx32_printer_defs.h
new file mode 100644
index 0000000..eb34dd6
--- /dev/null
+++ b/strace/mx32_printer_defs.h
@@ -0,0 +1,31 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+.block_ioctl = mx32_block_ioctl,
+.btrfs_ioctl = mx32_btrfs_ioctl,
+.evdev_ioctl = mx32_evdev_ioctl,
+.fetch_seccomp_fprog = mx32_fetch_seccomp_fprog,
+.fetch_struct_flock = mx32_fetch_struct_flock,
+.fetch_struct_flock64 = mx32_fetch_struct_flock64,
+.fetch_struct_mmsghdr = mx32_fetch_struct_mmsghdr,
+.sizeof_struct_mmsghdr = mx32_sizeof_struct_mmsghdr,
+.fetch_struct_msghdr = mx32_fetch_struct_msghdr,
+.fetch_struct_statfs = mx32_fetch_struct_statfs,
+.fetch_struct_statfs64 = mx32_fetch_struct_statfs64,
+.hdio_ioctl = mx32_hdio_ioctl,
+.mtd_ioctl = mx32_mtd_ioctl,
+.printmqattr = mx32_printmqattr,
+.tprint_msgbuf = mx32_tprint_msgbuf,
+.print_sigevent = mx32_print_sigevent,
+.print_timespec = mx32_print_timespec,
+.sprint_timespec = mx32_sprint_timespec,
+.print_timespec_utime_pair = mx32_print_timespec_utime_pair,
+.print_itimerspec = mx32_print_itimerspec,
+.print_timeval = mx32_print_timeval,
+.print_timeval_pair = mx32_print_timeval_pair,
+.sprint_timeval = mx32_sprint_timeval,
+.print_itimerval = mx32_print_itimerval,
+.print_timex = mx32_print_timex,
+.printrusage = mx32_printrusage,
+.printsiginfo_at = mx32_printsiginfo_at,
+.print_siginfo_array = mx32_print_siginfo_array,
+.rtc_ioctl = mx32_rtc_ioctl,
+.v4l2_ioctl = mx32_v4l2_ioctl,
diff --git a/strace/mx32_type_defs.h b/strace/mx32_type_defs.h
new file mode 100644
index 0000000..31f10a8
--- /dev/null
+++ b/strace/mx32_type_defs.h
@@ -0,0 +1,127 @@
+#ifdef MPERS_mx32_struct_blk_user_trace_setup
+# define struct_blk_user_trace_setup MPERS_mx32_struct_blk_user_trace_setup
+#endif
+#ifdef MPERS_mx32_struct_blkpg_ioctl_arg
+# define struct_blkpg_ioctl_arg MPERS_mx32_struct_blkpg_ioctl_arg
+#endif
+#ifdef MPERS_mx32_struct_blkpg_partition
+# define struct_blkpg_partition MPERS_mx32_struct_blkpg_partition
+#endif
+#ifdef MPERS_mx32_struct_btrfs_ioctl_dev_replace_args
+# define struct_btrfs_ioctl_dev_replace_args MPERS_mx32_struct_btrfs_ioctl_dev_replace_args
+#endif
+#ifdef MPERS_mx32_struct_btrfs_ioctl_send_args
+# define struct_btrfs_ioctl_send_args MPERS_mx32_struct_btrfs_ioctl_send_args
+#endif
+#ifdef MPERS_mx32_struct_btrfs_ioctl_received_subvol_args
+# define struct_btrfs_ioctl_received_subvol_args MPERS_mx32_struct_btrfs_ioctl_received_subvol_args
+#endif
+#ifdef MPERS_mx32_kernel_dirent
+# define kernel_dirent MPERS_mx32_kernel_dirent
+#endif
+#ifdef MPERS_mx32_struct_ff_effect
+# define struct_ff_effect MPERS_mx32_struct_ff_effect
+#endif
+#ifdef MPERS_mx32_seccomp_fprog_t
+# define seccomp_fprog_t MPERS_mx32_seccomp_fprog_t
+#endif
+#ifdef MPERS_mx32_struct_flock
+# define struct_flock MPERS_mx32_struct_flock
+#endif
+#ifdef MPERS_mx32_struct_flock64
+# define struct_flock64 MPERS_mx32_struct_flock64
+#endif
+#ifdef MPERS_mx32_struct_mmsghdr
+# define struct_mmsghdr MPERS_mx32_struct_mmsghdr
+#endif
+#ifdef MPERS_mx32_struct_msghdr
+# define struct_msghdr MPERS_mx32_struct_msghdr
+#endif
+#ifdef MPERS_mx32_struct_statfs
+# define struct_statfs MPERS_mx32_struct_statfs
+#endif
+#ifdef MPERS_mx32_struct_statfs64
+# define struct_statfs64 MPERS_mx32_struct_statfs64
+#endif
+#ifdef MPERS_mx32_struct_hd_geometry
+# define struct_hd_geometry MPERS_mx32_struct_hd_geometry
+#endif
+#ifdef MPERS_mx32_msqid_ds_t
+# define msqid_ds_t MPERS_mx32_msqid_ds_t
+#endif
+#ifdef MPERS_mx32_shmid_ds_t
+# define shmid_ds_t MPERS_mx32_shmid_ds_t
+#endif
+#ifdef MPERS_mx32_struct_mtd_oob_buf
+# define struct_mtd_oob_buf MPERS_mx32_struct_mtd_oob_buf
+#endif
+#ifdef MPERS_mx32_mq_attr_t
+# define mq_attr_t MPERS_mx32_mq_attr_t
+#endif
+#ifdef MPERS_mx32_msgbuf_t
+# define msgbuf_t MPERS_mx32_msgbuf_t
+#endif
+#ifdef MPERS_mx32_struct_sigevent
+# define struct_sigevent MPERS_mx32_struct_sigevent
+#endif
+#ifdef MPERS_mx32_time_t
+# define time_t MPERS_mx32_time_t
+#endif
+#ifdef MPERS_mx32_timespec_t
+# define timespec_t MPERS_mx32_timespec_t
+#endif
+#ifdef MPERS_mx32_timeval_t
+# define timeval_t MPERS_mx32_timeval_t
+#endif
+#ifdef MPERS_mx32_struct_timex
+# define struct_timex MPERS_mx32_struct_timex
+#endif
+#ifdef MPERS_mx32_rusage_t
+# define rusage_t MPERS_mx32_rusage_t
+#endif
+#ifdef MPERS_mx32_siginfo_t
+# define siginfo_t MPERS_mx32_siginfo_t
+#endif
+#ifdef MPERS_mx32_struct_rtc_pll_info
+# define struct_rtc_pll_info MPERS_mx32_struct_rtc_pll_info
+#endif
+#ifdef MPERS_mx32_stack_t
+# define stack_t MPERS_mx32_stack_t
+#endif
+#ifdef MPERS_mx32_sysinfo_t
+# define sysinfo_t MPERS_mx32_sysinfo_t
+#endif
+#ifdef MPERS_mx32_tms_t
+# define tms_t MPERS_mx32_tms_t
+#endif
+#ifdef MPERS_mx32_utimbuf_t
+# define utimbuf_t MPERS_mx32_utimbuf_t
+#endif
+#ifdef MPERS_mx32_struct_v4l2_buffer
+# define struct_v4l2_buffer MPERS_mx32_struct_v4l2_buffer
+#endif
+#ifdef MPERS_mx32_struct_v4l2_create_buffers
+# define struct_v4l2_create_buffers MPERS_mx32_struct_v4l2_create_buffers
+#endif
+#ifdef MPERS_mx32_struct_v4l2_ext_control
+# define struct_v4l2_ext_control MPERS_mx32_struct_v4l2_ext_control
+#endif
+#ifdef MPERS_mx32_struct_v4l2_ext_controls
+# define struct_v4l2_ext_controls MPERS_mx32_struct_v4l2_ext_controls
+#endif
+#ifdef MPERS_mx32_struct_v4l2_format
+# define struct_v4l2_format MPERS_mx32_struct_v4l2_format
+#endif
+#ifdef MPERS_mx32_struct_v4l2_framebuffer
+# define struct_v4l2_framebuffer MPERS_mx32_struct_v4l2_framebuffer
+#endif
+#ifdef MPERS_mx32_struct_v4l2_input
+# define struct_v4l2_input MPERS_mx32_struct_v4l2_input
+#endif
+#ifdef MPERS_mx32_struct_v4l2_standard
+# define struct_v4l2_standard MPERS_mx32_struct_v4l2_standard
+#endif
+#undef MPERS_PRINTER_NAME
+#define MPERS_PRINTER_NAME(printer_name) printer_name
+#include "mx32_printer_decls.h"
+#include MPERS_mx32_IOCTL_MACROS
diff --git a/strace/native_defs.h b/strace/native_defs.h
new file mode 100644
index 0000000..cdc735e
--- /dev/null
+++ b/strace/native_defs.h
@@ -0,0 +1,4 @@
+#undef MPERS_PRINTER_NAME
+#define MPERS_PRINTER_NAME(printer_name) printer_name
+
+#include "native_printer_decls.h"
diff --git a/strace/native_printer_decls.h b/strace/native_printer_decls.h
new file mode 100644
index 0000000..14456ad
--- /dev/null
+++ b/strace/native_printer_decls.h
@@ -0,0 +1,31 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+extern int block_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int btrfs_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int evdev_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern _Bool fetch_seccomp_fprog(struct tcb *tcp, const long addr, void *p);
+extern _Bool fetch_struct_flock(struct tcb *tcp, const long addr, void *p);
+extern _Bool fetch_struct_flock64(struct tcb *tcp, const long addr, void *p);
+extern int fetch_struct_mmsghdr(struct tcb *tcp, const unsigned long addr, void *p);
+extern unsigned int sizeof_struct_mmsghdr(void);
+extern int fetch_struct_msghdr(struct tcb *tcp, const unsigned long addr, void *p);
+extern _Bool fetch_struct_statfs(struct tcb *tcp, const long addr, struct strace_statfs *p);
+extern _Bool fetch_struct_statfs64(struct tcb *tcp, const long addr, const unsigned long size, struct strace_statfs *p);
+extern int hdio_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int mtd_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern void printmqattr(struct tcb *tcp, const long addr);
+extern void tprint_msgbuf(struct tcb *tcp, const long addr, const unsigned long count);
+extern void print_sigevent(struct tcb *tcp, const long addr);
+extern void print_timespec(struct tcb *tcp, const long addr);
+extern const char * sprint_timespec(struct tcb *tcp, const long addr);
+extern void print_timespec_utime_pair(struct tcb *tcp, const long addr);
+extern void print_itimerspec(struct tcb *tcp, const long addr);
+extern void print_timeval(struct tcb *tcp, const long addr);
+extern void print_timeval_pair(struct tcb *tcp, const long addr);
+extern const char * sprint_timeval(struct tcb *tcp, const long addr);
+extern void print_itimerval(struct tcb *tcp, const long addr);
+extern int print_timex(struct tcb *tcp, const long addr);
+extern void printrusage(struct tcb *tcp, long addr);
+extern void printsiginfo_at(struct tcb *tcp, long addr);
+extern void print_siginfo_array(struct tcb *tcp, unsigned long addr, unsigned long len);
+extern int rtc_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
+extern int v4l2_ioctl(struct tcb *tcp, const unsigned int code, const long arg);
diff --git a/strace/native_printer_defs.h b/strace/native_printer_defs.h
new file mode 100644
index 0000000..470ca1f
--- /dev/null
+++ b/strace/native_printer_defs.h
@@ -0,0 +1,31 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+.block_ioctl = block_ioctl,
+.btrfs_ioctl = btrfs_ioctl,
+.evdev_ioctl = evdev_ioctl,
+.fetch_seccomp_fprog = fetch_seccomp_fprog,
+.fetch_struct_flock = fetch_struct_flock,
+.fetch_struct_flock64 = fetch_struct_flock64,
+.fetch_struct_mmsghdr = fetch_struct_mmsghdr,
+.sizeof_struct_mmsghdr = sizeof_struct_mmsghdr,
+.fetch_struct_msghdr = fetch_struct_msghdr,
+.fetch_struct_statfs = fetch_struct_statfs,
+.fetch_struct_statfs64 = fetch_struct_statfs64,
+.hdio_ioctl = hdio_ioctl,
+.mtd_ioctl = mtd_ioctl,
+.printmqattr = printmqattr,
+.tprint_msgbuf = tprint_msgbuf,
+.print_sigevent = print_sigevent,
+.print_timespec = print_timespec,
+.sprint_timespec = sprint_timespec,
+.print_timespec_utime_pair = print_timespec_utime_pair,
+.print_itimerspec = print_itimerspec,
+.print_timeval = print_timeval,
+.print_timeval_pair = print_timeval_pair,
+.sprint_timeval = sprint_timeval,
+.print_itimerval = print_itimerval,
+.print_timex = print_timex,
+.printrusage = printrusage,
+.printsiginfo_at = printsiginfo_at,
+.print_siginfo_array = print_siginfo_array,
+.rtc_ioctl = rtc_ioctl,
+.v4l2_ioctl = v4l2_ioctl,
diff --git a/strace/net.c b/strace/net.c
new file mode 100644
index 0000000..017764c
--- /dev/null
+++ b/strace/net.c
@@ -0,0 +1,855 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-2000 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <sys/stat.h>
+#include <sys/socket.h>
+#include <sys/uio.h>
+#include <sys/un.h>
+#include <netinet/in.h>
+#ifdef HAVE_NETINET_TCP_H
+# include <netinet/tcp.h>
+#endif
+#ifdef HAVE_NETINET_UDP_H
+# include <netinet/udp.h>
+#endif
+#ifdef HAVE_NETINET_SCTP_H
+# include <netinet/sctp.h>
+#endif
+#include <arpa/inet.h>
+#include <net/if.h>
+#include <asm/types.h>
+#ifdef HAVE_NETIPX_IPX_H
+# include <netipx/ipx.h>
+#else
+# include <linux/ipx.h>
+#endif
+
+#if defined(HAVE_LINUX_IP_VS_H)
+# include <linux/ip_vs.h>
+#endif
+#include <linux/netlink.h>
+#if defined(HAVE_LINUX_NETFILTER_ARP_ARP_TABLES_H)
+# include <linux/netfilter_arp/arp_tables.h>
+#endif
+#if defined(HAVE_LINUX_NETFILTER_BRIDGE_EBTABLES_H)
+# include <linux/netfilter_bridge/ebtables.h>
+#endif
+#if defined(HAVE_LINUX_NETFILTER_IPV4_IP_TABLES_H)
+# include <linux/netfilter_ipv4/ip_tables.h>
+#endif
+#if defined(HAVE_LINUX_NETFILTER_IPV6_IP6_TABLES_H)
+# include <linux/netfilter_ipv6/ip6_tables.h>
+#endif
+#include <linux/if_packet.h>
+#include <linux/icmp.h>
+
+#include "xlat/socktypes.h"
+#include "xlat/sock_type_flags.h"
+#ifndef SOCK_TYPE_MASK
+# define SOCK_TYPE_MASK 0xf
+#endif
+
+#include "xlat/socketlayers.h"
+
+#include "xlat/inet_protocols.h"
+
+#if !defined NETLINK_SOCK_DIAG && defined NETLINK_INET_DIAG
+# define NETLINK_SOCK_DIAG NETLINK_INET_DIAG
+#endif
+#include "xlat/netlink_protocols.h"
+
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+# include <bluetooth/bluetooth.h>
+# include "xlat/bt_protocols.h"
+#endif
+
+void
+print_ifindex(unsigned int ifindex)
+{
+#ifdef HAVE_IF_INDEXTONAME
+	char buf[IFNAMSIZ + 1];
+
+	if (if_indextoname(ifindex, buf)) {
+		tprints("if_nametoindex(");
+		print_quoted_string(buf, sizeof(buf), QUOTE_0_TERMINATED);
+		tprints(")");
+		return;
+	}
+#endif
+	tprintf("%u", ifindex);
+}
+
+static void
+decode_sockbuf(struct tcb *tcp, int fd, long addr, long addrlen)
+{
+
+	switch (verbose(tcp) ? getfdproto(tcp, fd) : SOCK_PROTO_UNKNOWN) {
+	case SOCK_PROTO_NETLINK:
+		decode_netlink(tcp, addr, addrlen);
+		break;
+	default:
+		printstr(tcp, addr, addrlen);
+	}
+}
+
+/*
+ * low bits of the socket type define real socket type,
+ * other bits are socket type flags.
+ */
+static void
+tprint_sock_type(unsigned int flags)
+{
+	const char *str = xlookup(socktypes, flags & SOCK_TYPE_MASK);
+
+	if (str) {
+		tprints(str);
+		flags &= ~SOCK_TYPE_MASK;
+		if (!flags)
+			return;
+		tprints("|");
+	}
+	printflags(sock_type_flags, flags, "SOCK_???");
+}
+
+SYS_FUNC(socket)
+{
+	printxval(addrfams, tcp->u_arg[0], "AF_???");
+	tprints(", ");
+	tprint_sock_type(tcp->u_arg[1]);
+	tprints(", ");
+	switch (tcp->u_arg[0]) {
+	case AF_INET:
+	case AF_INET6:
+		printxval(inet_protocols, tcp->u_arg[2], "IPPROTO_???");
+		break;
+
+	case AF_NETLINK:
+		printxval(netlink_protocols, tcp->u_arg[2], "NETLINK_???");
+		break;
+
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+	case AF_BLUETOOTH:
+		printxval(bt_protocols, tcp->u_arg[2], "BTPROTO_???");
+		break;
+#endif
+
+	default:
+		tprintf("%lu", tcp->u_arg[2]);
+		break;
+	}
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(bind)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	const int addrlen = tcp->u_arg[2];
+	decode_sockaddr(tcp, tcp->u_arg[1], addrlen);
+	tprintf(", %d", addrlen);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(listen)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	tprintf("%lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+static bool
+fetch_socklen(struct tcb *tcp, int *plen,
+	      const unsigned long sockaddr, const unsigned long socklen)
+{
+	return verbose(tcp) && sockaddr && socklen
+	       && umove(tcp, socklen, plen) == 0;
+}
+
+static int
+decode_sockname(struct tcb *tcp)
+{
+	int ulen, rlen;
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		if (fetch_socklen(tcp, &ulen, tcp->u_arg[1], tcp->u_arg[2])) {
+			set_tcb_priv_ulong(tcp, ulen);
+			return 0;
+		} else {
+			printaddr(tcp->u_arg[1]);
+			tprints(", ");
+			printaddr(tcp->u_arg[2]);
+			return RVAL_DECODED;
+		}
+	}
+
+	ulen = get_tcb_priv_ulong(tcp);
+
+	if (syserror(tcp) || umove(tcp, tcp->u_arg[2], &rlen) < 0) {
+		printaddr(tcp->u_arg[1]);
+		tprintf(", [%d]", ulen);
+	} else {
+		decode_sockaddr(tcp, tcp->u_arg[1], ulen > rlen ? rlen : ulen);
+		if (ulen != rlen)
+			tprintf(", [%d->%d]", ulen, rlen);
+		else
+			tprintf(", [%d]", rlen);
+	}
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(accept)
+{
+	return decode_sockname(tcp) | RVAL_FD;
+}
+
+SYS_FUNC(accept4)
+{
+	int rc = decode_sockname(tcp);
+
+	if (rc & RVAL_DECODED) {
+		tprints(", ");
+		printflags(sock_type_flags, tcp->u_arg[3], "SOCK_???");
+	}
+
+	return rc | RVAL_FD;
+}
+
+SYS_FUNC(send)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	decode_sockbuf(tcp, tcp->u_arg[0], tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu, ", tcp->u_arg[2]);
+	/* flags */
+	printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sendto)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	decode_sockbuf(tcp, tcp->u_arg[0], tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu, ", tcp->u_arg[2]);
+	/* flags */
+	printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+	/* to address */
+	const int addrlen = tcp->u_arg[5];
+	tprints(", ");
+	decode_sockaddr(tcp, tcp->u_arg[4], addrlen);
+	/* to length */
+	tprintf(", %d", addrlen);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(recv)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		if (syserror(tcp)) {
+			printaddr(tcp->u_arg[1]);
+		} else {
+			decode_sockbuf(tcp, tcp->u_arg[0], tcp->u_arg[1],
+				     tcp->u_rval);
+		}
+
+		tprintf(", %lu, ", tcp->u_arg[2]);
+		printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+	}
+	return 0;
+}
+
+SYS_FUNC(recvfrom)
+{
+	int ulen, rlen;
+
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		if (fetch_socklen(tcp, &ulen, tcp->u_arg[4], tcp->u_arg[5])) {
+			set_tcb_priv_ulong(tcp, ulen);
+		}
+	} else {
+		/* buf */
+		if (syserror(tcp)) {
+			printaddr(tcp->u_arg[1]);
+		} else {
+			decode_sockbuf(tcp, tcp->u_arg[0], tcp->u_arg[1],
+				     tcp->u_rval);
+		}
+		/* size */
+		tprintf(", %lu, ", tcp->u_arg[2]);
+		/* flags */
+		printflags(msg_flags, tcp->u_arg[3], "MSG_???");
+		tprints(", ");
+
+		ulen = get_tcb_priv_ulong(tcp);
+
+		if (!fetch_socklen(tcp, &rlen, tcp->u_arg[4], tcp->u_arg[5])) {
+			/* from address */
+			printaddr(tcp->u_arg[4]);
+			tprints(", ");
+			/* from length */
+			printaddr(tcp->u_arg[5]);
+			return 0;
+		}
+		if (syserror(tcp)) {
+			/* from address */
+			printaddr(tcp->u_arg[4]);
+			/* from length */
+			tprintf(", [%d]", ulen);
+			return 0;
+		}
+		/* from address */
+		decode_sockaddr(tcp, tcp->u_arg[4], ulen > rlen ? rlen : ulen);
+		/* from length */
+		if (ulen != rlen)
+			tprintf(", [%d->%d]", ulen, rlen);
+		else
+			tprintf(", [%d]", rlen);
+	}
+	return 0;
+}
+
+#include "xlat/shutdown_modes.h"
+
+SYS_FUNC(shutdown)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printxval(shutdown_modes, tcp->u_arg[1], "SHUT_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(getsockname)
+{
+	return decode_sockname(tcp);
+}
+
+static void
+printpair_fd(struct tcb *tcp, const int i0, const int i1)
+{
+	tprints("[");
+	printfd(tcp, i0);
+	tprints(", ");
+	printfd(tcp, i1);
+	tprints("]");
+}
+
+static void
+decode_pair_fd(struct tcb *tcp, const long addr)
+{
+	int pair[2];
+
+	if (umove_or_printaddr(tcp, addr, &pair))
+		return;
+
+	printpair_fd(tcp, pair[0], pair[1]);
+}
+
+static int
+do_pipe(struct tcb *tcp, int flags_arg)
+{
+	if (exiting(tcp)) {
+		decode_pair_fd(tcp, tcp->u_arg[0]);
+		if (flags_arg >= 0) {
+			tprints(", ");
+			printflags(open_mode_flags, tcp->u_arg[flags_arg], "O_???");
+		}
+	}
+	return 0;
+}
+
+SYS_FUNC(pipe)
+{
+#ifdef HAVE_GETRVAL2
+	if (exiting(tcp) && !syserror(tcp))
+		printpair_fd(tcp, tcp->u_rval, getrval2(tcp));
+	return 0;
+#else
+	return do_pipe(tcp, -1);
+#endif
+}
+
+SYS_FUNC(pipe2)
+{
+	return do_pipe(tcp, 1);
+}
+
+SYS_FUNC(socketpair)
+{
+	if (entering(tcp)) {
+		printxval(addrfams, tcp->u_arg[0], "AF_???");
+		tprints(", ");
+		tprint_sock_type(tcp->u_arg[1]);
+		tprintf(", %lu", tcp->u_arg[2]);
+	} else {
+		tprints(", ");
+		decode_pair_fd(tcp, tcp->u_arg[3]);
+	}
+	return 0;
+}
+
+#include "xlat/sockoptions.h"
+#include "xlat/sockipoptions.h"
+#include "xlat/getsockipoptions.h"
+#include "xlat/setsockipoptions.h"
+#include "xlat/sockipv6options.h"
+#include "xlat/getsockipv6options.h"
+#include "xlat/setsockipv6options.h"
+#include "xlat/sockipxoptions.h"
+#include "xlat/sockrawoptions.h"
+#include "xlat/sockpacketoptions.h"
+#include "xlat/socksctpoptions.h"
+#include "xlat/socktcpoptions.h"
+
+static void
+print_sockopt_fd_level_name(struct tcb *tcp, int fd, unsigned int level,
+			    unsigned int name, bool is_getsockopt)
+{
+	printfd(tcp, fd);
+	tprints(", ");
+	printxval(socketlayers, level, "SOL_??");
+	tprints(", ");
+
+	switch (level) {
+	case SOL_SOCKET:
+		printxval(sockoptions, name, "SO_???");
+		break;
+	case SOL_IP:
+		printxvals(name, "IP_???", sockipoptions,
+			is_getsockopt ? getsockipoptions : setsockipoptions, NULL);
+		break;
+	case SOL_IPV6:
+		printxvals(name, "IPV6_???", sockipv6options,
+			is_getsockopt ? getsockipv6options : setsockipv6options, NULL);
+		break;
+	case SOL_IPX:
+		printxval(sockipxoptions, name, "IPX_???");
+		break;
+	case SOL_PACKET:
+		printxval(sockpacketoptions, name, "PACKET_???");
+		break;
+	case SOL_TCP:
+		printxval(socktcpoptions, name, "TCP_???");
+		break;
+	case SOL_SCTP:
+		printxval(socksctpoptions, name, "SCTP_???");
+		break;
+	case SOL_RAW:
+		printxval(sockrawoptions, name, "RAW_???");
+		break;
+
+		/* Other SOL_* protocol levels still need work. */
+
+	default:
+		tprintf("%u", name);
+	}
+
+	tprints(", ");
+}
+
+static void
+print_linger(struct tcb *tcp, long addr, int len)
+{
+	struct linger linger;
+
+	if (len != sizeof(linger) ||
+	    umove(tcp, addr, &linger) < 0) {
+		printaddr(addr);
+		return;
+	}
+
+	tprintf("{onoff=%d, linger=%d}",
+		linger.l_onoff,
+		linger.l_linger);
+}
+
+#ifdef SO_PEERCRED
+static void
+print_ucred(struct tcb *tcp, long addr, int len)
+{
+	struct ucred uc;
+
+	if (len != sizeof(uc) ||
+	    umove(tcp, addr, &uc) < 0) {
+		printaddr(addr);
+	} else {
+		tprintf("{pid=%u, uid=%u, gid=%u}",
+			(unsigned) uc.pid,
+			(unsigned) uc.uid,
+			(unsigned) uc.gid);
+	}
+}
+#endif /* SO_PEERCRED */
+
+#ifdef PACKET_STATISTICS
+static void
+print_tpacket_stats(struct tcb *tcp, long addr, int len)
+{
+	struct tpacket_stats stats;
+
+	if (len != sizeof(stats) ||
+	    umove(tcp, addr, &stats) < 0) {
+		printaddr(addr);
+	} else {
+		tprintf("{packets=%u, drops=%u}",
+			stats.tp_packets,
+			stats.tp_drops);
+	}
+}
+#endif /* PACKET_STATISTICS */
+
+#include "xlat/icmpfilterflags.h"
+
+static void
+print_icmp_filter(struct tcb *tcp, const long addr, int len)
+{
+	struct icmp_filter filter = {};
+
+	if (len > (int) sizeof(filter))
+		len = sizeof(filter);
+	else if (len <= 0) {
+		printaddr(addr);
+		return;
+	}
+
+	if (umoven_or_printaddr(tcp, addr, len, &filter))
+		return;
+
+	tprints("~(");
+	printflags(icmpfilterflags, ~filter.data, "ICMP_???");
+	tprints(")");
+}
+
+static void
+print_getsockopt(struct tcb *tcp, unsigned int level, unsigned int name,
+		 long addr, int len)
+{
+	if (addr && verbose(tcp))
+	switch (level) {
+	case SOL_SOCKET:
+		switch (name) {
+		case SO_LINGER:
+			print_linger(tcp, addr, len);
+			goto done;
+#ifdef SO_PEERCRED
+		case SO_PEERCRED:
+			print_ucred(tcp, addr, len);
+			goto done;
+#endif
+		}
+		break;
+
+	case SOL_PACKET:
+		switch (name) {
+#ifdef PACKET_STATISTICS
+		case PACKET_STATISTICS:
+			print_tpacket_stats(tcp, addr, len);
+			goto done;
+#endif
+		}
+		break;
+
+	case SOL_RAW:
+		switch (name) {
+		case ICMP_FILTER:
+			print_icmp_filter(tcp, addr, len);
+			goto done;
+		}
+		break;
+	}
+
+	/* default arg printing */
+
+	if (verbose(tcp)) {
+		if (len == sizeof(int)) {
+			printnum_int(tcp, addr, "%d");
+		} else {
+			printstr(tcp, addr, len);
+		}
+	} else {
+		printaddr(addr);
+	}
+done:
+	tprintf(", [%d]", len);
+}
+
+SYS_FUNC(getsockopt)
+{
+	if (entering(tcp)) {
+		print_sockopt_fd_level_name(tcp, tcp->u_arg[0],
+					    tcp->u_arg[1], tcp->u_arg[2], true);
+	} else {
+		int len;
+
+		if (syserror(tcp) || umove(tcp, tcp->u_arg[4], &len) < 0) {
+			printaddr(tcp->u_arg[3]);
+			tprints(", ");
+			printaddr(tcp->u_arg[4]);
+		} else {
+			print_getsockopt(tcp, tcp->u_arg[1], tcp->u_arg[2],
+					 tcp->u_arg[3], len);
+		}
+	}
+	return 0;
+}
+
+#ifdef IP_ADD_MEMBERSHIP
+static void
+print_mreq(struct tcb *tcp, long addr, unsigned int len)
+{
+	struct ip_mreq mreq;
+
+	if (len < sizeof(mreq)) {
+		printstr(tcp, addr, len);
+		return;
+	}
+	if (umove_or_printaddr(tcp, addr, &mreq))
+		return;
+
+	tprints("{imr_multiaddr=inet_addr(");
+	print_quoted_string(inet_ntoa(mreq.imr_multiaddr),
+			    16, QUOTE_0_TERMINATED);
+	tprints("), imr_interface=inet_addr(");
+	print_quoted_string(inet_ntoa(mreq.imr_interface),
+			    16, QUOTE_0_TERMINATED);
+	tprints(")}");
+}
+#endif /* IP_ADD_MEMBERSHIP */
+
+#ifdef IPV6_ADD_MEMBERSHIP
+static void
+print_mreq6(struct tcb *tcp, long addr, unsigned int len)
+{
+	struct ipv6_mreq mreq;
+
+	if (len < sizeof(mreq))
+		goto fail;
+
+	if (umove_or_printaddr(tcp, addr, &mreq))
+		return;
+
+	const struct in6_addr *in6 = &mreq.ipv6mr_multiaddr;
+	char address[INET6_ADDRSTRLEN];
+
+	if (!inet_ntop(AF_INET6, in6, address, sizeof(address)))
+		goto fail;
+
+	tprints("{ipv6mr_multiaddr=inet_pton(");
+	print_quoted_string(address, sizeof(address), QUOTE_0_TERMINATED);
+	tprints("), ipv6mr_interface=");
+	print_ifindex(mreq.ipv6mr_interface);
+	tprints("}");
+	return;
+
+fail:
+	printstr(tcp, addr, len);
+}
+#endif /* IPV6_ADD_MEMBERSHIP */
+
+#ifdef MCAST_JOIN_GROUP
+static void
+print_group_req(struct tcb *tcp, long addr, int len)
+{
+	struct group_req greq;
+
+	if (len != sizeof(greq) ||
+	    umove(tcp, addr, &greq) < 0) {
+		printaddr(addr);
+		return;
+	}
+
+	tprintf("{gr_interface=%u, gr_group=", greq.gr_interface);
+	print_sockaddr(tcp, &greq.gr_group, sizeof(greq.gr_group));
+	tprintf("}");
+
+}
+#endif /* MCAST_JOIN_GROUP */
+
+#ifdef PACKET_RX_RING
+static void
+print_tpacket_req(struct tcb *tcp, long addr, int len)
+{
+	struct tpacket_req req;
+
+	if (len != sizeof(req) ||
+	    umove(tcp, addr, &req) < 0) {
+		printaddr(addr);
+	} else {
+		tprintf("{block_size=%u, block_nr=%u, "
+			"frame_size=%u, frame_nr=%u}",
+			req.tp_block_size,
+			req.tp_block_nr,
+			req.tp_frame_size,
+			req.tp_frame_nr);
+	}
+}
+#endif /* PACKET_RX_RING */
+
+#ifdef PACKET_ADD_MEMBERSHIP
+# include "xlat/packet_mreq_type.h"
+
+static void
+print_packet_mreq(struct tcb *tcp, long addr, int len)
+{
+	struct packet_mreq mreq;
+
+	if (len != sizeof(mreq) ||
+	    umove(tcp, addr, &mreq) < 0) {
+		printaddr(addr);
+	} else {
+		unsigned int i;
+
+		tprintf("{mr_ifindex=%u, mr_type=", mreq.mr_ifindex);
+		printxval(packet_mreq_type, mreq.mr_type, "PACKET_MR_???");
+		tprintf(", mr_alen=%u, mr_address=", mreq.mr_alen);
+		if (mreq.mr_alen > ARRAY_SIZE(mreq.mr_address))
+			mreq.mr_alen = ARRAY_SIZE(mreq.mr_address);
+		for (i = 0; i < mreq.mr_alen; ++i)
+			tprintf("%02x", mreq.mr_address[i]);
+		tprints("}");
+	}
+}
+#endif /* PACKET_ADD_MEMBERSHIP */
+
+static void
+print_setsockopt(struct tcb *tcp, unsigned int level, unsigned int name,
+		 long addr, int len)
+{
+	if (addr && verbose(tcp))
+	switch (level) {
+	case SOL_SOCKET:
+		switch (name) {
+		case SO_LINGER:
+			print_linger(tcp, addr, len);
+			goto done;
+		}
+		break;
+
+	case SOL_IP:
+		switch (name) {
+#ifdef IP_ADD_MEMBERSHIP
+		case IP_ADD_MEMBERSHIP:
+		case IP_DROP_MEMBERSHIP:
+			print_mreq(tcp, addr, len);
+			goto done;
+#endif /* IP_ADD_MEMBERSHIP */
+#ifdef MCAST_JOIN_GROUP
+		case MCAST_JOIN_GROUP:
+		case MCAST_LEAVE_GROUP:
+			print_group_req(tcp, addr, len);
+			goto done;
+#endif /* MCAST_JOIN_GROUP */
+		}
+		break;
+
+	case SOL_IPV6:
+		switch (name) {
+#ifdef IPV6_ADD_MEMBERSHIP
+		case IPV6_ADD_MEMBERSHIP:
+		case IPV6_DROP_MEMBERSHIP:
+# ifdef IPV6_JOIN_ANYCAST
+		case IPV6_JOIN_ANYCAST:
+# endif
+# ifdef IPV6_LEAVE_ANYCAST
+		case IPV6_LEAVE_ANYCAST:
+# endif
+			print_mreq6(tcp, addr, len);
+			goto done;
+#endif /* IPV6_ADD_MEMBERSHIP */
+		}
+		break;
+
+	case SOL_PACKET:
+		switch (name) {
+#ifdef PACKET_RX_RING
+		case PACKET_RX_RING:
+# ifdef PACKET_TX_RING
+		case PACKET_TX_RING:
+# endif
+			print_tpacket_req(tcp, addr, len);
+			goto done;
+#endif /* PACKET_RX_RING */
+#ifdef PACKET_ADD_MEMBERSHIP
+		case PACKET_ADD_MEMBERSHIP:
+		case PACKET_DROP_MEMBERSHIP:
+			print_packet_mreq(tcp, addr, len);
+			goto done;
+#endif /* PACKET_ADD_MEMBERSHIP */
+		}
+		break;
+
+	case SOL_RAW:
+		switch (name) {
+		case ICMP_FILTER:
+			print_icmp_filter(tcp, addr, len);
+			goto done;
+		}
+		break;
+	}
+
+	/* default arg printing */
+
+	if (verbose(tcp)) {
+		if (len == sizeof(int)) {
+			printnum_int(tcp, addr, "%d");
+		} else {
+			printstr(tcp, addr, len);
+		}
+	} else {
+		printaddr(addr);
+	}
+done:
+	tprintf(", %d", len);
+}
+
+SYS_FUNC(setsockopt)
+{
+	print_sockopt_fd_level_name(tcp, tcp->u_arg[0],
+				    tcp->u_arg[1], tcp->u_arg[2], false);
+	print_setsockopt(tcp, tcp->u_arg[1], tcp->u_arg[2],
+			 tcp->u_arg[3], tcp->u_arg[4]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/netlink.c b/strace/netlink.c
new file mode 100644
index 0000000..71573d4
--- /dev/null
+++ b/strace/netlink.c
@@ -0,0 +1,132 @@
+/*
+ * Copyright (c) 2016 Fabien Siron <fabien.siron@epita.fr>
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sys/socket.h>
+#include <linux/netlink.h>
+#include "xlat/netlink_flags.h"
+#include "xlat/netlink_types.h"
+
+/*
+ * Fetch a struct nlmsghdr from the given address.
+ */
+static bool
+fetch_nlmsghdr(struct tcb *tcp, struct nlmsghdr *nlmsghdr,
+	       const unsigned long addr, const unsigned long len)
+{
+	if (len < sizeof(struct nlmsghdr)) {
+		printstr(tcp, addr, len);
+		return false;
+	}
+
+	if (umove_or_printaddr(tcp, addr, nlmsghdr))
+		return false;
+
+	return true;
+}
+
+static void
+print_nlmsghdr(struct tcb *tcp, const struct nlmsghdr *const nlmsghdr)
+{
+	/* print the whole structure regardless of its nlmsg_len */
+
+	tprintf("{len=%u, type=", nlmsghdr->nlmsg_len);
+
+	printxval(netlink_types, nlmsghdr->nlmsg_type, "NLMSG_???");
+
+	tprints(", flags=");
+	printflags(netlink_flags, nlmsghdr->nlmsg_flags, "NLM_F_???");
+
+	tprintf(", seq=%u, pid=%u}", nlmsghdr->nlmsg_seq,
+		nlmsghdr->nlmsg_pid);
+}
+
+static void
+decode_nlmsghdr_with_payload(struct tcb *tcp,
+			     const struct nlmsghdr *const nlmsghdr,
+			     const unsigned long addr,
+			     const unsigned long len)
+{
+	tprints("{");
+
+	print_nlmsghdr(tcp, nlmsghdr);
+
+	unsigned long nlmsg_len =
+		nlmsghdr->nlmsg_len > len ? len : nlmsghdr->nlmsg_len;
+	if (nlmsg_len > sizeof(struct nlmsghdr)) {
+		tprints(", ");
+
+		printstr(tcp, addr + sizeof(struct nlmsghdr),
+			 nlmsg_len - sizeof(struct nlmsghdr));
+	}
+
+	tprints("}");
+}
+
+void
+decode_netlink(struct tcb *tcp, unsigned long addr, unsigned long len)
+{
+	struct nlmsghdr nlmsghdr;
+	bool print_array = false;
+	unsigned int elt;
+
+	for (elt = 0; fetch_nlmsghdr(tcp, &nlmsghdr, addr, len); elt++) {
+		if (abbrev(tcp) && elt == max_strlen) {
+			tprints("...");
+			break;
+		}
+
+		unsigned long nlmsg_len = NLMSG_ALIGN(nlmsghdr.nlmsg_len);
+		unsigned long next_addr = 0, next_len = 0;
+
+		if (nlmsghdr.nlmsg_len >= sizeof(struct nlmsghdr)) {
+			next_len = (len >= nlmsg_len) ? len - nlmsg_len : 0;
+
+			if (next_len && addr + nlmsg_len > addr)
+				next_addr = addr + nlmsg_len;
+		}
+
+		if (!print_array && next_addr) {
+			tprints("[");
+			print_array = true;
+		}
+
+		decode_nlmsghdr_with_payload(tcp, &nlmsghdr, addr, len);
+
+		if (!next_addr)
+			break;
+
+		tprints(", ");
+		addr = next_addr;
+		len = next_len;
+	}
+
+	if (print_array) {
+		tprints("]");
+	}
+}
diff --git a/strace/numa.c b/strace/numa.c
new file mode 100644
index 0000000..b46fc7f
--- /dev/null
+++ b/strace/numa.c
@@ -0,0 +1,178 @@
+/*
+ * Copyright (c) 2003-2007 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+static bool
+print_node(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	if (elem_size < sizeof(long)) {
+		tprintf("%#0*x", (int) elem_size * 2 + 2,
+			* (unsigned int *) elem_buf);
+	} else {
+		tprintf("%#0*lx", (int) elem_size * 2 + 2,
+			* (unsigned long *) elem_buf);
+	}
+
+	return true;
+}
+
+static void
+print_nodemask(struct tcb *tcp, unsigned long addr, unsigned long maxnodes)
+{
+	const unsigned long nmemb =
+		(maxnodes + 8 * current_wordsize - 2) / (8 * current_wordsize);
+
+	if (nmemb < maxnodes / (8 * current_wordsize) ||
+	    (maxnodes && !nmemb)) {
+		printaddr(addr);
+		return;
+	}
+
+	unsigned long buf;
+	print_array(tcp, addr, nmemb, &buf, current_wordsize,
+		    umoven_or_printaddr, print_node, 0);
+}
+
+SYS_FUNC(migrate_pages)
+{
+	tprintf("%d, %lu, ", (int) tcp->u_arg[0], tcp->u_arg[1]);
+	print_nodemask(tcp, tcp->u_arg[2], tcp->u_arg[1]);
+	tprints(", ");
+	print_nodemask(tcp, tcp->u_arg[3], tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/policies.h"
+#include "xlat/mbindflags.h"
+
+SYS_FUNC(mbind)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %lu, ", tcp->u_arg[1]);
+	printxval_long(policies, tcp->u_arg[2], "MPOL_???");
+	tprints(", ");
+	print_nodemask(tcp, tcp->u_arg[3], tcp->u_arg[4]);
+	tprintf(", %lu, ", tcp->u_arg[4]);
+	printflags(mbindflags, tcp->u_arg[5], "MPOL_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(set_mempolicy)
+{
+	printxval(policies, tcp->u_arg[0], "MPOL_???");
+	tprints(", ");
+	print_nodemask(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+#include "xlat/mempolicyflags.h"
+
+SYS_FUNC(get_mempolicy)
+{
+	if (exiting(tcp)) {
+		int pol;
+		if (!umove_or_printaddr(tcp, tcp->u_arg[0], &pol)) {
+			tprints("[");
+			printxval(policies, pol, "MPOL_???");
+			tprints("]");
+		}
+		tprints(", ");
+		print_nodemask(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		tprintf(", %lu, ", tcp->u_arg[2]);
+		printaddr(tcp->u_arg[3]);
+		tprints(", ");
+		printflags_long(mempolicyflags, tcp->u_arg[4], "MPOL_???");
+	}
+	return 0;
+}
+
+#include "xlat/move_pages_flags.h"
+
+static bool
+print_addr(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	unsigned long addr;
+
+	if (elem_size < sizeof(long)) {
+		addr = * (unsigned int *) elem_buf;
+	} else {
+		addr = * (unsigned long *) elem_buf;
+	}
+
+	printaddr(addr);
+
+	return true;
+}
+
+static bool
+print_status(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const int status = * (int *) elem_buf;
+
+	if (status < 0 && (unsigned) -status < nerrnos)
+		tprintf("%s", errnoent[-status]);
+	else
+		tprintf("%d", status);
+
+	return true;
+}
+
+static bool
+print_int(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	tprintf("%d", * (int *) elem_buf);
+
+	return true;
+}
+
+SYS_FUNC(move_pages)
+{
+	const unsigned long npages = tcp->u_arg[1];
+	long buf;
+
+	if (entering(tcp)) {
+		tprintf("%d, %lu, ", (int) tcp->u_arg[0], npages);
+		print_array(tcp, tcp->u_arg[2], npages, &buf, current_wordsize,
+			    umoven_or_printaddr, print_addr, 0);
+		tprints(", ");
+		print_array(tcp, tcp->u_arg[3], npages, &buf, sizeof(int),
+			    umoven_or_printaddr, print_int, 0);
+		tprints(", ");
+	} else {
+		print_array(tcp, tcp->u_arg[4], npages, &buf, sizeof(int),
+			    umoven_or_printaddr, print_status, 0);
+		tprints(", ");
+		printflags(move_pages_flags, tcp->u_arg[5], "MPOL_???");
+	}
+	return 0;
+}
diff --git a/strace/open.c b/strace/open.c
new file mode 100644
index 0000000..90dd10f
--- /dev/null
+++ b/strace/open.c
@@ -0,0 +1,150 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2007 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2007 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2009-2013 Denys Vlasenko <dvlasenk@redhat.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+
+#ifdef O_LARGEFILE
+# if O_LARGEFILE == 0          /* biarch platforms in 64-bit mode */
+#  undef O_LARGEFILE
+#  ifdef SPARC64
+#   define O_LARGEFILE 0x40000
+#  elif defined X86_64 || defined S390X
+#   define O_LARGEFILE 0100000
+#  endif
+# endif
+#endif
+
+#include "xlat/open_access_modes.h"
+#include "xlat/open_mode_flags.h"
+
+#ifndef AT_FDCWD
+# define AT_FDCWD                -100
+#endif
+
+/* The fd is an "int", so when decoding x86 on x86_64, we need to force sign
+ * extension to get the right value.  We do this by declaring fd as int here.
+ */
+void
+print_dirfd(struct tcb *tcp, int fd)
+{
+	if (fd == AT_FDCWD)
+		tprints("AT_FDCWD, ");
+	else {
+		printfd(tcp, fd);
+		tprints(", ");
+	}
+}
+
+/*
+ * low bits of the open(2) flags define access mode,
+ * other bits are real flags.
+ */
+const char *
+sprint_open_modes(unsigned int flags)
+{
+	static char outstr[(1 + ARRAY_SIZE(open_mode_flags)) * sizeof("O_LARGEFILE")];
+	char *p;
+	char sep;
+	const char *str;
+	const struct xlat *x;
+
+	sep = ' ';
+	p = stpcpy(outstr, "flags");
+	str = xlookup(open_access_modes, flags & 3);
+	if (str) {
+		*p++ = sep;
+		p = stpcpy(p, str);
+		flags &= ~3;
+		if (!flags)
+			return outstr;
+		sep = '|';
+	}
+
+	for (x = open_mode_flags; x->str; x++) {
+		if ((flags & x->val) == x->val) {
+			*p++ = sep;
+			p = stpcpy(p, x->str);
+			flags &= ~x->val;
+			if (!flags)
+				return outstr;
+			sep = '|';
+		}
+	}
+	/* flags is still nonzero */
+	*p++ = sep;
+	sprintf(p, "%#x", flags);
+	return outstr;
+}
+
+void
+tprint_open_modes(unsigned int flags)
+{
+	tprints(sprint_open_modes(flags) + sizeof("flags"));
+}
+
+static int
+decode_open(struct tcb *tcp, int offset)
+{
+	printpath(tcp, tcp->u_arg[offset]);
+	tprints(", ");
+	/* flags */
+	tprint_open_modes(tcp->u_arg[offset + 1]);
+	if (tcp->u_arg[offset + 1] & O_CREAT) {
+		/* mode */
+		tprintf(", %#lo", tcp->u_arg[offset + 2]);
+	}
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(open)
+{
+	return decode_open(tcp, 0);
+}
+
+SYS_FUNC(openat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	return decode_open(tcp, 1);
+}
+
+SYS_FUNC(creat)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprintf(", %#lo", tcp->u_arg[1]);
+
+	return RVAL_DECODED | RVAL_FD;
+}
diff --git a/strace/or1k_atomic.c b/strace/or1k_atomic.c
new file mode 100644
index 0000000..54d3a0d
--- /dev/null
+++ b/strace/or1k_atomic.c
@@ -0,0 +1,77 @@
+/*
+ * Copyright (c) 2013 Christian Svensson <blue@cmd.nu>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef OR1K
+
+#define OR1K_ATOMIC_SWAP        1
+#define OR1K_ATOMIC_CMPXCHG     2
+#define OR1K_ATOMIC_XCHG        3
+#define OR1K_ATOMIC_ADD         4
+#define OR1K_ATOMIC_DECPOS      5
+#define OR1K_ATOMIC_AND         6
+#define OR1K_ATOMIC_OR          7
+#define OR1K_ATOMIC_UMAX        8
+#define OR1K_ATOMIC_UMIN        9
+
+#include "xlat/atomic_ops.h"
+
+SYS_FUNC(or1k_atomic)
+{
+	printxval_long(atomic_ops, tcp->u_arg[0], "???");
+	switch(tcp->u_arg[0]) {
+	case OR1K_ATOMIC_SWAP:
+		tprintf(", 0x%lx, 0x%lx", tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+	case OR1K_ATOMIC_CMPXCHG:
+		tprintf(", 0x%lx, %#lx, %#lx", tcp->u_arg[1], tcp->u_arg[2],
+			tcp->u_arg[3]);
+		break;
+
+	case OR1K_ATOMIC_XCHG:
+	case OR1K_ATOMIC_ADD:
+	case OR1K_ATOMIC_AND:
+	case OR1K_ATOMIC_OR:
+	case OR1K_ATOMIC_UMAX:
+	case OR1K_ATOMIC_UMIN:
+		tprintf(", 0x%lx, %#lx", tcp->u_arg[1], tcp->u_arg[2]);
+		break;
+
+	case OR1K_ATOMIC_DECPOS:
+		tprintf(", 0x%lx", tcp->u_arg[1]);
+		break;
+
+	default:
+		break;
+	}
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+#endif /* OR1K */
diff --git a/strace/pathtrace.c b/strace/pathtrace.c
new file mode 100644
index 0000000..74dc3a0
--- /dev/null
+++ b/strace/pathtrace.c
@@ -0,0 +1,357 @@
+/*
+ * Copyright (c) 2011, Comtrol Corp.
+ * 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 <sys/param.h>
+#include <poll.h>
+
+#include "syscall.h"
+
+const char **paths_selected = NULL;
+static unsigned num_selected = 0;
+
+/*
+ * Return true if specified path matches one that we're tracing.
+ */
+static int
+pathmatch(const char *path)
+{
+	unsigned i;
+
+	for (i = 0; i < num_selected; ++i) {
+		if (strcmp(path, paths_selected[i]) == 0)
+			return 1;
+	}
+	return 0;
+}
+
+/*
+ * Return true if specified path (in user-space) matches.
+ */
+static int
+upathmatch(struct tcb *tcp, unsigned long upath)
+{
+	char path[PATH_MAX + 1];
+
+	return umovestr(tcp, upath, sizeof path, path) > 0 &&
+		pathmatch(path);
+}
+
+/*
+ * Return true if specified fd maps to a path we're tracing.
+ */
+static int
+fdmatch(struct tcb *tcp, int fd)
+{
+	char path[PATH_MAX + 1];
+	int n = getfdpath(tcp, fd, path, sizeof(path));
+
+	return n >= 0 && pathmatch(path);
+}
+
+/*
+ * Add a path to the set we're tracing.
+ * Specifying NULL will delete all paths.
+ */
+static void
+storepath(const char *path)
+{
+	unsigned i;
+
+	if (pathmatch(path))
+		return; /* already in table */
+
+	i = num_selected++;
+	paths_selected = xreallocarray(paths_selected, num_selected,
+				       sizeof(paths_selected[0]));
+	paths_selected[i] = path;
+}
+
+/*
+ * Get path associated with fd.
+ */
+int
+getfdpath(struct tcb *tcp, int fd, char *buf, unsigned bufsize)
+{
+	char linkpath[sizeof("/proc/%u/fd/%u") + 2 * sizeof(int)*3];
+	ssize_t n;
+
+	if (fd < 0)
+		return -1;
+
+	sprintf(linkpath, "/proc/%u/fd/%u", tcp->pid, fd);
+	n = readlink(linkpath, buf, bufsize - 1);
+	/*
+	 * NB: if buf is too small, readlink doesn't fail,
+	 * it returns truncated result (IOW: n == bufsize - 1).
+	 */
+	if (n >= 0)
+		buf[n] = '\0';
+	return n;
+}
+
+/*
+ * Add a path to the set we're tracing.  Also add the canonicalized
+ * version of the path.  Secifying NULL will delete all paths.
+ */
+void
+pathtrace_select(const char *path)
+{
+	char *rpath;
+
+	storepath(path);
+
+	rpath = realpath(path, NULL);
+
+	if (rpath == NULL)
+		return;
+
+	/* if realpath and specified path are same, we're done */
+	if (strcmp(path, rpath) == 0) {
+		free(rpath);
+		return;
+	}
+
+	error_msg("Requested path '%s' resolved into '%s'", path, rpath);
+	storepath(rpath);
+}
+
+/*
+ * Return true if syscall accesses a selected path
+ * (or if no paths have been specified for tracing).
+ */
+int
+pathtrace_match(struct tcb *tcp)
+{
+	const struct_sysent *s;
+
+	s = tcp->s_ent;
+
+	if (!(s->sys_flags & (TRACE_FILE | TRACE_DESC | TRACE_NETWORK)))
+		return 0;
+
+	/*
+	 * Check for special cases where we need to do something
+	 * other than test arg[0].
+	 */
+
+	switch (s->sen) {
+	case SEN_dup2:
+	case SEN_dup3:
+	case SEN_kexec_file_load:
+	case SEN_sendfile:
+	case SEN_sendfile64:
+	case SEN_tee:
+		/* fd, fd */
+		return fdmatch(tcp, tcp->u_arg[0]) ||
+			fdmatch(tcp, tcp->u_arg[1]);
+
+	case SEN_faccessat:
+	case SEN_fchmodat:
+	case SEN_fchownat:
+	case SEN_futimesat:
+	case SEN_inotify_add_watch:
+	case SEN_mkdirat:
+	case SEN_mknodat:
+	case SEN_name_to_handle_at:
+	case SEN_newfstatat:
+	case SEN_openat:
+	case SEN_readlinkat:
+	case SEN_unlinkat:
+	case SEN_utimensat:
+		/* fd, path */
+		return fdmatch(tcp, tcp->u_arg[0]) ||
+			upathmatch(tcp, tcp->u_arg[1]);
+
+	case SEN_link:
+	case SEN_mount:
+	case SEN_pivotroot:
+		/* path, path */
+		return upathmatch(tcp, tcp->u_arg[0]) ||
+			upathmatch(tcp, tcp->u_arg[1]);
+
+	case SEN_quotactl:
+		/* x, path */
+		return upathmatch(tcp, tcp->u_arg[1]);
+
+	case SEN_linkat:
+	case SEN_renameat2:
+	case SEN_renameat:
+		/* fd, path, fd, path */
+		return fdmatch(tcp, tcp->u_arg[0]) ||
+			fdmatch(tcp, tcp->u_arg[2]) ||
+			upathmatch(tcp, tcp->u_arg[1]) ||
+			upathmatch(tcp, tcp->u_arg[3]);
+
+	case SEN_old_mmap:
+#if defined(S390)
+	case SEN_old_mmap_pgoff:
+#endif
+	case SEN_mmap:
+	case SEN_mmap_4koff:
+	case SEN_mmap_pgoff:
+	case SEN_ARCH_mmap:
+		/* x, x, x, x, fd */
+		return fdmatch(tcp, tcp->u_arg[4]);
+
+	case SEN_symlinkat:
+		/* path, fd, path */
+		return fdmatch(tcp, tcp->u_arg[1]) ||
+			upathmatch(tcp, tcp->u_arg[0]) ||
+			upathmatch(tcp, tcp->u_arg[2]);
+
+	case SEN_copy_file_range:
+	case SEN_splice:
+		/* fd, x, fd, x, x, x */
+		return fdmatch(tcp, tcp->u_arg[0]) ||
+			fdmatch(tcp, tcp->u_arg[2]);
+
+	case SEN_epoll_ctl:
+		/* x, x, fd, x */
+		return fdmatch(tcp, tcp->u_arg[2]);
+
+
+	case SEN_fanotify_mark:
+		/* x, x, x, fd, path */
+		return fdmatch(tcp, tcp->u_arg[3]) ||
+			upathmatch(tcp, tcp->u_arg[4]);
+
+	case SEN_oldselect:
+	case SEN_pselect6:
+	case SEN_select:
+	{
+		int     i, j;
+		int     nfds;
+		long   *args, oldargs[5];
+		unsigned fdsize;
+		fd_set *fds;
+
+		args = tcp->u_arg;
+		if (SEN_oldselect == s->sen) {
+			if (umoven(tcp, tcp->u_arg[0], sizeof oldargs,
+				   oldargs) < 0)
+			{
+				error_msg("umoven() failed");
+				return 0;
+			}
+			args = oldargs;
+		}
+
+		/* Kernel truncates arg[0] to int, we do the same. */
+		nfds = (int) args[0];
+		/* Kernel rejects negative nfds, so we don't parse it either. */
+		if (nfds <= 0)
+			return 0;
+		/* Beware of select(2^31-1, NULL, NULL, NULL) and similar... */
+		if (nfds > 1024*1024)
+			nfds = 1024*1024;
+		fdsize = (((nfds + 7) / 8) + current_wordsize-1) & -current_wordsize;
+		fds = xmalloc(fdsize);
+
+		for (i = 1; i <= 3; ++i) {
+			if (args[i] == 0)
+				continue;
+			if (umoven(tcp, args[i], fdsize, fds) < 0) {
+				error_msg("umoven() failed");
+				continue;
+			}
+			for (j = 0;; j++) {
+				j = next_set_bit(fds, j, nfds);
+				if (j < 0)
+					break;
+				if (fdmatch(tcp, j)) {
+					free(fds);
+					return 1;
+				}
+			}
+		}
+		free(fds);
+		return 0;
+	}
+
+	case SEN_poll:
+	case SEN_ppoll:
+	{
+		struct pollfd fds;
+		unsigned nfds;
+		unsigned long start, cur, end;
+
+		start = tcp->u_arg[0];
+		nfds = tcp->u_arg[1];
+
+		end = start + sizeof(fds) * nfds;
+
+		if (nfds == 0 || end < start)
+			return 0;
+
+		for (cur = start; cur < end; cur += sizeof(fds))
+			if ((umoven(tcp, cur, sizeof fds, &fds) == 0)
+			    && fdmatch(tcp, fds.fd))
+				return 1;
+
+		return 0;
+	}
+
+	case SEN_bpf:
+	case SEN_epoll_create:
+	case SEN_epoll_create1:
+	case SEN_eventfd2:
+	case SEN_eventfd:
+	case SEN_fanotify_init:
+	case SEN_inotify_init1:
+	case SEN_memfd_create:
+	case SEN_perf_event_open:
+	case SEN_pipe:
+	case SEN_pipe2:
+	case SEN_printargs:
+	case SEN_socket:
+	case SEN_socketpair:
+	case SEN_timerfd_create:
+	case SEN_timerfd_gettime:
+	case SEN_timerfd_settime:
+	case SEN_userfaultfd:
+		/*
+		 * These have TRACE_FILE or TRACE_DESCRIPTOR or TRACE_NETWORK set,
+		 * but they don't have any file descriptor or path args to test.
+		 */
+		return 0;
+	}
+
+	/*
+	 * Our fallback position for calls that haven't already
+	 * been handled is to just check arg[0].
+	 */
+
+	if (s->sys_flags & TRACE_FILE)
+		return upathmatch(tcp, tcp->u_arg[0]);
+
+	if (s->sys_flags & (TRACE_DESC | TRACE_NETWORK))
+		return fdmatch(tcp, tcp->u_arg[0]);
+
+	return 0;
+}
diff --git a/strace/perf.c b/strace/perf.c
new file mode 100644
index 0000000..8ab58a0
--- /dev/null
+++ b/strace/perf.c
@@ -0,0 +1,47 @@
+/*
+ * Copyright (c) 2013 Ben Noordhuis <info@bnoordhuis.nl>
+ * Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_LINUX_PERF_EVENT_H
+# include <linux/perf_event.h>
+#endif
+
+#include "xlat/perf_event_open_flags.h"
+
+SYS_FUNC(perf_event_open)
+{
+	printaddr(tcp->u_arg[0]);
+	tprintf(", %d, %d, %d, ",
+		(int) tcp->u_arg[1],
+		(int) tcp->u_arg[2],
+		(int) tcp->u_arg[3]);
+	printflags_long(perf_event_open_flags, tcp->u_arg[4], "PERF_FLAG_???");
+
+	return RVAL_DECODED | RVAL_FD;
+}
diff --git a/strace/personality.c b/strace/personality.c
new file mode 100644
index 0000000..44ed5e3
--- /dev/null
+++ b/strace/personality.c
@@ -0,0 +1,69 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <linux/personality.h>
+#include "xlat/personality_types.h"
+#include "xlat/personality_flags.h"
+
+
+SYS_FUNC(personality)
+{
+	unsigned int pers;
+
+	if (entering(tcp)) {
+		pers = tcp->u_arg[0];
+		if (0xffffffff == pers) {
+			tprints("0xffffffff");
+		} else {
+			printxval(personality_types, pers & PER_MASK, "PER_???");
+			pers &= ~PER_MASK;
+			if (pers) {
+				tprints("|");
+				printflags(personality_flags, pers, NULL);
+			}
+		}
+		return 0;
+	}
+
+	if (syserror(tcp))
+		return 0;
+
+	pers = tcp->u_rval;
+	const char *type = xlookup(personality_types, pers & PER_MASK);
+	char *p;
+	static char outstr[1024];
+	if (type)
+		p = stpcpy(outstr, type);
+	else
+		p = outstr + sprintf(outstr, "%#x /* %s */", pers & PER_MASK, "PER_???");
+	pers &= ~PER_MASK;
+	if (pers)
+		strcpy(p, sprintflags("|", personality_flags, pers));
+	tcp->auxstr = outstr;
+	return RVAL_HEX | RVAL_STR;
+}
diff --git a/strace/poll.c b/strace/poll.c
new file mode 100644
index 0000000..b66c46d
--- /dev/null
+++ b/strace/poll.c
@@ -0,0 +1,186 @@
+/*
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <poll.h>
+
+#include "xlat/pollflags.h"
+
+static bool
+print_pollfd(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const struct pollfd *fds = elem_buf;
+
+	tprints("{fd=");
+	printfd(tcp, fds->fd);
+	if (fds->fd >= 0) {
+		tprints(", events=");
+		printflags(pollflags, (unsigned short) fds->events, "POLL???");
+	}
+	tprints("}");
+
+	return true;
+}
+
+static void
+decode_poll_entering(struct tcb *tcp)
+{
+	const unsigned long addr = tcp->u_arg[0];
+	const unsigned int nfds = tcp->u_arg[1];
+	struct pollfd fds;
+
+	print_array(tcp, addr, nfds, &fds, sizeof(fds),
+		    umoven_or_printaddr, print_pollfd, 0);
+	tprintf(", %u, ", nfds);
+}
+
+static int
+decode_poll_exiting(struct tcb *tcp, const long pts)
+{
+	struct pollfd fds;
+	const unsigned int nfds = tcp->u_arg[1];
+	const unsigned long size = sizeof(fds) * nfds;
+	const unsigned long start = tcp->u_arg[0];
+	const unsigned long end = start + size;
+	const unsigned long max_printed =
+		abbrev(tcp) ? max_strlen : (unsigned int) -1;
+	unsigned long printed, cur;
+
+	static char outstr[1024];
+	char *outptr;
+#define end_outstr (outstr + sizeof(outstr))
+
+	if (syserror(tcp))
+		return 0;
+	if (tcp->u_rval == 0) {
+		tcp->auxstr = "Timeout";
+		return RVAL_STR;
+	}
+
+	if (!verbose(tcp) || !start || !nfds ||
+	    size / sizeof(fds) != nfds || end < start)
+		return 0;
+
+	outptr = outstr;
+
+	for (printed = 0, cur = start; cur < end; cur += sizeof(fds)) {
+		if (umove(tcp, cur, &fds) < 0) {
+			if (outptr == outstr)
+				*outptr++ = '[';
+			else
+				outptr = stpcpy(outptr, ", ");
+			outptr += sprintf(outptr, "%#lx", cur);
+			break;
+		}
+		if (!fds.revents)
+			continue;
+		if (outptr == outstr)
+			*outptr++ = '[';
+		else
+			outptr = stpcpy(outptr, ", ");
+		if (printed >= max_printed) {
+			outptr = stpcpy(outptr, "...");
+			break;
+		}
+
+		static const char fmt[] = "{fd=%d, revents=";
+		char fdstr[sizeof(fmt) + sizeof(int) * 3];
+		sprintf(fdstr, fmt, fds.fd);
+
+		const char *flagstr = sprintflags("", pollflags,
+						  (unsigned short) fds.revents);
+
+		if (outptr + strlen(fdstr) + strlen(flagstr) + 1 >=
+		    end_outstr - (2 + 2 * sizeof(long) + sizeof(", ], ..."))) {
+			outptr = stpcpy(outptr, "...");
+			break;
+		}
+		outptr = stpcpy(outptr, fdstr);
+		outptr = stpcpy(outptr, flagstr);
+		*outptr++ = '}';
+		++printed;
+	}
+
+	if (outptr != outstr)
+		*outptr++ = ']';
+
+	*outptr = '\0';
+	if (pts) {
+		const char *str = sprint_timespec(tcp, pts);
+
+		if (outptr + sizeof(", left ") + strlen(str) < end_outstr) {
+			outptr = stpcpy(outptr, outptr == outstr ? "left " : ", left ");
+			outptr = stpcpy(outptr, str);
+		} else {
+			outptr = stpcpy(outptr, ", ...");
+		}
+	}
+
+	if (outptr == outstr)
+		return 0;
+
+	tcp->auxstr = outstr;
+	return RVAL_STR;
+#undef end_outstr
+}
+
+SYS_FUNC(poll)
+{
+	if (entering(tcp)) {
+		decode_poll_entering(tcp);
+		int timeout = tcp->u_arg[2];
+
+#ifdef INFTIM
+		if (INFTIM == timeout)
+			tprints("INFTIM");
+		else
+#endif
+			tprintf("%d", timeout);
+
+		return 0;
+	} else {
+		return decode_poll_exiting(tcp, 0);
+	}
+}
+
+SYS_FUNC(ppoll)
+{
+	if (entering(tcp)) {
+		decode_poll_entering(tcp);
+
+		print_timespec(tcp, tcp->u_arg[2]);
+		tprints(", ");
+		/* NB: kernel requires arg[4] == NSIG / 8 */
+		print_sigset_addr_len(tcp, tcp->u_arg[3], tcp->u_arg[4]);
+		tprintf(", %lu", tcp->u_arg[4]);
+
+		return 0;
+	} else {
+		return decode_poll_exiting(tcp, tcp->u_arg[2]);
+	}
+}
diff --git a/strace/prctl.c b/strace/prctl.c
new file mode 100644
index 0000000..cd51d4c
--- /dev/null
+++ b/strace/prctl.c
@@ -0,0 +1,337 @@
+/*
+ * Copyright (c) 1994-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-2000 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2007 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2008-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sys/prctl.h>
+
+#include "xlat/prctl_options.h"
+#include "xlat/pr_cap_ambient.h"
+#include "xlat/pr_mce_kill.h"
+#include "xlat/pr_mce_kill_policy.h"
+#include "xlat/pr_set_mm.h"
+#include "xlat/pr_tsc.h"
+#include "xlat/pr_unalign_flags.h"
+
+#ifndef TASK_COMM_LEN
+# define TASK_COMM_LEN 16
+#endif
+
+#ifdef HAVE_LINUX_SECCOMP_H
+# include <linux/seccomp.h>
+#endif
+#include "xlat/seccomp_mode.h"
+
+#ifdef HAVE_LINUX_SECUREBITS_H
+# include <linux/securebits.h>
+#endif
+#include "xlat/secbits.h"
+
+/* these constants are the same as in <linux/capability.h> */
+enum {
+#include "caps0.h"
+#include "caps1.h"
+};
+
+#include "xlat/cap.h"
+
+static void
+print_prctl_args(struct tcb *tcp, const unsigned int first)
+{
+	unsigned int i;
+
+	for (i = first; i < tcp->s_ent->nargs; ++i)
+		tprintf(", %#lx", tcp->u_arg[i]);
+}
+
+SYS_FUNC(prctl)
+{
+	const unsigned int option = tcp->u_arg[0];
+	unsigned int i;
+
+	if (entering(tcp))
+		printxval(prctl_options, option, "PR_???");
+
+	switch (option) {
+	case PR_GET_DUMPABLE:
+	case PR_GET_KEEPCAPS:
+	case PR_GET_SECCOMP:
+	case PR_GET_TIMERSLACK:
+	case PR_GET_TIMING:
+		return RVAL_DECODED;
+
+	case PR_GET_CHILD_SUBREAPER:
+	case PR_GET_ENDIAN:
+	case PR_GET_FPEMU:
+	case PR_GET_FPEXC:
+		if (entering(tcp))
+			tprints(", ");
+		else
+			printnum_int(tcp, tcp->u_arg[1], "%u");
+		break;
+
+	case PR_GET_NAME:
+		if (entering(tcp))
+			tprints(", ");
+		else {
+			if (syserror(tcp))
+				printaddr(tcp->u_arg[1]);
+			else
+				printstr(tcp, tcp->u_arg[1], -1);
+		}
+		break;
+
+	case PR_GET_PDEATHSIG:
+		if (entering(tcp))
+			tprints(", ");
+		else if (!umove_or_printaddr(tcp, tcp->u_arg[1], &i)) {
+			tprints("[");
+			tprints(signame(i));
+			tprints("]");
+		}
+		break;
+
+	case PR_GET_SECUREBITS:
+		if (entering(tcp))
+			break;
+		if (syserror(tcp) || tcp->u_rval == 0)
+			return 0;
+		tcp->auxstr = sprintflags("", secbits,
+					  (unsigned long) tcp->u_rval);
+		return RVAL_STR;
+
+	case PR_GET_TID_ADDRESS:
+		if (entering(tcp))
+			tprints(", ");
+		else
+			printnum_ptr(tcp, tcp->u_arg[1]);
+		break;
+
+	case PR_GET_TSC:
+		if (entering(tcp))
+			tprints(", ");
+		else if (!umove_or_printaddr(tcp, tcp->u_arg[1], &i)) {
+			tprints("[");
+			printxval(pr_tsc, i, "PR_TSC_???");
+			tprints("]");
+		}
+		break;
+
+	case PR_GET_UNALIGN:
+		if (entering(tcp))
+			tprints(", ");
+		else if (!umove_or_printaddr(tcp, tcp->u_arg[1], &i)) {
+			tprints("[");
+			printflags(pr_unalign_flags, i, "PR_UNALIGN_???");
+			tprints("]");
+		}
+		break;
+
+	/* PR_TASK_PERF_EVENTS_* take no arguments. */
+	case PR_TASK_PERF_EVENTS_DISABLE:
+	case PR_TASK_PERF_EVENTS_ENABLE:
+		return RVAL_DECODED;
+
+	case PR_SET_CHILD_SUBREAPER:
+	case PR_SET_DUMPABLE:
+	case PR_SET_ENDIAN:
+	case PR_SET_FPEMU:
+	case PR_SET_FPEXC:
+	case PR_SET_KEEPCAPS:
+	case PR_SET_TIMING:
+		tprintf(", %lu", tcp->u_arg[1]);
+		return RVAL_DECODED;
+
+	case PR_CAPBSET_DROP:
+	case PR_CAPBSET_READ:
+		tprints(", ");
+		printxval_long(cap, tcp->u_arg[1], "CAP_???");
+		return RVAL_DECODED;
+
+	case PR_CAP_AMBIENT:
+		tprints(", ");
+		printxval_long(pr_cap_ambient, tcp->u_arg[1],
+			       "PR_CAP_AMBIENT_???");
+		switch (tcp->u_arg[1]) {
+		case PR_CAP_AMBIENT_RAISE:
+		case PR_CAP_AMBIENT_LOWER:
+		case PR_CAP_AMBIENT_IS_SET:
+			tprints(", ");
+			printxval_long(cap, tcp->u_arg[2], "CAP_???");
+			print_prctl_args(tcp, 3);
+			break;
+		default:
+			print_prctl_args(tcp, 2);
+			break;
+		}
+		return RVAL_DECODED;
+
+	case PR_MCE_KILL:
+		tprints(", ");
+		printxval_long(pr_mce_kill, tcp->u_arg[1], "PR_MCE_KILL_???");
+		tprints(", ");
+		if (PR_MCE_KILL_SET == tcp->u_arg[1])
+			printxval_long(pr_mce_kill_policy, tcp->u_arg[2],
+				   "PR_MCE_KILL_???");
+		else
+			tprintf("%#lx", tcp->u_arg[2]);
+		print_prctl_args(tcp, 3);
+		return RVAL_DECODED;
+
+	case PR_SET_NAME:
+		tprints(", ");
+		printstr(tcp, tcp->u_arg[1], TASK_COMM_LEN);
+		return RVAL_DECODED;
+
+#ifdef __ANDROID__
+# ifndef PR_SET_VMA_ANON_NAME
+#  define PR_SET_VMA_ANON_NAME    0
+# endif
+	case PR_SET_VMA:
+		if (tcp->u_arg[1] == PR_SET_VMA_ANON_NAME) {
+			tprintf(", PR_SET_VMA_ANON_NAME, %#lx", tcp->u_arg[2]);
+			tprintf(", %lu, ", tcp->u_arg[3]);
+			printstr(tcp, tcp->u_arg[4], -1);
+		} else {
+			/* There are no other sub-options now, but there
+			 * might be in future... */
+			print_prctl_args(tcp, 1);
+		}
+		return RVAL_DECODED;
+#endif
+
+	case PR_SET_MM:
+		tprints(", ");
+		printxval(pr_set_mm, tcp->u_arg[1], "PR_SET_MM_???");
+		print_prctl_args(tcp, 2);
+		return RVAL_DECODED;
+
+	case PR_SET_PDEATHSIG:
+		tprints(", ");
+		if ((unsigned long) tcp->u_arg[1] > 128)
+			tprintf("%lu", tcp->u_arg[1]);
+		else
+			tprints(signame(tcp->u_arg[1]));
+		return RVAL_DECODED;
+
+	case PR_SET_PTRACER:
+		tprints(", ");
+		if (tcp->u_arg[1] == -1)
+			tprints("PR_SET_PTRACER_ANY");
+		else
+			tprintf("%lu", tcp->u_arg[1]);
+		return RVAL_DECODED;
+
+	case PR_SET_SECCOMP:
+		tprints(", ");
+		printxval_long(seccomp_mode, tcp->u_arg[1],
+			  "SECCOMP_MODE_???");
+		if (SECCOMP_MODE_STRICT == tcp->u_arg[1])
+			return RVAL_DECODED;
+		if (SECCOMP_MODE_FILTER == tcp->u_arg[1]) {
+			tprints(", ");
+			print_seccomp_filter(tcp, tcp->u_arg[2]);
+			return RVAL_DECODED;
+		}
+		print_prctl_args(tcp, 2);
+		return RVAL_DECODED;
+
+	case PR_SET_SECUREBITS:
+		tprints(", ");
+		printflags_long(secbits, tcp->u_arg[1], "SECBIT_???");
+		return RVAL_DECODED;
+
+	case PR_SET_TIMERSLACK:
+		tprintf(", %ld", tcp->u_arg[1]);
+		return RVAL_DECODED;
+
+	case PR_SET_TSC:
+		tprints(", ");
+		printxval(pr_tsc, tcp->u_arg[1], "PR_TSC_???");
+		return RVAL_DECODED;
+
+	case PR_SET_UNALIGN:
+		tprints(", ");
+		printflags(pr_unalign_flags, tcp->u_arg[1], "PR_UNALIGN_???");
+		return RVAL_DECODED;
+
+	case PR_SET_NO_NEW_PRIVS:
+	case PR_SET_THP_DISABLE:
+		tprintf(", %lu", tcp->u_arg[1]);
+		print_prctl_args(tcp, 2);
+		return RVAL_DECODED;
+
+	case PR_MCE_KILL_GET:
+		if (entering(tcp)) {
+			print_prctl_args(tcp, 1);
+			return 0;
+		}
+		if (syserror(tcp))
+			return 0;
+		tcp->auxstr = xlookup(pr_mce_kill_policy,
+				      (unsigned long) tcp->u_rval);
+		return tcp->auxstr ? RVAL_STR : RVAL_UDECIMAL;
+
+	case PR_GET_NO_NEW_PRIVS:
+	case PR_GET_THP_DISABLE:
+	case PR_MPX_DISABLE_MANAGEMENT:
+	case PR_MPX_ENABLE_MANAGEMENT:
+	default:
+		print_prctl_args(tcp, 1);
+		return RVAL_DECODED;
+	}
+	return 0;
+}
+
+#if defined X86_64 || defined X32
+# include <asm/prctl.h>
+# include "xlat/archvals.h"
+
+SYS_FUNC(arch_prctl)
+{
+	const unsigned int option = tcp->u_arg[0];
+
+	if (entering(tcp))
+		printxval(archvals, option, "ARCH_???");
+
+	switch (option) {
+	case ARCH_GET_GS:
+	case ARCH_GET_FS:
+		if (entering(tcp))
+			tprints(", ");
+		else
+			printnum_ptr(tcp, tcp->u_arg[1]);
+		return 0;
+	}
+
+	tprintf(", %#lx", tcp->u_arg[1]);
+	return RVAL_DECODED;
+}
+#endif /* X86_64 || X32 */
diff --git a/strace/print_mq_attr.c b/strace/print_mq_attr.c
new file mode 100644
index 0000000..1807834
--- /dev/null
+++ b/strace/print_mq_attr.c
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(mq_attr_t)
+
+#ifdef HAVE_MQUEUE_H
+# include <mqueue.h>
+typedef struct mq_attr mq_attr_t;
+#elif defined HAVE_LINUX_MQUEUE_H
+# include <linux/types.h>
+# include <linux/mqueue.h>
+typedef struct mq_attr mq_attr_t;
+#endif
+
+#include MPERS_DEFS
+
+MPERS_PRINTER_DECL(void, printmqattr, struct tcb *tcp, const long addr)
+{
+#if defined HAVE_MQUEUE_H || defined HAVE_LINUX_MQUEUE_H
+	mq_attr_t attr;
+	if (umove_or_printaddr(tcp, addr, &attr))
+		return;
+	tprints("{mq_flags=");
+	tprint_open_modes(attr.mq_flags);
+	tprintf(", mq_maxmsg=%ld, mq_msgsize=%ld, mq_curmsg=%ld}",
+		(long) attr.mq_maxmsg, (long) attr.mq_msgsize,
+		(long) attr.mq_curmsgs);
+#else
+	printaddr(addr);
+#endif
+}
diff --git a/strace/print_msgbuf.c b/strace/print_msgbuf.c
new file mode 100644
index 0000000..68d8741
--- /dev/null
+++ b/strace/print_msgbuf.c
@@ -0,0 +1,52 @@
+/*
+ * Copyright (c) 1993 Ulrich Pegelow <pegelow@moorea.uni-muenster.de>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2006 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sys/msg.h>
+
+#include DEF_MPERS_TYPE(msgbuf_t)
+typedef struct msgbuf msgbuf_t;
+#include MPERS_DEFS
+
+MPERS_PRINTER_DECL(void, tprint_msgbuf,
+		   struct tcb *tcp, const long addr, const unsigned long count)
+{
+	msgbuf_t msg;
+
+	if (!umove_or_printaddr(tcp, addr, &msg)) {
+		tprintf("{%lu, ", (long) msg.mtype);
+		printstr(tcp, addr + sizeof(msg.mtype), count);
+		tprints("}");
+	}
+	tprintf(", %lu, ", count);
+}
diff --git a/strace/print_sigevent.c b/strace/print_sigevent.c
new file mode 100644
index 0000000..caf1fdf
--- /dev/null
+++ b/strace/print_sigevent.c
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2003, 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_sigevent)
+#include "sigevent.h"
+#include MPERS_DEFS
+
+#include <signal.h>
+#include "xlat/sigev_value.h"
+
+MPERS_PRINTER_DECL(void, print_sigevent, struct tcb *tcp, const long addr)
+{
+	struct_sigevent sev;
+
+	if (umove_or_printaddr(tcp, addr, &sev))
+		return;
+
+	tprints("{");
+	if (sev.sigev_value.sival_ptr) {
+		tprintf("sigev_value={int=%d, ptr=",
+			sev.sigev_value.sival_int);
+		printaddr((unsigned long) sev.sigev_value.sival_ptr);
+		tprints("}, ");
+	}
+
+	tprints("sigev_signo=");
+	switch (sev.sigev_notify) {
+	case SIGEV_SIGNAL:
+	case SIGEV_THREAD:
+	case SIGEV_THREAD_ID:
+		tprints(signame(sev.sigev_signo));
+		break;
+	default:
+		tprintf("%u", sev.sigev_signo);
+	}
+
+	tprints(", sigev_notify=");
+	printxval(sigev_value, sev.sigev_notify, "SIGEV_???");
+
+	switch (sev.sigev_notify) {
+	case SIGEV_THREAD_ID:
+		tprintf(", sigev_notify_thread_id=%d", sev.sigev_un.tid);
+		break;
+	case SIGEV_THREAD:
+		tprints(", sigev_notify_function=");
+		printaddr(sev.sigev_un.sigev_thread.function);
+		tprints(", sigev_notify_attributes=");
+		printaddr(sev.sigev_un.sigev_thread.attribute);
+		break;
+	}
+	tprints("}");
+}
diff --git a/strace/print_statfs.c b/strace/print_statfs.c
new file mode 100644
index 0000000..2661d07
--- /dev/null
+++ b/strace/print_statfs.c
@@ -0,0 +1,130 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "statfs.h"
+#include "xlat/fsmagic.h"
+#include "xlat/statfs_flags.h"
+
+static void
+print_statfs_type(const char *const prefix, const unsigned long long magic)
+{
+	tprints(prefix);
+	const char *s = xlat_search(fsmagic, ARRAY_SIZE(fsmagic), magic);
+	if (s)
+		tprints(s);
+	else
+		tprintf("%#llx", magic);
+}
+
+#if defined HAVE_STRUCT_STATFS_F_FLAGS || defined HAVE_STRUCT_STATFS64_F_FLAGS
+static void
+print_statfs_flags(const char *const prefix, const unsigned long long flags)
+{
+	if (flags & ST_VALID) {
+		tprints(prefix);
+		printflags64(statfs_flags, flags, "ST_???");
+	}
+}
+#endif /* HAVE_STRUCT_STATFS_F_FLAGS || HAVE_STRUCT_STATFS64_F_FLAGS */
+
+static void
+print_statfs_number(const char *const prefix, const unsigned long long number)
+{
+	tprints(prefix);
+	tprintf("%llu",  number);
+}
+
+void
+print_struct_statfs(struct tcb *tcp, const long addr)
+{
+#ifdef HAVE_STRUCT_STATFS
+	struct strace_statfs b;
+
+	if (!fetch_struct_statfs(tcp, addr, &b))
+		return;
+
+	print_statfs_type("{f_type=", b.f_type);
+	print_statfs_number(", f_bsize=", b.f_bsize);
+	print_statfs_number(", f_blocks=", b.f_blocks);
+	print_statfs_number(", f_bfree=", b.f_bfree);
+	print_statfs_number(", f_bavail=", b.f_bavail);
+	print_statfs_number(", f_files=", b.f_files);
+	print_statfs_number(", f_ffree=", b.f_ffree);
+# if defined HAVE_STRUCT_STATFS_F_FSID_VAL \
+  || defined HAVE_STRUCT_STATFS_F_FSID___VAL
+	print_statfs_number(", f_fsid={", b.f_fsid[0]);
+	print_statfs_number(", ", b.f_fsid[1]);
+	tprints("}");
+# endif
+	print_statfs_number(", f_namelen=", b.f_namelen);
+# ifdef HAVE_STRUCT_STATFS_F_FRSIZE
+	print_statfs_number(", f_frsize=", b.f_frsize);
+# endif
+# ifdef HAVE_STRUCT_STATFS_F_FLAGS
+	print_statfs_flags(", f_flags=", b.f_flags);
+# endif
+	tprints("}");
+#else
+	printaddr(addr);
+#endif
+}
+
+void
+print_struct_statfs64(struct tcb *tcp, const long addr, const unsigned long size)
+{
+#ifdef HAVE_STRUCT_STATFS64
+	struct strace_statfs b;
+
+	if (!fetch_struct_statfs64(tcp, addr, size, &b))
+		return;
+
+	print_statfs_type("{f_type=", b.f_type);
+	print_statfs_number(", f_bsize=", b.f_bsize);
+	print_statfs_number(", f_blocks=", b.f_blocks);
+	print_statfs_number(", f_bfree=", b.f_bfree);
+	print_statfs_number(", f_bavail=", b.f_bavail);
+	print_statfs_number(", f_files=", b.f_files);
+	print_statfs_number(", f_ffree=", b.f_ffree);
+# if defined HAVE_STRUCT_STATFS64_F_FSID_VAL \
+  || defined HAVE_STRUCT_STATFS64_F_FSID___VAL
+	print_statfs_number(", f_fsid={", b.f_fsid[0]);
+	print_statfs_number(", ", b.f_fsid[1]);
+	tprints("}");
+# endif
+	print_statfs_number(", f_namelen=", b.f_namelen);
+# ifdef HAVE_STRUCT_STATFS64_F_FRSIZE
+	print_statfs_number(", f_frsize=", b.f_frsize);
+# endif
+# ifdef HAVE_STRUCT_STATFS64_F_FLAGS
+	print_statfs_flags(", f_flags=", b.f_flags);
+# endif
+	tprints("}");
+#else
+	printaddr(addr);
+#endif
+}
diff --git a/strace/print_time.c b/strace/print_time.c
new file mode 100644
index 0000000..500ce8e
--- /dev/null
+++ b/strace/print_time.c
@@ -0,0 +1,280 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(time_t)
+#include DEF_MPERS_TYPE(timespec_t)
+#include DEF_MPERS_TYPE(timeval_t)
+
+typedef struct timespec timespec_t;
+typedef struct timeval timeval_t;
+
+#include MPERS_DEFS
+
+#ifndef UTIME_NOW
+# define UTIME_NOW ((1l << 30) - 1l)
+#endif
+#ifndef UTIME_OMIT
+# define UTIME_OMIT ((1l << 30) - 2l)
+#endif
+
+static const char time_fmt[] = "{%jd, %jd}";
+
+static void
+print_timespec_t(const timespec_t *t)
+{
+	tprintf(time_fmt, (intmax_t) t->tv_sec, (intmax_t) t->tv_nsec);
+}
+
+static void
+print_timespec_t_utime(const timespec_t *t)
+{
+	switch (t->tv_nsec) {
+	case UTIME_NOW:
+		tprints("UTIME_NOW");
+		break;
+	case UTIME_OMIT:
+		tprints("UTIME_OMIT");
+		break;
+	default:
+		print_timespec_t(t);
+		break;
+	}
+}
+
+static void
+print_timeval_t(const timeval_t *t)
+{
+	tprintf(time_fmt, (intmax_t) t->tv_sec, (intmax_t) t->tv_usec);
+}
+
+MPERS_PRINTER_DECL(void, print_timespec,
+		   struct tcb *tcp, const long addr)
+{
+	timespec_t t;
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	print_timespec_t(&t);
+}
+
+MPERS_PRINTER_DECL(const char *, sprint_timespec,
+		   struct tcb *tcp, const long addr)
+{
+	timespec_t t;
+	static char buf[sizeof(time_fmt) + 3 * sizeof(t)];
+
+	if (!addr) {
+		strcpy(buf, "NULL");
+	} else if (!verbose(tcp) || (exiting(tcp) && syserror(tcp)) ||
+		   umove(tcp, addr, &t)) {
+		snprintf(buf, sizeof(buf), "%#lx", addr);
+	} else {
+		snprintf(buf, sizeof(buf), time_fmt,
+			 (intmax_t) t.tv_sec, (intmax_t) t.tv_nsec);
+	}
+
+	return buf;
+}
+
+MPERS_PRINTER_DECL(void, print_timespec_utime_pair,
+		   struct tcb *tcp, const long addr)
+{
+	timespec_t t[2];
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	tprints("[");
+	print_timespec_t_utime(&t[0]);
+	tprints(", ");
+	print_timespec_t_utime(&t[1]);
+	tprints("]");
+}
+
+MPERS_PRINTER_DECL(void, print_itimerspec,
+		   struct tcb *tcp, const long addr)
+{
+	timespec_t t[2];
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	tprints("{it_interval=");
+	print_timespec_t(&t[0]);
+	tprints(", it_value=");
+	print_timespec_t(&t[1]);
+	tprints("}");
+}
+
+MPERS_PRINTER_DECL(void, print_timeval,
+		   struct tcb *tcp, const long addr)
+{
+	timeval_t t;
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	print_timeval_t(&t);
+}
+
+MPERS_PRINTER_DECL(void, print_timeval_pair,
+		   struct tcb *tcp, const long addr)
+{
+	timeval_t t[2];
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	tprints("[");
+	print_timeval_t(&t[0]);
+	tprints(", ");
+	print_timeval_t(&t[1]);
+	tprints("]");
+}
+
+MPERS_PRINTER_DECL(const char *, sprint_timeval,
+		   struct tcb *tcp, const long addr)
+{
+	timeval_t t;
+	static char buf[sizeof(time_fmt) + 3 * sizeof(t)];
+
+	if (!addr) {
+		strcpy(buf, "NULL");
+	} else if (!verbose(tcp) || (exiting(tcp) && syserror(tcp)) ||
+		   umove(tcp, addr, &t)) {
+		snprintf(buf, sizeof(buf), "%#lx", addr);
+	} else {
+		snprintf(buf, sizeof(buf), time_fmt,
+			 (intmax_t) t.tv_sec, (intmax_t) t.tv_usec);
+	}
+
+	return buf;
+}
+
+MPERS_PRINTER_DECL(void, print_itimerval,
+		   struct tcb *tcp, const long addr)
+{
+	timeval_t t[2];
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	tprints("{it_interval=");
+	print_timeval_t(&t[0]);
+	tprints(", it_value=");
+	print_timeval_t(&t[1]);
+	tprints("}");
+}
+
+SYS_FUNC(time)
+{
+	if (exiting(tcp)) {
+		time_t t;
+
+		if (!umove_or_printaddr(tcp, tcp->u_arg[0], &t))
+			tprintf("[%jd]", (intmax_t) t);
+	}
+
+	return 0;
+}
+
+#ifdef ALPHA
+
+typedef struct {
+	int tv_sec, tv_usec;
+} timeval32_t;
+
+static void
+print_timeval32_t(const timeval32_t *t)
+{
+	tprintf(time_fmt, (intmax_t) t->tv_sec, (intmax_t) t->tv_usec);
+}
+
+void
+print_timeval32(struct tcb *tcp, const long addr)
+{
+	timeval32_t t;
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	print_timeval32_t(&t);
+}
+
+void
+print_timeval32_pair(struct tcb *tcp, const long addr)
+{
+	timeval32_t t[2];
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	tprints("[");
+	print_timeval32_t(&t[0]);
+	tprints(", ");
+	print_timeval32_t(&t[1]);
+	tprints("]");
+}
+
+void
+print_itimerval32(struct tcb *tcp, const long addr)
+{
+	timeval32_t t[2];
+
+	if (umove_or_printaddr(tcp, addr, &t))
+		return;
+
+	tprints("{it_interval=");
+	print_timeval32_t(&t[0]);
+	tprints(", it_value=");
+	print_timeval32_t(&t[1]);
+	tprints("}");
+}
+
+const char *
+sprint_timeval32(struct tcb *tcp, const long addr)
+{
+	timeval32_t t;
+	static char buf[sizeof(time_fmt) + 3 * sizeof(t)];
+
+	if (!addr) {
+		strcpy(buf, "NULL");
+	} else if (!verbose(tcp) || (exiting(tcp) && syserror(tcp)) ||
+		   umove(tcp, addr, &t)) {
+		snprintf(buf, sizeof(buf), "%#lx", addr);
+	} else {
+		snprintf(buf, sizeof(buf), time_fmt,
+			 (intmax_t) t.tv_sec, (intmax_t) t.tv_usec);
+	}
+
+	return buf;
+}
+
+#endif /* ALPHA */
diff --git a/strace/print_timex.c b/strace/print_timex.c
new file mode 100644
index 0000000..ad6a711
--- /dev/null
+++ b/strace/print_timex.c
@@ -0,0 +1,72 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_timex)
+
+#include <sys/timex.h>
+typedef struct timex struct_timex;
+
+#include MPERS_DEFS
+
+#include "xlat/adjtimex_modes.h"
+#include "xlat/adjtimex_status.h"
+
+MPERS_PRINTER_DECL(int, print_timex, struct tcb *tcp, const long addr)
+{
+	struct_timex tx;
+
+	if (umove_or_printaddr(tcp, addr, &tx))
+		return -1;
+
+	tprints("{modes=");
+	printflags(adjtimex_modes, tx.modes, "ADJ_???");
+	tprintf(", offset=%jd, freq=%jd, maxerror=%ju, esterror=%ju, status=",
+		(intmax_t) tx.offset, (intmax_t) tx.freq,
+		(uintmax_t) tx.maxerror, (uintmax_t) tx.esterror);
+	printflags(adjtimex_status, tx.status, "STA_???");
+	tprintf(", constant=%jd, precision=%ju, tolerance=%jd",
+		(intmax_t) tx.constant, (uintmax_t) tx.precision,
+		(intmax_t) tx.tolerance);
+	tprintf(", time={%jd, %jd}",
+		(intmax_t) tx.time.tv_sec, (intmax_t) tx.time.tv_usec);
+	tprintf(", tick=%jd, ppsfreq=%jd, jitter=%jd",
+		(intmax_t) tx.tick, (intmax_t) tx.ppsfreq, (intmax_t) tx.jitter);
+	tprintf(", shift=%d, stabil=%jd, jitcnt=%jd",
+		tx.shift, (intmax_t) tx.stabil, (intmax_t) tx.jitcnt);
+	tprintf(", calcnt=%jd, errcnt=%jd, stbcnt=%jd",
+		(intmax_t) tx.calcnt, (intmax_t) tx.errcnt, (intmax_t) tx.stbcnt);
+#ifdef HAVE_STRUCT_TIMEX_TAI
+	tprintf(", tai=%d", tx.tai);
+#endif
+	tprints("}");
+	return 0;
+}
diff --git a/strace/printers.h b/strace/printers.h
new file mode 100644
index 0000000..07ba17d
--- /dev/null
+++ b/strace/printers.h
@@ -0,0 +1,95 @@
+/* Generated by Makefile from block.c.mpers.i btrfs.c.mpers.i dirent.c.mpers.i evdev.c.mpers.i fetch_seccomp_fprog.c.mpers.i fetch_struct_flock.c.mpers.i fetch_struct_mmsghdr.c.mpers.i fetch_struct_msghdr.c.mpers.i fetch_struct_statfs.c.mpers.i hdio.c.mpers.i ipc_msgctl.c.mpers.i ipc_shmctl.c.mpers.i mtd.c.mpers.i print_mq_attr.c.mpers.i print_msgbuf.c.mpers.i print_sigevent.c.mpers.i print_time.c.mpers.i print_timex.c.mpers.i printrusage.c.mpers.i printsiginfo.c.mpers.i rtc.c.mpers.i sigaltstack.c.mpers.i sysinfo.c.mpers.i times.c.mpers.i utime.c.mpers.i v4l2.c.mpers.i; do not edit. */
+typedef struct {
+ int (*block_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define block_ioctl MPERS_PRINTER_NAME(block_ioctl)
+
+ int (*btrfs_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define btrfs_ioctl MPERS_PRINTER_NAME(btrfs_ioctl)
+
+ int (*evdev_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define evdev_ioctl MPERS_PRINTER_NAME(evdev_ioctl)
+
+ _Bool (*fetch_seccomp_fprog)(struct tcb *tcp, const long addr, void *p);
+#define fetch_seccomp_fprog MPERS_PRINTER_NAME(fetch_seccomp_fprog)
+
+ _Bool (*fetch_struct_flock)(struct tcb *tcp, const long addr, void *p);
+#define fetch_struct_flock MPERS_PRINTER_NAME(fetch_struct_flock)
+
+ _Bool (*fetch_struct_flock64)(struct tcb *tcp, const long addr, void *p);
+#define fetch_struct_flock64 MPERS_PRINTER_NAME(fetch_struct_flock64)
+
+ int (*fetch_struct_mmsghdr)(struct tcb *tcp, const unsigned long addr, void *p);
+#define fetch_struct_mmsghdr MPERS_PRINTER_NAME(fetch_struct_mmsghdr)
+
+ unsigned int (*sizeof_struct_mmsghdr)(void);
+#define sizeof_struct_mmsghdr MPERS_PRINTER_NAME(sizeof_struct_mmsghdr)
+
+ int (*fetch_struct_msghdr)(struct tcb *tcp, const unsigned long addr, void *p);
+#define fetch_struct_msghdr MPERS_PRINTER_NAME(fetch_struct_msghdr)
+
+ _Bool (*fetch_struct_statfs)(struct tcb *tcp, const long addr, struct strace_statfs *p);
+#define fetch_struct_statfs MPERS_PRINTER_NAME(fetch_struct_statfs)
+
+ _Bool (*fetch_struct_statfs64)(struct tcb *tcp, const long addr, const unsigned long size, struct strace_statfs *p);
+#define fetch_struct_statfs64 MPERS_PRINTER_NAME(fetch_struct_statfs64)
+
+ int (*hdio_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define hdio_ioctl MPERS_PRINTER_NAME(hdio_ioctl)
+
+ int (*mtd_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define mtd_ioctl MPERS_PRINTER_NAME(mtd_ioctl)
+
+ void (*printmqattr)(struct tcb *tcp, const long addr);
+#define printmqattr MPERS_PRINTER_NAME(printmqattr)
+
+ void (*tprint_msgbuf)(struct tcb *tcp, const long addr, const unsigned long count);
+#define tprint_msgbuf MPERS_PRINTER_NAME(tprint_msgbuf)
+
+ void (*print_sigevent)(struct tcb *tcp, const long addr);
+#define print_sigevent MPERS_PRINTER_NAME(print_sigevent)
+
+ void (*print_timespec)(struct tcb *tcp, const long addr);
+#define print_timespec MPERS_PRINTER_NAME(print_timespec)
+
+ const char * (*sprint_timespec)(struct tcb *tcp, const long addr);
+#define sprint_timespec MPERS_PRINTER_NAME(sprint_timespec)
+
+ void (*print_timespec_utime_pair)(struct tcb *tcp, const long addr);
+#define print_timespec_utime_pair MPERS_PRINTER_NAME(print_timespec_utime_pair)
+
+ void (*print_itimerspec)(struct tcb *tcp, const long addr);
+#define print_itimerspec MPERS_PRINTER_NAME(print_itimerspec)
+
+ void (*print_timeval)(struct tcb *tcp, const long addr);
+#define print_timeval MPERS_PRINTER_NAME(print_timeval)
+
+ void (*print_timeval_pair)(struct tcb *tcp, const long addr);
+#define print_timeval_pair MPERS_PRINTER_NAME(print_timeval_pair)
+
+ const char * (*sprint_timeval)(struct tcb *tcp, const long addr);
+#define sprint_timeval MPERS_PRINTER_NAME(sprint_timeval)
+
+ void (*print_itimerval)(struct tcb *tcp, const long addr);
+#define print_itimerval MPERS_PRINTER_NAME(print_itimerval)
+
+ int (*print_timex)(struct tcb *tcp, const long addr);
+#define print_timex MPERS_PRINTER_NAME(print_timex)
+
+ void (*printrusage)(struct tcb *tcp, long addr);
+#define printrusage MPERS_PRINTER_NAME(printrusage)
+
+ void (*printsiginfo_at)(struct tcb *tcp, long addr);
+#define printsiginfo_at MPERS_PRINTER_NAME(printsiginfo_at)
+
+ void (*print_siginfo_array)(struct tcb *tcp, unsigned long addr, unsigned long len);
+#define print_siginfo_array MPERS_PRINTER_NAME(print_siginfo_array)
+
+ int (*rtc_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define rtc_ioctl MPERS_PRINTER_NAME(rtc_ioctl)
+
+ int (*v4l2_ioctl)(struct tcb *tcp, const unsigned int code, const long arg);
+#define v4l2_ioctl MPERS_PRINTER_NAME(v4l2_ioctl)
+
+} struct_printers;
+extern const struct_printers *printers;
+#define MPERS_PRINTER_NAME(printer_name) printers->printer_name
diff --git a/strace/printmode.c b/strace/printmode.c
new file mode 100644
index 0000000..ad87507
--- /dev/null
+++ b/strace/printmode.c
@@ -0,0 +1,62 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2012 Denys Vlasenko <vda.linux@googlemail.com>
+ * 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 <fcntl.h>
+#include <sys/stat.h>
+
+#include "xlat/modetypes.h"
+
+const char *
+sprintmode(unsigned int mode)
+{
+	static char buf[sizeof("S_IFSOCK|S_ISUID|S_ISGID|S_ISVTX|%o")
+			+ sizeof(int)*3
+			+ /*paranoia:*/ 8];
+	const char *s;
+
+	if ((mode & S_IFMT) == 0)
+		s = "";
+	else if ((s = xlookup(modetypes, mode & S_IFMT)) == NULL) {
+		sprintf(buf, "%#o", mode);
+		return buf;
+	}
+	s = buf + sprintf(buf, "%s%s%s%s", s,
+		(mode & S_ISUID) ? "|S_ISUID" : "",
+		(mode & S_ISGID) ? "|S_ISGID" : "",
+		(mode & S_ISVTX) ? "|S_ISVTX" : "");
+	mode &= ~(S_IFMT|S_ISUID|S_ISGID|S_ISVTX);
+	if (mode)
+		sprintf((char*)s, "|%#o", mode);
+	s = (*buf == '|') ? buf + 1 : buf;
+	return *s ? s : "0";
+}
diff --git a/strace/printrusage.c b/strace/printrusage.c
new file mode 100644
index 0000000..acf67eb
--- /dev/null
+++ b/strace/printrusage.c
@@ -0,0 +1,124 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <sys/resource.h>
+
+#include DEF_MPERS_TYPE(rusage_t)
+
+typedef struct rusage rusage_t;
+
+#include MPERS_DEFS
+
+MPERS_PRINTER_DECL(void, printrusage, struct tcb *tcp, long addr)
+{
+	rusage_t ru;
+
+	if (umove_or_printaddr(tcp, addr, &ru))
+		return;
+
+	tprintf("{ru_utime={%llu, %llu}, ru_stime={%llu, %llu}, ",
+		widen_to_ull(ru.ru_utime.tv_sec),
+		widen_to_ull(ru.ru_utime.tv_usec),
+		widen_to_ull(ru.ru_stime.tv_sec),
+		widen_to_ull(ru.ru_stime.tv_usec));
+	if (abbrev(tcp))
+		tprints("...}");
+	else {
+		tprintf("ru_maxrss=%llu, ", widen_to_ull(ru.ru_maxrss));
+		tprintf("ru_ixrss=%llu, ", widen_to_ull(ru.ru_ixrss));
+		tprintf("ru_idrss=%llu, ", widen_to_ull(ru.ru_idrss));
+		tprintf("ru_isrss=%llu, ", widen_to_ull(ru.ru_isrss));
+		tprintf("ru_minflt=%llu, ", widen_to_ull(ru.ru_minflt));
+		tprintf("ru_majflt=%llu, ", widen_to_ull(ru.ru_majflt));
+		tprintf("ru_nswap=%llu, ", widen_to_ull(ru.ru_nswap));
+		tprintf("ru_inblock=%llu, ", widen_to_ull(ru.ru_inblock));
+		tprintf("ru_oublock=%llu, ", widen_to_ull(ru.ru_oublock));
+		tprintf("ru_msgsnd=%llu, ", widen_to_ull(ru.ru_msgsnd));
+		tprintf("ru_msgrcv=%llu, ", widen_to_ull(ru.ru_msgrcv));
+		tprintf("ru_nsignals=%llu, ", widen_to_ull(ru.ru_nsignals));
+		tprintf("ru_nvcsw=%llu, ", widen_to_ull(ru.ru_nvcsw));
+		tprintf("ru_nivcsw=%llu}", widen_to_ull(ru.ru_nivcsw));
+	}
+}
+
+#ifdef ALPHA
+void
+printrusage32(struct tcb *tcp, long addr)
+{
+	struct timeval32 {
+		unsigned tv_sec;
+		unsigned tv_usec;
+	};
+	struct rusage32 {
+		struct timeval32 ru_utime;	/* user time used */
+		struct timeval32 ru_stime;	/* system time used */
+		long	ru_maxrss;		/* maximum resident set size */
+		long	ru_ixrss;		/* integral shared memory size */
+		long	ru_idrss;		/* integral unshared data size */
+		long	ru_isrss;		/* integral unshared stack size */
+		long	ru_minflt;		/* page reclaims */
+		long	ru_majflt;		/* page faults */
+		long	ru_nswap;		/* swaps */
+		long	ru_inblock;		/* block input operations */
+		long	ru_oublock;		/* block output operations */
+		long	ru_msgsnd;		/* messages sent */
+		long	ru_msgrcv;		/* messages received */
+		long	ru_nsignals;		/* signals received */
+		long	ru_nvcsw;		/* voluntary context switches */
+		long	ru_nivcsw;		/* involuntary " */
+	} ru;
+
+	if (umove_or_printaddr(tcp, addr, &ru))
+		return;
+
+	tprintf("{ru_utime={%lu, %lu}, ru_stime={%lu, %lu}, ",
+		(long) ru.ru_utime.tv_sec, (long) ru.ru_utime.tv_usec,
+		(long) ru.ru_stime.tv_sec, (long) ru.ru_stime.tv_usec);
+	if (abbrev(tcp))
+		tprints("...}");
+	else {
+		tprintf("ru_maxrss=%lu, ", ru.ru_maxrss);
+		tprintf("ru_ixrss=%lu, ", ru.ru_ixrss);
+		tprintf("ru_idrss=%lu, ", ru.ru_idrss);
+		tprintf("ru_isrss=%lu, ", ru.ru_isrss);
+		tprintf("ru_minflt=%lu, ", ru.ru_minflt);
+		tprintf("ru_majflt=%lu, ", ru.ru_majflt);
+		tprintf("ru_nswap=%lu, ", ru.ru_nswap);
+		tprintf("ru_inblock=%lu, ", ru.ru_inblock);
+		tprintf("ru_oublock=%lu, ", ru.ru_oublock);
+		tprintf("ru_msgsnd=%lu, ", ru.ru_msgsnd);
+		tprintf("ru_msgrcv=%lu, ", ru.ru_msgrcv);
+		tprintf("ru_nsignals=%lu, ", ru.ru_nsignals);
+		tprintf("ru_nvcsw=%lu, ", ru.ru_nvcsw);
+		tprintf("ru_nivcsw=%lu}", ru.ru_nivcsw);
+	}
+}
+#endif
diff --git a/strace/printsiginfo.c b/strace/printsiginfo.c
new file mode 100644
index 0000000..699460f
--- /dev/null
+++ b/strace/printsiginfo.c
@@ -0,0 +1,256 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2001 John Hughes <john@Calva.COM>
+ * Copyright (c) 2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2011-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * 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 DEF_MPERS_TYPE(siginfo_t)
+
+#include <signal.h>
+#include <linux/audit.h>
+
+#include MPERS_DEFS
+
+#ifndef IN_MPERS
+#include "printsiginfo.h"
+#endif
+
+#include "xlat/audit_arch.h"
+#include "xlat/sigbus_codes.h"
+#include "xlat/sigchld_codes.h"
+#include "xlat/sigfpe_codes.h"
+#include "xlat/sigill_codes.h"
+#include "xlat/siginfo_codes.h"
+#include "xlat/sigpoll_codes.h"
+#include "xlat/sigprof_codes.h"
+#include "xlat/sigsegv_codes.h"
+#include "xlat/sigsys_codes.h"
+#include "xlat/sigtrap_codes.h"
+
+#ifdef SIGEMT
+# include "xlat/sigemt_codes.h"
+#endif
+
+#ifndef SI_FROMUSER
+# define SI_FROMUSER(sip)	((sip)->si_code <= 0)
+#endif
+
+static void
+printsigsource(const siginfo_t *sip)
+{
+	tprintf(", si_pid=%u, si_uid=%u",
+		(unsigned int) sip->si_pid,
+		(unsigned int) sip->si_uid);
+}
+
+static void
+printsigval(const siginfo_t *sip)
+{
+	tprintf(", si_value={int=%d, ptr=", sip->si_int);
+	printaddr((unsigned long) sip->si_ptr);
+	tprints("}");
+}
+
+static void
+print_si_code(int si_signo, unsigned int si_code)
+{
+	const char *code = xlookup(siginfo_codes, si_code);
+
+	if (!code) {
+		switch (si_signo) {
+		case SIGTRAP:
+			code = xlookup(sigtrap_codes, si_code);
+			break;
+		case SIGCHLD:
+			code = xlookup(sigchld_codes, si_code);
+			break;
+		case SIGPOLL:
+			code = xlookup(sigpoll_codes, si_code);
+			break;
+		case SIGPROF:
+			code = xlookup(sigprof_codes, si_code);
+			break;
+		case SIGILL:
+			code = xlookup(sigill_codes, si_code);
+			break;
+#ifdef SIGEMT
+		case SIGEMT:
+			code = xlookup(sigemt_codes, si_code);
+			break;
+#endif
+		case SIGFPE:
+			code = xlookup(sigfpe_codes, si_code);
+			break;
+		case SIGSEGV:
+			code = xlookup(sigsegv_codes, si_code);
+			break;
+		case SIGBUS:
+			code = xlookup(sigbus_codes, si_code);
+			break;
+		case SIGSYS:
+			code = xlookup(sigsys_codes, si_code);
+			break;
+		}
+	}
+
+	if (code)
+		tprints(code);
+	else
+		tprintf("%#x", si_code);
+}
+
+static void
+print_si_info(const siginfo_t *sip)
+{
+	if (sip->si_errno) {
+		tprints(", si_errno=");
+		if ((unsigned) sip->si_errno < nerrnos
+		    && errnoent[sip->si_errno])
+			tprints(errnoent[sip->si_errno]);
+		else
+			tprintf("%d", sip->si_errno);
+	}
+
+	if (SI_FROMUSER(sip)) {
+		switch (sip->si_code) {
+		case SI_USER:
+			printsigsource(sip);
+			break;
+		case SI_TKILL:
+			printsigsource(sip);
+			break;
+#if defined HAVE_SIGINFO_T_SI_TIMERID && defined HAVE_SIGINFO_T_SI_OVERRUN
+		case SI_TIMER:
+			tprintf(", si_timerid=%#x, si_overrun=%d",
+				sip->si_timerid, sip->si_overrun);
+			printsigval(sip);
+			break;
+#endif
+		default:
+			printsigsource(sip);
+			if (sip->si_ptr)
+				printsigval(sip);
+			break;
+		}
+	} else {
+		switch (sip->si_signo) {
+		case SIGCHLD:
+			printsigsource(sip);
+			tprints(", si_status=");
+			if (sip->si_code == CLD_EXITED)
+				tprintf("%d", sip->si_status);
+			else
+				printsignal(sip->si_status);
+			tprintf(", si_utime=%llu, si_stime=%llu",
+				widen_to_ull(sip->si_utime),
+				widen_to_ull(sip->si_stime));
+			break;
+		case SIGILL: case SIGFPE:
+		case SIGSEGV: case SIGBUS:
+			tprints(", si_addr=");
+			printaddr((unsigned long) sip->si_addr);
+			break;
+		case SIGPOLL:
+			switch (sip->si_code) {
+			case POLL_IN: case POLL_OUT: case POLL_MSG:
+				tprintf(", si_band=%ld",
+					(long) sip->si_band);
+				break;
+			}
+			break;
+#ifdef HAVE_SIGINFO_T_SI_SYSCALL
+		case SIGSYS:
+			tprints(", si_call_addr=");
+			printaddr((unsigned long) sip->si_call_addr);
+			tprintf(", si_syscall=__NR_%s, si_arch=",
+				syscall_name((unsigned) sip->si_syscall));
+			printxval(audit_arch, sip->si_arch, "AUDIT_ARCH_???");
+			break;
+#endif
+		default:
+			if (sip->si_pid || sip->si_uid)
+				printsigsource(sip);
+			if (sip->si_ptr)
+				printsigval(sip);
+		}
+	}
+}
+
+#ifdef IN_MPERS
+static
+#endif
+void
+printsiginfo(const siginfo_t *sip)
+{
+	if (sip->si_signo == 0) {
+		tprints("{}");
+		return;
+	}
+	tprints("{si_signo=");
+	printsignal(sip->si_signo);
+
+	tprints(", si_code=");
+	print_si_code(sip->si_signo, sip->si_code);
+
+#ifdef SI_NOINFO
+	if (sip->si_code != SI_NOINFO)
+#endif
+		print_si_info(sip);
+
+	tprints("}");
+}
+
+MPERS_PRINTER_DECL(void, printsiginfo_at,
+		   struct tcb *tcp, long addr)
+{
+	siginfo_t si;
+
+	if (!umove_or_printaddr(tcp, addr, &si))
+		printsiginfo(&si);
+}
+
+static bool
+print_siginfo_t(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	printsiginfo((const siginfo_t *) elem_buf);
+	return true;
+}
+
+MPERS_PRINTER_DECL(void, print_siginfo_array,
+		   struct tcb *tcp, unsigned long addr, unsigned long len)
+{
+	siginfo_t si;
+
+	print_array(tcp, addr, len, &si, sizeof(si),
+		    umoven_or_printaddr, print_siginfo_t, 0);
+}
diff --git a/strace/printsiginfo.h b/strace/printsiginfo.h
new file mode 100644
index 0000000..cb2d99d
--- /dev/null
+++ b/strace/printsiginfo.h
@@ -0,0 +1 @@
+extern void printsiginfo(const siginfo_t *);
diff --git a/strace/printstat.h b/strace/printstat.h
new file mode 100644
index 0000000..5bf745c
--- /dev/null
+++ b/strace/printstat.h
@@ -0,0 +1,134 @@
+/*
+ * Copyright (c) 1999-2003 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2004 David S. Miller <davem@nuts.davemloft.net>
+ * Copyright (c) 2003-2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2007 Jan Kratochvil <jan.kratochvil@redhat.com>
+ * Copyright (c) 2009 Denys Vlasenko <dvlasenk@redhat.com>
+ * Copyright (c) 2009-2010 Andreas Schwab <schwab@linux-m68k.org>
+ * Copyright (c) 2012 H.J. Lu <hongjiu.lu@intel.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef DO_PRINTSTAT
+# define DO_PRINTSTAT do_printstat
+#endif
+
+#ifndef STRUCT_STAT
+# define STRUCT_STAT struct stat
+#endif
+
+#ifndef STAT_MAJOR
+# define STAT_MAJOR(x) major(x)
+#endif
+
+#ifndef STAT_MINOR
+# define STAT_MINOR(x) minor(x)
+#endif
+
+static void
+DO_PRINTSTAT(struct tcb *tcp, const STRUCT_STAT *statbuf)
+{
+	if (!abbrev(tcp)) {
+		tprintf("{st_dev=makedev(%u, %u), st_ino=%llu, st_mode=%s, ",
+			(unsigned int) STAT_MAJOR(statbuf->st_dev),
+			(unsigned int) STAT_MINOR(statbuf->st_dev),
+			widen_to_ull(statbuf->st_ino),
+			sprintmode(statbuf->st_mode));
+		tprintf("st_nlink=%u, st_uid=%u, st_gid=%u, ",
+			(unsigned int) statbuf->st_nlink,
+			(unsigned int) statbuf->st_uid,
+			(unsigned int) statbuf->st_gid);
+#ifdef HAVE_STRUCT_STAT_ST_BLKSIZE
+		tprintf("st_blksize=%u, ", (unsigned int) statbuf->st_blksize);
+#endif
+#ifdef HAVE_STRUCT_STAT_ST_BLOCKS
+		tprintf("st_blocks=%llu, ", widen_to_ull(statbuf->st_blocks));
+#endif
+	} else {
+		tprintf("{st_mode=%s, ", sprintmode(statbuf->st_mode));
+	}
+
+	switch (statbuf->st_mode & S_IFMT) {
+	case S_IFCHR: case S_IFBLK:
+#ifdef HAVE_STRUCT_STAT_ST_RDEV
+		tprintf("st_rdev=makedev(%u, %u), ",
+			(unsigned int) STAT_MAJOR(statbuf->st_rdev),
+			(unsigned int) STAT_MINOR(statbuf->st_rdev));
+#else /* !HAVE_STRUCT_STAT_ST_RDEV */
+		tprintf("st_size=makedev(%u, %u), ",
+			(unsigned int) STAT_MAJOR(statbuf->st_size),
+			(unsigned int) STAT_MINOR(statbuf->st_size));
+#endif /* !HAVE_STRUCT_STAT_ST_RDEV */
+		break;
+	default:
+		tprintf("st_size=%llu, ", widen_to_ull(statbuf->st_size));
+		break;
+	}
+
+	if (!abbrev(tcp)) {
+		const bool cast = sizeof(statbuf->st_atime) == sizeof(int);
+
+		tprints("st_atime=");
+		tprints(sprinttime(cast ? (time_t) (int) statbuf->st_atime:
+					  (time_t) statbuf->st_atime));
+#ifdef HAVE_STRUCT_STAT_ST_ATIME_NSEC
+		if (statbuf->st_atime_nsec)
+			tprintf(".%09lu", (unsigned long) statbuf->st_atime_nsec);
+#endif
+		tprints(", st_mtime=");
+		tprints(sprinttime(cast ? (time_t) (int) statbuf->st_mtime:
+					  (time_t) statbuf->st_mtime));
+#ifdef HAVE_STRUCT_STAT_ST_MTIME_NSEC
+		if (statbuf->st_mtime_nsec)
+			tprintf(".%09lu", (unsigned long) statbuf->st_mtime_nsec);
+#endif
+		tprints(", st_ctime=");
+		tprints(sprinttime(cast ? (time_t) (int) statbuf->st_ctime:
+					  (time_t) statbuf->st_ctime));
+#ifdef HAVE_STRUCT_STAT_ST_CTIME_NSEC
+		if (statbuf->st_ctime_nsec)
+			tprintf(".%09lu", (unsigned long) statbuf->st_ctime_nsec);
+#endif
+#ifdef HAVE_STRUCT_STAT_ST_FLAGS
+		tprintf(", st_flags=%u", (unsigned int) statbuf->st_flags);
+#endif
+#ifdef HAVE_STRUCT_STAT_ST_FSTYPE
+		tprintf(", st_fstype=%.*s",
+			(int) sizeof statbuf->st_fstype, statbuf->st_fstype);
+#endif
+#ifdef HAVE_STRUCT_STAT_ST_GEN
+		tprintf(", st_gen=%u", (unsigned int) statbuf->st_gen);
+#endif
+		tprints("}");
+	} else {
+		tprints("...}");
+	}
+}
+
+#undef STAT_MINOR
+#undef STAT_MAJOR
+#undef STRUCT_STAT
+#undef DO_PRINTSTAT
diff --git a/strace/process.c b/strace/process.c
new file mode 100644
index 0000000..32dcfe2
--- /dev/null
+++ b/strace/process.c
@@ -0,0 +1,264 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 1999 IBM Deutschland Entwicklung GmbH, IBM Corporation
+ *                     Linux for s390 port by D.J. Barrow
+ *                    <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * Copyright (c) 2000 PocketPenguins Inc.  Linux for Hitachi SuperH
+ *                    port by Greg Banks <gbanks@pocketpenguins.com>
+ *
+ * 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"
+
+#ifdef HAVE_ELF_H
+# include <elf.h>
+#endif
+
+#include "xlat/nt_descriptor_types.h"
+
+#include "regs.h"
+#include "ptrace.h"
+#include "xlat/ptrace_cmds.h"
+#include "xlat/ptrace_setoptions_flags.h"
+#include "xlat/ptrace_peeksiginfo_flags.h"
+
+#define uoff(member)	offsetof(struct user, member)
+#define XLAT_UOFF(member)	{ uoff(member), "offsetof(struct user, " #member ")" }
+
+static const struct xlat struct_user_offsets[] = {
+#include "userent.h"
+	XLAT_END
+};
+
+static void
+print_user_offset_addr(const unsigned long addr)
+{
+	const struct xlat *x;
+
+	for (x = struct_user_offsets; x->str; ++x) {
+		if (x->val >= addr)
+			break;
+	}
+
+	if (!x->str) {
+		printaddr(addr);
+	} else if (x->val > addr) {
+		if (x == struct_user_offsets) {
+			printaddr(addr);
+		} else {
+			--x;
+			tprintf("%s + %lu",
+				x->str, addr - (unsigned long) x->val);
+		}
+	} else {
+		tprints(x->str);
+	}
+}
+
+SYS_FUNC(ptrace)
+{
+	const unsigned long request = tcp->u_arg[0];
+	const int pid = tcp->u_arg[1];
+	const unsigned long addr = tcp->u_arg[2];
+	const unsigned long data = tcp->u_arg[3];
+
+	if (entering(tcp)) {
+		/* request */
+		printxval64(ptrace_cmds, request, "PTRACE_???");
+
+		if (request == PTRACE_TRACEME) {
+			/* pid, addr, and data are ignored. */
+			return RVAL_DECODED;
+		}
+
+		/* pid */
+		tprintf(", %d", pid);
+
+		/* addr */
+		switch (request) {
+		case PTRACE_ATTACH:
+		case PTRACE_INTERRUPT:
+		case PTRACE_KILL:
+		case PTRACE_LISTEN:
+			/* addr and data are ignored */
+			return RVAL_DECODED;
+		case PTRACE_PEEKUSER:
+		case PTRACE_POKEUSER:
+			tprints(", ");
+			print_user_offset_addr(addr);
+			break;
+		case PTRACE_GETREGSET:
+		case PTRACE_SETREGSET:
+			tprints(", ");
+			printxval(nt_descriptor_types, addr, "NT_???");
+			break;
+		case PTRACE_GETSIGMASK:
+		case PTRACE_SETSIGMASK:
+		case PTRACE_SECCOMP_GET_FILTER:
+			tprintf(", %lu", addr);
+			break;
+		case PTRACE_PEEKSIGINFO: {
+			tprints(", ");
+			struct {
+				uint64_t off;
+				uint32_t flags;
+				uint32_t nr;
+			} psi;
+			if (umove_or_printaddr(tcp, addr, &psi)) {
+				tprints(", ");
+				printaddr(data);
+				return RVAL_DECODED;
+			}
+			tprintf("{off=%" PRIu64 ", flags=", psi.off);
+			printflags(ptrace_peeksiginfo_flags, psi.flags,
+				   "PTRACE_PEEKSIGINFO_???");
+			tprintf(", nr=%u}", psi.nr);
+			break;
+		}
+		default:
+			tprints(", ");
+			printaddr(addr);
+		}
+
+# if defined IA64 || defined SPARC || defined SPARC64
+		switch (request) {
+#  ifdef IA64
+		case PTRACE_PEEKDATA:
+		case PTRACE_PEEKTEXT:
+		case PTRACE_PEEKUSER:
+			/* data is ignored */
+			return RVAL_DECODED | RVAL_HEX;
+#  endif /* IA64 */
+#  if defined SPARC || defined SPARC64
+		case PTRACE_GETREGS:
+		case PTRACE_SETREGS:
+		case PTRACE_GETFPREGS:
+		case PTRACE_SETFPREGS:
+			/* data is ignored */
+			return RVAL_DECODED;
+#  endif /* SPARC || SPARC64 */
+		}
+# endif /* IA64 || SPARC || SPARC64 */
+
+		tprints(", ");
+
+		/* data */
+		switch (request) {
+		case PTRACE_CONT:
+		case PTRACE_DETACH:
+		case PTRACE_SYSCALL:
+#ifdef PTRACE_SINGLESTEP
+		case PTRACE_SINGLESTEP:
+#endif
+#ifdef PTRACE_SINGLEBLOCK
+		case PTRACE_SINGLEBLOCK:
+#endif
+#ifdef PTRACE_SYSEMU
+		case PTRACE_SYSEMU:
+#endif
+#ifdef PTRACE_SYSEMU_SINGLESTEP
+		case PTRACE_SYSEMU_SINGLESTEP:
+#endif
+			printsignal(data);
+			break;
+		case PTRACE_SEIZE:
+		case PTRACE_SETOPTIONS:
+#ifdef PTRACE_OLDSETOPTIONS
+		case PTRACE_OLDSETOPTIONS:
+#endif
+			printflags64(ptrace_setoptions_flags, data, "PTRACE_O_???");
+			break;
+		case PTRACE_SETSIGINFO:
+			printsiginfo_at(tcp, data);
+			break;
+		case PTRACE_SETSIGMASK:
+			print_sigset_addr_len(tcp, data, addr);
+			break;
+		case PTRACE_SETREGSET:
+			tprint_iov(tcp, /*len:*/ 1, data, IOV_DECODE_ADDR);
+			break;
+#ifndef IA64
+		case PTRACE_PEEKDATA:
+		case PTRACE_PEEKTEXT:
+		case PTRACE_PEEKUSER:
+#endif
+		case PTRACE_GETEVENTMSG:
+		case PTRACE_GETREGSET:
+		case PTRACE_GETSIGINFO:
+		case PTRACE_GETSIGMASK:
+		case PTRACE_PEEKSIGINFO:
+		case PTRACE_SECCOMP_GET_FILTER:
+			if (verbose(tcp)) {
+				/* print data on exiting syscall */
+				return 0;
+			}
+			/* fall through */
+		default:
+			printaddr(data);
+			break;
+		}
+
+		return RVAL_DECODED;
+	} else {
+		switch (request) {
+#ifndef IA64
+		case PTRACE_PEEKDATA:
+		case PTRACE_PEEKTEXT:
+		case PTRACE_PEEKUSER:
+			printnum_ptr(tcp, data);
+			break;
+#endif
+		case PTRACE_GETEVENTMSG:
+			printnum_ulong(tcp, data);
+			break;
+		case PTRACE_GETREGSET:
+			tprint_iov(tcp, /*len:*/ 1, data, IOV_DECODE_ADDR);
+			break;
+		case PTRACE_GETSIGINFO:
+			printsiginfo_at(tcp, data);
+			break;
+		case PTRACE_GETSIGMASK:
+			print_sigset_addr_len(tcp, data, addr);
+			break;
+		case PTRACE_PEEKSIGINFO:
+			if (syserror(tcp))
+				printaddr(data);
+			else
+				print_siginfo_array(tcp, data, tcp->u_rval);
+			break;
+		case PTRACE_SECCOMP_GET_FILTER:
+			if (syserror(tcp))
+				printaddr(data);
+			else
+				print_seccomp_fprog(tcp, data, tcp->u_rval);
+			break;
+		}
+	}
+	return 0;
+}
diff --git a/strace/process_vm.c b/strace/process_vm.c
new file mode 100644
index 0000000..0a9dcd2
--- /dev/null
+++ b/strace/process_vm.c
@@ -0,0 +1,75 @@
+/*
+ * Copyright (c) 2012 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2012-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+SYS_FUNC(process_vm_readv)
+{
+	if (entering(tcp)) {
+		/* arg 1: pid */
+		tprintf("%ld, ", tcp->u_arg[0]);
+	} else {
+		/* arg 2: local iov */
+		if (syserror(tcp)) {
+			printaddr(tcp->u_arg[1]);
+		} else {
+			tprint_iov(tcp, tcp->u_arg[2], tcp->u_arg[1],
+				   IOV_DECODE_STR);
+		}
+		/* arg 3: local iovcnt */
+		tprintf(", %lu, ", tcp->u_arg[2]);
+		/* arg 4: remote iov */
+		if (syserror(tcp)) {
+			printaddr(tcp->u_arg[3]);
+		} else {
+			tprint_iov(tcp, tcp->u_arg[4], tcp->u_arg[3],
+				   IOV_DECODE_ADDR);
+		}
+		/* arg 5: remote iovcnt */
+		/* arg 6: flags */
+		tprintf(", %lu, %lu", tcp->u_arg[4], tcp->u_arg[5]);
+	}
+	return 0;
+}
+
+SYS_FUNC(process_vm_writev)
+{
+	/* arg 1: pid */
+	tprintf("%ld, ", tcp->u_arg[0]);
+	/* arg 2: local iov */
+	tprint_iov(tcp, tcp->u_arg[2], tcp->u_arg[1], IOV_DECODE_STR);
+	/* arg 3: local iovcnt */
+	tprintf(", %lu, ", tcp->u_arg[2]);
+	/* arg 4: remote iov */
+	tprint_iov(tcp, tcp->u_arg[4], tcp->u_arg[3], IOV_DECODE_ADDR);
+	/* arg 5: remote iovcnt */
+	/* arg 6: flags */
+	tprintf(", %lu, %lu", tcp->u_arg[4], tcp->u_arg[5]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ptp.c b/strace/ptp.c
new file mode 100644
index 0000000..69880e1
--- /dev/null
+++ b/strace/ptp.c
@@ -0,0 +1,138 @@
+/*
+ * Copyright (c) 2014 Stefan Sørensen <stefan.sorensen@spectralink.com>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <linux/ioctl.h>
+#include <linux/ptp_clock.h>
+
+#include "xlat/ptp_flags_options.h"
+
+int
+ptp_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	if (!verbose(tcp))
+		return RVAL_DECODED;
+
+	switch (code) {
+	case PTP_EXTTS_REQUEST: {
+		struct ptp_extts_request extts;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &extts))
+			break;
+
+		tprintf("{index=%d, flags=", extts.index);
+		printflags(ptp_flags_options, extts.flags, "PTP_???");
+		tprints("}");
+		break;
+	}
+
+	case PTP_PEROUT_REQUEST: {
+		struct ptp_perout_request perout;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &perout))
+			break;
+
+		tprintf("{start={%" PRId64 ", %" PRIu32 "}"
+			   ", period={%" PRId64 ", %" PRIu32 "}"
+			   ", index=%d, flags=",
+			(int64_t)perout.start.sec, perout.start.nsec,
+			(int64_t)perout.period.sec, perout.period.nsec,
+			perout.index);
+		printflags(ptp_flags_options, perout.flags, "PTP_???");
+		tprints("}");
+		break;
+	}
+
+	case PTP_ENABLE_PPS:
+		tprintf(", %ld", arg);
+		break;
+
+	case PTP_SYS_OFFSET: {
+		struct ptp_sys_offset sysoff;
+
+		if (entering(tcp)) {
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &sysoff))
+				break;
+
+			tprintf("{n_samples=%u", sysoff.n_samples);
+			return 1;
+		} else {
+			unsigned int n_samples, i;
+
+			if (syserror(tcp)) {
+				tprints("}");
+				break;
+			}
+
+			tprints(", ");
+			if (umove(tcp, arg, &sysoff) < 0) {
+				tprints("???}");
+				break;
+			}
+
+			tprints("ts=[");
+			n_samples = sysoff.n_samples > PTP_MAX_SAMPLES ?
+				PTP_MAX_SAMPLES : sysoff.n_samples;
+			for (i = 0; i < 2 * n_samples + 1; ++i) {
+				if (i > 0)
+					tprints(", ");
+				tprintf("{%" PRId64 ", %" PRIu32 "}",
+					(int64_t)sysoff.ts[i].sec,
+					sysoff.ts[i].nsec);
+			}
+			if (sysoff.n_samples > PTP_MAX_SAMPLES)
+				tprints(", ...");
+			tprints("]}");
+			break;
+		}
+	}
+	case PTP_CLOCK_GETCAPS: {
+		struct ptp_clock_caps caps;
+
+		if (entering(tcp))
+			return 0;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &caps))
+			break;
+
+		tprintf("{max_adj=%d, n_alarm=%d, n_ext_ts=%d, n_per_out=%d, pps=%d}",
+			caps.max_adj, caps.n_alarm, caps.n_ext_ts,
+			caps.n_per_out, caps.pps);
+		break;
+	}
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/ptrace.h b/strace/ptrace.h
new file mode 100644
index 0000000..2e7d5e3
--- /dev/null
+++ b/strace/ptrace.h
@@ -0,0 +1,174 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2010 Wang Chao <wang.chao@cn.fujitsu.com>
+ * Copyright (c) 2011-2013 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2011-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2013 Ali Polatel <alip@exherbo.org>
+ * Copyright (c) 2015 Mike Frysinger <vapier@gentoo.org>
+ * 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.
+ */
+
+#ifdef NEED_PTRACE_PROTOTYPE_WORKAROUND
+# define ptrace xptrace
+# include <sys/ptrace.h>
+# undef ptrace
+extern long ptrace(int, int, char *, long);
+#else
+# include <sys/ptrace.h>
+#endif
+
+#ifdef HAVE_STRUCT_IA64_FPREG
+# define ia64_fpreg XXX_ia64_fpreg
+#endif
+#ifdef HAVE_STRUCT_PT_ALL_USER_REGS
+# define pt_all_user_regs XXX_pt_all_user_regs
+#endif
+#ifdef HAVE_STRUCT_PTRACE_PEEKSIGINFO_ARGS
+# define ptrace_peeksiginfo_args XXX_ptrace_peeksiginfo_args
+#endif
+
+#include <linux/ptrace.h>
+
+#ifdef HAVE_STRUCT_IA64_FPREG
+# undef ia64_fpreg
+#endif
+#ifdef HAVE_STRUCT_PT_ALL_USER_REGS
+# undef pt_all_user_regs
+#endif
+#ifdef HAVE_STRUCT_PTRACE_PEEKSIGINFO_ARGS
+# undef ptrace_peeksiginfo_args
+#endif
+
+#ifndef PTRACE_EVENT_FORK
+# define PTRACE_EVENT_FORK	1
+#endif
+#ifndef PTRACE_EVENT_VFORK
+# define PTRACE_EVENT_VFORK	2
+#endif
+#ifndef PTRACE_EVENT_CLONE
+# define PTRACE_EVENT_CLONE	3
+#endif
+#ifndef PTRACE_EVENT_EXEC
+# define PTRACE_EVENT_EXEC	4
+#endif
+#ifndef PTRACE_EVENT_VFORK_DONE
+# define PTRACE_EVENT_VFORK_DONE	5
+#endif
+#ifndef PTRACE_EVENT_EXIT
+# define PTRACE_EVENT_EXIT	6
+#endif
+#ifndef PTRACE_EVENT_SECCOMP
+# define PTRACE_EVENT_SECCOMP	7
+#endif
+#ifdef PTRACE_EVENT_STOP
+/* Linux 3.1 - 3.3 releases had a broken value.  It was fixed in 3.4.  */
+# if PTRACE_EVENT_STOP == 7
+#  undef PTRACE_EVENT_STOP
+# endif
+#endif
+#ifndef PTRACE_EVENT_STOP
+# define PTRACE_EVENT_STOP	128
+#endif
+
+#ifndef PTRACE_O_TRACESYSGOOD
+# define PTRACE_O_TRACESYSGOOD	1
+#endif
+#ifndef PTRACE_O_TRACEFORK
+# define PTRACE_O_TRACEFORK	(1 << PTRACE_EVENT_FORK)
+#endif
+#ifndef PTRACE_O_TRACEVFORK
+# define PTRACE_O_TRACEVFORK	(1 << PTRACE_EVENT_VFORK)
+#endif
+#ifndef PTRACE_O_TRACECLONE
+# define PTRACE_O_TRACECLONE	(1 << PTRACE_EVENT_CLONE)
+#endif
+#ifndef PTRACE_O_TRACEEXEC
+# define PTRACE_O_TRACEEXEC	(1 << PTRACE_EVENT_EXEC)
+#endif
+#ifndef PTRACE_O_TRACEVFORKDONE
+# define PTRACE_O_TRACEVFORKDONE	(1 << PTRACE_EVENT_VFORK_DONE)
+#endif
+#ifndef PTRACE_O_TRACEEXIT
+# define PTRACE_O_TRACEEXIT	(1 << PTRACE_EVENT_EXIT)
+#endif
+#ifndef PTRACE_O_TRACESECCOMP
+# define PTRACE_O_TRACESECCOMP	(1 << PTRACE_EVENT_SECCOMP)
+#endif
+#ifndef PTRACE_O_EXITKILL
+# define PTRACE_O_EXITKILL	(1 << 20)
+#endif
+#ifndef PTRACE_O_SUSPEND_SECCOMP
+# define PTRACE_O_SUSPEND_SECCOMP	(1 << 21)
+#endif
+
+#ifndef PTRACE_SETOPTIONS
+# define PTRACE_SETOPTIONS	0x4200
+#endif
+#ifndef PTRACE_GETEVENTMSG
+# define PTRACE_GETEVENTMSG	0x4201
+#endif
+#ifndef PTRACE_GETSIGINFO
+# define PTRACE_GETSIGINFO	0x4202
+#endif
+#ifndef PTRACE_SETSIGINFO
+# define PTRACE_SETSIGINFO	0x4203
+#endif
+#ifndef PTRACE_GETREGSET
+# define PTRACE_GETREGSET	0x4204
+#endif
+#ifndef PTRACE_SETREGSET
+# define PTRACE_SETREGSET	0x4205
+#endif
+#ifndef PTRACE_SEIZE
+# define PTRACE_SEIZE		0x4206
+#endif
+#ifndef PTRACE_INTERRUPT
+# define PTRACE_INTERRUPT	0x4207
+#endif
+#ifndef PTRACE_LISTEN
+# define PTRACE_LISTEN		0x4208
+#endif
+#ifndef PTRACE_PEEKSIGINFO
+# define PTRACE_PEEKSIGINFO	0x4209
+#endif
+#ifndef PTRACE_GETSIGMASK
+# define PTRACE_GETSIGMASK	0x420a
+#endif
+#ifndef PTRACE_SETSIGMASK
+# define PTRACE_SETSIGMASK	0x420b
+#endif
+#ifndef PTRACE_SECCOMP_GET_FILTER
+# define PTRACE_SECCOMP_GET_FILTER	0x420c
+#endif
+
+#if !HAVE_DECL_PTRACE_PEEKUSER
+# define PTRACE_PEEKUSER PTRACE_PEEKUSR
+#endif
+#if !HAVE_DECL_PTRACE_POKEUSER
+# define PTRACE_POKEUSER PTRACE_POKEUSR
+#endif
diff --git a/strace/qemu_multiarch_testing/README b/strace/qemu_multiarch_testing/README
new file mode 100644
index 0000000..9e4ef00
--- /dev/null
+++ b/strace/qemu_multiarch_testing/README
@@ -0,0 +1,49 @@
+How to test strace build using Aboriginal Linux's system images.
+
+* Put a autoconf'ed strace source tree into hdc.dir/strace dir.
+For example, this should work:
+git clone git://strace.git.sourceforge.net/gitroot/strace/strace &&
+cd strace && ./bootstrap
+
+* Run ./make-hdc-img.sh: it will generate ext2 image file,
+hdc.img, from hdc.dir/* data. This requires root for loop mount.
+
+* Download and unpack, or build from source and unpack
+one or more system-image-ARCH directories into this directory
+(the one which contains this README).
+
+* Run: ./parallel-build-hdc-img.sh system-image-DIR1 system-image-DIR2...
+(background it if you don't want to see "Waiting to finish" thing).
+This runs a strace build in several qemu virtual machines in parallel.
+
+* Observe system-image-*.log file(s) with growing log of strace build.
+
+There is no automated detection of errors for now: you need to examine
+logs yourself.
+
+For me, the following system images worked (tests passed/skipped/failed):
+system-image-armv4l  - 14/14/1 (failed: stat32-v.test - wrong stat decoding, sun_path.test - libc error)
+system-image-armv4tl - 15/14/0
+system-image-armv5l  - 15/14/0
+system-image-armv6l  - 15/14/0
+system-image-i486    - 14/14/1 (failed: count.test - grep segfault)
+system-image-i586    - 14/14/1 (failed: count.test - grep segfault)
+system-image-i686    - 14/14/1 (failed: count.test - grep segfault)
+system-image-mips    - 15/14/0
+system-image-mipsel  - 15/14/0
+system-image-powerpc - 13/14/2 (failed: ipc_sem.test - ipc_sem segfault)
+system-image-sparc   - 13/14/2 (failed: ipc_sem.test - ipc_sem segfault)
+system-image-x86_64  - 14/15/0
+
+And these did not:
+system-image-m68k    - qemu-system-m68k: -M q800: Unsupported machine type
+system-image-mips64  - init dies before reaching /mnt/init
+system-image-sh4     - hdc does not mount (no support for 2 disks)
+
+
+To debug a build problem in one of sandboxes, change keep_hdb
+to "keep_hdb=true" in parallel-build-hdc-img.sh
+
+This preserves system-image-DIR1/hdb.img after the build,
+so you can go into system-image-DIR1 and run
+"HDB=hdb.img ./dev-environment.sh" to debug the problem.
diff --git a/strace/qemu_multiarch_testing/hdc.dir/init b/strace/qemu_multiarch_testing/hdc.dir/init
new file mode 100755
index 0000000..ea905ab
--- /dev/null
+++ b/strace/qemu_multiarch_testing/hdc.dir/init
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+# Emit a msg to let user know this place was reached
+echo "Copying to /home"
+# Had a case where cp SEGVs, let's have diagnostics for it
+cp -a /mnt /home || { echo "cp: $?"; exit 1; }
+cd /home/mnt || exit $?
+exec ./init2
+echo "Failed to exec ./init2"
diff --git a/strace/qemu_multiarch_testing/hdc.dir/init2 b/strace/qemu_multiarch_testing/hdc.dir/init2
new file mode 100755
index 0000000..8c0200a
--- /dev/null
+++ b/strace/qemu_multiarch_testing/hdc.dir/init2
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+umount /mnt # optional
+(
+	set -e -x
+	cd strace
+	./configure
+	make
+	size strace
+	make check VERBOSE=1 &&
+		cat tests/test-suite.log ||:
+	test "x$FTP_PORT" = x ||
+		ftpput -P "$FTP_PORT" "$FTP_SERVER" strace
+) 2>&1 | tee strace_build.log
+mount -o remount,ro /home
+sync
+sleep 1
diff --git a/strace/qemu_multiarch_testing/make-hdc-img.sh b/strace/qemu_multiarch_testing/make-hdc-img.sh
new file mode 100755
index 0000000..3c35f4e
--- /dev/null
+++ b/strace/qemu_multiarch_testing/make-hdc-img.sh
@@ -0,0 +1,30 @@
+#!/bin/sh -ex
+
+mountpoint -q /
+[ ! -e hdc.img.dir ]
+
+cleanup()
+{
+	trap - EXIT
+	if mountpoint -q hdc.img.dir; then
+		umount -d hdc.img.dir
+	fi
+	mountpoint -q hdc.img.dir ||
+		rm -rf hdc.img.dir
+	exit $@
+}
+
+trap 'cleanup $?' EXIT
+trap 'cleanup 1' HUP PIPE INT QUIT TERM
+
+size=$(du -ks hdc.dir | sed -rn 's/^([0-9]+).*/\1/p')
+[ "$size" -gt 0 ]
+
+rm -f hdc.img
+dd if=/dev/zero of=hdc.img count=1 bs=1024 seek=$(($size*2))
+mkfs.ext3 -q -F -b 1024 -i 4096 hdc.img
+tune2fs -c 0 -i 0 hdc.img
+mkdir hdc.img.dir
+mount -o loop hdc.img hdc.img.dir
+cp -a hdc.dir/* hdc.img.dir/
+umount -d hdc.img.dir
diff --git a/strace/qemu_multiarch_testing/parallel-build-hdc-img.sh b/strace/qemu_multiarch_testing/parallel-build-hdc-img.sh
new file mode 100755
index 0000000..8d27367
--- /dev/null
+++ b/strace/qemu_multiarch_testing/parallel-build-hdc-img.sh
@@ -0,0 +1,31 @@
+#!/bin/sh
+
+export HDBMEGS=64
+keep_hdb=false
+
+build_in_dir()
+{
+	cd "$1" || exit 1
+	rm -f hdb.img
+	nice -n10 time ./native-build.sh ../hdc.img
+	$keep_hdb || rm -f hdb.img
+	echo >&3 "Finished: $1"
+}
+
+started=false
+for dir; do
+	test -d "$dir" || continue
+	test -e "$dir/native-build.sh" || continue
+	echo "Starting: $dir"
+	build_in_dir "$dir" 3>&1 </dev/null >"$dir.log" 2>&1 &
+	started=true
+done
+
+$started || {
+	echo "Give me system-image-ARCH directories on command line"
+	exit 1
+}
+
+echo "Waiting to finish"
+wait
+echo "Done, check the logs"
diff --git a/strace/quota.c b/strace/quota.c
new file mode 100644
index 0000000..0a388b2
--- /dev/null
+++ b/strace/quota.c
@@ -0,0 +1,540 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#define SUBCMDMASK  0x00ff
+#define SUBCMDSHIFT 8
+#define QCMD_CMD(cmd)	((uint32_t)(cmd) >> SUBCMDSHIFT)
+#define QCMD_TYPE(cmd)	((uint32_t)(cmd) & SUBCMDMASK)
+
+#define OLD_CMD(cmd)	((uint32_t)(cmd) << SUBCMDSHIFT)
+#define NEW_CMD(cmd)	((uint32_t)(cmd) | 0x800000)
+#define XQM_CMD(cmd)	((uint32_t)(cmd) | ('X' << SUBCMDSHIFT))
+
+#include "xlat/quotacmds.h"
+#include "xlat/quotatypes.h"
+#include "xlat/quota_formats.h"
+#include "xlat/xfs_quota_flags.h"
+#include "xlat/xfs_dqblk_flags.h"
+#include "xlat/if_dqblk_valid.h"
+#include "xlat/if_dqinfo_flags.h"
+#include "xlat/if_dqinfo_valid.h"
+
+struct if_dqblk
+{
+	uint64_t dqb_bhardlimit;
+	uint64_t dqb_bsoftlimit;
+	uint64_t dqb_curspace;
+	uint64_t dqb_ihardlimit;
+	uint64_t dqb_isoftlimit;
+	uint64_t dqb_curinodes;
+	uint64_t dqb_btime;
+	uint64_t dqb_itime;
+	uint32_t dqb_valid;
+};
+
+struct if_nextdqblk {
+	uint64_t dqb_bhardlimit;
+	uint64_t dqb_bsoftlimit;
+	uint64_t dqb_curspace;
+	uint64_t dqb_ihardlimit;
+	uint64_t dqb_isoftlimit;
+	uint64_t dqb_curinodes;
+	uint64_t dqb_btime;
+	uint64_t dqb_itime;
+	uint32_t dqb_valid;
+	uint32_t dqb_id;
+};
+
+struct v1_dqblk
+{
+	uint32_t dqb_bhardlimit;	/* absolute limit on disk blks alloc */
+	uint32_t dqb_bsoftlimit;	/* preferred limit on disk blks */
+	uint32_t dqb_curblocks;		/* current block count */
+	uint32_t dqb_ihardlimit;	/* maximum # allocated inodes */
+	uint32_t dqb_isoftlimit;	/* preferred inode limit */
+	uint32_t dqb_curinodes;		/* current # allocated inodes */
+	time_t  dqb_btime;		/* time limit for excessive disk use */
+	time_t  dqb_itime;		/* time limit for excessive files */
+};
+
+struct v2_dqblk
+{
+	unsigned int dqb_ihardlimit;
+	unsigned int dqb_isoftlimit;
+	unsigned int dqb_curinodes;
+	unsigned int dqb_bhardlimit;
+	unsigned int dqb_bsoftlimit;
+	uint64_t dqb_curspace;
+	time_t  dqb_btime;
+	time_t  dqb_itime;
+};
+
+struct xfs_dqblk
+{
+	int8_t  d_version;		/* version of this structure */
+	int8_t  d_flags;		/* XFS_{USER,PROJ,GROUP}_QUOTA */
+	uint16_t d_fieldmask;		/* field specifier */
+	uint32_t d_id;			/* user, project, or group ID */
+	uint64_t d_blk_hardlimit;	/* absolute limit on disk blks */
+	uint64_t d_blk_softlimit;	/* preferred limit on disk blks */
+	uint64_t d_ino_hardlimit;	/* maximum # allocated inodes */
+	uint64_t d_ino_softlimit;	/* preferred inode limit */
+	uint64_t d_bcount;		/* # disk blocks owned by the user */
+	uint64_t d_icount;		/* # inodes owned by the user */
+	int32_t d_itimer;		/* zero if within inode limits */
+	int32_t d_btimer;		/* similar to above; for disk blocks */
+	uint16_t d_iwarns;		/* # warnings issued wrt num inodes */
+	uint16_t d_bwarns;		/* # warnings issued wrt disk blocks */
+	int32_t d_padding2;		/* padding2 - for future use */
+	uint64_t d_rtb_hardlimit;	/* absolute limit on realtime blks */
+	uint64_t d_rtb_softlimit;	/* preferred limit on RT disk blks */
+	uint64_t d_rtbcount;		/* # realtime blocks owned */
+	int32_t d_rtbtimer;		/* similar to above; for RT disk blks */
+	uint16_t d_rtbwarns;		/* # warnings issued wrt RT disk blks */
+	int16_t d_padding3;		/* padding3 - for future use */
+	char    d_padding4[8];		/* yet more padding */
+};
+
+struct if_dqinfo
+{
+	uint64_t dqi_bgrace;
+	uint64_t dqi_igrace;
+	uint32_t dqi_flags;
+	uint32_t dqi_valid;
+};
+
+struct v2_dqinfo
+{
+	unsigned int dqi_bgrace;
+	unsigned int dqi_igrace;
+	unsigned int dqi_flags;
+	unsigned int dqi_blocks;
+	unsigned int dqi_free_blk;
+	unsigned int dqi_free_entry;
+};
+
+struct v1_dqstats
+{
+	uint32_t lookups;
+	uint32_t drops;
+	uint32_t reads;
+	uint32_t writes;
+	uint32_t cache_hits;
+	uint32_t allocated_dquots;
+	uint32_t free_dquots;
+	uint32_t syncs;
+};
+
+struct v2_dqstats
+{
+	uint32_t lookups;
+	uint32_t drops;
+	uint32_t reads;
+	uint32_t writes;
+	uint32_t cache_hits;
+	uint32_t allocated_dquots;
+	uint32_t free_dquots;
+	uint32_t syncs;
+	uint32_t version;
+};
+
+typedef struct fs_qfilestat
+{
+	uint64_t qfs_ino;	/* inode number */
+	uint64_t qfs_nblks;	/* number of BBs 512-byte-blks */
+	uint32_t qfs_nextents;	/* number of extents */
+} fs_qfilestat_t;
+
+struct xfs_dqstats
+{
+	int8_t  qs_version;		/* version number for future changes */
+	uint16_t qs_flags;		/* XFS_QUOTA_{U,P,G}DQ_{ACCT,ENFD} */
+	int8_t  qs_pad;			/* unused */
+	fs_qfilestat_t qs_uquota;	/* user quota storage information */
+	fs_qfilestat_t qs_gquota;	/* group quota storage information */
+	uint32_t qs_incoredqs;		/* number of dquots incore */
+	int32_t qs_btimelimit;		/* limit for blks timer */
+	int32_t qs_itimelimit;		/* limit for inodes timer */
+	int32_t qs_rtbtimelimit;	/* limit for rt blks timer */
+	uint16_t qs_bwarnlimit;		/* limit for num warnings */
+	uint16_t qs_iwarnlimit;		/* limit for num warnings */
+};
+
+struct fs_qfilestatv {
+	uint64_t qfs_ino, qfs_nblks;
+	uint32_t qfs_nextents, qfs_pad;
+};
+
+struct fs_quota_statv {
+	int8_t qs_version;
+	uint8_t qs_pad1;
+	uint16_t qs_flags;
+	uint32_t qs_incoredqs;
+	struct fs_qfilestatv qs_uquota;
+	struct fs_qfilestatv qs_gquota;
+	struct fs_qfilestatv qs_pquota;
+	int32_t qs_btimelimit;
+	int32_t qs_itimelimit;
+	int32_t qs_rtbtimelimit;
+	uint16_t qs_bwarnlimit;
+	uint16_t qs_iwarnlimit;
+	uint64_t qs_pad2[8];
+};
+
+static int
+decode_cmd_data(struct tcb *tcp, uint32_t cmd, unsigned long data)
+{
+	switch (cmd) {
+		case Q_GETQUOTA:
+			if (entering(tcp))
+				return 0;
+		case Q_SETQUOTA:
+		{
+			struct if_dqblk dq;
+
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{bhardlimit=%" PRIu64 ", ", dq.dqb_bhardlimit);
+			tprintf("bsoftlimit=%" PRIu64 ", ", dq.dqb_bsoftlimit);
+			tprintf("curspace=%" PRIu64 ", ", dq.dqb_curspace);
+			tprintf("ihardlimit=%" PRIu64 ", ", dq.dqb_ihardlimit);
+			tprintf("isoftlimit=%" PRIu64 ", ", dq.dqb_isoftlimit);
+			tprintf("curinodes=%" PRIu64 ", ", dq.dqb_curinodes);
+			if (!abbrev(tcp)) {
+				tprintf("btime=%" PRIu64 ", ", dq.dqb_btime);
+				tprintf("itime=%" PRIu64 ", ", dq.dqb_itime);
+				tprints("valid=");
+				printflags(if_dqblk_valid,
+					   dq.dqb_valid, "QIF_???");
+				tprints("}");
+			} else
+				tprints("...}");
+			break;
+		}
+		case Q_GETNEXTQUOTA:
+		{
+			struct if_nextdqblk dq;
+
+			if (entering(tcp))
+				return 0;
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{bhardlimit=%" PRIu64 ", ", dq.dqb_bhardlimit);
+			tprintf("bsoftlimit=%" PRIu64 ", ", dq.dqb_bsoftlimit);
+			tprintf("curspace=%" PRIu64 ", ", dq.dqb_curspace);
+			tprintf("ihardlimit=%" PRIu64 ", ", dq.dqb_ihardlimit);
+			tprintf("isoftlimit=%" PRIu64 ", ", dq.dqb_isoftlimit);
+			tprintf("curinodes=%" PRIu64 ", ", dq.dqb_curinodes);
+			if (!abbrev(tcp)) {
+				tprintf("btime=%" PRIu64 ", ", dq.dqb_btime);
+				tprintf("itime=%" PRIu64 ", ", dq.dqb_itime);
+				tprints("valid=");
+				printflags(if_dqblk_valid,
+					   dq.dqb_valid, "QIF_???");
+				tprintf(", id=%u}", dq.dqb_id);
+			} else
+				tprintf("id=%u, ...}", dq.dqb_id);
+			break;
+		}
+		case Q_V1_GETQUOTA:
+			if (entering(tcp))
+				return 0;
+		case Q_V1_SETQUOTA:
+		{
+			struct v1_dqblk dq;
+
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{bhardlimit=%u, ", dq.dqb_bhardlimit);
+			tprintf("bsoftlimit=%u, ", dq.dqb_bsoftlimit);
+			tprintf("curblocks=%u, ", dq.dqb_curblocks);
+			tprintf("ihardlimit=%u, ", dq.dqb_ihardlimit);
+			tprintf("isoftlimit=%u, ", dq.dqb_isoftlimit);
+			tprintf("curinodes=%u, ", dq.dqb_curinodes);
+			tprintf("btime=%lu, ", (long) dq.dqb_btime);
+			tprintf("itime=%lu}", (long) dq.dqb_itime);
+			break;
+		}
+		case Q_V2_GETQUOTA:
+			if (entering(tcp))
+				return 0;
+		case Q_V2_SETQUOTA:
+		{
+			struct v2_dqblk dq;
+
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{ihardlimit=%u, ", dq.dqb_ihardlimit);
+			tprintf("isoftlimit=%u, ", dq.dqb_isoftlimit);
+			tprintf("curinodes=%u, ", dq.dqb_curinodes);
+			tprintf("bhardlimit=%u, ", dq.dqb_bhardlimit);
+			tprintf("bsoftlimit=%u, ", dq.dqb_bsoftlimit);
+			tprintf("curspace=%" PRIu64 ", ", dq.dqb_curspace);
+			tprintf("btime=%lu, ", (long) dq.dqb_btime);
+			tprintf("itime=%lu}", (long) dq.dqb_itime);
+			break;
+		}
+		case Q_XGETQUOTA:
+		case Q_XGETNEXTQUOTA:
+			if (entering(tcp))
+				return 0;
+		case Q_XSETQLIM:
+		{
+			struct xfs_dqblk dq;
+
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{version=%d, ", dq.d_version);
+			tprints("flags=");
+			printflags(xfs_dqblk_flags,
+				   (uint8_t) dq.d_flags, "XFS_???_QUOTA");
+			tprintf(", fieldmask=%#x, ", dq.d_fieldmask);
+			tprintf("id=%u, ", dq.d_id);
+			tprintf("blk_hardlimit=%" PRIu64 ", ", dq.d_blk_hardlimit);
+			tprintf("blk_softlimit=%" PRIu64 ", ", dq.d_blk_softlimit);
+			tprintf("ino_hardlimit=%" PRIu64 ", ", dq.d_ino_hardlimit);
+			tprintf("ino_softlimit=%" PRIu64 ", ", dq.d_ino_softlimit);
+			tprintf("bcount=%" PRIu64 ", ", dq.d_bcount);
+			tprintf("icount=%" PRIu64 ", ", dq.d_icount);
+			if (!abbrev(tcp)) {
+				tprintf("itimer=%d, ", dq.d_itimer);
+				tprintf("btimer=%d, ", dq.d_btimer);
+				tprintf("iwarns=%u, ", dq.d_iwarns);
+				tprintf("bwarns=%u, ", dq.d_bwarns);
+				tprintf("rtbcount=%" PRIu64 ", ", dq.d_rtbcount);
+				tprintf("rtbtimer=%d, ", dq.d_rtbtimer);
+				tprintf("rtbwarns=%u}", dq.d_rtbwarns);
+			} else
+				tprints("...}");
+			break;
+		}
+		case Q_GETFMT:
+		{
+			uint32_t fmt;
+
+			if (entering(tcp))
+				return 0;
+			if (umove_or_printaddr(tcp, data, &fmt))
+				break;
+			tprints("[");
+			printxval(quota_formats, fmt, "QFMT_VFS_???");
+			tprints("]");
+			break;
+		}
+		case Q_GETINFO:
+			if (entering(tcp))
+				return 0;
+		case Q_SETINFO:
+		{
+			struct if_dqinfo dq;
+
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{bgrace=%" PRIu64 ", ", dq.dqi_bgrace);
+			tprintf("igrace=%" PRIu64 ", ", dq.dqi_igrace);
+			tprints("flags=");
+			printflags(if_dqinfo_flags, dq.dqi_flags, "DQF_???");
+			tprints(", valid=");
+			printflags(if_dqinfo_valid, dq.dqi_valid, "IIF_???");
+			tprints("}");
+			break;
+		}
+		case Q_V2_GETINFO:
+			if (entering(tcp))
+				return 0;
+		case Q_V2_SETINFO:
+		{
+			struct v2_dqinfo dq;
+
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{bgrace=%u, ", dq.dqi_bgrace);
+			tprintf("igrace=%u, ", dq.dqi_igrace);
+			tprints("flags=");
+			printflags(if_dqinfo_flags, dq.dqi_flags, "DQF_???");
+			tprintf(", blocks=%u, ", dq.dqi_blocks);
+			tprintf("free_blk=%u, ", dq.dqi_free_blk);
+			tprintf("free_entry=%u}", dq.dqi_free_entry);
+			break;
+		}
+		case Q_V1_GETSTATS:
+		{
+			struct v1_dqstats dq;
+
+			if (entering(tcp))
+				return 0;
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{lookups=%u, ", dq.lookups);
+			tprintf("drops=%u, ", dq.drops);
+			tprintf("reads=%u, ", dq.reads);
+			tprintf("writes=%u, ", dq.writes);
+			tprintf("cache_hits=%u, ", dq.cache_hits);
+			tprintf("allocated_dquots=%u, ", dq.allocated_dquots);
+			tprintf("free_dquots=%u, ", dq.free_dquots);
+			tprintf("syncs=%u}", dq.syncs);
+			break;
+		}
+		case Q_V2_GETSTATS:
+		{
+			struct v2_dqstats dq;
+
+			if (entering(tcp))
+				return 0;
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{lookups=%u, ", dq.lookups);
+			tprintf("drops=%u, ", dq.drops);
+			tprintf("reads=%u, ", dq.reads);
+			tprintf("writes=%u, ", dq.writes);
+			tprintf("cache_hits=%u, ", dq.cache_hits);
+			tprintf("allocated_dquots=%u, ", dq.allocated_dquots);
+			tprintf("free_dquots=%u, ", dq.free_dquots);
+			tprintf("syncs=%u, ", dq.syncs);
+			tprintf("version=%u}", dq.version);
+			break;
+		}
+		case Q_XGETQSTAT:
+		{
+			struct xfs_dqstats dq;
+
+			if (entering(tcp))
+				return 0;
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{version=%d, ", dq.qs_version);
+			if (abbrev(tcp)) {
+				tprints("...}");
+				break;
+			}
+			tprints("flags=");
+			printflags(xfs_quota_flags,
+				   dq.qs_flags, "XFS_QUOTA_???");
+			tprintf(", incoredqs=%u, ", dq.qs_incoredqs);
+			tprintf("u_ino=%" PRIu64 ", ", dq.qs_uquota.qfs_ino);
+			tprintf("u_nblks=%" PRIu64 ", ", dq.qs_uquota.qfs_nblks);
+			tprintf("u_nextents=%u, ", dq.qs_uquota.qfs_nextents);
+			tprintf("g_ino=%" PRIu64 ", ", dq.qs_gquota.qfs_ino);
+			tprintf("g_nblks=%" PRIu64 ", ", dq.qs_gquota.qfs_nblks);
+			tprintf("g_nextents=%u, ", dq.qs_gquota.qfs_nextents);
+			tprintf("btimelimit=%d, ", dq.qs_btimelimit);
+			tprintf("itimelimit=%d, ", dq.qs_itimelimit);
+			tprintf("rtbtimelimit=%d, ", dq.qs_rtbtimelimit);
+			tprintf("bwarnlimit=%u, ", dq.qs_bwarnlimit);
+			tprintf("iwarnlimit=%u}", dq.qs_iwarnlimit);
+			break;
+		}
+		case Q_XGETQSTATV:
+		{
+			struct fs_quota_statv dq;
+
+			if (entering(tcp))
+				return 0;
+			if (umove_or_printaddr(tcp, data, &dq))
+				break;
+			tprintf("{version=%d, ", dq.qs_version);
+			if (abbrev(tcp)) {
+				tprints("...}");
+				break;
+			}
+			tprints("flags=");
+			printflags(xfs_quota_flags,
+				   dq.qs_flags, "XFS_QUOTA_???");
+			tprintf(", incoredqs=%u, ", dq.qs_incoredqs);
+			tprintf("u_ino=%" PRIu64 ", ", dq.qs_uquota.qfs_ino);
+			tprintf("u_nblks=%" PRIu64 ", ", dq.qs_uquota.qfs_nblks);
+			tprintf("u_nextents=%u, ", dq.qs_uquota.qfs_nextents);
+			tprintf("g_ino=%" PRIu64 ", ", dq.qs_gquota.qfs_ino);
+			tprintf("g_nblks=%" PRIu64 ", ", dq.qs_gquota.qfs_nblks);
+			tprintf("g_nextents=%u, ", dq.qs_gquota.qfs_nextents);
+			tprintf("p_ino=%" PRIu64 ", ", dq.qs_pquota.qfs_ino);
+			tprintf("p_nblks=%" PRIu64 ", ", dq.qs_pquota.qfs_nblks);
+			tprintf("p_nextents=%u, ", dq.qs_pquota.qfs_nextents);
+			tprintf("btimelimit=%d, ", dq.qs_btimelimit);
+			tprintf("itimelimit=%d, ", dq.qs_itimelimit);
+			tprintf("rtbtimelimit=%d, ", dq.qs_rtbtimelimit);
+			tprintf("bwarnlimit=%u, ", dq.qs_bwarnlimit);
+			tprintf("iwarnlimit=%u}", dq.qs_iwarnlimit);
+			break;
+		}
+		case Q_XQUOTAON:
+		case Q_XQUOTAOFF:
+		{
+			uint32_t flag;
+
+			if (umove_or_printaddr(tcp, data, &flag))
+				break;
+			tprints("[");
+			printflags(xfs_quota_flags, flag, "XFS_QUOTA_???");
+			tprints("]");
+			break;
+		}
+		default:
+			printaddr(data);
+			break;
+	}
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(quotactl)
+{
+	/*
+	 * The Linux kernel only looks at the low 32 bits of command and id
+	 * arguments, but on some 64-bit architectures (s390x) this word
+	 * will have been sign-extended when we see it.  The high 1 bits
+	 * don't mean anything, so don't confuse the output with them.
+	 */
+	uint32_t qcmd = tcp->u_arg[0];
+	uint32_t cmd = QCMD_CMD(qcmd);
+	uint32_t type = QCMD_TYPE(qcmd);
+	uint32_t id = tcp->u_arg[2];
+
+	if (entering(tcp)) {
+		printxval(quotacmds, cmd, "Q_???");
+		tprints("|");
+		printxval(quotatypes, type, "???QUOTA");
+		tprints(", ");
+		printpath(tcp, tcp->u_arg[1]);
+		tprints(", ");
+		switch (cmd) {
+			case Q_QUOTAON:
+			case Q_V1_QUOTAON:
+				printxval(quota_formats, id, "QFMT_VFS_???");
+				tprints(", ");
+				printpath(tcp, tcp->u_arg[3]);
+				return RVAL_DECODED;
+		}
+		tprintf("%u, ", id);
+	}
+	return decode_cmd_data(tcp, cmd, tcp->u_arg[3]);
+}
diff --git a/strace/readahead.c b/strace/readahead.c
new file mode 100644
index 0000000..3f8e4ce
--- /dev/null
+++ b/strace/readahead.c
@@ -0,0 +1,12 @@
+#include "defs.h"
+
+SYS_FUNC(readahead)
+{
+	int argn;
+
+	printfd(tcp, tcp->u_arg[0]);
+	argn = printllval(tcp, ", %lld", 1);
+	tprintf(", %ld", tcp->u_arg[argn]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/readlink.c b/strace/readlink.c
new file mode 100644
index 0000000..299b083
--- /dev/null
+++ b/strace/readlink.c
@@ -0,0 +1,69 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2006 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2006 Bernhard Kaindl <bk@suse.de>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+static int
+decode_readlink(struct tcb *tcp, int offset)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[offset]);
+		tprints(", ");
+	} else {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[offset + 1]);
+		else
+			/* Used to use printpathn(), but readlink
+			 * neither includes NUL in the returned count,
+			 * nor actually writes it into memory.
+			 * printpathn() would decide on printing
+			 * "..." continuation based on garbage
+			 * past return buffer's end.
+			 */
+			printstr(tcp, tcp->u_arg[offset + 1], tcp->u_rval);
+		tprintf(", %lu", tcp->u_arg[offset + 2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(readlink)
+{
+	return decode_readlink(tcp, 0);
+}
+
+SYS_FUNC(readlinkat)
+{
+	if (entering(tcp))
+		print_dirfd(tcp, tcp->u_arg[0]);
+	return decode_readlink(tcp, 1);
+}
diff --git a/strace/reboot.c b/strace/reboot.c
new file mode 100644
index 0000000..1669a3d
--- /dev/null
+++ b/strace/reboot.c
@@ -0,0 +1,23 @@
+#include "defs.h"
+
+#include "xlat/bootflags1.h"
+#include "xlat/bootflags2.h"
+#include "xlat/bootflags3.h"
+
+SYS_FUNC(reboot)
+{
+	const unsigned int magic1 = tcp->u_arg[0];
+	const unsigned int magic2 = tcp->u_arg[1];
+	const unsigned int cmd = tcp->u_arg[2];
+
+	printflags(bootflags1, magic1, "LINUX_REBOOT_MAGIC_???");
+	tprints(", ");
+	printflags(bootflags2, magic2, "LINUX_REBOOT_MAGIC_???");
+	tprints(", ");
+	printflags(bootflags3, cmd, "LINUX_REBOOT_CMD_???");
+	if (cmd == LINUX_REBOOT_CMD_RESTART2) {
+		tprints(", ");
+		printstr(tcp, tcp->u_arg[3], -1);
+	}
+	return RVAL_DECODED;
+}
diff --git a/strace/regs.h b/strace/regs.h
new file mode 100644
index 0000000..9b0746c
--- /dev/null
+++ b/strace/regs.h
@@ -0,0 +1,7 @@
+#include <sys/user.h>
+
+#ifdef HAVE_SYS_REG_H
+# include <sys/reg.h>
+#endif
+
+#include "arch_regs.h"
diff --git a/strace/renameat.c b/strace/renameat.c
new file mode 100644
index 0000000..746e9c4
--- /dev/null
+++ b/strace/renameat.c
@@ -0,0 +1,30 @@
+#include "defs.h"
+
+static void
+decode_renameat(struct tcb *tcp)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	print_dirfd(tcp, tcp->u_arg[2]);
+	printpath(tcp, tcp->u_arg[3]);
+}
+
+SYS_FUNC(renameat)
+{
+	decode_renameat(tcp);
+
+	return RVAL_DECODED;
+}
+
+#include <linux/fs.h>
+#include "xlat/rename_flags.h"
+
+SYS_FUNC(renameat2)
+{
+	decode_renameat(tcp);
+	tprints(", ");
+	printflags(rename_flags, tcp->u_arg[4], "RENAME_??");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/resource.c b/strace/resource.c
new file mode 100644
index 0000000..475afc2
--- /dev/null
+++ b/strace/resource.c
@@ -0,0 +1,198 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <sys/resource.h>
+
+#include "xlat/resources.h"
+
+static const char *
+sprint_rlim64(uint64_t lim)
+{
+	static char buf[sizeof(uint64_t)*3 + sizeof("*1024")];
+
+	if (lim == UINT64_MAX)
+		return "RLIM64_INFINITY";
+
+	if (lim > 1024 && lim % 1024 == 0)
+		sprintf(buf, "%" PRIu64 "*1024", lim / 1024);
+	else
+		sprintf(buf, "%" PRIu64, lim);
+	return buf;
+}
+
+static void
+print_rlimit64(struct tcb *tcp, unsigned long addr)
+{
+	struct rlimit_64 {
+		uint64_t rlim_cur;
+		uint64_t rlim_max;
+	} rlim;
+
+	if (!umove_or_printaddr(tcp, addr, &rlim)) {
+		tprintf("{rlim_cur=%s,", sprint_rlim64(rlim.rlim_cur));
+		tprintf(" rlim_max=%s}", sprint_rlim64(rlim.rlim_max));
+	}
+}
+
+#if !defined(current_wordsize) || current_wordsize == 4
+
+static const char *
+sprint_rlim32(uint32_t lim)
+{
+	static char buf[sizeof(uint32_t)*3 + sizeof("*1024")];
+
+	if (lim == UINT32_MAX)
+		return "RLIM_INFINITY";
+
+	if (lim > 1024 && lim % 1024 == 0)
+		sprintf(buf, "%" PRIu32 "*1024", lim / 1024);
+	else
+		sprintf(buf, "%" PRIu32, lim);
+	return buf;
+}
+
+static void
+print_rlimit32(struct tcb *tcp, unsigned long addr)
+{
+	struct rlimit_32 {
+		uint32_t rlim_cur;
+		uint32_t rlim_max;
+	} rlim;
+
+	if (!umove_or_printaddr(tcp, addr, &rlim)) {
+		tprintf("{rlim_cur=%s,", sprint_rlim32(rlim.rlim_cur));
+		tprintf(" rlim_max=%s}", sprint_rlim32(rlim.rlim_max));
+	}
+}
+
+static void
+decode_rlimit(struct tcb *tcp, unsigned long addr)
+{
+# if defined(X86_64) || defined(X32)
+	/*
+	 * i386 is the only personality on X86_64 and X32
+	 * with 32-bit rlim_t.
+	 * When current_personality is X32, current_wordsize
+	 * equals to 4 but rlim_t is 64-bit.
+	 */
+	if (current_personality == 1)
+# else
+	if (current_wordsize == 4)
+# endif
+		print_rlimit32(tcp, addr);
+	else
+		print_rlimit64(tcp, addr);
+}
+
+#else /* defined(current_wordsize) && current_wordsize != 4 */
+
+# define decode_rlimit print_rlimit64
+
+#endif
+
+SYS_FUNC(getrlimit)
+{
+	if (entering(tcp)) {
+		printxval(resources, tcp->u_arg[0], "RLIMIT_???");
+		tprints(", ");
+	}
+	else {
+		decode_rlimit(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+SYS_FUNC(setrlimit)
+{
+	printxval(resources, tcp->u_arg[0], "RLIMIT_???");
+	tprints(", ");
+	decode_rlimit(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(prlimit64)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+		printxval(resources, tcp->u_arg[1], "RLIMIT_???");
+		tprints(", ");
+		print_rlimit64(tcp, tcp->u_arg[2]);
+		tprints(", ");
+	} else {
+		print_rlimit64(tcp, tcp->u_arg[3]);
+	}
+	return 0;
+}
+
+#include "xlat/usagewho.h"
+
+SYS_FUNC(getrusage)
+{
+	if (entering(tcp)) {
+		printxval(usagewho, tcp->u_arg[0], "RUSAGE_???");
+		tprints(", ");
+	}
+	else
+		printrusage(tcp, tcp->u_arg[1]);
+	return 0;
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_getrusage)
+{
+	if (entering(tcp)) {
+		printxval(usagewho, tcp->u_arg[0], "RUSAGE_???");
+		tprints(", ");
+	}
+	else
+		printrusage32(tcp, tcp->u_arg[1]);
+	return 0;
+}
+#endif /* ALPHA */
+
+#include "xlat/priorities.h"
+
+SYS_FUNC(getpriority)
+{
+	printxval(priorities, tcp->u_arg[0], "PRIO_???");
+	tprintf(", %d", (int) tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(setpriority)
+{
+	printxval(priorities, tcp->u_arg[0], "PRIO_???");
+	tprintf(", %d, %d", (int) tcp->u_arg[1], (int) tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/rtc.c b/strace/rtc.c
new file mode 100644
index 0000000..7f123e4
--- /dev/null
+++ b/strace/rtc.c
@@ -0,0 +1,154 @@
+/*
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2004-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(struct_rtc_pll_info)
+
+#include <linux/ioctl.h>
+#include <linux/rtc.h>
+
+typedef struct rtc_pll_info struct_rtc_pll_info;
+
+#include MPERS_DEFS
+
+static void
+print_rtc_time(struct tcb *tcp, const struct rtc_time *rt)
+{
+	tprintf("{tm_sec=%d, tm_min=%d, tm_hour=%d, "
+		"tm_mday=%d, tm_mon=%d, tm_year=%d, ",
+		rt->tm_sec, rt->tm_min, rt->tm_hour,
+		rt->tm_mday, rt->tm_mon, rt->tm_year);
+	if (!abbrev(tcp))
+		tprintf("tm_wday=%d, tm_yday=%d, tm_isdst=%d}",
+			rt->tm_wday, rt->tm_yday, rt->tm_isdst);
+	else
+		tprints("...}");
+}
+
+static void
+decode_rtc_time(struct tcb *tcp, const long addr)
+{
+	struct rtc_time rt;
+
+	if (!umove_or_printaddr(tcp, addr, &rt))
+		print_rtc_time(tcp, &rt);
+}
+
+static void
+decode_rtc_wkalrm(struct tcb *tcp, const long addr)
+{
+	struct rtc_wkalrm wk;
+
+	if (!umove_or_printaddr(tcp, addr, &wk)) {
+		tprintf("{enabled=%d, pending=%d, time=", wk.enabled, wk.pending);
+		print_rtc_time(tcp, &wk.time);
+		tprints("}");
+	}
+}
+
+static void
+decode_rtc_pll_info(struct tcb *tcp, const long addr)
+{
+	struct_rtc_pll_info pll;
+
+	if (!umove_or_printaddr(tcp, addr, &pll))
+		tprintf("{pll_ctrl=%d, pll_value=%d, pll_max=%d, pll_min=%d"
+			", pll_posmult=%d, pll_negmult=%d, pll_clock=%ld}",
+			pll.pll_ctrl, pll.pll_value, pll.pll_max, pll.pll_min,
+			pll.pll_posmult, pll.pll_negmult, (long) pll.pll_clock);
+}
+
+MPERS_PRINTER_DECL(int, rtc_ioctl, struct tcb *tcp,
+		   const unsigned int code, const long arg)
+{
+	switch (code) {
+	case RTC_ALM_READ:
+	case RTC_RD_TIME:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case RTC_ALM_SET:
+	case RTC_SET_TIME:
+		tprints(", ");
+		decode_rtc_time(tcp, arg);
+		break;
+	case RTC_IRQP_SET:
+	case RTC_EPOCH_SET:
+		tprintf(", %lu", arg);
+		break;
+	case RTC_IRQP_READ:
+	case RTC_EPOCH_READ:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_ulong(tcp, arg);
+		break;
+	case RTC_WKALM_RD:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case RTC_WKALM_SET:
+		tprints(", ");
+		decode_rtc_wkalrm(tcp, arg);
+		break;
+	case RTC_PLL_GET:
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case RTC_PLL_SET:
+		tprints(", ");
+		decode_rtc_pll_info(tcp, arg);
+		break;
+#ifdef RTC_VL_READ
+	case RTC_VL_READ:
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+#endif
+	case RTC_AIE_ON:
+	case RTC_AIE_OFF:
+	case RTC_UIE_ON:
+	case RTC_UIE_OFF:
+	case RTC_PIE_ON:
+	case RTC_PIE_OFF:
+	case RTC_WIE_ON:
+	case RTC_WIE_OFF:
+#ifdef RTC_VL_CLR
+	case RTC_VL_CLR:
+#endif
+		/* no args */
+		break;
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/sched.c b/strace/sched.c
new file mode 100644
index 0000000..86d4c22
--- /dev/null
+++ b/strace/sched.c
@@ -0,0 +1,147 @@
+/*
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2012-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sched.h>
+
+#include "xlat/schedulers.h"
+#include "xlat/sched_flags.h"
+
+SYS_FUNC(sched_getscheduler)
+{
+	if (entering(tcp)) {
+		tprintf("%d", (int) tcp->u_arg[0]);
+	} else if (!syserror(tcp)) {
+		tcp->auxstr = xlookup(schedulers, (unsigned long) tcp->u_rval);
+		if (tcp->auxstr != NULL)
+			return RVAL_STR;
+	}
+	return 0;
+}
+
+SYS_FUNC(sched_setscheduler)
+{
+	tprintf("%d, ", (int) tcp->u_arg[0]);
+	printxval(schedulers, tcp->u_arg[1], "SCHED_???");
+	tprints(", ");
+	printnum_int(tcp, tcp->u_arg[2], "%d");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sched_getparam)
+{
+	if (entering(tcp))
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+	else
+		printnum_int(tcp, tcp->u_arg[1], "%d");
+	return 0;
+}
+
+SYS_FUNC(sched_setparam)
+{
+	tprintf("%d, ", (int) tcp->u_arg[0]);
+	printnum_int(tcp, tcp->u_arg[1], "%d");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sched_get_priority_min)
+{
+	printxval(schedulers, tcp->u_arg[0], "SCHED_???");
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sched_rr_get_interval)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+	} else {
+		if (syserror(tcp))
+			printaddr(tcp->u_arg[1]);
+		else
+			print_timespec(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+static void
+print_sched_attr(struct tcb *tcp, const long addr, unsigned int size)
+{
+	struct {
+		uint32_t size;
+		uint32_t sched_policy;
+		uint64_t sched_flags;
+		uint32_t sched_nice;
+		uint32_t sched_priority;
+		uint64_t sched_runtime;
+		uint64_t sched_deadline;
+		uint64_t sched_period;
+	} attr = {};
+
+	if (size > sizeof(attr))
+		size = sizeof(attr);
+	if (umoven_or_printaddr(tcp, addr, size, &attr))
+		return;
+
+	tprintf("{size=%u, sched_policy=", attr.size);
+	printxval(schedulers, attr.sched_policy, "SCHED_???");
+	tprints(", sched_flags=");
+	printflags64(sched_flags, attr.sched_flags, "SCHED_FLAG_???");
+	tprintf(", sched_nice=%d", attr.sched_nice);
+	tprintf(", sched_priority=%u", attr.sched_priority);
+	tprintf(", sched_runtime=%" PRIu64, attr.sched_runtime);
+	tprintf(", sched_deadline=%" PRIu64, attr.sched_deadline);
+	tprintf(", sched_period=%" PRIu64 "}", attr.sched_period);
+}
+
+SYS_FUNC(sched_setattr)
+{
+	tprintf("%d, ", (int) tcp->u_arg[0]);
+	print_sched_attr(tcp, tcp->u_arg[1], 0x100);
+	tprintf(", %u", (unsigned int) tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sched_getattr)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+	} else {
+		print_sched_attr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+		tprintf(", %u, %u",
+			(unsigned int) tcp->u_arg[2],
+			(unsigned int) tcp->u_arg[3]);
+	}
+
+	return 0;
+}
diff --git a/strace/scsi.c b/strace/scsi.c
new file mode 100644
index 0000000..dc51dd5
--- /dev/null
+++ b/strace/scsi.c
@@ -0,0 +1,283 @@
+/*
+ * Copyright (c) 2007 Vladimir Nadvornik <nadvornik@suse.cz>
+ * Copyright (c) 2007 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_SCSI_SG_H
+
+# include <linux/ioctl.h>
+# include <scsi/sg.h>
+
+# include "xlat/sg_io_dxfer_direction.h"
+
+# ifdef HAVE_LINUX_BSG_H
+#  include <linux/bsg.h>
+#  include <sys/uio.h>
+#  include "xlat/bsg_protocol.h"
+#  include "xlat/bsg_subprotocol.h"
+# endif
+
+static bool
+print_uchar(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	tprintf("%02x", (unsigned int) (* (unsigned char *) elem_buf));
+
+	return true;
+}
+
+static void
+print_sg_io_buffer(struct tcb *tcp, const unsigned long addr, const unsigned int len)
+{
+	unsigned char buf;
+
+	print_array(tcp, addr, len, &buf, sizeof(buf),
+		    umoven_or_printaddr, print_uchar, 0);
+}
+
+static int
+print_sg_io_v3_req(struct tcb *tcp, const long arg)
+{
+	struct sg_io_hdr sg_io;
+
+	if (umove(tcp, arg, &sg_io) < 0) {
+		tprints("???}");
+		return RVAL_DECODED | 1;
+	}
+
+	printxval(sg_io_dxfer_direction, sg_io.dxfer_direction,
+		  "SG_DXFER_???");
+	tprintf(", cmd[%u]=", sg_io.cmd_len);
+	print_sg_io_buffer(tcp, (unsigned long) sg_io.cmdp, sg_io.cmd_len);
+	tprintf(", mx_sb_len=%d", sg_io.mx_sb_len);
+	tprintf(", iovec_count=%d", sg_io.iovec_count);
+	tprintf(", dxfer_len=%u", sg_io.dxfer_len);
+	tprintf(", timeout=%u", sg_io.timeout);
+	tprintf(", flags=%#x", sg_io.flags);
+
+	if (sg_io.dxfer_direction == SG_DXFER_TO_DEV ||
+	    sg_io.dxfer_direction == SG_DXFER_TO_FROM_DEV) {
+		tprintf(", data[%u]=", sg_io.dxfer_len);
+		if (sg_io.iovec_count)
+			tprint_iov_upto(tcp, sg_io.iovec_count,
+					(unsigned long) sg_io.dxferp,
+					IOV_DECODE_STR,
+					sg_io.dxfer_len);
+		else
+			print_sg_io_buffer(tcp, (unsigned long) sg_io.dxferp,
+					   sg_io.dxfer_len);
+	}
+	return 1;
+}
+
+static void
+print_sg_io_v3_res(struct tcb *tcp, const long arg)
+{
+	struct sg_io_hdr sg_io;
+
+	if (umove(tcp, arg, &sg_io) < 0) {
+		tprints(", ???");
+		return;
+	}
+
+	if (sg_io.dxfer_direction == SG_DXFER_FROM_DEV ||
+	    sg_io.dxfer_direction == SG_DXFER_TO_FROM_DEV) {
+		uint32_t din_len = sg_io.dxfer_len;
+
+		if (sg_io.resid > 0)
+			din_len -= sg_io.resid;
+		tprintf(", data[%u]=", din_len);
+		if (sg_io.iovec_count)
+			tprint_iov_upto(tcp, sg_io.iovec_count,
+					(unsigned long) sg_io.dxferp,
+					IOV_DECODE_STR,
+					din_len);
+		else
+			print_sg_io_buffer(tcp, (unsigned long) sg_io.dxferp,
+					   din_len);
+	}
+	tprintf(", status=%02x", sg_io.status);
+	tprintf(", masked_status=%02x", sg_io.masked_status);
+	tprintf(", sb[%u]=", sg_io.sb_len_wr);
+	print_sg_io_buffer(tcp, (unsigned long) sg_io.sbp, sg_io.sb_len_wr);
+	tprintf(", host_status=%#x", sg_io.host_status);
+	tprintf(", driver_status=%#x", sg_io.driver_status);
+	tprintf(", resid=%d", sg_io.resid);
+	tprintf(", duration=%d", sg_io.duration);
+	tprintf(", info=%#x", sg_io.info);
+}
+
+#ifdef HAVE_LINUX_BSG_H
+
+static int
+print_sg_io_v4_req(struct tcb *tcp, const long arg)
+{
+	struct sg_io_v4 sg_io;
+
+	if (umove(tcp, arg, &sg_io) < 0) {
+		tprints("???}");
+		return RVAL_DECODED | 1;
+	}
+
+	printxval(bsg_protocol, sg_io.protocol, "BSG_PROTOCOL_???");
+	tprints(", ");
+	printxval(bsg_subprotocol, sg_io.subprotocol, "BSG_SUB_PROTOCOL_???");
+	tprintf(", request[%u]=", sg_io.request_len);
+	print_sg_io_buffer(tcp, sg_io.request, sg_io.request_len);
+	tprintf(", request_tag=%" PRI__u64, sg_io.request_tag);
+	tprintf(", request_attr=%u", sg_io.request_attr);
+	tprintf(", request_priority=%u", sg_io.request_priority);
+	tprintf(", request_extra=%u", sg_io.request_extra);
+	tprintf(", max_response_len=%u", sg_io.max_response_len);
+
+	tprintf(", dout_iovec_count=%u", sg_io.dout_iovec_count);
+	tprintf(", dout_xfer_len=%u", sg_io.dout_xfer_len);
+	tprintf(", din_iovec_count=%u", sg_io.din_iovec_count);
+	tprintf(", din_xfer_len=%u", sg_io.din_xfer_len);
+	tprintf(", timeout=%u", sg_io.timeout);
+	tprintf(", flags=%u", sg_io.flags);
+	tprintf(", usr_ptr=%" PRI__u64, sg_io.usr_ptr);
+	tprintf(", spare_in=%u", sg_io.spare_in);
+	tprintf(", dout[%u]=", sg_io.dout_xfer_len);
+	if (sg_io.dout_iovec_count)
+		tprint_iov_upto(tcp, sg_io.dout_iovec_count, sg_io.dout_xferp,
+				IOV_DECODE_STR, sg_io.dout_xfer_len);
+	else
+		print_sg_io_buffer(tcp, sg_io.dout_xferp, sg_io.dout_xfer_len);
+	return 1;
+}
+
+static void
+print_sg_io_v4_res(struct tcb *tcp, const long arg)
+{
+	struct sg_io_v4 sg_io;
+	uint32_t din_len;
+
+	if (umove(tcp, arg, &sg_io) < 0) {
+		tprints(", ???");
+		return;
+	}
+
+	tprintf(", response[%u]=", sg_io.response_len);
+	print_sg_io_buffer(tcp, sg_io.response, sg_io.response_len);
+	din_len = sg_io.din_xfer_len;
+	if (sg_io.din_resid > 0)
+		din_len -= sg_io.din_resid;
+	tprintf(", din[%u]=", din_len);
+	if (sg_io.din_iovec_count)
+		tprint_iov_upto(tcp, sg_io.din_iovec_count, sg_io.din_xferp,
+				IOV_DECODE_STR, din_len);
+	else
+		print_sg_io_buffer(tcp, sg_io.din_xferp, din_len);
+	tprintf(", driver_status=%u", sg_io.driver_status);
+	tprintf(", transport_status=%u", sg_io.transport_status);
+	tprintf(", device_status=%u", sg_io.device_status);
+	tprintf(", retry_delay=%u", sg_io.retry_delay);
+	tprintf(", info=%u", sg_io.info);
+	tprintf(", duration=%u", sg_io.duration);
+	tprintf(", response_len=%u", sg_io.response_len);
+	tprintf(", din_resid=%u", sg_io.din_resid);
+	tprintf(", dout_resid=%u", sg_io.dout_resid);
+	tprintf(", generated_tag=%" PRI__u64, sg_io.generated_tag);
+	tprintf(", spare_out=%u", sg_io.spare_out);
+}
+
+#else /* !HAVE_LINUX_BSG_H */
+
+static int
+print_sg_io_v4_req(struct tcb *tcp, const long arg)
+{
+	tprints("...}");
+	return RVAL_DECODED | 1;
+}
+
+static void
+print_sg_io_v4_res(struct tcb *tcp, const long arg)
+{
+}
+
+#endif
+
+static int
+print_sg_io_req(struct tcb *tcp, uint32_t iid, const long arg)
+{
+	tprintf("{'%c', ", iid);
+
+	switch (iid) {
+	case 'S':
+		return print_sg_io_v3_req(tcp, arg);
+	case 'Q':
+		return print_sg_io_v4_req(tcp, arg);
+	default:
+		tprints("...}");
+		return RVAL_DECODED | 1;
+	}
+
+}
+
+static void
+print_sg_io_res(struct tcb *tcp, uint32_t iid, const long arg)
+{
+	switch (iid) {
+	case 'S':
+		print_sg_io_v3_res(tcp, arg);
+		break;
+	case 'Q':
+		print_sg_io_v4_res(tcp, arg);
+		break;
+	}
+}
+
+int
+scsi_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	uint32_t iid;
+
+	if (SG_IO != code)
+		return RVAL_DECODED;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (!arg || umove(tcp, arg, &iid) < 0) {
+			printaddr(arg);
+			return RVAL_DECODED | 1;
+		} else {
+			return print_sg_io_req(tcp, iid, arg);
+		}
+	} else {
+		if (!syserror(tcp)) {
+			if (umove(tcp, arg, &iid) < 0)
+				tprints(", ???");
+			else
+				print_sg_io_res(tcp, iid, arg);
+		}
+		tprintf("}");
+		return RVAL_DECODED | 1;
+	}
+}
+
+#endif /* HAVE_SCSI_SG_H */
diff --git a/strace/seccomp.c b/strace/seccomp.c
new file mode 100644
index 0000000..4d8d7e4
--- /dev/null
+++ b/strace/seccomp.c
@@ -0,0 +1,227 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_LINUX_SECCOMP_H
+# include <linux/seccomp.h>
+#endif
+#include "xlat/seccomp_ops.h"
+#include "xlat/seccomp_filter_flags.h"
+
+#ifdef HAVE_LINUX_FILTER_H
+# include <linux/filter.h>
+# include "xlat/bpf_class.h"
+# include "xlat/bpf_miscop.h"
+# include "xlat/bpf_mode.h"
+# include "xlat/bpf_op_alu.h"
+# include "xlat/bpf_op_jmp.h"
+# include "xlat/bpf_rval.h"
+# include "xlat/bpf_size.h"
+# include "xlat/bpf_src.h"
+
+# ifndef SECCOMP_RET_ACTION
+#  define SECCOMP_RET_ACTION 0x7fff0000U
+# endif
+# include "xlat/seccomp_ret_action.h"
+#endif
+
+struct bpf_filter {
+	uint16_t code;
+	uint8_t jt;
+	uint8_t jf;
+	uint32_t k;
+};
+
+#ifdef HAVE_LINUX_FILTER_H
+
+static void
+decode_bpf_code(uint16_t code)
+{
+	uint16_t i = code & ~BPF_CLASS(code);
+
+	printxval(bpf_class, BPF_CLASS(code), "BPF_???");
+	switch (BPF_CLASS(code)) {
+		case BPF_LD:
+		case BPF_LDX:
+			tprints("|");
+			printxval(bpf_size, BPF_SIZE(code), "BPF_???");
+			tprints("|");
+			printxval(bpf_mode, BPF_MODE(code), "BPF_???");
+			break;
+		case BPF_ST:
+		case BPF_STX:
+			if (i)
+				tprintf("|%#x /* %s */", i, "BPF_???");
+			break;
+		case BPF_ALU:
+			tprints("|");
+			printxval(bpf_src, BPF_SRC(code), "BPF_???");
+			tprints("|");
+			printxval(bpf_op_alu, BPF_OP(code), "BPF_???");
+			break;
+		case BPF_JMP:
+			tprints("|");
+			printxval(bpf_src, BPF_SRC(code), "BPF_???");
+			tprints("|");
+			printxval(bpf_op_jmp, BPF_OP(code), "BPF_???");
+			break;
+		case BPF_RET:
+			tprints("|");
+			printxval(bpf_rval, BPF_RVAL(code), "BPF_???");
+			i &= ~BPF_RVAL(code);
+			if (i)
+				tprintf("|%#x /* %s */", i, "BPF_???");
+			break;
+		case BPF_MISC:
+			tprints("|");
+			printxval(bpf_miscop, BPF_MISCOP(code), "BPF_???");
+			i &= ~BPF_MISCOP(code);
+			if (i)
+				tprintf("|%#x /* %s */", i, "BPF_???");
+			break;
+	}
+
+}
+
+#endif /* HAVE_LINUX_FILTER_H */
+
+static void
+decode_bpf_stmt(const struct bpf_filter *filter)
+{
+#ifdef HAVE_LINUX_FILTER_H
+	tprints("BPF_STMT(");
+	decode_bpf_code(filter->code);
+	tprints(", ");
+	if (BPF_CLASS(filter->code) == BPF_RET) {
+		unsigned int action = SECCOMP_RET_ACTION & filter->k;
+		unsigned int data = filter->k & ~action;
+
+		printxval(seccomp_ret_action, action, "SECCOMP_RET_???");
+		if (data)
+			tprintf("|%#x)", data);
+		else
+			tprints(")");
+	} else {
+		tprintf("%#x)", filter->k);
+	}
+#else
+	tprintf("BPF_STMT(%#x, %#x)", filter->code, filter->k);
+#endif /* HAVE_LINUX_FILTER_H */
+}
+
+static void
+decode_bpf_jump(const struct bpf_filter *filter)
+{
+#ifdef HAVE_LINUX_FILTER_H
+	tprints("BPF_JUMP(");
+	decode_bpf_code(filter->code);
+	tprintf(", %#x, %#x, %#x)",
+		filter->k, filter->jt, filter->jf);
+#else
+	tprintf("BPF_JUMP(%#x, %#x, %#x, %#x)",
+		filter->code, filter->k, filter->jt, filter->jf);
+#endif /* HAVE_LINUX_FILTER_H */
+}
+
+#ifndef BPF_MAXINSNS
+# define BPF_MAXINSNS 4096
+#endif
+
+static bool
+print_bpf_filter(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const struct bpf_filter *filter = elem_buf;
+	unsigned int *pn = data;
+
+	if ((*pn)++ >= BPF_MAXINSNS) {
+		tprints("...");
+		return false;
+	}
+
+	if (filter->jt || filter->jf)
+		decode_bpf_jump(filter);
+	else
+		decode_bpf_stmt(filter);
+
+	return true;
+}
+
+void
+print_seccomp_fprog(struct tcb *tcp, unsigned long addr, unsigned short len)
+{
+	if (abbrev(tcp)) {
+		printaddr(addr);
+	} else {
+		unsigned int insns = 0;
+		struct bpf_filter filter;
+
+		print_array(tcp, addr, len, &filter, sizeof(filter),
+			    umoven_or_printaddr, print_bpf_filter, &insns);
+	}
+}
+
+#include "seccomp_fprog.h"
+
+void
+print_seccomp_filter(struct tcb *tcp, unsigned long addr)
+{
+	struct seccomp_fprog fprog;
+
+	if (fetch_seccomp_fprog(tcp, addr, &fprog)) {
+		tprintf("{len=%hu, filter=", fprog.len);
+		print_seccomp_fprog(tcp, fprog.filter, fprog.len);
+		tprints("}");
+	}
+}
+
+static void
+decode_seccomp_set_mode_strict(unsigned int flags, unsigned long addr)
+{
+	tprintf("%u, ", flags);
+	printaddr(addr);
+}
+
+SYS_FUNC(seccomp)
+{
+	unsigned int op = tcp->u_arg[0];
+
+	printxval(seccomp_ops, op, "SECCOMP_SET_MODE_???");
+	tprints(", ");
+
+	if (op == SECCOMP_SET_MODE_FILTER) {
+		printflags(seccomp_filter_flags, tcp->u_arg[1],
+			   "SECCOMP_FILTER_FLAG_???");
+		tprints(", ");
+		print_seccomp_filter(tcp, tcp->u_arg[2]);
+	} else {
+		decode_seccomp_set_mode_strict(tcp->u_arg[1],
+					       tcp->u_arg[2]);
+	}
+
+	return RVAL_DECODED;
+}
diff --git a/strace/seccomp_fprog.h b/strace/seccomp_fprog.h
new file mode 100644
index 0000000..6b1f77f
--- /dev/null
+++ b/strace/seccomp_fprog.h
@@ -0,0 +1,4 @@
+struct seccomp_fprog {
+	unsigned short len;
+	unsigned long filter;
+};
diff --git a/strace/sen.h b/strace/sen.h
new file mode 100644
index 0000000..bf6cdfd
--- /dev/null
+++ b/strace/sen.h
@@ -0,0 +1,420 @@
+enum {
+SEN_printargs = 0,
+SEN_accept,
+SEN_accept4,
+SEN_access,
+SEN_acct,
+SEN_add_key,
+SEN_adjtimex,
+SEN_afs_syscall,
+SEN_alarm,
+SEN_ARCH_mmap,
+SEN_arch_prctl,
+SEN_bdflush,
+SEN_bind,
+SEN_bpf,
+SEN_break,
+SEN_brk,
+SEN_cacheflush,
+SEN_capget,
+SEN_capset,
+SEN_chdir,
+SEN_chmod,
+SEN_chown,
+SEN_chown16,
+SEN_chroot,
+SEN_clock_adjtime,
+SEN_clock_getres,
+SEN_clock_gettime,
+SEN_clock_nanosleep,
+SEN_clock_settime,
+SEN_clone,
+SEN_close,
+SEN_connect,
+SEN_copy_file_range,
+SEN_creat,
+SEN_create_module,
+SEN_delete_module,
+SEN_dup,
+SEN_dup2,
+SEN_dup3,
+SEN_epoll_create,
+SEN_epoll_create1,
+SEN_epoll_ctl,
+SEN_epoll_pwait,
+SEN_epoll_wait,
+SEN_eventfd,
+SEN_eventfd2,
+SEN_execv,
+SEN_execve,
+SEN_execveat,
+SEN_exit,
+SEN_faccessat,
+SEN_fadvise64,
+SEN_fadvise64_64,
+SEN_fallocate,
+SEN_fanotify_init,
+SEN_fanotify_mark,
+SEN_fchdir,
+SEN_fchmod,
+SEN_fchmodat,
+SEN_fchown,
+SEN_fchown16,
+SEN_fchownat,
+SEN_fcntl,
+SEN_fcntl64,
+SEN_fdatasync,
+SEN_fgetxattr,
+SEN_finit_module,
+SEN_flistxattr,
+SEN_flock,
+SEN_fork,
+SEN_fremovexattr,
+SEN_fsetxattr,
+SEN_fstat,
+SEN_fstat64,
+SEN_fstatfs,
+SEN_fstatfs64,
+SEN_fsync,
+SEN_ftime,
+SEN_ftruncate,
+SEN_ftruncate64,
+SEN_futex,
+SEN_futimesat,
+SEN_getcpu,
+SEN_getcwd,
+SEN_getdents,
+SEN_getdents64,
+SEN_getdtablesize,
+SEN_getegid,
+SEN_getegid16,
+SEN_geteuid,
+SEN_geteuid16,
+SEN_getgid,
+SEN_getgid16,
+SEN_getgroups,
+SEN_getgroups16,
+SEN_gethostname,
+SEN_getitimer,
+SEN_get_kernel_syms,
+SEN_get_mempolicy,
+SEN_getpagesize,
+SEN_getpeername,
+SEN_getpgid,
+SEN_getpgrp,
+SEN_getpid,
+SEN_getpmsg,
+SEN_getppid,
+SEN_getpriority,
+SEN_getrandom,
+SEN_getresgid,
+SEN_getresgid16,
+SEN_getresuid,
+SEN_getresuid16,
+SEN_getrlimit,
+SEN_get_robust_list,
+SEN_getrusage,
+SEN_getsid,
+SEN_getsockname,
+SEN_getsockopt,
+SEN_get_thread_area,
+SEN_gettid,
+SEN_gettimeofday,
+SEN_getuid,
+SEN_getuid16,
+SEN_getxattr,
+SEN_getxgid,
+SEN_getxpid,
+SEN_getxuid,
+SEN_gtty,
+SEN_idle,
+SEN_init_module,
+SEN_inotify_add_watch,
+SEN_inotify_init,
+SEN_inotify_init1,
+SEN_inotify_rm_watch,
+SEN_io_cancel,
+SEN_ioctl,
+SEN_io_destroy,
+SEN_io_getevents,
+SEN_ioperm,
+SEN_iopl,
+SEN_ioprio_get,
+SEN_ioprio_set,
+SEN_io_setup,
+SEN_io_submit,
+SEN_ipc,
+SEN_kcmp,
+SEN_kexec_file_load,
+SEN_kexec_load,
+SEN_keyctl,
+SEN_kill,
+SEN_link,
+SEN_linkat,
+SEN_listen,
+SEN_listxattr,
+SEN_llseek,
+SEN_lock,
+SEN_lookup_dcookie,
+SEN_lseek,
+SEN_lstat,
+SEN_lstat64,
+SEN_madvise,
+SEN_mbind,
+SEN_membarrier,
+SEN_memfd_create,
+SEN_migrate_pages,
+SEN_mincore,
+SEN_mkdir,
+SEN_mkdirat,
+SEN_mknod,
+SEN_mknodat,
+SEN_mlock,
+SEN_mlock2,
+SEN_mlockall,
+SEN_mmap,
+SEN_mmap_4koff,
+SEN_mmap_pgoff,
+SEN_modify_ldt,
+SEN_mount,
+SEN_move_pages,
+SEN_mprotect,
+SEN_mpx,
+SEN_mq_getsetattr,
+SEN_mq_notify,
+SEN_mq_open,
+SEN_mq_timedreceive,
+SEN_mq_timedsend,
+SEN_mq_unlink,
+SEN_mremap,
+SEN_msgctl,
+SEN_msgget,
+SEN_msgrcv,
+SEN_msgsnd,
+SEN_msync,
+SEN_munlock,
+SEN_munlockall,
+SEN_munmap,
+SEN_name_to_handle_at,
+SEN_nanosleep,
+SEN_newfstatat,
+SEN_nfsservctl,
+SEN_nice,
+SEN_oldfstat,
+SEN_oldlstat,
+SEN_old_mmap,
+SEN_old_mmap_pgoff,
+SEN_oldolduname,
+SEN_oldselect,
+SEN_oldstat,
+SEN_olduname,
+SEN_open,
+SEN_openat,
+SEN_open_by_handle_at,
+SEN_or1k_atomic,
+SEN_osf_fstatfs,
+SEN_osf_getitimer,
+SEN_osf_getrusage,
+SEN_osf_gettimeofday,
+SEN_osf_select,
+SEN_osf_setitimer,
+SEN_osf_settimeofday,
+SEN_osf_statfs,
+SEN_osf_utimes,
+SEN_osf_wait4,
+SEN_pause,
+SEN_perf_event_open,
+SEN_personality,
+SEN_pipe,
+SEN_pipe2,
+SEN_pivotroot,
+SEN_poll,
+SEN_ppoll,
+SEN_prctl,
+SEN_pread,
+SEN_preadv,
+SEN_preadv2,
+SEN_prlimit64,
+SEN_process_vm_readv,
+SEN_process_vm_writev,
+SEN_prof,
+SEN_profil,
+SEN_pselect6,
+SEN_ptrace,
+SEN_putpmsg,
+SEN_pwrite,
+SEN_pwritev,
+SEN_pwritev2,
+SEN_query_module,
+SEN_quotactl,
+SEN_read,
+SEN_readahead,
+SEN_readdir,
+SEN_readlink,
+SEN_readlinkat,
+SEN_readv,
+SEN_reboot,
+SEN_recv,
+SEN_recvfrom,
+SEN_recvmmsg,
+SEN_recvmsg,
+SEN_remap_file_pages,
+SEN_removexattr,
+SEN_rename,
+SEN_renameat,
+SEN_renameat2,
+SEN_request_key,
+SEN_restart_syscall,
+SEN_rmdir,
+SEN_rt_sigaction,
+SEN_rt_sigpending,
+SEN_rt_sigprocmask,
+SEN_rt_sigqueueinfo,
+SEN_rt_sigreturn,
+SEN_rt_sigsuspend,
+SEN_rt_sigtimedwait,
+SEN_rt_tgsigqueueinfo,
+SEN_sched_getaffinity,
+SEN_sched_getattr,
+SEN_sched_getparam,
+SEN_sched_get_priority_max,
+SEN_sched_get_priority_min,
+SEN_sched_getscheduler,
+SEN_sched_rr_get_interval,
+SEN_sched_setaffinity,
+SEN_sched_setattr,
+SEN_sched_setparam,
+SEN_sched_setscheduler,
+SEN_sched_yield,
+SEN_seccomp,
+SEN_security,
+SEN_select,
+SEN_semctl,
+SEN_semget,
+SEN_semop,
+SEN_semtimedop,
+SEN_send,
+SEN_sendfile,
+SEN_sendfile64,
+SEN_sendmmsg,
+SEN_sendmsg,
+SEN_sendto,
+SEN_setdomainname,
+SEN_setfsgid,
+SEN_setfsgid16,
+SEN_setfsuid,
+SEN_setfsuid16,
+SEN_setgid,
+SEN_setgid16,
+SEN_setgroups,
+SEN_setgroups16,
+SEN_sethostname,
+SEN_setitimer,
+SEN_set_mempolicy,
+SEN_setns,
+SEN_setpgid,
+SEN_setpgrp,
+SEN_setpriority,
+SEN_setregid,
+SEN_setregid16,
+SEN_setresgid,
+SEN_setresgid16,
+SEN_setresuid,
+SEN_setresuid16,
+SEN_setreuid,
+SEN_setreuid16,
+SEN_setrlimit,
+SEN_set_robust_list,
+SEN_setsid,
+SEN_setsockopt,
+SEN_set_thread_area,
+SEN_set_tid_address,
+SEN_settimeofday,
+SEN_setuid,
+SEN_setuid16,
+SEN_setup,
+SEN_setxattr,
+SEN_shmat,
+SEN_shmctl,
+SEN_shmdt,
+SEN_shmget,
+SEN_shutdown,
+SEN_sigaction,
+SEN_sigaltstack,
+SEN_siggetmask,
+SEN_signal,
+SEN_signalfd,
+SEN_signalfd4,
+SEN_sigpending,
+SEN_sigprocmask,
+SEN_sigreturn,
+SEN_sigsetmask,
+SEN_sigsuspend,
+SEN_socket,
+SEN_socketcall,
+SEN_socketpair,
+SEN_splice,
+SEN_sram_alloc,
+SEN_stat,
+SEN_stat64,
+SEN_statfs,
+SEN_statfs64,
+SEN_stime,
+SEN_stty,
+SEN_subpage_prot,
+SEN_swapoff,
+SEN_swapon,
+SEN_symlink,
+SEN_symlinkat,
+SEN_sync,
+SEN_sync_file_range,
+SEN_sync_file_range2,
+SEN_syncfs,
+SEN_syscall,
+SEN_sysctl,
+SEN_sysfs,
+SEN_sysinfo,
+SEN_syslog,
+SEN_sysmips,
+SEN_tee,
+SEN_tgkill,
+SEN_time,
+SEN_timer_create,
+SEN_timer_delete,
+SEN_timerfd,
+SEN_timerfd_create,
+SEN_timerfd_gettime,
+SEN_timerfd_settime,
+SEN_timer_getoverrun,
+SEN_timer_gettime,
+SEN_timer_settime,
+SEN_times,
+SEN_truncate,
+SEN_truncate64,
+SEN_tuxcall,
+SEN_ulimit,
+SEN_umask,
+SEN_umount,
+SEN_umount2,
+SEN_uname,
+SEN_unlink,
+SEN_unlinkat,
+SEN_unshare,
+SEN_uselib,
+SEN_userfaultfd,
+SEN_ustat,
+SEN_utime,
+SEN_utimensat,
+SEN_utimes,
+SEN_vfork,
+SEN_vhangup,
+SEN_vm86,
+SEN_vm86old,
+SEN_vmsplice,
+SEN_vserver,
+SEN_wait4,
+SEN_waitid,
+SEN_waitpid,
+SEN_write,
+SEN_writev,
+};
diff --git a/strace/sendfile.c b/strace/sendfile.c
new file mode 100644
index 0000000..97fd7c5
--- /dev/null
+++ b/strace/sendfile.c
@@ -0,0 +1,73 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+SYS_FUNC(sendfile64)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		printfd(tcp, tcp->u_arg[1]);
+		tprints(", ");
+		if (!printnum_int64(tcp, tcp->u_arg[2], "%" PRIu64)) {
+			tprintf(", %lu", tcp->u_arg[3]);
+			return RVAL_DECODED;
+		}
+	} else {
+		if (!syserror(tcp) && tcp->u_rval) {
+			tprints(" => ");
+			printnum_int64(tcp, tcp->u_arg[2], "%" PRIu64);
+		}
+		tprintf(", %lu", tcp->u_arg[3]);
+	}
+
+	return 0;
+}
+
+SYS_FUNC(sendfile)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		printfd(tcp, tcp->u_arg[1]);
+		tprints(", ");
+		if (!printnum_ulong(tcp, tcp->u_arg[2])
+		    || !tcp->u_arg[3]) {
+			tprintf(", %lu", tcp->u_arg[3]);
+			return RVAL_DECODED;
+		}
+	} else {
+		if (!syserror(tcp) && tcp->u_rval) {
+			tprints(" => ");
+			printnum_ulong(tcp, tcp->u_arg[2]);
+		}
+		tprintf(", %lu", tcp->u_arg[3]);
+	}
+
+	return 0;
+}
diff --git a/strace/sigaltstack.c b/strace/sigaltstack.c
new file mode 100644
index 0000000..b3e4357
--- /dev/null
+++ b/strace/sigaltstack.c
@@ -0,0 +1,67 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * 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 DEF_MPERS_TYPE(stack_t)
+
+#include <signal.h>
+
+#include MPERS_DEFS
+
+#include "xlat/sigaltstack_flags.h"
+
+static void
+print_stack_t(struct tcb *tcp, unsigned long addr)
+{
+	stack_t ss;
+
+	if (umove_or_printaddr(tcp, addr, &ss))
+		return;
+
+	tprints("{ss_sp=");
+	printaddr((unsigned long) ss.ss_sp);
+	tprints(", ss_flags=");
+	printflags(sigaltstack_flags, ss.ss_flags, "SS_???");
+	tprintf(", ss_size=%lu}", (unsigned long) ss.ss_size);
+}
+
+SYS_FUNC(sigaltstack)
+{
+	if (entering(tcp)) {
+		print_stack_t(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_stack_t(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/sigevent.h b/strace/sigevent.h
new file mode 100644
index 0000000..6b3bacf
--- /dev/null
+++ b/strace/sigevent.h
@@ -0,0 +1,47 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef SIGEVENT_H_
+#define SIGEVENT_H_
+
+typedef struct {
+	union {
+		int sival_int;
+		unsigned long sival_ptr;
+	} sigev_value;
+	int sigev_signo;
+	int sigev_notify;
+	union {
+		int tid;
+		struct {
+			unsigned long function;
+			unsigned long attribute;
+		} sigev_thread;
+	} sigev_un;
+} struct_sigevent;
+
+#endif
diff --git a/strace/signal.c b/strace/signal.c
new file mode 100644
index 0000000..cb200bf
--- /dev/null
+++ b/strace/signal.c
@@ -0,0 +1,701 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 1999 IBM Deutschland Entwicklung GmbH, IBM Corporation
+ *                     Linux for s390 port by D.J. Barrow
+ *                    <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * 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 <signal.h>
+
+#ifndef NSIG
+# warning NSIG is not defined, using 32
+# define NSIG 32
+#elif NSIG < 32
+# error NSIG < 32
+#endif
+
+/* The libc headers do not define this constant since it should only be
+   used by the implementation.  So we define it here.  */
+#ifndef SA_RESTORER
+# ifdef ASM_SA_RESTORER
+#  define SA_RESTORER ASM_SA_RESTORER
+# endif
+#endif
+
+/*
+ * Some architectures define SA_RESTORER in their headers,
+ * but do not actually have sa_restorer.
+ *
+ * Some architectures, otherwise, do not define SA_RESTORER in their headers,
+ * but actually have sa_restorer.
+ */
+#ifdef SA_RESTORER
+# if defined HPPA || defined IA64
+#  define HAVE_SA_RESTORER 0
+# else
+#  define HAVE_SA_RESTORER 1
+# endif
+#else /* !SA_RESTORER */
+# if defined SPARC || defined SPARC64 || defined M68K
+#  define HAVE_SA_RESTORER 1
+# else
+#  define HAVE_SA_RESTORER 0
+# endif
+#endif
+
+#include "xlat/sigact_flags.h"
+#include "xlat/sigprocmaskcmds.h"
+
+/* Anonymous realtime signals. */
+#ifndef ASM_SIGRTMIN
+/* Linux kernel >= 3.18 defines SIGRTMIN to 32 on all architectures. */
+# define ASM_SIGRTMIN 32
+#endif
+#ifndef ASM_SIGRTMAX
+/* Under glibc 2.1, SIGRTMAX et al are functions, but __SIGRTMAX is a
+   constant.  This is what we want.  Otherwise, just use SIGRTMAX. */
+# ifdef SIGRTMAX
+#  ifndef __SIGRTMAX
+#   define __SIGRTMAX SIGRTMAX
+#  endif
+# endif
+# ifdef __SIGRTMAX
+#  define ASM_SIGRTMAX __SIGRTMAX
+# endif
+#endif
+
+/* Note on the size of sigset_t:
+ *
+ * In glibc, sigset_t is an array with space for 1024 bits (!),
+ * even though all arches supported by Linux have only 64 signals
+ * except MIPS, which has 128. IOW, it is 128 bytes long.
+ *
+ * In-kernel sigset_t is sized correctly (it is either 64 or 128 bit long).
+ * However, some old syscall return only 32 lower bits (one word).
+ * Example: sys_sigpending vs sys_rt_sigpending.
+ *
+ * Be aware of this fact when you try to
+ *     memcpy(&tcp->u_arg[1], &something, sizeof(sigset_t))
+ * - sizeof(sigset_t) is much bigger than you think,
+ * it may overflow tcp->u_arg[] array, and it may try to copy more data
+ * than is really available in <something>.
+ * Similarly,
+ *     umoven(tcp, addr, sizeof(sigset_t), &sigset)
+ * may be a bad idea: it'll try to read much more data than needed
+ * to fetch a sigset_t.
+ * Use (NSIG / 8) as a size instead.
+ */
+
+const char *
+signame(const int sig)
+{
+	static char buf[sizeof("SIGRT_%u") + sizeof(int)*3];
+
+	if (sig >= 0) {
+		const unsigned int s = sig;
+
+		if (s < nsignals)
+			return signalent[s];
+#ifdef ASM_SIGRTMAX
+		if (s >= ASM_SIGRTMIN && s <= (unsigned int) ASM_SIGRTMAX) {
+			sprintf(buf, "SIGRT_%u", s - ASM_SIGRTMIN);
+			return buf;
+		}
+#endif
+	}
+	sprintf(buf, "%d", sig);
+	return buf;
+}
+
+static unsigned int
+popcount32(const uint32_t *a, unsigned int size)
+{
+	unsigned int count = 0;
+
+	for (; size; ++a, --size) {
+		uint32_t x = *a;
+
+#ifdef HAVE___BUILTIN_POPCOUNT
+		count += __builtin_popcount(x);
+#else
+		for (; x; ++count)
+			x &= x - 1;
+#endif
+	}
+
+	return count;
+}
+
+const char *
+sprintsigmask_n(const char *prefix, const void *sig_mask, unsigned int bytes)
+{
+	/*
+	 * The maximum number of signal names to be printed is NSIG * 2 / 3.
+	 * Most of signal names have length 7,
+	 * average length of signal names is less than 7.
+	 * The length of prefix string does not exceed 16.
+	 */
+	static char outstr[128 + 8 * (NSIG * 2 / 3)];
+
+	char *s;
+	const uint32_t *mask;
+	uint32_t inverted_mask[NSIG / 32];
+	unsigned int size;
+	int i;
+	char sep;
+
+	s = stpcpy(outstr, prefix);
+
+	mask = sig_mask;
+	/* length of signal mask in 4-byte words */
+	size = (bytes >= NSIG / 8) ? NSIG / 32 : (bytes + 3) / 4;
+
+	/* check whether 2/3 or more bits are set */
+	if (popcount32(mask, size) >= size * 32 * 2 / 3) {
+		/* show those signals that are NOT in the mask */
+		unsigned int j;
+		for (j = 0; j < size; ++j)
+			inverted_mask[j] = ~mask[j];
+		mask = inverted_mask;
+		*s++ = '~';
+	}
+
+	sep = '[';
+	for (i = 0; (i = next_set_bit(mask, i, size * 32)) >= 0; ) {
+		++i;
+		*s++ = sep;
+		if ((unsigned) i < nsignals) {
+			s = stpcpy(s, signalent[i] + 3);
+		}
+#ifdef ASM_SIGRTMAX
+		else if (i >= ASM_SIGRTMIN && i <= ASM_SIGRTMAX) {
+			s += sprintf(s, "RT_%u", i - ASM_SIGRTMIN);
+		}
+#endif
+		else {
+			s += sprintf(s, "%u", i);
+		}
+		sep = ' ';
+	}
+	if (sep == '[')
+		*s++ = sep;
+	*s++ = ']';
+	*s = '\0';
+	return outstr;
+}
+
+#define sprintsigmask_val(prefix, mask) \
+	sprintsigmask_n((prefix), &(mask), sizeof(mask))
+
+#define tprintsigmask_val(prefix, mask) \
+	tprints(sprintsigmask_n((prefix), &(mask), sizeof(mask)))
+
+void
+printsignal(int nr)
+{
+	tprints(signame(nr));
+}
+
+static void
+print_sigset_addr_len_limit(struct tcb *tcp, long addr, long len, long min_len)
+{
+	/*
+	 * Here len is usually equal to NSIG / 8 or current_wordsize.
+	 * But we code this defensively:
+	 */
+	if (len < min_len || len > NSIG / 8) {
+		printaddr(addr);
+		return;
+	}
+	int mask[NSIG / 8 / sizeof(int)] = {};
+	if (umoven_or_printaddr(tcp, addr, len, mask))
+		return;
+	tprints(sprintsigmask_n("", mask, len));
+}
+
+void
+print_sigset_addr_len(struct tcb *tcp, long addr, long len)
+{
+	print_sigset_addr_len_limit(tcp, addr, len, current_wordsize);
+}
+
+SYS_FUNC(sigsetmask)
+{
+	if (entering(tcp)) {
+		tprintsigmask_val("", tcp->u_arg[0]);
+	}
+	else if (!syserror(tcp)) {
+		tcp->auxstr = sprintsigmask_val("old mask ", tcp->u_rval);
+		return RVAL_HEX | RVAL_STR;
+	}
+	return 0;
+}
+
+#ifdef HAVE_SIGACTION
+
+struct old_sigaction {
+	/* sa_handler may be a libc #define, need to use other name: */
+#ifdef MIPS
+	unsigned int sa_flags;
+	void (*__sa_handler)(int);
+	/* Kernel treats sa_mask as an array of longs. */
+	unsigned long sa_mask[NSIG / sizeof(long) ? NSIG / sizeof(long) : 1];
+#else
+	void (*__sa_handler)(int);
+	unsigned long sa_mask;
+	unsigned long sa_flags;
+#endif /* !MIPS */
+#if HAVE_SA_RESTORER
+	void (*sa_restorer)(void);
+#endif
+};
+
+struct old_sigaction32 {
+	/* sa_handler may be a libc #define, need to use other name: */
+	uint32_t __sa_handler;
+	uint32_t sa_mask;
+	uint32_t sa_flags;
+#if HAVE_SA_RESTORER
+	uint32_t sa_restorer;
+#endif
+};
+
+static void
+decode_old_sigaction(struct tcb *tcp, long addr)
+{
+	struct old_sigaction sa;
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+	if (current_wordsize != sizeof(sa.__sa_handler) && current_wordsize == 4) {
+		struct old_sigaction32 sa32;
+
+		if (umove_or_printaddr(tcp, addr, &sa32))
+			return;
+
+		memset(&sa, 0, sizeof(sa));
+		sa.__sa_handler = (void*)(uintptr_t)sa32.__sa_handler;
+		sa.sa_flags = sa32.sa_flags;
+#if HAVE_SA_RESTORER && defined SA_RESTORER
+		sa.sa_restorer = (void*)(uintptr_t)sa32.sa_restorer;
+#endif
+		sa.sa_mask = sa32.sa_mask;
+	} else
+#endif
+	if (umove_or_printaddr(tcp, addr, &sa))
+		return;
+
+	/* Architectures using function pointers, like
+	 * hppa, may need to manipulate the function pointer
+	 * to compute the result of a comparison. However,
+	 * the __sa_handler function pointer exists only in
+	 * the address space of the traced process, and can't
+	 * be manipulated by strace. In order to prevent the
+	 * compiler from generating code to manipulate
+	 * __sa_handler we cast the function pointers to long. */
+	tprints("{");
+	if ((long)sa.__sa_handler == (long)SIG_ERR)
+		tprints("SIG_ERR");
+	else if ((long)sa.__sa_handler == (long)SIG_DFL)
+		tprints("SIG_DFL");
+	else if ((long)sa.__sa_handler == (long)SIG_IGN)
+		tprints("SIG_IGN");
+	else
+		printaddr((long) sa.__sa_handler);
+	tprints(", ");
+#ifdef MIPS
+	tprintsigmask_addr("", sa.sa_mask);
+#else
+	tprintsigmask_val("", sa.sa_mask);
+#endif
+	tprints(", ");
+	printflags(sigact_flags, sa.sa_flags, "SA_???");
+#if HAVE_SA_RESTORER && defined SA_RESTORER
+	if (sa.sa_flags & SA_RESTORER)
+		tprintf(", %p", sa.sa_restorer);
+#endif
+	tprints("}");
+}
+
+SYS_FUNC(sigaction)
+{
+	if (entering(tcp)) {
+		printsignal(tcp->u_arg[0]);
+		tprints(", ");
+		decode_old_sigaction(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else
+		decode_old_sigaction(tcp, tcp->u_arg[2]);
+	return 0;
+}
+
+SYS_FUNC(signal)
+{
+	if (entering(tcp)) {
+		printsignal(tcp->u_arg[0]);
+		tprints(", ");
+		switch (tcp->u_arg[1]) {
+		case (long) SIG_ERR:
+			tprints("SIG_ERR");
+			break;
+		case (long) SIG_DFL:
+			tprints("SIG_DFL");
+			break;
+		case (long) SIG_IGN:
+			tprints("SIG_IGN");
+			break;
+		default:
+			printaddr(tcp->u_arg[1]);
+		}
+		return 0;
+	}
+	else if (!syserror(tcp)) {
+		switch (tcp->u_rval) {
+		case (long) SIG_ERR:
+			tcp->auxstr = "SIG_ERR"; break;
+		case (long) SIG_DFL:
+			tcp->auxstr = "SIG_DFL"; break;
+		case (long) SIG_IGN:
+			tcp->auxstr = "SIG_IGN"; break;
+		default:
+			tcp->auxstr = NULL;
+		}
+		return RVAL_HEX | RVAL_STR;
+	}
+	return 0;
+}
+
+#endif /* HAVE_SIGACTION */
+
+SYS_FUNC(siggetmask)
+{
+	if (exiting(tcp)) {
+		tcp->auxstr = sprintsigmask_val("mask ", tcp->u_rval);
+	}
+	return RVAL_HEX | RVAL_STR;
+}
+
+SYS_FUNC(sigsuspend)
+{
+	tprintsigmask_val("", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+#ifdef HAVE_SIGACTION
+
+/* "Old" sigprocmask, which operates with word-sized signal masks */
+SYS_FUNC(sigprocmask)
+{
+# ifdef ALPHA
+	if (entering(tcp)) {
+		/*
+		 * Alpha/OSF is different: it doesn't pass in two pointers,
+		 * but rather passes in the new bitmask as an argument and
+		 * then returns the old bitmask.  This "works" because we
+		 * only have 64 signals to worry about.  If you want more,
+		 * use of the rt_sigprocmask syscall is required.
+		 * Alpha:
+		 *	old = osf_sigprocmask(how, new);
+		 * Everyone else:
+		 *	ret = sigprocmask(how, &new, &old, ...);
+		 */
+		printxval(sigprocmaskcmds, tcp->u_arg[0], "SIG_???");
+		tprintsigmask_val(", ", tcp->u_arg[1]);
+	}
+	else if (!syserror(tcp)) {
+		tcp->auxstr = sprintsigmask_val("old mask ", tcp->u_rval);
+		return RVAL_HEX | RVAL_STR;
+	}
+# else /* !ALPHA */
+	if (entering(tcp)) {
+		printxval(sigprocmaskcmds, tcp->u_arg[0], "SIG_???");
+		tprints(", ");
+		print_sigset_addr_len(tcp, tcp->u_arg[1], current_wordsize);
+		tprints(", ");
+	}
+	else {
+		print_sigset_addr_len(tcp, tcp->u_arg[2], current_wordsize);
+	}
+# endif /* !ALPHA */
+	return 0;
+}
+
+#endif /* HAVE_SIGACTION */
+
+SYS_FUNC(kill)
+{
+	tprintf("%d, %s",
+		(int) tcp->u_arg[0],
+		signame(tcp->u_arg[1]));
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(tgkill)
+{
+	tprintf("%d, %d, %s",
+		(int) tcp->u_arg[0],
+		(int) tcp->u_arg[1],
+		signame(tcp->u_arg[2]));
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(sigpending)
+{
+	if (exiting(tcp))
+		print_sigset_addr_len(tcp, tcp->u_arg[0], current_wordsize);
+	return 0;
+}
+
+SYS_FUNC(rt_sigprocmask)
+{
+	/* Note: arg[3] is the length of the sigset. Kernel requires NSIG / 8 */
+	if (entering(tcp)) {
+		printxval(sigprocmaskcmds, tcp->u_arg[0], "SIG_???");
+		tprints(", ");
+		print_sigset_addr_len(tcp, tcp->u_arg[1], tcp->u_arg[3]);
+		tprints(", ");
+	}
+	else {
+		print_sigset_addr_len(tcp, tcp->u_arg[2], tcp->u_arg[3]);
+		tprintf(", %lu", tcp->u_arg[3]);
+	}
+	return 0;
+}
+
+/* Structure describing the action to be taken when a signal arrives.  */
+struct new_sigaction
+{
+	/* sa_handler may be a libc #define, need to use other name: */
+#ifdef MIPS
+	unsigned int sa_flags;
+	void (*__sa_handler)(int);
+#else
+	void (*__sa_handler)(int);
+	unsigned long sa_flags;
+#endif /* !MIPS */
+#if HAVE_SA_RESTORER
+	void (*sa_restorer)(void);
+#endif
+	/* Kernel treats sa_mask as an array of longs. */
+	unsigned long sa_mask[NSIG / sizeof(long) ? NSIG / sizeof(long) : 1];
+};
+/* Same for i386-on-x86_64 and similar cases */
+struct new_sigaction32
+{
+	uint32_t __sa_handler;
+	uint32_t sa_flags;
+#if HAVE_SA_RESTORER
+	uint32_t sa_restorer;
+#endif
+	uint32_t sa_mask[2 * (NSIG / sizeof(long) ? NSIG / sizeof(long) : 1)];
+};
+
+static void
+decode_new_sigaction(struct tcb *tcp, long addr)
+{
+	struct new_sigaction sa;
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+	if (current_wordsize != sizeof(sa.sa_flags) && current_wordsize == 4) {
+		struct new_sigaction32 sa32;
+
+		if (umove_or_printaddr(tcp, addr, &sa32))
+			return;
+
+		memset(&sa, 0, sizeof(sa));
+		sa.__sa_handler = (void*)(unsigned long)sa32.__sa_handler;
+		sa.sa_flags     = sa32.sa_flags;
+#if HAVE_SA_RESTORER && defined SA_RESTORER
+		sa.sa_restorer  = (void*)(unsigned long)sa32.sa_restorer;
+#endif
+		/* Kernel treats sa_mask as an array of longs.
+		 * For 32-bit process, "long" is uint32_t, thus, for example,
+		 * 32th bit in sa_mask will end up as bit 0 in sa_mask[1].
+		 * But for (64-bit) kernel, 32th bit in sa_mask is
+		 * 32th bit in 0th (64-bit) long!
+		 * For little-endian, it's the same.
+		 * For big-endian, we swap 32-bit words.
+		 */
+		sa.sa_mask[0] = sa32.sa_mask[0] + ((long)(sa32.sa_mask[1]) << 32);
+	} else
+#endif
+	if (umove_or_printaddr(tcp, addr, &sa))
+		return;
+
+	/* Architectures using function pointers, like
+	 * hppa, may need to manipulate the function pointer
+	 * to compute the result of a comparison. However,
+	 * the __sa_handler function pointer exists only in
+	 * the address space of the traced process, and can't
+	 * be manipulated by strace. In order to prevent the
+	 * compiler from generating code to manipulate
+	 * __sa_handler we cast the function pointers to long. */
+	tprints("{");
+	if ((long)sa.__sa_handler == (long)SIG_ERR)
+		tprints("SIG_ERR");
+	else if ((long)sa.__sa_handler == (long)SIG_DFL)
+		tprints("SIG_DFL");
+	else if ((long)sa.__sa_handler == (long)SIG_IGN)
+		tprints("SIG_IGN");
+	else
+		printaddr((unsigned long) sa.__sa_handler);
+	tprints(", ");
+	/*
+	 * Sigset size is in tcp->u_arg[4] (SPARC)
+	 * or in tcp->u_arg[3] (all other),
+	 * but kernel won't handle sys_rt_sigaction
+	 * with wrong sigset size (just returns EINVAL instead).
+	 * We just fetch the right size, which is NSIG / 8.
+	 */
+	tprintsigmask_val("", sa.sa_mask);
+	tprints(", ");
+
+	printflags(sigact_flags, sa.sa_flags, "SA_???");
+#if HAVE_SA_RESTORER && defined SA_RESTORER
+	if (sa.sa_flags & SA_RESTORER)
+		tprintf(", %p", sa.sa_restorer);
+#endif
+	tprints("}");
+}
+
+SYS_FUNC(rt_sigaction)
+{
+	if (entering(tcp)) {
+		printsignal(tcp->u_arg[0]);
+		tprints(", ");
+		decode_new_sigaction(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+		decode_new_sigaction(tcp, tcp->u_arg[2]);
+#if defined(SPARC) || defined(SPARC64)
+		tprintf(", %#lx, %lu", tcp->u_arg[3], tcp->u_arg[4]);
+#elif defined(ALPHA)
+		tprintf(", %lu, %#lx", tcp->u_arg[3], tcp->u_arg[4]);
+#else
+		tprintf(", %lu", tcp->u_arg[3]);
+#endif
+	}
+	return 0;
+}
+
+SYS_FUNC(rt_sigpending)
+{
+	if (exiting(tcp)) {
+		/*
+		 * One of the few syscalls where sigset size (arg[1])
+		 * is allowed to be <= NSIG / 8, not strictly ==.
+		 * This allows non-rt sigpending() syscall
+		 * to reuse rt_sigpending() code in kernel.
+		 */
+		print_sigset_addr_len_limit(tcp, tcp->u_arg[0],
+					    tcp->u_arg[1], 1);
+		tprintf(", %lu", tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+SYS_FUNC(rt_sigsuspend)
+{
+	/* NB: kernel requires arg[1] == NSIG / 8 */
+	print_sigset_addr_len(tcp, tcp->u_arg[0], tcp->u_arg[1]);
+	tprintf(", %lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+static void
+print_sigqueueinfo(struct tcb *tcp, int sig, unsigned long uinfo)
+{
+	printsignal(sig);
+	tprints(", ");
+	printsiginfo_at(tcp, uinfo);
+}
+
+SYS_FUNC(rt_sigqueueinfo)
+{
+	tprintf("%d, ", (int) tcp->u_arg[0]);
+	print_sigqueueinfo(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(rt_tgsigqueueinfo)
+{
+	tprintf("%d, %d, ", (int) tcp->u_arg[0], (int) tcp->u_arg[1]);
+	print_sigqueueinfo(tcp, tcp->u_arg[2], tcp->u_arg[3]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(rt_sigtimedwait)
+{
+	/* NB: kernel requires arg[3] == NSIG / 8 */
+	if (entering(tcp)) {
+		print_sigset_addr_len(tcp, tcp->u_arg[0], tcp->u_arg[3]);
+		tprints(", ");
+		if (!(tcp->u_arg[1] && verbose(tcp))) {
+			/*
+			 * This is the only "return" parameter,
+			 * if we are not going to fetch it on exit,
+			 * decode all parameters on entry.
+			 */
+			printaddr(tcp->u_arg[1]);
+			tprints(", ");
+			print_timespec(tcp, tcp->u_arg[2]);
+			tprintf(", %lu", tcp->u_arg[3]);
+		} else {
+			char *sts = xstrdup(sprint_timespec(tcp, tcp->u_arg[2]));
+			set_tcb_priv_data(tcp, sts, free);
+		}
+	} else {
+		if (tcp->u_arg[1] && verbose(tcp)) {
+			printsiginfo_at(tcp, tcp->u_arg[1]);
+			tprints(", ");
+			tprints(get_tcb_priv_data(tcp));
+			tprintf(", %lu", tcp->u_arg[3]);
+		}
+
+		if (!syserror(tcp) && tcp->u_rval) {
+			tcp->auxstr = signame(tcp->u_rval);
+			return RVAL_STR;
+		}
+	}
+	return 0;
+};
+
+SYS_FUNC(restart_syscall)
+{
+	tprintf("<... resuming interrupted %s ...>",
+		tcp->s_prev_ent ? tcp->s_prev_ent->sys_name : "system call");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/signalent.sh b/strace/signalent.sh
new file mode 100755
index 0000000..62ae786
--- /dev/null
+++ b/strace/signalent.sh
@@ -0,0 +1,53 @@
+#!/bin/sh
+# Copyright (c) 1996 Rick Sladkey <jrs@world.std.com>
+# 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.
+
+cat $* |
+	sed -n -e 's/\/\*.*\*\// /' -e 's/^#[ 	]*define[ 	][ 	]*SIG\([^_ 	]*\)[ 	][ 	]*\([0-9][0-9]*\)[ 	]*$/\1 \2/p' |
+	sort -k2n | uniq |
+	awk '
+	BEGIN {
+		tabs = "\t\t\t\t\t\t\t\t"
+		signal = -1;
+	}
+	$2 <= 256 {
+		if (signal == $2)
+			next
+		while (++signal < $2) {
+			n = "\"SIG_" signal "\""
+			s = "\t" n ","
+			s = s substr(tabs, 1, 16/8 - int((length(n) + 1)/8))
+			s = s "/* " signal " */"
+			print s
+		}
+		if (signal == $2)
+			n = "\"SIG" $1 "\""
+		n = "\"SIG" $1 "\""
+		s = "\t" n ","
+		s = s substr(tabs, 1, 16/8 - int((length(n) + 1)/8))
+		s = s "/* " signal " */"
+		print s
+	}
+	'
diff --git a/strace/signalfd.c b/strace/signalfd.c
new file mode 100644
index 0000000..8ddf871
--- /dev/null
+++ b/strace/signalfd.c
@@ -0,0 +1,60 @@
+/*
+ * Copyright (c) 2008-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+#ifdef HAVE_SYS_SIGNALFD_H
+# include <sys/signalfd.h>
+#endif
+
+#include "xlat/sfd_flags.h"
+
+static int
+do_signalfd(struct tcb *tcp, int flags_arg)
+{
+	/* NB: kernel requires arg[2] == NSIG / 8 */
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	print_sigset_addr_len(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	tprintf(", %lu", tcp->u_arg[2]);
+	if (flags_arg >= 0) {
+		tprints(", ");
+		printflags(sfd_flags, tcp->u_arg[flags_arg], "SFD_???");
+	}
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(signalfd)
+{
+	return do_signalfd(tcp, -1);
+}
+
+SYS_FUNC(signalfd4)
+{
+	return do_signalfd(tcp, 3);
+}
diff --git a/strace/sigreturn.c b/strace/sigreturn.c
new file mode 100644
index 0000000..f0dab0d
--- /dev/null
+++ b/strace/sigreturn.c
@@ -0,0 +1,24 @@
+#include "defs.h"
+#include <signal.h>
+#include "regs.h"
+#include "ptrace.h"
+
+#if defined HAVE_ASM_SIGCONTEXT_H && !defined HAVE_STRUCT_SIGCONTEXT
+# include <asm/sigcontext.h>
+#endif
+
+#ifndef NSIG
+# warning NSIG is not defined, using 32
+# define NSIG 32
+#elif NSIG < 32
+# error NSIG < 32
+#endif
+
+#include "arch_sigreturn.c"
+
+SYS_FUNC(sigreturn)
+{
+	arch_sigreturn(tcp);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/sock.c b/strace/sock.c
new file mode 100644
index 0000000..cf13896
--- /dev/null
+++ b/strace/sock.c
@@ -0,0 +1,328 @@
+/*
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * 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 <sys/socket.h>
+#if defined ALPHA || defined SH || defined SH64
+# include <linux/ioctl.h>
+#endif
+#include <linux/sockios.h>
+#include <arpa/inet.h>
+#include <net/if.h>
+
+#include "xlat/iffflags.h"
+
+#define PRINT_IFREQ_ADDR(tcp, ifr, sockaddr)					\
+	do {									\
+		tprints(#sockaddr "=");						\
+		print_sockaddr(tcp, &((ifr)->sockaddr),				\
+			       sizeof((ifr)->sockaddr));			\
+	} while (0)
+
+static void
+print_ifname(const char *ifname)
+{
+	print_quoted_string(ifname, IFNAMSIZ + 1, QUOTE_0_TERMINATED);
+}
+
+static void
+print_ifreq(struct tcb *tcp, const unsigned int code, const long arg,
+	    const struct ifreq *ifr)
+{
+	switch (code) {
+	case SIOCSIFADDR:
+	case SIOCGIFADDR:
+		PRINT_IFREQ_ADDR(tcp, ifr, ifr_addr);
+		break;
+	case SIOCSIFDSTADDR:
+	case SIOCGIFDSTADDR:
+		PRINT_IFREQ_ADDR(tcp, ifr, ifr_dstaddr);
+		break;
+	case SIOCSIFBRDADDR:
+	case SIOCGIFBRDADDR:
+		PRINT_IFREQ_ADDR(tcp, ifr, ifr_broadaddr);
+		break;
+	case SIOCSIFNETMASK:
+	case SIOCGIFNETMASK:
+		PRINT_IFREQ_ADDR(tcp, ifr, ifr_netmask);
+		break;
+	case SIOCSIFHWADDR:
+	case SIOCGIFHWADDR: {
+		/* XXX Are there other hardware addresses
+		   than 6-byte MACs?  */
+		const unsigned char *bytes =
+			(unsigned char *) &ifr->ifr_hwaddr.sa_data;
+		tprintf("ifr_hwaddr=%02x:%02x:%02x:%02x:%02x:%02x",
+			bytes[0], bytes[1], bytes[2],
+			bytes[3], bytes[4], bytes[5]);
+		break;
+	}
+	case SIOCSIFFLAGS:
+	case SIOCGIFFLAGS:
+		tprints("ifr_flags=");
+		printflags(iffflags, (unsigned short) ifr->ifr_flags, "IFF_???");
+		break;
+	case SIOCSIFMETRIC:
+	case SIOCGIFMETRIC:
+		tprintf("ifr_metric=%d", ifr->ifr_metric);
+		break;
+	case SIOCSIFMTU:
+	case SIOCGIFMTU:
+		tprintf("ifr_mtu=%d", ifr->ifr_mtu);
+		break;
+	case SIOCSIFSLAVE:
+	case SIOCGIFSLAVE:
+		tprints("ifr_slave=");
+		print_ifname(ifr->ifr_slave);
+		break;
+	case SIOCSIFTXQLEN:
+	case SIOCGIFTXQLEN:
+		tprintf("ifr_qlen=%d", ifr->ifr_qlen);
+		break;
+	case SIOCSIFMAP:
+	case SIOCGIFMAP:
+		tprintf("ifr_map={mem_start=%#lx, "
+			"mem_end=%#lx, base_addr=%#x, "
+			"irq=%u, dma=%u, port=%u}",
+			ifr->ifr_map.mem_start,
+			ifr->ifr_map.mem_end,
+			(unsigned) ifr->ifr_map.base_addr,
+			(unsigned) ifr->ifr_map.irq,
+			(unsigned) ifr->ifr_map.dma,
+			(unsigned) ifr->ifr_map.port);
+		break;
+	}
+}
+
+static unsigned int
+print_ifc_len(int len)
+{
+	const unsigned int n = (unsigned int) len / sizeof(struct ifreq);
+
+	if (len < 0 || n * sizeof(struct ifreq) != (unsigned int) len)
+		tprintf("%d", len);
+	else
+		tprintf("%u * sizeof(struct ifreq)", n);
+
+	return n;
+}
+
+static int
+decode_ifconf(struct tcb *tcp, const long addr)
+{
+	struct ifconf ifc;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, addr, &ifc))
+			return RVAL_DECODED | 1;
+		if (ifc.ifc_buf) {
+			tprints("{");
+			print_ifc_len(ifc.ifc_len);
+		}
+		return 1;
+	}
+
+	if (syserror(tcp) || umove(tcp, addr, &ifc) < 0) {
+		if (ifc.ifc_buf)
+			tprints("}");
+		else
+			printaddr(addr);
+		return RVAL_DECODED | 1;
+	}
+
+	if (!ifc.ifc_buf) {
+		tprints("{");
+		print_ifc_len(ifc.ifc_len);
+		tprints(", NULL}");
+		return RVAL_DECODED | 1;
+	}
+
+	tprints(" => ");
+	const unsigned int nifra = print_ifc_len(ifc.ifc_len);
+	if (!nifra) {
+		tprints("}");
+		return RVAL_DECODED | 1;
+	}
+
+	struct ifreq ifra[nifra > max_strlen ? max_strlen : nifra];
+	tprints(", ");
+	if (umove_or_printaddr(tcp, (unsigned long) ifc.ifc_buf, &ifra)) {
+		tprints("}");
+		return RVAL_DECODED | 1;
+	}
+
+	tprints("[");
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(ifra); ++i) {
+		if (i > 0)
+			tprints(", ");
+		tprints("{ifr_name=");
+		print_ifname(ifra[i].ifr_name);
+		tprints(", ");
+		PRINT_IFREQ_ADDR(tcp, &ifra[i], ifr_addr);
+		tprints("}");
+	}
+	if (i < nifra)
+		tprints(", ...");
+	tprints("]}");
+
+	return RVAL_DECODED | 1;
+}
+
+int
+sock_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	struct ifreq ifr;
+
+	switch (code) {
+	case SIOCGIFCONF:
+		return decode_ifconf(tcp, arg);
+
+#ifdef SIOCBRADDBR
+	case SIOCBRADDBR:
+	case SIOCBRDELBR:
+		tprints(", ");
+		printstr(tcp, arg, -1);
+		break;
+#endif
+
+#ifdef FIOSETOWN
+	case FIOSETOWN:
+#endif
+#ifdef SIOCSPGRP
+	case SIOCSPGRP:
+#endif
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+
+#ifdef FIOGETOWN
+	case FIOGETOWN:
+#endif
+#ifdef SIOCGPGRP
+	case SIOCGPGRP:
+#endif
+#ifdef SIOCATMARK
+	case SIOCATMARK:
+#endif
+		if (entering(tcp))
+			return 0;
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+
+#ifdef SIOCBRADDIF
+	case SIOCBRADDIF:
+#endif
+#ifdef SIOCBRDELIF
+	case SIOCBRDELIF:
+#endif
+		/* no arguments */
+		break;
+
+	case SIOCSIFNAME:
+	case SIOCSIFADDR:
+	case SIOCSIFDSTADDR:
+	case SIOCSIFBRDADDR:
+	case SIOCSIFNETMASK:
+	case SIOCSIFFLAGS:
+	case SIOCSIFMETRIC:
+	case SIOCSIFMTU:
+	case SIOCSIFSLAVE:
+	case SIOCSIFHWADDR:
+	case SIOCSIFTXQLEN:
+	case SIOCSIFMAP:
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &ifr))
+			break;
+
+		tprints("{ifr_name=");
+		print_ifname(ifr.ifr_name);
+		tprints(", ");
+		if (code == SIOCSIFNAME) {
+			tprints("ifr_newname=");
+			print_ifname(ifr.ifr_newname);
+		} else {
+			print_ifreq(tcp, code, arg, &ifr);
+		}
+		tprints("}");
+		break;
+
+	case SIOCGIFNAME:
+	case SIOCGIFINDEX:
+	case SIOCGIFADDR:
+	case SIOCGIFDSTADDR:
+	case SIOCGIFBRDADDR:
+	case SIOCGIFNETMASK:
+	case SIOCGIFFLAGS:
+	case SIOCGIFMETRIC:
+	case SIOCGIFMTU:
+	case SIOCGIFSLAVE:
+	case SIOCGIFHWADDR:
+	case SIOCGIFTXQLEN:
+	case SIOCGIFMAP:
+		if (entering(tcp)) {
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &ifr))
+				break;
+
+			if (SIOCGIFNAME == code) {
+				tprintf("{ifr_index=%d", ifr.ifr_ifindex);
+			} else {
+				tprints("{ifr_name=");
+				print_ifname(ifr.ifr_name);
+			}
+			return 1;
+		} else {
+			if (syserror(tcp)) {
+				tprints("}");
+				break;
+			}
+
+			tprints(", ");
+			if (umove(tcp, arg, &ifr) < 0) {
+				tprints("???}");
+				break;
+			}
+
+			if (SIOCGIFNAME == code) {
+				tprints("ifr_name=");
+				print_ifname(ifr.ifr_name);
+			} else {
+				print_ifreq(tcp, code, arg, &ifr);
+			}
+			tprints("}");
+			break;
+		}
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/sockaddr.c b/strace/sockaddr.c
new file mode 100644
index 0000000..412396b
--- /dev/null
+++ b/strace/sockaddr.c
@@ -0,0 +1,306 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-2000 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sys/socket.h>
+#include <sys/un.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
+#include <linux/netlink.h>
+#include <linux/if_packet.h>
+#include <linux/if_arp.h>
+#include <linux/if_ether.h>
+
+#ifdef HAVE_NETIPX_IPX_H
+# include <netipx/ipx.h>
+#else
+# include <linux/ipx.h>
+#endif
+
+#include "xlat/addrfams.h"
+#include "xlat/arp_hardware_types.h"
+#include "xlat/ethernet_protocols.h"
+#include "xlat/af_packet_types.h"
+
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+# include <bluetooth/bluetooth.h>
+# include <bluetooth/hci.h>
+# include <bluetooth/l2cap.h>
+# include <bluetooth/rfcomm.h>
+# include <bluetooth/sco.h>
+
+# include "xlat/hci_channels.h"
+#endif
+
+#define SIZEOF_SA_FAMILY sizeof(((struct sockaddr *) 0)->sa_family)
+
+static void
+print_sockaddr_data_un(const void *const buf, const int addrlen)
+{
+	const struct sockaddr_un *const sa_un = buf;
+	const int un_len = addrlen > (int) sizeof(*sa_un)
+			   ? (int) sizeof(*sa_un) : addrlen;
+	const int path_len = un_len - SIZEOF_SA_FAMILY;
+
+	tprints("sun_path=");
+	if (sa_un->sun_path[0]) {
+		print_quoted_string(sa_un->sun_path, path_len + 1,
+				    QUOTE_0_TERMINATED);
+	} else {
+		tprints("@");
+		print_quoted_string(sa_un->sun_path + 1, path_len - 1, 0);
+	}
+}
+
+static void
+print_sockaddr_data_in(const void *const buf, const int addrlen)
+{
+	const struct sockaddr_in *const sa_in = buf;
+
+	tprintf("sin_port=htons(%u), sin_addr=inet_addr(\"%s\")",
+		ntohs(sa_in->sin_port), inet_ntoa(sa_in->sin_addr));
+}
+
+#define SIN6_MIN_LEN offsetof(struct sockaddr_in6, sin6_scope_id)
+
+static void
+print_sockaddr_data_in6(const void *const buf, const int addrlen)
+{
+	const struct sockaddr_in6 *const sa_in6 = buf;
+
+	char string_addr[100];
+	inet_ntop(AF_INET6, &sa_in6->sin6_addr,
+		  string_addr, sizeof(string_addr));
+	tprintf("sin6_port=htons(%u), inet_pton(AF_INET6"
+		", \"%s\", &sin6_addr), sin6_flowinfo=htonl(%u)",
+		ntohs(sa_in6->sin6_port), string_addr,
+		ntohl(sa_in6->sin6_flowinfo));
+
+	if (addrlen <= (int) SIN6_MIN_LEN)
+		return;
+
+	tprints(", sin6_scope_id=");
+#if defined IN6_IS_ADDR_LINKLOCAL && defined IN6_IS_ADDR_MC_LINKLOCAL
+	if (IN6_IS_ADDR_LINKLOCAL(&sa_in6->sin6_addr)
+	    || IN6_IS_ADDR_MC_LINKLOCAL(&sa_in6->sin6_addr))
+		print_ifindex(sa_in6->sin6_scope_id);
+	else
+#endif
+		tprintf("%u", sa_in6->sin6_scope_id);
+}
+
+static void
+print_sockaddr_data_ipx(const void *const buf, const int addrlen)
+{
+	const struct sockaddr_ipx *const sa_ipx = buf;
+	unsigned int i;
+
+	tprintf("sipx_port=htons(%u)"
+		", sipx_network=htonl(%#08x)"
+		", sipx_node=[",
+		ntohs(sa_ipx->sipx_port),
+		ntohl(sa_ipx->sipx_network));
+	for (i = 0; i < IPX_NODE_LEN; ++i) {
+		tprintf("%s%#02x", i ? ", " : "",
+			sa_ipx->sipx_node[i]);
+	}
+	tprintf("], sipx_type=%#02x", sa_ipx->sipx_type);
+}
+
+static void
+print_sockaddr_data_nl(const void *const buf, const int addrlen)
+{
+	const struct sockaddr_nl *const sa_nl = buf;
+
+	tprintf("nl_pid=%d, nl_groups=%#08x",
+		sa_nl->nl_pid, sa_nl->nl_groups);
+}
+
+static void
+print_sockaddr_data_ll(const void *const buf, const int addrlen)
+{
+	const struct sockaddr_ll *const sa_ll = buf;
+
+	tprints("sll_protocol=htons(");
+	printxval(ethernet_protocols, ntohs(sa_ll->sll_protocol), "ETH_P_???");
+	tprints("), sll_ifindex=");
+	print_ifindex(sa_ll->sll_ifindex);
+	tprints(", sll_hatype=");
+	printxval(arp_hardware_types, sa_ll->sll_hatype, "ARPHRD_???");
+	tprints(", sll_pkttype=");
+	printxval(af_packet_types, sa_ll->sll_pkttype, "PACKET_???");
+	tprintf(", sll_halen=%u", sa_ll->sll_halen);
+	if (sa_ll->sll_halen) {
+		const unsigned int oob_halen =
+			addrlen - offsetof(struct sockaddr_ll, sll_addr);
+		unsigned int i;
+
+		tprints(", sll_addr=[");
+		for (i = 0; i < sa_ll->sll_halen; ++i) {
+			if (i)
+				tprints(", ");
+			if (i >= oob_halen) {
+				tprints("...");
+				break;
+			}
+			tprintf("%#02x", sa_ll->sll_addr[i]);
+		}
+		tprints("]");
+	}
+}
+
+static void
+print_sockaddr_data_raw(const void *const buf, const int addrlen)
+{
+	const char *const data = buf + SIZEOF_SA_FAMILY;
+	const int datalen = addrlen - SIZEOF_SA_FAMILY;
+
+	tprints("sa_data=");
+	print_quoted_string(data, datalen, 0);
+}
+
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+static void
+print_sockaddr_data_bt(const void *const buf, const int addrlen)
+{
+	switch (addrlen) {
+		case sizeof(struct sockaddr_hci): {
+			const struct sockaddr_hci *const hci = buf;
+			tprintf("hci_dev=htobs(%hu), hci_channel=",
+				btohs(hci->hci_dev));
+			printxval(hci_channels, hci->hci_channel,
+				  "HCI_CHANNEL_???");
+			break;
+		}
+		case sizeof(struct sockaddr_sco): {
+			const struct sockaddr_sco *const sco = buf;
+			tprintf("sco_bdaddr=%02x:%02x:%02x:%02x:%02x:%02x",
+				sco->sco_bdaddr.b[0], sco->sco_bdaddr.b[1],
+				sco->sco_bdaddr.b[2], sco->sco_bdaddr.b[3],
+				sco->sco_bdaddr.b[4], sco->sco_bdaddr.b[5]);
+			break;
+		}
+		case sizeof(struct sockaddr_rc): {
+			const struct sockaddr_rc *const rc = buf;
+			tprintf("rc_bdaddr=%02x:%02x:%02x:%02x:%02x:%02x"
+				", rc_channel=%u",
+				rc->rc_bdaddr.b[0], rc->rc_bdaddr.b[1],
+				rc->rc_bdaddr.b[2], rc->rc_bdaddr.b[3],
+				rc->rc_bdaddr.b[4], rc->rc_bdaddr.b[5],
+				rc->rc_channel);
+			break;
+		}
+		case sizeof(struct sockaddr_l2): {
+			const struct sockaddr_l2 *const l2 = buf;
+			tprintf("l2_psm=htobs(%hu)"
+				", l2_bdaddr=%02x:%02x:%02x:%02x:%02x:%02x"
+				", l2_cid=htobs(%hu), l2_bdaddr_type=%u",
+				btohs(l2->l2_psm),
+				l2->l2_bdaddr.b[0], l2->l2_bdaddr.b[1],
+				l2->l2_bdaddr.b[2], l2->l2_bdaddr.b[3],
+				l2->l2_bdaddr.b[4], l2->l2_bdaddr.b[5],
+				btohs(l2->l2_cid), l2->l2_bdaddr_type);
+			break;
+		}
+		default:
+			print_sockaddr_data_raw(buf, addrlen);
+			break;
+	}
+}
+#endif /* HAVE_BLUETOOTH_BLUETOOTH_H */
+
+typedef void (* const sockaddr_printer)(const void *const, const int);
+
+static const struct {
+	const sockaddr_printer printer;
+	const int min_len;
+} sa_printers[] = {
+	[AF_UNIX] = { print_sockaddr_data_un, SIZEOF_SA_FAMILY + 1 },
+	[AF_INET] = { print_sockaddr_data_in, sizeof(struct sockaddr_in) },
+	[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 },
+	[AF_PACKET] = { print_sockaddr_data_ll, sizeof(struct sockaddr_ll) },
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+	[AF_BLUETOOTH] = { print_sockaddr_data_bt, SIZEOF_SA_FAMILY + 1 },
+#endif
+};
+
+void
+print_sockaddr(struct tcb *tcp, const void *const buf, const int addrlen)
+{
+	const struct sockaddr *const sa = buf;
+
+	tprints("{sa_family=");
+	printxval(addrfams, sa->sa_family, "AF_???");
+
+	if (addrlen > (int) SIZEOF_SA_FAMILY) {
+		tprints(", ");
+
+		if (sa->sa_family < ARRAY_SIZE(sa_printers)
+		    && sa_printers[sa->sa_family].printer
+		    && addrlen >= sa_printers[sa->sa_family].min_len) {
+			sa_printers[sa->sa_family].printer(buf, addrlen);
+		} else {
+			print_sockaddr_data_raw(buf, addrlen);
+		}
+	}
+
+	tprints("}");
+}
+
+int
+decode_sockaddr(struct tcb *tcp, long addr, int addrlen)
+{
+	if (addrlen < 2) {
+		printaddr(addr);
+		return -1;
+	}
+
+	union {
+		struct sockaddr sa;
+		struct sockaddr_storage storage;
+		char pad[sizeof(struct sockaddr_storage) + 1];
+	} addrbuf;
+
+	if ((unsigned) addrlen > sizeof(addrbuf.storage))
+		addrlen = sizeof(addrbuf.storage);
+
+	if (umoven_or_printaddr(tcp, addr, addrlen, addrbuf.pad))
+		return -1;
+
+	memset(&addrbuf.pad[addrlen], 0, sizeof(addrbuf.pad) - addrlen);
+
+	print_sockaddr(tcp, &addrbuf, addrlen);
+
+	return addrbuf.sa.sa_family;
+}
diff --git a/strace/socketcall.c b/strace/socketcall.c
new file mode 100644
index 0000000..9f48a10
--- /dev/null
+++ b/strace/socketcall.c
@@ -0,0 +1,45 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "xlat/socketcalls.h"
+
+SYS_FUNC(socketcall)
+{
+	const unsigned int call = tcp->u_arg[0];
+	const char *str = xlookup(socketcalls, call);
+
+	if (str)
+		tprints(str);
+	else
+		tprintf("%d", call);
+
+	tprints(", ");
+	printaddr(tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/socketutils.c b/strace/socketutils.c
new file mode 100644
index 0000000..ff02559
--- /dev/null
+++ b/strace/socketutils.c
@@ -0,0 +1,500 @@
+/*
+ * Copyright (c) 2014 Zubin Mithra <zubin.mithra@gmail.com>
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <netinet/in.h>
+#include <sys/socket.h>
+#include <arpa/inet.h>
+#include <linux/netlink.h>
+#include <linux/sock_diag.h>
+#include <linux/inet_diag.h>
+#include <linux/unix_diag.h>
+#include <linux/netlink_diag.h>
+#include <linux/rtnetlink.h>
+#include "xlat/netlink_protocols.h"
+
+#if !defined NETLINK_SOCK_DIAG && defined NETLINK_INET_DIAG
+# define NETLINK_SOCK_DIAG NETLINK_INET_DIAG
+#endif
+
+#include <sys/un.h>
+#ifndef UNIX_PATH_MAX
+# define UNIX_PATH_MAX sizeof(((struct sockaddr_un *) 0)->sun_path)
+#endif
+
+typedef struct {
+	unsigned long inode;
+	char *details;
+} cache_entry;
+
+#define CACHE_SIZE 1024U
+static cache_entry cache[CACHE_SIZE];
+#define CACHE_MASK (CACHE_SIZE - 1)
+
+static int
+cache_and_print_inode_details(const unsigned long inode, char *const details)
+{
+	cache_entry *e = &cache[inode & CACHE_MASK];
+	free(e->details);
+	e->inode = inode;
+	e->details = details;
+
+	tprints(details);
+	return 1;
+}
+
+bool
+print_sockaddr_by_inode_cached(const unsigned long inode)
+{
+	const cache_entry *const e = &cache[inode & CACHE_MASK];
+	if (e && inode == e->inode) {
+		tprints(e->details);
+		return true;
+	}
+	return false;
+}
+
+static bool
+send_query(const int fd, void *req, size_t req_size)
+{
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct iovec iov = {
+		.iov_base = req,
+		.iov_len = req_size
+	};
+	const struct msghdr msg = {
+		.msg_name = &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	for (;;) {
+		if (sendmsg(fd, &msg, 0) < 0) {
+			if (errno == EINTR)
+				continue;
+			return false;
+		}
+		return true;
+	}
+}
+
+static bool
+inet_send_query(const int fd, const int family, const int proto)
+{
+	struct {
+		const struct nlmsghdr nlh;
+		const struct inet_diag_req_v2 idr;
+	} req = {
+		.nlh = {
+			.nlmsg_len = sizeof(req),
+			.nlmsg_type = SOCK_DIAG_BY_FAMILY,
+			.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
+		},
+		.idr = {
+			.sdiag_family = family,
+			.sdiag_protocol = proto,
+			.idiag_states = -1
+		}
+	};
+	return send_query(fd, &req, sizeof(req));
+}
+
+static int
+inet_parse_response(const char *const proto_name, const void *const data,
+		    const int data_len, const unsigned long inode)
+{
+	const struct inet_diag_msg *const diag_msg = data;
+	static const char zero_addr[sizeof(struct in6_addr)];
+	socklen_t addr_size, text_size;
+
+	if (data_len < (int) NLMSG_LENGTH(sizeof(*diag_msg)))
+		return -1;
+	if (diag_msg->idiag_inode != inode)
+		return 0;
+
+	switch(diag_msg->idiag_family) {
+		case AF_INET:
+			addr_size = sizeof(struct in_addr);
+			text_size = INET_ADDRSTRLEN;
+			break;
+		case AF_INET6:
+			addr_size = sizeof(struct in6_addr);
+			text_size = INET6_ADDRSTRLEN;
+			break;
+		default:
+			return -1;
+	}
+
+	char src_buf[text_size];
+	char *details;
+
+	if (!inet_ntop(diag_msg->idiag_family, diag_msg->id.idiag_src,
+		       src_buf, text_size))
+		return -1;
+
+	if (diag_msg->id.idiag_dport ||
+	    memcmp(zero_addr, diag_msg->id.idiag_dst, addr_size)) {
+		char dst_buf[text_size];
+
+		if (!inet_ntop(diag_msg->idiag_family, diag_msg->id.idiag_dst,
+			       dst_buf, text_size))
+			return -1;
+
+		if (asprintf(&details, "%s:[%s:%u->%s:%u]", proto_name,
+			     src_buf, ntohs(diag_msg->id.idiag_sport),
+			     dst_buf, ntohs(diag_msg->id.idiag_dport)) < 0)
+			return false;
+	} else {
+		if (asprintf(&details, "%s:[%s:%u]", proto_name, src_buf,
+			     ntohs(diag_msg->id.idiag_sport)) < 0)
+			return false;
+	}
+
+	return cache_and_print_inode_details(inode, details);
+}
+
+static bool
+receive_responses(const int fd, const unsigned long inode,
+		  const char *proto_name,
+		  int (* parser) (const char *, const void *,
+				  int, unsigned long))
+{
+	static union {
+		struct nlmsghdr hdr;
+		long buf[8192 / sizeof(long)];
+	} hdr_buf;
+
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct iovec iov = {
+		.iov_base = hdr_buf.buf,
+		.iov_len = sizeof(hdr_buf.buf)
+	};
+	int flags = 0;
+
+	for (;;) {
+		struct msghdr msg = {
+			.msg_name = &nladdr,
+			.msg_namelen = sizeof(nladdr),
+			.msg_iov = &iov,
+			.msg_iovlen = 1
+		};
+
+		ssize_t ret = recvmsg(fd, &msg, flags);
+		if (ret < 0) {
+			if (errno == EINTR)
+				continue;
+			return false;
+		}
+
+		const struct nlmsghdr *h = &hdr_buf.hdr;
+		if (!NLMSG_OK(h, ret))
+			return false;
+		for (; NLMSG_OK(h, ret); h = NLMSG_NEXT(h, ret)) {
+			if (h->nlmsg_type != SOCK_DIAG_BY_FAMILY)
+				return false;
+			const int rc = parser(proto_name, NLMSG_DATA(h),
+					      h->nlmsg_len, inode);
+			if (rc > 0)
+				return true;
+			if (rc < 0)
+				return false;
+		}
+		flags = MSG_DONTWAIT;
+	}
+}
+
+static bool
+inet_print(const int fd, const int family, const int protocol,
+	   const unsigned long inode, const char *proto_name)
+{
+	return inet_send_query(fd, family, protocol)
+		&& receive_responses(fd, inode, proto_name, inet_parse_response);
+}
+
+static bool
+unix_send_query(const int fd, const unsigned long inode)
+{
+	struct {
+		const struct nlmsghdr nlh;
+		const struct unix_diag_req udr;
+	} req = {
+		.nlh = {
+			.nlmsg_len = sizeof(req),
+			.nlmsg_type = SOCK_DIAG_BY_FAMILY,
+			.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
+		},
+		.udr = {
+			.sdiag_family = AF_UNIX,
+			.udiag_ino = inode,
+			.udiag_states = -1,
+			.udiag_show = UDIAG_SHOW_NAME | UDIAG_SHOW_PEER
+		}
+	};
+	return send_query(fd, &req, sizeof(req));
+}
+
+static int
+unix_parse_response(const char *proto_name, const void *data,
+		    const int data_len, const unsigned long inode)
+{
+	const struct unix_diag_msg *diag_msg = data;
+	struct rtattr *attr;
+	int rta_len = data_len - NLMSG_LENGTH(sizeof(*diag_msg));
+	uint32_t peer = 0;
+	size_t path_len = 0;
+	char path[UNIX_PATH_MAX + 1];
+
+	if (rta_len < 0)
+		return -1;
+	if (diag_msg->udiag_ino != inode)
+		return 0;
+	if (diag_msg->udiag_family != AF_UNIX)
+		return -1;
+
+	for (attr = (struct rtattr *) (diag_msg + 1);
+	     RTA_OK(attr, rta_len);
+	     attr = RTA_NEXT(attr, rta_len)) {
+		switch (attr->rta_type) {
+		case UNIX_DIAG_NAME:
+			if (!path_len) {
+				path_len = RTA_PAYLOAD(attr);
+				if (path_len > UNIX_PATH_MAX)
+					path_len = UNIX_PATH_MAX;
+				memcpy(path, RTA_DATA(attr), path_len);
+				path[path_len] = '\0';
+			}
+			break;
+		case UNIX_DIAG_PEER:
+			if (RTA_PAYLOAD(attr) >= 4)
+				peer = *(uint32_t *) RTA_DATA(attr);
+			break;
+		}
+	}
+
+	/*
+	 * print obtained information in the following format:
+	 * "UNIX:[" SELF_INODE [ "->" PEER_INODE ][ "," SOCKET_FILE ] "]"
+	 */
+	if (!peer && !path_len)
+		return -1;
+
+	char peer_str[3 + sizeof(peer) * 3];
+	if (peer)
+		snprintf(peer_str, sizeof(peer_str), "->%u", peer);
+	else
+		peer_str[0] = '\0';
+
+	const char *path_str;
+	if (path_len) {
+		char *outstr = alloca(4 * path_len + 4);
+
+		outstr[0] = ',';
+		if (path[0] == '\0') {
+			outstr[1] = '@';
+			string_quote(path + 1, outstr + 2,
+				     path_len - 1, QUOTE_0_TERMINATED);
+		} else {
+			string_quote(path, outstr + 1,
+				     path_len, QUOTE_0_TERMINATED);
+		}
+		path_str = outstr;
+	} else {
+		path_str = "";
+	}
+
+	char *details;
+	if (asprintf(&details, "%s:[%lu%s%s]", proto_name, inode,
+		     peer_str, path_str) < 0)
+		return -1;
+
+	return cache_and_print_inode_details(inode, details);
+}
+
+static bool
+netlink_send_query(const int fd, const unsigned long inode)
+{
+	struct {
+		const struct nlmsghdr nlh;
+		const struct netlink_diag_req ndr;
+	} req = {
+		.nlh = {
+			.nlmsg_len = sizeof(req),
+			.nlmsg_type = SOCK_DIAG_BY_FAMILY,
+			.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
+		},
+		.ndr = {
+			.sdiag_family = AF_NETLINK,
+			.sdiag_protocol = NDIAG_PROTO_ALL,
+			.ndiag_show = NDIAG_SHOW_MEMINFO
+		}
+	};
+	return send_query(fd, &req, sizeof(req));
+}
+
+static int
+netlink_parse_response(const char *proto_name, const void *data,
+		    const int data_len, const unsigned long inode)
+{
+	const struct netlink_diag_msg *const diag_msg = data;
+	const char *netlink_proto;
+	char *details;
+
+	if (data_len < (int) NLMSG_LENGTH(sizeof(*diag_msg)))
+		return -1;
+	if (diag_msg->ndiag_ino != inode)
+		return 0;
+
+	if (diag_msg->ndiag_family != AF_NETLINK)
+		return -1;
+
+	netlink_proto = xlookup(netlink_protocols,
+				diag_msg->ndiag_protocol);
+
+	if (netlink_proto) {
+		static const char netlink_prefix[] = "NETLINK_";
+		const size_t netlink_prefix_len =
+			sizeof(netlink_prefix) -1;
+		if (strncmp(netlink_proto, netlink_prefix,
+			    netlink_prefix_len) == 0)
+			netlink_proto += netlink_prefix_len;
+		if (asprintf(&details, "%s:[%s:%u]", proto_name,
+			     netlink_proto, diag_msg->ndiag_portid) < 0)
+			return -1;
+	} else {
+		if (asprintf(&details, "%s:[%u]", proto_name,
+			     (unsigned) diag_msg->ndiag_protocol) < 0)
+			return -1;
+	}
+
+	return cache_and_print_inode_details(inode, details);
+}
+
+static bool
+unix_print(const int fd, const unsigned long inode)
+{
+	return unix_send_query(fd, inode)
+		&& receive_responses(fd, inode, "UNIX", unix_parse_response);
+}
+
+static bool
+tcp_v4_print(const int fd, const unsigned long inode)
+{
+	return inet_print(fd, AF_INET, IPPROTO_TCP, inode, "TCP");
+}
+
+static bool
+udp_v4_print(const int fd, const unsigned long inode)
+{
+	return inet_print(fd, AF_INET, IPPROTO_UDP, inode, "UDP");
+}
+
+static bool
+tcp_v6_print(const int fd, const unsigned long inode)
+{
+	return inet_print(fd, AF_INET6, IPPROTO_TCP, inode, "TCPv6");
+}
+
+static bool
+udp_v6_print(const int fd, const unsigned long inode)
+{
+	return inet_print(fd, AF_INET6, IPPROTO_UDP, inode, "UDPv6");
+}
+
+static bool
+netlink_print(const int fd, const unsigned long inode)
+{
+	return netlink_send_query(fd, inode)
+		&& receive_responses(fd, inode, "NETLINK",
+				     netlink_parse_response);
+}
+
+static const struct {
+	const char *const name;
+	bool (*const print)(int, unsigned long);
+} protocols[] = {
+	[SOCK_PROTO_UNIX] = { "UNIX", unix_print },
+	[SOCK_PROTO_TCP] = { "TCP", tcp_v4_print },
+	[SOCK_PROTO_UDP] = { "UDP", udp_v4_print },
+	[SOCK_PROTO_TCPv6] = { "TCPv6", tcp_v6_print },
+	[SOCK_PROTO_UDPv6] = { "UDPv6", udp_v6_print },
+	[SOCK_PROTO_NETLINK] = { "NETLINK", netlink_print }
+};
+
+enum sock_proto
+get_proto_by_name(const char *const name)
+{
+	unsigned int i;
+	for (i = (unsigned int) SOCK_PROTO_UNKNOWN + 1;
+	     i < ARRAY_SIZE(protocols); ++i) {
+		if (protocols[i].name && !strcmp(name, protocols[i].name))
+			return (enum sock_proto) i;
+	}
+	return SOCK_PROTO_UNKNOWN;
+}
+
+/* Given an inode number of a socket, print out the details
+ * of the ip address and port. */
+
+bool
+print_sockaddr_by_inode(const unsigned long inode, const enum sock_proto proto)
+{
+	if ((unsigned int) proto >= ARRAY_SIZE(protocols) ||
+	    (proto != SOCK_PROTO_UNKNOWN && !protocols[proto].print))
+		return false;
+
+	const int fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG);
+	if (fd < 0)
+		return false;
+	bool r = false;
+
+	if (proto != SOCK_PROTO_UNKNOWN) {
+		r = protocols[proto].print(fd, inode);
+		if (!r) {
+			tprintf("%s:[%lu]", protocols[proto].name, inode);
+			r = true;
+		}
+	} else {
+		unsigned int i;
+		for (i = (unsigned int) SOCK_PROTO_UNKNOWN + 1;
+		     i < ARRAY_SIZE(protocols); ++i) {
+			if (!protocols[i].print)
+				continue;
+			r = protocols[i].print(fd, inode);
+			if (r)
+				break;
+		}
+	}
+
+	close(fd);
+	return r;
+}
diff --git a/strace/sram_alloc.c b/strace/sram_alloc.c
new file mode 100644
index 0000000..969e10e
--- /dev/null
+++ b/strace/sram_alloc.c
@@ -0,0 +1,19 @@
+#include "defs.h"
+
+#ifdef BFIN
+
+#include <bfin_sram.h>
+
+#include "xlat/sram_alloc_flags.h"
+
+SYS_FUNC(sram_alloc)
+{
+	/* size */
+	tprintf("%lu, ", tcp->u_arg[0]);
+	/* flags */
+	printflags_long(sram_alloc_flags, tcp->u_arg[1], "???_SRAM");
+
+	return RVAL_DECODED | RVAL_HEX;
+}
+
+#endif /* BFIN */
diff --git a/strace/statfs.c b/strace/statfs.c
new file mode 100644
index 0000000..00dd04c
--- /dev/null
+++ b/strace/statfs.c
@@ -0,0 +1,12 @@
+#include "defs.h"
+
+SYS_FUNC(statfs)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_struct_statfs(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/statfs.h b/strace/statfs.h
new file mode 100644
index 0000000..9341687
--- /dev/null
+++ b/strace/statfs.h
@@ -0,0 +1,45 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef STRACE_STATFS_H
+#define STRACE_STATFS_H
+
+struct strace_statfs {
+	unsigned long long f_type;
+	unsigned long long f_bsize;
+	unsigned long long f_blocks;
+	unsigned long long f_bfree;
+	unsigned long long f_bavail;
+	unsigned long long f_files;
+	unsigned long long f_ffree;
+	unsigned long f_fsid[2];
+	unsigned long long f_namelen;
+	unsigned long long f_frsize;
+	unsigned long long f_flags;
+};
+
+#endif /* STRACE_STATFS_H */
diff --git a/strace/statfs64.c b/strace/statfs64.c
new file mode 100644
index 0000000..f459831
--- /dev/null
+++ b/strace/statfs64.c
@@ -0,0 +1,14 @@
+#include "defs.h"
+
+SYS_FUNC(statfs64)
+{
+	const unsigned long size = tcp->u_arg[1];
+
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprintf(", %lu, ", size);
+	} else {
+		print_struct_statfs64(tcp, tcp->u_arg[2], size);
+	}
+	return 0;
+}
diff --git a/strace/strace-graph b/strace/strace-graph
new file mode 100755
index 0000000..5435e86
--- /dev/null
+++ b/strace/strace-graph
@@ -0,0 +1,352 @@
+#!/usr/bin/perl
+
+# This script processes strace -f output.  It displays a graph of invoked
+# subprocesses, and is useful for finding out what complex commands do.
+
+# You will probably want to invoke strace with -q as well, and with
+# -s 100 to get complete filenames.
+
+# The script can also handle the output with strace -t, -tt, or -ttt.
+# It will add elapsed time for each process in that case.
+
+# This script is Copyright (C) 1998 by Richard Braakman <dark@xs4all.nl>.
+
+# 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.
+
+use strict;
+use warnings;
+
+my %unfinished;
+my $floatform;
+
+# Scales for strace slowdown.  Make configurable!
+my $scale_factor = 3.5;
+
+while (<>) {
+    my ($pid, $call, $args, $result, $time, $time_spent);
+    chop;
+    $floatform = 0;
+
+    s/^(\d+)\s+//;
+    $pid = $1;
+
+    if (s/^(\d\d):(\d\d):(\d\d)(?:\.(\d\d\d\d\d\d))? //) {
+	$time = $1 * 3600 + $2 * 60 + $3;
+	if (defined $4) {
+	    $time = $time + $4 / 1000000;
+	    $floatform = 1;
+	}
+    } elsif (s/^(\d+)\.(\d\d\d\d\d\d) //) {
+	$time = $1 + ($2 / 1000000);
+	$floatform = 1;
+    }
+
+    if (s/ <unfinished ...>$//) {
+	$unfinished{$pid} = $_;
+	next;
+    }
+
+    if (s/^<... \S+ resumed> //) {
+	unless (exists $unfinished{$pid}) {
+	    print STDERR "$0: $ARGV: cannot find start of resumed call on line $.";
+	    next;
+	}
+	$_ = $unfinished{$pid} . $_;
+	delete $unfinished{$pid};
+    }
+
+    if (/^--- SIG(\S+) (.*) ---$/) {
+	# $pid received signal $1
+	# currently we don't do anything with this
+	next;
+    }
+
+    if (/^\+\+\+ killed by SIG(\S+) \+\+\+$/) {
+	# $pid received signal $1
+	handle_killed($pid, $time);
+	next;
+    }
+
+    if (/^\+\+\+ exited with (\d+) \+\+\+$/) {
+	# $pid exited $1
+	# currently we don't do anything with this
+	next;
+    }
+
+    ($call, $args, $result) = /(\S+)\((.*)\)\s+= (.*)$/;
+    if ($result =~ /^(.*) <([0-9.]*)>$/) {
+	($result, $time_spent) = ($1, $2);
+    }
+    unless (defined $result) {
+	print STDERR "$0: $ARGV: $.: cannot parse line.\n";
+	next;
+    }
+
+    handle_trace($pid, $call, $args, $result, $time);
+}
+
+display_trace();
+
+exit 0;
+
+sub parse_str {
+    my ($in) = @_;
+    my $result = "";
+
+    while (1) {
+	if ($in =~ s/^\\(.)//) {
+	    $result .= $1;
+	} elsif ($in =~ s/^\"//) {
+	    if ($in =~ s/^\.\.\.//) {
+		return ("$result...", $in);
+	    }
+	    return ($result, $in);
+	} elsif ($in =~ s/([^\\\"]*)//) {
+	    $result .= $1;
+	} else {
+	    return (undef, $in);
+	}
+    }
+}
+
+sub parse_one {
+    my ($in) = @_;
+
+    if ($in =~ s/^\"//) {
+	my $tmp;
+	($tmp, $in) = parse_str($in);
+	if (not defined $tmp) {
+	    print STDERR "$0: $ARGV: $.: cannot parse string.\n";
+	    return (undef, $in);
+	}
+	return ($tmp, $in);
+    } elsif ($in =~ s/^0x([[:xdigit:]]+)//) {
+	return (hex $1, $in);
+    } elsif ($in =~ s/^(\d+)//) {
+	return (int $1, $in);
+    } else {
+	print STDERR "$0: $ARGV: $.: unrecognized element.\n";
+	return (undef, $in);
+    }
+}
+
+sub parseargs {
+    my ($in) = @_;
+    my @args = ();
+    my $tmp;
+
+    while (length $in) {
+	if ($in =~ s/^\[//) {
+	    my @subarr = ();
+	    if ($in =~ s,^/\* (\d+) vars \*/\],,) {
+		push @args, $1;
+	    } else {
+		while ($in !~ s/^\]//) {
+		    ($tmp, $in) = parse_one($in);
+		    defined $tmp or return undef;
+		    push @subarr, $tmp;
+		    unless ($in =~ /^\]/ or $in =~ s/^, //) {
+			print STDERR "$0: $ARGV: $.: missing comma in array.\n";
+			return undef;
+		    }
+		    if ($in =~ s/^\.\.\.//) {
+			push @subarr, "...";
+		    }
+		}
+		push @args, \@subarr;
+	    }
+	} elsif ($in =~ s/^\{//) {
+	    my %subhash = ();
+	    while ($in !~ s/^\}//) {
+		my $key;
+		unless ($in =~ s/^(\w+)=//) {
+		    print STDERR "$0: $ARGV: $.: struct field expected.\n";
+		    return undef;
+		}
+		$key = $1;
+		($tmp, $in) = parse_one($in);
+		defined $tmp or return undef;
+		$subhash{$key} = $tmp;
+		unless ($in =~ s/, //) {
+		    print STDERR "$0: $ARGV: $.: missing comma in struct.\n";
+		    return undef;
+		}
+	    }
+	    push @args, \%subhash;
+	} else {
+	    ($tmp, $in) = parse_one($in);
+	    defined $tmp or return undef;
+	    push @args, $tmp;
+	}
+	unless (length($in) == 0 or $in =~ s/^, //) {
+	    print STDERR "$0: $ARGV: $.: missing comma.\n";
+	    return undef;
+	}
+    }
+    return @args;
+}
+
+
+my $depth = "";
+
+# process info, indexed by pid.
+# fields:
+#    parent         pid number
+#    seq            clones, forks and execs for this pid, in sequence  (array)
+
+#  filename and argv (from latest exec)
+#  basename (derived from filename)
+# argv[0] is modified to add the basename if it differs from the 0th argument.
+
+my %pr;
+
+sub handle_trace {
+    my ($pid, $call, $args, $result, $time) = @_;
+    my $p;
+
+    if (defined $time and not defined $pr{$pid}{start}) {
+	$pr{$pid}{start} = $time;
+    }
+
+    if ($call eq 'execve') {
+	return if $result ne '0';
+
+	my ($filename, $argv) = parseargs($args);
+	my ($basename) = $filename =~ m/([^\/]*)$/;
+	if ($basename ne $$argv[0]) {
+	    $$argv[0] = "$basename($$argv[0])";
+        }
+	my $seq = $pr{$pid}{seq};
+	$seq = [] if not defined $seq;
+
+	push @$seq, ['EXEC', $filename, $argv];
+
+	$pr{$pid}{seq} = $seq;
+    } elsif ($call eq 'fork' || $call eq 'clone' || $call eq 'vfork') {
+	return if $result == 0;
+
+	my $seq = $pr{$pid}{seq};
+	$seq = [] if not defined $seq;
+	push @$seq, ['FORK', $result];
+	$pr{$pid}{seq} = $seq;
+	$pr{$result}{parent} = $pid;
+	$pr{$result}{seq} = [];
+    } elsif ($call eq '_exit' || $call eq 'exit_group') {
+	$pr{$pid}{end} = $time if defined $time;
+    }
+}
+
+sub handle_killed {
+    my ($pid, $time) = @_;
+    $pr{$pid}{end} = $time if defined $time;
+}
+
+sub straight_seq {
+    my ($pid) = @_;
+    my $seq = $pr{$pid}{seq};
+
+    for my $elem (@$seq) {
+	if ($$elem[0] eq 'EXEC') {
+	    my $argv = $$elem[2];
+	    print "$$elem[0] $$elem[1] @$argv\n";
+	} elsif ($$elem[0] eq 'FORK') {
+	    print "$$elem[0] $$elem[1]\n";
+	} else {
+	    print "$$elem[0]\n";
+	}
+    }
+}
+
+sub first_exec {
+    my ($pid) = @_;
+    my $seq = $pr{$pid}{seq};
+
+    for my $elem (@$seq) {
+	if ($$elem[0] eq 'EXEC') {
+	    return $elem;
+	}
+    }
+    return undef;
+}
+
+sub display_pid_trace {
+    my ($pid, $lead) = @_;
+    my $i = 0;
+    my @seq = @{$pr{$pid}{seq}};
+    my $elapsed;
+
+    if (not defined first_exec($pid)) {
+	unshift @seq, ['EXEC', '', ['(anon)'] ];
+    }
+
+    if (defined $pr{$pid}{start} and defined $pr{$pid}{end}) {
+	$elapsed = $pr{$pid}{end} - $pr{$pid}{start};
+	$elapsed /= $scale_factor;
+	if ($floatform) {
+	    $elapsed = sprintf("%0.02f", $elapsed);
+	} else {
+	    $elapsed = int $elapsed;
+	}
+    }
+
+    for my $elem (@seq) {
+	$i++;
+	if ($$elem[0] eq 'EXEC') {
+	    my $argv = $$elem[2];
+	    if (defined $elapsed) {
+		print "$lead [$elapsed] $pid @$argv\n";
+		undef $elapsed;
+	    } else {
+		print "$lead $pid @$argv\n";
+	    }
+	} elsif ($$elem[0] eq 'FORK') {
+	    if ($i == 1) {
+                if ($lead =~ /-$/) {
+		    display_pid_trace($$elem[1], "$lead--+--");
+                } else {
+		    display_pid_trace($$elem[1], "$lead  +--");
+                }
+	    } elsif ($i == @seq) {
+		display_pid_trace($$elem[1], "$lead  `--");
+	    } else {
+		display_pid_trace($$elem[1], "$lead  +--");
+	    }
+	}
+	if ($i == 1) {
+	    $lead =~ s/\`--/   /g;
+	    $lead =~ s/-/ /g;
+	    $lead =~ s/\+/|/g;
+	}
+    }
+}
+
+sub display_trace {
+    my ($startpid) = @_;
+
+    $startpid = (keys %pr)[0];
+    while ($pr{$startpid}{parent}) {
+	$startpid = $pr{$startpid}{parent};
+    }
+
+    display_pid_trace($startpid, "");
+}
diff --git a/strace/strace-log-merge b/strace/strace-log-merge
new file mode 100755
index 0000000..8ab2409
--- /dev/null
+++ b/strace/strace-log-merge
@@ -0,0 +1,43 @@
+#!/bin/sh
+
+show_usage()
+{
+	cat <<__EOF__
+Usage: ${0##*/} STRACE_LOG
+
+Finds all STRACE_LOG.PID files, adds PID prefix to every line,
+then combines and sorts them, and prints result to standard output.
+
+It is assumed that STRACE_LOGs were produced by strace with -tt[t]
+option which prints timestamps (otherwise sorting won't do any good).
+__EOF__
+}
+
+if [ $# -ne 1 ]; then
+	show_usage >&2
+	exit 1
+elif [ "$1" = '--help' ]; then
+	show_usage
+	exit 0
+fi
+
+logfile=$1
+
+for file in "$logfile".*; do
+	[ -f "$file" ] || continue
+	suffix=${file#"$logfile".}
+	[ "$suffix" -gt 0 ] 2> /dev/null ||
+		continue
+	pid=$(printf "%-5s" $suffix)
+	# Some strace logs have last line which is not '\n' terminated,
+	# so add extra newline to every file.
+	# grep -v '^$' removes empty lines which may result.
+	sed "s/^/$pid /" < "$file"
+	echo
+done \
+| sort -s -k2,2 | grep -v '^$'
+
+rc=$?
+[ $rc -eq 1 ] &&
+	echo >&2 "${0##*/}: $logfile: strace output not found"
+exit $rc
diff --git a/strace/strace.1 b/strace/strace.1
new file mode 100644
index 0000000..b7dddc0
--- /dev/null
+++ b/strace/strace.1
@@ -0,0 +1,736 @@
+.\" Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+.\" Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+.\" Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+.\" 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.
+.de CW
+.sp
+.nf
+.ft CW
+..
+.de CE
+.ft R
+.fi
+.sp
+..
+.\" Macro IX is not defined in the groff macros
+.if \n(.g \{\
+.  de IX
+..
+.\}
+.TH STRACE 1 "2010-03-30"
+.SH NAME
+strace \- trace system calls and signals
+.SH SYNOPSIS
+.B strace
+[\fB-CdffhikqrtttTvVxxy\fR]
+[\fB-I\fIn\fR]
+[\fB-b\fIexecve\fR]
+[\fB-e\fIexpr\fR]...
+[\fB-a\fIcolumn\fR]
+[\fB-o\fIfile\fR]
+[\fB-s\fIstrsize\fR]
+[\fB-P\fIpath\fR]... \fB-p\fIpid\fR... /
+[\fB-D\fR]
+[\fB-E\fIvar\fR[=\fIval\fR]]... [\fB-u\fIusername\fR]
+\fIcommand\fR [\fIargs\fR]
+.sp
+.B strace
+\fB-c\fR[\fBdf\fR]
+[\fB-I\fIn\fR]
+[\fB-b\fIexecve\fR]
+[\fB-e\fIexpr\fR]...
+[\fB-O\fIoverhead\fR]
+[\fB-S\fIsortby\fR] \fB-p\fIpid\fR... /
+[\fB-D\fR]
+[\fB-E\fIvar\fR[=\fIval\fR]]... [\fB-u\fIusername\fR]
+\fIcommand\fR [\fIargs\fR]
+.SH DESCRIPTION
+.IX "strace command" "" "\fLstrace\fR command"
+.LP
+In the simplest case
+.B strace
+runs the specified
+.I command
+until it exits.
+It intercepts and records the system calls which are called
+by a process and the signals which are received by a process.
+The name of each system call, its arguments and its return value
+are printed on standard error or to the file specified with the
+.B \-o
+option.
+.LP
+.B strace
+is a useful diagnostic, instructional, and debugging tool.
+System administrators, diagnosticians and trouble-shooters will find
+it invaluable for solving problems with
+programs for which the source is not readily available since
+they do not need to be recompiled in order to trace them.
+Students, hackers and the overly-curious will find that
+a great deal can be learned about a system and its system calls by
+tracing even ordinary programs.  And programmers will find that
+since system calls and signals are events that happen at the user/kernel
+interface, a close examination of this boundary is very
+useful for bug isolation, sanity checking and
+attempting to capture race conditions.
+.LP
+Each line in the trace contains the system call name, followed
+by its arguments in parentheses and its return value.
+An example from stracing the command "cat /dev/null" is:
+.CW
+open("/dev/null", O_RDONLY) = 3
+.CE
+Errors (typically a return value of \-1) have the errno symbol
+and error string appended.
+.CW
+open("/foo/bar", O_RDONLY) = \-1 ENOENT (No such file or directory)
+.CE
+Signals are printed as signal symbol and decoded siginfo structure.
+An excerpt from stracing and interrupting the command "sleep 666" is:
+.CW
+sigsuspend([] <unfinished ...>
+--- SIGINT {si_signo=SIGINT, si_code=SI_USER, si_pid=...} ---
++++ killed by SIGINT +++
+.CE
+If a system call is being executed and meanwhile another one is being called
+from a different thread/process then
+.B strace
+will try to preserve the order of those events and mark the ongoing call as
+being
+.IR unfinished .
+When the call returns it will be marked as
+.IR resumed .
+.CW
+[pid 28772] select(4, [3], NULL, NULL, NULL <unfinished ...>
+[pid 28779] clock_gettime(CLOCK_REALTIME, {1130322148, 939977000}) = 0
+[pid 28772] <... select resumed> )      = 1 (in [3])
+.CE
+Interruption of a (restartable) system call by a signal delivery is processed
+differently as kernel terminates the system call and also arranges its
+immediate reexecution after the signal handler completes.
+.CW
+read(0, 0x7ffff72cf5cf, 1)              = ? ERESTARTSYS (To be restarted)
+--- SIGALRM ... ---
+rt_sigreturn(0xe)                       = 0
+read(0, "", 1)                          = 0
+.CE
+Arguments are printed in symbolic form with a passion.
+This example shows the shell performing ">>xyzzy" output redirection:
+.CW
+open("xyzzy", O_WRONLY|O_APPEND|O_CREAT, 0666) = 3
+.CE
+Here the third argument of open is decoded by breaking down the
+flag argument into its three bitwise-OR constituents and printing the
+mode value in octal by tradition.  Where traditional or native
+usage differs from ANSI or POSIX, the latter forms are preferred.
+In some cases,
+.B strace
+output has proven to be more readable than the source.
+.LP
+Structure pointers are dereferenced and the members are displayed
+as appropriate.  In all cases arguments are formatted in the most C-like
+fashion possible.
+For example, the essence of the command "ls \-l /dev/null" is captured as:
+.CW
+lstat("/dev/null", {st_mode=S_IFCHR|0666, st_rdev=makedev(1, 3), ...}) = 0
+.CE
+Notice how the 'struct stat' argument is dereferenced and how each member is
+displayed symbolically.  In particular, observe how the st_mode member
+is carefully decoded into a bitwise-OR of symbolic and numeric values.
+Also notice in this example that the first argument to lstat is an input
+to the system call and the second argument is an output.  Since output
+arguments are not modified if the system call fails, arguments may not
+always be dereferenced.  For example, retrying the "ls \-l" example
+with a non-existent file produces the following line:
+.CW
+lstat("/foo/bar", 0xb004) = \-1 ENOENT (No such file or directory)
+.CE
+In this case the porch light is on but nobody is home.
+.LP
+Character pointers are dereferenced and printed as C strings.
+Non-printing characters in strings are normally represented by
+ordinary C escape codes.
+Only the first
+.I strsize
+(32 by default) bytes of strings are printed;
+longer strings have an ellipsis appended following the closing quote.
+Here is a line from "ls \-l" where the
+.B getpwuid
+library routine is reading the password file:
+.CW
+read(3, "root::0:0:System Administrator:/"..., 1024) = 422
+.CE
+While structures are annotated using curly braces, simple pointers
+and arrays are printed using square brackets with commas separating
+elements.  Here is an example from the command "id" on a system with
+supplementary group ids:
+.CW
+getgroups(32, [100, 0]) = 2
+.CE
+On the other hand, bit-sets are also shown using square brackets
+but set elements are separated only by a space.  Here is the shell
+preparing to execute an external command:
+.CW
+sigprocmask(SIG_BLOCK, [CHLD TTOU], []) = 0
+.CE
+Here the second argument is a bit-set of two signals, SIGCHLD and SIGTTOU.
+In some cases the bit-set is so full that printing out the unset
+elements is more valuable.  In that case, the bit-set is prefixed by
+a tilde like this:
+.CW
+sigprocmask(SIG_UNBLOCK, ~[], NULL) = 0
+.CE
+Here the second argument represents the full set of all signals.
+.SH OPTIONS
+.TP 12
+.TP
+.B \-c
+Count time, calls, and errors for each system call and report a summary on
+program exit.  On Linux, this attempts to show system time (CPU time spent
+running in the kernel) independent of wall clock time.  If
+.B \-c
+is used with
+.B \-f
+or
+.B \-F
+(below), only aggregate totals for all traced processes are kept.
+.TP
+.B \-C
+Like
+.B \-c
+but also print regular output while processes are running.
+.TP
+.B \-D
+Run tracer process as a detached grandchild, not as parent of the
+tracee.  This reduces the visible effect of
+.B strace
+by keeping the tracee a direct child of the calling process.
+.TP
+.B \-d
+Show some debugging output of
+.B strace
+itself on the standard error.
+.TP
+.B \-f
+Trace child processes as they are created by currently traced
+processes as a result of the
+.BR fork (2),
+.BR vfork (2)
+and
+.BR clone (2)
+system calls.  Note that
+.B \-p
+.I PID
+.B \-f
+will attach all threads of process PID if it is multi-threaded,
+not only thread with thread_id = PID.
+.TP
+.B \-ff
+If the
+.B \-o
+.I filename
+option is in effect, each processes trace is written to
+.I filename.pid
+where pid is the numeric process id of each process.
+This is incompatible with
+.BR \-c ,
+since no per-process counts are kept.
+.TP
+.B \-F
+This option is now obsolete and it has the same functionality as
+.BR \-f .
+.TP
+.B \-h
+Print the help summary.
+.TP
+.B \-i
+Print the instruction pointer at the time of the system call.
+.TP
+.B \-k
+Print the execution stack trace of the traced processes after each system call (experimental).
+This option is available only if
+.B strace
+is built with libunwind.
+.TP
+.B \-q
+Suppress messages about attaching, detaching etc.  This happens
+automatically when output is redirected to a file and the command
+is run directly instead of attaching.
+.TP
+.B \-qq
+If given twice, suppress messages about process exit status.
+.TP
+.B \-r
+Print a relative timestamp upon entry to each system call.  This
+records the time difference between the beginning of successive
+system calls.
+.TP
+.B \-t
+Prefix each line of the trace with the time of day.
+.TP
+.B \-tt
+If given twice, the time printed will include the microseconds.
+.TP
+.B \-ttt
+If given thrice, the time printed will include the microseconds
+and the leading portion will be printed as the number
+of seconds since the epoch.
+.TP
+.B \-T
+Show the time spent in system calls.  This records the time
+difference between the beginning and the end of each system call.
+.TP
+.B \-w
+Summarise the time difference between the beginning and end of
+each system call.  The default is to summarise the system time.
+.TP
+.B \-v
+Print unabbreviated versions of environment, stat, termios, etc.
+calls.  These structures are very common in calls and so the default
+behavior displays a reasonable subset of structure members.  Use
+this option to get all of the gory details.
+.TP
+.B \-V
+Print the version number of
+.BR strace .
+.TP
+.B \-x
+Print all non-ASCII strings in hexadecimal string format.
+.TP
+.B \-xx
+Print all strings in hexadecimal string format.
+.TP
+.B \-y
+Print paths associated with file descriptor arguments.
+.TP
+.B \-yy
+Print protocol specific information associated with socket file descriptors.
+.TP
+.BI "\-a " column
+Align return values in a specific column (default column 40).
+.TP
+.BI "\-b " syscall
+If specified syscall is reached, detach from traced process.
+Currently, only
+.I execve
+syscall is supported.  This option is useful if you want to trace
+multi-threaded process and therefore require -f, but don't want
+to trace its (potentially very complex) children.
+.TP
+.BI "\-e " expr
+A qualifying expression which modifies which events to trace
+or how to trace them.  The format of the expression is:
+.RS 15
+.IP
+[\,\fIqualifier\/\fB=\fR][\fB!\fR]\,\fIvalue1\/\fR[\fB,\,\fIvalue2\/\fR]...
+.RE
+.IP
+where
+.I qualifier
+is one of
+.BR trace ,
+.BR abbrev ,
+.BR verbose ,
+.BR raw ,
+.BR signal ,
+.BR read ,
+or
+.B write
+and
+.I value
+is a qualifier-dependent symbol or number.  The default
+qualifier is
+.BR trace .
+Using an exclamation mark negates the set of values.  For example,
+.BR \-e "\ " open
+means literally
+.BR \-e "\ " trace = open
+which in turn means trace only the
+.B open
+system call.  By contrast,
+.BR \-e "\ " trace "=!" open
+means to trace every system call except
+.BR open .
+In addition, the special values
+.B all
+and
+.B none
+have the obvious meanings.
+.IP
+Note that some shells use the exclamation point for history
+expansion even inside quoted arguments.  If so, you must escape
+the exclamation point with a backslash.
+.TP
+\fB\-e\ trace\fR=\,\fIset\fR
+Trace only the specified set of system calls.  The
+.B \-c
+option is useful for determining which system calls might be useful
+to trace.  For example,
+.BR trace = open,close,read,write
+means to only
+trace those four system calls.  Be careful when making inferences
+about the user/kernel boundary if only a subset of system calls
+are being monitored.  The default is
+.BR trace = all .
+.TP
+.BR "\-e\ trace" = file
+Trace all system calls which take a file name as an argument.  You
+can think of this as an abbreviation for
+.BR "\-e\ trace" = open , stat , chmod , unlink ,...
+which is useful to seeing what files the process is referencing.
+Furthermore, using the abbreviation will ensure that you don't
+accidentally forget to include a call like
+.B lstat
+in the list.  Betchya woulda forgot that one.
+.TP
+.BR "\-e\ trace" = process
+Trace all system calls which involve process management.  This
+is useful for watching the fork, wait, and exec steps of a process.
+.TP
+.BR "\-e\ trace" = network
+Trace all the network related system calls.
+.TP
+.BR "\-e\ trace" = signal
+Trace all signal related system calls.
+.TP
+.BR "\-e\ trace" = ipc
+Trace all IPC related system calls.
+.TP
+.BR "\-e\ trace" = desc
+Trace all file descriptor related system calls.
+.TP
+.BR "\-e\ trace" = memory
+Trace all memory mapping related system calls.
+.TP
+\fB\-e\ abbrev\fR=\,\fIset\fR
+Abbreviate the output from printing each member of large structures.
+The default is
+.BR abbrev = all .
+The
+.B \-v
+option has the effect of
+.BR abbrev = none .
+.TP
+\fB\-e\ verbose\fR=\,\fIset\fR
+Dereference structures for the specified set of system calls.  The
+default is
+.BR verbose = all .
+.TP
+\fB\-e\ raw\fR=\,\fIset\fR
+Print raw, undecoded arguments for the specified set of system calls.
+This option has the effect of causing all arguments to be printed
+in hexadecimal.  This is mostly useful if you don't trust the
+decoding or you need to know the actual numeric value of an
+argument.
+.TP
+\fB\-e\ signal\fR=\,\fIset\fR
+Trace only the specified subset of signals.  The default is
+.BR signal = all .
+For example,
+.B signal "=!" SIGIO
+(or
+.BR signal "=!" io )
+causes SIGIO signals not to be traced.
+.TP
+\fB\-e\ read\fR=\,\fIset\fR
+Perform a full hexadecimal and ASCII dump of all the data read from
+file descriptors listed in the specified set.  For example, to see
+all input activity on file descriptors
+.I 3
+and
+.I 5
+use
+\fB\-e\ read\fR=\,\fI3\fR,\fI5\fR.
+Note that this is independent from the normal tracing of the
+.BR read (2)
+system call which is controlled by the option
+.BR -e "\ " trace = read .
+.TP
+\fB\-e\ write\fR=\,\fIset\fR
+Perform a full hexadecimal and ASCII dump of all the data written to
+file descriptors listed in the specified set.  For example, to see
+all output activity on file descriptors
+.I 3
+and
+.I 5
+use
+\fB\-e\ write\fR=\,\fI3\fR,\,\fI5\fR.
+Note that this is independent from the normal tracing of the
+.BR write (2)
+system call which is controlled by the option
+.BR -e "\ " trace = write .
+.TP
+.BI "\-I " interruptible
+When strace can be interrupted by signals (such as pressing ^C).
+1: no signals are blocked; 2: fatal signals are blocked while decoding syscall
+(default); 3: fatal signals are always blocked (default if '-o FILE PROG');
+4: fatal signals and SIGTSTP (^Z) are always blocked (useful to make
+strace -o FILE PROG not stop on ^Z).
+.TP
+.BI "\-o " filename
+Write the trace output to the file
+.I filename
+rather than to stderr.
+Use
+.I filename.pid
+if
+.B \-ff
+is used.
+If the argument begins with '|' or with '!' then the rest of the
+argument is treated as a command and all output is piped to it.
+This is convenient for piping the debugging output to a program
+without affecting the redirections of executed programs.
+.TP
+.BI "\-O " overhead
+Set the overhead for tracing system calls to
+.I overhead
+microseconds.
+This is useful for overriding the default heuristic for guessing
+how much time is spent in mere measuring when timing system calls using
+the
+.B \-c
+option.  The accuracy of the heuristic can be gauged by timing a given
+program run without tracing (using
+.BR time (1))
+and comparing the accumulated
+system call time to the total produced using
+.BR \-c .
+.TP
+.BI "\-p " pid
+Attach to the process with the process
+.SM ID
+.I pid
+and begin tracing.
+The trace may be terminated
+at any time by a keyboard interrupt signal (\c
+.SM CTRL\s0-C).
+.B strace
+will respond by detaching itself from the traced process(es)
+leaving it (them) to continue running.
+Multiple
+.B \-p
+options can be used to attach to many processes in addition to
+.I command
+(which is optional if at least one
+.B \-p
+option is given).
+.B \-p
+"`pidof PROG`" syntax is supported.
+.TP
+.BI "\-P " path
+Trace only system calls accessing
+.IR path .
+Multiple
+.B \-P
+options can be used to specify several paths.
+.TP
+.BI "\-s " strsize
+Specify the maximum string size to print (the default is 32).  Note
+that filenames are not considered strings and are always printed in
+full.
+.TP
+.BI "\-S " sortby
+Sort the output of the histogram printed by the
+.B \-c
+option by the specified criterion.  Legal values are
+.BR time ,
+.BR calls ,
+.BR name ,
+and
+.B nothing
+(default is
+.BR time ).
+.TP
+.BI "\-u " username
+Run command with the user \s-1ID\s0, group \s-2ID\s0, and
+supplementary groups of
+.IR username .
+This option is only useful when running as root and enables the
+correct execution of setuid and/or setgid binaries.
+Unless this option is used setuid and setgid programs are executed
+without effective privileges.
+.TP
+\fB\-E\ \fIvar\fR=\,\fIval\fR
+Run command with
+.IR var = val
+in its list of environment variables.
+.TP
+.BI "\-E " var
+Remove
+.IR var
+from the inherited list of environment variables before passing it on to
+the command.
+.SH DIAGNOSTICS
+When
+.I command
+exits,
+.B strace
+exits with the same exit status.
+If
+.I command
+is terminated by a signal,
+.B strace
+terminates itself with the same signal, so that
+.B strace
+can be used as a wrapper process transparent to the invoking parent process.
+Note that parent-child relationship (signal stop notifications,
+getppid() value, etc) between traced process and its parent are not preserved
+unless
+.B \-D
+is used.
+.LP
+When using
+.BR \-p ,
+the exit status of
+.B strace
+is zero unless there was an unexpected error in doing the tracing.
+.SH "SETUID INSTALLATION"
+If
+.B strace
+is installed setuid to root then the invoking user will be able to
+attach to and trace processes owned by any user.
+In addition setuid and setgid programs will be executed and traced
+with the correct effective privileges.
+Since only users trusted with full root privileges should be allowed
+to do these things,
+it only makes sense to install
+.B strace
+as setuid to root when the users who can execute it are restricted
+to those users who have this trust.
+For example, it makes sense to install a special version of
+.B strace
+with mode 'rwsr-xr--', user
+.B root
+and group
+.BR trace ,
+where members of the
+.B trace
+group are trusted users.
+If you do use this feature, please remember to install
+a non-setuid version of
+.B strace
+for ordinary lusers to use.
+.SH "SEE ALSO"
+.BR ltrace (1),
+.BR time (1),
+.BR ptrace (2),
+.BR proc (5)
+.SH NOTES
+It is a pity that so much tracing clutter is produced by systems
+employing shared libraries.
+.LP
+It is instructive to think about system call inputs and outputs
+as data-flow across the user/kernel boundary.  Because user-space
+and kernel-space are separate and address-protected, it is
+sometimes possible to make deductive inferences about process
+behavior using inputs and outputs as propositions.
+.LP
+In some cases, a system call will differ from the documented behavior
+or have a different name.  For example, on System V-derived systems
+the true
+.BR time (2)
+system call does not take an argument and the
+.B stat
+function is called
+.B xstat
+and takes an extra leading argument.  These
+discrepancies are normal but idiosyncratic characteristics of the
+system call interface and are accounted for by C library wrapper
+functions.
+.LP
+Some system calls have different names in different architectures and
+personalities.  In these cases, system call filtering and printing
+uses the names that match corresponding
+.BR __NR_ *
+kernel macros of the tracee's architecture and personality.
+There are two exceptions from this general rule:
+.BR arm_fadvise64_64 (2)
+ARM syscall and
+.BR xtensa_fadvise64_64 (2)
+Xtensa syscall are filtered and printed as
+.BR fadvise64_64 (2).
+.LP
+On some platforms a process that is attached to with the
+.B \-p
+option may observe a spurious EINTR return from the current
+system call that is not restartable.  (Ideally, all system calls
+should be restarted on strace attach, making the attach invisible
+to the traced process, but a few system calls aren't.
+Arguably, every instance of such behavior is a kernel bug.)
+This may have an unpredictable effect on the process
+if the process takes no action to restart the system call.
+.SH BUGS
+Programs that use the
+.I setuid
+bit do not have
+effective user
+.SM ID
+privileges while being traced.
+.LP
+A traced process runs slowly.
+.LP
+Traced processes which are descended from
+.I command
+may be left running after an interrupt signal (\c
+.SM CTRL\s0-C).
+.LP
+The
+.B \-i
+option is weakly supported.
+.SH HISTORY
+The original
+.B strace
+was written by Paul Kranenburg
+for SunOS and was inspired by its trace utility.
+The SunOS version of
+.B strace
+was ported to Linux and enhanced
+by Branko Lankester, who also wrote the Linux kernel support.
+Even though Paul released
+.B strace
+2.5 in 1992,
+Branko's work was based on Paul's
+.B strace
+1.5 release from 1991.
+In 1993, Rick Sladkey merged
+.B strace
+2.5 for SunOS and the second release of
+.B strace
+for Linux, added many of the features of
+.BR truss (1)
+from SVR4, and produced an
+.B strace
+that worked on both platforms.  In 1994 Rick ported
+.B strace
+to SVR4 and Solaris and wrote the
+automatic configuration support.  In 1995 he ported
+.B strace
+to Irix
+and tired of writing about himself in the third person.
+.SH PROBLEMS
+Problems with
+.B strace
+should be reported to the
+.B strace
+mailing list at <strace\-devel@lists.sourceforge.net>.
diff --git a/strace/strace.c b/strace/strace.c
new file mode 100644
index 0000000..ab4867f
--- /dev/null
+++ b/strace/strace.c
@@ -0,0 +1,2418 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * 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 <stdarg.h>
+#include <sys/param.h>
+#include <fcntl.h>
+#include <signal.h>
+#include <sys/resource.h>
+#include <sys/wait.h>
+#include <sys/stat.h>
+#include <pwd.h>
+#include <grp.h>
+#include <dirent.h>
+#include <sys/utsname.h>
+#ifdef HAVE_PRCTL
+# include <sys/prctl.h>
+#endif
+
+#include "ptrace.h"
+#include "printsiginfo.h"
+
+/* In some libc, these aren't declared. Do it ourself: */
+extern char **environ;
+extern int optind;
+extern char *optarg;
+
+#ifdef USE_LIBUNWIND
+/* if this is true do the stack trace for every system call */
+bool stack_trace_enabled = false;
+#endif
+
+#if defined __NR_tkill
+# define my_tkill(tid, sig) syscall(__NR_tkill, (tid), (sig))
+#else
+   /* kill() may choose arbitrarily the target task of the process group
+      while we later wait on a that specific TID.  PID process waits become
+      TID task specific waits for a process under ptrace(2).  */
+# warning "tkill(2) not available, risk of strace hangs!"
+# define my_tkill(tid, sig) kill((tid), (sig))
+#endif
+
+/* Glue for systems without a MMU that cannot provide fork() */
+#if !defined(HAVE_FORK)
+# undef NOMMU_SYSTEM
+# define NOMMU_SYSTEM 1
+#endif
+#if NOMMU_SYSTEM
+# define fork() vfork()
+#endif
+
+const unsigned int syscall_trap_sig = SIGTRAP | 0x80;
+
+cflag_t cflag = CFLAG_NONE;
+unsigned int followfork = 0;
+unsigned int ptrace_setoptions = PTRACE_O_TRACESYSGOOD | PTRACE_O_TRACEEXEC;
+unsigned int xflag = 0;
+bool debug_flag = 0;
+bool Tflag = 0;
+bool iflag = 0;
+bool count_wallclock = 0;
+unsigned int qflag = 0;
+static unsigned int tflag = 0;
+static bool rflag = 0;
+static bool print_pid_pfx = 0;
+
+/* -I n */
+enum {
+    INTR_NOT_SET        = 0,
+    INTR_ANYWHERE       = 1, /* don't block/ignore any signals */
+    INTR_WHILE_WAIT     = 2, /* block fatal signals while decoding syscall. default */
+    INTR_NEVER          = 3, /* block fatal signals. default if '-o FILE PROG' */
+    INTR_BLOCK_TSTP_TOO = 4, /* block fatal signals and SIGTSTP (^Z) */
+    NUM_INTR_OPTS
+};
+static int opt_intr;
+/* We play with signal mask only if this mode is active: */
+#define interactive (opt_intr == INTR_WHILE_WAIT)
+
+/*
+ * daemonized_tracer supports -D option.
+ * With this option, strace forks twice.
+ * Unlike normal case, with -D *grandparent* process exec's,
+ * becoming a traced process. Child exits (this prevents traced process
+ * from having children it doesn't expect to have), and grandchild
+ * attaches to grandparent similarly to strace -p PID.
+ * This allows for more transparent interaction in cases
+ * when process and its parent are communicating via signals,
+ * wait() etc. Without -D, strace process gets lodged in between,
+ * disrupting parent<->child link.
+ */
+static bool daemonized_tracer = 0;
+
+#if USE_SEIZE
+static int post_attach_sigstop = TCB_IGNORE_ONE_SIGSTOP;
+# define use_seize (post_attach_sigstop == 0)
+#else
+# define post_attach_sigstop TCB_IGNORE_ONE_SIGSTOP
+# define use_seize 0
+#endif
+
+/* Sometimes we want to print only succeeding syscalls. */
+bool not_failing_only = 0;
+
+/* Show path associated with fd arguments */
+unsigned int show_fd_path = 0;
+
+static bool detach_on_execve = 0;
+/* Are we "strace PROG" and need to skip detach on first execve? */
+static bool skip_one_b_execve = 0;
+/* Are we "strace PROG" and need to hide everything until execve? */
+bool hide_log_until_execve = 0;
+
+static int exit_code = 0;
+static int strace_child = 0;
+static int strace_tracer_pid = 0;
+
+static char *username = NULL;
+static uid_t run_uid;
+static gid_t run_gid;
+
+unsigned int max_strlen = DEFAULT_STRLEN;
+static int acolumn = DEFAULT_ACOLUMN;
+static char *acolumn_spaces;
+
+static char *outfname = NULL;
+/* If -ff, points to stderr. Else, it's our common output log */
+static FILE *shared_log;
+
+struct tcb *printing_tcp = NULL;
+static struct tcb *current_tcp;
+
+static struct tcb **tcbtab;
+static unsigned int nprocs, tcbtabsize;
+static const char *progname;
+
+unsigned os_release; /* generated from uname()'s u.release */
+
+static void detach(struct tcb *tcp);
+static void cleanup(void);
+static void interrupt(int sig);
+static sigset_t empty_set, blocked_set;
+
+#ifdef HAVE_SIG_ATOMIC_T
+static volatile sig_atomic_t interrupted;
+#else
+static volatile int interrupted;
+#endif
+
+#ifndef HAVE_STRERROR
+
+#if !HAVE_DECL_SYS_ERRLIST
+extern int sys_nerr;
+extern char *sys_errlist[];
+#endif
+
+const char *
+strerror(int err_no)
+{
+	static char buf[sizeof("Unknown error %d") + sizeof(int)*3];
+
+	if (err_no < 1 || err_no >= sys_nerr) {
+		sprintf(buf, "Unknown error %d", err_no);
+		return buf;
+	}
+	return sys_errlist[err_no];
+}
+
+#endif /* HAVE_STERRROR */
+
+static void
+usage(void)
+{
+	printf("\
+usage: strace [-CdffhiqrtttTvVwxxy] [-I n] [-e expr]...\n\
+              [-a column] [-o file] [-s strsize] [-P path]...\n\
+              -p pid... / [-D] [-E var=val]... [-u username] PROG [ARGS]\n\
+   or: strace -c[dfw] [-I n] [-e expr]... [-O overhead] [-S sortby]\n\
+              -p pid... / [-D] [-E var=val]... [-u username] PROG [ARGS]\n\
+\n\
+Output format:\n\
+  -a column      alignment COLUMN for printing syscall results (default %d)\n\
+  -i             print instruction pointer at time of syscall\n\
+  -o file        send trace output to FILE instead of stderr\n\
+  -q             suppress messages about attaching, detaching, etc.\n\
+  -r             print relative timestamp\n\
+  -s strsize     limit length of print strings to STRSIZE chars (default %d)\n\
+  -t             print absolute timestamp\n\
+  -tt            print absolute timestamp with usecs\n\
+  -T             print time spent in each syscall\n\
+  -x             print non-ascii strings in hex\n\
+  -xx            print all strings in hex\n\
+  -y             print paths associated with file descriptor arguments\n\
+  -yy            print protocol specific information associated with socket file descriptors\n\
+\n\
+Statistics:\n\
+  -c             count time, calls, and errors for each syscall and report summary\n\
+  -C             like -c but also print regular output\n\
+  -O overhead    set overhead for tracing syscalls to OVERHEAD usecs\n\
+  -S sortby      sort syscall counts by: time, calls, name, nothing (default %s)\n\
+  -w             summarise syscall latency (default is system time)\n\
+\n\
+Filtering:\n\
+  -e expr        a qualifying expression: option=[!]all or option=[!]val1[,val2]...\n\
+     options:    trace, abbrev, verbose, raw, signal, read, write\n\
+  -P path        trace accesses to path\n\
+\n\
+Tracing:\n\
+  -b execve      detach on execve syscall\n\
+  -D             run tracer process as a detached grandchild, not as parent\n\
+  -f             follow forks\n\
+  -ff            follow forks with output into separate files\n\
+  -I interruptible\n\
+     1:          no signals are blocked\n\
+     2:          fatal signals are blocked while decoding syscall (default)\n\
+     3:          fatal signals are always blocked (default if '-o FILE PROG')\n\
+     4:          fatal signals and SIGTSTP (^Z) are always blocked\n\
+                 (useful to make 'strace -o FILE PROG' not stop on ^Z)\n\
+\n\
+Startup:\n\
+  -E var         remove var from the environment for command\n\
+  -E var=val     put var=val in the environment for command\n\
+  -p pid         trace process with process id PID, may be repeated\n\
+  -u username    run command as username handling setuid and/or setgid\n\
+\n\
+Miscellaneous:\n\
+  -d             enable debug output to stderr\n\
+  -v             verbose mode: print unabbreviated argv, stat, termios, etc. args\n\
+  -h             print help message\n\
+  -V             print version\n\
+"
+#ifdef USE_LIBUNWIND
+"  -k             obtain stack trace between each syscall (experimental)\n\
+"
+#endif
+/* ancient, no one should use it
+-F -- attempt to follow vforks (deprecated, use -f)\n\
+ */
+/* this is broken, so don't document it
+-z -- print only succeeding syscalls\n\
+ */
+, DEFAULT_ACOLUMN, DEFAULT_STRLEN, DEFAULT_SORTBY);
+	exit(0);
+}
+
+static void ATTRIBUTE_NORETURN
+die(void)
+{
+	if (strace_tracer_pid == getpid()) {
+		cflag = 0;
+		cleanup();
+	}
+	exit(1);
+}
+
+static void verror_msg(int err_no, const char *fmt, va_list p)
+{
+	char *msg;
+
+	fflush(NULL);
+
+	/* We want to print entire message with single fprintf to ensure
+	 * message integrity if stderr is shared with other programs.
+	 * Thus we use vasprintf + single fprintf.
+	 */
+	msg = NULL;
+	if (vasprintf(&msg, fmt, p) >= 0) {
+		if (err_no)
+			fprintf(stderr, "%s: %s: %s\n", progname, msg, strerror(err_no));
+		else
+			fprintf(stderr, "%s: %s\n", progname, msg);
+		free(msg);
+	} else {
+		/* malloc in vasprintf failed, try it without malloc */
+		fprintf(stderr, "%s: ", progname);
+		vfprintf(stderr, fmt, p);
+		if (err_no)
+			fprintf(stderr, ": %s\n", strerror(err_no));
+		else
+			putc('\n', stderr);
+	}
+	/* We don't switch stderr to buffered, thus fprintf(stderr)
+	 * always flushes its output and this is not necessary: */
+	/* fflush(stderr); */
+}
+
+void error_msg(const char *fmt, ...)
+{
+	va_list p;
+	va_start(p, fmt);
+	verror_msg(0, fmt, p);
+	va_end(p);
+}
+
+void error_msg_and_die(const char *fmt, ...)
+{
+	va_list p;
+	va_start(p, fmt);
+	verror_msg(0, fmt, p);
+	die();
+}
+
+void error_msg_and_help(const char *fmt, ...)
+{
+	if (fmt != NULL) {
+		va_list p;
+		va_start(p, fmt);
+		verror_msg(0, fmt, p);
+	}
+	fprintf(stderr, "Try '%s -h' for more information.\n", progname);
+	die();
+}
+
+void perror_msg(const char *fmt, ...)
+{
+	va_list p;
+	va_start(p, fmt);
+	verror_msg(errno, fmt, p);
+	va_end(p);
+}
+
+void perror_msg_and_die(const char *fmt, ...)
+{
+	va_list p;
+	va_start(p, fmt);
+	verror_msg(errno, fmt, p);
+	die();
+}
+
+static void
+error_opt_arg(int opt, const char *arg)
+{
+	error_msg_and_help("invalid -%c argument: '%s'", opt, arg);
+}
+
+#if USE_SEIZE
+static int
+ptrace_attach_or_seize(int pid)
+{
+	int r;
+	if (!use_seize)
+		return ptrace(PTRACE_ATTACH, pid, 0L, 0L);
+	r = ptrace(PTRACE_SEIZE, pid, 0L, (unsigned long) ptrace_setoptions);
+	if (r)
+		return r;
+	r = ptrace(PTRACE_INTERRUPT, pid, 0L, 0L);
+	return r;
+}
+#else
+# define ptrace_attach_or_seize(pid) ptrace(PTRACE_ATTACH, (pid), 0, 0)
+#endif
+
+/*
+ * Used when we want to unblock stopped traced process.
+ * Should be only used with PTRACE_CONT, PTRACE_DETACH and PTRACE_SYSCALL.
+ * Returns 0 on success or if error was ESRCH
+ * (presumably process was killed while we talk to it).
+ * Otherwise prints error message and returns -1.
+ */
+static int
+ptrace_restart(int op, struct tcb *tcp, int sig)
+{
+	int err;
+	const char *msg;
+
+	errno = 0;
+	ptrace(op, tcp->pid, (void *) 0, (long) sig);
+	err = errno;
+	if (!err)
+		return 0;
+
+	msg = "SYSCALL";
+	if (op == PTRACE_CONT)
+		msg = "CONT";
+	if (op == PTRACE_DETACH)
+		msg = "DETACH";
+#ifdef PTRACE_LISTEN
+	if (op == PTRACE_LISTEN)
+		msg = "LISTEN";
+#endif
+	/*
+	 * Why curcol != 0? Otherwise sometimes we get this:
+	 *
+	 * 10252 kill(10253, SIGKILL)              = 0
+	 *  <ptrace(SYSCALL,10252):No such process>10253 ...next decode...
+	 *
+	 * 10252 died after we retrieved syscall exit data,
+	 * 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));
+		line_ended();
+	}
+	if (err == ESRCH)
+		return 0;
+	errno = err;
+	perror_msg("ptrace(PTRACE_%s,pid:%d,sig:%d)", msg, tcp->pid, sig);
+	return -1;
+}
+
+static void
+set_cloexec_flag(int fd)
+{
+	int flags, newflags;
+
+	flags = fcntl(fd, F_GETFD);
+	if (flags < 0) {
+		/* Can happen only if fd is bad.
+		 * Should never happen: if it does, we have a bug
+		 * in the caller. Therefore we just abort
+		 * instead of propagating the error.
+		 */
+		perror_msg_and_die("fcntl(%d, F_GETFD)", fd);
+	}
+
+	newflags = flags | FD_CLOEXEC;
+	if (flags == newflags)
+		return;
+
+	fcntl(fd, F_SETFD, newflags); /* never fails */
+}
+
+static void
+kill_save_errno(pid_t pid, int sig)
+{
+	int saved_errno = errno;
+
+	(void) kill(pid, sig);
+	errno = saved_errno;
+}
+
+/*
+ * When strace is setuid executable, we have to swap uids
+ * before and after filesystem and process management operations.
+ */
+static void
+swap_uid(void)
+{
+	int euid = geteuid(), uid = getuid();
+
+	if (euid != uid && setreuid(euid, uid) < 0) {
+		perror_msg_and_die("setreuid");
+	}
+}
+
+#ifdef _LARGEFILE64_SOURCE
+# ifdef HAVE_FOPEN64
+#  define fopen_for_output fopen64
+# else
+#  define fopen_for_output fopen
+# endif
+# define struct_stat struct stat64
+# define stat_file stat64
+# define struct_dirent struct dirent64
+# define read_dir readdir64
+# define struct_rlimit struct rlimit64
+# define set_rlimit setrlimit64
+#else
+# define fopen_for_output fopen
+# define struct_stat struct stat
+# define stat_file stat
+# define struct_dirent struct dirent
+# define read_dir readdir
+# define struct_rlimit struct rlimit
+# define set_rlimit setrlimit
+#endif
+
+static FILE *
+strace_fopen(const char *path)
+{
+	FILE *fp;
+
+	swap_uid();
+	fp = fopen_for_output(path, "w");
+	if (!fp)
+		perror_msg_and_die("Can't fopen '%s'", path);
+	swap_uid();
+	set_cloexec_flag(fileno(fp));
+	return fp;
+}
+
+static int popen_pid = 0;
+
+#ifndef _PATH_BSHELL
+# define _PATH_BSHELL "/bin/sh"
+#endif
+
+/*
+ * We cannot use standard popen(3) here because we have to distinguish
+ * popen child process from other processes we trace, and standard popen(3)
+ * does not export its child's pid.
+ */
+static FILE *
+strace_popen(const char *command)
+{
+	FILE *fp;
+	int pid;
+	int fds[2];
+
+	swap_uid();
+	if (pipe(fds) < 0)
+		perror_msg_and_die("pipe");
+
+	set_cloexec_flag(fds[1]); /* never fails */
+
+	pid = vfork();
+	if (pid < 0)
+		perror_msg_and_die("vfork");
+
+	if (pid == 0) {
+		/* child */
+		close(fds[1]);
+		if (fds[0] != 0) {
+			if (dup2(fds[0], 0))
+				perror_msg_and_die("dup2");
+			close(fds[0]);
+		}
+		execl(_PATH_BSHELL, "sh", "-c", command, NULL);
+		perror_msg_and_die("Can't execute '%s'", _PATH_BSHELL);
+	}
+
+	/* parent */
+	popen_pid = pid;
+	close(fds[0]);
+	swap_uid();
+	fp = fdopen(fds[1], "w");
+	if (!fp)
+		die_out_of_memory();
+	return fp;
+}
+
+void
+tprintf(const char *fmt, ...)
+{
+	va_list args;
+
+	va_start(args, fmt);
+	if (current_tcp) {
+		int n = strace_vfprintf(current_tcp->outf, fmt, args);
+		if (n < 0) {
+			if (current_tcp->outf != stderr)
+				perror_msg("%s", outfname);
+		} else
+			current_tcp->curcol += n;
+	}
+	va_end(args);
+}
+
+#ifndef HAVE_FPUTS_UNLOCKED
+# define fputs_unlocked fputs
+#endif
+
+void
+tprints(const char *str)
+{
+	if (current_tcp) {
+		int n = fputs_unlocked(str, current_tcp->outf);
+		if (n >= 0) {
+			current_tcp->curcol += strlen(str);
+			return;
+		}
+		if (current_tcp->outf != stderr)
+			perror_msg("%s", outfname);
+	}
+}
+
+void
+line_ended(void)
+{
+	if (current_tcp) {
+		current_tcp->curcol = 0;
+		fflush(current_tcp->outf);
+	}
+	if (printing_tcp) {
+		printing_tcp->curcol = 0;
+		printing_tcp = NULL;
+	}
+}
+
+void
+printleader(struct tcb *tcp)
+{
+	/* If -ff, "previous tcb we printed" is always the same as current,
+	 * because we have per-tcb output files.
+	 */
+	if (followfork >= 2)
+		printing_tcp = tcp;
+
+	if (printing_tcp) {
+		current_tcp = printing_tcp;
+		if (printing_tcp->curcol != 0 && (followfork < 2 || printing_tcp == tcp)) {
+			/*
+			 * case 1: we have a shared log (i.e. not -ff), and last line
+			 * wasn't finished (same or different tcb, doesn't matter).
+			 * case 2: split log, we are the same tcb, but our last line
+			 * didn't finish ("SIGKILL nuked us after syscall entry" etc).
+			 */
+			tprints(" <unfinished ...>\n");
+			printing_tcp->curcol = 0;
+		}
+	}
+
+	printing_tcp = tcp;
+	current_tcp = tcp;
+	current_tcp->curcol = 0;
+
+	if (print_pid_pfx)
+		tprintf("%-5d ", tcp->pid);
+	else if (nprocs > 1 && !outfname)
+		tprintf("[pid %5u] ", tcp->pid);
+
+	if (tflag) {
+		char str[sizeof("HH:MM:SS")];
+		struct timeval tv, dtv;
+		static struct timeval otv;
+
+		gettimeofday(&tv, NULL);
+		if (rflag) {
+			if (otv.tv_sec == 0)
+				otv = tv;
+			tv_sub(&dtv, &tv, &otv);
+			tprintf("%6ld.%06ld ",
+				(long) dtv.tv_sec, (long) dtv.tv_usec);
+			otv = tv;
+		}
+		else if (tflag > 2) {
+			tprintf("%ld.%06ld ",
+				(long) tv.tv_sec, (long) tv.tv_usec);
+		}
+		else {
+			time_t local = tv.tv_sec;
+			strftime(str, sizeof(str), "%T", localtime(&local));
+			if (tflag > 1)
+				tprintf("%s.%06ld ", str, (long) tv.tv_usec);
+			else
+				tprintf("%s ", str);
+		}
+	}
+	if (iflag)
+		print_pc(tcp);
+}
+
+void
+tabto(void)
+{
+	if (current_tcp->curcol < acolumn)
+		tprints(acolumn_spaces + current_tcp->curcol);
+}
+
+/* Should be only called directly *after successful attach* to a tracee.
+ * Otherwise, "strace -oFILE -ff -p<nonexistant_pid>"
+ * may create bogus empty FILE.<nonexistant_pid>, and then die.
+ */
+static void
+newoutf(struct tcb *tcp)
+{
+	tcp->outf = shared_log; /* if not -ff mode, the same file is for all */
+	if (followfork >= 2) {
+		char name[520 + sizeof(int) * 3];
+		sprintf(name, "%.512s.%u", outfname, tcp->pid);
+		tcp->outf = strace_fopen(name);
+	}
+}
+
+static void
+expand_tcbtab(void)
+{
+	/* Allocate some (more) TCBs (and expand the table).
+	   We don't want to relocate the TCBs because our
+	   callers have pointers and it would be a pain.
+	   So tcbtab is a table of pointers.  Since we never
+	   free the TCBs, we allocate a single chunk of many.  */
+	unsigned int new_tcbtabsize, alloc_tcbtabsize;
+	struct tcb *newtcbs;
+
+	if (tcbtabsize) {
+		alloc_tcbtabsize = tcbtabsize;
+		new_tcbtabsize = tcbtabsize * 2;
+	} else {
+		new_tcbtabsize = alloc_tcbtabsize = 1;
+	}
+
+	newtcbs = xcalloc(alloc_tcbtabsize, sizeof(newtcbs[0]));
+	tcbtab = xreallocarray(tcbtab, new_tcbtabsize, sizeof(tcbtab[0]));
+	while (tcbtabsize < new_tcbtabsize)
+		tcbtab[tcbtabsize++] = newtcbs++;
+}
+
+static struct tcb *
+alloctcb(int pid)
+{
+	unsigned int i;
+	struct tcb *tcp;
+
+	if (nprocs == tcbtabsize)
+		expand_tcbtab();
+
+	for (i = 0; i < tcbtabsize; i++) {
+		tcp = tcbtab[i];
+		if (!tcp->pid) {
+			memset(tcp, 0, sizeof(*tcp));
+			tcp->pid = pid;
+#if SUPPORTED_PERSONALITIES > 1
+			tcp->currpers = current_personality;
+#endif
+
+#ifdef USE_LIBUNWIND
+			if (stack_trace_enabled)
+				unwind_tcb_init(tcp);
+#endif
+
+			nprocs++;
+			if (debug_flag)
+				error_msg("new tcb for pid %d, active tcbs:%d",
+					  tcp->pid, nprocs);
+			return tcp;
+		}
+	}
+	error_msg_and_die("bug in alloctcb");
+}
+
+void *
+get_tcb_priv_data(const struct tcb *tcp)
+{
+	return tcp->_priv_data;
+}
+
+int
+set_tcb_priv_data(struct tcb *tcp, void *const priv_data,
+		  void (*const free_priv_data)(void *))
+{
+	if (tcp->_priv_data)
+		return -1;
+
+	tcp->_free_priv_data = free_priv_data;
+	tcp->_priv_data = priv_data;
+
+	return 0;
+}
+
+void
+free_tcb_priv_data(struct tcb *tcp)
+{
+	if (tcp->_priv_data) {
+		if (tcp->_free_priv_data) {
+			tcp->_free_priv_data(tcp->_priv_data);
+			tcp->_free_priv_data = NULL;
+		}
+		tcp->_priv_data = NULL;
+	}
+}
+
+static void
+droptcb(struct tcb *tcp)
+{
+	if (tcp->pid == 0)
+		return;
+
+	free_tcb_priv_data(tcp);
+
+#ifdef USE_LIBUNWIND
+	if (stack_trace_enabled) {
+		unwind_tcb_fin(tcp);
+	}
+#endif
+
+	nprocs--;
+	if (debug_flag)
+		error_msg("dropped tcb for pid %d, %d remain",
+			  tcp->pid, nprocs);
+
+	if (tcp->outf) {
+		if (followfork >= 2) {
+			if (tcp->curcol != 0)
+				fprintf(tcp->outf, " <detached ...>\n");
+			fclose(tcp->outf);
+		} else {
+			if (printing_tcp == tcp && tcp->curcol != 0)
+				fprintf(tcp->outf, " <detached ...>\n");
+			fflush(tcp->outf);
+		}
+	}
+
+	if (current_tcp == tcp)
+		current_tcp = NULL;
+	if (printing_tcp == tcp)
+		printing_tcp = NULL;
+
+	memset(tcp, 0, sizeof(*tcp));
+}
+
+/* Detach traced process.
+ * Never call DETACH twice on the same process as both unattached and
+ * attached-unstopped processes give the same ESRCH.  For unattached process we
+ * would SIGSTOP it and wait for its SIGSTOP notification forever.
+ */
+static void
+detach(struct tcb *tcp)
+{
+	int error;
+	int status;
+
+	/*
+	 * Linux wrongly insists the child be stopped
+	 * before detaching.  Arghh.  We go through hoops
+	 * to make a clean break of things.
+	 */
+#if defined(SPARC)
+# undef PTRACE_DETACH
+# define PTRACE_DETACH PTRACE_SUNDETACH
+#endif
+
+	if (!(tcp->flags & TCB_ATTACHED))
+		goto drop;
+
+	/* We attached but possibly didn't see the expected SIGSTOP.
+	 * We must catch exactly one as otherwise the detached process
+	 * would be left stopped (process state T).
+	 */
+	if (tcp->flags & TCB_IGNORE_ONE_SIGSTOP)
+		goto wait_loop;
+
+	error = ptrace(PTRACE_DETACH, tcp->pid, 0, 0);
+	if (!error) {
+		/* On a clear day, you can see forever. */
+		goto drop;
+	}
+	if (errno != ESRCH) {
+		/* Shouldn't happen. */
+		perror_msg("detach: ptrace(PTRACE_DETACH,%u)", tcp->pid);
+		goto drop;
+	}
+	/* ESRCH: process is either not stopped or doesn't exist. */
+	if (my_tkill(tcp->pid, 0) < 0) {
+		if (errno != ESRCH)
+			/* Shouldn't happen. */
+			perror_msg("detach: tkill(%u,0)", tcp->pid);
+		/* else: process doesn't exist. */
+		goto drop;
+	}
+	/* Process is not stopped, need to stop it. */
+	if (use_seize) {
+		/*
+		 * With SEIZE, tracee can be in group-stop already.
+		 * In this state sending it another SIGSTOP does nothing.
+		 * Need to use INTERRUPT.
+		 * Testcase: trying to ^C a "strace -p <stopped_process>".
+		 */
+		error = ptrace(PTRACE_INTERRUPT, tcp->pid, 0, 0);
+		if (!error)
+			goto wait_loop;
+		if (errno != ESRCH)
+			perror_msg("detach: ptrace(PTRACE_INTERRUPT,%u)", tcp->pid);
+	}
+	else {
+		error = my_tkill(tcp->pid, SIGSTOP);
+		if (!error)
+			goto wait_loop;
+		if (errno != ESRCH)
+			perror_msg("detach: tkill(%u,SIGSTOP)", tcp->pid);
+	}
+	/* Either process doesn't exist, or some weird error. */
+	goto drop;
+
+ wait_loop:
+	/* We end up here in three cases:
+	 * 1. We sent PTRACE_INTERRUPT (use_seize case)
+	 * 2. We sent SIGSTOP (!use_seize)
+	 * 3. Attach SIGSTOP was already pending (TCB_IGNORE_ONE_SIGSTOP set)
+	 */
+	for (;;) {
+		unsigned int sig;
+		if (waitpid(tcp->pid, &status, __WALL) < 0) {
+			if (errno == EINTR)
+				continue;
+			/*
+			 * if (errno == ECHILD) break;
+			 * ^^^  WRONG! We expect this PID to exist,
+			 * and want to emit a message otherwise:
+			 */
+			perror_msg("detach: waitpid(%u)", tcp->pid);
+			break;
+		}
+		if (!WIFSTOPPED(status)) {
+			/*
+			 * Tracee exited or was killed by signal.
+			 * We shouldn't normally reach this place:
+			 * we don't want to consume exit status.
+			 * Consider "strace -p PID" being ^C-ed:
+			 * we want merely to detach from PID.
+			 *
+			 * However, we _can_ end up here if tracee
+			 * was SIGKILLed.
+			 */
+			break;
+		}
+		sig = WSTOPSIG(status);
+		if (debug_flag)
+			error_msg("detach wait: event:%d sig:%d",
+				  (unsigned)status >> 16, sig);
+		if (use_seize) {
+			unsigned event = (unsigned)status >> 16;
+			if (event == PTRACE_EVENT_STOP /*&& sig == SIGTRAP*/) {
+				/*
+				 * sig == SIGTRAP: PTRACE_INTERRUPT stop.
+				 * sig == other: process was already stopped
+				 * with this stopping sig (see tests/detach-stopped).
+				 * Looks like re-injecting this sig is not necessary
+				 * in DETACH for the tracee to remain stopped.
+				 */
+				sig = 0;
+			}
+			/*
+			 * PTRACE_INTERRUPT is not guaranteed to produce
+			 * the above event if other ptrace-stop is pending.
+			 * See tests/detach-sleeping testcase:
+			 * strace got SIGINT while tracee is sleeping.
+			 * We sent PTRACE_INTERRUPT.
+			 * We see syscall exit, not PTRACE_INTERRUPT stop.
+			 * We won't get PTRACE_INTERRUPT stop
+			 * if we would CONT now. Need to DETACH.
+			 */
+			if (sig == syscall_trap_sig)
+				sig = 0;
+			/* else: not sure in which case we can be here.
+			 * Signal stop? Inject it while detaching.
+			 */
+			ptrace_restart(PTRACE_DETACH, tcp, sig);
+			break;
+		}
+		/* Note: this check has to be after use_seize check */
+		/* (else, in use_seize case SIGSTOP will be mistreated) */
+		if (sig == SIGSTOP) {
+			/* Detach, suppressing SIGSTOP */
+			ptrace_restart(PTRACE_DETACH, tcp, 0);
+			break;
+		}
+		if (sig == syscall_trap_sig)
+			sig = 0;
+		/* Can't detach just yet, may need to wait for SIGSTOP */
+		error = ptrace_restart(PTRACE_CONT, tcp, sig);
+		if (error < 0) {
+			/* Should not happen.
+			 * Note: ptrace_restart returns 0 on ESRCH, so it's not it.
+			 * ptrace_restart already emitted error message.
+			 */
+			break;
+		}
+	}
+
+ drop:
+	if (!qflag && (tcp->flags & TCB_ATTACHED))
+		error_msg("Process %u detached", tcp->pid);
+
+	droptcb(tcp);
+}
+
+static void
+process_opt_p_list(char *opt)
+{
+	while (*opt) {
+		/*
+		 * We accept -p PID,PID; -p "`pidof PROG`"; -p "`pgrep PROG`".
+		 * pidof uses space as delim, pgrep uses newline. :(
+		 */
+		int pid;
+		char *delim = opt + strcspn(opt, ", \n\t");
+		char c = *delim;
+
+		*delim = '\0';
+		pid = string_to_uint(opt);
+		if (pid <= 0) {
+			error_msg_and_die("Invalid process id: '%s'", opt);
+		}
+		if (pid == strace_tracer_pid) {
+			error_msg_and_die("I'm sorry, I can't let you do that, Dave.");
+		}
+		*delim = c;
+		alloctcb(pid);
+		if (c == '\0')
+			break;
+		opt = delim + 1;
+	}
+}
+
+static void
+startup_attach(void)
+{
+	pid_t parent_pid = strace_tracer_pid;
+	unsigned int tcbi;
+	struct tcb *tcp;
+
+	/*
+	 * Block user interruptions as we would leave the traced
+	 * process stopped (process state T) if we would terminate in
+	 * between PTRACE_ATTACH and wait4() on SIGSTOP.
+	 * We rely on cleanup() from this point on.
+	 */
+	if (interactive)
+		sigprocmask(SIG_BLOCK, &blocked_set, NULL);
+
+	if (daemonized_tracer) {
+		pid_t pid = fork();
+		if (pid < 0) {
+			perror_msg_and_die("fork");
+		}
+		if (pid) { /* parent */
+			/*
+			 * Wait for grandchild to attach to straced process
+			 * (grandparent). Grandchild SIGKILLs us after it attached.
+			 * Grandparent's wait() is unblocked by our death,
+			 * it proceeds to exec the straced program.
+			 */
+			pause();
+			_exit(0); /* paranoia */
+		}
+		/* grandchild */
+		/* We will be the tracer process. Remember our new pid: */
+		strace_tracer_pid = getpid();
+	}
+
+	for (tcbi = 0; tcbi < tcbtabsize; tcbi++) {
+		tcp = tcbtab[tcbi];
+
+		if (!tcp->pid)
+			continue;
+
+		/* Is this a process we should attach to, but not yet attached? */
+		if (tcp->flags & TCB_ATTACHED)
+			continue; /* no, we already attached it */
+
+		if (tcp->pid == parent_pid || tcp->pid == strace_tracer_pid) {
+			errno = EPERM;
+			perror_msg("attach: %d", tcp->pid);
+			droptcb(tcp);
+			continue;
+		}
+		if (followfork && tcp->pid != strace_child) {
+			char procdir[sizeof("/proc/%d/task") + sizeof(int) * 3];
+			DIR *dir;
+
+			sprintf(procdir, "/proc/%d/task", tcp->pid);
+			dir = opendir(procdir);
+			if (dir != NULL) {
+				unsigned int ntid = 0, nerr = 0;
+				struct_dirent *de;
+
+				while ((de = read_dir(dir)) != NULL) {
+					struct tcb *cur_tcp;
+					int tid;
+
+					if (de->d_fileno == 0)
+						continue;
+					/* we trust /proc filesystem */
+					tid = atoi(de->d_name);
+					if (tid <= 0)
+						continue;
+					++ntid;
+					if (ptrace_attach_or_seize(tid) < 0) {
+						++nerr;
+						if (debug_flag)
+							error_msg("attach to pid %d failed", tid);
+						continue;
+					}
+					if (debug_flag)
+						error_msg("attach to pid %d succeeded", tid);
+					cur_tcp = tcp;
+					if (tid != tcp->pid)
+						cur_tcp = alloctcb(tid);
+					cur_tcp->flags |= TCB_ATTACHED | TCB_STARTUP | post_attach_sigstop;
+					newoutf(cur_tcp);
+				}
+				closedir(dir);
+				if (interactive) {
+					sigprocmask(SIG_SETMASK, &empty_set, NULL);
+					if (interrupted)
+						goto ret;
+					sigprocmask(SIG_BLOCK, &blocked_set, NULL);
+				}
+				ntid -= nerr;
+				if (ntid == 0) {
+					perror_msg("attach: ptrace(PTRACE_ATTACH, ...)");
+					droptcb(tcp);
+					continue;
+				}
+				if (!qflag) {
+					if (ntid > 1)
+						error_msg("Process %u attached"
+							  " with %u threads",
+							  tcp->pid, ntid);
+					else
+						error_msg("Process %u attached",
+							  tcp->pid);
+				}
+				if (!(tcp->flags & TCB_ATTACHED)) {
+					/* -p PID, we failed to attach to PID itself
+					 * but did attach to some of its sibling threads.
+					 * Drop PID's tcp.
+					 */
+					droptcb(tcp);
+				}
+				continue;
+			} /* if (opendir worked) */
+		} /* if (-f) */
+		if (ptrace_attach_or_seize(tcp->pid) < 0) {
+			perror_msg("attach: ptrace(PTRACE_ATTACH, ...)");
+			droptcb(tcp);
+			continue;
+		}
+		tcp->flags |= TCB_ATTACHED | TCB_STARTUP | post_attach_sigstop;
+		newoutf(tcp);
+		if (debug_flag)
+			error_msg("attach to pid %d (main) succeeded", tcp->pid);
+
+		if (!qflag)
+			error_msg("Process %u attached", tcp->pid);
+	} /* for each tcbtab[] */
+
+	if (daemonized_tracer) {
+		/*
+		 * Make parent go away.
+		 * Also makes grandparent's wait() unblock.
+		 */
+		kill(parent_pid, SIGKILL);
+		strace_child = 0;
+	}
+
+ ret:
+	if (interactive)
+		sigprocmask(SIG_SETMASK, &empty_set, NULL);
+}
+
+/* Stack-o-phobic exec helper, in the hope to work around
+ * NOMMU + "daemonized tracer" difficulty.
+ */
+struct exec_params {
+	int fd_to_close;
+	uid_t run_euid;
+	gid_t run_egid;
+	char **argv;
+	char *pathname;
+};
+static struct exec_params params_for_tracee;
+
+static void ATTRIBUTE_NOINLINE ATTRIBUTE_NORETURN
+exec_or_die(void)
+{
+	struct exec_params *params = &params_for_tracee;
+
+	if (params->fd_to_close >= 0)
+		close(params->fd_to_close);
+	if (!daemonized_tracer && !use_seize) {
+		if (ptrace(PTRACE_TRACEME, 0L, 0L, 0L) < 0) {
+			perror_msg_and_die("ptrace(PTRACE_TRACEME, ...)");
+		}
+	}
+
+	if (username != NULL) {
+		/*
+		 * It is important to set groups before we
+		 * lose privileges on setuid.
+		 */
+		if (initgroups(username, run_gid) < 0) {
+			perror_msg_and_die("initgroups");
+		}
+		if (setregid(run_gid, params->run_egid) < 0) {
+			perror_msg_and_die("setregid");
+		}
+		if (setreuid(run_uid, params->run_euid) < 0) {
+			perror_msg_and_die("setreuid");
+		}
+	}
+	else if (geteuid() != 0)
+		if (setreuid(run_uid, run_uid) < 0) {
+			perror_msg_and_die("setreuid");
+		}
+
+	if (!daemonized_tracer) {
+		/*
+		 * Induce a ptrace stop. Tracer (our parent)
+		 * will resume us with PTRACE_SYSCALL and display
+		 * the immediately following execve syscall.
+		 * Can't do this on NOMMU systems, we are after
+		 * vfork: parent is blocked, stopping would deadlock.
+		 */
+		if (!NOMMU_SYSTEM)
+			kill(getpid(), SIGSTOP);
+	} else {
+		alarm(3);
+		/* we depend on SIGCHLD set to SIG_DFL by init code */
+		/* if it happens to be SIG_IGN'ed, wait won't block */
+		wait(NULL);
+		alarm(0);
+	}
+
+	execv(params->pathname, params->argv);
+	perror_msg_and_die("exec");
+}
+
+static int
+open_dummy_desc(void)
+{
+	int fds[2];
+
+	if (pipe(fds))
+		perror_msg_and_die("pipe");
+	close(fds[1]);
+	return fds[0];
+}
+
+static void
+startup_child(char **argv)
+{
+	struct_stat statbuf;
+	const char *filename;
+	size_t filename_len;
+	char pathname[PATH_MAX];
+	int pid;
+	struct tcb *tcp;
+
+	filename = argv[0];
+	filename_len = strlen(filename);
+
+	if (filename_len > sizeof(pathname) - 1) {
+		errno = ENAMETOOLONG;
+		perror_msg_and_die("exec");
+	}
+	if (strchr(filename, '/')) {
+		strcpy(pathname, filename);
+	}
+#ifdef USE_DEBUGGING_EXEC
+	/*
+	 * Debuggers customarily check the current directory
+	 * first regardless of the path but doing that gives
+	 * security geeks a panic attack.
+	 */
+	else if (stat_file(filename, &statbuf) == 0)
+		strcpy(pathname, filename);
+#endif /* USE_DEBUGGING_EXEC */
+	else {
+		const char *path;
+		size_t m, n, len;
+
+		for (path = getenv("PATH"); path && *path; path += m) {
+			const char *colon = strchr(path, ':');
+			if (colon) {
+				n = colon - path;
+				m = n + 1;
+			}
+			else
+				m = n = strlen(path);
+			if (n == 0) {
+				if (!getcwd(pathname, PATH_MAX))
+					continue;
+				len = strlen(pathname);
+			}
+			else if (n > sizeof pathname - 1)
+				continue;
+			else {
+				strncpy(pathname, path, n);
+				len = n;
+			}
+			if (len && pathname[len - 1] != '/')
+				pathname[len++] = '/';
+			if (filename_len + len > sizeof(pathname) - 1)
+				continue;
+			strcpy(pathname + len, filename);
+			if (stat_file(pathname, &statbuf) == 0 &&
+			    /* Accept only regular files
+			       with some execute bits set.
+			       XXX not perfect, might still fail */
+			    S_ISREG(statbuf.st_mode) &&
+			    (statbuf.st_mode & 0111))
+				break;
+		}
+		if (!path || !*path)
+			pathname[0] = '\0';
+	}
+	if (stat_file(pathname, &statbuf) < 0) {
+		perror_msg_and_die("Can't stat '%s'", filename);
+	}
+
+	params_for_tracee.fd_to_close = (shared_log != stderr) ? fileno(shared_log) : -1;
+	params_for_tracee.run_euid = (statbuf.st_mode & S_ISUID) ? statbuf.st_uid : run_uid;
+	params_for_tracee.run_egid = (statbuf.st_mode & S_ISGID) ? statbuf.st_gid : run_gid;
+	params_for_tracee.argv = argv;
+	/*
+	 * On NOMMU, can be safely freed only after execve in tracee.
+	 * It's hard to know when that happens, so we just leak it.
+	 */
+	params_for_tracee.pathname = NOMMU_SYSTEM ? xstrdup(pathname) : pathname;
+
+#if defined HAVE_PRCTL && defined PR_SET_PTRACER && defined PR_SET_PTRACER_ANY
+	if (daemonized_tracer)
+		prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY);
+#endif
+
+	pid = fork();
+	if (pid < 0) {
+		perror_msg_and_die("fork");
+	}
+	if ((pid != 0 && daemonized_tracer)
+	 || (pid == 0 && !daemonized_tracer)
+	) {
+		/* We are to become the tracee. Two cases:
+		 * -D: we are parent
+		 * not -D: we are child
+		 */
+		exec_or_die();
+	}
+
+	/* We are the tracer */
+
+	if (!daemonized_tracer) {
+		strace_child = pid;
+		if (!use_seize) {
+			/* child did PTRACE_TRACEME, nothing to do in parent */
+		} else {
+			if (!NOMMU_SYSTEM) {
+				/* Wait until child stopped itself */
+				int status;
+				while (waitpid(pid, &status, WSTOPPED) < 0) {
+					if (errno == EINTR)
+						continue;
+					perror_msg_and_die("waitpid");
+				}
+				if (!WIFSTOPPED(status) || WSTOPSIG(status) != SIGSTOP) {
+					kill_save_errno(pid, SIGKILL);
+					perror_msg_and_die("Unexpected wait status %x", status);
+				}
+			}
+			/* Else: NOMMU case, we have no way to sync.
+			 * Just attach to it as soon as possible.
+			 * This means that we may miss a few first syscalls...
+			 */
+
+			if (ptrace_attach_or_seize(pid)) {
+				kill_save_errno(pid, SIGKILL);
+				perror_msg_and_die("Can't attach to %d", pid);
+			}
+			if (!NOMMU_SYSTEM)
+				kill(pid, SIGCONT);
+		}
+		tcp = alloctcb(pid);
+		if (!NOMMU_SYSTEM)
+			tcp->flags |= TCB_ATTACHED | TCB_STARTUP | post_attach_sigstop;
+		else
+			tcp->flags |= TCB_ATTACHED | TCB_STARTUP;
+		newoutf(tcp);
+	}
+	else {
+		/* With -D, we are *child* here, the tracee is our parent. */
+		strace_child = strace_tracer_pid;
+		strace_tracer_pid = getpid();
+		alloctcb(strace_child);
+		/* attaching will be done later, by startup_attach */
+		/* note: we don't do newoutf(tcp) here either! */
+
+		/* NOMMU BUG! -D mode is active, we (child) return,
+		 * and we will scribble over parent's stack!
+		 * When parent later unpauses, it segfaults.
+		 *
+		 * We work around it
+		 * (1) by declaring exec_or_die() NORETURN,
+		 * hopefully compiler will just jump to it
+		 * instead of call (won't push anything to stack),
+		 * (2) by trying very hard in exec_or_die()
+		 * to not use any stack,
+		 * (3) having a really big (PATH_MAX) stack object
+		 * in this function, which creates a "buffer" between
+		 * child's and parent's stack pointers.
+		 * This may save us if (1) and (2) failed
+		 * and compiler decided to use stack in exec_or_die() anyway
+		 * (happens on i386 because of stack parameter passing).
+		 *
+		 * A cleaner solution is to use makecontext + setcontext
+		 * to create a genuine separate stack and execute on it.
+		 */
+	}
+	/*
+	 * A case where straced process is part of a pipe:
+	 * { sleep 1; yes | head -n99999; } | strace -o/dev/null sh -c 'exec <&-; sleep 9'
+	 * If strace won't close its fd#0, closing it in tracee is not enough:
+	 * the pipe is still open, it has a reader. Thus, "head" will not get its
+	 * SIGPIPE at once, on the first write.
+	 *
+	 * Preventing it by closing strace's stdin/out.
+	 * (Don't leave fds 0 and 1 closed, this is bad practice: future opens
+	 * will reuse them, unexpectedly making a newly opened object "stdin").
+	 */
+	close(0);
+	open_dummy_desc(); /* opens to fd#0 */
+	dup2(0, 1);
+#if 0
+	/* A good idea too, but we sometimes need to print error messages */
+	if (shared_log != stderr)
+		dup2(0, 2);
+#endif
+}
+
+#if USE_SEIZE
+static void
+test_ptrace_seize(void)
+{
+	int pid;
+
+	/* Need fork for test. NOMMU has no forks */
+	if (NOMMU_SYSTEM) {
+		post_attach_sigstop = 0; /* this sets use_seize to 1 */
+		return;
+	}
+
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_die("fork");
+
+	if (pid == 0) {
+		pause();
+		_exit(0);
+	}
+
+	/* PTRACE_SEIZE, unlike ATTACH, doesn't force tracee to trap.  After
+	 * attaching tracee continues to run unless a trap condition occurs.
+	 * PTRACE_SEIZE doesn't affect signal or group stop state.
+	 */
+	if (ptrace(PTRACE_SEIZE, pid, 0, 0) == 0) {
+		post_attach_sigstop = 0; /* this sets use_seize to 1 */
+	} else if (debug_flag) {
+		error_msg("PTRACE_SEIZE doesn't work");
+	}
+
+	kill(pid, SIGKILL);
+
+	while (1) {
+		int status, tracee_pid;
+
+		errno = 0;
+		tracee_pid = waitpid(pid, &status, 0);
+		if (tracee_pid <= 0) {
+			if (errno == EINTR)
+				continue;
+			perror_msg_and_die("%s: unexpected wait result %d",
+					 __func__, tracee_pid);
+		}
+		if (WIFSIGNALED(status)) {
+			return;
+		}
+		error_msg_and_die("%s: unexpected wait status %x",
+				__func__, status);
+	}
+}
+#else /* !USE_SEIZE */
+# define test_ptrace_seize() ((void)0)
+#endif
+
+static unsigned
+get_os_release(void)
+{
+	unsigned rel;
+	const char *p;
+	struct utsname u;
+	if (uname(&u) < 0)
+		perror_msg_and_die("uname");
+	/* u.release has this form: "3.2.9[-some-garbage]" */
+	rel = 0;
+	p = u.release;
+	for (;;) {
+		if (!(*p >= '0' && *p <= '9'))
+			error_msg_and_die("Bad OS release string: '%s'", u.release);
+		/* Note: this open-codes KERNEL_VERSION(): */
+		rel = (rel << 8) | atoi(p);
+		if (rel >= KERNEL_VERSION(1,0,0))
+			break;
+		while (*p >= '0' && *p <= '9')
+			p++;
+		if (*p != '.') {
+			if (rel >= KERNEL_VERSION(0,1,0)) {
+				/* "X.Y-something" means "X.Y.0" */
+				rel <<= 8;
+				break;
+			}
+			error_msg_and_die("Bad OS release string: '%s'", u.release);
+		}
+		p++;
+	}
+	return rel;
+}
+
+/*
+ * Initialization part of main() was eating much stack (~0.5k),
+ * which was unused after init.
+ * We can reuse it if we move init code into a separate function.
+ *
+ * Don't want main() to inline us and defeat the reason
+ * we have a separate function.
+ */
+static void ATTRIBUTE_NOINLINE
+init(int argc, char *argv[])
+{
+	int c, i;
+	int optF = 0;
+	struct sigaction sa;
+
+	progname = argv[0] ? argv[0] : "strace";
+
+	/* Make sure SIGCHLD has the default action so that waitpid
+	   definitely works without losing track of children.  The user
+	   should not have given us a bogus state to inherit, but he might
+	   have.  Arguably we should detect SIG_IGN here and pass it on
+	   to children, but probably noone really needs that.  */
+	signal(SIGCHLD, SIG_DFL);
+
+	strace_tracer_pid = getpid();
+
+	os_release = get_os_release();
+
+	shared_log = stderr;
+	set_sortby(DEFAULT_SORTBY);
+	set_personality(DEFAULT_PERSONALITY);
+	qualify("trace=all");
+	qualify("abbrev=all");
+	qualify("verbose=all");
+#if DEFAULT_QUAL_FLAGS != (QUAL_TRACE | QUAL_ABBREV | QUAL_VERBOSE)
+# error Bug in DEFAULT_QUAL_FLAGS
+#endif
+	qualify("signal=all");
+	while ((c = getopt(argc, argv,
+		"+b:cCdfFhiqrtTvVwxyz"
+#ifdef USE_LIBUNWIND
+		"k"
+#endif
+		"D"
+		"a:e:o:O:p:s:S:u:E:P:I:")) != EOF) {
+		switch (c) {
+		case 'b':
+			if (strcmp(optarg, "execve") != 0)
+				error_msg_and_die("Syscall '%s' for -b isn't supported",
+					optarg);
+			detach_on_execve = 1;
+			break;
+		case 'c':
+			if (cflag == CFLAG_BOTH) {
+				error_msg_and_help("-c and -C are mutually exclusive");
+			}
+			cflag = CFLAG_ONLY_STATS;
+			break;
+		case 'C':
+			if (cflag == CFLAG_ONLY_STATS) {
+				error_msg_and_help("-c and -C are mutually exclusive");
+			}
+			cflag = CFLAG_BOTH;
+			break;
+		case 'd':
+			debug_flag = 1;
+			break;
+		case 'D':
+			daemonized_tracer = 1;
+			break;
+		case 'F':
+			optF = 1;
+			break;
+		case 'f':
+			followfork++;
+			break;
+		case 'h':
+			usage();
+			break;
+		case 'i':
+			iflag = 1;
+			break;
+		case 'q':
+			qflag++;
+			break;
+		case 'r':
+			rflag = 1;
+			/* fall through to tflag++ */
+		case 't':
+			tflag++;
+			break;
+		case 'T':
+			Tflag = 1;
+			break;
+		case 'w':
+			count_wallclock = 1;
+			break;
+		case 'x':
+			xflag++;
+			break;
+		case 'y':
+			show_fd_path++;
+			break;
+		case 'v':
+			qualify("abbrev=none");
+			break;
+		case 'V':
+			printf("%s -- version %s\n", PACKAGE_NAME, VERSION);
+			exit(0);
+			break;
+		case 'z':
+			not_failing_only = 1;
+			break;
+		case 'a':
+			acolumn = string_to_uint(optarg);
+			if (acolumn < 0)
+				error_opt_arg(c, optarg);
+			break;
+		case 'e':
+			qualify(optarg);
+			break;
+		case 'o':
+			outfname = xstrdup(optarg);
+			break;
+		case 'O':
+			i = string_to_uint(optarg);
+			if (i < 0)
+				error_opt_arg(c, optarg);
+			set_overhead(i);
+			break;
+		case 'p':
+			process_opt_p_list(optarg);
+			break;
+		case 'P':
+			pathtrace_select(optarg);
+			break;
+		case 's':
+			i = string_to_uint(optarg);
+			if (i < 0)
+				error_opt_arg(c, optarg);
+			max_strlen = i;
+			break;
+		case 'S':
+			set_sortby(optarg);
+			break;
+		case 'u':
+			username = xstrdup(optarg);
+			break;
+#ifdef USE_LIBUNWIND
+		case 'k':
+			stack_trace_enabled = true;
+			break;
+#endif
+		case 'E':
+			if (putenv(optarg) < 0)
+				die_out_of_memory();
+			break;
+		case 'I':
+			opt_intr = string_to_uint(optarg);
+			if (opt_intr <= 0 || opt_intr >= NUM_INTR_OPTS)
+				error_opt_arg(c, optarg);
+			break;
+		default:
+			error_msg_and_help(NULL);
+			break;
+		}
+	}
+	argv += optind;
+	/* argc -= optind; - no need, argc is not used below */
+
+	acolumn_spaces = xmalloc(acolumn + 1);
+	memset(acolumn_spaces, ' ', acolumn);
+	acolumn_spaces[acolumn] = '\0';
+
+	if (!argv[0] && !nprocs) {
+		error_msg_and_help("must have PROG [ARGS] or -p PID");
+	}
+
+	if (!argv[0] && daemonized_tracer) {
+		error_msg_and_help("PROG [ARGS] must be specified with -D");
+	}
+
+	if (!followfork)
+		followfork = optF;
+
+	if (followfork >= 2 && cflag) {
+		error_msg_and_help("(-c or -C) and -ff are mutually exclusive");
+	}
+
+	if (count_wallclock && !cflag) {
+		error_msg_and_help("-w must be given with (-c or -C)");
+	}
+
+	if (cflag == CFLAG_ONLY_STATS) {
+		if (iflag)
+			error_msg("-%c has no effect with -c", 'i');
+#ifdef USE_LIBUNWIND
+		if (stack_trace_enabled)
+			error_msg("-%c has no effect with -c", 'k');
+#endif
+		if (rflag)
+			error_msg("-%c has no effect with -c", 'r');
+		if (tflag)
+			error_msg("-%c has no effect with -c", 't');
+		if (Tflag)
+			error_msg("-%c has no effect with -c", 'T');
+		if (show_fd_path)
+			error_msg("-%c has no effect with -c", 'y');
+	}
+
+#ifdef USE_LIBUNWIND
+	if (stack_trace_enabled)
+		unwind_init();
+#endif
+
+	/* See if they want to run as another user. */
+	if (username != NULL) {
+		struct passwd *pent;
+
+		if (getuid() != 0 || geteuid() != 0) {
+			error_msg_and_die("You must be root to use the -u option");
+		}
+		pent = getpwnam(username);
+		if (pent == NULL) {
+			error_msg_and_die("Cannot find user '%s'", username);
+		}
+		run_uid = pent->pw_uid;
+		run_gid = pent->pw_gid;
+	}
+	else {
+		run_uid = getuid();
+		run_gid = getgid();
+	}
+
+	if (followfork)
+		ptrace_setoptions |= PTRACE_O_TRACECLONE |
+				     PTRACE_O_TRACEFORK |
+				     PTRACE_O_TRACEVFORK;
+	if (debug_flag)
+		error_msg("ptrace_setoptions = %#x", ptrace_setoptions);
+	test_ptrace_seize();
+
+	if (fcntl(0, F_GETFD) == -1 || fcntl(1, F_GETFD) == -1) {
+		/*
+		 * Something weird with our stdin and/or stdout -
+		 * for example, may be not open? In this case,
+		 * ensure that none of the future opens uses them.
+		 *
+		 * This was seen in the wild when /proc/sys/kernel/core_pattern
+		 * was set to "|/bin/strace -o/tmp/LOG PROG":
+		 * kernel runs coredump helper with fd#0 open but fd#1 closed (!),
+		 * therefore LOG gets opened to fd#1, and fd#1 is closed by
+		 * "don't hold up stdin/out open" code soon after.
+		 */
+		int fd = open_dummy_desc();
+		while (fd >= 0 && fd < 2)
+			fd = dup(fd);
+		if (fd > 2)
+			close(fd);
+	}
+
+	/* Check if they want to redirect the output. */
+	if (outfname) {
+		/* See if they want to pipe the output. */
+		if (outfname[0] == '|' || outfname[0] == '!') {
+			/*
+			 * We can't do the <outfname>.PID funny business
+			 * when using popen, so prohibit it.
+			 */
+			if (followfork >= 2)
+				error_msg_and_help("piping the output and -ff are mutually exclusive");
+			shared_log = strace_popen(outfname + 1);
+		}
+		else if (followfork < 2)
+			shared_log = strace_fopen(outfname);
+	} else {
+		/* -ff without -o FILE is the same as single -f */
+		if (followfork >= 2)
+			followfork = 1;
+	}
+
+	if (!outfname || outfname[0] == '|' || outfname[0] == '!') {
+		char *buf = xmalloc(BUFSIZ);
+		setvbuf(shared_log, buf, _IOLBF, BUFSIZ);
+	}
+	if (outfname && argv[0]) {
+		if (!opt_intr)
+			opt_intr = INTR_NEVER;
+		if (!qflag)
+			qflag = 1;
+	}
+	if (!opt_intr)
+		opt_intr = INTR_WHILE_WAIT;
+
+	/* argv[0]	-pPID	-oFILE	Default interactive setting
+	 * yes		*	0	INTR_WHILE_WAIT
+	 * no		1	0	INTR_WHILE_WAIT
+	 * yes		*	1	INTR_NEVER
+	 * no		1	1	INTR_WHILE_WAIT
+	 */
+
+	sigemptyset(&empty_set);
+	sigemptyset(&blocked_set);
+
+	/* startup_child() must be called before the signal handlers get
+	 * installed below as they are inherited into the spawned process.
+	 * Also we do not need to be protected by them as during interruption
+	 * in the startup_child() mode we kill the spawned process anyway.
+	 */
+	if (argv[0]) {
+		if (!NOMMU_SYSTEM || daemonized_tracer)
+			hide_log_until_execve = 1;
+		skip_one_b_execve = 1;
+		startup_child(argv);
+	}
+
+	sa.sa_handler = SIG_IGN;
+	sigemptyset(&sa.sa_mask);
+	sa.sa_flags = 0;
+	sigaction(SIGTTOU, &sa, NULL); /* SIG_IGN */
+	sigaction(SIGTTIN, &sa, NULL); /* SIG_IGN */
+	if (opt_intr != INTR_ANYWHERE) {
+		if (opt_intr == INTR_BLOCK_TSTP_TOO)
+			sigaction(SIGTSTP, &sa, NULL); /* SIG_IGN */
+		/*
+		 * In interactive mode (if no -o OUTFILE, or -p PID is used),
+		 * fatal signals are blocked while syscall stop is processed,
+		 * and acted on in between, when waiting for new syscall stops.
+		 * In non-interactive mode, signals are ignored.
+		 */
+		if (opt_intr == INTR_WHILE_WAIT) {
+			sigaddset(&blocked_set, SIGHUP);
+			sigaddset(&blocked_set, SIGINT);
+			sigaddset(&blocked_set, SIGQUIT);
+			sigaddset(&blocked_set, SIGPIPE);
+			sigaddset(&blocked_set, SIGTERM);
+			sa.sa_handler = interrupt;
+		}
+		/* SIG_IGN, or set handler for these */
+		sigaction(SIGHUP, &sa, NULL);
+		sigaction(SIGINT, &sa, NULL);
+		sigaction(SIGQUIT, &sa, NULL);
+		sigaction(SIGPIPE, &sa, NULL);
+		sigaction(SIGTERM, &sa, NULL);
+	}
+	if (nprocs != 0 || daemonized_tracer)
+		startup_attach();
+
+	/* Do we want pids printed in our -o OUTFILE?
+	 * -ff: no (every pid has its own file); or
+	 * -f: yes (there can be more pids in the future); or
+	 * -p PID1,PID2: yes (there are already more than one pid)
+	 */
+	print_pid_pfx = (outfname && followfork < 2 && (followfork == 1 || nprocs > 1));
+}
+
+static struct tcb *
+pid2tcb(int pid)
+{
+	unsigned int i;
+
+	if (pid <= 0)
+		return NULL;
+
+	for (i = 0; i < tcbtabsize; i++) {
+		struct tcb *tcp = tcbtab[i];
+		if (tcp->pid == pid)
+			return tcp;
+	}
+
+	return NULL;
+}
+
+static void
+cleanup(void)
+{
+	unsigned int i;
+	struct tcb *tcp;
+	int fatal_sig;
+
+	/* 'interrupted' is a volatile object, fetch it only once */
+	fatal_sig = interrupted;
+	if (!fatal_sig)
+		fatal_sig = SIGTERM;
+
+	for (i = 0; i < tcbtabsize; i++) {
+		tcp = tcbtab[i];
+		if (!tcp->pid)
+			continue;
+		if (debug_flag)
+			error_msg("cleanup: looking at pid %u", tcp->pid);
+		if (tcp->pid == strace_child) {
+			kill(tcp->pid, SIGCONT);
+			kill(tcp->pid, fatal_sig);
+		}
+		detach(tcp);
+	}
+	if (cflag)
+		call_summary(shared_log);
+}
+
+static void
+interrupt(int sig)
+{
+	interrupted = sig;
+}
+
+static void
+print_debug_info(const int pid, int status)
+{
+	const unsigned int event = (unsigned int) status >> 16;
+	char buf[sizeof("WIFEXITED,exitcode=%u") + sizeof(int)*3 /*paranoia:*/ + 16];
+	char evbuf[sizeof(",EVENT_VFORK_DONE (%u)") + sizeof(int)*3 /*paranoia:*/ + 16];
+
+	strcpy(buf, "???");
+	if (WIFSIGNALED(status))
+#ifdef WCOREDUMP
+		sprintf(buf, "WIFSIGNALED,%ssig=%s",
+				WCOREDUMP(status) ? "core," : "",
+				signame(WTERMSIG(status)));
+#else
+		sprintf(buf, "WIFSIGNALED,sig=%s",
+				signame(WTERMSIG(status)));
+#endif
+	if (WIFEXITED(status))
+		sprintf(buf, "WIFEXITED,exitcode=%u", WEXITSTATUS(status));
+	if (WIFSTOPPED(status))
+		sprintf(buf, "WIFSTOPPED,sig=%s", signame(WSTOPSIG(status)));
+#ifdef WIFCONTINUED
+	/* Should never be seen */
+	if (WIFCONTINUED(status))
+		strcpy(buf, "WIFCONTINUED");
+#endif
+	evbuf[0] = '\0';
+	if (event != 0) {
+		static const char *const event_names[] = {
+			[PTRACE_EVENT_CLONE] = "CLONE",
+			[PTRACE_EVENT_FORK]  = "FORK",
+			[PTRACE_EVENT_VFORK] = "VFORK",
+			[PTRACE_EVENT_VFORK_DONE] = "VFORK_DONE",
+			[PTRACE_EVENT_EXEC]  = "EXEC",
+			[PTRACE_EVENT_EXIT]  = "EXIT",
+			/* [PTRACE_EVENT_STOP (=128)] would make biggish array */
+		};
+		const char *e = "??";
+		if (event < ARRAY_SIZE(event_names))
+			e = event_names[event];
+		else if (event == PTRACE_EVENT_STOP)
+			e = "STOP";
+		sprintf(evbuf, ",EVENT_%s (%u)", e, event);
+	}
+	error_msg("[wait(0x%06x) = %u] %s%s", status, pid, buf, evbuf);
+}
+
+static struct tcb *
+maybe_allocate_tcb(const int pid, int status)
+{
+	if (!WIFSTOPPED(status)) {
+		if (detach_on_execve && pid == strace_child) {
+			/* example: strace -bexecve sh -c 'exec true' */
+			strace_child = 0;
+			return NULL;
+		}
+		/*
+		 * This can happen if we inherited an unknown child.
+		 * Example: (sleep 1 & exec strace true)
+		 */
+		error_msg("Exit of unknown pid %u ignored", pid);
+		return NULL;
+	}
+	if (followfork) {
+		/* We assume it's a fork/vfork/clone child */
+		struct tcb *tcp = alloctcb(pid);
+		tcp->flags |= TCB_ATTACHED | TCB_STARTUP | post_attach_sigstop;
+		newoutf(tcp);
+		if (!qflag)
+			error_msg("Process %d attached", pid);
+		return tcp;
+	} else {
+		/* This can happen if a clone call used
+		 * CLONE_PTRACE itself.
+		 */
+		ptrace(PTRACE_CONT, pid, NULL, 0);
+		error_msg("Stop of unknown pid %u seen, PTRACE_CONTed it", pid);
+		return NULL;
+	}
+}
+
+static struct tcb *
+maybe_switch_tcbs(struct tcb *tcp, const int pid)
+{
+	FILE *fp;
+	struct tcb *execve_thread;
+	long old_pid = 0;
+
+	if (ptrace(PTRACE_GETEVENTMSG, pid, NULL, (long) &old_pid) < 0)
+		return tcp;
+	/* Avoid truncation in pid2tcb() param passing */
+	if (old_pid <= 0 || old_pid == pid)
+		return tcp;
+	if ((unsigned long) old_pid > UINT_MAX)
+		return tcp;
+	execve_thread = pid2tcb(old_pid);
+	/* It should be !NULL, but I feel paranoid */
+	if (!execve_thread)
+		return tcp;
+
+	if (execve_thread->curcol != 0) {
+		/*
+		 * One case we are here is -ff:
+		 * try "strace -oLOG -ff test/threaded_execve"
+		 */
+		fprintf(execve_thread->outf, " <pid changed to %d ...>\n", pid);
+		/*execve_thread->curcol = 0; - no need, see code below */
+	}
+	/* Swap output FILEs (needed for -ff) */
+	fp = execve_thread->outf;
+	execve_thread->outf = tcp->outf;
+	tcp->outf = fp;
+	/* And their column positions */
+	execve_thread->curcol = tcp->curcol;
+	tcp->curcol = 0;
+	/* Drop leader, but close execve'd thread outfile (if -ff) */
+	droptcb(tcp);
+	/* Switch to the thread, reusing leader's outfile and pid */
+	tcp = execve_thread;
+	tcp->pid = pid;
+	if (cflag != CFLAG_ONLY_STATS) {
+		printleader(tcp);
+		tprintf("+++ superseded by execve in pid %lu +++\n", old_pid);
+		line_ended();
+		tcp->flags |= TCB_REPRINT;
+	}
+
+	return tcp;
+}
+
+static void
+print_signalled(struct tcb *tcp, const int pid, int status)
+{
+	if (pid == strace_child) {
+		exit_code = 0x100 | WTERMSIG(status);
+		strace_child = 0;
+	}
+
+	if (cflag != CFLAG_ONLY_STATS
+	 && (qual_flags[WTERMSIG(status)] & QUAL_SIGNAL)
+	) {
+		printleader(tcp);
+#ifdef WCOREDUMP
+		tprintf("+++ killed by %s %s+++\n",
+			signame(WTERMSIG(status)),
+			WCOREDUMP(status) ? "(core dumped) " : "");
+#else
+		tprintf("+++ killed by %s +++\n",
+			signame(WTERMSIG(status)));
+#endif
+		line_ended();
+	}
+}
+
+static void
+print_exited(struct tcb *tcp, const int pid, int status)
+{
+	if (pid == strace_child) {
+		exit_code = WEXITSTATUS(status);
+		strace_child = 0;
+	}
+
+	if (cflag != CFLAG_ONLY_STATS &&
+	    qflag < 2) {
+		printleader(tcp);
+		tprintf("+++ exited with %d +++\n", WEXITSTATUS(status));
+		line_ended();
+	}
+}
+
+static void
+print_stopped(struct tcb *tcp, const siginfo_t *si, const unsigned int sig)
+{
+	if (cflag != CFLAG_ONLY_STATS
+	    && !hide_log_until_execve
+	    && (qual_flags[sig] & QUAL_SIGNAL)
+	   ) {
+		printleader(tcp);
+		if (si) {
+			tprintf("--- %s ", signame(sig));
+			printsiginfo(si);
+			tprints(" ---\n");
+		} else
+			tprintf("--- stopped by %s ---\n", signame(sig));
+		line_ended();
+	}
+}
+
+static void
+startup_tcb(struct tcb *tcp)
+{
+	if (debug_flag)
+		error_msg("pid %d has TCB_STARTUP, initializing it", tcp->pid);
+
+	tcp->flags &= ~TCB_STARTUP;
+
+	if (!use_seize) {
+		if (debug_flag)
+			error_msg("setting opts 0x%x on pid %d",
+				  ptrace_setoptions, tcp->pid);
+		if (ptrace(PTRACE_SETOPTIONS, tcp->pid, NULL, ptrace_setoptions) < 0) {
+			if (errno != ESRCH) {
+				/* Should never happen, really */
+				perror_msg_and_die("PTRACE_SETOPTIONS");
+			}
+		}
+	}
+}
+
+/* Returns true iff the main trace loop has to continue. */
+static bool
+trace(void)
+{
+	int pid;
+	int wait_errno;
+	int status;
+	bool stopped;
+	unsigned int sig;
+	unsigned int event;
+	struct tcb *tcp;
+	struct rusage ru;
+
+	if (interrupted)
+		return false;
+
+	/*
+	 * Used to exit simply when nprocs hits zero, but in this testcase:
+	 *  int main() { _exit(!!fork()); }
+	 * under strace -f, parent sometimes (rarely) manages
+	 * to exit before we see the first stop of the child,
+	 * and we are losing track of it:
+	 *  19923 clone(...) = 19924
+	 *  19923 exit_group(1)     = ?
+	 *  19923 +++ exited with 1 +++
+	 * Exiting only when wait() returns ECHILD works better.
+	 */
+	if (popen_pid != 0) {
+		/* However, if -o|logger is in use, we can't do that.
+		 * Can work around that by double-forking the logger,
+		 * but that loses the ability to wait for its completion
+		 * on exit. Oh well...
+		 */
+		if (nprocs == 0)
+			return false;
+	}
+
+	if (interactive)
+		sigprocmask(SIG_SETMASK, &empty_set, NULL);
+	pid = wait4(-1, &status, __WALL, (cflag ? &ru : NULL));
+	wait_errno = errno;
+	if (interactive)
+		sigprocmask(SIG_BLOCK, &blocked_set, NULL);
+
+	if (pid < 0) {
+		if (wait_errno == EINTR)
+			return true;
+		if (nprocs == 0 && wait_errno == ECHILD)
+			return false;
+		/*
+		 * If nprocs > 0, ECHILD is not expected,
+		 * treat it as any other error here:
+		 */
+		errno = wait_errno;
+		perror_msg_and_die("wait4(__WALL)");
+	}
+
+	if (pid == popen_pid) {
+		if (!WIFSTOPPED(status))
+			popen_pid = 0;
+		return true;
+	}
+
+	if (debug_flag)
+		print_debug_info(pid, status);
+
+	/* Look up 'pid' in our table. */
+	tcp = pid2tcb(pid);
+
+	if (!tcp) {
+		tcp = maybe_allocate_tcb(pid, status);
+		if (!tcp)
+			return true;
+	}
+
+	if (WIFSTOPPED(status))
+		get_regs(pid);
+	else
+		clear_regs();
+
+	event = (unsigned int) status >> 16;
+
+	if (event == PTRACE_EVENT_EXEC) {
+		/*
+		 * Under Linux, execve changes pid to thread leader's pid,
+		 * and we see this changed pid on EVENT_EXEC and later,
+		 * execve sysexit. Leader "disappears" without exit
+		 * notification. Let user know that, drop leader's tcb,
+		 * and fix up pid in execve thread's tcb.
+		 * Effectively, execve thread's tcb replaces leader's tcb.
+		 *
+		 * BTW, leader is 'stuck undead' (doesn't report WIFEXITED
+		 * on exit syscall) in multithreaded programs exactly
+		 * in order to handle this case.
+		 *
+		 * PTRACE_GETEVENTMSG returns old pid starting from Linux 3.0.
+		 * On 2.6 and earlier, it can return garbage.
+		 */
+		if (os_release >= KERNEL_VERSION(3,0,0))
+			tcp = maybe_switch_tcbs(tcp, pid);
+
+		if (detach_on_execve && !skip_one_b_execve) {
+			detach(tcp); /* do "-b execve" thingy */
+			return true;
+		}
+		skip_one_b_execve = 0;
+	}
+
+	/* Set current output file */
+	current_tcp = tcp;
+
+	if (cflag) {
+		tv_sub(&tcp->dtime, &ru.ru_stime, &tcp->stime);
+		tcp->stime = ru.ru_stime;
+	}
+
+	if (WIFSIGNALED(status)) {
+		print_signalled(tcp, pid, status);
+		droptcb(tcp);
+		return true;
+	}
+
+	if (WIFEXITED(status)) {
+		print_exited(tcp, pid, status);
+		droptcb(tcp);
+		return true;
+	}
+
+	if (!WIFSTOPPED(status)) {
+		/*
+		 * Neither signalled, exited or stopped.
+		 * How could that be?
+		 */
+		error_msg("pid %u not stopped!", pid);
+		droptcb(tcp);
+		return true;
+	}
+
+	/* Is this the very first time we see this tracee stopped? */
+	if (tcp->flags & TCB_STARTUP) {
+		startup_tcb(tcp);
+		if (get_scno(tcp) == 1)
+			tcp->s_prev_ent = tcp->s_ent;
+	}
+
+	sig = WSTOPSIG(status);
+
+	if (event != 0) {
+		/* Ptrace event */
+#if USE_SEIZE
+		if (event == PTRACE_EVENT_STOP) {
+			/*
+			 * PTRACE_INTERRUPT-stop or group-stop.
+			 * PTRACE_INTERRUPT-stop has sig == SIGTRAP here.
+			 */
+			switch (sig) {
+				case SIGSTOP:
+				case SIGTSTP:
+				case SIGTTIN:
+				case SIGTTOU:
+					stopped = true;
+					goto show_stopsig;
+			}
+		}
+#endif
+		goto restart_tracee_with_sig_0;
+	}
+
+	/*
+	 * Is this post-attach SIGSTOP?
+	 * Interestingly, the process may stop
+	 * with STOPSIG equal to some other signal
+	 * than SIGSTOP if we happend to attach
+	 * just before the process takes a signal.
+	 */
+	if (sig == SIGSTOP && (tcp->flags & TCB_IGNORE_ONE_SIGSTOP)) {
+		if (debug_flag)
+			error_msg("ignored SIGSTOP on pid %d", tcp->pid);
+		tcp->flags &= ~TCB_IGNORE_ONE_SIGSTOP;
+		goto restart_tracee_with_sig_0;
+	}
+
+	if (sig != syscall_trap_sig) {
+		siginfo_t si = {};
+
+		/*
+		 * True if tracee is stopped by signal
+		 * (as opposed to "tracee received signal").
+		 * TODO: shouldn't we check for errno == EINVAL too?
+		 * We can get ESRCH instead, you know...
+		 */
+		stopped = ptrace(PTRACE_GETSIGINFO, pid, 0, (long) &si) < 0;
+#if USE_SEIZE
+show_stopsig:
+#endif
+		print_stopped(tcp, stopped ? NULL : &si, sig);
+
+		if (!stopped)
+			/* It's signal-delivery-stop. Inject the signal */
+			goto restart_tracee;
+
+		/* It's group-stop */
+		if (use_seize) {
+			/*
+			 * This ends ptrace-stop, but does *not* end group-stop.
+			 * This makes stopping signals work properly on straced process
+			 * (that is, process really stops. It used to continue to run).
+			 */
+			if (ptrace_restart(PTRACE_LISTEN, tcp, 0) < 0) {
+				/* Note: ptrace_restart emitted error message */
+				exit_code = 1;
+				return false;
+			}
+			return true;
+		}
+		/* We don't have PTRACE_LISTEN support... */
+		goto restart_tracee;
+	}
+
+	/* We handled quick cases, we are permitted to interrupt now. */
+	if (interrupted)
+		return false;
+
+	/*
+	 * This should be syscall entry or exit.
+	 * Handle it.
+	 */
+	if (trace_syscall(tcp) < 0) {
+		/*
+		 * ptrace() failed in trace_syscall().
+		 * Likely a result of process disappearing mid-flight.
+		 * Observed case: exit_group() or SIGKILL terminating
+		 * all processes in thread group.
+		 * We assume that ptrace error was caused by process death.
+		 * We used to detach(tcp) here, but since we no longer
+		 * implement "detach before death" policy/hack,
+		 * we can let this process to report its death to us
+		 * normally, via WIFEXITED or WIFSIGNALED wait status.
+		 */
+		return true;
+	}
+
+restart_tracee_with_sig_0:
+	sig = 0;
+
+restart_tracee:
+	if (ptrace_restart(PTRACE_SYSCALL, tcp, sig) < 0) {
+		/* Note: ptrace_restart emitted error message */
+		exit_code = 1;
+		return false;
+	}
+
+	return true;
+}
+
+int
+main(int argc, char *argv[])
+{
+	init(argc, argv);
+
+	while (trace())
+		;
+
+	cleanup();
+	fflush(NULL);
+	if (shared_log != stderr)
+		fclose(shared_log);
+	if (popen_pid) {
+		while (waitpid(popen_pid, NULL, 0) < 0 && errno == EINTR)
+			;
+	}
+	if (exit_code > 0xff) {
+		/* Avoid potential core file clobbering.  */
+		struct_rlimit rlim = {0, 0};
+		set_rlimit(RLIMIT_CORE, &rlim);
+
+		/* Child was killed by a signal, mimic that.  */
+		exit_code &= 0xff;
+		signal(exit_code, SIG_DFL);
+		raise(exit_code);
+		/* Paranoia - what if this signal is not fatal?
+		   Exit with 128 + signo then.  */
+		exit_code += 128;
+	}
+
+	return exit_code;
+}
diff --git a/strace/strace.spec.in b/strace/strace.spec.in
new file mode 100644
index 0000000..0e13640
--- /dev/null
+++ b/strace/strace.spec.in
@@ -0,0 +1,563 @@
+Summary: Tracks and displays system calls associated with a running process
+Name: strace
+Version: @PACKAGE_VERSION@
+Release: 1%{?dist}
+License: BSD
+Group: Development/Debuggers
+URL: http://sourceforge.net/projects/strace/
+Source: http://downloads.sourceforge.net/strace/%{name}-%{version}.tar.xz
+%if 0%{?fedora_version} >= 20 || 0%{?centos_version} >= 800 || 0%{?rhel_version} >= 800 || 0%{?scientificlinux_version} >= 800 || 0%{?suse_version} >= 1300
+%define buildrequires_libunwind_devel BuildRequires: libunwind-devel
+%endif
+%ifarch x86_64
+# for experimental -k option
+%{?buildrequires_libunwind_devel}
+%endif
+%define strace64_arches ppc64 sparc64
+%{?!buildroot:BuildRoot: %_tmppath/buildroot-%name-%version-%release}
+
+%description
+The strace program intercepts and records the system calls called and
+received by a running process.  Strace can print a record of each
+system call, its arguments and its return value.  Strace is useful for
+diagnosing problems and debugging, as well as for instructional
+purposes.
+
+Install strace if you need a tool to track the system calls made and
+received by a process.
+
+%ifarch %{strace64_arches}
+%package -n strace64
+Summary: Tracks and displays system calls associated with a running process.
+Group: Development/Debuggers
+
+%description -n strace64
+The strace program intercepts and records the system calls called and
+received by a running process.  Strace can print a record of each
+system call, its arguments and its return value.  Strace is useful for
+diagnosing problems and debugging, as well as for instructional
+purposes.
+
+Install strace if you need a tool to track the system calls made and
+received by a process.
+
+This package provides the `strace64' program to trace 64-bit processes.
+The `strace' program in the `strace' package is for 32-bit processes.
+%endif
+
+%prep
+%setup -q
+echo -n %version-%release > .tarball-version
+
+%build
+echo 'BEGIN OF BUILD ENVIRONMENT INFORMATION'
+uname -a |head -1
+libc="$(ldd /bin/sh |sed -n 's|^[^/]*\(/[^ ]*/libc\.so[^ ]*\).*|\1|p' |head -1)"
+$libc |head -1
+file -L /bin/sh
+gcc --version |head -1
+kver="$(echo -e '#include <linux/version.h>\nLINUX_VERSION_CODE' | gcc -E -P -)"
+printf 'kernel-headers %%s.%%s.%%s\n' $(($kver/65536)) $(($kver/256%%256)) $(($kver%%256))
+echo 'END OF BUILD ENVIRONMENT INFORMATION'
+
+%configure
+make %{?_smp_mflags}
+
+%install
+make DESTDIR=%{buildroot} install
+
+# remove unpackaged files from the buildroot
+rm -f %{buildroot}%{_bindir}/strace-graph
+
+%define copy64 ln
+%if 0%{?rhel}
+%if 0%{?rhel} < 6
+%endif
+%define copy64 cp -p
+%endif
+
+%ifarch %{strace64_arches}
+%{copy64} %{buildroot}%{_bindir}/strace %{buildroot}%{_bindir}/strace64
+%endif
+
+%check
+make %{?_smp_mflags} -k check VERBOSE=1
+echo 'BEGIN OF TEST SUITE INFORMATION'
+tail -n 99999 -- tests*/test-suite.log tests*/ksysent.log
+echo 'END OF TEST SUITE INFORMATION'
+
+%files
+%{?suse_version:%defattr(-,root,root)}
+%doc CREDITS ChangeLog ChangeLog-CVS COPYING NEWS README
+%{_bindir}/strace
+%{_bindir}/strace-log-merge
+%{_mandir}/man1/*
+
+%ifarch %{strace64_arches}
+%files -n strace64
+%{?suse_version:%defattr(-,root,root)}
+%{_bindir}/strace64
+%endif
+
+%changelog
+* @RPM_CHANGELOGTIME@ @PACKAGE_BUGREPORT@ - @PACKAGE_VERSION@-1
+- @PACKAGE_STRING@ snapshot.
+
+* Tue Jul 26 2016 Dmitry V. Levin <ldv@altlinux.org> - 4.13-1
+- v4.12 -> v4.13.
+
+* Tue May 31 2016 Dmitry V. Levin <ldv@altlinux.org> - 4.12-1
+- v4.11-163-g972018f -> v4.12.
+
+* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 4.11.0.163.9720-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
+
+* Fri Jan 15 2016 Dmitry V. Levin <ldv@altlinux.org> - 4.11.0.163.9720-1
+- New upstream snapshot v4.11-163-g972018f:
+  + fixed decoding of syscalls unknown to the kernel on s390/s390x (#1298294).
+
+* Wed Dec 23 2015 Dmitry V. Levin <ldv@altlinux.org> - 4.11-2
+- Enabled experimental -k option on x86_64 (#1170296).
+
+* Mon Dec 21 2015 Dmitry V. Levin <ldv@altlinux.org> - 4.11-1
+- New upstream release:
+  + print nanoseconds along with seconds in stat family syscalls (#1251176).
+
+* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.10-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
+
+* Mon May 11 2015 Marcin Juszkiewicz <mjuszkiewicz@redhat.com> - 4.10-2
+- Backport set of upstream patches to get it buildable on AArch64
+
+* Fri Mar 06 2015 Dmitry V. Levin <ldv@altlinux.org> - 4.10-1
+- New upstream release:
+  + enhanced ioctl decoding (#902788).
+
+* Mon Nov 03 2014 Lubomir Rintel <lkundrak@v3.sk> - 4.9-3
+- Regenerate ioctl entries with proper kernel headers
+
+* Mon Aug 18 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.9-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
+
+* Fri Aug 15 2014 Dmitry V. Levin <ldv@altlinux.org> - 4.9-1
+- New upstream release:
+  + fixed build when <sys/ptrace.h> and <linux/ptrace.h> conflict (#993384);
+  + updated CLOCK_* constants (#1088455);
+  + enabled ppc64le support (#1122323);
+  + fixed attach to a process on ppc64le (#1129569).
+
+* Fri Jul 25 2014 Dan Horák <dan[at]danny.cz> - 4.8-5
+- update for ppc64
+
+* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.8-4
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
+
+* Fri Dec  6 2013 Peter Robinson <pbrobinson@fedoraproject.org> 4.8-3
+- Fix FTBFS
+
+* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.8-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
+
+* Mon Jun 03 2013 Dmitry V. Levin <ldv@altlinux.org> - 4.8-1
+- New upstream release:
+  + fixed ERESTARTNOINTR leaking to userspace on ancient kernels (#659382);
+  + fixed decoding of *xattr syscalls (#885233);
+  + fixed handling of files with 64-bit inode numbers by 32-bit strace (#912790);
+  + added aarch64 support (#969858).
+
+* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.7-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
+
+* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.7-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
+
+* Wed May 02 2012 Dmitry V. Levin <ldv@altlinux.org> 4.7-1
+- New upstream release.
+  + implemented proper handling of real SIGTRAPs (#162774).
+
+* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.6-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
+
+* Mon Mar 14 2011 Dmitry V. Levin <ldv@altlinux.org> - 4.6-1
+- New upstream release.
+  + fixed a corner case in waitpid handling (#663547).
+
+* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.5.20-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
+
+* Tue Apr 13 2010 Roland McGrath <roland@redhat.com> - 4.5.20-1
+- New upstream release, work mostly by Andreas Schwab and Dmitry V. Levin.
+  + fixed potential stack buffer overflow in select decoder (#556678);
+  + fixed FTBFS (#539044).
+
+* Wed Oct 21 2009 Roland McGrath <roland@redhat.com> - 4.5.19-1
+- New upstream release, work mostly by Dmitry V. Levin <ldv@altlinux.org>
+  + exit/kill strace with traced process exitcode/signal (#105371);
+  + fixed build on ARM EABI (#507576);
+  + fixed display of 32-bit argv array on 64-bit architectures (#519480);
+  + fixed display of 32-bit fcntl(F_SETLK) on 64-bit architectures (#471169);
+  + fixed several bugs in strings decoder, including potential heap
+    memory corruption (#470529, #478324, #511035).
+
+* Thu Aug 28 2008 Roland McGrath <roland@redhat.com> - 4.5.18-1
+- build fix for newer kernel headers (#457291)
+- fix CLONE_VFORK handling (#455078)
+- Support new Linux/PPC system call subpage_prot and PROT_SAO flag.
+- In sigaction system call, display sa_flags value along with SIG_DFL/SIG_IGN.
+
+* Mon Jul 21 2008 Roland McGrath <roland@redhat.com> - 4.5.17-1
+- handle O_CLOEXEC, MSG_CMSG_CLOEXEC (#365781)
+- fix biarch stat64 decoding (#222275)
+- fix spurious "..." in printing of environment strings (#358241)
+- improve prctl decoding (#364401)
+- fix hang wait on exited child with exited child (#354261)
+- fix biarch fork/vfork (-f) tracing (#447475)
+- fix biarch printing of negative argument kill (#430585)
+- fix biarch decoding of error return values (#447587)
+- fix -f tracing of CLONE_VFORK (#455078)
+- fix ia64 register clobberation in -f tracing (#453438)
+- print SO_NODEFER, SA_RESETHAND instead of SA_NOMASK, SA_ONESHOT (#455821)
+- fix futex argument decoding (#448628, #448629)
+
+* Fri Aug  3 2007 Roland McGrath <roland@redhat.com> - 4.5.16-1
+- fix multithread issues (#240962, #240961, #247907)
+- fix spurious SIGSTOP on early interrupt (#240986)
+- fix utime for biarch (#247185)
+- fix -u error message (#247170)
+- better futex syscall printing (##241467)
+- fix argv/envp printing with small -s settings, and for biarch
+- new syscalls: getcpu, eventfd, timerfd, signalfd, epoll_pwait,
+  move_pages, utimensat
+
+* Tue Jan 16 2007 Roland McGrath <roland@redhat.com> - 4.5.15-1
+- biarch fixes (#179740, #192193, #171626, #173050, #218433, #218043)
+- fix -ff -o behavior (#204950, #218435, #193808, #219423)
+- better quotactl printing (#118696)
+- *at, inotify*, pselect6, ppoll and unshare syscalls (#178633, #191275)
+- glibc-2.5 build fixes (#209856)
+- memory corruption fixes (#200621
+- fix race in child setup under -f (#180293)
+- show ipc key values in hex (#198179, #192182)
+- disallow -c with -ff (#187847)
+- Resolves: RHBZ #179740, RHBZ #192193, RHBZ #204950, RHBZ #218435
+- Resolves: RHBZ #193808, RHBZ #219423, RHBZ #171626, RHBZ #173050
+- Resolves: RHBZ #218433, RHBZ #218043, RHBZ #118696, RHBZ #178633
+- Resolves: RHBZ #191275, RHBZ #209856, RHBZ #200621, RHBZ #180293
+- Resolves: RHBZ #198179, RHBZ #198182, RHBZ #187847
+
+* Mon Nov 20 2006 Jakub Jelinek <jakub@redhat.com> - 4.5.14-4
+- Fix ia64 syscall decoding (#206768)
+- Fix build with glibc-2.4.90-33 and up on all arches but ia64
+- Fix build against 2.6.18+ headers
+
+* Tue Aug 22 2006 Roland McGrath <roland@redhat.com> - 4.5.14-3
+- Fix bogus decoding of syscalls >= 300 (#201462, #202620).
+
+* Fri Jul 14 2006 Jesse Keating <jkeating@redhat.com> - 4.5.14-2
+- rebuild
+
+* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 4.5.14-1.2
+- bump again for long double bug on ppc{,64}
+
+* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 4.5.14-1.1
+- rebuilt for new gcc4.1 snapshot and glibc changes
+
+* Mon Jan 16 2006 Roland McGrath <roland@redhat.com> - 4.5.14-1
+- Fix biarch decoding of socket syscalls (#174354).
+- Fix biarch -e support (#173986).
+- Accept numeric syscalls in -e (#174798).
+- Fix ipc syscall decoding (#164755).
+- Improve msgrcv printing (#164757).
+- Man page updates (#165375).
+- Improve mount syscall printing (#165377).
+- Correct printing of restarting syscalls (#165469).
+
+* Wed Aug  3 2005 Roland McGrath <roland@redhat.com> - 4.5.13-1
+- Fix setsockopt decoding on 64-bit (#162449).
+- Fix typos in socket option name strings (#161578).
+- Display more IPV6 socket options by name (#162450).
+- Don't display inappropriate syscalls for -e trace=file (#159340).
+- New selector type -e trace=desc for file-descriptor using calls (#159400).
+- Fix 32-bit old_mmap syscall decoding on x86-64 (#162467, #164215).
+- Fix errors detaching from multithreaded process on interrupt (#161919).
+- Note 4.5.12 fix for crash handling bad signal numbers (#162739).
+
+* Wed Jun  8 2005 Roland McGrath <roland@redhat.com> - 4.5.12-1
+- Fix known syscall recognition for IA32 processes on x86-64 (#158934).
+- Fix bad output for ptrace on x86-64 (#159787).
+- Fix potential buffer overruns (#151570, #159196).
+- Make some diagnostics more consistent (#159308).
+- Update PowerPC system calls.
+- Better printing for Linux aio system calls.
+- Don't truncate statfs64 fields to 32 bits in output (#158243).
+- Cosmetic code cleanups (#159688).
+
+* Tue Mar 22 2005 Roland McGrath <roland@redhat.com> - 4.5.11-1
+- Build tweaks.
+- Note 4.5.10 select fix (#151570).
+
+* Mon Mar 14 2005 Roland McGrath <roland@redhat.com> - 4.5.10-1
+- Fix select handling on nonstandard fd_set sizes.
+- Don't print errors for null file name pointers.
+- Fix initial execve output with -i (#143365).
+
+* Fri Feb  4 2005 Roland McGrath <roland@redhat.com> - 4.5.9-2
+- update ia64 syscall list (#146245)
+- fix x86_64 syscall argument extraction for 32-bit processes (#146093)
+- fix -e signal=NAME parsing (#143362)
+- fix x86_64 exit_group syscall handling
+- improve socket ioctl printing (#138223)
+- code cleanups (#143369, #143370)
+- improve mount flags printing (#141932)
+- support symbolic printing of x86_64 arch_prctl parameters (#142667)
+- fix potential crash in getxattr printing
+
+* Tue Oct 19 2004 Roland McGrath <roland@redhat.com> - 4.5.8-1
+- fix multithreaded exit handling (#132150, #135254)
+- fix ioctl name matching (#129808)
+- print RTC_* ioctl structure contents (#58606)
+- grok epoll_* syscalls (#134463)
+- grok new RLIMIT_* values (#133594)
+- print struct cmsghdr contents for sendmsg (#131689)
+- fix clock_* and timer_* argument output (#131420)
+
+* Tue Aug 31 2004 Roland McGrath <roland@redhat.com> - 4.5.7-2
+- new upstream version, misc fixes and updates (#128091, #129166, #128391, #129378, #130965, #131177)
+
+* Mon Jul 12 2004 Roland McGrath <roland@redhat.com> 4.5.6-1
+- new upstream version, updates ioctl lists (#127398), fixes quotactl (#127393), more ioctl decoding (#126917)
+
+* Sun Jun 27 2004 Roland McGrath <roland@redhat.com> 4.5.5-1
+- new upstream version, fixes x86-64 biarch support (#126547)
+
+* Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com> 4.5.4-2
+- rebuilt
+
+* Thu Jun  3 2004 Roland McGrath <roland@redhat.com> 4.5.4-0.FC1
+- rebuilt for FC1 update
+
+* Thu Jun  3 2004 Roland McGrath <roland@redhat.com> 4.5.4-1
+- new upstream version, more ioctls (#122257), minor fixes
+
+* Fri Apr 16 2004 Roland McGrath <roland@redhat.com> 4.5.3-1
+- new upstream version, mq_* calls (#120701), -p vs NPTL (#120462), more fixes (#118694, #120541, #118685)
+
+* Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com> 4.5.2-1.1
+- rebuilt
+
+* Mon Mar  1 2004 Roland McGrath <roland@redhat.com> 4.5.2-1
+- new upstream version, sched_* calls (#116990), show core flag (#112117)
+
+* Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
+- rebuilt
+
+* Thu Nov 13 2003 Roland McGrath <roland@redhat.com> 4.5.1-1
+- new upstream version, more fixes (#108012, #105366, #105359, #105358)
+
+* Tue Sep 30 2003 Roland McGrath <roland@redhat.com> 4.5-3
+- revert bogus s390 fix
+
+* Thu Sep 25 2003 Roland McGrath <roland@redhat.com> 4.5-1.2.1AS
+- rebuilt for 2.1AS erratum
+
+* Wed Sep 24 2003 Roland McGrath <roland@redhat.com> 4.5-2
+- rebuilt
+
+* Wed Sep 24 2003 Roland McGrath <roland@redhat.com> 4.5-1
+- new upstream version, more fixes (#101499, #104365)
+
+* Thu Jul 17 2003 Roland McGrath <roland@redhat.com> 4.4.99-2
+- rebuilt
+
+* Thu Jul 17 2003 Roland McGrath <roland@redhat.com> 4.4.99-1
+- new upstream version, groks more new system calls, PF_INET6 sockets
+
+* Tue Jun 10 2003 Roland McGrath <roland@redhat.com> 4.4.98-1
+- new upstream version, more fixes (#90754, #91085)
+
+* Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
+- rebuilt
+
+* Sun Mar 30 2003 Roland McGrath <roland@redhat.com> 4.4.96-1
+- new upstream version, handles yet more 2.5 syscalls, x86_64 & ia64 fixes
+
+* Mon Feb 24 2003 Elliot Lee <sopwith@redhat.com> 4.4.95-2
+- rebuilt
+
+* Mon Feb 24 2003 Roland McGrath <roland@redhat.com> 4.4.95-1
+- new upstream version, fixed getresuid/getresgid (#84959)
+
+* Wed Feb 19 2003 Roland McGrath <roland@redhat.com> 4.4.94-1
+- new upstream version, new option -E to set environment variables (#82392)
+
+* Wed Jan 22 2003 Tim Powers <timp@redhat.com> 4.4.93-2
+- rebuilt
+
+* Tue Jan 21 2003 Roland McGrath <roland@redhat.com> 4.4.93-1
+- new upstream version, fixes ppc and s390 bugs, adds missing ptrace requests
+
+* Fri Jan 10 2003 Roland McGrath <roland@redhat.com> 4.4.91-1
+- new upstream version, fixes -f on x86-64
+
+* Fri Jan 10 2003 Roland McGrath <roland@redhat.com> 4.4.90-1
+- new upstream version, fixes all known bugs modulo ia64 and s390 issues
+
+* Fri Jan 03 2003 Florian La Roche <Florian.LaRoche@redhat.de> 4.4-11
+- add further s390 patch from IBM
+
+* Wed Nov 27 2002 Tim Powers <timp@redhat.com> 4.4-10
+- remove unpackaged files from the buildroot
+
+* Mon Oct 07 2002 Phil Knirsch <pknirsch@redhat.com> 4.4-9.1
+- Added latest s390(x) patch.
+
+* Fri Sep 06 2002 Karsten Hopp <karsten@redhat.de> 4.4-9
+- preliminary x86_64 support with an ugly patch to help
+  debugging. Needs cleanup!
+
+* Mon Sep  2 2002 Jakub Jelinek <jakub@redhat.com> 4.4-8
+- newer version of the clone fixing patch (Roland McGrath)
+- aio syscalls for i386/ia64/ppc (Ben LaHaise)
+
+* Wed Aug 28 2002 Jakub Jelinek <jakub@redhat.com> 4.4-7
+- fix strace -f (Roland McGrath, #68994)
+- handle ?et_thread_area, SA_RESTORER (Ulrich Drepper)
+
+* Fri Jun 21 2002 Jakub Jelinek <jakub@redhat.com> 4.4-6
+- handle futexes, *xattr, sendfile64, etc. (Ulrich Drepper)
+- handle modify_ldt (#66894)
+
+* Thu May 23 2002 Tim Powers <timp@redhat.com>
+- automated rebuild
+
+* Tue Apr 16 2002 Jakub Jelinek <jakub@redhat.com> 4.4-4
+- fix for the last patch by Jeff Law (#62591)
+
+* Mon Mar  4 2002 Preston Brown <pbrown@redhat.com> 4.4-3
+- integrate patch from Jeff Law to eliminate hang tracing threads
+
+* Sat Feb 23 2002 Florian La Roche <Florian.LaRoche@redhat.de>
+- minor update from debian tar-ball
+
+* Wed Jan 02 2002 Florian La Roche <Florian.LaRoche@redhat.de>
+- update to 4.4
+
+* Sun Jul 22 2001 Florian La Roche <Florian.LaRoche@redhat.de>
+- disable s390 patches, they are already included
+
+* Wed Jul 18 2001 Preston Brown <pbrown@redhat.com> 4.3-1
+- new upstream version.  Seems to have integrated most new syscalls
+- tracing threaded programs is now functional.
+
+* Mon Jun 11 2001 Than Ngo <than@redhat.com>
+- port s390 patches from IBM
+
+* Wed May 16 2001 Nalin Dahyabhai <nalin@redhat.com>
+- modify new syscall patch to allocate enough heap space in setgroups32()
+
+* Wed Feb 14 2001 Jakub Jelinek <jakub@redhat.com>
+- #include <time.h> in addition to <sys/time.h>
+
+* Fri Jan 26 2001 Karsten Hopp <karsten@redhat.com>
+- clean up conflicting patches. This happened only
+  when building on S390
+
+* Fri Jan 19 2001 Bill Nottingham <notting@redhat.com>
+- update to CVS, reintegrate ia64 support
+
+* Fri Dec  8 2000 Bernhard Rosenkraenzer <bero@redhat.com>
+- Get S/390 support into the normal package
+
+* Sat Nov 18 2000 Florian La Roche <Florian.LaRoche@redhat.de>
+- added S/390 patch from IBM, adapting it to not conflict with
+  IA64 patch
+
+* Sat Aug 19 2000 Jakub Jelinek <jakub@redhat.com>
+- doh, actually apply the 2.4 syscalls patch
+- make it compile with 2.4.0-test7-pre4+ headers, add
+  getdents64 and fcntl64
+
+* Thu Aug  3 2000 Jakub Jelinek <jakub@redhat.com>
+- add a bunch of new 2.4 syscalls (#14036)
+
+* Wed Jul 12 2000 Prospector <bugzilla@redhat.com>
+- automatic rebuild
+- excludearch ia64
+
+* Fri Jun  2 2000 Matt Wilson <msw@redhat.com>
+- use buildinstall for FHS
+
+* Wed May 24 2000 Jakub Jelinek <jakub@redhat.com>
+- make things compile on sparc
+- fix sigreturn on sparc
+
+* Fri Mar 31 2000 Bill Nottingham <notting@redhat.com>
+- fix stat64 misdef (#10485)
+
+* Tue Mar 21 2000 Michael K. Johnson <johnsonm@redhat.com>
+- added ia64 patch
+
+* Thu Feb 03 2000 Cristian Gafton <gafton@redhat.com>
+- man pages are compressed
+- version 4.2 (why are we keeping all these patches around?)
+
+* Sat Nov 27 1999 Jeff Johnson <jbj@redhat.com>
+- update to 4.1 (with sparc socketcall patch).
+
+* Fri Nov 12 1999 Jakub Jelinek <jakub@redhat.com>
+- fix socketcall on sparc.
+
+* Thu Sep 02 1999 Cristian Gafton <gafton@redhat.com>
+- fix KERN_SECURELVL compile problem
+
+* Tue Aug 31 1999 Cristian Gafton <gafton@redhat.com>
+- added alpha patch from HJLu to fix the osf_sigprocmask interpretation
+
+* Sat Jun 12 1999 Jeff Johnson <jbj@redhat.com>
+- update to 3.99.1.
+
+* Wed Jun  2 1999 Jeff Johnson <jbj@redhat.com>
+- add (the other :-) jj's sparc patch.
+
+* Wed May 26 1999 Jeff Johnson <jbj@redhat.com>
+- upgrade to 3.99 in order to
+-    add new 2.2.x open flags (#2955).
+-    add new 2.2.x syscalls (#2866).
+- strace 3.1 patches carried along for now.
+
+* Sun May 16 1999 Jeff Johnson <jbj@redhat.com>
+- don't rely on (broken!) rpm %%patch (#2735)
+
+* Tue Apr 06 1999 Preston Brown <pbrown@redhat.com>
+- strip binary
+
+* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com>
+- auto rebuild in the new build environment (release 16)
+
+* Tue Feb  9 1999 Jeff Johnson <jbj@redhat.com>
+- vfork est arrive!
+
+* Tue Feb  9 1999 Christopher Blizzard <blizzard@redhat.com>
+- Add patch to follow clone() syscalls, too.
+
+* Sun Jan 17 1999 Jeff Johnson <jbj@redhat.com>
+- patch to build alpha/sparc with glibc 2.1.
+
+* Thu Dec 03 1998 Cristian Gafton <gafton@redhat.com>
+- patch to build on ARM
+
+* Wed Sep 30 1998 Jeff Johnson <jbj@redhat.com>
+- fix typo (printf, not tprintf).
+
+* Sat Sep 19 1998 Jeff Johnson <jbj@redhat.com>
+- fix compile problem on sparc.
+
+* Tue Aug 18 1998 Cristian Gafton <gafton@redhat.com>
+- buildroot
+
+* Mon Jul 20 1998 Cristian Gafton <gafton@redhat.com>
+- added the umoven patch from James Youngman <jay@gnu.org>
+- fixed build problems on newer glibc releases
+
+* Mon Jun 08 1998 Prospector System <bugs@redhat.com>
+- translations modified for de, fr, tr
diff --git a/strace/swapon.c b/strace/swapon.c
new file mode 100644
index 0000000..ef88b1c
--- /dev/null
+++ b/strace/swapon.c
@@ -0,0 +1,24 @@
+#include "defs.h"
+
+#include <sys/swap.h>
+
+#include "xlat/swap_flags.h"
+
+SYS_FUNC(swapon)
+{
+	unsigned int flags = tcp->u_arg[1];
+	unsigned int prio = flags & SWAP_FLAG_PRIO_MASK;
+	flags &= ~SWAP_FLAG_PRIO_MASK;
+
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	if (flags) {
+		printflags(swap_flags, flags, "SWAP_FLAG_???");
+		if (prio)
+			tprintf("|%u", prio);
+	} else {
+		tprintf("%u", prio);
+	}
+
+	return RVAL_DECODED;
+}
diff --git a/strace/sync_file_range.c b/strace/sync_file_range.c
new file mode 100644
index 0000000..855e8af
--- /dev/null
+++ b/strace/sync_file_range.c
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2013 William Manley <william.manley@youview.com>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+#include "xlat/sync_file_range_flags.h"
+
+SYS_FUNC(sync_file_range)
+{
+	int argn;
+
+	printfd(tcp, tcp->u_arg[0]);
+	argn = printllval(tcp, ", %lld, ", 1);
+	argn = printllval(tcp, "%lld, ", argn);
+	printflags(sync_file_range_flags, tcp->u_arg[argn],
+		   "SYNC_FILE_RANGE_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/sync_file_range2.c b/strace/sync_file_range2.c
new file mode 100644
index 0000000..a1ef091
--- /dev/null
+++ b/strace/sync_file_range2.c
@@ -0,0 +1,45 @@
+/*
+ * Copyright (c) 2013 William Manley <william.manley@youview.com>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+#include "xlat/sync_file_range_flags.h"
+
+SYS_FUNC(sync_file_range2)
+{
+	int argn;
+
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printflags(sync_file_range_flags, tcp->u_arg[1],
+		   "SYNC_FILE_RANGE_???");
+	argn = printllval(tcp, ", %lld, ", 2);
+	argn = printllval(tcp, "%lld", argn);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/sys_func.h b/strace/sys_func.h
new file mode 100644
index 0000000..a40a293
--- /dev/null
+++ b/strace/sys_func.h
@@ -0,0 +1,311 @@
+extern SYS_FUNC(accept);
+extern SYS_FUNC(accept4);
+extern SYS_FUNC(access);
+extern SYS_FUNC(add_key);
+extern SYS_FUNC(adjtimex);
+extern SYS_FUNC(arch_prctl);
+extern SYS_FUNC(bind);
+extern SYS_FUNC(bpf);
+extern SYS_FUNC(brk);
+extern SYS_FUNC(cacheflush);
+extern SYS_FUNC(capget);
+extern SYS_FUNC(capset);
+extern SYS_FUNC(chdir);
+extern SYS_FUNC(chmod);
+extern SYS_FUNC(chown);
+extern SYS_FUNC(clock_adjtime);
+extern SYS_FUNC(clock_gettime);
+extern SYS_FUNC(clock_nanosleep);
+extern SYS_FUNC(clock_settime);
+extern SYS_FUNC(clone);
+extern SYS_FUNC(close);
+extern SYS_FUNC(copy_file_range);
+extern SYS_FUNC(creat);
+extern SYS_FUNC(create_module);
+extern SYS_FUNC(delete_module);
+extern SYS_FUNC(dup);
+extern SYS_FUNC(dup2);
+extern SYS_FUNC(dup3);
+extern SYS_FUNC(epoll_create);
+extern SYS_FUNC(epoll_create1);
+extern SYS_FUNC(epoll_ctl);
+extern SYS_FUNC(epoll_pwait);
+extern SYS_FUNC(epoll_wait);
+extern SYS_FUNC(eventfd);
+extern SYS_FUNC(eventfd2);
+extern SYS_FUNC(execv);
+extern SYS_FUNC(execve);
+extern SYS_FUNC(execveat);
+extern SYS_FUNC(exit);
+extern SYS_FUNC(faccessat);
+extern SYS_FUNC(fadvise64);
+extern SYS_FUNC(fadvise64_64);
+extern SYS_FUNC(fallocate);
+extern SYS_FUNC(fanotify_init);
+extern SYS_FUNC(fanotify_mark);
+extern SYS_FUNC(fchmod);
+extern SYS_FUNC(fchmodat);
+extern SYS_FUNC(fchown);
+extern SYS_FUNC(fchownat);
+extern SYS_FUNC(fcntl);
+extern SYS_FUNC(fcntl64);
+extern SYS_FUNC(fgetxattr);
+extern SYS_FUNC(finit_module);
+extern SYS_FUNC(flistxattr);
+extern SYS_FUNC(flock);
+extern SYS_FUNC(fork);
+extern SYS_FUNC(fremovexattr);
+extern SYS_FUNC(fsetxattr);
+extern SYS_FUNC(fstat);
+extern SYS_FUNC(fstat64);
+extern SYS_FUNC(fstatfs);
+extern SYS_FUNC(fstatfs64);
+extern SYS_FUNC(ftruncate);
+extern SYS_FUNC(ftruncate64);
+extern SYS_FUNC(futex);
+extern SYS_FUNC(futimesat);
+extern SYS_FUNC(fxstat);
+extern SYS_FUNC(getcpu);
+extern SYS_FUNC(getcwd);
+extern SYS_FUNC(getdents);
+extern SYS_FUNC(getdents64);
+extern SYS_FUNC(getgroups);
+extern SYS_FUNC(gethostname);
+extern SYS_FUNC(getitimer);
+extern SYS_FUNC(get_mempolicy);
+extern SYS_FUNC(getpagesize);
+extern SYS_FUNC(getpriority);
+extern SYS_FUNC(getrandom);
+extern SYS_FUNC(getresuid);
+extern SYS_FUNC(getrlimit);
+extern SYS_FUNC(get_robust_list);
+extern SYS_FUNC(getrusage);
+extern SYS_FUNC(getsockname);
+extern SYS_FUNC(getsockopt);
+extern SYS_FUNC(get_thread_area);
+extern SYS_FUNC(gettimeofday);
+extern SYS_FUNC(getuid);
+extern SYS_FUNC(getxattr);
+extern SYS_FUNC(getxgid);
+extern SYS_FUNC(getxpid);
+extern SYS_FUNC(getxuid);
+extern SYS_FUNC(init_module);
+extern SYS_FUNC(inotify_add_watch);
+extern SYS_FUNC(inotify_init1);
+extern SYS_FUNC(inotify_rm_watch);
+extern SYS_FUNC(io_cancel);
+extern SYS_FUNC(ioctl);
+extern SYS_FUNC(io_destroy);
+extern SYS_FUNC(io_getevents);
+extern SYS_FUNC(ioperm);
+extern SYS_FUNC(iopl);
+extern SYS_FUNC(ioprio_get);
+extern SYS_FUNC(ioprio_set);
+extern SYS_FUNC(io_setup);
+extern SYS_FUNC(io_submit);
+extern SYS_FUNC(ipc);
+extern SYS_FUNC(kcmp);
+extern SYS_FUNC(kexec_file_load);
+extern SYS_FUNC(kexec_load);
+extern SYS_FUNC(keyctl);
+extern SYS_FUNC(kill);
+extern SYS_FUNC(link);
+extern SYS_FUNC(linkat);
+extern SYS_FUNC(listen);
+extern SYS_FUNC(listxattr);
+extern SYS_FUNC(llseek);
+extern SYS_FUNC(lookup_dcookie);
+extern SYS_FUNC(lseek);
+extern SYS_FUNC(madvise);
+extern SYS_FUNC(mbind);
+extern SYS_FUNC(membarrier);
+extern SYS_FUNC(memfd_create);
+extern SYS_FUNC(migrate_pages);
+extern SYS_FUNC(mincore);
+extern SYS_FUNC(mknod);
+extern SYS_FUNC(mknodat);
+extern SYS_FUNC(mlock2);
+extern SYS_FUNC(mlockall);
+extern SYS_FUNC(mmap);
+extern SYS_FUNC(mmap_4koff);
+extern SYS_FUNC(mmap_pgoff);
+extern SYS_FUNC(modify_ldt);
+extern SYS_FUNC(mount);
+extern SYS_FUNC(move_pages);
+extern SYS_FUNC(mprotect);
+extern SYS_FUNC(mq_getsetattr);
+extern SYS_FUNC(mq_notify);
+extern SYS_FUNC(mq_open);
+extern SYS_FUNC(mq_timedreceive);
+extern SYS_FUNC(mq_timedsend);
+extern SYS_FUNC(mremap);
+extern SYS_FUNC(msgctl);
+extern SYS_FUNC(msgget);
+extern SYS_FUNC(msgrcv);
+extern SYS_FUNC(msgsnd);
+extern SYS_FUNC(msync);
+extern SYS_FUNC(munmap);
+extern SYS_FUNC(name_to_handle_at);
+extern SYS_FUNC(nanosleep);
+extern SYS_FUNC(newfstatat);
+extern SYS_FUNC(oldfstat);
+extern SYS_FUNC(old_mmap);
+extern SYS_FUNC(old_mmap_pgoff);
+extern SYS_FUNC(oldselect);
+extern SYS_FUNC(oldstat);
+extern SYS_FUNC(open);
+extern SYS_FUNC(openat);
+extern SYS_FUNC(open_by_handle_at);
+extern SYS_FUNC(or1k_atomic);
+extern SYS_FUNC(osf_fstatfs);
+extern SYS_FUNC(osf_getitimer);
+extern SYS_FUNC(osf_getrusage);
+extern SYS_FUNC(osf_gettimeofday);
+extern SYS_FUNC(osf_select);
+extern SYS_FUNC(osf_setitimer);
+extern SYS_FUNC(osf_settimeofday);
+extern SYS_FUNC(osf_statfs);
+extern SYS_FUNC(osf_utimes);
+extern SYS_FUNC(osf_wait4);
+extern SYS_FUNC(perf_event_open);
+extern SYS_FUNC(personality);
+extern SYS_FUNC(pipe);
+extern SYS_FUNC(pipe2);
+extern SYS_FUNC(poll);
+extern SYS_FUNC(ppoll);
+extern SYS_FUNC(prctl);
+extern SYS_FUNC(pread);
+extern SYS_FUNC(preadv);
+extern SYS_FUNC(preadv2);
+extern SYS_FUNC(prlimit64);
+extern SYS_FUNC(process_vm_readv);
+extern SYS_FUNC(process_vm_writev);
+extern SYS_FUNC(pselect6);
+extern SYS_FUNC(ptrace);
+extern SYS_FUNC(pwrite);
+extern SYS_FUNC(pwritev);
+extern SYS_FUNC(pwritev2);
+extern SYS_FUNC(quotactl);
+extern SYS_FUNC(read);
+extern SYS_FUNC(readahead);
+extern SYS_FUNC(readdir);
+extern SYS_FUNC(readlink);
+extern SYS_FUNC(readlinkat);
+extern SYS_FUNC(readv);
+extern SYS_FUNC(reboot);
+extern SYS_FUNC(recv);
+extern SYS_FUNC(recvfrom);
+extern SYS_FUNC(recvmmsg);
+extern SYS_FUNC(recvmsg);
+extern SYS_FUNC(remap_file_pages);
+extern SYS_FUNC(removexattr);
+extern SYS_FUNC(renameat);
+extern SYS_FUNC(renameat2);
+extern SYS_FUNC(request_key);
+extern SYS_FUNC(restart_syscall);
+extern SYS_FUNC(rt_sigaction);
+extern SYS_FUNC(rt_sigpending);
+extern SYS_FUNC(rt_sigprocmask);
+extern SYS_FUNC(rt_sigqueueinfo);
+extern SYS_FUNC(rt_sigsuspend);
+extern SYS_FUNC(rt_sigtimedwait);
+extern SYS_FUNC(rt_tgsigqueueinfo);
+extern SYS_FUNC(sched_getaffinity);
+extern SYS_FUNC(sched_getattr);
+extern SYS_FUNC(sched_getparam);
+extern SYS_FUNC(sched_get_priority_min);
+extern SYS_FUNC(sched_getscheduler);
+extern SYS_FUNC(sched_rr_get_interval);
+extern SYS_FUNC(sched_setaffinity);
+extern SYS_FUNC(sched_setattr);
+extern SYS_FUNC(sched_setparam);
+extern SYS_FUNC(sched_setscheduler);
+extern SYS_FUNC(seccomp);
+extern SYS_FUNC(select);
+extern SYS_FUNC(semctl);
+extern SYS_FUNC(semget);
+extern SYS_FUNC(semop);
+extern SYS_FUNC(semtimedop);
+extern SYS_FUNC(send);
+extern SYS_FUNC(sendfile);
+extern SYS_FUNC(sendfile64);
+extern SYS_FUNC(sendmmsg);
+extern SYS_FUNC(sendmsg);
+extern SYS_FUNC(sendto);
+extern SYS_FUNC(setfsuid);
+extern SYS_FUNC(setgroups);
+extern SYS_FUNC(sethostname);
+extern SYS_FUNC(setitimer);
+extern SYS_FUNC(set_mempolicy);
+extern SYS_FUNC(setns);
+extern SYS_FUNC(setpriority);
+extern SYS_FUNC(setresuid);
+extern SYS_FUNC(setreuid);
+extern SYS_FUNC(setrlimit);
+extern SYS_FUNC(setsockopt);
+extern SYS_FUNC(set_thread_area);
+extern SYS_FUNC(settimeofday);
+extern SYS_FUNC(setuid);
+extern SYS_FUNC(setxattr);
+extern SYS_FUNC(shmat);
+extern SYS_FUNC(shmctl);
+extern SYS_FUNC(shmdt);
+extern SYS_FUNC(shmget);
+extern SYS_FUNC(shutdown);
+extern SYS_FUNC(sigaction);
+extern SYS_FUNC(sigaltstack);
+extern SYS_FUNC(siggetmask);
+extern SYS_FUNC(signal);
+extern SYS_FUNC(signalfd);
+extern SYS_FUNC(signalfd4);
+extern SYS_FUNC(sigpending);
+extern SYS_FUNC(sigprocmask);
+extern SYS_FUNC(sigreturn);
+extern SYS_FUNC(sigsetmask);
+extern SYS_FUNC(sigsuspend);
+extern SYS_FUNC(socket);
+extern SYS_FUNC(socketcall);
+extern SYS_FUNC(socketpair);
+extern SYS_FUNC(splice);
+extern SYS_FUNC(sram_alloc);
+extern SYS_FUNC(stat);
+extern SYS_FUNC(stat64);
+extern SYS_FUNC(statfs);
+extern SYS_FUNC(statfs64);
+extern SYS_FUNC(subpage_prot);
+extern SYS_FUNC(swapon);
+extern SYS_FUNC(symlinkat);
+extern SYS_FUNC(sync_file_range);
+extern SYS_FUNC(sync_file_range2);
+extern SYS_FUNC(sysctl);
+extern SYS_FUNC(sysinfo);
+extern SYS_FUNC(syslog);
+extern SYS_FUNC(sysmips);
+extern SYS_FUNC(tee);
+extern SYS_FUNC(tgkill);
+extern SYS_FUNC(time);
+extern SYS_FUNC(timer_create);
+extern SYS_FUNC(timerfd_create);
+extern SYS_FUNC(timerfd_gettime);
+extern SYS_FUNC(timerfd_settime);
+extern SYS_FUNC(timer_gettime);
+extern SYS_FUNC(timer_settime);
+extern SYS_FUNC(times);
+extern SYS_FUNC(truncate);
+extern SYS_FUNC(truncate64);
+extern SYS_FUNC(umask);
+extern SYS_FUNC(umount2);
+extern SYS_FUNC(uname);
+extern SYS_FUNC(unlinkat);
+extern SYS_FUNC(unshare);
+extern SYS_FUNC(userfaultfd);
+extern SYS_FUNC(utime);
+extern SYS_FUNC(utimensat);
+extern SYS_FUNC(utimes);
+extern SYS_FUNC(vmsplice);
+extern SYS_FUNC(wait4);
+extern SYS_FUNC(waitid);
+extern SYS_FUNC(waitpid);
+extern SYS_FUNC(write);
+extern SYS_FUNC(writev);
+extern SYS_FUNC(xstat);
diff --git a/strace/syscall.c b/strace/syscall.c
new file mode 100644
index 0000000..6af0dec
--- /dev/null
+++ b/strace/syscall.c
@@ -0,0 +1,1345 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 1999 IBM Deutschland Entwicklung GmbH, IBM Corporation
+ *                     Linux for s390 port by D.J. Barrow
+ *                    <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * 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 "native_defs.h"
+#include <sys/param.h>
+#include <signal.h>
+
+/* for struct iovec */
+#include <sys/uio.h>
+
+#include "regs.h"
+#include "ptrace.h"
+
+#if defined(SPARC64)
+# undef PTRACE_GETREGS
+# define PTRACE_GETREGS PTRACE_GETREGS64
+# undef PTRACE_SETREGS
+# define PTRACE_SETREGS PTRACE_SETREGS64
+#endif
+
+#if defined SPARC64
+# include <asm/psrcompat.h>
+#elif defined SPARC
+# include <asm/psr.h>
+#endif
+
+#ifdef IA64
+# include <asm/rse.h>
+#endif
+
+#ifndef NT_PRSTATUS
+# define NT_PRSTATUS 1
+#endif
+
+#ifndef NSIG
+# warning: NSIG is not defined, using 32
+# define NSIG 32
+#endif
+
+#include "syscall.h"
+
+/* Define these shorthand notations to simplify the syscallent files. */
+#define TD TRACE_DESC
+#define TF TRACE_FILE
+#define TI TRACE_IPC
+#define TN TRACE_NETWORK
+#define TP TRACE_PROCESS
+#define TS TRACE_SIGNAL
+#define TM TRACE_MEMORY
+#define NF SYSCALL_NEVER_FAILS
+#define MA MAX_ARGS
+#define SI STACKTRACE_INVALIDATE_CACHE
+#define SE STACKTRACE_CAPTURE_ON_ENTER
+
+#define SEN(syscall_name) SEN_ ## syscall_name, SYS_FUNC_NAME(sys_ ## syscall_name)
+
+const struct_sysent sysent0[] = {
+#include "syscallent.h"
+};
+
+#if SUPPORTED_PERSONALITIES > 1
+# include PERSONALITY1_INCLUDE_FUNCS
+static const struct_sysent sysent1[] = {
+# include "syscallent1.h"
+};
+#endif
+
+#if SUPPORTED_PERSONALITIES > 2
+# include PERSONALITY2_INCLUDE_FUNCS
+static const struct_sysent sysent2[] = {
+# include "syscallent2.h"
+};
+#endif
+
+/* Now undef them since short defines cause wicked namespace pollution. */
+#undef SEN
+#undef TD
+#undef TF
+#undef TI
+#undef TN
+#undef TP
+#undef TS
+#undef TM
+#undef NF
+#undef MA
+#undef SI
+#undef SE
+
+/*
+ * `ioctlent[012].h' files are automatically generated by the auxiliary
+ * program `ioctlsort', such that the list is sorted by the `code' field.
+ * This has the side-effect of resolving the _IO.. macros into
+ * plain integers, eliminating the need to include here everything
+ * in "/usr/include".
+ */
+
+const char *const errnoent0[] = {
+#include "errnoent.h"
+};
+const char *const signalent0[] = {
+#include "signalent.h"
+};
+const struct_ioctlent ioctlent0[] = {
+#include "ioctlent0.h"
+};
+
+#if SUPPORTED_PERSONALITIES > 1
+static const char *const errnoent1[] = {
+# include "errnoent1.h"
+};
+static const char *const signalent1[] = {
+# include "signalent1.h"
+};
+static const struct_ioctlent ioctlent1[] = {
+# include "ioctlent1.h"
+};
+# include PERSONALITY0_INCLUDE_PRINTERS_DECLS
+static const struct_printers printers0 = {
+# include PERSONALITY0_INCLUDE_PRINTERS_DEFS
+};
+# include PERSONALITY1_INCLUDE_PRINTERS_DECLS
+static const struct_printers printers1 = {
+# include PERSONALITY1_INCLUDE_PRINTERS_DEFS
+};
+#endif
+
+#if SUPPORTED_PERSONALITIES > 2
+static const char *const errnoent2[] = {
+# include "errnoent2.h"
+};
+static const char *const signalent2[] = {
+# include "signalent2.h"
+};
+static const struct_ioctlent ioctlent2[] = {
+# include "ioctlent2.h"
+};
+# include PERSONALITY2_INCLUDE_PRINTERS_DECLS
+static const struct_printers printers2 = {
+# include PERSONALITY2_INCLUDE_PRINTERS_DEFS
+};
+#endif
+
+enum {
+	nsyscalls0 = ARRAY_SIZE(sysent0)
+#if SUPPORTED_PERSONALITIES > 1
+	, nsyscalls1 = ARRAY_SIZE(sysent1)
+# if SUPPORTED_PERSONALITIES > 2
+	, nsyscalls2 = ARRAY_SIZE(sysent2)
+# endif
+#endif
+};
+
+enum {
+	nerrnos0 = ARRAY_SIZE(errnoent0)
+#if SUPPORTED_PERSONALITIES > 1
+	, nerrnos1 = ARRAY_SIZE(errnoent1)
+# if SUPPORTED_PERSONALITIES > 2
+	, nerrnos2 = ARRAY_SIZE(errnoent2)
+# endif
+#endif
+};
+
+enum {
+	nsignals0 = ARRAY_SIZE(signalent0)
+#if SUPPORTED_PERSONALITIES > 1
+	, nsignals1 = ARRAY_SIZE(signalent1)
+# if SUPPORTED_PERSONALITIES > 2
+	, nsignals2 = ARRAY_SIZE(signalent2)
+# endif
+#endif
+};
+
+enum {
+	nioctlents0 = ARRAY_SIZE(ioctlent0)
+#if SUPPORTED_PERSONALITIES > 1
+	, nioctlents1 = ARRAY_SIZE(ioctlent1)
+# if SUPPORTED_PERSONALITIES > 2
+	, nioctlents2 = ARRAY_SIZE(ioctlent2)
+# endif
+#endif
+};
+
+#if SUPPORTED_PERSONALITIES > 1
+const struct_sysent *sysent = sysent0;
+const char *const *errnoent = errnoent0;
+const char *const *signalent = signalent0;
+const struct_ioctlent *ioctlent = ioctlent0;
+const struct_printers *printers = &printers0;
+#endif
+
+unsigned nsyscalls = nsyscalls0;
+unsigned nerrnos = nerrnos0;
+unsigned nsignals = nsignals0;
+unsigned nioctlents = nioctlents0;
+
+unsigned num_quals;
+qualbits_t *qual_vec[SUPPORTED_PERSONALITIES];
+
+static const unsigned nsyscall_vec[SUPPORTED_PERSONALITIES] = {
+	nsyscalls0,
+#if SUPPORTED_PERSONALITIES > 1
+	nsyscalls1,
+#endif
+#if SUPPORTED_PERSONALITIES > 2
+	nsyscalls2,
+#endif
+};
+static const struct_sysent *const sysent_vec[SUPPORTED_PERSONALITIES] = {
+	sysent0,
+#if SUPPORTED_PERSONALITIES > 1
+	sysent1,
+#endif
+#if SUPPORTED_PERSONALITIES > 2
+	sysent2,
+#endif
+};
+
+enum {
+	MAX_NSYSCALLS1 = (nsyscalls0
+#if SUPPORTED_PERSONALITIES > 1
+			> nsyscalls1 ? nsyscalls0 : nsyscalls1
+#endif
+			),
+	MAX_NSYSCALLS2 = (MAX_NSYSCALLS1
+#if SUPPORTED_PERSONALITIES > 2
+			> nsyscalls2 ? MAX_NSYSCALLS1 : nsyscalls2
+#endif
+			),
+	MAX_NSYSCALLS = MAX_NSYSCALLS2,
+	/* We are ready for arches with up to 255 signals,
+	 * even though the largest known signo is on MIPS and it is 128.
+	 * The number of existing syscalls on all arches is
+	 * larger that 255 anyway, so it is just a pedantic matter.
+	 */
+	MIN_QUALS = MAX_NSYSCALLS > 255 ? MAX_NSYSCALLS : 255
+};
+
+#if SUPPORTED_PERSONALITIES > 1
+unsigned current_personality;
+
+# ifndef current_wordsize
+unsigned current_wordsize;
+static const int personality_wordsize[SUPPORTED_PERSONALITIES] = {
+	PERSONALITY0_WORDSIZE,
+	PERSONALITY1_WORDSIZE,
+# if SUPPORTED_PERSONALITIES > 2
+	PERSONALITY2_WORDSIZE,
+# endif
+};
+# endif
+
+void
+set_personality(int personality)
+{
+	nsyscalls = nsyscall_vec[personality];
+	sysent = sysent_vec[personality];
+
+	switch (personality) {
+	case 0:
+		errnoent = errnoent0;
+		nerrnos = nerrnos0;
+		ioctlent = ioctlent0;
+		nioctlents = nioctlents0;
+		signalent = signalent0;
+		nsignals = nsignals0;
+		printers = &printers0;
+		break;
+
+	case 1:
+		errnoent = errnoent1;
+		nerrnos = nerrnos1;
+		ioctlent = ioctlent1;
+		nioctlents = nioctlents1;
+		signalent = signalent1;
+		nsignals = nsignals1;
+		printers = &printers1;
+		break;
+
+# if SUPPORTED_PERSONALITIES > 2
+	case 2:
+		errnoent = errnoent2;
+		nerrnos = nerrnos2;
+		ioctlent = ioctlent2;
+		nioctlents = nioctlents2;
+		signalent = signalent2;
+		nsignals = nsignals2;
+		printers = &printers2;
+		break;
+# endif
+	}
+
+	current_personality = personality;
+# ifndef current_wordsize
+	current_wordsize = personality_wordsize[personality];
+# endif
+}
+
+static void
+update_personality(struct tcb *tcp, unsigned int personality)
+{
+	if (personality == current_personality)
+		return;
+	set_personality(personality);
+
+	if (personality == tcp->currpers)
+		return;
+	tcp->currpers = personality;
+
+# undef PERSONALITY_NAMES
+# if defined POWERPC64
+#  define PERSONALITY_NAMES {"64 bit", "32 bit"}
+# elif defined X86_64
+#  define PERSONALITY_NAMES {"64 bit", "32 bit", "x32"}
+# elif defined X32
+#  define PERSONALITY_NAMES {"x32", "32 bit"}
+# elif defined AARCH64
+#  define PERSONALITY_NAMES {"64 bit", "32 bit"}
+# elif defined TILE
+#  define PERSONALITY_NAMES {"64-bit", "32-bit"}
+# endif
+# ifdef PERSONALITY_NAMES
+	if (!qflag) {
+		static const char *const names[] = PERSONALITY_NAMES;
+		error_msg("[ Process PID=%d runs in %s mode. ]",
+			  tcp->pid, names[personality]);
+	}
+# endif
+}
+#endif
+
+static int qual_syscall(), qual_signal(), qual_desc();
+
+static const struct qual_options {
+	unsigned int bitflag;
+	const char *option_name;
+	int (*qualify)(const char *, int, int);
+	const char *argument_name;
+} qual_options[] = {
+	{ QUAL_TRACE,	"trace",	qual_syscall,	"system call"	},
+	{ QUAL_TRACE,	"t",		qual_syscall,	"system call"	},
+	{ QUAL_ABBREV,	"abbrev",	qual_syscall,	"system call"	},
+	{ QUAL_ABBREV,	"a",		qual_syscall,	"system call"	},
+	{ QUAL_VERBOSE,	"verbose",	qual_syscall,	"system call"	},
+	{ QUAL_VERBOSE,	"v",		qual_syscall,	"system call"	},
+	{ QUAL_RAW,	"raw",		qual_syscall,	"system call"	},
+	{ QUAL_RAW,	"x",		qual_syscall,	"system call"	},
+	{ QUAL_SIGNAL,	"signal",	qual_signal,	"signal"	},
+	{ QUAL_SIGNAL,	"signals",	qual_signal,	"signal"	},
+	{ QUAL_SIGNAL,	"s",		qual_signal,	"signal"	},
+	{ QUAL_READ,	"read",		qual_desc,	"descriptor"	},
+	{ QUAL_READ,	"reads",	qual_desc,	"descriptor"	},
+	{ QUAL_READ,	"r",		qual_desc,	"descriptor"	},
+	{ QUAL_WRITE,	"write",	qual_desc,	"descriptor"	},
+	{ QUAL_WRITE,	"writes",	qual_desc,	"descriptor"	},
+	{ QUAL_WRITE,	"w",		qual_desc,	"descriptor"	},
+	{ 0,		NULL,		NULL,		NULL		},
+};
+
+static void
+reallocate_qual(const unsigned int n)
+{
+	unsigned p;
+	qualbits_t *qp;
+	for (p = 0; p < SUPPORTED_PERSONALITIES; p++) {
+		qp = qual_vec[p] = xreallocarray(qual_vec[p], n,
+						 sizeof(qualbits_t));
+		memset(&qp[num_quals], 0, (n - num_quals) * sizeof(qualbits_t));
+	}
+	num_quals = n;
+}
+
+static void
+qualify_one(const unsigned int n, unsigned int bitflag, const int not, const int pers)
+{
+	int p;
+
+	if (num_quals <= n)
+		reallocate_qual(n + 1);
+
+	for (p = 0; p < SUPPORTED_PERSONALITIES; p++) {
+		if (pers == p || pers < 0) {
+			if (not)
+				qual_vec[p][n] &= ~bitflag;
+			else
+				qual_vec[p][n] |= bitflag;
+		}
+	}
+}
+
+static int
+qual_syscall(const char *s, const unsigned int bitflag, const int not)
+{
+	int p;
+	unsigned int i;
+	int rc = -1;
+
+	if (*s >= '0' && *s <= '9') {
+		i = string_to_uint(s);
+		if (i >= MAX_NSYSCALLS)
+			return -1;
+		qualify_one(i, bitflag, not, -1);
+		return 0;
+	}
+
+	for (p = 0; p < SUPPORTED_PERSONALITIES; p++) {
+		for (i = 0; i < nsyscall_vec[p]; i++) {
+			if (sysent_vec[p][i].sys_name
+			 && strcmp(s, sysent_vec[p][i].sys_name) == 0
+			) {
+				qualify_one(i, bitflag, not, p);
+				rc = 0;
+			}
+		}
+	}
+
+	return rc;
+}
+
+static int
+qual_signal(const char *s, const unsigned int bitflag, const int not)
+{
+	unsigned int i;
+
+	if (*s >= '0' && *s <= '9') {
+		int signo = string_to_uint(s);
+		if (signo < 0 || signo > 255)
+			return -1;
+		qualify_one(signo, bitflag, not, -1);
+		return 0;
+	}
+	if (strncasecmp(s, "SIG", 3) == 0)
+		s += 3;
+	for (i = 0; i <= NSIG; i++) {
+		if (strcasecmp(s, signame(i) + 3) == 0) {
+			qualify_one(i, bitflag, not, -1);
+			return 0;
+		}
+	}
+	return -1;
+}
+
+static int
+qual_desc(const char *s, const unsigned int bitflag, const int not)
+{
+	if (*s >= '0' && *s <= '9') {
+		int desc = string_to_uint(s);
+		if (desc < 0 || desc > 0x7fff) /* paranoia */
+			return -1;
+		qualify_one(desc, bitflag, not, -1);
+		return 0;
+	}
+	return -1;
+}
+
+static int
+lookup_class(const char *s)
+{
+	if (strcmp(s, "file") == 0)
+		return TRACE_FILE;
+	if (strcmp(s, "ipc") == 0)
+		return TRACE_IPC;
+	if (strcmp(s, "network") == 0)
+		return TRACE_NETWORK;
+	if (strcmp(s, "process") == 0)
+		return TRACE_PROCESS;
+	if (strcmp(s, "signal") == 0)
+		return TRACE_SIGNAL;
+	if (strcmp(s, "desc") == 0)
+		return TRACE_DESC;
+	if (strcmp(s, "memory") == 0)
+		return TRACE_MEMORY;
+	return -1;
+}
+
+void
+qualify(const char *s)
+{
+	const struct qual_options *opt;
+	char *copy;
+	const char *p;
+	int not;
+	unsigned int i;
+
+	if (num_quals == 0)
+		reallocate_qual(MIN_QUALS);
+
+	opt = &qual_options[0];
+	for (i = 0; (p = qual_options[i].option_name); i++) {
+		unsigned int len = strlen(p);
+		if (strncmp(s, p, len) == 0 && s[len] == '=') {
+			opt = &qual_options[i];
+			s += len + 1;
+			break;
+		}
+	}
+	not = 0;
+	if (*s == '!') {
+		not = 1;
+		s++;
+	}
+	if (strcmp(s, "none") == 0) {
+		not = 1 - not;
+		s = "all";
+	}
+	if (strcmp(s, "all") == 0) {
+		for (i = 0; i < num_quals; i++) {
+			qualify_one(i, opt->bitflag, not, -1);
+		}
+		return;
+	}
+	for (i = 0; i < num_quals; i++) {
+		qualify_one(i, opt->bitflag, !not, -1);
+	}
+	copy = xstrdup(s);
+	for (p = strtok(copy, ","); p; p = strtok(NULL, ",")) {
+		int n;
+		if (opt->bitflag == QUAL_TRACE && (n = lookup_class(p)) > 0) {
+			unsigned pers;
+			for (pers = 0; pers < SUPPORTED_PERSONALITIES; pers++) {
+				for (i = 0; i < nsyscall_vec[pers]; i++)
+					if (sysent_vec[pers][i].sys_flags & n)
+						qualify_one(i, opt->bitflag, not, pers);
+			}
+			continue;
+		}
+		if (opt->qualify(p, opt->bitflag, not)) {
+			error_msg_and_die("invalid %s '%s'",
+				opt->argument_name, p);
+		}
+	}
+	free(copy);
+	return;
+}
+
+#ifdef SYS_socket_subcall
+static void
+decode_socket_subcall(struct tcb *tcp)
+{
+	const int call = tcp->u_arg[0];
+
+	if (call < 1 || call >= SYS_socket_nsubcalls)
+		return;
+
+	const unsigned long scno = SYS_socket_subcall + call;
+	const unsigned int nargs = sysent[scno].nargs;
+	uint64_t buf[nargs];
+
+	if (umoven(tcp, tcp->u_arg[1], nargs * current_wordsize, buf) < 0)
+		return;
+
+	tcp->scno = scno;
+	tcp->qual_flg = qual_flags[scno];
+	tcp->s_ent = &sysent[scno];
+
+	unsigned int i;
+	for (i = 0; i < nargs; ++i)
+		tcp->u_arg[i] = (sizeof(uint32_t) == current_wordsize)
+				? ((uint32_t *) (void *) buf)[i] : buf[i];
+}
+#endif
+
+#ifdef SYS_ipc_subcall
+static void
+decode_ipc_subcall(struct tcb *tcp)
+{
+	unsigned int call = tcp->u_arg[0];
+	const unsigned int version = call >> 16;
+
+	if (version) {
+# if defined S390 || defined S390X
+		return;
+# else
+#  ifdef SPARC64
+		if (current_wordsize == 8)
+			return;
+#  endif
+		set_tcb_priv_ulong(tcp, version);
+		call &= 0xffff;
+# endif
+	}
+
+	switch (call) {
+		case  1: case  2: case  3: case  4:
+		case 11: case 12: case 13: case 14:
+		case 21: case 22: case 23: case 24:
+			break;
+		default:
+			return;
+	}
+
+	tcp->scno = SYS_ipc_subcall + call;
+	tcp->qual_flg = qual_flags[tcp->scno];
+	tcp->s_ent = &sysent[tcp->scno];
+
+	const unsigned int n = tcp->s_ent->nargs;
+	unsigned int i;
+	for (i = 0; i < n; i++)
+		tcp->u_arg[i] = tcp->u_arg[i + 1];
+}
+#endif
+
+#ifdef LINUX_MIPSO32
+static void
+decode_mips_subcall(struct tcb *tcp)
+{
+	if (!SCNO_IS_VALID(tcp->u_arg[0]))
+		return;
+	tcp->scno = tcp->u_arg[0];
+	tcp->qual_flg = qual_flags[tcp->scno];
+	tcp->s_ent = &sysent[tcp->scno];
+	memmove(&tcp->u_arg[0], &tcp->u_arg[1],
+		sizeof(tcp->u_arg) - sizeof(tcp->u_arg[0]));
+	/*
+	 * Fetching the last arg of 7-arg syscalls (fadvise64_64
+	 * and sync_file_range) would require additional code,
+	 * see linux/mips/get_syscall_args.c
+	 */
+}
+#endif
+
+static void
+dumpio(struct tcb *tcp)
+{
+	int sen;
+
+	if (syserror(tcp))
+		return;
+	if ((unsigned long) tcp->u_arg[0] >= num_quals)
+		return;
+	sen = tcp->s_ent->sen;
+	if (SEN_printargs == sen)
+		return;
+	if (qual_flags[tcp->u_arg[0]] & QUAL_READ) {
+		switch (sen) {
+		case SEN_read:
+		case SEN_pread:
+		case SEN_recv:
+		case SEN_recvfrom:
+			dumpstr(tcp, tcp->u_arg[1], tcp->u_rval);
+			return;
+		case SEN_readv:
+		case SEN_preadv:
+		case SEN_preadv2:
+			dumpiov_upto(tcp, tcp->u_arg[2], tcp->u_arg[1],
+				     tcp->u_rval);
+			return;
+		case SEN_recvmsg:
+			dumpiov_in_msghdr(tcp, tcp->u_arg[1], tcp->u_rval);
+			return;
+		case SEN_recvmmsg:
+			dumpiov_in_mmsghdr(tcp, tcp->u_arg[1]);
+			return;
+		}
+	}
+	if (qual_flags[tcp->u_arg[0]] & QUAL_WRITE) {
+		switch (sen) {
+		case SEN_write:
+		case SEN_pwrite:
+		case SEN_send:
+		case SEN_sendto:
+			dumpstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+			break;
+		case SEN_writev:
+		case SEN_pwritev:
+		case SEN_pwritev2:
+		case SEN_vmsplice:
+			dumpiov(tcp, tcp->u_arg[2], tcp->u_arg[1]);
+			break;
+		case SEN_sendmsg:
+			dumpiov_in_msghdr(tcp, tcp->u_arg[1],
+					  (unsigned long) -1L);
+			break;
+		case SEN_sendmmsg:
+			dumpiov_in_mmsghdr(tcp, tcp->u_arg[1]);
+			break;
+		}
+	}
+}
+
+/*
+ * Shuffle syscall numbers so that we don't have huge gaps in syscall table.
+ * The shuffling should be an involution: shuffle_scno(shuffle_scno(n)) == n.
+ */
+#if defined(ARM) || defined(AARCH64) /* So far only 32-bit ARM needs this */
+static long
+shuffle_scno(unsigned long scno)
+{
+	if (scno < ARM_FIRST_SHUFFLED_SYSCALL)
+		return scno;
+
+	/* __ARM_NR_cmpxchg? Swap with LAST_ORDINARY+1 */
+	if (scno == ARM_FIRST_SHUFFLED_SYSCALL)
+		return 0x000ffff0;
+	if (scno == 0x000ffff0)
+		return ARM_FIRST_SHUFFLED_SYSCALL;
+
+#define ARM_SECOND_SHUFFLED_SYSCALL (ARM_FIRST_SHUFFLED_SYSCALL + 1)
+	/*
+	 * Is it ARM specific syscall?
+	 * Swap [0x000f0000, 0x000f0000 + LAST_SPECIAL] range
+	 * with [SECOND_SHUFFLED, SECOND_SHUFFLED + LAST_SPECIAL] range.
+	 */
+	if (scno >= 0x000f0000 &&
+	    scno <= 0x000f0000 + ARM_LAST_SPECIAL_SYSCALL) {
+		return scno - 0x000f0000 + ARM_SECOND_SHUFFLED_SYSCALL;
+	}
+	if (scno <= ARM_SECOND_SHUFFLED_SYSCALL + ARM_LAST_SPECIAL_SYSCALL) {
+		return scno + 0x000f0000 - ARM_SECOND_SHUFFLED_SYSCALL;
+	}
+
+	return scno;
+}
+#else
+# define shuffle_scno(scno) ((long)(scno))
+#endif
+
+const char *
+syscall_name(long scno)
+{
+	static char buf[sizeof("syscall_%lu") + sizeof(long)*3];
+
+	if (SCNO_IS_VALID(scno))
+		return sysent[scno].sys_name;
+	else {
+		sprintf(buf, "syscall_%lu", shuffle_scno(scno));
+		return buf;
+	}
+}
+
+static long get_regs_error;
+
+void
+clear_regs(void)
+{
+	get_regs_error = -1;
+}
+
+static int get_syscall_args(struct tcb *);
+static int get_syscall_result(struct tcb *);
+static int arch_get_scno(struct tcb *tcp);
+static void get_error(struct tcb *, const bool);
+#if defined X86_64 || defined POWERPC
+static int getregs_old(pid_t);
+#endif
+
+static int
+trace_syscall_entering(struct tcb *tcp)
+{
+	int res, scno_good;
+
+	scno_good = res = get_scno(tcp);
+	if (res == 0)
+		return res;
+	if (res == 1)
+		res = get_syscall_args(tcp);
+
+	if (res != 1) {
+		printleader(tcp);
+		if (scno_good != 1)
+			tprints("????" /* anti-trigraph gap */ "(");
+		else
+			tprintf("%s(", syscall_name(tcp->scno));
+		/*
+		 * " <unavailable>" will be added later by the code which
+		 * detects ptrace errors.
+		 */
+		goto ret;
+	}
+
+#ifdef LINUX_MIPSO32
+	if (SEN_syscall == tcp->s_ent->sen)
+		decode_mips_subcall(tcp);
+#endif
+
+	if (   SEN_execve == tcp->s_ent->sen
+# if defined(SPARC) || defined(SPARC64)
+	    || SEN_execv == tcp->s_ent->sen
+# endif
+	   ) {
+		hide_log_until_execve = 0;
+	}
+
+#if defined(SYS_socket_subcall) || defined(SYS_ipc_subcall)
+	switch (tcp->s_ent->sen) {
+# ifdef SYS_socket_subcall
+		case SEN_socketcall:
+			decode_socket_subcall(tcp);
+			break;
+# endif
+# ifdef SYS_ipc_subcall
+		case SEN_ipc:
+			decode_ipc_subcall(tcp);
+			break;
+# endif
+	}
+#endif
+
+	if (!(tcp->qual_flg & QUAL_TRACE)
+	 || (tracing_paths && !pathtrace_match(tcp))
+	) {
+		tcp->flags |= TCB_INSYSCALL | TCB_FILTERED;
+		tcp->sys_func_rval = 0;
+		return 0;
+	}
+
+	tcp->flags &= ~TCB_FILTERED;
+
+	if (cflag == CFLAG_ONLY_STATS || hide_log_until_execve) {
+		res = 0;
+		goto ret;
+	}
+
+#ifdef USE_LIBUNWIND
+	if (stack_trace_enabled) {
+		if (tcp->s_ent->sys_flags & STACKTRACE_CAPTURE_ON_ENTER)
+			unwind_capture_stacktrace(tcp);
+	}
+#endif
+
+	printleader(tcp);
+	tprintf("%s(", syscall_name(tcp->scno));
+	if ((tcp->qual_flg & QUAL_RAW) && SEN_exit != tcp->s_ent->sen)
+		res = printargs(tcp);
+	else
+		res = tcp->s_ent->sys_func(tcp);
+
+	fflush(tcp->outf);
+ ret:
+	tcp->flags |= TCB_INSYSCALL;
+	tcp->sys_func_rval = res;
+	/* Measure the entrance time as late as possible to avoid errors. */
+	if (Tflag || cflag)
+		gettimeofday(&tcp->etime, NULL);
+	return res;
+}
+
+static int
+trace_syscall_exiting(struct tcb *tcp)
+{
+	int sys_res;
+	struct timeval tv;
+	int res;
+	long u_error;
+
+	/* Measure the exit time as early as possible to avoid errors. */
+	if (Tflag || cflag)
+		gettimeofday(&tv, NULL);
+
+#ifdef USE_LIBUNWIND
+	if (stack_trace_enabled) {
+		if (tcp->s_ent->sys_flags & STACKTRACE_INVALIDATE_CACHE)
+			unwind_cache_invalidate(tcp);
+	}
+#endif
+
+#if SUPPORTED_PERSONALITIES > 1
+	update_personality(tcp, tcp->currpers);
+#endif
+	res = (get_regs_error ? -1 : get_syscall_result(tcp));
+	if (filtered(tcp) || hide_log_until_execve)
+		goto ret;
+
+	if (cflag) {
+		count_syscall(tcp, &tv);
+		if (cflag == CFLAG_ONLY_STATS) {
+			goto ret;
+		}
+	}
+
+	/* If not in -ff mode, and printing_tcp != tcp,
+	 * then the log currently does not end with output
+	 * of _our syscall entry_, but with something else.
+	 * We need to say which syscall's return is this.
+	 *
+	 * Forced reprinting via TCB_REPRINT is used only by
+	 * "strace -ff -oLOG test/threaded_execve" corner case.
+	 * It's the only case when -ff mode needs reprinting.
+	 */
+	if ((followfork < 2 && printing_tcp != tcp) || (tcp->flags & TCB_REPRINT)) {
+		tcp->flags &= ~TCB_REPRINT;
+		printleader(tcp);
+		tprintf("<... %s resumed> ", syscall_name(tcp->scno));
+	}
+	printing_tcp = tcp;
+
+	tcp->s_prev_ent = NULL;
+	if (res != 1) {
+		/* There was error in one of prior ptrace ops */
+		tprints(") ");
+		tabto();
+		tprints("= ? <unavailable>\n");
+		line_ended();
+		tcp->flags &= ~TCB_INSYSCALL;
+		tcp->sys_func_rval = 0;
+		free_tcb_priv_data(tcp);
+		return res;
+	}
+	tcp->s_prev_ent = tcp->s_ent;
+
+	sys_res = 0;
+	if (tcp->qual_flg & QUAL_RAW) {
+		/* sys_res = printargs(tcp); - but it's nop on sysexit */
+	} else {
+	/* FIXME: not_failing_only (IOW, option -z) is broken:
+	 * failure of syscall is known only after syscall return.
+	 * Thus we end up with something like this on, say, ENOENT:
+	 *     open("doesnt_exist", O_RDONLY <unfinished ...>
+	 *     {next syscall decode}
+	 * whereas the intended result is that open(...) line
+	 * is not shown at all.
+	 */
+		if (not_failing_only && tcp->u_error)
+			goto ret;	/* ignore failed syscalls */
+		if (tcp->sys_func_rval & RVAL_DECODED)
+			sys_res = tcp->sys_func_rval;
+		else
+			sys_res = tcp->s_ent->sys_func(tcp);
+	}
+
+	tprints(") ");
+	tabto();
+	u_error = tcp->u_error;
+	if (tcp->qual_flg & QUAL_RAW) {
+		if (u_error)
+			tprintf("= -1 (errno %ld)", u_error);
+		else
+			tprintf("= %#lx", tcp->u_rval);
+	}
+	else if (!(sys_res & RVAL_NONE) && u_error) {
+		switch (u_error) {
+		/* Blocked signals do not interrupt any syscalls.
+		 * In this case syscalls don't return ERESTARTfoo codes.
+		 *
+		 * Deadly signals set to SIG_DFL interrupt syscalls
+		 * and kill the process regardless of which of the codes below
+		 * is returned by the interrupted syscall.
+		 * In some cases, kernel forces a kernel-generated deadly
+		 * signal to be unblocked and set to SIG_DFL (and thus cause
+		 * death) if it is blocked or SIG_IGNed: for example, SIGSEGV
+		 * or SIGILL. (The alternative is to leave process spinning
+		 * forever on the faulty instruction - not useful).
+		 *
+		 * SIG_IGNed signals and non-deadly signals set to SIG_DFL
+		 * (for example, SIGCHLD, SIGWINCH) interrupt syscalls,
+		 * but kernel will always restart them.
+		 */
+		case ERESTARTSYS:
+			/* Most common type of signal-interrupted syscall exit code.
+			 * The system call will be restarted with the same arguments
+			 * if SA_RESTART is set; otherwise, it will fail with EINTR.
+			 */
+			tprints("= ? ERESTARTSYS (To be restarted if SA_RESTART is set)");
+			break;
+		case ERESTARTNOINTR:
+			/* Rare. For example, fork() returns this if interrupted.
+			 * SA_RESTART is ignored (assumed set): the restart is unconditional.
+			 */
+			tprints("= ? ERESTARTNOINTR (To be restarted)");
+			break;
+		case ERESTARTNOHAND:
+			/* pause(), rt_sigsuspend() etc use this code.
+			 * SA_RESTART is ignored (assumed not set):
+			 * syscall won't restart (will return EINTR instead)
+			 * even after signal with SA_RESTART set. However,
+			 * after SIG_IGN or SIG_DFL signal it will restart
+			 * (thus the name "restart only if has no handler").
+			 */
+			tprints("= ? ERESTARTNOHAND (To be restarted if no handler)");
+			break;
+		case ERESTART_RESTARTBLOCK:
+			/* Syscalls like nanosleep(), poll() which can't be
+			 * restarted with their original arguments use this
+			 * code. Kernel will execute restart_syscall() instead,
+			 * which changes arguments before restarting syscall.
+			 * SA_RESTART is ignored (assumed not set) similarly
+			 * to ERESTARTNOHAND. (Kernel can't honor SA_RESTART
+			 * since restart data is saved in "restart block"
+			 * in task struct, and if signal handler uses a syscall
+			 * which in turn saves another such restart block,
+			 * old data is lost and restart becomes impossible)
+			 */
+			tprints("= ? ERESTART_RESTARTBLOCK (Interrupted by signal)");
+			break;
+		default:
+			if ((unsigned long) u_error < nerrnos
+			    && errnoent[u_error])
+				tprintf("= -1 %s (%s)", errnoent[u_error],
+					strerror(u_error));
+			else
+				tprintf("= -1 ERRNO_%lu (%s)", u_error,
+					strerror(u_error));
+			break;
+		}
+		if ((sys_res & RVAL_STR) && tcp->auxstr)
+			tprintf(" (%s)", tcp->auxstr);
+	}
+	else {
+		if (sys_res & RVAL_NONE)
+			tprints("= ?");
+		else {
+			switch (sys_res & RVAL_MASK) {
+			case RVAL_HEX:
+#if SUPPORTED_PERSONALITIES > 1
+				if (current_wordsize < sizeof(long))
+					tprintf("= %#x",
+						(unsigned int) tcp->u_rval);
+				else
+#endif
+					tprintf("= %#lx", tcp->u_rval);
+				break;
+			case RVAL_OCTAL:
+				tprintf("= %#lo", tcp->u_rval);
+				break;
+			case RVAL_UDECIMAL:
+#if SUPPORTED_PERSONALITIES > 1
+				if (current_wordsize < sizeof(long))
+					tprintf("= %u",
+						(unsigned int) tcp->u_rval);
+				else
+#endif
+					tprintf("= %lu", tcp->u_rval);
+				break;
+			case RVAL_DECIMAL:
+				tprintf("= %ld", tcp->u_rval);
+				break;
+			case RVAL_FD:
+				if (show_fd_path) {
+					tprints("= ");
+					printfd(tcp, tcp->u_rval);
+				}
+				else
+					tprintf("= %ld", tcp->u_rval);
+				break;
+#if HAVE_STRUCT_TCB_EXT_ARG
+			/*
+			case RVAL_LHEX:
+				tprintf("= %#llx", tcp->u_lrval);
+				break;
+			case RVAL_LOCTAL:
+				tprintf("= %#llo", tcp->u_lrval);
+				break;
+			*/
+			case RVAL_LUDECIMAL:
+				tprintf("= %llu", tcp->u_lrval);
+				break;
+			/*
+			case RVAL_LDECIMAL:
+				tprintf("= %lld", tcp->u_lrval);
+				break;
+			*/
+#endif /* HAVE_STRUCT_TCB_EXT_ARG */
+			default:
+				error_msg("invalid rval format");
+				break;
+			}
+		}
+		if ((sys_res & RVAL_STR) && tcp->auxstr)
+			tprintf(" (%s)", tcp->auxstr);
+	}
+	if (Tflag) {
+		tv_sub(&tv, &tv, &tcp->etime);
+		tprintf(" <%ld.%06ld>",
+			(long) tv.tv_sec, (long) tv.tv_usec);
+	}
+	tprints("\n");
+	dumpio(tcp);
+	line_ended();
+
+#ifdef USE_LIBUNWIND
+	if (stack_trace_enabled)
+		unwind_print_stacktrace(tcp);
+#endif
+
+ ret:
+	tcp->flags &= ~TCB_INSYSCALL;
+	tcp->sys_func_rval = 0;
+	free_tcb_priv_data(tcp);
+	return 0;
+}
+
+int
+trace_syscall(struct tcb *tcp)
+{
+	return exiting(tcp) ?
+		trace_syscall_exiting(tcp) : trace_syscall_entering(tcp);
+}
+
+bool
+is_erestart(struct tcb *tcp)
+{
+	switch (tcp->u_error) {
+		case ERESTARTSYS:
+		case ERESTARTNOINTR:
+		case ERESTARTNOHAND:
+		case ERESTART_RESTARTBLOCK:
+			return true;
+		default:
+			return false;
+	}
+}
+
+static int saved_u_error;
+
+void
+temporarily_clear_syserror(struct tcb *tcp)
+{
+	saved_u_error = tcp->u_error;
+	tcp->u_error = 0;
+}
+
+void
+restore_cleared_syserror(struct tcb *tcp)
+{
+	tcp->u_error = saved_u_error;
+}
+
+#include "kernel_types.h"
+
+/*
+ * Check the syscall return value register value for whether it is
+ * a negated errno code indicating an error, or a success return value.
+ */
+static inline bool
+is_negated_errno(kernel_ulong_t val)
+{
+	/* Linux kernel defines MAX_ERRNO to 4095. */
+	kernel_ulong_t max = -(kernel_long_t) 4095;
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+	if (current_wordsize < sizeof(val)) {
+		val = (uint32_t) val;
+		max = (uint32_t) max;
+	}
+#elif defined X32
+	/*
+	 * current_wordsize is 4 even in personality 0 (native X32)
+	 * but truncation _must not_ be done in it.
+	 * can't check current_wordsize here!
+	 */
+	if (current_personality != 0) {
+		val = (uint32_t) val;
+		max = (uint32_t) max;
+	}
+#endif
+
+	return val >= max;
+}
+
+#include "arch_regs.c"
+
+#ifdef HAVE_GETRVAL2
+# include "arch_getrval2.c"
+#endif
+
+void
+print_pc(struct tcb *tcp)
+{
+#if defined ARCH_PC_REG
+# define ARCH_GET_PC 0
+#elif defined ARCH_PC_PEEK_ADDR
+	long pc;
+# define ARCH_PC_REG pc
+# define ARCH_GET_PC upeek(tcp->pid, ARCH_PC_PEEK_ADDR, &pc)
+#else
+# error Neither ARCH_PC_REG nor ARCH_PC_PEEK_ADDR is defined
+#endif
+	if (get_regs_error || ARCH_GET_PC)
+		tprints(current_wordsize == 4 ? "[????????] "
+					      : "[????????????????] ");
+	else
+		tprintf(current_wordsize == 4 ? "[%08lx] " : "[%016lx] ",
+			(unsigned long) ARCH_PC_REG);
+}
+
+#if defined ARCH_REGS_FOR_GETREGSET
+static long
+get_regset(pid_t pid)
+{
+# ifdef ARCH_IOVEC_FOR_GETREGSET
+	/* variable iovec */
+	ARCH_IOVEC_FOR_GETREGSET.iov_len = sizeof(ARCH_REGS_FOR_GETREGSET);
+	return ptrace(PTRACE_GETREGSET, pid, NT_PRSTATUS,
+		      &ARCH_IOVEC_FOR_GETREGSET);
+# else
+	/* constant iovec */
+	static struct iovec io = {
+		.iov_base = &ARCH_REGS_FOR_GETREGSET,
+		.iov_len = sizeof(ARCH_REGS_FOR_GETREGSET)
+	};
+	return ptrace(PTRACE_GETREGSET, pid, NT_PRSTATUS, &io);
+
+# endif
+}
+#endif /* ARCH_REGS_FOR_GETREGSET */
+
+void
+get_regs(pid_t pid)
+{
+#undef USE_GET_SYSCALL_RESULT_REGS
+#ifdef ARCH_REGS_FOR_GETREGSET
+# ifdef X86_64
+	/* Try PTRACE_GETREGSET first, fallback to PTRACE_GETREGS. */
+	static int getregset_support;
+
+	if (getregset_support >= 0) {
+		get_regs_error = get_regset(pid);
+		if (getregset_support > 0)
+			return;
+		if (get_regs_error >= 0) {
+			getregset_support = 1;
+			return;
+		}
+		if (errno == EPERM || errno == ESRCH)
+			return;
+		getregset_support = -1;
+	}
+	get_regs_error = getregs_old(pid);
+# else /* !X86_64 */
+	/* Assume that PTRACE_GETREGSET works. */
+	get_regs_error = get_regset(pid);
+# endif
+#elif defined ARCH_REGS_FOR_GETREGS
+# if defined SPARC || defined SPARC64
+	/* SPARC systems have the meaning of data and addr reversed */
+	get_regs_error =
+		ptrace(PTRACE_GETREGS, pid, (void *) &ARCH_REGS_FOR_GETREGS, 0);
+# elif defined POWERPC
+	static bool old_kernel = 0;
+	if (old_kernel)
+		goto old;
+	get_regs_error = ptrace(PTRACE_GETREGS, pid, NULL, &ARCH_REGS_FOR_GETREGS);
+	if (get_regs_error && errno == EIO) {
+		old_kernel = 1;
+ old:
+		get_regs_error = getregs_old(pid);
+	}
+# else
+	/* Assume that PTRACE_GETREGS works. */
+	get_regs_error = ptrace(PTRACE_GETREGS, pid, NULL, &ARCH_REGS_FOR_GETREGS);
+# endif
+
+#else /* !ARCH_REGS_FOR_GETREGSET && !ARCH_REGS_FOR_GETREGS */
+# define USE_GET_SYSCALL_RESULT_REGS 1
+# warning get_regs is not implemented for this architecture yet
+	get_regs_error = 0;
+#endif
+}
+
+/*
+ * Returns:
+ * 0: "ignore this ptrace stop", bail out of trace_syscall_entering() silently.
+ * 1: ok, continue in trace_syscall_entering().
+ * other: error, trace_syscall_entering() should print error indicator
+ *    ("????" etc) and bail out.
+ */
+int
+get_scno(struct tcb *tcp)
+{
+	if (get_regs_error)
+		return -1;
+
+	int rc = arch_get_scno(tcp);
+	if (rc != 1)
+		return rc;
+
+	if (SCNO_IS_VALID(tcp->scno)) {
+		tcp->s_ent = &sysent[tcp->scno];
+		tcp->qual_flg = qual_flags[tcp->scno];
+	} else {
+		static const struct_sysent unknown = {
+			.nargs = MAX_ARGS,
+			.sys_flags = 0,
+			.sys_func = printargs,
+			.sys_name = "system call",
+		};
+		tcp->s_ent = &unknown;
+		tcp->qual_flg = QUAL_RAW | DEFAULT_QUAL_FLAGS;
+		if (debug_flag)
+			error_msg("pid %d invalid syscall %ld", tcp->pid, tcp->scno);
+	}
+	return 1;
+}
+
+#ifdef USE_GET_SYSCALL_RESULT_REGS
+static int get_syscall_result_regs(struct tcb *);
+#endif
+
+/* Returns:
+ * 1: ok, continue in trace_syscall_exiting().
+ * -1: error, trace_syscall_exiting() should print error indicator
+ *    ("????" etc) and bail out.
+ */
+static int
+get_syscall_result(struct tcb *tcp)
+{
+#ifdef USE_GET_SYSCALL_RESULT_REGS
+	if (get_syscall_result_regs(tcp))
+		return -1;
+#endif
+	tcp->u_error = 0;
+	get_error(tcp, !(tcp->s_ent->sys_flags & SYSCALL_NEVER_FAILS));
+
+	return 1;
+}
+
+#include "get_scno.c"
+#include "get_syscall_args.c"
+#ifdef USE_GET_SYSCALL_RESULT_REGS
+# include "get_syscall_result.c"
+#endif
+#include "get_error.c"
+#if defined X86_64 || defined POWERPC
+# include "getregs_old.c"
+#endif
diff --git a/strace/syscallent.sh b/strace/syscallent.sh
new file mode 100755
index 0000000..16dd77f
--- /dev/null
+++ b/strace/syscallent.sh
@@ -0,0 +1,73 @@
+#!/bin/sh
+# Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+# 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.
+
+cat ${1+"$@"} |
+	sed -n 's/^#[ 	]*define[ 	][ 	]*SYS_\([^ 	]*\)[ 	]*[^0-9]*\([0-9]*\).*$/\1 \2/p
+s/^#[ 	]*define[ 	][ 	]*__NR_\([^ 	]*\)[ 	]*[^0-9]*\([0-9]*\).*$/\1 \2/p
+s/^#[ ]*define[ ][ ]*__NR_\([^ ]*\)[ ]*[^0-9()]*(__NR_Linux + \([0-9]*\))$/\1 \2/p' |
+	sort -k2n | uniq |
+	awk '
+	BEGIN {
+		tabs = "\t\t\t\t\t\t\t\t"
+		call = -1;
+	}
+	{
+		while (++call < $2) {
+			f = "printargs"
+			n = "SYS_" call
+			s = "\t{ MA,\t0,\t"
+			s = s f ","
+			s = s substr(tabs, 1, 24/8 - int((length(f) + 1)/8))
+			s = s "\"" n "\""
+			s = s substr(tabs, 1, 16/8 - int((length(n) + 2)/8))
+			s = s "}, /* " call " */"
+			print s
+		}
+		f = "sys_" $1
+		n = $1
+		s = "\t{ MA,\t0,\t"
+		s = s f ","
+		s = s substr(tabs, 1, 24/8 - int((length(f) + 1)/8))
+		s = s "\"" n "\""
+		s = s substr(tabs, 1, 16/8 - int((length(n) + 2)/8))
+		s = s "}, /* " call " */"
+		print s
+	}
+	END {
+		limit = call + 100
+		while (++call < limit) {
+			f = "printargs"
+			n = "SYS_" call
+			s = "\t{ MA,\t0,\t"
+			s = s f ","
+			s = s substr(tabs, 1, 24/8 - int((length(f) + 1)/8))
+			s = s "\"" n "\""
+			s = s substr(tabs, 1, 16/8 - int((length(n) + 2)/8))
+			s = s "}, /* " call " */"
+			print s
+		}
+	}
+	'
diff --git a/strace/sysctl.c b/strace/sysctl.c
new file mode 100644
index 0000000..03e98c1
--- /dev/null
+++ b/strace/sysctl.c
@@ -0,0 +1,192 @@
+/*
+ * Copyright (c) 1999 Ulrich Drepper <drepper@cygnus.com>
+ * Copyright (c) 2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2005-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <linux/sysctl.h>
+
+#include "xlat/sysctl_root.h"
+#include "xlat/sysctl_kern.h"
+#include "xlat/sysctl_vm.h"
+#include "xlat/sysctl_net.h"
+#include "xlat/sysctl_net_core.h"
+#include "xlat/sysctl_net_unix.h"
+#include "xlat/sysctl_net_ipv4.h"
+#include "xlat/sysctl_net_ipv4_route.h"
+#include "xlat/sysctl_net_ipv4_conf.h"
+#include "xlat/sysctl_net_ipv6.h"
+#include "xlat/sysctl_net_ipv6_route.h"
+
+SYS_FUNC(sysctl)
+{
+	struct __sysctl_args info;
+	int *name;
+	unsigned long size;
+
+	if (umove_or_printaddr(tcp, tcp->u_arg[0], &info))
+		return RVAL_DECODED;
+
+	size = sizeof(int) * (unsigned long) info.nlen;
+	name = (size / sizeof(int) != (unsigned long) info.nlen) ? NULL : malloc(size);
+	if (name == NULL ||
+	    umoven(tcp, (unsigned long) info.name, size, name) < 0) {
+		free(name);
+		if (entering(tcp))
+			tprintf("{%p, %d, %p, %p, %p, %lu}",
+				info.name, info.nlen, info.oldval,
+				info.oldlenp, info.newval, (unsigned long)info.newlen);
+		return RVAL_DECODED;
+	}
+
+	if (entering(tcp)) {
+		unsigned int cnt = 0, max_cnt;
+
+		tprints("{{");
+
+		if (info.nlen == 0)
+			goto out;
+		printxval(sysctl_root, name[0], "CTL_???");
+		++cnt;
+
+		if (info.nlen == 1)
+			goto out;
+		switch (name[0]) {
+		case CTL_KERN:
+			tprints(", ");
+			printxval(sysctl_kern, name[1], "KERN_???");
+			++cnt;
+			break;
+		case CTL_VM:
+			tprints(", ");
+			printxval(sysctl_vm, name[1], "VM_???");
+			++cnt;
+			break;
+		case CTL_NET:
+			tprints(", ");
+			printxval(sysctl_net, name[1], "NET_???");
+			++cnt;
+
+			if (info.nlen == 2)
+				goto out;
+			switch (name[1]) {
+			case NET_CORE:
+				tprints(", ");
+				printxval(sysctl_net_core, name[2],
+					  "NET_CORE_???");
+				break;
+			case NET_UNIX:
+				tprints(", ");
+				printxval(sysctl_net_unix, name[2],
+					  "NET_UNIX_???");
+				break;
+			case NET_IPV4:
+				tprints(", ");
+				printxval(sysctl_net_ipv4, name[2],
+					  "NET_IPV4_???");
+
+				if (info.nlen == 3)
+					goto out;
+				switch (name[2]) {
+				case NET_IPV4_ROUTE:
+					tprints(", ");
+					printxval(sysctl_net_ipv4_route,
+						  name[3],
+						  "NET_IPV4_ROUTE_???");
+					break;
+				case NET_IPV4_CONF:
+					tprints(", ");
+					printxval(sysctl_net_ipv4_conf,
+						  name[3],
+						  "NET_IPV4_CONF_???");
+					break;
+				default:
+					goto out;
+				}
+				break;
+			case NET_IPV6:
+				tprints(", ");
+				printxval(sysctl_net_ipv6, name[2],
+					  "NET_IPV6_???");
+
+				if (info.nlen == 3)
+					goto out;
+				switch (name[2]) {
+				case NET_IPV6_ROUTE:
+					tprints(", ");
+					printxval(sysctl_net_ipv6_route,
+						  name[3],
+						  "NET_IPV6_ROUTE_???");
+					break;
+				default:
+					goto out;
+				}
+				break;
+			default:
+				goto out;
+			}
+			break;
+		default:
+			goto out;
+		}
+	out:
+		max_cnt = info.nlen;
+		if (abbrev(tcp) && max_cnt > max_strlen)
+			max_cnt = max_strlen;
+		while (cnt < max_cnt)
+			tprintf(", %x", name[cnt++]);
+		if (cnt < (unsigned) info.nlen)
+			tprints(", ...");
+		tprintf("}, %d, ", info.nlen);
+	} else {
+		size_t oldlen = 0;
+		if (info.oldval == NULL) {
+			tprints("NULL");
+		} else if (umove(tcp, (long)info.oldlenp, &oldlen) >= 0
+			   && info.nlen >= 2
+			   && ((name[0] == CTL_KERN
+				&& (name[1] == KERN_OSRELEASE
+				    || name[1] == KERN_OSTYPE
+					)))) {
+			printpath(tcp, (size_t)info.oldval);
+		} else {
+			tprintf("%p", info.oldval);
+		}
+		tprintf(", %lu, ", (unsigned long)oldlen);
+		if (info.newval == NULL)
+			tprints("NULL");
+		else if (syserror(tcp))
+			tprintf("%p", info.newval);
+		else
+			printpath(tcp, (size_t)info.newval);
+		tprintf(", %lu", (unsigned long)info.newlen);
+	}
+
+	free(name);
+	return 0;
+}
diff --git a/strace/sysinfo.c b/strace/sysinfo.c
new file mode 100644
index 0000000..c3cb9ad
--- /dev/null
+++ b/strace/sysinfo.c
@@ -0,0 +1,80 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2012 H.J. Lu <hongjiu.lu@intel.com>
+ * Copyright (c) 2012 Denys Vlasenko <vda.linux@googlemail.com>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * 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 DEF_MPERS_TYPE(sysinfo_t)
+#include <sys/sysinfo.h>
+typedef struct sysinfo sysinfo_t;
+#include MPERS_DEFS
+
+SYS_FUNC(sysinfo)
+{
+	sysinfo_t si;
+
+	if (entering(tcp))
+		return 0;
+
+	if (!umove_or_printaddr(tcp, tcp->u_arg[0], &si)) {
+		tprintf("{uptime=%llu"
+			", loads=[%llu, %llu, %llu]"
+			", totalram=%llu"
+			", freeram=%llu"
+			", sharedram=%llu"
+			", bufferram=%llu"
+			", totalswap=%llu"
+			", freeswap=%llu"
+			", procs=%u"
+			", totalhigh=%llu"
+			", freehigh=%llu"
+			", mem_unit=%u"
+			"}",
+			widen_to_ull(si.uptime)
+			, widen_to_ull(si.loads[0])
+			, widen_to_ull(si.loads[1])
+			, widen_to_ull(si.loads[2])
+			, widen_to_ull(si.totalram)
+			, widen_to_ull(si.freeram)
+			, widen_to_ull(si.sharedram)
+			, widen_to_ull(si.bufferram)
+			, widen_to_ull(si.totalswap)
+			, widen_to_ull(si.freeswap)
+			, (unsigned) si.procs
+			, widen_to_ull(si.totalhigh)
+			, widen_to_ull(si.freehigh)
+			, si.mem_unit
+			);
+	}
+
+	return 0;
+}
diff --git a/strace/syslog.c b/strace/syslog.c
new file mode 100644
index 0000000..6be941c
--- /dev/null
+++ b/strace/syslog.c
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) 2012-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+enum {
+	SYSLOG_ACTION_CLOSE = 0,
+	SYSLOG_ACTION_OPEN,
+	SYSLOG_ACTION_READ,
+	SYSLOG_ACTION_READ_ALL,
+	SYSLOG_ACTION_READ_CLEAR,
+	SYSLOG_ACTION_CLEAR,
+	SYSLOG_ACTION_CONSOLE_OFF,
+	SYSLOG_ACTION_CONSOLE_ON,
+	SYSLOG_ACTION_CONSOLE_LEVEL,
+	SYSLOG_ACTION_SIZE_UNREAD,
+	SYSLOG_ACTION_SIZE_BUFFER
+};
+
+#include "xlat/syslog_action_type.h"
+
+SYS_FUNC(syslog)
+{
+	int type = tcp->u_arg[0];
+
+	if (entering(tcp)) {
+		/* type */
+		printxval(syslog_action_type, type, "SYSLOG_ACTION_???");
+		tprints(", ");
+	}
+
+	switch (type) {
+		case SYSLOG_ACTION_READ:
+		case SYSLOG_ACTION_READ_ALL:
+		case SYSLOG_ACTION_READ_CLEAR:
+			if (entering(tcp))
+				return 0;
+			break;
+		default:
+			printaddr(tcp->u_arg[1]);
+			tprintf(", %lu", tcp->u_arg[2]);
+			return RVAL_DECODED;
+	}
+
+	/* bufp */
+	if (syserror(tcp))
+		printaddr(tcp->u_arg[1]);
+	else
+		printstr(tcp, tcp->u_arg[1], tcp->u_rval);
+	/* len */
+	tprintf(", %d", (int) tcp->u_arg[2]);
+
+	return 0;
+}
diff --git a/strace/sysmips.c b/strace/sysmips.c
new file mode 100644
index 0000000..47acfec
--- /dev/null
+++ b/strace/sysmips.c
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2001 Wichert Akkerman <wichert@deephackmode.org>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef MIPS
+
+#ifdef HAVE_LINUX_UTSNAME_H
+# include <linux/utsname.h>
+#endif
+#ifdef HAVE_ASM_SYSMIPS_H
+# include <asm/sysmips.h>
+#endif
+
+#ifndef __NEW_UTS_LEN
+# define __NEW_UTS_LEN 64
+#endif
+
+#include "xlat/sysmips_operations.h"
+
+SYS_FUNC(sysmips)
+{
+	printxval_long(sysmips_operations, tcp->u_arg[0], "???");
+	tprints(", ");
+
+	switch (tcp->u_arg[0]) {
+	case SETNAME: {
+		char nodename[__NEW_UTS_LEN + 1];
+
+		if (!verbose(tcp))
+			break;
+		if (umovestr(tcp, tcp->u_arg[1], (__NEW_UTS_LEN + 1),
+			     nodename) < 0) {
+			printaddr(tcp->u_arg[1]);
+		} else {
+			print_quoted_string(nodename, __NEW_UTS_LEN + 1,
+					    QUOTE_0_TERMINATED);
+		}
+		return RVAL_DECODED;
+	}
+	case MIPS_ATOMIC_SET:
+		printaddr(tcp->u_arg[1]);
+		tprintf(", %#lx", tcp->u_arg[2]);
+		return RVAL_DECODED;
+	case MIPS_FIXADE:
+		tprintf("%#lx", tcp->u_arg[1]);
+		return RVAL_DECODED;
+	}
+
+	tprintf("%ld, %ld, %ld", tcp->u_arg[1], tcp->u_arg[2], tcp->u_arg[3]);
+	return RVAL_DECODED;
+}
+
+#endif /* MIPS */
diff --git a/strace/term.c b/strace/term.c
new file mode 100644
index 0000000..530ffc4
--- /dev/null
+++ b/strace/term.c
@@ -0,0 +1,305 @@
+/*
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * 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"
+/*
+ * The C library's definition of struct termios might differ from
+ * the kernel one, and we need to use the kernel layout.
+ */
+#include <linux/termios.h>
+
+#include "xlat/tcxonc_options.h"
+#include "xlat/tcflsh_options.h"
+#include "xlat/baud_options.h"
+#include "xlat/modem_flags.h"
+
+static void
+decode_termios(struct tcb *tcp, const long addr)
+{
+	struct termios tios;
+	int i;
+
+	if (!verbose(tcp))
+		return;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &tios))
+		return;
+	if (abbrev(tcp)) {
+		tprints("{");
+		printxval(baud_options, tios.c_cflag & CBAUD, "B???");
+		tprintf(" %sopost %sisig %sicanon %secho ...}",
+			(tios.c_oflag & OPOST) ? "" : "-",
+			(tios.c_lflag & ISIG) ? "" : "-",
+			(tios.c_lflag & ICANON) ? "" : "-",
+			(tios.c_lflag & ECHO) ? "" : "-");
+		return;
+	}
+	tprintf("{c_iflags=%#lx, c_oflags=%#lx, ",
+		(long) tios.c_iflag, (long) tios.c_oflag);
+	tprintf("c_cflags=%#lx, c_lflags=%#lx, ",
+		(long) tios.c_cflag, (long) tios.c_lflag);
+	tprintf("c_line=%u, ", tios.c_line);
+	if (!(tios.c_lflag & ICANON))
+		tprintf("c_cc[VMIN]=%d, c_cc[VTIME]=%d, ",
+			tios.c_cc[VMIN], tios.c_cc[VTIME]);
+	tprintf("c_cc=\"");
+	for (i = 0; i < NCCS; i++)
+		tprintf("\\x%02x", tios.c_cc[i]);
+	tprintf("\"}");
+}
+
+static void
+decode_termio(struct tcb *tcp, const long addr)
+{
+	struct termio tio;
+	int i;
+
+	if (!verbose(tcp))
+		return;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &tio))
+		return;
+	if (abbrev(tcp)) {
+		tprints("{");
+		printxval(baud_options, tio.c_cflag & CBAUD, "B???");
+		tprintf(" %sopost %sisig %sicanon %secho ...}",
+			(tio.c_oflag & OPOST) ? "" : "-",
+			(tio.c_lflag & ISIG) ? "" : "-",
+			(tio.c_lflag & ICANON) ? "" : "-",
+			(tio.c_lflag & ECHO) ? "" : "-");
+		return;
+	}
+	tprintf("{c_iflags=%#lx, c_oflags=%#lx, ",
+		(long) tio.c_iflag, (long) tio.c_oflag);
+	tprintf("c_cflags=%#lx, c_lflags=%#lx, ",
+		(long) tio.c_cflag, (long) tio.c_lflag);
+	tprintf("c_line=%u, ", tio.c_line);
+#ifdef _VMIN
+	if (!(tio.c_lflag & ICANON))
+		tprintf("c_cc[_VMIN]=%d, c_cc[_VTIME]=%d, ",
+			tio.c_cc[_VMIN], tio.c_cc[_VTIME]);
+#else /* !_VMIN */
+	if (!(tio.c_lflag & ICANON))
+		tprintf("c_cc[VMIN]=%d, c_cc[VTIME]=%d, ",
+			tio.c_cc[VMIN], tio.c_cc[VTIME]);
+#endif /* !_VMIN */
+	tprintf("c_cc=\"");
+	for (i = 0; i < NCC; i++)
+		tprintf("\\x%02x", tio.c_cc[i]);
+	tprintf("\"}");
+}
+
+static void
+decode_winsize(struct tcb *tcp, const long addr)
+{
+	struct winsize ws;
+
+	if (!verbose(tcp))
+		return;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &ws))
+		return;
+	tprintf("{ws_row=%d, ws_col=%d, ws_xpixel=%d, ws_ypixel=%d}",
+		ws.ws_row, ws.ws_col, ws.ws_xpixel, ws.ws_ypixel);
+}
+
+#ifdef TIOCGSIZE
+static void
+decode_ttysize(struct tcb *tcp, const long addr)
+{
+	struct ttysize ts;
+
+	if (!verbose(tcp))
+		return;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &ts))
+		return;
+	tprintf("{ts_lines=%d, ts_cols=%d}",
+		ts.ts_lines, ts.ts_cols);
+}
+#endif
+
+static void
+decode_modem_flags(struct tcb *tcp, const long addr)
+{
+	int i;
+
+	if (!verbose(tcp))
+		return;
+
+	tprints(", ");
+	if (umove_or_printaddr(tcp, addr, &i))
+		return;
+	tprints("[");
+	printflags(modem_flags, i, "TIOCM_???");
+	tprints("]");
+}
+
+int
+term_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	switch (code) {
+	/* struct termios */
+	case TCGETS:
+#ifdef TCGETS2
+	case TCGETS2:
+#endif
+	case TIOCGLCKTRMIOS:
+		if (entering(tcp))
+			return 0;
+	case TCSETS:
+#ifdef TCSETS2
+	case TCSETS2:
+#endif
+	case TCSETSW:
+#ifdef TCSETSW2
+	case TCSETSW2:
+#endif
+	case TCSETSF:
+#ifdef TCSETSF2
+	case TCSETSF2:
+#endif
+	case TIOCSLCKTRMIOS:
+		decode_termios(tcp, arg);
+		break;
+
+	/* struct termio */
+	case TCGETA:
+		if (entering(tcp))
+			return 0;
+	case TCSETA:
+	case TCSETAW:
+	case TCSETAF:
+		decode_termio(tcp, arg);
+		break;
+
+	/* struct winsize */
+	case TIOCGWINSZ:
+		if (entering(tcp))
+			return 0;
+	case TIOCSWINSZ:
+		decode_winsize(tcp, arg);
+		break;
+
+	/* struct ttysize */
+#ifdef TIOCGSIZE
+	case TIOCGSIZE:
+		if (entering(tcp))
+			return 0;
+	case TIOCSSIZE:
+		decode_ttysize(tcp, arg);
+		break;
+#endif
+
+	/* ioctls with a direct decodable arg */
+	case TCXONC:
+		tprints(", ");
+		printxval_long(tcxonc_options, arg, "TC???");
+		break;
+	case TCFLSH:
+		tprints(", ");
+		printxval_long(tcflsh_options, arg, "TC???");
+		break;
+	case TCSBRK:
+	case TCSBRKP:
+	case TIOCSCTTY:
+		tprintf(", %d", (int) arg);
+		break;
+
+	/* ioctls with an indirect parameter displayed as modem flags */
+	case TIOCMGET:
+		if (entering(tcp))
+			return 0;
+	case TIOCMBIS:
+	case TIOCMBIC:
+	case TIOCMSET:
+		decode_modem_flags(tcp, arg);
+		break;
+
+	/* ioctls with an indirect parameter displayed in decimal */
+	case TIOCGPGRP:
+	case TIOCGSID:
+	case TIOCGETD:
+	case TIOCGSOFTCAR:
+	case TIOCGPTN:
+	case FIONREAD:
+	case TIOCOUTQ:
+#ifdef TIOCGEXCL
+	case TIOCGEXCL:
+#endif
+#ifdef TIOCGDEV
+	case TIOCGDEV:
+#endif
+		if (entering(tcp))
+			return 0;
+	case TIOCSPGRP:
+	case TIOCSETD:
+	case FIONBIO:
+	case FIOASYNC:
+	case TIOCPKT:
+	case TIOCSSOFTCAR:
+	case TIOCSPTLCK:
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+
+	/* ioctls with an indirect parameter displayed as a char */
+	case TIOCSTI:
+		tprints(", ");
+		printstr(tcp, arg, 1);
+		break;
+
+	/* ioctls with no parameters */
+
+	case TIOCSBRK:
+	case TIOCCBRK:
+	case TIOCCONS:
+	case TIOCNOTTY:
+	case TIOCEXCL:
+	case TIOCNXCL:
+	case FIOCLEX:
+	case FIONCLEX:
+#ifdef TIOCVHANGUP
+	case TIOCVHANGUP:
+#endif
+#ifdef TIOCSSERIAL
+	case TIOCSSERIAL:
+#endif
+		break;
+
+	/* ioctls which are unknown */
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/test/Makefile b/strace/test/Makefile
new file mode 100644
index 0000000..ad727fc
--- /dev/null
+++ b/strace/test/Makefile
@@ -0,0 +1,20 @@
+CFLAGS += -Wall
+
+PROGS = \
+    sig skodic clone leaderkill childthread \
+    sigkill_rain wait_must_be_interruptible threaded_execve \
+    mtd ubi seccomp sfd mmap_offset_decode x32_lseek x32_mmap \
+    many_looping_threads
+
+all: $(PROGS)
+
+leaderkill: LDFLAGS += -pthread
+
+childthread: LDFLAGS += -pthread
+
+many_looping_threads: LDFLAGS += -pthread
+
+clean distclean:
+	rm -f *.o core $(PROGS) *.gdb
+
+.PHONY: all clean distclean
diff --git a/strace/test/many_looping_threads.c b/strace/test/many_looping_threads.c
new file mode 100644
index 0000000..918bd9d
--- /dev/null
+++ b/strace/test/many_looping_threads.c
@@ -0,0 +1,49 @@
+// This testcase, when run with large number of threads
+// under stace -f, may never finish because strace does not
+// ensure any fairness in thread scheduling:
+// it restarts threads as they stop. If daughter threads crowd out
+// the "mother" and _they_ get continually restarted by strace,
+// the end of spawning loop will never be reached.
+//
+// Also, it is a testcase which triggers the
+// "strace: Exit of unknown pid 32457 seen"
+// message when on testcase exit, strace sees deaths of newly-attached
+// threads _before_ their first syscall stop.
+//
+#include <stdio.h>
+#include <pthread.h>
+#include <unistd.h>
+#include <sys/types.h>
+#include <signal.h>
+#include <stdlib.h>
+
+static int thd_no;
+
+static void *sub_thd(void *c)
+{
+	dprintf(1, "sub-thread %d created\n", ++thd_no);
+	for (;;)
+		getuid();
+	return NULL;
+}
+
+int main(int argc, char *argv[])
+{
+	int i;
+	pthread_t *thd;
+	int num_threads = 1;
+
+	if (argv[1])
+		num_threads = atoi(argv[1]);
+
+	thd = malloc(num_threads * sizeof(thd[0]));
+	dprintf(1, "test start, num_threads:%d...\n", num_threads);
+
+	for (i = 0; i < num_threads; i++) {
+		pthread_create(&thd[i], NULL, sub_thd, NULL);
+		dprintf(1, "after pthread_create\n");
+	}
+
+	/* Exit. This kills all threads */
+	return 0;
+}
diff --git a/strace/tests/Makefile.am b/strace/tests/Makefile.am
new file mode 100644
index 0000000..9023029
--- /dev/null
+++ b/strace/tests/Makefile.am
@@ -0,0 +1,786 @@
+# Automake input for strace tests.
+#
+# Copyright (c) 2011-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+OS = linux
+ARCH = @arch@
+MPERS_NAME =
+ARCH_MFLAGS =
+AM_CFLAGS = $(WARN_CFLAGS)
+AM_CPPFLAGS = $(ARCH_MFLAGS) \
+	      -I$(builddir) \
+	      -I$(top_builddir)/$(OS)/$(ARCH) \
+	      -I$(top_srcdir)/$(OS)/$(ARCH) \
+	      -I$(top_builddir)/$(OS) \
+	      -I$(top_srcdir)/$(OS) \
+	      -I$(top_builddir) \
+	      -I$(top_srcdir)
+AM_LDFLAGS = $(ARCH_MFLAGS)
+
+libtests_a_SOURCES = \
+	errno2name.c \
+	error_msg.c \
+	get_page_size.c \
+	hexdump_strdup.c \
+	hexquote_strndup.c \
+	inode_of_sockfd.c \
+	libmmsg.c \
+	libsocketcall.c \
+	overflowuid.c \
+	print_quoted_string.c \
+	printflags.c \
+	printxval.c \
+	signal2name.c \
+	tail_alloc.c \
+	tests.h \
+	tprintf.c \
+	# end of libtests_a_SOURCES
+libtests_a_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+check_LIBRARIES = libtests.a
+LDADD = libtests.a
+
+check_PROGRAMS = \
+	_newselect \
+	accept \
+	accept4 \
+	access \
+	acct \
+	adjtimex \
+	aio \
+	alarm \
+	attach-f-p \
+	attach-p-cmd-cmd \
+	attach-p-cmd-p \
+	bpf \
+	brk \
+	btrfs \
+	caps \
+	chmod \
+	chown \
+	chown32 \
+	chroot \
+	clock_adjtime \
+	clock_nanosleep \
+	clock_xettime \
+	copy_file_range \
+	count-f \
+	creat \
+	dup \
+	dup2 \
+	dup3 \
+	epoll_create \
+	epoll_create1 \
+	epoll_ctl \
+	epoll_pwait \
+	epoll_wait \
+	eventfd \
+	execve \
+	execve-v \
+	execveat \
+	execveat-v \
+	faccessat \
+	fanotify_mark \
+	fchdir \
+	fchmod \
+	fchmodat \
+	fchown \
+	fchown32 \
+	fchownat \
+	fcntl \
+	fcntl64 \
+	fdatasync \
+	file_handle \
+	file_ioctl \
+	filter-unavailable \
+	flock \
+	fork-f \
+	fstat \
+	fstat64 \
+	fstatat64 \
+	fstatfs \
+	fstatfs64 \
+	fsync \
+	ftruncate \
+	ftruncate64 \
+	futimesat \
+	get_mempolicy \
+	getcwd \
+	getdents \
+	getdents64 \
+	getegid \
+	getegid32 \
+	geteuid \
+	geteuid32 \
+	getgid \
+	getgid32 \
+	getgroups \
+	getgroups32 \
+	getpeername \
+	getpgrp \
+	getrandom \
+	getresgid \
+	getresgid32 \
+	getresuid \
+	getresuid32 \
+	getrlimit \
+	getrusage \
+	getsid \
+	getsockname \
+	getuid \
+	getuid32 \
+	getxxid \
+	inet-cmsg \
+	ioctl \
+	ioctl_block \
+	ioctl_evdev \
+	ioctl_evdev-v \
+	ioctl_mtd \
+	ioctl_rtc \
+	ioctl_rtc-v \
+	ioctl_uffdio \
+	ioctl_v4l2 \
+	ioperm \
+	iopl \
+	ip_mreq \
+	ipc \
+	ipc_msg \
+	ipc_msgbuf \
+	ipc_sem \
+	ipc_shm \
+	kill \
+	ksysent \
+	lchown \
+	lchown32 \
+	link \
+	linkat \
+	llseek \
+	lseek \
+	lstat \
+	lstat64 \
+	mbind \
+	membarrier \
+	memfd_create \
+	migrate_pages \
+	mincore \
+	mkdir \
+	mkdirat \
+	mknod \
+	mknodat \
+	mlock \
+	mlock2 \
+	mlockall \
+	mmap \
+	mmap64 \
+	mmsg \
+	mmsg-silent \
+	mmsg_name \
+	mmsg_name-v \
+	mount \
+	move_pages \
+	mq \
+	msg_control \
+	msg_control-v \
+	msg_name \
+	munlockall \
+	nanosleep \
+	net-accept-connect \
+	net-icmp_filter \
+	net-sockaddr \
+	net-y-unix \
+	net-yy-inet \
+	net-yy-netlink \
+	net-yy-unix \
+	netlink_inet_diag \
+	netlink_netlink_diag \
+	netlink_protocol \
+	netlink_unix_diag \
+	newfstatat \
+	nsyscalls \
+	old_mmap \
+	oldselect \
+	open \
+	openat \
+	pause \
+	pc \
+	personality \
+	pipe \
+	poll \
+	ppoll \
+	prctl-seccomp-filter-v \
+	prctl-seccomp-strict \
+	pread64-pwrite64 \
+	preadv \
+	preadv-pwritev \
+	preadv2-pwritev2 \
+	prlimit64 \
+	pselect6 \
+	ptrace \
+	pwritev \
+	read-write \
+	readdir \
+	readlink \
+	readlinkat \
+	readv \
+	reboot \
+	recvfrom \
+	recvmmsg-timeout \
+	recvmsg \
+	remap_file_pages \
+	rename \
+	renameat \
+	renameat2 \
+	restart_syscall \
+	rmdir \
+	rt_sigpending \
+	rt_sigprocmask \
+	rt_sigqueueinfo \
+	rt_sigsuspend \
+	rt_sigtimedwait \
+	rt_tgsigqueueinfo \
+	sched_get_priority_mxx \
+	sched_rr_get_interval \
+	sched_xetaffinity \
+	sched_xetattr \
+	sched_xetparam \
+	sched_xetscheduler \
+	sched_yield \
+	scm_rights \
+	seccomp-filter \
+	seccomp-filter-v \
+	seccomp-strict \
+	select \
+	semop \
+	sendfile \
+	sendfile64 \
+	set_mempolicy \
+	set_ptracer_any \
+	setdomainname \
+	setfsgid \
+	setfsgid32 \
+	setfsuid \
+	setfsuid32 \
+	setgid \
+	setgid32 \
+	setgroups \
+	setgroups32 \
+	sethostname \
+	setregid \
+	setregid32 \
+	setresgid \
+	setresgid32 \
+	setresuid \
+	setresuid32 \
+	setreuid \
+	setreuid32 \
+	setrlimit \
+	setuid \
+	setuid32 \
+	shmxt \
+	shutdown \
+	sigaction \
+	sigaltstack \
+	siginfo \
+	signal_receive \
+	signalfd \
+	sigreturn \
+	sleep \
+	socketcall \
+	splice \
+	stack-fcall \
+	stat \
+	stat64 \
+	statfs \
+	statfs64 \
+	swap \
+	symlink \
+	symlinkat \
+	sync \
+	sync_file_range \
+	sync_file_range2 \
+	sysinfo \
+	syslog \
+	tee \
+	time \
+	timer_create \
+	timer_xettime \
+	timerfd_xettime \
+	times \
+	times-fail \
+	truncate \
+	truncate64 \
+	ugetrlimit \
+	uio \
+	umask \
+	umount \
+	umount2 \
+	umovestr \
+	umovestr2 \
+	umovestr3 \
+	uname \
+	unix-pair-send-recv \
+	unix-pair-sendto-recvfrom \
+	unlink \
+	unlinkat \
+	userfaultfd \
+	utime \
+	utimensat \
+	utimes \
+	vfork-f \
+	vhangup \
+	vmsplice \
+	wait4 \
+	wait4-v \
+	waitid \
+	waitid-v \
+	waitpid \
+	xattr \
+	xet_robust_list \
+	xetitimer \
+	xetpgid \
+	xetpriority \
+	xettimeofday \
+	# end of check_PROGRAMS
+
+attach_f_p_LDADD = -lrt -lpthread $(LDADD)
+clock_xettime_LDADD = -lrt $(LDADD)
+count_f_LDADD = -lpthread $(LDADD)
+filter_unavailable_LDADD = -lpthread $(LDADD)
+fstat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+fstatat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ftruncate64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+lstat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+mmap64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+mq_LDADD = -lrt $(LDADD)
+newfstatat_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+pc_LDADD = $(dl_LIBS) $(LDADD)
+pread64_pwrite64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+preadv_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+preadv_pwritev_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+pwritev_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+stat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+statfs_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+times_LDADD = -lrt $(LDADD)
+truncate64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+uio_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+
+stack_fcall_SOURCES = stack-fcall.c \
+	stack-fcall-0.c stack-fcall-1.c stack-fcall-2.c stack-fcall-3.c
+
+if USE_LIBUNWIND
+LIBUNWIND_TESTS = strace-k.test
+else
+LIBUNWIND_TESTS =
+endif
+
+DECODER_TESTS = \
+	_newselect.test \
+	accept.test \
+	accept4.test \
+	access.test \
+	acct.test \
+	adjtimex.test \
+	aio.test \
+	alarm.test \
+	bpf.test \
+	brk.test \
+	btrfs.test \
+	btrfs-v.test \
+	btrfs-w.test \
+	btrfs-vw.test \
+	caps.test \
+	chmod.test \
+	chown.test \
+	chown32.test \
+	chroot.test \
+	clock_adjtime.test \
+	clock_nanosleep.test \
+	clock_xettime.test \
+	copy_file_range.test \
+	creat.test \
+	dup.test \
+	dup2.test \
+	dup3.test \
+	epoll_create.test \
+	epoll_create1.test \
+	epoll_ctl.test \
+	epoll_pwait.test \
+	epoll_wait.test \
+	eventfd.test \
+	execve-v.test \
+	execve.test \
+	execveat-v.test \
+	execveat.test \
+	faccessat.test \
+	fanotify_mark.test \
+	fchdir.test \
+	fchmod.test \
+	fchmodat.test \
+	fchown.test \
+	fchown32.test \
+	fchownat.test \
+	fcntl.test \
+	fcntl64.test \
+	fdatasync.test \
+	file_handle.test \
+	file_ioctl.test \
+	flock.test \
+	fstat.test \
+	fstat64.test \
+	fstatat64.test \
+	fstatfs.test \
+	fstatfs64.test \
+	fsync.test \
+	ftruncate.test \
+	ftruncate64.test \
+	futimesat.test \
+	get_mempolicy.test \
+	getcwd.test \
+	getdents.test \
+	getdents64.test \
+	getegid.test \
+	getegid32.test \
+	geteuid.test \
+	geteuid32.test \
+	getgid.test \
+	getgid32.test \
+	getgroups.test \
+	getgroups32.test \
+	getpeername.test \
+	getpgrp.test \
+	getrandom.test \
+	getresgid.test \
+	getresgid32.test \
+	getresuid.test \
+	getresuid32.test \
+	getrlimit.test \
+	getrusage.test \
+	getsid.test \
+	getsockname.test \
+	getuid.test \
+	getuid32.test \
+	getxxid.test \
+	inet-cmsg.test \
+	ioctl.test \
+	ioctl_block.test \
+	ioctl_evdev.test \
+	ioctl_evdev-v.test \
+	ioctl_mtd.test \
+	ioctl_rtc.test \
+	ioctl_rtc-v.test \
+	ioctl_uffdio.test \
+	ioctl_v4l2.test \
+	ioperm.test \
+	iopl.test \
+	ip_mreq.test \
+	ipc.test \
+	ipc_msg.test \
+	ipc_msgbuf.test \
+	ipc_sem.test \
+	ipc_shm.test \
+	kill.test \
+	lchown.test \
+	lchown32.test \
+	link.test \
+	linkat.test \
+	llseek.test \
+	lseek.test \
+	lstat.test \
+	lstat64.test \
+	mbind.test \
+	membarrier.test \
+	memfd_create.test \
+	migrate_pages.test \
+	mincore.test \
+	mkdir.test \
+	mkdirat.test \
+	mknod.test \
+	mknodat.test \
+	mlock.test \
+	mlock2.test \
+	mlockall.test \
+	mmap.test \
+	mmap64.test \
+	mmsg.test \
+	mmsg-silent.test \
+	mmsg_name.test \
+	mmsg_name-v.test \
+	mount.test \
+	move_pages.test \
+	mq.test \
+	msg_control.test \
+	msg_control-v.test \
+	msg_name.test \
+	munlockall.test \
+	nanosleep.test \
+	net-icmp_filter.test \
+	net-sockaddr.test \
+	net-y-unix.test \
+	net-yy-inet.test \
+	net-yy-netlink.test \
+	net-yy-unix.test \
+	net.test \
+	netlink_protocol.test \
+	newfstatat.test \
+	nsyscalls.test \
+	old_mmap.test \
+	oldselect.test \
+	open.test \
+	openat.test \
+	pause.test \
+	personality.test \
+	pipe.test \
+	poll.test \
+	ppoll.test \
+	prctl-seccomp-filter-v.test \
+	prctl-seccomp-strict.test \
+	pread64-pwrite64.test \
+	preadv-pwritev.test \
+	preadv2-pwritev2.test \
+	preadv.test \
+	prlimit64.test \
+	pselect6.test \
+	ptrace.test \
+	pwritev.test \
+	read-write.test \
+	readdir.test \
+	readlink.test \
+	readlinkat.test \
+	readv.test \
+	reboot.test \
+	recvfrom.test \
+	recvmmsg-timeout.test \
+	recvmsg.test \
+	remap_file_pages.test \
+	rename.test \
+	renameat.test \
+	renameat2.test \
+	rmdir.test \
+	rt_sigpending.test \
+	rt_sigprocmask.test \
+	rt_sigqueueinfo.test \
+	rt_sigsuspend.test \
+	rt_sigtimedwait.test \
+	rt_tgsigqueueinfo.test \
+	sched_get_priority_mxx.test \
+	sched_rr_get_interval.test \
+	sched_xetaffinity.test \
+	sched_xetattr.test \
+	sched_xetparam.test \
+	sched_xetscheduler.test \
+	sched_yield.test \
+	scm_rights-fd.test \
+	seccomp-filter-v.test \
+	seccomp-filter.test \
+	seccomp-strict.test \
+	select.test \
+	semop.test \
+	sendfile.test \
+	sendfile64.test \
+	set_mempolicy.test \
+	setdomainname.test \
+	setfsgid.test \
+	setfsgid32.test \
+	setfsuid.test \
+	setfsuid32.test \
+	setgid.test \
+	setgid32.test \
+	setgroups.test \
+	setgroups32.test \
+	sethostname.test \
+	setregid.test \
+	setregid32.test \
+	setresgid.test \
+	setresgid32.test \
+	setresuid.test \
+	setresuid32.test \
+	setreuid.test \
+	setreuid32.test \
+	setrlimit.test \
+	setuid.test \
+	setuid32.test \
+	shmxt.test \
+	shutdown.test \
+	sigaction.test \
+	sigaltstack.test \
+	siginfo.test \
+	signalfd.test \
+	sigreturn.test \
+	socketcall.test \
+	splice.test \
+	stat.test \
+	stat64.test \
+	statfs.test \
+	statfs64.test \
+	sun_path.test \
+	swap.test \
+	symlink.test \
+	symlinkat.test \
+	sync.test \
+	sync_file_range.test \
+	sync_file_range2.test \
+	sysinfo.test \
+	syslog.test \
+	tee.test \
+	time.test \
+	timer_create.test \
+	timer_xettime.test \
+	timerfd_xettime.test \
+	times-fail.test \
+	times.test \
+	truncate.test \
+	truncate64.test \
+	ugetrlimit.test \
+	uio.test \
+	umask.test \
+	umount.test \
+	umount2.test \
+	umovestr.test \
+	umovestr2.test \
+	umovestr3.test \
+	uname.test \
+	unix-pair-send-recv.test \
+	unix-pair-sendto-recvfrom.test \
+	unlink.test \
+	unlinkat.test \
+	userfaultfd.test \
+	utime.test \
+	utimensat.test \
+	utimes.test \
+	vhangup.test \
+	vmsplice.test \
+	wait4.test \
+	wait4-v.test \
+	waitid.test \
+	waitid-v.test \
+	waitpid.test \
+	xattr.test \
+	xet_robust_list.test \
+	xetitimer.test \
+	xetpgid.test \
+	xetpriority.test \
+	xettimeofday.test \
+	# end of DECODER_TESTS
+
+MISC_TESTS = \
+	attach-f-p.test \
+	attach-p-cmd.test \
+	bexecve.test \
+	count-f.test \
+	count.test \
+	detach-running.test \
+	detach-sleeping.test \
+	detach-stopped.test \
+	filter-unavailable.test \
+	fork-f.test \
+	ksysent.test \
+	opipe.test \
+	pc.test \
+	qual_syscall.test \
+	redirect.test \
+	restart_syscall.test \
+	signal_receive.test \
+	strace-E.test \
+	strace-S.test \
+	strace-T.test \
+	strace-V.test \
+	strace-ff.test \
+	strace-r.test \
+	strace-t.test \
+	strace-tt.test \
+	strace-ttt.test \
+	vfork-f.test \
+	# end of MISC_TESTS
+
+TESTS = $(DECODER_TESTS) $(MISC_TESTS) $(LIBUNWIND_TESTS)
+
+XFAIL_TESTS_ =
+XFAIL_TESTS_m32 = $(LIBUNWIND_TESTS)
+XFAIL_TESTS_mx32 = $(LIBUNWIND_TESTS)
+XFAIL_TESTS = $(XFAIL_TESTS_$(MPERS_NAME))
+
+TEST_LOG_COMPILER = env
+AM_TEST_LOG_FLAGS = STRACE_ARCH=$(ARCH) $(srcdir)/run.sh
+
+EXTRA_DIST = init.sh run.sh match.awk \
+	     caps.awk \
+	     count-f.expected \
+	     eventfd.expected \
+	     fanotify_mark.expected \
+	     filter-unavailable.expected \
+	     fstatat.c \
+	     fstatx.c \
+	     getresugid.c \
+	     ip_mreq.expected \
+	     ipc.sh \
+	     ipc_msgbuf.expected \
+	     ksysent.sed \
+	     lstatx.c \
+	     memfd_create.expected \
+	     mq.expected \
+	     net.expected \
+	     oldselect.expected \
+	     pipe.expected \
+	     ppoll.expected \
+	     ppoll-v.expected \
+	     setfsugid.c \
+	     setreugid.c \
+	     setresugid.c \
+	     setugid.c \
+	     sigaction.awk \
+	     sigaltstack.expected \
+	     signalfd.expected \
+	     sockname.c \
+	     statfs.expected \
+	     statx.sh \
+	     strace-E.expected \
+	     strace-T.expected \
+	     strace-ff.expected \
+	     strace-k.test \
+	     strace-r.expected \
+	     struct_flock.c \
+	     sun_path.expected \
+	     uio.expected \
+	     umovestr.expected \
+	     unix-pair-send-recv.expected \
+	     unix-pair-sendto-recvfrom.expected \
+	     xchownx.c \
+	     xgetrlimit.c \
+	     xselect.c \
+	     xstatfs.c \
+	     xstatfs64.c \
+	     xstatfsx.c \
+	     xstatx.c \
+	     $(TESTS)
+
+ksysent.h: $(srcdir)/ksysent.sed
+	echo '#include <asm/unistd.h>' | \
+		$(CPP) $(AM_CPPFLAGS) $(CPPFLAGS) -dM - > $@.t1
+	LC_COLLATE=C sed -n -f $(srcdir)/ksysent.sed < $@.t1 > $@.t2
+	mv -f $@.t2 $@
+	rm -f $@.t1
+
+BUILT_SOURCES = ksysent.h
+CLEANFILES = ksysent.h $(TESTS:=.tmp)
diff --git a/strace/tests/_newselect.c b/strace/tests/_newselect.c
new file mode 100644
index 0000000..be1672e
--- /dev/null
+++ b/strace/tests/_newselect.c
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR__newselect
+
+# define TEST_SYSCALL_NR __NR__newselect
+# define TEST_SYSCALL_STR "_newselect"
+# include "xselect.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR__newselect")
+
+#endif
diff --git a/strace/tests/_newselect.test b/strace/tests/_newselect.test
new file mode 100755
index 0000000..3371d4d
--- /dev/null
+++ b/strace/tests/_newselect.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check _newselect syscall decoding.
+
+. "${srcdir=.}/select.test"
diff --git a/strace/tests/accept.c b/strace/tests/accept.c
new file mode 100644
index 0000000..8d42ba1
--- /dev/null
+++ b/strace/tests/accept.c
@@ -0,0 +1,85 @@
+/*
+ * Check decoding of accept syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef TEST_SYSCALL_NAME
+# define TEST_SYSCALL_NAME accept
+#endif
+
+#define TEST_SYSCALL_PREPARE connect_un()
+static void connect_un(void);
+#include "sockname.c"
+
+static void
+connect_un(void)
+{
+	int cfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (cfd < 0)
+		perror_msg_and_skip("socket");
+
+	struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = TEST_SOCKET ".connect"
+	};
+
+	(void) unlink(un.sun_path);
+	if (bind(cfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+	(void) unlink(un.sun_path);
+
+	un.sun_path[sizeof(TEST_SOCKET) - 1] = '\0';
+	if (connect(cfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("connect");
+}
+
+int
+main(void)
+{
+	int lfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (lfd < 0)
+		perror_msg_and_skip("socket");
+
+	(void) unlink(TEST_SOCKET);
+
+	const struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = TEST_SOCKET
+	};
+
+	if (bind(lfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+	if (listen(lfd, 16))
+		perror_msg_and_skip("listen");
+
+	test_sockname_syscall(lfd);
+
+	(void) unlink(TEST_SOCKET);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/accept.test b/strace/tests/accept.test
new file mode 100755
index 0000000..b5e0790
--- /dev/null
+++ b/strace/tests/accept.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of accept syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22
diff --git a/strace/tests/accept4.c b/strace/tests/accept4.c
new file mode 100644
index 0000000..d26e15c
--- /dev/null
+++ b/strace/tests/accept4.c
@@ -0,0 +1,44 @@
+/*
+ * Check decoding of accept4 syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+
+#if defined HAVE_ACCEPT4 && defined O_CLOEXEC
+
+# define TEST_SYSCALL_NAME accept4
+# define SUFFIX_ARGS , O_CLOEXEC
+# define SUFFIX_STR ", SOCK_CLOEXEC"
+# include "accept.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_ACCEPT4 && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/accept4.test b/strace/tests/accept4.test
new file mode 100755
index 0000000..722f25a
--- /dev/null
+++ b/strace/tests/accept4.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of accept4 syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a37
diff --git a/strace/tests/access.c b/strace/tests/access.c
new file mode 100644
index 0000000..2920db5
--- /dev/null
+++ b/strace/tests/access.c
@@ -0,0 +1,29 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_access
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "access_sample";
+
+	long rc = syscall(__NR_access, sample, F_OK);
+	printf("access(\"%s\", F_OK) = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	rc = syscall(__NR_access, sample, R_OK|W_OK|X_OK);
+	printf("access(\"%s\", R_OK|W_OK|X_OK) = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_access")
+
+#endif
diff --git a/strace/tests/access.test b/strace/tests/access.test
new file mode 100755
index 0000000..3ab2eb4
--- /dev/null
+++ b/strace/tests/access.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check access syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog > /dev/null
+run_strace -eaccess -a30 $args > "$EXP"
+
+# Filter out access() calls made by libc.
+grep -F access_sample < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/acct.c b/strace/tests/acct.c
new file mode 100644
index 0000000..ef11b0b
--- /dev/null
+++ b/strace/tests/acct.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_acct
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const char sample[] = "acct_sample";
+
+	long rc = syscall(__NR_acct, sample);
+	printf("acct(\"%s\") = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR__acct")
+
+#endif
diff --git a/strace/tests/acct.test b/strace/tests/acct.test
new file mode 100755
index 0000000..b9bca75
--- /dev/null
+++ b/strace/tests/acct.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check acct syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20
diff --git a/strace/tests/adjtimex.c b/strace/tests/adjtimex.c
new file mode 100644
index 0000000..9507fbe
--- /dev/null
+++ b/strace/tests/adjtimex.c
@@ -0,0 +1,83 @@
+/*
+ * This file is part of adjtimex strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <stdint.h>
+#include <string.h>
+#include <sys/timex.h>
+
+int
+main(void)
+{
+	adjtimex(NULL);
+	printf("adjtimex\\(NULL\\) = -1 EFAULT \\(%m\\)\n");
+
+	struct timex * const tx = tail_alloc(sizeof(*tx));
+	memset(tx, 0, sizeof(*tx));
+
+	int state = adjtimex(tx);
+	if (state < 0)
+		perror_msg_and_skip("adjtimex");
+
+	printf("adjtimex\\(\\{modes=0, offset=%jd, freq=%jd, maxerror=%jd"
+	       ", esterror=%jd, status=%s, constant=%jd, precision=%jd"
+	       ", tolerance=%jd, time=\\{%jd, %jd\\}, tick=%jd, ppsfreq=%jd"
+	       ", jitter=%jd, shift=%d, stabil=%jd, jitcnt=%jd, calcnt=%jd"
+	       ", errcnt=%jd, stbcnt=%jd"
+#ifdef HAVE_STRUCT_TIMEX_TAI
+	       ", tai=%d"
+#endif
+	       "\\}\\) = %d \\(TIME_[A-Z]+\\)\n",
+	       (intmax_t) tx->offset,
+	       (intmax_t) tx->freq,
+	       (intmax_t) tx->maxerror,
+	       (intmax_t) tx->esterror,
+	       tx->status ? "STA_[A-Z]+(\\|STA_[A-Z]+)*" : "0",
+	       (intmax_t) tx->constant,
+	       (intmax_t) tx->precision,
+	       (intmax_t) tx->tolerance,
+	       (intmax_t) tx->time.tv_sec,
+	       (intmax_t) tx->time.tv_usec,
+	       (intmax_t) tx->tick,
+	       (intmax_t) tx->ppsfreq,
+	       (intmax_t) tx->jitter,
+	       tx->shift,
+	       (intmax_t) tx->stabil,
+	       (intmax_t) tx->jitcnt,
+	       (intmax_t) tx->calcnt,
+	       (intmax_t) tx->errcnt,
+	       (intmax_t) tx->stbcnt,
+#ifdef HAVE_STRUCT_TIMEX_TAI
+	       tx->tai,
+#endif
+	       state);
+
+	return 0;
+}
diff --git a/strace/tests/adjtimex.test b/strace/tests/adjtimex.test
new file mode 100755
index 0000000..0140550
--- /dev/null
+++ b/strace/tests/adjtimex.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check adjtimex syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a 15 -e adjtimex $args > "$OUT"
+match_grep "$LOG" "$OUT"
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/aio.c b/strace/tests/aio.c
new file mode 100644
index 0000000..ab259f4
--- /dev/null
+++ b/strace/tests/aio.c
@@ -0,0 +1,215 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <fcntl.h>
+#include <inttypes.h>
+#include <stdio.h>
+#include <time.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+#if defined __NR_io_setup \
+ && defined __NR_io_submit \
+ && defined __NR_io_getevents \
+ && defined __NR_io_cancel \
+ && defined __NR_io_destroy
+# include <linux/aio_abi.h>
+
+int
+main(void)
+{
+	const unsigned int sizeof_data0 = 4096;
+	const unsigned int sizeof_data1 = 8192;
+	void *data0 = tail_alloc(sizeof_data0);
+	void *data1 = tail_alloc(sizeof_data1);
+
+	const struct iocb proto_cb[] = {
+		{
+			.aio_data = 0xfeedface11111111,
+			.aio_reqprio = 11,
+			.aio_buf = (unsigned long) data0,
+			.aio_offset = 0xdeface1facefeed,
+			.aio_nbytes = sizeof_data0
+		},
+		{
+			.aio_data = 0xfeedface22222222,
+			.aio_reqprio = 22,
+			.aio_buf = (unsigned long) data1,
+			.aio_offset = 0xdeface2cafef00d,
+			.aio_nbytes = sizeof_data1
+		}
+	};
+	const struct iocb *cb = tail_memdup(proto_cb, sizeof(proto_cb));
+
+	const struct iovec proto_iov0[] = {
+		{
+			.iov_base = data0,
+			.iov_len = sizeof_data0 / 4
+		},
+		{
+			.iov_base = data0 + sizeof_data0 / 4,
+			.iov_len = sizeof_data0 / 4 * 3
+		},
+	};
+	const struct iovec *iov0 = tail_memdup(proto_iov0, sizeof(proto_iov0));
+
+	const struct iovec proto_iov1[] = {
+		{
+			.iov_base = data1,
+			.iov_len = sizeof_data1 / 4
+		},
+		{
+			.iov_base = data1 + sizeof_data1 / 4,
+			.iov_len = sizeof_data1 / 4 * 3
+		},
+	};
+	const struct iovec *iov1 = tail_memdup(proto_iov1, sizeof(proto_iov1));
+
+	const struct iocb proto_cbv[] = {
+		{
+			.aio_data = 0xfeed11111111face,
+			.aio_lio_opcode = 7,
+			.aio_reqprio = 111,
+			.aio_buf = (unsigned long) iov0,
+			.aio_offset = 0xdeface1facefeed,
+			.aio_nbytes = ARRAY_SIZE(proto_iov0)
+		},
+		{
+			.aio_data = 0xfeed22222222face,
+			.aio_lio_opcode = 7,
+			.aio_reqprio = 222,
+			.aio_buf = (unsigned long) iov1,
+			.aio_offset = 0xdeface2cafef00d,
+			.aio_nbytes = ARRAY_SIZE(proto_iov1)
+		}
+	};
+	const struct iocb *cbv = tail_memdup(proto_cbv, sizeof(proto_cbv));
+
+	const struct iocb proto_cbc = {
+		.aio_data = 0xdeadbeefbadc0ded,
+		.aio_reqprio = 99,
+		.aio_fildes = -42
+	};
+	const struct iocb *cbc = tail_memdup(&proto_cbc, sizeof(proto_cbc));
+
+	const long proto_cbs[] = {
+		(long) &cb[0], (long) &cb[1]
+	};
+	const long *cbs = tail_memdup(proto_cbs, sizeof(proto_cbs));
+
+	const long proto_cbvs[] = {
+		(long) &cbv[0], (long) &cbv[1],
+	};
+	const long *cbvs = tail_memdup(proto_cbvs, sizeof(proto_cbvs));
+
+	unsigned long *ctx = tail_alloc(sizeof(unsigned long));
+	*ctx = 0;
+
+	const unsigned int nr = ARRAY_SIZE(proto_cb);
+	const unsigned long lnr = (unsigned long) (0xdeadbeef00000000ULL | nr);
+
+	const struct io_event *ev = tail_alloc(nr * sizeof(struct io_event));
+	const struct timespec proto_ts = { .tv_nsec = 123456789 };
+	const struct timespec *ts = tail_memdup(&proto_ts, sizeof(proto_ts));
+
+	(void) close(0);
+	if (open("/dev/zero", O_RDONLY))
+		perror_msg_and_skip("open: %s", "/dev/zero");
+
+	if (syscall(__NR_io_setup, lnr, ctx))
+		perror_msg_and_skip("io_setup");
+	printf("io_setup(%u, [%lu]) = 0\n", nr, *ctx);
+
+	assert(syscall(__NR_io_submit, *ctx, -1L, cbs) == -1);
+	printf("io_submit(%lu, -1, %p) = -1 %s (%m)\n",
+	       *ctx, cbs, errno2name());
+
+	if (syscall(__NR_io_submit, *ctx, nr, cbs) != (long) nr)
+		perror_msg_and_skip("io_submit");
+	printf("io_submit(%lu, %u, ["
+		"{data=%#llx, pread, reqprio=11, fildes=0, "
+			"buf=%p, nbytes=%u, offset=%lld}, "
+		"{data=%#llx, pread, reqprio=22, fildes=0, "
+			"buf=%p, nbytes=%u, offset=%lld}"
+		"]) = %u\n",
+	       *ctx, nr,
+	       (unsigned long long) cb[0].aio_data, data0,
+	       sizeof_data0, (long long) cb[0].aio_offset,
+	       (unsigned long long) cb[1].aio_data, data1,
+	       sizeof_data1, (long long) cb[1].aio_offset,
+	       nr);
+
+	assert(syscall(__NR_io_getevents, *ctx, nr, nr + 1, ev, ts) == (long) nr);
+	printf("io_getevents(%lu, %u, %u, ["
+		"{data=%#llx, obj=%p, res=%u, res2=0}, "
+		"{data=%#llx, obj=%p, res=%u, res2=0}"
+		"], {0, 123456789}) = %u\n",
+	       *ctx, nr, nr + 1,
+	       (unsigned long long) cb[0].aio_data, &cb[0], sizeof_data0,
+	       (unsigned long long) cb[1].aio_data, &cb[1], sizeof_data1,
+	       nr);
+
+	assert(syscall(__NR_io_cancel, *ctx, cbc, ev) == -1);
+	printf("io_cancel(%lu, {data=%#llx, pread, reqprio=99, fildes=-42}, %p) "
+		"= -1 %s (%m)\n",
+	       *ctx, (unsigned long long) cbc->aio_data, ev, errno2name());
+
+	if (syscall(__NR_io_submit, *ctx, nr, cbvs) != (long) nr)
+		perror_msg_and_skip("io_submit");
+	printf("io_submit(%lu, %u, ["
+		"{data=%#llx, preadv, reqprio=%hd, fildes=0, "
+			"iovec=[{iov_base=%p, iov_len=%u}"
+			", {iov_base=%p, iov_len=%u}], offset=%lld}, "
+		"{data=%#llx, preadv, reqprio=%hd, fildes=0, "
+			"iovec=[{iov_base=%p, iov_len=%u}"
+			", {iov_base=%p, iov_len=%u}], offset=%lld}"
+		"]) = %u\n",
+	       *ctx, nr,
+	       (unsigned long long) cbv[0].aio_data, cbv[0].aio_reqprio,
+	       iov0[0].iov_base, (unsigned int) iov0[0].iov_len,
+	       iov0[1].iov_base, (unsigned int) iov0[1].iov_len,
+	       (long long) cbv[0].aio_offset,
+	       (unsigned long long) cbv[1].aio_data, cbv[1].aio_reqprio,
+	       iov1[0].iov_base, (unsigned int) iov1[0].iov_len,
+	       iov1[1].iov_base, (unsigned int) iov1[1].iov_len,
+	       (long long) cbv[1].aio_offset,
+	       nr);
+
+	assert(syscall(__NR_io_destroy, *ctx) == 0);
+	printf("io_destroy(%lu) = 0\n", *ctx);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_io_*")
+
+#endif
diff --git a/strace/tests/aio.test b/strace/tests/aio.test
new file mode 100755
index 0000000..2ba90da
--- /dev/null
+++ b/strace/tests/aio.test
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+# Check io_* syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+syscalls=io_setup,io_submit,io_getevents,io_cancel,io_destroy
+run_strace_match_diff -a14 -e trace=$syscalls
diff --git a/strace/tests/alarm.c b/strace/tests/alarm.c
new file mode 100644
index 0000000..fc10b66
--- /dev/null
+++ b/strace/tests/alarm.c
@@ -0,0 +1,52 @@
+/*
+ * This file is part of alarm strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_alarm
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	int rc = syscall(__NR_alarm, (unsigned long) 0xffffffff0000002a);
+	printf("alarm(%u) = %d\n", 42, rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_alarm")
+
+#endif
diff --git a/strace/tests/alarm.test b/strace/tests/alarm.test
new file mode 100755
index 0000000..267b223
--- /dev/null
+++ b/strace/tests/alarm.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check alarm syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/attach-f-p.c b/strace/tests/attach-f-p.c
new file mode 100644
index 0000000..8e0f205
--- /dev/null
+++ b/strace/tests/attach-f-p.c
@@ -0,0 +1,145 @@
+/*
+ * This file is part of attach-f-p strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <errno.h>
+#include <pthread.h>
+#include <signal.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <time.h>
+#include <sys/syscall.h>
+#include <unistd.h>
+
+#define N 3
+
+typedef union {
+	void *ptr;
+	pid_t pid;
+} retval_t;
+
+typedef struct {
+	sigset_t set;
+	unsigned int no;
+} thread_arg_t;
+
+static const char text_parent[] = "attach-f-p.test parent";
+static const char *child[N] = {
+	"attach-f-p.test child 0",
+	"attach-f-p.test child 1",
+	"attach-f-p.test child 2"
+};
+static const int sigs[N] = { SIGALRM, SIGUSR1, SIGUSR2 };
+static const struct itimerspec its[N] = {
+	{ .it_value.tv_sec = 1 },
+	{ .it_value.tv_sec = 2 },
+	{ .it_value.tv_sec = 3 }
+};
+static thread_arg_t args[N] = {
+	{ .no = 0 },
+	{ .no = 1 },
+	{ .no = 2 }
+};
+
+static void *
+thread(void *a)
+{
+	thread_arg_t *arg = a;
+	int signo;
+	errno = sigwait(&arg->set, &signo);
+	if (errno)
+		perror_msg_and_fail("sigwait");
+	assert(chdir(child[arg->no]) == -1);
+	retval_t retval = { .pid = syscall(__NR_gettid) };
+	return retval.ptr;
+}
+
+int
+main(void)
+{
+	static timer_t timerid[N];
+	pthread_t t[N];
+	unsigned int i;
+
+	for (i = 0; i < N; ++i) {
+		sigemptyset(&args[i].set);
+		sigaddset(&args[i].set, sigs[i]);
+
+		errno = pthread_sigmask(SIG_BLOCK, &args[i].set, NULL);
+		if (errno)
+			perror_msg_and_fail("pthread_sigmask");
+	}
+
+	for (i = 0; i < N; ++i) {
+		struct sigevent sev = {
+			.sigev_notify = SIGEV_SIGNAL,
+			.sigev_signo = sigs[i]
+		};
+		if (timer_create(CLOCK_MONOTONIC, &sev, &timerid[i]))
+			perror_msg_and_skip("timer_create");
+
+		if (timer_settime(timerid[i], 0, &its[i], NULL))
+			perror_msg_and_fail("timer_settime");
+
+		errno = pthread_create(&t[i], NULL, thread, (void *) &args[i]);
+		if (errno)
+			perror_msg_and_fail("pthread_create");
+	}
+
+	if (write(3, "\n", 1) != 1)
+		perror_msg_and_fail("write");
+
+	for (i = 0; i < N; ++i) {
+		retval_t retval;
+		errno = pthread_join(t[i], &retval.ptr);
+		if (errno)
+			perror_msg_and_fail("pthread_join");
+		errno = ENOENT;
+		printf("%-5d chdir(\"%s\") = -1 ENOENT (%m)\n"
+		       "%-5d +++ exited with 0 +++\n",
+		       retval.pid, child[i], retval.pid);
+	}
+
+	/* sleep a bit more to let the tracer catch up */
+	if (timer_settime(timerid[0], 0, &its[0], NULL))
+		perror_msg_and_fail("timer_settime");
+	int signo;
+	errno = sigwait(&args[0].set, &signo);
+	if (errno)
+		perror_msg_and_fail("sigwait");
+
+	pid_t pid = getpid();
+	assert(chdir(text_parent) == -1);
+
+	printf("%-5d chdir(\"%s\") = -1 ENOENT (%m)\n"
+	       "%-5d +++ exited with 0 +++\n", pid, text_parent, pid);
+
+	return 0;
+}
diff --git a/strace/tests/attach-f-p.test b/strace/tests/attach-f-p.test
new file mode 100755
index 0000000..02230a0
--- /dev/null
+++ b/strace/tests/attach-f-p.test
@@ -0,0 +1,49 @@
+#!/bin/sh
+#
+# Check that -f -p attaches to threads properly.
+#
+# Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -f -p is implemented using /proc/$pid/task/
+[ -d /proc/self/task/ ] ||
+	framework_skip_ '/proc/self/task/ is not available'
+run_prog_skip_if_failed \
+	kill -0 $$
+run_prog ./attach-f-p > /dev/null 3>&1
+
+./set_ptracer_any sh -c "exec ./attach-f-p > $EXP 3> $OUT" > /dev/null &
+tracee_pid=$!
+
+while ! [ -s "$OUT" ]; do
+	kill -0 $tracee_pid 2> /dev/null ||
+		fail_ 'set_ptracer_any sleep failed'
+done
+
+run_strace -a32 -f -echdir -esignal=none -p $tracee_pid
+match_diff "$LOG" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/attach-p-cmd-cmd.c b/strace/tests/attach-p-cmd-cmd.c
new file mode 100644
index 0000000..d2b3ca1
--- /dev/null
+++ b/strace/tests/attach-p-cmd-cmd.c
@@ -0,0 +1,44 @@
+/*
+ * This file is part of attach-p-cmd strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	static const char text[] = "attach-p-cmd.test cmd";
+	pid_t pid = getpid();
+	assert(chdir(text) == -1);
+	printf("%-5d chdir(\"%s\") = -1 ENOENT (%m)\n"
+	       "%-5d +++ exited with 0 +++\n", pid, text, pid);
+	return 0;
+}
diff --git a/strace/tests/attach-p-cmd-p.c b/strace/tests/attach-p-cmd-p.c
new file mode 100644
index 0000000..a059ce5
--- /dev/null
+++ b/strace/tests/attach-p-cmd-p.c
@@ -0,0 +1,63 @@
+/*
+ * This file is part of attach-p-cmd strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <signal.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+static void
+handler(int signo)
+{
+}
+
+int
+main(int ac, char **av)
+{
+	if (ac < 2)
+		error_msg_and_fail("missing operand");
+
+	if (ac > 2)
+		error_msg_and_fail("extra operand");
+
+	const struct sigaction act = { .sa_handler = handler };
+	if (sigaction(SIGALRM, &act, NULL))
+		perror_msg_and_skip("sigaction");
+
+	sigset_t mask = {};
+	sigaddset(&mask, SIGALRM);
+	if (sigprocmask(SIG_UNBLOCK, &mask, NULL))
+		perror_msg_and_skip("sigprocmask");
+
+	alarm(atoi(av[1]));
+	pause();
+
+	return !(chdir("attach-p-cmd.test -p") && ENOENT == errno);
+}
diff --git a/strace/tests/attach-p-cmd.test b/strace/tests/attach-p-cmd.test
new file mode 100755
index 0000000..f8c1d1c
--- /dev/null
+++ b/strace/tests/attach-p-cmd.test
@@ -0,0 +1,53 @@
+#!/bin/sh
+#
+# Check that simultaneous use of -p option and tracing of a command works.
+#
+# Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed \
+	kill -0 $$
+run_prog ./attach-p-cmd-cmd > /dev/null
+run_prog ./attach-p-cmd-p 1 > /dev/null
+
+./set_ptracer_any ./attach-p-cmd-p 1 > "$OUT" &
+tracee_pid=$!
+
+while ! [ -s "$OUT" ]; do
+	kill -0 $tracee_pid 2> /dev/null ||
+		fail_ 'set_ptracer_any sleep failed'
+done
+
+run_strace -a30 -echdir -p $tracee_pid ./attach-p-cmd-cmd > "$OUT"
+{
+printf '%-5d --- SIGALRM {si_signo=SIGALRM, si_code=SI_KERNEL} ---\n' $tracee_pid
+printf '%-5d chdir("attach-p-cmd.test -p") = -1 ENOENT (No such file or directory)\n' $tracee_pid
+printf '%-5d +++ exited with 0 +++\n' $tracee_pid
+} >> "$OUT"
+
+match_diff "$LOG" "$OUT"
+rm -f "$OUT"
diff --git a/strace/tests/bexecve.test b/strace/tests/bexecve.test
new file mode 100755
index 0000000..f1ab04f
--- /dev/null
+++ b/strace/tests/bexecve.test
@@ -0,0 +1,58 @@
+#!/bin/sh
+#
+# Check -bexecve behavior.
+#
+# Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_strace_redir()
+{
+	args="$*"
+	$STRACE "$@" 2> "$LOG"
+}
+
+run_strace_redir -enone ./set_ptracer_any true ||
+	dump_log_and_fail_with "$STRACE $args: unexpected exit status"
+
+run_strace_redir -enone ./set_ptracer_any false
+[ $? -eq 1 ] ||
+	dump_log_and_fail_with "$STRACE $args: unexpected exit status"
+
+run_strace_redir -bexecve -enone ./set_ptracer_any false ||
+	dump_log_and_fail_with "$STRACE $args: unexpected exit status"
+
+pattern_detached='[^:]*strace: Process [1-9][0-9]* detached'
+pattern_personality='[^:]*strace: \[ Process PID=[1-9][0-9]* runs in .* mode. \]'
+
+LC_ALL=C grep -x "$pattern_detached" "$LOG" > /dev/null ||
+	dump_log_and_fail_with "$STRACE $args: output mismatch"
+
+if LC_ALL=C grep -E -v -x "($pattern_detached|$pattern_personality)" "$LOG" > /dev/null; then
+	dump_log_and_fail_with "$STRACE $args: unexpected output"
+fi
+
+exit 0
diff --git a/strace/tests/bpf.c b/strace/tests/bpf.c
new file mode 100644
index 0000000..d9b05e5
--- /dev/null
+++ b/strace/tests/bpf.c
@@ -0,0 +1,129 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <stdint.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+#if defined HAVE_UNION_BPF_ATTR_LOG_BUF && defined __NR_bpf
+# include <linux/bpf.h>
+
+static const struct bpf_insn insns[] = {
+	{ .code = BPF_JMP | BPF_EXIT }
+};
+
+static char log_buf[4096];
+
+static int
+map_create(void)
+{
+	union bpf_attr attr = {
+		.key_size = 4,
+		.value_size = 8,
+		.max_entries = 256
+	};
+	return syscall(__NR_bpf, BPF_MAP_CREATE, &attr, sizeof(attr));
+}
+
+static int
+map_any(int cmd)
+{
+	union bpf_attr attr = {
+		.map_fd = -1,
+		.key = 0xdeadbeef,
+		.value = 0xbadc0ded
+	};
+	return syscall(__NR_bpf, cmd, &attr, sizeof(attr));
+}
+
+static int
+prog_load(void)
+{
+	union bpf_attr attr = {
+		.insn_cnt = sizeof(insns) / sizeof(insns[0]),
+		.insns = (unsigned long) insns,
+		.license = (unsigned long) "GPL",
+		.log_level = 42,
+		.log_size = sizeof(log_buf),
+		.log_buf = (unsigned long) log_buf
+	};
+	return syscall(__NR_bpf, BPF_PROG_LOAD, &attr, sizeof(attr));
+}
+
+int
+main(void)
+{
+	if (!map_create())
+		perror_msg_and_skip("BPF_MAP_CREATE");
+	printf("bpf\\(BPF_MAP_CREATE, "
+	       "\\{map_type=BPF_MAP_TYPE_UNSPEC, key_size=4, value_size=8, max_entries=256\\}, "
+	       "%u\\) += -1 .*\n",
+		(unsigned) sizeof(union bpf_attr));
+
+	if (!map_any(BPF_MAP_LOOKUP_ELEM))
+		perror_msg_and_skip("BPF_MAP_LOOKUP_ELEM");
+	printf("bpf\\(BPF_MAP_LOOKUP_ELEM, "
+	       "\\{map_fd=-1, key=0xdeadbeef\\}, %u\\) += -1 .*\n",
+		(unsigned) sizeof(union bpf_attr));
+
+	if (!map_any(BPF_MAP_UPDATE_ELEM))
+		perror_msg_and_skip("BPF_MAP_UPDATE_ELEM");
+	printf("bpf\\(BPF_MAP_UPDATE_ELEM, "
+	       "\\{map_fd=-1, key=0xdeadbeef, value=0xbadc0ded, flags=BPF_ANY\\}, "
+	       "%u\\) += -1 .*\n",
+		(unsigned) sizeof(union bpf_attr));
+
+	if (!map_any(BPF_MAP_DELETE_ELEM))
+		perror_msg_and_skip("BPF_MAP_DELETE_ELEM");
+	printf("bpf\\(BPF_MAP_DELETE_ELEM, "
+	       "\\{map_fd=-1, key=0xdeadbeef\\}, %u\\) += -1 .*\n",
+		(unsigned) sizeof(union bpf_attr));
+
+	if (!map_any(BPF_MAP_GET_NEXT_KEY))
+		perror_msg_and_skip("BPF_MAP_GET_NEXT_KEY");
+	printf("bpf\\(BPF_MAP_GET_NEXT_KEY, "
+	       "\\{map_fd=-1, key=0xdeadbeef\\}, %u\\) += -1 .*\n",
+		(unsigned) sizeof(union bpf_attr));
+
+	if (!prog_load())
+		perror_msg_and_skip("BPF_PROG_LOAD");
+	printf("bpf\\(BPF_PROG_LOAD, "
+	       "\\{prog_type=BPF_PROG_TYPE_UNSPEC, insn_cnt=1, insns=%p, "
+	       "license=\"GPL\", log_level=42, log_size=4096, log_buf=%p, "
+	       "kern_version=0\\}, %u\\) += -1 .*\n",
+		insns, log_buf, (unsigned) sizeof(union bpf_attr));
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_bpf")
+
+#endif
diff --git a/strace/tests/bpf.test b/strace/tests/bpf.test
new file mode 100755
index 0000000..6c77ae1
--- /dev/null
+++ b/strace/tests/bpf.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check bpf syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -ebpf $args > "$OUT"
+match_grep "$LOG" "$OUT"
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/brk.c b/strace/tests/brk.c
new file mode 100644
index 0000000..ed311aa
--- /dev/null
+++ b/strace/tests/brk.c
@@ -0,0 +1,22 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_brk
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_brk, NULL);
+	printf("brk\\(NULL\\) = %#lx\n", rc);
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_brk")
+
+#endif
diff --git a/strace/tests/brk.test b/strace/tests/brk.test
new file mode 100755
index 0000000..8c0e2e4
--- /dev/null
+++ b/strace/tests/brk.test
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+# Check brk syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a10 -ebrk $args > "$EXP"
+match_grep "$LOG" "$EXP"
+rm -f "$EXP"
diff --git a/strace/tests/btrfs-v.test b/strace/tests/btrfs-v.test
new file mode 100755
index 0000000..1ee17b4
--- /dev/null
+++ b/strace/tests/btrfs-v.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check verbose decoding of btrfs ioctl
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./btrfs -v > /dev/null
+run_strace -a16 -veioctl $args > "$EXP"
+check_prog grep
+grep -v '^ioctl([012],' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/btrfs-vw.test b/strace/tests/btrfs-vw.test
new file mode 100755
index 0000000..c7e40ad
--- /dev/null
+++ b/strace/tests/btrfs-vw.test
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+# Check verbose decoding of btrfs ioctl w/ live ioctls.
+
+# WARNING: USE OF THIS TEST WILL MODIFY AN EXISTING BTRFS FILE SYSTEM
+
+# Typical usage:
+# mkfs.btrfs <dev>
+# mount <dev> /mnt
+# BTRFS_MOUNTPOINT=/mnt make check TESTS="btrfs-vw"
+# umount /mnt
+
+. "${srcdir=.}/init.sh"
+
+if [ -z "${BTRFS_MOUNTPOINT}" ]; then
+    skip_ "\$BTRFS_MOUNTPOINT not set"
+elif [ ! -d "${BTRFS_MOUNTPOINT}" ]; then
+    skip_ "\$BTRFS_MOUNTPOINT does not point to a directory"
+fi
+
+run_prog ./btrfs -v -w "${BTRFS_MOUNTPOINT}" > /dev/null
+run_strace -a16 -veioctl $args > "$EXP"
+check_prog grep
+grep -v '^ioctl([012],' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/btrfs-w.test b/strace/tests/btrfs-w.test
new file mode 100755
index 0000000..6238dca
--- /dev/null
+++ b/strace/tests/btrfs-w.test
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+# Check decoding of btrfs ioctl w/ live ioctls.
+
+# WARNING: USE OF THIS TEST WILL MODIFY AN EXISTING BTRFS FILE SYSTEM
+
+# Typical usage:
+# mkfs.btrfs <dev>
+# mount <dev> /mnt
+# BTRFS_MOUNTPOINT=/mnt make check TESTS="btrfs-w"
+# umount /mnt
+
+. "${srcdir=.}/init.sh"
+
+if [ -z "${BTRFS_MOUNTPOINT}" ]; then
+    skip_ "\$BTRFS_MOUNTPOINT not set"
+elif [ ! -d "${BTRFS_MOUNTPOINT}" ]; then
+    skip_ "\$BTRFS_MOUNTPOINT does not point to a directory"
+fi
+
+run_prog ./btrfs -w "${BTRFS_MOUNTPOINT}" > /dev/null
+run_strace -a16 -eioctl $args > "$EXP"
+check_prog grep
+grep -v '^ioctl([012],' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/btrfs.c b/strace/tests/btrfs.c
new file mode 100644
index 0000000..e5940ce
--- /dev/null
+++ b/strace/tests/btrfs.c
@@ -0,0 +1,1934 @@
+#include "tests.h"
+
+#ifdef HAVE_LINUX_BTRFS_H
+
+#include <errno.h>
+#include <fcntl.h>
+#include <inttypes.h>
+#include <limits.h>
+#include <stdbool.h>
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/ioctl.h>
+#include <sys/stat.h>
+#include <sys/vfs.h>
+#include <linux/fs.h>
+#include <linux/btrfs.h>
+#include <linux/magic.h>
+#include "xlat.h"
+
+#include "xlat/btrfs_balance_args.h"
+#include "xlat/btrfs_balance_flags.h"
+#include "xlat/btrfs_balance_state.h"
+#include "xlat/btrfs_compress_types.h"
+#include "xlat/btrfs_defrag_flags.h"
+#include "xlat/btrfs_dev_stats_values.h"
+#include "xlat/btrfs_dev_stats_flags.h"
+#include "xlat/btrfs_qgroup_inherit_flags.h"
+#include "xlat/btrfs_qgroup_limit_flags.h"
+#include "xlat/btrfs_scrub_flags.h"
+#include "xlat/btrfs_send_flags.h"
+#include "xlat/btrfs_space_info_flags.h"
+#include "xlat/btrfs_snap_flags_v2.h"
+#include "xlat/btrfs_tree_objectids.h"
+#include "xlat/btrfs_features_compat.h"
+#include "xlat/btrfs_features_compat_ro.h"
+#include "xlat/btrfs_features_incompat.h"
+#include "xlat/btrfs_key_types.h"
+
+#ifdef HAVE_LINUX_FIEMAP_H
+# include <linux/fiemap.h>
+# include "xlat/fiemap_flags.h"
+# include "xlat/fiemap_extent_flags.h"
+#endif
+
+#ifndef BTRFS_LABEL_SIZE
+# define BTRFS_LABEL_SIZE 256
+#endif
+
+#ifndef BTRFS_NAME_LEN
+# define BTRFS_NAME_LEN 255
+#endif
+
+/*
+ * Prior to Linux 3.12, the BTRFS_IOC_DEFAULT_SUBVOL used u64 in
+ * its definition, which isn't exported by the kernel.
+ */
+typedef __u64 u64;
+
+static const char *btrfs_test_root;
+static int btrfs_test_dir_fd;
+static bool verbose = false;
+static bool write_ok = false;
+
+const unsigned char uuid_reference[BTRFS_UUID_SIZE] = {
+	0x01, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef,
+	0xfe, 0xdc, 0xba, 0x98, 0x76, 0x54, 0x32, 0x10,
+};
+
+const char uuid_reference_string[] = "01234567-89ab-cdef-fedc-ba9876543210";
+
+#ifndef BTRFS_IOC_QUOTA_RESCAN
+struct btrfs_ioctl_quota_rescan_args {
+	uint64_t flags, progress, reserved[6];
+};
+# define BTRFS_IOC_QUOTA_RESCAN _IOW(BTRFS_IOCTL_MAGIC, 44, \
+					struct btrfs_ioctl_quota_rescan_args)
+# define BTRFS_IOC_QUOTA_RESCAN_STATUS _IOR(BTRFS_IOCTL_MAGIC, 45, \
+					struct btrfs_ioctl_quota_rescan_args)
+#endif
+
+#ifndef BTRFS_IOC_QUOTA_RESCAN_WAIT
+# define BTRFS_IOC_QUOTA_RESCAN_WAIT _IO(BTRFS_IOCTL_MAGIC, 46)
+#endif
+
+#ifndef BTRFS_IOC_GET_FEATURES
+# define BTRFS_IOC_GET_FEATURES _IOR(BTRFS_IOCTL_MAGIC, 57, \
+                                   struct btrfs_ioctl_feature_flags)
+# define BTRFS_IOC_SET_FEATURES _IOW(BTRFS_IOCTL_MAGIC, 57, \
+                                   struct btrfs_ioctl_feature_flags[2])
+# define BTRFS_IOC_GET_SUPPORTED_FEATURES _IOR(BTRFS_IOCTL_MAGIC, 57, \
+                                   struct btrfs_ioctl_feature_flags[3])
+#endif
+
+#ifndef HAVE_STRUCT_BTRFS_IOCTL_FEATURE_FLAGS_COMPAT_FLAGS
+struct btrfs_ioctl_feature_flags {
+        uint64_t compat_flags;
+        uint64_t compat_ro_flags;
+        uint64_t incompat_flags;
+};
+#endif
+
+#ifndef HAVE_STRUCT_BTRFS_IOCTL_DEFRAG_RANGE_ARGS_START
+struct btrfs_ioctl_defrag_range_args {
+        uint64_t start;
+        uint64_t len;
+        uint64_t flags;
+        uint32_t extent_thresh;
+        uint32_t compress_type;
+        uint32_t unused[4];
+};
+#endif
+
+#ifndef FIDEDUPERANGE
+# define FIDEDUPERANGE   _IOWR(0x94, 54, struct file_dedupe_range)
+struct file_dedupe_range_info {
+	int64_t dest_fd;	/* in - destination file */
+	uint64_t dest_offset;	/* in - start of extent in destination */
+	uint64_t bytes_deduped;	/* out - total # of bytes we were able
+				 * to dedupe from this file. */
+	/* status of this dedupe operation:
+	 * < 0 for error
+	 * == FILE_DEDUPE_RANGE_SAME if dedupe succeeds
+	 * == FILE_DEDUPE_RANGE_DIFFERS if data differs
+	 */
+	int32_t status;		/* out - see above description */
+	uint32_t reserved;	/* must be zero */
+};
+
+struct file_dedupe_range {
+	uint64_t src_offset;	/* in - start of extent in source */
+	uint64_t src_length;	/* in - length of extent */
+	uint16_t dest_count;	/* in - total elements in info array */
+	uint16_t reserved1;	/* must be zero */
+	uint32_t reserved2;	/* must be zero */
+	struct file_dedupe_range_info info[0];
+};
+#endif
+
+#ifndef BTRFS_IOC_TREE_SEARCH_V2
+# define BTRFS_IOC_TREE_SEARCH_V2 _IOWR(BTRFS_IOCTL_MAGIC, 17, \
+                                           struct btrfs_ioctl_search_args_v2)
+struct btrfs_ioctl_search_args_v2 {
+	struct btrfs_ioctl_search_key key; /* in/out - search parameters */
+	uint64_t buf_size;		   /* in - size of buffer
+					    * out - on EOVERFLOW: needed size
+					    *       to store item */
+        uint64_t buf[0];		   /* out - found items */
+};
+#endif
+
+
+static const char *
+maybe_print_uint64max(uint64_t val)
+{
+	if (val == UINT64_MAX)
+		return " /* UINT64_MAX */";
+	return "";
+}
+
+/* takes highest valid flag bit */
+static uint64_t
+max_flags_plus_one(int bit)
+{
+	int i;
+	uint64_t val = 0;
+	if (bit == -1)
+		return 1;
+	for (i = 0; i <= bit + 1 && i < 64; i++)
+		val |= (1ULL << i);
+	return val;
+}
+
+/*
+ * Consumes no arguments, returns nothing:
+ *
+ * - BTRFS_IOC_TRANS_START
+ * - BTRFS_IOC_TRANS_END
+ */
+static void
+btrfs_test_trans_ioctls(void)
+{
+	ioctl(-1, BTRFS_IOC_TRANS_START, NULL);
+	printf("ioctl(-1, BTRFS_IOC_TRANS_START) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_TRANS_END, NULL);
+	printf("ioctl(-1, BTRFS_IOC_TRANS_END) = -1 EBADF (%m)\n");
+}
+
+/*
+ * Consumes no arguments, returns nothing:
+ * - BTRFS_IOC_SYNC
+ *
+ * Consumes argument, returns nothing
+ * - BTRFS_IOC_WAIT_SYNC
+ */
+static void
+btrfs_test_sync_ioctls(void)
+{
+	uint64_t u64val = 0xdeadbeefbadc0ded;
+
+	ioctl(-1, BTRFS_IOC_SYNC, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SYNC) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_WAIT_SYNC, NULL);
+	printf("ioctl(-1, BTRFS_IOC_WAIT_SYNC, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_WAIT_SYNC, &u64val);
+	printf("ioctl(-1, BTRFS_IOC_WAIT_SYNC, [%" PRIu64
+	       "]) = -1 EBADF (%m)\n", u64val);
+
+	/*
+	 * The live test of BTRFS_IOC_SYNC happens as a part of the test
+	 * for BTRFS_IOC_LOGICAL_INO
+	 */
+}
+
+static void
+btrfs_print_qgroup_inherit(struct btrfs_qgroup_inherit *inherit)
+{
+	printf("{flags=");
+	printflags(btrfs_qgroup_inherit_flags, inherit->flags,
+		   "BTRFS_QGROUP_INHERIT_???");
+	printf(", num_qgroups=%" PRI__u64
+	       ", num_ref_copies=%" PRI__u64
+	       ", num_excl_copies=%" PRI__u64", lim={flags=",
+	       inherit->num_qgroups, inherit->num_ref_copies,
+	       inherit->num_excl_copies);
+	printflags(btrfs_qgroup_limit_flags,
+		   inherit->lim.flags,
+		   "BTRFS_QGROUP_LIMIT_???");
+	printf(", max_rfer=%" PRI__u64 ", max_excl=%" PRI__u64
+	       ", rsv_rfer=%" PRI__u64 ", rsv_excl=%" PRI__u64
+	       "}, qgroups=",
+	       inherit->lim.max_rfer, inherit->lim.max_excl,
+	       inherit->lim.rsv_rfer, inherit->lim.rsv_excl);
+	if (verbose) {
+		unsigned int i;
+		printf("[");
+		for (i = 0; i < inherit->num_qgroups; i++) {
+			if (i > 0)
+				printf(", ");
+			printf("%" PRI__u64, inherit->qgroups[i]);
+		}
+		printf("]");
+	} else
+		printf("...");
+	printf("}");
+}
+
+
+static void
+btrfs_print_vol_args_v2(struct btrfs_ioctl_vol_args_v2 *args, int print_qgroups)
+{
+	printf("{fd=%d, flags=", (int) args->fd);
+	printflags(btrfs_snap_flags_v2, args->flags, "BTRFS_SUBVOL_???");
+
+	if (args->flags & BTRFS_SUBVOL_QGROUP_INHERIT) {
+		printf(", size=%" PRI__u64 ", qgroup_inherit=", args->size);
+		if (args->qgroup_inherit && print_qgroups)
+			btrfs_print_qgroup_inherit(args->qgroup_inherit);
+		else if (args->qgroup_inherit)
+			printf("%p", args->qgroup_inherit);
+		else
+			printf("NULL");
+	}
+	printf(", name=\"%s\"}", args->name);
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_SNAP_CREATE
+ * - BTRFS_IOC_SUBVOL_CREATE
+ * - BTRFS_IOC_SNAP_DESTROY
+ * - BTRFS_IOC_DEFAULT_SUBVOL
+ *
+ * Consumes argument, returns u64:
+ * - BTRFS_IOC_SNAP_CREATE_V2
+ * - BTRFS_IOC_SUBVOL_CREATE_V2
+ */
+
+static void
+btrfs_test_subvol_ioctls(void)
+{
+	const char *subvol_name = "subvol-name";
+	char *long_subvol_name;
+	void *bad_pointer = (void *) (unsigned long) 0xdeadbeeffffffeed;
+	uint64_t u64val = 0xdeadbeefbadc0ded;
+	struct btrfs_ioctl_vol_args vol_args = {};
+	struct btrfs_ioctl_vol_args_v2 vol_args_v2 = {
+		.fd = 2,
+		.flags = max_flags_plus_one(2),
+	};
+
+	long_subvol_name = malloc(BTRFS_PATH_NAME_MAX);
+	if (!long_subvol_name)
+		perror_msg_and_fail("malloc failed");
+	memset(long_subvol_name, 'f', BTRFS_PATH_NAME_MAX);
+	long_subvol_name[BTRFS_PATH_NAME_MAX - 1] = '\0';
+
+	strcpy(vol_args.name, subvol_name);
+
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE, "
+	       "{fd=0, name=\"%s\"}) = -1 EBADF (%m)\n", vol_args.name);
+
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE, "
+	       "{fd=0, name=\"%s\"}) = -1 EBADF (%m)\n", vol_args.name);
+
+	ioctl(-1, BTRFS_IOC_SNAP_DESTROY, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_DESTROY,"
+	       " {fd=0, name=\"%s\"}) = -1 EBADF (%m)\n", vol_args.name);
+
+	strncpy(vol_args.name, long_subvol_name, BTRFS_PATH_NAME_MAX);
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE,"
+	       " {fd=0, name=\"%s\"}) = -1 EBADF (%m)\n", vol_args.name);
+
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE,"
+	       " {fd=0, name=\"%s\"}) = -1 EBADF (%m)\n", vol_args.name);
+
+	ioctl(-1, BTRFS_IOC_SNAP_DESTROY, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_DESTROY,"
+	       " {fd=0, name=\"%s\"}) = -1 EBADF (%m)\n", vol_args.name);
+
+	long_subvol_name = realloc(long_subvol_name, BTRFS_SUBVOL_NAME_MAX);
+	if (!long_subvol_name)
+		perror_msg_and_fail("realloc failed");
+
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, NULL) = -1 EBADF (%m)\n");
+
+	strcpy(vol_args_v2.name, subvol_name);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 1);
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 1);
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	strncpy(vol_args_v2.name, long_subvol_name, BTRFS_SUBVOL_NAME_MAX);
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 1);
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 1);
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	strcpy(vol_args_v2.name, subvol_name);
+	vol_args_v2.qgroup_inherit = bad_pointer;
+
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 0);
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 0);
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	const unsigned int n_qgroups = 8;
+	unsigned int i;
+	struct btrfs_qgroup_inherit *inherit;
+	vol_args_v2.size =
+		sizeof(*inherit) + n_qgroups * sizeof(inherit->qgroups[0]);
+	inherit = tail_alloc(vol_args_v2.size);
+
+	inherit->flags = 0x3;
+	inherit->num_ref_copies = 0;
+	inherit->num_excl_copies = 0;
+	inherit->num_qgroups = n_qgroups;
+	for (i = 0; i < n_qgroups; i++)
+		inherit->qgroups[i] = 1ULL << i;
+	inherit->lim.flags = 0x7f;
+	inherit->lim.max_rfer = u64val;
+	inherit->lim.max_excl = u64val;
+	inherit->lim.rsv_rfer = u64val;
+	inherit->lim.rsv_excl = u64val;
+	vol_args_v2.qgroup_inherit = inherit;
+
+	printf("ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 1);
+	ioctl(-1, BTRFS_IOC_SNAP_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, ");
+	btrfs_print_vol_args_v2(&vol_args_v2, 1);
+	ioctl(-1, BTRFS_IOC_SUBVOL_CREATE_V2, &vol_args_v2);
+	printf(") = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_DEFAULT_SUBVOL, NULL);
+	printf("ioctl(-1, BTRFS_IOC_DEFAULT_SUBVOL, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_DEFAULT_SUBVOL, &u64val);
+	printf("ioctl(-1, BTRFS_IOC_DEFAULT_SUBVOL, [%"
+	       PRIu64 "]) = -1 EBADF (%m)\n", u64val);
+
+	printf("ioctl(-1, BTRFS_IOC_SUBVOL_SETFLAGS, ");
+	printflags(btrfs_snap_flags_v2, vol_args_v2.flags,
+		   "BTRFS_SUBVOL_???");
+	ioctl(-1, BTRFS_IOC_SUBVOL_SETFLAGS, &vol_args_v2.flags);
+	printf(") = -1 EBADF (%m)\n");
+
+	if (write_ok) {
+		struct btrfs_ioctl_vol_args_v2 args_passed;
+		/*
+		 * Returns transid if flags & BTRFS_SUBVOL_CREATE_ASYNC
+		 * - BTRFS_IOC_SNAP_CREATE_V2
+		 * - BTRFS_IOC_SUBVOL_CREATE_V2
+		 */
+		int subvolfd;
+
+		strncpy(vol_args_v2.name, subvol_name,
+			sizeof(vol_args_v2.name));
+		vol_args_v2.flags = BTRFS_SUBVOL_CREATE_ASYNC;
+		vol_args_v2.size = 0;
+		vol_args_v2.qgroup_inherit = NULL;
+		args_passed = vol_args_v2;
+		printf("ioctl(%d, BTRFS_IOC_SUBVOL_CREATE_V2, ",
+			btrfs_test_dir_fd);
+		btrfs_print_vol_args_v2(&vol_args_v2, 1);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SUBVOL_CREATE_V2,
+		      &args_passed);
+		printf(" => {transid=%" PRI__u64"}) = 0\n",
+			args_passed.transid);
+
+		subvolfd = openat(btrfs_test_dir_fd, subvol_name,
+				  O_RDONLY|O_DIRECTORY);
+		if (subvolfd < 0)
+			perror_msg_and_fail("openat(%s) failed", subvol_name);
+
+		strncpy(vol_args_v2.name, long_subvol_name, BTRFS_NAME_LEN);
+		vol_args_v2.fd = subvolfd;
+		args_passed = vol_args_v2;
+		printf("ioctl(%d, BTRFS_IOC_SNAP_CREATE_V2, ",
+		       btrfs_test_dir_fd);
+		btrfs_print_vol_args_v2(&args_passed, 1);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SNAP_CREATE_V2,
+		      &args_passed);
+		printf(" => {transid=%" PRI__u64"}) = 0\n",
+			args_passed.transid);
+
+		/* This only works when mounted w/ -ouser_subvol_rm_allowed */
+		strncpy(vol_args.name, long_subvol_name, 255);
+		vol_args.name[255] = 0;
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SNAP_DESTROY, &vol_args);
+		printf("ioctl(%d, BTRFS_IOC_SNAP_DESTROY, "
+		       "{fd=%d, name=\"%.*s\"}) = 0\n",
+		       btrfs_test_dir_fd, (int) vol_args.fd, 255, long_subvol_name);
+
+		strcpy(vol_args.name, subvol_name);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SNAP_DESTROY, &vol_args);
+		printf("ioctl(%d, BTRFS_IOC_SNAP_DESTROY, "
+		       "{fd=%d, name=\"%s\"}) = 0\n",
+		       btrfs_test_dir_fd, (int) vol_args.fd, subvol_name);
+
+		close(subvolfd);
+	}
+	free(long_subvol_name);
+}
+
+static void
+btrfs_print_balance_args(struct btrfs_balance_args *args)
+{
+	printf("{profiles=");
+	printflags(btrfs_space_info_flags, args->profiles,
+		   "BTRFS_BLOCK_GROUP_???");
+	printf(", usage=%"PRI__u64 "%s, devid=%"PRI__u64 "%s, pstart=%"PRI__u64
+	       "%s, pend=%"PRI__u64 "%s, vstart=%"PRI__u64 "%s, vend=%"PRI__u64
+	       "%s, target=%"PRI__u64 "%s, flags=",
+		args->usage, maybe_print_uint64max(args->usage),
+		args->devid, maybe_print_uint64max(args->devid),
+		args->pstart, maybe_print_uint64max(args->pstart),
+		args->pend, maybe_print_uint64max(args->pend),
+		args->vstart, maybe_print_uint64max(args->vstart),
+		args->vend, maybe_print_uint64max(args->vend),
+		args->target, maybe_print_uint64max(args->target));
+	printflags(btrfs_balance_args, args->flags, "BTRFS_BALANCE_ARGS_???");
+	printf("}");
+}
+
+/*
+ * Accepts argument, returns nothing
+ * - BTRFS_IOC_BALANCE
+ * - BTRFS_IOC_BALANCE_CTL
+ *
+ * Accepts argument, returns argument
+ * - BTRFS_IOC_BALANCE_V2
+ */
+static void
+btrfs_test_balance_ioctls(void)
+{
+	struct btrfs_ioctl_balance_args args = {
+		.flags = 0x3f,
+		.data = {
+			.profiles = 0x7,
+			.flags = 0x7,
+			.devid = 1,
+			.pend = -1ULL,
+			.vend = -1ULL,
+		},
+
+		.meta = {
+			.profiles = 0x38,
+			.flags = 0x38,
+			.devid = 1,
+		},
+
+		.sys = {
+			.profiles = 0x1c0 | (1ULL << 48),
+			.flags = 0x4c0,
+			.devid = 1,
+		},
+	};
+	struct btrfs_ioctl_vol_args vol_args = {};
+
+	ioctl(-1, BTRFS_IOC_BALANCE_CTL, 1);
+	printf("ioctl(-1, BTRFS_IOC_BALANCE_CTL, "
+	       "BTRFS_BALANCE_CTL_PAUSE) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_BALANCE_CTL, 2);
+	printf("ioctl(-1, BTRFS_IOC_BALANCE_CTL, "
+	       "BTRFS_BALANCE_CTL_CANCEL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_BALANCE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_BALANCE) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_BALANCE, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_BALANCE) = -1 EBADF (%m)\n");
+
+	/* struct btrfs_ioctl_balance_args */
+	ioctl(-1, BTRFS_IOC_BALANCE_V2, NULL);
+	printf("ioctl(-1, BTRFS_IOC_BALANCE_V2, NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_BALANCE_V2, {flags=");
+	printflags(btrfs_balance_flags, args.flags, "BTRFS_BALANCE_???");
+	printf(", data=");
+	btrfs_print_balance_args(&args.data);
+	printf(", meta=");
+	btrfs_print_balance_args(&args.meta);
+	printf(", sys=");
+	btrfs_print_balance_args(&args.sys);
+	ioctl(-1, BTRFS_IOC_BALANCE_V2, &args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	if (write_ok) {
+		args.flags = BTRFS_BALANCE_DATA | BTRFS_BALANCE_METADATA |
+			     BTRFS_BALANCE_SYSTEM;
+		args.data.flags = 0;
+		args.data.profiles = 0;
+		args.meta.flags = 0;
+		args.meta.profiles = 0;
+		args.sys.flags = 0;
+		args.sys.profiles = 0;
+		printf("ioctl(%d, BTRFS_IOC_BALANCE_V2, {flags=",
+			btrfs_test_dir_fd);
+
+		printflags(btrfs_balance_flags, args.flags,
+			   "BTRFS_BALANCE_???");
+		printf(", data=");
+		btrfs_print_balance_args(&args.data);
+		printf(", meta=");
+		btrfs_print_balance_args(&args.meta);
+		printf(", sys=");
+		btrfs_print_balance_args(&args.sys);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_BALANCE_V2,  &args);
+		printf("} => {flags=");
+		printflags(btrfs_balance_flags, args.flags,
+			   "BTRFS_BALANCE_???");
+		printf(", state=");
+		printflags(btrfs_balance_state, args.state,
+			   "BTRFS_BALANCE_STATE_???");
+		printf(", data=");
+		btrfs_print_balance_args(&args.data);
+		printf(", meta=");
+		btrfs_print_balance_args(&args.meta);
+		printf(", sys=");
+		btrfs_print_balance_args(&args.sys);
+		printf("}) = 0\n");
+	}
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_RESIZE
+ *
+ * Requires /dev/btrfs-control, consumes argument, returns nothing:
+ * - BTRFS_IOC_SCAN_DEV
+ * - BTRFS_IOC_DEVICES_READY
+ *
+ */
+static void
+btrfs_test_device_ioctls(void)
+{
+	const char *devid = "1";
+	const char *devname = "/dev/sda1";
+	struct btrfs_ioctl_vol_args args = {
+		.fd = 2,
+	};
+
+	ioctl(-1, BTRFS_IOC_RESIZE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_RESIZE, NULL) = -1 EBADF (%m)\n");
+
+	strcpy(args.name, devid);
+	ioctl(-1, BTRFS_IOC_RESIZE, &args);
+	printf("ioctl(-1, BTRFS_IOC_RESIZE, "
+	       "{fd=%d, name=\"%s\"}) = -1 EBADF (%m)\n",
+	       (int) args.fd, args.name);
+
+	ioctl(-1, BTRFS_IOC_SCAN_DEV, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SCAN_DEV, NULL) = -1 EBADF (%m)\n");
+
+	strcpy(args.name, devname);
+	ioctl(-1, BTRFS_IOC_SCAN_DEV, &args);
+	printf("ioctl(-1, BTRFS_IOC_SCAN_DEV, "
+	       "{fd=%d, name=\"%s\"}) = -1 EBADF (%m)\n",
+	       (int) args.fd, args.name);
+
+	ioctl(-1, BTRFS_IOC_ADD_DEV, NULL);
+	printf("ioctl(-1, BTRFS_IOC_ADD_DEV, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_ADD_DEV, &args);
+	printf("ioctl(-1, BTRFS_IOC_ADD_DEV, "
+	       "{fd=%d, name=\"%s\"}) = -1 EBADF (%m)\n",
+	       (int) args.fd, args.name);
+
+	ioctl(-1, BTRFS_IOC_RM_DEV, NULL);
+	printf("ioctl(-1, BTRFS_IOC_RM_DEV, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_RM_DEV, &args);
+	printf("ioctl(-1, BTRFS_IOC_RM_DEV, "
+	       "{fd=%d, name=\"%s\"}) = -1 EBADF (%m)\n",
+	       (int) args.fd, args.name);
+
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_CLONE
+ * - BTRFS_IOC_CLONE_RANGE
+ */
+static void
+btrfs_test_clone_ioctls(void)
+{
+	int clone_fd = 4;
+	struct btrfs_ioctl_clone_range_args args = {
+		.src_fd = clone_fd,
+		.src_offset = 4096,
+		.src_length = 16384,
+		.dest_offset = 128 * 1024,
+	};
+
+	ioctl(-1, BTRFS_IOC_CLONE, clone_fd);
+	printf("ioctl(-1, BTRFS_IOC_CLONE or FICLONE, %x) = -1 EBADF (%m)\n",
+		clone_fd);
+
+	ioctl(-1, BTRFS_IOC_CLONE_RANGE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_CLONE_RANGE or FICLONERANGE, "
+	       "NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_CLONE_RANGE, &args);
+	printf("ioctl(-1, BTRFS_IOC_CLONE_RANGE or FICLONERANGE, "
+	       "{src_fd=%d, src_offset=%" PRI__u64 ", src_length=%" PRI__u64
+	       ", dest_offset=%" PRI__u64 "}) = -1 EBADF (%m)\n",
+		(int) args.src_fd, args.src_offset, args.src_length,
+		args.dest_offset);
+}
+
+#define BTRFS_COMPRESS_TYPES 2
+#define BTRFS_INVALID_COMPRESS (BTRFS_COMPRESS_TYPES + 1)
+
+static void
+btrfs_print_defrag_range_args(struct btrfs_ioctl_defrag_range_args *args)
+{
+	printf("{start=%" PRIu64", len=%" PRIu64 "%s, flags=",
+		(uint64_t) args->start, (uint64_t) args->len,
+		maybe_print_uint64max(args->len));
+
+	printflags(btrfs_defrag_flags, args->flags, "BTRFS_DEFRAG_RANGE_???");
+	printf(", extent_thresh=%u, compress_type=", args->extent_thresh);
+	printxval(btrfs_compress_types, args->compress_type,
+		  "BTRFS_COMPRESS_???");
+	printf("}");
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_DEFRAG
+ * - BTRFS_DEFRAG_RANGE
+ */
+static void
+btrfs_test_defrag_ioctls(void)
+{
+	struct btrfs_ioctl_vol_args vol_args = {};
+	struct btrfs_ioctl_defrag_range_args args = {
+		.start = 0,
+		.len = -1ULL,
+		.flags = max_flags_plus_one(1),
+		.extent_thresh = 128 * 1024,
+		.compress_type = 2, /* BTRFS_COMPRESS_LZO */
+	};
+
+	/*
+	 * These are documented as using vol_args but don't
+	 * actually consume it.
+	 */
+	ioctl(-1, BTRFS_IOC_DEFRAG, NULL);
+	printf("ioctl(-1, BTRFS_IOC_DEFRAG) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_DEFRAG, &vol_args);
+	printf("ioctl(-1, BTRFS_IOC_DEFRAG) = -1 EBADF (%m)\n");
+
+	/* struct btrfs_ioctl_defrag_range_args */
+	ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, ");
+	btrfs_print_defrag_range_args(&args);
+	ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, &args);
+	printf(") = -1 EBADF (%m)\n");
+
+	args.compress_type = BTRFS_INVALID_COMPRESS;
+	printf("ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, ");
+	btrfs_print_defrag_range_args(&args);
+	ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, &args);
+	printf(") = -1 EBADF (%m)\n");
+
+	args.len--;
+	printf("ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, ");
+	btrfs_print_defrag_range_args(&args);
+	ioctl(-1, BTRFS_IOC_DEFRAG_RANGE, &args);
+	printf(") = -1 EBADF (%m)\n");
+}
+
+static const char *
+xlookup(const struct xlat *xlat, const uint64_t val)
+{
+	for (; xlat->str != NULL; xlat++)
+		if (xlat->val == val)
+			return xlat->str;
+	return NULL;
+}
+
+static void
+btrfs_print_objectid(uint64_t objectid)
+{
+	const char *str = xlookup(btrfs_tree_objectids, objectid);
+	printf("%" PRIu64, objectid);
+	if (str)
+		printf(" /* %s */", str);
+}
+
+static void
+btrfs_print_key_type(uint32_t type)
+{
+	const char *str = xlookup(btrfs_key_types, type);
+	printf("%u", type);
+	if (str)
+		printf(" /* %s */", str);
+}
+
+static void
+btrfs_print_search_key(struct btrfs_ioctl_search_key *key)
+{
+	printf("key={tree_id=");
+	btrfs_print_objectid(key->tree_id);
+	if (verbose || key->min_objectid != 256) {
+		printf(", min_objectid=");
+		btrfs_print_objectid(key->min_objectid);
+	}
+	if (verbose || key->max_objectid != -256ULL) {
+		printf(", max_objectid=");
+		btrfs_print_objectid(key->max_objectid);
+	}
+	if (key->min_offset)
+		printf(", min_offset=%" PRI__u64 "%s",
+		       key->min_offset, maybe_print_uint64max(key->min_offset));
+	if (key->max_offset)
+		printf(", max_offset=%" PRI__u64 "%s",
+		       key->max_offset, maybe_print_uint64max(key->max_offset));
+	if (key->min_transid)
+		printf(", min_transid=%" PRI__u64"%s", key->min_transid,
+		       maybe_print_uint64max(key->min_transid));
+	if (key->max_transid)
+		printf(", max_transid=%" PRI__u64"%s", key->max_transid,
+		       maybe_print_uint64max(key->max_transid));
+	printf(", min_type=");
+	btrfs_print_key_type(key->min_type);
+	printf(", max_type=");
+	btrfs_print_key_type(key->max_type);
+	printf(", nr_items=%u}", key->nr_items);
+}
+
+static void
+btrfs_print_tree_search_buf(struct btrfs_ioctl_search_key *key,
+			    void *buf, uint64_t buf_size)
+{
+	if (verbose) {
+		uint64_t i;
+		uint64_t off = 0;
+		printf("[");
+		for (i = 0; i < key->nr_items; i++) {
+			struct btrfs_ioctl_search_header *sh;
+			sh = (typeof(sh))(buf + off);
+			if (i)
+				printf(", ");
+			printf("{transid=%" PRI__u64 ", objectid=",
+				sh->transid);
+			btrfs_print_objectid(sh->objectid);
+			printf(", offset=%" PRI__u64 ", type=", sh->offset);
+			btrfs_print_key_type(sh->type);
+			printf(", len=%u}", sh->len);
+			off += sizeof(*sh) + sh->len;
+		}
+		printf("]");
+	} else
+		printf("...");
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_TREE_SEARCH
+ * - BTRFS_IOC_TREE_SEARCH_V2
+ */
+static void
+btrfs_test_search_ioctls(void)
+{
+	struct btrfs_ioctl_search_key key_reference = {
+		.tree_id = 5,
+		.min_objectid = 256,
+		.max_objectid = -1ULL,
+		.min_offset = 0,
+		.max_offset = -1ULL,
+		.min_transid = 0,
+		.max_transid = -1ULL,
+		.min_type = 0,
+		.max_type = -1U,
+		.nr_items = 10,
+	};
+	struct btrfs_ioctl_search_args search_args;
+	struct btrfs_ioctl_search_args_v2 search_args_v2 = {
+		.buf_size = 4096,
+	};
+
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH, NULL);
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, NULL);
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, NULL) = -1 EBADF (%m)\n");
+
+	search_args.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH, {");
+	btrfs_print_search_key(&search_args.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH, &search_args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	search_args_v2.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, {");
+	btrfs_print_search_key(&search_args_v2.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, &search_args_v2);
+	printf(", buf_size=%" PRIu64 "}) = -1 EBADF (%m)\n",
+	       (uint64_t)search_args_v2.buf_size);
+
+	key_reference.min_objectid = 6;
+	key_reference.max_objectid = 7;
+	search_args.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH, {");
+	btrfs_print_search_key(&search_args.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH, &search_args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	search_args_v2.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, {");
+	btrfs_print_search_key(&search_args_v2.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, &search_args_v2);
+	printf(", buf_size=%" PRIu64 "}) = -1 EBADF (%m)\n",
+	       (uint64_t)search_args_v2.buf_size);
+
+	key_reference.min_offset++;
+	key_reference.max_offset--;
+	search_args.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH, {");
+	btrfs_print_search_key(&search_args.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH, &search_args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	search_args_v2.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, {");
+	btrfs_print_search_key(&search_args_v2.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, &search_args_v2);
+	printf(", buf_size=%" PRIu64 "}) = -1 EBADF (%m)\n",
+	       (uint64_t)search_args_v2.buf_size);
+
+	key_reference.min_transid++;
+	key_reference.max_transid--;
+	search_args.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH, {");
+	btrfs_print_search_key(&search_args.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH, &search_args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	search_args_v2.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, {");
+	btrfs_print_search_key(&search_args_v2.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, &search_args_v2);
+	printf(", buf_size=%" PRIu64 "}) = -1 EBADF (%m)\n",
+	       (uint64_t)search_args_v2.buf_size);
+
+	key_reference.min_type = 1;
+	key_reference.max_type = 12;
+	search_args.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH, {");
+	btrfs_print_search_key(&search_args.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH, &search_args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	search_args_v2.key = key_reference;
+	printf("ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, {");
+	btrfs_print_search_key(&search_args_v2.key);
+	ioctl(-1, BTRFS_IOC_TREE_SEARCH_V2, &search_args_v2);
+	printf(", buf_size=%" PRIu64 "}) = -1 EBADF (%m)\n",
+	       (uint64_t)search_args_v2.buf_size);
+
+	if (btrfs_test_root) {
+		struct btrfs_ioctl_search_args_v2 *args;
+		int bufsize = 4096;
+
+		key_reference.tree_id = 5;
+		key_reference.min_type = 1;
+		key_reference.max_type = 1;
+		key_reference.min_objectid = 256;
+		key_reference.max_objectid = 357;
+		key_reference.min_offset = 0;
+		key_reference.max_offset = -1ULL;
+
+		search_args.key = key_reference;
+		printf("ioctl(%d, BTRFS_IOC_TREE_SEARCH, {",
+			btrfs_test_dir_fd);
+		btrfs_print_search_key(&search_args.key);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_TREE_SEARCH, &search_args);
+		printf("} => {key={nr_items=%u}, buf=",
+			search_args.key.nr_items);
+		btrfs_print_tree_search_buf(&search_args.key, search_args.buf,
+					    sizeof(search_args.buf));
+		printf("}) = 0\n");
+
+		args = malloc(sizeof(*args) + bufsize);
+		if (!args)
+			perror_msg_and_fail("malloc failed");
+
+		args->key = key_reference;
+		args->buf_size = bufsize;
+		printf("ioctl(%d, BTRFS_IOC_TREE_SEARCH_V2, {",
+			btrfs_test_dir_fd);
+		btrfs_print_search_key(&key_reference);
+		printf(", buf_size=%" PRIu64 "}", (uint64_t) args->buf_size);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_TREE_SEARCH_V2, args);
+		printf(" => {key={nr_items=%u}, buf_size=%" PRIu64 ", buf=",
+			args->key.nr_items, (uint64_t)args->buf_size);
+		btrfs_print_tree_search_buf(&args->key, args->buf,
+					    args->buf_size);
+		printf("}) = 0\n");
+
+		args->key = key_reference;
+		args->buf_size = sizeof(struct btrfs_ioctl_search_header);
+		printf("ioctl(%d, BTRFS_IOC_TREE_SEARCH_V2, {",
+			btrfs_test_dir_fd);
+		btrfs_print_search_key(&args->key);
+		printf(", buf_size=%" PRIu64 "}", (uint64_t)args->buf_size);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_TREE_SEARCH_V2, args);
+		printf(" => {buf_size=%" PRIu64 "}) = -1 EOVERFLOW (%m)\n",
+			(uint64_t)args->buf_size);
+		free(args);
+	}
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_INO_LOOKUP
+ */
+static void
+btrfs_test_ino_lookup_ioctl(void)
+{
+	struct btrfs_ioctl_ino_lookup_args args = {
+		.treeid = 5,
+		.objectid = 256,
+	};
+
+	ioctl(-1, BTRFS_IOC_INO_LOOKUP, NULL);
+	printf("ioctl(-1, BTRFS_IOC_INO_LOOKUP, NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_INO_LOOKUP, {treeid=");
+	btrfs_print_objectid(args.treeid);
+	printf(", objectid=");
+	btrfs_print_objectid(args.objectid);
+	ioctl(-1, BTRFS_IOC_INO_LOOKUP, &args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	if (btrfs_test_root) {
+		printf("ioctl(%d, BTRFS_IOC_INO_LOOKUP, {treeid=",
+		       btrfs_test_dir_fd);
+		btrfs_print_objectid(args.treeid);
+		printf(", objectid=");
+		btrfs_print_objectid(args.objectid);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_INO_LOOKUP, &args);
+		printf("} => {name=\"%s\"}) = 0\n", args.name);
+	}
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_SPACE_INFO
+ */
+static void
+btrfs_test_space_info_ioctl(void)
+{
+	struct btrfs_ioctl_space_args args = {};
+
+	ioctl(-1, BTRFS_IOC_SPACE_INFO, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SPACE_INFO, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SPACE_INFO, &args);
+	printf("ioctl(-1, BTRFS_IOC_SPACE_INFO, "
+	       "{space_slots=%" PRI__u64 "}) = -1 EBADF (%m)\n",
+		args.space_slots);
+
+	if (btrfs_test_root) {
+		struct btrfs_ioctl_space_args args_passed;
+		struct btrfs_ioctl_space_args *argsp;
+		args_passed = args;
+		printf("ioctl(%d, BTRFS_IOC_SPACE_INFO, "
+		       "{space_slots=%" PRI__u64 "}",
+		       btrfs_test_dir_fd, args_passed.space_slots);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SPACE_INFO, &args_passed);
+		printf(" => {total_spaces=%" PRI__u64 "}) = 0\n",
+			args_passed.total_spaces);
+
+		argsp = malloc(sizeof(args) +
+			args_passed.total_spaces * sizeof(args.spaces[0]));
+		if (!argsp)
+			perror_msg_and_fail("malloc failed");
+
+		*argsp = args;
+		argsp->space_slots = args_passed.total_spaces;
+		printf("ioctl(%d, BTRFS_IOC_SPACE_INFO, "
+		       "{space_slots=%" PRI__u64 "}",
+		       btrfs_test_dir_fd, argsp->space_slots);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SPACE_INFO, argsp);
+		printf(" => {total_spaces=%" PRI__u64 ", spaces=",
+			argsp->total_spaces);
+		if (verbose) {
+			unsigned int i;
+			printf("[");
+			for (i = 0; i < argsp->total_spaces; i++) {
+				struct btrfs_ioctl_space_info *info;
+				info = &argsp->spaces[i];
+				if (i)
+					printf(", ");
+				printf("{flags=");
+				printflags(btrfs_space_info_flags, info->flags,
+					   "BTRFS_SPACE_INFO_???");
+				printf(", total_bytes=%" PRI__u64
+				       ", used_bytes=%" PRI__u64 "}",
+				       info->total_bytes, info->used_bytes);
+			}
+
+			printf("]");
+		} else
+			printf("...");
+		printf("}) = 0\n");
+		free(argsp);
+	}
+}
+
+/*
+ * Consumes no arguments, returns nothing:
+ * - BTRFS_IOC_SCRUB_CANCEL
+ * Consumes argument, returns argument:
+ - * BTRFS_IOC_SCRUB
+ - * BTRFS_IOC_SCRUB_PROGRESS
+ */
+static void
+btrfs_test_scrub_ioctls(void)
+{
+	struct btrfs_ioctl_scrub_args args = {
+		.devid = 1,
+		.start = 0,
+		.end = -1ULL,
+		.flags = max_flags_plus_one(0),
+	};
+
+	ioctl(-1, BTRFS_IOC_SCRUB, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SCRUB, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SCRUB_CANCEL, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SCRUB_CANCEL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SCRUB, {devid=%" PRI__u64 ", start=%"
+		PRI__u64 "%s, end=%" PRI__u64"%s, flags=",
+		args.devid, args.start, maybe_print_uint64max(args.start),
+		args.end, maybe_print_uint64max(args.end));
+	printflags(btrfs_scrub_flags, args.flags, "BTRFS_SCRUB_???");
+	ioctl(-1, BTRFS_IOC_SCRUB, &args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SCRUB_PROGRESS, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SCRUB_PROGRESS, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SCRUB_PROGRESS, &args);
+	printf("ioctl(-1, BTRFS_IOC_SCRUB_PROGRESS, "
+	       "{devid=%" PRI__u64 "}) = -1 EBADF (%m)\n", args.devid);
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_DEV_INFO
+ */
+static void
+btrfs_test_dev_info_ioctl(void)
+{
+	struct btrfs_ioctl_dev_info_args args = {
+		.devid = 1,
+	};
+	memcpy(&args.uuid, uuid_reference, BTRFS_UUID_SIZE);
+
+	ioctl(-1, BTRFS_IOC_DEV_INFO, NULL);
+	printf("ioctl(-1, BTRFS_IOC_DEV_INFO, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_DEV_INFO, &args);
+	printf("ioctl(-1, BTRFS_IOC_DEV_INFO, "
+	       "{devid=%" PRI__u64", uuid=%s}) = -1 EBADF (%m)\n",
+		args.devid, uuid_reference_string);
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_INO_PATHS
+ * - BTRFS_IOC_LOGICAL_INO
+ */
+static void
+btrfs_test_ino_path_ioctls(void)
+{
+	char buf[16384];
+	struct btrfs_ioctl_ino_path_args args = {
+		.inum = 256,
+		.size = sizeof(buf),
+		.fspath = (unsigned long)buf,
+	};
+
+	ioctl(-1, BTRFS_IOC_INO_PATHS, NULL);
+	printf("ioctl(-1, BTRFS_IOC_INO_PATHS, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_LOGICAL_INO, NULL);
+	printf("ioctl(-1, BTRFS_IOC_LOGICAL_INO, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_INO_PATHS, &args);
+	printf("ioctl(-1, BTRFS_IOC_INO_PATHS, "
+	       "{inum=%" PRI__u64", size=%" PRI__u64
+	       ", fspath=0x%" PRI__x64 "}) = -1 EBADF (%m)\n",
+	       args.inum, args.size, args.fspath);
+
+	ioctl(-1, BTRFS_IOC_LOGICAL_INO, &args);
+	printf("ioctl(-1, BTRFS_IOC_LOGICAL_INO, {logical=%" PRI__u64
+	       ", size=%" PRI__u64", inodes=0x%" PRI__x64
+	       "}) = -1 EBADF (%m)\n", args.inum, args.size, args.fspath);
+
+#ifdef HAVE_LINUX_FIEMAP_H
+	if (btrfs_test_root) {
+		int size;
+		struct stat si;
+		int ret;
+		struct btrfs_data_container *data = (void *)buf;
+		struct fiemap *fiemap;
+		int fd;
+
+		ret = fstat(btrfs_test_dir_fd, &si);
+		if (ret)
+			perror_msg_and_fail("fstat failed");
+
+		args.inum = si.st_ino;
+		printf("ioctl(%d, BTRFS_IOC_INO_PATHS, "
+		       "{inum=%" PRI__u64", size=%" PRI__u64
+		       ", fspath=0x%" PRI__x64"}",
+		       btrfs_test_dir_fd, args.inum, args.size,
+		       args.fspath);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_INO_PATHS, &args);
+		printf(" => {fspath={bytes_left=%u, bytes_missing=%u, elem_cnt=%u, elem_missed=%u, val=",
+			data->bytes_left, data->bytes_missing, data->elem_cnt,
+			data->elem_missed);
+		if (verbose) {
+			printf("[\"strace-test\"]");
+		} else
+			printf("...");
+		printf("}}) = 0\n");
+
+		fd = openat(btrfs_test_dir_fd, "file1", O_RDWR|O_CREAT, 0600);
+		if (fd < 0)
+			perror_msg_and_fail("openat(file1) failed");
+
+		ret = fstat(fd, &si);
+		if (ret)
+			perror_msg_and_fail("fstat failed");
+
+		if (write(fd, buf, sizeof(buf)) < 0)
+			perror_msg_and_fail("write: fd");
+
+		/*
+		 * Force delalloc so we can actually
+		 * search for the extent.
+		 */
+		fsync(fd);
+		ioctl(fd, BTRFS_IOC_SYNC, NULL);
+		printf("ioctl(%d, BTRFS_IOC_SYNC) = 0\n", fd);
+
+		size = sizeof(*fiemap) + 2 * sizeof(fiemap->fm_extents[0]);
+		fiemap = malloc(size);
+		if (!fiemap)
+			perror_msg_and_fail("malloc failed");
+		memset(fiemap, 0, size);
+
+		fiemap->fm_length = sizeof(buf);
+		fiemap->fm_extent_count = 2;
+
+		/* This is also a live test for FIEMAP */
+		printf("ioctl(%d, FS_IOC_FIEMAP, {fm_start=%" PRI__u64
+		       ", fm_length=%" PRI__u64", fm_flags=",
+		       fd, fiemap->fm_start, fiemap->fm_length);
+		printflags(fiemap_flags, fiemap->fm_flags, "FIEMAP_FLAG_???");
+		printf(", fm_extent_count=%u}", fiemap->fm_extent_count);
+		ioctl(fd, FS_IOC_FIEMAP, fiemap);
+		printf(" => {fm_flags=");
+		printflags(fiemap_flags, fiemap->fm_flags, "FIEMAP_FLAG_???");
+		printf(", fm_mapped_extents=%u, fm_extents=",
+			fiemap->fm_mapped_extents);
+		if (verbose) {
+			printf("[");
+			unsigned int i;
+			for (i = 0; i < fiemap->fm_mapped_extents; i++) {
+				struct fiemap_extent *fe;
+				fe = &fiemap->fm_extents[i];
+				if (i)
+					printf(", ");
+				printf("{fe_logical=%" PRI__u64
+				       ", fe_physical=%" PRI__u64
+				       ", fe_length=%" PRI__u64
+				       ", ",
+				       fe->fe_logical, fe->fe_physical,
+				       fe->fe_length);
+				printflags(fiemap_extent_flags, fe->fe_flags,
+					   "FIEMAP_EXTENT_???");
+				printf("}");
+			}
+			printf("]");
+		} else
+			printf("...");
+		printf("}) = 0\n");
+
+		args.inum = fiemap->fm_extents[0].fe_physical;
+		printf("ioctl(%d, BTRFS_IOC_LOGICAL_INO, {logical=%" PRI__u64
+		       ", size=%" PRI__u64", inodes=0x%" PRI__x64"}",
+		       fd, args.inum, args.size, args.fspath);
+		ioctl(fd, BTRFS_IOC_LOGICAL_INO, &args);
+		printf(" => {inodes={bytes_left=%u, bytes_missing=%u, elem_cnt=%u, elem_missed=%u, val=",
+			data->bytes_left, data->bytes_missing, data->elem_cnt,
+			data->elem_missed);
+		if (verbose) {
+			printf("[{inum=%llu, offset=0, root=5}]",
+			       (unsigned long long) si.st_ino);
+		} else
+			printf("...");
+		printf("}}) = 0\n");
+		close(fd);
+		free(fiemap);
+	}
+#endif /* HAVE_LINUX_FIEMAP_H */
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_SET_RECEIVED_SUBVOL
+ */
+static void
+btrfs_test_set_received_subvol_ioctl(void)
+{
+	struct btrfs_ioctl_received_subvol_args args = {
+		.stransid = 0x12345,
+		.stime = {
+			.sec = 1463193386,
+			.nsec = 12345,
+		},
+	};
+	memcpy(&args.uuid, uuid_reference, BTRFS_UUID_SIZE);
+
+	ioctl(-1, BTRFS_IOC_SET_RECEIVED_SUBVOL, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SET_RECEIVED_SUBVOL, "
+	       "NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SET_RECEIVED_SUBVOL, &args);
+	printf("ioctl(-1, BTRFS_IOC_SET_RECEIVED_SUBVOL, "
+	       "{uuid=%s, stransid=%" PRI__u64", stime=%" PRI__u64
+	       ".%u, flags=0}) = -1 EBADF (%m)\n",
+	       uuid_reference_string, args.stransid, args.stime.sec,
+	       args.stime.nsec);
+}
+
+/*
+ * Consumes argument, returns nothing (output is via send_fd)
+ * - BTRFS_IOC_SEND
+ */
+static void
+btrfs_test_send_ioctl(void)
+{
+	uint64_t u64_array[2] = { 256, 257 };
+	struct btrfs_ioctl_send_args args = {
+		.send_fd = 4,
+		.parent_root = 257,
+		.flags = max_flags_plus_one(2),
+	};
+
+	ioctl(-1, BTRFS_IOC_SEND, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SEND, NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SEND, "
+	       "{send_fd=%d, clone_sources_count=%" PRI__u64
+	       ", clone_sources=",
+	       (int) args.send_fd, args.clone_sources_count);
+	if (verbose)
+		printf("NULL");
+	else
+		printf("...");
+	printf(", parent_root=");
+	btrfs_print_objectid(args.parent_root);
+	printf(", flags=");
+	printflags(btrfs_send_flags, args.flags, "BTRFS_SEND_FLAGS_???");
+	ioctl(-1, BTRFS_IOC_SEND, &args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	args.clone_sources_count = 2;
+	args.clone_sources = (__u64 *) (void *) u64_array;
+
+	printf("ioctl(-1, BTRFS_IOC_SEND, "
+	       "{send_fd=%d, clone_sources_count=%" PRI__u64
+	       ", clone_sources=",
+	       (int) args.send_fd, args.clone_sources_count);
+	if (verbose) {
+		printf("[");
+		btrfs_print_objectid(u64_array[0]);
+		printf(", ");
+		btrfs_print_objectid(u64_array[1]);
+		printf("]");
+	} else
+		printf("...");
+	printf(", parent_root=");
+	btrfs_print_objectid(args.parent_root);
+	printf(", flags=");
+	printflags(btrfs_send_flags, args.flags, "BTRFS_SEND_FLAGS_???");
+	ioctl(-1, BTRFS_IOC_SEND, &args);
+	printf("}) = -1 EBADF (%m)\n");
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_QUOTA_CTL
+ */
+static void
+btrfs_test_quota_ctl_ioctl(void)
+{
+	struct btrfs_ioctl_quota_ctl_args args = {
+		.cmd = 1,
+	};
+
+	ioctl(-1, BTRFS_IOC_QUOTA_CTL, NULL);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_CTL, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_QUOTA_CTL, &args);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_CTL, "
+	       "BTRFS_QUOTA_CTL_ENABLE}) = -1 EBADF (%m)\n");
+
+	args.cmd = 2;
+	ioctl(-1, BTRFS_IOC_QUOTA_CTL, &args);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_CTL, "
+	       "BTRFS_QUOTA_CTL_DISABLE}) = -1 EBADF (%m)\n");
+
+	args.cmd = 3;
+	ioctl(-1, BTRFS_IOC_QUOTA_CTL, &args);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_CTL, "
+	       "BTRFS_QUOTA_CTL_RESCAN__NOTUSED}) = -1 EBADF (%m)\n");
+
+	args.cmd = 4;
+	ioctl(-1, BTRFS_IOC_QUOTA_CTL, &args);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_CTL, "
+	       "0x4 /* BTRFS_QUOTA_CTL_??? */}) = -1 EBADF (%m)\n");
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_QGROUP_ASSIGN
+ */
+static void
+btrfs_test_qgroup_assign_ioctl(void)
+{
+	struct btrfs_ioctl_qgroup_assign_args args = {
+		.assign = 1,
+		.src = 257,
+		.dst = 258,
+	};
+
+	ioctl(-1, BTRFS_IOC_QGROUP_ASSIGN, NULL);
+	printf("ioctl(-1, BTRFS_IOC_QGROUP_ASSIGN, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_QGROUP_ASSIGN, &args);
+	printf("ioctl(-1, BTRFS_IOC_QGROUP_ASSIGN, "
+	       "{assign=%" PRI__u64", src=%" PRI__u64", dst=%" PRI__u64
+	       "}) = -1 EBADF (%m)\n", args.assign, args.src, args.dst);
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_QGROUP_CREATE
+  */
+static void
+btrfs_test_qgroup_create_ioctl(void)
+{
+	struct btrfs_ioctl_qgroup_create_args args = {
+		.create = 1,
+		.qgroupid = 257,
+	};
+
+	ioctl(-1, BTRFS_IOC_QGROUP_CREATE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_QGROUP_CREATE, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_QGROUP_CREATE, &args);
+	printf("ioctl(-1, BTRFS_IOC_QGROUP_CREATE, "
+	       "{create=%" PRI__u64", qgroupid=%" PRI__u64
+	       "}) = -1 EBADF (%m)\n", args.create, args.qgroupid);
+}
+
+/*
+ * Consumes nothing, returns nothing:
+ * - BTRFS_IOC_QUOTA_RESCAN_WAIT
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_QUOTA_RESCAN
+ */
+static void
+btrfs_test_quota_rescan_ioctl(void)
+{
+	struct btrfs_ioctl_quota_rescan_args args = {
+		.progress = 1,
+	};
+
+	ioctl(-1, BTRFS_IOC_QUOTA_RESCAN, NULL);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_RESCAN, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_QUOTA_RESCAN, &args);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_RESCAN, "
+	       "{flags=0}) = -1 EBADF (%m)\n");
+	ioctl(-1, BTRFS_IOC_QUOTA_RESCAN_WAIT, NULL);
+	printf("ioctl(-1, BTRFS_IOC_QUOTA_RESCAN_WAIT) = -1 EBADF (%m)\n");
+
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_SET_FSLABEL
+ *
+ * Consumes no argument, returns argument:
+ * - BTRFS_IOC_GET_FS_LABEL
+ */
+static void
+btrfs_test_label_ioctls(void)
+{
+	char label[BTRFS_LABEL_SIZE] = "btrfs-label";
+
+	ioctl(-1, BTRFS_IOC_SET_FSLABEL, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SET_FSLABEL, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_SET_FSLABEL, label);
+	printf("ioctl(-1, BTRFS_IOC_SET_FSLABEL, \"%s\") = -1 EBADF (%m)\n",
+		label);
+
+	if (write_ok) {
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_SET_FSLABEL, label);
+		printf("ioctl(%d, BTRFS_IOC_SET_FSLABEL, \"%s\") = 0\n",
+			btrfs_test_dir_fd, label);
+
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_FSLABEL, label);
+		printf("ioctl(%d, BTRFS_IOC_GET_FSLABEL, \"%s\") = 0\n",
+			btrfs_test_dir_fd, label);
+	}
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_GET_DEV_STATS
+ */
+static void
+btrfs_test_get_dev_stats_ioctl(void)
+{
+	struct btrfs_ioctl_get_dev_stats args = {
+		.devid = 1,
+		.nr_items = 5,
+		.flags = max_flags_plus_one(0),
+	};
+
+	ioctl(-1, BTRFS_IOC_GET_DEV_STATS, NULL);
+	printf("ioctl(-1, BTRFS_IOC_GET_DEV_STATS, NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_GET_DEV_STATS, {devid=%" PRI__u64
+		", nr_items=%" PRI__u64", flags=",
+		args.devid, args.nr_items);
+	printflags(btrfs_dev_stats_flags, args.flags,
+		     "BTRFS_DEV_STATS_???");
+	ioctl(-1, BTRFS_IOC_GET_DEV_STATS, &args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	if (write_ok) {
+		unsigned int i;
+		args.flags = BTRFS_DEV_STATS_RESET;
+		printf("ioctl(%d, BTRFS_IOC_GET_DEV_STATS, {devid=%" PRI__u64
+			", nr_items=%" PRI__u64", flags=",
+			btrfs_test_dir_fd, args.devid, args.nr_items);
+		printflags(btrfs_dev_stats_flags, args.flags,
+			     "BTRFS_DEV_STATS_???");
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_DEV_STATS, &args);
+		printf("} => {nr_items=%" PRI__u64 ", flags=",
+			args.nr_items);
+		printflags(btrfs_dev_stats_flags, args.flags,
+			   "BTRFS_DEV_STATS_???");
+		printf(", [");
+		for (i = 0; i < args.nr_items; i++) {
+			const char *name = xlookup(btrfs_dev_stats_values, i);
+			if (i)
+				printf(", ");
+			if (name)
+				printf("/* %s */ ", name);
+			printf("%" PRI__u64, args.values[i]);
+		}
+		printf("]}) = 0\n");
+	}
+}
+
+/*
+ * Consumes argument, returns argument:
+ * - BTRFS_IOC_DEV_REPLACE
+ *
+ * Test environment for this is more difficult; It's better to do it by hand.
+ */
+static void
+btrfs_test_dev_replace_ioctl(void)
+{
+	struct btrfs_ioctl_dev_replace_args args = {
+		.cmd = BTRFS_IOCTL_DEV_REPLACE_CMD_START,
+		.start = {
+			.srcdevid = 1,
+		},
+	};
+	strcpy((char *)args.start.srcdev_name, "/dev/sda1");
+	strcpy((char *)args.start.tgtdev_name, "/dev/sdb1");
+
+	/* struct btrfs_ioctl_dev_replace_args */
+	ioctl(-1, BTRFS_IOC_DEV_REPLACE, NULL);
+	printf("ioctl(-1, BTRFS_IOC_DEV_REPLACE, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, BTRFS_IOC_DEV_REPLACE, &args);
+	printf("ioctl(-1, BTRFS_IOC_DEV_REPLACE, "
+	       "{cmd=BTRFS_IOCTL_DEV_REPLACE_CMD_START, start={srcdevid=%"
+	       PRI__u64", cont_reading_from_srcdev_mode=%" PRI__u64
+	       ", srcdev_name=\"%s\", tgtdev_name=\"%s\"}}) = -1 EBADF (%m)\n",
+	       args.start.srcdevid,
+	       args.start.cont_reading_from_srcdev_mode,
+	       (char *)args.start.srcdev_name,
+	       (char *)args.start.tgtdev_name);
+
+	args.cmd = 1;
+	ioctl(-1, BTRFS_IOC_DEV_REPLACE, &args);
+	printf("ioctl(-1, BTRFS_IOC_DEV_REPLACE, "
+	       "{cmd=BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS}) = -1 EBADF (%m)\n");
+}
+
+static void
+btrfs_test_extent_same_ioctl(void)
+{
+#ifdef BTRFS_IOC_FILE_EXTENT_SAME
+	struct file_dedupe_range args = {
+		.src_offset = 1024,
+		.src_length = 10240,
+	};
+	struct file_dedupe_range *argsp;
+
+	ioctl(-1, BTRFS_IOC_FILE_EXTENT_SAME, NULL);
+	printf("ioctl(-1, BTRFS_IOC_FILE_EXTENT_SAME or FIDEDUPERANGE, "
+	       "NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_FILE_EXTENT_SAME or FIDEDUPERANGE, "
+	       "{src_offset=%" PRIu64
+	       ", src_length=%" PRIu64
+	       ", dest_count=%hu, info=[]",
+		(uint64_t)args.src_offset,
+		(uint64_t)args.src_length, args.dest_count);
+	ioctl(-1, BTRFS_IOC_FILE_EXTENT_SAME, &args);
+	printf("}) = -1 EBADF (%m)\n");
+
+	argsp = malloc(sizeof(*argsp) + sizeof(argsp->info[0]) * 3);
+	if (!argsp)
+		perror_msg_and_fail("malloc failed");
+	memset(argsp, 0, sizeof(*argsp) + sizeof(argsp->info[0]) * 3);
+
+	*argsp = args;
+	argsp->dest_count = 3;
+	argsp->info[0].dest_fd = 2;
+	argsp->info[0].dest_offset = 0;
+	argsp->info[1].dest_fd = 2;
+	argsp->info[1].dest_offset = 10240;
+	argsp->info[2].dest_fd = 2;
+	argsp->info[2].dest_offset = 20480;
+
+	printf("ioctl(-1, BTRFS_IOC_FILE_EXTENT_SAME or FIDEDUPERANGE, "
+	       "{src_offset=%" PRIu64
+	       ", src_length=%" PRIu64
+	       ", dest_count=%hu, info=",
+		(int64_t)argsp->src_offset,
+		(uint64_t)argsp->src_length, argsp->dest_count);
+		printf("[{dest_fd=%" PRId64 ", dest_offset=%" PRIu64
+		       "}, {dest_fd=%" PRId64 ", dest_offset=%"PRIu64 "}",
+		       (int64_t)argsp->info[0].dest_fd,
+		       (uint64_t)argsp->info[0].dest_offset,
+		       (int64_t)argsp->info[1].dest_fd,
+		       (uint64_t)argsp->info[1].dest_offset);
+	if (verbose)
+		printf(", {dest_fd=%" PRId64 ", dest_offset=%" PRIu64 "}",
+		       (int64_t)argsp->info[2].dest_fd,
+		       (uint64_t)argsp->info[2].dest_offset);
+	else
+		printf(", ...");
+	printf("]");
+	ioctl(-1, BTRFS_IOC_FILE_EXTENT_SAME, argsp);
+	printf("}) = -1 EBADF (%m)\n");
+
+	if (write_ok) {
+		int fd1, fd2;
+		char buf[16384];
+
+		memset(buf, 0, sizeof(buf));
+
+		fd1 = openat(btrfs_test_dir_fd, "file1", O_RDWR|O_CREAT, 0600);
+		if (fd1 < 0)
+			perror_msg_and_fail("open file1 failed");
+
+		fd2 = openat(btrfs_test_dir_fd, "file2", O_RDWR|O_CREAT, 0600);
+		if (fd2 < 0)
+			perror_msg_and_fail("open file2 failed");
+
+		if (write(fd1, buf, sizeof(buf)) < 0)
+			perror_msg_and_fail("write: fd1");
+		if (write(fd1, buf, sizeof(buf)) < 0)
+			perror_msg_and_fail("write: fd1");
+		if (write(fd2, buf, sizeof(buf)) < 0)
+			perror_msg_and_fail("write: fd2");
+		if (write(fd2, buf, sizeof(buf)) < 0)
+			perror_msg_and_fail("write: fd2");
+
+		close(fd2);
+		fd2 = openat(btrfs_test_dir_fd, "file2", O_RDONLY);
+		if (fd2 < 0)
+			perror_msg_and_fail("open file2 failed");
+
+		memset(argsp, 0, sizeof(*argsp) + sizeof(argsp->info[0]) * 3);
+
+		argsp->src_offset = 0;
+		argsp->src_length = 4096;
+		argsp->dest_count = 3;
+		argsp->info[0].dest_fd = fd2;
+		argsp->info[0].dest_offset = 0;
+		argsp->info[1].dest_fd = fd2;
+		argsp->info[1].dest_offset = 10240;
+		argsp->info[2].dest_fd = fd2;
+		argsp->info[2].dest_offset = 20480;
+
+		printf("ioctl(%d, BTRFS_IOC_FILE_EXTENT_SAME or FIDEDUPERANGE, "
+		       "{src_offset=%" PRIu64 ", src_length=%" PRIu64
+		       ", dest_count=%hu, info=", fd1,
+		       (uint64_t)argsp->src_offset,
+		       (uint64_t)argsp->src_length, argsp->dest_count);
+		printf("[{dest_fd=%" PRId64 ", dest_offset=%" PRIu64
+		       "}, {dest_fd=%" PRId64 ", dest_offset=%"PRIu64 "}",
+		       (int64_t)argsp->info[0].dest_fd,
+		       (uint64_t)argsp->info[0].dest_offset,
+		       (int64_t)argsp->info[1].dest_fd,
+		       (uint64_t)argsp->info[1].dest_offset);
+		if (verbose)
+			printf(", {dest_fd=%" PRId64
+			       ", dest_offset=%" PRIu64 "}",
+			       (int64_t)argsp->info[2].dest_fd,
+			       (uint64_t)argsp->info[2].dest_offset);
+		else
+			printf(", ...");
+
+		ioctl(fd1, BTRFS_IOC_FILE_EXTENT_SAME, argsp);
+		printf("]} => {info=");
+		printf("[{bytes_deduped=%" PRIu64 ", status=%d}, "
+			"{bytes_deduped=%" PRIu64 ", status=%d}",
+		       (uint64_t)argsp->info[0].bytes_deduped,
+		       argsp->info[0].status,
+		       (uint64_t)argsp->info[1].bytes_deduped,
+		       argsp->info[1].status);
+		if (verbose)
+			printf(", {bytes_deduped=%" PRIu64 ", status=%d}",
+			       (uint64_t)argsp->info[2].bytes_deduped,
+			       argsp->info[2].status);
+		else
+			printf(", ...");
+		printf("]}) = 0\n");
+		close(fd1);
+		close(fd2);
+		unlinkat(btrfs_test_dir_fd, "file1", 0);
+		unlinkat(btrfs_test_dir_fd, "file2", 0);
+		close(fd1);
+		close(fd2);
+	}
+	free(argsp);
+#endif /* BTRFS_IOC_FILE_EXTENT_SAME */
+}
+
+static void
+btrfs_print_features(struct btrfs_ioctl_feature_flags *flags)
+{
+	printf("{compat_flags=");
+	printflags(btrfs_features_compat, flags->compat_flags,
+		   "BTRFS_FEATURE_COMPAT_???");
+
+	printf(", compat_ro_flags=");
+	printflags(btrfs_features_compat_ro, flags->compat_ro_flags,
+		   "BTRFS_FEATURE_COMPAT_RO_???");
+
+	printf(", incompat_flags=");
+	printflags(btrfs_features_incompat, flags->incompat_flags,
+		   "BTRFS_FEATURE_INCOMPAT_???");
+	printf("}");
+}
+
+/*
+ * Consumes argument, returns nothing:
+ * - BTRFS_IOC_SET_FEATURES
+ *
+ * Consumes nothing, returns argument:
+ * - BTRFS_IOC_GET_FEATURES
+ * - BTRFS_IOC_GET_SUPPORTED_FEATURES
+ */
+static void
+btrfs_test_features_ioctls(void)
+{
+	struct btrfs_ioctl_feature_flags args[2] = {
+		{
+			.compat_flags = max_flags_plus_one(-1),
+			.incompat_flags = max_flags_plus_one(9),
+			.compat_ro_flags = max_flags_plus_one(0),
+		}, {
+			.compat_flags = max_flags_plus_one(-1),
+			.incompat_flags = max_flags_plus_one(9),
+			.compat_ro_flags = max_flags_plus_one(0),
+		},
+	};
+	struct btrfs_ioctl_feature_flags supported_features[3];
+
+	ioctl(-1, BTRFS_IOC_SET_FEATURES, NULL);
+	printf("ioctl(-1, BTRFS_IOC_SET_FEATURES, NULL) = -1 EBADF (%m)\n");
+
+	printf("ioctl(-1, BTRFS_IOC_SET_FEATURES, [");
+	btrfs_print_features(&args[0]);
+	printf(", ");
+	btrfs_print_features(&args[1]);
+	ioctl(-1, BTRFS_IOC_SET_FEATURES, &args);
+	printf("]) = -1 EBADF (%m)\n");
+
+	if (btrfs_test_root) {
+		printf("ioctl(%d, BTRFS_IOC_GET_FEATURES, ",
+		       btrfs_test_dir_fd);
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_FEATURES,
+		      &supported_features);
+		btrfs_print_features(&supported_features[0]);
+		printf(") = 0\n");
+
+		ioctl(btrfs_test_dir_fd, BTRFS_IOC_GET_SUPPORTED_FEATURES,
+		      &supported_features);
+		printf("ioctl(%d, BTRFS_IOC_GET_SUPPORTED_FEATURES, ",
+		       btrfs_test_dir_fd);
+		printf("[ /* supported */ ");
+		btrfs_print_features(&supported_features[0]);
+		printf(", /* safe to set */ ");
+		btrfs_print_features(&supported_features[1]);
+		printf(", /* safe to clear */ ");
+		btrfs_print_features(&supported_features[2]);
+		printf("]) = 0\n");
+	}
+}
+
+static void
+btrfs_test_read_ioctls(void)
+{
+	static const struct xlat btrfs_read_cmd[] = {
+		XLAT(BTRFS_IOC_BALANCE_PROGRESS),
+		XLAT(BTRFS_IOC_FS_INFO),
+		XLAT(BTRFS_IOC_GET_FEATURES),
+		XLAT(BTRFS_IOC_GET_FSLABEL),
+		XLAT(BTRFS_IOC_GET_SUPPORTED_FEATURES),
+		XLAT(BTRFS_IOC_QGROUP_LIMIT),
+		XLAT(BTRFS_IOC_QUOTA_RESCAN_STATUS),
+		XLAT(BTRFS_IOC_START_SYNC),
+		XLAT(BTRFS_IOC_SUBVOL_GETFLAGS),
+	};
+
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(btrfs_read_cmd); ++i) {
+		ioctl(-1, (unsigned long) btrfs_read_cmd[i].val, 0);
+		printf("ioctl(-1, %s, NULL) = -1 EBADF (%m)\n", btrfs_read_cmd[i].str);
+	}
+}
+
+int
+main(int argc, char *argv[])
+{
+
+	int opt;
+	int ret;
+	const char *path;
+
+	while ((opt = getopt(argc, argv, "wv")) != -1) {
+		switch (opt) {
+		case 'v':
+			/*
+			 * These tests are incomplete, especially when
+			 * printing arrays of objects are involved.
+			 */
+			verbose = true;
+			break;
+		case 'w':
+			write_ok = true;
+			break;
+		default:
+			error_msg_and_fail("usage: btrfs [-v] [-w] [path]");
+		}
+	}
+
+	/*
+	 * This will enable optional tests that require a valid file descriptor
+	 */
+	if (optind < argc) {
+		int rootfd;
+		struct statfs sfi;
+		path = argv[optind];
+
+		ret = statfs(path, &sfi);
+		if (ret)
+			perror_msg_and_fail("statfs(%s) failed", path);
+
+		if ((unsigned) sfi.f_type != BTRFS_SUPER_MAGIC)
+			error_msg_and_fail("%s is not a btrfs file system",
+					   path);
+
+		btrfs_test_root = path;
+		rootfd = open(path, O_RDONLY|O_DIRECTORY);
+		if (rootfd < 0)
+			perror_msg_and_fail("open(%s) failed", path);
+
+		ret = mkdirat(rootfd, "strace-test", 0755);
+		if (ret < 0 && errno != EEXIST)
+			perror_msg_and_fail("mkdirat(strace-test) failed");
+
+		btrfs_test_dir_fd = openat(rootfd, "strace-test",
+					   O_RDONLY|O_DIRECTORY);
+		if (btrfs_test_dir_fd < 0)
+			perror_msg_and_fail("openat(strace-test) failed");
+		close(rootfd);
+	} else
+		write_ok = false;
+
+	if (btrfs_test_root) {
+		fprintf(stderr, "Testing live ioctls on %s (%s)\n",
+			btrfs_test_root, write_ok ? "read/write" : "read only");
+	}
+
+	btrfs_test_read_ioctls();
+	btrfs_test_trans_ioctls();
+	btrfs_test_sync_ioctls();
+	btrfs_test_subvol_ioctls();
+	btrfs_test_balance_ioctls();
+	btrfs_test_device_ioctls();
+	btrfs_test_clone_ioctls();
+	btrfs_test_defrag_ioctls();
+	btrfs_test_search_ioctls();
+	btrfs_test_ino_lookup_ioctl();
+	btrfs_test_space_info_ioctl();
+	btrfs_test_scrub_ioctls();
+	btrfs_test_dev_info_ioctl();
+	btrfs_test_ino_path_ioctls();
+	btrfs_test_set_received_subvol_ioctl();
+	btrfs_test_send_ioctl();
+	btrfs_test_quota_ctl_ioctl();
+	btrfs_test_qgroup_assign_ioctl();
+	btrfs_test_qgroup_create_ioctl();
+	btrfs_test_quota_rescan_ioctl();
+	btrfs_test_label_ioctls();
+	btrfs_test_get_dev_stats_ioctl();
+	btrfs_test_dev_replace_ioctl();
+	btrfs_test_extent_same_ioctl();
+	btrfs_test_features_ioctls();
+
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_LINUX_BTRFS_H")
+
+#endif
diff --git a/strace/tests/btrfs.test b/strace/tests/btrfs.test
new file mode 100755
index 0000000..2121b5b
--- /dev/null
+++ b/strace/tests/btrfs.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check basic btrfs ioctl decoding.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/caps.awk b/strace/tests/caps.awk
new file mode 100644
index 0000000..67003ac
--- /dev/null
+++ b/strace/tests/caps.awk
@@ -0,0 +1,47 @@
+#!/bin/gawk
+#
+# This file is part of caps strace test.
+#
+# Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+BEGIN {
+	cap = "(0|1<<CAP_[A-Z_]+(\\|1<<CAP_[A-Z_]+)*|1<<CAP_[A-Z_]+(\\|1<<CAP_[A-Z_]+){37}\\|0xffffffc0)"
+	s_efault = "-1 EFAULT (Bad address)"
+	r_efault = "-1 EFAULT \\(Bad address\\)"
+	r_addr = "0x[[:xdigit:]]+"
+	s[1] = "capget(NULL, NULL) = " s_efault
+	r[2] = "^capget\\(" r_addr ", " r_addr "\\) = " r_efault
+	r[3] = "^capget\\(\\{_LINUX_CAPABILITY_VERSION_3, 0\\}, " r_addr "\\) = " r_efault
+	r[4] = "^capget\\(\\{_LINUX_CAPABILITY_VERSION_3, 0\\}, \\{" cap ", " cap ", " cap "\\}\\) = 0$"
+	capset_data = "{1<<CAP_DAC_OVERRIDE|1<<CAP_WAKE_ALARM, 1<<CAP_DAC_READ_SEARCH|1<<CAP_BLOCK_SUSPEND, 0}"
+	s[5] = "capset({_LINUX_CAPABILITY_VERSION_3, 0}, " capset_data ") = -1 EPERM (Operation not permitted)"
+	s[6] = "+++ exited with 0 +++"
+
+	lines = 6
+	fail = 0
+}
+
+@include "match.awk"
diff --git a/strace/tests/caps.c b/strace/tests/caps.c
new file mode 100644
index 0000000..17e1077
--- /dev/null
+++ b/strace/tests/caps.c
@@ -0,0 +1,62 @@
+/*
+ * This file is part of caps strace test.
+ *
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <string.h>
+
+extern int capget(int *, int *);
+extern int capset(int *, const int *);
+
+int
+main(void)
+{
+	const int data[] = { 2, 4, 0, 8, 16, 0 };
+	const int v3 = 0x20080522;
+
+	int * const head = tail_alloc(sizeof(int) * 2);
+	head[0] = v3;
+	head[1] = 0;
+	int * const tail_data = tail_alloc(sizeof(data));
+
+	capget(NULL, NULL);
+	capget(head + 2, tail_data);
+	capget(head, tail_data + ARRAY_SIZE(data));
+
+	if (capget(head, tail_data))
+		perror_msg_and_skip("capget");
+	if (head[0] != v3)
+		error_msg_and_skip("capget: v3 expected");
+
+	memcpy(tail_data, data, sizeof(data));
+	if (capset(head, data) == 0 || errno != EPERM)
+		perror_msg_and_skip("capset");
+
+	return 0;
+}
diff --git a/strace/tests/caps.test b/strace/tests/caps.test
new file mode 100755
index 0000000..607a75b
--- /dev/null
+++ b/strace/tests/caps.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check capget/capset syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -a 19 -e trace=capget,capset $args
+match_awk
+
+exit 0
diff --git a/strace/tests/chmod.c b/strace/tests/chmod.c
new file mode 100644
index 0000000..056101c
--- /dev/null
+++ b/strace/tests/chmod.c
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 2016 Anchit Jain <anchitjain1234@gmail.com>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_chmod
+
+#include <fcntl.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <errno.h>
+
+int
+main(void)
+{
+	static const char fname[] = "chmod_test_file";
+
+	if (open(fname, O_CREAT|O_RDONLY, 0400) == -1)
+		perror_msg_and_fail("open");
+
+	int chmod_res = syscall(__NR_chmod, fname, 0600);
+
+	if (chmod_res == 0) {
+		printf("chmod(\"%s\", 0600) = 0\n", fname);
+	} else {
+		if (errno == ENOSYS) {
+			printf("chmod(\"%s\", 0600) = -1 ENOSYS (%m)\n", fname);
+		} else {
+			perror_msg_and_fail("chmod");
+		}
+	}
+
+	if (unlink(fname) == -1)
+		perror_msg_and_fail("unlink");
+
+	if (chmod_res == 0) {
+		if (syscall(__NR_chmod, fname, 0600) != -1)
+			perror_msg_and_fail("chmod");
+
+		printf("chmod(\"%s\", 0600) = -1 ENOENT (%m)\n", fname);
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_chmod")
+
+#endif
diff --git a/strace/tests/chmod.test b/strace/tests/chmod.test
new file mode 100755
index 0000000..70e561a
--- /dev/null
+++ b/strace/tests/chmod.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check chmod syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28
diff --git a/strace/tests/chown.c b/strace/tests/chown.c
new file mode 100644
index 0000000..59a4d63
--- /dev/null
+++ b/strace/tests/chown.c
@@ -0,0 +1,19 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_chown
+
+# define SYSCALL_NR __NR_chown
+# define SYSCALL_NAME "chown"
+
+# if defined __NR_chown32 && __NR_chown != __NR_chown32
+#  define UGID_TYPE_IS_SHORT
+# endif
+
+# include "xchownx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_chown")
+
+#endif
diff --git a/strace/tests/chown.test b/strace/tests/chown.test
new file mode 100755
index 0000000..eb356ce
--- /dev/null
+++ b/strace/tests/chown.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check chown syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28
diff --git a/strace/tests/chown32.c b/strace/tests/chown32.c
new file mode 100644
index 0000000..5e590a8
--- /dev/null
+++ b/strace/tests/chown32.c
@@ -0,0 +1,14 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_chown32
+
+# define SYSCALL_NR __NR_chown32
+# define SYSCALL_NAME "chown32"
+# include "xchownx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_chown32")
+
+#endif
diff --git a/strace/tests/chown32.test b/strace/tests/chown32.test
new file mode 100755
index 0000000..0fa04c2
--- /dev/null
+++ b/strace/tests/chown32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check chown32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a31
diff --git a/strace/tests/chroot.c b/strace/tests/chroot.c
new file mode 100644
index 0000000..fb9548c
--- /dev/null
+++ b/strace/tests/chroot.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_chroot
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "chroot.sample";
+
+	long rc = syscall(__NR_chroot, sample);
+	printf("chroot(\"%s\") = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_chroot")
+
+#endif
diff --git a/strace/tests/chroot.test b/strace/tests/chroot.test
new file mode 100755
index 0000000..3b384f5
--- /dev/null
+++ b/strace/tests/chroot.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check chroot syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24
diff --git a/strace/tests/clock_adjtime.c b/strace/tests/clock_adjtime.c
new file mode 100644
index 0000000..93c58b7
--- /dev/null
+++ b/strace/tests/clock_adjtime.c
@@ -0,0 +1,60 @@
+/*
+ * This file is part of clock_adjtime strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_clock_adjtime
+
+# include <stdio.h>
+# include <time.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_clock_adjtime, CLOCK_MONOTONIC, NULL);
+	printf("clock_adjtime(CLOCK_MONOTONIC, NULL) = %ld %s (%m)\n",
+	       rc, errno2name());
+
+	void *efault = tail_alloc(1);
+
+	rc = syscall(__NR_clock_adjtime, CLOCK_REALTIME, efault);
+	printf("clock_adjtime(CLOCK_REALTIME, %p) = %ld %s (%m)\n",
+	       efault, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_clock_adjtime")
+
+#endif
diff --git a/strace/tests/clock_adjtime.test b/strace/tests/clock_adjtime.test
new file mode 100755
index 0000000..df2c060
--- /dev/null
+++ b/strace/tests/clock_adjtime.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check clock_adjtime syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a37
diff --git a/strace/tests/clock_nanosleep.c b/strace/tests/clock_nanosleep.c
new file mode 100644
index 0000000..1c4c427
--- /dev/null
+++ b/strace/tests/clock_nanosleep.c
@@ -0,0 +1,122 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <signal.h>
+#include <time.h>
+#include <unistd.h>
+#include <sys/time.h>
+#include <sys/syscall.h>
+
+static void
+handler(int signo)
+{
+}
+
+int
+main(void)
+{
+	struct {
+		struct timespec ts;
+		uint32_t pad[2];
+	} req = {
+		.ts = { .tv_nsec = 0xc0de1 },
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	}, rem = {
+		.ts = { .tv_sec = 0xc0de2, .tv_nsec = 0xc0de3 },
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	};
+	const sigset_t set = {};
+	const struct sigaction act = { .sa_handler = handler };
+	const struct itimerval itv = {
+		.it_interval.tv_usec = 222222,
+		.it_value.tv_usec = 111111
+	};
+
+	if (syscall(__NR_clock_nanosleep, CLOCK_REALTIME, 0, &req.ts, NULL))
+		perror_msg_and_skip("clock_nanosleep CLOCK_REALTIME");
+	printf("clock_nanosleep(CLOCK_REALTIME, 0, {%jd, %jd}, NULL) = 0\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec);
+
+	assert(syscall(__NR_clock_nanosleep, CLOCK_REALTIME, 0,
+		       NULL, &rem.ts) == -1);
+	printf("clock_nanosleep(CLOCK_REALTIME, 0, NULL, %p)"
+	       " = -1 EFAULT (%m)\n", &rem.ts);
+
+	assert(syscall(__NR_clock_nanosleep, CLOCK_REALTIME, 0,
+		       &req.ts, &rem.ts) == 0);
+	printf("clock_nanosleep(CLOCK_REALTIME, 0, {%jd, %jd}, %p) = 0\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec, &rem.ts);
+
+	req.ts.tv_nsec = 999999999 + 1;
+	assert(syscall(__NR_clock_nanosleep, CLOCK_MONOTONIC, 0,
+		       &req.ts, &rem.ts) == -1);
+	printf("clock_nanosleep(CLOCK_MONOTONIC, 0"
+	       ", {%jd, %jd}, %p) = -1 EINVAL (%m)\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec, &rem.ts);
+
+	assert(sigaction(SIGALRM, &act, NULL) == 0);
+	assert(sigprocmask(SIG_SETMASK, &set, NULL) == 0);
+
+	if (setitimer(ITIMER_REAL, &itv, NULL))
+		perror_msg_and_skip("setitimer");
+	printf("setitimer(ITIMER_REAL, {it_interval={%jd, %jd}"
+	       ", it_value={%jd, %jd}}, NULL) = 0\n",
+	       (intmax_t) itv.it_interval.tv_sec,
+	       (intmax_t) itv.it_interval.tv_usec,
+	       (intmax_t) itv.it_value.tv_sec,
+	       (intmax_t) itv.it_value.tv_usec);
+
+	--req.ts.tv_nsec;
+	assert(syscall(__NR_clock_nanosleep, CLOCK_REALTIME, 0,
+		       &req.ts, &rem.ts) == -1);
+	printf("clock_nanosleep(CLOCK_REALTIME, 0, {%jd, %jd}, {%jd, %jd})"
+	       " = ? ERESTART_RESTARTBLOCK (Interrupted by signal)\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec,
+	       (intmax_t) rem.ts.tv_sec, (intmax_t) rem.ts.tv_nsec);
+	puts("--- SIGALRM {si_signo=SIGALRM, si_code=SI_KERNEL} ---");
+
+	assert(syscall(__NR_clock_gettime, CLOCK_REALTIME, &req.ts) == 0);
+	printf("clock_gettime(CLOCK_REALTIME, {%jd, %jd}) = 0\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec);
+
+	++req.ts.tv_sec;
+	rem.ts.tv_sec = 0xc0de4;
+	rem.ts.tv_nsec = 0xc0de5;
+	assert(syscall(__NR_clock_nanosleep, CLOCK_REALTIME, TIMER_ABSTIME,
+		       &req.ts, &rem.ts) == -1);
+	printf("clock_nanosleep(CLOCK_REALTIME, TIMER_ABSTIME, {%jd, %jd}, %p)"
+	       " = ? ERESTARTNOHAND (To be restarted if no handler)\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec, &rem.ts);
+	puts("--- SIGALRM {si_signo=SIGALRM, si_code=SI_KERNEL} ---");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/clock_nanosleep.test b/strace/tests/clock_nanosleep.test
new file mode 100755
index 0000000..ec434a6
--- /dev/null
+++ b/strace/tests/clock_nanosleep.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check clock_nanosleep, clock_gettime, and setitimer syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=clock_nanosleep,clock_gettime,setitimer
diff --git a/strace/tests/clock_xettime.c b/strace/tests/clock_xettime.c
new file mode 100644
index 0000000..633351a
--- /dev/null
+++ b/strace/tests/clock_xettime.c
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <stdint.h>
+#include <time.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+#if defined __NR_clock_getres \
+ && defined __NR_clock_gettime \
+ && defined __NR_clock_settime
+
+int
+main(void)
+{
+	struct {
+		struct timespec ts;
+		uint32_t pad[2];
+	} t = {
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	};
+
+	if (syscall(__NR_clock_getres, CLOCK_REALTIME, &t.ts))
+		perror_msg_and_skip("clock_getres CLOCK_REALTIME");
+	printf("clock_getres(CLOCK_REALTIME, {%jd, %jd}) = 0\n",
+	       (intmax_t) t.ts.tv_sec,
+	       (intmax_t) t.ts.tv_nsec);
+
+	if (syscall(__NR_clock_gettime, CLOCK_PROCESS_CPUTIME_ID, &t.ts))
+		perror_msg_and_skip("clock_gettime CLOCK_PROCESS_CPUTIME_ID");
+	printf("clock_gettime(CLOCK_PROCESS_CPUTIME_ID, {%jd, %jd}) = 0\n",
+	       (intmax_t) t.ts.tv_sec,
+	       (intmax_t) t.ts.tv_nsec);
+
+	t.ts.tv_sec = 0xdeface1;
+	t.ts.tv_nsec = 0xdeface2;
+	if (!syscall(__NR_clock_settime, CLOCK_THREAD_CPUTIME_ID, &t.ts))
+		error_msg_and_skip("clock_settime CLOCK_THREAD_CPUTIME_ID:"
+				   " EINVAL expected");
+	printf("clock_settime(CLOCK_THREAD_CPUTIME_ID, {%jd, %jd})"
+	       " = -1 EINVAL (%m)\n",
+	       (intmax_t) t.ts.tv_sec,
+	       (intmax_t) t.ts.tv_nsec);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_clock_getres && __NR_clock_gettime && __NR_clock_settime")
+
+#endif
diff --git a/strace/tests/clock_xettime.test b/strace/tests/clock_xettime.test
new file mode 100755
index 0000000..f045a66
--- /dev/null
+++ b/strace/tests/clock_xettime.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check clock_getres, clock_gettime, and clock_settime syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a36 -e trace=clock_getres,clock_gettime,clock_settime
diff --git a/strace/tests/copy_file_range.c b/strace/tests/copy_file_range.c
new file mode 100644
index 0000000..0e563d6
--- /dev/null
+++ b/strace/tests/copy_file_range.c
@@ -0,0 +1,65 @@
+/*
+ * This file is part of copy_file_range strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_copy_file_range
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd_in = (long int) 0xdeadbeefffffffff;
+	const long int fd_out = (long int) 0xdeadbeeffffffffe;
+	long long int *const off_in = tail_alloc(sizeof(*off_in));
+	long long int *const off_out = tail_alloc(sizeof(*off_out));
+	*off_in = 0xdeadbef1facefed1;
+	*off_out = 0xdeadbef2facefed2;
+	const size_t len = (size_t) 0xdeadbef3facefed3ULL;
+	const unsigned int flags = 0;
+
+	long rc = syscall(__NR_copy_file_range,
+			  fd_in, off_in, fd_out, off_out, len, flags);
+	printf("copy_file_range(%d, [%lld], %d, [%lld], %zu, %u)"
+	       " = %ld %s (%m)\n",
+	       (int) fd_in, *off_in, (int) fd_out, *off_out, len, flags,
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_copy_file_range")
+
+#endif
diff --git a/strace/tests/copy_file_range.test b/strace/tests/copy_file_range.test
new file mode 100755
index 0000000..c39f6ac
--- /dev/null
+++ b/strace/tests/copy_file_range.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check copy_file_range syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/count-f.c b/strace/tests/count-f.c
new file mode 100644
index 0000000..6992b16
--- /dev/null
+++ b/strace/tests/count-f.c
@@ -0,0 +1,102 @@
+/*
+ * This file is part of count-f strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <errno.h>
+#include <pthread.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/wait.h>
+#include <unistd.h>
+
+#define N 32
+#define P 8
+#define T 4
+
+static void *
+thread(void *arg)
+{
+	unsigned int i;
+
+	assert(chdir(".") == 0);
+	for (i = 0; i < N; ++i) {
+		assert(chdir("") == -1);
+		assert(chdir(".") == 0);
+	}
+
+	return NULL;
+}
+
+static int
+process(void)
+{
+	unsigned int i;
+	pthread_t t[T];
+
+	for (i = 0; i < T; ++i) {
+		errno = pthread_create(&t[i], NULL, thread, NULL);
+		if (errno)
+			perror_msg_and_fail("pthread_create");
+	}
+
+	for (i = 0; i < T; ++i) {
+		void *retval;
+		errno = pthread_join(t[i], &retval);
+		if (errno)
+			perror_msg_and_fail("pthread_join");
+	}
+
+	return 0;
+}
+
+int
+main(void)
+{
+	unsigned int i;
+	pid_t p[P];
+
+	for (i = 0; i < P; ++i) {
+		p[i] = fork();
+		if (p[i] < 0)
+			perror_msg_and_fail("fork");
+		if (!p[i])
+			return process();
+	}
+	for (i = 0; i < P; ++i) {
+		int s;
+
+		assert(waitpid(p[i], &s, 0) == p[i]);
+		assert(WIFEXITED(s));
+		if (WEXITSTATUS(s))
+			return WEXITSTATUS(s);
+	}
+
+	return 0;
+}
diff --git a/strace/tests/count-f.expected b/strace/tests/count-f.expected
new file mode 100644
index 0000000..f61ba54
--- /dev/null
+++ b/strace/tests/count-f.expected
@@ -0,0 +1 @@
+[ ]*[^ ]+ +[^ ]+ +[^ ]+ +2080 +1024 +chdir
diff --git a/strace/tests/count-f.test b/strace/tests/count-f.test
new file mode 100755
index 0000000..67515ef
--- /dev/null
+++ b/strace/tests/count-f.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check whether -c counts through forks and clones properly
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -q -f -c $args
+match_grep
+
+exit 0
diff --git a/strace/tests/count.test b/strace/tests/count.test
new file mode 100755
index 0000000..e75dc6b
--- /dev/null
+++ b/strace/tests/count.test
@@ -0,0 +1,56 @@
+#!/bin/sh
+#
+# Check whether -c and -w options work.
+#
+# Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./sleep 0
+check_prog grep
+
+grep_log()
+{
+	local pattern="$1"; shift
+
+	run_strace "$@" ./sleep 1
+
+	grep nanosleep "$LOG" > /dev/null ||
+		framework_skip_ 'sleep does not use nanosleep'
+
+	LC_ALL=C grep -E -x -e "$pattern" "$LOG" > /dev/null || {
+		echo "Pattern of expected output: $pattern"
+		echo 'Actual output:'
+		dump_log_and_fail_with "$STRACE $args output mismatch"
+	}
+}
+
+grep_log ' *[^ ]+ +0\.0[^n]*nanosleep'		-c
+grep_log ' *[^ ]+ +0\.0[^n]*nanosleep'		-c -enanosleep
+grep_log ' *[^ ]+ +(1\.[01]|0\.99)[^n]*nanosleep'	-cw
+grep_log '100\.00 +(1\.[01]|0\.99)[^n]*nanosleep'	-cw -enanosleep
+
+exit 0
diff --git a/strace/tests/creat.c b/strace/tests/creat.c
new file mode 100644
index 0000000..8572e7f
--- /dev/null
+++ b/strace/tests/creat.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_creat
+
+# include <stdio.h>
+# include <unistd.h>
+
+# define TMP_FILE "creat"
+
+int
+main(void)
+{
+	long rc = syscall(__NR_creat, TMP_FILE, 0400);
+	printf("creat(\"%s\", %#o) = %ld %s (%m)\n",
+	       TMP_FILE, 0400, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_creat")
+
+#endif
diff --git a/strace/tests/creat.test b/strace/tests/creat.test
new file mode 100755
index 0000000..49fddd2
--- /dev/null
+++ b/strace/tests/creat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check creat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21
diff --git a/strace/tests/detach-running.test b/strace/tests/detach-running.test
new file mode 100755
index 0000000..b77dc51
--- /dev/null
+++ b/strace/tests/detach-running.test
@@ -0,0 +1,90 @@
+#!/bin/sh
+#
+# Ensure that strace can detach from running processes.
+#
+# Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed \
+	kill -0 $$
+
+check_prog sleep
+
+set -e
+
+./set_ptracer_any sh -c "echo > $LOG; while :; do :; done" > /dev/null &
+
+while ! [ -s "$LOG" ]; do
+	kill -0 $! 2> /dev/null ||
+		fail_ 'set_ptracer_any sh failed'
+	$SLEEP_A_BIT
+done
+
+tracee_pid=$!
+
+cleanup()
+{
+	set +e
+	kill $tracee_pid
+	wait $tracee_pid 2> /dev/null
+	return 0
+}
+
+rm -f "$LOG"
+$STRACE -p $tracee_pid 2> "$LOG" &
+
+while ! grep -F "Process $tracee_pid attached" "$LOG" > /dev/null; do
+	kill -0 $! 2> /dev/null || {
+		cleanup
+		dump_log_and_fail_with "$STRACE -p failed to attach"
+	}
+	$SLEEP_A_BIT
+done
+
+kill -INT $!
+wait $!
+
+grep -F "Process $tracee_pid detached" "$LOG" > /dev/null || {
+		cleanup
+		dump_log_and_fail_with "$STRACE -p failed to detach"
+	}
+
+if [ -f /proc/self/status ]; then
+	$SLEEP_A_BIT
+	test -d /proc/$tracee_pid || {
+		cleanup
+		dump_log_and_fail_with 'tracee died after detach'
+	}
+	grep '^State:.*R (running)' < /proc/$tracee_pid/status > /dev/null || {
+		grep '^State:' < /proc/$tracee_pid/status
+		cleanup
+		dump_log_and_fail_with 'tracee is not running after detach'
+	}
+fi
+
+cleanup
+exit 0
diff --git a/strace/tests/detach-sleeping.test b/strace/tests/detach-sleeping.test
new file mode 100755
index 0000000..546c21d
--- /dev/null
+++ b/strace/tests/detach-sleeping.test
@@ -0,0 +1,91 @@
+#!/bin/sh
+#
+# Ensure that strace can detach from sleeping processes.
+#
+# Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed \
+	kill -0 $$
+
+check_prog sleep
+
+set -e
+
+rm -f "$LOG"
+./set_ptracer_any sleep $((2*$TIMEOUT_DURATION)) > "$LOG" &
+
+while ! [ -s "$LOG" ]; do
+	kill -0 $! 2> /dev/null ||
+		fail_ 'set_ptracer_any sleep failed'
+	$SLEEP_A_BIT
+done
+
+tracee_pid=$!
+
+cleanup()
+{
+	set +e
+	kill $tracee_pid
+	wait $tracee_pid 2> /dev/null
+	return 0
+}
+
+rm -f "$LOG"
+$STRACE -p $tracee_pid 2> "$LOG" &
+
+while ! grep -F "Process $tracee_pid attached" "$LOG" > /dev/null; do
+	kill -0 $! 2> /dev/null || {
+		cleanup
+		dump_log_and_fail_with "$STRACE -p failed to attach"
+	}
+	$SLEEP_A_BIT
+done
+
+kill -INT $!
+wait $!
+
+grep -F "Process $tracee_pid detached" "$LOG" > /dev/null || {
+	cleanup
+	dump_log_and_fail_with "$STRACE -p failed to detach"
+}
+
+if [ -f /proc/self/status ]; then
+	$SLEEP_A_BIT
+	test -d /proc/$tracee_pid || {
+		cleanup
+		dump_log_and_fail_with 'tracee died after detach'
+	}
+	grep '^State:.*S (sleeping)' < /proc/$tracee_pid/status > /dev/null || {
+		grep '^State:' < /proc/$tracee_pid/status
+		cleanup
+		dump_log_and_fail_with 'tracee is not sleeping after detach'
+	}
+fi
+
+cleanup
+exit 0
diff --git a/strace/tests/detach-stopped.test b/strace/tests/detach-stopped.test
new file mode 100755
index 0000000..ca4d4e9
--- /dev/null
+++ b/strace/tests/detach-stopped.test
@@ -0,0 +1,106 @@
+#!/bin/sh
+#
+# Ensure that strace can detach from stopped processes.
+#
+# Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed \
+	kill -0 $$
+
+check_prog sleep
+
+$STRACE -d -enone / > /dev/null 2> "$LOG"
+if grep -x "[^:]*strace: PTRACE_SEIZE doesn't work" "$LOG" > /dev/null; then
+	skip_ "PTRACE_SEIZE doesn't work"
+fi
+
+set -e
+
+rm -f "$LOG"
+./set_ptracer_any sleep $((2*$TIMEOUT_DURATION)) > "$LOG" &
+
+while ! [ -s "$LOG" ]; do
+	kill -0 $! 2> /dev/null ||
+		fail_ 'set_ptracer_any sleep failed'
+	$SLEEP_A_BIT
+done
+
+tracee_pid=$!
+kill -STOP $tracee_pid
+
+cleanup()
+{
+	set +e
+	kill $tracee_pid
+	kill -CONT $tracee_pid
+	wait $tracee_pid 2> /dev/null
+	return 0
+}
+
+rm -f "$LOG"
+$STRACE -p $tracee_pid 2> "$LOG" &
+
+while ! grep -F "Process $tracee_pid attached" "$LOG" > /dev/null; do
+	kill -0 $! 2> /dev/null || {
+		cleanup
+		dump_log_and_fail_with "$STRACE -p failed to attach"
+	}
+	$SLEEP_A_BIT
+done
+
+while ! grep -F -e '--- stopped by ' "$LOG" > /dev/null; do
+	kill -0 $! 2> /dev/null || {
+		cleanup
+		dump_log_and_fail_with "$STRACE -p missed stop notifications"
+	}
+	$SLEEP_A_BIT
+done
+
+kill -INT $!
+wait $!
+
+grep -F "Process $tracee_pid detached" "$LOG" > /dev/null || {
+	cleanup
+	dump_log_and_fail_with "$STRACE -p failed to detach"
+}
+
+if [ -f /proc/self/status ]; then
+	$SLEEP_A_BIT
+	test -d /proc/$tracee_pid || {
+		cleanup
+		dump_log_and_fail_with 'tracee died after detach'
+	}
+	grep '^State:.*T (stopped)' < /proc/$tracee_pid/status > /dev/null || {
+		grep '^State:' < /proc/$tracee_pid/status
+		cleanup
+		dump_log_and_fail_with 'tracee is not group-stopped after detach'
+	}
+fi
+
+cleanup
+exit 0
diff --git a/strace/tests/dup.c b/strace/tests/dup.c
new file mode 100644
index 0000000..62157e2
--- /dev/null
+++ b/strace/tests/dup.c
@@ -0,0 +1,13 @@
+#include "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	int rc = dup(-1);
+	printf("dup(-1) = %d %s (%m)\n", rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/dup.test b/strace/tests/dup.test
new file mode 100755
index 0000000..1dc1919
--- /dev/null
+++ b/strace/tests/dup.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check dup syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a8
diff --git a/strace/tests/dup2.c b/strace/tests/dup2.c
new file mode 100644
index 0000000..70d8f3e
--- /dev/null
+++ b/strace/tests/dup2.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_dup2
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd_old = (long int) 0xdeadbeefffffffff;
+	const long int fd_new = (long int) 0xdeadbeeffffffffe;
+
+	long rc = syscall(__NR_dup2, fd_old, fd_new);
+	printf("dup2(%d, %d) = %ld %s (%m)\n",
+	       (int) fd_old, (int) fd_new, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_dup2")
+
+#endif
diff --git a/strace/tests/dup2.test b/strace/tests/dup2.test
new file mode 100755
index 0000000..509c5db
--- /dev/null
+++ b/strace/tests/dup2.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check dup2 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a13
diff --git a/strace/tests/dup3.c b/strace/tests/dup3.c
new file mode 100644
index 0000000..884331a
--- /dev/null
+++ b/strace/tests/dup3.c
@@ -0,0 +1,28 @@
+#include "tests.h"
+#include <fcntl.h>
+#include <sys/syscall.h>
+
+#if defined __NR_dup3 && defined O_CLOEXEC
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd_old = (long int) 0xdeadbeefffffffff;
+	const long int fd_new = (long int) 0xdeadbeeffffffffe;
+
+	long rc = syscall(__NR_dup3, fd_old, fd_new, O_CLOEXEC);
+	printf("dup3(%d, %d, O_CLOEXEC) = %ld %s (%m)\n",
+	       (int) fd_old, (int) fd_new, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_dup3 && && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/dup3.test b/strace/tests/dup3.test
new file mode 100755
index 0000000..293f78f
--- /dev/null
+++ b/strace/tests/dup3.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check dup3 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24
diff --git a/strace/tests/epoll_create.c b/strace/tests/epoll_create.c
new file mode 100644
index 0000000..4be06c4
--- /dev/null
+++ b/strace/tests/epoll_create.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_epoll_create
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int size = (long int) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_epoll_create, size);
+	printf("epoll_create(%d) = %ld %s (%m)\n",
+	       (int) size, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_epoll_creat")
+
+#endif
diff --git a/strace/tests/epoll_create.test b/strace/tests/epoll_create.test
new file mode 100755
index 0000000..472a9bd
--- /dev/null
+++ b/strace/tests/epoll_create.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check epoll_create syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a17
diff --git a/strace/tests/epoll_create1.c b/strace/tests/epoll_create1.c
new file mode 100644
index 0000000..d348492
--- /dev/null
+++ b/strace/tests/epoll_create1.c
@@ -0,0 +1,60 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <sys/syscall.h>
+
+#if defined __NR_epoll_create1 && defined O_CLOEXEC
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_epoll_create1, O_CLOEXEC);
+	if (rc == -1) {
+		printf("epoll_create1(EPOLL_CLOEXEC) = -1 %s (%m)\n",
+		       errno2name());
+	} else {
+		printf("epoll_create1(EPOLL_CLOEXEC) = %ld\n", rc);
+	}
+
+	rc = syscall(__NR_epoll_create1, O_CLOEXEC | O_NONBLOCK);
+	printf("epoll_create1(EPOLL_CLOEXEC|%#x) = %ld %s (%m)\n",
+	       O_NONBLOCK, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_epoll_create1 && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/epoll_create1.test b/strace/tests/epoll_create1.test
new file mode 100755
index 0000000..7a926a9
--- /dev/null
+++ b/strace/tests/epoll_create1.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check epoll_create1 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28
diff --git a/strace/tests/epoll_ctl.c b/strace/tests/epoll_ctl.c
new file mode 100644
index 0000000..231e271
--- /dev/null
+++ b/strace/tests/epoll_ctl.c
@@ -0,0 +1,45 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_epoll_ctl
+
+# include <inttypes.h>
+# include <stdio.h>
+# include <sys/epoll.h>
+# include <unistd.h>
+
+static long
+invoke_syscall(unsigned long epfd, unsigned long op, unsigned long fd, void *ev)
+{
+	op |= (unsigned long) 0xffffffff00000000;
+	return syscall(__NR_epoll_ctl, epfd, op, fd, (unsigned long) ev);
+}
+
+int
+main(void)
+{
+	struct epoll_event *const ev = tail_alloc(sizeof(*ev));
+	ev->events = EPOLLIN;
+
+	long rc = invoke_syscall(-1U, EPOLL_CTL_ADD, -2U, ev);
+	printf("epoll_ctl(-1, EPOLL_CTL_ADD, -2, {EPOLLIN,"
+	       " {u32=%u, u64=%" PRIu64 "}}) = %ld %s (%m)\n",
+	       ev->data.u32, ev->data.u64, rc, errno2name());
+
+	rc = invoke_syscall(-3U, EPOLL_CTL_DEL, -4U, ev);
+	printf("epoll_ctl(-3, EPOLL_CTL_DEL, -4, %p) = %ld %s (%m)\n",
+	       ev, rc, errno2name());
+
+	rc = invoke_syscall(-1UL, EPOLL_CTL_MOD, -16UL, 0);
+	printf("epoll_ctl(-1, EPOLL_CTL_MOD, -16, NULL) = %ld %s (%m)\n",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_epoll_ctl")
+
+#endif
diff --git a/strace/tests/epoll_ctl.test b/strace/tests/epoll_ctl.test
new file mode 100755
index 0000000..1aded54
--- /dev/null
+++ b/strace/tests/epoll_ctl.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check epoll_ctl syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/epoll_pwait.c b/strace/tests/epoll_pwait.c
new file mode 100644
index 0000000..acd4218
--- /dev/null
+++ b/strace/tests/epoll_pwait.c
@@ -0,0 +1,32 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_epoll_pwait
+
+# include <signal.h>
+# include <stdio.h>
+# include <sys/epoll.h>
+# include <unistd.h>
+
+# include "kernel_types.h"
+
+int
+main(void)
+{
+	sigset_t set[2];
+	struct epoll_event *const ev = tail_alloc(sizeof(*ev));
+
+	long rc = syscall(__NR_epoll_pwait, -1, ev, 1, -2,
+			  set, (kernel_ulong_t) sizeof(set));
+	printf("epoll_pwait(-1, %p, 1, -2, %p, %u) = %ld %s (%m)\n",
+	       ev, set, (unsigned) sizeof(set), rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_epoll_pwait")
+
+#endif
diff --git a/strace/tests/epoll_pwait.test b/strace/tests/epoll_pwait.test
new file mode 100755
index 0000000..c7aeeac
--- /dev/null
+++ b/strace/tests/epoll_pwait.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of epoll_pwait syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/epoll_wait.c b/strace/tests/epoll_wait.c
new file mode 100644
index 0000000..c2eb563
--- /dev/null
+++ b/strace/tests/epoll_wait.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_epoll_wait
+
+# include <stdio.h>
+# include <sys/epoll.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	struct epoll_event *const ev = tail_alloc(sizeof(*ev));
+
+	long rc = syscall(__NR_epoll_wait, -1, ev, 1, -2);
+	printf("epoll_wait(-1, %p, 1, -2) = %ld %s (%m)\n",
+	       ev, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_epoll_wait")
+
+#endif
diff --git a/strace/tests/epoll_wait.test b/strace/tests/epoll_wait.test
new file mode 100755
index 0000000..83ae161
--- /dev/null
+++ b/strace/tests/epoll_wait.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check epoll_wait syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a26
diff --git a/strace/tests/errno2name.c b/strace/tests/errno2name.c
new file mode 100644
index 0000000..4a17699
--- /dev/null
+++ b/strace/tests/errno2name.c
@@ -0,0 +1,481 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+
+#define CASE(x) case x: return #x
+
+const char *
+errno2name(void)
+{
+	switch (errno) {
+	/* names taken from linux/errnoent.h */
+#ifdef E2BIG
+	CASE(E2BIG);
+#endif
+#ifdef EACCES
+	CASE(EACCES);
+#endif
+#ifdef EADDRINUSE
+	CASE(EADDRINUSE);
+#endif
+#ifdef EADDRNOTAVAIL
+	CASE(EADDRNOTAVAIL);
+#endif
+#ifdef EADV
+	CASE(EADV);
+#endif
+#ifdef EAFNOSUPPORT
+	CASE(EAFNOSUPPORT);
+#endif
+#ifdef EAGAIN
+	CASE(EAGAIN);
+#endif
+#ifdef EALREADY
+	CASE(EALREADY);
+#endif
+#ifdef EBADCOOKIE
+	CASE(EBADCOOKIE);
+#endif
+#ifdef EBADE
+	CASE(EBADE);
+#endif
+#ifdef EBADF
+	CASE(EBADF);
+#endif
+#ifdef EBADFD
+	CASE(EBADFD);
+#endif
+#ifdef EBADHANDLE
+	CASE(EBADHANDLE);
+#endif
+#ifdef EBADMSG
+	CASE(EBADMSG);
+#endif
+#ifdef EBADR
+	CASE(EBADR);
+#endif
+#ifdef EBADRQC
+	CASE(EBADRQC);
+#endif
+#ifdef EBADSLT
+	CASE(EBADSLT);
+#endif
+#ifdef EBADTYPE
+	CASE(EBADTYPE);
+#endif
+#ifdef EBFONT
+	CASE(EBFONT);
+#endif
+#ifdef EBUSY
+	CASE(EBUSY);
+#endif
+#ifdef ECANCELED
+	CASE(ECANCELED);
+#endif
+#ifdef ECHILD
+	CASE(ECHILD);
+#endif
+#ifdef ECHRNG
+	CASE(ECHRNG);
+#endif
+#ifdef ECOMM
+	CASE(ECOMM);
+#endif
+#ifdef ECONNABORTED
+	CASE(ECONNABORTED);
+#endif
+#ifdef ECONNREFUSED
+	CASE(ECONNREFUSED);
+#endif
+#ifdef ECONNRESET
+	CASE(ECONNRESET);
+#endif
+#ifdef EDEADLK
+	CASE(EDEADLK);
+#endif
+#ifdef EDESTADDRREQ
+	CASE(EDESTADDRREQ);
+#endif
+#ifdef EDOM
+	CASE(EDOM);
+#endif
+#ifdef EDOTDOT
+	CASE(EDOTDOT);
+#endif
+#ifdef EDQUOT
+	CASE(EDQUOT);
+#endif
+#ifdef EEXIST
+	CASE(EEXIST);
+#endif
+#ifdef EFAULT
+	CASE(EFAULT);
+#endif
+#ifdef EFBIG
+	CASE(EFBIG);
+#endif
+#ifdef EHOSTDOWN
+	CASE(EHOSTDOWN);
+#endif
+#ifdef EHOSTUNREACH
+	CASE(EHOSTUNREACH);
+#endif
+#ifdef EHWPOISON
+	CASE(EHWPOISON);
+#endif
+#ifdef EIDRM
+	CASE(EIDRM);
+#endif
+#ifdef EILSEQ
+	CASE(EILSEQ);
+#endif
+#ifdef EINPROGRESS
+	CASE(EINPROGRESS);
+#endif
+#ifdef EINTR
+	CASE(EINTR);
+#endif
+#ifdef EINVAL
+	CASE(EINVAL);
+#endif
+#ifdef EIO
+	CASE(EIO);
+#endif
+#ifdef EIOCBQUEUED
+	CASE(EIOCBQUEUED);
+#endif
+#ifdef EISCONN
+	CASE(EISCONN);
+#endif
+#ifdef EISDIR
+	CASE(EISDIR);
+#endif
+#ifdef EISNAM
+	CASE(EISNAM);
+#endif
+#ifdef EJUKEBOX
+	CASE(EJUKEBOX);
+#endif
+#ifdef EKEYEXPIRED
+	CASE(EKEYEXPIRED);
+#endif
+#ifdef EKEYREJECTED
+	CASE(EKEYREJECTED);
+#endif
+#ifdef EKEYREVOKED
+	CASE(EKEYREVOKED);
+#endif
+#ifdef EL2HLT
+	CASE(EL2HLT);
+#endif
+#ifdef EL2NSYNC
+	CASE(EL2NSYNC);
+#endif
+#ifdef EL3HLT
+	CASE(EL3HLT);
+#endif
+#ifdef EL3RST
+	CASE(EL3RST);
+#endif
+#ifdef ELIBACC
+	CASE(ELIBACC);
+#endif
+#ifdef ELIBBAD
+	CASE(ELIBBAD);
+#endif
+#ifdef ELIBEXEC
+	CASE(ELIBEXEC);
+#endif
+#ifdef ELIBMAX
+	CASE(ELIBMAX);
+#endif
+#ifdef ELIBSCN
+	CASE(ELIBSCN);
+#endif
+#ifdef ELNRNG
+	CASE(ELNRNG);
+#endif
+#ifdef ELOOP
+	CASE(ELOOP);
+#endif
+#ifdef EMEDIUMTYPE
+	CASE(EMEDIUMTYPE);
+#endif
+#ifdef EMFILE
+	CASE(EMFILE);
+#endif
+#ifdef EMLINK
+	CASE(EMLINK);
+#endif
+#ifdef EMSGSIZE
+	CASE(EMSGSIZE);
+#endif
+#ifdef EMULTIHOP
+	CASE(EMULTIHOP);
+#endif
+#ifdef ENAMETOOLONG
+	CASE(ENAMETOOLONG);
+#endif
+#ifdef ENAVAIL
+	CASE(ENAVAIL);
+#endif
+#ifdef ENETDOWN
+	CASE(ENETDOWN);
+#endif
+#ifdef ENETRESET
+	CASE(ENETRESET);
+#endif
+#ifdef ENETUNREACH
+	CASE(ENETUNREACH);
+#endif
+#ifdef ENFILE
+	CASE(ENFILE);
+#endif
+#ifdef ENOANO
+	CASE(ENOANO);
+#endif
+#ifdef ENOBUFS
+	CASE(ENOBUFS);
+#endif
+#ifdef ENOCSI
+	CASE(ENOCSI);
+#endif
+#ifdef ENODATA
+	CASE(ENODATA);
+#endif
+#ifdef ENODEV
+	CASE(ENODEV);
+#endif
+#ifdef ENOENT
+	CASE(ENOENT);
+#endif
+#ifdef ENOEXEC
+	CASE(ENOEXEC);
+#endif
+#ifdef ENOIOCTLCMD
+	CASE(ENOIOCTLCMD);
+#endif
+#ifdef ENOKEY
+	CASE(ENOKEY);
+#endif
+#ifdef ENOLCK
+	CASE(ENOLCK);
+#endif
+#ifdef ENOLINK
+	CASE(ENOLINK);
+#endif
+#ifdef ENOMEDIUM
+	CASE(ENOMEDIUM);
+#endif
+#ifdef ENOMEM
+	CASE(ENOMEM);
+#endif
+#ifdef ENOMSG
+	CASE(ENOMSG);
+#endif
+#ifdef ENONET
+	CASE(ENONET);
+#endif
+#ifdef ENOPKG
+	CASE(ENOPKG);
+#endif
+#ifdef ENOPROTOOPT
+	CASE(ENOPROTOOPT);
+#endif
+#ifdef ENOSPC
+	CASE(ENOSPC);
+#endif
+#ifdef ENOSR
+	CASE(ENOSR);
+#endif
+#ifdef ENOSTR
+	CASE(ENOSTR);
+#endif
+#ifdef ENOSYS
+	CASE(ENOSYS);
+#endif
+#ifdef ENOTBLK
+	CASE(ENOTBLK);
+#endif
+#ifdef ENOTCONN
+	CASE(ENOTCONN);
+#endif
+#ifdef ENOTDIR
+	CASE(ENOTDIR);
+#endif
+#ifdef ENOTEMPTY
+	CASE(ENOTEMPTY);
+#endif
+#ifdef ENOTNAM
+	CASE(ENOTNAM);
+#endif
+#ifdef ENOTRECOVERABLE
+	CASE(ENOTRECOVERABLE);
+#endif
+#ifdef ENOTSOCK
+	CASE(ENOTSOCK);
+#endif
+#ifdef ENOTSUPP
+	CASE(ENOTSUPP);
+#endif
+#ifdef ENOTSYNC
+	CASE(ENOTSYNC);
+#endif
+#ifdef ENOTTY
+	CASE(ENOTTY);
+#endif
+#ifdef ENOTUNIQ
+	CASE(ENOTUNIQ);
+#endif
+#ifdef ENXIO
+	CASE(ENXIO);
+#endif
+#ifdef EOPENSTALE
+	CASE(EOPENSTALE);
+#endif
+#ifdef EOPNOTSUPP
+	CASE(EOPNOTSUPP);
+#endif
+#ifdef EOVERFLOW
+	CASE(EOVERFLOW);
+#endif
+#ifdef EOWNERDEAD
+	CASE(EOWNERDEAD);
+#endif
+#ifdef EPERM
+	CASE(EPERM);
+#endif
+#ifdef EPFNOSUPPORT
+	CASE(EPFNOSUPPORT);
+#endif
+#ifdef EPIPE
+	CASE(EPIPE);
+#endif
+#ifdef EPROBE_DEFER
+	CASE(EPROBE_DEFER);
+#endif
+#ifdef EPROTO
+	CASE(EPROTO);
+#endif
+#ifdef EPROTONOSUPPORT
+	CASE(EPROTONOSUPPORT);
+#endif
+#ifdef EPROTOTYPE
+	CASE(EPROTOTYPE);
+#endif
+#ifdef ERANGE
+	CASE(ERANGE);
+#endif
+#ifdef EREMCHG
+	CASE(EREMCHG);
+#endif
+#ifdef EREMOTE
+	CASE(EREMOTE);
+#endif
+#ifdef EREMOTEIO
+	CASE(EREMOTEIO);
+#endif
+#ifdef ERESTART
+	CASE(ERESTART);
+#endif
+#ifdef ERESTARTNOHAND
+	CASE(ERESTARTNOHAND);
+#endif
+#ifdef ERESTARTNOINTR
+	CASE(ERESTARTNOINTR);
+#endif
+#ifdef ERESTARTSYS
+	CASE(ERESTARTSYS);
+#endif
+#ifdef ERESTART_RESTARTBLOCK
+	CASE(ERESTART_RESTARTBLOCK);
+#endif
+#ifdef ERFKILL
+	CASE(ERFKILL);
+#endif
+#ifdef EROFS
+	CASE(EROFS);
+#endif
+#ifdef ESERVERFAULT
+	CASE(ESERVERFAULT);
+#endif
+#ifdef ESHUTDOWN
+	CASE(ESHUTDOWN);
+#endif
+#ifdef ESOCKTNOSUPPORT
+	CASE(ESOCKTNOSUPPORT);
+#endif
+#ifdef ESPIPE
+	CASE(ESPIPE);
+#endif
+#ifdef ESRCH
+	CASE(ESRCH);
+#endif
+#ifdef ESRMNT
+	CASE(ESRMNT);
+#endif
+#ifdef ESTALE
+	CASE(ESTALE);
+#endif
+#ifdef ESTRPIPE
+	CASE(ESTRPIPE);
+#endif
+#ifdef ETIME
+	CASE(ETIME);
+#endif
+#ifdef ETIMEDOUT
+	CASE(ETIMEDOUT);
+#endif
+#ifdef ETOOMANYREFS
+	CASE(ETOOMANYREFS);
+#endif
+#ifdef ETOOSMALL
+	CASE(ETOOSMALL);
+#endif
+#ifdef ETXTBSY
+	CASE(ETXTBSY);
+#endif
+#ifdef EUCLEAN
+	CASE(EUCLEAN);
+#endif
+#ifdef EUNATCH
+	CASE(EUNATCH);
+#endif
+#ifdef EUSERS
+	CASE(EUSERS);
+#endif
+#ifdef EXDEV
+	CASE(EXDEV);
+#endif
+#ifdef EXFULL
+	CASE(EXFULL);
+#endif
+	default: perror_msg_and_fail("unknown errno %d", errno);
+	}
+}
diff --git a/strace/tests/error_msg.c b/strace/tests/error_msg.c
new file mode 100644
index 0000000..498a882
--- /dev/null
+++ b/strace/tests/error_msg.c
@@ -0,0 +1,85 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <stdarg.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+void
+perror_msg_and_fail(const char *fmt, ...)
+{
+	int err_no = errno;
+	va_list p;
+
+	va_start(p, fmt);
+	vfprintf(stderr, fmt, p);
+	if (err_no)
+		fprintf(stderr, ": %s\n", strerror(err_no));
+	else
+		putc('\n', stderr);
+	exit(1);
+}
+
+void
+error_msg_and_fail(const char *fmt, ...)
+{
+	va_list p;
+
+	va_start(p, fmt);
+	vfprintf(stderr, fmt, p);
+	putc('\n', stderr);
+	exit(1);
+}
+
+void
+error_msg_and_skip(const char *fmt, ...)
+{
+	va_list p;
+
+	va_start(p, fmt);
+	vfprintf(stderr, fmt, p);
+	putc('\n', stderr);
+	exit(77);
+}
+
+void
+perror_msg_and_skip(const char *fmt, ...)
+{
+	int err_no = errno;
+	va_list p;
+
+	va_start(p, fmt);
+	vfprintf(stderr, fmt, p);
+	if (err_no)
+		fprintf(stderr, ": %s\n", strerror(err_no));
+	else
+		putc('\n', stderr);
+	exit(77);
+}
diff --git a/strace/tests/eventfd.c b/strace/tests/eventfd.c
new file mode 100644
index 0000000..8b08443
--- /dev/null
+++ b/strace/tests/eventfd.c
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+#if defined __NR_eventfd2 && defined O_CLOEXEC
+
+int
+main(void)
+{
+	(void) close(0);
+	if (syscall(__NR_eventfd2, -1L, 1 | O_CLOEXEC | O_NONBLOCK))
+		perror_msg_and_skip("eventfd2");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_eventfd2 && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/eventfd.expected b/strace/tests/eventfd.expected
new file mode 100644
index 0000000..c4b45a0
--- /dev/null
+++ b/strace/tests/eventfd.expected
@@ -0,0 +1,2 @@
+eventfd2(4294967295, EFD_SEMAPHORE|EFD_CLOEXEC|EFD_NONBLOCK) = 0
++++ exited with 0 +++
diff --git a/strace/tests/eventfd.test b/strace/tests/eventfd.test
new file mode 100755
index 0000000..e181ed6
--- /dev/null
+++ b/strace/tests/eventfd.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check eventfd2 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -e eventfd2 $args
+match_diff
+
+exit 0
diff --git a/strace/tests/execve-v.c b/strace/tests/execve-v.c
new file mode 100644
index 0000000..26bc9d6
--- /dev/null
+++ b/strace/tests/execve-v.c
@@ -0,0 +1,3 @@
+/* This file is part of execve-v strace test. */
+#define VERBOSE_EXECVE
+#include "execve.c"
diff --git a/strace/tests/execve-v.test b/strace/tests/execve-v.test
new file mode 100755
index 0000000..cce5860
--- /dev/null
+++ b/strace/tests/execve-v.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check verbose decoding of execve syscall.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog > /dev/null
+run_strace -veexecve $args > "$EXP"
+
+# Filter out execve() call made by strace.
+grep -F test.execve < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/execve.c b/strace/tests/execve.c
new file mode 100644
index 0000000..852eebf
--- /dev/null
+++ b/strace/tests/execve.c
@@ -0,0 +1,171 @@
+/*
+ * This file is part of execve strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+
+#define FILENAME "test.execve\nfilename"
+#define Q_FILENAME "test.execve\\nfilename"
+
+static const char * const argv[] = {
+	FILENAME, "first", "second", (const char *) -1L,
+	(const char *) -2L, (const char *) -3L
+};
+static const char * const q_argv[] = {
+	Q_FILENAME, "first", "second"
+};
+
+static const char * const envp[] = {
+	"foobar=1", "foo\nbar=2", (const char *) -1L,
+	(const char *) -2L, (const char *) -3L
+};
+static const char * const q_envp[] = {
+	"foobar=1", "foo\\nbar=2"
+};
+
+int
+main(void)
+{
+	char ** const tail_argv = tail_memdup(argv, sizeof(argv));
+	char ** const tail_envp = tail_memdup(envp, sizeof(envp));
+
+	execve(FILENAME, tail_argv, tail_envp);
+	printf("execve(\"%s\""
+	       ", [\"%s\", \"%s\", \"%s\", %p, %p, %p, ???]"
+#ifdef VERBOSE_EXECVE
+	       ", [\"%s\", \"%s\", %p, %p, %p, ???]"
+#else
+	       ", [/* 5 vars, unterminated */]"
+#endif
+	       ") = -1 ENOENT (%m)\n",
+	       Q_FILENAME, q_argv[0], q_argv[1], q_argv[2],
+	       argv[3], argv[4], argv[5]
+#ifdef VERBOSE_EXECVE
+	       , q_envp[0], q_envp[1], envp[2], envp[3], envp[4]
+#endif
+	       );
+
+	tail_argv[ARRAY_SIZE(q_argv)] = NULL;
+	tail_envp[ARRAY_SIZE(q_envp)] = NULL;
+
+	execve(FILENAME, tail_argv, tail_envp);
+	printf("execve(\"%s\", [\"%s\", \"%s\", \"%s\"]"
+#ifdef VERBOSE_EXECVE
+	       ", [\"%s\", \"%s\"]"
+#else
+	       ", [/* 2 vars */]"
+#endif
+	       ") = -1 ENOENT (%m)\n",
+	       Q_FILENAME, q_argv[0], q_argv[1], q_argv[2]
+#ifdef VERBOSE_EXECVE
+	       , q_envp[0], q_envp[1]
+#endif
+	       );
+
+	execve(FILENAME, tail_argv + 2, tail_envp + 1);
+	printf("execve(\"%s\", [\"%s\"]"
+#ifdef VERBOSE_EXECVE
+	       ", [\"%s\"]"
+#else
+	       ", [/* 1 var */]"
+#endif
+	       ") = -1 ENOENT (%m)\n",
+	       Q_FILENAME, q_argv[2]
+#ifdef VERBOSE_EXECVE
+	       , q_envp[1]
+#endif
+	       );
+
+	char **const empty = tail_alloc(sizeof(*empty));
+	char **const efault = empty + 1;
+	*empty = NULL;
+
+	execve(FILENAME, empty, empty);
+	printf("execve(\"%s\", []"
+#ifdef VERBOSE_EXECVE
+	       ", []"
+#else
+	       ", [/* 0 vars */]"
+#endif
+	       ") = -1 ENOENT (%m)\n", Q_FILENAME);
+
+	char str_a[] = "012345678901234567890123456789012";
+	char str_b[] = "_abcdefghijklmnopqrstuvwxyz()[]{}";
+#define DEFAULT_STRLEN ((unsigned int) sizeof(str_a) - 2)
+	char **const a = tail_alloc(sizeof(*a) * (DEFAULT_STRLEN + 2));
+	char **const b = tail_alloc(sizeof(*b) * (DEFAULT_STRLEN + 2));
+	unsigned int i;
+	for (i = 0; i <= DEFAULT_STRLEN; ++i) {
+		a[i] = &str_a[i];
+		b[i] = &str_b[i];
+	}
+	a[i] = b[i] = NULL;
+
+	execve(FILENAME, a, b);
+	printf("execve(\"%s\", [\"%.*s\"...", Q_FILENAME, DEFAULT_STRLEN, a[0]);
+	for (i = 1; i < DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", a[i]);
+#ifdef VERBOSE_EXECVE
+	printf(", \"%s\"", a[i]);
+#else
+	printf(", ...");
+#endif
+#ifdef VERBOSE_EXECVE
+	printf("], [\"%.*s\"...", DEFAULT_STRLEN, b[0]);
+	for (i = 1; i <= DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", b[i]);
+#else
+	printf("], [/* %u vars */", DEFAULT_STRLEN + 1);
+#endif
+	printf("]) = -1 ENOENT (%m)\n");
+
+	execve(FILENAME, a + 1, b + 1);
+	printf("execve(\"%s\", [\"%s\"", Q_FILENAME, a[1]);
+	for (i = 2; i <= DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", a[i]);
+#ifdef VERBOSE_EXECVE
+	printf("], [\"%s\"", b[1]);
+	for (i = 2; i <= DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", b[i]);
+#else
+	printf("], [/* %d vars */", DEFAULT_STRLEN);
+#endif
+	printf("]) = -1 ENOENT (%m)\n");
+
+	execve(FILENAME, (char **) tail_argv[ARRAY_SIZE(q_argv)], efault);
+	printf("execve(\"%s\", NULL, %p) = -1 ENOENT (%m)\n",
+	       Q_FILENAME, efault);
+
+	execve(FILENAME, efault, NULL);
+	printf("execve(\"%s\", %p, NULL) = -1 ENOENT (%m)\n",
+	       Q_FILENAME, efault);
+
+	return 0;
+}
diff --git a/strace/tests/execve.test b/strace/tests/execve.test
new file mode 100755
index 0000000..263b6fc
--- /dev/null
+++ b/strace/tests/execve.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check execve syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog > /dev/null
+run_strace -eexecve $args > "$EXP"
+
+# Filter out execve() call made by strace.
+grep -F test.execve < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/execveat-v.c b/strace/tests/execveat-v.c
new file mode 100644
index 0000000..530ddfc
--- /dev/null
+++ b/strace/tests/execveat-v.c
@@ -0,0 +1,3 @@
+/* This file is part of execveat-v strace test. */
+#define VERBOSE_EXECVEAT
+#include "execveat.c"
diff --git a/strace/tests/execveat-v.test b/strace/tests/execveat-v.test
new file mode 100755
index 0000000..a905224
--- /dev/null
+++ b/strace/tests/execveat-v.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check verbose decoding of execveat syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -e trace=execveat
diff --git a/strace/tests/execveat.c b/strace/tests/execveat.c
new file mode 100644
index 0000000..972fc17
--- /dev/null
+++ b/strace/tests/execveat.c
@@ -0,0 +1,186 @@
+/*
+ * This file is part of execveat strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+#ifdef __NR_execveat
+
+# define FILENAME "test.execveat\nfilename"
+# define Q_FILENAME "test.execveat\\nfilename"
+
+static const char * const argv[] = {
+	FILENAME, "first", "second", (const char *) -1L,
+	(const char *) -2L, (const char *) -3L
+};
+static const char * const q_argv[] = {
+	Q_FILENAME, "first", "second"
+};
+
+static const char * const envp[] = {
+	"foobar=1", "foo\nbar=2", (const char *) -1L,
+	(const char *) -2L, (const char *) -3L
+};
+static const char * const q_envp[] = {
+	"foobar=1", "foo\\nbar=2"
+};
+
+int
+main(void)
+{
+	const char ** const tail_argv = tail_memdup(argv, sizeof(argv));
+	const char ** const tail_envp = tail_memdup(envp, sizeof(envp));
+
+	syscall(__NR_execveat, -100, FILENAME, tail_argv, tail_envp, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\""
+	       ", [\"%s\", \"%s\", \"%s\", %p, %p, %p, ???]"
+#ifdef VERBOSE_EXECVEAT
+	       ", [\"%s\", \"%s\", %p, %p, %p, ???]"
+#else
+	       ", [/* 5 vars, unterminated */]"
+#endif
+	       ", AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       Q_FILENAME, q_argv[0], q_argv[1], q_argv[2],
+	       argv[3], argv[4], argv[5],
+#ifdef VERBOSE_EXECVEAT
+	       q_envp[0], q_envp[1], envp[2], envp[3], envp[4],
+#endif
+	       errno2name());
+
+	tail_argv[ARRAY_SIZE(q_argv)] = NULL;
+	tail_envp[ARRAY_SIZE(q_envp)] = NULL;
+
+	syscall(__NR_execveat, -100, FILENAME, tail_argv, tail_envp, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", [\"%s\", \"%s\", \"%s\"]"
+#ifdef VERBOSE_EXECVEAT
+	       ", [\"%s\", \"%s\"]"
+#else
+	       ", [/* 2 vars */]"
+#endif
+	       ", AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       Q_FILENAME, q_argv[0], q_argv[1], q_argv[2],
+#ifdef VERBOSE_EXECVEAT
+	       q_envp[0], q_envp[1],
+#endif
+	       errno2name());
+
+	syscall(__NR_execveat, -100, FILENAME, tail_argv + 2, tail_envp + 1, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", [\"%s\"]"
+#ifdef VERBOSE_EXECVEAT
+	       ", [\"%s\"]"
+#else
+	       ", [/* 1 var */]"
+#endif
+	       ", AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       Q_FILENAME, q_argv[2],
+#ifdef VERBOSE_EXECVEAT
+	       q_envp[1],
+#endif
+	       errno2name());
+
+	char **const empty = tail_alloc(sizeof(*empty));
+	char **const efault = empty + 1;
+	*empty = NULL;
+
+	syscall(__NR_execveat, -100, FILENAME, empty, empty, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", []"
+#ifdef VERBOSE_EXECVEAT
+	       ", []"
+#else
+	       ", [/* 0 vars */]"
+#endif
+	       ", AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       Q_FILENAME, errno2name());
+
+	char str_a[] = "012345678901234567890123456789012";
+	char str_b[] = "_abcdefghijklmnopqrstuvwxyz()[]{}";
+#define DEFAULT_STRLEN ((unsigned int) sizeof(str_a) - 2)
+	char **const a = tail_alloc(sizeof(*a) * (DEFAULT_STRLEN + 2));
+	char **const b = tail_alloc(sizeof(*b) * (DEFAULT_STRLEN + 2));
+	unsigned int i;
+	for (i = 0; i <= DEFAULT_STRLEN; ++i) {
+		a[i] = &str_a[i];
+		b[i] = &str_b[i];
+	}
+	a[i] = b[i] = NULL;
+
+	syscall(__NR_execveat, -100, FILENAME, a, b, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", [\"%.*s\"...", Q_FILENAME, DEFAULT_STRLEN, a[0]);
+	for (i = 1; i < DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", a[i]);
+#ifdef VERBOSE_EXECVEAT
+	printf(", \"%s\"", a[i]);
+#else
+	printf(", ...");
+#endif
+#ifdef VERBOSE_EXECVEAT
+	printf("], [\"%.*s\"...", DEFAULT_STRLEN, b[0]);
+	for (i = 1; i <= DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", b[i]);
+#else
+	printf("], [/* %u vars */", DEFAULT_STRLEN + 1);
+#endif
+	printf("], AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       errno2name());
+
+	syscall(__NR_execveat, -100, FILENAME, a + 1, b + 1, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", [\"%s\"", Q_FILENAME, a[1]);
+	for (i = 2; i <= DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", a[i]);
+#ifdef VERBOSE_EXECVEAT
+	printf("], [\"%s\"", b[1]);
+	for (i = 2; i <= DEFAULT_STRLEN; ++i)
+		printf(", \"%s\"", b[i]);
+#else
+	printf("], [/* %d vars */", DEFAULT_STRLEN);
+#endif
+	printf("], AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       errno2name());
+
+	syscall(__NR_execveat, -100, FILENAME, NULL, efault, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", NULL, %p"
+	       ", AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       Q_FILENAME, efault, errno2name());
+
+	syscall(__NR_execveat, -100, FILENAME, efault, NULL, 0x1100);
+	printf("execveat(AT_FDCWD, \"%s\", %p, NULL"
+	       ", AT_SYMLINK_NOFOLLOW|AT_EMPTY_PATH) = -1 %s (%m)\n",
+	       Q_FILENAME, efault, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_execveat")
+
+#endif
diff --git a/strace/tests/execveat.test b/strace/tests/execveat.test
new file mode 100755
index 0000000..879e03e
--- /dev/null
+++ b/strace/tests/execveat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check execveat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/faccessat.c b/strace/tests/faccessat.c
new file mode 100644
index 0000000..06a6ae3
--- /dev/null
+++ b/strace/tests/faccessat.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_faccessat
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "faccessat.sample";
+	const long int fd = (long int) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_faccessat, fd, sample, F_OK);
+	printf("faccessat(%d, \"%s\", F_OK) = %ld %s (%m)\n",
+	       (int) fd, sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_faccessat")
+
+#endif
diff --git a/strace/tests/faccessat.test b/strace/tests/faccessat.test
new file mode 100755
index 0000000..61e7e2f
--- /dev/null
+++ b/strace/tests/faccessat.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check faccessat syscall decoding.
+
+. "${srcdir=.}/openat.test"
diff --git a/strace/tests/fanotify_mark.c b/strace/tests/fanotify_mark.c
new file mode 100644
index 0000000..e467bf0
--- /dev/null
+++ b/strace/tests/fanotify_mark.c
@@ -0,0 +1,18 @@
+#include "tests.h"
+
+#if defined HAVE_SYS_FANOTIFY_H && defined HAVE_FANOTIFY_MARK
+
+# include <sys/fanotify.h>
+
+int
+main(void)
+{
+	fanotify_mark(-1, FAN_MARK_ADD, FAN_MODIFY | FAN_ONDIR, -100, ".");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_SYS_FANOTIFY_H && HAVE_FANOTIFY_MARK")
+
+#endif
diff --git a/strace/tests/fanotify_mark.expected b/strace/tests/fanotify_mark.expected
new file mode 100644
index 0000000..d2bb336
--- /dev/null
+++ b/strace/tests/fanotify_mark.expected
@@ -0,0 +1 @@
+fanotify_mark\(-1, FAN_MARK_ADD, FAN_MODIFY\|FAN_ONDIR, AT_FDCWD, "\."\) += -1.*
diff --git a/strace/tests/fanotify_mark.test b/strace/tests/fanotify_mark.test
new file mode 100755
index 0000000..4b7749a
--- /dev/null
+++ b/strace/tests/fanotify_mark.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check fanotify_mark syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -efanotify_mark $args
+match_grep
+
+exit 0
diff --git a/strace/tests/fchdir.c b/strace/tests/fchdir.c
new file mode 100644
index 0000000..7306d4d
--- /dev/null
+++ b/strace/tests/fchdir.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fchdir
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd = (long int) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_fchdir, fd);
+	printf("fchdir(%d) = %ld %s (%m)\n",
+	       (int) fd, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fchdir")
+
+#endif
diff --git a/strace/tests/fchdir.test b/strace/tests/fchdir.test
new file mode 100755
index 0000000..3a4296e
--- /dev/null
+++ b/strace/tests/fchdir.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fchdir syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a11
diff --git a/strace/tests/fchmod.c b/strace/tests/fchmod.c
new file mode 100644
index 0000000..57fefa1
--- /dev/null
+++ b/strace/tests/fchmod.c
@@ -0,0 +1,69 @@
+/*
+ * Copyright (c) 2016 Fabien Siron <fabien.siron@epita.fr>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_fchmod
+
+#include <fcntl.h>
+#include <sys/stat.h>
+#include <stdio.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	static const char fname[] = "fchmod_test_file";
+
+	int fd = open(fname, O_CREAT|O_RDONLY, 0400);
+
+	if (fd == -1)
+		perror_msg_and_fail("open");
+
+	if (unlink(fname) == -1)
+		perror_msg_and_fail("unlink");
+
+	if (syscall(__NR_fchmod, fd, 0600) == 0) {
+		close(fd);
+
+		printf("fchmod(%d, 0600) = 0\n", fd);
+
+		if (syscall(__NR_fchmod, fd, 0600) != -1)
+			perror_msg_and_fail("fchmod");
+	}
+	printf("fchmod(%d, 0600) = -1 %s (%m)\n", fd, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fchmod")
+
+#endif
diff --git a/strace/tests/fchmod.test b/strace/tests/fchmod.test
new file mode 100755
index 0000000..32ad456
--- /dev/null
+++ b/strace/tests/fchmod.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fchmod syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a16
diff --git a/strace/tests/fchmodat.c b/strace/tests/fchmodat.c
new file mode 100644
index 0000000..2ae613e
--- /dev/null
+++ b/strace/tests/fchmodat.c
@@ -0,0 +1,68 @@
+/*
+ * Check decoding of fchmodat syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fchmodat
+
+# include <fcntl.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "fchmodat_sample";
+
+	if (open(sample, O_RDONLY | O_CREAT, 0400) == -1)
+		perror_msg_and_fail("open");
+
+	if (syscall(__NR_fchmodat, -100, sample, 0600) == 0) {
+		printf("fchmodat(AT_FDCWD, \"%s\", 0600) = 0\n", sample);
+
+		if (unlink(sample))
+			perror_msg_and_fail("unlink");
+
+		if (syscall(__NR_fchmodat, -100, sample, 0600) != -1)
+			perror_msg_and_fail("fchmodat");
+	}
+
+	printf("fchmodat(AT_FDCWD, \"%s\", 0600) = -1 %s (%m)\n",
+	       sample, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fchmodat")
+
+#endif
diff --git a/strace/tests/fchmodat.test b/strace/tests/fchmodat.test
new file mode 100755
index 0000000..13cbe80
--- /dev/null
+++ b/strace/tests/fchmodat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of fchmodat syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/fchown.c b/strace/tests/fchown.c
new file mode 100644
index 0000000..53a522e
--- /dev/null
+++ b/strace/tests/fchown.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fchown
+
+# define SYSCALL_NR __NR_fchown
+# define SYSCALL_NAME "fchown"
+# define ACCESS_BY_DESCRIPTOR
+
+# if defined __NR_fchown32 && __NR_fchown != __NR_fchown32
+#  define UGID_TYPE_IS_SHORT
+# endif
+
+# include "xchownx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fchown")
+
+#endif
diff --git a/strace/tests/fchown.test b/strace/tests/fchown.test
new file mode 100755
index 0000000..63a0f2e
--- /dev/null
+++ b/strace/tests/fchown.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fchown syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a16
diff --git a/strace/tests/fchown32.c b/strace/tests/fchown32.c
new file mode 100644
index 0000000..0927b56
--- /dev/null
+++ b/strace/tests/fchown32.c
@@ -0,0 +1,15 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fchown32
+
+# define SYSCALL_NR __NR_fchown32
+# define SYSCALL_NAME "fchown32"
+# define ACCESS_BY_DESCRIPTOR
+# include "xchownx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fchown32")
+
+#endif
diff --git a/strace/tests/fchown32.test b/strace/tests/fchown32.test
new file mode 100755
index 0000000..e837f54
--- /dev/null
+++ b/strace/tests/fchown32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fchown32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a18
diff --git a/strace/tests/fchownat.c b/strace/tests/fchownat.c
new file mode 100644
index 0000000..9a0ecc8
--- /dev/null
+++ b/strace/tests/fchownat.c
@@ -0,0 +1,75 @@
+/*
+ * Check decoding of fchownat syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+#include <fcntl.h>
+
+#if defined __NR_fchownat && defined AT_FDCWD && defined AT_SYMLINK_NOFOLLOW
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "fchownat_sample";
+	uid_t uid = geteuid();
+	uid_t gid = getegid();
+
+	if (open(sample, O_RDONLY | O_CREAT, 0400) == -1)
+		perror_msg_and_fail("open");
+
+	long rc = syscall(__NR_fchownat, AT_FDCWD, sample, uid, gid, 0);
+	if (rc == 0) {
+		printf("fchownat(AT_FDCWD, \"%s\", %d, %d, 0) = 0\n",
+		       sample, uid, gid);
+
+		if (unlink(sample))
+			perror_msg_and_fail("unlink");
+
+		rc = syscall(__NR_fchownat, AT_FDCWD,
+			     sample, -1, -1L, AT_SYMLINK_NOFOLLOW);
+
+		printf("fchownat(AT_FDCWD, \"%s\", -1, -1, AT_SYMLINK_NOFOLLOW)"
+		       " = %ld %s (%m)\n", sample, rc, errno2name());
+	} else {
+		printf("fchownat(AT_FDCWD, \"%s\", %d, %d, 0)"
+		       " = %ld %s (%m)\n", sample, uid, gid, rc, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fchownat && AT_FDCWD && AT_SYMLINK_NOFOLLOW")
+
+#endif
diff --git a/strace/tests/fchownat.test b/strace/tests/fchownat.test
new file mode 100755
index 0000000..e5d0f28
--- /dev/null
+++ b/strace/tests/fchownat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of fchownat syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/fcntl.c b/strace/tests/fcntl.c
new file mode 100644
index 0000000..1ea83e1
--- /dev/null
+++ b/strace/tests/fcntl.c
@@ -0,0 +1,83 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fcntl
+
+# define TEST_SYSCALL_NR __NR_fcntl
+# define TEST_SYSCALL_STR "fcntl"
+# include "struct_flock.c"
+
+# define TEST_FLOCK64_EINVAL(cmd) test_flock64_einval(cmd, #cmd)
+
+static void
+test_flock64_einval(const int cmd, const char *name)
+{
+	struct_kernel_flock64 fl = {
+		.l_type = F_RDLCK,
+		.l_start = 0xdefaced1facefeed,
+		.l_len = 0xdefaced2cafef00d
+	};
+	invoke_test_syscall(cmd, &fl);
+	printf("%s(0, %s, %p) = %s\n",
+	       TEST_SYSCALL_STR, name, &fl, EINVAL_STR);
+}
+
+static void
+test_flock64(void)
+{
+/*
+ * F_[GS]ETOWN_EX had conflicting values with F_[GS]ETLK64
+ * in kernel revisions v2.6.32-rc1~96..v2.6.32-rc7~23.
+ */
+#if !defined(F_GETOWN_EX) || F_GETOWN_EX != F_SETLK64
+	TEST_FLOCK64_EINVAL(F_SETLK64);
+#endif
+	TEST_FLOCK64_EINVAL(F_SETLKW64);
+#if !defined(F_SETOWN_EX) || F_SETOWN_EX != F_GETLK64
+	TEST_FLOCK64_EINVAL(F_GETLK64);
+#endif
+}
+
+int
+main(void)
+{
+	create_sample();
+	test_flock();
+	test_flock64();
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fcntl")
+
+#endif
diff --git a/strace/tests/fcntl.test b/strace/tests/fcntl.test
new file mode 100755
index 0000000..9aea122
--- /dev/null
+++ b/strace/tests/fcntl.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fcntl decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a8
diff --git a/strace/tests/fcntl64.c b/strace/tests/fcntl64.c
new file mode 100644
index 0000000..b83a098
--- /dev/null
+++ b/strace/tests/fcntl64.c
@@ -0,0 +1,101 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fcntl64
+
+# define TEST_SYSCALL_NR __NR_fcntl64
+# define TEST_SYSCALL_STR "fcntl64"
+# include "struct_flock.c"
+
+# define TEST_FLOCK64_EINVAL(cmd) test_flock64_einval(cmd, #cmd)
+
+static void
+test_flock64_einval(const int cmd, const char *name)
+{
+	struct_kernel_flock64 fl = {
+		.l_type = F_RDLCK,
+		.l_start = 0xdefaced1facefeed,
+		.l_len = 0xdefaced2cafef00d
+	};
+	invoke_test_syscall(cmd, &fl);
+	printf("%s(0, %s, {l_type=F_RDLCK, l_whence=SEEK_SET"
+	       ", l_start=%jd, l_len=%jd}) = %s\n", TEST_SYSCALL_STR, name,
+	       (intmax_t) fl.l_start, (intmax_t) fl.l_len, EINVAL_STR);
+}
+
+static void
+test_flock64(void)
+{
+	TEST_FLOCK64_EINVAL(F_SETLK64);
+	TEST_FLOCK64_EINVAL(F_SETLKW64);
+# ifdef F_OFD_SETLK
+	TEST_FLOCK64_EINVAL(F_OFD_SETLK);
+	TEST_FLOCK64_EINVAL(F_OFD_SETLKW);
+# endif
+
+	struct_kernel_flock64 fl = {
+		.l_type = F_RDLCK,
+		.l_len = FILE_LEN
+	};
+	long rc = invoke_test_syscall(F_SETLK64, &fl);
+	printf("%s(0, F_SETLK64, {l_type=F_RDLCK, l_whence=SEEK_SET"
+	       ", l_start=0, l_len=%d}) = %s\n",
+	       TEST_SYSCALL_STR, FILE_LEN, rc ? EINVAL_STR : "0");
+
+	if (rc)
+		return;
+
+	invoke_test_syscall(F_GETLK64, &fl);
+	printf("%s(0, F_GETLK64, {l_type=F_UNLCK, l_whence=SEEK_SET"
+	       ", l_start=0, l_len=%d, l_pid=0}) = 0\n",
+	       TEST_SYSCALL_STR, FILE_LEN);
+
+	invoke_test_syscall(F_SETLK64, &fl);
+	printf("%s(0, F_SETLK64, {l_type=F_UNLCK, l_whence=SEEK_SET"
+	       ", l_start=0, l_len=%d}) = 0\n",
+	       TEST_SYSCALL_STR, FILE_LEN);
+}
+
+int
+main(void)
+{
+	create_sample();
+	test_flock();
+	test_flock64();
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fcntl64")
+
+#endif
diff --git a/strace/tests/fcntl64.test b/strace/tests/fcntl64.test
new file mode 100755
index 0000000..00ba671
--- /dev/null
+++ b/strace/tests/fcntl64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check fcntl64 syscall decoding.
+
+. "${srcdir=.}/fcntl.test"
diff --git a/strace/tests/fdatasync.c b/strace/tests/fdatasync.c
new file mode 100644
index 0000000..86f1cfa
--- /dev/null
+++ b/strace/tests/fdatasync.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fdatasync
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd = (long int) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_fdatasync, fd);
+	printf("fdatasync(%d) = %ld %s (%m)\n", (int) fd, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fdatasync")
+
+#endif
diff --git a/strace/tests/fdatasync.test b/strace/tests/fdatasync.test
new file mode 100755
index 0000000..ff59749
--- /dev/null
+++ b/strace/tests/fdatasync.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fdatasync syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a14
diff --git a/strace/tests/file_handle.c b/strace/tests/file_handle.c
new file mode 100644
index 0000000..ac2b358
--- /dev/null
+++ b/strace/tests/file_handle.c
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+
+#ifdef MAX_HANDLE_SZ
+
+# include <alloca.h>
+# include <assert.h>
+# include <errno.h>
+# include <stdio.h>
+
+int
+main(void)
+{
+	struct file_handle *handle =
+		alloca(sizeof(struct file_handle) + MAX_HANDLE_SZ);
+	const int dirfd = AT_FDCWD;
+	const int flags = AT_SYMLINK_FOLLOW;
+	int mount_id;
+	unsigned int i;
+
+	handle->handle_bytes = 0;
+
+	assert(name_to_handle_at(dirfd, ".", handle, &mount_id, flags | 1) == -1);
+	if (EINVAL != errno)
+		perror_msg_and_skip("name_to_handle_at");
+	printf("name_to_handle_at(AT_FDCWD, \".\", {handle_bytes=0}, %p"
+	       ", AT_SYMLINK_FOLLOW|0x1) = -1 EINVAL (%m)\n", &mount_id);
+
+	assert(name_to_handle_at(dirfd, ".", handle, &mount_id, flags) == -1);
+	if (EOVERFLOW != errno)
+		perror_msg_and_skip("name_to_handle_at");
+	printf("name_to_handle_at(AT_FDCWD, \".\", {handle_bytes=0 => %u}"
+	       ", %p, AT_SYMLINK_FOLLOW) = -1 EOVERFLOW (%m)\n",
+	       handle->handle_bytes, &mount_id);
+
+	assert(name_to_handle_at(dirfd, ".", handle, &mount_id, flags) == 0);
+	printf("name_to_handle_at(AT_FDCWD, \".\", {handle_bytes=%u"
+	       ", handle_type=%d, f_handle=0x",
+	       handle->handle_bytes, handle->handle_type);
+	for (i = 0; i < handle->handle_bytes; ++i)
+		printf("%02x", handle->f_handle[i]);
+	printf("}, [%d], AT_SYMLINK_FOLLOW) = 0\n", mount_id);
+
+	printf("open_by_handle_at(-1, {handle_bytes=%u, handle_type=%d"
+	       ", f_handle=0x", handle->handle_bytes, handle->handle_type);
+	for (i = 0; i < handle->handle_bytes; ++i)
+		printf("%02x", handle->f_handle[i]);
+	int rc = open_by_handle_at(-1, handle, O_RDONLY | O_DIRECTORY);
+	printf("}, O_RDONLY|O_DIRECTORY) = %d %s (%m)\n", rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("MAX_HANDLE_SZ")
+
+#endif
diff --git a/strace/tests/file_handle.test b/strace/tests/file_handle.test
new file mode 100755
index 0000000..1ccc9d4
--- /dev/null
+++ b/strace/tests/file_handle.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check name_to_handle_at and open_by_handle_at syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=name_to_handle_at,open_by_handle_at
diff --git a/strace/tests/file_ioctl.c b/strace/tests/file_ioctl.c
new file mode 100644
index 0000000..0fe17b1
--- /dev/null
+++ b/strace/tests/file_ioctl.c
@@ -0,0 +1,45 @@
+#include "tests.h"
+
+#ifdef HAVE_LINUX_FIEMAP_H
+
+# include <stdio.h>
+# include <sys/ioctl.h>
+# include <linux/fiemap.h>
+# include <linux/fs.h>
+# include "xlat.h"
+# include "xlat/fiemap_flags.h"
+
+static void
+test_fiemap(void)
+{
+	(void) tail_alloc(1);
+	struct fiemap *const args = tail_alloc(sizeof(*args));
+
+	printf("ioctl(-1, FS_IOC_FIEMAP, {fm_start=%" PRI__u64
+	       ", fm_length=%" PRI__u64", fm_flags=",
+	       args->fm_start, args->fm_length);
+	printflags(fiemap_flags, args->fm_flags, "FIEMAP_FLAG_???");
+	printf(", fm_extent_count=%u})", args->fm_extent_count);
+	ioctl(-1, FS_IOC_FIEMAP, args);
+	printf(" = -1 EBADF (%m)\n");
+
+	/* The live version of this test is in btrfs.c */
+}
+
+/* clone and dedupe ioctls are in btrfs.c since they originated there */
+
+int
+main(int argc, char *argv[])
+{
+	test_fiemap();
+
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_LINUX_FIEMAP_H")
+
+#endif
diff --git a/strace/tests/file_ioctl.test b/strace/tests/file_ioctl.test
new file mode 100755
index 0000000..7b8b8ce
--- /dev/null
+++ b/strace/tests/file_ioctl.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check FS_IOC_FIEMAP ioctl decoding.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/filter-unavailable.c b/strace/tests/filter-unavailable.c
new file mode 100644
index 0000000..6368b2c
--- /dev/null
+++ b/strace/tests/filter-unavailable.c
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include <pthread.h>
+#include <sys/wait.h>
+
+#define P 16
+#define T 7
+
+static void *
+thread(void *arg)
+{
+	assert(write(1, "", 1) == 1);
+	pause();
+	return arg;
+}
+
+static int
+process(void)
+{
+	int i;
+	int fds[2];
+	pthread_t t;
+	struct timespec ts = { .tv_nsec = 10000000 };
+
+	(void) close(0);
+	(void) close(1);
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	for (i = 0; i < T; ++i)
+		assert(pthread_create(&t, NULL, thread, NULL) == 0);
+	for (i = 0; i < T; ++i)
+		assert(read(0, fds, 1) == 1);
+
+	(void) nanosleep(&ts, 0);
+	return 0;
+}
+
+int
+main(void)
+{
+	int i, s;
+	pid_t p;
+
+	for (i = 0; i < P; ++i) {
+		p = fork();
+		if (p < 0)
+			perror_msg_and_fail("fork");
+		if (p == 0)
+			return process();
+		assert(waitpid(p, &s, 0) == p);
+		assert(WIFEXITED(s));
+		if (WEXITSTATUS(s))
+			return WEXITSTATUS(s);
+	}
+	return 0;
+}
diff --git a/strace/tests/filter-unavailable.expected b/strace/tests/filter-unavailable.expected
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/strace/tests/filter-unavailable.expected
diff --git a/strace/tests/filter-unavailable.test b/strace/tests/filter-unavailable.test
new file mode 100755
index 0000000..15a9ad1
--- /dev/null
+++ b/strace/tests/filter-unavailable.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# check that <unavailable> syscalls are filtered properly
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -qq -f -echdir -esignal=none $args
+match_diff
+
+exit 0
diff --git a/strace/tests/flock.c b/strace/tests/flock.c
new file mode 100644
index 0000000..d6e2008
--- /dev/null
+++ b/strace/tests/flock.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_flock
+
+# include <stdio.h>
+# include <sys/file.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const unsigned long fd = (long int) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_flock, fd, LOCK_SH);
+	printf("flock(%d, LOCK_SH) = %ld %s (%m)\n",
+	       (int) fd, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_flock")
+
+#endif
diff --git a/strace/tests/flock.test b/strace/tests/flock.test
new file mode 100755
index 0000000..24fcd74
--- /dev/null
+++ b/strace/tests/flock.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check flock syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a19
diff --git a/strace/tests/fork-f.c b/strace/tests/fork-f.c
new file mode 100644
index 0000000..11ac3d9
--- /dev/null
+++ b/strace/tests/fork-f.c
@@ -0,0 +1,97 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/wait.h>
+
+static inline int
+logit_(const char *const str)
+{
+	return !chdir(str);
+}
+
+#define prefix "fork-f."
+#define logit(arg) logit_(prefix arg)
+
+int main(int ac, char **av)
+{
+	if (ac < 1)
+		return 1;
+	if (ac > 1)
+		return logit("exec");
+
+	logit("start");
+
+	int child_wait_fds[2];
+	(void) close(0);
+	if (pipe(child_wait_fds))
+		perror_msg_and_fail("pipe");
+
+	pid_t pid = fork();
+
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		close(child_wait_fds[1]);
+
+		if (read(0, child_wait_fds, sizeof(int)))
+			_exit(2);
+
+		char *const args[] = { av[0], (char *) "", NULL };
+		if (logit("child") || execve(args[0], args, args + 1))
+			_exit(2);
+	}
+
+	close(0);
+
+	logit("parent");
+	close(child_wait_fds[1]);
+
+	int status;
+	assert(wait(&status) == pid);
+	assert(status == 0);
+
+	pid_t ppid = getpid();
+	logit("finish");
+
+	printf("%-5d chdir(\"%sstart\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%sparent\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%schild\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%sexec\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%sfinish\") = -1 ENOENT (%m)\n",
+	       ppid, prefix,
+	       ppid, prefix,
+	       pid, prefix,
+	       pid, prefix,
+	       ppid, prefix);
+	return 0;
+}
diff --git a/strace/tests/fork-f.test b/strace/tests/fork-f.test
new file mode 100755
index 0000000..d8ca1e3
--- /dev/null
+++ b/strace/tests/fork-f.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check how strace -f follows fork syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a26 -qq -f -e trace=chdir -e signal=none
diff --git a/strace/tests/fstat.c b/strace/tests/fstat.c
new file mode 100644
index 0000000..0206c9f
--- /dev/null
+++ b/strace/tests/fstat.c
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fstat
+
+# define TEST_SYSCALL_NR __NR_fstat
+# define TEST_SYSCALL_STR "fstat"
+# define SAMPLE_SIZE ((kernel_ulong_t) 43147718418)
+# include "fstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fstat")
+
+#endif
diff --git a/strace/tests/fstat.test b/strace/tests/fstat.test
new file mode 100755
index 0000000..506b440
--- /dev/null
+++ b/strace/tests/fstat.test
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+# Check fstat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+# strace -P is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+syscall=$NAME
+run_prog > /dev/null
+sample=$syscall.sample
+> "$sample"
+run_strace -ve$syscall -P$sample $args > "$OUT"
+match_diff "$LOG" "$OUT"
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/fstat64.c b/strace/tests/fstat64.c
new file mode 100644
index 0000000..59c94a2
--- /dev/null
+++ b/strace/tests/fstat64.c
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fstat64
+
+# define TEST_SYSCALL_NR __NR_fstat64
+# define TEST_SYSCALL_STR "fstat64"
+# define STRUCT_STAT struct stat64
+# define STRUCT_STAT_STR "struct stat64"
+# define SAMPLE_SIZE ((libc_off_t) 43147718418)
+# include "fstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fstat64")
+
+#endif
diff --git a/strace/tests/fstat64.test b/strace/tests/fstat64.test
new file mode 100755
index 0000000..8b4f5ef
--- /dev/null
+++ b/strace/tests/fstat64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check fstat64 syscall decoding.
+
+. "${srcdir=.}/fstat.test"
diff --git a/strace/tests/fstatat.c b/strace/tests/fstatat.c
new file mode 100644
index 0000000..ff47601
--- /dev/null
+++ b/strace/tests/fstatat.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifdef HAVE_FSTATAT
+
+# define TEST_SYSCALL_INVOKE(sample, pst) \
+	fstatat(AT_FDCWD, sample, pst, AT_SYMLINK_NOFOLLOW)
+# define PRINT_SYSCALL_HEADER(sample) \
+	printf("%s(AT_FDCWD, \"%s\", ", TEST_SYSCALL_STR, sample)
+# define PRINT_SYSCALL_FOOTER \
+	puts(", AT_SYMLINK_NOFOLLOW) = 0")
+
+# include "xstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_FSTATAT")
+
+#endif
diff --git a/strace/tests/fstatat64.c b/strace/tests/fstatat64.c
new file mode 100644
index 0000000..1bf95c1
--- /dev/null
+++ b/strace/tests/fstatat64.c
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fstatat64
+
+# define TEST_SYSCALL_NR __NR_fstatat64
+# define TEST_SYSCALL_STR "fstatat64"
+# include "fstatat.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fstatat64")
+
+#endif
diff --git a/strace/tests/fstatat64.test b/strace/tests/fstatat64.test
new file mode 100755
index 0000000..484008a
--- /dev/null
+++ b/strace/tests/fstatat64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check fstatat64 syscall decoding.
+
+. "${srcdir=.}/statx.sh"
diff --git a/strace/tests/fstatfs.c b/strace/tests/fstatfs.c
new file mode 100644
index 0000000..7ff39dc
--- /dev/null
+++ b/strace/tests/fstatfs.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fstatfs
+
+# define SYSCALL_ARG_FMT		"%d"
+# define SYSCALL_ARG(file, desc)	(desc)
+# define SYSCALL_NR			__NR_fstatfs
+# define SYSCALL_NAME			"fstatfs"
+# include "xstatfs.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fstatfs")
+
+#endif
diff --git a/strace/tests/fstatfs.test b/strace/tests/fstatfs.test
new file mode 100755
index 0000000..646e66f
--- /dev/null
+++ b/strace/tests/fstatfs.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check fstatfs syscall decoding.
+
+. "${srcdir=.}/statfs.test"
diff --git a/strace/tests/fstatfs64.c b/strace/tests/fstatfs64.c
new file mode 100644
index 0000000..6c59974
--- /dev/null
+++ b/strace/tests/fstatfs64.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fstatfs64
+
+# define SYSCALL_ARG_FMT		"%d"
+# define SYSCALL_ARG(file, desc)	(desc)
+# define SYSCALL_NR			__NR_fstatfs64
+# define SYSCALL_NAME			"fstatfs64"
+# include "xstatfs64.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fstatfs64")
+
+#endif
diff --git a/strace/tests/fstatfs64.test b/strace/tests/fstatfs64.test
new file mode 100755
index 0000000..179ff1b
--- /dev/null
+++ b/strace/tests/fstatfs64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check fstatfs64 syscall decoding.
+
+. "${srcdir=.}/statfs.test"
diff --git a/strace/tests/fstatx.c b/strace/tests/fstatx.c
new file mode 100644
index 0000000..890e30d
--- /dev/null
+++ b/strace/tests/fstatx.c
@@ -0,0 +1,37 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define TEST_SYSCALL_INVOKE(sample, pst) \
+	syscall(TEST_SYSCALL_NR, 0, pst)
+#define PRINT_SYSCALL_HEADER(sample) \
+	printf("%s(0, ", TEST_SYSCALL_STR)
+#define PRINT_SYSCALL_FOOTER \
+	puts(") = 0")
+
+#define USE_ASM_STAT
+
+#include "xstatx.c"
diff --git a/strace/tests/fsync.c b/strace/tests/fsync.c
new file mode 100644
index 0000000..911c167
--- /dev/null
+++ b/strace/tests/fsync.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_fsync
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd = (long int) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_fsync, fd);
+	printf("fsync(%d) = %ld %s (%m)\n", (int) fd, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_fsync")
+
+#endif
diff --git a/strace/tests/fsync.test b/strace/tests/fsync.test
new file mode 100755
index 0000000..a58b67b
--- /dev/null
+++ b/strace/tests/fsync.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check fsync syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/ftruncate.c b/strace/tests/ftruncate.c
new file mode 100644
index 0000000..db8388b
--- /dev/null
+++ b/strace/tests/ftruncate.c
@@ -0,0 +1,60 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_ftruncate
+
+# include <stdio.h>
+# include <unistd.h>
+
+# include "kernel_types.h"
+
+int
+main(void)
+{
+	const kernel_ulong_t len = (kernel_ulong_t) 0xdefaced0badc0deULL;
+	long rc;
+
+	if (sizeof(len) > sizeof(long))
+		rc = ftruncate(-1, len);
+	else
+		rc = syscall(__NR_ftruncate, -1L, len);
+
+	printf("ftruncate(-1, %llu) = %ld %s (%m)\n",
+	       (unsigned long long) len, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_ftruncate")
+
+#endif
diff --git a/strace/tests/ftruncate.test b/strace/tests/ftruncate.test
new file mode 100755
index 0000000..ec8a1e0
--- /dev/null
+++ b/strace/tests/ftruncate.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check ftruncate syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24
diff --git a/strace/tests/ftruncate64.c b/strace/tests/ftruncate64.c
new file mode 100644
index 0000000..0b13eaf
--- /dev/null
+++ b/strace/tests/ftruncate64.c
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_ftruncate64
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const off_t len = 0xdefaceddeadbeef;
+
+	int rc = ftruncate(-1, len);
+	printf("ftruncate64(-1, %llu) = %d %s (%m)\n",
+	       (unsigned long long) len, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_ftruncate64")
+
+#endif
diff --git a/strace/tests/ftruncate64.test b/strace/tests/ftruncate64.test
new file mode 100755
index 0000000..9068210
--- /dev/null
+++ b/strace/tests/ftruncate64.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check ftruncate64 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a36
diff --git a/strace/tests/futimesat.c b/strace/tests/futimesat.c
new file mode 100644
index 0000000..785c894
--- /dev/null
+++ b/strace/tests/futimesat.c
@@ -0,0 +1,86 @@
+/*
+ * Check decoding of futimesat syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_futimesat
+
+# include <stdio.h>
+# include <sys/time.h>
+# include <unistd.h>
+
+#define CAST_NUM(n)						\
+	(sizeof(n) == sizeof(long) ?				\
+		(unsigned long long) (unsigned long) (n) :	\
+		(unsigned long long) (n))
+
+int
+main(void)
+{
+	struct timeval tv;
+	if (gettimeofday(&tv, NULL))
+		perror_msg_and_fail("gettimeofday");
+
+	static const char sample[] = "futimesat_sample";
+	unsigned long dirfd = (unsigned long) 0xdeadbeef00000000 | -100U;
+
+	long rc = syscall(__NR_futimesat, dirfd, sample, 0);
+	printf("futimesat(AT_FDCWD, \"%s\", NULL) = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	struct timeval *const ts = tail_alloc(sizeof(*ts) * 2);
+	dirfd = (unsigned long) 0xdeadbeefffffffff;
+
+	rc = syscall(__NR_futimesat, dirfd, 0, ts + 1);
+	printf("futimesat(%d, NULL, %p) = %ld %s (%m)\n",
+	       (int) dirfd, ts + 1, rc, errno2name());
+
+	ts[0].tv_sec = tv.tv_sec;
+	ts[0].tv_usec = tv.tv_usec;
+	ts[1].tv_sec = tv.tv_sec - 1;
+	ts[1].tv_usec = tv.tv_usec + 1;
+
+	(void) close(0);
+	rc = syscall(__NR_futimesat, 0, "", ts);
+	printf("futimesat(0, \"\", [{%llu, %llu}, {%llu, %llu}])"
+	       " = %ld %s (%m)\n",
+	       CAST_NUM(ts[0].tv_sec), CAST_NUM(ts[0].tv_usec),
+	       CAST_NUM(ts[1].tv_sec), CAST_NUM(ts[1].tv_usec),
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_futimesat")
+
+#endif
diff --git a/strace/tests/futimesat.test b/strace/tests/futimesat.test
new file mode 100755
index 0000000..3a67c04
--- /dev/null
+++ b/strace/tests/futimesat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check futimesat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28
diff --git a/strace/tests/get_mempolicy.c b/strace/tests/get_mempolicy.c
new file mode 100644
index 0000000..6923a21
--- /dev/null
+++ b/strace/tests/get_mempolicy.c
@@ -0,0 +1,135 @@
+/*
+ * Check decoding of get_mempolicy syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_get_mempolicy
+
+# include <stdio.h>
+# include <unistd.h>
+
+# include "xlat.h"
+# include "xlat/policies.h"
+
+# define MAX_STRLEN 3
+# define NLONGS(n) ((n + 8 * sizeof(long) - 2) \
+		      / (8 * sizeof(long)))
+
+static void
+print_nodes(unsigned long maxnode)
+{
+	unsigned long *const nodemask =
+		tail_alloc(sizeof(*nodemask) * NLONGS(maxnode));
+
+	if (syscall(__NR_get_mempolicy, 0, nodemask, maxnode, 0, 0)) {
+		printf("get_mempolicy(NULL, %p, %lu, NULL, 0) = -1 %s (%m)\n",
+		       nodemask, maxnode, errno2name());
+		return;
+	}
+
+	printf("get_mempolicy(NULL, [");
+
+	unsigned int nlongs = NLONGS(maxnode);
+	unsigned int i;
+	for (i = 0; i < nlongs; ++i) {
+		if (i)
+			fputs(", ", stdout);
+		if (i >= MAX_STRLEN) {
+			fputs("...", stdout);
+			break;
+		}
+		printf("%#0*lx", (int) sizeof(*nodemask) * 2 + 2, nodemask[i]);
+	}
+
+	printf("], %lu, NULL, 0) = 0\n", maxnode);
+}
+
+int
+main(void)
+{
+	long rc;
+
+	if (syscall(__NR_get_mempolicy, 0, 0, 0, 0, 0))
+		perror_msg_and_skip("get_mempolicy");
+	puts("get_mempolicy(NULL, NULL, 0, NULL, 0) = 0");
+
+	int *mode = (void *) 0xdefaced1baddeed2;
+	unsigned long maxnode = (unsigned long) 0xcafef00dbadc0ded;
+	const unsigned long *nodemask = (void *) 0xfacedad3bebefed4;
+	const unsigned long addr = (unsigned long) 0xfacefeeddeadbeef;
+	const unsigned long flags = -1U;
+	rc = syscall(__NR_get_mempolicy, mode, nodemask, maxnode, addr, flags);
+	printf("get_mempolicy(%p, %p, %lu, %#lx, %s|%#lx) = %ld %s (%m)\n",
+	       mode, nodemask, maxnode, addr,
+	       "MPOL_F_NODE|MPOL_F_ADDR",
+	       flags & ~3, rc, errno2name());
+
+	mode = tail_alloc(sizeof(*mode));
+
+	rc = syscall(__NR_get_mempolicy, mode, 0, 0, 0, 0);
+	printf("get_mempolicy([");
+	printxval(policies, (unsigned) *mode, "MPOL_???");
+	printf("], NULL, 0, NULL, 0) = %ld\n", rc);
+
+	*mode = -1;
+	rc = syscall(__NR_get_mempolicy, mode, 0, 0, mode - 1, 2);
+	printf("get_mempolicy([");
+	printxval(policies, (unsigned) *mode, "MPOL_???");
+	printf("], NULL, 0, %p, MPOL_F_ADDR) = %ld\n", mode - 1, rc);
+
+	maxnode = get_page_size() * 8;
+
+	print_nodes(maxnode);
+	print_nodes(maxnode + 1);
+	print_nodes(maxnode + 2);
+
+	maxnode = sizeof(*nodemask) * 8;
+	print_nodes(maxnode - 1);
+	print_nodes(maxnode    );
+	print_nodes(maxnode + 1);
+	print_nodes(maxnode + 2);
+	print_nodes(maxnode * 2 - 1);
+	print_nodes(maxnode * 2    );
+	print_nodes(maxnode * 2 + 1);
+	print_nodes(maxnode * 2 + 2);
+	print_nodes(maxnode * 3 - 1);
+	print_nodes(maxnode * 3    );
+	print_nodes(maxnode * 3 + 1);
+	print_nodes(maxnode * 3 + 2);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_get_mempolicy")
+
+#endif
diff --git a/strace/tests/get_mempolicy.test b/strace/tests/get_mempolicy.test
new file mode 100755
index 0000000..9227097
--- /dev/null
+++ b/strace/tests/get_mempolicy.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check get_mempolicy syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -s3 -a38
diff --git a/strace/tests/get_page_size.c b/strace/tests/get_page_size.c
new file mode 100644
index 0000000..aeea861
--- /dev/null
+++ b/strace/tests/get_page_size.c
@@ -0,0 +1,13 @@
+#include "tests.h"
+#include <unistd.h>
+
+size_t
+get_page_size(void)
+{
+	static size_t page_size;
+
+	if (!page_size)
+		page_size = sysconf(_SC_PAGESIZE);
+
+	return page_size;
+}
diff --git a/strace/tests/getcwd.c b/strace/tests/getcwd.c
new file mode 100644
index 0000000..3135df2
--- /dev/null
+++ b/strace/tests/getcwd.c
@@ -0,0 +1,39 @@
+#include "tests.h"
+
+#include <sys/syscall.h>
+
+#ifdef __NR_getcwd
+
+# include <stdio.h>
+# include <unistd.h>
+# include <sys/param.h>
+
+int
+main(void)
+{
+	long res;
+	char cur_dir[PATH_MAX + 1];
+
+	res = syscall(__NR_getcwd, cur_dir, sizeof(cur_dir));
+
+	if (res <= 0)
+		perror_msg_and_fail("getcwd");
+
+	printf("getcwd(\"");
+	print_quoted_string(cur_dir);
+	printf("\", %zu) = %ld\n", sizeof(cur_dir), res);
+
+	syscall(__NR_getcwd, cur_dir, 0);
+
+	printf("getcwd(%p, 0) = -1 ERANGE (%m)\n", cur_dir);
+
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getcwd");
+
+#endif
diff --git a/strace/tests/getcwd.test b/strace/tests/getcwd.test
new file mode 100755
index 0000000..405187e
--- /dev/null
+++ b/strace/tests/getcwd.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getcwd syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a18
diff --git a/strace/tests/getdents.c b/strace/tests/getdents.c
new file mode 100644
index 0000000..7ea2067
--- /dev/null
+++ b/strace/tests/getdents.c
@@ -0,0 +1,143 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getdents
+
+# include <assert.h>
+# include <dirent.h>
+# include <fcntl.h>
+# include <stddef.h>
+# include <stdio.h>
+# include <sys/stat.h>
+# include <unistd.h>
+# include "kernel_types.h"
+
+static const char fname[] =
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nZ";
+static const char qname[] =
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nZ";
+
+static char buf[8192];
+
+static const char *
+str_d_type(const unsigned char d_type)
+{
+	switch (d_type) {
+		case DT_DIR:
+			return "DT_DIR";
+		case DT_REG:
+			return "DT_REG";
+		default:
+			return "DT_UNKNOWN";
+	}
+}
+static void
+print_dirent(const kernel_dirent *d)
+{
+	const unsigned int d_name_offset = offsetof(kernel_dirent, d_name);
+	int d_name_len = d->d_reclen - d_name_offset - 1;
+	assert(d_name_len > 0);
+
+	printf("{d_ino=%llu, d_off=%llu, d_reclen=%u, d_name=",
+	       (unsigned long long) d->d_ino,
+	       (unsigned long long) d->d_off, d->d_reclen);
+
+	if (d->d_name[0] == '.')
+		printf("\"%.*s\"", d_name_len, d->d_name);
+	else
+		printf("\"%s\"", qname);
+
+	printf(", d_type=%s}",
+	       str_d_type(*((const char *) d + d->d_reclen - 1)));
+}
+
+int
+main(int ac, const char **av)
+{
+	char *dname;
+
+	assert(ac == 1);
+	assert(asprintf(&dname, "%s.test.tmp.dir", av[0]) > 0);
+	assert(!mkdir(dname, 0700));
+	assert(!chdir(dname));
+	(void) close(0);
+	assert(!creat(fname, 0600));
+	assert(!close(0));
+	assert(!open(".", O_RDONLY | O_DIRECTORY));
+
+	unsigned long count = (unsigned long) 0xfacefeeddeadbeef;
+	long rc = syscall(__NR_getdents, (long) 0xdefacedffffffff, NULL, count);
+	printf("getdents(-1, NULL, %u) = %ld %s (%m)\n",
+	       (unsigned) count, rc, errno2name());
+
+	count = (unsigned long) 0xfacefeed00000000 | sizeof(buf);
+	while ((rc = syscall(__NR_getdents, 0, buf, count))) {
+		kernel_dirent *d;
+		long i;
+
+		if (rc < 0)
+			perror_msg_and_skip("getdents");
+		printf("getdents(0, [");
+		for (i = 0; i < rc; i += d->d_reclen) {
+			d = (kernel_dirent *) &buf[i];
+			if (i)
+				printf(", ");
+			print_dirent(d);
+		}
+		printf("], %u) = %ld\n", (unsigned) count, rc);
+	}
+	printf("getdents(0, [], %u) = 0\n", (unsigned) count);
+	puts("+++ exited with 0 +++");
+	assert(!unlink(fname));
+	assert(!chdir(".."));
+	assert(!rmdir(dname));
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getdents")
+
+#endif
diff --git a/strace/tests/getdents.test b/strace/tests/getdents.test
new file mode 100755
index 0000000..23c4ac3
--- /dev/null
+++ b/strace/tests/getdents.test
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+# Check getdents syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+rm -rf -- "$LOG".dir
+run_strace_match_diff -a22 -v
diff --git a/strace/tests/getdents64.c b/strace/tests/getdents64.c
new file mode 100644
index 0000000..54149d2
--- /dev/null
+++ b/strace/tests/getdents64.c
@@ -0,0 +1,148 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getdents64
+
+# include <assert.h>
+# include <dirent.h>
+# include <fcntl.h>
+# include <inttypes.h>
+# include <stddef.h>
+# include <stdio.h>
+# include <sys/stat.h>
+# include <unistd.h>
+
+static const char fname[] =
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nZ";
+static const char qname[] =
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nZ";
+
+typedef struct {
+		uint64_t d_ino;
+		uint64_t d_off;
+		unsigned short d_reclen;
+		unsigned char d_type;
+		char d_name[256];
+} kernel_dirent64;
+
+static char buf[8192];
+
+static const char *
+str_d_type(const unsigned char d_type)
+{
+	switch (d_type) {
+		case DT_DIR:
+			return "DT_DIR";
+		case DT_REG:
+			return "DT_REG";
+		default:
+			return "DT_UNKNOWN";
+	}
+}
+static void
+print_dirent(const kernel_dirent64 *d)
+{
+	const unsigned int d_name_offset = offsetof(kernel_dirent64, d_name);
+	int d_name_len = d->d_reclen - d_name_offset;
+	assert(d_name_len > 0);
+
+	printf("{d_ino=%" PRIu64 ", d_off=%" PRId64
+	       ", d_reclen=%u, d_type=%s, d_name=",
+	       d->d_ino, d->d_off, d->d_reclen, str_d_type(d->d_type));
+
+	if (d->d_name[0] == '.')
+		printf("\"%.*s\"}", d_name_len, d->d_name);
+	else
+		printf("\"%s\"}", qname);
+}
+
+int
+main(int ac, const char **av)
+{
+	char *dname;
+
+	assert(ac == 1);
+	assert(asprintf(&dname, "%s.test.tmp.dir", av[0]) > 0);
+	assert(!mkdir(dname, 0700));
+	assert(!chdir(dname));
+	(void) close(0);
+	assert(!creat(fname, 0600));
+	assert(!close(0));
+	assert(!open(".", O_RDONLY | O_DIRECTORY));
+
+	unsigned long count = (unsigned long) 0xfacefeeddeadbeef;
+	long rc = syscall(__NR_getdents64, (long) 0xdefacedffffffff, NULL, count);
+	printf("getdents64(-1, NULL, %u) = %ld %s (%m)\n",
+	       (unsigned) count, rc, errno2name());
+
+	count = (unsigned long) 0xfacefeed00000000 | sizeof(buf);
+	while ((rc = syscall(__NR_getdents64, 0, buf, count))) {
+		kernel_dirent64 *d;
+		long i;
+
+		if (rc < 0)
+			perror_msg_and_skip("getdents64");
+		printf("getdents64(0, [");
+		for (i = 0; i < rc; i += d->d_reclen) {
+			d = (kernel_dirent64 *) &buf[i];
+			if (i)
+				printf(", ");
+			print_dirent(d);
+		}
+		printf("], %u) = %ld\n", (unsigned) count, rc);
+	}
+	printf("getdents64(0, [], %u) = 0\n", (unsigned) count);
+	puts("+++ exited with 0 +++");
+	assert(!unlink(fname));
+	assert(!chdir(".."));
+	assert(!rmdir(dname));
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getdents64")
+
+#endif
diff --git a/strace/tests/getdents64.test b/strace/tests/getdents64.test
new file mode 100755
index 0000000..401cfc7
--- /dev/null
+++ b/strace/tests/getdents64.test
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+# Check getdents64 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+rm -rf -- "$LOG".dir
+run_strace_match_diff -a24 -v
diff --git a/strace/tests/getegid.c b/strace/tests/getegid.c
new file mode 100644
index 0000000..31e4b44
--- /dev/null
+++ b/strace/tests/getegid.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getegid
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getegid() = %ld\n", syscall(__NR_getegid));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getegid")
+
+#endif
diff --git a/strace/tests/getegid.test b/strace/tests/getegid.test
new file mode 100755
index 0000000..4354158
--- /dev/null
+++ b/strace/tests/getegid.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check getegid syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/getegid32.c b/strace/tests/getegid32.c
new file mode 100644
index 0000000..7dc358a
--- /dev/null
+++ b/strace/tests/getegid32.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getegid32
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getegid32() = %ld\n", syscall(__NR_getegid32));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getegid32")
+
+#endif
diff --git a/strace/tests/getegid32.test b/strace/tests/getegid32.test
new file mode 100755
index 0000000..a266620
--- /dev/null
+++ b/strace/tests/getegid32.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check getegid32 syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/geteuid.c b/strace/tests/geteuid.c
new file mode 100644
index 0000000..0820656
--- /dev/null
+++ b/strace/tests/geteuid.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_geteuid
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("geteuid() = %ld\n", syscall(__NR_geteuid));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_geteuid")
+
+#endif
diff --git a/strace/tests/geteuid.test b/strace/tests/geteuid.test
new file mode 100755
index 0000000..14ff6a6
--- /dev/null
+++ b/strace/tests/geteuid.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check geteuid syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/geteuid32.c b/strace/tests/geteuid32.c
new file mode 100644
index 0000000..7e731d0
--- /dev/null
+++ b/strace/tests/geteuid32.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_geteuid32
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("geteuid32() = %ld\n", syscall(__NR_geteuid32));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_geteuid32")
+
+#endif
diff --git a/strace/tests/geteuid32.test b/strace/tests/geteuid32.test
new file mode 100755
index 0000000..9dd173d
--- /dev/null
+++ b/strace/tests/geteuid32.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check geteuid32 syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/getgid.c b/strace/tests/getgid.c
new file mode 100644
index 0000000..46969d3
--- /dev/null
+++ b/strace/tests/getgid.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getgid
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getgid() = %ld\n", syscall(__NR_getgid));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getgid")
+
+#endif
diff --git a/strace/tests/getgid.test b/strace/tests/getgid.test
new file mode 100755
index 0000000..f4f0c2e
--- /dev/null
+++ b/strace/tests/getgid.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check getgid syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/getgid32.c b/strace/tests/getgid32.c
new file mode 100644
index 0000000..11580d0
--- /dev/null
+++ b/strace/tests/getgid32.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getgid32
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getgid32() = %ld\n", syscall(__NR_getgid32));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getgid32")
+
+#endif
diff --git a/strace/tests/getgid32.test b/strace/tests/getgid32.test
new file mode 100755
index 0000000..3bc98d1
--- /dev/null
+++ b/strace/tests/getgid32.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check getgid32 syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/getgroups.c b/strace/tests/getgroups.c
new file mode 100644
index 0000000..d70689c
--- /dev/null
+++ b/strace/tests/getgroups.c
@@ -0,0 +1,148 @@
+/*
+ * Check decoding of getgroups/getgroups32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifdef __NR_getgroups32
+
+# define SYSCALL_NR	__NR_getgroups32
+# define SYSCALL_NAME	"getgroups32"
+# define GID_TYPE	unsigned int
+
+#else
+
+# include "tests.h"
+# include <sys/syscall.h>
+
+# ifdef __NR_getgroups
+
+#  define SYSCALL_NR	__NR_getgroups
+#  define SYSCALL_NAME	"getgroups"
+#  if defined __NR_getgroups32 && __NR_getgroups != __NR_getgroups32
+#   define GID_TYPE	unsigned short
+#  else
+#   define GID_TYPE	unsigned int
+#  endif
+
+# endif
+
+#endif
+
+#ifdef GID_TYPE
+
+# include <stdio.h>
+# include <unistd.h>
+
+#define MAX_STRLEN 32
+static long ngroups;
+
+static void
+get_groups(const long size, GID_TYPE *const g)
+{
+	long i = syscall(SYSCALL_NR, size, g);
+	if (i != ngroups)
+		perror_msg_and_fail("%s(%#lx, %p)", SYSCALL_NAME, size, g);
+
+	printf("%s(%u, [", SYSCALL_NAME, (unsigned) size);
+	for (i = 0; i < ngroups; ++i) {
+		if (i)
+			printf(", ");
+		if (i >= MAX_STRLEN) {
+			printf("...");
+			break;
+		}
+		printf("%u", (unsigned int) g[i]);
+	}
+	printf("]) = %ld\n", ngroups);
+}
+
+int
+main(void)
+{
+	long rc;
+
+	/* check how the first argument is decoded */
+	ngroups = syscall(SYSCALL_NR, 0, 0);
+	printf("%s(0, NULL) = %ld\n", SYSCALL_NAME, ngroups);
+	if (ngroups < 0)
+		perror_msg_and_fail(SYSCALL_NAME);
+
+	rc = syscall(SYSCALL_NR, (long) 0xffffffff00000000ULL, 0);
+	printf("%s(0, NULL) = %ld\n", SYSCALL_NAME, rc);
+
+	rc = syscall(SYSCALL_NR, -1U, 0);
+	printf("%s(%u, NULL) = %ld %s (%m)\n",
+	       SYSCALL_NAME, -1U, rc, errno2name());
+
+	rc = syscall(SYSCALL_NR, -1L, 0);
+	printf("%s(%u, NULL) = %ld %s (%m)\n",
+	       SYSCALL_NAME, -1U, rc, errno2name());
+
+	const unsigned int ngroups_max = sysconf(_SC_NGROUPS_MAX);
+
+	rc = syscall(SYSCALL_NR, ngroups_max, 0);
+	if (rc < 0)
+		printf("%s(%u, NULL) = %ld %s (%m)\n",
+		       SYSCALL_NAME, ngroups_max, rc, errno2name());
+	else
+		printf("%s(%u, NULL) = %ld\n",
+		       SYSCALL_NAME, ngroups_max, rc);
+
+	rc = syscall(SYSCALL_NR, (long) 0xffffffff00000000ULL | ngroups_max, 0);
+	if (rc < 0)
+		printf("%s(%u, NULL) = %ld %s (%m)\n",
+		       SYSCALL_NAME, ngroups_max, rc, errno2name());
+	else
+		printf("%s(%u, NULL) = %ld\n",
+		       SYSCALL_NAME, ngroups_max, rc);
+
+	/* check how the second argument is decoded */
+	GID_TYPE *const g1 =
+		tail_alloc(ngroups ? sizeof(*g1) * ngroups : 1);
+	GID_TYPE *const g2 = tail_alloc(sizeof(*g2) * (ngroups + 1));
+	void *efault = g2 + ngroups + 1;
+
+	get_groups(ngroups, g1);
+	get_groups(ngroups + 1, g1);
+	get_groups(ngroups + 1, g2);
+
+	if (ngroups) {
+		rc = syscall(SYSCALL_NR, ngroups, efault);
+		printf("%s(%u, %p) = %ld %s (%m)\n",
+		       SYSCALL_NAME, (unsigned) ngroups, efault,
+		       rc, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getgroups")
+
+#endif
diff --git a/strace/tests/getgroups.test b/strace/tests/getgroups.test
new file mode 100755
index 0000000..2eb3056
--- /dev/null
+++ b/strace/tests/getgroups.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getgroups syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a17
diff --git a/strace/tests/getgroups32.c b/strace/tests/getgroups32.c
new file mode 100644
index 0000000..2576548
--- /dev/null
+++ b/strace/tests/getgroups32.c
@@ -0,0 +1,12 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getgroups32
+
+# include "getgroups.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getgroups32")
+
+#endif
diff --git a/strace/tests/getgroups32.test b/strace/tests/getgroups32.test
new file mode 100755
index 0000000..12a8bcc
--- /dev/null
+++ b/strace/tests/getgroups32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getgroups32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a19
diff --git a/strace/tests/getpeername.c b/strace/tests/getpeername.c
new file mode 100644
index 0000000..c842ace
--- /dev/null
+++ b/strace/tests/getpeername.c
@@ -0,0 +1,63 @@
+/*
+ * Check decoding of getpeername syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define TEST_SYSCALL_NAME getpeername
+#include "sockname.c"
+
+int
+main(void)
+{
+	int lfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	int cfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (lfd < 0 || cfd < 0)
+		perror_msg_and_skip("socket");
+
+	(void) unlink(TEST_SOCKET);
+
+	const struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = TEST_SOCKET
+	};
+
+	if (bind(lfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+	if (listen(lfd, 1))
+		perror_msg_and_skip("listen");
+	if (connect(cfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("connect");
+	if (accept(lfd, 0, 0) < 0)
+		perror_msg_and_skip("accept");
+
+	test_sockname_syscall(cfd);
+
+	(void) unlink(TEST_SOCKET);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/getpeername.test b/strace/tests/getpeername.test
new file mode 100755
index 0000000..81f01bb
--- /dev/null
+++ b/strace/tests/getpeername.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of getpeername syscall.
+
+. "${srcdir=.}/getsockname.test"
diff --git a/strace/tests/getpgrp.c b/strace/tests/getpgrp.c
new file mode 100644
index 0000000..fd3139b
--- /dev/null
+++ b/strace/tests/getpgrp.c
@@ -0,0 +1,22 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getpgrp
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getpgrp() = %ld\n", syscall(__NR_getpgrp));
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getpgrp")
+
+#endif
diff --git a/strace/tests/getpgrp.test b/strace/tests/getpgrp.test
new file mode 100755
index 0000000..e116bb5
--- /dev/null
+++ b/strace/tests/getpgrp.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getpgrp syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/getrandom.c b/strace/tests/getrandom.c
new file mode 100644
index 0000000..4c17c29
--- /dev/null
+++ b/strace/tests/getrandom.c
@@ -0,0 +1,64 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getrandom
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	unsigned char buf[4];
+
+	if (syscall(__NR_getrandom, buf, sizeof(buf) - 1, 0) != sizeof(buf) - 1)
+		perror_msg_and_skip("getrandom");
+	printf("getrandom(\"\\x%02x\\x%02x\\x%02x\", 3, 0) = 3\n",
+	       (int) buf[0], (int) buf[1], (int) buf[2]);
+
+	if (syscall(__NR_getrandom, buf, sizeof(buf), 1) != sizeof(buf))
+		perror_msg_and_skip("getrandom");
+	printf("getrandom(\"\\x%02x\\x%02x\\x%02x\"..., 4, GRND_NONBLOCK) = 4\n",
+	       (int) buf[0], (int) buf[1], (int) buf[2]);
+
+	if (syscall(__NR_getrandom, buf, sizeof(buf), 0x3003) != -1)
+		perror_msg_and_skip("getrandom");
+	printf("getrandom(%p, 4, GRND_NONBLOCK|GRND_RANDOM|0x3000) = "
+	       "-1 EINVAL (%m)\n", buf);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getrandom")
+
+#endif
diff --git a/strace/tests/getrandom.test b/strace/tests/getrandom.test
new file mode 100755
index 0000000..e06367c
--- /dev/null
+++ b/strace/tests/getrandom.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getrandom syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a32 -xx -s3
diff --git a/strace/tests/getresgid.c b/strace/tests/getresgid.c
new file mode 100644
index 0000000..5827cdd
--- /dev/null
+++ b/strace/tests/getresgid.c
@@ -0,0 +1,21 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getresgid
+
+# define SYSCALL_NR	__NR_getresgid
+# define SYSCALL_NAME	"getresgid"
+
+# if defined __NR_getresgid32 && __NR_getresgid != __NR_getresgid32
+#  define UGID_TYPE	short
+# else
+#  define UGID_TYPE	int
+# endif
+
+# include "getresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getresgid")
+
+#endif
diff --git a/strace/tests/getresgid.test b/strace/tests/getresgid.test
new file mode 100755
index 0000000..9f5186e
--- /dev/null
+++ b/strace/tests/getresgid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getresgid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a25
diff --git a/strace/tests/getresgid32.c b/strace/tests/getresgid32.c
new file mode 100644
index 0000000..ca337d8
--- /dev/null
+++ b/strace/tests/getresgid32.c
@@ -0,0 +1,15 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getresgid32
+
+# define SYSCALL_NR	__NR_getresgid32
+# define SYSCALL_NAME	"getresgid32"
+# define UGID_TYPE	int
+# include "getresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getresgid32")
+
+#endif
diff --git a/strace/tests/getresgid32.test b/strace/tests/getresgid32.test
new file mode 100755
index 0000000..a979891
--- /dev/null
+++ b/strace/tests/getresgid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getresgid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a27
diff --git a/strace/tests/getresugid.c b/strace/tests/getresugid.c
new file mode 100644
index 0000000..0ee721c
--- /dev/null
+++ b/strace/tests/getresugid.c
@@ -0,0 +1,58 @@
+/*
+ * Check decoding of getresuid/getresgid/getresuid32/getresgid32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <assert.h>
+#include <stdio.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	unsigned UGID_TYPE *const r = tail_alloc(sizeof(*r));
+	unsigned UGID_TYPE *const e = tail_alloc(sizeof(*e));
+	unsigned UGID_TYPE *const s = tail_alloc(sizeof(*s));
+
+	if (syscall(SYSCALL_NR, r, e, s))
+		perror_msg_and_fail(SYSCALL_NAME);
+
+	printf("%s([%u], [%u], [%u]) = 0\n", SYSCALL_NAME,
+	       (unsigned) *r, (unsigned) *e, (unsigned) *s);
+
+	assert(syscall(SYSCALL_NR, NULL, e, s) == -1);
+	printf("%s(NULL, %p, %p) = -1 EFAULT (%m)\n", SYSCALL_NAME, e, s);
+
+	assert(syscall(SYSCALL_NR, r, NULL, s) == -1);
+	printf("%s(%p, NULL, %p) = -1 EFAULT (%m)\n", SYSCALL_NAME, r, s);
+
+	assert(syscall(SYSCALL_NR, r, e, NULL) == -1);
+	printf("%s(%p, %p, NULL) = -1 EFAULT (%m)\n", SYSCALL_NAME, r, e);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/getresuid.c b/strace/tests/getresuid.c
new file mode 100644
index 0000000..bf4ada1
--- /dev/null
+++ b/strace/tests/getresuid.c
@@ -0,0 +1,21 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getresuid
+
+# define SYSCALL_NR	__NR_getresuid
+# define SYSCALL_NAME	"getresuid"
+
+# if defined __NR_getresuid32 && __NR_getresuid != __NR_getresuid32
+#  define UGID_TYPE	short
+# else
+#  define UGID_TYPE	int
+# endif
+
+# include "getresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getresuid")
+
+#endif
diff --git a/strace/tests/getresuid.test b/strace/tests/getresuid.test
new file mode 100755
index 0000000..eee1ac0
--- /dev/null
+++ b/strace/tests/getresuid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getresuid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a25
diff --git a/strace/tests/getresuid32.c b/strace/tests/getresuid32.c
new file mode 100644
index 0000000..3154e27
--- /dev/null
+++ b/strace/tests/getresuid32.c
@@ -0,0 +1,15 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getresuid32
+
+# define SYSCALL_NR	__NR_getresuid32
+# define SYSCALL_NAME	"getresuid32"
+# define UGID_TYPE	int
+# include "getresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getresuid32")
+
+#endif
diff --git a/strace/tests/getresuid32.test b/strace/tests/getresuid32.test
new file mode 100755
index 0000000..fdc76a3
--- /dev/null
+++ b/strace/tests/getresuid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getresuid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a27
diff --git a/strace/tests/getrlimit.c b/strace/tests/getrlimit.c
new file mode 100644
index 0000000..9fb668d
--- /dev/null
+++ b/strace/tests/getrlimit.c
@@ -0,0 +1,14 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getrlimit
+
+# define NR_GETRLIMIT	__NR_getrlimit
+# define STR_GETRLIMIT	"getrlimit"
+# include "xgetrlimit.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getrlimit")
+
+#endif
diff --git a/strace/tests/getrlimit.test b/strace/tests/getrlimit.test
new file mode 100755
index 0000000..6fd88ae
--- /dev/null
+++ b/strace/tests/getrlimit.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of getrlimit syscall.
+
+. "${srcdir=.}/setrlimit.test"
diff --git a/strace/tests/getrusage.c b/strace/tests/getrusage.c
new file mode 100644
index 0000000..7fd9823
--- /dev/null
+++ b/strace/tests/getrusage.c
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2016 Fei Jie <feij.fnst@cn.fujitsu.com>
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getrusage
+
+# include <stdio.h>
+# include <stdint.h>
+# include <sys/resource.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	struct rusage *const usage = tail_alloc(sizeof(struct rusage));
+	int rc = syscall(__NR_getrusage, RUSAGE_SELF, usage);
+	printf("getrusage(RUSAGE_SELF, {ru_utime={%ju, %ju}"
+	       ", ru_stime={%ju, %ju}, ru_maxrss=%lu, ru_ixrss=%lu"
+	       ", ru_idrss=%lu, ru_isrss=%lu, ru_minflt=%lu"
+	       ", ru_majflt=%lu, ru_nswap=%lu, ru_inblock=%lu"
+	       ", ru_oublock=%lu, ru_msgsnd=%lu, ru_msgrcv=%lu"
+	       ", ru_nsignals=%lu, ru_nvcsw=%lu, ru_nivcsw=%lu}) = %d\n",
+	       (uintmax_t) usage->ru_utime.tv_sec,
+	       (uintmax_t) usage->ru_utime.tv_usec,
+	       (uintmax_t) usage->ru_stime.tv_sec,
+	       (uintmax_t) usage->ru_stime.tv_usec,
+	       usage->ru_maxrss, usage->ru_ixrss, usage->ru_idrss,
+	       usage->ru_isrss, usage->ru_minflt, usage->ru_majflt,
+	       usage->ru_nswap, usage->ru_inblock, usage->ru_oublock,
+	       usage->ru_msgsnd, usage->ru_msgrcv, usage->ru_nsignals,
+	       usage->ru_nvcsw, usage->ru_nivcsw, rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getrusage")
+
+#endif
diff --git a/strace/tests/getrusage.test b/strace/tests/getrusage.test
new file mode 100755
index 0000000..4a3e8ed
--- /dev/null
+++ b/strace/tests/getrusage.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getrusage syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v
diff --git a/strace/tests/getsid.c b/strace/tests/getsid.c
new file mode 100644
index 0000000..b563de9
--- /dev/null
+++ b/strace/tests/getsid.c
@@ -0,0 +1,13 @@
+#include "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	pid_t pid = getpid();
+	printf("getsid(%d) = %d\n", pid, getsid(pid));
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/getsid.test b/strace/tests/getsid.test
new file mode 100755
index 0000000..3fcf979
--- /dev/null
+++ b/strace/tests/getsid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getsid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/getsockname.c b/strace/tests/getsockname.c
new file mode 100644
index 0000000..66ac4e6
--- /dev/null
+++ b/strace/tests/getsockname.c
@@ -0,0 +1,56 @@
+/*
+ * Check decoding of getsockname syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define TEST_SYSCALL_NAME getsockname
+#include "sockname.c"
+
+int
+main(void)
+{
+	int lfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (lfd < 0)
+		perror_msg_and_skip("socket");
+
+	(void) unlink(TEST_SOCKET);
+
+	const struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = TEST_SOCKET
+	};
+
+	if (bind(lfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+
+	test_sockname_syscall(lfd);
+
+	(void) unlink(TEST_SOCKET);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/getsockname.test b/strace/tests/getsockname.test
new file mode 100755
index 0000000..99b2850
--- /dev/null
+++ b/strace/tests/getsockname.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of getsockname syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a27
diff --git a/strace/tests/getuid.c b/strace/tests/getuid.c
new file mode 100644
index 0000000..25731c8
--- /dev/null
+++ b/strace/tests/getuid.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getuid
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getuid() = %ld\n", syscall(__NR_getuid));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getuid")
+
+#endif
diff --git a/strace/tests/getuid.test b/strace/tests/getuid.test
new file mode 100755
index 0000000..9aaf74b
--- /dev/null
+++ b/strace/tests/getuid.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check getuid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+check_prog uniq
+run_prog > /dev/null
+run_strace -qq -a9 -e$NAME $args > "$EXP"
+uniq < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+rm -f "$OUT" "$EXP"
diff --git a/strace/tests/getuid32.c b/strace/tests/getuid32.c
new file mode 100644
index 0000000..c6f68ae
--- /dev/null
+++ b/strace/tests/getuid32.c
@@ -0,0 +1,20 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_getuid32
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("getuid32() = %ld\n", syscall(__NR_getuid32));
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getuid32")
+
+#endif
diff --git a/strace/tests/getuid32.test b/strace/tests/getuid32.test
new file mode 100755
index 0000000..ae0c557
--- /dev/null
+++ b/strace/tests/getuid32.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check getuid32 syscall decoding.
+
+. "${srcdir=.}/getuid.test"
diff --git a/strace/tests/getxxid.c b/strace/tests/getxxid.c
new file mode 100644
index 0000000..1f2076c
--- /dev/null
+++ b/strace/tests/getxxid.c
@@ -0,0 +1,61 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_getxpid && defined __NR_getxuid && defined __NR_getxgid
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long id;
+	pid_t ppid;
+
+	id = syscall(__NR_getxpid);
+	ppid = getppid();
+	printf("getxpid() = %ld (ppid %ld)\n", id, (long) ppid);
+	printf("getxpid() = %ld (ppid %ld)\n", id, (long) ppid);
+
+	id = syscall(__NR_getxuid);
+	printf("getxuid() = %ld (euid %ld)\n", id, id);
+
+	id = syscall(__NR_getxgid);
+	printf("getxgid() = %ld (egid %ld)\n", id, id);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getxpid && __NR_getxuid && __NR_getxgid")
+
+#endif
diff --git a/strace/tests/getxxid.test b/strace/tests/getxxid.test
new file mode 100755
index 0000000..9b89d7c
--- /dev/null
+++ b/strace/tests/getxxid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getxpid, getxuid, and getxgid syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10 -e trace=getxpid,getxuid,getxgid
diff --git a/strace/tests/hexdump_strdup.c b/strace/tests/hexdump_strdup.c
new file mode 100644
index 0000000..4d6b53f
--- /dev/null
+++ b/strace/tests/hexdump_strdup.c
@@ -0,0 +1,66 @@
+/*
+ * Make a hexdump copy of C string
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <assert.h>
+#include <stdlib.h>
+#include <string.h>
+
+const char *
+hexdump_memdup(const char *src, size_t len)
+{
+	size_t dst_size = 3 * len + 2;
+	assert(dst_size > len);
+
+	char *dst = malloc(dst_size);
+	if (!dst)
+		perror_msg_and_fail("malloc(%zu)", dst_size);
+
+	char *p = dst;
+	const unsigned char *usrc = (const unsigned char *) src;
+	size_t i;
+	for (i = 0; i < len; ++i) {
+		unsigned int c = usrc[i];
+		*(p++) = ' ';
+		if (i == 8)
+			*(p++) = ' ';
+		*(p++) = "0123456789abcdef"[c >> 4];
+		*(p++) = "0123456789abcdef"[c & 0xf];
+	}
+	*p = '\0';
+
+	return dst;
+}
+
+const char *
+hexdump_strdup(const char *src)
+{
+	return hexdump_memdup(src, strlen(src));
+}
diff --git a/strace/tests/hexquote_strndup.c b/strace/tests/hexquote_strndup.c
new file mode 100644
index 0000000..3ad3970
--- /dev/null
+++ b/strace/tests/hexquote_strndup.c
@@ -0,0 +1,58 @@
+/*
+ * Make a hexquoted copy of a string
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <assert.h>
+#include <stdlib.h>
+#include <string.h>
+
+const char *
+hexquote_strndup(const char *src, const size_t src_len)
+{
+	const size_t dst_size = 4 * src_len + 1;
+	assert(dst_size > src_len);
+
+	char *dst = malloc(dst_size);
+	if (!dst)
+		perror_msg_and_fail("malloc(%zu)", dst_size);
+
+	char *p = dst;
+	size_t i;
+	for (i = 0; i < src_len; ++i) {
+		unsigned int c = ((const unsigned char *) src)[i];
+		*(p++) = '\\';
+		*(p++) = 'x';
+		*(p++) = "0123456789abcdef"[c >> 4];
+		*(p++) = "0123456789abcdef"[c & 0xf];
+	}
+	*p = '\0';
+
+	return dst;
+}
diff --git a/strace/tests/inet-cmsg.c b/strace/tests/inet-cmsg.c
new file mode 100644
index 0000000..b530016
--- /dev/null
+++ b/strace/tests/inet-cmsg.c
@@ -0,0 +1,195 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <fcntl.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
+static void
+print_pktinfo(const struct cmsghdr *c)
+{
+	printf("IP_PKTINFO, cmsg_data={ipi_ifindex=if_nametoindex(\"lo\")"
+	       ", ipi_spec_dst=inet_addr(\"127.0.0.1\")"
+	       ", ipi_addr=inet_addr(\"127.0.0.1\")}");
+}
+
+static void
+print_ttl(const struct cmsghdr *c)
+{
+	const unsigned int *ttl = (const unsigned int *) CMSG_DATA(c);
+
+	printf("IP_TTL, cmsg_data=[%u]", *ttl);
+}
+
+static void
+print_tos(const struct cmsghdr *c)
+{
+	const uint8_t *tos = (const uint8_t *) CMSG_DATA(c);
+
+	printf("IP_TOS, cmsg_data=[%#x]", *tos);
+}
+
+static void
+print_opts(const char *name, const struct cmsghdr *c)
+{
+	const unsigned char *opts = (const unsigned char *) CMSG_DATA(c);
+	const size_t len = c->cmsg_len - CMSG_ALIGN(sizeof(*c));
+
+	printf("%s", name);
+	if (len) {
+		printf(", cmsg_data=[");
+		size_t i;
+		for (i = 0; i < len; ++i)
+			printf("%s0x%02x", i ? ", " : "", opts[i]);
+		printf("]");
+	}
+}
+
+#ifdef IP_ORIGDSTADDR
+static void
+print_origdstaddr(const struct cmsghdr *c)
+{
+	const struct sockaddr_in *sin =
+		(const struct sockaddr_in *) CMSG_DATA(c);
+
+	printf("IP_ORIGDSTADDR, cmsg_data={sa_family=AF_INET, sin_port=htons(%u)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}", ntohs(sin->sin_port));
+}
+#endif
+
+int
+main(void)
+{
+	int i;
+	while ((i = open("/dev/null", O_RDWR)) < 3)
+		assert(i >= 0);
+	assert(!close(0));
+	assert(!close(3));
+
+	if (socket(AF_INET, SOCK_DGRAM, 0))
+		perror_msg_and_skip("socket");
+	struct sockaddr_in addr = {
+		.sin_family = AF_INET,
+		.sin_addr.s_addr = htonl(INADDR_LOOPBACK)
+	};
+	socklen_t len = sizeof(addr);
+	if (bind(0, (struct sockaddr *) &addr, len))
+		perror_msg_and_skip("bind");
+	assert(!getsockname(0, (struct sockaddr *) &addr, &len));
+
+	assert(socket(AF_INET, SOCK_DGRAM, 0) == 3);
+	assert(!connect(3, (struct sockaddr *) &addr, len));
+
+	const int opt_1 = htonl(0x01000000);
+#define SETSOCKOPT(fd, name) assert(!setsockopt(fd, IPPROTO_IP, (name), &opt_1, sizeof(opt_1)))
+	SETSOCKOPT(3, IP_OPTIONS);
+	SETSOCKOPT(0, IP_PKTINFO);
+	SETSOCKOPT(0, IP_RECVTTL);
+	SETSOCKOPT(0, IP_RECVTOS);
+	SETSOCKOPT(0, IP_RECVOPTS);
+	SETSOCKOPT(0, IP_RETOPTS);
+#ifdef IP_RECVORIGDSTADDR
+	SETSOCKOPT(0, IP_RECVORIGDSTADDR);
+#endif
+
+	static const char data[] = "data";
+	const size_t size = sizeof(data) - 1;
+	assert(send(3, data, size, 0) == (int) size);
+	assert(!close(3));
+
+	char buf[size];
+	struct iovec iov = {
+		.iov_base = buf,
+		.iov_len = sizeof(buf)
+	};
+	struct cmsghdr control[16];
+	struct msghdr mh = {
+		.msg_name = &addr,
+		.msg_namelen = len,
+		.msg_iov = &iov,
+		.msg_iovlen = 1,
+		.msg_control = control,
+		.msg_controllen = sizeof(control)
+	};
+
+	assert(recvmsg(0, &mh, 0) == (int) size);
+	assert(!close(0));
+
+	printf("recvmsg(0, {msg_name={sa_family=AF_INET, sin_port=htons(%u)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}, msg_namelen=%u"
+	       ", msg_iov=[{iov_base=\"%s\", iov_len=%u}], msg_iovlen=1"
+	       ", msg_control=[",
+	       ntohs(addr.sin_port), (unsigned) mh.msg_namelen,
+	       data, (unsigned) size);
+
+	struct cmsghdr *c;
+	for (c = CMSG_FIRSTHDR(&mh); c; c = CMSG_NXTHDR(&mh, c)) {
+		if (IPPROTO_IP != c->cmsg_level)
+			continue;
+		if (c != control)
+			printf(", ");
+		printf("{cmsg_len=%lu, cmsg_level=SOL_IP, cmsg_type=",
+		       (unsigned long) c->cmsg_len);
+		switch (c->cmsg_type) {
+			case IP_PKTINFO:
+				print_pktinfo(c);
+				break;
+			case IP_TTL:
+				print_ttl(c);
+				break;
+			case IP_TOS:
+				print_tos(c);
+				break;
+			case IP_RECVOPTS:
+				print_opts("IP_RECVOPTS", c);
+				break;
+			case IP_RETOPTS:
+				print_opts("IP_RETOPTS", c);
+				break;
+#ifdef IP_ORIGDSTADDR
+			case IP_ORIGDSTADDR:
+				print_origdstaddr(c);
+				break;
+#endif
+			default:
+				printf("%d", c->cmsg_type);
+				break;
+		}
+		printf("}");
+	}
+	printf("], msg_controllen=%lu, msg_flags=0}, 0) = %u\n",
+	       (unsigned long) mh.msg_controllen, (unsigned) size);
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
diff --git a/strace/tests/inet-cmsg.test b/strace/tests/inet-cmsg.test
new file mode 100755
index 0000000..52ff5f5
--- /dev/null
+++ b/strace/tests/inet-cmsg.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check IPPROTO_IP control messages decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=recvmsg
diff --git a/strace/tests/init.sh b/strace/tests/init.sh
new file mode 100644
index 0000000..b6fa522
--- /dev/null
+++ b/strace/tests/init.sh
@@ -0,0 +1,226 @@
+#!/bin/sh
+#
+# Copyright (c) 2011-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+ME_="${0##*/}"
+LOG="$ME_.tmp"
+OUT="$LOG.out"
+EXP="$LOG.exp"
+NAME="${ME_%.test}"
+
+warn_() { printf >&2 '%s\n' "$*"; }
+fail_() { warn_ "$ME_: failed test: $*"; exit 1; }
+skip_() { warn_ "$ME_: skipped test: $*"; exit 77; }
+framework_failure_() { warn_ "$ME_: framework failure: $*"; exit 99; }
+framework_skip_() { warn_ "$ME_: framework skip: $*"; exit 77; }
+
+check_prog()
+{
+	type "$@" > /dev/null 2>&1 ||
+		framework_skip_ "$* is not available"
+}
+
+dump_log_and_fail_with()
+{
+	cat < "$LOG"
+	fail_ "$*"
+}
+
+run_prog()
+{
+	if [ $# -eq 0 ]; then
+		set -- "./$NAME"
+	fi
+	args="$*"
+	"$@" || {
+		if [ $? -eq 77 ]; then
+			skip_ "$args exited with code 77"
+		else
+			fail_ "$args failed"
+		fi
+	}
+}
+
+
+run_prog_skip_if_failed()
+{
+	args="$*"
+	"$@" || framework_skip_ "$args failed"
+}
+
+run_strace()
+{
+	> "$LOG" || fail_ "failed to write $LOG"
+	args="$*"
+	$STRACE -o "$LOG" "$@" ||
+		dump_log_and_fail_with "$STRACE $args failed"
+}
+
+run_strace_merge()
+{
+	rm -f -- "$LOG".[0-9]*
+	run_strace -ff -tt "$@"
+	"$srcdir"/../strace-log-merge "$LOG" > "$LOG" ||
+		dump_log_and_fail_with 'strace-log-merge failed'
+	rm -f -- "$LOG".[0-9]*
+}
+
+check_gawk()
+{
+	check_prog gawk
+	check_prog grep
+
+	local program="$1"; shift
+	if grep '^@include[[:space:]]' < "$program" > /dev/null; then
+		gawk '@include "/dev/null"' < /dev/null ||
+			framework_skip_ 'gawk does not support @include'
+	fi
+}
+
+# Usage: [FILE_TO_CHECK [AWK_PROGRAM [ERROR_MESSAGE [EXTRA_AWK_OPTIONS...]]]]
+# Check whether AWK_PROGRAM matches FILE_TO_CHECK using gawk.
+# If it doesn't, dump FILE_TO_CHECK and fail with ERROR_MESSAGE.
+match_awk()
+{
+	local output program error
+	if [ $# -eq 0 ]; then
+		output="$LOG"
+	else
+		output="$1"; shift
+	fi
+	if [ $# -eq 0 ]; then
+		program="$srcdir/$NAME.awk"
+	else
+		program="$1"; shift
+	fi
+	if [ $# -eq 0 ]; then
+		error="$STRACE $args output mismatch"
+	else
+		error="$1"; shift
+	fi
+
+	check_gawk "$program"
+
+	AWKPATH="$srcdir" gawk -f "$program" "$@" < "$output" || {
+		cat < "$output"
+		fail_ "$error"
+	}
+}
+
+# Usage: [FILE_TO_CHECK [FILE_TO_COMPATE_WITH [ERROR_MESSAGE]]]
+# Check whether FILE_TO_CHECK differs from FILE_TO_COMPATE_WITH.
+# If it does, dump the difference and fail with ERROR_MESSAGE.
+match_diff()
+{
+	local output expected error
+	if [ $# -eq 0 ]; then
+		output="$LOG"
+	else
+		output="$1"; shift
+	fi
+	if [ $# -eq 0 ]; then
+		expected="$srcdir/$NAME.expected"
+	else
+		expected="$1"; shift
+	fi
+	if [ $# -eq 0 ]; then
+		error="$STRACE $args output mismatch"
+	else
+		error="$1"; shift
+	fi
+
+	check_prog diff
+
+	diff -- "$expected" "$output" ||
+		fail_ "$error"
+}
+
+# Usage: [FILE_TO_CHECK [FILE_WITH_PATTERNS [ERROR_MESSAGE]]]
+# Check whether all patterns listed in FILE_WITH_PATTERNS
+# match FILE_TO_CHECK using egrep.
+# If at least one of these patterns does not match,
+# dump both files and fail with ERROR_MESSAGE.
+match_grep()
+{
+	local output patterns error pattern failed=
+	if [ $# -eq 0 ]; then
+		output="$LOG"
+	else
+		output="$1"; shift
+	fi
+	if [ $# -eq 0 ]; then
+		patterns="$srcdir/$NAME.expected"
+	else
+		patterns="$1"; shift
+	fi
+	if [ $# -eq 0 ]; then
+		error="$STRACE $args output mismatch"
+	else
+		error="$1"; shift
+	fi
+
+	check_prog wc
+	check_prog grep
+
+	while read -r pattern; do
+		LC_ALL=C grep -E -x -e "$pattern" < "$output" > /dev/null || {
+			test -n "$failed" || {
+				echo 'Failed patterns of expected output:'
+				failed=1
+			}
+			printf '%s\n' "$pattern"
+		}
+	done < "$patterns"
+	test -z "$failed" || {
+		echo 'Actual output:'
+		cat < "$output"
+		fail_ "$error"
+	}
+}
+
+# Usage: run_strace_match_diff [args to run_strace]
+run_strace_match_diff()
+{
+	args="$*"
+	[ -n "$args" -a -z "${args##*-e trace=*}" ] ||
+		set -- -e trace="$NAME" "$@"
+	run_prog > /dev/null
+	run_strace "$@" $args > "$EXP"
+	match_diff "$LOG" "$EXP"
+	rm -f "$EXP"
+}
+
+check_prog cat
+check_prog rm
+
+rm -f "$LOG"
+
+: "${STRACE:=../strace}"
+: "${TIMEOUT_DURATION:=60}"
+: "${SLEEP_A_BIT:=sleep 1}"
+
+[ -z "${VERBOSE-}" ] ||
+	set -x
diff --git a/strace/tests/inode_of_sockfd.c b/strace/tests/inode_of_sockfd.c
new file mode 100644
index 0000000..b227f30
--- /dev/null
+++ b/strace/tests/inode_of_sockfd.c
@@ -0,0 +1,59 @@
+/*
+ * This file is part of strace test suite.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/param.h>
+
+unsigned long
+inode_of_sockfd(const int fd)
+{
+	assert(fd >= 0);
+
+	char linkpath[sizeof("/proc/self/fd/%u") + sizeof(int) * 3];
+	assert(snprintf(linkpath, sizeof(linkpath), "/proc/self/fd/%u", fd)
+	       < (int) sizeof(linkpath));
+
+	char path[PATH_MAX + 1];
+	const ssize_t path_len = readlink(linkpath, path, sizeof(path) - 1);
+	if (path_len < 0)
+		perror_msg_and_fail("readlink: %s", linkpath);
+	path[path_len] = '\0';
+
+	static const char prefix[] = "socket:[";
+	const size_t prefix_len = sizeof(prefix) - 1;
+	assert(strncmp(path, prefix, prefix_len) == 0
+	       && path[path_len - 1] == ']');
+
+	return strtoul(path + prefix_len, NULL, 10);
+}
diff --git a/strace/tests/ioctl.c b/strace/tests/ioctl.c
new file mode 100644
index 0000000..f05ff5c
--- /dev/null
+++ b/strace/tests/ioctl.c
@@ -0,0 +1,105 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <unistd.h>
+#include <termios.h>
+#include <sys/ioctl.h>
+
+#ifdef HAVE_LINUX_MMTIMER_H
+# include <linux/mmtimer.h>
+#endif
+#ifdef HAVE_LINUX_HIDDEV_H
+# include <linux/hiddev.h>
+#endif
+#ifdef HAVE_LINUX_INPUT_H
+# include <linux/input.h>
+#endif
+
+#include <linux/videodev2.h>
+
+#if defined MMTIMER_GETRES \
+ && defined VIDIOC_ENUMINPUT \
+ && defined HIDIOCGVERSION \
+ && defined HIDIOCGPHYS \
+ && defined EVIOCGBIT \
+ && defined EV_KEY
+
+int
+main(void )
+{
+	uint64_t data = 0;
+
+#ifndef POWERPC
+	struct termios tty;
+	(void) ioctl(-1, TCGETS, &tty);
+	printf("ioctl(-1, TCGETS, %p)"
+	       " = -1 EBADF (%m)\n", &tty);
+#endif
+
+	(void) ioctl(-1, MMTIMER_GETRES, &data);
+	printf("ioctl(-1, MMTIMER_GETRES, %p)"
+	       " = -1 EBADF (%m)\n", &data);
+
+	(void) ioctl(-1, VIDIOC_ENUMINPUT, 0);
+	printf("ioctl(-1, VIDIOC_ENUMINPUT, NULL)"
+	       " = -1 EBADF (%m)\n");
+
+	(void) ioctl(-1, HIDIOCGVERSION, &data);
+	printf("ioctl(-1, HIDIOCGRDESCSIZE or HIDIOCGVERSION, %p)"
+	       " = -1 EBADF (%m)\n", &data);
+
+	(void) ioctl(-1, HIDIOCGPHYS(8), &data);
+	printf("ioctl(-1, HIDIOCGPHYS(8), %p)"
+	       " = -1 EBADF (%m)\n", &data);
+
+	(void) ioctl(-1, EVIOCGBIT(EV_KEY, 8), &data);
+	printf("ioctl(-1, EVIOCGBIT(EV_KEY, 8), %p)"
+	       " = -1 EBADF (%m)\n", &data);
+
+	(void) ioctl(-1, _IOR('M', 13, int), &data);
+	printf("ioctl(-1, MIXER_READ(13) or OTPSELECT, [MTD_OTP_OFF])"
+	       " = -1 EBADF (%m)\n");
+
+	(void) ioctl(-1, _IOR(0xde, 0xad, data), &data);
+	printf("ioctl(-1, _IOC(_IOC_READ, 0xde, 0xad, 0x08), %p)"
+	       " = -1 EBADF (%m)\n", &data);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("MMTIMER_GETRES && VIDIOC_ENUMINPUT"
+		    " && HIDIOCGVERSION && HIDIOCGPHYS"
+		    " && EVIOCGBIT && EV_KEY")
+
+#endif
diff --git a/strace/tests/ioctl.test b/strace/tests/ioctl.test
new file mode 100755
index 0000000..94bc5d4
--- /dev/null
+++ b/strace/tests/ioctl.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check ioctl syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a16 -eioctl $args > "$EXP"
+check_prog grep
+grep -v '^ioctl([012],' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/ioctl_block.c b/strace/tests/ioctl_block.c
new file mode 100644
index 0000000..3dc030d
--- /dev/null
+++ b/strace/tests/ioctl_block.c
@@ -0,0 +1,213 @@
+/*
+ * This file is part of ioctl_block strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <inttypes.h>
+#include <stdio.h>
+#include <string.h>
+#include <sys/ioctl.h>
+#include <linux/fs.h>
+#include <linux/blkpg.h>
+#ifdef HAVE_STRUCT_BLK_USER_TRACE_SETUP
+# include <linux/blktrace_api.h>
+#endif
+#include "xlat.h"
+
+static const unsigned int magic = 0xdeadbeef;
+static const unsigned long lmagic = (unsigned long) 0xdeadbeefbadc0ded;
+
+static void
+init_magic(void *addr, const unsigned int size)
+{
+	unsigned int *p = addr;
+	const unsigned int *end = addr + size - sizeof(int);
+
+	for (; p <= end; ++p)
+		*(unsigned int *) p = magic;
+}
+
+static struct xlat block_argless[] = {
+	XLAT(BLKRRPART),
+	XLAT(BLKFLSBUF),
+#ifdef BLKTRACESTART
+	XLAT(BLKTRACESTART),
+#endif
+#ifdef BLKTRACESTOP
+	XLAT(BLKTRACESTOP),
+#endif
+#ifdef BLKTRACETEARDOWN
+	XLAT(BLKTRACETEARDOWN),
+#endif
+};
+
+#define TEST_NULL_ARG(cmd) \
+	ioctl(-1, cmd, 0); \
+	printf("ioctl(-1, %s, NULL) = -1 EBADF (%m)\n", #cmd)
+
+int
+main(void)
+{
+	TEST_NULL_ARG(BLKBSZGET);
+	TEST_NULL_ARG(BLKBSZSET);
+	TEST_NULL_ARG(BLKFRAGET);
+	TEST_NULL_ARG(BLKGETSIZE);
+	TEST_NULL_ARG(BLKGETSIZE64);
+	TEST_NULL_ARG(BLKPG);
+	TEST_NULL_ARG(BLKRAGET);
+	TEST_NULL_ARG(BLKROGET);
+	TEST_NULL_ARG(BLKROSET);
+	TEST_NULL_ARG(BLKSECTGET);
+	TEST_NULL_ARG(BLKSECTGET);
+	TEST_NULL_ARG(BLKSSZGET);
+#ifdef BLKALIGNOFF
+	TEST_NULL_ARG(BLKALIGNOFF);
+#endif
+#ifdef BLKDISCARD
+	TEST_NULL_ARG(BLKDISCARD);
+#endif
+#ifdef BLKDISCARDZEROES
+	TEST_NULL_ARG(BLKDISCARDZEROES);
+#endif
+#ifdef BLKIOMIN
+	TEST_NULL_ARG(BLKIOMIN);
+#endif
+#ifdef BLKIOOPT
+	TEST_NULL_ARG(BLKIOOPT);
+#endif
+#ifdef BLKPBSZGET
+	TEST_NULL_ARG(BLKPBSZGET);
+#endif
+#ifdef BLKROTATIONAL
+	TEST_NULL_ARG(BLKROTATIONAL);
+#endif
+#ifdef BLKSECDISCARD
+	TEST_NULL_ARG(BLKSECDISCARD);
+#endif
+#ifdef BLKZEROOUT
+	TEST_NULL_ARG(BLKZEROOUT);
+#endif
+#if defined BLKTRACESETUP && defined HAVE_STRUCT_BLK_USER_TRACE_SETUP
+	TEST_NULL_ARG(BLKTRACESETUP);
+#endif
+
+	ioctl(-1, BLKRASET, lmagic);
+	printf("ioctl(-1, BLKRASET, %lu) = -1 EBADF (%m)\n", lmagic);
+
+	ioctl(-1, BLKFRASET, lmagic);
+	printf("ioctl(-1, BLKFRASET, %lu) = -1 EBADF (%m)\n", lmagic);
+
+	int *const val_int = tail_alloc(sizeof(*val_int));
+	*val_int = magic;
+
+	ioctl(-1, BLKROSET, val_int);
+	printf("ioctl(-1, BLKROSET, [%d]) = -1 EBADF (%m)\n", *val_int);
+
+	ioctl(-1, BLKBSZSET, val_int);
+	printf("ioctl(-1, BLKBSZSET, [%d]) = -1 EBADF (%m)\n", *val_int);
+
+	uint64_t *pair_int64 = tail_alloc(sizeof(*pair_int64) * 2);
+	pair_int64[0] = 0xdeadbeefbadc0ded;
+	pair_int64[1] = 0xfacefeedcafef00d;
+
+#ifdef BLKDISCARD
+	ioctl(-1, BLKDISCARD, pair_int64);
+	printf("ioctl(-1, BLKDISCARD, [%" PRIu64 ", %" PRIu64 "])"
+	       " = -1 EBADF (%m)\n", pair_int64[0], pair_int64[1]);
+#endif
+
+#ifdef BLKSECDISCARD
+	ioctl(-1, BLKSECDISCARD, pair_int64);
+	printf("ioctl(-1, BLKSECDISCARD, [%" PRIu64 ", %" PRIu64 "])"
+	       " = -1 EBADF (%m)\n", pair_int64[0], pair_int64[1]);
+#endif
+
+#ifdef BLKZEROOUT
+	ioctl(-1, BLKZEROOUT, pair_int64);
+	printf("ioctl(-1, BLKZEROOUT, [%" PRIu64 ", %" PRIu64 "])"
+	       " = -1 EBADF (%m)\n", pair_int64[0], pair_int64[1]);
+#endif
+
+	struct blkpg_ioctl_arg *const blkpg = tail_alloc(sizeof(*blkpg));
+	blkpg->op = 3;
+	blkpg->flags = 0xdeadbeef;
+	blkpg->datalen = 0xbadc0ded;
+	blkpg->data = (void *) (unsigned long) 0xcafef00dfffffeed;
+
+	ioctl(-1, BLKPG, blkpg);
+	printf("ioctl(-1, BLKPG, {%s, flags=%d, datalen=%d"
+	       ", data=%#lx}) = -1 EBADF (%m)\n",
+	       "BLKPG_RESIZE_PARTITION", blkpg->flags, blkpg->datalen,
+	       (unsigned long) blkpg->data);
+
+	struct blkpg_partition *const bp = tail_alloc(sizeof(*bp));
+	bp->start = 0xfac1fed2dad3bef4;
+	bp->length = 0xfac5fed6dad7bef8;
+	bp->pno = magic;
+	memset(bp->devname, 'A', sizeof(bp->devname));
+	memset(bp->volname, 'B', sizeof(bp->volname));
+	blkpg->op = 1;
+	blkpg->data = bp;
+
+	ioctl(-1, BLKPG, blkpg);
+	printf("ioctl(-1, BLKPG, {%s, flags=%d, datalen=%d"
+	       ", data={start=%lld, length=%lld, pno=%d"
+	       ", devname=\"%.*s\", volname=\"%.*s\"}})"
+	       " = -1 EBADF (%m)\n",
+	       "BLKPG_ADD_PARTITION",
+	       blkpg->flags, blkpg->datalen,
+	       bp->start, bp->length, bp->pno,
+	       (int) sizeof(bp->devname) - 1, bp->devname,
+	       (int) sizeof(bp->volname) - 1, bp->volname);
+
+#if defined BLKTRACESETUP && defined HAVE_STRUCT_BLK_USER_TRACE_SETUP
+	struct blk_user_trace_setup *const buts = tail_alloc(sizeof(*buts));
+	init_magic(buts, sizeof(*buts));
+
+	ioctl(-1, BLKTRACESETUP, buts);
+	printf("ioctl(-1, BLKTRACESETUP, {act_mask=%hu, buf_size=%u, buf_nr=%u"
+	       ", start_lba=%" PRI__u64 ", end_lba=%" PRI__u64 ", pid=%u})"
+	       " = -1 EBADF (%m)\n",
+	       buts->act_mask, buts->buf_size, buts->buf_nr,
+	       buts->start_lba, buts->end_lba, buts->pid);
+#endif
+
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(block_argless); ++i) {
+		ioctl(-1, (unsigned long) block_argless[i].val, lmagic);
+		printf("ioctl(-1, %s) = -1 EBADF (%m)\n", block_argless[i].str);
+	}
+
+	ioctl(-1, _IOC(_IOC_READ, 0x12, 0xfe, 0xff), lmagic);
+	printf("ioctl(-1, %s, %#lx) = -1 EBADF (%m)\n",
+	       "_IOC(_IOC_READ, 0x12, 0xfe, 0xff)", lmagic);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/ioctl_block.test b/strace/tests/ioctl_block.test
new file mode 100755
index 0000000..0bf2500
--- /dev/null
+++ b/strace/tests/ioctl_block.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of BLK* ioctls.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/ioctl_evdev-v.c b/strace/tests/ioctl_evdev-v.c
new file mode 100644
index 0000000..6f1adcf
--- /dev/null
+++ b/strace/tests/ioctl_evdev-v.c
@@ -0,0 +1,3 @@
+/* This file is part of ioctl_evdev-v strace test. */
+#define VERBOSE_IOCTL
+#include "ioctl_evdev.c"
diff --git a/strace/tests/ioctl_evdev-v.test b/strace/tests/ioctl_evdev-v.test
new file mode 100755
index 0000000..8794101
--- /dev/null
+++ b/strace/tests/ioctl_evdev-v.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check verbose decoding EVIOC* ioctls.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a16 -veioctl $args > "$EXP"
+check_prog grep
+grep -v '^ioctl([012],' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/ioctl_evdev.c b/strace/tests/ioctl_evdev.c
new file mode 100644
index 0000000..5040b1c
--- /dev/null
+++ b/strace/tests/ioctl_evdev.c
@@ -0,0 +1,284 @@
+/*
+ * This file is part of ioctl_evdev strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#ifdef HAVE_LINUX_INPUT_H
+
+# include <errno.h>
+# include <inttypes.h>
+# include <stdio.h>
+# include <string.h>
+# include <sys/ioctl.h>
+# include <linux/input.h>
+
+static const unsigned int magic = 0xdeadbeef;
+static const unsigned long lmagic = (unsigned long) 0xdeadbeefbadc0ded;
+
+static void
+init_magic(void *addr, const unsigned int size)
+{
+	unsigned int *p = addr;
+	const unsigned int *end = addr + size - sizeof(int);
+
+	for (; p <= end; ++p)
+		*(unsigned int *) p = magic;
+}
+
+# ifdef VERBOSE_IOCTL
+static void
+print_envelope(const struct ff_envelope *const e)
+{
+	printf(", envelope={attack_length=%hu, attack_level=%hu"
+	       ", fade_length=%hu, fade_level=%#hx}",
+	       e->attack_length, e->attack_level,
+	       e->fade_length, e->fade_level);
+}
+# endif /* VERBOSE_IOCTL */
+
+static void
+print_ffe_common(const struct ff_effect *const ffe, const char *const type_str)
+{
+	printf("ioctl(-1, EVIOCSFF, {type=%s, id=%" PRIu16
+	       ", direction=%" PRIu16 ", ",
+	       type_str, ffe->id, ffe->direction);
+# ifdef VERBOSE_IOCTL
+	printf("trigger={button=%hu, interval=%hu}"
+	       ", replay={length=%hu, delay=%hu}",
+	       ffe->trigger.button, ffe->trigger.interval,
+	       ffe->replay.length, ffe->replay.delay);
+# endif /* VERBOSE_IOCTL */
+}
+
+# define TEST_NULL_ARG(cmd) \
+	ioctl(-1, cmd, 0); \
+	printf("ioctl(-1, %s, NULL) = -1 EBADF (%m)\n", #cmd)
+
+int
+main(void)
+{
+	TEST_NULL_ARG(EVIOCGVERSION);
+	TEST_NULL_ARG(EVIOCGEFFECTS);
+	TEST_NULL_ARG(EVIOCGID);
+	TEST_NULL_ARG(EVIOCGKEYCODE);
+	TEST_NULL_ARG(EVIOCSKEYCODE);
+	TEST_NULL_ARG(EVIOCSFF);
+# ifdef EVIOCGKEYCODE_V2
+	TEST_NULL_ARG(EVIOCGKEYCODE_V2);
+# endif
+# ifdef EVIOCSKEYCODE_V2
+	TEST_NULL_ARG(EVIOCSKEYCODE_V2);
+# endif
+# ifdef EVIOCGREP
+	TEST_NULL_ARG(EVIOCGREP);
+# endif
+# ifdef EVIOCSREP
+	TEST_NULL_ARG(EVIOCSREP);
+# endif
+# ifdef EVIOCSCLOCKID
+	TEST_NULL_ARG(EVIOCSCLOCKID);
+# endif
+
+	TEST_NULL_ARG(EVIOCGNAME(0));
+	TEST_NULL_ARG(EVIOCGPHYS(0));
+	TEST_NULL_ARG(EVIOCGUNIQ(0));
+	TEST_NULL_ARG(EVIOCGKEY(0));
+	TEST_NULL_ARG(EVIOCGLED(0));
+# ifdef EVIOCGMTSLOTS
+	TEST_NULL_ARG(EVIOCGMTSLOTS(0));
+# endif
+# ifdef EVIOCGPROP
+	TEST_NULL_ARG(EVIOCGPROP(0));
+# endif
+	TEST_NULL_ARG(EVIOCGSND(0));
+# ifdef EVIOCGSW
+	TEST_NULL_ARG(EVIOCGSW(0));
+# endif
+
+	TEST_NULL_ARG(EVIOCGABS(ABS_X));
+	TEST_NULL_ARG(EVIOCSABS(ABS_X));
+
+	TEST_NULL_ARG(EVIOCGBIT(EV_SYN, 0));
+	TEST_NULL_ARG(EVIOCGBIT(EV_KEY, 1));
+	TEST_NULL_ARG(EVIOCGBIT(EV_REL, 2));
+	TEST_NULL_ARG(EVIOCGBIT(EV_ABS, 3));
+	TEST_NULL_ARG(EVIOCGBIT(EV_MSC, 4));
+# ifdef EV_SW
+	TEST_NULL_ARG(EVIOCGBIT(EV_SW, 5));
+# endif
+	TEST_NULL_ARG(EVIOCGBIT(EV_LED, 6));
+	TEST_NULL_ARG(EVIOCGBIT(EV_SND, 7));
+	TEST_NULL_ARG(EVIOCGBIT(EV_REP, 8));
+	TEST_NULL_ARG(EVIOCGBIT(EV_FF, 9));
+	TEST_NULL_ARG(EVIOCGBIT(EV_PWR, 10));
+	TEST_NULL_ARG(EVIOCGBIT(EV_FF_STATUS, 11));
+
+	ioctl(-1, EVIOCGBIT(EV_MAX, 42), 0);
+	printf("ioctl(-1, EVIOCGBIT(%#x /* EV_??? */, 42), NULL)"
+	       " = -1 EBADF (%m)\n", EV_MAX);
+
+	ioctl(-1, EVIOCRMFF, lmagic);
+	printf("ioctl(-1, EVIOCRMFF, %d) = -1 EBADF (%m)\n", (int) lmagic);
+
+	ioctl(-1, EVIOCGRAB, lmagic);
+	printf("ioctl(-1, EVIOCGRAB, %lu) = -1 EBADF (%m)\n", lmagic);
+
+# ifdef EVIOCREVOKE
+	ioctl(-1, EVIOCREVOKE, lmagic);
+	printf("ioctl(-1, EVIOCREVOKE, %lu) = -1 EBADF (%m)\n", lmagic);
+# endif
+
+	const unsigned int size = get_page_size();
+	void *const page = tail_alloc(size);
+	init_magic(page, size);
+
+	int *const val_int = tail_alloc(sizeof(*val_int));
+	*val_int = magic;
+
+# ifdef EVIOCSCLOCKID
+	ioctl(-1, EVIOCSCLOCKID, val_int);
+	printf("ioctl(-1, EVIOCSCLOCKID, [%u]) = -1 EBADF (%m)\n", *val_int);
+# endif
+
+	int *pair_int = tail_alloc(sizeof(*pair_int) * 2);
+	pair_int[0] = 0xdeadbeef;
+	pair_int[1] = 0xbadc0ded;
+
+# ifdef EVIOSGREP
+	ioctl(-1, EVIOCSREP, pair_int);
+	printf("ioctl(-1, EVIOCSREP, [%u, %u]) = -1 EBADF (%m)\n",
+	       pair_int[0], pair_int[1]);
+# endif
+
+	pair_int[1] = 1;
+	ioctl(-1, EVIOCSKEYCODE, pair_int);
+	printf("ioctl(-1, EVIOCSKEYCODE, [%u, %s]) = -1 EBADF (%m)\n",
+	       pair_int[0], "KEY_ESC");
+
+# ifdef EVIOCSKEYCODE_V2
+	struct input_keymap_entry *const ike = tail_alloc(sizeof(*ike));
+	init_magic(ike, sizeof(*ike));
+	ike->keycode = 2;
+
+	ioctl(-1, EVIOCSKEYCODE_V2, ike);
+	printf("ioctl(-1, EVIOCSKEYCODE_V2, {flags=%" PRIu8
+	       ", len=%" PRIu8 ", ", ike->flags, ike->len);
+#  ifdef VERBOSE_IOCTL
+	printf("index=%" PRIu16 ", keycode=%s, scancode=[",
+	       ike->index, "KEY_1");
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(ike->scancode); ++i) {
+		if (i > 0)
+			printf(", ");
+		printf("%" PRIx8, ike->scancode[i]);
+	}
+	printf("]");
+#  else
+	printf("...");
+#  endif
+	errno = EBADF;
+	printf("}) = -1 EBADF (%m)\n");
+# endif
+
+	struct ff_effect *const ffe = tail_alloc(sizeof(*ffe));
+	init_magic(ffe, sizeof(*ffe));
+
+	ffe->type = FF_CONSTANT;
+	ioctl(-1, EVIOCSFF, ffe);
+	print_ffe_common(ffe, "FF_CONSTANT");
+
+#  ifdef VERBOSE_IOCTL
+	printf(", constant={level=%hd", ffe->u.constant.level);
+	print_envelope(&ffe->u.constant.envelope);
+	printf("}");
+#  else
+	printf("...");
+#  endif
+	errno = EBADF;
+	printf("}) = -1 EBADF (%m)\n");
+
+#  ifdef VERBOSE_IOCTL
+	ffe->type = FF_RAMP;
+	ioctl(-1, EVIOCSFF, ffe);
+	print_ffe_common(ffe, "FF_RAMP");
+	printf(", ramp={start_level=%hd, end_level=%hd",
+	       ffe->u.ramp.start_level, ffe->u.ramp.end_level);
+	print_envelope(&ffe->u.ramp.envelope);
+	errno = EBADF;
+	printf("}}) = -1 EBADF (%m)\n");
+
+	ffe->type = FF_PERIODIC;
+	ioctl(-1, EVIOCSFF, ffe);
+	print_ffe_common(ffe, "FF_PERIODIC");
+	printf(", periodic={waveform=%hu, period=%hu, magnitude=%hd"
+	       ", offset=%hd, phase=%hu",
+	       ffe->u.periodic.waveform, ffe->u.periodic.period,
+	       ffe->u.periodic.magnitude, ffe->u.periodic.offset,
+	       ffe->u.periodic.phase);
+	print_envelope(&ffe->u.periodic.envelope);
+	printf(", custom_len=%u, custom_data=%p}",
+	       ffe->u.periodic.custom_len, ffe->u.periodic.custom_data);
+	errno = EBADF;
+	printf("}) = -1 EBADF (%m)\n");
+
+	ffe->type = FF_RUMBLE;
+	ioctl(-1, EVIOCSFF, ffe);
+	print_ffe_common(ffe, "FF_RUMBLE");
+	printf(", rumble={strong_magnitude=%hu, weak_magnitude=%hu}",
+	       ffe->u.rumble.strong_magnitude, ffe->u.rumble.weak_magnitude);
+	errno = EBADF;
+	printf("}) = -1 EBADF (%m)\n");
+
+	ffe->type = 0xff;
+	ioctl(-1, EVIOCSFF, ffe);
+	print_ffe_common(ffe, "0xff /* FF_??? */");
+	errno = EBADF;
+	printf("}) = -1 EBADF (%m)\n");
+#  endif
+
+	ioctl(-1, _IOC(_IOC_READ, 0x45, 0x01, 0xff), lmagic);
+	printf("ioctl(-1, %s, %#lx) = -1 EBADF (%m)\n",
+	       "_IOC(_IOC_READ, 0x45, 0x01, 0xff)", lmagic);
+
+	ioctl(-1, _IOC(_IOC_WRITE, 0x45, 0x01, 0xff), lmagic);
+	printf("ioctl(-1, %s, %#lx) = -1 EBADF (%m)\n",
+	       "_IOC(_IOC_WRITE, 0x45, 0x01, 0xff)", lmagic);
+
+	ioctl(-1, _IOC(_IOC_READ|_IOC_WRITE, 0x45, 0xfe, 0xff), lmagic);
+	printf("ioctl(-1, %s, %#lx) = -1 EBADF (%m)\n",
+	       "_IOC(_IOC_READ|_IOC_WRITE, 0x45, 0xfe, 0xff)", lmagic);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_LINUX_INPUT_H")
+
+#endif
diff --git a/strace/tests/ioctl_evdev.test b/strace/tests/ioctl_evdev.test
new file mode 100755
index 0000000..7ed2e98
--- /dev/null
+++ b/strace/tests/ioctl_evdev.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of EVIOC* ioctls.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/ioctl_mtd.c b/strace/tests/ioctl_mtd.c
new file mode 100644
index 0000000..b761da8
--- /dev/null
+++ b/strace/tests/ioctl_mtd.c
@@ -0,0 +1,208 @@
+/*
+ * This file is part of ioctl_mtd strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <errno.h>
+#include <inttypes.h>
+#include <stdio.h>
+#include <string.h>
+#include <sys/ioctl.h>
+#include <linux/ioctl.h>
+#include <linux/version.h>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 3, 0)
+# include "mtd-abi.h"
+#else
+# include <mtd/mtd-abi.h>
+#endif
+
+static const unsigned int magic = 0xdeadbeef;
+static const unsigned long lmagic = (unsigned long) 0xdeadbeefbadc0ded;
+
+static void
+init_magic(void *addr, const unsigned int size)
+{
+	unsigned int *p = addr;
+	const unsigned int *end = addr + size - sizeof(int);
+
+	for (; p <= end; ++p)
+		*(unsigned int *) p = magic;
+}
+
+#define TEST_NULL_ARG(cmd) \
+	do { \
+		ioctl(-1, cmd, 0); \
+		if (_IOC_DIR(cmd) == _IOC_WRITE) \
+			printf("ioctl(-1, MIXER_WRITE(%u) or %s, NULL)" \
+			       " = -1 EBADF (%m)\n", \
+			       (unsigned int) _IOC_NR(cmd), #cmd); \
+		else if (_IOC_DIR(cmd) == _IOC_READ) \
+			printf("ioctl(-1, MIXER_READ(%u) or %s, NULL)" \
+			       " = -1 EBADF (%m)\n", \
+			       (unsigned int) _IOC_NR(cmd), #cmd); \
+		else \
+			printf("ioctl(-1, %s, NULL) = -1 EBADF (%m)\n", #cmd); \
+		} while (0)
+
+#define TEST_erase_info_user(cmd, eiu) \
+	ioctl(-1, cmd, eiu); \
+	printf("ioctl(-1, MIXER_%s(%u) or %s, {start=%#x, length=%#x})" \
+	       " = -1 EBADF (%m)\n", \
+	       (_IOC_DIR(cmd) == _IOC_READ) ? "READ" : "WRITE", \
+	       (unsigned int) _IOC_NR(cmd), #cmd, \
+	       eiu->start, eiu->length)
+
+int
+main(void)
+{
+	TEST_NULL_ARG(ECCGETLAYOUT);
+	TEST_NULL_ARG(ECCGETSTATS);
+	TEST_NULL_ARG(MEMERASE);
+	TEST_NULL_ARG(MEMERASE64);
+	TEST_NULL_ARG(MEMGETBADBLOCK);
+	TEST_NULL_ARG(MEMGETINFO);
+	TEST_NULL_ARG(MEMGETOOBSEL);
+	TEST_NULL_ARG(MEMGETREGIONCOUNT);
+	TEST_NULL_ARG(MEMISLOCKED);
+	TEST_NULL_ARG(MEMLOCK);
+	TEST_NULL_ARG(MEMREADOOB);
+	TEST_NULL_ARG(MEMREADOOB64);
+	TEST_NULL_ARG(MEMSETBADBLOCK);
+	TEST_NULL_ARG(MEMUNLOCK);
+	TEST_NULL_ARG(MEMWRITE);
+	TEST_NULL_ARG(MEMWRITEOOB);
+	TEST_NULL_ARG(MEMWRITEOOB64);
+	TEST_NULL_ARG(OTPGETREGIONCOUNT);
+	TEST_NULL_ARG(OTPGETREGIONINFO);
+	TEST_NULL_ARG(OTPLOCK);
+	TEST_NULL_ARG(OTPSELECT);
+
+	ioctl(-1, MTDFILEMODE, MTD_FILE_MODE_NORMAL);
+	printf("ioctl(-1, MTDFILEMODE, MTD_FILE_MODE_NORMAL) = -1 EBADF (%m)\n");
+
+	int *const opt = tail_alloc(sizeof(*opt));
+	*opt = MTD_OTP_OFF;
+	ioctl(-1, OTPSELECT, opt);
+	printf("ioctl(-1, MIXER_READ(%u) or OTPSELECT, [MTD_OTP_OFF])"
+	       " = -1 EBADF (%m)\n", (unsigned int) _IOC_NR(OTPSELECT));
+
+	uint64_t *const v64 = tail_alloc(sizeof(*v64));
+	init_magic(v64, sizeof(*v64));
+
+	ioctl(-1, MEMGETBADBLOCK, v64);
+	printf("ioctl(-1, MIXER_WRITE(%u) or MEMGETBADBLOCK, [%" PRIu64 "])"
+	       " = -1 EBADF (%m)\n",
+	       (unsigned int) _IOC_NR(MEMGETBADBLOCK), *v64);
+
+	ioctl(-1, MEMSETBADBLOCK, v64);
+	printf("ioctl(-1, MIXER_WRITE(%u) or MEMSETBADBLOCK, [%" PRIu64 "])"
+	       " = -1 EBADF (%m)\n",
+	       (unsigned int) _IOC_NR(MEMSETBADBLOCK), *v64);
+
+	struct region_info_user *const riu = tail_alloc(sizeof(*riu));
+	init_magic(riu, sizeof(*riu));
+	ioctl(-1, MEMGETREGIONINFO, riu);
+	printf("ioctl(-1, %s, {regionindex=%#x}) = -1 EBADF (%m)\n",
+	       "MEMGETREGIONINFO"
+#ifdef __i386__
+	       " or MTRRIOC_GET_PAGE_ENTRY"
+#endif
+	       , riu->regionindex);
+
+	struct erase_info_user *const eiu = tail_alloc(sizeof(*eiu));
+	init_magic(eiu, sizeof(*eiu));
+
+	TEST_erase_info_user(MEMERASE, eiu);
+	TEST_erase_info_user(MEMLOCK, eiu);
+	TEST_erase_info_user(MEMUNLOCK, eiu);
+	TEST_erase_info_user(MEMISLOCKED, eiu);
+
+	struct erase_info_user64 *const eiu64 = tail_alloc(sizeof(*eiu64));
+	init_magic(eiu64, sizeof(*eiu64));
+	ioctl(-1, MEMERASE64, eiu64);
+	printf("ioctl(-1, MIXER_WRITE(%u) or %s, {start=%#llx, length=%#llx})"
+	       " = -1 EBADF (%m)\n",
+	       (unsigned int) _IOC_NR(MEMERASE64), "MEMERASE64",
+	       (unsigned long long) eiu64->start,
+	       (unsigned long long) eiu64->length);
+
+	struct mtd_oob_buf *const oob = tail_alloc(sizeof(*oob));
+	init_magic(oob, sizeof(*oob));
+
+	ioctl(-1, MEMWRITEOOB, oob);
+	printf("ioctl(-1, MEMWRITEOOB, {start=%#x, length=%#x, ptr=%p})"
+	       " = -1 EBADF (%m)\n", oob->start, oob->length, oob->ptr);
+
+	ioctl(-1, MEMREADOOB, oob);
+	printf("ioctl(-1, MEMREADOOB, {start=%#x, length=%#x, ptr=%p})"
+	       " = -1 EBADF (%m)\n", oob->start, oob->length, oob->ptr);
+
+	struct mtd_oob_buf64 *const oob64 = tail_alloc(sizeof(*oob64));
+	init_magic(oob64, sizeof(*oob64));
+
+	ioctl(-1, MEMWRITEOOB64, oob64);
+	printf("ioctl(-1, MEMWRITEOOB64"
+	       ", {start=%#llx, length=%#x, usr_ptr=%#llx}) = -1 EBADF (%m)\n",
+	       (unsigned long long) oob64->start, oob64->length,
+	       (unsigned long long) oob64->usr_ptr);
+
+	ioctl(-1, MEMREADOOB64, oob64);
+	printf("ioctl(-1, MEMREADOOB64"
+	       ", {start=%#llx, length=%#x, usr_ptr=%#llx}) = -1 EBADF (%m)\n",
+	       (unsigned long long) oob64->start, oob64->length,
+	       (unsigned long long) oob64->usr_ptr);
+
+
+	struct otp_info *const oi = tail_alloc(sizeof(*oi));
+	init_magic(oi, sizeof(*oi));
+	ioctl(-1, OTPLOCK, oi);
+	printf("ioctl(-1, MIXER_READ(%u) or OTPLOCK"
+	       ", {start=%#x, length=%#x, locked=%u}) = -1 EBADF (%m)\n",
+	       (unsigned int) _IOC_NR(OTPLOCK),  oi->start, oi->length, oi->locked);
+
+	struct mtd_write_req *const wr = tail_alloc(sizeof(*wr));
+	init_magic(wr, sizeof(*wr));
+	wr->mode = MTD_OPS_PLACE_OOB;
+	ioctl(-1, MEMWRITE, wr);
+	printf("ioctl(-1, MEMWRITE, {start=%#llx, len=%#llx, ooblen=%#llx"
+	       ", usr_data=%#llx, usr_oob=%#llx, mode=MTD_OPS_PLACE_OOB})"
+	       " = -1 EBADF (%m)\n",
+	       (unsigned long long) wr->start,
+	       (unsigned long long) wr->len,
+	       (unsigned long long) wr->ooblen,
+	       (unsigned long long) wr->usr_data,
+	       (unsigned long long) wr->usr_oob);
+
+	ioctl(-1, _IOC(_IOC_READ|_IOC_WRITE, 0x4d, 0xfe, 0xff), lmagic);
+	printf("ioctl(-1, %s, %#lx) = -1 EBADF (%m)\n",
+	       "_IOC(_IOC_READ|_IOC_WRITE, 0x4d, 0xfe, 0xff)", lmagic);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/ioctl_mtd.test b/strace/tests/ioctl_mtd.test
new file mode 100755
index 0000000..0842807
--- /dev/null
+++ b/strace/tests/ioctl_mtd.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of 'M' type ioctls.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/ioctl_rtc-v.c b/strace/tests/ioctl_rtc-v.c
new file mode 100644
index 0000000..abdace1
--- /dev/null
+++ b/strace/tests/ioctl_rtc-v.c
@@ -0,0 +1,3 @@
+/* This file is part of ioctl_rtc-v strace test. */
+#define VERBOSE_IOCTL
+#include "ioctl_rtc.c"
diff --git a/strace/tests/ioctl_rtc-v.test b/strace/tests/ioctl_rtc-v.test
new file mode 100755
index 0000000..a255322
--- /dev/null
+++ b/strace/tests/ioctl_rtc-v.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check verbose decoding of RTC_* ioctls.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a16 -veioctl $args > "$EXP"
+check_prog grep
+grep -v '^ioctl([012],' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/ioctl_rtc.c b/strace/tests/ioctl_rtc.c
new file mode 100644
index 0000000..ee09955
--- /dev/null
+++ b/strace/tests/ioctl_rtc.c
@@ -0,0 +1,218 @@
+/*
+ * This file is part of ioctl_rtc strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <stdio.h>
+#include <string.h>
+#include <sys/ioctl.h>
+#include <linux/types.h>
+#include <linux/rtc.h>
+#include "xlat.h"
+
+static const unsigned int magic = 0xdeadbeef;
+static const unsigned long lmagic = (unsigned long) 0xdeadbeefbadc0ded;
+
+static void
+init_magic(void *addr, const unsigned int size)
+{
+	unsigned int *p = addr;
+	const unsigned int *end = addr + size - sizeof(int);
+
+	for (; p <= end; ++p)
+		*(unsigned int *) p = magic;
+}
+
+static void
+print_rtc_time(const struct rtc_time *rt)
+{
+	printf("{tm_sec=%d, tm_min=%d, tm_hour=%d"
+	       ", tm_mday=%d, tm_mon=%d, tm_year=%d",
+	       rt->tm_sec, rt->tm_min, rt->tm_hour,
+	       rt->tm_mday, rt->tm_mon, rt->tm_year);
+#ifdef VERBOSE_IOCTL
+	printf(", tm_wday=%d, tm_yday=%d, tm_isdst=%d}",
+	       rt->tm_wday, rt->tm_yday, rt->tm_isdst);
+#else
+	printf(", ...}");
+#endif
+}
+
+static struct xlat rtc_argless[] = {
+	XLAT(RTC_AIE_OFF),
+	XLAT(RTC_PIE_ON),
+	XLAT(RTC_PIE_OFF),
+	XLAT(RTC_UIE_ON),
+	XLAT(RTC_WIE_ON),
+	XLAT(RTC_WIE_OFF),
+#ifdef RTC_VL_CLR
+	XLAT(RTC_VL_CLR),
+#endif
+};
+
+int
+main(void)
+{
+	const unsigned int size = get_page_size();
+
+	void *const page = tail_alloc(size);
+	init_magic(page, size);
+
+	struct rtc_time *rt = tail_alloc(sizeof(*rt));
+	init_magic(rt, sizeof(*rt));
+
+	struct rtc_wkalrm *wk = tail_alloc(sizeof(*wk));
+	init_magic(wk, sizeof(*wk));
+
+	struct rtc_pll_info *pll = tail_alloc(sizeof(*pll));
+	init_magic(pll, sizeof(*pll));
+
+	/* RTC_ALM_READ */
+	ioctl(-1, RTC_ALM_READ, 0);
+	printf("ioctl(-1, RTC_ALM_READ, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_ALM_READ, page);
+	printf("ioctl(-1, RTC_ALM_READ, %p) = -1 EBADF (%m)\n", page);
+
+	/* RTC_RD_TIME */
+	ioctl(-1, RTC_RD_TIME, 0);
+	printf("ioctl(-1, RTC_RD_TIME, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_RD_TIME, page);
+	printf("ioctl(-1, RTC_RD_TIME, %p) = -1 EBADF (%m)\n", page);
+
+	/* RTC_ALM_SET */
+	ioctl(-1, RTC_ALM_SET, 0);
+	printf("ioctl(-1, RTC_ALM_SET, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_ALM_SET, rt);
+	printf("ioctl(-1, RTC_ALM_SET, ");
+	print_rtc_time(rt);
+	errno = EBADF;
+	printf(") = -1 EBADF (%m)\n");
+
+	/* RTC_SET_TIME */
+	ioctl(-1, RTC_SET_TIME, 0);
+	printf("ioctl(-1, RTC_SET_TIME, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_SET_TIME, rt);
+	printf("ioctl(-1, RTC_SET_TIME, ");
+	print_rtc_time(rt);
+	errno = EBADF;
+	printf(") = -1 EBADF (%m)\n");
+
+	/* RTC_IRQP_SET */
+	ioctl(-1, RTC_IRQP_SET, lmagic);
+	printf("ioctl(-1, RTC_IRQP_SET, %lu) = -1 EBADF (%m)\n", lmagic);
+
+	/* RTC_EPOCH_SET */
+	ioctl(-1, RTC_EPOCH_SET, lmagic);
+	printf("ioctl(-1, RTC_EPOCH_SET, %lu) = -1 EBADF (%m)\n", lmagic);
+
+	/* RTC_IRQP_READ */
+	ioctl(-1, RTC_IRQP_READ, 0);
+	printf("ioctl(-1, RTC_IRQP_READ, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_IRQP_READ, page);
+	printf("ioctl(-1, RTC_IRQP_READ, %p) = -1 EBADF (%m)\n", page);
+
+	/* RTC_EPOCH_READ */
+	ioctl(-1, RTC_EPOCH_READ, 0);
+	printf("ioctl(-1, RTC_EPOCH_READ, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_EPOCH_READ, page);
+	printf("ioctl(-1, RTC_EPOCH_READ, %p) = -1 EBADF (%m)\n", page);
+
+	/* RTC_WKALM_RD */
+	ioctl(-1, RTC_WKALM_RD, 0);
+	printf("ioctl(-1, RTC_WKALM_RD, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_WKALM_RD, page);
+	printf("ioctl(-1, RTC_WKALM_RD, %p) = -1 EBADF (%m)\n", page);
+
+	/* RTC_WKALM_SET */
+	ioctl(-1, RTC_WKALM_SET, 0);
+	printf("ioctl(-1, RTC_WKALM_SET, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_WKALM_SET, wk);
+	printf("ioctl(-1, RTC_WKALM_SET, {enabled=%u, pending=%u, time=",
+	       (unsigned) wk->enabled, (unsigned) wk->pending);
+	print_rtc_time(&wk->time);
+	errno = EBADF;
+	printf("}) = -1 EBADF (%m)\n");
+
+	/* RTC_PLL_GET */
+	ioctl(-1, RTC_PLL_GET, 0);
+	printf("ioctl(-1, RTC_PLL_GET, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_PLL_GET, page);
+	printf("ioctl(-1, RTC_PLL_GET, %p) = -1 EBADF (%m)\n", page);
+
+	/* RTC_PLL_SET */
+	ioctl(-1, RTC_PLL_SET, 0);
+	printf("ioctl(-1, RTC_PLL_SET, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_PLL_SET, pll);
+	printf("ioctl(-1, RTC_PLL_SET, {pll_ctrl=%d, pll_value=%d"
+	       ", pll_max=%d, pll_min=%d, pll_posmult=%d, pll_negmult=%d"
+	       ", pll_clock=%ld}) = -1 EBADF (%m)\n",
+	       pll->pll_ctrl, pll->pll_value, pll->pll_max, pll->pll_min,
+	       pll->pll_posmult, pll->pll_negmult, pll->pll_clock);
+
+#ifdef RTC_VL_READ
+	/* RTC_VL_READ */
+	ioctl(-1, RTC_VL_READ, 0);
+	printf("ioctl(-1, RTC_VL_READ, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, RTC_VL_READ, page);
+	printf("ioctl(-1, RTC_VL_READ, %p) = -1 EBADF (%m)\n", page);
+#endif
+
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(rtc_argless); ++i) {
+		ioctl(-1, (unsigned long) rtc_argless[i].val, lmagic);
+		printf("ioctl(-1, %s) = -1 EBADF (%m)\n", rtc_argless[i].str);
+	}
+
+	ioctl(-1, RTC_UIE_OFF, lmagic);
+	printf("ioctl(-1, %s) = -1 EBADF (%m)\n", "PHN_NOT_OH or RTC_UIE_OFF");
+
+	ioctl(-1, RTC_AIE_ON, lmagic);
+#ifdef HPPA
+	printf("ioctl(-1, %s) = -1 EBADF (%m)\n", "PA_PERF_ON or RTC_AIE_ON");
+#else
+	printf("ioctl(-1, %s) = -1 EBADF (%m)\n", "RTC_AIE_ON");
+#endif
+
+	ioctl(-1, _IO(0x70, 0x40), lmagic);
+	printf("ioctl(-1, %s, %#lx) = -1 EBADF (%m)\n", "NVRAM_INIT", lmagic);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/ioctl_rtc.test b/strace/tests/ioctl_rtc.test
new file mode 100755
index 0000000..4545f2a
--- /dev/null
+++ b/strace/tests/ioctl_rtc.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check basic decoding of RTC_* ioctls.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/ioctl_uffdio.c b/strace/tests/ioctl_uffdio.c
new file mode 100644
index 0000000..73a8a99
--- /dev/null
+++ b/strace/tests/ioctl_uffdio.c
@@ -0,0 +1,213 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c)      2016 Red Hat, Inc.
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_userfaultfd && defined HAVE_LINUX_USERFAULTFD_H
+
+# include <fcntl.h>
+# include <inttypes.h>
+# include <stdint.h>
+# include <stdio.h>
+# include <string.h>
+# include <unistd.h>
+
+# include <sys/ioctl.h>
+# include <sys/mman.h>
+# include <linux/ioctl.h>
+# include <linux/userfaultfd.h>
+
+int
+main(void)
+{
+	int rc;
+	int fd = syscall(__NR_userfaultfd, O_NONBLOCK);
+	size_t pagesize = getpagesize();
+
+	if (fd < 0)
+		perror_msg_and_skip("userfaultfd");
+
+	/* ---- API ---- */
+	struct uffdio_api *api_struct = tail_alloc(sizeof(*api_struct));
+
+	/* With a bad fd */
+	memset(api_struct, 0, sizeof(*api_struct));
+	rc = ioctl(-1, UFFDIO_API, api_struct);
+	printf("ioctl(-1, UFFDIO_API, {api=0, features=0}) = %d %s (%m)\n",
+	       rc, errno2name());
+	/* With a bad pointer */
+	rc = ioctl(fd, UFFDIO_API, NULL);
+	printf("ioctl(%d, UFFDIO_API, NULL) = %d %s (%m)\n",
+		fd, rc, errno2name());
+	/* Normal call */
+	api_struct->api = UFFD_API;
+	api_struct->features = 0;
+	rc = ioctl(fd, UFFDIO_API, api_struct);
+	printf("ioctl(%d, UFFDIO_API, {api=0xaa, features=0, "
+	       "features.out=%#" PRIx64 ", " "ioctls=1<<_UFFDIO_REGISTER|"
+	       "1<<_UFFDIO_UNREGISTER|1<<_UFFDIO_API",
+	       fd, (uint64_t)api_struct->features);
+	api_struct->ioctls &= ~(1ull<<_UFFDIO_REGISTER|
+				1ull<<_UFFDIO_UNREGISTER|
+				1ull<<_UFFDIO_API);
+	if (api_struct->ioctls)
+		printf("|%#" PRIx64, (uint64_t)api_struct->ioctls);
+	printf("}) = %d\n", rc);
+
+	/* For the rest of the tests we need some anonymous memory */
+	void *area1 = mmap(NULL, pagesize, PROT_READ|PROT_WRITE,
+			   MAP_PRIVATE|MAP_ANONYMOUS,
+			   -1, 0);
+	if (area1 == MAP_FAILED)
+		perror_msg_and_fail("mmap area1");
+	void *area2 = mmap(NULL, pagesize, PROT_READ|PROT_WRITE,
+			   MAP_PRIVATE|MAP_ANONYMOUS,
+			   -1, 0);
+	if (area2 == MAP_FAILED)
+		perror_msg_and_fail("mmap area2");
+	madvise(area2, pagesize, MADV_DONTNEED);
+	*(char *)area1 = 42;
+
+	/* ---- REGISTER ---- */
+	struct uffdio_register *register_struct =
+					 tail_alloc(sizeof(*register_struct));
+	memset(register_struct, 0, sizeof(*register_struct));
+
+	rc = ioctl(-1, UFFDIO_REGISTER, register_struct);
+	printf("ioctl(-1, UFFDIO_REGISTER, {range={start=0, len=0}, "
+	       "mode=0}) = %d %s (%m)\n", rc, errno2name());
+
+	rc = ioctl(fd, UFFDIO_REGISTER, NULL);
+	printf("ioctl(%d, UFFDIO_REGISTER, NULL) = %d %s (%m)\n",
+	       fd, rc, errno2name());
+
+	register_struct->range.start = (uint64_t)(uintptr_t)area2;
+	register_struct->range.len = pagesize;
+	register_struct->mode = UFFDIO_REGISTER_MODE_MISSING;
+	rc = ioctl(fd, UFFDIO_REGISTER, register_struct);
+	printf("ioctl(%d, UFFDIO_REGISTER, {range={start=%p, len=%#zx}, "
+	       "mode=UFFDIO_REGISTER_MODE_MISSING, ioctls="
+	       "1<<_UFFDIO_WAKE|1<<_UFFDIO_COPY|1<<_UFFDIO_ZEROPAGE",
+	       fd, area2, pagesize);
+	register_struct->ioctls &= ~(1ull<<_UFFDIO_WAKE|
+				    1ull<<_UFFDIO_COPY|
+				    1ull<<_UFFDIO_ZEROPAGE);
+	if (register_struct->ioctls)
+		printf("|%#" PRIx64, (uint64_t)register_struct->ioctls);
+	printf("}) = %d\n", rc);
+
+	/* With area2 registered we can now do the atomic copies onto it
+	 * but be careful not to access it in any other way otherwise
+	 * userfaultfd will cause us to stall.
+	 */
+	/* ---- COPY ---- */
+	struct uffdio_copy *copy_struct = tail_alloc(sizeof(*copy_struct));
+
+	memset(copy_struct, 0, sizeof(*copy_struct));
+	rc = ioctl(-1, UFFDIO_COPY, copy_struct);
+	printf("ioctl(-1, UFFDIO_COPY, {dst=0, src=0, len=0, mode=0"
+	       "}) = %d %s (%m)\n", rc, errno2name());
+
+	rc = ioctl(fd, UFFDIO_COPY, NULL);
+	printf("ioctl(%d, UFFDIO_COPY, NULL) = %d %s (%m)\n",
+	       fd, rc, errno2name());
+
+	copy_struct->dst = (uint64_t)(uintptr_t)area2;
+	copy_struct->src = (uint64_t)(uintptr_t)area1;
+	copy_struct->len = pagesize;
+	copy_struct->mode = UFFDIO_COPY_MODE_DONTWAKE;
+	rc = ioctl(fd, UFFDIO_COPY, copy_struct);
+	printf("ioctl(%d, UFFDIO_COPY, {dst=%p, src=%p, len=%#zx,"
+	       " mode=UFFDIO_COPY_MODE_DONTWAKE, copy=%#zx}) = %d\n",
+	       fd, area2, area1, pagesize, pagesize, rc);
+
+	/* ---- ZEROPAGE ---- */
+	struct uffdio_zeropage *zero_struct = tail_alloc(sizeof(*zero_struct));
+	madvise(area2, pagesize, MADV_DONTNEED);
+
+	memset(zero_struct, 0, sizeof(*zero_struct));
+	rc = ioctl(-1, UFFDIO_ZEROPAGE, zero_struct);
+	printf("ioctl(-1, UFFDIO_ZEROPAGE, {range={start=0, len=0}, mode=0"
+	       "}) = %d %s (%m)\n", rc, errno2name());
+
+	rc = ioctl(fd, UFFDIO_ZEROPAGE, NULL);
+	printf("ioctl(%d, UFFDIO_ZEROPAGE, NULL) = %d %s (%m)\n",
+	       fd, rc, errno2name());
+
+	zero_struct->range.start = (uint64_t)(uintptr_t)area2;
+	zero_struct->range.len = pagesize;
+	zero_struct->mode = UFFDIO_ZEROPAGE_MODE_DONTWAKE;
+	rc = ioctl(fd, UFFDIO_ZEROPAGE, zero_struct);
+	printf("ioctl(%d, UFFDIO_ZEROPAGE, {range={start=%p, len=%#zx},"
+	       " mode=UFFDIO_ZEROPAGE_MODE_DONTWAKE, zeropage=%#zx}) = %d\n",
+	       fd, area2, pagesize, pagesize, rc);
+
+	/* ---- WAKE ---- */
+	struct uffdio_range *range_struct = tail_alloc(sizeof(*range_struct));
+	memset(range_struct, 0, sizeof(*range_struct));
+
+	rc = ioctl(-1, UFFDIO_WAKE, range_struct);
+	printf("ioctl(-1, UFFDIO_WAKE, {start=0, len=0}) = %d %s (%m)\n",
+	       rc, errno2name());
+
+	rc = ioctl(fd, UFFDIO_WAKE, NULL);
+	printf("ioctl(%d, UFFDIO_WAKE, NULL) = %d %s (%m)\n",
+	       fd, rc, errno2name());
+
+	range_struct->start = (uint64_t)(uintptr_t)area2;
+	range_struct->len = pagesize;
+	rc = ioctl(fd, UFFDIO_WAKE, range_struct);
+	printf("ioctl(%d, UFFDIO_WAKE, {start=%p, len=%#zx}) = %d\n",
+	       fd, area2, pagesize, rc);
+
+	/* ---- UNREGISTER ---- */
+	memset(range_struct, 0, sizeof(*range_struct));
+
+	rc = ioctl(-1, UFFDIO_UNREGISTER, range_struct);
+	printf("ioctl(-1, UFFDIO_UNREGISTER, {start=0, len=0}) = %d %s (%m)\n",
+	       rc, errno2name());
+
+	rc = ioctl(fd, UFFDIO_UNREGISTER, NULL);
+	printf("ioctl(%d, UFFDIO_UNREGISTER, NULL) = %d %s (%m)\n",
+	       fd, rc, errno2name());
+
+	range_struct->start = (uint64_t)(uintptr_t)area2;
+	range_struct->len = pagesize;
+	rc = ioctl(fd, UFFDIO_UNREGISTER, range_struct);
+	printf("ioctl(%d, UFFDIO_UNREGISTER, {start=%p, len=%#zx}) = %d\n",
+	       fd, area2, pagesize, rc);
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_userfaultfd && HAVE_LINUX_USERFAULTFD_H")
+
+#endif
diff --git a/strace/tests/ioctl_uffdio.test b/strace/tests/ioctl_uffdio.test
new file mode 100755
index 0000000..fae9b55
--- /dev/null
+++ b/strace/tests/ioctl_uffdio.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check userfaultfd ioctl decoding.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/ioctl_v4l2.c b/strace/tests/ioctl_v4l2.c
new file mode 100644
index 0000000..850783d
--- /dev/null
+++ b/strace/tests/ioctl_v4l2.c
@@ -0,0 +1,522 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <string.h>
+#include <sys/ioctl.h>
+#include <linux/types.h>
+#include <linux/videodev2.h>
+
+static const unsigned int magic = 0xdeadbeef;
+
+static void
+init_magic(void *addr, const unsigned int size)
+{
+	unsigned int *p = addr;
+	const unsigned int *end = addr + size;
+
+	for (; p < end; ++p)
+		*(unsigned int *) p = magic;
+}
+
+int
+main(void )
+{
+	const unsigned int size = get_page_size();
+	void *const page = tail_alloc(size);
+	init_magic(page, size);
+
+	const union u_pixel_format {
+		unsigned int pixelformat;
+		unsigned char cc[sizeof(int)];
+	} u = {
+#if WORDS_BIGENDIAN
+		.cc = {
+			(unsigned char) (magic >> 24),
+			(unsigned char) (magic >> 16),
+			(unsigned char) (magic >> 8),
+			(unsigned char) magic
+		}
+#else
+		.pixelformat = magic
+#endif
+	};
+
+	/* VIDIOC_QUERYCAP */
+	ioctl(-1, VIDIOC_QUERYCAP, 0);
+	printf("ioctl(-1, VIDIOC_QUERYCAP, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_QUERYCAP, page);
+	printf("ioctl(-1, VIDIOC_QUERYCAP, %p) = -1 EBADF (%m)\n", page);
+
+	/* VIDIOC_ENUM_FMT */
+	ioctl(-1, VIDIOC_ENUM_FMT, 0);
+	printf("ioctl(-1, VIDIOC_ENUM_FMT, NULL) = -1 EBADF (%m)\n");
+
+	struct v4l2_fmtdesc *const p_fmtdesc = tail_alloc(sizeof(*p_fmtdesc));
+	p_fmtdesc->index = magic;
+	p_fmtdesc->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
+	ioctl(-1, VIDIOC_ENUM_FMT, p_fmtdesc);
+	printf("ioctl(-1, VIDIOC_ENUM_FMT, {index=%u"
+	       ", type=V4L2_BUF_TYPE_VIDEO_CAPTURE}) = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_G_FMT */
+	ioctl(-1, VIDIOC_G_FMT, 0);
+	printf("ioctl(-1, VIDIOC_G_FMT, NULL) = -1 EBADF (%m)\n");
+
+	struct v4l2_format *const p_format =
+		tail_alloc(sizeof(*p_format));
+	p_format->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
+
+	ioctl(-1, VIDIOC_G_FMT, p_format);
+	printf("ioctl(-1, VIDIOC_G_FMT"
+	       ", {type=V4L2_BUF_TYPE_VIDEO_CAPTURE}) = -1 EBADF (%m)\n");
+
+	/* VIDIOC_S_FMT */
+	ioctl(-1, VIDIOC_S_FMT, 0);
+	printf("ioctl(-1, VIDIOC_S_FMT, NULL) = -1 EBADF (%m)\n");
+
+	p_format->type = V4L2_BUF_TYPE_VIDEO_OUTPUT;
+	p_format->fmt.pix.width = 0xdad1beaf;
+	p_format->fmt.pix.height = 0xdad2beaf;
+	p_format->fmt.pix.pixelformat = 0xdeadbeef;
+	p_format->fmt.pix.field = V4L2_FIELD_NONE;
+	p_format->fmt.pix.bytesperline = 0xdad3beaf;
+	p_format->fmt.pix.sizeimage = 0xdad4beaf;
+	p_format->fmt.pix.colorspace = V4L2_COLORSPACE_JPEG;
+
+	ioctl(-1, VIDIOC_S_FMT, p_format);
+	printf("ioctl(-1, VIDIOC_S_FMT, {type=V4L2_BUF_TYPE_VIDEO_OUTPUT"
+	       ", fmt.pix={width=%u, height=%u, pixelformat="
+	       "v4l2_fourcc('\\x%x', '\\x%x', '\\x%x', '\\x%x')"
+	       ", field=V4L2_FIELD_NONE, bytesperline=%u, sizeimage=%u"
+	       ", colorspace=V4L2_COLORSPACE_JPEG}}) = -1 EBADF (%m)\n",
+	       p_format->fmt.pix.width, p_format->fmt.pix.height,
+	       u.cc[0], u.cc[1], u.cc[2], u.cc[3],
+	       p_format->fmt.pix.bytesperline, p_format->fmt.pix.sizeimage);
+
+	/* VIDIOC_TRY_FMT */
+	ioctl(-1, VIDIOC_TRY_FMT, 0);
+	printf("ioctl(-1, VIDIOC_TRY_FMT, NULL) = -1 EBADF (%m)\n");
+
+#if HAVE_DECL_V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE
+	memset(p_format, -1, sizeof(*p_format));
+	p_format->type = V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE;
+	p_format->fmt.pix_mp.width = 0xdad1beaf;
+	p_format->fmt.pix_mp.height = 0xdad2beaf;
+	p_format->fmt.pix_mp.pixelformat = 0xdeadbeef;
+	p_format->fmt.pix_mp.field = V4L2_FIELD_NONE;
+	p_format->fmt.pix_mp.colorspace = V4L2_COLORSPACE_JPEG;
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(p_format->fmt.pix_mp.plane_fmt); ++i) {
+		p_format->fmt.pix_mp.plane_fmt[i].sizeimage = 0xbadc0de0 | i;
+		p_format->fmt.pix_mp.plane_fmt[i].bytesperline = 0xdadbeaf0 | i;
+	}
+	ioctl(-1, VIDIOC_TRY_FMT, p_format);
+	printf("ioctl(-1, VIDIOC_TRY_FMT"
+	       ", {type=V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE"
+	       ", fmt.pix_mp={width=%u, height=%u, pixelformat="
+	       "v4l2_fourcc('\\x%x', '\\x%x', '\\x%x', '\\x%x')"
+	       ", field=V4L2_FIELD_NONE, colorspace=V4L2_COLORSPACE_JPEG"
+	       ", plane_fmt=[",
+	       p_format->fmt.pix_mp.width, p_format->fmt.pix_mp.height,
+	       u.cc[0], u.cc[1], u.cc[2], u.cc[3]);
+	for (i = 0; i < ARRAY_SIZE(p_format->fmt.pix_mp.plane_fmt); ++i) {
+		if (i)
+			printf(", ");
+		printf("{sizeimage=%u, bytesperline=%u}",
+		       p_format->fmt.pix_mp.plane_fmt[i].sizeimage,
+		       p_format->fmt.pix_mp.plane_fmt[i].bytesperline);
+	}
+	printf("], num_planes=%u}}) = -1 EBADF (%m)\n",
+	       p_format->fmt.pix_mp.num_planes);
+#else
+	ioctl(-1, VIDIOC_TRY_FMT, page);
+	printf("ioctl(-1, VIDIOC_TRY_FMT, {type=%#x /* V4L2_BUF_TYPE_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+#endif
+
+	/* VIDIOC_REQBUFS */
+	ioctl(-1, VIDIOC_REQBUFS, 0);
+	printf("ioctl(-1, VIDIOC_REQBUFS, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_REQBUFS,
+	      page + size - sizeof(struct v4l2_requestbuffers));
+	printf("ioctl(-1, VIDIOC_REQBUFS, {count=%u, type=%#x"
+	       " /* V4L2_BUF_TYPE_??? */, memory=%#x /* V4L2_MEMORY_??? */})"
+	       " = -1 EBADF (%m)\n", magic, magic, magic);
+
+	/* VIDIOC_QUERYBUF */
+	ioctl(-1, VIDIOC_QUERYBUF, 0);
+	printf("ioctl(-1, VIDIOC_QUERYBUF, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_QUERYBUF, page + size - sizeof(struct v4l2_buffer));
+	printf("ioctl(-1, VIDIOC_QUERYBUF, {type=%#x /* V4L2_BUF_TYPE_??? */"
+	       ", index=%u}) = -1 EBADF (%m)\n", magic, magic);
+
+	/* VIDIOC_QBUF */
+	ioctl(-1, VIDIOC_QBUF, 0);
+	printf("ioctl(-1, VIDIOC_QBUF, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_QBUF, page + size - sizeof(struct v4l2_buffer));
+	printf("ioctl(-1, VIDIOC_QBUF, {type=%#x /* V4L2_BUF_TYPE_??? */"
+	       ", index=%u}) = -1 EBADF (%m)\n", magic, magic);
+
+	/* VIDIOC_DQBUF */
+	ioctl(-1, VIDIOC_DQBUF, 0);
+	printf("ioctl(-1, VIDIOC_DQBUF, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_DQBUF, page + size - sizeof(struct v4l2_buffer));
+	printf("ioctl(-1, VIDIOC_DQBUF, {type=%#x"
+	       " /* V4L2_BUF_TYPE_??? */}) = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_G_FBUF */
+	ioctl(-1, VIDIOC_G_FBUF, 0);
+	printf("ioctl(-1, VIDIOC_G_FBUF, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_FBUF, page);
+	printf("ioctl(-1, VIDIOC_G_FBUF, %p) = -1 EBADF (%m)\n", page);
+
+	/* VIDIOC_S_FBUF */
+	ioctl(-1, VIDIOC_S_FBUF, 0);
+	printf("ioctl(-1, VIDIOC_S_FBUF, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_S_FBUF, page + size - sizeof(struct v4l2_framebuffer));
+	printf("ioctl(-1, VIDIOC_S_FBUF, {capability=%#x"
+	       ", flags=%#x, base=%#lx}) = -1 EBADF (%m)\n",
+	       magic, magic, *(unsigned long *) page);
+
+	/* VIDIOC_STREAMON */
+	ioctl(-1, VIDIOC_STREAMON, 0);
+	printf("ioctl(-1, VIDIOC_STREAMON, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_STREAMON, page + size - sizeof(int));
+	printf("ioctl(-1, VIDIOC_STREAMON, [%#x /* V4L2_BUF_TYPE_??? */])"
+	       " = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_STREAMOFF */
+	ioctl(-1, VIDIOC_STREAMOFF, 0);
+	printf("ioctl(-1, VIDIOC_STREAMOFF, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_STREAMOFF, page + size - sizeof(int));
+	printf("ioctl(-1, VIDIOC_STREAMOFF, [%#x /* V4L2_BUF_TYPE_??? */])"
+	       " = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_G_PARM */
+	ioctl(-1, VIDIOC_G_PARM, 0);
+	printf("ioctl(-1, VIDIOC_G_PARM, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_PARM, page + size - sizeof(struct v4l2_streamparm));
+	printf("ioctl(-1, VIDIOC_G_PARM, {type=%#x /* V4L2_BUF_TYPE_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_S_PARM */
+	ioctl(-1, VIDIOC_S_PARM, 0);
+	printf("ioctl(-1, VIDIOC_S_PARM, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_S_PARM, page);
+	printf("ioctl(-1, VIDIOC_S_PARM, {type=%#x /* V4L2_BUF_TYPE_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+
+	struct v4l2_streamparm *const p_streamparm =
+		tail_alloc(sizeof(*p_streamparm));
+	p_streamparm->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
+	p_streamparm->parm.capture.capability = V4L2_CAP_TIMEPERFRAME;
+	p_streamparm->parm.capture.capturemode = V4L2_MODE_HIGHQUALITY;
+	p_streamparm->parm.capture.timeperframe.numerator = 0xdeadbeef;
+	p_streamparm->parm.capture.timeperframe.denominator = 0xbadc0ded;
+	ioctl(-1, VIDIOC_S_PARM, p_streamparm);
+	printf("ioctl(-1, VIDIOC_S_PARM, {type=V4L2_BUF_TYPE_VIDEO_CAPTURE"
+	       ", parm.capture={capability=V4L2_CAP_TIMEPERFRAME"
+	       ", capturemode=V4L2_MODE_HIGHQUALITY, timeperframe=%u/%u"
+	       ", extendedmode=%u, readbuffers=%u}}) = -1 EBADF (%m)\n",
+	       p_streamparm->parm.capture.timeperframe.numerator,
+	       p_streamparm->parm.capture.timeperframe.denominator, -1U, -1U);
+
+	p_streamparm->type = V4L2_BUF_TYPE_VIDEO_OUTPUT;
+	p_streamparm->parm.output.outputmode = 0;
+	ioctl(-1, VIDIOC_S_PARM, p_streamparm);
+	printf("ioctl(-1, VIDIOC_S_PARM, {type=V4L2_BUF_TYPE_VIDEO_OUTPUT"
+	       ", parm.output={capability=V4L2_CAP_TIMEPERFRAME"
+	       ", outputmode=0, timeperframe=%u/%u"
+	       ", extendedmode=%u, writebuffers=%u}}) = -1 EBADF (%m)\n",
+	       p_streamparm->parm.output.timeperframe.numerator,
+	       p_streamparm->parm.output.timeperframe.denominator, -1U, -1U);
+
+	/* VIDIOC_G_STD */
+	ioctl(-1, VIDIOC_G_STD, 0);
+	printf("ioctl(-1, VIDIOC_G_STD, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_STD, page);
+	printf("ioctl(-1, VIDIOC_G_STD, %p) = -1 EBADF (%m)\n", page);
+
+	/* VIDIOC_S_STD */
+	ioctl(-1, VIDIOC_S_STD, 0);
+	printf("ioctl(-1, VIDIOC_S_STD, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_S_STD, page + size - sizeof(long long));
+	printf("ioctl(-1, VIDIOC_S_STD, [%#llx]) = -1 EBADF (%m)\n",
+	       *(unsigned long long *) page);
+
+	/* VIDIOC_ENUMSTD */
+	ioctl(-1, VIDIOC_ENUMSTD, 0);
+	printf("ioctl(-1, VIDIOC_ENUMSTD, NULL) = -1 EBADF (%m)\n");
+
+	struct v4l2_standard *const p_standard =
+		tail_alloc(sizeof(*p_standard));
+	p_standard->index = magic;
+	ioctl(-1, VIDIOC_ENUMSTD, p_standard);
+	printf("ioctl(-1, VIDIOC_ENUMSTD, {index=%u}) = -1 EBADF (%m)\n",
+	       magic);
+
+	/* VIDIOC_ENUMINPUT */
+	ioctl(-1, VIDIOC_ENUMINPUT, 0);
+	printf("ioctl(-1, VIDIOC_ENUMINPUT, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_ENUMINPUT, page);
+	printf("ioctl(-1, VIDIOC_ENUMINPUT, {index=%u}) = -1 EBADF (%m)\n",
+	       magic);
+
+	/* VIDIOC_G_CTRL */
+	ioctl(-1, VIDIOC_G_CTRL, 0);
+	printf("ioctl(-1, VIDIOC_G_CTRL, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_CTRL, page + size - sizeof(struct v4l2_control));
+	printf("ioctl(-1, VIDIOC_G_CTRL, {id=%#x /* V4L2_CID_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_S_CTRL */
+	ioctl(-1, VIDIOC_S_CTRL, 0);
+	printf("ioctl(-1, VIDIOC_S_CTRL, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_S_CTRL, page + size - sizeof(struct v4l2_control));
+	printf("ioctl(-1, VIDIOC_S_CTRL, {id=%#x /* V4L2_CID_??? */"
+	       ", value=%d}) = -1 EBADF (%m)\n", magic, magic);
+
+	/* VIDIOC_QUERYCTRL */
+	ioctl(-1, VIDIOC_QUERYCTRL, 0);
+	printf("ioctl(-1, VIDIOC_QUERYCTRL, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_QUERYCTRL,
+	      page + size - sizeof(struct v4l2_queryctrl));
+# ifdef V4L2_CTRL_FLAG_NEXT_CTRL
+	printf("ioctl(-1, VIDIOC_QUERYCTRL, {id=V4L2_CTRL_FLAG_NEXT_CTRL"
+	       "|%#x /* V4L2_CID_??? */}) = -1 EBADF (%m)\n",
+	       magic & ~V4L2_CTRL_FLAG_NEXT_CTRL);
+# else
+	printf("ioctl(-1, VIDIOC_QUERYCTRL, {id=%#x /* V4L2_CID_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+# endif
+
+	struct v4l2_queryctrl *const p_queryctrl =
+		tail_alloc(sizeof(*p_queryctrl));
+	p_queryctrl->id = V4L2_CID_SATURATION;
+	ioctl(-1, VIDIOC_QUERYCTRL, p_queryctrl);
+	printf("ioctl(-1, VIDIOC_QUERYCTRL, {id=V4L2_CID_SATURATION})"
+	       " = -1 EBADF (%m)\n");
+
+	/* VIDIOC_G_INPUT */
+	ioctl(-1, VIDIOC_G_INPUT, 0);
+	printf("ioctl(-1, VIDIOC_G_INPUT, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_INPUT, page);
+	printf("ioctl(-1, VIDIOC_G_INPUT, %p) = -1 EBADF (%m)\n", page);
+
+	/* VIDIOC_S_INPUT */
+	ioctl(-1, VIDIOC_S_INPUT, 0);
+	printf("ioctl(-1, VIDIOC_S_INPUT, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_S_INPUT, page + size - sizeof(int));
+	printf("ioctl(-1, VIDIOC_S_INPUT, [%u]) = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_CROPCAP */
+	ioctl(-1, VIDIOC_CROPCAP, 0);
+	printf("ioctl(-1, VIDIOC_CROPCAP, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_CROPCAP, page + size - sizeof(struct v4l2_cropcap));
+	printf("ioctl(-1, VIDIOC_CROPCAP, {type=%#x /* V4L2_BUF_TYPE_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_G_CROP */
+	ioctl(-1, VIDIOC_G_CROP, 0);
+	printf("ioctl(-1, VIDIOC_G_CROP, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_CROP, page + size - sizeof(struct v4l2_crop));
+	printf("ioctl(-1, VIDIOC_G_CROP, {type=%#x /* V4L2_BUF_TYPE_??? */})"
+	       " = -1 EBADF (%m)\n", magic);
+
+	/* VIDIOC_S_CROP */
+	ioctl(-1, VIDIOC_S_CROP, 0);
+	printf("ioctl(-1, VIDIOC_S_CROP, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_S_CROP, page + size - sizeof(struct v4l2_crop));
+	printf("ioctl(-1, VIDIOC_S_CROP, {type=%#x /* V4L2_BUF_TYPE_??? */"
+	       ", c={left=%d, top=%d, width=%u, height=%u}}) = -1 EBADF (%m)\n",
+	       magic, magic, magic, magic, magic);
+
+#ifdef VIDIOC_S_EXT_CTRLS
+	/* VIDIOC_S_EXT_CTRLS */
+	ioctl(-1, VIDIOC_S_EXT_CTRLS, 0);
+	printf("ioctl(-1, VIDIOC_S_EXT_CTRLS, NULL) = -1 EBADF (%m)\n");
+
+	struct v4l2_ext_controls *const p_ext_controls =
+		tail_alloc(sizeof(*p_ext_controls));
+	p_ext_controls->ctrl_class = V4L2_CTRL_CLASS_USER;
+	p_ext_controls->count = 0;
+	p_ext_controls->controls = (void *) -2UL;
+	ioctl(-1, VIDIOC_S_EXT_CTRLS, p_ext_controls);
+	printf("ioctl(-1, VIDIOC_S_EXT_CTRLS, {ctrl_class=V4L2_CTRL_CLASS_USER"
+	       ", count=%u}) = -1 EBADF (%m)\n", p_ext_controls->count);
+
+	p_ext_controls->ctrl_class = V4L2_CTRL_CLASS_MPEG;
+	p_ext_controls->count = magic;
+	ioctl(-1, VIDIOC_S_EXT_CTRLS, p_ext_controls);
+	printf("ioctl(-1, VIDIOC_S_EXT_CTRLS, {ctrl_class=V4L2_CTRL_CLASS_MPEG"
+	       ", count=%u, controls=%p}) = -1 EBADF (%m)\n",
+	       p_ext_controls->count, p_ext_controls->controls);
+
+# if HAVE_DECL_V4L2_CTRL_TYPE_STRING
+	p_ext_controls->count = 2;
+	p_ext_controls->controls =
+		tail_alloc(sizeof(*p_ext_controls->controls) * p_ext_controls->count);
+	p_ext_controls->controls[0].id = V4L2_CID_BRIGHTNESS;
+	p_ext_controls->controls[0].size = 0;
+	p_ext_controls->controls[0].value64 = 0xfacefeeddeadbeef;
+	p_ext_controls->controls[1].id = V4L2_CID_CONTRAST;
+	p_ext_controls->controls[1].size = 2;
+	p_ext_controls->controls[1].string =
+		tail_alloc(p_ext_controls->controls[1].size);
+
+	ioctl(-1, VIDIOC_S_EXT_CTRLS, p_ext_controls);
+	printf("ioctl(-1, VIDIOC_S_EXT_CTRLS"
+	       ", {ctrl_class=V4L2_CTRL_CLASS_MPEG, count=%u, controls="
+	       "[{id=V4L2_CID_BRIGHTNESS, size=0, value=%d, value64=%lld}"
+	       ", {id=V4L2_CID_CONTRAST, size=2, string=\"\\377\\377\"}"
+	       "] => controls="
+	       "[{id=V4L2_CID_BRIGHTNESS, size=0, value=%d, value64=%lld}"
+	       ", {id=V4L2_CID_CONTRAST, size=2, string=\"\\377\\377\"}"
+	       "], error_idx=%u}) = -1 EBADF (%m)\n",
+	       p_ext_controls->count,
+	       p_ext_controls->controls[0].value,
+	       (long long) p_ext_controls->controls[0].value64,
+	       p_ext_controls->controls[0].value,
+	       (long long) p_ext_controls->controls[0].value64,
+	       p_ext_controls->error_idx);
+
+	++p_ext_controls->count;
+	ioctl(-1, VIDIOC_S_EXT_CTRLS, p_ext_controls);
+	printf("ioctl(-1, VIDIOC_S_EXT_CTRLS"
+	       ", {ctrl_class=V4L2_CTRL_CLASS_MPEG, count=%u, controls="
+	       "[{id=V4L2_CID_BRIGHTNESS, size=0, value=%d, value64=%lld}"
+	       ", {id=V4L2_CID_CONTRAST, size=2, string=\"\\377\\377\"}"
+	       ", %p]}) = -1 EBADF (%m)\n",
+	       p_ext_controls->count,
+	       p_ext_controls->controls[0].value,
+	       (long long) p_ext_controls->controls[0].value64,
+	       p_ext_controls->controls + 2);
+# endif /* HAVE_DECL_V4L2_CTRL_TYPE_STRING */
+
+	/* VIDIOC_TRY_EXT_CTRLS */
+	ioctl(-1, VIDIOC_TRY_EXT_CTRLS, 0);
+	printf("ioctl(-1, VIDIOC_TRY_EXT_CTRLS, NULL) = -1 EBADF (%m)\n");
+
+	p_ext_controls->ctrl_class = V4L2_CTRL_CLASS_USER;
+	p_ext_controls->count = magic;
+	p_ext_controls->controls = (void *) -2UL;
+	ioctl(-1, VIDIOC_TRY_EXT_CTRLS, p_ext_controls);
+	printf("ioctl(-1, VIDIOC_TRY_EXT_CTRLS"
+	       ", {ctrl_class=V4L2_CTRL_CLASS_USER, count=%u, controls=%p})"
+	       " = -1 EBADF (%m)\n",
+	       p_ext_controls->count, p_ext_controls->controls);
+
+	/* VIDIOC_G_EXT_CTRLS */
+	ioctl(-1, VIDIOC_G_EXT_CTRLS, 0);
+	printf("ioctl(-1, VIDIOC_G_EXT_CTRLS, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_G_EXT_CTRLS, p_ext_controls);
+	printf("ioctl(-1, VIDIOC_G_EXT_CTRLS"
+	       ", {ctrl_class=V4L2_CTRL_CLASS_USER, count=%u, controls=%p"
+	       ", error_idx=%u}) = -1 EBADF (%m)\n",
+	       p_ext_controls->count, p_ext_controls->controls,
+	       p_ext_controls->error_idx);
+#endif /* VIDIOC_S_EXT_CTRLS */
+
+#ifdef VIDIOC_ENUM_FRAMESIZES
+	ioctl(-1, VIDIOC_ENUM_FRAMESIZES, 0);
+	printf("ioctl(-1, VIDIOC_ENUM_FRAMESIZES, NULL) = -1 EBADF (%m)\n");
+
+	struct v4l2_frmsizeenum *const p_frmsizeenum =
+		tail_alloc(sizeof(*p_frmsizeenum));
+	p_frmsizeenum->index = magic;
+	const union u_pixel_format u_frmsizeenum = {
+		.cc = { 'A', '\'', '\\', '\xfa' }
+	};
+#if WORDS_BIGENDIAN
+	p_frmsizeenum->pixel_format =
+		(unsigned) u_frmsizeenum.cc[0] << 24 |
+		(unsigned) u_frmsizeenum.cc[1] << 16 |
+		(unsigned) u_frmsizeenum.cc[2] << 8 |
+		(unsigned) u_frmsizeenum.cc[3];
+#else
+	p_frmsizeenum->pixel_format = u_frmsizeenum.pixelformat;
+#endif
+
+	ioctl(-1, VIDIOC_ENUM_FRAMESIZES, p_frmsizeenum);
+	printf("ioctl(-1, VIDIOC_ENUM_FRAMESIZES, {index=%u"
+	       ", pixel_format=v4l2_fourcc('%c', '\\%c', '\\%c', '\\x%x')})"
+	       " = -1 EBADF (%m)\n", p_frmsizeenum->index,
+	       u_frmsizeenum.cc[0], u_frmsizeenum.cc[1],
+	       u_frmsizeenum.cc[2], u_frmsizeenum.cc[3]);
+#endif /* VIDIOC_ENUM_FRAMESIZES */
+
+#ifdef VIDIOC_ENUM_FRAMEINTERVALS
+	ioctl(-1, VIDIOC_ENUM_FRAMEINTERVALS, 0);
+	printf("ioctl(-1, VIDIOC_ENUM_FRAMEINTERVALS, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_ENUM_FRAMEINTERVALS, page);
+	printf("ioctl(-1, VIDIOC_ENUM_FRAMEINTERVALS, {index=%u"
+	       ", pixel_format=v4l2_fourcc('\\x%x', '\\x%x', '\\x%x', '\\x%x')"
+	       ", width=%u, height=%u}) = -1 EBADF (%m)\n",
+	       magic, u.cc[0], u.cc[1], u.cc[2], u.cc[3], magic, magic);
+#endif /* VIDIOC_ENUM_FRAMEINTERVALS */
+
+#ifdef VIDIOC_CREATE_BUFS
+	ioctl(-1, VIDIOC_CREATE_BUFS, 0);
+	printf("ioctl(-1, VIDIOC_CREATE_BUFS, NULL) = -1 EBADF (%m)\n");
+
+	ioctl(-1, VIDIOC_CREATE_BUFS,
+	      page + size - sizeof(struct v4l2_create_buffers));
+	printf("ioctl(-1, VIDIOC_CREATE_BUFS, {count=%u, memory=%#x"
+	       " /* V4L2_MEMORY_??? */, format={type=%#x"
+	       " /* V4L2_BUF_TYPE_??? */}}) = -1 EBADF (%m)\n",
+	       magic, magic, magic);
+#endif /* VIDIOC_CREATE_BUFS */
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/ioctl_v4l2.test b/strace/tests/ioctl_v4l2.test
new file mode 100755
index 0000000..a092a3c
--- /dev/null
+++ b/strace/tests/ioctl_v4l2.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check basic VIDIOC_* ioctl decoding.
+
+. "${srcdir=.}/ioctl.test"
diff --git a/strace/tests/ioperm.c b/strace/tests/ioperm.c
new file mode 100644
index 0000000..f39bdf0
--- /dev/null
+++ b/strace/tests/ioperm.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_ioperm
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const unsigned long port = (unsigned long) 0xdeafbeefffffffff;
+
+	long rc = syscall(__NR_ioperm, port, 1, 0);
+	printf("ioperm(%#lx, %#lx, %d) = %ld %s (%m)\n",
+	       port, 1UL, 0, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_ioperm")
+
+#endif
diff --git a/strace/tests/ioperm.test b/strace/tests/ioperm.test
new file mode 100755
index 0000000..8c1c1cc
--- /dev/null
+++ b/strace/tests/ioperm.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check ioperm syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a27
diff --git a/strace/tests/iopl.c b/strace/tests/iopl.c
new file mode 100644
index 0000000..b547f3c
--- /dev/null
+++ b/strace/tests/iopl.c
@@ -0,0 +1,23 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_iopl
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_iopl, 4);
+	printf("iopl(4) = %ld %s (%m)\n", rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_iopl")
+
+#endif
diff --git a/strace/tests/iopl.test b/strace/tests/iopl.test
new file mode 100755
index 0000000..d0b5b11
--- /dev/null
+++ b/strace/tests/iopl.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check iopl syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a8
diff --git a/strace/tests/ip_mreq.c b/strace/tests/ip_mreq.c
new file mode 100644
index 0000000..0559b92
--- /dev/null
+++ b/strace/tests/ip_mreq.c
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <netinet/in.h>
+
+#if defined IP_ADD_MEMBERSHIP && defined IPV6_ADD_MEMBERSHIP \
+ && defined IPV6_JOIN_ANYCAST
+
+# include <assert.h>
+# include <unistd.h>
+# include <sys/socket.h>
+# include <arpa/inet.h>
+
+int
+main(void)
+{
+	struct ip_mreq m4;
+	struct ipv6_mreq m6;
+
+	inet_pton(AF_INET, "224.0.0.3", &m4.imr_multiaddr);
+	inet_pton(AF_INET, "127.0.0.1", &m4.imr_interface);
+	inet_pton(AF_INET6, "ff01::c", &m6.ipv6mr_multiaddr);
+	m6.ipv6mr_interface = 1;
+
+	(void) close(0);
+	if (socket(AF_INET, SOCK_DGRAM, 0))
+		perror_msg_and_skip("socket");
+
+	assert(setsockopt(0, SOL_IP, IP_ADD_MEMBERSHIP, &m4, 1) == -1);
+	assert(setsockopt(0, SOL_IP, IP_DROP_MEMBERSHIP, &m4, 1) == -1);
+	if (setsockopt(0, SOL_IP, IP_ADD_MEMBERSHIP, &m4, sizeof(m4)) ||
+	    setsockopt(0, SOL_IP, IP_DROP_MEMBERSHIP, &m4, sizeof(m4)))
+		perror_msg_and_skip("setsockopt");
+
+	assert(setsockopt(0, SOL_IPV6, IPV6_ADD_MEMBERSHIP, &m6, 1) == -1);
+	assert(setsockopt(0, SOL_IPV6, IPV6_DROP_MEMBERSHIP, &m6, 1) == -1);
+	assert(setsockopt(0, SOL_IPV6, IPV6_ADD_MEMBERSHIP, &m6, sizeof(m6)) == -1);
+	assert(setsockopt(0, SOL_IPV6, IPV6_DROP_MEMBERSHIP, &m6, sizeof(m6)) == -1);
+
+	assert(setsockopt(0, SOL_IPV6, IPV6_JOIN_ANYCAST, &m6, 1) == -1);
+	assert(setsockopt(0, SOL_IPV6, IPV6_LEAVE_ANYCAST, &m6, 1) == -1);
+	assert(setsockopt(0, SOL_IPV6, IPV6_JOIN_ANYCAST, &m6, sizeof(m6)) == -1);
+	assert(setsockopt(0, SOL_IPV6, IPV6_LEAVE_ANYCAST, &m6, sizeof(m6)) == -1);
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("IP_ADD_MEMBERSHIP && IPV6_ADD_MEMBERSHIP"
+		    " && IPV6_JOIN_ANYCAST")
+
+#endif
diff --git a/strace/tests/ip_mreq.expected b/strace/tests/ip_mreq.expected
new file mode 100644
index 0000000..e694c73
--- /dev/null
+++ b/strace/tests/ip_mreq.expected
@@ -0,0 +1,12 @@
+setsockopt\(0, SOL_IP, IP_ADD_MEMBERSHIP, "\\340", 1\) = -1 EINVAL .*
+setsockopt\(0, SOL_IP, IP_DROP_MEMBERSHIP, "\\340", 1\) = -1 EINVAL .*
+setsockopt\(0, SOL_IP, IP_ADD_MEMBERSHIP, \{imr_multiaddr=inet_addr\("224\.0\.0\.3"\), imr_interface=inet_addr\("127\.0\.0\.1"\)\}, 8\) = 0
+setsockopt\(0, SOL_IP, IP_DROP_MEMBERSHIP, \{imr_multiaddr=inet_addr\("224\.0\.0\.3"\), imr_interface=inet_addr\("127\.0\.0\.1"\)\}, 8\) = 0
+setsockopt\(0, SOL_IPV6, IPV6_ADD_MEMBERSHIP, "\\377", 1\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_DROP_MEMBERSHIP, "\\377", 1\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_ADD_MEMBERSHIP, \{ipv6mr_multiaddr=inet_pton\("ff01::c"\), ipv6mr_interface=if_nametoindex\("lo"\)\}, 20\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_DROP_MEMBERSHIP, \{ipv6mr_multiaddr=inet_pton\("ff01::c"\), ipv6mr_interface=if_nametoindex\("lo"\)\}, 20\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_JOIN_ANYCAST, "\\377", 1\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_LEAVE_ANYCAST, "\\377", 1\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_JOIN_ANYCAST, \{ipv6mr_multiaddr=inet_pton\("ff01::c"\), ipv6mr_interface=if_nametoindex\("lo"\)\}, 20\) = -1 ENOPROTOOPT .*
+setsockopt\(0, SOL_IPV6, IPV6_LEAVE_ANYCAST, \{ipv6mr_multiaddr=inet_pton\("ff01::c"\), ipv6mr_interface=if_nametoindex\("lo"\)\}, 20\) = -1 ENOPROTOOPT .*
diff --git a/strace/tests/ip_mreq.test b/strace/tests/ip_mreq.test
new file mode 100755
index 0000000..d423b1b
--- /dev/null
+++ b/strace/tests/ip_mreq.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check {IP,IPV6}_{ADD,DROP}_MEMBERSHIP setsockopt decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -e setsockopt $args
+match_grep
+
+exit 0
diff --git a/strace/tests/ipc.c b/strace/tests/ipc.c
new file mode 100644
index 0000000..d33a09f
--- /dev/null
+++ b/strace/tests/ipc.c
@@ -0,0 +1,122 @@
+/*
+ * Check decoding of ipc syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_ipc && defined HAVE_LINUX_IPC_H
+
+# include <errno.h>
+# include <stdio.h>
+# include <unistd.h>
+# include <linux/ipc.h>
+
+# ifndef SEMCTL
+#  define SEMCTL 3
+# endif
+# ifndef MSGRCV
+#  define MSGRCV 12
+# endif
+
+static int
+ipc_call(const unsigned short version, const unsigned short call,
+	 long a1, long a2, long a3, long a4, long a5)
+{
+	const unsigned long val =
+		(unsigned long) 0xfacefeed00000000 |
+		(unsigned int) version << 16 |
+		call;
+
+	return syscall(__NR_ipc, val, a1, a2, a3, a4, a5);
+}
+
+static int
+ipc_call0(const unsigned short version, const unsigned short call)
+{
+	int rc = ipc_call(version, call, 0, 0, 0, 0, 0);
+	int saved_errno = errno;
+	printf("ipc(");
+	if (version)
+		printf("%hu<<16|", version);
+	errno = saved_errno;
+	printf("%hu, 0, 0, 0, 0%s) = %d %s (%m)\n", call,
+# ifdef __s390__
+	       "",
+# else
+	       ", 0",
+# endif
+	       rc, errno2name());
+	return rc;
+}
+
+int
+main(void)
+{
+	void *const efault = tail_alloc(1) + 1;
+
+	int rc = ipc_call(0, SEMCTL, 0, 0, 0, (long) efault, 0);
+	if (rc != -1 || EFAULT != errno)
+		perror_msg_and_skip("ipc");
+	printf("semctl(0, 0, IPC_RMID, %p) = -1 EFAULT (%m)\n", efault);
+
+	unsigned short call;
+	for (call = 0; call <= 40; call += 10) {
+		ipc_call0(0, call);
+		ipc_call0(42, call);
+	}
+
+	rc = ipc_call(42, SEMCTL, 0, 0, 0, (long) efault, 0);
+	int test_version = EFAULT == errno;
+	if (test_version)
+		printf("semctl(0, 0, IPC_RMID, %p) = %d %s (%m)\n",
+		       efault, rc, errno2name());
+	else
+		printf("ipc(42<<16|SEMCTL, 0, 0, 0, %p) = %d %s (%m)\n",
+		       efault, rc, errno2name());
+
+	if (test_version) {
+		const int msqid = -2;
+		const long msgsz = -3;
+		const long msgtyp = 0;
+
+		rc = ipc_call(1, MSGRCV,
+			      msqid, msgsz, IPC_NOWAIT, (long) efault, msgtyp);
+		printf("msgrcv(%d, %p, %lu, %ld, IPC_NOWAIT) = %d %s (%m)\n",
+		       msqid, efault, msgsz, msgtyp, rc, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_ipc && HAVE_LINUX_IPC_H")
+
+#endif
diff --git a/strace/tests/ipc.sh b/strace/tests/ipc.sh
new file mode 100644
index 0000000..752d4bb
--- /dev/null
+++ b/strace/tests/ipc.sh
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# Check decoding of ipc syscalls
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -eipc $args > "$OUT"
+match_grep "$LOG" "$OUT"
+
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/ipc.test b/strace/tests/ipc.test
new file mode 100755
index 0000000..aa33fa6
--- /dev/null
+++ b/strace/tests/ipc.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of ipc syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a19
diff --git a/strace/tests/ipc_msg.c b/strace/tests/ipc_msg.c
new file mode 100644
index 0000000..2fd7d4f
--- /dev/null
+++ b/strace/tests/ipc_msg.c
@@ -0,0 +1,90 @@
+/*
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/msg.h>
+
+static int id = -1;
+
+static void
+cleanup(void)
+{
+	msgctl(id, IPC_RMID, NULL);
+	printf("msgctl\\(%d, (IPC_64\\|)?IPC_RMID, NULL\\) += 0\n", id);
+	id = -1;
+}
+
+int
+main(void)
+{
+	int rc;
+	struct msqid_ds ds;
+
+	id = msgget(IPC_PRIVATE, 0600);
+	if (id < 0)
+		perror_msg_and_skip("msgget");
+	printf("msgget\\(IPC_PRIVATE, 0600\\) += %d\n", id);
+	atexit(cleanup);
+
+	if (msgctl(id, IPC_STAT, &ds))
+		perror_msg_and_skip("msgctl IPC_STAT");
+	printf("msgctl\\(%d, (IPC_64\\|)?IPC_STAT, \\{msg_perm=\\{uid=%u, gid=%u, "
+		"mode=%#o, key=%u, cuid=%u, cgid=%u\\}, msg_stime=%u, msg_rtime=%u, "
+		"msg_ctime=%u, msg_qnum=%u, msg_qbytes=%u, msg_lspid=%u, "
+		"msg_lrpid=%u\\}\\) += 0\n",
+		id, (unsigned) ds.msg_perm.uid, (unsigned) ds.msg_perm.gid,
+		(unsigned) ds.msg_perm.mode, (unsigned) ds.msg_perm.__key,
+		(unsigned) ds.msg_perm.cuid, (unsigned) ds.msg_perm.cgid,
+		(unsigned) ds.msg_stime, (unsigned) ds.msg_rtime,
+		(unsigned) ds.msg_ctime, (unsigned) ds.msg_qnum,
+		(unsigned) ds.msg_qbytes, (unsigned) ds.msg_lspid,
+		(unsigned) ds.msg_lrpid);
+
+	int max = msgctl(0, MSG_INFO, &ds);
+	if (max < 0)
+		perror_msg_and_skip("msgctl MSG_INFO");
+	printf("msgctl\\(0, (IPC_64\\|)?MSG_INFO, %p\\) += %d\n", &ds, max);
+
+	rc = msgctl(id, MSG_STAT, &ds);
+	if (rc != id) {
+		/*
+		 * In linux < v2.6.24-rc1 the first argument must be
+		 * an index in the kernel's internal array.
+		 */
+		if (-1 != rc || EINVAL != errno)
+			perror_msg_and_skip("msgctl MSG_STAT");
+		printf("msgctl\\(%d, (IPC_64\\|)?MSG_STAT, %p\\) += -1 EINVAL \\(%m\\)\n", id, &ds);
+	} else {
+		printf("msgctl\\(%d, (IPC_64\\|)?MSG_STAT, %p\\) += %d\n", id, &ds, id);
+	}
+
+	return 0;
+}
diff --git a/strace/tests/ipc_msg.test b/strace/tests/ipc_msg.test
new file mode 100755
index 0000000..177495b
--- /dev/null
+++ b/strace/tests/ipc_msg.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of ipc msgget/msgctl syscalls
+
+. "${srcdir=.}/ipc.sh"
diff --git a/strace/tests/ipc_msgbuf.c b/strace/tests/ipc_msgbuf.c
new file mode 100644
index 0000000..2c90d26
--- /dev/null
+++ b/strace/tests/ipc_msgbuf.c
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdlib.h>
+#include <sys/ipc.h>
+#include <sys/msg.h>
+#include <sys/stat.h>
+#include "kernel_types.h"
+
+#define text_string "STRACE_STRING"
+#define msgsz sizeof(text_string)
+
+static int msqid = -1;
+
+static void
+cleanup(void)
+{
+	msgctl(msqid, IPC_RMID, 0);
+	msqid = -1;
+}
+
+int
+main (void)
+{
+	const long mtype = 0xdefaced;
+	struct {
+		kernel_long_t mtype;
+		char mtext[msgsz];
+	} msg = {
+		.mtype = mtype,
+		.mtext = text_string
+	};
+	msqid = msgget(IPC_PRIVATE, IPC_CREAT | S_IRWXU);
+	if (msqid == -1)
+		perror_msg_and_skip("msgget");
+	atexit(cleanup);
+	if (msgsnd(msqid, &msg, msgsz, 0) == -1)
+		perror_msg_and_skip("msgsnd");
+	if (msgrcv(msqid, &msg, msgsz, mtype, 0) != msgsz)
+		perror_msg_and_skip("msgrcv");
+	return 0;
+}
diff --git a/strace/tests/ipc_msgbuf.expected b/strace/tests/ipc_msgbuf.expected
new file mode 100644
index 0000000..880424b
--- /dev/null
+++ b/strace/tests/ipc_msgbuf.expected
@@ -0,0 +1,4 @@
+msgget\(IPC_PRIVATE, IPC_CREAT\|0700\) += [0-9]*
+msgsnd\([0-9]*, \{233811181, "STRACE_STRING\\0"\}, 14, 0\) += 0
+msgrcv\([0-9]*, \{233811181, "STRACE_STRING\\0"\}, 14, 233811181, 0\) += 14
+msgctl\([0-9]*, (IPC_64\|)?IPC_RMID, NULL\) += 0
diff --git a/strace/tests/ipc_msgbuf.test b/strace/tests/ipc_msgbuf.test
new file mode 100755
index 0000000..d0b65d1
--- /dev/null
+++ b/strace/tests/ipc_msgbuf.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check msgget, msgsnd, msgrcv, msgctl syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -v -e msgget,msgsnd,msgrcv,msgctl $args
+match_grep
+
+exit 0
diff --git a/strace/tests/ipc_sem.c b/strace/tests/ipc_sem.c
new file mode 100644
index 0000000..afe74d2
--- /dev/null
+++ b/strace/tests/ipc_sem.c
@@ -0,0 +1,97 @@
+/*
+ * Copyright (c) 2015 Andreas Schwab <schwab@suse.de>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/sem.h>
+
+union semun {
+	int              val;    /* Value for SETVAL */
+	struct semid_ds *buf;    /* Buffer for IPC_STAT, IPC_SET */
+	unsigned short  *array;  /* Array for GETALL, SETALL */
+	struct seminfo  *__buf;  /* Buffer for IPC_INFO
+				    (Linux-specific) */
+};
+
+static int id = -1;
+
+static void
+cleanup(void)
+{
+	semctl(id, 0, IPC_RMID, 0);
+	printf("semctl\\(%d, 0, (IPC_64\\|)?IPC_RMID, \\[?0\\]?\\) += 0\n", id);
+	id = -1;
+}
+
+int
+main(void)
+{
+	int rc;
+	union semun un;
+	struct semid_ds ds;
+	struct seminfo info;
+
+	id = semget(IPC_PRIVATE, 1, 0600);
+	if (id < 0)
+		perror_msg_and_skip("semget");
+	printf("semget\\(IPC_PRIVATE, 1, 0600\\) += %d\n", id);
+	atexit(cleanup);
+
+	un.buf = &ds;
+	if (semctl(id, 0, IPC_STAT, un))
+		perror_msg_and_skip("semctl IPC_STAT");
+	printf("semctl\\(%d, 0, (IPC_64\\|)?IPC_STAT, \\[?%p\\]?\\) += 0\n",
+	       id, &ds);
+
+	un.__buf = &info;
+	int max = semctl(0, 0, SEM_INFO, un);
+	if (max < 0)
+		perror_msg_and_skip("semctl SEM_INFO");
+	printf("semctl\\(0, 0, (IPC_64\\|)?SEM_INFO, \\[?%p\\]?\\) += %d\n",
+	       &info, max);
+
+	un.buf = &ds;
+	rc = semctl(id, 0, SEM_STAT, un);
+	if (rc != id) {
+		/*
+		 * In linux < v2.6.24-rc1 the first argument must be
+		 * an index in the kernel's internal array.
+		 */
+		if (-1 != rc || EINVAL != errno)
+			perror_msg_and_skip("semctl SEM_STAT");
+		printf("semctl\\(%d, 0, (IPC_64\\|)?SEM_STAT, \\[?%p\\]?\\)"
+		       " += -1 EINVAL \\(%m\\)\n", id, &ds);
+	} else {
+		printf("semctl\\(%d, 0, (IPC_64\\|)?SEM_STAT, \\[?%p\\]?\\)"
+		       " += %d\n", id, &ds, id);
+	}
+
+	return 0;
+}
diff --git a/strace/tests/ipc_sem.test b/strace/tests/ipc_sem.test
new file mode 100755
index 0000000..cc93d07
--- /dev/null
+++ b/strace/tests/ipc_sem.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of ipc semget/semctl syscalls
+
+. "${srcdir=.}/ipc.sh"
diff --git a/strace/tests/ipc_shm.c b/strace/tests/ipc_shm.c
new file mode 100644
index 0000000..54723e2
--- /dev/null
+++ b/strace/tests/ipc_shm.c
@@ -0,0 +1,90 @@
+/*
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/shm.h>
+
+static int id = -1;
+
+static void
+cleanup(void)
+{
+	shmctl(id, IPC_RMID, NULL);
+	printf("shmctl\\(%d, (IPC_64\\|)?IPC_RMID, NULL\\) += 0\n", id);
+	id = -1;
+}
+
+int
+main(void)
+{
+	int rc;
+	struct shmid_ds ds;
+
+	id = shmget(IPC_PRIVATE, 1, 0600);
+	if (id < 0)
+		perror_msg_and_skip("shmget");
+	printf("shmget\\(IPC_PRIVATE, 1, 0600\\) += %d\n", id);
+	atexit(cleanup);
+
+	if (shmctl(id, IPC_STAT, &ds))
+		perror_msg_and_skip("shmctl IPC_STAT");
+	printf("shmctl\\(%d, (IPC_64\\|)?IPC_STAT, \\{shm_perm=\\{uid=%u, gid=%u, "
+		"mode=%#o, key=%u, cuid=%u, cgid=%u\\}, shm_segsz=%u, shm_cpid=%u, "
+		"shm_lpid=%u, shm_nattch=%u, shm_atime=%u, shm_dtime=%u, "
+		"shm_ctime=%u\\}\\) += 0\n",
+		id, (unsigned) ds.shm_perm.uid, (unsigned) ds.shm_perm.gid,
+		(unsigned) ds.shm_perm.mode, (unsigned) ds.shm_perm.__key,
+		(unsigned) ds.shm_perm.cuid, (unsigned) ds.shm_perm.cgid,
+		(unsigned) ds.shm_segsz, (unsigned) ds.shm_cpid,
+		(unsigned) ds.shm_lpid, (unsigned) ds.shm_nattch,
+		(unsigned) ds.shm_atime, (unsigned) ds.shm_dtime,
+		(unsigned) ds. shm_ctime);
+
+	int max = shmctl(0, SHM_INFO, &ds);
+	if (max < 0)
+		perror_msg_and_skip("shmctl SHM_INFO");
+	printf("shmctl\\(0, (IPC_64\\|)?SHM_INFO, %p\\) += %d\n", &ds, max);
+
+	rc = shmctl(id, SHM_STAT, &ds);
+	if (rc != id) {
+		/*
+		 * In linux < v2.6.24-rc1 the first argument must be
+		 * an index in the kernel's internal array.
+		 */
+		if (-1 != rc || EINVAL != errno)
+			perror_msg_and_skip("shmctl SHM_STAT");
+		printf("shmctl\\(%d, (IPC_64\\|)?SHM_STAT, %p\\) += -1 EINVAL \\(%m\\)\n", id, &ds);
+	} else {
+		printf("shmctl\\(%d, (IPC_64\\|)?SHM_STAT, %p\\) += %d\n", id, &ds, id);
+	}
+
+	return 0;
+}
diff --git a/strace/tests/ipc_shm.test b/strace/tests/ipc_shm.test
new file mode 100755
index 0000000..a67ea29
--- /dev/null
+++ b/strace/tests/ipc_shm.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check decoding of ipc shmget/shmctl syscalls
+
+. "${srcdir=.}/ipc.sh"
diff --git a/strace/tests/kill.c b/strace/tests/kill.c
new file mode 100644
index 0000000..0755d68
--- /dev/null
+++ b/strace/tests/kill.c
@@ -0,0 +1,79 @@
+/*
+ * Check decoding of kill syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2016 Fei Jie <feij.fnst@cn.fujitsu.com>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_kill
+
+# include <signal.h>
+# include <stdio.h>
+# include <unistd.h>
+
+static void
+handler(int sig)
+{
+}
+
+int
+main(void)
+{
+	const struct sigaction act = { .sa_handler = handler };
+	if (sigaction(SIGALRM, &act, NULL))
+		perror_msg_and_fail("sigaction");
+
+	sigset_t mask;
+	sigemptyset(&mask);
+	sigaddset(&mask, SIGALRM);
+	if (sigprocmask(SIG_UNBLOCK, &mask, NULL))
+		perror_msg_and_fail("sigprocmask");
+
+	const int pid = getpid();
+	long rc = syscall(__NR_kill, pid, (long) 0xdefaced00000000 | SIGALRM);
+	printf("kill(%d, SIGALRM) = %ld\n", pid, rc);
+
+	const long big_pid = (long) 0xfacefeedbadc0ded;
+	const long big_sig = (long) 0xdeadbeefcafef00d;
+	rc = syscall(__NR_kill, big_pid, big_sig);
+	printf("kill(%d, %d) = %ld %s (%m)\n",
+	       (int) big_pid, (int) big_sig, rc, errno2name());
+
+	rc = syscall(__NR_kill, (long) 0xdefaced00000000 | pid, 0);
+	printf("kill(%d, SIG_0) = %ld\n", pid, rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_kill")
+
+#endif
diff --git a/strace/tests/kill.test b/strace/tests/kill.test
new file mode 100755
index 0000000..7a3a51a
--- /dev/null
+++ b/strace/tests/kill.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of kill syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12 -esignal=none
diff --git a/strace/tests/ksysent.c b/strace/tests/ksysent.c
new file mode 100644
index 0000000..66b4ffb
--- /dev/null
+++ b/strace/tests/ksysent.c
@@ -0,0 +1,122 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "syscall.h"
+
+#define TD 0
+#define TF 0
+#define TI 0
+#define TN 0
+#define TP 0
+#define TS 0
+#define TM 0
+#define NF 0
+#define MA 0
+#define SI 0
+#define SE 0
+#define SEN(arg) 0,0
+
+static const struct_sysent syscallent[] = {
+#include "syscallent.h"
+};
+
+typedef const char *pstr_t;
+static const pstr_t ksyslist[] = {
+#include "ksysent.h"
+};
+
+int
+main(void)
+{
+	int rc = 0;
+	unsigned int i;
+
+	for (i = 0; i < ARRAY_SIZE(ksyslist); ++i) {
+		if (!ksyslist[i])
+			continue;
+		if (i >= ARRAY_SIZE(syscallent) || !syscallent[i].sys_name) {
+			fprintf(stderr, "warning: \"%s\" syscall #%u"
+				" is missing in syscallent.h\n",
+				ksyslist[i], i);
+			continue;
+		}
+#ifdef SYS_socket_nsubcalls
+		if (i >= SYS_socket_subcall &&
+		    i < SYS_socket_subcall + SYS_socket_nsubcalls) {
+			fprintf(stderr, "error: \"%s\" syscall #%u"
+				" is a socket subcall in syscallent.h\n",
+				ksyslist[i], i);
+			rc = 1;
+			continue;
+		}
+#endif
+#ifdef SYS_ipc_nsubcalls
+		if (i >= SYS_ipc_subcall &&
+		    i < SYS_ipc_subcall + SYS_ipc_nsubcalls) {
+			fprintf(stderr, "error: \"%s\" syscall #%u"
+				" is an ipc subcall in syscallent.h\n",
+				ksyslist[i], i);
+			rc = 1;
+			continue;
+		}
+#endif
+		if (strcmp(ksyslist[i], syscallent[i].sys_name)) {
+			fprintf(stderr, "error: \"%s\" syscall #%u"
+				" is \"%s\" in syscallent.h\n",
+				ksyslist[i], i, syscallent[i].sys_name);
+			rc = 1;
+			continue;
+		}
+	}
+
+	for (i = 0; i < ARRAY_SIZE(syscallent); ++i) {
+		if (!syscallent[i].sys_name
+#ifdef SYS_socket_nsubcalls
+		    || (i >= SYS_socket_subcall &&
+			i < SYS_socket_subcall + SYS_socket_nsubcalls)
+#endif
+#ifdef SYS_ipc_nsubcalls
+		    || (i >= SYS_ipc_subcall &&
+			i < SYS_ipc_subcall + SYS_ipc_nsubcalls)
+#endif
+#ifdef ARM_FIRST_SHUFFLED_SYSCALL
+		    || (i >= ARM_FIRST_SHUFFLED_SYSCALL &&
+			i <= ARM_FIRST_SHUFFLED_SYSCALL +
+			    ARM_LAST_SPECIAL_SYSCALL + 1)
+#endif
+		   )
+			continue;
+		if (i >= ARRAY_SIZE(ksyslist) || !ksyslist[i]) {
+			fprintf(stderr, "note: unknown syscall #%u"
+				" is \"%s\" in syscallent.h\n",
+				i, syscallent[i].sys_name);
+		}
+	}
+
+	return rc;
+}
diff --git a/strace/tests/ksysent.sed b/strace/tests/ksysent.sed
new file mode 100644
index 0000000..56fe042
--- /dev/null
+++ b/strace/tests/ksysent.sed
@@ -0,0 +1,15 @@
+#!/bin/sed -nf
+
+# should not have been exported at all
+/#define[[:space:]]\+__NR_\(sys_epoll_\|arch_specific_syscall\|syscalls\|syscall_count\|syscall_max\|available\|reserved\|unused\)/d
+
+# should not be named this way
+s/__NR_\(arm\|xtensa\)_fadvise64_64/__NR_fadvise64_64/
+
+# legacy names
+s/__NR_get_cpu/__NR_getcpu/
+s/__NR_madvise1/__NR_madvise/
+s/__NR_paccept/__NR_accept4/
+
+# generate
+s/#define[[:space:]]\+__NR_\([a-z_][^[:space:]]\+\)\([[:space:]].*\)\?$/#ifdef __NR_\1\n[__NR_\1 \& 0xffff] = "\1",\n#endif/p
diff --git a/strace/tests/ksysent.test b/strace/tests/ksysent.test
new file mode 100755
index 0000000..8026648
--- /dev/null
+++ b/strace/tests/ksysent.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Validate syscallent.h
+
+./ksysent
diff --git a/strace/tests/lchown.c b/strace/tests/lchown.c
new file mode 100644
index 0000000..a116901
--- /dev/null
+++ b/strace/tests/lchown.c
@@ -0,0 +1,19 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_lchown
+
+# define SYSCALL_NR __NR_lchown
+# define SYSCALL_NAME "lchown"
+
+# if defined __NR_lchown32 && __NR_lchown != __NR_lchown32
+#  define UGID_TYPE_IS_SHORT
+# endif
+
+# include "xchownx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_lchown")
+
+#endif
diff --git a/strace/tests/lchown.test b/strace/tests/lchown.test
new file mode 100755
index 0000000..ceeaa85
--- /dev/null
+++ b/strace/tests/lchown.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check lchown syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a30
diff --git a/strace/tests/lchown32.c b/strace/tests/lchown32.c
new file mode 100644
index 0000000..ff5ad3e
--- /dev/null
+++ b/strace/tests/lchown32.c
@@ -0,0 +1,14 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_lchown32
+
+# define SYSCALL_NR __NR_lchown32
+# define SYSCALL_NAME "lchown32"
+# include "xchownx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_lchown32")
+
+#endif
diff --git a/strace/tests/lchown32.test b/strace/tests/lchown32.test
new file mode 100755
index 0000000..6ee1ac9
--- /dev/null
+++ b/strace/tests/lchown32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check lchown32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a32
diff --git a/strace/tests/libmmsg.c b/strace/tests/libmmsg.c
new file mode 100644
index 0000000..07feb7c
--- /dev/null
+++ b/strace/tests/libmmsg.c
@@ -0,0 +1,69 @@
+/*
+ * Wrappers for recvmmsg and sendmmsg syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <sys/syscall.h>
+
+#ifndef __NR_recvmmsg
+# define __NR_recvmmsg -1
+#endif
+#define SC_recvmmsg 19
+
+#ifndef __NR_sendmmsg
+# define __NR_sendmmsg -1
+#endif
+#define SC_sendmmsg 20
+
+int
+recv_mmsg(const int fd, struct mmsghdr *const vec,
+	  const unsigned int vlen, const unsigned int flags,
+	  struct timespec *const timeout)
+{
+	int rc = socketcall(__NR_recvmmsg, SC_recvmmsg,
+			    fd, (long) vec, vlen, flags, (long) timeout);
+
+	if (rc < 0 && ENOSYS == errno)
+		perror_msg_and_skip("recvmmsg");
+
+	return rc;
+}
+
+int
+send_mmsg(const int fd, struct mmsghdr *const vec,
+	  const unsigned int vlen, const unsigned int flags)
+{
+	int rc = socketcall(__NR_sendmmsg, SC_sendmmsg,
+			    fd, (long) vec, vlen, flags, 0);
+
+	if (rc < 0 && ENOSYS == errno)
+		perror_msg_and_skip("sendmmsg");
+
+	return rc;
+}
diff --git a/strace/tests/libsocketcall.c b/strace/tests/libsocketcall.c
new file mode 100644
index 0000000..718b50e
--- /dev/null
+++ b/strace/tests/libsocketcall.c
@@ -0,0 +1,69 @@
+/*
+ * Invoke a socket syscall, either directly or via __NR_socketcall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+/*
+ * Invoke a socket syscall, either directly or via __NR_socketcall.
+ * if nr == -1, no direct syscall invocation will be made.
+ */
+int
+socketcall(const int nr, const int call,
+	   long a1, long a2, long a3, long a4, long a5)
+{
+	int rc = -1;
+	errno = ENOSYS;
+
+# ifdef __NR_socketcall
+	static int have_socketcall = -1;
+
+	if (have_socketcall < 0) {
+		if (syscall(__NR_socketcall, 0L, 0L, 0L, 0L, 0L) < 0
+		    && EINVAL == errno) {
+			have_socketcall = 1;
+		} else {
+			have_socketcall = 0;
+		}
+	}
+
+	if (have_socketcall) {
+		const long args[] = { a1, a2, a3, a4, a5 };
+		rc = syscall(__NR_socketcall, call, args);
+	} else
+# endif
+	{
+		if (nr != -1)
+			rc = syscall(nr, a1, a2, a3, a4, a5);
+	}
+
+	return rc;
+}
diff --git a/strace/tests/link.c b/strace/tests/link.c
new file mode 100644
index 0000000..4b84e41
--- /dev/null
+++ b/strace/tests/link.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_link
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample_1[] = "link_sample_old";
+	static const char sample_2[] = "link_sample_new";
+
+	long rc = syscall(__NR_link, sample_1, sample_2);
+	printf("link(\"%s\", \"%s\") = %ld %s (%m)\n",
+	       sample_1, sample_2, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_link")
+
+#endif
diff --git a/strace/tests/link.test b/strace/tests/link.test
new file mode 100755
index 0000000..cfa2b0c
--- /dev/null
+++ b/strace/tests/link.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check link syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/linkat.c b/strace/tests/linkat.c
new file mode 100644
index 0000000..06d550e
--- /dev/null
+++ b/strace/tests/linkat.c
@@ -0,0 +1,37 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_linkat
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample_1[] = "linkat_sample_old";
+	static const char sample_2[] = "linkat_sample_new";
+	const long fd_old = (long) 0xdeadbeefffffffff;
+	const long fd_new = (long) 0xdeadbeeffffffffe;
+
+	long rc = syscall(__NR_linkat, fd_old, sample_1, fd_new, sample_2, 0);
+	printf("linkat(%d, \"%s\", %d, \"%s\", 0) = %ld %s (%m)\n",
+	       (int) fd_old, sample_1, (int) fd_new, sample_2,
+	       rc, errno2name());
+
+	rc = syscall(__NR_linkat, -100, sample_1, -100, sample_2, -1L);
+	printf("linkat(%s, \"%s\", %s, \"%s\", %s) = %ld %s (%m)\n",
+	       "AT_FDCWD", sample_1, "AT_FDCWD", sample_2,
+	       "AT_SYMLINK_NOFOLLOW|AT_REMOVEDIR|AT_SYMLINK_FOLLOW"
+	       "|AT_NO_AUTOMOUNT|AT_EMPTY_PATH|0xffffe0ff",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_linkat")
+
+#endif
diff --git a/strace/tests/linkat.test b/strace/tests/linkat.test
new file mode 100755
index 0000000..5627de7
--- /dev/null
+++ b/strace/tests/linkat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check linkat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/llseek.c b/strace/tests/llseek.c
new file mode 100644
index 0000000..e82535a
--- /dev/null
+++ b/strace/tests/llseek.c
@@ -0,0 +1,56 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR__llseek
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const unsigned long high = 0xfacefeed;
+	const unsigned long low = 0xdeadbeef;
+	const long long offset = 0xfacefeeddeadbeefLL;
+	unsigned long long result;
+
+	long rc = syscall(__NR__llseek, -1, high, low, &result, SEEK_SET);
+	printf("_llseek(-1, %lld, %p, SEEK_SET) = %ld %s (%m)\n",
+	       offset, &result, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR__llseek")
+
+#endif
diff --git a/strace/tests/llseek.test b/strace/tests/llseek.test
new file mode 100755
index 0000000..cf1607e
--- /dev/null
+++ b/strace/tests/llseek.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check _llseek syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog > /dev/null
+run_strace -e_llseek $args > "$EXP"
+grep -v '^lseek([0-9]' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/lseek.c b/strace/tests/lseek.c
new file mode 100644
index 0000000..e5efaa3
--- /dev/null
+++ b/strace/tests/lseek.c
@@ -0,0 +1,64 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_lseek
+
+# include <stdio.h>
+# include <unistd.h>
+# include "kernel_types.h"
+
+int
+main(void)
+{
+	const kernel_ulong_t offset = (kernel_ulong_t) 0xfacefeeddeadbeefULL;
+
+	if (sizeof(offset) > sizeof(long)) {
+		/*
+		 * Cannot use syscall because it takes long arguments.
+		 * Let's call lseek with hope it will invoke lseek syscall.
+		 */
+		long long rc = lseek(-1, offset, SEEK_SET);
+		printf("lseek(-1, %lld, SEEK_SET) = %lld %s (%m)\n",
+		       (long long) offset, rc, errno2name());
+	} else {
+		long rc = syscall(__NR_lseek, -1L, offset, SEEK_SET);
+		printf("lseek(-1, %ld, SEEK_SET) = %ld %s (%m)\n",
+		       (long) offset, rc, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_lseek")
+
+#endif
diff --git a/strace/tests/lseek.test b/strace/tests/lseek.test
new file mode 100755
index 0000000..f96a91d
--- /dev/null
+++ b/strace/tests/lseek.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# Check lseek syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog > /dev/null
+run_strace -a30 -elseek $args > "$EXP"
+grep -v '^lseek([0-9]' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/lstat.c b/strace/tests/lstat.c
new file mode 100644
index 0000000..663b638
--- /dev/null
+++ b/strace/tests/lstat.c
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_lstat
+
+# define TEST_SYSCALL_NR __NR_lstat
+# define TEST_SYSCALL_STR "lstat"
+# define SAMPLE_SIZE ((kernel_ulong_t) 43147718418)
+# include "lstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_lstat")
+
+#endif
diff --git a/strace/tests/lstat.test b/strace/tests/lstat.test
new file mode 100755
index 0000000..f513bb4
--- /dev/null
+++ b/strace/tests/lstat.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check lstat syscall decoding.
+
+. "${srcdir=.}/statx.sh"
diff --git a/strace/tests/lstat64.c b/strace/tests/lstat64.c
new file mode 100644
index 0000000..4a1858b
--- /dev/null
+++ b/strace/tests/lstat64.c
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_lstat64
+
+# define TEST_SYSCALL_NR __NR_lstat64
+# define TEST_SYSCALL_STR "lstat64"
+# define STRUCT_STAT struct stat64
+# define STRUCT_STAT_STR "struct stat64"
+# define SAMPLE_SIZE ((libc_off_t) 43147718418)
+# include "lstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_lstat64")
+
+#endif
diff --git a/strace/tests/lstat64.test b/strace/tests/lstat64.test
new file mode 100755
index 0000000..fcafe79
--- /dev/null
+++ b/strace/tests/lstat64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check lstat64 syscall decoding.
+
+. "${srcdir=.}/statx.sh"
diff --git a/strace/tests/lstatx.c b/strace/tests/lstatx.c
new file mode 100644
index 0000000..2bd4e9f
--- /dev/null
+++ b/strace/tests/lstatx.c
@@ -0,0 +1,37 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define TEST_SYSCALL_INVOKE(sample, pst) \
+	syscall(TEST_SYSCALL_NR, sample, pst)
+#define PRINT_SYSCALL_HEADER(sample) \
+	printf("%s(\"%s\", ", TEST_SYSCALL_STR, sample)
+#define PRINT_SYSCALL_FOOTER \
+	puts(") = 0")
+
+#define USE_ASM_STAT
+
+#include "xstatx.c"
diff --git a/strace/tests/match.awk b/strace/tests/match.awk
new file mode 100644
index 0000000..abfbae9
--- /dev/null
+++ b/strace/tests/match.awk
@@ -0,0 +1,53 @@
+#!/bin/gawk
+#
+# Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+# s[] is array of match strings
+# r[] is array of match patterns
+
+NR > lines { next }
+
+{
+	if (s[NR]) {
+		if ($0 == s[NR])
+			next
+		print "Line " NR " does not match expected string: " s[NR]
+	} else {
+		if (match($0, r[NR]))
+			next
+		print "Line " NR " does not match expected pattern: " r[NR]
+	}
+
+	fail = 1
+}
+
+END {
+	if (fail == 0 && NR != lines) {
+		fail = 1
+		print "Expected " lines " lines, found " NR " line(s)."
+	}
+	exit fail
+}
diff --git a/strace/tests/mbind.c b/strace/tests/mbind.c
new file mode 100644
index 0000000..b0f044d
--- /dev/null
+++ b/strace/tests/mbind.c
@@ -0,0 +1,61 @@
+/*
+ * Check decoding of mbind syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_mbind
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const unsigned long len = (unsigned long) 0xcafef00dbadc0ded;
+	const unsigned long mode = 3;
+	const unsigned long nodemask = (unsigned long) 0xfacefeedfffffff1;
+	const unsigned long maxnode = (unsigned long) 0xdeadbeeffffffff2;
+	const unsigned long flags = -1UL;
+
+	long rc = syscall(__NR_mbind, 0, len, mode, nodemask, maxnode, flags);
+	printf("mbind(NULL, %lu, %s, %#lx, %lu, %s|%#x) = %ld %s (%m)\n",
+	       len, "MPOL_INTERLEAVE", nodemask, maxnode,
+	       "MPOL_MF_STRICT|MPOL_MF_MOVE|MPOL_MF_MOVE_ALL",
+	       (unsigned) flags & ~7, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mbind")
+
+#endif
diff --git a/strace/tests/mbind.test b/strace/tests/mbind.test
new file mode 100755
index 0000000..2a07cac
--- /dev/null
+++ b/strace/tests/mbind.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of mbind syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/membarrier.c b/strace/tests/membarrier.c
new file mode 100644
index 0000000..7364d0f
--- /dev/null
+++ b/strace/tests/membarrier.c
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_membarrier
+
+# include <assert.h>
+# include <errno.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	assert(syscall(__NR_membarrier, 3, 255) == -1);
+	printf("membarrier(0x3 /* MEMBARRIER_CMD_??? */, 255) = -1 %s (%m)\n",
+	       errno2name());
+	if (errno != ENOSYS) {
+		/* the test needs to be updated? */
+		assert(syscall(__NR_membarrier, 0, 0) == 1);
+		puts("membarrier(MEMBARRIER_CMD_QUERY, 0)"
+		     " = 0x1 (MEMBARRIER_CMD_SHARED)");
+	}
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_membarrier")
+
+#endif
diff --git a/strace/tests/membarrier.test b/strace/tests/membarrier.test
new file mode 100755
index 0000000..ad1f713
--- /dev/null
+++ b/strace/tests/membarrier.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check membarrier syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a36
diff --git a/strace/tests/memfd_create.c b/strace/tests/memfd_create.c
new file mode 100644
index 0000000..9fe7f6d
--- /dev/null
+++ b/strace/tests/memfd_create.c
@@ -0,0 +1,18 @@
+#include "tests.h"
+#include <unistd.h>
+#include <sys/syscall.h>
+
+#ifdef __NR_memfd_create
+
+int
+main(void)
+{
+	syscall(__NR_memfd_create, "strace", 7);
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_memfd_create")
+
+#endif
diff --git a/strace/tests/memfd_create.expected b/strace/tests/memfd_create.expected
new file mode 100644
index 0000000..6fb938f
--- /dev/null
+++ b/strace/tests/memfd_create.expected
@@ -0,0 +1 @@
+memfd_create\("strace", MFD_CLOEXEC\|MFD_ALLOW_SEALING\|0x4\) += -1 .*
diff --git a/strace/tests/memfd_create.test b/strace/tests/memfd_create.test
new file mode 100755
index 0000000..6a34fc1
--- /dev/null
+++ b/strace/tests/memfd_create.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check memfd_create syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -e memfd_create $args
+match_grep
+
+exit 0
diff --git a/strace/tests/migrate_pages.c b/strace/tests/migrate_pages.c
new file mode 100644
index 0000000..995723c
--- /dev/null
+++ b/strace/tests/migrate_pages.c
@@ -0,0 +1,54 @@
+/*
+ * Check decoding of migrate_pages syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_migrate_pages
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long pid = (long) 0xfacefeedffffffff;
+	long rc = syscall(__NR_migrate_pages, pid, 0, 0, 0);
+	printf("migrate_pages(%d, 0, NULL, NULL) = %ld %s (%m)\n",
+	       (int) pid, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_migrate_pages")
+
+#endif
diff --git a/strace/tests/migrate_pages.test b/strace/tests/migrate_pages.test
new file mode 100755
index 0000000..fad53b7
--- /dev/null
+++ b/strace/tests/migrate_pages.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check migrate_pages syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a33
diff --git a/strace/tests/mincore.c b/strace/tests/mincore.c
new file mode 100644
index 0000000..ff2922a
--- /dev/null
+++ b/strace/tests/mincore.c
@@ -0,0 +1,80 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <sys/mman.h>
+
+#define DEFAULT_STRLEN 32
+
+static void
+print_mincore(const unsigned int pages, void *const addr,
+	      const size_t size, unsigned char *const vec)
+{
+	unsigned int i;
+
+	if (mincore(addr, size, vec))
+		perror_msg_and_skip("mincore");
+
+	printf("mincore(%p, %zu, [", addr, size);
+	for (i = 0; i < pages; ++i) {
+		if (i >= DEFAULT_STRLEN) {
+			printf("...");
+			break;
+		}
+		printf("%u", vec[i] & 1);
+	}
+	puts("]) = 0");
+}
+
+static void
+test_mincore(const unsigned int pages)
+{
+	const size_t page_size = get_page_size();
+	const size_t size = pages * page_size;
+	void *const addr = tail_alloc(size);
+	unsigned char *const vec = tail_alloc(pages);
+
+	mincore(addr, size, NULL);
+	printf("mincore(%p, %zu, NULL) = -1 %s (%m)\n",
+	       addr, size, errno2name());
+
+	print_mincore(pages, addr, size, vec);
+	if (size)
+		print_mincore(pages, addr, size - page_size + 1, vec);
+}
+
+int main(void)
+{
+	test_mincore(1);
+	test_mincore(2);
+	test_mincore(DEFAULT_STRLEN);
+	test_mincore(DEFAULT_STRLEN + 1);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/mincore.test b/strace/tests/mincore.test
new file mode 100755
index 0000000..6af9f49
--- /dev/null
+++ b/strace/tests/mincore.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mincore syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22
diff --git a/strace/tests/mkdir.c b/strace/tests/mkdir.c
new file mode 100644
index 0000000..dbb43c3
--- /dev/null
+++ b/strace/tests/mkdir.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_mkdir
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "mkdir";
+
+	long rc = syscall(__NR_mkdir, sample, 0600);
+	printf("mkdir(\"%s\", 0600) = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mkdir")
+
+#endif
diff --git a/strace/tests/mkdir.test b/strace/tests/mkdir.test
new file mode 100755
index 0000000..98d5a52
--- /dev/null
+++ b/strace/tests/mkdir.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mkdir syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21
diff --git a/strace/tests/mkdirat.c b/strace/tests/mkdirat.c
new file mode 100644
index 0000000..cbdf16c
--- /dev/null
+++ b/strace/tests/mkdirat.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_mkdirat
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "mkdirat.sample";
+	const long fd = (long) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_mkdirat, fd, sample, 0600);
+	printf("mkdirat(%d, \"%s\", 0600) = %ld %s (%m)\n",
+	       (int) fd, sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mkdirat")
+
+#endif
diff --git a/strace/tests/mkdirat.test b/strace/tests/mkdirat.test
new file mode 100755
index 0000000..e41ce35
--- /dev/null
+++ b/strace/tests/mkdirat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mkdirat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a36
diff --git a/strace/tests/mknod.c b/strace/tests/mknod.c
new file mode 100644
index 0000000..91ce751
--- /dev/null
+++ b/strace/tests/mknod.c
@@ -0,0 +1,60 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_mknod
+
+# include <stdio.h>
+# include <sys/stat.h>
+# include <unistd.h>
+
+# ifdef MAJOR_IN_SYSMACROS
+#  include <sys/sysmacros.h>
+# endif
+# ifdef MAJOR_IN_MKDEV
+#  include <sys/mkdev.h>
+# endif
+
+# define TMP_FILE "mknod"
+
+int
+main(void)
+{
+	long rc = syscall(__NR_mknod, TMP_FILE, 0, 0xdeadbeef);
+	printf("mknod(\"%s\", 0) = %ld %s (%m)\n",
+	       TMP_FILE, rc, errno2name());
+
+	rc = syscall(__NR_mknod, TMP_FILE, -1L, 0xdeadbeef);
+	printf("mknod(\"%s\", %#o) = %ld %s (%m)\n",
+	       TMP_FILE, -1, rc, errno2name());
+
+	rc = syscall(__NR_mknod, TMP_FILE, S_IFREG|0600, 0);
+	printf("mknod(\"%s\", S_IFREG|0600) = %ld %s (%m)\n",
+	       TMP_FILE, rc, errno2name());
+
+	unsigned long dev =
+		(unsigned long) 0xdeadbeef00000000 | makedev(1, 7);
+
+	rc = syscall(__NR_mknod, TMP_FILE, S_IFCHR | 0400, dev);
+	printf("mknod(\"%s\", S_IFCHR|0400, makedev(1, 7)) = %ld %s (%m)\n",
+	       TMP_FILE, rc, errno2name());
+
+	const unsigned long mode =
+		((unsigned long) 0xfacefeedffffffff & ~S_IFMT) | S_IFBLK;
+	dev = (unsigned long) 0xdeadbeefbadc0ded;
+
+	rc = syscall(__NR_mknod, TMP_FILE, mode, dev);
+	printf("mknod(\"%s\", S_IFBLK|S_ISUID|S_ISGID|S_ISVTX|%#o"
+	       ", makedev(%u, %u)) = %ld %s (%m)\n",
+	       TMP_FILE, (unsigned) mode & ~(S_IFMT|S_ISUID|S_ISGID|S_ISVTX),
+	       major((unsigned) dev), minor((unsigned) dev),
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mknod")
+
+#endif
diff --git a/strace/tests/mknod.test b/strace/tests/mknod.test
new file mode 100755
index 0000000..195f1e3
--- /dev/null
+++ b/strace/tests/mknod.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mknod syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a18
diff --git a/strace/tests/mknodat.c b/strace/tests/mknodat.c
new file mode 100644
index 0000000..2cdc47c
--- /dev/null
+++ b/strace/tests/mknodat.c
@@ -0,0 +1,41 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_mknodat
+
+# include <stdio.h>
+# include <sys/stat.h>
+# include <unistd.h>
+
+# ifdef MAJOR_IN_SYSMACROS
+#  include <sys/sysmacros.h>
+# endif
+# ifdef MAJOR_IN_MKDEV
+#  include <sys/mkdev.h>
+# endif
+
+int
+main(void)
+{
+	static const char sample[] = "mknokat_sample";
+	const long int fd = (long int) 0xdeadbeefffffffff;
+	long rc = syscall(__NR_mknodat, fd, sample, S_IFREG|0600, 0);
+	printf("mknodat(%d, \"%s\", S_IFREG|0600) = %ld %s (%m)\n",
+	       (int) fd, sample, rc, errno2name());
+
+	const unsigned long dev =
+		(unsigned long) 0xdeadbeef00000000 | makedev(1, 7);
+
+	rc = syscall(__NR_mknodat, fd, sample, S_IFCHR | 0400, dev);
+	printf("mknodat(%d, \"%s\", S_IFCHR|0400, makedev(1, 7)) = %ld %s (%m)\n",
+	       (int) fd, sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mknodat")
+
+#endif
diff --git a/strace/tests/mknodat.test b/strace/tests/mknodat.test
new file mode 100755
index 0000000..edf0498
--- /dev/null
+++ b/strace/tests/mknodat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mknodat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/mlock.c b/strace/tests/mlock.c
new file mode 100644
index 0000000..a56dc1f
--- /dev/null
+++ b/strace/tests/mlock.c
@@ -0,0 +1,37 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_mlock && defined __NR_munlock
+
+# include <stdio.h>
+# include <unistd.h>
+
+const int size = 1024;
+
+int
+main(void)
+{
+	const char *addr = tail_alloc(size);
+	if (syscall(__NR_mlock, addr, size) == 0) {
+		printf("mlock(%p, %d) = 0\n", addr, size);
+	} else {
+		printf("mlock(%p, %d) = -1 %s (%m)\n",
+		       addr, size, errno2name());
+	}
+
+	if (syscall(__NR_munlock, addr, size) == 0) {
+		printf("munlock(%p, %d) = 0\n", addr, size);
+	} else {
+		printf("munlock(%p, %d) = -1 %s (%m)\n",
+		       addr, size, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_DEFINED("__NR_mlock && __NR_munlock")
+
+#endif
diff --git a/strace/tests/mlock.test b/strace/tests/mlock.test
new file mode 100755
index 0000000..9a73a30
--- /dev/null
+++ b/strace/tests/mlock.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mlock and munlock syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=mlock,munlock -a20
diff --git a/strace/tests/mlock2.c b/strace/tests/mlock2.c
new file mode 100644
index 0000000..af63917
--- /dev/null
+++ b/strace/tests/mlock2.c
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_mlock2
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_mlock2, 0xdeadbeef, 0xdefaced, 0xffff);
+	printf("mlock2(0xdeadbeef, 233811181, MLOCK_ONFAULT|0xfffe)"
+	       " = %ld %s (%m)\n", rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mlock2")
+
+#endif
diff --git a/strace/tests/mlock2.test b/strace/tests/mlock2.test
new file mode 100755
index 0000000..bc412e9
--- /dev/null
+++ b/strace/tests/mlock2.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mlock2 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/mlockall.c b/strace/tests/mlockall.c
new file mode 100644
index 0000000..cafa4d6
--- /dev/null
+++ b/strace/tests/mlockall.c
@@ -0,0 +1,47 @@
+/*
+ * Check decoding of mlockall syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <stdio.h>
+#include <sys/mman.h>
+
+int
+main(void)
+{
+	printf("mlockall(0) = %d EINVAL (%m)\n", mlockall(0));
+
+	if (mlockall(MCL_CURRENT) == 0)
+		puts("mlockall(MCL_CURRENT) = 0");
+	else
+		printf("mlockall(MCL_CURRENT) = -1 %s (%m)\n", errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/mlockall.test b/strace/tests/mlockall.test
new file mode 100755
index 0000000..d7a6182
--- /dev/null
+++ b/strace/tests/mlockall.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of mlockall syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12
diff --git a/strace/tests/mmap.c b/strace/tests/mmap.c
new file mode 100644
index 0000000..e2ff716
--- /dev/null
+++ b/strace/tests/mmap.c
@@ -0,0 +1,106 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <stdint.h>
+#include <unistd.h>
+#include <limits.h>
+#include <sys/mman.h>
+
+int
+main(int ac, char **av)
+{
+	const char *const name = ac > 1 ? av[1] : "mmap";
+	const intmax_t pagesize = get_page_size();
+	const unsigned long length1 = pagesize * 6;
+	const unsigned long length2 = pagesize * 3;
+	const unsigned long length3 = pagesize * 2;
+	const int fd = -1;
+	off_t offset;
+	void *addr, *p;
+
+#if ULONG_MAX > 4294967295UL
+	offset = 0xcafedeadbeef000 & -pagesize;
+	addr = (void *) (uintmax_t) (0xfacefeed000 & -pagesize);
+#else
+	offset = 0xdeadbeef000 & -pagesize;
+	addr = (void *) (unsigned int) (0xfaced000 & -pagesize);
+#endif
+	const uintmax_t uoffset =
+	       sizeof(offset) == sizeof(int) ? (uintmax_t) (unsigned int) offset
+					     : (uintmax_t) offset;
+
+	(void) close(0);
+	(void) close(0);
+	printf("%s(NULL, 0, PROT_NONE, MAP_FILE, 0, 0) = -1 EBADF (%m)\n",
+	       name);
+	mmap(NULL, 0, PROT_NONE, MAP_FILE, 0, 0);
+
+	p = mmap(addr, length1, PROT_READ | PROT_WRITE,
+		 MAP_PRIVATE | MAP_ANONYMOUS, fd, offset);
+	if (MAP_FAILED == p)
+		perror_msg_and_fail("mmap");
+	printf("%s(%p, %lu, PROT_READ|PROT_WRITE, "
+	       "MAP_PRIVATE|MAP_ANONYMOUS, %d, %#jx) = %p\n",
+	       name, addr, length1, fd, uoffset, p);
+
+	if (msync(p, length1, MS_SYNC))
+		perror_msg_and_fail("msync");
+	printf("msync(%p, %lu, MS_SYNC) = 0\n", p, length1);
+
+	if (mprotect(p, length1, PROT_NONE))
+		perror_msg_and_fail("mprotect");
+	printf("mprotect(%p, %lu, PROT_NONE) = 0\n", p, length1);
+
+	addr = mremap(p, length1, length2, 0);
+	if (MAP_FAILED == addr)
+		perror_msg_and_fail("mremap");
+	printf("mremap(%p, %lu, %lu, 0) = %p\n", p, length1, length2, addr);
+
+	p =  mremap(addr, length2, length3, MREMAP_MAYMOVE | MREMAP_FIXED,
+		    addr + length2);
+	if (MAP_FAILED == p)
+		perror_msg_and_fail("mremap");
+	printf("mremap(%p, %lu, %lu, MREMAP_MAYMOVE|MREMAP_FIXED"
+	       ", %p) = %p\n", addr, length2, length3, addr + length2, p);
+
+	if (madvise(p, length3, MADV_NORMAL))
+		perror_msg_and_fail("madvise");
+	printf("madvise(%p, %lu, MADV_NORMAL) = 0\n", p, length3);
+
+	if (munmap(p, length3))
+		perror_msg_and_fail("munmap");
+	printf("munmap(%p, %lu) = 0\n", p, length3);
+
+	if (mlockall(MCL_FUTURE))
+		perror_msg_and_fail("mlockall");
+	puts("mlockall(MCL_FUTURE) = 0");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/mmap.test b/strace/tests/mmap.test
new file mode 100755
index 0000000..0b87114
--- /dev/null
+++ b/strace/tests/mmap.test
@@ -0,0 +1,58 @@
+#!/bin/sh
+#
+# Check mmap/mmap2, madvise, mlockall, mprotect, mremap, msync, and munmap
+# syscalls decoding.
+#
+# Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+check_prog sed
+run_prog > /dev/null
+
+syscall=
+for n in mmap mmap2; do
+	$STRACE -e$n -h > /dev/null && syscall=$syscall,$n
+done
+run_strace -e$syscall $args > /dev/null
+
+if grep '^mmap(NULL, 0, PROT_NONE,' < "$LOG" > /dev/null; then
+	mmap=mmap
+elif grep '^mmap2(NULL, 0, PROT_NONE,' < "$LOG" > /dev/null; then
+	mmap=mmap2
+else
+	dump_log_and_fail_with "mmap/mmap2 not found in $STRACE $args output"
+fi
+
+syscall=$mmap,madvise,mlockall,mprotect,mremap,msync,munmap
+
+run_prog "./$NAME" $mmap > /dev/null
+run_strace -a20 -e$syscall $args > "$EXP"
+sed -n "/^$mmap(NULL, 0, PROT_NONE,/,\$p" < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/mmap64.c b/strace/tests/mmap64.c
new file mode 100644
index 0000000..b31ce42
--- /dev/null
+++ b/strace/tests/mmap64.c
@@ -0,0 +1 @@
+#include "mmap.c"
diff --git a/strace/tests/mmap64.test b/strace/tests/mmap64.test
new file mode 100755
index 0000000..51f1896
--- /dev/null
+++ b/strace/tests/mmap64.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check mmap/mprotect/munmap syscalls decoding.
+# Target executable was compiled with -D_FILE_OFFSET_BITS=64.
+
+. "${srcdir=.}/mmap.test"
diff --git a/strace/tests/mmsg-silent.c b/strace/tests/mmsg-silent.c
new file mode 100644
index 0000000..47d0a50
--- /dev/null
+++ b/strace/tests/mmsg-silent.c
@@ -0,0 +1,63 @@
+/*
+ * Check silent decoding of sendmmsg and recvmmsg syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+
+#include "msghdr.h"
+
+int
+main(void)
+{
+	int fds[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds))
+		perror_msg_and_skip("socketpair");
+
+	char buf = 'A';
+	struct iovec iov = { .iov_base = &buf, .iov_len = sizeof(buf) };
+	struct mmsghdr mh = {
+		.msg_hdr = {
+			.msg_iov = &iov,
+			.msg_iovlen = 1
+		}
+	};
+
+	int rc = send_mmsg(fds[1], &mh, 1, MSG_DONTWAIT);
+	if (rc < 0)
+		perror_msg_and_skip("sendmmsg");
+	printf("sendmmsg(%d, %p, 1, MSG_DONTWAIT) = %d\n", fds[1], &mh, rc);
+
+	struct timespec t = { .tv_sec = 0, .tv_nsec = 12345678 };
+	rc = recv_mmsg(fds[0], &mh, 1, MSG_DONTWAIT, &t);
+	printf("recvmmsg(%d, %p, 1, MSG_DONTWAIT, %p) = %d\n",
+	       fds[0], &mh, &t, rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/mmsg-silent.test b/strace/tests/mmsg-silent.test
new file mode 100755
index 0000000..775e0ad
--- /dev/null
+++ b/strace/tests/mmsg-silent.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check silent decoding of sendmmsg and recvmmsg syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a25 -e verbose=none -e trace=sendmmsg,recvmmsg
diff --git a/strace/tests/mmsg.c b/strace/tests/mmsg.c
new file mode 100644
index 0000000..88805d1
--- /dev/null
+++ b/strace/tests/mmsg.c
@@ -0,0 +1,195 @@
+/*
+ * Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <unistd.h>
+
+#include "msghdr.h"
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (socketpair(AF_UNIX, SOCK_DGRAM, 0, fds))
+		perror_msg_and_skip("socketpair");
+	assert(0 == fds[0]);
+	assert(1 == fds[1]);
+
+	static const char w0_c[] = "012";
+	const char *w0_d = hexdump_strdup(w0_c);
+	void *w0 = tail_memdup(w0_c, LENGTH_OF(w0_c));
+
+	static const char w1_c[] = "34567";
+	const char *w1_d = hexdump_strdup(w1_c);
+	void *w1 = tail_memdup(w1_c, LENGTH_OF(w1_c));
+
+	static const char w2_c[] = "89abcde";
+	const char *w2_d = hexdump_strdup(w2_c);
+	void *w2 = tail_memdup(w2_c, LENGTH_OF(w2_c));
+
+	const struct iovec w0_iov_[] = {
+		{
+			.iov_base = w0,
+			.iov_len = LENGTH_OF(w0_c)
+		}, {
+			.iov_base = w1,
+			.iov_len = LENGTH_OF(w1_c)
+		}
+	};
+	struct iovec *w0_iov = tail_memdup(w0_iov_, sizeof(w0_iov_));
+
+	const struct iovec w1_iov_[] = {
+		{
+			.iov_base = w2,
+			.iov_len = LENGTH_OF(w2_c)
+		}
+	};
+	struct iovec *w1_iov = tail_memdup(w1_iov_, sizeof(w1_iov_));
+
+	const struct mmsghdr w_mmh_[] = {
+		{
+			.msg_hdr = {
+				.msg_iov = w0_iov,
+				.msg_iovlen = ARRAY_SIZE(w0_iov_),
+			}
+		}, {
+			.msg_hdr = {
+				.msg_iov = w1_iov,
+				.msg_iovlen = ARRAY_SIZE(w1_iov_),
+			}
+		}
+	};
+	void *w_mmh = tail_memdup(w_mmh_, sizeof(w_mmh_));
+	const unsigned int n_w_mmh = ARRAY_SIZE(w_mmh_);
+
+	int r = send_mmsg(1, w_mmh, n_w_mmh, MSG_DONTROUTE | MSG_NOSIGNAL);
+	if (r < 0)
+		perror_msg_and_skip("sendmmsg");
+	assert(r == (int) n_w_mmh);
+	assert(close(1) == 0);
+	tprintf("sendmmsg(1, [{msg_hdr={msg_name=NULL, msg_namelen=0"
+		", msg_iov=[{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}], msg_iovlen=%u"
+		", msg_controllen=0, msg_flags=0}, msg_len=%u}"
+		", {msg_hdr={msg_name=NULL, msg_namelen=0"
+		", msg_iov=[{iov_base=\"%s\", iov_len=%u}], msg_iovlen=%u"
+		", msg_controllen=0, msg_flags=0}, msg_len=%u}], %u"
+		", MSG_DONTROUTE|MSG_NOSIGNAL) = %d\n"
+		" = %u buffers in vector 0\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 1\n"
+		" | 00000 %-49s  %-16s |\n"
+		" = %u buffers in vector 1\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		w0_c, LENGTH_OF(w0_c),
+		w1_c, LENGTH_OF(w1_c),
+		ARRAY_SIZE(w0_iov_),
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c),
+		w2_c, LENGTH_OF(w2_c), ARRAY_SIZE(w1_iov_),
+		LENGTH_OF(w2_c),
+		n_w_mmh, r,
+		ARRAY_SIZE(w0_iov_), LENGTH_OF(w0_c), w0_d, w0_c,
+		LENGTH_OF(w1_c), w1_d, w1_c,
+		ARRAY_SIZE(w1_iov_), LENGTH_OF(w2_c), w2_d, w2_c);
+
+	const unsigned int w_len =
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c) + LENGTH_OF(w2_c);
+	const unsigned int r_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r_len);
+	void *r1 = tail_alloc(r_len);
+	void *r2 = tail_alloc(r_len);
+	const struct iovec r0_iov_[] = {
+		{
+			.iov_base = r0,
+			.iov_len = r_len
+		}
+	};
+	struct iovec *r0_iov = tail_memdup(r0_iov_, sizeof(r0_iov_));
+	const struct iovec r1_iov_[] = {
+		{
+			.iov_base = r1,
+			.iov_len = r_len
+		},
+		{
+			.iov_base = r2,
+			.iov_len = r_len
+		}
+	};
+	struct iovec *r1_iov = tail_memdup(r1_iov_, sizeof(r1_iov_));
+
+	const struct mmsghdr r_mmh_[] = {
+		{
+			.msg_hdr = {
+				.msg_iov = r0_iov,
+				.msg_iovlen = ARRAY_SIZE(r0_iov_),
+			}
+		}, {
+			.msg_hdr = {
+				.msg_iov = r1_iov,
+				.msg_iovlen = ARRAY_SIZE(r1_iov_),
+			}
+		}
+	};
+	void *r_mmh = tail_memdup(r_mmh_, sizeof(r_mmh_));
+	const unsigned int n_r_mmh = ARRAY_SIZE(r_mmh_);
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+
+	assert(recv_mmsg(0, r_mmh, n_r_mmh, MSG_DONTWAIT, NULL) == (int) n_r_mmh);
+	assert(close(0) == 0);
+	tprintf("recvmmsg(0, [{msg_hdr={msg_name=NULL, msg_namelen=0"
+		", msg_iov=[{iov_base=\"%s\", iov_len=%u}], msg_iovlen=%u"
+		", msg_controllen=0, msg_flags=0}, msg_len=%u}"
+		", {msg_hdr={msg_name=NULL, msg_namelen=0"
+		", msg_iov=[{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"\", iov_len=%u}], msg_iovlen=%u"
+		", msg_controllen=0, msg_flags=0}, msg_len=%u}], %u"
+		", MSG_DONTWAIT, NULL) = %d\n"
+		" = %u buffers in vector 0\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" = %u buffers in vector 1\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r_len, ARRAY_SIZE(r0_iov_), LENGTH_OF(r0_c),
+		r1_c, r_len, r_len, ARRAY_SIZE(r1_iov_), LENGTH_OF(r1_c),
+		n_r_mmh, r,
+		ARRAY_SIZE(r0_iov_), LENGTH_OF(r0_c), r0_d, r0_c,
+		ARRAY_SIZE(r1_iov_), LENGTH_OF(r1_c), r1_d, r1_c);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
diff --git a/strace/tests/mmsg.test b/strace/tests/mmsg.test
new file mode 100755
index 0000000..a8148ba
--- /dev/null
+++ b/strace/tests/mmsg.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check how iovecs in struct mmsghdr are decoded.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=recvmmsg,sendmmsg -e read=0 -e write=1
diff --git a/strace/tests/mmsg_name-v.c b/strace/tests/mmsg_name-v.c
new file mode 100644
index 0000000..60bd2bc
--- /dev/null
+++ b/strace/tests/mmsg_name-v.c
@@ -0,0 +1,4 @@
+/* This file is part of mmsg_name-v strace test. */
+#define VERBOSE_MMSGHDR
+#define TEST_NAME "mmsg_name-v"
+#include "mmsg_name.c"
diff --git a/strace/tests/mmsg_name-v.test b/strace/tests/mmsg_name-v.test
new file mode 100755
index 0000000..ab8dfba
--- /dev/null
+++ b/strace/tests/mmsg_name-v.test
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+# Check verbose decoding of msg_name* fields of struct msghdr array argument
+# of sendmmsg and recvmmsg syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -a25 -e trace=sendmmsg,recvmmsg
diff --git a/strace/tests/mmsg_name.c b/strace/tests/mmsg_name.c
new file mode 100644
index 0000000..f2b624a
--- /dev/null
+++ b/strace/tests/mmsg_name.c
@@ -0,0 +1,242 @@
+/*
+ * Check decoding of msg_name* fields of struct msghdr array argument
+ * of sendmmsg and recvmmsg syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <errno.h>
+#include <limits.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/un.h>
+
+#include "msghdr.h"
+
+#define DEFAULT_STRLEN 32
+
+#define IOV_MAX1 (IOV_MAX + 1)
+
+#ifndef TEST_NAME
+# define TEST_NAME "mmsg_name"
+#endif
+
+static void
+print_msghdr(const struct msghdr *const msg, const int user_msg_namelen)
+{
+	const struct sockaddr_un *const un = msg->msg_name;
+	const int offsetof_sun_path = offsetof(struct sockaddr_un, sun_path);
+
+	printf("{msg_name=");
+	if (!un)
+		printf("NULL");
+	else if (user_msg_namelen < offsetof_sun_path) {
+		printf("%p", un);
+	} else {
+		printf("{sa_family=AF_UNIX");
+		if (user_msg_namelen > offsetof_sun_path) {
+			int len = user_msg_namelen < (int) msg->msg_namelen ?
+				  user_msg_namelen : (int) msg->msg_namelen;
+			len -= offsetof_sun_path;
+			if (len > (int) sizeof(un->sun_path))
+				len = sizeof(un->sun_path);
+			printf(", sun_path=\"%.*s\"", len, un->sun_path);
+		}
+		printf("}");
+	}
+	printf(", msg_namelen=");
+	if (user_msg_namelen != (int) msg->msg_namelen) {
+		printf("%d->", user_msg_namelen);
+	}
+	printf("%d, msg_iov=[{iov_base=\"%c\", iov_len=1}]"
+	       ", msg_iovlen=1, msg_controllen=0, msg_flags=0}",
+	       (int) msg->msg_namelen, * (char *) msg->msg_iov[0].iov_base);
+}
+
+static void
+test_mmsg_name(const int send_fd, const int recv_fd)
+{
+	struct sockaddr_un *const send_addr =
+		tail_alloc(sizeof(*send_addr) * IOV_MAX1);
+	char *const send_buf = tail_alloc(sizeof(*send_buf) * IOV_MAX1);
+	struct iovec *const send_iov = tail_alloc(sizeof(*send_iov) * IOV_MAX1);
+	struct mmsghdr *const send_mh = tail_alloc(sizeof(*send_mh) * IOV_MAX1);
+
+	int i, rc;
+
+	for (i = 0; i < IOV_MAX1; ++i) {
+		int sun_len = i + 1 > (int) sizeof(send_addr[i].sun_path)
+				    ? (int) sizeof(send_addr[i].sun_path)
+				    : i + 1;
+
+		send_addr[i].sun_family = AF_UNIX;
+		memset(send_addr[i].sun_path, 'a' + i % 26, sun_len);
+
+		send_buf[i] = '0' + i % 10;
+
+		send_iov[i].iov_base = &send_buf[i];
+		send_iov[i].iov_len = sizeof(*send_buf);
+
+		send_mh[i].msg_hdr.msg_iov = &send_iov[i];
+		send_mh[i].msg_hdr.msg_iovlen = 1;
+		send_mh[i].msg_hdr.msg_name = &send_addr[i];
+		send_mh[i].msg_hdr.msg_namelen = i + 1;
+		send_mh[i].msg_hdr.msg_control = 0;
+		send_mh[i].msg_hdr.msg_controllen = 0;
+		send_mh[i].msg_hdr.msg_flags = 0;
+	}
+
+	rc = send_mmsg(send_fd, send_mh, IOV_MAX1, MSG_DONTWAIT);
+	int saved_errno = errno;
+
+	printf("sendmmsg(%d, [", send_fd);
+	for (i = 0; i < IOV_MAX1; ++i) {
+		if (i)
+			printf(", ");
+		if (i >= IOV_MAX
+# ifndef VERBOSE_MMSGHDR
+			|| i >= DEFAULT_STRLEN
+# endif
+		   ) {
+			printf("...");
+			break;
+		}
+		printf("{msg_hdr=");
+		print_msghdr(&send_mh[i].msg_hdr, i + 1);
+		printf("}");
+	}
+	errno = saved_errno;
+	printf("], %u, MSG_DONTWAIT) = %d %s (%m)\n",
+	       IOV_MAX1, rc, errno2name());
+
+	for (i = 0; i < IOV_MAX1; ++i) {
+		send_mh[i].msg_hdr.msg_name = 0;
+		send_mh[i].msg_hdr.msg_namelen = 0;
+	}
+
+	/*
+	 * When recvmmsg is called with a valid descriptor
+	 * but inaccessible memory, it causes segfaults on some architectures.
+	 * As in these cases we test decoding of failed recvmmsg calls,
+	 * it's ok to fail recvmmsg with any reason as long as
+	 * it doesn't read that inaccessible memory.
+	 */
+	rc = send_mmsg(-1, &send_mh[IOV_MAX], 2, MSG_DONTWAIT);
+	saved_errno = errno;
+	printf("sendmmsg(-1, [{msg_hdr=");
+	print_msghdr(&send_mh[IOV_MAX].msg_hdr, 0);
+	errno = saved_errno;
+	printf("}, %p], %u, MSG_DONTWAIT) = %d %s (%m)\n",
+	       &send_mh[IOV_MAX1], 2, rc, errno2name());
+
+	rc = send_mmsg(send_fd, send_mh, IOV_MAX1, MSG_DONTWAIT);
+	if (rc < 0)
+		perror_msg_and_skip("sendmmsg");
+
+	printf("sendmmsg(%d, [", send_fd);
+	for (i = 0; i < IOV_MAX1; ++i) {
+		if (i)
+			printf(", ");
+		if (i >= IOV_MAX
+#ifndef VERBOSE_MMSGHDR
+			|| i >= DEFAULT_STRLEN
+#endif
+		   ) {
+			printf("...");
+			break;
+		}
+		printf("{msg_hdr=");
+		print_msghdr(&send_mh[i].msg_hdr, 0);
+		printf("%s}", i < rc ? ", msg_len=1" : "");
+	}
+	printf("], %u, MSG_DONTWAIT) = %d\n", IOV_MAX1, rc);
+
+	struct sockaddr_un *const recv_addr =
+		tail_alloc(sizeof(*recv_addr) * IOV_MAX1);
+	char *const recv_buf = tail_alloc(sizeof(*recv_buf) * IOV_MAX1);
+	struct iovec *const recv_iov = tail_alloc(sizeof(*recv_iov) * IOV_MAX1);
+	struct mmsghdr *const recv_mh = tail_alloc(sizeof(*recv_mh) * IOV_MAX1);
+
+	for (i = 0; i < IOV_MAX1; ++i) {
+		recv_iov[i].iov_base = &recv_buf[i];
+		recv_iov[i].iov_len = sizeof(*recv_buf);
+
+		recv_mh[i].msg_hdr.msg_name = &recv_addr[i];
+		recv_mh[i].msg_hdr.msg_namelen = i;
+		recv_mh[i].msg_hdr.msg_iov = &recv_iov[i];
+		recv_mh[i].msg_hdr.msg_iovlen = 1;
+		recv_mh[i].msg_hdr.msg_control = 0;
+		recv_mh[i].msg_hdr.msg_controllen = 0;
+		recv_mh[i].msg_hdr.msg_flags = 0;
+	}
+
+	rc = recv_mmsg(recv_fd, recv_mh, IOV_MAX1, MSG_DONTWAIT, 0);
+	if (rc < 0)
+		perror_msg_and_skip("recvmmsg");
+
+	printf("recvmmsg(%d, [", recv_fd);
+	for (i = 0; i < rc; ++i) {
+		if (i)
+			printf(", ");
+#ifndef VERBOSE_MMSGHDR
+		if (i >= DEFAULT_STRLEN) {
+			printf("...");
+			break;
+		}
+#endif
+		printf("{msg_hdr=");
+		print_msghdr(&recv_mh[i].msg_hdr, i);
+		printf(", msg_len=1}");
+	}
+	printf("], %u, MSG_DONTWAIT, NULL) = %d\n", IOV_MAX1, rc);
+}
+
+int
+main(void)
+{
+	int fds[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds))
+		perror_msg_and_skip("socketpair");
+
+	const struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = TEST_NAME "-recvmmsg.test.send.socket"
+	};
+
+	(void) unlink(un.sun_path);
+	if (bind(fds[1], (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+	(void) unlink(un.sun_path);
+
+	test_mmsg_name(fds[1], fds[0]);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/mmsg_name.test b/strace/tests/mmsg_name.test
new file mode 100755
index 0000000..e18c972
--- /dev/null
+++ b/strace/tests/mmsg_name.test
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+# Check decoding of msg_name* fields of struct msghdr array argument
+# of sendmmsg and recvmmsg syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a25 -e trace=sendmmsg,recvmmsg
diff --git a/strace/tests/mount.c b/strace/tests/mount.c
new file mode 100644
index 0000000..cbfe42f
--- /dev/null
+++ b/strace/tests/mount.c
@@ -0,0 +1,84 @@
+/*
+ * Check decoding of mount syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/mount.h>
+
+#ifndef MS_MGC_VAL
+# define MS_MGC_VAL 0xC0ED0000
+#endif
+
+#ifndef MS_RELATIME
+# define MS_RELATIME (1ul << 21)
+#endif
+
+#define str_ro_nosuid_nodev_noexec "MS_RDONLY|MS_NOSUID|MS_NODEV|MS_NOEXEC"
+
+int
+main(void)
+{
+	static const char source[] = "mount_source";
+	static const char target[] = "mount_target";
+	static const char fstype[] = "mount_fstype";
+	static const char data[] = "mount_data";
+
+	int rc = mount(source, target, fstype, 15, data);
+	printf("mount(\"%s\", \"%s\", \"%s\", %s, \"%s\") = %d %s (%m)\n",
+	       source, target, fstype, str_ro_nosuid_nodev_noexec,
+	       data, rc, errno2name());
+
+	rc = mount(source, target, fstype, MS_RELATIME | 15, data);
+	printf("mount(\"%s\", \"%s\", \"%s\", %s, \"%s\") = %d %s (%m)\n",
+	       source, target, fstype,
+	       str_ro_nosuid_nodev_noexec "|MS_RELATIME",
+	       data, rc, errno2name());
+
+	rc = mount(source, target, fstype, MS_MGC_VAL, data);
+	printf("mount(\"%s\", \"%s\", \"%s\", %s, \"%s\") = %d %s (%m)\n",
+	       source, target, fstype, "MS_MGC_VAL", data, rc, errno2name());
+
+	rc = mount(source, target, fstype, MS_MGC_VAL | 15, data);
+	printf("mount(\"%s\", \"%s\", \"%s\", %s, \"%s\") = %d %s (%m)\n",
+	       source, target, fstype,
+	       "MS_MGC_VAL|" str_ro_nosuid_nodev_noexec,
+	       data, rc, errno2name());
+
+	rc = mount(source, target, fstype, MS_REMOUNT, data);
+	printf("mount(\"%s\", \"%s\", %p, %s, \"%s\") = %d %s (%m)\n",
+	       source, target, fstype, "MS_REMOUNT", data, rc, errno2name());
+
+	rc = mount(source, target, fstype, MS_BIND, data);
+	printf("mount(\"%s\", \"%s\", %p, %s, %p) = %d %s (%m)\n",
+	       source, target, fstype, "MS_BIND", data, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/mount.test b/strace/tests/mount.test
new file mode 100755
index 0000000..40fdca9
--- /dev/null
+++ b/strace/tests/mount.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of mount syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/move_pages.c b/strace/tests/move_pages.c
new file mode 100644
index 0000000..1059366
--- /dev/null
+++ b/strace/tests/move_pages.c
@@ -0,0 +1,251 @@
+/*
+ * Check decoding of move_pages syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_move_pages
+
+# include <errno.h>
+# include <stdio.h>
+# include <unistd.h>
+
+# define MAX_STRLEN 3
+
+static void
+print_page_array(const void **const pages,
+		 const unsigned long count,
+		 const unsigned int offset)
+{
+	if (!count) {
+		printf("%s", pages ? "[]" : "NULL");
+		return;
+	}
+	if (count <= offset) {
+		printf("%p", pages);
+		return;
+	}
+	printf("[");
+	unsigned long i;
+	for (i = 0; i < count; ++i) {
+		if (i)
+			printf(", ");
+		if (i + offset < count) {
+			if (i >= MAX_STRLEN) {
+				printf("...");
+				break;
+			}
+		} else {
+			printf("%p", pages + i);
+			break;
+		}
+		const void *const addr = pages[i];
+		if (addr)
+			printf("%p", addr);
+		else
+			printf("NULL");
+	}
+	printf("]");
+}
+
+static void
+print_node_array(const int *const nodes,
+		 const unsigned long count,
+		 const unsigned int offset)
+{
+	if (!count) {
+		printf("%s", nodes ? "[]" : "NULL");
+		return;
+	}
+	if (count <= offset) {
+		printf("%p", nodes);
+		return;
+	}
+	printf("[");
+	unsigned long i;
+	for (i = 0; i < count; ++i) {
+		if (i)
+			printf(", ");
+		if (i + offset < count) {
+			if (i >= MAX_STRLEN) {
+				printf("...");
+				break;
+			}
+		} else {
+			printf("%p", nodes + i);
+			break;
+		}
+		printf("%d", nodes[i]);
+	}
+	printf("]");
+}
+
+static void
+print_status_array(const int *const status, const unsigned long count)
+{
+	if (!count) {
+		printf("%s", status ? "[]" : "NULL");
+		return;
+	}
+	printf("[");
+	unsigned long i;
+	for (i = 0; i < count; ++i) {
+		if (i)
+			printf(", ");
+		if (i >= MAX_STRLEN) {
+			printf("...");
+			break;
+		}
+		if (status[i] >= 0) {
+			printf("%d", status[i]);
+		} else {
+			errno = -status[i];
+			printf("%s", errno2name());
+		}
+	}
+	printf("]");
+}
+
+static void
+print_stat_pages(const unsigned long pid, const unsigned long count,
+		 const void **const pages, int *const status)
+{
+	const unsigned long flags = (unsigned long) 0xfacefeed00000002;
+
+	long rc = syscall(__NR_move_pages,
+			  pid, count, pages, NULL, status, flags);
+	if (rc) {
+		int saved_errno = errno;
+		printf("move_pages(%d, %lu, ", (int) pid, count);
+		print_page_array(pages, count, 0);
+		printf(", NULL, ");
+		if (count)
+			printf("%p", status);
+		else
+			printf("[]");
+		errno = saved_errno;
+		printf(", MPOL_MF_MOVE) = %ld %s (%m)\n",
+		       rc, errno2name());
+	} else {
+		printf("move_pages(%d, %lu, ", (int) pid, count);
+		print_page_array(pages, count, 0);
+		printf(", NULL, ");
+		print_status_array(status, count);
+		printf(", MPOL_MF_MOVE) = 0\n");
+	}
+}
+
+static void
+print_move_pages(const unsigned long pid,
+		 unsigned long count,
+		 const unsigned int offset,
+		 const void **const pages,
+		 int *const nodes,
+		 int *const status)
+{
+	const unsigned long flags = (unsigned long) 0xfacefeed00000004;
+	count += offset;
+
+	long rc = syscall(__NR_move_pages,
+			  pid, count, pages, nodes, status, flags);
+	int saved_errno = errno;
+	printf("move_pages(%d, %lu, ", (int) pid, count);
+	print_page_array(pages, count, offset);
+	printf(", ");
+	print_node_array(nodes, count, offset);
+	printf(", ");
+	if (count)
+		printf("%p", status);
+	else
+		printf("[]");
+	printf(", MPOL_MF_MOVE_ALL) = ");
+	if (rc) {
+		errno = saved_errno;
+		printf("%ld %s (%m)\n", rc, errno2name());
+	} else {
+		puts("0");
+	}
+}
+
+int
+main(void)
+{
+	const unsigned long pid =
+		(unsigned long) 0xfacefeed00000000 | getpid();
+	unsigned long count = 1;
+	const unsigned page_size = get_page_size();
+	const void *const page = tail_alloc(page_size);
+	const void *const efault = page + page_size;
+	const void **pages = tail_alloc(sizeof(*pages));
+	int *nodes = tail_alloc(sizeof(*nodes));
+	int *status = tail_alloc(sizeof(*status));
+
+	print_stat_pages(pid, 0, pages, status);
+	print_move_pages(pid, 0, 0, pages, nodes, status);
+	print_move_pages(pid, 0, 1, pages + 1, nodes + 1, status + 1);
+
+	*pages = page;
+	print_stat_pages(pid, count, pages, status);
+	*nodes = 0xdeadbee1;
+	print_move_pages(pid, count, 0, pages, nodes, status);
+	print_move_pages(pid, count, 1, pages, nodes, status);
+
+	++count;
+	--status;
+	*(--pages) = efault;
+	print_stat_pages(pid, count, pages, status);
+	*(--nodes) = 0xdeadbee2;
+	print_move_pages(pid, count, 0, pages, nodes, status);
+	print_move_pages(pid, count, 1, pages, nodes, status);
+
+	++count;
+	--status;
+	*(--pages) = nodes;
+	print_stat_pages(pid, count, pages, status);
+	*(--nodes) = 0xdeadbee3;
+	print_move_pages(pid, count, 0, pages, nodes, status);
+	print_move_pages(pid, count, 1, pages, nodes, status);
+
+	++count;
+	--status;
+	*(--pages) = status;
+	print_stat_pages(pid, count, pages, status);
+	*(--nodes) = 0xdeadbee4;
+	print_move_pages(pid, count, 0, pages, nodes, status);
+	print_move_pages(pid, count, 1, pages, nodes, status);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_move_pages")
+
+#endif
diff --git a/strace/tests/move_pages.test b/strace/tests/move_pages.test
new file mode 100755
index 0000000..f957717
--- /dev/null
+++ b/strace/tests/move_pages.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of move_pages syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -s3
diff --git a/strace/tests/mq.c b/strace/tests/mq.c
new file mode 100644
index 0000000..d80f927
--- /dev/null
+++ b/strace/tests/mq.c
@@ -0,0 +1,59 @@
+/*
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#ifdef HAVE_MQUEUE_H
+
+# include <fcntl.h>
+# include <mqueue.h>
+# include <stdlib.h>
+# include <unistd.h>
+# include <sys/stat.h>
+
+int
+main (void)
+{
+	struct mq_attr attr;
+	(void) close(0);
+	if (mq_open("/strace-mq.test", O_CREAT, S_IRWXU, 0))
+		perror_msg_and_skip("mq_open");
+	if (mq_getattr(0, &attr))
+		perror_msg_and_skip("mq_getattr");
+	if (mq_setattr(0, &attr, 0))
+		perror_msg_and_skip("mq_setattr");
+	if (mq_unlink("/strace-mq.test"))
+		perror_msg_and_skip("mq_unlink");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_MQUEUE_H")
+
+#endif
diff --git a/strace/tests/mq.expected b/strace/tests/mq.expected
new file mode 100644
index 0000000..40b8eee
--- /dev/null
+++ b/strace/tests/mq.expected
@@ -0,0 +1,4 @@
+mq_open\("strace-mq.test", O_RDONLY\|O_CREAT, 0700, NULL\) += 0
+mq_getsetattr\(0, NULL, \{mq_flags=O_RDONLY, mq_maxmsg=[1-9][0-9]*, mq_msgsize=[1-9][0-9]*, mq_curmsg=0\}\) += 0
+mq_getsetattr\(0, \{mq_flags=O_RDONLY, mq_maxmsg=[1-9][0-9]*, mq_msgsize=[1-9][0-9]*, mq_curmsg=0\}, NULL\) += 0
+mq_unlink\("strace-mq.test"\) += 0
diff --git a/strace/tests/mq.test b/strace/tests/mq.test
new file mode 100755
index 0000000..e900591
--- /dev/null
+++ b/strace/tests/mq.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check mq_open, mq_getsetattr, mq_unlink syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -v -e mq_getsetattr,mq_open,mq_unlink $args
+match_grep
+
+exit 0
diff --git a/strace/tests/msg_control-v.c b/strace/tests/msg_control-v.c
new file mode 100644
index 0000000..d2a5653
--- /dev/null
+++ b/strace/tests/msg_control-v.c
@@ -0,0 +1,3 @@
+/* This file is part of msg_control-v strace test. */
+#define VERBOSE_MSGHDR
+#include "msg_control.c"
diff --git a/strace/tests/msg_control-v.test b/strace/tests/msg_control-v.test
new file mode 100755
index 0000000..41f9842
--- /dev/null
+++ b/strace/tests/msg_control-v.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check verbose decoding of struct msghdr ancillary data.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -a21 -e trace=sendmsg
diff --git a/strace/tests/msg_control.c b/strace/tests/msg_control.c
new file mode 100644
index 0000000..4f23b2a
--- /dev/null
+++ b/strace/tests/msg_control.c
@@ -0,0 +1,717 @@
+/*
+ * Check decoding of struct msghdr ancillary data.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <limits.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <net/if.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
+#ifndef SOL_IP
+# define SOL_IP 0
+#endif
+#ifndef SOL_TCP
+# define SOL_TCP 6
+#endif
+
+#ifndef SCM_SECURITY
+# define SCM_SECURITY 3
+#endif
+
+#define MIN_SIZE_OF(type, member) \
+	(offsetof(type, member) + sizeof(((type *) 0)->member))
+
+#define VAL_STR(val) val, #val
+
+static struct cmsghdr *
+get_cmsghdr(void *const page, const size_t len)
+{
+	return page - CMSG_ALIGN(len);
+}
+
+#define DEFAULT_STRLEN 32
+
+static void
+print_fds(const struct cmsghdr *const cmsg, const size_t cmsg_len)
+{
+	size_t nfd = cmsg_len > CMSG_LEN(0)
+		     ? (cmsg_len - CMSG_LEN(0)) / sizeof(int) : 0;
+	if (!nfd)
+		return;
+
+	printf(", cmsg_data=[");
+	int *fdp = (int *) CMSG_DATA(cmsg);
+	size_t i;
+	for (i = 0; i < nfd; ++i) {
+		if (i)
+			printf(", ");
+#ifndef VERBOSE_MSGHDR
+		if (i >= DEFAULT_STRLEN) {
+			printf("...");
+			break;
+		}
+#endif
+		printf("%d", fdp[i]);
+	}
+	printf("]");
+}
+
+static void
+test_scm_rights1(struct msghdr *const mh,
+		 const size_t msg_controllen,
+		 void *const page,
+		 const void *const src,
+		 const size_t cmsg_len)
+{
+	const size_t aligned_cms_len =
+		cmsg_len > CMSG_LEN(0) ? CMSG_ALIGN(cmsg_len) : CMSG_LEN(0);
+	if (cmsg_len >= CMSG_LEN(0)
+	    && aligned_cms_len + CMSG_LEN(0) <= msg_controllen)
+		return;
+
+	struct cmsghdr *cmsg = get_cmsghdr(page, msg_controllen);
+
+	if (msg_controllen >= MIN_SIZE_OF(struct cmsghdr, cmsg_len))
+		cmsg->cmsg_len = cmsg_len;
+	if (msg_controllen >= MIN_SIZE_OF(struct cmsghdr, cmsg_level))
+		cmsg->cmsg_level = SOL_SOCKET;
+	if (msg_controllen >= MIN_SIZE_OF(struct cmsghdr, cmsg_type))
+		cmsg->cmsg_type = SCM_RIGHTS;
+
+	size_t src_len =
+		cmsg_len < msg_controllen ? cmsg_len : msg_controllen;
+	if (src_len > CMSG_LEN(0))
+		memcpy(CMSG_DATA(cmsg), src, src_len - CMSG_LEN(0));
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = msg_controllen;
+
+	int rc = sendmsg(-1, mh, 0);
+	int saved_errno = errno;
+
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0");
+	if (msg_controllen < CMSG_LEN(0)) {
+		if (msg_controllen)
+			printf(", msg_control=%p", cmsg);
+	} else {
+		printf(", msg_control=[{cmsg_len=%lu, cmsg_level=SOL_SOCKET"
+		       ", cmsg_type=SCM_RIGHTS", (unsigned long) cmsg_len);
+		print_fds(cmsg, src_len);
+		printf("}");
+		if (aligned_cms_len < msg_controllen)
+			printf(", %p", (void *) cmsg + aligned_cms_len);
+		printf("]");
+	}
+
+	errno = saved_errno;
+	printf(", msg_controllen=%lu, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned long) msg_controllen, rc, errno2name());
+}
+
+static void
+test_scm_rights2(struct msghdr *const mh,
+		 const size_t msg_controllen,
+		 void *const page,
+		 const int *const *const src,
+		 const size_t *const cmsg_len)
+{
+	const size_t aligned_cms_len[2] = {
+		cmsg_len[0] > CMSG_LEN(0) ? CMSG_ALIGN(cmsg_len[0]) : CMSG_LEN(0),
+		cmsg_len[1] > CMSG_LEN(0) ? CMSG_ALIGN(cmsg_len[1]) : CMSG_LEN(0)
+	};
+	if (cmsg_len[0] < CMSG_LEN(0)
+	    || aligned_cms_len[0] + CMSG_LEN(0) > msg_controllen
+	    || aligned_cms_len[0] + aligned_cms_len[1] + CMSG_LEN(0) <= msg_controllen)
+		return;
+
+	struct cmsghdr *const cmsg[2] = {
+		get_cmsghdr(page, msg_controllen),
+		(void *) get_cmsghdr(page, msg_controllen) + aligned_cms_len[0]
+	};
+	cmsg[0]->cmsg_len = cmsg_len[0];
+	cmsg[0]->cmsg_level = SOL_SOCKET;
+	cmsg[0]->cmsg_type = SCM_RIGHTS;
+	if (cmsg_len[0] > CMSG_LEN(0))
+		memcpy(CMSG_DATA(cmsg[0]), src[0], cmsg_len[0] - CMSG_LEN(0));
+
+	const size_t msg_controllen1 = msg_controllen - aligned_cms_len[0];
+	if (msg_controllen1 >= MIN_SIZE_OF(struct cmsghdr, cmsg_len))
+		cmsg[1]->cmsg_len = cmsg_len[1];
+	if (msg_controllen >= MIN_SIZE_OF(struct cmsghdr, cmsg_level))
+		cmsg[1]->cmsg_level = SOL_SOCKET;
+	if (msg_controllen >= MIN_SIZE_OF(struct cmsghdr, cmsg_type))
+		cmsg[1]->cmsg_type = SCM_RIGHTS;
+	size_t src1_len =
+		cmsg_len[1] < msg_controllen1 ? cmsg_len[1] : msg_controllen1;
+	if (src1_len > CMSG_LEN(0))
+		memcpy(CMSG_DATA(cmsg[1]), src[1], src1_len - CMSG_LEN(0));
+
+	mh->msg_control = cmsg[0];
+	mh->msg_controllen = msg_controllen;
+
+	int rc = sendmsg(-1, mh, 0);
+	int saved_errno = errno;
+
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%lu"
+	       ", cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS",
+	       (unsigned long) cmsg_len[0]);
+	print_fds(cmsg[0], cmsg_len[0]);
+	printf("}, {cmsg_len=%lu, cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS",
+	       (unsigned long) cmsg_len[1]);
+	print_fds(cmsg[1], src1_len);
+	printf("}");
+	if (aligned_cms_len[1] < msg_controllen1)
+		printf(", %p", (void *) cmsg[1] + aligned_cms_len[1]);
+	printf("]");
+
+	errno = saved_errno;
+	printf(", msg_controllen=%lu, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned long) msg_controllen, rc, errno2name());
+}
+
+static void
+test_scm_rights3(struct msghdr *const mh, void *const page, const size_t nfds)
+{
+	const size_t len = CMSG_SPACE(sizeof(int) * nfds);
+	struct cmsghdr *cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(sizeof(int) * nfds);
+	cmsg->cmsg_level = SOL_SOCKET;
+	cmsg->cmsg_type = SCM_RIGHTS;
+	int *fdp = (int *) CMSG_DATA(cmsg);
+	size_t i;
+	for (i = 0; i < nfds; ++i)
+		fdp[i] = i;
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u"
+	       ", cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS",
+	       (unsigned) cmsg->cmsg_len);
+	print_fds(cmsg, cmsg->cmsg_len);
+	printf("}], msg_controllen=%lu, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned long) len, rc, errno2name());
+}
+
+static void
+print_security(const struct cmsghdr *const cmsg, const size_t cmsg_len)
+{
+	int n = cmsg_len > CMSG_LEN(0) ? cmsg_len - CMSG_LEN(0) : 0;
+	if (!n)
+		return;
+
+	printf(", cmsg_data=\"%.*s\"", n, CMSG_DATA(cmsg));
+}
+
+static void
+test_scm_security(struct msghdr *const mh,
+		  const size_t msg_controllen,
+		  void *const page,
+		  const void *const src,
+		  const size_t cmsg_len,
+		  const int cmsg_level,
+		  const char *const cmsg_level_str)
+{
+	const size_t aligned_cms_len =
+		cmsg_len > CMSG_LEN(0) ? CMSG_ALIGN(cmsg_len) : CMSG_LEN(0);
+	if (cmsg_len >= CMSG_LEN(0)
+	    && aligned_cms_len + CMSG_LEN(0) <= msg_controllen)
+		return;
+
+	struct cmsghdr *cmsg = get_cmsghdr(page, msg_controllen);
+
+	cmsg->cmsg_len = cmsg_len;
+	cmsg->cmsg_level = cmsg_level;
+	cmsg->cmsg_type = SCM_SECURITY;
+
+	size_t src_len =
+		cmsg_len < msg_controllen ? cmsg_len : msg_controllen;
+	if (src_len > CMSG_LEN(0))
+		memcpy(CMSG_DATA(cmsg), src, src_len - CMSG_LEN(0));
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = msg_controllen;
+
+	int rc = sendmsg(-1, mh, 0);
+	int saved_errno = errno;
+
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%lu, cmsg_level=%s"
+	       ", cmsg_type=SCM_SECURITY",
+	       (unsigned long) cmsg_len, cmsg_level_str);
+	print_security(cmsg, src_len);
+	printf("}");
+	if (aligned_cms_len < msg_controllen)
+		printf(", %p", (void *) cmsg + aligned_cms_len);
+	printf("]");
+
+	errno = saved_errno;
+	printf(", msg_controllen=%lu, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned long) msg_controllen, rc, errno2name());
+}
+
+static void
+test_unknown_type(struct msghdr *const mh,
+		  void *const page,
+		  const int cmsg_level,
+		  const char *const cmsg_level_str,
+		  const char *const cmsg_type_str)
+{
+	struct cmsghdr *cmsg = get_cmsghdr(page, CMSG_LEN(0));
+
+	cmsg->cmsg_len = CMSG_LEN(0);
+	cmsg->cmsg_level = cmsg_level;
+	cmsg->cmsg_type = 0xfacefeed;
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = cmsg->cmsg_len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u, cmsg_level=%s"
+	       ", cmsg_type=%#x /* %s */}], msg_controllen=%u, msg_flags=0}"
+	       ", 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, cmsg_level_str, cmsg->cmsg_type,
+	       cmsg_type_str, (unsigned) mh->msg_controllen, rc, errno2name());
+}
+
+static void
+test_sol_socket(struct msghdr *const mh, void *const page)
+{
+	static const int fds0[] = { -10, -11, -12, -13 };
+	static const int fds1[] = { -15, -16, -17, -18 };
+	size_t msg_controllen, max_msg_controllen;
+
+	max_msg_controllen = CMSG_SPACE(sizeof(fds0)) + sizeof(*fds0) - 1;
+	for (msg_controllen = 0;
+	     msg_controllen <= max_msg_controllen;
+	     msg_controllen++) {
+		size_t cmsg_len;
+
+		for (cmsg_len = 0;
+		     cmsg_len <= msg_controllen + CMSG_LEN(0);
+		     cmsg_len++) {
+			test_scm_rights1(mh, msg_controllen,
+					 page, fds0, cmsg_len);
+		}
+	}
+
+	max_msg_controllen =
+		CMSG_SPACE(sizeof(fds0)) + CMSG_SPACE(sizeof(fds1)) +
+		sizeof(*fds0) - 1;
+	for (msg_controllen = CMSG_LEN(0) * 2;
+	     msg_controllen <= max_msg_controllen;
+	     msg_controllen++) {
+		static const int *const fdps[] = { fds0, fds1 };
+		size_t cmsg_len[2];
+
+		for (cmsg_len[0] = CMSG_LEN(0);
+		     CMSG_ALIGN(cmsg_len[0]) + CMSG_LEN(0) <= msg_controllen
+		     && CMSG_ALIGN(cmsg_len[0]) <= CMSG_SPACE(sizeof(fds0));
+		     cmsg_len[0]++) {
+			const size_t msg_controllen1 =
+				msg_controllen - CMSG_ALIGN(cmsg_len[0]);
+
+			for (cmsg_len[1] = 0;
+			     cmsg_len[1] <= msg_controllen1 + CMSG_LEN(0);
+			     cmsg_len[1]++) {
+				test_scm_rights2(mh, msg_controllen,
+						 page, fdps, cmsg_len);
+			}
+		}
+	}
+
+	static const char text[16] = "0123456789abcdef";
+	max_msg_controllen = CMSG_SPACE(sizeof(text)) + CMSG_LEN(0) - 1;
+	for (msg_controllen = CMSG_LEN(0);
+	     msg_controllen <= max_msg_controllen;
+	     msg_controllen++) {
+		size_t cmsg_len;
+
+		for (cmsg_len = 0;
+		     cmsg_len <= msg_controllen + CMSG_LEN(0)
+		     && cmsg_len <= CMSG_LEN(sizeof(text));
+		     cmsg_len++) {
+			test_scm_security(mh, msg_controllen,
+					  page, text, cmsg_len,
+					  VAL_STR(SOL_SOCKET));
+		}
+	}
+
+	test_scm_rights3(mh, page, DEFAULT_STRLEN - 1);
+	test_scm_rights3(mh, page, DEFAULT_STRLEN);
+	test_scm_rights3(mh, page, DEFAULT_STRLEN + 1);
+
+	test_unknown_type(mh, page, VAL_STR(SOL_SOCKET), "SCM_???");
+}
+
+static void
+test_ip_pktinfo(struct msghdr *const mh, void *const page,
+	        const int cmsg_type, const char *const cmsg_type_str)
+{
+	const unsigned int len = CMSG_SPACE(sizeof(struct in_pktinfo));
+	struct cmsghdr *const cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(sizeof(struct in_pktinfo));
+	cmsg->cmsg_level = SOL_IP;
+	cmsg->cmsg_type = cmsg_type;
+
+	struct in_pktinfo *const info = (struct in_pktinfo *) CMSG_DATA(cmsg);
+#ifdef HAVE_IF_INDEXTONAME
+	info->ipi_ifindex = if_nametoindex("lo");
+#else
+	info->ipi_ifindex = 1;
+#endif
+	info->ipi_spec_dst.s_addr = inet_addr("1.2.3.4");
+	info->ipi_addr.s_addr = inet_addr("5.6.7.8");
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u, cmsg_level=SOL_IP"
+	       ", cmsg_type=%s, cmsg_data={ipi_ifindex=%s"
+	       ", ipi_spec_dst=inet_addr(\"%s\")"
+	       ", ipi_addr=inet_addr(\"%s\")}}]"
+	       ", msg_controllen=%u, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, cmsg_type_str,
+#ifdef HAVE_IF_INDEXTONAME
+	       "if_nametoindex(\"lo\")",
+#else
+	       "1",
+#endif
+	       "1.2.3.4", "5.6.7.8", len, rc, errno2name());
+}
+
+static void
+test_ip_uint(struct msghdr *const mh, void *const page,
+	     const int cmsg_type, const char *const cmsg_type_str)
+{
+	const unsigned int len = CMSG_SPACE(sizeof(int));
+	struct cmsghdr *const cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(sizeof(int));
+	cmsg->cmsg_level = SOL_IP;
+	cmsg->cmsg_type = cmsg_type;
+
+	unsigned int *u = (void *) CMSG_DATA(cmsg);
+	*u = 0xfacefeed;
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u"
+	       ", cmsg_level=SOL_IP, cmsg_type=%s, cmsg_data=[%u]}]"
+	       ", msg_controllen=%u, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, cmsg_type_str, *u, len,
+	       rc, errno2name());
+}
+
+static void
+test_ip_uint8_t(struct msghdr *const mh, void *const page,
+	        const int cmsg_type, const char *const cmsg_type_str)
+{
+	const unsigned int len = CMSG_SPACE(1);
+	struct cmsghdr *const cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(1);
+	cmsg->cmsg_level = SOL_IP;
+	cmsg->cmsg_type = cmsg_type;
+	*CMSG_DATA(cmsg) = 'A';
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u"
+	       ", cmsg_level=SOL_IP, cmsg_type=%s, cmsg_data=[%#x]}]"
+	       ", msg_controllen=%u, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, cmsg_type_str,
+	       (unsigned) (uint8_t) 'A', len, rc, errno2name());
+}
+
+static void
+print_ip_opts(const void *const cmsg_data, const unsigned int data_len)
+{
+	const unsigned char *const opts = cmsg_data;
+	unsigned int i;
+	for (i = 0; i < data_len; ++i) {
+		if (i)
+			printf(", ");
+#ifndef VERBOSE_MSGHDR
+		if (i >= DEFAULT_STRLEN) {
+			printf("...");
+			break;
+		}
+#endif
+		printf("0x%02x", opts[i]);
+	}
+}
+
+static void
+test_ip_opts(struct msghdr *const mh, void *const page,
+	     const int cmsg_type, const char *const cmsg_type_str,
+	     const unsigned int opts_len)
+{
+	unsigned int len = CMSG_SPACE(opts_len);
+	struct cmsghdr *cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(opts_len);
+	cmsg->cmsg_level = SOL_IP;
+	cmsg->cmsg_type = cmsg_type;
+	unsigned int i;
+	for (i = 0; i < opts_len; ++i)
+		CMSG_DATA(cmsg)[i] = 'A' + i;
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u"
+	       ", cmsg_level=SOL_IP, cmsg_type=%s, cmsg_data=[",
+	       (unsigned) cmsg->cmsg_len, cmsg_type_str);
+	print_ip_opts(CMSG_DATA(cmsg), opts_len);
+	printf("]}], msg_controllen=%u, msg_flags=0}, 0) = %d %s (%m)\n",
+	       len, rc, errno2name());
+}
+
+#ifdef IP_CHECKSUM
+struct sock_ee {
+	uint32_t ee_errno;
+	uint8_t  ee_origin;
+	uint8_t  ee_type;
+	uint8_t  ee_code;
+	uint8_t  ee_pad;
+	uint32_t ee_info;
+	uint32_t ee_data;
+	struct sockaddr_in offender;
+};
+
+static void
+test_ip_recverr(struct msghdr *const mh, void *const page,
+	        const int cmsg_type, const char *const cmsg_type_str)
+{
+	const unsigned int len = CMSG_SPACE(sizeof(struct sock_ee));
+	struct cmsghdr *const cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(sizeof(struct sock_ee));
+	cmsg->cmsg_level = SOL_IP;
+	cmsg->cmsg_type = cmsg_type;
+
+	struct sock_ee *const e = (struct sock_ee *) CMSG_DATA(cmsg);
+	e->ee_errno = 0xdeadbeef;
+	e->ee_origin = 2;
+	e->ee_type = 3;
+	e->ee_code = 4;
+	e->ee_info = 0xfacefeed;
+	e->ee_data = 0xbadc0ded;
+	e->offender.sin_family = AF_INET,
+	e->offender.sin_port = htons(12345),
+	e->offender.sin_addr.s_addr = htonl(INADDR_LOOPBACK);
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u, cmsg_level=SOL_IP"
+	       ", cmsg_type=%s, cmsg_data={ee_errno=%u, ee_origin=%u"
+	       ", ee_type=%u, ee_code=%u, ee_info=%u, ee_data=%u"
+	       ", offender={sa_family=AF_INET, sin_port=htons(%hu)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}}}]"
+	       ", msg_controllen=%u, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, cmsg_type_str,
+	       e->ee_errno, e->ee_origin, e->ee_type,
+	       e->ee_code, e->ee_info, e->ee_data,
+	       ntohs(e->offender.sin_port),
+	       len, rc, errno2name());
+}
+#endif
+
+#ifdef IP_ORIGDSTADDR
+static void
+test_ip_origdstaddr(struct msghdr *const mh, void *const page,
+		    const int cmsg_type, const char *const cmsg_type_str)
+{
+	const unsigned int len = CMSG_SPACE(sizeof(struct sockaddr_in));
+	struct cmsghdr *const cmsg = get_cmsghdr(page, len);
+
+	cmsg->cmsg_len = CMSG_LEN(sizeof(struct sockaddr_in));
+	cmsg->cmsg_level = SOL_IP;
+	cmsg->cmsg_type = cmsg_type;
+
+	struct sockaddr_in *const sin = (struct sockaddr_in *) CMSG_DATA(cmsg);
+	sin->sin_family = AF_INET,
+	sin->sin_port = htons(12345),
+	sin->sin_addr.s_addr = htonl(INADDR_LOOPBACK);
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u, cmsg_level=SOL_IP"
+	       ", cmsg_type=%s, cmsg_data={sa_family=AF_INET"
+	       ", sin_port=htons(%hu), sin_addr=inet_addr(\"127.0.0.1\")}}]"
+	       ", msg_controllen=%u, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, cmsg_type_str,
+	       ntohs(sin->sin_port), len, rc, errno2name());
+}
+#endif
+
+static void
+test_sol_ip(struct msghdr *const mh, void *const page)
+{
+	test_ip_pktinfo(mh, page, VAL_STR(IP_PKTINFO));
+	test_ip_uint(mh, page, VAL_STR(IP_TTL));
+	test_ip_uint8_t(mh, page, VAL_STR(IP_TOS));
+	test_ip_opts(mh, page, VAL_STR(IP_RECVOPTS), 1);
+	test_ip_opts(mh, page, VAL_STR(IP_RECVOPTS), 2);
+	test_ip_opts(mh, page, VAL_STR(IP_RECVOPTS), 3);
+	test_ip_opts(mh, page, VAL_STR(IP_RECVOPTS), 4);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), 5);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), 6);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), 7);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), 8);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), DEFAULT_STRLEN - 1);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), DEFAULT_STRLEN);
+	test_ip_opts(mh, page, VAL_STR(IP_RETOPTS), DEFAULT_STRLEN + 1);
+#ifdef IP_CHECKSUM
+	test_ip_recverr(mh, page, VAL_STR(IP_RECVERR));
+#endif
+#ifdef IP_ORIGDSTADDR
+	test_ip_origdstaddr(mh, page, VAL_STR(IP_ORIGDSTADDR));
+#endif
+#ifdef IP_CHECKSUM
+	test_ip_uint(mh, page, VAL_STR(IP_CHECKSUM));
+#endif
+	test_scm_security(mh, CMSG_LEN(0), page, 0, CMSG_LEN(0),
+			  VAL_STR(SOL_IP));
+	test_unknown_type(mh, page, VAL_STR(SOL_IP), "IP_???");
+}
+
+static void
+test_unknown_level(struct msghdr *const mh, void *const page)
+{
+	struct cmsghdr *cmsg = get_cmsghdr(page, CMSG_LEN(0));
+
+	cmsg->cmsg_len = CMSG_LEN(0);
+	cmsg->cmsg_level = SOL_TCP;
+	cmsg->cmsg_type = 0xdeadbeef;
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = cmsg->cmsg_len;
+
+	int rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u, cmsg_level=%s"
+	       ", cmsg_type=%#x}], msg_controllen=%u, msg_flags=0}"
+	       ", 0) = %d %s (%m)\n",
+	       (unsigned) cmsg->cmsg_len, "SOL_TCP", cmsg->cmsg_type,
+	       (unsigned) mh->msg_controllen, rc, errno2name());
+}
+
+static void
+test_big_len(struct msghdr *const mh)
+{
+	int optmem_max;
+
+	if (read_int_from_file("/proc/sys/net/core/optmem_max", &optmem_max)
+	    || optmem_max <= 0 || optmem_max > 0x100000)
+		optmem_max = sizeof(long long) * (2 * IOV_MAX + 512);
+	optmem_max = (optmem_max + sizeof(long long) - 1)
+		     & ~(sizeof(long long) - 1);
+
+	const size_t len = optmem_max * 2;
+	struct cmsghdr *const cmsg = tail_alloc(len);
+	cmsg->cmsg_len = len;
+	cmsg->cmsg_level = SOL_SOCKET;
+	cmsg->cmsg_type = SCM_RIGHTS;
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = len;
+
+	int rc = sendmsg(-1, mh, 0);
+	if (EBADF != errno)
+		perror_msg_and_skip("sendmsg");
+
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=[{cmsg_len=%u"
+	       ", cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS",
+	       (unsigned) cmsg->cmsg_len);
+	print_fds(cmsg, optmem_max);
+	printf("}, ...], msg_controllen=%lu, msg_flags=0}, 0) = %d %s (%m)\n",
+	       (unsigned long) len, rc, errno2name());
+}
+
+int main(int ac, const char **av)
+{
+	int rc = sendmsg(-1, 0, 0);
+	printf("sendmsg(-1, NULL, 0) = %d %s (%m)\n", rc, errno2name());
+
+	struct msghdr *mh = tail_alloc(sizeof(*mh));
+	memset(mh, 0, sizeof(*mh));
+	test_big_len(mh);
+
+	rc = sendmsg(-1, mh + 1, 0);
+	printf("sendmsg(-1, %p, 0) = %d %s (%m)\n",
+	       mh + 1, rc, errno2name());
+
+	void *page = tail_alloc(1) + 1;
+	mh->msg_control = page;
+	mh->msg_controllen = CMSG_LEN(0);
+	rc = sendmsg(-1, mh, 0);
+	printf("sendmsg(-1, {msg_name=NULL, msg_namelen=0, msg_iov=NULL"
+	       ", msg_iovlen=0, msg_control=%p, msg_controllen=%u"
+	       ", msg_flags=0}, 0) = %d %s (%m)\n",
+	       page, (unsigned) CMSG_LEN(0), rc, errno2name());
+
+	test_sol_socket(mh, page);
+	test_sol_ip(mh, page);
+	test_unknown_level(mh, page);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/msg_control.test b/strace/tests/msg_control.test
new file mode 100755
index 0000000..809ec7b
--- /dev/null
+++ b/strace/tests/msg_control.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of struct msghdr ancillary data.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21 -e trace=sendmsg
diff --git a/strace/tests/msg_name.c b/strace/tests/msg_name.c
new file mode 100644
index 0000000..c2ddda2
--- /dev/null
+++ b/strace/tests/msg_name.c
@@ -0,0 +1,160 @@
+/*
+ * Check decoding of struct msghdr.msg_name* arguments of recvmsg syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stddef.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+static int
+send_recv(const int send_fd, const int recv_fd,
+	 struct msghdr *const msg, const int flags)
+{
+	if (send(send_fd, "A", 1, 0) != 1)
+		perror_msg_and_skip("send");
+	return recvmsg(recv_fd, msg, flags);
+}
+
+static void
+test_msg_name(const int send_fd, const int recv_fd)
+{
+	char *const recv_buf = tail_alloc(sizeof(*recv_buf));
+	struct iovec *const iov = tail_alloc(sizeof(*iov));
+	iov->iov_base = recv_buf;
+	iov->iov_len = sizeof(*recv_buf);
+
+	struct sockaddr_un *const addr = tail_alloc(sizeof(*addr));
+	struct msghdr *const msg = tail_alloc(sizeof(*msg));
+	msg->msg_name = addr;
+	msg->msg_namelen = sizeof(*addr);
+	msg->msg_iov = iov;
+	msg->msg_iovlen = 1;
+	msg->msg_control = 0;
+	msg->msg_controllen = 0;
+	msg->msg_flags = 0;
+
+	int rc = send_recv(send_fd, recv_fd, msg, MSG_DONTWAIT);
+	if (rc < 0)
+		perror_msg_and_skip("recvmsg");
+	printf("recvmsg(%d, {msg_name={sa_family=AF_UNIX, sun_path=\"%s\"}"
+	       ", msg_namelen=%d->%d, msg_iov=[{iov_base=\"A\", iov_len=1}]"
+	       ", msg_iovlen=1, msg_controllen=0, msg_flags=0}, MSG_DONTWAIT)"
+	       " = %d\n",
+	       recv_fd, addr->sun_path, (int) sizeof(struct sockaddr_un),
+	       (int) msg->msg_namelen, rc);
+
+	memset(addr, 0, sizeof(*addr));
+	rc = send_recv(send_fd, recv_fd, msg, MSG_DONTWAIT);
+	printf("recvmsg(%d, {msg_name={sa_family=AF_UNIX, sun_path=\"%s\"}"
+	       ", msg_namelen=%d, msg_iov=[{iov_base=\"A\", iov_len=1}]"
+	       ", msg_iovlen=1, msg_controllen=0, msg_flags=0}, MSG_DONTWAIT)"
+	       " = %d\n",
+	       recv_fd, addr->sun_path, (int) msg->msg_namelen, rc);
+
+	msg->msg_name = 0;
+	rc = send_recv(send_fd, recv_fd, msg, MSG_DONTWAIT);
+	printf("recvmsg(%d, {msg_name=NULL, msg_namelen=%d"
+	       ", msg_iov=[{iov_base=\"A\", iov_len=1}], msg_iovlen=1"
+	       ", msg_controllen=0, msg_flags=0}, MSG_DONTWAIT) = %d\n",
+	       recv_fd, (int) msg->msg_namelen, rc);
+
+	const size_t offsetof_sun_path = offsetof(struct sockaddr_un, sun_path);
+	msg->msg_name = addr;
+	msg->msg_namelen = offsetof_sun_path;
+	memset(addr->sun_path, 'A', sizeof(addr->sun_path));
+
+	rc = send_recv(send_fd, recv_fd, msg, MSG_DONTWAIT);
+	printf("recvmsg(%d, {msg_name={sa_family=AF_UNIX}, msg_namelen=%d->%d"
+	       ", msg_iov=[{iov_base=\"A\", iov_len=1}], msg_iovlen=1"
+	       ", msg_controllen=0, msg_flags=0}, MSG_DONTWAIT) = %d\n",
+	       recv_fd, (int) offsetof_sun_path, (int) msg->msg_namelen, rc);
+
+	msg->msg_namelen = sizeof(struct sockaddr);
+	msg->msg_name = ((void *) (addr + 1)) - msg->msg_namelen;
+	rc = send_recv(send_fd, recv_fd, msg, MSG_DONTWAIT);
+	printf("recvmsg(%d, {msg_name={sa_family=AF_UNIX, sun_path=\"%.*s\"}"
+	       ", msg_namelen=%d->%d, msg_iov=[{iov_base=\"A\", iov_len=1}]"
+	       ", msg_iovlen=1, msg_controllen=0, msg_flags=0}, MSG_DONTWAIT)"
+	       " = %d\n",
+	       recv_fd, (int) (sizeof(struct sockaddr) - offsetof_sun_path),
+	       ((struct sockaddr_un *) msg->msg_name)->sun_path,
+	       (int) sizeof(struct sockaddr), (int) msg->msg_namelen, rc);
+
+	rc = send_recv(send_fd, recv_fd, msg, MSG_DONTWAIT);
+	printf("recvmsg(%d, {msg_namelen=%d}, MSG_DONTWAIT) = %d %s (%m)\n",
+	       recv_fd, (int) msg->msg_namelen, rc, errno2name());
+
+	/*
+	 * When recvmsg is called with a valid descriptor
+	 * but inaccessible memory, it causes segfaults on some architectures.
+	 * As in these cases we test decoding of failed recvmsg calls,
+	 * it's ok to fail recvmsg with any reason as long as
+	 * it doesn't read that inaccessible memory.
+	 */
+
+	/*
+	 * Sadly, musl recvmsg wrapper blindly dereferences 2nd argument,
+	 * so limit this test to glibc that doesn't.
+	 */
+#ifdef __GLIBC__
+	rc = send_recv(send_fd, -1, msg + 1, 0);
+	printf("recvmsg(-1, %p, 0) = %d %s (%m)\n",
+	       msg + 1, rc, errno2name());
+#endif
+
+	rc = send_recv(send_fd, -1, 0, 0);
+	printf("recvmsg(-1, NULL, 0) = %d %s (%m)\n",
+	       rc, errno2name());
+}
+
+int
+main(void)
+{
+	int fds[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds))
+		perror_msg_and_skip("socketpair");
+
+	const struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = "msg_name-recvmsg.test.send.socket"
+	};
+
+	(void) unlink(un.sun_path);
+	if (bind(fds[1], (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+	(void) unlink(un.sun_path);
+
+	test_msg_name(fds[1], fds[0]);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/msg_name.test b/strace/tests/msg_name.test
new file mode 100755
index 0000000..ac06dd5
--- /dev/null
+++ b/strace/tests/msg_name.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of struct msghdr.msg_name* arguments of recvmsg syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20 -e trace=recvmsg
diff --git a/strace/tests/munlockall.c b/strace/tests/munlockall.c
new file mode 100644
index 0000000..9ac6942
--- /dev/null
+++ b/strace/tests/munlockall.c
@@ -0,0 +1,13 @@
+#include "tests.h"
+
+#include <stdio.h>
+#include <sys/mman.h>
+
+int
+main(void)
+{
+	printf("munlockall() = %d\n", munlockall());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/munlockall.test b/strace/tests/munlockall.test
new file mode 100755
index 0000000..e25d60a
--- /dev/null
+++ b/strace/tests/munlockall.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check munlockall syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a13
diff --git a/strace/tests/nanosleep.c b/strace/tests/nanosleep.c
new file mode 100644
index 0000000..6b5999b
--- /dev/null
+++ b/strace/tests/nanosleep.c
@@ -0,0 +1,98 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <signal.h>
+#include <time.h>
+#include <sys/time.h>
+
+static void
+handler(int signo)
+{
+}
+
+int
+main(void)
+{
+	struct {
+		struct timespec ts;
+		uint32_t pad[2];
+	} req = {
+		.ts = { .tv_nsec = 0xc0de1 },
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	}, rem = {
+		.ts = { .tv_sec = 0xc0de2, .tv_nsec = 0xc0de3 },
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	};
+	const sigset_t set = {};
+	const struct sigaction act = { .sa_handler = handler };
+	const struct itimerval itv = { .it_value.tv_usec = 111111 };
+
+	if (nanosleep(&req.ts, NULL))
+		perror_msg_and_fail("nanosleep");
+	printf("nanosleep({%jd, %jd}, NULL) = 0\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec);
+
+	assert(nanosleep(NULL, &rem.ts) == -1);
+	printf("nanosleep(NULL, %p) = -1 EFAULT (%m)\n", &rem.ts);
+
+	if (nanosleep(&req.ts, &rem.ts))
+		perror_msg_and_fail("nanosleep");
+	printf("nanosleep({%jd, %jd}, %p) = 0\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec, &rem.ts);
+
+	req.ts.tv_nsec = 1000000000;
+	assert(nanosleep(&req.ts, &rem.ts) == -1);
+	printf("nanosleep({%jd, %jd}, %p) = -1 EINVAL (%m)\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec, &rem.ts);
+
+	assert(sigaction(SIGALRM, &act, NULL) == 0);
+	assert(sigprocmask(SIG_SETMASK, &set, NULL) == 0);
+
+	if (setitimer(ITIMER_REAL, &itv, NULL))
+		perror_msg_and_skip("setitimer");
+	printf("setitimer(ITIMER_REAL, {it_interval={%jd, %jd}"
+	       ", it_value={%jd, %jd}}, NULL) = 0\n",
+	       (intmax_t) itv.it_interval.tv_sec,
+	       (intmax_t) itv.it_interval.tv_usec,
+	       (intmax_t) itv.it_value.tv_sec,
+	       (intmax_t) itv.it_value.tv_usec);
+
+	req.ts.tv_nsec = 999999999;
+	assert(nanosleep(&req.ts, &rem.ts) == -1);
+	printf("nanosleep({%jd, %jd}, {%jd, %jd})"
+	       " = ? ERESTART_RESTARTBLOCK (Interrupted by signal)\n",
+	       (intmax_t) req.ts.tv_sec, (intmax_t) req.ts.tv_nsec,
+	       (intmax_t) rem.ts.tv_sec, (intmax_t) rem.ts.tv_nsec);
+	puts("--- SIGALRM {si_signo=SIGALRM, si_code=SI_KERNEL} ---");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/nanosleep.test b/strace/tests/nanosleep.test
new file mode 100755
index 0000000..055a8dc
--- /dev/null
+++ b/strace/tests/nanosleep.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check nanosleep and setitimer syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20 -e trace=nanosleep,setitimer
diff --git a/strace/tests/net-accept-connect.c b/strace/tests/net-accept-connect.c
new file mode 100644
index 0000000..04c05a6
--- /dev/null
+++ b/strace/tests/net-accept-connect.c
@@ -0,0 +1,106 @@
+/*
+ * Copyright (c) 2013-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stddef.h>
+#include <string.h>
+#include <signal.h>
+#include <unistd.h>
+#include <sys/wait.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+static void
+handler(int sig)
+{
+	assert(close(1) == 0);
+	_exit(0);
+}
+
+int
+main(int ac, const char **av)
+{
+	struct sockaddr_un addr = {
+		.sun_family = AF_UNIX,
+	};
+	socklen_t len;
+
+	assert(ac == 2);
+	assert(strlen(av[1]) > 0);
+
+	strncpy(addr.sun_path, av[1], sizeof(addr.sun_path));
+	len = offsetof(struct sockaddr_un, sun_path) + strlen(av[1]) + 1;
+	if (len > sizeof(addr))
+		len = sizeof(addr);
+
+	unlink(av[1]);
+	close(0);
+	close(1);
+
+	if (socket(AF_UNIX, SOCK_STREAM, 0))
+		perror_msg_and_skip("socket");
+	if (bind(0, (struct sockaddr *) &addr, len))
+		perror_msg_and_skip("bind");
+	if (listen(0, 5))
+		perror_msg_and_skip("listen");
+
+	memset(&addr, 0, sizeof addr);
+	assert(getsockname(0, (struct sockaddr *) &addr, &len) == 0);
+	if (len > sizeof(addr))
+		len = sizeof(addr);
+
+	pid_t pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (pid) {
+		assert(accept(0, (struct sockaddr *) &addr, &len) == 1);
+		assert(close(0) == 0);
+		assert(kill(pid, SIGUSR1) == 0);
+		int status;
+		assert(waitpid(pid, &status, 0) == pid);
+		assert(status == 0);
+		assert(close(1) == 0);
+	} else {
+		sigset_t set;
+		sigemptyset(&set);
+		sigaddset(&set, SIGUSR1);
+
+		assert(sigprocmask(SIG_BLOCK, &set, NULL) == 0);
+		assert(signal(SIGUSR1, handler) != SIG_ERR);
+		assert(socket(AF_UNIX, SOCK_STREAM, 0) == 1);
+		assert(close(0) == 0);
+		assert(connect(1, (struct sockaddr *) &addr, len) == 0);
+		assert(sigprocmask(SIG_UNBLOCK, &set, NULL) == 0);
+		assert(pause() == 99);
+		return 1;
+	}
+
+	unlink(av[1]);
+	return 0;
+}
diff --git a/strace/tests/net-icmp_filter.c b/strace/tests/net-icmp_filter.c
new file mode 100644
index 0000000..f3f99f1
--- /dev/null
+++ b/strace/tests/net-icmp_filter.c
@@ -0,0 +1,84 @@
+/*
+ * Check decoding of ICMP_FILTER.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <sys/socket.h>
+#include <linux/icmp.h>
+
+int
+main(void)
+{
+	getsockopt(-1, SOL_RAW, ICMP_FILTER, 0, 0);
+	printf("getsockopt(-1, SOL_RAW, ICMP_FILTER, NULL, NULL) = -1 %s (%m)\n",
+	       errno2name());
+
+	setsockopt(-1, SOL_RAW, ICMP_FILTER, NULL, 0);
+	printf("setsockopt(-1, SOL_RAW, ICMP_FILTER, NULL, 0) = -1 %s (%m)\n",
+	       errno2name());
+
+	socklen_t *const plen = tail_alloc(sizeof(*plen));
+	void *const efault = plen + 1;
+	struct icmp_filter *const f = tail_alloc(sizeof(*f));
+
+	getsockopt(-1, SOL_RAW, ICMP_FILTER, f, plen);
+	printf("getsockopt(-1, SOL_RAW, ICMP_FILTER, %p, %p) = -1 %s (%m)\n",
+	       f, plen, errno2name());
+
+	setsockopt(-1, SOL_RAW, ICMP_FILTER, efault, sizeof(*f));
+	printf("setsockopt(-1, SOL_RAW, ICMP_FILTER, %p, %u) = -1 %s (%m)\n",
+	       efault, (unsigned) sizeof(*f), errno2name());
+
+	f->data = ~(
+		1<<ICMP_ECHOREPLY |
+		1<<ICMP_DEST_UNREACH |
+		1<<ICMP_SOURCE_QUENCH |
+		1<<ICMP_REDIRECT |
+		1<<ICMP_TIME_EXCEEDED |
+		1<<ICMP_PARAMETERPROB);
+
+	setsockopt(-1, SOL_RAW, ICMP_FILTER, f, -2);
+	printf("setsockopt(-1, SOL_RAW, ICMP_FILTER, %p, -2) = -1 %s (%m)\n",
+	       f, errno2name());
+
+	setsockopt(-1, SOL_RAW, ICMP_FILTER, f, sizeof(*f));
+	printf("setsockopt(-1, SOL_RAW, ICMP_FILTER, %s, %u) = -1 %s (%m)\n",
+	       "~(1<<ICMP_ECHOREPLY|1<<ICMP_DEST_UNREACH|1<<ICMP_SOURCE_QUENCH"
+	       "|1<<ICMP_REDIRECT|1<<ICMP_TIME_EXCEEDED|1<<ICMP_PARAMETERPROB)",
+	       (unsigned) sizeof(*f), errno2name());
+
+	setsockopt(-1, SOL_RAW, ICMP_FILTER, f, sizeof(*f) * 2);
+	printf("setsockopt(-1, SOL_RAW, ICMP_FILTER, %s, %u) = -1 %s (%m)\n",
+	       "~(1<<ICMP_ECHOREPLY|1<<ICMP_DEST_UNREACH|1<<ICMP_SOURCE_QUENCH"
+	       "|1<<ICMP_REDIRECT|1<<ICMP_TIME_EXCEEDED|1<<ICMP_PARAMETERPROB)",
+	       (unsigned) sizeof(*f) * 2, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/net-icmp_filter.test b/strace/tests/net-icmp_filter.test
new file mode 100755
index 0000000..c05a5e6
--- /dev/null
+++ b/strace/tests/net-icmp_filter.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of ICMP_FILTER.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=getsockopt,setsockopt
diff --git a/strace/tests/net-sockaddr.c b/strace/tests/net-sockaddr.c
new file mode 100644
index 0000000..bf37779
--- /dev/null
+++ b/strace/tests/net-sockaddr.c
@@ -0,0 +1,517 @@
+/*
+ * Check decoding of sockaddr structures
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stddef.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <arpa/inet.h>
+#include <netinet/in.h>
+#include <linux/if_arp.h>
+#include <linux/if_ether.h>
+#include <linux/if_packet.h>
+#include <linux/ipx.h>
+#include <linux/netlink.h>
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+# include <bluetooth/bluetooth.h>
+# include <bluetooth/hci.h>
+# include <bluetooth/l2cap.h>
+# include <bluetooth/rfcomm.h>
+# include <bluetooth/sco.h>
+#endif
+
+#ifdef HAVE_IF_INDEXTONAME
+/* <linux/if.h> used to conflict with <net/if.h> */
+extern unsigned int if_nametoindex(const char *);
+#endif
+
+static void
+check_un(void)
+{
+	struct sockaddr_un *un = tail_alloc(sizeof(*un));
+	un->sun_family = AF_UNIX;
+	memset(un->sun_path, '0', sizeof(un->sun_path));
+	unsigned int len = sizeof(*un);
+	int ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path), 0, len, ret);
+
+	un->sun_path[1] = 0;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=\"%u\"}, %u)"
+	       " = %d EBADF (%m)\n", 0, len, ret);
+
+	un->sun_path[0] = 0;
+	un->sun_path[2] = 1;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=@\"\\0\\001%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path) - 3, 0, len, ret);
+
+	un = ((void *) un) - 2;
+	un->sun_family = AF_UNIX;
+	memset(un->sun_path, '0', sizeof(un->sun_path));
+	len = sizeof(*un) + 2;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path), 0, len, ret);
+
+	un->sun_path[0] = 0;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=@\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path) - 1, 0, len, ret);
+
+	un = ((void *) un) + 4;
+	un->sun_family = AF_UNIX;
+	len = sizeof(*un) - 2;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path) - 2, 0, len, ret);
+
+	un->sun_path[0] = 0;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=@\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path) - 3, 0, len, ret);
+
+	len = sizeof(*un);
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, %p, %u) = %d EBADF (%m)\n", un, len, ret);
+
+	un = tail_alloc(sizeof(struct sockaddr_storage));
+	un->sun_family = AF_UNIX;
+	memset(un->sun_path, '0', sizeof(un->sun_path));
+	len = sizeof(struct sockaddr_storage) + 1;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path), 0, len, ret);
+
+	un->sun_path[0] = 0;
+	ret = connect(-1, (void *) un, len);
+	printf("connect(-1, {sa_family=AF_UNIX, sun_path=@\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n",
+	       (int) sizeof(un->sun_path) - 1, 0, len, ret);
+}
+
+static void
+check_in(void)
+{
+	const unsigned short h_port = 12345;
+	static const char h_addr[] = "12.34.56.78";
+
+	struct sockaddr_in *in = tail_alloc(sizeof(*in));
+	in->sin_family = AF_INET;
+	in->sin_port = htons(h_port);
+	in->sin_addr.s_addr = inet_addr(h_addr);
+	unsigned int len = sizeof(*in);
+	int ret = connect(-1, (void *) in, len);
+	printf("connect(-1, {sa_family=AF_INET, sin_port=htons(%hu)"
+	       ", sin_addr=inet_addr(\"%s\")}, %u) = %d EBADF (%m)\n",
+	       h_port, h_addr, len, ret);
+
+	in = ((void *) in) - 4;
+	in->sin_family = AF_INET;
+	in->sin_port = htons(h_port);
+	in->sin_addr.s_addr = inet_addr(h_addr);
+	len = sizeof(*in) + 4;
+	ret = connect(-1, (void *) in, len);
+	printf("connect(-1, {sa_family=AF_INET, sin_port=htons(%hu)"
+	       ", sin_addr=inet_addr(\"%s\")}, %u) = %d EBADF (%m)\n",
+	       h_port, h_addr, len, ret);
+
+	in = ((void *) in) + 8;
+	in->sin_family = AF_INET;
+	in->sin_port = 0;
+	in->sin_addr.s_addr = 0;
+	len = sizeof(*in) - 4;
+	ret = connect(-1, (void *) in, len);
+	printf("connect(-1, {sa_family=AF_INET, sa_data=\"%s\"}, %u)"
+	       " = %d EBADF (%m)\n",
+	       "\\0\\0\\0\\0\\0\\0\\377\\377\\377\\377",
+	       len, ret);
+
+	len = sizeof(*in);
+	ret = connect(-1, (void *) in, len);
+	printf("connect(-1, %p, %u) = %d EBADF (%m)\n", in, len, ret);
+}
+
+static void
+check_in6_linklocal(struct sockaddr_in6 *const in6, const char *const h_addr)
+{
+	inet_pton(AF_INET6, h_addr, &in6->sin6_addr);
+
+	in6->sin6_scope_id = 0xfacefeed;
+	unsigned int len = sizeof(*in6);
+	int ret = connect(-1, (void *) in6, len);
+	printf("connect(-1, {sa_family=AF_INET6, sin6_port=htons(%hu)"
+	       ", inet_pton(AF_INET6, \"%s\", &sin6_addr)"
+	       ", sin6_flowinfo=htonl(%u)"
+	       ", sin6_scope_id=%u}, %u)"
+	       " = %d EBADF (%m)\n",
+	       ntohs(in6->sin6_port), h_addr,
+	       ntohl(in6->sin6_flowinfo), in6->sin6_scope_id, len, ret);
+
+#ifdef HAVE_IF_INDEXTONAME
+	in6->sin6_scope_id = if_nametoindex("lo");
+	if (in6->sin6_scope_id) {
+		ret = connect(-1, (void *) in6, len);
+		printf("connect(-1, {sa_family=AF_INET6, sin6_port=htons(%hu)"
+		       ", inet_pton(AF_INET6, \"%s\", &sin6_addr)"
+		       ", sin6_flowinfo=htonl(%u)"
+		       ", sin6_scope_id=if_nametoindex(\"lo\")}, %u)"
+		       " = %d EBADF (%m)\n",
+		       ntohs(in6->sin6_port), h_addr,
+		       ntohl(in6->sin6_flowinfo), len, ret);
+	}
+#endif
+}
+
+static void
+check_in6(void)
+{
+	const unsigned short h_port = 12345;
+	const unsigned int h_flowinfo = 1234567890;
+	static const char h_addr[] = "12:34:56:78:90:ab:cd:ef";
+
+	struct sockaddr_in6 *in6 = tail_alloc(sizeof(*in6));
+	in6->sin6_family = AF_INET6;
+	in6->sin6_port = htons(h_port);
+	in6->sin6_flowinfo = htonl(h_flowinfo);
+	inet_pton(AF_INET6, h_addr, &in6->sin6_addr);
+	in6->sin6_scope_id = 0xfacefeed;
+	unsigned int len = sizeof(*in6);
+	int ret = connect(-1, (void *) in6, len);
+	printf("connect(-1, {sa_family=AF_INET6, sin6_port=htons(%hu)"
+	       ", inet_pton(AF_INET6, \"%s\", &sin6_addr)"
+	       ", sin6_flowinfo=htonl(%u), sin6_scope_id=%u}, %u)"
+	       " = %d EBADF (%m)\n",
+	       h_port, h_addr, h_flowinfo, in6->sin6_scope_id, len, ret);
+
+	check_in6_linklocal(in6, "fe80::");
+	check_in6_linklocal(in6, "ff42::");
+
+	in6 = ((void *) in6) - 4;
+	in6->sin6_family = AF_INET6;
+	in6->sin6_port = htons(h_port);
+	in6->sin6_flowinfo = htonl(h_flowinfo);
+	inet_pton(AF_INET6, h_addr, &in6->sin6_addr);
+	in6->sin6_scope_id = 0xfacefeed;
+	len = sizeof(*in6) + 4;
+	ret = connect(-1, (void *) in6, len);
+	printf("connect(-1, {sa_family=AF_INET6, sin6_port=htons(%hu)"
+	       ", inet_pton(AF_INET6, \"%s\", &sin6_addr)"
+	       ", sin6_flowinfo=htonl(%u), sin6_scope_id=%u}, %u)"
+	       " = %d EBADF (%m)\n",
+	       h_port, h_addr, h_flowinfo, in6->sin6_scope_id, len, ret);
+
+	in6 = ((void *) in6) + 4 + sizeof(in6->sin6_scope_id);
+	in6->sin6_family = AF_INET6;
+	in6->sin6_port = htons(h_port);
+	in6->sin6_flowinfo = htonl(h_flowinfo);
+	inet_pton(AF_INET6, h_addr, &in6->sin6_addr);
+	len = sizeof(*in6) - sizeof(in6->sin6_scope_id);
+	ret = connect(-1, (void *) in6, len);
+	printf("connect(-1, {sa_family=AF_INET6, sin6_port=htons(%hu)"
+	       ", inet_pton(AF_INET6, \"%s\", &sin6_addr)"
+	       ", sin6_flowinfo=htonl(%u)}, %u)"
+	       " = %d EBADF (%m)\n",
+	       h_port, h_addr, h_flowinfo, len, ret);
+
+	in6 = ((void *) in6) + 4;
+	in6->sin6_family = AF_INET6;
+	in6->sin6_port = 0;
+	in6->sin6_flowinfo = 0;
+	memset(&in6->sin6_addr, '0', sizeof(in6->sin6_addr) - 4);
+	len = sizeof(*in6) - sizeof(in6->sin6_scope_id) - 4;
+	ret = connect(-1, (void *) in6, len);
+	printf("connect(-1, {sa_family=AF_INET6"
+	       ", sa_data=\"\\0\\0\\0\\0\\0\\000%.*u\"}, %u)"
+	       " = %d EBADF (%m)\n",
+	       (int) (len - offsetof(struct sockaddr_in6, sin6_addr)), 0,
+	       len, ret);
+
+	len = sizeof(*in6) - sizeof(in6->sin6_scope_id);
+	ret = connect(-1, (void *) in6, len);
+	printf("connect(-1, %p, %u) = %d EBADF (%m)\n", in6, len, ret);
+}
+
+static void
+check_ipx(void)
+{
+	const unsigned short h_port = 12345;
+	const unsigned int h_network = 0xfacefeed;
+	struct sockaddr_ipx c_ipx = {
+		.sipx_family = AF_IPX,
+		.sipx_port = htons(h_port),
+		.sipx_network = htonl(h_network),
+		.sipx_node = "ABCDEF",
+		.sipx_type = -1
+	};
+	void *ipx = tail_memdup(&c_ipx, sizeof(c_ipx));
+	unsigned int len = sizeof(c_ipx);
+	int ret = connect(-1, ipx, len);
+	printf("connect(-1, {sa_family=AF_IPX, sipx_port=htons(%u)"
+	       ", sipx_network=htonl(%#x)"
+	       ", sipx_node=[%#02x, %#02x, %#02x, %#02x, %#02x, %#02x]"
+	       ", sipx_type=%#02x}, %u) = %d EBADF (%m)\n",
+	       h_port, h_network,
+	       c_ipx.sipx_node[0], c_ipx.sipx_node[1],
+	       c_ipx.sipx_node[2], c_ipx.sipx_node[3],
+	       c_ipx.sipx_node[4], c_ipx.sipx_node[5],
+	       c_ipx.sipx_type, len, ret);
+}
+
+static void
+check_nl(void)
+{
+	struct sockaddr_nl *nl = tail_alloc(sizeof(*nl));
+	nl->nl_family = AF_NETLINK;
+	nl->nl_pid = 1234567890;
+	nl->nl_groups = 0xfacefeed;
+	unsigned int len = sizeof(*nl);
+	int ret = connect(-1, (void *) nl, len);
+	printf("connect(-1, {sa_family=AF_NETLINK, nl_pid=%d"
+	       ", nl_groups=%#08x}, %u) = %d EBADF (%m)\n",
+	       nl->nl_pid, nl->nl_groups, len, ret);
+
+	nl = ((void *) nl) - 4;
+	nl->nl_family = AF_NETLINK;
+	nl->nl_pid = 1234567890;
+	nl->nl_groups = 0xfacefeed;
+	len = sizeof(*nl) + 4;
+	ret = connect(-1, (void *) nl, len);
+	printf("connect(-1, {sa_family=AF_NETLINK, nl_pid=%d"
+	       ", nl_groups=%#08x}, %u) = %d EBADF (%m)\n",
+	       nl->nl_pid, nl->nl_groups, len, ret);
+}
+
+static void
+check_ll(void)
+{
+	struct sockaddr_ll c_ll = {
+		.sll_family = AF_PACKET,
+		.sll_protocol = htons(ETH_P_ALL),
+		.sll_ifindex = 0xfacefeed,
+		.sll_hatype = ARPHRD_ETHER,
+		.sll_pkttype = PACKET_HOST,
+		.sll_halen = sizeof(c_ll.sll_addr),
+		.sll_addr = "abcdefgh"
+	};
+	void *ll = tail_memdup(&c_ll, sizeof(c_ll));
+	unsigned int len = sizeof(c_ll);
+	int ret = connect(-1, ll, len);
+	printf("connect(-1, {sa_family=AF_PACKET"
+	       ", sll_protocol=htons(ETH_P_ALL)"
+	       ", sll_ifindex=%u, sll_hatype=ARPHRD_ETHER"
+	       ", sll_pkttype=PACKET_HOST, sll_halen=%u, sll_addr="
+	       "[%#02x, %#02x, %#02x, %#02x, %#02x, %#02x, %#02x, %#02x]"
+	       "}, %u) = %d EBADF (%m)\n",
+	       c_ll.sll_ifindex, c_ll.sll_halen,
+	       c_ll.sll_addr[0], c_ll.sll_addr[1],
+	       c_ll.sll_addr[2], c_ll.sll_addr[3],
+	       c_ll.sll_addr[4], c_ll.sll_addr[5],
+	       c_ll.sll_addr[6], c_ll.sll_addr[7],
+	       len, ret);
+
+	((struct sockaddr_ll *) ll)->sll_halen++;
+	ret = connect(-1, ll, len);
+	printf("connect(-1, {sa_family=AF_PACKET"
+	       ", sll_protocol=htons(ETH_P_ALL)"
+	       ", sll_ifindex=%u, sll_hatype=ARPHRD_ETHER"
+	       ", sll_pkttype=PACKET_HOST, sll_halen=%u, sll_addr="
+	       "[%#02x, %#02x, %#02x, %#02x, %#02x, %#02x, %#02x, %#02x, ...]"
+	       "}, %u) = %d EBADF (%m)\n",
+	       c_ll.sll_ifindex, c_ll.sll_halen + 1,
+	       c_ll.sll_addr[0], c_ll.sll_addr[1],
+	       c_ll.sll_addr[2], c_ll.sll_addr[3],
+	       c_ll.sll_addr[4], c_ll.sll_addr[5],
+	       c_ll.sll_addr[6], c_ll.sll_addr[7],
+	       len, ret);
+
+	((struct sockaddr_ll *) ll)->sll_halen = 0;
+	ret = connect(-1, ll, len);
+	printf("connect(-1, {sa_family=AF_PACKET"
+	       ", sll_protocol=htons(ETH_P_ALL)"
+	       ", sll_ifindex=%u, sll_hatype=ARPHRD_ETHER"
+	       ", sll_pkttype=PACKET_HOST, sll_halen=0}, %u)"
+	       " = %d EBADF (%m)\n", c_ll.sll_ifindex, len, ret);
+
+#ifdef HAVE_IF_INDEXTONAME
+	const int id = if_nametoindex("lo");
+	if (id) {
+		((struct sockaddr_ll *) ll)->sll_ifindex = id;
+		ret = connect(-1, ll, len);
+		printf("connect(-1, {sa_family=AF_PACKET"
+		       ", sll_protocol=htons(ETH_P_ALL)"
+		       ", sll_ifindex=if_nametoindex(\"lo\")"
+		       ", sll_hatype=ARPHRD_ETHER"
+		       ", sll_pkttype=PACKET_HOST, sll_halen=0}, %u)"
+		       " = %d EBADF (%m)\n", len, ret);
+	}
+#endif
+}
+
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+static void
+check_hci(void)
+{
+	const unsigned short h_port = 12345;
+	struct sockaddr_hci *hci = tail_alloc(sizeof(*hci));
+	hci->hci_family = AF_BLUETOOTH;
+	hci->hci_dev = htobs(h_port);
+	hci->hci_channel = HCI_CHANNEL_RAW;
+	unsigned int len = sizeof(*hci);
+	int ret = connect(-1, (void *) hci, len);
+	printf("connect(-1, {sa_family=AF_BLUETOOTH, hci_dev=htobs(%hu)"
+	       ", hci_channel=HCI_CHANNEL_RAW}, %u) = %d EBADF (%m)\n",
+	       h_port, len, ret);
+}
+
+static void
+check_sco(void)
+{
+	const struct sockaddr_sco c_sco = {
+		.sco_family = AF_BLUETOOTH,
+		.sco_bdaddr.b = "abcdef"
+	};
+	void *sco = tail_memdup(&c_sco, sizeof(c_sco));
+	unsigned int len = sizeof(c_sco);
+	int ret = connect(-1, sco, len);
+	printf("connect(-1, {sa_family=AF_BLUETOOTH"
+	       ", sco_bdaddr=%02x:%02x:%02x:%02x:%02x:%02x"
+	       "}, %u) = %d EBADF (%m)\n",
+	       c_sco.sco_bdaddr.b[0], c_sco.sco_bdaddr.b[1],
+	       c_sco.sco_bdaddr.b[2], c_sco.sco_bdaddr.b[3],
+	       c_sco.sco_bdaddr.b[4], c_sco.sco_bdaddr.b[5],
+	       len, ret);
+}
+
+static void
+check_rc(void)
+{
+	const struct sockaddr_rc c_rc = {
+		.rc_family = AF_BLUETOOTH,
+		.rc_bdaddr.b = "abcdef",
+		.rc_channel = 42
+	};
+	void *rc = tail_memdup(&c_rc, sizeof(c_rc));
+	unsigned int len = sizeof(c_rc);
+	int ret = connect(-1, rc, len);
+	printf("connect(-1, {sa_family=AF_BLUETOOTH"
+	       ", rc_bdaddr=%02x:%02x:%02x:%02x:%02x:%02x"
+	       ", rc_channel=%u}, %u) = %d EBADF (%m)\n",
+	       c_rc.rc_bdaddr.b[0], c_rc.rc_bdaddr.b[1],
+	       c_rc.rc_bdaddr.b[2], c_rc.rc_bdaddr.b[3],
+	       c_rc.rc_bdaddr.b[4], c_rc.rc_bdaddr.b[5],
+	       c_rc.rc_channel, len, ret);
+}
+
+static void
+check_l2(void)
+{
+	const unsigned short h_psm = 12345;
+	const unsigned short h_cid = 13579;
+	const struct sockaddr_l2 c_l2 = {
+		.l2_family = AF_BLUETOOTH,
+		.l2_psm = htobs(h_psm),
+		.l2_bdaddr.b = "abcdef",
+		.l2_cid = htobs(h_cid),
+		.l2_bdaddr_type = 42
+	};
+	void *l2 = tail_memdup(&c_l2, sizeof(c_l2));
+	unsigned int len = sizeof(c_l2);
+	int ret = connect(-1, l2, len);
+	printf("connect(-1, {sa_family=AF_BLUETOOTH"
+	       ", l2_psm=htobs(%hu)"
+	       ", l2_bdaddr=%02x:%02x:%02x:%02x:%02x:%02x"
+	       ", l2_cid=htobs(%hu), l2_bdaddr_type=%u}"
+	       ", %u) = %d EBADF (%m)\n", h_psm,
+	       c_l2.l2_bdaddr.b[0], c_l2.l2_bdaddr.b[1],
+	       c_l2.l2_bdaddr.b[2], c_l2.l2_bdaddr.b[3],
+	       c_l2.l2_bdaddr.b[4], c_l2.l2_bdaddr.b[5],
+	       h_cid, c_l2.l2_bdaddr_type, len, ret);
+}
+#endif
+
+static void
+check_raw(void)
+{
+	union {
+		struct sockaddr *sa;
+		struct sockaddr_storage *st;
+	} u = { .st = tail_alloc(sizeof(*u.st)) };
+	memset(u.st, '0', sizeof(*u.st));
+	u.sa->sa_family = 0xff;
+	unsigned int len = sizeof(*u.st) + 8;
+	int ret = connect(-1, (void *) u.st, len);
+	printf("connect(-1, {sa_family=%#x /* AF_??? */, sa_data=\"%.*u\"}"
+	       ", %u) = %d EBADF (%m)\n", u.sa->sa_family,
+	       (int) (sizeof(*u.st) - sizeof(u.sa->sa_family)), 0, len, ret);
+
+	u.sa->sa_family = 0;
+	len = sizeof(u.sa->sa_family) + 1;
+	ret = connect(-1, (void *) u.st, len);
+	printf("connect(-1, {sa_family=AF_UNSPEC, sa_data=\"0\"}, %u)"
+	       " = %d EBADF (%m)\n", len, ret);
+
+	u.sa->sa_family = AF_BLUETOOTH;
+	++len;
+	ret = connect(-1, (void *) u.st, len);
+	printf("connect(-1, {sa_family=AF_BLUETOOTH, sa_data=\"00\"}, %u)"
+	       " = %d EBADF (%m)\n", len, ret);
+}
+
+int
+main(void)
+{
+	check_un();
+	check_in();
+	check_in6();
+	check_ipx();
+	check_nl();
+	check_ll();
+#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
+	check_hci();
+	check_sco();
+	check_rc();
+	check_l2();
+#endif
+	check_raw();
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/net-sockaddr.test b/strace/tests/net-sockaddr.test
new file mode 100755
index 0000000..cdfe536
--- /dev/null
+++ b/strace/tests/net-sockaddr.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of sockaddr structures.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24 -e trace=connect
diff --git a/strace/tests/net-y-unix.c b/strace/tests/net-y-unix.c
new file mode 100644
index 0000000..3efc2f6
--- /dev/null
+++ b/strace/tests/net-y-unix.c
@@ -0,0 +1,235 @@
+/*
+ * This file is part of net-y-unix strace test.
+ *
+ * Copyright (c) 2013-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/param.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+int
+main(int ac, const char **av)
+{
+	assert(ac == 2);
+
+	struct sockaddr_un addr = { .sun_family = AF_UNIX };
+	unsigned int sun_path_len = strlen(av[1]);
+	assert(sun_path_len > 0 && sun_path_len <= sizeof(addr.sun_path));
+	strncpy(addr.sun_path, av[1], sizeof(addr.sun_path));
+	struct sockaddr * const listen_sa = tail_memdup(&addr, sizeof(addr));
+
+	socklen_t * const len = tail_alloc(sizeof(socklen_t));
+	*len = offsetof(struct sockaddr_un, sun_path) + strlen(av[1]) + 1;
+	if (*len > sizeof(addr))
+		*len = sizeof(addr);
+
+	int listen_fd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (listen_fd < 0)
+		perror_msg_and_skip("socket");
+	unsigned long listen_inode = inode_of_sockfd(listen_fd);
+	printf("socket(AF_UNIX, SOCK_STREAM, 0) = %d<socket:[%lu]>\n",
+	       listen_fd, listen_inode);
+
+	(void) unlink(av[1]);
+	if (bind(listen_fd, listen_sa, *len))
+		perror_msg_and_skip("bind");
+	printf("bind(%d<socket:[%lu]>, {sa_family=AF_UNIX, sun_path=\"%s\"}"
+	       ", %u) = 0\n", listen_fd, listen_inode, av[1], (unsigned) *len);
+
+	if (listen(listen_fd, 1))
+		perror_msg_and_skip("listen");
+	printf("listen(%d<socket:[%lu]>, 1) = 0\n", listen_fd, listen_inode);
+
+	unsigned int * const optval = tail_alloc(sizeof(unsigned int));
+	*len = sizeof(*optval);
+	if (getsockopt(listen_fd, SOL_SOCKET, SO_PASSCRED, optval, len))
+		perror_msg_and_fail("getsockopt");
+	printf("getsockopt(%d<socket:[%lu]>, SOL_SOCKET, SO_PASSCRED"
+	       ", [%u], [%u]) = 0\n",
+	       listen_fd, listen_inode, *optval, (unsigned) *len);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getsockname(listen_fd, listen_sa, len))
+		perror_msg_and_fail("getsockname");
+	printf("getsockname(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n", listen_fd, listen_inode,
+	       av[1], (int) sizeof(addr), (int) *len);
+
+	int connect_fd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (connect_fd < 0)
+		perror_msg_and_fail("socket");
+	unsigned long connect_inode = inode_of_sockfd(connect_fd);
+	printf("socket(AF_UNIX, SOCK_STREAM, 0) = %d<socket:[%lu]>\n",
+	       connect_fd, connect_inode);
+
+	if (connect(connect_fd, listen_sa, *len))
+		perror_msg_and_fail("connect");
+	printf("connect(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, %u) = 0\n",
+	       connect_fd, connect_inode, av[1], (unsigned) *len);
+
+	struct sockaddr * const accept_sa = tail_alloc(sizeof(addr));
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	int accept_fd = accept(listen_fd, accept_sa, len);
+	if (accept_fd < 0)
+		perror_msg_and_fail("accept");
+	unsigned long accept_inode = inode_of_sockfd(accept_fd);
+	printf("accept(%d<socket:[%lu]>, {sa_family=AF_UNIX}"
+	       ", [%d->%d]) = %d<socket:[%lu]>\n",
+	       listen_fd, listen_inode,
+	       (int) sizeof(addr), (int) *len,
+	       accept_fd, accept_inode);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getpeername(connect_fd, listen_sa, len))
+		perror_msg_and_fail("getpeername");
+	printf("getpeername(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n", connect_fd, connect_inode,
+	       av[1], (int) sizeof(addr), (int) *len);
+
+	char text[] = "text";
+	assert(sendto(connect_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, 0)
+	       == sizeof(text) - 1);
+	printf("sendto(%d<socket:[%lu]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, 0) = %u\n",
+	       connect_fd, connect_inode, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(connect_fd) == 0);
+	printf("close(%d<socket:[%lu]>) = 0\n", connect_fd, connect_inode);
+
+	assert(recvfrom(accept_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, NULL)
+	       == sizeof(text) - 1);
+	printf("recvfrom(%d<socket:[%lu]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, NULL) = %u\n",
+	       accept_fd, accept_inode, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(accept_fd) == 0);
+	printf("close(%d<socket:[%lu]>) = 0\n", accept_fd, accept_inode);
+
+	connect_fd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (connect_fd < 0)
+		perror_msg_and_fail("socket");
+	connect_inode = inode_of_sockfd(connect_fd);
+	printf("socket(AF_UNIX, SOCK_STREAM, 0) = %d<socket:[%lu]>\n",
+	       connect_fd, connect_inode);
+
+	*optval = 1;
+	*len = sizeof(*optval);
+	if (setsockopt(connect_fd, SOL_SOCKET, SO_PASSCRED, optval, *len))
+		perror_msg_and_fail("setsockopt");
+	printf("setsockopt(%d<socket:[%lu]>, SOL_SOCKET, SO_PASSCRED"
+	       ", [%u], %u) = 0\n",
+	       connect_fd, connect_inode, *optval, (unsigned) *len);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getsockname(listen_fd, listen_sa, len))
+		perror_msg_and_fail("getsockname");
+	printf("getsockname(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n",
+	       listen_fd, listen_inode, av[1],
+	       (int) sizeof(addr), (int) *len);
+
+	if (connect(connect_fd, listen_sa, *len))
+		perror_msg_and_fail("connect");
+	printf("connect(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, %u) = 0\n",
+	       connect_fd, connect_inode, av[1], (unsigned) *len);
+
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	accept_fd = accept(listen_fd, accept_sa, len);
+	if (accept_fd < 0)
+		perror_msg_and_fail("accept");
+	accept_inode = inode_of_sockfd(accept_fd);
+	const char * const sun_path1 =
+		((struct sockaddr_un *) accept_sa) -> sun_path + 1;
+	printf("accept(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=@\"%s\"}, [%d->%d]) = %d<socket:[%lu]>\n",
+	       listen_fd, listen_inode, sun_path1,
+	       (int) sizeof(addr), (int) *len,
+	       accept_fd, accept_inode);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getpeername(connect_fd, listen_sa, len))
+		perror_msg_and_fail("getpeername");
+	printf("getpeername(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n",
+	       connect_fd, connect_inode, av[1],
+	       (int) sizeof(addr), (int) *len);
+
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getsockname(connect_fd, accept_sa, len))
+		perror_msg_and_fail("getsockname");
+	printf("getsockname(%d<socket:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=@\"%s\"}, [%d->%d]) = 0\n",
+	       connect_fd, connect_inode, sun_path1,
+	       (int) sizeof(addr), (int) *len);
+
+	assert(sendto(connect_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, 0)
+	       == sizeof(text) - 1);
+	printf("sendto(%d<socket:[%lu]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, 0) = %u\n",
+	       connect_fd, connect_inode, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(connect_fd) == 0);
+	printf("close(%d<socket:[%lu]>) = 0\n", connect_fd, connect_inode);
+
+	assert(recvfrom(accept_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, NULL)
+	       == sizeof(text) - 1);
+	printf("recvfrom(%d<socket:[%lu]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, NULL) = %u\n",
+	       accept_fd, accept_inode, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(accept_fd) == 0);
+	printf("close(%d<socket:[%lu]>) = 0\n", accept_fd, accept_inode);
+
+	assert(unlink(av[1]) == 0);
+
+	assert(close(listen_fd) == 0);
+	printf("close(%d<socket:[%lu]>) = 0\n",
+	       listen_fd, listen_inode);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/net-y-unix.test b/strace/tests/net-y-unix.test
new file mode 100755
index 0000000..aec8159
--- /dev/null
+++ b/strace/tests/net-y-unix.test
@@ -0,0 +1,46 @@
+#!/bin/sh
+#
+# Check decoding of network syscalls in -y mode.
+#
+# Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -y is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+check_prog sed
+
+addr="$NAME-local-stream"
+run_prog "./$NAME" $addr > /dev/null
+
+run_strace -a20 -y -eclose,network $args > "$EXP"
+# Filter out close() calls made by ld.so and libc.
+sed -n '/socket/,$p' < "$LOG" > "$OUT"
+
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/net-yy-inet.c b/strace/tests/net-yy-inet.c
new file mode 100644
index 0000000..f76f941
--- /dev/null
+++ b/strace/tests/net-yy-inet.c
@@ -0,0 +1,173 @@
+/*
+ * This file is part of net-yy-inet strace test.
+ *
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <netinet/tcp.h>
+#include <arpa/inet.h>
+
+int
+main(void)
+{
+	const struct sockaddr_in addr = {
+		.sin_family = AF_INET,
+		.sin_addr.s_addr = htonl(INADDR_LOOPBACK)
+	};
+	struct sockaddr * const listen_sa = tail_memdup(&addr, sizeof(addr));
+	socklen_t * const len = tail_alloc(sizeof(socklen_t));
+	*len = sizeof(addr);
+
+	const int listen_fd = socket(AF_INET, SOCK_STREAM, 0);
+	if (listen_fd < 0)
+		perror_msg_and_skip("socket");
+	const unsigned long listen_inode = inode_of_sockfd(listen_fd);
+	printf("socket(AF_INET, SOCK_STREAM, IPPROTO_IP) = %d<TCP:[%lu]>\n",
+	       listen_fd, listen_inode);
+
+	if (bind(listen_fd, listen_sa, *len))
+		perror_msg_and_skip("bind");
+	printf("bind(%d<TCP:[%lu]>, {sa_family=AF_INET, sin_port=htons(0)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}, %u) = 0\n",
+	       listen_fd, listen_inode, (unsigned) *len);
+
+	if (listen(listen_fd, 1))
+		perror_msg_and_skip("listen");
+	printf("listen(%d<TCP:[%lu]>, 1) = 0\n", listen_fd, listen_inode);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getsockname(listen_fd, listen_sa, len))
+		perror_msg_and_fail("getsockname");
+	const unsigned int listen_port =
+		ntohs(((struct sockaddr_in *) listen_sa) -> sin_port);
+	printf("getsockname(%d<TCP:[127.0.0.1:%u]>, {sa_family=AF_INET"
+	       ", sin_port=htons(%u), sin_addr=inet_addr(\"127.0.0.1\")}"
+	       ", [%u]) = 0\n",
+	       listen_fd, listen_port, listen_port, (unsigned) *len);
+
+	unsigned int * const optval = tail_alloc(sizeof(unsigned int));
+	*len = sizeof(*optval);
+	if (getsockopt(listen_fd, SOL_TCP, TCP_MAXSEG, optval, len))
+		perror_msg_and_fail("getsockopt");
+	printf("getsockopt(%d<TCP:[127.0.0.1:%u]>, SOL_TCP, TCP_MAXSEG"
+	       ", [%u], [%u]) = 0\n",
+	       listen_fd, listen_port, *optval, (unsigned) *len);
+
+	const int connect_fd = socket(AF_INET, SOCK_STREAM, 0);
+	if (connect_fd < 0)
+		perror_msg_and_fail("socket");
+	const unsigned long connect_inode = inode_of_sockfd(connect_fd);
+	printf("socket(AF_INET, SOCK_STREAM, IPPROTO_IP) = %d<TCP:[%lu]>\n",
+	       connect_fd, connect_inode);
+
+	*len = sizeof(addr);
+	if (connect(connect_fd, listen_sa, *len))
+		perror_msg_and_fail("connect");
+	printf("connect(%d<TCP:[%lu]>, {sa_family=AF_INET, sin_port=htons(%u)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}, %u) = 0\n",
+	       connect_fd, connect_inode, listen_port, (unsigned) *len);
+
+	struct sockaddr * const accept_sa = tail_alloc(sizeof(addr));
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	const int accept_fd = accept(listen_fd, accept_sa, len);
+	if (accept_fd < 0)
+		perror_msg_and_fail("accept");
+	const unsigned int connect_port =
+		ntohs(((struct sockaddr_in *) accept_sa) -> sin_port);
+	printf("accept(%d<TCP:[127.0.0.1:%u]>, {sa_family=AF_INET"
+	       ", sin_port=htons(%u), sin_addr=inet_addr(\"127.0.0.1\")}"
+	       ", [%u]) = %d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>\n",
+	       listen_fd, listen_port, connect_port, (unsigned) *len,
+	       accept_fd, listen_port, connect_port);
+
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getpeername(accept_fd, accept_sa, len))
+		perror_msg_and_fail("getpeername");
+	printf("getpeername(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>"
+	       ", {sa_family=AF_INET, sin_port=htons(%u)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}, [%u]) = 0\n",
+	       accept_fd, listen_port, connect_port, connect_port,
+	       (unsigned) *len);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getpeername(connect_fd, listen_sa, len))
+		perror_msg_and_fail("getpeername");
+	printf("getpeername(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>"
+	       ", {sa_family=AF_INET, sin_port=htons(%u)"
+	       ", sin_addr=inet_addr(\"127.0.0.1\")}, [%u]) = 0\n",
+	       connect_fd, connect_port, listen_port, listen_port,
+	       (unsigned) *len);
+
+	*len = sizeof(*optval);
+	if (setsockopt(connect_fd, SOL_TCP, TCP_MAXSEG, optval, *len))
+		perror_msg_and_fail("setsockopt");
+	printf("setsockopt(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>"
+	       ", SOL_TCP, TCP_MAXSEG, [%u], %u) = 0\n",
+	       connect_fd, connect_port, listen_port, *optval,
+	       (unsigned) *len);
+
+	char text[] = "text";
+	assert(sendto(connect_fd, text, sizeof(text) - 1,
+	       MSG_DONTROUTE | MSG_DONTWAIT, NULL, 0) == sizeof(text) - 1);
+	printf("sendto(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>, \"%s\", %u"
+	       ", MSG_DONTROUTE|MSG_DONTWAIT, NULL, 0) = %u\n",
+	       connect_fd, connect_port, listen_port, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(connect_fd) == 0);
+	printf("close(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>) = 0\n",
+	       connect_fd, connect_port, listen_port);
+
+	assert(recvfrom(accept_fd, text, sizeof(text) - 1, MSG_WAITALL,
+			NULL, NULL) == sizeof(text) - 1);
+	printf("recvfrom(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>, \"%s\", %u"
+	       ", MSG_WAITALL, NULL, NULL) = %u\n",
+	       accept_fd, listen_port, connect_port, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(accept_fd) == 0);
+	printf("close(%d<TCP:[127.0.0.1:%u->127.0.0.1:%u]>) = 0\n",
+	       accept_fd, listen_port, connect_port);
+
+	assert(close(listen_fd) == 0);
+	printf("close(%d<TCP:[127.0.0.1:%u]>) = 0\n",
+	       listen_fd, listen_port);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/net-yy-inet.test b/strace/tests/net-yy-inet.test
new file mode 100755
index 0000000..2ebf91f
--- /dev/null
+++ b/strace/tests/net-yy-inet.test
@@ -0,0 +1,46 @@
+#!/bin/sh
+#
+# Check decoding of ip:port pairs associated with socket descriptors
+#
+# Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -yy is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+check_prog sed
+run_prog ./netlink_inet_diag
+
+run_prog "./$NAME" > /dev/null
+
+run_strace -a22 -yy -eclose,network $args > "$EXP"
+# Filter out close() calls made by ld.so and libc.
+sed -n '/socket/,$p' < "$LOG" > "$OUT"
+
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/net-yy-netlink.c b/strace/tests/net-yy-netlink.c
new file mode 100644
index 0000000..64d0efc
--- /dev/null
+++ b/strace/tests/net-yy-netlink.c
@@ -0,0 +1,84 @@
+/*
+ * This file is part of net-yy-netlink strace test.
+ *
+ * Copyright (c) 2013-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2016 Fabien Siron <fabien.siron@epita.fr>
+ * 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 "tests.h"
+#include <stddef.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <stdint.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <linux/netlink.h>
+#include <linux/sock_diag.h>
+#include <linux/netlink_diag.h>
+
+#if !defined NETLINK_SOCK_DIAG && defined NETLINK_INET_DIAG
+# define NETLINK_SOCK_DIAG NETLINK_INET_DIAG
+#endif
+
+int
+main(void)
+{
+	unsigned magic = 1234;
+	struct sockaddr_nl addr = {
+		.nl_family = AF_NETLINK,
+		.nl_pid = 1234
+	};
+	struct sockaddr *const sa = tail_memdup(&addr, sizeof(addr));
+	socklen_t * const len = tail_alloc(sizeof(socklen_t));
+	*len = sizeof(addr);
+
+	const int fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG);
+	if (fd < 0)
+		perror_msg_and_skip("socket");
+	const unsigned long inode = inode_of_sockfd(fd);
+	printf("socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG) = "
+	       "%d<NETLINK:[%lu]>\n", fd, inode);
+
+	if (bind(fd, sa, *len))
+		perror_msg_and_skip("bind");
+	printf("bind(%d<NETLINK:[%lu]>, {sa_family=AF_NETLINK"
+	       ", nl_pid=%u, nl_groups=00000000}, %u) = 0\n",
+	       fd, inode, magic, (unsigned) *len);
+
+	if (getsockname(fd, sa, len))
+		perror_msg_and_fail("getsockname");
+	printf("getsockname(%d<NETLINK:[SOCK_DIAG:%u]>, {sa_family=AF_NETLINK"
+	       ", nl_pid=%u, nl_groups=00000000}, [%u]) = 0\n",
+	       fd, magic, magic, (unsigned) *len);
+
+	if (close(fd))
+		perror_msg_and_fail("close");
+	printf("close(%d<NETLINK:[SOCK_DIAG:%u]>) = 0\n", fd, magic);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/net-yy-netlink.test b/strace/tests/net-yy-netlink.test
new file mode 100755
index 0000000..bff1d86
--- /dev/null
+++ b/strace/tests/net-yy-netlink.test
@@ -0,0 +1,49 @@
+#!/bin/sh
+#
+# Check decoding of protocol:portid pairs associated with socket
+# descriptors
+#
+# Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+# Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+# Copyright (c) 2016 Fabien Siron <fabien.siron@epita.fr>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -yy is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+check_prog sed
+run_prog ./netlink_netlink_diag
+
+run_prog "./$NAME" > /dev/null
+
+run_strace -a22 -yy -eclose,network $args > "$EXP"
+# Filter out close() calls made by ld.so and libc.
+sed -n '/socket/,$p' < "$LOG" > "$OUT"
+
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/net-yy-unix.c b/strace/tests/net-yy-unix.c
new file mode 100644
index 0000000..63637bd
--- /dev/null
+++ b/strace/tests/net-yy-unix.c
@@ -0,0 +1,229 @@
+/*
+ * This file is part of net-yy-unix strace test.
+ *
+ * Copyright (c) 2013-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/param.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+int
+main(int ac, const char **av)
+{
+	assert(ac == 2);
+
+	struct sockaddr_un addr = { .sun_family = AF_UNIX };
+	unsigned int sun_path_len = strlen(av[1]);
+	assert(sun_path_len > 0 && sun_path_len <= sizeof(addr.sun_path));
+	strncpy(addr.sun_path, av[1], sizeof(addr.sun_path));
+	struct sockaddr * const listen_sa = tail_memdup(&addr, sizeof(addr));
+
+	socklen_t * const len = tail_alloc(sizeof(socklen_t));
+	*len = offsetof(struct sockaddr_un, sun_path) + strlen(av[1]) + 1;
+	if (*len > sizeof(addr))
+		*len = sizeof(addr);
+
+	int listen_fd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (listen_fd < 0)
+		perror_msg_and_skip("socket");
+	unsigned long listen_inode = inode_of_sockfd(listen_fd);
+	printf("socket(AF_UNIX, SOCK_STREAM, 0) = %d<UNIX:[%lu]>\n",
+	       listen_fd, listen_inode);
+
+	(void) unlink(av[1]);
+	if (bind(listen_fd, listen_sa, *len))
+		perror_msg_and_skip("bind");
+	printf("bind(%d<UNIX:[%lu]>, {sa_family=AF_UNIX, sun_path=\"%s\"}"
+	       ", %u) = 0\n", listen_fd, listen_inode, av[1], (unsigned) *len);
+
+	if (listen(listen_fd, 1))
+		perror_msg_and_skip("listen");
+	printf("listen(%d<UNIX:[%lu,\"%s\"]>, 1) = 0\n",
+	       listen_fd, listen_inode, av[1]);
+
+	unsigned int * const optval = tail_alloc(sizeof(unsigned int));
+	*len = sizeof(*optval);
+	if (getsockopt(listen_fd, SOL_SOCKET, SO_PASSCRED, optval, len))
+		perror_msg_and_fail("getsockopt");
+	printf("getsockopt(%d<UNIX:[%lu,\"%s\"]>, SOL_SOCKET, SO_PASSCRED"
+	       ", [%u], [%u]) = 0\n",
+	       listen_fd, listen_inode, av[1], *optval, (unsigned) *len);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getsockname(listen_fd, listen_sa, len))
+		perror_msg_and_fail("getsockname");
+	printf("getsockname(%d<UNIX:[%lu,\"%s\"]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n", listen_fd, listen_inode,
+	       av[1], av[1], (int) sizeof(addr), (int) *len);
+
+	int connect_fd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (connect_fd < 0)
+		perror_msg_and_fail("socket");
+	unsigned long connect_inode = inode_of_sockfd(connect_fd);
+	printf("socket(AF_UNIX, SOCK_STREAM, 0) = %d<UNIX:[%lu]>\n",
+	       connect_fd, connect_inode);
+
+	if (connect(connect_fd, listen_sa, *len))
+		perror_msg_and_fail("connect");
+	printf("connect(%d<UNIX:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, %u) = 0\n",
+	       connect_fd, connect_inode, av[1], (unsigned) *len);
+
+	struct sockaddr * const accept_sa = tail_alloc(sizeof(addr));
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	int accept_fd = accept(listen_fd, accept_sa, len);
+	if (accept_fd < 0)
+		perror_msg_and_fail("accept");
+	unsigned long accept_inode = inode_of_sockfd(accept_fd);
+	printf("accept(%d<UNIX:[%lu,\"%s\"]>, {sa_family=AF_UNIX}"
+	       ", [%d->%d]) = %d<UNIX:[%lu->%lu,\"%s\"]>\n",
+	       listen_fd, listen_inode, av[1], (int) sizeof(addr), (int) *len,
+	       accept_fd, accept_inode, connect_inode, av[1]);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getpeername(connect_fd, listen_sa, len))
+		perror_msg_and_fail("getpeername");
+	printf("getpeername(%d<UNIX:[%lu->%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n",
+	       connect_fd, connect_inode,
+	       accept_inode, av[1], (int) sizeof(addr), (int) *len);
+
+	char text[] = "text";
+	assert(sendto(connect_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, 0)
+	       == sizeof(text) - 1);
+	printf("sendto(%d<UNIX:[%lu->%lu]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, 0) = %u\n",
+	       connect_fd, connect_inode, accept_inode, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(recvfrom(accept_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, NULL)
+	       == sizeof(text) - 1);
+	printf("recvfrom(%d<UNIX:[%lu->%lu,\"%s\"]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, NULL) = %u\n",
+	       accept_fd, accept_inode, connect_inode, av[1], text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(connect_fd) == 0);
+	printf("close(%d<UNIX:[%lu->%lu]>) = 0\n",
+	       connect_fd, connect_inode, accept_inode);
+
+	assert(close(accept_fd) == 0);
+	printf("close(%d<UNIX:[%lu->%lu,\"%s\"]>) = 0\n",
+	       accept_fd, accept_inode, connect_inode, av[1]);
+
+	connect_fd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (connect_fd < 0)
+		perror_msg_and_fail("socket");
+	connect_inode = inode_of_sockfd(connect_fd);
+	printf("socket(AF_UNIX, SOCK_STREAM, 0) = %d<UNIX:[%lu]>\n",
+	       connect_fd, connect_inode);
+
+	*optval = 1;
+	*len = sizeof(*optval);
+	if (setsockopt(connect_fd, SOL_SOCKET, SO_PASSCRED, optval, *len))
+		perror_msg_and_fail("setsockopt");
+	printf("setsockopt(%d<UNIX:[%lu]>, SOL_SOCKET, SO_PASSCRED"
+	       ", [%u], %u) = 0\n",
+	       connect_fd, connect_inode, *optval, (unsigned) *len);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getsockname(listen_fd, listen_sa, len))
+		perror_msg_and_fail("getsockname");
+	printf("getsockname(%d<UNIX:[%lu,\"%s\"]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n", listen_fd, listen_inode,
+	       av[1], av[1], (int) sizeof(addr), (int) *len);
+
+	if (connect(connect_fd, listen_sa, *len))
+		perror_msg_and_fail("connect");
+	printf("connect(%d<UNIX:[%lu]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, %u) = 0\n",
+	       connect_fd, connect_inode, av[1], (unsigned) *len);
+
+	memset(accept_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	accept_fd = accept(listen_fd, accept_sa, len);
+	if (accept_fd < 0)
+		perror_msg_and_fail("accept");
+	accept_inode = inode_of_sockfd(accept_fd);
+	const char * const sun_path1 =
+		((struct sockaddr_un *) accept_sa) -> sun_path + 1;
+	printf("accept(%d<UNIX:[%lu,\"%s\"]>, {sa_family=AF_UNIX"
+	       ", sun_path=@\"%s\"}, [%d->%d]) = %d<UNIX:[%lu->%lu,\"%s\"]>\n",
+	       listen_fd, listen_inode, av[1], sun_path1,
+	       (int) sizeof(addr), (int) *len,
+	       accept_fd, accept_inode, connect_inode, av[1]);
+
+	memset(listen_sa, 0, sizeof(addr));
+	*len = sizeof(addr);
+	if (getpeername(connect_fd, listen_sa, len))
+		perror_msg_and_fail("getpeername");
+	printf("getpeername(%d<UNIX:[%lu->%lu,@\"%s\"]>, {sa_family=AF_UNIX"
+	       ", sun_path=\"%s\"}, [%d->%d]) = 0\n", connect_fd, connect_inode,
+	       accept_inode, sun_path1, av[1], (int) sizeof(addr), (int) *len);
+
+	assert(sendto(connect_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, 0)
+	       == sizeof(text) - 1);
+	printf("sendto(%d<UNIX:[%lu->%lu,@\"%s\"]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, 0) = %u\n",
+	       connect_fd, connect_inode, accept_inode, sun_path1, text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(recvfrom(accept_fd, text, sizeof(text) - 1, MSG_DONTWAIT, NULL, NULL)
+	       == sizeof(text) - 1);
+	printf("recvfrom(%d<UNIX:[%lu->%lu,\"%s\"]>, \"%s\", %u, MSG_DONTWAIT"
+	       ", NULL, NULL) = %u\n",
+	       accept_fd, accept_inode, connect_inode, av[1], text,
+	       (unsigned) sizeof(text) - 1, (unsigned) sizeof(text) - 1);
+
+	assert(close(connect_fd) == 0);
+	printf("close(%d<UNIX:[%lu->%lu,@\"%s\"]>) = 0\n",
+	       connect_fd, connect_inode, accept_inode, sun_path1);
+
+	assert(close(accept_fd) == 0);
+	printf("close(%d<UNIX:[%lu->%lu,\"%s\"]>) = 0\n",
+	       accept_fd, accept_inode, connect_inode, av[1]);
+
+	assert(unlink(av[1]) == 0);
+
+	assert(close(listen_fd) == 0);
+	printf("close(%d<UNIX:[%lu,\"%s\"]>) = 0\n",
+	       listen_fd, listen_inode, av[1]);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/net-yy-unix.test b/strace/tests/net-yy-unix.test
new file mode 100755
index 0000000..b82761c
--- /dev/null
+++ b/strace/tests/net-yy-unix.test
@@ -0,0 +1,49 @@
+#!/bin/sh
+#
+# Check decoding of address information (inode[->peer][,path])
+# associated with unix domain socket descriptors.
+#
+# Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+# Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -yy is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+check_prog sed
+run_prog ./netlink_unix_diag
+
+addr="$NAME-local-stream"
+run_prog "./$NAME" $addr > /dev/null
+
+run_strace -a22 -yy -eclose,network $args > "$EXP"
+# Filter out close() calls made by ld.so and libc.
+sed -n '/socket/,$p' < "$LOG" > "$OUT"
+
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/net.expected b/strace/tests/net.expected
new file mode 100644
index 0000000..80dd070
--- /dev/null
+++ b/strace/tests/net.expected
@@ -0,0 +1,7 @@
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +socket\(AF_(LOCAL|UNIX|FILE), SOCK_STREAM, 0\) += 0
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +socket\(AF_(LOCAL|UNIX|FILE), SOCK_STREAM, 0\) += 1
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +bind\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="net-local-stream"\}, 19\) += 0
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +listen\(0, 5\) += 0
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +getsockname\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="net-local-stream"\}, \[19\]\) += 0
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +accept\(0, \{sa_family=AF_(LOCAL|UNIX|FILE)\}, \[19->2\]\) += 1
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +connect\(1, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="net-local-stream"\}, 19\) += 0
diff --git a/strace/tests/net.test b/strace/tests/net.test
new file mode 100755
index 0000000..cf943ff
--- /dev/null
+++ b/strace/tests/net.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check how network syscalls are traced.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./net-accept-connect net-local-stream
+run_strace_merge -enetwork $args
+match_grep
+
+exit 0
diff --git a/strace/tests/netlink_inet_diag.c b/strace/tests/netlink_inet_diag.c
new file mode 100644
index 0000000..2332e20
--- /dev/null
+++ b/strace/tests/netlink_inet_diag.c
@@ -0,0 +1,144 @@
+/*
+ * This file is part of inet-yy strace test.
+ *
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <string.h>
+#include <unistd.h>
+#include <netinet/in.h>
+#include <linux/netlink.h>
+#include <linux/sock_diag.h>
+#include <linux/inet_diag.h>
+
+static void
+send_query(const int fd, const int family, const int proto)
+{
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct {
+		struct nlmsghdr nlh;
+		struct inet_diag_req_v2 idr;
+	} req = {
+		.nlh = {
+			.nlmsg_len = sizeof(req),
+			.nlmsg_type = SOCK_DIAG_BY_FAMILY,
+			.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
+		},
+		.idr = {
+			.sdiag_family = family,
+			.sdiag_protocol = proto,
+			.idiag_states = -1
+		}
+	};
+	struct iovec iov = {
+		.iov_base = &req,
+		.iov_len = sizeof(req)
+	};
+	struct msghdr msg = {
+		.msg_name = (void *) &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	if (sendmsg(fd, &msg, 0) <= 0)
+		perror_msg_and_skip("sendmsg");
+}
+
+static void
+check_responses(const int fd)
+{
+	static union {
+		struct nlmsghdr hdr;
+		long buf[8192 / sizeof(long)];
+	} hdr_buf;
+
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct iovec iov = {
+		.iov_base = hdr_buf.buf,
+		.iov_len = sizeof(hdr_buf.buf)
+	};
+	struct msghdr msg = {
+		.msg_name = (void *) &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	ssize_t ret = recvmsg(fd, &msg, 0);
+	if (ret <= 0)
+		perror_msg_and_skip("recvmsg");
+
+	struct nlmsghdr *h = &hdr_buf.hdr;
+	if (!NLMSG_OK(h, ret))
+		error_msg_and_skip("!NLMSG_OK");
+	if (h->nlmsg_type == NLMSG_ERROR) {
+		const struct nlmsgerr *err = NLMSG_DATA(h);
+		if (h->nlmsg_len < NLMSG_LENGTH(sizeof(*err)))
+			error_msg_and_skip("NLMSG_ERROR");
+		errno = -err->error;
+		perror_msg_and_skip("NLMSG_ERROR");
+	}
+	if (h->nlmsg_type != SOCK_DIAG_BY_FAMILY)
+		error_msg_and_skip("unexpected nlmsg_type %u",
+				   (unsigned) h->nlmsg_type);
+
+	const struct inet_diag_msg *diag = NLMSG_DATA(h);
+	if (h->nlmsg_len < NLMSG_LENGTH(sizeof(*diag)))
+		error_msg_and_skip("short response");
+}
+
+int main(void)
+{
+	struct sockaddr_in addr;
+	socklen_t len = sizeof(addr);
+
+	memset(&addr, 0, sizeof(addr));
+	addr.sin_family = AF_INET;
+	addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK);
+
+	close(0);
+	close(1);
+
+	if (socket(AF_INET, SOCK_STREAM, 0))
+		perror_msg_and_skip("socket AF_INET");
+	if (bind(0, (struct sockaddr *) &addr, len))
+		perror_msg_and_skip("bind");
+	if (listen(0, 5))
+		perror_msg_and_skip("listen");
+	if (socket(AF_NETLINK, SOCK_RAW, NETLINK_INET_DIAG) != 1)
+		perror_msg_and_skip("socket AF_NETLINK");
+
+	send_query(1, AF_INET, IPPROTO_TCP);
+	check_responses(1);
+	return 0;
+}
diff --git a/strace/tests/netlink_netlink_diag.c b/strace/tests/netlink_netlink_diag.c
new file mode 100644
index 0000000..fc32822
--- /dev/null
+++ b/strace/tests/netlink_netlink_diag.c
@@ -0,0 +1,147 @@
+/*
+ * This file is part of net-yy-netlink strace test.
+ *
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2016 Fabien Siron <fabien.siron@epita.fr>
+ * 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 "tests.h"
+#include <errno.h>
+#include <string.h>
+#include <unistd.h>
+#include <netinet/in.h>
+#include <linux/netlink.h>
+#include <linux/sock_diag.h>
+#include <linux/netlink_diag.h>
+
+#if !defined NETLINK_SOCK_DIAG && defined NETLINK_INET_DIAG
+# define NETLINK_SOCK_DIAG NETLINK_INET_DIAG
+#endif
+
+static void
+send_query(const int fd)
+{
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct {
+		struct nlmsghdr nlh;
+		struct netlink_diag_req ndr;
+	} req = {
+		.nlh = {
+			.nlmsg_len = sizeof(req),
+			.nlmsg_type = SOCK_DIAG_BY_FAMILY,
+			.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
+		},
+		.ndr = {
+			.sdiag_family = AF_NETLINK,
+			.sdiag_protocol = NDIAG_PROTO_ALL,
+			.ndiag_show = NDIAG_SHOW_MEMINFO
+		}
+	};
+	struct iovec iov = {
+		.iov_base = &req,
+		.iov_len = sizeof(req)
+	};
+	struct msghdr msg = {
+		.msg_name = (void *) &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	if (sendmsg(fd, &msg, 0) <= 0)
+		perror_msg_and_skip("sendmsg");
+}
+
+static void
+check_responses(const int fd)
+{
+	static union {
+		struct nlmsghdr hdr;
+		long buf[8192 / sizeof(long)];
+	} hdr_buf;
+
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct iovec iov = {
+		.iov_base = hdr_buf.buf,
+		.iov_len = sizeof(hdr_buf.buf)
+	};
+	struct msghdr msg = {
+		.msg_name = (void *) &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	ssize_t ret = recvmsg(fd, &msg, 0);
+	if (ret <= 0)
+		perror_msg_and_skip("recvmsg");
+
+	struct nlmsghdr *h = &hdr_buf.hdr;
+	if (!NLMSG_OK(h, ret))
+		error_msg_and_skip("!NLMSG_OK");
+	if (h->nlmsg_type == NLMSG_ERROR) {
+		const struct nlmsgerr *err = NLMSG_DATA(h);
+		if (h->nlmsg_len < NLMSG_LENGTH(sizeof(*err)))
+			error_msg_and_skip("NLMSG_ERROR");
+		errno = -err->error;
+		perror_msg_and_skip("NLMSG_ERROR");
+	}
+	if (h->nlmsg_type != SOCK_DIAG_BY_FAMILY)
+		error_msg_and_skip("unexpected nlmsg_type %u",
+				   (unsigned) h->nlmsg_type);
+
+	const struct netlink_diag_msg *diag = NLMSG_DATA(h);
+	if (h->nlmsg_len < NLMSG_LENGTH(sizeof(*diag)))
+		error_msg_and_skip("short response");
+}
+
+int main(void)
+{
+	struct sockaddr_nl addr;
+	socklen_t len = sizeof(addr);
+
+	memset(&addr, 0, sizeof(addr));
+	addr.nl_family = AF_NETLINK;
+
+	close(0);
+	close(1);
+
+	if (socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG))
+		perror_msg_and_skip("socket AF_NETLINK");
+	if (bind(0, (struct sockaddr *) &addr, len))
+		perror_msg_and_skip("bind");
+
+	if (socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG) != 1)
+		perror_msg_and_skip("socket AF_NETLINK");
+
+	send_query(1);
+	check_responses(1);
+	return 0;
+}
diff --git a/strace/tests/netlink_protocol.c b/strace/tests/netlink_protocol.c
new file mode 100644
index 0000000..aee9a87
--- /dev/null
+++ b/strace/tests/netlink_protocol.c
@@ -0,0 +1,265 @@
+/*
+ * Check decoding of netlink protocol.
+ *
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2016 Fabien Siron <fabien.siron@epita.fr>
+ * 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 "tests.h"
+
+#ifdef HAVE_SYS_XATTR_H
+
+# include <stdio.h>
+# include <stdlib.h>
+# include <string.h>
+# include <unistd.h>
+# include <sys/xattr.h>
+# include <netinet/in.h>
+# include <linux/netlink.h>
+# include <linux/sock_diag.h>
+# include <linux/netlink_diag.h>
+
+# if !defined NETLINK_SOCK_DIAG && defined NETLINK_INET_DIAG
+#  define NETLINK_SOCK_DIAG NETLINK_INET_DIAG
+# endif
+
+static void
+send_query(const int fd)
+{
+	static const struct req {
+		struct nlmsghdr nlh;
+		const char magic[4];
+	} c_req = {
+		.nlh = {
+			.nlmsg_len = sizeof(struct req),
+			.nlmsg_type = NLMSG_NOOP,
+			.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST
+		},
+		.magic = "abcd"
+	};
+	struct req *const req = tail_memdup(&c_req, sizeof(c_req));
+
+	/* zero address */
+	if (sendto(fd, NULL, sizeof(*req), MSG_DONTWAIT, NULL, 0) != -1)
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, NULL, %u, MSG_DONTWAIT, NULL, 0) = -1 %s (%m)\n",
+	       fd, (unsigned) sizeof(*req), errno2name());
+
+	/* zero length */
+	if (sendto(fd, req, 0, MSG_DONTWAIT, NULL, 0) != 0)
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, \"\", 0, MSG_DONTWAIT, NULL, 0) = 0\n", fd);
+
+	/* zero address and length */
+	if (sendto(fd, NULL, 0, MSG_DONTWAIT, NULL, 0) != 0)
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, NULL, 0, MSG_DONTWAIT, NULL, 0) = 0\n", fd);
+
+	/* unfetchable struct nlmsghdr */
+	const void *const efault = tail_alloc(sizeof(struct nlmsghdr) - 1);
+	sendto(fd, efault, sizeof(struct nlmsghdr), MSG_DONTWAIT, NULL, 0);
+
+	printf("sendto(%d, %p, %u, MSG_DONTWAIT, NULL, 0) = -1 EFAULT (%m)\n",
+	       fd, efault, (unsigned) sizeof(struct nlmsghdr));
+
+	/* whole message length < sizeof(struct nlmsghdr) */
+	if (sendto(fd, req->magic, sizeof(req->magic), MSG_DONTWAIT, NULL, 0)
+	    != (unsigned) sizeof(req->magic))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, \"abcd\", %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, (unsigned) sizeof(req->magic), (unsigned) sizeof(req->magic));
+
+	/* a single message with some data */
+	if (sendto(fd, req, sizeof(*req), MSG_DONTWAIT, NULL, 0) !=
+	    (unsigned) sizeof(*req))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, {{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}, \"abcd\"}, %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, req->nlh.nlmsg_len, NLM_F_DUMP,
+	       (unsigned) sizeof(*req), (unsigned) sizeof(*req));
+
+	/* a single message without data */
+	req->nlh.nlmsg_len = sizeof(req->nlh);
+
+	if (sendto(fd, &req->nlh, sizeof(req->nlh), MSG_DONTWAIT, NULL, 0)
+	    != (unsigned) sizeof(req->nlh))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, {{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}}, %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, req->nlh.nlmsg_len, NLM_F_DUMP,
+	       (unsigned) sizeof(req->nlh), (unsigned) sizeof(req->nlh));
+
+	/* nlmsg_len > whole message length */
+	req->nlh.nlmsg_len = sizeof(*req) + 8;
+	if (sendto(fd, req, sizeof(*req), MSG_DONTWAIT, NULL, 0) !=
+	    (unsigned) sizeof(*req))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, {{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}, \"abcd\"}, %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, req->nlh.nlmsg_len, NLM_F_DUMP,
+	       (unsigned) sizeof(*req), (unsigned) sizeof(*req));
+
+	/* nlmsg_len < sizeof(struct nlmsghdr) */
+	req->nlh.nlmsg_len = 8;
+	if (sendto(fd, req, sizeof(*req), MSG_DONTWAIT, NULL, 0) != sizeof(*req))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, {{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}}, %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, req->nlh.nlmsg_len, NLM_F_DUMP,
+	       (unsigned) sizeof(*req), (unsigned) sizeof(*req));
+
+	/* a sequence of two nlmsg objects */
+	struct reqs {
+		struct req req1;
+		char padding[NLMSG_ALIGN(sizeof(struct req)) - sizeof(struct req)];
+		struct req req2;
+	} *const reqs = tail_alloc(sizeof(*reqs));
+	memcpy(&reqs->req1, &c_req, sizeof(c_req));
+	memcpy(&reqs->req2, &c_req, sizeof(c_req));
+
+	sendto(fd, reqs, sizeof(*reqs), MSG_DONTWAIT, NULL, 0);
+
+	printf("sendto(%d, [{{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}, \"abcd\"}, {{len=%u, type=NLMSG_NOOP"
+	       ", flags=NLM_F_REQUEST|0x%x, seq=0, pid=0}, \"abcd\"}]"
+	       ", %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, reqs->req1.nlh.nlmsg_len, NLM_F_DUMP,
+	       reqs->req2.nlh.nlmsg_len, NLM_F_DUMP,
+	       (unsigned) sizeof(*reqs), (unsigned) sizeof(*reqs));
+
+	/* unfetchable second struct nlmsghdr */
+	void *const efault2 = tail_memdup(&reqs->req1, sizeof(reqs->req1));
+	sendto(fd, efault2, sizeof(*reqs), MSG_DONTWAIT, NULL, 0);
+
+	printf("sendto(%d, [{{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}, \"abcd\"}, %p], %u, MSG_DONTWAIT, NULL, 0)"
+	       " = -1 EFAULT (%m)\n",
+	       fd, reqs->req1.nlh.nlmsg_len, NLM_F_DUMP,
+	       &((struct reqs *) efault2)->req2, (unsigned) sizeof(*reqs));
+
+	/* message length is not enough for the second struct nlmsghdr */
+	if (sendto(fd, reqs, sizeof(*reqs) - sizeof(req->nlh), MSG_DONTWAIT, NULL, 0)
+	    != sizeof(*reqs) - sizeof(req->nlh))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, [{{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}, \"abcd\"}, \"",
+	       fd, reqs->req1.nlh.nlmsg_len, NLM_F_DUMP);
+	print_quoted_memory((void *) &reqs->req2.nlh,
+			    sizeof(reqs->req2) - sizeof(req->nlh));
+	printf("\"], %u, MSG_DONTWAIT, NULL, 0) = %u\n",
+	       (unsigned) (sizeof(*reqs) - sizeof(req->nlh)),
+	       (unsigned) (sizeof(*reqs) - sizeof(req->nlh)));
+
+	/* second nlmsg_len < sizeof(struct nlmsghdr) */
+	reqs->req2.nlh.nlmsg_len = 4;
+	if (sendto(fd, reqs, sizeof(*reqs), MSG_DONTWAIT, NULL, 0)
+	    != sizeof(*reqs))
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, [{{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+	       ", seq=0, pid=0}, \"abcd\"}, {{len=%u, type=NLMSG_NOOP"
+	       ", flags=NLM_F_REQUEST|0x%x, seq=0, pid=0}}], %u"
+	       ", MSG_DONTWAIT, NULL, 0) = %u\n",
+	       fd, reqs->req1.nlh.nlmsg_len, NLM_F_DUMP,
+	       reqs->req2.nlh.nlmsg_len, NLM_F_DUMP,
+	       (unsigned) sizeof(*reqs), (unsigned) sizeof(*reqs));
+
+	/* abbreviated output */
+# define DEFAULT_STRLEN 32
+# define ABBREV_LEN (DEFAULT_STRLEN + 1)
+	const unsigned int msg_len = sizeof(struct nlmsghdr) * ABBREV_LEN;
+	struct nlmsghdr *const msgs = tail_alloc(msg_len);
+	unsigned int i;
+	for (i = 0; i < ABBREV_LEN; ++i) {
+		msgs[i].nlmsg_len = sizeof(*msgs);
+		msgs[i].nlmsg_type = NLMSG_NOOP;
+		msgs[i].nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST;
+		msgs[i].nlmsg_seq = i;
+		msgs[i].nlmsg_pid = 0;
+	}
+
+	if (sendto(fd, msgs, msg_len, MSG_DONTWAIT, NULL, 0) != (int) msg_len)
+		perror_msg_and_skip("sendto");
+
+	printf("sendto(%d, [", fd);
+	for (i = 0; i < DEFAULT_STRLEN; ++i) {
+		if (i)
+			printf(", ");
+		printf("{{len=%u, type=NLMSG_NOOP, flags=NLM_F_REQUEST|0x%x"
+		       ", seq=%u, pid=0}}",
+		       msgs[i].nlmsg_len, NLM_F_DUMP, msgs[i].nlmsg_seq);
+	}
+	printf(", ...], %u, MSG_DONTWAIT, NULL, 0) = %u\n", msg_len, msg_len);
+}
+
+int main(void)
+{
+	struct sockaddr_nl addr;
+	socklen_t len = sizeof(addr);
+	int fd;
+
+	memset(&addr, 0, sizeof(addr));
+	addr.nl_family = AF_NETLINK;
+
+	if ((fd = socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG)) == -1)
+		perror_msg_and_skip("socket AF_NETLINK");
+
+	printf("socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG) = %d\n",
+	       fd);
+	if (bind(fd, (struct sockaddr *) &addr, len))
+		perror_msg_and_skip("bind");
+	printf("bind(%d, {sa_family=AF_NETLINK, nl_pid=0, nl_groups=00000000}"
+	       ", %u) = 0\n", fd, len);
+
+	char *path;
+	if (asprintf(&path, "/proc/self/fd/%u", fd) < 0)
+		perror_msg_and_fail("asprintf");
+	char buf[256];
+	if (getxattr(path, "system.sockprotoname", buf, sizeof(buf) - 1) < 0)
+		perror_msg_and_skip("getxattr");
+	free(path);
+
+	send_query(fd);
+
+	printf("+++ exited with 0 +++\n");
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_SYS_XATTR_H")
+
+#endif
diff --git a/strace/tests/netlink_protocol.test b/strace/tests/netlink_protocol.test
new file mode 100755
index 0000000..ab2bb1e
--- /dev/null
+++ b/strace/tests/netlink_protocol.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check decoding of netlink protocol.
+
+. "${srcdir=.}/init.sh"
+
+# getfdproto is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+    framework_skip_ '/proc/self/fd/ is not available'
+
+run_strace_match_diff -e trace=network
diff --git a/strace/tests/netlink_unix_diag.c b/strace/tests/netlink_unix_diag.c
new file mode 100644
index 0000000..269adc6
--- /dev/null
+++ b/strace/tests/netlink_unix_diag.c
@@ -0,0 +1,156 @@
+/*
+ * This file is part of net-yy-unix strace test.
+ *
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <errno.h>
+#include <stddef.h>
+#include <stdint.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+#include <linux/netlink.h>
+#include <linux/sock_diag.h>
+#include <linux/unix_diag.h>
+
+#if !defined NETLINK_SOCK_DIAG && defined NETLINK_INET_DIAG
+# define NETLINK_SOCK_DIAG NETLINK_INET_DIAG
+#endif
+
+static void
+send_query(const int fd)
+{
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct {
+		struct nlmsghdr nlh;
+		struct unix_diag_req udr;
+	} req = {
+		.nlh = {
+			.nlmsg_len = sizeof(req),
+			.nlmsg_type = SOCK_DIAG_BY_FAMILY,
+			.nlmsg_flags = NLM_F_REQUEST | NLM_F_DUMP
+		},
+		.udr = {
+			.sdiag_family = AF_UNIX,
+			.udiag_states = -1,
+			.udiag_show = UDIAG_SHOW_NAME | UDIAG_SHOW_PEER
+		}
+	};
+	struct iovec iov = {
+		.iov_base = &req,
+		.iov_len = sizeof(req)
+	};
+	struct msghdr msg = {
+		.msg_name = (void *) &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	if (sendmsg(fd, &msg, 0) <= 0)
+		perror_msg_and_skip("sendmsg");
+}
+
+static void
+check_responses(const int fd)
+{
+	static union {
+		struct nlmsghdr hdr;
+		long buf[8192 / sizeof(long)];
+	} hdr_buf;
+
+	struct sockaddr_nl nladdr = {
+		.nl_family = AF_NETLINK
+	};
+	struct iovec iov = {
+		.iov_base = hdr_buf.buf,
+		.iov_len = sizeof(hdr_buf.buf)
+	};
+	struct msghdr msg = {
+		.msg_name = (void *) &nladdr,
+		.msg_namelen = sizeof(nladdr),
+		.msg_iov = &iov,
+		.msg_iovlen = 1
+	};
+
+	ssize_t ret = recvmsg(fd, &msg, 0);
+	if (ret <= 0)
+		perror_msg_and_skip("recvmsg");
+
+	struct nlmsghdr *h = &hdr_buf.hdr;
+	if (!NLMSG_OK(h, ret))
+		error_msg_and_skip("!NLMSG_OK");
+	if (h->nlmsg_type == NLMSG_ERROR) {
+		const struct nlmsgerr *err = NLMSG_DATA(h);
+		if (h->nlmsg_len < NLMSG_LENGTH(sizeof(*err)))
+			error_msg_and_skip("NLMSG_ERROR");
+		errno = -err->error;
+		perror_msg_and_skip("NLMSG_ERROR");
+	}
+	if (h->nlmsg_type != SOCK_DIAG_BY_FAMILY)
+		error_msg_and_skip("unexpected nlmsg_type %u",
+				   (unsigned) h->nlmsg_type);
+
+	const struct unix_diag_msg *diag = NLMSG_DATA(h);
+	if (h->nlmsg_len < NLMSG_LENGTH(sizeof(*diag)))
+		error_msg_and_skip("short response");
+}
+
+#define SUN_PATH "netlink_unix_diag_socket"
+int main(void)
+{
+	struct sockaddr_un addr = {
+		.sun_family = AF_UNIX,
+		.sun_path = SUN_PATH
+	};
+	socklen_t len = offsetof(struct sockaddr_un, sun_path) + sizeof(SUN_PATH);
+
+	close(0);
+	close(1);
+
+	(void) unlink(SUN_PATH);
+	if (socket(AF_UNIX, SOCK_STREAM, 0))
+		perror_msg_and_skip("socket AF_UNIX");
+	if (bind(0, (struct sockaddr *) &addr, len))
+		perror_msg_and_skip("bind");
+	if (listen(0, 5))
+		perror_msg_and_skip("listen");
+
+	assert(unlink(SUN_PATH) == 0);
+
+	if (socket(AF_NETLINK, SOCK_RAW, NETLINK_SOCK_DIAG) != 1)
+		perror_msg_and_skip("socket AF_NETLINK");
+
+	send_query(1);
+	check_responses(1);
+	return 0;
+}
diff --git a/strace/tests/newfstatat.c b/strace/tests/newfstatat.c
new file mode 100644
index 0000000..6fb34db
--- /dev/null
+++ b/strace/tests/newfstatat.c
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_newfstatat
+
+# define TEST_SYSCALL_NR __NR_newfstatat
+# define TEST_SYSCALL_STR "newfstatat"
+# include "fstatat.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_newfstatat")
+
+#endif
diff --git a/strace/tests/newfstatat.test b/strace/tests/newfstatat.test
new file mode 100755
index 0000000..6d83ec0
--- /dev/null
+++ b/strace/tests/newfstatat.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check newfstatat syscall decoding.
+
+. "${srcdir=.}/statx.sh"
diff --git a/strace/tests/nsyscalls.c b/strace/tests/nsyscalls.c
new file mode 100644
index 0000000..c9c92c4
--- /dev/null
+++ b/strace/tests/nsyscalls.c
@@ -0,0 +1,93 @@
+/*
+ * Check decoding of out-of-range syscalls.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "kernel_types.h"
+#include "syscall.h"
+
+#define TD 0
+#define TF 0
+#define TI 0
+#define TN 0
+#define TP 0
+#define TS 0
+#define TM 0
+#define NF 0
+#define MA 0
+#define SI 0
+#define SE 0
+#define SEN(arg) 0,0
+
+static const struct_sysent syscallent[] = {
+#include "syscallent.h"
+};
+
+#include <sys/syscall.h>
+
+#if defined __X32_SYSCALL_BIT && defined __NR_read \
+ && (__X32_SYSCALL_BIT & __NR_read) != 0
+# define SYSCALL_BIT __X32_SYSCALL_BIT
+#else
+# define SYSCALL_BIT 0
+#endif
+
+static const unsigned long nr = ARRAY_SIZE(syscallent) | SYSCALL_BIT;
+
+int
+main(void)
+{
+	static const kernel_ulong_t a[] = {
+		(kernel_ulong_t) 0xface0fedbadc0ded,
+		(kernel_ulong_t) 0xface1fedbadc1ded,
+		(kernel_ulong_t) 0xface2fedbadc2ded,
+		(kernel_ulong_t) 0xface3fedbadc3ded,
+		(kernel_ulong_t) 0xface4fedbadc4ded,
+		(kernel_ulong_t) 0xface5fedbadc5ded
+	};
+
+	long rc = syscall(nr, a[0], a[1], a[2], a[3], a[4], a[5]);
+#ifdef LINUX_MIPSO32
+	printf("syscall(%#lx, %#lx, %#lx, %#lx, %#lx, %#lx, %#lx)"
+	       " = %ld ENOSYS (%m)\n", nr,
+	       a[0], a[1], a[2], a[3], a[4], a[5], rc);
+#else
+	printf("syscall_%lu(%#llx, %#llx, %#llx, %#llx, %#llx, %#llx)"
+	       " = %ld (errno %d)\n", nr & (~SYSCALL_BIT),
+	       (unsigned long long) a[0],
+	       (unsigned long long) a[1],
+	       (unsigned long long) a[2],
+	       (unsigned long long) a[3],
+	       (unsigned long long) a[4],
+	       (unsigned long long) a[5],
+	       rc, errno);
+#endif
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/nsyscalls.test b/strace/tests/nsyscalls.test
new file mode 100755
index 0000000..3760831
--- /dev/null
+++ b/strace/tests/nsyscalls.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check decoding of out-of-range syscalls.
+
+. "${srcdir=.}/init.sh"
+
+case "$STRACE_ARCH" in
+	mips) syscall=syscall ;;
+	*) syscall=none ;;
+esac
+
+run_strace_match_diff -e trace=$syscall
diff --git a/strace/tests/old_mmap.c b/strace/tests/old_mmap.c
new file mode 100644
index 0000000..97051db
--- /dev/null
+++ b/strace/tests/old_mmap.c
@@ -0,0 +1,102 @@
+/*
+ * Check decoding of "old mmap" edition of mmap syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+/*
+ * On s390x, this is the mmap syscall used by glibc, so,
+ * from one side, it's already covered by another test, and, from another side,
+ * it would require additional efforts to filter out mmap calls made by glibc.
+ */
+
+#if defined __NR_mmap && \
+(   defined __arm__ \
+ || defined __i386__ \
+ || defined __m68k__ \
+ || (defined __s390__ && !defined __s390x__) \
+)
+
+# include <stdio.h>
+# include <string.h>
+# include <sys/mman.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_mmap, 0);
+	printf("mmap(NULL) = %ld %s (%m)\n", rc, errno2name());
+
+	const unsigned int args1_c[6] = {
+		0xdeadbeef,		/* addr */
+		0xfacefeed,		/* len */
+		PROT_READ|PROT_EXEC,	/* prot */
+		MAP_FILE|MAP_FIXED,	/* flags */
+		-2U,			/* fd */
+		0xbadc0ded		/* offset */
+	};
+	const unsigned int page_size = get_page_size();
+	const unsigned int args2_c[6] = {
+		0,
+		page_size,
+		PROT_READ|PROT_WRITE,
+		MAP_PRIVATE|MAP_ANONYMOUS,
+		-1U,
+		0xfaced000 & -page_size
+	};
+	void *args = tail_memdup(args1_c, sizeof(args1_c));
+
+	rc = syscall(__NR_mmap, args);
+	printf("mmap(%#x, %u, PROT_READ|PROT_EXEC, MAP_FILE|MAP_FIXED"
+	       ", %d, %#x) = %ld %s (%m)\n",
+	       args1_c[0], args1_c[1], args1_c[4], args1_c[5],
+	       rc, errno2name());
+
+	memcpy(args, args2_c, sizeof(args2_c));
+	rc = syscall(__NR_mmap, args);
+	printf("mmap(NULL, %u, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS"
+	       ", %d, %#x) = %#lx\n",
+	       args2_c[1], args2_c[4], args2_c[5], rc);
+
+	void *addr = (void *) rc;
+	if (mprotect(addr, page_size, PROT_NONE))
+		perror_msg_and_fail("mprotect(%p, %u, PROT_NONE)",
+				    addr, page_size);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_mmap && (__arm__ || __i386__ || __m68k__"
+		    " || (__s390__ && !__s390x__))")
+
+#endif
diff --git a/strace/tests/old_mmap.test b/strace/tests/old_mmap.test
new file mode 100755
index 0000000..af776ff
--- /dev/null
+++ b/strace/tests/old_mmap.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of "old mmap" edition of mmap syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a11 -e trace=mmap
diff --git a/strace/tests/oldselect.c b/strace/tests/oldselect.c
new file mode 100644
index 0000000..b8f265a
--- /dev/null
+++ b/strace/tests/oldselect.c
@@ -0,0 +1,66 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_select && defined __NR__newselect \
+ && __NR_select != __NR__newselect \
+ && !defined SPARC
+
+# include <unistd.h>
+# include <sys/select.h>
+
+int
+main(void)
+{
+	int fds[2];
+	fd_set r = {}, w = {};
+	struct timeval timeout = { .tv_sec = 0, .tv_usec = 42 };
+	long args[] = {
+		2, (long) &r, (long) &w, 0, (long) &timeout,
+		0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded, 0xdeadbeef
+	};
+
+	(void) close(0);
+	(void) close(1);
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	FD_SET(0, &w);
+	FD_SET(1, &r);
+	if (syscall(__NR_select, args))
+		perror_msg_and_skip("select");
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_select && __NR__newselect")
+
+#endif
diff --git a/strace/tests/oldselect.expected b/strace/tests/oldselect.expected
new file mode 100644
index 0000000..c0426f4
--- /dev/null
+++ b/strace/tests/oldselect.expected
@@ -0,0 +1,2 @@
+select(2, [1], [0], NULL, {0, 42}) = 0 (Timeout)
++++ exited with 0 +++
diff --git a/strace/tests/oldselect.test b/strace/tests/oldselect.test
new file mode 100755
index 0000000..35661ad
--- /dev/null
+++ b/strace/tests/oldselect.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check old select syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -a34 -eselect $args
+match_diff
+
+exit 0
diff --git a/strace/tests/open.c b/strace/tests/open.c
new file mode 100644
index 0000000..726b1ec
--- /dev/null
+++ b/strace/tests/open.c
@@ -0,0 +1,70 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_open
+
+# include <fcntl.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "open.sample";
+	int fd = syscall(__NR_open, sample, O_RDONLY|O_CREAT, 0400);
+
+	if (fd < 0) {
+		printf("open(\"%s\", O_RDONLY|O_CREAT, 0400)"
+		       " = %d %s (%m)\n", sample, fd, errno2name());
+	} else {
+		printf("open(\"%s\", O_RDONLY|O_CREAT, 0400) = %d\n",
+		       sample, fd);
+		close(fd);
+		if (unlink(sample))
+			perror_msg_and_fail("unlink");
+
+		fd = syscall(__NR_open, sample, O_RDONLY);
+		printf("open(\"%s\", O_RDONLY) = %d %s (%m)\n",
+		       sample, fd, errno2name());
+
+		fd = syscall(__NR_open, sample, O_WRONLY|O_NONBLOCK|0x80000000);
+		printf("open(\"%s\", O_WRONLY|O_NONBLOCK|0x80000000)"
+		       " = %d %s (%m)\n", sample, fd, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_open")
+
+#endif
diff --git a/strace/tests/open.test b/strace/tests/open.test
new file mode 100755
index 0000000..6df19cb
--- /dev/null
+++ b/strace/tests/open.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check open syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a30 -P $NAME.sample
diff --git a/strace/tests/openat.c b/strace/tests/openat.c
new file mode 100644
index 0000000..a3de1dd
--- /dev/null
+++ b/strace/tests/openat.c
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2016 Katerina Koukiou <k.koukiou@gmail.com>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_openat
+
+# include <fcntl.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "openat.sample";
+	int fd = syscall(__NR_openat, -100, sample, O_RDONLY|O_CREAT, 0400);
+	if (fd == -1) {
+		printf("openat(AT_FDCWD, \"%s\", O_RDONLY|O_CREAT, 0400)"
+		       " = -1 %s (%m)\n", sample, errno2name());
+	} else {
+		printf("openat(AT_FDCWD, \"%s\", O_RDONLY|O_CREAT, 0400)"
+		       " = %d\n", sample, fd);
+		close(fd);
+		if (unlink(sample) == -1)
+			perror_msg_and_fail("unlink");
+
+		fd = syscall(__NR_openat, -100, sample, O_RDONLY);
+		printf("openat(AT_FDCWD, \"%s\", O_RDONLY) = %d %s (%m)\n",
+		       sample, fd, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_openat")
+
+#endif
diff --git a/strace/tests/openat.test b/strace/tests/openat.test
new file mode 100755
index 0000000..68c4cee
--- /dev/null
+++ b/strace/tests/openat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check openat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -P $NAME.sample
diff --git a/strace/tests/opipe.test b/strace/tests/opipe.test
new file mode 100755
index 0000000..90e6838
--- /dev/null
+++ b/strace/tests/opipe.test
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+# Check how -o '|pipe' works.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog grep chdir $srcdir/umovestr.expected > "$EXP"
+run_prog ./umovestr
+
+> "$LOG" || fail_ "failed to write $LOG"
+$STRACE -o "|cat > $LOG && $SLEEP_A_BIT && grep chdir < $LOG > $OUT" -e chdir $args ||
+	dump_log_and_fail_with "$STRACE $args failed"
+
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/overflowuid.c b/strace/tests/overflowuid.c
new file mode 100644
index 0000000..a3c742b
--- /dev/null
+++ b/strace/tests/overflowuid.c
@@ -0,0 +1,95 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <errno.h>
+#include <fcntl.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+int
+read_int_from_file(const char *const fname, int *const pvalue)
+{
+	const int fd = open(fname, O_RDONLY);
+	if (fd < 0)
+		return -1;
+
+	long lval;
+	char buf[sizeof(lval) * 3];
+	int n = read(fd, buf, sizeof(buf) - 1);
+	int saved_errno = errno;
+	close(fd);
+
+	if (n < 0) {
+		errno = saved_errno;
+		return -1;
+	}
+
+	buf[n] = '\0';
+	char *endptr = 0;
+	errno = 0;
+	lval = strtol(buf, &endptr, 10);
+	if (!endptr || (*endptr && '\n' != *endptr)
+#if INT_MAX < LONG_MAX
+	    || lval > INT_MAX || lval < INT_MIN
+#endif
+	    || ERANGE == errno) {
+		if (!errno)
+			errno = EINVAL;
+		return -1;
+	}
+
+	*pvalue = (int) lval;
+	return 0;
+}
+
+static void
+check_overflow_id(const int id, const char *overflowid)
+{
+	int n;
+
+	if (read_int_from_file(overflowid, &n)) {
+		if (ENOENT == errno)
+			return;
+		perror_msg_and_fail("read_int_from_file: %s", overflowid);
+	}
+
+	if (id == n)
+		error_msg_and_skip("%d matches %s", id, overflowid);
+}
+
+void
+check_overflowuid(const int uid)
+{
+	check_overflow_id(uid, "/proc/sys/kernel/overflowuid");
+}
+
+void
+check_overflowgid(const int gid)
+{
+	check_overflow_id(gid, "/proc/sys/kernel/overflowgid");
+}
diff --git a/strace/tests/pause.c b/strace/tests/pause.c
new file mode 100644
index 0000000..6dadd15
--- /dev/null
+++ b/strace/tests/pause.c
@@ -0,0 +1,74 @@
+/*
+ * Check decoding of pause syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2016 Fei Jie <feij.fnst@cn.fujitsu.com>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_pause
+
+# include <signal.h>
+# include <stdio.h>
+# include <sys/time.h>
+# include <unistd.h>
+
+static void
+handler(int sig)
+{
+}
+
+int
+main(void)
+{
+	const struct sigaction act = { .sa_handler = handler };
+	if (sigaction(SIGALRM, &act, NULL))
+		perror_msg_and_fail("sigaction");
+
+	sigset_t mask;
+	sigemptyset(&mask);
+	sigaddset(&mask, SIGALRM);
+	if (sigprocmask(SIG_UNBLOCK, &mask, NULL))
+		perror_msg_and_fail("sigprocmask");
+
+	const struct itimerval itv = { .it_value.tv_usec = 123456 };
+	if (setitimer(ITIMER_REAL, &itv, NULL))
+		perror_msg_and_fail("setitimer");
+
+	pause();
+	printf("pause() = ? ERESTARTNOHAND (To be restarted if no handler)\n");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_pause")
+
+#endif
diff --git a/strace/tests/pause.test b/strace/tests/pause.test
new file mode 100755
index 0000000..c5fdacd
--- /dev/null
+++ b/strace/tests/pause.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of pause syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a8 -esignal=none
diff --git a/strace/tests/pc.c b/strace/tests/pc.c
new file mode 100644
index 0000000..f53acd4
--- /dev/null
+++ b/strace/tests/pc.c
@@ -0,0 +1,97 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <dlfcn.h>
+#include <fcntl.h>
+#include <unistd.h>
+#include <sys/mman.h>
+#include <sys/wait.h>
+#include <sys/sendfile.h>
+
+int main(void)
+{
+	const unsigned long pagesize = get_page_size();
+
+#ifdef __s390__
+	/*
+	 * The si_addr field is unreliable:
+	 * https://marc.info/?l=linux-s390&m=142515870124248&w=2
+	 */
+	error_msg_and_skip("s390: si_addr is unreliable");
+#endif
+
+	/* write instruction pointer length to the log */
+	assert(write(-1, NULL, 2 * sizeof(void *)) < 0);
+
+	/* just a noticeable line in the log */
+	assert(munmap(&main, 0) < 0);
+
+	int pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		const unsigned long mask = ~(pagesize - 1);
+		unsigned long addr = (unsigned long) &main & mask;
+		unsigned long size = pagesize << 1;
+
+#ifdef HAVE_DLADDR
+		Dl_info info;
+		if (dladdr(&main, &info)) {
+			const unsigned long base =
+				(unsigned long) info.dli_fbase & mask;
+			if (base < addr) {
+				size += addr - base;
+				addr = base;
+			}
+		} else
+#endif
+		{
+			addr -= size;
+			size <<= 1;
+		}
+
+		/* SIGSEGV is expected */
+		(void) munmap((void *) addr, size);
+		(void) munmap((void *) addr, size);
+		error_msg_and_skip("SIGSEGV did not happen");
+	}
+
+	int status;
+	assert(wait(&status) == pid);
+	assert(WIFSIGNALED(status));
+	assert(WTERMSIG(status) == SIGSEGV);
+
+	/* dump process map for debug purposes */
+	close(0);
+	if (!open("/proc/self/maps", O_RDONLY))
+		(void) sendfile(1, 0, NULL, pagesize);
+
+	return 0;
+}
diff --git a/strace/tests/pc.test b/strace/tests/pc.test
new file mode 100755
index 0000000..cc55878
--- /dev/null
+++ b/strace/tests/pc.test
@@ -0,0 +1,61 @@
+#!/bin/sh
+#
+# Check -i option.
+#
+# Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+check_prog sed
+
+run_prog > /dev/null
+
+args="-if $args"
+$STRACE $args 2> "$LOG" ||
+	dump_log_and_fail_with "$STRACE $args failed"
+
+len="$(sed -n 's/^\[[[:xdigit:]]\+\] write(-1, NULL, \([[:digit:]]\{1,2\}\))[[:space:]]\+= -1 .*/\1/p' "$LOG")" &&
+[ -n "$len" ] &&
+pid="$(sed -n 's/^\[[[:xdigit:]]\{'"$len"'\}\] --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_\(KILLED\|DUMPED\), si_pid=\([[:digit:]]\+\), .*/\2/p' "$LOG")" &&
+[ -n "$pid" ] &&
+ip="$(sed -n 's/^\[pid \+'"$pid"'\] \[\([[:xdigit:]]\{'"$len"'\}\)] --- SIGSEGV {.*} ---$/\1/p' "$LOG")" &&
+[ -n "$ip" ] &&
+addr="$(echo "$ip" |sed 's/^0\+//')" &&
+[ -n "$addr" ] ||
+	dump_log_and_fail_with
+
+EXPECTED="$LOG.expected"
+cat > "$EXPECTED" << __EOF__
+\\[[[:xdigit:]]{$len}\\] munmap\\(0x[[:xdigit:]]+, 0\\) += -1 .*
+\\[pid +$pid\\] \\[$ip\\] --- SIGSEGV \\{si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=0x$addr\\} ---
+\\[pid +$pid\\] \\[\\?{$len}\\] \\+\\+\\+ killed by SIGSEGV( \\(core dumped\\))? \\+\\+\\+
+\\[\\?{$len}\\] \\+\\+\\+ exited with 0 \\+\\+\\+
+__EOF__
+
+match_grep "$LOG" "$EXPECTED"
+rm -f "$EXPECTED"
+
+exit 0
diff --git a/strace/tests/personality.c b/strace/tests/personality.c
new file mode 100644
index 0000000..7a279a1
--- /dev/null
+++ b/strace/tests/personality.c
@@ -0,0 +1,118 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <stdio.h>
+#include <sys/personality.h>
+
+int main(void)
+{
+	const unsigned int good_type = PER_BSD;
+	const char *good_type_str = "PER_BSD";
+
+	const unsigned int bad_type = 0x1f;
+	const char *bad_type_str = "0x1f /\\* PER_\\?\\?\\? \\*/";
+
+	const unsigned int good_flags =
+		SHORT_INODE | WHOLE_SECONDS | STICKY_TIMEOUTS;
+	const char *good_flags_str =
+		"SHORT_INODE\\|WHOLE_SECONDS\\|STICKY_TIMEOUTS";
+
+	const unsigned int bad_flags = 0x10000;
+	const char *bad_flags_str = "0x10000";
+
+	const unsigned int saved_pers = personality(0xffffffff);
+	printf("personality\\(0xffffffff\\) = %#x \\([^)]*\\)\n", saved_pers);
+
+	/* PER_LINUX */
+	personality(PER_LINUX);
+	printf("personality\\(PER_LINUX\\) = %#x \\([^)]*\\)\n", saved_pers);
+
+	personality(0xffffffff);
+	puts("personality\\(0xffffffff\\) = 0 \\(PER_LINUX\\)");
+
+	personality(good_flags);
+	printf("personality\\(PER_LINUX\\|%s\\) = 0 \\(PER_LINUX\\)\n",
+	       good_flags_str);
+
+	personality(bad_flags);
+	printf("personality\\(PER_LINUX\\|%s\\)"
+	       " = %#x \\(PER_LINUX\\|%s\\)\n",
+	       bad_flags_str, good_flags, good_flags_str);
+
+	personality(good_flags | bad_flags);
+	printf("personality\\(PER_LINUX\\|%s\\|%s\\)"
+	       " = %#x \\(PER_LINUX\\|%s\\)\n",
+	       good_flags_str, bad_flags_str, bad_flags, bad_flags_str);
+
+	/* another valid type */
+	personality(good_type);
+	printf("personality\\(%s\\) = %#x \\(PER_LINUX\\|%s\\|%s\\)\n",
+	       good_type_str, good_flags | bad_flags,
+	       good_flags_str, bad_flags_str);
+
+	personality(good_type | good_flags);
+	printf("personality\\(%s\\|%s\\) = %#x \\(%s\\)\n",
+	       good_type_str, good_flags_str, good_type, good_type_str);
+
+	personality(good_type | bad_flags);
+	printf("personality\\(%s\\|%s\\) = %#x \\(%s\\|%s\\)\n",
+	       good_type_str, bad_flags_str, good_type | good_flags,
+	       good_type_str, good_flags_str);
+
+	personality(good_type | good_flags | bad_flags);
+	printf("personality\\(%s\\|%s\\|%s\\) = %#x \\(%s\\|%s\\)\n",
+	       good_type_str, good_flags_str, bad_flags_str,
+	       good_type | bad_flags,
+	       good_type_str, bad_flags_str);
+
+	/* invalid type */
+	personality(bad_type);
+	printf("personality\\(%s\\) = %#x \\(%s\\|%s\\|%s\\)\n",
+	       bad_type_str, good_type | good_flags | bad_flags,
+	       good_type_str, good_flags_str, bad_flags_str);
+
+	personality(bad_type | good_flags);
+	printf("personality\\(%s\\|%s\\) = %#x \\(%s\\)\n",
+	       bad_type_str, good_flags_str, bad_type, bad_type_str);
+
+	personality(bad_type | bad_flags);
+	printf("personality\\(%s\\|%s\\) = %#x \\(%s\\|%s\\)\n",
+	       bad_type_str, bad_flags_str, bad_type | good_flags,
+	       bad_type_str, good_flags_str);
+
+	personality(bad_type | good_flags | bad_flags);
+	printf("personality\\(%s\\|%s\\|%s\\) = %#x \\(%s\\|%s\\)\n",
+	       bad_type_str, good_flags_str, bad_flags_str,
+	       bad_type | bad_flags, bad_type_str, bad_flags_str);
+
+	personality(saved_pers);
+	printf("personality\\([^)]*\\) = %#x \\(%s\\|%s\\|%s\\)\n",
+	       bad_type | good_flags | bad_flags,
+	       bad_type_str, good_flags_str, bad_flags_str);
+
+	return 0;
+}
diff --git a/strace/tests/personality.test b/strace/tests/personality.test
new file mode 100755
index 0000000..8f8c0ad
--- /dev/null
+++ b/strace/tests/personality.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check personality syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a20 -epersonality $args > "$OUT"
+match_grep "$LOG" "$OUT"
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/pipe.c b/strace/tests/pipe.c
new file mode 100644
index 0000000..68217f2
--- /dev/null
+++ b/strace/tests/pipe.c
@@ -0,0 +1,57 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#ifdef HAVE_PIPE2
+
+# include <stdio.h>
+# include <fcntl.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	(void) close(0);
+	(void) close(1);
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	(void) close(0);
+	(void) close(1);
+	if (pipe2(fds, O_NONBLOCK))
+		perror_msg_and_skip("pipe2");
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PIPE2")
+
+#endif
diff --git a/strace/tests/pipe.expected b/strace/tests/pipe.expected
new file mode 100644
index 0000000..675cb85
--- /dev/null
+++ b/strace/tests/pipe.expected
@@ -0,0 +1,2 @@
+pipe(\(\[0, 1\]|2\(\[0, 1\], 0)\) += 0
+pipe2\(\[0, 1\], O_NONBLOCK\) += 0
diff --git a/strace/tests/pipe.test b/strace/tests/pipe.test
new file mode 100755
index 0000000..a445f86
--- /dev/null
+++ b/strace/tests/pipe.test
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+# Check pipe/pipe2 syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+syscall=pipe2
+for n in pipe; do
+	$STRACE -e$n -h > /dev/null && syscall=$syscall,$n
+done
+
+run_prog
+run_strace -e$syscall $args
+match_grep
+
+exit 0
diff --git a/strace/tests/poll.c b/strace/tests/poll.c
new file mode 100644
index 0000000..551e9b4
--- /dev/null
+++ b/strace/tests/poll.c
@@ -0,0 +1,259 @@
+/*
+ * This file is part of poll strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_poll
+
+# include <assert.h>
+# include <errno.h>
+# include <poll.h>
+# include <stdio.h>
+# include <stdlib.h>
+# include <unistd.h>
+
+#define PRINT_EVENT(flag, member) \
+	if (member & flag) { \
+		if (member != pfd->member) \
+			tprintf("|"); \
+		tprintf(#flag); \
+		member &= ~flag; \
+	}
+
+static void
+print_pollfd_entering(const struct pollfd *const pfd)
+{
+	tprintf("{fd=%d", pfd->fd);
+	if (pfd->fd >= 0) {
+		tprintf(", events=");
+		short events = pfd->events;
+
+		if (pfd->events) {
+			PRINT_EVENT(POLLIN, events)
+			PRINT_EVENT(POLLPRI, events)
+			PRINT_EVENT(POLLOUT, events)
+#ifdef POLLRDNORM
+			PRINT_EVENT(POLLRDNORM, events)
+#endif
+#ifdef POLLWRNORM
+			PRINT_EVENT(POLLWRNORM, events)
+#endif
+#ifdef POLLRDBAND
+			PRINT_EVENT(POLLRDBAND, events)
+#endif
+#ifdef POLLWRBAND
+			PRINT_EVENT(POLLWRBAND, events)
+#endif
+			PRINT_EVENT(POLLERR, events)
+			PRINT_EVENT(POLLHUP, events)
+			PRINT_EVENT(POLLNVAL, events)
+		} else
+			tprintf("0");
+	}
+	tprintf("}");
+}
+
+static void
+print_pollfd_array_entering(const struct pollfd *const pfd,
+			    const unsigned int size,
+			    const unsigned int valid,
+			    const unsigned int abbrev)
+{
+	tprintf("[");
+	unsigned int i;
+	for (i = 0; i < size; ++i) {
+		if (i)
+			tprintf(", ");
+		if (i >= valid) {
+			tprintf("%p", &pfd[i]);
+			break;
+		}
+		if (i >= abbrev) {
+			tprintf("...");
+			break;
+		}
+		print_pollfd_entering(&pfd[i]);
+	}
+	tprintf("]");
+}
+
+static void
+print_pollfd_exiting(const struct pollfd *const pfd,
+		     unsigned int *const seen,
+		     const unsigned int abbrev)
+{
+	if (!pfd->revents || pfd->fd < 0 || *seen > abbrev)
+		return;
+
+	if (*seen)
+		tprintf(", ");
+	++(*seen);
+
+	if (*seen > abbrev) {
+		tprintf("...");
+		return;
+	}
+	tprintf("{fd=%d, revents=", pfd->fd);
+	short revents = pfd->revents;
+
+	PRINT_EVENT(POLLIN, revents)
+	PRINT_EVENT(POLLPRI, revents)
+	PRINT_EVENT(POLLOUT, revents)
+#ifdef POLLRDNORM
+	PRINT_EVENT(POLLRDNORM, revents)
+#endif
+#ifdef POLLWRNORM
+	PRINT_EVENT(POLLWRNORM, revents)
+#endif
+#ifdef POLLRDBAND
+	PRINT_EVENT(POLLRDBAND, revents)
+#endif
+#ifdef POLLWRBAND
+	PRINT_EVENT(POLLWRBAND, revents)
+#endif
+	PRINT_EVENT(POLLERR, revents)
+	PRINT_EVENT(POLLHUP, revents)
+	PRINT_EVENT(POLLNVAL, revents)
+	tprintf("}");
+}
+
+static void
+print_pollfd_array_exiting(const struct pollfd *const pfd,
+			   const unsigned int size,
+			   const unsigned int abbrev)
+{
+	tprintf("[");
+	unsigned int seen = 0;
+	unsigned int i;
+	for (i = 0; i < size; ++i)
+		print_pollfd_exiting(&pfd[i], &seen, abbrev);
+	tprintf("]");
+}
+
+int
+main(int ac, char **av)
+{
+	tprintf("%s", "");
+
+	assert(syscall(__NR_poll, NULL, 42, 0) == -1);
+	if (ENOSYS == errno)
+		perror_msg_and_skip("poll");
+	tprintf("poll(NULL, 42, 0) = -1 EFAULT (%m)\n");
+
+	int fds[2];
+	if (pipe(fds) || pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	const unsigned int abbrev = (ac > 1) ? atoi(av[1]) : -1;
+	const struct pollfd pfds0[] = {
+		{ .fd = 0, .events = POLLIN | POLLPRI | POLLRDNORM | POLLRDBAND },
+		{ .fd = 1, .events = POLLOUT | POLLWRNORM | POLLWRBAND },
+		{ .fd = fds[0], .events = POLLIN | POLLPRI },
+		{ .fd = fds[1], .events = POLLOUT },
+		{ .fd = 2, .events = POLLOUT | POLLWRBAND }
+	};
+	struct pollfd *const tail_fds0 = tail_memdup(pfds0, sizeof(pfds0));
+	const int timeout = 42;
+	int rc = syscall(__NR_poll, tail_fds0, 0, timeout);
+	assert(rc == 0);
+
+	tprintf("poll([], 0, %d) = %d (Timeout)\n", timeout, rc);
+
+	rc = syscall(__NR_poll, tail_fds0, ARRAY_SIZE(pfds0), timeout);
+	assert(rc == 3);
+
+	tprintf("poll(");
+	print_pollfd_array_entering(tail_fds0, ARRAY_SIZE(pfds0),
+				    ARRAY_SIZE(pfds0), abbrev);
+	tprintf(", %u, %d) = %d (", ARRAY_SIZE(pfds0), timeout, rc);
+	print_pollfd_array_exiting(tail_fds0, ARRAY_SIZE(pfds0), abbrev);
+	tprintf(")\n");
+
+	tail_fds0[0].fd = -1;
+	tail_fds0[2].fd = -3;
+	tail_fds0[4].events = 0;
+	rc = syscall(__NR_poll, tail_fds0, ARRAY_SIZE(pfds0), timeout);
+	assert(rc == 2);
+
+	tprintf("poll(");
+	print_pollfd_array_entering(tail_fds0, ARRAY_SIZE(pfds0),
+				    ARRAY_SIZE(pfds0), abbrev);
+	tprintf(", %u, %d) = %d (", ARRAY_SIZE(pfds0), timeout, rc);
+	print_pollfd_array_exiting(tail_fds0, ARRAY_SIZE(pfds0), abbrev);
+	tprintf(")\n");
+
+	tail_fds0[1].fd = -2;
+	tail_fds0[4].fd = -5;
+	rc = syscall(__NR_poll, tail_fds0, ARRAY_SIZE(pfds0), timeout);
+	assert(rc == 1);
+
+	tprintf("poll(");
+	print_pollfd_array_entering(tail_fds0, ARRAY_SIZE(pfds0),
+				    ARRAY_SIZE(pfds0), abbrev);
+	tprintf(", %u, %d) = %d (", ARRAY_SIZE(pfds0), timeout, rc);
+	print_pollfd_array_exiting(tail_fds0, ARRAY_SIZE(pfds0), abbrev);
+	tprintf(")\n");
+
+	struct pollfd pfds1[] = {
+		{ .fd = 1, .events = POLLIN | POLLPRI | POLLRDNORM | POLLRDBAND },
+		{ .fd = 0, .events = POLLOUT | POLLWRNORM | POLLWRBAND }
+	};
+	struct pollfd *const tail_fds1 = tail_memdup(pfds1, sizeof(pfds1));
+	rc = syscall(__NR_poll, tail_fds1, ARRAY_SIZE(pfds1), timeout);
+	assert(rc == 0);
+
+	tprintf("poll(");
+	print_pollfd_array_entering(tail_fds1, ARRAY_SIZE(pfds1),
+				    ARRAY_SIZE(pfds1), abbrev);
+	tprintf(", %u, %d) = %d (Timeout)\n", ARRAY_SIZE(pfds1), timeout, rc);
+
+	const void *const efault = tail_fds0 + ARRAY_SIZE(pfds0);
+	rc = syscall(__NR_poll, efault, 1, 0);
+	assert(rc == -1);
+	tprintf("poll(%p, 1, 0) = -1 EFAULT (%m)\n", efault);
+
+	const unsigned int valid = 1;
+	const void *const epfds = tail_fds0 + ARRAY_SIZE(pfds0) - valid;
+	rc = syscall(__NR_poll, epfds, valid + 1, 0);
+	assert(rc == -1);
+	tprintf("poll(");
+	print_pollfd_array_entering(epfds, valid + 1, valid, abbrev);
+	errno = EFAULT;
+	tprintf(", %u, 0) = -1 EFAULT (%m)\n", valid + 1);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_poll")
+
+#endif
diff --git a/strace/tests/poll.test b/strace/tests/poll.test
new file mode 100755
index 0000000..b74be29
--- /dev/null
+++ b/strace/tests/poll.test
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+# Check poll syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -a16 -vepoll $args > "$OUT"
+match_diff "$LOG" "$OUT"
+
+for abbrev in 0 1 2 3 4 5; do
+	run_prog "./$NAME" $abbrev > /dev/null
+	run_strace -a16 -epoll -s$abbrev $args > "$OUT"
+	match_diff "$LOG" "$OUT"
+done
+
+rm -f "$OUT"
diff --git a/strace/tests/ppoll-v.expected b/strace/tests/ppoll-v.expected
new file mode 100644
index 0000000..5172717
--- /dev/null
+++ b/strace/tests/ppoll-v.expected
@@ -0,0 +1,3 @@
+ppoll\(\[\{fd=0, events=POLLIN\|POLLPRI\|POLLRDNORM\|POLLRDBAND\}, \{fd=1, events=POLLOUT(\|POLLWRNORM)?\|POLLWRBAND\}, \{fd=3, events=POLLIN\|POLLPRI\}, \{fd=4, events=POLLOUT\}\], 4, \{42, 999999999\}, \[(USR2 CHLD|CHLD USR2)\], (4|8|16)\) = 2 \(\[\{fd=1, revents=POLLOUT(\|POLLWRNORM)?\}, \{fd=4, revents=POLLOUT\}\], left \{42, 9[0-9]{8}\}\)
+ppoll\(\[\{fd=1, events=POLLIN\|POLLPRI\|POLLRDNORM\|POLLRDBAND\}, \{fd=0, events=POLLOUT(\|POLLWRNORM)?\|POLLWRBAND\}\], 2, \{0, 999\}, ~\[HUP KILL STOP[^]]*\], (4|8|16)\) = 0 \(Timeout\)
+ppoll\(NULL, 42, NULL, NULL, (4|8|16)\) = -1 EFAULT .*
diff --git a/strace/tests/ppoll.c b/strace/tests/ppoll.c
new file mode 100644
index 0000000..46d7e81
--- /dev/null
+++ b/strace/tests/ppoll.c
@@ -0,0 +1,94 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <poll.h>
+#include <signal.h>
+#include <unistd.h>
+
+static void
+test1(void)
+{
+	const struct timespec timeout = { .tv_sec = 42, .tv_nsec = 999999999 };
+	struct pollfd fds[] = {
+		{ .fd = 0, .events = POLLIN | POLLPRI | POLLRDNORM | POLLRDBAND },
+		{ .fd = 1, .events = POLLOUT | POLLWRNORM | POLLWRBAND },
+		{ .fd = 3, .events = POLLIN | POLLPRI },
+		{ .fd = 4, .events = POLLOUT }
+	};
+
+	sigset_t mask;
+	sigemptyset(&mask);
+	sigaddset(&mask, SIGUSR2);
+	sigaddset(&mask, SIGCHLD);
+
+	int rc = ppoll(fds, sizeof(fds) / sizeof(*fds), &timeout, &mask);
+	if (rc < 0)
+		perror_msg_and_skip("ppoll");
+	assert(rc == 2);
+}
+
+static void
+test2(void)
+{
+	const struct timespec timeout = { .tv_sec = 0, .tv_nsec = 999 };
+	struct pollfd fds[] = {
+		{ .fd = 1, .events = POLLIN | POLLPRI | POLLRDNORM | POLLRDBAND },
+		{ .fd = 0, .events = POLLOUT | POLLWRNORM | POLLWRBAND }
+	};
+
+	sigset_t mask;
+	sigfillset(&mask);
+	sigdelset(&mask, SIGHUP);
+	sigdelset(&mask, SIGKILL);
+	sigdelset(&mask, SIGSTOP);
+
+	int rc = ppoll(fds, sizeof(fds) / sizeof(*fds), &timeout, &mask);
+	if (rc < 0)
+		perror_msg_and_skip("ppoll");
+	assert(rc == 0);
+}
+
+int
+main(void)
+{
+	int fds[2];
+
+	(void) close(0);
+	(void) close(1);
+	(void) close(3);
+	(void) close(4);
+	if (pipe(fds) || pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	test1();
+	test2();
+
+	assert(ppoll(NULL, 42, NULL, NULL) < 0);
+	return 0;
+}
diff --git a/strace/tests/ppoll.expected b/strace/tests/ppoll.expected
new file mode 100644
index 0000000..4dfc830
--- /dev/null
+++ b/strace/tests/ppoll.expected
@@ -0,0 +1,3 @@
+ppoll\(\[\{fd=0, events=POLLIN\|POLLPRI\|POLLRDNORM\|POLLRDBAND\}, \{fd=1, events=POLLOUT(\|POLLWRNORM)?\|POLLWRBAND\}, \.\.\.\], 4, \{42, 999999999\}, \[(USR2 CHLD|CHLD USR2)\], (4|8|16)\) = 2 \(\[\{fd=1, revents=POLLOUT(\|POLLWRNORM)?\}, \{fd=4, revents=POLLOUT\}\], left \{42, 9[0-9]{8}\}\)
+ppoll\(\[\{fd=1, events=POLLIN\|POLLPRI\|POLLRDNORM\|POLLRDBAND\}, \{fd=0, events=POLLOUT(\|POLLWRNORM)?\|POLLWRBAND\}\], 2, \{0, 999\}, ~\[HUP KILL STOP[^]]*\], (4|8|16)\) = 0 \(Timeout\)
+ppoll\(NULL, 42, NULL, NULL, (4|8|16)\) = -1 EFAULT .*
diff --git a/strace/tests/ppoll.test b/strace/tests/ppoll.test
new file mode 100755
index 0000000..98389ee
--- /dev/null
+++ b/strace/tests/ppoll.test
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# Check ppoll syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -a30 -s2 -e ppoll $args
+match_grep
+run_strace -a30 -v -s2 -e ppoll $args
+match_grep "$LOG" "$srcdir/$NAME-v.expected"
+
+exit 0
diff --git a/strace/tests/prctl-seccomp-filter-v.c b/strace/tests/prctl-seccomp-filter-v.c
new file mode 100644
index 0000000..a03f202
--- /dev/null
+++ b/strace/tests/prctl-seccomp-filter-v.c
@@ -0,0 +1,145 @@
+/*
+ * Check verbose decoding of prctl PR_SET_SECCOMP SECCOMP_MODE_FILTER.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stddef.h>
+#include <unistd.h>
+#include <stdio.h>
+#include <errno.h>
+#include <sys/syscall.h>
+
+#ifdef HAVE_PRCTL
+# include <sys/prctl.h>
+#endif
+#ifdef HAVE_LINUX_SECCOMP_H
+# include <linux/seccomp.h>
+#endif
+#ifdef HAVE_LINUX_FILTER_H
+# include <linux/filter.h>
+#endif
+
+#if defined HAVE_PRCTL \
+ && defined PR_SET_NO_NEW_PRIVS \
+ && defined PR_SET_SECCOMP \
+ && defined SECCOMP_MODE_FILTER \
+ && defined SECCOMP_RET_ERRNO \
+ && defined BPF_JUMP \
+ && defined BPF_STMT
+
+#define SOCK_FILTER_ALLOW_SYSCALL(nr) \
+		BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, __NR_ ## nr, 0, 1), \
+		BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ALLOW)
+
+#define SOCK_FILTER_DENY_SYSCALL(nr, err) \
+		BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, __NR_ ## nr, 0, 1), \
+		BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ERRNO|(SECCOMP_RET_DATA & (err)))
+
+#define SOCK_FILTER_KILL_PROCESS \
+		BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_KILL)
+
+#define PRINT_ALLOW_SYSCALL(nr) \
+	printf("BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, %#x, 0, 0x1), " \
+	       "BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ALLOW), ", \
+	       __NR_ ## nr)
+
+#define PRINT_DENY_SYSCALL(nr, err) \
+	printf("BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, %#x, 0, 0x1), " \
+	       "BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ERRNO|%#x), ", \
+	       __NR_ ## nr, err)
+
+static const struct sock_filter filter[] = {
+	/* load syscall number */
+	BPF_STMT(BPF_LD|BPF_W|BPF_ABS, offsetof(struct seccomp_data, nr)),
+
+	/* allow syscalls */
+	SOCK_FILTER_ALLOW_SYSCALL(close),
+	SOCK_FILTER_ALLOW_SYSCALL(exit),
+	SOCK_FILTER_ALLOW_SYSCALL(exit_group),
+
+	/* deny syscalls */
+	SOCK_FILTER_DENY_SYSCALL(sync, EBUSY),
+	SOCK_FILTER_DENY_SYSCALL(setsid, EPERM),
+
+	/* kill process */
+	SOCK_FILTER_KILL_PROCESS
+};
+
+static const struct sock_fprog prog = {
+	.len = ARRAY_SIZE(filter),
+	.filter = (struct sock_filter *) filter,
+};
+
+int
+main(void)
+{
+	int fds[2];
+
+	puts("prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0)  = 0");
+
+	printf("prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, {len=%u, filter=[",
+	       prog.len);
+
+	printf("BPF_STMT(BPF_LD|BPF_W|BPF_ABS, %#x), ",
+	       (unsigned) offsetof(struct seccomp_data, nr));
+
+	PRINT_ALLOW_SYSCALL(close);
+	PRINT_ALLOW_SYSCALL(exit);
+	PRINT_ALLOW_SYSCALL(exit_group);
+
+	PRINT_DENY_SYSCALL(sync, EBUSY),
+	PRINT_DENY_SYSCALL(setsid, EPERM),
+
+	printf("BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_KILL)");
+
+	puts("]}) = 0");
+	puts("+++ exited with 0 +++");
+
+	fflush(stdout);
+	close(0);
+	close(1);
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	if (prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0))
+		perror_msg_and_skip("PR_SET_NO_NEW_PRIVS");
+	if (prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &prog))
+		perror_msg_and_skip("PR_SET_SECCOMP");
+	if (close(0) || close(1))
+		_exit(77);
+
+	_exit(0);
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PRCTL && PR_SET_NO_NEW_PRIVS && PR_SET_SECCOMP"
+		    " && SECCOMP_MODE_FILTER && SECCOMP_RET_ERRNO"
+		    " && BPF_JUMP && BPF_STMT")
+
+#endif
diff --git a/strace/tests/prctl-seccomp-filter-v.test b/strace/tests/prctl-seccomp-filter-v.test
new file mode 100755
index 0000000..44e4a78
--- /dev/null
+++ b/strace/tests/prctl-seccomp-filter-v.test
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# Check verbose decoding of prctl PR_SET_SECCOMP SECCOMP_MODE_FILTER.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+run_prog > /dev/null
+run_strace -v -eprctl $args > "$EXP"
+grep -v '^prctl(PR_GET_' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/prctl-seccomp-strict.c b/strace/tests/prctl-seccomp-strict.c
new file mode 100644
index 0000000..57387c9
--- /dev/null
+++ b/strace/tests/prctl-seccomp-strict.c
@@ -0,0 +1,73 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+#ifdef HAVE_PRCTL
+# include <sys/prctl.h>
+#endif
+
+#if defined HAVE_PRCTL && defined PR_SET_SECCOMP && defined __NR_exit
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char text1[] =
+		"prctl(PR_SET_SECCOMP, SECCOMP_MODE_STRICT) = 0\n";
+	static const char text2[] = "+++ exited with 0 +++\n";
+
+	int rc = prctl(PR_SET_SECCOMP, -1L, 1, 2, 3);
+	printf("prctl(PR_SET_SECCOMP, %#lx /* SECCOMP_MODE_??? */, 0x1, 0x2, 0x3)"
+	       " = %d %s (%m)\n", -1L, rc, errno2name());
+	fflush(stdout);
+
+	rc = prctl(PR_SET_SECCOMP, 1);
+	if (rc) {
+		printf("prctl(PR_SET_SECCOMP, SECCOMP_MODE_STRICT)"
+		       " = %d %s (%m)\n", rc, errno2name());
+		fflush(stdout);
+		rc = 0;
+	} else {
+		/*
+		 * If kernel implementaton of SECCOMP_MODE_STRICT is buggy,
+		 * the following syscall will result to SIGKILL.
+		 */
+		rc = write(1, text1, LENGTH_OF(text1)) != LENGTH_OF(text1);
+	}
+
+	rc += write(1, text2, LENGTH_OF(text2)) != LENGTH_OF(text2);
+	return !!syscall(__NR_exit, rc);
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PRCTL && PR_SET_SECCOMP && __NR_exit")
+
+#endif
diff --git a/strace/tests/prctl-seccomp-strict.test b/strace/tests/prctl-seccomp-strict.test
new file mode 100755
index 0000000..1f987df
--- /dev/null
+++ b/strace/tests/prctl-seccomp-strict.test
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+# Check how prctl PR_SET_SECCOMP SECCOMP_MODE_STRICT is decoded.
+
+. "${srcdir=.}/init.sh"
+
+check_prog grep
+set -- "./$NAME"
+"$@" > /dev/null || {
+	case $? in
+		77) skip_ "$* exited with code 77" ;;
+		137) framework_skip_ "$* killed by SIGKILL, fix your kernel" ;;
+		*) fail_ "$args failed" ;;
+	esac
+}
+run_strace -eprctl "$@" > "$EXP"
+grep -v '^prctl(PR_GET_' < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+rm -f "$EXP" "$OUT"
diff --git a/strace/tests/pread64-pwrite64.c b/strace/tests/pread64-pwrite64.c
new file mode 100644
index 0000000..4a0932a
--- /dev/null
+++ b/strace/tests/pread64-pwrite64.c
@@ -0,0 +1,223 @@
+/*
+ * Check decoding of pread64 and pwrite64 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <fcntl.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+static void
+dump_str(const char *str, const unsigned int len)
+{
+	static const char dots[16] = "................";
+	unsigned int i;
+
+	for (i = 0; i < len; i += 16) {
+		unsigned int n = len - i > 16 ? 16 : len - i;
+		const char *dump = hexdump_memdup(str + i, n);
+
+		tprintf(" | %05x %-49s  %-16.*s |\n",
+			i, dump, n, dots);
+
+		free((void *) dump);
+	}
+}
+
+static void
+print_hex(const char *str, const unsigned int len)
+{
+	const unsigned char *ustr = (const unsigned char *) str;
+	unsigned int i;
+
+	for (i = 0; i < len; ++i) {
+		unsigned int c = ustr[i];
+
+		switch (c) {
+		case '\t':
+			tprintf("\\t"); break;
+		case '\n':
+			tprintf("\\n"); break;
+		case '\v':
+			tprintf("\\v"); break;
+		case '\f':
+			tprintf("\\f"); break;
+		case '\r':
+			tprintf("\\r"); break;
+		default:
+			tprintf("\\%o", ustr[i]);
+		}
+	}
+}
+
+static void
+test_dump(const unsigned int len)
+{
+	static char *buf;
+
+	if (buf) {
+		size_t ps1 = get_page_size() - 1;
+		buf = (void *) (((size_t) buf + ps1) & ~ps1) - len;
+	} else {
+		buf = tail_alloc(len);
+	}
+
+	const off_t offset = 0xdefaceddeadbeefLL + len;
+	long rc = pread(0, buf, len, offset);
+	if (rc != (int) len)
+		perror_msg_and_fail("pread64: expected %d, returned %ld",
+				    len, rc);
+
+	tprintf("%s(%d, \"", "pread64", 0);
+	print_hex(buf, len);
+	tprintf("\", %d, %lld) = %ld\n", len, (long long) offset, rc);
+	dump_str(buf, len);
+
+	unsigned int i;
+	for (i = 0; i < len; ++i)
+		buf[i] = i;
+
+	rc = pwrite(1, buf, len, offset);
+	if (rc != (int) len)
+		perror_msg_and_fail("pwrite64: expected %d, returned %ld",
+				    len, rc);
+
+	tprintf("%s(%d, \"", "pwrite64", 1);
+	print_hex(buf, len);
+	tprintf("\", %d, %lld) = %ld\n", len, (long long) offset, rc);
+	dump_str(buf, len);
+
+	if (!len)
+		buf = 0;
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	static char tmp[] = "pread64-pwrite64-tmpfile";
+	if (open(tmp, O_CREAT|O_RDONLY|O_TRUNC, 0600) != 0)
+		perror_msg_and_fail("creat: %s", tmp);
+	if (open(tmp, O_WRONLY) != 1)
+		perror_msg_and_fail("open: %s", tmp);
+
+	char *nil = tail_alloc(1);
+	*nil = '\0';
+
+	static const char w_c[] = "0123456789abcde";
+	const unsigned int w_len = LENGTH_OF(w_c);
+	const char *w_d = hexdump_strdup(w_c);
+	const void *w = tail_memdup(w_c, w_len);
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	const unsigned int r0_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r0_len);
+
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+	const unsigned int r1_len = w_len - r0_len;
+	void *r1 = tail_alloc(w_len);
+
+	void *efault = r1 - get_page_size();
+
+	long rc;
+
+	rc = pwrite(1, w, 0, 0);
+	if (rc)
+		perror_msg_and_fail("pwrite64: expected 0, returned %ld", rc);
+	tprintf("pwrite64(1, \"\", 0, 0) = 0\n");
+
+	rc = pwrite(1, efault, 1, 0);
+	if (rc != -1)
+		perror_msg_and_fail("pwrite64: expected -1 EFAULT"
+				    ", returned %ld", rc);
+	tprintf("pwrite64(1, %p, 1, 0) = -1 EFAULT (%m)\n", efault);
+
+	rc = pwrite(1, nil, 1, -3);
+	if (rc != -1)
+		perror_msg_and_fail("pwrite64: expected -1, returned %ld", rc);
+	tprintf("pwrite64(1, \"\\0\", 1, -3) = -1 EINVAL (%m)\n");
+
+	rc = pwrite(1, w, w_len, 0);
+	if (rc != (int) w_len)
+		perror_msg_and_fail("pwrite64: expected %u, returned %ld",
+				    w_len, rc);
+	tprintf("pwrite64(1, \"%s\", %u, 0) = %ld\n"
+		" | 00000 %-49s  %-16s |\n",
+		w_c, w_len, rc, w_d, w_c);
+	close(1);
+
+	rc = pread(0, r0, 0, 0);
+	if (rc)
+		perror_msg_and_fail("pread64: expected 0, returned %ld", rc);
+	tprintf("pread64(0, \"\", 0, 0) = 0\n");
+
+	rc = pread(0, efault, 1, 0);
+	if (rc != -1)
+		perror_msg_and_fail("pread64: expected -1, returned %ld", rc);
+	tprintf("pread64(0, %p, 1, 0) = -1 EFAULT (%m)\n", efault);
+
+	rc = pread(0, efault, 2, -7);
+	if (rc != -1)
+		perror_msg_and_fail("pread64: expected -1, returned %ld", rc);
+	tprintf("pread64(0, %p, 2, -7) = -1 EINVAL (%m)\n", efault);
+
+	rc = pread(0, r0, r0_len, 0);
+	if (rc != (int) r0_len)
+		perror_msg_and_fail("pread64: expected %u, returned %ld",
+				    r0_len, rc);
+	tprintf("pread64(0, \"%s\", %u, 0) = %ld\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r0_len, rc, r0_d, r0_c);
+
+	rc = pread(0, r1, w_len, r0_len);
+	if (rc != (int) r1_len)
+		perror_msg_and_fail("pread64: expected %u, returned %ld",
+				    r1_len, rc);
+	tprintf("pread64(0, \"%s\", %u, %u) = %ld\n"
+		" | 00000 %-49s  %-16s |\n",
+		r1_c, w_len, r0_len, rc, r1_d, r1_c);
+	close(0);
+
+	if (open("/dev/zero", O_RDONLY))
+		perror_msg_and_fail("open");
+
+	if (open("/dev/null", O_WRONLY) != 1)
+		perror_msg_and_fail("open");
+
+	unsigned int i;
+	for (i = 0; i <= 32; ++i)
+		test_dump(i);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
diff --git a/strace/tests/pread64-pwrite64.test b/strace/tests/pread64-pwrite64.test
new file mode 100755
index 0000000..e585406
--- /dev/null
+++ b/strace/tests/pread64-pwrite64.test
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+# Check decoding and dumping of pread64 and pwrite64 syscalls.
+
+. "${srcdir=.}/init.sh"
+
+# strace -P is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+tmpfile=pread64-pwrite64-tmpfile
+> $tmpfile
+
+run_strace_match_diff \
+	-a21 -eread=0 -ewrite=1 -e trace=pread64,pwrite64 \
+	-P $tmpfile -P /dev/zero -P /dev/null
+
+rm -f $tmpfile
diff --git a/strace/tests/preadv-pwritev.c b/strace/tests/preadv-pwritev.c
new file mode 100644
index 0000000..0770d69
--- /dev/null
+++ b/strace/tests/preadv-pwritev.c
@@ -0,0 +1,182 @@
+/*
+ * Check decoding of preadv and pwritev syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#if defined HAVE_PREADV && defined HAVE_PWRITEV
+
+# include <fcntl.h>
+# include <stdio.h>
+# include <sys/uio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	static char tmp[] = "preadv-pwritev-tmpfile";
+	if (open(tmp, O_CREAT|O_RDONLY|O_TRUNC, 0600) != 0)
+		perror_msg_and_fail("creat: %s", tmp);
+	if (open(tmp, O_WRONLY) != 1)
+		perror_msg_and_fail("open: %s", tmp);
+	if (unlink(tmp))
+		perror_msg_and_fail("unlink: %s", tmp);
+
+	static const char w0_c[] = "012";
+	const char *w0_d = hexdump_strdup(w0_c);
+	void *w0 = tail_memdup(w0_c, LENGTH_OF(w0_c));
+
+	const void *efault = w0 + LENGTH_OF(w0_c);
+
+	static const char w1_c[] = "34567";
+	const char *w1_d = hexdump_strdup(w1_c);
+	void *w1 = tail_memdup(w1_c, LENGTH_OF(w1_c));
+
+	static const char w2_c[] = "89abcde";
+	const char *w2_d = hexdump_strdup(w2_c);
+	void *w2 = tail_memdup(w2_c, LENGTH_OF(w2_c));
+
+	long rc;
+
+	rc = pwritev(1, efault, 42, 0);
+	tprintf("pwritev(1, %p, 42, 0) = %ld %s (%m)\n",
+		efault, rc, errno2name());
+
+	rc = preadv(0, efault, 42, 0);
+	tprintf("preadv(0, %p, 42, 0) = %ld %s (%m)\n",
+		efault, rc, errno2name());
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+
+	const struct iovec w_iov_[] = {
+		{
+			.iov_base = w0,
+			.iov_len = LENGTH_OF(w0_c)
+		}, {
+			.iov_base = w1,
+			.iov_len = LENGTH_OF(w1_c)
+		}, {
+			.iov_base = w2,
+			.iov_len = LENGTH_OF(w2_c)
+		}
+	};
+	const struct iovec *w_iov = tail_memdup(w_iov_, sizeof(w_iov_));
+
+	rc = pwritev(1, w_iov, 0, 0);
+	if (rc)
+		perror_msg_and_fail("pwritev: expected 0, returned %ld", rc);
+	tprintf("pwritev(1, [], 0, 0) = 0\n");
+
+	rc = pwritev(1, w_iov + ARRAY_SIZE(w_iov_) - 1, 2, 0);
+	tprintf("pwritev(1, [{iov_base=\"%s\", iov_len=%u}, %p], 2, 0)"
+		" = %ld %s (%m)\n",
+		w2_c, LENGTH_OF(w2_c), w_iov + ARRAY_SIZE(w_iov_),
+		rc, errno2name());
+
+	const unsigned int w_len =
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c) + LENGTH_OF(w2_c);
+
+	rc = pwritev(1, w_iov, ARRAY_SIZE(w_iov_), 0);
+	if (rc != (int) w_len)
+		perror_msg_and_fail("pwritev: expected %u, returned %ld",
+				    w_len, rc);
+	close(1);
+	tprintf("pwritev(1, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}], %u, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 1\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 2\n"
+		" | 00000 %-49s  %-16s |\n",
+		w0_c, LENGTH_OF(w0_c), w1_c, LENGTH_OF(w1_c),
+		w2_c, LENGTH_OF(w2_c), ARRAY_SIZE(w_iov_), w_len,
+		LENGTH_OF(w0_c), w0_d, w0_c,
+		LENGTH_OF(w1_c), w1_d, w1_c, LENGTH_OF(w2_c), w2_d, w2_c);
+
+	const unsigned int r_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r_len);
+	const struct iovec r0_iov_[] = {
+		{
+			.iov_base = r0,
+			.iov_len = r_len
+		}
+	};
+	const struct iovec *r_iov = tail_memdup(r0_iov_, sizeof(r0_iov_));
+
+	rc = preadv(0, r_iov, ARRAY_SIZE(r0_iov_), 0);
+	if (rc != (int) r_len)
+		perror_msg_and_fail("preadv: expected %u, returned %ld",
+				    r_len, rc);
+	tprintf("preadv(0, [{iov_base=\"%s\", iov_len=%u}], %u, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r_len, ARRAY_SIZE(r0_iov_), r_len, r_len, r0_d, r0_c);
+
+	void *r1 = tail_alloc(r_len);
+	void *r2 = tail_alloc(w_len);
+	const struct iovec r1_iov_[] = {
+		{
+			.iov_base = r1,
+			.iov_len = r_len
+		},
+		{
+			.iov_base = r2,
+			.iov_len = w_len
+		}
+	};
+	r_iov = tail_memdup(r1_iov_, sizeof(r1_iov_));
+
+	rc = preadv(0, r_iov, ARRAY_SIZE(r1_iov_), r_len);
+	if (rc != (int) w_len - r_len)
+		perror_msg_and_fail("preadv: expected %d, returned %ld",
+				    (int) w_len - r_len, rc);
+	tprintf("preadv(0, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"\", iov_len=%u}], %u, %u) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r1_c, r_len, w_len, ARRAY_SIZE(r1_iov_),
+		r_len, w_len - r_len,
+		w_len - r_len, r1_d, r1_c);
+	close(0);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PREADV && HAVE_PWRITEV")
+
+#endif
diff --git a/strace/tests/preadv-pwritev.test b/strace/tests/preadv-pwritev.test
new file mode 100755
index 0000000..cb2a077
--- /dev/null
+++ b/strace/tests/preadv-pwritev.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding and dumping of preadv and pwritev syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a19 -eread=0 -ewrite=1 -e trace=preadv,pwritev
diff --git a/strace/tests/preadv.c b/strace/tests/preadv.c
new file mode 100644
index 0000000..eb53a5e
--- /dev/null
+++ b/strace/tests/preadv.c
@@ -0,0 +1,159 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#ifdef HAVE_PREADV
+
+# include <fcntl.h>
+# include <stdio.h>
+# include <sys/uio.h>
+# include <unistd.h>
+
+# define LEN 8
+
+static void
+print_iov(const struct iovec *iov)
+{
+	unsigned int i;
+	unsigned char *buf = iov->iov_base;
+
+	fputs("{iov_base=\"", stdout);
+	for (i = 0; i < iov->iov_len; ++i)
+		printf("\\%d", (int) buf[i]);
+	printf("\", iov_len=%u}", (unsigned) iov->iov_len);
+}
+
+static void
+print_iovec(const struct iovec *iov, unsigned int cnt)
+{
+	unsigned int i;
+	putchar('[');
+	for (i = 0; i < cnt; ++i) {
+		if (i)
+			fputs(", ", stdout);
+		print_iov(&iov[i]);
+	}
+	putchar(']');
+}
+
+int
+main(void)
+{
+	const off_t offset = 0xdefaceddeadbeefLL;
+	char *buf = tail_alloc(LEN);
+	struct iovec *iov = tail_alloc(sizeof(*iov));
+	iov->iov_base = buf;
+	iov->iov_len = LEN;
+
+	(void) close(0);
+	if (open("/dev/zero", O_RDONLY))
+		perror_msg_and_fail("open");
+
+	if (preadv(0, iov, 1, offset) != LEN)
+		perror_msg_and_fail("preadv");
+	printf("preadv(0, ");
+	print_iovec(iov, 1);
+	printf(", 1, %lld) = %u\n", (long long) offset, LEN);
+
+	if (preadv(0, iov, 1, -1) != -1)
+		perror_msg_and_fail("preadv");
+	printf("preadv(0, %p, 1, -1) = -1 EINVAL (%m)\n", iov);
+
+	if (preadv(0, NULL, 1, -2) != -1)
+		perror_msg_and_fail("preadv");
+	printf("preadv(0, NULL, 1, -2) = -1 EINVAL (%m)\n");
+
+	if (preadv(0, iov, 0, -3) != -1)
+		perror_msg_and_fail("preadv");
+	printf("preadv(0, [], 0, -3) = -1 EINVAL (%m)\n");
+
+	static const char tmp[] = "preadv-tmpfile";
+	int fd = open(tmp, O_RDWR | O_CREAT | O_TRUNC, 0600);
+	if (fd < 0)
+		perror_msg_and_fail("open");
+	if (unlink(tmp))
+		perror_msg_and_fail("unlink");
+
+	static const char w[] = "0123456789abcde";
+	if (write(fd, w, LENGTH_OF(w)) != LENGTH_OF(w))
+		perror_msg_and_fail("write");
+
+	static const char r0_c[] = "01234567";
+	static const char r1_c[] = "89abcde";
+
+	const unsigned int r_len = (LENGTH_OF(w) + 1) / 2;
+	void *r0 = tail_alloc(r_len);
+	const struct iovec r0_iov_[] = {
+		{
+			.iov_base = r0,
+			.iov_len = r_len
+		}
+	};
+	const struct iovec *r_iov = tail_memdup(r0_iov_, sizeof(r0_iov_));
+
+	long rc;
+
+	rc = preadv(fd, r_iov, ARRAY_SIZE(r0_iov_), 0);
+	if (rc != (int) r_len)
+		perror_msg_and_fail("preadv: expected %u, returned %ld",
+				    r_len, rc);
+	printf("preadv(%d, [{iov_base=\"%s\", iov_len=%u}], %u, 0) = %u\n",
+	       fd, r0_c, r_len, ARRAY_SIZE(r0_iov_), r_len);
+
+	void *r1 = tail_alloc(r_len);
+	void *r2 = tail_alloc(LENGTH_OF(w));
+	const struct iovec r1_iov_[] = {
+		{
+			.iov_base = r1,
+			.iov_len = r_len
+		},
+		{
+			.iov_base = r2,
+			.iov_len = LENGTH_OF(w)
+		}
+	};
+	r_iov = tail_memdup(r1_iov_, sizeof(r1_iov_));
+
+	rc = preadv(fd, r_iov, ARRAY_SIZE(r1_iov_), r_len);
+	if (rc != (int) LENGTH_OF(w) - r_len)
+		perror_msg_and_fail("preadv: expected %d, returned %ld",
+				    (int) LENGTH_OF(w) - r_len, rc);
+	printf("preadv(%d, [{iov_base=\"%s\", iov_len=%u}"
+	       ", {iov_base=\"\", iov_len=%u}], %u, %u) = %u\n",
+	       fd, r1_c, r_len, LENGTH_OF(w), ARRAY_SIZE(r1_iov_),
+		r_len, LENGTH_OF(w) - r_len);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PREADV")
+
+#endif
diff --git a/strace/tests/preadv.test b/strace/tests/preadv.test
new file mode 100755
index 0000000..d1abdb7
--- /dev/null
+++ b/strace/tests/preadv.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check preadv syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21
diff --git a/strace/tests/preadv2-pwritev2.c b/strace/tests/preadv2-pwritev2.c
new file mode 100644
index 0000000..1a607c9
--- /dev/null
+++ b/strace/tests/preadv2-pwritev2.c
@@ -0,0 +1,214 @@
+/*
+ * Check decoding of preadv2 and pwritev2 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_preadv2 && defined __NR_pwritev2
+
+# include <errno.h>
+# include <fcntl.h>
+# include <stdio.h>
+# include <sys/uio.h>
+# include <unistd.h>
+
+static int
+pr(const int fd, const struct iovec *const vec,
+   const unsigned long vlen, const unsigned long pos)
+{
+	return syscall(__NR_preadv2, fd, vec, vlen, pos, 0L, 0L);
+}
+
+static int
+pw(const int fd, const struct iovec *const vec,
+   const unsigned long vlen, const unsigned long pos)
+{
+	return syscall(__NR_pwritev2, fd, vec, vlen, pos, 0L, 0L);
+}
+
+static void
+dumpio(void)
+{
+	static char tmp[] = "preadv2-pwritev2-tmpfile";
+	if (open(tmp, O_CREAT|O_RDONLY|O_TRUNC, 0600) != 0)
+		perror_msg_and_fail("creat: %s", tmp);
+	if (open(tmp, O_WRONLY) != 1)
+		perror_msg_and_fail("open: %s", tmp);
+	if (unlink(tmp))
+		perror_msg_and_fail("unlink: %s", tmp);
+
+	static const char w0_c[] = "012";
+	const char *w0_d = hexdump_strdup(w0_c);
+	void *w0 = tail_memdup(w0_c, LENGTH_OF(w0_c));
+
+	static const char w1_c[] = "34567";
+	const char *w1_d = hexdump_strdup(w1_c);
+	void *w1 = tail_memdup(w1_c, LENGTH_OF(w1_c));
+
+	static const char w2_c[] = "89abcde";
+	const char *w2_d = hexdump_strdup(w2_c);
+	void *w2 = tail_memdup(w2_c, LENGTH_OF(w2_c));
+
+	long rc;
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+
+	const struct iovec w_iov_[] = {
+		{
+			.iov_base = w0,
+			.iov_len = LENGTH_OF(w0_c)
+		}, {
+			.iov_base = w1,
+			.iov_len = LENGTH_OF(w1_c)
+		}, {
+			.iov_base = w2,
+			.iov_len = LENGTH_OF(w2_c)
+		}
+	};
+	const struct iovec *w_iov = tail_memdup(w_iov_, sizeof(w_iov_));
+
+	rc = pw(1, w_iov, 0, 0);
+	if (rc)
+		perror_msg_and_fail("pwritev2: expected 0, returned %ld", rc);
+	tprintf("pwritev2(1, [], 0, 0, 0) = 0\n");
+
+	rc = pw(1, w_iov + ARRAY_SIZE(w_iov_) - 1, 2, 0);
+	tprintf("pwritev2(1, [{iov_base=\"%s\", iov_len=%u}, %p], 2, 0, 0)"
+		" = %ld %s (%m)\n",
+		w2_c, LENGTH_OF(w2_c), w_iov + ARRAY_SIZE(w_iov_),
+		rc, errno2name());
+
+	const unsigned int w_len =
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c) + LENGTH_OF(w2_c);
+
+	rc = pw(1, w_iov, ARRAY_SIZE(w_iov_), 0);
+	if (rc != (int) w_len)
+		perror_msg_and_fail("pwritev2: expected %u, returned %ld",
+				    w_len, rc);
+	close(1);
+	tprintf("pwritev2(1, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}], %u, 0, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 1\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 2\n"
+		" | 00000 %-49s  %-16s |\n",
+		w0_c, LENGTH_OF(w0_c), w1_c, LENGTH_OF(w1_c),
+		w2_c, LENGTH_OF(w2_c), ARRAY_SIZE(w_iov_), w_len,
+		LENGTH_OF(w0_c), w0_d, w0_c,
+		LENGTH_OF(w1_c), w1_d, w1_c, LENGTH_OF(w2_c), w2_d, w2_c);
+
+	const unsigned int r_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r_len);
+	const struct iovec r0_iov_[] = {
+		{
+			.iov_base = r0,
+			.iov_len = r_len
+		}
+	};
+	const struct iovec *r_iov = tail_memdup(r0_iov_, sizeof(r0_iov_));
+
+	rc = pr(0, r_iov, ARRAY_SIZE(r0_iov_), 0);
+	if (rc != (int) r_len)
+		perror_msg_and_fail("preadv2: expected %u, returned %ld",
+				    r_len, rc);
+	tprintf("preadv2(0, [{iov_base=\"%s\", iov_len=%u}], %u, 0, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r_len, ARRAY_SIZE(r0_iov_), r_len, r_len, r0_d, r0_c);
+
+	void *r1 = tail_alloc(r_len);
+	void *r2 = tail_alloc(w_len);
+	const struct iovec r1_iov_[] = {
+		{
+			.iov_base = r1,
+			.iov_len = r_len
+		},
+		{
+			.iov_base = r2,
+			.iov_len = w_len
+		}
+	};
+	r_iov = tail_memdup(r1_iov_, sizeof(r1_iov_));
+
+	rc = pr(0, r_iov, ARRAY_SIZE(r1_iov_), r_len);
+	if (rc != (int) w_len - r_len)
+		perror_msg_and_fail("preadv2: expected %d, returned %ld",
+				    (int) w_len - r_len, rc);
+	tprintf("preadv2(0, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"\", iov_len=%u}], %u, %u, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r1_c, r_len, w_len, ARRAY_SIZE(r1_iov_),
+		r_len, w_len - r_len,
+		w_len - r_len, r1_d, r1_c);
+	close(0);
+}
+
+int
+main(void)
+{
+	const unsigned long vlen = (unsigned long) 0xfac1fed2dad3bef4;
+	const unsigned long long pos = 0xfac5fed6dad7bef8;
+	const unsigned long pos_l = (unsigned long) pos;
+	const unsigned long pos_h = (sizeof(long) == sizeof(long long)) ?
+		(unsigned long) 0xbadc0deddeadbeef : 0xfac5fed6UL;
+	int test_dumpio = 1;
+
+	tprintf("%s", "");
+
+	syscall(__NR_preadv2, -1, NULL, vlen, pos_l, pos_h, 1);
+	if (ENOSYS == errno)
+		test_dumpio = 0;
+	tprintf("preadv2(-1, NULL, %lu, %lld, RWF_HIPRI) = -1 %s (%m)\n",
+	       vlen, pos, errno2name());
+
+	syscall(__NR_pwritev2, -1, NULL, vlen, pos_l, pos_h, 1);
+	if (ENOSYS == errno)
+		test_dumpio = 0;
+	tprintf("pwritev2(-1, NULL, %lu, %lld, RWF_HIPRI) = -1 %s (%m)\n",
+	       vlen, pos, errno2name());
+
+	if (test_dumpio)
+		dumpio();
+
+	tprintf("%s\n", "+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_preadv2 && __NR_pwritev2")
+
+#endif
diff --git a/strace/tests/preadv2-pwritev2.test b/strace/tests/preadv2-pwritev2.test
new file mode 100755
index 0000000..5641ef4
--- /dev/null
+++ b/strace/tests/preadv2-pwritev2.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding and dumping of preadv2 and pwritev2 syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22 -eread=0 -ewrite=1 -e trace=preadv2,pwritev2
diff --git a/strace/tests/print_quoted_string.c b/strace/tests/print_quoted_string.c
new file mode 100644
index 0000000..3ad8602
--- /dev/null
+++ b/strace/tests/print_quoted_string.c
@@ -0,0 +1,75 @@
+#include "tests.h"
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+/*
+ * Based on string_quote() from util.c.
+ * Assumes instr is NUL-terminated.
+ */
+
+void
+print_quoted_string(const char *instr)
+{
+	print_quoted_memory(instr, strlen(instr));
+}
+
+void
+print_quoted_memory(const char *instr, const size_t len)
+{
+	const unsigned char *str = (const unsigned char*) instr;
+	size_t i;
+
+	for (i = 0; i < len; ++i) {
+		const int c = str[i];
+		switch (c) {
+			case '\"':
+				printf("\\\"");
+				break;
+			case '\\':
+				printf("\\\\");
+				break;
+			case '\f':
+				printf("\\f");
+				break;
+			case '\n':
+				printf("\\n");
+				break;
+			case '\r':
+				printf("\\r");
+				break;
+			case '\t':
+				printf("\\t");
+				break;
+			case '\v':
+				printf("\\v");
+				break;
+			default:
+				if (c >= ' ' && c <= 0x7e)
+					putchar(c);
+				else {
+					putchar('\\');
+
+					char c1 = '0' + (c & 0x7);
+					char c2 = '0' + ((c >> 3) & 0x7);
+					char c3 = '0' + (c >> 6);
+
+					if (*str >= '0' && *str <= '9') {
+						/* Print \octal */
+						putchar(c3);
+						putchar(c2);
+					} else {
+						/* Print \[[o]o]o */
+						if (c3 != '0')
+							putchar(c3);
+						if (c3 != '0' || c2 != '0')
+							putchar(c2);
+					}
+					putchar(c1);
+				}
+				break;
+		}
+	}
+
+}
diff --git a/strace/tests/printflags.c b/strace/tests/printflags.c
new file mode 100644
index 0000000..badc85d
--- /dev/null
+++ b/strace/tests/printflags.c
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include "xlat.h"
+#include <stdio.h>
+
+int
+printflags(const struct xlat *xlat, unsigned long long flags,
+	   const char *const dflt)
+{
+	if (flags == 0 && xlat->val == 0 && xlat->str) {
+		fputs(xlat->str, stdout);
+		return 1;
+	}
+
+	int n;
+	char sep = 0;
+	for (n = 0; xlat->str; xlat++) {
+		if (xlat->val && (flags & xlat->val) == xlat->val) {
+			if (sep)
+				putc(sep, stdout);
+			else
+				sep = '|';
+			fputs(xlat->str, stdout);
+			flags &= ~xlat->val;
+			n++;
+		}
+	}
+
+	if (n) {
+		if (flags) {
+			if (sep)
+				putc(sep, stdout);
+			printf("%#llx", flags);
+			n++;
+		}
+	} else {
+		if (flags) {
+			printf("%#llx", flags);
+			if (dflt)
+				printf(" /* %s */", dflt);
+		} else {
+			if (dflt)
+				putc('0', stdout);
+		}
+	}
+
+	return n;
+}
diff --git a/strace/tests/printxval.c b/strace/tests/printxval.c
new file mode 100644
index 0000000..4fb61c8
--- /dev/null
+++ b/strace/tests/printxval.c
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include "xlat.h"
+#include <stdio.h>
+
+int
+printxval(const struct xlat *xlat, unsigned long long val,
+	  const char *const dflt)
+{
+	for (; xlat->str; xlat++) {
+		if (xlat->val == val) {
+			fputs(xlat->str, stdout);
+			return 1;
+		}
+	}
+
+	printf("%#llx", val);
+	if (dflt)
+		printf(" /* %s */", dflt);
+	return 0;
+}
diff --git a/strace/tests/prlimit64.c b/strace/tests/prlimit64.c
new file mode 100644
index 0000000..6721d49
--- /dev/null
+++ b/strace/tests/prlimit64.c
@@ -0,0 +1,92 @@
+/*
+ * Check decoding of prlimit64 syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_prlimit64
+
+# include <inttypes.h>
+# include <stdio.h>
+# include <stdint.h>
+# include <sys/resource.h>
+# include <unistd.h>
+
+# include "xlat.h"
+# include "xlat/resources.h"
+
+const char *
+sprint_rlim(uint64_t lim)
+{
+	if (lim == -1ULL)
+		return "RLIM64_INFINITY";
+
+	static char buf[2][sizeof(lim)*3 + sizeof("*1024")];
+	static int i;
+	i &= 1;
+	if (lim > 1024 && lim % 1024 == 0)
+		sprintf(buf[i], "%" PRIu64 "*1024", lim / 1024);
+	else
+		sprintf(buf[i], "%" PRIu64, lim);
+
+	return buf[i++];
+}
+
+int
+main(void)
+{
+	unsigned long pid =
+		(unsigned long) 0xdefaced00000000 | (unsigned) getpid();
+	uint64_t *const rlimit = tail_alloc(sizeof(*rlimit) * 2);
+	const struct xlat *xlat;
+
+	for (xlat = resources; xlat->str; ++xlat) {
+		unsigned long res = 0xfacefeed00000000 | xlat->val;
+		long rc = syscall(__NR_prlimit64, pid, res, 0, rlimit);
+		if (rc)
+			printf("prlimit64(%d, %s, NULL, %p) = %ld %s (%m)\n",
+			       (unsigned) pid, xlat->str, rlimit,
+			       rc, errno2name());
+		else
+			printf("prlimit64(%d, %s, NULL"
+			       ", {rlim_cur=%s, rlim_max=%s}) = 0\n",
+			       (unsigned) pid, xlat->str,
+			       sprint_rlim(rlimit[0]),
+			       sprint_rlim(rlimit[1]));
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_prlimit64")
+
+#endif
diff --git a/strace/tests/prlimit64.test b/strace/tests/prlimit64.test
new file mode 100755
index 0000000..2d2240d
--- /dev/null
+++ b/strace/tests/prlimit64.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of prlimit64 syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/pselect6.c b/strace/tests/pselect6.c
new file mode 100644
index 0000000..49258a9
--- /dev/null
+++ b/strace/tests/pselect6.c
@@ -0,0 +1,153 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+/*
+ * Based on test by Dr. David Alan Gilbert <dave@treblig.org>
+ */
+
+#include "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <signal.h>
+#include <unistd.h>
+#include <sys/select.h>
+#include <sys/syscall.h>
+#include <sys/time.h>
+
+#ifdef __NR_pselect6
+
+#ifndef NSIG
+# warning NSIG is not defined, using 32
+# define NSIG 32
+#endif
+
+static fd_set set[3][0x1000000 / sizeof(fd_set)];
+
+static void
+handler(int signo)
+{
+}
+
+int main(int ac, char **av)
+{
+	int fds[2];
+	struct {
+		struct timespec ts;
+		int pad[2];
+	} tm_in = {
+		.ts = { .tv_sec = 0xc0de1, .tv_nsec = 0xc0de2 },
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	}, tm = tm_in;
+	sigset_t mask;
+	const struct sigaction act = { .sa_handler = handler };
+	const struct itimerval itv = { .it_value.tv_usec = 111111 };
+
+	sigemptyset(&mask);
+	sigaddset(&mask, SIGHUP);
+	sigaddset(&mask, SIGCHLD);
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	/*
+	 * Start with a nice simple pselect.
+	 */
+	FD_SET(fds[0], set[0]);
+	FD_SET(fds[1], set[0]);
+	FD_SET(fds[0], set[1]);
+	FD_SET(fds[1], set[1]);
+	FD_SET(1, set[2]);
+	FD_SET(2, set[2]);
+	int rc = pselect(fds[1] + 1, set[0], set[1], set[2], NULL, NULL);
+	if (rc < 0)
+		perror_msg_and_skip("pselect");
+	assert(rc == 1);
+	printf("pselect6(%d, [%d %d], [%d %d], [1 2], NULL, {NULL, %u}) "
+	       "= 1 (out [%d])\n",
+	       fds[1] + 1, fds[0], fds[1],
+	       fds[0], fds[1],
+	       NSIG / 8, fds[1]);
+
+	/*
+	 * Another simple one, with a timeout.
+	 */
+	FD_SET(1, set[1]);
+	FD_SET(2, set[1]);
+	FD_SET(fds[0], set[1]);
+	FD_SET(fds[1], set[1]);
+	assert(syscall(__NR_pselect6, fds[1] + 1, NULL, set[1], NULL, &tm.ts, NULL) == 3);
+	printf("pselect6(%d, NULL, [1 2 %d %d], NULL, {%lld, %lld}, NULL)"
+	       " = 3 (out [1 2 %d], left {%lld, %lld})\n",
+	       fds[1] + 1, fds[0], fds[1],
+	       (long long) tm_in.ts.tv_sec, (long long) tm_in.ts.tv_nsec,
+	       fds[1],
+	       (long long) tm.ts.tv_sec, (long long) tm.ts.tv_nsec);
+
+	/*
+	 * Now the crash case that trinity found, negative nfds
+	 * but with a pointer to a large chunk of valid memory.
+	 */
+	FD_ZERO(set[0]);
+	FD_SET(fds[1],set[0]);
+	assert(pselect(-1, NULL, set[0], NULL, NULL, &mask) == -1);
+	printf("pselect6(-1, NULL, %p, NULL, NULL, {[HUP CHLD], %u}) "
+	       "= -1 EINVAL (%m)\n", set[0], NSIG / 8);
+
+	/*
+	 * Another variant, with nfds exceeding FD_SETSIZE limit.
+	 */
+	FD_ZERO(set[0]);
+	FD_SET(fds[0],set[0]);
+	FD_ZERO(set[1]);
+	tm.ts.tv_sec = 0;
+	tm.ts.tv_nsec = 123;
+	assert(pselect(FD_SETSIZE + 1, set[0], set[1], NULL, &tm.ts, &mask) == 0);
+	printf("pselect6(%d, [%d], [], NULL, {0, 123}, {[HUP CHLD], %u}) "
+	       "= 0 (Timeout)\n", FD_SETSIZE + 1, fds[0], NSIG / 8);
+
+	/*
+	 * See how timeouts are decoded.
+	 */
+	assert(sigaction(SIGALRM, &act, NULL) == 0);
+	assert(setitimer(ITIMER_REAL, &itv, NULL) == 0);
+
+	tm.ts.tv_nsec = 222222222;
+	assert(pselect(0, NULL, NULL, NULL, &tm.ts, &mask) == -1);
+	printf("pselect6(0, NULL, NULL, NULL, {0, 222222222}, {[HUP CHLD], %u})"
+	       " = ? ERESTARTNOHAND (To be restarted if no handler)\n",
+	       NSIG / 8);
+	puts("--- SIGALRM {si_signo=SIGALRM, si_code=SI_KERNEL} ---");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_pselect6")
+
+#endif
diff --git a/strace/tests/pselect6.test b/strace/tests/pselect6.test
new file mode 100755
index 0000000..203f8e2
--- /dev/null
+++ b/strace/tests/pselect6.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check pselect6 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/ptrace.c b/strace/tests/ptrace.c
new file mode 100644
index 0000000..7971b89
--- /dev/null
+++ b/strace/tests/ptrace.c
@@ -0,0 +1,477 @@
+/*
+ * Check decoding of ptrace syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rt_sigprocmask
+
+# include <errno.h>
+# include <signal.h>
+# include <stdio.h>
+# include <string.h>
+# include <sys/wait.h>
+# include <unistd.h>
+# include "ptrace.h"
+# include <linux/audit.h>
+
+static long
+do_ptrace(unsigned long request, unsigned long pid,
+	  unsigned long addr, unsigned long data)
+{
+	return syscall(__NR_ptrace, request, pid, addr, data);
+}
+
+static void
+test_peeksiginfo(unsigned long pid, const unsigned long bad_request)
+{
+	long rc = do_ptrace(PTRACE_PEEKSIGINFO, pid, 0, bad_request);
+	printf("ptrace(PTRACE_PEEKSIGINFO, %u, NULL, %#lx)"
+	       " = %ld %s (%m)\n", (unsigned) pid, bad_request, rc, errno2name());
+
+	struct {
+		unsigned long long off;
+		unsigned int flags, nr;
+	} *const psi = tail_alloc(sizeof(*psi));
+
+	psi->off = 0xdeadbeeffacefeed;
+	psi->flags = 1;
+	psi->nr = 42;
+
+	rc = do_ptrace(PTRACE_PEEKSIGINFO,
+		       pid, (unsigned long) psi, bad_request);
+	printf("ptrace(PTRACE_PEEKSIGINFO, %u, {off=%llu"
+	       ", flags=PTRACE_PEEKSIGINFO_SHARED, nr=%u}, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, psi->off, psi->nr, bad_request, rc, errno2name());
+
+	pid = fork();
+	if ((pid_t) pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		sigset_t mask;
+		sigemptyset(&mask);
+		sigaddset(&mask, SIGUSR1);
+		sigaddset(&mask, SIGUSR2);
+		sigaddset(&mask, SIGALRM);
+
+		if (sigprocmask(SIG_BLOCK, &mask, NULL))
+			perror_msg_and_fail("sigprocmask");
+
+		raise(SIGUSR1);
+		raise(SIGUSR2);
+		raise(SIGALRM);
+
+		if (do_ptrace(PTRACE_TRACEME, 0, 0, 0))
+			perror_msg_and_fail("child: PTRACE_TRACEME");
+
+		raise(SIGSTOP);
+		_exit(0);
+	}
+
+	const unsigned int nsigs = 4;
+	const uid_t uid = geteuid();
+	siginfo_t *sigs = tail_alloc(sizeof(*sigs) * nsigs);
+
+	psi->off = 0;
+	psi->flags = 0;
+	psi->nr = nsigs;
+
+	for (;;) {
+		int status, tracee, saved;
+
+		errno = 0;
+		tracee = wait(&status);
+		if (tracee <= 0) {
+			if (errno == EINTR)
+				continue;
+			saved = errno;
+			kill (pid, SIGKILL);
+			errno = saved;
+			perror_msg_and_fail("wait");
+		}
+		if (WIFEXITED(status)) {
+			if (WEXITSTATUS(status) == 0)
+				break;
+			error_msg_and_fail("unexpected exit status %u",
+					   WEXITSTATUS(status));
+		}
+		if (WIFSIGNALED(status))
+			error_msg_and_fail("unexpected signal %u",
+					   WTERMSIG(status));
+		if (!WIFSTOPPED(status) || WSTOPSIG(status) != SIGSTOP) {
+			kill(pid, SIGKILL);
+			error_msg_and_fail("unexpected wait status %x",
+					   status);
+		}
+
+		rc = do_ptrace(PTRACE_PEEKSIGINFO, pid,
+			       (unsigned long) psi, (unsigned long) sigs);
+		if (rc < 0) {
+			printf("ptrace(PTRACE_PEEKSIGINFO, %u, {off=%llu"
+			       ", flags=0, nr=%u}, %p) = %ld %s (%m)\n",
+			       (unsigned) pid, psi->off, psi->nr, sigs,
+			       rc, errno2name());
+		} else {
+			printf("ptrace(PTRACE_PEEKSIGINFO, %u, {off=%llu"
+			       ", flags=0, nr=%u}"
+			       ", [{si_signo=SIGUSR1, si_code=SI_TKILL"
+			       ", si_pid=%u, si_uid=%u}"
+			       ", {si_signo=SIGUSR2, si_code=SI_TKILL"
+			       ", si_pid=%u, si_uid=%u}"
+			       ", {si_signo=SIGALRM, si_code=SI_TKILL"
+			       ", si_pid=%u, si_uid=%u}"
+			       "]) = %ld\n",
+			       (unsigned) pid, psi->off, psi->nr,
+			       (unsigned) pid, (unsigned) uid,
+			       (unsigned) pid, (unsigned) uid,
+			       (unsigned) pid, (unsigned) uid,
+			       rc);
+		}
+
+		if (do_ptrace(PTRACE_CONT, pid, 0, 0)) {
+			saved = errno;
+			kill (pid, SIGKILL);
+			errno = saved;
+			perror_msg_and_fail("ptrace");
+		}
+		printf("ptrace(PTRACE_CONT, %ld, NULL, SIG_0) = 0\n", pid);
+	}
+}
+
+int
+main(void)
+{
+	const unsigned long bad_request =
+		(unsigned long) 0xdeadbeeffffffeed;
+	const unsigned long bad_data =
+		(unsigned long) 0xdeadcafefffff00d;
+	const unsigned long pid =
+		(unsigned long) 0xdefaced00000000 | (unsigned) getpid();
+
+	unsigned int sigset_size;
+
+	for (sigset_size = 1024 / 8; sigset_size; sigset_size >>= 1) {
+		if (!syscall(__NR_rt_sigprocmask,
+			     SIG_SETMASK, NULL, NULL, sigset_size))
+			break;
+	}
+	if (!sigset_size)
+		perror_msg_and_fail("rt_sigprocmask");
+
+	void *const k_set = tail_alloc(sigset_size);
+	siginfo_t *const sip = tail_alloc(sizeof(*sip));
+
+	long rc = do_ptrace(bad_request, pid, 0, 0);
+	printf("ptrace(%#lx /* PTRACE_??? */, %u, NULL, NULL) = %ld %s (%m)\n",
+	       bad_request, (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_PEEKDATA, pid, bad_request, bad_data);
+# ifdef IA64
+	printf("ptrace(PTRACE_PEEKDATA, %u, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+# else
+	printf("ptrace(PTRACE_PEEKDATA, %u, %#lx, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, bad_data, rc, errno2name());
+#endif
+
+	rc = do_ptrace(PTRACE_PEEKTEXT, pid, bad_request, bad_data);
+# ifdef IA64
+	printf("ptrace(PTRACE_PEEKTEXT, %u, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+# else
+	printf("ptrace(PTRACE_PEEKTEXT, %u, %#lx, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, bad_data, rc, errno2name());
+#endif
+
+	rc = do_ptrace(PTRACE_PEEKUSER, pid, bad_request, bad_data);
+# ifdef IA64
+	printf("ptrace(PTRACE_PEEKUSER, %u, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+# else
+	printf("ptrace(PTRACE_PEEKUSER, %u, %#lx, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, bad_data, rc, errno2name());
+#endif
+
+	rc = do_ptrace(PTRACE_POKEUSER, pid, bad_request, bad_data);
+	printf("ptrace(PTRACE_POKEUSER, %u, %#lx, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, bad_data, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_ATTACH, pid, 0, 0);
+	printf("ptrace(PTRACE_ATTACH, %u) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_INTERRUPT, pid, 0, 0);
+	printf("ptrace(PTRACE_INTERRUPT, %u) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_KILL, pid, 0, 0);
+	printf("ptrace(PTRACE_KILL, %u) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_LISTEN, pid, 0, 0);
+	printf("ptrace(PTRACE_LISTEN, %u) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	sigset_t libc_set;
+	sigemptyset(&libc_set);
+	sigaddset(&libc_set, SIGUSR1);
+	memcpy(k_set, &libc_set, sigset_size);
+
+	rc = do_ptrace(PTRACE_SETSIGMASK,
+		       pid, sigset_size, (unsigned long) k_set);
+	printf("ptrace(PTRACE_SETSIGMASK, %u, %u, [USR1])"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, sigset_size, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_GETSIGMASK,
+		       pid, sigset_size, (unsigned long) k_set);
+	printf("ptrace(PTRACE_GETSIGMASK, %u, %u, %p)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, sigset_size, k_set, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_SECCOMP_GET_FILTER, pid, 42, 0);
+	printf("ptrace(PTRACE_SECCOMP_GET_FILTER, %u, 42, NULL)"
+	       " = %ld %s (%m)\n", (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_GETEVENTMSG, pid, bad_request, bad_data);
+	printf("ptrace(PTRACE_GETEVENTMSG, %u, %#lx, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, bad_data, rc, errno2name());
+
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGIO;
+	sip->si_code = 1;
+	sip->si_errno = ENOENT;
+	sip->si_band = -2;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGIO"
+	       ", si_code=POLL_IN, si_errno=ENOENT, si_band=-2})"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGTRAP;
+	sip->si_code = 1;
+	sip->si_errno = ENOENT;
+	sip->si_pid = 2;
+	sip->si_uid = 3;
+	sip->si_ptr = (void *) bad_request;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGTRAP"
+	       ", si_code=TRAP_BRKPT, si_errno=ENOENT, si_pid=2, si_uid=3"
+	       ", si_value={int=%d, ptr=%p}}) = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_int, sip->si_ptr, rc, errno2name());
+
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGILL;
+	sip->si_code = 1;
+	sip->si_errno = ENOENT;
+	sip->si_addr = (void *) (unsigned long) 0xfacefeeddeadbeef;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGILL"
+	       ", si_code=ILL_ILLOPC, si_errno=ENOENT, si_addr=%p})"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_addr, rc, errno2name());
+
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGFPE;
+	sip->si_code = 1;
+	sip->si_errno = ENOENT;
+	sip->si_addr = (void *) (unsigned long) 0xfacefeeddeadbeef;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGFPE"
+	       ", si_code=FPE_INTDIV, si_errno=ENOENT, si_addr=%p})"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_addr, rc, errno2name());
+
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGBUS;
+	sip->si_code = 1;
+	sip->si_errno = -2;
+	sip->si_addr = (void *) (unsigned long) 0xfacefeeddeadbeef;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGBUS"
+	       ", si_code=BUS_ADRALN, si_errno=%d, si_addr=%p})"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_errno, sip->si_addr,
+	       rc, errno2name());
+
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGPROF;
+	sip->si_code = 0xbadc0ded;
+	sip->si_errno = -2;
+	sip->si_pid = 0;
+	sip->si_uid = 3;
+	sip->si_ptr = 0;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGPROF"
+	       ", si_code=%#x, si_errno=%d, si_pid=0, si_uid=3})"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_code, sip->si_errno,
+	       rc, errno2name());
+
+#ifdef HAVE_SIGINFO_T_SI_SYSCALL
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGSYS;
+	sip->si_code = 1;
+	sip->si_errno = ENOENT;
+	sip->si_call_addr = (void *) (unsigned long) 0xfacefeeddeadbeef;
+	sip->si_syscall = -1U;
+	sip->si_arch = AUDIT_ARCH_X86_64;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGSYS"
+	       ", si_code=SYS_SECCOMP, si_errno=ENOENT, si_call_addr=%p"
+	       ", si_syscall=__NR_syscall_%u, si_arch=AUDIT_ARCH_X86_64})"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_call_addr, sip->si_syscall,
+	       rc, errno2name());
+#endif
+
+#if defined HAVE_SIGINFO_T_SI_TIMERID && defined HAVE_SIGINFO_T_SI_OVERRUN
+	memset(sip, -1, sizeof(*sip));
+	sip->si_signo = SIGHUP;
+	sip->si_code = SI_TIMER;
+	sip->si_errno = ENOENT;
+	sip->si_timerid = 0xdeadbeef;
+	sip->si_overrun = -1;
+	sip->si_ptr = (void *) (unsigned long) 0xfacefeeddeadbeef;
+
+	rc = do_ptrace(PTRACE_SETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_SETSIGINFO, %u, %#lx, {si_signo=SIGHUP"
+	       ", si_code=SI_TIMER, si_errno=ENOENT, si_timerid=%#x"
+	       ", si_overrun=%d, si_value={int=%d, ptr=%p}}) = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, sip->si_timerid, sip->si_overrun,
+	       sip->si_int, sip->si_ptr, rc, errno2name());
+#endif
+
+	rc = do_ptrace(PTRACE_GETSIGINFO,
+		       pid, bad_request, (unsigned long) sip);
+	printf("ptrace(PTRACE_GETSIGINFO, %u, %#lx, %p)"
+	       " = %ld %s (%m)\n", (unsigned) pid, bad_request, sip, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_CONT, pid, 0, SIGUSR1);
+	printf("ptrace(PTRACE_CONT, %u, NULL, SIGUSR1) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_DETACH, pid, 0, SIGUSR2);
+	printf("ptrace(PTRACE_DETACH, %u, NULL, SIGUSR2) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_SYSCALL, pid, 0, SIGUSR1);
+	printf("ptrace(PTRACE_SYSCALL, %u, NULL, SIGUSR1) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+#ifdef PTRACE_SINGLESTEP
+	rc = do_ptrace(PTRACE_SINGLESTEP, pid, 0, SIGUSR2);
+	printf("ptrace(PTRACE_SINGLESTEP, %u, NULL, SIGUSR2) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+#endif
+
+#ifdef PTRACE_SINGLEBLOCK
+	rc = do_ptrace(PTRACE_SINGLEBLOCK, pid, 0, SIGUSR1);
+	printf("ptrace(PTRACE_SINGLEBLOCK, %u, NULL, SIGUSR1) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+#endif
+
+#ifdef PTRACE_SYSEMU
+	rc = do_ptrace(PTRACE_SYSEMU, pid, 0, SIGUSR2);
+	printf("ptrace(PTRACE_SYSEMU, %u, NULL, SIGUSR2) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+#endif
+#ifdef PTRACE_SYSEMU_SINGLESTEP
+	rc = do_ptrace(PTRACE_SYSEMU_SINGLESTEP, pid, 0, SIGUSR1);
+	printf("ptrace(PTRACE_SYSEMU_SINGLESTEP, %u, NULL, SIGUSR1)"
+	       " = %ld %s (%m)\n", (unsigned) pid, rc, errno2name());
+#endif
+
+	rc = do_ptrace(PTRACE_SETOPTIONS,
+		       pid, 0, PTRACE_O_TRACEFORK|PTRACE_O_TRACECLONE);
+	printf("ptrace(PTRACE_SETOPTIONS, %u, NULL"
+	       ", PTRACE_O_TRACEFORK|PTRACE_O_TRACECLONE) = %ld %s (%m)\n",
+	       (unsigned) pid, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_SEIZE,
+		       pid, bad_request, PTRACE_O_TRACESYSGOOD);
+	printf("ptrace(PTRACE_SEIZE, %u, %#lx"
+	       ", PTRACE_O_TRACESYSGOOD) = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_SETREGSET, pid, 1, bad_request);
+	printf("ptrace(PTRACE_SETREGSET, %u, NT_PRSTATUS, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+
+	rc = do_ptrace(PTRACE_GETREGSET, pid, 3, bad_request);
+	printf("ptrace(PTRACE_GETREGSET, %u, NT_PRPSINFO, %#lx)"
+	       " = %ld %s (%m)\n",
+	       (unsigned) pid, bad_request, rc, errno2name());
+
+	test_peeksiginfo(pid, bad_request);
+
+	rc = do_ptrace(PTRACE_TRACEME, 0, 0, 0);
+	if (rc)
+		printf("ptrace(PTRACE_TRACEME) = %ld %s (%m)\n",
+		       rc, errno2name());
+	else
+		printf("ptrace(PTRACE_TRACEME) = 0\n");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rt_sigprocmask")
+
+#endif
diff --git a/strace/tests/ptrace.test b/strace/tests/ptrace.test
new file mode 100755
index 0000000..5add9be
--- /dev/null
+++ b/strace/tests/ptrace.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of ptrace syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a23 -e signal=none
diff --git a/strace/tests/pwritev.c b/strace/tests/pwritev.c
new file mode 100644
index 0000000..58e5b41
--- /dev/null
+++ b/strace/tests/pwritev.c
@@ -0,0 +1,147 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#ifdef HAVE_PWRITEV
+
+# include <fcntl.h>
+# include <stdio.h>
+# include <sys/uio.h>
+# include <unistd.h>
+
+# define LEN 8
+# define LIM (LEN - 1)
+
+static void
+print_iov(const struct iovec *iov)
+{
+	unsigned int i;
+	unsigned char *buf = iov->iov_base;
+
+	fputs("{iov_base=\"", stdout);
+	for (i = 0; i < iov->iov_len; ++i) {
+		if (i < LIM)
+			printf("\\%d", (int) buf[i]);
+	}
+	printf("\"%s, iov_len=%u}",
+	       i > LIM ? "..." : "", (unsigned) iov->iov_len);
+}
+
+static void
+print_iovec(const struct iovec *iov, unsigned int cnt, unsigned int size)
+{
+	if (!size) {
+		printf("%p", iov);
+		return;
+	}
+	unsigned int i;
+	putchar('[');
+	for (i = 0; i < cnt; ++i) {
+		if (i)
+			fputs(", ", stdout);
+		if (i == size) {
+			printf("%p", &iov[i]);
+			break;
+		}
+		if (i == LIM) {
+			fputs("...", stdout);
+			break;
+		}
+		print_iov(&iov[i]);
+	}
+	putchar(']');
+}
+
+int
+main(void)
+{
+	(void) close(0);
+	if (open("/dev/null", O_WRONLY))
+		perror_msg_and_fail("open");
+
+	char *buf = tail_alloc(LEN);
+	unsigned i;
+	for (i = 0; i < LEN; ++i)
+		buf[i] = i;
+
+	struct iovec *iov = tail_alloc(sizeof(*iov) * LEN);
+	for (i = 0; i < LEN; ++i) {
+		buf[i] = i;
+		iov[i].iov_base = &buf[i];
+		iov[i].iov_len = LEN - i;
+	}
+
+	const off_t offset = 0xdefaceddeadbeefLL;
+	long rc;
+	int written = 0;
+	for (i = 0; i < LEN; ++i) {
+		written += iov[i].iov_len;
+		if (pwritev(0, iov, i + 1, offset + i) != written)
+			perror_msg_and_fail("pwritev");
+		fputs("pwritev(0, ", stdout);
+		print_iovec(iov, i + 1, LEN);
+		printf(", %u, %lld) = %d\n",
+		       i + 1, (long long) offset + i, written);
+	}
+
+	for (i = 0; i <= LEN; ++i) {
+		unsigned int n = LEN + 1 - i;
+		fputs("pwritev(0, ", stdout);
+		print_iovec(iov + i, n, LEN - i);
+		rc = pwritev(0, iov + i, n, offset + LEN + i);
+		printf(", %u, %lld) = %ld %s (%m)\n",
+		       n, (long long) offset + LEN + i, rc, errno2name());
+	}
+
+	iov->iov_base = iov + LEN * 2;
+	rc = pwritev(0, iov, 1, -1);
+	printf("pwritev(0, [{iov_base=%p, iov_len=%d}], 1, -1) = %ld %s (%m)\n",
+	       iov->iov_base, LEN, rc, errno2name());
+
+	iov += LEN;
+	rc = pwritev(0, iov, 42, -2);
+	printf("pwritev(0, %p, 42, -2) = %ld %s (%m)\n",
+	       iov, rc, errno2name());
+
+	rc = pwritev(0, NULL, 1, -3);
+	printf("pwritev(0, NULL, 1, -3) = %ld %s (%m)\n",
+	       rc, errno2name());
+
+	rc = pwritev(0, iov, 0, -4);
+	printf("pwritev(0, [], 0, -4) = %ld %s (%m)\n",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PWRITEV")
+
+#endif
diff --git a/strace/tests/pwritev.test b/strace/tests/pwritev.test
new file mode 100755
index 0000000..0aed683
--- /dev/null
+++ b/strace/tests/pwritev.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check pwritev syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22 -s7
diff --git a/strace/tests/qual_syscall.test b/strace/tests/qual_syscall.test
new file mode 100755
index 0000000..1aff1cc
--- /dev/null
+++ b/strace/tests/qual_syscall.test
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+# Ensure that strace -e trace=set works.
+
+. "${srcdir=.}/init.sh"
+
+check_prog ls
+run_strace -e execve ls
+
+grep '^execve(' "$LOG" > /dev/null ||
+	dump_log_and_fail_with "$STRACE $args output mismatch"
+
+grep -v '^execve(' "$LOG" |
+LC_ALL=C grep '^[[:alnum:]_]*(' > /dev/null &&
+	dump_log_and_fail_with "$STRACE $args unexpected output"
+
+run_strace -e trace=process ls
+
+grep '^execve(' "$LOG" > /dev/null ||
+	dump_log_and_fail_with "$STRACE $args output mismatch"
+
+grep '^open' "$LOG" > /dev/null &&
+	dump_log_and_fail_with "$STRACE $args unexpected output"
+
+exit 0
diff --git a/strace/tests/read-write.c b/strace/tests/read-write.c
new file mode 100644
index 0000000..4d1e730
--- /dev/null
+++ b/strace/tests/read-write.c
@@ -0,0 +1,209 @@
+/*
+ * Check decoding and dumping of read and write syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <fcntl.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+static void
+dump_str(const char *str, const unsigned int len)
+{
+	static const char dots[16] = "................";
+	unsigned int i;
+
+	for (i = 0; i < len; i += 16) {
+		unsigned int n = len - i > 16 ? 16 : len - i;
+		const char *dump = hexdump_memdup(str + i, n);
+
+		tprintf(" | %05x %-49s  %-16.*s |\n",
+			i, dump, n, dots);
+
+		free((void *) dump);
+	}
+}
+
+static void
+print_hex(const char *str, const unsigned int len)
+{
+	const unsigned char *ustr = (const unsigned char *) str;
+	unsigned int i;
+
+	for (i = 0; i < len; ++i) {
+		unsigned int c = ustr[i];
+
+		switch (c) {
+		case '\t':
+			tprintf("\\t"); break;
+		case '\n':
+			tprintf("\\n"); break;
+		case '\v':
+			tprintf("\\v"); break;
+		case '\f':
+			tprintf("\\f"); break;
+		case '\r':
+			tprintf("\\r"); break;
+		default:
+			tprintf("\\%o", ustr[i]);
+		}
+	}
+}
+
+static void
+test_dump(const unsigned int len)
+{
+	static char *buf;
+
+	if (buf) {
+		size_t ps1 = get_page_size() - 1;
+		buf = (void *) (((size_t) buf + ps1) & ~ps1) - len;
+	} else {
+		buf = tail_alloc(len);
+	}
+
+	long rc = read(0, buf, len);
+	if (rc != (int) len)
+		perror_msg_and_fail("read: expected %d, returned %ld",
+				    len, rc);
+
+	tprintf("%s(%d, \"", "read", 0);
+	print_hex(buf, len);
+	tprintf("\", %d) = %ld\n", len, rc);
+	dump_str(buf, len);
+
+	unsigned int i;
+	for (i = 0; i < len; ++i)
+		buf[i] = i;
+
+	rc = write(1, buf, len);
+	if (rc != (int) len)
+		perror_msg_and_fail("write: expected %d, returned %ld",
+				    len, rc);
+
+	tprintf("%s(%d, \"", "write", 1);
+	print_hex(buf, len);
+	tprintf("\", %d) = %ld\n", len, rc);
+	dump_str(buf, len);
+
+	if (!len)
+		buf = 0;
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	static char tmp[] = "read-write-tmpfile";
+	if (open(tmp, O_CREAT|O_RDONLY|O_TRUNC, 0600) != 0)
+		perror_msg_and_fail("creat: %s", tmp);
+	if (open(tmp, O_WRONLY) != 1)
+		perror_msg_and_fail("open: %s", tmp);
+
+	static const char w_c[] = "0123456789abcde";
+	const unsigned int w_len = LENGTH_OF(w_c);
+	const char *w_d = hexdump_strdup(w_c);
+	const void *w = tail_memdup(w_c, w_len);
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	const unsigned int r0_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r0_len);
+
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+	const unsigned int r1_len = w_len - r0_len;
+	void *r1 = tail_alloc(w_len);
+
+	void *efault = r1 - get_page_size();
+
+	long rc;
+
+	rc = write(1, w, 0);
+	if (rc)
+		perror_msg_and_fail("write: expected 0, returned %ld", rc);
+	tprintf("write(1, \"\", 0) = 0\n");
+
+	rc = write(1, efault, 1);
+	if (rc != -1)
+		perror_msg_and_fail("write: expected -1 EFAULT"
+				    ", returned %ld", rc);
+	tprintf("write(1, %p, 1) = -1 EFAULT (%m)\n", efault);
+
+	rc = write(1, w, w_len);
+	if (rc != (int) w_len)
+		perror_msg_and_fail("write: expected %u, returned %ld",
+				    w_len, rc);
+	tprintf("write(1, \"%s\", %u) = %ld\n"
+		" | 00000 %-49s  %-16s |\n",
+		w_c, w_len, rc, w_d, w_c);
+	close(1);
+
+	rc = read(0, r0, 0);
+	if (rc)
+		perror_msg_and_fail("read: expected 0, returned %ld", rc);
+	tprintf("read(0, \"\", 0) = 0\n");
+
+	rc = read(0, efault, 1);
+	if (rc != -1)
+		perror_msg_and_fail("read: expected -1, returned %ld", rc);
+	tprintf("read(0, %p, 1) = -1 EFAULT (%m)\n", efault);
+
+	rc = read(0, r0, r0_len);
+	if (rc != (int) r0_len)
+		perror_msg_and_fail("read: expected %u, returned %ld",
+				    r0_len, rc);
+	tprintf("read(0, \"%s\", %u) = %ld\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r0_len, rc, r0_d, r0_c);
+
+	rc = read(0, r1, w_len);
+	if (rc != (int) r1_len)
+		perror_msg_and_fail("read: expected %u, returned %ld",
+				    r1_len, rc);
+	tprintf("read(0, \"%s\", %u) = %ld\n"
+		" | 00000 %-49s  %-16s |\n",
+		r1_c, w_len, rc, r1_d, r1_c);
+	close(0);
+
+	if (open("/dev/zero", O_RDONLY))
+		perror_msg_and_fail("open");
+
+	if (open("/dev/null", O_WRONLY) != 1)
+		perror_msg_and_fail("open");
+
+	unsigned int i;
+	for (i = 0; i <= 32; ++i)
+		test_dump(i);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
diff --git a/strace/tests/read-write.test b/strace/tests/read-write.test
new file mode 100755
index 0000000..3700541
--- /dev/null
+++ b/strace/tests/read-write.test
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+# Check decoding and dumping of read and write syscalls.
+
+. "${srcdir=.}/init.sh"
+
+# strace -P is implemented using /proc/self/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+tmpfile=read-write-tmpfile
+> $tmpfile
+
+run_strace_match_diff \
+	-a15 -eread=0 -ewrite=1 -e trace=read,write \
+	-P $tmpfile -P /dev/zero -P /dev/null
+
+rm -f $tmpfile
diff --git a/strace/tests/readdir.c b/strace/tests/readdir.c
new file mode 100644
index 0000000..85170aa
--- /dev/null
+++ b/strace/tests/readdir.c
@@ -0,0 +1,102 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_readdir
+
+# include <assert.h>
+# include <dirent.h>
+# include <fcntl.h>
+# include <stdio.h>
+# include <string.h>
+# include <sys/stat.h>
+# include <unistd.h>
+
+static const char fname[] =
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n"
+	"A\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nZ";
+static const char qname[] =
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\n"
+	"A\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nA\\nZ";
+
+int
+main(int ac, const char **av)
+{
+	char *dname;
+	struct {
+		unsigned long   d_ino;
+		unsigned long   d_off;
+		unsigned short  d_reclen;
+		char d_name[1024];
+	} e;
+	int rc;
+
+	assert(ac == 1);
+	assert(asprintf(&dname, "%s.test.tmp.dir", av[0]) > 0);
+	assert(!mkdir(dname, 0700));
+	assert(!chdir(dname));
+	(void) close(0);
+	assert(!creat(fname, 0600));
+	assert(!close(0));
+	assert(!open(".", O_RDONLY | O_DIRECTORY));
+	while ((rc = syscall(__NR_readdir, 0, &e, 1))) {
+		if (rc < 0)
+			perror_msg_and_skip("readdir");
+		e.d_name[e.d_reclen] = '\0';
+		printf("readdir(0, {d_ino=%lu, d_off=%lu, d_reclen=%u"
+		       ", d_name=\"%s\"}) = %d\n",
+		       e.d_ino, e.d_off, e.d_reclen,
+		       e.d_name[0] == '.' ? e.d_name : qname, rc);
+	}
+	printf("readdir(0, %p) = 0\n", &e);
+	puts("+++ exited with 0 +++");
+	assert(!unlink(fname));
+	assert(!chdir(".."));
+	assert(!rmdir(dname));
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_readdir")
+
+#endif
diff --git a/strace/tests/readdir.test b/strace/tests/readdir.test
new file mode 100755
index 0000000..e313273
--- /dev/null
+++ b/strace/tests/readdir.test
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+# Check readdir syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+rm -rf -- "$LOG".dir
+run_strace_match_diff -a16
diff --git a/strace/tests/readlink.c b/strace/tests/readlink.c
new file mode 100644
index 0000000..85777e4
--- /dev/null
+++ b/strace/tests/readlink.c
@@ -0,0 +1,81 @@
+/*
+ * Copyright (c) 2015 Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_readlink
+
+# include <stdio.h>
+# include <unistd.h>
+
+# define PREFIX "test.readlink"
+# define TARGET (PREFIX ".target")
+# define LINKPATH (PREFIX ".link")
+
+int
+main(void)
+{
+	const char * const fname = tail_memdup(LINKPATH, sizeof(LINKPATH));
+	const char * const hex_fname =
+		hexquote_strndup(fname, sizeof(LINKPATH) - 1);
+
+	const unsigned int size = sizeof(TARGET) - 1;
+	char * const buf = tail_alloc(size);
+
+	(void) unlink(fname);
+
+	long rc = syscall(__NR_readlink, fname, buf, size);
+	printf("readlink(\"%s\", %p, %u) = -1 ENOENT (%m)\n",
+	       hex_fname, buf, size);
+
+	if (symlink(TARGET, fname))
+		perror_msg_and_fail("symlink");
+
+	rc = syscall(__NR_readlink, fname, buf, size);
+	if (rc < 0) {
+		perror("readlink");
+		(void) unlink(fname);
+		return 77;
+	}
+	const char * const hex_buf = hexquote_strndup(buf, size);
+	printf("readlink(\"%s\", \"%s\", %u) = %u\n",
+	       hex_fname, hex_buf, size, size);
+
+	if (unlink(fname))
+		perror_msg_and_fail("unlink");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_readlink")
+
+#endif
diff --git a/strace/tests/readlink.test b/strace/tests/readlink.test
new file mode 100755
index 0000000..c026ecb
--- /dev/null
+++ b/strace/tests/readlink.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check readlink syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -xx
diff --git a/strace/tests/readlinkat.c b/strace/tests/readlinkat.c
new file mode 100644
index 0000000..5ca9e72
--- /dev/null
+++ b/strace/tests/readlinkat.c
@@ -0,0 +1,81 @@
+/*
+ * Copyright (c) 2015 Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_readlinkat
+
+# include <stdio.h>
+# include <unistd.h>
+
+# define PREFIX "test.readlinkat"
+# define TARGET (PREFIX ".target")
+# define LINKPATH (PREFIX ".link")
+
+int
+main(void)
+{
+	const char * const fname = tail_memdup(LINKPATH, sizeof(LINKPATH));
+	const char * const hex_fname =
+		hexquote_strndup(fname, sizeof(LINKPATH) - 1);
+
+	const unsigned int size = sizeof(TARGET) - 1;
+	char * const buf = tail_alloc(size);
+
+	(void) unlink(fname);
+
+	long rc = syscall(__NR_readlinkat, -100, fname, buf, size);
+	printf("readlinkat(AT_FDCWD, \"%s\", %p, %u) = -1 ENOENT (%m)\n",
+	       hex_fname, buf, size);
+
+	if (symlink(TARGET, fname))
+		perror_msg_and_fail("symlink");
+
+	rc = syscall(__NR_readlinkat, -100, fname, buf, size);
+	if (rc < 0) {
+		perror("readlinkat");
+		(void) unlink(fname);
+		return 77;
+	}
+	const char * const hex_buf = hexquote_strndup(buf, size);
+	printf("readlinkat(AT_FDCWD, \"%s\", \"%s\", %u) = %u\n",
+	       hex_fname, hex_buf, size, size);
+
+	if (unlink(fname))
+		perror_msg_and_fail("unlink");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_readlink")
+
+#endif
diff --git a/strace/tests/readlinkat.test b/strace/tests/readlinkat.test
new file mode 100755
index 0000000..229c8e1
--- /dev/null
+++ b/strace/tests/readlinkat.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check readlinkat syscall decoding.
+
+. "${srcdir=.}/readlink.test"
diff --git a/strace/tests/readv.c b/strace/tests/readv.c
new file mode 100644
index 0000000..c134d72
--- /dev/null
+++ b/strace/tests/readv.c
@@ -0,0 +1,159 @@
+/*
+ * Check decoding of readv and writev syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <assert.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/uio.h>
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	assert(0 == fds[0]);
+	assert(1 == fds[1]);
+
+	static const char w0_c[] = "012";
+	const char *w0_d = hexdump_strdup(w0_c);
+	void *w0 = tail_memdup(w0_c, LENGTH_OF(w0_c));
+
+	const void *efault = w0 + LENGTH_OF(w0_c);
+
+	static const char w1_c[] = "34567";
+	const char *w1_d = hexdump_strdup(w1_c);
+	void *w1 = tail_memdup(w1_c, LENGTH_OF(w1_c));
+
+	static const char w2_c[] = "89abcde";
+	const char *w2_d = hexdump_strdup(w2_c);
+	void *w2 = tail_memdup(w2_c, LENGTH_OF(w2_c));
+	long rc;
+
+	rc = writev(1, efault, 42);
+	tprintf("writev(1, %p, 42) = %ld %s (%m)\n",
+		efault, rc, errno2name());
+
+	rc = readv(0, efault, 42);
+	tprintf("readv(0, %p, 42) = %ld %s (%m)\n",
+		efault, rc, errno2name());
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+
+	const struct iovec w_iov_[] = {
+		{
+			.iov_base = w0,
+			.iov_len = LENGTH_OF(w0_c)
+		}, {
+			.iov_base = w1,
+			.iov_len = LENGTH_OF(w1_c)
+		}, {
+			.iov_base = w2,
+			.iov_len = LENGTH_OF(w2_c)
+		}
+	};
+	const struct iovec *w_iov = tail_memdup(w_iov_, sizeof(w_iov_));
+
+	tprintf("writev(1, [], 0) = %ld\n",
+		(long) writev(1, w_iov, 0));
+
+	rc = writev(1, w_iov + ARRAY_SIZE(w_iov_) - 1, 2);
+	tprintf("writev(1, [{iov_base=\"%s\", iov_len=%u}, %p], 2)"
+		" = %ld %s (%m)\n",
+		w2_c, LENGTH_OF(w2_c), w_iov + ARRAY_SIZE(w_iov_),
+		rc, errno2name());
+
+	const unsigned int w_len =
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c) + LENGTH_OF(w2_c);
+
+	assert(writev(1, w_iov, ARRAY_SIZE(w_iov_)) == (int) w_len);
+	close(1);
+	tprintf("writev(1, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}], %u) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 1\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 2\n"
+		" | 00000 %-49s  %-16s |\n",
+		w0_c, LENGTH_OF(w0_c), w1_c, LENGTH_OF(w1_c),
+		w2_c, LENGTH_OF(w2_c), ARRAY_SIZE(w_iov_), w_len,
+		LENGTH_OF(w0_c), w0_d, w0_c,
+		LENGTH_OF(w1_c), w1_d, w1_c, LENGTH_OF(w2_c), w2_d, w2_c);
+
+	const unsigned int r_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r_len);
+	const struct iovec r0_iov_[] = {
+		{
+			.iov_base = r0,
+			.iov_len = r_len
+		}
+	};
+	const struct iovec *r_iov = tail_memdup(r0_iov_, sizeof(r0_iov_));
+
+	assert(readv(0, r_iov, ARRAY_SIZE(r0_iov_)) == (int) r_len);
+	tprintf("readv(0, [{iov_base=\"%s\", iov_len=%u}], %u) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r_len, ARRAY_SIZE(r0_iov_), r_len, r_len, r0_d, r0_c);
+
+	void *r1 = tail_alloc(r_len);
+	void *r2 = tail_alloc(w_len);
+	const struct iovec r1_iov_[] = {
+		{
+			.iov_base = r1,
+			.iov_len = r_len
+		},
+		{
+			.iov_base = r2,
+			.iov_len = w_len
+		}
+	};
+	r_iov = tail_memdup(r1_iov_, sizeof(r1_iov_));
+
+	assert(readv(0, r_iov, ARRAY_SIZE(r1_iov_)) == (int) w_len - r_len);
+	tprintf("readv(0, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"\", iov_len=%u}], %u) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r1_c, r_len, w_len, ARRAY_SIZE(r1_iov_), w_len - r_len,
+		w_len - r_len, r1_d, r1_c);
+	close(0);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
diff --git a/strace/tests/readv.test b/strace/tests/readv.test
new file mode 100755
index 0000000..cbcffde
--- /dev/null
+++ b/strace/tests/readv.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of readv and writev syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a16 -eread=0 -ewrite=1 -e trace=readv,writev
diff --git a/strace/tests/reboot.c b/strace/tests/reboot.c
new file mode 100644
index 0000000..eedc2a6
--- /dev/null
+++ b/strace/tests/reboot.c
@@ -0,0 +1,37 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_reboot
+
+# include <stdio.h>
+# include <linux/reboot.h>
+# include <unistd.h>
+
+# define INVALID_MAGIC 319887762
+# define INVALID_CMD 0x01234568
+
+int
+main(void)
+{
+	static const char buf[] = "reboot";
+	long rc = syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, \
+	          INVALID_MAGIC, LINUX_REBOOT_CMD_RESTART2, buf);
+	printf("reboot(LINUX_REBOOT_MAGIC1, %#x /* LINUX_REBOOT_MAGIC_??? */,"
+	       " LINUX_REBOOT_CMD_RESTART2, \"%s\") = %ld %s (%m)\n",
+	       INVALID_MAGIC, buf, rc, errno2name());
+
+	rc = syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, \
+	     LINUX_REBOOT_MAGIC2, INVALID_CMD);
+	printf("reboot(LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2,"
+	       " %#x /* LINUX_REBOOT_CMD_??? */) = %ld %s (%m)\n",
+	       INVALID_CMD, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_reboot")
+
+#endif
diff --git a/strace/tests/reboot.test b/strace/tests/reboot.test
new file mode 100755
index 0000000..a97dd21
--- /dev/null
+++ b/strace/tests/reboot.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check reboot syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/recvfrom.c b/strace/tests/recvfrom.c
new file mode 100644
index 0000000..b12454d
--- /dev/null
+++ b/strace/tests/recvfrom.c
@@ -0,0 +1,89 @@
+/*
+ * Check decoding of sockaddr related arguments of recvfrom syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define TEST_SYSCALL_NAME recvfrom
+#define TEST_SYSCALL_PREPARE send_un()
+#define PREFIX_S_ARGS	, recv_buf, 1, 0
+#define PREFIX_S_STR	", \"A\", 1, 0"
+#define PREFIX_F_ARGS	, 0, 1, 0
+#define PREFIX_F_STR	", NULL, 1, 0"
+static void send_un(void);
+static char recv_buf[1];
+#include "sockname.c"
+
+static int cfd;
+
+static void
+send_un(void)
+{
+	if (send(cfd, "A", 1, 0) != 1)
+		perror_msg_and_skip("send");
+}
+
+int
+main(void)
+{
+	cfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	int lfd = socket(AF_UNIX, SOCK_STREAM, 0);
+	if (cfd < 0 || lfd < 0)
+		perror_msg_and_skip("socket");
+
+	struct sockaddr_un un = {
+		.sun_family = AF_UNIX,
+		.sun_path = TEST_SOCKET ".send"
+	};
+
+	(void) unlink(un.sun_path);
+	if (bind(cfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+	(void) unlink(un.sun_path);
+
+	un.sun_path[sizeof(TEST_SOCKET) - 1] = '\0';
+	(void) unlink(un.sun_path);
+
+	if (bind(lfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("bind");
+
+	if (listen(lfd, 1))
+		perror_msg_and_skip("listen");
+
+	if (connect(cfd, (const void *) &un, sizeof(un)))
+		perror_msg_and_skip("connect");
+
+	int afd = accept(lfd, 0, 0);
+	if (afd < 0)
+		perror_msg_and_skip("accept");
+
+	(void) unlink(un.sun_path);
+
+	test_sockname_syscall(afd);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/recvfrom.test b/strace/tests/recvfrom.test
new file mode 100755
index 0000000..9dfbc89
--- /dev/null
+++ b/strace/tests/recvfrom.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of sockaddr related arguments of recvfrom syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a35
diff --git a/strace/tests/recvmmsg-timeout.c b/strace/tests/recvmmsg-timeout.c
new file mode 100644
index 0000000..4afd8a6
--- /dev/null
+++ b/strace/tests/recvmmsg-timeout.c
@@ -0,0 +1,70 @@
+/*
+ * Check decoding of timeout argument of recvmmsg syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+
+#include "msghdr.h"
+
+int
+main(void)
+{
+	int fds[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds))
+		perror_msg_and_skip("socketpair");
+
+	if (send(fds[1], "A", 1, 0) != 1)
+		perror_msg_and_skip("send");
+
+	char buf;
+	struct iovec iov = { .iov_base = &buf, .iov_len = sizeof(buf) };
+	struct mmsghdr mh = {
+		.msg_hdr = {
+			.msg_iov = &iov,
+			.msg_iovlen = 1
+		}
+	};
+	struct timespec t = { .tv_sec = 0, .tv_nsec = 12345678 };
+
+	int rc = recv_mmsg(-1, &mh, 1, 0, &t);
+	printf("recvmmsg(-1, %p, 1, 0, {0, 12345678})"
+	       " = %d %s (%m)\n", &mh, rc, errno2name());
+
+	rc = recv_mmsg(fds[0], &mh, 1, 0, &t);
+	if (rc < 0)
+		perror_msg_and_skip("recvmmsg");
+	printf("recvmmsg(%d, [{msg_hdr={msg_name=NULL, msg_namelen=0"
+	       ", msg_iov=[{iov_base=\"A\", iov_len=1}], msg_iovlen=1"
+	       ", msg_controllen=0, msg_flags=0}, msg_len=1}], 1, 0"
+	       ", {0, 12345678}) = %d (left {0, %d})\n",
+	       fds[0], rc, (int) t.tv_nsec);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/recvmmsg-timeout.test b/strace/tests/recvmmsg-timeout.test
new file mode 100755
index 0000000..36a1222
--- /dev/null
+++ b/strace/tests/recvmmsg-timeout.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of timeout argument of recvmmsg syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a25 -e trace=recvmmsg
diff --git a/strace/tests/recvmsg.c b/strace/tests/recvmsg.c
new file mode 100644
index 0000000..19afe8f
--- /dev/null
+++ b/strace/tests/recvmsg.c
@@ -0,0 +1,160 @@
+/*
+ * Check decoding of recvmsg and sendmsg syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <assert.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <sys/uio.h>
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds))
+		perror_msg_and_skip("socketpair");
+	assert(0 == fds[0]);
+	assert(1 == fds[1]);
+
+	static const char w0_c[] = "012";
+	const char *w0_d = hexdump_strdup(w0_c);
+	void *w0 = tail_memdup(w0_c, LENGTH_OF(w0_c));
+
+	static const char w1_c[] = "34567";
+	const char *w1_d = hexdump_strdup(w1_c);
+	void *w1 = tail_memdup(w1_c, LENGTH_OF(w1_c));
+
+	static const char w2_c[] = "89abcde";
+	const char *w2_d = hexdump_strdup(w2_c);
+	void *w2 = tail_memdup(w2_c, LENGTH_OF(w2_c));
+
+	static const char r0_c[] = "01234567";
+	const char *r0_d = hexdump_strdup(r0_c);
+	static const char r1_c[] = "89abcde";
+	const char *r1_d = hexdump_strdup(r1_c);
+
+	const struct iovec w_iov_[] = {
+		{
+			.iov_base = w0,
+			.iov_len = LENGTH_OF(w0_c)
+		}, {
+			.iov_base = w1,
+			.iov_len = LENGTH_OF(w1_c)
+		}, {
+			.iov_base = w2,
+			.iov_len = LENGTH_OF(w2_c)
+		}
+	};
+	struct iovec *w_iov = tail_memdup(w_iov_, sizeof(w_iov_));
+	const unsigned int w_len =
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c) + LENGTH_OF(w2_c);
+
+	const struct msghdr w_mh_ = {
+		.msg_iov = w_iov,
+		.msg_iovlen = ARRAY_SIZE(w_iov_)
+	};
+	const struct msghdr *w_mh = tail_memdup(&w_mh_, sizeof(w_mh_));
+
+	assert(sendmsg(1, w_mh, 0) == (int) w_len);
+	close(1);
+	tprintf("sendmsg(1, {msg_name=NULL, msg_namelen=0, msg_iov="
+		"[{iov_base=\"%s\", iov_len=%u}, {iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}], msg_iovlen=%u"
+		", msg_controllen=0, msg_flags=0}, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 1\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 2\n"
+		" | 00000 %-49s  %-16s |\n",
+		w0_c, LENGTH_OF(w0_c),
+		w1_c, LENGTH_OF(w1_c),
+		w2_c, LENGTH_OF(w2_c),
+		ARRAY_SIZE(w_iov_), w_len,
+		LENGTH_OF(w0_c), w0_d, w0_c,
+		LENGTH_OF(w1_c), w1_d, w1_c,
+		LENGTH_OF(w2_c), w2_d, w2_c);
+
+	const unsigned int r_len = (w_len + 1) / 2;
+	void *r0 = tail_alloc(r_len);
+	const struct iovec r0_iov_[] = {
+		{
+			.iov_base = r0,
+			.iov_len = r_len
+		}
+	};
+	struct iovec *r_iov = tail_memdup(r0_iov_, sizeof(r0_iov_));
+
+	const struct msghdr r_mh_ = {
+		.msg_iov = r_iov,
+		.msg_iovlen = ARRAY_SIZE(r0_iov_)
+	};
+	struct msghdr *r_mh = tail_memdup(&r_mh_, sizeof(r_mh_));
+
+	assert(recvmsg(0, r_mh, 0) == (int) r_len);
+	tprintf("recvmsg(0, {msg_name=NULL, msg_namelen=0, msg_iov="
+		"[{iov_base=\"%s\", iov_len=%u}], msg_iovlen=%u"
+		", msg_controllen=0, msg_flags=0}, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r0_c, r_len, ARRAY_SIZE(r0_iov_), r_len, r_len, r0_d, r0_c);
+
+	void *r1 = tail_alloc(r_len);
+	void *r2 = tail_alloc(w_len);
+	const struct iovec r1_iov_[] = {
+		{
+			.iov_base = r1,
+			.iov_len = r_len
+		},
+		{
+			.iov_base = r2,
+			.iov_len = w_len
+		}
+	};
+	r_iov = tail_memdup(r1_iov_, sizeof(r1_iov_));
+	r_mh->msg_iov = r_iov;
+	r_mh->msg_iovlen = ARRAY_SIZE(r1_iov_);
+
+	assert(recvmsg(0, r_mh, 0) == (int) w_len - r_len);
+	tprintf("recvmsg(0, {msg_name=NULL, msg_namelen=0, msg_iov="
+		"[{iov_base=\"%s\", iov_len=%u}, {iov_base=\"\", iov_len=%u}]"
+		", msg_iovlen=%u, msg_controllen=0, msg_flags=0}, 0) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n",
+		r1_c, r_len, w_len, ARRAY_SIZE(r1_iov_), w_len - r_len,
+		w_len - r_len, r1_d, r1_c);
+	close(0);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
diff --git a/strace/tests/recvmsg.test b/strace/tests/recvmsg.test
new file mode 100755
index 0000000..e373a20
--- /dev/null
+++ b/strace/tests/recvmsg.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of recvmsg and sendmsg syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -eread=0 -ewrite=1 -e trace=recvmsg,sendmsg
diff --git a/strace/tests/redirect.test b/strace/tests/redirect.test
new file mode 100755
index 0000000..07fbcdf
--- /dev/null
+++ b/strace/tests/redirect.test
@@ -0,0 +1,69 @@
+#!/bin/sh
+#
+# Ensure that strace does not retain stdin and stdout descriptors.
+#
+# Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed \
+	kill -0 $$
+
+check_prog sleep
+check_prog yes
+
+> "$LOG"
+
+(
+	$SLEEP_A_BIT &
+	yes
+	if kill -0 $! 2> /dev/null; then
+		wait
+	else
+		echo TIMEOUT >> $LOG
+	fi
+) | $STRACE -qq -enone -esignal=none \
+	sh -c "exec <&- >&-; $SLEEP_A_BIT; $SLEEP_A_BIT"
+
+if [ -s "$LOG" ]; then
+	fail_ "$STRACE failed to redirect standard input"
+fi
+
+$STRACE -qq -enone -esignal=none \
+	sh -c "exec <&- >&-; $SLEEP_A_BIT; $SLEEP_A_BIT" |
+(
+	$SLEEP_A_BIT &
+	cat > /dev/null
+	if kill -0 $! 2> /dev/null; then
+		wait
+	else
+		echo TIMEOUT >> $LOG
+	fi
+)
+
+if [ -s "$LOG" ]; then
+	fail_ "$STRACE failed to redirect standard output"
+fi
diff --git a/strace/tests/remap_file_pages.c b/strace/tests/remap_file_pages.c
new file mode 100644
index 0000000..8aa099e
--- /dev/null
+++ b/strace/tests/remap_file_pages.c
@@ -0,0 +1,61 @@
+/*
+ * Check decoding of remap_file_pages syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_remap_file_pages
+
+# include <stdio.h>
+# include <sys/mman.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const unsigned long addr = (unsigned long) 0xfacefeeddeadbeef;
+	const unsigned long size = (unsigned long) 0xdefaced1bad2f00d;
+	const unsigned long prot = PROT_READ|PROT_WRITE|PROT_EXEC;
+	const unsigned long pgoff = (unsigned long) 0xcaf3babebad4deed;
+	const unsigned long flags = MAP_PRIVATE|MAP_ANONYMOUS;
+
+	long rc = syscall(__NR_remap_file_pages, addr, size, prot, pgoff, flags);
+	printf("remap_file_pages(%#lx, %lu, %s, %lu, %s) = %ld %s (%m)\n",
+	       addr, size, "PROT_READ|PROT_WRITE|PROT_EXEC", pgoff,
+	       "MAP_PRIVATE|MAP_ANONYMOUS", rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_remap_file_pages")
+
+#endif
diff --git a/strace/tests/remap_file_pages.test b/strace/tests/remap_file_pages.test
new file mode 100755
index 0000000..9d51a9a
--- /dev/null
+++ b/strace/tests/remap_file_pages.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check remap_file_pages syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/rename.c b/strace/tests/rename.c
new file mode 100644
index 0000000..a2a9209
--- /dev/null
+++ b/strace/tests/rename.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rename
+
+# include <stdio.h>
+# include <unistd.h>
+
+# define OLD_FILE "rename_old"
+# define NEW_FILE "rename_new"
+
+int
+main(void)
+{
+	long rc = syscall(__NR_rename, OLD_FILE, NEW_FILE);
+	printf("rename(\"%s\", \"%s\") = %ld %s (%m)\n",
+	       OLD_FILE, NEW_FILE, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rename")
+
+#endif
diff --git a/strace/tests/rename.test b/strace/tests/rename.test
new file mode 100755
index 0000000..9067e4c
--- /dev/null
+++ b/strace/tests/rename.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check rename syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a35
diff --git a/strace/tests/renameat.c b/strace/tests/renameat.c
new file mode 100644
index 0000000..da38f23
--- /dev/null
+++ b/strace/tests/renameat.c
@@ -0,0 +1,31 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_renameat
+
+# include <stdio.h>
+# include <unistd.h>
+
+# define OLD_FILE "renameat_old"
+# define NEW_FILE "renameat_new"
+
+int
+main(void)
+{
+	const long int fd_old = (long int) 0xdeadbeefffffffff;
+	const long int fd_new = (long int) 0xdeadbeeffffffffe;
+
+	long rc = syscall(__NR_renameat, fd_old, OLD_FILE, fd_new, NEW_FILE);
+	printf("renameat(%d, \"%s\", %d, \"%s\") = %ld %s (%m)\n",
+	       (int) fd_old, OLD_FILE, (int) fd_new, NEW_FILE,
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_renameat")
+
+#endif
diff --git a/strace/tests/renameat.test b/strace/tests/renameat.test
new file mode 100755
index 0000000..9b0a61d
--- /dev/null
+++ b/strace/tests/renameat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check renameat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/renameat2.c b/strace/tests/renameat2.c
new file mode 100644
index 0000000..28a1b5b
--- /dev/null
+++ b/strace/tests/renameat2.c
@@ -0,0 +1,62 @@
+/*
+ * Check decoding of renameat2 syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_renameat2
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char oldpath[] = "renameat2_oldpath";
+	static const char newpath[] = "renameat2_newpath";
+	const unsigned long olddirfd =
+		(unsigned long) 0xfacefeedffffffff;
+	const unsigned long newdirfd =
+		(unsigned long) 0xfacefeed00000000 | -100U;
+
+	long rc = syscall(__NR_renameat2,
+			  olddirfd, oldpath, newdirfd, newpath, 1);
+	printf("renameat2(%d, \"%s\", AT_FDCWD, \"%s\", RENAME_NOREPLACE)"
+	       " = %ld %s (%m)\n",
+	       (int) olddirfd, oldpath, newpath, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_renameat2")
+
+#endif
diff --git a/strace/tests/renameat2.test b/strace/tests/renameat2.test
new file mode 100755
index 0000000..4c176bb
--- /dev/null
+++ b/strace/tests/renameat2.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check renameat2 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/restart_syscall.c b/strace/tests/restart_syscall.c
new file mode 100644
index 0000000..3f07d78
--- /dev/null
+++ b/strace/tests/restart_syscall.c
@@ -0,0 +1,77 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <signal.h>
+#include <time.h>
+#include <sys/time.h>
+
+int
+main(void)
+{
+#if defined __x86_64__ && defined __ILP32__
+	/*
+	 * x32 is broken from the beginning:
+	 * https://lkml.org/lkml/2015/11/30/790
+	 */
+	error_msg_and_skip("x32 is broken");
+#else
+	const sigset_t set = {};
+	const struct sigaction act = { .sa_handler = SIG_IGN };
+	const struct itimerval itv = { .it_value.tv_usec = 111111 };
+	struct timespec req = { .tv_nsec = 222222222 }, rem;
+
+	assert(sigaction(SIGALRM, &act, NULL) == 0);
+	assert(sigprocmask(SIG_SETMASK, &set, NULL) == 0);
+	if (setitimer(ITIMER_REAL, &itv, NULL))
+		perror_msg_and_skip("setitimer");
+	if (nanosleep(&req, &rem))
+		perror_msg_and_fail("nanosleep");
+
+	printf("nanosleep\\(\\{%jd, %jd\\}, \\{%jd, %jd\\}\\)"
+	       " = \\? ERESTART_RESTARTBLOCK \\(Interrupted by signal\\)\n",
+	       (intmax_t) req.tv_sec, (intmax_t) req.tv_nsec,
+	       (intmax_t) rem.tv_sec, (intmax_t) rem.tv_nsec);
+	puts("--- SIGALRM \\{si_signo=SIGALRM, si_code=SI_KERNEL\\} ---");
+#ifdef __arm__
+/* old kernels used to overwrite ARM_r0 with -EINTR */
+# define ALTERNATIVE_NANOSLEEP_REQ "0xfffffffc|"
+#else
+# define ALTERNATIVE_NANOSLEEP_REQ ""
+#endif
+	printf("(nanosleep\\((%s\\{%jd, %jd\\}), %p|restart_syscall\\(<\\.\\.\\."
+	       " resuming interrupted nanosleep \\.\\.\\.>)\\) = 0\n",
+	       ALTERNATIVE_NANOSLEEP_REQ,
+	       (intmax_t) req.tv_sec, (intmax_t) req.tv_nsec, &rem);
+
+	puts("\\+\\+\\+ exited with 0 \\+\\+\\+");
+	return 0;
+#endif
+}
diff --git a/strace/tests/restart_syscall.test b/strace/tests/restart_syscall.test
new file mode 100755
index 0000000..6dfda16
--- /dev/null
+++ b/strace/tests/restart_syscall.test
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+# Check how "resuming interrupted nanosleep" works.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+syscalls=nanosleep,restart_syscall
+run_strace -a20 -e trace=$syscalls $args > "$OUT"
+match_grep "$LOG" "$OUT"
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/rmdir.c b/strace/tests/rmdir.c
new file mode 100644
index 0000000..e5a7f1d
--- /dev/null
+++ b/strace/tests/rmdir.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rmdir
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "rmdir_sample";
+	long rc = syscall(__NR_rmdir, sample);
+	printf("rmdir(\"%s\") = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rmdir")
+
+#endif
diff --git a/strace/tests/rmdir.test b/strace/tests/rmdir.test
new file mode 100755
index 0000000..81ee66b
--- /dev/null
+++ b/strace/tests/rmdir.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check rmdir syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22
diff --git a/strace/tests/rt_sigpending.c b/strace/tests/rt_sigpending.c
new file mode 100644
index 0000000..a6381cd
--- /dev/null
+++ b/strace/tests/rt_sigpending.c
@@ -0,0 +1,128 @@
+/*
+ * This file is part of rt_sigpending strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rt_sigpending
+
+# include <assert.h>
+# include <signal.h>
+# include <stdio.h>
+# include <string.h>
+# include <unistd.h>
+
+static long
+k_sigpending(void *const set, const unsigned long size)
+{
+	return syscall(__NR_rt_sigpending, set, size);
+}
+
+static void
+iterate(const char *const text, unsigned int size, void *set)
+{
+	for (;;) {
+		if (k_sigpending(set, size)) {
+			tprintf("rt_sigpending(%p, %u) = -1 EFAULT (%m)\n",
+				set, size);
+			break;
+		}
+		if (size) {
+#if WORDS_BIGENDIAN
+			if (size < sizeof(long))
+				tprintf("rt_sigpending(%s, %u) = 0\n",
+					"[]", size);
+			else
+#endif
+				tprintf("rt_sigpending(%s, %u) = 0\n",
+					text, size);
+		} else {
+			tprintf("rt_sigpending(%p, %u) = 0\n", set, size);
+			break;
+		}
+		size >>= 1;
+		set += size;
+	}
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	const unsigned int big_size = 1024 / 8;
+	void *k_set = tail_alloc(big_size);
+	sigset_t *const libc_set = tail_alloc(sizeof(sigset_t));
+
+	sigemptyset(libc_set);
+	if (sigprocmask(SIG_SETMASK, libc_set, NULL))
+		perror_msg_and_fail("sigprocmask");
+
+	memset(k_set, 0, big_size);
+	unsigned int set_size = big_size;
+	for (; set_size; set_size >>= 1, k_set += set_size) {
+		if (!k_sigpending(k_set, set_size))
+			break;
+		tprintf("rt_sigpending(%p, %u) = -1 EINVAL (%m)\n",
+			k_set, set_size);
+	}
+	if (!set_size)
+		perror_msg_and_fail("rt_sigpending");
+	tprintf("rt_sigpending(%s, %u) = 0\n", "[]", set_size);
+
+	iterate("[]", set_size >> 1, k_set + (set_size >> 1));
+
+	void *const efault = k_set + (set_size >> 1);
+	assert(k_sigpending(efault, set_size) == -1);
+	tprintf("rt_sigpending(%p, %u) = -1 EFAULT (%m)\n",
+		efault, set_size);
+
+	sigaddset(libc_set, SIGHUP);
+	if (sigprocmask(SIG_SETMASK, libc_set, NULL))
+		perror_msg_and_fail("sigprocmask");
+	raise(SIGHUP);
+
+	iterate("[HUP]", set_size, k_set);
+
+	sigaddset(libc_set, SIGINT);
+	if (sigprocmask(SIG_SETMASK, libc_set, NULL))
+		perror_msg_and_fail("sigprocmask");
+	raise(SIGINT);
+
+	iterate("[HUP INT]", set_size, k_set);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rt_sigpending")
+
+#endif
diff --git a/strace/tests/rt_sigpending.test b/strace/tests/rt_sigpending.test
new file mode 100755
index 0000000..40c83a8
--- /dev/null
+++ b/strace/tests/rt_sigpending.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check rt_sigpending syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20
diff --git a/strace/tests/rt_sigprocmask.c b/strace/tests/rt_sigprocmask.c
new file mode 100644
index 0000000..ab92cde
--- /dev/null
+++ b/strace/tests/rt_sigprocmask.c
@@ -0,0 +1,174 @@
+/*
+ * This file is part of rt_sigprocmask strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rt_sigprocmask
+
+# include <assert.h>
+# include <signal.h>
+# include <stdio.h>
+# include <string.h>
+# include <unistd.h>
+
+static long
+k_sigprocmask(const unsigned long how, void *const new_set,
+	      void *const old_set, const unsigned long size)
+{
+	return syscall(__NR_rt_sigprocmask, how, new_set, old_set, size);
+}
+
+static void
+iterate(const char *const text, void *set, void *old, unsigned int size)
+{
+	for (;;) {
+		if (k_sigprocmask(SIG_UNBLOCK, set, old, size)) {
+			if (size < sizeof(long))
+				tprintf("rt_sigprocmask(SIG_UNBLOCK"
+					", %p, %p, %u) = -1 EINVAL (%m)\n",
+					set, old, size);
+			else
+				tprintf("rt_sigprocmask(SIG_UNBLOCK"
+					", %s, %p, %u) = -1 EINVAL (%m)\n",
+					text, old, size);
+		} else {
+			tprintf("rt_sigprocmask(SIG_UNBLOCK, %s, [], %u)"
+				" = 0\n", text, size);
+		}
+		if (!size)
+			break;
+		size >>= 1;
+		set += size;
+		old += size;
+	}
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	const unsigned int big_size = 1024 / 8;
+	unsigned int set_size;
+
+	for (set_size = big_size; set_size; set_size >>= 1) {
+		if (!k_sigprocmask(SIG_SETMASK, NULL, NULL, set_size))
+			break;
+		tprintf("rt_sigprocmask(SIG_SETMASK, NULL, NULL, %u)"
+			" = -1 EINVAL (%m)\n", set_size);
+	}
+	if (!set_size)
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_SETMASK, NULL, NULL, %u) = 0\n",
+		set_size);
+
+	void *const k_set = tail_alloc(set_size);
+	void *const old_set = tail_alloc(set_size);
+	sigset_t *const libc_set = tail_alloc(sizeof(sigset_t));
+
+	memset(k_set, 0, set_size);
+	if (k_sigprocmask(SIG_SETMASK, k_set, NULL, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_SETMASK, [], NULL, %u) = 0\n", set_size);
+
+	if (k_sigprocmask(SIG_UNBLOCK, k_set - set_size, old_set, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_UNBLOCK, ~[], [], %u) = 0\n", set_size);
+
+	assert(k_sigprocmask(SIG_SETMASK, k_set - set_size,
+			     old_set, set_size << 1) == -1);
+	tprintf("rt_sigprocmask(SIG_SETMASK, %p, %p, %u) = -1 EINVAL (%m)\n",
+		k_set - set_size, old_set, set_size << 1);
+
+	iterate("~[]", k_set - set_size, old_set, set_size >> 1);
+
+	sigemptyset(libc_set);
+	sigaddset(libc_set, SIGHUP);
+	memcpy(k_set, libc_set, set_size);
+
+	if (k_sigprocmask(SIG_BLOCK, k_set, old_set, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_BLOCK, [HUP], [], %u) = 0\n", set_size);
+
+	memset(libc_set, -1, sizeof(sigset_t));
+	sigdelset(libc_set, SIGHUP);
+	memcpy(k_set, libc_set, set_size);
+
+	if (k_sigprocmask(SIG_UNBLOCK, k_set, old_set, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_UNBLOCK, ~[HUP], [HUP], %u) = 0\n",
+		set_size);
+
+	sigdelset(libc_set, SIGKILL);
+	memcpy(k_set, libc_set, set_size);
+
+	if (k_sigprocmask(SIG_UNBLOCK, k_set, old_set, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_UNBLOCK, ~[HUP KILL], [HUP], %u) = 0\n",
+		set_size);
+
+	sigemptyset(libc_set);
+	sigaddset(libc_set, SIGHUP);
+	sigaddset(libc_set, SIGINT);
+	sigaddset(libc_set, SIGQUIT);
+	sigaddset(libc_set, SIGALRM);
+	sigaddset(libc_set, SIGTERM);
+	memcpy(k_set, libc_set, set_size);
+
+	if (k_sigprocmask(SIG_BLOCK, k_set, old_set, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_BLOCK, %s, [HUP], %u) = 0\n",
+		"[HUP INT QUIT ALRM TERM]", set_size);
+
+	if (k_sigprocmask(SIG_SETMASK, NULL, old_set, set_size))
+		perror_msg_and_fail("rt_sigprocmask");
+	tprintf("rt_sigprocmask(SIG_SETMASK, NULL, %s, %u) = 0\n",
+		"[HUP INT QUIT ALRM TERM]", set_size);
+
+	assert(k_sigprocmask(SIG_SETMASK, k_set + (set_size >> 1), NULL,
+			     set_size) == -1);
+	tprintf("rt_sigprocmask(SIG_SETMASK, %p, NULL, %u) = -1 EFAULT (%m)\n",
+		k_set + (set_size >> 1), set_size);
+
+	assert(k_sigprocmask(SIG_SETMASK, k_set, old_set + (set_size >> 1),
+			     set_size) == -1);
+	tprintf("rt_sigprocmask(SIG_SETMASK, %s, %p, %u) = -1 EFAULT (%m)\n",
+		"[HUP INT QUIT ALRM TERM]",
+		old_set + (set_size >> 1), set_size);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rt_sigprocmask")
+
+#endif
diff --git a/strace/tests/rt_sigprocmask.test b/strace/tests/rt_sigprocmask.test
new file mode 100755
index 0000000..1e60ebd
--- /dev/null
+++ b/strace/tests/rt_sigprocmask.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check rt_sigprocmask syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/rt_sigqueueinfo.c b/strace/tests/rt_sigqueueinfo.c
new file mode 100644
index 0000000..9ca860a
--- /dev/null
+++ b/strace/tests/rt_sigqueueinfo.c
@@ -0,0 +1,55 @@
+/*
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <signal.h>
+#include <unistd.h>
+
+int
+main (void)
+{
+	struct sigaction sa = {
+		.sa_handler = SIG_IGN
+	};
+	union sigval value = {
+		.sival_ptr = (void *) (unsigned long) 0xdeadbeefbadc0ded
+	};
+	pid_t pid = getpid();
+
+	assert(sigaction(SIGUSR1, &sa, NULL) == 0);
+	if (sigqueue(pid, SIGUSR1, value))
+		perror_msg_and_skip("sigqueue");
+	printf("rt_sigqueueinfo(%u, SIGUSR1, {si_signo=SIGUSR1, "
+		"si_code=SI_QUEUE, si_pid=%u, si_uid=%u, "
+		"si_value={int=%d, ptr=%p}}) = 0\n",
+		pid, pid, getuid(), value.sival_int, value.sival_ptr);
+	printf("+++ exited with 0 +++\n");
+
+	return 0;
+}
diff --git a/strace/tests/rt_sigqueueinfo.test b/strace/tests/rt_sigqueueinfo.test
new file mode 100755
index 0000000..c03c76f
--- /dev/null
+++ b/strace/tests/rt_sigqueueinfo.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of rt_sigqueueinfo syscall
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -esignal=none
diff --git a/strace/tests/rt_sigsuspend.c b/strace/tests/rt_sigsuspend.c
new file mode 100644
index 0000000..b96a8c9
--- /dev/null
+++ b/strace/tests/rt_sigsuspend.c
@@ -0,0 +1,165 @@
+/*
+ * This file is part of rt_sigsuspend strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rt_sigsuspend
+
+# include <assert.h>
+# include <errno.h>
+# include <signal.h>
+# include <stdio.h>
+# include <stdint.h>
+# include <string.h>
+# include <unistd.h>
+
+static long
+k_sigsuspend(const sigset_t *const set, const unsigned long size)
+{
+	return syscall(__NR_rt_sigsuspend, set, size);
+}
+
+static void
+iterate(const char *const text, const int sig,
+	const void *const set, unsigned int size)
+{
+	const void *mask;
+
+	for (mask = set;; size >>= 1, mask += size) {
+		raise(sig);
+		assert(k_sigsuspend(mask, size) == -1);
+		if (EINTR == errno) {
+			tprintf("rt_sigsuspend(%s, %u) = ? ERESTARTNOHAND"
+				" (To be restarted if no handler)\n",
+				text, size);
+		} else {
+			if (size < sizeof(long))
+				tprintf("rt_sigsuspend(%p, %u)"
+					" = -1 EINVAL (%m)\n",
+					mask, size);
+			else
+				tprintf("rt_sigsuspend(%s, %u)"
+					" = -1 EINVAL (%m)\n",
+					set == mask ? text : "~[]", size);
+		}
+		if (!size)
+			break;
+	}
+}
+
+static void
+handler(int signo)
+{
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	const unsigned int big_size = 1024 / 8;
+	void *k_set = tail_alloc(big_size);
+	memset(k_set, 0, big_size);
+
+	sigset_t *const libc_set = tail_alloc(sizeof(sigset_t));
+	sigemptyset(libc_set);
+	sigaddset(libc_set, SIGUSR1);
+	if (sigprocmask(SIG_SETMASK, libc_set, NULL))
+		perror_msg_and_fail("sigprocmask");
+
+	const struct sigaction sa = {
+		.sa_handler = handler
+	};
+	if (sigaction(SIGUSR1, &sa, NULL))
+		perror_msg_and_fail("sigaction");
+
+	raise(SIGUSR1);
+	unsigned int set_size = big_size;
+	for (; set_size; set_size >>= 1, k_set += set_size) {
+		assert(k_sigsuspend(k_set, set_size) == -1);
+		if (EINTR == errno)
+			break;
+		tprintf("rt_sigsuspend(%p, %u) = -1 EINVAL (%m)\n",
+			k_set, set_size);
+	}
+	if (!set_size)
+		perror_msg_and_fail("rt_sigsuspend");
+	tprintf("rt_sigsuspend([], %u) = ? ERESTARTNOHAND"
+		" (To be restarted if no handler)\n", set_size);
+
+	sigemptyset(libc_set);
+	sigaddset(libc_set, SIGUSR2);
+	memcpy(k_set, libc_set, set_size);
+	raise(SIGUSR1);
+	assert(k_sigsuspend(k_set, set_size) == -1);
+	assert(EINTR == errno);
+	tprintf("rt_sigsuspend([USR2], %u) = ? ERESTARTNOHAND"
+		" (To be restarted if no handler)\n", set_size);
+
+	sigaddset(libc_set, SIGHUP);
+	memcpy(k_set, libc_set, set_size);
+	raise(SIGUSR1);
+	assert(k_sigsuspend(k_set, set_size) == -1);
+	assert(EINTR == errno);
+	tprintf("rt_sigsuspend([HUP USR2], %u) = ? ERESTARTNOHAND"
+		" (To be restarted if no handler)\n", set_size);
+
+	sigaddset(libc_set, SIGINT);
+	memcpy(k_set, libc_set, set_size);
+	raise(SIGUSR1);
+	assert(k_sigsuspend(k_set, set_size) == -1);
+	assert(EINTR == errno);
+	tprintf("rt_sigsuspend([HUP INT USR2], %u) = ? ERESTARTNOHAND"
+		" (To be restarted if no handler)\n", set_size);
+
+	memset(libc_set, -1, sizeof(*libc_set));
+	sigdelset(libc_set, SIGUSR1);
+	memcpy(k_set, libc_set, set_size);
+	raise(SIGUSR1);
+	assert(k_sigsuspend(k_set, set_size) == -1);
+	assert(EINTR == errno);
+	tprintf("rt_sigsuspend(~[USR1], %u) = ? ERESTARTNOHAND"
+		" (To be restarted if no handler)\n", set_size);
+
+	assert(k_sigsuspend(k_set - set_size, set_size << 1) == -1);
+	tprintf("rt_sigsuspend(%p, %u) = -1 EINVAL (%m)\n",
+		k_set - set_size, set_size << 1);
+
+	iterate("~[USR1]", SIGUSR1, k_set, set_size >> 1);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rt_sigsuspend")
+
+#endif
diff --git a/strace/tests/rt_sigsuspend.test b/strace/tests/rt_sigsuspend.test
new file mode 100755
index 0000000..2e30fd4
--- /dev/null
+++ b/strace/tests/rt_sigsuspend.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check rt_sigsuspend syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20 -esignal=none
diff --git a/strace/tests/rt_sigtimedwait.c b/strace/tests/rt_sigtimedwait.c
new file mode 100644
index 0000000..6136b7c
--- /dev/null
+++ b/strace/tests/rt_sigtimedwait.c
@@ -0,0 +1,182 @@
+/*
+ * This file is part of rt_sigtimedwait strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rt_sigtimedwait
+
+# include <assert.h>
+# include <errno.h>
+# include <signal.h>
+# include <stdio.h>
+# include <stdint.h>
+# include <string.h>
+# include <unistd.h>
+
+static long
+k_sigtimedwait(const sigset_t *const set, siginfo_t *const info,
+	       const struct timespec *const timeout, const unsigned long size)
+{
+	return syscall(__NR_rt_sigtimedwait, set, info, timeout, size);
+}
+
+static void
+iterate(const char *const text, const void *set,
+	const struct timespec *const timeout, unsigned int size)
+{
+	for (;;) {
+		assert(k_sigtimedwait(set, NULL, timeout, size) == -1);
+		if (EINTR == errno) {
+			tprintf("rt_sigtimedwait(%s, NULL, {%jd, %jd}, %u)"
+				" = -1 EAGAIN (%m)\n", text,
+				(intmax_t) timeout->tv_sec,
+				(intmax_t) timeout->tv_nsec,
+				size);
+		} else {
+			if (size < sizeof(long))
+				tprintf("rt_sigtimedwait(%p, NULL, {%jd, %jd}"
+					", %u) = -1 EINVAL (%m)\n",
+					set, (intmax_t) timeout->tv_sec,
+					(intmax_t) timeout->tv_nsec, size);
+			else
+				tprintf("rt_sigtimedwait(%s, NULL, {%jd, %jd}"
+					", %u) = -1 EINVAL (%m)\n",
+					text, (intmax_t) timeout->tv_sec,
+					(intmax_t) timeout->tv_nsec, size);
+		}
+		if (!size)
+			break;
+		size >>= 1;
+		set += size;
+	}
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	siginfo_t *const info = tail_alloc(sizeof(*info));
+	struct timespec *const timeout = tail_alloc(sizeof(*timeout));
+	timeout->tv_sec = 0;
+	timeout->tv_nsec = 42;
+
+	const unsigned int big_size = 1024 / 8;
+	void *k_set = tail_alloc(big_size);
+	memset(k_set, 0, big_size);
+
+	unsigned int set_size = big_size;
+	for (; set_size; set_size >>= 1, k_set += set_size) {
+		assert(k_sigtimedwait(k_set, NULL, timeout, set_size) == -1);
+		if (EAGAIN == errno)
+			break;
+		tprintf("rt_sigtimedwait(%p, NULL, {%jd, %jd}, %u)"
+			" = -1 EINVAL (%m)\n",
+			k_set, (intmax_t) timeout->tv_sec,
+			(intmax_t) timeout->tv_nsec, set_size);
+	}
+	if (!set_size)
+		perror_msg_and_fail("rt_sigtimedwait");
+	tprintf("rt_sigtimedwait([], NULL, {%jd, %jd}, %u) = -1 EAGAIN (%m)\n",
+		(intmax_t) timeout->tv_sec, (intmax_t) timeout->tv_nsec,
+		set_size);
+
+	sigset_t *const libc_set = tail_alloc(sizeof(sigset_t));
+	sigemptyset(libc_set);
+	sigaddset(libc_set, SIGHUP);
+	memcpy(k_set, libc_set, set_size);
+
+	assert(k_sigtimedwait(k_set, info, timeout, set_size) == -1);
+	assert(EAGAIN == errno);
+	tprintf("rt_sigtimedwait([HUP], %p, {%jd, %jd}, %u) = -1 EAGAIN (%m)\n",
+		info, (intmax_t) timeout->tv_sec,
+		(intmax_t) timeout->tv_nsec, set_size);
+
+	sigaddset(libc_set, SIGINT);
+	memcpy(k_set, libc_set, set_size);
+
+	assert(k_sigtimedwait(k_set, info, timeout, set_size) == -1);
+	assert(EAGAIN == errno);
+	tprintf("rt_sigtimedwait([HUP INT], %p, {%jd, %jd}, %u)"
+		" = -1 EAGAIN (%m)\n",
+		info, (intmax_t) timeout->tv_sec,
+		(intmax_t) timeout->tv_nsec, set_size);
+
+	sigaddset(libc_set, SIGQUIT);
+	sigaddset(libc_set, SIGALRM);
+	sigaddset(libc_set, SIGTERM);
+	memcpy(k_set, libc_set, set_size);
+
+	assert(k_sigtimedwait(k_set, info, timeout, set_size) == -1);
+	assert(EAGAIN == errno);
+	tprintf("rt_sigtimedwait(%s, %p, {%jd, %jd}, %u) = -1 EAGAIN (%m)\n",
+		"[HUP INT QUIT ALRM TERM]",
+		info, (intmax_t) timeout->tv_sec,
+		(intmax_t) timeout->tv_nsec, set_size);
+
+	memset(k_set - set_size, -1, set_size);
+	assert(k_sigtimedwait(k_set - set_size, info, timeout, set_size) == -1);
+	assert(EAGAIN == errno);
+	tprintf("rt_sigtimedwait(~[], %p, {%jd, %jd}, %u) = -1 EAGAIN (%m)\n",
+		info, (intmax_t) timeout->tv_sec,
+		(intmax_t) timeout->tv_nsec, set_size);
+
+	if (sigprocmask(SIG_SETMASK, libc_set, NULL))
+		perror_msg_and_fail("sigprocmask");
+
+	assert(k_sigtimedwait(k_set - set_size, info, NULL, set_size << 1) == -1);
+	tprintf("rt_sigtimedwait(%p, %p, NULL, %u) = -1 EINVAL (%m)\n",
+		k_set - set_size, info, set_size << 1);
+
+	iterate("~[]", k_set - set_size, timeout, set_size >> 1);
+
+	timeout->tv_sec = 1;
+	raise(SIGALRM);
+	assert(k_sigtimedwait(k_set, info, timeout, set_size) == SIGALRM);
+	tprintf("rt_sigtimedwait(%s, {si_signo=%s, si_code=SI_TKILL"
+		", si_pid=%d, si_uid=%d}, {%jd, %jd}, %u) = %d (%s)\n",
+		"[HUP INT QUIT ALRM TERM]", "SIGALRM", getpid(), getuid(),
+		(intmax_t) timeout->tv_sec, (intmax_t) timeout->tv_nsec,
+		set_size, SIGALRM, "SIGALRM");
+
+	raise(SIGALRM);
+	assert(k_sigtimedwait(k_set, NULL, NULL, set_size) == SIGALRM);
+	tprintf("rt_sigtimedwait(%s, NULL, NULL, %u) = %d (%s)\n",
+		"[HUP INT QUIT ALRM TERM]", set_size, SIGALRM, "SIGALRM");
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rt_sigtimedwait")
+
+#endif
diff --git a/strace/tests/rt_sigtimedwait.test b/strace/tests/rt_sigtimedwait.test
new file mode 100755
index 0000000..e15fb77
--- /dev/null
+++ b/strace/tests/rt_sigtimedwait.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check rt_sigtimedwait syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a38
diff --git a/strace/tests/rt_tgsigqueueinfo.c b/strace/tests/rt_tgsigqueueinfo.c
new file mode 100644
index 0000000..0926fb1
--- /dev/null
+++ b/strace/tests/rt_tgsigqueueinfo.c
@@ -0,0 +1,87 @@
+/*
+ * This file is part of rt_tgsigqueueinfo strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_rt_tgsigqueueinfo
+
+# include <errno.h>
+# include <signal.h>
+# include <stdio.h>
+# include <string.h>
+# include <unistd.h>
+
+static long
+k_tgsigqueueinfo(const pid_t pid, const int sig, const void const *info)
+{
+	return syscall(__NR_rt_tgsigqueueinfo,
+		       (unsigned long) 0xffffffff00000000 | pid,
+		       (unsigned long) 0xffffffff00000000 | pid,
+		       (unsigned long) 0xffffffff00000000 | sig,
+		       info);
+}
+
+int
+main (void)
+{
+	const struct sigaction sa = {
+		.sa_handler = SIG_IGN
+	};
+	if (sigaction(SIGUSR1, &sa, NULL))
+		perror_msg_and_fail("sigaction");
+
+	siginfo_t *const info = tail_alloc(sizeof(*info));
+	memset(info, 0, sizeof(*info));
+	info->si_signo = SIGUSR1;
+	info->si_errno = ENOENT;
+	info->si_code = SI_QUEUE;
+	info->si_pid = getpid();
+	info->si_uid = getuid();
+	info->si_value.sival_ptr = (void *) (unsigned long) 0xdeadbeeffacefeed;
+
+	if (k_tgsigqueueinfo(info->si_pid, SIGUSR1, info))
+		perror_msg_and_fail("rt_tgsigqueueinfo");
+
+	printf("rt_tgsigqueueinfo(%u, %u, %s, {si_signo=%s"
+		", si_code=SI_QUEUE, si_errno=ENOENT, si_pid=%u"
+		", si_uid=%u, si_value={int=%d, ptr=%p}}) = 0\n",
+		info->si_pid, info->si_pid, "SIGUSR1", "SIGUSR1",
+		info->si_pid, info->si_uid, info->si_value.sival_int,
+		info->si_value.sival_ptr);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_rt_tgsigqueueinfo")
+
+#endif
diff --git a/strace/tests/rt_tgsigqueueinfo.test b/strace/tests/rt_tgsigqueueinfo.test
new file mode 100755
index 0000000..ab24e2d
--- /dev/null
+++ b/strace/tests/rt_tgsigqueueinfo.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of rt_tgsigqueueinfo syscall
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -esignal=none
diff --git a/strace/tests/run.sh b/strace/tests/run.sh
new file mode 100755
index 0000000..02d9912
--- /dev/null
+++ b/strace/tests/run.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+. "${srcdir=.}/init.sh"
+
+$STRACE -V > /dev/null ||
+	framework_failure_ "$STRACE is not available"
+
+TIMEOUT="timeout -s 9 $TIMEOUT_DURATION"
+$TIMEOUT true > /dev/null 2>&1 ||
+	TIMEOUT=
+
+exec $TIMEOUT "$@"
diff --git a/strace/tests/sched_get_priority_mxx.c b/strace/tests/sched_get_priority_mxx.c
new file mode 100644
index 0000000..7145317
--- /dev/null
+++ b/strace/tests/sched_get_priority_mxx.c
@@ -0,0 +1,29 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#if defined(__NR_sched_get_priority_min) \
+ && defined(__NR_sched_get_priority_max)
+
+# include <sched.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	int rc = syscall(__NR_sched_get_priority_min, SCHED_FIFO);
+	printf("sched_get_priority_min(SCHED_FIFO) = %d\n", rc);
+
+	rc = syscall(__NR_sched_get_priority_max, SCHED_RR);
+	printf("sched_get_priority_max(SCHED_RR) = %d\n", rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_get_priority_min"
+                    " && defined __NR_sched_get_priority_max");
+
+#endif
diff --git a/strace/tests/sched_get_priority_mxx.test b/strace/tests/sched_get_priority_mxx.test
new file mode 100755
index 0000000..0d1a1a7
--- /dev/null
+++ b/strace/tests/sched_get_priority_mxx.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sched_get_priority_min and sched_get_priority_max syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a33 -e trace=sched_get_priority_min,sched_get_priority_max
diff --git a/strace/tests/sched_rr_get_interval.c b/strace/tests/sched_rr_get_interval.c
new file mode 100644
index 0000000..dd069e2
--- /dev/null
+++ b/strace/tests/sched_rr_get_interval.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_sched_rr_get_interval
+
+# include <stdio.h>
+# include <sched.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	struct timespec *const tp = tail_alloc(sizeof(struct timespec));
+	long rc = syscall(__NR_sched_rr_get_interval, -1, tp);
+	printf("sched_rr_get_interval(-1, %p) = %ld %s (%m)\n",
+	       tp, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_rr_get_interval")
+
+#endif
diff --git a/strace/tests/sched_rr_get_interval.test b/strace/tests/sched_rr_get_interval.test
new file mode 100755
index 0000000..828ba5d
--- /dev/null
+++ b/strace/tests/sched_rr_get_interval.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sched_rr_get_interval syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a31
diff --git a/strace/tests/sched_xetaffinity.c b/strace/tests/sched_xetaffinity.c
new file mode 100644
index 0000000..8851a4a
--- /dev/null
+++ b/strace/tests/sched_xetaffinity.c
@@ -0,0 +1,121 @@
+/*
+ * This file is part of sched_xetaffinity strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+#include <sched.h>
+
+#if defined __NR_sched_getaffinity && defined __NR_sched_setaffinity \
+ && defined CPU_ISSET_S && defined CPU_ZERO_S && defined CPU_SET_S
+
+# include <assert.h>
+# include <errno.h>
+# include <stdio.h>
+# include <unistd.h>
+
+static int
+getaffinity(unsigned long pid, unsigned long size, void *set)
+{
+	return syscall(__NR_sched_getaffinity, pid, size, set);
+}
+
+static int
+setaffinity(unsigned long pid, unsigned long size, void *set)
+{
+	return syscall(__NR_sched_setaffinity, pid, size, set);
+}
+
+int
+main(void)
+{
+	unsigned int cpuset_size = 1;
+	const pid_t pid = getpid();
+
+	while (cpuset_size) {
+		assert(getaffinity(pid, cpuset_size, NULL) == -1);
+		if (EFAULT == errno)
+			break;
+		if (EINVAL != errno)
+			perror_msg_and_skip("sched_getaffinity");
+		printf("sched_getaffinity(%d, %u, NULL) = -1 EINVAL (%m)\n",
+		       pid, cpuset_size);
+		cpuset_size <<= 1;
+	}
+	assert(cpuset_size);
+	printf("sched_getaffinity(%d, %u, NULL) = -1 EFAULT (%m)\n",
+	       pid, cpuset_size);
+
+	cpu_set_t *cpuset = tail_alloc(cpuset_size);
+	assert(getaffinity(pid, cpuset_size, cpuset + 1) == -1);
+	printf("sched_getaffinity(%d, %u, %p) = -1 EFAULT (%m)\n",
+		pid, cpuset_size, cpuset + 1);
+
+	assert(getaffinity(pid, cpuset_size, cpuset) == (int) cpuset_size);
+	printf("sched_getaffinity(%d, %u, [", pid, cpuset_size);
+	const char *sep;
+	unsigned int i, cpu;
+	for (i = 0, cpu = 0, sep = ""; i < cpuset_size * 8; ++i) {
+		if (CPU_ISSET_S(i, cpuset_size, cpuset)) {
+			printf("%s%u", sep, i);
+			sep = " ";
+			cpu = i;
+		}
+	}
+	printf("]) = %u\n", cpuset_size);
+
+	CPU_ZERO_S(cpuset_size, cpuset);
+	CPU_SET_S(cpu, cpuset_size, cpuset);
+	if (setaffinity(pid, cpuset_size, cpuset))
+		perror_msg_and_skip("sched_setaffinity");
+	printf("sched_setaffinity(%d, %u, [%u]) = 0\n",
+	       pid, cpuset_size, cpu);
+
+	const unsigned int big_size = cpuset_size < 128 ? 128 : cpuset_size * 2;
+	cpuset = tail_alloc(big_size);
+	const int ret_size = getaffinity(pid, big_size, cpuset);
+	assert(ret_size >= (int) cpuset_size && ret_size <= (int) big_size);
+	printf("sched_getaffinity(%d, %u, [", pid, big_size);
+	for (i = 0, sep = ""; i < (unsigned) ret_size * 8; ++i) {
+		if (CPU_ISSET_S(i, (unsigned) ret_size, cpuset)) {
+			printf("%s%u", sep, i);
+			sep = " ";
+		}
+	}
+	printf("]) = %d\n", ret_size);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_getaffinity && __NR_sched_setaffinity"
+		    " && CPU_ISSET_S && CPU_ZERO_S && CPU_SET_S")
+
+#endif
diff --git a/strace/tests/sched_xetaffinity.test b/strace/tests/sched_xetaffinity.test
new file mode 100755
index 0000000..246ea21
--- /dev/null
+++ b/strace/tests/sched_xetaffinity.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sched_getaffinity and sched_setaffinity syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28 -e trace=sched_getaffinity,sched_setaffinity
diff --git a/strace/tests/sched_xetattr.c b/strace/tests/sched_xetattr.c
new file mode 100644
index 0000000..c06e9b2
--- /dev/null
+++ b/strace/tests/sched_xetattr.c
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_sched_getattr && defined __NR_sched_setattr
+
+# include <inttypes.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static union {
+		struct {
+			uint32_t size;
+			uint32_t sched_policy;
+			uint64_t sched_flags;
+			uint32_t sched_nice;
+			uint32_t sched_priority;
+			uint64_t sched_runtime;
+			uint64_t sched_deadline;
+			uint64_t sched_period;
+		} attr;
+		char buf[256];
+	} sched;
+
+	if (syscall(__NR_sched_getattr, 0, &sched, sizeof(sched), 0))
+		perror_msg_and_skip("sched_getattr");
+
+	printf("sched_getattr\\(0, \\{size=%u, sched_policy=SCHED_[A-Z]+, sched_flags=%s, sched_nice=%u, sched_priority=%u, sched_runtime=%" PRIu64 ", sched_deadline=%" PRIu64 ", sched_period=%" PRIu64 "\\}, 256, 0\\) += 0\n",
+		sched.attr.size,
+		sched.attr.sched_flags ? "SCHED_FLAG_RESET_ON_FORK" : "0",
+		sched.attr.sched_nice,
+		sched.attr.sched_priority,
+		sched.attr.sched_runtime,
+		sched.attr.sched_deadline,
+		sched.attr.sched_period);
+
+	sched.attr.sched_flags |= 1;
+	if (syscall(__NR_sched_setattr, 0, &sched, 0))
+		perror_msg_and_skip("sched_setattr");
+
+	printf("sched_setattr\\(0, \\{size=%u, sched_policy=SCHED_[A-Z]+, sched_flags=%s, sched_nice=%u, sched_priority=%u, sched_runtime=%" PRIu64 ", sched_deadline=%" PRIu64 ", sched_period=%" PRIu64 "\\}, 0\\) += 0\n",
+		sched.attr.size,
+		"SCHED_FLAG_RESET_ON_FORK",
+		sched.attr.sched_nice,
+		sched.attr.sched_priority,
+		sched.attr.sched_runtime,
+		sched.attr.sched_deadline,
+		sched.attr.sched_period);
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_getattr && __NR_sched_setattr")
+
+#endif
diff --git a/strace/tests/sched_xetattr.test b/strace/tests/sched_xetattr.test
new file mode 100755
index 0000000..c2c7914
--- /dev/null
+++ b/strace/tests/sched_xetattr.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check sched_getattr and sched_setattr syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -e sched_getattr,sched_setattr $args > "$OUT"
+match_grep "$LOG" "$OUT"
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/sched_xetparam.c b/strace/tests/sched_xetparam.c
new file mode 100644
index 0000000..cb30818
--- /dev/null
+++ b/strace/tests/sched_xetparam.c
@@ -0,0 +1,33 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_sched_getparam && defined __NR_sched_setparam
+
+# include <sched.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	struct sched_param *const param =
+		tail_alloc(sizeof(struct sched_param));
+
+	long rc = syscall(__NR_sched_getparam, 0, param);
+	printf("sched_getparam(0, [%d]) = %ld\n",
+	       param->sched_priority, rc);
+
+	param->sched_priority = -1;
+	rc = syscall(__NR_sched_setparam, 0, param);
+	printf("sched_setparam(0, [%d]) = %ld %s (%m)\n",
+	       param->sched_priority, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_getparam && __NR_sched_setparam")
+
+#endif
diff --git a/strace/tests/sched_xetparam.test b/strace/tests/sched_xetparam.test
new file mode 100755
index 0000000..c9fede1
--- /dev/null
+++ b/strace/tests/sched_xetparam.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sched_getparam and sched_setparam syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a23 -e trace=sched_getparam,sched_setparam
diff --git a/strace/tests/sched_xetscheduler.c b/strace/tests/sched_xetscheduler.c
new file mode 100644
index 0000000..f86adfa
--- /dev/null
+++ b/strace/tests/sched_xetscheduler.c
@@ -0,0 +1,62 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_sched_getscheduler && defined __NR_sched_setscheduler
+
+# include <sched.h>
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	struct sched_param *const param = tail_alloc(sizeof(struct sched_param));
+	long rc = syscall(__NR_sched_getscheduler, 0);
+	const char *scheduler;
+	switch (rc) {
+		case SCHED_FIFO:
+			scheduler = "SCHED_FIFO";
+			break;
+		case SCHED_RR:
+			scheduler = "SCHED_RR";
+			break;
+# ifdef SCHED_BATCH
+		case SCHED_BATCH:
+			scheduler = "SCHED_BATCH";
+			break;
+# endif
+# ifdef SCHED_IDLE
+		case SCHED_IDLE:
+			scheduler = "SCHED_IDLE";
+			break;
+# endif
+# ifdef SCHED_ISO
+		case SCHED_ISO:
+			scheduler = "SCHED_ISO";
+			break;
+# endif
+# ifdef SCHED_DEADLINE
+		case SCHED_DEADLINE:
+			scheduler = "SCHED_DEADLINE";
+			break;
+# endif
+		default:
+			scheduler = "SCHED_OTHER";
+	}
+	printf("sched_getscheduler(0) = %ld (%s)\n",
+	       rc, scheduler);
+
+	param->sched_priority = -1;
+	rc = syscall(__NR_sched_setscheduler, 0, SCHED_FIFO, param);
+	printf("sched_setscheduler(0, SCHED_FIFO, [%d]) = %ld %s (%m)\n",
+	       param->sched_priority, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_getscheduler && __NR_sched_setscheduler")
+
+#endif
diff --git a/strace/tests/sched_xetscheduler.test b/strace/tests/sched_xetscheduler.test
new file mode 100755
index 0000000..07c93f3
--- /dev/null
+++ b/strace/tests/sched_xetscheduler.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sched_getscheduler and sched_setscheduler syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22 -e trace=sched_getscheduler,sched_setscheduler
diff --git a/strace/tests/sched_yield.c b/strace/tests/sched_yield.c
new file mode 100644
index 0000000..ed25722
--- /dev/null
+++ b/strace/tests/sched_yield.c
@@ -0,0 +1,22 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_sched_yield
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("sched_yield() = %ld\n", syscall(__NR_sched_yield));
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sched_yield")
+
+#endif
diff --git a/strace/tests/sched_yield.test b/strace/tests/sched_yield.test
new file mode 100755
index 0000000..f0c2c30
--- /dev/null
+++ b/strace/tests/sched_yield.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sched_yield syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a14
diff --git a/strace/tests/scm_rights-fd.test b/strace/tests/scm_rights-fd.test
new file mode 100755
index 0000000..8447375
--- /dev/null
+++ b/strace/tests/scm_rights-fd.test
@@ -0,0 +1,80 @@
+#!/bin/sh
+#
+# Check how SCM_RIGHTS and SCM_CREDENTIALS control messages are decoded in -y mode.
+#
+# Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -y is implemented using /proc/$pid/fd
+[ -d /proc/self/fd/ ] ||
+	framework_skip_ '/proc/self/fd/ is not available'
+
+check_prog mkdir
+check_prog rm
+check_prog seq
+check_prog touch
+
+dir="$LOG.dir"
+rm -rf -- "$dir"
+mkdir -- "$dir" ||
+	framework_skip_ 'failed to create a directory'
+
+file="$dir/$(for i in $(seq 1 127); do echo A; done; echo Z)"
+
+touch -- "$file" ||
+	framework_skip_ 'failed to create a file'
+
+run_prog ./scm_rights /dev/zero
+run_strace -y -x -enetwork $args "$file"
+
+hex='[[:xdigit:]]'
+n='[1-9][0-9]*'
+sample="$(for i in $(seq 1 15); do printf '\\\\xf%x' $i; done)"
+socket='<socket:\[[0-9]+\]>'
+
+path6='(/.*/(A\\n){127}Z|\\x2f(\\x'"$hex$hex"')*\\x2f(\\x41\\x0a){127}\\x5a)'
+rights_data='\[4</dev/null>, 5</dev/zero>, 6<'"$path6"'>\]'
+iov='\[\{iov_base="'"$sample"'", iov_len=15\}\]'
+ids='\{pid='"$n"', uid=[0-9]+, gid=[0-9]+\}'
+
+msg_head='\{msg_name=NULL, msg_namelen=0, msg_iov='"$iov"', msg_iovlen=1, msg_control='
+msg_tail=', msg_controllen='"$n"', msg_flags=0'
+rights='\{cmsg_len='"$n"', cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS, cmsg_data='"$rights_data"'\}'
+creds='\{cmsg_len='"$n"', cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, cmsg_data='"$ids"'\}'
+
+EXPECTED="$LOG.expected"
+
+cat > "$EXPECTED" << __EOF__
+sendmsg\\(3$socket, $msg_head\\[$rights\\]$msg_tail\\}, 0\\) = 15
+recvmsg\\(0$socket, $msg_head\\[$creds, $rights\\]$msg_tail\\}, 0\\) = 15
+__EOF__
+
+match_grep "$LOG" "$EXPECTED"
+rm -f "$EXPECTED"
+rm -rf -- "$dir"
+
+exit 0
diff --git a/strace/tests/scm_rights.c b/strace/tests/scm_rights.c
new file mode 100644
index 0000000..42caed7
--- /dev/null
+++ b/strace/tests/scm_rights.c
@@ -0,0 +1,105 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <fcntl.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+
+int main(int ac, const char **av)
+{
+	assert(ac > 0);
+	int fds[ac];
+
+	static const char sample[] =
+		"\xf1\xf2\xf3\xf4\xf5\xf6\xf7\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff";
+	const unsigned int data_size = sizeof(sample) - 1;
+	void *data = tail_alloc(data_size);
+	memcpy(data, sample, data_size);
+
+	struct iovec *iov = tail_alloc(sizeof(struct iovec));
+	iov->iov_base = data;
+	iov->iov_len = data_size;
+
+	struct msghdr *mh = tail_alloc(sizeof(struct msghdr));
+	memset(mh, 0, sizeof(*mh));
+	mh->msg_iov = iov;
+	mh->msg_iovlen = 1;
+
+	int i;
+	while ((i = open("/dev/null", O_RDWR)) <= ac + 2)
+		assert(i >= 0);
+	while (i > 2)
+		assert(close(i--) == 0);
+	assert(close(0) == 0);
+
+	int sv[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
+		perror_msg_and_skip("socketpair");
+	int one = 1;
+	if (setsockopt(sv[0], SOL_SOCKET, SO_PASSCRED, &one, sizeof(one)))
+		perror_msg_and_skip("setsockopt");
+
+	assert((fds[0] = open("/dev/null", O_RDWR)) == 4);
+	for (i = 1; i < ac; ++i)
+		assert((fds[i] = open(av[i], O_RDONLY)) == i + 4);
+
+	unsigned int cmsg_size = CMSG_SPACE(sizeof(fds));
+	struct cmsghdr *cmsg = tail_alloc(cmsg_size);
+	memset(cmsg, 0, cmsg_size);
+	cmsg->cmsg_level = SOL_SOCKET;
+	cmsg->cmsg_type = SCM_RIGHTS;
+	cmsg->cmsg_len = CMSG_LEN(sizeof(fds));
+	memcpy(CMSG_DATA(cmsg), fds, sizeof(fds));
+
+	mh->msg_control = cmsg;
+	mh->msg_controllen = cmsg_size;
+
+	assert(sendmsg(sv[1], mh, 0) == (int) data_size);
+
+	assert(close(sv[1]) == 0);
+	assert(open("/dev/null", O_RDWR) == sv[1]);
+
+	for (i = 0; i < ac; ++i) {
+		assert(close(fds[i]) == 0);
+		fds[i] = 0;
+	}
+
+	cmsg_size += CMSG_SPACE(sizeof(struct ucred));
+	cmsg = tail_alloc(cmsg_size);
+	memset(cmsg, 0, cmsg_size);
+	mh->msg_control = cmsg;
+	mh->msg_controllen = cmsg_size;
+
+	assert(recvmsg(0, mh, 0) == (int) data_size);
+	assert(close(0) == 0);
+
+	return 0;
+}
diff --git a/strace/tests/seccomp-filter-v.c b/strace/tests/seccomp-filter-v.c
new file mode 100644
index 0000000..ef69c0d
--- /dev/null
+++ b/strace/tests/seccomp-filter-v.c
@@ -0,0 +1,213 @@
+/*
+ * Check verbose decoding of seccomp SECCOMP_SET_MODE_FILTER.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <errno.h>
+#include <stddef.h>
+#include <stdio.h>
+#include <sys/syscall.h>
+#include <unistd.h>
+
+#ifdef HAVE_PRCTL
+# include <sys/prctl.h>
+#endif
+#ifdef HAVE_LINUX_SECCOMP_H
+# include <linux/seccomp.h>
+#endif
+#ifdef HAVE_LINUX_FILTER_H
+# include <linux/filter.h>
+#endif
+
+#if defined __NR_seccomp \
+ && defined PR_SET_NO_NEW_PRIVS \
+ && defined SECCOMP_SET_MODE_FILTER \
+ && defined SECCOMP_RET_ERRNO \
+ && defined BPF_JUMP \
+ && defined BPF_STMT
+
+#define SOCK_FILTER_ALLOW_SYSCALL(nr) \
+		BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, __NR_ ## nr, 0, 1), \
+		BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ALLOW)
+
+#define SOCK_FILTER_DENY_SYSCALL(nr, err) \
+		BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, __NR_ ## nr, 0, 1), \
+		BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ERRNO|(SECCOMP_RET_DATA & (err)))
+
+#define SOCK_FILTER_KILL_PROCESS \
+		BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_KILL)
+
+#define PRINT_ALLOW_SYSCALL(nr) \
+	tprintf("BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, %#x, 0, 0x1), " \
+	       "BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ALLOW), ", \
+	       __NR_ ## nr)
+
+#define PRINT_DENY_SYSCALL(nr, err) \
+	tprintf("BPF_JUMP(BPF_JMP|BPF_K|BPF_JEQ, %#x, 0, 0x1), " \
+	       "BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_ERRNO|%#x), ", \
+	       __NR_ ## nr, err)
+
+static const struct sock_filter filter_c[] = {
+	/* load syscall number */
+	BPF_STMT(BPF_LD|BPF_W|BPF_ABS, offsetof(struct seccomp_data, nr)),
+
+	/* allow syscalls */
+	SOCK_FILTER_ALLOW_SYSCALL(close),
+	SOCK_FILTER_ALLOW_SYSCALL(exit),
+	SOCK_FILTER_ALLOW_SYSCALL(exit_group),
+
+	/* deny syscalls */
+	SOCK_FILTER_DENY_SYSCALL(sync, EBUSY),
+	SOCK_FILTER_DENY_SYSCALL(setsid, EPERM),
+
+	/* kill process */
+	SOCK_FILTER_KILL_PROCESS
+};
+
+#ifndef BPF_MAXINSNS
+# define BPF_MAXINSNS 4096
+#endif
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	static const char kill_stmt_txt[] =
+		"BPF_STMT(BPF_RET|BPF_K, SECCOMP_RET_KILL)";
+	struct sock_filter *const filter =
+		tail_memdup(filter_c, sizeof(filter_c));
+	struct sock_filter *const big_filter =
+		tail_alloc(sizeof(*big_filter) * (BPF_MAXINSNS + 1));
+	struct sock_fprog *const prog = tail_alloc(sizeof(*prog));
+
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	if (prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0))
+		perror_msg_and_skip("PR_SET_NO_NEW_PRIVS");
+
+	prog->filter = filter +  ARRAY_SIZE(filter_c);
+	prog->len = 1;
+	syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, 0, prog);
+	tprintf("seccomp(SECCOMP_SET_MODE_FILTER, 0, {len=1, filter=%p})"
+		" = -1 EFAULT (%m)\n", prog->filter);
+
+	prog->filter = filter +  ARRAY_SIZE(filter_c) - 1;
+	prog->len = 3;
+	syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, 0, prog);
+	tprintf("seccomp(SECCOMP_SET_MODE_FILTER, 0, {len=%u"
+		", filter=[%s, %p]}) = -1 EFAULT (%m)\n",
+		prog->len, kill_stmt_txt, filter +  ARRAY_SIZE(filter_c));
+
+	prog->len = 0;
+	syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, 0, prog);
+	tprintf("seccomp(SECCOMP_SET_MODE_FILTER, 0, {len=0, filter=[]})"
+		" = -1 EINVAL (%m)\n");
+
+	unsigned int i;
+	for (i = 0; i <= BPF_MAXINSNS; ++i) {
+		const struct sock_filter stmt =
+			BPF_STMT(BPF_CLASS(i), i << 16);
+		big_filter[i] = stmt;
+	}
+
+	prog->filter = big_filter;
+	prog->len = BPF_MAXINSNS + 1;
+	tprintf("seccomp(SECCOMP_SET_MODE_FILTER, %s, {len=%u, filter=[",
+		"SECCOMP_FILTER_FLAG_TSYNC|0xfffffffe", prog->len);
+	for (i = 0; i < BPF_MAXINSNS; ++i) {
+		if (i)
+			tprintf(", ");
+		switch(BPF_CLASS(i)) {
+		case BPF_LD:
+			tprintf("BPF_STMT(BPF_LD|BPF_W|BPF_IMM, %#x)", i << 16);
+			break;
+		case BPF_LDX:
+			tprintf("BPF_STMT(BPF_LDX|BPF_W|BPF_IMM, %#x)", i << 16);
+			break;
+		case BPF_ST:
+			tprintf("BPF_STMT(BPF_ST, %#x)", i << 16);
+			break;
+		case BPF_STX:
+			tprintf("BPF_STMT(BPF_STX, %#x)", i << 16);
+			break;
+		case BPF_ALU:
+			tprintf("BPF_STMT(BPF_ALU|BPF_K|BPF_ADD, %#x)", i << 16);
+			break;
+		case BPF_JMP:
+			tprintf("BPF_STMT(BPF_JMP|BPF_K|BPF_JA, %#x)", i << 16);
+			break;
+		case BPF_RET:
+			tprintf("BPF_STMT(BPF_RET|BPF_K, %#x"
+				" /* SECCOMP_RET_??? */)", i << 16);
+			break;
+		case BPF_MISC:
+			tprintf("BPF_STMT(BPF_MISC|BPF_TAX, %#x)", i << 16);
+			break;
+		}
+	}
+	tprintf(", ...]})");
+	syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, -1, prog);
+	tprintf(" = -1 EINVAL (%m)\n");
+
+	prog->filter = filter;
+	prog->len = ARRAY_SIZE(filter_c);
+
+	tprintf("seccomp(SECCOMP_SET_MODE_FILTER, 0, {len=%u, filter=[",
+		prog->len);
+
+	tprintf("BPF_STMT(BPF_LD|BPF_W|BPF_ABS, %#x), ",
+	       (unsigned) offsetof(struct seccomp_data, nr));
+
+	PRINT_ALLOW_SYSCALL(close);
+	PRINT_ALLOW_SYSCALL(exit);
+	PRINT_ALLOW_SYSCALL(exit_group);
+
+	PRINT_DENY_SYSCALL(sync, EBUSY),
+	PRINT_DENY_SYSCALL(setsid, EPERM),
+
+	tprintf("%s]}) = 0\n+++ exited with 0 +++\n", kill_stmt_txt);
+
+	if (syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, 0, prog))
+		perror_msg_and_skip("SECCOMP_SET_MODE_FILTER");
+
+	if (close(0) || close(1))
+		_exit(77);
+
+	_exit(0);
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_seccomp && PR_SET_NO_NEW_PRIVS"
+		    " && SECCOMP_SET_MODE_FILTER && SECCOMP_RET_ERRNO"
+		    " && BPF_JUMP && BPF_STMT")
+
+#endif
diff --git a/strace/tests/seccomp-filter-v.test b/strace/tests/seccomp-filter-v.test
new file mode 100755
index 0000000..f873eb6
--- /dev/null
+++ b/strace/tests/seccomp-filter-v.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check verbose decoding of seccomp SECCOMP_SET_MODE_FILTER.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -e trace=seccomp
diff --git a/strace/tests/seccomp-filter.c b/strace/tests/seccomp-filter.c
new file mode 100644
index 0000000..0326f6e
--- /dev/null
+++ b/strace/tests/seccomp-filter.c
@@ -0,0 +1,75 @@
+/*
+ * Check decoding of seccomp SECCOMP_SET_MODE_FILTER.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <stdio.h>
+#include <sys/syscall.h>
+#include <unistd.h>
+
+#ifdef HAVE_LINUX_SECCOMP_H
+# include <linux/seccomp.h>
+#endif
+#ifdef HAVE_LINUX_FILTER_H
+# include <linux/filter.h>
+#endif
+
+#if defined __NR_seccomp && defined SECCOMP_SET_MODE_FILTER
+
+# define N 7
+
+int
+main(void)
+{
+	struct sock_filter *const filter = tail_alloc(sizeof(*filter) * N);
+	const void *const efault = tail_alloc(1);
+	struct sock_fprog *const prog = tail_alloc(sizeof(*prog));
+	long rc;
+
+	prog->filter = filter;
+	prog->len = N;
+	rc = syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, -1, prog);
+	printf("seccomp(SECCOMP_SET_MODE_FILTER, %s, {len=%u, filter=%p})"
+	       " = %ld %s (%m)\n", "SECCOMP_FILTER_FLAG_TSYNC|0xfffffffe",
+	       prog->len, prog->filter, rc, errno2name());
+
+	rc = syscall(__NR_seccomp, SECCOMP_SET_MODE_FILTER, -2L, efault);
+	printf("seccomp(SECCOMP_SET_MODE_FILTER, %s, %p) = %ld %s (%m)\n",
+	       "0xfffffffe /* SECCOMP_FILTER_FLAG_??? */",
+	       efault, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_seccomp && SECCOMP_SET_MODE_FILTER")
+
+#endif
diff --git a/strace/tests/seccomp-filter.test b/strace/tests/seccomp-filter.test
new file mode 100755
index 0000000..65c6d49
--- /dev/null
+++ b/strace/tests/seccomp-filter.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of seccomp SECCOMP_SET_MODE_FILTER.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=seccomp
diff --git a/strace/tests/seccomp-strict.c b/strace/tests/seccomp-strict.c
new file mode 100644
index 0000000..c145567
--- /dev/null
+++ b/strace/tests/seccomp-strict.c
@@ -0,0 +1,74 @@
+/*
+ * Check how seccomp SECCOMP_SET_MODE_STRICT is decoded.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_seccomp && defined __NR_exit
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char text1[] =
+		"seccomp(SECCOMP_SET_MODE_STRICT, 0, NULL) = 0\n";
+	static const char text2[] = "+++ exited with 0 +++\n";
+	const unsigned long addr = (unsigned long) 0xfacefeeddeadbeef;
+	long rc;
+
+	rc = syscall(__NR_seccomp, -1L, -1L, addr);
+	printf("seccomp(%#x /* SECCOMP_SET_MODE_??? */, %u, %#lx)"
+	       " = %ld %s (%m)\n", -1, -1, addr, rc, errno2name());
+	fflush(stdout);
+
+	rc = syscall(__NR_seccomp, 0, 0, 0);
+	if (rc) {
+		printf("seccomp(SECCOMP_SET_MODE_STRICT, 0, NULL)"
+		       " = %ld %s (%m)\n", rc, errno2name());
+		fflush(stdout);
+		rc = 0;
+	} else {
+		/*
+		 * If kernel implementaton of SECCOMP_MODE_STRICT is buggy,
+		 * the following syscall will result to SIGKILL.
+		 */
+		rc = write(1, text1, LENGTH_OF(text1)) != LENGTH_OF(text1);
+	}
+
+	rc += write(1, text2, LENGTH_OF(text2)) != LENGTH_OF(text2);
+	return !!syscall(__NR_exit, rc);
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_seccomp && __NR_exit")
+
+#endif
diff --git a/strace/tests/seccomp-strict.test b/strace/tests/seccomp-strict.test
new file mode 100755
index 0000000..b354c6a
--- /dev/null
+++ b/strace/tests/seccomp-strict.test
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+# Check how seccomp SECCOMP_SET_MODE_STRICT is decoded.
+
+. "${srcdir=.}/init.sh"
+
+set -- "./$NAME"
+"$@" > /dev/null || {
+	case $? in
+		77) skip_ "$* exited with code 77" ;;
+		137) framework_skip_ "$* killed by SIGKILL, fix your kernel" ;;
+		*) fail_ "$args failed" ;;
+	esac
+}
+run_strace -eseccomp "$@" > "$EXP"
+match_diff "$LOG" "$EXP"
+rm -f "$EXP"
diff --git a/strace/tests/select.c b/strace/tests/select.c
new file mode 100644
index 0000000..fa551a6
--- /dev/null
+++ b/strace/tests/select.c
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_select && !defined __NR__newselect
+
+# define TEST_SYSCALL_NR __NR_select
+# define TEST_SYSCALL_STR "select"
+# include "xselect.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_select && !__NR__newselect")
+
+#endif
diff --git a/strace/tests/select.test b/strace/tests/select.test
new file mode 100755
index 0000000..60b88ca
--- /dev/null
+++ b/strace/tests/select.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check select syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a36
diff --git a/strace/tests/semop.c b/strace/tests/semop.c
new file mode 100644
index 0000000..214ce32
--- /dev/null
+++ b/strace/tests/semop.c
@@ -0,0 +1,54 @@
+#include "tests.h"
+#include <sys/types.h>
+#include <sys/ipc.h>
+#include <sys/sem.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
+
+union semun
+{
+	int val;
+	struct semid_ds *buf;
+	unsigned short *array;
+	struct seminfo *__buf;
+};
+
+static int id = -1;
+
+static void
+cleanup(void)
+{
+	semctl(id, 0, IPC_RMID, 0);
+	id = -1;
+}
+
+int
+main(void)
+{
+	id = semget(IPC_PRIVATE, 1, 0600);
+	if (id < 0)
+		perror_msg_and_skip("semget");
+	atexit(cleanup);
+
+	union semun sem_union = { .val = 0 };
+	if (semctl(id, 0, SETVAL, sem_union) == -1)
+		perror_msg_and_skip("semctl");
+
+	struct sembuf *const sem_b = tail_alloc(sizeof(*sem_b));
+	sem_b->sem_num = 0;
+	sem_b->sem_op = 1;
+	sem_b->sem_flg = SEM_UNDO;
+
+	if (semop(id, sem_b, 1))
+		perror_msg_and_skip("semop, 1");
+	printf("semop(%d, [{0, 1, SEM_UNDO}], 1) = 0\n", id);
+
+	sem_b->sem_op = -1;
+	if (semop(id, sem_b, 1))
+		perror_msg_and_skip("semop, -1");
+	printf("semop(%d, [{0, -1, SEM_UNDO}], 1) = 0\n", id);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/semop.test b/strace/tests/semop.test
new file mode 100755
index 0000000..7e8f32c
--- /dev/null
+++ b/strace/tests/semop.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check semop syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a32
diff --git a/strace/tests/sendfile.c b/strace/tests/sendfile.c
new file mode 100644
index 0000000..b1c7574
--- /dev/null
+++ b/strace/tests/sendfile.c
@@ -0,0 +1,130 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_sendfile
+
+# include <assert.h>
+# include <errno.h>
+# include <fcntl.h>
+# include <stdio.h>
+# include <stdint.h>
+# include <unistd.h>
+# include <sys/socket.h>
+# include <sys/stat.h>
+
+int
+main(int ac, const char **av)
+{
+	assert(ac == 1);
+
+	(void) close(0);
+	if (open("/dev/zero", O_RDONLY) != 0)
+		perror_msg_and_skip("open: %s", "/dev/zero");
+
+	int sv[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
+		perror_msg_and_skip("socketpair");
+
+	int reg_in = open(av[0], O_RDONLY);
+	if (reg_in < 0)
+		perror_msg_and_fail("open: %s", av[0]);
+
+	struct stat stb;
+	assert(fstat(reg_in, &stb) == 0);
+	const size_t blen = stb.st_size / 3;
+	const size_t alen = stb.st_size - blen;
+	assert(S_ISREG(stb.st_mode) && blen > 0);
+
+	const size_t page_len = get_page_size();
+	assert(syscall(__NR_sendfile, 0, 1, NULL, page_len) == -1);
+	if (EBADF != errno)
+		perror_msg_and_skip("sendfile");
+	printf("sendfile(0, 1, NULL, %lu) = -1 EBADF (%m)\n",
+	       (unsigned long) page_len);
+
+	uint32_t *p_off = tail_alloc(sizeof(uint32_t));
+	void *p = p_off + 1;
+	*p_off = 0;
+
+	assert(syscall(__NR_sendfile, 0, 1, p, page_len) == -1);
+	printf("sendfile(0, 1, %#lx, %lu) = -1 EFAULT (%m)\n",
+	       (unsigned long) p, (unsigned long) page_len);
+
+	assert(syscall(__NR_sendfile, sv[1], reg_in, NULL, alen)
+	       == (long) alen);
+	printf("sendfile(%d, %d, NULL, %lu) = %lu\n",
+	       sv[1], reg_in, (unsigned long) alen,
+	       (unsigned long) alen);
+
+	p = p_off;
+	if (syscall(__NR_sendfile, sv[1], reg_in, p_off, alen) != (long) alen) {
+		printf("sendfile(%d, %d, %#lx, %lu) = -1 EFAULT (%m)\n",
+		       sv[1], reg_in, (unsigned long) p_off,
+		       (unsigned long) alen);
+		--p_off;
+		*p_off = 0;
+		assert(syscall(__NR_sendfile, sv[1], reg_in, p_off, alen)
+		       == (long) alen);
+	}
+	printf("sendfile(%d, %d, [0] => [%lu], %lu) = %lu\n",
+	       sv[1], reg_in, (unsigned long) alen,
+	       (unsigned long) alen, (unsigned long) alen);
+
+	assert(syscall(__NR_sendfile, sv[1], reg_in, p_off, stb.st_size + 1)
+	       == (long) blen);
+	printf("sendfile(%d, %d, [%lu] => [%lu], %lu) = %lu\n",
+	       sv[1], reg_in, (unsigned long) alen,
+	       (unsigned long) stb.st_size,
+	       (unsigned long) stb.st_size + 1,
+	       (unsigned long) blen);
+
+	if (p_off != p) {
+		uint64_t *p_off64 = (uint64_t *) p_off;
+		*p_off64 = 0xcafef00dfacefeed;
+		assert(syscall(__NR_sendfile, sv[1], reg_in, p_off64, 1) == -1);
+		printf("sendfile(%d, %d, [14627392582579060461], 1)"
+		       " = -1 EINVAL (%m)\n", sv[1], reg_in);
+		*p_off64 = 0xdefaced;
+	} else {
+		*p_off = 0xdefaced;
+	}
+	assert(syscall(__NR_sendfile, sv[1], reg_in, p_off, 1) == 0);
+	printf("sendfile(%d, %d, [233811181], 1) = 0\n",
+	       sv[1], reg_in);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sendfile")
+
+#endif
diff --git a/strace/tests/sendfile.test b/strace/tests/sendfile.test
new file mode 100755
index 0000000..48dba58
--- /dev/null
+++ b/strace/tests/sendfile.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sendfile syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a27
diff --git a/strace/tests/sendfile64.c b/strace/tests/sendfile64.c
new file mode 100644
index 0000000..7c4a6f5
--- /dev/null
+++ b/strace/tests/sendfile64.c
@@ -0,0 +1,117 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_sendfile64
+
+# include <assert.h>
+# include <errno.h>
+# include <fcntl.h>
+# include <stdio.h>
+# include <stdint.h>
+# include <unistd.h>
+# include <sys/socket.h>
+# include <sys/stat.h>
+
+int
+main(int ac, const char **av)
+{
+	assert(ac == 1);
+
+	(void) close(0);
+	if (open("/dev/zero", O_RDONLY) != 0)
+		perror_msg_and_skip("open: %s", "/dev/zero");
+
+	int sv[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
+		perror_msg_and_skip("socketpair");
+
+	int reg_in = open(av[0], O_RDONLY);
+	if (reg_in < 0)
+		perror_msg_and_fail("open: %s", av[0]);
+
+	struct stat stb;
+	assert(fstat(reg_in, &stb) == 0);
+	const size_t blen = stb.st_size / 3;
+	const size_t alen = stb.st_size - blen;
+	assert(S_ISREG(stb.st_mode) && blen > 0);
+
+	const size_t page_len = get_page_size();
+	assert(syscall(__NR_sendfile64, 0, 1, NULL, page_len) == -1);
+	if (EBADF != errno)
+		perror_msg_and_skip("sendfile64");
+	printf("sendfile64(0, 1, NULL, %lu) = -1 EBADF (%m)\n",
+	       (unsigned long) page_len);
+
+	uint64_t *p_off = tail_alloc(sizeof(uint64_t));
+	void *p = p_off + 1;
+	*p_off = 0;
+
+	assert(syscall(__NR_sendfile64, 0, 1, p, page_len) == -1);
+	printf("sendfile64(0, 1, %#lx, %lu) = -1 EFAULT (%m)\n",
+	       (unsigned long) p, (unsigned long) page_len);
+
+	assert(syscall(__NR_sendfile64, sv[1], reg_in, NULL, alen)
+	       == (long) alen);
+	printf("sendfile64(%d, %d, NULL, %lu) = %lu\n",
+	       sv[1], reg_in, (unsigned long) alen,
+	       (unsigned long) alen);
+
+	assert(syscall(__NR_sendfile64, sv[1], reg_in, p_off, alen)
+	       == (long) alen);
+	printf("sendfile64(%d, %d, [0] => [%lu], %lu) = %lu\n",
+	       sv[1], reg_in, (unsigned long) alen,
+	       (unsigned long) alen, (unsigned long) alen);
+
+	assert(syscall(__NR_sendfile64, sv[1], reg_in, p_off, stb.st_size + 1)
+	       == (long) blen);
+	printf("sendfile64(%d, %d, [%lu] => [%lu], %lu) = %lu\n",
+	       sv[1], reg_in, (unsigned long) alen,
+	       (unsigned long) stb.st_size,
+	       (unsigned long) stb.st_size + 1,
+	       (unsigned long) blen);
+
+	*p_off = 0xcafef00dfacefeed;
+	assert(syscall(__NR_sendfile64, sv[1], reg_in, p_off, 1) == -1);
+	printf("sendfile64(%d, %d, [14627392582579060461], 1)"
+		" = -1 EINVAL (%m)\n", sv[1], reg_in);
+
+	*p_off = 0xfacefeed;
+	assert(syscall(__NR_sendfile64, sv[1], reg_in, p_off, 1) == 0);
+	printf("sendfile64(%d, %d, [4207869677], 1) = 0\n", sv[1], reg_in);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sendfile64")
+
+#endif
diff --git a/strace/tests/sendfile64.test b/strace/tests/sendfile64.test
new file mode 100755
index 0000000..faa0525
--- /dev/null
+++ b/strace/tests/sendfile64.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sendfile64 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a29
diff --git a/strace/tests/set_mempolicy.c b/strace/tests/set_mempolicy.c
new file mode 100644
index 0000000..e59e89f
--- /dev/null
+++ b/strace/tests/set_mempolicy.c
@@ -0,0 +1,152 @@
+/*
+ * Check decoding of set_mempolicy syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_set_mempolicy
+
+# include <errno.h>
+# include <stdio.h>
+# include <string.h>
+# include <unistd.h>
+
+# include "xlat.h"
+# include "xlat/policies.h"
+
+# define MAX_STRLEN 3
+# define NLONGS(n) ((n + 8 * sizeof(long) - 2) \
+		      / (8 * sizeof(long)))
+
+static void
+print_nodes(const unsigned long maxnode, unsigned int offset)
+{
+	unsigned int nlongs = NLONGS(maxnode);
+	if (nlongs <= offset)
+		nlongs = 0;
+	else
+		nlongs -= offset;
+	const unsigned int size = nlongs * sizeof(long);
+	unsigned long *const nodemask =
+		tail_alloc(size ? size : (offset ? 1 : 0));
+	memset(nodemask, 0, size);
+
+	long rc = syscall(__NR_set_mempolicy, 0, nodemask, maxnode);
+	int saved_errno = errno;
+
+	fputs("set_mempolicy(MPOL_DEFAULT, ", stdout);
+
+	if (nlongs) {
+		putc('[', stdout);
+		unsigned int i;
+		for (i = 0; i < nlongs + offset; ++i) {
+			if (i)
+				fputs(", ", stdout);
+			if (i < nlongs) {
+				if (i >= MAX_STRLEN) {
+					fputs("...", stdout);
+					break;
+				}
+				printf("%#0*lx", (int) sizeof(long) * 2 + 2,
+				       nodemask[i]);
+			} else {
+				printf("%p", nodemask + i);
+				break;
+			}
+		}
+		putc(']', stdout);
+	} else {
+		if (maxnode)
+			printf("%p", nodemask);
+		else
+			printf("[]");
+	}
+
+	printf(", %lu) = ", maxnode);
+	if (rc) {
+		errno = saved_errno;
+		printf("%ld %s (%m)\n", rc, errno2name());
+	} else {
+		puts("0");
+	}
+}
+
+static void
+test_offset(const unsigned int offset)
+{
+	unsigned long maxnode = get_page_size() * 8;
+
+	print_nodes(maxnode, offset);
+	print_nodes(maxnode + 1, offset);
+	print_nodes(maxnode + 2, offset);
+
+	maxnode = sizeof(long) * 8;
+	print_nodes(0, offset);
+	print_nodes(1, offset);
+	print_nodes(2, offset);
+	print_nodes(maxnode - 1, offset);
+	print_nodes(maxnode    , offset);
+	print_nodes(maxnode + 1, offset);
+	print_nodes(maxnode + 2, offset);
+	print_nodes(maxnode * 2 - 1, offset);
+	print_nodes(maxnode * 2    , offset);
+	print_nodes(maxnode * 2 + 1, offset);
+	print_nodes(maxnode * 2 + 2, offset);
+	print_nodes(maxnode * 3 - 1, offset);
+	print_nodes(maxnode * 3    , offset);
+	print_nodes(maxnode * 3 + 1, offset);
+	print_nodes(maxnode * 3 + 2, offset);
+	print_nodes(maxnode * 4 + 2, offset);
+}
+
+int
+main(void)
+{
+	if (syscall(__NR_set_mempolicy, 0, 0, 0))
+		perror_msg_and_skip("set_mempolicy");
+	puts("set_mempolicy(MPOL_DEFAULT, NULL, 0) = 0");
+
+	const unsigned long *nodemask = (void *) 0xfacefeedfffffffe;
+	const unsigned long maxnode = (unsigned long) 0xcafef00dbadc0ded;
+	long rc = syscall(__NR_set_mempolicy, 1, nodemask, maxnode);
+	printf("set_mempolicy(MPOL_PREFERRED, %p, %lu) = %ld %s (%m)\n",
+	       nodemask, maxnode, rc, errno2name());
+
+	test_offset(0);
+	test_offset(1);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_set_mempolicy")
+
+#endif
diff --git a/strace/tests/set_mempolicy.test b/strace/tests/set_mempolicy.test
new file mode 100755
index 0000000..0ed6666
--- /dev/null
+++ b/strace/tests/set_mempolicy.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check set_mempolicy syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -s3 -a35
diff --git a/strace/tests/set_ptracer_any.c b/strace/tests/set_ptracer_any.c
new file mode 100644
index 0000000..bc2f90c
--- /dev/null
+++ b/strace/tests/set_ptracer_any.c
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2013-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+#ifdef HAVE_PRCTL
+# include <sys/prctl.h>
+#endif
+
+int main(int argc, char **argv)
+{
+	if (argc < 2)
+		return 99;
+#if defined HAVE_PRCTL && defined PR_SET_PTRACER && defined PR_SET_PTRACER_ANY
+	/* Turn off restrictions on tracing if applicable.  If the options
+	 * aren't available on this system, that's OK too.  */
+	(void) prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY);
+#endif
+	if (write(1, "\n", 1) != 1) {
+		perror("write");
+		return 99;
+	}
+	(void) execvp(argv[1], argv + 1);
+	perror(argv[1]);
+	return 99;
+}
diff --git a/strace/tests/setdomainname.c b/strace/tests/setdomainname.c
new file mode 100644
index 0000000..1d83ffd
--- /dev/null
+++ b/strace/tests/setdomainname.c
@@ -0,0 +1,24 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setdomainname
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_setdomainname, 0, 63);
+	printf("setdomainname(NULL, 63) = %ld %s (%m)\n",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setdomainname")
+
+#endif
diff --git a/strace/tests/setdomainname.test b/strace/tests/setdomainname.test
new file mode 100755
index 0000000..2159e7c
--- /dev/null
+++ b/strace/tests/setdomainname.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setdomainname syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24
diff --git a/strace/tests/setfsgid.c b/strace/tests/setfsgid.c
new file mode 100644
index 0000000..9f3a279
--- /dev/null
+++ b/strace/tests/setfsgid.c
@@ -0,0 +1,23 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setfsgid
+
+# define SYSCALL_NR	__NR_setfsgid
+# define SYSCALL_NAME	"setfsgid"
+
+# if defined __NR_setfsgid32 && __NR_setfsgid != __NR_setfsgid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_getegid)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	getegid()
+# endif
+
+# include "setfsugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setfsgid")
+
+#endif
diff --git a/strace/tests/setfsgid.test b/strace/tests/setfsgid.test
new file mode 100755
index 0000000..0ae2b0a
--- /dev/null
+++ b/strace/tests/setfsgid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setfsgid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12
diff --git a/strace/tests/setfsgid32.c b/strace/tests/setfsgid32.c
new file mode 100644
index 0000000..149b767
--- /dev/null
+++ b/strace/tests/setfsgid32.c
@@ -0,0 +1,16 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setfsgid32
+
+# define SYSCALL_NR	__NR_setfsgid32
+# define SYSCALL_NAME	"setfsgid32"
+# define UGID_TYPE	int
+# define GETUGID	getegid()
+# include "setfsugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setfsgid32")
+
+#endif
diff --git a/strace/tests/setfsgid32.test b/strace/tests/setfsgid32.test
new file mode 100755
index 0000000..9b7a2bf
--- /dev/null
+++ b/strace/tests/setfsgid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setfsgid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a14
diff --git a/strace/tests/setfsugid.c b/strace/tests/setfsugid.c
new file mode 100644
index 0000000..5b8f4fd
--- /dev/null
+++ b/strace/tests/setfsugid.c
@@ -0,0 +1,65 @@
+/*
+ * Check decoding of setfsuid/setfsgid/setfsuid32/setfsgid32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <stdio.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	unsigned int ugid = GETUGID;
+
+	const long tests[] = {
+		ugid,
+		0xffff0000U | ugid,
+		(unsigned long) 0xffffffff00000000ULL | ugid,
+		0xffffU,
+		-1U,
+		-1L,
+		0xc0deffffU,
+		0xfacefeedU,
+		(long) 0xfacefeeddeadbeefULL
+	};
+
+	unsigned int i;
+
+	for (i = 0; i < ARRAY_SIZE(tests); ++i) {
+		const unsigned int num = (unsigned UGID_TYPE) tests[i];
+		unsigned int rc;
+
+		rc = syscall(SYSCALL_NR, tests[i]);
+		printf("%s(%u) = %u\n", SYSCALL_NAME, num, rc);
+
+		rc = syscall(SYSCALL_NR, ugid);
+		printf("%s(%u) = %u\n", SYSCALL_NAME, ugid, rc);
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/setfsuid.c b/strace/tests/setfsuid.c
new file mode 100644
index 0000000..7c77f50
--- /dev/null
+++ b/strace/tests/setfsuid.c
@@ -0,0 +1,23 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setfsuid
+
+# define SYSCALL_NR	__NR_setfsuid
+# define SYSCALL_NAME	"setfsuid"
+
+# if defined __NR_setfsuid32 && __NR_setfsuid != __NR_setfsuid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_geteuid)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	geteuid()
+# endif
+
+# include "setfsugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setfsuid")
+
+#endif
diff --git a/strace/tests/setfsuid.test b/strace/tests/setfsuid.test
new file mode 100755
index 0000000..18a1021
--- /dev/null
+++ b/strace/tests/setfsuid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setfsuid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12
diff --git a/strace/tests/setfsuid32.c b/strace/tests/setfsuid32.c
new file mode 100644
index 0000000..cb72d7c
--- /dev/null
+++ b/strace/tests/setfsuid32.c
@@ -0,0 +1,16 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setfsuid32
+
+# define SYSCALL_NR	__NR_setfsuid32
+# define SYSCALL_NAME	"setfsuid32"
+# define UGID_TYPE	int
+# define GETUGID	geteuid()
+# include "setfsugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setfsuid32")
+
+#endif
diff --git a/strace/tests/setfsuid32.test b/strace/tests/setfsuid32.test
new file mode 100755
index 0000000..2dce3cc
--- /dev/null
+++ b/strace/tests/setfsuid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setfsuid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a14
diff --git a/strace/tests/setgid.c b/strace/tests/setgid.c
new file mode 100644
index 0000000..aa3f898
--- /dev/null
+++ b/strace/tests/setgid.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setgid
+
+# define SYSCALL_NR	__NR_setgid
+# define SYSCALL_NAME	"setgid"
+
+# if defined __NR_setgid32 && __NR_setgid != __NR_setgid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_getegid)
+#  define CHECK_OVERFLOWUGID(arg)	check_overflowgid(arg)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	getegid()
+#  define CHECK_OVERFLOWUGID(arg)
+# endif
+
+# include "setugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setgid")
+
+#endif
diff --git a/strace/tests/setgid.test b/strace/tests/setgid.test
new file mode 100755
index 0000000..a3a9004
--- /dev/null
+++ b/strace/tests/setgid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setgid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/setgid32.c b/strace/tests/setgid32.c
new file mode 100644
index 0000000..c9f1221
--- /dev/null
+++ b/strace/tests/setgid32.c
@@ -0,0 +1,17 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setgid32
+
+# define SYSCALL_NR	__NR_setgid32
+# define SYSCALL_NAME	"setgid32"
+# define UGID_TYPE	int
+# define GETUGID	getegid()
+# define CHECK_OVERFLOWUGID(arg)
+# include "setugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setgid32")
+
+#endif
diff --git a/strace/tests/setgid32.test b/strace/tests/setgid32.test
new file mode 100755
index 0000000..11a87e1
--- /dev/null
+++ b/strace/tests/setgid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setgid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12
diff --git a/strace/tests/setgroups.c b/strace/tests/setgroups.c
new file mode 100644
index 0000000..8355301
--- /dev/null
+++ b/strace/tests/setgroups.c
@@ -0,0 +1,171 @@
+/*
+ * Check decoding of setgroups/setgroups32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifdef __NR_setgroups32
+
+# define SYSCALL_NR	__NR_setgroups32
+# define SYSCALL_NAME	"setgroups32"
+# define GID_TYPE	unsigned int
+
+#else
+
+# include "tests.h"
+# include <sys/syscall.h>
+
+# ifdef __NR_setgroups
+
+#  define SYSCALL_NR	__NR_setgroups
+#  define SYSCALL_NAME	"setgroups"
+#  if defined __NR_setgroups32 && __NR_setgroups != __NR_setgroups32
+#   define GID_TYPE	unsigned short
+#  else
+#   define GID_TYPE	unsigned int
+#  endif
+
+# endif
+
+#endif
+
+#ifdef GID_TYPE
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	/* check how the first argument is decoded */
+	if (syscall(SYSCALL_NR, 0, 0))
+		printf("%s(0, NULL) = -1 %s (%m)\n", SYSCALL_NAME, errno2name());
+	else
+		printf("%s(0, NULL) = 0\n", SYSCALL_NAME);
+
+	if (syscall(SYSCALL_NR, (long) 0xffffffff00000000ULL, 0))
+		printf("%s(0, NULL) = -1 %s (%m)\n",
+		       SYSCALL_NAME, errno2name());
+	else
+		printf("%s(0, NULL) = 0\n", SYSCALL_NAME);
+
+	syscall(SYSCALL_NR, 1, 0);
+	printf("%s(1, NULL) = -1 %s (%m)\n", SYSCALL_NAME, errno2name());
+
+	syscall(SYSCALL_NR, (long) 0xffffffff00000001ULL, 0);
+	printf("%s(1, NULL) = -1 %s (%m)\n", SYSCALL_NAME, errno2name());
+
+	syscall(SYSCALL_NR, -1U, 0);
+	printf("%s(%u, NULL) = -1 %s (%m)\n", SYSCALL_NAME, -1U, errno2name());
+
+	syscall(SYSCALL_NR, -1L, 0);
+	printf("%s(%u, NULL) = -1 %s (%m)\n", SYSCALL_NAME, -1U, errno2name());
+
+	/* check how the second argument is decoded */
+	const GID_TYPE *const g1 = tail_alloc(sizeof(*g1));
+	GID_TYPE *const g2 = tail_alloc(sizeof(*g2) * 2);
+	GID_TYPE *const g3 = tail_alloc(sizeof(*g3) * 3);
+
+	if (syscall(SYSCALL_NR, 0, g1 + 1))
+		printf("%s(0, []) = -1 %s (%m)\n",
+		       SYSCALL_NAME, errno2name());
+	else
+		printf("%s(0, []) = 0\n", SYSCALL_NAME);
+
+	if (syscall(SYSCALL_NR, 1, g1))
+		printf("%s(1, [%u]) = -1 %s (%m)\n",
+		       SYSCALL_NAME, (unsigned) *g1, errno2name());
+	else
+		printf("%s(1, [%u]) = 0\n",
+		       SYSCALL_NAME, (unsigned) *g1);
+
+	syscall(SYSCALL_NR, 1, g1 + 1);
+	printf("%s(1, %p) = -1 %s (%m)\n",
+	       SYSCALL_NAME, g1 + 1, errno2name());
+
+	syscall(SYSCALL_NR, 1, -1L);
+	printf("%s(1, %#lx) = -1 %s (%m)\n", SYSCALL_NAME, -1L, errno2name());
+
+	syscall(SYSCALL_NR, 2, g1);
+	printf("%s(2, [%u, %p]) = -1 %s (%m)\n",
+	       SYSCALL_NAME, (unsigned) *g1, g1 + 1, errno2name());
+
+	g2[0] = -2;
+	g2[1] = -3;
+	if (syscall(SYSCALL_NR, 2, g2))
+		printf("%s(2, [%u, %u]) = -1 %s (%m)\n", SYSCALL_NAME,
+		       (unsigned) g2[0], (unsigned) g2[1], errno2name());
+	else
+		printf("%s(2, [%u, %u]) = 0\n", SYSCALL_NAME,
+		       (unsigned) g2[0], (unsigned) g2[1]);
+
+	syscall(SYSCALL_NR, 3, g2);
+	printf("%s(3, [%u, %u, %p]) = -1 %s (%m)\n", SYSCALL_NAME,
+	       (unsigned) g2[0], (unsigned) g2[1], g2 + 2, errno2name());
+
+	g3[0] = 0;
+	g3[1] = 1;
+	if (syscall(SYSCALL_NR, 3, g3))
+		printf("%s(3, [%u, %u, ...]) = -1 %s (%m)\n", SYSCALL_NAME,
+		       (unsigned) g3[0], (unsigned) g3[1], errno2name());
+	else
+		printf("%s(3, [%u, %u]) = 0\n", SYSCALL_NAME,
+		       (unsigned) g3[0], (unsigned) g3[1]);
+
+	syscall(SYSCALL_NR, 4, g3);
+	printf("%s(4, [%u, %u, ...]) = -1 %s (%m)\n", SYSCALL_NAME,
+	       (unsigned) g3[0], (unsigned) g3[1], errno2name());
+
+	long rc = sysconf(_SC_NGROUPS_MAX);
+	const unsigned ngroups_max = rc;
+
+	if ((unsigned long) rc == ngroups_max && (int) ngroups_max > 0) {
+		syscall(SYSCALL_NR, ngroups_max, g3);
+		printf("%s(%u, [%u, %u, ...]) = -1 %s (%m)\n", SYSCALL_NAME,
+		       ngroups_max, (unsigned) g3[0], (unsigned) g3[1],
+		       errno2name());
+
+		const unsigned long size =
+			(unsigned long) 0xffffffff00000000ULL | ngroups_max;
+		syscall(SYSCALL_NR, size, g3);
+		printf("%s(%u, [%u, %u, ...]) = -1 %s (%m)\n", SYSCALL_NAME,
+		       ngroups_max, (unsigned) g3[0], (unsigned) g3[1],
+		       errno2name());
+
+		syscall(SYSCALL_NR, ngroups_max + 1, g3);
+		printf("%s(%u, %p) = -1 %s (%m)\n", SYSCALL_NAME,
+		       ngroups_max + 1, g3, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setgroups")
+
+#endif
diff --git a/strace/tests/setgroups.test b/strace/tests/setgroups.test
new file mode 100755
index 0000000..0dcc8f7
--- /dev/null
+++ b/strace/tests/setgroups.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setgroups syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -s2 -a17
diff --git a/strace/tests/setgroups32.c b/strace/tests/setgroups32.c
new file mode 100644
index 0000000..bd0a1fd
--- /dev/null
+++ b/strace/tests/setgroups32.c
@@ -0,0 +1,12 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setgroups32
+
+# include "setgroups.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setgroups32")
+
+#endif
diff --git a/strace/tests/setgroups32.test b/strace/tests/setgroups32.test
new file mode 100755
index 0000000..ee4750d
--- /dev/null
+++ b/strace/tests/setgroups32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setgroups32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -s2 -a19
diff --git a/strace/tests/sethostname.c b/strace/tests/sethostname.c
new file mode 100644
index 0000000..65d0a78
--- /dev/null
+++ b/strace/tests/sethostname.c
@@ -0,0 +1,24 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_sethostname
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_sethostname, 0, 63);
+	printf("sethostname(NULL, 63) = %ld %s (%m)\n",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sethostname")
+
+#endif
diff --git a/strace/tests/sethostname.test b/strace/tests/sethostname.test
new file mode 100755
index 0000000..78f8c58
--- /dev/null
+++ b/strace/tests/sethostname.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sethostname syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a22
diff --git a/strace/tests/setregid.c b/strace/tests/setregid.c
new file mode 100644
index 0000000..6efa388
--- /dev/null
+++ b/strace/tests/setregid.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setregid
+
+# define SYSCALL_NR	__NR_setregid
+# define SYSCALL_NAME	"setregid"
+
+# if defined __NR_setregid32 && __NR_setregid != __NR_setregid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_getegid)
+#  define CHECK_OVERFLOWUGID(arg)	check_overflowgid(arg)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	getegid()
+#  define CHECK_OVERFLOWUGID(arg)
+# endif
+
+# include "setreugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setregid")
+
+#endif
diff --git a/strace/tests/setregid.test b/strace/tests/setregid.test
new file mode 100755
index 0000000..101c7bd
--- /dev/null
+++ b/strace/tests/setregid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setregid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a15
diff --git a/strace/tests/setregid32.c b/strace/tests/setregid32.c
new file mode 100644
index 0000000..0d0ebed
--- /dev/null
+++ b/strace/tests/setregid32.c
@@ -0,0 +1,17 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setregid32
+
+# define SYSCALL_NR	__NR_setregid32
+# define SYSCALL_NAME	"setregid32"
+# define UGID_TYPE	int
+# define GETUGID	getegid()
+# define CHECK_OVERFLOWUGID(arg)
+# include "setreugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setregid32")
+
+#endif
diff --git a/strace/tests/setregid32.test b/strace/tests/setregid32.test
new file mode 100755
index 0000000..e57e66c
--- /dev/null
+++ b/strace/tests/setregid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setregid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a17
diff --git a/strace/tests/setresgid.c b/strace/tests/setresgid.c
new file mode 100644
index 0000000..6754c2f
--- /dev/null
+++ b/strace/tests/setresgid.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setresgid
+
+# define SYSCALL_NR	__NR_setresgid
+# define SYSCALL_NAME	"setresgid"
+
+# if defined __NR_setresgid32 && __NR_setresgid != __NR_setresgid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_getegid)
+#  define CHECK_OVERFLOWUGID(arg)	check_overflowgid(arg)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	getegid()
+#  define CHECK_OVERFLOWUGID(arg)
+# endif
+
+# include "setresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setresgid")
+
+#endif
diff --git a/strace/tests/setresgid.test b/strace/tests/setresgid.test
new file mode 100755
index 0000000..5a69574
--- /dev/null
+++ b/strace/tests/setresgid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setresgid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a19
diff --git a/strace/tests/setresgid32.c b/strace/tests/setresgid32.c
new file mode 100644
index 0000000..29a8042
--- /dev/null
+++ b/strace/tests/setresgid32.c
@@ -0,0 +1,17 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setresgid32
+
+# define SYSCALL_NR	__NR_setresgid32
+# define SYSCALL_NAME	"setresgid32"
+# define UGID_TYPE	int
+# define GETUGID	getegid()
+# define CHECK_OVERFLOWUGID(arg)
+# include "setresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setresgid32")
+
+#endif
diff --git a/strace/tests/setresgid32.test b/strace/tests/setresgid32.test
new file mode 100755
index 0000000..528b2c9
--- /dev/null
+++ b/strace/tests/setresgid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setresgid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21
diff --git a/strace/tests/setresugid.c b/strace/tests/setresugid.c
new file mode 100644
index 0000000..711bd31
--- /dev/null
+++ b/strace/tests/setresugid.c
@@ -0,0 +1,113 @@
+/*
+ * Check decoding of setresuid/setresgid/setresuid32/setresgid32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <errno.h>
+#include <stdio.h>
+#include <unistd.h>
+
+static int
+ugid2int(const unsigned UGID_TYPE ugid)
+{
+	if ((unsigned UGID_TYPE) -1U == ugid)
+		return -1;
+	else
+		return ugid;
+}
+
+static void
+print_int(const unsigned int num)
+{
+	if (num == -1U)
+		printf("-1");
+	else
+		printf("%u", num);
+}
+
+static int
+num_matches_id(const unsigned int num, const unsigned int ugid)
+{
+	return num == ugid || num == -1U;
+}
+
+#define TRIPLE(val)	\
+	{ val, ugid, ugid }, { ugid, val, ugid }, { ugid, ugid, val }
+
+int
+main(void)
+{
+	unsigned int ugid = GETUGID;
+	CHECK_OVERFLOWUGID(ugid);
+
+	const struct {
+		const long r, e, s;
+	} tests[] = {
+		{ ugid, ugid, ugid },
+		TRIPLE((unsigned long) 0xffffffff00000000ULL | ugid),
+		TRIPLE(-1U),
+		TRIPLE(-1L),
+		TRIPLE(0xffff0000U | ugid),
+		TRIPLE(0xffff),
+		TRIPLE(0xc0deffffU)
+	};
+
+	unsigned int i;
+
+	for (i = 0; i < ARRAY_SIZE(tests); ++i) {
+		const unsigned int rn = ugid2int(tests[i].r);
+		const unsigned int en = ugid2int(tests[i].e);
+		const unsigned int sn = ugid2int(tests[i].s);
+
+		if (!num_matches_id(rn, ugid) ||
+		    !num_matches_id(en, ugid) ||
+		    !num_matches_id(sn, ugid))
+			continue;
+
+		if (syscall(SYSCALL_NR, tests[i].r, tests[i].e, tests[i].s)) {
+			if (!i && ENOSYS == errno) {
+				printf("%s(%u, %u, %u) = -1 ENOSYS (%m)\n",
+				       SYSCALL_NAME, ugid, ugid, ugid);
+				break;
+			}
+			perror_msg_and_fail("%s(%#lx, %#lx, %#lx)",
+					    SYSCALL_NAME,
+					    tests[i].r, tests[i].e, tests[i].s);
+		}
+
+		printf("%s(", SYSCALL_NAME);
+		print_int(rn);
+		printf(", ");
+		print_int(en);
+		printf(", ");
+		print_int(sn);
+		printf(") = 0\n");
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/setresuid.c b/strace/tests/setresuid.c
new file mode 100644
index 0000000..b924f91
--- /dev/null
+++ b/strace/tests/setresuid.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setresuid
+
+# define SYSCALL_NR	__NR_setresuid
+# define SYSCALL_NAME	"setresuid"
+
+# if defined __NR_setresuid32 && __NR_setresuid != __NR_setresuid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_geteuid)
+#  define CHECK_OVERFLOWUGID(arg)	check_overflowuid(arg)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	geteuid()
+#  define CHECK_OVERFLOWUGID(arg)
+# endif
+
+# include "setresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setresuid")
+
+#endif
diff --git a/strace/tests/setresuid.test b/strace/tests/setresuid.test
new file mode 100755
index 0000000..f1219e0
--- /dev/null
+++ b/strace/tests/setresuid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setresuid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a19
diff --git a/strace/tests/setresuid32.c b/strace/tests/setresuid32.c
new file mode 100644
index 0000000..d4187dd
--- /dev/null
+++ b/strace/tests/setresuid32.c
@@ -0,0 +1,17 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setresuid32
+
+# define SYSCALL_NR	__NR_setresuid32
+# define SYSCALL_NAME	"setresuid32"
+# define UGID_TYPE	int
+# define GETUGID	geteuid()
+# define CHECK_OVERFLOWUGID(arg)
+# include "setresugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setresuid32")
+
+#endif
diff --git a/strace/tests/setresuid32.test b/strace/tests/setresuid32.test
new file mode 100755
index 0000000..942a3a6
--- /dev/null
+++ b/strace/tests/setresuid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setresuid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21
diff --git a/strace/tests/setreugid.c b/strace/tests/setreugid.c
new file mode 100644
index 0000000..38c80d5
--- /dev/null
+++ b/strace/tests/setreugid.c
@@ -0,0 +1,106 @@
+/*
+ * Check decoding of setreuid/setregid/setreuid32/setregid32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <errno.h>
+#include <stdio.h>
+#include <unistd.h>
+
+static int
+ugid2int(const unsigned UGID_TYPE ugid)
+{
+	if ((unsigned UGID_TYPE) -1U == ugid)
+		return -1;
+	else
+		return ugid;
+}
+
+static void
+print_int(const unsigned int num)
+{
+	if (num == -1U)
+		printf("-1");
+	else
+		printf("%u", num);
+}
+
+static int
+num_matches_id(const unsigned int num, const unsigned int ugid)
+{
+	return num == ugid || num == -1U;
+}
+
+#define PAIR(val)	{ val, ugid }, { ugid, val }
+
+int
+main(void)
+{
+	unsigned int ugid = GETUGID;
+	CHECK_OVERFLOWUGID(ugid);
+
+	const struct {
+		const long r, e;
+	} tests[] = {
+		{ ugid, ugid },
+		PAIR((unsigned long) 0xffffffff00000000ULL | ugid),
+		PAIR(-1U),
+		PAIR(-1L),
+		PAIR(0xffff0000U | ugid),
+		PAIR(0xffff),
+		PAIR(0xc0deffffU)
+	};
+
+	unsigned int i;
+
+	for (i = 0; i < ARRAY_SIZE(tests); ++i) {
+		const unsigned int rn = ugid2int(tests[i].r);
+		const unsigned int en = ugid2int(tests[i].e);
+
+		if (!num_matches_id(rn, ugid) || !num_matches_id(en, ugid))
+			continue;
+
+		if (syscall(SYSCALL_NR, tests[i].r, tests[i].e)) {
+			if (!i && ENOSYS == errno) {
+				printf("%s(%u, %u) = -1 ENOSYS (%m)\n",
+				       SYSCALL_NAME, ugid, ugid);
+				break;
+			}
+			perror_msg_and_fail("%s(%#lx, %#lx)", SYSCALL_NAME,
+					    tests[i].r, tests[i].e);
+		}
+
+		printf("%s(", SYSCALL_NAME);
+		print_int(rn);
+		printf(", ");
+		print_int(en);
+		printf(") = 0\n");
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/setreuid.c b/strace/tests/setreuid.c
new file mode 100644
index 0000000..dc13038
--- /dev/null
+++ b/strace/tests/setreuid.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setreuid
+
+# define SYSCALL_NR	__NR_setreuid
+# define SYSCALL_NAME	"setreuid"
+
+# if defined __NR_setreuid32 && __NR_setreuid != __NR_setreuid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_geteuid)
+#  define CHECK_OVERFLOWUGID(arg)	check_overflowuid(arg)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	geteuid()
+#  define CHECK_OVERFLOWUGID(arg)
+# endif
+
+# include "setreugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setreuid")
+
+#endif
diff --git a/strace/tests/setreuid.test b/strace/tests/setreuid.test
new file mode 100755
index 0000000..b6db3c1
--- /dev/null
+++ b/strace/tests/setreuid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setreuid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a15
diff --git a/strace/tests/setreuid32.c b/strace/tests/setreuid32.c
new file mode 100644
index 0000000..43b7b91
--- /dev/null
+++ b/strace/tests/setreuid32.c
@@ -0,0 +1,17 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setreuid32
+
+# define SYSCALL_NR	__NR_setreuid32
+# define SYSCALL_NAME	"setreuid32"
+# define UGID_TYPE	int
+# define GETUGID	geteuid()
+# define CHECK_OVERFLOWUGID(arg)
+# include "setreugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setreuid32")
+
+#endif
diff --git a/strace/tests/setreuid32.test b/strace/tests/setreuid32.test
new file mode 100755
index 0000000..23323d4
--- /dev/null
+++ b/strace/tests/setreuid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setreuid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a17
diff --git a/strace/tests/setrlimit.c b/strace/tests/setrlimit.c
new file mode 100644
index 0000000..b5a14c6
--- /dev/null
+++ b/strace/tests/setrlimit.c
@@ -0,0 +1,76 @@
+/*
+ * Check decoding of setrlimit syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setrlimit
+
+# include "xgetrlimit.c"
+
+int
+main(void)
+{
+	kernel_ulong_t *const rlimit = tail_alloc(sizeof(*rlimit) * 2);
+	const struct xlat *xlat;
+
+	for (xlat = resources; xlat->str; ++xlat) {
+		unsigned long res = 0xfacefeed00000000 | xlat->val;
+		long rc = syscall(__NR_setrlimit, res, 0);
+		printf("setrlimit(%s, NULL) = %ld %s (%m)\n",
+		       xlat->str, rc, errno2name());
+
+		struct rlimit libc_rlim = {};
+		if (getrlimit((int) res, &libc_rlim))
+			continue;
+		rlimit[0] = libc_rlim.rlim_cur;
+		rlimit[1] = libc_rlim.rlim_max;
+
+		rc = syscall(__NR_setrlimit, res, rlimit);
+		int saved_errno = errno;
+		printf("setrlimit(%s, {rlim_cur=%s, rlim_max=%s})",
+		       xlat->str,
+		       sprint_rlim(rlimit[0]), sprint_rlim(rlimit[1]));
+		if (rc) {
+			errno = saved_errno;
+			printf(" = %ld %s (%m)\n", rc, errno2name());
+		} else {
+			printf(" = 0\n");
+		}
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setrlimit")
+
+#endif
diff --git a/strace/tests/setrlimit.test b/strace/tests/setrlimit.test
new file mode 100755
index 0000000..7920608
--- /dev/null
+++ b/strace/tests/setrlimit.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of getrlimit/ugetrlimit/setrlimit syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a27
diff --git a/strace/tests/setugid.c b/strace/tests/setugid.c
new file mode 100644
index 0000000..dd6b921
--- /dev/null
+++ b/strace/tests/setugid.c
@@ -0,0 +1,97 @@
+/*
+ * Check decoding of setuid/setgid/setuid32/setgid32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <errno.h>
+#include <stdio.h>
+#include <unistd.h>
+
+static int
+ugid2int(const unsigned UGID_TYPE ugid)
+{
+	if ((unsigned UGID_TYPE) -1U == ugid)
+		return -1;
+	else
+		return ugid;
+}
+
+int
+main(void)
+{
+	unsigned int ugid = GETUGID;
+	CHECK_OVERFLOWUGID(ugid);
+
+	const long tests[] = {
+		ugid,
+		0xffff0000U | ugid,
+		(unsigned long) 0xffffffff00000000ULL | ugid,
+		0xffffU,
+		-1U,
+		-1L
+	};
+
+	unsigned int i;
+
+	for (i = 0; i < ARRAY_SIZE(tests); ++i) {
+		const unsigned int num = ugid2int(tests[i]);
+		long expected;
+
+		if (num == ugid)
+			expected = 0;
+		else if (num == -1U)
+			expected = -1;
+		else
+			continue;
+
+		const long rc = syscall(SYSCALL_NR, tests[i]);
+		int saved_errno = errno;
+		if (rc != expected) {
+			if (!i && ENOSYS == errno) {
+				printf("%s(%u) = -1 ENOSYS (%m)\n",
+				       SYSCALL_NAME, ugid);
+				break;
+			}
+			perror_msg_and_fail("%s(%#lx) != %ld",
+					    SYSCALL_NAME, tests[i], expected);
+		}
+
+		printf("%s(", SYSCALL_NAME);
+		if (num == -1U)
+			printf("-1");
+		else
+			printf("%u", num);
+		errno = saved_errno;
+		if (expected)
+			printf(") = -1 %s (%m)\n", errno2name());
+		else
+			printf(") = 0\n");
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/setuid.c b/strace/tests/setuid.c
new file mode 100644
index 0000000..c9e97e0
--- /dev/null
+++ b/strace/tests/setuid.c
@@ -0,0 +1,25 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setuid
+
+# define SYSCALL_NR	__NR_setuid
+# define SYSCALL_NAME	"setuid"
+
+# if defined __NR_setuid32 && __NR_setuid != __NR_setuid32
+#  define UGID_TYPE	short
+#  define GETUGID	syscall(__NR_geteuid)
+#  define CHECK_OVERFLOWUGID(arg)	check_overflowuid(arg)
+# else
+#  define UGID_TYPE	int
+#  define GETUGID	geteuid()
+#  define CHECK_OVERFLOWUGID(arg)
+# endif
+
+# include "setugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setuid")
+
+#endif
diff --git a/strace/tests/setuid.test b/strace/tests/setuid.test
new file mode 100755
index 0000000..9279233
--- /dev/null
+++ b/strace/tests/setuid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setuid syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/setuid32.c b/strace/tests/setuid32.c
new file mode 100644
index 0000000..9247cb2
--- /dev/null
+++ b/strace/tests/setuid32.c
@@ -0,0 +1,17 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_setuid32
+
+# define SYSCALL_NR	__NR_setuid32
+# define SYSCALL_NAME	"setuid32"
+# define UGID_TYPE	int
+# define GETUGID	geteuid()
+# define CHECK_OVERFLOWUGID(arg)
+# include "setugid.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_setuid32")
+
+#endif
diff --git a/strace/tests/setuid32.test b/strace/tests/setuid32.test
new file mode 100755
index 0000000..7998392
--- /dev/null
+++ b/strace/tests/setuid32.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setuid32 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12
diff --git a/strace/tests/shmxt.c b/strace/tests/shmxt.c
new file mode 100644
index 0000000..8e087f3
--- /dev/null
+++ b/strace/tests/shmxt.c
@@ -0,0 +1,53 @@
+#include "tests.h"
+#include <stdio.h>
+#include <stdlib.h>
+#include <sys/shm.h>
+
+static int id = -1;
+
+static void
+cleanup(void)
+{
+	shmctl(id, IPC_RMID, NULL);
+	id = -1;
+}
+
+#ifdef __alpha__
+# define SHMAT "osf_shmat"
+#else
+# define SHMAT "shmat"
+#endif
+
+int
+main(void)
+{
+	id = shmget(IPC_PRIVATE, 1, 0600);
+	if (id < 0)
+		perror_msg_and_skip("shmget");
+	atexit(cleanup);
+
+	shmat(id, NULL, SHM_REMAP);
+	printf("%s(%d, NULL, SHM_REMAP) = -1 %s (%m)\n",
+	       SHMAT, id, errno2name());
+
+	void *shmaddr = shmat(id, NULL, SHM_RDONLY);
+	if (shmaddr == (void *)(-1))
+		perror_msg_and_skip("shmat SHM_RDONLY");
+	printf("%s(%d, NULL, SHM_RDONLY) = %p\n", SHMAT, id, shmaddr);
+
+	if (shmdt(shmaddr))
+		perror_msg_and_skip("shmdt");
+	printf("shmdt(%p) = 0\n", shmaddr);
+
+	++shmaddr;
+	void *shmaddr2 = shmat(id, shmaddr, SHM_RND);
+	if (shmaddr2 == (void *)(-1))
+		printf("%s(%d, %p, SHM_RND) = -1 %s (%m)\n",
+		       SHMAT, id, shmaddr, errno2name());
+	else
+		printf("%s(%d, %p, SHM_RND) = %p\n",
+		       SHMAT, id, shmaddr, shmaddr2);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/shmxt.test b/strace/tests/shmxt.test
new file mode 100755
index 0000000..3757cfa
--- /dev/null
+++ b/strace/tests/shmxt.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check shmat and shmdt syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+case "$STRACE_ARCH" in
+	alpha) shmat=osf_shmat ;;
+	*) shmat=shmat ;;
+esac
+
+run_strace_match_diff -e trace=$shmat,shmdt -a11
diff --git a/strace/tests/shutdown.c b/strace/tests/shutdown.c
new file mode 100644
index 0000000..d770c43
--- /dev/null
+++ b/strace/tests/shutdown.c
@@ -0,0 +1,15 @@
+/* Check decoding of shutdown syscall. */
+
+#include "tests.h"
+#include <stdio.h>
+#include <sys/socket.h>
+
+int
+main(void)
+{
+	int rc = shutdown(-1, SHUT_RDWR);
+	printf("shutdown(-1, SHUT_RDWR) = %d %s (%m)\n", rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/shutdown.test b/strace/tests/shutdown.test
new file mode 100755
index 0000000..22f0d5a
--- /dev/null
+++ b/strace/tests/shutdown.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of shutdown syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24
diff --git a/strace/tests/sigaction.awk b/strace/tests/sigaction.awk
new file mode 100644
index 0000000..5c6b6d0
--- /dev/null
+++ b/strace/tests/sigaction.awk
@@ -0,0 +1,64 @@
+#!/bin/gawk
+#
+# Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+BEGIN {
+	n1[1] = "SIG_IGN, \\[HUP INT\\], SA_RESTORER\\|SA_RESTART, 0x[0-9a-f]+"
+	n2[1] = "SIG_IGN, \\[HUP INT\\], SA_RESTART"
+
+	n1[2] = "0x[0-9a-f]+, \\[QUIT TERM\\], SA_RESTORER\\|SA_SIGINFO, 0x[0-9a-f]+"
+	n2[2] = "0x[0-9a-f]+, \\[QUIT TERM\\], SA_SIGINFO"
+
+	n1[3] = "SIG_DFL, \\[\\], SA_RESTORER, 0x[0-9a-f]+"
+	n2[3] = "SIG_DFL, \\[\\], 0"
+
+	n1[4] = "SIG_DFL, ~\\[HUP( ((RT|SIGRT)[^] ]+|[3-9][0-9]|1[0-9][0-9]))*\\], SA_RESTORER, 0x[0-9a-f]+"
+	n2[4] = "SIG_DFL, ~\\[HUP( ((RT|SIGRT)[^] ]+|[3-9][0-9]|1[0-9][0-9]))*\\], 0"
+
+	o1[1] = o2[1] = "SIG_DFL, \\[\\], 0"
+
+	for (i = 2; i < 5; i++) {
+		o1[i] = n1[i - 1]
+		o2[i] = n2[i - 1]
+	}
+
+	a1 = "(0x[0-9a-f]+, )?(4|8|16)"
+	a2 = "(4|8|16)(, 0x[0-9a-f]+)?"
+	a3 = "0x[0-9a-f]+, (4|8|16)"
+
+	for (i = 1; i < 5; i++) {
+		r[i] = "^rt_sigaction\\(SIGUSR2, (" \
+			"\\{" n1[i] "\\}, \\{" o1[i] "\\}, " a1 "|" \
+			"\\{" n2[i] "\\}, \\{" o2[i] "\\}, " a2 "|" \
+			"\\{" n2[i] "\\}, \\{" o2[i] "\\}, " a3 ")\\) = 0$"
+	}
+	s[5] = "+++ exited with 0 +++"
+
+	lines = 5
+	fail = 0
+}
+
+@include "match.awk"
diff --git a/strace/tests/sigaction.c b/strace/tests/sigaction.c
new file mode 100644
index 0000000..1c034ff
--- /dev/null
+++ b/strace/tests/sigaction.c
@@ -0,0 +1,67 @@
+/*
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <assert.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include <signal.h>
+
+static void handle_signal(int no)
+{
+	_exit(128 + no);
+}
+
+int
+main(void)
+{
+	struct sigaction sa, sa0;
+
+	sa.sa_handler = SIG_IGN;
+	sigemptyset(&sa.sa_mask);
+	sigaddset(&sa.sa_mask, SIGHUP);
+	sigaddset(&sa.sa_mask, SIGINT);
+	sa.sa_flags = SA_RESTART;
+	assert(!sigaction(SIGUSR2, &sa, &sa0));
+
+	sa.sa_handler = handle_signal;
+	sigemptyset(&sa.sa_mask);
+	sigaddset(&sa.sa_mask, SIGQUIT);
+	sigaddset(&sa.sa_mask, SIGTERM);
+	sa.sa_flags = SA_SIGINFO;
+	assert(!sigaction(SIGUSR2, &sa, &sa0));
+
+	sa.sa_handler = SIG_DFL;
+	sigemptyset(&sa.sa_mask);
+	sa.sa_flags = 0;
+	assert(!sigaction(SIGUSR2, &sa, &sa0));
+
+	sigfillset(&sa.sa_mask);
+	sigdelset(&sa.sa_mask, SIGHUP);
+	assert(!sigaction(SIGUSR2, &sa, &sa0));
+
+	return 0;
+}
diff --git a/strace/tests/sigaction.test b/strace/tests/sigaction.test
new file mode 100755
index 0000000..fcde3ba
--- /dev/null
+++ b/strace/tests/sigaction.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check rt_sigaction decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -ert_sigaction $args
+match_awk
+
+exit 0
diff --git a/strace/tests/sigaltstack.c b/strace/tests/sigaltstack.c
new file mode 100644
index 0000000..884e3c5
--- /dev/null
+++ b/strace/tests/sigaltstack.c
@@ -0,0 +1,15 @@
+#include "tests.h"
+#include <signal.h>
+
+int
+main(void)
+{
+	stack_t ss = {
+		.ss_sp = (void *) 0xbaadf00d,
+		.ss_flags = SS_DISABLE,
+		.ss_size = 0xdeadbeef
+	};
+	if (sigaltstack(&ss, (stack_t *) 0))
+		perror_msg_and_skip("sigaltstack");
+	return 0;
+}
diff --git a/strace/tests/sigaltstack.expected b/strace/tests/sigaltstack.expected
new file mode 100644
index 0000000..be8092b
--- /dev/null
+++ b/strace/tests/sigaltstack.expected
@@ -0,0 +1,2 @@
+sigaltstack({ss_sp=0xbaadf00d, ss_flags=SS_DISABLE, ss_size=3735928559}, NULL) = 0
++++ exited with 0 +++
diff --git a/strace/tests/sigaltstack.test b/strace/tests/sigaltstack.test
new file mode 100755
index 0000000..ff83c2e
--- /dev/null
+++ b/strace/tests/sigaltstack.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check sigaltstack syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -e sigaltstack $args
+match_diff
+
+exit 0
diff --git a/strace/tests/siginfo.c b/strace/tests/siginfo.c
new file mode 100644
index 0000000..48cfaf3
--- /dev/null
+++ b/strace/tests/siginfo.c
@@ -0,0 +1,170 @@
+/*
+ * Check SIGCHLD siginfo_t decoding.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <signal.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/wait.h>
+
+static siginfo_t sinfo;
+
+static void
+handler(int no, siginfo_t *si, void *uc)
+{
+	memcpy(&sinfo, si, sizeof(sinfo));
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	pid_t pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		char c;
+		(void) close(1);
+		assert(read(0, &c, sizeof(c)) == 1);
+		return 42;
+	}
+
+	(void) close(0);
+
+	struct sigaction sa = {
+		.sa_sigaction = handler,
+		.sa_flags = SA_SIGINFO
+	};
+	assert(sigaction(SIGCHLD, &sa, NULL) == 0);
+
+	sigset_t block_mask, unblock_mask;
+	assert(sigprocmask(SIG_SETMASK, NULL, &block_mask) == 0);
+	sigaddset(&block_mask, SIGCHLD);
+	assert(sigprocmask(SIG_SETMASK, &block_mask, NULL) == 0);
+
+	unblock_mask = block_mask;
+	sigdelset(&unblock_mask, SIGCHLD);
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	sigsuspend(&unblock_mask);
+	tprintf("--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED"
+		", si_pid=%d, si_uid=%u, si_status=%d"
+		", si_utime=%llu, si_stime=%llu} ---\n",
+		sinfo.si_pid, sinfo.si_uid, sinfo.si_status,
+		widen_to_ull(sinfo.si_utime), widen_to_ull(sinfo.si_stime));
+
+	int s;
+	assert(wait(&s) == pid);
+	assert(WIFEXITED(s) && WEXITSTATUS(s) == 42);
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		(void) close(1);
+		char c;
+		assert(read(0, &c, sizeof(c)) == 1);
+		(void) raise(SIGUSR1);
+		return 1;
+	}
+
+	(void) close(0);
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	sigsuspend(&unblock_mask);
+	tprintf("--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_KILLED"
+		", si_pid=%d, si_uid=%u, si_status=SIGUSR1"
+		", si_utime=%llu, si_stime=%llu} ---\n",
+		sinfo.si_pid, sinfo.si_uid,
+		widen_to_ull(sinfo.si_utime), widen_to_ull(sinfo.si_stime));
+
+	assert(wait(&s) == pid);
+	assert(WIFSIGNALED(s) && WTERMSIG(s) == SIGUSR1);
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		(void) close(1);
+		raise(SIGSTOP);
+		char c;
+		assert(read(0, &c, sizeof(c)) == 1);
+		return 0;
+	}
+
+	(void) close(0);
+
+	sigsuspend(&unblock_mask);
+	tprintf("--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_STOPPED"
+		", si_pid=%d, si_uid=%u, si_status=SIGSTOP"
+		", si_utime=%llu, si_stime=%llu} ---\n",
+		sinfo.si_pid, sinfo.si_uid,
+		widen_to_ull(sinfo.si_utime), widen_to_ull(sinfo.si_stime));
+
+	assert(kill(pid, SIGCONT) == 0);
+
+	sigsuspend(&unblock_mask);
+	tprintf("--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_CONTINUED"
+		", si_pid=%d, si_uid=%u, si_status=SIGCONT"
+		", si_utime=%llu, si_stime=%llu} ---\n",
+		sinfo.si_pid, sinfo.si_uid,
+		widen_to_ull(sinfo.si_utime), widen_to_ull(sinfo.si_stime));
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	sigsuspend(&unblock_mask);
+	tprintf("--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED"
+		", si_pid=%d, si_uid=%u, si_status=0"
+		", si_utime=%llu, si_stime=%llu} ---\n",
+		sinfo.si_pid, sinfo.si_uid,
+		widen_to_ull(sinfo.si_utime), widen_to_ull(sinfo.si_stime));
+
+	assert(wait(&s) == pid && s == 0);
+
+	tprintf("%s\n", "+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/siginfo.test b/strace/tests/siginfo.test
new file mode 100755
index 0000000..725f714
--- /dev/null
+++ b/strace/tests/siginfo.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check SIGCHLD siginfo_t decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=none
diff --git a/strace/tests/signal2name.c b/strace/tests/signal2name.c
new file mode 100644
index 0000000..e301f4e
--- /dev/null
+++ b/strace/tests/signal2name.c
@@ -0,0 +1,55 @@
+#include "tests.h"
+#include <signal.h>
+
+#define CASE(x) case x: return #x
+
+const char *
+signal2name(int sig)
+{
+	switch (sig) {
+	CASE(SIGALRM);
+	CASE(SIGBUS);
+	CASE(SIGCHLD);
+	CASE(SIGCONT);
+	CASE(SIGFPE);
+	CASE(SIGHUP);
+	CASE(SIGILL);
+	CASE(SIGINT);
+	CASE(SIGIO);
+	CASE(SIGPIPE);
+	CASE(SIGPROF);
+	CASE(SIGQUIT);
+	CASE(SIGSEGV);
+	CASE(SIGSYS);
+	CASE(SIGTERM);
+	CASE(SIGTRAP);
+	CASE(SIGTSTP);
+	CASE(SIGTTIN);
+	CASE(SIGTTOU);
+	CASE(SIGURG);
+	CASE(SIGUSR1);
+	CASE(SIGUSR2);
+	CASE(SIGVTALRM);
+	CASE(SIGWINCH);
+	CASE(SIGXCPU);
+	CASE(SIGXFSZ);
+#if defined ALPHA
+	CASE(SIGABRT);
+	CASE(SIGEMT);
+	CASE(SIGINFO);
+#elif defined SPARC || defined SPARC64
+	CASE(SIGABRT);
+	CASE(SIGEMT);
+	CASE(SIGLOST);
+#elif defined MIPS
+	CASE(SIGEMT);
+	CASE(SIGIOT);
+	CASE(SIGPWR);
+#else
+	CASE(SIGABRT);
+	CASE(SIGPWR);
+	CASE(SIGSTKFLT);
+#endif
+	default: perror_msg_and_fail("unknown signal number %d", sig);
+	}
+}
diff --git a/strace/tests/signal_receive.c b/strace/tests/signal_receive.c
new file mode 100644
index 0000000..1c4293e
--- /dev/null
+++ b/strace/tests/signal_receive.c
@@ -0,0 +1,45 @@
+#include "tests.h"
+#include <signal.h>
+#include <stdio.h>
+#include <unistd.h>
+
+void sig_print(const char *signame, const int pid, const int uid)
+{
+	printf("kill(%d, %s) = 0\n"
+	       "--- %s {si_signo=%s, si_code=SI_USER, si_pid=%d"
+	       ", si_uid=%d} ---\n",
+	       pid, signame, signame, signame, pid, uid);
+}
+
+static void
+handler(int sig)
+{
+}
+
+int
+main(void)
+{
+	int sig, pid = getpid(), uid = getuid();
+	const struct sigaction act = { .sa_handler = handler };
+	sigset_t mask;
+	sigemptyset(&mask);
+
+	for (sig = 1; sig <= 31; sig++) {
+		if( sig != SIGKILL && sig != SIGSTOP) {
+			sigaction(sig, &act, NULL);
+			sigaddset(&mask, sig);
+		}
+	}
+	sigprocmask(SIG_UNBLOCK, &mask, NULL);
+
+	for (sig = 1; sig <= 31; sig++) {
+		if(sig != SIGKILL && sig != SIGSTOP) {
+			if (kill(pid, sig) != 0)
+				perror_msg_and_fail("kill: %d", sig);
+			sig_print(signal2name(sig), pid, uid);
+		}
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/signal_receive.test b/strace/tests/signal_receive.test
new file mode 100755
index 0000000..9685b66
--- /dev/null
+++ b/strace/tests/signal_receive.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check whether strace traces signals properly.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a16 -e trace=kill
diff --git a/strace/tests/signalfd.c b/strace/tests/signalfd.c
new file mode 100644
index 0000000..7b1d6ce
--- /dev/null
+++ b/strace/tests/signalfd.c
@@ -0,0 +1,54 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+
+#if defined HAVE_SYS_SIGNALFD_H && defined HAVE_SIGNALFD && defined O_CLOEXEC
+
+# include <signal.h>
+# include <unistd.h>
+# include <sys/signalfd.h>
+
+int
+main(void)
+{
+	sigset_t mask;
+	sigemptyset(&mask);
+	sigaddset(&mask, SIGUSR2);
+	sigaddset(&mask, SIGCHLD);
+	(void) close(0);
+	if (signalfd(-1, &mask, O_CLOEXEC | O_NONBLOCK))
+		perror_msg_and_skip("signalfd");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_SYS_SIGNALFD_H && HAVE_SIGNALFD && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/signalfd.expected b/strace/tests/signalfd.expected
new file mode 100644
index 0000000..21937bc
--- /dev/null
+++ b/strace/tests/signalfd.expected
@@ -0,0 +1 @@
+signalfd4\(-1, \[(USR2 CHLD|CHLD USR2)\], (4|8|16), SFD_CLOEXEC\|SFD_NONBLOCK\) += 0
diff --git a/strace/tests/signalfd.test b/strace/tests/signalfd.test
new file mode 100755
index 0000000..dcbfe68
--- /dev/null
+++ b/strace/tests/signalfd.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check signalfd4 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -e signalfd4 $args
+match_grep
+
+exit 0
diff --git a/strace/tests/sigreturn.c b/strace/tests/sigreturn.c
new file mode 100644
index 0000000..dace040
--- /dev/null
+++ b/strace/tests/sigreturn.c
@@ -0,0 +1,57 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdlib.h>
+#include <signal.h>
+
+#ifdef ASM_SIGRTMIN
+# define RT_0 ASM_SIGRTMIN
+#else
+/* Linux kernel >= 3.18 defines SIGRTMIN to 32 on all architectures. */
+# define RT_0 32
+#endif
+
+static void handler(int sig)
+{
+}
+
+int main(void) {
+	sigset_t set;
+	sigemptyset(&set);
+	sigaddset(&set, SIGUSR2);
+	sigaddset(&set, SIGCHLD);
+	sigaddset(&set, RT_0 +  3);
+	sigaddset(&set, RT_0 +  4);
+	sigaddset(&set, RT_0 +  5);
+	sigaddset(&set, RT_0 + 26);
+	sigaddset(&set, RT_0 + 27);
+	sigprocmask(SIG_SETMASK, &set, NULL);
+	signal(SIGUSR1, handler);
+	raise(SIGUSR1);
+	return 0;
+}
diff --git a/strace/tests/sigreturn.test b/strace/tests/sigreturn.test
new file mode 100755
index 0000000..f9a612b
--- /dev/null
+++ b/strace/tests/sigreturn.test
@@ -0,0 +1,48 @@
+#!/bin/sh
+#
+# Check rt_sigprocmask and sigreturn/rt_sigreturn decoding.
+#
+# Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -esignal $args
+
+mask='\[(USR2 CHLD|CHLD USR2) RT_3 RT_4 RT_5 RT_26 RT_27\]'
+rt_sigprocmask='rt_sigprocmask\(SIG_SETMASK, '"$mask"', NULL, [[:digit:]]+\) += 0'
+osf_sigprocmask='osf_sigprocmask\(SIG_SETMASK, '"$mask"'\) += 0 +\(old mask \[[^]]*\]\)'
+EXPECTED="$LOG.expected"
+
+cat > "$EXPECTED" << __EOF__
+$rt_sigprocmask|$osf_sigprocmask
+(rt_)?sigreturn\\((\\{mask=$mask\\})?\\) += 0
+__EOF__
+
+match_grep "$LOG" "$EXPECTED"
+rm -f "$EXPECTED"
+
+exit 0
diff --git a/strace/tests/sleep.c b/strace/tests/sleep.c
new file mode 100644
index 0000000..f4bce3c
--- /dev/null
+++ b/strace/tests/sleep.c
@@ -0,0 +1,49 @@
+/*
+ * A simple nanosleep based sleep(1) replacement.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdlib.h>
+#include <time.h>
+
+int
+main(int ac, char **av)
+{
+	if (ac < 2)
+		error_msg_and_fail("missing operand");
+
+	if (ac > 2)
+		error_msg_and_fail("extra operand");
+
+	struct timespec ts = { atoi(av[1]), 0 };
+
+	if (nanosleep(&ts, NULL))
+		perror_msg_and_fail("nanosleep");
+
+	return 0;
+}
diff --git a/strace/tests/socketcall.c b/strace/tests/socketcall.c
new file mode 100644
index 0000000..5ccddc4
--- /dev/null
+++ b/strace/tests/socketcall.c
@@ -0,0 +1,95 @@
+/*
+ * Check decoding of socketcall syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_socketcall
+
+# include <assert.h>
+# include <stdio.h>
+# include <unistd.h>
+
+# include "xlat.h"
+# include "xlat/socketcalls.h"
+
+static const char *
+xlookup_uint(const struct xlat *xlat, const unsigned int val)
+{
+	for (; xlat->str != NULL; xlat++)
+		if (xlat->val == val)
+			return xlat->str;
+	return NULL;
+}
+
+static const int sc_min = 1, sc_max = 20;
+static void *efault;
+
+static void
+test_socketcall(const int i, const void *const addr)
+{
+	const unsigned long call =
+		(unsigned long) 0xfacefeed00000000 | (unsigned int) i;
+
+	long rc = syscall(__NR_socketcall, call, addr);
+
+	if (i < sc_min || i > sc_max) {
+		printf("socketcall(%d, %p) = %ld %s (%m)\n",
+		       (int) call, addr, rc, errno2name());
+	} else if (addr == efault) {
+		const char *const str = xlookup_uint(socketcalls, i);
+		assert(str);
+		printf("socketcall(%s, %p) = %ld %s (%m)\n",
+		       str, addr, rc, errno2name());
+	}
+}
+int
+main(void)
+{
+	assert((unsigned) sc_min == socketcalls[0].val);
+	assert((unsigned) sc_max == socketcalls[ARRAY_SIZE(socketcalls) - 2].val);
+
+	const unsigned long *const args = tail_alloc(sizeof(*args) * 6);
+	efault = tail_alloc(1) + 1;
+
+	int i;
+	for (i = sc_min - 3; i <= sc_max + 3; ++i) {
+		test_socketcall(i, efault);
+		test_socketcall(i, args);
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_socketcall")
+
+#endif
diff --git a/strace/tests/socketcall.test b/strace/tests/socketcall.test
new file mode 100755
index 0000000..959bc83
--- /dev/null
+++ b/strace/tests/socketcall.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of socketcall syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20
diff --git a/strace/tests/sockname.c b/strace/tests/sockname.c
new file mode 100644
index 0000000..56a8a36
--- /dev/null
+++ b/strace/tests/sockname.c
@@ -0,0 +1,160 @@
+/*
+ * Check decoding of sockname family syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stddef.h>
+#include <stdio.h>
+#include <string.h>
+#include <signal.h>
+#include <unistd.h>
+#include <sys/wait.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+#ifndef TEST_SYSCALL_NAME
+# error TEST_SYSCALL_NAME must be defined
+#endif
+
+#define TEST_SYSCALL_STR__(a) #a
+#define TEST_SYSCALL_STR_(a) TEST_SYSCALL_STR__(a)
+#define TEST_SYSCALL_STR TEST_SYSCALL_STR_(TEST_SYSCALL_NAME)
+#define TEST_SOCKET TEST_SYSCALL_STR ".socket"
+
+#ifdef TEST_SYSCALL_PREPARE
+# define PREPARE_TEST_SYSCALL_INVOCATION do { TEST_SYSCALL_PREPARE; } while (0)
+#else
+# define PREPARE_TEST_SYSCALL_INVOCATION do {} while (0)
+#endif
+
+#ifndef PREFIX_S_ARGS
+# define PREFIX_S_ARGS
+#endif
+#ifndef PREFIX_F_ARGS
+# define PREFIX_F_ARGS
+#endif
+#ifndef PREFIX_S_STR
+# define PREFIX_S_STR ""
+#endif
+#ifndef PREFIX_F_STR
+# define PREFIX_F_STR ""
+#endif
+#ifndef SUFFIX_ARGS
+# define SUFFIX_ARGS
+#endif
+#ifndef SUFFIX_STR
+# define SUFFIX_STR ""
+#endif
+
+static void
+test_sockname_syscall(const int fd)
+{
+	socklen_t *const plen = tail_alloc(sizeof(*plen));
+	*plen = sizeof(struct sockaddr_un);
+	struct sockaddr_un *addr = tail_alloc(*plen);
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	int rc = TEST_SYSCALL_NAME(fd PREFIX_S_ARGS, (void *) addr,
+				   plen SUFFIX_ARGS);
+	if (rc < 0)
+		perror_msg_and_skip(TEST_SYSCALL_STR);
+	printf("%s(%d%s, {sa_family=AF_UNIX, sun_path=\"%s\"}"
+	       ", [%d->%d]%s) = %d\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_S_STR, addr->sun_path,
+	       (int) sizeof(struct sockaddr_un), (int) *plen, SUFFIX_STR, rc);
+
+	memset(addr, 0, sizeof(*addr));
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_S_ARGS, (void *) addr,
+			       plen SUFFIX_ARGS);
+	if (rc < 0)
+		perror_msg_and_skip(TEST_SYSCALL_STR);
+	printf("%s(%d%s, {sa_family=AF_UNIX, sun_path=\"%s\"}"
+	       ", [%d]%s) = %d\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_S_STR, addr->sun_path,
+	       (int) *plen, SUFFIX_STR, rc);
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_F_ARGS, (void *) addr, 0 SUFFIX_ARGS);
+	printf("%s(%d%s, %p, NULL%s) = %d %s (%m)\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_F_STR, addr, SUFFIX_STR, rc,
+	       errno2name());
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_S_ARGS, 0, 0 SUFFIX_ARGS);
+	if (rc < 0)
+		printf("%s(%d%s, NULL, NULL%s) = %d %s (%m)\n",
+		       TEST_SYSCALL_STR, fd, PREFIX_F_STR, SUFFIX_STR, rc,
+		       errno2name());
+	else
+		printf("%s(%d%s, NULL, NULL%s) = %d\n",
+		       TEST_SYSCALL_STR, fd, PREFIX_S_STR, SUFFIX_STR, rc);
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_F_ARGS, (void *) addr,
+			       plen + 1 SUFFIX_ARGS);
+	printf("%s(%d%s, %p, %p%s) = %d %s (%m)\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_F_STR, addr,
+	       plen + 1, SUFFIX_STR, rc, errno2name());
+
+	const size_t offsetof_sun_path = offsetof(struct sockaddr_un, sun_path);
+	*plen = offsetof_sun_path;
+	memset(addr->sun_path, 'A', sizeof(addr->sun_path));
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_S_ARGS, (void *) addr,
+			       plen SUFFIX_ARGS);
+	if (rc < 0)
+		perror_msg_and_skip(TEST_SYSCALL_STR);
+	printf("%s(%d%s, {sa_family=AF_UNIX}, [%d->%d]%s) = %d\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_S_STR,
+	       (int) offsetof_sun_path, (int) *plen, SUFFIX_STR, rc);
+
+	++addr;
+	*plen = sizeof(struct sockaddr);
+	addr = (void *) addr - *plen;
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_S_ARGS, (void *) addr,
+			       plen SUFFIX_ARGS);
+	if (rc < 0)
+		perror_msg_and_skip(TEST_SYSCALL_STR);
+	printf("%s(%d%s, {sa_family=AF_UNIX, sun_path=\"%.*s\"}"
+	       ", [%d->%d]%s) = %d\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_S_STR,
+	       (int) (sizeof(struct sockaddr) - offsetof_sun_path),
+	       addr->sun_path, (int) sizeof(struct sockaddr),
+	       (int) *plen, SUFFIX_STR, rc);
+
+	PREPARE_TEST_SYSCALL_INVOCATION;
+	rc = TEST_SYSCALL_NAME(fd PREFIX_F_ARGS, (void *) addr,
+			       plen SUFFIX_ARGS);
+	printf("%s(%d%s, %p, [%d]%s) = %d %s (%m)\n",
+	       TEST_SYSCALL_STR, fd, PREFIX_F_STR, addr,
+	       *plen, SUFFIX_STR, rc, errno2name());
+}
diff --git a/strace/tests/splice.c b/strace/tests/splice.c
new file mode 100644
index 0000000..433cf7f
--- /dev/null
+++ b/strace/tests/splice.c
@@ -0,0 +1,65 @@
+/*
+ * This file is part of splice strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_splice
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd_in = (long int) 0xdeadbeefffffffff;
+	const long int fd_out = (long int) 0xdeadbeeffffffffe;
+	long long int *const off_in = tail_alloc(sizeof(*off_in));
+	long long int *const off_out = tail_alloc(sizeof(*off_out));
+	*off_in = 0xdeadbef1facefed1;
+	*off_out = 0xdeadbef2facefed2;
+	const size_t len = (size_t) 0xdeadbef3facefed3ULL;
+	const unsigned int flags = 15;
+
+	long rc = syscall(__NR_splice,
+			  fd_in, off_in, fd_out, off_out, len, flags);
+	printf("splice(%d, [%lld], %d, [%lld], %zu, %s) = %ld %s (%m)\n",
+	       (int) fd_in, *off_in, (int) fd_out, *off_out, len,
+	       "SPLICE_F_MOVE|SPLICE_F_NONBLOCK|SPLICE_F_MORE|SPLICE_F_GIFT",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_splice")
+
+#endif
diff --git a/strace/tests/splice.test b/strace/tests/splice.test
new file mode 100755
index 0000000..cc5c327
--- /dev/null
+++ b/strace/tests/splice.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check splice syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/stack-fcall-0.c b/strace/tests/stack-fcall-0.c
new file mode 100644
index 0000000..12a260d
--- /dev/null
+++ b/strace/tests/stack-fcall-0.c
@@ -0,0 +1,6 @@
+int f1(int i);
+
+int f0(int i)
+{
+	return f1(i) - i;
+}
diff --git a/strace/tests/stack-fcall-1.c b/strace/tests/stack-fcall-1.c
new file mode 100644
index 0000000..8716702
--- /dev/null
+++ b/strace/tests/stack-fcall-1.c
@@ -0,0 +1,6 @@
+int f2(int i);
+
+int f1(int i)
+{
+	return f2(i) + i;
+}
diff --git a/strace/tests/stack-fcall-2.c b/strace/tests/stack-fcall-2.c
new file mode 100644
index 0000000..19f8cf8
--- /dev/null
+++ b/strace/tests/stack-fcall-2.c
@@ -0,0 +1,6 @@
+int f3(int i);
+
+int f2(int i)
+{
+	return f3(i) - i;
+}
diff --git a/strace/tests/stack-fcall-3.c b/strace/tests/stack-fcall-3.c
new file mode 100644
index 0000000..3af1667
--- /dev/null
+++ b/strace/tests/stack-fcall-3.c
@@ -0,0 +1,6 @@
+#include <unistd.h>
+
+int f3(int i)
+{
+	return getpid() + i;
+}
diff --git a/strace/tests/stack-fcall.c b/strace/tests/stack-fcall.c
new file mode 100644
index 0000000..134d54f
--- /dev/null
+++ b/strace/tests/stack-fcall.c
@@ -0,0 +1,7 @@
+int f0(int i);
+
+int main(int argc, char** argv)
+{
+	f0(argc);
+	return 0;
+}
diff --git a/strace/tests/stat.c b/strace/tests/stat.c
new file mode 100644
index 0000000..f64ff30
--- /dev/null
+++ b/strace/tests/stat.c
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_stat
+
+# define TEST_SYSCALL_NR __NR_stat
+# define TEST_SYSCALL_STR "stat"
+# define SAMPLE_SIZE ((kernel_ulong_t) 43147718418)
+# include "lstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_stat")
+
+#endif
diff --git a/strace/tests/stat.test b/strace/tests/stat.test
new file mode 100755
index 0000000..ba8938c
--- /dev/null
+++ b/strace/tests/stat.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check stat syscall decoding.
+
+. "${srcdir=.}/statx.sh"
diff --git a/strace/tests/stat64.c b/strace/tests/stat64.c
new file mode 100644
index 0000000..c164189
--- /dev/null
+++ b/strace/tests/stat64.c
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_stat64
+
+# define TEST_SYSCALL_NR __NR_stat64
+# define TEST_SYSCALL_STR "stat64"
+# define STRUCT_STAT struct stat64
+# define STRUCT_STAT_STR "struct stat64"
+# define SAMPLE_SIZE ((libc_off_t) 43147718418)
+# include "lstatx.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_stat64")
+
+#endif
diff --git a/strace/tests/stat64.test b/strace/tests/stat64.test
new file mode 100755
index 0000000..abcfb9e
--- /dev/null
+++ b/strace/tests/stat64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check stat64 syscall decoding.
+
+. "${srcdir=.}/statx.sh"
diff --git a/strace/tests/statfs.c b/strace/tests/statfs.c
new file mode 100644
index 0000000..5a87afc
--- /dev/null
+++ b/strace/tests/statfs.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_statfs
+
+# define SYSCALL_ARG_FMT		"\"%s\""
+# define SYSCALL_ARG(file, desc)	(file)
+# define SYSCALL_NR			__NR_statfs
+# define SYSCALL_NAME			"statfs"
+# include "xstatfs.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_statfs")
+
+#endif
diff --git a/strace/tests/statfs.expected b/strace/tests/statfs.expected
new file mode 100644
index 0000000..0fa4510
--- /dev/null
+++ b/strace/tests/statfs.expected
@@ -0,0 +1 @@
+statfs(64)?\("/proc/self/status"(, [1-9][0-9]*)?, \{f_type=PROC_SUPER_MAGIC, f_bsize=[1-9][0-9]*, f_blocks=[0-9]+, f_bfree=[0-9]+, f_bavail=[0-9]+, f_files=[0-9]+, f_ffree=[0-9]+, f_fsid=\{[0-9]+, [0-9]+\}, f_namelen=[1-9][0-9]*(, f_frsize=[0-9]+)?(, f_flags=ST_VALID(\|ST_[A-Z]+)*)?\}\) += 0
diff --git a/strace/tests/statfs.test b/strace/tests/statfs.test
new file mode 100755
index 0000000..6075576
--- /dev/null
+++ b/strace/tests/statfs.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check statfs syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+# this test probes /proc/self/status
+[ -f /proc/self/status ] ||
+	framework_skip_ '/proc/self/status is not available'
+
+run_strace_match_diff -a17
diff --git a/strace/tests/statfs64.c b/strace/tests/statfs64.c
new file mode 100644
index 0000000..b85dce2
--- /dev/null
+++ b/strace/tests/statfs64.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_statfs64
+
+# define SYSCALL_ARG_FMT		"\"%s\""
+# define SYSCALL_ARG(file, desc)	(file)
+# define SYSCALL_NR			__NR_statfs64
+# define SYSCALL_NAME			"statfs64"
+# include "xstatfs64.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_statfs64")
+
+#endif
diff --git a/strace/tests/statfs64.test b/strace/tests/statfs64.test
new file mode 100755
index 0000000..9c0aa27
--- /dev/null
+++ b/strace/tests/statfs64.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check statfs64 syscall decoding.
+
+. "${srcdir=.}/statfs.test"
diff --git a/strace/tests/statx.sh b/strace/tests/statx.sh
new file mode 100755
index 0000000..830e5fc
--- /dev/null
+++ b/strace/tests/statx.sh
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of stat family syscalls.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -P $NAME.sample
diff --git a/strace/tests/strace-E.expected b/strace/tests/strace-E.expected
new file mode 100644
index 0000000..d7823b7
--- /dev/null
+++ b/strace/tests/strace-E.expected
@@ -0,0 +1 @@
+execve\("\./sleep", \["\./sleep", "0"\], \[.*"option_E_var=OPTION_E_VAL".*\]\) = 0
diff --git a/strace/tests/strace-E.test b/strace/tests/strace-E.test
new file mode 100755
index 0000000..d76ec3f
--- /dev/null
+++ b/strace/tests/strace-E.test
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+# Check -E option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./sleep 0 > /dev/null
+run_strace -E option_E_var=OPTION_E_VAL -v $args
+match_grep
diff --git a/strace/tests/strace-S.test b/strace/tests/strace-S.test
new file mode 100755
index 0000000..44c15cc
--- /dev/null
+++ b/strace/tests/strace-S.test
@@ -0,0 +1,32 @@
+#!/bin/sh
+
+# Check -S option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./readv > /dev/null
+
+test_c()
+{
+	local sortby sortopts sedexpr
+	sortby="$1"; shift
+	sortopts="$1"; shift
+	sedexpr="$1"; shift
+
+	run_strace -c -w -S "$sortby" ./readv > /dev/null
+	sed -ne "$sedexpr" < "$LOG" > "$OUT"
+
+	[ -s "$OUT" ] ||
+		fail_ "$STRACE $args output mismatch"
+	LC_ALL=C sort -c $sortopts "$OUT" || {
+		echo 'Actual output:'
+		cat < "$LOG"
+		fail_ "$STRACE $args output not sorted properly"
+	}
+}
+
+c='[[:space:]]\+\([^[:space:]]\+\)'
+test_c calls '-n -r' '/^[[:space:]]\+[0-9]/ s/^'"$c$c$c$c"'[[:space:]].*/\4/p'
+test_c name '' '/^[[:space:]]\+[0-9]/ s/^'"$c$c$c$c"'\([[:space:]]\+[0-9]\+\)\?'"$c"'$/\6/p'
+
+rm -f "$OUT"
diff --git a/strace/tests/strace-T.expected b/strace/tests/strace-T.expected
new file mode 100644
index 0000000..809b7ea
--- /dev/null
+++ b/strace/tests/strace-T.expected
@@ -0,0 +1 @@
+nanosleep\(\{1, 0\}, NULL\) = 0 <(1\.[01]|0\.9)[[:digit:]]{5}>
diff --git a/strace/tests/strace-T.test b/strace/tests/strace-T.test
new file mode 100755
index 0000000..7ab84a7
--- /dev/null
+++ b/strace/tests/strace-T.test
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+# Check -T option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./sleep 0
+run_strace -a24 -T -enanosleep ./sleep 1
+match_grep
diff --git a/strace/tests/strace-V.test b/strace/tests/strace-V.test
new file mode 100755
index 0000000..91093ac
--- /dev/null
+++ b/strace/tests/strace-V.test
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+# Check -V option.
+
+. "${srcdir=.}/init.sh"
+
+run_strace -V > "$LOG"
+
+getval()
+{
+	sed -n 's/#define[[:space:]]*'"$1"'[[:space:]]*"\([^"]*\)".*/\1/p' ../config.h
+}
+
+printf "%s -- version %s\n" "$(getval PACKAGE_NAME)" "$(getval VERSION)" > "$EXP"
+
+match_diff "$EXP" "$LOG"
+rm -f "$EXP"
diff --git a/strace/tests/strace-ff.expected b/strace/tests/strace-ff.expected
new file mode 100644
index 0000000..627a1b4
--- /dev/null
+++ b/strace/tests/strace-ff.expected
@@ -0,0 +1,2 @@
+exit_group(0) = ?
++++ exited with 0 +++
diff --git a/strace/tests/strace-ff.test b/strace/tests/strace-ff.test
new file mode 100755
index 0000000..2ce06f1
--- /dev/null
+++ b/strace/tests/strace-ff.test
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+# Check -ff option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed \
+	kill -0 $$
+
+./set_ptracer_any ./sleep 1 > "$OUT" &
+tracee_pid=$!
+
+while ! [ -s "$OUT" ]; do
+	kill -0 $tracee_pid 2> /dev/null ||
+		fail_ 'set_ptracer_any sleep failed'
+done
+
+rm -f "$LOG".*
+run_strace -a14 -eexit_group -ff -p $tracee_pid
+
+# check that output matches
+match_diff "$LOG.$tracee_pid"
+
+# check that no other output files have been created
+set -- "$LOG".*
+[ "$LOG.$tracee_pid" = "$*" ] ||
+	fail_ "too many output files: $*"
+
+rm -f "$OUT" "$LOG.$tracee_pid"
diff --git a/strace/tests/strace-k.test b/strace/tests/strace-k.test
new file mode 100755
index 0000000..5919bac
--- /dev/null
+++ b/strace/tests/strace-k.test
@@ -0,0 +1,53 @@
+#!/bin/sh
+#
+# Ensure that strace -k works.
+#
+# Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+# Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+. "${srcdir=.}/init.sh"
+
+# strace -k is implemented using /proc/$pid/maps
+[ -f /proc/self/maps ] ||
+	framework_skip_ '/proc/self/maps is not available'
+
+check_prog sed
+check_prog tr
+
+run_prog ./stack-fcall
+run_strace -e getpid -k $args
+
+expected='getpid f3 f2 f1 f0 main '
+result=$(sed -n '1,/(main+0x[a-f0-9]\+) .*/ s/^.*(\([^+]\+\)+0x[a-f0-9]\+) .*/\1/p' "$LOG" |
+	tr '\n' ' ')
+
+test "$result" = "$expected" || {
+	echo "expected: \"$expected\""
+	echo "result: \"$result\""
+	dump_log_and_fail_with "$STRACE $args output mismatch"
+}
+
+exit 0
diff --git a/strace/tests/strace-r.expected b/strace/tests/strace-r.expected
new file mode 100644
index 0000000..8009c35
--- /dev/null
+++ b/strace/tests/strace-r.expected
@@ -0,0 +1,2 @@
+[ ]{5}0\.0{6} execve\("\./sleep", \["\./sleep", "1"\], \[/\* [[:digit:]]+ vars \*/\]\) = 0
+[ ]{5}(1\.[01]|0\.9)[[:digit:]]{5} \+\+\+ exited with 0 \+\+\+
diff --git a/strace/tests/strace-r.test b/strace/tests/strace-r.test
new file mode 100755
index 0000000..4ba01f1
--- /dev/null
+++ b/strace/tests/strace-r.test
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+# Check -r option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./sleep 0
+run_strace -r -eexecve ./sleep 1
+match_grep
diff --git a/strace/tests/strace-t.test b/strace/tests/strace-t.test
new file mode 100755
index 0000000..1d213e6
--- /dev/null
+++ b/strace/tests/strace-t.test
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+# Check -t option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed date +%T > /dev/null
+run_prog ./sleep 0
+
+t0="$(date +%T)"
+run_strace -t -eexecve $args
+t1="$(date +%T)"
+
+EXPECTED="$LOG.expected"
+cat > "$EXPECTED" << __EOF__
+($t0|$t1) execve\\("\\./sleep", \\["\\./sleep", "0"\\], \\[/\\* [[:digit:]]+ vars \\*/\\]\\) = 0
+__EOF__
+
+match_grep "$LOG" "$EXPECTED"
+rm -f "$EXPECTED"
diff --git a/strace/tests/strace-tt.test b/strace/tests/strace-tt.test
new file mode 100755
index 0000000..237646d
--- /dev/null
+++ b/strace/tests/strace-tt.test
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+# Check -tt option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed date +%T > /dev/null
+run_prog ./sleep 0
+
+t0="$(date +%T)"
+run_strace -tt -eexecve $args
+t1="$(date +%T)"
+
+EXPECTED="$LOG.expected"
+cat > "$EXPECTED" << __EOF__
+($t0|$t1)\\.[[:digit:]]{6} execve\\("\\./sleep", \\["\\./sleep", "0"\\], \\[/\\* [[:digit:]]+ vars \\*/\\]\\) = 0
+__EOF__
+
+match_grep "$LOG" "$EXPECTED"
+rm -f "$EXPECTED"
diff --git a/strace/tests/strace-ttt.test b/strace/tests/strace-ttt.test
new file mode 100755
index 0000000..8b0032a
--- /dev/null
+++ b/strace/tests/strace-ttt.test
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+# Check -ttt option.
+
+. "${srcdir=.}/init.sh"
+
+run_prog_skip_if_failed date +%s > /dev/null
+run_prog ./sleep 0
+
+t0="$(date +%s)"
+run_strace -ttt -eexecve $args
+t1="$(date +%s)"
+
+EXPECTED="$LOG.expected"
+cat > "$EXPECTED" << __EOF__
+($t0|$t1)\\.[[:digit:]]{6} execve\\("\\./sleep", \\["\\./sleep", "0"\\], \\[/\\* [[:digit:]]+ vars \\*/\\]\\) = 0
+__EOF__
+
+match_grep "$LOG" "$EXPECTED"
+rm -f "$EXPECTED"
diff --git a/strace/tests/struct_flock.c b/strace/tests/struct_flock.c
new file mode 100644
index 0000000..aae71a0
--- /dev/null
+++ b/strace/tests/struct_flock.c
@@ -0,0 +1,107 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <stdio.h>
+#include <stdint.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include "flock.h"
+
+#define FILE_LEN 4096
+#define EINVAL_STR "-1 EINVAL (Invalid argument)"
+
+#define TEST_FLOCK_EINVAL(cmd) test_flock_einval(cmd, #cmd)
+
+#ifdef HAVE_TYPEOF
+# define TYPEOF_FLOCK_OFF_T typeof(((struct_kernel_flock *) NULL)->l_len)
+#else
+# define TYPEOF_FLOCK_OFF_T off_t
+#endif
+
+static long
+invoke_test_syscall(const unsigned int cmd, void *const p)
+{
+	const unsigned long op = (unsigned long) 0xffffffff00000000 | cmd;
+
+	return syscall(TEST_SYSCALL_NR, 0, op, (unsigned long) p);
+}
+
+static void
+test_flock_einval(const int cmd, const char *name)
+{
+	struct_kernel_flock fl = {
+		.l_type = F_RDLCK,
+		.l_start = (TYPEOF_FLOCK_OFF_T) 0xdefaced1facefeed,
+		.l_len = (TYPEOF_FLOCK_OFF_T) 0xdefaced2cafef00d
+	};
+	invoke_test_syscall(cmd, &fl);
+	printf("%s(0, %s, {l_type=F_RDLCK, l_whence=SEEK_SET"
+	       ", l_start=%jd, l_len=%jd}) = %s\n", TEST_SYSCALL_STR, name,
+	       (intmax_t) fl.l_start, (intmax_t) fl.l_len, EINVAL_STR);
+}
+
+static void
+test_flock(void)
+{
+	TEST_FLOCK_EINVAL(F_SETLK);
+	TEST_FLOCK_EINVAL(F_SETLKW);
+
+	struct_kernel_flock fl = {
+		.l_type = F_RDLCK,
+		.l_len = FILE_LEN
+	};
+	long rc = invoke_test_syscall(F_SETLK, &fl);
+	printf("%s(0, F_SETLK, {l_type=F_RDLCK, l_whence=SEEK_SET"
+	       ", l_start=0, l_len=%d}) = %s\n",
+	       TEST_SYSCALL_STR, FILE_LEN, rc ? EINVAL_STR : "0");
+	if (rc)
+		return;
+
+	invoke_test_syscall(F_GETLK, &fl);
+	printf("%s(0, F_GETLK, {l_type=F_UNLCK, l_whence=SEEK_SET"
+	       ", l_start=0, l_len=%d, l_pid=0}) = 0\n",
+	       TEST_SYSCALL_STR, FILE_LEN);
+
+	invoke_test_syscall(F_SETLK, &fl);
+	printf("%s(0, F_SETLK, {l_type=F_UNLCK, l_whence=SEEK_SET"
+	       ", l_start=0, l_len=%d}) = 0\n",
+	       TEST_SYSCALL_STR, FILE_LEN);
+}
+
+static void
+create_sample(void)
+{
+	char fname[] = TEST_SYSCALL_STR "_XXXXXX";
+
+	(void) close(0);
+	if (mkstemp(fname))
+		perror_msg_and_fail("mkstemp: %s", fname);
+	if (unlink(fname))
+		perror_msg_and_fail("unlink: %s", fname);
+	if (ftruncate(0, FILE_LEN))
+		perror_msg_and_fail("ftruncate");
+}
diff --git a/strace/tests/sun_path.expected b/strace/tests/sun_path.expected
new file mode 100644
index 0000000..30a11c0
--- /dev/null
+++ b/strace/tests/sun_path.expected
@@ -0,0 +1,3 @@
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +bind\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678"\}, 110\) += 0
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +getsockname\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678"\}, \[110->111\]\) += 0
+[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +connect\(1, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678"\}, 110\) += 0
diff --git a/strace/tests/sun_path.test b/strace/tests/sun_path.test
new file mode 100755
index 0000000..728328a
--- /dev/null
+++ b/strace/tests/sun_path.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check how long sun_path addresses are traced.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./net-accept-connect 123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678
+run_strace_merge -ebind,connect,getsockname $args
+match_grep
+
+exit 0
diff --git a/strace/tests/swap.c b/strace/tests/swap.c
new file mode 100644
index 0000000..065af4d
--- /dev/null
+++ b/strace/tests/swap.c
@@ -0,0 +1,51 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_swapon && defined __NR_swapoff
+
+# include <stdio.h>
+# include <sys/swap.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "swap.sample";
+	long rc;
+
+	rc = syscall(__NR_swapon, sample, 0);
+	printf("swapon(\"%s\", %s) = %ld %s (%m)\n",
+	       sample, "0", rc, errno2name());
+
+	rc = syscall(__NR_swapon, sample, 42);
+	printf("swapon(\"%s\", %s) = %ld %s (%m)\n",
+	       sample, "42", rc, errno2name());
+
+	rc = syscall(__NR_swapon, sample, SWAP_FLAG_PREFER);
+	printf("swapon(\"%s\", %s) = %ld %s (%m)\n",
+	       sample, "SWAP_FLAG_PREFER", rc, errno2name());
+
+	rc = syscall(__NR_swapon, sample, SWAP_FLAG_PREFER | 42);
+	printf("swapon(\"%s\", %s) = %ld %s (%m)\n",
+	       sample, "SWAP_FLAG_PREFER|42", rc, errno2name());
+
+	rc = syscall(__NR_swapon, sample, -1L);
+	printf("swapon(\"%s\", %s) = %ld %s (%m)\n",
+	       sample,
+	       "SWAP_FLAG_PREFER|SWAP_FLAG_DISCARD|SWAP_FLAG_DISCARD_ONCE"
+	       "|SWAP_FLAG_DISCARD_PAGES|0xfff80000|32767",
+	       rc, errno2name());
+
+	rc = syscall(__NR_swapoff, sample);
+	printf("swapoff(\"%s\") = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_swapon && __NR_swapoff")
+
+#endif
diff --git a/strace/tests/swap.test b/strace/tests/swap.test
new file mode 100755
index 0000000..a30e1fd
--- /dev/null
+++ b/strace/tests/swap.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check swapon and swapoff syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a23 -e trace=swapon,swapoff
diff --git a/strace/tests/symlink.c b/strace/tests/symlink.c
new file mode 100644
index 0000000..44c5655
--- /dev/null
+++ b/strace/tests/symlink.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_symlink
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample_1[] = "symlink_new";
+	static const char sample_2[] = "symlink";
+
+	long rc = syscall(__NR_symlink, sample_1, sample_2);
+	printf("symlink(\"%s\", \"%s\") = %ld %s (%m)\n",
+	       sample_1, sample_2, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_symlink")
+
+#endif
diff --git a/strace/tests/symlink.test b/strace/tests/symlink.test
new file mode 100755
index 0000000..79b93ba
--- /dev/null
+++ b/strace/tests/symlink.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check symlink syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a34
diff --git a/strace/tests/symlinkat.c b/strace/tests/symlinkat.c
new file mode 100644
index 0000000..3dfdd80
--- /dev/null
+++ b/strace/tests/symlinkat.c
@@ -0,0 +1,28 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_symlinkat
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd = (long int) 0xdeadbeefffffffff;
+	static const char oldpath[] = "symlink_old";
+	static const char newpath[] = "symlink_new";
+
+	long rc = syscall(__NR_symlinkat, oldpath, fd, newpath);
+	printf("symlinkat(\"%s\", %d, \"%s\") = %ld %s (%m)\n",
+	       oldpath, (int) fd, newpath, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_symlinkat")
+
+#endif
diff --git a/strace/tests/symlinkat.test b/strace/tests/symlinkat.test
new file mode 100755
index 0000000..d8501ff
--- /dev/null
+++ b/strace/tests/symlinkat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check symlinkat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/sync.c b/strace/tests/sync.c
new file mode 100644
index 0000000..132a6f2
--- /dev/null
+++ b/strace/tests/sync.c
@@ -0,0 +1,22 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_sync
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	printf("sync() = %ld\n", syscall(__NR_sync));
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_sync")
+
+#endif
diff --git a/strace/tests/sync.test b/strace/tests/sync.test
new file mode 100755
index 0000000..f6bf6c8
--- /dev/null
+++ b/strace/tests/sync.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sync syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a7
diff --git a/strace/tests/sync_file_range.c b/strace/tests/sync_file_range.c
new file mode 100644
index 0000000..9426e3c
--- /dev/null
+++ b/strace/tests/sync_file_range.c
@@ -0,0 +1,63 @@
+/*
+ * Check decoding of sync_file_range syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <sys/syscall.h>
+
+#if defined HAVE_SYNC_FILE_RANGE && defined __NR_sync_file_range
+
+# include <stdio.h>
+
+int
+main(void)
+{
+	const int fd = -1;
+	const off64_t offset = 0xdeadbeefbadc0ded;
+	const off64_t nbytes = 0xfacefeedcafef00d;
+	const unsigned int flags = -1;
+
+	int rc = sync_file_range(fd, offset, nbytes, flags);
+	printf("%s(%d, %lld, %lld, SYNC_FILE_RANGE_WAIT_BEFORE"
+	       "|SYNC_FILE_RANGE_WRITE|SYNC_FILE_RANGE_WAIT_AFTER"
+	       "|0xfffffff8) = %d %s (%m)\n",
+	       "sync_file_range", fd,
+	       (long long) offset,
+	       (long long) nbytes,
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_SYNC_FILE_RANGE && __NR_sync_file_range")
+
+#endif
diff --git a/strace/tests/sync_file_range.test b/strace/tests/sync_file_range.test
new file mode 100755
index 0000000..6aa86d6
--- /dev/null
+++ b/strace/tests/sync_file_range.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sync_file_range syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/sync_file_range2.c b/strace/tests/sync_file_range2.c
new file mode 100644
index 0000000..d19cf25
--- /dev/null
+++ b/strace/tests/sync_file_range2.c
@@ -0,0 +1,63 @@
+/*
+ * Check decoding of sync_file_range2 syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <sys/syscall.h>
+
+#if defined HAVE_SYNC_FILE_RANGE && defined  __NR_sync_file_range2
+
+# include <stdio.h>
+
+int
+main(void)
+{
+	const int fd = -1;
+	const off64_t offset = 0xdeadbeefbadc0ded;
+	const off64_t nbytes = 0xfacefeedcafef00d;
+	const unsigned int flags = -1;
+
+	int rc = sync_file_range(fd, offset, nbytes, flags);
+	printf("%s(%d, SYNC_FILE_RANGE_WAIT_BEFORE"
+	       "|SYNC_FILE_RANGE_WRITE|SYNC_FILE_RANGE_WAIT_AFTER"
+	       "|0xfffffff8, %lld, %lld) = %d %s (%m)\n",
+	       "sync_file_range2", fd,
+	       (long long) offset,
+	       (long long) nbytes,
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_SYNC_FILE_RANGE && __NR_sync_file_range2")
+
+#endif
diff --git a/strace/tests/sync_file_range2.test b/strace/tests/sync_file_range2.test
new file mode 100755
index 0000000..0d9945e
--- /dev/null
+++ b/strace/tests/sync_file_range2.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check sync_file_range2 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/sysinfo.c b/strace/tests/sysinfo.c
new file mode 100644
index 0000000..377bdc9
--- /dev/null
+++ b/strace/tests/sysinfo.c
@@ -0,0 +1,76 @@
+/*
+ * This file is part of sysinfo strace test.
+ *
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <sys/sysinfo.h>
+
+int
+main(void)
+{
+	sysinfo(NULL);
+	printf("sysinfo(NULL) = -1 EFAULT (%m)\n");
+
+	struct sysinfo * const si = tail_alloc(sizeof(*si));
+
+	if (sysinfo(si))
+		perror_msg_and_skip("sysinfo");
+	printf("sysinfo({uptime=%llu"
+		", loads=[%llu, %llu, %llu]"
+		", totalram=%llu"
+		", freeram=%llu"
+		", sharedram=%llu"
+		", bufferram=%llu"
+		", totalswap=%llu"
+		", freeswap=%llu"
+		", procs=%u"
+		", totalhigh=%llu"
+		", freehigh=%llu"
+		", mem_unit=%u"
+		"}) = 0\n"
+		, (unsigned long long) si->uptime
+		, (unsigned long long) si->loads[0]
+		, (unsigned long long) si->loads[1]
+		, (unsigned long long) si->loads[2]
+		, (unsigned long long) si->totalram
+		, (unsigned long long) si->freeram
+		, (unsigned long long) si->sharedram
+		, (unsigned long long) si->bufferram
+		, (unsigned long long) si->totalswap
+		, (unsigned long long) si->freeswap
+		, (unsigned) si->procs
+		, (unsigned long long) si->totalhigh
+		, (unsigned long long) si->freehigh
+		, si->mem_unit
+		);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/sysinfo.test b/strace/tests/sysinfo.test
new file mode 100755
index 0000000..806d8b6
--- /dev/null
+++ b/strace/tests/sysinfo.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of sysinfo syscall
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a14
diff --git a/strace/tests/syslog.c b/strace/tests/syslog.c
new file mode 100644
index 0000000..8c68298
--- /dev/null
+++ b/strace/tests/syslog.c
@@ -0,0 +1,27 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_syslog
+
+# include <stdio.h>
+# include <unistd.h>
+
+# define SYSLOG_ACTION_READ 2
+
+int
+main(void)
+{
+	const long addr = (long) 0xfacefeeddeadbeef;
+	int rc = syscall(__NR_syslog, SYSLOG_ACTION_READ, addr, -1);
+	printf("syslog(SYSLOG_ACTION_READ, %#lx, -1) = %d %s (%m)\n",
+	       addr, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_syslog")
+
+#endif
diff --git a/strace/tests/syslog.test b/strace/tests/syslog.test
new file mode 100755
index 0000000..1c2158e
--- /dev/null
+++ b/strace/tests/syslog.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check syslog syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a36
diff --git a/strace/tests/tail_alloc.c b/strace/tests/tail_alloc.c
new file mode 100644
index 0000000..08081d4
--- /dev/null
+++ b/strace/tests/tail_alloc.c
@@ -0,0 +1,63 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <string.h>
+#include <sys/mman.h>
+
+void *
+tail_alloc(const size_t size)
+{
+	const size_t page_size = get_page_size();
+	const size_t len = (size + page_size - 1) & -page_size;
+	const size_t alloc_size = len + 6 * page_size;
+
+	void *p = mmap(NULL, alloc_size, PROT_READ | PROT_WRITE,
+		       MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
+	if (MAP_FAILED == p)
+		perror_msg_and_fail("mmap(%zu)", alloc_size);
+
+	void *start_work = p + 3 * page_size;
+	void *tail_guard = start_work + len;
+
+	if (munmap(p, page_size) ||
+	    munmap(p + 2 * page_size, page_size) ||
+	    munmap(tail_guard, page_size) ||
+	    munmap(tail_guard + 2 * page_size, page_size))
+		perror_msg_and_fail("munmap");
+
+	memset(start_work, 0xff, len);
+	return tail_guard - size;
+}
+
+void *
+tail_memdup(const void *p, const size_t size)
+{
+	void *dest = tail_alloc(size);
+	memcpy(dest, p, size);
+	return dest;
+}
diff --git a/strace/tests/tee.c b/strace/tests/tee.c
new file mode 100644
index 0000000..f36f92a
--- /dev/null
+++ b/strace/tests/tee.c
@@ -0,0 +1,60 @@
+/*
+ * This file is part of tee strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_tee
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const long int fd_in = (long int) 0xdeadbeefffffffff;
+	const long int fd_out = (long int) 0xdeadbeeffffffffe;
+	const size_t len = (size_t) 0xdeadbef3facefed3ULL;
+	const unsigned int flags = 15;
+
+	long rc = syscall(__NR_tee, fd_in, fd_out, len, flags);
+	printf("tee(%d, %d, %zu, %s) = %ld %s (%m)\n",
+	       (int) fd_in, (int) fd_out, len,
+	       "SPLICE_F_MOVE|SPLICE_F_NONBLOCK|SPLICE_F_MORE|SPLICE_F_GIFT",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_tee")
+
+#endif
diff --git a/strace/tests/tee.test b/strace/tests/tee.test
new file mode 100755
index 0000000..76b6000
--- /dev/null
+++ b/strace/tests/tee.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check tee syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/tests.h b/strace/tests/tests.h
new file mode 100644
index 0000000..e0bf228
--- /dev/null
+++ b/strace/tests/tests.h
@@ -0,0 +1,154 @@
+/*
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifndef TESTS_H_
+# define TESTS_H_
+
+# ifdef HAVE_CONFIG_H
+#  include "config.h"
+# endif
+
+# include <sys/types.h>
+# include "gcc_compat.h"
+
+/* Cached sysconf(_SC_PAGESIZE). */
+size_t get_page_size(void);
+
+/* Print message and strerror(errno) to stderr, then exit(1). */
+void perror_msg_and_fail(const char *, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+/* Print message to stderr, then exit(1). */
+void error_msg_and_fail(const char *, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+/* Print message to stderr, then exit(77). */
+void error_msg_and_skip(const char *, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+/* Print message and strerror(errno) to stderr, then exit(77). */
+void perror_msg_and_skip(const char *, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
+
+/*
+ * Allocate memory that ends on the page boundary.
+ * Pages allocated by this call are preceeded by an unmapped page
+ * and followed also by an unmapped page.
+ */
+void *tail_alloc(const size_t)
+	ATTRIBUTE_MALLOC ATTRIBUTE_ALLOC_SIZE((1));
+/* Allocate memory using tail_alloc, then memcpy. */
+void *tail_memdup(const void *, const size_t)
+	ATTRIBUTE_MALLOC ATTRIBUTE_ALLOC_SIZE((2));
+
+/* Close stdin, move stdout to a non-standard descriptor, and print. */
+void tprintf(const char *, ...)
+	ATTRIBUTE_FORMAT((printf, 1, 2));
+
+/* Make a hexdump copy of C string */
+const char *hexdump_strdup(const char *);
+
+/* Make a hexdump copy of memory */
+const char *hexdump_memdup(const char *, size_t);
+
+/* Make a hexquoted copy of a string */
+const char *hexquote_strndup(const char *, size_t);
+
+/* Return inode number of socket descriptor. */
+unsigned long inode_of_sockfd(int);
+
+/* Print string in a quoted form. */
+void print_quoted_string(const char *);
+
+/* Print memory in a quoted form. */
+void print_quoted_memory(const char *, size_t);
+
+/* Read an int from the file. */
+int read_int_from_file(const char *, int *);
+
+/* Check whether given uid matches kernel overflowuid. */
+void check_overflowuid(const int);
+
+/* Check whether given gid matches kernel overflowgid. */
+void check_overflowgid(const int);
+
+/* Translate errno to its name. */
+const char *errno2name(void);
+
+/* Translate signal number to its name. */
+const char *signal2name(int);
+
+struct xlat;
+
+/* Print flags in symbolic form according to xlat table. */
+int printflags(const struct xlat *, const unsigned long long, const char *);
+
+/* Print constant in symbolic form according to xlat table. */
+int printxval(const struct xlat *, const unsigned long long, const char *);
+
+/* Invoke a socket syscall, either directly or via __NR_socketcall. */
+int socketcall(const int nr, const int call,
+	       long a1, long a2, long a3, long a4, long a5);
+
+/* Wrappers for recvmmsg and sendmmsg syscalls. */
+struct mmsghdr;
+struct timespec;
+int recv_mmsg(int, struct mmsghdr *, unsigned int, unsigned int, struct timespec *);
+int send_mmsg(int, struct mmsghdr *, unsigned int, unsigned int);
+
+# define ARRAY_SIZE(arg) ((unsigned int) (sizeof(arg) / sizeof((arg)[0])))
+# define LENGTH_OF(arg) ((unsigned int) sizeof(arg) - 1)
+
+/*
+ * Widen without sign-extension a signed integer type to unsigned long long.
+ */
+#define widen_to_ull(v) \
+	(sizeof(v) == sizeof(int) ? (unsigned long long) (unsigned int) (v) : \
+	 sizeof(v) == sizeof(long) ? (unsigned long long) (unsigned long) (v) : \
+	 (unsigned long long) (v))
+
+# define SKIP_MAIN_UNDEFINED(arg) \
+	int main(void) { error_msg_and_skip("undefined: %s", arg); }
+
+/*
+ * The kernel used to define 64-bit types on 64-bit systems on a per-arch
+ * basis.  Some architectures would use unsigned long and others would use
+ * unsigned long long.  These types were exported as part of the
+ * kernel-userspace ABI and now must be maintained forever.  This matches
+ * what the kernel exports for each architecture so we don't need to cast
+ * every printing of __u64 or __s64 to stdint types.
+ */
+# if SIZEOF_LONG == 4
+#  define PRI__64 "ll"
+# elif defined ALPHA || defined IA64 || defined MIPS || defined POWERPC
+#  define PRI__64 "l"
+# else
+#  define PRI__64 "ll"
+# endif
+
+# define PRI__d64 PRI__64"d"
+# define PRI__u64 PRI__64"u"
+# define PRI__x64 PRI__64"x"
+
+#endif
diff --git a/strace/tests/time.c b/strace/tests/time.c
new file mode 100644
index 0000000..041b011
--- /dev/null
+++ b/strace/tests/time.c
@@ -0,0 +1,61 @@
+/*
+ * This file is part of time strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_time
+
+# include <time.h>
+# include <stdio.h>
+# include <stdint.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	time_t *p = tail_alloc(sizeof(time_t));
+
+	time_t t = syscall(__NR_time, NULL);
+	if ((time_t) -1 == t)
+		perror_msg_and_skip("time");
+	printf("time(NULL) = %jd\n", (intmax_t) t);
+
+	t = syscall(__NR_time, p);
+	printf("time([%jd]) = %jd\n", (intmax_t) *p, (intmax_t) t);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_time")
+
+#endif
diff --git a/strace/tests/time.test b/strace/tests/time.test
new file mode 100755
index 0000000..6ab193a
--- /dev/null
+++ b/strace/tests/time.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check time syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a10
diff --git a/strace/tests/timer_create.c b/strace/tests/timer_create.c
new file mode 100644
index 0000000..ff924d3
--- /dev/null
+++ b/strace/tests/timer_create.c
@@ -0,0 +1,122 @@
+/*
+ * This file is part of timer_create strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_timer_create
+
+# include <stdio.h>
+# include <signal.h>
+# include <time.h>
+# include <unistd.h>
+# include "sigevent.h"
+
+int
+main(void)
+{
+	syscall(__NR_timer_create, CLOCK_REALTIME, NULL, NULL);
+	printf("timer_create(CLOCK_REALTIME, NULL, NULL) = -1 %s (%m)\n",
+	       errno2name());
+
+	int tid[4] = {};
+	struct_sigevent sev = {
+		.sigev_notify = 0xdefaced,
+		.sigev_signo = 0xfacefeed,
+		.sigev_value.sival_ptr = (unsigned long) 0xdeadbeefbadc0ded
+	};
+
+	syscall(__NR_timer_create, CLOCK_REALTIME, &sev, NULL);
+	printf("timer_create(CLOCK_REALTIME, {sigev_value={int=%d, ptr=%#lx}"
+	       ", sigev_signo=%u, sigev_notify=%#x /* SIGEV_??? */}"
+	       ", NULL) = -1 %s (%m)\n",
+	       sev.sigev_value.sival_int,
+	       sev.sigev_value.sival_ptr,
+	       sev.sigev_signo, sev.sigev_notify,
+	       errno2name());
+
+	sev.sigev_notify = SIGEV_NONE;
+	if (syscall(__NR_timer_create, CLOCK_REALTIME, &sev, &tid[0]))
+		perror_msg_and_skip("timer_create CLOCK_REALTIME");
+	printf("timer_create(CLOCK_REALTIME, {sigev_value={int=%d, ptr=%#lx}"
+	       ", sigev_signo=%u, sigev_notify=SIGEV_NONE}, [%d]) = 0\n",
+	       sev.sigev_value.sival_int,
+	       sev.sigev_value.sival_ptr,
+	       sev.sigev_signo, tid[0]);
+
+	sev.sigev_notify = SIGEV_SIGNAL;
+	sev.sigev_signo = SIGALRM;
+	if (syscall(__NR_timer_create, CLOCK_MONOTONIC, &sev, &tid[1]))
+		perror_msg_and_skip("timer_create CLOCK_MONOTONIC");
+	printf("timer_create(CLOCK_MONOTONIC, {sigev_value={int=%d, ptr=%#lx}"
+	       ", sigev_signo=SIGALRM, sigev_notify=SIGEV_SIGNAL}"
+	       ", [%d]) = 0\n",
+	       sev.sigev_value.sival_int,
+	       sev.sigev_value.sival_ptr, tid[1]);
+
+	sev.sigev_notify = SIGEV_THREAD;
+	sev.sigev_un.sigev_thread.function = (unsigned long) 0xdeadbeefbadc0ded;
+	sev.sigev_un.sigev_thread.attribute = (unsigned long) 0xcafef00dfacefeed;
+	if (syscall(__NR_timer_create, CLOCK_REALTIME, &sev, &tid[2]))
+		perror_msg_and_skip("timer_create CLOCK_REALTIME");
+	printf("timer_create(CLOCK_REALTIME, {sigev_value={int=%d, ptr=%#lx}"
+	       ", sigev_signo=SIGALRM, sigev_notify=SIGEV_THREAD"
+	       ", sigev_notify_function=%#lx, sigev_notify_attributes=%#lx}"
+	       ", [%d]) = 0\n",
+	       sev.sigev_value.sival_int,
+	       sev.sigev_value.sival_ptr,
+	       sev.sigev_un.sigev_thread.function,
+	       sev.sigev_un.sigev_thread.attribute,
+	       tid[2]);
+
+#ifndef SIGEV_THREAD_ID
+# define SIGEV_THREAD_ID 4
+#endif
+	sev.sigev_notify = SIGEV_THREAD_ID;
+	sev.sigev_un.tid = getpid();
+	if (syscall(__NR_timer_create, CLOCK_MONOTONIC, &sev, &tid[3]))
+		perror_msg_and_skip("timer_create CLOCK_MONOTONIC");
+	printf("timer_create(CLOCK_MONOTONIC, {sigev_value={int=%d, ptr=%#lx}"
+	       ", sigev_signo=SIGALRM, sigev_notify=SIGEV_THREAD_ID"
+	       ", sigev_notify_thread_id=%d}"
+	       ", [%d]) = 0\n",
+	       sev.sigev_value.sival_int,
+	       sev.sigev_value.sival_ptr,
+	       sev.sigev_un.tid,
+	       tid[3]);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_timer_create")
+
+#endif
diff --git a/strace/tests/timer_create.test b/strace/tests/timer_create.test
new file mode 100755
index 0000000..870a179
--- /dev/null
+++ b/strace/tests/timer_create.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check timer_create syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/timer_xettime.c b/strace/tests/timer_xettime.c
new file mode 100644
index 0000000..7c691c6
--- /dev/null
+++ b/strace/tests/timer_xettime.c
@@ -0,0 +1,106 @@
+/*
+ * This file is part of timer_xettime strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_timer_create \
+ && defined __NR_timer_gettime \
+ && defined __NR_timer_settime
+
+# include <stdio.h>
+# include <stdint.h>
+# include <signal.h>
+# include <time.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	syscall(__NR_timer_settime, 0xdefaced, TIMER_ABSTIME, NULL, NULL);
+	printf("timer_settime(%d, TIMER_ABSTIME, NULL, NULL)"
+	       " = -1 EINVAL (%m)\n", 0xdefaced);
+
+	int tid;
+	struct sigevent sev = { .sigev_notify = SIGEV_NONE };
+
+	if (syscall(__NR_timer_create, CLOCK_MONOTONIC, &sev, &tid))
+		perror_msg_and_skip("timer_create");
+	printf("timer_create(CLOCK_MONOTONIC, {sigev_signo=0"
+	       ", sigev_notify=SIGEV_NONE}, [%d]) = 0\n", tid);
+
+	struct {
+		struct itimerspec its;
+		uint32_t pad[4];
+	} old = {
+		.pad = { 0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded }
+	}, new = {
+		.its = {
+			.it_interval = { 0xdeface1, 0xdeface2 },
+			.it_value = { 0xdeface3, 0xdeface4 }
+		},
+		.pad = { 0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded }
+	};
+
+	if (syscall(__NR_timer_settime, tid, 0, &new.its, &old.its))
+		perror_msg_and_skip("timer_settime");
+	printf("timer_settime(%d, 0"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ") = 0\n",
+	       tid,
+	       (intmax_t) new.its.it_interval.tv_sec,
+	       (intmax_t) new.its.it_interval.tv_nsec,
+	       (intmax_t) new.its.it_value.tv_sec,
+	       (intmax_t) new.its.it_value.tv_nsec,
+	       (intmax_t) old.its.it_interval.tv_sec,
+	       (intmax_t) old.its.it_interval.tv_nsec,
+	       (intmax_t) old.its.it_value.tv_sec,
+	       (intmax_t) old.its.it_value.tv_nsec);
+
+	if (syscall(__NR_timer_gettime, tid, &old.its))
+		perror_msg_and_skip("timer_gettime");
+	printf("timer_gettime(%d"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ") = 0\n",
+	       tid,
+	       (intmax_t) old.its.it_interval.tv_sec,
+	       (intmax_t) old.its.it_interval.tv_nsec,
+	       (intmax_t) old.its.it_value.tv_sec,
+	       (intmax_t) old.its.it_value.tv_nsec);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_timer_create && __NR_timer_gettime && __NR_timer_settime")
+
+#endif
diff --git a/strace/tests/timer_xettime.test b/strace/tests/timer_xettime.test
new file mode 100755
index 0000000..08bcdd6
--- /dev/null
+++ b/strace/tests/timer_xettime.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check timer_create, timer_settime, and timer_gettime syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=timer_create,timer_settime,timer_gettime
diff --git a/strace/tests/timerfd_xettime.c b/strace/tests/timerfd_xettime.c
new file mode 100644
index 0000000..f97c1db
--- /dev/null
+++ b/strace/tests/timerfd_xettime.c
@@ -0,0 +1,97 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <sys/syscall.h>
+
+#if defined __NR_timerfd_create \
+ && defined __NR_timerfd_gettime \
+ && defined __NR_timerfd_settime \
+ && defined O_CLOEXEC
+
+# include <stdio.h>
+# include <stdint.h>
+# include <time.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	(void) close(0);
+	if (syscall(__NR_timerfd_create, CLOCK_MONOTONIC, O_CLOEXEC | O_NONBLOCK))
+		perror_msg_and_skip("timerfd_create");
+	puts("timerfd_create(CLOCK_MONOTONIC, TFD_CLOEXEC|TFD_NONBLOCK) = 0");
+
+	struct {
+		struct itimerspec its;
+		uint32_t pad[4];
+	} old = {
+		.pad = { 0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded }
+	}, new = {
+		.its = {
+			.it_interval = { 0xdeface1, 0xdeface2 },
+			.it_value = { 0xdeface3, 0xdeface4 }
+		},
+		.pad = { 0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded }
+	};
+
+	if (syscall(__NR_timerfd_settime, 0, 0, &new.its, &old.its))
+		perror_msg_and_skip("timerfd_settime");
+	printf("timerfd_settime(0, 0"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ") = 0\n",
+	       (intmax_t) new.its.it_interval.tv_sec,
+	       (intmax_t) new.its.it_interval.tv_nsec,
+	       (intmax_t) new.its.it_value.tv_sec,
+	       (intmax_t) new.its.it_value.tv_nsec,
+	       (intmax_t) old.its.it_interval.tv_sec,
+	       (intmax_t) old.its.it_interval.tv_nsec,
+	       (intmax_t) old.its.it_value.tv_sec,
+	       (intmax_t) old.its.it_value.tv_nsec);
+
+	if (syscall(__NR_timerfd_gettime, 0, &old.its))
+		perror_msg_and_skip("timerfd_gettime");
+	printf("timerfd_gettime(0"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ") = 0\n",
+	       (intmax_t) old.its.it_interval.tv_sec,
+	       (intmax_t) old.its.it_interval.tv_nsec,
+	       (intmax_t) old.its.it_value.tv_sec,
+	       (intmax_t) old.its.it_value.tv_nsec);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_timerfd_create && __NR_timerfd_gettime"
+		    " && __NR_timerfd_settime && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/timerfd_xettime.test b/strace/tests/timerfd_xettime.test
new file mode 100755
index 0000000..75aa21c
--- /dev/null
+++ b/strace/tests/timerfd_xettime.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check timerfd_create, timerfd_settime, and timerfd_gettime syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=timerfd_create,timerfd_settime,timerfd_gettime
diff --git a/strace/tests/times-fail.c b/strace/tests/times-fail.c
new file mode 100644
index 0000000..5f5277c
--- /dev/null
+++ b/strace/tests/times-fail.c
@@ -0,0 +1,15 @@
+#include "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/syscall.h>
+
+int
+main (void)
+{
+	assert(syscall(__NR_times, 0x42) == -1);
+	printf("times(0x42) = -1 EFAULT (%m)\n");
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
diff --git a/strace/tests/times-fail.test b/strace/tests/times-fail.test
new file mode 100755
index 0000000..ee28a06
--- /dev/null
+++ b/strace/tests/times-fail.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of failing times syscall
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a12 -e trace=times
diff --git a/strace/tests/times.c b/strace/tests/times.c
new file mode 100644
index 0000000..6c76dbc
--- /dev/null
+++ b/strace/tests/times.c
@@ -0,0 +1,139 @@
+/*
+ * Copyright (c) 2015 Eugene Syromyatnikov <evgsyr@gmail.com>
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+/**
+ * @file
+ * This test burns some CPU cycles in user space and kernel space in order to
+ * get some non-zero values returned by times(2).
+ */
+
+#include "tests.h"
+#include <sched.h>
+#include <stdio.h>
+#include <time.h>
+#include <unistd.h>
+
+#include <sys/syscall.h>
+#include <sys/times.h>
+#include <sys/wait.h>
+
+enum {
+	NUM_USER_ITERS = 1000000,
+	PARENT_CPUTIME_LIMIT_NSEC = 200000000,
+	CHILD_CPUTIME_LIMIT_NSEC = 300000000
+};
+
+int
+main (void)
+{
+	struct timespec ts;
+	volatile int dummy = 0;
+	int i;
+
+	pid_t pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	const long cputime_limit =
+		pid ? PARENT_CPUTIME_LIMIT_NSEC : CHILD_CPUTIME_LIMIT_NSEC;
+
+	/* Enjoying my user time */
+	while (clock_gettime(CLOCK_PROCESS_CPUTIME_ID, &ts) == 0) {
+		if (ts.tv_sec || ts.tv_nsec >= cputime_limit)
+			break;
+
+		for (i = 0; i < NUM_USER_ITERS; ++i)
+			++dummy;
+	}
+
+	/* Enjoying my system time */
+	while (clock_gettime(CLOCK_PROCESS_CPUTIME_ID, &ts) == 0) {
+		if (ts.tv_sec || ts.tv_nsec >= cputime_limit * 2)
+			break;
+
+		sched_yield();
+	}
+
+	if (pid == 0) {
+		return 0;
+	} else {
+		wait(NULL);
+	}
+
+	struct tms tbuf;
+	unsigned long long llres;
+
+	/*
+	 * On systems where user's and kernel's long types are the same,
+	 * prefer direct times syscall over libc's times function because
+	 * the latter is more prone to return value truncation.
+	 */
+#undef USE_LIBC_SYSCALL
+#if defined __NR_times && \
+   !defined(LINUX_MIPSN32) && \
+   !(defined __x86_64__ && defined __ILP32__)
+# define USE_LIBC_SYSCALL 1
+#endif
+
+#if defined USE_LIBC_SYSCALL
+	long res = syscall(__NR_times, &tbuf);
+
+	if (-1L == res)
+		perror_msg_and_skip("times");
+	else
+		llres = (unsigned long) res;
+#elif defined __NR_times && defined __x86_64__ && defined __ILP32__
+	register long arg asm("rdi") = (long) &tbuf;
+	asm volatile("syscall\n\t"
+		     : "=a"(llres)
+		     : "0"(__NR_times), "r"(arg)
+		     : "memory", "cc", "r11", "cx");
+	if (llres > 0xfffffffffffff000)
+		return 77;
+#else
+	clock_t res = times(&tbuf);
+
+	if ((clock_t) -1 == res)
+		perror_msg_and_skip("times");
+	if (sizeof(res) < sizeof(unsigned long long))
+		llres = (unsigned long) res;
+	else
+		llres = res;
+#endif
+
+	printf("times({tms_utime=%llu, tms_stime=%llu, ",
+		(unsigned long long) tbuf.tms_utime,
+		(unsigned long long) tbuf.tms_stime);
+	printf("tms_cutime=%llu, tms_cstime=%llu}) = %llu\n",
+		(unsigned long long) tbuf.tms_cutime,
+		(unsigned long long) tbuf.tms_cstime,
+		llres);
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
diff --git a/strace/tests/times.test b/strace/tests/times.test
new file mode 100755
index 0000000..b97e0d3
--- /dev/null
+++ b/strace/tests/times.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of times syscall
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -esignal=none
diff --git a/strace/tests/tprintf.c b/strace/tests/tprintf.c
new file mode 100644
index 0000000..a759d8a
--- /dev/null
+++ b/strace/tests/tprintf.c
@@ -0,0 +1,90 @@
+/*
+ * Close stdin, move stdout to a non-standard descriptor, and print.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <assert.h>
+#include <errno.h>
+#include <stdarg.h>
+#include <stdio.h>
+#include <unistd.h>
+
+static ssize_t
+write_retry(int fd, const void *buf, size_t count)
+{
+	ssize_t rc;
+
+	do {
+		errno = 0;
+		rc = write(fd, buf, count);
+	} while (rc == -1 && EINTR == errno);
+
+	if (rc <= 0)
+		perror_msg_and_fail("write");
+
+	return rc;
+}
+
+static void
+write_loop(int fd, const char *buf, size_t count)
+{
+	ssize_t offset = 0;
+
+	while (count > 0) {
+		ssize_t block = write_retry(fd, &buf[offset], count);
+
+		offset += block;
+		count -= (size_t) block;
+	}
+}
+
+void
+tprintf(const char *fmt, ...)
+{
+	static int initialized;
+	if (!initialized) {
+		assert(dup2(1, 3) == 3);
+		assert(close(1) == 0);
+		(void) close(0);
+		initialized = 1;
+	}
+
+	va_list p;
+	va_start(p, fmt);
+
+	static char buf[65536];
+	int len = vsnprintf(buf, sizeof(buf), fmt, p);
+	if (len < 0)
+		perror_msg_and_fail("vsnprintf");
+	assert((unsigned) len < sizeof(buf));
+
+	write_loop(3, buf, len);
+
+	va_end(p);
+}
diff --git a/strace/tests/truncate.c b/strace/tests/truncate.c
new file mode 100644
index 0000000..c3ad2ba
--- /dev/null
+++ b/strace/tests/truncate.c
@@ -0,0 +1,61 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_truncate
+
+# include <stdio.h>
+# include <unistd.h>
+# include "kernel_types.h"
+
+int
+main(void)
+{
+	static const char fname[] = "truncate\nfilename";
+	static const char qname[] = "truncate\\nfilename";
+	const kernel_ulong_t len = (kernel_ulong_t) 0xdefaced0badc0deULL;
+	long rc;
+
+	if (sizeof(len) > sizeof(long))
+		rc = truncate(fname, len);
+	else
+		rc = syscall(__NR_truncate, fname, len);
+
+	printf("truncate(\"%s\", %llu) = %ld %s (%m)\n",
+	       qname, (unsigned long long) len, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_truncate")
+
+#endif
diff --git a/strace/tests/truncate.test b/strace/tests/truncate.test
new file mode 100755
index 0000000..6bf1e70
--- /dev/null
+++ b/strace/tests/truncate.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check truncate syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/truncate64.c b/strace/tests/truncate64.c
new file mode 100644
index 0000000..c973c45
--- /dev/null
+++ b/strace/tests/truncate64.c
@@ -0,0 +1,55 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_truncate64
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char fname[] = "truncate64\nfilename";
+	static const char qname[] = "truncate64\\nfilename";
+	const off_t len = 0xdefaceddeadbeef;
+
+	int rc = truncate(fname, len);
+	printf("truncate64(\"%s\", %llu) = %d %s (%m)\n",
+	       qname, (unsigned long long) len, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_truncate64")
+
+#endif
diff --git a/strace/tests/truncate64.test b/strace/tests/truncate64.test
new file mode 100755
index 0000000..c466806
--- /dev/null
+++ b/strace/tests/truncate64.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check truncate64 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff
diff --git a/strace/tests/ugetrlimit.c b/strace/tests/ugetrlimit.c
new file mode 100644
index 0000000..dc24bb8
--- /dev/null
+++ b/strace/tests/ugetrlimit.c
@@ -0,0 +1,14 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_ugetrlimit
+
+# define NR_GETRLIMIT	__NR_ugetrlimit
+# define STR_GETRLIMIT	"ugetrlimit"
+# include "xgetrlimit.c"
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_ugetrlimit")
+
+#endif
diff --git a/strace/tests/ugetrlimit.test b/strace/tests/ugetrlimit.test
new file mode 100755
index 0000000..f4648ff
--- /dev/null
+++ b/strace/tests/ugetrlimit.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of ugetrlimit syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28
diff --git a/strace/tests/uio.c b/strace/tests/uio.c
new file mode 100644
index 0000000..6291f97
--- /dev/null
+++ b/strace/tests/uio.c
@@ -0,0 +1,62 @@
+/*
+ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#if defined(HAVE_PREADV) && defined(HAVE_PWRITEV)
+
+# include <fcntl.h>
+# include <unistd.h>
+# include <sys/uio.h>
+# include <assert.h>
+
+int
+main(void)
+{
+	const off_t offset = 0xdefaceddeadbeefLL;
+	char buf[4];
+	struct iovec iov = { buf, sizeof buf };
+
+	(void) close(0);
+	assert(open("/dev/zero", O_RDONLY) == 0);
+	assert(pread(0, buf, sizeof buf, offset) == 4);
+	assert(preadv(0, &iov, 1, offset) == 4);
+	assert(!close(0));
+
+	assert(open("/dev/null", O_WRONLY) == 0);
+	assert(pwrite(0, buf, sizeof buf, offset) == 4);
+	assert(pwritev(0, &iov, 1, offset) == 4);
+	assert(!close(0));
+
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_PREADV && HAVE_PWRITEV")
+
+#endif
diff --git a/strace/tests/uio.expected b/strace/tests/uio.expected
new file mode 100644
index 0000000..98d5c06
--- /dev/null
+++ b/strace/tests/uio.expected
@@ -0,0 +1,4 @@
+pread(64)?\(0, "\\0\\0\\0\\0", 4, 1004211379570065135\) += 4
+preadv\(0, \[\{iov_base="\\0\\0\\0\\0", iov_len=4\}\], 1, 1004211379570065135\) += 4
+pwrite(64)?\(0, "\\0\\0\\0\\0", 4, 1004211379570065135\) += 4
+pwritev\(0, \[\{iov_base="\\0\\0\\0\\0", iov_len=4\}\], 1, 1004211379570065135\) += 4
diff --git a/strace/tests/uio.test b/strace/tests/uio.test
new file mode 100755
index 0000000..020b97e
--- /dev/null
+++ b/strace/tests/uio.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check how pread/pwrite and preadv/pwritev syscalls are traced.
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -edesc $args
+match_grep
+
+exit 0
diff --git a/strace/tests/umask.c b/strace/tests/umask.c
new file mode 100644
index 0000000..2dcea28
--- /dev/null
+++ b/strace/tests/umask.c
@@ -0,0 +1,12 @@
+#include <stdio.h>
+#include <sys/stat.h>
+
+int
+main(void)
+{
+	mode_t rc = umask(044);
+	printf("umask(%#o) = %#o\n", 044, rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/umask.test b/strace/tests/umask.test
new file mode 100755
index 0000000..1351721
--- /dev/null
+++ b/strace/tests/umask.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check umask syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a11
diff --git a/strace/tests/umount.c b/strace/tests/umount.c
new file mode 100644
index 0000000..cc382fe
--- /dev/null
+++ b/strace/tests/umount.c
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <sys/stat.h>
+#include <sys/mount.h>
+#include <sys/syscall.h>
+#include <unistd.h>
+
+#ifdef __NR_oldumount
+# define TEST_SYSCALL_STR "oldumount"
+#else
+# if defined __NR_umount && defined __NR_umount2
+#  define __NR_oldumount __NR_umount
+#  define TEST_SYSCALL_STR "umount"
+# endif
+#endif
+
+#ifdef __NR_oldumount
+
+int
+main(void)
+{
+	static const char sample[] = "umount.sample";
+	if (mkdir(sample, 0700))
+		perror_msg_and_fail("mkdir: %s", sample);
+
+	long rc = syscall(__NR_oldumount, sample);
+	printf("%s(\"%s\") = %ld %s (%m)\n",
+	       TEST_SYSCALL_STR, sample, rc, errno2name());
+
+	if (rmdir(sample))
+		perror_msg_and_fail("rmdir: %s", sample);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_oldumount")
+
+#endif
diff --git a/strace/tests/umount.test b/strace/tests/umount.test
new file mode 100755
index 0000000..a5840d5
--- /dev/null
+++ b/strace/tests/umount.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check umount syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+case "$STRACE_ARCH" in
+	alpha) syscall=oldumount ;;
+	*) syscall=umount ;;
+esac
+run_strace_match_diff -a24 -s6 -e trace=$syscall
diff --git a/strace/tests/umount2.c b/strace/tests/umount2.c
new file mode 100644
index 0000000..45ed1a4
--- /dev/null
+++ b/strace/tests/umount2.c
@@ -0,0 +1,55 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/stat.h>
+#include <sys/mount.h>
+#include <sys/syscall.h>
+
+#ifdef __NR_umount2
+# define TEST_SYSCALL_STR "umount2"
+#else
+# define __NR_umount2 __NR_umount
+# define TEST_SYSCALL_STR "umount"
+#endif
+
+int
+main(void)
+{
+	static const char sample[] = "umount2.sample";
+	if (mkdir(sample, 0700))
+		perror_msg_and_fail("mkdir: %s", sample);
+	(void) syscall(__NR_umount2, sample, 31);
+	printf("%s(\"%s\", MNT_FORCE|MNT_DETACH|MNT_EXPIRE|UMOUNT_NOFOLLOW|0x10)"
+	       " = -1 EINVAL (%m)\n", TEST_SYSCALL_STR, sample);
+	if (rmdir(sample))
+		perror_msg_and_fail("rmdir: %s", sample);
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/umount2.test b/strace/tests/umount2.test
new file mode 100755
index 0000000..c43b38d
--- /dev/null
+++ b/strace/tests/umount2.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check umount2 syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+case "$STRACE_ARCH" in
+	alpha|ia64) syscall=umount ;;
+	*) syscall=umount2 ;;
+esac
+run_strace_match_diff -s7 -e trace=$syscall
diff --git a/strace/tests/umovestr.c b/strace/tests/umovestr.c
new file mode 100644
index 0000000..95fccb6
--- /dev/null
+++ b/strace/tests/umovestr.c
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <string.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	const size_t tail_len = 257;
+	char *addr = tail_alloc(tail_len);
+	memset(addr, '/', tail_len - 1);
+	addr[tail_len - 1] = '\0';
+	if (chdir(addr))
+		perror_msg_and_skip("chdir");
+	return 0;
+}
diff --git a/strace/tests/umovestr.expected b/strace/tests/umovestr.expected
new file mode 100644
index 0000000..c26d877
--- /dev/null
+++ b/strace/tests/umovestr.expected
@@ -0,0 +1,2 @@
+chdir("////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////") = 0
++++ exited with 0 +++
diff --git a/strace/tests/umovestr.test b/strace/tests/umovestr.test
new file mode 100755
index 0000000..5ae8ffa
--- /dev/null
+++ b/strace/tests/umovestr.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# umovestr short read regression test
+
+. "${srcdir=.}/init.sh"
+
+run_prog
+run_strace -e chdir $args
+match_diff
+
+exit 0
diff --git a/strace/tests/umovestr2.c b/strace/tests/umovestr2.c
new file mode 100644
index 0000000..b2c63d8
--- /dev/null
+++ b/strace/tests/umovestr2.c
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+
+int
+main(void)
+{
+	const size_t page_len = get_page_size();
+	const size_t tail_len = page_len * 2 - 1;
+	const size_t str_len = tail_len - 1;
+
+	char *addr = tail_alloc(tail_len);
+	memset(addr, '0', str_len);
+	addr[str_len] = '\0';
+
+	char *argv[] = { NULL };
+	char *envp[] = { addr, NULL };
+	execve("", argv, envp);
+
+	printf("execve(\"\", [], [\"%0*u\"]) = -1 ENOENT (%m)\n",
+	       (int) str_len, 0);
+	puts("+++ exited with 0 +++");
+
+	return 0;
+}
diff --git a/strace/tests/umovestr2.test b/strace/tests/umovestr2.test
new file mode 100755
index 0000000..5c5d561
--- /dev/null
+++ b/strace/tests/umovestr2.test
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+# umovestr short read regression test
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -veexecve -s262144 $args > "$EXP"
+check_prog sed
+sed 1d < "$LOG" > "$OUT"
+match_diff "$OUT" "$EXP"
+
+rm -f "$EXP" "$OUT"
+
+exit 0
diff --git a/strace/tests/umovestr3.c b/strace/tests/umovestr3.c
new file mode 100644
index 0000000..cf2fa7d
--- /dev/null
+++ b/strace/tests/umovestr3.c
@@ -0,0 +1,47 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/param.h>
+
+int
+main(void)
+{
+	const unsigned int size = PATH_MAX - 1;
+	const char *p = tail_alloc(size);
+	const char *const efault = p + size;
+
+	for (; p <= efault; ++p) {
+		int rc = chdir(p);
+		printf("chdir(%p) = %d %s (%m)\n", p, rc, errno2name());
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/umovestr3.test b/strace/tests/umovestr3.test
new file mode 100755
index 0000000..d5be283
--- /dev/null
+++ b/strace/tests/umovestr3.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# yet another umovestr short read test
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a14 -e trace=chdir
diff --git a/strace/tests/uname.c b/strace/tests/uname.c
new file mode 100644
index 0000000..571cf9b
--- /dev/null
+++ b/strace/tests/uname.c
@@ -0,0 +1,44 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_uname
+
+# include <stdio.h>
+# include <sys/utsname.h>
+# include <unistd.h>
+
+int main(int ac, char **av)
+{
+	int abbrev = ac > 1;
+	struct utsname *const uname = tail_alloc(sizeof(struct utsname));
+	int rc = syscall(__NR_uname, uname);
+	printf("uname({sysname=\"");
+	print_quoted_string(uname->sysname);
+	printf("\", nodename=\"");
+	print_quoted_string(uname->nodename);
+	if (abbrev) {
+		printf("\", ...");
+	} else {
+		printf("\", release=\"");
+		print_quoted_string(uname->release);
+		printf("\", version=\"");
+		print_quoted_string(uname->version);
+		printf("\", machine=\"");
+		print_quoted_string(uname->machine);
+# ifdef HAVE_STRUCT_UTSNAME_DOMAINNAME
+		printf("\", domainname=\"");
+		print_quoted_string(uname->domainname);
+# endif
+		printf("\"");
+	}
+	printf("}) = %d\n", rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_uname")
+
+#endif
diff --git a/strace/tests/uname.test b/strace/tests/uname.test
new file mode 100755
index 0000000..03fe30c
--- /dev/null
+++ b/strace/tests/uname.test
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+# Check uname syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+check_prog uniq
+
+run_prog > /dev/null
+run_strace -v -euname $args > "$EXP"
+uniq < "$LOG" > "$OUT"
+
+run_prog "./$NAME" abbrev > /dev/null
+run_strace -euname $args >> "$EXP"
+uniq < "$LOG" >> "$OUT"
+
+match_diff "$OUT" "$EXP"
+rm -f "$OUT" "$EXP"
diff --git a/strace/tests/unix-pair-send-recv.c b/strace/tests/unix-pair-send-recv.c
new file mode 100644
index 0000000..9540239
--- /dev/null
+++ b/strace/tests/unix-pair-send-recv.c
@@ -0,0 +1,110 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#include <assert.h>
+#include <errno.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <sys/syscall.h>
+
+#ifndef __NR_send
+# define __NR_send -1
+#endif
+#define SC_send 9
+
+#ifndef __NR_recv
+# define __NR_recv -1
+#endif
+#define SC_recv 10
+
+static int
+sys_send(int sockfd, const void *buf, size_t len, int flags)
+{
+	int rc = socketcall(__NR_send, SC_send,
+			    sockfd, (long) buf, len, flags, 0);
+	if (rc < 0 && ENOSYS == errno)
+		perror_msg_and_skip("send");
+	return rc;
+}
+
+static int
+sys_recv(int sockfd, const void *buf, size_t len, int flags)
+{
+	int rc = socketcall(__NR_recv, SC_recv,
+			    sockfd, (long) buf, len, flags, 0);
+	if (rc < 0 && ENOSYS == errno)
+		perror_msg_and_skip("recv");
+	return rc;
+}
+
+static void
+transpose(char *str, const size_t len)
+{
+	size_t i;
+
+	for (i = 0; i < len / 2; ++i) {
+		char c = str[i];
+		str[i] = str[len - 1 - i];
+		str[len - 1 - i] = c;
+	}
+}
+
+int
+main(int ac, char **av)
+{
+	assert(ac == 2);
+	const size_t len = strlen(av[1]);
+	assert(len);
+	char *const buf0 = tail_alloc(len);
+	char *const buf1 = tail_alloc(len);
+	memcpy(buf0, av[1], len);
+
+	(void) close(0);
+	(void) close(1);
+
+	int sv[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
+		perror_msg_and_skip("socketpair");
+
+	assert(sys_send(0, buf0, len, MSG_DONTROUTE) == (int) len);
+	assert(sys_recv(1, buf1, len, MSG_WAITALL) == (int) len);
+
+	transpose(buf1, len);
+	assert(sys_send(1, buf1, len, MSG_DONTROUTE) == (int) len);
+	if (close(1))
+		perror_msg_and_fail("close(1)");
+
+	assert(sys_recv(0, buf0, len, MSG_WAITALL) == (int) len);
+	if (close(0))
+		perror_msg_and_fail("close(0)");
+	assert(sys_recv(0, NULL, len, MSG_DONTWAIT) == -1);
+
+	return 0;
+}
diff --git a/strace/tests/unix-pair-send-recv.expected b/strace/tests/unix-pair-send-recv.expected
new file mode 100644
index 0000000..3935978
--- /dev/null
+++ b/strace/tests/unix-pair-send-recv.expected
@@ -0,0 +1,10 @@
+send(0, "abcdefghijklmnopqrstuvwxyz", 26, MSG_DONTROUTE) = 26
+ | 00000  61 62 63 64 65 66 67 68  69 6a 6b 6c 6d 6e 6f 70  abcdefghijklmnop |
+ | 00010  71 72 73 74 75 76 77 78  79 7a                    qrstuvwxyz       |
+recv(1, "abcdefghijklmnopqrstuvwxyz", 26, MSG_WAITALL) = 26
+send(1, "zyxwvutsrqponmlkjihgfedcba", 26, MSG_DONTROUTE) = 26
+recv(0, "zyxwvutsrqponmlkjihgfedcba", 26, MSG_WAITALL) = 26
+ | 00000  7a 79 78 77 76 75 74 73  72 71 70 6f 6e 6d 6c 6b  zyxwvutsrqponmlk |
+ | 00010  6a 69 68 67 66 65 64 63  62 61                    jihgfedcba       |
+recv(0, NULL, 26, MSG_DONTWAIT) = -1 EBADF (Bad file descriptor)
++++ exited with 0 +++
diff --git a/strace/tests/unix-pair-send-recv.test b/strace/tests/unix-pair-send-recv.test
new file mode 100755
index 0000000..4defdeb
--- /dev/null
+++ b/strace/tests/unix-pair-send-recv.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check decoding and dumping of send and recv syscalls.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./unix-pair-send-recv abcdefghijklmnopqrstuvwxyz
+run_strace -a32 -esignal=none -esend,recv -eread=0 -ewrite=0 $args
+match_diff
+
+exit 0
diff --git a/strace/tests/unix-pair-sendto-recvfrom.c b/strace/tests/unix-pair-sendto-recvfrom.c
new file mode 100644
index 0000000..cea382c
--- /dev/null
+++ b/strace/tests/unix-pair-sendto-recvfrom.c
@@ -0,0 +1,87 @@
+/*
+ * Check decoding and dumping of sendto and recvfrom syscalls.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/socket.h>
+#include <sys/wait.h>
+
+static void
+transpose(char *str, int len)
+{
+	int i;
+
+	for (i = 0; i < len / 2; ++i) {
+		char c = str[i];
+		str[i] = str[len - 1 - i];
+		str[len - 1 - i] = c;
+	}
+}
+
+int
+main(int ac, char **av)
+{
+	assert(ac == 2);
+	const int len = strlen(av[1]);
+	assert(len);
+
+	(void) close(0);
+	(void) close(1);
+
+	int sv[2];
+	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
+		perror_msg_and_skip("socketpair");
+
+	pid_t pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (pid) {
+		assert(close(1) == 0);
+		transpose(av[1], len);
+		assert(sendto(0, av[1], len, MSG_DONTROUTE, NULL, 0) == len);
+		assert(recvfrom(0, av[1], len, MSG_WAITALL, NULL, NULL) == len);
+		assert(close(0) == 0);
+
+                int status;
+		assert(waitpid(pid, &status, 0) == pid);
+		assert(status == 0);
+	} else {
+		assert(close(0) == 0);
+		assert(recvfrom(1, av[1], len, MSG_WAITALL, NULL, NULL) == len);
+		transpose(av[1], len);
+		assert(sendto(1, av[1], len, MSG_DONTROUTE, NULL, 0) == len);
+		assert(recvfrom(1, av[1], len, MSG_WAITALL, NULL, NULL) == 0);
+		assert(close(1) == 0);
+	}
+
+	return 0;
+}
diff --git a/strace/tests/unix-pair-sendto-recvfrom.expected b/strace/tests/unix-pair-sendto-recvfrom.expected
new file mode 100644
index 0000000..f8fd244
--- /dev/null
+++ b/strace/tests/unix-pair-sendto-recvfrom.expected
@@ -0,0 +1,7 @@
+sendto(0, "zyxwvutsrqponmlkjihgfedcba", 26, MSG_DONTROUTE, NULL, 0) = 26
+ | 00000  7a 79 78 77 76 75 74 73  72 71 70 6f 6e 6d 6c 6b  zyxwvutsrqponmlk |
+ | 00010  6a 69 68 67 66 65 64 63  62 61                    jihgfedcba       |
+recvfrom(0, "abcdefghijklmnopqrstuvwxyz", 26, MSG_WAITALL, NULL, NULL) = 26
+ | 00000  61 62 63 64 65 66 67 68  69 6a 6b 6c 6d 6e 6f 70  abcdefghijklmnop |
+ | 00010  71 72 73 74 75 76 77 78  79 7a                    qrstuvwxyz       |
++++ exited with 0 +++
diff --git a/strace/tests/unix-pair-sendto-recvfrom.test b/strace/tests/unix-pair-sendto-recvfrom.test
new file mode 100755
index 0000000..21afe23
--- /dev/null
+++ b/strace/tests/unix-pair-sendto-recvfrom.test
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+# Check decoding and dumping of sendto and recvfrom syscalls.
+
+. "${srcdir=.}/init.sh"
+
+run_prog ./unix-pair-sendto-recvfrom abcdefghijklmnopqrstuvwxyz
+run_strace -esignal=none -esendto,recvfrom -eread=0 -ewrite=0 $args
+match_diff
+
+exit 0
diff --git a/strace/tests/unlink.c b/strace/tests/unlink.c
new file mode 100644
index 0000000..f5a1a1a
--- /dev/null
+++ b/strace/tests/unlink.c
@@ -0,0 +1,26 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_unlink
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "unlink_sample";
+
+	long rc = syscall(__NR_unlink, sample);
+	printf("unlink(\"%s\") = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_unlink")
+
+#endif
diff --git a/strace/tests/unlink.test b/strace/tests/unlink.test
new file mode 100755
index 0000000..09bf79a
--- /dev/null
+++ b/strace/tests/unlink.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check unlink syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24
diff --git a/strace/tests/unlinkat.c b/strace/tests/unlinkat.c
new file mode 100644
index 0000000..29eeb19
--- /dev/null
+++ b/strace/tests/unlinkat.c
@@ -0,0 +1,34 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_unlinkat
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	static const char sample[] = "unlinkat_sample";
+	const long fd = (long) 0xdeadbeefffffffff;
+
+	long rc = syscall(__NR_unlinkat, fd, sample, 0);
+	printf("unlinkat(%d, \"%s\", 0) = %ld %s (%m)\n",
+	       (int) fd, sample, rc, errno2name());
+
+	rc = syscall(__NR_unlinkat, -100, sample, -1L);
+	printf("unlinkat(%s, \"%s\", %s) = %ld %s (%m)\n",
+	       "AT_FDCWD", sample,
+	       "AT_SYMLINK_NOFOLLOW|AT_REMOVEDIR|AT_SYMLINK_FOLLOW"
+	       "|AT_NO_AUTOMOUNT|AT_EMPTY_PATH|0xffffe0ff",
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_unlinkat")
+
+#endif
diff --git a/strace/tests/unlinkat.test b/strace/tests/unlinkat.test
new file mode 100755
index 0000000..864261f
--- /dev/null
+++ b/strace/tests/unlinkat.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check unlinkat syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a35
diff --git a/strace/tests/userfaultfd.c b/strace/tests/userfaultfd.c
new file mode 100644
index 0000000..5747a2a
--- /dev/null
+++ b/strace/tests/userfaultfd.c
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <fcntl.h>
+#include <sys/syscall.h>
+
+#if defined __NR_userfaultfd && defined O_CLOEXEC
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	long rc = syscall(__NR_userfaultfd, 1 | O_NONBLOCK | O_CLOEXEC);
+	printf("userfaultfd(O_NONBLOCK|O_CLOEXEC|0x1) = %ld %s (%m)\n",
+	       rc, errno2name());
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_userfaultfd && O_CLOEXEC")
+
+#endif
diff --git a/strace/tests/userfaultfd.test b/strace/tests/userfaultfd.test
new file mode 100755
index 0000000..af8b6fb
--- /dev/null
+++ b/strace/tests/userfaultfd.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check userfaultfd syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a38
diff --git a/strace/tests/utime.c b/strace/tests/utime.c
new file mode 100644
index 0000000..2286217
--- /dev/null
+++ b/strace/tests/utime.c
@@ -0,0 +1,67 @@
+/*
+ * This file is part of utime strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <time.h>
+#include <utime.h>
+#include <errno.h>
+#include <stdio.h>
+
+static void
+print_tm(const struct tm * const p)
+{
+	printf("%02d/%02d/%02d-%02d:%02d:%02d",
+	       p->tm_year + 1900, p->tm_mon + 1, p->tm_mday,
+	       p->tm_hour, p->tm_min, p->tm_sec);
+}
+
+int
+main(void)
+{
+	utime("", NULL);
+	printf("utime(\"\", NULL) = -1 ENOENT (%m)\n");
+
+	const time_t t = time(NULL);
+	const struct tm * const p = localtime(&t);
+	const struct utimbuf u = { .actime = t, .modtime = t };
+	const struct utimbuf const *tail_u = tail_memdup(&u, sizeof(u));
+
+	printf("utime(\"utime\\nfilename\", [");
+	print_tm(p);
+	printf(", ");
+	print_tm(p);
+	printf("]) = -1 ENOENT ");
+	assert(utime("utime\nfilename", tail_u) == -1);
+	if (ENOENT != errno)
+		perror_msg_and_skip("utime");
+	printf("(%m)\n");
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/utime.test b/strace/tests/utime.test
new file mode 100755
index 0000000..4cb95ea
--- /dev/null
+++ b/strace/tests/utime.test
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+# Check decoding of utime syscall.
+
+. "${srcdir=.}/init.sh"
+
+$STRACE -e utime -h > /dev/null ||
+	        skip_ 'utime syscall is not supported on this architecture'
+
+run_prog > /dev/null
+run_strace -a 16 -e utime $args > "$OUT"
+
+check_prog grep
+LC_ALL=C grep -x "utime(.*" "$LOG" > /dev/null || {
+	rm -f "$OUT"
+	skip_ 'test executable does not use utime syscall'
+}
+match_diff "$LOG" "$OUT"
+
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/utimensat.c b/strace/tests/utimensat.c
new file mode 100644
index 0000000..24e9106
--- /dev/null
+++ b/strace/tests/utimensat.c
@@ -0,0 +1,100 @@
+/*
+ * This file is part of utimensat strace test.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <stdint.h>
+#include <stdio.h>
+#include <sys/stat.h>
+#include <sys/time.h>
+
+#if defined HAVE_UTIMENSAT \
+ && defined AT_FDCWD && defined AT_SYMLINK_NOFOLLOW \
+ && defined UTIME_NOW && defined UTIME_OMIT
+
+static void
+print_ts(const struct timespec *ts)
+{
+	printf("{%ju, %ju}", (uintmax_t) ts->tv_sec, (uintmax_t) ts->tv_nsec);
+}
+
+int
+main(void)
+{
+	static const char fname[] = "utimensat\nfilename";
+
+	assert(utimensat(AT_FDCWD, fname, NULL, 0) == -1);
+	if (ENOENT != errno)
+		error_msg_and_skip("utimensat");
+
+	#define PREFIX "utimensat(AT_FDCWD, \"utimensat\\nfilename\", "
+	printf(PREFIX "NULL, 0) = -1 ENOENT (%m)\n");
+
+	struct timeval tv;
+	struct timespec ts[2];
+
+	if (gettimeofday(&tv, NULL))
+		perror_msg_and_skip("gettimeofday");
+
+	ts[0].tv_sec = tv.tv_sec;
+	ts[0].tv_nsec = tv.tv_usec;
+	ts[1].tv_sec = tv.tv_sec - 1;
+	ts[1].tv_nsec = tv.tv_usec + 1;
+
+	printf(PREFIX "[");
+	print_ts(&ts[0]);
+	printf(", ");
+	print_ts(&ts[1]);
+	printf("], AT_SYMLINK_NOFOLLOW) = -1 ENOENT ");
+
+	assert(utimensat(AT_FDCWD, fname, ts, AT_SYMLINK_NOFOLLOW) == -1);
+	if (ENOENT != errno)
+		error_msg_and_skip("utimensat");
+	printf("(%m)\n");
+
+	ts[0].tv_nsec = UTIME_NOW;
+	ts[1].tv_nsec = UTIME_OMIT;
+	assert(utimensat(AT_FDCWD, fname, ts, AT_SYMLINK_NOFOLLOW) == -1);
+	if (ENOENT != errno)
+		error_msg_and_skip("utimensat");
+	printf(PREFIX "[UTIME_NOW, UTIME_OMIT], AT_SYMLINK_NOFOLLOW)"
+	       " = -1 ENOENT (%m)\n");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_UTIMENSAT && AT_FDCWD && AT_SYMLINK_NOFOLLOW"
+		    " && UTIME_NOW && UTIME_OMIT")
+
+#endif
diff --git a/strace/tests/utimensat.test b/strace/tests/utimensat.test
new file mode 100755
index 0000000..52e3f31
--- /dev/null
+++ b/strace/tests/utimensat.test
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+# Check decoding of utimensat syscall.
+
+. "${srcdir=.}/init.sh"
+
+run_prog > /dev/null
+run_strace -e utimensat $args > "$OUT"
+
+check_prog grep
+LC_ALL=C grep -x "utimensat(.*" "$LOG" > /dev/null || {
+        rm -f "$OUT"
+        skip_ 'test executable does not use utimensat syscall'
+}
+
+match_diff "$LOG" "$OUT"
+
+rm -f "$OUT"
+
+exit 0
diff --git a/strace/tests/utimes.c b/strace/tests/utimes.c
new file mode 100644
index 0000000..e9fe931
--- /dev/null
+++ b/strace/tests/utimes.c
@@ -0,0 +1,83 @@
+/*
+ * Check decoding of utimes syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_utimes
+
+# include <stdio.h>
+# include <sys/time.h>
+# include <unistd.h>
+
+#define CAST_NUM(n)						\
+	(sizeof(n) == sizeof(long) ?				\
+		(unsigned long long) (unsigned long) (n) :	\
+		(unsigned long long) (n))
+
+int
+main(void)
+{
+	struct timeval tv;
+	if (gettimeofday(&tv, NULL))
+		perror_msg_and_fail("gettimeofday");
+
+	static const char sample[] = "utimes_sample";
+
+	long rc = syscall(__NR_utimes, sample, 0);
+	printf("utimes(\"%s\", NULL) = %ld %s (%m)\n",
+	       sample, rc, errno2name());
+
+	struct timeval *const ts = tail_alloc(sizeof(*ts) * 2);
+
+	rc = syscall(__NR_utimes, 0, ts + 1);
+	printf("utimes(NULL, %p) = %ld %s (%m)\n",
+	       ts + 1, rc, errno2name());
+
+	ts[0].tv_sec = tv.tv_sec;
+	ts[0].tv_usec = tv.tv_usec;
+	ts[1].tv_sec = tv.tv_sec - 1;
+	ts[1].tv_usec = tv.tv_usec + 1;
+
+	rc = syscall(__NR_utimes, "", ts);
+	printf("utimes(\"\", [{%llu, %llu}, {%llu, %llu}])"
+	       " = %ld %s (%m)\n",
+	       CAST_NUM(ts[0].tv_sec), CAST_NUM(ts[0].tv_usec),
+	       CAST_NUM(ts[1].tv_sec), CAST_NUM(ts[1].tv_usec),
+	       rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_utimes")
+
+#endif
diff --git a/strace/tests/utimes.test b/strace/tests/utimes.test
new file mode 100755
index 0000000..99143a0
--- /dev/null
+++ b/strace/tests/utimes.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check utimes syscall decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a21
diff --git a/strace/tests/vfork-f.c b/strace/tests/vfork-f.c
new file mode 100644
index 0000000..b14e4b4
--- /dev/null
+++ b/strace/tests/vfork-f.c
@@ -0,0 +1,109 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <fcntl.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/wait.h>
+
+static inline int
+logit_(const char *const str)
+{
+	return !chdir(str);
+}
+
+#define prefix "vfork-f."
+#define logit(arg) logit_(prefix arg)
+
+int main(int ac, char **av)
+{
+	if (ac < 1)
+		return 1;
+	if (ac > 1) {
+		if (read(0, &ac, sizeof(int)))
+			return 2;
+		return logit("exec");
+	}
+
+	logit("start");
+
+	int child_wait_fds[2];
+	(void) close(0);
+	if (pipe(child_wait_fds))
+		perror_msg_and_fail("pipe");
+	if (fcntl(child_wait_fds[1], F_SETFD, FD_CLOEXEC))
+		perror_msg_and_fail("fcntl");
+
+	int parent_wait_fds[2];
+	if (pipe(parent_wait_fds))
+		perror_msg_and_fail("pipe");
+	if (fcntl(parent_wait_fds[0], F_SETFD, FD_CLOEXEC))
+		perror_msg_and_fail("fcntl");
+	if (fcntl(parent_wait_fds[1], F_SETFD, FD_CLOEXEC))
+		perror_msg_and_fail("fcntl");
+
+	char *const args[] = { av[0], (char *) "", NULL };
+	pid_t pid = vfork();
+
+	if (pid < 0)
+		perror_msg_and_fail("vfork");
+
+	if (!pid) {
+		if (logit("child") || execve(args[0], args, args + 1))
+			_exit(2);
+	}
+
+	close(0);
+	close(parent_wait_fds[1]);
+
+	if (read(parent_wait_fds[0], &parent_wait_fds[1], sizeof(int)))
+		perror_msg_and_fail("read");
+	logit("parent");
+	close(child_wait_fds[1]);
+
+	int status;
+	assert(wait(&status) == pid);
+	assert(status == 0);
+
+	pid_t ppid = getpid();
+	logit("finish");
+
+	printf("%-5d chdir(\"%sstart\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%schild\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%sparent\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%sexec\") = -1 ENOENT (%m)\n"
+	       "%-5d chdir(\"%sfinish\") = -1 ENOENT (%m)\n",
+	       ppid, prefix,
+	       pid, prefix,
+	       ppid, prefix,
+	       pid, prefix,
+	       ppid, prefix);
+	return 0;
+}
diff --git a/strace/tests/vfork-f.test b/strace/tests/vfork-f.test
new file mode 100755
index 0000000..ff4422b
--- /dev/null
+++ b/strace/tests/vfork-f.test
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# Check how strace -f follows vfork syscall.
+
+. "${srcdir=.}/fork-f.test"
diff --git a/strace/tests/vhangup.c b/strace/tests/vhangup.c
new file mode 100644
index 0000000..468f334
--- /dev/null
+++ b/strace/tests/vhangup.c
@@ -0,0 +1,37 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_vhangup
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	if (setsid() == -1)
+		perror_msg_and_skip("setsid");
+
+	long rc = syscall(__NR_vhangup);
+
+	/*
+	 * On setsid() success, the new session has no controlling terminal,
+	 * therefore a subsequent vhangup() has nothing to hangup.
+	 *
+	 * The system call, however, returns 0 iff the calling process
+	 * has CAP_SYS_TTY_CONFIG capability.
+	 */
+	if (rc)
+		printf("vhangup() = %ld %s (%m)\n", rc, errno2name());
+	else
+		puts("vhangup() = 0");
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_vhangup")
+
+#endif
diff --git a/strace/tests/vhangup.test b/strace/tests/vhangup.test
new file mode 100755
index 0000000..8fe1cac
--- /dev/null
+++ b/strace/tests/vhangup.test
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+# Check vhangup syscall decoding.
+
+. "${srcdir=.}/init.sh"
+
+run_strace_match_diff -a10
diff --git a/strace/tests/vmsplice.c b/strace/tests/vmsplice.c
new file mode 100644
index 0000000..06c0694
--- /dev/null
+++ b/strace/tests/vmsplice.c
@@ -0,0 +1,107 @@
+/*
+ * This file is part of vmsplice strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_vmsplice
+
+# include <assert.h>
+# include <stdio.h>
+# include <unistd.h>
+# include <sys/uio.h>
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	assert(0 == fds[0]);
+	assert(1 == fds[1]);
+
+	static const char w0_c[] = "012";
+	const char *w0_d = hexdump_strdup(w0_c);
+	void *w0 = tail_memdup(w0_c, LENGTH_OF(w0_c));
+
+	static const char w1_c[] = "34567";
+	const char *w1_d = hexdump_strdup(w1_c);
+	void *w1 = tail_memdup(w1_c, LENGTH_OF(w1_c));
+
+	static const char w2_c[] = "89abcde";
+	const char *w2_d = hexdump_strdup(w2_c);
+	void *w2 = tail_memdup(w2_c, LENGTH_OF(w2_c));
+
+	const struct iovec iov_[] = {
+		{
+			.iov_base = w0,
+			.iov_len = LENGTH_OF(w0_c)
+		}, {
+			.iov_base = w1,
+			.iov_len = LENGTH_OF(w1_c)
+		}, {
+			.iov_base = w2,
+			.iov_len = LENGTH_OF(w2_c)
+		}
+	};
+	const struct iovec *iov = tail_memdup(iov_, sizeof(iov_));
+	const unsigned int len =
+		LENGTH_OF(w0_c) + LENGTH_OF(w1_c) + LENGTH_OF(w2_c);
+
+	tprintf("vmsplice(1, [{iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}"
+		", {iov_base=\"%s\", iov_len=%u}], %u, %s) = %u\n"
+		" * %u bytes in buffer 0\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 1\n"
+		" | 00000 %-49s  %-16s |\n"
+		" * %u bytes in buffer 2\n"
+		" | 00000 %-49s  %-16s |\n",
+		w0_c, LENGTH_OF(w0_c), w1_c, LENGTH_OF(w1_c),
+		w2_c, LENGTH_OF(w2_c), ARRAY_SIZE(iov_),
+		"SPLICE_F_NONBLOCK", len,
+		LENGTH_OF(w0_c), w0_d, w0_c,
+		LENGTH_OF(w1_c), w1_d, w1_c, LENGTH_OF(w2_c), w2_d, w2_c);
+
+	const long rc = syscall(__NR_vmsplice, 1, iov, ARRAY_SIZE(iov_), 2);
+	if (rc < 0)
+		perror_msg_and_skip("vmsplice");
+	assert(rc == (int) len);
+
+	tprintf("+++ exited with 0 +++\n");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_vmsplice")
+
+#endif
diff --git a/strace/tests/vmsplice.test b/strace/tests/vmsplice.test
new file mode 100755
index 0000000..8a80650
--- /dev/null
+++ b/strace/tests/vmsplice.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of vmsplice syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -ewrite=1
diff --git a/strace/tests/wait4-v.c b/strace/tests/wait4-v.c
new file mode 100644
index 0000000..95a3c8b
--- /dev/null
+++ b/strace/tests/wait4-v.c
@@ -0,0 +1,3 @@
+/* This file is part of wait4-v strace test. */
+#define VERBOSE_RUSAGE
+#include "wait4.c"
diff --git a/strace/tests/wait4-v.test b/strace/tests/wait4-v.test
new file mode 100755
index 0000000..58e55f2
--- /dev/null
+++ b/strace/tests/wait4-v.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check verbose decoding of wait4 syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -e signal=none -e trace=wait4
diff --git a/strace/tests/wait4.c b/strace/tests/wait4.c
new file mode 100644
index 0000000..981818c
--- /dev/null
+++ b/strace/tests/wait4.c
@@ -0,0 +1,199 @@
+/*
+ * Check decoding of wait4 syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <signal.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/wait.h>
+#include <sys/resource.h>
+
+static const char *
+sprint_rusage(const struct rusage *const ru)
+{
+	static char buf[1024];
+	snprintf(buf, sizeof(buf),
+		 "{ru_utime={%lu, %lu}"
+		 ", ru_stime={%lu, %lu}"
+#ifdef VERBOSE_RUSAGE
+		 ", ru_maxrss=%lu"
+		 ", ru_ixrss=%lu"
+		 ", ru_idrss=%lu"
+		 ", ru_isrss=%lu"
+		 ", ru_minflt=%lu"
+		 ", ru_majflt=%lu"
+		 ", ru_nswap=%lu"
+		 ", ru_inblock=%lu"
+		 ", ru_oublock=%lu"
+		 ", ru_msgsnd=%lu"
+		 ", ru_msgrcv=%lu"
+		 ", ru_nsignals=%lu"
+		 ", ru_nvcsw=%lu"
+		 ", ru_nivcsw=%lu}"
+#else
+		 ", ...}"
+#endif
+		 , (long) ru->ru_utime.tv_sec
+		 , (long) ru->ru_utime.tv_usec
+		 , (long) ru->ru_stime.tv_sec
+		 , (long) ru->ru_stime.tv_usec
+#ifdef VERBOSE_RUSAGE
+		 , (long) ru->ru_maxrss
+		 , (long) ru->ru_ixrss
+		 , (long) ru->ru_idrss
+		 , (long) ru->ru_isrss
+		 , (long) ru->ru_minflt
+		 , (long) ru->ru_majflt
+		 , (long) ru->ru_nswap
+		 , (long) ru->ru_inblock
+		 , (long) ru->ru_oublock
+		 , (long) ru->ru_msgsnd
+		 , (long) ru->ru_msgrcv
+		 , (long) ru->ru_nsignals
+		 , (long) ru->ru_nvcsw
+		 , (long) ru->ru_nivcsw
+#endif
+		 );
+	return buf;
+}
+
+static pid_t
+do_wait4(pid_t pid, int *wstatus, int options, struct rusage *ru)
+{
+	sigset_t mask = {};
+	sigaddset(&mask, SIGCHLD);
+
+	assert(sigprocmask(SIG_BLOCK, &mask, NULL) == 0);
+	pid_t rc = wait4(pid, wstatus, options, ru);
+	assert(sigprocmask(SIG_UNBLOCK, &mask, NULL) == 0);
+	return rc;
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	pid_t pid;
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		char c;
+		(void) close(1);
+		assert(read(0, &c, sizeof(c)) == 1);
+		return 42;
+	}
+
+	(void) close(0);
+
+	int *const s = tail_alloc(sizeof(*s));
+	if (wait4(pid, s, WNOHANG|__WALL, NULL))
+		perror_msg_and_fail("wait4 #1");
+	tprintf("wait4(%d, %p, WNOHANG|__WALL, NULL) = 0\n", pid, s);
+
+	struct rusage *const rusage = tail_alloc(sizeof(*rusage));
+	if (wait4(pid, s, WNOHANG|__WALL, rusage))
+		perror_msg_and_fail("wait4 #2");
+	tprintf("wait4(%d, %p, WNOHANG|__WALL, %p) = 0\n", pid, s, rusage);
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	assert(do_wait4(pid, s, 0, rusage) == pid);
+	assert(WIFEXITED(*s) && WEXITSTATUS(*s) == 42);
+	tprintf("wait4(%d, [{WIFEXITED(s) && WEXITSTATUS(s) == 42}], 0, %s)"
+		" = %d\n", pid, sprint_rusage(rusage), pid);
+
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		(void) raise(SIGUSR1);
+		return 1;
+	}
+
+	assert(do_wait4(pid, s, __WALL, rusage) == pid);
+	assert(WIFSIGNALED(*s) && WTERMSIG(*s) == SIGUSR1);
+	tprintf("wait4(%d, [{WIFSIGNALED(s) && WTERMSIG(s) == SIGUSR1}]"
+		", __WALL, %s) = %d\n", pid, sprint_rusage(rusage), pid);
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		(void) close(1);
+		raise(SIGSTOP);
+		char c;
+		assert(read(0, &c, sizeof(c)) == 1);
+		return 0;
+	}
+
+	(void) close(0);
+
+	assert(do_wait4(pid, s, WSTOPPED, rusage) == pid);
+	assert(WIFSTOPPED(*s) && WSTOPSIG(*s) == SIGSTOP);
+	tprintf("wait4(%d, [{WIFSTOPPED(s) && WSTOPSIG(s) == SIGSTOP}]"
+		", WSTOPPED, %s) = %d\n", pid, sprint_rusage(rusage), pid);
+
+	if (kill(pid, SIGCONT))
+		perror_msg_and_fail("kill(SIGCONT)");
+
+#if defined WCONTINUED && defined WIFCONTINUED
+	assert(do_wait4(pid, s, WCONTINUED, rusage) == pid);
+	assert(WIFCONTINUED(*s));
+	tprintf("wait4(%d, [{WIFCONTINUED(s)}], WCONTINUED"
+		", %s) = %d\n", pid, sprint_rusage(rusage), pid);
+#endif /* WCONTINUED && WIFCONTINUED */
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	assert(do_wait4(pid, s, 0, rusage) == pid);
+	assert(WIFEXITED(*s) && WEXITSTATUS(*s) == 0);
+	tprintf("wait4(%d, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0"
+		", %s) = %d\n", pid, sprint_rusage(rusage), pid);
+
+	assert(wait4(-1, s, WNOHANG|WSTOPPED|__WALL, rusage) == -1);
+	tprintf("wait4(-1, %p, WNOHANG|WSTOPPED|__WALL, %p) = -1 %s (%m)\n",
+		s, rusage, errno2name());
+
+	tprintf("%s\n", "+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/wait4.test b/strace/tests/wait4.test
new file mode 100755
index 0000000..6338d1f
--- /dev/null
+++ b/strace/tests/wait4.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of wait4 syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -esignal=none
diff --git a/strace/tests/waitid-v.c b/strace/tests/waitid-v.c
new file mode 100644
index 0000000..06171ae
--- /dev/null
+++ b/strace/tests/waitid-v.c
@@ -0,0 +1,3 @@
+/* This file is part of waitid-v strace test. */
+#define VERBOSE_RUSAGE
+#include "waitid.c"
diff --git a/strace/tests/waitid-v.test b/strace/tests/waitid-v.test
new file mode 100755
index 0000000..eb498cb
--- /dev/null
+++ b/strace/tests/waitid-v.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check verbose decoding of waitid syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -v -e signal=none -e trace=waitid
diff --git a/strace/tests/waitid.c b/strace/tests/waitid.c
new file mode 100644
index 0000000..bd7e8ef
--- /dev/null
+++ b/strace/tests/waitid.c
@@ -0,0 +1,263 @@
+/*
+ * Check decoding of waitid syscall.
+ *
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <signal.h>
+#include <stdio.h>
+#include <string.h>
+#include <unistd.h>
+#include <sys/wait.h>
+#include <sys/resource.h>
+#include <sys/syscall.h>
+
+static const char *
+sprint_rusage(const struct rusage *const ru)
+{
+	static char buf[1024];
+	snprintf(buf, sizeof(buf),
+		 "{ru_utime={%llu, %llu}"
+		 ", ru_stime={%llu, %llu}"
+#ifdef VERBOSE_RUSAGE
+		 ", ru_maxrss=%llu"
+		 ", ru_ixrss=%llu"
+		 ", ru_idrss=%llu"
+		 ", ru_isrss=%llu"
+		 ", ru_minflt=%llu"
+		 ", ru_majflt=%llu"
+		 ", ru_nswap=%llu"
+		 ", ru_inblock=%llu"
+		 ", ru_oublock=%llu"
+		 ", ru_msgsnd=%llu"
+		 ", ru_msgrcv=%llu"
+		 ", ru_nsignals=%llu"
+		 ", ru_nvcsw=%llu"
+		 ", ru_nivcsw=%llu}"
+#else
+		 ", ...}"
+#endif
+		 , widen_to_ull(ru->ru_utime.tv_sec)
+		 , widen_to_ull(ru->ru_utime.tv_usec)
+		 , widen_to_ull(ru->ru_stime.tv_sec)
+		 , widen_to_ull(ru->ru_stime.tv_usec)
+#ifdef VERBOSE_RUSAGE
+		 , widen_to_ull(ru->ru_maxrss)
+		 , widen_to_ull(ru->ru_ixrss)
+		 , widen_to_ull(ru->ru_idrss)
+		 , widen_to_ull(ru->ru_isrss)
+		 , widen_to_ull(ru->ru_minflt)
+		 , widen_to_ull(ru->ru_majflt)
+		 , widen_to_ull(ru->ru_nswap)
+		 , widen_to_ull(ru->ru_inblock)
+		 , widen_to_ull(ru->ru_oublock)
+		 , widen_to_ull(ru->ru_msgsnd)
+		 , widen_to_ull(ru->ru_msgrcv)
+		 , widen_to_ull(ru->ru_nsignals)
+		 , widen_to_ull(ru->ru_nvcsw)
+		 , widen_to_ull(ru->ru_nivcsw)
+#endif
+		 );
+	return buf;
+}
+
+#define CASE(x) case x: return #x
+
+static const char *
+si_code_2_name(const int code)
+{
+	switch (code) {
+#ifdef CLD_EXITED
+	CASE(CLD_EXITED);
+#endif
+#ifdef CLD_KILLED
+	CASE(CLD_KILLED);
+#endif
+#ifdef CLD_DUMPED
+	CASE(CLD_DUMPED);
+#endif
+#ifdef CLD_TRAPPED
+	CASE(CLD_TRAPPED);
+#endif
+#ifdef CLD_STOPPED
+	CASE(CLD_STOPPED);
+#endif
+#ifdef CLD_CONTINUED
+	CASE(CLD_CONTINUED);
+#endif
+	default: perror_msg_and_fail("unknown si_code %d", code);
+	}
+}
+
+static const char *
+sprint_siginfo(const siginfo_t *const si, const char *const status_text)
+{
+	static char buf[1024];
+	snprintf(buf, sizeof(buf),
+		 "{si_signo=SIGCHLD"
+		 ", si_code=%s"
+		 ", si_pid=%u"
+		 ", si_uid=%u"
+		 ", si_status=%s"
+		 ", si_utime=%llu"
+		 ", si_stime=%llu}",
+		 si_code_2_name(si->si_code),
+		 si->si_pid,
+		 si->si_uid,
+		 status_text,
+		 widen_to_ull(si->si_utime),
+		 widen_to_ull(si->si_stime));
+	return buf;
+}
+
+static unsigned long
+poison(unsigned int v)
+{
+	return (unsigned long) 0xfacefeed00000000 | v;
+}
+
+static long
+do_waitid(const unsigned int idtype,
+	  const unsigned int id,
+	  const siginfo_t const *infop,
+	  const unsigned int options,
+	  const struct rusage *const rusage)
+{
+	sigset_t mask = {};
+	sigaddset(&mask, SIGCHLD);
+
+	assert(sigprocmask(SIG_BLOCK, &mask, NULL) == 0);
+	long rc = syscall(__NR_waitid, poison(idtype), poison(id),
+			  infop, poison(options), rusage);
+	assert(sigprocmask(SIG_UNBLOCK, &mask, NULL) == 0);
+	return rc;
+}
+
+int
+main(void)
+{
+	tprintf("%s", "");
+
+	int fds[2];
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	pid_t pid;
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		char c;
+		(void) close(1);
+		assert(read(0, &c, sizeof(c)) == 1);
+		return 42;
+	}
+
+	(void) close(0);
+
+	if (do_waitid(P_PID, pid, 0, WNOHANG|WEXITED, 0))
+		perror_msg_and_fail("waitid #1");
+	tprintf("waitid(P_PID, %d, NULL, WNOHANG|WEXITED, NULL) = 0\n", pid);
+
+	siginfo_t *const sinfo = tail_alloc(sizeof(*sinfo));
+	memset(sinfo, 0, sizeof(*sinfo));
+	struct rusage *const rusage = tail_alloc(sizeof(*rusage));
+	if (do_waitid(P_PID, pid, sinfo, WNOHANG|WEXITED|WSTOPPED, rusage))
+		perror_msg_and_fail("waitid #2");
+	tprintf("waitid(P_PID, %d, {}, WNOHANG|WEXITED|WSTOPPED, %s) = 0\n",
+		pid, sprint_rusage(rusage));
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	if (do_waitid(P_PID, pid, sinfo, WEXITED, rusage))
+		perror_msg_and_fail("waitid #3");
+	tprintf("waitid(P_PID, %d, %s, WEXITED, %s) = 0\n",
+		pid, sprint_siginfo(sinfo, "42"), sprint_rusage(rusage));
+
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		(void) raise(SIGUSR1);
+		return 1;
+	}
+
+	if (do_waitid(P_PID, pid, sinfo, WEXITED, rusage))
+		perror_msg_and_fail("waitid #4");
+	tprintf("waitid(P_PID, %d, %s, WEXITED, %s) = 0\n",
+		pid, sprint_siginfo(sinfo, "SIGUSR1"), sprint_rusage(rusage));
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+	pid = fork();
+	if (pid < 0)
+		perror_msg_and_fail("fork");
+
+	if (!pid) {
+		(void) close(1);
+		raise(SIGSTOP);
+		char c;
+		assert(read(0, &c, sizeof(c)) == 1);
+		return 0;
+	}
+
+	(void) close(0);
+
+	if (do_waitid(P_PID, pid, sinfo, WSTOPPED, rusage))
+		perror_msg_and_fail("waitid #5");
+	tprintf("waitid(P_PID, %d, %s, WSTOPPED, %s) = 0\n",
+		pid, sprint_siginfo(sinfo, "SIGSTOP"), sprint_rusage(rusage));
+
+	if (kill(pid, SIGCONT))
+		perror_msg_and_fail("kill(SIGCONT)");
+
+#if defined WCONTINUED
+	if (do_waitid(P_PID, pid, sinfo, WCONTINUED, rusage))
+		perror_msg_and_fail("waitid #6");
+	tprintf("waitid(P_PID, %d, %s, WCONTINUED, %s) = 0\n",
+		pid, sprint_siginfo(sinfo, "SIGCONT"), sprint_rusage(rusage));
+#endif /* WCONTINUED */
+
+	assert(write(1, "", 1) == 1);
+	(void) close(1);
+
+	if (do_waitid(P_PID, pid, sinfo, WEXITED, rusage))
+		perror_msg_and_fail("waitid #7");
+	tprintf("waitid(P_PID, %d, %s, WEXITED, %s) = 0\n",
+		pid, sprint_siginfo(sinfo, "0"), sprint_rusage(rusage));
+
+	long rc = do_waitid(P_ALL, -1, sinfo, WEXITED|WSTOPPED, rusage);
+	tprintf("waitid(P_ALL, -1, %p, WEXITED|WSTOPPED, %p)"
+		" = %ld %s (%m)\n", sinfo, rusage, rc, errno2name());
+
+	tprintf("%s\n", "+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/waitid.test b/strace/tests/waitid.test
new file mode 100755
index 0000000..3bcba3a
--- /dev/null
+++ b/strace/tests/waitid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of waitid syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -esignal=none
diff --git a/strace/tests/waitpid.c b/strace/tests/waitpid.c
new file mode 100644
index 0000000..c6f0ad4
--- /dev/null
+++ b/strace/tests/waitpid.c
@@ -0,0 +1,56 @@
+/*
+ * Check decoding of waitpid syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#ifdef __NR_waitpid
+
+# include <stdio.h>
+# include <unistd.h>
+# include <sys/wait.h>
+
+int
+main(void)
+{
+	unsigned long pid =
+		(unsigned long) 0xdefaced00000000 | (unsigned) getpid();
+	long rc = syscall(__NR_waitpid, pid, 0L, (unsigned long) WNOHANG);
+	printf("waitpid(%d, NULL, WNOHANG) = %ld %s (%m)\n",
+	       (int) pid, rc, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_waitpid")
+
+#endif
diff --git a/strace/tests/waitpid.test b/strace/tests/waitpid.test
new file mode 100755
index 0000000..93807d1
--- /dev/null
+++ b/strace/tests/waitpid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check decoding of waitpid syscall.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a28
diff --git a/strace/tests/xattr.c b/strace/tests/xattr.c
new file mode 100644
index 0000000..e72436c
--- /dev/null
+++ b/strace/tests/xattr.c
@@ -0,0 +1,148 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+
+#ifdef HAVE_SYS_XATTR_H
+
+# include <assert.h>
+# include <stdio.h>
+# include <sys/xattr.h>
+
+# ifndef XATTR_SIZE_MAX
+#  define XATTR_SIZE_MAX 65536
+# endif
+
+int
+main(void)
+{
+	static const char name[] = "strace.test";
+	static const char c_value[] = "foo\0bar";
+	static const char q_value[] = "foo\\0bar";
+
+	const char *const z_value = tail_memdup(c_value, sizeof(c_value));
+	char *const efault = tail_alloc(1) + 1;
+	const char *const value = tail_memdup(c_value, sizeof(c_value) - 1);
+	char *const big = tail_alloc(XATTR_SIZE_MAX + 1);
+
+	assert(fsetxattr(-1, 0, 0, 0, XATTR_CREATE) == -1);
+	printf("fsetxattr(-1, NULL, NULL, 0, XATTR_CREATE) = -1 %s (%m)\n",
+	       errno2name());
+
+	assert(fsetxattr(-1, 0, z_value, 0, XATTR_CREATE) == -1);
+	printf("fsetxattr(-1, NULL, \"\", 0, XATTR_CREATE) = -1 %s (%m)\n",
+	       errno2name());
+
+	assert(fsetxattr(-1, name, big, XATTR_SIZE_MAX + 1, XATTR_CREATE) == -1);
+	printf("fsetxattr(-1, \"%s\", %p, %u, XATTR_CREATE)"
+	       " = -1 %s (%m)\n",
+	       name, big, XATTR_SIZE_MAX + 1, errno2name());
+
+	assert(fsetxattr(-1, name, value, sizeof(c_value), XATTR_CREATE) == -1);
+	printf("fsetxattr(-1, \"%s\", %p, %u, XATTR_CREATE)"
+	       " = -1 %s (%m)\n",
+	       name, value, (unsigned) sizeof(c_value), errno2name());
+
+	assert(fsetxattr(-1, name, z_value, sizeof(c_value), XATTR_REPLACE) == -1);
+	printf("fsetxattr(-1, \"%s\", \"%s\", %u, XATTR_REPLACE)"
+	       " = -1 %s (%m)\n",
+	       name, q_value, (unsigned) sizeof(c_value), errno2name());
+
+	assert(fsetxattr(-1, name, value, sizeof(c_value) - 1, XATTR_CREATE|XATTR_REPLACE) == -1);
+	printf("fsetxattr(-1, \"%s\", \"%s\", %u, XATTR_CREATE|XATTR_REPLACE)"
+	       " = -1 %s (%m)\n",
+	       name, q_value, (unsigned) sizeof(c_value) - 1, errno2name());
+
+	assert(setxattr(".", name, z_value, sizeof(c_value), XATTR_CREATE) == -1);
+	printf("setxattr(\".\", \"%s\", \"%s\", %u, XATTR_CREATE)"
+	       " = -1 %s (%m)\n",
+	       name, q_value, (unsigned) sizeof(c_value), errno2name());
+
+	assert(lsetxattr(".", name, value, sizeof(c_value) - 1, XATTR_CREATE) == -1);
+	printf("lsetxattr(\".\", \"%s\", \"%s\", %u, XATTR_CREATE)"
+	       " = -1 %s (%m)\n",
+	       name, q_value, (unsigned) sizeof(c_value) - 1, errno2name());
+
+	assert(fgetxattr(-1, name, efault, 4) == -1);
+	printf("fgetxattr(-1, \"%s\", %p, 4) = -1 %s (%m)\n",
+	       name, efault, errno2name());
+
+	assert(getxattr(".", name, big, XATTR_SIZE_MAX + 1) == -1);
+	printf("getxattr(\".\", \"%s\", %p, %u) = -1 %s (%m)\n",
+	       name, big, XATTR_SIZE_MAX + 1, errno2name());
+
+	assert(lgetxattr(".", name, big + 1, XATTR_SIZE_MAX) == -1);
+	printf("lgetxattr(\".\", \"%s\", %p, %u) = -1 %s (%m)\n",
+	       name, big + 1, XATTR_SIZE_MAX, errno2name());
+
+	assert(flistxattr(-1, efault, 4) == -1);
+	printf("flistxattr(-1, %p, 4) = -1 %s (%m)\n",
+	       efault, errno2name());
+
+	assert(llistxattr("", efault + 1, 4) == -1);
+	printf("llistxattr(\"\", %p, 4) = -1 %s (%m)\n",
+	       efault + 1, errno2name());
+
+	ssize_t rc = listxattr(".", big, 0);
+	if (rc < 0)
+		printf("listxattr(\".\", %p, 0) = -1 %s (%m)\n",
+		       big, errno2name());
+	else
+		printf("listxattr(\".\", %p, 0) = %ld\n",
+		       big, (long) rc);
+
+	rc = listxattr(".", big, XATTR_SIZE_MAX + 1);
+	if (rc < 0)
+		printf("listxattr(\".\", %p, %u) = -1 %s (%m)\n",
+		       big, XATTR_SIZE_MAX + 1, errno2name());
+	else {
+		printf("listxattr(\".\", \"");
+		print_quoted_memory(big, rc);
+		printf("\", %u) = %ld\n", XATTR_SIZE_MAX + 1, (long) rc);
+	}
+
+	assert(fremovexattr(-1, name) == -1);
+	printf("fremovexattr(-1, \"%s\") = -1 %s (%m)\n",
+	       name, errno2name());
+
+	assert(removexattr(".", name) == -1);
+	printf("removexattr(\".\", \"%s\") = -1 %s (%m)\n",
+	       name, errno2name());
+
+	assert(lremovexattr(".", name) == -1);
+	printf("lremovexattr(\".\", \"%s\") = -1 %s (%m)\n",
+	       name, errno2name());
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_SYS_XATTR_H")
+
+#endif
diff --git a/strace/tests/xattr.test b/strace/tests/xattr.test
new file mode 100755
index 0000000..8c7a87b
--- /dev/null
+++ b/strace/tests/xattr.test
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Check *xattr syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+
+syscalls=
+for n in getxattr setxattr listxattr removexattr; do
+	syscalls="$syscalls,${n},f${n},l${n}"
+done
+
+run_strace_match_diff -a22 -e trace=$syscalls
diff --git a/strace/tests/xchownx.c b/strace/tests/xchownx.c
new file mode 100644
index 0000000..b065675
--- /dev/null
+++ b/strace/tests/xchownx.c
@@ -0,0 +1,171 @@
+/*
+ * Check decoding of chown/chown32/lchown/lchown32/fchown/fchown32 syscalls.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <errno.h>
+#include <fcntl.h>
+#include <stdio.h>
+#include <unistd.h>
+
+#ifdef UGID_TYPE_IS_SHORT
+# define UGID_TYPE	short
+# define GETEUID	syscall(__NR_geteuid)
+# define GETEGID	syscall(__NR_getegid)
+# define CHECK_OVERFLOWUID(arg)	check_overflowuid(arg)
+# define CHECK_OVERFLOWGID(arg)	check_overflowgid(arg)
+#else
+# define UGID_TYPE	int
+# define GETEUID	geteuid()
+# define GETEGID	getegid()
+# define CHECK_OVERFLOWUID(arg)
+# define CHECK_OVERFLOWGID(arg)
+#endif
+
+#define UNLINK_SAMPLE \
+	if (unlink(sample)) perror_msg_and_fail("unlink")
+#define CLOSE_SAMPLE \
+	if (close(fd)) perror_msg_and_fail("close")
+
+#ifdef ACCESS_BY_DESCRIPTOR
+# define SYSCALL_ARG1 fd
+# define FMT_ARG1 "%d"
+# define EOK_CMD CLOSE_SAMPLE
+# define CLEANUP_CMD UNLINK_SAMPLE
+#else
+# define SYSCALL_ARG1 sample
+# define FMT_ARG1 "\"%s\""
+# define EOK_CMD UNLINK_SAMPLE
+# define CLEANUP_CMD CLOSE_SAMPLE
+#endif
+
+static int
+ugid2int(const unsigned UGID_TYPE id)
+{
+	if ((unsigned UGID_TYPE) -1U == id)
+		return -1;
+	else
+		return id;
+}
+
+static void
+print_int(const unsigned int num)
+{
+	if (num == -1U)
+		printf(", -1");
+	else
+		printf(", %u", num);
+}
+
+static int
+num_matches_id(const unsigned int num, const unsigned int id)
+{
+	return num == id || num == -1U;
+}
+
+#define PAIR(val)	{ val, gid }, { uid, val }
+
+int
+main(void)
+{
+	static const char sample[] = SYSCALL_NAME "_sample";
+
+	unsigned int uid = GETEUID;
+	CHECK_OVERFLOWUID(uid);
+	unsigned int gid = GETEGID;
+	CHECK_OVERFLOWUID(gid);
+
+	const struct {
+		const long uid, gid;
+	} tests[] = {
+		{ uid, gid },
+		{ (unsigned long) 0xffffffff00000000ULL | uid, gid },
+		{ uid, (unsigned long) 0xffffffff00000000ULL | gid },
+		PAIR(-1U),
+		PAIR(-1L),
+		{ 0xffff0000U | uid, gid },
+		{ uid, 0xffff0000U | gid },
+		PAIR(0xffff),
+		PAIR(0xc0deffffU),
+		PAIR(0xfacefeedU),
+		PAIR((long) 0xfacefeeddeadbeefULL)
+	};
+
+	int fd = open(sample, O_RDONLY | O_CREAT, 0400);
+	if (fd < 0)
+		perror_msg_and_fail("open");
+
+	CLEANUP_CMD;
+
+	unsigned int i;
+	long expected = 0;
+
+	for (i = 0; i < ARRAY_SIZE(tests); ++i) {
+		const unsigned int unum = ugid2int(tests[i].uid);
+		const unsigned int gnum = ugid2int(tests[i].gid);
+
+		if (num_matches_id(unum, uid) &&
+		    num_matches_id(gnum, gid)) {
+			if (expected)
+				continue;
+		} else {
+			if (!expected) {
+				expected = -1;
+				EOK_CMD;
+			}
+		}
+
+		const long rc = syscall(SYSCALL_NR, SYSCALL_ARG1,
+					tests[i].uid, tests[i].gid);
+		int saved_errno = errno;
+		if (rc != expected) {
+			if (!i && ENOSYS == errno) {
+				printf("%s(" FMT_ARG1 ", %u, %u)"
+				       " = -1 ENOSYS (%m)\n",
+				       SYSCALL_NAME, SYSCALL_ARG1, uid, gid);
+				break;
+			}
+			perror_msg_and_fail("%s(" FMT_ARG1
+					    ", %#lx, %#lx) != %ld",
+					    SYSCALL_NAME, SYSCALL_ARG1,
+					    tests[i].uid, tests[i].gid,
+					    expected);
+		}
+
+		printf("%s(" FMT_ARG1, SYSCALL_NAME, SYSCALL_ARG1);
+		print_int(unum);
+		print_int(gnum);
+		errno = saved_errno;
+		if (expected)
+			printf(") = %ld %s (%m)\n", expected, errno2name());
+		else
+			printf(") = 0\n");
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/xet_robust_list.c b/strace/tests/xet_robust_list.c
new file mode 100644
index 0000000..eef31dc
--- /dev/null
+++ b/strace/tests/xet_robust_list.c
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_get_robust_list && defined __NR_set_robust_list
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const pid_t pid = getpid();
+	const long long_pid = (unsigned long) (0xdeadbeef00000000LL | pid);
+	void **p_head = tail_alloc(sizeof(void *));
+	size_t *p_len = tail_alloc(sizeof(size_t));
+
+	if (syscall(__NR_get_robust_list, long_pid, p_head, p_len))
+		perror_msg_and_skip("get_robust_list");
+	printf("get_robust_list(%d, [%#lx], [%lu]) = 0\n",
+	       (int) pid, (unsigned long) *p_head, (unsigned long) *p_len);
+
+	void *head = tail_alloc(*p_len);
+	if (syscall(__NR_set_robust_list, head, *p_len))
+		perror_msg_and_skip("set_robust_list");
+	printf("set_robust_list(%p, %lu) = 0\n",
+	       head, (unsigned long) *p_len);
+
+	if (syscall(__NR_get_robust_list, long_pid, p_head, p_len))
+		perror_msg_and_skip("get_robust_list");
+	printf("get_robust_list(%d, [%#lx], [%lu]) = 0\n",
+	       (int) pid, (unsigned long) *p_head, (unsigned long) *p_len);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_get_robust_list && __NR_set_robust_list")
+
+#endif
diff --git a/strace/tests/xet_robust_list.test b/strace/tests/xet_robust_list.test
new file mode 100755
index 0000000..8a3a382
--- /dev/null
+++ b/strace/tests/xet_robust_list.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check get_robust_list and set_robust_list syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a24 -e trace=get_robust_list,set_robust_list
diff --git a/strace/tests/xetitimer.c b/strace/tests/xetitimer.c
new file mode 100644
index 0000000..9c9fd99
--- /dev/null
+++ b/strace/tests/xetitimer.c
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <stdio.h>
+#include <stdint.h>
+#include <sys/time.h>
+
+int
+main(void)
+{
+	struct {
+		struct itimerval itv;
+		uint32_t pad[4];
+	} old = {
+		.pad = { 0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded }
+	}, new = {
+		.itv = {
+			.it_interval = { 0xc0de1, 0xc0de2 },
+			.it_value = { 0xc0de3, 0xc0de4 }
+		},
+		.pad = { 0xdeadbeef, 0xbadc0ded, 0xdeadbeef, 0xbadc0ded }
+	};
+
+	if (setitimer(ITIMER_REAL, &new.itv, &old.itv))
+		perror_msg_and_skip("setitimer");
+	printf("setitimer(ITIMER_REAL"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ") = 0\n",
+	       (intmax_t) new.itv.it_interval.tv_sec,
+	       (intmax_t) new.itv.it_interval.tv_usec,
+	       (intmax_t) new.itv.it_value.tv_sec,
+	       (intmax_t) new.itv.it_value.tv_usec,
+	       (intmax_t) old.itv.it_interval.tv_sec,
+	       (intmax_t) old.itv.it_interval.tv_usec,
+	       (intmax_t) old.itv.it_value.tv_sec,
+	       (intmax_t) old.itv.it_value.tv_usec);
+
+	if (getitimer(ITIMER_REAL, &old.itv))
+		perror_msg_and_skip("getitimer");
+	printf("getitimer(ITIMER_REAL"
+	       ", {it_interval={%jd, %jd}, it_value={%jd, %jd}}"
+	       ") = 0\n",
+	       (intmax_t) old.itv.it_interval.tv_sec,
+	       (intmax_t) old.itv.it_interval.tv_usec,
+	       (intmax_t) old.itv.it_value.tv_sec,
+	       (intmax_t) old.itv.it_value.tv_usec);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/xetitimer.test b/strace/tests/xetitimer.test
new file mode 100755
index 0000000..4aa00cc
--- /dev/null
+++ b/strace/tests/xetitimer.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check setitimer and getitimer syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -e trace=setitimer,getitimer
diff --git a/strace/tests/xetpgid.c b/strace/tests/xetpgid.c
new file mode 100644
index 0000000..6ce79c1
--- /dev/null
+++ b/strace/tests/xetpgid.c
@@ -0,0 +1,59 @@
+/*
+ * This file is part of xetpgid strace test.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_getpgid && defined __NR_setpgid
+
+# include <stdio.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const int pid = getpid();
+	long rc = syscall(__NR_getpgid,
+			  (unsigned long) 0xffffffff00000000 | pid);
+	printf("getpgid(%d) = %ld\n", pid, rc);
+
+	rc = syscall(__NR_setpgid,
+		     (unsigned long) 0xffffffff00000000,
+		     (unsigned long) 0xffffffff00000000 | pid);
+	printf("setpgid(0, %d) = %ld\n", pid, rc);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getpgid && __NR_setpgid")
+
+#endif
diff --git a/strace/tests/xetpgid.test b/strace/tests/xetpgid.test
new file mode 100755
index 0000000..07f4f9e
--- /dev/null
+++ b/strace/tests/xetpgid.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getpgid and setpgid syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a11 -e trace=getpgid,setpgid
diff --git a/strace/tests/xetpriority.c b/strace/tests/xetpriority.c
new file mode 100644
index 0000000..a32b031
--- /dev/null
+++ b/strace/tests/xetpriority.c
@@ -0,0 +1,35 @@
+#include "tests.h"
+#include <sys/syscall.h>
+
+#if defined __NR_getpriority && defined __NR_setpriority
+
+# include <stdio.h>
+# include <sys/resource.h>
+# include <unistd.h>
+
+int
+main(void)
+{
+	const int pid = getpid();
+	long rc = syscall(__NR_getpriority, PRIO_PROCESS,
+			  (unsigned long) 0xffffffff00000000 | pid);
+	printf("getpriority(PRIO_PROCESS, %d) = %ld\n", pid, rc);
+
+	rc = syscall(__NR_setpriority, PRIO_PROCESS,
+		     (unsigned long) 0xffffffff00000000 | pid,
+		     (unsigned long) 0xffffffff00000000);
+	if (rc)
+		printf("setpriority(PRIO_PROCESS, %d, 0) = %ld %s (%m)\n",
+		       pid, rc, errno2name());
+	else
+		printf("setpriority(PRIO_PROCESS, %d, 0) = 0\n", pid);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("__NR_getpriority && _NR_setpriority")
+
+#endif
diff --git a/strace/tests/xetpriority.test b/strace/tests/xetpriority.test
new file mode 100755
index 0000000..2c84ba4
--- /dev/null
+++ b/strace/tests/xetpriority.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check getpriority and setpriority syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a29 -e trace=getpriority,setpriority
diff --git a/strace/tests/xettimeofday.c b/strace/tests/xettimeofday.c
new file mode 100644
index 0000000..ae28e02
--- /dev/null
+++ b/strace/tests/xettimeofday.c
@@ -0,0 +1,72 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 "tests.h"
+#include <assert.h>
+#include <stdio.h>
+#include <stdint.h>
+#include <unistd.h>
+#include <sys/time.h>
+#include <sys/syscall.h>
+
+int
+main(void)
+{
+	struct {
+		struct timeval tv;
+		uint32_t pad0[2];
+		struct timezone tz;
+		uint32_t pad1[2];
+	} t = {
+		.pad0 = { 0xdeadbeef, 0xbadc0ded },
+		.pad1 = { 0xdeadbeef, 0xbadc0ded }
+	};
+
+	if (syscall(__NR_gettimeofday, &t.tv, NULL))
+		perror_msg_and_skip("gettimeofday");
+	printf("gettimeofday({%jd, %jd}, NULL) = 0\n",
+	       (intmax_t) t.tv.tv_sec, (intmax_t) t.tv.tv_usec);
+
+	if (syscall(__NR_gettimeofday, &t.tv, &t.tz))
+		perror_msg_and_skip("gettimeofday");
+	printf("gettimeofday({%jd, %jd}"
+	       ", {tz_minuteswest=%d, tz_dsttime=%d}) = 0\n",
+	       (intmax_t) t.tv.tv_sec, (intmax_t) t.tv.tv_usec,
+	       t.tz.tz_minuteswest, t.tz.tz_dsttime);
+
+	t.tv.tv_sec = -1;
+	t.tv.tv_usec = 1000000000;
+	assert(syscall(__NR_settimeofday, &t.tv, &t.tz) == -1);
+	printf("settimeofday({%jd, %jd}"
+	       ", {tz_minuteswest=%d, tz_dsttime=%d})"
+	       " = -1 EINVAL (%m)\n",
+	       (intmax_t) t.tv.tv_sec, (intmax_t) t.tv.tv_usec,
+	       t.tz.tz_minuteswest, t.tz.tz_dsttime);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/xettimeofday.test b/strace/tests/xettimeofday.test
new file mode 100755
index 0000000..68764e4
--- /dev/null
+++ b/strace/tests/xettimeofday.test
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Check gettimeofday and settimeofday syscalls decoding.
+
+. "${srcdir=.}/init.sh"
+run_strace_match_diff -a20 -e trace=gettimeofday,settimeofday
diff --git a/strace/tests/xgetrlimit.c b/strace/tests/xgetrlimit.c
new file mode 100644
index 0000000..d787ce3
--- /dev/null
+++ b/strace/tests/xgetrlimit.c
@@ -0,0 +1,92 @@
+/*
+ * Check decoding of getrlimit/ugetrlimit syscall.
+ *
+ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <errno.h>
+#include <stdint.h>
+#include <stdio.h>
+#include <sys/resource.h>
+#include <unistd.h>
+
+#include "kernel_types.h"
+#include "xlat.h"
+#include "xlat/resources.h"
+
+const char *
+sprint_rlim(kernel_ulong_t lim)
+{
+	if (sizeof(lim) == sizeof(uint64_t)) {
+		if (lim == (kernel_ulong_t) -1ULL)
+			return "RLIM64_INFINITY";
+	} else {
+		if (lim == (kernel_ulong_t) -1U)
+			return "RLIM_INFINITY";
+	}
+
+	static char buf[2][sizeof(lim)*3 + sizeof("*1024")];
+	static int i;
+	i &= 1;
+	if (lim > 1024 && lim % 1024 == 0)
+		sprintf(buf[i], "%llu*1024", (unsigned long long) lim / 1024);
+	else
+		sprintf(buf[i], "%llu", (unsigned long long) lim);
+
+	return buf[i++];
+}
+
+#ifdef NR_GETRLIMIT
+
+int
+main(void)
+{
+	kernel_ulong_t *const rlimit = tail_alloc(sizeof(*rlimit) * 2);
+	const struct xlat *xlat;
+
+	for (xlat = resources; xlat->str; ++xlat) {
+		unsigned long res = 0xfacefeed00000000 | xlat->val;
+		long rc = syscall(NR_GETRLIMIT, res, 0);
+		if (rc && ENOSYS == errno)
+			perror_msg_and_skip(STR_GETRLIMIT);
+		printf("%s(%s, NULL) = %ld %s (%m)\n",
+		       STR_GETRLIMIT, xlat->str, rc, errno2name());
+
+		rc = syscall(NR_GETRLIMIT, res, rlimit);
+		if (rc)
+			printf("%s(%s, NULL) = %ld %s (%m)\n",
+			       STR_GETRLIMIT, xlat->str, rc, errno2name());
+		else
+			printf("%s(%s, {rlim_cur=%s, rlim_max=%s})"
+			       " = 0\n", STR_GETRLIMIT, xlat->str,
+			       sprint_rlim(rlimit[0]), sprint_rlim(rlimit[1]));
+	}
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#endif /* NR_GETRLIMIT */
diff --git a/strace/tests/xselect.c b/strace/tests/xselect.c
new file mode 100644
index 0000000..08e29e1
--- /dev/null
+++ b/strace/tests/xselect.c
@@ -0,0 +1,105 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+/*
+ * Based on test by Dr. David Alan Gilbert <dave@treblig.org>
+ */
+
+#include <assert.h>
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/select.h>
+
+static fd_set set[0x1000000 / sizeof(fd_set)];
+
+int main(void)
+{
+	int fds[2];
+	struct {
+		struct timeval tv;
+		int pad[2];
+	} tm_in = {
+		.tv = { .tv_sec = 0xc0de1, .tv_usec = 0xc0de2 },
+		.pad = { 0xdeadbeef, 0xbadc0ded }
+	}, tm = tm_in;
+
+	if (pipe(fds))
+		perror_msg_and_fail("pipe");
+
+	/*
+	 * Start with a nice simple select.
+	 */
+	FD_ZERO(set);
+	FD_SET(fds[0], set);
+	FD_SET(fds[1], set);
+	int rc = syscall(TEST_SYSCALL_NR, fds[1] + 1, set, set, set, NULL);
+	if (rc < 0)
+		perror_msg_and_skip(TEST_SYSCALL_STR);
+	assert(rc == 1);
+	printf("%s(%d, [%d %d], [%d %d], [%d %d], NULL) = 1 ()\n",
+	       TEST_SYSCALL_STR, fds[1] + 1, fds[0], fds[1],
+	       fds[0], fds[1], fds[0], fds[1]);
+
+	/*
+	 * Another simple one, with a timeout.
+	 */
+	FD_SET(1, set);
+	FD_SET(2, set);
+	FD_SET(fds[0], set);
+	FD_SET(fds[1], set);
+	assert(syscall(TEST_SYSCALL_NR, fds[1] + 1, NULL, set, NULL, &tm.tv) == 3);
+	printf("%s(%d, NULL, [1 2 %d %d], NULL, {%lld, %lld})"
+	       " = 3 (out [1 2 %d], left {%lld, %lld})\n",
+	       TEST_SYSCALL_STR, fds[1] + 1, fds[0], fds[1],
+	       (long long) tm_in.tv.tv_sec, (long long) tm_in.tv.tv_usec,
+	       fds[1],
+	       (long long) tm.tv.tv_sec, (long long) tm.tv.tv_usec);
+
+	/*
+	 * Now the crash case that trinity found, negative nfds
+	 * but with a pointer to a large chunk of valid memory.
+	 */
+	FD_ZERO(set);
+	FD_SET(fds[1],set);
+	assert(syscall(TEST_SYSCALL_NR, -1, NULL, set, NULL, NULL) == -1);
+	printf("%s(-1, NULL, %p, NULL, NULL) = -1 EINVAL (%m)\n",
+	       TEST_SYSCALL_STR, set);
+
+	/*
+	 * Another variant, with nfds exceeding FD_SETSIZE limit.
+	 */
+	FD_ZERO(set);
+	FD_SET(fds[0],set);
+	tm.tv.tv_sec = 0;
+	tm.tv.tv_usec = 123;
+	assert(syscall(TEST_SYSCALL_NR, FD_SETSIZE + 1, set, set + 1, NULL, &tm.tv) == 0);
+	printf("%s(%d, [%d], [], NULL, {0, 123}) = 0 (Timeout)\n",
+	       TEST_SYSCALL_STR, FD_SETSIZE + 1, fds[0]);
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/xstatfs.c b/strace/tests/xstatfs.c
new file mode 100644
index 0000000..26c43de
--- /dev/null
+++ b/strace/tests/xstatfs.c
@@ -0,0 +1,46 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define SYSCALL_INVOKE(file, desc, ptr, size) \
+	syscall(SYSCALL_NR, SYSCALL_ARG(file, desc), ptr)
+#define PRINT_SYSCALL_HEADER(file, desc, size) \
+	printf("%s(" SYSCALL_ARG_FMT ", ", SYSCALL_NAME, SYSCALL_ARG(file, desc))
+
+#define STRUCT_STATFS	struct statfs
+#ifdef HAVE_STRUCT_STATFS_F_FRSIZE
+# define PRINT_F_FRSIZE
+#endif
+#ifdef HAVE_STRUCT_STATFS_F_FLAGS
+# define PRINT_F_FLAGS
+#endif
+#if defined HAVE_STRUCT_STATFS_F_FSID_VAL
+# define PRINT_F_FSID	f_fsid.val
+#elif defined HAVE_STRUCT_STATFS_F_FSID___VAL
+# define PRINT_F_FSID	f_fsid.__val
+#endif
+
+#include "xstatfsx.c"
diff --git a/strace/tests/xstatfs64.c b/strace/tests/xstatfs64.c
new file mode 100644
index 0000000..8f50de2
--- /dev/null
+++ b/strace/tests/xstatfs64.c
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#define SYSCALL_INVOKE(file, desc, ptr, size) \
+	syscall(SYSCALL_NR, SYSCALL_ARG(file, desc), size, ptr)
+#define PRINT_SYSCALL_HEADER(file, desc, size) \
+	printf("%s(" SYSCALL_ARG_FMT ", %u, ", SYSCALL_NAME, \
+	       SYSCALL_ARG(file, desc), (unsigned) size)
+
+#define STRUCT_STATFS	struct statfs64
+#ifdef HAVE_STRUCT_STATFS64_F_FRSIZE
+# define PRINT_F_FRSIZE
+#endif
+#ifdef HAVE_STRUCT_STATFS64_F_FLAGS
+# define PRINT_F_FLAGS
+#endif
+#if defined HAVE_STRUCT_STATFS64_F_FSID_VAL
+# define PRINT_F_FSID	f_fsid.val
+#elif defined HAVE_STRUCT_STATFS64_F_FSID___VAL
+# define PRINT_F_FSID	f_fsid.__val
+#endif
+#define CHECK_ODD_SIZE
+
+#include "xstatfsx.c"
diff --git a/strace/tests/xstatfsx.c b/strace/tests/xstatfsx.c
new file mode 100644
index 0000000..3561866
--- /dev/null
+++ b/strace/tests/xstatfsx.c
@@ -0,0 +1,120 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <stdio.h>
+#include <fcntl.h>
+#include <unistd.h>
+
+#include <linux/types.h>
+#include <asm/statfs.h>
+
+#include "xlat.h"
+#include "xlat/fsmagic.h"
+#include "xlat/statfs_flags.h"
+
+#define PRINT_NUM(arg)							\
+	if (sizeof(b->arg) == sizeof(int))				\
+		printf(", %s=%u", #arg, (unsigned int) b->arg);		\
+	else if (sizeof(b->arg) == sizeof(long))				\
+		printf(", %s=%lu", #arg, (unsigned long) b->arg);	\
+	else								\
+		printf(", %s=%llu", #arg, (unsigned long long) b->arg)
+
+static void
+print_statfs_type(const char *const prefix, const unsigned int magic)
+{
+	fputs(prefix, stdout);
+	unsigned int i;
+	for (i = 0; i < ARRAY_SIZE(fsmagic); ++i)
+		if (magic == fsmagic[i].val) {
+			fputs(fsmagic[i].str, stdout);
+			return;
+		}
+	printf("%#x", magic);
+}
+
+static void
+print_statfs(const char *const sample, const char *magic_str)
+{
+	int fd = open(sample, O_RDONLY);
+	if (fd < 0)
+		perror_msg_and_fail("open: %s", sample);
+
+	STRUCT_STATFS *const b = tail_alloc(sizeof(*b));
+	long rc = SYSCALL_INVOKE(sample, fd, b, sizeof(*b));
+	if (rc)
+		perror_msg_and_skip(SYSCALL_NAME);
+
+	PRINT_SYSCALL_HEADER(sample, fd, sizeof(*b));
+	if (magic_str)
+		printf("{f_type=%s", magic_str);
+	else
+		print_statfs_type("{f_type=", b->f_type);
+	PRINT_NUM(f_bsize);
+	PRINT_NUM(f_blocks);
+	PRINT_NUM(f_bfree);
+	PRINT_NUM(f_bavail);
+	PRINT_NUM(f_files);
+	PRINT_NUM(f_ffree);
+#ifdef PRINT_F_FSID
+	printf(", f_fsid={%u, %u}",
+	       (unsigned) b->PRINT_F_FSID[0], (unsigned) b->PRINT_F_FSID[1]);
+#endif
+	PRINT_NUM(f_namelen);
+#ifdef PRINT_F_FRSIZE
+	PRINT_NUM(f_frsize);
+#endif
+#ifdef PRINT_F_FLAGS
+	if (b->f_flags & ST_VALID) {
+		printf(", f_flags=");
+		printflags(statfs_flags, b->f_flags, "ST_???");
+	}
+#endif
+	printf("}) = 0\n");
+}
+
+int
+main(void)
+{
+	print_statfs("/proc/self/status", "PROC_SUPER_MAGIC");
+
+	print_statfs(".", NULL);
+
+	long rc = SYSCALL_INVOKE("", -1, 0, sizeof(STRUCT_STATFS));
+	PRINT_SYSCALL_HEADER("", -1, sizeof(STRUCT_STATFS));
+	printf("NULL) = %ld %s (%m)\n", rc, errno2name());
+
+#ifdef CHECK_ODD_SIZE
+	const unsigned long addr = (unsigned long) 0xfacefeeddeadbeef;
+	rc = SYSCALL_INVOKE("", -1, addr, sizeof(STRUCT_STATFS) + 1);
+	PRINT_SYSCALL_HEADER("", -1, sizeof(STRUCT_STATFS) + 1);
+	printf("%#lx) = %ld %s (%m)\n", addr, rc, errno2name());
+#endif
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
diff --git a/strace/tests/xstatx.c b/strace/tests/xstatx.c
new file mode 100644
index 0000000..2883f16
--- /dev/null
+++ b/strace/tests/xstatx.c
@@ -0,0 +1,316 @@
+/*
+ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#if defined HAVE_FTRUNCATE && defined HAVE_FUTIMENS
+
+# ifndef TEST_SYSCALL_STR
+#  error TEST_SYSCALL_STR must be defined
+# endif
+# ifndef TEST_SYSCALL_INVOKE
+#  error TEST_SYSCALL_INVOKE must be defined
+# endif
+# ifndef PRINT_SYSCALL_HEADER
+#  error PRINT_SYSCALL_HEADER must be defined
+# endif
+# ifndef PRINT_SYSCALL_FOOTER
+#  error PRINT_SYSCALL_FOOTER must be defined
+# endif
+
+# include <stdio.h>
+# include <stddef.h>
+# include <time.h>
+# include <unistd.h>
+
+# if defined MAJOR_IN_SYSMACROS
+#  include <sys/sysmacros.h>
+# elif defined MAJOR_IN_MKDEV
+#  include <sys/mkdev.h>
+# else
+#  include <sys/types.h>
+# endif
+
+static void
+print_time(const time_t t)
+{
+	if (!t) {
+		printf("0");
+		return;
+	}
+
+	struct tm *p = localtime(&t);
+
+	if (p)
+		printf("%02d/%02d/%02d-%02d:%02d:%02d",
+		       p->tm_year + 1900, p->tm_mon + 1, p->tm_mday,
+		       p->tm_hour, p->tm_min, p->tm_sec);
+	else
+		printf("%llu", (unsigned long long) t);
+}
+
+typedef off_t libc_off_t;
+
+# ifdef USE_ASM_STAT
+#  define stat libc_stat
+#  define stat64 libc_stat64
+# endif
+# include <fcntl.h>
+# include <sys/stat.h>
+# ifdef USE_ASM_STAT
+#  undef stat
+#  undef stat64
+# endif
+
+# ifdef USE_ASM_STAT
+#  undef st_atime
+#  undef st_mtime
+#  undef st_ctime
+#  undef dev_t
+#  undef gid_t
+#  undef ino_t
+#  undef loff_t
+#  undef mode_t
+#  undef nlink_t
+#  undef off64_t
+#  undef off_t
+#  undef time_t
+#  undef uid_t
+#  define dev_t __kernel_dev_t
+#  define gid_t __kernel_gid_t
+#  define ino_t __kernel_ino_t
+#  define loff_t __kernel_loff_t
+#  define mode_t __kernel_mode_t
+#  define nlink_t __kernel_nlink_t
+#  define off64_t __kernel_off64_t
+#  define off_t __kernel_off_t
+#  define time_t __kernel_time_t
+#  define uid_t __kernel_uid_t
+#  include "asm_stat.h"
+# else
+#  undef HAVE_STRUCT_STAT_ST_ATIME_NSEC
+#  ifdef HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC
+#   define HAVE_STRUCT_STAT_ST_ATIME_NSEC 1
+#   undef st_atime_nsec
+#   define st_atime_nsec st_atim.tv_nsec
+#  endif
+#  undef HAVE_STRUCT_STAT_ST_MTIME_NSEC
+#  ifdef HAVE_STRUCT_STAT_ST_MTIM_TV_NSEC
+#   define HAVE_STRUCT_STAT_ST_MTIME_NSEC 1
+#   undef st_mtime_nsec
+#   define st_mtime_nsec st_mtim.tv_nsec
+#  endif
+#  undef HAVE_STRUCT_STAT_ST_CTIME_NSEC
+#  ifdef HAVE_STRUCT_STAT_ST_CTIM_TV_NSEC
+#   define HAVE_STRUCT_STAT_ST_CTIME_NSEC 1
+#   undef st_ctime_nsec
+#   define st_ctime_nsec st_ctim.tv_nsec
+#  endif
+# endif
+
+# ifndef STRUCT_STAT
+#  define STRUCT_STAT struct stat
+#  define STRUCT_STAT_STR "struct stat"
+# endif
+# ifndef SAMPLE_SIZE
+#  define SAMPLE_SIZE 43147718418
+# endif
+
+static void
+print_ftype(const unsigned int mode)
+{
+	if (S_ISREG(mode))
+		printf("S_IFREG");
+	else if (S_ISDIR(mode))
+		printf("S_IFDIR");
+	else if (S_ISCHR(mode))
+		printf("S_IFCHR");
+	else if (S_ISBLK(mode))
+		printf("S_IFBLK");
+	else
+		printf("%#o", mode & S_IFMT);
+}
+
+static void
+print_perms(const unsigned int mode)
+{
+	printf("%#o", mode & ~S_IFMT);
+}
+
+static void
+print_stat(const STRUCT_STAT *st)
+{
+	printf("{st_dev=makedev(%u, %u)",
+	       (unsigned int) major(st->st_dev),
+	       (unsigned int) minor(st->st_dev));
+	printf(", st_ino=%llu", (unsigned long long) st->st_ino);
+	printf(", st_mode=");
+	print_ftype(st->st_mode);
+	printf("|");
+	print_perms(st->st_mode);
+	printf(", st_nlink=%u", (unsigned int) st->st_nlink);
+	printf(", st_uid=%u", (unsigned int) st->st_uid);
+	printf(", st_gid=%u", (unsigned int) st->st_gid);
+	printf(", st_blksize=%u", (unsigned int) st->st_blksize);
+	printf(", st_blocks=%u", (unsigned int) st->st_blocks);
+
+	switch (st->st_mode & S_IFMT) {
+	case S_IFCHR: case S_IFBLK:
+		printf(", st_rdev=makedev(%u, %u)",
+		       (unsigned int) major(st->st_rdev),
+		       (unsigned int) minor(st->st_rdev));
+		break;
+	default:
+		printf(", st_size=%llu", (unsigned long long) st->st_size);
+	}
+
+	printf(", st_atime=");
+	print_time(st->st_atime);
+# ifdef HAVE_STRUCT_STAT_ST_ATIME_NSEC
+	if (st->st_atime_nsec)
+		printf(".%09lu", (unsigned long) st->st_atime_nsec);
+# endif
+	printf(", st_mtime=");
+	print_time(st->st_mtime);
+# ifdef HAVE_STRUCT_STAT_ST_MTIME_NSEC
+	if (st->st_mtime_nsec)
+		printf(".%09lu", (unsigned long) st->st_mtime_nsec);
+# endif
+	printf(", st_ctime=");
+	print_time(st->st_ctime);
+# ifdef HAVE_STRUCT_STAT_ST_CTIME_NSEC
+	if (st->st_ctime_nsec)
+		printf(".%09lu", (unsigned long) st->st_ctime_nsec);
+# endif
+	printf("}");
+}
+
+static int
+create_sample(const char *fname, const libc_off_t size)
+{
+	static const struct timespec ts[] = {
+		{-10843, 135}, {-10841, 246}
+	};
+
+	(void) close(0);
+	if (open(fname, O_RDWR | O_CREAT | O_TRUNC, 0640)) {
+		perror(fname);
+		return 77;
+	}
+	if (ftruncate(0, size)) {
+		perror("ftruncate");
+		return 77;
+	}
+	if (futimens(0, ts)) {
+		perror("futimens");
+		return 77;
+	}
+	return 0;
+}
+
+int
+main(void)
+{
+	static const char sample[] = TEST_SYSCALL_STR ".sample";
+	STRUCT_STAT st[2];
+
+	int rc = create_sample(sample, SAMPLE_SIZE);
+	if (rc) {
+		(void) unlink(sample);
+		return rc;
+	}
+
+	if (TEST_SYSCALL_INVOKE(sample, st)) {
+		perror(TEST_SYSCALL_STR);
+		(void) unlink(sample);
+		return 77;
+	}
+	(void) unlink(sample);
+	if ((unsigned long long) SAMPLE_SIZE !=
+	    (unsigned long long) st[0].st_size) {
+		fprintf(stderr, "Size mismatch: "
+				"requested size(%llu) != st_size(%llu)\n",
+			(unsigned long long) SAMPLE_SIZE,
+			(unsigned long long) st[0].st_size);
+		fprintf(stderr, "The most likely reason for this is incorrect"
+				" definition of %s.\n"
+				"Here is some diagnostics that might help:\n",
+			STRUCT_STAT_STR);
+		fprintf(stderr, "offsetof(%s, st_dev) = %zu"
+				", sizeof(st_dev) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_dev),
+			sizeof(st[0].st_dev));
+		fprintf(stderr, "offsetof(%s, st_ino) = %zu"
+				", sizeof(st_ino) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_ino),
+			sizeof(st[0].st_ino));
+		fprintf(stderr, "offsetof(%s, st_mode) = %zu"
+				", sizeof(st_mode) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_mode),
+			sizeof(st[0].st_mode));
+		fprintf(stderr, "offsetof(%s, st_nlink) = %zu"
+				", sizeof(st_nlink) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_nlink),
+			sizeof(st[0].st_nlink));
+		fprintf(stderr, "offsetof(%s, st_uid) = %zu"
+				", sizeof(st_uid) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_uid),
+			sizeof(st[0].st_uid));
+		fprintf(stderr, "offsetof(%s, st_gid) = %zu"
+				", sizeof(st_gid) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_gid),
+			sizeof(st[0].st_gid));
+		fprintf(stderr, "offsetof(%s, st_rdev) = %zu"
+				", sizeof(st_rdev) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_rdev),
+			sizeof(st[0].st_rdev));
+		fprintf(stderr, "offsetof(%s, st_size) = %zu"
+				", sizeof(st_size) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_size),
+			sizeof(st[0].st_size));
+		fprintf(stderr, "offsetof(%s, st_blksize) = %zu"
+				", sizeof(st_blksize) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_blksize),
+			sizeof(st[0].st_blksize));
+		fprintf(stderr, "offsetof(%s, st_blocks) = %zu"
+				", sizeof(st_blocks) = %zu\n",
+			STRUCT_STAT_STR, offsetof(STRUCT_STAT, st_blocks),
+			sizeof(st[0].st_blocks));
+		return 77;
+	}
+
+	PRINT_SYSCALL_HEADER(sample);
+	print_stat(st);
+	PRINT_SYSCALL_FOOTER;
+
+	puts("+++ exited with 0 +++");
+	return 0;
+}
+
+#else
+
+SKIP_MAIN_UNDEFINED("HAVE_FTRUNCATE && HAVE_FUTIMENS")
+
+#endif
diff --git a/strace/time.c b/strace/time.c
new file mode 100644
index 0000000..963d0ea
--- /dev/null
+++ b/strace/time.c
@@ -0,0 +1,337 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * 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 <fcntl.h>
+#include <signal.h>
+#include <sys/timex.h>
+
+static void
+print_timezone(struct tcb *tcp, const long addr)
+{
+	struct timezone tz;
+
+	if (umove_or_printaddr(tcp, addr, &tz))
+		return;
+
+	tprintf("{tz_minuteswest=%d, tz_dsttime=%d}",
+		tz.tz_minuteswest, tz.tz_dsttime);
+}
+
+SYS_FUNC(gettimeofday)
+{
+	if (exiting(tcp)) {
+		print_timeval(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		print_timezone(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_gettimeofday)
+{
+	if (exiting(tcp)) {
+		print_timeval32(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		print_timezone(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+#endif
+
+SYS_FUNC(settimeofday)
+{
+	print_timeval(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	print_timezone(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_settimeofday)
+{
+	print_timeval32(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	print_timezone(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+#endif
+
+SYS_FUNC(nanosleep)
+{
+	if (entering(tcp)) {
+		print_timespec(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+
+		/*
+		 * Second (returned) timespec is only significant if syscall
+		 * was interrupted.  On success and in case of other errors we
+		 * print only its address, since kernel doesn't modify it,
+		 * and printing the value may show uninitialized data.
+		 */
+		if (is_erestart(tcp)) {
+			temporarily_clear_syserror(tcp);
+			print_timespec(tcp, tcp->u_arg[1]);
+			restore_cleared_syserror(tcp);
+		} else {
+			printaddr(tcp->u_arg[1]);
+		}
+	}
+	return 0;
+}
+
+#include "xlat/itimer_which.h"
+
+SYS_FUNC(getitimer)
+{
+	if (entering(tcp)) {
+		printxval(itimer_which, tcp->u_arg[0], "ITIMER_???");
+		tprints(", ");
+	} else {
+		print_itimerval(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_getitimer)
+{
+	if (entering(tcp)) {
+		printxval(itimer_which, tcp->u_arg[0], "ITIMER_???");
+		tprints(", ");
+	} else {
+		print_itimerval32(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+#endif
+
+SYS_FUNC(setitimer)
+{
+	if (entering(tcp)) {
+		printxval(itimer_which, tcp->u_arg[0], "ITIMER_???");
+		tprints(", ");
+		print_itimerval(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+		print_itimerval(tcp, tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_setitimer)
+{
+	if (entering(tcp)) {
+		printxval(itimer_which, tcp->u_arg[0], "ITIMER_???");
+		tprints(", ");
+		print_itimerval32(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+		print_itimerval32(tcp, tcp->u_arg[2]);
+	}
+	return 0;
+}
+#endif
+
+#include "xlat/adjtimex_state.h"
+
+static int
+do_adjtimex(struct tcb *tcp, long addr)
+{
+	if (print_timex(tcp, addr))
+		return 0;
+	tcp->auxstr = xlookup(adjtimex_state, (unsigned long) tcp->u_rval);
+	if (tcp->auxstr)
+		return RVAL_STR;
+	return 0;
+}
+
+SYS_FUNC(adjtimex)
+{
+	if (exiting(tcp))
+		return do_adjtimex(tcp, tcp->u_arg[0]);
+	return 0;
+}
+
+#include "xlat/clockflags.h"
+#include "xlat/clocknames.h"
+
+static void
+printclockname(int clockid)
+{
+#ifdef CLOCKID_TO_FD
+# include "xlat/cpuclocknames.h"
+
+	if (clockid < 0) {
+		if ((clockid & CLOCKFD_MASK) == CLOCKFD)
+			tprintf("FD_TO_CLOCKID(%d)", CLOCKID_TO_FD(clockid));
+		else {
+			if(CPUCLOCK_PERTHREAD(clockid))
+				tprintf("MAKE_THREAD_CPUCLOCK(%d,", CPUCLOCK_PID(clockid));
+			else
+				tprintf("MAKE_PROCESS_CPUCLOCK(%d,", CPUCLOCK_PID(clockid));
+			printxval(cpuclocknames, clockid & CLOCKFD_MASK, "CPUCLOCK_???");
+			tprints(")");
+		}
+	}
+	else
+#endif
+		printxval(clocknames, clockid, "CLOCK_???");
+}
+
+SYS_FUNC(clock_settime)
+{
+	printclockname(tcp->u_arg[0]);
+	tprints(", ");
+	print_timespec(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(clock_gettime)
+{
+	if (entering(tcp)) {
+		printclockname(tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_timespec(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+SYS_FUNC(clock_nanosleep)
+{
+	if (entering(tcp)) {
+		printclockname(tcp->u_arg[0]);
+		tprints(", ");
+		printflags(clockflags, tcp->u_arg[1], "TIMER_???");
+		tprints(", ");
+		print_timespec(tcp, tcp->u_arg[2]);
+		tprints(", ");
+	} else {
+		/*
+		 * Second (returned) timespec is only significant
+		 * if syscall was interrupted and flags is not TIMER_ABSTIME.
+		 */
+		if (!tcp->u_arg[1] && is_erestart(tcp)) {
+			temporarily_clear_syserror(tcp);
+			print_timespec(tcp, tcp->u_arg[3]);
+			restore_cleared_syserror(tcp);
+		} else {
+			printaddr(tcp->u_arg[3]);
+		}
+	}
+	return 0;
+}
+
+SYS_FUNC(clock_adjtime)
+{
+	if (exiting(tcp))
+		return do_adjtimex(tcp, tcp->u_arg[1]);
+	printclockname(tcp->u_arg[0]);
+	tprints(", ");
+	return 0;
+}
+
+SYS_FUNC(timer_create)
+{
+	if (entering(tcp)) {
+		printclockname(tcp->u_arg[0]);
+		tprints(", ");
+		print_sigevent(tcp, tcp->u_arg[1]);
+		tprints(", ");
+	} else {
+		printnum_int(tcp, tcp->u_arg[2], "%d");
+	}
+	return 0;
+}
+
+SYS_FUNC(timer_settime)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+		printflags(clockflags, tcp->u_arg[1], "TIMER_???");
+		tprints(", ");
+		print_itimerspec(tcp, tcp->u_arg[2]);
+		tprints(", ");
+	} else {
+		print_itimerspec(tcp, tcp->u_arg[3]);
+	}
+	return 0;
+}
+
+SYS_FUNC(timer_gettime)
+{
+	if (entering(tcp)) {
+		tprintf("%d, ", (int) tcp->u_arg[0]);
+	} else {
+		print_itimerspec(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
+
+#include "xlat/timerfdflags.h"
+
+SYS_FUNC(timerfd_create)
+{
+	printclockname(tcp->u_arg[0]);
+	tprints(", ");
+	printflags(timerfdflags, tcp->u_arg[1], "TFD_???");
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+SYS_FUNC(timerfd_settime)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printflags(timerfdflags, tcp->u_arg[1], "TFD_???");
+	tprints(", ");
+	print_itimerspec(tcp, tcp->u_arg[2]);
+	tprints(", ");
+	print_itimerspec(tcp, tcp->u_arg[3]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(timerfd_gettime)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_itimerspec(tcp, tcp->u_arg[1]);
+	}
+	return 0;
+}
diff --git a/strace/times.c b/strace/times.c
new file mode 100644
index 0000000..04df462
--- /dev/null
+++ b/strace/times.c
@@ -0,0 +1,62 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2012 H.J. Lu <hongjiu.lu@intel.com>
+ * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 DEF_MPERS_TYPE(tms_t)
+#include <sys/times.h>
+typedef struct tms tms_t;
+#include MPERS_DEFS
+
+SYS_FUNC(times)
+{
+	tms_t tbuf;
+
+	if (entering(tcp))
+		return 0;
+
+	if (!umove_or_printaddr(tcp, tcp->u_arg[0], &tbuf)) {
+		tprintf("{tms_utime=%llu, tms_stime=%llu, ",
+			widen_to_ull(tbuf.tms_utime),
+			widen_to_ull(tbuf.tms_stime));
+		tprintf("tms_cutime=%llu, tms_cstime=%llu}",
+			widen_to_ull(tbuf.tms_cutime),
+			widen_to_ull(tbuf.tms_cstime));
+	}
+
+	return syserror(tcp) ? RVAL_DECIMAL :
+#if defined(RVAL_LUDECIMAL) && !defined(IN_MPERS)
+			       RVAL_LUDECIMAL;
+#else
+			       RVAL_UDECIMAL;
+#endif
+}
diff --git a/strace/travis-build.sh b/strace/travis-build.sh
new file mode 100755
index 0000000..e6da4bb
--- /dev/null
+++ b/strace/travis-build.sh
@@ -0,0 +1,32 @@
+#!/bin/sh -ex
+
+case "$CC" in
+	gcc)
+		ENABLE_GCC_WERROR=--enable-gcc-Werror
+		;;
+	clang-*)
+		# clang -mx32 fails with the following error:
+		# clang: error: clang frontend command failed with exit code 70 (use -v to see invocation)
+		export st_cv_mx32_runtime=no
+		;;
+esac
+
+case "${TARGET-}" in
+	x32)
+		CC="$CC -mx32"
+		;;
+	x86)
+		CC="$CC -m32"
+		export DISTCHECK_CONFIGURE_FLAGS='--build=i686-pc-linux-gnu'
+		;;
+esac
+
+$CC --version
+export CC_FOR_BUILD="$CC"
+
+./git-set-file-times
+./bootstrap
+./configure --enable-maintainer-mode ${ENABLE_GCC_WERROR-} ${DISTCHECK_CONFIGURE_FLAGS-}
+
+j=-j`getconf _NPROCESSORS_ONLN 2> /dev/null` || j=
+make -k $j distcheck VERBOSE=${VERBOSE-}
diff --git a/strace/travis-install.sh b/strace/travis-install.sh
new file mode 100755
index 0000000..567a49b
--- /dev/null
+++ b/strace/travis-install.sh
@@ -0,0 +1,30 @@
+#!/bin/sh -ex
+
+updated=
+apt_get_install()
+{
+	[ -n "$updated" ] || {
+		sudo apt-get -qq update
+		updated=1
+	}
+	sudo apt-get -qq --no-install-suggests --no-install-recommends \
+		install -y "$@"
+}
+
+case "$CC" in
+	gcc)
+		apt_get_install gcc-multilib
+		;;
+	clang-*)
+		apt_get_install gcc-multilib "$CC"
+		;;
+	musl-gcc)
+		sudo add-apt-repository ppa:bortis/musl -y
+		apt_get_install gcc-multilib musl-tools linux-musl-dev
+		;;
+esac
+
+if [ "${COVERAGE-}" = true ]; then
+	apt_get_install lcov
+	pip install --user codecov
+fi
diff --git a/strace/travis-success.sh b/strace/travis-success.sh
new file mode 100755
index 0000000..cb04d45
--- /dev/null
+++ b/strace/travis-success.sh
@@ -0,0 +1,12 @@
+#!/bin/sh -ex
+
+if [ "${COVERAGE-}" = true ]; then
+	set -- strace-*.tar.xz
+	tar -xf "$1"
+	dir="${1%.tar.xz}"
+	cd "$dir"
+	export CC_FOR_BUILD="$CC"
+	./configure --enable-code-coverage
+	make -k $j all check VERBOSE=${VERBOSE-}
+	codecov --gcov-args=-abcp ||:
+fi
diff --git a/strace/truncate.c b/strace/truncate.c
new file mode 100644
index 0000000..1428094
--- /dev/null
+++ b/strace/truncate.c
@@ -0,0 +1,33 @@
+#include "defs.h"
+
+SYS_FUNC(truncate)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprintf(", %lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(truncate64)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	printllval(tcp, ", %llu", 1);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(ftruncate)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprintf(", %lu", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(ftruncate64)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	printllval(tcp, ", %llu", 1);
+
+	return RVAL_DECODED;
+}
diff --git a/strace/ubi.c b/strace/ubi.c
new file mode 100644
index 0000000..dfac0be
--- /dev/null
+++ b/strace/ubi.c
@@ -0,0 +1,201 @@
+/*
+ * Copyright (c) 2012 Mike Frysinger <vapier@gentoo.org>
+ *
+ * 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 <linux/ioctl.h>
+
+/* The UBI api changes, so we have to keep a local copy */
+#include <linux/version.h>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 7, 0)
+# include "ubi-user.h"
+#else
+# include <mtd/ubi-user.h>
+#endif
+
+#include "xlat/ubi_volume_types.h"
+#include "xlat/ubi_volume_props.h"
+
+int
+ubi_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	if (!verbose(tcp))
+		return RVAL_DECODED;
+
+	switch (code) {
+	case UBI_IOCMKVOL:
+		if (entering(tcp)) {
+			struct ubi_mkvol_req mkvol;
+
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &mkvol))
+				break;
+
+			tprintf("{vol_id=%" PRIi32 ", alignment=%" PRIi32
+				", bytes=%" PRIi64 ", vol_type=", mkvol.vol_id,
+				mkvol.alignment, (int64_t)mkvol.bytes);
+			printxval(ubi_volume_types,
+				    (uint8_t) mkvol.vol_type, "UBI_???_VOLUME");
+			tprintf(", name_len=%" PRIi16 ", name=", mkvol.name_len);
+			if (print_quoted_string(mkvol.name,
+					CLAMP(mkvol.name_len, 0, UBI_MAX_VOLUME_NAME),
+					QUOTE_0_TERMINATED) > 0) {
+				tprints("...");
+			}
+			tprints("}");
+			return 1;
+		}
+		if (!syserror(tcp)) {
+			tprints(" => ");
+			printnum_int(tcp, arg, "%d");
+		}
+		break;
+
+	case UBI_IOCRSVOL: {
+		struct ubi_rsvol_req rsvol;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &rsvol))
+			break;
+
+		tprintf("{vol_id=%" PRIi32 ", bytes=%" PRIi64 "}",
+			rsvol.vol_id, (int64_t)rsvol.bytes);
+		break;
+	}
+
+	case UBI_IOCRNVOL: {
+		struct ubi_rnvol_req rnvol;
+		int c;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &rnvol))
+			break;
+
+		tprintf("{count=%" PRIi32 ", ents=[", rnvol.count);
+		for (c = 0; c < CLAMP(rnvol.count, 0, UBI_MAX_RNVOL); ++c) {
+			if (c)
+				tprints(", ");
+			tprintf("{vol_id=%" PRIi32 ", name_len=%" PRIi16
+				", name=", rnvol.ents[c].vol_id,
+				rnvol.ents[c].name_len);
+			if (print_quoted_string(rnvol.ents[c].name,
+					CLAMP(rnvol.ents[c].name_len, 0, UBI_MAX_VOLUME_NAME),
+					QUOTE_0_TERMINATED) > 0) {
+				tprints("...");
+			}
+			tprints("}");
+		}
+		tprints("]}");
+		break;
+	}
+
+	case UBI_IOCEBCH: {
+		struct ubi_leb_change_req leb;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &leb))
+			break;
+
+		tprintf("{lnum=%d, bytes=%d}", leb.lnum, leb.bytes);
+		break;
+	}
+
+	case UBI_IOCATT:
+		if (entering(tcp)) {
+			struct ubi_attach_req attach;
+
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &attach))
+				break;
+
+			tprintf("{ubi_num=%" PRIi32 ", mtd_num=%" PRIi32
+				", vid_hdr_offset=%" PRIi32
+				", max_beb_per1024=%" PRIi16 "}",
+				attach.ubi_num, attach.mtd_num,
+				attach.vid_hdr_offset, attach.max_beb_per1024);
+			return 1;
+		}
+		if (!syserror(tcp)) {
+			tprints(" => ");
+			printnum_int(tcp, arg, "%d");
+		}
+		break;
+
+	case UBI_IOCEBMAP: {
+		struct ubi_map_req map;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &map))
+			break;
+
+		tprintf("{lnum=%" PRIi32 ", dtype=%" PRIi8 "}",
+			map.lnum, map.dtype);
+		break;
+	}
+
+	case UBI_IOCSETVOLPROP: {
+		struct ubi_set_vol_prop_req prop;
+
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &prop))
+			break;
+
+		tprints("{property=");
+		printxval(ubi_volume_props, prop.property, "UBI_VOL_PROP_???");
+		tprintf(", value=%#" PRIx64 "}", (uint64_t)prop.value);
+		break;
+	}
+
+
+	case UBI_IOCVOLUP:
+		tprints(", ");
+		printnum_int64(tcp, arg, "%" PRIi64);
+		break;
+
+	case UBI_IOCDET:
+	case UBI_IOCEBER:
+	case UBI_IOCEBISMAP:
+	case UBI_IOCEBUNMAP:
+	case UBI_IOCRMVOL:
+		tprints(", ");
+		printnum_int(tcp, arg, "%d");
+		break;
+
+#ifdef UBI_IOCVOLCRBLK
+	case UBI_IOCVOLCRBLK:
+#endif
+#ifdef UBI_IOCVOLRMBLK
+	case UBI_IOCVOLRMBLK:
+#endif
+		/* no arguments */
+		break;
+
+	default:
+		return RVAL_DECODED;
+	}
+
+	return RVAL_DECODED | 1;
+}
diff --git a/strace/uid.c b/strace/uid.c
new file mode 100644
index 0000000..67e8e58
--- /dev/null
+++ b/strace/uid.c
@@ -0,0 +1,199 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2003-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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.
+ */
+
+#ifdef STRACE_UID_SIZE
+# if STRACE_UID_SIZE != 16
+#  error invalid STRACE_UID_SIZE
+# endif
+
+# define SIZEIFY(x)		SIZEIFY_(x,STRACE_UID_SIZE)
+# define SIZEIFY_(x,size)	SIZEIFY__(x,size)
+# define SIZEIFY__(x,size)	x ## size
+
+# define printuid	SIZEIFY(printuid)
+# define sys_chown	SIZEIFY(sys_chown)
+# define sys_fchown	SIZEIFY(sys_fchown)
+# define sys_getgroups	SIZEIFY(sys_getgroups)
+# define sys_getresuid	SIZEIFY(sys_getresuid)
+# define sys_getuid	SIZEIFY(sys_getuid)
+# define sys_setfsuid	SIZEIFY(sys_setfsuid)
+# define sys_setgroups	SIZEIFY(sys_setgroups)
+# define sys_setresuid	SIZEIFY(sys_setresuid)
+# define sys_setreuid	SIZEIFY(sys_setreuid)
+# define sys_setuid	SIZEIFY(sys_setuid)
+#endif /* STRACE_UID_SIZE */
+
+#include "defs.h"
+
+#ifdef STRACE_UID_SIZE
+# if !NEED_UID16_PARSERS
+#  undef STRACE_UID_SIZE
+# endif
+#else
+# define STRACE_UID_SIZE 32
+#endif
+
+#ifdef STRACE_UID_SIZE
+
+# undef uid_t
+# define uid_t		uid_t_(STRACE_UID_SIZE)
+# define uid_t_(size)	uid_t__(size)
+# define uid_t__(size)	uint ## size ## _t
+
+SYS_FUNC(getuid)
+{
+	return RVAL_UDECIMAL | RVAL_DECODED;
+}
+
+SYS_FUNC(setfsuid)
+{
+	tprintf("%u", (uid_t) tcp->u_arg[0]);
+
+	return RVAL_UDECIMAL | RVAL_DECODED;
+}
+
+SYS_FUNC(setuid)
+{
+	printuid("", tcp->u_arg[0]);
+
+	return RVAL_DECODED;
+}
+
+static void
+get_print_uid(struct tcb *tcp, const char *prefix, const long addr)
+{
+	uid_t uid;
+
+	tprints(prefix);
+	if (!umove_or_printaddr(tcp, addr, &uid))
+		tprintf("[%u]", uid);
+}
+
+SYS_FUNC(getresuid)
+{
+	if (entering(tcp))
+		return 0;
+
+	get_print_uid(tcp, "", tcp->u_arg[0]);
+	get_print_uid(tcp, ", ", tcp->u_arg[1]);
+	get_print_uid(tcp, ", ", tcp->u_arg[2]);
+
+	return 0;
+}
+
+SYS_FUNC(setreuid)
+{
+	printuid("", tcp->u_arg[0]);
+	printuid(", ", tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(setresuid)
+{
+	printuid("", tcp->u_arg[0]);
+	printuid(", ", tcp->u_arg[1]);
+	printuid(", ", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(chown)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	printuid(", ", tcp->u_arg[1]);
+	printuid(", ", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fchown)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	printuid(", ", tcp->u_arg[1]);
+	printuid(", ", tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+void
+printuid(const char *text, const unsigned int uid)
+{
+	if ((uid_t) -1U == (uid_t) uid)
+		tprintf("%s-1", text);
+	else
+		tprintf("%s%u", text, (uid_t) uid);
+}
+
+static bool
+print_gid(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	tprintf("%u", (unsigned int) (* (uid_t *) elem_buf));
+
+	return true;
+}
+
+static void
+print_groups(struct tcb *tcp, const unsigned int len, const unsigned long addr)
+{
+	static unsigned long ngroups_max;
+	if (!ngroups_max)
+		ngroups_max = sysconf(_SC_NGROUPS_MAX);
+
+	if (len > ngroups_max) {
+		printaddr(addr);
+		return;
+	}
+
+	uid_t gid;
+	print_array(tcp, addr, len, &gid, sizeof(gid),
+		    umoven_or_printaddr, print_gid, 0);
+}
+
+SYS_FUNC(setgroups)
+{
+	const unsigned int len = tcp->u_arg[0];
+
+	tprintf("%u, ", len);
+	print_groups(tcp, len, tcp->u_arg[1]);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(getgroups)
+{
+	if (entering(tcp))
+		tprintf("%u, ", (unsigned int) tcp->u_arg[0]);
+	else
+		print_groups(tcp, tcp->u_rval, tcp->u_arg[1]);
+	return 0;
+}
+
+#endif /* STRACE_UID_SIZE */
diff --git a/strace/uid16.c b/strace/uid16.c
new file mode 100644
index 0000000..c6d665d
--- /dev/null
+++ b/strace/uid16.c
@@ -0,0 +1,2 @@
+#define STRACE_UID_SIZE 16
+#include "uid.c"
diff --git a/strace/umask.c b/strace/umask.c
new file mode 100644
index 0000000..dda40d4
--- /dev/null
+++ b/strace/umask.c
@@ -0,0 +1,8 @@
+#include "defs.h"
+
+SYS_FUNC(umask)
+{
+	tprintf("%#lo", tcp->u_arg[0]);
+
+	return RVAL_DECODED | RVAL_OCTAL;
+}
diff --git a/strace/umount.c b/strace/umount.c
new file mode 100644
index 0000000..8fafeab
--- /dev/null
+++ b/strace/umount.c
@@ -0,0 +1,11 @@
+#include "defs.h"
+#include "xlat/umount_flags.h"
+
+SYS_FUNC(umount2)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printflags(umount_flags, tcp->u_arg[1], "MNT_???");
+
+	return RVAL_DECODED;
+}
diff --git a/strace/uname.c b/strace/uname.c
new file mode 100644
index 0000000..3df11e8
--- /dev/null
+++ b/strace/uname.c
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2012-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sys/utsname.h>
+
+SYS_FUNC(uname)
+{
+	struct utsname uname;
+
+	if (entering(tcp))
+		return 0;
+
+	if (!umove_or_printaddr(tcp, tcp->u_arg[0], &uname)) {
+#define PRINT_UTS_MEMBER(prefix, member) \
+		tprints(prefix #member "="); \
+		print_quoted_string(uname.member, sizeof(uname.member), \
+				    QUOTE_0_TERMINATED)
+
+		PRINT_UTS_MEMBER("{", sysname);
+		PRINT_UTS_MEMBER(", ", nodename);
+		if (abbrev(tcp)) {
+			tprints(", ...}");
+			return 0;
+		}
+		PRINT_UTS_MEMBER(", ", release);
+		PRINT_UTS_MEMBER(", ", version);
+		PRINT_UTS_MEMBER(", ", machine);
+#ifdef HAVE_STRUCT_UTSNAME_DOMAINNAME
+		PRINT_UTS_MEMBER(", ", domainname);
+#endif
+		tprints("}");
+	}
+
+	return 0;
+}
diff --git a/strace/unwind.c b/strace/unwind.c
new file mode 100644
index 0000000..238e215
--- /dev/null
+++ b/strace/unwind.c
@@ -0,0 +1,585 @@
+/*
+ * Copyright (c) 2013 Luca Clementi <luca.clementi@gmail.com>
+ *
+ * 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 <limits.h>
+#include <libunwind-ptrace.h>
+
+#ifdef _LARGEFILE64_SOURCE
+# ifdef HAVE_FOPEN64
+#  define fopen_for_input fopen64
+# else
+#  define fopen_for_input fopen
+# endif
+#else
+# define fopen_for_input fopen
+#endif
+
+#define DPRINTF(F, A, ...) if (debug_flag) error_msg("[unwind(" A ")] " F, __VA_ARGS__)
+
+/*
+ * Кeep a sorted array of cache entries,
+ * so that we can binary search through it.
+ */
+struct mmap_cache_t {
+	/**
+	 * example entry:
+	 * 7fabbb09b000-7fabbb09f000 r-xp 00179000 fc:00 1180246 /lib/libc-2.11.1.so
+	 *
+	 * start_addr  is 0x7fabbb09b000
+	 * end_addr    is 0x7fabbb09f000
+	 * mmap_offset is 0x179000
+	 * binary_filename is "/lib/libc-2.11.1.so"
+	 */
+	unsigned long start_addr;
+	unsigned long end_addr;
+	unsigned long mmap_offset;
+	char *binary_filename;
+};
+
+/*
+ * Type used in stacktrace walker
+ */
+typedef void (*call_action_fn)(void *data,
+			       const char *binary_filename,
+			       const char *symbol_name,
+			       unw_word_t function_offset,
+			       unsigned long true_offset);
+typedef void (*error_action_fn)(void *data,
+				const char *error,
+				unsigned long true_offset);
+
+/*
+ * Type used in stacktrace capturing
+ */
+struct call_t {
+       struct call_t* next;
+       char *output_line;
+};
+
+struct queue_t {
+       struct call_t *tail;
+       struct call_t *head;
+};
+
+static void queue_print(struct queue_t *queue);
+static void delete_mmap_cache(struct tcb *tcp, const char *caller);
+
+static unw_addr_space_t libunwind_as;
+static unsigned int mmap_cache_generation;
+
+void
+unwind_init(void)
+{
+	libunwind_as = unw_create_addr_space(&_UPT_accessors, 0);
+	if (!libunwind_as)
+		error_msg_and_die("failed to create address space for stack tracing");
+	unw_set_caching_policy(libunwind_as, UNW_CACHE_GLOBAL);
+}
+
+void
+unwind_tcb_init(struct tcb *tcp)
+{
+	tcp->libunwind_ui = _UPT_create(tcp->pid);
+	if (!tcp->libunwind_ui)
+		die_out_of_memory();
+
+	tcp->queue = xmalloc(sizeof(*tcp->queue));
+	tcp->queue->head = NULL;
+	tcp->queue->tail = NULL;
+}
+
+void
+unwind_tcb_fin(struct tcb *tcp)
+{
+	queue_print(tcp->queue);
+	free(tcp->queue);
+	tcp->queue = NULL;
+
+	delete_mmap_cache(tcp, __FUNCTION__);
+
+	_UPT_destroy(tcp->libunwind_ui);
+	tcp->libunwind_ui = NULL;
+}
+
+/*
+ * caching of /proc/ID/maps for each process to speed up stack tracing
+ *
+ * The cache must be refreshed after syscalls that affect memory mappings,
+ * e.g. mmap, mprotect, munmap, execve.
+ */
+static void
+build_mmap_cache(struct tcb* tcp)
+{
+	FILE *fp;
+	struct mmap_cache_t *cache_head;
+	/* start with a small dynamically-allocated array and then expand it */
+	size_t cur_array_size = 10;
+	char filename[sizeof("/proc/4294967296/maps")];
+	char buffer[PATH_MAX + 80];
+
+	unw_flush_cache(libunwind_as, 0, 0);
+
+	sprintf(filename, "/proc/%u/maps", tcp->pid);
+	fp = fopen_for_input(filename, "r");
+	if (!fp) {
+		perror_msg("fopen: %s", filename);
+		return;
+	}
+
+	cache_head = xcalloc(cur_array_size, sizeof(*cache_head));
+
+	while (fgets(buffer, sizeof(buffer), fp) != NULL) {
+		struct mmap_cache_t *entry;
+		unsigned long start_addr, end_addr, mmap_offset;
+		char exec_bit;
+		char binary_path[PATH_MAX];
+
+		if (sscanf(buffer, "%lx-%lx %*c%*c%c%*c %lx %*x:%*x %*d %[^\n]",
+			   &start_addr, &end_addr, &exec_bit,
+			   &mmap_offset, binary_path) != 5)
+			continue;
+
+		/* ignore mappings that have no PROT_EXEC bit set */
+		if (exec_bit != 'x')
+			continue;
+
+		if (end_addr < start_addr) {
+			error_msg("%s: unrecognized file format", filename);
+			break;
+		}
+
+		/*
+		 * sanity check to make sure that we're storing
+		 * non-overlapping regions in ascending order
+		 */
+		if (tcp->mmap_cache_size > 0) {
+			entry = &cache_head[tcp->mmap_cache_size - 1];
+			if (entry->start_addr == start_addr &&
+			    entry->end_addr == end_addr) {
+				/* duplicate entry, e.g. [vsyscall] */
+				continue;
+			}
+			if (start_addr <= entry->start_addr ||
+			    start_addr < entry->end_addr) {
+				error_msg("%s: overlapping memory region",
+					  filename);
+				continue;
+			}
+		}
+
+		if (tcp->mmap_cache_size >= cur_array_size) {
+			cur_array_size *= 2;
+			cache_head = xreallocarray(cache_head, cur_array_size,
+						   sizeof(*cache_head));
+		}
+
+		entry = &cache_head[tcp->mmap_cache_size];
+		entry->start_addr = start_addr;
+		entry->end_addr = end_addr;
+		entry->mmap_offset = mmap_offset;
+		entry->binary_filename = xstrdup(binary_path);
+		tcp->mmap_cache_size++;
+	}
+	fclose(fp);
+	tcp->mmap_cache = cache_head;
+	tcp->mmap_cache_generation = mmap_cache_generation;
+
+	DPRINTF("tgen=%u, ggen=%u, tcp=%p, cache=%p",
+		"cache-build",
+		tcp->mmap_cache_generation,
+		mmap_cache_generation,
+		tcp, tcp->mmap_cache);
+}
+
+/* deleting the cache */
+static void
+delete_mmap_cache(struct tcb *tcp, const char *caller)
+{
+	unsigned int i;
+
+	DPRINTF("tgen=%u, ggen=%u, tcp=%p, cache=%p, caller=%s",
+		"cache-delete",
+		tcp->mmap_cache_generation,
+		mmap_cache_generation,
+		tcp, tcp->mmap_cache, caller);
+
+	for (i = 0; i < tcp->mmap_cache_size; i++) {
+		free(tcp->mmap_cache[i].binary_filename);
+		tcp->mmap_cache[i].binary_filename = NULL;
+	}
+	free(tcp->mmap_cache);
+	tcp->mmap_cache = NULL;
+	tcp->mmap_cache_size = 0;
+}
+
+static bool
+rebuild_cache_if_invalid(struct tcb *tcp, const char *caller)
+{
+	if ((tcp->mmap_cache_generation != mmap_cache_generation)
+	    && tcp->mmap_cache)
+		delete_mmap_cache(tcp, caller);
+
+	if (!tcp->mmap_cache)
+		build_mmap_cache(tcp);
+
+	if (!tcp->mmap_cache || !tcp->mmap_cache_size)
+		return false;
+	else
+		return true;
+}
+
+void
+unwind_cache_invalidate(struct tcb* tcp)
+{
+#if SUPPORTED_PERSONALITIES > 1
+	if (tcp->currpers != DEFAULT_PERSONALITY) {
+		/* disable strack trace */
+		return;
+	}
+#endif
+	mmap_cache_generation++;
+	DPRINTF("tgen=%u, ggen=%u, tcp=%p, cache=%p", "increment",
+		tcp->mmap_cache_generation,
+		mmap_cache_generation,
+		tcp,
+		tcp->mmap_cache);
+}
+
+static void
+get_symbol_name(unw_cursor_t *cursor, char **name,
+		size_t *size, unw_word_t *offset)
+{
+	for (;;) {
+		int rc = unw_get_proc_name(cursor, *name, *size, offset);
+		if (rc == 0)
+			break;
+		if (rc != -UNW_ENOMEM) {
+			**name = '\0';
+			*offset = 0;
+			break;
+		}
+		*name = xreallocarray(*name, 2, *size);
+		*size *= 2;
+	}
+}
+
+static int
+print_stack_frame(struct tcb *tcp,
+		  call_action_fn call_action,
+		  error_action_fn error_action,
+		  void *data,
+		  unw_cursor_t *cursor,
+		  char **symbol_name,
+		  size_t *symbol_name_size)
+{
+	unw_word_t ip;
+	int lower = 0;
+	int upper = (int) tcp->mmap_cache_size - 1;
+
+	if (unw_get_reg(cursor, UNW_REG_IP, &ip) < 0) {
+		perror_msg("Can't walk the stack of process %d", tcp->pid);
+		return -1;
+	}
+
+	while (lower <= upper) {
+		struct mmap_cache_t *cur_mmap_cache;
+		int mid = (upper + lower) / 2;
+
+		cur_mmap_cache = &tcp->mmap_cache[mid];
+
+		if (ip >= cur_mmap_cache->start_addr &&
+		    ip < cur_mmap_cache->end_addr) {
+			unsigned long true_offset;
+			unw_word_t function_offset;
+
+			get_symbol_name(cursor, symbol_name, symbol_name_size,
+					&function_offset);
+			true_offset = ip - cur_mmap_cache->start_addr +
+				cur_mmap_cache->mmap_offset;
+			call_action(data,
+				    cur_mmap_cache->binary_filename,
+				    *symbol_name,
+				    function_offset,
+				    true_offset);
+			return 0;
+		}
+		else if (ip < cur_mmap_cache->start_addr)
+			upper = mid - 1;
+		else
+			lower = mid + 1;
+	}
+
+	/*
+	 * there is a bug in libunwind >= 1.0
+	 * after a set_tid_address syscall
+	 * unw_get_reg returns IP == 0
+	 */
+	if(ip)
+		error_action(data, "unexpected_backtracing_error", ip);
+	return -1;
+}
+
+/*
+ * walking the stack
+ */
+static void
+stacktrace_walk(struct tcb *tcp,
+		call_action_fn call_action,
+		error_action_fn error_action,
+		void *data)
+{
+	char *symbol_name;
+	size_t symbol_name_size = 40;
+	unw_cursor_t cursor;
+	int stack_depth;
+
+	if (!tcp->mmap_cache)
+		error_msg_and_die("bug: mmap_cache is NULL");
+	if (tcp->mmap_cache_size == 0)
+		error_msg_and_die("bug: mmap_cache is empty");
+
+	symbol_name = xmalloc(symbol_name_size);
+
+	if (unw_init_remote(&cursor, libunwind_as, tcp->libunwind_ui) < 0)
+		perror_msg_and_die("Can't initiate libunwind");
+
+	for (stack_depth = 0; stack_depth < 256; ++stack_depth) {
+		if (print_stack_frame(tcp, call_action, error_action, data,
+				&cursor, &symbol_name, &symbol_name_size) < 0)
+			break;
+		if (unw_step(&cursor) <= 0)
+			break;
+	}
+	if (stack_depth >= 256)
+		error_action(data, "too many stack frames", 0);
+
+	free(symbol_name);
+}
+
+/*
+ * printing an entry in stack to stream or buffer
+ */
+/*
+ * we want to keep the format used by backtrace_symbols from the glibc
+ *
+ * ./a.out() [0x40063d]
+ * ./a.out() [0x4006bb]
+ * ./a.out() [0x4006c6]
+ * /lib64/libc.so.6(__libc_start_main+0xed) [0x7fa2f8a5976d]
+ * ./a.out() [0x400569]
+ */
+#define STACK_ENTRY_SYMBOL_FMT			\
+	" > %s(%s+0x%lx) [0x%lx]\n",		\
+	binary_filename,			\
+	symbol_name,				\
+	(unsigned long) function_offset,	\
+	true_offset
+#define STACK_ENTRY_NOSYMBOL_FMT		\
+	" > %s() [0x%lx]\n",			\
+	binary_filename, true_offset
+#define STACK_ENTRY_BUG_FMT			\
+	" > BUG IN %s\n"
+#define STACK_ENTRY_ERROR_WITH_OFFSET_FMT	\
+	" > %s [0x%lx]\n", error, true_offset
+#define STACK_ENTRY_ERROR_FMT			\
+	" > %s\n", error
+
+static void
+print_call_cb(void *dummy,
+	      const char *binary_filename,
+	      const char *symbol_name,
+	      unw_word_t function_offset,
+	      unsigned long true_offset)
+{
+	if (symbol_name && (symbol_name[0] != '\0'))
+		tprintf(STACK_ENTRY_SYMBOL_FMT);
+	else if (binary_filename)
+		tprintf(STACK_ENTRY_NOSYMBOL_FMT);
+	else
+		tprintf(STACK_ENTRY_BUG_FMT, __FUNCTION__);
+
+	line_ended();
+}
+
+static void
+print_error_cb(void *dummy,
+	       const char *error,
+	       unsigned long true_offset)
+{
+	if (true_offset)
+		tprintf(STACK_ENTRY_ERROR_WITH_OFFSET_FMT);
+	else
+		tprintf(STACK_ENTRY_ERROR_FMT);
+
+	line_ended();
+}
+
+static char *
+sprint_call_or_error(const char *binary_filename,
+		     const char *symbol_name,
+		     unw_word_t function_offset,
+		     unsigned long true_offset,
+		     const char *error)
+{
+       char *output_line = NULL;
+       int n;
+
+       if (symbol_name)
+               n = asprintf(&output_line, STACK_ENTRY_SYMBOL_FMT);
+       else if (binary_filename)
+               n = asprintf(&output_line, STACK_ENTRY_NOSYMBOL_FMT);
+       else if (error)
+               n = true_offset
+                       ? asprintf(&output_line, STACK_ENTRY_ERROR_WITH_OFFSET_FMT)
+                       : asprintf(&output_line, STACK_ENTRY_ERROR_FMT);
+       else
+               n = asprintf(&output_line, STACK_ENTRY_BUG_FMT, __FUNCTION__);
+
+       if (n < 0)
+               error_msg_and_die("error in asprintf");
+
+       return output_line;
+}
+
+/*
+ * queue manipulators
+ */
+static void
+queue_put(struct queue_t *queue,
+	  const char *binary_filename,
+	  const char *symbol_name,
+	  unw_word_t function_offset,
+	  unsigned long true_offset,
+	  const char *error)
+{
+	struct call_t *call;
+
+	call = xmalloc(sizeof(*call));
+	call->output_line = sprint_call_or_error(binary_filename,
+						 symbol_name,
+						 function_offset,
+						 true_offset,
+						 error);
+	call->next = NULL;
+
+	if (!queue->head) {
+		queue->head = call;
+		queue->tail = call;
+	} else {
+		queue->tail->next = call;
+		queue->tail = call;
+	}
+}
+
+static void
+queue_put_call(void *queue,
+	       const char *binary_filename,
+	       const char *symbol_name,
+	       unw_word_t function_offset,
+	       unsigned long true_offset)
+{
+	queue_put(queue,
+		  binary_filename,
+		  symbol_name,
+		  function_offset,
+		  true_offset,
+		  NULL);
+}
+
+static void
+queue_put_error(void *queue,
+		const char *error,
+		unsigned long ip)
+{
+	queue_put(queue, NULL, NULL, 0, ip, error);
+}
+
+static void
+queue_print(struct queue_t *queue)
+{
+	struct call_t *call, *tmp;
+
+	queue->tail = NULL;
+	call = queue->head;
+	queue->head = NULL;
+	while (call) {
+		tmp = call;
+		call = call->next;
+
+		tprints(tmp->output_line);
+		line_ended();
+
+		free(tmp->output_line);
+		tmp->output_line = NULL;
+		tmp->next = NULL;
+		free(tmp);
+	}
+}
+
+/*
+ * printing stack
+ */
+void
+unwind_print_stacktrace(struct tcb* tcp)
+{
+#if SUPPORTED_PERSONALITIES > 1
+	if (tcp->currpers != DEFAULT_PERSONALITY) {
+		/* disable strack trace */
+		return;
+	}
+#endif
+       if (tcp->queue->head) {
+	       DPRINTF("tcp=%p, queue=%p", "queueprint", tcp, tcp->queue->head);
+	       queue_print(tcp->queue);
+       }
+       else if (rebuild_cache_if_invalid(tcp, __FUNCTION__)) {
+               DPRINTF("tcp=%p, queue=%p", "stackprint", tcp, tcp->queue->head);
+               stacktrace_walk(tcp, print_call_cb, print_error_cb, NULL);
+       }
+}
+
+/*
+ * capturing stack
+ */
+void
+unwind_capture_stacktrace(struct tcb *tcp)
+{
+#if SUPPORTED_PERSONALITIES > 1
+	if (tcp->currpers != DEFAULT_PERSONALITY) {
+		/* disable strack trace */
+		return;
+	}
+#endif
+	if (tcp->queue->head)
+		error_msg_and_die("bug: unprinted entries in queue");
+
+	if (rebuild_cache_if_invalid(tcp, __FUNCTION__)) {
+		stacktrace_walk(tcp, queue_put_call, queue_put_error,
+				tcp->queue);
+		DPRINTF("tcp=%p, queue=%p", "captured", tcp, tcp->queue->head);
+	}
+}
diff --git a/strace/upeek.c b/strace/upeek.c
new file mode 100644
index 0000000..1edfcaa
--- /dev/null
+++ b/strace/upeek.c
@@ -0,0 +1,52 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 1999 IBM Deutschland Entwicklung GmbH, IBM Corporation
+ *                     Linux for s390 port by D.J. Barrow
+ *                    <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * 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 "ptrace.h"
+
+int
+upeek(int pid, long off, long *res)
+{
+	long val;
+
+	errno = 0;
+	val = ptrace(PTRACE_PEEKUSER, (pid_t) pid, (void *) off, 0);
+	if (val == -1 && errno) {
+		if (errno != ESRCH) {
+			perror_msg("upeek: PTRACE_PEEKUSER pid:%d @0x%lx)", pid, off);
+		}
+		return -1;
+	}
+	*res = val;
+	return 0;
+}
diff --git a/strace/userfaultfd.c b/strace/userfaultfd.c
new file mode 100644
index 0000000..2721105
--- /dev/null
+++ b/strace/userfaultfd.c
@@ -0,0 +1,158 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <fcntl.h>
+
+#include "xlat/uffd_flags.h"
+
+SYS_FUNC(userfaultfd)
+{
+	printflags(uffd_flags, tcp->u_arg[0], "UFFD_???");
+
+	return RVAL_DECODED | RVAL_FD;
+}
+
+#ifdef HAVE_LINUX_USERFAULTFD_H
+# include <linux/ioctl.h>
+# include <linux/userfaultfd.h>
+
+# include "xlat/uffd_api_flags.h"
+# include "xlat/uffd_copy_flags.h"
+# include "xlat/uffd_register_ioctl_flags.h"
+# include "xlat/uffd_register_mode_flags.h"
+# include "xlat/uffd_zeropage_flags.h"
+
+static void
+tprintf_uffdio_range(const struct uffdio_range *range)
+{
+	tprintf("{start=%#" PRI__x64 ", len=%#" PRI__x64 "}",
+		range->start, range->len);
+}
+
+int
+uffdio_ioctl(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	switch (code) {
+	case UFFDIO_API: {
+		struct uffdio_api ua;
+		if (entering(tcp)) {
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &ua))
+				return RVAL_DECODED | 1;
+			/* Features is intended to contain some flags, but
+			 * there aren't any defined yet.
+			 */
+			tprintf("{api=%#" PRI__x64
+				", features=%#" PRI__x64,
+				ua.api, ua.features);
+		} else {
+			if (!syserror(tcp) && !umove(tcp, arg, &ua)) {
+				tprintf(", features.out=%#" PRI__x64
+					", ioctls=", ua.features);
+				printflags64(uffd_api_flags, ua.ioctls,
+					     "_UFFDIO_???");
+			}
+			tprintf("}");
+		}
+		return 1;
+	}
+
+	case UFFDIO_COPY: {
+		struct uffdio_copy uc;
+		if (entering(tcp)) {
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &uc))
+				return RVAL_DECODED | 1;
+			tprintf("{dst=%#" PRI__x64 ", src=%#" PRI__x64
+				", len=%#" PRI__x64 ", mode=",
+				uc.dst, uc.src, uc.len);
+			printflags64(uffd_copy_flags, uc.mode,
+				     "UFFDIO_COPY_???");
+		} else {
+			if (!syserror(tcp) && !umove(tcp, arg, &uc))
+				tprintf(", copy=%#" PRI__x64, uc.copy);
+			tprints("}");
+		}
+		return 1;
+	}
+
+	case UFFDIO_REGISTER: {
+		struct uffdio_register ur;
+		if (entering(tcp)) {
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &ur))
+				return RVAL_DECODED | 1;
+			tprintf("{range=");
+			tprintf_uffdio_range(&ur.range);
+			tprintf(", mode=");
+			printflags64(uffd_register_mode_flags, ur.mode,
+				     "UFFDIO_REGISTER_MODE_???");
+		} else {
+			if (!syserror(tcp) && !umove(tcp, arg, &ur)) {
+				tprintf(", ioctls=");
+				printflags64(uffd_register_ioctl_flags,
+					     ur.ioctls, "UFFDIO_???");
+			}
+			tprints("}");
+		}
+		return 1;
+	}
+
+	case UFFDIO_UNREGISTER:
+	case UFFDIO_WAKE: {
+		struct uffdio_range ura;
+		tprints(", ");
+		if (!umove_or_printaddr(tcp, arg, &ura))
+			tprintf_uffdio_range(&ura);
+		return RVAL_DECODED | 1;
+	}
+
+	case UFFDIO_ZEROPAGE: {
+		struct uffdio_zeropage uz;
+		if (entering(tcp)) {
+			tprints(", ");
+			if (umove_or_printaddr(tcp, arg, &uz))
+				return RVAL_DECODED | 1;
+			tprintf("{range=");
+			tprintf_uffdio_range(&uz.range);
+			tprintf(", mode=");
+			printflags64(uffd_zeropage_flags, uz.mode,
+				     "UFFDIO_ZEROPAGE_???");
+		} else {
+			if (!syserror(tcp) && !umove(tcp, arg, &uz))
+				tprintf(", zeropage=%#" PRI__x64, uz.zeropage);
+			tprints("}");
+		}
+		return 1;
+	}
+
+	default:
+		return RVAL_DECODED;
+	}
+}
+#endif /* HAVE_LINUX_USERFAULTFD_H */
diff --git a/strace/util.c b/strace/util.c
new file mode 100644
index 0000000..afa3290
--- /dev/null
+++ b/strace/util.c
@@ -0,0 +1,1490 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 1999 IBM Deutschland Entwicklung GmbH, IBM Corporation
+ *                     Linux for s390 port by D.J. Barrow
+ *                    <barrow_dj@mail.yahoo.com,djbarrow@de.ibm.com>
+ * 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 <sys/param.h>
+#include <fcntl.h>
+#include <stdarg.h>
+#ifdef HAVE_SYS_XATTR_H
+# include <sys/xattr.h>
+#endif
+#include <sys/uio.h>
+
+#include "regs.h"
+#include "ptrace.h"
+
+int
+string_to_uint(const char *str)
+{
+	char *error;
+	long value;
+
+	if (!*str)
+		return -1;
+	errno = 0;
+	value = strtol(str, &error, 10);
+	if (errno || *error || value < 0 || (long)(int)value != value)
+		return -1;
+	return (int)value;
+}
+
+int
+tv_nz(const struct timeval *a)
+{
+	return a->tv_sec || a->tv_usec;
+}
+
+int
+tv_cmp(const struct timeval *a, const struct timeval *b)
+{
+	if (a->tv_sec < b->tv_sec
+	    || (a->tv_sec == b->tv_sec && a->tv_usec < b->tv_usec))
+		return -1;
+	if (a->tv_sec > b->tv_sec
+	    || (a->tv_sec == b->tv_sec && a->tv_usec > b->tv_usec))
+		return 1;
+	return 0;
+}
+
+double
+tv_float(const struct timeval *tv)
+{
+	return tv->tv_sec + tv->tv_usec/1000000.0;
+}
+
+void
+tv_add(struct timeval *tv, const struct timeval *a, const struct timeval *b)
+{
+	tv->tv_sec = a->tv_sec + b->tv_sec;
+	tv->tv_usec = a->tv_usec + b->tv_usec;
+	if (tv->tv_usec >= 1000000) {
+		tv->tv_sec++;
+		tv->tv_usec -= 1000000;
+	}
+}
+
+void
+tv_sub(struct timeval *tv, const struct timeval *a, const struct timeval *b)
+{
+	tv->tv_sec = a->tv_sec - b->tv_sec;
+	tv->tv_usec = a->tv_usec - b->tv_usec;
+	if (((long) tv->tv_usec) < 0) {
+		tv->tv_sec--;
+		tv->tv_usec += 1000000;
+	}
+}
+
+void
+tv_div(struct timeval *tv, const struct timeval *a, int n)
+{
+	tv->tv_usec = (a->tv_sec % n * 1000000 + a->tv_usec + n / 2) / n;
+	tv->tv_sec = a->tv_sec / n + tv->tv_usec / 1000000;
+	tv->tv_usec %= 1000000;
+}
+
+void
+tv_mul(struct timeval *tv, const struct timeval *a, int n)
+{
+	tv->tv_usec = a->tv_usec * n;
+	tv->tv_sec = a->tv_sec * n + tv->tv_usec / 1000000;
+	tv->tv_usec %= 1000000;
+}
+
+const char *
+xlookup(const struct xlat *xlat, const uint64_t val)
+{
+	for (; xlat->str != NULL; xlat++)
+		if (xlat->val == val)
+			return xlat->str;
+	return NULL;
+}
+
+static int
+xlat_bsearch_compare(const void *a, const void *b)
+{
+	const uint64_t val1 = *(const uint64_t *) a;
+	const uint64_t val2 = ((const struct xlat *) b)->val;
+	return (val1 > val2) ? 1 : (val1 < val2) ? -1 : 0;
+}
+
+const char *
+xlat_search(const struct xlat *xlat, const size_t nmemb, const uint64_t val)
+{
+	const struct xlat *e =
+		bsearch((const void*) &val,
+			xlat, nmemb, sizeof(*xlat), xlat_bsearch_compare);
+
+	return e ? e->str : NULL;
+}
+
+#if !defined HAVE_STPCPY
+char *
+stpcpy(char *dst, const char *src)
+{
+	while ((*dst = *src++) != '\0')
+		dst++;
+	return dst;
+}
+#endif
+
+/* Find a next bit which is set.
+ * Starts testing at cur_bit.
+ * Returns -1 if no more bits are set.
+ *
+ * We never touch bytes we don't need to.
+ * On big-endian, array is assumed to consist of
+ * current_wordsize wide words: for example, is current_wordsize is 4,
+ * the bytes are walked in 3,2,1,0, 7,6,5,4, 11,10,9,8 ... sequence.
+ * On little-endian machines, word size is immaterial.
+ */
+int
+next_set_bit(const void *bit_array, unsigned cur_bit, unsigned size_bits)
+{
+	const unsigned endian = 1;
+	int little_endian = * (char *) (void *) &endian;
+
+	const uint8_t *array = bit_array;
+	unsigned pos = cur_bit / 8;
+	unsigned pos_xor_mask = little_endian ? 0 : current_wordsize-1;
+
+	for (;;) {
+		uint8_t bitmask;
+		uint8_t cur_byte;
+
+		if (cur_bit >= size_bits)
+			return -1;
+		cur_byte = array[pos ^ pos_xor_mask];
+		if (cur_byte == 0) {
+			cur_bit = (cur_bit + 8) & (-8);
+			pos++;
+			continue;
+		}
+		bitmask = 1 << (cur_bit & 7);
+		for (;;) {
+			if (cur_byte & bitmask)
+				return cur_bit;
+			cur_bit++;
+			if (cur_bit >= size_bits)
+				return -1;
+			bitmask <<= 1;
+			/* This check *can't be* optimized out: */
+			if (bitmask == 0)
+				break;
+		}
+		pos++;
+	}
+}
+/*
+ * Print entry in struct xlat table, if there.
+ */
+void
+printxvals(const uint64_t val, const char *dflt, const struct xlat *xlat, ...)
+{
+	va_list args;
+
+	va_start(args, xlat);
+	for (; xlat; xlat = va_arg(args, const struct xlat *)) {
+		const char *str = xlookup(xlat, val);
+
+		if (str) {
+			tprints(str);
+			va_end(args);
+			return;
+		}
+	}
+	/* No hits -- print raw # instead. */
+	tprintf("%#" PRIx64 " /* %s */", val, dflt);
+
+	va_end(args);
+}
+
+/*
+ * Fetch 64bit argument at position arg_no and
+ * return the index of the next argument.
+ */
+int
+getllval(struct tcb *tcp, unsigned long long *val, int arg_no)
+{
+#if SIZEOF_LONG > 4 && SIZEOF_LONG == SIZEOF_LONG_LONG
+# if SUPPORTED_PERSONALITIES > 1
+#  ifdef X86_64
+	if (current_personality != 1) {
+#  else
+	if (current_wordsize > 4) {
+#  endif
+# endif
+		*val = tcp->u_arg[arg_no];
+		arg_no++;
+# if SUPPORTED_PERSONALITIES > 1
+	} else {
+#  if defined(AARCH64) || defined(POWERPC64)
+		/* Align arg_no to the next even number. */
+		arg_no = (arg_no + 1) & 0xe;
+#  endif /* AARCH64 || POWERPC64 */
+		*val = LONG_LONG(tcp->u_arg[arg_no], tcp->u_arg[arg_no + 1]);
+		arg_no += 2;
+	}
+# endif /* SUPPORTED_PERSONALITIES > 1 */
+#elif SIZEOF_LONG > 4
+#  error Unsupported configuration: SIZEOF_LONG > 4 && SIZEOF_LONG_LONG > SIZEOF_LONG
+#elif HAVE_STRUCT_TCB_EXT_ARG
+# if SUPPORTED_PERSONALITIES > 1
+	if (current_personality == 1) {
+		*val = LONG_LONG(tcp->u_arg[arg_no], tcp->u_arg[arg_no + 1]);
+		arg_no += 2;
+	} else
+# endif
+	{
+		*val = tcp->ext_arg[arg_no];
+		arg_no++;
+	}
+#else
+# if defined __ARM_EABI__ || \
+     defined LINUX_MIPSO32 || \
+     defined POWERPC || \
+     defined XTENSA
+	/* Align arg_no to the next even number. */
+	arg_no = (arg_no + 1) & 0xe;
+# endif
+	*val = LONG_LONG(tcp->u_arg[arg_no], tcp->u_arg[arg_no + 1]);
+	arg_no += 2;
+#endif
+
+	return arg_no;
+}
+
+/*
+ * Print 64bit argument at position arg_no and
+ * return the index of the next argument.
+ */
+int
+printllval(struct tcb *tcp, const char *format, int arg_no)
+{
+	unsigned long long val = 0;
+
+	arg_no = getllval(tcp, &val, arg_no);
+	tprintf(format, val);
+	return arg_no;
+}
+
+/*
+ * Interpret `xlat' as an array of flags
+ * print the entries whose bits are on in `flags'
+ * return # of flags printed.
+ */
+void
+addflags(const struct xlat *xlat, uint64_t flags)
+{
+	for (; xlat->str; xlat++) {
+		if (xlat->val && (flags & xlat->val) == xlat->val) {
+			tprintf("|%s", xlat->str);
+			flags &= ~xlat->val;
+		}
+	}
+	if (flags) {
+		tprintf("|%#" PRIx64, flags);
+	}
+}
+
+/*
+ * Interpret `xlat' as an array of flags.
+ * Print to static string the entries whose bits are on in `flags'
+ * Return static string.
+ */
+const char *
+sprintflags(const char *prefix, const struct xlat *xlat, uint64_t flags)
+{
+	static char outstr[1024];
+	char *outptr;
+	int found = 0;
+
+	outptr = stpcpy(outstr, prefix);
+
+	if (flags == 0 && xlat->val == 0 && xlat->str) {
+		strcpy(outptr, xlat->str);
+		return outstr;
+	}
+
+	for (; xlat->str; xlat++) {
+		if (xlat->val && (flags & xlat->val) == xlat->val) {
+			if (found)
+				*outptr++ = '|';
+			outptr = stpcpy(outptr, xlat->str);
+			found = 1;
+			flags &= ~xlat->val;
+			if (!flags)
+				break;
+		}
+	}
+	if (flags) {
+		if (found)
+			*outptr++ = '|';
+		outptr += sprintf(outptr, "%#" PRIx64, flags);
+	}
+
+	return outstr;
+}
+
+int
+printflags64(const struct xlat *xlat, uint64_t flags, const char *dflt)
+{
+	int n;
+	const char *sep;
+
+	if (flags == 0 && xlat->val == 0 && xlat->str) {
+		tprints(xlat->str);
+		return 1;
+	}
+
+	sep = "";
+	for (n = 0; xlat->str; xlat++) {
+		if (xlat->val && (flags & xlat->val) == xlat->val) {
+			tprintf("%s%s", sep, xlat->str);
+			flags &= ~xlat->val;
+			sep = "|";
+			n++;
+		}
+	}
+
+	if (n) {
+		if (flags) {
+			tprintf("%s%#" PRIx64, sep, flags);
+			n++;
+		}
+	} else {
+		if (flags) {
+			tprintf("%#" PRIx64, flags);
+			if (dflt)
+				tprintf(" /* %s */", dflt);
+		} else {
+			if (dflt)
+				tprints("0");
+		}
+	}
+
+	return n;
+}
+
+void
+printaddr(const long addr)
+{
+	if (!addr)
+		tprints("NULL");
+	else
+		tprintf("%#lx", addr);
+}
+
+#define DEF_PRINTNUM(name, type) \
+bool									\
+printnum_ ## name(struct tcb *tcp, const long addr, const char *fmt)	\
+{									\
+	type num;							\
+	if (umove_or_printaddr(tcp, addr, &num))			\
+		return false;						\
+	tprints("[");							\
+	tprintf(fmt, num);						\
+	tprints("]");							\
+	return true;							\
+}
+
+#define DEF_PRINTPAIR(name, type) \
+bool									\
+printpair_ ## name(struct tcb *tcp, const long addr, const char *fmt)	\
+{									\
+	type pair[2];							\
+	if (umove_or_printaddr(tcp, addr, &pair))			\
+		return false;						\
+	tprints("[");							\
+	tprintf(fmt, pair[0]);						\
+	tprints(", ");							\
+	tprintf(fmt, pair[1]);						\
+	tprints("]");							\
+	return true;							\
+}
+
+DEF_PRINTNUM(int, int)
+DEF_PRINTPAIR(int, int)
+DEF_PRINTNUM(short, short)
+DEF_PRINTNUM(int64, uint64_t)
+DEF_PRINTPAIR(int64, uint64_t)
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+bool
+printnum_long_int(struct tcb *tcp, const long addr,
+		  const char *fmt_long, const char *fmt_int)
+{
+	if (current_wordsize > sizeof(int)) {
+		return printnum_int64(tcp, addr, fmt_long);
+	} else {
+		return printnum_int(tcp, addr, fmt_int);
+	}
+}
+#endif
+
+const char *
+sprinttime(time_t t)
+{
+	struct tm *tmp;
+	static char buf[sizeof(int) * 3 * 6];
+
+	if (t == 0) {
+		strcpy(buf, "0");
+		return buf;
+	}
+	tmp = localtime(&t);
+	if (tmp)
+		snprintf(buf, sizeof buf, "%02d/%02d/%02d-%02d:%02d:%02d",
+			tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
+			tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
+	else
+		snprintf(buf, sizeof buf, "%lu", (unsigned long) t);
+
+	return buf;
+}
+
+enum sock_proto
+getfdproto(struct tcb *tcp, int fd)
+{
+#ifdef HAVE_SYS_XATTR_H
+	size_t bufsize = 256;
+	char buf[bufsize];
+	ssize_t r;
+	char path[sizeof("/proc/%u/fd/%u") + 2 * sizeof(int)*3];
+
+	if (fd < 0)
+		return SOCK_PROTO_UNKNOWN;
+
+	sprintf(path, "/proc/%u/fd/%u", tcp->pid, fd);
+	r = getxattr(path, "system.sockprotoname", buf, bufsize - 1);
+	if (r <= 0)
+		return SOCK_PROTO_UNKNOWN;
+	else {
+		/*
+		 * This is a protection for the case when the kernel
+		 * side does not append a null byte to the buffer.
+		 */
+		buf[r] = '\0';
+
+		return get_proto_by_name(buf);
+	}
+#else
+	return SOCK_PROTO_UNKNOWN;
+#endif
+}
+
+void
+printfd(struct tcb *tcp, int fd)
+{
+	char path[PATH_MAX + 1];
+	if (show_fd_path && getfdpath(tcp, fd, path, sizeof(path)) >= 0) {
+		static const char socket_prefix[] = "socket:[";
+		const size_t socket_prefix_len = sizeof(socket_prefix) - 1;
+		const size_t path_len = strlen(path);
+
+		tprintf("%d<", fd);
+		if (show_fd_path > 1 &&
+		    strncmp(path, socket_prefix, socket_prefix_len) == 0 &&
+		    path[path_len - 1] == ']') {
+			unsigned long inode =
+				strtoul(path + socket_prefix_len, NULL, 10);
+
+			if (!print_sockaddr_by_inode_cached(inode)) {
+				const enum sock_proto proto =
+					getfdproto(tcp, fd);
+				if (!print_sockaddr_by_inode(inode, proto))
+					tprints(path);
+			}
+		} else {
+			print_quoted_string(path, path_len,
+					    QUOTE_OMIT_LEADING_TRAILING_QUOTES);
+		}
+		tprints(">");
+	} else
+		tprintf("%d", fd);
+}
+
+/*
+ * Quote string `instr' of length `size'
+ * Write up to (3 + `size' * 4) bytes to `outstr' buffer.
+ *
+ * If QUOTE_0_TERMINATED `style' flag is set,
+ * treat `instr' as a NUL-terminated string,
+ * checking up to (`size' + 1) bytes of `instr'.
+ *
+ * If QUOTE_OMIT_LEADING_TRAILING_QUOTES `style' flag is set,
+ * do not add leading and trailing quoting symbols.
+ *
+ * Returns 0 if QUOTE_0_TERMINATED is set and NUL was seen, 1 otherwise.
+ * Note that if QUOTE_0_TERMINATED is not set, always returns 1.
+ */
+int
+string_quote(const char *instr, char *outstr, const unsigned int size,
+	     const unsigned int style)
+{
+	const unsigned char *ustr = (const unsigned char *) instr;
+	char *s = outstr;
+	unsigned int i;
+	int usehex, c, eol;
+
+	if (style & QUOTE_0_TERMINATED)
+		eol = '\0';
+	else
+		eol = 0x100; /* this can never match a char */
+
+	usehex = 0;
+	if (xflag > 1)
+		usehex = 1;
+	else if (xflag) {
+		/* Check for presence of symbol which require
+		   to hex-quote the whole string. */
+		for (i = 0; i < size; ++i) {
+			c = ustr[i];
+			/* Check for NUL-terminated string. */
+			if (c == eol)
+				break;
+
+			/* Force hex unless c is printable or whitespace */
+			if (c > 0x7e) {
+				usehex = 1;
+				break;
+			}
+			/* In ASCII isspace is only these chars: "\t\n\v\f\r".
+			 * They happen to have ASCII codes 9,10,11,12,13.
+			 */
+			if (c < ' ' && (unsigned)(c - 9) >= 5) {
+				usehex = 1;
+				break;
+			}
+		}
+	}
+
+	if (!(style & QUOTE_OMIT_LEADING_TRAILING_QUOTES))
+		*s++ = '\"';
+
+	if (usehex) {
+		/* Hex-quote the whole string. */
+		for (i = 0; i < size; ++i) {
+			c = ustr[i];
+			/* Check for NUL-terminated string. */
+			if (c == eol)
+				goto asciz_ended;
+			*s++ = '\\';
+			*s++ = 'x';
+			*s++ = "0123456789abcdef"[c >> 4];
+			*s++ = "0123456789abcdef"[c & 0xf];
+		}
+	} else {
+		for (i = 0; i < size; ++i) {
+			c = ustr[i];
+			/* Check for NUL-terminated string. */
+			if (c == eol)
+				goto asciz_ended;
+			switch (c) {
+				case '\"': case '\\':
+					*s++ = '\\';
+					*s++ = c;
+					break;
+				case '\f':
+					*s++ = '\\';
+					*s++ = 'f';
+					break;
+				case '\n':
+					*s++ = '\\';
+					*s++ = 'n';
+					break;
+				case '\r':
+					*s++ = '\\';
+					*s++ = 'r';
+					break;
+				case '\t':
+					*s++ = '\\';
+					*s++ = 't';
+					break;
+				case '\v':
+					*s++ = '\\';
+					*s++ = 'v';
+					break;
+				default:
+					if (c >= ' ' && c <= 0x7e)
+						*s++ = c;
+					else {
+						/* Print \octal */
+						*s++ = '\\';
+						if (i + 1 < size
+						    && ustr[i + 1] >= '0'
+						    && ustr[i + 1] <= '9'
+						) {
+							/* Print \ooo */
+							*s++ = '0' + (c >> 6);
+							*s++ = '0' + ((c >> 3) & 0x7);
+						} else {
+							/* Print \[[o]o]o */
+							if ((c >> 3) != 0) {
+								if ((c >> 6) != 0)
+									*s++ = '0' + (c >> 6);
+								*s++ = '0' + ((c >> 3) & 0x7);
+							}
+						}
+						*s++ = '0' + (c & 0x7);
+					}
+					break;
+			}
+		}
+	}
+
+	if (!(style & QUOTE_OMIT_LEADING_TRAILING_QUOTES))
+		*s++ = '\"';
+	*s = '\0';
+
+	/* Return zero if we printed entire ASCIZ string (didn't truncate it) */
+	if (style & QUOTE_0_TERMINATED && ustr[i] == '\0') {
+		/* We didn't see NUL yet (otherwise we'd jump to 'asciz_ended')
+		 * but next char is NUL.
+		 */
+		return 0;
+	}
+
+	return 1;
+
+ asciz_ended:
+	if (!(style & QUOTE_OMIT_LEADING_TRAILING_QUOTES))
+		*s++ = '\"';
+	*s = '\0';
+	/* Return zero: we printed entire ASCIZ string (didn't truncate it) */
+	return 0;
+}
+
+#ifndef ALLOCA_CUTOFF
+# define ALLOCA_CUTOFF	4032
+#endif
+#define use_alloca(n) ((n) <= ALLOCA_CUTOFF)
+
+/*
+ * Quote string `str' of length `size' and print the result.
+ *
+ * If QUOTE_0_TERMINATED `style' flag is set,
+ * treat `str' as a NUL-terminated string and
+ * quote at most (`size' - 1) bytes.
+ *
+ * If QUOTE_OMIT_LEADING_TRAILING_QUOTES `style' flag is set,
+ * do not add leading and trailing quoting symbols.
+ *
+ * Returns 0 if QUOTE_0_TERMINATED is set and NUL was seen, 1 otherwise.
+ * Note that if QUOTE_0_TERMINATED is not set, always returns 1.
+ */
+int
+print_quoted_string(const char *str, unsigned int size,
+		    const unsigned int style)
+{
+	char *buf;
+	char *outstr;
+	unsigned int alloc_size;
+	int rc;
+
+	if (size && style & QUOTE_0_TERMINATED)
+		--size;
+
+	alloc_size = 4 * size;
+	if (alloc_size / 4 != size) {
+		error_msg("Out of memory");
+		tprints("???");
+		return -1;
+	}
+	alloc_size += 1 + (style & QUOTE_OMIT_LEADING_TRAILING_QUOTES ? 0 : 2);
+
+	if (use_alloca(alloc_size)) {
+		outstr = alloca(alloc_size);
+		buf = NULL;
+	} else {
+		outstr = buf = malloc(alloc_size);
+		if (!buf) {
+			error_msg("Out of memory");
+			tprints("???");
+			return -1;
+		}
+	}
+
+	rc = string_quote(str, outstr, size, style);
+	tprints(outstr);
+
+	free(buf);
+	return rc;
+}
+
+/*
+ * Print path string specified by address `addr' and length `n'.
+ * If path length exceeds `n', append `...' to the output.
+ */
+void
+printpathn(struct tcb *tcp, long addr, unsigned int n)
+{
+	char path[PATH_MAX + 1];
+	int nul_seen;
+
+	if (!addr) {
+		tprints("NULL");
+		return;
+	}
+
+	/* Cap path length to the path buffer size */
+	if (n > sizeof path - 1)
+		n = sizeof path - 1;
+
+	/* Fetch one byte more to find out whether path length > n. */
+	nul_seen = umovestr(tcp, addr, n + 1, path);
+	if (nul_seen < 0)
+		printaddr(addr);
+	else {
+		path[n++] = '\0';
+		print_quoted_string(path, n, QUOTE_0_TERMINATED);
+		if (!nul_seen)
+			tprints("...");
+	}
+}
+
+void
+printpath(struct tcb *tcp, long addr)
+{
+	/* Size must correspond to char path[] size in printpathn */
+	printpathn(tcp, addr, PATH_MAX);
+}
+
+/*
+ * Print string specified by address `addr' and length `len'.
+ * If `len' < 0, treat the string as a NUL-terminated string.
+ * If string length exceeds `max_strlen', append `...' to the output.
+ */
+void
+printstr(struct tcb *tcp, long addr, long len)
+{
+	static char *str = NULL;
+	static char *outstr;
+	unsigned int size;
+	unsigned int style;
+	int ellipsis;
+
+	if (!addr) {
+		tprints("NULL");
+		return;
+	}
+	/* Allocate static buffers if they are not allocated yet. */
+	if (!str) {
+		unsigned int outstr_size = 4 * max_strlen + /*for quotes and NUL:*/ 3;
+
+		if (outstr_size / 4 != max_strlen)
+			die_out_of_memory();
+		str = xmalloc(max_strlen + 1);
+		outstr = xmalloc(outstr_size);
+	}
+
+	size = max_strlen;
+	if (len == -1) {
+		/*
+		 * Treat as a NUL-terminated string: fetch one byte more
+		 * because string_quote may look one byte ahead.
+		 */
+		if (umovestr(tcp, addr, size + 1, str) < 0) {
+			printaddr(addr);
+			return;
+		}
+		style = QUOTE_0_TERMINATED;
+	}
+	else {
+		if (size > (unsigned long)len)
+			size = (unsigned long)len;
+		if (umoven(tcp, addr, size, str) < 0) {
+			printaddr(addr);
+			return;
+		}
+		style = 0;
+	}
+
+	/* If string_quote didn't see NUL and (it was supposed to be ASCIZ str
+	 * or we were requested to print more than -s NUM chars)...
+	 */
+	ellipsis = (string_quote(str, outstr, size, style) &&
+			(len < 0 || (unsigned long) len > max_strlen));
+
+	tprints(outstr);
+	if (ellipsis)
+		tprints("...");
+}
+
+void
+dumpiov_upto(struct tcb *tcp, int len, long addr, unsigned long data_size)
+{
+#if SUPPORTED_PERSONALITIES > 1
+	union {
+		struct { uint32_t base; uint32_t len; } *iov32;
+		struct { uint64_t base; uint64_t len; } *iov64;
+	} iovu;
+#define iov iovu.iov64
+#define sizeof_iov \
+	(current_wordsize == 4 ? sizeof(*iovu.iov32) : sizeof(*iovu.iov64))
+#define iov_iov_base(i) \
+	(current_wordsize == 4 ? (uint64_t) iovu.iov32[i].base : iovu.iov64[i].base)
+#define iov_iov_len(i) \
+	(current_wordsize == 4 ? (uint64_t) iovu.iov32[i].len : iovu.iov64[i].len)
+#else
+	struct iovec *iov;
+#define sizeof_iov sizeof(*iov)
+#define iov_iov_base(i) iov[i].iov_base
+#define iov_iov_len(i) iov[i].iov_len
+#endif
+	int i;
+	unsigned size;
+
+	size = sizeof_iov * len;
+	/* Assuming no sane program has millions of iovs */
+	if ((unsigned)len > 1024*1024 /* insane or negative size? */
+	    || (iov = malloc(size)) == NULL) {
+		error_msg("Out of memory");
+		return;
+	}
+	if (umoven(tcp, addr, size, iov) >= 0) {
+		for (i = 0; i < len; i++) {
+			unsigned long iov_len = iov_iov_len(i);
+			if (iov_len > data_size)
+				iov_len = data_size;
+			if (!iov_len)
+				break;
+			data_size -= iov_len;
+			/* include the buffer number to make it easy to
+			 * match up the trace with the source */
+			tprintf(" * %lu bytes in buffer %d\n", iov_len, i);
+			dumpstr(tcp, (long) iov_iov_base(i), iov_len);
+		}
+	}
+	free(iov);
+#undef sizeof_iov
+#undef iov_iov_base
+#undef iov_iov_len
+#undef iov
+}
+
+void
+dumpstr(struct tcb *tcp, long addr, int len)
+{
+	static int strsize = -1;
+	static unsigned char *str;
+
+	char outbuf[
+		(
+			(sizeof(
+			"xx xx xx xx xx xx xx xx  xx xx xx xx xx xx xx xx  "
+			"1234567890123456") + /*in case I'm off by few:*/ 4)
+		/*align to 8 to make memset easier:*/ + 7) & -8
+	];
+	const unsigned char *src;
+	int i;
+
+	memset(outbuf, ' ', sizeof(outbuf));
+
+	if (strsize < len + 16) {
+		free(str);
+		str = malloc(len + 16);
+		if (!str) {
+			strsize = -1;
+			error_msg("Out of memory");
+			return;
+		}
+		strsize = len + 16;
+	}
+
+	if (umoven(tcp, addr, len, str) < 0)
+		return;
+
+	/* Space-pad to 16 bytes */
+	i = len;
+	while (i & 0xf)
+		str[i++] = ' ';
+
+	i = 0;
+	src = str;
+	while (i < len) {
+		char *dst = outbuf;
+		/* Hex dump */
+		do {
+			if (i < len) {
+				*dst++ = "0123456789abcdef"[*src >> 4];
+				*dst++ = "0123456789abcdef"[*src & 0xf];
+			}
+			else {
+				*dst++ = ' ';
+				*dst++ = ' ';
+			}
+			dst++; /* space is there by memset */
+			i++;
+			if ((i & 7) == 0)
+				dst++; /* space is there by memset */
+			src++;
+		} while (i & 0xf);
+		/* ASCII dump */
+		i -= 16;
+		src -= 16;
+		do {
+			if (*src >= ' ' && *src < 0x7f)
+				*dst++ = *src;
+			else
+				*dst++ = '.';
+			src++;
+		} while (++i & 0xf);
+		*dst = '\0';
+		tprintf(" | %05x  %s |\n", i - 16, outbuf);
+	}
+}
+
+#ifdef HAVE_PROCESS_VM_READV
+/* C library supports this, but the kernel might not. */
+static bool process_vm_readv_not_supported = 0;
+#else
+
+/* Need to do this since process_vm_readv() is not yet available in libc.
+ * When libc is be updated, only "static bool process_vm_readv_not_supported"
+ * line should remain.
+ */
+#if !defined(__NR_process_vm_readv)
+# if defined(I386)
+#  define __NR_process_vm_readv  347
+# elif defined(X86_64)
+#  define __NR_process_vm_readv  310
+# elif defined(POWERPC)
+#  define __NR_process_vm_readv  351
+# endif
+#endif
+
+#if defined(__NR_process_vm_readv)
+static bool process_vm_readv_not_supported = 0;
+/* Have to avoid duplicating with the C library headers. */
+static ssize_t strace_process_vm_readv(pid_t pid,
+		 const struct iovec *lvec,
+		 unsigned long liovcnt,
+		 const struct iovec *rvec,
+		 unsigned long riovcnt,
+		 unsigned long flags)
+{
+	return syscall(__NR_process_vm_readv, (long)pid, lvec, liovcnt, rvec, riovcnt, flags);
+}
+#define process_vm_readv strace_process_vm_readv
+#else
+static bool process_vm_readv_not_supported = 1;
+# define process_vm_readv(...) (errno = ENOSYS, -1)
+#endif
+
+#endif /* end of hack */
+
+static ssize_t
+vm_read_mem(pid_t pid, void *laddr, long raddr, size_t len)
+{
+	const struct iovec local = {
+		.iov_base = laddr,
+		.iov_len = len
+	};
+	const struct iovec remote = {
+		.iov_base = (void *) raddr,
+		.iov_len = len
+	};
+
+	return process_vm_readv(pid, &local, 1, &remote, 1, 0);
+}
+
+/*
+ * move `len' bytes of data from process `pid'
+ * at address `addr' to our space at `our_addr'
+ */
+int
+umoven(struct tcb *tcp, long addr, unsigned int len, void *our_addr)
+{
+	char *laddr = our_addr;
+	int pid = tcp->pid;
+	unsigned int n, m, nread;
+	union {
+		long val;
+		char x[sizeof(long)];
+	} u;
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+	if (current_wordsize < sizeof(addr))
+		addr &= (1ul << 8 * current_wordsize) - 1;
+#endif
+
+	if (!process_vm_readv_not_supported) {
+		int r = vm_read_mem(pid, laddr, addr, len);
+		if ((unsigned int) r == len)
+			return 0;
+		if (r >= 0) {
+			error_msg("umoven: short read (%u < %u) @0x%lx",
+				  (unsigned int) r, len, addr);
+			return -1;
+		}
+		switch (errno) {
+			case ENOSYS:
+				process_vm_readv_not_supported = 1;
+				break;
+			case EPERM:
+				/* operation not permitted, try PTRACE_PEEKDATA */
+				break;
+			case ESRCH:
+				/* the process is gone */
+				return -1;
+			case EFAULT: case EIO:
+				/* address space is inaccessible */
+				return -1;
+			default:
+				/* all the rest is strange and should be reported */
+				perror_msg("process_vm_readv");
+				return -1;
+		}
+	}
+
+	nread = 0;
+	if (addr & (sizeof(long) - 1)) {
+		/* addr not a multiple of sizeof(long) */
+		n = addr & (sizeof(long) - 1);	/* residue */
+		addr &= -sizeof(long);		/* aligned address */
+		errno = 0;
+		u.val = ptrace(PTRACE_PEEKDATA, pid, (void *) addr, 0);
+		switch (errno) {
+			case 0:
+				break;
+			case ESRCH: case EINVAL:
+				/* these could be seen if the process is gone */
+				return -1;
+			case EFAULT: case EIO: case EPERM:
+				/* address space is inaccessible */
+				return -1;
+			default:
+				/* all the rest is strange and should be reported */
+				perror_msg("umoven: PTRACE_PEEKDATA pid:%d @0x%lx",
+					    pid, addr);
+				return -1;
+		}
+		m = MIN(sizeof(long) - n, len);
+		memcpy(laddr, &u.x[n], m);
+		addr += sizeof(long);
+		laddr += m;
+		nread += m;
+		len -= m;
+	}
+	while (len) {
+		errno = 0;
+		u.val = ptrace(PTRACE_PEEKDATA, pid, (void *) addr, 0);
+		switch (errno) {
+			case 0:
+				break;
+			case ESRCH: case EINVAL:
+				/* these could be seen if the process is gone */
+				return -1;
+			case EFAULT: case EIO: case EPERM:
+				/* address space is inaccessible */
+				if (nread) {
+					perror_msg("umoven: short read (%u < %u) @0x%lx",
+						   nread, nread + len, addr - nread);
+				}
+				return -1;
+			default:
+				/* all the rest is strange and should be reported */
+				perror_msg("umoven: PTRACE_PEEKDATA pid:%d @0x%lx",
+					    pid, addr);
+				return -1;
+		}
+		m = MIN(sizeof(long), len);
+		memcpy(laddr, u.x, m);
+		addr += sizeof(long);
+		laddr += m;
+		nread += m;
+		len -= m;
+	}
+
+	return 0;
+}
+
+int
+umoven_or_printaddr(struct tcb *tcp, const long addr, const unsigned int len,
+		    void *our_addr)
+{
+	if (!addr || !verbose(tcp) || (exiting(tcp) && syserror(tcp)) ||
+	    umoven(tcp, addr, len, our_addr) < 0) {
+		printaddr(addr);
+		return -1;
+	}
+	return 0;
+}
+
+/*
+ * Like `umove' but make the additional effort of looking
+ * for a terminating zero byte.
+ *
+ * Returns < 0 on error, > 0 if NUL was seen,
+ * (TODO if useful: return count of bytes including NUL),
+ * else 0 if len bytes were read but no NUL byte seen.
+ *
+ * Note: there is no guarantee we won't overwrite some bytes
+ * in laddr[] _after_ terminating NUL (but, of course,
+ * we never write past laddr[len-1]).
+ */
+int
+umovestr(struct tcb *tcp, long addr, unsigned int len, char *laddr)
+{
+#if SIZEOF_LONG == 4
+	const unsigned long x01010101 = 0x01010101ul;
+	const unsigned long x80808080 = 0x80808080ul;
+#elif SIZEOF_LONG == 8
+	const unsigned long x01010101 = 0x0101010101010101ul;
+	const unsigned long x80808080 = 0x8080808080808080ul;
+#else
+# error SIZEOF_LONG > 8
+#endif
+
+	int pid = tcp->pid;
+	unsigned int n, m, nread;
+	union {
+		unsigned long val;
+		char x[sizeof(long)];
+	} u;
+
+#if SUPPORTED_PERSONALITIES > 1 && SIZEOF_LONG > 4
+	if (current_wordsize < sizeof(addr))
+		addr &= (1ul << 8 * current_wordsize) - 1;
+#endif
+
+	nread = 0;
+	if (!process_vm_readv_not_supported) {
+		const size_t page_size = get_pagesize();
+		const size_t page_mask = page_size - 1;
+
+		while (len > 0) {
+			unsigned int chunk_len;
+			unsigned int end_in_page;
+
+			/*
+			 * Don't cross pages, otherwise we can get EFAULT
+			 * and fail to notice that terminating NUL lies
+			 * in the existing (first) page.
+			 */
+			chunk_len = len > page_size ? page_size : len;
+			end_in_page = (addr + chunk_len) & page_mask;
+			if (chunk_len > end_in_page) /* crosses to the next page */
+				chunk_len -= end_in_page;
+
+			int r = vm_read_mem(pid, laddr, addr, chunk_len);
+			if (r > 0) {
+				if (memchr(laddr, '\0', r))
+					return 1;
+				addr += r;
+				laddr += r;
+				nread += r;
+				len -= r;
+				continue;
+			}
+			switch (errno) {
+				case ENOSYS:
+					process_vm_readv_not_supported = 1;
+					goto vm_readv_didnt_work;
+				case ESRCH:
+					/* the process is gone */
+					return -1;
+				case EPERM:
+					/* operation not permitted, try PTRACE_PEEKDATA */
+					if (!nread)
+						goto vm_readv_didnt_work;
+					/* fall through */
+				case EFAULT: case EIO:
+					/* address space is inaccessible */
+					if (nread) {
+						perror_msg("umovestr: short read (%d < %d) @0x%lx",
+							   nread, nread + len, addr - nread);
+					}
+					return -1;
+				default:
+					/* all the rest is strange and should be reported */
+					perror_msg("process_vm_readv");
+					return -1;
+			}
+		}
+		return 0;
+	}
+ vm_readv_didnt_work:
+
+	if (addr & (sizeof(long) - 1)) {
+		/* addr not a multiple of sizeof(long) */
+		n = addr & (sizeof(long) - 1);	/* residue */
+		addr &= -sizeof(long);		/* aligned address */
+		errno = 0;
+		u.val = ptrace(PTRACE_PEEKDATA, pid, (void *) addr, 0);
+		switch (errno) {
+			case 0:
+				break;
+			case ESRCH: case EINVAL:
+				/* these could be seen if the process is gone */
+				return -1;
+			case EFAULT: case EIO: case EPERM:
+				/* address space is inaccessible */
+				return -1;
+			default:
+				/* all the rest is strange and should be reported */
+				perror_msg("umovestr: PTRACE_PEEKDATA pid:%d @0x%lx",
+					    pid, addr);
+				return -1;
+		}
+		m = MIN(sizeof(long) - n, len);
+		memcpy(laddr, &u.x[n], m);
+		while (n & (sizeof(long) - 1))
+			if (u.x[n++] == '\0')
+				return 1;
+		addr += sizeof(long);
+		laddr += m;
+		nread += m;
+		len -= m;
+	}
+
+	while (len) {
+		errno = 0;
+		u.val = ptrace(PTRACE_PEEKDATA, pid, (void *) addr, 0);
+		switch (errno) {
+			case 0:
+				break;
+			case ESRCH: case EINVAL:
+				/* these could be seen if the process is gone */
+				return -1;
+			case EFAULT: case EIO: case EPERM:
+				/* address space is inaccessible */
+				if (nread) {
+					perror_msg("umovestr: short read (%d < %d) @0x%lx",
+						   nread, nread + len, addr - nread);
+				}
+				return -1;
+			default:
+				/* all the rest is strange and should be reported */
+				perror_msg("umovestr: PTRACE_PEEKDATA pid:%d @0x%lx",
+					   pid, addr);
+				return -1;
+		}
+		m = MIN(sizeof(long), len);
+		memcpy(laddr, u.x, m);
+		/* "If a NUL char exists in this word" */
+		if ((u.val - x01010101) & ~u.val & x80808080)
+			return 1;
+		addr += sizeof(long);
+		laddr += m;
+		nread += m;
+		len -= m;
+	}
+	return 0;
+}
+
+/*
+ * Iteratively fetch and print up to nmemb elements of elem_size size
+ * from the array that starts at tracee's address start_addr.
+ *
+ * Array elements are being fetched to the address specified by elem_buf.
+ *
+ * The fetcher callback function specified by umoven_func should follow
+ * the same semantics as umoven_or_printaddr function.
+ *
+ * The printer callback function specified by print_func is expected
+ * to print something; if it returns false, no more iterations will be made.
+ *
+ * The pointer specified by opaque_data is passed to each invocation
+ * of print_func callback function.
+ *
+ * This function prints:
+ * - "NULL", if start_addr is NULL;
+ * - "[]", if nmemb is 0;
+ * - start_addr, if nmemb * elem_size overflows or wraps around;
+ * - nothing, if the first element cannot be fetched
+ *   (if umoven_func returns non-zero), but it is assumed that
+ *   umoven_func has printed the address it failed to fetch data from;
+ * - elements of the array, delimited by ", ", with the array itself
+ *   enclosed with [] brackets.
+ *
+ * If abbrev(tcp) is true, then
+ * - the maximum number of elements printed equals to max_strlen;
+ * - "..." is printed instead of max_strlen+1 element
+ *   and no more iterations will be made.
+ *
+ * This function returns true only if
+ * - umoven_func has been called at least once AND
+ * - umoven_func has not returned false.
+ */
+bool
+print_array(struct tcb *tcp,
+	    const unsigned long start_addr,
+	    const size_t nmemb,
+	    void *const elem_buf,
+	    const size_t elem_size,
+	    int (*const umoven_func)(struct tcb *,
+				     long,
+				     unsigned int,
+				     void *),
+	    bool (*const print_func)(struct tcb *,
+				     void *elem_buf,
+				     size_t elem_size,
+				     void *opaque_data),
+	    void *const opaque_data)
+{
+	if (!start_addr) {
+		tprints("NULL");
+		return false;
+	}
+
+	if (!nmemb) {
+		tprints("[]");
+		return false;
+	}
+
+	const size_t size = nmemb * elem_size;
+	const unsigned long end_addr = start_addr + size;
+
+	if (end_addr <= start_addr || size / elem_size != nmemb) {
+		printaddr(start_addr);
+		return false;
+	}
+
+	const unsigned long abbrev_end =
+		(abbrev(tcp) && max_strlen < nmemb) ?
+			start_addr + elem_size * max_strlen : end_addr;
+	unsigned long cur;
+
+	for (cur = start_addr; cur < end_addr; cur += elem_size) {
+		if (cur != start_addr)
+			tprints(", ");
+
+		if (umoven_func(tcp, cur, elem_size, elem_buf))
+			break;
+
+		if (cur == start_addr)
+			tprints("[");
+
+		if (cur >= abbrev_end) {
+			tprints("...");
+			cur = end_addr;
+			break;
+		}
+
+		if (!print_func(tcp, elem_buf, elem_size, opaque_data)) {
+			cur = end_addr;
+			break;
+		}
+	}
+	if (cur != start_addr)
+		tprints("]");
+
+	return cur >= end_addr;
+}
+
+int
+printargs(struct tcb *tcp)
+{
+	if (entering(tcp)) {
+		int i;
+		int n = tcp->s_ent->nargs;
+		for (i = 0; i < n; i++) {
+#if HAVE_STRUCT_TCB_EXT_ARG
+# if SUPPORTED_PERSONALITIES > 1
+			if (current_personality == 1)
+				tprintf("%s%#lx", i ? ", " : "", tcp->u_arg[i]);
+			else
+# endif
+			tprintf("%s%#llx", i ? ", " : "", tcp->ext_arg[i]);
+#else
+			tprintf("%s%#lx", i ? ", " : "", tcp->u_arg[i]);
+#endif
+		}
+	}
+	return 0;
+}
+
+int
+printargs_u(struct tcb *tcp)
+{
+	const int n = tcp->s_ent->nargs;
+	int i;
+	for (i = 0; i < n; ++i)
+		tprintf("%s%u", i ? ", " : "",
+			(unsigned int) tcp->u_arg[i]);
+	return RVAL_DECODED;
+}
+
+int
+printargs_d(struct tcb *tcp)
+{
+	const int n = tcp->s_ent->nargs;
+	int i;
+	for (i = 0; i < n; ++i)
+		tprintf("%s%d", i ? ", " : "",
+			(int) tcp->u_arg[i]);
+	return RVAL_DECODED;
+}
+
+#if defined _LARGEFILE64_SOURCE && defined HAVE_OPEN64
+# define open_file open64
+#else
+# define open_file open
+#endif
+
+int
+read_int_from_file(const char *const fname, int *const pvalue)
+{
+	const int fd = open_file(fname, O_RDONLY);
+	if (fd < 0)
+		return -1;
+
+	long lval;
+	char buf[sizeof(lval) * 3];
+	int n = read(fd, buf, sizeof(buf) - 1);
+	int saved_errno = errno;
+	close(fd);
+
+	if (n < 0) {
+		errno = saved_errno;
+		return -1;
+	}
+
+	buf[n] = '\0';
+	char *endptr = 0;
+	errno = 0;
+	lval = strtol(buf, &endptr, 10);
+	if (!endptr || (*endptr && '\n' != *endptr)
+#if INT_MAX < LONG_MAX
+	    || lval > INT_MAX || lval < INT_MIN
+#endif
+	    || ERANGE == errno) {
+		if (!errno)
+			errno = EINVAL;
+		return -1;
+	}
+
+	*pvalue = (int) lval;
+	return 0;
+}
diff --git a/strace/utime.c b/strace/utime.c
new file mode 100644
index 0000000..4f8f40a
--- /dev/null
+++ b/strace/utime.c
@@ -0,0 +1,23 @@
+#include "defs.h"
+
+#include DEF_MPERS_TYPE(utimbuf_t)
+
+#include <utime.h>
+
+typedef struct utimbuf utimbuf_t;
+
+#include MPERS_DEFS
+
+SYS_FUNC(utime)
+{
+	utimbuf_t u;
+
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	if (!umove_or_printaddr(tcp, tcp->u_arg[1], &u)) {
+		tprintf("[%s,", sprinttime(u.actime));
+		tprintf(" %s]", sprinttime(u.modtime));
+	}
+
+	return RVAL_DECODED;
+}
diff --git a/strace/utimes.c b/strace/utimes.c
new file mode 100644
index 0000000..2908529
--- /dev/null
+++ b/strace/utimes.c
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2006-2007 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2006 Bernhard Kaindl <bk@suse.de>
+ * Copyright (c) 2006-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+SYS_FUNC(utimes)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	print_timeval_pair(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(futimesat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	print_timeval_pair(tcp, tcp->u_arg[2]);
+
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(utimensat)
+{
+	print_dirfd(tcp, tcp->u_arg[0]);
+	printpath(tcp, tcp->u_arg[1]);
+	tprints(", ");
+	print_timespec_utime_pair(tcp, tcp->u_arg[2]);
+	tprints(", ");
+	printflags(at_flags, tcp->u_arg[3], "AT_???");
+
+	return RVAL_DECODED;
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_utimes)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	print_timeval32_pair(tcp, tcp->u_arg[1]);
+
+	return RVAL_DECODED;
+}
+#endif /* ALPHA */
diff --git a/strace/v4l2.c b/strace/v4l2.c
new file mode 100644
index 0000000..237766e
--- /dev/null
+++ b/strace/v4l2.c
@@ -0,0 +1,953 @@
+/*
+ * Copyright (c) 2014 Philippe De Muyter <phdm@macqel.be>
+ * Copyright (c) 2014 William Manley <will@williammanley.net>
+ * Copyright (c) 2011 Peter Zotov <whitequark@whitequark.org>
+ * 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 DEF_MPERS_TYPE(struct_v4l2_buffer)
+#include DEF_MPERS_TYPE(struct_v4l2_create_buffers)
+#include DEF_MPERS_TYPE(struct_v4l2_ext_control)
+#include DEF_MPERS_TYPE(struct_v4l2_ext_controls)
+#include DEF_MPERS_TYPE(struct_v4l2_format)
+#include DEF_MPERS_TYPE(struct_v4l2_framebuffer)
+#include DEF_MPERS_TYPE(struct_v4l2_input)
+#include DEF_MPERS_TYPE(struct_v4l2_standard)
+
+#include <stdint.h>
+#include <linux/ioctl.h>
+#include <linux/types.h>
+#include <linux/videodev2.h>
+
+typedef struct v4l2_buffer struct_v4l2_buffer;
+typedef struct v4l2_create_buffers struct_v4l2_create_buffers;
+typedef struct v4l2_ext_control struct_v4l2_ext_control;
+typedef struct v4l2_ext_controls struct_v4l2_ext_controls;
+typedef struct v4l2_format struct_v4l2_format;
+typedef struct v4l2_framebuffer struct_v4l2_framebuffer;
+typedef struct v4l2_input struct_v4l2_input;
+typedef struct v4l2_standard struct_v4l2_standard;
+
+#include MPERS_DEFS
+
+/* some historical constants */
+#ifndef V4L2_CID_HCENTER
+#define V4L2_CID_HCENTER (V4L2_CID_BASE+22)
+#endif
+#ifndef V4L2_CID_VCENTER
+#define V4L2_CID_VCENTER (V4L2_CID_BASE+23)
+#endif
+#ifndef V4L2_CID_BAND_STOP_FILTER
+#define V4L2_CID_BAND_STOP_FILTER (V4L2_CID_BASE+33)
+#endif
+
+#define FMT_FRACT "%u/%u"
+#define ARGS_FRACT(x) ((x).numerator), ((x).denominator)
+
+#define FMT_RECT "{left=%d, top=%d, width=%u, height=%u}"
+#define ARGS_RECT(x) (x).left, (x).top, (x).width, (x).height
+
+static void
+print_pixelformat(uint32_t fourcc)
+{
+	const union {
+		uint32_t pixelformat;
+		unsigned char cc[sizeof(uint32_t)];
+	} u = {
+#if WORDS_BIGENDIAN
+		.cc = {
+			(unsigned char) (fourcc >> 24),
+			(unsigned char) (fourcc >> 16),
+			(unsigned char) (fourcc >> 8),
+			(unsigned char) fourcc
+		}
+#else
+		.pixelformat = fourcc
+#endif
+	};
+	unsigned int i;
+
+	tprints("v4l2_fourcc(");
+	for (i = 0; i < sizeof(u.cc); ++i) {
+		unsigned char c = u.cc[i];
+
+		if (i)
+			tprints(", ");
+		if (c == '\'' || c == '\\') {
+			char sym[] = {
+				'\'',
+				'\\',
+				c,
+				'\'',
+				'\0'
+			};
+			tprints(sym);
+		} else if (c >= ' ' && c <= 0x7e) {
+			char sym[] = {
+				'\'',
+				c,
+				'\'',
+				'\0'
+			};
+			tprints(sym);
+		} else {
+			char hex[] = {
+				'\'',
+				'\\',
+				'x',
+				"0123456789abcdef"[c >> 4],
+				"0123456789abcdef"[c & 0xf],
+				'\'',
+				'\0'
+			};
+			tprints(hex);
+		}
+	}
+	tprints(")");
+}
+
+#include "xlat/v4l2_device_capabilities_flags.h"
+
+static int
+print_v4l2_capability(struct tcb *tcp, const long arg)
+{
+	struct v4l2_capability caps;
+
+	if (entering(tcp))
+		return 0;
+	tprints(", ");
+	if (umove_or_printaddr(tcp, arg, &caps))
+		return 1;
+	tprints("{driver=");
+	print_quoted_string((const char *) caps.driver,
+			    sizeof(caps.driver), QUOTE_0_TERMINATED);
+	tprints(", card=");
+	print_quoted_string((const char *) caps.card,
+			    sizeof(caps.card), QUOTE_0_TERMINATED);
+	tprints(", bus_info=");
+	print_quoted_string((const char *) caps.bus_info,
+			    sizeof(caps.bus_info), QUOTE_0_TERMINATED);
+	tprintf(", version=%u.%u.%u, capabilities=",
+		(caps.version >> 16) & 0xFF,
+		(caps.version >> 8) & 0xFF,
+		caps.version & 0xFF);
+	printflags(v4l2_device_capabilities_flags, caps.capabilities,
+		   "V4L2_CAP_???");
+#ifdef V4L2_CAP_DEVICE_CAPS
+	tprints(", device_caps=");
+	printflags(v4l2_device_capabilities_flags, caps.device_caps,
+		   "V4L2_CAP_???");
+#endif
+	tprints("}");
+	return 1;
+}
+
+#include "xlat/v4l2_buf_types.h"
+#include "xlat/v4l2_format_description_flags.h"
+
+static int
+print_v4l2_fmtdesc(struct tcb *tcp, const long arg)
+{
+	struct v4l2_fmtdesc f;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &f))
+			return RVAL_DECODED | 1;
+		tprintf("{index=%u, type=", f.index);
+		printxval(v4l2_buf_types, f.type, "V4L2_BUF_TYPE_???");
+		return 0;
+	}
+
+	if (!syserror(tcp) && !umove(tcp, arg, &f)) {
+		tprints(", flags=");
+		printflags(v4l2_format_description_flags, f.flags,
+			   "V4L2_FMT_FLAG_???");
+		tprints(", description=");
+		print_quoted_string((const char *) f.description,
+				    sizeof(f.description),
+				    QUOTE_0_TERMINATED);
+		tprints(", pixelformat=");
+		print_pixelformat(f.pixelformat);
+	}
+	tprints("}");
+	return 1;
+}
+
+#include "xlat/v4l2_fields.h"
+#include "xlat/v4l2_colorspaces.h"
+
+static void
+print_v4l2_format_fmt(const char *prefix, const struct_v4l2_format *f)
+{
+	switch (f->type) {
+	case V4L2_BUF_TYPE_VIDEO_CAPTURE:
+	case V4L2_BUF_TYPE_VIDEO_OUTPUT:
+		tprints(prefix);
+		tprintf("fmt.pix={width=%u, height=%u, pixelformat=",
+			f->fmt.pix.width, f->fmt.pix.height);
+		print_pixelformat(f->fmt.pix.pixelformat);
+		tprints(", field=");
+		printxval(v4l2_fields, f->fmt.pix.field, "V4L2_FIELD_???");
+		tprintf(", bytesperline=%u, sizeimage=%u, colorspace=",
+			f->fmt.pix.bytesperline, f->fmt.pix.sizeimage);
+		printxval(v4l2_colorspaces, f->fmt.pix.colorspace,
+			  "V4L2_COLORSPACE_???");
+		tprints("}");
+		break;
+#if HAVE_DECL_V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE
+	case V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE:
+	case V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE: {
+		unsigned int i, max;
+
+		tprints(prefix);
+		tprintf("fmt.pix_mp={width=%u, height=%u, pixelformat=",
+			f->fmt.pix_mp.width, f->fmt.pix_mp.height);
+		print_pixelformat(f->fmt.pix_mp.pixelformat);
+		tprints(", field=");
+		printxval(v4l2_fields, f->fmt.pix_mp.field, "V4L2_FIELD_???");
+		tprints(", colorspace=");
+		printxval(v4l2_colorspaces, f->fmt.pix_mp.colorspace,
+			  "V4L2_COLORSPACE_???");
+		tprints(", plane_fmt=[");
+		max = f->fmt.pix_mp.num_planes;
+		if (max > VIDEO_MAX_PLANES)
+			max = VIDEO_MAX_PLANES;
+		for (i = 0; i < max; i++) {
+			if (i > 0)
+				tprints(", ");
+			tprintf("{sizeimage=%u, bytesperline=%u}",
+				f->fmt.pix_mp.plane_fmt[i].sizeimage,
+				f->fmt.pix_mp.plane_fmt[i].bytesperline);
+		}
+		tprintf("], num_planes=%u}", (unsigned) f->fmt.pix_mp.num_planes);
+		break;
+	}
+#endif
+
+	/* TODO: Complete this switch statement */
+#if 0
+	case V4L2_BUF_TYPE_VIDEO_OVERLAY:
+#if HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY
+	case V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY:
+#endif
+		tprints(prefix);
+		tprints("fmt.win={???}");
+		break;
+
+	case V4L2_BUF_TYPE_VBI_CAPTURE:
+	case V4L2_BUF_TYPE_VBI_OUTPUT:
+		tprints(prefix);
+		tprints("fmt.vbi={???}");
+		break;
+
+	case V4L2_BUF_TYPE_SLICED_VBI_CAPTURE:
+	case V4L2_BUF_TYPE_SLICED_VBI_OUTPUT:
+		tprints(prefix);
+		tprints("fmt.sliced={???}");
+		break;
+
+#if HAVE_DECL_V4L2_BUF_TYPE_SDR_CAPTURE
+	case V4L2_BUF_TYPE_SDR_CAPTURE:
+	case V4L2_BUF_TYPE_SDR_OUTPUT:
+		tprints(prefix);
+		tprints("fmt.sdr={???}");
+		break;
+#endif
+#endif
+	}
+}
+
+static int
+print_v4l2_format(struct tcb *tcp, const long arg, const bool is_get)
+{
+	struct_v4l2_format f;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &f))
+			return RVAL_DECODED | 1;
+		tprints("{type=");
+		printxval(v4l2_buf_types, f.type, "V4L2_BUF_TYPE_???");
+		if (is_get)
+			return 0;
+		print_v4l2_format_fmt(", ", &f);
+	} else {
+		if (!syserror(tcp) && !umove(tcp, arg, &f)) {
+			const char *delim = is_get ? ", " : " => ";
+			print_v4l2_format_fmt(delim, &f);
+		}
+		tprints("}");
+	}
+	return 1;
+}
+
+#include "xlat/v4l2_memories.h"
+
+static int
+print_v4l2_requestbuffers(struct tcb *tcp, const long arg)
+{
+	struct v4l2_requestbuffers reqbufs;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &reqbufs))
+			return RVAL_DECODED | 1;
+		tprintf("{count=%u, type=", reqbufs.count);
+		printxval(v4l2_buf_types, reqbufs.type, "V4L2_BUF_TYPE_???");
+		tprints(", memory=");
+		printxval(v4l2_memories, reqbufs.memory, "V4L2_MEMORY_???");
+		tprints("}");
+		return 0;
+	} else {
+		static char outstr[sizeof("{count=}") + sizeof(int) * 3];
+
+		if (syserror(tcp) || umove(tcp, arg, &reqbufs) < 0)
+			return 1;
+		sprintf(outstr, "{count=%u}", reqbufs.count);
+		tcp->auxstr = outstr;
+		return 1 + RVAL_STR;
+	}
+}
+
+#include "xlat/v4l2_buf_flags.h"
+
+static int
+print_v4l2_buffer(struct tcb *tcp, const unsigned int code, const long arg)
+{
+	struct_v4l2_buffer b;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &b))
+			return RVAL_DECODED | 1;
+		tprints("{type=");
+		printxval(v4l2_buf_types, b.type, "V4L2_BUF_TYPE_???");
+		if (code != VIDIOC_DQBUF)
+			tprintf(", index=%u", b.index);
+	} else {
+		if (!syserror(tcp) && umove(tcp, arg, &b) == 0) {
+			if (code == VIDIOC_DQBUF)
+				tprintf(", index=%u", b.index);
+			tprints(", memory=");
+			printxval(v4l2_memories, b.memory, "V4L2_MEMORY_???");
+
+			if (b.memory == V4L2_MEMORY_MMAP) {
+				tprintf(", m.offset=%#x", b.m.offset);
+			} else if (b.memory == V4L2_MEMORY_USERPTR) {
+				tprints(", m.userptr=");
+				printaddr((unsigned long) b.m.userptr);
+			}
+
+			tprintf(", length=%u, bytesused=%u, flags=",
+				b.length, b.bytesused);
+			printflags(v4l2_buf_flags, b.flags, "V4L2_BUF_FLAG_???");
+			if (code == VIDIOC_DQBUF)
+				tprintf(", timestamp = {%ju.%06ju}",
+					(uintmax_t)b.timestamp.tv_sec,
+					(uintmax_t)b.timestamp.tv_usec);
+			tprints(", ...");
+		}
+		tprints("}");
+	}
+	return 1;
+}
+
+static int
+print_v4l2_framebuffer(struct tcb *tcp, const long arg)
+{
+	struct_v4l2_framebuffer b;
+
+	tprints(", ");
+	if (!umove_or_printaddr(tcp, arg, &b)) {
+		tprintf("{capability=%#x, flags=%#x, base=",
+			b.capability, b.flags);
+		printaddr((unsigned long) b.base);
+		tprints("}");
+	}
+
+	return RVAL_DECODED | 1;
+}
+
+static int
+print_v4l2_buf_type(struct tcb *tcp, const long arg)
+{
+	int type;
+
+	tprints(", ");
+	if (!umove_or_printaddr(tcp, arg, &type)) {
+		tprints("[");
+		printxval(v4l2_buf_types, type, "V4L2_BUF_TYPE_???");
+		tprints("]");
+	}
+	return RVAL_DECODED | 1;
+}
+
+#include "xlat/v4l2_streaming_capabilities.h"
+#include "xlat/v4l2_capture_modes.h"
+
+static int
+print_v4l2_streamparm(struct tcb *tcp, const long arg, const bool is_get)
+{
+	struct v4l2_streamparm s;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &s))
+			return RVAL_DECODED | 1;
+		tprints("{type=");
+		printxval(v4l2_buf_types, s.type, "V4L2_BUF_TYPE_???");
+		switch (s.type) {
+			case V4L2_BUF_TYPE_VIDEO_CAPTURE:
+			case V4L2_BUF_TYPE_VIDEO_OUTPUT:
+				if (is_get)
+					return 0;
+				tprints(", ");
+				break;
+			default:
+				tprints("}");
+				return RVAL_DECODED | 1;
+		}
+	} else {
+		if (syserror(tcp) || umove(tcp, arg, &s) < 0) {
+			tprints("}");
+			return 1;
+		}
+		tprints(is_get ? ", " : " => ");
+	}
+
+	if (s.type == V4L2_BUF_TYPE_VIDEO_CAPTURE) {
+		tprints("parm.capture={capability=");
+		printflags(v4l2_streaming_capabilities,
+			   s.parm.capture.capability, "V4L2_CAP_???");
+
+		tprints(", capturemode=");
+		printflags(v4l2_capture_modes,
+			   s.parm.capture.capturemode, "V4L2_MODE_???");
+
+		tprintf(", timeperframe=" FMT_FRACT,
+			ARGS_FRACT(s.parm.capture.timeperframe));
+
+		tprintf(", extendedmode=%u, readbuffers=%u}",
+			s.parm.capture.extendedmode,
+			s.parm.capture.readbuffers);
+	} else {
+		tprints("parm.output={capability=");
+		printflags(v4l2_streaming_capabilities,
+			   s.parm.output.capability, "V4L2_CAP_???");
+
+		tprintf(", outputmode=%u", s.parm.output.outputmode);
+
+		tprintf(", timeperframe=" FMT_FRACT,
+			ARGS_FRACT(s.parm.output.timeperframe));
+
+		tprintf(", extendedmode=%u, writebuffers=%u}",
+			s.parm.output.extendedmode,
+			s.parm.output.writebuffers);
+	}
+	if (exiting(tcp))
+		tprints("}");
+	return 1;
+}
+
+static int
+print_v4l2_standard(struct tcb *tcp, const long arg)
+{
+	struct_v4l2_standard s;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &s))
+			return RVAL_DECODED | 1;
+		tprintf("{index=%u", s.index);
+	} else {
+		if (!syserror(tcp) && !umove(tcp, arg, &s)) {
+			tprints(", name=");
+			print_quoted_string((const char *) s.name,
+					    sizeof(s.name),
+					    QUOTE_0_TERMINATED);
+			tprintf(", frameperiod=" FMT_FRACT,
+				ARGS_FRACT(s.frameperiod));
+			tprintf(", framelines=%d", s.framelines);
+		}
+		tprints("}");
+	}
+	return 1;
+}
+
+#include "xlat/v4l2_input_types.h"
+
+static int
+print_v4l2_input(struct tcb *tcp, const long arg)
+{
+	struct_v4l2_input i;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &i))
+			return RVAL_DECODED | 1;
+		tprintf("{index=%u", i.index);
+	} else {
+		if (!syserror(tcp) && !umove(tcp, arg, &i)) {
+			tprints(", name=");
+			print_quoted_string((const char *) i.name,
+					    sizeof(i.name),
+					    QUOTE_0_TERMINATED);
+			tprints(", type=");
+			printxval(v4l2_input_types, i.type,
+				  "V4L2_INPUT_TYPE_???");
+		}
+		tprints("}");
+	}
+	return 1;
+}
+
+#include "xlat/v4l2_control_ids.h"
+
+static int
+print_v4l2_control(struct tcb *tcp, const long arg, const bool is_get)
+{
+	struct v4l2_control c;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &c))
+			return RVAL_DECODED | 1;
+		tprints("{id=");
+		printxval(v4l2_control_ids, c.id, "V4L2_CID_???");
+		if (!is_get)
+			tprintf(", value=%d", c.value);
+		return 0;
+	}
+
+	if (!syserror(tcp) && !umove(tcp, arg, &c)) {
+		tprints(is_get ? ", " : " => ");
+		tprintf("value=%d", c.value);
+	}
+
+	tprints("}");
+	return 1;
+}
+
+#include "xlat/v4l2_control_types.h"
+#include "xlat/v4l2_control_flags.h"
+
+static int
+print_v4l2_queryctrl(struct tcb *tcp, const long arg)
+{
+	struct v4l2_queryctrl c;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &c))
+			return RVAL_DECODED | 1;
+		tprints("{id=");
+	} else {
+		if (syserror(tcp) || umove(tcp, arg, &c) < 0) {
+			tprints("}");
+			return 1;
+		}
+		if (get_tcb_priv_ulong(tcp))
+			tprints(" => ");
+	}
+
+	if (entering(tcp) || get_tcb_priv_ulong(tcp)) {
+#ifdef V4L2_CTRL_FLAG_NEXT_CTRL
+		const unsigned long next = c.id & V4L2_CTRL_FLAG_NEXT_CTRL;
+		set_tcb_priv_ulong(tcp, next);
+		if (next) {
+			tprints("V4L2_CTRL_FLAG_NEXT_CTRL|");
+			c.id &= ~V4L2_CTRL_FLAG_NEXT_CTRL;
+		}
+#endif
+		printxval(v4l2_control_ids, c.id, "V4L2_CID_???");
+	}
+
+	if (exiting(tcp)) {
+		tprints(", type=");
+		printxval(v4l2_control_types, c.type, "V4L2_CTRL_TYPE_???");
+		tprints(", name=");
+		print_quoted_string((const char *) c.name,
+				    sizeof(c.name),
+				    QUOTE_0_TERMINATED);
+		tprintf(", minimum=%d, maximum=%d, step=%d"
+			", default_value=%d, flags=",
+			c.minimum, c.maximum, c.step, c.default_value);
+		printflags(v4l2_control_flags, c.flags, "V4L2_CTRL_FLAG_???");
+		tprints("}");
+	}
+	return 1;
+}
+
+static int
+print_v4l2_cropcap(struct tcb *tcp, const long arg)
+{
+	struct v4l2_cropcap c;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &c))
+			return RVAL_DECODED | 1;
+		tprints("{type=");
+		printxval(v4l2_buf_types, c.type, "V4L2_BUF_TYPE_???");
+		return 0;
+	}
+	if (!syserror(tcp) && !umove(tcp, arg, &c)) {
+		tprintf(", bounds=" FMT_RECT
+			", defrect=" FMT_RECT
+			", pixelaspect=" FMT_FRACT,
+			ARGS_RECT(c.bounds),
+			ARGS_RECT(c.defrect),
+			ARGS_FRACT(c.pixelaspect));
+	}
+	tprints("}");
+	return 1;
+}
+
+static int
+print_v4l2_crop(struct tcb *tcp, const long arg, const bool is_get)
+{
+	struct v4l2_crop c;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &c))
+			return RVAL_DECODED | 1;
+		tprints("{type=");
+		printxval(v4l2_buf_types, c.type, "V4L2_BUF_TYPE_???");
+		if (is_get)
+			return 0;
+		tprintf(", c=" FMT_RECT, ARGS_RECT(c.c));
+	} else {
+		if (!syserror(tcp) && !umove(tcp, arg, &c))
+			tprintf(", c=" FMT_RECT, ARGS_RECT(c.c));
+	}
+
+	tprints("}");
+	return RVAL_DECODED | 1;
+}
+
+#ifdef VIDIOC_S_EXT_CTRLS
+static bool
+print_v4l2_ext_control(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
+{
+	const struct_v4l2_ext_control *p = elem_buf;
+
+	tprints("{id=");
+	printxval(v4l2_control_ids, p->id, "V4L2_CID_???");
+# if HAVE_DECL_V4L2_CTRL_TYPE_STRING
+	tprintf(", size=%u", p->size);
+	if (p->size > 0) {
+		tprints(", string=");
+		printstr(tcp, (long) p->string, p->size);
+	} else
+# endif
+	tprintf(", value=%d, value64=%lld", p->value,
+		(long long) p->value64);
+	tprints("}");
+
+	return true;
+}
+
+#include "xlat/v4l2_control_classes.h"
+
+static int
+umoven_or_printaddr_ignore_syserror(struct tcb *tcp, const long addr,
+				    const unsigned int len, void *our_addr)
+{
+	if (!addr || umoven(tcp, addr, len, our_addr) < 0) {
+		printaddr(addr);
+		return -1;
+	}
+	return 0;
+}
+
+static int
+print_v4l2_ext_controls(struct tcb *tcp, const long arg, const bool is_get)
+{
+	struct_v4l2_ext_controls c;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &c))
+			return RVAL_DECODED | 1;
+		tprints("{ctrl_class=");
+		printxval(v4l2_control_classes, c.ctrl_class,
+			  "V4L2_CTRL_CLASS_???");
+		tprintf(", count=%u", c.count);
+		if (!c.count) {
+			tprints("}");
+			return RVAL_DECODED | 1;
+		}
+		if (is_get)
+			return 0;
+		tprints(", ");
+	} else {
+		if (umove(tcp, arg, &c) < 0) {
+			tprints("}");
+			return 1;
+		}
+		tprints(is_get ? ", " : " => ");
+	}
+
+	tprints("controls=");
+	struct_v4l2_ext_control ctrl;
+	bool fail = !print_array(tcp, (unsigned long) c.controls, c.count,
+				 &ctrl, sizeof(ctrl),
+				 umoven_or_printaddr_ignore_syserror,
+				 print_v4l2_ext_control, 0);
+
+	if (exiting(tcp) && syserror(tcp))
+		tprintf(", error_idx=%u", c.error_idx);
+
+	if (exiting(tcp) || fail) {
+		tprints("}");
+		return RVAL_DECODED | 1;
+	}
+	return 1;
+}
+#endif /* VIDIOC_S_EXT_CTRLS */
+
+#ifdef VIDIOC_ENUM_FRAMESIZES
+# include "xlat/v4l2_framesize_types.h"
+
+static int
+print_v4l2_frmsizeenum(struct tcb *tcp, const long arg)
+{
+	struct v4l2_frmsizeenum s;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &s))
+			return RVAL_DECODED | 1;
+		tprintf("{index=%u, pixel_format=", s.index);
+		print_pixelformat(s.pixel_format);
+		return 0;
+	}
+
+	if (!syserror(tcp) && !umove(tcp, arg, &s)) {
+		tprints(", type=");
+		printxval(v4l2_framesize_types, s.type, "V4L2_FRMSIZE_TYPE_???");
+		switch (s.type) {
+		case V4L2_FRMSIZE_TYPE_DISCRETE:
+			tprintf(", discrete={width=%u, height=%u}",
+				s.discrete.width, s.discrete.height);
+			break;
+		case V4L2_FRMSIZE_TYPE_STEPWISE:
+			tprintf(", stepwise={min_width=%u, max_width=%u, "
+				"step_width=%u, min_height=%u, max_height=%u, "
+				"step_height=%u}",
+				s.stepwise.min_width, s.stepwise.max_width,
+				s.stepwise.step_width, s.stepwise.min_height,
+				s.stepwise.max_height, s.stepwise.step_height);
+			break;
+		}
+	}
+	tprints("}");
+	return 1;
+}
+#endif /* VIDIOC_ENUM_FRAMESIZES */
+
+#ifdef VIDIOC_ENUM_FRAMEINTERVALS
+# include "xlat/v4l2_frameinterval_types.h"
+
+static int
+print_v4l2_frmivalenum(struct tcb *tcp, const long arg)
+{
+	struct v4l2_frmivalenum f;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &f))
+			return RVAL_DECODED | 1;
+		tprintf("{index=%u, pixel_format=", f.index);
+		print_pixelformat(f.pixel_format);
+		tprintf(", width=%u, height=%u", f.width, f.height);
+		return 0;
+	}
+	if (!syserror(tcp) && !umove(tcp, arg, &f)) {
+		tprints(", type=");
+		printxval(v4l2_frameinterval_types, f.type,
+			  "V4L2_FRMIVAL_TYPE_???");
+		switch (f.type) {
+		case V4L2_FRMIVAL_TYPE_DISCRETE:
+			tprintf(", discrete=" FMT_FRACT,
+				ARGS_FRACT(f.discrete));
+			break;
+		case V4L2_FRMIVAL_TYPE_STEPWISE:
+		case V4L2_FRMSIZE_TYPE_CONTINUOUS:
+			tprintf(", stepwise={min=" FMT_FRACT ", max="
+				FMT_FRACT ", step=" FMT_FRACT "}",
+				ARGS_FRACT(f.stepwise.min),
+				ARGS_FRACT(f.stepwise.max),
+				ARGS_FRACT(f.stepwise.step));
+			break;
+		}
+	}
+	tprints("}");
+	return 1;
+}
+#endif /* VIDIOC_ENUM_FRAMEINTERVALS */
+
+#ifdef VIDIOC_CREATE_BUFS
+static int
+print_v4l2_create_buffers(struct tcb *tcp, const long arg)
+{
+	struct_v4l2_create_buffers b;
+
+	if (entering(tcp)) {
+		tprints(", ");
+		if (umove_or_printaddr(tcp, arg, &b))
+			return RVAL_DECODED | 1;
+		tprintf("{count=%u, memory=", b.count);
+		printxval(v4l2_memories, b.memory, "V4L2_MEMORY_???");
+		tprints(", format={type=");
+		printxval(v4l2_buf_types, b.format.type,
+			  "V4L2_BUF_TYPE_???");
+		print_v4l2_format_fmt(", ",
+				      (struct_v4l2_format *) &b.format);
+		tprints("}}");
+		return 0;
+	} else {
+		static const char fmt[] = "{index=%u, count=%u}";
+		static char outstr[sizeof(fmt) + sizeof(int) * 6];
+
+		if (syserror(tcp) || umove(tcp, arg, &b) < 0)
+			return 1;
+		sprintf(outstr, fmt, b.index, b.count);
+		tcp->auxstr = outstr;
+		return 1 + RVAL_STR;
+	}
+}
+#endif /* VIDIOC_CREATE_BUFS */
+
+MPERS_PRINTER_DECL(int, v4l2_ioctl,
+		   struct tcb *tcp, const unsigned int code, const long arg)
+{
+	if (!verbose(tcp))
+		return RVAL_DECODED;
+
+	switch (code) {
+	case VIDIOC_QUERYCAP: /* R */
+		return print_v4l2_capability(tcp, arg);
+
+	case VIDIOC_ENUM_FMT: /* RW */
+		return print_v4l2_fmtdesc(tcp, arg);
+
+	case VIDIOC_G_FMT: /* RW */
+	case VIDIOC_S_FMT: /* RW */
+	case VIDIOC_TRY_FMT: /* RW */
+		return print_v4l2_format(tcp, arg, code == VIDIOC_G_FMT);
+
+	case VIDIOC_REQBUFS: /* RW */
+		return print_v4l2_requestbuffers(tcp, arg);
+
+	case VIDIOC_QUERYBUF: /* RW */
+	case VIDIOC_QBUF: /* RW */
+	case VIDIOC_DQBUF: /* RW */
+		return print_v4l2_buffer(tcp, code, arg);
+
+	case VIDIOC_G_FBUF: /* R */
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case VIDIOC_S_FBUF: /* W */
+		return print_v4l2_framebuffer(tcp, arg);
+
+	case VIDIOC_STREAMON: /* W */
+	case VIDIOC_STREAMOFF: /* W */
+		return print_v4l2_buf_type(tcp, arg);
+
+	case VIDIOC_G_PARM: /* RW */
+	case VIDIOC_S_PARM: /* RW */
+		return print_v4l2_streamparm(tcp, arg, code == VIDIOC_G_PARM);
+
+	case VIDIOC_G_STD: /* R */
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case VIDIOC_S_STD: /* W */
+		tprints(", ");
+		printnum_int64(tcp, arg, "%#" PRIx64);
+		return RVAL_DECODED | 1;
+
+	case VIDIOC_ENUMSTD: /* RW */
+		return print_v4l2_standard(tcp, arg);
+
+	case VIDIOC_ENUMINPUT: /* RW */
+		return print_v4l2_input(tcp, arg);
+
+	case VIDIOC_G_CTRL: /* RW */
+	case VIDIOC_S_CTRL: /* RW */
+		return print_v4l2_control(tcp, arg, code == VIDIOC_G_CTRL);
+
+	case VIDIOC_QUERYCTRL: /* RW */
+		return print_v4l2_queryctrl(tcp, arg);
+
+	case VIDIOC_G_INPUT: /* R */
+		if (entering(tcp))
+			return 0;
+		/* fall through */
+	case VIDIOC_S_INPUT: /* RW */
+		tprints(", ");
+		printnum_int(tcp, arg, "%u");
+		return RVAL_DECODED | 1;
+
+	case VIDIOC_CROPCAP: /* RW */
+		return print_v4l2_cropcap(tcp, arg);
+
+	case VIDIOC_G_CROP: /* RW */
+	case VIDIOC_S_CROP: /* W */
+		return print_v4l2_crop(tcp, arg, code == VIDIOC_G_CROP);
+
+#ifdef VIDIOC_S_EXT_CTRLS
+	case VIDIOC_S_EXT_CTRLS: /* RW */
+	case VIDIOC_TRY_EXT_CTRLS: /* RW */
+	case VIDIOC_G_EXT_CTRLS: /* RW */
+		return print_v4l2_ext_controls(tcp, arg,
+					       code == VIDIOC_G_EXT_CTRLS);
+#endif /* VIDIOC_S_EXT_CTRLS */
+
+#ifdef VIDIOC_ENUM_FRAMESIZES
+	case VIDIOC_ENUM_FRAMESIZES: /* RW */
+		return print_v4l2_frmsizeenum(tcp, arg);
+#endif /* VIDIOC_ENUM_FRAMESIZES */
+
+#ifdef VIDIOC_ENUM_FRAMEINTERVALS
+	case VIDIOC_ENUM_FRAMEINTERVALS: /* RW */
+		return print_v4l2_frmivalenum(tcp, arg);
+#endif /* VIDIOC_ENUM_FRAMEINTERVALS */
+
+#ifdef VIDIOC_CREATE_BUFS
+	case VIDIOC_CREATE_BUFS: /* RW */
+		return print_v4l2_create_buffers(tcp, arg);
+#endif /* VIDIOC_CREATE_BUFS */
+
+	default:
+		return RVAL_DECODED;
+	}
+}
diff --git a/strace/vsprintf.c b/strace/vsprintf.c
new file mode 100644
index 0000000..aae40db
--- /dev/null
+++ b/strace/vsprintf.c
@@ -0,0 +1,788 @@
+/*
+ * Taken from Linux kernel's linux/lib/vsprintf.c
+ * and somewhat simplified.
+ *
+ * Copyright (C) 1991, 1992  Linus Torvalds
+ */
+/* vsprintf.c -- Lars Wirzenius & Linus Torvalds. */
+/*
+ * Wirzenius wrote this portably, Torvalds fucked it up :-)
+ */
+
+#include "defs.h"
+
+#if USE_CUSTOM_PRINTF
+
+#include <stdarg.h>
+#include <limits.h>
+
+#ifndef HAVE_FPUTS_UNLOCKED
+# define fputs_unlocked fputs
+#endif
+
+#define noinline_for_stack /*nothing*/
+#define likely(expr)       (expr)
+#define unlikely(expr)     (expr)
+
+#define do_div(n, d)       ({ __typeof(num) t = n % d; n /= d; t; })
+
+#undef isdigit
+#define isdigit(a) ((unsigned char)((a) - '0') <= 9)
+
+static inline
+int skip_atoi(const char **s)
+{
+	int i = 0;
+	const char *p = *s;
+
+	while (isdigit(*p))
+		i = i*10 + *p++ - '0';
+
+	*s = p;
+	return i;
+}
+
+/* Decimal conversion is by far the most typical, and is used
+ * for /proc and /sys data. This directly impacts e.g. top performance
+ * with many processes running. We optimize it for speed
+ * using ideas described at <http://www.cs.uiowa.edu/~jones/bcd/divide.html>
+ * (with permission from the author, Douglas W. Jones).
+ */
+
+#if LONG_MAX != 0x7fffffffUL || LLONG_MAX != 0x7fffffffffffffffULL
+/* Formats correctly any integer in [0, 999999999] */
+static noinline_for_stack
+char *put_dec_full9(char *buf, unsigned q)
+{
+	unsigned r;
+
+	/* Possible ways to approx. divide by 10
+	 * (x * 0x1999999a) >> 32 x < 1073741829 (multiply must be 64-bit)
+	 * (x * 0xcccd) >> 19     x <      81920 (x < 262149 when 64-bit mul)
+	 * (x * 0x6667) >> 18     x <      43699
+	 * (x * 0x3334) >> 17     x <      16389
+	 * (x * 0x199a) >> 16     x <      16389
+	 * (x * 0x0ccd) >> 15     x <      16389
+	 * (x * 0x0667) >> 14     x <       2739
+	 * (x * 0x0334) >> 13     x <       1029
+	 * (x * 0x019a) >> 12     x <       1029
+	 * (x * 0x00cd) >> 11     x <       1029 shorter code than * 0x67 (on i386)
+	 * (x * 0x0067) >> 10     x <        179
+	 * (x * 0x0034) >>  9     x <         69 same
+	 * (x * 0x001a) >>  8     x <         69 same
+	 * (x * 0x000d) >>  7     x <         69 same, shortest code (on i386)
+	 * (x * 0x0007) >>  6     x <         19
+	 * See <http://www.cs.uiowa.edu/~jones/bcd/divide.html>
+	 */
+	r      = (q * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (q - 10 * r) + '0'; /* 1 */
+	q      = (r * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (r - 10 * q) + '0'; /* 2 */
+	r      = (q * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (q - 10 * r) + '0'; /* 3 */
+	q      = (r * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (r - 10 * q) + '0'; /* 4 */
+	r      = (q * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (q - 10 * r) + '0'; /* 5 */
+	/* Now value is under 10000, can avoid 64-bit multiply */
+	q      = (r * 0x199a) >> 16;
+	*buf++ = (r - 10 * q)  + '0'; /* 6 */
+	r      = (q * 0xcd) >> 11;
+	*buf++ = (q - 10 * r)  + '0'; /* 7 */
+	q      = (r * 0xcd) >> 11;
+	*buf++ = (r - 10 * q) + '0'; /* 8 */
+	*buf++ = q + '0'; /* 9 */
+	return buf;
+}
+#endif
+
+/* Similar to above but do not pad with zeros.
+ * Code can be easily arranged to print 9 digits too, but our callers
+ * always call put_dec_full9() instead when the number has 9 decimal digits.
+ */
+static noinline_for_stack
+char *put_dec_trunc8(char *buf, unsigned r)
+{
+	unsigned q;
+
+	/* Copy of previous function's body with added early returns */
+	q      = (r * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (r - 10 * q) + '0'; /* 2 */
+	if (q == 0) return buf;
+	r      = (q * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (q - 10 * r) + '0'; /* 3 */
+	if (r == 0) return buf;
+	q      = (r * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (r - 10 * q) + '0'; /* 4 */
+	if (q == 0) return buf;
+	r      = (q * (uint64_t)0x1999999a) >> 32;
+	*buf++ = (q - 10 * r) + '0'; /* 5 */
+	if (r == 0) return buf;
+	q      = (r * 0x199a) >> 16;
+	*buf++ = (r - 10 * q)  + '0'; /* 6 */
+	if (q == 0) return buf;
+	r      = (q * 0xcd) >> 11;
+	*buf++ = (q - 10 * r)  + '0'; /* 7 */
+	if (r == 0) return buf;
+	q      = (r * 0xcd) >> 11;
+	*buf++ = (r - 10 * q) + '0'; /* 8 */
+	if (q == 0) return buf;
+	*buf++ = q + '0'; /* 9 */
+	return buf;
+}
+
+/* There are two algorithms to print larger numbers.
+ * One is generic: divide by 1000000000 and repeatedly print
+ * groups of (up to) 9 digits. It's conceptually simple,
+ * but requires a (unsigned long long) / 1000000000 division.
+ *
+ * Second algorithm splits 64-bit unsigned long long into 16-bit chunks,
+ * manipulates them cleverly and generates groups of 4 decimal digits.
+ * It so happens that it does NOT require long long division.
+ *
+ * If long is > 32 bits, division of 64-bit values is relatively easy,
+ * and we will use the first algorithm.
+ * If long long is > 64 bits (strange architecture with VERY large long long),
+ * second algorithm can't be used, and we again use the first one.
+ *
+ * Else (if long is 32 bits and long long is 64 bits) we use second one.
+ */
+
+#if LONG_MAX != 0x7fffffffUL || LLONG_MAX != 0x7fffffffffffffffULL
+
+/* First algorithm: generic */
+
+static
+char *put_dec(char *buf, unsigned long long n)
+{
+	if (n >= 100*1000*1000) {
+		while (n >= 1000*1000*1000)
+			buf = put_dec_full9(buf, do_div(n, 1000*1000*1000));
+		if (n >= 100*1000*1000)
+			return put_dec_full9(buf, n);
+	}
+	return put_dec_trunc8(buf, n);
+}
+
+#else
+
+/* Second algorithm: valid only for 64-bit long longs */
+
+static noinline_for_stack
+char *put_dec_full4(char *buf, unsigned q)
+{
+	unsigned r;
+	r      = (q * 0xcccd) >> 19;
+	*buf++ = (q - 10 * r) + '0';
+	q      = (r * 0x199a) >> 16;
+	*buf++ = (r - 10 * q)  + '0';
+	r      = (q * 0xcd) >> 11;
+	*buf++ = (q - 10 * r)  + '0';
+	*buf++ = r + '0';
+	return buf;
+}
+
+/* Based on code by Douglas W. Jones found at
+ * <http://www.cs.uiowa.edu/~jones/bcd/decimal.html#sixtyfour>
+ * (with permission from the author).
+ * Performs no 64-bit division and hence should be fast on 32-bit machines.
+ */
+static
+char *put_dec(char *buf, unsigned long long n)
+{
+	uint32_t d3, d2, d1, q, h;
+
+	if (n < 100*1000*1000)
+		return put_dec_trunc8(buf, n);
+
+	d1  = ((uint32_t)n >> 16); /* implicit "& 0xffff" */
+	h   = (n >> 32);
+	d2  = (h      ) & 0xffff;
+	d3  = (h >> 16); /* implicit "& 0xffff" */
+
+	q   = 656 * d3 + 7296 * d2 + 5536 * d1 + ((uint32_t)n & 0xffff);
+
+	buf = put_dec_full4(buf, q % 10000);
+	q   = q / 10000;
+
+	d1  = q + 7671 * d3 + 9496 * d2 + 6 * d1;
+	buf = put_dec_full4(buf, d1 % 10000);
+	q   = d1 / 10000;
+
+	d2  = q + 4749 * d3 + 42 * d2;
+	buf = put_dec_full4(buf, d2 % 10000);
+	q   = d2 / 10000;
+
+	d3  = q + 281 * d3;
+	if (!d3)
+		goto done;
+	buf = put_dec_full4(buf, d3 % 10000);
+	q   = d3 / 10000;
+	if (!q)
+		goto done;
+	buf = put_dec_full4(buf, q);
+ done:
+	while (buf[-1] == '0')
+		--buf;
+
+	return buf;
+}
+
+#endif
+
+/*
+ * For strace, the following formats are not supported:
+ * %h[h]u, %zu, %tu  - use [unsigned] int/long/long long fmt instead
+ * %8.4u  - no precision field for integers allowed (ok for strings)
+ * %+d, % d  - no forced sign or force "space positive" sign
+ * %-07u  - use %-7u instead
+ * %X  - works as %x
+ */
+
+#define ZEROPAD	1		/* pad with zero */
+#define SIGN	2		/* unsigned/signed long */
+//#define PLUS	4		/* show plus */
+//#define SPACE	8		/* space if plus */
+#define LEFT	16		/* left justified */
+//#deefine SMALL	32		/* use lowercase in hex (must be 32 == 0x20) */
+#define SPECIAL	64		/* prefix hex with "0x", octal with "0" */
+
+enum format_type {
+	FORMAT_TYPE_NONE, /* Just a string part */
+	FORMAT_TYPE_WIDTH,
+	FORMAT_TYPE_PRECISION,
+	FORMAT_TYPE_CHAR,
+	FORMAT_TYPE_STR,
+	FORMAT_TYPE_PTR,
+	FORMAT_TYPE_PERCENT_CHAR,
+	FORMAT_TYPE_INVALID,
+	FORMAT_TYPE_LONG_LONG,
+	FORMAT_TYPE_ULONG,
+	FORMAT_TYPE_LONG,
+	FORMAT_TYPE_UINT,
+	FORMAT_TYPE_INT,
+};
+
+struct printf_spec {
+	uint8_t	type;		/* format_type enum */
+	uint8_t	flags;		/* flags to number() */
+	uint8_t	base;		/* number base, 8, 10 or 16 only */
+	uint8_t	qualifier;	/* number qualifier, one of 'hHlLtzZ' */
+	int	field_width;	/* width of output field */
+	int	precision;	/* # of digits/chars */
+};
+
+static noinline_for_stack
+char *number(char *buf, char *end, unsigned long long num,
+	     struct printf_spec spec)
+{
+	/* we are called with base 8, 10 or 16, only, thus don't need "G..."  */
+	static const char digits[16] = "0123456789abcdef"; /* "GHIJKLMNOPQRSTUVWXYZ"; */
+
+	char tmp[sizeof(long long)*3 + 4];
+	char sign;
+	int need_pfx = ((spec.flags & SPECIAL) && spec.base != 10);
+	int i;
+
+	/* We may overflow the buf. Crudely check for it */
+	i = sizeof(long long)*3 + 4;
+	if (i < spec.field_width)
+		i = spec.field_width;
+	if ((end - buf) <= i)
+		return buf + i;
+
+//we don't use formats like "%-07u"
+//	if (spec.flags & LEFT)
+//		spec.flags &= ~ZEROPAD;
+	sign = 0;
+	if (spec.flags & SIGN) {
+		if ((signed long long)num < 0) {
+			sign = '-';
+			num = -(signed long long)num;
+			spec.field_width--;
+//		} else if (spec.flags & PLUS) {
+//			sign = '+';
+//			spec.field_width--;
+//		} else if (spec.flags & SPACE) {
+//			sign = ' ';
+//			spec.field_width--;
+		}
+	}
+	if (need_pfx) {
+		spec.field_width--;
+		if (spec.base == 16)
+			spec.field_width--;
+	}
+
+	/* generate full string in tmp[], in reverse order */
+	i = 0;
+	if (num < spec.base)
+		tmp[i++] = digits[num];
+	/* Generic code, for any base:
+	else do {
+		tmp[i++] = (digits[do_div(num,base)]);
+	} while (num != 0);
+	*/
+	else if (spec.base != 10) { /* 8 or 16 */
+		int mask = spec.base - 1;
+		int shift = 3;
+
+		if (spec.base == 16)
+			shift = 4;
+		do {
+			tmp[i++] = digits[((unsigned char)num) & mask];
+			num >>= shift;
+		} while (num);
+	} else { /* base 10 */
+		i = put_dec(tmp, num) - tmp;
+	}
+
+//spec.precision is assumed 0 ("not specified")
+//	/* printing 100 using %2d gives "100", not "00" */
+//	if (i > spec.precision)
+//		spec.precision = i;
+//	/* leading space padding */
+//	spec.field_width -= spec.precision;
+	spec.field_width -= i;
+	if (!(spec.flags & (ZEROPAD+LEFT))) {
+		while (--spec.field_width >= 0) {
+			///if (buf < end)
+				*buf = ' ';
+			++buf;
+		}
+	}
+	/* sign */
+	if (sign) {
+		///if (buf < end)
+			*buf = sign;
+		++buf;
+	}
+	/* "0x" / "0" prefix */
+	if (need_pfx) {
+		///if (buf < end)
+			*buf = '0';
+		++buf;
+		if (spec.base == 16) {
+			///if (buf < end)
+				*buf = 'x';
+			++buf;
+		}
+	}
+	/* zero or space padding */
+	if (!(spec.flags & LEFT)) {
+		char c = (spec.flags & ZEROPAD) ? '0' : ' ';
+		while (--spec.field_width >= 0) {
+			///if (buf < end)
+				*buf = c;
+			++buf;
+		}
+	}
+//	/* hmm even more zero padding? */
+//	while (i <= --spec.precision) {
+//		///if (buf < end)
+//			*buf = '0';
+//		++buf;
+//	}
+	/* actual digits of result */
+	while (--i >= 0) {
+		///if (buf < end)
+			*buf = tmp[i];
+		++buf;
+	}
+	/* trailing space padding */
+	while (--spec.field_width >= 0) {
+		///if (buf < end)
+			*buf = ' ';
+		++buf;
+	}
+
+	return buf;
+}
+
+static noinline_for_stack
+char *string(char *buf, char *end, const char *s, struct printf_spec spec)
+{
+	int len, i;
+
+	if (!s)
+		s = "(null)";
+
+	len = strnlen(s, spec.precision);
+
+	/* We may overflow the buf. Crudely check for it */
+	i = len;
+	if (i < spec.field_width)
+		i = spec.field_width;
+	if ((end - buf) <= i)
+		return buf + i;
+
+	if (!(spec.flags & LEFT)) {
+		while (len < spec.field_width--) {
+			///if (buf < end)
+				*buf = ' ';
+			++buf;
+		}
+	}
+	for (i = 0; i < len; ++i) {
+		///if (buf < end)
+			*buf = *s;
+		++buf; ++s;
+	}
+	while (len < spec.field_width--) {
+		///if (buf < end)
+			*buf = ' ';
+		++buf;
+	}
+
+	return buf;
+}
+
+static noinline_for_stack
+char *pointer(const char *fmt, char *buf, char *end, void *ptr,
+	      struct printf_spec spec)
+{
+//	spec.flags |= SMALL;
+	if (spec.field_width == -1) {
+		spec.field_width = 2 * sizeof(void *);
+		spec.flags |= ZEROPAD;
+	}
+	spec.base = 16;
+
+	return number(buf, end, (unsigned long) ptr, spec);
+}
+
+/*
+ * Helper function to decode printf style format.
+ * Each call decode a token from the format and return the
+ * number of characters read (or likely the delta where it wants
+ * to go on the next call).
+ * The decoded token is returned through the parameters
+ *
+ * 'h', 'l', or 'L' for integer fields
+ * 'z' support added 23/7/1999 S.H.
+ * 'z' changed to 'Z' --davidm 1/25/99
+ * 't' added for ptrdiff_t
+ *
+ * @fmt: the format string
+ * @type of the token returned
+ * @flags: various flags such as +, -, # tokens..
+ * @field_width: overwritten width
+ * @base: base of the number (octal, hex, ...)
+ * @precision: precision of a number
+ * @qualifier: qualifier of a number (long, size_t, ...)
+ */
+static noinline_for_stack
+int format_decode(const char *fmt, struct printf_spec *spec)
+{
+	const char *start = fmt;
+
+	/* we finished early by reading the field width */
+	if (spec->type == FORMAT_TYPE_WIDTH) {
+		if (spec->field_width < 0) {
+			spec->field_width = -spec->field_width;
+			spec->flags |= LEFT;
+		}
+		spec->type = FORMAT_TYPE_NONE;
+		goto precision;
+	}
+
+	/* we finished early by reading the precision */
+	if (spec->type == FORMAT_TYPE_PRECISION) {
+		if (spec->precision < 0)
+			spec->precision = 0;
+
+		spec->type = FORMAT_TYPE_NONE;
+		goto qualifier;
+	}
+
+	/* By default */
+	spec->type = FORMAT_TYPE_NONE;
+
+	for (;;) {
+		if (*fmt == '\0')
+			return fmt - start;
+		if (*fmt == '%')
+			break;
+		++fmt;
+	}
+
+	/* Return the current non-format string */
+	if (fmt != start)
+		return fmt - start;
+
+	/* Process flags */
+	spec->flags = 0;
+
+	while (1) { /* this also skips first '%' */
+		bool found = true;
+
+		++fmt;
+
+		switch (*fmt) {
+		case '-': spec->flags |= LEFT;    break;
+//		case '+': spec->flags |= PLUS;    break;
+//		case ' ': spec->flags |= SPACE;   break;
+		case '#': spec->flags |= SPECIAL; break;
+		case '0': spec->flags |= ZEROPAD; break;
+		default:  found = false;
+		}
+
+		if (!found)
+			break;
+	}
+
+	/* get field width */
+	spec->field_width = -1;
+
+	if (isdigit(*fmt))
+		spec->field_width = skip_atoi(&fmt);
+	else if (*fmt == '*') {
+		/* it's the next argument */
+		spec->type = FORMAT_TYPE_WIDTH;
+		return ++fmt - start;
+	}
+
+precision:
+	/* get the precision */
+	spec->precision = -1;
+	if (*fmt == '.') {
+		++fmt;
+		if (isdigit(*fmt)) {
+			spec->precision = skip_atoi(&fmt);
+//			if (spec->precision < 0)
+//				spec->precision = 0;
+		} else if (*fmt == '*') {
+			/* it's the next argument */
+			spec->type = FORMAT_TYPE_PRECISION;
+			return ++fmt - start;
+		}
+	}
+
+qualifier:
+	/* get the conversion qualifier */
+	spec->qualifier = -1;
+	if (*fmt == 'l') {
+		spec->qualifier = *fmt++;
+		if (unlikely(spec->qualifier == *fmt)) {
+			spec->qualifier = 'L';
+			++fmt;
+		}
+	}
+
+	/* default base */
+	spec->base = 10;
+	switch (*fmt) {
+	case 'c':
+		spec->type = FORMAT_TYPE_CHAR;
+		return ++fmt - start;
+
+	case 's':
+		spec->type = FORMAT_TYPE_STR;
+		return ++fmt - start;
+
+	case 'p':
+		spec->type = FORMAT_TYPE_PTR;
+		return ++fmt - start;
+
+	case '%':
+		spec->type = FORMAT_TYPE_PERCENT_CHAR;
+		return ++fmt - start;
+
+	/* integer number formats - set up the flags and "break" */
+	case 'o':
+		spec->base = 8;
+		break;
+
+	case 'x':
+//		spec->flags |= SMALL;
+
+	case 'X':
+		spec->base = 16;
+		break;
+
+	case 'd':
+	case 'i':
+		spec->flags |= SIGN;
+	case 'u':
+		break;
+
+	default:
+		spec->type = FORMAT_TYPE_INVALID;
+		return fmt - start;
+	}
+
+	if (spec->qualifier == 'L')
+		spec->type = FORMAT_TYPE_LONG_LONG;
+	else if (spec->qualifier == 'l') {
+		if (spec->flags & SIGN)
+			spec->type = FORMAT_TYPE_LONG;
+		else
+			spec->type = FORMAT_TYPE_ULONG;
+	} else {
+		if (spec->flags & SIGN)
+			spec->type = FORMAT_TYPE_INT;
+		else
+			spec->type = FORMAT_TYPE_UINT;
+	}
+
+	return ++fmt - start;
+}
+
+/**
+ * vsnprintf - Format a string and place it in a buffer
+ * @buf: The buffer to place the result into
+ * @size: The size of the buffer, including the trailing null space
+ * @fmt: The format string to use
+ * @args: Arguments for the format string
+ *
+ * The return value is the number of characters which would
+ * be generated for the given input, excluding the trailing
+ * '\0', as per ISO C99. If you want to have the exact
+ * number of characters written into @buf as return value
+ * (not including the trailing '\0'), use vscnprintf(). If the
+ * return is greater than or equal to @size, the resulting
+ * string is truncated.
+ *
+ * If you're not already dealing with a va_list consider using snprintf().
+ */
+static
+int kernel_vsnprintf(char *buf, size_t size, const char *fmt, va_list args)
+{
+	unsigned long long num;
+	char *str, *end;
+	struct printf_spec spec = {0};
+
+	str = buf;
+	end = buf + size;
+
+	while (*fmt) {
+		const char *old_fmt = fmt;
+		int read = format_decode(fmt, &spec);
+
+		fmt += read;
+
+		switch (spec.type) {
+		case FORMAT_TYPE_NONE: {
+			int copy = read;
+			if (str < end) {
+				if (copy > end - str)
+					copy = end - str;
+				memcpy(str, old_fmt, copy);
+			}
+			str += read;
+			break;
+		}
+
+		case FORMAT_TYPE_WIDTH:
+			spec.field_width = va_arg(args, int);
+			break;
+
+		case FORMAT_TYPE_PRECISION:
+			spec.precision = va_arg(args, int);
+			break;
+
+		case FORMAT_TYPE_CHAR: {
+			char c;
+
+			if (!(spec.flags & LEFT)) {
+				while (--spec.field_width > 0) {
+					if (str < end)
+						*str = ' ';
+					++str;
+
+				}
+			}
+			c = (unsigned char) va_arg(args, int);
+			if (str < end)
+				*str = c;
+			++str;
+			while (--spec.field_width > 0) {
+				if (str < end)
+					*str = ' ';
+				++str;
+			}
+			break;
+		}
+
+		case FORMAT_TYPE_STR:
+			str = string(str, end, va_arg(args, char *), spec);
+			break;
+
+		case FORMAT_TYPE_PTR:
+			str = pointer(fmt+1, str, end, va_arg(args, void *),
+				      spec);
+//			while (isalnum(*fmt))
+//				fmt++;
+			break;
+
+		case FORMAT_TYPE_PERCENT_CHAR:
+			if (str < end)
+				*str = '%';
+			++str;
+			break;
+
+		case FORMAT_TYPE_INVALID:
+			if (str < end)
+				*str = '%';
+			++str;
+			break;
+
+		default:
+			switch (spec.type) {
+			case FORMAT_TYPE_LONG_LONG:
+				num = va_arg(args, long long);
+				break;
+			case FORMAT_TYPE_ULONG:
+				num = va_arg(args, unsigned long);
+				break;
+			case FORMAT_TYPE_LONG:
+				num = va_arg(args, long);
+				break;
+			case FORMAT_TYPE_INT:
+				num = (int) va_arg(args, int);
+				break;
+			default:
+				num = va_arg(args, unsigned int);
+			}
+
+			str = number(str, end, num, spec);
+		}
+	}
+
+//	if (size > 0) {
+		if (str < end)
+			*str = '\0';
+//		else
+//			end[-1] = '\0';
+//	}
+
+	/* the trailing null byte doesn't count towards the total */
+	return str-buf;
+
+}
+
+int strace_vfprintf(FILE *fp, const char *fmt, va_list args)
+{
+	static char *buf = NULL;
+	static unsigned buflen = 0;
+
+	int r;
+	va_list a1;
+
+	va_copy(a1, args);
+	unsigned len = kernel_vsnprintf(buf, buflen, fmt, a1);
+	va_end(a1);
+
+	if (len >= buflen) {
+		buflen = len + 256;
+		free(buf);
+		buf = xmalloc(buflen);
+		/*len =*/ kernel_vsnprintf(buf, buflen, fmt, args);
+	}
+
+	r = fputs_unlocked(buf, fp);
+	if (r < 0) return r;
+	return len;
+}
+
+#endif /* USE_CUSTOM_PRINTF */
diff --git a/strace/wait.c b/strace/wait.c
new file mode 100644
index 0000000..64bd3b7
--- /dev/null
+++ b/strace/wait.c
@@ -0,0 +1,190 @@
+/*
+ * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
+ * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
+ * Copyright (c) 1993-1996 Rick Sladkey <jrs@world.std.com>
+ * Copyright (c) 1996-1999 Wichert Akkerman <wichert@cistron.nl>
+ * Copyright (c) 2002-2004 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2009-2013 Denys Vlasenko <dvlasenk@redhat.com>
+ * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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 <sys/wait.h>
+
+#include "xlat/wait4_options.h"
+
+#if !defined WCOREFLAG && defined WCOREFLG
+# define WCOREFLAG WCOREFLG
+#endif
+#ifndef WCOREFLAG
+# define WCOREFLAG 0x80
+#endif
+#ifndef WCOREDUMP
+# define WCOREDUMP(status)  ((status) & 0200)
+#endif
+#ifndef W_STOPCODE
+# define W_STOPCODE(sig)  ((sig) << 8 | 0x7f)
+#endif
+#ifndef W_EXITCODE
+# define W_EXITCODE(ret, sig)  ((ret) << 8 | (sig))
+#endif
+#ifndef W_CONTINUED
+# define W_CONTINUED 0xffff
+#endif
+
+#include "ptrace.h"
+#include "xlat/ptrace_events.h"
+
+static int
+printstatus(int status)
+{
+	int exited = 0;
+
+	/*
+	 * Here is a tricky presentation problem.  This solution
+	 * is still not entirely satisfactory but since there
+	 * are no wait status constructors it will have to do.
+	 */
+	if (WIFSTOPPED(status)) {
+		int sig = WSTOPSIG(status);
+		tprintf("[{WIFSTOPPED(s) && WSTOPSIG(s) == %s%s}",
+			signame(sig & 0x7f),
+			sig & 0x80 ? " | 0x80" : "");
+		status &= ~W_STOPCODE(sig);
+	}
+	else if (WIFSIGNALED(status)) {
+		tprintf("[{WIFSIGNALED(s) && WTERMSIG(s) == %s%s}",
+			signame(WTERMSIG(status)),
+			WCOREDUMP(status) ? " && WCOREDUMP(s)" : "");
+		status &= ~(W_EXITCODE(0, WTERMSIG(status)) | WCOREFLAG);
+	}
+	else if (WIFEXITED(status)) {
+		tprintf("[{WIFEXITED(s) && WEXITSTATUS(s) == %d}",
+			WEXITSTATUS(status));
+		exited = 1;
+		status &= ~W_EXITCODE(WEXITSTATUS(status), 0);
+	}
+#ifdef WIFCONTINUED
+	else if (WIFCONTINUED(status)) {
+		tprints("[{WIFCONTINUED(s)}");
+		status &= ~W_CONTINUED;
+	}
+#endif
+	else {
+		tprintf("[%#x]", status);
+		return 0;
+	}
+
+	if (status) {
+		unsigned int event = (unsigned int) status >> 16;
+		if (event) {
+			tprints(" | ");
+			printxval(ptrace_events, event, "PTRACE_EVENT_???");
+			tprints(" << 16");
+			status &= 0xffff;
+		}
+		if (status)
+			tprintf(" | %#x", status);
+	}
+	tprints("]");
+
+	return exited;
+}
+
+static int
+printwaitn(struct tcb *tcp, void (*const print_rusage)(struct tcb *, long))
+{
+	if (entering(tcp)) {
+		/* On Linux, kernel-side pid_t is typedef'ed to int
+		 * on all arches. Also, glibc-2.8 truncates wait3 and wait4
+		 * pid argument to int on 64bit arches, producing,
+		 * for example, wait4(4294967295, ...) instead of -1
+		 * in strace. We have to use int here, not long.
+		 */
+		int pid = tcp->u_arg[0];
+		tprintf("%d, ", pid);
+	} else {
+		int status;
+
+		/* status */
+		if (tcp->u_rval == 0)
+			printaddr(tcp->u_arg[1]);
+		else if (!umove_or_printaddr(tcp, tcp->u_arg[1], &status))
+			printstatus(status);
+		/* options */
+		tprints(", ");
+		printflags(wait4_options, tcp->u_arg[2], "W???");
+		if (print_rusage) {
+			/* usage */
+			tprints(", ");
+			if (tcp->u_rval > 0)
+				print_rusage(tcp, tcp->u_arg[3]);
+			else
+				printaddr(tcp->u_arg[3]);
+		}
+	}
+	return 0;
+}
+
+SYS_FUNC(waitpid)
+{
+	return printwaitn(tcp, NULL);
+}
+
+SYS_FUNC(wait4)
+{
+	return printwaitn(tcp, printrusage);
+}
+
+#ifdef ALPHA
+SYS_FUNC(osf_wait4)
+{
+	return printwaitn(tcp, printrusage32);
+}
+#endif
+
+#include "xlat/waitid_types.h"
+
+SYS_FUNC(waitid)
+{
+	if (entering(tcp)) {
+		printxval(waitid_types, tcp->u_arg[0], "P_???");
+		int pid = tcp->u_arg[1];
+		tprintf(", %d, ", pid);
+	} else {
+		/* siginfo */
+		printsiginfo_at(tcp, tcp->u_arg[2]);
+		/* options */
+		tprints(", ");
+		printflags(wait4_options, tcp->u_arg[3], "W???");
+		/* usage */
+		tprints(", ");
+		printrusage(tcp, tcp->u_arg[4]);
+	}
+	return 0;
+}
diff --git a/strace/xattr.c b/strace/xattr.c
new file mode 100644
index 0000000..30a8467
--- /dev/null
+++ b/strace/xattr.c
@@ -0,0 +1,157 @@
+/*
+ * Copyright (c) 2002-2005 Roland McGrath <roland@redhat.com>
+ * Copyright (c) 2004 Ulrich Drepper <drepper@redhat.com>
+ * Copyright (c) 2005-2016 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+#ifdef HAVE_SYS_XATTR_H
+# include <sys/xattr.h>
+#endif
+
+#include "xlat/xattrflags.h"
+
+#ifndef XATTR_SIZE_MAX
+# define XATTR_SIZE_MAX 65536
+#endif
+
+static void
+print_xattr_val(struct tcb *tcp,
+		unsigned long addr,
+		unsigned long insize,
+		unsigned long size)
+{
+	static char buf[XATTR_SIZE_MAX];
+
+	tprints(", ");
+
+	if (!addr || size > sizeof(buf))
+		printaddr(addr);
+	else if (!size || !umoven_or_printaddr(tcp, addr, size, buf)) {
+		/* Don't print terminating NUL if there is one. */
+		if (size && buf[size - 1] == '\0')
+			--size;
+
+		print_quoted_string(buf, size, 0);
+	}
+	tprintf(", %lu", insize);
+}
+
+SYS_FUNC(setxattr)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], -1);
+	print_xattr_val(tcp, tcp->u_arg[2], tcp->u_arg[3], tcp->u_arg[3]);
+	tprints(", ");
+	printflags(xattrflags, tcp->u_arg[4], "XATTR_???");
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fsetxattr)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], -1);
+	print_xattr_val(tcp, tcp->u_arg[2], tcp->u_arg[3], tcp->u_arg[3]);
+	tprints(", ");
+	printflags(xattrflags, tcp->u_arg[4], "XATTR_???");
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(getxattr)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		printstr(tcp, tcp->u_arg[1], -1);
+	} else {
+		print_xattr_val(tcp, tcp->u_arg[2], tcp->u_arg[3], tcp->u_rval);
+	}
+	return 0;
+}
+
+SYS_FUNC(fgetxattr)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+		printstr(tcp, tcp->u_arg[1], -1);
+	} else {
+		print_xattr_val(tcp, tcp->u_arg[2], tcp->u_arg[3], tcp->u_rval);
+	}
+	return 0;
+}
+
+static void
+print_xattr_list(struct tcb *tcp, unsigned long addr, unsigned long size)
+{
+	if (!size || syserror(tcp)) {
+		printaddr(addr);
+	} else {
+		printstr(tcp, addr, tcp->u_rval);
+	}
+	tprintf(", %lu", size);
+}
+
+SYS_FUNC(listxattr)
+{
+	if (entering(tcp)) {
+		printpath(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_xattr_list(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(flistxattr)
+{
+	if (entering(tcp)) {
+		printfd(tcp, tcp->u_arg[0]);
+		tprints(", ");
+	} else {
+		print_xattr_list(tcp, tcp->u_arg[1], tcp->u_arg[2]);
+	}
+	return 0;
+}
+
+SYS_FUNC(removexattr)
+{
+	printpath(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], -1);
+	return RVAL_DECODED;
+}
+
+SYS_FUNC(fremovexattr)
+{
+	printfd(tcp, tcp->u_arg[0]);
+	tprints(", ");
+	printstr(tcp, tcp->u_arg[1], -1);
+	return RVAL_DECODED;
+}
diff --git a/strace/xlat.h b/strace/xlat.h
new file mode 100644
index 0000000..2f7643c
--- /dev/null
+++ b/strace/xlat.h
@@ -0,0 +1,16 @@
+#ifndef STRACE_XLAT_H
+
+# include <stdint.h>
+
+struct xlat {
+	uint64_t val;
+	const char *str;
+};
+
+# define XLAT(val)			{ (unsigned)(val), #val }
+# define XLAT_PAIR(val, str)		{ (unsigned)(val), str  }
+# define XLAT_TYPE(type, val)		{     (type)(val), #val }
+# define XLAT_TYPE_PAIR(type, val, str)	{     (type)(val), str  }
+# define XLAT_END			{		0, 0    }
+
+#endif
diff --git a/strace/xlat/Makemodule.am b/strace/xlat/Makemodule.am
new file mode 100644
index 0000000..06db6bd
--- /dev/null
+++ b/strace/xlat/Makemodule.am
@@ -0,0 +1,582 @@
+XLAT_INPUT_FILES = xlat/access_flags.in xlat/aclipc.in xlat/addrfams.in xlat/adjtimex_modes.in xlat/adjtimex_state.in xlat/adjtimex_status.in xlat/advise.in xlat/af_packet_types.in xlat/archvals.in xlat/arp_hardware_types.in xlat/at_flags.in xlat/atomic_ops.in xlat/audit_arch.in xlat/baud_options.in xlat/blkpg_ops.in xlat/bootflags1.in xlat/bootflags2.in xlat/bootflags3.in xlat/bpf_class.in xlat/bpf_commands.in xlat/bpf_map_types.in xlat/bpf_map_update_elem_flags.in xlat/bpf_miscop.in xlat/bpf_mode.in xlat/bpf_op_alu.in xlat/bpf_op_jmp.in xlat/bpf_prog_types.in xlat/bpf_rval.in xlat/bpf_size.in xlat/bpf_src.in xlat/bsg_protocol.in xlat/bsg_subprotocol.in xlat/bt_protocols.in xlat/btrfs_balance_args.in xlat/btrfs_balance_ctl_cmds.in xlat/btrfs_balance_flags.in xlat/btrfs_balance_state.in xlat/btrfs_compress_types.in xlat/btrfs_defrag_flags.in xlat/btrfs_dev_replace_cmds.in xlat/btrfs_dev_replace_results.in xlat/btrfs_dev_replace_state.in xlat/btrfs_dev_stats_flags.in xlat/btrfs_dev_stats_values.in xlat/btrfs_features_compat.in xlat/btrfs_features_compat_ro.in xlat/btrfs_features_incompat.in xlat/btrfs_key_types.in xlat/btrfs_qgroup_ctl_cmds.in xlat/btrfs_qgroup_inherit_flags.in xlat/btrfs_qgroup_limit_flags.in xlat/btrfs_qgroup_status_flags.in xlat/btrfs_scrub_flags.in xlat/btrfs_send_flags.in xlat/btrfs_snap_flags_v2.in xlat/btrfs_space_info_flags.in xlat/btrfs_tree_objectids.in xlat/cacheflush_scope.in xlat/cap.in xlat/cap_mask0.in xlat/cap_mask1.in xlat/cap_version.in xlat/clockflags.in xlat/clocknames.in xlat/clone_flags.in xlat/cpuclocknames.in xlat/delete_module_flags.in xlat/dirent_types.in xlat/efd_flags.in xlat/epollctls.in xlat/epollevents.in xlat/epollflags.in xlat/ethernet_protocols.in xlat/evdev_abs.in xlat/evdev_autorepeat.in xlat/evdev_ev.in xlat/evdev_ff_status.in xlat/evdev_ff_types.in xlat/evdev_keycode.in xlat/evdev_leds.in xlat/evdev_misc.in xlat/evdev_mtslots.in xlat/evdev_prop.in xlat/evdev_relative_axes.in xlat/evdev_snd.in xlat/evdev_switch.in xlat/evdev_sync.in xlat/falloc_flags.in xlat/fan_classes.in xlat/fan_event_flags.in xlat/fan_init_flags.in xlat/fan_mark_flags.in xlat/fcntl64cmds.in xlat/fcntlcmds.in xlat/fdflags.in xlat/fiemap_extent_flags.in xlat/fiemap_flags.in xlat/flockcmds.in xlat/f_owner_types.in xlat/f_seals.in xlat/fsmagic.in xlat/futexops.in xlat/futexwakecmps.in xlat/futexwakeops.in xlat/getrandom_flags.in xlat/getsockipoptions.in xlat/getsockipv6options.in xlat/hci_channels.in xlat/icmpfilterflags.in xlat/if_dqblk_valid.in xlat/if_dqinfo_flags.in xlat/if_dqinfo_valid.in xlat/iffflags.in xlat/inet_protocols.in xlat/inotify_flags.in xlat/inotify_init_flags.in xlat/ioctl_dirs.in xlat/ioprio_class.in xlat/ioprio_who.in xlat/ipccalls.in xlat/ipc_msg_flags.in xlat/ip_cmsg_types.in xlat/itimer_which.in xlat/kcmp_types.in xlat/kexec_arch_values.in xlat/kexec_file_load_flags.in xlat/kexec_load_flags.in xlat/keyctl_commands.in xlat/key_perms.in xlat/key_reqkeys.in xlat/key_spec.in xlat/lockfcmds.in xlat/loop_crypt_type_options.in xlat/loop_flags_options.in xlat/madvise_cmds.in xlat/mbindflags.in xlat/mctl_sync.in xlat/membarrier_cmds.in xlat/memfd_create_flags.in xlat/mempolicyflags.in xlat/mlockall_flags.in xlat/mlock_flags.in xlat/mmap_flags.in xlat/mmap_prot.in xlat/modem_flags.in xlat/modetypes.in xlat/module_init_flags.in xlat/mount_flags.in xlat/move_pages_flags.in xlat/mremap_flags.in xlat/msgctl_flags.in xlat/msg_flags.in xlat/mtd_file_mode_options.in xlat/mtd_flags_options.in xlat/mtd_mode_options.in xlat/mtd_nandecc_options.in xlat/mtd_otp_options.in xlat/mtd_type_options.in xlat/netlink_flags.in xlat/netlink_protocols.in xlat/netlink_types.in xlat/notifyflags.in xlat/nt_descriptor_types.in xlat/open_access_modes.in xlat/open_mode_flags.in xlat/openmodessol.in xlat/packet_mreq_type.in xlat/perf_event_open_flags.in xlat/personality_flags.in xlat/personality_types.in xlat/policies.in xlat/pollflags.in xlat/pr_cap_ambient.in xlat/prctl_options.in xlat/priorities.in xlat/pr_mce_kill.in xlat/pr_mce_kill_policy.in xlat/pr_set_mm.in xlat/pr_tsc.in xlat/pr_unalign_flags.in xlat/ptp_flags_options.in xlat/ptrace_cmds.in xlat/ptrace_events.in xlat/ptrace_peeksiginfo_flags.in xlat/ptrace_setoptions_flags.in xlat/quotacmds.in xlat/quota_formats.in xlat/quotatypes.in xlat/rename_flags.in xlat/resource_flags.in xlat/resources.in xlat/rwf_flags.in xlat/sched_flags.in xlat/schedulers.in xlat/scmvals.in xlat/secbits.in xlat/seccomp_filter_flags.in xlat/seccomp_mode.in xlat/seccomp_ops.in xlat/seccomp_ret_action.in xlat/semctl_flags.in xlat/semop_flags.in xlat/setsockipoptions.in xlat/setsockipv6options.in xlat/sfd_flags.in xlat/sg_io_dxfer_direction.in xlat/shmctl_flags.in xlat/shm_flags.in xlat/shm_resource_flags.in xlat/shutdown_modes.in xlat/sigact_flags.in xlat/sigaltstack_flags.in xlat/sigbus_codes.in xlat/sigchld_codes.in xlat/sigemt_codes.in xlat/sigev_value.in xlat/sigfpe_codes.in xlat/sigill_codes.in xlat/siginfo_codes.in xlat/sigpoll_codes.in xlat/sigprocmaskcmds.in xlat/sigprof_codes.in xlat/sigsegv_codes.in xlat/sigsys_codes.in xlat/sigtrap_codes.in xlat/socketcalls.in xlat/socketlayers.in xlat/sockipoptions.in xlat/sockipv6options.in xlat/sockipxoptions.in xlat/sockoptions.in xlat/sockpacketoptions.in xlat/sockrawoptions.in xlat/socksctpoptions.in xlat/socktcpoptions.in xlat/sock_type_flags.in xlat/socktypes.in xlat/splice_flags.in xlat/sram_alloc_flags.in xlat/statfs_flags.in xlat/swap_flags.in xlat/sync_file_range_flags.in xlat/sysctl_kern.in xlat/sysctl_net_core.in xlat/sysctl_net.in xlat/sysctl_net_ipv4_conf.in xlat/sysctl_net_ipv4.in xlat/sysctl_net_ipv4_route.in xlat/sysctl_net_ipv6.in xlat/sysctl_net_ipv6_route.in xlat/sysctl_net_unix.in xlat/sysctl_root.in xlat/sysctl_vm.in xlat/syslog_action_type.in xlat/sysmips_operations.in xlat/tcflsh_options.in xlat/tcxonc_options.in xlat/timerfdflags.in xlat/ubi_volume_props.in xlat/ubi_volume_types.in xlat/uffd_api_flags.in xlat/uffd_copy_flags.in xlat/uffd_flags.in xlat/uffd_register_ioctl_flags.in xlat/uffd_register_mode_flags.in xlat/uffd_zeropage_flags.in xlat/umount_flags.in xlat/usagewho.in xlat/v4l2_buf_flags.in xlat/v4l2_buf_types.in xlat/v4l2_capture_modes.in xlat/v4l2_colorspaces.in xlat/v4l2_control_classes.in xlat/v4l2_control_flags.in xlat/v4l2_control_ids.in xlat/v4l2_control_types.in xlat/v4l2_device_capabilities_flags.in xlat/v4l2_fields.in xlat/v4l2_format_description_flags.in xlat/v4l2_frameinterval_types.in xlat/v4l2_framesize_types.in xlat/v4l2_input_types.in xlat/v4l2_memories.in xlat/v4l2_streaming_capabilities.in xlat/wait4_options.in xlat/waitid_types.in xlat/whence_codes.in xlat/xattrflags.in xlat/xfs_dqblk_flags.in xlat/xfs_quota_flags.in 
+XLAT_HEADER_FILES = xlat/access_flags.h xlat/aclipc.h xlat/addrfams.h xlat/adjtimex_modes.h xlat/adjtimex_state.h xlat/adjtimex_status.h xlat/advise.h xlat/af_packet_types.h xlat/archvals.h xlat/arp_hardware_types.h xlat/at_flags.h xlat/atomic_ops.h xlat/audit_arch.h xlat/baud_options.h xlat/blkpg_ops.h xlat/bootflags1.h xlat/bootflags2.h xlat/bootflags3.h xlat/bpf_class.h xlat/bpf_commands.h xlat/bpf_map_types.h xlat/bpf_map_update_elem_flags.h xlat/bpf_miscop.h xlat/bpf_mode.h xlat/bpf_op_alu.h xlat/bpf_op_jmp.h xlat/bpf_prog_types.h xlat/bpf_rval.h xlat/bpf_size.h xlat/bpf_src.h xlat/bsg_protocol.h xlat/bsg_subprotocol.h xlat/bt_protocols.h xlat/btrfs_balance_args.h xlat/btrfs_balance_ctl_cmds.h xlat/btrfs_balance_flags.h xlat/btrfs_balance_state.h xlat/btrfs_compress_types.h xlat/btrfs_defrag_flags.h xlat/btrfs_dev_replace_cmds.h xlat/btrfs_dev_replace_results.h xlat/btrfs_dev_replace_state.h xlat/btrfs_dev_stats_flags.h xlat/btrfs_dev_stats_values.h xlat/btrfs_features_compat.h xlat/btrfs_features_compat_ro.h xlat/btrfs_features_incompat.h xlat/btrfs_key_types.h xlat/btrfs_qgroup_ctl_cmds.h xlat/btrfs_qgroup_inherit_flags.h xlat/btrfs_qgroup_limit_flags.h xlat/btrfs_qgroup_status_flags.h xlat/btrfs_scrub_flags.h xlat/btrfs_send_flags.h xlat/btrfs_snap_flags_v2.h xlat/btrfs_space_info_flags.h xlat/btrfs_tree_objectids.h xlat/cacheflush_scope.h xlat/cap.h xlat/cap_mask0.h xlat/cap_mask1.h xlat/cap_version.h xlat/clockflags.h xlat/clocknames.h xlat/clone_flags.h xlat/cpuclocknames.h xlat/delete_module_flags.h xlat/dirent_types.h xlat/efd_flags.h xlat/epollctls.h xlat/epollevents.h xlat/epollflags.h xlat/ethernet_protocols.h xlat/evdev_abs.h xlat/evdev_autorepeat.h xlat/evdev_ev.h xlat/evdev_ff_status.h xlat/evdev_ff_types.h xlat/evdev_keycode.h xlat/evdev_leds.h xlat/evdev_misc.h xlat/evdev_mtslots.h xlat/evdev_prop.h xlat/evdev_relative_axes.h xlat/evdev_snd.h xlat/evdev_switch.h xlat/evdev_sync.h xlat/falloc_flags.h xlat/fan_classes.h xlat/fan_event_flags.h xlat/fan_init_flags.h xlat/fan_mark_flags.h xlat/fcntl64cmds.h xlat/fcntlcmds.h xlat/fdflags.h xlat/fiemap_extent_flags.h xlat/fiemap_flags.h xlat/flockcmds.h xlat/f_owner_types.h xlat/f_seals.h xlat/fsmagic.h xlat/futexops.h xlat/futexwakecmps.h xlat/futexwakeops.h xlat/getrandom_flags.h xlat/getsockipoptions.h xlat/getsockipv6options.h xlat/hci_channels.h xlat/icmpfilterflags.h xlat/if_dqblk_valid.h xlat/if_dqinfo_flags.h xlat/if_dqinfo_valid.h xlat/iffflags.h xlat/inet_protocols.h xlat/inotify_flags.h xlat/inotify_init_flags.h xlat/ioctl_dirs.h xlat/ioprio_class.h xlat/ioprio_who.h xlat/ipccalls.h xlat/ipc_msg_flags.h xlat/ip_cmsg_types.h xlat/itimer_which.h xlat/kcmp_types.h xlat/kexec_arch_values.h xlat/kexec_file_load_flags.h xlat/kexec_load_flags.h xlat/keyctl_commands.h xlat/key_perms.h xlat/key_reqkeys.h xlat/key_spec.h xlat/lockfcmds.h xlat/loop_crypt_type_options.h xlat/loop_flags_options.h xlat/madvise_cmds.h xlat/mbindflags.h xlat/mctl_sync.h xlat/membarrier_cmds.h xlat/memfd_create_flags.h xlat/mempolicyflags.h xlat/mlockall_flags.h xlat/mlock_flags.h xlat/mmap_flags.h xlat/mmap_prot.h xlat/modem_flags.h xlat/modetypes.h xlat/module_init_flags.h xlat/mount_flags.h xlat/move_pages_flags.h xlat/mremap_flags.h xlat/msgctl_flags.h xlat/msg_flags.h xlat/mtd_file_mode_options.h xlat/mtd_flags_options.h xlat/mtd_mode_options.h xlat/mtd_nandecc_options.h xlat/mtd_otp_options.h xlat/mtd_type_options.h xlat/netlink_flags.h xlat/netlink_protocols.h xlat/netlink_types.h xlat/notifyflags.h xlat/nt_descriptor_types.h xlat/open_access_modes.h xlat/open_mode_flags.h xlat/openmodessol.h xlat/packet_mreq_type.h xlat/perf_event_open_flags.h xlat/personality_flags.h xlat/personality_types.h xlat/policies.h xlat/pollflags.h xlat/pr_cap_ambient.h xlat/prctl_options.h xlat/priorities.h xlat/pr_mce_kill.h xlat/pr_mce_kill_policy.h xlat/pr_set_mm.h xlat/pr_tsc.h xlat/pr_unalign_flags.h xlat/ptp_flags_options.h xlat/ptrace_cmds.h xlat/ptrace_events.h xlat/ptrace_peeksiginfo_flags.h xlat/ptrace_setoptions_flags.h xlat/quotacmds.h xlat/quota_formats.h xlat/quotatypes.h xlat/rename_flags.h xlat/resource_flags.h xlat/resources.h xlat/rwf_flags.h xlat/sched_flags.h xlat/schedulers.h xlat/scmvals.h xlat/secbits.h xlat/seccomp_filter_flags.h xlat/seccomp_mode.h xlat/seccomp_ops.h xlat/seccomp_ret_action.h xlat/semctl_flags.h xlat/semop_flags.h xlat/setsockipoptions.h xlat/setsockipv6options.h xlat/sfd_flags.h xlat/sg_io_dxfer_direction.h xlat/shmctl_flags.h xlat/shm_flags.h xlat/shm_resource_flags.h xlat/shutdown_modes.h xlat/sigact_flags.h xlat/sigaltstack_flags.h xlat/sigbus_codes.h xlat/sigchld_codes.h xlat/sigemt_codes.h xlat/sigev_value.h xlat/sigfpe_codes.h xlat/sigill_codes.h xlat/siginfo_codes.h xlat/sigpoll_codes.h xlat/sigprocmaskcmds.h xlat/sigprof_codes.h xlat/sigsegv_codes.h xlat/sigsys_codes.h xlat/sigtrap_codes.h xlat/socketcalls.h xlat/socketlayers.h xlat/sockipoptions.h xlat/sockipv6options.h xlat/sockipxoptions.h xlat/sockoptions.h xlat/sockpacketoptions.h xlat/sockrawoptions.h xlat/socksctpoptions.h xlat/socktcpoptions.h xlat/sock_type_flags.h xlat/socktypes.h xlat/splice_flags.h xlat/sram_alloc_flags.h xlat/statfs_flags.h xlat/swap_flags.h xlat/sync_file_range_flags.h xlat/sysctl_kern.h xlat/sysctl_net_core.h xlat/sysctl_net.h xlat/sysctl_net_ipv4_conf.h xlat/sysctl_net_ipv4.h xlat/sysctl_net_ipv4_route.h xlat/sysctl_net_ipv6.h xlat/sysctl_net_ipv6_route.h xlat/sysctl_net_unix.h xlat/sysctl_root.h xlat/sysctl_vm.h xlat/syslog_action_type.h xlat/sysmips_operations.h xlat/tcflsh_options.h xlat/tcxonc_options.h xlat/timerfdflags.h xlat/ubi_volume_props.h xlat/ubi_volume_types.h xlat/uffd_api_flags.h xlat/uffd_copy_flags.h xlat/uffd_flags.h xlat/uffd_register_ioctl_flags.h xlat/uffd_register_mode_flags.h xlat/uffd_zeropage_flags.h xlat/umount_flags.h xlat/usagewho.h xlat/v4l2_buf_flags.h xlat/v4l2_buf_types.h xlat/v4l2_capture_modes.h xlat/v4l2_colorspaces.h xlat/v4l2_control_classes.h xlat/v4l2_control_flags.h xlat/v4l2_control_ids.h xlat/v4l2_control_types.h xlat/v4l2_device_capabilities_flags.h xlat/v4l2_fields.h xlat/v4l2_format_description_flags.h xlat/v4l2_frameinterval_types.h xlat/v4l2_framesize_types.h xlat/v4l2_input_types.h xlat/v4l2_memories.h xlat/v4l2_streaming_capabilities.h xlat/wait4_options.h xlat/waitid_types.h xlat/whence_codes.h xlat/xattrflags.h xlat/xfs_dqblk_flags.h xlat/xfs_quota_flags.h 
+$(top_srcdir)/xlat/access_flags.h: $(top_srcdir)/xlat/access_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/aclipc.h: $(top_srcdir)/xlat/aclipc.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/addrfams.h: $(top_srcdir)/xlat/addrfams.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/adjtimex_modes.h: $(top_srcdir)/xlat/adjtimex_modes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/adjtimex_state.h: $(top_srcdir)/xlat/adjtimex_state.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/adjtimex_status.h: $(top_srcdir)/xlat/adjtimex_status.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/advise.h: $(top_srcdir)/xlat/advise.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/af_packet_types.h: $(top_srcdir)/xlat/af_packet_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/archvals.h: $(top_srcdir)/xlat/archvals.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/arp_hardware_types.h: $(top_srcdir)/xlat/arp_hardware_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/at_flags.h: $(top_srcdir)/xlat/at_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/atomic_ops.h: $(top_srcdir)/xlat/atomic_ops.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/audit_arch.h: $(top_srcdir)/xlat/audit_arch.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/baud_options.h: $(top_srcdir)/xlat/baud_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/blkpg_ops.h: $(top_srcdir)/xlat/blkpg_ops.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bootflags1.h: $(top_srcdir)/xlat/bootflags1.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bootflags2.h: $(top_srcdir)/xlat/bootflags2.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bootflags3.h: $(top_srcdir)/xlat/bootflags3.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_class.h: $(top_srcdir)/xlat/bpf_class.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_commands.h: $(top_srcdir)/xlat/bpf_commands.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_map_types.h: $(top_srcdir)/xlat/bpf_map_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_map_update_elem_flags.h: $(top_srcdir)/xlat/bpf_map_update_elem_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_miscop.h: $(top_srcdir)/xlat/bpf_miscop.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_mode.h: $(top_srcdir)/xlat/bpf_mode.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_op_alu.h: $(top_srcdir)/xlat/bpf_op_alu.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_op_jmp.h: $(top_srcdir)/xlat/bpf_op_jmp.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_prog_types.h: $(top_srcdir)/xlat/bpf_prog_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_rval.h: $(top_srcdir)/xlat/bpf_rval.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_size.h: $(top_srcdir)/xlat/bpf_size.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bpf_src.h: $(top_srcdir)/xlat/bpf_src.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bsg_protocol.h: $(top_srcdir)/xlat/bsg_protocol.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bsg_subprotocol.h: $(top_srcdir)/xlat/bsg_subprotocol.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/bt_protocols.h: $(top_srcdir)/xlat/bt_protocols.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_balance_args.h: $(top_srcdir)/xlat/btrfs_balance_args.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_balance_ctl_cmds.h: $(top_srcdir)/xlat/btrfs_balance_ctl_cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_balance_flags.h: $(top_srcdir)/xlat/btrfs_balance_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_balance_state.h: $(top_srcdir)/xlat/btrfs_balance_state.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_compress_types.h: $(top_srcdir)/xlat/btrfs_compress_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_defrag_flags.h: $(top_srcdir)/xlat/btrfs_defrag_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_dev_replace_cmds.h: $(top_srcdir)/xlat/btrfs_dev_replace_cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_dev_replace_results.h: $(top_srcdir)/xlat/btrfs_dev_replace_results.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_dev_replace_state.h: $(top_srcdir)/xlat/btrfs_dev_replace_state.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_dev_stats_flags.h: $(top_srcdir)/xlat/btrfs_dev_stats_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_dev_stats_values.h: $(top_srcdir)/xlat/btrfs_dev_stats_values.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_features_compat.h: $(top_srcdir)/xlat/btrfs_features_compat.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_features_compat_ro.h: $(top_srcdir)/xlat/btrfs_features_compat_ro.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_features_incompat.h: $(top_srcdir)/xlat/btrfs_features_incompat.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_key_types.h: $(top_srcdir)/xlat/btrfs_key_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_qgroup_ctl_cmds.h: $(top_srcdir)/xlat/btrfs_qgroup_ctl_cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_qgroup_inherit_flags.h: $(top_srcdir)/xlat/btrfs_qgroup_inherit_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_qgroup_limit_flags.h: $(top_srcdir)/xlat/btrfs_qgroup_limit_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_qgroup_status_flags.h: $(top_srcdir)/xlat/btrfs_qgroup_status_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_scrub_flags.h: $(top_srcdir)/xlat/btrfs_scrub_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_send_flags.h: $(top_srcdir)/xlat/btrfs_send_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_snap_flags_v2.h: $(top_srcdir)/xlat/btrfs_snap_flags_v2.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_space_info_flags.h: $(top_srcdir)/xlat/btrfs_space_info_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/btrfs_tree_objectids.h: $(top_srcdir)/xlat/btrfs_tree_objectids.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/cacheflush_scope.h: $(top_srcdir)/xlat/cacheflush_scope.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/cap.h: $(top_srcdir)/xlat/cap.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/cap_mask0.h: $(top_srcdir)/xlat/cap_mask0.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/cap_mask1.h: $(top_srcdir)/xlat/cap_mask1.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/cap_version.h: $(top_srcdir)/xlat/cap_version.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/clockflags.h: $(top_srcdir)/xlat/clockflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/clocknames.h: $(top_srcdir)/xlat/clocknames.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/clone_flags.h: $(top_srcdir)/xlat/clone_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/cpuclocknames.h: $(top_srcdir)/xlat/cpuclocknames.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/delete_module_flags.h: $(top_srcdir)/xlat/delete_module_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/dirent_types.h: $(top_srcdir)/xlat/dirent_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/efd_flags.h: $(top_srcdir)/xlat/efd_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/epollctls.h: $(top_srcdir)/xlat/epollctls.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/epollevents.h: $(top_srcdir)/xlat/epollevents.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/epollflags.h: $(top_srcdir)/xlat/epollflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ethernet_protocols.h: $(top_srcdir)/xlat/ethernet_protocols.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_abs.h: $(top_srcdir)/xlat/evdev_abs.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_autorepeat.h: $(top_srcdir)/xlat/evdev_autorepeat.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_ev.h: $(top_srcdir)/xlat/evdev_ev.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_ff_status.h: $(top_srcdir)/xlat/evdev_ff_status.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_ff_types.h: $(top_srcdir)/xlat/evdev_ff_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_keycode.h: $(top_srcdir)/xlat/evdev_keycode.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_leds.h: $(top_srcdir)/xlat/evdev_leds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_misc.h: $(top_srcdir)/xlat/evdev_misc.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_mtslots.h: $(top_srcdir)/xlat/evdev_mtslots.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_prop.h: $(top_srcdir)/xlat/evdev_prop.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_relative_axes.h: $(top_srcdir)/xlat/evdev_relative_axes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_snd.h: $(top_srcdir)/xlat/evdev_snd.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_switch.h: $(top_srcdir)/xlat/evdev_switch.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/evdev_sync.h: $(top_srcdir)/xlat/evdev_sync.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/falloc_flags.h: $(top_srcdir)/xlat/falloc_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fan_classes.h: $(top_srcdir)/xlat/fan_classes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fan_event_flags.h: $(top_srcdir)/xlat/fan_event_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fan_init_flags.h: $(top_srcdir)/xlat/fan_init_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fan_mark_flags.h: $(top_srcdir)/xlat/fan_mark_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fcntl64cmds.h: $(top_srcdir)/xlat/fcntl64cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fcntlcmds.h: $(top_srcdir)/xlat/fcntlcmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fdflags.h: $(top_srcdir)/xlat/fdflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fiemap_extent_flags.h: $(top_srcdir)/xlat/fiemap_extent_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fiemap_flags.h: $(top_srcdir)/xlat/fiemap_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/flockcmds.h: $(top_srcdir)/xlat/flockcmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/f_owner_types.h: $(top_srcdir)/xlat/f_owner_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/f_seals.h: $(top_srcdir)/xlat/f_seals.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/fsmagic.h: $(top_srcdir)/xlat/fsmagic.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/futexops.h: $(top_srcdir)/xlat/futexops.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/futexwakecmps.h: $(top_srcdir)/xlat/futexwakecmps.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/futexwakeops.h: $(top_srcdir)/xlat/futexwakeops.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/getrandom_flags.h: $(top_srcdir)/xlat/getrandom_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/getsockipoptions.h: $(top_srcdir)/xlat/getsockipoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/getsockipv6options.h: $(top_srcdir)/xlat/getsockipv6options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/hci_channels.h: $(top_srcdir)/xlat/hci_channels.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/icmpfilterflags.h: $(top_srcdir)/xlat/icmpfilterflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/if_dqblk_valid.h: $(top_srcdir)/xlat/if_dqblk_valid.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/if_dqinfo_flags.h: $(top_srcdir)/xlat/if_dqinfo_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/if_dqinfo_valid.h: $(top_srcdir)/xlat/if_dqinfo_valid.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/iffflags.h: $(top_srcdir)/xlat/iffflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/inet_protocols.h: $(top_srcdir)/xlat/inet_protocols.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/inotify_flags.h: $(top_srcdir)/xlat/inotify_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/inotify_init_flags.h: $(top_srcdir)/xlat/inotify_init_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ioctl_dirs.h: $(top_srcdir)/xlat/ioctl_dirs.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ioprio_class.h: $(top_srcdir)/xlat/ioprio_class.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ioprio_who.h: $(top_srcdir)/xlat/ioprio_who.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ipccalls.h: $(top_srcdir)/xlat/ipccalls.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ipc_msg_flags.h: $(top_srcdir)/xlat/ipc_msg_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ip_cmsg_types.h: $(top_srcdir)/xlat/ip_cmsg_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/itimer_which.h: $(top_srcdir)/xlat/itimer_which.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/kcmp_types.h: $(top_srcdir)/xlat/kcmp_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/kexec_arch_values.h: $(top_srcdir)/xlat/kexec_arch_values.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/kexec_file_load_flags.h: $(top_srcdir)/xlat/kexec_file_load_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/kexec_load_flags.h: $(top_srcdir)/xlat/kexec_load_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/keyctl_commands.h: $(top_srcdir)/xlat/keyctl_commands.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/key_perms.h: $(top_srcdir)/xlat/key_perms.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/key_reqkeys.h: $(top_srcdir)/xlat/key_reqkeys.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/key_spec.h: $(top_srcdir)/xlat/key_spec.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/lockfcmds.h: $(top_srcdir)/xlat/lockfcmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/loop_crypt_type_options.h: $(top_srcdir)/xlat/loop_crypt_type_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/loop_flags_options.h: $(top_srcdir)/xlat/loop_flags_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/madvise_cmds.h: $(top_srcdir)/xlat/madvise_cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mbindflags.h: $(top_srcdir)/xlat/mbindflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mctl_sync.h: $(top_srcdir)/xlat/mctl_sync.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/membarrier_cmds.h: $(top_srcdir)/xlat/membarrier_cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/memfd_create_flags.h: $(top_srcdir)/xlat/memfd_create_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mempolicyflags.h: $(top_srcdir)/xlat/mempolicyflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mlockall_flags.h: $(top_srcdir)/xlat/mlockall_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mlock_flags.h: $(top_srcdir)/xlat/mlock_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mmap_flags.h: $(top_srcdir)/xlat/mmap_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mmap_prot.h: $(top_srcdir)/xlat/mmap_prot.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/modem_flags.h: $(top_srcdir)/xlat/modem_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/modetypes.h: $(top_srcdir)/xlat/modetypes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/module_init_flags.h: $(top_srcdir)/xlat/module_init_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mount_flags.h: $(top_srcdir)/xlat/mount_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/move_pages_flags.h: $(top_srcdir)/xlat/move_pages_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mremap_flags.h: $(top_srcdir)/xlat/mremap_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/msgctl_flags.h: $(top_srcdir)/xlat/msgctl_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/msg_flags.h: $(top_srcdir)/xlat/msg_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mtd_file_mode_options.h: $(top_srcdir)/xlat/mtd_file_mode_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mtd_flags_options.h: $(top_srcdir)/xlat/mtd_flags_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mtd_mode_options.h: $(top_srcdir)/xlat/mtd_mode_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mtd_nandecc_options.h: $(top_srcdir)/xlat/mtd_nandecc_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mtd_otp_options.h: $(top_srcdir)/xlat/mtd_otp_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/mtd_type_options.h: $(top_srcdir)/xlat/mtd_type_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/netlink_flags.h: $(top_srcdir)/xlat/netlink_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/netlink_protocols.h: $(top_srcdir)/xlat/netlink_protocols.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/netlink_types.h: $(top_srcdir)/xlat/netlink_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/notifyflags.h: $(top_srcdir)/xlat/notifyflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/nt_descriptor_types.h: $(top_srcdir)/xlat/nt_descriptor_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/open_access_modes.h: $(top_srcdir)/xlat/open_access_modes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/open_mode_flags.h: $(top_srcdir)/xlat/open_mode_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/openmodessol.h: $(top_srcdir)/xlat/openmodessol.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/packet_mreq_type.h: $(top_srcdir)/xlat/packet_mreq_type.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/perf_event_open_flags.h: $(top_srcdir)/xlat/perf_event_open_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/personality_flags.h: $(top_srcdir)/xlat/personality_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/personality_types.h: $(top_srcdir)/xlat/personality_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/policies.h: $(top_srcdir)/xlat/policies.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pollflags.h: $(top_srcdir)/xlat/pollflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pr_cap_ambient.h: $(top_srcdir)/xlat/pr_cap_ambient.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/prctl_options.h: $(top_srcdir)/xlat/prctl_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/priorities.h: $(top_srcdir)/xlat/priorities.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pr_mce_kill.h: $(top_srcdir)/xlat/pr_mce_kill.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pr_mce_kill_policy.h: $(top_srcdir)/xlat/pr_mce_kill_policy.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pr_set_mm.h: $(top_srcdir)/xlat/pr_set_mm.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pr_tsc.h: $(top_srcdir)/xlat/pr_tsc.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/pr_unalign_flags.h: $(top_srcdir)/xlat/pr_unalign_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ptp_flags_options.h: $(top_srcdir)/xlat/ptp_flags_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ptrace_cmds.h: $(top_srcdir)/xlat/ptrace_cmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ptrace_events.h: $(top_srcdir)/xlat/ptrace_events.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ptrace_peeksiginfo_flags.h: $(top_srcdir)/xlat/ptrace_peeksiginfo_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ptrace_setoptions_flags.h: $(top_srcdir)/xlat/ptrace_setoptions_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/quotacmds.h: $(top_srcdir)/xlat/quotacmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/quota_formats.h: $(top_srcdir)/xlat/quota_formats.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/quotatypes.h: $(top_srcdir)/xlat/quotatypes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/rename_flags.h: $(top_srcdir)/xlat/rename_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/resource_flags.h: $(top_srcdir)/xlat/resource_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/resources.h: $(top_srcdir)/xlat/resources.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/rwf_flags.h: $(top_srcdir)/xlat/rwf_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sched_flags.h: $(top_srcdir)/xlat/sched_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/schedulers.h: $(top_srcdir)/xlat/schedulers.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/scmvals.h: $(top_srcdir)/xlat/scmvals.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/secbits.h: $(top_srcdir)/xlat/secbits.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/seccomp_filter_flags.h: $(top_srcdir)/xlat/seccomp_filter_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/seccomp_mode.h: $(top_srcdir)/xlat/seccomp_mode.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/seccomp_ops.h: $(top_srcdir)/xlat/seccomp_ops.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/seccomp_ret_action.h: $(top_srcdir)/xlat/seccomp_ret_action.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/semctl_flags.h: $(top_srcdir)/xlat/semctl_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/semop_flags.h: $(top_srcdir)/xlat/semop_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/setsockipoptions.h: $(top_srcdir)/xlat/setsockipoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/setsockipv6options.h: $(top_srcdir)/xlat/setsockipv6options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sfd_flags.h: $(top_srcdir)/xlat/sfd_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sg_io_dxfer_direction.h: $(top_srcdir)/xlat/sg_io_dxfer_direction.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/shmctl_flags.h: $(top_srcdir)/xlat/shmctl_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/shm_flags.h: $(top_srcdir)/xlat/shm_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/shm_resource_flags.h: $(top_srcdir)/xlat/shm_resource_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/shutdown_modes.h: $(top_srcdir)/xlat/shutdown_modes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigact_flags.h: $(top_srcdir)/xlat/sigact_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigaltstack_flags.h: $(top_srcdir)/xlat/sigaltstack_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigbus_codes.h: $(top_srcdir)/xlat/sigbus_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigchld_codes.h: $(top_srcdir)/xlat/sigchld_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigemt_codes.h: $(top_srcdir)/xlat/sigemt_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigev_value.h: $(top_srcdir)/xlat/sigev_value.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigfpe_codes.h: $(top_srcdir)/xlat/sigfpe_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigill_codes.h: $(top_srcdir)/xlat/sigill_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/siginfo_codes.h: $(top_srcdir)/xlat/siginfo_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigpoll_codes.h: $(top_srcdir)/xlat/sigpoll_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigprocmaskcmds.h: $(top_srcdir)/xlat/sigprocmaskcmds.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigprof_codes.h: $(top_srcdir)/xlat/sigprof_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigsegv_codes.h: $(top_srcdir)/xlat/sigsegv_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigsys_codes.h: $(top_srcdir)/xlat/sigsys_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sigtrap_codes.h: $(top_srcdir)/xlat/sigtrap_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/socketcalls.h: $(top_srcdir)/xlat/socketcalls.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/socketlayers.h: $(top_srcdir)/xlat/socketlayers.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sockipoptions.h: $(top_srcdir)/xlat/sockipoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sockipv6options.h: $(top_srcdir)/xlat/sockipv6options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sockipxoptions.h: $(top_srcdir)/xlat/sockipxoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sockoptions.h: $(top_srcdir)/xlat/sockoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sockpacketoptions.h: $(top_srcdir)/xlat/sockpacketoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sockrawoptions.h: $(top_srcdir)/xlat/sockrawoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/socksctpoptions.h: $(top_srcdir)/xlat/socksctpoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/socktcpoptions.h: $(top_srcdir)/xlat/socktcpoptions.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sock_type_flags.h: $(top_srcdir)/xlat/sock_type_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/socktypes.h: $(top_srcdir)/xlat/socktypes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/splice_flags.h: $(top_srcdir)/xlat/splice_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sram_alloc_flags.h: $(top_srcdir)/xlat/sram_alloc_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/statfs_flags.h: $(top_srcdir)/xlat/statfs_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/swap_flags.h: $(top_srcdir)/xlat/swap_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sync_file_range_flags.h: $(top_srcdir)/xlat/sync_file_range_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_kern.h: $(top_srcdir)/xlat/sysctl_kern.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_core.h: $(top_srcdir)/xlat/sysctl_net_core.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net.h: $(top_srcdir)/xlat/sysctl_net.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_ipv4_conf.h: $(top_srcdir)/xlat/sysctl_net_ipv4_conf.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_ipv4.h: $(top_srcdir)/xlat/sysctl_net_ipv4.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_ipv4_route.h: $(top_srcdir)/xlat/sysctl_net_ipv4_route.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_ipv6.h: $(top_srcdir)/xlat/sysctl_net_ipv6.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_ipv6_route.h: $(top_srcdir)/xlat/sysctl_net_ipv6_route.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_net_unix.h: $(top_srcdir)/xlat/sysctl_net_unix.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_root.h: $(top_srcdir)/xlat/sysctl_root.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysctl_vm.h: $(top_srcdir)/xlat/sysctl_vm.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/syslog_action_type.h: $(top_srcdir)/xlat/syslog_action_type.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/sysmips_operations.h: $(top_srcdir)/xlat/sysmips_operations.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/tcflsh_options.h: $(top_srcdir)/xlat/tcflsh_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/tcxonc_options.h: $(top_srcdir)/xlat/tcxonc_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/timerfdflags.h: $(top_srcdir)/xlat/timerfdflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ubi_volume_props.h: $(top_srcdir)/xlat/ubi_volume_props.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/ubi_volume_types.h: $(top_srcdir)/xlat/ubi_volume_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/uffd_api_flags.h: $(top_srcdir)/xlat/uffd_api_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/uffd_copy_flags.h: $(top_srcdir)/xlat/uffd_copy_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/uffd_flags.h: $(top_srcdir)/xlat/uffd_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/uffd_register_ioctl_flags.h: $(top_srcdir)/xlat/uffd_register_ioctl_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/uffd_register_mode_flags.h: $(top_srcdir)/xlat/uffd_register_mode_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/uffd_zeropage_flags.h: $(top_srcdir)/xlat/uffd_zeropage_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/umount_flags.h: $(top_srcdir)/xlat/umount_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/usagewho.h: $(top_srcdir)/xlat/usagewho.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_buf_flags.h: $(top_srcdir)/xlat/v4l2_buf_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_buf_types.h: $(top_srcdir)/xlat/v4l2_buf_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_capture_modes.h: $(top_srcdir)/xlat/v4l2_capture_modes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_colorspaces.h: $(top_srcdir)/xlat/v4l2_colorspaces.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_control_classes.h: $(top_srcdir)/xlat/v4l2_control_classes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_control_flags.h: $(top_srcdir)/xlat/v4l2_control_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_control_ids.h: $(top_srcdir)/xlat/v4l2_control_ids.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_control_types.h: $(top_srcdir)/xlat/v4l2_control_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_device_capabilities_flags.h: $(top_srcdir)/xlat/v4l2_device_capabilities_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_fields.h: $(top_srcdir)/xlat/v4l2_fields.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_format_description_flags.h: $(top_srcdir)/xlat/v4l2_format_description_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_frameinterval_types.h: $(top_srcdir)/xlat/v4l2_frameinterval_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_framesize_types.h: $(top_srcdir)/xlat/v4l2_framesize_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_input_types.h: $(top_srcdir)/xlat/v4l2_input_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_memories.h: $(top_srcdir)/xlat/v4l2_memories.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/v4l2_streaming_capabilities.h: $(top_srcdir)/xlat/v4l2_streaming_capabilities.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/wait4_options.h: $(top_srcdir)/xlat/wait4_options.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/waitid_types.h: $(top_srcdir)/xlat/waitid_types.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/whence_codes.h: $(top_srcdir)/xlat/whence_codes.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/xattrflags.h: $(top_srcdir)/xlat/xattrflags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/xfs_dqblk_flags.h: $(top_srcdir)/xlat/xfs_dqblk_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
+$(top_srcdir)/xlat/xfs_quota_flags.h: $(top_srcdir)/xlat/xfs_quota_flags.in $(top_srcdir)/xlat/gen.sh
+	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@
diff --git a/strace/xlat/access_flags.h b/strace/xlat/access_flags.h
new file mode 100644
index 0000000..a30f082
--- /dev/null
+++ b/strace/xlat/access_flags.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/access_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat access_flags in mpers mode
+
+#else
+
+static
+const struct xlat access_flags[] = {
+#if defined(F_OK) || (defined(HAVE_DECL_F_OK) && HAVE_DECL_F_OK)
+  XLAT(F_OK),
+#endif
+#if defined(R_OK) || (defined(HAVE_DECL_R_OK) && HAVE_DECL_R_OK)
+  XLAT(R_OK),
+#endif
+#if defined(W_OK) || (defined(HAVE_DECL_W_OK) && HAVE_DECL_W_OK)
+  XLAT(W_OK),
+#endif
+#if defined(X_OK) || (defined(HAVE_DECL_X_OK) && HAVE_DECL_X_OK)
+  XLAT(X_OK),
+#endif
+#if defined(EFF_ONLY_OK) || (defined(HAVE_DECL_EFF_ONLY_OK) && HAVE_DECL_EFF_ONLY_OK)
+  XLAT(EFF_ONLY_OK),
+#endif
+#if defined(EX_OK) || (defined(HAVE_DECL_EX_OK) && HAVE_DECL_EX_OK)
+  XLAT(EX_OK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/access_flags.in b/strace/xlat/access_flags.in
new file mode 100644
index 0000000..cc46ad5
--- /dev/null
+++ b/strace/xlat/access_flags.in
@@ -0,0 +1,6 @@
+F_OK
+R_OK
+W_OK
+X_OK
+EFF_ONLY_OK
+EX_OK
diff --git a/strace/xlat/aclcmds.h b/strace/xlat/aclcmds.h
new file mode 100644
index 0000000..d12302a
--- /dev/null
+++ b/strace/xlat/aclcmds.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/aclcmds.in; do not edit. */
+
+static const struct xlat aclcmds[] = {
+#if defined(SETACL) || (defined(HAVE_DECL_SETACL) && HAVE_DECL_SETACL)
+	XLAT(SETACL),
+#endif
+#if defined(GETACL) || (defined(HAVE_DECL_GETACL) && HAVE_DECL_GETACL)
+	XLAT(GETACL),
+#endif
+#if defined(GETACLCNT) || (defined(HAVE_DECL_GETACLCNT) && HAVE_DECL_GETACLCNT)
+	XLAT(GETACLCNT),
+#endif
+#if defined(ACL_GET) || (defined(HAVE_DECL_ACL_GET) && HAVE_DECL_ACL_GET)
+	XLAT(ACL_GET),
+#endif
+#if defined(ACL_SET) || (defined(HAVE_DECL_ACL_SET) && HAVE_DECL_ACL_SET)
+	XLAT(ACL_SET),
+#endif
+#if defined(ACL_CNT) || (defined(HAVE_DECL_ACL_CNT) && HAVE_DECL_ACL_CNT)
+	XLAT(ACL_CNT),
+#endif
+	XLAT_END
+};
diff --git a/strace/xlat/aclipc.h b/strace/xlat/aclipc.h
new file mode 100644
index 0000000..6dabb83
--- /dev/null
+++ b/strace/xlat/aclipc.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/aclipc.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat aclipc in mpers mode
+
+#else
+
+static
+const struct xlat aclipc[] = {
+#if defined(IPC_SHM) || (defined(HAVE_DECL_IPC_SHM) && HAVE_DECL_IPC_SHM)
+  XLAT(IPC_SHM),
+#endif
+#if defined(IPC_SEM) || (defined(HAVE_DECL_IPC_SEM) && HAVE_DECL_IPC_SEM)
+  XLAT(IPC_SEM),
+#endif
+#if defined(IPC_MSG) || (defined(HAVE_DECL_IPC_MSG) && HAVE_DECL_IPC_MSG)
+  XLAT(IPC_MSG),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/aclipc.in b/strace/xlat/aclipc.in
new file mode 100644
index 0000000..fd4d61c
--- /dev/null
+++ b/strace/xlat/aclipc.in
@@ -0,0 +1,3 @@
+IPC_SHM
+IPC_SEM
+IPC_MSG
diff --git a/strace/xlat/addrfams.h b/strace/xlat/addrfams.h
new file mode 100644
index 0000000..fc437b2
--- /dev/null
+++ b/strace/xlat/addrfams.h
@@ -0,0 +1,181 @@
+/* Generated by ./xlat/gen.sh from ./xlat/addrfams.in; do not edit. */
+#if !(defined(AF_UNSPEC) || (defined(HAVE_DECL_AF_UNSPEC) && HAVE_DECL_AF_UNSPEC))
+# define AF_UNSPEC 0
+#endif
+#if !(defined(AF_UNIX) || (defined(HAVE_DECL_AF_UNIX) && HAVE_DECL_AF_UNIX))
+# define AF_UNIX 1
+#endif
+#if !(defined(AF_INET) || (defined(HAVE_DECL_AF_INET) && HAVE_DECL_AF_INET))
+# define AF_INET 2
+#endif
+#if !(defined(AF_AX25) || (defined(HAVE_DECL_AF_AX25) && HAVE_DECL_AF_AX25))
+# define AF_AX25 3
+#endif
+#if !(defined(AF_IPX) || (defined(HAVE_DECL_AF_IPX) && HAVE_DECL_AF_IPX))
+# define AF_IPX 4
+#endif
+#if !(defined(AF_APPLETALK) || (defined(HAVE_DECL_AF_APPLETALK) && HAVE_DECL_AF_APPLETALK))
+# define AF_APPLETALK 5
+#endif
+#if !(defined(AF_NETROM) || (defined(HAVE_DECL_AF_NETROM) && HAVE_DECL_AF_NETROM))
+# define AF_NETROM 6
+#endif
+#if !(defined(AF_BRIDGE) || (defined(HAVE_DECL_AF_BRIDGE) && HAVE_DECL_AF_BRIDGE))
+# define AF_BRIDGE 7
+#endif
+#if !(defined(AF_ATMPVC) || (defined(HAVE_DECL_AF_ATMPVC) && HAVE_DECL_AF_ATMPVC))
+# define AF_ATMPVC 8
+#endif
+#if !(defined(AF_X25) || (defined(HAVE_DECL_AF_X25) && HAVE_DECL_AF_X25))
+# define AF_X25 9
+#endif
+#if !(defined(AF_INET6) || (defined(HAVE_DECL_AF_INET6) && HAVE_DECL_AF_INET6))
+# define AF_INET6 10
+#endif
+#if !(defined(AF_ROSE) || (defined(HAVE_DECL_AF_ROSE) && HAVE_DECL_AF_ROSE))
+# define AF_ROSE 11
+#endif
+#if !(defined(AF_DECnet) || (defined(HAVE_DECL_AF_DECnet) && HAVE_DECL_AF_DECnet))
+# define AF_DECnet 12
+#endif
+#if !(defined(AF_NETBEUI) || (defined(HAVE_DECL_AF_NETBEUI) && HAVE_DECL_AF_NETBEUI))
+# define AF_NETBEUI 13
+#endif
+#if !(defined(AF_SECURITY) || (defined(HAVE_DECL_AF_SECURITY) && HAVE_DECL_AF_SECURITY))
+# define AF_SECURITY 14
+#endif
+#if !(defined(AF_KEY) || (defined(HAVE_DECL_AF_KEY) && HAVE_DECL_AF_KEY))
+# define AF_KEY 15
+#endif
+#if !(defined(AF_NETLINK) || (defined(HAVE_DECL_AF_NETLINK) && HAVE_DECL_AF_NETLINK))
+# define AF_NETLINK 16
+#endif
+#if !(defined(AF_PACKET) || (defined(HAVE_DECL_AF_PACKET) && HAVE_DECL_AF_PACKET))
+# define AF_PACKET 17
+#endif
+#if !(defined(AF_ASH) || (defined(HAVE_DECL_AF_ASH) && HAVE_DECL_AF_ASH))
+# define AF_ASH 18
+#endif
+#if !(defined(AF_ECONET) || (defined(HAVE_DECL_AF_ECONET) && HAVE_DECL_AF_ECONET))
+# define AF_ECONET 19
+#endif
+#if !(defined(AF_ATMSVC) || (defined(HAVE_DECL_AF_ATMSVC) && HAVE_DECL_AF_ATMSVC))
+# define AF_ATMSVC 20
+#endif
+#if !(defined(AF_RDS) || (defined(HAVE_DECL_AF_RDS) && HAVE_DECL_AF_RDS))
+# define AF_RDS 21
+#endif
+#if !(defined(AF_SNA) || (defined(HAVE_DECL_AF_SNA) && HAVE_DECL_AF_SNA))
+# define AF_SNA 22
+#endif
+#if !(defined(AF_IRDA) || (defined(HAVE_DECL_AF_IRDA) && HAVE_DECL_AF_IRDA))
+# define AF_IRDA 23
+#endif
+#if !(defined(AF_PPPOX) || (defined(HAVE_DECL_AF_PPPOX) && HAVE_DECL_AF_PPPOX))
+# define AF_PPPOX 24
+#endif
+#if !(defined(AF_WANPIPE) || (defined(HAVE_DECL_AF_WANPIPE) && HAVE_DECL_AF_WANPIPE))
+# define AF_WANPIPE 25
+#endif
+#if !(defined(AF_LLC) || (defined(HAVE_DECL_AF_LLC) && HAVE_DECL_AF_LLC))
+# define AF_LLC 26
+#endif
+#if !(defined(AF_IB) || (defined(HAVE_DECL_AF_IB) && HAVE_DECL_AF_IB))
+# define AF_IB 27
+#endif
+#if !(defined(AF_MPLS) || (defined(HAVE_DECL_AF_MPLS) && HAVE_DECL_AF_MPLS))
+# define AF_MPLS 28
+#endif
+#if !(defined(AF_CAN) || (defined(HAVE_DECL_AF_CAN) && HAVE_DECL_AF_CAN))
+# define AF_CAN 29
+#endif
+#if !(defined(AF_TIPC) || (defined(HAVE_DECL_AF_TIPC) && HAVE_DECL_AF_TIPC))
+# define AF_TIPC 30
+#endif
+#if !(defined(AF_BLUETOOTH) || (defined(HAVE_DECL_AF_BLUETOOTH) && HAVE_DECL_AF_BLUETOOTH))
+# define AF_BLUETOOTH 31
+#endif
+#if !(defined(AF_IUCV) || (defined(HAVE_DECL_AF_IUCV) && HAVE_DECL_AF_IUCV))
+# define AF_IUCV 32
+#endif
+#if !(defined(AF_RXRPC) || (defined(HAVE_DECL_AF_RXRPC) && HAVE_DECL_AF_RXRPC))
+# define AF_RXRPC 33
+#endif
+#if !(defined(AF_ISDN) || (defined(HAVE_DECL_AF_ISDN) && HAVE_DECL_AF_ISDN))
+# define AF_ISDN 34
+#endif
+#if !(defined(AF_PHONET) || (defined(HAVE_DECL_AF_PHONET) && HAVE_DECL_AF_PHONET))
+# define AF_PHONET 35
+#endif
+#if !(defined(AF_IEEE802154) || (defined(HAVE_DECL_AF_IEEE802154) && HAVE_DECL_AF_IEEE802154))
+# define AF_IEEE802154 36
+#endif
+#if !(defined(AF_CAIF) || (defined(HAVE_DECL_AF_CAIF) && HAVE_DECL_AF_CAIF))
+# define AF_CAIF 37
+#endif
+#if !(defined(AF_ALG) || (defined(HAVE_DECL_AF_ALG) && HAVE_DECL_AF_ALG))
+# define AF_ALG 38
+#endif
+#if !(defined(AF_NFC) || (defined(HAVE_DECL_AF_NFC) && HAVE_DECL_AF_NFC))
+# define AF_NFC 39
+#endif
+#if !(defined(AF_VSOCK) || (defined(HAVE_DECL_AF_VSOCK) && HAVE_DECL_AF_VSOCK))
+# define AF_VSOCK 40
+#endif
+#if !(defined(AF_KCM) || (defined(HAVE_DECL_AF_KCM) && HAVE_DECL_AF_KCM))
+# define AF_KCM 41
+#endif
+#if !(defined(AF_QIPCRTR) || (defined(HAVE_DECL_AF_QIPCRTR) && HAVE_DECL_AF_QIPCRTR))
+# define AF_QIPCRTR 42
+#endif
+
+#ifndef IN_MPERS
+
+const struct xlat addrfams[] = {
+ XLAT(AF_UNSPEC),
+ XLAT(AF_UNIX),
+ XLAT(AF_INET),
+ XLAT(AF_AX25),
+ XLAT(AF_IPX),
+ XLAT(AF_APPLETALK),
+ XLAT(AF_NETROM),
+ XLAT(AF_BRIDGE),
+ XLAT(AF_ATMPVC),
+ XLAT(AF_X25),
+ XLAT(AF_INET6),
+ XLAT(AF_ROSE),
+ XLAT(AF_DECnet),
+ XLAT(AF_NETBEUI),
+ XLAT(AF_SECURITY),
+ XLAT(AF_KEY),
+ XLAT(AF_NETLINK),
+ XLAT(AF_PACKET),
+ XLAT(AF_ASH),
+ XLAT(AF_ECONET),
+ XLAT(AF_ATMSVC),
+ XLAT(AF_RDS),
+ XLAT(AF_SNA),
+ XLAT(AF_IRDA),
+ XLAT(AF_PPPOX),
+ XLAT(AF_WANPIPE),
+ XLAT(AF_LLC),
+ XLAT(AF_IB),
+ XLAT(AF_MPLS),
+ XLAT(AF_CAN),
+ XLAT(AF_TIPC),
+ XLAT(AF_BLUETOOTH),
+ XLAT(AF_IUCV),
+ XLAT(AF_RXRPC),
+ XLAT(AF_ISDN),
+ XLAT(AF_PHONET),
+ XLAT(AF_IEEE802154),
+ XLAT(AF_CAIF),
+ XLAT(AF_ALG),
+ XLAT(AF_NFC),
+ XLAT(AF_VSOCK),
+ XLAT(AF_KCM),
+ XLAT(AF_QIPCRTR),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/addrfams.in b/strace/xlat/addrfams.in
new file mode 100644
index 0000000..315667e
--- /dev/null
+++ b/strace/xlat/addrfams.in
@@ -0,0 +1,43 @@
+AF_UNSPEC	0
+AF_UNIX		1
+AF_INET		2
+AF_AX25		3
+AF_IPX		4
+AF_APPLETALK	5
+AF_NETROM	6
+AF_BRIDGE	7
+AF_ATMPVC	8
+AF_X25		9
+AF_INET6	10
+AF_ROSE		11
+AF_DECnet	12
+AF_NETBEUI	13
+AF_SECURITY	14
+AF_KEY		15
+AF_NETLINK	16
+AF_PACKET	17
+AF_ASH		18
+AF_ECONET	19
+AF_ATMSVC	20
+AF_RDS		21
+AF_SNA		22
+AF_IRDA		23
+AF_PPPOX	24
+AF_WANPIPE	25
+AF_LLC		26
+AF_IB		27
+AF_MPLS		28
+AF_CAN		29
+AF_TIPC		30
+AF_BLUETOOTH	31
+AF_IUCV		32
+AF_RXRPC	33
+AF_ISDN		34
+AF_PHONET	35
+AF_IEEE802154	36
+AF_CAIF		37
+AF_ALG		38
+AF_NFC		39
+AF_VSOCK	40
+AF_KCM		41
+AF_QIPCRTR	42
diff --git a/strace/xlat/adjtimex_modes.h b/strace/xlat/adjtimex_modes.h
new file mode 100644
index 0000000..7415fe8
--- /dev/null
+++ b/strace/xlat/adjtimex_modes.h
@@ -0,0 +1,56 @@
+/* Generated by ./xlat/gen.sh from ./xlat/adjtimex_modes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat adjtimex_modes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat adjtimex_modes[] = {
+ XLAT(0),
+#if defined(ADJ_OFFSET) || (defined(HAVE_DECL_ADJ_OFFSET) && HAVE_DECL_ADJ_OFFSET)
+  XLAT(ADJ_OFFSET),
+#endif
+#if defined(ADJ_FREQUENCY) || (defined(HAVE_DECL_ADJ_FREQUENCY) && HAVE_DECL_ADJ_FREQUENCY)
+  XLAT(ADJ_FREQUENCY),
+#endif
+#if defined(ADJ_MAXERROR) || (defined(HAVE_DECL_ADJ_MAXERROR) && HAVE_DECL_ADJ_MAXERROR)
+  XLAT(ADJ_MAXERROR),
+#endif
+#if defined(ADJ_ESTERROR) || (defined(HAVE_DECL_ADJ_ESTERROR) && HAVE_DECL_ADJ_ESTERROR)
+  XLAT(ADJ_ESTERROR),
+#endif
+#if defined(ADJ_STATUS) || (defined(HAVE_DECL_ADJ_STATUS) && HAVE_DECL_ADJ_STATUS)
+  XLAT(ADJ_STATUS),
+#endif
+#if defined(ADJ_TIMECONST) || (defined(HAVE_DECL_ADJ_TIMECONST) && HAVE_DECL_ADJ_TIMECONST)
+  XLAT(ADJ_TIMECONST),
+#endif
+#if defined(ADJ_TAI) || (defined(HAVE_DECL_ADJ_TAI) && HAVE_DECL_ADJ_TAI)
+  XLAT(ADJ_TAI),
+#endif
+#if defined(ADJ_SETOFFSET) || (defined(HAVE_DECL_ADJ_SETOFFSET) && HAVE_DECL_ADJ_SETOFFSET)
+  XLAT(ADJ_SETOFFSET),
+#endif
+#if defined(ADJ_MICRO) || (defined(HAVE_DECL_ADJ_MICRO) && HAVE_DECL_ADJ_MICRO)
+  XLAT(ADJ_MICRO),
+#endif
+#if defined(ADJ_NANO) || (defined(HAVE_DECL_ADJ_NANO) && HAVE_DECL_ADJ_NANO)
+  XLAT(ADJ_NANO),
+#endif
+#if defined(ADJ_TICK) || (defined(HAVE_DECL_ADJ_TICK) && HAVE_DECL_ADJ_TICK)
+  XLAT(ADJ_TICK),
+#endif
+#if defined(ADJ_OFFSET_SINGLESHOT) || (defined(HAVE_DECL_ADJ_OFFSET_SINGLESHOT) && HAVE_DECL_ADJ_OFFSET_SINGLESHOT)
+  XLAT(ADJ_OFFSET_SINGLESHOT),
+#endif
+#if defined(ADJ_OFFSET_SS_READ) || (defined(HAVE_DECL_ADJ_OFFSET_SS_READ) && HAVE_DECL_ADJ_OFFSET_SS_READ)
+  XLAT(ADJ_OFFSET_SS_READ),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/adjtimex_modes.in b/strace/xlat/adjtimex_modes.in
new file mode 100644
index 0000000..e2ca680
--- /dev/null
+++ b/strace/xlat/adjtimex_modes.in
@@ -0,0 +1,14 @@
+0
+ADJ_OFFSET
+ADJ_FREQUENCY
+ADJ_MAXERROR
+ADJ_ESTERROR
+ADJ_STATUS
+ADJ_TIMECONST
+ADJ_TAI
+ADJ_SETOFFSET
+ADJ_MICRO
+ADJ_NANO
+ADJ_TICK
+ADJ_OFFSET_SINGLESHOT
+ADJ_OFFSET_SS_READ
diff --git a/strace/xlat/adjtimex_state.h b/strace/xlat/adjtimex_state.h
new file mode 100644
index 0000000..888f1b6
--- /dev/null
+++ b/strace/xlat/adjtimex_state.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/adjtimex_state.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat adjtimex_state in mpers mode
+
+#else
+
+static
+const struct xlat adjtimex_state[] = {
+#if defined(TIME_OK) || (defined(HAVE_DECL_TIME_OK) && HAVE_DECL_TIME_OK)
+  XLAT(TIME_OK),
+#endif
+#if defined(TIME_INS) || (defined(HAVE_DECL_TIME_INS) && HAVE_DECL_TIME_INS)
+  XLAT(TIME_INS),
+#endif
+#if defined(TIME_DEL) || (defined(HAVE_DECL_TIME_DEL) && HAVE_DECL_TIME_DEL)
+  XLAT(TIME_DEL),
+#endif
+#if defined(TIME_OOP) || (defined(HAVE_DECL_TIME_OOP) && HAVE_DECL_TIME_OOP)
+  XLAT(TIME_OOP),
+#endif
+#if defined(TIME_WAIT) || (defined(HAVE_DECL_TIME_WAIT) && HAVE_DECL_TIME_WAIT)
+  XLAT(TIME_WAIT),
+#endif
+#if defined(TIME_ERROR) || (defined(HAVE_DECL_TIME_ERROR) && HAVE_DECL_TIME_ERROR)
+  XLAT(TIME_ERROR),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/adjtimex_state.in b/strace/xlat/adjtimex_state.in
new file mode 100644
index 0000000..873b9a1
--- /dev/null
+++ b/strace/xlat/adjtimex_state.in
@@ -0,0 +1,6 @@
+TIME_OK
+TIME_INS
+TIME_DEL
+TIME_OOP
+TIME_WAIT
+TIME_ERROR
diff --git a/strace/xlat/adjtimex_status.h b/strace/xlat/adjtimex_status.h
new file mode 100644
index 0000000..16e7811
--- /dev/null
+++ b/strace/xlat/adjtimex_status.h
@@ -0,0 +1,64 @@
+/* Generated by ./xlat/gen.sh from ./xlat/adjtimex_status.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat adjtimex_status[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat adjtimex_status[] = {
+#if defined(STA_PLL) || (defined(HAVE_DECL_STA_PLL) && HAVE_DECL_STA_PLL)
+  XLAT(STA_PLL),
+#endif
+#if defined(STA_PPSFREQ) || (defined(HAVE_DECL_STA_PPSFREQ) && HAVE_DECL_STA_PPSFREQ)
+  XLAT(STA_PPSFREQ),
+#endif
+#if defined(STA_PPSTIME) || (defined(HAVE_DECL_STA_PPSTIME) && HAVE_DECL_STA_PPSTIME)
+  XLAT(STA_PPSTIME),
+#endif
+#if defined(STA_FLL) || (defined(HAVE_DECL_STA_FLL) && HAVE_DECL_STA_FLL)
+  XLAT(STA_FLL),
+#endif
+#if defined(STA_INS) || (defined(HAVE_DECL_STA_INS) && HAVE_DECL_STA_INS)
+  XLAT(STA_INS),
+#endif
+#if defined(STA_DEL) || (defined(HAVE_DECL_STA_DEL) && HAVE_DECL_STA_DEL)
+  XLAT(STA_DEL),
+#endif
+#if defined(STA_UNSYNC) || (defined(HAVE_DECL_STA_UNSYNC) && HAVE_DECL_STA_UNSYNC)
+  XLAT(STA_UNSYNC),
+#endif
+#if defined(STA_FREQHOLD) || (defined(HAVE_DECL_STA_FREQHOLD) && HAVE_DECL_STA_FREQHOLD)
+  XLAT(STA_FREQHOLD),
+#endif
+#if defined(STA_PPSSIGNAL) || (defined(HAVE_DECL_STA_PPSSIGNAL) && HAVE_DECL_STA_PPSSIGNAL)
+  XLAT(STA_PPSSIGNAL),
+#endif
+#if defined(STA_PPSJITTER) || (defined(HAVE_DECL_STA_PPSJITTER) && HAVE_DECL_STA_PPSJITTER)
+  XLAT(STA_PPSJITTER),
+#endif
+#if defined(STA_PPSWANDER) || (defined(HAVE_DECL_STA_PPSWANDER) && HAVE_DECL_STA_PPSWANDER)
+  XLAT(STA_PPSWANDER),
+#endif
+#if defined(STA_PPSERROR) || (defined(HAVE_DECL_STA_PPSERROR) && HAVE_DECL_STA_PPSERROR)
+  XLAT(STA_PPSERROR),
+#endif
+#if defined(STA_CLOCKERR) || (defined(HAVE_DECL_STA_CLOCKERR) && HAVE_DECL_STA_CLOCKERR)
+  XLAT(STA_CLOCKERR),
+#endif
+#if defined(STA_NANO) || (defined(HAVE_DECL_STA_NANO) && HAVE_DECL_STA_NANO)
+  XLAT(STA_NANO),
+#endif
+#if defined(STA_MODE) || (defined(HAVE_DECL_STA_MODE) && HAVE_DECL_STA_MODE)
+  XLAT(STA_MODE),
+#endif
+#if defined(STA_CLK) || (defined(HAVE_DECL_STA_CLK) && HAVE_DECL_STA_CLK)
+  XLAT(STA_CLK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/adjtimex_status.in b/strace/xlat/adjtimex_status.in
new file mode 100644
index 0000000..c6b6264
--- /dev/null
+++ b/strace/xlat/adjtimex_status.in
@@ -0,0 +1,16 @@
+STA_PLL
+STA_PPSFREQ
+STA_PPSTIME
+STA_FLL
+STA_INS
+STA_DEL
+STA_UNSYNC
+STA_FREQHOLD
+STA_PPSSIGNAL
+STA_PPSJITTER
+STA_PPSWANDER
+STA_PPSERROR
+STA_CLOCKERR
+STA_NANO
+STA_MODE
+STA_CLK
diff --git a/strace/xlat/advise.h b/strace/xlat/advise.h
new file mode 100644
index 0000000..526219d
--- /dev/null
+++ b/strace/xlat/advise.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/advise.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat advise in mpers mode
+
+#else
+
+static
+const struct xlat advise[] = {
+#if defined(POSIX_FADV_NORMAL) || (defined(HAVE_DECL_POSIX_FADV_NORMAL) && HAVE_DECL_POSIX_FADV_NORMAL)
+  XLAT(POSIX_FADV_NORMAL),
+#endif
+#if defined(POSIX_FADV_RANDOM) || (defined(HAVE_DECL_POSIX_FADV_RANDOM) && HAVE_DECL_POSIX_FADV_RANDOM)
+  XLAT(POSIX_FADV_RANDOM),
+#endif
+#if defined(POSIX_FADV_SEQUENTIAL) || (defined(HAVE_DECL_POSIX_FADV_SEQUENTIAL) && HAVE_DECL_POSIX_FADV_SEQUENTIAL)
+  XLAT(POSIX_FADV_SEQUENTIAL),
+#endif
+#if defined(POSIX_FADV_WILLNEED) || (defined(HAVE_DECL_POSIX_FADV_WILLNEED) && HAVE_DECL_POSIX_FADV_WILLNEED)
+  XLAT(POSIX_FADV_WILLNEED),
+#endif
+#if defined(POSIX_FADV_DONTNEED) || (defined(HAVE_DECL_POSIX_FADV_DONTNEED) && HAVE_DECL_POSIX_FADV_DONTNEED)
+  XLAT(POSIX_FADV_DONTNEED),
+#endif
+#if defined(POSIX_FADV_NOREUSE) || (defined(HAVE_DECL_POSIX_FADV_NOREUSE) && HAVE_DECL_POSIX_FADV_NOREUSE)
+  XLAT(POSIX_FADV_NOREUSE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/advise.in b/strace/xlat/advise.in
new file mode 100644
index 0000000..47540e0
--- /dev/null
+++ b/strace/xlat/advise.in
@@ -0,0 +1,6 @@
+POSIX_FADV_NORMAL
+POSIX_FADV_RANDOM
+POSIX_FADV_SEQUENTIAL
+POSIX_FADV_WILLNEED
+POSIX_FADV_DONTNEED
+POSIX_FADV_NOREUSE
diff --git a/strace/xlat/af_packet_types.h b/strace/xlat/af_packet_types.h
new file mode 100644
index 0000000..72bb419
--- /dev/null
+++ b/strace/xlat/af_packet_types.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/af_packet_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat af_packet_types in mpers mode
+
+#else
+
+static
+const struct xlat af_packet_types[] = {
+#if defined(PACKET_HOST) || (defined(HAVE_DECL_PACKET_HOST) && HAVE_DECL_PACKET_HOST)
+  XLAT(PACKET_HOST),
+#endif
+#if defined(PACKET_BROADCAST) || (defined(HAVE_DECL_PACKET_BROADCAST) && HAVE_DECL_PACKET_BROADCAST)
+  XLAT(PACKET_BROADCAST),
+#endif
+#if defined(PACKET_MULTICAST) || (defined(HAVE_DECL_PACKET_MULTICAST) && HAVE_DECL_PACKET_MULTICAST)
+  XLAT(PACKET_MULTICAST),
+#endif
+#if defined(PACKET_OTHERHOST) || (defined(HAVE_DECL_PACKET_OTHERHOST) && HAVE_DECL_PACKET_OTHERHOST)
+  XLAT(PACKET_OTHERHOST),
+#endif
+#if defined(PACKET_OUTGOING) || (defined(HAVE_DECL_PACKET_OUTGOING) && HAVE_DECL_PACKET_OUTGOING)
+  XLAT(PACKET_OUTGOING),
+#endif
+#if defined(PACKET_LOOPBACK) || (defined(HAVE_DECL_PACKET_LOOPBACK) && HAVE_DECL_PACKET_LOOPBACK)
+  XLAT(PACKET_LOOPBACK),
+#endif
+#if defined(PACKET_FASTROUTE) || (defined(HAVE_DECL_PACKET_FASTROUTE) && HAVE_DECL_PACKET_FASTROUTE)
+  XLAT(PACKET_FASTROUTE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/af_packet_types.in b/strace/xlat/af_packet_types.in
new file mode 100644
index 0000000..18cf655
--- /dev/null
+++ b/strace/xlat/af_packet_types.in
@@ -0,0 +1,7 @@
+PACKET_HOST
+PACKET_BROADCAST
+PACKET_MULTICAST
+PACKET_OTHERHOST
+PACKET_OUTGOING
+PACKET_LOOPBACK
+PACKET_FASTROUTE
diff --git a/strace/xlat/archvals.h b/strace/xlat/archvals.h
new file mode 100644
index 0000000..9ace509
--- /dev/null
+++ b/strace/xlat/archvals.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/archvals.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat archvals in mpers mode
+
+#else
+
+static
+const struct xlat archvals[] = {
+#if defined(ARCH_SET_GS) || (defined(HAVE_DECL_ARCH_SET_GS) && HAVE_DECL_ARCH_SET_GS)
+  XLAT(ARCH_SET_GS),
+#endif
+#if defined(ARCH_SET_FS) || (defined(HAVE_DECL_ARCH_SET_FS) && HAVE_DECL_ARCH_SET_FS)
+  XLAT(ARCH_SET_FS),
+#endif
+#if defined(ARCH_GET_FS) || (defined(HAVE_DECL_ARCH_GET_FS) && HAVE_DECL_ARCH_GET_FS)
+  XLAT(ARCH_GET_FS),
+#endif
+#if defined(ARCH_GET_GS) || (defined(HAVE_DECL_ARCH_GET_GS) && HAVE_DECL_ARCH_GET_GS)
+  XLAT(ARCH_GET_GS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/archvals.in b/strace/xlat/archvals.in
new file mode 100644
index 0000000..22ad7c1
--- /dev/null
+++ b/strace/xlat/archvals.in
@@ -0,0 +1,4 @@
+ARCH_SET_GS
+ARCH_SET_FS
+ARCH_GET_FS
+ARCH_GET_GS
diff --git a/strace/xlat/arp_hardware_types.h b/strace/xlat/arp_hardware_types.h
new file mode 100644
index 0000000..7e669b3
--- /dev/null
+++ b/strace/xlat/arp_hardware_types.h
@@ -0,0 +1,206 @@
+/* Generated by ./xlat/gen.sh from ./xlat/arp_hardware_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat arp_hardware_types in mpers mode
+
+#else
+
+static
+const struct xlat arp_hardware_types[] = {
+#if defined(ARPHRD_NETROM) || (defined(HAVE_DECL_ARPHRD_NETROM) && HAVE_DECL_ARPHRD_NETROM)
+  XLAT(ARPHRD_NETROM),
+#endif
+#if defined(ARPHRD_ETHER) || (defined(HAVE_DECL_ARPHRD_ETHER) && HAVE_DECL_ARPHRD_ETHER)
+  XLAT(ARPHRD_ETHER),
+#endif
+#if defined(ARPHRD_EETHER) || (defined(HAVE_DECL_ARPHRD_EETHER) && HAVE_DECL_ARPHRD_EETHER)
+  XLAT(ARPHRD_EETHER),
+#endif
+#if defined(ARPHRD_AX25) || (defined(HAVE_DECL_ARPHRD_AX25) && HAVE_DECL_ARPHRD_AX25)
+  XLAT(ARPHRD_AX25),
+#endif
+#if defined(ARPHRD_PRONET) || (defined(HAVE_DECL_ARPHRD_PRONET) && HAVE_DECL_ARPHRD_PRONET)
+  XLAT(ARPHRD_PRONET),
+#endif
+#if defined(ARPHRD_CHAOS) || (defined(HAVE_DECL_ARPHRD_CHAOS) && HAVE_DECL_ARPHRD_CHAOS)
+  XLAT(ARPHRD_CHAOS),
+#endif
+#if defined(ARPHRD_IEEE802) || (defined(HAVE_DECL_ARPHRD_IEEE802) && HAVE_DECL_ARPHRD_IEEE802)
+  XLAT(ARPHRD_IEEE802),
+#endif
+#if defined(ARPHRD_ARCNET) || (defined(HAVE_DECL_ARPHRD_ARCNET) && HAVE_DECL_ARPHRD_ARCNET)
+  XLAT(ARPHRD_ARCNET),
+#endif
+#if defined(ARPHRD_APPLETLK) || (defined(HAVE_DECL_ARPHRD_APPLETLK) && HAVE_DECL_ARPHRD_APPLETLK)
+  XLAT(ARPHRD_APPLETLK),
+#endif
+#if defined(ARPHRD_DLCI) || (defined(HAVE_DECL_ARPHRD_DLCI) && HAVE_DECL_ARPHRD_DLCI)
+  XLAT(ARPHRD_DLCI),
+#endif
+#if defined(ARPHRD_ATM) || (defined(HAVE_DECL_ARPHRD_ATM) && HAVE_DECL_ARPHRD_ATM)
+  XLAT(ARPHRD_ATM),
+#endif
+#if defined(ARPHRD_METRICOM) || (defined(HAVE_DECL_ARPHRD_METRICOM) && HAVE_DECL_ARPHRD_METRICOM)
+  XLAT(ARPHRD_METRICOM),
+#endif
+#if defined(ARPHRD_IEEE1394) || (defined(HAVE_DECL_ARPHRD_IEEE1394) && HAVE_DECL_ARPHRD_IEEE1394)
+  XLAT(ARPHRD_IEEE1394),
+#endif
+#if defined(ARPHRD_EUI64) || (defined(HAVE_DECL_ARPHRD_EUI64) && HAVE_DECL_ARPHRD_EUI64)
+  XLAT(ARPHRD_EUI64),
+#endif
+#if defined(ARPHRD_INFINIBAND) || (defined(HAVE_DECL_ARPHRD_INFINIBAND) && HAVE_DECL_ARPHRD_INFINIBAND)
+  XLAT(ARPHRD_INFINIBAND),
+#endif
+#if defined(ARPHRD_SLIP) || (defined(HAVE_DECL_ARPHRD_SLIP) && HAVE_DECL_ARPHRD_SLIP)
+  XLAT(ARPHRD_SLIP),
+#endif
+#if defined(ARPHRD_CSLIP) || (defined(HAVE_DECL_ARPHRD_CSLIP) && HAVE_DECL_ARPHRD_CSLIP)
+  XLAT(ARPHRD_CSLIP),
+#endif
+#if defined(ARPHRD_SLIP6) || (defined(HAVE_DECL_ARPHRD_SLIP6) && HAVE_DECL_ARPHRD_SLIP6)
+  XLAT(ARPHRD_SLIP6),
+#endif
+#if defined(ARPHRD_CSLIP6) || (defined(HAVE_DECL_ARPHRD_CSLIP6) && HAVE_DECL_ARPHRD_CSLIP6)
+  XLAT(ARPHRD_CSLIP6),
+#endif
+#if defined(ARPHRD_RSRVD) || (defined(HAVE_DECL_ARPHRD_RSRVD) && HAVE_DECL_ARPHRD_RSRVD)
+  XLAT(ARPHRD_RSRVD),
+#endif
+#if defined(ARPHRD_ADAPT) || (defined(HAVE_DECL_ARPHRD_ADAPT) && HAVE_DECL_ARPHRD_ADAPT)
+  XLAT(ARPHRD_ADAPT),
+#endif
+#if defined(ARPHRD_ROSE) || (defined(HAVE_DECL_ARPHRD_ROSE) && HAVE_DECL_ARPHRD_ROSE)
+  XLAT(ARPHRD_ROSE),
+#endif
+#if defined(ARPHRD_X25) || (defined(HAVE_DECL_ARPHRD_X25) && HAVE_DECL_ARPHRD_X25)
+  XLAT(ARPHRD_X25),
+#endif
+#if defined(ARPHRD_HWX25) || (defined(HAVE_DECL_ARPHRD_HWX25) && HAVE_DECL_ARPHRD_HWX25)
+  XLAT(ARPHRD_HWX25),
+#endif
+#if defined(ARPHRD_CAN) || (defined(HAVE_DECL_ARPHRD_CAN) && HAVE_DECL_ARPHRD_CAN)
+  XLAT(ARPHRD_CAN),
+#endif
+#if defined(ARPHRD_PPP) || (defined(HAVE_DECL_ARPHRD_PPP) && HAVE_DECL_ARPHRD_PPP)
+  XLAT(ARPHRD_PPP),
+#endif
+#if defined(ARPHRD_CISCO) || (defined(HAVE_DECL_ARPHRD_CISCO) && HAVE_DECL_ARPHRD_CISCO)
+  XLAT(ARPHRD_CISCO),
+#endif
+#if defined(ARPHRD_LAPB) || (defined(HAVE_DECL_ARPHRD_LAPB) && HAVE_DECL_ARPHRD_LAPB)
+  XLAT(ARPHRD_LAPB),
+#endif
+#if defined(ARPHRD_DDCMP) || (defined(HAVE_DECL_ARPHRD_DDCMP) && HAVE_DECL_ARPHRD_DDCMP)
+  XLAT(ARPHRD_DDCMP),
+#endif
+#if defined(ARPHRD_RAWHDLC) || (defined(HAVE_DECL_ARPHRD_RAWHDLC) && HAVE_DECL_ARPHRD_RAWHDLC)
+  XLAT(ARPHRD_RAWHDLC),
+#endif
+#if defined(ARPHRD_TUNNEL) || (defined(HAVE_DECL_ARPHRD_TUNNEL) && HAVE_DECL_ARPHRD_TUNNEL)
+  XLAT(ARPHRD_TUNNEL),
+#endif
+#if defined(ARPHRD_TUNNEL6) || (defined(HAVE_DECL_ARPHRD_TUNNEL6) && HAVE_DECL_ARPHRD_TUNNEL6)
+  XLAT(ARPHRD_TUNNEL6),
+#endif
+#if defined(ARPHRD_FRAD) || (defined(HAVE_DECL_ARPHRD_FRAD) && HAVE_DECL_ARPHRD_FRAD)
+  XLAT(ARPHRD_FRAD),
+#endif
+#if defined(ARPHRD_SKIP) || (defined(HAVE_DECL_ARPHRD_SKIP) && HAVE_DECL_ARPHRD_SKIP)
+  XLAT(ARPHRD_SKIP),
+#endif
+#if defined(ARPHRD_LOOPBACK) || (defined(HAVE_DECL_ARPHRD_LOOPBACK) && HAVE_DECL_ARPHRD_LOOPBACK)
+  XLAT(ARPHRD_LOOPBACK),
+#endif
+#if defined(ARPHRD_LOCALTLK) || (defined(HAVE_DECL_ARPHRD_LOCALTLK) && HAVE_DECL_ARPHRD_LOCALTLK)
+  XLAT(ARPHRD_LOCALTLK),
+#endif
+#if defined(ARPHRD_FDDI) || (defined(HAVE_DECL_ARPHRD_FDDI) && HAVE_DECL_ARPHRD_FDDI)
+  XLAT(ARPHRD_FDDI),
+#endif
+#if defined(ARPHRD_BIF) || (defined(HAVE_DECL_ARPHRD_BIF) && HAVE_DECL_ARPHRD_BIF)
+  XLAT(ARPHRD_BIF),
+#endif
+#if defined(ARPHRD_SIT) || (defined(HAVE_DECL_ARPHRD_SIT) && HAVE_DECL_ARPHRD_SIT)
+  XLAT(ARPHRD_SIT),
+#endif
+#if defined(ARPHRD_IPDDP) || (defined(HAVE_DECL_ARPHRD_IPDDP) && HAVE_DECL_ARPHRD_IPDDP)
+  XLAT(ARPHRD_IPDDP),
+#endif
+#if defined(ARPHRD_IPGRE) || (defined(HAVE_DECL_ARPHRD_IPGRE) && HAVE_DECL_ARPHRD_IPGRE)
+  XLAT(ARPHRD_IPGRE),
+#endif
+#if defined(ARPHRD_PIMREG) || (defined(HAVE_DECL_ARPHRD_PIMREG) && HAVE_DECL_ARPHRD_PIMREG)
+  XLAT(ARPHRD_PIMREG),
+#endif
+#if defined(ARPHRD_HIPPI) || (defined(HAVE_DECL_ARPHRD_HIPPI) && HAVE_DECL_ARPHRD_HIPPI)
+  XLAT(ARPHRD_HIPPI),
+#endif
+#if defined(ARPHRD_ASH) || (defined(HAVE_DECL_ARPHRD_ASH) && HAVE_DECL_ARPHRD_ASH)
+  XLAT(ARPHRD_ASH),
+#endif
+#if defined(ARPHRD_ECONET) || (defined(HAVE_DECL_ARPHRD_ECONET) && HAVE_DECL_ARPHRD_ECONET)
+  XLAT(ARPHRD_ECONET),
+#endif
+#if defined(ARPHRD_IRDA) || (defined(HAVE_DECL_ARPHRD_IRDA) && HAVE_DECL_ARPHRD_IRDA)
+  XLAT(ARPHRD_IRDA),
+#endif
+#if defined(ARPHRD_FCPP) || (defined(HAVE_DECL_ARPHRD_FCPP) && HAVE_DECL_ARPHRD_FCPP)
+  XLAT(ARPHRD_FCPP),
+#endif
+#if defined(ARPHRD_FCAL) || (defined(HAVE_DECL_ARPHRD_FCAL) && HAVE_DECL_ARPHRD_FCAL)
+  XLAT(ARPHRD_FCAL),
+#endif
+#if defined(ARPHRD_FCPL) || (defined(HAVE_DECL_ARPHRD_FCPL) && HAVE_DECL_ARPHRD_FCPL)
+  XLAT(ARPHRD_FCPL),
+#endif
+#if defined(ARPHRD_FCFABRIC) || (defined(HAVE_DECL_ARPHRD_FCFABRIC) && HAVE_DECL_ARPHRD_FCFABRIC)
+  XLAT(ARPHRD_FCFABRIC),
+#endif
+#if defined(ARPHRD_IEEE802_TR) || (defined(HAVE_DECL_ARPHRD_IEEE802_TR) && HAVE_DECL_ARPHRD_IEEE802_TR)
+  XLAT(ARPHRD_IEEE802_TR),
+#endif
+#if defined(ARPHRD_IEEE80211) || (defined(HAVE_DECL_ARPHRD_IEEE80211) && HAVE_DECL_ARPHRD_IEEE80211)
+  XLAT(ARPHRD_IEEE80211),
+#endif
+#if defined(ARPHRD_IEEE80211_PRISM) || (defined(HAVE_DECL_ARPHRD_IEEE80211_PRISM) && HAVE_DECL_ARPHRD_IEEE80211_PRISM)
+  XLAT(ARPHRD_IEEE80211_PRISM),
+#endif
+#if defined(ARPHRD_IEEE80211_RADIOTAP) || (defined(HAVE_DECL_ARPHRD_IEEE80211_RADIOTAP) && HAVE_DECL_ARPHRD_IEEE80211_RADIOTAP)
+  XLAT(ARPHRD_IEEE80211_RADIOTAP),
+#endif
+#if defined(ARPHRD_IEEE802154) || (defined(HAVE_DECL_ARPHRD_IEEE802154) && HAVE_DECL_ARPHRD_IEEE802154)
+  XLAT(ARPHRD_IEEE802154),
+#endif
+#if defined(ARPHRD_IEEE802154_MONITOR) || (defined(HAVE_DECL_ARPHRD_IEEE802154_MONITOR) && HAVE_DECL_ARPHRD_IEEE802154_MONITOR)
+  XLAT(ARPHRD_IEEE802154_MONITOR),
+#endif
+#if defined(ARPHRD_PHONET) || (defined(HAVE_DECL_ARPHRD_PHONET) && HAVE_DECL_ARPHRD_PHONET)
+  XLAT(ARPHRD_PHONET),
+#endif
+#if defined(ARPHRD_PHONET_PIPE) || (defined(HAVE_DECL_ARPHRD_PHONET_PIPE) && HAVE_DECL_ARPHRD_PHONET_PIPE)
+  XLAT(ARPHRD_PHONET_PIPE),
+#endif
+#if defined(ARPHRD_CAIF) || (defined(HAVE_DECL_ARPHRD_CAIF) && HAVE_DECL_ARPHRD_CAIF)
+  XLAT(ARPHRD_CAIF),
+#endif
+#if defined(ARPHRD_IP6GRE) || (defined(HAVE_DECL_ARPHRD_IP6GRE) && HAVE_DECL_ARPHRD_IP6GRE)
+  XLAT(ARPHRD_IP6GRE),
+#endif
+#if defined(ARPHRD_NETLINK) || (defined(HAVE_DECL_ARPHRD_NETLINK) && HAVE_DECL_ARPHRD_NETLINK)
+  XLAT(ARPHRD_NETLINK),
+#endif
+#if defined(ARPHRD_6LOWPAN) || (defined(HAVE_DECL_ARPHRD_6LOWPAN) && HAVE_DECL_ARPHRD_6LOWPAN)
+  XLAT(ARPHRD_6LOWPAN),
+#endif
+#if defined(ARPHRD_VOID) || (defined(HAVE_DECL_ARPHRD_VOID) && HAVE_DECL_ARPHRD_VOID)
+  XLAT(ARPHRD_VOID),
+#endif
+#if defined(ARPHRD_NONE) || (defined(HAVE_DECL_ARPHRD_NONE) && HAVE_DECL_ARPHRD_NONE)
+  XLAT(ARPHRD_NONE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/arp_hardware_types.in b/strace/xlat/arp_hardware_types.in
new file mode 100644
index 0000000..df8b4fc
--- /dev/null
+++ b/strace/xlat/arp_hardware_types.in
@@ -0,0 +1,64 @@
+ARPHRD_NETROM
+ARPHRD_ETHER
+ARPHRD_EETHER
+ARPHRD_AX25
+ARPHRD_PRONET
+ARPHRD_CHAOS
+ARPHRD_IEEE802
+ARPHRD_ARCNET
+ARPHRD_APPLETLK
+ARPHRD_DLCI
+ARPHRD_ATM
+ARPHRD_METRICOM
+ARPHRD_IEEE1394
+ARPHRD_EUI64
+ARPHRD_INFINIBAND
+ARPHRD_SLIP
+ARPHRD_CSLIP
+ARPHRD_SLIP6
+ARPHRD_CSLIP6
+ARPHRD_RSRVD
+ARPHRD_ADAPT
+ARPHRD_ROSE
+ARPHRD_X25
+ARPHRD_HWX25
+ARPHRD_CAN
+ARPHRD_PPP
+ARPHRD_CISCO
+ARPHRD_LAPB
+ARPHRD_DDCMP
+ARPHRD_RAWHDLC
+ARPHRD_TUNNEL
+ARPHRD_TUNNEL6
+ARPHRD_FRAD
+ARPHRD_SKIP
+ARPHRD_LOOPBACK
+ARPHRD_LOCALTLK
+ARPHRD_FDDI
+ARPHRD_BIF
+ARPHRD_SIT
+ARPHRD_IPDDP
+ARPHRD_IPGRE
+ARPHRD_PIMREG
+ARPHRD_HIPPI
+ARPHRD_ASH
+ARPHRD_ECONET
+ARPHRD_IRDA
+ARPHRD_FCPP
+ARPHRD_FCAL
+ARPHRD_FCPL
+ARPHRD_FCFABRIC
+ARPHRD_IEEE802_TR
+ARPHRD_IEEE80211
+ARPHRD_IEEE80211_PRISM
+ARPHRD_IEEE80211_RADIOTAP
+ARPHRD_IEEE802154
+ARPHRD_IEEE802154_MONITOR
+ARPHRD_PHONET
+ARPHRD_PHONET_PIPE
+ARPHRD_CAIF
+ARPHRD_IP6GRE
+ARPHRD_NETLINK
+ARPHRD_6LOWPAN
+ARPHRD_VOID
+ARPHRD_NONE
diff --git a/strace/xlat/at_flags.h b/strace/xlat/at_flags.h
new file mode 100644
index 0000000..5bebc0b
--- /dev/null
+++ b/strace/xlat/at_flags.h
@@ -0,0 +1,29 @@
+/* Generated by ./xlat/gen.sh from ./xlat/at_flags.in; do not edit. */
+#if !(defined(AT_SYMLINK_NOFOLLOW) || (defined(HAVE_DECL_AT_SYMLINK_NOFOLLOW) && HAVE_DECL_AT_SYMLINK_NOFOLLOW))
+# define AT_SYMLINK_NOFOLLOW 0x100
+#endif
+#if !(defined(AT_REMOVEDIR) || (defined(HAVE_DECL_AT_REMOVEDIR) && HAVE_DECL_AT_REMOVEDIR))
+# define AT_REMOVEDIR 0x200
+#endif
+#if !(defined(AT_SYMLINK_FOLLOW) || (defined(HAVE_DECL_AT_SYMLINK_FOLLOW) && HAVE_DECL_AT_SYMLINK_FOLLOW))
+# define AT_SYMLINK_FOLLOW 0x400
+#endif
+#if !(defined(AT_NO_AUTOMOUNT) || (defined(HAVE_DECL_AT_NO_AUTOMOUNT) && HAVE_DECL_AT_NO_AUTOMOUNT))
+# define AT_NO_AUTOMOUNT 0x800
+#endif
+#if !(defined(AT_EMPTY_PATH) || (defined(HAVE_DECL_AT_EMPTY_PATH) && HAVE_DECL_AT_EMPTY_PATH))
+# define AT_EMPTY_PATH 0x1000
+#endif
+
+#ifndef IN_MPERS
+
+const struct xlat at_flags[] = {
+ XLAT(AT_SYMLINK_NOFOLLOW),
+ XLAT(AT_REMOVEDIR),
+ XLAT(AT_SYMLINK_FOLLOW),
+ XLAT(AT_NO_AUTOMOUNT),
+ XLAT(AT_EMPTY_PATH),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/at_flags.in b/strace/xlat/at_flags.in
new file mode 100644
index 0000000..77a8de9
--- /dev/null
+++ b/strace/xlat/at_flags.in
@@ -0,0 +1,5 @@
+AT_SYMLINK_NOFOLLOW	0x100
+AT_REMOVEDIR		0x200
+AT_SYMLINK_FOLLOW	0x400
+AT_NO_AUTOMOUNT		0x800
+AT_EMPTY_PATH		0x1000
diff --git a/strace/xlat/atomic_ops.h b/strace/xlat/atomic_ops.h
new file mode 100644
index 0000000..224dfea
--- /dev/null
+++ b/strace/xlat/atomic_ops.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/atomic_ops.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat atomic_ops in mpers mode
+
+#else
+
+static
+const struct xlat atomic_ops[] = {
+{ OR1K_ATOMIC_SWAP,		"SWAP"		},
+{ OR1K_ATOMIC_CMPXCHG,		"CMPXCHG"	},
+{ OR1K_ATOMIC_XCHG,		"XCHG"		},
+{ OR1K_ATOMIC_ADD,		"ADD"		},
+{ OR1K_ATOMIC_DECPOS,		"DECPOS"	},
+{ OR1K_ATOMIC_AND,		"AND"		},
+{ OR1K_ATOMIC_OR,		"OR"		},
+{ OR1K_ATOMIC_UMAX,		"UMAX"		},
+{ OR1K_ATOMIC_UMIN,		"UMIN"		},
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/atomic_ops.in b/strace/xlat/atomic_ops.in
new file mode 100644
index 0000000..42261ea
--- /dev/null
+++ b/strace/xlat/atomic_ops.in
@@ -0,0 +1,9 @@
+	{ OR1K_ATOMIC_SWAP,		"SWAP"		},
+	{ OR1K_ATOMIC_CMPXCHG,		"CMPXCHG"	},
+	{ OR1K_ATOMIC_XCHG,		"XCHG"		},
+	{ OR1K_ATOMIC_ADD,		"ADD"		},
+	{ OR1K_ATOMIC_DECPOS,		"DECPOS"	},
+	{ OR1K_ATOMIC_AND,		"AND"		},
+	{ OR1K_ATOMIC_OR,		"OR"		},
+	{ OR1K_ATOMIC_UMAX,		"UMAX"		},
+	{ OR1K_ATOMIC_UMIN,		"UMIN"		},
diff --git a/strace/xlat/audit_arch.h b/strace/xlat/audit_arch.h
new file mode 100644
index 0000000..16d3947
--- /dev/null
+++ b/strace/xlat/audit_arch.h
@@ -0,0 +1,129 @@
+/* Generated by ./xlat/gen.sh from ./xlat/audit_arch.in; do not edit. */
+#ifdef EM_ARM
+#endif
+#ifdef EM_FRV
+#endif
+#ifdef EM_MICROBLAZE
+#endif
+#ifdef EM_OPENRISC
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat audit_arch[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat audit_arch[] = {
+/* linux used to have linux/elf-em.h out of sync with linux/audit.h */
+#if defined(AUDIT_ARCH_AARCH64) || (defined(HAVE_DECL_AUDIT_ARCH_AARCH64) && HAVE_DECL_AUDIT_ARCH_AARCH64)
+  XLAT(AUDIT_ARCH_AARCH64),
+#endif
+#if defined(AUDIT_ARCH_ALPHA) || (defined(HAVE_DECL_AUDIT_ARCH_ALPHA) && HAVE_DECL_AUDIT_ARCH_ALPHA)
+  XLAT(AUDIT_ARCH_ALPHA),
+#endif
+#ifdef EM_ARM
+#if defined(AUDIT_ARCH_ARM) || (defined(HAVE_DECL_AUDIT_ARCH_ARM) && HAVE_DECL_AUDIT_ARCH_ARM)
+  XLAT(AUDIT_ARCH_ARM),
+#endif
+#if defined(AUDIT_ARCH_ARMEB) || (defined(HAVE_DECL_AUDIT_ARCH_ARMEB) && HAVE_DECL_AUDIT_ARCH_ARMEB)
+  XLAT(AUDIT_ARCH_ARMEB),
+#endif
+#endif
+#if defined(AUDIT_ARCH_CRIS) || (defined(HAVE_DECL_AUDIT_ARCH_CRIS) && HAVE_DECL_AUDIT_ARCH_CRIS)
+  XLAT(AUDIT_ARCH_CRIS),
+#endif
+#ifdef EM_FRV
+#if defined(AUDIT_ARCH_FRV) || (defined(HAVE_DECL_AUDIT_ARCH_FRV) && HAVE_DECL_AUDIT_ARCH_FRV)
+  XLAT(AUDIT_ARCH_FRV),
+#endif
+#endif
+#if defined(AUDIT_ARCH_I386) || (defined(HAVE_DECL_AUDIT_ARCH_I386) && HAVE_DECL_AUDIT_ARCH_I386)
+  XLAT(AUDIT_ARCH_I386),
+#endif
+#if defined(AUDIT_ARCH_IA64) || (defined(HAVE_DECL_AUDIT_ARCH_IA64) && HAVE_DECL_AUDIT_ARCH_IA64)
+  XLAT(AUDIT_ARCH_IA64),
+#endif
+#if defined(AUDIT_ARCH_M32R) || (defined(HAVE_DECL_AUDIT_ARCH_M32R) && HAVE_DECL_AUDIT_ARCH_M32R)
+  XLAT(AUDIT_ARCH_M32R),
+#endif
+#if defined(AUDIT_ARCH_M68K) || (defined(HAVE_DECL_AUDIT_ARCH_M68K) && HAVE_DECL_AUDIT_ARCH_M68K)
+  XLAT(AUDIT_ARCH_M68K),
+#endif
+#ifdef EM_MICROBLAZE
+#if defined(AUDIT_ARCH_MICROBLAZE) || (defined(HAVE_DECL_AUDIT_ARCH_MICROBLAZE) && HAVE_DECL_AUDIT_ARCH_MICROBLAZE)
+  XLAT(AUDIT_ARCH_MICROBLAZE),
+#endif
+#endif
+#if defined(AUDIT_ARCH_MIPS) || (defined(HAVE_DECL_AUDIT_ARCH_MIPS) && HAVE_DECL_AUDIT_ARCH_MIPS)
+  XLAT(AUDIT_ARCH_MIPS),
+#endif
+#if defined(AUDIT_ARCH_MIPS64) || (defined(HAVE_DECL_AUDIT_ARCH_MIPS64) && HAVE_DECL_AUDIT_ARCH_MIPS64)
+  XLAT(AUDIT_ARCH_MIPS64),
+#endif
+#if defined(AUDIT_ARCH_MIPS64N32) || (defined(HAVE_DECL_AUDIT_ARCH_MIPS64N32) && HAVE_DECL_AUDIT_ARCH_MIPS64N32)
+  XLAT(AUDIT_ARCH_MIPS64N32),
+#endif
+#if defined(AUDIT_ARCH_MIPSEL) || (defined(HAVE_DECL_AUDIT_ARCH_MIPSEL) && HAVE_DECL_AUDIT_ARCH_MIPSEL)
+  XLAT(AUDIT_ARCH_MIPSEL),
+#endif
+#if defined(AUDIT_ARCH_MIPSEL64) || (defined(HAVE_DECL_AUDIT_ARCH_MIPSEL64) && HAVE_DECL_AUDIT_ARCH_MIPSEL64)
+  XLAT(AUDIT_ARCH_MIPSEL64),
+#endif
+#if defined(AUDIT_ARCH_MIPSEL64N32) || (defined(HAVE_DECL_AUDIT_ARCH_MIPSEL64N32) && HAVE_DECL_AUDIT_ARCH_MIPSEL64N32)
+  XLAT(AUDIT_ARCH_MIPSEL64N32),
+#endif
+#ifdef EM_OPENRISC
+#if defined(AUDIT_ARCH_OPENRISC) || (defined(HAVE_DECL_AUDIT_ARCH_OPENRISC) && HAVE_DECL_AUDIT_ARCH_OPENRISC)
+  XLAT(AUDIT_ARCH_OPENRISC),
+#endif
+#endif
+#if defined(AUDIT_ARCH_PARISC) || (defined(HAVE_DECL_AUDIT_ARCH_PARISC) && HAVE_DECL_AUDIT_ARCH_PARISC)
+  XLAT(AUDIT_ARCH_PARISC),
+#endif
+#if defined(AUDIT_ARCH_PARISC64) || (defined(HAVE_DECL_AUDIT_ARCH_PARISC64) && HAVE_DECL_AUDIT_ARCH_PARISC64)
+  XLAT(AUDIT_ARCH_PARISC64),
+#endif
+#if defined(AUDIT_ARCH_PPC) || (defined(HAVE_DECL_AUDIT_ARCH_PPC) && HAVE_DECL_AUDIT_ARCH_PPC)
+  XLAT(AUDIT_ARCH_PPC),
+#endif
+#if defined(AUDIT_ARCH_PPC64) || (defined(HAVE_DECL_AUDIT_ARCH_PPC64) && HAVE_DECL_AUDIT_ARCH_PPC64)
+  XLAT(AUDIT_ARCH_PPC64),
+#endif
+#if defined(AUDIT_ARCH_PPC64LE) || (defined(HAVE_DECL_AUDIT_ARCH_PPC64LE) && HAVE_DECL_AUDIT_ARCH_PPC64LE)
+  XLAT(AUDIT_ARCH_PPC64LE),
+#endif
+#if defined(AUDIT_ARCH_S390) || (defined(HAVE_DECL_AUDIT_ARCH_S390) && HAVE_DECL_AUDIT_ARCH_S390)
+  XLAT(AUDIT_ARCH_S390),
+#endif
+#if defined(AUDIT_ARCH_S390X) || (defined(HAVE_DECL_AUDIT_ARCH_S390X) && HAVE_DECL_AUDIT_ARCH_S390X)
+  XLAT(AUDIT_ARCH_S390X),
+#endif
+#if defined(AUDIT_ARCH_SH) || (defined(HAVE_DECL_AUDIT_ARCH_SH) && HAVE_DECL_AUDIT_ARCH_SH)
+  XLAT(AUDIT_ARCH_SH),
+#endif
+#if defined(AUDIT_ARCH_SH64) || (defined(HAVE_DECL_AUDIT_ARCH_SH64) && HAVE_DECL_AUDIT_ARCH_SH64)
+  XLAT(AUDIT_ARCH_SH64),
+#endif
+#if defined(AUDIT_ARCH_SHEL) || (defined(HAVE_DECL_AUDIT_ARCH_SHEL) && HAVE_DECL_AUDIT_ARCH_SHEL)
+  XLAT(AUDIT_ARCH_SHEL),
+#endif
+#if defined(AUDIT_ARCH_SHEL64) || (defined(HAVE_DECL_AUDIT_ARCH_SHEL64) && HAVE_DECL_AUDIT_ARCH_SHEL64)
+  XLAT(AUDIT_ARCH_SHEL64),
+#endif
+#if defined(AUDIT_ARCH_SPARC) || (defined(HAVE_DECL_AUDIT_ARCH_SPARC) && HAVE_DECL_AUDIT_ARCH_SPARC)
+  XLAT(AUDIT_ARCH_SPARC),
+#endif
+#if defined(AUDIT_ARCH_SPARC64) || (defined(HAVE_DECL_AUDIT_ARCH_SPARC64) && HAVE_DECL_AUDIT_ARCH_SPARC64)
+  XLAT(AUDIT_ARCH_SPARC64),
+#endif
+#if defined(AUDIT_ARCH_X86_64) || (defined(HAVE_DECL_AUDIT_ARCH_X86_64) && HAVE_DECL_AUDIT_ARCH_X86_64)
+  XLAT(AUDIT_ARCH_X86_64),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/audit_arch.in b/strace/xlat/audit_arch.in
new file mode 100644
index 0000000..e0b3db3
--- /dev/null
+++ b/strace/xlat/audit_arch.in
@@ -0,0 +1,41 @@
+/* linux used to have linux/elf-em.h out of sync with linux/audit.h */
+AUDIT_ARCH_AARCH64
+AUDIT_ARCH_ALPHA
+#ifdef EM_ARM
+AUDIT_ARCH_ARM
+AUDIT_ARCH_ARMEB
+#endif
+AUDIT_ARCH_CRIS
+#ifdef EM_FRV
+AUDIT_ARCH_FRV
+#endif
+AUDIT_ARCH_I386
+AUDIT_ARCH_IA64
+AUDIT_ARCH_M32R
+AUDIT_ARCH_M68K
+#ifdef EM_MICROBLAZE
+AUDIT_ARCH_MICROBLAZE
+#endif
+AUDIT_ARCH_MIPS
+AUDIT_ARCH_MIPS64
+AUDIT_ARCH_MIPS64N32
+AUDIT_ARCH_MIPSEL
+AUDIT_ARCH_MIPSEL64
+AUDIT_ARCH_MIPSEL64N32
+#ifdef EM_OPENRISC
+AUDIT_ARCH_OPENRISC
+#endif
+AUDIT_ARCH_PARISC
+AUDIT_ARCH_PARISC64
+AUDIT_ARCH_PPC
+AUDIT_ARCH_PPC64
+AUDIT_ARCH_PPC64LE
+AUDIT_ARCH_S390
+AUDIT_ARCH_S390X
+AUDIT_ARCH_SH
+AUDIT_ARCH_SH64
+AUDIT_ARCH_SHEL
+AUDIT_ARCH_SHEL64
+AUDIT_ARCH_SPARC
+AUDIT_ARCH_SPARC64
+AUDIT_ARCH_X86_64
diff --git a/strace/xlat/baud_options.h b/strace/xlat/baud_options.h
new file mode 100644
index 0000000..0ea7336
--- /dev/null
+++ b/strace/xlat/baud_options.h
@@ -0,0 +1,113 @@
+/* Generated by ./xlat/gen.sh from ./xlat/baud_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat baud_options in mpers mode
+
+#else
+
+static
+const struct xlat baud_options[] = {
+#if defined(B0) || (defined(HAVE_DECL_B0) && HAVE_DECL_B0)
+  XLAT(B0),
+#endif
+#if defined(B50) || (defined(HAVE_DECL_B50) && HAVE_DECL_B50)
+  XLAT(B50),
+#endif
+#if defined(B75) || (defined(HAVE_DECL_B75) && HAVE_DECL_B75)
+  XLAT(B75),
+#endif
+#if defined(B110) || (defined(HAVE_DECL_B110) && HAVE_DECL_B110)
+  XLAT(B110),
+#endif
+#if defined(B134) || (defined(HAVE_DECL_B134) && HAVE_DECL_B134)
+  XLAT(B134),
+#endif
+#if defined(B150) || (defined(HAVE_DECL_B150) && HAVE_DECL_B150)
+  XLAT(B150),
+#endif
+#if defined(B200) || (defined(HAVE_DECL_B200) && HAVE_DECL_B200)
+  XLAT(B200),
+#endif
+#if defined(B300) || (defined(HAVE_DECL_B300) && HAVE_DECL_B300)
+  XLAT(B300),
+#endif
+#if defined(B600) || (defined(HAVE_DECL_B600) && HAVE_DECL_B600)
+  XLAT(B600),
+#endif
+#if defined(B1200) || (defined(HAVE_DECL_B1200) && HAVE_DECL_B1200)
+  XLAT(B1200),
+#endif
+#if defined(B1800) || (defined(HAVE_DECL_B1800) && HAVE_DECL_B1800)
+  XLAT(B1800),
+#endif
+#if defined(B2400) || (defined(HAVE_DECL_B2400) && HAVE_DECL_B2400)
+  XLAT(B2400),
+#endif
+#if defined(B4800) || (defined(HAVE_DECL_B4800) && HAVE_DECL_B4800)
+  XLAT(B4800),
+#endif
+#if defined(B9600) || (defined(HAVE_DECL_B9600) && HAVE_DECL_B9600)
+  XLAT(B9600),
+#endif
+#if defined(B19200) || (defined(HAVE_DECL_B19200) && HAVE_DECL_B19200)
+  XLAT(B19200),
+#endif
+#if defined(B38400) || (defined(HAVE_DECL_B38400) && HAVE_DECL_B38400)
+  XLAT(B38400),
+#endif
+#if defined(B57600) || (defined(HAVE_DECL_B57600) && HAVE_DECL_B57600)
+  XLAT(B57600),
+#endif
+#if defined(B115200) || (defined(HAVE_DECL_B115200) && HAVE_DECL_B115200)
+  XLAT(B115200),
+#endif
+#if defined(B230400) || (defined(HAVE_DECL_B230400) && HAVE_DECL_B230400)
+  XLAT(B230400),
+#endif
+#if defined(B460800) || (defined(HAVE_DECL_B460800) && HAVE_DECL_B460800)
+  XLAT(B460800),
+#endif
+#if defined(B500000) || (defined(HAVE_DECL_B500000) && HAVE_DECL_B500000)
+  XLAT(B500000),
+#endif
+#if defined(B576000) || (defined(HAVE_DECL_B576000) && HAVE_DECL_B576000)
+  XLAT(B576000),
+#endif
+#if defined(B921600) || (defined(HAVE_DECL_B921600) && HAVE_DECL_B921600)
+  XLAT(B921600),
+#endif
+#if defined(B1000000) || (defined(HAVE_DECL_B1000000) && HAVE_DECL_B1000000)
+  XLAT(B1000000),
+#endif
+#if defined(B1152000) || (defined(HAVE_DECL_B1152000) && HAVE_DECL_B1152000)
+  XLAT(B1152000),
+#endif
+#if defined(B1500000) || (defined(HAVE_DECL_B1500000) && HAVE_DECL_B1500000)
+  XLAT(B1500000),
+#endif
+#if defined(B2000000) || (defined(HAVE_DECL_B2000000) && HAVE_DECL_B2000000)
+  XLAT(B2000000),
+#endif
+#if defined(B2500000) || (defined(HAVE_DECL_B2500000) && HAVE_DECL_B2500000)
+  XLAT(B2500000),
+#endif
+#if defined(B3000000) || (defined(HAVE_DECL_B3000000) && HAVE_DECL_B3000000)
+  XLAT(B3000000),
+#endif
+#if defined(B3500000) || (defined(HAVE_DECL_B3500000) && HAVE_DECL_B3500000)
+  XLAT(B3500000),
+#endif
+#if defined(B4000000) || (defined(HAVE_DECL_B4000000) && HAVE_DECL_B4000000)
+  XLAT(B4000000),
+#endif
+#if defined(EXTA) || (defined(HAVE_DECL_EXTA) && HAVE_DECL_EXTA)
+  XLAT(EXTA),
+#endif
+#if defined(EXTB) || (defined(HAVE_DECL_EXTB) && HAVE_DECL_EXTB)
+  XLAT(EXTB),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/baud_options.in b/strace/xlat/baud_options.in
new file mode 100644
index 0000000..be7311a
--- /dev/null
+++ b/strace/xlat/baud_options.in
@@ -0,0 +1,33 @@
+B0
+B50
+B75
+B110
+B134
+B150
+B200
+B300
+B600
+B1200
+B1800
+B2400
+B4800
+B9600
+B19200
+B38400
+B57600
+B115200
+B230400
+B460800
+B500000
+B576000
+B921600
+B1000000
+B1152000
+B1500000
+B2000000
+B2500000
+B3000000
+B3500000
+B4000000
+EXTA
+EXTB
diff --git a/strace/xlat/blkpg_ops.h b/strace/xlat/blkpg_ops.h
new file mode 100644
index 0000000..bc36705
--- /dev/null
+++ b/strace/xlat/blkpg_ops.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/blkpg_ops.in; do not edit. */
+#if !(defined(BLKPG_ADD_PARTITION) || (defined(HAVE_DECL_BLKPG_ADD_PARTITION) && HAVE_DECL_BLKPG_ADD_PARTITION))
+# define BLKPG_ADD_PARTITION 1
+#endif
+#if !(defined(BLKPG_DEL_PARTITION) || (defined(HAVE_DECL_BLKPG_DEL_PARTITION) && HAVE_DECL_BLKPG_DEL_PARTITION))
+# define BLKPG_DEL_PARTITION 2
+#endif
+#if !(defined(BLKPG_RESIZE_PARTITION) || (defined(HAVE_DECL_BLKPG_RESIZE_PARTITION) && HAVE_DECL_BLKPG_RESIZE_PARTITION))
+# define BLKPG_RESIZE_PARTITION 3
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat blkpg_ops[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat blkpg_ops[] = {
+ XLAT(BLKPG_ADD_PARTITION),
+ XLAT(BLKPG_DEL_PARTITION),
+ XLAT(BLKPG_RESIZE_PARTITION),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/blkpg_ops.in b/strace/xlat/blkpg_ops.in
new file mode 100644
index 0000000..fb194de
--- /dev/null
+++ b/strace/xlat/blkpg_ops.in
@@ -0,0 +1,3 @@
+BLKPG_ADD_PARTITION	1
+BLKPG_DEL_PARTITION	2
+BLKPG_RESIZE_PARTITION	3
diff --git a/strace/xlat/bootflags1.h b/strace/xlat/bootflags1.h
new file mode 100644
index 0000000..fb27140
--- /dev/null
+++ b/strace/xlat/bootflags1.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bootflags1.in; do not edit. */
+#if !(defined(LINUX_REBOOT_MAGIC1) || (defined(HAVE_DECL_LINUX_REBOOT_MAGIC1) && HAVE_DECL_LINUX_REBOOT_MAGIC1))
+# define LINUX_REBOOT_MAGIC1 0xfee1dead
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bootflags1 in mpers mode
+
+#else
+
+static
+const struct xlat bootflags1[] = {
+ XLAT(LINUX_REBOOT_MAGIC1),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bootflags1.in b/strace/xlat/bootflags1.in
new file mode 100644
index 0000000..4204823
--- /dev/null
+++ b/strace/xlat/bootflags1.in
@@ -0,0 +1 @@
+LINUX_REBOOT_MAGIC1 0xfee1dead
diff --git a/strace/xlat/bootflags2.h b/strace/xlat/bootflags2.h
new file mode 100644
index 0000000..612aae1
--- /dev/null
+++ b/strace/xlat/bootflags2.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bootflags2.in; do not edit. */
+#if !(defined(LINUX_REBOOT_MAGIC2) || (defined(HAVE_DECL_LINUX_REBOOT_MAGIC2) && HAVE_DECL_LINUX_REBOOT_MAGIC2))
+# define LINUX_REBOOT_MAGIC2 672274793
+#endif
+#if !(defined(LINUX_REBOOT_MAGIC2A) || (defined(HAVE_DECL_LINUX_REBOOT_MAGIC2A) && HAVE_DECL_LINUX_REBOOT_MAGIC2A))
+# define LINUX_REBOOT_MAGIC2A 85072278
+#endif
+#if !(defined(LINUX_REBOOT_MAGIC2B) || (defined(HAVE_DECL_LINUX_REBOOT_MAGIC2B) && HAVE_DECL_LINUX_REBOOT_MAGIC2B))
+# define LINUX_REBOOT_MAGIC2B 369367448
+#endif
+#if !(defined(LINUX_REBOOT_MAGIC2C) || (defined(HAVE_DECL_LINUX_REBOOT_MAGIC2C) && HAVE_DECL_LINUX_REBOOT_MAGIC2C))
+# define LINUX_REBOOT_MAGIC2C 537993216
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bootflags2 in mpers mode
+
+#else
+
+static
+const struct xlat bootflags2[] = {
+ XLAT(LINUX_REBOOT_MAGIC2),
+ XLAT(LINUX_REBOOT_MAGIC2A),
+ XLAT(LINUX_REBOOT_MAGIC2B),
+ XLAT(LINUX_REBOOT_MAGIC2C),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bootflags2.in b/strace/xlat/bootflags2.in
new file mode 100644
index 0000000..8daa342
--- /dev/null
+++ b/strace/xlat/bootflags2.in
@@ -0,0 +1,4 @@
+LINUX_REBOOT_MAGIC2 672274793
+LINUX_REBOOT_MAGIC2A 85072278
+LINUX_REBOOT_MAGIC2B 369367448
+LINUX_REBOOT_MAGIC2C 537993216
diff --git a/strace/xlat/bootflags3.h b/strace/xlat/bootflags3.h
new file mode 100644
index 0000000..47ea9cf
--- /dev/null
+++ b/strace/xlat/bootflags3.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bootflags3.in; do not edit. */
+#if !(defined(LINUX_REBOOT_CMD_RESTART) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_RESTART) && HAVE_DECL_LINUX_REBOOT_CMD_RESTART))
+# define LINUX_REBOOT_CMD_RESTART 0x01234567
+#endif
+#if !(defined(LINUX_REBOOT_CMD_HALT) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_HALT) && HAVE_DECL_LINUX_REBOOT_CMD_HALT))
+# define LINUX_REBOOT_CMD_HALT 0xCDEF0123
+#endif
+#if !(defined(LINUX_REBOOT_CMD_CAD_ON) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_CAD_ON) && HAVE_DECL_LINUX_REBOOT_CMD_CAD_ON))
+# define LINUX_REBOOT_CMD_CAD_ON 0x89ABCDEF
+#endif
+#if !(defined(LINUX_REBOOT_CMD_CAD_OFF) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_CAD_OFF) && HAVE_DECL_LINUX_REBOOT_CMD_CAD_OFF))
+# define LINUX_REBOOT_CMD_CAD_OFF 0x00000000
+#endif
+#if !(defined(LINUX_REBOOT_CMD_POWER_OFF) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_POWER_OFF) && HAVE_DECL_LINUX_REBOOT_CMD_POWER_OFF))
+# define LINUX_REBOOT_CMD_POWER_OFF 0x4321FEDC
+#endif
+#if !(defined(LINUX_REBOOT_CMD_RESTART2) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_RESTART2) && HAVE_DECL_LINUX_REBOOT_CMD_RESTART2))
+# define LINUX_REBOOT_CMD_RESTART2 0xA1B2C3D4
+#endif
+#if !(defined(LINUX_REBOOT_CMD_SW_SUSPEND) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_SW_SUSPEND) && HAVE_DECL_LINUX_REBOOT_CMD_SW_SUSPEND))
+# define LINUX_REBOOT_CMD_SW_SUSPEND 0xD000FCE2
+#endif
+#if !(defined(LINUX_REBOOT_CMD_KEXEC) || (defined(HAVE_DECL_LINUX_REBOOT_CMD_KEXEC) && HAVE_DECL_LINUX_REBOOT_CMD_KEXEC))
+# define LINUX_REBOOT_CMD_KEXEC 0x45584543
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bootflags3 in mpers mode
+
+#else
+
+static
+const struct xlat bootflags3[] = {
+ XLAT(LINUX_REBOOT_CMD_RESTART),
+ XLAT(LINUX_REBOOT_CMD_HALT),
+ XLAT(LINUX_REBOOT_CMD_CAD_ON),
+ XLAT(LINUX_REBOOT_CMD_CAD_OFF),
+ XLAT(LINUX_REBOOT_CMD_POWER_OFF),
+ XLAT(LINUX_REBOOT_CMD_RESTART2),
+ XLAT(LINUX_REBOOT_CMD_SW_SUSPEND),
+ XLAT(LINUX_REBOOT_CMD_KEXEC),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bootflags3.in b/strace/xlat/bootflags3.in
new file mode 100644
index 0000000..c0337e8
--- /dev/null
+++ b/strace/xlat/bootflags3.in
@@ -0,0 +1,8 @@
+LINUX_REBOOT_CMD_RESTART 0x01234567
+LINUX_REBOOT_CMD_HALT 0xCDEF0123
+LINUX_REBOOT_CMD_CAD_ON 0x89ABCDEF
+LINUX_REBOOT_CMD_CAD_OFF 0x00000000
+LINUX_REBOOT_CMD_POWER_OFF 0x4321FEDC
+LINUX_REBOOT_CMD_RESTART2 0xA1B2C3D4
+LINUX_REBOOT_CMD_SW_SUSPEND 0xD000FCE2
+LINUX_REBOOT_CMD_KEXEC 0x45584543
diff --git a/strace/xlat/bpf_class.h b/strace/xlat/bpf_class.h
new file mode 100644
index 0000000..bdabc9a
--- /dev/null
+++ b/strace/xlat/bpf_class.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_class.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_class in mpers mode
+
+#else
+
+static
+const struct xlat bpf_class[] = {
+#if defined(BPF_LD) || (defined(HAVE_DECL_BPF_LD) && HAVE_DECL_BPF_LD)
+  XLAT(BPF_LD),
+#endif
+#if defined(BPF_LDX) || (defined(HAVE_DECL_BPF_LDX) && HAVE_DECL_BPF_LDX)
+  XLAT(BPF_LDX),
+#endif
+#if defined(BPF_ST) || (defined(HAVE_DECL_BPF_ST) && HAVE_DECL_BPF_ST)
+  XLAT(BPF_ST),
+#endif
+#if defined(BPF_STX) || (defined(HAVE_DECL_BPF_STX) && HAVE_DECL_BPF_STX)
+  XLAT(BPF_STX),
+#endif
+#if defined(BPF_ALU) || (defined(HAVE_DECL_BPF_ALU) && HAVE_DECL_BPF_ALU)
+  XLAT(BPF_ALU),
+#endif
+#if defined(BPF_JMP) || (defined(HAVE_DECL_BPF_JMP) && HAVE_DECL_BPF_JMP)
+  XLAT(BPF_JMP),
+#endif
+#if defined(BPF_RET) || (defined(HAVE_DECL_BPF_RET) && HAVE_DECL_BPF_RET)
+  XLAT(BPF_RET),
+#endif
+#if defined(BPF_MISC) || (defined(HAVE_DECL_BPF_MISC) && HAVE_DECL_BPF_MISC)
+  XLAT(BPF_MISC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_class.in b/strace/xlat/bpf_class.in
new file mode 100644
index 0000000..f8bd3d7
--- /dev/null
+++ b/strace/xlat/bpf_class.in
@@ -0,0 +1,8 @@
+BPF_LD
+BPF_LDX
+BPF_ST
+BPF_STX
+BPF_ALU
+BPF_JMP
+BPF_RET
+BPF_MISC
diff --git a/strace/xlat/bpf_commands.h b/strace/xlat/bpf_commands.h
new file mode 100644
index 0000000..56e9968
--- /dev/null
+++ b/strace/xlat/bpf_commands.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_commands.in; do not edit. */
+#if !(defined(BPF_MAP_CREATE) || (defined(HAVE_DECL_BPF_MAP_CREATE) && HAVE_DECL_BPF_MAP_CREATE))
+# define BPF_MAP_CREATE 0
+#endif
+#if !(defined(BPF_MAP_LOOKUP_ELEM) || (defined(HAVE_DECL_BPF_MAP_LOOKUP_ELEM) && HAVE_DECL_BPF_MAP_LOOKUP_ELEM))
+# define BPF_MAP_LOOKUP_ELEM 1
+#endif
+#if !(defined(BPF_MAP_UPDATE_ELEM) || (defined(HAVE_DECL_BPF_MAP_UPDATE_ELEM) && HAVE_DECL_BPF_MAP_UPDATE_ELEM))
+# define BPF_MAP_UPDATE_ELEM 2
+#endif
+#if !(defined(BPF_MAP_DELETE_ELEM) || (defined(HAVE_DECL_BPF_MAP_DELETE_ELEM) && HAVE_DECL_BPF_MAP_DELETE_ELEM))
+# define BPF_MAP_DELETE_ELEM 3
+#endif
+#if !(defined(BPF_MAP_GET_NEXT_KEY) || (defined(HAVE_DECL_BPF_MAP_GET_NEXT_KEY) && HAVE_DECL_BPF_MAP_GET_NEXT_KEY))
+# define BPF_MAP_GET_NEXT_KEY 4
+#endif
+#if !(defined(BPF_PROG_LOAD) || (defined(HAVE_DECL_BPF_PROG_LOAD) && HAVE_DECL_BPF_PROG_LOAD))
+# define BPF_PROG_LOAD 5
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_commands in mpers mode
+
+#else
+
+static
+const struct xlat bpf_commands[] = {
+ XLAT(BPF_MAP_CREATE),
+ XLAT(BPF_MAP_LOOKUP_ELEM),
+ XLAT(BPF_MAP_UPDATE_ELEM),
+ XLAT(BPF_MAP_DELETE_ELEM),
+ XLAT(BPF_MAP_GET_NEXT_KEY),
+ XLAT(BPF_PROG_LOAD),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_commands.in b/strace/xlat/bpf_commands.in
new file mode 100644
index 0000000..5c3035f
--- /dev/null
+++ b/strace/xlat/bpf_commands.in
@@ -0,0 +1,6 @@
+BPF_MAP_CREATE 0
+BPF_MAP_LOOKUP_ELEM 1
+BPF_MAP_UPDATE_ELEM 2
+BPF_MAP_DELETE_ELEM 3
+BPF_MAP_GET_NEXT_KEY 4
+BPF_PROG_LOAD 5
diff --git a/strace/xlat/bpf_map_types.h b/strace/xlat/bpf_map_types.h
new file mode 100644
index 0000000..2ce223a
--- /dev/null
+++ b/strace/xlat/bpf_map_types.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_map_types.in; do not edit. */
+#if !(defined(BPF_MAP_TYPE_UNSPEC) || (defined(HAVE_DECL_BPF_MAP_TYPE_UNSPEC) && HAVE_DECL_BPF_MAP_TYPE_UNSPEC))
+# define BPF_MAP_TYPE_UNSPEC 0
+#endif
+#if !(defined(BPF_MAP_TYPE_HASH) || (defined(HAVE_DECL_BPF_MAP_TYPE_HASH) && HAVE_DECL_BPF_MAP_TYPE_HASH))
+# define BPF_MAP_TYPE_HASH 1
+#endif
+#if !(defined(BPF_MAP_TYPE_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_ARRAY))
+# define BPF_MAP_TYPE_ARRAY 2
+#endif
+#if !(defined(BPF_MAP_TYPE_PROG_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_PROG_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_PROG_ARRAY))
+# define BPF_MAP_TYPE_PROG_ARRAY 3
+#endif
+#if !(defined(BPF_MAP_TYPE_PERF_EVENT_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_PERF_EVENT_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_PERF_EVENT_ARRAY))
+# define BPF_MAP_TYPE_PERF_EVENT_ARRAY 4
+#endif
+#if !(defined(BPF_MAP_TYPE_PERCPU_HASH) || (defined(HAVE_DECL_BPF_MAP_TYPE_PERCPU_HASH) && HAVE_DECL_BPF_MAP_TYPE_PERCPU_HASH))
+# define BPF_MAP_TYPE_PERCPU_HASH 5
+#endif
+#if !(defined(BPF_MAP_TYPE_PERCPU_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_PERCPU_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_PERCPU_ARRAY))
+# define BPF_MAP_TYPE_PERCPU_ARRAY 6
+#endif
+#if !(defined(BPF_MAP_TYPE_STACK_TRACE) || (defined(HAVE_DECL_BPF_MAP_TYPE_STACK_TRACE) && HAVE_DECL_BPF_MAP_TYPE_STACK_TRACE))
+# define BPF_MAP_TYPE_STACK_TRACE 7
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_map_types in mpers mode
+
+#else
+
+static
+const struct xlat bpf_map_types[] = {
+ XLAT(BPF_MAP_TYPE_UNSPEC),
+ XLAT(BPF_MAP_TYPE_HASH),
+ XLAT(BPF_MAP_TYPE_ARRAY),
+ XLAT(BPF_MAP_TYPE_PROG_ARRAY),
+ XLAT(BPF_MAP_TYPE_PERF_EVENT_ARRAY),
+ XLAT(BPF_MAP_TYPE_PERCPU_HASH),
+ XLAT(BPF_MAP_TYPE_PERCPU_ARRAY),
+ XLAT(BPF_MAP_TYPE_STACK_TRACE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_map_types.in b/strace/xlat/bpf_map_types.in
new file mode 100644
index 0000000..b048af1
--- /dev/null
+++ b/strace/xlat/bpf_map_types.in
@@ -0,0 +1,8 @@
+BPF_MAP_TYPE_UNSPEC 0
+BPF_MAP_TYPE_HASH 1
+BPF_MAP_TYPE_ARRAY 2
+BPF_MAP_TYPE_PROG_ARRAY 3
+BPF_MAP_TYPE_PERF_EVENT_ARRAY 4
+BPF_MAP_TYPE_PERCPU_HASH 5
+BPF_MAP_TYPE_PERCPU_ARRAY 6
+BPF_MAP_TYPE_STACK_TRACE 7
diff --git a/strace/xlat/bpf_map_update_elem_flags.h b/strace/xlat/bpf_map_update_elem_flags.h
new file mode 100644
index 0000000..038863e
--- /dev/null
+++ b/strace/xlat/bpf_map_update_elem_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_map_update_elem_flags.in; do not edit. */
+#if !(defined(BPF_ANY) || (defined(HAVE_DECL_BPF_ANY) && HAVE_DECL_BPF_ANY))
+# define BPF_ANY 0
+#endif
+#if !(defined(BPF_NOEXIST) || (defined(HAVE_DECL_BPF_NOEXIST) && HAVE_DECL_BPF_NOEXIST))
+# define BPF_NOEXIST 1
+#endif
+#if !(defined(BPF_EXIST) || (defined(HAVE_DECL_BPF_EXIST) && HAVE_DECL_BPF_EXIST))
+# define BPF_EXIST 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_map_update_elem_flags in mpers mode
+
+#else
+
+static
+const struct xlat bpf_map_update_elem_flags[] = {
+ XLAT(BPF_ANY),
+ XLAT(BPF_NOEXIST),
+ XLAT(BPF_EXIST),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_map_update_elem_flags.in b/strace/xlat/bpf_map_update_elem_flags.in
new file mode 100644
index 0000000..6b1d61f
--- /dev/null
+++ b/strace/xlat/bpf_map_update_elem_flags.in
@@ -0,0 +1,3 @@
+BPF_ANY 0
+BPF_NOEXIST 1
+BPF_EXIST 2
diff --git a/strace/xlat/bpf_miscop.h b/strace/xlat/bpf_miscop.h
new file mode 100644
index 0000000..bedf35b
--- /dev/null
+++ b/strace/xlat/bpf_miscop.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_miscop.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_miscop in mpers mode
+
+#else
+
+static
+const struct xlat bpf_miscop[] = {
+#if defined(BPF_TAX) || (defined(HAVE_DECL_BPF_TAX) && HAVE_DECL_BPF_TAX)
+  XLAT(BPF_TAX),
+#endif
+#if defined(BPF_TXA) || (defined(HAVE_DECL_BPF_TXA) && HAVE_DECL_BPF_TXA)
+  XLAT(BPF_TXA),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_miscop.in b/strace/xlat/bpf_miscop.in
new file mode 100644
index 0000000..c9703b1
--- /dev/null
+++ b/strace/xlat/bpf_miscop.in
@@ -0,0 +1,2 @@
+BPF_TAX
+BPF_TXA
diff --git a/strace/xlat/bpf_mode.h b/strace/xlat/bpf_mode.h
new file mode 100644
index 0000000..0e3c862
--- /dev/null
+++ b/strace/xlat/bpf_mode.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_mode.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_mode in mpers mode
+
+#else
+
+static
+const struct xlat bpf_mode[] = {
+#if defined(BPF_IMM) || (defined(HAVE_DECL_BPF_IMM) && HAVE_DECL_BPF_IMM)
+  XLAT(BPF_IMM),
+#endif
+#if defined(BPF_ABS) || (defined(HAVE_DECL_BPF_ABS) && HAVE_DECL_BPF_ABS)
+  XLAT(BPF_ABS),
+#endif
+#if defined(BPF_IND) || (defined(HAVE_DECL_BPF_IND) && HAVE_DECL_BPF_IND)
+  XLAT(BPF_IND),
+#endif
+#if defined(BPF_MEM) || (defined(HAVE_DECL_BPF_MEM) && HAVE_DECL_BPF_MEM)
+  XLAT(BPF_MEM),
+#endif
+#if defined(BPF_LEN) || (defined(HAVE_DECL_BPF_LEN) && HAVE_DECL_BPF_LEN)
+  XLAT(BPF_LEN),
+#endif
+#if defined(BPF_MSH) || (defined(HAVE_DECL_BPF_MSH) && HAVE_DECL_BPF_MSH)
+  XLAT(BPF_MSH),
+#endif
+#if defined(BPF_XADD) || (defined(HAVE_DECL_BPF_XADD) && HAVE_DECL_BPF_XADD)
+  XLAT(BPF_XADD),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_mode.in b/strace/xlat/bpf_mode.in
new file mode 100644
index 0000000..10adecd
--- /dev/null
+++ b/strace/xlat/bpf_mode.in
@@ -0,0 +1,7 @@
+BPF_IMM
+BPF_ABS
+BPF_IND
+BPF_MEM
+BPF_LEN
+BPF_MSH
+BPF_XADD
diff --git a/strace/xlat/bpf_op_alu.h b/strace/xlat/bpf_op_alu.h
new file mode 100644
index 0000000..d20a8c7
--- /dev/null
+++ b/strace/xlat/bpf_op_alu.h
@@ -0,0 +1,53 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_op_alu.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_op_alu in mpers mode
+
+#else
+
+static
+const struct xlat bpf_op_alu[] = {
+#if defined(BPF_ADD) || (defined(HAVE_DECL_BPF_ADD) && HAVE_DECL_BPF_ADD)
+  XLAT(BPF_ADD),
+#endif
+#if defined(BPF_SUB) || (defined(HAVE_DECL_BPF_SUB) && HAVE_DECL_BPF_SUB)
+  XLAT(BPF_SUB),
+#endif
+#if defined(BPF_MUL) || (defined(HAVE_DECL_BPF_MUL) && HAVE_DECL_BPF_MUL)
+  XLAT(BPF_MUL),
+#endif
+#if defined(BPF_DIV) || (defined(HAVE_DECL_BPF_DIV) && HAVE_DECL_BPF_DIV)
+  XLAT(BPF_DIV),
+#endif
+#if defined(BPF_OR) || (defined(HAVE_DECL_BPF_OR) && HAVE_DECL_BPF_OR)
+  XLAT(BPF_OR),
+#endif
+#if defined(BPF_AND) || (defined(HAVE_DECL_BPF_AND) && HAVE_DECL_BPF_AND)
+  XLAT(BPF_AND),
+#endif
+#if defined(BPF_LSH) || (defined(HAVE_DECL_BPF_LSH) && HAVE_DECL_BPF_LSH)
+  XLAT(BPF_LSH),
+#endif
+#if defined(BPF_RSH) || (defined(HAVE_DECL_BPF_RSH) && HAVE_DECL_BPF_RSH)
+  XLAT(BPF_RSH),
+#endif
+#if defined(BPF_NEG) || (defined(HAVE_DECL_BPF_NEG) && HAVE_DECL_BPF_NEG)
+  XLAT(BPF_NEG),
+#endif
+#if defined(BPF_MOD) || (defined(HAVE_DECL_BPF_MOD) && HAVE_DECL_BPF_MOD)
+  XLAT(BPF_MOD),
+#endif
+#if defined(BPF_XOR) || (defined(HAVE_DECL_BPF_XOR) && HAVE_DECL_BPF_XOR)
+  XLAT(BPF_XOR),
+#endif
+#if defined(BPF_MOV) || (defined(HAVE_DECL_BPF_MOV) && HAVE_DECL_BPF_MOV)
+  XLAT(BPF_MOV),
+#endif
+#if defined(BPF_ARSH) || (defined(HAVE_DECL_BPF_ARSH) && HAVE_DECL_BPF_ARSH)
+  XLAT(BPF_ARSH),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_op_alu.in b/strace/xlat/bpf_op_alu.in
new file mode 100644
index 0000000..e43aec6
--- /dev/null
+++ b/strace/xlat/bpf_op_alu.in
@@ -0,0 +1,13 @@
+BPF_ADD
+BPF_SUB
+BPF_MUL
+BPF_DIV
+BPF_OR
+BPF_AND
+BPF_LSH
+BPF_RSH
+BPF_NEG
+BPF_MOD
+BPF_XOR
+BPF_MOV
+BPF_ARSH
diff --git a/strace/xlat/bpf_op_jmp.h b/strace/xlat/bpf_op_jmp.h
new file mode 100644
index 0000000..d43b30e
--- /dev/null
+++ b/strace/xlat/bpf_op_jmp.h
@@ -0,0 +1,44 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_op_jmp.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_op_jmp in mpers mode
+
+#else
+
+static
+const struct xlat bpf_op_jmp[] = {
+#if defined(BPF_JA) || (defined(HAVE_DECL_BPF_JA) && HAVE_DECL_BPF_JA)
+  XLAT(BPF_JA),
+#endif
+#if defined(BPF_JEQ) || (defined(HAVE_DECL_BPF_JEQ) && HAVE_DECL_BPF_JEQ)
+  XLAT(BPF_JEQ),
+#endif
+#if defined(BPF_JGT) || (defined(HAVE_DECL_BPF_JGT) && HAVE_DECL_BPF_JGT)
+  XLAT(BPF_JGT),
+#endif
+#if defined(BPF_JGE) || (defined(HAVE_DECL_BPF_JGE) && HAVE_DECL_BPF_JGE)
+  XLAT(BPF_JGE),
+#endif
+#if defined(BPF_JSET) || (defined(HAVE_DECL_BPF_JSET) && HAVE_DECL_BPF_JSET)
+  XLAT(BPF_JSET),
+#endif
+#if defined(BPF_JNE) || (defined(HAVE_DECL_BPF_JNE) && HAVE_DECL_BPF_JNE)
+  XLAT(BPF_JNE),
+#endif
+#if defined(BPF_JSGT) || (defined(HAVE_DECL_BPF_JSGT) && HAVE_DECL_BPF_JSGT)
+  XLAT(BPF_JSGT),
+#endif
+#if defined(BPF_JSGE) || (defined(HAVE_DECL_BPF_JSGE) && HAVE_DECL_BPF_JSGE)
+  XLAT(BPF_JSGE),
+#endif
+#if defined(BPF_CALL) || (defined(HAVE_DECL_BPF_CALL) && HAVE_DECL_BPF_CALL)
+  XLAT(BPF_CALL),
+#endif
+#if defined(BPF_EXIT) || (defined(HAVE_DECL_BPF_EXIT) && HAVE_DECL_BPF_EXIT)
+  XLAT(BPF_EXIT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_op_jmp.in b/strace/xlat/bpf_op_jmp.in
new file mode 100644
index 0000000..456c0af
--- /dev/null
+++ b/strace/xlat/bpf_op_jmp.in
@@ -0,0 +1,10 @@
+BPF_JA
+BPF_JEQ
+BPF_JGT
+BPF_JGE
+BPF_JSET
+BPF_JNE
+BPF_JSGT
+BPF_JSGE
+BPF_CALL
+BPF_EXIT
diff --git a/strace/xlat/bpf_prog_types.h b/strace/xlat/bpf_prog_types.h
new file mode 100644
index 0000000..43f3e8e
--- /dev/null
+++ b/strace/xlat/bpf_prog_types.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_prog_types.in; do not edit. */
+#if !(defined(BPF_PROG_TYPE_UNSPEC) || (defined(HAVE_DECL_BPF_PROG_TYPE_UNSPEC) && HAVE_DECL_BPF_PROG_TYPE_UNSPEC))
+# define BPF_PROG_TYPE_UNSPEC 0
+#endif
+#if !(defined(BPF_PROG_TYPE_SOCKET_FILTER) || (defined(HAVE_DECL_BPF_PROG_TYPE_SOCKET_FILTER) && HAVE_DECL_BPF_PROG_TYPE_SOCKET_FILTER))
+# define BPF_PROG_TYPE_SOCKET_FILTER 1
+#endif
+#if !(defined(BPF_PROG_TYPE_KPROBE) || (defined(HAVE_DECL_BPF_PROG_TYPE_KPROBE) && HAVE_DECL_BPF_PROG_TYPE_KPROBE))
+# define BPF_PROG_TYPE_KPROBE 2
+#endif
+#if !(defined(BPF_PROG_TYPE_SCHED_CLS) || (defined(HAVE_DECL_BPF_PROG_TYPE_SCHED_CLS) && HAVE_DECL_BPF_PROG_TYPE_SCHED_CLS))
+# define BPF_PROG_TYPE_SCHED_CLS 3
+#endif
+#if !(defined(BPF_PROG_TYPE_SCHED_ACT) || (defined(HAVE_DECL_BPF_PROG_TYPE_SCHED_ACT) && HAVE_DECL_BPF_PROG_TYPE_SCHED_ACT))
+# define BPF_PROG_TYPE_SCHED_ACT 4
+#endif
+#if !(defined(BPF_PROG_TYPE_TRACEPOINT) || (defined(HAVE_DECL_BPF_PROG_TYPE_TRACEPOINT) && HAVE_DECL_BPF_PROG_TYPE_TRACEPOINT))
+# define BPF_PROG_TYPE_TRACEPOINT 5
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_prog_types in mpers mode
+
+#else
+
+static
+const struct xlat bpf_prog_types[] = {
+ XLAT(BPF_PROG_TYPE_UNSPEC),
+ XLAT(BPF_PROG_TYPE_SOCKET_FILTER),
+ XLAT(BPF_PROG_TYPE_KPROBE),
+ XLAT(BPF_PROG_TYPE_SCHED_CLS),
+ XLAT(BPF_PROG_TYPE_SCHED_ACT),
+ XLAT(BPF_PROG_TYPE_TRACEPOINT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_prog_types.in b/strace/xlat/bpf_prog_types.in
new file mode 100644
index 0000000..e6e8446
--- /dev/null
+++ b/strace/xlat/bpf_prog_types.in
@@ -0,0 +1,6 @@
+BPF_PROG_TYPE_UNSPEC 0
+BPF_PROG_TYPE_SOCKET_FILTER 1
+BPF_PROG_TYPE_KPROBE 2
+BPF_PROG_TYPE_SCHED_CLS 3
+BPF_PROG_TYPE_SCHED_ACT 4
+BPF_PROG_TYPE_TRACEPOINT 5
diff --git a/strace/xlat/bpf_rval.h b/strace/xlat/bpf_rval.h
new file mode 100644
index 0000000..8f84f03
--- /dev/null
+++ b/strace/xlat/bpf_rval.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_rval.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_rval in mpers mode
+
+#else
+
+static
+const struct xlat bpf_rval[] = {
+#if defined(BPF_K) || (defined(HAVE_DECL_BPF_K) && HAVE_DECL_BPF_K)
+  XLAT(BPF_K),
+#endif
+#if defined(BPF_X) || (defined(HAVE_DECL_BPF_X) && HAVE_DECL_BPF_X)
+  XLAT(BPF_X),
+#endif
+#if defined(BPF_A) || (defined(HAVE_DECL_BPF_A) && HAVE_DECL_BPF_A)
+  XLAT(BPF_A),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_rval.in b/strace/xlat/bpf_rval.in
new file mode 100644
index 0000000..44e137e
--- /dev/null
+++ b/strace/xlat/bpf_rval.in
@@ -0,0 +1,3 @@
+BPF_K
+BPF_X
+BPF_A
diff --git a/strace/xlat/bpf_size.h b/strace/xlat/bpf_size.h
new file mode 100644
index 0000000..f07bc9c
--- /dev/null
+++ b/strace/xlat/bpf_size.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_size.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_size in mpers mode
+
+#else
+
+static
+const struct xlat bpf_size[] = {
+#if defined(BPF_W) || (defined(HAVE_DECL_BPF_W) && HAVE_DECL_BPF_W)
+  XLAT(BPF_W),
+#endif
+#if defined(BPF_H) || (defined(HAVE_DECL_BPF_H) && HAVE_DECL_BPF_H)
+  XLAT(BPF_H),
+#endif
+#if defined(BPF_B) || (defined(HAVE_DECL_BPF_B) && HAVE_DECL_BPF_B)
+  XLAT(BPF_B),
+#endif
+#if defined(BPF_DW) || (defined(HAVE_DECL_BPF_DW) && HAVE_DECL_BPF_DW)
+  XLAT(BPF_DW),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_size.in b/strace/xlat/bpf_size.in
new file mode 100644
index 0000000..5e0a508
--- /dev/null
+++ b/strace/xlat/bpf_size.in
@@ -0,0 +1,4 @@
+BPF_W
+BPF_H
+BPF_B
+BPF_DW
diff --git a/strace/xlat/bpf_src.h b/strace/xlat/bpf_src.h
new file mode 100644
index 0000000..c063e75
--- /dev/null
+++ b/strace/xlat/bpf_src.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bpf_src.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bpf_src in mpers mode
+
+#else
+
+static
+const struct xlat bpf_src[] = {
+#if defined(BPF_K) || (defined(HAVE_DECL_BPF_K) && HAVE_DECL_BPF_K)
+  XLAT(BPF_K),
+#endif
+#if defined(BPF_X) || (defined(HAVE_DECL_BPF_X) && HAVE_DECL_BPF_X)
+  XLAT(BPF_X),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bpf_src.in b/strace/xlat/bpf_src.in
new file mode 100644
index 0000000..ede6abb
--- /dev/null
+++ b/strace/xlat/bpf_src.in
@@ -0,0 +1,2 @@
+BPF_K
+BPF_X
diff --git a/strace/xlat/bsg_protocol.h b/strace/xlat/bsg_protocol.h
new file mode 100644
index 0000000..541085d
--- /dev/null
+++ b/strace/xlat/bsg_protocol.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bsg_protocol.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bsg_protocol in mpers mode
+
+#else
+
+static
+const struct xlat bsg_protocol[] = {
+#if defined(BSG_PROTOCOL_SCSI) || (defined(HAVE_DECL_BSG_PROTOCOL_SCSI) && HAVE_DECL_BSG_PROTOCOL_SCSI)
+  XLAT(BSG_PROTOCOL_SCSI),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bsg_protocol.in b/strace/xlat/bsg_protocol.in
new file mode 100644
index 0000000..d47f15b
--- /dev/null
+++ b/strace/xlat/bsg_protocol.in
@@ -0,0 +1 @@
+BSG_PROTOCOL_SCSI
diff --git a/strace/xlat/bsg_subprotocol.h b/strace/xlat/bsg_subprotocol.h
new file mode 100644
index 0000000..8073213
--- /dev/null
+++ b/strace/xlat/bsg_subprotocol.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bsg_subprotocol.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bsg_subprotocol in mpers mode
+
+#else
+
+static
+const struct xlat bsg_subprotocol[] = {
+#if defined(BSG_SUB_PROTOCOL_SCSI_CMD) || (defined(HAVE_DECL_BSG_SUB_PROTOCOL_SCSI_CMD) && HAVE_DECL_BSG_SUB_PROTOCOL_SCSI_CMD)
+  XLAT(BSG_SUB_PROTOCOL_SCSI_CMD),
+#endif
+#if defined(BSG_SUB_PROTOCOL_SCSI_TMF) || (defined(HAVE_DECL_BSG_SUB_PROTOCOL_SCSI_TMF) && HAVE_DECL_BSG_SUB_PROTOCOL_SCSI_TMF)
+  XLAT(BSG_SUB_PROTOCOL_SCSI_TMF),
+#endif
+#if defined(BSG_SUB_PROTOCOL_SCSI_TRANSPORT) || (defined(HAVE_DECL_BSG_SUB_PROTOCOL_SCSI_TRANSPORT) && HAVE_DECL_BSG_SUB_PROTOCOL_SCSI_TRANSPORT)
+  XLAT(BSG_SUB_PROTOCOL_SCSI_TRANSPORT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bsg_subprotocol.in b/strace/xlat/bsg_subprotocol.in
new file mode 100644
index 0000000..5e63cd0
--- /dev/null
+++ b/strace/xlat/bsg_subprotocol.in
@@ -0,0 +1,3 @@
+BSG_SUB_PROTOCOL_SCSI_CMD
+BSG_SUB_PROTOCOL_SCSI_TMF
+BSG_SUB_PROTOCOL_SCSI_TRANSPORT
diff --git a/strace/xlat/bt_protocols.h b/strace/xlat/bt_protocols.h
new file mode 100644
index 0000000..7b0e164
--- /dev/null
+++ b/strace/xlat/bt_protocols.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/bt_protocols.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat bt_protocols in mpers mode
+
+#else
+
+static
+const struct xlat bt_protocols[] = {
+#if defined(BTPROTO_L2CAP) || (defined(HAVE_DECL_BTPROTO_L2CAP) && HAVE_DECL_BTPROTO_L2CAP)
+  XLAT(BTPROTO_L2CAP),
+#endif
+#if defined(BTPROTO_HCI) || (defined(HAVE_DECL_BTPROTO_HCI) && HAVE_DECL_BTPROTO_HCI)
+  XLAT(BTPROTO_HCI),
+#endif
+#if defined(BTPROTO_SCO) || (defined(HAVE_DECL_BTPROTO_SCO) && HAVE_DECL_BTPROTO_SCO)
+  XLAT(BTPROTO_SCO),
+#endif
+#if defined(BTPROTO_RFCOMM) || (defined(HAVE_DECL_BTPROTO_RFCOMM) && HAVE_DECL_BTPROTO_RFCOMM)
+  XLAT(BTPROTO_RFCOMM),
+#endif
+#if defined(BTPROTO_BNEP) || (defined(HAVE_DECL_BTPROTO_BNEP) && HAVE_DECL_BTPROTO_BNEP)
+  XLAT(BTPROTO_BNEP),
+#endif
+#if defined(BTPROTO_CMTP) || (defined(HAVE_DECL_BTPROTO_CMTP) && HAVE_DECL_BTPROTO_CMTP)
+  XLAT(BTPROTO_CMTP),
+#endif
+#if defined(BTPROTO_HIDP) || (defined(HAVE_DECL_BTPROTO_HIDP) && HAVE_DECL_BTPROTO_HIDP)
+  XLAT(BTPROTO_HIDP),
+#endif
+#if defined(BTPROTO_AVDTP) || (defined(HAVE_DECL_BTPROTO_AVDTP) && HAVE_DECL_BTPROTO_AVDTP)
+  XLAT(BTPROTO_AVDTP),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/bt_protocols.in b/strace/xlat/bt_protocols.in
new file mode 100644
index 0000000..1f7f348
--- /dev/null
+++ b/strace/xlat/bt_protocols.in
@@ -0,0 +1,8 @@
+BTPROTO_L2CAP
+BTPROTO_HCI
+BTPROTO_SCO
+BTPROTO_RFCOMM
+BTPROTO_BNEP
+BTPROTO_CMTP
+BTPROTO_HIDP
+BTPROTO_AVDTP
diff --git a/strace/xlat/btrfs_balance_args.h b/strace/xlat/btrfs_balance_args.h
new file mode 100644
index 0000000..d1f1091
--- /dev/null
+++ b/strace/xlat/btrfs_balance_args.h
@@ -0,0 +1,60 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_balance_args.in; do not edit. */
+#if !(defined(BTRFS_BALANCE_ARGS_PROFILES) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_PROFILES) && HAVE_DECL_BTRFS_BALANCE_ARGS_PROFILES))
+# define BTRFS_BALANCE_ARGS_PROFILES (1ULL << 0)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_USAGE) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_USAGE) && HAVE_DECL_BTRFS_BALANCE_ARGS_USAGE))
+# define BTRFS_BALANCE_ARGS_USAGE (1ULL << 1)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_DEVID) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_DEVID) && HAVE_DECL_BTRFS_BALANCE_ARGS_DEVID))
+# define BTRFS_BALANCE_ARGS_DEVID (1ULL << 2)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_DRANGE) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_DRANGE) && HAVE_DECL_BTRFS_BALANCE_ARGS_DRANGE))
+# define BTRFS_BALANCE_ARGS_DRANGE (1ULL << 3)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_VRANGE) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_VRANGE) && HAVE_DECL_BTRFS_BALANCE_ARGS_VRANGE))
+# define BTRFS_BALANCE_ARGS_VRANGE (1ULL << 4)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_LIMIT) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_LIMIT) && HAVE_DECL_BTRFS_BALANCE_ARGS_LIMIT))
+# define BTRFS_BALANCE_ARGS_LIMIT (1ULL << 5)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_LIMIT_RANGE) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_LIMIT_RANGE) && HAVE_DECL_BTRFS_BALANCE_ARGS_LIMIT_RANGE))
+# define BTRFS_BALANCE_ARGS_LIMIT_RANGE (1ULL << 6)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_STRIPES_RANGE) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_STRIPES_RANGE) && HAVE_DECL_BTRFS_BALANCE_ARGS_STRIPES_RANGE))
+# define BTRFS_BALANCE_ARGS_STRIPES_RANGE (1ULL << 7)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_CONVERT) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_CONVERT) && HAVE_DECL_BTRFS_BALANCE_ARGS_CONVERT))
+# define BTRFS_BALANCE_ARGS_CONVERT (1ULL << 8)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_SOFT) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_SOFT) && HAVE_DECL_BTRFS_BALANCE_ARGS_SOFT))
+# define BTRFS_BALANCE_ARGS_SOFT (1ULL << 9)
+#endif
+#if !(defined(BTRFS_BALANCE_ARGS_USAGE_RANGE) || (defined(HAVE_DECL_BTRFS_BALANCE_ARGS_USAGE_RANGE) && HAVE_DECL_BTRFS_BALANCE_ARGS_USAGE_RANGE))
+# define BTRFS_BALANCE_ARGS_USAGE_RANGE (1ULL << 10)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_balance_args[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_balance_args[] = {
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_PROFILES),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_USAGE),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_DEVID),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_DRANGE),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_VRANGE),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_LIMIT),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_LIMIT_RANGE),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_STRIPES_RANGE),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_CONVERT),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_SOFT),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ARGS_USAGE_RANGE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_balance_args.in b/strace/xlat/btrfs_balance_args.in
new file mode 100644
index 0000000..ffeaacc
--- /dev/null
+++ b/strace/xlat/btrfs_balance_args.in
@@ -0,0 +1,12 @@
+#val_type uint64_t
+BTRFS_BALANCE_ARGS_PROFILES	(1ULL << 0)
+BTRFS_BALANCE_ARGS_USAGE	(1ULL << 1)
+BTRFS_BALANCE_ARGS_DEVID	(1ULL << 2)
+BTRFS_BALANCE_ARGS_DRANGE	(1ULL << 3)
+BTRFS_BALANCE_ARGS_VRANGE	(1ULL << 4)
+BTRFS_BALANCE_ARGS_LIMIT        (1ULL << 5)
+BTRFS_BALANCE_ARGS_LIMIT_RANGE  (1ULL << 6)
+BTRFS_BALANCE_ARGS_STRIPES_RANGE (1ULL << 7)
+BTRFS_BALANCE_ARGS_CONVERT	(1ULL << 8)
+BTRFS_BALANCE_ARGS_SOFT		(1ULL << 9)
+BTRFS_BALANCE_ARGS_USAGE_RANGE	(1ULL << 10)
diff --git a/strace/xlat/btrfs_balance_ctl_cmds.h b/strace/xlat/btrfs_balance_ctl_cmds.h
new file mode 100644
index 0000000..9bdc820
--- /dev/null
+++ b/strace/xlat/btrfs_balance_ctl_cmds.h
@@ -0,0 +1,24 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_balance_ctl_cmds.in; do not edit. */
+#if !(defined(BTRFS_BALANCE_CTL_PAUSE) || (defined(HAVE_DECL_BTRFS_BALANCE_CTL_PAUSE) && HAVE_DECL_BTRFS_BALANCE_CTL_PAUSE))
+# define BTRFS_BALANCE_CTL_PAUSE 1
+#endif
+#if !(defined(BTRFS_BALANCE_CTL_CANCEL) || (defined(HAVE_DECL_BTRFS_BALANCE_CTL_CANCEL) && HAVE_DECL_BTRFS_BALANCE_CTL_CANCEL))
+# define BTRFS_BALANCE_CTL_CANCEL 2
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_balance_ctl_cmds[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_balance_ctl_cmds[] = {
+ XLAT(BTRFS_BALANCE_CTL_PAUSE),
+ XLAT(BTRFS_BALANCE_CTL_CANCEL),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_balance_ctl_cmds.in b/strace/xlat/btrfs_balance_ctl_cmds.in
new file mode 100644
index 0000000..5cdd0bc
--- /dev/null
+++ b/strace/xlat/btrfs_balance_ctl_cmds.in
@@ -0,0 +1,2 @@
+BTRFS_BALANCE_CTL_PAUSE         1
+BTRFS_BALANCE_CTL_CANCEL        2
diff --git a/strace/xlat/btrfs_balance_flags.h b/strace/xlat/btrfs_balance_flags.h
new file mode 100644
index 0000000..c071b6e
--- /dev/null
+++ b/strace/xlat/btrfs_balance_flags.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_balance_flags.in; do not edit. */
+#if !(defined(BTRFS_BALANCE_DATA) || (defined(HAVE_DECL_BTRFS_BALANCE_DATA) && HAVE_DECL_BTRFS_BALANCE_DATA))
+# define BTRFS_BALANCE_DATA (1ULL << 0)
+#endif
+#if !(defined(BTRFS_BALANCE_SYSTEM) || (defined(HAVE_DECL_BTRFS_BALANCE_SYSTEM) && HAVE_DECL_BTRFS_BALANCE_SYSTEM))
+# define BTRFS_BALANCE_SYSTEM (1ULL << 1)
+#endif
+#if !(defined(BTRFS_BALANCE_METADATA) || (defined(HAVE_DECL_BTRFS_BALANCE_METADATA) && HAVE_DECL_BTRFS_BALANCE_METADATA))
+# define BTRFS_BALANCE_METADATA (1ULL << 2)
+#endif
+#if !(defined(BTRFS_BALANCE_FORCE) || (defined(HAVE_DECL_BTRFS_BALANCE_FORCE) && HAVE_DECL_BTRFS_BALANCE_FORCE))
+# define BTRFS_BALANCE_FORCE (1ULL << 3)
+#endif
+#if !(defined(BTRFS_BALANCE_RESUME) || (defined(HAVE_DECL_BTRFS_BALANCE_RESUME) && HAVE_DECL_BTRFS_BALANCE_RESUME))
+# define BTRFS_BALANCE_RESUME (1ULL << 4)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_balance_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_balance_flags[] = {
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_DATA),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_SYSTEM),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_METADATA),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_FORCE),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_RESUME),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_balance_flags.in b/strace/xlat/btrfs_balance_flags.in
new file mode 100644
index 0000000..00ae0d1
--- /dev/null
+++ b/strace/xlat/btrfs_balance_flags.in
@@ -0,0 +1,6 @@
+#val_type uint64_t
+BTRFS_BALANCE_DATA              (1ULL << 0)
+BTRFS_BALANCE_SYSTEM            (1ULL << 1)
+BTRFS_BALANCE_METADATA          (1ULL << 2)
+BTRFS_BALANCE_FORCE		(1ULL << 3)
+BTRFS_BALANCE_RESUME		(1ULL << 4)
diff --git a/strace/xlat/btrfs_balance_state.h b/strace/xlat/btrfs_balance_state.h
new file mode 100644
index 0000000..64c8511
--- /dev/null
+++ b/strace/xlat/btrfs_balance_state.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_balance_state.in; do not edit. */
+#if !(defined(BTRFS_BALANCE_STATE_RUNNING) || (defined(HAVE_DECL_BTRFS_BALANCE_STATE_RUNNING) && HAVE_DECL_BTRFS_BALANCE_STATE_RUNNING))
+# define BTRFS_BALANCE_STATE_RUNNING (1ULL << 0)
+#endif
+#if !(defined(BTRFS_BALANCE_STATE_PAUSE_REQ) || (defined(HAVE_DECL_BTRFS_BALANCE_STATE_PAUSE_REQ) && HAVE_DECL_BTRFS_BALANCE_STATE_PAUSE_REQ))
+# define BTRFS_BALANCE_STATE_PAUSE_REQ (1ULL << 1)
+#endif
+#if !(defined(BTRFS_BALANCE_STATE_CANCEL_REQ) || (defined(HAVE_DECL_BTRFS_BALANCE_STATE_CANCEL_REQ) && HAVE_DECL_BTRFS_BALANCE_STATE_CANCEL_REQ))
+# define BTRFS_BALANCE_STATE_CANCEL_REQ (1ULL << 2)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_balance_state[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_balance_state[] = {
+ XLAT(BTRFS_BALANCE_STATE_RUNNING),
+ XLAT(BTRFS_BALANCE_STATE_PAUSE_REQ),
+ XLAT(BTRFS_BALANCE_STATE_CANCEL_REQ),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_balance_state.in b/strace/xlat/btrfs_balance_state.in
new file mode 100644
index 0000000..5dbfca5
--- /dev/null
+++ b/strace/xlat/btrfs_balance_state.in
@@ -0,0 +1,3 @@
+BTRFS_BALANCE_STATE_RUNNING     (1ULL << 0)
+BTRFS_BALANCE_STATE_PAUSE_REQ   (1ULL << 1)
+BTRFS_BALANCE_STATE_CANCEL_REQ  (1ULL << 2)
diff --git a/strace/xlat/btrfs_compress_types.h b/strace/xlat/btrfs_compress_types.h
new file mode 100644
index 0000000..dd89c63
--- /dev/null
+++ b/strace/xlat/btrfs_compress_types.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_compress_types.in; do not edit. */
+#if !(defined(BTRFS_COMPRESS_NONE) || (defined(HAVE_DECL_BTRFS_COMPRESS_NONE) && HAVE_DECL_BTRFS_COMPRESS_NONE))
+# define BTRFS_COMPRESS_NONE 0
+#endif
+#if !(defined(BTRFS_COMPRESS_ZLIB) || (defined(HAVE_DECL_BTRFS_COMPRESS_ZLIB) && HAVE_DECL_BTRFS_COMPRESS_ZLIB))
+# define BTRFS_COMPRESS_ZLIB 1
+#endif
+#if !(defined(BTRFS_COMPRESS_LZO) || (defined(HAVE_DECL_BTRFS_COMPRESS_LZO) && HAVE_DECL_BTRFS_COMPRESS_LZO))
+# define BTRFS_COMPRESS_LZO 2
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_compress_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_compress_types[] = {
+ XLAT(BTRFS_COMPRESS_NONE),
+ XLAT(BTRFS_COMPRESS_ZLIB),
+ XLAT(BTRFS_COMPRESS_LZO),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_compress_types.in b/strace/xlat/btrfs_compress_types.in
new file mode 100644
index 0000000..c47d59f
--- /dev/null
+++ b/strace/xlat/btrfs_compress_types.in
@@ -0,0 +1,3 @@
+BTRFS_COMPRESS_NONE 0
+BTRFS_COMPRESS_ZLIB 1
+BTRFS_COMPRESS_LZO 2
diff --git a/strace/xlat/btrfs_defrag_flags.h b/strace/xlat/btrfs_defrag_flags.h
new file mode 100644
index 0000000..2990b21
--- /dev/null
+++ b/strace/xlat/btrfs_defrag_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_defrag_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_defrag_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_defrag_flags[] = {
+#if defined(BTRFS_DEFRAG_RANGE_COMPRESS) || (defined(HAVE_DECL_BTRFS_DEFRAG_RANGE_COMPRESS) && HAVE_DECL_BTRFS_DEFRAG_RANGE_COMPRESS)
+  XLAT_TYPE(uint64_t, BTRFS_DEFRAG_RANGE_COMPRESS),
+#endif
+#if defined(BTRFS_DEFRAG_RANGE_START_IO) || (defined(HAVE_DECL_BTRFS_DEFRAG_RANGE_START_IO) && HAVE_DECL_BTRFS_DEFRAG_RANGE_START_IO)
+  XLAT_TYPE(uint64_t, BTRFS_DEFRAG_RANGE_START_IO),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_defrag_flags.in b/strace/xlat/btrfs_defrag_flags.in
new file mode 100644
index 0000000..ae026c8
--- /dev/null
+++ b/strace/xlat/btrfs_defrag_flags.in
@@ -0,0 +1,3 @@
+#val_type uint64_t
+BTRFS_DEFRAG_RANGE_COMPRESS
+BTRFS_DEFRAG_RANGE_START_IO
diff --git a/strace/xlat/btrfs_dev_replace_cmds.h b/strace/xlat/btrfs_dev_replace_cmds.h
new file mode 100644
index 0000000..83bd044
--- /dev/null
+++ b/strace/xlat/btrfs_dev_replace_cmds.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_dev_replace_cmds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_dev_replace_cmds[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_dev_replace_cmds[] = {
+#if defined(BTRFS_IOCTL_DEV_REPLACE_CMD_START) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_CMD_START) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_CMD_START)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_CMD_START),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_CMD_CANCEL) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_CMD_CANCEL) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_CMD_CANCEL)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_CMD_CANCEL),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_dev_replace_cmds.in b/strace/xlat/btrfs_dev_replace_cmds.in
new file mode 100644
index 0000000..18600f0
--- /dev/null
+++ b/strace/xlat/btrfs_dev_replace_cmds.in
@@ -0,0 +1,4 @@
+#val_type uint64_t
+BTRFS_IOCTL_DEV_REPLACE_CMD_START
+BTRFS_IOCTL_DEV_REPLACE_CMD_STATUS
+BTRFS_IOCTL_DEV_REPLACE_CMD_CANCEL
diff --git a/strace/xlat/btrfs_dev_replace_results.h b/strace/xlat/btrfs_dev_replace_results.h
new file mode 100644
index 0000000..62fe4f8
--- /dev/null
+++ b/strace/xlat/btrfs_dev_replace_results.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_dev_replace_results.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_dev_replace_results[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_dev_replace_results[] = {
+#if defined(BTRFS_IOCTL_DEV_REPLACE_RESULT_NO_ERROR) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_NO_ERROR) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_NO_ERROR)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_RESULT_NO_ERROR),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_RESULT_NOT_STARTED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_NOT_STARTED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_NOT_STARTED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_RESULT_NOT_STARTED),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_RESULT_ALREADY_STARTED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_ALREADY_STARTED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_ALREADY_STARTED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_RESULT_ALREADY_STARTED),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_RESULT_SCRUB_INPROGRESS) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_SCRUB_INPROGRESS) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_RESULT_SCRUB_INPROGRESS)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_RESULT_SCRUB_INPROGRESS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_dev_replace_results.in b/strace/xlat/btrfs_dev_replace_results.in
new file mode 100644
index 0000000..bf89282
--- /dev/null
+++ b/strace/xlat/btrfs_dev_replace_results.in
@@ -0,0 +1,5 @@
+#val_type uint64_t
+BTRFS_IOCTL_DEV_REPLACE_RESULT_NO_ERROR
+BTRFS_IOCTL_DEV_REPLACE_RESULT_NOT_STARTED
+BTRFS_IOCTL_DEV_REPLACE_RESULT_ALREADY_STARTED
+BTRFS_IOCTL_DEV_REPLACE_RESULT_SCRUB_INPROGRESS
diff --git a/strace/xlat/btrfs_dev_replace_state.h b/strace/xlat/btrfs_dev_replace_state.h
new file mode 100644
index 0000000..7095c1a
--- /dev/null
+++ b/strace/xlat/btrfs_dev_replace_state.h
@@ -0,0 +1,31 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_dev_replace_state.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_dev_replace_state[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_dev_replace_state[] = {
+#if defined(BTRFS_IOCTL_DEV_REPLACE_STATE_NEVER_STARTED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_NEVER_STARTED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_NEVER_STARTED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_STATE_NEVER_STARTED),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_STATE_STARTED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_STARTED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_STARTED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_STATE_STARTED),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_STATE_FINISHED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_FINISHED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_FINISHED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_STATE_FINISHED),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_STATE_CANCELED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_CANCELED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_CANCELED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_STATE_CANCELED),
+#endif
+#if defined(BTRFS_IOCTL_DEV_REPLACE_STATE_SUSPENDED) || (defined(HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_SUSPENDED) && HAVE_DECL_BTRFS_IOCTL_DEV_REPLACE_STATE_SUSPENDED)
+  XLAT_TYPE(uint64_t, BTRFS_IOCTL_DEV_REPLACE_STATE_SUSPENDED),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_dev_replace_state.in b/strace/xlat/btrfs_dev_replace_state.in
new file mode 100644
index 0000000..bbc0ba1
--- /dev/null
+++ b/strace/xlat/btrfs_dev_replace_state.in
@@ -0,0 +1,6 @@
+#val_type uint64_t
+BTRFS_IOCTL_DEV_REPLACE_STATE_NEVER_STARTED
+BTRFS_IOCTL_DEV_REPLACE_STATE_STARTED
+BTRFS_IOCTL_DEV_REPLACE_STATE_FINISHED
+BTRFS_IOCTL_DEV_REPLACE_STATE_CANCELED
+BTRFS_IOCTL_DEV_REPLACE_STATE_SUSPENDED
diff --git a/strace/xlat/btrfs_dev_stats_flags.h b/strace/xlat/btrfs_dev_stats_flags.h
new file mode 100644
index 0000000..7bfbb09
--- /dev/null
+++ b/strace/xlat/btrfs_dev_stats_flags.h
@@ -0,0 +1,19 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_dev_stats_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_dev_stats_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_dev_stats_flags[] = {
+#if defined(BTRFS_DEV_STATS_RESET) || (defined(HAVE_DECL_BTRFS_DEV_STATS_RESET) && HAVE_DECL_BTRFS_DEV_STATS_RESET)
+  XLAT_TYPE(uint64_t, BTRFS_DEV_STATS_RESET),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_dev_stats_flags.in b/strace/xlat/btrfs_dev_stats_flags.in
new file mode 100644
index 0000000..9ff56c3
--- /dev/null
+++ b/strace/xlat/btrfs_dev_stats_flags.in
@@ -0,0 +1,2 @@
+#val_type uint64_t
+BTRFS_DEV_STATS_RESET
diff --git a/strace/xlat/btrfs_dev_stats_values.h b/strace/xlat/btrfs_dev_stats_values.h
new file mode 100644
index 0000000..eaaeff0
--- /dev/null
+++ b/strace/xlat/btrfs_dev_stats_values.h
@@ -0,0 +1,21 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_dev_stats_values.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_dev_stats_values[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_dev_stats_values[] = {
+ XLAT_TYPE(uint64_t, BTRFS_DEV_STAT_WRITE_ERRS),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_STAT_READ_ERRS),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_STAT_FLUSH_ERRS),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_STAT_CORRUPTION_ERRS),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_STAT_GENERATION_ERRS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_dev_stats_values.in b/strace/xlat/btrfs_dev_stats_values.in
new file mode 100644
index 0000000..02a37be
--- /dev/null
+++ b/strace/xlat/btrfs_dev_stats_values.in
@@ -0,0 +1,7 @@
+#val_type uint64_t
+#unconditional
+BTRFS_DEV_STAT_WRITE_ERRS
+BTRFS_DEV_STAT_READ_ERRS
+BTRFS_DEV_STAT_FLUSH_ERRS
+BTRFS_DEV_STAT_CORRUPTION_ERRS
+BTRFS_DEV_STAT_GENERATION_ERRS
diff --git a/strace/xlat/btrfs_features_compat.h b/strace/xlat/btrfs_features_compat.h
new file mode 100644
index 0000000..d1e61d8
--- /dev/null
+++ b/strace/xlat/btrfs_features_compat.h
@@ -0,0 +1,16 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_features_compat.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_features_compat[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_features_compat[] = {
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_features_compat.in b/strace/xlat/btrfs_features_compat.in
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/strace/xlat/btrfs_features_compat.in
diff --git a/strace/xlat/btrfs_features_compat_ro.h b/strace/xlat/btrfs_features_compat_ro.h
new file mode 100644
index 0000000..adb9a4d
--- /dev/null
+++ b/strace/xlat/btrfs_features_compat_ro.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_features_compat_ro.in; do not edit. */
+#if !(defined(BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE) || (defined(HAVE_DECL_BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE) && HAVE_DECL_BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE))
+# define BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE (1ULL << 0)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_features_compat_ro[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_features_compat_ro[] = {
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_features_compat_ro.in b/strace/xlat/btrfs_features_compat_ro.in
new file mode 100644
index 0000000..3fd1b6d
--- /dev/null
+++ b/strace/xlat/btrfs_features_compat_ro.in
@@ -0,0 +1,2 @@
+#val_type uint64_t
+BTRFS_FEATURE_COMPAT_RO_FREE_SPACE_TREE (1ULL << 0)
diff --git a/strace/xlat/btrfs_features_incompat.h b/strace/xlat/btrfs_features_incompat.h
new file mode 100644
index 0000000..b012f41
--- /dev/null
+++ b/strace/xlat/btrfs_features_incompat.h
@@ -0,0 +1,56 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_features_incompat.in; do not edit. */
+#if !(defined(BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF))
+# define BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF (1ULL << 0)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL))
+# define BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL (1ULL << 1)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_MIXED_GROUPS) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_MIXED_GROUPS) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_MIXED_GROUPS))
+# define BTRFS_FEATURE_INCOMPAT_MIXED_GROUPS (1ULL << 2)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_COMPRESS_LZO) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_COMPRESS_LZO) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_COMPRESS_LZO))
+# define BTRFS_FEATURE_INCOMPAT_COMPRESS_LZO (1ULL << 3)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_COMPRESS_LZOv2) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_COMPRESS_LZOv2) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_COMPRESS_LZOv2))
+# define BTRFS_FEATURE_INCOMPAT_COMPRESS_LZOv2 (1ULL << 4)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_BIG_METADATA) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_BIG_METADATA) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_BIG_METADATA))
+# define BTRFS_FEATURE_INCOMPAT_BIG_METADATA (1ULL << 5)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF))
+# define BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF (1ULL << 6)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_RAID56) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_RAID56) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_RAID56))
+# define BTRFS_FEATURE_INCOMPAT_RAID56 (1ULL << 7)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA))
+# define BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA (1ULL << 8)
+#endif
+#if !(defined(BTRFS_FEATURE_INCOMPAT_NO_HOLES) || (defined(HAVE_DECL_BTRFS_FEATURE_INCOMPAT_NO_HOLES) && HAVE_DECL_BTRFS_FEATURE_INCOMPAT_NO_HOLES))
+# define BTRFS_FEATURE_INCOMPAT_NO_HOLES (1ULL << 9)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_features_incompat[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_features_incompat[] = {
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_MIXED_GROUPS),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_COMPRESS_LZO),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_COMPRESS_LZOv2),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_BIG_METADATA),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_RAID56),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA),
+ XLAT_TYPE(uint64_t, BTRFS_FEATURE_INCOMPAT_NO_HOLES),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_features_incompat.in b/strace/xlat/btrfs_features_incompat.in
new file mode 100644
index 0000000..45baacf
--- /dev/null
+++ b/strace/xlat/btrfs_features_incompat.in
@@ -0,0 +1,11 @@
+#val_type uint64_t
+BTRFS_FEATURE_INCOMPAT_MIXED_BACKREF    (1ULL << 0)
+BTRFS_FEATURE_INCOMPAT_DEFAULT_SUBVOL   (1ULL << 1)
+BTRFS_FEATURE_INCOMPAT_MIXED_GROUPS     (1ULL << 2)
+BTRFS_FEATURE_INCOMPAT_COMPRESS_LZO     (1ULL << 3)
+BTRFS_FEATURE_INCOMPAT_COMPRESS_LZOv2   (1ULL << 4)
+BTRFS_FEATURE_INCOMPAT_BIG_METADATA     (1ULL << 5)
+BTRFS_FEATURE_INCOMPAT_EXTENDED_IREF    (1ULL << 6)
+BTRFS_FEATURE_INCOMPAT_RAID56           (1ULL << 7)
+BTRFS_FEATURE_INCOMPAT_SKINNY_METADATA  (1ULL << 8)
+BTRFS_FEATURE_INCOMPAT_NO_HOLES         (1ULL << 9)
diff --git a/strace/xlat/btrfs_key_types.h b/strace/xlat/btrfs_key_types.h
new file mode 100644
index 0000000..1a72165
--- /dev/null
+++ b/strace/xlat/btrfs_key_types.h
@@ -0,0 +1,180 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_key_types.in; do not edit. */
+#if !(defined(BTRFS_INODE_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_INODE_ITEM_KEY) && HAVE_DECL_BTRFS_INODE_ITEM_KEY))
+# define BTRFS_INODE_ITEM_KEY 1
+#endif
+#if !(defined(BTRFS_INODE_REF_KEY) || (defined(HAVE_DECL_BTRFS_INODE_REF_KEY) && HAVE_DECL_BTRFS_INODE_REF_KEY))
+# define BTRFS_INODE_REF_KEY 12
+#endif
+#if !(defined(BTRFS_INODE_EXTREF_KEY) || (defined(HAVE_DECL_BTRFS_INODE_EXTREF_KEY) && HAVE_DECL_BTRFS_INODE_EXTREF_KEY))
+# define BTRFS_INODE_EXTREF_KEY 13
+#endif
+#if !(defined(BTRFS_XATTR_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_XATTR_ITEM_KEY) && HAVE_DECL_BTRFS_XATTR_ITEM_KEY))
+# define BTRFS_XATTR_ITEM_KEY 24
+#endif
+#if !(defined(BTRFS_ORPHAN_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_ORPHAN_ITEM_KEY) && HAVE_DECL_BTRFS_ORPHAN_ITEM_KEY))
+# define BTRFS_ORPHAN_ITEM_KEY 48
+#endif
+#if !(defined(BTRFS_DIR_LOG_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_DIR_LOG_ITEM_KEY) && HAVE_DECL_BTRFS_DIR_LOG_ITEM_KEY))
+# define BTRFS_DIR_LOG_ITEM_KEY 60
+#endif
+#if !(defined(BTRFS_DIR_LOG_INDEX_KEY) || (defined(HAVE_DECL_BTRFS_DIR_LOG_INDEX_KEY) && HAVE_DECL_BTRFS_DIR_LOG_INDEX_KEY))
+# define BTRFS_DIR_LOG_INDEX_KEY 72
+#endif
+#if !(defined(BTRFS_DIR_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_DIR_ITEM_KEY) && HAVE_DECL_BTRFS_DIR_ITEM_KEY))
+# define BTRFS_DIR_ITEM_KEY 84
+#endif
+#if !(defined(BTRFS_DIR_INDEX_KEY) || (defined(HAVE_DECL_BTRFS_DIR_INDEX_KEY) && HAVE_DECL_BTRFS_DIR_INDEX_KEY))
+# define BTRFS_DIR_INDEX_KEY 96
+#endif
+#if !(defined(BTRFS_EXTENT_DATA_KEY) || (defined(HAVE_DECL_BTRFS_EXTENT_DATA_KEY) && HAVE_DECL_BTRFS_EXTENT_DATA_KEY))
+# define BTRFS_EXTENT_DATA_KEY 108
+#endif
+#if !(defined(BTRFS_EXTENT_CSUM_KEY) || (defined(HAVE_DECL_BTRFS_EXTENT_CSUM_KEY) && HAVE_DECL_BTRFS_EXTENT_CSUM_KEY))
+# define BTRFS_EXTENT_CSUM_KEY 128
+#endif
+#if !(defined(BTRFS_ROOT_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_ROOT_ITEM_KEY) && HAVE_DECL_BTRFS_ROOT_ITEM_KEY))
+# define BTRFS_ROOT_ITEM_KEY 132
+#endif
+#if !(defined(BTRFS_ROOT_BACKREF_KEY) || (defined(HAVE_DECL_BTRFS_ROOT_BACKREF_KEY) && HAVE_DECL_BTRFS_ROOT_BACKREF_KEY))
+# define BTRFS_ROOT_BACKREF_KEY 144
+#endif
+#if !(defined(BTRFS_ROOT_REF_KEY) || (defined(HAVE_DECL_BTRFS_ROOT_REF_KEY) && HAVE_DECL_BTRFS_ROOT_REF_KEY))
+# define BTRFS_ROOT_REF_KEY 156
+#endif
+#if !(defined(BTRFS_EXTENT_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_EXTENT_ITEM_KEY) && HAVE_DECL_BTRFS_EXTENT_ITEM_KEY))
+# define BTRFS_EXTENT_ITEM_KEY 168
+#endif
+#if !(defined(BTRFS_METADATA_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_METADATA_ITEM_KEY) && HAVE_DECL_BTRFS_METADATA_ITEM_KEY))
+# define BTRFS_METADATA_ITEM_KEY 169
+#endif
+#if !(defined(BTRFS_TREE_BLOCK_REF_KEY) || (defined(HAVE_DECL_BTRFS_TREE_BLOCK_REF_KEY) && HAVE_DECL_BTRFS_TREE_BLOCK_REF_KEY))
+# define BTRFS_TREE_BLOCK_REF_KEY 176
+#endif
+#if !(defined(BTRFS_EXTENT_DATA_REF_KEY) || (defined(HAVE_DECL_BTRFS_EXTENT_DATA_REF_KEY) && HAVE_DECL_BTRFS_EXTENT_DATA_REF_KEY))
+# define BTRFS_EXTENT_DATA_REF_KEY 178
+#endif
+#if !(defined(BTRFS_EXTENT_REF_V0_KEY) || (defined(HAVE_DECL_BTRFS_EXTENT_REF_V0_KEY) && HAVE_DECL_BTRFS_EXTENT_REF_V0_KEY))
+# define BTRFS_EXTENT_REF_V0_KEY 180
+#endif
+#if !(defined(BTRFS_SHARED_BLOCK_REF_KEY) || (defined(HAVE_DECL_BTRFS_SHARED_BLOCK_REF_KEY) && HAVE_DECL_BTRFS_SHARED_BLOCK_REF_KEY))
+# define BTRFS_SHARED_BLOCK_REF_KEY 182
+#endif
+#if !(defined(BTRFS_SHARED_DATA_REF_KEY) || (defined(HAVE_DECL_BTRFS_SHARED_DATA_REF_KEY) && HAVE_DECL_BTRFS_SHARED_DATA_REF_KEY))
+# define BTRFS_SHARED_DATA_REF_KEY 184
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_ITEM_KEY) && HAVE_DECL_BTRFS_BLOCK_GROUP_ITEM_KEY))
+# define BTRFS_BLOCK_GROUP_ITEM_KEY 192
+#endif
+#if !(defined(BTRFS_FREE_SPACE_INFO_KEY) || (defined(HAVE_DECL_BTRFS_FREE_SPACE_INFO_KEY) && HAVE_DECL_BTRFS_FREE_SPACE_INFO_KEY))
+# define BTRFS_FREE_SPACE_INFO_KEY 198
+#endif
+#if !(defined(BTRFS_FREE_SPACE_EXTENT_KEY) || (defined(HAVE_DECL_BTRFS_FREE_SPACE_EXTENT_KEY) && HAVE_DECL_BTRFS_FREE_SPACE_EXTENT_KEY))
+# define BTRFS_FREE_SPACE_EXTENT_KEY 199
+#endif
+#if !(defined(BTRFS_FREE_SPACE_BITMAP_KEY) || (defined(HAVE_DECL_BTRFS_FREE_SPACE_BITMAP_KEY) && HAVE_DECL_BTRFS_FREE_SPACE_BITMAP_KEY))
+# define BTRFS_FREE_SPACE_BITMAP_KEY 200
+#endif
+#if !(defined(BTRFS_DEV_EXTENT_KEY) || (defined(HAVE_DECL_BTRFS_DEV_EXTENT_KEY) && HAVE_DECL_BTRFS_DEV_EXTENT_KEY))
+# define BTRFS_DEV_EXTENT_KEY 204
+#endif
+#if !(defined(BTRFS_DEV_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_DEV_ITEM_KEY) && HAVE_DECL_BTRFS_DEV_ITEM_KEY))
+# define BTRFS_DEV_ITEM_KEY 216
+#endif
+#if !(defined(BTRFS_CHUNK_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_CHUNK_ITEM_KEY) && HAVE_DECL_BTRFS_CHUNK_ITEM_KEY))
+# define BTRFS_CHUNK_ITEM_KEY 228
+#endif
+#if !(defined(BTRFS_QGROUP_STATUS_KEY) || (defined(HAVE_DECL_BTRFS_QGROUP_STATUS_KEY) && HAVE_DECL_BTRFS_QGROUP_STATUS_KEY))
+# define BTRFS_QGROUP_STATUS_KEY 240
+#endif
+#if !(defined(BTRFS_QGROUP_INFO_KEY) || (defined(HAVE_DECL_BTRFS_QGROUP_INFO_KEY) && HAVE_DECL_BTRFS_QGROUP_INFO_KEY))
+# define BTRFS_QGROUP_INFO_KEY 242
+#endif
+#if !(defined(BTRFS_QGROUP_LIMIT_KEY) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_KEY) && HAVE_DECL_BTRFS_QGROUP_LIMIT_KEY))
+# define BTRFS_QGROUP_LIMIT_KEY 244
+#endif
+#if !(defined(BTRFS_QGROUP_RELATION_KEY) || (defined(HAVE_DECL_BTRFS_QGROUP_RELATION_KEY) && HAVE_DECL_BTRFS_QGROUP_RELATION_KEY))
+# define BTRFS_QGROUP_RELATION_KEY 246
+#endif
+#if !(defined(BTRFS_BALANCE_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_BALANCE_ITEM_KEY) && HAVE_DECL_BTRFS_BALANCE_ITEM_KEY))
+# define BTRFS_BALANCE_ITEM_KEY 248
+#endif
+#if !(defined(BTRFS_TEMPORARY_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_TEMPORARY_ITEM_KEY) && HAVE_DECL_BTRFS_TEMPORARY_ITEM_KEY))
+# define BTRFS_TEMPORARY_ITEM_KEY 248
+#endif
+#if !(defined(BTRFS_DEV_STATS_KEY) || (defined(HAVE_DECL_BTRFS_DEV_STATS_KEY) && HAVE_DECL_BTRFS_DEV_STATS_KEY))
+# define BTRFS_DEV_STATS_KEY 249
+#endif
+#if !(defined(BTRFS_PERSISTENT_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_PERSISTENT_ITEM_KEY) && HAVE_DECL_BTRFS_PERSISTENT_ITEM_KEY))
+# define BTRFS_PERSISTENT_ITEM_KEY 249
+#endif
+#if !(defined(BTRFS_DEV_REPLACE_KEY) || (defined(HAVE_DECL_BTRFS_DEV_REPLACE_KEY) && HAVE_DECL_BTRFS_DEV_REPLACE_KEY))
+# define BTRFS_DEV_REPLACE_KEY 250
+#endif
+#if !(defined(BTRFS_UUID_KEY_SUBVOL) || (defined(HAVE_DECL_BTRFS_UUID_KEY_SUBVOL) && HAVE_DECL_BTRFS_UUID_KEY_SUBVOL))
+# define BTRFS_UUID_KEY_SUBVOL 251
+#endif
+#if !(defined(BTRFS_UUID_KEY_RECEIVED_SUBVOL) || (defined(HAVE_DECL_BTRFS_UUID_KEY_RECEIVED_SUBVOL) && HAVE_DECL_BTRFS_UUID_KEY_RECEIVED_SUBVOL))
+# define BTRFS_UUID_KEY_RECEIVED_SUBVOL 252
+#endif
+#if !(defined(BTRFS_STRING_ITEM_KEY) || (defined(HAVE_DECL_BTRFS_STRING_ITEM_KEY) && HAVE_DECL_BTRFS_STRING_ITEM_KEY))
+# define BTRFS_STRING_ITEM_KEY 253
+#endif
+#if !(defined(UINT32_MAX) || (defined(HAVE_DECL_UINT32_MAX) && HAVE_DECL_UINT32_MAX))
+# define UINT32_MAX -1U
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_key_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_key_types[] = {
+ XLAT_TYPE(uint64_t, BTRFS_INODE_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_INODE_REF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_INODE_EXTREF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_XATTR_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_ORPHAN_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DIR_LOG_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DIR_LOG_INDEX_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DIR_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DIR_INDEX_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_EXTENT_DATA_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_EXTENT_CSUM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_ROOT_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_ROOT_BACKREF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_ROOT_REF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_EXTENT_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_METADATA_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_TREE_BLOCK_REF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_EXTENT_DATA_REF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_EXTENT_REF_V0_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_SHARED_BLOCK_REF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_SHARED_DATA_REF_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_FREE_SPACE_INFO_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_FREE_SPACE_EXTENT_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_FREE_SPACE_BITMAP_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_EXTENT_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_CHUNK_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_STATUS_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_INFO_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_RELATION_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_BALANCE_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_TEMPORARY_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_STATS_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_PERSISTENT_ITEM_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_REPLACE_KEY),
+ XLAT_TYPE(uint64_t, BTRFS_UUID_KEY_SUBVOL),
+ XLAT_TYPE(uint64_t, BTRFS_UUID_KEY_RECEIVED_SUBVOL),
+ XLAT_TYPE(uint64_t, BTRFS_STRING_ITEM_KEY),
+ XLAT_TYPE(uint64_t, UINT32_MAX),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_key_types.in b/strace/xlat/btrfs_key_types.in
new file mode 100644
index 0000000..5721e60
--- /dev/null
+++ b/strace/xlat/btrfs_key_types.in
@@ -0,0 +1,42 @@
+#val_type uint64_t
+BTRFS_INODE_ITEM_KEY            1
+BTRFS_INODE_REF_KEY             12
+BTRFS_INODE_EXTREF_KEY          13
+BTRFS_XATTR_ITEM_KEY            24
+BTRFS_ORPHAN_ITEM_KEY           48
+BTRFS_DIR_LOG_ITEM_KEY  60
+BTRFS_DIR_LOG_INDEX_KEY 72
+BTRFS_DIR_ITEM_KEY      84
+BTRFS_DIR_INDEX_KEY     96
+BTRFS_EXTENT_DATA_KEY   108
+BTRFS_EXTENT_CSUM_KEY   128
+BTRFS_ROOT_ITEM_KEY     132
+BTRFS_ROOT_BACKREF_KEY  144
+BTRFS_ROOT_REF_KEY      156
+BTRFS_EXTENT_ITEM_KEY   168
+BTRFS_METADATA_ITEM_KEY 169
+BTRFS_TREE_BLOCK_REF_KEY        176
+BTRFS_EXTENT_DATA_REF_KEY       178
+BTRFS_EXTENT_REF_V0_KEY         180
+BTRFS_SHARED_BLOCK_REF_KEY      182
+BTRFS_SHARED_DATA_REF_KEY       184
+BTRFS_BLOCK_GROUP_ITEM_KEY 192
+BTRFS_FREE_SPACE_INFO_KEY 198
+BTRFS_FREE_SPACE_EXTENT_KEY 199
+BTRFS_FREE_SPACE_BITMAP_KEY 200
+BTRFS_DEV_EXTENT_KEY    204
+BTRFS_DEV_ITEM_KEY      216
+BTRFS_CHUNK_ITEM_KEY    228
+BTRFS_QGROUP_STATUS_KEY         240
+BTRFS_QGROUP_INFO_KEY           242
+BTRFS_QGROUP_LIMIT_KEY          244
+BTRFS_QGROUP_RELATION_KEY       246
+BTRFS_BALANCE_ITEM_KEY  248
+BTRFS_TEMPORARY_ITEM_KEY        248
+BTRFS_DEV_STATS_KEY             249
+BTRFS_PERSISTENT_ITEM_KEY       249
+BTRFS_DEV_REPLACE_KEY   250
+BTRFS_UUID_KEY_SUBVOL   251
+BTRFS_UUID_KEY_RECEIVED_SUBVOL  252
+BTRFS_STRING_ITEM_KEY   253
+UINT32_MAX -1U
diff --git a/strace/xlat/btrfs_qgroup_ctl_cmds.h b/strace/xlat/btrfs_qgroup_ctl_cmds.h
new file mode 100644
index 0000000..25bdce2
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_ctl_cmds.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_qgroup_ctl_cmds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_qgroup_ctl_cmds[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_qgroup_ctl_cmds[] = {
+#if defined(BTRFS_QUOTA_CTL_ENABLE) || (defined(HAVE_DECL_BTRFS_QUOTA_CTL_ENABLE) && HAVE_DECL_BTRFS_QUOTA_CTL_ENABLE)
+  XLAT_TYPE(uint64_t, BTRFS_QUOTA_CTL_ENABLE),
+#endif
+#if defined(BTRFS_QUOTA_CTL_DISABLE) || (defined(HAVE_DECL_BTRFS_QUOTA_CTL_DISABLE) && HAVE_DECL_BTRFS_QUOTA_CTL_DISABLE)
+  XLAT_TYPE(uint64_t, BTRFS_QUOTA_CTL_DISABLE),
+#endif
+#if defined(BTRFS_QUOTA_CTL_RESCAN__NOTUSED) || (defined(HAVE_DECL_BTRFS_QUOTA_CTL_RESCAN__NOTUSED) && HAVE_DECL_BTRFS_QUOTA_CTL_RESCAN__NOTUSED)
+  XLAT_TYPE(uint64_t, BTRFS_QUOTA_CTL_RESCAN__NOTUSED),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_qgroup_ctl_cmds.in b/strace/xlat/btrfs_qgroup_ctl_cmds.in
new file mode 100644
index 0000000..05e2003
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_ctl_cmds.in
@@ -0,0 +1,4 @@
+#val_type uint64_t
+BTRFS_QUOTA_CTL_ENABLE
+BTRFS_QUOTA_CTL_DISABLE
+BTRFS_QUOTA_CTL_RESCAN__NOTUSED
diff --git a/strace/xlat/btrfs_qgroup_inherit_flags.h b/strace/xlat/btrfs_qgroup_inherit_flags.h
new file mode 100644
index 0000000..ead56ea
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_inherit_flags.h
@@ -0,0 +1,19 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_qgroup_inherit_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_qgroup_inherit_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_qgroup_inherit_flags[] = {
+#if defined(BTRFS_QGROUP_INHERIT_SET_LIMITS) || (defined(HAVE_DECL_BTRFS_QGROUP_INHERIT_SET_LIMITS) && HAVE_DECL_BTRFS_QGROUP_INHERIT_SET_LIMITS)
+  XLAT_TYPE(uint64_t, BTRFS_QGROUP_INHERIT_SET_LIMITS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_qgroup_inherit_flags.in b/strace/xlat/btrfs_qgroup_inherit_flags.in
new file mode 100644
index 0000000..0e133b9
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_inherit_flags.in
@@ -0,0 +1,2 @@
+#val_type uint64_t
+BTRFS_QGROUP_INHERIT_SET_LIMITS
diff --git a/strace/xlat/btrfs_qgroup_limit_flags.h b/strace/xlat/btrfs_qgroup_limit_flags.h
new file mode 100644
index 0000000..114c876
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_limit_flags.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_qgroup_limit_flags.in; do not edit. */
+#if !(defined(BTRFS_QGROUP_LIMIT_MAX_RFER) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_MAX_RFER) && HAVE_DECL_BTRFS_QGROUP_LIMIT_MAX_RFER))
+# define BTRFS_QGROUP_LIMIT_MAX_RFER (1ULL << 0)
+#endif
+#if !(defined(BTRFS_QGROUP_LIMIT_MAX_EXCL) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_MAX_EXCL) && HAVE_DECL_BTRFS_QGROUP_LIMIT_MAX_EXCL))
+# define BTRFS_QGROUP_LIMIT_MAX_EXCL (1ULL << 1)
+#endif
+#if !(defined(BTRFS_QGROUP_LIMIT_RSV_RFER) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_RSV_RFER) && HAVE_DECL_BTRFS_QGROUP_LIMIT_RSV_RFER))
+# define BTRFS_QGROUP_LIMIT_RSV_RFER (1ULL << 2)
+#endif
+#if !(defined(BTRFS_QGROUP_LIMIT_RSV_EXCL) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_RSV_EXCL) && HAVE_DECL_BTRFS_QGROUP_LIMIT_RSV_EXCL))
+# define BTRFS_QGROUP_LIMIT_RSV_EXCL (1ULL << 3)
+#endif
+#if !(defined(BTRFS_QGROUP_LIMIT_RFER_CMPR) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_RFER_CMPR) && HAVE_DECL_BTRFS_QGROUP_LIMIT_RFER_CMPR))
+# define BTRFS_QGROUP_LIMIT_RFER_CMPR (1ULL << 4)
+#endif
+#if !(defined(BTRFS_QGROUP_LIMIT_EXCL_CMPR) || (defined(HAVE_DECL_BTRFS_QGROUP_LIMIT_EXCL_CMPR) && HAVE_DECL_BTRFS_QGROUP_LIMIT_EXCL_CMPR))
+# define BTRFS_QGROUP_LIMIT_EXCL_CMPR (1ULL << 5)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_qgroup_limit_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_qgroup_limit_flags[] = {
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_MAX_RFER),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_MAX_EXCL),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_RSV_RFER),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_RSV_EXCL),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_RFER_CMPR),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_LIMIT_EXCL_CMPR),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_qgroup_limit_flags.in b/strace/xlat/btrfs_qgroup_limit_flags.in
new file mode 100644
index 0000000..bac7abe
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_limit_flags.in
@@ -0,0 +1,7 @@
+#val_type uint64_t
+BTRFS_QGROUP_LIMIT_MAX_RFER     (1ULL << 0)
+BTRFS_QGROUP_LIMIT_MAX_EXCL     (1ULL << 1)
+BTRFS_QGROUP_LIMIT_RSV_RFER     (1ULL << 2)
+BTRFS_QGROUP_LIMIT_RSV_EXCL     (1ULL << 3)
+BTRFS_QGROUP_LIMIT_RFER_CMPR    (1ULL << 4)
+BTRFS_QGROUP_LIMIT_EXCL_CMPR    (1ULL << 5)
diff --git a/strace/xlat/btrfs_qgroup_status_flags.h b/strace/xlat/btrfs_qgroup_status_flags.h
new file mode 100644
index 0000000..d02a86b
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_status_flags.h
@@ -0,0 +1,24 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_qgroup_status_flags.in; do not edit. */
+#if !(defined(BTRFS_QGROUP_STATUS_FLAG_ON) || (defined(HAVE_DECL_BTRFS_QGROUP_STATUS_FLAG_ON) && HAVE_DECL_BTRFS_QGROUP_STATUS_FLAG_ON))
+# define BTRFS_QGROUP_STATUS_FLAG_ON (1ULL << 0)
+#endif
+#if !(defined(BTRFS_QGROUP_STATUS_FLAG_RESCAN) || (defined(HAVE_DECL_BTRFS_QGROUP_STATUS_FLAG_RESCAN) && HAVE_DECL_BTRFS_QGROUP_STATUS_FLAG_RESCAN))
+# define BTRFS_QGROUP_STATUS_FLAG_RESCAN (1ULL << 1)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_qgroup_status_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_qgroup_status_flags[] = {
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_STATUS_FLAG_ON),
+ XLAT_TYPE(uint64_t, BTRFS_QGROUP_STATUS_FLAG_RESCAN),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_qgroup_status_flags.in b/strace/xlat/btrfs_qgroup_status_flags.in
new file mode 100644
index 0000000..86f60ac
--- /dev/null
+++ b/strace/xlat/btrfs_qgroup_status_flags.in
@@ -0,0 +1,3 @@
+#val_type uint64_t
+BTRFS_QGROUP_STATUS_FLAG_ON             (1ULL << 0)
+BTRFS_QGROUP_STATUS_FLAG_RESCAN         (1ULL << 1)
diff --git a/strace/xlat/btrfs_scrub_flags.h b/strace/xlat/btrfs_scrub_flags.h
new file mode 100644
index 0000000..5823e34
--- /dev/null
+++ b/strace/xlat/btrfs_scrub_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_scrub_flags.in; do not edit. */
+#if !(defined(BTRFS_SCRUB_READONLY) || (defined(HAVE_DECL_BTRFS_SCRUB_READONLY) && HAVE_DECL_BTRFS_SCRUB_READONLY))
+# define BTRFS_SCRUB_READONLY 1
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_scrub_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_scrub_flags[] = {
+ XLAT_TYPE(uint64_t, BTRFS_SCRUB_READONLY),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_scrub_flags.in b/strace/xlat/btrfs_scrub_flags.in
new file mode 100644
index 0000000..914de3d
--- /dev/null
+++ b/strace/xlat/btrfs_scrub_flags.in
@@ -0,0 +1,2 @@
+#val_type uint64_t
+BTRFS_SCRUB_READONLY    1
diff --git a/strace/xlat/btrfs_send_flags.h b/strace/xlat/btrfs_send_flags.h
new file mode 100644
index 0000000..be2b02a
--- /dev/null
+++ b/strace/xlat/btrfs_send_flags.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_send_flags.in; do not edit. */
+#if !(defined(BTRFS_SEND_FLAG_NO_FILE_DATA) || (defined(HAVE_DECL_BTRFS_SEND_FLAG_NO_FILE_DATA) && HAVE_DECL_BTRFS_SEND_FLAG_NO_FILE_DATA))
+# define BTRFS_SEND_FLAG_NO_FILE_DATA 0x1
+#endif
+#if !(defined(BTRFS_SEND_FLAG_OMIT_STREAM_HEADER) || (defined(HAVE_DECL_BTRFS_SEND_FLAG_OMIT_STREAM_HEADER) && HAVE_DECL_BTRFS_SEND_FLAG_OMIT_STREAM_HEADER))
+# define BTRFS_SEND_FLAG_OMIT_STREAM_HEADER 0x2
+#endif
+#if !(defined(BTRFS_SEND_FLAG_OMIT_END_CMD) || (defined(HAVE_DECL_BTRFS_SEND_FLAG_OMIT_END_CMD) && HAVE_DECL_BTRFS_SEND_FLAG_OMIT_END_CMD))
+# define BTRFS_SEND_FLAG_OMIT_END_CMD 0x4
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_send_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_send_flags[] = {
+ XLAT(BTRFS_SEND_FLAG_NO_FILE_DATA),
+ XLAT(BTRFS_SEND_FLAG_OMIT_STREAM_HEADER),
+ XLAT(BTRFS_SEND_FLAG_OMIT_END_CMD),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_send_flags.in b/strace/xlat/btrfs_send_flags.in
new file mode 100644
index 0000000..652ef39
--- /dev/null
+++ b/strace/xlat/btrfs_send_flags.in
@@ -0,0 +1,3 @@
+BTRFS_SEND_FLAG_NO_FILE_DATA            0x1
+BTRFS_SEND_FLAG_OMIT_STREAM_HEADER      0x2
+BTRFS_SEND_FLAG_OMIT_END_CMD            0x4
diff --git a/strace/xlat/btrfs_snap_flags_v2.h b/strace/xlat/btrfs_snap_flags_v2.h
new file mode 100644
index 0000000..4208852
--- /dev/null
+++ b/strace/xlat/btrfs_snap_flags_v2.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_snap_flags_v2.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_snap_flags_v2[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_snap_flags_v2[] = {
+#if defined(BTRFS_SUBVOL_CREATE_ASYNC) || (defined(HAVE_DECL_BTRFS_SUBVOL_CREATE_ASYNC) && HAVE_DECL_BTRFS_SUBVOL_CREATE_ASYNC)
+  XLAT_TYPE(uint64_t, BTRFS_SUBVOL_CREATE_ASYNC),
+#endif
+#if defined(BTRFS_SUBVOL_RDONLY) || (defined(HAVE_DECL_BTRFS_SUBVOL_RDONLY) && HAVE_DECL_BTRFS_SUBVOL_RDONLY)
+  XLAT_TYPE(uint64_t, BTRFS_SUBVOL_RDONLY),
+#endif
+#if defined(BTRFS_SUBVOL_QGROUP_INHERIT) || (defined(HAVE_DECL_BTRFS_SUBVOL_QGROUP_INHERIT) && HAVE_DECL_BTRFS_SUBVOL_QGROUP_INHERIT)
+  XLAT_TYPE(uint64_t, BTRFS_SUBVOL_QGROUP_INHERIT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_snap_flags_v2.in b/strace/xlat/btrfs_snap_flags_v2.in
new file mode 100644
index 0000000..43ea574
--- /dev/null
+++ b/strace/xlat/btrfs_snap_flags_v2.in
@@ -0,0 +1,4 @@
+#val_type uint64_t
+BTRFS_SUBVOL_CREATE_ASYNC
+BTRFS_SUBVOL_RDONLY
+BTRFS_SUBVOL_QGROUP_INHERIT
diff --git a/strace/xlat/btrfs_space_info_flags.h b/strace/xlat/btrfs_space_info_flags.h
new file mode 100644
index 0000000..7dcf06c
--- /dev/null
+++ b/strace/xlat/btrfs_space_info_flags.h
@@ -0,0 +1,60 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_space_info_flags.in; do not edit. */
+#if !(defined(BTRFS_BLOCK_GROUP_DATA) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_DATA) && HAVE_DECL_BTRFS_BLOCK_GROUP_DATA))
+# define BTRFS_BLOCK_GROUP_DATA (1ULL << 0)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_SYSTEM) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_SYSTEM) && HAVE_DECL_BTRFS_BLOCK_GROUP_SYSTEM))
+# define BTRFS_BLOCK_GROUP_SYSTEM (1ULL << 1)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_METADATA) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_METADATA) && HAVE_DECL_BTRFS_BLOCK_GROUP_METADATA))
+# define BTRFS_BLOCK_GROUP_METADATA (1ULL << 2)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_RAID0) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_RAID0) && HAVE_DECL_BTRFS_BLOCK_GROUP_RAID0))
+# define BTRFS_BLOCK_GROUP_RAID0 (1ULL << 3)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_RAID1) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_RAID1) && HAVE_DECL_BTRFS_BLOCK_GROUP_RAID1))
+# define BTRFS_BLOCK_GROUP_RAID1 (1ULL << 4)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_DUP) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_DUP) && HAVE_DECL_BTRFS_BLOCK_GROUP_DUP))
+# define BTRFS_BLOCK_GROUP_DUP (1ULL << 5)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_RAID10) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_RAID10) && HAVE_DECL_BTRFS_BLOCK_GROUP_RAID10))
+# define BTRFS_BLOCK_GROUP_RAID10 (1ULL << 6)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_RAID5) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_RAID5) && HAVE_DECL_BTRFS_BLOCK_GROUP_RAID5))
+# define BTRFS_BLOCK_GROUP_RAID5 (1ULL << 7)
+#endif
+#if !(defined(BTRFS_BLOCK_GROUP_RAID6) || (defined(HAVE_DECL_BTRFS_BLOCK_GROUP_RAID6) && HAVE_DECL_BTRFS_BLOCK_GROUP_RAID6))
+# define BTRFS_BLOCK_GROUP_RAID6 (1ULL << 8)
+#endif
+#if !(defined(BTRFS_AVAIL_ALLOC_BIT_SINGLE) || (defined(HAVE_DECL_BTRFS_AVAIL_ALLOC_BIT_SINGLE) && HAVE_DECL_BTRFS_AVAIL_ALLOC_BIT_SINGLE))
+# define BTRFS_AVAIL_ALLOC_BIT_SINGLE (1ULL << 48)
+#endif
+#if !(defined(BTRFS_SPACE_INFO_GLOBAL_RSV) || (defined(HAVE_DECL_BTRFS_SPACE_INFO_GLOBAL_RSV) && HAVE_DECL_BTRFS_SPACE_INFO_GLOBAL_RSV))
+# define BTRFS_SPACE_INFO_GLOBAL_RSV (1ULL << 49)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_space_info_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_space_info_flags[] = {
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_DATA),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_SYSTEM),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_METADATA),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_RAID0),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_RAID1),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_DUP),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_RAID10),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_RAID5),
+ XLAT_TYPE(uint64_t, BTRFS_BLOCK_GROUP_RAID6),
+ XLAT_TYPE(uint64_t, BTRFS_AVAIL_ALLOC_BIT_SINGLE),
+ XLAT_TYPE(uint64_t, BTRFS_SPACE_INFO_GLOBAL_RSV),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_space_info_flags.in b/strace/xlat/btrfs_space_info_flags.in
new file mode 100644
index 0000000..be6d195
--- /dev/null
+++ b/strace/xlat/btrfs_space_info_flags.in
@@ -0,0 +1,12 @@
+#val_type uint64_t
+BTRFS_BLOCK_GROUP_DATA          (1ULL << 0)
+BTRFS_BLOCK_GROUP_SYSTEM        (1ULL << 1)
+BTRFS_BLOCK_GROUP_METADATA      (1ULL << 2)
+BTRFS_BLOCK_GROUP_RAID0         (1ULL << 3)
+BTRFS_BLOCK_GROUP_RAID1         (1ULL << 4)
+BTRFS_BLOCK_GROUP_DUP           (1ULL << 5)
+BTRFS_BLOCK_GROUP_RAID10        (1ULL << 6)
+BTRFS_BLOCK_GROUP_RAID5         (1ULL << 7)
+BTRFS_BLOCK_GROUP_RAID6         (1ULL << 8)
+BTRFS_AVAIL_ALLOC_BIT_SINGLE    (1ULL << 48)
+BTRFS_SPACE_INFO_GLOBAL_RSV     (1ULL << 49)
diff --git a/strace/xlat/btrfs_tree_objectids.h b/strace/xlat/btrfs_tree_objectids.h
new file mode 100644
index 0000000..f96ee7f
--- /dev/null
+++ b/strace/xlat/btrfs_tree_objectids.h
@@ -0,0 +1,68 @@
+/* Generated by ./xlat/gen.sh from ./xlat/btrfs_tree_objectids.in; do not edit. */
+#if !(defined(BTRFS_ROOT_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_ROOT_TREE_OBJECTID) && HAVE_DECL_BTRFS_ROOT_TREE_OBJECTID))
+# define BTRFS_ROOT_TREE_OBJECTID 1ULL
+#endif
+#if !(defined(BTRFS_EXTENT_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_EXTENT_TREE_OBJECTID) && HAVE_DECL_BTRFS_EXTENT_TREE_OBJECTID))
+# define BTRFS_EXTENT_TREE_OBJECTID 2ULL
+#endif
+#if !(defined(BTRFS_CHUNK_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_CHUNK_TREE_OBJECTID) && HAVE_DECL_BTRFS_CHUNK_TREE_OBJECTID))
+# define BTRFS_CHUNK_TREE_OBJECTID 3ULL
+#endif
+#if !(defined(BTRFS_DEV_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_DEV_TREE_OBJECTID) && HAVE_DECL_BTRFS_DEV_TREE_OBJECTID))
+# define BTRFS_DEV_TREE_OBJECTID 4ULL
+#endif
+#if !(defined(BTRFS_FS_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_FS_TREE_OBJECTID) && HAVE_DECL_BTRFS_FS_TREE_OBJECTID))
+# define BTRFS_FS_TREE_OBJECTID 5ULL
+#endif
+#if !(defined(BTRFS_ROOT_TREE_DIR_OBJECTID) || (defined(HAVE_DECL_BTRFS_ROOT_TREE_DIR_OBJECTID) && HAVE_DECL_BTRFS_ROOT_TREE_DIR_OBJECTID))
+# define BTRFS_ROOT_TREE_DIR_OBJECTID 6ULL
+#endif
+#if !(defined(BTRFS_CSUM_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_CSUM_TREE_OBJECTID) && HAVE_DECL_BTRFS_CSUM_TREE_OBJECTID))
+# define BTRFS_CSUM_TREE_OBJECTID 7ULL
+#endif
+#if !(defined(BTRFS_QUOTA_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_QUOTA_TREE_OBJECTID) && HAVE_DECL_BTRFS_QUOTA_TREE_OBJECTID))
+# define BTRFS_QUOTA_TREE_OBJECTID 8ULL
+#endif
+#if !(defined(BTRFS_UUID_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_UUID_TREE_OBJECTID) && HAVE_DECL_BTRFS_UUID_TREE_OBJECTID))
+# define BTRFS_UUID_TREE_OBJECTID 9ULL
+#endif
+#if !(defined(BTRFS_FREE_SPACE_TREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_FREE_SPACE_TREE_OBJECTID) && HAVE_DECL_BTRFS_FREE_SPACE_TREE_OBJECTID))
+# define BTRFS_FREE_SPACE_TREE_OBJECTID 10ULL
+#endif
+#if !(defined(BTRFS_FIRST_FREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_FIRST_FREE_OBJECTID) && HAVE_DECL_BTRFS_FIRST_FREE_OBJECTID))
+# define BTRFS_FIRST_FREE_OBJECTID 256ULL
+#endif
+#if !(defined(BTRFS_LAST_FREE_OBJECTID) || (defined(HAVE_DECL_BTRFS_LAST_FREE_OBJECTID) && HAVE_DECL_BTRFS_LAST_FREE_OBJECTID))
+# define BTRFS_LAST_FREE_OBJECTID -256ULL
+#endif
+#if !(defined(UINT64_MAX) || (defined(HAVE_DECL_UINT64_MAX) && HAVE_DECL_UINT64_MAX))
+# define UINT64_MAX -1ULL
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat btrfs_tree_objectids[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat btrfs_tree_objectids[] = {
+ XLAT_TYPE(uint64_t, BTRFS_ROOT_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_EXTENT_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_CHUNK_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_DEV_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_FS_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_ROOT_TREE_DIR_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_CSUM_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_QUOTA_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_UUID_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_FREE_SPACE_TREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_FIRST_FREE_OBJECTID),
+ XLAT_TYPE(uint64_t, BTRFS_LAST_FREE_OBJECTID),
+ XLAT_TYPE(uint64_t, UINT64_MAX),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/btrfs_tree_objectids.in b/strace/xlat/btrfs_tree_objectids.in
new file mode 100644
index 0000000..0b6e598
--- /dev/null
+++ b/strace/xlat/btrfs_tree_objectids.in
@@ -0,0 +1,14 @@
+#val_type uint64_t
+BTRFS_ROOT_TREE_OBJECTID 1ULL
+BTRFS_EXTENT_TREE_OBJECTID 2ULL
+BTRFS_CHUNK_TREE_OBJECTID 3ULL
+BTRFS_DEV_TREE_OBJECTID 4ULL
+BTRFS_FS_TREE_OBJECTID 5ULL
+BTRFS_ROOT_TREE_DIR_OBJECTID 6ULL
+BTRFS_CSUM_TREE_OBJECTID 7ULL
+BTRFS_QUOTA_TREE_OBJECTID 8ULL
+BTRFS_UUID_TREE_OBJECTID 9ULL
+BTRFS_FREE_SPACE_TREE_OBJECTID 10ULL
+BTRFS_FIRST_FREE_OBJECTID 256ULL
+BTRFS_LAST_FREE_OBJECTID -256ULL
+UINT64_MAX -1ULL
diff --git a/strace/xlat/cacheflush_scope.h b/strace/xlat/cacheflush_scope.h
new file mode 100644
index 0000000..4859774
--- /dev/null
+++ b/strace/xlat/cacheflush_scope.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/cacheflush_scope.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat cacheflush_scope in mpers mode
+
+#else
+
+static
+const struct xlat cacheflush_scope[] = {
+#if defined(FLUSH_SCOPE_LINE) || (defined(HAVE_DECL_FLUSH_SCOPE_LINE) && HAVE_DECL_FLUSH_SCOPE_LINE)
+  XLAT(FLUSH_SCOPE_LINE),
+#endif
+#if defined(FLUSH_SCOPE_PAGE) || (defined(HAVE_DECL_FLUSH_SCOPE_PAGE) && HAVE_DECL_FLUSH_SCOPE_PAGE)
+  XLAT(FLUSH_SCOPE_PAGE),
+#endif
+#if defined(FLUSH_SCOPE_ALL) || (defined(HAVE_DECL_FLUSH_SCOPE_ALL) && HAVE_DECL_FLUSH_SCOPE_ALL)
+  XLAT(FLUSH_SCOPE_ALL),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/cacheflush_scope.in b/strace/xlat/cacheflush_scope.in
new file mode 100644
index 0000000..5f91b90
--- /dev/null
+++ b/strace/xlat/cacheflush_scope.in
@@ -0,0 +1,3 @@
+FLUSH_SCOPE_LINE
+FLUSH_SCOPE_PAGE
+FLUSH_SCOPE_ALL
diff --git a/strace/xlat/cap.h b/strace/xlat/cap.h
new file mode 100644
index 0000000..fb50990
--- /dev/null
+++ b/strace/xlat/cap.h
@@ -0,0 +1,52 @@
+/* Generated by ./xlat/gen.sh from ./xlat/cap.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat cap in mpers mode
+
+#else
+
+static
+const struct xlat cap[] = {
+ XLAT(CAP_CHOWN),
+ XLAT(CAP_DAC_OVERRIDE),
+ XLAT(CAP_DAC_READ_SEARCH),
+ XLAT(CAP_FOWNER),
+ XLAT(CAP_FSETID),
+ XLAT(CAP_KILL),
+ XLAT(CAP_SETGID),
+ XLAT(CAP_SETUID),
+ XLAT(CAP_SETPCAP),
+ XLAT(CAP_LINUX_IMMUTABLE),
+ XLAT(CAP_NET_BIND_SERVICE),
+ XLAT(CAP_NET_BROADCAST),
+ XLAT(CAP_NET_ADMIN),
+ XLAT(CAP_NET_RAW),
+ XLAT(CAP_IPC_LOCK),
+ XLAT(CAP_IPC_OWNER),
+ XLAT(CAP_SYS_MODULE),
+ XLAT(CAP_SYS_RAWIO),
+ XLAT(CAP_SYS_CHROOT),
+ XLAT(CAP_SYS_PTRACE),
+ XLAT(CAP_SYS_PACCT),
+ XLAT(CAP_SYS_ADMIN),
+ XLAT(CAP_SYS_BOOT),
+ XLAT(CAP_SYS_NICE),
+ XLAT(CAP_SYS_RESOURCE),
+ XLAT(CAP_SYS_TIME),
+ XLAT(CAP_SYS_TTY_CONFIG),
+ XLAT(CAP_MKNOD),
+ XLAT(CAP_LEASE),
+ XLAT(CAP_AUDIT_WRITE),
+ XLAT(CAP_AUDIT_CONTROL),
+ XLAT(CAP_SETFCAP),
+ XLAT(CAP_MAC_OVERRIDE),
+ XLAT(CAP_MAC_ADMIN),
+ XLAT(CAP_SYSLOG),
+ XLAT(CAP_WAKE_ALARM),
+ XLAT(CAP_BLOCK_SUSPEND),
+ XLAT(CAP_AUDIT_READ),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/cap.in b/strace/xlat/cap.in
new file mode 100644
index 0000000..bbac8d3
--- /dev/null
+++ b/strace/xlat/cap.in
@@ -0,0 +1,39 @@
+#unconditional
+CAP_CHOWN
+CAP_DAC_OVERRIDE
+CAP_DAC_READ_SEARCH
+CAP_FOWNER
+CAP_FSETID
+CAP_KILL
+CAP_SETGID
+CAP_SETUID
+CAP_SETPCAP
+CAP_LINUX_IMMUTABLE
+CAP_NET_BIND_SERVICE
+CAP_NET_BROADCAST
+CAP_NET_ADMIN
+CAP_NET_RAW
+CAP_IPC_LOCK
+CAP_IPC_OWNER
+CAP_SYS_MODULE
+CAP_SYS_RAWIO
+CAP_SYS_CHROOT
+CAP_SYS_PTRACE
+CAP_SYS_PACCT
+CAP_SYS_ADMIN
+CAP_SYS_BOOT
+CAP_SYS_NICE
+CAP_SYS_RESOURCE
+CAP_SYS_TIME
+CAP_SYS_TTY_CONFIG
+CAP_MKNOD
+CAP_LEASE
+CAP_AUDIT_WRITE
+CAP_AUDIT_CONTROL
+CAP_SETFCAP
+CAP_MAC_OVERRIDE
+CAP_MAC_ADMIN
+CAP_SYSLOG
+CAP_WAKE_ALARM
+CAP_BLOCK_SUSPEND
+CAP_AUDIT_READ
diff --git a/strace/xlat/cap_mask0.h b/strace/xlat/cap_mask0.h
new file mode 100644
index 0000000..4402dc2
--- /dev/null
+++ b/strace/xlat/cap_mask0.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/cap_mask0.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat cap_mask0 in mpers mode
+
+#else
+
+static
+const struct xlat cap_mask0[] = {
+ XLAT_PAIR(1ULL<<CAP_CHOWN, "1<<CAP_CHOWN"),
+ XLAT_PAIR(1ULL<<CAP_DAC_OVERRIDE, "1<<CAP_DAC_OVERRIDE"),
+ XLAT_PAIR(1ULL<<CAP_DAC_READ_SEARCH, "1<<CAP_DAC_READ_SEARCH"),
+ XLAT_PAIR(1ULL<<CAP_FOWNER, "1<<CAP_FOWNER"),
+ XLAT_PAIR(1ULL<<CAP_FSETID, "1<<CAP_FSETID"),
+ XLAT_PAIR(1ULL<<CAP_KILL, "1<<CAP_KILL"),
+ XLAT_PAIR(1ULL<<CAP_SETGID, "1<<CAP_SETGID"),
+ XLAT_PAIR(1ULL<<CAP_SETUID, "1<<CAP_SETUID"),
+ XLAT_PAIR(1ULL<<CAP_SETPCAP, "1<<CAP_SETPCAP"),
+ XLAT_PAIR(1ULL<<CAP_LINUX_IMMUTABLE, "1<<CAP_LINUX_IMMUTABLE"),
+ XLAT_PAIR(1ULL<<CAP_NET_BIND_SERVICE, "1<<CAP_NET_BIND_SERVICE"),
+ XLAT_PAIR(1ULL<<CAP_NET_BROADCAST, "1<<CAP_NET_BROADCAST"),
+ XLAT_PAIR(1ULL<<CAP_NET_ADMIN, "1<<CAP_NET_ADMIN"),
+ XLAT_PAIR(1ULL<<CAP_NET_RAW, "1<<CAP_NET_RAW"),
+ XLAT_PAIR(1ULL<<CAP_IPC_LOCK, "1<<CAP_IPC_LOCK"),
+ XLAT_PAIR(1ULL<<CAP_IPC_OWNER, "1<<CAP_IPC_OWNER"),
+ XLAT_PAIR(1ULL<<CAP_SYS_MODULE, "1<<CAP_SYS_MODULE"),
+ XLAT_PAIR(1ULL<<CAP_SYS_RAWIO, "1<<CAP_SYS_RAWIO"),
+ XLAT_PAIR(1ULL<<CAP_SYS_CHROOT, "1<<CAP_SYS_CHROOT"),
+ XLAT_PAIR(1ULL<<CAP_SYS_PTRACE, "1<<CAP_SYS_PTRACE"),
+ XLAT_PAIR(1ULL<<CAP_SYS_PACCT, "1<<CAP_SYS_PACCT"),
+ XLAT_PAIR(1ULL<<CAP_SYS_ADMIN, "1<<CAP_SYS_ADMIN"),
+ XLAT_PAIR(1ULL<<CAP_SYS_BOOT, "1<<CAP_SYS_BOOT"),
+ XLAT_PAIR(1ULL<<CAP_SYS_NICE, "1<<CAP_SYS_NICE"),
+ XLAT_PAIR(1ULL<<CAP_SYS_RESOURCE, "1<<CAP_SYS_RESOURCE"),
+ XLAT_PAIR(1ULL<<CAP_SYS_TIME, "1<<CAP_SYS_TIME"),
+ XLAT_PAIR(1ULL<<CAP_SYS_TTY_CONFIG, "1<<CAP_SYS_TTY_CONFIG"),
+ XLAT_PAIR(1ULL<<CAP_MKNOD, "1<<CAP_MKNOD"),
+ XLAT_PAIR(1ULL<<CAP_LEASE, "1<<CAP_LEASE"),
+ XLAT_PAIR(1ULL<<CAP_AUDIT_WRITE, "1<<CAP_AUDIT_WRITE"),
+ XLAT_PAIR(1ULL<<CAP_AUDIT_CONTROL, "1<<CAP_AUDIT_CONTROL"),
+ XLAT_PAIR(1ULL<<CAP_SETFCAP, "1<<CAP_SETFCAP"),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/cap_mask0.in b/strace/xlat/cap_mask0.in
new file mode 100644
index 0000000..4c48b84
--- /dev/null
+++ b/strace/xlat/cap_mask0.in
@@ -0,0 +1,33 @@
+#unconditional
+1<<CAP_CHOWN
+1<<CAP_DAC_OVERRIDE
+1<<CAP_DAC_READ_SEARCH
+1<<CAP_FOWNER
+1<<CAP_FSETID
+1<<CAP_KILL
+1<<CAP_SETGID
+1<<CAP_SETUID
+1<<CAP_SETPCAP
+1<<CAP_LINUX_IMMUTABLE
+1<<CAP_NET_BIND_SERVICE
+1<<CAP_NET_BROADCAST
+1<<CAP_NET_ADMIN
+1<<CAP_NET_RAW
+1<<CAP_IPC_LOCK
+1<<CAP_IPC_OWNER
+1<<CAP_SYS_MODULE
+1<<CAP_SYS_RAWIO
+1<<CAP_SYS_CHROOT
+1<<CAP_SYS_PTRACE
+1<<CAP_SYS_PACCT
+1<<CAP_SYS_ADMIN
+1<<CAP_SYS_BOOT
+1<<CAP_SYS_NICE
+1<<CAP_SYS_RESOURCE
+1<<CAP_SYS_TIME
+1<<CAP_SYS_TTY_CONFIG
+1<<CAP_MKNOD
+1<<CAP_LEASE
+1<<CAP_AUDIT_WRITE
+1<<CAP_AUDIT_CONTROL
+1<<CAP_SETFCAP
diff --git a/strace/xlat/cap_mask1.h b/strace/xlat/cap_mask1.h
new file mode 100644
index 0000000..074f5c6
--- /dev/null
+++ b/strace/xlat/cap_mask1.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/cap_mask1.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat cap_mask1 in mpers mode
+
+#else
+
+static
+const struct xlat cap_mask1[] = {
+ XLAT_PAIR(1ULL<<CAP_MAC_OVERRIDE, "1<<CAP_MAC_OVERRIDE"),
+ XLAT_PAIR(1ULL<<CAP_MAC_ADMIN, "1<<CAP_MAC_ADMIN"),
+ XLAT_PAIR(1ULL<<CAP_SYSLOG, "1<<CAP_SYSLOG"),
+ XLAT_PAIR(1ULL<<CAP_WAKE_ALARM, "1<<CAP_WAKE_ALARM"),
+ XLAT_PAIR(1ULL<<CAP_BLOCK_SUSPEND, "1<<CAP_BLOCK_SUSPEND"),
+ XLAT_PAIR(1ULL<<CAP_AUDIT_READ, "1<<CAP_AUDIT_READ"),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/cap_mask1.in b/strace/xlat/cap_mask1.in
new file mode 100644
index 0000000..bf787a0
--- /dev/null
+++ b/strace/xlat/cap_mask1.in
@@ -0,0 +1,7 @@
+#unconditional
+1<<CAP_MAC_OVERRIDE
+1<<CAP_MAC_ADMIN
+1<<CAP_SYSLOG
+1<<CAP_WAKE_ALARM
+1<<CAP_BLOCK_SUSPEND
+1<<CAP_AUDIT_READ
diff --git a/strace/xlat/cap_version.h b/strace/xlat/cap_version.h
new file mode 100644
index 0000000..35c9189
--- /dev/null
+++ b/strace/xlat/cap_version.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/cap_version.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat cap_version in mpers mode
+
+#else
+
+static
+const struct xlat cap_version[] = {
+ XLAT(_LINUX_CAPABILITY_VERSION_1),
+ XLAT(_LINUX_CAPABILITY_VERSION_2),
+ XLAT(_LINUX_CAPABILITY_VERSION_3),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/cap_version.in b/strace/xlat/cap_version.in
new file mode 100644
index 0000000..3d5b744
--- /dev/null
+++ b/strace/xlat/cap_version.in
@@ -0,0 +1,4 @@
+#unconditional
+_LINUX_CAPABILITY_VERSION_1
+_LINUX_CAPABILITY_VERSION_2
+_LINUX_CAPABILITY_VERSION_3
diff --git a/strace/xlat/capabilities.h b/strace/xlat/capabilities.h
new file mode 100644
index 0000000..e7539a8
--- /dev/null
+++ b/strace/xlat/capabilities.h
@@ -0,0 +1,37 @@
+/* Generated by ./xlat/gen.sh from ./xlat/capabilities.in; do not edit. */
+
+static const struct xlat capabilities[] = {
+	{ 1<<CAP_CHOWN, "CAP_CHOWN" },
+	{ 1<<CAP_DAC_OVERRIDE, "CAP_DAC_OVERRIDE" },
+	{ 1<<CAP_DAC_READ_SEARCH, "CAP_DAC_READ_SEARCH" },
+	{ 1<<CAP_FOWNER, "CAP_FOWNER" },
+	{ 1<<CAP_FSETID, "CAP_FSETID" },
+	{ 1<<CAP_KILL, "CAP_KILL" },
+	{ 1<<CAP_SETGID, "CAP_SETGID" },
+	{ 1<<CAP_SETUID, "CAP_SETUID" },
+	{ 1<<CAP_SETPCAP, "CAP_SETPCAP" },
+	{ 1<<CAP_LINUX_IMMUTABLE, "CAP_LINUX_IMMUTABLE" },
+	{ 1<<CAP_NET_BIND_SERVICE, "CAP_NET_BIND_SERVICE" },
+	{ 1<<CAP_NET_BROADCAST, "CAP_NET_BROADCAST" },
+	{ 1<<CAP_NET_ADMIN, "CAP_NET_ADMIN" },
+	{ 1<<CAP_NET_RAW, "CAP_NET_RAW" },
+	{ 1<<CAP_IPC_LOCK, "CAP_IPC_LOCK" },
+	{ 1<<CAP_IPC_OWNER, "CAP_IPC_OWNER" },
+	{ 1<<CAP_SYS_MODULE, "CAP_SYS_MODULE" },
+	{ 1<<CAP_SYS_RAWIO, "CAP_SYS_RAWIO" },
+	{ 1<<CAP_SYS_CHROOT, "CAP_SYS_CHROOT" },
+	{ 1<<CAP_SYS_PTRACE, "CAP_SYS_PTRACE" },
+	{ 1<<CAP_SYS_PACCT, "CAP_SYS_PACCT" },
+	{ 1<<CAP_SYS_ADMIN, "CAP_SYS_ADMIN" },
+	{ 1<<CAP_SYS_BOOT, "CAP_SYS_BOOT" },
+	{ 1<<CAP_SYS_NICE, "CAP_SYS_NICE" },
+	{ 1<<CAP_SYS_RESOURCE, "CAP_SYS_RESOURCE" },
+	{ 1<<CAP_SYS_TIME, "CAP_SYS_TIME" },
+	{ 1<<CAP_SYS_TTY_CONFIG, "CAP_SYS_TTY_CONFIG" },
+	{ 1<<CAP_MKNOD, "CAP_MKNOD" },
+	{ 1<<CAP_LEASE, "CAP_LEASE" },
+	{ 1<<CAP_AUDIT_WRITE, "CAP_AUDIT_WRITE" },
+	{ 1<<CAP_AUDIT_CONTROL, "CAP_AUDIT_CONTROL" },
+	{ 1<<CAP_SETFCAP, "CAP_SETFCAP" },
+	XLAT_END
+};
diff --git a/strace/xlat/capabilities1.h b/strace/xlat/capabilities1.h
new file mode 100644
index 0000000..9403283
--- /dev/null
+++ b/strace/xlat/capabilities1.h
@@ -0,0 +1,11 @@
+/* Generated by ./xlat/gen.sh from ./xlat/capabilities1.in; do not edit. */
+
+static const struct xlat capabilities1[] = {
+	{ 1<<CAP_MAC_OVERRIDE, "CAP_MAC_OVERRIDE" },
+	{ 1<<CAP_MAC_ADMIN, "CAP_MAC_ADMIN" },
+	{ 1<<CAP_SYSLOG, "CAP_SYSLOG" },
+	{ 1<<CAP_WAKE_ALARM, "CAP_WAKE_ALARM" },
+	{ 1<<CAP_BLOCK_SUSPEND, "CAP_BLOCK_SUSPEND" },
+	{ 1<<CAP_AUDIT_READ, "CAP_AUDIT_READ" },
+	XLAT_END
+};
diff --git a/strace/xlat/clockflags.h b/strace/xlat/clockflags.h
new file mode 100644
index 0000000..d24419d
--- /dev/null
+++ b/strace/xlat/clockflags.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/clockflags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat clockflags in mpers mode
+
+#else
+
+static
+const struct xlat clockflags[] = {
+#if defined(TIMER_ABSTIME) || (defined(HAVE_DECL_TIMER_ABSTIME) && HAVE_DECL_TIMER_ABSTIME)
+  XLAT(TIMER_ABSTIME),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/clockflags.in b/strace/xlat/clockflags.in
new file mode 100644
index 0000000..2c3a82f
--- /dev/null
+++ b/strace/xlat/clockflags.in
@@ -0,0 +1 @@
+TIMER_ABSTIME
diff --git a/strace/xlat/clocknames.h b/strace/xlat/clocknames.h
new file mode 100644
index 0000000..29beb38
--- /dev/null
+++ b/strace/xlat/clocknames.h
@@ -0,0 +1,50 @@
+/* Generated by ./xlat/gen.sh from ./xlat/clocknames.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat clocknames in mpers mode
+
+#else
+
+static
+const struct xlat clocknames[] = {
+#if defined(CLOCK_REALTIME) || (defined(HAVE_DECL_CLOCK_REALTIME) && HAVE_DECL_CLOCK_REALTIME)
+  XLAT(CLOCK_REALTIME),
+#endif
+#if defined(CLOCK_MONOTONIC) || (defined(HAVE_DECL_CLOCK_MONOTONIC) && HAVE_DECL_CLOCK_MONOTONIC)
+  XLAT(CLOCK_MONOTONIC),
+#endif
+#if defined(CLOCK_PROCESS_CPUTIME_ID) || (defined(HAVE_DECL_CLOCK_PROCESS_CPUTIME_ID) && HAVE_DECL_CLOCK_PROCESS_CPUTIME_ID)
+  XLAT(CLOCK_PROCESS_CPUTIME_ID),
+#endif
+#if defined(CLOCK_THREAD_CPUTIME_ID) || (defined(HAVE_DECL_CLOCK_THREAD_CPUTIME_ID) && HAVE_DECL_CLOCK_THREAD_CPUTIME_ID)
+  XLAT(CLOCK_THREAD_CPUTIME_ID),
+#endif
+#if defined(CLOCK_MONOTONIC_RAW) || (defined(HAVE_DECL_CLOCK_MONOTONIC_RAW) && HAVE_DECL_CLOCK_MONOTONIC_RAW)
+  XLAT(CLOCK_MONOTONIC_RAW),
+#endif
+#if defined(CLOCK_REALTIME_COARSE) || (defined(HAVE_DECL_CLOCK_REALTIME_COARSE) && HAVE_DECL_CLOCK_REALTIME_COARSE)
+  XLAT(CLOCK_REALTIME_COARSE),
+#endif
+#if defined(CLOCK_MONOTONIC_COARSE) || (defined(HAVE_DECL_CLOCK_MONOTONIC_COARSE) && HAVE_DECL_CLOCK_MONOTONIC_COARSE)
+  XLAT(CLOCK_MONOTONIC_COARSE),
+#endif
+#if defined(CLOCK_BOOTTIME) || (defined(HAVE_DECL_CLOCK_BOOTTIME) && HAVE_DECL_CLOCK_BOOTTIME)
+  XLAT(CLOCK_BOOTTIME),
+#endif
+#if defined(CLOCK_REALTIME_ALARM) || (defined(HAVE_DECL_CLOCK_REALTIME_ALARM) && HAVE_DECL_CLOCK_REALTIME_ALARM)
+  XLAT(CLOCK_REALTIME_ALARM),
+#endif
+#if defined(CLOCK_BOOTTIME_ALARM) || (defined(HAVE_DECL_CLOCK_BOOTTIME_ALARM) && HAVE_DECL_CLOCK_BOOTTIME_ALARM)
+  XLAT(CLOCK_BOOTTIME_ALARM),
+#endif
+#if defined(CLOCK_SGI_CYCLE) || (defined(HAVE_DECL_CLOCK_SGI_CYCLE) && HAVE_DECL_CLOCK_SGI_CYCLE)
+  XLAT(CLOCK_SGI_CYCLE),
+#endif
+#if defined(CLOCK_TAI) || (defined(HAVE_DECL_CLOCK_TAI) && HAVE_DECL_CLOCK_TAI)
+  XLAT(CLOCK_TAI),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/clocknames.in b/strace/xlat/clocknames.in
new file mode 100644
index 0000000..4485666
--- /dev/null
+++ b/strace/xlat/clocknames.in
@@ -0,0 +1,12 @@
+CLOCK_REALTIME
+CLOCK_MONOTONIC
+CLOCK_PROCESS_CPUTIME_ID
+CLOCK_THREAD_CPUTIME_ID
+CLOCK_MONOTONIC_RAW
+CLOCK_REALTIME_COARSE
+CLOCK_MONOTONIC_COARSE
+CLOCK_BOOTTIME
+CLOCK_REALTIME_ALARM
+CLOCK_BOOTTIME_ALARM
+CLOCK_SGI_CYCLE
+CLOCK_TAI
diff --git a/strace/xlat/clone_flags.h b/strace/xlat/clone_flags.h
new file mode 100644
index 0000000..a7e4c4b
--- /dev/null
+++ b/strace/xlat/clone_flags.h
@@ -0,0 +1,106 @@
+/* Generated by ./xlat/gen.sh from ./xlat/clone_flags.in; do not edit. */
+#if !(defined(CLONE_VM) || (defined(HAVE_DECL_CLONE_VM) && HAVE_DECL_CLONE_VM))
+# define CLONE_VM 0x00000100
+#endif
+#if !(defined(CLONE_FS) || (defined(HAVE_DECL_CLONE_FS) && HAVE_DECL_CLONE_FS))
+# define CLONE_FS 0x00000200
+#endif
+#if !(defined(CLONE_FILES) || (defined(HAVE_DECL_CLONE_FILES) && HAVE_DECL_CLONE_FILES))
+# define CLONE_FILES 0x00000400
+#endif
+#if !(defined(CLONE_SIGHAND) || (defined(HAVE_DECL_CLONE_SIGHAND) && HAVE_DECL_CLONE_SIGHAND))
+# define CLONE_SIGHAND 0x00000800
+#endif
+#if !(defined(CLONE_IDLETASK) || (defined(HAVE_DECL_CLONE_IDLETASK) && HAVE_DECL_CLONE_IDLETASK))
+# define CLONE_IDLETASK 0x00001000
+#endif
+#if !(defined(CLONE_PTRACE) || (defined(HAVE_DECL_CLONE_PTRACE) && HAVE_DECL_CLONE_PTRACE))
+# define CLONE_PTRACE 0x00002000
+#endif
+#if !(defined(CLONE_VFORK) || (defined(HAVE_DECL_CLONE_VFORK) && HAVE_DECL_CLONE_VFORK))
+# define CLONE_VFORK 0x00004000
+#endif
+#if !(defined(CLONE_PARENT) || (defined(HAVE_DECL_CLONE_PARENT) && HAVE_DECL_CLONE_PARENT))
+# define CLONE_PARENT 0x00008000
+#endif
+#if !(defined(CLONE_THREAD) || (defined(HAVE_DECL_CLONE_THREAD) && HAVE_DECL_CLONE_THREAD))
+# define CLONE_THREAD 0x00010000
+#endif
+#if !(defined(CLONE_NEWNS) || (defined(HAVE_DECL_CLONE_NEWNS) && HAVE_DECL_CLONE_NEWNS))
+# define CLONE_NEWNS 0x00020000
+#endif
+#if !(defined(CLONE_SYSVSEM) || (defined(HAVE_DECL_CLONE_SYSVSEM) && HAVE_DECL_CLONE_SYSVSEM))
+# define CLONE_SYSVSEM 0x00040000
+#endif
+#if !(defined(CLONE_SETTLS) || (defined(HAVE_DECL_CLONE_SETTLS) && HAVE_DECL_CLONE_SETTLS))
+# define CLONE_SETTLS 0x00080000
+#endif
+#if !(defined(CLONE_PARENT_SETTID) || (defined(HAVE_DECL_CLONE_PARENT_SETTID) && HAVE_DECL_CLONE_PARENT_SETTID))
+# define CLONE_PARENT_SETTID 0x00100000
+#endif
+#if !(defined(CLONE_CHILD_CLEARTID) || (defined(HAVE_DECL_CLONE_CHILD_CLEARTID) && HAVE_DECL_CLONE_CHILD_CLEARTID))
+# define CLONE_CHILD_CLEARTID 0x00200000
+#endif
+#if !(defined(CLONE_UNTRACED) || (defined(HAVE_DECL_CLONE_UNTRACED) && HAVE_DECL_CLONE_UNTRACED))
+# define CLONE_UNTRACED 0x00800000
+#endif
+#if !(defined(CLONE_CHILD_SETTID) || (defined(HAVE_DECL_CLONE_CHILD_SETTID) && HAVE_DECL_CLONE_CHILD_SETTID))
+# define CLONE_CHILD_SETTID 0x01000000
+#endif
+#if !(defined(CLONE_NEWCGROUP) || (defined(HAVE_DECL_CLONE_NEWCGROUP) && HAVE_DECL_CLONE_NEWCGROUP))
+# define CLONE_NEWCGROUP 0x02000000
+#endif
+#if !(defined(CLONE_NEWUTS) || (defined(HAVE_DECL_CLONE_NEWUTS) && HAVE_DECL_CLONE_NEWUTS))
+# define CLONE_NEWUTS 0x04000000
+#endif
+#if !(defined(CLONE_NEWIPC) || (defined(HAVE_DECL_CLONE_NEWIPC) && HAVE_DECL_CLONE_NEWIPC))
+# define CLONE_NEWIPC 0x08000000
+#endif
+#if !(defined(CLONE_NEWUSER) || (defined(HAVE_DECL_CLONE_NEWUSER) && HAVE_DECL_CLONE_NEWUSER))
+# define CLONE_NEWUSER 0x10000000
+#endif
+#if !(defined(CLONE_NEWPID) || (defined(HAVE_DECL_CLONE_NEWPID) && HAVE_DECL_CLONE_NEWPID))
+# define CLONE_NEWPID 0x20000000
+#endif
+#if !(defined(CLONE_NEWNET) || (defined(HAVE_DECL_CLONE_NEWNET) && HAVE_DECL_CLONE_NEWNET))
+# define CLONE_NEWNET 0x40000000
+#endif
+#if !(defined(CLONE_IO) || (defined(HAVE_DECL_CLONE_IO) && HAVE_DECL_CLONE_IO))
+# define CLONE_IO 0x80000000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat clone_flags in mpers mode
+
+#else
+
+static
+const struct xlat clone_flags[] = {
+ XLAT(CLONE_VM),
+ XLAT(CLONE_FS),
+ XLAT(CLONE_FILES),
+ XLAT(CLONE_SIGHAND),
+ XLAT(CLONE_IDLETASK),
+ XLAT(CLONE_PTRACE),
+ XLAT(CLONE_VFORK),
+ XLAT(CLONE_PARENT),
+ XLAT(CLONE_THREAD),
+ XLAT(CLONE_NEWNS),
+ XLAT(CLONE_SYSVSEM),
+ XLAT(CLONE_SETTLS),
+ XLAT(CLONE_PARENT_SETTID),
+ XLAT(CLONE_CHILD_CLEARTID),
+ XLAT(CLONE_UNTRACED),
+ XLAT(CLONE_CHILD_SETTID),
+ XLAT(CLONE_NEWCGROUP),
+ XLAT(CLONE_NEWUTS),
+ XLAT(CLONE_NEWIPC),
+ XLAT(CLONE_NEWUSER),
+ XLAT(CLONE_NEWPID),
+ XLAT(CLONE_NEWNET),
+ XLAT(CLONE_IO),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/clone_flags.in b/strace/xlat/clone_flags.in
new file mode 100644
index 0000000..2b08c79
--- /dev/null
+++ b/strace/xlat/clone_flags.in
@@ -0,0 +1,23 @@
+CLONE_VM	0x00000100
+CLONE_FS	0x00000200
+CLONE_FILES	0x00000400
+CLONE_SIGHAND	0x00000800
+CLONE_IDLETASK	0x00001000
+CLONE_PTRACE	0x00002000
+CLONE_VFORK	0x00004000
+CLONE_PARENT	0x00008000
+CLONE_THREAD	0x00010000
+CLONE_NEWNS	0x00020000
+CLONE_SYSVSEM	0x00040000
+CLONE_SETTLS	0x00080000
+CLONE_PARENT_SETTID	0x00100000
+CLONE_CHILD_CLEARTID	0x00200000
+CLONE_UNTRACED	0x00800000
+CLONE_CHILD_SETTID	0x01000000
+CLONE_NEWCGROUP	0x02000000
+CLONE_NEWUTS	0x04000000
+CLONE_NEWIPC	0x08000000
+CLONE_NEWUSER	0x10000000
+CLONE_NEWPID	0x20000000
+CLONE_NEWNET	0x40000000
+CLONE_IO	0x80000000
diff --git a/strace/xlat/cpuclocknames.h b/strace/xlat/cpuclocknames.h
new file mode 100644
index 0000000..8975159
--- /dev/null
+++ b/strace/xlat/cpuclocknames.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/cpuclocknames.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat cpuclocknames in mpers mode
+
+#else
+
+static
+const struct xlat cpuclocknames[] = {
+#if defined(CPUCLOCK_PROF) || (defined(HAVE_DECL_CPUCLOCK_PROF) && HAVE_DECL_CPUCLOCK_PROF)
+  XLAT(CPUCLOCK_PROF),
+#endif
+#if defined(CPUCLOCK_VIRT) || (defined(HAVE_DECL_CPUCLOCK_VIRT) && HAVE_DECL_CPUCLOCK_VIRT)
+  XLAT(CPUCLOCK_VIRT),
+#endif
+#if defined(CPUCLOCK_SCHED) || (defined(HAVE_DECL_CPUCLOCK_SCHED) && HAVE_DECL_CPUCLOCK_SCHED)
+  XLAT(CPUCLOCK_SCHED),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/cpuclocknames.in b/strace/xlat/cpuclocknames.in
new file mode 100644
index 0000000..e61fa8f
--- /dev/null
+++ b/strace/xlat/cpuclocknames.in
@@ -0,0 +1,3 @@
+CPUCLOCK_PROF
+CPUCLOCK_VIRT
+CPUCLOCK_SCHED
diff --git a/strace/xlat/delete_module_flags.h b/strace/xlat/delete_module_flags.h
new file mode 100644
index 0000000..279c45a
--- /dev/null
+++ b/strace/xlat/delete_module_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/delete_module_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat delete_module_flags in mpers mode
+
+#else
+
+static
+const struct xlat delete_module_flags[] = {
+#if defined(O_NONBLOCK) || (defined(HAVE_DECL_O_NONBLOCK) && HAVE_DECL_O_NONBLOCK)
+  XLAT(O_NONBLOCK),
+#endif
+#if defined(O_TRUNC) || (defined(HAVE_DECL_O_TRUNC) && HAVE_DECL_O_TRUNC)
+  XLAT(O_TRUNC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/delete_module_flags.in b/strace/xlat/delete_module_flags.in
new file mode 100644
index 0000000..8f02711
--- /dev/null
+++ b/strace/xlat/delete_module_flags.in
@@ -0,0 +1,2 @@
+O_NONBLOCK
+O_TRUNC
diff --git a/strace/xlat/dirent_types.h b/strace/xlat/dirent_types.h
new file mode 100644
index 0000000..42df495
--- /dev/null
+++ b/strace/xlat/dirent_types.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/dirent_types.in; do not edit. */
+
+#ifndef IN_MPERS
+
+const struct xlat dirent_types[] = {
+#if defined(DT_UNKNOWN) || (defined(HAVE_DECL_DT_UNKNOWN) && HAVE_DECL_DT_UNKNOWN)
+  XLAT(DT_UNKNOWN),
+#endif
+#if defined(DT_FIFO) || (defined(HAVE_DECL_DT_FIFO) && HAVE_DECL_DT_FIFO)
+  XLAT(DT_FIFO),
+#endif
+#if defined(DT_CHR) || (defined(HAVE_DECL_DT_CHR) && HAVE_DECL_DT_CHR)
+  XLAT(DT_CHR),
+#endif
+#if defined(DT_DIR) || (defined(HAVE_DECL_DT_DIR) && HAVE_DECL_DT_DIR)
+  XLAT(DT_DIR),
+#endif
+#if defined(DT_BLK) || (defined(HAVE_DECL_DT_BLK) && HAVE_DECL_DT_BLK)
+  XLAT(DT_BLK),
+#endif
+#if defined(DT_REG) || (defined(HAVE_DECL_DT_REG) && HAVE_DECL_DT_REG)
+  XLAT(DT_REG),
+#endif
+#if defined(DT_LNK) || (defined(HAVE_DECL_DT_LNK) && HAVE_DECL_DT_LNK)
+  XLAT(DT_LNK),
+#endif
+#if defined(DT_SOCK) || (defined(HAVE_DECL_DT_SOCK) && HAVE_DECL_DT_SOCK)
+  XLAT(DT_SOCK),
+#endif
+#if defined(DT_WHT) || (defined(HAVE_DECL_DT_WHT) && HAVE_DECL_DT_WHT)
+  XLAT(DT_WHT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/dirent_types.in b/strace/xlat/dirent_types.in
new file mode 100644
index 0000000..b16cc21
--- /dev/null
+++ b/strace/xlat/dirent_types.in
@@ -0,0 +1,9 @@
+DT_UNKNOWN
+DT_FIFO
+DT_CHR
+DT_DIR
+DT_BLK
+DT_REG
+DT_LNK
+DT_SOCK
+DT_WHT
diff --git a/strace/xlat/direnttypes.h b/strace/xlat/direnttypes.h
new file mode 100644
index 0000000..b883b09
--- /dev/null
+++ b/strace/xlat/direnttypes.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/direnttypes.in; do not edit. */
+
+static const struct xlat direnttypes[] = {
+#if defined(DT_UNKNOWN) || (defined(HAVE_DECL_DT_UNKNOWN) && HAVE_DECL_DT_UNKNOWN)
+ XLAT(DT_UNKNOWN),
+#endif
+#if defined(DT_FIFO) || (defined(HAVE_DECL_DT_FIFO) && HAVE_DECL_DT_FIFO)
+ XLAT(DT_FIFO),
+#endif
+#if defined(DT_CHR) || (defined(HAVE_DECL_DT_CHR) && HAVE_DECL_DT_CHR)
+ XLAT(DT_CHR),
+#endif
+#if defined(DT_DIR) || (defined(HAVE_DECL_DT_DIR) && HAVE_DECL_DT_DIR)
+ XLAT(DT_DIR),
+#endif
+#if defined(DT_BLK) || (defined(HAVE_DECL_DT_BLK) && HAVE_DECL_DT_BLK)
+ XLAT(DT_BLK),
+#endif
+#if defined(DT_REG) || (defined(HAVE_DECL_DT_REG) && HAVE_DECL_DT_REG)
+ XLAT(DT_REG),
+#endif
+#if defined(DT_LNK) || (defined(HAVE_DECL_DT_LNK) && HAVE_DECL_DT_LNK)
+ XLAT(DT_LNK),
+#endif
+#if defined(DT_SOCK) || (defined(HAVE_DECL_DT_SOCK) && HAVE_DECL_DT_SOCK)
+ XLAT(DT_SOCK),
+#endif
+#if defined(DT_WHT) || (defined(HAVE_DECL_DT_WHT) && HAVE_DECL_DT_WHT)
+ XLAT(DT_WHT),
+#endif
+ XLAT_END
+};
diff --git a/strace/xlat/domains.h b/strace/xlat/domains.h
new file mode 100644
index 0000000..6b603f3
--- /dev/null
+++ b/strace/xlat/domains.h
@@ -0,0 +1,143 @@
+/* Generated by ./xlat/gen.sh from ./xlat/domains.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat domains in mpers mode
+
+#else
+
+static
+const struct xlat domains[] = {
+#if defined(PF_UNSPEC) || (defined(HAVE_DECL_PF_UNSPEC) && HAVE_DECL_PF_UNSPEC)
+  XLAT(PF_UNSPEC),
+#endif
+#if defined(PF_LOCAL) || (defined(HAVE_DECL_PF_LOCAL) && HAVE_DECL_PF_LOCAL)
+  XLAT(PF_LOCAL),
+#endif
+#if defined(PF_UNIX) || (defined(HAVE_DECL_PF_UNIX) && HAVE_DECL_PF_UNIX)
+  XLAT(PF_UNIX),
+#endif
+#if defined(PF_INET) || (defined(HAVE_DECL_PF_INET) && HAVE_DECL_PF_INET)
+  XLAT(PF_INET),
+#endif
+#if defined(PF_AX25) || (defined(HAVE_DECL_PF_AX25) && HAVE_DECL_PF_AX25)
+  XLAT(PF_AX25),
+#endif
+#if defined(PF_IPX) || (defined(HAVE_DECL_PF_IPX) && HAVE_DECL_PF_IPX)
+  XLAT(PF_IPX),
+#endif
+#if defined(PF_APPLETALK) || (defined(HAVE_DECL_PF_APPLETALK) && HAVE_DECL_PF_APPLETALK)
+  XLAT(PF_APPLETALK),
+#endif
+#if defined(PF_NETROM) || (defined(HAVE_DECL_PF_NETROM) && HAVE_DECL_PF_NETROM)
+  XLAT(PF_NETROM),
+#endif
+#if defined(PF_BRIDGE) || (defined(HAVE_DECL_PF_BRIDGE) && HAVE_DECL_PF_BRIDGE)
+  XLAT(PF_BRIDGE),
+#endif
+#if defined(PF_ATMPVC) || (defined(HAVE_DECL_PF_ATMPVC) && HAVE_DECL_PF_ATMPVC)
+  XLAT(PF_ATMPVC),
+#endif
+#if defined(PF_X25) || (defined(HAVE_DECL_PF_X25) && HAVE_DECL_PF_X25)
+  XLAT(PF_X25),
+#endif
+#if defined(PF_INET6) || (defined(HAVE_DECL_PF_INET6) && HAVE_DECL_PF_INET6)
+  XLAT(PF_INET6),
+#endif
+#if defined(PF_ROSE) || (defined(HAVE_DECL_PF_ROSE) && HAVE_DECL_PF_ROSE)
+  XLAT(PF_ROSE),
+#endif
+#if defined(PF_DECnet) || (defined(HAVE_DECL_PF_DECnet) && HAVE_DECL_PF_DECnet)
+  XLAT(PF_DECnet),
+#endif
+#if defined(PF_NETBEUI) || (defined(HAVE_DECL_PF_NETBEUI) && HAVE_DECL_PF_NETBEUI)
+  XLAT(PF_NETBEUI),
+#endif
+#if defined(PF_SECURITY) || (defined(HAVE_DECL_PF_SECURITY) && HAVE_DECL_PF_SECURITY)
+  XLAT(PF_SECURITY),
+#endif
+#if defined(PF_KEY) || (defined(HAVE_DECL_PF_KEY) && HAVE_DECL_PF_KEY)
+  XLAT(PF_KEY),
+#endif
+#if defined(PF_NETLINK) || (defined(HAVE_DECL_PF_NETLINK) && HAVE_DECL_PF_NETLINK)
+  XLAT(PF_NETLINK),
+#endif
+#if defined(PF_ROUTE) || (defined(HAVE_DECL_PF_ROUTE) && HAVE_DECL_PF_ROUTE)
+  XLAT(PF_ROUTE),
+#endif
+#if defined(PF_PACKET) || (defined(HAVE_DECL_PF_PACKET) && HAVE_DECL_PF_PACKET)
+  XLAT(PF_PACKET),
+#endif
+#if defined(PF_ASH) || (defined(HAVE_DECL_PF_ASH) && HAVE_DECL_PF_ASH)
+  XLAT(PF_ASH),
+#endif
+#if defined(PF_ECONET) || (defined(HAVE_DECL_PF_ECONET) && HAVE_DECL_PF_ECONET)
+  XLAT(PF_ECONET),
+#endif
+#if defined(PF_ATMSVC) || (defined(HAVE_DECL_PF_ATMSVC) && HAVE_DECL_PF_ATMSVC)
+  XLAT(PF_ATMSVC),
+#endif
+#if defined(PF_RDS) || (defined(HAVE_DECL_PF_RDS) && HAVE_DECL_PF_RDS)
+  XLAT(PF_RDS),
+#endif
+#if defined(PF_SNA) || (defined(HAVE_DECL_PF_SNA) && HAVE_DECL_PF_SNA)
+  XLAT(PF_SNA),
+#endif
+#if defined(PF_IRDA) || (defined(HAVE_DECL_PF_IRDA) && HAVE_DECL_PF_IRDA)
+  XLAT(PF_IRDA),
+#endif
+#if defined(PF_PPPOX) || (defined(HAVE_DECL_PF_PPPOX) && HAVE_DECL_PF_PPPOX)
+  XLAT(PF_PPPOX),
+#endif
+#if defined(PF_WANPIPE) || (defined(HAVE_DECL_PF_WANPIPE) && HAVE_DECL_PF_WANPIPE)
+  XLAT(PF_WANPIPE),
+#endif
+#if defined(PF_LLC) || (defined(HAVE_DECL_PF_LLC) && HAVE_DECL_PF_LLC)
+  XLAT(PF_LLC),
+#endif
+#if defined(PF_IB) || (defined(HAVE_DECL_PF_IB) && HAVE_DECL_PF_IB)
+  XLAT(PF_IB),
+#endif
+#if defined(PF_MPLS) || (defined(HAVE_DECL_PF_MPLS) && HAVE_DECL_PF_MPLS)
+  XLAT(PF_MPLS),
+#endif
+#if defined(PF_CAN) || (defined(HAVE_DECL_PF_CAN) && HAVE_DECL_PF_CAN)
+  XLAT(PF_CAN),
+#endif
+#if defined(PF_TIPC) || (defined(HAVE_DECL_PF_TIPC) && HAVE_DECL_PF_TIPC)
+  XLAT(PF_TIPC),
+#endif
+#if defined(PF_BLUETOOTH) || (defined(HAVE_DECL_PF_BLUETOOTH) && HAVE_DECL_PF_BLUETOOTH)
+  XLAT(PF_BLUETOOTH),
+#endif
+#if defined(PF_IUCV) || (defined(HAVE_DECL_PF_IUCV) && HAVE_DECL_PF_IUCV)
+  XLAT(PF_IUCV),
+#endif
+#if defined(PF_RXRPC) || (defined(HAVE_DECL_PF_RXRPC) && HAVE_DECL_PF_RXRPC)
+  XLAT(PF_RXRPC),
+#endif
+#if defined(PF_ISDN) || (defined(HAVE_DECL_PF_ISDN) && HAVE_DECL_PF_ISDN)
+  XLAT(PF_ISDN),
+#endif
+#if defined(PF_PHONET) || (defined(HAVE_DECL_PF_PHONET) && HAVE_DECL_PF_PHONET)
+  XLAT(PF_PHONET),
+#endif
+#if defined(PF_IEEE802154) || (defined(HAVE_DECL_PF_IEEE802154) && HAVE_DECL_PF_IEEE802154)
+  XLAT(PF_IEEE802154),
+#endif
+#if defined(PF_CAIF) || (defined(HAVE_DECL_PF_CAIF) && HAVE_DECL_PF_CAIF)
+  XLAT(PF_CAIF),
+#endif
+#if defined(PF_ALG) || (defined(HAVE_DECL_PF_ALG) && HAVE_DECL_PF_ALG)
+  XLAT(PF_ALG),
+#endif
+#if defined(PF_NFC) || (defined(HAVE_DECL_PF_NFC) && HAVE_DECL_PF_NFC)
+  XLAT(PF_NFC),
+#endif
+#if defined(PF_VSOCK) || (defined(HAVE_DECL_PF_VSOCK) && HAVE_DECL_PF_VSOCK)
+  XLAT(PF_VSOCK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/efd_flags.h b/strace/xlat/efd_flags.h
new file mode 100644
index 0000000..641f116
--- /dev/null
+++ b/strace/xlat/efd_flags.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/efd_flags.in; do not edit. */
+#if !(defined(EFD_SEMAPHORE) || (defined(HAVE_DECL_EFD_SEMAPHORE) && HAVE_DECL_EFD_SEMAPHORE))
+# define EFD_SEMAPHORE 1
+#endif
+#if defined EFD_CLOEXEC || defined O_CLOEXEC
+#if !(defined(EFD_CLOEXEC) || (defined(HAVE_DECL_EFD_CLOEXEC) && HAVE_DECL_EFD_CLOEXEC))
+# define EFD_CLOEXEC O_CLOEXEC
+#endif
+#endif
+#if !(defined(EFD_NONBLOCK) || (defined(HAVE_DECL_EFD_NONBLOCK) && HAVE_DECL_EFD_NONBLOCK))
+# define EFD_NONBLOCK O_NONBLOCK
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat efd_flags in mpers mode
+
+#else
+
+static
+const struct xlat efd_flags[] = {
+ XLAT(EFD_SEMAPHORE),
+#if defined EFD_CLOEXEC || defined O_CLOEXEC
+ XLAT(EFD_CLOEXEC),
+#endif
+ XLAT(EFD_NONBLOCK),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/efd_flags.in b/strace/xlat/efd_flags.in
new file mode 100644
index 0000000..258fb9f
--- /dev/null
+++ b/strace/xlat/efd_flags.in
@@ -0,0 +1,5 @@
+EFD_SEMAPHORE	1
+#if defined EFD_CLOEXEC || defined O_CLOEXEC
+EFD_CLOEXEC	O_CLOEXEC
+#endif
+EFD_NONBLOCK	O_NONBLOCK
diff --git a/strace/xlat/epollctls.h b/strace/xlat/epollctls.h
new file mode 100644
index 0000000..6b06d8c
--- /dev/null
+++ b/strace/xlat/epollctls.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/epollctls.in; do not edit. */
+#if !(defined(EPOLL_CTL_ADD) || (defined(HAVE_DECL_EPOLL_CTL_ADD) && HAVE_DECL_EPOLL_CTL_ADD))
+# define EPOLL_CTL_ADD 1
+#endif
+#if !(defined(EPOLL_CTL_DEL) || (defined(HAVE_DECL_EPOLL_CTL_DEL) && HAVE_DECL_EPOLL_CTL_DEL))
+# define EPOLL_CTL_DEL 2
+#endif
+#if !(defined(EPOLL_CTL_MOD) || (defined(HAVE_DECL_EPOLL_CTL_MOD) && HAVE_DECL_EPOLL_CTL_MOD))
+# define EPOLL_CTL_MOD 3
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat epollctls in mpers mode
+
+#else
+
+static
+const struct xlat epollctls[] = {
+ XLAT(EPOLL_CTL_ADD),
+ XLAT(EPOLL_CTL_DEL),
+ XLAT(EPOLL_CTL_MOD),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/epollctls.in b/strace/xlat/epollctls.in
new file mode 100644
index 0000000..86665f6
--- /dev/null
+++ b/strace/xlat/epollctls.in
@@ -0,0 +1,3 @@
+EPOLL_CTL_ADD 1
+EPOLL_CTL_DEL 2
+EPOLL_CTL_MOD 3
diff --git a/strace/xlat/epollevents.h b/strace/xlat/epollevents.h
new file mode 100644
index 0000000..3b98b6d
--- /dev/null
+++ b/strace/xlat/epollevents.h
@@ -0,0 +1,59 @@
+/* Generated by ./xlat/gen.sh from ./xlat/epollevents.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat epollevents in mpers mode
+
+#else
+
+static
+const struct xlat epollevents[] = {
+#if defined(EPOLLIN) || (defined(HAVE_DECL_EPOLLIN) && HAVE_DECL_EPOLLIN)
+  XLAT(EPOLLIN),
+#endif
+#if defined(EPOLLPRI) || (defined(HAVE_DECL_EPOLLPRI) && HAVE_DECL_EPOLLPRI)
+  XLAT(EPOLLPRI),
+#endif
+#if defined(EPOLLOUT) || (defined(HAVE_DECL_EPOLLOUT) && HAVE_DECL_EPOLLOUT)
+  XLAT(EPOLLOUT),
+#endif
+#if defined(EPOLLRDNORM) || (defined(HAVE_DECL_EPOLLRDNORM) && HAVE_DECL_EPOLLRDNORM)
+  XLAT(EPOLLRDNORM),
+#endif
+#if defined(EPOLLRDBAND) || (defined(HAVE_DECL_EPOLLRDBAND) && HAVE_DECL_EPOLLRDBAND)
+  XLAT(EPOLLRDBAND),
+#endif
+#if defined(EPOLLWRNORM) || (defined(HAVE_DECL_EPOLLWRNORM) && HAVE_DECL_EPOLLWRNORM)
+  XLAT(EPOLLWRNORM),
+#endif
+#if defined(EPOLLWRBAND) || (defined(HAVE_DECL_EPOLLWRBAND) && HAVE_DECL_EPOLLWRBAND)
+  XLAT(EPOLLWRBAND),
+#endif
+#if defined(EPOLLMSG) || (defined(HAVE_DECL_EPOLLMSG) && HAVE_DECL_EPOLLMSG)
+  XLAT(EPOLLMSG),
+#endif
+#if defined(EPOLLERR) || (defined(HAVE_DECL_EPOLLERR) && HAVE_DECL_EPOLLERR)
+  XLAT(EPOLLERR),
+#endif
+#if defined(EPOLLHUP) || (defined(HAVE_DECL_EPOLLHUP) && HAVE_DECL_EPOLLHUP)
+  XLAT(EPOLLHUP),
+#endif
+#if defined(EPOLLRDHUP) || (defined(HAVE_DECL_EPOLLRDHUP) && HAVE_DECL_EPOLLRDHUP)
+  XLAT(EPOLLRDHUP),
+#endif
+#if defined(EPOLLEXCLUSIVE) || (defined(HAVE_DECL_EPOLLEXCLUSIVE) && HAVE_DECL_EPOLLEXCLUSIVE)
+  XLAT(EPOLLEXCLUSIVE),
+#endif
+#if defined(EPOLLWAKEUP) || (defined(HAVE_DECL_EPOLLWAKEUP) && HAVE_DECL_EPOLLWAKEUP)
+  XLAT(EPOLLWAKEUP),
+#endif
+#if defined(EPOLLONESHOT) || (defined(HAVE_DECL_EPOLLONESHOT) && HAVE_DECL_EPOLLONESHOT)
+  XLAT(EPOLLONESHOT),
+#endif
+#if defined(EPOLLET) || (defined(HAVE_DECL_EPOLLET) && HAVE_DECL_EPOLLET)
+  XLAT(EPOLLET),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/epollevents.in b/strace/xlat/epollevents.in
new file mode 100644
index 0000000..6fa6707
--- /dev/null
+++ b/strace/xlat/epollevents.in
@@ -0,0 +1,15 @@
+EPOLLIN
+EPOLLPRI
+EPOLLOUT
+EPOLLRDNORM
+EPOLLRDBAND
+EPOLLWRNORM
+EPOLLWRBAND
+EPOLLMSG
+EPOLLERR
+EPOLLHUP
+EPOLLRDHUP
+EPOLLEXCLUSIVE
+EPOLLWAKEUP
+EPOLLONESHOT
+EPOLLET
diff --git a/strace/xlat/epollflags.h b/strace/xlat/epollflags.h
new file mode 100644
index 0000000..cae4fe9
--- /dev/null
+++ b/strace/xlat/epollflags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/epollflags.in; do not edit. */
+#if defined EPOLL_CLOEXEC || defined O_CLOEXEC
+#if !(defined(EPOLL_CLOEXEC) || (defined(HAVE_DECL_EPOLL_CLOEXEC) && HAVE_DECL_EPOLL_CLOEXEC))
+# define EPOLL_CLOEXEC O_CLOEXEC
+#endif
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat epollflags in mpers mode
+
+#else
+
+static
+const struct xlat epollflags[] = {
+#if defined EPOLL_CLOEXEC || defined O_CLOEXEC
+ XLAT(EPOLL_CLOEXEC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/epollflags.in b/strace/xlat/epollflags.in
new file mode 100644
index 0000000..e7ebaaf
--- /dev/null
+++ b/strace/xlat/epollflags.in
@@ -0,0 +1,3 @@
+#if defined EPOLL_CLOEXEC || defined O_CLOEXEC
+EPOLL_CLOEXEC	O_CLOEXEC
+#endif
diff --git a/strace/xlat/ethernet_protocols.h b/strace/xlat/ethernet_protocols.h
new file mode 100644
index 0000000..142fee9
--- /dev/null
+++ b/strace/xlat/ethernet_protocols.h
@@ -0,0 +1,263 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ethernet_protocols.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ethernet_protocols in mpers mode
+
+#else
+
+static
+const struct xlat ethernet_protocols[] = {
+#if defined(ETH_P_LOOP) || (defined(HAVE_DECL_ETH_P_LOOP) && HAVE_DECL_ETH_P_LOOP)
+  XLAT(ETH_P_LOOP),
+#endif
+#if defined(ETH_P_PUP) || (defined(HAVE_DECL_ETH_P_PUP) && HAVE_DECL_ETH_P_PUP)
+  XLAT(ETH_P_PUP),
+#endif
+#if defined(ETH_P_PUPAT) || (defined(HAVE_DECL_ETH_P_PUPAT) && HAVE_DECL_ETH_P_PUPAT)
+  XLAT(ETH_P_PUPAT),
+#endif
+#if defined(ETH_P_TSN) || (defined(HAVE_DECL_ETH_P_TSN) && HAVE_DECL_ETH_P_TSN)
+  XLAT(ETH_P_TSN),
+#endif
+#if defined(ETH_P_IP) || (defined(HAVE_DECL_ETH_P_IP) && HAVE_DECL_ETH_P_IP)
+  XLAT(ETH_P_IP),
+#endif
+#if defined(ETH_P_X25) || (defined(HAVE_DECL_ETH_P_X25) && HAVE_DECL_ETH_P_X25)
+  XLAT(ETH_P_X25),
+#endif
+#if defined(ETH_P_ARP) || (defined(HAVE_DECL_ETH_P_ARP) && HAVE_DECL_ETH_P_ARP)
+  XLAT(ETH_P_ARP),
+#endif
+#if defined(ETH_P_BPQ) || (defined(HAVE_DECL_ETH_P_BPQ) && HAVE_DECL_ETH_P_BPQ)
+  XLAT(ETH_P_BPQ),
+#endif
+#if defined(ETH_P_IEEEPUP) || (defined(HAVE_DECL_ETH_P_IEEEPUP) && HAVE_DECL_ETH_P_IEEEPUP)
+  XLAT(ETH_P_IEEEPUP),
+#endif
+#if defined(ETH_P_IEEEPUPAT) || (defined(HAVE_DECL_ETH_P_IEEEPUPAT) && HAVE_DECL_ETH_P_IEEEPUPAT)
+  XLAT(ETH_P_IEEEPUPAT),
+#endif
+#if defined(ETH_P_BATMAN) || (defined(HAVE_DECL_ETH_P_BATMAN) && HAVE_DECL_ETH_P_BATMAN)
+  XLAT(ETH_P_BATMAN),
+#endif
+#if defined(ETH_P_DEC) || (defined(HAVE_DECL_ETH_P_DEC) && HAVE_DECL_ETH_P_DEC)
+  XLAT(ETH_P_DEC),
+#endif
+#if defined(ETH_P_DNA_DL) || (defined(HAVE_DECL_ETH_P_DNA_DL) && HAVE_DECL_ETH_P_DNA_DL)
+  XLAT(ETH_P_DNA_DL),
+#endif
+#if defined(ETH_P_DNA_RC) || (defined(HAVE_DECL_ETH_P_DNA_RC) && HAVE_DECL_ETH_P_DNA_RC)
+  XLAT(ETH_P_DNA_RC),
+#endif
+#if defined(ETH_P_DNA_RT) || (defined(HAVE_DECL_ETH_P_DNA_RT) && HAVE_DECL_ETH_P_DNA_RT)
+  XLAT(ETH_P_DNA_RT),
+#endif
+#if defined(ETH_P_LAT) || (defined(HAVE_DECL_ETH_P_LAT) && HAVE_DECL_ETH_P_LAT)
+  XLAT(ETH_P_LAT),
+#endif
+#if defined(ETH_P_DIAG) || (defined(HAVE_DECL_ETH_P_DIAG) && HAVE_DECL_ETH_P_DIAG)
+  XLAT(ETH_P_DIAG),
+#endif
+#if defined(ETH_P_CUST) || (defined(HAVE_DECL_ETH_P_CUST) && HAVE_DECL_ETH_P_CUST)
+  XLAT(ETH_P_CUST),
+#endif
+#if defined(ETH_P_SCA) || (defined(HAVE_DECL_ETH_P_SCA) && HAVE_DECL_ETH_P_SCA)
+  XLAT(ETH_P_SCA),
+#endif
+#if defined(ETH_P_TEB) || (defined(HAVE_DECL_ETH_P_TEB) && HAVE_DECL_ETH_P_TEB)
+  XLAT(ETH_P_TEB),
+#endif
+#if defined(ETH_P_RARP) || (defined(HAVE_DECL_ETH_P_RARP) && HAVE_DECL_ETH_P_RARP)
+  XLAT(ETH_P_RARP),
+#endif
+#if defined(ETH_P_ATALK) || (defined(HAVE_DECL_ETH_P_ATALK) && HAVE_DECL_ETH_P_ATALK)
+  XLAT(ETH_P_ATALK),
+#endif
+#if defined(ETH_P_AARP) || (defined(HAVE_DECL_ETH_P_AARP) && HAVE_DECL_ETH_P_AARP)
+  XLAT(ETH_P_AARP),
+#endif
+#if defined(ETH_P_8021Q) || (defined(HAVE_DECL_ETH_P_8021Q) && HAVE_DECL_ETH_P_8021Q)
+  XLAT(ETH_P_8021Q),
+#endif
+#if defined(ETH_P_IPX) || (defined(HAVE_DECL_ETH_P_IPX) && HAVE_DECL_ETH_P_IPX)
+  XLAT(ETH_P_IPX),
+#endif
+#if defined(ETH_P_IPV6) || (defined(HAVE_DECL_ETH_P_IPV6) && HAVE_DECL_ETH_P_IPV6)
+  XLAT(ETH_P_IPV6),
+#endif
+#if defined(ETH_P_PAUSE) || (defined(HAVE_DECL_ETH_P_PAUSE) && HAVE_DECL_ETH_P_PAUSE)
+  XLAT(ETH_P_PAUSE),
+#endif
+#if defined(ETH_P_SLOW) || (defined(HAVE_DECL_ETH_P_SLOW) && HAVE_DECL_ETH_P_SLOW)
+  XLAT(ETH_P_SLOW),
+#endif
+#if defined(ETH_P_WCCP) || (defined(HAVE_DECL_ETH_P_WCCP) && HAVE_DECL_ETH_P_WCCP)
+  XLAT(ETH_P_WCCP),
+#endif
+#if defined(ETH_P_MPLS_UC) || (defined(HAVE_DECL_ETH_P_MPLS_UC) && HAVE_DECL_ETH_P_MPLS_UC)
+  XLAT(ETH_P_MPLS_UC),
+#endif
+#if defined(ETH_P_MPLS_MC) || (defined(HAVE_DECL_ETH_P_MPLS_MC) && HAVE_DECL_ETH_P_MPLS_MC)
+  XLAT(ETH_P_MPLS_MC),
+#endif
+#if defined(ETH_P_ATMMPOA) || (defined(HAVE_DECL_ETH_P_ATMMPOA) && HAVE_DECL_ETH_P_ATMMPOA)
+  XLAT(ETH_P_ATMMPOA),
+#endif
+#if defined(ETH_P_PPP_DISC) || (defined(HAVE_DECL_ETH_P_PPP_DISC) && HAVE_DECL_ETH_P_PPP_DISC)
+  XLAT(ETH_P_PPP_DISC),
+#endif
+#if defined(ETH_P_PPP_SES) || (defined(HAVE_DECL_ETH_P_PPP_SES) && HAVE_DECL_ETH_P_PPP_SES)
+  XLAT(ETH_P_PPP_SES),
+#endif
+#if defined(ETH_P_LINK_CTL) || (defined(HAVE_DECL_ETH_P_LINK_CTL) && HAVE_DECL_ETH_P_LINK_CTL)
+  XLAT(ETH_P_LINK_CTL),
+#endif
+#if defined(ETH_P_ATMFATE) || (defined(HAVE_DECL_ETH_P_ATMFATE) && HAVE_DECL_ETH_P_ATMFATE)
+  XLAT(ETH_P_ATMFATE),
+#endif
+#if defined(ETH_P_PAE) || (defined(HAVE_DECL_ETH_P_PAE) && HAVE_DECL_ETH_P_PAE)
+  XLAT(ETH_P_PAE),
+#endif
+#if defined(ETH_P_AOE) || (defined(HAVE_DECL_ETH_P_AOE) && HAVE_DECL_ETH_P_AOE)
+  XLAT(ETH_P_AOE),
+#endif
+#if defined(ETH_P_8021AD) || (defined(HAVE_DECL_ETH_P_8021AD) && HAVE_DECL_ETH_P_8021AD)
+  XLAT(ETH_P_8021AD),
+#endif
+#if defined(ETH_P_802_EX1) || (defined(HAVE_DECL_ETH_P_802_EX1) && HAVE_DECL_ETH_P_802_EX1)
+  XLAT(ETH_P_802_EX1),
+#endif
+#if defined(ETH_P_TIPC) || (defined(HAVE_DECL_ETH_P_TIPC) && HAVE_DECL_ETH_P_TIPC)
+  XLAT(ETH_P_TIPC),
+#endif
+#if defined(ETH_P_MACSEC) || (defined(HAVE_DECL_ETH_P_MACSEC) && HAVE_DECL_ETH_P_MACSEC)
+  XLAT(ETH_P_MACSEC),
+#endif
+#if defined(ETH_P_8021AH) || (defined(HAVE_DECL_ETH_P_8021AH) && HAVE_DECL_ETH_P_8021AH)
+  XLAT(ETH_P_8021AH),
+#endif
+#if defined(ETH_P_MVRP) || (defined(HAVE_DECL_ETH_P_MVRP) && HAVE_DECL_ETH_P_MVRP)
+  XLAT(ETH_P_MVRP),
+#endif
+#if defined(ETH_P_1588) || (defined(HAVE_DECL_ETH_P_1588) && HAVE_DECL_ETH_P_1588)
+  XLAT(ETH_P_1588),
+#endif
+#if defined(ETH_P_PRP) || (defined(HAVE_DECL_ETH_P_PRP) && HAVE_DECL_ETH_P_PRP)
+  XLAT(ETH_P_PRP),
+#endif
+#if defined(ETH_P_FCOE) || (defined(HAVE_DECL_ETH_P_FCOE) && HAVE_DECL_ETH_P_FCOE)
+  XLAT(ETH_P_FCOE),
+#endif
+#if defined(ETH_P_TDLS) || (defined(HAVE_DECL_ETH_P_TDLS) && HAVE_DECL_ETH_P_TDLS)
+  XLAT(ETH_P_TDLS),
+#endif
+#if defined(ETH_P_FIP) || (defined(HAVE_DECL_ETH_P_FIP) && HAVE_DECL_ETH_P_FIP)
+  XLAT(ETH_P_FIP),
+#endif
+#if defined(ETH_P_80221) || (defined(HAVE_DECL_ETH_P_80221) && HAVE_DECL_ETH_P_80221)
+  XLAT(ETH_P_80221),
+#endif
+#if defined(ETH_P_HSR) || (defined(HAVE_DECL_ETH_P_HSR) && HAVE_DECL_ETH_P_HSR)
+  XLAT(ETH_P_HSR),
+#endif
+#if defined(ETH_P_LOOPBACK) || (defined(HAVE_DECL_ETH_P_LOOPBACK) && HAVE_DECL_ETH_P_LOOPBACK)
+  XLAT(ETH_P_LOOPBACK),
+#endif
+#if defined(ETH_P_QINQ1) || (defined(HAVE_DECL_ETH_P_QINQ1) && HAVE_DECL_ETH_P_QINQ1)
+  XLAT(ETH_P_QINQ1),
+#endif
+#if defined(ETH_P_QINQ2) || (defined(HAVE_DECL_ETH_P_QINQ2) && HAVE_DECL_ETH_P_QINQ2)
+  XLAT(ETH_P_QINQ2),
+#endif
+#if defined(ETH_P_QINQ3) || (defined(HAVE_DECL_ETH_P_QINQ3) && HAVE_DECL_ETH_P_QINQ3)
+  XLAT(ETH_P_QINQ3),
+#endif
+#if defined(ETH_P_EDSA) || (defined(HAVE_DECL_ETH_P_EDSA) && HAVE_DECL_ETH_P_EDSA)
+  XLAT(ETH_P_EDSA),
+#endif
+#if defined(ETH_P_AF_IUCV) || (defined(HAVE_DECL_ETH_P_AF_IUCV) && HAVE_DECL_ETH_P_AF_IUCV)
+  XLAT(ETH_P_AF_IUCV),
+#endif
+#if defined(ETH_P_802_3_MIN) || (defined(HAVE_DECL_ETH_P_802_3_MIN) && HAVE_DECL_ETH_P_802_3_MIN)
+  XLAT(ETH_P_802_3_MIN),
+#endif
+#if defined(ETH_P_802_3) || (defined(HAVE_DECL_ETH_P_802_3) && HAVE_DECL_ETH_P_802_3)
+  XLAT(ETH_P_802_3),
+#endif
+#if defined(ETH_P_AX25) || (defined(HAVE_DECL_ETH_P_AX25) && HAVE_DECL_ETH_P_AX25)
+  XLAT(ETH_P_AX25),
+#endif
+#if defined(ETH_P_ALL) || (defined(HAVE_DECL_ETH_P_ALL) && HAVE_DECL_ETH_P_ALL)
+  XLAT(ETH_P_ALL),
+#endif
+#if defined(ETH_P_802_2) || (defined(HAVE_DECL_ETH_P_802_2) && HAVE_DECL_ETH_P_802_2)
+  XLAT(ETH_P_802_2),
+#endif
+#if defined(ETH_P_SNAP) || (defined(HAVE_DECL_ETH_P_SNAP) && HAVE_DECL_ETH_P_SNAP)
+  XLAT(ETH_P_SNAP),
+#endif
+#if defined(ETH_P_DDCMP) || (defined(HAVE_DECL_ETH_P_DDCMP) && HAVE_DECL_ETH_P_DDCMP)
+  XLAT(ETH_P_DDCMP),
+#endif
+#if defined(ETH_P_WAN_PPP) || (defined(HAVE_DECL_ETH_P_WAN_PPP) && HAVE_DECL_ETH_P_WAN_PPP)
+  XLAT(ETH_P_WAN_PPP),
+#endif
+#if defined(ETH_P_PPP_MP) || (defined(HAVE_DECL_ETH_P_PPP_MP) && HAVE_DECL_ETH_P_PPP_MP)
+  XLAT(ETH_P_PPP_MP),
+#endif
+#if defined(ETH_P_LOCALTALK) || (defined(HAVE_DECL_ETH_P_LOCALTALK) && HAVE_DECL_ETH_P_LOCALTALK)
+  XLAT(ETH_P_LOCALTALK),
+#endif
+#if defined(ETH_P_CAN) || (defined(HAVE_DECL_ETH_P_CAN) && HAVE_DECL_ETH_P_CAN)
+  XLAT(ETH_P_CAN),
+#endif
+#if defined(ETH_P_CANFD) || (defined(HAVE_DECL_ETH_P_CANFD) && HAVE_DECL_ETH_P_CANFD)
+  XLAT(ETH_P_CANFD),
+#endif
+#if defined(ETH_P_PPPTALK) || (defined(HAVE_DECL_ETH_P_PPPTALK) && HAVE_DECL_ETH_P_PPPTALK)
+  XLAT(ETH_P_PPPTALK),
+#endif
+#if defined(ETH_P_TR_802_2) || (defined(HAVE_DECL_ETH_P_TR_802_2) && HAVE_DECL_ETH_P_TR_802_2)
+  XLAT(ETH_P_TR_802_2),
+#endif
+#if defined(ETH_P_MOBITEX) || (defined(HAVE_DECL_ETH_P_MOBITEX) && HAVE_DECL_ETH_P_MOBITEX)
+  XLAT(ETH_P_MOBITEX),
+#endif
+#if defined(ETH_P_CONTROL) || (defined(HAVE_DECL_ETH_P_CONTROL) && HAVE_DECL_ETH_P_CONTROL)
+  XLAT(ETH_P_CONTROL),
+#endif
+#if defined(ETH_P_IRDA) || (defined(HAVE_DECL_ETH_P_IRDA) && HAVE_DECL_ETH_P_IRDA)
+  XLAT(ETH_P_IRDA),
+#endif
+#if defined(ETH_P_ECONET) || (defined(HAVE_DECL_ETH_P_ECONET) && HAVE_DECL_ETH_P_ECONET)
+  XLAT(ETH_P_ECONET),
+#endif
+#if defined(ETH_P_HDLC) || (defined(HAVE_DECL_ETH_P_HDLC) && HAVE_DECL_ETH_P_HDLC)
+  XLAT(ETH_P_HDLC),
+#endif
+#if defined(ETH_P_ARCNET) || (defined(HAVE_DECL_ETH_P_ARCNET) && HAVE_DECL_ETH_P_ARCNET)
+  XLAT(ETH_P_ARCNET),
+#endif
+#if defined(ETH_P_DSA) || (defined(HAVE_DECL_ETH_P_DSA) && HAVE_DECL_ETH_P_DSA)
+  XLAT(ETH_P_DSA),
+#endif
+#if defined(ETH_P_TRAILER) || (defined(HAVE_DECL_ETH_P_TRAILER) && HAVE_DECL_ETH_P_TRAILER)
+  XLAT(ETH_P_TRAILER),
+#endif
+#if defined(ETH_P_PHONET) || (defined(HAVE_DECL_ETH_P_PHONET) && HAVE_DECL_ETH_P_PHONET)
+  XLAT(ETH_P_PHONET),
+#endif
+#if defined(ETH_P_IEEE802154) || (defined(HAVE_DECL_ETH_P_IEEE802154) && HAVE_DECL_ETH_P_IEEE802154)
+  XLAT(ETH_P_IEEE802154),
+#endif
+#if defined(ETH_P_CAIF) || (defined(HAVE_DECL_ETH_P_CAIF) && HAVE_DECL_ETH_P_CAIF)
+  XLAT(ETH_P_CAIF),
+#endif
+#if defined(ETH_P_XDSA) || (defined(HAVE_DECL_ETH_P_XDSA) && HAVE_DECL_ETH_P_XDSA)
+  XLAT(ETH_P_XDSA),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ethernet_protocols.in b/strace/xlat/ethernet_protocols.in
new file mode 100644
index 0000000..df078ba
--- /dev/null
+++ b/strace/xlat/ethernet_protocols.in
@@ -0,0 +1,83 @@
+ETH_P_LOOP
+ETH_P_PUP
+ETH_P_PUPAT
+ETH_P_TSN
+ETH_P_IP
+ETH_P_X25
+ETH_P_ARP
+ETH_P_BPQ
+ETH_P_IEEEPUP
+ETH_P_IEEEPUPAT
+ETH_P_BATMAN
+ETH_P_DEC
+ETH_P_DNA_DL
+ETH_P_DNA_RC
+ETH_P_DNA_RT
+ETH_P_LAT
+ETH_P_DIAG
+ETH_P_CUST
+ETH_P_SCA
+ETH_P_TEB
+ETH_P_RARP
+ETH_P_ATALK
+ETH_P_AARP
+ETH_P_8021Q
+ETH_P_IPX
+ETH_P_IPV6
+ETH_P_PAUSE
+ETH_P_SLOW
+ETH_P_WCCP
+ETH_P_MPLS_UC
+ETH_P_MPLS_MC
+ETH_P_ATMMPOA
+ETH_P_PPP_DISC
+ETH_P_PPP_SES
+ETH_P_LINK_CTL
+ETH_P_ATMFATE
+ETH_P_PAE
+ETH_P_AOE
+ETH_P_8021AD
+ETH_P_802_EX1
+ETH_P_TIPC
+ETH_P_MACSEC
+ETH_P_8021AH
+ETH_P_MVRP
+ETH_P_1588
+ETH_P_PRP
+ETH_P_FCOE
+ETH_P_TDLS
+ETH_P_FIP
+ETH_P_80221
+ETH_P_HSR
+ETH_P_LOOPBACK
+ETH_P_QINQ1
+ETH_P_QINQ2
+ETH_P_QINQ3
+ETH_P_EDSA
+ETH_P_AF_IUCV
+ETH_P_802_3_MIN
+ETH_P_802_3
+ETH_P_AX25
+ETH_P_ALL
+ETH_P_802_2
+ETH_P_SNAP
+ETH_P_DDCMP
+ETH_P_WAN_PPP
+ETH_P_PPP_MP
+ETH_P_LOCALTALK
+ETH_P_CAN
+ETH_P_CANFD
+ETH_P_PPPTALK
+ETH_P_TR_802_2
+ETH_P_MOBITEX
+ETH_P_CONTROL
+ETH_P_IRDA
+ETH_P_ECONET
+ETH_P_HDLC
+ETH_P_ARCNET
+ETH_P_DSA
+ETH_P_TRAILER
+ETH_P_PHONET
+ETH_P_IEEE802154
+ETH_P_CAIF
+ETH_P_XDSA
diff --git a/strace/xlat/evdev_abs.h b/strace/xlat/evdev_abs.h
new file mode 100644
index 0000000..3edd1f3
--- /dev/null
+++ b/strace/xlat/evdev_abs.h
@@ -0,0 +1,132 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_abs.in; do not edit. */
+
+#ifndef IN_MPERS
+
+const struct xlat evdev_abs[] = {
+#if defined(ABS_X) || (defined(HAVE_DECL_ABS_X) && HAVE_DECL_ABS_X)
+  XLAT(ABS_X),
+#endif
+#if defined(ABS_Y) || (defined(HAVE_DECL_ABS_Y) && HAVE_DECL_ABS_Y)
+  XLAT(ABS_Y),
+#endif
+#if defined(ABS_Z) || (defined(HAVE_DECL_ABS_Z) && HAVE_DECL_ABS_Z)
+  XLAT(ABS_Z),
+#endif
+#if defined(ABS_RX) || (defined(HAVE_DECL_ABS_RX) && HAVE_DECL_ABS_RX)
+  XLAT(ABS_RX),
+#endif
+#if defined(ABS_RY) || (defined(HAVE_DECL_ABS_RY) && HAVE_DECL_ABS_RY)
+  XLAT(ABS_RY),
+#endif
+#if defined(ABS_RZ) || (defined(HAVE_DECL_ABS_RZ) && HAVE_DECL_ABS_RZ)
+  XLAT(ABS_RZ),
+#endif
+#if defined(ABS_THROTTLE) || (defined(HAVE_DECL_ABS_THROTTLE) && HAVE_DECL_ABS_THROTTLE)
+  XLAT(ABS_THROTTLE),
+#endif
+#if defined(ABS_RUDDER) || (defined(HAVE_DECL_ABS_RUDDER) && HAVE_DECL_ABS_RUDDER)
+  XLAT(ABS_RUDDER),
+#endif
+#if defined(ABS_WHEEL) || (defined(HAVE_DECL_ABS_WHEEL) && HAVE_DECL_ABS_WHEEL)
+  XLAT(ABS_WHEEL),
+#endif
+#if defined(ABS_GAS) || (defined(HAVE_DECL_ABS_GAS) && HAVE_DECL_ABS_GAS)
+  XLAT(ABS_GAS),
+#endif
+#if defined(ABS_BRAKE) || (defined(HAVE_DECL_ABS_BRAKE) && HAVE_DECL_ABS_BRAKE)
+  XLAT(ABS_BRAKE),
+#endif
+#if defined(ABS_HAT0X) || (defined(HAVE_DECL_ABS_HAT0X) && HAVE_DECL_ABS_HAT0X)
+  XLAT(ABS_HAT0X),
+#endif
+#if defined(ABS_HAT0Y) || (defined(HAVE_DECL_ABS_HAT0Y) && HAVE_DECL_ABS_HAT0Y)
+  XLAT(ABS_HAT0Y),
+#endif
+#if defined(ABS_HAT1X) || (defined(HAVE_DECL_ABS_HAT1X) && HAVE_DECL_ABS_HAT1X)
+  XLAT(ABS_HAT1X),
+#endif
+#if defined(ABS_HAT1Y) || (defined(HAVE_DECL_ABS_HAT1Y) && HAVE_DECL_ABS_HAT1Y)
+  XLAT(ABS_HAT1Y),
+#endif
+#if defined(ABS_HAT2X) || (defined(HAVE_DECL_ABS_HAT2X) && HAVE_DECL_ABS_HAT2X)
+  XLAT(ABS_HAT2X),
+#endif
+#if defined(ABS_HAT2Y) || (defined(HAVE_DECL_ABS_HAT2Y) && HAVE_DECL_ABS_HAT2Y)
+  XLAT(ABS_HAT2Y),
+#endif
+#if defined(ABS_HAT3X) || (defined(HAVE_DECL_ABS_HAT3X) && HAVE_DECL_ABS_HAT3X)
+  XLAT(ABS_HAT3X),
+#endif
+#if defined(ABS_HAT3Y) || (defined(HAVE_DECL_ABS_HAT3Y) && HAVE_DECL_ABS_HAT3Y)
+  XLAT(ABS_HAT3Y),
+#endif
+#if defined(ABS_PRESSURE) || (defined(HAVE_DECL_ABS_PRESSURE) && HAVE_DECL_ABS_PRESSURE)
+  XLAT(ABS_PRESSURE),
+#endif
+#if defined(ABS_DISTANCE) || (defined(HAVE_DECL_ABS_DISTANCE) && HAVE_DECL_ABS_DISTANCE)
+  XLAT(ABS_DISTANCE),
+#endif
+#if defined(ABS_TILT_X) || (defined(HAVE_DECL_ABS_TILT_X) && HAVE_DECL_ABS_TILT_X)
+  XLAT(ABS_TILT_X),
+#endif
+#if defined(ABS_TILT_Y) || (defined(HAVE_DECL_ABS_TILT_Y) && HAVE_DECL_ABS_TILT_Y)
+  XLAT(ABS_TILT_Y),
+#endif
+#if defined(ABS_TOOL_WIDTH) || (defined(HAVE_DECL_ABS_TOOL_WIDTH) && HAVE_DECL_ABS_TOOL_WIDTH)
+  XLAT(ABS_TOOL_WIDTH),
+#endif
+#if defined(ABS_VOLUME) || (defined(HAVE_DECL_ABS_VOLUME) && HAVE_DECL_ABS_VOLUME)
+  XLAT(ABS_VOLUME),
+#endif
+#if defined(ABS_MISC) || (defined(HAVE_DECL_ABS_MISC) && HAVE_DECL_ABS_MISC)
+  XLAT(ABS_MISC),
+#endif
+#if defined(ABS_MT_SLOT) || (defined(HAVE_DECL_ABS_MT_SLOT) && HAVE_DECL_ABS_MT_SLOT)
+  XLAT(ABS_MT_SLOT),
+#endif
+#if defined(ABS_MT_TOUCH_MAJOR) || (defined(HAVE_DECL_ABS_MT_TOUCH_MAJOR) && HAVE_DECL_ABS_MT_TOUCH_MAJOR)
+  XLAT(ABS_MT_TOUCH_MAJOR),
+#endif
+#if defined(ABS_MT_TOUCH_MINOR) || (defined(HAVE_DECL_ABS_MT_TOUCH_MINOR) && HAVE_DECL_ABS_MT_TOUCH_MINOR)
+  XLAT(ABS_MT_TOUCH_MINOR),
+#endif
+#if defined(ABS_MT_WIDTH_MAJOR) || (defined(HAVE_DECL_ABS_MT_WIDTH_MAJOR) && HAVE_DECL_ABS_MT_WIDTH_MAJOR)
+  XLAT(ABS_MT_WIDTH_MAJOR),
+#endif
+#if defined(ABS_MT_WIDTH_MINOR) || (defined(HAVE_DECL_ABS_MT_WIDTH_MINOR) && HAVE_DECL_ABS_MT_WIDTH_MINOR)
+  XLAT(ABS_MT_WIDTH_MINOR),
+#endif
+#if defined(ABS_MT_ORIENTATION) || (defined(HAVE_DECL_ABS_MT_ORIENTATION) && HAVE_DECL_ABS_MT_ORIENTATION)
+  XLAT(ABS_MT_ORIENTATION),
+#endif
+#if defined(ABS_MT_POSITION_X) || (defined(HAVE_DECL_ABS_MT_POSITION_X) && HAVE_DECL_ABS_MT_POSITION_X)
+  XLAT(ABS_MT_POSITION_X),
+#endif
+#if defined(ABS_MT_POSITION_Y) || (defined(HAVE_DECL_ABS_MT_POSITION_Y) && HAVE_DECL_ABS_MT_POSITION_Y)
+  XLAT(ABS_MT_POSITION_Y),
+#endif
+#if defined(ABS_MT_TOOL_TYPE) || (defined(HAVE_DECL_ABS_MT_TOOL_TYPE) && HAVE_DECL_ABS_MT_TOOL_TYPE)
+  XLAT(ABS_MT_TOOL_TYPE),
+#endif
+#if defined(ABS_MT_BLOB_ID) || (defined(HAVE_DECL_ABS_MT_BLOB_ID) && HAVE_DECL_ABS_MT_BLOB_ID)
+  XLAT(ABS_MT_BLOB_ID),
+#endif
+#if defined(ABS_MT_TRACKING_ID) || (defined(HAVE_DECL_ABS_MT_TRACKING_ID) && HAVE_DECL_ABS_MT_TRACKING_ID)
+  XLAT(ABS_MT_TRACKING_ID),
+#endif
+#if defined(ABS_MT_PRESSURE) || (defined(HAVE_DECL_ABS_MT_PRESSURE) && HAVE_DECL_ABS_MT_PRESSURE)
+  XLAT(ABS_MT_PRESSURE),
+#endif
+#if defined(ABS_MT_DISTANCE) || (defined(HAVE_DECL_ABS_MT_DISTANCE) && HAVE_DECL_ABS_MT_DISTANCE)
+  XLAT(ABS_MT_DISTANCE),
+#endif
+#if defined(ABS_MT_TOOL_X) || (defined(HAVE_DECL_ABS_MT_TOOL_X) && HAVE_DECL_ABS_MT_TOOL_X)
+  XLAT(ABS_MT_TOOL_X),
+#endif
+#if defined(ABS_MT_TOOL_Y) || (defined(HAVE_DECL_ABS_MT_TOOL_Y) && HAVE_DECL_ABS_MT_TOOL_Y)
+  XLAT(ABS_MT_TOOL_Y),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_abs.in b/strace/xlat/evdev_abs.in
new file mode 100644
index 0000000..ec8c2f4
--- /dev/null
+++ b/strace/xlat/evdev_abs.in
@@ -0,0 +1,41 @@
+ABS_X
+ABS_Y
+ABS_Z
+ABS_RX
+ABS_RY
+ABS_RZ
+ABS_THROTTLE
+ABS_RUDDER
+ABS_WHEEL
+ABS_GAS
+ABS_BRAKE
+ABS_HAT0X
+ABS_HAT0Y
+ABS_HAT1X
+ABS_HAT1Y
+ABS_HAT2X
+ABS_HAT2Y
+ABS_HAT3X
+ABS_HAT3Y
+ABS_PRESSURE
+ABS_DISTANCE
+ABS_TILT_X
+ABS_TILT_Y
+ABS_TOOL_WIDTH
+ABS_VOLUME
+ABS_MISC
+ABS_MT_SLOT
+ABS_MT_TOUCH_MAJOR
+ABS_MT_TOUCH_MINOR
+ABS_MT_WIDTH_MAJOR
+ABS_MT_WIDTH_MINOR
+ABS_MT_ORIENTATION
+ABS_MT_POSITION_X
+ABS_MT_POSITION_Y
+ABS_MT_TOOL_TYPE
+ABS_MT_BLOB_ID
+ABS_MT_TRACKING_ID
+ABS_MT_PRESSURE
+ABS_MT_DISTANCE
+ABS_MT_TOOL_X
+ABS_MT_TOOL_Y
diff --git a/strace/xlat/evdev_autorepeat.h b/strace/xlat/evdev_autorepeat.h
new file mode 100644
index 0000000..67f1ce6
--- /dev/null
+++ b/strace/xlat/evdev_autorepeat.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_autorepeat.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_autorepeat[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_autorepeat[] = {
+#if defined(REP_DELAY) || (defined(HAVE_DECL_REP_DELAY) && HAVE_DECL_REP_DELAY)
+  XLAT(REP_DELAY),
+#endif
+#if defined(REP_PERIOD) || (defined(HAVE_DECL_REP_PERIOD) && HAVE_DECL_REP_PERIOD)
+  XLAT(REP_PERIOD),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_autorepeat.in b/strace/xlat/evdev_autorepeat.in
new file mode 100644
index 0000000..ac8b8fb
--- /dev/null
+++ b/strace/xlat/evdev_autorepeat.in
@@ -0,0 +1,2 @@
+REP_DELAY
+REP_PERIOD
diff --git a/strace/xlat/evdev_ev.h b/strace/xlat/evdev_ev.h
new file mode 100644
index 0000000..1d49445
--- /dev/null
+++ b/strace/xlat/evdev_ev.h
@@ -0,0 +1,50 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_ev.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat evdev_ev in mpers mode
+
+#else
+
+static
+const struct xlat evdev_ev[] = {
+#if defined(EV_SYN) || (defined(HAVE_DECL_EV_SYN) && HAVE_DECL_EV_SYN)
+  XLAT(EV_SYN),
+#endif
+#if defined(EV_KEY) || (defined(HAVE_DECL_EV_KEY) && HAVE_DECL_EV_KEY)
+  XLAT(EV_KEY),
+#endif
+#if defined(EV_REL) || (defined(HAVE_DECL_EV_REL) && HAVE_DECL_EV_REL)
+  XLAT(EV_REL),
+#endif
+#if defined(EV_ABS) || (defined(HAVE_DECL_EV_ABS) && HAVE_DECL_EV_ABS)
+  XLAT(EV_ABS),
+#endif
+#if defined(EV_MSC) || (defined(HAVE_DECL_EV_MSC) && HAVE_DECL_EV_MSC)
+  XLAT(EV_MSC),
+#endif
+#if defined(EV_SW) || (defined(HAVE_DECL_EV_SW) && HAVE_DECL_EV_SW)
+  XLAT(EV_SW),
+#endif
+#if defined(EV_LED) || (defined(HAVE_DECL_EV_LED) && HAVE_DECL_EV_LED)
+  XLAT(EV_LED),
+#endif
+#if defined(EV_SND) || (defined(HAVE_DECL_EV_SND) && HAVE_DECL_EV_SND)
+  XLAT(EV_SND),
+#endif
+#if defined(EV_REP) || (defined(HAVE_DECL_EV_REP) && HAVE_DECL_EV_REP)
+  XLAT(EV_REP),
+#endif
+#if defined(EV_FF) || (defined(HAVE_DECL_EV_FF) && HAVE_DECL_EV_FF)
+  XLAT(EV_FF),
+#endif
+#if defined(EV_PWR) || (defined(HAVE_DECL_EV_PWR) && HAVE_DECL_EV_PWR)
+  XLAT(EV_PWR),
+#endif
+#if defined(EV_FF_STATUS) || (defined(HAVE_DECL_EV_FF_STATUS) && HAVE_DECL_EV_FF_STATUS)
+  XLAT(EV_FF_STATUS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_ev.in b/strace/xlat/evdev_ev.in
new file mode 100644
index 0000000..0974b59
--- /dev/null
+++ b/strace/xlat/evdev_ev.in
@@ -0,0 +1,12 @@
+EV_SYN
+EV_KEY
+EV_REL
+EV_ABS
+EV_MSC
+EV_SW
+EV_LED
+EV_SND
+EV_REP
+EV_FF
+EV_PWR
+EV_FF_STATUS
diff --git a/strace/xlat/evdev_ff_status.h b/strace/xlat/evdev_ff_status.h
new file mode 100644
index 0000000..2313d1a
--- /dev/null
+++ b/strace/xlat/evdev_ff_status.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_ff_status.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_ff_status[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_ff_status[] = {
+#if defined(FF_STATUS_STOPPED) || (defined(HAVE_DECL_FF_STATUS_STOPPED) && HAVE_DECL_FF_STATUS_STOPPED)
+  XLAT(FF_STATUS_STOPPED),
+#endif
+#if defined(FF_STATUS_PLAYING) || (defined(HAVE_DECL_FF_STATUS_PLAYING) && HAVE_DECL_FF_STATUS_PLAYING)
+  XLAT(FF_STATUS_PLAYING),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_ff_status.in b/strace/xlat/evdev_ff_status.in
new file mode 100644
index 0000000..3f88710
--- /dev/null
+++ b/strace/xlat/evdev_ff_status.in
@@ -0,0 +1,2 @@
+FF_STATUS_STOPPED
+FF_STATUS_PLAYING
diff --git a/strace/xlat/evdev_ff_types.h b/strace/xlat/evdev_ff_types.h
new file mode 100644
index 0000000..2608bb1
--- /dev/null
+++ b/strace/xlat/evdev_ff_types.h
@@ -0,0 +1,64 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_ff_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_ff_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_ff_types[] = {
+#if defined(FF_RUMBLE) || (defined(HAVE_DECL_FF_RUMBLE) && HAVE_DECL_FF_RUMBLE)
+  XLAT(FF_RUMBLE),
+#endif
+#if defined(FF_PERIODIC) || (defined(HAVE_DECL_FF_PERIODIC) && HAVE_DECL_FF_PERIODIC)
+  XLAT(FF_PERIODIC),
+#endif
+#if defined(FF_CONSTANT) || (defined(HAVE_DECL_FF_CONSTANT) && HAVE_DECL_FF_CONSTANT)
+  XLAT(FF_CONSTANT),
+#endif
+#if defined(FF_SPRING) || (defined(HAVE_DECL_FF_SPRING) && HAVE_DECL_FF_SPRING)
+  XLAT(FF_SPRING),
+#endif
+#if defined(FF_FRICTION) || (defined(HAVE_DECL_FF_FRICTION) && HAVE_DECL_FF_FRICTION)
+  XLAT(FF_FRICTION),
+#endif
+#if defined(FF_DAMPER) || (defined(HAVE_DECL_FF_DAMPER) && HAVE_DECL_FF_DAMPER)
+  XLAT(FF_DAMPER),
+#endif
+#if defined(FF_INERTIA) || (defined(HAVE_DECL_FF_INERTIA) && HAVE_DECL_FF_INERTIA)
+  XLAT(FF_INERTIA),
+#endif
+#if defined(FF_RAMP) || (defined(HAVE_DECL_FF_RAMP) && HAVE_DECL_FF_RAMP)
+  XLAT(FF_RAMP),
+#endif
+#if defined(FF_SQUARE) || (defined(HAVE_DECL_FF_SQUARE) && HAVE_DECL_FF_SQUARE)
+  XLAT(FF_SQUARE),
+#endif
+#if defined(FF_TRIANGLE) || (defined(HAVE_DECL_FF_TRIANGLE) && HAVE_DECL_FF_TRIANGLE)
+  XLAT(FF_TRIANGLE),
+#endif
+#if defined(FF_SINE) || (defined(HAVE_DECL_FF_SINE) && HAVE_DECL_FF_SINE)
+  XLAT(FF_SINE),
+#endif
+#if defined(FF_SAW_UP) || (defined(HAVE_DECL_FF_SAW_UP) && HAVE_DECL_FF_SAW_UP)
+  XLAT(FF_SAW_UP),
+#endif
+#if defined(FF_SAW_DOWN) || (defined(HAVE_DECL_FF_SAW_DOWN) && HAVE_DECL_FF_SAW_DOWN)
+  XLAT(FF_SAW_DOWN),
+#endif
+#if defined(FF_CUSTOM) || (defined(HAVE_DECL_FF_CUSTOM) && HAVE_DECL_FF_CUSTOM)
+  XLAT(FF_CUSTOM),
+#endif
+#if defined(FF_GAIN) || (defined(HAVE_DECL_FF_GAIN) && HAVE_DECL_FF_GAIN)
+  XLAT(FF_GAIN),
+#endif
+#if defined(FF_AUTOCENTER) || (defined(HAVE_DECL_FF_AUTOCENTER) && HAVE_DECL_FF_AUTOCENTER)
+  XLAT(FF_AUTOCENTER),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_ff_types.in b/strace/xlat/evdev_ff_types.in
new file mode 100644
index 0000000..c6714f8
--- /dev/null
+++ b/strace/xlat/evdev_ff_types.in
@@ -0,0 +1,16 @@
+FF_RUMBLE
+FF_PERIODIC
+FF_CONSTANT
+FF_SPRING
+FF_FRICTION
+FF_DAMPER
+FF_INERTIA
+FF_RAMP
+FF_SQUARE
+FF_TRIANGLE
+FF_SINE
+FF_SAW_UP
+FF_SAW_DOWN
+FF_CUSTOM
+FF_GAIN
+FF_AUTOCENTER
diff --git a/strace/xlat/evdev_keycode.h b/strace/xlat/evdev_keycode.h
new file mode 100644
index 0000000..c4efd2c
--- /dev/null
+++ b/strace/xlat/evdev_keycode.h
@@ -0,0 +1,1721 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_keycode.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_keycode[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_keycode[] = {
+#if defined(KEY_RESERVED) || (defined(HAVE_DECL_KEY_RESERVED) && HAVE_DECL_KEY_RESERVED)
+  XLAT(KEY_RESERVED),
+#endif
+#if defined(KEY_ESC) || (defined(HAVE_DECL_KEY_ESC) && HAVE_DECL_KEY_ESC)
+  XLAT(KEY_ESC),
+#endif
+#if defined(KEY_1) || (defined(HAVE_DECL_KEY_1) && HAVE_DECL_KEY_1)
+  XLAT(KEY_1),
+#endif
+#if defined(KEY_2) || (defined(HAVE_DECL_KEY_2) && HAVE_DECL_KEY_2)
+  XLAT(KEY_2),
+#endif
+#if defined(KEY_3) || (defined(HAVE_DECL_KEY_3) && HAVE_DECL_KEY_3)
+  XLAT(KEY_3),
+#endif
+#if defined(KEY_4) || (defined(HAVE_DECL_KEY_4) && HAVE_DECL_KEY_4)
+  XLAT(KEY_4),
+#endif
+#if defined(KEY_5) || (defined(HAVE_DECL_KEY_5) && HAVE_DECL_KEY_5)
+  XLAT(KEY_5),
+#endif
+#if defined(KEY_6) || (defined(HAVE_DECL_KEY_6) && HAVE_DECL_KEY_6)
+  XLAT(KEY_6),
+#endif
+#if defined(KEY_7) || (defined(HAVE_DECL_KEY_7) && HAVE_DECL_KEY_7)
+  XLAT(KEY_7),
+#endif
+#if defined(KEY_8) || (defined(HAVE_DECL_KEY_8) && HAVE_DECL_KEY_8)
+  XLAT(KEY_8),
+#endif
+#if defined(KEY_9) || (defined(HAVE_DECL_KEY_9) && HAVE_DECL_KEY_9)
+  XLAT(KEY_9),
+#endif
+#if defined(KEY_0) || (defined(HAVE_DECL_KEY_0) && HAVE_DECL_KEY_0)
+  XLAT(KEY_0),
+#endif
+#if defined(KEY_MINUS) || (defined(HAVE_DECL_KEY_MINUS) && HAVE_DECL_KEY_MINUS)
+  XLAT(KEY_MINUS),
+#endif
+#if defined(KEY_EQUAL) || (defined(HAVE_DECL_KEY_EQUAL) && HAVE_DECL_KEY_EQUAL)
+  XLAT(KEY_EQUAL),
+#endif
+#if defined(KEY_BACKSPACE) || (defined(HAVE_DECL_KEY_BACKSPACE) && HAVE_DECL_KEY_BACKSPACE)
+  XLAT(KEY_BACKSPACE),
+#endif
+#if defined(KEY_TAB) || (defined(HAVE_DECL_KEY_TAB) && HAVE_DECL_KEY_TAB)
+  XLAT(KEY_TAB),
+#endif
+#if defined(KEY_Q) || (defined(HAVE_DECL_KEY_Q) && HAVE_DECL_KEY_Q)
+  XLAT(KEY_Q),
+#endif
+#if defined(KEY_W) || (defined(HAVE_DECL_KEY_W) && HAVE_DECL_KEY_W)
+  XLAT(KEY_W),
+#endif
+#if defined(KEY_E) || (defined(HAVE_DECL_KEY_E) && HAVE_DECL_KEY_E)
+  XLAT(KEY_E),
+#endif
+#if defined(KEY_R) || (defined(HAVE_DECL_KEY_R) && HAVE_DECL_KEY_R)
+  XLAT(KEY_R),
+#endif
+#if defined(KEY_T) || (defined(HAVE_DECL_KEY_T) && HAVE_DECL_KEY_T)
+  XLAT(KEY_T),
+#endif
+#if defined(KEY_Y) || (defined(HAVE_DECL_KEY_Y) && HAVE_DECL_KEY_Y)
+  XLAT(KEY_Y),
+#endif
+#if defined(KEY_U) || (defined(HAVE_DECL_KEY_U) && HAVE_DECL_KEY_U)
+  XLAT(KEY_U),
+#endif
+#if defined(KEY_I) || (defined(HAVE_DECL_KEY_I) && HAVE_DECL_KEY_I)
+  XLAT(KEY_I),
+#endif
+#if defined(KEY_O) || (defined(HAVE_DECL_KEY_O) && HAVE_DECL_KEY_O)
+  XLAT(KEY_O),
+#endif
+#if defined(KEY_P) || (defined(HAVE_DECL_KEY_P) && HAVE_DECL_KEY_P)
+  XLAT(KEY_P),
+#endif
+#if defined(KEY_LEFTBRACE) || (defined(HAVE_DECL_KEY_LEFTBRACE) && HAVE_DECL_KEY_LEFTBRACE)
+  XLAT(KEY_LEFTBRACE),
+#endif
+#if defined(KEY_RIGHTBRACE) || (defined(HAVE_DECL_KEY_RIGHTBRACE) && HAVE_DECL_KEY_RIGHTBRACE)
+  XLAT(KEY_RIGHTBRACE),
+#endif
+#if defined(KEY_ENTER) || (defined(HAVE_DECL_KEY_ENTER) && HAVE_DECL_KEY_ENTER)
+  XLAT(KEY_ENTER),
+#endif
+#if defined(KEY_LEFTCTRL) || (defined(HAVE_DECL_KEY_LEFTCTRL) && HAVE_DECL_KEY_LEFTCTRL)
+  XLAT(KEY_LEFTCTRL),
+#endif
+#if defined(KEY_A) || (defined(HAVE_DECL_KEY_A) && HAVE_DECL_KEY_A)
+  XLAT(KEY_A),
+#endif
+#if defined(KEY_S) || (defined(HAVE_DECL_KEY_S) && HAVE_DECL_KEY_S)
+  XLAT(KEY_S),
+#endif
+#if defined(KEY_D) || (defined(HAVE_DECL_KEY_D) && HAVE_DECL_KEY_D)
+  XLAT(KEY_D),
+#endif
+#if defined(KEY_F) || (defined(HAVE_DECL_KEY_F) && HAVE_DECL_KEY_F)
+  XLAT(KEY_F),
+#endif
+#if defined(KEY_G) || (defined(HAVE_DECL_KEY_G) && HAVE_DECL_KEY_G)
+  XLAT(KEY_G),
+#endif
+#if defined(KEY_H) || (defined(HAVE_DECL_KEY_H) && HAVE_DECL_KEY_H)
+  XLAT(KEY_H),
+#endif
+#if defined(KEY_J) || (defined(HAVE_DECL_KEY_J) && HAVE_DECL_KEY_J)
+  XLAT(KEY_J),
+#endif
+#if defined(KEY_K) || (defined(HAVE_DECL_KEY_K) && HAVE_DECL_KEY_K)
+  XLAT(KEY_K),
+#endif
+#if defined(KEY_L) || (defined(HAVE_DECL_KEY_L) && HAVE_DECL_KEY_L)
+  XLAT(KEY_L),
+#endif
+#if defined(KEY_SEMICOLON) || (defined(HAVE_DECL_KEY_SEMICOLON) && HAVE_DECL_KEY_SEMICOLON)
+  XLAT(KEY_SEMICOLON),
+#endif
+#if defined(KEY_APOSTROPHE) || (defined(HAVE_DECL_KEY_APOSTROPHE) && HAVE_DECL_KEY_APOSTROPHE)
+  XLAT(KEY_APOSTROPHE),
+#endif
+#if defined(KEY_GRAVE) || (defined(HAVE_DECL_KEY_GRAVE) && HAVE_DECL_KEY_GRAVE)
+  XLAT(KEY_GRAVE),
+#endif
+#if defined(KEY_LEFTSHIFT) || (defined(HAVE_DECL_KEY_LEFTSHIFT) && HAVE_DECL_KEY_LEFTSHIFT)
+  XLAT(KEY_LEFTSHIFT),
+#endif
+#if defined(KEY_BACKSLASH) || (defined(HAVE_DECL_KEY_BACKSLASH) && HAVE_DECL_KEY_BACKSLASH)
+  XLAT(KEY_BACKSLASH),
+#endif
+#if defined(KEY_Z) || (defined(HAVE_DECL_KEY_Z) && HAVE_DECL_KEY_Z)
+  XLAT(KEY_Z),
+#endif
+#if defined(KEY_X) || (defined(HAVE_DECL_KEY_X) && HAVE_DECL_KEY_X)
+  XLAT(KEY_X),
+#endif
+#if defined(KEY_C) || (defined(HAVE_DECL_KEY_C) && HAVE_DECL_KEY_C)
+  XLAT(KEY_C),
+#endif
+#if defined(KEY_V) || (defined(HAVE_DECL_KEY_V) && HAVE_DECL_KEY_V)
+  XLAT(KEY_V),
+#endif
+#if defined(KEY_B) || (defined(HAVE_DECL_KEY_B) && HAVE_DECL_KEY_B)
+  XLAT(KEY_B),
+#endif
+#if defined(KEY_N) || (defined(HAVE_DECL_KEY_N) && HAVE_DECL_KEY_N)
+  XLAT(KEY_N),
+#endif
+#if defined(KEY_M) || (defined(HAVE_DECL_KEY_M) && HAVE_DECL_KEY_M)
+  XLAT(KEY_M),
+#endif
+#if defined(KEY_COMMA) || (defined(HAVE_DECL_KEY_COMMA) && HAVE_DECL_KEY_COMMA)
+  XLAT(KEY_COMMA),
+#endif
+#if defined(KEY_DOT) || (defined(HAVE_DECL_KEY_DOT) && HAVE_DECL_KEY_DOT)
+  XLAT(KEY_DOT),
+#endif
+#if defined(KEY_SLASH) || (defined(HAVE_DECL_KEY_SLASH) && HAVE_DECL_KEY_SLASH)
+  XLAT(KEY_SLASH),
+#endif
+#if defined(KEY_RIGHTSHIFT) || (defined(HAVE_DECL_KEY_RIGHTSHIFT) && HAVE_DECL_KEY_RIGHTSHIFT)
+  XLAT(KEY_RIGHTSHIFT),
+#endif
+#if defined(KEY_KPASTERISK) || (defined(HAVE_DECL_KEY_KPASTERISK) && HAVE_DECL_KEY_KPASTERISK)
+  XLAT(KEY_KPASTERISK),
+#endif
+#if defined(KEY_LEFTALT) || (defined(HAVE_DECL_KEY_LEFTALT) && HAVE_DECL_KEY_LEFTALT)
+  XLAT(KEY_LEFTALT),
+#endif
+#if defined(KEY_SPACE) || (defined(HAVE_DECL_KEY_SPACE) && HAVE_DECL_KEY_SPACE)
+  XLAT(KEY_SPACE),
+#endif
+#if defined(KEY_CAPSLOCK) || (defined(HAVE_DECL_KEY_CAPSLOCK) && HAVE_DECL_KEY_CAPSLOCK)
+  XLAT(KEY_CAPSLOCK),
+#endif
+#if defined(KEY_F1) || (defined(HAVE_DECL_KEY_F1) && HAVE_DECL_KEY_F1)
+  XLAT(KEY_F1),
+#endif
+#if defined(KEY_F2) || (defined(HAVE_DECL_KEY_F2) && HAVE_DECL_KEY_F2)
+  XLAT(KEY_F2),
+#endif
+#if defined(KEY_F3) || (defined(HAVE_DECL_KEY_F3) && HAVE_DECL_KEY_F3)
+  XLAT(KEY_F3),
+#endif
+#if defined(KEY_F4) || (defined(HAVE_DECL_KEY_F4) && HAVE_DECL_KEY_F4)
+  XLAT(KEY_F4),
+#endif
+#if defined(KEY_F5) || (defined(HAVE_DECL_KEY_F5) && HAVE_DECL_KEY_F5)
+  XLAT(KEY_F5),
+#endif
+#if defined(KEY_F6) || (defined(HAVE_DECL_KEY_F6) && HAVE_DECL_KEY_F6)
+  XLAT(KEY_F6),
+#endif
+#if defined(KEY_F7) || (defined(HAVE_DECL_KEY_F7) && HAVE_DECL_KEY_F7)
+  XLAT(KEY_F7),
+#endif
+#if defined(KEY_F8) || (defined(HAVE_DECL_KEY_F8) && HAVE_DECL_KEY_F8)
+  XLAT(KEY_F8),
+#endif
+#if defined(KEY_F9) || (defined(HAVE_DECL_KEY_F9) && HAVE_DECL_KEY_F9)
+  XLAT(KEY_F9),
+#endif
+#if defined(KEY_F10) || (defined(HAVE_DECL_KEY_F10) && HAVE_DECL_KEY_F10)
+  XLAT(KEY_F10),
+#endif
+#if defined(KEY_NUMLOCK) || (defined(HAVE_DECL_KEY_NUMLOCK) && HAVE_DECL_KEY_NUMLOCK)
+  XLAT(KEY_NUMLOCK),
+#endif
+#if defined(KEY_SCROLLLOCK) || (defined(HAVE_DECL_KEY_SCROLLLOCK) && HAVE_DECL_KEY_SCROLLLOCK)
+  XLAT(KEY_SCROLLLOCK),
+#endif
+#if defined(KEY_KP7) || (defined(HAVE_DECL_KEY_KP7) && HAVE_DECL_KEY_KP7)
+  XLAT(KEY_KP7),
+#endif
+#if defined(KEY_KP8) || (defined(HAVE_DECL_KEY_KP8) && HAVE_DECL_KEY_KP8)
+  XLAT(KEY_KP8),
+#endif
+#if defined(KEY_KP9) || (defined(HAVE_DECL_KEY_KP9) && HAVE_DECL_KEY_KP9)
+  XLAT(KEY_KP9),
+#endif
+#if defined(KEY_KPMINUS) || (defined(HAVE_DECL_KEY_KPMINUS) && HAVE_DECL_KEY_KPMINUS)
+  XLAT(KEY_KPMINUS),
+#endif
+#if defined(KEY_KP4) || (defined(HAVE_DECL_KEY_KP4) && HAVE_DECL_KEY_KP4)
+  XLAT(KEY_KP4),
+#endif
+#if defined(KEY_KP5) || (defined(HAVE_DECL_KEY_KP5) && HAVE_DECL_KEY_KP5)
+  XLAT(KEY_KP5),
+#endif
+#if defined(KEY_KP6) || (defined(HAVE_DECL_KEY_KP6) && HAVE_DECL_KEY_KP6)
+  XLAT(KEY_KP6),
+#endif
+#if defined(KEY_KPPLUS) || (defined(HAVE_DECL_KEY_KPPLUS) && HAVE_DECL_KEY_KPPLUS)
+  XLAT(KEY_KPPLUS),
+#endif
+#if defined(KEY_KP1) || (defined(HAVE_DECL_KEY_KP1) && HAVE_DECL_KEY_KP1)
+  XLAT(KEY_KP1),
+#endif
+#if defined(KEY_KP2) || (defined(HAVE_DECL_KEY_KP2) && HAVE_DECL_KEY_KP2)
+  XLAT(KEY_KP2),
+#endif
+#if defined(KEY_KP3) || (defined(HAVE_DECL_KEY_KP3) && HAVE_DECL_KEY_KP3)
+  XLAT(KEY_KP3),
+#endif
+#if defined(KEY_KP0) || (defined(HAVE_DECL_KEY_KP0) && HAVE_DECL_KEY_KP0)
+  XLAT(KEY_KP0),
+#endif
+#if defined(KEY_KPDOT) || (defined(HAVE_DECL_KEY_KPDOT) && HAVE_DECL_KEY_KPDOT)
+  XLAT(KEY_KPDOT),
+#endif
+
+#if defined(KEY_ZENKAKUHANKAKU) || (defined(HAVE_DECL_KEY_ZENKAKUHANKAKU) && HAVE_DECL_KEY_ZENKAKUHANKAKU)
+  XLAT(KEY_ZENKAKUHANKAKU),
+#endif
+#if defined(KEY_102ND) || (defined(HAVE_DECL_KEY_102ND) && HAVE_DECL_KEY_102ND)
+  XLAT(KEY_102ND),
+#endif
+#if defined(KEY_F11) || (defined(HAVE_DECL_KEY_F11) && HAVE_DECL_KEY_F11)
+  XLAT(KEY_F11),
+#endif
+#if defined(KEY_F12) || (defined(HAVE_DECL_KEY_F12) && HAVE_DECL_KEY_F12)
+  XLAT(KEY_F12),
+#endif
+#if defined(KEY_RO) || (defined(HAVE_DECL_KEY_RO) && HAVE_DECL_KEY_RO)
+  XLAT(KEY_RO),
+#endif
+#if defined(KEY_KATAKANA) || (defined(HAVE_DECL_KEY_KATAKANA) && HAVE_DECL_KEY_KATAKANA)
+  XLAT(KEY_KATAKANA),
+#endif
+#if defined(KEY_HIRAGANA) || (defined(HAVE_DECL_KEY_HIRAGANA) && HAVE_DECL_KEY_HIRAGANA)
+  XLAT(KEY_HIRAGANA),
+#endif
+#if defined(KEY_HENKAN) || (defined(HAVE_DECL_KEY_HENKAN) && HAVE_DECL_KEY_HENKAN)
+  XLAT(KEY_HENKAN),
+#endif
+#if defined(KEY_KATAKANAHIRAGANA) || (defined(HAVE_DECL_KEY_KATAKANAHIRAGANA) && HAVE_DECL_KEY_KATAKANAHIRAGANA)
+  XLAT(KEY_KATAKANAHIRAGANA),
+#endif
+#if defined(KEY_MUHENKAN) || (defined(HAVE_DECL_KEY_MUHENKAN) && HAVE_DECL_KEY_MUHENKAN)
+  XLAT(KEY_MUHENKAN),
+#endif
+#if defined(KEY_KPJPCOMMA) || (defined(HAVE_DECL_KEY_KPJPCOMMA) && HAVE_DECL_KEY_KPJPCOMMA)
+  XLAT(KEY_KPJPCOMMA),
+#endif
+#if defined(KEY_KPENTER) || (defined(HAVE_DECL_KEY_KPENTER) && HAVE_DECL_KEY_KPENTER)
+  XLAT(KEY_KPENTER),
+#endif
+#if defined(KEY_RIGHTCTRL) || (defined(HAVE_DECL_KEY_RIGHTCTRL) && HAVE_DECL_KEY_RIGHTCTRL)
+  XLAT(KEY_RIGHTCTRL),
+#endif
+#if defined(KEY_KPSLASH) || (defined(HAVE_DECL_KEY_KPSLASH) && HAVE_DECL_KEY_KPSLASH)
+  XLAT(KEY_KPSLASH),
+#endif
+#if defined(KEY_SYSRQ) || (defined(HAVE_DECL_KEY_SYSRQ) && HAVE_DECL_KEY_SYSRQ)
+  XLAT(KEY_SYSRQ),
+#endif
+#if defined(KEY_RIGHTALT) || (defined(HAVE_DECL_KEY_RIGHTALT) && HAVE_DECL_KEY_RIGHTALT)
+  XLAT(KEY_RIGHTALT),
+#endif
+#if defined(KEY_LINEFEED) || (defined(HAVE_DECL_KEY_LINEFEED) && HAVE_DECL_KEY_LINEFEED)
+  XLAT(KEY_LINEFEED),
+#endif
+#if defined(KEY_HOME) || (defined(HAVE_DECL_KEY_HOME) && HAVE_DECL_KEY_HOME)
+  XLAT(KEY_HOME),
+#endif
+#if defined(KEY_UP) || (defined(HAVE_DECL_KEY_UP) && HAVE_DECL_KEY_UP)
+  XLAT(KEY_UP),
+#endif
+#if defined(KEY_PAGEUP) || (defined(HAVE_DECL_KEY_PAGEUP) && HAVE_DECL_KEY_PAGEUP)
+  XLAT(KEY_PAGEUP),
+#endif
+#if defined(KEY_LEFT) || (defined(HAVE_DECL_KEY_LEFT) && HAVE_DECL_KEY_LEFT)
+  XLAT(KEY_LEFT),
+#endif
+#if defined(KEY_RIGHT) || (defined(HAVE_DECL_KEY_RIGHT) && HAVE_DECL_KEY_RIGHT)
+  XLAT(KEY_RIGHT),
+#endif
+#if defined(KEY_END) || (defined(HAVE_DECL_KEY_END) && HAVE_DECL_KEY_END)
+  XLAT(KEY_END),
+#endif
+#if defined(KEY_DOWN) || (defined(HAVE_DECL_KEY_DOWN) && HAVE_DECL_KEY_DOWN)
+  XLAT(KEY_DOWN),
+#endif
+#if defined(KEY_PAGEDOWN) || (defined(HAVE_DECL_KEY_PAGEDOWN) && HAVE_DECL_KEY_PAGEDOWN)
+  XLAT(KEY_PAGEDOWN),
+#endif
+#if defined(KEY_INSERT) || (defined(HAVE_DECL_KEY_INSERT) && HAVE_DECL_KEY_INSERT)
+  XLAT(KEY_INSERT),
+#endif
+#if defined(KEY_DELETE) || (defined(HAVE_DECL_KEY_DELETE) && HAVE_DECL_KEY_DELETE)
+  XLAT(KEY_DELETE),
+#endif
+#if defined(KEY_MACRO) || (defined(HAVE_DECL_KEY_MACRO) && HAVE_DECL_KEY_MACRO)
+  XLAT(KEY_MACRO),
+#endif
+#if defined(KEY_MUTE) || (defined(HAVE_DECL_KEY_MUTE) && HAVE_DECL_KEY_MUTE)
+  XLAT(KEY_MUTE),
+#endif
+#if defined(KEY_VOLUMEDOWN) || (defined(HAVE_DECL_KEY_VOLUMEDOWN) && HAVE_DECL_KEY_VOLUMEDOWN)
+  XLAT(KEY_VOLUMEDOWN),
+#endif
+#if defined(KEY_VOLUMEUP) || (defined(HAVE_DECL_KEY_VOLUMEUP) && HAVE_DECL_KEY_VOLUMEUP)
+  XLAT(KEY_VOLUMEUP),
+#endif
+#if defined(KEY_POWER) || (defined(HAVE_DECL_KEY_POWER) && HAVE_DECL_KEY_POWER)
+  XLAT(KEY_POWER),
+#endif
+#if defined(KEY_KPEQUAL) || (defined(HAVE_DECL_KEY_KPEQUAL) && HAVE_DECL_KEY_KPEQUAL)
+  XLAT(KEY_KPEQUAL),
+#endif
+#if defined(KEY_KPPLUSMINUS) || (defined(HAVE_DECL_KEY_KPPLUSMINUS) && HAVE_DECL_KEY_KPPLUSMINUS)
+  XLAT(KEY_KPPLUSMINUS),
+#endif
+#if defined(KEY_PAUSE) || (defined(HAVE_DECL_KEY_PAUSE) && HAVE_DECL_KEY_PAUSE)
+  XLAT(KEY_PAUSE),
+#endif
+#if defined(KEY_SCALE) || (defined(HAVE_DECL_KEY_SCALE) && HAVE_DECL_KEY_SCALE)
+  XLAT(KEY_SCALE),
+#endif
+
+#if defined(KEY_KPCOMMA) || (defined(HAVE_DECL_KEY_KPCOMMA) && HAVE_DECL_KEY_KPCOMMA)
+  XLAT(KEY_KPCOMMA),
+#endif
+#if defined(KEY_HANGEUL) || (defined(HAVE_DECL_KEY_HANGEUL) && HAVE_DECL_KEY_HANGEUL)
+  XLAT(KEY_HANGEUL),
+#endif
+#if defined(KEY_HANGUEL) || (defined(HAVE_DECL_KEY_HANGUEL) && HAVE_DECL_KEY_HANGUEL)
+  XLAT(KEY_HANGUEL),
+#endif
+#if defined(KEY_HANJA) || (defined(HAVE_DECL_KEY_HANJA) && HAVE_DECL_KEY_HANJA)
+  XLAT(KEY_HANJA),
+#endif
+#if defined(KEY_YEN) || (defined(HAVE_DECL_KEY_YEN) && HAVE_DECL_KEY_YEN)
+  XLAT(KEY_YEN),
+#endif
+#if defined(KEY_LEFTMETA) || (defined(HAVE_DECL_KEY_LEFTMETA) && HAVE_DECL_KEY_LEFTMETA)
+  XLAT(KEY_LEFTMETA),
+#endif
+#if defined(KEY_RIGHTMETA) || (defined(HAVE_DECL_KEY_RIGHTMETA) && HAVE_DECL_KEY_RIGHTMETA)
+  XLAT(KEY_RIGHTMETA),
+#endif
+#if defined(KEY_COMPOSE) || (defined(HAVE_DECL_KEY_COMPOSE) && HAVE_DECL_KEY_COMPOSE)
+  XLAT(KEY_COMPOSE),
+#endif
+
+#if defined(KEY_STOP) || (defined(HAVE_DECL_KEY_STOP) && HAVE_DECL_KEY_STOP)
+  XLAT(KEY_STOP),
+#endif
+#if defined(KEY_AGAIN) || (defined(HAVE_DECL_KEY_AGAIN) && HAVE_DECL_KEY_AGAIN)
+  XLAT(KEY_AGAIN),
+#endif
+#if defined(KEY_PROPS) || (defined(HAVE_DECL_KEY_PROPS) && HAVE_DECL_KEY_PROPS)
+  XLAT(KEY_PROPS),
+#endif
+#if defined(KEY_UNDO) || (defined(HAVE_DECL_KEY_UNDO) && HAVE_DECL_KEY_UNDO)
+  XLAT(KEY_UNDO),
+#endif
+#if defined(KEY_FRONT) || (defined(HAVE_DECL_KEY_FRONT) && HAVE_DECL_KEY_FRONT)
+  XLAT(KEY_FRONT),
+#endif
+#if defined(KEY_COPY) || (defined(HAVE_DECL_KEY_COPY) && HAVE_DECL_KEY_COPY)
+  XLAT(KEY_COPY),
+#endif
+#if defined(KEY_OPEN) || (defined(HAVE_DECL_KEY_OPEN) && HAVE_DECL_KEY_OPEN)
+  XLAT(KEY_OPEN),
+#endif
+#if defined(KEY_PASTE) || (defined(HAVE_DECL_KEY_PASTE) && HAVE_DECL_KEY_PASTE)
+  XLAT(KEY_PASTE),
+#endif
+#if defined(KEY_FIND) || (defined(HAVE_DECL_KEY_FIND) && HAVE_DECL_KEY_FIND)
+  XLAT(KEY_FIND),
+#endif
+#if defined(KEY_CUT) || (defined(HAVE_DECL_KEY_CUT) && HAVE_DECL_KEY_CUT)
+  XLAT(KEY_CUT),
+#endif
+#if defined(KEY_HELP) || (defined(HAVE_DECL_KEY_HELP) && HAVE_DECL_KEY_HELP)
+  XLAT(KEY_HELP),
+#endif
+#if defined(KEY_MENU) || (defined(HAVE_DECL_KEY_MENU) && HAVE_DECL_KEY_MENU)
+  XLAT(KEY_MENU),
+#endif
+#if defined(KEY_CALC) || (defined(HAVE_DECL_KEY_CALC) && HAVE_DECL_KEY_CALC)
+  XLAT(KEY_CALC),
+#endif
+#if defined(KEY_SETUP) || (defined(HAVE_DECL_KEY_SETUP) && HAVE_DECL_KEY_SETUP)
+  XLAT(KEY_SETUP),
+#endif
+#if defined(KEY_SLEEP) || (defined(HAVE_DECL_KEY_SLEEP) && HAVE_DECL_KEY_SLEEP)
+  XLAT(KEY_SLEEP),
+#endif
+#if defined(KEY_WAKEUP) || (defined(HAVE_DECL_KEY_WAKEUP) && HAVE_DECL_KEY_WAKEUP)
+  XLAT(KEY_WAKEUP),
+#endif
+#if defined(KEY_FILE) || (defined(HAVE_DECL_KEY_FILE) && HAVE_DECL_KEY_FILE)
+  XLAT(KEY_FILE),
+#endif
+#if defined(KEY_SENDFILE) || (defined(HAVE_DECL_KEY_SENDFILE) && HAVE_DECL_KEY_SENDFILE)
+  XLAT(KEY_SENDFILE),
+#endif
+#if defined(KEY_DELETEFILE) || (defined(HAVE_DECL_KEY_DELETEFILE) && HAVE_DECL_KEY_DELETEFILE)
+  XLAT(KEY_DELETEFILE),
+#endif
+#if defined(KEY_XFER) || (defined(HAVE_DECL_KEY_XFER) && HAVE_DECL_KEY_XFER)
+  XLAT(KEY_XFER),
+#endif
+#if defined(KEY_PROG1) || (defined(HAVE_DECL_KEY_PROG1) && HAVE_DECL_KEY_PROG1)
+  XLAT(KEY_PROG1),
+#endif
+#if defined(KEY_PROG2) || (defined(HAVE_DECL_KEY_PROG2) && HAVE_DECL_KEY_PROG2)
+  XLAT(KEY_PROG2),
+#endif
+#if defined(KEY_WWW) || (defined(HAVE_DECL_KEY_WWW) && HAVE_DECL_KEY_WWW)
+  XLAT(KEY_WWW),
+#endif
+#if defined(KEY_MSDOS) || (defined(HAVE_DECL_KEY_MSDOS) && HAVE_DECL_KEY_MSDOS)
+  XLAT(KEY_MSDOS),
+#endif
+#if defined(KEY_COFFEE) || (defined(HAVE_DECL_KEY_COFFEE) && HAVE_DECL_KEY_COFFEE)
+  XLAT(KEY_COFFEE),
+#endif
+#if defined(KEY_ROTATE_DISPLAY) || (defined(HAVE_DECL_KEY_ROTATE_DISPLAY) && HAVE_DECL_KEY_ROTATE_DISPLAY)
+  XLAT(KEY_ROTATE_DISPLAY),
+#endif
+#if defined(KEY_DIRECTION) || (defined(HAVE_DECL_KEY_DIRECTION) && HAVE_DECL_KEY_DIRECTION)
+  XLAT(KEY_DIRECTION),
+#endif
+#if defined(KEY_CYCLEWINDOWS) || (defined(HAVE_DECL_KEY_CYCLEWINDOWS) && HAVE_DECL_KEY_CYCLEWINDOWS)
+  XLAT(KEY_CYCLEWINDOWS),
+#endif
+#if defined(KEY_MAIL) || (defined(HAVE_DECL_KEY_MAIL) && HAVE_DECL_KEY_MAIL)
+  XLAT(KEY_MAIL),
+#endif
+#if defined(KEY_BOOKMARKS) || (defined(HAVE_DECL_KEY_BOOKMARKS) && HAVE_DECL_KEY_BOOKMARKS)
+  XLAT(KEY_BOOKMARKS),
+#endif
+#if defined(KEY_COMPUTER) || (defined(HAVE_DECL_KEY_COMPUTER) && HAVE_DECL_KEY_COMPUTER)
+  XLAT(KEY_COMPUTER),
+#endif
+#if defined(KEY_BACK) || (defined(HAVE_DECL_KEY_BACK) && HAVE_DECL_KEY_BACK)
+  XLAT(KEY_BACK),
+#endif
+#if defined(KEY_FORWARD) || (defined(HAVE_DECL_KEY_FORWARD) && HAVE_DECL_KEY_FORWARD)
+  XLAT(KEY_FORWARD),
+#endif
+#if defined(KEY_CLOSECD) || (defined(HAVE_DECL_KEY_CLOSECD) && HAVE_DECL_KEY_CLOSECD)
+  XLAT(KEY_CLOSECD),
+#endif
+#if defined(KEY_EJECTCD) || (defined(HAVE_DECL_KEY_EJECTCD) && HAVE_DECL_KEY_EJECTCD)
+  XLAT(KEY_EJECTCD),
+#endif
+#if defined(KEY_EJECTCLOSECD) || (defined(HAVE_DECL_KEY_EJECTCLOSECD) && HAVE_DECL_KEY_EJECTCLOSECD)
+  XLAT(KEY_EJECTCLOSECD),
+#endif
+#if defined(KEY_NEXTSONG) || (defined(HAVE_DECL_KEY_NEXTSONG) && HAVE_DECL_KEY_NEXTSONG)
+  XLAT(KEY_NEXTSONG),
+#endif
+#if defined(KEY_PLAYPAUSE) || (defined(HAVE_DECL_KEY_PLAYPAUSE) && HAVE_DECL_KEY_PLAYPAUSE)
+  XLAT(KEY_PLAYPAUSE),
+#endif
+#if defined(KEY_PREVIOUSSONG) || (defined(HAVE_DECL_KEY_PREVIOUSSONG) && HAVE_DECL_KEY_PREVIOUSSONG)
+  XLAT(KEY_PREVIOUSSONG),
+#endif
+#if defined(KEY_STOPCD) || (defined(HAVE_DECL_KEY_STOPCD) && HAVE_DECL_KEY_STOPCD)
+  XLAT(KEY_STOPCD),
+#endif
+#if defined(KEY_RECORD) || (defined(HAVE_DECL_KEY_RECORD) && HAVE_DECL_KEY_RECORD)
+  XLAT(KEY_RECORD),
+#endif
+#if defined(KEY_REWIND) || (defined(HAVE_DECL_KEY_REWIND) && HAVE_DECL_KEY_REWIND)
+  XLAT(KEY_REWIND),
+#endif
+#if defined(KEY_PHONE) || (defined(HAVE_DECL_KEY_PHONE) && HAVE_DECL_KEY_PHONE)
+  XLAT(KEY_PHONE),
+#endif
+#if defined(KEY_ISO) || (defined(HAVE_DECL_KEY_ISO) && HAVE_DECL_KEY_ISO)
+  XLAT(KEY_ISO),
+#endif
+#if defined(KEY_CONFIG) || (defined(HAVE_DECL_KEY_CONFIG) && HAVE_DECL_KEY_CONFIG)
+  XLAT(KEY_CONFIG),
+#endif
+#if defined(KEY_HOMEPAGE) || (defined(HAVE_DECL_KEY_HOMEPAGE) && HAVE_DECL_KEY_HOMEPAGE)
+  XLAT(KEY_HOMEPAGE),
+#endif
+#if defined(KEY_REFRESH) || (defined(HAVE_DECL_KEY_REFRESH) && HAVE_DECL_KEY_REFRESH)
+  XLAT(KEY_REFRESH),
+#endif
+#if defined(KEY_EXIT) || (defined(HAVE_DECL_KEY_EXIT) && HAVE_DECL_KEY_EXIT)
+  XLAT(KEY_EXIT),
+#endif
+#if defined(KEY_MOVE) || (defined(HAVE_DECL_KEY_MOVE) && HAVE_DECL_KEY_MOVE)
+  XLAT(KEY_MOVE),
+#endif
+#if defined(KEY_EDIT) || (defined(HAVE_DECL_KEY_EDIT) && HAVE_DECL_KEY_EDIT)
+  XLAT(KEY_EDIT),
+#endif
+#if defined(KEY_SCROLLUP) || (defined(HAVE_DECL_KEY_SCROLLUP) && HAVE_DECL_KEY_SCROLLUP)
+  XLAT(KEY_SCROLLUP),
+#endif
+#if defined(KEY_SCROLLDOWN) || (defined(HAVE_DECL_KEY_SCROLLDOWN) && HAVE_DECL_KEY_SCROLLDOWN)
+  XLAT(KEY_SCROLLDOWN),
+#endif
+#if defined(KEY_KPLEFTPAREN) || (defined(HAVE_DECL_KEY_KPLEFTPAREN) && HAVE_DECL_KEY_KPLEFTPAREN)
+  XLAT(KEY_KPLEFTPAREN),
+#endif
+#if defined(KEY_KPRIGHTPAREN) || (defined(HAVE_DECL_KEY_KPRIGHTPAREN) && HAVE_DECL_KEY_KPRIGHTPAREN)
+  XLAT(KEY_KPRIGHTPAREN),
+#endif
+#if defined(KEY_NEW) || (defined(HAVE_DECL_KEY_NEW) && HAVE_DECL_KEY_NEW)
+  XLAT(KEY_NEW),
+#endif
+#if defined(KEY_REDO) || (defined(HAVE_DECL_KEY_REDO) && HAVE_DECL_KEY_REDO)
+  XLAT(KEY_REDO),
+#endif
+
+#if defined(KEY_F13) || (defined(HAVE_DECL_KEY_F13) && HAVE_DECL_KEY_F13)
+  XLAT(KEY_F13),
+#endif
+#if defined(KEY_F14) || (defined(HAVE_DECL_KEY_F14) && HAVE_DECL_KEY_F14)
+  XLAT(KEY_F14),
+#endif
+#if defined(KEY_F15) || (defined(HAVE_DECL_KEY_F15) && HAVE_DECL_KEY_F15)
+  XLAT(KEY_F15),
+#endif
+#if defined(KEY_F16) || (defined(HAVE_DECL_KEY_F16) && HAVE_DECL_KEY_F16)
+  XLAT(KEY_F16),
+#endif
+#if defined(KEY_F17) || (defined(HAVE_DECL_KEY_F17) && HAVE_DECL_KEY_F17)
+  XLAT(KEY_F17),
+#endif
+#if defined(KEY_F18) || (defined(HAVE_DECL_KEY_F18) && HAVE_DECL_KEY_F18)
+  XLAT(KEY_F18),
+#endif
+#if defined(KEY_F19) || (defined(HAVE_DECL_KEY_F19) && HAVE_DECL_KEY_F19)
+  XLAT(KEY_F19),
+#endif
+#if defined(KEY_F20) || (defined(HAVE_DECL_KEY_F20) && HAVE_DECL_KEY_F20)
+  XLAT(KEY_F20),
+#endif
+#if defined(KEY_F21) || (defined(HAVE_DECL_KEY_F21) && HAVE_DECL_KEY_F21)
+  XLAT(KEY_F21),
+#endif
+#if defined(KEY_F22) || (defined(HAVE_DECL_KEY_F22) && HAVE_DECL_KEY_F22)
+  XLAT(KEY_F22),
+#endif
+#if defined(KEY_F23) || (defined(HAVE_DECL_KEY_F23) && HAVE_DECL_KEY_F23)
+  XLAT(KEY_F23),
+#endif
+#if defined(KEY_F24) || (defined(HAVE_DECL_KEY_F24) && HAVE_DECL_KEY_F24)
+  XLAT(KEY_F24),
+#endif
+
+#if defined(KEY_PLAYCD) || (defined(HAVE_DECL_KEY_PLAYCD) && HAVE_DECL_KEY_PLAYCD)
+  XLAT(KEY_PLAYCD),
+#endif
+#if defined(KEY_PAUSECD) || (defined(HAVE_DECL_KEY_PAUSECD) && HAVE_DECL_KEY_PAUSECD)
+  XLAT(KEY_PAUSECD),
+#endif
+#if defined(KEY_PROG3) || (defined(HAVE_DECL_KEY_PROG3) && HAVE_DECL_KEY_PROG3)
+  XLAT(KEY_PROG3),
+#endif
+#if defined(KEY_PROG4) || (defined(HAVE_DECL_KEY_PROG4) && HAVE_DECL_KEY_PROG4)
+  XLAT(KEY_PROG4),
+#endif
+#if defined(KEY_DASHBOARD) || (defined(HAVE_DECL_KEY_DASHBOARD) && HAVE_DECL_KEY_DASHBOARD)
+  XLAT(KEY_DASHBOARD),
+#endif
+#if defined(KEY_SUSPEND) || (defined(HAVE_DECL_KEY_SUSPEND) && HAVE_DECL_KEY_SUSPEND)
+  XLAT(KEY_SUSPEND),
+#endif
+#if defined(KEY_CLOSE) || (defined(HAVE_DECL_KEY_CLOSE) && HAVE_DECL_KEY_CLOSE)
+  XLAT(KEY_CLOSE),
+#endif
+#if defined(KEY_PLAY) || (defined(HAVE_DECL_KEY_PLAY) && HAVE_DECL_KEY_PLAY)
+  XLAT(KEY_PLAY),
+#endif
+#if defined(KEY_FASTFORWARD) || (defined(HAVE_DECL_KEY_FASTFORWARD) && HAVE_DECL_KEY_FASTFORWARD)
+  XLAT(KEY_FASTFORWARD),
+#endif
+#if defined(KEY_BASSBOOST) || (defined(HAVE_DECL_KEY_BASSBOOST) && HAVE_DECL_KEY_BASSBOOST)
+  XLAT(KEY_BASSBOOST),
+#endif
+#if defined(KEY_PRINT) || (defined(HAVE_DECL_KEY_PRINT) && HAVE_DECL_KEY_PRINT)
+  XLAT(KEY_PRINT),
+#endif
+#if defined(KEY_HP) || (defined(HAVE_DECL_KEY_HP) && HAVE_DECL_KEY_HP)
+  XLAT(KEY_HP),
+#endif
+#if defined(KEY_CAMERA) || (defined(HAVE_DECL_KEY_CAMERA) && HAVE_DECL_KEY_CAMERA)
+  XLAT(KEY_CAMERA),
+#endif
+#if defined(KEY_SOUND) || (defined(HAVE_DECL_KEY_SOUND) && HAVE_DECL_KEY_SOUND)
+  XLAT(KEY_SOUND),
+#endif
+#if defined(KEY_QUESTION) || (defined(HAVE_DECL_KEY_QUESTION) && HAVE_DECL_KEY_QUESTION)
+  XLAT(KEY_QUESTION),
+#endif
+#if defined(KEY_EMAIL) || (defined(HAVE_DECL_KEY_EMAIL) && HAVE_DECL_KEY_EMAIL)
+  XLAT(KEY_EMAIL),
+#endif
+#if defined(KEY_CHAT) || (defined(HAVE_DECL_KEY_CHAT) && HAVE_DECL_KEY_CHAT)
+  XLAT(KEY_CHAT),
+#endif
+#if defined(KEY_SEARCH) || (defined(HAVE_DECL_KEY_SEARCH) && HAVE_DECL_KEY_SEARCH)
+  XLAT(KEY_SEARCH),
+#endif
+#if defined(KEY_CONNECT) || (defined(HAVE_DECL_KEY_CONNECT) && HAVE_DECL_KEY_CONNECT)
+  XLAT(KEY_CONNECT),
+#endif
+#if defined(KEY_FINANCE) || (defined(HAVE_DECL_KEY_FINANCE) && HAVE_DECL_KEY_FINANCE)
+  XLAT(KEY_FINANCE),
+#endif
+#if defined(KEY_SPORT) || (defined(HAVE_DECL_KEY_SPORT) && HAVE_DECL_KEY_SPORT)
+  XLAT(KEY_SPORT),
+#endif
+#if defined(KEY_SHOP) || (defined(HAVE_DECL_KEY_SHOP) && HAVE_DECL_KEY_SHOP)
+  XLAT(KEY_SHOP),
+#endif
+#if defined(KEY_ALTERASE) || (defined(HAVE_DECL_KEY_ALTERASE) && HAVE_DECL_KEY_ALTERASE)
+  XLAT(KEY_ALTERASE),
+#endif
+#if defined(KEY_CANCEL) || (defined(HAVE_DECL_KEY_CANCEL) && HAVE_DECL_KEY_CANCEL)
+  XLAT(KEY_CANCEL),
+#endif
+#if defined(KEY_BRIGHTNESSDOWN) || (defined(HAVE_DECL_KEY_BRIGHTNESSDOWN) && HAVE_DECL_KEY_BRIGHTNESSDOWN)
+  XLAT(KEY_BRIGHTNESSDOWN),
+#endif
+#if defined(KEY_BRIGHTNESSUP) || (defined(HAVE_DECL_KEY_BRIGHTNESSUP) && HAVE_DECL_KEY_BRIGHTNESSUP)
+  XLAT(KEY_BRIGHTNESSUP),
+#endif
+#if defined(KEY_MEDIA) || (defined(HAVE_DECL_KEY_MEDIA) && HAVE_DECL_KEY_MEDIA)
+  XLAT(KEY_MEDIA),
+#endif
+
+#if defined(KEY_SWITCHVIDEOMODE) || (defined(HAVE_DECL_KEY_SWITCHVIDEOMODE) && HAVE_DECL_KEY_SWITCHVIDEOMODE)
+  XLAT(KEY_SWITCHVIDEOMODE),
+#endif
+
+#if defined(KEY_KBDILLUMTOGGLE) || (defined(HAVE_DECL_KEY_KBDILLUMTOGGLE) && HAVE_DECL_KEY_KBDILLUMTOGGLE)
+  XLAT(KEY_KBDILLUMTOGGLE),
+#endif
+#if defined(KEY_KBDILLUMDOWN) || (defined(HAVE_DECL_KEY_KBDILLUMDOWN) && HAVE_DECL_KEY_KBDILLUMDOWN)
+  XLAT(KEY_KBDILLUMDOWN),
+#endif
+#if defined(KEY_KBDILLUMUP) || (defined(HAVE_DECL_KEY_KBDILLUMUP) && HAVE_DECL_KEY_KBDILLUMUP)
+  XLAT(KEY_KBDILLUMUP),
+#endif
+
+#if defined(KEY_SEND) || (defined(HAVE_DECL_KEY_SEND) && HAVE_DECL_KEY_SEND)
+  XLAT(KEY_SEND),
+#endif
+#if defined(KEY_REPLY) || (defined(HAVE_DECL_KEY_REPLY) && HAVE_DECL_KEY_REPLY)
+  XLAT(KEY_REPLY),
+#endif
+#if defined(KEY_FORWARDMAIL) || (defined(HAVE_DECL_KEY_FORWARDMAIL) && HAVE_DECL_KEY_FORWARDMAIL)
+  XLAT(KEY_FORWARDMAIL),
+#endif
+#if defined(KEY_SAVE) || (defined(HAVE_DECL_KEY_SAVE) && HAVE_DECL_KEY_SAVE)
+  XLAT(KEY_SAVE),
+#endif
+#if defined(KEY_DOCUMENTS) || (defined(HAVE_DECL_KEY_DOCUMENTS) && HAVE_DECL_KEY_DOCUMENTS)
+  XLAT(KEY_DOCUMENTS),
+#endif
+
+#if defined(KEY_BATTERY) || (defined(HAVE_DECL_KEY_BATTERY) && HAVE_DECL_KEY_BATTERY)
+  XLAT(KEY_BATTERY),
+#endif
+
+#if defined(KEY_BLUETOOTH) || (defined(HAVE_DECL_KEY_BLUETOOTH) && HAVE_DECL_KEY_BLUETOOTH)
+  XLAT(KEY_BLUETOOTH),
+#endif
+#if defined(KEY_WLAN) || (defined(HAVE_DECL_KEY_WLAN) && HAVE_DECL_KEY_WLAN)
+  XLAT(KEY_WLAN),
+#endif
+#if defined(KEY_UWB) || (defined(HAVE_DECL_KEY_UWB) && HAVE_DECL_KEY_UWB)
+  XLAT(KEY_UWB),
+#endif
+
+#if defined(KEY_UNKNOWN) || (defined(HAVE_DECL_KEY_UNKNOWN) && HAVE_DECL_KEY_UNKNOWN)
+  XLAT(KEY_UNKNOWN),
+#endif
+
+#if defined(KEY_VIDEO_NEXT) || (defined(HAVE_DECL_KEY_VIDEO_NEXT) && HAVE_DECL_KEY_VIDEO_NEXT)
+  XLAT(KEY_VIDEO_NEXT),
+#endif
+#if defined(KEY_VIDEO_PREV) || (defined(HAVE_DECL_KEY_VIDEO_PREV) && HAVE_DECL_KEY_VIDEO_PREV)
+  XLAT(KEY_VIDEO_PREV),
+#endif
+#if defined(KEY_BRIGHTNESS_CYCLE) || (defined(HAVE_DECL_KEY_BRIGHTNESS_CYCLE) && HAVE_DECL_KEY_BRIGHTNESS_CYCLE)
+  XLAT(KEY_BRIGHTNESS_CYCLE),
+#endif
+#if defined(KEY_BRIGHTNESS_AUTO) || (defined(HAVE_DECL_KEY_BRIGHTNESS_AUTO) && HAVE_DECL_KEY_BRIGHTNESS_AUTO)
+  XLAT(KEY_BRIGHTNESS_AUTO),
+#endif
+#if defined(KEY_BRIGHTNESS_ZERO) || (defined(HAVE_DECL_KEY_BRIGHTNESS_ZERO) && HAVE_DECL_KEY_BRIGHTNESS_ZERO)
+  XLAT(KEY_BRIGHTNESS_ZERO),
+#endif
+#if defined(KEY_DISPLAY_OFF) || (defined(HAVE_DECL_KEY_DISPLAY_OFF) && HAVE_DECL_KEY_DISPLAY_OFF)
+  XLAT(KEY_DISPLAY_OFF),
+#endif
+
+#if defined(KEY_WWAN) || (defined(HAVE_DECL_KEY_WWAN) && HAVE_DECL_KEY_WWAN)
+  XLAT(KEY_WWAN),
+#endif
+#if defined(KEY_WIMAX) || (defined(HAVE_DECL_KEY_WIMAX) && HAVE_DECL_KEY_WIMAX)
+  XLAT(KEY_WIMAX),
+#endif
+#if defined(KEY_RFKILL) || (defined(HAVE_DECL_KEY_RFKILL) && HAVE_DECL_KEY_RFKILL)
+  XLAT(KEY_RFKILL),
+#endif
+
+#if defined(KEY_MICMUTE) || (defined(HAVE_DECL_KEY_MICMUTE) && HAVE_DECL_KEY_MICMUTE)
+  XLAT(KEY_MICMUTE),
+#endif
+
+#if defined(BTN_0) || (defined(HAVE_DECL_BTN_0) && HAVE_DECL_BTN_0)
+  XLAT(BTN_0),
+#endif
+#if defined(BTN_1) || (defined(HAVE_DECL_BTN_1) && HAVE_DECL_BTN_1)
+  XLAT(BTN_1),
+#endif
+#if defined(BTN_2) || (defined(HAVE_DECL_BTN_2) && HAVE_DECL_BTN_2)
+  XLAT(BTN_2),
+#endif
+#if defined(BTN_3) || (defined(HAVE_DECL_BTN_3) && HAVE_DECL_BTN_3)
+  XLAT(BTN_3),
+#endif
+#if defined(BTN_4) || (defined(HAVE_DECL_BTN_4) && HAVE_DECL_BTN_4)
+  XLAT(BTN_4),
+#endif
+#if defined(BTN_5) || (defined(HAVE_DECL_BTN_5) && HAVE_DECL_BTN_5)
+  XLAT(BTN_5),
+#endif
+#if defined(BTN_6) || (defined(HAVE_DECL_BTN_6) && HAVE_DECL_BTN_6)
+  XLAT(BTN_6),
+#endif
+#if defined(BTN_7) || (defined(HAVE_DECL_BTN_7) && HAVE_DECL_BTN_7)
+  XLAT(BTN_7),
+#endif
+#if defined(BTN_8) || (defined(HAVE_DECL_BTN_8) && HAVE_DECL_BTN_8)
+  XLAT(BTN_8),
+#endif
+#if defined(BTN_9) || (defined(HAVE_DECL_BTN_9) && HAVE_DECL_BTN_9)
+  XLAT(BTN_9),
+#endif
+
+#if defined(BTN_MOUSE) || (defined(HAVE_DECL_BTN_MOUSE) && HAVE_DECL_BTN_MOUSE)
+  XLAT(BTN_MOUSE),
+#endif
+#if defined(BTN_LEFT) || (defined(HAVE_DECL_BTN_LEFT) && HAVE_DECL_BTN_LEFT)
+  XLAT(BTN_LEFT),
+#endif
+#if defined(BTN_RIGHT) || (defined(HAVE_DECL_BTN_RIGHT) && HAVE_DECL_BTN_RIGHT)
+  XLAT(BTN_RIGHT),
+#endif
+#if defined(BTN_MIDDLE) || (defined(HAVE_DECL_BTN_MIDDLE) && HAVE_DECL_BTN_MIDDLE)
+  XLAT(BTN_MIDDLE),
+#endif
+#if defined(BTN_SIDE) || (defined(HAVE_DECL_BTN_SIDE) && HAVE_DECL_BTN_SIDE)
+  XLAT(BTN_SIDE),
+#endif
+#if defined(BTN_EXTRA) || (defined(HAVE_DECL_BTN_EXTRA) && HAVE_DECL_BTN_EXTRA)
+  XLAT(BTN_EXTRA),
+#endif
+#if defined(BTN_FORWARD) || (defined(HAVE_DECL_BTN_FORWARD) && HAVE_DECL_BTN_FORWARD)
+  XLAT(BTN_FORWARD),
+#endif
+#if defined(BTN_BACK) || (defined(HAVE_DECL_BTN_BACK) && HAVE_DECL_BTN_BACK)
+  XLAT(BTN_BACK),
+#endif
+#if defined(BTN_TASK) || (defined(HAVE_DECL_BTN_TASK) && HAVE_DECL_BTN_TASK)
+  XLAT(BTN_TASK),
+#endif
+
+#if defined(BTN_JOYSTICK) || (defined(HAVE_DECL_BTN_JOYSTICK) && HAVE_DECL_BTN_JOYSTICK)
+  XLAT(BTN_JOYSTICK),
+#endif
+#if defined(BTN_TRIGGER) || (defined(HAVE_DECL_BTN_TRIGGER) && HAVE_DECL_BTN_TRIGGER)
+  XLAT(BTN_TRIGGER),
+#endif
+#if defined(BTN_THUMB) || (defined(HAVE_DECL_BTN_THUMB) && HAVE_DECL_BTN_THUMB)
+  XLAT(BTN_THUMB),
+#endif
+#if defined(BTN_THUMB2) || (defined(HAVE_DECL_BTN_THUMB2) && HAVE_DECL_BTN_THUMB2)
+  XLAT(BTN_THUMB2),
+#endif
+#if defined(BTN_TOP) || (defined(HAVE_DECL_BTN_TOP) && HAVE_DECL_BTN_TOP)
+  XLAT(BTN_TOP),
+#endif
+#if defined(BTN_TOP2) || (defined(HAVE_DECL_BTN_TOP2) && HAVE_DECL_BTN_TOP2)
+  XLAT(BTN_TOP2),
+#endif
+#if defined(BTN_PINKIE) || (defined(HAVE_DECL_BTN_PINKIE) && HAVE_DECL_BTN_PINKIE)
+  XLAT(BTN_PINKIE),
+#endif
+#if defined(BTN_BASE) || (defined(HAVE_DECL_BTN_BASE) && HAVE_DECL_BTN_BASE)
+  XLAT(BTN_BASE),
+#endif
+#if defined(BTN_BASE2) || (defined(HAVE_DECL_BTN_BASE2) && HAVE_DECL_BTN_BASE2)
+  XLAT(BTN_BASE2),
+#endif
+#if defined(BTN_BASE3) || (defined(HAVE_DECL_BTN_BASE3) && HAVE_DECL_BTN_BASE3)
+  XLAT(BTN_BASE3),
+#endif
+#if defined(BTN_BASE4) || (defined(HAVE_DECL_BTN_BASE4) && HAVE_DECL_BTN_BASE4)
+  XLAT(BTN_BASE4),
+#endif
+#if defined(BTN_BASE5) || (defined(HAVE_DECL_BTN_BASE5) && HAVE_DECL_BTN_BASE5)
+  XLAT(BTN_BASE5),
+#endif
+#if defined(BTN_BASE6) || (defined(HAVE_DECL_BTN_BASE6) && HAVE_DECL_BTN_BASE6)
+  XLAT(BTN_BASE6),
+#endif
+#if defined(BTN_DEAD) || (defined(HAVE_DECL_BTN_DEAD) && HAVE_DECL_BTN_DEAD)
+  XLAT(BTN_DEAD),
+#endif
+
+#if defined(BTN_GAMEPAD) || (defined(HAVE_DECL_BTN_GAMEPAD) && HAVE_DECL_BTN_GAMEPAD)
+  XLAT(BTN_GAMEPAD),
+#endif
+#if defined(BTN_SOUTH) || (defined(HAVE_DECL_BTN_SOUTH) && HAVE_DECL_BTN_SOUTH)
+  XLAT(BTN_SOUTH),
+#endif
+#if defined(BTN_A) || (defined(HAVE_DECL_BTN_A) && HAVE_DECL_BTN_A)
+  XLAT(BTN_A),
+#endif
+#if defined(BTN_EAST) || (defined(HAVE_DECL_BTN_EAST) && HAVE_DECL_BTN_EAST)
+  XLAT(BTN_EAST),
+#endif
+#if defined(BTN_B) || (defined(HAVE_DECL_BTN_B) && HAVE_DECL_BTN_B)
+  XLAT(BTN_B),
+#endif
+#if defined(BTN_C) || (defined(HAVE_DECL_BTN_C) && HAVE_DECL_BTN_C)
+  XLAT(BTN_C),
+#endif
+#if defined(BTN_NORTH) || (defined(HAVE_DECL_BTN_NORTH) && HAVE_DECL_BTN_NORTH)
+  XLAT(BTN_NORTH),
+#endif
+#if defined(BTN_X) || (defined(HAVE_DECL_BTN_X) && HAVE_DECL_BTN_X)
+  XLAT(BTN_X),
+#endif
+#if defined(BTN_WEST) || (defined(HAVE_DECL_BTN_WEST) && HAVE_DECL_BTN_WEST)
+  XLAT(BTN_WEST),
+#endif
+#if defined(BTN_Y) || (defined(HAVE_DECL_BTN_Y) && HAVE_DECL_BTN_Y)
+  XLAT(BTN_Y),
+#endif
+#if defined(BTN_Z) || (defined(HAVE_DECL_BTN_Z) && HAVE_DECL_BTN_Z)
+  XLAT(BTN_Z),
+#endif
+#if defined(BTN_TL) || (defined(HAVE_DECL_BTN_TL) && HAVE_DECL_BTN_TL)
+  XLAT(BTN_TL),
+#endif
+#if defined(BTN_TR) || (defined(HAVE_DECL_BTN_TR) && HAVE_DECL_BTN_TR)
+  XLAT(BTN_TR),
+#endif
+#if defined(BTN_TL2) || (defined(HAVE_DECL_BTN_TL2) && HAVE_DECL_BTN_TL2)
+  XLAT(BTN_TL2),
+#endif
+#if defined(BTN_TR2) || (defined(HAVE_DECL_BTN_TR2) && HAVE_DECL_BTN_TR2)
+  XLAT(BTN_TR2),
+#endif
+#if defined(BTN_SELECT) || (defined(HAVE_DECL_BTN_SELECT) && HAVE_DECL_BTN_SELECT)
+  XLAT(BTN_SELECT),
+#endif
+#if defined(BTN_START) || (defined(HAVE_DECL_BTN_START) && HAVE_DECL_BTN_START)
+  XLAT(BTN_START),
+#endif
+#if defined(BTN_MODE) || (defined(HAVE_DECL_BTN_MODE) && HAVE_DECL_BTN_MODE)
+  XLAT(BTN_MODE),
+#endif
+#if defined(BTN_THUMBL) || (defined(HAVE_DECL_BTN_THUMBL) && HAVE_DECL_BTN_THUMBL)
+  XLAT(BTN_THUMBL),
+#endif
+#if defined(BTN_THUMBR) || (defined(HAVE_DECL_BTN_THUMBR) && HAVE_DECL_BTN_THUMBR)
+  XLAT(BTN_THUMBR),
+#endif
+
+#if defined(BTN_DIGI) || (defined(HAVE_DECL_BTN_DIGI) && HAVE_DECL_BTN_DIGI)
+  XLAT(BTN_DIGI),
+#endif
+#if defined(BTN_TOOL_PEN) || (defined(HAVE_DECL_BTN_TOOL_PEN) && HAVE_DECL_BTN_TOOL_PEN)
+  XLAT(BTN_TOOL_PEN),
+#endif
+#if defined(BTN_TOOL_RUBBER) || (defined(HAVE_DECL_BTN_TOOL_RUBBER) && HAVE_DECL_BTN_TOOL_RUBBER)
+  XLAT(BTN_TOOL_RUBBER),
+#endif
+#if defined(BTN_TOOL_BRUSH) || (defined(HAVE_DECL_BTN_TOOL_BRUSH) && HAVE_DECL_BTN_TOOL_BRUSH)
+  XLAT(BTN_TOOL_BRUSH),
+#endif
+#if defined(BTN_TOOL_PENCIL) || (defined(HAVE_DECL_BTN_TOOL_PENCIL) && HAVE_DECL_BTN_TOOL_PENCIL)
+  XLAT(BTN_TOOL_PENCIL),
+#endif
+#if defined(BTN_TOOL_AIRBRUSH) || (defined(HAVE_DECL_BTN_TOOL_AIRBRUSH) && HAVE_DECL_BTN_TOOL_AIRBRUSH)
+  XLAT(BTN_TOOL_AIRBRUSH),
+#endif
+#if defined(BTN_TOOL_FINGER) || (defined(HAVE_DECL_BTN_TOOL_FINGER) && HAVE_DECL_BTN_TOOL_FINGER)
+  XLAT(BTN_TOOL_FINGER),
+#endif
+#if defined(BTN_TOOL_MOUSE) || (defined(HAVE_DECL_BTN_TOOL_MOUSE) && HAVE_DECL_BTN_TOOL_MOUSE)
+  XLAT(BTN_TOOL_MOUSE),
+#endif
+#if defined(BTN_TOOL_LENS) || (defined(HAVE_DECL_BTN_TOOL_LENS) && HAVE_DECL_BTN_TOOL_LENS)
+  XLAT(BTN_TOOL_LENS),
+#endif
+#if defined(BTN_TOOL_QUINTTAP) || (defined(HAVE_DECL_BTN_TOOL_QUINTTAP) && HAVE_DECL_BTN_TOOL_QUINTTAP)
+  XLAT(BTN_TOOL_QUINTTAP),
+#endif
+#if defined(BTN_TOUCH) || (defined(HAVE_DECL_BTN_TOUCH) && HAVE_DECL_BTN_TOUCH)
+  XLAT(BTN_TOUCH),
+#endif
+#if defined(BTN_STYLUS) || (defined(HAVE_DECL_BTN_STYLUS) && HAVE_DECL_BTN_STYLUS)
+  XLAT(BTN_STYLUS),
+#endif
+#if defined(BTN_STYLUS2) || (defined(HAVE_DECL_BTN_STYLUS2) && HAVE_DECL_BTN_STYLUS2)
+  XLAT(BTN_STYLUS2),
+#endif
+#if defined(BTN_TOOL_DOUBLETAP) || (defined(HAVE_DECL_BTN_TOOL_DOUBLETAP) && HAVE_DECL_BTN_TOOL_DOUBLETAP)
+  XLAT(BTN_TOOL_DOUBLETAP),
+#endif
+#if defined(BTN_TOOL_TRIPLETAP) || (defined(HAVE_DECL_BTN_TOOL_TRIPLETAP) && HAVE_DECL_BTN_TOOL_TRIPLETAP)
+  XLAT(BTN_TOOL_TRIPLETAP),
+#endif
+#if defined(BTN_TOOL_QUADTAP) || (defined(HAVE_DECL_BTN_TOOL_QUADTAP) && HAVE_DECL_BTN_TOOL_QUADTAP)
+  XLAT(BTN_TOOL_QUADTAP),
+#endif
+
+#if defined(BTN_WHEEL) || (defined(HAVE_DECL_BTN_WHEEL) && HAVE_DECL_BTN_WHEEL)
+  XLAT(BTN_WHEEL),
+#endif
+#if defined(BTN_GEAR_DOWN) || (defined(HAVE_DECL_BTN_GEAR_DOWN) && HAVE_DECL_BTN_GEAR_DOWN)
+  XLAT(BTN_GEAR_DOWN),
+#endif
+#if defined(BTN_GEAR_UP) || (defined(HAVE_DECL_BTN_GEAR_UP) && HAVE_DECL_BTN_GEAR_UP)
+  XLAT(BTN_GEAR_UP),
+#endif
+
+#if defined(KEY_OK) || (defined(HAVE_DECL_KEY_OK) && HAVE_DECL_KEY_OK)
+  XLAT(KEY_OK),
+#endif
+#if defined(KEY_SELECT) || (defined(HAVE_DECL_KEY_SELECT) && HAVE_DECL_KEY_SELECT)
+  XLAT(KEY_SELECT),
+#endif
+#if defined(KEY_GOTO) || (defined(HAVE_DECL_KEY_GOTO) && HAVE_DECL_KEY_GOTO)
+  XLAT(KEY_GOTO),
+#endif
+#if defined(KEY_CLEAR) || (defined(HAVE_DECL_KEY_CLEAR) && HAVE_DECL_KEY_CLEAR)
+  XLAT(KEY_CLEAR),
+#endif
+#if defined(KEY_POWER2) || (defined(HAVE_DECL_KEY_POWER2) && HAVE_DECL_KEY_POWER2)
+  XLAT(KEY_POWER2),
+#endif
+#if defined(KEY_OPTION) || (defined(HAVE_DECL_KEY_OPTION) && HAVE_DECL_KEY_OPTION)
+  XLAT(KEY_OPTION),
+#endif
+#if defined(KEY_INFO) || (defined(HAVE_DECL_KEY_INFO) && HAVE_DECL_KEY_INFO)
+  XLAT(KEY_INFO),
+#endif
+#if defined(KEY_TIME) || (defined(HAVE_DECL_KEY_TIME) && HAVE_DECL_KEY_TIME)
+  XLAT(KEY_TIME),
+#endif
+#if defined(KEY_VENDOR) || (defined(HAVE_DECL_KEY_VENDOR) && HAVE_DECL_KEY_VENDOR)
+  XLAT(KEY_VENDOR),
+#endif
+#if defined(KEY_ARCHIVE) || (defined(HAVE_DECL_KEY_ARCHIVE) && HAVE_DECL_KEY_ARCHIVE)
+  XLAT(KEY_ARCHIVE),
+#endif
+#if defined(KEY_PROGRAM) || (defined(HAVE_DECL_KEY_PROGRAM) && HAVE_DECL_KEY_PROGRAM)
+  XLAT(KEY_PROGRAM),
+#endif
+#if defined(KEY_CHANNEL) || (defined(HAVE_DECL_KEY_CHANNEL) && HAVE_DECL_KEY_CHANNEL)
+  XLAT(KEY_CHANNEL),
+#endif
+#if defined(KEY_FAVORITES) || (defined(HAVE_DECL_KEY_FAVORITES) && HAVE_DECL_KEY_FAVORITES)
+  XLAT(KEY_FAVORITES),
+#endif
+#if defined(KEY_EPG) || (defined(HAVE_DECL_KEY_EPG) && HAVE_DECL_KEY_EPG)
+  XLAT(KEY_EPG),
+#endif
+#if defined(KEY_PVR) || (defined(HAVE_DECL_KEY_PVR) && HAVE_DECL_KEY_PVR)
+  XLAT(KEY_PVR),
+#endif
+#if defined(KEY_MHP) || (defined(HAVE_DECL_KEY_MHP) && HAVE_DECL_KEY_MHP)
+  XLAT(KEY_MHP),
+#endif
+#if defined(KEY_LANGUAGE) || (defined(HAVE_DECL_KEY_LANGUAGE) && HAVE_DECL_KEY_LANGUAGE)
+  XLAT(KEY_LANGUAGE),
+#endif
+#if defined(KEY_TITLE) || (defined(HAVE_DECL_KEY_TITLE) && HAVE_DECL_KEY_TITLE)
+  XLAT(KEY_TITLE),
+#endif
+#if defined(KEY_SUBTITLE) || (defined(HAVE_DECL_KEY_SUBTITLE) && HAVE_DECL_KEY_SUBTITLE)
+  XLAT(KEY_SUBTITLE),
+#endif
+#if defined(KEY_ANGLE) || (defined(HAVE_DECL_KEY_ANGLE) && HAVE_DECL_KEY_ANGLE)
+  XLAT(KEY_ANGLE),
+#endif
+#if defined(KEY_ZOOM) || (defined(HAVE_DECL_KEY_ZOOM) && HAVE_DECL_KEY_ZOOM)
+  XLAT(KEY_ZOOM),
+#endif
+#if defined(KEY_MODE) || (defined(HAVE_DECL_KEY_MODE) && HAVE_DECL_KEY_MODE)
+  XLAT(KEY_MODE),
+#endif
+#if defined(KEY_KEYBOARD) || (defined(HAVE_DECL_KEY_KEYBOARD) && HAVE_DECL_KEY_KEYBOARD)
+  XLAT(KEY_KEYBOARD),
+#endif
+#if defined(KEY_SCREEN) || (defined(HAVE_DECL_KEY_SCREEN) && HAVE_DECL_KEY_SCREEN)
+  XLAT(KEY_SCREEN),
+#endif
+#if defined(KEY_PC) || (defined(HAVE_DECL_KEY_PC) && HAVE_DECL_KEY_PC)
+  XLAT(KEY_PC),
+#endif
+#if defined(KEY_TV) || (defined(HAVE_DECL_KEY_TV) && HAVE_DECL_KEY_TV)
+  XLAT(KEY_TV),
+#endif
+#if defined(KEY_TV2) || (defined(HAVE_DECL_KEY_TV2) && HAVE_DECL_KEY_TV2)
+  XLAT(KEY_TV2),
+#endif
+#if defined(KEY_VCR) || (defined(HAVE_DECL_KEY_VCR) && HAVE_DECL_KEY_VCR)
+  XLAT(KEY_VCR),
+#endif
+#if defined(KEY_VCR2) || (defined(HAVE_DECL_KEY_VCR2) && HAVE_DECL_KEY_VCR2)
+  XLAT(KEY_VCR2),
+#endif
+#if defined(KEY_SAT) || (defined(HAVE_DECL_KEY_SAT) && HAVE_DECL_KEY_SAT)
+  XLAT(KEY_SAT),
+#endif
+#if defined(KEY_SAT2) || (defined(HAVE_DECL_KEY_SAT2) && HAVE_DECL_KEY_SAT2)
+  XLAT(KEY_SAT2),
+#endif
+#if defined(KEY_CD) || (defined(HAVE_DECL_KEY_CD) && HAVE_DECL_KEY_CD)
+  XLAT(KEY_CD),
+#endif
+#if defined(KEY_TAPE) || (defined(HAVE_DECL_KEY_TAPE) && HAVE_DECL_KEY_TAPE)
+  XLAT(KEY_TAPE),
+#endif
+#if defined(KEY_RADIO) || (defined(HAVE_DECL_KEY_RADIO) && HAVE_DECL_KEY_RADIO)
+  XLAT(KEY_RADIO),
+#endif
+#if defined(KEY_TUNER) || (defined(HAVE_DECL_KEY_TUNER) && HAVE_DECL_KEY_TUNER)
+  XLAT(KEY_TUNER),
+#endif
+#if defined(KEY_PLAYER) || (defined(HAVE_DECL_KEY_PLAYER) && HAVE_DECL_KEY_PLAYER)
+  XLAT(KEY_PLAYER),
+#endif
+#if defined(KEY_TEXT) || (defined(HAVE_DECL_KEY_TEXT) && HAVE_DECL_KEY_TEXT)
+  XLAT(KEY_TEXT),
+#endif
+#if defined(KEY_DVD) || (defined(HAVE_DECL_KEY_DVD) && HAVE_DECL_KEY_DVD)
+  XLAT(KEY_DVD),
+#endif
+#if defined(KEY_AUX) || (defined(HAVE_DECL_KEY_AUX) && HAVE_DECL_KEY_AUX)
+  XLAT(KEY_AUX),
+#endif
+#if defined(KEY_MP3) || (defined(HAVE_DECL_KEY_MP3) && HAVE_DECL_KEY_MP3)
+  XLAT(KEY_MP3),
+#endif
+#if defined(KEY_AUDIO) || (defined(HAVE_DECL_KEY_AUDIO) && HAVE_DECL_KEY_AUDIO)
+  XLAT(KEY_AUDIO),
+#endif
+#if defined(KEY_VIDEO) || (defined(HAVE_DECL_KEY_VIDEO) && HAVE_DECL_KEY_VIDEO)
+  XLAT(KEY_VIDEO),
+#endif
+#if defined(KEY_DIRECTORY) || (defined(HAVE_DECL_KEY_DIRECTORY) && HAVE_DECL_KEY_DIRECTORY)
+  XLAT(KEY_DIRECTORY),
+#endif
+#if defined(KEY_LIST) || (defined(HAVE_DECL_KEY_LIST) && HAVE_DECL_KEY_LIST)
+  XLAT(KEY_LIST),
+#endif
+#if defined(KEY_MEMO) || (defined(HAVE_DECL_KEY_MEMO) && HAVE_DECL_KEY_MEMO)
+  XLAT(KEY_MEMO),
+#endif
+#if defined(KEY_CALENDAR) || (defined(HAVE_DECL_KEY_CALENDAR) && HAVE_DECL_KEY_CALENDAR)
+  XLAT(KEY_CALENDAR),
+#endif
+#if defined(KEY_RED) || (defined(HAVE_DECL_KEY_RED) && HAVE_DECL_KEY_RED)
+  XLAT(KEY_RED),
+#endif
+#if defined(KEY_GREEN) || (defined(HAVE_DECL_KEY_GREEN) && HAVE_DECL_KEY_GREEN)
+  XLAT(KEY_GREEN),
+#endif
+#if defined(KEY_YELLOW) || (defined(HAVE_DECL_KEY_YELLOW) && HAVE_DECL_KEY_YELLOW)
+  XLAT(KEY_YELLOW),
+#endif
+#if defined(KEY_BLUE) || (defined(HAVE_DECL_KEY_BLUE) && HAVE_DECL_KEY_BLUE)
+  XLAT(KEY_BLUE),
+#endif
+#if defined(KEY_CHANNELUP) || (defined(HAVE_DECL_KEY_CHANNELUP) && HAVE_DECL_KEY_CHANNELUP)
+  XLAT(KEY_CHANNELUP),
+#endif
+#if defined(KEY_CHANNELDOWN) || (defined(HAVE_DECL_KEY_CHANNELDOWN) && HAVE_DECL_KEY_CHANNELDOWN)
+  XLAT(KEY_CHANNELDOWN),
+#endif
+#if defined(KEY_FIRST) || (defined(HAVE_DECL_KEY_FIRST) && HAVE_DECL_KEY_FIRST)
+  XLAT(KEY_FIRST),
+#endif
+#if defined(KEY_LAST) || (defined(HAVE_DECL_KEY_LAST) && HAVE_DECL_KEY_LAST)
+  XLAT(KEY_LAST),
+#endif
+#if defined(KEY_AB) || (defined(HAVE_DECL_KEY_AB) && HAVE_DECL_KEY_AB)
+  XLAT(KEY_AB),
+#endif
+#if defined(KEY_NEXT) || (defined(HAVE_DECL_KEY_NEXT) && HAVE_DECL_KEY_NEXT)
+  XLAT(KEY_NEXT),
+#endif
+#if defined(KEY_RESTART) || (defined(HAVE_DECL_KEY_RESTART) && HAVE_DECL_KEY_RESTART)
+  XLAT(KEY_RESTART),
+#endif
+#if defined(KEY_SLOW) || (defined(HAVE_DECL_KEY_SLOW) && HAVE_DECL_KEY_SLOW)
+  XLAT(KEY_SLOW),
+#endif
+#if defined(KEY_SHUFFLE) || (defined(HAVE_DECL_KEY_SHUFFLE) && HAVE_DECL_KEY_SHUFFLE)
+  XLAT(KEY_SHUFFLE),
+#endif
+#if defined(KEY_BREAK) || (defined(HAVE_DECL_KEY_BREAK) && HAVE_DECL_KEY_BREAK)
+  XLAT(KEY_BREAK),
+#endif
+#if defined(KEY_PREVIOUS) || (defined(HAVE_DECL_KEY_PREVIOUS) && HAVE_DECL_KEY_PREVIOUS)
+  XLAT(KEY_PREVIOUS),
+#endif
+#if defined(KEY_DIGITS) || (defined(HAVE_DECL_KEY_DIGITS) && HAVE_DECL_KEY_DIGITS)
+  XLAT(KEY_DIGITS),
+#endif
+#if defined(KEY_TEEN) || (defined(HAVE_DECL_KEY_TEEN) && HAVE_DECL_KEY_TEEN)
+  XLAT(KEY_TEEN),
+#endif
+#if defined(KEY_TWEN) || (defined(HAVE_DECL_KEY_TWEN) && HAVE_DECL_KEY_TWEN)
+  XLAT(KEY_TWEN),
+#endif
+#if defined(KEY_VIDEOPHONE) || (defined(HAVE_DECL_KEY_VIDEOPHONE) && HAVE_DECL_KEY_VIDEOPHONE)
+  XLAT(KEY_VIDEOPHONE),
+#endif
+#if defined(KEY_GAMES) || (defined(HAVE_DECL_KEY_GAMES) && HAVE_DECL_KEY_GAMES)
+  XLAT(KEY_GAMES),
+#endif
+#if defined(KEY_ZOOMIN) || (defined(HAVE_DECL_KEY_ZOOMIN) && HAVE_DECL_KEY_ZOOMIN)
+  XLAT(KEY_ZOOMIN),
+#endif
+#if defined(KEY_ZOOMOUT) || (defined(HAVE_DECL_KEY_ZOOMOUT) && HAVE_DECL_KEY_ZOOMOUT)
+  XLAT(KEY_ZOOMOUT),
+#endif
+#if defined(KEY_ZOOMRESET) || (defined(HAVE_DECL_KEY_ZOOMRESET) && HAVE_DECL_KEY_ZOOMRESET)
+  XLAT(KEY_ZOOMRESET),
+#endif
+#if defined(KEY_WORDPROCESSOR) || (defined(HAVE_DECL_KEY_WORDPROCESSOR) && HAVE_DECL_KEY_WORDPROCESSOR)
+  XLAT(KEY_WORDPROCESSOR),
+#endif
+#if defined(KEY_EDITOR) || (defined(HAVE_DECL_KEY_EDITOR) && HAVE_DECL_KEY_EDITOR)
+  XLAT(KEY_EDITOR),
+#endif
+#if defined(KEY_SPREADSHEET) || (defined(HAVE_DECL_KEY_SPREADSHEET) && HAVE_DECL_KEY_SPREADSHEET)
+  XLAT(KEY_SPREADSHEET),
+#endif
+#if defined(KEY_GRAPHICSEDITOR) || (defined(HAVE_DECL_KEY_GRAPHICSEDITOR) && HAVE_DECL_KEY_GRAPHICSEDITOR)
+  XLAT(KEY_GRAPHICSEDITOR),
+#endif
+#if defined(KEY_PRESENTATION) || (defined(HAVE_DECL_KEY_PRESENTATION) && HAVE_DECL_KEY_PRESENTATION)
+  XLAT(KEY_PRESENTATION),
+#endif
+#if defined(KEY_DATABASE) || (defined(HAVE_DECL_KEY_DATABASE) && HAVE_DECL_KEY_DATABASE)
+  XLAT(KEY_DATABASE),
+#endif
+#if defined(KEY_NEWS) || (defined(HAVE_DECL_KEY_NEWS) && HAVE_DECL_KEY_NEWS)
+  XLAT(KEY_NEWS),
+#endif
+#if defined(KEY_VOICEMAIL) || (defined(HAVE_DECL_KEY_VOICEMAIL) && HAVE_DECL_KEY_VOICEMAIL)
+  XLAT(KEY_VOICEMAIL),
+#endif
+#if defined(KEY_ADDRESSBOOK) || (defined(HAVE_DECL_KEY_ADDRESSBOOK) && HAVE_DECL_KEY_ADDRESSBOOK)
+  XLAT(KEY_ADDRESSBOOK),
+#endif
+#if defined(KEY_MESSENGER) || (defined(HAVE_DECL_KEY_MESSENGER) && HAVE_DECL_KEY_MESSENGER)
+  XLAT(KEY_MESSENGER),
+#endif
+#if defined(KEY_DISPLAYTOGGLE) || (defined(HAVE_DECL_KEY_DISPLAYTOGGLE) && HAVE_DECL_KEY_DISPLAYTOGGLE)
+  XLAT(KEY_DISPLAYTOGGLE),
+#endif
+#if defined(KEY_BRIGHTNESS_TOGGLE) || (defined(HAVE_DECL_KEY_BRIGHTNESS_TOGGLE) && HAVE_DECL_KEY_BRIGHTNESS_TOGGLE)
+  XLAT(KEY_BRIGHTNESS_TOGGLE),
+#endif
+#if defined(KEY_SPELLCHECK) || (defined(HAVE_DECL_KEY_SPELLCHECK) && HAVE_DECL_KEY_SPELLCHECK)
+  XLAT(KEY_SPELLCHECK),
+#endif
+#if defined(KEY_LOGOFF) || (defined(HAVE_DECL_KEY_LOGOFF) && HAVE_DECL_KEY_LOGOFF)
+  XLAT(KEY_LOGOFF),
+#endif
+
+#if defined(KEY_DOLLAR) || (defined(HAVE_DECL_KEY_DOLLAR) && HAVE_DECL_KEY_DOLLAR)
+  XLAT(KEY_DOLLAR),
+#endif
+#if defined(KEY_EURO) || (defined(HAVE_DECL_KEY_EURO) && HAVE_DECL_KEY_EURO)
+  XLAT(KEY_EURO),
+#endif
+
+#if defined(KEY_FRAMEBACK) || (defined(HAVE_DECL_KEY_FRAMEBACK) && HAVE_DECL_KEY_FRAMEBACK)
+  XLAT(KEY_FRAMEBACK),
+#endif
+#if defined(KEY_FRAMEFORWARD) || (defined(HAVE_DECL_KEY_FRAMEFORWARD) && HAVE_DECL_KEY_FRAMEFORWARD)
+  XLAT(KEY_FRAMEFORWARD),
+#endif
+#if defined(KEY_CONTEXT_MENU) || (defined(HAVE_DECL_KEY_CONTEXT_MENU) && HAVE_DECL_KEY_CONTEXT_MENU)
+  XLAT(KEY_CONTEXT_MENU),
+#endif
+#if defined(KEY_MEDIA_REPEAT) || (defined(HAVE_DECL_KEY_MEDIA_REPEAT) && HAVE_DECL_KEY_MEDIA_REPEAT)
+  XLAT(KEY_MEDIA_REPEAT),
+#endif
+#if defined(KEY_10CHANNELSUP) || (defined(HAVE_DECL_KEY_10CHANNELSUP) && HAVE_DECL_KEY_10CHANNELSUP)
+  XLAT(KEY_10CHANNELSUP),
+#endif
+#if defined(KEY_10CHANNELSDOWN) || (defined(HAVE_DECL_KEY_10CHANNELSDOWN) && HAVE_DECL_KEY_10CHANNELSDOWN)
+  XLAT(KEY_10CHANNELSDOWN),
+#endif
+#if defined(KEY_IMAGES) || (defined(HAVE_DECL_KEY_IMAGES) && HAVE_DECL_KEY_IMAGES)
+  XLAT(KEY_IMAGES),
+#endif
+
+#if defined(KEY_DEL_EOL) || (defined(HAVE_DECL_KEY_DEL_EOL) && HAVE_DECL_KEY_DEL_EOL)
+  XLAT(KEY_DEL_EOL),
+#endif
+#if defined(KEY_DEL_EOS) || (defined(HAVE_DECL_KEY_DEL_EOS) && HAVE_DECL_KEY_DEL_EOS)
+  XLAT(KEY_DEL_EOS),
+#endif
+#if defined(KEY_INS_LINE) || (defined(HAVE_DECL_KEY_INS_LINE) && HAVE_DECL_KEY_INS_LINE)
+  XLAT(KEY_INS_LINE),
+#endif
+#if defined(KEY_DEL_LINE) || (defined(HAVE_DECL_KEY_DEL_LINE) && HAVE_DECL_KEY_DEL_LINE)
+  XLAT(KEY_DEL_LINE),
+#endif
+
+#if defined(KEY_FN) || (defined(HAVE_DECL_KEY_FN) && HAVE_DECL_KEY_FN)
+  XLAT(KEY_FN),
+#endif
+#if defined(KEY_FN_ESC) || (defined(HAVE_DECL_KEY_FN_ESC) && HAVE_DECL_KEY_FN_ESC)
+  XLAT(KEY_FN_ESC),
+#endif
+#if defined(KEY_FN_F1) || (defined(HAVE_DECL_KEY_FN_F1) && HAVE_DECL_KEY_FN_F1)
+  XLAT(KEY_FN_F1),
+#endif
+#if defined(KEY_FN_F2) || (defined(HAVE_DECL_KEY_FN_F2) && HAVE_DECL_KEY_FN_F2)
+  XLAT(KEY_FN_F2),
+#endif
+#if defined(KEY_FN_F3) || (defined(HAVE_DECL_KEY_FN_F3) && HAVE_DECL_KEY_FN_F3)
+  XLAT(KEY_FN_F3),
+#endif
+#if defined(KEY_FN_F4) || (defined(HAVE_DECL_KEY_FN_F4) && HAVE_DECL_KEY_FN_F4)
+  XLAT(KEY_FN_F4),
+#endif
+#if defined(KEY_FN_F5) || (defined(HAVE_DECL_KEY_FN_F5) && HAVE_DECL_KEY_FN_F5)
+  XLAT(KEY_FN_F5),
+#endif
+#if defined(KEY_FN_F6) || (defined(HAVE_DECL_KEY_FN_F6) && HAVE_DECL_KEY_FN_F6)
+  XLAT(KEY_FN_F6),
+#endif
+#if defined(KEY_FN_F7) || (defined(HAVE_DECL_KEY_FN_F7) && HAVE_DECL_KEY_FN_F7)
+  XLAT(KEY_FN_F7),
+#endif
+#if defined(KEY_FN_F8) || (defined(HAVE_DECL_KEY_FN_F8) && HAVE_DECL_KEY_FN_F8)
+  XLAT(KEY_FN_F8),
+#endif
+#if defined(KEY_FN_F9) || (defined(HAVE_DECL_KEY_FN_F9) && HAVE_DECL_KEY_FN_F9)
+  XLAT(KEY_FN_F9),
+#endif
+#if defined(KEY_FN_F10) || (defined(HAVE_DECL_KEY_FN_F10) && HAVE_DECL_KEY_FN_F10)
+  XLAT(KEY_FN_F10),
+#endif
+#if defined(KEY_FN_F11) || (defined(HAVE_DECL_KEY_FN_F11) && HAVE_DECL_KEY_FN_F11)
+  XLAT(KEY_FN_F11),
+#endif
+#if defined(KEY_FN_F12) || (defined(HAVE_DECL_KEY_FN_F12) && HAVE_DECL_KEY_FN_F12)
+  XLAT(KEY_FN_F12),
+#endif
+#if defined(KEY_FN_1) || (defined(HAVE_DECL_KEY_FN_1) && HAVE_DECL_KEY_FN_1)
+  XLAT(KEY_FN_1),
+#endif
+#if defined(KEY_FN_2) || (defined(HAVE_DECL_KEY_FN_2) && HAVE_DECL_KEY_FN_2)
+  XLAT(KEY_FN_2),
+#endif
+#if defined(KEY_FN_D) || (defined(HAVE_DECL_KEY_FN_D) && HAVE_DECL_KEY_FN_D)
+  XLAT(KEY_FN_D),
+#endif
+#if defined(KEY_FN_E) || (defined(HAVE_DECL_KEY_FN_E) && HAVE_DECL_KEY_FN_E)
+  XLAT(KEY_FN_E),
+#endif
+#if defined(KEY_FN_F) || (defined(HAVE_DECL_KEY_FN_F) && HAVE_DECL_KEY_FN_F)
+  XLAT(KEY_FN_F),
+#endif
+#if defined(KEY_FN_S) || (defined(HAVE_DECL_KEY_FN_S) && HAVE_DECL_KEY_FN_S)
+  XLAT(KEY_FN_S),
+#endif
+#if defined(KEY_FN_B) || (defined(HAVE_DECL_KEY_FN_B) && HAVE_DECL_KEY_FN_B)
+  XLAT(KEY_FN_B),
+#endif
+
+#if defined(KEY_BRL_DOT1) || (defined(HAVE_DECL_KEY_BRL_DOT1) && HAVE_DECL_KEY_BRL_DOT1)
+  XLAT(KEY_BRL_DOT1),
+#endif
+#if defined(KEY_BRL_DOT2) || (defined(HAVE_DECL_KEY_BRL_DOT2) && HAVE_DECL_KEY_BRL_DOT2)
+  XLAT(KEY_BRL_DOT2),
+#endif
+#if defined(KEY_BRL_DOT3) || (defined(HAVE_DECL_KEY_BRL_DOT3) && HAVE_DECL_KEY_BRL_DOT3)
+  XLAT(KEY_BRL_DOT3),
+#endif
+#if defined(KEY_BRL_DOT4) || (defined(HAVE_DECL_KEY_BRL_DOT4) && HAVE_DECL_KEY_BRL_DOT4)
+  XLAT(KEY_BRL_DOT4),
+#endif
+#if defined(KEY_BRL_DOT5) || (defined(HAVE_DECL_KEY_BRL_DOT5) && HAVE_DECL_KEY_BRL_DOT5)
+  XLAT(KEY_BRL_DOT5),
+#endif
+#if defined(KEY_BRL_DOT6) || (defined(HAVE_DECL_KEY_BRL_DOT6) && HAVE_DECL_KEY_BRL_DOT6)
+  XLAT(KEY_BRL_DOT6),
+#endif
+#if defined(KEY_BRL_DOT7) || (defined(HAVE_DECL_KEY_BRL_DOT7) && HAVE_DECL_KEY_BRL_DOT7)
+  XLAT(KEY_BRL_DOT7),
+#endif
+#if defined(KEY_BRL_DOT8) || (defined(HAVE_DECL_KEY_BRL_DOT8) && HAVE_DECL_KEY_BRL_DOT8)
+  XLAT(KEY_BRL_DOT8),
+#endif
+#if defined(KEY_BRL_DOT9) || (defined(HAVE_DECL_KEY_BRL_DOT9) && HAVE_DECL_KEY_BRL_DOT9)
+  XLAT(KEY_BRL_DOT9),
+#endif
+#if defined(KEY_BRL_DOT10) || (defined(HAVE_DECL_KEY_BRL_DOT10) && HAVE_DECL_KEY_BRL_DOT10)
+  XLAT(KEY_BRL_DOT10),
+#endif
+
+#if defined(KEY_NUMERIC_0) || (defined(HAVE_DECL_KEY_NUMERIC_0) && HAVE_DECL_KEY_NUMERIC_0)
+  XLAT(KEY_NUMERIC_0),
+#endif
+#if defined(KEY_NUMERIC_1) || (defined(HAVE_DECL_KEY_NUMERIC_1) && HAVE_DECL_KEY_NUMERIC_1)
+  XLAT(KEY_NUMERIC_1),
+#endif
+#if defined(KEY_NUMERIC_2) || (defined(HAVE_DECL_KEY_NUMERIC_2) && HAVE_DECL_KEY_NUMERIC_2)
+  XLAT(KEY_NUMERIC_2),
+#endif
+#if defined(KEY_NUMERIC_3) || (defined(HAVE_DECL_KEY_NUMERIC_3) && HAVE_DECL_KEY_NUMERIC_3)
+  XLAT(KEY_NUMERIC_3),
+#endif
+#if defined(KEY_NUMERIC_4) || (defined(HAVE_DECL_KEY_NUMERIC_4) && HAVE_DECL_KEY_NUMERIC_4)
+  XLAT(KEY_NUMERIC_4),
+#endif
+#if defined(KEY_NUMERIC_5) || (defined(HAVE_DECL_KEY_NUMERIC_5) && HAVE_DECL_KEY_NUMERIC_5)
+  XLAT(KEY_NUMERIC_5),
+#endif
+#if defined(KEY_NUMERIC_6) || (defined(HAVE_DECL_KEY_NUMERIC_6) && HAVE_DECL_KEY_NUMERIC_6)
+  XLAT(KEY_NUMERIC_6),
+#endif
+#if defined(KEY_NUMERIC_7) || (defined(HAVE_DECL_KEY_NUMERIC_7) && HAVE_DECL_KEY_NUMERIC_7)
+  XLAT(KEY_NUMERIC_7),
+#endif
+#if defined(KEY_NUMERIC_8) || (defined(HAVE_DECL_KEY_NUMERIC_8) && HAVE_DECL_KEY_NUMERIC_8)
+  XLAT(KEY_NUMERIC_8),
+#endif
+#if defined(KEY_NUMERIC_9) || (defined(HAVE_DECL_KEY_NUMERIC_9) && HAVE_DECL_KEY_NUMERIC_9)
+  XLAT(KEY_NUMERIC_9),
+#endif
+#if defined(KEY_NUMERIC_STAR) || (defined(HAVE_DECL_KEY_NUMERIC_STAR) && HAVE_DECL_KEY_NUMERIC_STAR)
+  XLAT(KEY_NUMERIC_STAR),
+#endif
+#if defined(KEY_NUMERIC_POUND) || (defined(HAVE_DECL_KEY_NUMERIC_POUND) && HAVE_DECL_KEY_NUMERIC_POUND)
+  XLAT(KEY_NUMERIC_POUND),
+#endif
+#if defined(KEY_NUMERIC_A) || (defined(HAVE_DECL_KEY_NUMERIC_A) && HAVE_DECL_KEY_NUMERIC_A)
+  XLAT(KEY_NUMERIC_A),
+#endif
+#if defined(KEY_NUMERIC_B) || (defined(HAVE_DECL_KEY_NUMERIC_B) && HAVE_DECL_KEY_NUMERIC_B)
+  XLAT(KEY_NUMERIC_B),
+#endif
+#if defined(KEY_NUMERIC_C) || (defined(HAVE_DECL_KEY_NUMERIC_C) && HAVE_DECL_KEY_NUMERIC_C)
+  XLAT(KEY_NUMERIC_C),
+#endif
+#if defined(KEY_NUMERIC_D) || (defined(HAVE_DECL_KEY_NUMERIC_D) && HAVE_DECL_KEY_NUMERIC_D)
+  XLAT(KEY_NUMERIC_D),
+#endif
+
+#if defined(KEY_CAMERA_FOCUS) || (defined(HAVE_DECL_KEY_CAMERA_FOCUS) && HAVE_DECL_KEY_CAMERA_FOCUS)
+  XLAT(KEY_CAMERA_FOCUS),
+#endif
+#if defined(KEY_WPS_BUTTON) || (defined(HAVE_DECL_KEY_WPS_BUTTON) && HAVE_DECL_KEY_WPS_BUTTON)
+  XLAT(KEY_WPS_BUTTON),
+#endif
+
+#if defined(KEY_TOUCHPAD_TOGGLE) || (defined(HAVE_DECL_KEY_TOUCHPAD_TOGGLE) && HAVE_DECL_KEY_TOUCHPAD_TOGGLE)
+  XLAT(KEY_TOUCHPAD_TOGGLE),
+#endif
+#if defined(KEY_TOUCHPAD_ON) || (defined(HAVE_DECL_KEY_TOUCHPAD_ON) && HAVE_DECL_KEY_TOUCHPAD_ON)
+  XLAT(KEY_TOUCHPAD_ON),
+#endif
+#if defined(KEY_TOUCHPAD_OFF) || (defined(HAVE_DECL_KEY_TOUCHPAD_OFF) && HAVE_DECL_KEY_TOUCHPAD_OFF)
+  XLAT(KEY_TOUCHPAD_OFF),
+#endif
+
+#if defined(KEY_CAMERA_ZOOMIN) || (defined(HAVE_DECL_KEY_CAMERA_ZOOMIN) && HAVE_DECL_KEY_CAMERA_ZOOMIN)
+  XLAT(KEY_CAMERA_ZOOMIN),
+#endif
+#if defined(KEY_CAMERA_ZOOMOUT) || (defined(HAVE_DECL_KEY_CAMERA_ZOOMOUT) && HAVE_DECL_KEY_CAMERA_ZOOMOUT)
+  XLAT(KEY_CAMERA_ZOOMOUT),
+#endif
+#if defined(KEY_CAMERA_UP) || (defined(HAVE_DECL_KEY_CAMERA_UP) && HAVE_DECL_KEY_CAMERA_UP)
+  XLAT(KEY_CAMERA_UP),
+#endif
+#if defined(KEY_CAMERA_DOWN) || (defined(HAVE_DECL_KEY_CAMERA_DOWN) && HAVE_DECL_KEY_CAMERA_DOWN)
+  XLAT(KEY_CAMERA_DOWN),
+#endif
+#if defined(KEY_CAMERA_LEFT) || (defined(HAVE_DECL_KEY_CAMERA_LEFT) && HAVE_DECL_KEY_CAMERA_LEFT)
+  XLAT(KEY_CAMERA_LEFT),
+#endif
+#if defined(KEY_CAMERA_RIGHT) || (defined(HAVE_DECL_KEY_CAMERA_RIGHT) && HAVE_DECL_KEY_CAMERA_RIGHT)
+  XLAT(KEY_CAMERA_RIGHT),
+#endif
+
+#if defined(KEY_ATTENDANT_ON) || (defined(HAVE_DECL_KEY_ATTENDANT_ON) && HAVE_DECL_KEY_ATTENDANT_ON)
+  XLAT(KEY_ATTENDANT_ON),
+#endif
+#if defined(KEY_ATTENDANT_OFF) || (defined(HAVE_DECL_KEY_ATTENDANT_OFF) && HAVE_DECL_KEY_ATTENDANT_OFF)
+  XLAT(KEY_ATTENDANT_OFF),
+#endif
+#if defined(KEY_ATTENDANT_TOGGLE) || (defined(HAVE_DECL_KEY_ATTENDANT_TOGGLE) && HAVE_DECL_KEY_ATTENDANT_TOGGLE)
+  XLAT(KEY_ATTENDANT_TOGGLE),
+#endif
+#if defined(KEY_LIGHTS_TOGGLE) || (defined(HAVE_DECL_KEY_LIGHTS_TOGGLE) && HAVE_DECL_KEY_LIGHTS_TOGGLE)
+  XLAT(KEY_LIGHTS_TOGGLE),
+#endif
+
+#if defined(BTN_DPAD_UP) || (defined(HAVE_DECL_BTN_DPAD_UP) && HAVE_DECL_BTN_DPAD_UP)
+  XLAT(BTN_DPAD_UP),
+#endif
+#if defined(BTN_DPAD_DOWN) || (defined(HAVE_DECL_BTN_DPAD_DOWN) && HAVE_DECL_BTN_DPAD_DOWN)
+  XLAT(BTN_DPAD_DOWN),
+#endif
+#if defined(BTN_DPAD_LEFT) || (defined(HAVE_DECL_BTN_DPAD_LEFT) && HAVE_DECL_BTN_DPAD_LEFT)
+  XLAT(BTN_DPAD_LEFT),
+#endif
+#if defined(BTN_DPAD_RIGHT) || (defined(HAVE_DECL_BTN_DPAD_RIGHT) && HAVE_DECL_BTN_DPAD_RIGHT)
+  XLAT(BTN_DPAD_RIGHT),
+#endif
+
+#if defined(KEY_ALS_TOGGLE) || (defined(HAVE_DECL_KEY_ALS_TOGGLE) && HAVE_DECL_KEY_ALS_TOGGLE)
+  XLAT(KEY_ALS_TOGGLE),
+#endif
+
+#if defined(KEY_BUTTONCONFIG) || (defined(HAVE_DECL_KEY_BUTTONCONFIG) && HAVE_DECL_KEY_BUTTONCONFIG)
+  XLAT(KEY_BUTTONCONFIG),
+#endif
+#if defined(KEY_TASKMANAGER) || (defined(HAVE_DECL_KEY_TASKMANAGER) && HAVE_DECL_KEY_TASKMANAGER)
+  XLAT(KEY_TASKMANAGER),
+#endif
+#if defined(KEY_JOURNAL) || (defined(HAVE_DECL_KEY_JOURNAL) && HAVE_DECL_KEY_JOURNAL)
+  XLAT(KEY_JOURNAL),
+#endif
+#if defined(KEY_CONTROLPANEL) || (defined(HAVE_DECL_KEY_CONTROLPANEL) && HAVE_DECL_KEY_CONTROLPANEL)
+  XLAT(KEY_CONTROLPANEL),
+#endif
+#if defined(KEY_APPSELECT) || (defined(HAVE_DECL_KEY_APPSELECT) && HAVE_DECL_KEY_APPSELECT)
+  XLAT(KEY_APPSELECT),
+#endif
+#if defined(KEY_SCREENSAVER) || (defined(HAVE_DECL_KEY_SCREENSAVER) && HAVE_DECL_KEY_SCREENSAVER)
+  XLAT(KEY_SCREENSAVER),
+#endif
+#if defined(KEY_VOICECOMMAND) || (defined(HAVE_DECL_KEY_VOICECOMMAND) && HAVE_DECL_KEY_VOICECOMMAND)
+  XLAT(KEY_VOICECOMMAND),
+#endif
+
+#if defined(KEY_BRIGHTNESS_MIN) || (defined(HAVE_DECL_KEY_BRIGHTNESS_MIN) && HAVE_DECL_KEY_BRIGHTNESS_MIN)
+  XLAT(KEY_BRIGHTNESS_MIN),
+#endif
+#if defined(KEY_BRIGHTNESS_MAX) || (defined(HAVE_DECL_KEY_BRIGHTNESS_MAX) && HAVE_DECL_KEY_BRIGHTNESS_MAX)
+  XLAT(KEY_BRIGHTNESS_MAX),
+#endif
+
+#if defined(KEY_KBDINPUTASSIST_PREV) || (defined(HAVE_DECL_KEY_KBDINPUTASSIST_PREV) && HAVE_DECL_KEY_KBDINPUTASSIST_PREV)
+  XLAT(KEY_KBDINPUTASSIST_PREV),
+#endif
+#if defined(KEY_KBDINPUTASSIST_NEXT) || (defined(HAVE_DECL_KEY_KBDINPUTASSIST_NEXT) && HAVE_DECL_KEY_KBDINPUTASSIST_NEXT)
+  XLAT(KEY_KBDINPUTASSIST_NEXT),
+#endif
+#if defined(KEY_KBDINPUTASSIST_PREVGROUP) || (defined(HAVE_DECL_KEY_KBDINPUTASSIST_PREVGROUP) && HAVE_DECL_KEY_KBDINPUTASSIST_PREVGROUP)
+  XLAT(KEY_KBDINPUTASSIST_PREVGROUP),
+#endif
+#if defined(KEY_KBDINPUTASSIST_NEXTGROUP) || (defined(HAVE_DECL_KEY_KBDINPUTASSIST_NEXTGROUP) && HAVE_DECL_KEY_KBDINPUTASSIST_NEXTGROUP)
+  XLAT(KEY_KBDINPUTASSIST_NEXTGROUP),
+#endif
+#if defined(KEY_KBDINPUTASSIST_ACCEPT) || (defined(HAVE_DECL_KEY_KBDINPUTASSIST_ACCEPT) && HAVE_DECL_KEY_KBDINPUTASSIST_ACCEPT)
+  XLAT(KEY_KBDINPUTASSIST_ACCEPT),
+#endif
+#if defined(KEY_KBDINPUTASSIST_CANCEL) || (defined(HAVE_DECL_KEY_KBDINPUTASSIST_CANCEL) && HAVE_DECL_KEY_KBDINPUTASSIST_CANCEL)
+  XLAT(KEY_KBDINPUTASSIST_CANCEL),
+#endif
+
+#if defined(KEY_RIGHT_UP) || (defined(HAVE_DECL_KEY_RIGHT_UP) && HAVE_DECL_KEY_RIGHT_UP)
+  XLAT(KEY_RIGHT_UP),
+#endif
+#if defined(KEY_RIGHT_DOWN) || (defined(HAVE_DECL_KEY_RIGHT_DOWN) && HAVE_DECL_KEY_RIGHT_DOWN)
+  XLAT(KEY_RIGHT_DOWN),
+#endif
+#if defined(KEY_LEFT_UP) || (defined(HAVE_DECL_KEY_LEFT_UP) && HAVE_DECL_KEY_LEFT_UP)
+  XLAT(KEY_LEFT_UP),
+#endif
+#if defined(KEY_LEFT_DOWN) || (defined(HAVE_DECL_KEY_LEFT_DOWN) && HAVE_DECL_KEY_LEFT_DOWN)
+  XLAT(KEY_LEFT_DOWN),
+#endif
+
+#if defined(KEY_ROOT_MENU) || (defined(HAVE_DECL_KEY_ROOT_MENU) && HAVE_DECL_KEY_ROOT_MENU)
+  XLAT(KEY_ROOT_MENU),
+#endif
+#if defined(KEY_MEDIA_TOP_MENU) || (defined(HAVE_DECL_KEY_MEDIA_TOP_MENU) && HAVE_DECL_KEY_MEDIA_TOP_MENU)
+  XLAT(KEY_MEDIA_TOP_MENU),
+#endif
+#if defined(KEY_NUMERIC_11) || (defined(HAVE_DECL_KEY_NUMERIC_11) && HAVE_DECL_KEY_NUMERIC_11)
+  XLAT(KEY_NUMERIC_11),
+#endif
+#if defined(KEY_NUMERIC_12) || (defined(HAVE_DECL_KEY_NUMERIC_12) && HAVE_DECL_KEY_NUMERIC_12)
+  XLAT(KEY_NUMERIC_12),
+#endif
+
+#if defined(KEY_AUDIO_DESC) || (defined(HAVE_DECL_KEY_AUDIO_DESC) && HAVE_DECL_KEY_AUDIO_DESC)
+  XLAT(KEY_AUDIO_DESC),
+#endif
+#if defined(KEY_3D_MODE) || (defined(HAVE_DECL_KEY_3D_MODE) && HAVE_DECL_KEY_3D_MODE)
+  XLAT(KEY_3D_MODE),
+#endif
+#if defined(KEY_NEXT_FAVORITE) || (defined(HAVE_DECL_KEY_NEXT_FAVORITE) && HAVE_DECL_KEY_NEXT_FAVORITE)
+  XLAT(KEY_NEXT_FAVORITE),
+#endif
+#if defined(KEY_STOP_RECORD) || (defined(HAVE_DECL_KEY_STOP_RECORD) && HAVE_DECL_KEY_STOP_RECORD)
+  XLAT(KEY_STOP_RECORD),
+#endif
+#if defined(KEY_PAUSE_RECORD) || (defined(HAVE_DECL_KEY_PAUSE_RECORD) && HAVE_DECL_KEY_PAUSE_RECORD)
+  XLAT(KEY_PAUSE_RECORD),
+#endif
+#if defined(KEY_VOD) || (defined(HAVE_DECL_KEY_VOD) && HAVE_DECL_KEY_VOD)
+  XLAT(KEY_VOD),
+#endif
+#if defined(KEY_UNMUTE) || (defined(HAVE_DECL_KEY_UNMUTE) && HAVE_DECL_KEY_UNMUTE)
+  XLAT(KEY_UNMUTE),
+#endif
+#if defined(KEY_FASTREVERSE) || (defined(HAVE_DECL_KEY_FASTREVERSE) && HAVE_DECL_KEY_FASTREVERSE)
+  XLAT(KEY_FASTREVERSE),
+#endif
+#if defined(KEY_SLOWREVERSE) || (defined(HAVE_DECL_KEY_SLOWREVERSE) && HAVE_DECL_KEY_SLOWREVERSE)
+  XLAT(KEY_SLOWREVERSE),
+#endif
+
+#if defined(BTN_TRIGGER_HAPPY) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY) && HAVE_DECL_BTN_TRIGGER_HAPPY)
+  XLAT(BTN_TRIGGER_HAPPY),
+#endif
+#if defined(BTN_TRIGGER_HAPPY1) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY1) && HAVE_DECL_BTN_TRIGGER_HAPPY1)
+  XLAT(BTN_TRIGGER_HAPPY1),
+#endif
+#if defined(BTN_TRIGGER_HAPPY2) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY2) && HAVE_DECL_BTN_TRIGGER_HAPPY2)
+  XLAT(BTN_TRIGGER_HAPPY2),
+#endif
+#if defined(BTN_TRIGGER_HAPPY3) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY3) && HAVE_DECL_BTN_TRIGGER_HAPPY3)
+  XLAT(BTN_TRIGGER_HAPPY3),
+#endif
+#if defined(BTN_TRIGGER_HAPPY4) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY4) && HAVE_DECL_BTN_TRIGGER_HAPPY4)
+  XLAT(BTN_TRIGGER_HAPPY4),
+#endif
+#if defined(BTN_TRIGGER_HAPPY5) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY5) && HAVE_DECL_BTN_TRIGGER_HAPPY5)
+  XLAT(BTN_TRIGGER_HAPPY5),
+#endif
+#if defined(BTN_TRIGGER_HAPPY6) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY6) && HAVE_DECL_BTN_TRIGGER_HAPPY6)
+  XLAT(BTN_TRIGGER_HAPPY6),
+#endif
+#if defined(BTN_TRIGGER_HAPPY7) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY7) && HAVE_DECL_BTN_TRIGGER_HAPPY7)
+  XLAT(BTN_TRIGGER_HAPPY7),
+#endif
+#if defined(BTN_TRIGGER_HAPPY8) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY8) && HAVE_DECL_BTN_TRIGGER_HAPPY8)
+  XLAT(BTN_TRIGGER_HAPPY8),
+#endif
+#if defined(BTN_TRIGGER_HAPPY9) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY9) && HAVE_DECL_BTN_TRIGGER_HAPPY9)
+  XLAT(BTN_TRIGGER_HAPPY9),
+#endif
+#if defined(BTN_TRIGGER_HAPPY10) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY10) && HAVE_DECL_BTN_TRIGGER_HAPPY10)
+  XLAT(BTN_TRIGGER_HAPPY10),
+#endif
+#if defined(BTN_TRIGGER_HAPPY11) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY11) && HAVE_DECL_BTN_TRIGGER_HAPPY11)
+  XLAT(BTN_TRIGGER_HAPPY11),
+#endif
+#if defined(BTN_TRIGGER_HAPPY12) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY12) && HAVE_DECL_BTN_TRIGGER_HAPPY12)
+  XLAT(BTN_TRIGGER_HAPPY12),
+#endif
+#if defined(BTN_TRIGGER_HAPPY13) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY13) && HAVE_DECL_BTN_TRIGGER_HAPPY13)
+  XLAT(BTN_TRIGGER_HAPPY13),
+#endif
+#if defined(BTN_TRIGGER_HAPPY14) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY14) && HAVE_DECL_BTN_TRIGGER_HAPPY14)
+  XLAT(BTN_TRIGGER_HAPPY14),
+#endif
+#if defined(BTN_TRIGGER_HAPPY15) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY15) && HAVE_DECL_BTN_TRIGGER_HAPPY15)
+  XLAT(BTN_TRIGGER_HAPPY15),
+#endif
+#if defined(BTN_TRIGGER_HAPPY16) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY16) && HAVE_DECL_BTN_TRIGGER_HAPPY16)
+  XLAT(BTN_TRIGGER_HAPPY16),
+#endif
+#if defined(BTN_TRIGGER_HAPPY17) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY17) && HAVE_DECL_BTN_TRIGGER_HAPPY17)
+  XLAT(BTN_TRIGGER_HAPPY17),
+#endif
+#if defined(BTN_TRIGGER_HAPPY18) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY18) && HAVE_DECL_BTN_TRIGGER_HAPPY18)
+  XLAT(BTN_TRIGGER_HAPPY18),
+#endif
+#if defined(BTN_TRIGGER_HAPPY19) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY19) && HAVE_DECL_BTN_TRIGGER_HAPPY19)
+  XLAT(BTN_TRIGGER_HAPPY19),
+#endif
+#if defined(BTN_TRIGGER_HAPPY20) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY20) && HAVE_DECL_BTN_TRIGGER_HAPPY20)
+  XLAT(BTN_TRIGGER_HAPPY20),
+#endif
+#if defined(BTN_TRIGGER_HAPPY21) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY21) && HAVE_DECL_BTN_TRIGGER_HAPPY21)
+  XLAT(BTN_TRIGGER_HAPPY21),
+#endif
+#if defined(BTN_TRIGGER_HAPPY22) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY22) && HAVE_DECL_BTN_TRIGGER_HAPPY22)
+  XLAT(BTN_TRIGGER_HAPPY22),
+#endif
+#if defined(BTN_TRIGGER_HAPPY23) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY23) && HAVE_DECL_BTN_TRIGGER_HAPPY23)
+  XLAT(BTN_TRIGGER_HAPPY23),
+#endif
+#if defined(BTN_TRIGGER_HAPPY24) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY24) && HAVE_DECL_BTN_TRIGGER_HAPPY24)
+  XLAT(BTN_TRIGGER_HAPPY24),
+#endif
+#if defined(BTN_TRIGGER_HAPPY25) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY25) && HAVE_DECL_BTN_TRIGGER_HAPPY25)
+  XLAT(BTN_TRIGGER_HAPPY25),
+#endif
+#if defined(BTN_TRIGGER_HAPPY26) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY26) && HAVE_DECL_BTN_TRIGGER_HAPPY26)
+  XLAT(BTN_TRIGGER_HAPPY26),
+#endif
+#if defined(BTN_TRIGGER_HAPPY27) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY27) && HAVE_DECL_BTN_TRIGGER_HAPPY27)
+  XLAT(BTN_TRIGGER_HAPPY27),
+#endif
+#if defined(BTN_TRIGGER_HAPPY28) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY28) && HAVE_DECL_BTN_TRIGGER_HAPPY28)
+  XLAT(BTN_TRIGGER_HAPPY28),
+#endif
+#if defined(BTN_TRIGGER_HAPPY29) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY29) && HAVE_DECL_BTN_TRIGGER_HAPPY29)
+  XLAT(BTN_TRIGGER_HAPPY29),
+#endif
+#if defined(BTN_TRIGGER_HAPPY30) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY30) && HAVE_DECL_BTN_TRIGGER_HAPPY30)
+  XLAT(BTN_TRIGGER_HAPPY30),
+#endif
+#if defined(BTN_TRIGGER_HAPPY31) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY31) && HAVE_DECL_BTN_TRIGGER_HAPPY31)
+  XLAT(BTN_TRIGGER_HAPPY31),
+#endif
+#if defined(BTN_TRIGGER_HAPPY32) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY32) && HAVE_DECL_BTN_TRIGGER_HAPPY32)
+  XLAT(BTN_TRIGGER_HAPPY32),
+#endif
+#if defined(BTN_TRIGGER_HAPPY33) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY33) && HAVE_DECL_BTN_TRIGGER_HAPPY33)
+  XLAT(BTN_TRIGGER_HAPPY33),
+#endif
+#if defined(BTN_TRIGGER_HAPPY34) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY34) && HAVE_DECL_BTN_TRIGGER_HAPPY34)
+  XLAT(BTN_TRIGGER_HAPPY34),
+#endif
+#if defined(BTN_TRIGGER_HAPPY35) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY35) && HAVE_DECL_BTN_TRIGGER_HAPPY35)
+  XLAT(BTN_TRIGGER_HAPPY35),
+#endif
+#if defined(BTN_TRIGGER_HAPPY36) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY36) && HAVE_DECL_BTN_TRIGGER_HAPPY36)
+  XLAT(BTN_TRIGGER_HAPPY36),
+#endif
+#if defined(BTN_TRIGGER_HAPPY37) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY37) && HAVE_DECL_BTN_TRIGGER_HAPPY37)
+  XLAT(BTN_TRIGGER_HAPPY37),
+#endif
+#if defined(BTN_TRIGGER_HAPPY38) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY38) && HAVE_DECL_BTN_TRIGGER_HAPPY38)
+  XLAT(BTN_TRIGGER_HAPPY38),
+#endif
+#if defined(BTN_TRIGGER_HAPPY39) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY39) && HAVE_DECL_BTN_TRIGGER_HAPPY39)
+  XLAT(BTN_TRIGGER_HAPPY39),
+#endif
+#if defined(BTN_TRIGGER_HAPPY40) || (defined(HAVE_DECL_BTN_TRIGGER_HAPPY40) && HAVE_DECL_BTN_TRIGGER_HAPPY40)
+  XLAT(BTN_TRIGGER_HAPPY40),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_keycode.in b/strace/xlat/evdev_keycode.in
new file mode 100644
index 0000000..15c829a
--- /dev/null
+++ b/strace/xlat/evdev_keycode.in
@@ -0,0 +1,595 @@
+KEY_RESERVED
+KEY_ESC
+KEY_1
+KEY_2
+KEY_3
+KEY_4
+KEY_5
+KEY_6
+KEY_7
+KEY_8
+KEY_9
+KEY_0
+KEY_MINUS
+KEY_EQUAL
+KEY_BACKSPACE
+KEY_TAB
+KEY_Q
+KEY_W
+KEY_E
+KEY_R
+KEY_T
+KEY_Y
+KEY_U
+KEY_I
+KEY_O
+KEY_P
+KEY_LEFTBRACE
+KEY_RIGHTBRACE
+KEY_ENTER
+KEY_LEFTCTRL
+KEY_A
+KEY_S
+KEY_D
+KEY_F
+KEY_G
+KEY_H
+KEY_J
+KEY_K
+KEY_L
+KEY_SEMICOLON
+KEY_APOSTROPHE
+KEY_GRAVE
+KEY_LEFTSHIFT
+KEY_BACKSLASH
+KEY_Z
+KEY_X
+KEY_C
+KEY_V
+KEY_B
+KEY_N
+KEY_M
+KEY_COMMA
+KEY_DOT
+KEY_SLASH
+KEY_RIGHTSHIFT
+KEY_KPASTERISK
+KEY_LEFTALT
+KEY_SPACE
+KEY_CAPSLOCK
+KEY_F1
+KEY_F2
+KEY_F3
+KEY_F4
+KEY_F5
+KEY_F6
+KEY_F7
+KEY_F8
+KEY_F9
+KEY_F10
+KEY_NUMLOCK
+KEY_SCROLLLOCK
+KEY_KP7
+KEY_KP8
+KEY_KP9
+KEY_KPMINUS
+KEY_KP4
+KEY_KP5
+KEY_KP6
+KEY_KPPLUS
+KEY_KP1
+KEY_KP2
+KEY_KP3
+KEY_KP0
+KEY_KPDOT
+
+KEY_ZENKAKUHANKAKU
+KEY_102ND
+KEY_F11
+KEY_F12
+KEY_RO
+KEY_KATAKANA
+KEY_HIRAGANA
+KEY_HENKAN
+KEY_KATAKANAHIRAGANA
+KEY_MUHENKAN
+KEY_KPJPCOMMA
+KEY_KPENTER
+KEY_RIGHTCTRL
+KEY_KPSLASH
+KEY_SYSRQ
+KEY_RIGHTALT
+KEY_LINEFEED
+KEY_HOME
+KEY_UP
+KEY_PAGEUP
+KEY_LEFT
+KEY_RIGHT
+KEY_END
+KEY_DOWN
+KEY_PAGEDOWN
+KEY_INSERT
+KEY_DELETE
+KEY_MACRO
+KEY_MUTE
+KEY_VOLUMEDOWN
+KEY_VOLUMEUP
+KEY_POWER
+KEY_KPEQUAL
+KEY_KPPLUSMINUS
+KEY_PAUSE
+KEY_SCALE
+
+KEY_KPCOMMA
+KEY_HANGEUL
+KEY_HANGUEL
+KEY_HANJA
+KEY_YEN
+KEY_LEFTMETA
+KEY_RIGHTMETA
+KEY_COMPOSE
+
+KEY_STOP
+KEY_AGAIN
+KEY_PROPS
+KEY_UNDO
+KEY_FRONT
+KEY_COPY
+KEY_OPEN
+KEY_PASTE
+KEY_FIND
+KEY_CUT
+KEY_HELP
+KEY_MENU
+KEY_CALC
+KEY_SETUP
+KEY_SLEEP
+KEY_WAKEUP
+KEY_FILE
+KEY_SENDFILE
+KEY_DELETEFILE
+KEY_XFER
+KEY_PROG1
+KEY_PROG2
+KEY_WWW
+KEY_MSDOS
+KEY_COFFEE
+KEY_ROTATE_DISPLAY
+KEY_DIRECTION
+KEY_CYCLEWINDOWS
+KEY_MAIL
+KEY_BOOKMARKS
+KEY_COMPUTER
+KEY_BACK
+KEY_FORWARD
+KEY_CLOSECD
+KEY_EJECTCD
+KEY_EJECTCLOSECD
+KEY_NEXTSONG
+KEY_PLAYPAUSE
+KEY_PREVIOUSSONG
+KEY_STOPCD
+KEY_RECORD
+KEY_REWIND
+KEY_PHONE
+KEY_ISO
+KEY_CONFIG
+KEY_HOMEPAGE
+KEY_REFRESH
+KEY_EXIT
+KEY_MOVE
+KEY_EDIT
+KEY_SCROLLUP
+KEY_SCROLLDOWN
+KEY_KPLEFTPAREN
+KEY_KPRIGHTPAREN
+KEY_NEW
+KEY_REDO
+
+KEY_F13
+KEY_F14
+KEY_F15
+KEY_F16
+KEY_F17
+KEY_F18
+KEY_F19
+KEY_F20
+KEY_F21
+KEY_F22
+KEY_F23
+KEY_F24
+
+KEY_PLAYCD
+KEY_PAUSECD
+KEY_PROG3
+KEY_PROG4
+KEY_DASHBOARD
+KEY_SUSPEND
+KEY_CLOSE
+KEY_PLAY
+KEY_FASTFORWARD
+KEY_BASSBOOST
+KEY_PRINT
+KEY_HP
+KEY_CAMERA
+KEY_SOUND
+KEY_QUESTION
+KEY_EMAIL
+KEY_CHAT
+KEY_SEARCH
+KEY_CONNECT
+KEY_FINANCE
+KEY_SPORT
+KEY_SHOP
+KEY_ALTERASE
+KEY_CANCEL
+KEY_BRIGHTNESSDOWN
+KEY_BRIGHTNESSUP
+KEY_MEDIA
+
+KEY_SWITCHVIDEOMODE
+
+KEY_KBDILLUMTOGGLE
+KEY_KBDILLUMDOWN
+KEY_KBDILLUMUP
+
+KEY_SEND
+KEY_REPLY
+KEY_FORWARDMAIL
+KEY_SAVE
+KEY_DOCUMENTS
+
+KEY_BATTERY
+
+KEY_BLUETOOTH
+KEY_WLAN
+KEY_UWB
+
+KEY_UNKNOWN
+
+KEY_VIDEO_NEXT
+KEY_VIDEO_PREV
+KEY_BRIGHTNESS_CYCLE
+KEY_BRIGHTNESS_AUTO
+KEY_BRIGHTNESS_ZERO
+KEY_DISPLAY_OFF
+
+KEY_WWAN
+KEY_WIMAX
+KEY_RFKILL
+
+KEY_MICMUTE
+
+BTN_0
+BTN_1
+BTN_2
+BTN_3
+BTN_4
+BTN_5
+BTN_6
+BTN_7
+BTN_8
+BTN_9
+
+BTN_MOUSE
+BTN_LEFT
+BTN_RIGHT
+BTN_MIDDLE
+BTN_SIDE
+BTN_EXTRA
+BTN_FORWARD
+BTN_BACK
+BTN_TASK
+
+BTN_JOYSTICK
+BTN_TRIGGER
+BTN_THUMB
+BTN_THUMB2
+BTN_TOP
+BTN_TOP2
+BTN_PINKIE
+BTN_BASE
+BTN_BASE2
+BTN_BASE3
+BTN_BASE4
+BTN_BASE5
+BTN_BASE6
+BTN_DEAD
+
+BTN_GAMEPAD
+BTN_SOUTH
+BTN_A
+BTN_EAST
+BTN_B
+BTN_C
+BTN_NORTH
+BTN_X
+BTN_WEST
+BTN_Y
+BTN_Z
+BTN_TL
+BTN_TR
+BTN_TL2
+BTN_TR2
+BTN_SELECT
+BTN_START
+BTN_MODE
+BTN_THUMBL
+BTN_THUMBR
+
+BTN_DIGI
+BTN_TOOL_PEN
+BTN_TOOL_RUBBER
+BTN_TOOL_BRUSH
+BTN_TOOL_PENCIL
+BTN_TOOL_AIRBRUSH
+BTN_TOOL_FINGER
+BTN_TOOL_MOUSE
+BTN_TOOL_LENS
+BTN_TOOL_QUINTTAP
+BTN_TOUCH
+BTN_STYLUS
+BTN_STYLUS2
+BTN_TOOL_DOUBLETAP
+BTN_TOOL_TRIPLETAP
+BTN_TOOL_QUADTAP
+
+BTN_WHEEL
+BTN_GEAR_DOWN
+BTN_GEAR_UP
+
+KEY_OK
+KEY_SELECT
+KEY_GOTO
+KEY_CLEAR
+KEY_POWER2
+KEY_OPTION
+KEY_INFO
+KEY_TIME
+KEY_VENDOR
+KEY_ARCHIVE
+KEY_PROGRAM
+KEY_CHANNEL
+KEY_FAVORITES
+KEY_EPG
+KEY_PVR
+KEY_MHP
+KEY_LANGUAGE
+KEY_TITLE
+KEY_SUBTITLE
+KEY_ANGLE
+KEY_ZOOM
+KEY_MODE
+KEY_KEYBOARD
+KEY_SCREEN
+KEY_PC
+KEY_TV
+KEY_TV2
+KEY_VCR
+KEY_VCR2
+KEY_SAT
+KEY_SAT2
+KEY_CD
+KEY_TAPE
+KEY_RADIO
+KEY_TUNER
+KEY_PLAYER
+KEY_TEXT
+KEY_DVD
+KEY_AUX
+KEY_MP3
+KEY_AUDIO
+KEY_VIDEO
+KEY_DIRECTORY
+KEY_LIST
+KEY_MEMO
+KEY_CALENDAR
+KEY_RED
+KEY_GREEN
+KEY_YELLOW
+KEY_BLUE
+KEY_CHANNELUP
+KEY_CHANNELDOWN
+KEY_FIRST
+KEY_LAST
+KEY_AB
+KEY_NEXT
+KEY_RESTART
+KEY_SLOW
+KEY_SHUFFLE
+KEY_BREAK
+KEY_PREVIOUS
+KEY_DIGITS
+KEY_TEEN
+KEY_TWEN
+KEY_VIDEOPHONE
+KEY_GAMES
+KEY_ZOOMIN
+KEY_ZOOMOUT
+KEY_ZOOMRESET
+KEY_WORDPROCESSOR
+KEY_EDITOR
+KEY_SPREADSHEET
+KEY_GRAPHICSEDITOR
+KEY_PRESENTATION
+KEY_DATABASE
+KEY_NEWS
+KEY_VOICEMAIL
+KEY_ADDRESSBOOK
+KEY_MESSENGER
+KEY_DISPLAYTOGGLE
+KEY_BRIGHTNESS_TOGGLE
+KEY_SPELLCHECK
+KEY_LOGOFF
+
+KEY_DOLLAR
+KEY_EURO
+
+KEY_FRAMEBACK
+KEY_FRAMEFORWARD
+KEY_CONTEXT_MENU
+KEY_MEDIA_REPEAT
+KEY_10CHANNELSUP
+KEY_10CHANNELSDOWN
+KEY_IMAGES
+
+KEY_DEL_EOL
+KEY_DEL_EOS
+KEY_INS_LINE
+KEY_DEL_LINE
+
+KEY_FN
+KEY_FN_ESC
+KEY_FN_F1
+KEY_FN_F2
+KEY_FN_F3
+KEY_FN_F4
+KEY_FN_F5
+KEY_FN_F6
+KEY_FN_F7
+KEY_FN_F8
+KEY_FN_F9
+KEY_FN_F10
+KEY_FN_F11
+KEY_FN_F12
+KEY_FN_1
+KEY_FN_2
+KEY_FN_D
+KEY_FN_E
+KEY_FN_F
+KEY_FN_S
+KEY_FN_B
+
+KEY_BRL_DOT1
+KEY_BRL_DOT2
+KEY_BRL_DOT3
+KEY_BRL_DOT4
+KEY_BRL_DOT5
+KEY_BRL_DOT6
+KEY_BRL_DOT7
+KEY_BRL_DOT8
+KEY_BRL_DOT9
+KEY_BRL_DOT10
+
+KEY_NUMERIC_0
+KEY_NUMERIC_1
+KEY_NUMERIC_2
+KEY_NUMERIC_3
+KEY_NUMERIC_4
+KEY_NUMERIC_5
+KEY_NUMERIC_6
+KEY_NUMERIC_7
+KEY_NUMERIC_8
+KEY_NUMERIC_9
+KEY_NUMERIC_STAR
+KEY_NUMERIC_POUND
+KEY_NUMERIC_A
+KEY_NUMERIC_B
+KEY_NUMERIC_C
+KEY_NUMERIC_D
+
+KEY_CAMERA_FOCUS
+KEY_WPS_BUTTON
+
+KEY_TOUCHPAD_TOGGLE
+KEY_TOUCHPAD_ON
+KEY_TOUCHPAD_OFF
+
+KEY_CAMERA_ZOOMIN
+KEY_CAMERA_ZOOMOUT
+KEY_CAMERA_UP
+KEY_CAMERA_DOWN
+KEY_CAMERA_LEFT
+KEY_CAMERA_RIGHT
+
+KEY_ATTENDANT_ON
+KEY_ATTENDANT_OFF
+KEY_ATTENDANT_TOGGLE
+KEY_LIGHTS_TOGGLE
+
+BTN_DPAD_UP
+BTN_DPAD_DOWN
+BTN_DPAD_LEFT
+BTN_DPAD_RIGHT
+
+KEY_ALS_TOGGLE
+
+KEY_BUTTONCONFIG
+KEY_TASKMANAGER
+KEY_JOURNAL
+KEY_CONTROLPANEL
+KEY_APPSELECT
+KEY_SCREENSAVER
+KEY_VOICECOMMAND
+
+KEY_BRIGHTNESS_MIN
+KEY_BRIGHTNESS_MAX
+
+KEY_KBDINPUTASSIST_PREV
+KEY_KBDINPUTASSIST_NEXT
+KEY_KBDINPUTASSIST_PREVGROUP
+KEY_KBDINPUTASSIST_NEXTGROUP
+KEY_KBDINPUTASSIST_ACCEPT
+KEY_KBDINPUTASSIST_CANCEL
+
+KEY_RIGHT_UP
+KEY_RIGHT_DOWN
+KEY_LEFT_UP
+KEY_LEFT_DOWN
+
+KEY_ROOT_MENU
+KEY_MEDIA_TOP_MENU
+KEY_NUMERIC_11
+KEY_NUMERIC_12
+
+KEY_AUDIO_DESC
+KEY_3D_MODE
+KEY_NEXT_FAVORITE
+KEY_STOP_RECORD
+KEY_PAUSE_RECORD
+KEY_VOD
+KEY_UNMUTE
+KEY_FASTREVERSE
+KEY_SLOWREVERSE
+
+BTN_TRIGGER_HAPPY
+BTN_TRIGGER_HAPPY1
+BTN_TRIGGER_HAPPY2
+BTN_TRIGGER_HAPPY3
+BTN_TRIGGER_HAPPY4
+BTN_TRIGGER_HAPPY5
+BTN_TRIGGER_HAPPY6
+BTN_TRIGGER_HAPPY7
+BTN_TRIGGER_HAPPY8
+BTN_TRIGGER_HAPPY9
+BTN_TRIGGER_HAPPY10
+BTN_TRIGGER_HAPPY11
+BTN_TRIGGER_HAPPY12
+BTN_TRIGGER_HAPPY13
+BTN_TRIGGER_HAPPY14
+BTN_TRIGGER_HAPPY15
+BTN_TRIGGER_HAPPY16
+BTN_TRIGGER_HAPPY17
+BTN_TRIGGER_HAPPY18
+BTN_TRIGGER_HAPPY19
+BTN_TRIGGER_HAPPY20
+BTN_TRIGGER_HAPPY21
+BTN_TRIGGER_HAPPY22
+BTN_TRIGGER_HAPPY23
+BTN_TRIGGER_HAPPY24
+BTN_TRIGGER_HAPPY25
+BTN_TRIGGER_HAPPY26
+BTN_TRIGGER_HAPPY27
+BTN_TRIGGER_HAPPY28
+BTN_TRIGGER_HAPPY29
+BTN_TRIGGER_HAPPY30
+BTN_TRIGGER_HAPPY31
+BTN_TRIGGER_HAPPY32
+BTN_TRIGGER_HAPPY33
+BTN_TRIGGER_HAPPY34
+BTN_TRIGGER_HAPPY35
+BTN_TRIGGER_HAPPY36
+BTN_TRIGGER_HAPPY37
+BTN_TRIGGER_HAPPY38
+BTN_TRIGGER_HAPPY39
+BTN_TRIGGER_HAPPY40
diff --git a/strace/xlat/evdev_leds.h b/strace/xlat/evdev_leds.h
new file mode 100644
index 0000000..8f2b24c
--- /dev/null
+++ b/strace/xlat/evdev_leds.h
@@ -0,0 +1,49 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_leds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_leds[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_leds[] = {
+#if defined(LED_NUML) || (defined(HAVE_DECL_LED_NUML) && HAVE_DECL_LED_NUML)
+  XLAT(LED_NUML),
+#endif
+#if defined(LED_CAPSL) || (defined(HAVE_DECL_LED_CAPSL) && HAVE_DECL_LED_CAPSL)
+  XLAT(LED_CAPSL),
+#endif
+#if defined(LED_SCROLLL) || (defined(HAVE_DECL_LED_SCROLLL) && HAVE_DECL_LED_SCROLLL)
+  XLAT(LED_SCROLLL),
+#endif
+#if defined(LED_COMPOSE) || (defined(HAVE_DECL_LED_COMPOSE) && HAVE_DECL_LED_COMPOSE)
+  XLAT(LED_COMPOSE),
+#endif
+#if defined(LED_KANA) || (defined(HAVE_DECL_LED_KANA) && HAVE_DECL_LED_KANA)
+  XLAT(LED_KANA),
+#endif
+#if defined(LED_SLEEP) || (defined(HAVE_DECL_LED_SLEEP) && HAVE_DECL_LED_SLEEP)
+  XLAT(LED_SLEEP),
+#endif
+#if defined(LED_SUSPEND) || (defined(HAVE_DECL_LED_SUSPEND) && HAVE_DECL_LED_SUSPEND)
+  XLAT(LED_SUSPEND),
+#endif
+#if defined(LED_MUTE) || (defined(HAVE_DECL_LED_MUTE) && HAVE_DECL_LED_MUTE)
+  XLAT(LED_MUTE),
+#endif
+#if defined(LED_MISC) || (defined(HAVE_DECL_LED_MISC) && HAVE_DECL_LED_MISC)
+  XLAT(LED_MISC),
+#endif
+#if defined(LED_MAIL) || (defined(HAVE_DECL_LED_MAIL) && HAVE_DECL_LED_MAIL)
+  XLAT(LED_MAIL),
+#endif
+#if defined(LED_CHARGING) || (defined(HAVE_DECL_LED_CHARGING) && HAVE_DECL_LED_CHARGING)
+  XLAT(LED_CHARGING),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_leds.in b/strace/xlat/evdev_leds.in
new file mode 100644
index 0000000..c085ed3
--- /dev/null
+++ b/strace/xlat/evdev_leds.in
@@ -0,0 +1,11 @@
+LED_NUML
+LED_CAPSL
+LED_SCROLLL
+LED_COMPOSE
+LED_KANA
+LED_SLEEP
+LED_SUSPEND
+LED_MUTE
+LED_MISC
+LED_MAIL
+LED_CHARGING
diff --git a/strace/xlat/evdev_misc.h b/strace/xlat/evdev_misc.h
new file mode 100644
index 0000000..8a363d3
--- /dev/null
+++ b/strace/xlat/evdev_misc.h
@@ -0,0 +1,34 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_misc.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_misc[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_misc[] = {
+#if defined(MSC_SERIAL) || (defined(HAVE_DECL_MSC_SERIAL) && HAVE_DECL_MSC_SERIAL)
+  XLAT(MSC_SERIAL),
+#endif
+#if defined(MSC_PULSELED) || (defined(HAVE_DECL_MSC_PULSELED) && HAVE_DECL_MSC_PULSELED)
+  XLAT(MSC_PULSELED),
+#endif
+#if defined(MSC_GESTURE) || (defined(HAVE_DECL_MSC_GESTURE) && HAVE_DECL_MSC_GESTURE)
+  XLAT(MSC_GESTURE),
+#endif
+#if defined(MSC_RAW) || (defined(HAVE_DECL_MSC_RAW) && HAVE_DECL_MSC_RAW)
+  XLAT(MSC_RAW),
+#endif
+#if defined(MSC_SCAN) || (defined(HAVE_DECL_MSC_SCAN) && HAVE_DECL_MSC_SCAN)
+  XLAT(MSC_SCAN),
+#endif
+#if defined(MSC_TIMESTAMP) || (defined(HAVE_DECL_MSC_TIMESTAMP) && HAVE_DECL_MSC_TIMESTAMP)
+  XLAT(MSC_TIMESTAMP),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_misc.in b/strace/xlat/evdev_misc.in
new file mode 100644
index 0000000..385ee4d
--- /dev/null
+++ b/strace/xlat/evdev_misc.in
@@ -0,0 +1,6 @@
+MSC_SERIAL
+MSC_PULSELED
+MSC_GESTURE
+MSC_RAW
+MSC_SCAN
+MSC_TIMESTAMP
diff --git a/strace/xlat/evdev_mtslots.h b/strace/xlat/evdev_mtslots.h
new file mode 100644
index 0000000..4379f37
--- /dev/null
+++ b/strace/xlat/evdev_mtslots.h
@@ -0,0 +1,61 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_mtslots.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_mtslots[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_mtslots[] = {
+#if defined(ABS_MT_SLOT) || (defined(HAVE_DECL_ABS_MT_SLOT) && HAVE_DECL_ABS_MT_SLOT)
+  XLAT(ABS_MT_SLOT),
+#endif
+#if defined(ABS_MT_TOUCH_MAJOR) || (defined(HAVE_DECL_ABS_MT_TOUCH_MAJOR) && HAVE_DECL_ABS_MT_TOUCH_MAJOR)
+  XLAT(ABS_MT_TOUCH_MAJOR),
+#endif
+#if defined(ABS_MT_TOUCH_MINOR) || (defined(HAVE_DECL_ABS_MT_TOUCH_MINOR) && HAVE_DECL_ABS_MT_TOUCH_MINOR)
+  XLAT(ABS_MT_TOUCH_MINOR),
+#endif
+#if defined(ABS_MT_WIDTH_MAJOR) || (defined(HAVE_DECL_ABS_MT_WIDTH_MAJOR) && HAVE_DECL_ABS_MT_WIDTH_MAJOR)
+  XLAT(ABS_MT_WIDTH_MAJOR),
+#endif
+#if defined(ABS_MT_WIDTH_MINOR) || (defined(HAVE_DECL_ABS_MT_WIDTH_MINOR) && HAVE_DECL_ABS_MT_WIDTH_MINOR)
+  XLAT(ABS_MT_WIDTH_MINOR),
+#endif
+#if defined(ABS_MT_ORIENTATION) || (defined(HAVE_DECL_ABS_MT_ORIENTATION) && HAVE_DECL_ABS_MT_ORIENTATION)
+  XLAT(ABS_MT_ORIENTATION),
+#endif
+#if defined(ABS_MT_POSITION_X) || (defined(HAVE_DECL_ABS_MT_POSITION_X) && HAVE_DECL_ABS_MT_POSITION_X)
+  XLAT(ABS_MT_POSITION_X),
+#endif
+#if defined(ABS_MT_POSITION_Y) || (defined(HAVE_DECL_ABS_MT_POSITION_Y) && HAVE_DECL_ABS_MT_POSITION_Y)
+  XLAT(ABS_MT_POSITION_Y),
+#endif
+#if defined(ABS_MT_TOOL_TYPE) || (defined(HAVE_DECL_ABS_MT_TOOL_TYPE) && HAVE_DECL_ABS_MT_TOOL_TYPE)
+  XLAT(ABS_MT_TOOL_TYPE),
+#endif
+#if defined(ABS_MT_BLOB_ID) || (defined(HAVE_DECL_ABS_MT_BLOB_ID) && HAVE_DECL_ABS_MT_BLOB_ID)
+  XLAT(ABS_MT_BLOB_ID),
+#endif
+#if defined(ABS_MT_TRACKING_ID) || (defined(HAVE_DECL_ABS_MT_TRACKING_ID) && HAVE_DECL_ABS_MT_TRACKING_ID)
+  XLAT(ABS_MT_TRACKING_ID),
+#endif
+#if defined(ABS_MT_PRESSURE) || (defined(HAVE_DECL_ABS_MT_PRESSURE) && HAVE_DECL_ABS_MT_PRESSURE)
+  XLAT(ABS_MT_PRESSURE),
+#endif
+#if defined(ABS_MT_DISTANCE) || (defined(HAVE_DECL_ABS_MT_DISTANCE) && HAVE_DECL_ABS_MT_DISTANCE)
+  XLAT(ABS_MT_DISTANCE),
+#endif
+#if defined(ABS_MT_TOOL_X) || (defined(HAVE_DECL_ABS_MT_TOOL_X) && HAVE_DECL_ABS_MT_TOOL_X)
+  XLAT(ABS_MT_TOOL_X),
+#endif
+#if defined(ABS_MT_TOOL_Y) || (defined(HAVE_DECL_ABS_MT_TOOL_Y) && HAVE_DECL_ABS_MT_TOOL_Y)
+  XLAT(ABS_MT_TOOL_Y),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_mtslots.in b/strace/xlat/evdev_mtslots.in
new file mode 100644
index 0000000..eedf688
--- /dev/null
+++ b/strace/xlat/evdev_mtslots.in
@@ -0,0 +1,15 @@
+ABS_MT_SLOT
+ABS_MT_TOUCH_MAJOR
+ABS_MT_TOUCH_MINOR
+ABS_MT_WIDTH_MAJOR
+ABS_MT_WIDTH_MINOR
+ABS_MT_ORIENTATION
+ABS_MT_POSITION_X
+ABS_MT_POSITION_Y
+ABS_MT_TOOL_TYPE
+ABS_MT_BLOB_ID
+ABS_MT_TRACKING_ID
+ABS_MT_PRESSURE
+ABS_MT_DISTANCE
+ABS_MT_TOOL_X
+ABS_MT_TOOL_Y
diff --git a/strace/xlat/evdev_prop.h b/strace/xlat/evdev_prop.h
new file mode 100644
index 0000000..9f4f336
--- /dev/null
+++ b/strace/xlat/evdev_prop.h
@@ -0,0 +1,37 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_prop.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_prop[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_prop[] = {
+#if defined(INPUT_PROP_POINTER) || (defined(HAVE_DECL_INPUT_PROP_POINTER) && HAVE_DECL_INPUT_PROP_POINTER)
+  XLAT(INPUT_PROP_POINTER),
+#endif
+#if defined(INPUT_PROP_DIRECT) || (defined(HAVE_DECL_INPUT_PROP_DIRECT) && HAVE_DECL_INPUT_PROP_DIRECT)
+  XLAT(INPUT_PROP_DIRECT),
+#endif
+#if defined(INPUT_PROP_BUTTONPAD) || (defined(HAVE_DECL_INPUT_PROP_BUTTONPAD) && HAVE_DECL_INPUT_PROP_BUTTONPAD)
+  XLAT(INPUT_PROP_BUTTONPAD),
+#endif
+#if defined(INPUT_PROP_SEMI_MT) || (defined(HAVE_DECL_INPUT_PROP_SEMI_MT) && HAVE_DECL_INPUT_PROP_SEMI_MT)
+  XLAT(INPUT_PROP_SEMI_MT),
+#endif
+#if defined(INPUT_PROP_TOPBUTTONPAD) || (defined(HAVE_DECL_INPUT_PROP_TOPBUTTONPAD) && HAVE_DECL_INPUT_PROP_TOPBUTTONPAD)
+  XLAT(INPUT_PROP_TOPBUTTONPAD),
+#endif
+#if defined(INPUT_PROP_POINTING_STICK) || (defined(HAVE_DECL_INPUT_PROP_POINTING_STICK) && HAVE_DECL_INPUT_PROP_POINTING_STICK)
+  XLAT(INPUT_PROP_POINTING_STICK),
+#endif
+#if defined(INPUT_PROP_ACCELEROMETER) || (defined(HAVE_DECL_INPUT_PROP_ACCELEROMETER) && HAVE_DECL_INPUT_PROP_ACCELEROMETER)
+  XLAT(INPUT_PROP_ACCELEROMETER),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_prop.in b/strace/xlat/evdev_prop.in
new file mode 100644
index 0000000..b659000
--- /dev/null
+++ b/strace/xlat/evdev_prop.in
@@ -0,0 +1,7 @@
+INPUT_PROP_POINTER
+INPUT_PROP_DIRECT
+INPUT_PROP_BUTTONPAD
+INPUT_PROP_SEMI_MT
+INPUT_PROP_TOPBUTTONPAD
+INPUT_PROP_POINTING_STICK
+INPUT_PROP_ACCELEROMETER
diff --git a/strace/xlat/evdev_relative_axes.h b/strace/xlat/evdev_relative_axes.h
new file mode 100644
index 0000000..b3b9b9a
--- /dev/null
+++ b/strace/xlat/evdev_relative_axes.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_relative_axes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_relative_axes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_relative_axes[] = {
+#if defined(REL_X) || (defined(HAVE_DECL_REL_X) && HAVE_DECL_REL_X)
+  XLAT(REL_X),
+#endif
+#if defined(REL_Y) || (defined(HAVE_DECL_REL_Y) && HAVE_DECL_REL_Y)
+  XLAT(REL_Y),
+#endif
+#if defined(REL_Z) || (defined(HAVE_DECL_REL_Z) && HAVE_DECL_REL_Z)
+  XLAT(REL_Z),
+#endif
+#if defined(REL_RX) || (defined(HAVE_DECL_REL_RX) && HAVE_DECL_REL_RX)
+  XLAT(REL_RX),
+#endif
+#if defined(REL_RY) || (defined(HAVE_DECL_REL_RY) && HAVE_DECL_REL_RY)
+  XLAT(REL_RY),
+#endif
+#if defined(REL_RZ) || (defined(HAVE_DECL_REL_RZ) && HAVE_DECL_REL_RZ)
+  XLAT(REL_RZ),
+#endif
+#if defined(REL_HWHEEL) || (defined(HAVE_DECL_REL_HWHEEL) && HAVE_DECL_REL_HWHEEL)
+  XLAT(REL_HWHEEL),
+#endif
+#if defined(REL_DIAL) || (defined(HAVE_DECL_REL_DIAL) && HAVE_DECL_REL_DIAL)
+  XLAT(REL_DIAL),
+#endif
+#if defined(REL_WHEEL) || (defined(HAVE_DECL_REL_WHEEL) && HAVE_DECL_REL_WHEEL)
+  XLAT(REL_WHEEL),
+#endif
+#if defined(REL_MISC) || (defined(HAVE_DECL_REL_MISC) && HAVE_DECL_REL_MISC)
+  XLAT(REL_MISC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_relative_axes.in b/strace/xlat/evdev_relative_axes.in
new file mode 100644
index 0000000..7158d47
--- /dev/null
+++ b/strace/xlat/evdev_relative_axes.in
@@ -0,0 +1,10 @@
+REL_X
+REL_Y
+REL_Z
+REL_RX
+REL_RY
+REL_RZ
+REL_HWHEEL
+REL_DIAL
+REL_WHEEL
+REL_MISC
diff --git a/strace/xlat/evdev_snd.h b/strace/xlat/evdev_snd.h
new file mode 100644
index 0000000..e03885f
--- /dev/null
+++ b/strace/xlat/evdev_snd.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_snd.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_snd[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_snd[] = {
+#if defined(SND_CLICK) || (defined(HAVE_DECL_SND_CLICK) && HAVE_DECL_SND_CLICK)
+  XLAT(SND_CLICK),
+#endif
+#if defined(SND_BELL) || (defined(HAVE_DECL_SND_BELL) && HAVE_DECL_SND_BELL)
+  XLAT(SND_BELL),
+#endif
+#if defined(SND_TONE) || (defined(HAVE_DECL_SND_TONE) && HAVE_DECL_SND_TONE)
+  XLAT(SND_TONE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_snd.in b/strace/xlat/evdev_snd.in
new file mode 100644
index 0000000..eaebe3c
--- /dev/null
+++ b/strace/xlat/evdev_snd.in
@@ -0,0 +1,3 @@
+SND_CLICK
+SND_BELL
+SND_TONE
diff --git a/strace/xlat/evdev_switch.h b/strace/xlat/evdev_switch.h
new file mode 100644
index 0000000..fb8c2cf
--- /dev/null
+++ b/strace/xlat/evdev_switch.h
@@ -0,0 +1,64 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_switch.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_switch[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_switch[] = {
+#if defined(SW_LID) || (defined(HAVE_DECL_SW_LID) && HAVE_DECL_SW_LID)
+  XLAT(SW_LID),
+#endif
+#if defined(SW_TABLET_MODE) || (defined(HAVE_DECL_SW_TABLET_MODE) && HAVE_DECL_SW_TABLET_MODE)
+  XLAT(SW_TABLET_MODE),
+#endif
+#if defined(SW_HEADPHONE_INSERT) || (defined(HAVE_DECL_SW_HEADPHONE_INSERT) && HAVE_DECL_SW_HEADPHONE_INSERT)
+  XLAT(SW_HEADPHONE_INSERT),
+#endif
+#if defined(SW_RFKILL_ALL) || (defined(HAVE_DECL_SW_RFKILL_ALL) && HAVE_DECL_SW_RFKILL_ALL)
+  XLAT(SW_RFKILL_ALL),
+#endif
+#if defined(SW_RADIO) || (defined(HAVE_DECL_SW_RADIO) && HAVE_DECL_SW_RADIO)
+  XLAT(SW_RADIO),
+#endif
+#if defined(SW_MICROPHONE_INSERT) || (defined(HAVE_DECL_SW_MICROPHONE_INSERT) && HAVE_DECL_SW_MICROPHONE_INSERT)
+  XLAT(SW_MICROPHONE_INSERT),
+#endif
+#if defined(SW_DOCK) || (defined(HAVE_DECL_SW_DOCK) && HAVE_DECL_SW_DOCK)
+  XLAT(SW_DOCK),
+#endif
+#if defined(SW_LINEOUT_INSERT) || (defined(HAVE_DECL_SW_LINEOUT_INSERT) && HAVE_DECL_SW_LINEOUT_INSERT)
+  XLAT(SW_LINEOUT_INSERT),
+#endif
+#if defined(SW_JACK_PHYSICAL_INSERT) || (defined(HAVE_DECL_SW_JACK_PHYSICAL_INSERT) && HAVE_DECL_SW_JACK_PHYSICAL_INSERT)
+  XLAT(SW_JACK_PHYSICAL_INSERT),
+#endif
+#if defined(SW_VIDEOOUT_INSERT) || (defined(HAVE_DECL_SW_VIDEOOUT_INSERT) && HAVE_DECL_SW_VIDEOOUT_INSERT)
+  XLAT(SW_VIDEOOUT_INSERT),
+#endif
+#if defined(SW_CAMERA_LENS_COVER) || (defined(HAVE_DECL_SW_CAMERA_LENS_COVER) && HAVE_DECL_SW_CAMERA_LENS_COVER)
+  XLAT(SW_CAMERA_LENS_COVER),
+#endif
+#if defined(SW_KEYPAD_SLIDE) || (defined(HAVE_DECL_SW_KEYPAD_SLIDE) && HAVE_DECL_SW_KEYPAD_SLIDE)
+  XLAT(SW_KEYPAD_SLIDE),
+#endif
+#if defined(SW_FRONT_PROXIMITY) || (defined(HAVE_DECL_SW_FRONT_PROXIMITY) && HAVE_DECL_SW_FRONT_PROXIMITY)
+  XLAT(SW_FRONT_PROXIMITY),
+#endif
+#if defined(SW_ROTATE_LOCK) || (defined(HAVE_DECL_SW_ROTATE_LOCK) && HAVE_DECL_SW_ROTATE_LOCK)
+  XLAT(SW_ROTATE_LOCK),
+#endif
+#if defined(SW_LINEIN_INSERT) || (defined(HAVE_DECL_SW_LINEIN_INSERT) && HAVE_DECL_SW_LINEIN_INSERT)
+  XLAT(SW_LINEIN_INSERT),
+#endif
+#if defined(SW_MUTE_DEVICE) || (defined(HAVE_DECL_SW_MUTE_DEVICE) && HAVE_DECL_SW_MUTE_DEVICE)
+  XLAT(SW_MUTE_DEVICE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_switch.in b/strace/xlat/evdev_switch.in
new file mode 100644
index 0000000..381d838
--- /dev/null
+++ b/strace/xlat/evdev_switch.in
@@ -0,0 +1,16 @@
+SW_LID
+SW_TABLET_MODE
+SW_HEADPHONE_INSERT
+SW_RFKILL_ALL
+SW_RADIO
+SW_MICROPHONE_INSERT
+SW_DOCK
+SW_LINEOUT_INSERT
+SW_JACK_PHYSICAL_INSERT
+SW_VIDEOOUT_INSERT
+SW_CAMERA_LENS_COVER
+SW_KEYPAD_SLIDE
+SW_FRONT_PROXIMITY
+SW_ROTATE_LOCK
+SW_LINEIN_INSERT
+SW_MUTE_DEVICE
diff --git a/strace/xlat/evdev_sync.h b/strace/xlat/evdev_sync.h
new file mode 100644
index 0000000..2e53d78
--- /dev/null
+++ b/strace/xlat/evdev_sync.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/evdev_sync.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat evdev_sync[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat evdev_sync[] = {
+#if defined(SYN_REPORT) || (defined(HAVE_DECL_SYN_REPORT) && HAVE_DECL_SYN_REPORT)
+  XLAT(SYN_REPORT),
+#endif
+#if defined(SYN_CONFIG) || (defined(HAVE_DECL_SYN_CONFIG) && HAVE_DECL_SYN_CONFIG)
+  XLAT(SYN_CONFIG),
+#endif
+#if defined(SYN_MT_REPORT) || (defined(HAVE_DECL_SYN_MT_REPORT) && HAVE_DECL_SYN_MT_REPORT)
+  XLAT(SYN_MT_REPORT),
+#endif
+#if defined(SYN_DROPPED) || (defined(HAVE_DECL_SYN_DROPPED) && HAVE_DECL_SYN_DROPPED)
+  XLAT(SYN_DROPPED),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/evdev_sync.in b/strace/xlat/evdev_sync.in
new file mode 100644
index 0000000..39c2e4a
--- /dev/null
+++ b/strace/xlat/evdev_sync.in
@@ -0,0 +1,4 @@
+SYN_REPORT
+SYN_CONFIG
+SYN_MT_REPORT
+SYN_DROPPED
diff --git a/strace/xlat/f_owner_types.h b/strace/xlat/f_owner_types.h
new file mode 100644
index 0000000..611895a
--- /dev/null
+++ b/strace/xlat/f_owner_types.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/f_owner_types.in; do not edit. */
+#if !(defined(F_OWNER_TID) || (defined(HAVE_DECL_F_OWNER_TID) && HAVE_DECL_F_OWNER_TID))
+# define F_OWNER_TID 0
+#endif
+#if !(defined(F_OWNER_PID) || (defined(HAVE_DECL_F_OWNER_PID) && HAVE_DECL_F_OWNER_PID))
+# define F_OWNER_PID 1
+#endif
+#if !(defined(F_OWNER_PGRP) || (defined(HAVE_DECL_F_OWNER_PGRP) && HAVE_DECL_F_OWNER_PGRP))
+# define F_OWNER_PGRP 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat f_owner_types in mpers mode
+
+#else
+
+static
+const struct xlat f_owner_types[] = {
+ XLAT(F_OWNER_TID),
+ XLAT(F_OWNER_PID),
+ XLAT(F_OWNER_PGRP),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/f_owner_types.in b/strace/xlat/f_owner_types.in
new file mode 100644
index 0000000..2c8124d
--- /dev/null
+++ b/strace/xlat/f_owner_types.in
@@ -0,0 +1,3 @@
+F_OWNER_TID	0
+F_OWNER_PID	1
+F_OWNER_PGRP	2
diff --git a/strace/xlat/f_seals.h b/strace/xlat/f_seals.h
new file mode 100644
index 0000000..6efd079
--- /dev/null
+++ b/strace/xlat/f_seals.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/f_seals.in; do not edit. */
+#if !(defined(F_SEAL_SEAL) || (defined(HAVE_DECL_F_SEAL_SEAL) && HAVE_DECL_F_SEAL_SEAL))
+# define F_SEAL_SEAL 1
+#endif
+#if !(defined(F_SEAL_SHRINK) || (defined(HAVE_DECL_F_SEAL_SHRINK) && HAVE_DECL_F_SEAL_SHRINK))
+# define F_SEAL_SHRINK 2
+#endif
+#if !(defined(F_SEAL_GROW) || (defined(HAVE_DECL_F_SEAL_GROW) && HAVE_DECL_F_SEAL_GROW))
+# define F_SEAL_GROW 4
+#endif
+#if !(defined(F_SEAL_WRITE) || (defined(HAVE_DECL_F_SEAL_WRITE) && HAVE_DECL_F_SEAL_WRITE))
+# define F_SEAL_WRITE 8
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat f_seals in mpers mode
+
+#else
+
+static
+const struct xlat f_seals[] = {
+ XLAT(F_SEAL_SEAL),
+ XLAT(F_SEAL_SHRINK),
+ XLAT(F_SEAL_GROW),
+ XLAT(F_SEAL_WRITE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/f_seals.in b/strace/xlat/f_seals.in
new file mode 100644
index 0000000..7faad8f
--- /dev/null
+++ b/strace/xlat/f_seals.in
@@ -0,0 +1,4 @@
+F_SEAL_SEAL	1
+F_SEAL_SHRINK	2
+F_SEAL_GROW	4
+F_SEAL_WRITE	8
diff --git a/strace/xlat/falloc_flags.h b/strace/xlat/falloc_flags.h
new file mode 100644
index 0000000..0e34b47
--- /dev/null
+++ b/strace/xlat/falloc_flags.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/falloc_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat falloc_flags in mpers mode
+
+#else
+
+static
+const struct xlat falloc_flags[] = {
+#if defined(FALLOC_FL_KEEP_SIZE) || (defined(HAVE_DECL_FALLOC_FL_KEEP_SIZE) && HAVE_DECL_FALLOC_FL_KEEP_SIZE)
+  XLAT(FALLOC_FL_KEEP_SIZE),
+#endif
+#if defined(FALLOC_FL_PUNCH_HOLE) || (defined(HAVE_DECL_FALLOC_FL_PUNCH_HOLE) && HAVE_DECL_FALLOC_FL_PUNCH_HOLE)
+  XLAT(FALLOC_FL_PUNCH_HOLE),
+#endif
+#if defined(FALLOC_FL_NO_HIDE_STALE) || (defined(HAVE_DECL_FALLOC_FL_NO_HIDE_STALE) && HAVE_DECL_FALLOC_FL_NO_HIDE_STALE)
+  XLAT(FALLOC_FL_NO_HIDE_STALE),
+#endif
+#if defined(FALLOC_FL_COLLAPSE_RANGE) || (defined(HAVE_DECL_FALLOC_FL_COLLAPSE_RANGE) && HAVE_DECL_FALLOC_FL_COLLAPSE_RANGE)
+  XLAT(FALLOC_FL_COLLAPSE_RANGE),
+#endif
+#if defined(FALLOC_FL_ZERO_RANGE) || (defined(HAVE_DECL_FALLOC_FL_ZERO_RANGE) && HAVE_DECL_FALLOC_FL_ZERO_RANGE)
+  XLAT(FALLOC_FL_ZERO_RANGE),
+#endif
+#if defined(FALLOC_FL_INSERT_RANGE) || (defined(HAVE_DECL_FALLOC_FL_INSERT_RANGE) && HAVE_DECL_FALLOC_FL_INSERT_RANGE)
+  XLAT(FALLOC_FL_INSERT_RANGE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/falloc_flags.in b/strace/xlat/falloc_flags.in
new file mode 100644
index 0000000..936e960
--- /dev/null
+++ b/strace/xlat/falloc_flags.in
@@ -0,0 +1,6 @@
+FALLOC_FL_KEEP_SIZE
+FALLOC_FL_PUNCH_HOLE
+FALLOC_FL_NO_HIDE_STALE
+FALLOC_FL_COLLAPSE_RANGE
+FALLOC_FL_ZERO_RANGE
+FALLOC_FL_INSERT_RANGE
diff --git a/strace/xlat/fan_classes.h b/strace/xlat/fan_classes.h
new file mode 100644
index 0000000..cd26d75
--- /dev/null
+++ b/strace/xlat/fan_classes.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fan_classes.in; do not edit. */
+#if !(defined(FAN_CLASS_NOTIF) || (defined(HAVE_DECL_FAN_CLASS_NOTIF) && HAVE_DECL_FAN_CLASS_NOTIF))
+# define FAN_CLASS_NOTIF 0x00000000
+#endif
+#if !(defined(FAN_CLASS_CONTENT) || (defined(HAVE_DECL_FAN_CLASS_CONTENT) && HAVE_DECL_FAN_CLASS_CONTENT))
+# define FAN_CLASS_CONTENT 0x00000004
+#endif
+#if !(defined(FAN_CLASS_PRE_CONTENT) || (defined(HAVE_DECL_FAN_CLASS_PRE_CONTENT) && HAVE_DECL_FAN_CLASS_PRE_CONTENT))
+# define FAN_CLASS_PRE_CONTENT 0x00000008
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fan_classes in mpers mode
+
+#else
+
+static
+const struct xlat fan_classes[] = {
+ XLAT(FAN_CLASS_NOTIF),
+ XLAT(FAN_CLASS_CONTENT),
+ XLAT(FAN_CLASS_PRE_CONTENT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fan_classes.in b/strace/xlat/fan_classes.in
new file mode 100644
index 0000000..e7cd307
--- /dev/null
+++ b/strace/xlat/fan_classes.in
@@ -0,0 +1,3 @@
+FAN_CLASS_NOTIF 0x00000000
+FAN_CLASS_CONTENT 0x00000004
+FAN_CLASS_PRE_CONTENT 0x00000008
diff --git a/strace/xlat/fan_event_flags.h b/strace/xlat/fan_event_flags.h
new file mode 100644
index 0000000..7c19d82
--- /dev/null
+++ b/strace/xlat/fan_event_flags.h
@@ -0,0 +1,54 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fan_event_flags.in; do not edit. */
+#if !(defined(FAN_ACCESS) || (defined(HAVE_DECL_FAN_ACCESS) && HAVE_DECL_FAN_ACCESS))
+# define FAN_ACCESS 0x00000001
+#endif
+#if !(defined(FAN_MODIFY) || (defined(HAVE_DECL_FAN_MODIFY) && HAVE_DECL_FAN_MODIFY))
+# define FAN_MODIFY 0x00000002
+#endif
+#if !(defined(FAN_CLOSE_WRITE) || (defined(HAVE_DECL_FAN_CLOSE_WRITE) && HAVE_DECL_FAN_CLOSE_WRITE))
+# define FAN_CLOSE_WRITE 0x00000008
+#endif
+#if !(defined(FAN_CLOSE_NOWRITE) || (defined(HAVE_DECL_FAN_CLOSE_NOWRITE) && HAVE_DECL_FAN_CLOSE_NOWRITE))
+# define FAN_CLOSE_NOWRITE 0x00000010
+#endif
+#if !(defined(FAN_OPEN) || (defined(HAVE_DECL_FAN_OPEN) && HAVE_DECL_FAN_OPEN))
+# define FAN_OPEN 0x00000020
+#endif
+#if !(defined(FAN_Q_OVERFLOW) || (defined(HAVE_DECL_FAN_Q_OVERFLOW) && HAVE_DECL_FAN_Q_OVERFLOW))
+# define FAN_Q_OVERFLOW 0x00004000
+#endif
+#if !(defined(FAN_OPEN_PERM) || (defined(HAVE_DECL_FAN_OPEN_PERM) && HAVE_DECL_FAN_OPEN_PERM))
+# define FAN_OPEN_PERM 0x00010000
+#endif
+#if !(defined(FAN_ACCESS_PERM) || (defined(HAVE_DECL_FAN_ACCESS_PERM) && HAVE_DECL_FAN_ACCESS_PERM))
+# define FAN_ACCESS_PERM 0x00020000
+#endif
+#if !(defined(FAN_ONDIR) || (defined(HAVE_DECL_FAN_ONDIR) && HAVE_DECL_FAN_ONDIR))
+# define FAN_ONDIR 0x40000000
+#endif
+#if !(defined(FAN_EVENT_ON_CHILD) || (defined(HAVE_DECL_FAN_EVENT_ON_CHILD) && HAVE_DECL_FAN_EVENT_ON_CHILD))
+# define FAN_EVENT_ON_CHILD 0x08000000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fan_event_flags in mpers mode
+
+#else
+
+static
+const struct xlat fan_event_flags[] = {
+ XLAT(FAN_ACCESS),
+ XLAT(FAN_MODIFY),
+ XLAT(FAN_CLOSE_WRITE),
+ XLAT(FAN_CLOSE_NOWRITE),
+ XLAT(FAN_OPEN),
+ XLAT(FAN_Q_OVERFLOW),
+ XLAT(FAN_OPEN_PERM),
+ XLAT(FAN_ACCESS_PERM),
+ XLAT(FAN_ONDIR),
+ XLAT(FAN_EVENT_ON_CHILD),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fan_event_flags.in b/strace/xlat/fan_event_flags.in
new file mode 100644
index 0000000..c8d4552
--- /dev/null
+++ b/strace/xlat/fan_event_flags.in
@@ -0,0 +1,10 @@
+FAN_ACCESS 0x00000001
+FAN_MODIFY 0x00000002
+FAN_CLOSE_WRITE 0x00000008
+FAN_CLOSE_NOWRITE 0x00000010
+FAN_OPEN 0x00000020
+FAN_Q_OVERFLOW 0x00004000
+FAN_OPEN_PERM 0x00010000
+FAN_ACCESS_PERM 0x00020000
+FAN_ONDIR 0x40000000
+FAN_EVENT_ON_CHILD 0x08000000
diff --git a/strace/xlat/fan_init_flags.h b/strace/xlat/fan_init_flags.h
new file mode 100644
index 0000000..b11e47a
--- /dev/null
+++ b/strace/xlat/fan_init_flags.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fan_init_flags.in; do not edit. */
+#if !(defined(FAN_CLOEXEC) || (defined(HAVE_DECL_FAN_CLOEXEC) && HAVE_DECL_FAN_CLOEXEC))
+# define FAN_CLOEXEC 0x00000001
+#endif
+#if !(defined(FAN_NONBLOCK) || (defined(HAVE_DECL_FAN_NONBLOCK) && HAVE_DECL_FAN_NONBLOCK))
+# define FAN_NONBLOCK 0x00000002
+#endif
+#if !(defined(FAN_UNLIMITED_QUEUE) || (defined(HAVE_DECL_FAN_UNLIMITED_QUEUE) && HAVE_DECL_FAN_UNLIMITED_QUEUE))
+# define FAN_UNLIMITED_QUEUE 0x00000010
+#endif
+#if !(defined(FAN_UNLIMITED_MARKS) || (defined(HAVE_DECL_FAN_UNLIMITED_MARKS) && HAVE_DECL_FAN_UNLIMITED_MARKS))
+# define FAN_UNLIMITED_MARKS 0x00000020
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fan_init_flags in mpers mode
+
+#else
+
+static
+const struct xlat fan_init_flags[] = {
+ XLAT(FAN_CLOEXEC),
+ XLAT(FAN_NONBLOCK),
+ XLAT(FAN_UNLIMITED_QUEUE),
+ XLAT(FAN_UNLIMITED_MARKS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fan_init_flags.in b/strace/xlat/fan_init_flags.in
new file mode 100644
index 0000000..ca33039
--- /dev/null
+++ b/strace/xlat/fan_init_flags.in
@@ -0,0 +1,4 @@
+FAN_CLOEXEC 0x00000001
+FAN_NONBLOCK 0x00000002
+FAN_UNLIMITED_QUEUE 0x00000010
+FAN_UNLIMITED_MARKS 0x00000020
diff --git a/strace/xlat/fan_mark_flags.h b/strace/xlat/fan_mark_flags.h
new file mode 100644
index 0000000..f2f9140
--- /dev/null
+++ b/strace/xlat/fan_mark_flags.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fan_mark_flags.in; do not edit. */
+#if !(defined(FAN_MARK_ADD) || (defined(HAVE_DECL_FAN_MARK_ADD) && HAVE_DECL_FAN_MARK_ADD))
+# define FAN_MARK_ADD 0x00000001
+#endif
+#if !(defined(FAN_MARK_REMOVE) || (defined(HAVE_DECL_FAN_MARK_REMOVE) && HAVE_DECL_FAN_MARK_REMOVE))
+# define FAN_MARK_REMOVE 0x00000002
+#endif
+#if !(defined(FAN_MARK_DONT_FOLLOW) || (defined(HAVE_DECL_FAN_MARK_DONT_FOLLOW) && HAVE_DECL_FAN_MARK_DONT_FOLLOW))
+# define FAN_MARK_DONT_FOLLOW 0x00000004
+#endif
+#if !(defined(FAN_MARK_ONLYDIR) || (defined(HAVE_DECL_FAN_MARK_ONLYDIR) && HAVE_DECL_FAN_MARK_ONLYDIR))
+# define FAN_MARK_ONLYDIR 0x00000008
+#endif
+#if !(defined(FAN_MARK_MOUNT) || (defined(HAVE_DECL_FAN_MARK_MOUNT) && HAVE_DECL_FAN_MARK_MOUNT))
+# define FAN_MARK_MOUNT 0x00000010
+#endif
+#if !(defined(FAN_MARK_IGNORED_MASK) || (defined(HAVE_DECL_FAN_MARK_IGNORED_MASK) && HAVE_DECL_FAN_MARK_IGNORED_MASK))
+# define FAN_MARK_IGNORED_MASK 0x00000020
+#endif
+#if !(defined(FAN_MARK_IGNORED_SURV_MODIFY) || (defined(HAVE_DECL_FAN_MARK_IGNORED_SURV_MODIFY) && HAVE_DECL_FAN_MARK_IGNORED_SURV_MODIFY))
+# define FAN_MARK_IGNORED_SURV_MODIFY 0x00000040
+#endif
+#if !(defined(FAN_MARK_FLUSH) || (defined(HAVE_DECL_FAN_MARK_FLUSH) && HAVE_DECL_FAN_MARK_FLUSH))
+# define FAN_MARK_FLUSH 0x00000080
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fan_mark_flags in mpers mode
+
+#else
+
+static
+const struct xlat fan_mark_flags[] = {
+ XLAT(FAN_MARK_ADD),
+ XLAT(FAN_MARK_REMOVE),
+ XLAT(FAN_MARK_DONT_FOLLOW),
+ XLAT(FAN_MARK_ONLYDIR),
+ XLAT(FAN_MARK_MOUNT),
+ XLAT(FAN_MARK_IGNORED_MASK),
+ XLAT(FAN_MARK_IGNORED_SURV_MODIFY),
+ XLAT(FAN_MARK_FLUSH),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fan_mark_flags.in b/strace/xlat/fan_mark_flags.in
new file mode 100644
index 0000000..134af4b
--- /dev/null
+++ b/strace/xlat/fan_mark_flags.in
@@ -0,0 +1,8 @@
+FAN_MARK_ADD 0x00000001
+FAN_MARK_REMOVE 0x00000002
+FAN_MARK_DONT_FOLLOW 0x00000004
+FAN_MARK_ONLYDIR 0x00000008
+FAN_MARK_MOUNT 0x00000010
+FAN_MARK_IGNORED_MASK 0x00000020
+FAN_MARK_IGNORED_SURV_MODIFY 0x00000040
+FAN_MARK_FLUSH 0x00000080
diff --git a/strace/xlat/fcntl64cmds.h b/strace/xlat/fcntl64cmds.h
new file mode 100644
index 0000000..e01e533
--- /dev/null
+++ b/strace/xlat/fcntl64cmds.h
@@ -0,0 +1,27 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fcntl64cmds.in; do not edit. */
+#if !(defined(F_GETLK64) || (defined(HAVE_DECL_F_GETLK64) && HAVE_DECL_F_GETLK64))
+# define F_GETLK64 12
+#endif
+#if !(defined(F_SETLK64) || (defined(HAVE_DECL_F_SETLK64) && HAVE_DECL_F_SETLK64))
+# define F_SETLK64 13
+#endif
+#if !(defined(F_SETLKW64) || (defined(HAVE_DECL_F_SETLKW64) && HAVE_DECL_F_SETLKW64))
+# define F_SETLKW64 14
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fcntl64cmds in mpers mode
+
+#else
+
+static
+const struct xlat fcntl64cmds[] = {
+/* asm-generic/fcntl.h */
+ XLAT(F_GETLK64),
+ XLAT(F_SETLK64),
+ XLAT(F_SETLKW64),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fcntl64cmds.in b/strace/xlat/fcntl64cmds.in
new file mode 100644
index 0000000..074efe4
--- /dev/null
+++ b/strace/xlat/fcntl64cmds.in
@@ -0,0 +1,4 @@
+/* asm-generic/fcntl.h */
+F_GETLK64	12
+F_SETLK64	13
+F_SETLKW64	14
diff --git a/strace/xlat/fcntlcmds.h b/strace/xlat/fcntlcmds.h
new file mode 100644
index 0000000..33280f3
--- /dev/null
+++ b/strace/xlat/fcntlcmds.h
@@ -0,0 +1,125 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fcntlcmds.in; do not edit. */
+#if !(defined(F_DUPFD) || (defined(HAVE_DECL_F_DUPFD) && HAVE_DECL_F_DUPFD))
+# define F_DUPFD 0
+#endif
+#if !(defined(F_GETFD) || (defined(HAVE_DECL_F_GETFD) && HAVE_DECL_F_GETFD))
+# define F_GETFD 1
+#endif
+#if !(defined(F_SETFD) || (defined(HAVE_DECL_F_SETFD) && HAVE_DECL_F_SETFD))
+# define F_SETFD 2
+#endif
+#if !(defined(F_GETFL) || (defined(HAVE_DECL_F_GETFL) && HAVE_DECL_F_GETFL))
+# define F_GETFL 3
+#endif
+#if !(defined(F_SETFL) || (defined(HAVE_DECL_F_SETFL) && HAVE_DECL_F_SETFL))
+# define F_SETFL 4
+#endif
+#if !(defined(F_GETLK) || (defined(HAVE_DECL_F_GETLK) && HAVE_DECL_F_GETLK))
+# define F_GETLK 5
+#endif
+#if !(defined(F_SETLK) || (defined(HAVE_DECL_F_SETLK) && HAVE_DECL_F_SETLK))
+# define F_SETLK 6
+#endif
+#if !(defined(F_SETLKW) || (defined(HAVE_DECL_F_SETLKW) && HAVE_DECL_F_SETLKW))
+# define F_SETLKW 7
+#endif
+#if !(defined(F_SETOWN) || (defined(HAVE_DECL_F_SETOWN) && HAVE_DECL_F_SETOWN))
+# define F_SETOWN 8
+#endif
+#if !(defined(F_GETOWN) || (defined(HAVE_DECL_F_GETOWN) && HAVE_DECL_F_GETOWN))
+# define F_GETOWN 9
+#endif
+#if !(defined(F_SETSIG) || (defined(HAVE_DECL_F_SETSIG) && HAVE_DECL_F_SETSIG))
+# define F_SETSIG 10
+#endif
+#if !(defined(F_GETSIG) || (defined(HAVE_DECL_F_GETSIG) && HAVE_DECL_F_GETSIG))
+# define F_GETSIG 11
+#endif
+#if !(defined(F_SETOWN_EX) || (defined(HAVE_DECL_F_SETOWN_EX) && HAVE_DECL_F_SETOWN_EX))
+# define F_SETOWN_EX 15
+#endif
+#if !(defined(F_GETOWN_EX) || (defined(HAVE_DECL_F_GETOWN_EX) && HAVE_DECL_F_GETOWN_EX))
+# define F_GETOWN_EX 16
+#endif
+#if !(defined(F_GETOWNER_UIDS) || (defined(HAVE_DECL_F_GETOWNER_UIDS) && HAVE_DECL_F_GETOWNER_UIDS))
+# define F_GETOWNER_UIDS 17
+#endif
+#if !(defined(F_OFD_GETLK) || (defined(HAVE_DECL_F_OFD_GETLK) && HAVE_DECL_F_OFD_GETLK))
+# define F_OFD_GETLK 36
+#endif
+#if !(defined(F_OFD_SETLK) || (defined(HAVE_DECL_F_OFD_SETLK) && HAVE_DECL_F_OFD_SETLK))
+# define F_OFD_SETLK 37
+#endif
+#if !(defined(F_OFD_SETLKW) || (defined(HAVE_DECL_F_OFD_SETLKW) && HAVE_DECL_F_OFD_SETLKW))
+# define F_OFD_SETLKW 38
+#endif
+#if !(defined(F_SETLEASE) || (defined(HAVE_DECL_F_SETLEASE) && HAVE_DECL_F_SETLEASE))
+# define F_SETLEASE (1024 + 0)
+#endif
+#if !(defined(F_GETLEASE) || (defined(HAVE_DECL_F_GETLEASE) && HAVE_DECL_F_GETLEASE))
+# define F_GETLEASE (1024 + 1)
+#endif
+#if !(defined(F_NOTIFY) || (defined(HAVE_DECL_F_NOTIFY) && HAVE_DECL_F_NOTIFY))
+# define F_NOTIFY (1024 + 2)
+#endif
+#if !(defined(F_CANCELLK) || (defined(HAVE_DECL_F_CANCELLK) && HAVE_DECL_F_CANCELLK))
+# define F_CANCELLK (1024 + 5)
+#endif
+#if !(defined(F_DUPFD_CLOEXEC) || (defined(HAVE_DECL_F_DUPFD_CLOEXEC) && HAVE_DECL_F_DUPFD_CLOEXEC))
+# define F_DUPFD_CLOEXEC (1024 + 6)
+#endif
+#if !(defined(F_SETPIPE_SZ) || (defined(HAVE_DECL_F_SETPIPE_SZ) && HAVE_DECL_F_SETPIPE_SZ))
+# define F_SETPIPE_SZ (1024 + 7)
+#endif
+#if !(defined(F_GETPIPE_SZ) || (defined(HAVE_DECL_F_GETPIPE_SZ) && HAVE_DECL_F_GETPIPE_SZ))
+# define F_GETPIPE_SZ (1024 + 8)
+#endif
+#if !(defined(F_ADD_SEALS) || (defined(HAVE_DECL_F_ADD_SEALS) && HAVE_DECL_F_ADD_SEALS))
+# define F_ADD_SEALS (1024 + 9)
+#endif
+#if !(defined(F_GET_SEALS) || (defined(HAVE_DECL_F_GET_SEALS) && HAVE_DECL_F_GET_SEALS))
+# define F_GET_SEALS (1024 + 10)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fcntlcmds in mpers mode
+
+#else
+
+static
+const struct xlat fcntlcmds[] = {
+/* asm-generic/fcntl.h */
+ XLAT(F_DUPFD),
+ XLAT(F_GETFD),
+ XLAT(F_SETFD),
+ XLAT(F_GETFL),
+ XLAT(F_SETFL),
+ XLAT(F_GETLK),
+ XLAT(F_SETLK),
+ XLAT(F_SETLKW),
+ XLAT(F_SETOWN),
+ XLAT(F_GETOWN),
+ XLAT(F_SETSIG),
+ XLAT(F_GETSIG),
+ XLAT(F_SETOWN_EX),
+ XLAT(F_GETOWN_EX),
+ XLAT(F_GETOWNER_UIDS),
+ XLAT(F_OFD_GETLK),
+ XLAT(F_OFD_SETLK),
+ XLAT(F_OFD_SETLKW),
+
+/* linux/fcntl.h */
+ XLAT(F_SETLEASE),
+ XLAT(F_GETLEASE),
+ XLAT(F_NOTIFY),
+ XLAT(F_CANCELLK),
+ XLAT(F_DUPFD_CLOEXEC),
+ XLAT(F_SETPIPE_SZ),
+ XLAT(F_GETPIPE_SZ),
+ XLAT(F_ADD_SEALS),
+ XLAT(F_GET_SEALS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fcntlcmds.in b/strace/xlat/fcntlcmds.in
new file mode 100644
index 0000000..c050836
--- /dev/null
+++ b/strace/xlat/fcntlcmds.in
@@ -0,0 +1,30 @@
+/* asm-generic/fcntl.h */
+F_DUPFD		0
+F_GETFD		1
+F_SETFD		2
+F_GETFL		3
+F_SETFL		4
+F_GETLK		5
+F_SETLK		6
+F_SETLKW	7
+F_SETOWN	8
+F_GETOWN	9
+F_SETSIG	10
+F_GETSIG	11
+F_SETOWN_EX	15
+F_GETOWN_EX	16
+F_GETOWNER_UIDS	17
+F_OFD_GETLK	36
+F_OFD_SETLK	37
+F_OFD_SETLKW	38
+
+/* linux/fcntl.h */
+F_SETLEASE	(1024 + 0)
+F_GETLEASE	(1024 + 1)
+F_NOTIFY	(1024 + 2)
+F_CANCELLK	(1024 + 5)
+F_DUPFD_CLOEXEC	(1024 + 6)
+F_SETPIPE_SZ	(1024 + 7)
+F_GETPIPE_SZ	(1024 + 8)
+F_ADD_SEALS	(1024 + 9)
+F_GET_SEALS	(1024 + 10)
diff --git a/strace/xlat/fdflags.h b/strace/xlat/fdflags.h
new file mode 100644
index 0000000..8a5d03c
--- /dev/null
+++ b/strace/xlat/fdflags.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fdflags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fdflags in mpers mode
+
+#else
+
+static
+const struct xlat fdflags[] = {
+#if defined(FD_CLOEXEC) || (defined(HAVE_DECL_FD_CLOEXEC) && HAVE_DECL_FD_CLOEXEC)
+  XLAT(FD_CLOEXEC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fdflags.in b/strace/xlat/fdflags.in
new file mode 100644
index 0000000..f6c02b4
--- /dev/null
+++ b/strace/xlat/fdflags.in
@@ -0,0 +1 @@
+FD_CLOEXEC
diff --git a/strace/xlat/fiemap_extent_flags.h b/strace/xlat/fiemap_extent_flags.h
new file mode 100644
index 0000000..629328c
--- /dev/null
+++ b/strace/xlat/fiemap_extent_flags.h
@@ -0,0 +1,58 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fiemap_extent_flags.in; do not edit. */
+#if !(defined(FIEMAP_EXTENT_LAST) || (defined(HAVE_DECL_FIEMAP_EXTENT_LAST) && HAVE_DECL_FIEMAP_EXTENT_LAST))
+# define FIEMAP_EXTENT_LAST 0x00000001
+#endif
+#if !(defined(FIEMAP_EXTENT_UNKNOWN) || (defined(HAVE_DECL_FIEMAP_EXTENT_UNKNOWN) && HAVE_DECL_FIEMAP_EXTENT_UNKNOWN))
+# define FIEMAP_EXTENT_UNKNOWN 0x00000002
+#endif
+#if !(defined(FIEMAP_EXTENT_DELALLOC) || (defined(HAVE_DECL_FIEMAP_EXTENT_DELALLOC) && HAVE_DECL_FIEMAP_EXTENT_DELALLOC))
+# define FIEMAP_EXTENT_DELALLOC 0x00000004
+#endif
+#if !(defined(FIEMAP_EXTENT_ENCODED) || (defined(HAVE_DECL_FIEMAP_EXTENT_ENCODED) && HAVE_DECL_FIEMAP_EXTENT_ENCODED))
+# define FIEMAP_EXTENT_ENCODED 0x00000008
+#endif
+#if !(defined(FIEMAP_EXTENT_DATA_ENCRYPTED) || (defined(HAVE_DECL_FIEMAP_EXTENT_DATA_ENCRYPTED) && HAVE_DECL_FIEMAP_EXTENT_DATA_ENCRYPTED))
+# define FIEMAP_EXTENT_DATA_ENCRYPTED 0x00000080
+#endif
+#if !(defined(FIEMAP_EXTENT_NOT_ALIGNED) || (defined(HAVE_DECL_FIEMAP_EXTENT_NOT_ALIGNED) && HAVE_DECL_FIEMAP_EXTENT_NOT_ALIGNED))
+# define FIEMAP_EXTENT_NOT_ALIGNED 0x00000100
+#endif
+#if !(defined(FIEMAP_EXTENT_DATA_INLINE) || (defined(HAVE_DECL_FIEMAP_EXTENT_DATA_INLINE) && HAVE_DECL_FIEMAP_EXTENT_DATA_INLINE))
+# define FIEMAP_EXTENT_DATA_INLINE 0x00000200
+#endif
+#if !(defined(FIEMAP_EXTENT_DATA_TAIL) || (defined(HAVE_DECL_FIEMAP_EXTENT_DATA_TAIL) && HAVE_DECL_FIEMAP_EXTENT_DATA_TAIL))
+# define FIEMAP_EXTENT_DATA_TAIL 0x00000400
+#endif
+#if !(defined(FIEMAP_EXTENT_UNWRITTEN) || (defined(HAVE_DECL_FIEMAP_EXTENT_UNWRITTEN) && HAVE_DECL_FIEMAP_EXTENT_UNWRITTEN))
+# define FIEMAP_EXTENT_UNWRITTEN 0x00000800
+#endif
+#if !(defined(FIEMAP_EXTENT_MERGED) || (defined(HAVE_DECL_FIEMAP_EXTENT_MERGED) && HAVE_DECL_FIEMAP_EXTENT_MERGED))
+# define FIEMAP_EXTENT_MERGED 0x00001000
+#endif
+#if !(defined(FIEMAP_EXTENT_SHARED) || (defined(HAVE_DECL_FIEMAP_EXTENT_SHARED) && HAVE_DECL_FIEMAP_EXTENT_SHARED))
+# define FIEMAP_EXTENT_SHARED 0x00002000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fiemap_extent_flags in mpers mode
+
+#else
+
+static
+const struct xlat fiemap_extent_flags[] = {
+ XLAT(FIEMAP_EXTENT_LAST),
+ XLAT(FIEMAP_EXTENT_UNKNOWN),
+ XLAT(FIEMAP_EXTENT_DELALLOC),
+ XLAT(FIEMAP_EXTENT_ENCODED),
+ XLAT(FIEMAP_EXTENT_DATA_ENCRYPTED),
+ XLAT(FIEMAP_EXTENT_NOT_ALIGNED),
+ XLAT(FIEMAP_EXTENT_DATA_INLINE),
+ XLAT(FIEMAP_EXTENT_DATA_TAIL),
+ XLAT(FIEMAP_EXTENT_UNWRITTEN),
+ XLAT(FIEMAP_EXTENT_MERGED),
+ XLAT(FIEMAP_EXTENT_SHARED),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fiemap_extent_flags.in b/strace/xlat/fiemap_extent_flags.in
new file mode 100644
index 0000000..4d8911a
--- /dev/null
+++ b/strace/xlat/fiemap_extent_flags.in
@@ -0,0 +1,11 @@
+FIEMAP_EXTENT_LAST		0x00000001
+FIEMAP_EXTENT_UNKNOWN		0x00000002
+FIEMAP_EXTENT_DELALLOC		0x00000004
+FIEMAP_EXTENT_ENCODED		0x00000008
+FIEMAP_EXTENT_DATA_ENCRYPTED	0x00000080
+FIEMAP_EXTENT_NOT_ALIGNED	0x00000100
+FIEMAP_EXTENT_DATA_INLINE	0x00000200
+FIEMAP_EXTENT_DATA_TAIL		0x00000400
+FIEMAP_EXTENT_UNWRITTEN		0x00000800
+FIEMAP_EXTENT_MERGED		0x00001000
+FIEMAP_EXTENT_SHARED		0x00002000
diff --git a/strace/xlat/fiemap_flags.h b/strace/xlat/fiemap_flags.h
new file mode 100644
index 0000000..4f463ef
--- /dev/null
+++ b/strace/xlat/fiemap_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fiemap_flags.in; do not edit. */
+#if !(defined(FIEMAP_FLAG_SYNC) || (defined(HAVE_DECL_FIEMAP_FLAG_SYNC) && HAVE_DECL_FIEMAP_FLAG_SYNC))
+# define FIEMAP_FLAG_SYNC 1
+#endif
+#if !(defined(FIEMAP_FLAG_XATTR) || (defined(HAVE_DECL_FIEMAP_FLAG_XATTR) && HAVE_DECL_FIEMAP_FLAG_XATTR))
+# define FIEMAP_FLAG_XATTR 2
+#endif
+#if !(defined(FIEMAP_FLAG_CACHE) || (defined(HAVE_DECL_FIEMAP_FLAG_CACHE) && HAVE_DECL_FIEMAP_FLAG_CACHE))
+# define FIEMAP_FLAG_CACHE 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fiemap_flags in mpers mode
+
+#else
+
+static
+const struct xlat fiemap_flags[] = {
+ XLAT(FIEMAP_FLAG_SYNC),
+ XLAT(FIEMAP_FLAG_XATTR),
+ XLAT(FIEMAP_FLAG_CACHE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fiemap_flags.in b/strace/xlat/fiemap_flags.in
new file mode 100644
index 0000000..aff7295
--- /dev/null
+++ b/strace/xlat/fiemap_flags.in
@@ -0,0 +1,3 @@
+FIEMAP_FLAG_SYNC	1
+FIEMAP_FLAG_XATTR	2
+FIEMAP_FLAG_CACHE	4
diff --git a/strace/xlat/fileflags.h b/strace/xlat/fileflags.h
new file mode 100644
index 0000000..3b47cf0
--- /dev/null
+++ b/strace/xlat/fileflags.h
@@ -0,0 +1,5 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fileflags.in; do not edit. */
+
+static const struct xlat fileflags[] = {
+	XLAT_END
+};
diff --git a/strace/xlat/flockcmds.h b/strace/xlat/flockcmds.h
new file mode 100644
index 0000000..2ccd714
--- /dev/null
+++ b/strace/xlat/flockcmds.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/flockcmds.in; do not edit. */
+#if !(defined(LOCK_SH) || (defined(HAVE_DECL_LOCK_SH) && HAVE_DECL_LOCK_SH))
+# define LOCK_SH 1
+#endif
+#if !(defined(LOCK_EX) || (defined(HAVE_DECL_LOCK_EX) && HAVE_DECL_LOCK_EX))
+# define LOCK_EX 2
+#endif
+#if !(defined(LOCK_NB) || (defined(HAVE_DECL_LOCK_NB) && HAVE_DECL_LOCK_NB))
+# define LOCK_NB 4
+#endif
+#if !(defined(LOCK_UN) || (defined(HAVE_DECL_LOCK_UN) && HAVE_DECL_LOCK_UN))
+# define LOCK_UN 8
+#endif
+#if !(defined(LOCK_MAND) || (defined(HAVE_DECL_LOCK_MAND) && HAVE_DECL_LOCK_MAND))
+# define LOCK_MAND 32
+#endif
+#if !(defined(LOCK_RW) || (defined(HAVE_DECL_LOCK_RW) && HAVE_DECL_LOCK_RW))
+# define LOCK_RW 192
+#endif
+#if !(defined(LOCK_READ) || (defined(HAVE_DECL_LOCK_READ) && HAVE_DECL_LOCK_READ))
+# define LOCK_READ 64
+#endif
+#if !(defined(LOCK_WRITE) || (defined(HAVE_DECL_LOCK_WRITE) && HAVE_DECL_LOCK_WRITE))
+# define LOCK_WRITE 128
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat flockcmds in mpers mode
+
+#else
+
+static
+const struct xlat flockcmds[] = {
+ XLAT(LOCK_SH),
+ XLAT(LOCK_EX),
+ XLAT(LOCK_NB),
+ XLAT(LOCK_UN),
+ XLAT(LOCK_MAND),
+ XLAT(LOCK_RW),
+ XLAT(LOCK_READ),
+ XLAT(LOCK_WRITE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/flockcmds.in b/strace/xlat/flockcmds.in
new file mode 100644
index 0000000..d6bddb3
--- /dev/null
+++ b/strace/xlat/flockcmds.in
@@ -0,0 +1,8 @@
+LOCK_SH		1
+LOCK_EX		2
+LOCK_NB		4
+LOCK_UN		8
+LOCK_MAND	32
+LOCK_RW		192
+LOCK_READ	64
+LOCK_WRITE	128
diff --git a/strace/xlat/fsmagic.h b/strace/xlat/fsmagic.h
new file mode 100644
index 0000000..ec1777c
--- /dev/null
+++ b/strace/xlat/fsmagic.h
@@ -0,0 +1,88 @@
+/* Generated by ./xlat/gen.sh from ./xlat/fsmagic.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat fsmagic in mpers mode
+
+#else
+
+static
+const struct xlat fsmagic[] = {
+/* sorted by value, suitable for bsearch(3) */
+{ 0x0000002f,	"QNX4_SUPER_MAGIC"	},
+{ 0x00000187,	"AUTOFS_SUPER_MAGIC"	},
+{ 0x00001373,	"DEVFS_SUPER_MAGIC"	},
+{ 0x0000137d,	"EXT_SUPER_MAGIC"	},
+{ 0x0000137f,	"MINIX_SUPER_MAGIC"	},
+{ 0x0000138f,	"MINIX_SUPER_MAGIC2"	},
+{ 0x00001cd1,	"DEVPTS_SUPER_MAGIC"	},
+{ 0x00002468,	"MINIX2_SUPER_MAGIC"	},
+{ 0x00002478,	"MINIX2_SUPER_MAGIC2"	},
+{ 0x00003434,	"NILFS_SUPER_MAGIC"	},
+{ 0x00004d44,	"MSDOS_SUPER_MAGIC"	},
+{ 0x00004d5a,	"MINIX3_SUPER_MAGIC"	},
+{ 0x0000517b,	"SMB_SUPER_MAGIC"	},
+{ 0x0000564c,	"NCP_SUPER_MAGIC"	},
+{ 0x00006969,	"NFS_SUPER_MAGIC"	},
+{ 0x000072b6,	"JFFS2_SUPER_MAGIC"	},
+{ 0x00009660,	"ISOFS_SUPER_MAGIC"	},
+{ 0x00009fa0,	"PROC_SUPER_MAGIC"	},
+{ 0x00009fa1,	"OPENPROM_SUPER_MAGIC"	},
+{ 0x00009fa2,	"USBDEVICE_SUPER_MAGIC"	},
+{ 0x0000adf5,	"ADFS_SUPER_MAGIC"	},
+{ 0x0000adff,	"AFFS_SUPER_MAGIC"	},
+{ 0x0000ef51,	"EXT2_OLD_SUPER_MAGIC"	},
+{ 0x0000ef53,	"EXT2_SUPER_MAGIC"	},
+{ 0x0000f15f,	"ECRYPTFS_SUPER_MAGIC"	},
+{ 0x00011954,	"UFS_MAGIC"		},
+{ 0x0027e0eb,	"CGROUP_SUPER_MAGIC"	},
+{ 0x00414a53,	"EFS_SUPER_MAGIC"	},
+{ 0x00c0ffee,	"HOSTFS_SUPER_MAGIC"	},
+{ 0x01021994,	"TMPFS_MAGIC"		},
+{ 0x01021997,	"V9FS_MAGIC"		},
+{ 0x012fd16d,	"XIAFS_SUPER_MAGIC"	},
+{ 0x012ff7b4,	"XENIX_SUPER_MAGIC"	},
+{ 0x012ff7b5,	"SYSV4_SUPER_MAGIC"	},
+{ 0x012ff7b6,	"SYSV2_SUPER_MAGIC"	},
+{ 0x012ff7b7,	"COH_SUPER_MAGIC"	},
+{ 0x02011994,	"SHMFS_SUPER_MAGIC"	},
+{ 0x09041934,	"ANON_INODE_FS_MAGIC"	},
+{ 0x0bad1dea,	"FUTEXFS_SUPER_MAGIC"	},
+{ 0x11307854,	"MTD_INODE_FS_MAGIC"	},
+{ 0x15013346,	"UDF_SUPER_MAGIC"	},
+{ 0x28cd3d45,	"CRAMFS_MAGIC"		},
+{ 0x42494e4d,	"BINFMTFS_MAGIC"	},
+{ 0x43415d53,	"SMACK_MAGIC"		},
+{ 0x453dcd28,	"CRAMFS_MAGIC_WEND"	},
+{ 0x50495045,	"PIPEFS_MAGIC"		},
+{ 0x52654973,	"REISERFS_SUPER_MAGIC"	},
+{ 0x5346414f,	"AFS_SUPER_MAGIC"	},
+{ 0x534f434b,	"SOCKFS_MAGIC"		},
+{ 0x54190100,	"UFS_CIGAM"		},
+{ 0x57ac6e9d,	"STACK_END_MAGIC"	},
+{ 0x6165676c,	"PSTOREFS_MAGIC"	},
+{ 0x62646576,	"BDEVFS_MAGIC"		},
+{ 0x62656572,	"SYSFS_MAGIC"		},
+{ 0x63677270,	"CGROUP2_SUPER_MAGIC"	},
+{ 0x64626720,	"DEBUGFS_MAGIC"		},
+{ 0x68191122,	"QNX6_SUPER_MAGIC"	},
+{ 0x6e736673,	"NSFS_MAGIC"		},
+{ 0x73636673,	"SECURITYFS_MAGIC"	},
+{ 0x73717368,	"SQUASHFS_MAGIC"	},
+{ 0x73727279,	"BTRFS_TEST_MAGIC"	},
+{ 0x73757245,	"CODA_SUPER_MAGIC"	},
+{ 0x74726163,	"TRACEFS_MAGIC"		},
+{ 0x794c7630,	"OVERLAYFS_SUPER_MAGIC"	},
+{ 0x858458f6,	"RAMFS_MAGIC"		},
+{ 0x9123683e,	"BTRFS_SUPER_MAGIC"	},
+{ 0x958458f6,	"HUGETLBFS_MAGIC"	},
+{ 0xabba1974,	"XENFS_SUPER_MAGIC"	},
+{ 0xcafe4a11,	"BPF_FS_MAGIC"		},
+{ 0xde5e81e4,	"EFIVARFS_MAGIC"	},
+{ 0xf2f52010,	"F2FS_SUPER_MAGIC"	},
+{ 0xf97cff8c,	"SELINUX_MAGIC"		},
+{ 0xf995e849,	"HPFS_SUPER_MAGIC"	},
+ /* this array should remain not NULL-terminated */
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/fsmagic.in b/strace/xlat/fsmagic.in
new file mode 100644
index 0000000..f9005b6
--- /dev/null
+++ b/strace/xlat/fsmagic.in
@@ -0,0 +1,75 @@
+/* sorted by value, suitable for bsearch(3) */
+{ 0x0000002f,	"QNX4_SUPER_MAGIC"	},
+{ 0x00000187,	"AUTOFS_SUPER_MAGIC"	},
+{ 0x00001373,	"DEVFS_SUPER_MAGIC"	},
+{ 0x0000137d,	"EXT_SUPER_MAGIC"	},
+{ 0x0000137f,	"MINIX_SUPER_MAGIC"	},
+{ 0x0000138f,	"MINIX_SUPER_MAGIC2"	},
+{ 0x00001cd1,	"DEVPTS_SUPER_MAGIC"	},
+{ 0x00002468,	"MINIX2_SUPER_MAGIC"	},
+{ 0x00002478,	"MINIX2_SUPER_MAGIC2"	},
+{ 0x00003434,	"NILFS_SUPER_MAGIC"	},
+{ 0x00004d44,	"MSDOS_SUPER_MAGIC"	},
+{ 0x00004d5a,	"MINIX3_SUPER_MAGIC"	},
+{ 0x0000517b,	"SMB_SUPER_MAGIC"	},
+{ 0x0000564c,	"NCP_SUPER_MAGIC"	},
+{ 0x00006969,	"NFS_SUPER_MAGIC"	},
+{ 0x000072b6,	"JFFS2_SUPER_MAGIC"	},
+{ 0x00009660,	"ISOFS_SUPER_MAGIC"	},
+{ 0x00009fa0,	"PROC_SUPER_MAGIC"	},
+{ 0x00009fa1,	"OPENPROM_SUPER_MAGIC"	},
+{ 0x00009fa2,	"USBDEVICE_SUPER_MAGIC"	},
+{ 0x0000adf5,	"ADFS_SUPER_MAGIC"	},
+{ 0x0000adff,	"AFFS_SUPER_MAGIC"	},
+{ 0x0000ef51,	"EXT2_OLD_SUPER_MAGIC"	},
+{ 0x0000ef53,	"EXT2_SUPER_MAGIC"	},
+{ 0x0000f15f,	"ECRYPTFS_SUPER_MAGIC"	},
+{ 0x00011954,	"UFS_MAGIC"		},
+{ 0x0027e0eb,	"CGROUP_SUPER_MAGIC"	},
+{ 0x00414a53,	"EFS_SUPER_MAGIC"	},
+{ 0x00c0ffee,	"HOSTFS_SUPER_MAGIC"	},
+{ 0x01021994,	"TMPFS_MAGIC"		},
+{ 0x01021997,	"V9FS_MAGIC"		},
+{ 0x012fd16d,	"XIAFS_SUPER_MAGIC"	},
+{ 0x012ff7b4,	"XENIX_SUPER_MAGIC"	},
+{ 0x012ff7b5,	"SYSV4_SUPER_MAGIC"	},
+{ 0x012ff7b6,	"SYSV2_SUPER_MAGIC"	},
+{ 0x012ff7b7,	"COH_SUPER_MAGIC"	},
+{ 0x02011994,	"SHMFS_SUPER_MAGIC"	},
+{ 0x09041934,	"ANON_INODE_FS_MAGIC"	},
+{ 0x0bad1dea,	"FUTEXFS_SUPER_MAGIC"	},
+{ 0x11307854,	"MTD_INODE_FS_MAGIC"	},
+{ 0x15013346,	"UDF_SUPER_MAGIC"	},
+{ 0x28cd3d45,	"CRAMFS_MAGIC"		},
+{ 0x42494e4d,	"BINFMTFS_MAGIC"	},
+{ 0x43415d53,	"SMACK_MAGIC"		},
+{ 0x453dcd28,	"CRAMFS_MAGIC_WEND"	},
+{ 0x50495045,	"PIPEFS_MAGIC"		},
+{ 0x52654973,	"REISERFS_SUPER_MAGIC"	},
+{ 0x5346414f,	"AFS_SUPER_MAGIC"	},
+{ 0x534f434b,	"SOCKFS_MAGIC"		},
+{ 0x54190100,	"UFS_CIGAM"		},
+{ 0x57ac6e9d,	"STACK_END_MAGIC"	},
+{ 0x6165676c,	"PSTOREFS_MAGIC"	},
+{ 0x62646576,	"BDEVFS_MAGIC"		},
+{ 0x62656572,	"SYSFS_MAGIC"		},
+{ 0x63677270,	"CGROUP2_SUPER_MAGIC"	},
+{ 0x64626720,	"DEBUGFS_MAGIC"		},
+{ 0x68191122,	"QNX6_SUPER_MAGIC"	},
+{ 0x6e736673,	"NSFS_MAGIC"		},
+{ 0x73636673,	"SECURITYFS_MAGIC"	},
+{ 0x73717368,	"SQUASHFS_MAGIC"	},
+{ 0x73727279,	"BTRFS_TEST_MAGIC"	},
+{ 0x73757245,	"CODA_SUPER_MAGIC"	},
+{ 0x74726163,	"TRACEFS_MAGIC"		},
+{ 0x794c7630,	"OVERLAYFS_SUPER_MAGIC"	},
+{ 0x858458f6,	"RAMFS_MAGIC"		},
+{ 0x9123683e,	"BTRFS_SUPER_MAGIC"	},
+{ 0x958458f6,	"HUGETLBFS_MAGIC"	},
+{ 0xabba1974,	"XENFS_SUPER_MAGIC"	},
+{ 0xcafe4a11,	"BPF_FS_MAGIC"		},
+{ 0xde5e81e4,	"EFIVARFS_MAGIC"	},
+{ 0xf2f52010,	"F2FS_SUPER_MAGIC"	},
+{ 0xf97cff8c,	"SELINUX_MAGIC"		},
+{ 0xf995e849,	"HPFS_SUPER_MAGIC"	},
+#unterminated
diff --git a/strace/xlat/futexops.h b/strace/xlat/futexops.h
new file mode 100644
index 0000000..536b162
--- /dev/null
+++ b/strace/xlat/futexops.h
@@ -0,0 +1,129 @@
+/* Generated by ./xlat/gen.sh from ./xlat/futexops.in; do not edit. */
+#if !(defined(FUTEX_WAIT) || (defined(HAVE_DECL_FUTEX_WAIT) && HAVE_DECL_FUTEX_WAIT))
+# define FUTEX_WAIT 0
+#endif
+#if !(defined(FUTEX_WAKE) || (defined(HAVE_DECL_FUTEX_WAKE) && HAVE_DECL_FUTEX_WAKE))
+# define FUTEX_WAKE 1
+#endif
+#if !(defined(FUTEX_FD) || (defined(HAVE_DECL_FUTEX_FD) && HAVE_DECL_FUTEX_FD))
+# define FUTEX_FD 2
+#endif
+#if !(defined(FUTEX_REQUEUE) || (defined(HAVE_DECL_FUTEX_REQUEUE) && HAVE_DECL_FUTEX_REQUEUE))
+# define FUTEX_REQUEUE 3
+#endif
+#if !(defined(FUTEX_CMP_REQUEUE) || (defined(HAVE_DECL_FUTEX_CMP_REQUEUE) && HAVE_DECL_FUTEX_CMP_REQUEUE))
+# define FUTEX_CMP_REQUEUE 4
+#endif
+#if !(defined(FUTEX_WAKE_OP) || (defined(HAVE_DECL_FUTEX_WAKE_OP) && HAVE_DECL_FUTEX_WAKE_OP))
+# define FUTEX_WAKE_OP 5
+#endif
+#if !(defined(FUTEX_LOCK_PI) || (defined(HAVE_DECL_FUTEX_LOCK_PI) && HAVE_DECL_FUTEX_LOCK_PI))
+# define FUTEX_LOCK_PI 6
+#endif
+#if !(defined(FUTEX_UNLOCK_PI) || (defined(HAVE_DECL_FUTEX_UNLOCK_PI) && HAVE_DECL_FUTEX_UNLOCK_PI))
+# define FUTEX_UNLOCK_PI 7
+#endif
+#if !(defined(FUTEX_TRYLOCK_PI) || (defined(HAVE_DECL_FUTEX_TRYLOCK_PI) && HAVE_DECL_FUTEX_TRYLOCK_PI))
+# define FUTEX_TRYLOCK_PI 8
+#endif
+#if !(defined(FUTEX_WAIT_BITSET) || (defined(HAVE_DECL_FUTEX_WAIT_BITSET) && HAVE_DECL_FUTEX_WAIT_BITSET))
+# define FUTEX_WAIT_BITSET 9
+#endif
+#if !(defined(FUTEX_WAKE_BITSET) || (defined(HAVE_DECL_FUTEX_WAKE_BITSET) && HAVE_DECL_FUTEX_WAKE_BITSET))
+# define FUTEX_WAKE_BITSET 10
+#endif
+#if !(defined(FUTEX_WAIT_REQUEUE_PI) || (defined(HAVE_DECL_FUTEX_WAIT_REQUEUE_PI) && HAVE_DECL_FUTEX_WAIT_REQUEUE_PI))
+# define FUTEX_WAIT_REQUEUE_PI 11
+#endif
+#if !(defined(FUTEX_CMP_REQUEUE_PI) || (defined(HAVE_DECL_FUTEX_CMP_REQUEUE_PI) && HAVE_DECL_FUTEX_CMP_REQUEUE_PI))
+# define FUTEX_CMP_REQUEUE_PI 12
+#endif
+#if !(defined(FUTEX_WAIT_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAIT_PRIVATE) && HAVE_DECL_FUTEX_WAIT_PRIVATE))
+# define FUTEX_WAIT_PRIVATE (FUTEX_WAIT | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_WAKE_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAKE_PRIVATE) && HAVE_DECL_FUTEX_WAKE_PRIVATE))
+# define FUTEX_WAKE_PRIVATE (FUTEX_WAKE | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_REQUEUE_PRIVATE) || (defined(HAVE_DECL_FUTEX_REQUEUE_PRIVATE) && HAVE_DECL_FUTEX_REQUEUE_PRIVATE))
+# define FUTEX_REQUEUE_PRIVATE (FUTEX_REQUEUE | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_CMP_REQUEUE_PRIVATE) || (defined(HAVE_DECL_FUTEX_CMP_REQUEUE_PRIVATE) && HAVE_DECL_FUTEX_CMP_REQUEUE_PRIVATE))
+# define FUTEX_CMP_REQUEUE_PRIVATE (FUTEX_CMP_REQUEUE | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_WAKE_OP_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAKE_OP_PRIVATE) && HAVE_DECL_FUTEX_WAKE_OP_PRIVATE))
+# define FUTEX_WAKE_OP_PRIVATE (FUTEX_WAKE_OP | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_LOCK_PI_PRIVATE) || (defined(HAVE_DECL_FUTEX_LOCK_PI_PRIVATE) && HAVE_DECL_FUTEX_LOCK_PI_PRIVATE))
+# define FUTEX_LOCK_PI_PRIVATE (FUTEX_LOCK_PI | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_UNLOCK_PI_PRIVATE) || (defined(HAVE_DECL_FUTEX_UNLOCK_PI_PRIVATE) && HAVE_DECL_FUTEX_UNLOCK_PI_PRIVATE))
+# define FUTEX_UNLOCK_PI_PRIVATE (FUTEX_UNLOCK_PI | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_TRYLOCK_PI_PRIVATE) || (defined(HAVE_DECL_FUTEX_TRYLOCK_PI_PRIVATE) && HAVE_DECL_FUTEX_TRYLOCK_PI_PRIVATE))
+# define FUTEX_TRYLOCK_PI_PRIVATE (FUTEX_TRYLOCK_PI | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_WAIT_BITSET_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAIT_BITSET_PRIVATE) && HAVE_DECL_FUTEX_WAIT_BITSET_PRIVATE))
+# define FUTEX_WAIT_BITSET_PRIVATE (FUTEX_WAIT_BITSET | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_WAKE_BITSET_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAKE_BITSET_PRIVATE) && HAVE_DECL_FUTEX_WAKE_BITSET_PRIVATE))
+# define FUTEX_WAKE_BITSET_PRIVATE (FUTEX_WAKE_BITSET | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_WAIT_REQUEUE_PI_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAIT_REQUEUE_PI_PRIVATE) && HAVE_DECL_FUTEX_WAIT_REQUEUE_PI_PRIVATE))
+# define FUTEX_WAIT_REQUEUE_PI_PRIVATE (FUTEX_WAIT_REQUEUE_PI | FUTEX_PRIVATE_FLAG)
+#endif
+#if !(defined(FUTEX_CMP_REQUEUE_PI_PRIVATE) || (defined(HAVE_DECL_FUTEX_CMP_REQUEUE_PI_PRIVATE) && HAVE_DECL_FUTEX_CMP_REQUEUE_PI_PRIVATE))
+# define FUTEX_CMP_REQUEUE_PI_PRIVATE (FUTEX_CMP_REQUEUE_PI | FUTEX_PRIVATE_FLAG)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat futexops in mpers mode
+
+#else
+
+static
+const struct xlat futexops[] = {
+ XLAT(FUTEX_WAIT),
+ XLAT(FUTEX_WAKE),
+ XLAT(FUTEX_FD),
+ XLAT(FUTEX_REQUEUE),
+ XLAT(FUTEX_CMP_REQUEUE),
+ XLAT(FUTEX_WAKE_OP),
+ XLAT(FUTEX_LOCK_PI),
+ XLAT(FUTEX_UNLOCK_PI),
+ XLAT(FUTEX_TRYLOCK_PI),
+ XLAT(FUTEX_WAIT_BITSET),
+ XLAT(FUTEX_WAKE_BITSET),
+ XLAT(FUTEX_WAIT_REQUEUE_PI),
+ XLAT(FUTEX_CMP_REQUEUE_PI),
+ XLAT(FUTEX_WAIT_PRIVATE),
+ XLAT(FUTEX_WAKE_PRIVATE),
+#if defined(FUTEX_FD) || (defined(HAVE_DECL_FUTEX_FD) && HAVE_DECL_FUTEX_FD)
+  XLAT(FUTEX_FD|FUTEX_PRIVATE_FLAG),
+#endif
+ XLAT(FUTEX_REQUEUE_PRIVATE),
+ XLAT(FUTEX_CMP_REQUEUE_PRIVATE),
+ XLAT(FUTEX_WAKE_OP_PRIVATE),
+ XLAT(FUTEX_LOCK_PI_PRIVATE),
+ XLAT(FUTEX_UNLOCK_PI_PRIVATE),
+ XLAT(FUTEX_TRYLOCK_PI_PRIVATE),
+ XLAT(FUTEX_WAIT_BITSET_PRIVATE),
+ XLAT(FUTEX_WAKE_BITSET_PRIVATE),
+ XLAT(FUTEX_WAIT_REQUEUE_PI_PRIVATE),
+ XLAT(FUTEX_CMP_REQUEUE_PI_PRIVATE),
+#if defined(FUTEX_WAIT_BITSET) || (defined(HAVE_DECL_FUTEX_WAIT_BITSET) && HAVE_DECL_FUTEX_WAIT_BITSET)
+  XLAT(FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME),
+#endif
+#if defined(FUTEX_WAIT_BITSET_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAIT_BITSET_PRIVATE) && HAVE_DECL_FUTEX_WAIT_BITSET_PRIVATE)
+  XLAT(FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME),
+#endif
+#if defined(FUTEX_WAIT_REQUEUE_PI) || (defined(HAVE_DECL_FUTEX_WAIT_REQUEUE_PI) && HAVE_DECL_FUTEX_WAIT_REQUEUE_PI)
+  XLAT(FUTEX_WAIT_REQUEUE_PI|FUTEX_CLOCK_REALTIME),
+#endif
+#if defined(FUTEX_WAIT_REQUEUE_PI_PRIVATE) || (defined(HAVE_DECL_FUTEX_WAIT_REQUEUE_PI_PRIVATE) && HAVE_DECL_FUTEX_WAIT_REQUEUE_PI_PRIVATE)
+  XLAT(FUTEX_WAIT_REQUEUE_PI_PRIVATE|FUTEX_CLOCK_REALTIME),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/futexops.in b/strace/xlat/futexops.in
new file mode 100644
index 0000000..3372673
--- /dev/null
+++ b/strace/xlat/futexops.in
@@ -0,0 +1,30 @@
+FUTEX_WAIT	0
+FUTEX_WAKE	1
+FUTEX_FD	2
+FUTEX_REQUEUE	3
+FUTEX_CMP_REQUEUE	4
+FUTEX_WAKE_OP	5
+FUTEX_LOCK_PI	6
+FUTEX_UNLOCK_PI	7
+FUTEX_TRYLOCK_PI	8
+FUTEX_WAIT_BITSET	9
+FUTEX_WAKE_BITSET	10
+FUTEX_WAIT_REQUEUE_PI	11
+FUTEX_CMP_REQUEUE_PI	12
+FUTEX_WAIT_PRIVATE	(FUTEX_WAIT | FUTEX_PRIVATE_FLAG)
+FUTEX_WAKE_PRIVATE	(FUTEX_WAKE | FUTEX_PRIVATE_FLAG)
+FUTEX_FD|FUTEX_PRIVATE_FLAG
+FUTEX_REQUEUE_PRIVATE	(FUTEX_REQUEUE | FUTEX_PRIVATE_FLAG)
+FUTEX_CMP_REQUEUE_PRIVATE	(FUTEX_CMP_REQUEUE | FUTEX_PRIVATE_FLAG)
+FUTEX_WAKE_OP_PRIVATE	(FUTEX_WAKE_OP | FUTEX_PRIVATE_FLAG)
+FUTEX_LOCK_PI_PRIVATE	(FUTEX_LOCK_PI | FUTEX_PRIVATE_FLAG)
+FUTEX_UNLOCK_PI_PRIVATE	(FUTEX_UNLOCK_PI | FUTEX_PRIVATE_FLAG)
+FUTEX_TRYLOCK_PI_PRIVATE	(FUTEX_TRYLOCK_PI | FUTEX_PRIVATE_FLAG)
+FUTEX_WAIT_BITSET_PRIVATE	(FUTEX_WAIT_BITSET | FUTEX_PRIVATE_FLAG)
+FUTEX_WAKE_BITSET_PRIVATE	(FUTEX_WAKE_BITSET | FUTEX_PRIVATE_FLAG)
+FUTEX_WAIT_REQUEUE_PI_PRIVATE	(FUTEX_WAIT_REQUEUE_PI | FUTEX_PRIVATE_FLAG)
+FUTEX_CMP_REQUEUE_PI_PRIVATE	(FUTEX_CMP_REQUEUE_PI | FUTEX_PRIVATE_FLAG)
+FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME
+FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME
+FUTEX_WAIT_REQUEUE_PI|FUTEX_CLOCK_REALTIME
+FUTEX_WAIT_REQUEUE_PI_PRIVATE|FUTEX_CLOCK_REALTIME
diff --git a/strace/xlat/futexwakecmps.h b/strace/xlat/futexwakecmps.h
new file mode 100644
index 0000000..379e0a0
--- /dev/null
+++ b/strace/xlat/futexwakecmps.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/futexwakecmps.in; do not edit. */
+#if !(defined(FUTEX_OP_CMP_EQ) || (defined(HAVE_DECL_FUTEX_OP_CMP_EQ) && HAVE_DECL_FUTEX_OP_CMP_EQ))
+# define FUTEX_OP_CMP_EQ 0
+#endif
+#if !(defined(FUTEX_OP_CMP_NE) || (defined(HAVE_DECL_FUTEX_OP_CMP_NE) && HAVE_DECL_FUTEX_OP_CMP_NE))
+# define FUTEX_OP_CMP_NE 1
+#endif
+#if !(defined(FUTEX_OP_CMP_LT) || (defined(HAVE_DECL_FUTEX_OP_CMP_LT) && HAVE_DECL_FUTEX_OP_CMP_LT))
+# define FUTEX_OP_CMP_LT 2
+#endif
+#if !(defined(FUTEX_OP_CMP_LE) || (defined(HAVE_DECL_FUTEX_OP_CMP_LE) && HAVE_DECL_FUTEX_OP_CMP_LE))
+# define FUTEX_OP_CMP_LE 3
+#endif
+#if !(defined(FUTEX_OP_CMP_GT) || (defined(HAVE_DECL_FUTEX_OP_CMP_GT) && HAVE_DECL_FUTEX_OP_CMP_GT))
+# define FUTEX_OP_CMP_GT 4
+#endif
+#if !(defined(FUTEX_OP_CMP_GE) || (defined(HAVE_DECL_FUTEX_OP_CMP_GE) && HAVE_DECL_FUTEX_OP_CMP_GE))
+# define FUTEX_OP_CMP_GE 5
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat futexwakecmps in mpers mode
+
+#else
+
+static
+const struct xlat futexwakecmps[] = {
+ XLAT(FUTEX_OP_CMP_EQ),
+ XLAT(FUTEX_OP_CMP_NE),
+ XLAT(FUTEX_OP_CMP_LT),
+ XLAT(FUTEX_OP_CMP_LE),
+ XLAT(FUTEX_OP_CMP_GT),
+ XLAT(FUTEX_OP_CMP_GE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/futexwakecmps.in b/strace/xlat/futexwakecmps.in
new file mode 100644
index 0000000..743e44c
--- /dev/null
+++ b/strace/xlat/futexwakecmps.in
@@ -0,0 +1,6 @@
+FUTEX_OP_CMP_EQ	0
+FUTEX_OP_CMP_NE	1
+FUTEX_OP_CMP_LT	2
+FUTEX_OP_CMP_LE	3
+FUTEX_OP_CMP_GT	4
+FUTEX_OP_CMP_GE	5
diff --git a/strace/xlat/futexwakeops.h b/strace/xlat/futexwakeops.h
new file mode 100644
index 0000000..cd9b6b5
--- /dev/null
+++ b/strace/xlat/futexwakeops.h
@@ -0,0 +1,34 @@
+/* Generated by ./xlat/gen.sh from ./xlat/futexwakeops.in; do not edit. */
+#if !(defined(FUTEX_OP_SET) || (defined(HAVE_DECL_FUTEX_OP_SET) && HAVE_DECL_FUTEX_OP_SET))
+# define FUTEX_OP_SET 0
+#endif
+#if !(defined(FUTEX_OP_ADD) || (defined(HAVE_DECL_FUTEX_OP_ADD) && HAVE_DECL_FUTEX_OP_ADD))
+# define FUTEX_OP_ADD 1
+#endif
+#if !(defined(FUTEX_OP_OR) || (defined(HAVE_DECL_FUTEX_OP_OR) && HAVE_DECL_FUTEX_OP_OR))
+# define FUTEX_OP_OR 2
+#endif
+#if !(defined(FUTEX_OP_ANDN) || (defined(HAVE_DECL_FUTEX_OP_ANDN) && HAVE_DECL_FUTEX_OP_ANDN))
+# define FUTEX_OP_ANDN 3
+#endif
+#if !(defined(FUTEX_OP_XOR) || (defined(HAVE_DECL_FUTEX_OP_XOR) && HAVE_DECL_FUTEX_OP_XOR))
+# define FUTEX_OP_XOR 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat futexwakeops in mpers mode
+
+#else
+
+static
+const struct xlat futexwakeops[] = {
+ XLAT(FUTEX_OP_SET),
+ XLAT(FUTEX_OP_ADD),
+ XLAT(FUTEX_OP_OR),
+ XLAT(FUTEX_OP_ANDN),
+ XLAT(FUTEX_OP_XOR),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/futexwakeops.in b/strace/xlat/futexwakeops.in
new file mode 100644
index 0000000..5bb5b19
--- /dev/null
+++ b/strace/xlat/futexwakeops.in
@@ -0,0 +1,5 @@
+FUTEX_OP_SET	0
+FUTEX_OP_ADD	1
+FUTEX_OP_OR	2
+FUTEX_OP_ANDN	3
+FUTEX_OP_XOR	4
diff --git a/strace/xlat/gen.sh b/strace/xlat/gen.sh
new file mode 100755
index 0000000..cf78c47
--- /dev/null
+++ b/strace/xlat/gen.sh
@@ -0,0 +1,316 @@
+#!/bin/sh
+#
+# Copyright (c) 2014-2015 Mike Frysinger <vapier@gentoo.org>
+# Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+# 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.
+
+usage()
+{
+	cat <<EOF
+Usage: $0 <input> <output>
+
+Generate xlat header files from <input> (a file or dir of files) and write
+the generated headers to <output>.
+EOF
+	exit 1
+}
+
+cond_def()
+{
+	local line
+	line="$1"; shift
+
+	local val
+	val="$(printf %s "$line" |
+		sed -n 's/^\([^[:space:]]\+\).*$/\1/p')"
+
+	local def
+	def="$(printf %s "${line}" |
+		sed -n 's/^[^[:space:]]\+[[:space:]]\+\([^[:space:]].*\)$/\1/p')"
+
+	if [ -n "$def" ]; then
+		cat <<-EOF
+		#if !(defined($val) || (defined(HAVE_DECL_$val) && HAVE_DECL_$val))
+		# define $val $def
+		#endif
+		EOF
+	fi
+}
+
+print_xlat()
+{
+	local val
+	val="$1"; shift
+
+	if [ -z "${val_type-}" ]; then
+		echo " XLAT(${val}),"
+	else
+		echo " XLAT_TYPE(${val_type}, ${val}),"
+	fi
+}
+
+print_xlat_pair()
+{
+	local val str
+	val="$1"; shift
+	str="$1"; shift
+
+	if [ -z "${val_type-}" ]; then
+		echo " XLAT_PAIR(${val}, \"${str}\"),"
+	else
+		echo " XLAT_TYPE_PAIR(${val_type}, ${val}, \"${str}\"),"
+	fi
+}
+
+cond_xlat()
+{
+	local line val m def xlat
+	line="$1"; shift
+
+	val="$(printf %s "${line}" | sed -n 's/^\([^[:space:]]\+\).*$/\1/p')"
+	m="${val%%|*}"
+	def="$(printf %s "${line}" |
+	       sed -n 's/^[^[:space:]]\+[[:space:]]\+\([^[:space:]].*\)$/\1/p')"
+
+	if [ "${m}" = "${m#1<<}" ]; then
+		xlat="$(print_xlat "${val}")"
+	else
+		xlat="$(print_xlat_pair "1ULL<<${val#1<<}" "${val}")"
+		m="${m#1<<}"
+	fi
+
+	if [ -z "${def}" ]; then
+		cat <<-EOF
+		#if defined(${m}) || (defined(HAVE_DECL_${m}) && HAVE_DECL_${m})
+		 ${xlat}
+		#endif
+		EOF
+	else
+		echo "$xlat"
+	fi
+}
+
+gen_header()
+{
+	local input="$1" output="$2" name="$3"
+	echo "generating ${output}"
+	(
+	local defs="${0%/*}/../defs.h"
+	local mpers="${0%/*}/../mpers_xlat.h"
+	local decl="extern const struct xlat ${name}[];"
+	local in_defs= in_mpers=
+
+	if grep -F -x "$decl" "$defs" > /dev/null; then
+		in_defs=1
+	elif grep -F -x "$decl" "$mpers" > /dev/null; then
+		in_mpers=1
+	fi
+
+	echo "/* Generated by $0 from $1; do not edit. */"
+
+	local unconditional= unterminated= line
+	# 1st pass: output directives.
+	while read line; do
+		LC_COLLATE=C
+		case $line in
+		'#conditional')
+			unconditional=
+			;;
+		'#unconditional')
+			unconditional=1
+			;;
+		'#unterminated')
+			unterminated=1
+			;;
+		'#val_type '*)
+			# to be processed during 2nd pass
+			;;
+		'#'*)
+			echo "${line}"
+			;;
+		[A-Z_]*)
+			[ -n "$unconditional" ] ||
+				cond_def "$line"
+			;;
+		esac
+	done < "$input"
+
+	echo
+	if [ -n "$in_defs" ]; then
+		cat <<-EOF
+			#ifndef IN_MPERS
+
+		EOF
+	elif [ -n "$in_mpers" ]; then
+		cat <<-EOF
+			#ifdef IN_MPERS
+
+			${decl}
+
+			#else
+
+			# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+			static
+			# endif
+		EOF
+	else
+		cat <<-EOF
+			#ifdef IN_MPERS
+
+			# error static const struct xlat ${name} in mpers mode
+
+			#else
+
+			static
+		EOF
+	fi
+	echo "const struct xlat ${name}[] = {"
+
+	unconditional= val_type=
+	# 2nd pass: output everything.
+	while read line; do
+		LC_COLLATE=C
+		case ${line} in
+		'#conditional')
+			unconditional=
+			;;
+		'#unconditional')
+			unconditional=1
+			;;
+		'#unterminated')
+			# processed during 1st pass
+			;;
+		'#val_type '*)
+			val_type="${line#\#val_type }"
+			;;
+		[A-Z_]*)	# symbolic constants
+			if [ -n "${unconditional}" ]; then
+				print_xlat "${line}"
+			else
+				cond_xlat "${line}"
+			fi
+			;;
+		'1<<'[A-Z_]*)	# symbolic constants with shift
+			if [ -n "${unconditional}" ]; then
+				print_xlat_pair "1ULL<<${line#1<<}" "${line}"
+			else
+				cond_xlat "${line}"
+			fi
+			;;
+		[0-9]*)	# numeric constants
+			print_xlat "${line}"
+			;;
+		*)	# verbatim lines
+			echo "${line}"
+			;;
+		esac
+	done < "${input}"
+	if [ -n "${unterminated}" ]; then
+		echo " /* this array should remain not NULL-terminated */"
+	else
+		echo " XLAT_END"
+	fi
+
+	cat <<-EOF
+		};
+
+		#endif /* !IN_MPERS */
+	EOF
+	) >"${output}"
+}
+
+gen_make()
+{
+	local output="$1"
+	local name
+	shift
+	echo "generating ${output}"
+	(
+		printf "XLAT_INPUT_FILES = "
+		printf 'xlat/%s.in ' "$@"
+		echo
+		printf "XLAT_HEADER_FILES = "
+		printf 'xlat/%s.h ' "$@"
+		echo
+		for name; do
+			printf '$(top_srcdir)/xlat/%s.h: $(top_srcdir)/xlat/%s.in $(top_srcdir)/xlat/gen.sh\n' \
+				"${name}" "${name}"
+			echo '	$(AM_V_GEN)$(top_srcdir)/xlat/gen.sh $< $@'
+		done
+	) >"${output}"
+}
+
+gen_git()
+{
+	local output="$1"
+	shift
+	echo "generating ${output}"
+	(
+		printf '/%s\n' .gitignore Makemodule.am
+		printf '/%s.h\n' "$@"
+	) >"${output}"
+}
+
+main()
+{
+	case $# in
+	0) set -- "${0%/*}" "${0%/*}" ;;
+	2) ;;
+	*) usage ;;
+	esac
+
+	local input="$1"
+	local output="$2"
+	local name
+	local jobs=0
+	local ncpus="$(getconf _NPROCESSORS_ONLN)"
+	[ "${ncpus}" -ge 1 ] ||
+		ncpus=1
+
+	if [ -d "${input}" ]; then
+		local f names=
+		for f in "${input}"/*.in; do
+			[ -f "${f}" ] || continue
+			name=${f##*/}
+			name=${name%.in}
+			gen_header "${f}" "${output}/${name}.h" "${name}" &
+			names="${names} ${name}"
+			: $(( jobs += 1 ))
+			if [ ${jobs} -ge ${ncpus} ]; then
+				jobs=0
+				wait
+			fi
+		done
+		gen_git "${output}/.gitignore" ${names}
+		gen_make "${output}/Makemodule.am" ${names}
+		wait
+	else
+		name=${input##*/}
+		name=${name%.in}
+		gen_header "${input}" "${output}" "${name}"
+	fi
+}
+
+main "$@"
diff --git a/strace/xlat/getrandom_flags.h b/strace/xlat/getrandom_flags.h
new file mode 100644
index 0000000..6b88199
--- /dev/null
+++ b/strace/xlat/getrandom_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/getrandom_flags.in; do not edit. */
+#if !(defined(GRND_NONBLOCK) || (defined(HAVE_DECL_GRND_NONBLOCK) && HAVE_DECL_GRND_NONBLOCK))
+# define GRND_NONBLOCK 1
+#endif
+#if !(defined(GRND_RANDOM) || (defined(HAVE_DECL_GRND_RANDOM) && HAVE_DECL_GRND_RANDOM))
+# define GRND_RANDOM 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat getrandom_flags in mpers mode
+
+#else
+
+static
+const struct xlat getrandom_flags[] = {
+ XLAT(GRND_NONBLOCK),
+ XLAT(GRND_RANDOM),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/getrandom_flags.in b/strace/xlat/getrandom_flags.in
new file mode 100644
index 0000000..ad1a758
--- /dev/null
+++ b/strace/xlat/getrandom_flags.in
@@ -0,0 +1,2 @@
+GRND_NONBLOCK	1
+GRND_RANDOM	2
diff --git a/strace/xlat/getsockipoptions.h b/strace/xlat/getsockipoptions.h
new file mode 100644
index 0000000..cd043a1
--- /dev/null
+++ b/strace/xlat/getsockipoptions.h
@@ -0,0 +1,83 @@
+/* Generated by ./xlat/gen.sh from ./xlat/getsockipoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat getsockipoptions in mpers mode
+
+#else
+
+static
+const struct xlat getsockipoptions[] = {
+/*
+* Options specific to getsockopt(SOL_IP).
+* Common {g,s}etsockopt(SOL_IP) options
+* should be in sockipoptions.in instead.
+*/
+
+#if defined(ARPT_SO_GET_INFO) || (defined(HAVE_DECL_ARPT_SO_GET_INFO) && HAVE_DECL_ARPT_SO_GET_INFO)
+  XLAT(ARPT_SO_GET_INFO),
+#endif
+#if defined(ARPT_SO_GET_ENTRIES) || (defined(HAVE_DECL_ARPT_SO_GET_ENTRIES) && HAVE_DECL_ARPT_SO_GET_ENTRIES)
+  XLAT(ARPT_SO_GET_ENTRIES),
+#endif
+#if defined(ARPT_SO_GET_REVISION_MATCH) || (defined(HAVE_DECL_ARPT_SO_GET_REVISION_MATCH) && HAVE_DECL_ARPT_SO_GET_REVISION_MATCH)
+  XLAT(ARPT_SO_GET_REVISION_MATCH),
+#endif
+#if defined(ARPT_SO_GET_REVISION_TARGET) || (defined(HAVE_DECL_ARPT_SO_GET_REVISION_TARGET) && HAVE_DECL_ARPT_SO_GET_REVISION_TARGET)
+  XLAT(ARPT_SO_GET_REVISION_TARGET),
+#endif
+
+#if defined(EBT_SO_GET_INFO) || (defined(HAVE_DECL_EBT_SO_GET_INFO) && HAVE_DECL_EBT_SO_GET_INFO)
+  XLAT(EBT_SO_GET_INFO),
+#endif
+#if defined(EBT_SO_GET_ENTRIES) || (defined(HAVE_DECL_EBT_SO_GET_ENTRIES) && HAVE_DECL_EBT_SO_GET_ENTRIES)
+  XLAT(EBT_SO_GET_ENTRIES),
+#endif
+#if defined(EBT_SO_GET_INIT_INFO) || (defined(HAVE_DECL_EBT_SO_GET_INIT_INFO) && HAVE_DECL_EBT_SO_GET_INIT_INFO)
+  XLAT(EBT_SO_GET_INIT_INFO),
+#endif
+#if defined(EBT_SO_GET_INIT_ENTRIES) || (defined(HAVE_DECL_EBT_SO_GET_INIT_ENTRIES) && HAVE_DECL_EBT_SO_GET_INIT_ENTRIES)
+  XLAT(EBT_SO_GET_INIT_ENTRIES),
+#endif
+
+#if defined(IP_VS_SO_GET_VERSION) || (defined(HAVE_DECL_IP_VS_SO_GET_VERSION) && HAVE_DECL_IP_VS_SO_GET_VERSION)
+  XLAT(IP_VS_SO_GET_VERSION),
+#endif
+#if defined(IP_VS_SO_GET_INFO) || (defined(HAVE_DECL_IP_VS_SO_GET_INFO) && HAVE_DECL_IP_VS_SO_GET_INFO)
+  XLAT(IP_VS_SO_GET_INFO),
+#endif
+#if defined(IP_VS_SO_GET_SERVICES) || (defined(HAVE_DECL_IP_VS_SO_GET_SERVICES) && HAVE_DECL_IP_VS_SO_GET_SERVICES)
+  XLAT(IP_VS_SO_GET_SERVICES),
+#endif
+#if defined(IP_VS_SO_GET_SERVICE) || (defined(HAVE_DECL_IP_VS_SO_GET_SERVICE) && HAVE_DECL_IP_VS_SO_GET_SERVICE)
+  XLAT(IP_VS_SO_GET_SERVICE),
+#endif
+#if defined(IP_VS_SO_GET_DESTS) || (defined(HAVE_DECL_IP_VS_SO_GET_DESTS) && HAVE_DECL_IP_VS_SO_GET_DESTS)
+  XLAT(IP_VS_SO_GET_DESTS),
+#endif
+#if defined(IP_VS_SO_GET_DEST) || (defined(HAVE_DECL_IP_VS_SO_GET_DEST) && HAVE_DECL_IP_VS_SO_GET_DEST)
+  XLAT(IP_VS_SO_GET_DEST),
+#endif
+#if defined(IP_VS_SO_GET_TIMEOUT) || (defined(HAVE_DECL_IP_VS_SO_GET_TIMEOUT) && HAVE_DECL_IP_VS_SO_GET_TIMEOUT)
+  XLAT(IP_VS_SO_GET_TIMEOUT),
+#endif
+#if defined(IP_VS_SO_GET_DAEMON) || (defined(HAVE_DECL_IP_VS_SO_GET_DAEMON) && HAVE_DECL_IP_VS_SO_GET_DAEMON)
+  XLAT(IP_VS_SO_GET_DAEMON),
+#endif
+
+#if defined(IPT_SO_GET_INFO) || (defined(HAVE_DECL_IPT_SO_GET_INFO) && HAVE_DECL_IPT_SO_GET_INFO)
+  XLAT(IPT_SO_GET_INFO),
+#endif
+#if defined(IPT_SO_GET_ENTRIES) || (defined(HAVE_DECL_IPT_SO_GET_ENTRIES) && HAVE_DECL_IPT_SO_GET_ENTRIES)
+  XLAT(IPT_SO_GET_ENTRIES),
+#endif
+#if defined(IPT_SO_GET_REVISION_MATCH) || (defined(HAVE_DECL_IPT_SO_GET_REVISION_MATCH) && HAVE_DECL_IPT_SO_GET_REVISION_MATCH)
+  XLAT(IPT_SO_GET_REVISION_MATCH),
+#endif
+#if defined(IPT_SO_GET_REVISION_TARGET) || (defined(HAVE_DECL_IPT_SO_GET_REVISION_TARGET) && HAVE_DECL_IPT_SO_GET_REVISION_TARGET)
+  XLAT(IPT_SO_GET_REVISION_TARGET),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/getsockipoptions.in b/strace/xlat/getsockipoptions.in
new file mode 100644
index 0000000..847cec2
--- /dev/null
+++ b/strace/xlat/getsockipoptions.in
@@ -0,0 +1,29 @@
+/*
+ * Options specific to getsockopt(SOL_IP).
+ * Common {g,s}etsockopt(SOL_IP) options
+ * should be in sockipoptions.in instead.
+ */
+
+ARPT_SO_GET_INFO
+ARPT_SO_GET_ENTRIES
+ARPT_SO_GET_REVISION_MATCH
+ARPT_SO_GET_REVISION_TARGET
+
+EBT_SO_GET_INFO
+EBT_SO_GET_ENTRIES
+EBT_SO_GET_INIT_INFO
+EBT_SO_GET_INIT_ENTRIES
+
+IP_VS_SO_GET_VERSION
+IP_VS_SO_GET_INFO
+IP_VS_SO_GET_SERVICES
+IP_VS_SO_GET_SERVICE
+IP_VS_SO_GET_DESTS
+IP_VS_SO_GET_DEST
+IP_VS_SO_GET_TIMEOUT
+IP_VS_SO_GET_DAEMON
+
+IPT_SO_GET_INFO
+IPT_SO_GET_ENTRIES
+IPT_SO_GET_REVISION_MATCH
+IPT_SO_GET_REVISION_TARGET
diff --git a/strace/xlat/getsockipv6options.h b/strace/xlat/getsockipv6options.h
new file mode 100644
index 0000000..402be18
--- /dev/null
+++ b/strace/xlat/getsockipv6options.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/getsockipv6options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat getsockipv6options in mpers mode
+
+#else
+
+static
+const struct xlat getsockipv6options[] = {
+/*
+* Options specific to getsockopt(SOL_IPV6).
+* Common {g,s}etsockopt(SOL_IPV6) options
+* should be in sockipv6options.in instead.
+*/
+
+#if defined(IP6T_SO_GET_INFO) || (defined(HAVE_DECL_IP6T_SO_GET_INFO) && HAVE_DECL_IP6T_SO_GET_INFO)
+  XLAT(IP6T_SO_GET_INFO),
+#endif
+#if defined(IP6T_SO_GET_ENTRIES) || (defined(HAVE_DECL_IP6T_SO_GET_ENTRIES) && HAVE_DECL_IP6T_SO_GET_ENTRIES)
+  XLAT(IP6T_SO_GET_ENTRIES),
+#endif
+#if defined(IP6T_SO_GET_REVISION_MATCH) || (defined(HAVE_DECL_IP6T_SO_GET_REVISION_MATCH) && HAVE_DECL_IP6T_SO_GET_REVISION_MATCH)
+  XLAT(IP6T_SO_GET_REVISION_MATCH),
+#endif
+#if defined(IP6T_SO_GET_REVISION_TARGET) || (defined(HAVE_DECL_IP6T_SO_GET_REVISION_TARGET) && HAVE_DECL_IP6T_SO_GET_REVISION_TARGET)
+  XLAT(IP6T_SO_GET_REVISION_TARGET),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/getsockipv6options.in b/strace/xlat/getsockipv6options.in
new file mode 100644
index 0000000..da44a10
--- /dev/null
+++ b/strace/xlat/getsockipv6options.in
@@ -0,0 +1,10 @@
+/*
+ * Options specific to getsockopt(SOL_IPV6).
+ * Common {g,s}etsockopt(SOL_IPV6) options
+ * should be in sockipv6options.in instead.
+ */
+
+IP6T_SO_GET_INFO
+IP6T_SO_GET_ENTRIES
+IP6T_SO_GET_REVISION_MATCH
+IP6T_SO_GET_REVISION_TARGET
diff --git a/strace/xlat/hci_channels.h b/strace/xlat/hci_channels.h
new file mode 100644
index 0000000..ab6d3e3
--- /dev/null
+++ b/strace/xlat/hci_channels.h
@@ -0,0 +1,29 @@
+/* Generated by ./xlat/gen.sh from ./xlat/hci_channels.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat hci_channels in mpers mode
+
+#else
+
+static
+const struct xlat hci_channels[] = {
+#if defined(HCI_CHANNEL_RAW) || (defined(HAVE_DECL_HCI_CHANNEL_RAW) && HAVE_DECL_HCI_CHANNEL_RAW)
+  XLAT(HCI_CHANNEL_RAW),
+#endif
+#if defined(HCI_CHANNEL_USER) || (defined(HAVE_DECL_HCI_CHANNEL_USER) && HAVE_DECL_HCI_CHANNEL_USER)
+  XLAT(HCI_CHANNEL_USER),
+#endif
+#if defined(HCI_CHANNEL_MONITOR) || (defined(HAVE_DECL_HCI_CHANNEL_MONITOR) && HAVE_DECL_HCI_CHANNEL_MONITOR)
+  XLAT(HCI_CHANNEL_MONITOR),
+#endif
+#if defined(HCI_CHANNEL_CONTROL) || (defined(HAVE_DECL_HCI_CHANNEL_CONTROL) && HAVE_DECL_HCI_CHANNEL_CONTROL)
+  XLAT(HCI_CHANNEL_CONTROL),
+#endif
+#if defined(HCI_CHANNEL_LOGGING) || (defined(HAVE_DECL_HCI_CHANNEL_LOGGING) && HAVE_DECL_HCI_CHANNEL_LOGGING)
+  XLAT(HCI_CHANNEL_LOGGING),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/hci_channels.in b/strace/xlat/hci_channels.in
new file mode 100644
index 0000000..1fae39b
--- /dev/null
+++ b/strace/xlat/hci_channels.in
@@ -0,0 +1,5 @@
+HCI_CHANNEL_RAW
+HCI_CHANNEL_USER
+HCI_CHANNEL_MONITOR
+HCI_CHANNEL_CONTROL
+HCI_CHANNEL_LOGGING
diff --git a/strace/xlat/icmpfilterflags.h b/strace/xlat/icmpfilterflags.h
new file mode 100644
index 0000000..1672a19
--- /dev/null
+++ b/strace/xlat/icmpfilterflags.h
@@ -0,0 +1,53 @@
+/* Generated by ./xlat/gen.sh from ./xlat/icmpfilterflags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat icmpfilterflags in mpers mode
+
+#else
+
+static
+const struct xlat icmpfilterflags[] = {
+#if defined(ICMP_ECHOREPLY) || (defined(HAVE_DECL_ICMP_ECHOREPLY) && HAVE_DECL_ICMP_ECHOREPLY)
+  XLAT_PAIR(1ULL<<ICMP_ECHOREPLY, "1<<ICMP_ECHOREPLY"),
+#endif
+#if defined(ICMP_DEST_UNREACH) || (defined(HAVE_DECL_ICMP_DEST_UNREACH) && HAVE_DECL_ICMP_DEST_UNREACH)
+  XLAT_PAIR(1ULL<<ICMP_DEST_UNREACH, "1<<ICMP_DEST_UNREACH"),
+#endif
+#if defined(ICMP_SOURCE_QUENCH) || (defined(HAVE_DECL_ICMP_SOURCE_QUENCH) && HAVE_DECL_ICMP_SOURCE_QUENCH)
+  XLAT_PAIR(1ULL<<ICMP_SOURCE_QUENCH, "1<<ICMP_SOURCE_QUENCH"),
+#endif
+#if defined(ICMP_REDIRECT) || (defined(HAVE_DECL_ICMP_REDIRECT) && HAVE_DECL_ICMP_REDIRECT)
+  XLAT_PAIR(1ULL<<ICMP_REDIRECT, "1<<ICMP_REDIRECT"),
+#endif
+#if defined(ICMP_ECHO) || (defined(HAVE_DECL_ICMP_ECHO) && HAVE_DECL_ICMP_ECHO)
+  XLAT_PAIR(1ULL<<ICMP_ECHO, "1<<ICMP_ECHO"),
+#endif
+#if defined(ICMP_TIME_EXCEEDED) || (defined(HAVE_DECL_ICMP_TIME_EXCEEDED) && HAVE_DECL_ICMP_TIME_EXCEEDED)
+  XLAT_PAIR(1ULL<<ICMP_TIME_EXCEEDED, "1<<ICMP_TIME_EXCEEDED"),
+#endif
+#if defined(ICMP_PARAMETERPROB) || (defined(HAVE_DECL_ICMP_PARAMETERPROB) && HAVE_DECL_ICMP_PARAMETERPROB)
+  XLAT_PAIR(1ULL<<ICMP_PARAMETERPROB, "1<<ICMP_PARAMETERPROB"),
+#endif
+#if defined(ICMP_TIMESTAMP) || (defined(HAVE_DECL_ICMP_TIMESTAMP) && HAVE_DECL_ICMP_TIMESTAMP)
+  XLAT_PAIR(1ULL<<ICMP_TIMESTAMP, "1<<ICMP_TIMESTAMP"),
+#endif
+#if defined(ICMP_TIMESTAMPREPLY) || (defined(HAVE_DECL_ICMP_TIMESTAMPREPLY) && HAVE_DECL_ICMP_TIMESTAMPREPLY)
+  XLAT_PAIR(1ULL<<ICMP_TIMESTAMPREPLY, "1<<ICMP_TIMESTAMPREPLY"),
+#endif
+#if defined(ICMP_INFO_REQUEST) || (defined(HAVE_DECL_ICMP_INFO_REQUEST) && HAVE_DECL_ICMP_INFO_REQUEST)
+  XLAT_PAIR(1ULL<<ICMP_INFO_REQUEST, "1<<ICMP_INFO_REQUEST"),
+#endif
+#if defined(ICMP_INFO_REPLY) || (defined(HAVE_DECL_ICMP_INFO_REPLY) && HAVE_DECL_ICMP_INFO_REPLY)
+  XLAT_PAIR(1ULL<<ICMP_INFO_REPLY, "1<<ICMP_INFO_REPLY"),
+#endif
+#if defined(ICMP_ADDRESS) || (defined(HAVE_DECL_ICMP_ADDRESS) && HAVE_DECL_ICMP_ADDRESS)
+  XLAT_PAIR(1ULL<<ICMP_ADDRESS, "1<<ICMP_ADDRESS"),
+#endif
+#if defined(ICMP_ADDRESSREPLY) || (defined(HAVE_DECL_ICMP_ADDRESSREPLY) && HAVE_DECL_ICMP_ADDRESSREPLY)
+  XLAT_PAIR(1ULL<<ICMP_ADDRESSREPLY, "1<<ICMP_ADDRESSREPLY"),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/icmpfilterflags.in b/strace/xlat/icmpfilterflags.in
new file mode 100644
index 0000000..dac579e
--- /dev/null
+++ b/strace/xlat/icmpfilterflags.in
@@ -0,0 +1,13 @@
+1<<ICMP_ECHOREPLY
+1<<ICMP_DEST_UNREACH
+1<<ICMP_SOURCE_QUENCH
+1<<ICMP_REDIRECT
+1<<ICMP_ECHO
+1<<ICMP_TIME_EXCEEDED
+1<<ICMP_PARAMETERPROB
+1<<ICMP_TIMESTAMP
+1<<ICMP_TIMESTAMPREPLY
+1<<ICMP_INFO_REQUEST
+1<<ICMP_INFO_REPLY
+1<<ICMP_ADDRESS
+1<<ICMP_ADDRESSREPLY
diff --git a/strace/xlat/if_dqblk_valid.h b/strace/xlat/if_dqblk_valid.h
new file mode 100644
index 0000000..67d3934
--- /dev/null
+++ b/strace/xlat/if_dqblk_valid.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/if_dqblk_valid.in; do not edit. */
+#if !(defined(QIF_BLIMITS) || (defined(HAVE_DECL_QIF_BLIMITS) && HAVE_DECL_QIF_BLIMITS))
+# define QIF_BLIMITS (1 << 0)
+#endif
+#if !(defined(QIF_SPACE) || (defined(HAVE_DECL_QIF_SPACE) && HAVE_DECL_QIF_SPACE))
+# define QIF_SPACE (1 << 1)
+#endif
+#if !(defined(QIF_ILIMITS) || (defined(HAVE_DECL_QIF_ILIMITS) && HAVE_DECL_QIF_ILIMITS))
+# define QIF_ILIMITS (1 << 2)
+#endif
+#if !(defined(QIF_INODES) || (defined(HAVE_DECL_QIF_INODES) && HAVE_DECL_QIF_INODES))
+# define QIF_INODES (1 << 3)
+#endif
+#if !(defined(QIF_BTIME) || (defined(HAVE_DECL_QIF_BTIME) && HAVE_DECL_QIF_BTIME))
+# define QIF_BTIME (1 << 4)
+#endif
+#if !(defined(QIF_ITIME) || (defined(HAVE_DECL_QIF_ITIME) && HAVE_DECL_QIF_ITIME))
+# define QIF_ITIME (1 << 5)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat if_dqblk_valid in mpers mode
+
+#else
+
+static
+const struct xlat if_dqblk_valid[] = {
+ XLAT(QIF_BLIMITS),
+ XLAT(QIF_SPACE),
+ XLAT(QIF_ILIMITS),
+ XLAT(QIF_INODES),
+ XLAT(QIF_BTIME),
+ XLAT(QIF_ITIME),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/if_dqblk_valid.in b/strace/xlat/if_dqblk_valid.in
new file mode 100644
index 0000000..2b3ea54
--- /dev/null
+++ b/strace/xlat/if_dqblk_valid.in
@@ -0,0 +1,6 @@
+QIF_BLIMITS	(1 << 0)
+QIF_SPACE	(1 << 1)
+QIF_ILIMITS	(1 << 2)
+QIF_INODES	(1 << 3)
+QIF_BTIME	(1 << 4)
+QIF_ITIME	(1 << 5)
diff --git a/strace/xlat/if_dqinfo_flags.h b/strace/xlat/if_dqinfo_flags.h
new file mode 100644
index 0000000..72b2690
--- /dev/null
+++ b/strace/xlat/if_dqinfo_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/if_dqinfo_flags.in; do not edit. */
+#if !(defined(DQF_ROOT_SQUASH) || (defined(HAVE_DECL_DQF_ROOT_SQUASH) && HAVE_DECL_DQF_ROOT_SQUASH))
+# define DQF_ROOT_SQUASH (1 << 0)
+#endif
+#if !(defined(DQF_SYS_FILE) || (defined(HAVE_DECL_DQF_SYS_FILE) && HAVE_DECL_DQF_SYS_FILE))
+# define DQF_SYS_FILE (1 << 16)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat if_dqinfo_flags in mpers mode
+
+#else
+
+static
+const struct xlat if_dqinfo_flags[] = {
+ XLAT(DQF_ROOT_SQUASH),
+ XLAT(DQF_SYS_FILE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/if_dqinfo_flags.in b/strace/xlat/if_dqinfo_flags.in
new file mode 100644
index 0000000..914532c
--- /dev/null
+++ b/strace/xlat/if_dqinfo_flags.in
@@ -0,0 +1,2 @@
+DQF_ROOT_SQUASH	(1 << 0)
+DQF_SYS_FILE	(1 << 16)
diff --git a/strace/xlat/if_dqinfo_valid.h b/strace/xlat/if_dqinfo_valid.h
new file mode 100644
index 0000000..8944d17
--- /dev/null
+++ b/strace/xlat/if_dqinfo_valid.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/if_dqinfo_valid.in; do not edit. */
+#if !(defined(IIF_BGRACE) || (defined(HAVE_DECL_IIF_BGRACE) && HAVE_DECL_IIF_BGRACE))
+# define IIF_BGRACE (1 << 0)
+#endif
+#if !(defined(IIF_IGRACE) || (defined(HAVE_DECL_IIF_IGRACE) && HAVE_DECL_IIF_IGRACE))
+# define IIF_IGRACE (1 << 1)
+#endif
+#if !(defined(IIF_FLAGS) || (defined(HAVE_DECL_IIF_FLAGS) && HAVE_DECL_IIF_FLAGS))
+# define IIF_FLAGS (1 << 2)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat if_dqinfo_valid in mpers mode
+
+#else
+
+static
+const struct xlat if_dqinfo_valid[] = {
+ XLAT(IIF_BGRACE),
+ XLAT(IIF_IGRACE),
+ XLAT(IIF_FLAGS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/if_dqinfo_valid.in b/strace/xlat/if_dqinfo_valid.in
new file mode 100644
index 0000000..7d6eca6
--- /dev/null
+++ b/strace/xlat/if_dqinfo_valid.in
@@ -0,0 +1,3 @@
+IIF_BGRACE	(1 << 0)
+IIF_IGRACE	(1 << 1)
+IIF_FLAGS	(1 << 2)
diff --git a/strace/xlat/iffflags.h b/strace/xlat/iffflags.h
new file mode 100644
index 0000000..5047b65
--- /dev/null
+++ b/strace/xlat/iffflags.h
@@ -0,0 +1,59 @@
+/* Generated by ./xlat/gen.sh from ./xlat/iffflags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat iffflags in mpers mode
+
+#else
+
+static
+const struct xlat iffflags[] = {
+#if defined(IFF_UP) || (defined(HAVE_DECL_IFF_UP) && HAVE_DECL_IFF_UP)
+  XLAT(IFF_UP),
+#endif
+#if defined(IFF_BROADCAST) || (defined(HAVE_DECL_IFF_BROADCAST) && HAVE_DECL_IFF_BROADCAST)
+  XLAT(IFF_BROADCAST),
+#endif
+#if defined(IFF_DEBUG) || (defined(HAVE_DECL_IFF_DEBUG) && HAVE_DECL_IFF_DEBUG)
+  XLAT(IFF_DEBUG),
+#endif
+#if defined(IFF_LOOPBACK) || (defined(HAVE_DECL_IFF_LOOPBACK) && HAVE_DECL_IFF_LOOPBACK)
+  XLAT(IFF_LOOPBACK),
+#endif
+#if defined(IFF_POINTOPOINT) || (defined(HAVE_DECL_IFF_POINTOPOINT) && HAVE_DECL_IFF_POINTOPOINT)
+  XLAT(IFF_POINTOPOINT),
+#endif
+#if defined(IFF_NOTRAILERS) || (defined(HAVE_DECL_IFF_NOTRAILERS) && HAVE_DECL_IFF_NOTRAILERS)
+  XLAT(IFF_NOTRAILERS),
+#endif
+#if defined(IFF_RUNNING) || (defined(HAVE_DECL_IFF_RUNNING) && HAVE_DECL_IFF_RUNNING)
+  XLAT(IFF_RUNNING),
+#endif
+#if defined(IFF_NOARP) || (defined(HAVE_DECL_IFF_NOARP) && HAVE_DECL_IFF_NOARP)
+  XLAT(IFF_NOARP),
+#endif
+#if defined(IFF_PROMISC) || (defined(HAVE_DECL_IFF_PROMISC) && HAVE_DECL_IFF_PROMISC)
+  XLAT(IFF_PROMISC),
+#endif
+#if defined(IFF_ALLMULTI) || (defined(HAVE_DECL_IFF_ALLMULTI) && HAVE_DECL_IFF_ALLMULTI)
+  XLAT(IFF_ALLMULTI),
+#endif
+#if defined(IFF_MASTER) || (defined(HAVE_DECL_IFF_MASTER) && HAVE_DECL_IFF_MASTER)
+  XLAT(IFF_MASTER),
+#endif
+#if defined(IFF_SLAVE) || (defined(HAVE_DECL_IFF_SLAVE) && HAVE_DECL_IFF_SLAVE)
+  XLAT(IFF_SLAVE),
+#endif
+#if defined(IFF_MULTICAST) || (defined(HAVE_DECL_IFF_MULTICAST) && HAVE_DECL_IFF_MULTICAST)
+  XLAT(IFF_MULTICAST),
+#endif
+#if defined(IFF_PORTSEL) || (defined(HAVE_DECL_IFF_PORTSEL) && HAVE_DECL_IFF_PORTSEL)
+  XLAT(IFF_PORTSEL),
+#endif
+#if defined(IFF_AUTOMEDIA) || (defined(HAVE_DECL_IFF_AUTOMEDIA) && HAVE_DECL_IFF_AUTOMEDIA)
+  XLAT(IFF_AUTOMEDIA),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/iffflags.in b/strace/xlat/iffflags.in
new file mode 100644
index 0000000..a6249b0
--- /dev/null
+++ b/strace/xlat/iffflags.in
@@ -0,0 +1,15 @@
+IFF_UP
+IFF_BROADCAST
+IFF_DEBUG
+IFF_LOOPBACK
+IFF_POINTOPOINT
+IFF_NOTRAILERS
+IFF_RUNNING
+IFF_NOARP
+IFF_PROMISC
+IFF_ALLMULTI
+IFF_MASTER
+IFF_SLAVE
+IFF_MULTICAST
+IFF_PORTSEL
+IFF_AUTOMEDIA
diff --git a/strace/xlat/inet_protocols.h b/strace/xlat/inet_protocols.h
new file mode 100644
index 0000000..73d1133
--- /dev/null
+++ b/strace/xlat/inet_protocols.h
@@ -0,0 +1,113 @@
+/* Generated by ./xlat/gen.sh from ./xlat/inet_protocols.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat inet_protocols in mpers mode
+
+#else
+
+static
+const struct xlat inet_protocols[] = {
+#if defined(IPPROTO_IP) || (defined(HAVE_DECL_IPPROTO_IP) && HAVE_DECL_IPPROTO_IP)
+  XLAT(IPPROTO_IP),
+#endif
+#if defined(IPPROTO_ICMP) || (defined(HAVE_DECL_IPPROTO_ICMP) && HAVE_DECL_IPPROTO_ICMP)
+  XLAT(IPPROTO_ICMP),
+#endif
+#if defined(IPPROTO_TCP) || (defined(HAVE_DECL_IPPROTO_TCP) && HAVE_DECL_IPPROTO_TCP)
+  XLAT(IPPROTO_TCP),
+#endif
+#if defined(IPPROTO_UDP) || (defined(HAVE_DECL_IPPROTO_UDP) && HAVE_DECL_IPPROTO_UDP)
+  XLAT(IPPROTO_UDP),
+#endif
+#if defined(IPPROTO_IGMP) || (defined(HAVE_DECL_IPPROTO_IGMP) && HAVE_DECL_IPPROTO_IGMP)
+  XLAT(IPPROTO_IGMP),
+#endif
+#if defined(IPPROTO_GGP) || (defined(HAVE_DECL_IPPROTO_GGP) && HAVE_DECL_IPPROTO_GGP)
+  XLAT(IPPROTO_GGP),
+#endif
+#if defined(IPPROTO_IPIP) || (defined(HAVE_DECL_IPPROTO_IPIP) && HAVE_DECL_IPPROTO_IPIP)
+  XLAT(IPPROTO_IPIP),
+#endif
+#if defined(IPPROTO_EGP) || (defined(HAVE_DECL_IPPROTO_EGP) && HAVE_DECL_IPPROTO_EGP)
+  XLAT(IPPROTO_EGP),
+#endif
+#if defined(IPPROTO_PUP) || (defined(HAVE_DECL_IPPROTO_PUP) && HAVE_DECL_IPPROTO_PUP)
+  XLAT(IPPROTO_PUP),
+#endif
+#if defined(IPPROTO_IDP) || (defined(HAVE_DECL_IPPROTO_IDP) && HAVE_DECL_IPPROTO_IDP)
+  XLAT(IPPROTO_IDP),
+#endif
+#if defined(IPPROTO_TP) || (defined(HAVE_DECL_IPPROTO_TP) && HAVE_DECL_IPPROTO_TP)
+  XLAT(IPPROTO_TP),
+#endif
+#if defined(IPPROTO_DCCP) || (defined(HAVE_DECL_IPPROTO_DCCP) && HAVE_DECL_IPPROTO_DCCP)
+  XLAT(IPPROTO_DCCP),
+#endif
+#if defined(IPPROTO_IPV6) || (defined(HAVE_DECL_IPPROTO_IPV6) && HAVE_DECL_IPPROTO_IPV6)
+  XLAT(IPPROTO_IPV6),
+#endif
+#if defined(IPPROTO_ROUTING) || (defined(HAVE_DECL_IPPROTO_ROUTING) && HAVE_DECL_IPPROTO_ROUTING)
+  XLAT(IPPROTO_ROUTING),
+#endif
+#if defined(IPPROTO_FRAGMENT) || (defined(HAVE_DECL_IPPROTO_FRAGMENT) && HAVE_DECL_IPPROTO_FRAGMENT)
+  XLAT(IPPROTO_FRAGMENT),
+#endif
+#if defined(IPPROTO_RSVP) || (defined(HAVE_DECL_IPPROTO_RSVP) && HAVE_DECL_IPPROTO_RSVP)
+  XLAT(IPPROTO_RSVP),
+#endif
+#if defined(IPPROTO_GRE) || (defined(HAVE_DECL_IPPROTO_GRE) && HAVE_DECL_IPPROTO_GRE)
+  XLAT(IPPROTO_GRE),
+#endif
+#if defined(IPPROTO_ESP) || (defined(HAVE_DECL_IPPROTO_ESP) && HAVE_DECL_IPPROTO_ESP)
+  XLAT(IPPROTO_ESP),
+#endif
+#if defined(IPPROTO_AH) || (defined(HAVE_DECL_IPPROTO_AH) && HAVE_DECL_IPPROTO_AH)
+  XLAT(IPPROTO_AH),
+#endif
+#if defined(IPPROTO_ICMPV6) || (defined(HAVE_DECL_IPPROTO_ICMPV6) && HAVE_DECL_IPPROTO_ICMPV6)
+  XLAT(IPPROTO_ICMPV6),
+#endif
+#if defined(IPPROTO_NONE) || (defined(HAVE_DECL_IPPROTO_NONE) && HAVE_DECL_IPPROTO_NONE)
+  XLAT(IPPROTO_NONE),
+#endif
+#if defined(IPPROTO_DSTOPTS) || (defined(HAVE_DECL_IPPROTO_DSTOPTS) && HAVE_DECL_IPPROTO_DSTOPTS)
+  XLAT(IPPROTO_DSTOPTS),
+#endif
+#if defined(IPPROTO_HELLO) || (defined(HAVE_DECL_IPPROTO_HELLO) && HAVE_DECL_IPPROTO_HELLO)
+  XLAT(IPPROTO_HELLO),
+#endif
+#if defined(IPPROTO_ND) || (defined(HAVE_DECL_IPPROTO_ND) && HAVE_DECL_IPPROTO_ND)
+  XLAT(IPPROTO_ND),
+#endif
+#if defined(IPPROTO_MTP) || (defined(HAVE_DECL_IPPROTO_MTP) && HAVE_DECL_IPPROTO_MTP)
+  XLAT(IPPROTO_MTP),
+#endif
+#if defined(IPPROTO_ENCAP) || (defined(HAVE_DECL_IPPROTO_ENCAP) && HAVE_DECL_IPPROTO_ENCAP)
+  XLAT(IPPROTO_ENCAP),
+#endif
+#if defined(IPPROTO_PIM) || (defined(HAVE_DECL_IPPROTO_PIM) && HAVE_DECL_IPPROTO_PIM)
+  XLAT(IPPROTO_PIM),
+#endif
+#if defined(IPPROTO_COMP) || (defined(HAVE_DECL_IPPROTO_COMP) && HAVE_DECL_IPPROTO_COMP)
+  XLAT(IPPROTO_COMP),
+#endif
+#if defined(IPPROTO_SCTP) || (defined(HAVE_DECL_IPPROTO_SCTP) && HAVE_DECL_IPPROTO_SCTP)
+  XLAT(IPPROTO_SCTP),
+#endif
+#if defined(IPPROTO_UDPLITE) || (defined(HAVE_DECL_IPPROTO_UDPLITE) && HAVE_DECL_IPPROTO_UDPLITE)
+  XLAT(IPPROTO_UDPLITE),
+#endif
+#if defined(IPPROTO_MPLS) || (defined(HAVE_DECL_IPPROTO_MPLS) && HAVE_DECL_IPPROTO_MPLS)
+  XLAT(IPPROTO_MPLS),
+#endif
+#if defined(IPPROTO_RAW) || (defined(HAVE_DECL_IPPROTO_RAW) && HAVE_DECL_IPPROTO_RAW)
+  XLAT(IPPROTO_RAW),
+#endif
+#if defined(IPPROTO_MAX) || (defined(HAVE_DECL_IPPROTO_MAX) && HAVE_DECL_IPPROTO_MAX)
+  XLAT(IPPROTO_MAX),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/inet_protocols.in b/strace/xlat/inet_protocols.in
new file mode 100644
index 0000000..b7e13c9
--- /dev/null
+++ b/strace/xlat/inet_protocols.in
@@ -0,0 +1,33 @@
+IPPROTO_IP
+IPPROTO_ICMP
+IPPROTO_TCP
+IPPROTO_UDP
+IPPROTO_IGMP
+IPPROTO_GGP
+IPPROTO_IPIP
+IPPROTO_EGP
+IPPROTO_PUP
+IPPROTO_IDP
+IPPROTO_TP
+IPPROTO_DCCP
+IPPROTO_IPV6
+IPPROTO_ROUTING
+IPPROTO_FRAGMENT
+IPPROTO_RSVP
+IPPROTO_GRE
+IPPROTO_ESP
+IPPROTO_AH
+IPPROTO_ICMPV6
+IPPROTO_NONE
+IPPROTO_DSTOPTS
+IPPROTO_HELLO
+IPPROTO_ND
+IPPROTO_MTP
+IPPROTO_ENCAP
+IPPROTO_PIM
+IPPROTO_COMP
+IPPROTO_SCTP
+IPPROTO_UDPLITE
+IPPROTO_MPLS
+IPPROTO_RAW
+IPPROTO_MAX
diff --git a/strace/xlat/inotify_flags.h b/strace/xlat/inotify_flags.h
new file mode 100644
index 0000000..5638f5b
--- /dev/null
+++ b/strace/xlat/inotify_flags.h
@@ -0,0 +1,98 @@
+/* Generated by ./xlat/gen.sh from ./xlat/inotify_flags.in; do not edit. */
+#if !(defined(IN_ACCESS) || (defined(HAVE_DECL_IN_ACCESS) && HAVE_DECL_IN_ACCESS))
+# define IN_ACCESS 0x00000001
+#endif
+#if !(defined(IN_MODIFY) || (defined(HAVE_DECL_IN_MODIFY) && HAVE_DECL_IN_MODIFY))
+# define IN_MODIFY 0x00000002
+#endif
+#if !(defined(IN_ATTRIB) || (defined(HAVE_DECL_IN_ATTRIB) && HAVE_DECL_IN_ATTRIB))
+# define IN_ATTRIB 0x00000004
+#endif
+#if !(defined(IN_CLOSE_WRITE) || (defined(HAVE_DECL_IN_CLOSE_WRITE) && HAVE_DECL_IN_CLOSE_WRITE))
+# define IN_CLOSE_WRITE 0x00000008
+#endif
+#if !(defined(IN_CLOSE_NOWRITE) || (defined(HAVE_DECL_IN_CLOSE_NOWRITE) && HAVE_DECL_IN_CLOSE_NOWRITE))
+# define IN_CLOSE_NOWRITE 0x00000010
+#endif
+#if !(defined(IN_OPEN) || (defined(HAVE_DECL_IN_OPEN) && HAVE_DECL_IN_OPEN))
+# define IN_OPEN 0x00000020
+#endif
+#if !(defined(IN_MOVED_FROM) || (defined(HAVE_DECL_IN_MOVED_FROM) && HAVE_DECL_IN_MOVED_FROM))
+# define IN_MOVED_FROM 0x00000040
+#endif
+#if !(defined(IN_MOVED_TO) || (defined(HAVE_DECL_IN_MOVED_TO) && HAVE_DECL_IN_MOVED_TO))
+# define IN_MOVED_TO 0x00000080
+#endif
+#if !(defined(IN_CREATE) || (defined(HAVE_DECL_IN_CREATE) && HAVE_DECL_IN_CREATE))
+# define IN_CREATE 0x00000100
+#endif
+#if !(defined(IN_DELETE) || (defined(HAVE_DECL_IN_DELETE) && HAVE_DECL_IN_DELETE))
+# define IN_DELETE 0x00000200
+#endif
+#if !(defined(IN_DELETE_SELF) || (defined(HAVE_DECL_IN_DELETE_SELF) && HAVE_DECL_IN_DELETE_SELF))
+# define IN_DELETE_SELF 0x00000400
+#endif
+#if !(defined(IN_MOVE_SELF) || (defined(HAVE_DECL_IN_MOVE_SELF) && HAVE_DECL_IN_MOVE_SELF))
+# define IN_MOVE_SELF 0x00000800
+#endif
+#if !(defined(IN_UNMOUNT) || (defined(HAVE_DECL_IN_UNMOUNT) && HAVE_DECL_IN_UNMOUNT))
+# define IN_UNMOUNT 0x00002000
+#endif
+#if !(defined(IN_Q_OVERFLOW) || (defined(HAVE_DECL_IN_Q_OVERFLOW) && HAVE_DECL_IN_Q_OVERFLOW))
+# define IN_Q_OVERFLOW 0x00004000
+#endif
+#if !(defined(IN_IGNORED) || (defined(HAVE_DECL_IN_IGNORED) && HAVE_DECL_IN_IGNORED))
+# define IN_IGNORED 0x00008000
+#endif
+#if !(defined(IN_ONLYDIR) || (defined(HAVE_DECL_IN_ONLYDIR) && HAVE_DECL_IN_ONLYDIR))
+# define IN_ONLYDIR 0x01000000
+#endif
+#if !(defined(IN_DONT_FOLLOW) || (defined(HAVE_DECL_IN_DONT_FOLLOW) && HAVE_DECL_IN_DONT_FOLLOW))
+# define IN_DONT_FOLLOW 0x02000000
+#endif
+#if !(defined(IN_EXCL_UNLINK) || (defined(HAVE_DECL_IN_EXCL_UNLINK) && HAVE_DECL_IN_EXCL_UNLINK))
+# define IN_EXCL_UNLINK 0x04000000
+#endif
+#if !(defined(IN_MASK_ADD) || (defined(HAVE_DECL_IN_MASK_ADD) && HAVE_DECL_IN_MASK_ADD))
+# define IN_MASK_ADD 0x20000000
+#endif
+#if !(defined(IN_ISDIR) || (defined(HAVE_DECL_IN_ISDIR) && HAVE_DECL_IN_ISDIR))
+# define IN_ISDIR 0x40000000
+#endif
+#if !(defined(IN_ONESHOT) || (defined(HAVE_DECL_IN_ONESHOT) && HAVE_DECL_IN_ONESHOT))
+# define IN_ONESHOT 0x80000000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat inotify_flags in mpers mode
+
+#else
+
+static
+const struct xlat inotify_flags[] = {
+ XLAT(IN_ACCESS),
+ XLAT(IN_MODIFY),
+ XLAT(IN_ATTRIB),
+ XLAT(IN_CLOSE_WRITE),
+ XLAT(IN_CLOSE_NOWRITE),
+ XLAT(IN_OPEN),
+ XLAT(IN_MOVED_FROM),
+ XLAT(IN_MOVED_TO),
+ XLAT(IN_CREATE),
+ XLAT(IN_DELETE),
+ XLAT(IN_DELETE_SELF),
+ XLAT(IN_MOVE_SELF),
+ XLAT(IN_UNMOUNT),
+ XLAT(IN_Q_OVERFLOW),
+ XLAT(IN_IGNORED),
+ XLAT(IN_ONLYDIR),
+ XLAT(IN_DONT_FOLLOW),
+ XLAT(IN_EXCL_UNLINK),
+ XLAT(IN_MASK_ADD),
+ XLAT(IN_ISDIR),
+ XLAT(IN_ONESHOT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/inotify_flags.in b/strace/xlat/inotify_flags.in
new file mode 100644
index 0000000..db1d839
--- /dev/null
+++ b/strace/xlat/inotify_flags.in
@@ -0,0 +1,21 @@
+IN_ACCESS 0x00000001
+IN_MODIFY 0x00000002
+IN_ATTRIB 0x00000004
+IN_CLOSE_WRITE 0x00000008
+IN_CLOSE_NOWRITE 0x00000010
+IN_OPEN 0x00000020
+IN_MOVED_FROM 0x00000040
+IN_MOVED_TO 0x00000080
+IN_CREATE 0x00000100
+IN_DELETE 0x00000200
+IN_DELETE_SELF 0x00000400
+IN_MOVE_SELF 0x00000800
+IN_UNMOUNT 0x00002000
+IN_Q_OVERFLOW 0x00004000
+IN_IGNORED 0x00008000
+IN_ONLYDIR 0x01000000
+IN_DONT_FOLLOW 0x02000000
+IN_EXCL_UNLINK 0x04000000
+IN_MASK_ADD 0x20000000
+IN_ISDIR 0x40000000
+IN_ONESHOT 0x80000000
diff --git a/strace/xlat/inotify_init_flags.h b/strace/xlat/inotify_init_flags.h
new file mode 100644
index 0000000..80991f6
--- /dev/null
+++ b/strace/xlat/inotify_init_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/inotify_init_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat inotify_init_flags in mpers mode
+
+#else
+
+static
+const struct xlat inotify_init_flags[] = {
+#if defined(O_NONBLOCK) || (defined(HAVE_DECL_O_NONBLOCK) && HAVE_DECL_O_NONBLOCK)
+  XLAT(O_NONBLOCK),
+#endif
+#if defined(O_CLOEXEC) || (defined(HAVE_DECL_O_CLOEXEC) && HAVE_DECL_O_CLOEXEC)
+  XLAT(O_CLOEXEC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/inotify_init_flags.in b/strace/xlat/inotify_init_flags.in
new file mode 100644
index 0000000..fb0338b
--- /dev/null
+++ b/strace/xlat/inotify_init_flags.in
@@ -0,0 +1,2 @@
+O_NONBLOCK
+O_CLOEXEC
diff --git a/strace/xlat/ioctl_dirs.h b/strace/xlat/ioctl_dirs.h
new file mode 100644
index 0000000..14bb3e4
--- /dev/null
+++ b/strace/xlat/ioctl_dirs.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ioctl_dirs.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ioctl_dirs in mpers mode
+
+#else
+
+static
+const struct xlat ioctl_dirs[] = {
+#if defined(_IOC_READ) || (defined(HAVE_DECL__IOC_READ) && HAVE_DECL__IOC_READ)
+  XLAT(_IOC_READ),
+#endif
+#if defined(_IOC_WRITE) || (defined(HAVE_DECL__IOC_WRITE) && HAVE_DECL__IOC_WRITE)
+  XLAT(_IOC_WRITE),
+#endif
+#if defined(_IOC_NONE) || (defined(HAVE_DECL__IOC_NONE) && HAVE_DECL__IOC_NONE)
+  XLAT(_IOC_NONE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ioctl_dirs.in b/strace/xlat/ioctl_dirs.in
new file mode 100644
index 0000000..4c97a86
--- /dev/null
+++ b/strace/xlat/ioctl_dirs.in
@@ -0,0 +1,3 @@
+_IOC_READ
+_IOC_WRITE
+_IOC_NONE
diff --git a/strace/xlat/ioprio_class.h b/strace/xlat/ioprio_class.h
new file mode 100644
index 0000000..3e4f893
--- /dev/null
+++ b/strace/xlat/ioprio_class.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ioprio_class.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ioprio_class in mpers mode
+
+#else
+
+static
+const struct xlat ioprio_class[] = {
+ XLAT(IOPRIO_CLASS_NONE),
+ XLAT(IOPRIO_CLASS_RT),
+ XLAT(IOPRIO_CLASS_BE),
+ XLAT(IOPRIO_CLASS_IDLE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ioprio_class.in b/strace/xlat/ioprio_class.in
new file mode 100644
index 0000000..5020e5a
--- /dev/null
+++ b/strace/xlat/ioprio_class.in
@@ -0,0 +1,5 @@
+#unconditional
+IOPRIO_CLASS_NONE
+IOPRIO_CLASS_RT
+IOPRIO_CLASS_BE
+IOPRIO_CLASS_IDLE
diff --git a/strace/xlat/ioprio_who.h b/strace/xlat/ioprio_who.h
new file mode 100644
index 0000000..b7880ca
--- /dev/null
+++ b/strace/xlat/ioprio_who.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ioprio_who.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ioprio_who in mpers mode
+
+#else
+
+static
+const struct xlat ioprio_who[] = {
+ XLAT(IOPRIO_WHO_PROCESS),
+ XLAT(IOPRIO_WHO_PGRP),
+ XLAT(IOPRIO_WHO_USER),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ioprio_who.in b/strace/xlat/ioprio_who.in
new file mode 100644
index 0000000..20b1bd1
--- /dev/null
+++ b/strace/xlat/ioprio_who.in
@@ -0,0 +1,4 @@
+#unconditional
+IOPRIO_WHO_PROCESS
+IOPRIO_WHO_PGRP
+IOPRIO_WHO_USER
diff --git a/strace/xlat/ip_cmsg_types.h b/strace/xlat/ip_cmsg_types.h
new file mode 100644
index 0000000..979d295
--- /dev/null
+++ b/strace/xlat/ip_cmsg_types.h
@@ -0,0 +1,49 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ip_cmsg_types.in; do not edit. */
+#if !(defined(IP_TOS) || (defined(HAVE_DECL_IP_TOS) && HAVE_DECL_IP_TOS))
+# define IP_TOS 1
+#endif
+#if !(defined(IP_TTL) || (defined(HAVE_DECL_IP_TTL) && HAVE_DECL_IP_TTL))
+# define IP_TTL 2
+#endif
+#if !(defined(IP_RECVOPTS) || (defined(HAVE_DECL_IP_RECVOPTS) && HAVE_DECL_IP_RECVOPTS))
+# define IP_RECVOPTS 6
+#endif
+#if !(defined(IP_RETOPTS) || (defined(HAVE_DECL_IP_RETOPTS) && HAVE_DECL_IP_RETOPTS))
+# define IP_RETOPTS 7
+#endif
+#if !(defined(IP_PKTINFO) || (defined(HAVE_DECL_IP_PKTINFO) && HAVE_DECL_IP_PKTINFO))
+# define IP_PKTINFO 8
+#endif
+#if !(defined(IP_RECVERR) || (defined(HAVE_DECL_IP_RECVERR) && HAVE_DECL_IP_RECVERR))
+# define IP_RECVERR 11
+#endif
+#if !(defined(IP_ORIGDSTADDR) || (defined(HAVE_DECL_IP_ORIGDSTADDR) && HAVE_DECL_IP_ORIGDSTADDR))
+# define IP_ORIGDSTADDR 20
+#endif
+#if !(defined(IP_CHECKSUM) || (defined(HAVE_DECL_IP_CHECKSUM) && HAVE_DECL_IP_CHECKSUM))
+# define IP_CHECKSUM 23
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ip_cmsg_types in mpers mode
+
+#else
+
+static
+const struct xlat ip_cmsg_types[] = {
+ XLAT(IP_TOS),
+ XLAT(IP_TTL),
+ XLAT(IP_RECVOPTS),
+ XLAT(IP_RETOPTS),
+ XLAT(IP_PKTINFO),
+ XLAT(IP_RECVERR),
+ XLAT(IP_ORIGDSTADDR),
+ XLAT(IP_CHECKSUM),
+#if defined(SCM_SECURITY) || (defined(HAVE_DECL_SCM_SECURITY) && HAVE_DECL_SCM_SECURITY)
+  XLAT(SCM_SECURITY),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ip_cmsg_types.in b/strace/xlat/ip_cmsg_types.in
new file mode 100644
index 0000000..1bc81f4
--- /dev/null
+++ b/strace/xlat/ip_cmsg_types.in
@@ -0,0 +1,9 @@
+IP_TOS		1
+IP_TTL		2
+IP_RECVOPTS	6
+IP_RETOPTS	7
+IP_PKTINFO	8
+IP_RECVERR	11
+IP_ORIGDSTADDR	20
+IP_CHECKSUM	23
+SCM_SECURITY
diff --git a/strace/xlat/ipc_msg_flags.h b/strace/xlat/ipc_msg_flags.h
new file mode 100644
index 0000000..a37ca87
--- /dev/null
+++ b/strace/xlat/ipc_msg_flags.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ipc_msg_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ipc_msg_flags in mpers mode
+
+#else
+
+static
+const struct xlat ipc_msg_flags[] = {
+#if defined(MSG_NOERROR) || (defined(HAVE_DECL_MSG_NOERROR) && HAVE_DECL_MSG_NOERROR)
+  XLAT(MSG_NOERROR),
+#endif
+#if defined(MSG_EXCEPT) || (defined(HAVE_DECL_MSG_EXCEPT) && HAVE_DECL_MSG_EXCEPT)
+  XLAT(MSG_EXCEPT),
+#endif
+#if defined(IPC_NOWAIT) || (defined(HAVE_DECL_IPC_NOWAIT) && HAVE_DECL_IPC_NOWAIT)
+  XLAT(IPC_NOWAIT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ipc_msg_flags.in b/strace/xlat/ipc_msg_flags.in
new file mode 100644
index 0000000..5aef101
--- /dev/null
+++ b/strace/xlat/ipc_msg_flags.in
@@ -0,0 +1,3 @@
+MSG_NOERROR
+MSG_EXCEPT
+IPC_NOWAIT
diff --git a/strace/xlat/ipccalls.h b/strace/xlat/ipccalls.h
new file mode 100644
index 0000000..fc988e6
--- /dev/null
+++ b/strace/xlat/ipccalls.h
@@ -0,0 +1,62 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ipccalls.in; do not edit. */
+#if !(defined(SEMOP) || (defined(HAVE_DECL_SEMOP) && HAVE_DECL_SEMOP))
+# define SEMOP 1
+#endif
+#if !(defined(SEMGET) || (defined(HAVE_DECL_SEMGET) && HAVE_DECL_SEMGET))
+# define SEMGET 2
+#endif
+#if !(defined(SEMCTL) || (defined(HAVE_DECL_SEMCTL) && HAVE_DECL_SEMCTL))
+# define SEMCTL 3
+#endif
+#if !(defined(SEMTIMEDOP) || (defined(HAVE_DECL_SEMTIMEDOP) && HAVE_DECL_SEMTIMEDOP))
+# define SEMTIMEDOP 4
+#endif
+#if !(defined(MSGSND) || (defined(HAVE_DECL_MSGSND) && HAVE_DECL_MSGSND))
+# define MSGSND 11
+#endif
+#if !(defined(MSGRCV) || (defined(HAVE_DECL_MSGRCV) && HAVE_DECL_MSGRCV))
+# define MSGRCV 12
+#endif
+#if !(defined(MSGGET) || (defined(HAVE_DECL_MSGGET) && HAVE_DECL_MSGGET))
+# define MSGGET 13
+#endif
+#if !(defined(MSGCTL) || (defined(HAVE_DECL_MSGCTL) && HAVE_DECL_MSGCTL))
+# define MSGCTL 14
+#endif
+#if !(defined(SHMAT) || (defined(HAVE_DECL_SHMAT) && HAVE_DECL_SHMAT))
+# define SHMAT 21
+#endif
+#if !(defined(SHMDT) || (defined(HAVE_DECL_SHMDT) && HAVE_DECL_SHMDT))
+# define SHMDT 22
+#endif
+#if !(defined(SHMGET) || (defined(HAVE_DECL_SHMGET) && HAVE_DECL_SHMGET))
+# define SHMGET 23
+#endif
+#if !(defined(SHMCTL) || (defined(HAVE_DECL_SHMCTL) && HAVE_DECL_SHMCTL))
+# define SHMCTL 24
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ipccalls in mpers mode
+
+#else
+
+static
+const struct xlat ipccalls[] = {
+ XLAT(SEMOP),
+ XLAT(SEMGET),
+ XLAT(SEMCTL),
+ XLAT(SEMTIMEDOP),
+ XLAT(MSGSND),
+ XLAT(MSGRCV),
+ XLAT(MSGGET),
+ XLAT(MSGCTL),
+ XLAT(SHMAT),
+ XLAT(SHMDT),
+ XLAT(SHMGET),
+ XLAT(SHMCTL),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ipccalls.in b/strace/xlat/ipccalls.in
new file mode 100644
index 0000000..b338678
--- /dev/null
+++ b/strace/xlat/ipccalls.in
@@ -0,0 +1,12 @@
+SEMOP		 1
+SEMGET		 2
+SEMCTL		 3
+SEMTIMEDOP	 4
+MSGSND		11
+MSGRCV		12
+MSGGET		13
+MSGCTL		14
+SHMAT		21
+SHMDT		22
+SHMGET		23
+SHMCTL		24
diff --git a/strace/xlat/itimer_which.h b/strace/xlat/itimer_which.h
new file mode 100644
index 0000000..a9180c6
--- /dev/null
+++ b/strace/xlat/itimer_which.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/itimer_which.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat itimer_which in mpers mode
+
+#else
+
+static
+const struct xlat itimer_which[] = {
+#if defined(ITIMER_REAL) || (defined(HAVE_DECL_ITIMER_REAL) && HAVE_DECL_ITIMER_REAL)
+  XLAT(ITIMER_REAL),
+#endif
+#if defined(ITIMER_VIRTUAL) || (defined(HAVE_DECL_ITIMER_VIRTUAL) && HAVE_DECL_ITIMER_VIRTUAL)
+  XLAT(ITIMER_VIRTUAL),
+#endif
+#if defined(ITIMER_PROF) || (defined(HAVE_DECL_ITIMER_PROF) && HAVE_DECL_ITIMER_PROF)
+  XLAT(ITIMER_PROF),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/itimer_which.in b/strace/xlat/itimer_which.in
new file mode 100644
index 0000000..768b20f
--- /dev/null
+++ b/strace/xlat/itimer_which.in
@@ -0,0 +1,3 @@
+ITIMER_REAL
+ITIMER_VIRTUAL
+ITIMER_PROF
diff --git a/strace/xlat/kcmp_types.h b/strace/xlat/kcmp_types.h
new file mode 100644
index 0000000..ba067f0
--- /dev/null
+++ b/strace/xlat/kcmp_types.h
@@ -0,0 +1,42 @@
+/* Generated by ./xlat/gen.sh from ./xlat/kcmp_types.in; do not edit. */
+#if !(defined(KCMP_FILE) || (defined(HAVE_DECL_KCMP_FILE) && HAVE_DECL_KCMP_FILE))
+# define KCMP_FILE 0
+#endif
+#if !(defined(KCMP_VM) || (defined(HAVE_DECL_KCMP_VM) && HAVE_DECL_KCMP_VM))
+# define KCMP_VM 1
+#endif
+#if !(defined(KCMP_FILES) || (defined(HAVE_DECL_KCMP_FILES) && HAVE_DECL_KCMP_FILES))
+# define KCMP_FILES 2
+#endif
+#if !(defined(KCMP_FS) || (defined(HAVE_DECL_KCMP_FS) && HAVE_DECL_KCMP_FS))
+# define KCMP_FS 3
+#endif
+#if !(defined(KCMP_SIGHAND) || (defined(HAVE_DECL_KCMP_SIGHAND) && HAVE_DECL_KCMP_SIGHAND))
+# define KCMP_SIGHAND 4
+#endif
+#if !(defined(KCMP_IO) || (defined(HAVE_DECL_KCMP_IO) && HAVE_DECL_KCMP_IO))
+# define KCMP_IO 5
+#endif
+#if !(defined(KCMP_SYSVSEM) || (defined(HAVE_DECL_KCMP_SYSVSEM) && HAVE_DECL_KCMP_SYSVSEM))
+# define KCMP_SYSVSEM 6
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat kcmp_types in mpers mode
+
+#else
+
+static
+const struct xlat kcmp_types[] = {
+ XLAT(KCMP_FILE),
+ XLAT(KCMP_VM),
+ XLAT(KCMP_FILES),
+ XLAT(KCMP_FS),
+ XLAT(KCMP_SIGHAND),
+ XLAT(KCMP_IO),
+ XLAT(KCMP_SYSVSEM),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/kcmp_types.in b/strace/xlat/kcmp_types.in
new file mode 100644
index 0000000..4357776
--- /dev/null
+++ b/strace/xlat/kcmp_types.in
@@ -0,0 +1,7 @@
+KCMP_FILE	0
+KCMP_VM		1
+KCMP_FILES	2
+KCMP_FS		3
+KCMP_SIGHAND	4
+KCMP_IO		5
+KCMP_SYSVSEM	6
diff --git a/strace/xlat/kexec_arch_values.h b/strace/xlat/kexec_arch_values.h
new file mode 100644
index 0000000..1850d94
--- /dev/null
+++ b/strace/xlat/kexec_arch_values.h
@@ -0,0 +1,62 @@
+/* Generated by ./xlat/gen.sh from ./xlat/kexec_arch_values.in; do not edit. */
+#if !(defined(KEXEC_ARCH_DEFAULT) || (defined(HAVE_DECL_KEXEC_ARCH_DEFAULT) && HAVE_DECL_KEXEC_ARCH_DEFAULT))
+# define KEXEC_ARCH_DEFAULT ( 0 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_386) || (defined(HAVE_DECL_KEXEC_ARCH_386) && HAVE_DECL_KEXEC_ARCH_386))
+# define KEXEC_ARCH_386 ( 3 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_68K) || (defined(HAVE_DECL_KEXEC_ARCH_68K) && HAVE_DECL_KEXEC_ARCH_68K))
+# define KEXEC_ARCH_68K ( 4 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_X86_64) || (defined(HAVE_DECL_KEXEC_ARCH_X86_64) && HAVE_DECL_KEXEC_ARCH_X86_64))
+# define KEXEC_ARCH_X86_64 (62 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_PPC) || (defined(HAVE_DECL_KEXEC_ARCH_PPC) && HAVE_DECL_KEXEC_ARCH_PPC))
+# define KEXEC_ARCH_PPC (20 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_PPC64) || (defined(HAVE_DECL_KEXEC_ARCH_PPC64) && HAVE_DECL_KEXEC_ARCH_PPC64))
+# define KEXEC_ARCH_PPC64 (21 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_IA_64) || (defined(HAVE_DECL_KEXEC_ARCH_IA_64) && HAVE_DECL_KEXEC_ARCH_IA_64))
+# define KEXEC_ARCH_IA_64 (50 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_ARM) || (defined(HAVE_DECL_KEXEC_ARCH_ARM) && HAVE_DECL_KEXEC_ARCH_ARM))
+# define KEXEC_ARCH_ARM (40 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_S390) || (defined(HAVE_DECL_KEXEC_ARCH_S390) && HAVE_DECL_KEXEC_ARCH_S390))
+# define KEXEC_ARCH_S390 (22 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_SH) || (defined(HAVE_DECL_KEXEC_ARCH_SH) && HAVE_DECL_KEXEC_ARCH_SH))
+# define KEXEC_ARCH_SH (42 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_MIPS_LE) || (defined(HAVE_DECL_KEXEC_ARCH_MIPS_LE) && HAVE_DECL_KEXEC_ARCH_MIPS_LE))
+# define KEXEC_ARCH_MIPS_LE (10 << 16)
+#endif
+#if !(defined(KEXEC_ARCH_MIPS) || (defined(HAVE_DECL_KEXEC_ARCH_MIPS) && HAVE_DECL_KEXEC_ARCH_MIPS))
+# define KEXEC_ARCH_MIPS ( 8 << 16)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat kexec_arch_values in mpers mode
+
+#else
+
+static
+const struct xlat kexec_arch_values[] = {
+ XLAT(KEXEC_ARCH_DEFAULT),
+ XLAT(KEXEC_ARCH_386),
+ XLAT(KEXEC_ARCH_68K),
+ XLAT(KEXEC_ARCH_X86_64),
+ XLAT(KEXEC_ARCH_PPC),
+ XLAT(KEXEC_ARCH_PPC64),
+ XLAT(KEXEC_ARCH_IA_64),
+ XLAT(KEXEC_ARCH_ARM),
+ XLAT(KEXEC_ARCH_S390),
+ XLAT(KEXEC_ARCH_SH),
+ XLAT(KEXEC_ARCH_MIPS_LE),
+ XLAT(KEXEC_ARCH_MIPS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/kexec_arch_values.in b/strace/xlat/kexec_arch_values.in
new file mode 100644
index 0000000..66d25bf
--- /dev/null
+++ b/strace/xlat/kexec_arch_values.in
@@ -0,0 +1,12 @@
+KEXEC_ARCH_DEFAULT ( 0 << 16)
+KEXEC_ARCH_386     ( 3 << 16)
+KEXEC_ARCH_68K     ( 4 << 16)
+KEXEC_ARCH_X86_64  (62 << 16)
+KEXEC_ARCH_PPC     (20 << 16)
+KEXEC_ARCH_PPC64   (21 << 16)
+KEXEC_ARCH_IA_64   (50 << 16)
+KEXEC_ARCH_ARM     (40 << 16)
+KEXEC_ARCH_S390    (22 << 16)
+KEXEC_ARCH_SH      (42 << 16)
+KEXEC_ARCH_MIPS_LE (10 << 16)
+KEXEC_ARCH_MIPS    ( 8 << 16)
diff --git a/strace/xlat/kexec_file_load_flags.h b/strace/xlat/kexec_file_load_flags.h
new file mode 100644
index 0000000..340ca3f
--- /dev/null
+++ b/strace/xlat/kexec_file_load_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/kexec_file_load_flags.in; do not edit. */
+#if !(defined(KEXEC_FILE_UNLOAD) || (defined(HAVE_DECL_KEXEC_FILE_UNLOAD) && HAVE_DECL_KEXEC_FILE_UNLOAD))
+# define KEXEC_FILE_UNLOAD 1
+#endif
+#if !(defined(KEXEC_FILE_ON_CRASH) || (defined(HAVE_DECL_KEXEC_FILE_ON_CRASH) && HAVE_DECL_KEXEC_FILE_ON_CRASH))
+# define KEXEC_FILE_ON_CRASH 2
+#endif
+#if !(defined(KEXEC_FILE_NO_INITRAMFS) || (defined(HAVE_DECL_KEXEC_FILE_NO_INITRAMFS) && HAVE_DECL_KEXEC_FILE_NO_INITRAMFS))
+# define KEXEC_FILE_NO_INITRAMFS 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat kexec_file_load_flags in mpers mode
+
+#else
+
+static
+const struct xlat kexec_file_load_flags[] = {
+ XLAT(KEXEC_FILE_UNLOAD),
+ XLAT(KEXEC_FILE_ON_CRASH),
+ XLAT(KEXEC_FILE_NO_INITRAMFS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/kexec_file_load_flags.in b/strace/xlat/kexec_file_load_flags.in
new file mode 100644
index 0000000..3ca7552
--- /dev/null
+++ b/strace/xlat/kexec_file_load_flags.in
@@ -0,0 +1,3 @@
+KEXEC_FILE_UNLOAD	1
+KEXEC_FILE_ON_CRASH	2
+KEXEC_FILE_NO_INITRAMFS	4
diff --git a/strace/xlat/kexec_flags.h b/strace/xlat/kexec_flags.h
new file mode 100644
index 0000000..e43ebff
--- /dev/null
+++ b/strace/xlat/kexec_flags.h
@@ -0,0 +1,11 @@
+/* Generated by ./xlat/gen.sh from ./xlat/kexec_flags.in; do not edit. */
+
+static const struct xlat kexec_flags[] = {
+#if defined(KEXEC_ON_CRASH) || (defined(HAVE_DECL_KEXEC_ON_CRASH) && HAVE_DECL_KEXEC_ON_CRASH)
+	XLAT(KEXEC_ON_CRASH),
+#endif
+#if defined(KEXEC_PRESERVE_CONTEXT) || (defined(HAVE_DECL_KEXEC_PRESERVE_CONTEXT) && HAVE_DECL_KEXEC_PRESERVE_CONTEXT)
+	XLAT(KEXEC_PRESERVE_CONTEXT),
+#endif
+	XLAT_END
+};
diff --git a/strace/xlat/kexec_load_flags.h b/strace/xlat/kexec_load_flags.h
new file mode 100644
index 0000000..00a51c7
--- /dev/null
+++ b/strace/xlat/kexec_load_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/kexec_load_flags.in; do not edit. */
+#if !(defined(KEXEC_ON_CRASH) || (defined(HAVE_DECL_KEXEC_ON_CRASH) && HAVE_DECL_KEXEC_ON_CRASH))
+# define KEXEC_ON_CRASH 0x00000001
+#endif
+#if !(defined(KEXEC_PRESERVE_CONTEXT) || (defined(HAVE_DECL_KEXEC_PRESERVE_CONTEXT) && HAVE_DECL_KEXEC_PRESERVE_CONTEXT))
+# define KEXEC_PRESERVE_CONTEXT 0x00000002
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat kexec_load_flags in mpers mode
+
+#else
+
+static
+const struct xlat kexec_load_flags[] = {
+ XLAT(KEXEC_ON_CRASH),
+ XLAT(KEXEC_PRESERVE_CONTEXT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/kexec_load_flags.in b/strace/xlat/kexec_load_flags.in
new file mode 100644
index 0000000..4fa8b68
--- /dev/null
+++ b/strace/xlat/kexec_load_flags.in
@@ -0,0 +1,2 @@
+KEXEC_ON_CRASH		0x00000001
+KEXEC_PRESERVE_CONTEXT	0x00000002
diff --git a/strace/xlat/key_perms.h b/strace/xlat/key_perms.h
new file mode 100644
index 0000000..4488f70
--- /dev/null
+++ b/strace/xlat/key_perms.h
@@ -0,0 +1,126 @@
+/* Generated by ./xlat/gen.sh from ./xlat/key_perms.in; do not edit. */
+#if !(defined(KEY_POS_VIEW) || (defined(HAVE_DECL_KEY_POS_VIEW) && HAVE_DECL_KEY_POS_VIEW))
+# define KEY_POS_VIEW 0x01000000
+#endif
+#if !(defined(KEY_POS_READ) || (defined(HAVE_DECL_KEY_POS_READ) && HAVE_DECL_KEY_POS_READ))
+# define KEY_POS_READ 0x02000000
+#endif
+#if !(defined(KEY_POS_WRITE) || (defined(HAVE_DECL_KEY_POS_WRITE) && HAVE_DECL_KEY_POS_WRITE))
+# define KEY_POS_WRITE 0x04000000
+#endif
+#if !(defined(KEY_POS_SEARCH) || (defined(HAVE_DECL_KEY_POS_SEARCH) && HAVE_DECL_KEY_POS_SEARCH))
+# define KEY_POS_SEARCH 0x08000000
+#endif
+#if !(defined(KEY_POS_LINK) || (defined(HAVE_DECL_KEY_POS_LINK) && HAVE_DECL_KEY_POS_LINK))
+# define KEY_POS_LINK 0x10000000
+#endif
+#if !(defined(KEY_POS_SETATTR) || (defined(HAVE_DECL_KEY_POS_SETATTR) && HAVE_DECL_KEY_POS_SETATTR))
+# define KEY_POS_SETATTR 0x20000000
+#endif
+#if !(defined(KEY_POS_ALL) || (defined(HAVE_DECL_KEY_POS_ALL) && HAVE_DECL_KEY_POS_ALL))
+# define KEY_POS_ALL 0x3f000000
+#endif
+#if !(defined(KEY_USR_VIEW) || (defined(HAVE_DECL_KEY_USR_VIEW) && HAVE_DECL_KEY_USR_VIEW))
+# define KEY_USR_VIEW 0x00010000
+#endif
+#if !(defined(KEY_USR_READ) || (defined(HAVE_DECL_KEY_USR_READ) && HAVE_DECL_KEY_USR_READ))
+# define KEY_USR_READ 0x00020000
+#endif
+#if !(defined(KEY_USR_WRITE) || (defined(HAVE_DECL_KEY_USR_WRITE) && HAVE_DECL_KEY_USR_WRITE))
+# define KEY_USR_WRITE 0x00040000
+#endif
+#if !(defined(KEY_USR_SEARCH) || (defined(HAVE_DECL_KEY_USR_SEARCH) && HAVE_DECL_KEY_USR_SEARCH))
+# define KEY_USR_SEARCH 0x00080000
+#endif
+#if !(defined(KEY_USR_LINK) || (defined(HAVE_DECL_KEY_USR_LINK) && HAVE_DECL_KEY_USR_LINK))
+# define KEY_USR_LINK 0x00100000
+#endif
+#if !(defined(KEY_USR_SETATTR) || (defined(HAVE_DECL_KEY_USR_SETATTR) && HAVE_DECL_KEY_USR_SETATTR))
+# define KEY_USR_SETATTR 0x00200000
+#endif
+#if !(defined(KEY_USR_ALL) || (defined(HAVE_DECL_KEY_USR_ALL) && HAVE_DECL_KEY_USR_ALL))
+# define KEY_USR_ALL 0x003f0000
+#endif
+#if !(defined(KEY_GRP_VIEW) || (defined(HAVE_DECL_KEY_GRP_VIEW) && HAVE_DECL_KEY_GRP_VIEW))
+# define KEY_GRP_VIEW 0x00000100
+#endif
+#if !(defined(KEY_GRP_READ) || (defined(HAVE_DECL_KEY_GRP_READ) && HAVE_DECL_KEY_GRP_READ))
+# define KEY_GRP_READ 0x00000200
+#endif
+#if !(defined(KEY_GRP_WRITE) || (defined(HAVE_DECL_KEY_GRP_WRITE) && HAVE_DECL_KEY_GRP_WRITE))
+# define KEY_GRP_WRITE 0x00000400
+#endif
+#if !(defined(KEY_GRP_SEARCH) || (defined(HAVE_DECL_KEY_GRP_SEARCH) && HAVE_DECL_KEY_GRP_SEARCH))
+# define KEY_GRP_SEARCH 0x00000800
+#endif
+#if !(defined(KEY_GRP_LINK) || (defined(HAVE_DECL_KEY_GRP_LINK) && HAVE_DECL_KEY_GRP_LINK))
+# define KEY_GRP_LINK 0x00001000
+#endif
+#if !(defined(KEY_GRP_SETATTR) || (defined(HAVE_DECL_KEY_GRP_SETATTR) && HAVE_DECL_KEY_GRP_SETATTR))
+# define KEY_GRP_SETATTR 0x00002000
+#endif
+#if !(defined(KEY_GRP_ALL) || (defined(HAVE_DECL_KEY_GRP_ALL) && HAVE_DECL_KEY_GRP_ALL))
+# define KEY_GRP_ALL 0x00003f00
+#endif
+#if !(defined(KEY_OTH_VIEW) || (defined(HAVE_DECL_KEY_OTH_VIEW) && HAVE_DECL_KEY_OTH_VIEW))
+# define KEY_OTH_VIEW 0x00000001
+#endif
+#if !(defined(KEY_OTH_READ) || (defined(HAVE_DECL_KEY_OTH_READ) && HAVE_DECL_KEY_OTH_READ))
+# define KEY_OTH_READ 0x00000002
+#endif
+#if !(defined(KEY_OTH_WRITE) || (defined(HAVE_DECL_KEY_OTH_WRITE) && HAVE_DECL_KEY_OTH_WRITE))
+# define KEY_OTH_WRITE 0x00000004
+#endif
+#if !(defined(KEY_OTH_SEARCH) || (defined(HAVE_DECL_KEY_OTH_SEARCH) && HAVE_DECL_KEY_OTH_SEARCH))
+# define KEY_OTH_SEARCH 0x00000008
+#endif
+#if !(defined(KEY_OTH_LINK) || (defined(HAVE_DECL_KEY_OTH_LINK) && HAVE_DECL_KEY_OTH_LINK))
+# define KEY_OTH_LINK 0x00000010
+#endif
+#if !(defined(KEY_OTH_SETATTR) || (defined(HAVE_DECL_KEY_OTH_SETATTR) && HAVE_DECL_KEY_OTH_SETATTR))
+# define KEY_OTH_SETATTR 0x00000020
+#endif
+#if !(defined(KEY_OTH_ALL) || (defined(HAVE_DECL_KEY_OTH_ALL) && HAVE_DECL_KEY_OTH_ALL))
+# define KEY_OTH_ALL 0x0000003f
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat key_perms in mpers mode
+
+#else
+
+static
+const struct xlat key_perms[] = {
+ XLAT(KEY_POS_VIEW),
+ XLAT(KEY_POS_READ),
+ XLAT(KEY_POS_WRITE),
+ XLAT(KEY_POS_SEARCH),
+ XLAT(KEY_POS_LINK),
+ XLAT(KEY_POS_SETATTR),
+ XLAT(KEY_POS_ALL),
+ XLAT(KEY_USR_VIEW),
+ XLAT(KEY_USR_READ),
+ XLAT(KEY_USR_WRITE),
+ XLAT(KEY_USR_SEARCH),
+ XLAT(KEY_USR_LINK),
+ XLAT(KEY_USR_SETATTR),
+ XLAT(KEY_USR_ALL),
+ XLAT(KEY_GRP_VIEW),
+ XLAT(KEY_GRP_READ),
+ XLAT(KEY_GRP_WRITE),
+ XLAT(KEY_GRP_SEARCH),
+ XLAT(KEY_GRP_LINK),
+ XLAT(KEY_GRP_SETATTR),
+ XLAT(KEY_GRP_ALL),
+ XLAT(KEY_OTH_VIEW),
+ XLAT(KEY_OTH_READ),
+ XLAT(KEY_OTH_WRITE),
+ XLAT(KEY_OTH_SEARCH),
+ XLAT(KEY_OTH_LINK),
+ XLAT(KEY_OTH_SETATTR),
+ XLAT(KEY_OTH_ALL),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/key_perms.in b/strace/xlat/key_perms.in
new file mode 100644
index 0000000..c96a9ed
--- /dev/null
+++ b/strace/xlat/key_perms.in
@@ -0,0 +1,28 @@
+KEY_POS_VIEW	0x01000000
+KEY_POS_READ	0x02000000
+KEY_POS_WRITE	0x04000000
+KEY_POS_SEARCH	0x08000000
+KEY_POS_LINK	0x10000000
+KEY_POS_SETATTR	0x20000000
+KEY_POS_ALL	0x3f000000
+KEY_USR_VIEW	0x00010000
+KEY_USR_READ	0x00020000
+KEY_USR_WRITE	0x00040000
+KEY_USR_SEARCH	0x00080000
+KEY_USR_LINK	0x00100000
+KEY_USR_SETATTR	0x00200000
+KEY_USR_ALL	0x003f0000
+KEY_GRP_VIEW	0x00000100
+KEY_GRP_READ	0x00000200
+KEY_GRP_WRITE	0x00000400
+KEY_GRP_SEARCH	0x00000800
+KEY_GRP_LINK	0x00001000
+KEY_GRP_SETATTR	0x00002000
+KEY_GRP_ALL	0x00003f00
+KEY_OTH_VIEW	0x00000001
+KEY_OTH_READ	0x00000002
+KEY_OTH_WRITE	0x00000004
+KEY_OTH_SEARCH	0x00000008
+KEY_OTH_LINK	0x00000010
+KEY_OTH_SETATTR	0x00000020
+KEY_OTH_ALL	0x0000003f
diff --git a/strace/xlat/key_reqkeys.h b/strace/xlat/key_reqkeys.h
new file mode 100644
index 0000000..920fbe4
--- /dev/null
+++ b/strace/xlat/key_reqkeys.h
@@ -0,0 +1,50 @@
+/* Generated by ./xlat/gen.sh from ./xlat/key_reqkeys.in; do not edit. */
+#if !(defined(KEY_REQKEY_DEFL_NO_CHANGE) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_NO_CHANGE) && HAVE_DECL_KEY_REQKEY_DEFL_NO_CHANGE))
+# define KEY_REQKEY_DEFL_NO_CHANGE -1
+#endif
+#if !(defined(KEY_REQKEY_DEFL_DEFAULT) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_DEFAULT) && HAVE_DECL_KEY_REQKEY_DEFL_DEFAULT))
+# define KEY_REQKEY_DEFL_DEFAULT 0
+#endif
+#if !(defined(KEY_REQKEY_DEFL_THREAD_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_THREAD_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_THREAD_KEYRING))
+# define KEY_REQKEY_DEFL_THREAD_KEYRING 1
+#endif
+#if !(defined(KEY_REQKEY_DEFL_PROCESS_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_PROCESS_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_PROCESS_KEYRING))
+# define KEY_REQKEY_DEFL_PROCESS_KEYRING 2
+#endif
+#if !(defined(KEY_REQKEY_DEFL_SESSION_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_SESSION_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_SESSION_KEYRING))
+# define KEY_REQKEY_DEFL_SESSION_KEYRING 3
+#endif
+#if !(defined(KEY_REQKEY_DEFL_USER_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_USER_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_USER_KEYRING))
+# define KEY_REQKEY_DEFL_USER_KEYRING 4
+#endif
+#if !(defined(KEY_REQKEY_DEFL_USER_SESSION_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_USER_SESSION_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_USER_SESSION_KEYRING))
+# define KEY_REQKEY_DEFL_USER_SESSION_KEYRING 5
+#endif
+#if !(defined(KEY_REQKEY_DEFL_GROUP_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_GROUP_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_GROUP_KEYRING))
+# define KEY_REQKEY_DEFL_GROUP_KEYRING 6
+#endif
+#if !(defined(KEY_REQKEY_DEFL_REQUESTOR_KEYRING) || (defined(HAVE_DECL_KEY_REQKEY_DEFL_REQUESTOR_KEYRING) && HAVE_DECL_KEY_REQKEY_DEFL_REQUESTOR_KEYRING))
+# define KEY_REQKEY_DEFL_REQUESTOR_KEYRING 7
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat key_reqkeys in mpers mode
+
+#else
+
+static
+const struct xlat key_reqkeys[] = {
+ XLAT(KEY_REQKEY_DEFL_NO_CHANGE),
+ XLAT(KEY_REQKEY_DEFL_DEFAULT),
+ XLAT(KEY_REQKEY_DEFL_THREAD_KEYRING),
+ XLAT(KEY_REQKEY_DEFL_PROCESS_KEYRING),
+ XLAT(KEY_REQKEY_DEFL_SESSION_KEYRING),
+ XLAT(KEY_REQKEY_DEFL_USER_KEYRING),
+ XLAT(KEY_REQKEY_DEFL_USER_SESSION_KEYRING),
+ XLAT(KEY_REQKEY_DEFL_GROUP_KEYRING),
+ XLAT(KEY_REQKEY_DEFL_REQUESTOR_KEYRING),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/key_reqkeys.in b/strace/xlat/key_reqkeys.in
new file mode 100644
index 0000000..747e440
--- /dev/null
+++ b/strace/xlat/key_reqkeys.in
@@ -0,0 +1,9 @@
+KEY_REQKEY_DEFL_NO_CHANGE -1
+KEY_REQKEY_DEFL_DEFAULT 0
+KEY_REQKEY_DEFL_THREAD_KEYRING 1
+KEY_REQKEY_DEFL_PROCESS_KEYRING 2
+KEY_REQKEY_DEFL_SESSION_KEYRING 3
+KEY_REQKEY_DEFL_USER_KEYRING 4
+KEY_REQKEY_DEFL_USER_SESSION_KEYRING 5
+KEY_REQKEY_DEFL_GROUP_KEYRING 6
+KEY_REQKEY_DEFL_REQUESTOR_KEYRING 7
diff --git a/strace/xlat/key_spec.h b/strace/xlat/key_spec.h
new file mode 100644
index 0000000..888a8f3
--- /dev/null
+++ b/strace/xlat/key_spec.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/key_spec.in; do not edit. */
+#if !(defined(KEY_SPEC_THREAD_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_THREAD_KEYRING) && HAVE_DECL_KEY_SPEC_THREAD_KEYRING))
+# define KEY_SPEC_THREAD_KEYRING -1
+#endif
+#if !(defined(KEY_SPEC_PROCESS_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_PROCESS_KEYRING) && HAVE_DECL_KEY_SPEC_PROCESS_KEYRING))
+# define KEY_SPEC_PROCESS_KEYRING -2
+#endif
+#if !(defined(KEY_SPEC_SESSION_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_SESSION_KEYRING) && HAVE_DECL_KEY_SPEC_SESSION_KEYRING))
+# define KEY_SPEC_SESSION_KEYRING -3
+#endif
+#if !(defined(KEY_SPEC_USER_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_USER_KEYRING) && HAVE_DECL_KEY_SPEC_USER_KEYRING))
+# define KEY_SPEC_USER_KEYRING -4
+#endif
+#if !(defined(KEY_SPEC_USER_SESSION_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_USER_SESSION_KEYRING) && HAVE_DECL_KEY_SPEC_USER_SESSION_KEYRING))
+# define KEY_SPEC_USER_SESSION_KEYRING -5
+#endif
+#if !(defined(KEY_SPEC_GROUP_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_GROUP_KEYRING) && HAVE_DECL_KEY_SPEC_GROUP_KEYRING))
+# define KEY_SPEC_GROUP_KEYRING -6
+#endif
+#if !(defined(KEY_SPEC_REQKEY_AUTH_KEY) || (defined(HAVE_DECL_KEY_SPEC_REQKEY_AUTH_KEY) && HAVE_DECL_KEY_SPEC_REQKEY_AUTH_KEY))
+# define KEY_SPEC_REQKEY_AUTH_KEY -7
+#endif
+#if !(defined(KEY_SPEC_REQUESTOR_KEYRING) || (defined(HAVE_DECL_KEY_SPEC_REQUESTOR_KEYRING) && HAVE_DECL_KEY_SPEC_REQUESTOR_KEYRING))
+# define KEY_SPEC_REQUESTOR_KEYRING -8
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat key_spec in mpers mode
+
+#else
+
+static
+const struct xlat key_spec[] = {
+ XLAT(KEY_SPEC_THREAD_KEYRING),
+ XLAT(KEY_SPEC_PROCESS_KEYRING),
+ XLAT(KEY_SPEC_SESSION_KEYRING),
+ XLAT(KEY_SPEC_USER_KEYRING),
+ XLAT(KEY_SPEC_USER_SESSION_KEYRING),
+ XLAT(KEY_SPEC_GROUP_KEYRING),
+ XLAT(KEY_SPEC_REQKEY_AUTH_KEY),
+ XLAT(KEY_SPEC_REQUESTOR_KEYRING),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/key_spec.in b/strace/xlat/key_spec.in
new file mode 100644
index 0000000..3e87954
--- /dev/null
+++ b/strace/xlat/key_spec.in
@@ -0,0 +1,8 @@
+KEY_SPEC_THREAD_KEYRING -1
+KEY_SPEC_PROCESS_KEYRING -2
+KEY_SPEC_SESSION_KEYRING -3
+KEY_SPEC_USER_KEYRING -4
+KEY_SPEC_USER_SESSION_KEYRING -5
+KEY_SPEC_GROUP_KEYRING -6
+KEY_SPEC_REQKEY_AUTH_KEY -7
+KEY_SPEC_REQUESTOR_KEYRING -8
diff --git a/strace/xlat/keyctl_commands.h b/strace/xlat/keyctl_commands.h
new file mode 100644
index 0000000..14a1e09
--- /dev/null
+++ b/strace/xlat/keyctl_commands.h
@@ -0,0 +1,110 @@
+/* Generated by ./xlat/gen.sh from ./xlat/keyctl_commands.in; do not edit. */
+#if !(defined(KEYCTL_GET_KEYRING_ID) || (defined(HAVE_DECL_KEYCTL_GET_KEYRING_ID) && HAVE_DECL_KEYCTL_GET_KEYRING_ID))
+# define KEYCTL_GET_KEYRING_ID 0
+#endif
+#if !(defined(KEYCTL_JOIN_SESSION_KEYRING) || (defined(HAVE_DECL_KEYCTL_JOIN_SESSION_KEYRING) && HAVE_DECL_KEYCTL_JOIN_SESSION_KEYRING))
+# define KEYCTL_JOIN_SESSION_KEYRING 1
+#endif
+#if !(defined(KEYCTL_UPDATE) || (defined(HAVE_DECL_KEYCTL_UPDATE) && HAVE_DECL_KEYCTL_UPDATE))
+# define KEYCTL_UPDATE 2
+#endif
+#if !(defined(KEYCTL_REVOKE) || (defined(HAVE_DECL_KEYCTL_REVOKE) && HAVE_DECL_KEYCTL_REVOKE))
+# define KEYCTL_REVOKE 3
+#endif
+#if !(defined(KEYCTL_CHOWN) || (defined(HAVE_DECL_KEYCTL_CHOWN) && HAVE_DECL_KEYCTL_CHOWN))
+# define KEYCTL_CHOWN 4
+#endif
+#if !(defined(KEYCTL_SETPERM) || (defined(HAVE_DECL_KEYCTL_SETPERM) && HAVE_DECL_KEYCTL_SETPERM))
+# define KEYCTL_SETPERM 5
+#endif
+#if !(defined(KEYCTL_DESCRIBE) || (defined(HAVE_DECL_KEYCTL_DESCRIBE) && HAVE_DECL_KEYCTL_DESCRIBE))
+# define KEYCTL_DESCRIBE 6
+#endif
+#if !(defined(KEYCTL_CLEAR) || (defined(HAVE_DECL_KEYCTL_CLEAR) && HAVE_DECL_KEYCTL_CLEAR))
+# define KEYCTL_CLEAR 7
+#endif
+#if !(defined(KEYCTL_LINK) || (defined(HAVE_DECL_KEYCTL_LINK) && HAVE_DECL_KEYCTL_LINK))
+# define KEYCTL_LINK 8
+#endif
+#if !(defined(KEYCTL_UNLINK) || (defined(HAVE_DECL_KEYCTL_UNLINK) && HAVE_DECL_KEYCTL_UNLINK))
+# define KEYCTL_UNLINK 9
+#endif
+#if !(defined(KEYCTL_SEARCH) || (defined(HAVE_DECL_KEYCTL_SEARCH) && HAVE_DECL_KEYCTL_SEARCH))
+# define KEYCTL_SEARCH 10
+#endif
+#if !(defined(KEYCTL_READ) || (defined(HAVE_DECL_KEYCTL_READ) && HAVE_DECL_KEYCTL_READ))
+# define KEYCTL_READ 11
+#endif
+#if !(defined(KEYCTL_INSTANTIATE) || (defined(HAVE_DECL_KEYCTL_INSTANTIATE) && HAVE_DECL_KEYCTL_INSTANTIATE))
+# define KEYCTL_INSTANTIATE 12
+#endif
+#if !(defined(KEYCTL_NEGATE) || (defined(HAVE_DECL_KEYCTL_NEGATE) && HAVE_DECL_KEYCTL_NEGATE))
+# define KEYCTL_NEGATE 13
+#endif
+#if !(defined(KEYCTL_SET_REQKEY_KEYRING) || (defined(HAVE_DECL_KEYCTL_SET_REQKEY_KEYRING) && HAVE_DECL_KEYCTL_SET_REQKEY_KEYRING))
+# define KEYCTL_SET_REQKEY_KEYRING 14
+#endif
+#if !(defined(KEYCTL_SET_TIMEOUT) || (defined(HAVE_DECL_KEYCTL_SET_TIMEOUT) && HAVE_DECL_KEYCTL_SET_TIMEOUT))
+# define KEYCTL_SET_TIMEOUT 15
+#endif
+#if !(defined(KEYCTL_ASSUME_AUTHORITY) || (defined(HAVE_DECL_KEYCTL_ASSUME_AUTHORITY) && HAVE_DECL_KEYCTL_ASSUME_AUTHORITY))
+# define KEYCTL_ASSUME_AUTHORITY 16
+#endif
+#if !(defined(KEYCTL_GET_SECURITY) || (defined(HAVE_DECL_KEYCTL_GET_SECURITY) && HAVE_DECL_KEYCTL_GET_SECURITY))
+# define KEYCTL_GET_SECURITY 17
+#endif
+#if !(defined(KEYCTL_SESSION_TO_PARENT) || (defined(HAVE_DECL_KEYCTL_SESSION_TO_PARENT) && HAVE_DECL_KEYCTL_SESSION_TO_PARENT))
+# define KEYCTL_SESSION_TO_PARENT 18
+#endif
+#if !(defined(KEYCTL_REJECT) || (defined(HAVE_DECL_KEYCTL_REJECT) && HAVE_DECL_KEYCTL_REJECT))
+# define KEYCTL_REJECT 19
+#endif
+#if !(defined(KEYCTL_INSTANTIATE_IOV) || (defined(HAVE_DECL_KEYCTL_INSTANTIATE_IOV) && HAVE_DECL_KEYCTL_INSTANTIATE_IOV))
+# define KEYCTL_INSTANTIATE_IOV 20
+#endif
+#if !(defined(KEYCTL_INVALIDATE) || (defined(HAVE_DECL_KEYCTL_INVALIDATE) && HAVE_DECL_KEYCTL_INVALIDATE))
+# define KEYCTL_INVALIDATE 21
+#endif
+#if !(defined(KEYCTL_GET_PERSISTENT) || (defined(HAVE_DECL_KEYCTL_GET_PERSISTENT) && HAVE_DECL_KEYCTL_GET_PERSISTENT))
+# define KEYCTL_GET_PERSISTENT 22
+#endif
+#if !(defined(KEYCTL_DH_COMPUTE) || (defined(HAVE_DECL_KEYCTL_DH_COMPUTE) && HAVE_DECL_KEYCTL_DH_COMPUTE))
+# define KEYCTL_DH_COMPUTE 23
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat keyctl_commands in mpers mode
+
+#else
+
+static
+const struct xlat keyctl_commands[] = {
+ XLAT(KEYCTL_GET_KEYRING_ID),
+ XLAT(KEYCTL_JOIN_SESSION_KEYRING),
+ XLAT(KEYCTL_UPDATE),
+ XLAT(KEYCTL_REVOKE),
+ XLAT(KEYCTL_CHOWN),
+ XLAT(KEYCTL_SETPERM),
+ XLAT(KEYCTL_DESCRIBE),
+ XLAT(KEYCTL_CLEAR),
+ XLAT(KEYCTL_LINK),
+ XLAT(KEYCTL_UNLINK),
+ XLAT(KEYCTL_SEARCH),
+ XLAT(KEYCTL_READ),
+ XLAT(KEYCTL_INSTANTIATE),
+ XLAT(KEYCTL_NEGATE),
+ XLAT(KEYCTL_SET_REQKEY_KEYRING),
+ XLAT(KEYCTL_SET_TIMEOUT),
+ XLAT(KEYCTL_ASSUME_AUTHORITY),
+ XLAT(KEYCTL_GET_SECURITY),
+ XLAT(KEYCTL_SESSION_TO_PARENT),
+ XLAT(KEYCTL_REJECT),
+ XLAT(KEYCTL_INSTANTIATE_IOV),
+ XLAT(KEYCTL_INVALIDATE),
+ XLAT(KEYCTL_GET_PERSISTENT),
+ XLAT(KEYCTL_DH_COMPUTE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/keyctl_commands.in b/strace/xlat/keyctl_commands.in
new file mode 100644
index 0000000..a30d139
--- /dev/null
+++ b/strace/xlat/keyctl_commands.in
@@ -0,0 +1,24 @@
+KEYCTL_GET_KEYRING_ID 0
+KEYCTL_JOIN_SESSION_KEYRING 1
+KEYCTL_UPDATE 2
+KEYCTL_REVOKE 3
+KEYCTL_CHOWN 4
+KEYCTL_SETPERM 5
+KEYCTL_DESCRIBE 6
+KEYCTL_CLEAR 7
+KEYCTL_LINK 8
+KEYCTL_UNLINK 9
+KEYCTL_SEARCH 10
+KEYCTL_READ 11
+KEYCTL_INSTANTIATE 12
+KEYCTL_NEGATE 13
+KEYCTL_SET_REQKEY_KEYRING 14
+KEYCTL_SET_TIMEOUT 15
+KEYCTL_ASSUME_AUTHORITY 16
+KEYCTL_GET_SECURITY 17
+KEYCTL_SESSION_TO_PARENT 18
+KEYCTL_REJECT 19
+KEYCTL_INSTANTIATE_IOV 20
+KEYCTL_INVALIDATE 21
+KEYCTL_GET_PERSISTENT 22
+KEYCTL_DH_COMPUTE 23
diff --git a/strace/xlat/lockfcmds.h b/strace/xlat/lockfcmds.h
new file mode 100644
index 0000000..632c9cb
--- /dev/null
+++ b/strace/xlat/lockfcmds.h
@@ -0,0 +1,29 @@
+/* Generated by ./xlat/gen.sh from ./xlat/lockfcmds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat lockfcmds in mpers mode
+
+#else
+
+static
+const struct xlat lockfcmds[] = {
+#if defined(F_RDLCK) || (defined(HAVE_DECL_F_RDLCK) && HAVE_DECL_F_RDLCK)
+  XLAT(F_RDLCK),
+#endif
+#if defined(F_WRLCK) || (defined(HAVE_DECL_F_WRLCK) && HAVE_DECL_F_WRLCK)
+  XLAT(F_WRLCK),
+#endif
+#if defined(F_UNLCK) || (defined(HAVE_DECL_F_UNLCK) && HAVE_DECL_F_UNLCK)
+  XLAT(F_UNLCK),
+#endif
+#if defined(F_EXLCK) || (defined(HAVE_DECL_F_EXLCK) && HAVE_DECL_F_EXLCK)
+  XLAT(F_EXLCK),
+#endif
+#if defined(F_SHLCK) || (defined(HAVE_DECL_F_SHLCK) && HAVE_DECL_F_SHLCK)
+  XLAT(F_SHLCK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/lockfcmds.in b/strace/xlat/lockfcmds.in
new file mode 100644
index 0000000..2d65ba9
--- /dev/null
+++ b/strace/xlat/lockfcmds.in
@@ -0,0 +1,5 @@
+F_RDLCK
+F_WRLCK
+F_UNLCK
+F_EXLCK
+F_SHLCK
diff --git a/strace/xlat/loop_crypt_type_options.h b/strace/xlat/loop_crypt_type_options.h
new file mode 100644
index 0000000..3b309aa
--- /dev/null
+++ b/strace/xlat/loop_crypt_type_options.h
@@ -0,0 +1,44 @@
+/* Generated by ./xlat/gen.sh from ./xlat/loop_crypt_type_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat loop_crypt_type_options in mpers mode
+
+#else
+
+static
+const struct xlat loop_crypt_type_options[] = {
+#if defined(LO_CRYPT_NONE) || (defined(HAVE_DECL_LO_CRYPT_NONE) && HAVE_DECL_LO_CRYPT_NONE)
+  XLAT(LO_CRYPT_NONE),
+#endif
+#if defined(LO_CRYPT_XOR) || (defined(HAVE_DECL_LO_CRYPT_XOR) && HAVE_DECL_LO_CRYPT_XOR)
+  XLAT(LO_CRYPT_XOR),
+#endif
+#if defined(LO_CRYPT_DES) || (defined(HAVE_DECL_LO_CRYPT_DES) && HAVE_DECL_LO_CRYPT_DES)
+  XLAT(LO_CRYPT_DES),
+#endif
+#if defined(LO_CRYPT_FISH2) || (defined(HAVE_DECL_LO_CRYPT_FISH2) && HAVE_DECL_LO_CRYPT_FISH2)
+  XLAT(LO_CRYPT_FISH2),
+#endif
+#if defined(LO_CRYPT_BLOW) || (defined(HAVE_DECL_LO_CRYPT_BLOW) && HAVE_DECL_LO_CRYPT_BLOW)
+  XLAT(LO_CRYPT_BLOW),
+#endif
+#if defined(LO_CRYPT_CAST128) || (defined(HAVE_DECL_LO_CRYPT_CAST128) && HAVE_DECL_LO_CRYPT_CAST128)
+  XLAT(LO_CRYPT_CAST128),
+#endif
+#if defined(LO_CRYPT_IDEA) || (defined(HAVE_DECL_LO_CRYPT_IDEA) && HAVE_DECL_LO_CRYPT_IDEA)
+  XLAT(LO_CRYPT_IDEA),
+#endif
+#if defined(LO_CRYPT_DUMMY) || (defined(HAVE_DECL_LO_CRYPT_DUMMY) && HAVE_DECL_LO_CRYPT_DUMMY)
+  XLAT(LO_CRYPT_DUMMY),
+#endif
+#if defined(LO_CRYPT_SKIPJACK) || (defined(HAVE_DECL_LO_CRYPT_SKIPJACK) && HAVE_DECL_LO_CRYPT_SKIPJACK)
+  XLAT(LO_CRYPT_SKIPJACK),
+#endif
+#if defined(LO_CRYPT_CRYPTOAPI) || (defined(HAVE_DECL_LO_CRYPT_CRYPTOAPI) && HAVE_DECL_LO_CRYPT_CRYPTOAPI)
+  XLAT(LO_CRYPT_CRYPTOAPI),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/loop_crypt_type_options.in b/strace/xlat/loop_crypt_type_options.in
new file mode 100644
index 0000000..e9b7bdd
--- /dev/null
+++ b/strace/xlat/loop_crypt_type_options.in
@@ -0,0 +1,10 @@
+LO_CRYPT_NONE
+LO_CRYPT_XOR
+LO_CRYPT_DES
+LO_CRYPT_FISH2
+LO_CRYPT_BLOW
+LO_CRYPT_CAST128
+LO_CRYPT_IDEA
+LO_CRYPT_DUMMY
+LO_CRYPT_SKIPJACK
+LO_CRYPT_CRYPTOAPI
diff --git a/strace/xlat/loop_flags_options.h b/strace/xlat/loop_flags_options.h
new file mode 100644
index 0000000..8ee1fea
--- /dev/null
+++ b/strace/xlat/loop_flags_options.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/loop_flags_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat loop_flags_options in mpers mode
+
+#else
+
+static
+const struct xlat loop_flags_options[] = {
+#if defined(LO_FLAGS_READ_ONLY) || (defined(HAVE_DECL_LO_FLAGS_READ_ONLY) && HAVE_DECL_LO_FLAGS_READ_ONLY)
+  XLAT(LO_FLAGS_READ_ONLY),
+#endif
+#if defined(LO_FLAGS_AUTOCLEAR) || (defined(HAVE_DECL_LO_FLAGS_AUTOCLEAR) && HAVE_DECL_LO_FLAGS_AUTOCLEAR)
+  XLAT(LO_FLAGS_AUTOCLEAR),
+#endif
+#if defined(LO_FLAGS_PARTSCAN) || (defined(HAVE_DECL_LO_FLAGS_PARTSCAN) && HAVE_DECL_LO_FLAGS_PARTSCAN)
+  XLAT(LO_FLAGS_PARTSCAN),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/loop_flags_options.in b/strace/xlat/loop_flags_options.in
new file mode 100644
index 0000000..9235dbb
--- /dev/null
+++ b/strace/xlat/loop_flags_options.in
@@ -0,0 +1,3 @@
+LO_FLAGS_READ_ONLY
+LO_FLAGS_AUTOCLEAR
+LO_FLAGS_PARTSCAN
diff --git a/strace/xlat/madvise_cmds.h b/strace/xlat/madvise_cmds.h
new file mode 100644
index 0000000..41aa3a5
--- /dev/null
+++ b/strace/xlat/madvise_cmds.h
@@ -0,0 +1,65 @@
+/* Generated by ./xlat/gen.sh from ./xlat/madvise_cmds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat madvise_cmds in mpers mode
+
+#else
+
+static
+const struct xlat madvise_cmds[] = {
+#if defined(MADV_NORMAL) || (defined(HAVE_DECL_MADV_NORMAL) && HAVE_DECL_MADV_NORMAL)
+  XLAT(MADV_NORMAL),
+#endif
+#if defined(MADV_RANDOM) || (defined(HAVE_DECL_MADV_RANDOM) && HAVE_DECL_MADV_RANDOM)
+  XLAT(MADV_RANDOM),
+#endif
+#if defined(MADV_SEQUENTIAL) || (defined(HAVE_DECL_MADV_SEQUENTIAL) && HAVE_DECL_MADV_SEQUENTIAL)
+  XLAT(MADV_SEQUENTIAL),
+#endif
+#if defined(MADV_WILLNEED) || (defined(HAVE_DECL_MADV_WILLNEED) && HAVE_DECL_MADV_WILLNEED)
+  XLAT(MADV_WILLNEED),
+#endif
+#if defined(MADV_DONTNEED) || (defined(HAVE_DECL_MADV_DONTNEED) && HAVE_DECL_MADV_DONTNEED)
+  XLAT(MADV_DONTNEED),
+#endif
+#if defined(MADV_FREE) || (defined(HAVE_DECL_MADV_FREE) && HAVE_DECL_MADV_FREE)
+  XLAT(MADV_FREE),
+#endif
+#if defined(MADV_REMOVE) || (defined(HAVE_DECL_MADV_REMOVE) && HAVE_DECL_MADV_REMOVE)
+  XLAT(MADV_REMOVE),
+#endif
+#if defined(MADV_DONTFORK) || (defined(HAVE_DECL_MADV_DONTFORK) && HAVE_DECL_MADV_DONTFORK)
+  XLAT(MADV_DONTFORK),
+#endif
+#if defined(MADV_DOFORK) || (defined(HAVE_DECL_MADV_DOFORK) && HAVE_DECL_MADV_DOFORK)
+  XLAT(MADV_DOFORK),
+#endif
+#if defined(MADV_HWPOISON) || (defined(HAVE_DECL_MADV_HWPOISON) && HAVE_DECL_MADV_HWPOISON)
+  XLAT(MADV_HWPOISON),
+#endif
+#if defined(MADV_SOFT_OFFLINE) || (defined(HAVE_DECL_MADV_SOFT_OFFLINE) && HAVE_DECL_MADV_SOFT_OFFLINE)
+  XLAT(MADV_SOFT_OFFLINE),
+#endif
+#if defined(MADV_MERGEABLE) || (defined(HAVE_DECL_MADV_MERGEABLE) && HAVE_DECL_MADV_MERGEABLE)
+  XLAT(MADV_MERGEABLE),
+#endif
+#if defined(MADV_UNMERGEABLE) || (defined(HAVE_DECL_MADV_UNMERGEABLE) && HAVE_DECL_MADV_UNMERGEABLE)
+  XLAT(MADV_UNMERGEABLE),
+#endif
+#if defined(MADV_HUGEPAGE) || (defined(HAVE_DECL_MADV_HUGEPAGE) && HAVE_DECL_MADV_HUGEPAGE)
+  XLAT(MADV_HUGEPAGE),
+#endif
+#if defined(MADV_NOHUGEPAGE) || (defined(HAVE_DECL_MADV_NOHUGEPAGE) && HAVE_DECL_MADV_NOHUGEPAGE)
+  XLAT(MADV_NOHUGEPAGE),
+#endif
+#if defined(MADV_DONTDUMP) || (defined(HAVE_DECL_MADV_DONTDUMP) && HAVE_DECL_MADV_DONTDUMP)
+  XLAT(MADV_DONTDUMP),
+#endif
+#if defined(MADV_DODUMP) || (defined(HAVE_DECL_MADV_DODUMP) && HAVE_DECL_MADV_DODUMP)
+  XLAT(MADV_DODUMP),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/madvise_cmds.in b/strace/xlat/madvise_cmds.in
new file mode 100644
index 0000000..bf6b1da
--- /dev/null
+++ b/strace/xlat/madvise_cmds.in
@@ -0,0 +1,17 @@
+MADV_NORMAL
+MADV_RANDOM
+MADV_SEQUENTIAL
+MADV_WILLNEED
+MADV_DONTNEED
+MADV_FREE
+MADV_REMOVE
+MADV_DONTFORK
+MADV_DOFORK
+MADV_HWPOISON
+MADV_SOFT_OFFLINE
+MADV_MERGEABLE
+MADV_UNMERGEABLE
+MADV_HUGEPAGE
+MADV_NOHUGEPAGE
+MADV_DONTDUMP
+MADV_DODUMP
diff --git a/strace/xlat/mbindflags.h b/strace/xlat/mbindflags.h
new file mode 100644
index 0000000..eb30ba1
--- /dev/null
+++ b/strace/xlat/mbindflags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mbindflags.in; do not edit. */
+#if !(defined(MPOL_MF_STRICT) || (defined(HAVE_DECL_MPOL_MF_STRICT) && HAVE_DECL_MPOL_MF_STRICT))
+# define MPOL_MF_STRICT 1
+#endif
+#if !(defined(MPOL_MF_MOVE) || (defined(HAVE_DECL_MPOL_MF_MOVE) && HAVE_DECL_MPOL_MF_MOVE))
+# define MPOL_MF_MOVE 2
+#endif
+#if !(defined(MPOL_MF_MOVE_ALL) || (defined(HAVE_DECL_MPOL_MF_MOVE_ALL) && HAVE_DECL_MPOL_MF_MOVE_ALL))
+# define MPOL_MF_MOVE_ALL 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mbindflags in mpers mode
+
+#else
+
+static
+const struct xlat mbindflags[] = {
+ XLAT(MPOL_MF_STRICT),
+ XLAT(MPOL_MF_MOVE),
+ XLAT(MPOL_MF_MOVE_ALL),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mbindflags.in b/strace/xlat/mbindflags.in
new file mode 100644
index 0000000..04f3ae6
--- /dev/null
+++ b/strace/xlat/mbindflags.in
@@ -0,0 +1,3 @@
+MPOL_MF_STRICT		1
+MPOL_MF_MOVE		2
+MPOL_MF_MOVE_ALL	4
diff --git a/strace/xlat/mctl_funcs.h b/strace/xlat/mctl_funcs.h
new file mode 100644
index 0000000..a6075cf
--- /dev/null
+++ b/strace/xlat/mctl_funcs.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mctl_funcs.in; do not edit. */
+
+static const struct xlat mctl_funcs[] = {
+#if defined(MC_LOCK) || (defined(HAVE_DECL_MC_LOCK) && HAVE_DECL_MC_LOCK)
+	XLAT(MC_LOCK),
+#endif
+#if defined(MC_LOCKAS) || (defined(HAVE_DECL_MC_LOCKAS) && HAVE_DECL_MC_LOCKAS)
+	XLAT(MC_LOCKAS),
+#endif
+#if defined(MC_SYNC) || (defined(HAVE_DECL_MC_SYNC) && HAVE_DECL_MC_SYNC)
+	XLAT(MC_SYNC),
+#endif
+#if defined(MC_UNLOCK) || (defined(HAVE_DECL_MC_UNLOCK) && HAVE_DECL_MC_UNLOCK)
+	XLAT(MC_UNLOCK),
+#endif
+#if defined(MC_UNLOCKAS) || (defined(HAVE_DECL_MC_UNLOCKAS) && HAVE_DECL_MC_UNLOCKAS)
+	XLAT(MC_UNLOCKAS),
+#endif
+	XLAT_END
+};
diff --git a/strace/xlat/mctl_lockas.h b/strace/xlat/mctl_lockas.h
new file mode 100644
index 0000000..647ee2d
--- /dev/null
+++ b/strace/xlat/mctl_lockas.h
@@ -0,0 +1,11 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mctl_lockas.in; do not edit. */
+
+static const struct xlat mctl_lockas[] = {
+#if defined(MCL_CURRENT) || (defined(HAVE_DECL_MCL_CURRENT) && HAVE_DECL_MCL_CURRENT)
+	XLAT(MCL_CURRENT),
+#endif
+#if defined(MCL_FUTURE) || (defined(HAVE_DECL_MCL_FUTURE) && HAVE_DECL_MCL_FUTURE)
+	XLAT(MCL_FUTURE),
+#endif
+	XLAT_END
+};
diff --git a/strace/xlat/mctl_sync.h b/strace/xlat/mctl_sync.h
new file mode 100644
index 0000000..144f7f7
--- /dev/null
+++ b/strace/xlat/mctl_sync.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mctl_sync.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mctl_sync in mpers mode
+
+#else
+
+static
+const struct xlat mctl_sync[] = {
+#if defined(MS_SYNC) || (defined(HAVE_DECL_MS_SYNC) && HAVE_DECL_MS_SYNC)
+  XLAT(MS_SYNC),
+#endif
+#if defined(MS_ASYNC) || (defined(HAVE_DECL_MS_ASYNC) && HAVE_DECL_MS_ASYNC)
+  XLAT(MS_ASYNC),
+#endif
+#if defined(MS_INVALIDATE) || (defined(HAVE_DECL_MS_INVALIDATE) && HAVE_DECL_MS_INVALIDATE)
+  XLAT(MS_INVALIDATE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mctl_sync.in b/strace/xlat/mctl_sync.in
new file mode 100644
index 0000000..1db4068
--- /dev/null
+++ b/strace/xlat/mctl_sync.in
@@ -0,0 +1,3 @@
+MS_SYNC
+MS_ASYNC
+MS_INVALIDATE
diff --git a/strace/xlat/membarrier_cmds.h b/strace/xlat/membarrier_cmds.h
new file mode 100644
index 0000000..9d4d518
--- /dev/null
+++ b/strace/xlat/membarrier_cmds.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/membarrier_cmds.in; do not edit. */
+#if !(defined(MEMBARRIER_CMD_QUERY) || (defined(HAVE_DECL_MEMBARRIER_CMD_QUERY) && HAVE_DECL_MEMBARRIER_CMD_QUERY))
+# define MEMBARRIER_CMD_QUERY 0
+#endif
+#if !(defined(MEMBARRIER_CMD_SHARED) || (defined(HAVE_DECL_MEMBARRIER_CMD_SHARED) && HAVE_DECL_MEMBARRIER_CMD_SHARED))
+# define MEMBARRIER_CMD_SHARED 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat membarrier_cmds in mpers mode
+
+#else
+
+static
+const struct xlat membarrier_cmds[] = {
+ XLAT(MEMBARRIER_CMD_QUERY),
+ XLAT(MEMBARRIER_CMD_SHARED),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/membarrier_cmds.in b/strace/xlat/membarrier_cmds.in
new file mode 100644
index 0000000..e087e8e
--- /dev/null
+++ b/strace/xlat/membarrier_cmds.in
@@ -0,0 +1,2 @@
+MEMBARRIER_CMD_QUERY	0
+MEMBARRIER_CMD_SHARED	1
diff --git a/strace/xlat/memfd_create_flags.h b/strace/xlat/memfd_create_flags.h
new file mode 100644
index 0000000..9b76099
--- /dev/null
+++ b/strace/xlat/memfd_create_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/memfd_create_flags.in; do not edit. */
+#if !(defined(MFD_CLOEXEC) || (defined(HAVE_DECL_MFD_CLOEXEC) && HAVE_DECL_MFD_CLOEXEC))
+# define MFD_CLOEXEC 1
+#endif
+#if !(defined(MFD_ALLOW_SEALING) || (defined(HAVE_DECL_MFD_ALLOW_SEALING) && HAVE_DECL_MFD_ALLOW_SEALING))
+# define MFD_ALLOW_SEALING 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat memfd_create_flags in mpers mode
+
+#else
+
+static
+const struct xlat memfd_create_flags[] = {
+ XLAT(MFD_CLOEXEC),
+ XLAT(MFD_ALLOW_SEALING),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/memfd_create_flags.in b/strace/xlat/memfd_create_flags.in
new file mode 100644
index 0000000..04a1b47
--- /dev/null
+++ b/strace/xlat/memfd_create_flags.in
@@ -0,0 +1,2 @@
+MFD_CLOEXEC 1
+MFD_ALLOW_SEALING 2
diff --git a/strace/xlat/mempolicyflags.h b/strace/xlat/mempolicyflags.h
new file mode 100644
index 0000000..38db13c
--- /dev/null
+++ b/strace/xlat/mempolicyflags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mempolicyflags.in; do not edit. */
+#if !(defined(MPOL_F_NODE) || (defined(HAVE_DECL_MPOL_F_NODE) && HAVE_DECL_MPOL_F_NODE))
+# define MPOL_F_NODE 1
+#endif
+#if !(defined(MPOL_F_ADDR) || (defined(HAVE_DECL_MPOL_F_ADDR) && HAVE_DECL_MPOL_F_ADDR))
+# define MPOL_F_ADDR 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mempolicyflags in mpers mode
+
+#else
+
+static
+const struct xlat mempolicyflags[] = {
+ XLAT(MPOL_F_NODE),
+ XLAT(MPOL_F_ADDR),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mempolicyflags.in b/strace/xlat/mempolicyflags.in
new file mode 100644
index 0000000..bdcc6f3
--- /dev/null
+++ b/strace/xlat/mempolicyflags.in
@@ -0,0 +1,2 @@
+MPOL_F_NODE	1
+MPOL_F_ADDR	2
diff --git a/strace/xlat/mlock_flags.h b/strace/xlat/mlock_flags.h
new file mode 100644
index 0000000..9ec2e54
--- /dev/null
+++ b/strace/xlat/mlock_flags.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mlock_flags.in; do not edit. */
+#if !(defined(MLOCK_ONFAULT) || (defined(HAVE_DECL_MLOCK_ONFAULT) && HAVE_DECL_MLOCK_ONFAULT))
+# define MLOCK_ONFAULT 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mlock_flags in mpers mode
+
+#else
+
+static
+const struct xlat mlock_flags[] = {
+ XLAT(MLOCK_ONFAULT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mlock_flags.in b/strace/xlat/mlock_flags.in
new file mode 100644
index 0000000..b285e67
--- /dev/null
+++ b/strace/xlat/mlock_flags.in
@@ -0,0 +1 @@
+MLOCK_ONFAULT	1
diff --git a/strace/xlat/mlockall_flags.h b/strace/xlat/mlockall_flags.h
new file mode 100644
index 0000000..c3fb08f
--- /dev/null
+++ b/strace/xlat/mlockall_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mlockall_flags.in; do not edit. */
+#if !(defined(MCL_CURRENT) || (defined(HAVE_DECL_MCL_CURRENT) && HAVE_DECL_MCL_CURRENT))
+# define MCL_CURRENT 1
+#endif
+#if !(defined(MCL_FUTURE) || (defined(HAVE_DECL_MCL_FUTURE) && HAVE_DECL_MCL_FUTURE))
+# define MCL_FUTURE 2
+#endif
+#if !(defined(MCL_ONFAULT) || (defined(HAVE_DECL_MCL_ONFAULT) && HAVE_DECL_MCL_ONFAULT))
+# define MCL_ONFAULT 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mlockall_flags in mpers mode
+
+#else
+
+static
+const struct xlat mlockall_flags[] = {
+ XLAT(MCL_CURRENT),
+ XLAT(MCL_FUTURE),
+ XLAT(MCL_ONFAULT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mlockall_flags.in b/strace/xlat/mlockall_flags.in
new file mode 100644
index 0000000..a39d7ba
--- /dev/null
+++ b/strace/xlat/mlockall_flags.in
@@ -0,0 +1,3 @@
+MCL_CURRENT	1
+MCL_FUTURE	2
+MCL_ONFAULT	4
diff --git a/strace/xlat/mmap_flags.h b/strace/xlat/mmap_flags.h
new file mode 100644
index 0000000..9ccc87e
--- /dev/null
+++ b/strace/xlat/mmap_flags.h
@@ -0,0 +1,119 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mmap_flags.in; do not edit. */
+#if defined(MAP_ANON) && (!defined(MAP_ANONYMOUS) || MAP_ANON != MAP_ANONYMOUS)
+#endif
+#if defined MAP_UNINITIALIZED && MAP_UNINITIALIZED > 0
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mmap_flags in mpers mode
+
+#else
+
+static
+const struct xlat mmap_flags[] = {
+#if defined(MAP_SHARED) || (defined(HAVE_DECL_MAP_SHARED) && HAVE_DECL_MAP_SHARED)
+  XLAT(MAP_SHARED),
+#endif
+#if defined(MAP_PRIVATE) || (defined(HAVE_DECL_MAP_PRIVATE) && HAVE_DECL_MAP_PRIVATE)
+  XLAT(MAP_PRIVATE),
+#endif
+#if defined(MAP_FIXED) || (defined(HAVE_DECL_MAP_FIXED) && HAVE_DECL_MAP_FIXED)
+  XLAT(MAP_FIXED),
+#endif
+#if defined(MAP_ANONYMOUS) || (defined(HAVE_DECL_MAP_ANONYMOUS) && HAVE_DECL_MAP_ANONYMOUS)
+  XLAT(MAP_ANONYMOUS),
+#endif
+#if defined(MAP_32BIT) || (defined(HAVE_DECL_MAP_32BIT) && HAVE_DECL_MAP_32BIT)
+  XLAT(MAP_32BIT),
+#endif
+#if defined(MAP_RENAME) || (defined(HAVE_DECL_MAP_RENAME) && HAVE_DECL_MAP_RENAME)
+  XLAT(MAP_RENAME),
+#endif
+#if defined(MAP_NORESERVE) || (defined(HAVE_DECL_MAP_NORESERVE) && HAVE_DECL_MAP_NORESERVE)
+  XLAT(MAP_NORESERVE),
+#endif
+#if defined(MAP_POPULATE) || (defined(HAVE_DECL_MAP_POPULATE) && HAVE_DECL_MAP_POPULATE)
+  XLAT(MAP_POPULATE),
+#endif
+#if defined(MAP_NONBLOCK) || (defined(HAVE_DECL_MAP_NONBLOCK) && HAVE_DECL_MAP_NONBLOCK)
+  XLAT(MAP_NONBLOCK),
+#endif
+/*
+* XXX - this was introduced in SunOS 4.x to distinguish between
+* the old pre-4.x "mmap()", which:
+*
+*	only let you map devices with an "mmap" routine (e.g.,
+*	frame buffers) in;
+*
+*	required you to specify the mapping address;
+*
+*	returned 0 on success and -1 on failure;
+*
+* memory and which, and the 4.x "mmap()" which:
+*
+*	can map plain files;
+*
+*	can be asked to pick where to map the file;
+*
+*	returns the address where it mapped the file on success
+*	and -1 on failure.
+*
+* It's not actually used in source code that calls "mmap()"; the
+* "mmap()" routine adds it for you.
+*
+* It'd be nice to come up with some way of eliminating it from
+* the flags, e.g. reporting calls *without* it as "old_mmap()"
+* and calls with it as "mmap()".
+*/
+#if defined(_MAP_NEW) || (defined(HAVE_DECL__MAP_NEW) && HAVE_DECL__MAP_NEW)
+  XLAT(_MAP_NEW),
+#endif
+#if defined(MAP_GROWSDOWN) || (defined(HAVE_DECL_MAP_GROWSDOWN) && HAVE_DECL_MAP_GROWSDOWN)
+  XLAT(MAP_GROWSDOWN),
+#endif
+#if defined(MAP_DENYWRITE) || (defined(HAVE_DECL_MAP_DENYWRITE) && HAVE_DECL_MAP_DENYWRITE)
+  XLAT(MAP_DENYWRITE),
+#endif
+#if defined(MAP_EXECUTABLE) || (defined(HAVE_DECL_MAP_EXECUTABLE) && HAVE_DECL_MAP_EXECUTABLE)
+  XLAT(MAP_EXECUTABLE),
+#endif
+#if defined(MAP_INHERIT) || (defined(HAVE_DECL_MAP_INHERIT) && HAVE_DECL_MAP_INHERIT)
+  XLAT(MAP_INHERIT),
+#endif
+#if defined(MAP_FILE) || (defined(HAVE_DECL_MAP_FILE) && HAVE_DECL_MAP_FILE)
+  XLAT(MAP_FILE),
+#endif
+#if defined(MAP_LOCKED) || (defined(HAVE_DECL_MAP_LOCKED) && HAVE_DECL_MAP_LOCKED)
+  XLAT(MAP_LOCKED),
+#endif
+/* FreeBSD ones */
+#if defined(MAP_ANON) && (!defined(MAP_ANONYMOUS) || MAP_ANON != MAP_ANONYMOUS)
+#if defined(MAP_ANON) || (defined(HAVE_DECL_MAP_ANON) && HAVE_DECL_MAP_ANON)
+  XLAT(MAP_ANON),
+#endif
+#endif
+#if defined(MAP_HASSEMAPHORE) || (defined(HAVE_DECL_MAP_HASSEMAPHORE) && HAVE_DECL_MAP_HASSEMAPHORE)
+  XLAT(MAP_HASSEMAPHORE),
+#endif
+#if defined(MAP_STACK) || (defined(HAVE_DECL_MAP_STACK) && HAVE_DECL_MAP_STACK)
+  XLAT(MAP_STACK),
+#endif
+#if defined(MAP_HUGETLB) || (defined(HAVE_DECL_MAP_HUGETLB) && HAVE_DECL_MAP_HUGETLB)
+  XLAT(MAP_HUGETLB),
+#endif
+#if defined MAP_UNINITIALIZED && MAP_UNINITIALIZED > 0
+#if defined(MAP_UNINITIALIZED) || (defined(HAVE_DECL_MAP_UNINITIALIZED) && HAVE_DECL_MAP_UNINITIALIZED)
+  XLAT(MAP_UNINITIALIZED),
+#endif
+#endif
+#if defined(MAP_NOSYNC) || (defined(HAVE_DECL_MAP_NOSYNC) && HAVE_DECL_MAP_NOSYNC)
+  XLAT(MAP_NOSYNC),
+#endif
+#if defined(MAP_NOCORE) || (defined(HAVE_DECL_MAP_NOCORE) && HAVE_DECL_MAP_NOCORE)
+  XLAT(MAP_NOCORE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mmap_flags.in b/strace/xlat/mmap_flags.in
new file mode 100644
index 0000000..e9fde44
--- /dev/null
+++ b/strace/xlat/mmap_flags.in
@@ -0,0 +1,55 @@
+MAP_SHARED
+MAP_PRIVATE
+MAP_FIXED
+MAP_ANONYMOUS
+MAP_32BIT
+MAP_RENAME
+MAP_NORESERVE
+MAP_POPULATE
+MAP_NONBLOCK
+/*
+ * XXX - this was introduced in SunOS 4.x to distinguish between
+ * the old pre-4.x "mmap()", which:
+ *
+ *	only let you map devices with an "mmap" routine (e.g.,
+ *	frame buffers) in;
+ *
+ *	required you to specify the mapping address;
+ *
+ *	returned 0 on success and -1 on failure;
+ *
+ * memory and which, and the 4.x "mmap()" which:
+ *
+ *	can map plain files;
+ *
+ *	can be asked to pick where to map the file;
+ *
+ *	returns the address where it mapped the file on success
+ *	and -1 on failure.
+ *
+ * It's not actually used in source code that calls "mmap()"; the
+ * "mmap()" routine adds it for you.
+ *
+ * It'd be nice to come up with some way of eliminating it from
+ * the flags, e.g. reporting calls *without* it as "old_mmap()"
+ * and calls with it as "mmap()".
+ */
+_MAP_NEW
+MAP_GROWSDOWN
+MAP_DENYWRITE
+MAP_EXECUTABLE
+MAP_INHERIT
+MAP_FILE
+MAP_LOCKED
+/* FreeBSD ones */
+#if defined(MAP_ANON) && (!defined(MAP_ANONYMOUS) || MAP_ANON != MAP_ANONYMOUS)
+MAP_ANON
+#endif
+MAP_HASSEMAPHORE
+MAP_STACK
+MAP_HUGETLB
+#if defined MAP_UNINITIALIZED && MAP_UNINITIALIZED > 0
+MAP_UNINITIALIZED
+#endif
+MAP_NOSYNC
+MAP_NOCORE
diff --git a/strace/xlat/mmap_prot.h b/strace/xlat/mmap_prot.h
new file mode 100644
index 0000000..0ff04eb
--- /dev/null
+++ b/strace/xlat/mmap_prot.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mmap_prot.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mmap_prot in mpers mode
+
+#else
+
+static
+const struct xlat mmap_prot[] = {
+#if defined(PROT_NONE) || (defined(HAVE_DECL_PROT_NONE) && HAVE_DECL_PROT_NONE)
+  XLAT(PROT_NONE),
+#endif
+#if defined(PROT_READ) || (defined(HAVE_DECL_PROT_READ) && HAVE_DECL_PROT_READ)
+  XLAT(PROT_READ),
+#endif
+#if defined(PROT_WRITE) || (defined(HAVE_DECL_PROT_WRITE) && HAVE_DECL_PROT_WRITE)
+  XLAT(PROT_WRITE),
+#endif
+#if defined(PROT_EXEC) || (defined(HAVE_DECL_PROT_EXEC) && HAVE_DECL_PROT_EXEC)
+  XLAT(PROT_EXEC),
+#endif
+#if defined(PROT_SEM) || (defined(HAVE_DECL_PROT_SEM) && HAVE_DECL_PROT_SEM)
+  XLAT(PROT_SEM),
+#endif
+#if defined(PROT_GROWSDOWN) || (defined(HAVE_DECL_PROT_GROWSDOWN) && HAVE_DECL_PROT_GROWSDOWN)
+  XLAT(PROT_GROWSDOWN),
+#endif
+#if defined(PROT_GROWSUP) || (defined(HAVE_DECL_PROT_GROWSUP) && HAVE_DECL_PROT_GROWSUP)
+  XLAT(PROT_GROWSUP),
+#endif
+#if defined(PROT_SAO) || (defined(HAVE_DECL_PROT_SAO) && HAVE_DECL_PROT_SAO)
+  XLAT(PROT_SAO),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mmap_prot.in b/strace/xlat/mmap_prot.in
new file mode 100644
index 0000000..0589980
--- /dev/null
+++ b/strace/xlat/mmap_prot.in
@@ -0,0 +1,8 @@
+PROT_NONE
+PROT_READ
+PROT_WRITE
+PROT_EXEC
+PROT_SEM
+PROT_GROWSDOWN
+PROT_GROWSUP
+PROT_SAO
diff --git a/strace/xlat/modem_flags.h b/strace/xlat/modem_flags.h
new file mode 100644
index 0000000..f171975
--- /dev/null
+++ b/strace/xlat/modem_flags.h
@@ -0,0 +1,47 @@
+/* Generated by ./xlat/gen.sh from ./xlat/modem_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat modem_flags in mpers mode
+
+#else
+
+static
+const struct xlat modem_flags[] = {
+#if defined(TIOCM_LE) || (defined(HAVE_DECL_TIOCM_LE) && HAVE_DECL_TIOCM_LE)
+  XLAT(TIOCM_LE),
+#endif
+#if defined(TIOCM_DTR) || (defined(HAVE_DECL_TIOCM_DTR) && HAVE_DECL_TIOCM_DTR)
+  XLAT(TIOCM_DTR),
+#endif
+#if defined(TIOCM_RTS) || (defined(HAVE_DECL_TIOCM_RTS) && HAVE_DECL_TIOCM_RTS)
+  XLAT(TIOCM_RTS),
+#endif
+#if defined(TIOCM_ST) || (defined(HAVE_DECL_TIOCM_ST) && HAVE_DECL_TIOCM_ST)
+  XLAT(TIOCM_ST),
+#endif
+#if defined(TIOCM_SR) || (defined(HAVE_DECL_TIOCM_SR) && HAVE_DECL_TIOCM_SR)
+  XLAT(TIOCM_SR),
+#endif
+#if defined(TIOCM_CTS) || (defined(HAVE_DECL_TIOCM_CTS) && HAVE_DECL_TIOCM_CTS)
+  XLAT(TIOCM_CTS),
+#endif
+#if defined(TIOCM_CAR) || (defined(HAVE_DECL_TIOCM_CAR) && HAVE_DECL_TIOCM_CAR)
+  XLAT(TIOCM_CAR),
+#endif
+#if defined(TIOCM_CD) || (defined(HAVE_DECL_TIOCM_CD) && HAVE_DECL_TIOCM_CD)
+  XLAT(TIOCM_CD),
+#endif
+#if defined(TIOCM_RNG) || (defined(HAVE_DECL_TIOCM_RNG) && HAVE_DECL_TIOCM_RNG)
+  XLAT(TIOCM_RNG),
+#endif
+#if defined(TIOCM_RI) || (defined(HAVE_DECL_TIOCM_RI) && HAVE_DECL_TIOCM_RI)
+  XLAT(TIOCM_RI),
+#endif
+#if defined(TIOCM_DSR) || (defined(HAVE_DECL_TIOCM_DSR) && HAVE_DECL_TIOCM_DSR)
+  XLAT(TIOCM_DSR),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/modem_flags.in b/strace/xlat/modem_flags.in
new file mode 100644
index 0000000..ad42d5e
--- /dev/null
+++ b/strace/xlat/modem_flags.in
@@ -0,0 +1,11 @@
+TIOCM_LE
+TIOCM_DTR
+TIOCM_RTS
+TIOCM_ST
+TIOCM_SR
+TIOCM_CTS
+TIOCM_CAR
+TIOCM_CD
+TIOCM_RNG
+TIOCM_RI
+TIOCM_DSR
diff --git a/strace/xlat/modetypes.h b/strace/xlat/modetypes.h
new file mode 100644
index 0000000..70d1868
--- /dev/null
+++ b/strace/xlat/modetypes.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/modetypes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat modetypes in mpers mode
+
+#else
+
+static
+const struct xlat modetypes[] = {
+#if defined(S_IFREG) || (defined(HAVE_DECL_S_IFREG) && HAVE_DECL_S_IFREG)
+  XLAT(S_IFREG),
+#endif
+#if defined(S_IFSOCK) || (defined(HAVE_DECL_S_IFSOCK) && HAVE_DECL_S_IFSOCK)
+  XLAT(S_IFSOCK),
+#endif
+#if defined(S_IFIFO) || (defined(HAVE_DECL_S_IFIFO) && HAVE_DECL_S_IFIFO)
+  XLAT(S_IFIFO),
+#endif
+#if defined(S_IFLNK) || (defined(HAVE_DECL_S_IFLNK) && HAVE_DECL_S_IFLNK)
+  XLAT(S_IFLNK),
+#endif
+#if defined(S_IFDIR) || (defined(HAVE_DECL_S_IFDIR) && HAVE_DECL_S_IFDIR)
+  XLAT(S_IFDIR),
+#endif
+#if defined(S_IFBLK) || (defined(HAVE_DECL_S_IFBLK) && HAVE_DECL_S_IFBLK)
+  XLAT(S_IFBLK),
+#endif
+#if defined(S_IFCHR) || (defined(HAVE_DECL_S_IFCHR) && HAVE_DECL_S_IFCHR)
+  XLAT(S_IFCHR),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/modetypes.in b/strace/xlat/modetypes.in
new file mode 100644
index 0000000..602cb00
--- /dev/null
+++ b/strace/xlat/modetypes.in
@@ -0,0 +1,7 @@
+S_IFREG
+S_IFSOCK
+S_IFIFO
+S_IFLNK
+S_IFDIR
+S_IFBLK
+S_IFCHR
diff --git a/strace/xlat/modflags.h b/strace/xlat/modflags.h
new file mode 100644
index 0000000..a277eb5
--- /dev/null
+++ b/strace/xlat/modflags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/modflags.in; do not edit. */
+
+static const struct xlat modflags[] = {
+#if defined(MOD_UNINITIALIZED) || (defined(HAVE_DECL_MOD_UNINITIALIZED) && HAVE_DECL_MOD_UNINITIALIZED)
+ XLAT(MOD_UNINITIALIZED),
+#endif
+#if defined(MOD_RUNNING) || (defined(HAVE_DECL_MOD_RUNNING) && HAVE_DECL_MOD_RUNNING)
+ XLAT(MOD_RUNNING),
+#endif
+#if defined(MOD_DELETED) || (defined(HAVE_DECL_MOD_DELETED) && HAVE_DECL_MOD_DELETED)
+ XLAT(MOD_DELETED),
+#endif
+#if defined(MOD_AUTOCLEAN) || (defined(HAVE_DECL_MOD_AUTOCLEAN) && HAVE_DECL_MOD_AUTOCLEAN)
+ XLAT(MOD_AUTOCLEAN),
+#endif
+#if defined(MOD_VISITED) || (defined(HAVE_DECL_MOD_VISITED) && HAVE_DECL_MOD_VISITED)
+ XLAT(MOD_VISITED),
+#endif
+#if defined(MOD_USED_ONCE) || (defined(HAVE_DECL_MOD_USED_ONCE) && HAVE_DECL_MOD_USED_ONCE)
+ XLAT(MOD_USED_ONCE),
+#endif
+#if defined(MOD_JUST_FREED) || (defined(HAVE_DECL_MOD_JUST_FREED) && HAVE_DECL_MOD_JUST_FREED)
+ XLAT(MOD_JUST_FREED),
+#endif
+ XLAT_END
+};
diff --git a/strace/xlat/module_init_flags.h b/strace/xlat/module_init_flags.h
new file mode 100644
index 0000000..0161d2a
--- /dev/null
+++ b/strace/xlat/module_init_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/module_init_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat module_init_flags in mpers mode
+
+#else
+
+static
+const struct xlat module_init_flags[] = {
+#if defined(MODULE_INIT_IGNORE_MODVERSIONS) || (defined(HAVE_DECL_MODULE_INIT_IGNORE_MODVERSIONS) && HAVE_DECL_MODULE_INIT_IGNORE_MODVERSIONS)
+  XLAT(MODULE_INIT_IGNORE_MODVERSIONS),
+#endif
+#if defined(MODULE_INIT_IGNORE_VERMAGIC) || (defined(HAVE_DECL_MODULE_INIT_IGNORE_VERMAGIC) && HAVE_DECL_MODULE_INIT_IGNORE_VERMAGIC)
+  XLAT(MODULE_INIT_IGNORE_VERMAGIC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/module_init_flags.in b/strace/xlat/module_init_flags.in
new file mode 100644
index 0000000..e672a59
--- /dev/null
+++ b/strace/xlat/module_init_flags.in
@@ -0,0 +1,2 @@
+MODULE_INIT_IGNORE_MODVERSIONS
+MODULE_INIT_IGNORE_VERMAGIC
diff --git a/strace/xlat/mount_flags.h b/strace/xlat/mount_flags.h
new file mode 100644
index 0000000..73e250e
--- /dev/null
+++ b/strace/xlat/mount_flags.h
@@ -0,0 +1,126 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mount_flags.in; do not edit. */
+#if !(defined(MS_RDONLY) || (defined(HAVE_DECL_MS_RDONLY) && HAVE_DECL_MS_RDONLY))
+# define MS_RDONLY 1
+#endif
+#if !(defined(MS_NOSUID) || (defined(HAVE_DECL_MS_NOSUID) && HAVE_DECL_MS_NOSUID))
+# define MS_NOSUID 2
+#endif
+#if !(defined(MS_NODEV) || (defined(HAVE_DECL_MS_NODEV) && HAVE_DECL_MS_NODEV))
+# define MS_NODEV 4
+#endif
+#if !(defined(MS_NOEXEC) || (defined(HAVE_DECL_MS_NOEXEC) && HAVE_DECL_MS_NOEXEC))
+# define MS_NOEXEC 8
+#endif
+#if !(defined(MS_SYNCHRONOUS) || (defined(HAVE_DECL_MS_SYNCHRONOUS) && HAVE_DECL_MS_SYNCHRONOUS))
+# define MS_SYNCHRONOUS 16
+#endif
+#if !(defined(MS_REMOUNT) || (defined(HAVE_DECL_MS_REMOUNT) && HAVE_DECL_MS_REMOUNT))
+# define MS_REMOUNT 32
+#endif
+#if !(defined(MS_MANDLOCK) || (defined(HAVE_DECL_MS_MANDLOCK) && HAVE_DECL_MS_MANDLOCK))
+# define MS_MANDLOCK 64
+#endif
+#if !(defined(MS_DIRSYNC) || (defined(HAVE_DECL_MS_DIRSYNC) && HAVE_DECL_MS_DIRSYNC))
+# define MS_DIRSYNC 128
+#endif
+#if !(defined(MS_NOATIME) || (defined(HAVE_DECL_MS_NOATIME) && HAVE_DECL_MS_NOATIME))
+# define MS_NOATIME 1024
+#endif
+#if !(defined(MS_NODIRATIME) || (defined(HAVE_DECL_MS_NODIRATIME) && HAVE_DECL_MS_NODIRATIME))
+# define MS_NODIRATIME 2048
+#endif
+#if !(defined(MS_BIND) || (defined(HAVE_DECL_MS_BIND) && HAVE_DECL_MS_BIND))
+# define MS_BIND 4096
+#endif
+#if !(defined(MS_MOVE) || (defined(HAVE_DECL_MS_MOVE) && HAVE_DECL_MS_MOVE))
+# define MS_MOVE 8192
+#endif
+#if !(defined(MS_REC) || (defined(HAVE_DECL_MS_REC) && HAVE_DECL_MS_REC))
+# define MS_REC 16384
+#endif
+#if !(defined(MS_SILENT) || (defined(HAVE_DECL_MS_SILENT) && HAVE_DECL_MS_SILENT))
+# define MS_SILENT 32768
+#endif
+#if !(defined(MS_POSIXACL) || (defined(HAVE_DECL_MS_POSIXACL) && HAVE_DECL_MS_POSIXACL))
+# define MS_POSIXACL (1<<16)
+#endif
+#if !(defined(MS_UNBINDABLE) || (defined(HAVE_DECL_MS_UNBINDABLE) && HAVE_DECL_MS_UNBINDABLE))
+# define MS_UNBINDABLE (1<<17)
+#endif
+#if !(defined(MS_PRIVATE) || (defined(HAVE_DECL_MS_PRIVATE) && HAVE_DECL_MS_PRIVATE))
+# define MS_PRIVATE (1<<18)
+#endif
+#if !(defined(MS_SLAVE) || (defined(HAVE_DECL_MS_SLAVE) && HAVE_DECL_MS_SLAVE))
+# define MS_SLAVE (1<<19)
+#endif
+#if !(defined(MS_SHARED) || (defined(HAVE_DECL_MS_SHARED) && HAVE_DECL_MS_SHARED))
+# define MS_SHARED (1<<20)
+#endif
+#if !(defined(MS_RELATIME) || (defined(HAVE_DECL_MS_RELATIME) && HAVE_DECL_MS_RELATIME))
+# define MS_RELATIME (1<<21)
+#endif
+#if !(defined(MS_KERNMOUNT) || (defined(HAVE_DECL_MS_KERNMOUNT) && HAVE_DECL_MS_KERNMOUNT))
+# define MS_KERNMOUNT (1<<22)
+#endif
+#if !(defined(MS_I_VERSION) || (defined(HAVE_DECL_MS_I_VERSION) && HAVE_DECL_MS_I_VERSION))
+# define MS_I_VERSION (1<<23)
+#endif
+#if !(defined(MS_STRICTATIME) || (defined(HAVE_DECL_MS_STRICTATIME) && HAVE_DECL_MS_STRICTATIME))
+# define MS_STRICTATIME (1<<24)
+#endif
+#if !(defined(MS_LAZYTIME) || (defined(HAVE_DECL_MS_LAZYTIME) && HAVE_DECL_MS_LAZYTIME))
+# define MS_LAZYTIME (1<<25)
+#endif
+#if !(defined(MS_NOSEC) || (defined(HAVE_DECL_MS_NOSEC) && HAVE_DECL_MS_NOSEC))
+# define MS_NOSEC (1<<28)
+#endif
+#if !(defined(MS_BORN) || (defined(HAVE_DECL_MS_BORN) && HAVE_DECL_MS_BORN))
+# define MS_BORN (1<<29)
+#endif
+#if !(defined(MS_ACTIVE) || (defined(HAVE_DECL_MS_ACTIVE) && HAVE_DECL_MS_ACTIVE))
+# define MS_ACTIVE (1<<30)
+#endif
+#if !(defined(MS_NOUSER) || (defined(HAVE_DECL_MS_NOUSER) && HAVE_DECL_MS_NOUSER))
+# define MS_NOUSER (1<<31)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mount_flags in mpers mode
+
+#else
+
+static
+const struct xlat mount_flags[] = {
+ XLAT(MS_RDONLY),
+ XLAT(MS_NOSUID),
+ XLAT(MS_NODEV),
+ XLAT(MS_NOEXEC),
+ XLAT(MS_SYNCHRONOUS),
+ XLAT(MS_REMOUNT),
+ XLAT(MS_MANDLOCK),
+ XLAT(MS_DIRSYNC),
+ XLAT(MS_NOATIME),
+ XLAT(MS_NODIRATIME),
+ XLAT(MS_BIND),
+ XLAT(MS_MOVE),
+ XLAT(MS_REC),
+ XLAT(MS_SILENT),
+ XLAT(MS_POSIXACL),
+ XLAT(MS_UNBINDABLE),
+ XLAT(MS_PRIVATE),
+ XLAT(MS_SLAVE),
+ XLAT(MS_SHARED),
+ XLAT(MS_RELATIME),
+ XLAT(MS_KERNMOUNT),
+ XLAT(MS_I_VERSION),
+ XLAT(MS_STRICTATIME),
+ XLAT(MS_LAZYTIME),
+ XLAT(MS_NOSEC),
+ XLAT(MS_BORN),
+ XLAT(MS_ACTIVE),
+ XLAT(MS_NOUSER),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mount_flags.in b/strace/xlat/mount_flags.in
new file mode 100644
index 0000000..fbb2a71
--- /dev/null
+++ b/strace/xlat/mount_flags.in
@@ -0,0 +1,28 @@
+MS_RDONLY	1
+MS_NOSUID	2
+MS_NODEV	4
+MS_NOEXEC	8
+MS_SYNCHRONOUS	16
+MS_REMOUNT	32
+MS_MANDLOCK	64
+MS_DIRSYNC	128
+MS_NOATIME	1024
+MS_NODIRATIME	2048
+MS_BIND		4096
+MS_MOVE		8192
+MS_REC		16384
+MS_SILENT	32768
+MS_POSIXACL	(1<<16)
+MS_UNBINDABLE	(1<<17)
+MS_PRIVATE	(1<<18)
+MS_SLAVE	(1<<19)
+MS_SHARED	(1<<20)
+MS_RELATIME	(1<<21)
+MS_KERNMOUNT	(1<<22)
+MS_I_VERSION	(1<<23)
+MS_STRICTATIME	(1<<24)
+MS_LAZYTIME	(1<<25)
+MS_NOSEC	(1<<28)
+MS_BORN		(1<<29)
+MS_ACTIVE	(1<<30)
+MS_NOUSER	(1<<31)
diff --git a/strace/xlat/move_pages_flags.h b/strace/xlat/move_pages_flags.h
new file mode 100644
index 0000000..0844fda
--- /dev/null
+++ b/strace/xlat/move_pages_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/move_pages_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat move_pages_flags in mpers mode
+
+#else
+
+static
+const struct xlat move_pages_flags[] = {
+#if defined(MPOL_MF_MOVE) || (defined(HAVE_DECL_MPOL_MF_MOVE) && HAVE_DECL_MPOL_MF_MOVE)
+  XLAT(MPOL_MF_MOVE),
+#endif
+#if defined(MPOL_MF_MOVE_ALL) || (defined(HAVE_DECL_MPOL_MF_MOVE_ALL) && HAVE_DECL_MPOL_MF_MOVE_ALL)
+  XLAT(MPOL_MF_MOVE_ALL),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/move_pages_flags.in b/strace/xlat/move_pages_flags.in
new file mode 100644
index 0000000..03555b8
--- /dev/null
+++ b/strace/xlat/move_pages_flags.in
@@ -0,0 +1,2 @@
+MPOL_MF_MOVE
+MPOL_MF_MOVE_ALL
diff --git a/strace/xlat/mremap_flags.h b/strace/xlat/mremap_flags.h
new file mode 100644
index 0000000..803cdeb
--- /dev/null
+++ b/strace/xlat/mremap_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mremap_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat mremap_flags in mpers mode
+
+#else
+
+static
+const struct xlat mremap_flags[] = {
+#if defined(MREMAP_MAYMOVE) || (defined(HAVE_DECL_MREMAP_MAYMOVE) && HAVE_DECL_MREMAP_MAYMOVE)
+  XLAT(MREMAP_MAYMOVE),
+#endif
+#if defined(MREMAP_FIXED) || (defined(HAVE_DECL_MREMAP_FIXED) && HAVE_DECL_MREMAP_FIXED)
+  XLAT(MREMAP_FIXED),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mremap_flags.in b/strace/xlat/mremap_flags.in
new file mode 100644
index 0000000..be13a6f
--- /dev/null
+++ b/strace/xlat/mremap_flags.in
@@ -0,0 +1,2 @@
+MREMAP_MAYMOVE
+MREMAP_FIXED
diff --git a/strace/xlat/msg_flags.h b/strace/xlat/msg_flags.h
new file mode 100644
index 0000000..f4729ba
--- /dev/null
+++ b/strace/xlat/msg_flags.h
@@ -0,0 +1,73 @@
+/* Generated by ./xlat/gen.sh from ./xlat/msg_flags.in; do not edit. */
+#if !(defined(MSG_BATCH) || (defined(HAVE_DECL_MSG_BATCH) && HAVE_DECL_MSG_BATCH))
+# define MSG_BATCH 0x40000
+#endif
+
+#ifndef IN_MPERS
+
+const struct xlat msg_flags[] = {
+#if defined(MSG_OOB) || (defined(HAVE_DECL_MSG_OOB) && HAVE_DECL_MSG_OOB)
+  XLAT(MSG_OOB),
+#endif
+#if defined(MSG_PEEK) || (defined(HAVE_DECL_MSG_PEEK) && HAVE_DECL_MSG_PEEK)
+  XLAT(MSG_PEEK),
+#endif
+#if defined(MSG_DONTROUTE) || (defined(HAVE_DECL_MSG_DONTROUTE) && HAVE_DECL_MSG_DONTROUTE)
+  XLAT(MSG_DONTROUTE),
+#endif
+#if defined(MSG_CTRUNC) || (defined(HAVE_DECL_MSG_CTRUNC) && HAVE_DECL_MSG_CTRUNC)
+  XLAT(MSG_CTRUNC),
+#endif
+#if defined(MSG_PROBE) || (defined(HAVE_DECL_MSG_PROBE) && HAVE_DECL_MSG_PROBE)
+  XLAT(MSG_PROBE),
+#endif
+#if defined(MSG_TRUNC) || (defined(HAVE_DECL_MSG_TRUNC) && HAVE_DECL_MSG_TRUNC)
+  XLAT(MSG_TRUNC),
+#endif
+#if defined(MSG_DONTWAIT) || (defined(HAVE_DECL_MSG_DONTWAIT) && HAVE_DECL_MSG_DONTWAIT)
+  XLAT(MSG_DONTWAIT),
+#endif
+#if defined(MSG_EOR) || (defined(HAVE_DECL_MSG_EOR) && HAVE_DECL_MSG_EOR)
+  XLAT(MSG_EOR),
+#endif
+#if defined(MSG_WAITALL) || (defined(HAVE_DECL_MSG_WAITALL) && HAVE_DECL_MSG_WAITALL)
+  XLAT(MSG_WAITALL),
+#endif
+#if defined(MSG_FIN) || (defined(HAVE_DECL_MSG_FIN) && HAVE_DECL_MSG_FIN)
+  XLAT(MSG_FIN),
+#endif
+#if defined(MSG_SYN) || (defined(HAVE_DECL_MSG_SYN) && HAVE_DECL_MSG_SYN)
+  XLAT(MSG_SYN),
+#endif
+#if defined(MSG_CONFIRM) || (defined(HAVE_DECL_MSG_CONFIRM) && HAVE_DECL_MSG_CONFIRM)
+  XLAT(MSG_CONFIRM),
+#endif
+#if defined(MSG_RST) || (defined(HAVE_DECL_MSG_RST) && HAVE_DECL_MSG_RST)
+  XLAT(MSG_RST),
+#endif
+#if defined(MSG_ERRQUEUE) || (defined(HAVE_DECL_MSG_ERRQUEUE) && HAVE_DECL_MSG_ERRQUEUE)
+  XLAT(MSG_ERRQUEUE),
+#endif
+#if defined(MSG_NOSIGNAL) || (defined(HAVE_DECL_MSG_NOSIGNAL) && HAVE_DECL_MSG_NOSIGNAL)
+  XLAT(MSG_NOSIGNAL),
+#endif
+#if defined(MSG_MORE) || (defined(HAVE_DECL_MSG_MORE) && HAVE_DECL_MSG_MORE)
+  XLAT(MSG_MORE),
+#endif
+#if defined(MSG_WAITFORONE) || (defined(HAVE_DECL_MSG_WAITFORONE) && HAVE_DECL_MSG_WAITFORONE)
+  XLAT(MSG_WAITFORONE),
+#endif
+ XLAT(MSG_BATCH),
+#if defined(MSG_EOF) || (defined(HAVE_DECL_MSG_EOF) && HAVE_DECL_MSG_EOF)
+  XLAT(MSG_EOF),
+#endif
+#if defined(MSG_FASTOPEN) || (defined(HAVE_DECL_MSG_FASTOPEN) && HAVE_DECL_MSG_FASTOPEN)
+  XLAT(MSG_FASTOPEN),
+#endif
+#if defined(MSG_CMSG_CLOEXEC) || (defined(HAVE_DECL_MSG_CMSG_CLOEXEC) && HAVE_DECL_MSG_CMSG_CLOEXEC)
+  XLAT(MSG_CMSG_CLOEXEC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/msg_flags.in b/strace/xlat/msg_flags.in
new file mode 100644
index 0000000..cf6b83c
--- /dev/null
+++ b/strace/xlat/msg_flags.in
@@ -0,0 +1,21 @@
+MSG_OOB
+MSG_PEEK
+MSG_DONTROUTE
+MSG_CTRUNC
+MSG_PROBE
+MSG_TRUNC
+MSG_DONTWAIT
+MSG_EOR
+MSG_WAITALL
+MSG_FIN
+MSG_SYN
+MSG_CONFIRM
+MSG_RST
+MSG_ERRQUEUE
+MSG_NOSIGNAL
+MSG_MORE
+MSG_WAITFORONE
+MSG_BATCH	0x40000
+MSG_EOF
+MSG_FASTOPEN
+MSG_CMSG_CLOEXEC
diff --git a/strace/xlat/msgctl_flags.h b/strace/xlat/msgctl_flags.h
new file mode 100644
index 0000000..a78ee14
--- /dev/null
+++ b/strace/xlat/msgctl_flags.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/msgctl_flags.in; do not edit. */
+#if !(defined(MSG_STAT) || (defined(HAVE_DECL_MSG_STAT) && HAVE_DECL_MSG_STAT))
+# define MSG_STAT 11
+#endif
+#if !(defined(MSG_INFO) || (defined(HAVE_DECL_MSG_INFO) && HAVE_DECL_MSG_INFO))
+# define MSG_INFO 12
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat msgctl_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat msgctl_flags[] = {
+#if defined(IPC_RMID) || (defined(HAVE_DECL_IPC_RMID) && HAVE_DECL_IPC_RMID)
+  XLAT(IPC_RMID),
+#endif
+#if defined(IPC_SET) || (defined(HAVE_DECL_IPC_SET) && HAVE_DECL_IPC_SET)
+  XLAT(IPC_SET),
+#endif
+#if defined(IPC_STAT) || (defined(HAVE_DECL_IPC_STAT) && HAVE_DECL_IPC_STAT)
+  XLAT(IPC_STAT),
+#endif
+#if defined(IPC_INFO) || (defined(HAVE_DECL_IPC_INFO) && HAVE_DECL_IPC_INFO)
+  XLAT(IPC_INFO),
+#endif
+ XLAT(MSG_STAT),
+ XLAT(MSG_INFO),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/msgctl_flags.in b/strace/xlat/msgctl_flags.in
new file mode 100644
index 0000000..4b54adf
--- /dev/null
+++ b/strace/xlat/msgctl_flags.in
@@ -0,0 +1,6 @@
+IPC_RMID
+IPC_SET
+IPC_STAT
+IPC_INFO
+MSG_STAT 11
+MSG_INFO 12
diff --git a/strace/xlat/msgflags.h b/strace/xlat/msgflags.h
new file mode 100644
index 0000000..a42115a
--- /dev/null
+++ b/strace/xlat/msgflags.h
@@ -0,0 +1,8 @@
+/* Generated by ./xlat/gen.sh from ./xlat/msgflags.in; do not edit. */
+
+static const struct xlat msgflags[] = {
+#if defined(RS_HIPRI) || (defined(HAVE_DECL_RS_HIPRI) && HAVE_DECL_RS_HIPRI)
+ XLAT(RS_HIPRI),
+#endif
+ XLAT_END
+};
diff --git a/strace/xlat/mtd_file_mode_options.h b/strace/xlat/mtd_file_mode_options.h
new file mode 100644
index 0000000..943919f
--- /dev/null
+++ b/strace/xlat/mtd_file_mode_options.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mtd_file_mode_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat mtd_file_mode_options[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat mtd_file_mode_options[] = {
+ XLAT(MTD_FILE_MODE_NORMAL),
+ XLAT(MTD_FILE_MODE_OTP_FACTORY),
+ XLAT(MTD_FILE_MODE_OTP_USER),
+ XLAT(MTD_FILE_MODE_RAW),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mtd_file_mode_options.in b/strace/xlat/mtd_file_mode_options.in
new file mode 100644
index 0000000..d9e21ad
--- /dev/null
+++ b/strace/xlat/mtd_file_mode_options.in
@@ -0,0 +1,5 @@
+#unconditional
+MTD_FILE_MODE_NORMAL
+MTD_FILE_MODE_OTP_FACTORY
+MTD_FILE_MODE_OTP_USER
+MTD_FILE_MODE_RAW
diff --git a/strace/xlat/mtd_flags_options.h b/strace/xlat/mtd_flags_options.h
new file mode 100644
index 0000000..8712561
--- /dev/null
+++ b/strace/xlat/mtd_flags_options.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mtd_flags_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat mtd_flags_options[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat mtd_flags_options[] = {
+#if defined(MTD_WRITEABLE) || (defined(HAVE_DECL_MTD_WRITEABLE) && HAVE_DECL_MTD_WRITEABLE)
+  XLAT(MTD_WRITEABLE),
+#endif
+#if defined(MTD_BIT_WRITEABLE) || (defined(HAVE_DECL_MTD_BIT_WRITEABLE) && HAVE_DECL_MTD_BIT_WRITEABLE)
+  XLAT(MTD_BIT_WRITEABLE),
+#endif
+#if defined(MTD_NO_ERASE) || (defined(HAVE_DECL_MTD_NO_ERASE) && HAVE_DECL_MTD_NO_ERASE)
+  XLAT(MTD_NO_ERASE),
+#endif
+#if defined(MTD_POWERUP_LOCK) || (defined(HAVE_DECL_MTD_POWERUP_LOCK) && HAVE_DECL_MTD_POWERUP_LOCK)
+  XLAT(MTD_POWERUP_LOCK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mtd_flags_options.in b/strace/xlat/mtd_flags_options.in
new file mode 100644
index 0000000..8b5a0a5
--- /dev/null
+++ b/strace/xlat/mtd_flags_options.in
@@ -0,0 +1,4 @@
+MTD_WRITEABLE
+MTD_BIT_WRITEABLE
+MTD_NO_ERASE
+MTD_POWERUP_LOCK
diff --git a/strace/xlat/mtd_mode_options.h b/strace/xlat/mtd_mode_options.h
new file mode 100644
index 0000000..b7e8b4a
--- /dev/null
+++ b/strace/xlat/mtd_mode_options.h
@@ -0,0 +1,19 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mtd_mode_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat mtd_mode_options[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat mtd_mode_options[] = {
+ XLAT(MTD_OPS_PLACE_OOB),
+ XLAT(MTD_OPS_AUTO_OOB),
+ XLAT(MTD_OPS_RAW),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mtd_mode_options.in b/strace/xlat/mtd_mode_options.in
new file mode 100644
index 0000000..f0dcc8b
--- /dev/null
+++ b/strace/xlat/mtd_mode_options.in
@@ -0,0 +1,4 @@
+#unconditional
+MTD_OPS_PLACE_OOB
+MTD_OPS_AUTO_OOB
+MTD_OPS_RAW
diff --git a/strace/xlat/mtd_nandecc_options.h b/strace/xlat/mtd_nandecc_options.h
new file mode 100644
index 0000000..21b0166
--- /dev/null
+++ b/strace/xlat/mtd_nandecc_options.h
@@ -0,0 +1,31 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mtd_nandecc_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat mtd_nandecc_options[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat mtd_nandecc_options[] = {
+#if defined(MTD_NANDECC_OFF) || (defined(HAVE_DECL_MTD_NANDECC_OFF) && HAVE_DECL_MTD_NANDECC_OFF)
+  XLAT(MTD_NANDECC_OFF),
+#endif
+#if defined(MTD_NANDECC_PLACE) || (defined(HAVE_DECL_MTD_NANDECC_PLACE) && HAVE_DECL_MTD_NANDECC_PLACE)
+  XLAT(MTD_NANDECC_PLACE),
+#endif
+#if defined(MTD_NANDECC_AUTOPLACE) || (defined(HAVE_DECL_MTD_NANDECC_AUTOPLACE) && HAVE_DECL_MTD_NANDECC_AUTOPLACE)
+  XLAT(MTD_NANDECC_AUTOPLACE),
+#endif
+#if defined(MTD_NANDECC_PLACEONLY) || (defined(HAVE_DECL_MTD_NANDECC_PLACEONLY) && HAVE_DECL_MTD_NANDECC_PLACEONLY)
+  XLAT(MTD_NANDECC_PLACEONLY),
+#endif
+#if defined(MTD_NANDECC_AUTOPL_USR) || (defined(HAVE_DECL_MTD_NANDECC_AUTOPL_USR) && HAVE_DECL_MTD_NANDECC_AUTOPL_USR)
+  XLAT(MTD_NANDECC_AUTOPL_USR),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mtd_nandecc_options.in b/strace/xlat/mtd_nandecc_options.in
new file mode 100644
index 0000000..cd96f3d
--- /dev/null
+++ b/strace/xlat/mtd_nandecc_options.in
@@ -0,0 +1,5 @@
+MTD_NANDECC_OFF
+MTD_NANDECC_PLACE
+MTD_NANDECC_AUTOPLACE
+MTD_NANDECC_PLACEONLY
+MTD_NANDECC_AUTOPL_USR
diff --git a/strace/xlat/mtd_otp_options.h b/strace/xlat/mtd_otp_options.h
new file mode 100644
index 0000000..2ee7f49
--- /dev/null
+++ b/strace/xlat/mtd_otp_options.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mtd_otp_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat mtd_otp_options[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat mtd_otp_options[] = {
+#if defined(MTD_OTP_OFF) || (defined(HAVE_DECL_MTD_OTP_OFF) && HAVE_DECL_MTD_OTP_OFF)
+  XLAT(MTD_OTP_OFF),
+#endif
+#if defined(MTD_OTP_FACTORY) || (defined(HAVE_DECL_MTD_OTP_FACTORY) && HAVE_DECL_MTD_OTP_FACTORY)
+  XLAT(MTD_OTP_FACTORY),
+#endif
+#if defined(MTD_OTP_USER) || (defined(HAVE_DECL_MTD_OTP_USER) && HAVE_DECL_MTD_OTP_USER)
+  XLAT(MTD_OTP_USER),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mtd_otp_options.in b/strace/xlat/mtd_otp_options.in
new file mode 100644
index 0000000..a00248f
--- /dev/null
+++ b/strace/xlat/mtd_otp_options.in
@@ -0,0 +1,3 @@
+MTD_OTP_OFF
+MTD_OTP_FACTORY
+MTD_OTP_USER
diff --git a/strace/xlat/mtd_type_options.h b/strace/xlat/mtd_type_options.h
new file mode 100644
index 0000000..46829e8
--- /dev/null
+++ b/strace/xlat/mtd_type_options.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/mtd_type_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat mtd_type_options[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat mtd_type_options[] = {
+#if defined(MTD_ABSENT) || (defined(HAVE_DECL_MTD_ABSENT) && HAVE_DECL_MTD_ABSENT)
+  XLAT(MTD_ABSENT),
+#endif
+#if defined(MTD_RAM) || (defined(HAVE_DECL_MTD_RAM) && HAVE_DECL_MTD_RAM)
+  XLAT(MTD_RAM),
+#endif
+#if defined(MTD_ROM) || (defined(HAVE_DECL_MTD_ROM) && HAVE_DECL_MTD_ROM)
+  XLAT(MTD_ROM),
+#endif
+#if defined(MTD_NORFLASH) || (defined(HAVE_DECL_MTD_NORFLASH) && HAVE_DECL_MTD_NORFLASH)
+  XLAT(MTD_NORFLASH),
+#endif
+#if defined(MTD_NANDFLASH) || (defined(HAVE_DECL_MTD_NANDFLASH) && HAVE_DECL_MTD_NANDFLASH)
+  XLAT(MTD_NANDFLASH),
+#endif
+#if defined(MTD_DATAFLASH) || (defined(HAVE_DECL_MTD_DATAFLASH) && HAVE_DECL_MTD_DATAFLASH)
+  XLAT(MTD_DATAFLASH),
+#endif
+#if defined(MTD_UBIVOLUME) || (defined(HAVE_DECL_MTD_UBIVOLUME) && HAVE_DECL_MTD_UBIVOLUME)
+  XLAT(MTD_UBIVOLUME),
+#endif
+#if defined(MTD_MLCNANDFLASH) || (defined(HAVE_DECL_MTD_MLCNANDFLASH) && HAVE_DECL_MTD_MLCNANDFLASH)
+  XLAT(MTD_MLCNANDFLASH),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/mtd_type_options.in b/strace/xlat/mtd_type_options.in
new file mode 100644
index 0000000..42643f9
--- /dev/null
+++ b/strace/xlat/mtd_type_options.in
@@ -0,0 +1,8 @@
+MTD_ABSENT
+MTD_RAM
+MTD_ROM
+MTD_NORFLASH
+MTD_NANDFLASH
+MTD_DATAFLASH
+MTD_UBIVOLUME
+MTD_MLCNANDFLASH
diff --git a/strace/xlat/netlink_flags.h b/strace/xlat/netlink_flags.h
new file mode 100644
index 0000000..ca1f3a3
--- /dev/null
+++ b/strace/xlat/netlink_flags.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/netlink_flags.in; do not edit. */
+#if !(defined(NLM_F_REQUEST) || (defined(HAVE_DECL_NLM_F_REQUEST) && HAVE_DECL_NLM_F_REQUEST))
+# define NLM_F_REQUEST 0x1
+#endif
+#if !(defined(NLM_F_MULTI) || (defined(HAVE_DECL_NLM_F_MULTI) && HAVE_DECL_NLM_F_MULTI))
+# define NLM_F_MULTI 0x2
+#endif
+#if !(defined(NLM_F_ACK) || (defined(HAVE_DECL_NLM_F_ACK) && HAVE_DECL_NLM_F_ACK))
+# define NLM_F_ACK 0x4
+#endif
+#if !(defined(NLM_F_ECHO) || (defined(HAVE_DECL_NLM_F_ECHO) && HAVE_DECL_NLM_F_ECHO))
+# define NLM_F_ECHO 0x8
+#endif
+#if !(defined(NLM_F_DUMP_INTR) || (defined(HAVE_DECL_NLM_F_DUMP_INTR) && HAVE_DECL_NLM_F_DUMP_INTR))
+# define NLM_F_DUMP_INTR 0x10
+#endif
+#if !(defined(NLM_F_DUMP_FILTERED) || (defined(HAVE_DECL_NLM_F_DUMP_FILTERED) && HAVE_DECL_NLM_F_DUMP_FILTERED))
+# define NLM_F_DUMP_FILTERED 0x20
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat netlink_flags in mpers mode
+
+#else
+
+static
+const struct xlat netlink_flags[] = {
+ XLAT(NLM_F_REQUEST),
+ XLAT(NLM_F_MULTI),
+ XLAT(NLM_F_ACK),
+ XLAT(NLM_F_ECHO),
+ XLAT(NLM_F_DUMP_INTR),
+ XLAT(NLM_F_DUMP_FILTERED),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/netlink_flags.in b/strace/xlat/netlink_flags.in
new file mode 100644
index 0000000..d84f4dd
--- /dev/null
+++ b/strace/xlat/netlink_flags.in
@@ -0,0 +1,6 @@
+NLM_F_REQUEST          0x1
+NLM_F_MULTI            0x2
+NLM_F_ACK              0x4
+NLM_F_ECHO             0x8
+NLM_F_DUMP_INTR                0x10
+NLM_F_DUMP_FILTERED    0x20
diff --git a/strace/xlat/netlink_protocols.h b/strace/xlat/netlink_protocols.h
new file mode 100644
index 0000000..ca2cc12
--- /dev/null
+++ b/strace/xlat/netlink_protocols.h
@@ -0,0 +1,77 @@
+/* Generated by ./xlat/gen.sh from ./xlat/netlink_protocols.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat netlink_protocols in mpers mode
+
+#else
+
+static
+const struct xlat netlink_protocols[] = {
+#if defined(NETLINK_ROUTE) || (defined(HAVE_DECL_NETLINK_ROUTE) && HAVE_DECL_NETLINK_ROUTE)
+  XLAT(NETLINK_ROUTE),
+#endif
+#if defined(NETLINK_UNUSED) || (defined(HAVE_DECL_NETLINK_UNUSED) && HAVE_DECL_NETLINK_UNUSED)
+  XLAT(NETLINK_UNUSED),
+#endif
+#if defined(NETLINK_USERSOCK) || (defined(HAVE_DECL_NETLINK_USERSOCK) && HAVE_DECL_NETLINK_USERSOCK)
+  XLAT(NETLINK_USERSOCK),
+#endif
+#if defined(NETLINK_FIREWALL) || (defined(HAVE_DECL_NETLINK_FIREWALL) && HAVE_DECL_NETLINK_FIREWALL)
+  XLAT(NETLINK_FIREWALL),
+#endif
+#if defined(NETLINK_SOCK_DIAG) || (defined(HAVE_DECL_NETLINK_SOCK_DIAG) && HAVE_DECL_NETLINK_SOCK_DIAG)
+  XLAT(NETLINK_SOCK_DIAG),
+#endif
+#if defined(NETLINK_NFLOG) || (defined(HAVE_DECL_NETLINK_NFLOG) && HAVE_DECL_NETLINK_NFLOG)
+  XLAT(NETLINK_NFLOG),
+#endif
+#if defined(NETLINK_XFRM) || (defined(HAVE_DECL_NETLINK_XFRM) && HAVE_DECL_NETLINK_XFRM)
+  XLAT(NETLINK_XFRM),
+#endif
+#if defined(NETLINK_SELINUX) || (defined(HAVE_DECL_NETLINK_SELINUX) && HAVE_DECL_NETLINK_SELINUX)
+  XLAT(NETLINK_SELINUX),
+#endif
+#if defined(NETLINK_ISCSI) || (defined(HAVE_DECL_NETLINK_ISCSI) && HAVE_DECL_NETLINK_ISCSI)
+  XLAT(NETLINK_ISCSI),
+#endif
+#if defined(NETLINK_AUDIT) || (defined(HAVE_DECL_NETLINK_AUDIT) && HAVE_DECL_NETLINK_AUDIT)
+  XLAT(NETLINK_AUDIT),
+#endif
+#if defined(NETLINK_FIB_LOOKUP) || (defined(HAVE_DECL_NETLINK_FIB_LOOKUP) && HAVE_DECL_NETLINK_FIB_LOOKUP)
+  XLAT(NETLINK_FIB_LOOKUP),
+#endif
+#if defined(NETLINK_CONNECTOR) || (defined(HAVE_DECL_NETLINK_CONNECTOR) && HAVE_DECL_NETLINK_CONNECTOR)
+  XLAT(NETLINK_CONNECTOR),
+#endif
+#if defined(NETLINK_NETFILTER) || (defined(HAVE_DECL_NETLINK_NETFILTER) && HAVE_DECL_NETLINK_NETFILTER)
+  XLAT(NETLINK_NETFILTER),
+#endif
+#if defined(NETLINK_IP6_FW) || (defined(HAVE_DECL_NETLINK_IP6_FW) && HAVE_DECL_NETLINK_IP6_FW)
+  XLAT(NETLINK_IP6_FW),
+#endif
+#if defined(NETLINK_DNRTMSG) || (defined(HAVE_DECL_NETLINK_DNRTMSG) && HAVE_DECL_NETLINK_DNRTMSG)
+  XLAT(NETLINK_DNRTMSG),
+#endif
+#if defined(NETLINK_KOBJECT_UEVENT) || (defined(HAVE_DECL_NETLINK_KOBJECT_UEVENT) && HAVE_DECL_NETLINK_KOBJECT_UEVENT)
+  XLAT(NETLINK_KOBJECT_UEVENT),
+#endif
+#if defined(NETLINK_GENERIC) || (defined(HAVE_DECL_NETLINK_GENERIC) && HAVE_DECL_NETLINK_GENERIC)
+  XLAT(NETLINK_GENERIC),
+#endif
+#if defined(NETLINK_SCSITRANSPORT) || (defined(HAVE_DECL_NETLINK_SCSITRANSPORT) && HAVE_DECL_NETLINK_SCSITRANSPORT)
+  XLAT(NETLINK_SCSITRANSPORT),
+#endif
+#if defined(NETLINK_ECRYPTFS) || (defined(HAVE_DECL_NETLINK_ECRYPTFS) && HAVE_DECL_NETLINK_ECRYPTFS)
+  XLAT(NETLINK_ECRYPTFS),
+#endif
+#if defined(NETLINK_RDMA) || (defined(HAVE_DECL_NETLINK_RDMA) && HAVE_DECL_NETLINK_RDMA)
+  XLAT(NETLINK_RDMA),
+#endif
+#if defined(NETLINK_CRYPTO) || (defined(HAVE_DECL_NETLINK_CRYPTO) && HAVE_DECL_NETLINK_CRYPTO)
+  XLAT(NETLINK_CRYPTO),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/netlink_protocols.in b/strace/xlat/netlink_protocols.in
new file mode 100644
index 0000000..76383f3
--- /dev/null
+++ b/strace/xlat/netlink_protocols.in
@@ -0,0 +1,21 @@
+NETLINK_ROUTE
+NETLINK_UNUSED
+NETLINK_USERSOCK
+NETLINK_FIREWALL
+NETLINK_SOCK_DIAG
+NETLINK_NFLOG
+NETLINK_XFRM
+NETLINK_SELINUX
+NETLINK_ISCSI
+NETLINK_AUDIT
+NETLINK_FIB_LOOKUP
+NETLINK_CONNECTOR
+NETLINK_NETFILTER
+NETLINK_IP6_FW
+NETLINK_DNRTMSG
+NETLINK_KOBJECT_UEVENT
+NETLINK_GENERIC
+NETLINK_SCSITRANSPORT
+NETLINK_ECRYPTFS
+NETLINK_RDMA
+NETLINK_CRYPTO
diff --git a/strace/xlat/netlink_types.h b/strace/xlat/netlink_types.h
new file mode 100644
index 0000000..96031f2
--- /dev/null
+++ b/strace/xlat/netlink_types.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/netlink_types.in; do not edit. */
+#if !(defined(NLMSG_NOOP) || (defined(HAVE_DECL_NLMSG_NOOP) && HAVE_DECL_NLMSG_NOOP))
+# define NLMSG_NOOP 0x1
+#endif
+#if !(defined(NLMSG_ERROR) || (defined(HAVE_DECL_NLMSG_ERROR) && HAVE_DECL_NLMSG_ERROR))
+# define NLMSG_ERROR 0x2
+#endif
+#if !(defined(NLMSG_DONE) || (defined(HAVE_DECL_NLMSG_DONE) && HAVE_DECL_NLMSG_DONE))
+# define NLMSG_DONE 0x3
+#endif
+#if !(defined(NLMSG_OVERRUN) || (defined(HAVE_DECL_NLMSG_OVERRUN) && HAVE_DECL_NLMSG_OVERRUN))
+# define NLMSG_OVERRUN 0x4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat netlink_types in mpers mode
+
+#else
+
+static
+const struct xlat netlink_types[] = {
+ XLAT(NLMSG_NOOP),
+ XLAT(NLMSG_ERROR),
+ XLAT(NLMSG_DONE),
+ XLAT(NLMSG_OVERRUN),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/netlink_types.in b/strace/xlat/netlink_types.in
new file mode 100644
index 0000000..9cb5297
--- /dev/null
+++ b/strace/xlat/netlink_types.in
@@ -0,0 +1,4 @@
+NLMSG_NOOP             0x1
+NLMSG_ERROR            0x2
+NLMSG_DONE             0x3
+NLMSG_OVERRUN          0x4
diff --git a/strace/xlat/notifyflags.h b/strace/xlat/notifyflags.h
new file mode 100644
index 0000000..e496e8c
--- /dev/null
+++ b/strace/xlat/notifyflags.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/notifyflags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat notifyflags in mpers mode
+
+#else
+
+static
+const struct xlat notifyflags[] = {
+#if defined(DN_ACCESS) || (defined(HAVE_DECL_DN_ACCESS) && HAVE_DECL_DN_ACCESS)
+  XLAT(DN_ACCESS),
+#endif
+#if defined(DN_MODIFY) || (defined(HAVE_DECL_DN_MODIFY) && HAVE_DECL_DN_MODIFY)
+  XLAT(DN_MODIFY),
+#endif
+#if defined(DN_CREATE) || (defined(HAVE_DECL_DN_CREATE) && HAVE_DECL_DN_CREATE)
+  XLAT(DN_CREATE),
+#endif
+#if defined(DN_DELETE) || (defined(HAVE_DECL_DN_DELETE) && HAVE_DECL_DN_DELETE)
+  XLAT(DN_DELETE),
+#endif
+#if defined(DN_RENAME) || (defined(HAVE_DECL_DN_RENAME) && HAVE_DECL_DN_RENAME)
+  XLAT(DN_RENAME),
+#endif
+#if defined(DN_ATTRIB) || (defined(HAVE_DECL_DN_ATTRIB) && HAVE_DECL_DN_ATTRIB)
+  XLAT(DN_ATTRIB),
+#endif
+#if defined(DN_MULTISHOT) || (defined(HAVE_DECL_DN_MULTISHOT) && HAVE_DECL_DN_MULTISHOT)
+  XLAT(DN_MULTISHOT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/notifyflags.in b/strace/xlat/notifyflags.in
new file mode 100644
index 0000000..e9f1492
--- /dev/null
+++ b/strace/xlat/notifyflags.in
@@ -0,0 +1,7 @@
+DN_ACCESS
+DN_MODIFY
+DN_CREATE
+DN_DELETE
+DN_RENAME
+DN_ATTRIB
+DN_MULTISHOT
diff --git a/strace/xlat/nt_descriptor_types.h b/strace/xlat/nt_descriptor_types.h
new file mode 100644
index 0000000..715c281
--- /dev/null
+++ b/strace/xlat/nt_descriptor_types.h
@@ -0,0 +1,83 @@
+/* Generated by ./xlat/gen.sh from ./xlat/nt_descriptor_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat nt_descriptor_types in mpers mode
+
+#else
+
+static
+const struct xlat nt_descriptor_types[] = {
+#if defined(NT_PRSTATUS) || (defined(HAVE_DECL_NT_PRSTATUS) && HAVE_DECL_NT_PRSTATUS)
+  XLAT(NT_PRSTATUS),
+#endif
+#if defined(NT_FPREGSET) || (defined(HAVE_DECL_NT_FPREGSET) && HAVE_DECL_NT_FPREGSET)
+  XLAT(NT_FPREGSET),
+#endif
+#if defined(NT_PRPSINFO) || (defined(HAVE_DECL_NT_PRPSINFO) && HAVE_DECL_NT_PRPSINFO)
+  XLAT(NT_PRPSINFO),
+#endif
+#if defined(NT_PRXREG) || (defined(HAVE_DECL_NT_PRXREG) && HAVE_DECL_NT_PRXREG)
+  XLAT(NT_PRXREG),
+#endif
+#if defined(NT_TASKSTRUCT) || (defined(HAVE_DECL_NT_TASKSTRUCT) && HAVE_DECL_NT_TASKSTRUCT)
+  XLAT(NT_TASKSTRUCT),
+#endif
+#if defined(NT_PLATFORM) || (defined(HAVE_DECL_NT_PLATFORM) && HAVE_DECL_NT_PLATFORM)
+  XLAT(NT_PLATFORM),
+#endif
+#if defined(NT_AUXV) || (defined(HAVE_DECL_NT_AUXV) && HAVE_DECL_NT_AUXV)
+  XLAT(NT_AUXV),
+#endif
+#if defined(NT_GWINDOWS) || (defined(HAVE_DECL_NT_GWINDOWS) && HAVE_DECL_NT_GWINDOWS)
+  XLAT(NT_GWINDOWS),
+#endif
+#if defined(NT_ASRS) || (defined(HAVE_DECL_NT_ASRS) && HAVE_DECL_NT_ASRS)
+  XLAT(NT_ASRS),
+#endif
+#if defined(NT_PSTATUS) || (defined(HAVE_DECL_NT_PSTATUS) && HAVE_DECL_NT_PSTATUS)
+  XLAT(NT_PSTATUS),
+#endif
+#if defined(NT_PSINFO) || (defined(HAVE_DECL_NT_PSINFO) && HAVE_DECL_NT_PSINFO)
+  XLAT(NT_PSINFO),
+#endif
+#if defined(NT_PRCRED) || (defined(HAVE_DECL_NT_PRCRED) && HAVE_DECL_NT_PRCRED)
+  XLAT(NT_PRCRED),
+#endif
+#if defined(NT_UTSNAME) || (defined(HAVE_DECL_NT_UTSNAME) && HAVE_DECL_NT_UTSNAME)
+  XLAT(NT_UTSNAME),
+#endif
+#if defined(NT_LWPSTATUS) || (defined(HAVE_DECL_NT_LWPSTATUS) && HAVE_DECL_NT_LWPSTATUS)
+  XLAT(NT_LWPSTATUS),
+#endif
+#if defined(NT_LWPSINFO) || (defined(HAVE_DECL_NT_LWPSINFO) && HAVE_DECL_NT_LWPSINFO)
+  XLAT(NT_LWPSINFO),
+#endif
+#if defined(NT_PRFPXREG) || (defined(HAVE_DECL_NT_PRFPXREG) && HAVE_DECL_NT_PRFPXREG)
+  XLAT(NT_PRFPXREG),
+#endif
+#if defined(NT_PRXFPREG) || (defined(HAVE_DECL_NT_PRXFPREG) && HAVE_DECL_NT_PRXFPREG)
+  XLAT(NT_PRXFPREG),
+#endif
+#if defined(NT_PPC_VMX) || (defined(HAVE_DECL_NT_PPC_VMX) && HAVE_DECL_NT_PPC_VMX)
+  XLAT(NT_PPC_VMX),
+#endif
+#if defined(NT_PPC_SPE) || (defined(HAVE_DECL_NT_PPC_SPE) && HAVE_DECL_NT_PPC_SPE)
+  XLAT(NT_PPC_SPE),
+#endif
+#if defined(NT_PPC_VSX) || (defined(HAVE_DECL_NT_PPC_VSX) && HAVE_DECL_NT_PPC_VSX)
+  XLAT(NT_PPC_VSX),
+#endif
+#if defined(NT_386_TLS) || (defined(HAVE_DECL_NT_386_TLS) && HAVE_DECL_NT_386_TLS)
+  XLAT(NT_386_TLS),
+#endif
+#if defined(NT_386_IOPERM) || (defined(HAVE_DECL_NT_386_IOPERM) && HAVE_DECL_NT_386_IOPERM)
+  XLAT(NT_386_IOPERM),
+#endif
+#if defined(NT_X86_XSTATE) || (defined(HAVE_DECL_NT_X86_XSTATE) && HAVE_DECL_NT_X86_XSTATE)
+  XLAT(NT_X86_XSTATE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/nt_descriptor_types.in b/strace/xlat/nt_descriptor_types.in
new file mode 100644
index 0000000..5e47d66
--- /dev/null
+++ b/strace/xlat/nt_descriptor_types.in
@@ -0,0 +1,23 @@
+NT_PRSTATUS
+NT_FPREGSET
+NT_PRPSINFO
+NT_PRXREG
+NT_TASKSTRUCT
+NT_PLATFORM
+NT_AUXV
+NT_GWINDOWS
+NT_ASRS
+NT_PSTATUS
+NT_PSINFO
+NT_PRCRED
+NT_UTSNAME
+NT_LWPSTATUS
+NT_LWPSINFO
+NT_PRFPXREG
+NT_PRXFPREG
+NT_PPC_VMX
+NT_PPC_SPE
+NT_PPC_VSX
+NT_386_TLS
+NT_386_IOPERM
+NT_X86_XSTATE
diff --git a/strace/xlat/open_access_modes.h b/strace/xlat/open_access_modes.h
new file mode 100644
index 0000000..8b11517
--- /dev/null
+++ b/strace/xlat/open_access_modes.h
@@ -0,0 +1,21 @@
+/* Generated by ./xlat/gen.sh from ./xlat/open_access_modes.in; do not edit. */
+
+#ifndef IN_MPERS
+
+const struct xlat open_access_modes[] = {
+#if defined(O_RDONLY) || (defined(HAVE_DECL_O_RDONLY) && HAVE_DECL_O_RDONLY)
+  XLAT(O_RDONLY),
+#endif
+#if defined(O_WRONLY) || (defined(HAVE_DECL_O_WRONLY) && HAVE_DECL_O_WRONLY)
+  XLAT(O_WRONLY),
+#endif
+#if defined(O_RDWR) || (defined(HAVE_DECL_O_RDWR) && HAVE_DECL_O_RDWR)
+  XLAT(O_RDWR),
+#endif
+#if defined(O_ACCMODE) || (defined(HAVE_DECL_O_ACCMODE) && HAVE_DECL_O_ACCMODE)
+  XLAT(O_ACCMODE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/open_access_modes.in b/strace/xlat/open_access_modes.in
new file mode 100644
index 0000000..423a29b
--- /dev/null
+++ b/strace/xlat/open_access_modes.in
@@ -0,0 +1,4 @@
+O_RDONLY
+O_WRONLY
+O_RDWR
+O_ACCMODE
diff --git a/strace/xlat/open_mode_flags.h b/strace/xlat/open_mode_flags.h
new file mode 100644
index 0000000..f81f16b
--- /dev/null
+++ b/strace/xlat/open_mode_flags.h
@@ -0,0 +1,121 @@
+/* Generated by ./xlat/gen.sh from ./xlat/open_mode_flags.in; do not edit. */
+#if defined(O_NDELAY) && (O_NDELAY != O_NONBLOCK)
+#endif
+#if defined(O_TMPFILE) && defined(O_DIRECTORY)
+#endif
+
+#ifndef IN_MPERS
+
+const struct xlat open_mode_flags[] = {
+#if defined(O_CREAT) || (defined(HAVE_DECL_O_CREAT) && HAVE_DECL_O_CREAT)
+  XLAT(O_CREAT),
+#endif
+#if defined(O_EXCL) || (defined(HAVE_DECL_O_EXCL) && HAVE_DECL_O_EXCL)
+  XLAT(O_EXCL),
+#endif
+#if defined(O_NOCTTY) || (defined(HAVE_DECL_O_NOCTTY) && HAVE_DECL_O_NOCTTY)
+  XLAT(O_NOCTTY),
+#endif
+#if defined(O_TRUNC) || (defined(HAVE_DECL_O_TRUNC) && HAVE_DECL_O_TRUNC)
+  XLAT(O_TRUNC),
+#endif
+#if defined(O_APPEND) || (defined(HAVE_DECL_O_APPEND) && HAVE_DECL_O_APPEND)
+  XLAT(O_APPEND),
+#endif
+#if defined(O_NONBLOCK) || (defined(HAVE_DECL_O_NONBLOCK) && HAVE_DECL_O_NONBLOCK)
+  XLAT(O_NONBLOCK),
+#endif
+#if defined(O_SYNC) || (defined(HAVE_DECL_O_SYNC) && HAVE_DECL_O_SYNC)
+  XLAT(O_SYNC),
+#endif
+#if defined(O_ASYNC) || (defined(HAVE_DECL_O_ASYNC) && HAVE_DECL_O_ASYNC)
+  XLAT(O_ASYNC),
+#endif
+#if defined(O_DSYNC) || (defined(HAVE_DECL_O_DSYNC) && HAVE_DECL_O_DSYNC)
+  XLAT(O_DSYNC),
+#endif
+#if defined(O_RSYNC) || (defined(HAVE_DECL_O_RSYNC) && HAVE_DECL_O_RSYNC)
+  XLAT(O_RSYNC),
+#endif
+#if defined(O_NDELAY) && (O_NDELAY != O_NONBLOCK)
+#if defined(O_NDELAY) || (defined(HAVE_DECL_O_NDELAY) && HAVE_DECL_O_NDELAY)
+  XLAT(O_NDELAY),
+#endif
+#endif
+#if defined(O_PRIV) || (defined(HAVE_DECL_O_PRIV) && HAVE_DECL_O_PRIV)
+  XLAT(O_PRIV),
+#endif
+#if defined(O_DIRECT) || (defined(HAVE_DECL_O_DIRECT) && HAVE_DECL_O_DIRECT)
+  XLAT(O_DIRECT),
+#endif
+#if defined(O_LARGEFILE) || (defined(HAVE_DECL_O_LARGEFILE) && HAVE_DECL_O_LARGEFILE)
+  XLAT(O_LARGEFILE),
+#endif
+#if defined(O_DIRECTORY) || (defined(HAVE_DECL_O_DIRECTORY) && HAVE_DECL_O_DIRECTORY)
+  XLAT(O_DIRECTORY),
+#endif
+#if defined(O_NOFOLLOW) || (defined(HAVE_DECL_O_NOFOLLOW) && HAVE_DECL_O_NOFOLLOW)
+  XLAT(O_NOFOLLOW),
+#endif
+#if defined(O_NOATIME) || (defined(HAVE_DECL_O_NOATIME) && HAVE_DECL_O_NOATIME)
+  XLAT(O_NOATIME),
+#endif
+#if defined(O_CLOEXEC) || (defined(HAVE_DECL_O_CLOEXEC) && HAVE_DECL_O_CLOEXEC)
+  XLAT(O_CLOEXEC),
+#endif
+#if defined(O_PATH) || (defined(HAVE_DECL_O_PATH) && HAVE_DECL_O_PATH)
+  XLAT(O_PATH),
+#endif
+#if defined(O_TMPFILE) && defined(O_DIRECTORY)
+/* The kernel & C libraries often inline O_DIRECTORY */
+{ O_TMPFILE & ~O_DIRECTORY, "O_TMPFILE" },
+#endif
+#if defined(FNDELAY) || (defined(HAVE_DECL_FNDELAY) && HAVE_DECL_FNDELAY)
+  XLAT(FNDELAY),
+#endif
+#if defined(FAPPEND) || (defined(HAVE_DECL_FAPPEND) && HAVE_DECL_FAPPEND)
+  XLAT(FAPPEND),
+#endif
+#if defined(FMARK) || (defined(HAVE_DECL_FMARK) && HAVE_DECL_FMARK)
+  XLAT(FMARK),
+#endif
+#if defined(FDEFER) || (defined(HAVE_DECL_FDEFER) && HAVE_DECL_FDEFER)
+  XLAT(FDEFER),
+#endif
+#if defined(FASYNC) || (defined(HAVE_DECL_FASYNC) && HAVE_DECL_FASYNC)
+  XLAT(FASYNC),
+#endif
+#if defined(FSHLOCK) || (defined(HAVE_DECL_FSHLOCK) && HAVE_DECL_FSHLOCK)
+  XLAT(FSHLOCK),
+#endif
+#if defined(FEXLOCK) || (defined(HAVE_DECL_FEXLOCK) && HAVE_DECL_FEXLOCK)
+  XLAT(FEXLOCK),
+#endif
+#if defined(FCREAT) || (defined(HAVE_DECL_FCREAT) && HAVE_DECL_FCREAT)
+  XLAT(FCREAT),
+#endif
+#if defined(FTRUNC) || (defined(HAVE_DECL_FTRUNC) && HAVE_DECL_FTRUNC)
+  XLAT(FTRUNC),
+#endif
+#if defined(FEXCL) || (defined(HAVE_DECL_FEXCL) && HAVE_DECL_FEXCL)
+  XLAT(FEXCL),
+#endif
+#if defined(FNBIO) || (defined(HAVE_DECL_FNBIO) && HAVE_DECL_FNBIO)
+  XLAT(FNBIO),
+#endif
+#if defined(FSYNC) || (defined(HAVE_DECL_FSYNC) && HAVE_DECL_FSYNC)
+  XLAT(FSYNC),
+#endif
+#if defined(FNOCTTY) || (defined(HAVE_DECL_FNOCTTY) && HAVE_DECL_FNOCTTY)
+  XLAT(FNOCTTY),
+#endif
+#if defined(O_SHLOCK) || (defined(HAVE_DECL_O_SHLOCK) && HAVE_DECL_O_SHLOCK)
+  XLAT(O_SHLOCK),
+#endif
+#if defined(O_EXLOCK) || (defined(HAVE_DECL_O_EXLOCK) && HAVE_DECL_O_EXLOCK)
+  XLAT(O_EXLOCK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/open_mode_flags.in b/strace/xlat/open_mode_flags.in
new file mode 100644
index 0000000..30bed26
--- /dev/null
+++ b/strace/xlat/open_mode_flags.in
@@ -0,0 +1,40 @@
+O_CREAT
+O_EXCL
+O_NOCTTY
+O_TRUNC
+O_APPEND
+O_NONBLOCK
+O_SYNC
+O_ASYNC
+O_DSYNC
+O_RSYNC
+#if defined(O_NDELAY) && (O_NDELAY != O_NONBLOCK)
+O_NDELAY
+#endif
+O_PRIV
+O_DIRECT
+O_LARGEFILE
+O_DIRECTORY
+O_NOFOLLOW
+O_NOATIME
+O_CLOEXEC
+O_PATH
+#if defined(O_TMPFILE) && defined(O_DIRECTORY)
+/* The kernel & C libraries often inline O_DIRECTORY */
+{ O_TMPFILE & ~O_DIRECTORY, "O_TMPFILE" },
+#endif
+FNDELAY
+FAPPEND
+FMARK
+FDEFER
+FASYNC
+FSHLOCK
+FEXLOCK
+FCREAT
+FTRUNC
+FEXCL
+FNBIO
+FSYNC
+FNOCTTY
+O_SHLOCK
+O_EXLOCK
diff --git a/strace/xlat/openmodessol.h b/strace/xlat/openmodessol.h
new file mode 100644
index 0000000..fb6a553
--- /dev/null
+++ b/strace/xlat/openmodessol.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/openmodessol.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat openmodessol in mpers mode
+
+#else
+
+static
+const struct xlat openmodessol[] = {
+{ 0,		"O_RDWR"	},
+{ 1,		"O_RDONLY"	},
+{ 2,		"O_WRONLY"	},
+{ 0x80,		"O_NONBLOCK"	},
+{ 8,		"O_APPEND"	},
+{ 0x100,	"O_CREAT"	},
+{ 0x200,	"O_TRUNC"	},
+{ 0x400,	"O_EXCL"	},
+{ 0x800,	"O_NOCTTY"	},
+{ 0x10,		"O_SYNC"	},
+{ 0x40,		"O_DSYNC"	},
+{ 0x8000,	"O_RSYNC"	},
+{ 4,		"O_NDELAY"	},
+{ 0x1000,	"O_PRIV"	},
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/openmodessol.in b/strace/xlat/openmodessol.in
new file mode 100644
index 0000000..e42af6f
--- /dev/null
+++ b/strace/xlat/openmodessol.in
@@ -0,0 +1,14 @@
+	{ 0,		"O_RDWR"	},
+	{ 1,		"O_RDONLY"	},
+	{ 2,		"O_WRONLY"	},
+	{ 0x80,		"O_NONBLOCK"	},
+	{ 8,		"O_APPEND"	},
+	{ 0x100,	"O_CREAT"	},
+	{ 0x200,	"O_TRUNC"	},
+	{ 0x400,	"O_EXCL"	},
+	{ 0x800,	"O_NOCTTY"	},
+	{ 0x10,		"O_SYNC"	},
+	{ 0x40,		"O_DSYNC"	},
+	{ 0x8000,	"O_RSYNC"	},
+	{ 4,		"O_NDELAY"	},
+	{ 0x1000,	"O_PRIV"	},
diff --git a/strace/xlat/packet_mreq_type.h b/strace/xlat/packet_mreq_type.h
new file mode 100644
index 0000000..012d3e7
--- /dev/null
+++ b/strace/xlat/packet_mreq_type.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/packet_mreq_type.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat packet_mreq_type in mpers mode
+
+#else
+
+static
+const struct xlat packet_mreq_type[] = {
+#if defined(PACKET_MR_MULTICAST) || (defined(HAVE_DECL_PACKET_MR_MULTICAST) && HAVE_DECL_PACKET_MR_MULTICAST)
+  XLAT(PACKET_MR_MULTICAST),
+#endif
+#if defined(PACKET_MR_PROMISC) || (defined(HAVE_DECL_PACKET_MR_PROMISC) && HAVE_DECL_PACKET_MR_PROMISC)
+  XLAT(PACKET_MR_PROMISC),
+#endif
+#if defined(PACKET_MR_ALLMULTI) || (defined(HAVE_DECL_PACKET_MR_ALLMULTI) && HAVE_DECL_PACKET_MR_ALLMULTI)
+  XLAT(PACKET_MR_ALLMULTI),
+#endif
+#if defined(PACKET_MR_UNICAST) || (defined(HAVE_DECL_PACKET_MR_UNICAST) && HAVE_DECL_PACKET_MR_UNICAST)
+  XLAT(PACKET_MR_UNICAST),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/packet_mreq_type.in b/strace/xlat/packet_mreq_type.in
new file mode 100644
index 0000000..0d6adfe
--- /dev/null
+++ b/strace/xlat/packet_mreq_type.in
@@ -0,0 +1,4 @@
+PACKET_MR_MULTICAST
+PACKET_MR_PROMISC
+PACKET_MR_ALLMULTI
+PACKET_MR_UNICAST
diff --git a/strace/xlat/perf_event_open_flags.h b/strace/xlat/perf_event_open_flags.h
new file mode 100644
index 0000000..922f9c4
--- /dev/null
+++ b/strace/xlat/perf_event_open_flags.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/perf_event_open_flags.in; do not edit. */
+#if !(defined(PERF_FLAG_FD_NO_GROUP) || (defined(HAVE_DECL_PERF_FLAG_FD_NO_GROUP) && HAVE_DECL_PERF_FLAG_FD_NO_GROUP))
+# define PERF_FLAG_FD_NO_GROUP 1
+#endif
+#if !(defined(PERF_FLAG_FD_OUTPUT) || (defined(HAVE_DECL_PERF_FLAG_FD_OUTPUT) && HAVE_DECL_PERF_FLAG_FD_OUTPUT))
+# define PERF_FLAG_FD_OUTPUT 2
+#endif
+#if !(defined(PERF_FLAG_PID_CGROUP) || (defined(HAVE_DECL_PERF_FLAG_PID_CGROUP) && HAVE_DECL_PERF_FLAG_PID_CGROUP))
+# define PERF_FLAG_PID_CGROUP 4
+#endif
+#if !(defined(PERF_FLAG_FD_CLOEXEC) || (defined(HAVE_DECL_PERF_FLAG_FD_CLOEXEC) && HAVE_DECL_PERF_FLAG_FD_CLOEXEC))
+# define PERF_FLAG_FD_CLOEXEC 8
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat perf_event_open_flags in mpers mode
+
+#else
+
+static
+const struct xlat perf_event_open_flags[] = {
+ XLAT(PERF_FLAG_FD_NO_GROUP),
+ XLAT(PERF_FLAG_FD_OUTPUT),
+ XLAT(PERF_FLAG_PID_CGROUP),
+ XLAT(PERF_FLAG_FD_CLOEXEC),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/perf_event_open_flags.in b/strace/xlat/perf_event_open_flags.in
new file mode 100644
index 0000000..b2a3450
--- /dev/null
+++ b/strace/xlat/perf_event_open_flags.in
@@ -0,0 +1,4 @@
+PERF_FLAG_FD_NO_GROUP	1
+PERF_FLAG_FD_OUTPUT	2
+PERF_FLAG_PID_CGROUP	4
+PERF_FLAG_FD_CLOEXEC	8
diff --git a/strace/xlat/personality_flags.h b/strace/xlat/personality_flags.h
new file mode 100644
index 0000000..1941e14
--- /dev/null
+++ b/strace/xlat/personality_flags.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/personality_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat personality_flags in mpers mode
+
+#else
+
+static
+const struct xlat personality_flags[] = {
+ XLAT(UNAME26),
+ XLAT(ADDR_NO_RANDOMIZE),
+ XLAT(FDPIC_FUNCPTRS),
+ XLAT(MMAP_PAGE_ZERO),
+ XLAT(ADDR_COMPAT_LAYOUT),
+ XLAT(READ_IMPLIES_EXEC),
+ XLAT(ADDR_LIMIT_32BIT),
+ XLAT(SHORT_INODE),
+ XLAT(WHOLE_SECONDS),
+ XLAT(STICKY_TIMEOUTS),
+ XLAT(ADDR_LIMIT_3GB),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/personality_flags.in b/strace/xlat/personality_flags.in
new file mode 100644
index 0000000..a8715e2
--- /dev/null
+++ b/strace/xlat/personality_flags.in
@@ -0,0 +1,12 @@
+#unconditional
+UNAME26
+ADDR_NO_RANDOMIZE
+FDPIC_FUNCPTRS
+MMAP_PAGE_ZERO
+ADDR_COMPAT_LAYOUT
+READ_IMPLIES_EXEC
+ADDR_LIMIT_32BIT
+SHORT_INODE
+WHOLE_SECONDS
+STICKY_TIMEOUTS
+ADDR_LIMIT_3GB
diff --git a/strace/xlat/personality_options.h b/strace/xlat/personality_options.h
new file mode 100644
index 0000000..64fb6af
--- /dev/null
+++ b/strace/xlat/personality_options.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/personality_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat personality_options in mpers mode
+
+#else
+
+static
+const struct xlat personality_options[] = {
+ XLAT(PER_LINUX),
+ XLAT(PER_LINUX_32BIT),
+ XLAT(PER_LINUX_FDPIC),
+ XLAT(PER_SVR4),
+ XLAT(PER_SVR3),
+ XLAT(PER_SCOSVR3),
+ XLAT(PER_OSR5),
+ XLAT(PER_WYSEV386),
+ XLAT(PER_ISCR4),
+ XLAT(PER_BSD),
+ XLAT(PER_SUNOS),
+ XLAT(PER_XENIX),
+ XLAT(PER_LINUX32),
+ XLAT(PER_LINUX32_3GB),
+ XLAT(PER_IRIX32),
+ XLAT(PER_IRIXN32),
+ XLAT(PER_IRIX64),
+ XLAT(PER_RISCOS),
+ XLAT(PER_SOLARIS),
+ XLAT(PER_UW7),
+ XLAT(PER_OSF4),
+ XLAT(PER_HPUX),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/personality_types.h b/strace/xlat/personality_types.h
new file mode 100644
index 0000000..859ded3
--- /dev/null
+++ b/strace/xlat/personality_types.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/personality_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat personality_types in mpers mode
+
+#else
+
+static
+const struct xlat personality_types[] = {
+ XLAT(PER_LINUX),
+ XLAT(PER_LINUX_32BIT),
+ XLAT(PER_LINUX_FDPIC),
+ XLAT(PER_SVR4),
+ XLAT(PER_SVR3),
+ XLAT(PER_SCOSVR3),
+ XLAT(PER_OSR5),
+ XLAT(PER_WYSEV386),
+ XLAT(PER_ISCR4),
+ XLAT(PER_BSD),
+ XLAT(PER_SUNOS),
+ XLAT(PER_XENIX),
+ XLAT(PER_LINUX32),
+ XLAT(PER_LINUX32_3GB),
+ XLAT(PER_IRIX32),
+ XLAT(PER_IRIXN32),
+ XLAT(PER_IRIX64),
+ XLAT(PER_RISCOS),
+ XLAT(PER_SOLARIS),
+ XLAT(PER_UW7),
+ XLAT(PER_OSF4),
+ XLAT(PER_HPUX),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/personality_types.in b/strace/xlat/personality_types.in
new file mode 100644
index 0000000..6832c65
--- /dev/null
+++ b/strace/xlat/personality_types.in
@@ -0,0 +1,23 @@
+#unconditional
+PER_LINUX
+PER_LINUX_32BIT
+PER_LINUX_FDPIC
+PER_SVR4
+PER_SVR3
+PER_SCOSVR3
+PER_OSR5
+PER_WYSEV386
+PER_ISCR4
+PER_BSD
+PER_SUNOS
+PER_XENIX
+PER_LINUX32
+PER_LINUX32_3GB
+PER_IRIX32
+PER_IRIXN32
+PER_IRIX64
+PER_RISCOS
+PER_SOLARIS
+PER_UW7
+PER_OSF4
+PER_HPUX
diff --git a/strace/xlat/pmsgflags.h b/strace/xlat/pmsgflags.h
new file mode 100644
index 0000000..b448eae
--- /dev/null
+++ b/strace/xlat/pmsgflags.h
@@ -0,0 +1,14 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pmsgflags.in; do not edit. */
+
+static const struct xlat pmsgflags[] = {
+#if defined(MSG_HIPRI) || (defined(HAVE_DECL_MSG_HIPRI) && HAVE_DECL_MSG_HIPRI)
+ XLAT(MSG_HIPRI),
+#endif
+#if defined(MSG_ANY) || (defined(HAVE_DECL_MSG_ANY) && HAVE_DECL_MSG_ANY)
+ XLAT(MSG_ANY),
+#endif
+#if defined(MSG_BAND) || (defined(HAVE_DECL_MSG_BAND) && HAVE_DECL_MSG_BAND)
+ XLAT(MSG_BAND),
+#endif
+ XLAT_END
+};
diff --git a/strace/xlat/policies.h b/strace/xlat/policies.h
new file mode 100644
index 0000000..8b44db6
--- /dev/null
+++ b/strace/xlat/policies.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/policies.in; do not edit. */
+#if !(defined(MPOL_DEFAULT) || (defined(HAVE_DECL_MPOL_DEFAULT) && HAVE_DECL_MPOL_DEFAULT))
+# define MPOL_DEFAULT 0
+#endif
+#if !(defined(MPOL_PREFERRED) || (defined(HAVE_DECL_MPOL_PREFERRED) && HAVE_DECL_MPOL_PREFERRED))
+# define MPOL_PREFERRED 1
+#endif
+#if !(defined(MPOL_BIND) || (defined(HAVE_DECL_MPOL_BIND) && HAVE_DECL_MPOL_BIND))
+# define MPOL_BIND 2
+#endif
+#if !(defined(MPOL_INTERLEAVE) || (defined(HAVE_DECL_MPOL_INTERLEAVE) && HAVE_DECL_MPOL_INTERLEAVE))
+# define MPOL_INTERLEAVE 3
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat policies in mpers mode
+
+#else
+
+static
+const struct xlat policies[] = {
+ XLAT(MPOL_DEFAULT),
+ XLAT(MPOL_PREFERRED),
+ XLAT(MPOL_BIND),
+ XLAT(MPOL_INTERLEAVE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/policies.in b/strace/xlat/policies.in
new file mode 100644
index 0000000..fab5396
--- /dev/null
+++ b/strace/xlat/policies.in
@@ -0,0 +1,4 @@
+MPOL_DEFAULT	0
+MPOL_PREFERRED	1
+MPOL_BIND	2
+MPOL_INTERLEAVE	3
diff --git a/strace/xlat/pollflags.h b/strace/xlat/pollflags.h
new file mode 100644
index 0000000..3c9f24a
--- /dev/null
+++ b/strace/xlat/pollflags.h
@@ -0,0 +1,44 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pollflags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pollflags in mpers mode
+
+#else
+
+static
+const struct xlat pollflags[] = {
+#if defined(POLLIN) || (defined(HAVE_DECL_POLLIN) && HAVE_DECL_POLLIN)
+  XLAT(POLLIN),
+#endif
+#if defined(POLLPRI) || (defined(HAVE_DECL_POLLPRI) && HAVE_DECL_POLLPRI)
+  XLAT(POLLPRI),
+#endif
+#if defined(POLLOUT) || (defined(HAVE_DECL_POLLOUT) && HAVE_DECL_POLLOUT)
+  XLAT(POLLOUT),
+#endif
+#if defined(POLLRDNORM) || (defined(HAVE_DECL_POLLRDNORM) && HAVE_DECL_POLLRDNORM)
+  XLAT(POLLRDNORM),
+#endif
+#if defined(POLLWRNORM) || (defined(HAVE_DECL_POLLWRNORM) && HAVE_DECL_POLLWRNORM)
+  XLAT(POLLWRNORM),
+#endif
+#if defined(POLLRDBAND) || (defined(HAVE_DECL_POLLRDBAND) && HAVE_DECL_POLLRDBAND)
+  XLAT(POLLRDBAND),
+#endif
+#if defined(POLLWRBAND) || (defined(HAVE_DECL_POLLWRBAND) && HAVE_DECL_POLLWRBAND)
+  XLAT(POLLWRBAND),
+#endif
+#if defined(POLLERR) || (defined(HAVE_DECL_POLLERR) && HAVE_DECL_POLLERR)
+  XLAT(POLLERR),
+#endif
+#if defined(POLLHUP) || (defined(HAVE_DECL_POLLHUP) && HAVE_DECL_POLLHUP)
+  XLAT(POLLHUP),
+#endif
+#if defined(POLLNVAL) || (defined(HAVE_DECL_POLLNVAL) && HAVE_DECL_POLLNVAL)
+  XLAT(POLLNVAL),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pollflags.in b/strace/xlat/pollflags.in
new file mode 100644
index 0000000..db41909
--- /dev/null
+++ b/strace/xlat/pollflags.in
@@ -0,0 +1,10 @@
+POLLIN
+POLLPRI
+POLLOUT
+POLLRDNORM
+POLLWRNORM
+POLLRDBAND
+POLLWRBAND
+POLLERR
+POLLHUP
+POLLNVAL
diff --git a/strace/xlat/pr_cap_ambient.h b/strace/xlat/pr_cap_ambient.h
new file mode 100644
index 0000000..83fa882
--- /dev/null
+++ b/strace/xlat/pr_cap_ambient.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pr_cap_ambient.in; do not edit. */
+#if !(defined(PR_CAP_AMBIENT_IS_SET) || (defined(HAVE_DECL_PR_CAP_AMBIENT_IS_SET) && HAVE_DECL_PR_CAP_AMBIENT_IS_SET))
+# define PR_CAP_AMBIENT_IS_SET 1
+#endif
+#if !(defined(PR_CAP_AMBIENT_RAISE) || (defined(HAVE_DECL_PR_CAP_AMBIENT_RAISE) && HAVE_DECL_PR_CAP_AMBIENT_RAISE))
+# define PR_CAP_AMBIENT_RAISE 2
+#endif
+#if !(defined(PR_CAP_AMBIENT_LOWER) || (defined(HAVE_DECL_PR_CAP_AMBIENT_LOWER) && HAVE_DECL_PR_CAP_AMBIENT_LOWER))
+# define PR_CAP_AMBIENT_LOWER 3
+#endif
+#if !(defined(PR_CAP_AMBIENT_CLEAR_ALL) || (defined(HAVE_DECL_PR_CAP_AMBIENT_CLEAR_ALL) && HAVE_DECL_PR_CAP_AMBIENT_CLEAR_ALL))
+# define PR_CAP_AMBIENT_CLEAR_ALL 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pr_cap_ambient in mpers mode
+
+#else
+
+static
+const struct xlat pr_cap_ambient[] = {
+ XLAT(PR_CAP_AMBIENT_IS_SET),
+ XLAT(PR_CAP_AMBIENT_RAISE),
+ XLAT(PR_CAP_AMBIENT_LOWER),
+ XLAT(PR_CAP_AMBIENT_CLEAR_ALL),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pr_cap_ambient.in b/strace/xlat/pr_cap_ambient.in
new file mode 100644
index 0000000..0f0d2f2
--- /dev/null
+++ b/strace/xlat/pr_cap_ambient.in
@@ -0,0 +1,4 @@
+PR_CAP_AMBIENT_IS_SET	1
+PR_CAP_AMBIENT_RAISE	2
+PR_CAP_AMBIENT_LOWER	3
+PR_CAP_AMBIENT_CLEAR_ALL	4
diff --git a/strace/xlat/pr_mce_kill.h b/strace/xlat/pr_mce_kill.h
new file mode 100644
index 0000000..d2839db
--- /dev/null
+++ b/strace/xlat/pr_mce_kill.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pr_mce_kill.in; do not edit. */
+#if !(defined(PR_MCE_KILL_CLEAR) || (defined(HAVE_DECL_PR_MCE_KILL_CLEAR) && HAVE_DECL_PR_MCE_KILL_CLEAR))
+# define PR_MCE_KILL_CLEAR 0
+#endif
+#if !(defined(PR_MCE_KILL_SET) || (defined(HAVE_DECL_PR_MCE_KILL_SET) && HAVE_DECL_PR_MCE_KILL_SET))
+# define PR_MCE_KILL_SET 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pr_mce_kill in mpers mode
+
+#else
+
+static
+const struct xlat pr_mce_kill[] = {
+ XLAT(PR_MCE_KILL_CLEAR),
+ XLAT(PR_MCE_KILL_SET),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pr_mce_kill.in b/strace/xlat/pr_mce_kill.in
new file mode 100644
index 0000000..574e55f
--- /dev/null
+++ b/strace/xlat/pr_mce_kill.in
@@ -0,0 +1,2 @@
+PR_MCE_KILL_CLEAR 0
+PR_MCE_KILL_SET 1
diff --git a/strace/xlat/pr_mce_kill_policy.h b/strace/xlat/pr_mce_kill_policy.h
new file mode 100644
index 0000000..aee9568
--- /dev/null
+++ b/strace/xlat/pr_mce_kill_policy.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pr_mce_kill_policy.in; do not edit. */
+#if !(defined(PR_MCE_KILL_LATE) || (defined(HAVE_DECL_PR_MCE_KILL_LATE) && HAVE_DECL_PR_MCE_KILL_LATE))
+# define PR_MCE_KILL_LATE 0
+#endif
+#if !(defined(PR_MCE_KILL_EARLY) || (defined(HAVE_DECL_PR_MCE_KILL_EARLY) && HAVE_DECL_PR_MCE_KILL_EARLY))
+# define PR_MCE_KILL_EARLY 1
+#endif
+#if !(defined(PR_MCE_KILL_DEFAULT) || (defined(HAVE_DECL_PR_MCE_KILL_DEFAULT) && HAVE_DECL_PR_MCE_KILL_DEFAULT))
+# define PR_MCE_KILL_DEFAULT 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pr_mce_kill_policy in mpers mode
+
+#else
+
+static
+const struct xlat pr_mce_kill_policy[] = {
+ XLAT(PR_MCE_KILL_LATE),
+ XLAT(PR_MCE_KILL_EARLY),
+ XLAT(PR_MCE_KILL_DEFAULT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pr_mce_kill_policy.in b/strace/xlat/pr_mce_kill_policy.in
new file mode 100644
index 0000000..510b566
--- /dev/null
+++ b/strace/xlat/pr_mce_kill_policy.in
@@ -0,0 +1,3 @@
+PR_MCE_KILL_LATE 0
+PR_MCE_KILL_EARLY 1
+PR_MCE_KILL_DEFAULT 2
diff --git a/strace/xlat/pr_set_mm.h b/strace/xlat/pr_set_mm.h
new file mode 100644
index 0000000..bc07483
--- /dev/null
+++ b/strace/xlat/pr_set_mm.h
@@ -0,0 +1,74 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pr_set_mm.in; do not edit. */
+#if !(defined(PR_SET_MM_START_CODE) || (defined(HAVE_DECL_PR_SET_MM_START_CODE) && HAVE_DECL_PR_SET_MM_START_CODE))
+# define PR_SET_MM_START_CODE 1
+#endif
+#if !(defined(PR_SET_MM_END_CODE) || (defined(HAVE_DECL_PR_SET_MM_END_CODE) && HAVE_DECL_PR_SET_MM_END_CODE))
+# define PR_SET_MM_END_CODE 2
+#endif
+#if !(defined(PR_SET_MM_START_DATA) || (defined(HAVE_DECL_PR_SET_MM_START_DATA) && HAVE_DECL_PR_SET_MM_START_DATA))
+# define PR_SET_MM_START_DATA 3
+#endif
+#if !(defined(PR_SET_MM_END_DATA) || (defined(HAVE_DECL_PR_SET_MM_END_DATA) && HAVE_DECL_PR_SET_MM_END_DATA))
+# define PR_SET_MM_END_DATA 4
+#endif
+#if !(defined(PR_SET_MM_START_STACK) || (defined(HAVE_DECL_PR_SET_MM_START_STACK) && HAVE_DECL_PR_SET_MM_START_STACK))
+# define PR_SET_MM_START_STACK 5
+#endif
+#if !(defined(PR_SET_MM_START_BRK) || (defined(HAVE_DECL_PR_SET_MM_START_BRK) && HAVE_DECL_PR_SET_MM_START_BRK))
+# define PR_SET_MM_START_BRK 6
+#endif
+#if !(defined(PR_SET_MM_BRK) || (defined(HAVE_DECL_PR_SET_MM_BRK) && HAVE_DECL_PR_SET_MM_BRK))
+# define PR_SET_MM_BRK 7
+#endif
+#if !(defined(PR_SET_MM_ARG_START) || (defined(HAVE_DECL_PR_SET_MM_ARG_START) && HAVE_DECL_PR_SET_MM_ARG_START))
+# define PR_SET_MM_ARG_START 8
+#endif
+#if !(defined(PR_SET_MM_ARG_END) || (defined(HAVE_DECL_PR_SET_MM_ARG_END) && HAVE_DECL_PR_SET_MM_ARG_END))
+# define PR_SET_MM_ARG_END 9
+#endif
+#if !(defined(PR_SET_MM_ENV_START) || (defined(HAVE_DECL_PR_SET_MM_ENV_START) && HAVE_DECL_PR_SET_MM_ENV_START))
+# define PR_SET_MM_ENV_START 10
+#endif
+#if !(defined(PR_SET_MM_ENV_END) || (defined(HAVE_DECL_PR_SET_MM_ENV_END) && HAVE_DECL_PR_SET_MM_ENV_END))
+# define PR_SET_MM_ENV_END 11
+#endif
+#if !(defined(PR_SET_MM_AUXV) || (defined(HAVE_DECL_PR_SET_MM_AUXV) && HAVE_DECL_PR_SET_MM_AUXV))
+# define PR_SET_MM_AUXV 12
+#endif
+#if !(defined(PR_SET_MM_EXE_FILE) || (defined(HAVE_DECL_PR_SET_MM_EXE_FILE) && HAVE_DECL_PR_SET_MM_EXE_FILE))
+# define PR_SET_MM_EXE_FILE 13
+#endif
+#if !(defined(PR_SET_MM_MAP) || (defined(HAVE_DECL_PR_SET_MM_MAP) && HAVE_DECL_PR_SET_MM_MAP))
+# define PR_SET_MM_MAP 14
+#endif
+#if !(defined(PR_SET_MM_MAP_SIZE) || (defined(HAVE_DECL_PR_SET_MM_MAP_SIZE) && HAVE_DECL_PR_SET_MM_MAP_SIZE))
+# define PR_SET_MM_MAP_SIZE 15
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pr_set_mm in mpers mode
+
+#else
+
+static
+const struct xlat pr_set_mm[] = {
+ XLAT(PR_SET_MM_START_CODE),
+ XLAT(PR_SET_MM_END_CODE),
+ XLAT(PR_SET_MM_START_DATA),
+ XLAT(PR_SET_MM_END_DATA),
+ XLAT(PR_SET_MM_START_STACK),
+ XLAT(PR_SET_MM_START_BRK),
+ XLAT(PR_SET_MM_BRK),
+ XLAT(PR_SET_MM_ARG_START),
+ XLAT(PR_SET_MM_ARG_END),
+ XLAT(PR_SET_MM_ENV_START),
+ XLAT(PR_SET_MM_ENV_END),
+ XLAT(PR_SET_MM_AUXV),
+ XLAT(PR_SET_MM_EXE_FILE),
+ XLAT(PR_SET_MM_MAP),
+ XLAT(PR_SET_MM_MAP_SIZE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pr_set_mm.in b/strace/xlat/pr_set_mm.in
new file mode 100644
index 0000000..191ba8d
--- /dev/null
+++ b/strace/xlat/pr_set_mm.in
@@ -0,0 +1,15 @@
+PR_SET_MM_START_CODE 1
+PR_SET_MM_END_CODE 2
+PR_SET_MM_START_DATA 3
+PR_SET_MM_END_DATA 4
+PR_SET_MM_START_STACK 5
+PR_SET_MM_START_BRK 6
+PR_SET_MM_BRK 7
+PR_SET_MM_ARG_START 8
+PR_SET_MM_ARG_END 9
+PR_SET_MM_ENV_START 10
+PR_SET_MM_ENV_END 11
+PR_SET_MM_AUXV 12
+PR_SET_MM_EXE_FILE 13
+PR_SET_MM_MAP 14
+PR_SET_MM_MAP_SIZE 15
diff --git a/strace/xlat/pr_tsc.h b/strace/xlat/pr_tsc.h
new file mode 100644
index 0000000..daec871
--- /dev/null
+++ b/strace/xlat/pr_tsc.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pr_tsc.in; do not edit. */
+#if !(defined(PR_TSC_ENABLE) || (defined(HAVE_DECL_PR_TSC_ENABLE) && HAVE_DECL_PR_TSC_ENABLE))
+# define PR_TSC_ENABLE 1
+#endif
+#if !(defined(PR_TSC_SIGSEGV) || (defined(HAVE_DECL_PR_TSC_SIGSEGV) && HAVE_DECL_PR_TSC_SIGSEGV))
+# define PR_TSC_SIGSEGV 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pr_tsc in mpers mode
+
+#else
+
+static
+const struct xlat pr_tsc[] = {
+ XLAT(PR_TSC_ENABLE),
+ XLAT(PR_TSC_SIGSEGV),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pr_tsc.in b/strace/xlat/pr_tsc.in
new file mode 100644
index 0000000..d03aafc
--- /dev/null
+++ b/strace/xlat/pr_tsc.in
@@ -0,0 +1,2 @@
+PR_TSC_ENABLE 1
+PR_TSC_SIGSEGV 2
diff --git a/strace/xlat/pr_unalign_flags.h b/strace/xlat/pr_unalign_flags.h
new file mode 100644
index 0000000..5a92686
--- /dev/null
+++ b/strace/xlat/pr_unalign_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/pr_unalign_flags.in; do not edit. */
+#if !(defined(PR_UNALIGN_NOPRINT) || (defined(HAVE_DECL_PR_UNALIGN_NOPRINT) && HAVE_DECL_PR_UNALIGN_NOPRINT))
+# define PR_UNALIGN_NOPRINT 1
+#endif
+#if !(defined(PR_UNALIGN_SIGBUS) || (defined(HAVE_DECL_PR_UNALIGN_SIGBUS) && HAVE_DECL_PR_UNALIGN_SIGBUS))
+# define PR_UNALIGN_SIGBUS 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat pr_unalign_flags in mpers mode
+
+#else
+
+static
+const struct xlat pr_unalign_flags[] = {
+ XLAT(PR_UNALIGN_NOPRINT),
+ XLAT(PR_UNALIGN_SIGBUS),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/pr_unalign_flags.in b/strace/xlat/pr_unalign_flags.in
new file mode 100644
index 0000000..0d3f2ff
--- /dev/null
+++ b/strace/xlat/pr_unalign_flags.in
@@ -0,0 +1,2 @@
+PR_UNALIGN_NOPRINT 1
+PR_UNALIGN_SIGBUS 2
diff --git a/strace/xlat/prctl_options.h b/strace/xlat/prctl_options.h
new file mode 100644
index 0000000..f1475b4
--- /dev/null
+++ b/strace/xlat/prctl_options.h
@@ -0,0 +1,202 @@
+/* Generated by ./xlat/gen.sh from ./xlat/prctl_options.in; do not edit. */
+#if !(defined(PR_SET_PDEATHSIG) || (defined(HAVE_DECL_PR_SET_PDEATHSIG) && HAVE_DECL_PR_SET_PDEATHSIG))
+# define PR_SET_PDEATHSIG 1
+#endif
+#if !(defined(PR_GET_PDEATHSIG) || (defined(HAVE_DECL_PR_GET_PDEATHSIG) && HAVE_DECL_PR_GET_PDEATHSIG))
+# define PR_GET_PDEATHSIG 2
+#endif
+#if !(defined(PR_GET_DUMPABLE) || (defined(HAVE_DECL_PR_GET_DUMPABLE) && HAVE_DECL_PR_GET_DUMPABLE))
+# define PR_GET_DUMPABLE 3
+#endif
+#if !(defined(PR_SET_DUMPABLE) || (defined(HAVE_DECL_PR_SET_DUMPABLE) && HAVE_DECL_PR_SET_DUMPABLE))
+# define PR_SET_DUMPABLE 4
+#endif
+#if !(defined(PR_GET_UNALIGN) || (defined(HAVE_DECL_PR_GET_UNALIGN) && HAVE_DECL_PR_GET_UNALIGN))
+# define PR_GET_UNALIGN 5
+#endif
+#if !(defined(PR_SET_UNALIGN) || (defined(HAVE_DECL_PR_SET_UNALIGN) && HAVE_DECL_PR_SET_UNALIGN))
+# define PR_SET_UNALIGN 6
+#endif
+#if !(defined(PR_GET_KEEPCAPS) || (defined(HAVE_DECL_PR_GET_KEEPCAPS) && HAVE_DECL_PR_GET_KEEPCAPS))
+# define PR_GET_KEEPCAPS 7
+#endif
+#if !(defined(PR_SET_KEEPCAPS) || (defined(HAVE_DECL_PR_SET_KEEPCAPS) && HAVE_DECL_PR_SET_KEEPCAPS))
+# define PR_SET_KEEPCAPS 8
+#endif
+#if !(defined(PR_GET_FPEMU) || (defined(HAVE_DECL_PR_GET_FPEMU) && HAVE_DECL_PR_GET_FPEMU))
+# define PR_GET_FPEMU 9
+#endif
+#if !(defined(PR_SET_FPEMU) || (defined(HAVE_DECL_PR_SET_FPEMU) && HAVE_DECL_PR_SET_FPEMU))
+# define PR_SET_FPEMU 10
+#endif
+#if !(defined(PR_GET_FPEXC) || (defined(HAVE_DECL_PR_GET_FPEXC) && HAVE_DECL_PR_GET_FPEXC))
+# define PR_GET_FPEXC 11
+#endif
+#if !(defined(PR_SET_FPEXC) || (defined(HAVE_DECL_PR_SET_FPEXC) && HAVE_DECL_PR_SET_FPEXC))
+# define PR_SET_FPEXC 12
+#endif
+#if !(defined(PR_GET_TIMING) || (defined(HAVE_DECL_PR_GET_TIMING) && HAVE_DECL_PR_GET_TIMING))
+# define PR_GET_TIMING 13
+#endif
+#if !(defined(PR_SET_TIMING) || (defined(HAVE_DECL_PR_SET_TIMING) && HAVE_DECL_PR_SET_TIMING))
+# define PR_SET_TIMING 14
+#endif
+#if !(defined(PR_SET_NAME) || (defined(HAVE_DECL_PR_SET_NAME) && HAVE_DECL_PR_SET_NAME))
+# define PR_SET_NAME 15
+#endif
+#if !(defined(PR_GET_NAME) || (defined(HAVE_DECL_PR_GET_NAME) && HAVE_DECL_PR_GET_NAME))
+# define PR_GET_NAME 16
+#endif
+#if !(defined(PR_GET_ENDIAN) || (defined(HAVE_DECL_PR_GET_ENDIAN) && HAVE_DECL_PR_GET_ENDIAN))
+# define PR_GET_ENDIAN 19
+#endif
+#if !(defined(PR_SET_ENDIAN) || (defined(HAVE_DECL_PR_SET_ENDIAN) && HAVE_DECL_PR_SET_ENDIAN))
+# define PR_SET_ENDIAN 20
+#endif
+#if !(defined(PR_GET_SECCOMP) || (defined(HAVE_DECL_PR_GET_SECCOMP) && HAVE_DECL_PR_GET_SECCOMP))
+# define PR_GET_SECCOMP 21
+#endif
+#if !(defined(PR_SET_SECCOMP) || (defined(HAVE_DECL_PR_SET_SECCOMP) && HAVE_DECL_PR_SET_SECCOMP))
+# define PR_SET_SECCOMP 22
+#endif
+#if !(defined(PR_CAPBSET_READ) || (defined(HAVE_DECL_PR_CAPBSET_READ) && HAVE_DECL_PR_CAPBSET_READ))
+# define PR_CAPBSET_READ 23
+#endif
+#if !(defined(PR_CAPBSET_DROP) || (defined(HAVE_DECL_PR_CAPBSET_DROP) && HAVE_DECL_PR_CAPBSET_DROP))
+# define PR_CAPBSET_DROP 24
+#endif
+#if !(defined(PR_GET_TSC) || (defined(HAVE_DECL_PR_GET_TSC) && HAVE_DECL_PR_GET_TSC))
+# define PR_GET_TSC 25
+#endif
+#if !(defined(PR_SET_TSC) || (defined(HAVE_DECL_PR_SET_TSC) && HAVE_DECL_PR_SET_TSC))
+# define PR_SET_TSC 26
+#endif
+#if !(defined(PR_GET_SECUREBITS) || (defined(HAVE_DECL_PR_GET_SECUREBITS) && HAVE_DECL_PR_GET_SECUREBITS))
+# define PR_GET_SECUREBITS 27
+#endif
+#if !(defined(PR_SET_SECUREBITS) || (defined(HAVE_DECL_PR_SET_SECUREBITS) && HAVE_DECL_PR_SET_SECUREBITS))
+# define PR_SET_SECUREBITS 28
+#endif
+#if !(defined(PR_SET_TIMERSLACK) || (defined(HAVE_DECL_PR_SET_TIMERSLACK) && HAVE_DECL_PR_SET_TIMERSLACK))
+# define PR_SET_TIMERSLACK 29
+#endif
+#if !(defined(PR_GET_TIMERSLACK) || (defined(HAVE_DECL_PR_GET_TIMERSLACK) && HAVE_DECL_PR_GET_TIMERSLACK))
+# define PR_GET_TIMERSLACK 30
+#endif
+#if !(defined(PR_TASK_PERF_EVENTS_DISABLE) || (defined(HAVE_DECL_PR_TASK_PERF_EVENTS_DISABLE) && HAVE_DECL_PR_TASK_PERF_EVENTS_DISABLE))
+# define PR_TASK_PERF_EVENTS_DISABLE 31
+#endif
+#if !(defined(PR_TASK_PERF_EVENTS_ENABLE) || (defined(HAVE_DECL_PR_TASK_PERF_EVENTS_ENABLE) && HAVE_DECL_PR_TASK_PERF_EVENTS_ENABLE))
+# define PR_TASK_PERF_EVENTS_ENABLE 32
+#endif
+#if !(defined(PR_MCE_KILL) || (defined(HAVE_DECL_PR_MCE_KILL) && HAVE_DECL_PR_MCE_KILL))
+# define PR_MCE_KILL 33
+#endif
+#if !(defined(PR_MCE_KILL_GET) || (defined(HAVE_DECL_PR_MCE_KILL_GET) && HAVE_DECL_PR_MCE_KILL_GET))
+# define PR_MCE_KILL_GET 34
+#endif
+#if !(defined(PR_SET_MM) || (defined(HAVE_DECL_PR_SET_MM) && HAVE_DECL_PR_SET_MM))
+# define PR_SET_MM 35
+#endif
+#if !(defined(PR_SET_PTRACER) || (defined(HAVE_DECL_PR_SET_PTRACER) && HAVE_DECL_PR_SET_PTRACER))
+# define PR_SET_PTRACER 0x59616d61
+#endif
+#if !(defined(PR_SET_CHILD_SUBREAPER) || (defined(HAVE_DECL_PR_SET_CHILD_SUBREAPER) && HAVE_DECL_PR_SET_CHILD_SUBREAPER))
+# define PR_SET_CHILD_SUBREAPER 36
+#endif
+#if !(defined(PR_GET_CHILD_SUBREAPER) || (defined(HAVE_DECL_PR_GET_CHILD_SUBREAPER) && HAVE_DECL_PR_GET_CHILD_SUBREAPER))
+# define PR_GET_CHILD_SUBREAPER 37
+#endif
+#if !(defined(PR_SET_NO_NEW_PRIVS) || (defined(HAVE_DECL_PR_SET_NO_NEW_PRIVS) && HAVE_DECL_PR_SET_NO_NEW_PRIVS))
+# define PR_SET_NO_NEW_PRIVS 38
+#endif
+#if !(defined(PR_GET_NO_NEW_PRIVS) || (defined(HAVE_DECL_PR_GET_NO_NEW_PRIVS) && HAVE_DECL_PR_GET_NO_NEW_PRIVS))
+# define PR_GET_NO_NEW_PRIVS 39
+#endif
+#if !(defined(PR_GET_TID_ADDRESS) || (defined(HAVE_DECL_PR_GET_TID_ADDRESS) && HAVE_DECL_PR_GET_TID_ADDRESS))
+# define PR_GET_TID_ADDRESS 40
+#endif
+#if !(defined(PR_SET_THP_DISABLE) || (defined(HAVE_DECL_PR_SET_THP_DISABLE) && HAVE_DECL_PR_SET_THP_DISABLE))
+# define PR_SET_THP_DISABLE 41
+#endif
+#if !(defined(PR_GET_THP_DISABLE) || (defined(HAVE_DECL_PR_GET_THP_DISABLE) && HAVE_DECL_PR_GET_THP_DISABLE))
+# define PR_GET_THP_DISABLE 42
+#endif
+#if !(defined(PR_MPX_ENABLE_MANAGEMENT) || (defined(HAVE_DECL_PR_MPX_ENABLE_MANAGEMENT) && HAVE_DECL_PR_MPX_ENABLE_MANAGEMENT))
+# define PR_MPX_ENABLE_MANAGEMENT 43
+#endif
+#if !(defined(PR_MPX_DISABLE_MANAGEMENT) || (defined(HAVE_DECL_PR_MPX_DISABLE_MANAGEMENT) && HAVE_DECL_PR_MPX_DISABLE_MANAGEMENT))
+# define PR_MPX_DISABLE_MANAGEMENT 44
+#endif
+#if !(defined(PR_SET_FP_MODE) || (defined(HAVE_DECL_PR_SET_FP_MODE) && HAVE_DECL_PR_SET_FP_MODE))
+# define PR_SET_FP_MODE 45
+#endif
+#if !(defined(PR_GET_FP_MODE) || (defined(HAVE_DECL_PR_GET_FP_MODE) && HAVE_DECL_PR_GET_FP_MODE))
+# define PR_GET_FP_MODE 46
+#endif
+#if !(defined(PR_CAP_AMBIENT) || (defined(HAVE_DECL_PR_CAP_AMBIENT) && HAVE_DECL_PR_CAP_AMBIENT))
+# define PR_CAP_AMBIENT 47
+#endif
+#if !(defined(PR_SET_VMA) || (defined(HAVE_DECL_PR_SET_VMA) && HAVE_DECL_PR_SET_VMA))
+# define PR_SET_VMA 0x53564d41
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat prctl_options in mpers mode
+
+#else
+
+static
+const struct xlat prctl_options[] = {
+ XLAT(PR_SET_PDEATHSIG),
+ XLAT(PR_GET_PDEATHSIG),
+ XLAT(PR_GET_DUMPABLE),
+ XLAT(PR_SET_DUMPABLE),
+ XLAT(PR_GET_UNALIGN),
+ XLAT(PR_SET_UNALIGN),
+ XLAT(PR_GET_KEEPCAPS),
+ XLAT(PR_SET_KEEPCAPS),
+ XLAT(PR_GET_FPEMU),
+ XLAT(PR_SET_FPEMU),
+ XLAT(PR_GET_FPEXC),
+ XLAT(PR_SET_FPEXC),
+ XLAT(PR_GET_TIMING),
+ XLAT(PR_SET_TIMING),
+ XLAT(PR_SET_NAME),
+ XLAT(PR_GET_NAME),
+ XLAT(PR_GET_ENDIAN),
+ XLAT(PR_SET_ENDIAN),
+ XLAT(PR_GET_SECCOMP),
+ XLAT(PR_SET_SECCOMP),
+ XLAT(PR_CAPBSET_READ),
+ XLAT(PR_CAPBSET_DROP),
+ XLAT(PR_GET_TSC),
+ XLAT(PR_SET_TSC),
+ XLAT(PR_GET_SECUREBITS),
+ XLAT(PR_SET_SECUREBITS),
+ XLAT(PR_SET_TIMERSLACK),
+ XLAT(PR_GET_TIMERSLACK),
+ XLAT(PR_TASK_PERF_EVENTS_DISABLE),
+ XLAT(PR_TASK_PERF_EVENTS_ENABLE),
+ XLAT(PR_MCE_KILL),
+ XLAT(PR_MCE_KILL_GET),
+ XLAT(PR_SET_MM),
+ XLAT(PR_SET_PTRACER),
+ XLAT(PR_SET_CHILD_SUBREAPER),
+ XLAT(PR_GET_CHILD_SUBREAPER),
+ XLAT(PR_SET_NO_NEW_PRIVS),
+ XLAT(PR_GET_NO_NEW_PRIVS),
+ XLAT(PR_GET_TID_ADDRESS),
+ XLAT(PR_SET_THP_DISABLE),
+ XLAT(PR_GET_THP_DISABLE),
+ XLAT(PR_MPX_ENABLE_MANAGEMENT),
+ XLAT(PR_MPX_DISABLE_MANAGEMENT),
+ XLAT(PR_SET_FP_MODE),
+ XLAT(PR_GET_FP_MODE),
+ XLAT(PR_CAP_AMBIENT),
+ XLAT(PR_SET_VMA),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/prctl_options.in b/strace/xlat/prctl_options.in
new file mode 100644
index 0000000..8c09ee3
--- /dev/null
+++ b/strace/xlat/prctl_options.in
@@ -0,0 +1,47 @@
+PR_SET_PDEATHSIG 1
+PR_GET_PDEATHSIG 2
+PR_GET_DUMPABLE 3
+PR_SET_DUMPABLE 4
+PR_GET_UNALIGN 5
+PR_SET_UNALIGN 6
+PR_GET_KEEPCAPS 7
+PR_SET_KEEPCAPS 8
+PR_GET_FPEMU 9
+PR_SET_FPEMU 10
+PR_GET_FPEXC 11
+PR_SET_FPEXC 12
+PR_GET_TIMING 13
+PR_SET_TIMING 14
+PR_SET_NAME 15
+PR_GET_NAME 16
+PR_GET_ENDIAN 19
+PR_SET_ENDIAN 20
+PR_GET_SECCOMP 21
+PR_SET_SECCOMP 22
+PR_CAPBSET_READ 23
+PR_CAPBSET_DROP 24
+PR_GET_TSC 25
+PR_SET_TSC 26
+PR_GET_SECUREBITS 27
+PR_SET_SECUREBITS 28
+PR_SET_TIMERSLACK 29
+PR_GET_TIMERSLACK 30
+PR_TASK_PERF_EVENTS_DISABLE 31
+PR_TASK_PERF_EVENTS_ENABLE 32
+PR_MCE_KILL 33
+PR_MCE_KILL_GET 34
+PR_SET_MM 35
+PR_SET_PTRACER 0x59616d61
+PR_SET_CHILD_SUBREAPER 36
+PR_GET_CHILD_SUBREAPER 37
+PR_SET_NO_NEW_PRIVS 38
+PR_GET_NO_NEW_PRIVS 39
+PR_GET_TID_ADDRESS 40
+PR_SET_THP_DISABLE 41
+PR_GET_THP_DISABLE 42
+PR_MPX_ENABLE_MANAGEMENT 43
+PR_MPX_DISABLE_MANAGEMENT 44
+PR_SET_FP_MODE 45
+PR_GET_FP_MODE 46
+PR_CAP_AMBIENT 47
+PR_SET_VMA 0x53564d41
diff --git a/strace/xlat/priorities.h b/strace/xlat/priorities.h
new file mode 100644
index 0000000..72c1a44
--- /dev/null
+++ b/strace/xlat/priorities.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/priorities.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat priorities in mpers mode
+
+#else
+
+static
+const struct xlat priorities[] = {
+#if defined(PRIO_PROCESS) || (defined(HAVE_DECL_PRIO_PROCESS) && HAVE_DECL_PRIO_PROCESS)
+  XLAT(PRIO_PROCESS),
+#endif
+#if defined(PRIO_PGRP) || (defined(HAVE_DECL_PRIO_PGRP) && HAVE_DECL_PRIO_PGRP)
+  XLAT(PRIO_PGRP),
+#endif
+#if defined(PRIO_USER) || (defined(HAVE_DECL_PRIO_USER) && HAVE_DECL_PRIO_USER)
+  XLAT(PRIO_USER),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/priorities.in b/strace/xlat/priorities.in
new file mode 100644
index 0000000..d1eaaee
--- /dev/null
+++ b/strace/xlat/priorities.in
@@ -0,0 +1,3 @@
+PRIO_PROCESS
+PRIO_PGRP
+PRIO_USER
diff --git a/strace/xlat/ptp_flags_options.h b/strace/xlat/ptp_flags_options.h
new file mode 100644
index 0000000..4ceffa6
--- /dev/null
+++ b/strace/xlat/ptp_flags_options.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ptp_flags_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ptp_flags_options in mpers mode
+
+#else
+
+static
+const struct xlat ptp_flags_options[] = {
+#if defined(PTP_ENABLE_FEATURE) || (defined(HAVE_DECL_PTP_ENABLE_FEATURE) && HAVE_DECL_PTP_ENABLE_FEATURE)
+  XLAT(PTP_ENABLE_FEATURE),
+#endif
+#if defined(PTP_RISING_EDGE) || (defined(HAVE_DECL_PTP_RISING_EDGE) && HAVE_DECL_PTP_RISING_EDGE)
+  XLAT(PTP_RISING_EDGE),
+#endif
+#if defined(PTP_FALLING_EDGE) || (defined(HAVE_DECL_PTP_FALLING_EDGE) && HAVE_DECL_PTP_FALLING_EDGE)
+  XLAT(PTP_FALLING_EDGE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ptp_flags_options.in b/strace/xlat/ptp_flags_options.in
new file mode 100644
index 0000000..9e65c7d
--- /dev/null
+++ b/strace/xlat/ptp_flags_options.in
@@ -0,0 +1,3 @@
+PTP_ENABLE_FEATURE
+PTP_RISING_EDGE
+PTP_FALLING_EDGE
diff --git a/strace/xlat/ptrace_cmds.h b/strace/xlat/ptrace_cmds.h
new file mode 100644
index 0000000..0a8e0f0
--- /dev/null
+++ b/strace/xlat/ptrace_cmds.h
@@ -0,0 +1,300 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ptrace_cmds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ptrace_cmds in mpers mode
+
+#else
+
+static
+const struct xlat ptrace_cmds[] = {
+#if defined(PTRACE_TRACEME) || (defined(HAVE_DECL_PTRACE_TRACEME) && HAVE_DECL_PTRACE_TRACEME)
+  XLAT(PTRACE_TRACEME),
+#endif
+#if defined(PTRACE_PEEKTEXT) || (defined(HAVE_DECL_PTRACE_PEEKTEXT) && HAVE_DECL_PTRACE_PEEKTEXT)
+  XLAT(PTRACE_PEEKTEXT),
+#endif
+#if defined(PTRACE_PEEKDATA) || (defined(HAVE_DECL_PTRACE_PEEKDATA) && HAVE_DECL_PTRACE_PEEKDATA)
+  XLAT(PTRACE_PEEKDATA),
+#endif
+#if defined(PTRACE_PEEKUSER) || (defined(HAVE_DECL_PTRACE_PEEKUSER) && HAVE_DECL_PTRACE_PEEKUSER)
+  XLAT(PTRACE_PEEKUSER),
+#endif
+#if defined(PTRACE_POKETEXT) || (defined(HAVE_DECL_PTRACE_POKETEXT) && HAVE_DECL_PTRACE_POKETEXT)
+  XLAT(PTRACE_POKETEXT),
+#endif
+#if defined(PTRACE_POKEDATA) || (defined(HAVE_DECL_PTRACE_POKEDATA) && HAVE_DECL_PTRACE_POKEDATA)
+  XLAT(PTRACE_POKEDATA),
+#endif
+#if defined(PTRACE_POKEUSER) || (defined(HAVE_DECL_PTRACE_POKEUSER) && HAVE_DECL_PTRACE_POKEUSER)
+  XLAT(PTRACE_POKEUSER),
+#endif
+#if defined(PTRACE_CONT) || (defined(HAVE_DECL_PTRACE_CONT) && HAVE_DECL_PTRACE_CONT)
+  XLAT(PTRACE_CONT),
+#endif
+#if defined(PTRACE_KILL) || (defined(HAVE_DECL_PTRACE_KILL) && HAVE_DECL_PTRACE_KILL)
+  XLAT(PTRACE_KILL),
+#endif
+#if defined(PTRACE_SINGLESTEP) || (defined(HAVE_DECL_PTRACE_SINGLESTEP) && HAVE_DECL_PTRACE_SINGLESTEP)
+  XLAT(PTRACE_SINGLESTEP),
+#endif
+#if defined(PTRACE_ATTACH) || (defined(HAVE_DECL_PTRACE_ATTACH) && HAVE_DECL_PTRACE_ATTACH)
+  XLAT(PTRACE_ATTACH),
+#endif
+#if defined(PTRACE_DETACH) || (defined(HAVE_DECL_PTRACE_DETACH) && HAVE_DECL_PTRACE_DETACH)
+  XLAT(PTRACE_DETACH),
+#endif
+#if defined(PTRACE_SYSCALL) || (defined(HAVE_DECL_PTRACE_SYSCALL) && HAVE_DECL_PTRACE_SYSCALL)
+  XLAT(PTRACE_SYSCALL),
+#endif
+#if defined(PTRACE_GETREGS) || (defined(HAVE_DECL_PTRACE_GETREGS) && HAVE_DECL_PTRACE_GETREGS)
+  XLAT(PTRACE_GETREGS),
+#endif
+#if defined(PTRACE_SETREGS) || (defined(HAVE_DECL_PTRACE_SETREGS) && HAVE_DECL_PTRACE_SETREGS)
+  XLAT(PTRACE_SETREGS),
+#endif
+#if defined(PTRACE_GETFPREGS) || (defined(HAVE_DECL_PTRACE_GETFPREGS) && HAVE_DECL_PTRACE_GETFPREGS)
+  XLAT(PTRACE_GETFPREGS),
+#endif
+#if defined(PTRACE_SETFPREGS) || (defined(HAVE_DECL_PTRACE_SETFPREGS) && HAVE_DECL_PTRACE_SETFPREGS)
+  XLAT(PTRACE_SETFPREGS),
+#endif
+#if defined(PTRACE_GETFPXREGS) || (defined(HAVE_DECL_PTRACE_GETFPXREGS) && HAVE_DECL_PTRACE_GETFPXREGS)
+  XLAT(PTRACE_GETFPXREGS),
+#endif
+#if defined(PTRACE_SETFPXREGS) || (defined(HAVE_DECL_PTRACE_SETFPXREGS) && HAVE_DECL_PTRACE_SETFPXREGS)
+  XLAT(PTRACE_SETFPXREGS),
+#endif
+#if defined(PTRACE_GETVRREGS) || (defined(HAVE_DECL_PTRACE_GETVRREGS) && HAVE_DECL_PTRACE_GETVRREGS)
+  XLAT(PTRACE_GETVRREGS),
+#endif
+#if defined(PTRACE_SETVRREGS) || (defined(HAVE_DECL_PTRACE_SETVRREGS) && HAVE_DECL_PTRACE_SETVRREGS)
+  XLAT(PTRACE_SETVRREGS),
+#endif
+#if defined(PTRACE_SETOPTIONS) || (defined(HAVE_DECL_PTRACE_SETOPTIONS) && HAVE_DECL_PTRACE_SETOPTIONS)
+  XLAT(PTRACE_SETOPTIONS),
+#endif
+#if defined(PTRACE_GETEVENTMSG) || (defined(HAVE_DECL_PTRACE_GETEVENTMSG) && HAVE_DECL_PTRACE_GETEVENTMSG)
+  XLAT(PTRACE_GETEVENTMSG),
+#endif
+#if defined(PTRACE_GETSIGINFO) || (defined(HAVE_DECL_PTRACE_GETSIGINFO) && HAVE_DECL_PTRACE_GETSIGINFO)
+  XLAT(PTRACE_GETSIGINFO),
+#endif
+#if defined(PTRACE_SETSIGINFO) || (defined(HAVE_DECL_PTRACE_SETSIGINFO) && HAVE_DECL_PTRACE_SETSIGINFO)
+  XLAT(PTRACE_SETSIGINFO),
+#endif
+#if defined(PTRACE_GETREGSET) || (defined(HAVE_DECL_PTRACE_GETREGSET) && HAVE_DECL_PTRACE_GETREGSET)
+  XLAT(PTRACE_GETREGSET),
+#endif
+#if defined(PTRACE_SETREGSET) || (defined(HAVE_DECL_PTRACE_SETREGSET) && HAVE_DECL_PTRACE_SETREGSET)
+  XLAT(PTRACE_SETREGSET),
+#endif
+#if defined(PTRACE_SET_SYSCALL) || (defined(HAVE_DECL_PTRACE_SET_SYSCALL) && HAVE_DECL_PTRACE_SET_SYSCALL)
+  XLAT(PTRACE_SET_SYSCALL),
+#endif
+#if defined(PTRACE_SEIZE) || (defined(HAVE_DECL_PTRACE_SEIZE) && HAVE_DECL_PTRACE_SEIZE)
+  XLAT(PTRACE_SEIZE),
+#endif
+#if defined(PTRACE_INTERRUPT) || (defined(HAVE_DECL_PTRACE_INTERRUPT) && HAVE_DECL_PTRACE_INTERRUPT)
+  XLAT(PTRACE_INTERRUPT),
+#endif
+#if defined(PTRACE_LISTEN) || (defined(HAVE_DECL_PTRACE_LISTEN) && HAVE_DECL_PTRACE_LISTEN)
+  XLAT(PTRACE_LISTEN),
+#endif
+#if defined(PTRACE_PEEKSIGINFO) || (defined(HAVE_DECL_PTRACE_PEEKSIGINFO) && HAVE_DECL_PTRACE_PEEKSIGINFO)
+  XLAT(PTRACE_PEEKSIGINFO),
+#endif
+#if defined(PTRACE_GETSIGMASK) || (defined(HAVE_DECL_PTRACE_GETSIGMASK) && HAVE_DECL_PTRACE_GETSIGMASK)
+  XLAT(PTRACE_GETSIGMASK),
+#endif
+#if defined(PTRACE_SETSIGMASK) || (defined(HAVE_DECL_PTRACE_SETSIGMASK) && HAVE_DECL_PTRACE_SETSIGMASK)
+  XLAT(PTRACE_SETSIGMASK),
+#endif
+#if defined(PTRACE_SECCOMP_GET_FILTER) || (defined(HAVE_DECL_PTRACE_SECCOMP_GET_FILTER) && HAVE_DECL_PTRACE_SECCOMP_GET_FILTER)
+  XLAT(PTRACE_SECCOMP_GET_FILTER),
+#endif
+/* arch-specific */
+#if defined(PTRACE_GET_THREAD_AREA) || (defined(HAVE_DECL_PTRACE_GET_THREAD_AREA) && HAVE_DECL_PTRACE_GET_THREAD_AREA)
+  XLAT(PTRACE_GET_THREAD_AREA),
+#endif
+#if defined(PTRACE_SET_THREAD_AREA) || (defined(HAVE_DECL_PTRACE_SET_THREAD_AREA) && HAVE_DECL_PTRACE_SET_THREAD_AREA)
+  XLAT(PTRACE_SET_THREAD_AREA),
+#endif
+#if defined(PTRACE_OLDSETOPTIONS) || (defined(HAVE_DECL_PTRACE_OLDSETOPTIONS) && HAVE_DECL_PTRACE_OLDSETOPTIONS)
+  XLAT(PTRACE_OLDSETOPTIONS),
+#endif
+#if defined(PTRACE_GETFDPIC) || (defined(HAVE_DECL_PTRACE_GETFDPIC) && HAVE_DECL_PTRACE_GETFDPIC)
+  XLAT(PTRACE_GETFDPIC),
+#endif
+#if defined(PTRACE_SINGLEBLOCK) || (defined(HAVE_DECL_PTRACE_SINGLEBLOCK) && HAVE_DECL_PTRACE_SINGLEBLOCK)
+  XLAT(PTRACE_SINGLEBLOCK),
+#endif
+/* arm */
+#if defined(PTRACE_GETWMMXREGS) || (defined(HAVE_DECL_PTRACE_GETWMMXREGS) && HAVE_DECL_PTRACE_GETWMMXREGS)
+  XLAT(PTRACE_GETWMMXREGS),
+#endif
+#if defined(PTRACE_SETWMMXREGS) || (defined(HAVE_DECL_PTRACE_SETWMMXREGS) && HAVE_DECL_PTRACE_SETWMMXREGS)
+  XLAT(PTRACE_SETWMMXREGS),
+#endif
+#if defined(PTRACE_GETCRUNCHREGS) || (defined(HAVE_DECL_PTRACE_GETCRUNCHREGS) && HAVE_DECL_PTRACE_GETCRUNCHREGS)
+  XLAT(PTRACE_GETCRUNCHREGS),
+#endif
+#if defined(PTRACE_SETCRUNCHREGS) || (defined(HAVE_DECL_PTRACE_SETCRUNCHREGS) && HAVE_DECL_PTRACE_SETCRUNCHREGS)
+  XLAT(PTRACE_SETCRUNCHREGS),
+#endif
+#if defined(PTRACE_GETVFPREGS) || (defined(HAVE_DECL_PTRACE_GETVFPREGS) && HAVE_DECL_PTRACE_GETVFPREGS)
+  XLAT(PTRACE_GETVFPREGS),
+#endif
+#if defined(PTRACE_SETVFPREGS) || (defined(HAVE_DECL_PTRACE_SETVFPREGS) && HAVE_DECL_PTRACE_SETVFPREGS)
+  XLAT(PTRACE_SETVFPREGS),
+#endif
+#if defined(PTRACE_GETHBPREGS) || (defined(HAVE_DECL_PTRACE_GETHBPREGS) && HAVE_DECL_PTRACE_GETHBPREGS)
+  XLAT(PTRACE_GETHBPREGS),
+#endif
+#if defined(PTRACE_SETHBPREGS) || (defined(HAVE_DECL_PTRACE_SETHBPREGS) && HAVE_DECL_PTRACE_SETHBPREGS)
+  XLAT(PTRACE_SETHBPREGS),
+#endif
+/* ia64 */
+#if defined(PTRACE_OLD_GETSIGINFO) || (defined(HAVE_DECL_PTRACE_OLD_GETSIGINFO) && HAVE_DECL_PTRACE_OLD_GETSIGINFO)
+  XLAT(PTRACE_OLD_GETSIGINFO),
+#endif
+#if defined(PTRACE_OLD_SETSIGINFO) || (defined(HAVE_DECL_PTRACE_OLD_SETSIGINFO) && HAVE_DECL_PTRACE_OLD_SETSIGINFO)
+  XLAT(PTRACE_OLD_SETSIGINFO),
+#endif
+/* mips */
+#if defined(PTRACE_PEEKTEXT_3264) || (defined(HAVE_DECL_PTRACE_PEEKTEXT_3264) && HAVE_DECL_PTRACE_PEEKTEXT_3264)
+  XLAT(PTRACE_PEEKTEXT_3264),
+#endif
+#if defined(PTRACE_PEEKDATA_3264) || (defined(HAVE_DECL_PTRACE_PEEKDATA_3264) && HAVE_DECL_PTRACE_PEEKDATA_3264)
+  XLAT(PTRACE_PEEKDATA_3264),
+#endif
+#if defined(PTRACE_POKETEXT_3264) || (defined(HAVE_DECL_PTRACE_POKETEXT_3264) && HAVE_DECL_PTRACE_POKETEXT_3264)
+  XLAT(PTRACE_POKETEXT_3264),
+#endif
+#if defined(PTRACE_POKEDATA_3264) || (defined(HAVE_DECL_PTRACE_POKEDATA_3264) && HAVE_DECL_PTRACE_POKEDATA_3264)
+  XLAT(PTRACE_POKEDATA_3264),
+#endif
+#if defined(PTRACE_GET_THREAD_AREA_3264) || (defined(HAVE_DECL_PTRACE_GET_THREAD_AREA_3264) && HAVE_DECL_PTRACE_GET_THREAD_AREA_3264)
+  XLAT(PTRACE_GET_THREAD_AREA_3264),
+#endif
+#if defined(PTRACE_GET_WATCH_REGS) || (defined(HAVE_DECL_PTRACE_GET_WATCH_REGS) && HAVE_DECL_PTRACE_GET_WATCH_REGS)
+  XLAT(PTRACE_GET_WATCH_REGS),
+#endif
+#if defined(PTRACE_SET_WATCH_REGS) || (defined(HAVE_DECL_PTRACE_SET_WATCH_REGS) && HAVE_DECL_PTRACE_SET_WATCH_REGS)
+  XLAT(PTRACE_SET_WATCH_REGS),
+#endif
+/* powerpc */
+#if defined(PTRACE_GETEVRREGS) || (defined(HAVE_DECL_PTRACE_GETEVRREGS) && HAVE_DECL_PTRACE_GETEVRREGS)
+  XLAT(PTRACE_GETEVRREGS),
+#endif
+#if defined(PTRACE_SETEVRREGS) || (defined(HAVE_DECL_PTRACE_SETEVRREGS) && HAVE_DECL_PTRACE_SETEVRREGS)
+  XLAT(PTRACE_SETEVRREGS),
+#endif
+#if defined(PTRACE_GETVSRREGS) || (defined(HAVE_DECL_PTRACE_GETVSRREGS) && HAVE_DECL_PTRACE_GETVSRREGS)
+  XLAT(PTRACE_GETVSRREGS),
+#endif
+#if defined(PTRACE_SETVSRREGS) || (defined(HAVE_DECL_PTRACE_SETVSRREGS) && HAVE_DECL_PTRACE_SETVSRREGS)
+  XLAT(PTRACE_SETVSRREGS),
+#endif
+#if defined(PTRACE_GET_DEBUGREG) || (defined(HAVE_DECL_PTRACE_GET_DEBUGREG) && HAVE_DECL_PTRACE_GET_DEBUGREG)
+  XLAT(PTRACE_GET_DEBUGREG),
+#endif
+#if defined(PTRACE_SET_DEBUGREG) || (defined(HAVE_DECL_PTRACE_SET_DEBUGREG) && HAVE_DECL_PTRACE_SET_DEBUGREG)
+  XLAT(PTRACE_SET_DEBUGREG),
+#endif
+#if defined(PPC_PTRACE_GETHWDBGINFO) || (defined(HAVE_DECL_PPC_PTRACE_GETHWDBGINFO) && HAVE_DECL_PPC_PTRACE_GETHWDBGINFO)
+  XLAT(PPC_PTRACE_GETHWDBGINFO),
+#endif
+#if defined(PPC_PTRACE_SETHWDEBUG) || (defined(HAVE_DECL_PPC_PTRACE_SETHWDEBUG) && HAVE_DECL_PPC_PTRACE_SETHWDEBUG)
+  XLAT(PPC_PTRACE_SETHWDEBUG),
+#endif
+#if defined(PPC_PTRACE_DELHWDEBUG) || (defined(HAVE_DECL_PPC_PTRACE_DELHWDEBUG) && HAVE_DECL_PPC_PTRACE_DELHWDEBUG)
+  XLAT(PPC_PTRACE_DELHWDEBUG),
+#endif
+/* s390 */
+#if defined(PTRACE_PEEKUSR_AREA) || (defined(HAVE_DECL_PTRACE_PEEKUSR_AREA) && HAVE_DECL_PTRACE_PEEKUSR_AREA)
+  XLAT(PTRACE_PEEKUSR_AREA),
+#endif
+#if defined(PTRACE_POKEUSR_AREA) || (defined(HAVE_DECL_PTRACE_POKEUSR_AREA) && HAVE_DECL_PTRACE_POKEUSR_AREA)
+  XLAT(PTRACE_POKEUSR_AREA),
+#endif
+#if defined(PTRACE_PEEKTEXT_AREA) || (defined(HAVE_DECL_PTRACE_PEEKTEXT_AREA) && HAVE_DECL_PTRACE_PEEKTEXT_AREA)
+  XLAT(PTRACE_PEEKTEXT_AREA),
+#endif
+#if defined(PTRACE_PEEKDATA_AREA) || (defined(HAVE_DECL_PTRACE_PEEKDATA_AREA) && HAVE_DECL_PTRACE_PEEKDATA_AREA)
+  XLAT(PTRACE_PEEKDATA_AREA),
+#endif
+#if defined(PTRACE_POKETEXT_AREA) || (defined(HAVE_DECL_PTRACE_POKETEXT_AREA) && HAVE_DECL_PTRACE_POKETEXT_AREA)
+  XLAT(PTRACE_POKETEXT_AREA),
+#endif
+#if defined(PTRACE_POKEDATA_AREA) || (defined(HAVE_DECL_PTRACE_POKEDATA_AREA) && HAVE_DECL_PTRACE_POKEDATA_AREA)
+  XLAT(PTRACE_POKEDATA_AREA),
+#endif
+#if defined(PTRACE_GET_LAST_BREAK) || (defined(HAVE_DECL_PTRACE_GET_LAST_BREAK) && HAVE_DECL_PTRACE_GET_LAST_BREAK)
+  XLAT(PTRACE_GET_LAST_BREAK),
+#endif
+#if defined(PTRACE_PEEK_SYSTEM_CALL) || (defined(HAVE_DECL_PTRACE_PEEK_SYSTEM_CALL) && HAVE_DECL_PTRACE_PEEK_SYSTEM_CALL)
+  XLAT(PTRACE_PEEK_SYSTEM_CALL),
+#endif
+#if defined(PTRACE_POKE_SYSTEM_CALL) || (defined(HAVE_DECL_PTRACE_POKE_SYSTEM_CALL) && HAVE_DECL_PTRACE_POKE_SYSTEM_CALL)
+  XLAT(PTRACE_POKE_SYSTEM_CALL),
+#endif
+#if defined(PTRACE_ENABLE_TE) || (defined(HAVE_DECL_PTRACE_ENABLE_TE) && HAVE_DECL_PTRACE_ENABLE_TE)
+  XLAT(PTRACE_ENABLE_TE),
+#endif
+#if defined(PTRACE_DISABLE_TE) || (defined(HAVE_DECL_PTRACE_DISABLE_TE) && HAVE_DECL_PTRACE_DISABLE_TE)
+  XLAT(PTRACE_DISABLE_TE),
+#endif
+#if defined(PTRACE_TE_ABORT_RAND) || (defined(HAVE_DECL_PTRACE_TE_ABORT_RAND) && HAVE_DECL_PTRACE_TE_ABORT_RAND)
+  XLAT(PTRACE_TE_ABORT_RAND),
+#endif
+/* sh */
+#if defined(PTRACE_GETDSPREGS) || (defined(HAVE_DECL_PTRACE_GETDSPREGS) && HAVE_DECL_PTRACE_GETDSPREGS)
+  XLAT(PTRACE_GETDSPREGS),
+#endif
+#if defined(PTRACE_SETDSPREGS) || (defined(HAVE_DECL_PTRACE_SETDSPREGS) && HAVE_DECL_PTRACE_SETDSPREGS)
+  XLAT(PTRACE_SETDSPREGS),
+#endif
+/* sparc */
+#if defined(PTRACE_SPARC_DETACH) || (defined(HAVE_DECL_PTRACE_SPARC_DETACH) && HAVE_DECL_PTRACE_SPARC_DETACH)
+  XLAT(PTRACE_SPARC_DETACH),
+#endif
+#if defined(PTRACE_READDATA) || (defined(HAVE_DECL_PTRACE_READDATA) && HAVE_DECL_PTRACE_READDATA)
+  XLAT(PTRACE_READDATA),
+#endif
+#if defined(PTRACE_WRITEDATA) || (defined(HAVE_DECL_PTRACE_WRITEDATA) && HAVE_DECL_PTRACE_WRITEDATA)
+  XLAT(PTRACE_WRITEDATA),
+#endif
+#if defined(PTRACE_READTEXT) || (defined(HAVE_DECL_PTRACE_READTEXT) && HAVE_DECL_PTRACE_READTEXT)
+  XLAT(PTRACE_READTEXT),
+#endif
+#if defined(PTRACE_WRITETEXT) || (defined(HAVE_DECL_PTRACE_WRITETEXT) && HAVE_DECL_PTRACE_WRITETEXT)
+  XLAT(PTRACE_WRITETEXT),
+#endif
+#if defined(PTRACE_GETFPAREGS) || (defined(HAVE_DECL_PTRACE_GETFPAREGS) && HAVE_DECL_PTRACE_GETFPAREGS)
+  XLAT(PTRACE_GETFPAREGS),
+#endif
+#if defined(PTRACE_SETFPAREGS) || (defined(HAVE_DECL_PTRACE_SETFPAREGS) && HAVE_DECL_PTRACE_SETFPAREGS)
+  XLAT(PTRACE_SETFPAREGS),
+#endif
+/* x86 */
+#if defined(PTRACE_ARCH_PRCTL) || (defined(HAVE_DECL_PTRACE_ARCH_PRCTL) && HAVE_DECL_PTRACE_ARCH_PRCTL)
+  XLAT(PTRACE_ARCH_PRCTL),
+#endif
+#if defined(PTRACE_SYSEMU) || (defined(HAVE_DECL_PTRACE_SYSEMU) && HAVE_DECL_PTRACE_SYSEMU)
+  XLAT(PTRACE_SYSEMU),
+#endif
+#if defined(PTRACE_SYSEMU_SINGLESTEP) || (defined(HAVE_DECL_PTRACE_SYSEMU_SINGLESTEP) && HAVE_DECL_PTRACE_SYSEMU_SINGLESTEP)
+  XLAT(PTRACE_SYSEMU_SINGLESTEP),
+#endif
+/* xtensa */
+#if defined(PTRACE_GETXTREGS) || (defined(HAVE_DECL_PTRACE_GETXTREGS) && HAVE_DECL_PTRACE_GETXTREGS)
+  XLAT(PTRACE_GETXTREGS),
+#endif
+#if defined(PTRACE_SETXTREGS) || (defined(HAVE_DECL_PTRACE_SETXTREGS) && HAVE_DECL_PTRACE_SETXTREGS)
+  XLAT(PTRACE_SETXTREGS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ptrace_cmds.in b/strace/xlat/ptrace_cmds.in
new file mode 100644
index 0000000..5e4da83
--- /dev/null
+++ b/strace/xlat/ptrace_cmds.in
@@ -0,0 +1,102 @@
+PTRACE_TRACEME
+PTRACE_PEEKTEXT
+PTRACE_PEEKDATA
+PTRACE_PEEKUSER
+PTRACE_POKETEXT
+PTRACE_POKEDATA
+PTRACE_POKEUSER
+PTRACE_CONT
+PTRACE_KILL
+PTRACE_SINGLESTEP
+PTRACE_ATTACH
+PTRACE_DETACH
+PTRACE_SYSCALL
+PTRACE_GETREGS
+PTRACE_SETREGS
+PTRACE_GETFPREGS
+PTRACE_SETFPREGS
+PTRACE_GETFPXREGS
+PTRACE_SETFPXREGS
+PTRACE_GETVRREGS
+PTRACE_SETVRREGS
+PTRACE_SETOPTIONS
+PTRACE_GETEVENTMSG
+PTRACE_GETSIGINFO
+PTRACE_SETSIGINFO
+PTRACE_GETREGSET
+PTRACE_SETREGSET
+PTRACE_SET_SYSCALL
+PTRACE_SEIZE
+PTRACE_INTERRUPT
+PTRACE_LISTEN
+PTRACE_PEEKSIGINFO
+PTRACE_GETSIGMASK
+PTRACE_SETSIGMASK
+PTRACE_SECCOMP_GET_FILTER
+/* arch-specific */
+PTRACE_GET_THREAD_AREA
+PTRACE_SET_THREAD_AREA
+PTRACE_OLDSETOPTIONS
+PTRACE_GETFDPIC
+PTRACE_SINGLEBLOCK
+/* arm */
+PTRACE_GETWMMXREGS
+PTRACE_SETWMMXREGS
+PTRACE_GETCRUNCHREGS
+PTRACE_SETCRUNCHREGS
+PTRACE_GETVFPREGS
+PTRACE_SETVFPREGS
+PTRACE_GETHBPREGS
+PTRACE_SETHBPREGS
+/* ia64 */
+PTRACE_OLD_GETSIGINFO
+PTRACE_OLD_SETSIGINFO
+/* mips */
+PTRACE_PEEKTEXT_3264
+PTRACE_PEEKDATA_3264
+PTRACE_POKETEXT_3264
+PTRACE_POKEDATA_3264
+PTRACE_GET_THREAD_AREA_3264
+PTRACE_GET_WATCH_REGS
+PTRACE_SET_WATCH_REGS
+/* powerpc */
+PTRACE_GETEVRREGS
+PTRACE_SETEVRREGS
+PTRACE_GETVSRREGS
+PTRACE_SETVSRREGS
+PTRACE_GET_DEBUGREG
+PTRACE_SET_DEBUGREG
+PPC_PTRACE_GETHWDBGINFO
+PPC_PTRACE_SETHWDEBUG
+PPC_PTRACE_DELHWDEBUG
+/* s390 */
+PTRACE_PEEKUSR_AREA
+PTRACE_POKEUSR_AREA
+PTRACE_PEEKTEXT_AREA
+PTRACE_PEEKDATA_AREA
+PTRACE_POKETEXT_AREA
+PTRACE_POKEDATA_AREA
+PTRACE_GET_LAST_BREAK
+PTRACE_PEEK_SYSTEM_CALL
+PTRACE_POKE_SYSTEM_CALL
+PTRACE_ENABLE_TE
+PTRACE_DISABLE_TE
+PTRACE_TE_ABORT_RAND
+/* sh */
+PTRACE_GETDSPREGS
+PTRACE_SETDSPREGS
+/* sparc */
+PTRACE_SPARC_DETACH
+PTRACE_READDATA
+PTRACE_WRITEDATA
+PTRACE_READTEXT
+PTRACE_WRITETEXT
+PTRACE_GETFPAREGS
+PTRACE_SETFPAREGS
+/* x86 */
+PTRACE_ARCH_PRCTL
+PTRACE_SYSEMU
+PTRACE_SYSEMU_SINGLESTEP
+/* xtensa */
+PTRACE_GETXTREGS
+PTRACE_SETXTREGS
diff --git a/strace/xlat/ptrace_events.h b/strace/xlat/ptrace_events.h
new file mode 100644
index 0000000..a466f10
--- /dev/null
+++ b/strace/xlat/ptrace_events.h
@@ -0,0 +1,42 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ptrace_events.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ptrace_events in mpers mode
+
+#else
+
+static
+const struct xlat ptrace_events[] = {
+#if defined(PTRACE_EVENT_FORK) || (defined(HAVE_DECL_PTRACE_EVENT_FORK) && HAVE_DECL_PTRACE_EVENT_FORK)
+  XLAT(PTRACE_EVENT_FORK),
+#endif
+#if defined(PTRACE_EVENT_VFORK) || (defined(HAVE_DECL_PTRACE_EVENT_VFORK) && HAVE_DECL_PTRACE_EVENT_VFORK)
+  XLAT(PTRACE_EVENT_VFORK),
+#endif
+#if defined(PTRACE_EVENT_CLONE) || (defined(HAVE_DECL_PTRACE_EVENT_CLONE) && HAVE_DECL_PTRACE_EVENT_CLONE)
+  XLAT(PTRACE_EVENT_CLONE),
+#endif
+#if defined(PTRACE_EVENT_EXEC) || (defined(HAVE_DECL_PTRACE_EVENT_EXEC) && HAVE_DECL_PTRACE_EVENT_EXEC)
+  XLAT(PTRACE_EVENT_EXEC),
+#endif
+#if defined(PTRACE_EVENT_VFORK_DONE) || (defined(HAVE_DECL_PTRACE_EVENT_VFORK_DONE) && HAVE_DECL_PTRACE_EVENT_VFORK_DONE)
+  XLAT(PTRACE_EVENT_VFORK_DONE),
+#endif
+#if defined(PTRACE_EVENT_EXIT) || (defined(HAVE_DECL_PTRACE_EVENT_EXIT) && HAVE_DECL_PTRACE_EVENT_EXIT)
+  XLAT(PTRACE_EVENT_EXIT),
+#endif
+#if defined(PTRACE_EVENT_SECCOMP) || (defined(HAVE_DECL_PTRACE_EVENT_SECCOMP) && HAVE_DECL_PTRACE_EVENT_SECCOMP)
+  XLAT(PTRACE_EVENT_SECCOMP),
+#endif
+#if defined(PTRACE_EVENT_STOP) || (defined(HAVE_DECL_PTRACE_EVENT_STOP) && HAVE_DECL_PTRACE_EVENT_STOP)
+  XLAT(PTRACE_EVENT_STOP),
+#endif
+/* tile */
+#if defined(PTRACE_EVENT_MIGRATE) || (defined(HAVE_DECL_PTRACE_EVENT_MIGRATE) && HAVE_DECL_PTRACE_EVENT_MIGRATE)
+  XLAT(PTRACE_EVENT_MIGRATE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ptrace_events.in b/strace/xlat/ptrace_events.in
new file mode 100644
index 0000000..a772e3c
--- /dev/null
+++ b/strace/xlat/ptrace_events.in
@@ -0,0 +1,10 @@
+PTRACE_EVENT_FORK
+PTRACE_EVENT_VFORK
+PTRACE_EVENT_CLONE
+PTRACE_EVENT_EXEC
+PTRACE_EVENT_VFORK_DONE
+PTRACE_EVENT_EXIT
+PTRACE_EVENT_SECCOMP
+PTRACE_EVENT_STOP
+/* tile */
+PTRACE_EVENT_MIGRATE
diff --git a/strace/xlat/ptrace_peeksiginfo_flags.h b/strace/xlat/ptrace_peeksiginfo_flags.h
new file mode 100644
index 0000000..c6152b7
--- /dev/null
+++ b/strace/xlat/ptrace_peeksiginfo_flags.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ptrace_peeksiginfo_flags.in; do not edit. */
+#if !(defined(PTRACE_PEEKSIGINFO_SHARED) || (defined(HAVE_DECL_PTRACE_PEEKSIGINFO_SHARED) && HAVE_DECL_PTRACE_PEEKSIGINFO_SHARED))
+# define PTRACE_PEEKSIGINFO_SHARED 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ptrace_peeksiginfo_flags in mpers mode
+
+#else
+
+static
+const struct xlat ptrace_peeksiginfo_flags[] = {
+ XLAT(PTRACE_PEEKSIGINFO_SHARED),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ptrace_peeksiginfo_flags.in b/strace/xlat/ptrace_peeksiginfo_flags.in
new file mode 100644
index 0000000..28a4c22
--- /dev/null
+++ b/strace/xlat/ptrace_peeksiginfo_flags.in
@@ -0,0 +1 @@
+PTRACE_PEEKSIGINFO_SHARED 1
diff --git a/strace/xlat/ptrace_setoptions_flags.h b/strace/xlat/ptrace_setoptions_flags.h
new file mode 100644
index 0000000..4eaca06
--- /dev/null
+++ b/strace/xlat/ptrace_setoptions_flags.h
@@ -0,0 +1,48 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ptrace_setoptions_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ptrace_setoptions_flags in mpers mode
+
+#else
+
+static
+const struct xlat ptrace_setoptions_flags[] = {
+#if defined(PTRACE_O_TRACESYSGOOD) || (defined(HAVE_DECL_PTRACE_O_TRACESYSGOOD) && HAVE_DECL_PTRACE_O_TRACESYSGOOD)
+  XLAT(PTRACE_O_TRACESYSGOOD),
+#endif
+#if defined(PTRACE_O_TRACEFORK) || (defined(HAVE_DECL_PTRACE_O_TRACEFORK) && HAVE_DECL_PTRACE_O_TRACEFORK)
+  XLAT(PTRACE_O_TRACEFORK),
+#endif
+#if defined(PTRACE_O_TRACEVFORK) || (defined(HAVE_DECL_PTRACE_O_TRACEVFORK) && HAVE_DECL_PTRACE_O_TRACEVFORK)
+  XLAT(PTRACE_O_TRACEVFORK),
+#endif
+#if defined(PTRACE_O_TRACECLONE) || (defined(HAVE_DECL_PTRACE_O_TRACECLONE) && HAVE_DECL_PTRACE_O_TRACECLONE)
+  XLAT(PTRACE_O_TRACECLONE),
+#endif
+#if defined(PTRACE_O_TRACEEXEC) || (defined(HAVE_DECL_PTRACE_O_TRACEEXEC) && HAVE_DECL_PTRACE_O_TRACEEXEC)
+  XLAT(PTRACE_O_TRACEEXEC),
+#endif
+#if defined(PTRACE_O_TRACEVFORKDONE) || (defined(HAVE_DECL_PTRACE_O_TRACEVFORKDONE) && HAVE_DECL_PTRACE_O_TRACEVFORKDONE)
+  XLAT(PTRACE_O_TRACEVFORKDONE),
+#endif
+#if defined(PTRACE_O_TRACEEXIT) || (defined(HAVE_DECL_PTRACE_O_TRACEEXIT) && HAVE_DECL_PTRACE_O_TRACEEXIT)
+  XLAT(PTRACE_O_TRACEEXIT),
+#endif
+#if defined(PTRACE_O_TRACESECCOMP) || (defined(HAVE_DECL_PTRACE_O_TRACESECCOMP) && HAVE_DECL_PTRACE_O_TRACESECCOMP)
+  XLAT(PTRACE_O_TRACESECCOMP),
+#endif
+#if defined(PTRACE_O_EXITKILL) || (defined(HAVE_DECL_PTRACE_O_EXITKILL) && HAVE_DECL_PTRACE_O_EXITKILL)
+  XLAT(PTRACE_O_EXITKILL),
+#endif
+#if defined(PTRACE_O_SUSPEND_SECCOMP) || (defined(HAVE_DECL_PTRACE_O_SUSPEND_SECCOMP) && HAVE_DECL_PTRACE_O_SUSPEND_SECCOMP)
+  XLAT(PTRACE_O_SUSPEND_SECCOMP),
+#endif
+/* tile */
+#if defined(PTRACE_O_TRACEMIGRATE) || (defined(HAVE_DECL_PTRACE_O_TRACEMIGRATE) && HAVE_DECL_PTRACE_O_TRACEMIGRATE)
+  XLAT(PTRACE_O_TRACEMIGRATE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ptrace_setoptions_flags.in b/strace/xlat/ptrace_setoptions_flags.in
new file mode 100644
index 0000000..8610c86
--- /dev/null
+++ b/strace/xlat/ptrace_setoptions_flags.in
@@ -0,0 +1,12 @@
+PTRACE_O_TRACESYSGOOD
+PTRACE_O_TRACEFORK
+PTRACE_O_TRACEVFORK
+PTRACE_O_TRACECLONE
+PTRACE_O_TRACEEXEC
+PTRACE_O_TRACEVFORKDONE
+PTRACE_O_TRACEEXIT
+PTRACE_O_TRACESECCOMP
+PTRACE_O_EXITKILL
+PTRACE_O_SUSPEND_SECCOMP
+/* tile */
+PTRACE_O_TRACEMIGRATE
diff --git a/strace/xlat/qm_which.h b/strace/xlat/qm_which.h
new file mode 100644
index 0000000..5012736
--- /dev/null
+++ b/strace/xlat/qm_which.h
@@ -0,0 +1,21 @@
+/* Generated by ./xlat/gen.sh from ./xlat/qm_which.in; do not edit. */
+
+static const struct xlat qm_which[] = {
+ XLAT(0),
+#if defined(QM_MODULES) || (defined(HAVE_DECL_QM_MODULES) && HAVE_DECL_QM_MODULES)
+ XLAT(QM_MODULES),
+#endif
+#if defined(QM_DEPS) || (defined(HAVE_DECL_QM_DEPS) && HAVE_DECL_QM_DEPS)
+ XLAT(QM_DEPS),
+#endif
+#if defined(QM_REFS) || (defined(HAVE_DECL_QM_REFS) && HAVE_DECL_QM_REFS)
+ XLAT(QM_REFS),
+#endif
+#if defined(QM_SYMBOLS) || (defined(HAVE_DECL_QM_SYMBOLS) && HAVE_DECL_QM_SYMBOLS)
+ XLAT(QM_SYMBOLS),
+#endif
+#if defined(QM_INFO) || (defined(HAVE_DECL_QM_INFO) && HAVE_DECL_QM_INFO)
+ XLAT(QM_INFO),
+#endif
+ XLAT_END
+};
diff --git a/strace/xlat/quota_formats.h b/strace/xlat/quota_formats.h
new file mode 100644
index 0000000..37f4027
--- /dev/null
+++ b/strace/xlat/quota_formats.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/quota_formats.in; do not edit. */
+#if !(defined(QFMT_VFS_OLD) || (defined(HAVE_DECL_QFMT_VFS_OLD) && HAVE_DECL_QFMT_VFS_OLD))
+# define QFMT_VFS_OLD 1
+#endif
+#if !(defined(QFMT_VFS_V0) || (defined(HAVE_DECL_QFMT_VFS_V0) && HAVE_DECL_QFMT_VFS_V0))
+# define QFMT_VFS_V0 2
+#endif
+#if !(defined(QFMT_OCFS2) || (defined(HAVE_DECL_QFMT_OCFS2) && HAVE_DECL_QFMT_OCFS2))
+# define QFMT_OCFS2 3
+#endif
+#if !(defined(QFMT_VFS_V1) || (defined(HAVE_DECL_QFMT_VFS_V1) && HAVE_DECL_QFMT_VFS_V1))
+# define QFMT_VFS_V1 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat quota_formats in mpers mode
+
+#else
+
+static
+const struct xlat quota_formats[] = {
+ XLAT(QFMT_VFS_OLD),
+ XLAT(QFMT_VFS_V0),
+ XLAT(QFMT_OCFS2),
+ XLAT(QFMT_VFS_V1),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/quota_formats.in b/strace/xlat/quota_formats.in
new file mode 100644
index 0000000..dcbbb61
--- /dev/null
+++ b/strace/xlat/quota_formats.in
@@ -0,0 +1,4 @@
+QFMT_VFS_OLD	1
+QFMT_VFS_V0	2
+QFMT_OCFS2	3
+QFMT_VFS_V1	4
diff --git a/strace/xlat/quotacmds.h b/strace/xlat/quotacmds.h
new file mode 100644
index 0000000..675cde9
--- /dev/null
+++ b/strace/xlat/quotacmds.h
@@ -0,0 +1,157 @@
+/* Generated by ./xlat/gen.sh from ./xlat/quotacmds.in; do not edit. */
+#if !(defined(Q_V1_QUOTAON) || (defined(HAVE_DECL_Q_V1_QUOTAON) && HAVE_DECL_Q_V1_QUOTAON))
+# define Q_V1_QUOTAON OLD_CMD(0x1)
+#endif
+#if !(defined(Q_V1_QUOTAOFF) || (defined(HAVE_DECL_Q_V1_QUOTAOFF) && HAVE_DECL_Q_V1_QUOTAOFF))
+# define Q_V1_QUOTAOFF OLD_CMD(0x2)
+#endif
+#if !(defined(Q_V1_GETQUOTA) || (defined(HAVE_DECL_Q_V1_GETQUOTA) && HAVE_DECL_Q_V1_GETQUOTA))
+# define Q_V1_GETQUOTA OLD_CMD(0x3)
+#endif
+#if !(defined(Q_V1_SETQUOTA) || (defined(HAVE_DECL_Q_V1_SETQUOTA) && HAVE_DECL_Q_V1_SETQUOTA))
+# define Q_V1_SETQUOTA OLD_CMD(0x4)
+#endif
+#if !(defined(Q_V1_SETUSE) || (defined(HAVE_DECL_Q_V1_SETUSE) && HAVE_DECL_Q_V1_SETUSE))
+# define Q_V1_SETUSE OLD_CMD(0x5)
+#endif
+#if !(defined(Q_V1_SYNC) || (defined(HAVE_DECL_Q_V1_SYNC) && HAVE_DECL_Q_V1_SYNC))
+# define Q_V1_SYNC OLD_CMD(0x6)
+#endif
+#if !(defined(Q_SETQLIM) || (defined(HAVE_DECL_Q_SETQLIM) && HAVE_DECL_Q_SETQLIM))
+# define Q_SETQLIM OLD_CMD(0x7)
+#endif
+#if !(defined(Q_V1_GETSTATS) || (defined(HAVE_DECL_Q_V1_GETSTATS) && HAVE_DECL_Q_V1_GETSTATS))
+# define Q_V1_GETSTATS OLD_CMD(0x8)
+#endif
+#if !(defined(Q_V1_RSQUASH) || (defined(HAVE_DECL_Q_V1_RSQUASH) && HAVE_DECL_Q_V1_RSQUASH))
+# define Q_V1_RSQUASH OLD_CMD(0x10)
+#endif
+#if !(defined(Q_V2_GETQUOTA) || (defined(HAVE_DECL_Q_V2_GETQUOTA) && HAVE_DECL_Q_V2_GETQUOTA))
+# define Q_V2_GETQUOTA OLD_CMD(0xD)
+#endif
+#if !(defined(Q_V2_SETQUOTA) || (defined(HAVE_DECL_Q_V2_SETQUOTA) && HAVE_DECL_Q_V2_SETQUOTA))
+# define Q_V2_SETQUOTA OLD_CMD(0xE)
+#endif
+#if !(defined(Q_V2_SETUSE) || (defined(HAVE_DECL_Q_V2_SETUSE) && HAVE_DECL_Q_V2_SETUSE))
+# define Q_V2_SETUSE OLD_CMD(0xF)
+#endif
+#if !(defined(Q_V2_GETINFO) || (defined(HAVE_DECL_Q_V2_GETINFO) && HAVE_DECL_Q_V2_GETINFO))
+# define Q_V2_GETINFO OLD_CMD(0x9)
+#endif
+#if !(defined(Q_V2_SETINFO) || (defined(HAVE_DECL_Q_V2_SETINFO) && HAVE_DECL_Q_V2_SETINFO))
+# define Q_V2_SETINFO OLD_CMD(0xA)
+#endif
+#if !(defined(Q_V2_SETGRACE) || (defined(HAVE_DECL_Q_V2_SETGRACE) && HAVE_DECL_Q_V2_SETGRACE))
+# define Q_V2_SETGRACE OLD_CMD(0xB)
+#endif
+#if !(defined(Q_V2_SETFLAGS) || (defined(HAVE_DECL_Q_V2_SETFLAGS) && HAVE_DECL_Q_V2_SETFLAGS))
+# define Q_V2_SETFLAGS OLD_CMD(0xC)
+#endif
+#if !(defined(Q_V2_GETSTATS) || (defined(HAVE_DECL_Q_V2_GETSTATS) && HAVE_DECL_Q_V2_GETSTATS))
+# define Q_V2_GETSTATS OLD_CMD(0x11)
+#endif
+#if !(defined(Q_SYNC) || (defined(HAVE_DECL_Q_SYNC) && HAVE_DECL_Q_SYNC))
+# define Q_SYNC NEW_CMD(0x1)
+#endif
+#if !(defined(Q_QUOTAON) || (defined(HAVE_DECL_Q_QUOTAON) && HAVE_DECL_Q_QUOTAON))
+# define Q_QUOTAON NEW_CMD(0x2)
+#endif
+#if !(defined(Q_QUOTAOFF) || (defined(HAVE_DECL_Q_QUOTAOFF) && HAVE_DECL_Q_QUOTAOFF))
+# define Q_QUOTAOFF NEW_CMD(0x3)
+#endif
+#if !(defined(Q_GETFMT) || (defined(HAVE_DECL_Q_GETFMT) && HAVE_DECL_Q_GETFMT))
+# define Q_GETFMT NEW_CMD(0x4)
+#endif
+#if !(defined(Q_GETINFO) || (defined(HAVE_DECL_Q_GETINFO) && HAVE_DECL_Q_GETINFO))
+# define Q_GETINFO NEW_CMD(0x5)
+#endif
+#if !(defined(Q_SETINFO) || (defined(HAVE_DECL_Q_SETINFO) && HAVE_DECL_Q_SETINFO))
+# define Q_SETINFO NEW_CMD(0x6)
+#endif
+#if !(defined(Q_GETQUOTA) || (defined(HAVE_DECL_Q_GETQUOTA) && HAVE_DECL_Q_GETQUOTA))
+# define Q_GETQUOTA NEW_CMD(0x7)
+#endif
+#if !(defined(Q_SETQUOTA) || (defined(HAVE_DECL_Q_SETQUOTA) && HAVE_DECL_Q_SETQUOTA))
+# define Q_SETQUOTA NEW_CMD(0x8)
+#endif
+#if !(defined(Q_GETNEXTQUOTA) || (defined(HAVE_DECL_Q_GETNEXTQUOTA) && HAVE_DECL_Q_GETNEXTQUOTA))
+# define Q_GETNEXTQUOTA NEW_CMD(0x9)
+#endif
+#if !(defined(Q_XQUOTAON) || (defined(HAVE_DECL_Q_XQUOTAON) && HAVE_DECL_Q_XQUOTAON))
+# define Q_XQUOTAON XQM_CMD(0x1)
+#endif
+#if !(defined(Q_XQUOTAOFF) || (defined(HAVE_DECL_Q_XQUOTAOFF) && HAVE_DECL_Q_XQUOTAOFF))
+# define Q_XQUOTAOFF XQM_CMD(0x2)
+#endif
+#if !(defined(Q_XGETQUOTA) || (defined(HAVE_DECL_Q_XGETQUOTA) && HAVE_DECL_Q_XGETQUOTA))
+# define Q_XGETQUOTA XQM_CMD(0x3)
+#endif
+#if !(defined(Q_XSETQLIM) || (defined(HAVE_DECL_Q_XSETQLIM) && HAVE_DECL_Q_XSETQLIM))
+# define Q_XSETQLIM XQM_CMD(0x4)
+#endif
+#if !(defined(Q_XGETQSTAT) || (defined(HAVE_DECL_Q_XGETQSTAT) && HAVE_DECL_Q_XGETQSTAT))
+# define Q_XGETQSTAT XQM_CMD(0x5)
+#endif
+#if !(defined(Q_XQUOTARM) || (defined(HAVE_DECL_Q_XQUOTARM) && HAVE_DECL_Q_XQUOTARM))
+# define Q_XQUOTARM XQM_CMD(0x6)
+#endif
+#if !(defined(Q_XQUOTASYNC) || (defined(HAVE_DECL_Q_XQUOTASYNC) && HAVE_DECL_Q_XQUOTASYNC))
+# define Q_XQUOTASYNC XQM_CMD(0x7)
+#endif
+#if !(defined(Q_XGETQSTATV) || (defined(HAVE_DECL_Q_XGETQSTATV) && HAVE_DECL_Q_XGETQSTATV))
+# define Q_XGETQSTATV XQM_CMD(0x8)
+#endif
+#if !(defined(Q_XGETNEXTQUOTA) || (defined(HAVE_DECL_Q_XGETNEXTQUOTA) && HAVE_DECL_Q_XGETNEXTQUOTA))
+# define Q_XGETNEXTQUOTA XQM_CMD(0x9)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat quotacmds in mpers mode
+
+#else
+
+static
+const struct xlat quotacmds[] = {
+ XLAT(Q_V1_QUOTAON),
+ XLAT(Q_V1_QUOTAOFF),
+ XLAT(Q_V1_GETQUOTA),
+ XLAT(Q_V1_SETQUOTA),
+ XLAT(Q_V1_SETUSE),
+ XLAT(Q_V1_SYNC),
+ XLAT(Q_SETQLIM),
+ XLAT(Q_V1_GETSTATS),
+ XLAT(Q_V1_RSQUASH),
+
+ XLAT(Q_V2_GETQUOTA),
+ XLAT(Q_V2_SETQUOTA),
+ XLAT(Q_V2_SETUSE),
+ XLAT(Q_V2_GETINFO),
+ XLAT(Q_V2_SETINFO),
+ XLAT(Q_V2_SETGRACE),
+ XLAT(Q_V2_SETFLAGS),
+ XLAT(Q_V2_GETSTATS),
+
+ XLAT(Q_SYNC),
+ XLAT(Q_QUOTAON),
+ XLAT(Q_QUOTAOFF),
+ XLAT(Q_GETFMT),
+ XLAT(Q_GETINFO),
+ XLAT(Q_SETINFO),
+ XLAT(Q_GETQUOTA),
+ XLAT(Q_SETQUOTA),
+ XLAT(Q_GETNEXTQUOTA),
+
+ XLAT(Q_XQUOTAON),
+ XLAT(Q_XQUOTAOFF),
+ XLAT(Q_XGETQUOTA),
+ XLAT(Q_XSETQLIM),
+ XLAT(Q_XGETQSTAT),
+ XLAT(Q_XQUOTARM),
+ XLAT(Q_XQUOTASYNC),
+ XLAT(Q_XGETQSTATV),
+ XLAT(Q_XGETNEXTQUOTA),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/quotacmds.in b/strace/xlat/quotacmds.in
new file mode 100644
index 0000000..5ff1993
--- /dev/null
+++ b/strace/xlat/quotacmds.in
@@ -0,0 +1,38 @@
+Q_V1_QUOTAON	OLD_CMD(0x1)
+Q_V1_QUOTAOFF	OLD_CMD(0x2)
+Q_V1_GETQUOTA	OLD_CMD(0x3)
+Q_V1_SETQUOTA	OLD_CMD(0x4)
+Q_V1_SETUSE	OLD_CMD(0x5)
+Q_V1_SYNC	OLD_CMD(0x6)
+Q_SETQLIM	OLD_CMD(0x7)
+Q_V1_GETSTATS	OLD_CMD(0x8)
+Q_V1_RSQUASH	OLD_CMD(0x10)
+
+Q_V2_GETQUOTA	OLD_CMD(0xD)
+Q_V2_SETQUOTA	OLD_CMD(0xE)
+Q_V2_SETUSE	OLD_CMD(0xF)
+Q_V2_GETINFO	OLD_CMD(0x9)
+Q_V2_SETINFO	OLD_CMD(0xA)
+Q_V2_SETGRACE	OLD_CMD(0xB)
+Q_V2_SETFLAGS	OLD_CMD(0xC)
+Q_V2_GETSTATS	OLD_CMD(0x11)
+
+Q_SYNC		NEW_CMD(0x1)
+Q_QUOTAON	NEW_CMD(0x2)
+Q_QUOTAOFF	NEW_CMD(0x3)
+Q_GETFMT	NEW_CMD(0x4)
+Q_GETINFO	NEW_CMD(0x5)
+Q_SETINFO	NEW_CMD(0x6)
+Q_GETQUOTA	NEW_CMD(0x7)
+Q_SETQUOTA	NEW_CMD(0x8)
+Q_GETNEXTQUOTA	NEW_CMD(0x9)
+
+Q_XQUOTAON	XQM_CMD(0x1)
+Q_XQUOTAOFF	XQM_CMD(0x2)
+Q_XGETQUOTA	XQM_CMD(0x3)
+Q_XSETQLIM	XQM_CMD(0x4)
+Q_XGETQSTAT	XQM_CMD(0x5)
+Q_XQUOTARM	XQM_CMD(0x6)
+Q_XQUOTASYNC	XQM_CMD(0x7)
+Q_XGETQSTATV	XQM_CMD(0x8)
+Q_XGETNEXTQUOTA	XQM_CMD(0x9)
diff --git a/strace/xlat/quotatypes.h b/strace/xlat/quotatypes.h
new file mode 100644
index 0000000..d223144
--- /dev/null
+++ b/strace/xlat/quotatypes.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/quotatypes.in; do not edit. */
+#if !(defined(USRQUOTA) || (defined(HAVE_DECL_USRQUOTA) && HAVE_DECL_USRQUOTA))
+# define USRQUOTA 0
+#endif
+#if !(defined(GRPQUOTA) || (defined(HAVE_DECL_GRPQUOTA) && HAVE_DECL_GRPQUOTA))
+# define GRPQUOTA 1
+#endif
+#if !(defined(PRJQUOTA) || (defined(HAVE_DECL_PRJQUOTA) && HAVE_DECL_PRJQUOTA))
+# define PRJQUOTA 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat quotatypes in mpers mode
+
+#else
+
+static
+const struct xlat quotatypes[] = {
+ XLAT(USRQUOTA),
+ XLAT(GRPQUOTA),
+ XLAT(PRJQUOTA),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/quotatypes.in b/strace/xlat/quotatypes.in
new file mode 100644
index 0000000..671fe7d
--- /dev/null
+++ b/strace/xlat/quotatypes.in
@@ -0,0 +1,3 @@
+USRQUOTA 0
+GRPQUOTA 1
+PRJQUOTA 2
diff --git a/strace/xlat/rename_flags.h b/strace/xlat/rename_flags.h
new file mode 100644
index 0000000..2fc0a76
--- /dev/null
+++ b/strace/xlat/rename_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/rename_flags.in; do not edit. */
+#if !(defined(RENAME_NOREPLACE) || (defined(HAVE_DECL_RENAME_NOREPLACE) && HAVE_DECL_RENAME_NOREPLACE))
+# define RENAME_NOREPLACE 1
+#endif
+#if !(defined(RENAME_EXCHANGE) || (defined(HAVE_DECL_RENAME_EXCHANGE) && HAVE_DECL_RENAME_EXCHANGE))
+# define RENAME_EXCHANGE 2
+#endif
+#if !(defined(RENAME_WHITEOUT) || (defined(HAVE_DECL_RENAME_WHITEOUT) && HAVE_DECL_RENAME_WHITEOUT))
+# define RENAME_WHITEOUT 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat rename_flags in mpers mode
+
+#else
+
+static
+const struct xlat rename_flags[] = {
+ XLAT(RENAME_NOREPLACE),
+ XLAT(RENAME_EXCHANGE),
+ XLAT(RENAME_WHITEOUT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/rename_flags.in b/strace/xlat/rename_flags.in
new file mode 100644
index 0000000..8d96b9b
--- /dev/null
+++ b/strace/xlat/rename_flags.in
@@ -0,0 +1,3 @@
+RENAME_NOREPLACE	1
+RENAME_EXCHANGE		2
+RENAME_WHITEOUT		4
diff --git a/strace/xlat/resource_flags.h b/strace/xlat/resource_flags.h
new file mode 100644
index 0000000..7761ca2
--- /dev/null
+++ b/strace/xlat/resource_flags.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/resource_flags.in; do not edit. */
+
+#ifndef IN_MPERS
+
+const struct xlat resource_flags[] = {
+#if defined(IPC_CREAT) || (defined(HAVE_DECL_IPC_CREAT) && HAVE_DECL_IPC_CREAT)
+  XLAT(IPC_CREAT),
+#endif
+#if defined(IPC_EXCL) || (defined(HAVE_DECL_IPC_EXCL) && HAVE_DECL_IPC_EXCL)
+  XLAT(IPC_EXCL),
+#endif
+#if defined(IPC_NOWAIT) || (defined(HAVE_DECL_IPC_NOWAIT) && HAVE_DECL_IPC_NOWAIT)
+  XLAT(IPC_NOWAIT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/resource_flags.in b/strace/xlat/resource_flags.in
new file mode 100644
index 0000000..e7ce9c6
--- /dev/null
+++ b/strace/xlat/resource_flags.in
@@ -0,0 +1,3 @@
+IPC_CREAT
+IPC_EXCL
+IPC_NOWAIT
diff --git a/strace/xlat/resources.h b/strace/xlat/resources.h
new file mode 100644
index 0000000..4493b08
--- /dev/null
+++ b/strace/xlat/resources.h
@@ -0,0 +1,65 @@
+/* Generated by ./xlat/gen.sh from ./xlat/resources.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat resources in mpers mode
+
+#else
+
+static
+const struct xlat resources[] = {
+#if defined(RLIMIT_AS) || (defined(HAVE_DECL_RLIMIT_AS) && HAVE_DECL_RLIMIT_AS)
+  XLAT(RLIMIT_AS),
+#endif
+#if defined(RLIMIT_CORE) || (defined(HAVE_DECL_RLIMIT_CORE) && HAVE_DECL_RLIMIT_CORE)
+  XLAT(RLIMIT_CORE),
+#endif
+#if defined(RLIMIT_CPU) || (defined(HAVE_DECL_RLIMIT_CPU) && HAVE_DECL_RLIMIT_CPU)
+  XLAT(RLIMIT_CPU),
+#endif
+#if defined(RLIMIT_DATA) || (defined(HAVE_DECL_RLIMIT_DATA) && HAVE_DECL_RLIMIT_DATA)
+  XLAT(RLIMIT_DATA),
+#endif
+#if defined(RLIMIT_FSIZE) || (defined(HAVE_DECL_RLIMIT_FSIZE) && HAVE_DECL_RLIMIT_FSIZE)
+  XLAT(RLIMIT_FSIZE),
+#endif
+#if defined(RLIMIT_LOCKS) || (defined(HAVE_DECL_RLIMIT_LOCKS) && HAVE_DECL_RLIMIT_LOCKS)
+  XLAT(RLIMIT_LOCKS),
+#endif
+#if defined(RLIMIT_MEMLOCK) || (defined(HAVE_DECL_RLIMIT_MEMLOCK) && HAVE_DECL_RLIMIT_MEMLOCK)
+  XLAT(RLIMIT_MEMLOCK),
+#endif
+#if defined(RLIMIT_MSGQUEUE) || (defined(HAVE_DECL_RLIMIT_MSGQUEUE) && HAVE_DECL_RLIMIT_MSGQUEUE)
+  XLAT(RLIMIT_MSGQUEUE),
+#endif
+#if defined(RLIMIT_NICE) || (defined(HAVE_DECL_RLIMIT_NICE) && HAVE_DECL_RLIMIT_NICE)
+  XLAT(RLIMIT_NICE),
+#endif
+#if defined(RLIMIT_NOFILE) || (defined(HAVE_DECL_RLIMIT_NOFILE) && HAVE_DECL_RLIMIT_NOFILE)
+  XLAT(RLIMIT_NOFILE),
+#endif
+#if defined(RLIMIT_NPROC) || (defined(HAVE_DECL_RLIMIT_NPROC) && HAVE_DECL_RLIMIT_NPROC)
+  XLAT(RLIMIT_NPROC),
+#endif
+#if defined(RLIMIT_RSS) || (defined(HAVE_DECL_RLIMIT_RSS) && HAVE_DECL_RLIMIT_RSS)
+  XLAT(RLIMIT_RSS),
+#endif
+#if defined(RLIMIT_RTPRIO) || (defined(HAVE_DECL_RLIMIT_RTPRIO) && HAVE_DECL_RLIMIT_RTPRIO)
+  XLAT(RLIMIT_RTPRIO),
+#endif
+#if defined(RLIMIT_RTTIME) || (defined(HAVE_DECL_RLIMIT_RTTIME) && HAVE_DECL_RLIMIT_RTTIME)
+  XLAT(RLIMIT_RTTIME),
+#endif
+#if defined(RLIMIT_SIGPENDING) || (defined(HAVE_DECL_RLIMIT_SIGPENDING) && HAVE_DECL_RLIMIT_SIGPENDING)
+  XLAT(RLIMIT_SIGPENDING),
+#endif
+#if defined(RLIMIT_STACK) || (defined(HAVE_DECL_RLIMIT_STACK) && HAVE_DECL_RLIMIT_STACK)
+  XLAT(RLIMIT_STACK),
+#endif
+#if defined(RLIMIT_VMEM) || (defined(HAVE_DECL_RLIMIT_VMEM) && HAVE_DECL_RLIMIT_VMEM)
+  XLAT(RLIMIT_VMEM),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/resources.in b/strace/xlat/resources.in
new file mode 100644
index 0000000..8c45b7f
--- /dev/null
+++ b/strace/xlat/resources.in
@@ -0,0 +1,17 @@
+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
diff --git a/strace/xlat/rwf_flags.h b/strace/xlat/rwf_flags.h
new file mode 100644
index 0000000..cd5cfdc
--- /dev/null
+++ b/strace/xlat/rwf_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/rwf_flags.in; do not edit. */
+#if !(defined(RWF_HIPRI) || (defined(HAVE_DECL_RWF_HIPRI) && HAVE_DECL_RWF_HIPRI))
+# define RWF_HIPRI 1
+#endif
+#if !(defined(RWF_DSYNC) || (defined(HAVE_DECL_RWF_DSYNC) && HAVE_DECL_RWF_DSYNC))
+# define RWF_DSYNC 2
+#endif
+#if !(defined(RWF_SYNC) || (defined(HAVE_DECL_RWF_SYNC) && HAVE_DECL_RWF_SYNC))
+# define RWF_SYNC 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat rwf_flags in mpers mode
+
+#else
+
+static
+const struct xlat rwf_flags[] = {
+ XLAT(RWF_HIPRI),
+ XLAT(RWF_DSYNC),
+ XLAT(RWF_SYNC),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/rwf_flags.in b/strace/xlat/rwf_flags.in
new file mode 100644
index 0000000..2e75445
--- /dev/null
+++ b/strace/xlat/rwf_flags.in
@@ -0,0 +1,3 @@
+RWF_HIPRI	1
+RWF_DSYNC	2
+RWF_SYNC	4
diff --git a/strace/xlat/sched_flags.h b/strace/xlat/sched_flags.h
new file mode 100644
index 0000000..7863861
--- /dev/null
+++ b/strace/xlat/sched_flags.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sched_flags.in; do not edit. */
+#if !(defined(SCHED_FLAG_RESET_ON_FORK) || (defined(HAVE_DECL_SCHED_FLAG_RESET_ON_FORK) && HAVE_DECL_SCHED_FLAG_RESET_ON_FORK))
+# define SCHED_FLAG_RESET_ON_FORK 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sched_flags in mpers mode
+
+#else
+
+static
+const struct xlat sched_flags[] = {
+ XLAT(SCHED_FLAG_RESET_ON_FORK),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sched_flags.in b/strace/xlat/sched_flags.in
new file mode 100644
index 0000000..824d91d
--- /dev/null
+++ b/strace/xlat/sched_flags.in
@@ -0,0 +1 @@
+SCHED_FLAG_RESET_ON_FORK 1
diff --git a/strace/xlat/schedulers.h b/strace/xlat/schedulers.h
new file mode 100644
index 0000000..099db27
--- /dev/null
+++ b/strace/xlat/schedulers.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/schedulers.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat schedulers in mpers mode
+
+#else
+
+static
+const struct xlat schedulers[] = {
+#if defined(SCHED_OTHER) || (defined(HAVE_DECL_SCHED_OTHER) && HAVE_DECL_SCHED_OTHER)
+  XLAT(SCHED_OTHER),
+#endif
+#if defined(SCHED_FIFO) || (defined(HAVE_DECL_SCHED_FIFO) && HAVE_DECL_SCHED_FIFO)
+  XLAT(SCHED_FIFO),
+#endif
+#if defined(SCHED_RR) || (defined(HAVE_DECL_SCHED_RR) && HAVE_DECL_SCHED_RR)
+  XLAT(SCHED_RR),
+#endif
+#if defined(SCHED_BATCH) || (defined(HAVE_DECL_SCHED_BATCH) && HAVE_DECL_SCHED_BATCH)
+  XLAT(SCHED_BATCH),
+#endif
+#if defined(SCHED_ISO) || (defined(HAVE_DECL_SCHED_ISO) && HAVE_DECL_SCHED_ISO)
+  XLAT(SCHED_ISO),
+#endif
+#if defined(SCHED_IDLE) || (defined(HAVE_DECL_SCHED_IDLE) && HAVE_DECL_SCHED_IDLE)
+  XLAT(SCHED_IDLE),
+#endif
+#if defined(SCHED_DEADLINE) || (defined(HAVE_DECL_SCHED_DEADLINE) && HAVE_DECL_SCHED_DEADLINE)
+  XLAT(SCHED_DEADLINE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/schedulers.in b/strace/xlat/schedulers.in
new file mode 100644
index 0000000..4a6e366
--- /dev/null
+++ b/strace/xlat/schedulers.in
@@ -0,0 +1,7 @@
+SCHED_OTHER
+SCHED_FIFO
+SCHED_RR
+SCHED_BATCH
+SCHED_ISO
+SCHED_IDLE
+SCHED_DEADLINE
diff --git a/strace/xlat/scmvals.h b/strace/xlat/scmvals.h
new file mode 100644
index 0000000..a7ca2f0
--- /dev/null
+++ b/strace/xlat/scmvals.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/scmvals.in; do not edit. */
+#if !(defined(SCM_RIGHTS) || (defined(HAVE_DECL_SCM_RIGHTS) && HAVE_DECL_SCM_RIGHTS))
+# define SCM_RIGHTS 1
+#endif
+#if !(defined(SCM_CREDENTIALS) || (defined(HAVE_DECL_SCM_CREDENTIALS) && HAVE_DECL_SCM_CREDENTIALS))
+# define SCM_CREDENTIALS 2
+#endif
+#if !(defined(SCM_SECURITY) || (defined(HAVE_DECL_SCM_SECURITY) && HAVE_DECL_SCM_SECURITY))
+# define SCM_SECURITY 3
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat scmvals in mpers mode
+
+#else
+
+static
+const struct xlat scmvals[] = {
+ XLAT(SCM_RIGHTS),
+ XLAT(SCM_CREDENTIALS),
+ XLAT(SCM_SECURITY),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/scmvals.in b/strace/xlat/scmvals.in
new file mode 100644
index 0000000..3d61f9e
--- /dev/null
+++ b/strace/xlat/scmvals.in
@@ -0,0 +1,3 @@
+SCM_RIGHTS	1
+SCM_CREDENTIALS	2
+SCM_SECURITY	3
diff --git a/strace/xlat/secbits.h b/strace/xlat/secbits.h
new file mode 100644
index 0000000..d616e1f
--- /dev/null
+++ b/strace/xlat/secbits.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/secbits.in; do not edit. */
+#if !(defined(SECBIT_NOROOT) || (defined(HAVE_DECL_SECBIT_NOROOT) && HAVE_DECL_SECBIT_NOROOT))
+# define SECBIT_NOROOT (1 << 0)
+#endif
+#if !(defined(SECBIT_NOROOT_LOCKED) || (defined(HAVE_DECL_SECBIT_NOROOT_LOCKED) && HAVE_DECL_SECBIT_NOROOT_LOCKED))
+# define SECBIT_NOROOT_LOCKED (1 << 1)
+#endif
+#if !(defined(SECBIT_NO_SETUID_FIXUP) || (defined(HAVE_DECL_SECBIT_NO_SETUID_FIXUP) && HAVE_DECL_SECBIT_NO_SETUID_FIXUP))
+# define SECBIT_NO_SETUID_FIXUP (1 << 2)
+#endif
+#if !(defined(SECBIT_NO_SETUID_FIXUP_LOCKED) || (defined(HAVE_DECL_SECBIT_NO_SETUID_FIXUP_LOCKED) && HAVE_DECL_SECBIT_NO_SETUID_FIXUP_LOCKED))
+# define SECBIT_NO_SETUID_FIXUP_LOCKED (1 << 3)
+#endif
+#if !(defined(SECBIT_KEEP_CAPS) || (defined(HAVE_DECL_SECBIT_KEEP_CAPS) && HAVE_DECL_SECBIT_KEEP_CAPS))
+# define SECBIT_KEEP_CAPS (1 << 4)
+#endif
+#if !(defined(SECBIT_KEEP_CAPS_LOCKED) || (defined(HAVE_DECL_SECBIT_KEEP_CAPS_LOCKED) && HAVE_DECL_SECBIT_KEEP_CAPS_LOCKED))
+# define SECBIT_KEEP_CAPS_LOCKED (1 << 5)
+#endif
+#if !(defined(SECBIT_NO_CAP_AMBIENT_RAISE) || (defined(HAVE_DECL_SECBIT_NO_CAP_AMBIENT_RAISE) && HAVE_DECL_SECBIT_NO_CAP_AMBIENT_RAISE))
+# define SECBIT_NO_CAP_AMBIENT_RAISE (1 << 6)
+#endif
+#if !(defined(SECBIT_NO_CAP_AMBIENT_RAISE_LOCKED) || (defined(HAVE_DECL_SECBIT_NO_CAP_AMBIENT_RAISE_LOCKED) && HAVE_DECL_SECBIT_NO_CAP_AMBIENT_RAISE_LOCKED))
+# define SECBIT_NO_CAP_AMBIENT_RAISE_LOCKED (1 << 7)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat secbits in mpers mode
+
+#else
+
+static
+const struct xlat secbits[] = {
+ XLAT(SECBIT_NOROOT),
+ XLAT(SECBIT_NOROOT_LOCKED),
+ XLAT(SECBIT_NO_SETUID_FIXUP),
+ XLAT(SECBIT_NO_SETUID_FIXUP_LOCKED),
+ XLAT(SECBIT_KEEP_CAPS),
+ XLAT(SECBIT_KEEP_CAPS_LOCKED),
+ XLAT(SECBIT_NO_CAP_AMBIENT_RAISE),
+ XLAT(SECBIT_NO_CAP_AMBIENT_RAISE_LOCKED),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/secbits.in b/strace/xlat/secbits.in
new file mode 100644
index 0000000..975bd83
--- /dev/null
+++ b/strace/xlat/secbits.in
@@ -0,0 +1,8 @@
+SECBIT_NOROOT (1 << 0)
+SECBIT_NOROOT_LOCKED (1 << 1)
+SECBIT_NO_SETUID_FIXUP (1 << 2)
+SECBIT_NO_SETUID_FIXUP_LOCKED (1 << 3)
+SECBIT_KEEP_CAPS (1 << 4)
+SECBIT_KEEP_CAPS_LOCKED (1 << 5)
+SECBIT_NO_CAP_AMBIENT_RAISE (1 << 6)
+SECBIT_NO_CAP_AMBIENT_RAISE_LOCKED (1 << 7)
diff --git a/strace/xlat/seccomp_filter_flags.h b/strace/xlat/seccomp_filter_flags.h
new file mode 100644
index 0000000..5c0decd
--- /dev/null
+++ b/strace/xlat/seccomp_filter_flags.h
@@ -0,0 +1,18 @@
+/* Generated by ./xlat/gen.sh from ./xlat/seccomp_filter_flags.in; do not edit. */
+#if !(defined(SECCOMP_FILTER_FLAG_TSYNC) || (defined(HAVE_DECL_SECCOMP_FILTER_FLAG_TSYNC) && HAVE_DECL_SECCOMP_FILTER_FLAG_TSYNC))
+# define SECCOMP_FILTER_FLAG_TSYNC 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat seccomp_filter_flags in mpers mode
+
+#else
+
+static
+const struct xlat seccomp_filter_flags[] = {
+ XLAT(SECCOMP_FILTER_FLAG_TSYNC),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/seccomp_filter_flags.in b/strace/xlat/seccomp_filter_flags.in
new file mode 100644
index 0000000..83482d0
--- /dev/null
+++ b/strace/xlat/seccomp_filter_flags.in
@@ -0,0 +1 @@
+SECCOMP_FILTER_FLAG_TSYNC 1
diff --git a/strace/xlat/seccomp_mode.h b/strace/xlat/seccomp_mode.h
new file mode 100644
index 0000000..842dd44
--- /dev/null
+++ b/strace/xlat/seccomp_mode.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/seccomp_mode.in; do not edit. */
+#if !(defined(SECCOMP_MODE_DISABLED) || (defined(HAVE_DECL_SECCOMP_MODE_DISABLED) && HAVE_DECL_SECCOMP_MODE_DISABLED))
+# define SECCOMP_MODE_DISABLED 0
+#endif
+#if !(defined(SECCOMP_MODE_STRICT) || (defined(HAVE_DECL_SECCOMP_MODE_STRICT) && HAVE_DECL_SECCOMP_MODE_STRICT))
+# define SECCOMP_MODE_STRICT 1
+#endif
+#if !(defined(SECCOMP_MODE_FILTER) || (defined(HAVE_DECL_SECCOMP_MODE_FILTER) && HAVE_DECL_SECCOMP_MODE_FILTER))
+# define SECCOMP_MODE_FILTER 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat seccomp_mode in mpers mode
+
+#else
+
+static
+const struct xlat seccomp_mode[] = {
+ XLAT(SECCOMP_MODE_DISABLED),
+ XLAT(SECCOMP_MODE_STRICT),
+ XLAT(SECCOMP_MODE_FILTER),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/seccomp_mode.in b/strace/xlat/seccomp_mode.in
new file mode 100644
index 0000000..eed9fae
--- /dev/null
+++ b/strace/xlat/seccomp_mode.in
@@ -0,0 +1,3 @@
+SECCOMP_MODE_DISABLED 0
+SECCOMP_MODE_STRICT 1
+SECCOMP_MODE_FILTER 2
diff --git a/strace/xlat/seccomp_ops.h b/strace/xlat/seccomp_ops.h
new file mode 100644
index 0000000..3fd0dc6
--- /dev/null
+++ b/strace/xlat/seccomp_ops.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/seccomp_ops.in; do not edit. */
+#if !(defined(SECCOMP_SET_MODE_STRICT) || (defined(HAVE_DECL_SECCOMP_SET_MODE_STRICT) && HAVE_DECL_SECCOMP_SET_MODE_STRICT))
+# define SECCOMP_SET_MODE_STRICT 0
+#endif
+#if !(defined(SECCOMP_SET_MODE_FILTER) || (defined(HAVE_DECL_SECCOMP_SET_MODE_FILTER) && HAVE_DECL_SECCOMP_SET_MODE_FILTER))
+# define SECCOMP_SET_MODE_FILTER 1
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat seccomp_ops in mpers mode
+
+#else
+
+static
+const struct xlat seccomp_ops[] = {
+ XLAT(SECCOMP_SET_MODE_STRICT),
+ XLAT(SECCOMP_SET_MODE_FILTER),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/seccomp_ops.in b/strace/xlat/seccomp_ops.in
new file mode 100644
index 0000000..c3320af
--- /dev/null
+++ b/strace/xlat/seccomp_ops.in
@@ -0,0 +1,2 @@
+SECCOMP_SET_MODE_STRICT 0
+SECCOMP_SET_MODE_FILTER 1
diff --git a/strace/xlat/seccomp_ret_action.h b/strace/xlat/seccomp_ret_action.h
new file mode 100644
index 0000000..2d41609
--- /dev/null
+++ b/strace/xlat/seccomp_ret_action.h
@@ -0,0 +1,29 @@
+/* Generated by ./xlat/gen.sh from ./xlat/seccomp_ret_action.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat seccomp_ret_action in mpers mode
+
+#else
+
+static
+const struct xlat seccomp_ret_action[] = {
+#if defined(SECCOMP_RET_KILL) || (defined(HAVE_DECL_SECCOMP_RET_KILL) && HAVE_DECL_SECCOMP_RET_KILL)
+  XLAT(SECCOMP_RET_KILL),
+#endif
+#if defined(SECCOMP_RET_TRAP) || (defined(HAVE_DECL_SECCOMP_RET_TRAP) && HAVE_DECL_SECCOMP_RET_TRAP)
+  XLAT(SECCOMP_RET_TRAP),
+#endif
+#if defined(SECCOMP_RET_ERRNO) || (defined(HAVE_DECL_SECCOMP_RET_ERRNO) && HAVE_DECL_SECCOMP_RET_ERRNO)
+  XLAT(SECCOMP_RET_ERRNO),
+#endif
+#if defined(SECCOMP_RET_TRACE) || (defined(HAVE_DECL_SECCOMP_RET_TRACE) && HAVE_DECL_SECCOMP_RET_TRACE)
+  XLAT(SECCOMP_RET_TRACE),
+#endif
+#if defined(SECCOMP_RET_ALLOW) || (defined(HAVE_DECL_SECCOMP_RET_ALLOW) && HAVE_DECL_SECCOMP_RET_ALLOW)
+  XLAT(SECCOMP_RET_ALLOW),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/seccomp_ret_action.in b/strace/xlat/seccomp_ret_action.in
new file mode 100644
index 0000000..6212dcb
--- /dev/null
+++ b/strace/xlat/seccomp_ret_action.in
@@ -0,0 +1,5 @@
+SECCOMP_RET_KILL
+SECCOMP_RET_TRAP
+SECCOMP_RET_ERRNO
+SECCOMP_RET_TRACE
+SECCOMP_RET_ALLOW
diff --git a/strace/xlat/semctl_flags.h b/strace/xlat/semctl_flags.h
new file mode 100644
index 0000000..b8e0c62
--- /dev/null
+++ b/strace/xlat/semctl_flags.h
@@ -0,0 +1,55 @@
+/* Generated by ./xlat/gen.sh from ./xlat/semctl_flags.in; do not edit. */
+#if !(defined(SEM_STAT) || (defined(HAVE_DECL_SEM_STAT) && HAVE_DECL_SEM_STAT))
+# define SEM_STAT 18
+#endif
+#if !(defined(SEM_INFO) || (defined(HAVE_DECL_SEM_INFO) && HAVE_DECL_SEM_INFO))
+# define SEM_INFO 19
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat semctl_flags in mpers mode
+
+#else
+
+static
+const struct xlat semctl_flags[] = {
+#if defined(IPC_RMID) || (defined(HAVE_DECL_IPC_RMID) && HAVE_DECL_IPC_RMID)
+  XLAT(IPC_RMID),
+#endif
+#if defined(IPC_SET) || (defined(HAVE_DECL_IPC_SET) && HAVE_DECL_IPC_SET)
+  XLAT(IPC_SET),
+#endif
+#if defined(IPC_STAT) || (defined(HAVE_DECL_IPC_STAT) && HAVE_DECL_IPC_STAT)
+  XLAT(IPC_STAT),
+#endif
+#if defined(IPC_INFO) || (defined(HAVE_DECL_IPC_INFO) && HAVE_DECL_IPC_INFO)
+  XLAT(IPC_INFO),
+#endif
+ XLAT(SEM_STAT),
+ XLAT(SEM_INFO),
+#if defined(GETPID) || (defined(HAVE_DECL_GETPID) && HAVE_DECL_GETPID)
+  XLAT(GETPID),
+#endif
+#if defined(GETVAL) || (defined(HAVE_DECL_GETVAL) && HAVE_DECL_GETVAL)
+  XLAT(GETVAL),
+#endif
+#if defined(GETALL) || (defined(HAVE_DECL_GETALL) && HAVE_DECL_GETALL)
+  XLAT(GETALL),
+#endif
+#if defined(GETNCNT) || (defined(HAVE_DECL_GETNCNT) && HAVE_DECL_GETNCNT)
+  XLAT(GETNCNT),
+#endif
+#if defined(GETZCNT) || (defined(HAVE_DECL_GETZCNT) && HAVE_DECL_GETZCNT)
+  XLAT(GETZCNT),
+#endif
+#if defined(SETVAL) || (defined(HAVE_DECL_SETVAL) && HAVE_DECL_SETVAL)
+  XLAT(SETVAL),
+#endif
+#if defined(SETALL) || (defined(HAVE_DECL_SETALL) && HAVE_DECL_SETALL)
+  XLAT(SETALL),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/semctl_flags.in b/strace/xlat/semctl_flags.in
new file mode 100644
index 0000000..5638adb
--- /dev/null
+++ b/strace/xlat/semctl_flags.in
@@ -0,0 +1,13 @@
+IPC_RMID
+IPC_SET
+IPC_STAT
+IPC_INFO
+SEM_STAT 18
+SEM_INFO 19
+GETPID
+GETVAL
+GETALL
+GETNCNT
+GETZCNT
+SETVAL
+SETALL
diff --git a/strace/xlat/semop_flags.h b/strace/xlat/semop_flags.h
new file mode 100644
index 0000000..b5ce4a0
--- /dev/null
+++ b/strace/xlat/semop_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/semop_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat semop_flags in mpers mode
+
+#else
+
+static
+const struct xlat semop_flags[] = {
+#if defined(SEM_UNDO) || (defined(HAVE_DECL_SEM_UNDO) && HAVE_DECL_SEM_UNDO)
+  XLAT(SEM_UNDO),
+#endif
+#if defined(IPC_NOWAIT) || (defined(HAVE_DECL_IPC_NOWAIT) && HAVE_DECL_IPC_NOWAIT)
+  XLAT(IPC_NOWAIT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/semop_flags.in b/strace/xlat/semop_flags.in
new file mode 100644
index 0000000..110eca6
--- /dev/null
+++ b/strace/xlat/semop_flags.in
@@ -0,0 +1,2 @@
+SEM_UNDO
+IPC_NOWAIT
diff --git a/strace/xlat/setsockipoptions.h b/strace/xlat/setsockipoptions.h
new file mode 100644
index 0000000..34ae307
--- /dev/null
+++ b/strace/xlat/setsockipoptions.h
@@ -0,0 +1,89 @@
+/* Generated by ./xlat/gen.sh from ./xlat/setsockipoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat setsockipoptions in mpers mode
+
+#else
+
+static
+const struct xlat setsockipoptions[] = {
+/*
+* Options specific to setsockopt(SOL_IP).
+* Common {g,s}etsockopt(SOL_IP) options
+* should be in sockipoptions.in instead.
+*/
+
+#if defined(ARPT_SO_SET_REPLACE) || (defined(HAVE_DECL_ARPT_SO_SET_REPLACE) && HAVE_DECL_ARPT_SO_SET_REPLACE)
+  XLAT(ARPT_SO_SET_REPLACE),
+#endif
+#if defined(ARPT_SO_SET_ADD_COUNTERS) || (defined(HAVE_DECL_ARPT_SO_SET_ADD_COUNTERS) && HAVE_DECL_ARPT_SO_SET_ADD_COUNTERS)
+  XLAT(ARPT_SO_SET_ADD_COUNTERS),
+#endif
+
+#if defined(EBT_SO_SET_ENTRIES) || (defined(HAVE_DECL_EBT_SO_SET_ENTRIES) && HAVE_DECL_EBT_SO_SET_ENTRIES)
+  XLAT(EBT_SO_SET_ENTRIES),
+#endif
+#if defined(EBT_SO_SET_COUNTERS) || (defined(HAVE_DECL_EBT_SO_SET_COUNTERS) && HAVE_DECL_EBT_SO_SET_COUNTERS)
+  XLAT(EBT_SO_SET_COUNTERS),
+#endif
+
+#if defined(IP_VS_SO_SET_NONE) || (defined(HAVE_DECL_IP_VS_SO_SET_NONE) && HAVE_DECL_IP_VS_SO_SET_NONE)
+  XLAT(IP_VS_SO_SET_NONE),
+#endif
+#if defined(IP_VS_SO_SET_INSERT) || (defined(HAVE_DECL_IP_VS_SO_SET_INSERT) && HAVE_DECL_IP_VS_SO_SET_INSERT)
+  XLAT(IP_VS_SO_SET_INSERT),
+#endif
+#if defined(IP_VS_SO_SET_ADD) || (defined(HAVE_DECL_IP_VS_SO_SET_ADD) && HAVE_DECL_IP_VS_SO_SET_ADD)
+  XLAT(IP_VS_SO_SET_ADD),
+#endif
+#if defined(IP_VS_SO_SET_EDIT) || (defined(HAVE_DECL_IP_VS_SO_SET_EDIT) && HAVE_DECL_IP_VS_SO_SET_EDIT)
+  XLAT(IP_VS_SO_SET_EDIT),
+#endif
+#if defined(IP_VS_SO_SET_DEL) || (defined(HAVE_DECL_IP_VS_SO_SET_DEL) && HAVE_DECL_IP_VS_SO_SET_DEL)
+  XLAT(IP_VS_SO_SET_DEL),
+#endif
+#if defined(IP_VS_SO_SET_FLUSH) || (defined(HAVE_DECL_IP_VS_SO_SET_FLUSH) && HAVE_DECL_IP_VS_SO_SET_FLUSH)
+  XLAT(IP_VS_SO_SET_FLUSH),
+#endif
+#if defined(IP_VS_SO_SET_LIST) || (defined(HAVE_DECL_IP_VS_SO_SET_LIST) && HAVE_DECL_IP_VS_SO_SET_LIST)
+  XLAT(IP_VS_SO_SET_LIST),
+#endif
+#if defined(IP_VS_SO_SET_ADDDEST) || (defined(HAVE_DECL_IP_VS_SO_SET_ADDDEST) && HAVE_DECL_IP_VS_SO_SET_ADDDEST)
+  XLAT(IP_VS_SO_SET_ADDDEST),
+#endif
+#if defined(IP_VS_SO_SET_DELDEST) || (defined(HAVE_DECL_IP_VS_SO_SET_DELDEST) && HAVE_DECL_IP_VS_SO_SET_DELDEST)
+  XLAT(IP_VS_SO_SET_DELDEST),
+#endif
+#if defined(IP_VS_SO_SET_EDITDEST) || (defined(HAVE_DECL_IP_VS_SO_SET_EDITDEST) && HAVE_DECL_IP_VS_SO_SET_EDITDEST)
+  XLAT(IP_VS_SO_SET_EDITDEST),
+#endif
+#if defined(IP_VS_SO_SET_TIMEOUT) || (defined(HAVE_DECL_IP_VS_SO_SET_TIMEOUT) && HAVE_DECL_IP_VS_SO_SET_TIMEOUT)
+  XLAT(IP_VS_SO_SET_TIMEOUT),
+#endif
+#if defined(IP_VS_SO_SET_STARTDAEMON) || (defined(HAVE_DECL_IP_VS_SO_SET_STARTDAEMON) && HAVE_DECL_IP_VS_SO_SET_STARTDAEMON)
+  XLAT(IP_VS_SO_SET_STARTDAEMON),
+#endif
+#if defined(IP_VS_SO_SET_STOPDAEMON) || (defined(HAVE_DECL_IP_VS_SO_SET_STOPDAEMON) && HAVE_DECL_IP_VS_SO_SET_STOPDAEMON)
+  XLAT(IP_VS_SO_SET_STOPDAEMON),
+#endif
+#if defined(IP_VS_SO_SET_RESTORE) || (defined(HAVE_DECL_IP_VS_SO_SET_RESTORE) && HAVE_DECL_IP_VS_SO_SET_RESTORE)
+  XLAT(IP_VS_SO_SET_RESTORE),
+#endif
+#if defined(IP_VS_SO_SET_SAVE) || (defined(HAVE_DECL_IP_VS_SO_SET_SAVE) && HAVE_DECL_IP_VS_SO_SET_SAVE)
+  XLAT(IP_VS_SO_SET_SAVE),
+#endif
+#if defined(IP_VS_SO_SET_ZERO) || (defined(HAVE_DECL_IP_VS_SO_SET_ZERO) && HAVE_DECL_IP_VS_SO_SET_ZERO)
+  XLAT(IP_VS_SO_SET_ZERO),
+#endif
+
+#if defined(IPT_SO_SET_REPLACE) || (defined(HAVE_DECL_IPT_SO_SET_REPLACE) && HAVE_DECL_IPT_SO_SET_REPLACE)
+  XLAT(IPT_SO_SET_REPLACE),
+#endif
+#if defined(IPT_SO_SET_ADD_COUNTERS) || (defined(HAVE_DECL_IPT_SO_SET_ADD_COUNTERS) && HAVE_DECL_IPT_SO_SET_ADD_COUNTERS)
+  XLAT(IPT_SO_SET_ADD_COUNTERS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/setsockipoptions.in b/strace/xlat/setsockipoptions.in
new file mode 100644
index 0000000..878a594
--- /dev/null
+++ b/strace/xlat/setsockipoptions.in
@@ -0,0 +1,31 @@
+/*
+ * Options specific to setsockopt(SOL_IP).
+ * Common {g,s}etsockopt(SOL_IP) options
+ * should be in sockipoptions.in instead.
+ */
+
+ARPT_SO_SET_REPLACE
+ARPT_SO_SET_ADD_COUNTERS
+
+EBT_SO_SET_ENTRIES
+EBT_SO_SET_COUNTERS
+
+IP_VS_SO_SET_NONE
+IP_VS_SO_SET_INSERT
+IP_VS_SO_SET_ADD
+IP_VS_SO_SET_EDIT
+IP_VS_SO_SET_DEL
+IP_VS_SO_SET_FLUSH
+IP_VS_SO_SET_LIST
+IP_VS_SO_SET_ADDDEST
+IP_VS_SO_SET_DELDEST
+IP_VS_SO_SET_EDITDEST
+IP_VS_SO_SET_TIMEOUT
+IP_VS_SO_SET_STARTDAEMON
+IP_VS_SO_SET_STOPDAEMON
+IP_VS_SO_SET_RESTORE
+IP_VS_SO_SET_SAVE
+IP_VS_SO_SET_ZERO
+
+IPT_SO_SET_REPLACE
+IPT_SO_SET_ADD_COUNTERS
diff --git a/strace/xlat/setsockipv6options.h b/strace/xlat/setsockipv6options.h
new file mode 100644
index 0000000..4fea6bc
--- /dev/null
+++ b/strace/xlat/setsockipv6options.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/setsockipv6options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat setsockipv6options in mpers mode
+
+#else
+
+static
+const struct xlat setsockipv6options[] = {
+/*
+* Options specific to setsockopt(SOL_IPV6).
+* Common {g,s}etsockopt(SOL_IPV6) options
+* should be in sockipv6options.in instead.
+*/
+
+#if defined(IP6T_SO_SET_REPLACE) || (defined(HAVE_DECL_IP6T_SO_SET_REPLACE) && HAVE_DECL_IP6T_SO_SET_REPLACE)
+  XLAT(IP6T_SO_SET_REPLACE),
+#endif
+#if defined(IP6T_SO_SET_ADD_COUNTERS) || (defined(HAVE_DECL_IP6T_SO_SET_ADD_COUNTERS) && HAVE_DECL_IP6T_SO_SET_ADD_COUNTERS)
+  XLAT(IP6T_SO_SET_ADD_COUNTERS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/setsockipv6options.in b/strace/xlat/setsockipv6options.in
new file mode 100644
index 0000000..a9eff85
--- /dev/null
+++ b/strace/xlat/setsockipv6options.in
@@ -0,0 +1,8 @@
+/*
+ * Options specific to setsockopt(SOL_IPV6).
+ * Common {g,s}etsockopt(SOL_IPV6) options
+ * should be in sockipv6options.in instead.
+ */
+
+IP6T_SO_SET_REPLACE
+IP6T_SO_SET_ADD_COUNTERS
diff --git a/strace/xlat/sfd_flags.h b/strace/xlat/sfd_flags.h
new file mode 100644
index 0000000..23d08b8
--- /dev/null
+++ b/strace/xlat/sfd_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sfd_flags.in; do not edit. */
+#if defined SFD_CLOEXEC || defined O_CLOEXEC
+#if !(defined(SFD_CLOEXEC) || (defined(HAVE_DECL_SFD_CLOEXEC) && HAVE_DECL_SFD_CLOEXEC))
+# define SFD_CLOEXEC O_CLOEXEC
+#endif
+#endif
+#if !(defined(SFD_NONBLOCK) || (defined(HAVE_DECL_SFD_NONBLOCK) && HAVE_DECL_SFD_NONBLOCK))
+# define SFD_NONBLOCK O_NONBLOCK
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sfd_flags in mpers mode
+
+#else
+
+static
+const struct xlat sfd_flags[] = {
+#if defined SFD_CLOEXEC || defined O_CLOEXEC
+ XLAT(SFD_CLOEXEC),
+#endif
+ XLAT(SFD_NONBLOCK),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sfd_flags.in b/strace/xlat/sfd_flags.in
new file mode 100644
index 0000000..20a5d1f
--- /dev/null
+++ b/strace/xlat/sfd_flags.in
@@ -0,0 +1,4 @@
+#if defined SFD_CLOEXEC || defined O_CLOEXEC
+SFD_CLOEXEC	O_CLOEXEC
+#endif
+SFD_NONBLOCK	O_NONBLOCK
diff --git a/strace/xlat/sg_io_dxfer_direction.h b/strace/xlat/sg_io_dxfer_direction.h
new file mode 100644
index 0000000..51248f5
--- /dev/null
+++ b/strace/xlat/sg_io_dxfer_direction.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sg_io_dxfer_direction.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sg_io_dxfer_direction in mpers mode
+
+#else
+
+static
+const struct xlat sg_io_dxfer_direction[] = {
+#if defined(SG_DXFER_NONE) || (defined(HAVE_DECL_SG_DXFER_NONE) && HAVE_DECL_SG_DXFER_NONE)
+  XLAT(SG_DXFER_NONE),
+#endif
+#if defined(SG_DXFER_TO_DEV) || (defined(HAVE_DECL_SG_DXFER_TO_DEV) && HAVE_DECL_SG_DXFER_TO_DEV)
+  XLAT(SG_DXFER_TO_DEV),
+#endif
+#if defined(SG_DXFER_FROM_DEV) || (defined(HAVE_DECL_SG_DXFER_FROM_DEV) && HAVE_DECL_SG_DXFER_FROM_DEV)
+  XLAT(SG_DXFER_FROM_DEV),
+#endif
+#if defined(SG_DXFER_TO_FROM_DEV) || (defined(HAVE_DECL_SG_DXFER_TO_FROM_DEV) && HAVE_DECL_SG_DXFER_TO_FROM_DEV)
+  XLAT(SG_DXFER_TO_FROM_DEV),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sg_io_dxfer_direction.in b/strace/xlat/sg_io_dxfer_direction.in
new file mode 100644
index 0000000..ef2ebd3
--- /dev/null
+++ b/strace/xlat/sg_io_dxfer_direction.in
@@ -0,0 +1,4 @@
+SG_DXFER_NONE
+SG_DXFER_TO_DEV
+SG_DXFER_FROM_DEV
+SG_DXFER_TO_FROM_DEV
diff --git a/strace/xlat/shm_flags.h b/strace/xlat/shm_flags.h
new file mode 100644
index 0000000..79e5407
--- /dev/null
+++ b/strace/xlat/shm_flags.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/shm_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat shm_flags in mpers mode
+
+#else
+
+static
+const struct xlat shm_flags[] = {
+#if defined(SHM_REMAP) || (defined(HAVE_DECL_SHM_REMAP) && HAVE_DECL_SHM_REMAP)
+  XLAT(SHM_REMAP),
+#endif
+#if defined(SHM_RDONLY) || (defined(HAVE_DECL_SHM_RDONLY) && HAVE_DECL_SHM_RDONLY)
+  XLAT(SHM_RDONLY),
+#endif
+#if defined(SHM_RND) || (defined(HAVE_DECL_SHM_RND) && HAVE_DECL_SHM_RND)
+  XLAT(SHM_RND),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/shm_flags.in b/strace/xlat/shm_flags.in
new file mode 100644
index 0000000..a620634
--- /dev/null
+++ b/strace/xlat/shm_flags.in
@@ -0,0 +1,3 @@
+SHM_REMAP
+SHM_RDONLY
+SHM_RND
diff --git a/strace/xlat/shm_resource_flags.h b/strace/xlat/shm_resource_flags.h
new file mode 100644
index 0000000..b216b45
--- /dev/null
+++ b/strace/xlat/shm_resource_flags.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/shm_resource_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat shm_resource_flags in mpers mode
+
+#else
+
+static
+const struct xlat shm_resource_flags[] = {
+#if defined(IPC_CREAT) || (defined(HAVE_DECL_IPC_CREAT) && HAVE_DECL_IPC_CREAT)
+  XLAT(IPC_CREAT),
+#endif
+#if defined(IPC_EXCL) || (defined(HAVE_DECL_IPC_EXCL) && HAVE_DECL_IPC_EXCL)
+  XLAT(IPC_EXCL),
+#endif
+#if defined(SHM_HUGETLB) || (defined(HAVE_DECL_SHM_HUGETLB) && HAVE_DECL_SHM_HUGETLB)
+  XLAT(SHM_HUGETLB),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/shm_resource_flags.in b/strace/xlat/shm_resource_flags.in
new file mode 100644
index 0000000..f3fc0dc
--- /dev/null
+++ b/strace/xlat/shm_resource_flags.in
@@ -0,0 +1,3 @@
+IPC_CREAT
+IPC_EXCL
+SHM_HUGETLB
diff --git a/strace/xlat/shmctl_flags.h b/strace/xlat/shmctl_flags.h
new file mode 100644
index 0000000..a5e9f1b
--- /dev/null
+++ b/strace/xlat/shmctl_flags.h
@@ -0,0 +1,42 @@
+/* Generated by ./xlat/gen.sh from ./xlat/shmctl_flags.in; do not edit. */
+#if !(defined(SHM_STAT) || (defined(HAVE_DECL_SHM_STAT) && HAVE_DECL_SHM_STAT))
+# define SHM_STAT 13
+#endif
+#if !(defined(SHM_INFO) || (defined(HAVE_DECL_SHM_INFO) && HAVE_DECL_SHM_INFO))
+# define SHM_INFO 14
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat shmctl_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat shmctl_flags[] = {
+#if defined(IPC_RMID) || (defined(HAVE_DECL_IPC_RMID) && HAVE_DECL_IPC_RMID)
+  XLAT(IPC_RMID),
+#endif
+#if defined(IPC_SET) || (defined(HAVE_DECL_IPC_SET) && HAVE_DECL_IPC_SET)
+  XLAT(IPC_SET),
+#endif
+#if defined(IPC_STAT) || (defined(HAVE_DECL_IPC_STAT) && HAVE_DECL_IPC_STAT)
+  XLAT(IPC_STAT),
+#endif
+#if defined(IPC_INFO) || (defined(HAVE_DECL_IPC_INFO) && HAVE_DECL_IPC_INFO)
+  XLAT(IPC_INFO),
+#endif
+ XLAT(SHM_STAT),
+ XLAT(SHM_INFO),
+#if defined(SHM_LOCK) || (defined(HAVE_DECL_SHM_LOCK) && HAVE_DECL_SHM_LOCK)
+  XLAT(SHM_LOCK),
+#endif
+#if defined(SHM_UNLOCK) || (defined(HAVE_DECL_SHM_UNLOCK) && HAVE_DECL_SHM_UNLOCK)
+  XLAT(SHM_UNLOCK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/shmctl_flags.in b/strace/xlat/shmctl_flags.in
new file mode 100644
index 0000000..08908bb
--- /dev/null
+++ b/strace/xlat/shmctl_flags.in
@@ -0,0 +1,8 @@
+IPC_RMID
+IPC_SET
+IPC_STAT
+IPC_INFO
+SHM_STAT 13
+SHM_INFO 14
+SHM_LOCK
+SHM_UNLOCK
diff --git a/strace/xlat/shutdown_modes.h b/strace/xlat/shutdown_modes.h
new file mode 100644
index 0000000..f34cb6b
--- /dev/null
+++ b/strace/xlat/shutdown_modes.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/shutdown_modes.in; do not edit. */
+#if !(defined(SHUT_RD) || (defined(HAVE_DECL_SHUT_RD) && HAVE_DECL_SHUT_RD))
+# define SHUT_RD 0
+#endif
+#if !(defined(SHUT_WR) || (defined(HAVE_DECL_SHUT_WR) && HAVE_DECL_SHUT_WR))
+# define SHUT_WR 1
+#endif
+#if !(defined(SHUT_RDWR) || (defined(HAVE_DECL_SHUT_RDWR) && HAVE_DECL_SHUT_RDWR))
+# define SHUT_RDWR 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat shutdown_modes in mpers mode
+
+#else
+
+static
+const struct xlat shutdown_modes[] = {
+ XLAT(SHUT_RD),
+ XLAT(SHUT_WR),
+ XLAT(SHUT_RDWR),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/shutdown_modes.in b/strace/xlat/shutdown_modes.in
new file mode 100644
index 0000000..2996711
--- /dev/null
+++ b/strace/xlat/shutdown_modes.in
@@ -0,0 +1,3 @@
+SHUT_RD 0
+SHUT_WR 1
+SHUT_RDWR 2
diff --git a/strace/xlat/sigact_flags.h b/strace/xlat/sigact_flags.h
new file mode 100644
index 0000000..31debc4
--- /dev/null
+++ b/strace/xlat/sigact_flags.h
@@ -0,0 +1,70 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigact_flags.in; do not edit. */
+#if defined SA_NOMASK && SA_NODEFER != SA_NOMASK
+#endif
+#if defined SA_ONESHOT && SA_ONESHOT != SA_RESETHAND
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sigact_flags in mpers mode
+
+#else
+
+static
+const struct xlat sigact_flags[] = {
+#if defined(SA_RESTORER) || (defined(HAVE_DECL_SA_RESTORER) && HAVE_DECL_SA_RESTORER)
+  XLAT(SA_RESTORER),
+#endif
+#if defined(SA_STACK) || (defined(HAVE_DECL_SA_STACK) && HAVE_DECL_SA_STACK)
+  XLAT(SA_STACK),
+#endif
+#if defined(SA_RESTART) || (defined(HAVE_DECL_SA_RESTART) && HAVE_DECL_SA_RESTART)
+  XLAT(SA_RESTART),
+#endif
+#if defined(SA_INTERRUPT) || (defined(HAVE_DECL_SA_INTERRUPT) && HAVE_DECL_SA_INTERRUPT)
+  XLAT(SA_INTERRUPT),
+#endif
+#if defined(SA_NODEFER) || (defined(HAVE_DECL_SA_NODEFER) && HAVE_DECL_SA_NODEFER)
+  XLAT(SA_NODEFER),
+#endif
+#if defined SA_NOMASK && SA_NODEFER != SA_NOMASK
+#if defined(SA_NOMASK) || (defined(HAVE_DECL_SA_NOMASK) && HAVE_DECL_SA_NOMASK)
+  XLAT(SA_NOMASK),
+#endif
+#endif
+#if defined(SA_RESETHAND) || (defined(HAVE_DECL_SA_RESETHAND) && HAVE_DECL_SA_RESETHAND)
+  XLAT(SA_RESETHAND),
+#endif
+#if defined SA_ONESHOT && SA_ONESHOT != SA_RESETHAND
+#if defined(SA_ONESHOT) || (defined(HAVE_DECL_SA_ONESHOT) && HAVE_DECL_SA_ONESHOT)
+  XLAT(SA_ONESHOT),
+#endif
+#endif
+#if defined(SA_SIGINFO) || (defined(HAVE_DECL_SA_SIGINFO) && HAVE_DECL_SA_SIGINFO)
+  XLAT(SA_SIGINFO),
+#endif
+#if defined(SA_RESETHAND) || (defined(HAVE_DECL_SA_RESETHAND) && HAVE_DECL_SA_RESETHAND)
+  XLAT(SA_RESETHAND),
+#endif
+#if defined(SA_ONSTACK) || (defined(HAVE_DECL_SA_ONSTACK) && HAVE_DECL_SA_ONSTACK)
+  XLAT(SA_ONSTACK),
+#endif
+#if defined(SA_NODEFER) || (defined(HAVE_DECL_SA_NODEFER) && HAVE_DECL_SA_NODEFER)
+  XLAT(SA_NODEFER),
+#endif
+#if defined(SA_NOCLDSTOP) || (defined(HAVE_DECL_SA_NOCLDSTOP) && HAVE_DECL_SA_NOCLDSTOP)
+  XLAT(SA_NOCLDSTOP),
+#endif
+#if defined(SA_NOCLDWAIT) || (defined(HAVE_DECL_SA_NOCLDWAIT) && HAVE_DECL_SA_NOCLDWAIT)
+  XLAT(SA_NOCLDWAIT),
+#endif
+#if defined(_SA_BSDCALL) || (defined(HAVE_DECL__SA_BSDCALL) && HAVE_DECL__SA_BSDCALL)
+  XLAT(_SA_BSDCALL),
+#endif
+#if defined(SA_NOPTRACE) || (defined(HAVE_DECL_SA_NOPTRACE) && HAVE_DECL_SA_NOPTRACE)
+  XLAT(SA_NOPTRACE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigact_flags.in b/strace/xlat/sigact_flags.in
new file mode 100644
index 0000000..27bcff8
--- /dev/null
+++ b/strace/xlat/sigact_flags.in
@@ -0,0 +1,20 @@
+SA_RESTORER
+SA_STACK
+SA_RESTART
+SA_INTERRUPT
+SA_NODEFER
+#if defined SA_NOMASK && SA_NODEFER != SA_NOMASK
+SA_NOMASK
+#endif
+SA_RESETHAND
+#if defined SA_ONESHOT && SA_ONESHOT != SA_RESETHAND
+SA_ONESHOT
+#endif
+SA_SIGINFO
+SA_RESETHAND
+SA_ONSTACK
+SA_NODEFER
+SA_NOCLDSTOP
+SA_NOCLDWAIT
+_SA_BSDCALL
+SA_NOPTRACE
diff --git a/strace/xlat/sigaltstack_flags.h b/strace/xlat/sigaltstack_flags.h
new file mode 100644
index 0000000..76ed327
--- /dev/null
+++ b/strace/xlat/sigaltstack_flags.h
@@ -0,0 +1,28 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigaltstack_flags.in; do not edit. */
+#if !(defined(SS_ONSTACK) || (defined(HAVE_DECL_SS_ONSTACK) && HAVE_DECL_SS_ONSTACK))
+# define SS_ONSTACK 1
+#endif
+#if !(defined(SS_DISABLE) || (defined(HAVE_DECL_SS_DISABLE) && HAVE_DECL_SS_DISABLE))
+# define SS_DISABLE 2
+#endif
+#if !(defined(SS_AUTODISARM) || (defined(HAVE_DECL_SS_AUTODISARM) && HAVE_DECL_SS_AUTODISARM))
+# define SS_AUTODISARM (1U << 31)
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigaltstack_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigaltstack_flags[] = {
+ XLAT(SS_ONSTACK),
+ XLAT(SS_DISABLE),
+ XLAT(SS_AUTODISARM),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigaltstack_flags.in b/strace/xlat/sigaltstack_flags.in
new file mode 100644
index 0000000..9313798
--- /dev/null
+++ b/strace/xlat/sigaltstack_flags.in
@@ -0,0 +1,3 @@
+SS_ONSTACK 1
+SS_DISABLE 2
+SS_AUTODISARM (1U << 31)
diff --git a/strace/xlat/sigbus_codes.h b/strace/xlat/sigbus_codes.h
new file mode 100644
index 0000000..4ad49ab
--- /dev/null
+++ b/strace/xlat/sigbus_codes.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigbus_codes.in; do not edit. */
+#if !(defined(BUS_ADRALN) || (defined(HAVE_DECL_BUS_ADRALN) && HAVE_DECL_BUS_ADRALN))
+# define BUS_ADRALN 1
+#endif
+#if !(defined(BUS_ADRERR) || (defined(HAVE_DECL_BUS_ADRERR) && HAVE_DECL_BUS_ADRERR))
+# define BUS_ADRERR 2
+#endif
+#if !(defined(BUS_OBJERR) || (defined(HAVE_DECL_BUS_OBJERR) && HAVE_DECL_BUS_OBJERR))
+# define BUS_OBJERR 3
+#endif
+#if !(defined(BUS_MCEERR_AR) || (defined(HAVE_DECL_BUS_MCEERR_AR) && HAVE_DECL_BUS_MCEERR_AR))
+# define BUS_MCEERR_AR 4
+#endif
+#if !(defined(BUS_MCEERR_AO) || (defined(HAVE_DECL_BUS_MCEERR_AO) && HAVE_DECL_BUS_MCEERR_AO))
+# define BUS_MCEERR_AO 5
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigbus_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigbus_codes[] = {
+ XLAT(BUS_ADRALN),
+ XLAT(BUS_ADRERR),
+ XLAT(BUS_OBJERR),
+ XLAT(BUS_MCEERR_AR),
+ XLAT(BUS_MCEERR_AO),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigbus_codes.in b/strace/xlat/sigbus_codes.in
new file mode 100644
index 0000000..1bce25f
--- /dev/null
+++ b/strace/xlat/sigbus_codes.in
@@ -0,0 +1,5 @@
+BUS_ADRALN 1
+BUS_ADRERR 2
+BUS_OBJERR 3
+BUS_MCEERR_AR 4
+BUS_MCEERR_AO 5
diff --git a/strace/xlat/sigchld_codes.h b/strace/xlat/sigchld_codes.h
new file mode 100644
index 0000000..e1bf046
--- /dev/null
+++ b/strace/xlat/sigchld_codes.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigchld_codes.in; do not edit. */
+#if !(defined(CLD_EXITED) || (defined(HAVE_DECL_CLD_EXITED) && HAVE_DECL_CLD_EXITED))
+# define CLD_EXITED 1
+#endif
+#if !(defined(CLD_KILLED) || (defined(HAVE_DECL_CLD_KILLED) && HAVE_DECL_CLD_KILLED))
+# define CLD_KILLED 2
+#endif
+#if !(defined(CLD_DUMPED) || (defined(HAVE_DECL_CLD_DUMPED) && HAVE_DECL_CLD_DUMPED))
+# define CLD_DUMPED 3
+#endif
+#if !(defined(CLD_TRAPPED) || (defined(HAVE_DECL_CLD_TRAPPED) && HAVE_DECL_CLD_TRAPPED))
+# define CLD_TRAPPED 4
+#endif
+#if !(defined(CLD_STOPPED) || (defined(HAVE_DECL_CLD_STOPPED) && HAVE_DECL_CLD_STOPPED))
+# define CLD_STOPPED 5
+#endif
+#if !(defined(CLD_CONTINUED) || (defined(HAVE_DECL_CLD_CONTINUED) && HAVE_DECL_CLD_CONTINUED))
+# define CLD_CONTINUED 6
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigchld_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigchld_codes[] = {
+ XLAT(CLD_EXITED),
+ XLAT(CLD_KILLED),
+ XLAT(CLD_DUMPED),
+ XLAT(CLD_TRAPPED),
+ XLAT(CLD_STOPPED),
+ XLAT(CLD_CONTINUED),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigchld_codes.in b/strace/xlat/sigchld_codes.in
new file mode 100644
index 0000000..202bec4
--- /dev/null
+++ b/strace/xlat/sigchld_codes.in
@@ -0,0 +1,6 @@
+CLD_EXITED 1
+CLD_KILLED 2
+CLD_DUMPED 3
+CLD_TRAPPED 4
+CLD_STOPPED 5
+CLD_CONTINUED 6
diff --git a/strace/xlat/sigemt_codes.h b/strace/xlat/sigemt_codes.h
new file mode 100644
index 0000000..68f6fb4
--- /dev/null
+++ b/strace/xlat/sigemt_codes.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigemt_codes.in; do not edit. */
+#if !(defined(EMT_TAGOVF) || (defined(HAVE_DECL_EMT_TAGOVF) && HAVE_DECL_EMT_TAGOVF))
+# define EMT_TAGOVF 1
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigemt_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigemt_codes[] = {
+ XLAT(EMT_TAGOVF),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigemt_codes.in b/strace/xlat/sigemt_codes.in
new file mode 100644
index 0000000..eb87561
--- /dev/null
+++ b/strace/xlat/sigemt_codes.in
@@ -0,0 +1 @@
+EMT_TAGOVF 1
diff --git a/strace/xlat/sigev_value.h b/strace/xlat/sigev_value.h
new file mode 100644
index 0000000..7c569a5
--- /dev/null
+++ b/strace/xlat/sigev_value.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigev_value.in; do not edit. */
+#if !(defined(SIGEV_SIGNAL) || (defined(HAVE_DECL_SIGEV_SIGNAL) && HAVE_DECL_SIGEV_SIGNAL))
+# define SIGEV_SIGNAL 0
+#endif
+#if !(defined(SIGEV_NONE) || (defined(HAVE_DECL_SIGEV_NONE) && HAVE_DECL_SIGEV_NONE))
+# define SIGEV_NONE 1
+#endif
+#if !(defined(SIGEV_THREAD) || (defined(HAVE_DECL_SIGEV_THREAD) && HAVE_DECL_SIGEV_THREAD))
+# define SIGEV_THREAD 2
+#endif
+#if !(defined(SIGEV_THREAD_ID) || (defined(HAVE_DECL_SIGEV_THREAD_ID) && HAVE_DECL_SIGEV_THREAD_ID))
+# define SIGEV_THREAD_ID 4
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigev_value[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigev_value[] = {
+ XLAT(SIGEV_SIGNAL),
+ XLAT(SIGEV_NONE),
+ XLAT(SIGEV_THREAD),
+ XLAT(SIGEV_THREAD_ID),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigev_value.in b/strace/xlat/sigev_value.in
new file mode 100644
index 0000000..d09806b
--- /dev/null
+++ b/strace/xlat/sigev_value.in
@@ -0,0 +1,4 @@
+SIGEV_SIGNAL 0
+SIGEV_NONE 1
+SIGEV_THREAD 2
+SIGEV_THREAD_ID 4
diff --git a/strace/xlat/sigfpe_codes.h b/strace/xlat/sigfpe_codes.h
new file mode 100644
index 0000000..c9e2959
--- /dev/null
+++ b/strace/xlat/sigfpe_codes.h
@@ -0,0 +1,48 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigfpe_codes.in; do not edit. */
+#if !(defined(FPE_INTDIV) || (defined(HAVE_DECL_FPE_INTDIV) && HAVE_DECL_FPE_INTDIV))
+# define FPE_INTDIV 1
+#endif
+#if !(defined(FPE_INTOVF) || (defined(HAVE_DECL_FPE_INTOVF) && HAVE_DECL_FPE_INTOVF))
+# define FPE_INTOVF 2
+#endif
+#if !(defined(FPE_FLTDIV) || (defined(HAVE_DECL_FPE_FLTDIV) && HAVE_DECL_FPE_FLTDIV))
+# define FPE_FLTDIV 3
+#endif
+#if !(defined(FPE_FLTOVF) || (defined(HAVE_DECL_FPE_FLTOVF) && HAVE_DECL_FPE_FLTOVF))
+# define FPE_FLTOVF 4
+#endif
+#if !(defined(FPE_FLTUND) || (defined(HAVE_DECL_FPE_FLTUND) && HAVE_DECL_FPE_FLTUND))
+# define FPE_FLTUND 5
+#endif
+#if !(defined(FPE_FLTRES) || (defined(HAVE_DECL_FPE_FLTRES) && HAVE_DECL_FPE_FLTRES))
+# define FPE_FLTRES 6
+#endif
+#if !(defined(FPE_FLTINV) || (defined(HAVE_DECL_FPE_FLTINV) && HAVE_DECL_FPE_FLTINV))
+# define FPE_FLTINV 7
+#endif
+#if !(defined(FPE_FLTSUB) || (defined(HAVE_DECL_FPE_FLTSUB) && HAVE_DECL_FPE_FLTSUB))
+# define FPE_FLTSUB 8
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigfpe_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigfpe_codes[] = {
+ XLAT(FPE_INTDIV),
+ XLAT(FPE_INTOVF),
+ XLAT(FPE_FLTDIV),
+ XLAT(FPE_FLTOVF),
+ XLAT(FPE_FLTUND),
+ XLAT(FPE_FLTRES),
+ XLAT(FPE_FLTINV),
+ XLAT(FPE_FLTSUB),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigfpe_codes.in b/strace/xlat/sigfpe_codes.in
new file mode 100644
index 0000000..4ef0667
--- /dev/null
+++ b/strace/xlat/sigfpe_codes.in
@@ -0,0 +1,8 @@
+FPE_INTDIV 1
+FPE_INTOVF 2
+FPE_FLTDIV 3
+FPE_FLTOVF 4
+FPE_FLTUND 5
+FPE_FLTRES 6
+FPE_FLTINV 7
+FPE_FLTSUB 8
diff --git a/strace/xlat/sigill_codes.h b/strace/xlat/sigill_codes.h
new file mode 100644
index 0000000..f16a69c
--- /dev/null
+++ b/strace/xlat/sigill_codes.h
@@ -0,0 +1,48 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigill_codes.in; do not edit. */
+#if !(defined(ILL_ILLOPC) || (defined(HAVE_DECL_ILL_ILLOPC) && HAVE_DECL_ILL_ILLOPC))
+# define ILL_ILLOPC 1
+#endif
+#if !(defined(ILL_ILLOPN) || (defined(HAVE_DECL_ILL_ILLOPN) && HAVE_DECL_ILL_ILLOPN))
+# define ILL_ILLOPN 2
+#endif
+#if !(defined(ILL_ILLADR) || (defined(HAVE_DECL_ILL_ILLADR) && HAVE_DECL_ILL_ILLADR))
+# define ILL_ILLADR 3
+#endif
+#if !(defined(ILL_ILLTRP) || (defined(HAVE_DECL_ILL_ILLTRP) && HAVE_DECL_ILL_ILLTRP))
+# define ILL_ILLTRP 4
+#endif
+#if !(defined(ILL_PRVOPC) || (defined(HAVE_DECL_ILL_PRVOPC) && HAVE_DECL_ILL_PRVOPC))
+# define ILL_PRVOPC 5
+#endif
+#if !(defined(ILL_PRVREG) || (defined(HAVE_DECL_ILL_PRVREG) && HAVE_DECL_ILL_PRVREG))
+# define ILL_PRVREG 6
+#endif
+#if !(defined(ILL_COPROC) || (defined(HAVE_DECL_ILL_COPROC) && HAVE_DECL_ILL_COPROC))
+# define ILL_COPROC 7
+#endif
+#if !(defined(ILL_BADSTK) || (defined(HAVE_DECL_ILL_BADSTK) && HAVE_DECL_ILL_BADSTK))
+# define ILL_BADSTK 8
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigill_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigill_codes[] = {
+ XLAT(ILL_ILLOPC),
+ XLAT(ILL_ILLOPN),
+ XLAT(ILL_ILLADR),
+ XLAT(ILL_ILLTRP),
+ XLAT(ILL_PRVOPC),
+ XLAT(ILL_PRVREG),
+ XLAT(ILL_COPROC),
+ XLAT(ILL_BADSTK),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigill_codes.in b/strace/xlat/sigill_codes.in
new file mode 100644
index 0000000..ca111ec
--- /dev/null
+++ b/strace/xlat/sigill_codes.in
@@ -0,0 +1,8 @@
+ILL_ILLOPC 1
+ILL_ILLOPN 2
+ILL_ILLADR 3
+ILL_ILLTRP 4
+ILL_PRVOPC 5
+ILL_PRVREG 6
+ILL_COPROC 7
+ILL_BADSTK 8
diff --git a/strace/xlat/siginfo_codes.h b/strace/xlat/siginfo_codes.h
new file mode 100644
index 0000000..faef6c7
--- /dev/null
+++ b/strace/xlat/siginfo_codes.h
@@ -0,0 +1,62 @@
+/* Generated by ./xlat/gen.sh from ./xlat/siginfo_codes.in; do not edit. */
+#if !(defined(SI_USER) || (defined(HAVE_DECL_SI_USER) && HAVE_DECL_SI_USER))
+# define SI_USER 0
+#endif
+#if !(defined(SI_KERNEL) || (defined(HAVE_DECL_SI_KERNEL) && HAVE_DECL_SI_KERNEL))
+# define SI_KERNEL 0x80
+#endif
+#if !(defined(SI_QUEUE) || (defined(HAVE_DECL_SI_QUEUE) && HAVE_DECL_SI_QUEUE))
+# define SI_QUEUE -1
+#endif
+#if !(defined(SI_TIMER) || (defined(HAVE_DECL_SI_TIMER) && HAVE_DECL_SI_TIMER))
+# define SI_TIMER -2
+#endif
+#if !(defined(SI_MESGQ) || (defined(HAVE_DECL_SI_MESGQ) && HAVE_DECL_SI_MESGQ))
+# define SI_MESGQ -3
+#endif
+#if !(defined(SI_ASYNCIO) || (defined(HAVE_DECL_SI_ASYNCIO) && HAVE_DECL_SI_ASYNCIO))
+# define SI_ASYNCIO -4
+#endif
+#if !(defined(SI_SIGIO) || (defined(HAVE_DECL_SI_SIGIO) && HAVE_DECL_SI_SIGIO))
+# define SI_SIGIO -5
+#endif
+#if !(defined(SI_TKILL) || (defined(HAVE_DECL_SI_TKILL) && HAVE_DECL_SI_TKILL))
+# define SI_TKILL -6
+#endif
+#if !(defined(SI_DETHREAD) || (defined(HAVE_DECL_SI_DETHREAD) && HAVE_DECL_SI_DETHREAD))
+# define SI_DETHREAD -7
+#endif
+#if !(defined(SI_ASYNCNL) || (defined(HAVE_DECL_SI_ASYNCNL) && HAVE_DECL_SI_ASYNCNL))
+# define SI_ASYNCNL -60
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat siginfo_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat siginfo_codes[] = {
+ XLAT(SI_USER),
+ XLAT(SI_KERNEL),
+ XLAT(SI_QUEUE),
+ XLAT(SI_TIMER),
+ XLAT(SI_MESGQ),
+ XLAT(SI_ASYNCIO),
+ XLAT(SI_SIGIO),
+ XLAT(SI_TKILL),
+ XLAT(SI_DETHREAD),
+ XLAT(SI_ASYNCNL),
+#if defined(SI_NOINFO) || (defined(HAVE_DECL_SI_NOINFO) && HAVE_DECL_SI_NOINFO)
+  XLAT(SI_NOINFO),
+#endif
+#if defined(SI_LWP) || (defined(HAVE_DECL_SI_LWP) && HAVE_DECL_SI_LWP)
+  XLAT(SI_LWP),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/siginfo_codes.in b/strace/xlat/siginfo_codes.in
new file mode 100644
index 0000000..a57c370
--- /dev/null
+++ b/strace/xlat/siginfo_codes.in
@@ -0,0 +1,12 @@
+SI_USER 0
+SI_KERNEL 0x80
+SI_QUEUE -1
+SI_TIMER -2
+SI_MESGQ -3
+SI_ASYNCIO -4
+SI_SIGIO -5
+SI_TKILL -6
+SI_DETHREAD -7
+SI_ASYNCNL -60
+SI_NOINFO
+SI_LWP
diff --git a/strace/xlat/sigpoll_codes.h b/strace/xlat/sigpoll_codes.h
new file mode 100644
index 0000000..55cc1bb
--- /dev/null
+++ b/strace/xlat/sigpoll_codes.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigpoll_codes.in; do not edit. */
+#if !(defined(POLL_IN) || (defined(HAVE_DECL_POLL_IN) && HAVE_DECL_POLL_IN))
+# define POLL_IN 1
+#endif
+#if !(defined(POLL_OUT) || (defined(HAVE_DECL_POLL_OUT) && HAVE_DECL_POLL_OUT))
+# define POLL_OUT 2
+#endif
+#if !(defined(POLL_MSG) || (defined(HAVE_DECL_POLL_MSG) && HAVE_DECL_POLL_MSG))
+# define POLL_MSG 3
+#endif
+#if !(defined(POLL_ERR) || (defined(HAVE_DECL_POLL_ERR) && HAVE_DECL_POLL_ERR))
+# define POLL_ERR 4
+#endif
+#if !(defined(POLL_PRI) || (defined(HAVE_DECL_POLL_PRI) && HAVE_DECL_POLL_PRI))
+# define POLL_PRI 5
+#endif
+#if !(defined(POLL_HUP) || (defined(HAVE_DECL_POLL_HUP) && HAVE_DECL_POLL_HUP))
+# define POLL_HUP 6
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigpoll_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigpoll_codes[] = {
+ XLAT(POLL_IN),
+ XLAT(POLL_OUT),
+ XLAT(POLL_MSG),
+ XLAT(POLL_ERR),
+ XLAT(POLL_PRI),
+ XLAT(POLL_HUP),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigpoll_codes.in b/strace/xlat/sigpoll_codes.in
new file mode 100644
index 0000000..00c2a1b
--- /dev/null
+++ b/strace/xlat/sigpoll_codes.in
@@ -0,0 +1,6 @@
+POLL_IN 1
+POLL_OUT 2
+POLL_MSG 3
+POLL_ERR 4
+POLL_PRI 5
+POLL_HUP 6
diff --git a/strace/xlat/sigprocmaskcmds.h b/strace/xlat/sigprocmaskcmds.h
new file mode 100644
index 0000000..427680b
--- /dev/null
+++ b/strace/xlat/sigprocmaskcmds.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigprocmaskcmds.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sigprocmaskcmds in mpers mode
+
+#else
+
+static
+const struct xlat sigprocmaskcmds[] = {
+#if defined(SIG_BLOCK) || (defined(HAVE_DECL_SIG_BLOCK) && HAVE_DECL_SIG_BLOCK)
+  XLAT(SIG_BLOCK),
+#endif
+#if defined(SIG_UNBLOCK) || (defined(HAVE_DECL_SIG_UNBLOCK) && HAVE_DECL_SIG_UNBLOCK)
+  XLAT(SIG_UNBLOCK),
+#endif
+#if defined(SIG_SETMASK) || (defined(HAVE_DECL_SIG_SETMASK) && HAVE_DECL_SIG_SETMASK)
+  XLAT(SIG_SETMASK),
+#endif
+#if defined(SIG_SETMASK32) || (defined(HAVE_DECL_SIG_SETMASK32) && HAVE_DECL_SIG_SETMASK32)
+  XLAT(SIG_SETMASK32),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigprocmaskcmds.in b/strace/xlat/sigprocmaskcmds.in
new file mode 100644
index 0000000..d88a02d
--- /dev/null
+++ b/strace/xlat/sigprocmaskcmds.in
@@ -0,0 +1,4 @@
+SIG_BLOCK
+SIG_UNBLOCK
+SIG_SETMASK
+SIG_SETMASK32
diff --git a/strace/xlat/sigprof_codes.h b/strace/xlat/sigprof_codes.h
new file mode 100644
index 0000000..2323b9e
--- /dev/null
+++ b/strace/xlat/sigprof_codes.h
@@ -0,0 +1,19 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigprof_codes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigprof_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigprof_codes[] = {
+#if defined(PROF_SIG) || (defined(HAVE_DECL_PROF_SIG) && HAVE_DECL_PROF_SIG)
+  XLAT(PROF_SIG),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigprof_codes.in b/strace/xlat/sigprof_codes.in
new file mode 100644
index 0000000..64dac11
--- /dev/null
+++ b/strace/xlat/sigprof_codes.in
@@ -0,0 +1 @@
+PROF_SIG
diff --git a/strace/xlat/sigsegv_codes.h b/strace/xlat/sigsegv_codes.h
new file mode 100644
index 0000000..67034cb
--- /dev/null
+++ b/strace/xlat/sigsegv_codes.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigsegv_codes.in; do not edit. */
+#if !(defined(SEGV_MAPERR) || (defined(HAVE_DECL_SEGV_MAPERR) && HAVE_DECL_SEGV_MAPERR))
+# define SEGV_MAPERR 1
+#endif
+#if !(defined(SEGV_ACCERR) || (defined(HAVE_DECL_SEGV_ACCERR) && HAVE_DECL_SEGV_ACCERR))
+# define SEGV_ACCERR 2
+#endif
+#if !(defined(SEGV_BNDERR) || (defined(HAVE_DECL_SEGV_BNDERR) && HAVE_DECL_SEGV_BNDERR))
+# define SEGV_BNDERR 3
+#endif
+#if !(defined(SEGV_PKUERR) || (defined(HAVE_DECL_SEGV_PKUERR) && HAVE_DECL_SEGV_PKUERR))
+# define SEGV_PKUERR 4
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigsegv_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigsegv_codes[] = {
+ XLAT(SEGV_MAPERR),
+ XLAT(SEGV_ACCERR),
+ XLAT(SEGV_BNDERR),
+ XLAT(SEGV_PKUERR),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigsegv_codes.in b/strace/xlat/sigsegv_codes.in
new file mode 100644
index 0000000..09c1606
--- /dev/null
+++ b/strace/xlat/sigsegv_codes.in
@@ -0,0 +1,4 @@
+SEGV_MAPERR 1
+SEGV_ACCERR 2
+SEGV_BNDERR 3
+SEGV_PKUERR 4
diff --git a/strace/xlat/sigsys_codes.h b/strace/xlat/sigsys_codes.h
new file mode 100644
index 0000000..6fba1fb
--- /dev/null
+++ b/strace/xlat/sigsys_codes.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigsys_codes.in; do not edit. */
+#if !(defined(SYS_SECCOMP) || (defined(HAVE_DECL_SYS_SECCOMP) && HAVE_DECL_SYS_SECCOMP))
+# define SYS_SECCOMP 1
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigsys_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigsys_codes[] = {
+ XLAT(SYS_SECCOMP),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigsys_codes.in b/strace/xlat/sigsys_codes.in
new file mode 100644
index 0000000..a8c4891
--- /dev/null
+++ b/strace/xlat/sigsys_codes.in
@@ -0,0 +1 @@
+SYS_SECCOMP 1
diff --git a/strace/xlat/sigtrap_codes.h b/strace/xlat/sigtrap_codes.h
new file mode 100644
index 0000000..f451dc4
--- /dev/null
+++ b/strace/xlat/sigtrap_codes.h
@@ -0,0 +1,32 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sigtrap_codes.in; do not edit. */
+#if !(defined(TRAP_BRKPT) || (defined(HAVE_DECL_TRAP_BRKPT) && HAVE_DECL_TRAP_BRKPT))
+# define TRAP_BRKPT 1
+#endif
+#if !(defined(TRAP_TRACE) || (defined(HAVE_DECL_TRAP_TRACE) && HAVE_DECL_TRAP_TRACE))
+# define TRAP_TRACE 2
+#endif
+#if !(defined(TRAP_BRANCH) || (defined(HAVE_DECL_TRAP_BRANCH) && HAVE_DECL_TRAP_BRANCH))
+# define TRAP_BRANCH 3
+#endif
+#if !(defined(TRAP_HWBKPT) || (defined(HAVE_DECL_TRAP_HWBKPT) && HAVE_DECL_TRAP_HWBKPT))
+# define TRAP_HWBKPT 4
+#endif
+
+#ifdef IN_MPERS
+
+extern const struct xlat sigtrap_codes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat sigtrap_codes[] = {
+ XLAT(TRAP_BRKPT),
+ XLAT(TRAP_TRACE),
+ XLAT(TRAP_BRANCH),
+ XLAT(TRAP_HWBKPT),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sigtrap_codes.in b/strace/xlat/sigtrap_codes.in
new file mode 100644
index 0000000..078aec8
--- /dev/null
+++ b/strace/xlat/sigtrap_codes.in
@@ -0,0 +1,4 @@
+TRAP_BRKPT 1
+TRAP_TRACE 2
+TRAP_BRANCH 3
+TRAP_HWBKPT 4
diff --git a/strace/xlat/sock_type_flags.h b/strace/xlat/sock_type_flags.h
new file mode 100644
index 0000000..d1af088
--- /dev/null
+++ b/strace/xlat/sock_type_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sock_type_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sock_type_flags in mpers mode
+
+#else
+
+static
+const struct xlat sock_type_flags[] = {
+#if defined(SOCK_CLOEXEC) || (defined(HAVE_DECL_SOCK_CLOEXEC) && HAVE_DECL_SOCK_CLOEXEC)
+  XLAT(SOCK_CLOEXEC),
+#endif
+#if defined(SOCK_NONBLOCK) || (defined(HAVE_DECL_SOCK_NONBLOCK) && HAVE_DECL_SOCK_NONBLOCK)
+  XLAT(SOCK_NONBLOCK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sock_type_flags.in b/strace/xlat/sock_type_flags.in
new file mode 100644
index 0000000..b99786b
--- /dev/null
+++ b/strace/xlat/sock_type_flags.in
@@ -0,0 +1,2 @@
+SOCK_CLOEXEC
+SOCK_NONBLOCK
diff --git a/strace/xlat/socketcalls.h b/strace/xlat/socketcalls.h
new file mode 100644
index 0000000..3680446
--- /dev/null
+++ b/strace/xlat/socketcalls.h
@@ -0,0 +1,94 @@
+/* Generated by ./xlat/gen.sh from ./xlat/socketcalls.in; do not edit. */
+#if !(defined(SYS_SOCKET) || (defined(HAVE_DECL_SYS_SOCKET) && HAVE_DECL_SYS_SOCKET))
+# define SYS_SOCKET 1
+#endif
+#if !(defined(SYS_BIND) || (defined(HAVE_DECL_SYS_BIND) && HAVE_DECL_SYS_BIND))
+# define SYS_BIND 2
+#endif
+#if !(defined(SYS_CONNECT) || (defined(HAVE_DECL_SYS_CONNECT) && HAVE_DECL_SYS_CONNECT))
+# define SYS_CONNECT 3
+#endif
+#if !(defined(SYS_LISTEN) || (defined(HAVE_DECL_SYS_LISTEN) && HAVE_DECL_SYS_LISTEN))
+# define SYS_LISTEN 4
+#endif
+#if !(defined(SYS_ACCEPT) || (defined(HAVE_DECL_SYS_ACCEPT) && HAVE_DECL_SYS_ACCEPT))
+# define SYS_ACCEPT 5
+#endif
+#if !(defined(SYS_GETSOCKNAME) || (defined(HAVE_DECL_SYS_GETSOCKNAME) && HAVE_DECL_SYS_GETSOCKNAME))
+# define SYS_GETSOCKNAME 6
+#endif
+#if !(defined(SYS_GETPEERNAME) || (defined(HAVE_DECL_SYS_GETPEERNAME) && HAVE_DECL_SYS_GETPEERNAME))
+# define SYS_GETPEERNAME 7
+#endif
+#if !(defined(SYS_SOCKETPAIR) || (defined(HAVE_DECL_SYS_SOCKETPAIR) && HAVE_DECL_SYS_SOCKETPAIR))
+# define SYS_SOCKETPAIR 8
+#endif
+#if !(defined(SYS_SEND) || (defined(HAVE_DECL_SYS_SEND) && HAVE_DECL_SYS_SEND))
+# define SYS_SEND 9
+#endif
+#if !(defined(SYS_RECV) || (defined(HAVE_DECL_SYS_RECV) && HAVE_DECL_SYS_RECV))
+# define SYS_RECV 10
+#endif
+#if !(defined(SYS_SENDTO) || (defined(HAVE_DECL_SYS_SENDTO) && HAVE_DECL_SYS_SENDTO))
+# define SYS_SENDTO 11
+#endif
+#if !(defined(SYS_RECVFROM) || (defined(HAVE_DECL_SYS_RECVFROM) && HAVE_DECL_SYS_RECVFROM))
+# define SYS_RECVFROM 12
+#endif
+#if !(defined(SYS_SHUTDOWN) || (defined(HAVE_DECL_SYS_SHUTDOWN) && HAVE_DECL_SYS_SHUTDOWN))
+# define SYS_SHUTDOWN 13
+#endif
+#if !(defined(SYS_SETSOCKOPT) || (defined(HAVE_DECL_SYS_SETSOCKOPT) && HAVE_DECL_SYS_SETSOCKOPT))
+# define SYS_SETSOCKOPT 14
+#endif
+#if !(defined(SYS_GETSOCKOPT) || (defined(HAVE_DECL_SYS_GETSOCKOPT) && HAVE_DECL_SYS_GETSOCKOPT))
+# define SYS_GETSOCKOPT 15
+#endif
+#if !(defined(SYS_SENDMSG) || (defined(HAVE_DECL_SYS_SENDMSG) && HAVE_DECL_SYS_SENDMSG))
+# define SYS_SENDMSG 16
+#endif
+#if !(defined(SYS_RECVMSG) || (defined(HAVE_DECL_SYS_RECVMSG) && HAVE_DECL_SYS_RECVMSG))
+# define SYS_RECVMSG 17
+#endif
+#if !(defined(SYS_ACCEPT4) || (defined(HAVE_DECL_SYS_ACCEPT4) && HAVE_DECL_SYS_ACCEPT4))
+# define SYS_ACCEPT4 18
+#endif
+#if !(defined(SYS_RECVMMSG) || (defined(HAVE_DECL_SYS_RECVMMSG) && HAVE_DECL_SYS_RECVMMSG))
+# define SYS_RECVMMSG 19
+#endif
+#if !(defined(SYS_SENDMMSG) || (defined(HAVE_DECL_SYS_SENDMMSG) && HAVE_DECL_SYS_SENDMMSG))
+# define SYS_SENDMMSG 20
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat socketcalls in mpers mode
+
+#else
+
+static
+const struct xlat socketcalls[] = {
+ XLAT(SYS_SOCKET),
+ XLAT(SYS_BIND),
+ XLAT(SYS_CONNECT),
+ XLAT(SYS_LISTEN),
+ XLAT(SYS_ACCEPT),
+ XLAT(SYS_GETSOCKNAME),
+ XLAT(SYS_GETPEERNAME),
+ XLAT(SYS_SOCKETPAIR),
+ XLAT(SYS_SEND),
+ XLAT(SYS_RECV),
+ XLAT(SYS_SENDTO),
+ XLAT(SYS_RECVFROM),
+ XLAT(SYS_SHUTDOWN),
+ XLAT(SYS_SETSOCKOPT),
+ XLAT(SYS_GETSOCKOPT),
+ XLAT(SYS_SENDMSG),
+ XLAT(SYS_RECVMSG),
+ XLAT(SYS_ACCEPT4),
+ XLAT(SYS_RECVMMSG),
+ XLAT(SYS_SENDMMSG),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/socketcalls.in b/strace/xlat/socketcalls.in
new file mode 100644
index 0000000..3ffeb6f
--- /dev/null
+++ b/strace/xlat/socketcalls.in
@@ -0,0 +1,20 @@
+SYS_SOCKET	1
+SYS_BIND	2
+SYS_CONNECT	3
+SYS_LISTEN	4
+SYS_ACCEPT	5
+SYS_GETSOCKNAME	6
+SYS_GETPEERNAME	7
+SYS_SOCKETPAIR	8
+SYS_SEND	9
+SYS_RECV	10
+SYS_SENDTO	11
+SYS_RECVFROM	12
+SYS_SHUTDOWN	13
+SYS_SETSOCKOPT	14
+SYS_GETSOCKOPT	15
+SYS_SENDMSG	16
+SYS_RECVMSG	17
+SYS_ACCEPT4	18
+SYS_RECVMMSG	19
+SYS_SENDMMSG	20
diff --git a/strace/xlat/socketlayers.h b/strace/xlat/socketlayers.h
new file mode 100644
index 0000000..5e486c3
--- /dev/null
+++ b/strace/xlat/socketlayers.h
@@ -0,0 +1,149 @@
+/* Generated by ./xlat/gen.sh from ./xlat/socketlayers.in; do not edit. */
+#if !(defined(SOL_IP) || (defined(HAVE_DECL_SOL_IP) && HAVE_DECL_SOL_IP))
+# define SOL_IP 0
+#endif
+#if !(defined(SOL_SOCKET) || (defined(HAVE_DECL_SOL_SOCKET) && HAVE_DECL_SOL_SOCKET))
+# define SOL_SOCKET 1
+#endif
+#if !(defined(SOL_TCP) || (defined(HAVE_DECL_SOL_TCP) && HAVE_DECL_SOL_TCP))
+# define SOL_TCP 6
+#endif
+#if !(defined(SOL_UDP) || (defined(HAVE_DECL_SOL_UDP) && HAVE_DECL_SOL_UDP))
+# define SOL_UDP 17
+#endif
+#if !(defined(SOL_IPV6) || (defined(HAVE_DECL_SOL_IPV6) && HAVE_DECL_SOL_IPV6))
+# define SOL_IPV6 41
+#endif
+#if !(defined(SOL_ICMPV6) || (defined(HAVE_DECL_SOL_ICMPV6) && HAVE_DECL_SOL_ICMPV6))
+# define SOL_ICMPV6 58
+#endif
+#if !(defined(SOL_SCTP) || (defined(HAVE_DECL_SOL_SCTP) && HAVE_DECL_SOL_SCTP))
+# define SOL_SCTP 132
+#endif
+#if !(defined(SOL_UDPLITE) || (defined(HAVE_DECL_SOL_UDPLITE) && HAVE_DECL_SOL_UDPLITE))
+# define SOL_UDPLITE 136
+#endif
+#if !(defined(SOL_RAW) || (defined(HAVE_DECL_SOL_RAW) && HAVE_DECL_SOL_RAW))
+# define SOL_RAW 255
+#endif
+#if !(defined(SOL_IPX) || (defined(HAVE_DECL_SOL_IPX) && HAVE_DECL_SOL_IPX))
+# define SOL_IPX 256
+#endif
+#if !(defined(SOL_AX25) || (defined(HAVE_DECL_SOL_AX25) && HAVE_DECL_SOL_AX25))
+# define SOL_AX25 257
+#endif
+#if !(defined(SOL_ATALK) || (defined(HAVE_DECL_SOL_ATALK) && HAVE_DECL_SOL_ATALK))
+# define SOL_ATALK 258
+#endif
+#if !(defined(SOL_NETROM) || (defined(HAVE_DECL_SOL_NETROM) && HAVE_DECL_SOL_NETROM))
+# define SOL_NETROM 259
+#endif
+#if !(defined(SOL_ROSE) || (defined(HAVE_DECL_SOL_ROSE) && HAVE_DECL_SOL_ROSE))
+# define SOL_ROSE 260
+#endif
+#if !(defined(SOL_DECNET) || (defined(HAVE_DECL_SOL_DECNET) && HAVE_DECL_SOL_DECNET))
+# define SOL_DECNET 261
+#endif
+#if !(defined(SOL_X25) || (defined(HAVE_DECL_SOL_X25) && HAVE_DECL_SOL_X25))
+# define SOL_X25 262
+#endif
+#if !(defined(SOL_PACKET) || (defined(HAVE_DECL_SOL_PACKET) && HAVE_DECL_SOL_PACKET))
+# define SOL_PACKET 263
+#endif
+#if !(defined(SOL_ATM) || (defined(HAVE_DECL_SOL_ATM) && HAVE_DECL_SOL_ATM))
+# define SOL_ATM 264
+#endif
+#if !(defined(SOL_AAL) || (defined(HAVE_DECL_SOL_AAL) && HAVE_DECL_SOL_AAL))
+# define SOL_AAL 265
+#endif
+#if !(defined(SOL_IRDA) || (defined(HAVE_DECL_SOL_IRDA) && HAVE_DECL_SOL_IRDA))
+# define SOL_IRDA 266
+#endif
+#if !(defined(SOL_NETBEUI) || (defined(HAVE_DECL_SOL_NETBEUI) && HAVE_DECL_SOL_NETBEUI))
+# define SOL_NETBEUI 267
+#endif
+#if !(defined(SOL_LLC) || (defined(HAVE_DECL_SOL_LLC) && HAVE_DECL_SOL_LLC))
+# define SOL_LLC 268
+#endif
+#if !(defined(SOL_DCCP) || (defined(HAVE_DECL_SOL_DCCP) && HAVE_DECL_SOL_DCCP))
+# define SOL_DCCP 269
+#endif
+#if !(defined(SOL_NETLINK) || (defined(HAVE_DECL_SOL_NETLINK) && HAVE_DECL_SOL_NETLINK))
+# define SOL_NETLINK 270
+#endif
+#if !(defined(SOL_TIPC) || (defined(HAVE_DECL_SOL_TIPC) && HAVE_DECL_SOL_TIPC))
+# define SOL_TIPC 271
+#endif
+#if !(defined(SOL_RXRPC) || (defined(HAVE_DECL_SOL_RXRPC) && HAVE_DECL_SOL_RXRPC))
+# define SOL_RXRPC 272
+#endif
+#if !(defined(SOL_PPPOL2TP) || (defined(HAVE_DECL_SOL_PPPOL2TP) && HAVE_DECL_SOL_PPPOL2TP))
+# define SOL_PPPOL2TP 273
+#endif
+#if !(defined(SOL_BLUETOOTH) || (defined(HAVE_DECL_SOL_BLUETOOTH) && HAVE_DECL_SOL_BLUETOOTH))
+# define SOL_BLUETOOTH 274
+#endif
+#if !(defined(SOL_PNPIPE) || (defined(HAVE_DECL_SOL_PNPIPE) && HAVE_DECL_SOL_PNPIPE))
+# define SOL_PNPIPE 275
+#endif
+#if !(defined(SOL_RDS) || (defined(HAVE_DECL_SOL_RDS) && HAVE_DECL_SOL_RDS))
+# define SOL_RDS 276
+#endif
+#if !(defined(SOL_IUCV) || (defined(HAVE_DECL_SOL_IUCV) && HAVE_DECL_SOL_IUCV))
+# define SOL_IUCV 277
+#endif
+#if !(defined(SOL_CAIF) || (defined(HAVE_DECL_SOL_CAIF) && HAVE_DECL_SOL_CAIF))
+# define SOL_CAIF 278
+#endif
+#if !(defined(SOL_ALG) || (defined(HAVE_DECL_SOL_ALG) && HAVE_DECL_SOL_ALG))
+# define SOL_ALG 279
+#endif
+#if !(defined(SOL_NFC) || (defined(HAVE_DECL_SOL_NFC) && HAVE_DECL_SOL_NFC))
+# define SOL_NFC 280
+#endif
+#if !(defined(SOL_KCM) || (defined(HAVE_DECL_SOL_KCM) && HAVE_DECL_SOL_KCM))
+# define SOL_KCM 281
+#endif
+
+#ifndef IN_MPERS
+
+const struct xlat socketlayers[] = {
+ XLAT(SOL_IP),
+ XLAT(SOL_SOCKET),
+ XLAT(SOL_TCP),
+ XLAT(SOL_UDP),
+ XLAT(SOL_IPV6),
+ XLAT(SOL_ICMPV6),
+ XLAT(SOL_SCTP),
+ XLAT(SOL_UDPLITE),
+ XLAT(SOL_RAW),
+ XLAT(SOL_IPX),
+ XLAT(SOL_AX25),
+ XLAT(SOL_ATALK),
+ XLAT(SOL_NETROM),
+ XLAT(SOL_ROSE),
+ XLAT(SOL_DECNET),
+ XLAT(SOL_X25),
+ XLAT(SOL_PACKET),
+ XLAT(SOL_ATM),
+ XLAT(SOL_AAL),
+ XLAT(SOL_IRDA),
+ XLAT(SOL_NETBEUI),
+ XLAT(SOL_LLC),
+ XLAT(SOL_DCCP),
+ XLAT(SOL_NETLINK),
+ XLAT(SOL_TIPC),
+ XLAT(SOL_RXRPC),
+ XLAT(SOL_PPPOL2TP),
+ XLAT(SOL_BLUETOOTH),
+ XLAT(SOL_PNPIPE),
+ XLAT(SOL_RDS),
+ XLAT(SOL_IUCV),
+ XLAT(SOL_CAIF),
+ XLAT(SOL_ALG),
+ XLAT(SOL_NFC),
+ XLAT(SOL_KCM),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/socketlayers.in b/strace/xlat/socketlayers.in
new file mode 100644
index 0000000..7b0b86e
--- /dev/null
+++ b/strace/xlat/socketlayers.in
@@ -0,0 +1,35 @@
+SOL_IP		0
+SOL_SOCKET	1
+SOL_TCP		6
+SOL_UDP		17
+SOL_IPV6	41
+SOL_ICMPV6	58
+SOL_SCTP	132
+SOL_UDPLITE	136
+SOL_RAW		255
+SOL_IPX		256
+SOL_AX25	257
+SOL_ATALK	258
+SOL_NETROM	259
+SOL_ROSE	260
+SOL_DECNET	261
+SOL_X25		262
+SOL_PACKET	263
+SOL_ATM		264
+SOL_AAL		265
+SOL_IRDA	266
+SOL_NETBEUI	267
+SOL_LLC		268
+SOL_DCCP	269
+SOL_NETLINK	270
+SOL_TIPC	271
+SOL_RXRPC	272
+SOL_PPPOL2TP	273
+SOL_BLUETOOTH	274
+SOL_PNPIPE	275
+SOL_RDS		276
+SOL_IUCV	277
+SOL_CAIF	278
+SOL_ALG		279
+SOL_NFC		280
+SOL_KCM		281
diff --git a/strace/xlat/sockipoptions.h b/strace/xlat/sockipoptions.h
new file mode 100644
index 0000000..7a75f87
--- /dev/null
+++ b/strace/xlat/sockipoptions.h
@@ -0,0 +1,161 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sockipoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sockipoptions in mpers mode
+
+#else
+
+static
+const struct xlat sockipoptions[] = {
+#if defined(IP_TOS) || (defined(HAVE_DECL_IP_TOS) && HAVE_DECL_IP_TOS)
+  XLAT(IP_TOS),
+#endif
+#if defined(IP_TTL) || (defined(HAVE_DECL_IP_TTL) && HAVE_DECL_IP_TTL)
+  XLAT(IP_TTL),
+#endif
+#if defined(IP_HDRINCL) || (defined(HAVE_DECL_IP_HDRINCL) && HAVE_DECL_IP_HDRINCL)
+  XLAT(IP_HDRINCL),
+#endif
+#if defined(IP_OPTIONS) || (defined(HAVE_DECL_IP_OPTIONS) && HAVE_DECL_IP_OPTIONS)
+  XLAT(IP_OPTIONS),
+#endif
+#if defined(IP_ROUTER_ALERT) || (defined(HAVE_DECL_IP_ROUTER_ALERT) && HAVE_DECL_IP_ROUTER_ALERT)
+  XLAT(IP_ROUTER_ALERT),
+#endif
+#if defined(IP_RECVOPTIONS) || (defined(HAVE_DECL_IP_RECVOPTIONS) && HAVE_DECL_IP_RECVOPTIONS)
+  XLAT(IP_RECVOPTIONS),
+#endif
+#if defined(IP_RECVOPTS) || (defined(HAVE_DECL_IP_RECVOPTS) && HAVE_DECL_IP_RECVOPTS)
+  XLAT(IP_RECVOPTS),
+#endif
+#if defined(IP_RETOPTS) || (defined(HAVE_DECL_IP_RETOPTS) && HAVE_DECL_IP_RETOPTS)
+  XLAT(IP_RETOPTS),
+#endif
+#if defined(IP_RECVRETOPTS) || (defined(HAVE_DECL_IP_RECVRETOPTS) && HAVE_DECL_IP_RECVRETOPTS)
+  XLAT(IP_RECVRETOPTS),
+#endif
+#if defined(IP_RECVDSTADDR) || (defined(HAVE_DECL_IP_RECVDSTADDR) && HAVE_DECL_IP_RECVDSTADDR)
+  XLAT(IP_RECVDSTADDR),
+#endif
+#if defined(IP_PKTINFO) || (defined(HAVE_DECL_IP_PKTINFO) && HAVE_DECL_IP_PKTINFO)
+  XLAT(IP_PKTINFO),
+#endif
+#if defined(IP_PKTOPTIONS) || (defined(HAVE_DECL_IP_PKTOPTIONS) && HAVE_DECL_IP_PKTOPTIONS)
+  XLAT(IP_PKTOPTIONS),
+#endif
+#if defined(IP_MTU_DISCOVER) || (defined(HAVE_DECL_IP_MTU_DISCOVER) && HAVE_DECL_IP_MTU_DISCOVER)
+  XLAT(IP_MTU_DISCOVER),
+#endif
+#if defined(IP_RECVERR) || (defined(HAVE_DECL_IP_RECVERR) && HAVE_DECL_IP_RECVERR)
+  XLAT(IP_RECVERR),
+#endif
+#if defined(IP_RECVTTL) || (defined(HAVE_DECL_IP_RECVTTL) && HAVE_DECL_IP_RECVTTL)
+  XLAT(IP_RECVTTL),
+#endif
+#if defined(IP_RECVTOS) || (defined(HAVE_DECL_IP_RECVTOS) && HAVE_DECL_IP_RECVTOS)
+  XLAT(IP_RECVTOS),
+#endif
+#if defined(IP_MTU) || (defined(HAVE_DECL_IP_MTU) && HAVE_DECL_IP_MTU)
+  XLAT(IP_MTU),
+#endif
+#if defined(IP_MULTICAST_IF) || (defined(HAVE_DECL_IP_MULTICAST_IF) && HAVE_DECL_IP_MULTICAST_IF)
+  XLAT(IP_MULTICAST_IF),
+#endif
+#if defined(IP_MULTICAST_TTL) || (defined(HAVE_DECL_IP_MULTICAST_TTL) && HAVE_DECL_IP_MULTICAST_TTL)
+  XLAT(IP_MULTICAST_TTL),
+#endif
+#if defined(IP_MULTICAST_LOOP) || (defined(HAVE_DECL_IP_MULTICAST_LOOP) && HAVE_DECL_IP_MULTICAST_LOOP)
+  XLAT(IP_MULTICAST_LOOP),
+#endif
+#if defined(IP_ADD_MEMBERSHIP) || (defined(HAVE_DECL_IP_ADD_MEMBERSHIP) && HAVE_DECL_IP_ADD_MEMBERSHIP)
+  XLAT(IP_ADD_MEMBERSHIP),
+#endif
+#if defined(IP_DROP_MEMBERSHIP) || (defined(HAVE_DECL_IP_DROP_MEMBERSHIP) && HAVE_DECL_IP_DROP_MEMBERSHIP)
+  XLAT(IP_DROP_MEMBERSHIP),
+#endif
+#if defined(IP_BROADCAST_IF) || (defined(HAVE_DECL_IP_BROADCAST_IF) && HAVE_DECL_IP_BROADCAST_IF)
+  XLAT(IP_BROADCAST_IF),
+#endif
+#if defined(IP_RECVIFINDEX) || (defined(HAVE_DECL_IP_RECVIFINDEX) && HAVE_DECL_IP_RECVIFINDEX)
+  XLAT(IP_RECVIFINDEX),
+#endif
+#if defined(IP_MSFILTER) || (defined(HAVE_DECL_IP_MSFILTER) && HAVE_DECL_IP_MSFILTER)
+  XLAT(IP_MSFILTER),
+#endif
+#if defined(IP_FREEBIND) || (defined(HAVE_DECL_IP_FREEBIND) && HAVE_DECL_IP_FREEBIND)
+  XLAT(IP_FREEBIND),
+#endif
+#if defined(IP_IPSEC_POLICY) || (defined(HAVE_DECL_IP_IPSEC_POLICY) && HAVE_DECL_IP_IPSEC_POLICY)
+  XLAT(IP_IPSEC_POLICY),
+#endif
+#if defined(IP_XFRM_POLICY) || (defined(HAVE_DECL_IP_XFRM_POLICY) && HAVE_DECL_IP_XFRM_POLICY)
+  XLAT(IP_XFRM_POLICY),
+#endif
+#if defined(IP_PASSSEC) || (defined(HAVE_DECL_IP_PASSSEC) && HAVE_DECL_IP_PASSSEC)
+  XLAT(IP_PASSSEC),
+#endif
+#if defined(IP_TRANSPARENT) || (defined(HAVE_DECL_IP_TRANSPARENT) && HAVE_DECL_IP_TRANSPARENT)
+  XLAT(IP_TRANSPARENT),
+#endif
+#if defined(IP_ORIGDSTADDR) || (defined(HAVE_DECL_IP_ORIGDSTADDR) && HAVE_DECL_IP_ORIGDSTADDR)
+  XLAT(IP_ORIGDSTADDR),
+#endif
+#if defined(IP_RECVORIGDSTADDR) || (defined(HAVE_DECL_IP_RECVORIGDSTADDR) && HAVE_DECL_IP_RECVORIGDSTADDR)
+  XLAT(IP_RECVORIGDSTADDR),
+#endif
+#if defined(IP_MINTTL) || (defined(HAVE_DECL_IP_MINTTL) && HAVE_DECL_IP_MINTTL)
+  XLAT(IP_MINTTL),
+#endif
+#if defined(IP_NODEFRAG) || (defined(HAVE_DECL_IP_NODEFRAG) && HAVE_DECL_IP_NODEFRAG)
+  XLAT(IP_NODEFRAG),
+#endif
+#if defined(IP_CHECKSUM) || (defined(HAVE_DECL_IP_CHECKSUM) && HAVE_DECL_IP_CHECKSUM)
+  XLAT(IP_CHECKSUM),
+#endif
+#if defined(IP_BIND_ADDRESS_NO_PORT) || (defined(HAVE_DECL_IP_BIND_ADDRESS_NO_PORT) && HAVE_DECL_IP_BIND_ADDRESS_NO_PORT)
+  XLAT(IP_BIND_ADDRESS_NO_PORT),
+#endif
+#if defined(IP_UNBLOCK_SOURCE) || (defined(HAVE_DECL_IP_UNBLOCK_SOURCE) && HAVE_DECL_IP_UNBLOCK_SOURCE)
+  XLAT(IP_UNBLOCK_SOURCE),
+#endif
+#if defined(IP_BLOCK_SOURCE) || (defined(HAVE_DECL_IP_BLOCK_SOURCE) && HAVE_DECL_IP_BLOCK_SOURCE)
+  XLAT(IP_BLOCK_SOURCE),
+#endif
+#if defined(IP_ADD_SOURCE_MEMBERSHIP) || (defined(HAVE_DECL_IP_ADD_SOURCE_MEMBERSHIP) && HAVE_DECL_IP_ADD_SOURCE_MEMBERSHIP)
+  XLAT(IP_ADD_SOURCE_MEMBERSHIP),
+#endif
+#if defined(IP_DROP_SOURCE_MEMBERSHIP) || (defined(HAVE_DECL_IP_DROP_SOURCE_MEMBERSHIP) && HAVE_DECL_IP_DROP_SOURCE_MEMBERSHIP)
+  XLAT(IP_DROP_SOURCE_MEMBERSHIP),
+#endif
+#if defined(MCAST_JOIN_GROUP) || (defined(HAVE_DECL_MCAST_JOIN_GROUP) && HAVE_DECL_MCAST_JOIN_GROUP)
+  XLAT(MCAST_JOIN_GROUP),
+#endif
+#if defined(MCAST_BLOCK_SOURCE) || (defined(HAVE_DECL_MCAST_BLOCK_SOURCE) && HAVE_DECL_MCAST_BLOCK_SOURCE)
+  XLAT(MCAST_BLOCK_SOURCE),
+#endif
+#if defined(MCAST_UNBLOCK_SOURCE) || (defined(HAVE_DECL_MCAST_UNBLOCK_SOURCE) && HAVE_DECL_MCAST_UNBLOCK_SOURCE)
+  XLAT(MCAST_UNBLOCK_SOURCE),
+#endif
+#if defined(MCAST_LEAVE_GROUP) || (defined(HAVE_DECL_MCAST_LEAVE_GROUP) && HAVE_DECL_MCAST_LEAVE_GROUP)
+  XLAT(MCAST_LEAVE_GROUP),
+#endif
+#if defined(MCAST_JOIN_SOURCE_GROUP) || (defined(HAVE_DECL_MCAST_JOIN_SOURCE_GROUP) && HAVE_DECL_MCAST_JOIN_SOURCE_GROUP)
+  XLAT(MCAST_JOIN_SOURCE_GROUP),
+#endif
+#if defined(MCAST_LEAVE_SOURCE_GROUP) || (defined(HAVE_DECL_MCAST_LEAVE_SOURCE_GROUP) && HAVE_DECL_MCAST_LEAVE_SOURCE_GROUP)
+  XLAT(MCAST_LEAVE_SOURCE_GROUP),
+#endif
+#if defined(MCAST_MSFILTER) || (defined(HAVE_DECL_MCAST_MSFILTER) && HAVE_DECL_MCAST_MSFILTER)
+  XLAT(MCAST_MSFILTER),
+#endif
+#if defined(IP_MULTICAST_ALL) || (defined(HAVE_DECL_IP_MULTICAST_ALL) && HAVE_DECL_IP_MULTICAST_ALL)
+  XLAT(IP_MULTICAST_ALL),
+#endif
+#if defined(IP_UNICAST_IF) || (defined(HAVE_DECL_IP_UNICAST_IF) && HAVE_DECL_IP_UNICAST_IF)
+  XLAT(IP_UNICAST_IF),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sockipoptions.in b/strace/xlat/sockipoptions.in
new file mode 100644
index 0000000..aa78532
--- /dev/null
+++ b/strace/xlat/sockipoptions.in
@@ -0,0 +1,49 @@
+IP_TOS
+IP_TTL
+IP_HDRINCL
+IP_OPTIONS
+IP_ROUTER_ALERT
+IP_RECVOPTIONS
+IP_RECVOPTS
+IP_RETOPTS
+IP_RECVRETOPTS
+IP_RECVDSTADDR
+IP_PKTINFO
+IP_PKTOPTIONS
+IP_MTU_DISCOVER
+IP_RECVERR
+IP_RECVTTL
+IP_RECVTOS
+IP_MTU
+IP_MULTICAST_IF
+IP_MULTICAST_TTL
+IP_MULTICAST_LOOP
+IP_ADD_MEMBERSHIP
+IP_DROP_MEMBERSHIP
+IP_BROADCAST_IF
+IP_RECVIFINDEX
+IP_MSFILTER
+IP_FREEBIND
+IP_IPSEC_POLICY
+IP_XFRM_POLICY
+IP_PASSSEC
+IP_TRANSPARENT
+IP_ORIGDSTADDR
+IP_RECVORIGDSTADDR
+IP_MINTTL
+IP_NODEFRAG
+IP_CHECKSUM
+IP_BIND_ADDRESS_NO_PORT
+IP_UNBLOCK_SOURCE
+IP_BLOCK_SOURCE
+IP_ADD_SOURCE_MEMBERSHIP
+IP_DROP_SOURCE_MEMBERSHIP
+MCAST_JOIN_GROUP
+MCAST_BLOCK_SOURCE
+MCAST_UNBLOCK_SOURCE
+MCAST_LEAVE_GROUP
+MCAST_JOIN_SOURCE_GROUP
+MCAST_LEAVE_SOURCE_GROUP
+MCAST_MSFILTER
+IP_MULTICAST_ALL
+IP_UNICAST_IF
diff --git a/strace/xlat/sockipv6options.h b/strace/xlat/sockipv6options.h
new file mode 100644
index 0000000..ee7ed6f
--- /dev/null
+++ b/strace/xlat/sockipv6options.h
@@ -0,0 +1,173 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sockipv6options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sockipv6options in mpers mode
+
+#else
+
+static
+const struct xlat sockipv6options[] = {
+#if defined(IPV6_ADDRFORM) || (defined(HAVE_DECL_IPV6_ADDRFORM) && HAVE_DECL_IPV6_ADDRFORM)
+  XLAT(IPV6_ADDRFORM),
+#endif
+#if defined(IPV6_2292PKTINFO) || (defined(HAVE_DECL_IPV6_2292PKTINFO) && HAVE_DECL_IPV6_2292PKTINFO)
+  XLAT(IPV6_2292PKTINFO),
+#endif
+#if defined(IPV6_2292HOPOPTS) || (defined(HAVE_DECL_IPV6_2292HOPOPTS) && HAVE_DECL_IPV6_2292HOPOPTS)
+  XLAT(IPV6_2292HOPOPTS),
+#endif
+#if defined(IPV6_2292DSTOPTS) || (defined(HAVE_DECL_IPV6_2292DSTOPTS) && HAVE_DECL_IPV6_2292DSTOPTS)
+  XLAT(IPV6_2292DSTOPTS),
+#endif
+#if defined(IPV6_2292RTHDR) || (defined(HAVE_DECL_IPV6_2292RTHDR) && HAVE_DECL_IPV6_2292RTHDR)
+  XLAT(IPV6_2292RTHDR),
+#endif
+#if defined(IPV6_2292PKTOPTIONS) || (defined(HAVE_DECL_IPV6_2292PKTOPTIONS) && HAVE_DECL_IPV6_2292PKTOPTIONS)
+  XLAT(IPV6_2292PKTOPTIONS),
+#endif
+#if defined(IPV6_CHECKSUM) || (defined(HAVE_DECL_IPV6_CHECKSUM) && HAVE_DECL_IPV6_CHECKSUM)
+  XLAT(IPV6_CHECKSUM),
+#endif
+#if defined(IPV6_2292HOPLIMIT) || (defined(HAVE_DECL_IPV6_2292HOPLIMIT) && HAVE_DECL_IPV6_2292HOPLIMIT)
+  XLAT(IPV6_2292HOPLIMIT),
+#endif
+#if defined(IPV6_NEXTHOP) || (defined(HAVE_DECL_IPV6_NEXTHOP) && HAVE_DECL_IPV6_NEXTHOP)
+  XLAT(IPV6_NEXTHOP),
+#endif
+#if defined(IPV6_AUTHHDR) || (defined(HAVE_DECL_IPV6_AUTHHDR) && HAVE_DECL_IPV6_AUTHHDR)
+  XLAT(IPV6_AUTHHDR),
+#endif
+#if defined(IPV6_FLOWINFO) || (defined(HAVE_DECL_IPV6_FLOWINFO) && HAVE_DECL_IPV6_FLOWINFO)
+  XLAT(IPV6_FLOWINFO),
+#endif
+#if defined(IPV6_UNICAST_HOPS) || (defined(HAVE_DECL_IPV6_UNICAST_HOPS) && HAVE_DECL_IPV6_UNICAST_HOPS)
+  XLAT(IPV6_UNICAST_HOPS),
+#endif
+#if defined(IPV6_MULTICAST_IF) || (defined(HAVE_DECL_IPV6_MULTICAST_IF) && HAVE_DECL_IPV6_MULTICAST_IF)
+  XLAT(IPV6_MULTICAST_IF),
+#endif
+#if defined(IPV6_MULTICAST_HOPS) || (defined(HAVE_DECL_IPV6_MULTICAST_HOPS) && HAVE_DECL_IPV6_MULTICAST_HOPS)
+  XLAT(IPV6_MULTICAST_HOPS),
+#endif
+#if defined(IPV6_MULTICAST_LOOP) || (defined(HAVE_DECL_IPV6_MULTICAST_LOOP) && HAVE_DECL_IPV6_MULTICAST_LOOP)
+  XLAT(IPV6_MULTICAST_LOOP),
+#endif
+#if defined(IPV6_ADD_MEMBERSHIP) || (defined(HAVE_DECL_IPV6_ADD_MEMBERSHIP) && HAVE_DECL_IPV6_ADD_MEMBERSHIP)
+  XLAT(IPV6_ADD_MEMBERSHIP),
+#endif
+#if defined(IPV6_DROP_MEMBERSHIP) || (defined(HAVE_DECL_IPV6_DROP_MEMBERSHIP) && HAVE_DECL_IPV6_DROP_MEMBERSHIP)
+  XLAT(IPV6_DROP_MEMBERSHIP),
+#endif
+#if defined(IPV6_ROUTER_ALERT) || (defined(HAVE_DECL_IPV6_ROUTER_ALERT) && HAVE_DECL_IPV6_ROUTER_ALERT)
+  XLAT(IPV6_ROUTER_ALERT),
+#endif
+#if defined(IPV6_MTU_DISCOVER) || (defined(HAVE_DECL_IPV6_MTU_DISCOVER) && HAVE_DECL_IPV6_MTU_DISCOVER)
+  XLAT(IPV6_MTU_DISCOVER),
+#endif
+#if defined(IPV6_MTU) || (defined(HAVE_DECL_IPV6_MTU) && HAVE_DECL_IPV6_MTU)
+  XLAT(IPV6_MTU),
+#endif
+#if defined(IPV6_RECVERR) || (defined(HAVE_DECL_IPV6_RECVERR) && HAVE_DECL_IPV6_RECVERR)
+  XLAT(IPV6_RECVERR),
+#endif
+#if defined(IPV6_V6ONLY) || (defined(HAVE_DECL_IPV6_V6ONLY) && HAVE_DECL_IPV6_V6ONLY)
+  XLAT(IPV6_V6ONLY),
+#endif
+#if defined(IPV6_JOIN_ANYCAST) || (defined(HAVE_DECL_IPV6_JOIN_ANYCAST) && HAVE_DECL_IPV6_JOIN_ANYCAST)
+  XLAT(IPV6_JOIN_ANYCAST),
+#endif
+#if defined(IPV6_LEAVE_ANYCAST) || (defined(HAVE_DECL_IPV6_LEAVE_ANYCAST) && HAVE_DECL_IPV6_LEAVE_ANYCAST)
+  XLAT(IPV6_LEAVE_ANYCAST),
+#endif
+#if defined(IPV6_FLOWLABEL_MGR) || (defined(HAVE_DECL_IPV6_FLOWLABEL_MGR) && HAVE_DECL_IPV6_FLOWLABEL_MGR)
+  XLAT(IPV6_FLOWLABEL_MGR),
+#endif
+#if defined(IPV6_FLOWINFO_SEND) || (defined(HAVE_DECL_IPV6_FLOWINFO_SEND) && HAVE_DECL_IPV6_FLOWINFO_SEND)
+  XLAT(IPV6_FLOWINFO_SEND),
+#endif
+#if defined(IPV6_IPSEC_POLICY) || (defined(HAVE_DECL_IPV6_IPSEC_POLICY) && HAVE_DECL_IPV6_IPSEC_POLICY)
+  XLAT(IPV6_IPSEC_POLICY),
+#endif
+#if defined(IPV6_XFRM_POLICY) || (defined(HAVE_DECL_IPV6_XFRM_POLICY) && HAVE_DECL_IPV6_XFRM_POLICY)
+  XLAT(IPV6_XFRM_POLICY),
+#endif
+#if defined(IPV6_HDRINCL) || (defined(HAVE_DECL_IPV6_HDRINCL) && HAVE_DECL_IPV6_HDRINCL)
+  XLAT(IPV6_HDRINCL),
+#endif
+#if defined(IPV6_RECVPKTINFO) || (defined(HAVE_DECL_IPV6_RECVPKTINFO) && HAVE_DECL_IPV6_RECVPKTINFO)
+  XLAT(IPV6_RECVPKTINFO),
+#endif
+#if defined(IPV6_PKTINFO) || (defined(HAVE_DECL_IPV6_PKTINFO) && HAVE_DECL_IPV6_PKTINFO)
+  XLAT(IPV6_PKTINFO),
+#endif
+#if defined(IPV6_RECVHOPLIMIT) || (defined(HAVE_DECL_IPV6_RECVHOPLIMIT) && HAVE_DECL_IPV6_RECVHOPLIMIT)
+  XLAT(IPV6_RECVHOPLIMIT),
+#endif
+#if defined(IPV6_HOPLIMIT) || (defined(HAVE_DECL_IPV6_HOPLIMIT) && HAVE_DECL_IPV6_HOPLIMIT)
+  XLAT(IPV6_HOPLIMIT),
+#endif
+#if defined(IPV6_RECVHOPOPTS) || (defined(HAVE_DECL_IPV6_RECVHOPOPTS) && HAVE_DECL_IPV6_RECVHOPOPTS)
+  XLAT(IPV6_RECVHOPOPTS),
+#endif
+#if defined(IPV6_HOPOPTS) || (defined(HAVE_DECL_IPV6_HOPOPTS) && HAVE_DECL_IPV6_HOPOPTS)
+  XLAT(IPV6_HOPOPTS),
+#endif
+#if defined(IPV6_RTHDRDSTOPTS) || (defined(HAVE_DECL_IPV6_RTHDRDSTOPTS) && HAVE_DECL_IPV6_RTHDRDSTOPTS)
+  XLAT(IPV6_RTHDRDSTOPTS),
+#endif
+#if defined(IPV6_RECVRTHDR) || (defined(HAVE_DECL_IPV6_RECVRTHDR) && HAVE_DECL_IPV6_RECVRTHDR)
+  XLAT(IPV6_RECVRTHDR),
+#endif
+#if defined(IPV6_RTHDR) || (defined(HAVE_DECL_IPV6_RTHDR) && HAVE_DECL_IPV6_RTHDR)
+  XLAT(IPV6_RTHDR),
+#endif
+#if defined(IPV6_RECVDSTOPTS) || (defined(HAVE_DECL_IPV6_RECVDSTOPTS) && HAVE_DECL_IPV6_RECVDSTOPTS)
+  XLAT(IPV6_RECVDSTOPTS),
+#endif
+#if defined(IPV6_DSTOPTS) || (defined(HAVE_DECL_IPV6_DSTOPTS) && HAVE_DECL_IPV6_DSTOPTS)
+  XLAT(IPV6_DSTOPTS),
+#endif
+#if defined(IPV6_RECVPATHMTU) || (defined(HAVE_DECL_IPV6_RECVPATHMTU) && HAVE_DECL_IPV6_RECVPATHMTU)
+  XLAT(IPV6_RECVPATHMTU),
+#endif
+#if defined(IPV6_PATHMTU) || (defined(HAVE_DECL_IPV6_PATHMTU) && HAVE_DECL_IPV6_PATHMTU)
+  XLAT(IPV6_PATHMTU),
+#endif
+#if defined(IPV6_DONTFRAG) || (defined(HAVE_DECL_IPV6_DONTFRAG) && HAVE_DECL_IPV6_DONTFRAG)
+  XLAT(IPV6_DONTFRAG),
+#endif
+#if defined(IPV6_USE_MIN_MTU) || (defined(HAVE_DECL_IPV6_USE_MIN_MTU) && HAVE_DECL_IPV6_USE_MIN_MTU)
+  XLAT(IPV6_USE_MIN_MTU),
+#endif
+#if defined(IPV6_RECVTCLASS) || (defined(HAVE_DECL_IPV6_RECVTCLASS) && HAVE_DECL_IPV6_RECVTCLASS)
+  XLAT(IPV6_RECVTCLASS),
+#endif
+#if defined(IPV6_TCLASS) || (defined(HAVE_DECL_IPV6_TCLASS) && HAVE_DECL_IPV6_TCLASS)
+  XLAT(IPV6_TCLASS),
+#endif
+#if defined(IPV6_AUTOFLOWLABEL) || (defined(HAVE_DECL_IPV6_AUTOFLOWLABEL) && HAVE_DECL_IPV6_AUTOFLOWLABEL)
+  XLAT(IPV6_AUTOFLOWLABEL),
+#endif
+#if defined(IPV6_ADDR_PREFERENCES) || (defined(HAVE_DECL_IPV6_ADDR_PREFERENCES) && HAVE_DECL_IPV6_ADDR_PREFERENCES)
+  XLAT(IPV6_ADDR_PREFERENCES),
+#endif
+#if defined(IPV6_MINHOPCOUNT) || (defined(HAVE_DECL_IPV6_MINHOPCOUNT) && HAVE_DECL_IPV6_MINHOPCOUNT)
+  XLAT(IPV6_MINHOPCOUNT),
+#endif
+#if defined(IPV6_ORIGDSTADDR) || (defined(HAVE_DECL_IPV6_ORIGDSTADDR) && HAVE_DECL_IPV6_ORIGDSTADDR)
+  XLAT(IPV6_ORIGDSTADDR),
+#endif
+#if defined(IPV6_RECVORIGDSTADDR) || (defined(HAVE_DECL_IPV6_RECVORIGDSTADDR) && HAVE_DECL_IPV6_RECVORIGDSTADDR)
+  XLAT(IPV6_RECVORIGDSTADDR),
+#endif
+#if defined(IPV6_TRANSPARENT) || (defined(HAVE_DECL_IPV6_TRANSPARENT) && HAVE_DECL_IPV6_TRANSPARENT)
+  XLAT(IPV6_TRANSPARENT),
+#endif
+#if defined(IPV6_UNICAST_IF) || (defined(HAVE_DECL_IPV6_UNICAST_IF) && HAVE_DECL_IPV6_UNICAST_IF)
+  XLAT(IPV6_UNICAST_IF),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sockipv6options.in b/strace/xlat/sockipv6options.in
new file mode 100644
index 0000000..5daa793
--- /dev/null
+++ b/strace/xlat/sockipv6options.in
@@ -0,0 +1,53 @@
+IPV6_ADDRFORM
+IPV6_2292PKTINFO
+IPV6_2292HOPOPTS
+IPV6_2292DSTOPTS
+IPV6_2292RTHDR
+IPV6_2292PKTOPTIONS
+IPV6_CHECKSUM
+IPV6_2292HOPLIMIT
+IPV6_NEXTHOP
+IPV6_AUTHHDR
+IPV6_FLOWINFO
+IPV6_UNICAST_HOPS
+IPV6_MULTICAST_IF
+IPV6_MULTICAST_HOPS
+IPV6_MULTICAST_LOOP
+IPV6_ADD_MEMBERSHIP
+IPV6_DROP_MEMBERSHIP
+IPV6_ROUTER_ALERT
+IPV6_MTU_DISCOVER
+IPV6_MTU
+IPV6_RECVERR
+IPV6_V6ONLY
+IPV6_JOIN_ANYCAST
+IPV6_LEAVE_ANYCAST
+IPV6_FLOWLABEL_MGR
+IPV6_FLOWINFO_SEND
+IPV6_IPSEC_POLICY
+IPV6_XFRM_POLICY
+IPV6_HDRINCL
+IPV6_RECVPKTINFO
+IPV6_PKTINFO
+IPV6_RECVHOPLIMIT
+IPV6_HOPLIMIT
+IPV6_RECVHOPOPTS
+IPV6_HOPOPTS
+IPV6_RTHDRDSTOPTS
+IPV6_RECVRTHDR
+IPV6_RTHDR
+IPV6_RECVDSTOPTS
+IPV6_DSTOPTS
+IPV6_RECVPATHMTU
+IPV6_PATHMTU
+IPV6_DONTFRAG
+IPV6_USE_MIN_MTU
+IPV6_RECVTCLASS
+IPV6_TCLASS
+IPV6_AUTOFLOWLABEL
+IPV6_ADDR_PREFERENCES
+IPV6_MINHOPCOUNT
+IPV6_ORIGDSTADDR
+IPV6_RECVORIGDSTADDR
+IPV6_TRANSPARENT
+IPV6_UNICAST_IF
diff --git a/strace/xlat/sockipxoptions.h b/strace/xlat/sockipxoptions.h
new file mode 100644
index 0000000..0e92f0e
--- /dev/null
+++ b/strace/xlat/sockipxoptions.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sockipxoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sockipxoptions in mpers mode
+
+#else
+
+static
+const struct xlat sockipxoptions[] = {
+#if defined(IPX_TYPE) || (defined(HAVE_DECL_IPX_TYPE) && HAVE_DECL_IPX_TYPE)
+  XLAT(IPX_TYPE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sockipxoptions.in b/strace/xlat/sockipxoptions.in
new file mode 100644
index 0000000..eba97fd
--- /dev/null
+++ b/strace/xlat/sockipxoptions.in
@@ -0,0 +1 @@
+IPX_TYPE
diff --git a/strace/xlat/sockoptions.h b/strace/xlat/sockoptions.h
new file mode 100644
index 0000000..87d570f
--- /dev/null
+++ b/strace/xlat/sockoptions.h
@@ -0,0 +1,213 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sockoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sockoptions in mpers mode
+
+#else
+
+static
+const struct xlat sockoptions[] = {
+#if defined(SO_DEBUG) || (defined(HAVE_DECL_SO_DEBUG) && HAVE_DECL_SO_DEBUG)
+  XLAT(SO_DEBUG),
+#endif
+#if defined(SO_REUSEADDR) || (defined(HAVE_DECL_SO_REUSEADDR) && HAVE_DECL_SO_REUSEADDR)
+  XLAT(SO_REUSEADDR),
+#endif
+#if defined(SO_TYPE) || (defined(HAVE_DECL_SO_TYPE) && HAVE_DECL_SO_TYPE)
+  XLAT(SO_TYPE),
+#endif
+#if defined(SO_ERROR) || (defined(HAVE_DECL_SO_ERROR) && HAVE_DECL_SO_ERROR)
+  XLAT(SO_ERROR),
+#endif
+#if defined(SO_DONTROUTE) || (defined(HAVE_DECL_SO_DONTROUTE) && HAVE_DECL_SO_DONTROUTE)
+  XLAT(SO_DONTROUTE),
+#endif
+#if defined(SO_BROADCAST) || (defined(HAVE_DECL_SO_BROADCAST) && HAVE_DECL_SO_BROADCAST)
+  XLAT(SO_BROADCAST),
+#endif
+#if defined(SO_SNDBUF) || (defined(HAVE_DECL_SO_SNDBUF) && HAVE_DECL_SO_SNDBUF)
+  XLAT(SO_SNDBUF),
+#endif
+#if defined(SO_RCVBUF) || (defined(HAVE_DECL_SO_RCVBUF) && HAVE_DECL_SO_RCVBUF)
+  XLAT(SO_RCVBUF),
+#endif
+#if defined(SO_SNDBUFFORCE) || (defined(HAVE_DECL_SO_SNDBUFFORCE) && HAVE_DECL_SO_SNDBUFFORCE)
+  XLAT(SO_SNDBUFFORCE),
+#endif
+#if defined(SO_RCVBUFFORCE) || (defined(HAVE_DECL_SO_RCVBUFFORCE) && HAVE_DECL_SO_RCVBUFFORCE)
+  XLAT(SO_RCVBUFFORCE),
+#endif
+#if defined(SO_KEEPALIVE) || (defined(HAVE_DECL_SO_KEEPALIVE) && HAVE_DECL_SO_KEEPALIVE)
+  XLAT(SO_KEEPALIVE),
+#endif
+#if defined(SO_OOBINLINE) || (defined(HAVE_DECL_SO_OOBINLINE) && HAVE_DECL_SO_OOBINLINE)
+  XLAT(SO_OOBINLINE),
+#endif
+#if defined(SO_NO_CHECK) || (defined(HAVE_DECL_SO_NO_CHECK) && HAVE_DECL_SO_NO_CHECK)
+  XLAT(SO_NO_CHECK),
+#endif
+#if defined(SO_PRIORITY) || (defined(HAVE_DECL_SO_PRIORITY) && HAVE_DECL_SO_PRIORITY)
+  XLAT(SO_PRIORITY),
+#endif
+#if defined(SO_LINGER) || (defined(HAVE_DECL_SO_LINGER) && HAVE_DECL_SO_LINGER)
+  XLAT(SO_LINGER),
+#endif
+#if defined(SO_BSDCOMPAT) || (defined(HAVE_DECL_SO_BSDCOMPAT) && HAVE_DECL_SO_BSDCOMPAT)
+  XLAT(SO_BSDCOMPAT),
+#endif
+#if defined(SO_REUSEPORT) || (defined(HAVE_DECL_SO_REUSEPORT) && HAVE_DECL_SO_REUSEPORT)
+  XLAT(SO_REUSEPORT),
+#endif
+#if defined(SO_PASSCRED) || (defined(HAVE_DECL_SO_PASSCRED) && HAVE_DECL_SO_PASSCRED)
+  XLAT(SO_PASSCRED),
+#endif
+#if defined(SO_PEERCRED) || (defined(HAVE_DECL_SO_PEERCRED) && HAVE_DECL_SO_PEERCRED)
+  XLAT(SO_PEERCRED),
+#endif
+#if defined(SO_RCVLOWAT) || (defined(HAVE_DECL_SO_RCVLOWAT) && HAVE_DECL_SO_RCVLOWAT)
+  XLAT(SO_RCVLOWAT),
+#endif
+#if defined(SO_SNDLOWAT) || (defined(HAVE_DECL_SO_SNDLOWAT) && HAVE_DECL_SO_SNDLOWAT)
+  XLAT(SO_SNDLOWAT),
+#endif
+#if defined(SO_RCVTIMEO) || (defined(HAVE_DECL_SO_RCVTIMEO) && HAVE_DECL_SO_RCVTIMEO)
+  XLAT(SO_RCVTIMEO),
+#endif
+#if defined(SO_SNDTIMEO) || (defined(HAVE_DECL_SO_SNDTIMEO) && HAVE_DECL_SO_SNDTIMEO)
+  XLAT(SO_SNDTIMEO),
+#endif
+#if defined(SO_SECURITY_AUTHENTICATION) || (defined(HAVE_DECL_SO_SECURITY_AUTHENTICATION) && HAVE_DECL_SO_SECURITY_AUTHENTICATION)
+  XLAT(SO_SECURITY_AUTHENTICATION),
+#endif
+#if defined(SO_SECURITY_ENCRYPTION_TRANSPORT) || (defined(HAVE_DECL_SO_SECURITY_ENCRYPTION_TRANSPORT) && HAVE_DECL_SO_SECURITY_ENCRYPTION_TRANSPORT)
+  XLAT(SO_SECURITY_ENCRYPTION_TRANSPORT),
+#endif
+#if defined(SO_SECURITY_ENCRYPTION_NETWORK) || (defined(HAVE_DECL_SO_SECURITY_ENCRYPTION_NETWORK) && HAVE_DECL_SO_SECURITY_ENCRYPTION_NETWORK)
+  XLAT(SO_SECURITY_ENCRYPTION_NETWORK),
+#endif
+#if defined(SO_BINDTODEVICE) || (defined(HAVE_DECL_SO_BINDTODEVICE) && HAVE_DECL_SO_BINDTODEVICE)
+  XLAT(SO_BINDTODEVICE),
+#endif
+#if defined(SO_ATTACH_FILTER) || (defined(HAVE_DECL_SO_ATTACH_FILTER) && HAVE_DECL_SO_ATTACH_FILTER)
+  XLAT(SO_ATTACH_FILTER),
+#endif
+#if defined(SO_GET_FILTER) || (defined(HAVE_DECL_SO_GET_FILTER) && HAVE_DECL_SO_GET_FILTER)
+  XLAT(SO_GET_FILTER),
+#endif
+#if defined(SO_DETACH_FILTER) || (defined(HAVE_DECL_SO_DETACH_FILTER) && HAVE_DECL_SO_DETACH_FILTER)
+  XLAT(SO_DETACH_FILTER),
+#endif
+#if defined(SO_DETACH_BPF) || (defined(HAVE_DECL_SO_DETACH_BPF) && HAVE_DECL_SO_DETACH_BPF)
+  XLAT(SO_DETACH_BPF),
+#endif
+#if defined(SO_PEERNAME) || (defined(HAVE_DECL_SO_PEERNAME) && HAVE_DECL_SO_PEERNAME)
+  XLAT(SO_PEERNAME),
+#endif
+#if defined(SO_TIMESTAMP) || (defined(HAVE_DECL_SO_TIMESTAMP) && HAVE_DECL_SO_TIMESTAMP)
+  XLAT(SO_TIMESTAMP),
+#endif
+#if defined(SO_ACCEPTCONN) || (defined(HAVE_DECL_SO_ACCEPTCONN) && HAVE_DECL_SO_ACCEPTCONN)
+  XLAT(SO_ACCEPTCONN),
+#endif
+#if defined(SO_PEERSEC) || (defined(HAVE_DECL_SO_PEERSEC) && HAVE_DECL_SO_PEERSEC)
+  XLAT(SO_PEERSEC),
+#endif
+#if defined(SO_PASSSEC) || (defined(HAVE_DECL_SO_PASSSEC) && HAVE_DECL_SO_PASSSEC)
+  XLAT(SO_PASSSEC),
+#endif
+#if defined(SO_TIMESTAMPNS) || (defined(HAVE_DECL_SO_TIMESTAMPNS) && HAVE_DECL_SO_TIMESTAMPNS)
+  XLAT(SO_TIMESTAMPNS),
+#endif
+#if defined(SO_MARK) || (defined(HAVE_DECL_SO_MARK) && HAVE_DECL_SO_MARK)
+  XLAT(SO_MARK),
+#endif
+#if defined(SO_TIMESTAMPING) || (defined(HAVE_DECL_SO_TIMESTAMPING) && HAVE_DECL_SO_TIMESTAMPING)
+  XLAT(SO_TIMESTAMPING),
+#endif
+#if defined(SO_PROTOCOL) || (defined(HAVE_DECL_SO_PROTOCOL) && HAVE_DECL_SO_PROTOCOL)
+  XLAT(SO_PROTOCOL),
+#endif
+#if defined(SO_DOMAIN) || (defined(HAVE_DECL_SO_DOMAIN) && HAVE_DECL_SO_DOMAIN)
+  XLAT(SO_DOMAIN),
+#endif
+#if defined(SO_RXQ_OVFL) || (defined(HAVE_DECL_SO_RXQ_OVFL) && HAVE_DECL_SO_RXQ_OVFL)
+  XLAT(SO_RXQ_OVFL),
+#endif
+#if defined(SO_WIFI_STATUS) || (defined(HAVE_DECL_SO_WIFI_STATUS) && HAVE_DECL_SO_WIFI_STATUS)
+  XLAT(SO_WIFI_STATUS),
+#endif
+#if defined(SO_PEEK_OFF) || (defined(HAVE_DECL_SO_PEEK_OFF) && HAVE_DECL_SO_PEEK_OFF)
+  XLAT(SO_PEEK_OFF),
+#endif
+#if defined(SO_NOFCS) || (defined(HAVE_DECL_SO_NOFCS) && HAVE_DECL_SO_NOFCS)
+  XLAT(SO_NOFCS),
+#endif
+#if defined(SO_LOCK_FILTER) || (defined(HAVE_DECL_SO_LOCK_FILTER) && HAVE_DECL_SO_LOCK_FILTER)
+  XLAT(SO_LOCK_FILTER),
+#endif
+#if defined(SO_SELECT_ERR_QUEUE) || (defined(HAVE_DECL_SO_SELECT_ERR_QUEUE) && HAVE_DECL_SO_SELECT_ERR_QUEUE)
+  XLAT(SO_SELECT_ERR_QUEUE),
+#endif
+#if defined(SO_BUSY_POLL) || (defined(HAVE_DECL_SO_BUSY_POLL) && HAVE_DECL_SO_BUSY_POLL)
+  XLAT(SO_BUSY_POLL),
+#endif
+#if defined(SO_MAX_PACING_RATE) || (defined(HAVE_DECL_SO_MAX_PACING_RATE) && HAVE_DECL_SO_MAX_PACING_RATE)
+  XLAT(SO_MAX_PACING_RATE),
+#endif
+#if defined(SO_BPF_EXTENSIONS) || (defined(HAVE_DECL_SO_BPF_EXTENSIONS) && HAVE_DECL_SO_BPF_EXTENSIONS)
+  XLAT(SO_BPF_EXTENSIONS),
+#endif
+#if defined(SO_INCOMING_CPU) || (defined(HAVE_DECL_SO_INCOMING_CPU) && HAVE_DECL_SO_INCOMING_CPU)
+  XLAT(SO_INCOMING_CPU),
+#endif
+#if defined(SO_ATTACH_BPF) || (defined(HAVE_DECL_SO_ATTACH_BPF) && HAVE_DECL_SO_ATTACH_BPF)
+  XLAT(SO_ATTACH_BPF),
+#endif
+#if defined(SO_ATTACH_REUSEPORT_CBPF) || (defined(HAVE_DECL_SO_ATTACH_REUSEPORT_CBPF) && HAVE_DECL_SO_ATTACH_REUSEPORT_CBPF)
+  XLAT(SO_ATTACH_REUSEPORT_CBPF),
+#endif
+#if defined(SO_ATTACH_REUSEPORT_EBPF) || (defined(HAVE_DECL_SO_ATTACH_REUSEPORT_EBPF) && HAVE_DECL_SO_ATTACH_REUSEPORT_EBPF)
+  XLAT(SO_ATTACH_REUSEPORT_EBPF),
+#endif
+#if defined(SO_CNX_ADVICE) || (defined(HAVE_DECL_SO_CNX_ADVICE) && HAVE_DECL_SO_CNX_ADVICE)
+  XLAT(SO_CNX_ADVICE),
+#endif
+
+#if defined(SO_ALLRAW) || (defined(HAVE_DECL_SO_ALLRAW) && HAVE_DECL_SO_ALLRAW)
+  XLAT(SO_ALLRAW),
+#endif
+#if defined(SO_ICS) || (defined(HAVE_DECL_SO_ICS) && HAVE_DECL_SO_ICS)
+  XLAT(SO_ICS),
+#endif
+#if defined(SO_IMASOCKET) || (defined(HAVE_DECL_SO_IMASOCKET) && HAVE_DECL_SO_IMASOCKET)
+  XLAT(SO_IMASOCKET),
+#endif
+#if defined(SO_LISTENING) || (defined(HAVE_DECL_SO_LISTENING) && HAVE_DECL_SO_LISTENING)
+  XLAT(SO_LISTENING),
+#endif
+#if defined(SO_MGMT) || (defined(HAVE_DECL_SO_MGMT) && HAVE_DECL_SO_MGMT)
+  XLAT(SO_MGMT),
+#endif
+#if defined(SO_ORDREL) || (defined(HAVE_DECL_SO_ORDREL) && HAVE_DECL_SO_ORDREL)
+  XLAT(SO_ORDREL),
+#endif
+#if defined(SO_PARALLELSVR) || (defined(HAVE_DECL_SO_PARALLELSVR) && HAVE_DECL_SO_PARALLELSVR)
+  XLAT(SO_PARALLELSVR),
+#endif
+#if defined(SO_PROTOTYPE) || (defined(HAVE_DECL_SO_PROTOTYPE) && HAVE_DECL_SO_PROTOTYPE)
+  XLAT(SO_PROTOTYPE),
+#endif
+#if defined(SO_RDWR) || (defined(HAVE_DECL_SO_RDWR) && HAVE_DECL_SO_RDWR)
+  XLAT(SO_RDWR),
+#endif
+#if defined(SO_SEMA) || (defined(HAVE_DECL_SO_SEMA) && HAVE_DECL_SO_SEMA)
+  XLAT(SO_SEMA),
+#endif
+#if defined(SO_USELOOPBACK) || (defined(HAVE_DECL_SO_USELOOPBACK) && HAVE_DECL_SO_USELOOPBACK)
+  XLAT(SO_USELOOPBACK),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sockoptions.in b/strace/xlat/sockoptions.in
new file mode 100644
index 0000000..fce851a
--- /dev/null
+++ b/strace/xlat/sockoptions.in
@@ -0,0 +1,67 @@
+SO_DEBUG
+SO_REUSEADDR
+SO_TYPE
+SO_ERROR
+SO_DONTROUTE
+SO_BROADCAST
+SO_SNDBUF
+SO_RCVBUF
+SO_SNDBUFFORCE
+SO_RCVBUFFORCE
+SO_KEEPALIVE
+SO_OOBINLINE
+SO_NO_CHECK
+SO_PRIORITY
+SO_LINGER
+SO_BSDCOMPAT
+SO_REUSEPORT
+SO_PASSCRED
+SO_PEERCRED
+SO_RCVLOWAT
+SO_SNDLOWAT
+SO_RCVTIMEO
+SO_SNDTIMEO
+SO_SECURITY_AUTHENTICATION
+SO_SECURITY_ENCRYPTION_TRANSPORT
+SO_SECURITY_ENCRYPTION_NETWORK
+SO_BINDTODEVICE
+SO_ATTACH_FILTER
+SO_GET_FILTER
+SO_DETACH_FILTER
+SO_DETACH_BPF
+SO_PEERNAME
+SO_TIMESTAMP
+SO_ACCEPTCONN
+SO_PEERSEC
+SO_PASSSEC
+SO_TIMESTAMPNS
+SO_MARK
+SO_TIMESTAMPING
+SO_PROTOCOL
+SO_DOMAIN
+SO_RXQ_OVFL
+SO_WIFI_STATUS
+SO_PEEK_OFF
+SO_NOFCS
+SO_LOCK_FILTER
+SO_SELECT_ERR_QUEUE
+SO_BUSY_POLL
+SO_MAX_PACING_RATE
+SO_BPF_EXTENSIONS
+SO_INCOMING_CPU
+SO_ATTACH_BPF
+SO_ATTACH_REUSEPORT_CBPF
+SO_ATTACH_REUSEPORT_EBPF
+SO_CNX_ADVICE
+
+SO_ALLRAW
+SO_ICS
+SO_IMASOCKET
+SO_LISTENING
+SO_MGMT
+SO_ORDREL
+SO_PARALLELSVR
+SO_PROTOTYPE
+SO_RDWR
+SO_SEMA
+SO_USELOOPBACK
diff --git a/strace/xlat/sockpacketoptions.h b/strace/xlat/sockpacketoptions.h
new file mode 100644
index 0000000..ae4c5f4
--- /dev/null
+++ b/strace/xlat/sockpacketoptions.h
@@ -0,0 +1,77 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sockpacketoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sockpacketoptions in mpers mode
+
+#else
+
+static
+const struct xlat sockpacketoptions[] = {
+#if defined(PACKET_ADD_MEMBERSHIP) || (defined(HAVE_DECL_PACKET_ADD_MEMBERSHIP) && HAVE_DECL_PACKET_ADD_MEMBERSHIP)
+  XLAT(PACKET_ADD_MEMBERSHIP),
+#endif
+#if defined(PACKET_DROP_MEMBERSHIP) || (defined(HAVE_DECL_PACKET_DROP_MEMBERSHIP) && HAVE_DECL_PACKET_DROP_MEMBERSHIP)
+  XLAT(PACKET_DROP_MEMBERSHIP),
+#endif
+#if defined(PACKET_RECV_OUTPUT) || (defined(HAVE_DECL_PACKET_RECV_OUTPUT) && HAVE_DECL_PACKET_RECV_OUTPUT)
+  XLAT(PACKET_RECV_OUTPUT),
+#endif
+#if defined(PACKET_RX_RING) || (defined(HAVE_DECL_PACKET_RX_RING) && HAVE_DECL_PACKET_RX_RING)
+  XLAT(PACKET_RX_RING),
+#endif
+#if defined(PACKET_STATISTICS) || (defined(HAVE_DECL_PACKET_STATISTICS) && HAVE_DECL_PACKET_STATISTICS)
+  XLAT(PACKET_STATISTICS),
+#endif
+#if defined(PACKET_COPY_THRESH) || (defined(HAVE_DECL_PACKET_COPY_THRESH) && HAVE_DECL_PACKET_COPY_THRESH)
+  XLAT(PACKET_COPY_THRESH),
+#endif
+#if defined(PACKET_AUXDATA) || (defined(HAVE_DECL_PACKET_AUXDATA) && HAVE_DECL_PACKET_AUXDATA)
+  XLAT(PACKET_AUXDATA),
+#endif
+#if defined(PACKET_ORIGDEV) || (defined(HAVE_DECL_PACKET_ORIGDEV) && HAVE_DECL_PACKET_ORIGDEV)
+  XLAT(PACKET_ORIGDEV),
+#endif
+#if defined(PACKET_VERSION) || (defined(HAVE_DECL_PACKET_VERSION) && HAVE_DECL_PACKET_VERSION)
+  XLAT(PACKET_VERSION),
+#endif
+#if defined(PACKET_HDRLEN) || (defined(HAVE_DECL_PACKET_HDRLEN) && HAVE_DECL_PACKET_HDRLEN)
+  XLAT(PACKET_HDRLEN),
+#endif
+#if defined(PACKET_RESERVE) || (defined(HAVE_DECL_PACKET_RESERVE) && HAVE_DECL_PACKET_RESERVE)
+  XLAT(PACKET_RESERVE),
+#endif
+#if defined(PACKET_TX_RING) || (defined(HAVE_DECL_PACKET_TX_RING) && HAVE_DECL_PACKET_TX_RING)
+  XLAT(PACKET_TX_RING),
+#endif
+#if defined(PACKET_LOSS) || (defined(HAVE_DECL_PACKET_LOSS) && HAVE_DECL_PACKET_LOSS)
+  XLAT(PACKET_LOSS),
+#endif
+#if defined(PACKET_VNET_HDR) || (defined(HAVE_DECL_PACKET_VNET_HDR) && HAVE_DECL_PACKET_VNET_HDR)
+  XLAT(PACKET_VNET_HDR),
+#endif
+#if defined(PACKET_TX_TIMESTAMP) || (defined(HAVE_DECL_PACKET_TX_TIMESTAMP) && HAVE_DECL_PACKET_TX_TIMESTAMP)
+  XLAT(PACKET_TX_TIMESTAMP),
+#endif
+#if defined(PACKET_TIMESTAMP) || (defined(HAVE_DECL_PACKET_TIMESTAMP) && HAVE_DECL_PACKET_TIMESTAMP)
+  XLAT(PACKET_TIMESTAMP),
+#endif
+#if defined(PACKET_FANOUT) || (defined(HAVE_DECL_PACKET_FANOUT) && HAVE_DECL_PACKET_FANOUT)
+  XLAT(PACKET_FANOUT),
+#endif
+#if defined(PACKET_TX_HAS_OFF) || (defined(HAVE_DECL_PACKET_TX_HAS_OFF) && HAVE_DECL_PACKET_TX_HAS_OFF)
+  XLAT(PACKET_TX_HAS_OFF),
+#endif
+#if defined(PACKET_QDISC_BYPASS) || (defined(HAVE_DECL_PACKET_QDISC_BYPASS) && HAVE_DECL_PACKET_QDISC_BYPASS)
+  XLAT(PACKET_QDISC_BYPASS),
+#endif
+#if defined(PACKET_ROLLOVER_STATS) || (defined(HAVE_DECL_PACKET_ROLLOVER_STATS) && HAVE_DECL_PACKET_ROLLOVER_STATS)
+  XLAT(PACKET_ROLLOVER_STATS),
+#endif
+#if defined(PACKET_FANOUT_DATA) || (defined(HAVE_DECL_PACKET_FANOUT_DATA) && HAVE_DECL_PACKET_FANOUT_DATA)
+  XLAT(PACKET_FANOUT_DATA),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sockpacketoptions.in b/strace/xlat/sockpacketoptions.in
new file mode 100644
index 0000000..d11ad0b
--- /dev/null
+++ b/strace/xlat/sockpacketoptions.in
@@ -0,0 +1,21 @@
+PACKET_ADD_MEMBERSHIP
+PACKET_DROP_MEMBERSHIP
+PACKET_RECV_OUTPUT
+PACKET_RX_RING
+PACKET_STATISTICS
+PACKET_COPY_THRESH
+PACKET_AUXDATA
+PACKET_ORIGDEV
+PACKET_VERSION
+PACKET_HDRLEN
+PACKET_RESERVE
+PACKET_TX_RING
+PACKET_LOSS
+PACKET_VNET_HDR
+PACKET_TX_TIMESTAMP
+PACKET_TIMESTAMP
+PACKET_FANOUT
+PACKET_TX_HAS_OFF
+PACKET_QDISC_BYPASS
+PACKET_ROLLOVER_STATS
+PACKET_FANOUT_DATA
diff --git a/strace/xlat/sockrawoptions.h b/strace/xlat/sockrawoptions.h
new file mode 100644
index 0000000..99868c8
--- /dev/null
+++ b/strace/xlat/sockrawoptions.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sockrawoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sockrawoptions in mpers mode
+
+#else
+
+static
+const struct xlat sockrawoptions[] = {
+#if defined(ICMP_FILTER) || (defined(HAVE_DECL_ICMP_FILTER) && HAVE_DECL_ICMP_FILTER)
+  XLAT(ICMP_FILTER),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sockrawoptions.in b/strace/xlat/sockrawoptions.in
new file mode 100644
index 0000000..b341134
--- /dev/null
+++ b/strace/xlat/sockrawoptions.in
@@ -0,0 +1 @@
+ICMP_FILTER
diff --git a/strace/xlat/socksctpoptions.h b/strace/xlat/socksctpoptions.h
new file mode 100644
index 0000000..7aa20db
--- /dev/null
+++ b/strace/xlat/socksctpoptions.h
@@ -0,0 +1,159 @@
+/* Generated by ./xlat/gen.sh from ./xlat/socksctpoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat socksctpoptions in mpers mode
+
+#else
+
+static
+const struct xlat socksctpoptions[] = {
+#if defined(SCTP_RTOINFO) || (defined(HAVE_DECL_SCTP_RTOINFO) && HAVE_DECL_SCTP_RTOINFO)
+  XLAT(SCTP_RTOINFO),
+#endif
+#if defined(SCTP_ASSOCINFO) || (defined(HAVE_DECL_SCTP_ASSOCINFO) && HAVE_DECL_SCTP_ASSOCINFO)
+  XLAT(SCTP_ASSOCINFO),
+#endif
+#if defined(SCTP_INITMSG) || (defined(HAVE_DECL_SCTP_INITMSG) && HAVE_DECL_SCTP_INITMSG)
+  XLAT(SCTP_INITMSG),
+#endif
+#if defined(SCTP_NODELAY) || (defined(HAVE_DECL_SCTP_NODELAY) && HAVE_DECL_SCTP_NODELAY)
+  XLAT(SCTP_NODELAY),
+#endif
+#if defined(SCTP_AUTOCLOSE) || (defined(HAVE_DECL_SCTP_AUTOCLOSE) && HAVE_DECL_SCTP_AUTOCLOSE)
+  XLAT(SCTP_AUTOCLOSE),
+#endif
+#if defined(SCTP_SET_PEER_PRIMARY_ADDR) || (defined(HAVE_DECL_SCTP_SET_PEER_PRIMARY_ADDR) && HAVE_DECL_SCTP_SET_PEER_PRIMARY_ADDR)
+  XLAT(SCTP_SET_PEER_PRIMARY_ADDR),
+#endif
+#if defined(SCTP_PRIMARY_ADDR) || (defined(HAVE_DECL_SCTP_PRIMARY_ADDR) && HAVE_DECL_SCTP_PRIMARY_ADDR)
+  XLAT(SCTP_PRIMARY_ADDR),
+#endif
+#if defined(SCTP_ADAPTATION_LAYER) || (defined(HAVE_DECL_SCTP_ADAPTATION_LAYER) && HAVE_DECL_SCTP_ADAPTATION_LAYER)
+  XLAT(SCTP_ADAPTATION_LAYER),
+#endif
+#if defined(SCTP_DISABLE_FRAGMENTS) || (defined(HAVE_DECL_SCTP_DISABLE_FRAGMENTS) && HAVE_DECL_SCTP_DISABLE_FRAGMENTS)
+  XLAT(SCTP_DISABLE_FRAGMENTS),
+#endif
+#if defined(SCTP_PEER_ADDR_PARAMS) || (defined(HAVE_DECL_SCTP_PEER_ADDR_PARAMS) && HAVE_DECL_SCTP_PEER_ADDR_PARAMS)
+  XLAT(SCTP_PEER_ADDR_PARAMS),
+#endif
+#if defined(SCTP_DEFAULT_SEND_PARAM) || (defined(HAVE_DECL_SCTP_DEFAULT_SEND_PARAM) && HAVE_DECL_SCTP_DEFAULT_SEND_PARAM)
+  XLAT(SCTP_DEFAULT_SEND_PARAM),
+#endif
+#if defined(SCTP_EVENTS) || (defined(HAVE_DECL_SCTP_EVENTS) && HAVE_DECL_SCTP_EVENTS)
+  XLAT(SCTP_EVENTS),
+#endif
+#if defined(SCTP_I_WANT_MAPPED_V4_ADDR) || (defined(HAVE_DECL_SCTP_I_WANT_MAPPED_V4_ADDR) && HAVE_DECL_SCTP_I_WANT_MAPPED_V4_ADDR)
+  XLAT(SCTP_I_WANT_MAPPED_V4_ADDR),
+#endif
+#if defined(SCTP_MAXSEG) || (defined(HAVE_DECL_SCTP_MAXSEG) && HAVE_DECL_SCTP_MAXSEG)
+  XLAT(SCTP_MAXSEG),
+#endif
+#if defined(SCTP_STATUS) || (defined(HAVE_DECL_SCTP_STATUS) && HAVE_DECL_SCTP_STATUS)
+  XLAT(SCTP_STATUS),
+#endif
+#if defined(SCTP_GET_PEER_ADDR_INFO) || (defined(HAVE_DECL_SCTP_GET_PEER_ADDR_INFO) && HAVE_DECL_SCTP_GET_PEER_ADDR_INFO)
+  XLAT(SCTP_GET_PEER_ADDR_INFO),
+#endif
+#if defined(SCTP_DELAYED_ACK) || (defined(HAVE_DECL_SCTP_DELAYED_ACK) && HAVE_DECL_SCTP_DELAYED_ACK)
+  XLAT(SCTP_DELAYED_ACK),
+#endif
+#if defined(SCTP_CONTEXT) || (defined(HAVE_DECL_SCTP_CONTEXT) && HAVE_DECL_SCTP_CONTEXT)
+  XLAT(SCTP_CONTEXT),
+#endif
+#if defined(SCTP_FRAGMENT_INTERLEAVE) || (defined(HAVE_DECL_SCTP_FRAGMENT_INTERLEAVE) && HAVE_DECL_SCTP_FRAGMENT_INTERLEAVE)
+  XLAT(SCTP_FRAGMENT_INTERLEAVE),
+#endif
+#if defined(SCTP_PARTIAL_DELIVERY_POINT) || (defined(HAVE_DECL_SCTP_PARTIAL_DELIVERY_POINT) && HAVE_DECL_SCTP_PARTIAL_DELIVERY_POINT)
+  XLAT(SCTP_PARTIAL_DELIVERY_POINT),
+#endif
+#if defined(SCTP_MAX_BURST) || (defined(HAVE_DECL_SCTP_MAX_BURST) && HAVE_DECL_SCTP_MAX_BURST)
+  XLAT(SCTP_MAX_BURST),
+#endif
+#if defined(SCTP_AUTH_CHUNK) || (defined(HAVE_DECL_SCTP_AUTH_CHUNK) && HAVE_DECL_SCTP_AUTH_CHUNK)
+  XLAT(SCTP_AUTH_CHUNK),
+#endif
+#if defined(SCTP_HMAC_IDENT) || (defined(HAVE_DECL_SCTP_HMAC_IDENT) && HAVE_DECL_SCTP_HMAC_IDENT)
+  XLAT(SCTP_HMAC_IDENT),
+#endif
+#if defined(SCTP_AUTH_KEY) || (defined(HAVE_DECL_SCTP_AUTH_KEY) && HAVE_DECL_SCTP_AUTH_KEY)
+  XLAT(SCTP_AUTH_KEY),
+#endif
+#if defined(SCTP_AUTH_ACTIVE_KEY) || (defined(HAVE_DECL_SCTP_AUTH_ACTIVE_KEY) && HAVE_DECL_SCTP_AUTH_ACTIVE_KEY)
+  XLAT(SCTP_AUTH_ACTIVE_KEY),
+#endif
+#if defined(SCTP_AUTH_DELETE_KEY) || (defined(HAVE_DECL_SCTP_AUTH_DELETE_KEY) && HAVE_DECL_SCTP_AUTH_DELETE_KEY)
+  XLAT(SCTP_AUTH_DELETE_KEY),
+#endif
+#if defined(SCTP_PEER_AUTH_CHUNKS) || (defined(HAVE_DECL_SCTP_PEER_AUTH_CHUNKS) && HAVE_DECL_SCTP_PEER_AUTH_CHUNKS)
+  XLAT(SCTP_PEER_AUTH_CHUNKS),
+#endif
+#if defined(SCTP_LOCAL_AUTH_CHUNKS) || (defined(HAVE_DECL_SCTP_LOCAL_AUTH_CHUNKS) && HAVE_DECL_SCTP_LOCAL_AUTH_CHUNKS)
+  XLAT(SCTP_LOCAL_AUTH_CHUNKS),
+#endif
+#if defined(SCTP_GET_ASSOC_NUMBER) || (defined(HAVE_DECL_SCTP_GET_ASSOC_NUMBER) && HAVE_DECL_SCTP_GET_ASSOC_NUMBER)
+  XLAT(SCTP_GET_ASSOC_NUMBER),
+#endif
+#if defined(SCTP_GET_ASSOC_ID_LIST) || (defined(HAVE_DECL_SCTP_GET_ASSOC_ID_LIST) && HAVE_DECL_SCTP_GET_ASSOC_ID_LIST)
+  XLAT(SCTP_GET_ASSOC_ID_LIST),
+#endif
+#if defined(SCTP_AUTO_ASCONF) || (defined(HAVE_DECL_SCTP_AUTO_ASCONF) && HAVE_DECL_SCTP_AUTO_ASCONF)
+  XLAT(SCTP_AUTO_ASCONF),
+#endif
+#if defined(SCTP_PEER_ADDR_THLDS) || (defined(HAVE_DECL_SCTP_PEER_ADDR_THLDS) && HAVE_DECL_SCTP_PEER_ADDR_THLDS)
+  XLAT(SCTP_PEER_ADDR_THLDS),
+#endif
+#if defined(SCTP_RECVRCVINFO) || (defined(HAVE_DECL_SCTP_RECVRCVINFO) && HAVE_DECL_SCTP_RECVRCVINFO)
+  XLAT(SCTP_RECVRCVINFO),
+#endif
+#if defined(SCTP_RECVNXTINFO) || (defined(HAVE_DECL_SCTP_RECVNXTINFO) && HAVE_DECL_SCTP_RECVNXTINFO)
+  XLAT(SCTP_RECVNXTINFO),
+#endif
+#if defined(SCTP_DEFAULT_SNDINFO) || (defined(HAVE_DECL_SCTP_DEFAULT_SNDINFO) && HAVE_DECL_SCTP_DEFAULT_SNDINFO)
+  XLAT(SCTP_DEFAULT_SNDINFO),
+#endif
+/* linux specific things */
+#if defined(SCTP_SOCKOPT_BINDX_ADD) || (defined(HAVE_DECL_SCTP_SOCKOPT_BINDX_ADD) && HAVE_DECL_SCTP_SOCKOPT_BINDX_ADD)
+  XLAT(SCTP_SOCKOPT_BINDX_ADD),
+#endif
+#if defined(SCTP_SOCKOPT_BINDX_REM) || (defined(HAVE_DECL_SCTP_SOCKOPT_BINDX_REM) && HAVE_DECL_SCTP_SOCKOPT_BINDX_REM)
+  XLAT(SCTP_SOCKOPT_BINDX_REM),
+#endif
+#if defined(SCTP_SOCKOPT_PEELOFF) || (defined(HAVE_DECL_SCTP_SOCKOPT_PEELOFF) && HAVE_DECL_SCTP_SOCKOPT_PEELOFF)
+  XLAT(SCTP_SOCKOPT_PEELOFF),
+#endif
+#if defined(SCTP_GET_PEER_ADDRS_NUM_OLD) || (defined(HAVE_DECL_SCTP_GET_PEER_ADDRS_NUM_OLD) && HAVE_DECL_SCTP_GET_PEER_ADDRS_NUM_OLD)
+  XLAT(SCTP_GET_PEER_ADDRS_NUM_OLD),
+#endif
+#if defined(SCTP_GET_PEER_ADDRS_OLD) || (defined(HAVE_DECL_SCTP_GET_PEER_ADDRS_OLD) && HAVE_DECL_SCTP_GET_PEER_ADDRS_OLD)
+  XLAT(SCTP_GET_PEER_ADDRS_OLD),
+#endif
+#if defined(SCTP_GET_LOCAL_ADDRS_NUM_OLD) || (defined(HAVE_DECL_SCTP_GET_LOCAL_ADDRS_NUM_OLD) && HAVE_DECL_SCTP_GET_LOCAL_ADDRS_NUM_OLD)
+  XLAT(SCTP_GET_LOCAL_ADDRS_NUM_OLD),
+#endif
+#if defined(SCTP_GET_LOCAL_ADDRS_OLD) || (defined(HAVE_DECL_SCTP_GET_LOCAL_ADDRS_OLD) && HAVE_DECL_SCTP_GET_LOCAL_ADDRS_OLD)
+  XLAT(SCTP_GET_LOCAL_ADDRS_OLD),
+#endif
+#if defined(SCTP_SOCKOPT_CONNECTX_OLD) || (defined(HAVE_DECL_SCTP_SOCKOPT_CONNECTX_OLD) && HAVE_DECL_SCTP_SOCKOPT_CONNECTX_OLD)
+  XLAT(SCTP_SOCKOPT_CONNECTX_OLD),
+#endif
+#if defined(SCTP_GET_PEER_ADDRS) || (defined(HAVE_DECL_SCTP_GET_PEER_ADDRS) && HAVE_DECL_SCTP_GET_PEER_ADDRS)
+  XLAT(SCTP_GET_PEER_ADDRS),
+#endif
+#if defined(SCTP_GET_LOCAL_ADDRS) || (defined(HAVE_DECL_SCTP_GET_LOCAL_ADDRS) && HAVE_DECL_SCTP_GET_LOCAL_ADDRS)
+  XLAT(SCTP_GET_LOCAL_ADDRS),
+#endif
+#if defined(SCTP_SOCKOPT_CONNECTX) || (defined(HAVE_DECL_SCTP_SOCKOPT_CONNECTX) && HAVE_DECL_SCTP_SOCKOPT_CONNECTX)
+  XLAT(SCTP_SOCKOPT_CONNECTX),
+#endif
+#if defined(SCTP_SOCKOPT_CONNECTX3) || (defined(HAVE_DECL_SCTP_SOCKOPT_CONNECTX3) && HAVE_DECL_SCTP_SOCKOPT_CONNECTX3)
+  XLAT(SCTP_SOCKOPT_CONNECTX3),
+#endif
+#if defined(SCTP_GET_ASSOC_STATS) || (defined(HAVE_DECL_SCTP_GET_ASSOC_STATS) && HAVE_DECL_SCTP_GET_ASSOC_STATS)
+  XLAT(SCTP_GET_ASSOC_STATS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/socksctpoptions.in b/strace/xlat/socksctpoptions.in
new file mode 100644
index 0000000..8af43b7
--- /dev/null
+++ b/strace/xlat/socksctpoptions.in
@@ -0,0 +1,49 @@
+SCTP_RTOINFO
+SCTP_ASSOCINFO
+SCTP_INITMSG
+SCTP_NODELAY
+SCTP_AUTOCLOSE
+SCTP_SET_PEER_PRIMARY_ADDR
+SCTP_PRIMARY_ADDR
+SCTP_ADAPTATION_LAYER
+SCTP_DISABLE_FRAGMENTS
+SCTP_PEER_ADDR_PARAMS
+SCTP_DEFAULT_SEND_PARAM
+SCTP_EVENTS
+SCTP_I_WANT_MAPPED_V4_ADDR
+SCTP_MAXSEG
+SCTP_STATUS
+SCTP_GET_PEER_ADDR_INFO
+SCTP_DELAYED_ACK
+SCTP_CONTEXT
+SCTP_FRAGMENT_INTERLEAVE
+SCTP_PARTIAL_DELIVERY_POINT
+SCTP_MAX_BURST
+SCTP_AUTH_CHUNK
+SCTP_HMAC_IDENT
+SCTP_AUTH_KEY
+SCTP_AUTH_ACTIVE_KEY
+SCTP_AUTH_DELETE_KEY
+SCTP_PEER_AUTH_CHUNKS
+SCTP_LOCAL_AUTH_CHUNKS
+SCTP_GET_ASSOC_NUMBER
+SCTP_GET_ASSOC_ID_LIST
+SCTP_AUTO_ASCONF
+SCTP_PEER_ADDR_THLDS
+SCTP_RECVRCVINFO
+SCTP_RECVNXTINFO
+SCTP_DEFAULT_SNDINFO
+/* linux specific things */
+SCTP_SOCKOPT_BINDX_ADD
+SCTP_SOCKOPT_BINDX_REM
+SCTP_SOCKOPT_PEELOFF
+SCTP_GET_PEER_ADDRS_NUM_OLD
+SCTP_GET_PEER_ADDRS_OLD
+SCTP_GET_LOCAL_ADDRS_NUM_OLD
+SCTP_GET_LOCAL_ADDRS_OLD
+SCTP_SOCKOPT_CONNECTX_OLD
+SCTP_GET_PEER_ADDRS
+SCTP_GET_LOCAL_ADDRS
+SCTP_SOCKOPT_CONNECTX
+SCTP_SOCKOPT_CONNECTX3
+SCTP_GET_ASSOC_STATS
diff --git a/strace/xlat/socktcpoptions.h b/strace/xlat/socktcpoptions.h
new file mode 100644
index 0000000..23f0770
--- /dev/null
+++ b/strace/xlat/socktcpoptions.h
@@ -0,0 +1,98 @@
+/* Generated by ./xlat/gen.sh from ./xlat/socktcpoptions.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat socktcpoptions in mpers mode
+
+#else
+
+static
+const struct xlat socktcpoptions[] = {
+#if defined(TCP_NODELAY) || (defined(HAVE_DECL_TCP_NODELAY) && HAVE_DECL_TCP_NODELAY)
+  XLAT(TCP_NODELAY),
+#endif
+#if defined(TCP_MAXSEG) || (defined(HAVE_DECL_TCP_MAXSEG) && HAVE_DECL_TCP_MAXSEG)
+  XLAT(TCP_MAXSEG),
+#endif
+#if defined(TCP_CORK) || (defined(HAVE_DECL_TCP_CORK) && HAVE_DECL_TCP_CORK)
+  XLAT(TCP_CORK),
+#endif
+#if defined(TCP_KEEPIDLE) || (defined(HAVE_DECL_TCP_KEEPIDLE) && HAVE_DECL_TCP_KEEPIDLE)
+  XLAT(TCP_KEEPIDLE),
+#endif
+#if defined(TCP_KEEPINTVL) || (defined(HAVE_DECL_TCP_KEEPINTVL) && HAVE_DECL_TCP_KEEPINTVL)
+  XLAT(TCP_KEEPINTVL),
+#endif
+#if defined(TCP_KEEPCNT) || (defined(HAVE_DECL_TCP_KEEPCNT) && HAVE_DECL_TCP_KEEPCNT)
+  XLAT(TCP_KEEPCNT),
+#endif
+#if defined(TCP_SYNCNT) || (defined(HAVE_DECL_TCP_SYNCNT) && HAVE_DECL_TCP_SYNCNT)
+  XLAT(TCP_SYNCNT),
+#endif
+#if defined(TCP_LINGER2) || (defined(HAVE_DECL_TCP_LINGER2) && HAVE_DECL_TCP_LINGER2)
+  XLAT(TCP_LINGER2),
+#endif
+#if defined(TCP_DEFER_ACCEPT) || (defined(HAVE_DECL_TCP_DEFER_ACCEPT) && HAVE_DECL_TCP_DEFER_ACCEPT)
+  XLAT(TCP_DEFER_ACCEPT),
+#endif
+#if defined(TCP_WINDOW_CLAMP) || (defined(HAVE_DECL_TCP_WINDOW_CLAMP) && HAVE_DECL_TCP_WINDOW_CLAMP)
+  XLAT(TCP_WINDOW_CLAMP),
+#endif
+#if defined(TCP_INFO) || (defined(HAVE_DECL_TCP_INFO) && HAVE_DECL_TCP_INFO)
+  XLAT(TCP_INFO),
+#endif
+#if defined(TCP_QUICKACK) || (defined(HAVE_DECL_TCP_QUICKACK) && HAVE_DECL_TCP_QUICKACK)
+  XLAT(TCP_QUICKACK),
+#endif
+#if defined(TCP_CONGESTION) || (defined(HAVE_DECL_TCP_CONGESTION) && HAVE_DECL_TCP_CONGESTION)
+  XLAT(TCP_CONGESTION),
+#endif
+#if defined(TCP_MD5SIG) || (defined(HAVE_DECL_TCP_MD5SIG) && HAVE_DECL_TCP_MD5SIG)
+  XLAT(TCP_MD5SIG),
+#endif
+#if defined(TCP_COOKIE_TRANSACTIONS) || (defined(HAVE_DECL_TCP_COOKIE_TRANSACTIONS) && HAVE_DECL_TCP_COOKIE_TRANSACTIONS)
+  XLAT(TCP_COOKIE_TRANSACTIONS),
+#endif
+#if defined(TCP_THIN_LINEAR_TIMEOUTS) || (defined(HAVE_DECL_TCP_THIN_LINEAR_TIMEOUTS) && HAVE_DECL_TCP_THIN_LINEAR_TIMEOUTS)
+  XLAT(TCP_THIN_LINEAR_TIMEOUTS),
+#endif
+#if defined(TCP_THIN_DUPACK) || (defined(HAVE_DECL_TCP_THIN_DUPACK) && HAVE_DECL_TCP_THIN_DUPACK)
+  XLAT(TCP_THIN_DUPACK),
+#endif
+#if defined(TCP_USER_TIMEOUT) || (defined(HAVE_DECL_TCP_USER_TIMEOUT) && HAVE_DECL_TCP_USER_TIMEOUT)
+  XLAT(TCP_USER_TIMEOUT),
+#endif
+#if defined(TCP_REPAIR) || (defined(HAVE_DECL_TCP_REPAIR) && HAVE_DECL_TCP_REPAIR)
+  XLAT(TCP_REPAIR),
+#endif
+#if defined(TCP_REPAIR_QUEUE) || (defined(HAVE_DECL_TCP_REPAIR_QUEUE) && HAVE_DECL_TCP_REPAIR_QUEUE)
+  XLAT(TCP_REPAIR_QUEUE),
+#endif
+#if defined(TCP_QUEUE_SEQ) || (defined(HAVE_DECL_TCP_QUEUE_SEQ) && HAVE_DECL_TCP_QUEUE_SEQ)
+  XLAT(TCP_QUEUE_SEQ),
+#endif
+#if defined(TCP_REPAIR_OPTIONS) || (defined(HAVE_DECL_TCP_REPAIR_OPTIONS) && HAVE_DECL_TCP_REPAIR_OPTIONS)
+  XLAT(TCP_REPAIR_OPTIONS),
+#endif
+#if defined(TCP_FASTOPEN) || (defined(HAVE_DECL_TCP_FASTOPEN) && HAVE_DECL_TCP_FASTOPEN)
+  XLAT(TCP_FASTOPEN),
+#endif
+#if defined(TCP_TIMESTAMP) || (defined(HAVE_DECL_TCP_TIMESTAMP) && HAVE_DECL_TCP_TIMESTAMP)
+  XLAT(TCP_TIMESTAMP),
+#endif
+#if defined(TCP_NOTSENT_LOWAT) || (defined(HAVE_DECL_TCP_NOTSENT_LOWAT) && HAVE_DECL_TCP_NOTSENT_LOWAT)
+  XLAT(TCP_NOTSENT_LOWAT),
+#endif
+#if defined(TCP_CC_INFO) || (defined(HAVE_DECL_TCP_CC_INFO) && HAVE_DECL_TCP_CC_INFO)
+  XLAT(TCP_CC_INFO),
+#endif
+#if defined(TCP_SAVE_SYN) || (defined(HAVE_DECL_TCP_SAVE_SYN) && HAVE_DECL_TCP_SAVE_SYN)
+  XLAT(TCP_SAVE_SYN),
+#endif
+#if defined(TCP_SAVED_SYN) || (defined(HAVE_DECL_TCP_SAVED_SYN) && HAVE_DECL_TCP_SAVED_SYN)
+  XLAT(TCP_SAVED_SYN),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/socktcpoptions.in b/strace/xlat/socktcpoptions.in
new file mode 100644
index 0000000..b454e10
--- /dev/null
+++ b/strace/xlat/socktcpoptions.in
@@ -0,0 +1,28 @@
+TCP_NODELAY
+TCP_MAXSEG
+TCP_CORK
+TCP_KEEPIDLE
+TCP_KEEPINTVL
+TCP_KEEPCNT
+TCP_SYNCNT
+TCP_LINGER2
+TCP_DEFER_ACCEPT
+TCP_WINDOW_CLAMP
+TCP_INFO
+TCP_QUICKACK
+TCP_CONGESTION
+TCP_MD5SIG
+TCP_COOKIE_TRANSACTIONS
+TCP_THIN_LINEAR_TIMEOUTS
+TCP_THIN_DUPACK
+TCP_USER_TIMEOUT
+TCP_REPAIR
+TCP_REPAIR_QUEUE
+TCP_QUEUE_SEQ
+TCP_REPAIR_OPTIONS
+TCP_FASTOPEN
+TCP_TIMESTAMP
+TCP_NOTSENT_LOWAT
+TCP_CC_INFO
+TCP_SAVE_SYN
+TCP_SAVED_SYN
diff --git a/strace/xlat/socktypes.h b/strace/xlat/socktypes.h
new file mode 100644
index 0000000..f9db97b
--- /dev/null
+++ b/strace/xlat/socktypes.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/socktypes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat socktypes in mpers mode
+
+#else
+
+static
+const struct xlat socktypes[] = {
+#if defined(SOCK_STREAM) || (defined(HAVE_DECL_SOCK_STREAM) && HAVE_DECL_SOCK_STREAM)
+  XLAT(SOCK_STREAM),
+#endif
+#if defined(SOCK_DGRAM) || (defined(HAVE_DECL_SOCK_DGRAM) && HAVE_DECL_SOCK_DGRAM)
+  XLAT(SOCK_DGRAM),
+#endif
+#if defined(SOCK_RAW) || (defined(HAVE_DECL_SOCK_RAW) && HAVE_DECL_SOCK_RAW)
+  XLAT(SOCK_RAW),
+#endif
+#if defined(SOCK_RDM) || (defined(HAVE_DECL_SOCK_RDM) && HAVE_DECL_SOCK_RDM)
+  XLAT(SOCK_RDM),
+#endif
+#if defined(SOCK_SEQPACKET) || (defined(HAVE_DECL_SOCK_SEQPACKET) && HAVE_DECL_SOCK_SEQPACKET)
+  XLAT(SOCK_SEQPACKET),
+#endif
+#if defined(SOCK_DCCP) || (defined(HAVE_DECL_SOCK_DCCP) && HAVE_DECL_SOCK_DCCP)
+  XLAT(SOCK_DCCP),
+#endif
+#if defined(SOCK_PACKET) || (defined(HAVE_DECL_SOCK_PACKET) && HAVE_DECL_SOCK_PACKET)
+  XLAT(SOCK_PACKET),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/socktypes.in b/strace/xlat/socktypes.in
new file mode 100644
index 0000000..4b3eadc
--- /dev/null
+++ b/strace/xlat/socktypes.in
@@ -0,0 +1,7 @@
+SOCK_STREAM
+SOCK_DGRAM
+SOCK_RAW
+SOCK_RDM
+SOCK_SEQPACKET
+SOCK_DCCP
+SOCK_PACKET
diff --git a/strace/xlat/splice_flags.h b/strace/xlat/splice_flags.h
new file mode 100644
index 0000000..5d30583
--- /dev/null
+++ b/strace/xlat/splice_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/splice_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat splice_flags in mpers mode
+
+#else
+
+static
+const struct xlat splice_flags[] = {
+#if defined(SPLICE_F_MOVE) || (defined(HAVE_DECL_SPLICE_F_MOVE) && HAVE_DECL_SPLICE_F_MOVE)
+  XLAT(SPLICE_F_MOVE),
+#endif
+#if defined(SPLICE_F_NONBLOCK) || (defined(HAVE_DECL_SPLICE_F_NONBLOCK) && HAVE_DECL_SPLICE_F_NONBLOCK)
+  XLAT(SPLICE_F_NONBLOCK),
+#endif
+#if defined(SPLICE_F_MORE) || (defined(HAVE_DECL_SPLICE_F_MORE) && HAVE_DECL_SPLICE_F_MORE)
+  XLAT(SPLICE_F_MORE),
+#endif
+#if defined(SPLICE_F_GIFT) || (defined(HAVE_DECL_SPLICE_F_GIFT) && HAVE_DECL_SPLICE_F_GIFT)
+  XLAT(SPLICE_F_GIFT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/splice_flags.in b/strace/xlat/splice_flags.in
new file mode 100644
index 0000000..72e2c0b
--- /dev/null
+++ b/strace/xlat/splice_flags.in
@@ -0,0 +1,4 @@
+SPLICE_F_MOVE
+SPLICE_F_NONBLOCK
+SPLICE_F_MORE
+SPLICE_F_GIFT
diff --git a/strace/xlat/sram_alloc_flags.h b/strace/xlat/sram_alloc_flags.h
new file mode 100644
index 0000000..009324f
--- /dev/null
+++ b/strace/xlat/sram_alloc_flags.h
@@ -0,0 +1,29 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sram_alloc_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sram_alloc_flags in mpers mode
+
+#else
+
+static
+const struct xlat sram_alloc_flags[] = {
+#if defined(L1_INST_SRAM) || (defined(HAVE_DECL_L1_INST_SRAM) && HAVE_DECL_L1_INST_SRAM)
+  XLAT(L1_INST_SRAM),
+#endif
+#if defined(L1_DATA_A_SRAM) || (defined(HAVE_DECL_L1_DATA_A_SRAM) && HAVE_DECL_L1_DATA_A_SRAM)
+  XLAT(L1_DATA_A_SRAM),
+#endif
+#if defined(L1_DATA_B_SRAM) || (defined(HAVE_DECL_L1_DATA_B_SRAM) && HAVE_DECL_L1_DATA_B_SRAM)
+  XLAT(L1_DATA_B_SRAM),
+#endif
+#if defined(L1_DATA_SRAM) || (defined(HAVE_DECL_L1_DATA_SRAM) && HAVE_DECL_L1_DATA_SRAM)
+  XLAT(L1_DATA_SRAM),
+#endif
+#if defined(L2_SRAM) || (defined(HAVE_DECL_L2_SRAM) && HAVE_DECL_L2_SRAM)
+  XLAT(L2_SRAM),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sram_alloc_flags.in b/strace/xlat/sram_alloc_flags.in
new file mode 100644
index 0000000..8c06633
--- /dev/null
+++ b/strace/xlat/sram_alloc_flags.in
@@ -0,0 +1,5 @@
+L1_INST_SRAM
+L1_DATA_A_SRAM
+L1_DATA_B_SRAM
+L1_DATA_SRAM
+L2_SRAM
diff --git a/strace/xlat/statfs_flags.h b/strace/xlat/statfs_flags.h
new file mode 100644
index 0000000..149f57f
--- /dev/null
+++ b/strace/xlat/statfs_flags.h
@@ -0,0 +1,54 @@
+/* Generated by ./xlat/gen.sh from ./xlat/statfs_flags.in; do not edit. */
+#if !(defined(ST_VALID) || (defined(HAVE_DECL_ST_VALID) && HAVE_DECL_ST_VALID))
+# define ST_VALID 0x0020
+#endif
+#if !(defined(ST_RDONLY) || (defined(HAVE_DECL_ST_RDONLY) && HAVE_DECL_ST_RDONLY))
+# define ST_RDONLY 0x0001
+#endif
+#if !(defined(ST_NOSUID) || (defined(HAVE_DECL_ST_NOSUID) && HAVE_DECL_ST_NOSUID))
+# define ST_NOSUID 0x0002
+#endif
+#if !(defined(ST_NODEV) || (defined(HAVE_DECL_ST_NODEV) && HAVE_DECL_ST_NODEV))
+# define ST_NODEV 0x0004
+#endif
+#if !(defined(ST_NOEXEC) || (defined(HAVE_DECL_ST_NOEXEC) && HAVE_DECL_ST_NOEXEC))
+# define ST_NOEXEC 0x0008
+#endif
+#if !(defined(ST_SYNCHRONOUS) || (defined(HAVE_DECL_ST_SYNCHRONOUS) && HAVE_DECL_ST_SYNCHRONOUS))
+# define ST_SYNCHRONOUS 0x0010
+#endif
+#if !(defined(ST_MANDLOCK) || (defined(HAVE_DECL_ST_MANDLOCK) && HAVE_DECL_ST_MANDLOCK))
+# define ST_MANDLOCK 0x0040
+#endif
+#if !(defined(ST_NOATIME) || (defined(HAVE_DECL_ST_NOATIME) && HAVE_DECL_ST_NOATIME))
+# define ST_NOATIME 0x0400
+#endif
+#if !(defined(ST_NODIRATIME) || (defined(HAVE_DECL_ST_NODIRATIME) && HAVE_DECL_ST_NODIRATIME))
+# define ST_NODIRATIME 0x0800
+#endif
+#if !(defined(ST_RELATIME) || (defined(HAVE_DECL_ST_RELATIME) && HAVE_DECL_ST_RELATIME))
+# define ST_RELATIME 0x1000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat statfs_flags in mpers mode
+
+#else
+
+static
+const struct xlat statfs_flags[] = {
+ XLAT(ST_VALID),
+ XLAT(ST_RDONLY),
+ XLAT(ST_NOSUID),
+ XLAT(ST_NODEV),
+ XLAT(ST_NOEXEC),
+ XLAT(ST_SYNCHRONOUS),
+ XLAT(ST_MANDLOCK),
+ XLAT(ST_NOATIME),
+ XLAT(ST_NODIRATIME),
+ XLAT(ST_RELATIME),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/statfs_flags.in b/strace/xlat/statfs_flags.in
new file mode 100644
index 0000000..f791a60
--- /dev/null
+++ b/strace/xlat/statfs_flags.in
@@ -0,0 +1,10 @@
+ST_VALID	0x0020
+ST_RDONLY	0x0001
+ST_NOSUID	0x0002
+ST_NODEV	0x0004
+ST_NOEXEC	0x0008
+ST_SYNCHRONOUS	0x0010
+ST_MANDLOCK	0x0040
+ST_NOATIME	0x0400
+ST_NODIRATIME	0x0800
+ST_RELATIME	0x1000
diff --git a/strace/xlat/swap_flags.h b/strace/xlat/swap_flags.h
new file mode 100644
index 0000000..9baec44
--- /dev/null
+++ b/strace/xlat/swap_flags.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/swap_flags.in; do not edit. */
+#if !(defined(SWAP_FLAG_PREFER) || (defined(HAVE_DECL_SWAP_FLAG_PREFER) && HAVE_DECL_SWAP_FLAG_PREFER))
+# define SWAP_FLAG_PREFER 0x8000
+#endif
+#if !(defined(SWAP_FLAG_DISCARD) || (defined(HAVE_DECL_SWAP_FLAG_DISCARD) && HAVE_DECL_SWAP_FLAG_DISCARD))
+# define SWAP_FLAG_DISCARD 0x10000
+#endif
+#if !(defined(SWAP_FLAG_DISCARD_ONCE) || (defined(HAVE_DECL_SWAP_FLAG_DISCARD_ONCE) && HAVE_DECL_SWAP_FLAG_DISCARD_ONCE))
+# define SWAP_FLAG_DISCARD_ONCE 0x20000
+#endif
+#if !(defined(SWAP_FLAG_DISCARD_PAGES) || (defined(HAVE_DECL_SWAP_FLAG_DISCARD_PAGES) && HAVE_DECL_SWAP_FLAG_DISCARD_PAGES))
+# define SWAP_FLAG_DISCARD_PAGES 0x40000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat swap_flags in mpers mode
+
+#else
+
+static
+const struct xlat swap_flags[] = {
+ XLAT(SWAP_FLAG_PREFER),
+ XLAT(SWAP_FLAG_DISCARD),
+ XLAT(SWAP_FLAG_DISCARD_ONCE),
+ XLAT(SWAP_FLAG_DISCARD_PAGES),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/swap_flags.in b/strace/xlat/swap_flags.in
new file mode 100644
index 0000000..8800e30
--- /dev/null
+++ b/strace/xlat/swap_flags.in
@@ -0,0 +1,4 @@
+SWAP_FLAG_PREFER 0x8000
+SWAP_FLAG_DISCARD 0x10000
+SWAP_FLAG_DISCARD_ONCE 0x20000
+SWAP_FLAG_DISCARD_PAGES 0x40000
diff --git a/strace/xlat/sync_file_range_flags.h b/strace/xlat/sync_file_range_flags.h
new file mode 100644
index 0000000..08d9ac1
--- /dev/null
+++ b/strace/xlat/sync_file_range_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sync_file_range_flags.in; do not edit. */
+#if !(defined(SYNC_FILE_RANGE_WAIT_BEFORE) || (defined(HAVE_DECL_SYNC_FILE_RANGE_WAIT_BEFORE) && HAVE_DECL_SYNC_FILE_RANGE_WAIT_BEFORE))
+# define SYNC_FILE_RANGE_WAIT_BEFORE 1
+#endif
+#if !(defined(SYNC_FILE_RANGE_WRITE) || (defined(HAVE_DECL_SYNC_FILE_RANGE_WRITE) && HAVE_DECL_SYNC_FILE_RANGE_WRITE))
+# define SYNC_FILE_RANGE_WRITE 2
+#endif
+#if !(defined(SYNC_FILE_RANGE_WAIT_AFTER) || (defined(HAVE_DECL_SYNC_FILE_RANGE_WAIT_AFTER) && HAVE_DECL_SYNC_FILE_RANGE_WAIT_AFTER))
+# define SYNC_FILE_RANGE_WAIT_AFTER 4
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sync_file_range_flags in mpers mode
+
+#else
+
+static
+const struct xlat sync_file_range_flags[] = {
+ XLAT(SYNC_FILE_RANGE_WAIT_BEFORE),
+ XLAT(SYNC_FILE_RANGE_WRITE),
+ XLAT(SYNC_FILE_RANGE_WAIT_AFTER),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sync_file_range_flags.in b/strace/xlat/sync_file_range_flags.in
new file mode 100644
index 0000000..0b179a1
--- /dev/null
+++ b/strace/xlat/sync_file_range_flags.in
@@ -0,0 +1,3 @@
+SYNC_FILE_RANGE_WAIT_BEFORE	1
+SYNC_FILE_RANGE_WRITE		2
+SYNC_FILE_RANGE_WAIT_AFTER	4
diff --git a/strace/xlat/sysctl_kern.h b/strace/xlat/sysctl_kern.h
new file mode 100644
index 0000000..b7276da
--- /dev/null
+++ b/strace/xlat/sysctl_kern.h
@@ -0,0 +1,114 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_kern.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_kern in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_kern[] = {
+ XLAT(KERN_OSTYPE),
+ XLAT(KERN_OSRELEASE),
+ XLAT(KERN_OSREV),
+ XLAT(KERN_VERSION),
+ XLAT(KERN_SECUREMASK),
+ XLAT(KERN_PROF),
+ XLAT(KERN_NODENAME),
+ XLAT(KERN_DOMAINNAME),
+ XLAT(KERN_PANIC),
+ XLAT(KERN_REALROOTDEV),
+ XLAT(KERN_SPARC_REBOOT),
+ XLAT(KERN_CTLALTDEL),
+ XLAT(KERN_PRINTK),
+ XLAT(KERN_NAMETRANS),
+ XLAT(KERN_PPC_HTABRECLAIM),
+ XLAT(KERN_PPC_ZEROPAGED),
+ XLAT(KERN_PPC_POWERSAVE_NAP),
+ XLAT(KERN_MODPROBE),
+ XLAT(KERN_SG_BIG_BUFF),
+ XLAT(KERN_ACCT),
+ XLAT(KERN_PPC_L2CR),
+ XLAT(KERN_RTSIGNR),
+ XLAT(KERN_RTSIGMAX),
+ XLAT(KERN_SHMMAX),
+ XLAT(KERN_MSGMAX),
+ XLAT(KERN_MSGMNB),
+ XLAT(KERN_MSGPOOL),
+ XLAT(KERN_SYSRQ),
+ XLAT(KERN_MAX_THREADS),
+ XLAT(KERN_RANDOM),
+ XLAT(KERN_SHMALL),
+ XLAT(KERN_MSGMNI),
+ XLAT(KERN_SEM),
+ XLAT(KERN_SPARC_STOP_A),
+ XLAT(KERN_SHMMNI),
+ XLAT(KERN_OVERFLOWUID),
+ XLAT(KERN_OVERFLOWGID),
+ XLAT(KERN_SHMPATH),
+ XLAT(KERN_HOTPLUG),
+ XLAT(KERN_IEEE_EMULATION_WARNINGS),
+ XLAT(KERN_S390_USER_DEBUG_LOGGING),
+ XLAT(KERN_CORE_USES_PID),
+ XLAT(KERN_TAINTED),
+ XLAT(KERN_CADPID),
+ XLAT(KERN_PIDMAX),
+ XLAT(KERN_CORE_PATTERN),
+ XLAT(KERN_PANIC_ON_OOPS),
+ XLAT(KERN_HPPA_PWRSW),
+ XLAT(KERN_HPPA_UNALIGNED),
+#if defined(KERN_PRINTK_RATELIMIT) || (defined(HAVE_DECL_KERN_PRINTK_RATELIMIT) && HAVE_DECL_KERN_PRINTK_RATELIMIT)
+  XLAT(KERN_PRINTK_RATELIMIT),
+#endif
+#if defined(KERN_PRINTK_RATELIMIT_BURST) || (defined(HAVE_DECL_KERN_PRINTK_RATELIMIT_BURST) && HAVE_DECL_KERN_PRINTK_RATELIMIT_BURST)
+  XLAT(KERN_PRINTK_RATELIMIT_BURST),
+#endif
+#if defined(KERN_PTY) || (defined(HAVE_DECL_KERN_PTY) && HAVE_DECL_KERN_PTY)
+  XLAT(KERN_PTY),
+#endif
+#if defined(KERN_NGROUPS_MAX) || (defined(HAVE_DECL_KERN_NGROUPS_MAX) && HAVE_DECL_KERN_NGROUPS_MAX)
+  XLAT(KERN_NGROUPS_MAX),
+#endif
+#if defined(KERN_SPARC_SCONS_PWROFF) || (defined(HAVE_DECL_KERN_SPARC_SCONS_PWROFF) && HAVE_DECL_KERN_SPARC_SCONS_PWROFF)
+  XLAT(KERN_SPARC_SCONS_PWROFF),
+#endif
+#if defined(KERN_HZ_TIMER) || (defined(HAVE_DECL_KERN_HZ_TIMER) && HAVE_DECL_KERN_HZ_TIMER)
+  XLAT(KERN_HZ_TIMER),
+#endif
+#if defined(KERN_UNKNOWN_NMI_PANIC) || (defined(HAVE_DECL_KERN_UNKNOWN_NMI_PANIC) && HAVE_DECL_KERN_UNKNOWN_NMI_PANIC)
+  XLAT(KERN_UNKNOWN_NMI_PANIC),
+#endif
+#if defined(KERN_BOOTLOADER_TYPE) || (defined(HAVE_DECL_KERN_BOOTLOADER_TYPE) && HAVE_DECL_KERN_BOOTLOADER_TYPE)
+  XLAT(KERN_BOOTLOADER_TYPE),
+#endif
+#if defined(KERN_RANDOMIZE) || (defined(HAVE_DECL_KERN_RANDOMIZE) && HAVE_DECL_KERN_RANDOMIZE)
+  XLAT(KERN_RANDOMIZE),
+#endif
+#if defined(KERN_SETUID_DUMPABLE) || (defined(HAVE_DECL_KERN_SETUID_DUMPABLE) && HAVE_DECL_KERN_SETUID_DUMPABLE)
+  XLAT(KERN_SETUID_DUMPABLE),
+#endif
+#if defined(KERN_SPIN_RETRY) || (defined(HAVE_DECL_KERN_SPIN_RETRY) && HAVE_DECL_KERN_SPIN_RETRY)
+  XLAT(KERN_SPIN_RETRY),
+#endif
+#if defined(KERN_ACPI_VIDEO_FLAGS) || (defined(HAVE_DECL_KERN_ACPI_VIDEO_FLAGS) && HAVE_DECL_KERN_ACPI_VIDEO_FLAGS)
+  XLAT(KERN_ACPI_VIDEO_FLAGS),
+#endif
+#if defined(KERN_IA64_UNALIGNED) || (defined(HAVE_DECL_KERN_IA64_UNALIGNED) && HAVE_DECL_KERN_IA64_UNALIGNED)
+  XLAT(KERN_IA64_UNALIGNED),
+#endif
+#if defined(KERN_COMPAT_LOG) || (defined(HAVE_DECL_KERN_COMPAT_LOG) && HAVE_DECL_KERN_COMPAT_LOG)
+  XLAT(KERN_COMPAT_LOG),
+#endif
+#if defined(KERN_MAX_LOCK_DEPTH) || (defined(HAVE_DECL_KERN_MAX_LOCK_DEPTH) && HAVE_DECL_KERN_MAX_LOCK_DEPTH)
+  XLAT(KERN_MAX_LOCK_DEPTH),
+#endif
+#if defined(KERN_NMI_WATCHDOG) || (defined(HAVE_DECL_KERN_NMI_WATCHDOG) && HAVE_DECL_KERN_NMI_WATCHDOG)
+  XLAT(KERN_NMI_WATCHDOG),
+#endif
+#if defined(KERN_PANIC_ON_NMI) || (defined(HAVE_DECL_KERN_PANIC_ON_NMI) && HAVE_DECL_KERN_PANIC_ON_NMI)
+  XLAT(KERN_PANIC_ON_NMI),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_kern.in b/strace/xlat/sysctl_kern.in
new file mode 100644
index 0000000..b0568ce
--- /dev/null
+++ b/strace/xlat/sysctl_kern.in
@@ -0,0 +1,68 @@
+#unconditional
+KERN_OSTYPE
+KERN_OSRELEASE
+KERN_OSREV
+KERN_VERSION
+KERN_SECUREMASK
+KERN_PROF
+KERN_NODENAME
+KERN_DOMAINNAME
+KERN_PANIC
+KERN_REALROOTDEV
+KERN_SPARC_REBOOT
+KERN_CTLALTDEL
+KERN_PRINTK
+KERN_NAMETRANS
+KERN_PPC_HTABRECLAIM
+KERN_PPC_ZEROPAGED
+KERN_PPC_POWERSAVE_NAP
+KERN_MODPROBE
+KERN_SG_BIG_BUFF
+KERN_ACCT
+KERN_PPC_L2CR
+KERN_RTSIGNR
+KERN_RTSIGMAX
+KERN_SHMMAX
+KERN_MSGMAX
+KERN_MSGMNB
+KERN_MSGPOOL
+KERN_SYSRQ
+KERN_MAX_THREADS
+KERN_RANDOM
+KERN_SHMALL
+KERN_MSGMNI
+KERN_SEM
+KERN_SPARC_STOP_A
+KERN_SHMMNI
+KERN_OVERFLOWUID
+KERN_OVERFLOWGID
+KERN_SHMPATH
+KERN_HOTPLUG
+KERN_IEEE_EMULATION_WARNINGS
+KERN_S390_USER_DEBUG_LOGGING
+KERN_CORE_USES_PID
+KERN_TAINTED
+KERN_CADPID
+KERN_PIDMAX
+KERN_CORE_PATTERN
+KERN_PANIC_ON_OOPS
+KERN_HPPA_PWRSW
+KERN_HPPA_UNALIGNED
+#conditional
+KERN_PRINTK_RATELIMIT
+KERN_PRINTK_RATELIMIT_BURST
+KERN_PTY
+KERN_NGROUPS_MAX
+KERN_SPARC_SCONS_PWROFF
+KERN_HZ_TIMER
+KERN_UNKNOWN_NMI_PANIC
+KERN_BOOTLOADER_TYPE
+KERN_RANDOMIZE
+KERN_SETUID_DUMPABLE
+KERN_SPIN_RETRY
+KERN_ACPI_VIDEO_FLAGS
+KERN_IA64_UNALIGNED
+KERN_COMPAT_LOG
+KERN_MAX_LOCK_DEPTH
+KERN_NMI_WATCHDOG
+KERN_PANIC_ON_NMI
diff --git a/strace/xlat/sysctl_net.h b/strace/xlat/sysctl_net.h
new file mode 100644
index 0000000..864c548
--- /dev/null
+++ b/strace/xlat/sysctl_net.h
@@ -0,0 +1,43 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net[] = {
+ XLAT(NET_CORE),
+ XLAT(NET_ETHER),
+ XLAT(NET_802),
+ XLAT(NET_UNIX),
+ XLAT(NET_IPV4),
+ XLAT(NET_IPX),
+ XLAT(NET_ATALK),
+ XLAT(NET_NETROM),
+ XLAT(NET_AX25),
+ XLAT(NET_BRIDGE),
+ XLAT(NET_ROSE),
+ XLAT(NET_IPV6),
+ XLAT(NET_X25),
+ XLAT(NET_TR),
+ XLAT(NET_DECNET),
+ XLAT(NET_ECONET),
+ XLAT(NET_SCTP),
+#if defined(NET_LLC) || (defined(HAVE_DECL_NET_LLC) && HAVE_DECL_NET_LLC)
+  XLAT(NET_LLC),
+#endif
+#if defined(NET_NETFILTER) || (defined(HAVE_DECL_NET_NETFILTER) && HAVE_DECL_NET_NETFILTER)
+  XLAT(NET_NETFILTER),
+#endif
+#if defined(NET_DCCP) || (defined(HAVE_DECL_NET_DCCP) && HAVE_DECL_NET_DCCP)
+  XLAT(NET_DCCP),
+#endif
+#if defined(NET_IRDA) || (defined(HAVE_DECL_NET_IRDA) && HAVE_DECL_NET_IRDA)
+  XLAT(NET_IRDA),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net.in b/strace/xlat/sysctl_net.in
new file mode 100644
index 0000000..cb08d91
--- /dev/null
+++ b/strace/xlat/sysctl_net.in
@@ -0,0 +1,23 @@
+#unconditional
+NET_CORE
+NET_ETHER
+NET_802
+NET_UNIX
+NET_IPV4
+NET_IPX
+NET_ATALK
+NET_NETROM
+NET_AX25
+NET_BRIDGE
+NET_ROSE
+NET_IPV6
+NET_X25
+NET_TR
+NET_DECNET
+NET_ECONET
+NET_SCTP
+#conditional
+NET_LLC
+NET_NETFILTER
+NET_DCCP
+NET_IRDA
diff --git a/strace/xlat/sysctl_net_core.h b/strace/xlat/sysctl_net_core.h
new file mode 100644
index 0000000..d3db06c
--- /dev/null
+++ b/strace/xlat/sysctl_net_core.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_core.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_core in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_core[] = {
+ XLAT(NET_CORE_WMEM_MAX),
+ XLAT(NET_CORE_RMEM_MAX),
+ XLAT(NET_CORE_WMEM_DEFAULT),
+ XLAT(NET_CORE_RMEM_DEFAULT),
+ XLAT(NET_CORE_MAX_BACKLOG),
+ XLAT(NET_CORE_FASTROUTE),
+ XLAT(NET_CORE_MSG_COST),
+ XLAT(NET_CORE_MSG_BURST),
+ XLAT(NET_CORE_OPTMEM_MAX),
+ XLAT(NET_CORE_HOT_LIST_LENGTH),
+ XLAT(NET_CORE_DIVERT_VERSION),
+ XLAT(NET_CORE_NO_CONG_THRESH),
+ XLAT(NET_CORE_NO_CONG),
+ XLAT(NET_CORE_LO_CONG),
+ XLAT(NET_CORE_MOD_CONG),
+ XLAT(NET_CORE_DEV_WEIGHT),
+ XLAT(NET_CORE_SOMAXCONN),
+#if defined(NET_CORE_DESTROY_DELAY) || (defined(HAVE_DECL_NET_CORE_DESTROY_DELAY) && HAVE_DECL_NET_CORE_DESTROY_DELAY)
+  XLAT(NET_CORE_DESTROY_DELAY),
+#endif
+#if defined(NET_CORE_BUDGET) || (defined(HAVE_DECL_NET_CORE_BUDGET) && HAVE_DECL_NET_CORE_BUDGET)
+  XLAT(NET_CORE_BUDGET),
+#endif
+#if defined(NET_CORE_AEVENT_ETIME) || (defined(HAVE_DECL_NET_CORE_AEVENT_ETIME) && HAVE_DECL_NET_CORE_AEVENT_ETIME)
+  XLAT(NET_CORE_AEVENT_ETIME),
+#endif
+#if defined(NET_CORE_AEVENT_RSEQTH) || (defined(HAVE_DECL_NET_CORE_AEVENT_RSEQTH) && HAVE_DECL_NET_CORE_AEVENT_RSEQTH)
+  XLAT(NET_CORE_AEVENT_RSEQTH),
+#endif
+#if defined(NET_CORE_WARNINGS) || (defined(HAVE_DECL_NET_CORE_WARNINGS) && HAVE_DECL_NET_CORE_WARNINGS)
+  XLAT(NET_CORE_WARNINGS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_core.in b/strace/xlat/sysctl_net_core.in
new file mode 100644
index 0000000..054fd9f
--- /dev/null
+++ b/strace/xlat/sysctl_net_core.in
@@ -0,0 +1,24 @@
+#unconditional
+NET_CORE_WMEM_MAX
+NET_CORE_RMEM_MAX
+NET_CORE_WMEM_DEFAULT
+NET_CORE_RMEM_DEFAULT
+NET_CORE_MAX_BACKLOG
+NET_CORE_FASTROUTE
+NET_CORE_MSG_COST
+NET_CORE_MSG_BURST
+NET_CORE_OPTMEM_MAX
+NET_CORE_HOT_LIST_LENGTH
+NET_CORE_DIVERT_VERSION
+NET_CORE_NO_CONG_THRESH
+NET_CORE_NO_CONG
+NET_CORE_LO_CONG
+NET_CORE_MOD_CONG
+NET_CORE_DEV_WEIGHT
+NET_CORE_SOMAXCONN
+#conditional
+NET_CORE_DESTROY_DELAY
+NET_CORE_BUDGET
+NET_CORE_AEVENT_ETIME
+NET_CORE_AEVENT_RSEQTH
+NET_CORE_WARNINGS
diff --git a/strace/xlat/sysctl_net_ipv4.h b/strace/xlat/sysctl_net_ipv4.h
new file mode 100644
index 0000000..cd0a005
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv4.h
@@ -0,0 +1,152 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_ipv4.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_ipv4 in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_ipv4[] = {
+ XLAT(NET_IPV4_FORWARD),
+ XLAT(NET_IPV4_DYNADDR),
+ XLAT(NET_IPV4_CONF),
+ XLAT(NET_IPV4_NEIGH),
+ XLAT(NET_IPV4_ROUTE),
+ XLAT(NET_IPV4_FIB_HASH),
+ XLAT(NET_IPV4_NETFILTER),
+ XLAT(NET_IPV4_TCP_TIMESTAMPS),
+ XLAT(NET_IPV4_TCP_WINDOW_SCALING),
+ XLAT(NET_IPV4_TCP_SACK),
+ XLAT(NET_IPV4_TCP_RETRANS_COLLAPSE),
+ XLAT(NET_IPV4_DEFAULT_TTL),
+ XLAT(NET_IPV4_AUTOCONFIG),
+ XLAT(NET_IPV4_NO_PMTU_DISC),
+ XLAT(NET_IPV4_TCP_SYN_RETRIES),
+ XLAT(NET_IPV4_IPFRAG_HIGH_THRESH),
+ XLAT(NET_IPV4_IPFRAG_LOW_THRESH),
+ XLAT(NET_IPV4_IPFRAG_TIME),
+ XLAT(NET_IPV4_TCP_MAX_KA_PROBES),
+ XLAT(NET_IPV4_TCP_KEEPALIVE_TIME),
+ XLAT(NET_IPV4_TCP_KEEPALIVE_PROBES),
+ XLAT(NET_IPV4_TCP_RETRIES1),
+ XLAT(NET_IPV4_TCP_RETRIES2),
+ XLAT(NET_IPV4_TCP_FIN_TIMEOUT),
+ XLAT(NET_IPV4_IP_MASQ_DEBUG),
+ XLAT(NET_TCP_SYNCOOKIES),
+ XLAT(NET_TCP_STDURG),
+ XLAT(NET_TCP_RFC1337),
+ XLAT(NET_TCP_SYN_TAILDROP),
+ XLAT(NET_TCP_MAX_SYN_BACKLOG),
+ XLAT(NET_IPV4_LOCAL_PORT_RANGE),
+ XLAT(NET_IPV4_ICMP_ECHO_IGNORE_ALL),
+ XLAT(NET_IPV4_ICMP_ECHO_IGNORE_BROADCASTS),
+ XLAT(NET_IPV4_ICMP_SOURCEQUENCH_RATE),
+ XLAT(NET_IPV4_ICMP_DESTUNREACH_RATE),
+ XLAT(NET_IPV4_ICMP_TIMEEXCEED_RATE),
+ XLAT(NET_IPV4_ICMP_PARAMPROB_RATE),
+ XLAT(NET_IPV4_ICMP_ECHOREPLY_RATE),
+ XLAT(NET_IPV4_ICMP_IGNORE_BOGUS_ERROR_RESPONSES),
+ XLAT(NET_IPV4_IGMP_MAX_MEMBERSHIPS),
+ XLAT(NET_TCP_TW_RECYCLE),
+ XLAT(NET_IPV4_ALWAYS_DEFRAG),
+ XLAT(NET_IPV4_TCP_KEEPALIVE_INTVL),
+ XLAT(NET_IPV4_INET_PEER_THRESHOLD),
+ XLAT(NET_IPV4_INET_PEER_MINTTL),
+ XLAT(NET_IPV4_INET_PEER_MAXTTL),
+ XLAT(NET_IPV4_INET_PEER_GC_MINTIME),
+ XLAT(NET_IPV4_INET_PEER_GC_MAXTIME),
+ XLAT(NET_TCP_ORPHAN_RETRIES),
+ XLAT(NET_TCP_ABORT_ON_OVERFLOW),
+ XLAT(NET_TCP_SYNACK_RETRIES),
+ XLAT(NET_TCP_MAX_ORPHANS),
+ XLAT(NET_TCP_MAX_TW_BUCKETS),
+ XLAT(NET_TCP_FACK),
+ XLAT(NET_TCP_REORDERING),
+ XLAT(NET_TCP_ECN),
+ XLAT(NET_TCP_DSACK),
+ XLAT(NET_TCP_MEM),
+ XLAT(NET_TCP_WMEM),
+ XLAT(NET_TCP_RMEM),
+ XLAT(NET_TCP_APP_WIN),
+ XLAT(NET_TCP_ADV_WIN_SCALE),
+ XLAT(NET_IPV4_NONLOCAL_BIND),
+ XLAT(NET_IPV4_ICMP_RATELIMIT),
+ XLAT(NET_IPV4_ICMP_RATEMASK),
+ XLAT(NET_TCP_TW_REUSE),
+ XLAT(NET_TCP_FRTO),
+ XLAT(NET_TCP_LOW_LATENCY),
+ XLAT(NET_IPV4_IPFRAG_SECRET_INTERVAL),
+#if defined(NET_IPV4_IGMP_MAX_MSF) || (defined(HAVE_DECL_NET_IPV4_IGMP_MAX_MSF) && HAVE_DECL_NET_IPV4_IGMP_MAX_MSF)
+  XLAT(NET_IPV4_IGMP_MAX_MSF),
+#endif
+#if defined(NET_TCP_NO_METRICS_SAVE) || (defined(HAVE_DECL_NET_TCP_NO_METRICS_SAVE) && HAVE_DECL_NET_TCP_NO_METRICS_SAVE)
+  XLAT(NET_TCP_NO_METRICS_SAVE),
+#endif
+#if defined(NET_TCP_DEFAULT_WIN_SCALE) || (defined(HAVE_DECL_NET_TCP_DEFAULT_WIN_SCALE) && HAVE_DECL_NET_TCP_DEFAULT_WIN_SCALE)
+  XLAT(NET_TCP_DEFAULT_WIN_SCALE),
+#endif
+#if defined(NET_TCP_MODERATE_RCVBUF) || (defined(HAVE_DECL_NET_TCP_MODERATE_RCVBUF) && HAVE_DECL_NET_TCP_MODERATE_RCVBUF)
+  XLAT(NET_TCP_MODERATE_RCVBUF),
+#endif
+#if defined(NET_TCP_TSO_WIN_DIVISOR) || (defined(HAVE_DECL_NET_TCP_TSO_WIN_DIVISOR) && HAVE_DECL_NET_TCP_TSO_WIN_DIVISOR)
+  XLAT(NET_TCP_TSO_WIN_DIVISOR),
+#endif
+#if defined(NET_TCP_BIC_BETA) || (defined(HAVE_DECL_NET_TCP_BIC_BETA) && HAVE_DECL_NET_TCP_BIC_BETA)
+  XLAT(NET_TCP_BIC_BETA),
+#endif
+#if defined(NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR) || (defined(HAVE_DECL_NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR) && HAVE_DECL_NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR)
+  XLAT(NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR),
+#endif
+#if defined(NET_TCP_CONG_CONTROL) || (defined(HAVE_DECL_NET_TCP_CONG_CONTROL) && HAVE_DECL_NET_TCP_CONG_CONTROL)
+  XLAT(NET_TCP_CONG_CONTROL),
+#endif
+#if defined(NET_TCP_ABC) || (defined(HAVE_DECL_NET_TCP_ABC) && HAVE_DECL_NET_TCP_ABC)
+  XLAT(NET_TCP_ABC),
+#endif
+#if defined(NET_IPV4_IPFRAG_MAX_DIST) || (defined(HAVE_DECL_NET_IPV4_IPFRAG_MAX_DIST) && HAVE_DECL_NET_IPV4_IPFRAG_MAX_DIST)
+  XLAT(NET_IPV4_IPFRAG_MAX_DIST),
+#endif
+#if defined(NET_TCP_MTU_PROBING) || (defined(HAVE_DECL_NET_TCP_MTU_PROBING) && HAVE_DECL_NET_TCP_MTU_PROBING)
+  XLAT(NET_TCP_MTU_PROBING),
+#endif
+#if defined(NET_TCP_BASE_MSS) || (defined(HAVE_DECL_NET_TCP_BASE_MSS) && HAVE_DECL_NET_TCP_BASE_MSS)
+  XLAT(NET_TCP_BASE_MSS),
+#endif
+#if defined(NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS) || (defined(HAVE_DECL_NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS) && HAVE_DECL_NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS)
+  XLAT(NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS),
+#endif
+#if defined(NET_TCP_DMA_COPYBREAK) || (defined(HAVE_DECL_NET_TCP_DMA_COPYBREAK) && HAVE_DECL_NET_TCP_DMA_COPYBREAK)
+  XLAT(NET_TCP_DMA_COPYBREAK),
+#endif
+#if defined(NET_TCP_SLOW_START_AFTER_IDLE) || (defined(HAVE_DECL_NET_TCP_SLOW_START_AFTER_IDLE) && HAVE_DECL_NET_TCP_SLOW_START_AFTER_IDLE)
+  XLAT(NET_TCP_SLOW_START_AFTER_IDLE),
+#endif
+#if defined(NET_CIPSOV4_CACHE_ENABLE) || (defined(HAVE_DECL_NET_CIPSOV4_CACHE_ENABLE) && HAVE_DECL_NET_CIPSOV4_CACHE_ENABLE)
+  XLAT(NET_CIPSOV4_CACHE_ENABLE),
+#endif
+#if defined(NET_CIPSOV4_CACHE_BUCKET_SIZE) || (defined(HAVE_DECL_NET_CIPSOV4_CACHE_BUCKET_SIZE) && HAVE_DECL_NET_CIPSOV4_CACHE_BUCKET_SIZE)
+  XLAT(NET_CIPSOV4_CACHE_BUCKET_SIZE),
+#endif
+#if defined(NET_CIPSOV4_RBM_OPTFMT) || (defined(HAVE_DECL_NET_CIPSOV4_RBM_OPTFMT) && HAVE_DECL_NET_CIPSOV4_RBM_OPTFMT)
+  XLAT(NET_CIPSOV4_RBM_OPTFMT),
+#endif
+#if defined(NET_CIPSOV4_RBM_STRICTVALID) || (defined(HAVE_DECL_NET_CIPSOV4_RBM_STRICTVALID) && HAVE_DECL_NET_CIPSOV4_RBM_STRICTVALID)
+  XLAT(NET_CIPSOV4_RBM_STRICTVALID),
+#endif
+#if defined(NET_TCP_AVAIL_CONG_CONTROL) || (defined(HAVE_DECL_NET_TCP_AVAIL_CONG_CONTROL) && HAVE_DECL_NET_TCP_AVAIL_CONG_CONTROL)
+  XLAT(NET_TCP_AVAIL_CONG_CONTROL),
+#endif
+#if defined(NET_TCP_ALLOWED_CONG_CONTROL) || (defined(HAVE_DECL_NET_TCP_ALLOWED_CONG_CONTROL) && HAVE_DECL_NET_TCP_ALLOWED_CONG_CONTROL)
+  XLAT(NET_TCP_ALLOWED_CONG_CONTROL),
+#endif
+#if defined(NET_TCP_MAX_SSTHRESH) || (defined(HAVE_DECL_NET_TCP_MAX_SSTHRESH) && HAVE_DECL_NET_TCP_MAX_SSTHRESH)
+  XLAT(NET_TCP_MAX_SSTHRESH),
+#endif
+#if defined(NET_TCP_FRTO_RESPONSE) || (defined(HAVE_DECL_NET_TCP_FRTO_RESPONSE) && HAVE_DECL_NET_TCP_FRTO_RESPONSE)
+  XLAT(NET_TCP_FRTO_RESPONSE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_ipv4.in b/strace/xlat/sysctl_net_ipv4.in
new file mode 100644
index 0000000..8f452e8
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv4.in
@@ -0,0 +1,94 @@
+#unconditional
+NET_IPV4_FORWARD
+NET_IPV4_DYNADDR
+NET_IPV4_CONF
+NET_IPV4_NEIGH
+NET_IPV4_ROUTE
+NET_IPV4_FIB_HASH
+NET_IPV4_NETFILTER
+NET_IPV4_TCP_TIMESTAMPS
+NET_IPV4_TCP_WINDOW_SCALING
+NET_IPV4_TCP_SACK
+NET_IPV4_TCP_RETRANS_COLLAPSE
+NET_IPV4_DEFAULT_TTL
+NET_IPV4_AUTOCONFIG
+NET_IPV4_NO_PMTU_DISC
+NET_IPV4_TCP_SYN_RETRIES
+NET_IPV4_IPFRAG_HIGH_THRESH
+NET_IPV4_IPFRAG_LOW_THRESH
+NET_IPV4_IPFRAG_TIME
+NET_IPV4_TCP_MAX_KA_PROBES
+NET_IPV4_TCP_KEEPALIVE_TIME
+NET_IPV4_TCP_KEEPALIVE_PROBES
+NET_IPV4_TCP_RETRIES1
+NET_IPV4_TCP_RETRIES2
+NET_IPV4_TCP_FIN_TIMEOUT
+NET_IPV4_IP_MASQ_DEBUG
+NET_TCP_SYNCOOKIES
+NET_TCP_STDURG
+NET_TCP_RFC1337
+NET_TCP_SYN_TAILDROP
+NET_TCP_MAX_SYN_BACKLOG
+NET_IPV4_LOCAL_PORT_RANGE
+NET_IPV4_ICMP_ECHO_IGNORE_ALL
+NET_IPV4_ICMP_ECHO_IGNORE_BROADCASTS
+NET_IPV4_ICMP_SOURCEQUENCH_RATE
+NET_IPV4_ICMP_DESTUNREACH_RATE
+NET_IPV4_ICMP_TIMEEXCEED_RATE
+NET_IPV4_ICMP_PARAMPROB_RATE
+NET_IPV4_ICMP_ECHOREPLY_RATE
+NET_IPV4_ICMP_IGNORE_BOGUS_ERROR_RESPONSES
+NET_IPV4_IGMP_MAX_MEMBERSHIPS
+NET_TCP_TW_RECYCLE
+NET_IPV4_ALWAYS_DEFRAG
+NET_IPV4_TCP_KEEPALIVE_INTVL
+NET_IPV4_INET_PEER_THRESHOLD
+NET_IPV4_INET_PEER_MINTTL
+NET_IPV4_INET_PEER_MAXTTL
+NET_IPV4_INET_PEER_GC_MINTIME
+NET_IPV4_INET_PEER_GC_MAXTIME
+NET_TCP_ORPHAN_RETRIES
+NET_TCP_ABORT_ON_OVERFLOW
+NET_TCP_SYNACK_RETRIES
+NET_TCP_MAX_ORPHANS
+NET_TCP_MAX_TW_BUCKETS
+NET_TCP_FACK
+NET_TCP_REORDERING
+NET_TCP_ECN
+NET_TCP_DSACK
+NET_TCP_MEM
+NET_TCP_WMEM
+NET_TCP_RMEM
+NET_TCP_APP_WIN
+NET_TCP_ADV_WIN_SCALE
+NET_IPV4_NONLOCAL_BIND
+NET_IPV4_ICMP_RATELIMIT
+NET_IPV4_ICMP_RATEMASK
+NET_TCP_TW_REUSE
+NET_TCP_FRTO
+NET_TCP_LOW_LATENCY
+NET_IPV4_IPFRAG_SECRET_INTERVAL
+#conditional
+NET_IPV4_IGMP_MAX_MSF
+NET_TCP_NO_METRICS_SAVE
+NET_TCP_DEFAULT_WIN_SCALE
+NET_TCP_MODERATE_RCVBUF
+NET_TCP_TSO_WIN_DIVISOR
+NET_TCP_BIC_BETA
+NET_IPV4_ICMP_ERRORS_USE_INBOUND_IFADDR
+NET_TCP_CONG_CONTROL
+NET_TCP_ABC
+NET_IPV4_IPFRAG_MAX_DIST
+NET_TCP_MTU_PROBING
+NET_TCP_BASE_MSS
+NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS
+NET_TCP_DMA_COPYBREAK
+NET_TCP_SLOW_START_AFTER_IDLE
+NET_CIPSOV4_CACHE_ENABLE
+NET_CIPSOV4_CACHE_BUCKET_SIZE
+NET_CIPSOV4_RBM_OPTFMT
+NET_CIPSOV4_RBM_STRICTVALID
+NET_TCP_AVAIL_CONG_CONTROL
+NET_TCP_ALLOWED_CONG_CONTROL
+NET_TCP_MAX_SSTHRESH
+NET_TCP_FRTO_RESPONSE
diff --git a/strace/xlat/sysctl_net_ipv4_conf.h b/strace/xlat/sysctl_net_ipv4_conf.h
new file mode 100644
index 0000000..c9cd4dc
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv4_conf.h
@@ -0,0 +1,48 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_ipv4_conf.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_ipv4_conf in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_ipv4_conf[] = {
+ XLAT(NET_IPV4_CONF_FORWARDING),
+ XLAT(NET_IPV4_CONF_MC_FORWARDING),
+ XLAT(NET_IPV4_CONF_PROXY_ARP),
+ XLAT(NET_IPV4_CONF_ACCEPT_REDIRECTS),
+ XLAT(NET_IPV4_CONF_SECURE_REDIRECTS),
+ XLAT(NET_IPV4_CONF_SEND_REDIRECTS),
+ XLAT(NET_IPV4_CONF_SHARED_MEDIA),
+ XLAT(NET_IPV4_CONF_RP_FILTER),
+ XLAT(NET_IPV4_CONF_ACCEPT_SOURCE_ROUTE),
+ XLAT(NET_IPV4_CONF_BOOTP_RELAY),
+ XLAT(NET_IPV4_CONF_LOG_MARTIANS),
+ XLAT(NET_IPV4_CONF_TAG),
+ XLAT(NET_IPV4_CONF_ARPFILTER),
+ XLAT(NET_IPV4_CONF_MEDIUM_ID),
+ XLAT(NET_IPV4_CONF_NOXFRM),
+ XLAT(NET_IPV4_CONF_NOPOLICY),
+#if defined(NET_IPV4_CONF_FORCE_IGMP_VERSION) || (defined(HAVE_DECL_NET_IPV4_CONF_FORCE_IGMP_VERSION) && HAVE_DECL_NET_IPV4_CONF_FORCE_IGMP_VERSION)
+  XLAT(NET_IPV4_CONF_FORCE_IGMP_VERSION),
+#endif
+#if defined(NET_IPV4_CONF_ARP_ANNOUNCE) || (defined(HAVE_DECL_NET_IPV4_CONF_ARP_ANNOUNCE) && HAVE_DECL_NET_IPV4_CONF_ARP_ANNOUNCE)
+  XLAT(NET_IPV4_CONF_ARP_ANNOUNCE),
+#endif
+#if defined(NET_IPV4_CONF_ARP_IGNORE) || (defined(HAVE_DECL_NET_IPV4_CONF_ARP_IGNORE) && HAVE_DECL_NET_IPV4_CONF_ARP_IGNORE)
+  XLAT(NET_IPV4_CONF_ARP_IGNORE),
+#endif
+#if defined(NET_IPV4_CONF_PROMOTE_SECONDARIES) || (defined(HAVE_DECL_NET_IPV4_CONF_PROMOTE_SECONDARIES) && HAVE_DECL_NET_IPV4_CONF_PROMOTE_SECONDARIES)
+  XLAT(NET_IPV4_CONF_PROMOTE_SECONDARIES),
+#endif
+#if defined(NET_IPV4_CONF_ARP_ACCEPT) || (defined(HAVE_DECL_NET_IPV4_CONF_ARP_ACCEPT) && HAVE_DECL_NET_IPV4_CONF_ARP_ACCEPT)
+  XLAT(NET_IPV4_CONF_ARP_ACCEPT),
+#endif
+#if defined(NET_IPV4_CONF_ARP_NOTIFY) || (defined(HAVE_DECL_NET_IPV4_CONF_ARP_NOTIFY) && HAVE_DECL_NET_IPV4_CONF_ARP_NOTIFY)
+  XLAT(NET_IPV4_CONF_ARP_NOTIFY),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_ipv4_conf.in b/strace/xlat/sysctl_net_ipv4_conf.in
new file mode 100644
index 0000000..be94bd2
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv4_conf.in
@@ -0,0 +1,24 @@
+#unconditional
+NET_IPV4_CONF_FORWARDING
+NET_IPV4_CONF_MC_FORWARDING
+NET_IPV4_CONF_PROXY_ARP
+NET_IPV4_CONF_ACCEPT_REDIRECTS
+NET_IPV4_CONF_SECURE_REDIRECTS
+NET_IPV4_CONF_SEND_REDIRECTS
+NET_IPV4_CONF_SHARED_MEDIA
+NET_IPV4_CONF_RP_FILTER
+NET_IPV4_CONF_ACCEPT_SOURCE_ROUTE
+NET_IPV4_CONF_BOOTP_RELAY
+NET_IPV4_CONF_LOG_MARTIANS
+NET_IPV4_CONF_TAG
+NET_IPV4_CONF_ARPFILTER
+NET_IPV4_CONF_MEDIUM_ID
+NET_IPV4_CONF_NOXFRM
+NET_IPV4_CONF_NOPOLICY
+#conditional
+NET_IPV4_CONF_FORCE_IGMP_VERSION
+NET_IPV4_CONF_ARP_ANNOUNCE
+NET_IPV4_CONF_ARP_IGNORE
+NET_IPV4_CONF_PROMOTE_SECONDARIES
+NET_IPV4_CONF_ARP_ACCEPT
+NET_IPV4_CONF_ARP_NOTIFY
diff --git a/strace/xlat/sysctl_net_ipv4_route.h b/strace/xlat/sysctl_net_ipv4_route.h
new file mode 100644
index 0000000..91983e4
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv4_route.h
@@ -0,0 +1,35 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_ipv4_route.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_ipv4_route in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_ipv4_route[] = {
+ XLAT(NET_IPV4_ROUTE_FLUSH),
+ XLAT(NET_IPV4_ROUTE_MIN_DELAY),
+ XLAT(NET_IPV4_ROUTE_MAX_DELAY),
+ XLAT(NET_IPV4_ROUTE_GC_THRESH),
+ XLAT(NET_IPV4_ROUTE_MAX_SIZE),
+ XLAT(NET_IPV4_ROUTE_GC_MIN_INTERVAL),
+ XLAT(NET_IPV4_ROUTE_GC_TIMEOUT),
+ XLAT(NET_IPV4_ROUTE_GC_INTERVAL),
+ XLAT(NET_IPV4_ROUTE_REDIRECT_LOAD),
+ XLAT(NET_IPV4_ROUTE_REDIRECT_NUMBER),
+ XLAT(NET_IPV4_ROUTE_REDIRECT_SILENCE),
+ XLAT(NET_IPV4_ROUTE_ERROR_COST),
+ XLAT(NET_IPV4_ROUTE_ERROR_BURST),
+ XLAT(NET_IPV4_ROUTE_GC_ELASTICITY),
+ XLAT(NET_IPV4_ROUTE_MTU_EXPIRES),
+ XLAT(NET_IPV4_ROUTE_MIN_PMTU),
+ XLAT(NET_IPV4_ROUTE_MIN_ADVMSS),
+ XLAT(NET_IPV4_ROUTE_SECRET_INTERVAL),
+#if defined(NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS) || (defined(HAVE_DECL_NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS) && HAVE_DECL_NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS)
+  XLAT(NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_ipv4_route.in b/strace/xlat/sysctl_net_ipv4_route.in
new file mode 100644
index 0000000..a77cf41
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv4_route.in
@@ -0,0 +1,21 @@
+#unconditional
+NET_IPV4_ROUTE_FLUSH
+NET_IPV4_ROUTE_MIN_DELAY
+NET_IPV4_ROUTE_MAX_DELAY
+NET_IPV4_ROUTE_GC_THRESH
+NET_IPV4_ROUTE_MAX_SIZE
+NET_IPV4_ROUTE_GC_MIN_INTERVAL
+NET_IPV4_ROUTE_GC_TIMEOUT
+NET_IPV4_ROUTE_GC_INTERVAL
+NET_IPV4_ROUTE_REDIRECT_LOAD
+NET_IPV4_ROUTE_REDIRECT_NUMBER
+NET_IPV4_ROUTE_REDIRECT_SILENCE
+NET_IPV4_ROUTE_ERROR_COST
+NET_IPV4_ROUTE_ERROR_BURST
+NET_IPV4_ROUTE_GC_ELASTICITY
+NET_IPV4_ROUTE_MTU_EXPIRES
+NET_IPV4_ROUTE_MIN_PMTU
+NET_IPV4_ROUTE_MIN_ADVMSS
+NET_IPV4_ROUTE_SECRET_INTERVAL
+#conditional
+NET_IPV4_ROUTE_GC_MIN_INTERVAL_MS
diff --git a/strace/xlat/sysctl_net_ipv6.h b/strace/xlat/sysctl_net_ipv6.h
new file mode 100644
index 0000000..c92a16c
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv6.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_ipv6.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_ipv6 in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_ipv6[] = {
+ XLAT(NET_IPV6_CONF),
+ XLAT(NET_IPV6_NEIGH),
+ XLAT(NET_IPV6_ROUTE),
+ XLAT(NET_IPV6_ICMP),
+ XLAT(NET_IPV6_BINDV6ONLY),
+ XLAT(NET_IPV6_IP6FRAG_HIGH_THRESH),
+ XLAT(NET_IPV6_IP6FRAG_LOW_THRESH),
+ XLAT(NET_IPV6_IP6FRAG_TIME),
+ XLAT(NET_IPV6_IP6FRAG_SECRET_INTERVAL),
+#if defined(NET_IPV6_MLD_MAX_MSF) || (defined(HAVE_DECL_NET_IPV6_MLD_MAX_MSF) && HAVE_DECL_NET_IPV6_MLD_MAX_MSF)
+  XLAT(NET_IPV6_MLD_MAX_MSF),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_ipv6.in b/strace/xlat/sysctl_net_ipv6.in
new file mode 100644
index 0000000..711dbb5
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv6.in
@@ -0,0 +1,12 @@
+#unconditional
+NET_IPV6_CONF
+NET_IPV6_NEIGH
+NET_IPV6_ROUTE
+NET_IPV6_ICMP
+NET_IPV6_BINDV6ONLY
+NET_IPV6_IP6FRAG_HIGH_THRESH
+NET_IPV6_IP6FRAG_LOW_THRESH
+NET_IPV6_IP6FRAG_TIME
+NET_IPV6_IP6FRAG_SECRET_INTERVAL
+#conditional
+NET_IPV6_MLD_MAX_MSF
diff --git a/strace/xlat/sysctl_net_ipv6_route.h b/strace/xlat/sysctl_net_ipv6_route.h
new file mode 100644
index 0000000..cc976ff
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv6_route.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_ipv6_route.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_ipv6_route in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_ipv6_route[] = {
+ XLAT(NET_IPV6_ROUTE_FLUSH),
+ XLAT(NET_IPV6_ROUTE_GC_THRESH),
+ XLAT(NET_IPV6_ROUTE_MAX_SIZE),
+ XLAT(NET_IPV6_ROUTE_GC_MIN_INTERVAL),
+ XLAT(NET_IPV6_ROUTE_GC_TIMEOUT),
+ XLAT(NET_IPV6_ROUTE_GC_INTERVAL),
+ XLAT(NET_IPV6_ROUTE_GC_ELASTICITY),
+ XLAT(NET_IPV6_ROUTE_MTU_EXPIRES),
+ XLAT(NET_IPV6_ROUTE_MIN_ADVMSS),
+#if defined(NET_IPV6_ROUTE_GC_MIN_INTERVAL_MS) || (defined(HAVE_DECL_NET_IPV6_ROUTE_GC_MIN_INTERVAL_MS) && HAVE_DECL_NET_IPV6_ROUTE_GC_MIN_INTERVAL_MS)
+  XLAT(NET_IPV6_ROUTE_GC_MIN_INTERVAL_MS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_ipv6_route.in b/strace/xlat/sysctl_net_ipv6_route.in
new file mode 100644
index 0000000..53e3800
--- /dev/null
+++ b/strace/xlat/sysctl_net_ipv6_route.in
@@ -0,0 +1,12 @@
+#unconditional
+NET_IPV6_ROUTE_FLUSH
+NET_IPV6_ROUTE_GC_THRESH
+NET_IPV6_ROUTE_MAX_SIZE
+NET_IPV6_ROUTE_GC_MIN_INTERVAL
+NET_IPV6_ROUTE_GC_TIMEOUT
+NET_IPV6_ROUTE_GC_INTERVAL
+NET_IPV6_ROUTE_GC_ELASTICITY
+NET_IPV6_ROUTE_MTU_EXPIRES
+NET_IPV6_ROUTE_MIN_ADVMSS
+#conditional
+NET_IPV6_ROUTE_GC_MIN_INTERVAL_MS
diff --git a/strace/xlat/sysctl_net_unix.h b/strace/xlat/sysctl_net_unix.h
new file mode 100644
index 0000000..c940dab
--- /dev/null
+++ b/strace/xlat/sysctl_net_unix.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_net_unix.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_net_unix in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_net_unix[] = {
+ XLAT(NET_UNIX_DESTROY_DELAY),
+ XLAT(NET_UNIX_DELETE_DELAY),
+ XLAT(NET_UNIX_MAX_DGRAM_QLEN),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_net_unix.in b/strace/xlat/sysctl_net_unix.in
new file mode 100644
index 0000000..7440a92
--- /dev/null
+++ b/strace/xlat/sysctl_net_unix.in
@@ -0,0 +1,4 @@
+#unconditional
+NET_UNIX_DESTROY_DELAY
+NET_UNIX_DELETE_DELAY
+NET_UNIX_MAX_DGRAM_QLEN
diff --git a/strace/xlat/sysctl_root.h b/strace/xlat/sysctl_root.h
new file mode 100644
index 0000000..0d4b039
--- /dev/null
+++ b/strace/xlat/sysctl_root.h
@@ -0,0 +1,41 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_root.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_root in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_root[] = {
+ XLAT(CTL_KERN),
+ XLAT(CTL_VM),
+ XLAT(CTL_NET),
+ XLAT(CTL_FS),
+ XLAT(CTL_DEBUG),
+ XLAT(CTL_DEV),
+ XLAT(CTL_BUS),
+ XLAT(CTL_ABI),
+ XLAT(CTL_CPU),
+#if defined(CTL_PROC) || (defined(HAVE_DECL_CTL_PROC) && HAVE_DECL_CTL_PROC)
+  XLAT(CTL_PROC),
+#endif
+#if defined(CTL_ARLAN) || (defined(HAVE_DECL_CTL_ARLAN) && HAVE_DECL_CTL_ARLAN)
+  XLAT(CTL_ARLAN),
+#endif
+#if defined(CTL_S390DBF) || (defined(HAVE_DECL_CTL_S390DBF) && HAVE_DECL_CTL_S390DBF)
+  XLAT(CTL_S390DBF),
+#endif
+#if defined(CTL_SUNRPC) || (defined(HAVE_DECL_CTL_SUNRPC) && HAVE_DECL_CTL_SUNRPC)
+  XLAT(CTL_SUNRPC),
+#endif
+#if defined(CTL_PM) || (defined(HAVE_DECL_CTL_PM) && HAVE_DECL_CTL_PM)
+  XLAT(CTL_PM),
+#endif
+#if defined(CTL_FRV) || (defined(HAVE_DECL_CTL_FRV) && HAVE_DECL_CTL_FRV)
+  XLAT(CTL_FRV),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_root.in b/strace/xlat/sysctl_root.in
new file mode 100644
index 0000000..670670c
--- /dev/null
+++ b/strace/xlat/sysctl_root.in
@@ -0,0 +1,17 @@
+#unconditional
+CTL_KERN
+CTL_VM
+CTL_NET
+CTL_FS
+CTL_DEBUG
+CTL_DEV
+CTL_BUS
+CTL_ABI
+CTL_CPU
+#conditional
+CTL_PROC
+CTL_ARLAN
+CTL_S390DBF
+CTL_SUNRPC
+CTL_PM
+CTL_FRV
diff --git a/strace/xlat/sysctl_vm.h b/strace/xlat/sysctl_vm.h
new file mode 100644
index 0000000..36896a2
--- /dev/null
+++ b/strace/xlat/sysctl_vm.h
@@ -0,0 +1,48 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysctl_vm.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysctl_vm in mpers mode
+
+#else
+
+static
+const struct xlat sysctl_vm[] = {
+ XLAT(VM_OVERCOMMIT_MEMORY),
+ XLAT(VM_PAGE_CLUSTER),
+ XLAT(VM_DIRTY_BACKGROUND),
+ XLAT(VM_DIRTY_RATIO),
+ XLAT(VM_DIRTY_WB_CS),
+ XLAT(VM_DIRTY_EXPIRE_CS),
+ XLAT(VM_NR_PDFLUSH_THREADS),
+ XLAT(VM_OVERCOMMIT_RATIO),
+ XLAT(VM_PAGEBUF),
+ XLAT(VM_HUGETLB_PAGES),
+ XLAT(VM_SWAPPINESS),
+ XLAT(VM_LOWMEM_RESERVE_RATIO),
+ XLAT(VM_MIN_FREE_KBYTES),
+#if defined(VM_MAX_MAP_COUNT) || (defined(HAVE_DECL_VM_MAX_MAP_COUNT) && HAVE_DECL_VM_MAX_MAP_COUNT)
+  XLAT(VM_MAX_MAP_COUNT),
+#endif
+#if defined(VM_LAPTOP_MODE) || (defined(HAVE_DECL_VM_LAPTOP_MODE) && HAVE_DECL_VM_LAPTOP_MODE)
+  XLAT(VM_LAPTOP_MODE),
+#endif
+#if defined(VM_BLOCK_DUMP) || (defined(HAVE_DECL_VM_BLOCK_DUMP) && HAVE_DECL_VM_BLOCK_DUMP)
+  XLAT(VM_BLOCK_DUMP),
+#endif
+#if defined(VM_HUGETLB_GROUP) || (defined(HAVE_DECL_VM_HUGETLB_GROUP) && HAVE_DECL_VM_HUGETLB_GROUP)
+  XLAT(VM_HUGETLB_GROUP),
+#endif
+#if defined(VM_VFS_CACHE_PRESSURE) || (defined(HAVE_DECL_VM_VFS_CACHE_PRESSURE) && HAVE_DECL_VM_VFS_CACHE_PRESSURE)
+  XLAT(VM_VFS_CACHE_PRESSURE),
+#endif
+#if defined(VM_LEGACY_VA_LAYOUT) || (defined(HAVE_DECL_VM_LEGACY_VA_LAYOUT) && HAVE_DECL_VM_LEGACY_VA_LAYOUT)
+  XLAT(VM_LEGACY_VA_LAYOUT),
+#endif
+#if defined(VM_SWAP_TOKEN_TIMEOUT) || (defined(HAVE_DECL_VM_SWAP_TOKEN_TIMEOUT) && HAVE_DECL_VM_SWAP_TOKEN_TIMEOUT)
+  XLAT(VM_SWAP_TOKEN_TIMEOUT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysctl_vm.in b/strace/xlat/sysctl_vm.in
new file mode 100644
index 0000000..3c2b473
--- /dev/null
+++ b/strace/xlat/sysctl_vm.in
@@ -0,0 +1,22 @@
+#unconditional
+VM_OVERCOMMIT_MEMORY
+VM_PAGE_CLUSTER
+VM_DIRTY_BACKGROUND
+VM_DIRTY_RATIO
+VM_DIRTY_WB_CS
+VM_DIRTY_EXPIRE_CS
+VM_NR_PDFLUSH_THREADS
+VM_OVERCOMMIT_RATIO
+VM_PAGEBUF
+VM_HUGETLB_PAGES
+VM_SWAPPINESS
+VM_LOWMEM_RESERVE_RATIO
+VM_MIN_FREE_KBYTES
+#conditional
+VM_MAX_MAP_COUNT
+VM_LAPTOP_MODE
+VM_BLOCK_DUMP
+VM_HUGETLB_GROUP
+VM_VFS_CACHE_PRESSURE
+VM_LEGACY_VA_LAYOUT
+VM_SWAP_TOKEN_TIMEOUT
diff --git a/strace/xlat/syslog_action_type.h b/strace/xlat/syslog_action_type.h
new file mode 100644
index 0000000..b4f543f
--- /dev/null
+++ b/strace/xlat/syslog_action_type.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/syslog_action_type.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat syslog_action_type in mpers mode
+
+#else
+
+static
+const struct xlat syslog_action_type[] = {
+ XLAT(SYSLOG_ACTION_CLOSE),
+ XLAT(SYSLOG_ACTION_OPEN),
+ XLAT(SYSLOG_ACTION_READ),
+ XLAT(SYSLOG_ACTION_READ_ALL),
+ XLAT(SYSLOG_ACTION_READ_CLEAR),
+ XLAT(SYSLOG_ACTION_CLEAR),
+ XLAT(SYSLOG_ACTION_CONSOLE_OFF),
+ XLAT(SYSLOG_ACTION_CONSOLE_ON),
+ XLAT(SYSLOG_ACTION_CONSOLE_LEVEL),
+ XLAT(SYSLOG_ACTION_SIZE_UNREAD),
+ XLAT(SYSLOG_ACTION_SIZE_BUFFER),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/syslog_action_type.in b/strace/xlat/syslog_action_type.in
new file mode 100644
index 0000000..6e0109a
--- /dev/null
+++ b/strace/xlat/syslog_action_type.in
@@ -0,0 +1,12 @@
+#unconditional
+SYSLOG_ACTION_CLOSE
+SYSLOG_ACTION_OPEN
+SYSLOG_ACTION_READ
+SYSLOG_ACTION_READ_ALL
+SYSLOG_ACTION_READ_CLEAR
+SYSLOG_ACTION_CLEAR
+SYSLOG_ACTION_CONSOLE_OFF
+SYSLOG_ACTION_CONSOLE_ON
+SYSLOG_ACTION_CONSOLE_LEVEL
+SYSLOG_ACTION_SIZE_UNREAD
+SYSLOG_ACTION_SIZE_BUFFER
diff --git a/strace/xlat/sysmips_operations.h b/strace/xlat/sysmips_operations.h
new file mode 100644
index 0000000..107caa2
--- /dev/null
+++ b/strace/xlat/sysmips_operations.h
@@ -0,0 +1,29 @@
+/* Generated by ./xlat/gen.sh from ./xlat/sysmips_operations.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat sysmips_operations in mpers mode
+
+#else
+
+static
+const struct xlat sysmips_operations[] = {
+#if defined(SETNAME) || (defined(HAVE_DECL_SETNAME) && HAVE_DECL_SETNAME)
+  XLAT(SETNAME),
+#endif
+#if defined(FLUSH_CACHE) || (defined(HAVE_DECL_FLUSH_CACHE) && HAVE_DECL_FLUSH_CACHE)
+  XLAT(FLUSH_CACHE),
+#endif
+#if defined(MIPS_FIXADE) || (defined(HAVE_DECL_MIPS_FIXADE) && HAVE_DECL_MIPS_FIXADE)
+  XLAT(MIPS_FIXADE),
+#endif
+#if defined(MIPS_RDNVRAM) || (defined(HAVE_DECL_MIPS_RDNVRAM) && HAVE_DECL_MIPS_RDNVRAM)
+  XLAT(MIPS_RDNVRAM),
+#endif
+#if defined(MIPS_ATOMIC_SET) || (defined(HAVE_DECL_MIPS_ATOMIC_SET) && HAVE_DECL_MIPS_ATOMIC_SET)
+  XLAT(MIPS_ATOMIC_SET),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/sysmips_operations.in b/strace/xlat/sysmips_operations.in
new file mode 100644
index 0000000..3d367cb
--- /dev/null
+++ b/strace/xlat/sysmips_operations.in
@@ -0,0 +1,5 @@
+SETNAME
+FLUSH_CACHE
+MIPS_FIXADE
+MIPS_RDNVRAM
+MIPS_ATOMIC_SET
diff --git a/strace/xlat/tcflsh_options.h b/strace/xlat/tcflsh_options.h
new file mode 100644
index 0000000..5d67bb7
--- /dev/null
+++ b/strace/xlat/tcflsh_options.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/tcflsh_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat tcflsh_options in mpers mode
+
+#else
+
+static
+const struct xlat tcflsh_options[] = {
+#if defined(TCIFLUSH) || (defined(HAVE_DECL_TCIFLUSH) && HAVE_DECL_TCIFLUSH)
+  XLAT(TCIFLUSH),
+#endif
+#if defined(TCOFLUSH) || (defined(HAVE_DECL_TCOFLUSH) && HAVE_DECL_TCOFLUSH)
+  XLAT(TCOFLUSH),
+#endif
+#if defined(TCIOFLUSH) || (defined(HAVE_DECL_TCIOFLUSH) && HAVE_DECL_TCIOFLUSH)
+  XLAT(TCIOFLUSH),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/tcflsh_options.in b/strace/xlat/tcflsh_options.in
new file mode 100644
index 0000000..470a5a4
--- /dev/null
+++ b/strace/xlat/tcflsh_options.in
@@ -0,0 +1,3 @@
+TCIFLUSH
+TCOFLUSH
+TCIOFLUSH
diff --git a/strace/xlat/tcxonc_options.h b/strace/xlat/tcxonc_options.h
new file mode 100644
index 0000000..83aae83
--- /dev/null
+++ b/strace/xlat/tcxonc_options.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/tcxonc_options.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat tcxonc_options in mpers mode
+
+#else
+
+static
+const struct xlat tcxonc_options[] = {
+#if defined(TCOOFF) || (defined(HAVE_DECL_TCOOFF) && HAVE_DECL_TCOOFF)
+  XLAT(TCOOFF),
+#endif
+#if defined(TCOON) || (defined(HAVE_DECL_TCOON) && HAVE_DECL_TCOON)
+  XLAT(TCOON),
+#endif
+#if defined(TCIOFF) || (defined(HAVE_DECL_TCIOFF) && HAVE_DECL_TCIOFF)
+  XLAT(TCIOFF),
+#endif
+#if defined(TCION) || (defined(HAVE_DECL_TCION) && HAVE_DECL_TCION)
+  XLAT(TCION),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/tcxonc_options.in b/strace/xlat/tcxonc_options.in
new file mode 100644
index 0000000..733aee9
--- /dev/null
+++ b/strace/xlat/tcxonc_options.in
@@ -0,0 +1,4 @@
+TCOOFF
+TCOON
+TCIOFF
+TCION
diff --git a/strace/xlat/timerfdflags.h b/strace/xlat/timerfdflags.h
new file mode 100644
index 0000000..2483df8
--- /dev/null
+++ b/strace/xlat/timerfdflags.h
@@ -0,0 +1,36 @@
+/* Generated by ./xlat/gen.sh from ./xlat/timerfdflags.in; do not edit. */
+#if !(defined(TFD_TIMER_ABSTIME) || (defined(HAVE_DECL_TFD_TIMER_ABSTIME) && HAVE_DECL_TFD_TIMER_ABSTIME))
+# define TFD_TIMER_ABSTIME (1 << 0)
+#endif
+#if !(defined(TFD_TIMER_CANCEL_ON_SET) || (defined(HAVE_DECL_TFD_TIMER_CANCEL_ON_SET) && HAVE_DECL_TFD_TIMER_CANCEL_ON_SET))
+# define TFD_TIMER_CANCEL_ON_SET (1 << 1)
+#endif
+#if defined TFD_CLOEXEC || defined O_CLOEXEC
+#if !(defined(TFD_CLOEXEC) || (defined(HAVE_DECL_TFD_CLOEXEC) && HAVE_DECL_TFD_CLOEXEC))
+# define TFD_CLOEXEC O_CLOEXEC
+#endif
+#endif
+#if !(defined(TFD_NONBLOCK) || (defined(HAVE_DECL_TFD_NONBLOCK) && HAVE_DECL_TFD_NONBLOCK))
+# define TFD_NONBLOCK O_NONBLOCK
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat timerfdflags in mpers mode
+
+#else
+
+static
+const struct xlat timerfdflags[] = {
+/* The Linux userspace headers didn't export these for a long time. */
+
+ XLAT(TFD_TIMER_ABSTIME),
+ XLAT(TFD_TIMER_CANCEL_ON_SET),
+#if defined TFD_CLOEXEC || defined O_CLOEXEC
+ XLAT(TFD_CLOEXEC),
+#endif
+ XLAT(TFD_NONBLOCK),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/timerfdflags.in b/strace/xlat/timerfdflags.in
new file mode 100644
index 0000000..bf767e3
--- /dev/null
+++ b/strace/xlat/timerfdflags.in
@@ -0,0 +1,8 @@
+/* The Linux userspace headers didn't export these for a long time. */
+
+TFD_TIMER_ABSTIME (1 << 0)
+TFD_TIMER_CANCEL_ON_SET (1 << 1)
+#if defined TFD_CLOEXEC || defined O_CLOEXEC
+TFD_CLOEXEC O_CLOEXEC
+#endif
+TFD_NONBLOCK O_NONBLOCK
diff --git a/strace/xlat/ubi_volume_props.h b/strace/xlat/ubi_volume_props.h
new file mode 100644
index 0000000..cfae600
--- /dev/null
+++ b/strace/xlat/ubi_volume_props.h
@@ -0,0 +1,15 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ubi_volume_props.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ubi_volume_props in mpers mode
+
+#else
+
+static
+const struct xlat ubi_volume_props[] = {
+ XLAT(UBI_VOL_PROP_DIRECT_WRITE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ubi_volume_props.in b/strace/xlat/ubi_volume_props.in
new file mode 100644
index 0000000..78f2880
--- /dev/null
+++ b/strace/xlat/ubi_volume_props.in
@@ -0,0 +1,2 @@
+#unconditional
+UBI_VOL_PROP_DIRECT_WRITE
diff --git a/strace/xlat/ubi_volume_types.h b/strace/xlat/ubi_volume_types.h
new file mode 100644
index 0000000..0facbf2
--- /dev/null
+++ b/strace/xlat/ubi_volume_types.h
@@ -0,0 +1,16 @@
+/* Generated by ./xlat/gen.sh from ./xlat/ubi_volume_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat ubi_volume_types in mpers mode
+
+#else
+
+static
+const struct xlat ubi_volume_types[] = {
+ XLAT(UBI_DYNAMIC_VOLUME),
+ XLAT(UBI_STATIC_VOLUME),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/ubi_volume_types.in b/strace/xlat/ubi_volume_types.in
new file mode 100644
index 0000000..b4de52e
--- /dev/null
+++ b/strace/xlat/ubi_volume_types.in
@@ -0,0 +1,3 @@
+#unconditional
+UBI_DYNAMIC_VOLUME
+UBI_STATIC_VOLUME
diff --git a/strace/xlat/uffd_api_flags.h b/strace/xlat/uffd_api_flags.h
new file mode 100644
index 0000000..4963ec4
--- /dev/null
+++ b/strace/xlat/uffd_api_flags.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/uffd_api_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat uffd_api_flags in mpers mode
+
+#else
+
+static
+const struct xlat uffd_api_flags[] = {
+#if defined(_UFFDIO_REGISTER) || (defined(HAVE_DECL__UFFDIO_REGISTER) && HAVE_DECL__UFFDIO_REGISTER)
+  XLAT_TYPE_PAIR(uint64_t, 1ULL<<_UFFDIO_REGISTER, "1<<_UFFDIO_REGISTER"),
+#endif
+#if defined(_UFFDIO_UNREGISTER) || (defined(HAVE_DECL__UFFDIO_UNREGISTER) && HAVE_DECL__UFFDIO_UNREGISTER)
+  XLAT_TYPE_PAIR(uint64_t, 1ULL<<_UFFDIO_UNREGISTER, "1<<_UFFDIO_UNREGISTER"),
+#endif
+#if defined(_UFFDIO_API) || (defined(HAVE_DECL__UFFDIO_API) && HAVE_DECL__UFFDIO_API)
+  XLAT_TYPE_PAIR(uint64_t, 1ULL<<_UFFDIO_API, "1<<_UFFDIO_API"),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/uffd_api_flags.in b/strace/xlat/uffd_api_flags.in
new file mode 100644
index 0000000..fd21087
--- /dev/null
+++ b/strace/xlat/uffd_api_flags.in
@@ -0,0 +1,4 @@
+#val_type uint64_t
+1<<_UFFDIO_REGISTER
+1<<_UFFDIO_UNREGISTER
+1<<_UFFDIO_API
diff --git a/strace/xlat/uffd_copy_flags.h b/strace/xlat/uffd_copy_flags.h
new file mode 100644
index 0000000..669c1bb
--- /dev/null
+++ b/strace/xlat/uffd_copy_flags.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/uffd_copy_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat uffd_copy_flags in mpers mode
+
+#else
+
+static
+const struct xlat uffd_copy_flags[] = {
+#if defined(UFFDIO_COPY_MODE_DONTWAKE) || (defined(HAVE_DECL_UFFDIO_COPY_MODE_DONTWAKE) && HAVE_DECL_UFFDIO_COPY_MODE_DONTWAKE)
+  XLAT_TYPE(uint64_t, UFFDIO_COPY_MODE_DONTWAKE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/uffd_copy_flags.in b/strace/xlat/uffd_copy_flags.in
new file mode 100644
index 0000000..02d6b19
--- /dev/null
+++ b/strace/xlat/uffd_copy_flags.in
@@ -0,0 +1,2 @@
+#val_type uint64_t
+UFFDIO_COPY_MODE_DONTWAKE
diff --git a/strace/xlat/uffd_flags.h b/strace/xlat/uffd_flags.h
new file mode 100644
index 0000000..5fd260e
--- /dev/null
+++ b/strace/xlat/uffd_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/uffd_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat uffd_flags in mpers mode
+
+#else
+
+static
+const struct xlat uffd_flags[] = {
+#if defined(O_NONBLOCK) || (defined(HAVE_DECL_O_NONBLOCK) && HAVE_DECL_O_NONBLOCK)
+  XLAT(O_NONBLOCK),
+#endif
+#if defined(O_CLOEXEC) || (defined(HAVE_DECL_O_CLOEXEC) && HAVE_DECL_O_CLOEXEC)
+  XLAT(O_CLOEXEC),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/uffd_flags.in b/strace/xlat/uffd_flags.in
new file mode 100644
index 0000000..fb0338b
--- /dev/null
+++ b/strace/xlat/uffd_flags.in
@@ -0,0 +1,2 @@
+O_NONBLOCK
+O_CLOEXEC
diff --git a/strace/xlat/uffd_register_ioctl_flags.h b/strace/xlat/uffd_register_ioctl_flags.h
new file mode 100644
index 0000000..0c90f3c
--- /dev/null
+++ b/strace/xlat/uffd_register_ioctl_flags.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/uffd_register_ioctl_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat uffd_register_ioctl_flags in mpers mode
+
+#else
+
+static
+const struct xlat uffd_register_ioctl_flags[] = {
+#if defined(_UFFDIO_WAKE) || (defined(HAVE_DECL__UFFDIO_WAKE) && HAVE_DECL__UFFDIO_WAKE)
+  XLAT_TYPE_PAIR(uint64_t, 1ULL<<_UFFDIO_WAKE, "1<<_UFFDIO_WAKE"),
+#endif
+#if defined(_UFFDIO_COPY) || (defined(HAVE_DECL__UFFDIO_COPY) && HAVE_DECL__UFFDIO_COPY)
+  XLAT_TYPE_PAIR(uint64_t, 1ULL<<_UFFDIO_COPY, "1<<_UFFDIO_COPY"),
+#endif
+#if defined(_UFFDIO_ZEROPAGE) || (defined(HAVE_DECL__UFFDIO_ZEROPAGE) && HAVE_DECL__UFFDIO_ZEROPAGE)
+  XLAT_TYPE_PAIR(uint64_t, 1ULL<<_UFFDIO_ZEROPAGE, "1<<_UFFDIO_ZEROPAGE"),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/uffd_register_ioctl_flags.in b/strace/xlat/uffd_register_ioctl_flags.in
new file mode 100644
index 0000000..f4e3b94
--- /dev/null
+++ b/strace/xlat/uffd_register_ioctl_flags.in
@@ -0,0 +1,4 @@
+#val_type uint64_t
+1<<_UFFDIO_WAKE
+1<<_UFFDIO_COPY
+1<<_UFFDIO_ZEROPAGE
diff --git a/strace/xlat/uffd_register_mode_flags.h b/strace/xlat/uffd_register_mode_flags.h
new file mode 100644
index 0000000..bfcae87
--- /dev/null
+++ b/strace/xlat/uffd_register_mode_flags.h
@@ -0,0 +1,20 @@
+/* Generated by ./xlat/gen.sh from ./xlat/uffd_register_mode_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat uffd_register_mode_flags in mpers mode
+
+#else
+
+static
+const struct xlat uffd_register_mode_flags[] = {
+#if defined(UFFDIO_REGISTER_MODE_MISSING) || (defined(HAVE_DECL_UFFDIO_REGISTER_MODE_MISSING) && HAVE_DECL_UFFDIO_REGISTER_MODE_MISSING)
+  XLAT_TYPE(uint64_t, UFFDIO_REGISTER_MODE_MISSING),
+#endif
+#if defined(UFFDIO_REGISTER_MODE_WP) || (defined(HAVE_DECL_UFFDIO_REGISTER_MODE_WP) && HAVE_DECL_UFFDIO_REGISTER_MODE_WP)
+  XLAT_TYPE(uint64_t, UFFDIO_REGISTER_MODE_WP),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/uffd_register_mode_flags.in b/strace/xlat/uffd_register_mode_flags.in
new file mode 100644
index 0000000..996b1f3
--- /dev/null
+++ b/strace/xlat/uffd_register_mode_flags.in
@@ -0,0 +1,3 @@
+#val_type uint64_t
+UFFDIO_REGISTER_MODE_MISSING
+UFFDIO_REGISTER_MODE_WP
diff --git a/strace/xlat/uffd_zeropage_flags.h b/strace/xlat/uffd_zeropage_flags.h
new file mode 100644
index 0000000..8367ff6
--- /dev/null
+++ b/strace/xlat/uffd_zeropage_flags.h
@@ -0,0 +1,17 @@
+/* Generated by ./xlat/gen.sh from ./xlat/uffd_zeropage_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat uffd_zeropage_flags in mpers mode
+
+#else
+
+static
+const struct xlat uffd_zeropage_flags[] = {
+#if defined(UFFDIO_ZEROPAGE_MODE_DONTWAKE) || (defined(HAVE_DECL_UFFDIO_ZEROPAGE_MODE_DONTWAKE) && HAVE_DECL_UFFDIO_ZEROPAGE_MODE_DONTWAKE)
+  XLAT_TYPE(uint64_t, UFFDIO_ZEROPAGE_MODE_DONTWAKE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/uffd_zeropage_flags.in b/strace/xlat/uffd_zeropage_flags.in
new file mode 100644
index 0000000..6d48a04
--- /dev/null
+++ b/strace/xlat/uffd_zeropage_flags.in
@@ -0,0 +1,2 @@
+#val_type uint64_t
+UFFDIO_ZEROPAGE_MODE_DONTWAKE
diff --git a/strace/xlat/umount_flags.h b/strace/xlat/umount_flags.h
new file mode 100644
index 0000000..3219782
--- /dev/null
+++ b/strace/xlat/umount_flags.h
@@ -0,0 +1,30 @@
+/* Generated by ./xlat/gen.sh from ./xlat/umount_flags.in; do not edit. */
+#if !(defined(MNT_FORCE) || (defined(HAVE_DECL_MNT_FORCE) && HAVE_DECL_MNT_FORCE))
+# define MNT_FORCE 1
+#endif
+#if !(defined(MNT_DETACH) || (defined(HAVE_DECL_MNT_DETACH) && HAVE_DECL_MNT_DETACH))
+# define MNT_DETACH 2
+#endif
+#if !(defined(MNT_EXPIRE) || (defined(HAVE_DECL_MNT_EXPIRE) && HAVE_DECL_MNT_EXPIRE))
+# define MNT_EXPIRE 4
+#endif
+#if !(defined(UMOUNT_NOFOLLOW) || (defined(HAVE_DECL_UMOUNT_NOFOLLOW) && HAVE_DECL_UMOUNT_NOFOLLOW))
+# define UMOUNT_NOFOLLOW 8
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat umount_flags in mpers mode
+
+#else
+
+static
+const struct xlat umount_flags[] = {
+ XLAT(MNT_FORCE),
+ XLAT(MNT_DETACH),
+ XLAT(MNT_EXPIRE),
+ XLAT(UMOUNT_NOFOLLOW),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/umount_flags.in b/strace/xlat/umount_flags.in
new file mode 100644
index 0000000..2edabcd
--- /dev/null
+++ b/strace/xlat/umount_flags.in
@@ -0,0 +1,4 @@
+MNT_FORCE	1
+MNT_DETACH	2
+MNT_EXPIRE	4
+UMOUNT_NOFOLLOW	8
diff --git a/strace/xlat/usagewho.h b/strace/xlat/usagewho.h
new file mode 100644
index 0000000..810f04c
--- /dev/null
+++ b/strace/xlat/usagewho.h
@@ -0,0 +1,23 @@
+/* Generated by ./xlat/gen.sh from ./xlat/usagewho.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat usagewho in mpers mode
+
+#else
+
+static
+const struct xlat usagewho[] = {
+#if defined(RUSAGE_SELF) || (defined(HAVE_DECL_RUSAGE_SELF) && HAVE_DECL_RUSAGE_SELF)
+  XLAT(RUSAGE_SELF),
+#endif
+#if defined(RUSAGE_CHILDREN) || (defined(HAVE_DECL_RUSAGE_CHILDREN) && HAVE_DECL_RUSAGE_CHILDREN)
+  XLAT(RUSAGE_CHILDREN),
+#endif
+#if defined(RUSAGE_BOTH) || (defined(HAVE_DECL_RUSAGE_BOTH) && HAVE_DECL_RUSAGE_BOTH)
+  XLAT(RUSAGE_BOTH),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/usagewho.in b/strace/xlat/usagewho.in
new file mode 100644
index 0000000..e2153b3
--- /dev/null
+++ b/strace/xlat/usagewho.in
@@ -0,0 +1,3 @@
+RUSAGE_SELF
+RUSAGE_CHILDREN
+RUSAGE_BOTH
diff --git a/strace/xlat/v4l2_buf_flags.h b/strace/xlat/v4l2_buf_flags.h
new file mode 100644
index 0000000..63f0b47
--- /dev/null
+++ b/strace/xlat/v4l2_buf_flags.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_buf_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_buf_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_buf_flags[] = {
+#if defined(V4L2_BUF_FLAG_MAPPED) || (defined(HAVE_DECL_V4L2_BUF_FLAG_MAPPED) && HAVE_DECL_V4L2_BUF_FLAG_MAPPED)
+  XLAT(V4L2_BUF_FLAG_MAPPED),
+#endif
+#if defined(V4L2_BUF_FLAG_QUEUED) || (defined(HAVE_DECL_V4L2_BUF_FLAG_QUEUED) && HAVE_DECL_V4L2_BUF_FLAG_QUEUED)
+  XLAT(V4L2_BUF_FLAG_QUEUED),
+#endif
+#if defined(V4L2_BUF_FLAG_DONE) || (defined(HAVE_DECL_V4L2_BUF_FLAG_DONE) && HAVE_DECL_V4L2_BUF_FLAG_DONE)
+  XLAT(V4L2_BUF_FLAG_DONE),
+#endif
+#if defined(V4L2_BUF_FLAG_KEYFRAME) || (defined(HAVE_DECL_V4L2_BUF_FLAG_KEYFRAME) && HAVE_DECL_V4L2_BUF_FLAG_KEYFRAME)
+  XLAT(V4L2_BUF_FLAG_KEYFRAME),
+#endif
+#if defined(V4L2_BUF_FLAG_PFRAME) || (defined(HAVE_DECL_V4L2_BUF_FLAG_PFRAME) && HAVE_DECL_V4L2_BUF_FLAG_PFRAME)
+  XLAT(V4L2_BUF_FLAG_PFRAME),
+#endif
+#if defined(V4L2_BUF_FLAG_BFRAME) || (defined(HAVE_DECL_V4L2_BUF_FLAG_BFRAME) && HAVE_DECL_V4L2_BUF_FLAG_BFRAME)
+  XLAT(V4L2_BUF_FLAG_BFRAME),
+#endif
+#if defined(V4L2_BUF_FLAG_TIMECODE) || (defined(HAVE_DECL_V4L2_BUF_FLAG_TIMECODE) && HAVE_DECL_V4L2_BUF_FLAG_TIMECODE)
+  XLAT(V4L2_BUF_FLAG_TIMECODE),
+#endif
+#if defined(V4L2_BUF_FLAG_INPUT) || (defined(HAVE_DECL_V4L2_BUF_FLAG_INPUT) && HAVE_DECL_V4L2_BUF_FLAG_INPUT)
+  XLAT(V4L2_BUF_FLAG_INPUT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_buf_flags.in b/strace/xlat/v4l2_buf_flags.in
new file mode 100644
index 0000000..ba7e86e
--- /dev/null
+++ b/strace/xlat/v4l2_buf_flags.in
@@ -0,0 +1,8 @@
+V4L2_BUF_FLAG_MAPPED
+V4L2_BUF_FLAG_QUEUED
+V4L2_BUF_FLAG_DONE
+V4L2_BUF_FLAG_KEYFRAME
+V4L2_BUF_FLAG_PFRAME
+V4L2_BUF_FLAG_BFRAME
+V4L2_BUF_FLAG_TIMECODE
+V4L2_BUF_FLAG_INPUT
diff --git a/strace/xlat/v4l2_buf_types.h b/strace/xlat/v4l2_buf_types.h
new file mode 100644
index 0000000..c5966a9
--- /dev/null
+++ b/strace/xlat/v4l2_buf_types.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_buf_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_buf_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_buf_types[] = {
+#if defined(V4L2_BUF_TYPE_VIDEO_CAPTURE) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VIDEO_CAPTURE) && HAVE_DECL_V4L2_BUF_TYPE_VIDEO_CAPTURE)
+  XLAT(V4L2_BUF_TYPE_VIDEO_CAPTURE),
+#endif
+#if defined(V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE) && HAVE_DECL_V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE)
+  XLAT(V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE),
+#endif
+#if defined(V4L2_BUF_TYPE_VIDEO_OUTPUT) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT) && HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT)
+  XLAT(V4L2_BUF_TYPE_VIDEO_OUTPUT),
+#endif
+#if defined(V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE) && HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE)
+  XLAT(V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE),
+#endif
+#if defined(V4L2_BUF_TYPE_VIDEO_OVERLAY) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OVERLAY) && HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OVERLAY)
+  XLAT(V4L2_BUF_TYPE_VIDEO_OVERLAY),
+#endif
+#if defined(V4L2_BUF_TYPE_VBI_CAPTURE) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VBI_CAPTURE) && HAVE_DECL_V4L2_BUF_TYPE_VBI_CAPTURE)
+  XLAT(V4L2_BUF_TYPE_VBI_CAPTURE),
+#endif
+#if defined(V4L2_BUF_TYPE_VBI_OUTPUT) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VBI_OUTPUT) && HAVE_DECL_V4L2_BUF_TYPE_VBI_OUTPUT)
+  XLAT(V4L2_BUF_TYPE_VBI_OUTPUT),
+#endif
+#if defined(V4L2_BUF_TYPE_SLICED_VBI_CAPTURE) || (defined(HAVE_DECL_V4L2_BUF_TYPE_SLICED_VBI_CAPTURE) && HAVE_DECL_V4L2_BUF_TYPE_SLICED_VBI_CAPTURE)
+  XLAT(V4L2_BUF_TYPE_SLICED_VBI_CAPTURE),
+#endif
+#if defined(V4L2_BUF_TYPE_SLICED_VBI_OUTPUT) || (defined(HAVE_DECL_V4L2_BUF_TYPE_SLICED_VBI_OUTPUT) && HAVE_DECL_V4L2_BUF_TYPE_SLICED_VBI_OUTPUT)
+  XLAT(V4L2_BUF_TYPE_SLICED_VBI_OUTPUT),
+#endif
+#if defined(V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY) || (defined(HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY) && HAVE_DECL_V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY)
+  XLAT(V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_buf_types.in b/strace/xlat/v4l2_buf_types.in
new file mode 100644
index 0000000..431cb59
--- /dev/null
+++ b/strace/xlat/v4l2_buf_types.in
@@ -0,0 +1,10 @@
+V4L2_BUF_TYPE_VIDEO_CAPTURE
+V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE
+V4L2_BUF_TYPE_VIDEO_OUTPUT
+V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE
+V4L2_BUF_TYPE_VIDEO_OVERLAY
+V4L2_BUF_TYPE_VBI_CAPTURE
+V4L2_BUF_TYPE_VBI_OUTPUT
+V4L2_BUF_TYPE_SLICED_VBI_CAPTURE
+V4L2_BUF_TYPE_SLICED_VBI_OUTPUT
+V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY
diff --git a/strace/xlat/v4l2_capture_modes.h b/strace/xlat/v4l2_capture_modes.h
new file mode 100644
index 0000000..ea21949
--- /dev/null
+++ b/strace/xlat/v4l2_capture_modes.h
@@ -0,0 +1,19 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_capture_modes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_capture_modes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_capture_modes[] = {
+#if defined(V4L2_MODE_HIGHQUALITY) || (defined(HAVE_DECL_V4L2_MODE_HIGHQUALITY) && HAVE_DECL_V4L2_MODE_HIGHQUALITY)
+  XLAT(V4L2_MODE_HIGHQUALITY),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_capture_modes.in b/strace/xlat/v4l2_capture_modes.in
new file mode 100644
index 0000000..4730764
--- /dev/null
+++ b/strace/xlat/v4l2_capture_modes.in
@@ -0,0 +1 @@
+V4L2_MODE_HIGHQUALITY
diff --git a/strace/xlat/v4l2_colorspaces.h b/strace/xlat/v4l2_colorspaces.h
new file mode 100644
index 0000000..857baf9
--- /dev/null
+++ b/strace/xlat/v4l2_colorspaces.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_colorspaces.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_colorspaces[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_colorspaces[] = {
+#if defined(V4L2_COLORSPACE_SMPTE170M) || (defined(HAVE_DECL_V4L2_COLORSPACE_SMPTE170M) && HAVE_DECL_V4L2_COLORSPACE_SMPTE170M)
+  XLAT(V4L2_COLORSPACE_SMPTE170M),
+#endif
+#if defined(V4L2_COLORSPACE_SMPTE240M) || (defined(HAVE_DECL_V4L2_COLORSPACE_SMPTE240M) && HAVE_DECL_V4L2_COLORSPACE_SMPTE240M)
+  XLAT(V4L2_COLORSPACE_SMPTE240M),
+#endif
+#if defined(V4L2_COLORSPACE_REC709) || (defined(HAVE_DECL_V4L2_COLORSPACE_REC709) && HAVE_DECL_V4L2_COLORSPACE_REC709)
+  XLAT(V4L2_COLORSPACE_REC709),
+#endif
+#if defined(V4L2_COLORSPACE_BT878) || (defined(HAVE_DECL_V4L2_COLORSPACE_BT878) && HAVE_DECL_V4L2_COLORSPACE_BT878)
+  XLAT(V4L2_COLORSPACE_BT878),
+#endif
+#if defined(V4L2_COLORSPACE_470_SYSTEM_M) || (defined(HAVE_DECL_V4L2_COLORSPACE_470_SYSTEM_M) && HAVE_DECL_V4L2_COLORSPACE_470_SYSTEM_M)
+  XLAT(V4L2_COLORSPACE_470_SYSTEM_M),
+#endif
+#if defined(V4L2_COLORSPACE_470_SYSTEM_BG) || (defined(HAVE_DECL_V4L2_COLORSPACE_470_SYSTEM_BG) && HAVE_DECL_V4L2_COLORSPACE_470_SYSTEM_BG)
+  XLAT(V4L2_COLORSPACE_470_SYSTEM_BG),
+#endif
+#if defined(V4L2_COLORSPACE_JPEG) || (defined(HAVE_DECL_V4L2_COLORSPACE_JPEG) && HAVE_DECL_V4L2_COLORSPACE_JPEG)
+  XLAT(V4L2_COLORSPACE_JPEG),
+#endif
+#if defined(V4L2_COLORSPACE_SRGB) || (defined(HAVE_DECL_V4L2_COLORSPACE_SRGB) && HAVE_DECL_V4L2_COLORSPACE_SRGB)
+  XLAT(V4L2_COLORSPACE_SRGB),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_colorspaces.in b/strace/xlat/v4l2_colorspaces.in
new file mode 100644
index 0000000..961e71c
--- /dev/null
+++ b/strace/xlat/v4l2_colorspaces.in
@@ -0,0 +1,8 @@
+V4L2_COLORSPACE_SMPTE170M
+V4L2_COLORSPACE_SMPTE240M
+V4L2_COLORSPACE_REC709
+V4L2_COLORSPACE_BT878
+V4L2_COLORSPACE_470_SYSTEM_M
+V4L2_COLORSPACE_470_SYSTEM_BG
+V4L2_COLORSPACE_JPEG
+V4L2_COLORSPACE_SRGB
diff --git a/strace/xlat/v4l2_control_classes.h b/strace/xlat/v4l2_control_classes.h
new file mode 100644
index 0000000..9ceb9c4
--- /dev/null
+++ b/strace/xlat/v4l2_control_classes.h
@@ -0,0 +1,43 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_control_classes.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_control_classes[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_control_classes[] = {
+#if defined(V4L2_CTRL_CLASS_USER) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_USER) && HAVE_DECL_V4L2_CTRL_CLASS_USER)
+  XLAT(V4L2_CTRL_CLASS_USER),
+#endif
+#if defined(V4L2_CTRL_CLASS_MPEG) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_MPEG) && HAVE_DECL_V4L2_CTRL_CLASS_MPEG)
+  XLAT(V4L2_CTRL_CLASS_MPEG),
+#endif
+#if defined(V4L2_CTRL_CLASS_CAMERA) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_CAMERA) && HAVE_DECL_V4L2_CTRL_CLASS_CAMERA)
+  XLAT(V4L2_CTRL_CLASS_CAMERA),
+#endif
+#if defined(V4L2_CTRL_CLASS_FM_TX) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_FM_TX) && HAVE_DECL_V4L2_CTRL_CLASS_FM_TX)
+  XLAT(V4L2_CTRL_CLASS_FM_TX),
+#endif
+#if defined(V4L2_CTRL_CLASS_FLASH) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_FLASH) && HAVE_DECL_V4L2_CTRL_CLASS_FLASH)
+  XLAT(V4L2_CTRL_CLASS_FLASH),
+#endif
+#if defined(V4L2_CTRL_CLASS_JPEG) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_JPEG) && HAVE_DECL_V4L2_CTRL_CLASS_JPEG)
+  XLAT(V4L2_CTRL_CLASS_JPEG),
+#endif
+#if defined(V4L2_CTRL_CLASS_IMAGE_SOURCE) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_IMAGE_SOURCE) && HAVE_DECL_V4L2_CTRL_CLASS_IMAGE_SOURCE)
+  XLAT(V4L2_CTRL_CLASS_IMAGE_SOURCE),
+#endif
+#if defined(V4L2_CTRL_CLASS_IMAGE_PROC) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_IMAGE_PROC) && HAVE_DECL_V4L2_CTRL_CLASS_IMAGE_PROC)
+  XLAT(V4L2_CTRL_CLASS_IMAGE_PROC),
+#endif
+#if defined(V4L2_CTRL_CLASS_FM_RX) || (defined(HAVE_DECL_V4L2_CTRL_CLASS_FM_RX) && HAVE_DECL_V4L2_CTRL_CLASS_FM_RX)
+  XLAT(V4L2_CTRL_CLASS_FM_RX),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_control_classes.in b/strace/xlat/v4l2_control_classes.in
new file mode 100644
index 0000000..5666a06
--- /dev/null
+++ b/strace/xlat/v4l2_control_classes.in
@@ -0,0 +1,9 @@
+V4L2_CTRL_CLASS_USER
+V4L2_CTRL_CLASS_MPEG
+V4L2_CTRL_CLASS_CAMERA
+V4L2_CTRL_CLASS_FM_TX
+V4L2_CTRL_CLASS_FLASH
+V4L2_CTRL_CLASS_JPEG
+V4L2_CTRL_CLASS_IMAGE_SOURCE
+V4L2_CTRL_CLASS_IMAGE_PROC
+V4L2_CTRL_CLASS_FM_RX
diff --git a/strace/xlat/v4l2_control_flags.h b/strace/xlat/v4l2_control_flags.h
new file mode 100644
index 0000000..a4c8a53
--- /dev/null
+++ b/strace/xlat/v4l2_control_flags.h
@@ -0,0 +1,40 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_control_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_control_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_control_flags[] = {
+#if defined(V4L2_CTRL_FLAG_DISABLED) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_DISABLED) && HAVE_DECL_V4L2_CTRL_FLAG_DISABLED)
+  XLAT(V4L2_CTRL_FLAG_DISABLED),
+#endif
+#if defined(V4L2_CTRL_FLAG_GRABBED) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_GRABBED) && HAVE_DECL_V4L2_CTRL_FLAG_GRABBED)
+  XLAT(V4L2_CTRL_FLAG_GRABBED),
+#endif
+#if defined(V4L2_CTRL_FLAG_READ_ONLY) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_READ_ONLY) && HAVE_DECL_V4L2_CTRL_FLAG_READ_ONLY)
+  XLAT(V4L2_CTRL_FLAG_READ_ONLY),
+#endif
+#if defined(V4L2_CTRL_FLAG_UPDATE) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_UPDATE) && HAVE_DECL_V4L2_CTRL_FLAG_UPDATE)
+  XLAT(V4L2_CTRL_FLAG_UPDATE),
+#endif
+#if defined(V4L2_CTRL_FLAG_INACTIVE) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_INACTIVE) && HAVE_DECL_V4L2_CTRL_FLAG_INACTIVE)
+  XLAT(V4L2_CTRL_FLAG_INACTIVE),
+#endif
+#if defined(V4L2_CTRL_FLAG_SLIDER) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_SLIDER) && HAVE_DECL_V4L2_CTRL_FLAG_SLIDER)
+  XLAT(V4L2_CTRL_FLAG_SLIDER),
+#endif
+#if defined(V4L2_CTRL_FLAG_WRITE_ONLY) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_WRITE_ONLY) && HAVE_DECL_V4L2_CTRL_FLAG_WRITE_ONLY)
+  XLAT(V4L2_CTRL_FLAG_WRITE_ONLY),
+#endif
+#if defined(V4L2_CTRL_FLAG_VOLATILE) || (defined(HAVE_DECL_V4L2_CTRL_FLAG_VOLATILE) && HAVE_DECL_V4L2_CTRL_FLAG_VOLATILE)
+  XLAT(V4L2_CTRL_FLAG_VOLATILE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_control_flags.in b/strace/xlat/v4l2_control_flags.in
new file mode 100644
index 0000000..18654de
--- /dev/null
+++ b/strace/xlat/v4l2_control_flags.in
@@ -0,0 +1,8 @@
+V4L2_CTRL_FLAG_DISABLED
+V4L2_CTRL_FLAG_GRABBED
+V4L2_CTRL_FLAG_READ_ONLY
+V4L2_CTRL_FLAG_UPDATE
+V4L2_CTRL_FLAG_INACTIVE
+V4L2_CTRL_FLAG_SLIDER
+V4L2_CTRL_FLAG_WRITE_ONLY
+V4L2_CTRL_FLAG_VOLATILE
diff --git a/strace/xlat/v4l2_control_ids.h b/strace/xlat/v4l2_control_ids.h
new file mode 100644
index 0000000..2f740db
--- /dev/null
+++ b/strace/xlat/v4l2_control_ids.h
@@ -0,0 +1,243 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_control_ids.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_control_ids[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_control_ids[] = {
+ XLAT(0),
+#if defined(V4L2_CID_BRIGHTNESS) || (defined(HAVE_DECL_V4L2_CID_BRIGHTNESS) && HAVE_DECL_V4L2_CID_BRIGHTNESS)
+  XLAT(V4L2_CID_BRIGHTNESS),
+#endif
+#if defined(V4L2_CID_CONTRAST) || (defined(HAVE_DECL_V4L2_CID_CONTRAST) && HAVE_DECL_V4L2_CID_CONTRAST)
+  XLAT(V4L2_CID_CONTRAST),
+#endif
+#if defined(V4L2_CID_SATURATION) || (defined(HAVE_DECL_V4L2_CID_SATURATION) && HAVE_DECL_V4L2_CID_SATURATION)
+  XLAT(V4L2_CID_SATURATION),
+#endif
+#if defined(V4L2_CID_HUE) || (defined(HAVE_DECL_V4L2_CID_HUE) && HAVE_DECL_V4L2_CID_HUE)
+  XLAT(V4L2_CID_HUE),
+#endif
+#if defined(V4L2_CID_AUDIO_VOLUME) || (defined(HAVE_DECL_V4L2_CID_AUDIO_VOLUME) && HAVE_DECL_V4L2_CID_AUDIO_VOLUME)
+  XLAT(V4L2_CID_AUDIO_VOLUME),
+#endif
+#if defined(V4L2_CID_AUDIO_BALANCE) || (defined(HAVE_DECL_V4L2_CID_AUDIO_BALANCE) && HAVE_DECL_V4L2_CID_AUDIO_BALANCE)
+  XLAT(V4L2_CID_AUDIO_BALANCE),
+#endif
+#if defined(V4L2_CID_AUDIO_BASS) || (defined(HAVE_DECL_V4L2_CID_AUDIO_BASS) && HAVE_DECL_V4L2_CID_AUDIO_BASS)
+  XLAT(V4L2_CID_AUDIO_BASS),
+#endif
+#if defined(V4L2_CID_AUDIO_TREBLE) || (defined(HAVE_DECL_V4L2_CID_AUDIO_TREBLE) && HAVE_DECL_V4L2_CID_AUDIO_TREBLE)
+  XLAT(V4L2_CID_AUDIO_TREBLE),
+#endif
+#if defined(V4L2_CID_AUDIO_MUTE) || (defined(HAVE_DECL_V4L2_CID_AUDIO_MUTE) && HAVE_DECL_V4L2_CID_AUDIO_MUTE)
+  XLAT(V4L2_CID_AUDIO_MUTE),
+#endif
+#if defined(V4L2_CID_AUDIO_LOUDNESS) || (defined(HAVE_DECL_V4L2_CID_AUDIO_LOUDNESS) && HAVE_DECL_V4L2_CID_AUDIO_LOUDNESS)
+  XLAT(V4L2_CID_AUDIO_LOUDNESS),
+#endif
+#if defined(V4L2_CID_BLACK_LEVEL) || (defined(HAVE_DECL_V4L2_CID_BLACK_LEVEL) && HAVE_DECL_V4L2_CID_BLACK_LEVEL)
+  XLAT(V4L2_CID_BLACK_LEVEL),
+#endif
+#if defined(V4L2_CID_AUTO_WHITE_BALANCE) || (defined(HAVE_DECL_V4L2_CID_AUTO_WHITE_BALANCE) && HAVE_DECL_V4L2_CID_AUTO_WHITE_BALANCE)
+  XLAT(V4L2_CID_AUTO_WHITE_BALANCE),
+#endif
+#if defined(V4L2_CID_DO_WHITE_BALANCE) || (defined(HAVE_DECL_V4L2_CID_DO_WHITE_BALANCE) && HAVE_DECL_V4L2_CID_DO_WHITE_BALANCE)
+  XLAT(V4L2_CID_DO_WHITE_BALANCE),
+#endif
+#if defined(V4L2_CID_RED_BALANCE) || (defined(HAVE_DECL_V4L2_CID_RED_BALANCE) && HAVE_DECL_V4L2_CID_RED_BALANCE)
+  XLAT(V4L2_CID_RED_BALANCE),
+#endif
+#if defined(V4L2_CID_BLUE_BALANCE) || (defined(HAVE_DECL_V4L2_CID_BLUE_BALANCE) && HAVE_DECL_V4L2_CID_BLUE_BALANCE)
+  XLAT(V4L2_CID_BLUE_BALANCE),
+#endif
+#if defined(V4L2_CID_GAMMA) || (defined(HAVE_DECL_V4L2_CID_GAMMA) && HAVE_DECL_V4L2_CID_GAMMA)
+  XLAT(V4L2_CID_GAMMA),
+#endif
+#if defined(V4L2_CID_WHITENESS) || (defined(HAVE_DECL_V4L2_CID_WHITENESS) && HAVE_DECL_V4L2_CID_WHITENESS)
+  XLAT(V4L2_CID_WHITENESS),
+#endif
+#if defined(V4L2_CID_EXPOSURE) || (defined(HAVE_DECL_V4L2_CID_EXPOSURE) && HAVE_DECL_V4L2_CID_EXPOSURE)
+  XLAT(V4L2_CID_EXPOSURE),
+#endif
+#if defined(V4L2_CID_AUTOGAIN) || (defined(HAVE_DECL_V4L2_CID_AUTOGAIN) && HAVE_DECL_V4L2_CID_AUTOGAIN)
+  XLAT(V4L2_CID_AUTOGAIN),
+#endif
+#if defined(V4L2_CID_GAIN) || (defined(HAVE_DECL_V4L2_CID_GAIN) && HAVE_DECL_V4L2_CID_GAIN)
+  XLAT(V4L2_CID_GAIN),
+#endif
+#if defined(V4L2_CID_HFLIP) || (defined(HAVE_DECL_V4L2_CID_HFLIP) && HAVE_DECL_V4L2_CID_HFLIP)
+  XLAT(V4L2_CID_HFLIP),
+#endif
+#if defined(V4L2_CID_VFLIP) || (defined(HAVE_DECL_V4L2_CID_VFLIP) && HAVE_DECL_V4L2_CID_VFLIP)
+  XLAT(V4L2_CID_VFLIP),
+#endif
+#if defined(V4L2_CID_HCENTER) || (defined(HAVE_DECL_V4L2_CID_HCENTER) && HAVE_DECL_V4L2_CID_HCENTER)
+  XLAT(V4L2_CID_HCENTER),
+#endif
+#if defined(V4L2_CID_VCENTER) || (defined(HAVE_DECL_V4L2_CID_VCENTER) && HAVE_DECL_V4L2_CID_VCENTER)
+  XLAT(V4L2_CID_VCENTER),
+#endif
+#if defined(V4L2_CID_POWER_LINE_FREQUENCY) || (defined(HAVE_DECL_V4L2_CID_POWER_LINE_FREQUENCY) && HAVE_DECL_V4L2_CID_POWER_LINE_FREQUENCY)
+  XLAT(V4L2_CID_POWER_LINE_FREQUENCY),
+#endif
+#if defined(V4L2_CID_HUE_AUTO) || (defined(HAVE_DECL_V4L2_CID_HUE_AUTO) && HAVE_DECL_V4L2_CID_HUE_AUTO)
+  XLAT(V4L2_CID_HUE_AUTO),
+#endif
+#if defined(V4L2_CID_WHITE_BALANCE_TEMPERATURE) || (defined(HAVE_DECL_V4L2_CID_WHITE_BALANCE_TEMPERATURE) && HAVE_DECL_V4L2_CID_WHITE_BALANCE_TEMPERATURE)
+  XLAT(V4L2_CID_WHITE_BALANCE_TEMPERATURE),
+#endif
+#if defined(V4L2_CID_SHARPNESS) || (defined(HAVE_DECL_V4L2_CID_SHARPNESS) && HAVE_DECL_V4L2_CID_SHARPNESS)
+  XLAT(V4L2_CID_SHARPNESS),
+#endif
+#if defined(V4L2_CID_BACKLIGHT_COMPENSATION) || (defined(HAVE_DECL_V4L2_CID_BACKLIGHT_COMPENSATION) && HAVE_DECL_V4L2_CID_BACKLIGHT_COMPENSATION)
+  XLAT(V4L2_CID_BACKLIGHT_COMPENSATION),
+#endif
+#if defined(V4L2_CID_CHROMA_AGC) || (defined(HAVE_DECL_V4L2_CID_CHROMA_AGC) && HAVE_DECL_V4L2_CID_CHROMA_AGC)
+  XLAT(V4L2_CID_CHROMA_AGC),
+#endif
+#if defined(V4L2_CID_CHROMA_GAIN) || (defined(HAVE_DECL_V4L2_CID_CHROMA_GAIN) && HAVE_DECL_V4L2_CID_CHROMA_GAIN)
+  XLAT(V4L2_CID_CHROMA_GAIN),
+#endif
+#if defined(V4L2_CID_COLOR_KILLER) || (defined(HAVE_DECL_V4L2_CID_COLOR_KILLER) && HAVE_DECL_V4L2_CID_COLOR_KILLER)
+  XLAT(V4L2_CID_COLOR_KILLER),
+#endif
+#if defined(V4L2_CID_COLORFX) || (defined(HAVE_DECL_V4L2_CID_COLORFX) && HAVE_DECL_V4L2_CID_COLORFX)
+  XLAT(V4L2_CID_COLORFX),
+#endif
+#if defined(V4L2_CID_COLORFX_CBCR) || (defined(HAVE_DECL_V4L2_CID_COLORFX_CBCR) && HAVE_DECL_V4L2_CID_COLORFX_CBCR)
+  XLAT(V4L2_CID_COLORFX_CBCR),
+#endif
+#if defined(V4L2_CID_AUTOBRIGHTNESS) || (defined(HAVE_DECL_V4L2_CID_AUTOBRIGHTNESS) && HAVE_DECL_V4L2_CID_AUTOBRIGHTNESS)
+  XLAT(V4L2_CID_AUTOBRIGHTNESS),
+#endif
+#if defined(V4L2_CID_BAND_STOP_FILTER) || (defined(HAVE_DECL_V4L2_CID_BAND_STOP_FILTER) && HAVE_DECL_V4L2_CID_BAND_STOP_FILTER)
+  XLAT(V4L2_CID_BAND_STOP_FILTER),
+#endif
+#if defined(V4L2_CID_ROTATE) || (defined(HAVE_DECL_V4L2_CID_ROTATE) && HAVE_DECL_V4L2_CID_ROTATE)
+  XLAT(V4L2_CID_ROTATE),
+#endif
+#if defined(V4L2_CID_BG_COLOR) || (defined(HAVE_DECL_V4L2_CID_BG_COLOR) && HAVE_DECL_V4L2_CID_BG_COLOR)
+  XLAT(V4L2_CID_BG_COLOR),
+#endif
+#if defined(V4L2_CID_ILLUMINATORS_1) || (defined(HAVE_DECL_V4L2_CID_ILLUMINATORS_1) && HAVE_DECL_V4L2_CID_ILLUMINATORS_1)
+  XLAT(V4L2_CID_ILLUMINATORS_1),
+#endif
+#if defined(V4L2_CID_ILLUMINATORS_2) || (defined(HAVE_DECL_V4L2_CID_ILLUMINATORS_2) && HAVE_DECL_V4L2_CID_ILLUMINATORS_2)
+  XLAT(V4L2_CID_ILLUMINATORS_2),
+#endif
+#if defined(V4L2_CID_MIN_BUFFERS_FOR_CAPTURE) || (defined(HAVE_DECL_V4L2_CID_MIN_BUFFERS_FOR_CAPTURE) && HAVE_DECL_V4L2_CID_MIN_BUFFERS_FOR_CAPTURE)
+  XLAT(V4L2_CID_MIN_BUFFERS_FOR_CAPTURE),
+#endif
+#if defined(V4L2_CID_MIN_BUFFERS_FOR_OUTPUT) || (defined(HAVE_DECL_V4L2_CID_MIN_BUFFERS_FOR_OUTPUT) && HAVE_DECL_V4L2_CID_MIN_BUFFERS_FOR_OUTPUT)
+  XLAT(V4L2_CID_MIN_BUFFERS_FOR_OUTPUT),
+#endif
+#if defined(V4L2_CID_ALPHA_COMPONENT) || (defined(HAVE_DECL_V4L2_CID_ALPHA_COMPONENT) && HAVE_DECL_V4L2_CID_ALPHA_COMPONENT)
+  XLAT(V4L2_CID_ALPHA_COMPONENT),
+#endif
+/*  Camera class control IDs */
+#if defined(V4L2_CID_EXPOSURE_AUTO) || (defined(HAVE_DECL_V4L2_CID_EXPOSURE_AUTO) && HAVE_DECL_V4L2_CID_EXPOSURE_AUTO)
+  XLAT(V4L2_CID_EXPOSURE_AUTO),
+#endif
+#if defined(V4L2_CID_EXPOSURE_ABSOLUTE) || (defined(HAVE_DECL_V4L2_CID_EXPOSURE_ABSOLUTE) && HAVE_DECL_V4L2_CID_EXPOSURE_ABSOLUTE)
+  XLAT(V4L2_CID_EXPOSURE_ABSOLUTE),
+#endif
+#if defined(V4L2_CID_EXPOSURE_AUTO_PRIORITY) || (defined(HAVE_DECL_V4L2_CID_EXPOSURE_AUTO_PRIORITY) && HAVE_DECL_V4L2_CID_EXPOSURE_AUTO_PRIORITY)
+  XLAT(V4L2_CID_EXPOSURE_AUTO_PRIORITY),
+#endif
+#if defined(V4L2_CID_PAN_RELATIVE) || (defined(HAVE_DECL_V4L2_CID_PAN_RELATIVE) && HAVE_DECL_V4L2_CID_PAN_RELATIVE)
+  XLAT(V4L2_CID_PAN_RELATIVE),
+#endif
+#if defined(V4L2_CID_TILT_RELATIVE) || (defined(HAVE_DECL_V4L2_CID_TILT_RELATIVE) && HAVE_DECL_V4L2_CID_TILT_RELATIVE)
+  XLAT(V4L2_CID_TILT_RELATIVE),
+#endif
+#if defined(V4L2_CID_PAN_RESET) || (defined(HAVE_DECL_V4L2_CID_PAN_RESET) && HAVE_DECL_V4L2_CID_PAN_RESET)
+  XLAT(V4L2_CID_PAN_RESET),
+#endif
+#if defined(V4L2_CID_TILT_RESET) || (defined(HAVE_DECL_V4L2_CID_TILT_RESET) && HAVE_DECL_V4L2_CID_TILT_RESET)
+  XLAT(V4L2_CID_TILT_RESET),
+#endif
+#if defined(V4L2_CID_PAN_ABSOLUTE) || (defined(HAVE_DECL_V4L2_CID_PAN_ABSOLUTE) && HAVE_DECL_V4L2_CID_PAN_ABSOLUTE)
+  XLAT(V4L2_CID_PAN_ABSOLUTE),
+#endif
+#if defined(V4L2_CID_TILT_ABSOLUTE) || (defined(HAVE_DECL_V4L2_CID_TILT_ABSOLUTE) && HAVE_DECL_V4L2_CID_TILT_ABSOLUTE)
+  XLAT(V4L2_CID_TILT_ABSOLUTE),
+#endif
+#if defined(V4L2_CID_FOCUS_ABSOLUTE) || (defined(HAVE_DECL_V4L2_CID_FOCUS_ABSOLUTE) && HAVE_DECL_V4L2_CID_FOCUS_ABSOLUTE)
+  XLAT(V4L2_CID_FOCUS_ABSOLUTE),
+#endif
+#if defined(V4L2_CID_FOCUS_RELATIVE) || (defined(HAVE_DECL_V4L2_CID_FOCUS_RELATIVE) && HAVE_DECL_V4L2_CID_FOCUS_RELATIVE)
+  XLAT(V4L2_CID_FOCUS_RELATIVE),
+#endif
+#if defined(V4L2_CID_FOCUS_AUTO) || (defined(HAVE_DECL_V4L2_CID_FOCUS_AUTO) && HAVE_DECL_V4L2_CID_FOCUS_AUTO)
+  XLAT(V4L2_CID_FOCUS_AUTO),
+#endif
+#if defined(V4L2_CID_ZOOM_ABSOLUTE) || (defined(HAVE_DECL_V4L2_CID_ZOOM_ABSOLUTE) && HAVE_DECL_V4L2_CID_ZOOM_ABSOLUTE)
+  XLAT(V4L2_CID_ZOOM_ABSOLUTE),
+#endif
+#if defined(V4L2_CID_ZOOM_RELATIVE) || (defined(HAVE_DECL_V4L2_CID_ZOOM_RELATIVE) && HAVE_DECL_V4L2_CID_ZOOM_RELATIVE)
+  XLAT(V4L2_CID_ZOOM_RELATIVE),
+#endif
+#if defined(V4L2_CID_ZOOM_CONTINUOUS) || (defined(HAVE_DECL_V4L2_CID_ZOOM_CONTINUOUS) && HAVE_DECL_V4L2_CID_ZOOM_CONTINUOUS)
+  XLAT(V4L2_CID_ZOOM_CONTINUOUS),
+#endif
+#if defined(V4L2_CID_PRIVACY) || (defined(HAVE_DECL_V4L2_CID_PRIVACY) && HAVE_DECL_V4L2_CID_PRIVACY)
+  XLAT(V4L2_CID_PRIVACY),
+#endif
+#if defined(V4L2_CID_IRIS_ABSOLUTE) || (defined(HAVE_DECL_V4L2_CID_IRIS_ABSOLUTE) && HAVE_DECL_V4L2_CID_IRIS_ABSOLUTE)
+  XLAT(V4L2_CID_IRIS_ABSOLUTE),
+#endif
+#if defined(V4L2_CID_IRIS_RELATIVE) || (defined(HAVE_DECL_V4L2_CID_IRIS_RELATIVE) && HAVE_DECL_V4L2_CID_IRIS_RELATIVE)
+  XLAT(V4L2_CID_IRIS_RELATIVE),
+#endif
+#if defined(V4L2_CID_AUTO_EXPOSURE_BIAS) || (defined(HAVE_DECL_V4L2_CID_AUTO_EXPOSURE_BIAS) && HAVE_DECL_V4L2_CID_AUTO_EXPOSURE_BIAS)
+  XLAT(V4L2_CID_AUTO_EXPOSURE_BIAS),
+#endif
+#if defined(V4L2_CID_AUTO_N_PRESET_WHITE_BALANCE) || (defined(HAVE_DECL_V4L2_CID_AUTO_N_PRESET_WHITE_BALANCE) && HAVE_DECL_V4L2_CID_AUTO_N_PRESET_WHITE_BALANCE)
+  XLAT(V4L2_CID_AUTO_N_PRESET_WHITE_BALANCE),
+#endif
+#if defined(V4L2_CID_WIDE_DYNAMIC_RANGE) || (defined(HAVE_DECL_V4L2_CID_WIDE_DYNAMIC_RANGE) && HAVE_DECL_V4L2_CID_WIDE_DYNAMIC_RANGE)
+  XLAT(V4L2_CID_WIDE_DYNAMIC_RANGE),
+#endif
+#if defined(V4L2_CID_IMAGE_STABILIZATION) || (defined(HAVE_DECL_V4L2_CID_IMAGE_STABILIZATION) && HAVE_DECL_V4L2_CID_IMAGE_STABILIZATION)
+  XLAT(V4L2_CID_IMAGE_STABILIZATION),
+#endif
+#if defined(V4L2_CID_ISO_SENSITIVITY) || (defined(HAVE_DECL_V4L2_CID_ISO_SENSITIVITY) && HAVE_DECL_V4L2_CID_ISO_SENSITIVITY)
+  XLAT(V4L2_CID_ISO_SENSITIVITY),
+#endif
+#if defined(V4L2_CID_ISO_SENSITIVITY_AUTO) || (defined(HAVE_DECL_V4L2_CID_ISO_SENSITIVITY_AUTO) && HAVE_DECL_V4L2_CID_ISO_SENSITIVITY_AUTO)
+  XLAT(V4L2_CID_ISO_SENSITIVITY_AUTO),
+#endif
+#if defined(V4L2_CID_EXPOSURE_METERING) || (defined(HAVE_DECL_V4L2_CID_EXPOSURE_METERING) && HAVE_DECL_V4L2_CID_EXPOSURE_METERING)
+  XLAT(V4L2_CID_EXPOSURE_METERING),
+#endif
+#if defined(V4L2_CID_SCENE_MODE) || (defined(HAVE_DECL_V4L2_CID_SCENE_MODE) && HAVE_DECL_V4L2_CID_SCENE_MODE)
+  XLAT(V4L2_CID_SCENE_MODE),
+#endif
+#if defined(V4L2_CID_3A_LOCK) || (defined(HAVE_DECL_V4L2_CID_3A_LOCK) && HAVE_DECL_V4L2_CID_3A_LOCK)
+  XLAT(V4L2_CID_3A_LOCK),
+#endif
+#if defined(V4L2_CID_AUTO_FOCUS_START) || (defined(HAVE_DECL_V4L2_CID_AUTO_FOCUS_START) && HAVE_DECL_V4L2_CID_AUTO_FOCUS_START)
+  XLAT(V4L2_CID_AUTO_FOCUS_START),
+#endif
+#if defined(V4L2_CID_AUTO_FOCUS_STOP) || (defined(HAVE_DECL_V4L2_CID_AUTO_FOCUS_STOP) && HAVE_DECL_V4L2_CID_AUTO_FOCUS_STOP)
+  XLAT(V4L2_CID_AUTO_FOCUS_STOP),
+#endif
+#if defined(V4L2_CID_AUTO_FOCUS_STATUS) || (defined(HAVE_DECL_V4L2_CID_AUTO_FOCUS_STATUS) && HAVE_DECL_V4L2_CID_AUTO_FOCUS_STATUS)
+  XLAT(V4L2_CID_AUTO_FOCUS_STATUS),
+#endif
+#if defined(V4L2_CID_AUTO_FOCUS_RANGE) || (defined(HAVE_DECL_V4L2_CID_AUTO_FOCUS_RANGE) && HAVE_DECL_V4L2_CID_AUTO_FOCUS_RANGE)
+  XLAT(V4L2_CID_AUTO_FOCUS_RANGE),
+#endif
+#if defined(V4L2_CID_PRIVATE_BASE) || (defined(HAVE_DECL_V4L2_CID_PRIVATE_BASE) && HAVE_DECL_V4L2_CID_PRIVATE_BASE)
+  XLAT(V4L2_CID_PRIVATE_BASE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_control_ids.in b/strace/xlat/v4l2_control_ids.in
new file mode 100644
index 0000000..3dee933
--- /dev/null
+++ b/strace/xlat/v4l2_control_ids.in
@@ -0,0 +1,77 @@
+0
+V4L2_CID_BRIGHTNESS
+V4L2_CID_CONTRAST
+V4L2_CID_SATURATION
+V4L2_CID_HUE
+V4L2_CID_AUDIO_VOLUME
+V4L2_CID_AUDIO_BALANCE
+V4L2_CID_AUDIO_BASS
+V4L2_CID_AUDIO_TREBLE
+V4L2_CID_AUDIO_MUTE
+V4L2_CID_AUDIO_LOUDNESS
+V4L2_CID_BLACK_LEVEL
+V4L2_CID_AUTO_WHITE_BALANCE
+V4L2_CID_DO_WHITE_BALANCE
+V4L2_CID_RED_BALANCE
+V4L2_CID_BLUE_BALANCE
+V4L2_CID_GAMMA
+V4L2_CID_WHITENESS
+V4L2_CID_EXPOSURE
+V4L2_CID_AUTOGAIN
+V4L2_CID_GAIN
+V4L2_CID_HFLIP
+V4L2_CID_VFLIP
+V4L2_CID_HCENTER
+V4L2_CID_VCENTER
+V4L2_CID_POWER_LINE_FREQUENCY
+V4L2_CID_HUE_AUTO
+V4L2_CID_WHITE_BALANCE_TEMPERATURE
+V4L2_CID_SHARPNESS
+V4L2_CID_BACKLIGHT_COMPENSATION
+V4L2_CID_CHROMA_AGC
+V4L2_CID_CHROMA_GAIN
+V4L2_CID_COLOR_KILLER
+V4L2_CID_COLORFX
+V4L2_CID_COLORFX_CBCR
+V4L2_CID_AUTOBRIGHTNESS
+V4L2_CID_BAND_STOP_FILTER
+V4L2_CID_ROTATE
+V4L2_CID_BG_COLOR
+V4L2_CID_ILLUMINATORS_1
+V4L2_CID_ILLUMINATORS_2
+V4L2_CID_MIN_BUFFERS_FOR_CAPTURE
+V4L2_CID_MIN_BUFFERS_FOR_OUTPUT
+V4L2_CID_ALPHA_COMPONENT
+/*  Camera class control IDs */
+V4L2_CID_EXPOSURE_AUTO
+V4L2_CID_EXPOSURE_ABSOLUTE
+V4L2_CID_EXPOSURE_AUTO_PRIORITY
+V4L2_CID_PAN_RELATIVE
+V4L2_CID_TILT_RELATIVE
+V4L2_CID_PAN_RESET
+V4L2_CID_TILT_RESET
+V4L2_CID_PAN_ABSOLUTE
+V4L2_CID_TILT_ABSOLUTE
+V4L2_CID_FOCUS_ABSOLUTE
+V4L2_CID_FOCUS_RELATIVE
+V4L2_CID_FOCUS_AUTO
+V4L2_CID_ZOOM_ABSOLUTE
+V4L2_CID_ZOOM_RELATIVE
+V4L2_CID_ZOOM_CONTINUOUS
+V4L2_CID_PRIVACY
+V4L2_CID_IRIS_ABSOLUTE
+V4L2_CID_IRIS_RELATIVE
+V4L2_CID_AUTO_EXPOSURE_BIAS
+V4L2_CID_AUTO_N_PRESET_WHITE_BALANCE
+V4L2_CID_WIDE_DYNAMIC_RANGE
+V4L2_CID_IMAGE_STABILIZATION
+V4L2_CID_ISO_SENSITIVITY
+V4L2_CID_ISO_SENSITIVITY_AUTO
+V4L2_CID_EXPOSURE_METERING
+V4L2_CID_SCENE_MODE
+V4L2_CID_3A_LOCK
+V4L2_CID_AUTO_FOCUS_START
+V4L2_CID_AUTO_FOCUS_STOP
+V4L2_CID_AUTO_FOCUS_STATUS
+V4L2_CID_AUTO_FOCUS_RANGE
+V4L2_CID_PRIVATE_BASE
diff --git a/strace/xlat/v4l2_control_types.h b/strace/xlat/v4l2_control_types.h
new file mode 100644
index 0000000..37ac812
--- /dev/null
+++ b/strace/xlat/v4l2_control_types.h
@@ -0,0 +1,43 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_control_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_control_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_control_types[] = {
+#if defined(V4L2_CTRL_TYPE_INTEGER) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_INTEGER) && HAVE_DECL_V4L2_CTRL_TYPE_INTEGER)
+  XLAT(V4L2_CTRL_TYPE_INTEGER),
+#endif
+#if defined(V4L2_CTRL_TYPE_BOOLEAN) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_BOOLEAN) && HAVE_DECL_V4L2_CTRL_TYPE_BOOLEAN)
+  XLAT(V4L2_CTRL_TYPE_BOOLEAN),
+#endif
+#if defined(V4L2_CTRL_TYPE_MENU) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_MENU) && HAVE_DECL_V4L2_CTRL_TYPE_MENU)
+  XLAT(V4L2_CTRL_TYPE_MENU),
+#endif
+#if defined(V4L2_CTRL_TYPE_INTEGER_MENU) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_INTEGER_MENU) && HAVE_DECL_V4L2_CTRL_TYPE_INTEGER_MENU)
+  XLAT(V4L2_CTRL_TYPE_INTEGER_MENU),
+#endif
+#if defined(V4L2_CTRL_TYPE_BITMASK) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_BITMASK) && HAVE_DECL_V4L2_CTRL_TYPE_BITMASK)
+  XLAT(V4L2_CTRL_TYPE_BITMASK),
+#endif
+#if defined(V4L2_CTRL_TYPE_BUTTON) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_BUTTON) && HAVE_DECL_V4L2_CTRL_TYPE_BUTTON)
+  XLAT(V4L2_CTRL_TYPE_BUTTON),
+#endif
+#if defined(V4L2_CTRL_TYPE_INTEGER64) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_INTEGER64) && HAVE_DECL_V4L2_CTRL_TYPE_INTEGER64)
+  XLAT(V4L2_CTRL_TYPE_INTEGER64),
+#endif
+#if defined(V4L2_CTRL_TYPE_STRING) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_STRING) && HAVE_DECL_V4L2_CTRL_TYPE_STRING)
+  XLAT(V4L2_CTRL_TYPE_STRING),
+#endif
+#if defined(V4L2_CTRL_TYPE_CTRL_CLASS) || (defined(HAVE_DECL_V4L2_CTRL_TYPE_CTRL_CLASS) && HAVE_DECL_V4L2_CTRL_TYPE_CTRL_CLASS)
+  XLAT(V4L2_CTRL_TYPE_CTRL_CLASS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_control_types.in b/strace/xlat/v4l2_control_types.in
new file mode 100644
index 0000000..26c587e
--- /dev/null
+++ b/strace/xlat/v4l2_control_types.in
@@ -0,0 +1,9 @@
+V4L2_CTRL_TYPE_INTEGER
+V4L2_CTRL_TYPE_BOOLEAN
+V4L2_CTRL_TYPE_MENU
+V4L2_CTRL_TYPE_INTEGER_MENU
+V4L2_CTRL_TYPE_BITMASK
+V4L2_CTRL_TYPE_BUTTON
+V4L2_CTRL_TYPE_INTEGER64
+V4L2_CTRL_TYPE_STRING
+V4L2_CTRL_TYPE_CTRL_CLASS
diff --git a/strace/xlat/v4l2_device_capabilities_flags.h b/strace/xlat/v4l2_device_capabilities_flags.h
new file mode 100644
index 0000000..248350e
--- /dev/null
+++ b/strace/xlat/v4l2_device_capabilities_flags.h
@@ -0,0 +1,85 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_device_capabilities_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_device_capabilities_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_device_capabilities_flags[] = {
+#if defined(V4L2_CAP_VIDEO_CAPTURE) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_CAPTURE) && HAVE_DECL_V4L2_CAP_VIDEO_CAPTURE)
+  XLAT(V4L2_CAP_VIDEO_CAPTURE),
+#endif
+#if defined(V4L2_CAP_VIDEO_OUTPUT) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_OUTPUT) && HAVE_DECL_V4L2_CAP_VIDEO_OUTPUT)
+  XLAT(V4L2_CAP_VIDEO_OUTPUT),
+#endif
+#if defined(V4L2_CAP_VIDEO_OVERLAY) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_OVERLAY) && HAVE_DECL_V4L2_CAP_VIDEO_OVERLAY)
+  XLAT(V4L2_CAP_VIDEO_OVERLAY),
+#endif
+#if defined(V4L2_CAP_VBI_CAPTURE) || (defined(HAVE_DECL_V4L2_CAP_VBI_CAPTURE) && HAVE_DECL_V4L2_CAP_VBI_CAPTURE)
+  XLAT(V4L2_CAP_VBI_CAPTURE),
+#endif
+#if defined(V4L2_CAP_VBI_OUTPUT) || (defined(HAVE_DECL_V4L2_CAP_VBI_OUTPUT) && HAVE_DECL_V4L2_CAP_VBI_OUTPUT)
+  XLAT(V4L2_CAP_VBI_OUTPUT),
+#endif
+#if defined(V4L2_CAP_SLICED_VBI_CAPTURE) || (defined(HAVE_DECL_V4L2_CAP_SLICED_VBI_CAPTURE) && HAVE_DECL_V4L2_CAP_SLICED_VBI_CAPTURE)
+  XLAT(V4L2_CAP_SLICED_VBI_CAPTURE),
+#endif
+#if defined(V4L2_CAP_SLICED_VBI_OUTPUT) || (defined(HAVE_DECL_V4L2_CAP_SLICED_VBI_OUTPUT) && HAVE_DECL_V4L2_CAP_SLICED_VBI_OUTPUT)
+  XLAT(V4L2_CAP_SLICED_VBI_OUTPUT),
+#endif
+#if defined(V4L2_CAP_RDS_CAPTURE) || (defined(HAVE_DECL_V4L2_CAP_RDS_CAPTURE) && HAVE_DECL_V4L2_CAP_RDS_CAPTURE)
+  XLAT(V4L2_CAP_RDS_CAPTURE),
+#endif
+#if defined(V4L2_CAP_VIDEO_OUTPUT_OVERLAY) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_OUTPUT_OVERLAY) && HAVE_DECL_V4L2_CAP_VIDEO_OUTPUT_OVERLAY)
+  XLAT(V4L2_CAP_VIDEO_OUTPUT_OVERLAY),
+#endif
+#if defined(V4L2_CAP_HW_FREQ_SEEK) || (defined(HAVE_DECL_V4L2_CAP_HW_FREQ_SEEK) && HAVE_DECL_V4L2_CAP_HW_FREQ_SEEK)
+  XLAT(V4L2_CAP_HW_FREQ_SEEK),
+#endif
+#if defined(V4L2_CAP_RDS_OUTPUT) || (defined(HAVE_DECL_V4L2_CAP_RDS_OUTPUT) && HAVE_DECL_V4L2_CAP_RDS_OUTPUT)
+  XLAT(V4L2_CAP_RDS_OUTPUT),
+#endif
+#if defined(V4L2_CAP_VIDEO_CAPTURE_MPLANE) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_CAPTURE_MPLANE) && HAVE_DECL_V4L2_CAP_VIDEO_CAPTURE_MPLANE)
+  XLAT(V4L2_CAP_VIDEO_CAPTURE_MPLANE),
+#endif
+#if defined(V4L2_CAP_VIDEO_OUTPUT_MPLANE) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_OUTPUT_MPLANE) && HAVE_DECL_V4L2_CAP_VIDEO_OUTPUT_MPLANE)
+  XLAT(V4L2_CAP_VIDEO_OUTPUT_MPLANE),
+#endif
+#if defined(V4L2_CAP_VIDEO_M2M) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_M2M) && HAVE_DECL_V4L2_CAP_VIDEO_M2M)
+  XLAT(V4L2_CAP_VIDEO_M2M),
+#endif
+#if defined(V4L2_CAP_VIDEO_M2M_MPLANE) || (defined(HAVE_DECL_V4L2_CAP_VIDEO_M2M_MPLANE) && HAVE_DECL_V4L2_CAP_VIDEO_M2M_MPLANE)
+  XLAT(V4L2_CAP_VIDEO_M2M_MPLANE),
+#endif
+#if defined(V4L2_CAP_TUNER) || (defined(HAVE_DECL_V4L2_CAP_TUNER) && HAVE_DECL_V4L2_CAP_TUNER)
+  XLAT(V4L2_CAP_TUNER),
+#endif
+#if defined(V4L2_CAP_AUDIO) || (defined(HAVE_DECL_V4L2_CAP_AUDIO) && HAVE_DECL_V4L2_CAP_AUDIO)
+  XLAT(V4L2_CAP_AUDIO),
+#endif
+#if defined(V4L2_CAP_RADIO) || (defined(HAVE_DECL_V4L2_CAP_RADIO) && HAVE_DECL_V4L2_CAP_RADIO)
+  XLAT(V4L2_CAP_RADIO),
+#endif
+#if defined(V4L2_CAP_MODULATOR) || (defined(HAVE_DECL_V4L2_CAP_MODULATOR) && HAVE_DECL_V4L2_CAP_MODULATOR)
+  XLAT(V4L2_CAP_MODULATOR),
+#endif
+#if defined(V4L2_CAP_READWRITE) || (defined(HAVE_DECL_V4L2_CAP_READWRITE) && HAVE_DECL_V4L2_CAP_READWRITE)
+  XLAT(V4L2_CAP_READWRITE),
+#endif
+#if defined(V4L2_CAP_ASYNCIO) || (defined(HAVE_DECL_V4L2_CAP_ASYNCIO) && HAVE_DECL_V4L2_CAP_ASYNCIO)
+  XLAT(V4L2_CAP_ASYNCIO),
+#endif
+#if defined(V4L2_CAP_STREAMING) || (defined(HAVE_DECL_V4L2_CAP_STREAMING) && HAVE_DECL_V4L2_CAP_STREAMING)
+  XLAT(V4L2_CAP_STREAMING),
+#endif
+#if defined(V4L2_CAP_DEVICE_CAPS) || (defined(HAVE_DECL_V4L2_CAP_DEVICE_CAPS) && HAVE_DECL_V4L2_CAP_DEVICE_CAPS)
+  XLAT(V4L2_CAP_DEVICE_CAPS),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_device_capabilities_flags.in b/strace/xlat/v4l2_device_capabilities_flags.in
new file mode 100644
index 0000000..6e8502e
--- /dev/null
+++ b/strace/xlat/v4l2_device_capabilities_flags.in
@@ -0,0 +1,23 @@
+V4L2_CAP_VIDEO_CAPTURE
+V4L2_CAP_VIDEO_OUTPUT
+V4L2_CAP_VIDEO_OVERLAY
+V4L2_CAP_VBI_CAPTURE
+V4L2_CAP_VBI_OUTPUT
+V4L2_CAP_SLICED_VBI_CAPTURE
+V4L2_CAP_SLICED_VBI_OUTPUT
+V4L2_CAP_RDS_CAPTURE
+V4L2_CAP_VIDEO_OUTPUT_OVERLAY
+V4L2_CAP_HW_FREQ_SEEK
+V4L2_CAP_RDS_OUTPUT
+V4L2_CAP_VIDEO_CAPTURE_MPLANE
+V4L2_CAP_VIDEO_OUTPUT_MPLANE
+V4L2_CAP_VIDEO_M2M
+V4L2_CAP_VIDEO_M2M_MPLANE
+V4L2_CAP_TUNER
+V4L2_CAP_AUDIO
+V4L2_CAP_RADIO
+V4L2_CAP_MODULATOR
+V4L2_CAP_READWRITE
+V4L2_CAP_ASYNCIO
+V4L2_CAP_STREAMING
+V4L2_CAP_DEVICE_CAPS
diff --git a/strace/xlat/v4l2_fields.h b/strace/xlat/v4l2_fields.h
new file mode 100644
index 0000000..a6c78db
--- /dev/null
+++ b/strace/xlat/v4l2_fields.h
@@ -0,0 +1,46 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_fields.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_fields[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_fields[] = {
+#if defined(V4L2_FIELD_ANY) || (defined(HAVE_DECL_V4L2_FIELD_ANY) && HAVE_DECL_V4L2_FIELD_ANY)
+  XLAT(V4L2_FIELD_ANY),
+#endif
+#if defined(V4L2_FIELD_NONE) || (defined(HAVE_DECL_V4L2_FIELD_NONE) && HAVE_DECL_V4L2_FIELD_NONE)
+  XLAT(V4L2_FIELD_NONE),
+#endif
+#if defined(V4L2_FIELD_TOP) || (defined(HAVE_DECL_V4L2_FIELD_TOP) && HAVE_DECL_V4L2_FIELD_TOP)
+  XLAT(V4L2_FIELD_TOP),
+#endif
+#if defined(V4L2_FIELD_BOTTOM) || (defined(HAVE_DECL_V4L2_FIELD_BOTTOM) && HAVE_DECL_V4L2_FIELD_BOTTOM)
+  XLAT(V4L2_FIELD_BOTTOM),
+#endif
+#if defined(V4L2_FIELD_INTERLACED) || (defined(HAVE_DECL_V4L2_FIELD_INTERLACED) && HAVE_DECL_V4L2_FIELD_INTERLACED)
+  XLAT(V4L2_FIELD_INTERLACED),
+#endif
+#if defined(V4L2_FIELD_SEQ_TB) || (defined(HAVE_DECL_V4L2_FIELD_SEQ_TB) && HAVE_DECL_V4L2_FIELD_SEQ_TB)
+  XLAT(V4L2_FIELD_SEQ_TB),
+#endif
+#if defined(V4L2_FIELD_SEQ_BT) || (defined(HAVE_DECL_V4L2_FIELD_SEQ_BT) && HAVE_DECL_V4L2_FIELD_SEQ_BT)
+  XLAT(V4L2_FIELD_SEQ_BT),
+#endif
+#if defined(V4L2_FIELD_ALTERNATE) || (defined(HAVE_DECL_V4L2_FIELD_ALTERNATE) && HAVE_DECL_V4L2_FIELD_ALTERNATE)
+  XLAT(V4L2_FIELD_ALTERNATE),
+#endif
+#if defined(V4L2_FIELD_INTERLACED_TB) || (defined(HAVE_DECL_V4L2_FIELD_INTERLACED_TB) && HAVE_DECL_V4L2_FIELD_INTERLACED_TB)
+  XLAT(V4L2_FIELD_INTERLACED_TB),
+#endif
+#if defined(V4L2_FIELD_INTERLACED_BT) || (defined(HAVE_DECL_V4L2_FIELD_INTERLACED_BT) && HAVE_DECL_V4L2_FIELD_INTERLACED_BT)
+  XLAT(V4L2_FIELD_INTERLACED_BT),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_fields.in b/strace/xlat/v4l2_fields.in
new file mode 100644
index 0000000..60d00e1
--- /dev/null
+++ b/strace/xlat/v4l2_fields.in
@@ -0,0 +1,10 @@
+V4L2_FIELD_ANY
+V4L2_FIELD_NONE
+V4L2_FIELD_TOP
+V4L2_FIELD_BOTTOM
+V4L2_FIELD_INTERLACED
+V4L2_FIELD_SEQ_TB
+V4L2_FIELD_SEQ_BT
+V4L2_FIELD_ALTERNATE
+V4L2_FIELD_INTERLACED_TB
+V4L2_FIELD_INTERLACED_BT
diff --git a/strace/xlat/v4l2_format_description_flags.h b/strace/xlat/v4l2_format_description_flags.h
new file mode 100644
index 0000000..d82236d
--- /dev/null
+++ b/strace/xlat/v4l2_format_description_flags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_format_description_flags.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_format_description_flags[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_format_description_flags[] = {
+#if defined(V4L2_FMT_FLAG_COMPRESSED) || (defined(HAVE_DECL_V4L2_FMT_FLAG_COMPRESSED) && HAVE_DECL_V4L2_FMT_FLAG_COMPRESSED)
+  XLAT(V4L2_FMT_FLAG_COMPRESSED),
+#endif
+#if defined(V4L2_FMT_FLAG_EMULATED) || (defined(HAVE_DECL_V4L2_FMT_FLAG_EMULATED) && HAVE_DECL_V4L2_FMT_FLAG_EMULATED)
+  XLAT(V4L2_FMT_FLAG_EMULATED),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_format_description_flags.in b/strace/xlat/v4l2_format_description_flags.in
new file mode 100644
index 0000000..ed5a3d3
--- /dev/null
+++ b/strace/xlat/v4l2_format_description_flags.in
@@ -0,0 +1,2 @@
+V4L2_FMT_FLAG_COMPRESSED
+V4L2_FMT_FLAG_EMULATED
diff --git a/strace/xlat/v4l2_frameinterval_types.h b/strace/xlat/v4l2_frameinterval_types.h
new file mode 100644
index 0000000..728c3c7
--- /dev/null
+++ b/strace/xlat/v4l2_frameinterval_types.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_frameinterval_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_frameinterval_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_frameinterval_types[] = {
+#if defined(V4L2_FRMIVAL_TYPE_DISCRETE) || (defined(HAVE_DECL_V4L2_FRMIVAL_TYPE_DISCRETE) && HAVE_DECL_V4L2_FRMIVAL_TYPE_DISCRETE)
+  XLAT(V4L2_FRMIVAL_TYPE_DISCRETE),
+#endif
+#if defined(V4L2_FRMIVAL_TYPE_CONTINUOUS) || (defined(HAVE_DECL_V4L2_FRMIVAL_TYPE_CONTINUOUS) && HAVE_DECL_V4L2_FRMIVAL_TYPE_CONTINUOUS)
+  XLAT(V4L2_FRMIVAL_TYPE_CONTINUOUS),
+#endif
+#if defined(V4L2_FRMIVAL_TYPE_STEPWISE) || (defined(HAVE_DECL_V4L2_FRMIVAL_TYPE_STEPWISE) && HAVE_DECL_V4L2_FRMIVAL_TYPE_STEPWISE)
+  XLAT(V4L2_FRMIVAL_TYPE_STEPWISE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_frameinterval_types.in b/strace/xlat/v4l2_frameinterval_types.in
new file mode 100644
index 0000000..30d46d6
--- /dev/null
+++ b/strace/xlat/v4l2_frameinterval_types.in
@@ -0,0 +1,3 @@
+V4L2_FRMIVAL_TYPE_DISCRETE
+V4L2_FRMIVAL_TYPE_CONTINUOUS
+V4L2_FRMIVAL_TYPE_STEPWISE
diff --git a/strace/xlat/v4l2_framesize_types.h b/strace/xlat/v4l2_framesize_types.h
new file mode 100644
index 0000000..28a77c2
--- /dev/null
+++ b/strace/xlat/v4l2_framesize_types.h
@@ -0,0 +1,25 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_framesize_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_framesize_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_framesize_types[] = {
+#if defined(V4L2_FRMSIZE_TYPE_DISCRETE) || (defined(HAVE_DECL_V4L2_FRMSIZE_TYPE_DISCRETE) && HAVE_DECL_V4L2_FRMSIZE_TYPE_DISCRETE)
+  XLAT(V4L2_FRMSIZE_TYPE_DISCRETE),
+#endif
+#if defined(V4L2_FRMSIZE_TYPE_CONTINUOUS) || (defined(HAVE_DECL_V4L2_FRMSIZE_TYPE_CONTINUOUS) && HAVE_DECL_V4L2_FRMSIZE_TYPE_CONTINUOUS)
+  XLAT(V4L2_FRMSIZE_TYPE_CONTINUOUS),
+#endif
+#if defined(V4L2_FRMSIZE_TYPE_STEPWISE) || (defined(HAVE_DECL_V4L2_FRMSIZE_TYPE_STEPWISE) && HAVE_DECL_V4L2_FRMSIZE_TYPE_STEPWISE)
+  XLAT(V4L2_FRMSIZE_TYPE_STEPWISE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_framesize_types.in b/strace/xlat/v4l2_framesize_types.in
new file mode 100644
index 0000000..5eb2b83
--- /dev/null
+++ b/strace/xlat/v4l2_framesize_types.in
@@ -0,0 +1,3 @@
+V4L2_FRMSIZE_TYPE_DISCRETE
+V4L2_FRMSIZE_TYPE_CONTINUOUS
+V4L2_FRMSIZE_TYPE_STEPWISE
diff --git a/strace/xlat/v4l2_input_types.h b/strace/xlat/v4l2_input_types.h
new file mode 100644
index 0000000..8707ce7
--- /dev/null
+++ b/strace/xlat/v4l2_input_types.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_input_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_input_types[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_input_types[] = {
+#if defined(V4L2_INPUT_TYPE_TUNER) || (defined(HAVE_DECL_V4L2_INPUT_TYPE_TUNER) && HAVE_DECL_V4L2_INPUT_TYPE_TUNER)
+  XLAT(V4L2_INPUT_TYPE_TUNER),
+#endif
+#if defined(V4L2_INPUT_TYPE_CAMERA) || (defined(HAVE_DECL_V4L2_INPUT_TYPE_CAMERA) && HAVE_DECL_V4L2_INPUT_TYPE_CAMERA)
+  XLAT(V4L2_INPUT_TYPE_CAMERA),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_input_types.in b/strace/xlat/v4l2_input_types.in
new file mode 100644
index 0000000..e05a5fe
--- /dev/null
+++ b/strace/xlat/v4l2_input_types.in
@@ -0,0 +1,2 @@
+V4L2_INPUT_TYPE_TUNER
+V4L2_INPUT_TYPE_CAMERA
diff --git a/strace/xlat/v4l2_memories.h b/strace/xlat/v4l2_memories.h
new file mode 100644
index 0000000..eda2ff9
--- /dev/null
+++ b/strace/xlat/v4l2_memories.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_memories.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_memories[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_memories[] = {
+#if defined(V4L2_MEMORY_MMAP) || (defined(HAVE_DECL_V4L2_MEMORY_MMAP) && HAVE_DECL_V4L2_MEMORY_MMAP)
+  XLAT(V4L2_MEMORY_MMAP),
+#endif
+#if defined(V4L2_MEMORY_USERPTR) || (defined(HAVE_DECL_V4L2_MEMORY_USERPTR) && HAVE_DECL_V4L2_MEMORY_USERPTR)
+  XLAT(V4L2_MEMORY_USERPTR),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_memories.in b/strace/xlat/v4l2_memories.in
new file mode 100644
index 0000000..e592d57
--- /dev/null
+++ b/strace/xlat/v4l2_memories.in
@@ -0,0 +1,2 @@
+V4L2_MEMORY_MMAP
+V4L2_MEMORY_USERPTR
diff --git a/strace/xlat/v4l2_streaming_capabilities.h b/strace/xlat/v4l2_streaming_capabilities.h
new file mode 100644
index 0000000..839146a
--- /dev/null
+++ b/strace/xlat/v4l2_streaming_capabilities.h
@@ -0,0 +1,19 @@
+/* Generated by ./xlat/gen.sh from ./xlat/v4l2_streaming_capabilities.in; do not edit. */
+
+#ifdef IN_MPERS
+
+extern const struct xlat v4l2_streaming_capabilities[];
+
+#else
+
+# if !(defined HAVE_M32_MPERS || defined HAVE_MX32_MPERS)
+static
+# endif
+const struct xlat v4l2_streaming_capabilities[] = {
+#if defined(V4L2_CAP_TIMEPERFRAME) || (defined(HAVE_DECL_V4L2_CAP_TIMEPERFRAME) && HAVE_DECL_V4L2_CAP_TIMEPERFRAME)
+  XLAT(V4L2_CAP_TIMEPERFRAME),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/v4l2_streaming_capabilities.in b/strace/xlat/v4l2_streaming_capabilities.in
new file mode 100644
index 0000000..1ae5e15
--- /dev/null
+++ b/strace/xlat/v4l2_streaming_capabilities.in
@@ -0,0 +1 @@
+V4L2_CAP_TIMEPERFRAME
diff --git a/strace/xlat/wait4_options.h b/strace/xlat/wait4_options.h
new file mode 100644
index 0000000..4960200
--- /dev/null
+++ b/strace/xlat/wait4_options.h
@@ -0,0 +1,51 @@
+/* Generated by ./xlat/gen.sh from ./xlat/wait4_options.in; do not edit. */
+#ifndef WSTOPPED
+#endif
+#if !(defined(__WCLONE) || (defined(HAVE_DECL___WCLONE) && HAVE_DECL___WCLONE))
+# define __WCLONE 0x80000000
+#endif
+#if !(defined(__WALL) || (defined(HAVE_DECL___WALL) && HAVE_DECL___WALL))
+# define __WALL 0x40000000
+#endif
+#if !(defined(__WNOTHREAD) || (defined(HAVE_DECL___WNOTHREAD) && HAVE_DECL___WNOTHREAD))
+# define __WNOTHREAD 0x20000000
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat wait4_options in mpers mode
+
+#else
+
+static
+const struct xlat wait4_options[] = {
+#if defined(WNOHANG) || (defined(HAVE_DECL_WNOHANG) && HAVE_DECL_WNOHANG)
+  XLAT(WNOHANG),
+#endif
+#ifndef WSTOPPED
+#if defined(WUNTRACED) || (defined(HAVE_DECL_WUNTRACED) && HAVE_DECL_WUNTRACED)
+  XLAT(WUNTRACED),
+#endif
+#endif
+#if defined(WEXITED) || (defined(HAVE_DECL_WEXITED) && HAVE_DECL_WEXITED)
+  XLAT(WEXITED),
+#endif
+#if defined(WTRAPPED) || (defined(HAVE_DECL_WTRAPPED) && HAVE_DECL_WTRAPPED)
+  XLAT(WTRAPPED),
+#endif
+#if defined(WSTOPPED) || (defined(HAVE_DECL_WSTOPPED) && HAVE_DECL_WSTOPPED)
+  XLAT(WSTOPPED),
+#endif
+#if defined(WCONTINUED) || (defined(HAVE_DECL_WCONTINUED) && HAVE_DECL_WCONTINUED)
+  XLAT(WCONTINUED),
+#endif
+#if defined(WNOWAIT) || (defined(HAVE_DECL_WNOWAIT) && HAVE_DECL_WNOWAIT)
+  XLAT(WNOWAIT),
+#endif
+ XLAT(__WCLONE),
+ XLAT(__WALL),
+ XLAT(__WNOTHREAD),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/wait4_options.in b/strace/xlat/wait4_options.in
new file mode 100644
index 0000000..df9f085
--- /dev/null
+++ b/strace/xlat/wait4_options.in
@@ -0,0 +1,12 @@
+WNOHANG
+#ifndef WSTOPPED
+WUNTRACED
+#endif
+WEXITED
+WTRAPPED
+WSTOPPED
+WCONTINUED
+WNOWAIT
+__WCLONE 0x80000000
+__WALL 0x40000000
+__WNOTHREAD 0x20000000
diff --git a/strace/xlat/waitid_types.h b/strace/xlat/waitid_types.h
new file mode 100644
index 0000000..ddee8ef
--- /dev/null
+++ b/strace/xlat/waitid_types.h
@@ -0,0 +1,41 @@
+/* Generated by ./xlat/gen.sh from ./xlat/waitid_types.in; do not edit. */
+
+#ifdef IN_MPERS
+
+# error static const struct xlat waitid_types in mpers mode
+
+#else
+
+static
+const struct xlat waitid_types[] = {
+#if defined(P_PID) || (defined(HAVE_DECL_P_PID) && HAVE_DECL_P_PID)
+  XLAT(P_PID),
+#endif
+#if defined(P_PPID) || (defined(HAVE_DECL_P_PPID) && HAVE_DECL_P_PPID)
+  XLAT(P_PPID),
+#endif
+#if defined(P_PGID) || (defined(HAVE_DECL_P_PGID) && HAVE_DECL_P_PGID)
+  XLAT(P_PGID),
+#endif
+#if defined(P_SID) || (defined(HAVE_DECL_P_SID) && HAVE_DECL_P_SID)
+  XLAT(P_SID),
+#endif
+#if defined(P_CID) || (defined(HAVE_DECL_P_CID) && HAVE_DECL_P_CID)
+  XLAT(P_CID),
+#endif
+#if defined(P_UID) || (defined(HAVE_DECL_P_UID) && HAVE_DECL_P_UID)
+  XLAT(P_UID),
+#endif
+#if defined(P_GID) || (defined(HAVE_DECL_P_GID) && HAVE_DECL_P_GID)
+  XLAT(P_GID),
+#endif
+#if defined(P_ALL) || (defined(HAVE_DECL_P_ALL) && HAVE_DECL_P_ALL)
+  XLAT(P_ALL),
+#endif
+#if defined(P_LWPID) || (defined(HAVE_DECL_P_LWPID) && HAVE_DECL_P_LWPID)
+  XLAT(P_LWPID),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/waitid_types.in b/strace/xlat/waitid_types.in
new file mode 100644
index 0000000..99a3560
--- /dev/null
+++ b/strace/xlat/waitid_types.in
@@ -0,0 +1,9 @@
+P_PID
+P_PPID
+P_PGID
+P_SID
+P_CID
+P_UID
+P_GID
+P_ALL
+P_LWPID
diff --git a/strace/xlat/whence_codes.h b/strace/xlat/whence_codes.h
new file mode 100644
index 0000000..aa3f862
--- /dev/null
+++ b/strace/xlat/whence_codes.h
@@ -0,0 +1,24 @@
+/* Generated by ./xlat/gen.sh from ./xlat/whence_codes.in; do not edit. */
+
+#ifndef IN_MPERS
+
+const struct xlat whence_codes[] = {
+#if defined(SEEK_SET) || (defined(HAVE_DECL_SEEK_SET) && HAVE_DECL_SEEK_SET)
+  XLAT(SEEK_SET),
+#endif
+#if defined(SEEK_CUR) || (defined(HAVE_DECL_SEEK_CUR) && HAVE_DECL_SEEK_CUR)
+  XLAT(SEEK_CUR),
+#endif
+#if defined(SEEK_END) || (defined(HAVE_DECL_SEEK_END) && HAVE_DECL_SEEK_END)
+  XLAT(SEEK_END),
+#endif
+#if defined(SEEK_DATA) || (defined(HAVE_DECL_SEEK_DATA) && HAVE_DECL_SEEK_DATA)
+  XLAT(SEEK_DATA),
+#endif
+#if defined(SEEK_HOLE) || (defined(HAVE_DECL_SEEK_HOLE) && HAVE_DECL_SEEK_HOLE)
+  XLAT(SEEK_HOLE),
+#endif
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/whence_codes.in b/strace/xlat/whence_codes.in
new file mode 100644
index 0000000..c04d79a
--- /dev/null
+++ b/strace/xlat/whence_codes.in
@@ -0,0 +1,5 @@
+SEEK_SET
+SEEK_CUR
+SEEK_END
+SEEK_DATA
+SEEK_HOLE
diff --git a/strace/xlat/xattrflags.h b/strace/xlat/xattrflags.h
new file mode 100644
index 0000000..36adfd0
--- /dev/null
+++ b/strace/xlat/xattrflags.h
@@ -0,0 +1,22 @@
+/* Generated by ./xlat/gen.sh from ./xlat/xattrflags.in; do not edit. */
+#if !(defined(XATTR_CREATE) || (defined(HAVE_DECL_XATTR_CREATE) && HAVE_DECL_XATTR_CREATE))
+# define XATTR_CREATE 1
+#endif
+#if !(defined(XATTR_REPLACE) || (defined(HAVE_DECL_XATTR_REPLACE) && HAVE_DECL_XATTR_REPLACE))
+# define XATTR_REPLACE 2
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat xattrflags in mpers mode
+
+#else
+
+static
+const struct xlat xattrflags[] = {
+ XLAT(XATTR_CREATE),
+ XLAT(XATTR_REPLACE),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/xattrflags.in b/strace/xlat/xattrflags.in
new file mode 100644
index 0000000..37488ee
--- /dev/null
+++ b/strace/xlat/xattrflags.in
@@ -0,0 +1,2 @@
+XATTR_CREATE	1
+XATTR_REPLACE	2
diff --git a/strace/xlat/xfs_dqblk_flags.h b/strace/xlat/xfs_dqblk_flags.h
new file mode 100644
index 0000000..b0a9184
--- /dev/null
+++ b/strace/xlat/xfs_dqblk_flags.h
@@ -0,0 +1,26 @@
+/* Generated by ./xlat/gen.sh from ./xlat/xfs_dqblk_flags.in; do not edit. */
+#if !(defined(XFS_USER_QUOTA) || (defined(HAVE_DECL_XFS_USER_QUOTA) && HAVE_DECL_XFS_USER_QUOTA))
+# define XFS_USER_QUOTA (1<<0)
+#endif
+#if !(defined(XFS_PROJ_QUOTA) || (defined(HAVE_DECL_XFS_PROJ_QUOTA) && HAVE_DECL_XFS_PROJ_QUOTA))
+# define XFS_PROJ_QUOTA (1<<1)
+#endif
+#if !(defined(XFS_GROUP_QUOTA) || (defined(HAVE_DECL_XFS_GROUP_QUOTA) && HAVE_DECL_XFS_GROUP_QUOTA))
+# define XFS_GROUP_QUOTA (1<<2)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat xfs_dqblk_flags in mpers mode
+
+#else
+
+static
+const struct xlat xfs_dqblk_flags[] = {
+ XLAT(XFS_USER_QUOTA),
+ XLAT(XFS_PROJ_QUOTA),
+ XLAT(XFS_GROUP_QUOTA),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/xfs_dqblk_flags.in b/strace/xlat/xfs_dqblk_flags.in
new file mode 100644
index 0000000..c3277bb
--- /dev/null
+++ b/strace/xlat/xfs_dqblk_flags.in
@@ -0,0 +1,3 @@
+XFS_USER_QUOTA	(1<<0)
+XFS_PROJ_QUOTA	(1<<1)
+XFS_GROUP_QUOTA	(1<<2)
diff --git a/strace/xlat/xfs_quota_flags.h b/strace/xlat/xfs_quota_flags.h
new file mode 100644
index 0000000..f635b96
--- /dev/null
+++ b/strace/xlat/xfs_quota_flags.h
@@ -0,0 +1,38 @@
+/* Generated by ./xlat/gen.sh from ./xlat/xfs_quota_flags.in; do not edit. */
+#if !(defined(XFS_QUOTA_UDQ_ACCT) || (defined(HAVE_DECL_XFS_QUOTA_UDQ_ACCT) && HAVE_DECL_XFS_QUOTA_UDQ_ACCT))
+# define XFS_QUOTA_UDQ_ACCT (1<<0)
+#endif
+#if !(defined(XFS_QUOTA_UDQ_ENFD) || (defined(HAVE_DECL_XFS_QUOTA_UDQ_ENFD) && HAVE_DECL_XFS_QUOTA_UDQ_ENFD))
+# define XFS_QUOTA_UDQ_ENFD (1<<1)
+#endif
+#if !(defined(XFS_QUOTA_GDQ_ACCT) || (defined(HAVE_DECL_XFS_QUOTA_GDQ_ACCT) && HAVE_DECL_XFS_QUOTA_GDQ_ACCT))
+# define XFS_QUOTA_GDQ_ACCT (1<<2)
+#endif
+#if !(defined(XFS_QUOTA_GDQ_ENFD) || (defined(HAVE_DECL_XFS_QUOTA_GDQ_ENFD) && HAVE_DECL_XFS_QUOTA_GDQ_ENFD))
+# define XFS_QUOTA_GDQ_ENFD (1<<3)
+#endif
+#if !(defined(XFS_QUOTA_PDQ_ACCT) || (defined(HAVE_DECL_XFS_QUOTA_PDQ_ACCT) && HAVE_DECL_XFS_QUOTA_PDQ_ACCT))
+# define XFS_QUOTA_PDQ_ACCT (1<<4)
+#endif
+#if !(defined(XFS_QUOTA_PDQ_ENFD) || (defined(HAVE_DECL_XFS_QUOTA_PDQ_ENFD) && HAVE_DECL_XFS_QUOTA_PDQ_ENFD))
+# define XFS_QUOTA_PDQ_ENFD (1<<5)
+#endif
+
+#ifdef IN_MPERS
+
+# error static const struct xlat xfs_quota_flags in mpers mode
+
+#else
+
+static
+const struct xlat xfs_quota_flags[] = {
+ XLAT(XFS_QUOTA_UDQ_ACCT),
+ XLAT(XFS_QUOTA_UDQ_ENFD),
+ XLAT(XFS_QUOTA_GDQ_ACCT),
+ XLAT(XFS_QUOTA_GDQ_ENFD),
+ XLAT(XFS_QUOTA_PDQ_ACCT),
+ XLAT(XFS_QUOTA_PDQ_ENFD),
+ XLAT_END
+};
+
+#endif /* !IN_MPERS */
diff --git a/strace/xlat/xfs_quota_flags.in b/strace/xlat/xfs_quota_flags.in
new file mode 100644
index 0000000..cf44da5
--- /dev/null
+++ b/strace/xlat/xfs_quota_flags.in
@@ -0,0 +1,6 @@
+XFS_QUOTA_UDQ_ACCT	(1<<0)
+XFS_QUOTA_UDQ_ENFD	(1<<1)
+XFS_QUOTA_GDQ_ACCT	(1<<2)
+XFS_QUOTA_GDQ_ENFD	(1<<3)
+XFS_QUOTA_PDQ_ACCT	(1<<4)
+XFS_QUOTA_PDQ_ENFD	(1<<5)
diff --git a/strace/xlate.el b/strace/xlate.el
new file mode 100644
index 0000000..d1645e7
--- /dev/null
+++ b/strace/xlate.el
@@ -0,0 +1,78 @@
+;; Copyright (c) 1993, 1994, 1995 Rick Sladkey <jrs@world.std.com>
+;; 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.
+
+;; Description: Automate the construction of strace xlat tables.
+
+;; Usage: Put point and mark around a set of definitions in a header
+;; file.  Then grab them with C-c G.  Switch to the strace source file
+;; and build the xlat table with C-c B.  Then type the name of the table.
+
+(global-set-key "\C-cG" 'grab-xlate)
+(global-set-key "\C-cB" 'build-xlate)
+
+(defvar xlate-list nil
+  "See grab-xlate and build-xlate.")
+
+(defun grab-xlate (beg end)
+  "Grab all of the defined names in the region and save them in xlate-list."
+  (interactive "r")
+  (save-excursion
+    (setq xlate-list nil)
+    (goto-char beg)
+    (beginning-of-line)
+    (while (< (point) end)
+      (and (looking-at "^#[ \t]*define[ \t]+\\([A-Za-z0-9_]+\\)[ \t]+")
+	   (setq xlate-list (cons (buffer-substring (match-beginning 1)
+						    (match-end 1))
+				  xlate-list)))
+      (forward-line)))
+  (and (fboundp 'deactivate-mark)
+       (deactivate-mark))
+  (setq xlate-list (nreverse xlate-list)))
+
+(defun build-xlate (&optional list)
+  "Build and insert an strace xlat table based on the last grab."
+  (interactive)
+  (or list
+      (setq list xlate-list))
+  (beginning-of-line)
+  (save-excursion
+    (insert "static struct xlat ?[] = {\n")
+    (while list
+      (insert "\t{ " (car list) ",\n")
+      (backward-char)
+      (move-to-column 24 'force)
+      (end-of-line)
+      (insert "\"" (car list) "\"")
+      (move-to-column 40 'force)
+      (end-of-line)
+      (insert "},")
+      (forward-line)
+      (setq list (cdr list)))
+    (insert "	{ 0,		NULL		},\n")
+    (insert "};\n")
+    (insert "\n"))
+  (search-forward "?")
+  (delete-backward-char 1))
diff --git a/strace/xmalloc.c b/strace/xmalloc.c
new file mode 100644
index 0000000..1158927
--- /dev/null
+++ b/strace/xmalloc.c
@@ -0,0 +1,87 @@
+/*
+ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * 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"
+
+void die_out_of_memory(void)
+{
+	static bool recursed = false;
+
+	if (recursed)
+		exit(1);
+	recursed = 1;
+
+	error_msg_and_die("Out of memory");
+}
+
+void *xmalloc(size_t size)
+{
+	void *p = malloc(size);
+
+	if (!p)
+		die_out_of_memory();
+
+	return p;
+}
+
+void *xcalloc(size_t nmemb, size_t size)
+{
+	void *p = calloc(nmemb, size);
+
+	if (!p)
+		die_out_of_memory();
+
+	return p;
+}
+
+#define HALF_SIZE_T	(((size_t) 1) << (sizeof(size_t) * 4))
+
+void *xreallocarray(void *ptr, size_t nmemb, size_t size)
+{
+	size_t bytes = nmemb * size;
+
+	if ((nmemb | size) >= HALF_SIZE_T &&
+	    size && bytes / size != nmemb)
+		die_out_of_memory();
+
+	void *p = realloc(ptr, bytes);
+
+	if (!p)
+		die_out_of_memory();
+
+	return p;
+}
+
+char *xstrdup(const char *str)
+{
+	char *p = strdup(str);
+
+	if (!p)
+		die_out_of_memory();
+
+	return p;
+}