Skip to contentSkip to conversation

linux-user: generate syscall_nr.sh

PATCH In review Laurent Vivier 4 participants 29 messages Mar 10, 2020 – Mar 13, 2020 Kbuild

lore
Share & tools
lore
#0 lore raw

v4 cover linux-user: generate syscall_nr.sh

This series copies the files syscall.tbl from linux v5.5 and generates the file syscall_nr.h from them.

This is done for all the QEMU targets that have a syscall.tbl in the linux source tree: mips, mips64, i386, x86_64, sparc, s390x, ppc, arm, microblaze, sh4, xtensa, m68k, hppa and alpha.

tilegx and cris are depecrated in linux (tilegx has no maintainer in QEMU)

aarch64, nios2, openrisc and riscv have no syscall.tbl in linux and files are generated manually with the help of a script from the asm-generic/unistd.h

Define do_arch_prctl() with -TARGET_ENOSYS for i386 as the syscall number is defined now.

I have also removed all syscalls in s390x/syscall_nr.h defined for !defined(TARGET_S390X).

I have added a script to copy all these files from linux and updated them at the end of the series with their latest version for today.

Two patches manage the special case for mips O32 that needs to know the number of arguments. We find them in strace sources.

v4:
generate syscall_nr.h for hppa32, not 64

v3:
Add a patch to define do_arch_prctl() for i386

v2:
fix a typo (double comma) in $(call quiet-command)
add a script to remove dependencies to syscall_nr.h in source directory

ppc, mips64:

we don't need to split syscall_nr.h as it is generated according TARGET_SYSTBL_ABI to TARGET_ABI_DIR
and generated values are incorrect according to the file name.

arm:

manage TARGET_NR_arm_sync_file_range

Once the syscall_nr.h are built in the build directory, the following script allows to compare them with the original one (first argument is the path to build directory), it must be run from the source directory:

cat > check_syscall_nr.sh <<EOF
BUILD="$1"

ARCHS="i386 alpha arm hppa i386 m68k microblaze s390x sh4 sparc sparc64 xtensa ppc"

syscall_nr_diff()

{
        arch=$1
        target=$2
        syscall_nr=linux-user/$arch/syscall_nr.h
        offset=$3
        REFERENCE=$(git log -1 --format=format:%h -- $syscall_nr)^
        if [ "$offset" = "" ] ; then
                git show $REFERENCE:$syscall_nr | \
                        sed 's/[[:blank:]]\/\*[^*]*\*\///' | \
                        sed 's/(\([^)]*\))/\1/'  > /tmp/old
        else
                git show $REFERENCE:$syscall_nr | \
                        sed 's/[[:blank:]]\/\*[^*]*\*\///' | \
                        sed "s/TARGET_NR_Linux/$offset/" > /tmp/old
        fi
        diff -wu --color=always /tmp/old \
                                $BUILD/$target/$syscall_nr | less -R
}

for arch in $ARCHS ; do
syscall_nr_diff $arch $arch-linux-user
done

syscall_nr_diff ppc ppc64-linux-user

syscall_nr_diff mips mips-linux-user 4000
syscall_nr_diff mips64 mips64-linux-user 5000
syscall_nr_diff mips64 mipsn32-linux-user 6000
EOF

Laurent Vivier (21):
linux-user: introduce parameters to generate syscall_nr.h linux-user,alpha: add syscall table generation support linux-user,hppa: add syscall table generation support linux-user,m68k: add syscall table generation support linux-user,xtensa: add syscall table generation support linux-user,sh4: add syscall table generation support linux-user,microblaze: add syscall table generation support linux-user,arm: add syscall table generation support linux-user,ppc: add syscall table generation support linux-user,s390x: remove syscall definitions for !TARGET_S390X linux-user,s390x: add syscall table generation support linux-user,sparc,sparc64: add syscall table generation support linux-user,x86_64,i386: cleanup TARGET_NR_arch_prctl linux-user,i386: add syscall table generation support linux-user,x86_64: add syscall table generation support linux-user,mips: add syscall table generation support linux-user,mips64: add syscall table generation support linux-user,scripts: add a script to update syscall.tbl
linux-user: update syscall.tbl from linux 0bf999f9c5e7 linux-user,mips: move content of mips_syscall_args linux-user,mips: update syscall-args-o32.c.inc

 MAINTAINERS                            |   1 +
 Makefile.target                        |   3 +-
 configure                              |  35 ++
 linux-user/Makefile.objs               |  19 +-
 linux-user/alpha/Makefile.objs         |   5 +
 linux-user/alpha/syscall.tbl           | 479 ++++++++++++++++
 linux-user/alpha/syscall_nr.h          | 492 -----------------
 linux-user/alpha/syscallhdr.sh         |  32 ++
 linux-user/arm/Makefile.objs           |   8 +
 linux-user/arm/syscall.tbl             | 453 +++++++++++++++
 linux-user/arm/syscall_nr.h            | 447 ---------------
 linux-user/arm/syscallhdr.sh           |  31 ++
 linux-user/hppa/Makefile.objs          |   5 +
 linux-user/hppa/syscall.tbl            | 437 +++++++++++++++
 linux-user/hppa/syscall_nr.h           | 358 ------------
 linux-user/hppa/syscallhdr.sh          |  32 ++
 linux-user/i386/Makefile.objs          |   5 +
 linux-user/i386/syscall_32.tbl         | 444 +++++++++++++++
 linux-user/i386/syscall_nr.h           | 387 -------------
 linux-user/i386/syscallhdr.sh          |  28 +
 linux-user/i386/target_cpu.h           |   4 +-
 linux-user/m68k/Makefile.objs          |   5 +
 linux-user/m68k/syscall.tbl            | 439 +++++++++++++++
 linux-user/m68k/syscall_nr.h           | 434 ---------------
 linux-user/m68k/syscallhdr.sh          |  32 ++
 linux-user/microblaze/Makefile.objs    |   5 +
 linux-user/microblaze/syscall.tbl      | 445 +++++++++++++++
 linux-user/microblaze/syscall_nr.h     | 442 ---------------
 linux-user/microblaze/syscallhdr.sh    |  32 ++
 linux-user/mips/Makefile.objs          |   5 +
 linux-user/mips/cpu_loop.c             | 440 +--------------
 linux-user/mips/syscall-args-o32.c.inc | 436 +++++++++++++++
 linux-user/mips/syscall_nr.h           | 425 ---------------
 linux-user/mips/syscall_o32.tbl        | 427 +++++++++++++++
 linux-user/mips/syscallhdr.sh          |  36 ++
 linux-user/mips64/Makefile.objs        |  12 +
 linux-user/mips64/syscall_n32.tbl      | 378 +++++++++++++
 linux-user/mips64/syscall_n64.tbl      | 354 ++++++++++++
 linux-user/mips64/syscall_nr.h         | 725 -------------------------
 linux-user/mips64/syscallhdr.sh        |  33 ++
 linux-user/ppc/Makefile.objs           |   6 +
 linux-user/ppc/signal.c                |   2 +-
 linux-user/ppc/syscall.tbl             | 521 ++++++++++++++++++
 linux-user/ppc/syscall_nr.h            | 402 --------------
 linux-user/ppc/syscallhdr.sh           |  34 ++
 linux-user/s390x/Makefile.objs         |   5 +
 linux-user/s390x/syscall.tbl           | 442 +++++++++++++++
 linux-user/s390x/syscall_nr.h          | 398 --------------
 linux-user/s390x/syscallhdr.sh         |  32 ++
 linux-user/sh4/Makefile.objs           |   5 +
 linux-user/sh4/syscall.tbl             | 442 +++++++++++++++
 linux-user/sh4/syscall_nr.h            | 441 ---------------
 linux-user/sh4/syscallhdr.sh           |  32 ++
 linux-user/sparc/Makefile.objs         |   5 +
 linux-user/sparc/syscall.tbl           | 485 +++++++++++++++++
 linux-user/sparc/syscall_nr.h          | 363 -------------
 linux-user/sparc/syscallhdr.sh         |  32 ++
 linux-user/sparc64/Makefile.objs       |   5 +
 linux-user/sparc64/syscall.tbl         | 485 +++++++++++++++++
 linux-user/sparc64/syscall_nr.h        | 366 -------------
 linux-user/sparc64/syscallhdr.sh       |  32 ++
 linux-user/syscall.c                   |  25 +-
 linux-user/x86_64/Makefile.objs        |   5 +
 linux-user/x86_64/syscall_64.tbl       | 404 ++++++++++++++
 linux-user/x86_64/syscall_nr.h         | 356 ------------
 linux-user/x86_64/syscallhdr.sh        |  28 +
 linux-user/xtensa/Makefile.objs        |   5 +
 linux-user/xtensa/syscall.tbl          | 410 ++++++++++++++
 linux-user/xtensa/syscall_nr.h         | 469 ----------------
 linux-user/xtensa/syscallhdr.sh        |  32 ++
 scripts/update-mips-syscall-args.sh    |  57 ++
 scripts/update-syscalltbl.sh           |  49 ++
 72 files changed, 8227 insertions(+), 6958 deletions(-)
 create mode 100644 linux-user/alpha/Makefile.objs
 create mode 100644 linux-user/alpha/syscall.tbl
 delete mode 100644 linux-user/alpha/syscall_nr.h
 create mode 100644 linux-user/alpha/syscallhdr.sh
 create mode 100644 linux-user/arm/Makefile.objs
 create mode 100644 linux-user/arm/syscall.tbl
 delete mode 100644 linux-user/arm/syscall_nr.h
 create mode 100644 linux-user/arm/syscallhdr.sh
 create mode 100644 linux-user/hppa/Makefile.objs
 create mode 100644 linux-user/hppa/syscall.tbl
 delete mode 100644 linux-user/hppa/syscall_nr.h
 create mode 100644 linux-user/hppa/syscallhdr.sh
 create mode 100644 linux-user/i386/Makefile.objs
 create mode 100644 linux-user/i386/syscall_32.tbl
 delete mode 100644 linux-user/i386/syscall_nr.h
 create mode 100644 linux-user/i386/syscallhdr.sh
 create mode 100644 linux-user/m68k/Makefile.objs
 create mode 100644 linux-user/m68k/syscall.tbl
 delete mode 100644 linux-user/m68k/syscall_nr.h
 create mode 100644 linux-user/m68k/syscallhdr.sh
 create mode 100644 linux-user/microblaze/Makefile.objs
 create mode 100644 linux-user/microblaze/syscall.tbl
 delete mode 100644 linux-user/microblaze/syscall_nr.h
 create mode 100644 linux-user/microblaze/syscallhdr.sh
 create mode 100644 linux-user/mips/Makefile.objs
 create mode 100644 linux-user/mips/syscall-args-o32.c.inc
 delete mode 100644 linux-user/mips/syscall_nr.h
 create mode 100644 linux-user/mips/syscall_o32.tbl
 create mode 100644 linux-user/mips/syscallhdr.sh
 create mode 100644 linux-user/mips64/Makefile.objs
 create mode 100644 linux-user/mips64/syscall_n32.tbl
 create mode 100644 linux-user/mips64/syscall_n64.tbl
 delete mode 100644 linux-user/mips64/syscall_nr.h
 create mode 100644 linux-user/mips64/syscallhdr.sh
 create mode 100644 linux-user/ppc/Makefile.objs
 create mode 100644 linux-user/ppc/syscall.tbl
 delete mode 100644 linux-user/ppc/syscall_nr.h
 create mode 100644 linux-user/ppc/syscallhdr.sh
 create mode 100644 linux-user/s390x/Makefile.objs
 create mode 100644 linux-user/s390x/syscall.tbl
 delete mode 100644 linux-user/s390x/syscall_nr.h
 create mode 100755 linux-user/s390x/syscallhdr.sh
 create mode 100644 linux-user/sh4/Makefile.objs
 create mode 100644 linux-user/sh4/syscall.tbl
 delete mode 100644 linux-user/sh4/syscall_nr.h
 create mode 100644 linux-user/sh4/syscallhdr.sh
 create mode 100644 linux-user/sparc/Makefile.objs
 create mode 100644 linux-user/sparc/syscall.tbl
 delete mode 100644 linux-user/sparc/syscall_nr.h
 create mode 100644 linux-user/sparc/syscallhdr.sh
 create mode 100644 linux-user/sparc64/Makefile.objs
 create mode 100644 linux-user/sparc64/syscall.tbl
 delete mode 100644 linux-user/sparc64/syscall_nr.h
 create mode 100644 linux-user/sparc64/syscallhdr.sh
 create mode 100644 linux-user/x86_64/Makefile.objs
 create mode 100644 linux-user/x86_64/syscall_64.tbl
 delete mode 100644 linux-user/x86_64/syscall_nr.h
 create mode 100644 linux-user/x86_64/syscallhdr.sh
 create mode 100644 linux-user/xtensa/Makefile.objs
 create mode 100644 linux-user/xtensa/syscall.tbl
 delete mode 100644 linux-user/xtensa/syscall_nr.h
 create mode 100644 linux-user/xtensa/syscallhdr.sh
 create mode 100755 scripts/update-mips-syscall-args.sh
 create mode 100755 scripts/update-syscalltbl.sh
Signature · 1 line
2.24.1
#1 lore raw

PATCH v4 1/21 linux-user: introduce parameters to generate syscall_nr.h

This will be used when we'll import syscall.tbl from the kernel

Add a script to remove all the dependencies to syscall_nr.h that point to source directory and not to the build directory. The list of arch will be update while the generated files are added.

---
 Makefile.target |  3 ++-
 configure       | 14 ++++++++++++++
 2 files changed, 16 insertions(+), 1 deletion(-)
Makefile.target +2 -1
index 2d43dc586a10..cb3a6fa5e704 100644
@@ -128,7 +128,8 @@ ifdef CONFIG_LINUX_USER
 
 QEMU_CFLAGS+=-I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR) \
              -I$(SRC_PATH)/linux-user/host/$(ARCH) \
-             -I$(SRC_PATH)/linux-user
+             -I$(SRC_PATH)/linux-user \
+             -Ilinux-user/$(TARGET_ABI_DIR)
 
 obj-y += linux-user/
 obj-y += gdbstub.o thunk.o
configure +14 -0
index cbf864bff1be..39e55a1ecf06 100755
@@ -1887,6 +1887,17 @@ fi
 # Remove old dependency files to make sure that they get properly regenerated
 rm -f */config-devices.mak.d
 
+# Remove syscall_nr.h to be sure they will be regenerated in the build
+# directory, not in the source directory
+for arch in ; do
+    # remove the file if it has been generated in the source directory
+    rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
+    # remove the dependency files
+    find . -name "*.d" \
+           -exec grep -q "${source_path}/linux-user/${arch}/syscall_nr.h" {} \; \
+           -exec rm {} \;
+done
+
 if test -z "$python"
 then
     error_exit "Python not found. Use --python=/path/to/python"
@@ -7931,6 +7942,9 @@ echo "TARGET_ABI_DIR=$TARGET_ABI_DIR" >> $config_target_mak
 if [ "$HOST_VARIANT_DIR" != "" ]; then
     echo "HOST_VARIANT_DIR=$HOST_VARIANT_DIR" >> $config_target_mak
 fi
+if [ "$TARGET_SYSTBL_ABI" != "" ]; then
+    echo "TARGET_SYSTBL_ABI=$TARGET_SYSTBL_ABI" >> $config_target_mak
+fi
 
 if supported_xen_target $target; then
     echo "CONFIG_XEN=y" >> $config_target_mak
Signature · 1 line
2.24.1
#2 lore raw

PATCH v4 2/21 linux-user, alpha: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/alpha/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                      |   3 +-
 linux-user/Makefile.objs       |   2 +
 linux-user/alpha/Makefile.objs |   5 +
 linux-user/alpha/syscall.tbl   | 479 ++++++++++++++++++++++++++++++++
 linux-user/alpha/syscall_nr.h  | 492 ---------------------------------
 linux-user/alpha/syscallhdr.sh |  32 +++
 6 files changed, 520 insertions(+), 493 deletions(-)
 create mode 100644 linux-user/alpha/Makefile.objs
 create mode 100644 linux-user/alpha/syscall.tbl
 delete mode 100644 linux-user/alpha/syscall_nr.h
 create mode 100644 linux-user/alpha/syscallhdr.sh
configure +2 -1
index 39e55a1ecf06..5a024d249008 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in ; do
+for arch in alpha ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7795,6 +7795,7 @@ case "$target_name" in
   ;;
   alpha)
     mttcg="yes"
+    TARGET_SYSTBL_ABI=common
   ;;
   arm|armeb)
     TARGET_ARCH=arm
linux-user/Makefile.objs +2 -0
index d2f33beb5e52..a1afb4d21f9f 100644
@@ -8,3 +8,5 @@ obj-$(TARGET_I386) += vm86.o
 obj-$(TARGET_ARM) += arm/nwfpe/
 obj-$(TARGET_ARM) += arm/semihost.o
 obj-$(TARGET_AARCH64) += arm/semihost.o
+
+obj-$(TARGET_ALPHA) += alpha/
linux-user/alpha/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..d6397a70abb2
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/alpha/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/alpha/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/alpha/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/alpha/syscall.tbl new file +479 -0

479 lines not on this page · raw message

linux-user/alpha/syscall_nr.h deleted +0 -492

492 lines not on this page · raw message

linux-user/alpha/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..55cafe6abf99
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_ALPHA_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#3 lore raw

PATCH v4 3/21 linux-user, hppa: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/parisc/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                     |   3 +-
 linux-user/Makefile.objs      |   1 +
 linux-user/hppa/Makefile.objs |   5 +
 linux-user/hppa/syscall.tbl   | 435 ++++++++++++++++++++++++++++++++++
 linux-user/hppa/syscall_nr.h  | 358 ----------------------------
 linux-user/hppa/syscallhdr.sh |  32 +++
 6 files changed, 475 insertions(+), 359 deletions(-)
 create mode 100644 linux-user/hppa/Makefile.objs
 create mode 100644 linux-user/hppa/syscall.tbl
 delete mode 100644 linux-user/hppa/syscall_nr.h
 create mode 100644 linux-user/hppa/syscallhdr.sh
configure +2 -1
index 5a024d249008..d96b767947af 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha ; do
+for arch in alpha hppa ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7814,6 +7814,7 @@ case "$target_name" in
   ;;
   hppa)
     mttcg="yes"
+    TARGET_SYSTBL_ABI=common,32
   ;;
   lm32)
   ;;
linux-user/Makefile.objs +1 -0
index a1afb4d21f9f..9f8e001241d5 100644
@@ -10,3 +10,4 @@ obj-$(TARGET_ARM) += arm/semihost.o
 obj-$(TARGET_AARCH64) += arm/semihost.o
 
 obj-$(TARGET_ALPHA) += alpha/
+obj-$(TARGET_HPPA) += hppa/
linux-user/hppa/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..f8368be6f314
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/hppa/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/hppa/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/hppa/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/hppa/syscall.tbl new file +435 -0

435 lines not on this page · raw message

linux-user/hppa/syscall_nr.h deleted +0 -358

358 lines not on this page · raw message

linux-user/hppa/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..ac91a9576213
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_HPPA_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry compat ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
Reviewed-by on v4 3/21
#4 lore raw

Re: [PATCH v4 03/21] linux-user,hppa: add syscall table generation support

Quoted 5 lines · Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/parisc/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

Quoted 12 lines
---
 configure                     |   3 +-
 linux-user/Makefile.objs      |   1 +
 linux-user/hppa/Makefile.objs |   5 +
 linux-user/hppa/syscall.tbl   | 435 ++++++++++++++++++++++++++++++++++
 linux-user/hppa/syscall_nr.h  | 358 ----------------------------
 linux-user/hppa/syscallhdr.sh |  32 +++
 6 files changed, 475 insertions(+), 359 deletions(-)
 create mode 100644 linux-user/hppa/Makefile.objs
 create mode 100644 linux-user/hppa/syscall.tbl
 delete mode 100644 linux-user/hppa/syscall_nr.h
 create mode 100644 linux-user/hppa/syscallhdr.sh

r~

#5 lore raw

PATCH v4 4/21 linux-user, m68k: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/m68k/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                     |   3 +-
 linux-user/Makefile.objs      |   1 +
 linux-user/m68k/Makefile.objs |   5 +
 linux-user/m68k/syscall.tbl   | 437 ++++++++++++++++++++++++++++++++++
 linux-user/m68k/syscall_nr.h  | 434 ---------------------------------
 linux-user/m68k/syscallhdr.sh |  32 +++
 6 files changed, 477 insertions(+), 435 deletions(-)
 create mode 100644 linux-user/m68k/Makefile.objs
 create mode 100644 linux-user/m68k/syscall.tbl
 delete mode 100644 linux-user/m68k/syscall_nr.h
 create mode 100644 linux-user/m68k/syscallhdr.sh
configure +2 -1
index d96b767947af..480e1d9af5f1 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa ; do
+for arch in alpha hppa m68k ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7821,6 +7821,7 @@ case "$target_name" in
   m68k)
     bflt="yes"
     gdb_xml_files="cf-core.xml cf-fp.xml m68k-fp.xml"
+    TARGET_SYSTBL_ABI=common
   ;;
   microblaze|microblazeel)
     TARGET_ARCH=microblaze
linux-user/Makefile.objs +1 -0
index 9f8e001241d5..ac74b23683cf 100644
@@ -11,3 +11,4 @@ obj-$(TARGET_AARCH64) += arm/semihost.o
 
 obj-$(TARGET_ALPHA) += alpha/
 obj-$(TARGET_HPPA) += hppa/
+obj-$(TARGET_M68K) += m68k/
linux-user/m68k/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..961bd05c237f
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/m68k/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/m68k/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/m68k/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/m68k/syscall.tbl new file +437 -0

437 lines not on this page · raw message

linux-user/m68k/syscall_nr.h deleted +0 -434

434 lines not on this page · raw message

linux-user/m68k/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..eeb4d01d34d3
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_M68K_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */\n" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#6 lore raw

PATCH v4 5/21 linux-user, xtensa: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/xtensa/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                       |   3 +-
 linux-user/Makefile.objs        |   1 +
 linux-user/xtensa/Makefile.objs |   5 +
 linux-user/xtensa/syscall.tbl   | 408 +++++++++++++++++++++++++++
 linux-user/xtensa/syscall_nr.h  | 469 --------------------------------
 linux-user/xtensa/syscallhdr.sh |  32 +++
 6 files changed, 448 insertions(+), 470 deletions(-)
 create mode 100644 linux-user/xtensa/Makefile.objs
 create mode 100644 linux-user/xtensa/syscall.tbl
 delete mode 100644 linux-user/xtensa/syscall_nr.h
 create mode 100644 linux-user/xtensa/syscallhdr.sh
configure +2 -1
index 480e1d9af5f1..3e72343b2aa9 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k ; do
+for arch in alpha hppa m68k xtensa ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7916,6 +7916,7 @@ case "$target_name" in
   ;;
   xtensa|xtensaeb)
     TARGET_ARCH=xtensa
+    TARGET_SYSTBL_ABI=common
     bflt="yes"
     mttcg="yes"
   ;;
linux-user/Makefile.objs +1 -0
index ac74b23683cf..13b821baf752 100644
@@ -12,3 +12,4 @@ obj-$(TARGET_AARCH64) += arm/semihost.o
 obj-$(TARGET_ALPHA) += alpha/
 obj-$(TARGET_HPPA) += hppa/
 obj-$(TARGET_M68K) += m68k/
+obj-$(TARGET_XTENSA) += xtensa/
linux-user/xtensa/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..d4be1b745544
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/xtensa/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/xtensa/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/xtensa/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/xtensa/syscall.tbl new file +408 -0

408 lines not on this page · raw message

linux-user/xtensa/syscall_nr.h deleted +0 -469

469 lines not on this page · raw message

linux-user/xtensa/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..eef0644c9431
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_XTENSA_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#7 lore raw

PATCH v4 6/21 linux-user, sh4: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/sh/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                    |   3 +-
 linux-user/Makefile.objs     |   1 +
 linux-user/sh4/Makefile.objs |   5 +
 linux-user/sh4/syscall.tbl   | 440 ++++++++++++++++++++++++++++++++++
 linux-user/sh4/syscall_nr.h  | 441 -----------------------------------
 linux-user/sh4/syscallhdr.sh |  32 +++
 6 files changed, 480 insertions(+), 442 deletions(-)
 create mode 100644 linux-user/sh4/Makefile.objs
 create mode 100644 linux-user/sh4/syscall.tbl
 delete mode 100644 linux-user/sh4/syscall_nr.h
 create mode 100644 linux-user/sh4/syscallhdr.sh
configure +2 -1
index 3e72343b2aa9..62f5bb601b75 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k xtensa ; do
+for arch in alpha hppa m68k xtensa sh4 ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7891,6 +7891,7 @@ case "$target_name" in
   ;;
   sh4|sh4eb)
     TARGET_ARCH=sh4
+    TARGET_SYSTBL_ABI=common
     bflt="yes"
   ;;
   sparc)
linux-user/Makefile.objs +1 -0
index 13b821baf752..d31f30d75851 100644
@@ -12,4 +12,5 @@ obj-$(TARGET_AARCH64) += arm/semihost.o
 obj-$(TARGET_ALPHA) += alpha/
 obj-$(TARGET_HPPA) += hppa/
 obj-$(TARGET_M68K) += m68k/
+obj-$(TARGET_SH4) += sh4/
 obj-$(TARGET_XTENSA) += xtensa/
linux-user/sh4/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..83fc939570d5
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/sh4/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/sh4/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/sh4/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/sh4/syscall.tbl new file +440 -0

440 lines not on this page · raw message

linux-user/sh4/syscall_nr.h deleted +0 -441

441 lines not on this page · raw message

linux-user/sh4/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..080790556ad0
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_SH4_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#8 lore raw

PATCH v4 7/21 linux-user, microblaze: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/microblaze/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                           |   3 +-
 linux-user/Makefile.objs            |   1 +
 linux-user/microblaze/Makefile.objs |   5 +
 linux-user/microblaze/syscall.tbl   | 443 ++++++++++++++++++++++++++++
 linux-user/microblaze/syscall_nr.h  | 442 ---------------------------
 linux-user/microblaze/syscallhdr.sh |  32 ++
 6 files changed, 483 insertions(+), 443 deletions(-)
 create mode 100644 linux-user/microblaze/Makefile.objs
 create mode 100644 linux-user/microblaze/syscall.tbl
 delete mode 100644 linux-user/microblaze/syscall_nr.h
 create mode 100644 linux-user/microblaze/syscallhdr.sh
configure +2 -1
index 62f5bb601b75..720bb5a96c62 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k xtensa sh4 ; do
+for arch in alpha hppa m68k xtensa sh4 microblaze ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7825,6 +7825,7 @@ case "$target_name" in
   ;;
   microblaze|microblazeel)
     TARGET_ARCH=microblaze
+    TARGET_SYSTBL_ABI=common
     bflt="yes"
     echo "TARGET_ABI32=y" >> $config_target_mak
   ;;
linux-user/Makefile.objs +1 -0
index d31f30d75851..5a26281e8867 100644
@@ -12,5 +12,6 @@ obj-$(TARGET_AARCH64) += arm/semihost.o
 obj-$(TARGET_ALPHA) += alpha/
 obj-$(TARGET_HPPA) += hppa/
 obj-$(TARGET_M68K) += m68k/
+obj-$(TARGET_MICROBLAZE) += microblaze/
 obj-$(TARGET_SH4) += sh4/
 obj-$(TARGET_XTENSA) += xtensa/
linux-user/microblaze/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..bb8b318dda7f
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/microblaze/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/microblaze/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/microblaze/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/microblaze/syscall.tbl new file +443 -0

443 lines not on this page · raw message

linux-user/microblaze/syscall_nr.h deleted +0 -442

442 lines not on this page · raw message

linux-user/microblaze/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..f55dce8a6248
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_MICROBLAZE_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#9 lore raw

PATCH v4 8/21 linux-user, arm: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/arm/tools/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

Update syscall.c to manage TARGET_NR_arm_sync_file_range as it has replaced TARGET_NR_sync_file_range2

Move existing stuff from linux-user/Makefile.objs to linux-user/arm/Makefile.objs

---
 configure                    |   3 +-
 linux-user/Makefile.objs     |   3 +-
 linux-user/arm/Makefile.objs |   8 +
 linux-user/arm/syscall.tbl   | 451 +++++++++++++++++++++++++++++++++++
 linux-user/arm/syscall_nr.h  | 447 ----------------------------------
 linux-user/arm/syscallhdr.sh |  31 +++
 linux-user/syscall.c         |   6 +
 7 files changed, 499 insertions(+), 450 deletions(-)
 create mode 100644 linux-user/arm/Makefile.objs
 create mode 100644 linux-user/arm/syscall.tbl
 delete mode 100644 linux-user/arm/syscall_nr.h
 create mode 100644 linux-user/arm/syscallhdr.sh
configure +2 -1
index 720bb5a96c62..5ed5e37df897 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k xtensa sh4 microblaze ; do
+for arch in alpha hppa m68k xtensa sh4 microblaze arm ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7799,6 +7799,7 @@ case "$target_name" in
   ;;
   arm|armeb)
     TARGET_ARCH=arm
+    TARGET_SYSTBL_ABI=common,oabi
     bflt="yes"
     mttcg="yes"
     gdb_xml_files="arm-core.xml arm-vfp.xml arm-vfp3.xml arm-neon.xml"
linux-user/Makefile.objs +1 -2
index 5a26281e8867..bc12e38291bc 100644
@@ -5,11 +5,10 @@ obj-y = main.o syscall.o strace.o mmap.o signal.o \
 
 obj-$(TARGET_HAS_BFLT) += flatload.o
 obj-$(TARGET_I386) += vm86.o
-obj-$(TARGET_ARM) += arm/nwfpe/
-obj-$(TARGET_ARM) += arm/semihost.o
 obj-$(TARGET_AARCH64) += arm/semihost.o
 
 obj-$(TARGET_ALPHA) += alpha/
+obj-$(TARGET_ARM) += arm/
 obj-$(TARGET_HPPA) += hppa/
 obj-$(TARGET_M68K) += m68k/
 obj-$(TARGET_MICROBLAZE) += microblaze/
linux-user/arm/Makefile.objs new file +8 -0
new file mode 100644
index 000000000000..c7eb94dcba8e
@@ -0,0 +1,8 @@
+obj-$(TARGET_ARM) += nwfpe/
+obj-$(TARGET_ARM) += semihost.o
+
+generated-files-y += linux-user/arm/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/arm/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/arm/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/arm/syscall.tbl new file +451 -0

451 lines not on this page · raw message

linux-user/arm/syscall_nr.h deleted +0 -447

447 lines not on this page · raw message

linux-user/arm/syscallhdr.sh new file +31 -0
new file mode 100644
index 000000000000..4c952b2cfb20
@@ -0,0 +1,31 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_ARM_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+if echo $out | grep -q uapi; then
+    fileguard="_UAPI$fileguard"
+fi
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    echo "#ifndef ${fileguard}"
+    echo "#define ${fileguard} 1"
+    echo ""
+
+    while read nr abi name entry ; do
+    if [ -z "$offset" ]; then
+        echo "#define TARGET_NR_${prefix}${name} $nr"
+    else
+        echo "#define TARGET_NR_${prefix}${name} ($offset + $nr)"
+        fi
+    done
+
+    echo ""
+    echo "#endif /* ${fileguard} */"
+) > "$out"
linux-user/syscall.c +6 -0
index 8d27d1080752..f50a16070815 100644
@@ -11727,8 +11727,14 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
 #endif
         return ret;
 #endif
+#if defined(TARGET_NR_sync_file_range2) || \
+    defined(TARGET_NR_arm_sync_file_range)
 #if defined(TARGET_NR_sync_file_range2)
     case TARGET_NR_sync_file_range2:
+#endif
+#if defined(TARGET_NR_arm_sync_file_range)
+    case TARGET_NR_arm_sync_file_range:
+#endif
         /* This is like sync_file_range but the arguments are reordered */
 #if TARGET_ABI_BITS == 32
         ret = get_errno(sync_file_range(arg1, target_offset64(arg3, arg4),
Signature · 1 line
2.24.1
Reviewed-by on v4 8/21
#10 lore raw

Re: [PATCH v4 08/21] linux-user,arm: add syscall table generation support

Quoted 11 lines · Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/arm/tools/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

Update syscall.c to manage TARGET_NR_arm_sync_file_range as it has replaced TARGET_NR_sync_file_range2

Move existing stuff from linux-user/Makefile.objs to linux-user/arm/Makefile.objs

Quoted 13 lines
---
 configure                    |   3 +-
 linux-user/Makefile.objs     |   3 +-
 linux-user/arm/Makefile.objs |   8 +
 linux-user/arm/syscall.tbl   | 451 +++++++++++++++++++++++++++++++++++
 linux-user/arm/syscall_nr.h  | 447 ----------------------------------
 linux-user/arm/syscallhdr.sh |  31 +++
 linux-user/syscall.c         |   6 +
 7 files changed, 499 insertions(+), 450 deletions(-)
 create mode 100644 linux-user/arm/Makefile.objs
 create mode 100644 linux-user/arm/syscall.tbl
 delete mode 100644 linux-user/arm/syscall_nr.h
 create mode 100644 linux-user/arm/syscallhdr.sh

r~

#11 lore raw

PATCH v4 9/21 linux-user, ppc: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/ppc/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h
and to not generate the entry if entry point is sys_ni_syscall.

Fix ppc/signal.c to define do_sigreturn() for TARGET_ABI32.

---
 configure                    |   6 +-
 linux-user/Makefile.objs     |   2 +
 linux-user/ppc/Makefile.objs |   6 +
 linux-user/ppc/signal.c      |   2 +-
 linux-user/ppc/syscall.tbl   | 519 +++++++++++++++++++++++++++++++++++
 linux-user/ppc/syscall_nr.h  | 402 ---------------------------
 linux-user/ppc/syscallhdr.sh |  34 +++
 7 files changed, 567 insertions(+), 404 deletions(-)
 create mode 100644 linux-user/ppc/Makefile.objs
 create mode 100644 linux-user/ppc/syscall.tbl
 delete mode 100644 linux-user/ppc/syscall_nr.h
 create mode 100644 linux-user/ppc/syscallhdr.sh
configure +5 -1
index 5ed5e37df897..f2500823ba52 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k xtensa sh4 microblaze arm ; do
+for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7858,10 +7858,12 @@ case "$target_name" in
   ;;
   ppc)
     gdb_xml_files="power-core.xml power-fpu.xml power-altivec.xml power-spe.xml"
+    TARGET_SYSTBL_ABI=common,nospu,32
   ;;
   ppc64)
     TARGET_BASE_ARCH=ppc
     TARGET_ABI_DIR=ppc
+    TARGET_SYSTBL_ABI=common,nospu,64
     mttcg=yes
     gdb_xml_files="power64-core.xml power-fpu.xml power-altivec.xml power-spe.xml power-vsx.xml"
   ;;
@@ -7869,6 +7871,7 @@ case "$target_name" in
     TARGET_ARCH=ppc64
     TARGET_BASE_ARCH=ppc
     TARGET_ABI_DIR=ppc
+    TARGET_SYSTBL_ABI=common,nospu,64
     mttcg=yes
     gdb_xml_files="power64-core.xml power-fpu.xml power-altivec.xml power-spe.xml power-vsx.xml"
   ;;
@@ -7876,6 +7879,7 @@ case "$target_name" in
     TARGET_ARCH=ppc64
     TARGET_BASE_ARCH=ppc
     TARGET_ABI_DIR=ppc
+    TARGET_SYSTBL_ABI=common,nospu,32
     echo "TARGET_ABI32=y" >> $config_target_mak
     gdb_xml_files="power64-core.xml power-fpu.xml power-altivec.xml power-spe.xml power-vsx.xml"
   ;;
linux-user/Makefile.objs +2 -0
index bc12e38291bc..8b00dad687b2 100644
@@ -12,5 +12,7 @@ obj-$(TARGET_ARM) += arm/
 obj-$(TARGET_HPPA) += hppa/
 obj-$(TARGET_M68K) += m68k/
 obj-$(TARGET_MICROBLAZE) += microblaze/
+obj-$(TARGET_PPC) += ppc/
+obj-$(TARGET_PPC64) += ppc/
 obj-$(TARGET_SH4) += sh4/
 obj-$(TARGET_XTENSA) += xtensa/
linux-user/ppc/Makefile.objs new file +6 -0
new file mode 100644
index 000000000000..be92e67eb160
@@ -0,0 +1,6 @@
+generated-files-y += linux-user/$(TARGET_ABI_DIR)/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)/syscallhdr.sh
+
+%/syscall_nr.h: $(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/ppc/signal.c +1 -1
index 5b82af6cb623..0c4e7ba54caf 100644
@@ -588,7 +588,7 @@ sigsegv:
 
 }
 
-#if !defined(TARGET_PPC64)
+#if !defined(TARGET_PPC64) || defined(TARGET_ABI32)
 long do_sigreturn(CPUPPCState *env)
 {
     struct target_sigcontext *sc = NULL;
linux-user/ppc/syscall.tbl new file +519 -0

519 lines not on this page · raw message

linux-user/ppc/syscall_nr.h deleted +0 -402

402 lines not on this page · raw message

linux-user/ppc/syscallhdr.sh new file +34 -0
new file mode 100644
index 000000000000..6c44e0eaad20
@@ -0,0 +1,34 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_PPC_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    while read nr abi name entry compat ; do
+        if [ "$entry" = "sys_ni_syscall" ] ; then
+            continue
+        fi
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+    printf "\n"
+) > "$out"
Signature · 1 line
2.24.1
#12 lore raw

PATCH v4 10/21 linux-user, s390x: remove syscall definitions for !TARGET_S390X

In reply to Laurent Vivier

We don't support other 32bit architecture.
Update file to comply with coding style (TAB).

---
 linux-user/s390x/syscall_nr.h | 313 +++++++++++++---------------------
 1 file changed, 123 insertions(+), 190 deletions(-)
linux-user/s390x/syscall_nr.h +123 -190
index b1553a0810c8..261da1b0c30e 100644
@@ -11,7 +11,7 @@
 #define TARGET_NR_write                4
 #define TARGET_NR_open                 5
 #define TARGET_NR_close                6
-#define TARGET_NR_restart_syscall	  7
+#define TARGET_NR_restart_syscall         7
 #define TARGET_NR_creat                8
 #define TARGET_NR_link                 9
 #define TARGET_NR_unlink              10
@@ -108,6 +108,7 @@
 #define TARGET_NR_personality        136
 #define TARGET_NR_afs_syscall        137 /* Syscall for Andrew File System */
 #define TARGET_NR_getdents           141
+#define TARGET_NR_select                142
 #define TARGET_NR_flock              143
 #define TARGET_NR_msync              144
 #define TARGET_NR_readv              145
@@ -147,116 +148,137 @@
 #define TARGET_NR_capset             185
 #define TARGET_NR_sigaltstack        186
 #define TARGET_NR_sendfile           187
-#define TARGET_NR_getpmsg		188
-#define TARGET_NR_putpmsg		189
-#define TARGET_NR_vfork		190
+#define TARGET_NR_getpmsg               188
+#define TARGET_NR_putpmsg               189
+#define TARGET_NR_vfork         190
+#define TARGET_NR_getrlimit             191     /* SuS compliant getrlimit */
+#define TARGET_NR_lchown                198
+#define TARGET_NR_getuid                199
+#define TARGET_NR_getgid                200
+#define TARGET_NR_geteuid               201
+#define TARGET_NR_getegid               202
+#define TARGET_NR_setreuid              203
+#define TARGET_NR_setregid              204
+#define TARGET_NR_getgroups     205
+#define TARGET_NR_setgroups     206
+#define TARGET_NR_fchown                207
+#define TARGET_NR_setresuid     208
+#define TARGET_NR_getresuid     209
+#define TARGET_NR_setresgid     210
+#define TARGET_NR_getresgid     211
+#define TARGET_NR_chown                 212
+#define TARGET_NR_setuid                213
+#define TARGET_NR_setgid                214
+#define TARGET_NR_setfsuid              215
+#define TARGET_NR_setfsgid              216
 #define TARGET_NR_pivot_root         217
 #define TARGET_NR_mincore            218
 #define TARGET_NR_madvise            219
-#define TARGET_NR_getdents64		220
-#define TARGET_NR_readahead		222
-#define TARGET_NR_setxattr		224
-#define TARGET_NR_lsetxattr		225
-#define TARGET_NR_fsetxattr		226
-#define TARGET_NR_getxattr		227
-#define TARGET_NR_lgetxattr		228
-#define TARGET_NR_fgetxattr		229
-#define TARGET_NR_listxattr		230
-#define TARGET_NR_llistxattr		231
-#define TARGET_NR_flistxattr		232
-#define TARGET_NR_removexattr	233
-#define TARGET_NR_lremovexattr	234
-#define TARGET_NR_fremovexattr	235
-#define TARGET_NR_gettid		236
-#define TARGET_NR_tkill		237
-#define TARGET_NR_futex		238
-#define TARGET_NR_sched_setaffinity	239
-#define TARGET_NR_sched_getaffinity	240
-#define TARGET_NR_tgkill		241
+#define TARGET_NR_getdents64            220
+#define TARGET_NR_readahead             222
+#define TARGET_NR_setxattr              224
+#define TARGET_NR_lsetxattr             225
+#define TARGET_NR_fsetxattr             226
+#define TARGET_NR_getxattr              227
+#define TARGET_NR_lgetxattr             228
+#define TARGET_NR_fgetxattr             229
+#define TARGET_NR_listxattr             230
+#define TARGET_NR_llistxattr            231
+#define TARGET_NR_flistxattr            232
+#define TARGET_NR_removexattr   233
+#define TARGET_NR_lremovexattr  234
+#define TARGET_NR_fremovexattr  235
+#define TARGET_NR_gettid                236
+#define TARGET_NR_tkill         237
+#define TARGET_NR_futex         238
+#define TARGET_NR_sched_setaffinity     239
+#define TARGET_NR_sched_getaffinity     240
+#define TARGET_NR_tgkill                241
 /* Number 242 is reserved for tux */
-#define TARGET_NR_io_setup		243
-#define TARGET_NR_io_destroy		244
-#define TARGET_NR_io_getevents	245
-#define TARGET_NR_io_submit		246
-#define TARGET_NR_io_cancel		247
-#define TARGET_NR_exit_group		248
-#define TARGET_NR_epoll_create	249
-#define TARGET_NR_epoll_ctl		250
-#define TARGET_NR_epoll_wait		251
-#define TARGET_NR_set_tid_address	252
-#define TARGET_NR_fadvise64		253
-#define TARGET_NR_timer_create	254
-#define TARGET_NR_timer_settime	(TARGET_NR_timer_create+1)
-#define TARGET_NR_timer_gettime	(TARGET_NR_timer_create+2)
-#define TARGET_NR_timer_getoverrun	(TARGET_NR_timer_create+3)
-#define TARGET_NR_timer_delete	(TARGET_NR_timer_create+4)
-#define TARGET_NR_clock_settime	(TARGET_NR_timer_create+5)
-#define TARGET_NR_clock_gettime	(TARGET_NR_timer_create+6)
-#define TARGET_NR_clock_getres	(TARGET_NR_timer_create+7)
-#define TARGET_NR_clock_nanosleep	(TARGET_NR_timer_create+8)
+#define TARGET_NR_io_setup              243
+#define TARGET_NR_io_destroy            244
+#define TARGET_NR_io_getevents  245
+#define TARGET_NR_io_submit             246
+#define TARGET_NR_io_cancel             247
+#define TARGET_NR_exit_group            248
+#define TARGET_NR_epoll_create  249
+#define TARGET_NR_epoll_ctl             250
+#define TARGET_NR_epoll_wait            251
+#define TARGET_NR_set_tid_address       252
+#define TARGET_NR_fadvise64             253
+#define TARGET_NR_timer_create  254
+#define TARGET_NR_timer_settime (TARGET_NR_timer_create + 1)
+#define TARGET_NR_timer_gettime (TARGET_NR_timer_create + 2)
+#define TARGET_NR_timer_getoverrun      (TARGET_NR_timer_create + 3)
+#define TARGET_NR_timer_delete  (TARGET_NR_timer_create + 4)
+#define TARGET_NR_clock_settime (TARGET_NR_timer_create + 5)
+#define TARGET_NR_clock_gettime (TARGET_NR_timer_create + 6)
+#define TARGET_NR_clock_getres  (TARGET_NR_timer_create + 7)
+#define TARGET_NR_clock_nanosleep       (TARGET_NR_timer_create + 8)
 /* Number 263 is reserved for vserver */
-#define TARGET_NR_statfs64		265
-#define TARGET_NR_fstatfs64		266
-#define TARGET_NR_remap_file_pages	267
+#define TARGET_NR_statfs64              265
+#define TARGET_NR_fstatfs64             266
+#define TARGET_NR_remap_file_pages      267
 /* Number 268 is reserved for new sys_mbind */
 /* Number 269 is reserved for new sys_get_mempolicy */
 /* Number 270 is reserved for new sys_set_mempolicy */
-#define TARGET_NR_mq_open		271
-#define TARGET_NR_mq_unlink		272
-#define TARGET_NR_mq_timedsend	273
-#define TARGET_NR_mq_timedreceive	274
-#define TARGET_NR_mq_notify		275
-#define TARGET_NR_mq_getsetattr	276
-#define TARGET_NR_kexec_load		277
-#define TARGET_NR_add_key		278
-#define TARGET_NR_request_key	279
-#define TARGET_NR_keyctl		280
-#define TARGET_NR_waitid		281
-#define TARGET_NR_ioprio_set		282
-#define TARGET_NR_ioprio_get		283
-#define TARGET_NR_inotify_init	284
-#define TARGET_NR_inotify_add_watch	285
-#define TARGET_NR_inotify_rm_watch	286
+#define TARGET_NR_mq_open               271
+#define TARGET_NR_mq_unlink             272
+#define TARGET_NR_mq_timedsend  273
+#define TARGET_NR_mq_timedreceive       274
+#define TARGET_NR_mq_notify             275
+#define TARGET_NR_mq_getsetattr 276
+#define TARGET_NR_kexec_load            277
+#define TARGET_NR_add_key               278
+#define TARGET_NR_request_key   279
+#define TARGET_NR_keyctl                280
+#define TARGET_NR_waitid                281
+#define TARGET_NR_ioprio_set            282
+#define TARGET_NR_ioprio_get            283
+#define TARGET_NR_inotify_init  284
+#define TARGET_NR_inotify_add_watch     285
+#define TARGET_NR_inotify_rm_watch      286
 /* Number 287 is reserved for new sys_migrate_pages */
-#define TARGET_NR_openat		288
-#define TARGET_NR_mkdirat		289
-#define TARGET_NR_mknodat		290
-#define TARGET_NR_fchownat		291
-#define TARGET_NR_futimesat		292
-#define TARGET_NR_unlinkat		294
-#define TARGET_NR_renameat		295
-#define TARGET_NR_linkat		296
-#define TARGET_NR_symlinkat		297
-#define TARGET_NR_readlinkat		298
-#define TARGET_NR_fchmodat		299
-#define TARGET_NR_faccessat		300
-#define TARGET_NR_pselect6		301
-#define TARGET_NR_ppoll		302
-#define TARGET_NR_unshare		303
-#define TARGET_NR_set_robust_list	304
-#define TARGET_NR_get_robust_list	305
-#define TARGET_NR_splice		306
-#define TARGET_NR_sync_file_range	307
-#define TARGET_NR_tee		308
-#define TARGET_NR_vmsplice		309
+#define TARGET_NR_openat                288
+#define TARGET_NR_mkdirat               289
+#define TARGET_NR_mknodat               290
+#define TARGET_NR_fchownat              291
+#define TARGET_NR_futimesat             292
+#define TARGET_NR_newfstatat            293
+#define TARGET_NR_unlinkat              294
+#define TARGET_NR_renameat              295
+#define TARGET_NR_linkat                296
+#define TARGET_NR_symlinkat             297
+#define TARGET_NR_readlinkat            298
+#define TARGET_NR_fchmodat              299
+#define TARGET_NR_faccessat             300
+#define TARGET_NR_pselect6              301
+#define TARGET_NR_ppoll         302
+#define TARGET_NR_unshare               303
+#define TARGET_NR_set_robust_list       304
+#define TARGET_NR_get_robust_list       305
+#define TARGET_NR_splice                306
+#define TARGET_NR_sync_file_range       307
+#define TARGET_NR_tee           308
+#define TARGET_NR_vmsplice              309
 /* Number 310 is reserved for new sys_move_pages */
-#define TARGET_NR_getcpu		311
-#define TARGET_NR_epoll_pwait	312
-#define TARGET_NR_utimes		313
-#define TARGET_NR_fallocate		314
-#define TARGET_NR_utimensat		315
-#define TARGET_NR_signalfd		316
-#define TARGET_NR_timerfd		317
-#define TARGET_NR_eventfd		318
-#define TARGET_NR_timerfd_create	319
-#define TARGET_NR_timerfd_settime	320
-#define TARGET_NR_timerfd_gettime	321
-#define TARGET_NR_signalfd4		322
-#define TARGET_NR_eventfd2		323
-#define TARGET_NR_inotify_init1	324
-#define TARGET_NR_pipe2		325
-#define TARGET_NR_dup3		326
-#define TARGET_NR_epoll_create1	327
+#define TARGET_NR_getcpu                311
+#define TARGET_NR_epoll_pwait   312
+#define TARGET_NR_utimes                313
+#define TARGET_NR_fallocate             314
+#define TARGET_NR_utimensat             315
+#define TARGET_NR_signalfd              316
+#define TARGET_NR_timerfd               317
+#define TARGET_NR_eventfd               318
+#define TARGET_NR_timerfd_create        319
+#define TARGET_NR_timerfd_settime       320
+#define TARGET_NR_timerfd_gettime       321
+#define TARGET_NR_signalfd4             322
+#define TARGET_NR_eventfd2              323
+#define TARGET_NR_inotify_init1 324
+#define TARGET_NR_pipe2         325
+#define TARGET_NR_dup3          326
+#define TARGET_NR_epoll_create1 327
 #define TARGET_NR_preadv                328
 #define TARGET_NR_pwritev               329
 #define TARGET_NR_rt_tgsigqueueinfo     330
@@ -305,94 +327,5 @@
 #define TARGET_NR_shutdown              373
 #define TARGET_NR_mlock2                374
 
-/*
- * There are some system calls that are not present on 64 bit, some
- * have a different name although they do the same (e.g. TARGET_NR_chown32
- * is TARGET_NR_chown on 64 bit).
- */
-#ifndef TARGET_S390X
-
-#define TARGET_NR_time		 13
-#define TARGET_NR_lchown		 16
-#define TARGET_NR_setuid		 23
-#define TARGET_NR_getuid		 24
-#define TARGET_NR_stime		 25
-#define TARGET_NR_setgid		 46
-#define TARGET_NR_getgid		 47
-#define TARGET_NR_geteuid		 49
-#define TARGET_NR_getegid		 50
-#define TARGET_NR_setreuid		 70
-#define TARGET_NR_setregid		 71
-#define TARGET_NR_getrlimit		 76
-#define TARGET_NR_getgroups		 80
-#define TARGET_NR_setgroups		 81
-#define TARGET_NR_fchown		 95
-#define TARGET_NR_ioperm		101
-#define TARGET_NR_setfsuid		138
-#define TARGET_NR_setfsgid		139
-#define TARGET_NR__llseek		140
-#define TARGET_NR__newselect 	142
-#define TARGET_NR_setresuid		164
-#define TARGET_NR_getresuid		165
-#define TARGET_NR_setresgid		170
-#define TARGET_NR_getresgid		171
-#define TARGET_NR_chown		182
-#define TARGET_NR_ugetrlimit		191	/* SuS compliant getrlimit */
-#define TARGET_NR_mmap2		192
-#define TARGET_NR_truncate64		193
-#define TARGET_NR_ftruncate64	194
-#define TARGET_NR_stat64		195
-#define TARGET_NR_lstat64		196
-#define TARGET_NR_fstat64		197
-#define TARGET_NR_lchown32		198
-#define TARGET_NR_getuid32		199
-#define TARGET_NR_getgid32		200
-#define TARGET_NR_geteuid32		201
-#define TARGET_NR_getegid32		202
-#define TARGET_NR_setreuid32		203
-#define TARGET_NR_setregid32		204
-#define TARGET_NR_getgroups32	205
-#define TARGET_NR_setgroups32	206
-#define TARGET_NR_fchown32		207
-#define TARGET_NR_setresuid32	208
-#define TARGET_NR_getresuid32	209
-#define TARGET_NR_setresgid32	210
-#define TARGET_NR_getresgid32	211
-#define TARGET_NR_chown32		212
-#define TARGET_NR_setuid32		213
-#define TARGET_NR_setgid32		214
-#define TARGET_NR_setfsuid32		215
-#define TARGET_NR_setfsgid32		216
-#define TARGET_NR_fcntl64		221
-#define TARGET_NR_sendfile64		223
-#define TARGET_NR_fadvise64_64	264
-#define TARGET_NR_fstatat64		293
-
-#else
-
-#define TARGET_NR_select		142
-#define TARGET_NR_getrlimit		191	/* SuS compliant getrlimit */
-#define TARGET_NR_lchown  		198
-#define TARGET_NR_getuid  		199
-#define TARGET_NR_getgid  		200
-#define TARGET_NR_geteuid  		201
-#define TARGET_NR_getegid  		202
-#define TARGET_NR_setreuid  		203
-#define TARGET_NR_setregid  		204
-#define TARGET_NR_getgroups  	205
-#define TARGET_NR_setgroups  	206
-#define TARGET_NR_fchown  		207
-#define TARGET_NR_setresuid  	208
-#define TARGET_NR_getresuid  	209
-#define TARGET_NR_setresgid  	210
-#define TARGET_NR_getresgid  	211
-#define TARGET_NR_chown  		212
-#define TARGET_NR_setuid  		213
-#define TARGET_NR_setgid  		214
-#define TARGET_NR_setfsuid  		215
-#define TARGET_NR_setfsgid  		216
-#define TARGET_NR_newfstatat		293
-
-#endif
 
 #endif
Signature · 1 line
2.24.1
#13 lore raw

PATCH v4 11/21 linux-user, s390x: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl from linux/arch/s390x/kernel/syscalls v5.5 Copy syscallhdr.sh from m68k.

---
 configure                      |   3 +-
 linux-user/Makefile.objs       |   1 +
 linux-user/s390x/Makefile.objs |   5 +
 linux-user/s390x/syscall.tbl   | 440 +++++++++++++++++++++++++++++++++
 linux-user/s390x/syscall_nr.h  | 331 -------------------------
 linux-user/s390x/syscallhdr.sh |  32 +++
 6 files changed, 480 insertions(+), 332 deletions(-)
 create mode 100644 linux-user/s390x/Makefile.objs
 create mode 100644 linux-user/s390x/syscall.tbl
 delete mode 100644 linux-user/s390x/syscall_nr.h
 create mode 100755 linux-user/s390x/syscallhdr.sh
configure +2 -1
index f2500823ba52..8805fab48279 100755
@@ -1889,7 +1889,7 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc ; do
+for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7912,6 +7912,7 @@ case "$target_name" in
     echo "TARGET_ABI32=y" >> $config_target_mak
   ;;
   s390x)
+    TARGET_SYSTBL_ABI=common,64
     mttcg=yes
     gdb_xml_files="s390x-core64.xml s390-acr.xml s390-fpr.xml s390-vx.xml s390-cr.xml s390-virt.xml s390-gs.xml"
   ;;
linux-user/Makefile.objs +1 -0
index 8b00dad687b2..f4e666e74c91 100644
@@ -14,5 +14,6 @@ obj-$(TARGET_M68K) += m68k/
 obj-$(TARGET_MICROBLAZE) += microblaze/
 obj-$(TARGET_PPC) += ppc/
 obj-$(TARGET_PPC64) += ppc/
+obj-$(TARGET_S390X) += s390x/
 obj-$(TARGET_SH4) += sh4/
 obj-$(TARGET_XTENSA) += xtensa/
linux-user/s390x/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..f30f1625ccff
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/s390x/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/s390x/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/s390x/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/s390x/syscall.tbl new file +440 -0

440 lines not on this page · raw message

linux-user/s390x/syscall_nr.h deleted +0 -331

331 lines not on this page · raw message

linux-user/s390x/syscallhdr.sh new file +32 -0
new file mode 100755
index 000000000000..85a99c48deea
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_S390X_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */\n" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#14 lore raw

PATCH v4 12/21 linux-user, sparc, sparc64: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/sparc/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                        |   6 +-
 linux-user/Makefile.objs         |   2 +
 linux-user/sparc/Makefile.objs   |   5 +
 linux-user/sparc/syscall.tbl     | 483 +++++++++++++++++++++++++++++++
 linux-user/sparc/syscall_nr.h    | 363 -----------------------
 linux-user/sparc/syscallhdr.sh   |  32 ++
 linux-user/sparc64/Makefile.objs |   5 +
 linux-user/sparc64/syscall.tbl   | 483 +++++++++++++++++++++++++++++++
 linux-user/sparc64/syscall_nr.h  | 366 -----------------------
 linux-user/sparc64/syscallhdr.sh |  32 ++
 10 files changed, 1047 insertions(+), 730 deletions(-)
 create mode 100644 linux-user/sparc/Makefile.objs
 create mode 100644 linux-user/sparc/syscall.tbl
 delete mode 100644 linux-user/sparc/syscall_nr.h
 create mode 100644 linux-user/sparc/syscallhdr.sh
 create mode 100644 linux-user/sparc64/Makefile.objs
 create mode 100644 linux-user/sparc64/syscall.tbl
 delete mode 100644 linux-user/sparc64/syscall_nr.h
 create mode 100644 linux-user/sparc64/syscallhdr.sh
configure +5 -1
index 8805fab48279..0f063c368f2a 100755
@@ -1889,7 +1889,8 @@ rm -f */config-devices.mak.d
 
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
-for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x ; do
+for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x sparc sparc64 \
+    ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7901,14 +7902,17 @@ case "$target_name" in
     bflt="yes"
   ;;
   sparc)
+    TARGET_SYSTBL_ABI=common,32
   ;;
   sparc64)
     TARGET_BASE_ARCH=sparc
+    TARGET_SYSTBL_ABI=common,64
   ;;
   sparc32plus)
     TARGET_ARCH=sparc64
     TARGET_BASE_ARCH=sparc
     TARGET_ABI_DIR=sparc
+    TARGET_SYSTBL_ABI=common,32
     echo "TARGET_ABI32=y" >> $config_target_mak
   ;;
   s390x)
linux-user/Makefile.objs +2 -0
index f4e666e74c91..36f20cad794c 100644
@@ -16,4 +16,6 @@ obj-$(TARGET_PPC) += ppc/
 obj-$(TARGET_PPC64) += ppc/
 obj-$(TARGET_S390X) += s390x/
 obj-$(TARGET_SH4) += sh4/
+obj-$(TARGET_SPARC) += sparc/
+obj-$(TARGET_SPARC64) += $(TARGET_ABI_DIR)/
 obj-$(TARGET_XTENSA) += xtensa/
linux-user/sparc/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..29d3f066cbab
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/sparc/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/sparc/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/sparc/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/sparc/syscall.tbl new file +483 -0

483 lines not on this page · raw message

linux-user/sparc/syscall_nr.h deleted +0 -363

363 lines not on this page · raw message

linux-user/sparc/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..34a99dc83269
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_SPARC_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry compat ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
linux-user/sparc64/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..afcd535bc4a4
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/sparc64/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/sparc64/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/sparc/syscall.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/sparc64/syscall.tbl new file +483 -0

483 lines not on this page · raw message

linux-user/sparc64/syscall_nr.h deleted +0 -366

366 lines not on this page · raw message

linux-user/sparc64/syscallhdr.sh new file +32 -0
new file mode 100644
index 000000000000..08c7e39bb3fe
@@ -0,0 +1,32 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_SPARC64_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry compat ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+) > "$out"
Signature · 1 line
2.24.1
#15 lore raw

PATCH v4 13/21 linux-user, x86_64, i386: cleanup TARGET_NR_arch_prctl

In reply to Laurent Vivier

Define do_arch_prctl() for i386 and x86_64, but return -TARGET_ENOSYS for i386.

---
 linux-user/i386/target_cpu.h |  4 ++--
 linux-user/syscall.c         | 19 +++++++++++--------
 2 files changed, 13 insertions(+), 10 deletions(-)
linux-user/i386/target_cpu.h +2 -2
index 0b44530854c8..2207d24c2eb0 100644
@@ -33,6 +33,8 @@ static inline void cpu_clone_regs_parent(CPUX86State *env, unsigned flags)
 {
 }
 
+abi_long do_arch_prctl(CPUX86State *env, int code, abi_ulong addr);
+
 #if defined(TARGET_ABI32)
 abi_long do_set_thread_area(CPUX86State *env, abi_ulong ptr);
 
@@ -42,8 +44,6 @@ static inline void cpu_set_tls(CPUX86State *env, target_ulong newtls)
     cpu_x86_load_seg(env, R_GS, env->segs[R_GS].selector);
 }
 #else
-abi_long do_arch_prctl(CPUX86State *env, int code, abi_ulong addr);
-
 static inline void cpu_set_tls(CPUX86State *env, target_ulong newtls)
 {
     do_arch_prctl(env, TARGET_ARCH_SET_FS, newtls);
linux-user/syscall.c +11 -8
index f50a16070815..0eede7620664 100644
@@ -5498,6 +5498,10 @@ static bitmask_transtbl mmap_flags_tbl[] = {
     { 0, 0, 0, 0 }
 };
 
+/*
+ * NOTE: TARGET_ABI32 is defined for TARGET_I386 (but not for TARGET_X86_64)
+ *       TARGET_I386 is defined if TARGET_X86_64 is defined
+ */
 #if defined(TARGET_I386)
 
 /* NOTE: there is really one LDT for all the threads */
@@ -5637,7 +5641,7 @@ static abi_long do_modify_ldt(CPUX86State *env, int func, abi_ulong ptr,
     return ret;
 }
 
-#if defined(TARGET_I386) && defined(TARGET_ABI32)
+#if defined(TARGET_ABI32)
 abi_long do_set_thread_area(CPUX86State *env, abi_ulong ptr)
 {
     uint64_t *gdt_table = g2h(env->gdt.base);
@@ -5769,9 +5773,12 @@ static abi_long do_get_thread_area(CPUX86State *env, abi_ulong ptr)
     unlock_user_struct(target_ldt_info, ptr, 1);
     return 0;
 }
-#endif /* TARGET_I386 && TARGET_ABI32 */
 
-#ifndef TARGET_ABI32
+abi_long do_arch_prctl(CPUX86State *env, int code, abi_ulong addr)
+{
+    return -ENOSYS;
+}
+#else
 abi_long do_arch_prctl(CPUX86State *env, int code, abi_ulong addr)
 {
     abi_long ret = 0;
@@ -5804,7 +5811,7 @@ abi_long do_arch_prctl(CPUX86State *env, int code, abi_ulong addr)
     }
     return ret;
 }
-#endif
+#endif /* defined(TARGET_ABI32 */
 
 #endif /* defined(TARGET_I386) */
 
@@ -10247,11 +10254,7 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
         break;
 #ifdef TARGET_NR_arch_prctl
     case TARGET_NR_arch_prctl:
-#if defined(TARGET_I386) && !defined(TARGET_ABI32)
         return do_arch_prctl(cpu_env, arg1, arg2);
-#else
-#error unreachable
-#endif
 #endif
 #ifdef TARGET_NR_pread64
     case TARGET_NR_pread64:
Signature · 1 line
2.24.1
#16 lore raw

PATCH v4 14/21 linux-user, i386: add syscall table generation support

In reply to Laurent Vivier

Copy syscall_32.tbl and syscallhdr.sh from linux/arch/x86/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                      |   3 +-
 linux-user/Makefile.objs       |   1 +
 linux-user/i386/Makefile.objs  |   5 +
 linux-user/i386/syscall_32.tbl | 442 +++++++++++++++++++++++++++++++++
 linux-user/i386/syscall_nr.h   | 387 -----------------------------
 linux-user/i386/syscallhdr.sh  |  28 +++
 6 files changed, 478 insertions(+), 388 deletions(-)
 create mode 100644 linux-user/i386/Makefile.objs
 create mode 100644 linux-user/i386/syscall_32.tbl
 delete mode 100644 linux-user/i386/syscall_nr.h
 create mode 100644 linux-user/i386/syscallhdr.sh
configure +2 -1
index 0f063c368f2a..84bedad04b21 100755
@@ -1890,7 +1890,7 @@ rm -f */config-devices.mak.d
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
 for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x sparc sparc64 \
-    ; do
+    i386 ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7788,6 +7788,7 @@ case "$target_name" in
   i386)
     mttcg="yes"
 	gdb_xml_files="i386-32bit.xml"
+    TARGET_SYSTBL_ABI=i386
   ;;
   x86_64)
     TARGET_BASE_ARCH=i386
linux-user/Makefile.objs +1 -0
index 36f20cad794c..720d9773b813 100644
@@ -10,6 +10,7 @@ obj-$(TARGET_AARCH64) += arm/semihost.o
 obj-$(TARGET_ALPHA) += alpha/
 obj-$(TARGET_ARM) += arm/
 obj-$(TARGET_HPPA) += hppa/
+obj-$(TARGET_I386) += i386/
 obj-$(TARGET_M68K) += m68k/
 obj-$(TARGET_MICROBLAZE) += microblaze/
 obj-$(TARGET_PPC) += ppc/
linux-user/i386/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..c25cf17bfb64
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/i386/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/i386/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/i386/syscall_32.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/i386/syscall_32.tbl new file +442 -0

442 lines not on this page · raw message

linux-user/i386/syscall_nr.h deleted +0 -387

387 lines not on this page · raw message

linux-user/i386/syscallhdr.sh new file +28 -0
new file mode 100644
index 000000000000..b2eca96db7e8
@@ -0,0 +1,28 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_I386_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    echo "#ifndef ${fileguard}"
+    echo "#define ${fileguard} 1"
+    echo ""
+
+    while read nr abi name entry ; do
+    if [ -z "$offset" ]; then
+        echo "#define TARGET_NR_${prefix}${name} $nr"
+    else
+        echo "#define TARGET_NR_${prefix}${name} ($offset + $nr)"
+        fi
+    done
+
+    echo ""
+    echo "#endif /* ${fileguard} */"
+) > "$out"
Signature · 1 line
2.24.1
#17 lore raw

PATCH v4 15/21 linux-user, x86_64: add syscall table generation support

In reply to Laurent Vivier

Copy syscall_64.tbl and syscallhdr.sh from linux/arch/x86/kernel/syscalls v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h

---
 configure                        |   3 +-
 linux-user/Makefile.objs         |   1 +
 linux-user/x86_64/Makefile.objs  |   5 +
 linux-user/x86_64/syscall_64.tbl | 402 +++++++++++++++++++++++++++++++
 linux-user/x86_64/syscall_nr.h   | 356 ---------------------------
 linux-user/x86_64/syscallhdr.sh  |  28 +++
 6 files changed, 438 insertions(+), 357 deletions(-)
 create mode 100644 linux-user/x86_64/Makefile.objs
 create mode 100644 linux-user/x86_64/syscall_64.tbl
 delete mode 100644 linux-user/x86_64/syscall_nr.h
 create mode 100644 linux-user/x86_64/syscallhdr.sh
configure +2 -1
index 84bedad04b21..eda37fd47669 100755
@@ -1890,7 +1890,7 @@ rm -f */config-devices.mak.d
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
 for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x sparc sparc64 \
-    i386 ; do
+    i386 x86_64 ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7792,6 +7792,7 @@ case "$target_name" in
   ;;
   x86_64)
     TARGET_BASE_ARCH=i386
+    TARGET_SYSTBL_ABI=common,64
     mttcg="yes"
 	gdb_xml_files="i386-64bit.xml"
   ;;
linux-user/Makefile.objs +1 -0
index 720d9773b813..1791bc48cd17 100644
@@ -19,4 +19,5 @@ obj-$(TARGET_S390X) += s390x/
 obj-$(TARGET_SH4) += sh4/
 obj-$(TARGET_SPARC) += sparc/
 obj-$(TARGET_SPARC64) += $(TARGET_ABI_DIR)/
+obj-$(TARGET_X86_64) += x86_64/
 obj-$(TARGET_XTENSA) += xtensa/
linux-user/x86_64/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..2cef1d48becc
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/x86_64/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/x86_64/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/x86_64/syscall_64.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI),"GEN","$@")
linux-user/x86_64/syscall_64.tbl new file +402 -0

402 lines not on this page · raw message

linux-user/x86_64/syscall_nr.h deleted +0 -356

356 lines not on this page · raw message

linux-user/x86_64/syscallhdr.sh new file +28 -0
new file mode 100644
index 000000000000..182be52a74f5
@@ -0,0 +1,28 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_X86_64_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    echo "#ifndef ${fileguard}"
+    echo "#define ${fileguard} 1"
+    echo ""
+
+    while read nr abi name entry ; do
+    if [ -z "$offset" ]; then
+        echo "#define TARGET_NR_${prefix}${name} $nr"
+    else
+        echo "#define TARGET_NR_${prefix}${name} ($offset + $nr)"
+        fi
+    done
+
+    echo ""
+    echo "#endif /* ${fileguard} */"
+) > "$out"
Signature · 1 line
2.24.1
#18 lore raw

PATCH v4 16/21 linux-user, mips: add syscall table generation support

In reply to Laurent Vivier

Copy syscall.tbl and syscallhdr.sh from linux/arch/mips/kernel/syscalls/syscall_o32.tbl v5.5 Update syscallhdr.sh to generate QEMU syscall_nr.h
Move the offset (4000) from the file to the Makefile.objs to be passed
to syscallhdr.sh
Rename on the fly fadvise64 to fadvise64_64.

---
 configure                       |   3 +-
 linux-user/Makefile.objs        |   1 +
 linux-user/mips/Makefile.objs   |   5 +
 linux-user/mips/syscall_nr.h    | 425 --------------------------------
 linux-user/mips/syscall_o32.tbl | 425 ++++++++++++++++++++++++++++++++
 linux-user/mips/syscallhdr.sh   |  36 +++
 6 files changed, 469 insertions(+), 426 deletions(-)
 create mode 100644 linux-user/mips/Makefile.objs
 delete mode 100644 linux-user/mips/syscall_nr.h
 create mode 100644 linux-user/mips/syscall_o32.tbl
 create mode 100644 linux-user/mips/syscallhdr.sh
configure +2 -1
index eda37fd47669..7432f955b8f5 100755
@@ -1890,7 +1890,7 @@ rm -f */config-devices.mak.d
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
 for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x sparc sparc64 \
-    i386 x86_64 ; do
+    i386 x86_64 mips ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7837,6 +7837,7 @@ case "$target_name" in
     mttcg="yes"
     TARGET_ARCH=mips
     echo "TARGET_ABI_MIPSO32=y" >> $config_target_mak
+    TARGET_SYSTBL_ABI=o32
   ;;
   mipsn32|mipsn32el)
     mttcg="yes"
linux-user/Makefile.objs +1 -0
index 1791bc48cd17..0a0715e9e192 100644
@@ -13,6 +13,7 @@ obj-$(TARGET_HPPA) += hppa/
 obj-$(TARGET_I386) += i386/
 obj-$(TARGET_M68K) += m68k/
 obj-$(TARGET_MICROBLAZE) += microblaze/
+obj-$(TARGET_MIPS) += mips/
 obj-$(TARGET_PPC) += ppc/
 obj-$(TARGET_PPC64) += ppc/
 obj-$(TARGET_S390X) += s390x/
linux-user/mips/Makefile.objs new file +5 -0
new file mode 100644
index 000000000000..9be4de07d99a
@@ -0,0 +1,5 @@
+generated-files-y += linux-user/mips/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/mips/syscallhdr.sh
+%/syscall_nr.h: $(SRC_PATH)/linux-user/mips/syscall_o32.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ $(TARGET_SYSTBL_ABI) "" 4000,"GEN","$@")
linux-user/mips/syscall_nr.h deleted +0 -425

425 lines not on this page · raw message

linux-user/mips/syscall_o32.tbl new file +425 -0

425 lines not on this page · raw message

linux-user/mips/syscallhdr.sh new file +36 -0
new file mode 100644
index 000000000000..761e3e47dda2
@@ -0,0 +1,36 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_MIPS_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry compat ; do
+        if [ "$name" = "fadvise64" ] ; then
+            name="fadvise64_64"
+        fi
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+    printf "\n"
+) > "$out"
Signature · 1 line
2.24.1
#19 lore raw

PATCH v4 17/21 linux-user, mips64: add syscall table generation support

In reply to Laurent Vivier

Copy syscall_n32.tbl, syscall_n64.tbl and syscallhdr.sh from linux/arch/parisc/kernel/syscalls v5.5
Update syscallhdr.sh to generate QEMU syscall_nr.h

Move the offsets (6000 for n32 and 5000 for n64) from the file to the Makefile.objs to be passed to syscallhdr.sh

---
 configure                         |   4 +-
 linux-user/Makefile.objs          |   1 +
 linux-user/mips64/Makefile.objs   |  12 +
 linux-user/mips64/syscall_n32.tbl | 376 ++++++++++++++++
 linux-user/mips64/syscall_n64.tbl | 352 +++++++++++++++
 linux-user/mips64/syscall_nr.h    | 725 ------------------------------
 linux-user/mips64/syscallhdr.sh   |  33 ++
 7 files changed, 777 insertions(+), 726 deletions(-)
 create mode 100644 linux-user/mips64/Makefile.objs
 create mode 100644 linux-user/mips64/syscall_n32.tbl
 create mode 100644 linux-user/mips64/syscall_n64.tbl
 delete mode 100644 linux-user/mips64/syscall_nr.h
 create mode 100644 linux-user/mips64/syscallhdr.sh
configure +3 -1
index 7432f955b8f5..a60292db63b3 100755
@@ -1890,7 +1890,7 @@ rm -f */config-devices.mak.d
 # Remove syscall_nr.h to be sure they will be regenerated in the build
 # directory, not in the source directory
 for arch in alpha hppa m68k xtensa sh4 microblaze arm ppc s390x sparc sparc64 \
-    i386 x86_64 mips ; do
+    i386 x86_64 mips mips64 ; do
     # remove the file if it has been generated in the source directory
     rm -f "${source_path}/linux-user/${arch}/syscall_nr.h"
     # remove the dependency files
@@ -7845,12 +7845,14 @@ case "$target_name" in
     TARGET_BASE_ARCH=mips
     echo "TARGET_ABI_MIPSN32=y" >> $config_target_mak
     echo "TARGET_ABI32=y" >> $config_target_mak
+    TARGET_SYSTBL_ABI=n32
   ;;
   mips64|mips64el)
     mttcg="yes"
     TARGET_ARCH=mips64
     TARGET_BASE_ARCH=mips
     echo "TARGET_ABI_MIPSN64=y" >> $config_target_mak
+    TARGET_SYSTBL_ABI=n64
   ;;
   moxie)
   ;;
linux-user/Makefile.objs +1 -0
index 0a0715e9e192..1940910a7321 100644
@@ -14,6 +14,7 @@ obj-$(TARGET_I386) += i386/
 obj-$(TARGET_M68K) += m68k/
 obj-$(TARGET_MICROBLAZE) += microblaze/
 obj-$(TARGET_MIPS) += mips/
+obj-$(TARGET_MIPS64) += mips64/
 obj-$(TARGET_PPC) += ppc/
 obj-$(TARGET_PPC64) += ppc/
 obj-$(TARGET_S390X) += s390x/
linux-user/mips64/Makefile.objs new file +12 -0
new file mode 100644
index 000000000000..573448f9568a
@@ -0,0 +1,12 @@
+generated-files-y += linux-user/$(TARGET_ABI_DIR)/syscall_nr.h
+
+syshdr := $(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)/syscallhdr.sh
+
+ifeq ($(TARGET_SYSTBL_ABI),n32)
+%/syscall_nr.h: $(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)/syscall_n32.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ n32 "" 6000,"GEN","$@")
+endif
+ifeq ($(TARGET_SYSTBL_ABI),n64)
+%/syscall_nr.h: $(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)/syscall_n64.tbl $(syshdr)
+	$(call quiet-command, sh $(syshdr) $< $@ n64 "" 5000,"GEN","$@")
+endif
linux-user/mips64/syscall_n32.tbl new file +376 -0

376 lines not on this page · raw message

linux-user/mips64/syscall_n64.tbl new file +352 -0

352 lines not on this page · raw message

linux-user/mips64/syscall_nr.h deleted +0 -725

725 lines not on this page · raw message

linux-user/mips64/syscallhdr.sh new file +33 -0
new file mode 100644
index 000000000000..ed5a45165a40
@@ -0,0 +1,33 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
+
+in="$1"
+out="$2"
+my_abis=`echo "($3)" | tr ',' '|'`
+prefix="$4"
+offset="$5"
+
+fileguard=LINUX_USER_MIPS64_`basename "$out" | sed \
+    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
+    -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
+grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
+    printf "#ifndef %s\n" "${fileguard}"
+    printf "#define %s\n" "${fileguard}"
+    printf "\n"
+
+    nxt=0
+    while read nr abi name entry compat ; do
+        if [ -z "$offset" ]; then
+            printf "#define TARGET_NR_%s%s\t%s\n" \
+                "${prefix}" "${name}" "${nr}"
+        else
+            printf "#define TARGET_NR_%s%s\t(%s + %s)\n" \
+                "${prefix}" "${name}" "${offset}" "${nr}"
+        fi
+        nxt=$((nr+1))
+    done
+
+    printf "\n"
+    printf "#endif /* %s */" "${fileguard}"
+    printf "\n"
+) > "$out"
Signature · 1 line
2.24.1
#20 lore raw

PATCH v4 18/21 linux-user, scripts: add a script to update syscall.tbl

In reply to Laurent Vivier

scripts/update-syscalltbl.sh has the list of syscall.tbl to update and can copy them from the linux source directory

---
 MAINTAINERS                  |  1 +
 scripts/update-syscalltbl.sh | 49 ++++++++++++++++++++++++++++++++++++
 2 files changed, 50 insertions(+)
 create mode 100755 scripts/update-syscalltbl.sh
MAINTAINERS +1 -0
index 36d0c6887a99..709832758e51 100644
@@ -2448,6 +2448,7 @@ S: Maintained
 F: linux-user/
 F: default-configs/*-linux-user.mak
 F: scripts/qemu-binfmt-conf.sh
+F: scripts/update-syscalltbl.sh
 
 Tiny Code Generator (TCG)
 -------------------------
scripts/update-syscalltbl.sh new file +49 -0

49 lines not on this page · raw message

Signature · 1 line
2.24.1
Reviewed-by on v4 18/21
#21 lore raw

Re: [PATCH v4 18/21] linux-user,scripts: add a script to update syscall.tbl

Quoted 10 lines · Laurent Vivier

scripts/update-syscalltbl.sh has the list of syscall.tbl to update and can copy them from the linux source directory

---
 MAINTAINERS                  |  1 +
 scripts/update-syscalltbl.sh | 49 ++++++++++++++++++++++++++++++++++++
 2 files changed, 50 insertions(+)
 create mode 100755 scripts/update-syscalltbl.sh

r~

#22 lore raw

PATCH v4 19/21 linux-user: update syscall.tbl from linux 0bf999f9c5e7

In reply to Laurent Vivier

Run scripts/update-syscalltbl.sh with linux commit 0bf999f9c5e7

---
 linux-user/arm/syscall.tbl        | 2 ++
 linux-user/hppa/syscall.tbl       | 2 ++
 linux-user/i386/syscall_32.tbl    | 2 ++
 linux-user/m68k/syscall.tbl       | 4 +++-
 linux-user/microblaze/syscall.tbl | 2 ++
 linux-user/mips/syscall_o32.tbl   | 2 ++
 linux-user/mips64/syscall_n32.tbl | 2 ++
 linux-user/mips64/syscall_n64.tbl | 2 ++
 linux-user/ppc/syscall.tbl        | 2 ++
 linux-user/s390x/syscall.tbl      | 2 ++
 linux-user/sh4/syscall.tbl        | 2 ++
 linux-user/sparc/syscall.tbl      | 2 ++
 linux-user/sparc64/syscall.tbl    | 2 ++
 linux-user/x86_64/syscall_64.tbl  | 2 ++
 linux-user/xtensa/syscall.tbl     | 2 ++
 15 files changed, 31 insertions(+), 1 deletion(-)
linux-user/arm/syscall.tbl +2 -0
index 6da7dc4d79cc..4d1cf74a2caa 100644
@@ -449,3 +449,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 435	common	clone3				sys_clone3
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/hppa/syscall.tbl +2 -0
index 285ff516150c..52a15f5cd130 100644
@@ -433,3 +433,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 435	common	clone3				sys_clone3_wrapper
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/i386/syscall_32.tbl +2 -0
index 15908eb9b17e..c17cb77eb150 100644
@@ -440,3 +440,5 @@
 433	i386	fspick			sys_fspick			__ia32_sys_fspick
 434	i386	pidfd_open		sys_pidfd_open			__ia32_sys_pidfd_open
 435	i386	clone3			sys_clone3			__ia32_sys_clone3
+437	i386	openat2			sys_openat2			__ia32_sys_openat2
+438	i386	pidfd_getfd		sys_pidfd_getfd			__ia32_sys_pidfd_getfd
linux-user/m68k/syscall.tbl +3 -1
index a88a285a0e5f..f4f49fcb76d0 100644
@@ -434,4 +434,6 @@
 432	common	fsmount				sys_fsmount
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
-# 435 reserved for clone3
+435	common	clone3				__sys_clone3
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/microblaze/syscall.tbl +2 -0
index 09b0cd7dab0a..4c67b11f9c9e 100644
@@ -441,3 +441,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 435	common	clone3				sys_clone3
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/mips/syscall_o32.tbl +2 -0
index 353539ea4140..ac586774c980 100644
@@ -423,3 +423,5 @@
 433	o32	fspick				sys_fspick
 434	o32	pidfd_open			sys_pidfd_open
 435	o32	clone3				__sys_clone3
+437	o32	openat2				sys_openat2
+438	o32	pidfd_getfd			sys_pidfd_getfd
linux-user/mips64/syscall_n32.tbl +2 -0
index e7c5ab38e403..1f9e8ad636cc 100644
@@ -374,3 +374,5 @@
 433	n32	fspick				sys_fspick
 434	n32	pidfd_open			sys_pidfd_open
 435	n32	clone3				__sys_clone3
+437	n32	openat2				sys_openat2
+438	n32	pidfd_getfd			sys_pidfd_getfd
linux-user/mips64/syscall_n64.tbl +2 -0
index 13cd66581f3b..c0b9d802dbf6 100644
@@ -350,3 +350,5 @@
 433	n64	fspick				sys_fspick
 434	n64	pidfd_open			sys_pidfd_open
 435	n64	clone3				__sys_clone3
+437	n64	openat2				sys_openat2
+438	n64	pidfd_getfd			sys_pidfd_getfd
linux-user/ppc/syscall.tbl +2 -0
index 43f736ed47f2..35b61bfc1b1a 100644
@@ -517,3 +517,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 435	nospu	clone3				ppc_clone3
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/s390x/syscall.tbl +2 -0
index 3054e9c035a3..bd7bd3581a0f 100644
@@ -438,3 +438,5 @@
 433  common	fspick			sys_fspick			sys_fspick
 434  common	pidfd_open		sys_pidfd_open			sys_pidfd_open
 435  common	clone3			sys_clone3			sys_clone3
+437  common	openat2			sys_openat2			sys_openat2
+438  common	pidfd_getfd		sys_pidfd_getfd			sys_pidfd_getfd
linux-user/sh4/syscall.tbl +2 -0
index b5ed26c4c005..c7a30fcd135f 100644
@@ -438,3 +438,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 # 435 reserved for clone3
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/sparc/syscall.tbl +2 -0
index 8c8cc7537fb2..f13615ecdecc 100644
@@ -481,3 +481,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 # 435 reserved for clone3
+437	common	openat2			sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/sparc64/syscall.tbl +2 -0
index 8c8cc7537fb2..f13615ecdecc 100644
@@ -481,3 +481,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 # 435 reserved for clone3
+437	common	openat2			sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
linux-user/x86_64/syscall_64.tbl +2 -0
index c29976eca4a8..44d510bc9b78 100644
@@ -357,6 +357,8 @@
 433	common	fspick			__x64_sys_fspick
 434	common	pidfd_open		__x64_sys_pidfd_open
 435	common	clone3			__x64_sys_clone3/ptregs
+437	common	openat2			__x64_sys_openat2
+438	common	pidfd_getfd		__x64_sys_pidfd_getfd
 
 #
 # x32-specific system call numbers start at 512 to avoid cache impact
linux-user/xtensa/syscall.tbl +2 -0
index 25f4de729a6d..85a9ab1bc04d 100644
@@ -406,3 +406,5 @@
 433	common	fspick				sys_fspick
 434	common	pidfd_open			sys_pidfd_open
 435	common	clone3				sys_clone3
+437	common	openat2				sys_openat2
+438	common	pidfd_getfd			sys_pidfd_getfd
Signature · 1 line
2.24.1
#23 lore raw

PATCH v4 20/21 linux-user,mips: move content of mips_syscall_args

In reply to Laurent Vivier

Move content of mips_syscall_args to mips-syscall-args-o32.c.inc to ease automatic update. No functionnal change

---
 linux-user/mips/cpu_loop.c             | 440 +------------------------
 linux-user/mips/syscall-args-o32.c.inc | 438 ++++++++++++++++++++++++
 2 files changed, 439 insertions(+), 439 deletions(-)
 create mode 100644 linux-user/mips/syscall-args-o32.c.inc
linux-user/mips/cpu_loop.c +1 -439
index 396367d81d8d..553e8ca7f576 100644
@@ -26,447 +26,9 @@
 
 # ifdef TARGET_ABI_MIPSO32
 #  define MIPS_SYSCALL_NUMBER_UNUSED -1
-#  define MIPS_SYS(name, args) args,
 static const int8_t mips_syscall_args[] = {
-        MIPS_SYS(sys_syscall    , 8)    /* 4000 */
-        MIPS_SYS(sys_exit       , 1)
-        MIPS_SYS(sys_fork       , 0)
-        MIPS_SYS(sys_read       , 3)
-        MIPS_SYS(sys_write      , 3)
-        MIPS_SYS(sys_open       , 3)    /* 4005 */
-        MIPS_SYS(sys_close      , 1)
-        MIPS_SYS(sys_waitpid    , 3)
-        MIPS_SYS(sys_creat      , 2)
-        MIPS_SYS(sys_link       , 2)
-        MIPS_SYS(sys_unlink     , 1)    /* 4010 */
-        MIPS_SYS(sys_execve     , 0)
-        MIPS_SYS(sys_chdir      , 1)
-        MIPS_SYS(sys_time       , 1)
-        MIPS_SYS(sys_mknod      , 3)
-        MIPS_SYS(sys_chmod      , 2)    /* 4015 */
-        MIPS_SYS(sys_lchown     , 3)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_stat */
-        MIPS_SYS(sys_lseek      , 3)
-        MIPS_SYS(sys_getpid     , 0)    /* 4020 */
-        MIPS_SYS(sys_mount      , 5)
-        MIPS_SYS(sys_umount     , 1)
-        MIPS_SYS(sys_setuid     , 1)
-        MIPS_SYS(sys_getuid     , 0)
-        MIPS_SYS(sys_stime      , 1)    /* 4025 */
-        MIPS_SYS(sys_ptrace     , 4)
-        MIPS_SYS(sys_alarm      , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_fstat */
-        MIPS_SYS(sys_pause      , 0)
-        MIPS_SYS(sys_utime      , 2)    /* 4030 */
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_access     , 2)
-        MIPS_SYS(sys_nice       , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4035 */
-        MIPS_SYS(sys_sync       , 0)
-        MIPS_SYS(sys_kill       , 2)
-        MIPS_SYS(sys_rename     , 2)
-        MIPS_SYS(sys_mkdir      , 2)
-        MIPS_SYS(sys_rmdir      , 1)    /* 4040 */
-        MIPS_SYS(sys_dup                , 1)
-        MIPS_SYS(sys_pipe       , 0)
-        MIPS_SYS(sys_times      , 1)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_brk                , 1)    /* 4045 */
-        MIPS_SYS(sys_setgid     , 1)
-        MIPS_SYS(sys_getgid     , 0)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was signal(2) */
-        MIPS_SYS(sys_geteuid    , 0)
-        MIPS_SYS(sys_getegid    , 0)    /* 4050 */
-        MIPS_SYS(sys_acct       , 0)
-        MIPS_SYS(sys_umount2    , 2)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ioctl      , 3)
-        MIPS_SYS(sys_fcntl      , 3)    /* 4055 */
-        MIPS_SYS(sys_ni_syscall , 2)
-        MIPS_SYS(sys_setpgid    , 2)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_olduname   , 1)
-        MIPS_SYS(sys_umask      , 1)    /* 4060 */
-        MIPS_SYS(sys_chroot     , 1)
-        MIPS_SYS(sys_ustat      , 2)
-        MIPS_SYS(sys_dup2       , 2)
-        MIPS_SYS(sys_getppid    , 0)
-        MIPS_SYS(sys_getpgrp    , 0)    /* 4065 */
-        MIPS_SYS(sys_setsid     , 0)
-        MIPS_SYS(sys_sigaction  , 3)
-        MIPS_SYS(sys_sgetmask   , 0)
-        MIPS_SYS(sys_ssetmask   , 1)
-        MIPS_SYS(sys_setreuid   , 2)    /* 4070 */
-        MIPS_SYS(sys_setregid   , 2)
-        MIPS_SYS(sys_sigsuspend , 0)
-        MIPS_SYS(sys_sigpending , 1)
-        MIPS_SYS(sys_sethostname        , 2)
-        MIPS_SYS(sys_setrlimit  , 2)    /* 4075 */
-        MIPS_SYS(sys_getrlimit  , 2)
-        MIPS_SYS(sys_getrusage  , 2)
-        MIPS_SYS(sys_gettimeofday, 2)
-        MIPS_SYS(sys_settimeofday, 2)
-        MIPS_SYS(sys_getgroups  , 2)    /* 4080 */
-        MIPS_SYS(sys_setgroups  , 2)
-        MIPS_SYS(sys_ni_syscall , 0)    /* old_select */
-        MIPS_SYS(sys_symlink    , 2)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_lstat */
-        MIPS_SYS(sys_readlink   , 3)    /* 4085 */
-        MIPS_SYS(sys_uselib     , 1)
-        MIPS_SYS(sys_swapon     , 2)
-        MIPS_SYS(sys_reboot     , 3)
-        MIPS_SYS(old_readdir    , 3)
-        MIPS_SYS(old_mmap       , 6)    /* 4090 */
-        MIPS_SYS(sys_munmap     , 2)
-        MIPS_SYS(sys_truncate   , 2)
-        MIPS_SYS(sys_ftruncate  , 2)
-        MIPS_SYS(sys_fchmod     , 2)
-        MIPS_SYS(sys_fchown     , 3)    /* 4095 */
-        MIPS_SYS(sys_getpriority        , 2)
-        MIPS_SYS(sys_setpriority        , 3)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_statfs     , 2)
-        MIPS_SYS(sys_fstatfs    , 2)    /* 4100 */
-        MIPS_SYS(sys_ni_syscall , 0)    /* was ioperm(2) */
-        MIPS_SYS(sys_socketcall , 2)
-        MIPS_SYS(sys_syslog     , 3)
-        MIPS_SYS(sys_setitimer  , 3)
-        MIPS_SYS(sys_getitimer  , 2)    /* 4105 */
-        MIPS_SYS(sys_newstat    , 2)
-        MIPS_SYS(sys_newlstat   , 2)
-        MIPS_SYS(sys_newfstat   , 2)
-        MIPS_SYS(sys_uname      , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4110 was iopl(2) */
-        MIPS_SYS(sys_vhangup    , 0)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_idle() */
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_vm86 */
-        MIPS_SYS(sys_wait4      , 4)
-        MIPS_SYS(sys_swapoff    , 1)    /* 4115 */
-        MIPS_SYS(sys_sysinfo    , 1)
-        MIPS_SYS(sys_ipc                , 6)
-        MIPS_SYS(sys_fsync      , 1)
-        MIPS_SYS(sys_sigreturn  , 0)
-        MIPS_SYS(sys_clone      , 6)    /* 4120 */
-        MIPS_SYS(sys_setdomainname, 2)
-        MIPS_SYS(sys_newuname   , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* sys_modify_ldt */
-        MIPS_SYS(sys_adjtimex   , 1)
-        MIPS_SYS(sys_mprotect   , 3)    /* 4125 */
-        MIPS_SYS(sys_sigprocmask        , 3)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was create_module */
-        MIPS_SYS(sys_init_module        , 5)
-        MIPS_SYS(sys_delete_module, 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4130 was get_kernel_syms */
-        MIPS_SYS(sys_quotactl   , 0)
-        MIPS_SYS(sys_getpgid    , 1)
-        MIPS_SYS(sys_fchdir     , 1)
-        MIPS_SYS(sys_bdflush    , 2)
-        MIPS_SYS(sys_sysfs      , 3)    /* 4135 */
-        MIPS_SYS(sys_personality        , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* for afs_syscall */
-        MIPS_SYS(sys_setfsuid   , 1)
-        MIPS_SYS(sys_setfsgid   , 1)
-        MIPS_SYS(sys_llseek     , 5)    /* 4140 */
-        MIPS_SYS(sys_getdents   , 3)
-        MIPS_SYS(sys_select     , 5)
-        MIPS_SYS(sys_flock      , 2)
-        MIPS_SYS(sys_msync      , 3)
-        MIPS_SYS(sys_readv      , 3)    /* 4145 */
-        MIPS_SYS(sys_writev     , 3)
-        MIPS_SYS(sys_cacheflush , 3)
-        MIPS_SYS(sys_cachectl   , 3)
-        MIPS_SYS(sys_sysmips    , 4)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4150 */
-        MIPS_SYS(sys_getsid     , 1)
-        MIPS_SYS(sys_fdatasync  , 0)
-        MIPS_SYS(sys_sysctl     , 1)
-        MIPS_SYS(sys_mlock      , 2)
-        MIPS_SYS(sys_munlock    , 2)    /* 4155 */
-        MIPS_SYS(sys_mlockall   , 1)
-        MIPS_SYS(sys_munlockall , 0)
-        MIPS_SYS(sys_sched_setparam, 2)
-        MIPS_SYS(sys_sched_getparam, 2)
-        MIPS_SYS(sys_sched_setscheduler, 3)     /* 4160 */
-        MIPS_SYS(sys_sched_getscheduler, 1)
-        MIPS_SYS(sys_sched_yield        , 0)
-        MIPS_SYS(sys_sched_get_priority_max, 1)
-        MIPS_SYS(sys_sched_get_priority_min, 1)
-        MIPS_SYS(sys_sched_rr_get_interval, 2)  /* 4165 */
-        MIPS_SYS(sys_nanosleep, 2)
-        MIPS_SYS(sys_mremap     , 5)
-        MIPS_SYS(sys_accept     , 3)
-        MIPS_SYS(sys_bind       , 3)
-        MIPS_SYS(sys_connect    , 3)    /* 4170 */
-        MIPS_SYS(sys_getpeername        , 3)
-        MIPS_SYS(sys_getsockname        , 3)
-        MIPS_SYS(sys_getsockopt , 5)
-        MIPS_SYS(sys_listen     , 2)
-        MIPS_SYS(sys_recv       , 4)    /* 4175 */
-        MIPS_SYS(sys_recvfrom   , 6)
-        MIPS_SYS(sys_recvmsg    , 3)
-        MIPS_SYS(sys_send       , 4)
-        MIPS_SYS(sys_sendmsg    , 3)
-        MIPS_SYS(sys_sendto     , 6)    /* 4180 */
-        MIPS_SYS(sys_setsockopt , 5)
-        MIPS_SYS(sys_shutdown   , 2)
-        MIPS_SYS(sys_socket     , 3)
-        MIPS_SYS(sys_socketpair , 4)
-        MIPS_SYS(sys_setresuid  , 3)    /* 4185 */
-        MIPS_SYS(sys_getresuid  , 3)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_query_module */
-        MIPS_SYS(sys_poll       , 3)
-        MIPS_SYS(sys_nfsservctl , 3)
-        MIPS_SYS(sys_setresgid  , 3)    /* 4190 */
-        MIPS_SYS(sys_getresgid  , 3)
-        MIPS_SYS(sys_prctl      , 5)
-        MIPS_SYS(sys_rt_sigreturn, 0)
-        MIPS_SYS(sys_rt_sigaction, 4)
-        MIPS_SYS(sys_rt_sigprocmask, 4) /* 4195 */
-        MIPS_SYS(sys_rt_sigpending, 2)
-        MIPS_SYS(sys_rt_sigtimedwait, 4)
-        MIPS_SYS(sys_rt_sigqueueinfo, 3)
-        MIPS_SYS(sys_rt_sigsuspend, 0)
-        MIPS_SYS(sys_pread64    , 6)    /* 4200 */
-        MIPS_SYS(sys_pwrite64   , 6)
-        MIPS_SYS(sys_chown      , 3)
-        MIPS_SYS(sys_getcwd     , 2)
-        MIPS_SYS(sys_capget     , 2)
-        MIPS_SYS(sys_capset     , 2)    /* 4205 */
-        MIPS_SYS(sys_sigaltstack        , 2)
-        MIPS_SYS(sys_sendfile   , 4)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_mmap2      , 6)    /* 4210 */
-        MIPS_SYS(sys_truncate64 , 4)
-        MIPS_SYS(sys_ftruncate64        , 4)
-        MIPS_SYS(sys_stat64     , 2)
-        MIPS_SYS(sys_lstat64    , 2)
-        MIPS_SYS(sys_fstat64    , 2)    /* 4215 */
-        MIPS_SYS(sys_pivot_root , 2)
-        MIPS_SYS(sys_mincore    , 3)
-        MIPS_SYS(sys_madvise    , 3)
-        MIPS_SYS(sys_getdents64 , 3)
-        MIPS_SYS(sys_fcntl64    , 3)    /* 4220 */
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_gettid     , 0)
-        MIPS_SYS(sys_readahead  , 5)
-        MIPS_SYS(sys_setxattr   , 5)
-        MIPS_SYS(sys_lsetxattr  , 5)    /* 4225 */
-        MIPS_SYS(sys_fsetxattr  , 5)
-        MIPS_SYS(sys_getxattr   , 4)
-        MIPS_SYS(sys_lgetxattr  , 4)
-        MIPS_SYS(sys_fgetxattr  , 4)
-        MIPS_SYS(sys_listxattr  , 3)    /* 4230 */
-        MIPS_SYS(sys_llistxattr , 3)
-        MIPS_SYS(sys_flistxattr , 3)
-        MIPS_SYS(sys_removexattr        , 2)
-        MIPS_SYS(sys_lremovexattr, 2)
-        MIPS_SYS(sys_fremovexattr, 2)   /* 4235 */
-        MIPS_SYS(sys_tkill      , 2)
-        MIPS_SYS(sys_sendfile64 , 5)
-        MIPS_SYS(sys_futex      , 6)
-        MIPS_SYS(sys_sched_setaffinity, 3)
-        MIPS_SYS(sys_sched_getaffinity, 3)      /* 4240 */
-        MIPS_SYS(sys_io_setup   , 2)
-        MIPS_SYS(sys_io_destroy , 1)
-        MIPS_SYS(sys_io_getevents, 5)
-        MIPS_SYS(sys_io_submit  , 3)
-        MIPS_SYS(sys_io_cancel  , 3)    /* 4245 */
-        MIPS_SYS(sys_exit_group , 1)
-        MIPS_SYS(sys_lookup_dcookie, 3)
-        MIPS_SYS(sys_epoll_create, 1)
-        MIPS_SYS(sys_epoll_ctl  , 4)
-        MIPS_SYS(sys_epoll_wait , 3)    /* 4250 */
-        MIPS_SYS(sys_remap_file_pages, 5)
-        MIPS_SYS(sys_set_tid_address, 1)
-        MIPS_SYS(sys_restart_syscall, 0)
-        MIPS_SYS(sys_fadvise64_64, 7)
-        MIPS_SYS(sys_statfs64   , 3)    /* 4255 */
-        MIPS_SYS(sys_fstatfs64  , 2)
-        MIPS_SYS(sys_timer_create, 3)
-        MIPS_SYS(sys_timer_settime, 4)
-        MIPS_SYS(sys_timer_gettime, 2)
-        MIPS_SYS(sys_timer_getoverrun, 1)       /* 4260 */
-        MIPS_SYS(sys_timer_delete, 1)
-        MIPS_SYS(sys_clock_settime, 2)
-        MIPS_SYS(sys_clock_gettime, 2)
-        MIPS_SYS(sys_clock_getres, 2)
-        MIPS_SYS(sys_clock_nanosleep, 4)        /* 4265 */
-        MIPS_SYS(sys_tgkill     , 3)
-        MIPS_SYS(sys_utimes     , 2)
-        MIPS_SYS(sys_mbind      , 4)
-        MIPS_SYS(sys_ni_syscall , 0)    /* sys_get_mempolicy */
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4270 sys_set_mempolicy */
-        MIPS_SYS(sys_mq_open    , 4)
-        MIPS_SYS(sys_mq_unlink  , 1)
-        MIPS_SYS(sys_mq_timedsend, 5)
-        MIPS_SYS(sys_mq_timedreceive, 5)
-        MIPS_SYS(sys_mq_notify  , 2)    /* 4275 */
-        MIPS_SYS(sys_mq_getsetattr, 3)
-        MIPS_SYS(sys_ni_syscall , 0)    /* sys_vserver */
-        MIPS_SYS(sys_waitid     , 4)
-        MIPS_SYS(sys_ni_syscall , 0)    /* available, was setaltroot */
-        MIPS_SYS(sys_add_key    , 5)
-        MIPS_SYS(sys_request_key, 4)
-        MIPS_SYS(sys_keyctl     , 5)
-        MIPS_SYS(sys_set_thread_area, 1)
-        MIPS_SYS(sys_inotify_init, 0)
-        MIPS_SYS(sys_inotify_add_watch, 3) /* 4285 */
-        MIPS_SYS(sys_inotify_rm_watch, 2)
-        MIPS_SYS(sys_migrate_pages, 4)
-        MIPS_SYS(sys_openat, 4)
-        MIPS_SYS(sys_mkdirat, 3)
-        MIPS_SYS(sys_mknodat, 4)        /* 4290 */
-        MIPS_SYS(sys_fchownat, 5)
-        MIPS_SYS(sys_futimesat, 3)
-        MIPS_SYS(sys_fstatat64, 4)
-        MIPS_SYS(sys_unlinkat, 3)
-        MIPS_SYS(sys_renameat, 4)       /* 4295 */
-        MIPS_SYS(sys_linkat, 5)
-        MIPS_SYS(sys_symlinkat, 3)
-        MIPS_SYS(sys_readlinkat, 4)
-        MIPS_SYS(sys_fchmodat, 3)
-        MIPS_SYS(sys_faccessat, 3)      /* 4300 */
-        MIPS_SYS(sys_pselect6, 6)
-        MIPS_SYS(sys_ppoll, 5)
-        MIPS_SYS(sys_unshare, 1)
-        MIPS_SYS(sys_splice, 6)
-        MIPS_SYS(sys_sync_file_range, 7) /* 4305 */
-        MIPS_SYS(sys_tee, 4)
-        MIPS_SYS(sys_vmsplice, 4)
-        MIPS_SYS(sys_move_pages, 6)
-        MIPS_SYS(sys_set_robust_list, 2)
-        MIPS_SYS(sys_get_robust_list, 3) /* 4310 */
-        MIPS_SYS(sys_kexec_load, 4)
-        MIPS_SYS(sys_getcpu, 3)
-        MIPS_SYS(sys_epoll_pwait, 6)
-        MIPS_SYS(sys_ioprio_set, 3)
-        MIPS_SYS(sys_ioprio_get, 2)
-        MIPS_SYS(sys_utimensat, 4)
-        MIPS_SYS(sys_signalfd, 3)
-        MIPS_SYS(sys_ni_syscall, 0)     /* was timerfd */
-        MIPS_SYS(sys_eventfd, 1)
-        MIPS_SYS(sys_fallocate, 6)      /* 4320 */
-        MIPS_SYS(sys_timerfd_create, 2)
-        MIPS_SYS(sys_timerfd_gettime, 2)
-        MIPS_SYS(sys_timerfd_settime, 4)
-        MIPS_SYS(sys_signalfd4, 4)
-        MIPS_SYS(sys_eventfd2, 2)       /* 4325 */
-        MIPS_SYS(sys_epoll_create1, 1)
-        MIPS_SYS(sys_dup3, 3)
-        MIPS_SYS(sys_pipe2, 2)
-        MIPS_SYS(sys_inotify_init1, 1)
-        MIPS_SYS(sys_preadv, 5)         /* 4330 */
-        MIPS_SYS(sys_pwritev, 5)
-        MIPS_SYS(sys_rt_tgsigqueueinfo, 4)
-        MIPS_SYS(sys_perf_event_open, 5)
-        MIPS_SYS(sys_accept4, 4)
-        MIPS_SYS(sys_recvmmsg, 5)       /* 4335 */
-        MIPS_SYS(sys_fanotify_init, 2)
-        MIPS_SYS(sys_fanotify_mark, 6)
-        MIPS_SYS(sys_prlimit64, 4)
-        MIPS_SYS(sys_name_to_handle_at, 5)
-        MIPS_SYS(sys_open_by_handle_at, 3) /* 4340 */
-        MIPS_SYS(sys_clock_adjtime, 2)
-        MIPS_SYS(sys_syncfs, 1)
-        MIPS_SYS(sys_sendmmsg, 4)
-        MIPS_SYS(sys_setns, 2)
-        MIPS_SYS(sys_process_vm_readv, 6) /* 345 */
-        MIPS_SYS(sys_process_vm_writev, 6)
-        MIPS_SYS(sys_kcmp, 5)
-        MIPS_SYS(sys_finit_module, 3)
-        MIPS_SYS(sys_sched_setattr, 2)
-        MIPS_SYS(sys_sched_getattr, 3)  /* 350 */
-        MIPS_SYS(sys_renameat2, 5)
-        MIPS_SYS(sys_seccomp, 3)
-        MIPS_SYS(sys_getrandom, 3)
-        MIPS_SYS(sys_memfd_create, 2)
-        MIPS_SYS(sys_bpf, 3)            /* 355 */
-        MIPS_SYS(sys_execveat, 5)
-        MIPS_SYS(sys_userfaultfd, 1)
-        MIPS_SYS(sys_membarrier, 2)
-        MIPS_SYS(sys_mlock2, 3)
-        MIPS_SYS(sys_copy_file_range, 6) /* 360 */
-        MIPS_SYS(sys_preadv2, 6)
-        MIPS_SYS(sys_pwritev2, 6)
-        MIPS_SYS(sys_pkey_mprotect, 4)
-        MIPS_SYS(sys_pkey_alloc, 2)
-        MIPS_SYS(sys_pkey_free, 1)                 /* 365 */
-        MIPS_SYS(sys_statx, 5)
-        MIPS_SYS(sys_rseq, 4)
-        MIPS_SYS(sys_io_pgetevents, 6)
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 370 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 375 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 380 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 385 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 390 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYS(sys_semget, 3)
-        MIPS_SYS(sys_semctl, 4)
-        MIPS_SYS(sys_shmget, 3)                    /* 395 */
-        MIPS_SYS(sys_shmctl, 3)
-        MIPS_SYS(sys_shmat, 3)
-        MIPS_SYS(sys_shmdt, 1)
-        MIPS_SYS(sys_msgget, 2)
-        MIPS_SYS(sys_msgsnd, 4)                    /* 400 */
-        MIPS_SYS(sys_msgrcv, 5)
-        MIPS_SYS(sys_msgctl, 3)
-        MIPS_SYS(sys_clock_gettime64, 2)
-        MIPS_SYS(sys_clock_settime64, 2)
-        MIPS_SYS(sys_clock_adjtime64, 2)           /* 405 */
-        MIPS_SYS(sys_clock_getres_time64, 2)
-        MIPS_SYS(sys_clock_nanosleep_time64, 4)
-        MIPS_SYS(sys_timer_gettime64, 2)
-        MIPS_SYS(sys_timer_settime64, 4)
-        MIPS_SYS(sys_timerfd_gettime64, 2)         /* 410 */
-        MIPS_SYS(sys_timerfd_settime64, 4)
-        MIPS_SYS(sys_utimensat_time64, 4)
-        MIPS_SYS(sys_pselect6_time64, 6)
-        MIPS_SYS(sys_ppoll_time64, 5)
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 415 */
-        MIPS_SYS(sys_io_pgetevents_time64, 6)
-        MIPS_SYS(sys_recvmmsg_time64, 5)
-        MIPS_SYS(sys_mq_timedsend_time64, 5)
-        MIPS_SYS(sys_mq_timedreceive_time64, 5)
-        MIPS_SYS(sys_semtimedop_time64, 4)         /* 420 */
-        MIPS_SYS(sys_rt_sigtimedwait_time64, 4)
-        MIPS_SYS(sys_futex_time64, 6)
-        MIPS_SYS(sys_sched_rr_get_interval_time64, 2)
-        MIPS_SYS(sys_pidfd_send_signal, 4)
-        MIPS_SYS(sys_io_uring_setup, 2)            /* 425 */
-        MIPS_SYS(sys_io_uring_enter, 6)
-        MIPS_SYS(sys_io_uring_register, 4)
-        MIPS_SYS(sys_open_tree, 3)
-        MIPS_SYS(sys_move_mount, 5)
-        MIPS_SYS(sys_fsopen, 2)                    /* 430 */
-        MIPS_SYS(sys_fsconfig, 5)
-        MIPS_SYS(sys_fsmount, 3)
-        MIPS_SYS(sys_fspick, 3)
-        MIPS_SYS(sys_pidfd_open, 2)
-        MIPS_SYS(sys_clone3, 2)                    /* 435 */
-
+#include "syscall-args-o32.c.inc"
 };
-#  undef MIPS_SYS
 # endif /* O32 */
 
 /* Break codes */
linux-user/mips/syscall-args-o32.c.inc new file +438 -0

438 lines not on this page · raw message

Signature · 1 line
2.24.1
#24 lore raw

PATCH v4 21/21 linux-user,mips: update syscall-args-o32.c.inc

In reply to Laurent Vivier

Add a script to update the file from strace github and run it

---
 linux-user/mips/syscall-args-o32.c.inc | 874 ++++++++++++-------------
 scripts/update-mips-syscall-args.sh    |  57 ++
 2 files changed, 493 insertions(+), 438 deletions(-)
 create mode 100755 scripts/update-mips-syscall-args.sh
linux-user/mips/syscall-args-o32.c.inc +436 -438
index f060b061441a..0ad35857b4e4 100644
@@ -1,438 +1,436 @@
-#  define MIPS_SYS(name, args) args,
-        MIPS_SYS(sys_syscall    , 8)    /* 4000 */
-        MIPS_SYS(sys_exit       , 1)
-        MIPS_SYS(sys_fork       , 0)
-        MIPS_SYS(sys_read       , 3)
-        MIPS_SYS(sys_write      , 3)
-        MIPS_SYS(sys_open       , 3)    /* 4005 */
-        MIPS_SYS(sys_close      , 1)
-        MIPS_SYS(sys_waitpid    , 3)
-        MIPS_SYS(sys_creat      , 2)
-        MIPS_SYS(sys_link       , 2)
-        MIPS_SYS(sys_unlink     , 1)    /* 4010 */
-        MIPS_SYS(sys_execve     , 0)
-        MIPS_SYS(sys_chdir      , 1)
-        MIPS_SYS(sys_time       , 1)
-        MIPS_SYS(sys_mknod      , 3)
-        MIPS_SYS(sys_chmod      , 2)    /* 4015 */
-        MIPS_SYS(sys_lchown     , 3)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_stat */
-        MIPS_SYS(sys_lseek      , 3)
-        MIPS_SYS(sys_getpid     , 0)    /* 4020 */
-        MIPS_SYS(sys_mount      , 5)
-        MIPS_SYS(sys_umount     , 1)
-        MIPS_SYS(sys_setuid     , 1)
-        MIPS_SYS(sys_getuid     , 0)
-        MIPS_SYS(sys_stime      , 1)    /* 4025 */
-        MIPS_SYS(sys_ptrace     , 4)
-        MIPS_SYS(sys_alarm      , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_fstat */
-        MIPS_SYS(sys_pause      , 0)
-        MIPS_SYS(sys_utime      , 2)    /* 4030 */
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_access     , 2)
-        MIPS_SYS(sys_nice       , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4035 */
-        MIPS_SYS(sys_sync       , 0)
-        MIPS_SYS(sys_kill       , 2)
-        MIPS_SYS(sys_rename     , 2)
-        MIPS_SYS(sys_mkdir      , 2)
-        MIPS_SYS(sys_rmdir      , 1)    /* 4040 */
-        MIPS_SYS(sys_dup                , 1)
-        MIPS_SYS(sys_pipe       , 0)
-        MIPS_SYS(sys_times      , 1)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_brk                , 1)    /* 4045 */
-        MIPS_SYS(sys_setgid     , 1)
-        MIPS_SYS(sys_getgid     , 0)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was signal(2) */
-        MIPS_SYS(sys_geteuid    , 0)
-        MIPS_SYS(sys_getegid    , 0)    /* 4050 */
-        MIPS_SYS(sys_acct       , 0)
-        MIPS_SYS(sys_umount2    , 2)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ioctl      , 3)
-        MIPS_SYS(sys_fcntl      , 3)    /* 4055 */
-        MIPS_SYS(sys_ni_syscall , 2)
-        MIPS_SYS(sys_setpgid    , 2)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_olduname   , 1)
-        MIPS_SYS(sys_umask      , 1)    /* 4060 */
-        MIPS_SYS(sys_chroot     , 1)
-        MIPS_SYS(sys_ustat      , 2)
-        MIPS_SYS(sys_dup2       , 2)
-        MIPS_SYS(sys_getppid    , 0)
-        MIPS_SYS(sys_getpgrp    , 0)    /* 4065 */
-        MIPS_SYS(sys_setsid     , 0)
-        MIPS_SYS(sys_sigaction  , 3)
-        MIPS_SYS(sys_sgetmask   , 0)
-        MIPS_SYS(sys_ssetmask   , 1)
-        MIPS_SYS(sys_setreuid   , 2)    /* 4070 */
-        MIPS_SYS(sys_setregid   , 2)
-        MIPS_SYS(sys_sigsuspend , 0)
-        MIPS_SYS(sys_sigpending , 1)
-        MIPS_SYS(sys_sethostname        , 2)
-        MIPS_SYS(sys_setrlimit  , 2)    /* 4075 */
-        MIPS_SYS(sys_getrlimit  , 2)
-        MIPS_SYS(sys_getrusage  , 2)
-        MIPS_SYS(sys_gettimeofday, 2)
-        MIPS_SYS(sys_settimeofday, 2)
-        MIPS_SYS(sys_getgroups  , 2)    /* 4080 */
-        MIPS_SYS(sys_setgroups  , 2)
-        MIPS_SYS(sys_ni_syscall , 0)    /* old_select */
-        MIPS_SYS(sys_symlink    , 2)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_lstat */
-        MIPS_SYS(sys_readlink   , 3)    /* 4085 */
-        MIPS_SYS(sys_uselib     , 1)
-        MIPS_SYS(sys_swapon     , 2)
-        MIPS_SYS(sys_reboot     , 3)
-        MIPS_SYS(old_readdir    , 3)
-        MIPS_SYS(old_mmap       , 6)    /* 4090 */
-        MIPS_SYS(sys_munmap     , 2)
-        MIPS_SYS(sys_truncate   , 2)
-        MIPS_SYS(sys_ftruncate  , 2)
-        MIPS_SYS(sys_fchmod     , 2)
-        MIPS_SYS(sys_fchown     , 3)    /* 4095 */
-        MIPS_SYS(sys_getpriority        , 2)
-        MIPS_SYS(sys_setpriority        , 3)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_statfs     , 2)
-        MIPS_SYS(sys_fstatfs    , 2)    /* 4100 */
-        MIPS_SYS(sys_ni_syscall , 0)    /* was ioperm(2) */
-        MIPS_SYS(sys_socketcall , 2)
-        MIPS_SYS(sys_syslog     , 3)
-        MIPS_SYS(sys_setitimer  , 3)
-        MIPS_SYS(sys_getitimer  , 2)    /* 4105 */
-        MIPS_SYS(sys_newstat    , 2)
-        MIPS_SYS(sys_newlstat   , 2)
-        MIPS_SYS(sys_newfstat   , 2)
-        MIPS_SYS(sys_uname      , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4110 was iopl(2) */
-        MIPS_SYS(sys_vhangup    , 0)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_idle() */
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_vm86 */
-        MIPS_SYS(sys_wait4      , 4)
-        MIPS_SYS(sys_swapoff    , 1)    /* 4115 */
-        MIPS_SYS(sys_sysinfo    , 1)
-        MIPS_SYS(sys_ipc                , 6)
-        MIPS_SYS(sys_fsync      , 1)
-        MIPS_SYS(sys_sigreturn  , 0)
-        MIPS_SYS(sys_clone      , 6)    /* 4120 */
-        MIPS_SYS(sys_setdomainname, 2)
-        MIPS_SYS(sys_newuname   , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* sys_modify_ldt */
-        MIPS_SYS(sys_adjtimex   , 1)
-        MIPS_SYS(sys_mprotect   , 3)    /* 4125 */
-        MIPS_SYS(sys_sigprocmask        , 3)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was create_module */
-        MIPS_SYS(sys_init_module        , 5)
-        MIPS_SYS(sys_delete_module, 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4130 was get_kernel_syms */
-        MIPS_SYS(sys_quotactl   , 0)
-        MIPS_SYS(sys_getpgid    , 1)
-        MIPS_SYS(sys_fchdir     , 1)
-        MIPS_SYS(sys_bdflush    , 2)
-        MIPS_SYS(sys_sysfs      , 3)    /* 4135 */
-        MIPS_SYS(sys_personality        , 1)
-        MIPS_SYS(sys_ni_syscall , 0)    /* for afs_syscall */
-        MIPS_SYS(sys_setfsuid   , 1)
-        MIPS_SYS(sys_setfsgid   , 1)
-        MIPS_SYS(sys_llseek     , 5)    /* 4140 */
-        MIPS_SYS(sys_getdents   , 3)
-        MIPS_SYS(sys_select     , 5)
-        MIPS_SYS(sys_flock      , 2)
-        MIPS_SYS(sys_msync      , 3)
-        MIPS_SYS(sys_readv      , 3)    /* 4145 */
-        MIPS_SYS(sys_writev     , 3)
-        MIPS_SYS(sys_cacheflush , 3)
-        MIPS_SYS(sys_cachectl   , 3)
-        MIPS_SYS(sys_sysmips    , 4)
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4150 */
-        MIPS_SYS(sys_getsid     , 1)
-        MIPS_SYS(sys_fdatasync  , 0)
-        MIPS_SYS(sys_sysctl     , 1)
-        MIPS_SYS(sys_mlock      , 2)
-        MIPS_SYS(sys_munlock    , 2)    /* 4155 */
-        MIPS_SYS(sys_mlockall   , 1)
-        MIPS_SYS(sys_munlockall , 0)
-        MIPS_SYS(sys_sched_setparam, 2)
-        MIPS_SYS(sys_sched_getparam, 2)
-        MIPS_SYS(sys_sched_setscheduler, 3)     /* 4160 */
-        MIPS_SYS(sys_sched_getscheduler, 1)
-        MIPS_SYS(sys_sched_yield        , 0)
-        MIPS_SYS(sys_sched_get_priority_max, 1)
-        MIPS_SYS(sys_sched_get_priority_min, 1)
-        MIPS_SYS(sys_sched_rr_get_interval, 2)  /* 4165 */
-        MIPS_SYS(sys_nanosleep, 2)
-        MIPS_SYS(sys_mremap     , 5)
-        MIPS_SYS(sys_accept     , 3)
-        MIPS_SYS(sys_bind       , 3)
-        MIPS_SYS(sys_connect    , 3)    /* 4170 */
-        MIPS_SYS(sys_getpeername        , 3)
-        MIPS_SYS(sys_getsockname        , 3)
-        MIPS_SYS(sys_getsockopt , 5)
-        MIPS_SYS(sys_listen     , 2)
-        MIPS_SYS(sys_recv       , 4)    /* 4175 */
-        MIPS_SYS(sys_recvfrom   , 6)
-        MIPS_SYS(sys_recvmsg    , 3)
-        MIPS_SYS(sys_send       , 4)
-        MIPS_SYS(sys_sendmsg    , 3)
-        MIPS_SYS(sys_sendto     , 6)    /* 4180 */
-        MIPS_SYS(sys_setsockopt , 5)
-        MIPS_SYS(sys_shutdown   , 2)
-        MIPS_SYS(sys_socket     , 3)
-        MIPS_SYS(sys_socketpair , 4)
-        MIPS_SYS(sys_setresuid  , 3)    /* 4185 */
-        MIPS_SYS(sys_getresuid  , 3)
-        MIPS_SYS(sys_ni_syscall , 0)    /* was sys_query_module */
-        MIPS_SYS(sys_poll       , 3)
-        MIPS_SYS(sys_nfsservctl , 3)
-        MIPS_SYS(sys_setresgid  , 3)    /* 4190 */
-        MIPS_SYS(sys_getresgid  , 3)
-        MIPS_SYS(sys_prctl      , 5)
-        MIPS_SYS(sys_rt_sigreturn, 0)
-        MIPS_SYS(sys_rt_sigaction, 4)
-        MIPS_SYS(sys_rt_sigprocmask, 4) /* 4195 */
-        MIPS_SYS(sys_rt_sigpending, 2)
-        MIPS_SYS(sys_rt_sigtimedwait, 4)
-        MIPS_SYS(sys_rt_sigqueueinfo, 3)
-        MIPS_SYS(sys_rt_sigsuspend, 0)
-        MIPS_SYS(sys_pread64    , 6)    /* 4200 */
-        MIPS_SYS(sys_pwrite64   , 6)
-        MIPS_SYS(sys_chown      , 3)
-        MIPS_SYS(sys_getcwd     , 2)
-        MIPS_SYS(sys_capget     , 2)
-        MIPS_SYS(sys_capset     , 2)    /* 4205 */
-        MIPS_SYS(sys_sigaltstack        , 2)
-        MIPS_SYS(sys_sendfile   , 4)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_mmap2      , 6)    /* 4210 */
-        MIPS_SYS(sys_truncate64 , 4)
-        MIPS_SYS(sys_ftruncate64        , 4)
-        MIPS_SYS(sys_stat64     , 2)
-        MIPS_SYS(sys_lstat64    , 2)
-        MIPS_SYS(sys_fstat64    , 2)    /* 4215 */
-        MIPS_SYS(sys_pivot_root , 2)
-        MIPS_SYS(sys_mincore    , 3)
-        MIPS_SYS(sys_madvise    , 3)
-        MIPS_SYS(sys_getdents64 , 3)
-        MIPS_SYS(sys_fcntl64    , 3)    /* 4220 */
-        MIPS_SYS(sys_ni_syscall , 0)
-        MIPS_SYS(sys_gettid     , 0)
-        MIPS_SYS(sys_readahead  , 5)
-        MIPS_SYS(sys_setxattr   , 5)
-        MIPS_SYS(sys_lsetxattr  , 5)    /* 4225 */
-        MIPS_SYS(sys_fsetxattr  , 5)
-        MIPS_SYS(sys_getxattr   , 4)
-        MIPS_SYS(sys_lgetxattr  , 4)
-        MIPS_SYS(sys_fgetxattr  , 4)
-        MIPS_SYS(sys_listxattr  , 3)    /* 4230 */
-        MIPS_SYS(sys_llistxattr , 3)
-        MIPS_SYS(sys_flistxattr , 3)
-        MIPS_SYS(sys_removexattr        , 2)
-        MIPS_SYS(sys_lremovexattr, 2)
-        MIPS_SYS(sys_fremovexattr, 2)   /* 4235 */
-        MIPS_SYS(sys_tkill      , 2)
-        MIPS_SYS(sys_sendfile64 , 5)
-        MIPS_SYS(sys_futex      , 6)
-        MIPS_SYS(sys_sched_setaffinity, 3)
-        MIPS_SYS(sys_sched_getaffinity, 3)      /* 4240 */
-        MIPS_SYS(sys_io_setup   , 2)
-        MIPS_SYS(sys_io_destroy , 1)
-        MIPS_SYS(sys_io_getevents, 5)
-        MIPS_SYS(sys_io_submit  , 3)
-        MIPS_SYS(sys_io_cancel  , 3)    /* 4245 */
-        MIPS_SYS(sys_exit_group , 1)
-        MIPS_SYS(sys_lookup_dcookie, 3)
-        MIPS_SYS(sys_epoll_create, 1)
-        MIPS_SYS(sys_epoll_ctl  , 4)
-        MIPS_SYS(sys_epoll_wait , 3)    /* 4250 */
-        MIPS_SYS(sys_remap_file_pages, 5)
-        MIPS_SYS(sys_set_tid_address, 1)
-        MIPS_SYS(sys_restart_syscall, 0)
-        MIPS_SYS(sys_fadvise64_64, 7)
-        MIPS_SYS(sys_statfs64   , 3)    /* 4255 */
-        MIPS_SYS(sys_fstatfs64  , 2)
-        MIPS_SYS(sys_timer_create, 3)
-        MIPS_SYS(sys_timer_settime, 4)
-        MIPS_SYS(sys_timer_gettime, 2)
-        MIPS_SYS(sys_timer_getoverrun, 1)       /* 4260 */
-        MIPS_SYS(sys_timer_delete, 1)
-        MIPS_SYS(sys_clock_settime, 2)
-        MIPS_SYS(sys_clock_gettime, 2)
-        MIPS_SYS(sys_clock_getres, 2)
-        MIPS_SYS(sys_clock_nanosleep, 4)        /* 4265 */
-        MIPS_SYS(sys_tgkill     , 3)
-        MIPS_SYS(sys_utimes     , 2)
-        MIPS_SYS(sys_mbind      , 4)
-        MIPS_SYS(sys_ni_syscall , 0)    /* sys_get_mempolicy */
-        MIPS_SYS(sys_ni_syscall , 0)    /* 4270 sys_set_mempolicy */
-        MIPS_SYS(sys_mq_open    , 4)
-        MIPS_SYS(sys_mq_unlink  , 1)
-        MIPS_SYS(sys_mq_timedsend, 5)
-        MIPS_SYS(sys_mq_timedreceive, 5)
-        MIPS_SYS(sys_mq_notify  , 2)    /* 4275 */
-        MIPS_SYS(sys_mq_getsetattr, 3)
-        MIPS_SYS(sys_ni_syscall , 0)    /* sys_vserver */
-        MIPS_SYS(sys_waitid     , 4)
-        MIPS_SYS(sys_ni_syscall , 0)    /* available, was setaltroot */
-        MIPS_SYS(sys_add_key    , 5)
-        MIPS_SYS(sys_request_key, 4)
-        MIPS_SYS(sys_keyctl     , 5)
-        MIPS_SYS(sys_set_thread_area, 1)
-        MIPS_SYS(sys_inotify_init, 0)
-        MIPS_SYS(sys_inotify_add_watch, 3) /* 4285 */
-        MIPS_SYS(sys_inotify_rm_watch, 2)
-        MIPS_SYS(sys_migrate_pages, 4)
-        MIPS_SYS(sys_openat, 4)
-        MIPS_SYS(sys_mkdirat, 3)
-        MIPS_SYS(sys_mknodat, 4)        /* 4290 */
-        MIPS_SYS(sys_fchownat, 5)
-        MIPS_SYS(sys_futimesat, 3)
-        MIPS_SYS(sys_fstatat64, 4)
-        MIPS_SYS(sys_unlinkat, 3)
-        MIPS_SYS(sys_renameat, 4)       /* 4295 */
-        MIPS_SYS(sys_linkat, 5)
-        MIPS_SYS(sys_symlinkat, 3)
-        MIPS_SYS(sys_readlinkat, 4)
-        MIPS_SYS(sys_fchmodat, 3)
-        MIPS_SYS(sys_faccessat, 3)      /* 4300 */
-        MIPS_SYS(sys_pselect6, 6)
-        MIPS_SYS(sys_ppoll, 5)
-        MIPS_SYS(sys_unshare, 1)
-        MIPS_SYS(sys_splice, 6)
-        MIPS_SYS(sys_sync_file_range, 7) /* 4305 */
-        MIPS_SYS(sys_tee, 4)
-        MIPS_SYS(sys_vmsplice, 4)
-        MIPS_SYS(sys_move_pages, 6)
-        MIPS_SYS(sys_set_robust_list, 2)
-        MIPS_SYS(sys_get_robust_list, 3) /* 4310 */
-        MIPS_SYS(sys_kexec_load, 4)
-        MIPS_SYS(sys_getcpu, 3)
-        MIPS_SYS(sys_epoll_pwait, 6)
-        MIPS_SYS(sys_ioprio_set, 3)
-        MIPS_SYS(sys_ioprio_get, 2)
-        MIPS_SYS(sys_utimensat, 4)
-        MIPS_SYS(sys_signalfd, 3)
-        MIPS_SYS(sys_ni_syscall, 0)     /* was timerfd */
-        MIPS_SYS(sys_eventfd, 1)
-        MIPS_SYS(sys_fallocate, 6)      /* 4320 */
-        MIPS_SYS(sys_timerfd_create, 2)
-        MIPS_SYS(sys_timerfd_gettime, 2)
-        MIPS_SYS(sys_timerfd_settime, 4)
-        MIPS_SYS(sys_signalfd4, 4)
-        MIPS_SYS(sys_eventfd2, 2)       /* 4325 */
-        MIPS_SYS(sys_epoll_create1, 1)
-        MIPS_SYS(sys_dup3, 3)
-        MIPS_SYS(sys_pipe2, 2)
-        MIPS_SYS(sys_inotify_init1, 1)
-        MIPS_SYS(sys_preadv, 5)         /* 4330 */
-        MIPS_SYS(sys_pwritev, 5)
-        MIPS_SYS(sys_rt_tgsigqueueinfo, 4)
-        MIPS_SYS(sys_perf_event_open, 5)
-        MIPS_SYS(sys_accept4, 4)
-        MIPS_SYS(sys_recvmmsg, 5)       /* 4335 */
-        MIPS_SYS(sys_fanotify_init, 2)
-        MIPS_SYS(sys_fanotify_mark, 6)
-        MIPS_SYS(sys_prlimit64, 4)
-        MIPS_SYS(sys_name_to_handle_at, 5)
-        MIPS_SYS(sys_open_by_handle_at, 3) /* 4340 */
-        MIPS_SYS(sys_clock_adjtime, 2)
-        MIPS_SYS(sys_syncfs, 1)
-        MIPS_SYS(sys_sendmmsg, 4)
-        MIPS_SYS(sys_setns, 2)
-        MIPS_SYS(sys_process_vm_readv, 6) /* 345 */
-        MIPS_SYS(sys_process_vm_writev, 6)
-        MIPS_SYS(sys_kcmp, 5)
-        MIPS_SYS(sys_finit_module, 3)
-        MIPS_SYS(sys_sched_setattr, 2)
-        MIPS_SYS(sys_sched_getattr, 3)  /* 350 */
-        MIPS_SYS(sys_renameat2, 5)
-        MIPS_SYS(sys_seccomp, 3)
-        MIPS_SYS(sys_getrandom, 3)
-        MIPS_SYS(sys_memfd_create, 2)
-        MIPS_SYS(sys_bpf, 3)            /* 355 */
-        MIPS_SYS(sys_execveat, 5)
-        MIPS_SYS(sys_userfaultfd, 1)
-        MIPS_SYS(sys_membarrier, 2)
-        MIPS_SYS(sys_mlock2, 3)
-        MIPS_SYS(sys_copy_file_range, 6) /* 360 */
-        MIPS_SYS(sys_preadv2, 6)
-        MIPS_SYS(sys_pwritev2, 6)
-        MIPS_SYS(sys_pkey_mprotect, 4)
-        MIPS_SYS(sys_pkey_alloc, 2)
-        MIPS_SYS(sys_pkey_free, 1)                 /* 365 */
-        MIPS_SYS(sys_statx, 5)
-        MIPS_SYS(sys_rseq, 4)
-        MIPS_SYS(sys_io_pgetevents, 6)
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 370 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 375 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 380 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 385 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 390 */
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYSCALL_NUMBER_UNUSED,
-        MIPS_SYS(sys_semget, 3)
-        MIPS_SYS(sys_semctl, 4)
-        MIPS_SYS(sys_shmget, 3)                    /* 395 */
-        MIPS_SYS(sys_shmctl, 3)
-        MIPS_SYS(sys_shmat, 3)
-        MIPS_SYS(sys_shmdt, 1)
-        MIPS_SYS(sys_msgget, 2)
-        MIPS_SYS(sys_msgsnd, 4)                    /* 400 */
-        MIPS_SYS(sys_msgrcv, 5)
-        MIPS_SYS(sys_msgctl, 3)
-        MIPS_SYS(sys_clock_gettime64, 2)
-        MIPS_SYS(sys_clock_settime64, 2)
-        MIPS_SYS(sys_clock_adjtime64, 2)           /* 405 */
-        MIPS_SYS(sys_clock_getres_time64, 2)
-        MIPS_SYS(sys_clock_nanosleep_time64, 4)
-        MIPS_SYS(sys_timer_gettime64, 2)
-        MIPS_SYS(sys_timer_settime64, 4)
-        MIPS_SYS(sys_timerfd_gettime64, 2)         /* 410 */
-        MIPS_SYS(sys_timerfd_settime64, 4)
-        MIPS_SYS(sys_utimensat_time64, 4)
-        MIPS_SYS(sys_pselect6_time64, 6)
-        MIPS_SYS(sys_ppoll_time64, 5)
-        MIPS_SYSCALL_NUMBER_UNUSED,                /* 415 */
-        MIPS_SYS(sys_io_pgetevents_time64, 6)
-        MIPS_SYS(sys_recvmmsg_time64, 5)
-        MIPS_SYS(sys_mq_timedsend_time64, 5)
-        MIPS_SYS(sys_mq_timedreceive_time64, 5)
-        MIPS_SYS(sys_semtimedop_time64, 4)         /* 420 */
-        MIPS_SYS(sys_rt_sigtimedwait_time64, 4)
-        MIPS_SYS(sys_futex_time64, 6)
-        MIPS_SYS(sys_sched_rr_get_interval_time64, 2)
-        MIPS_SYS(sys_pidfd_send_signal, 4)
-        MIPS_SYS(sys_io_uring_setup, 2)            /* 425 */
-        MIPS_SYS(sys_io_uring_enter, 6)
-        MIPS_SYS(sys_io_uring_register, 4)
-        MIPS_SYS(sys_open_tree, 3)
-        MIPS_SYS(sys_move_mount, 5)
-        MIPS_SYS(sys_fsopen, 2)                    /* 430 */
-        MIPS_SYS(sys_fsconfig, 5)
-        MIPS_SYS(sys_fsmount, 3)
-        MIPS_SYS(sys_fspick, 3)
-        MIPS_SYS(sys_pidfd_open, 2)
-        MIPS_SYS(sys_clone3, 2)                    /* 435 */
-#  undef MIPS_SYS
+    [   0] = 7, /* syscall */
+    [   1] = 1, /* exit */
+    [   2] = 0, /* fork */
+    [   3] = 3, /* read */
+    [   4] = 3, /* write */
+    [   5] = 3, /* open */
+    [   6] = 1, /* close */
+    [   7] = 3, /* waitpid */
+    [   8] = 2, /* creat */
+    [   9] = 2, /* link */
+    [  10] = 1, /* unlink */
+    [  11] = 3, /* execve */
+    [  12] = 1, /* chdir */
+    [  13] = 1, /* time */
+    [  14] = 3, /* mknod */
+    [  15] = 2, /* chmod */
+    [  16] = 3, /* lchown */
+    [  17] = 0, /* break */
+    [  18] = 2, /* oldstat */
+    [  19] = 3, /* lseek */
+    [  20] = 0, /* getpid */
+    [  21] = 5, /* mount */
+    [  22] = 1, /* umount */
+    [  23] = 1, /* setuid */
+    [  24] = 0, /* getuid */
+    [  25] = 1, /* stime */
+    [  26] = 4, /* ptrace */
+    [  27] = 1, /* alarm */
+    [  28] = 2, /* oldfstat */
+    [  29] = 0, /* pause */
+    [  30] = 2, /* utime */
+    [  31] = 0, /* stty */
+    [  32] = 0, /* gtty */
+    [  33] = 2, /* access */
+    [  34] = 1, /* nice */
+    [  35] = 1, /* ftime */
+    [  36] = 0, /* sync */
+    [  37] = 2, /* kill */
+    [  38] = 2, /* rename */
+    [  39] = 2, /* mkdir */
+    [  40] = 1, /* rmdir */
+    [  41] = 1, /* dup */
+    [  42] = 0, /* pipe */
+    [  43] = 1, /* times */
+    [  44] = 0, /* prof */
+    [  45] = 1, /* brk */
+    [  46] = 1, /* setgid */
+    [  47] = 0, /* getgid */
+    [  48] = 2, /* signal */
+    [  49] = 0, /* geteuid */
+    [  50] = 0, /* getegid */
+    [  51] = 1, /* acct */
+    [  52] = 2, /* umount2 */
+    [  53] = 0, /* lock */
+    [  54] = 3, /* ioctl */
+    [  55] = 3, /* fcntl */
+    [  56] = 0, /* mpx */
+    [  57] = 2, /* setpgid */
+    [  58] = 0, /* ulimit */
+    [  59] = 1, /* oldolduname */
+    [  60] = 1, /* umask */
+    [  61] = 1, /* chroot */
+    [  62] = 2, /* ustat */
+    [  63] = 2, /* dup2 */
+    [  64] = 0, /* getppid */
+    [  65] = 0, /* getpgrp */
+    [  66] = 0, /* setsid */
+    [  67] = 3, /* sigaction */
+    [  68] = 0, /* sgetmask */
+    [  69] = 1, /* ssetmask */
+    [  70] = 2, /* setreuid */
+    [  71] = 2, /* setregid */
+    [  72] = 1, /* sigsuspend */
+    [  73] = 1, /* sigpending */
+    [  74] = 2, /* sethostname */
+    [  75] = 2, /* setrlimit */
+    [  76] = 2, /* getrlimit */
+    [  77] = 2, /* getrusage */
+    [  78] = 2, /* gettimeofday */
+    [  79] = 2, /* settimeofday */
+    [  80] = 2, /* getgroups */
+    [  81] = 2, /* setgroups */
+    [  82] = 0, /* reserved82 */
+    [  83] = 2, /* symlink */
+    [  84] = 2, /* oldlstat */
+    [  85] = 3, /* readlink */
+    [  86] = 1, /* uselib */
+    [  87] = 2, /* swapon */
+    [  88] = 4, /* reboot */
+    [  89] = 3, /* readdir */
+    [  90] = 6, /* mmap */
+    [  91] = 2, /* munmap */
+    [  92] = 2, /* truncate */
+    [  93] = 2, /* ftruncate */
+    [  94] = 2, /* fchmod */
+    [  95] = 3, /* fchown */
+    [  96] = 2, /* getpriority */
+    [  97] = 3, /* setpriority */
+    [  98] = 0, /* profil */
+    [  99] = 2, /* statfs */
+    [ 100] = 2, /* fstatfs */
+    [ 101] = 3, /* ioperm */
+    [ 102] = 2, /* socketcall */
+    [ 103] = 3, /* syslog */
+    [ 104] = 3, /* setitimer */
+    [ 105] = 2, /* getitimer */
+    [ 106] = 2, /* stat */
+    [ 107] = 2, /* lstat */
+    [ 108] = 2, /* fstat */
+    [ 109] = 1, /* olduname */
+    [ 110] = 1, /* iopl */
+    [ 111] = 0, /* vhangup */
+    [ 112] = 0, /* idle */
+    [ 113] = 5, /* vm86 */
+    [ 114] = 4, /* wait4 */
+    [ 115] = 1, /* swapoff */
+    [ 116] = 1, /* sysinfo */
+    [ 117] = 6, /* ipc */
+    [ 118] = 1, /* fsync */
+    [ 119] = 0, /* sigreturn */
+    [ 120] = 5, /* clone */
+    [ 121] = 2, /* setdomainname */
+    [ 122] = 1, /* uname */
+    [ 123] = 0, /* modify_ldt */
+    [ 124] = 1, /* adjtimex */
+    [ 125] = 3, /* mprotect */
+    [ 126] = 3, /* sigprocmask */
+    [ 127] = 2, /* create_module */
+    [ 128] = 3, /* init_module */
+    [ 129] = 2, /* delete_module */
+    [ 130] = 1, /* get_kernel_syms */
+    [ 131] = 4, /* quotactl */
+    [ 132] = 1, /* getpgid */
+    [ 133] = 1, /* fchdir */
+    [ 134] = 2, /* bdflush */
+    [ 135] = 3, /* sysfs */
+    [ 136] = 1, /* personality */
+    [ 137] = 0, /* afs_syscall */
+    [ 138] = 1, /* setfsuid */
+    [ 139] = 1, /* setfsgid */
+    [ 140] = 5, /* _llseek */
+    [ 141] = 3, /* getdents */
+    [ 142] = 5, /* _newselect */
+    [ 143] = 2, /* flock */
+    [ 144] = 3, /* msync */
+    [ 145] = 3, /* readv */
+    [ 146] = 3, /* writev */
+    [ 147] = 3, /* cacheflush */
+    [ 148] = 3, /* cachectl */
+    [ 149] = 4, /* sysmips */
+    [ 150] = 0, /* setup */
+    [ 151] = 1, /* getsid */
+    [ 152] = 1, /* fdatasync */
+    [ 153] = 1, /* _sysctl */
+    [ 154] = 2, /* mlock */
+    [ 155] = 2, /* munlock */
+    [ 156] = 1, /* mlockall */
+    [ 157] = 0, /* munlockall */
+    [ 158] = 2, /* sched_setparam */
+    [ 159] = 2, /* sched_getparam */
+    [ 160] = 3, /* sched_setscheduler */
+    [ 161] = 1, /* sched_getscheduler */
+    [ 162] = 0, /* sched_yield */
+    [ 163] = 1, /* sched_get_priority_max */
+    [ 164] = 1, /* sched_get_priority_min */
+    [ 165] = 2, /* sched_rr_get_interval */
+    [ 166] = 2, /* nanosleep */
+    [ 167] = 5, /* mremap */
+    [ 168] = 3, /* accept */
+    [ 169] = 3, /* bind */
+    [ 170] = 3, /* connect */
+    [ 171] = 3, /* getpeername */
+    [ 172] = 3, /* getsockname */
+    [ 173] = 5, /* getsockopt */
+    [ 174] = 2, /* listen */
+    [ 175] = 4, /* recv */
+    [ 176] = 6, /* recvfrom */
+    [ 177] = 3, /* recvmsg */
+    [ 178] = 4, /* send */
+    [ 179] = 3, /* sendmsg */
+    [ 180] = 6, /* sendto */
+    [ 181] = 5, /* setsockopt */
+    [ 182] = 2, /* shutdown */
+    [ 183] = 3, /* socket */
+    [ 184] = 4, /* socketpair */
+    [ 185] = 3, /* setresuid */
+    [ 186] = 3, /* getresuid */
+    [ 187] = 5, /* query_module */
+    [ 188] = 3, /* poll */
+    [ 189] = 3, /* nfsservctl */
+    [ 190] = 3, /* setresgid */
+    [ 191] = 3, /* getresgid */
+    [ 192] = 5, /* prctl */
+    [ 193] = 0, /* rt_sigreturn */
+    [ 194] = 4, /* rt_sigaction */
+    [ 195] = 4, /* rt_sigprocmask */
+    [ 196] = 2, /* rt_sigpending */
+    [ 197] = 4, /* rt_sigtimedwait */
+    [ 198] = 3, /* rt_sigqueueinfo */
+    [ 199] = 2, /* rt_sigsuspend */
+    [ 200] = 6, /* pread64 */
+    [ 201] = 6, /* pwrite64 */
+    [ 202] = 3, /* chown */
+    [ 203] = 2, /* getcwd */
+    [ 204] = 2, /* capget */
+    [ 205] = 2, /* capset */
+    [ 206] = 2, /* sigaltstack */
+    [ 207] = 4, /* sendfile */
+    [ 208] = 5, /* getpmsg */
+    [ 209] = 5, /* putpmsg */
+    [ 210] = 6, /* mmap2 */
+    [ 211] = 4, /* truncate64 */
+    [ 212] = 4, /* ftruncate64 */
+    [ 213] = 2, /* stat64 */
+    [ 214] = 2, /* lstat64 */
+    [ 215] = 2, /* fstat64 */
+    [ 216] = 2, /* pivot_root */
+    [ 217] = 3, /* mincore */
+    [ 218] = 3, /* madvise */
+    [ 219] = 3, /* getdents64 */
+    [ 220] = 3, /* fcntl64 */
+    [ 221] = 0, /* reserved221 */
+    [ 222] = 0, /* gettid */
+    [ 223] = 5, /* readahead */
+    [ 224] = 5, /* setxattr */
+    [ 225] = 5, /* lsetxattr */
+    [ 226] = 5, /* fsetxattr */
+    [ 227] = 4, /* getxattr */
+    [ 228] = 4, /* lgetxattr */
+    [ 229] = 4, /* fgetxattr */
+    [ 230] = 3, /* listxattr */
+    [ 231] = 3, /* llistxattr */
+    [ 232] = 3, /* flistxattr */
+    [ 233] = 2, /* removexattr */
+    [ 234] = 2, /* lremovexattr */
+    [ 235] = 2, /* fremovexattr */
+    [ 236] = 2, /* tkill */
+    [ 237] = 4, /* sendfile64 */
+    [ 238] = 6, /* futex */
+    [ 239] = 3, /* sched_setaffinity */
+    [ 240] = 3, /* sched_getaffinity */
+    [ 241] = 2, /* io_setup */
+    [ 242] = 1, /* io_destroy */
+    [ 243] = 5, /* io_getevents */
+    [ 244] = 3, /* io_submit */
+    [ 245] = 3, /* io_cancel */
+    [ 246] = 1, /* exit_group */
+    [ 247] = 4, /* lookup_dcookie */
+    [ 248] = 1, /* epoll_create */
+    [ 249] = 4, /* epoll_ctl */
+    [ 250] = 4, /* epoll_wait */
+    [ 251] = 5, /* remap_file_pages */
+    [ 252] = 1, /* set_tid_address */
+    [ 253] = 0, /* restart_syscall */
+    [ 254] = 7, /* fadvise64 */
+    [ 255] = 3, /* statfs64 */
+    [ 256] = 3, /* fstatfs64 */
+    [ 257] = 3, /* timer_create */
+    [ 258] = 4, /* timer_settime */
+    [ 259] = 2, /* timer_gettime */
+    [ 260] = 1, /* timer_getoverrun */
+    [ 261] = 1, /* timer_delete */
+    [ 262] = 2, /* clock_settime */
+    [ 263] = 2, /* clock_gettime */
+    [ 264] = 2, /* clock_getres */
+    [ 265] = 4, /* clock_nanosleep */
+    [ 266] = 3, /* tgkill */
+    [ 267] = 2, /* utimes */
+    [ 268] = 6, /* mbind */
+    [ 269] = 5, /* get_mempolicy */
+    [ 270] = 3, /* set_mempolicy */
+    [ 271] = 4, /* mq_open */
+    [ 272] = 1, /* mq_unlink */
+    [ 273] = 5, /* mq_timedsend */
+    [ 274] = 5, /* mq_timedreceive */
+    [ 275] = 2, /* mq_notify */
+    [ 276] = 3, /* mq_getsetattr */
+    [ 277] = 5, /* vserver */
+    [ 278] = 5, /* waitid */
+    [ 279] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 280] = 5, /* add_key */
+    [ 281] = 4, /* request_key */
+    [ 282] = 5, /* keyctl */
+    [ 283] = 1, /* set_thread_area */
+    [ 284] = 0, /* inotify_init */
+    [ 285] = 3, /* inotify_add_watch */
+    [ 286] = 2, /* inotify_rm_watch */
+    [ 287] = 4, /* migrate_pages */
+    [ 288] = 4, /* openat */
+    [ 289] = 3, /* mkdirat */
+    [ 290] = 4, /* mknodat */
+    [ 291] = 5, /* fchownat */
+    [ 292] = 3, /* futimesat */
+    [ 293] = 4, /* fstatat64 */
+    [ 294] = 3, /* unlinkat */
+    [ 295] = 4, /* renameat */
+    [ 296] = 5, /* linkat */
+    [ 297] = 3, /* symlinkat */
+    [ 298] = 4, /* readlinkat */
+    [ 299] = 3, /* fchmodat */
+    [ 300] = 3, /* faccessat */
+    [ 301] = 6, /* pselect6 */
+    [ 302] = 5, /* ppoll */
+    [ 303] = 1, /* unshare */
+    [ 304] = 6, /* splice */
+    [ 305] = 7, /* sync_file_range */
+    [ 306] = 4, /* tee */
+    [ 307] = 4, /* vmsplice */
+    [ 308] = 6, /* move_pages */
+    [ 309] = 2, /* set_robust_list */
+    [ 310] = 3, /* get_robust_list */
+    [ 311] = 4, /* kexec_load */
+    [ 312] = 3, /* getcpu */
+    [ 313] = 6, /* epoll_pwait */
+    [ 314] = 3, /* ioprio_set */
+    [ 315] = 2, /* ioprio_get */
+    [ 316] = 4, /* utimensat */
+    [ 317] = 3, /* signalfd */
+    [ 318] = 4, /* timerfd */
+    [ 319] = 1, /* eventfd */
+    [ 320] = 6, /* fallocate */
+    [ 321] = 2, /* timerfd_create */
+    [ 322] = 2, /* timerfd_gettime */
+    [ 323] = 4, /* timerfd_settime */
+    [ 324] = 4, /* signalfd4 */
+    [ 325] = 2, /* eventfd2 */
+    [ 326] = 1, /* epoll_create1 */
+    [ 327] = 3, /* dup3 */
+    [ 328] = 2, /* pipe2 */
+    [ 329] = 1, /* inotify_init1 */
+    [ 330] = 5, /* preadv */
+    [ 331] = 5, /* pwritev */
+    [ 332] = 4, /* rt_tgsigqueueinfo */
+    [ 333] = 5, /* perf_event_open */
+    [ 334] = 4, /* accept4 */
+    [ 335] = 5, /* recvmmsg */
+    [ 336] = 2, /* fanotify_init */
+    [ 337] = 6, /* fanotify_mark */
+    [ 338] = 4, /* prlimit64 */
+    [ 339] = 5, /* name_to_handle_at */
+    [ 340] = 3, /* open_by_handle_at */
+    [ 341] = 2, /* clock_adjtime */
+    [ 342] = 1, /* syncfs */
+    [ 343] = 4, /* sendmmsg */
+    [ 344] = 2, /* setns */
+    [ 345] = 6, /* process_vm_readv */
+    [ 346] = 6, /* process_vm_writev */
+    [ 347] = 5, /* kcmp */
+    [ 348] = 3, /* finit_module */
+    [ 349] = 3, /* sched_setattr */
+    [ 350] = 4, /* sched_getattr */
+    [ 351] = 5, /* renameat2 */
+    [ 352] = 3, /* seccomp */
+    [ 353] = 3, /* getrandom */
+    [ 354] = 2, /* memfd_create */
+    [ 355] = 3, /* bpf */
+    [ 356] = 5, /* execveat */
+    [ 357] = 1, /* userfaultfd */
+    [ 358] = 2, /* membarrier */
+    [ 359] = 3, /* mlock2 */
+    [ 360] = 6, /* copy_file_range */
+    [ 361] = 6, /* preadv2 */
+    [ 362] = 6, /* pwritev2 */
+    [ 363] = 4, /* pkey_mprotect */
+    [ 364] = 2, /* pkey_alloc */
+    [ 365] = 1, /* pkey_free */
+    [ 366] = 5, /* statx */
+    [ 367] = 4, /* rseq */
+    [ 368] = 6, /* io_pgetevents */
+    [ 369] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 370] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 371] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 372] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 373] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 374] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 375] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 376] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 377] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 378] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 379] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 380] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 381] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 382] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 383] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 384] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 385] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 386] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 387] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 388] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 389] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 390] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 391] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 392] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 393] = 3, /* semget */
+    [ 394] = 4, /* semctl */
+    [ 395] = 3, /* shmget */
+    [ 396] = 3, /* shmctl */
+    [ 397] = 3, /* shmat */
+    [ 398] = 1, /* shmdt */
+    [ 399] = 2, /* msgget */
+    [ 400] = 4, /* msgsnd */
+    [ 401] = 5, /* msgrcv */
+    [ 402] = 3, /* msgctl */
+    [ 403] = 2, /* clock_gettime64 */
+    [ 404] = 2, /* clock_settime64 */
+    [ 405] = 2, /* clock_adjtime64 */
+    [ 406] = 2, /* clock_getres_time64 */
+    [ 407] = 4, /* clock_nanosleep_time64 */
+    [ 408] = 2, /* timer_gettime64 */
+    [ 409] = 4, /* timer_settime64 */
+    [ 410] = 2, /* timerfd_gettime64 */
+    [ 411] = 4, /* timerfd_settime64 */
+    [ 412] = 4, /* utimensat_time64 */
+    [ 413] = 6, /* pselect6_time64 */
+    [ 414] = 5, /* ppoll_time64 */
+    [ 415] = MIPS_SYSCALL_NUMBER_UNUSED,
+    [ 416] = 6, /* io_pgetevents_time64 */
+    [ 417] = 5, /* recvmmsg_time64 */
+    [ 418] = 5, /* mq_timedsend_time64 */
+    [ 419] = 5, /* mq_timedreceive_time64 */
+    [ 420] = 4, /* semtimedop_time64 */
+    [ 421] = 4, /* rt_sigtimedwait_time64 */
+    [ 422] = 6, /* futex_time64 */
+    [ 423] = 2, /* sched_rr_get_interval_time64 */
+    [ 424] = 4, /* pidfd_send_signal */
+    [ 425] = 2, /* io_uring_setup */
+    [ 426] = 6, /* io_uring_enter */
+    [ 427] = 4, /* io_uring_register */
+    [ 428] = 3, /* open_tree */
+    [ 429] = 5, /* move_mount */
+    [ 430] = 2, /* fsopen */
+    [ 431] = 5, /* fsconfig */
+    [ 432] = 3, /* fsmount */
+    [ 433] = 3, /* fspick */
+    [ 434] = 2, /* pidfd_open */
+    [ 435] = 2, /* clone3 */
scripts/update-mips-syscall-args.sh new file +57 -0

57 lines not on this page · raw message

Signature · 1 line
2.24.1
#25 lore raw
In reply to Laurent Vivier
Quoted 4 lines · Laurent Vivier

This series copies the files syscall.tbl from linux v5.5 and generates the file syscall_nr.h from them.

Quoted 8 lines

This is done for all the QEMU targets that have a syscall.tbl in the linux source tree: mips, mips64, i386, x86_64, sparc, s390x, ppc, arm, microblaze, sh4, xtensa, m68k, hppa and alpha.

tilegx and cris are depecrated in linux (tilegx has no maintainer in QEMU)

aarch64, nios2, openrisc and riscv have no syscall.tbl in linux and files are generated manually with the help of a script from the asm-generic/unistd.h

Incidentally I hear from Arnd Bergmann that eventually the plan is to have a syscall.tbl equivalent for the asm-generic users, though I don't think there's a timescale for when this might happen.

thanks
-- PMM

#26 lore raw

Le 10/03/2020 à 12:15, Peter Maydell a écrit :

Quoted 9 lines · Laurent Vivier
Quoted 8 lines

This series copies the files syscall.tbl from linux v5.5 and generates the file syscall_nr.h from them.

This is done for all the QEMU targets that have a syscall.tbl in the linux source tree: mips, mips64, i386, x86_64, sparc, s390x, ppc, arm, microblaze, sh4, xtensa, m68k, hppa and alpha.

Quoted 8 lines
Quoted 4 lines

tilegx and cris are depecrated in linux (tilegx has no maintainer in QEMU)

aarch64, nios2, openrisc and riscv have no syscall.tbl in linux and files are generated manually with the help of a script from the asm-generic/unistd.h

Incidentally I hear from Arnd Bergmann that eventually the plan is to have a syscall.tbl equivalent for the asm-generic users, though I don't think there's a timescale for when this might happen.

Thank you for the information.

Anyway I've sent a second series to generate the syscall_nr.h file from the asm-generic file.

Laurent

#27 lore raw
In reply to Laurent Vivier
Patchew URL: https://patchew.org/QEMU/[email protected]/

Patchew URL: https://patchew.org/QEMU/[email protected]/

Hi,

This series failed the asan build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally.

=== TEST SCRIPT BEGIN ===
#!/bin/bash
export ARCH=x86_64
make docker-image-fedora V=1 NETWORK=1
time make docker-test-debug@fedora TARGET_LIST=x86_64-softmmu J=14 NETWORK=1 === TEST SCRIPT END ===

PASS 1 fdc-test /x86_64/fdc/cmos
PASS 2 fdc-test /x86_64/fdc/no_media_on_start
PASS 3 fdc-test /x86_64/fdc/read_without_media
==6533==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 fdc-test /x86_64/fdc/media_change
PASS 5 fdc-test /x86_64/fdc/sense_interrupt
PASS 6 fdc-test /x86_64/fdc/relative_seek
---
PASS 32 test-opts-visitor /visitor/opts/range/beyond
PASS 33 test-opts-visitor /visitor/opts/dict/unvisited
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-coroutine -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-coroutine"
==6575==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==6575==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffc1dbf000; bottom 0x7fc9c0620000; size: 0x00360179f000 (231953002496)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-coroutine /basic/no-dangling-access
---
PASS 11 test-aio /aio/event/wait
PASS 12 test-aio /aio/event/flush
PASS 13 test-aio /aio/event/wait/no-flush-cb
==6590==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 test-aio /aio/timer/schedule
PASS 15 test-aio /aio/coroutine/queue-chaining
PASS 16 test-aio /aio-gsource/flush
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/ide-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ide-test" PASS 28 test-aio /aio-gsource/timer/schedule
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-aio-multithread -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-aio-multithread"
==6601==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-aio-multithread /aio/multi/lifecycle
==6598==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 ide-test /x86_64/ide/identify
==6618==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 test-aio-multithread /aio/multi/schedule
PASS 2 ide-test /x86_64/ide/flush
==6629==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 ide-test /x86_64/ide/bmdma/simple_rw
PASS 3 test-aio-multithread /aio/multi/mutex/contended
==6635==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 ide-test /x86_64/ide/bmdma/trim
==6646==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 test-aio-multithread /aio/multi/mutex/handoff
PASS 5 test-aio-multithread /aio/multi/mutex/mcs
PASS 6 test-aio-multithread /aio/multi/mutex/pthread
---
PASS 6 test-throttle /throttle/detach_attach
PASS 7 test-throttle /throttle/config_functions
PASS 8 test-throttle /throttle/accounting
==6663==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-throttle /throttle/groups
PASS 10 test-throttle /throttle/config/enabled
PASS 11 test-throttle /throttle/config/conflicting
---
PASS 14 test-throttle /throttle/config/max
PASS 15 test-throttle /throttle/config/iops_size
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-thread-pool -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-thread-pool"
==6667==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-thread-pool /thread-pool/submit
PASS 2 test-thread-pool /thread-pool/submit-aio
PASS 3 test-thread-pool /thread-pool/submit-co
PASS 4 test-thread-pool /thread-pool/submit-many
==6734==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 test-thread-pool /thread-pool/cancel
PASS 6 test-thread-pool /thread-pool/cancel-async
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-hbitmap -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-hbitmap"
---
PASS 14 test-hbitmap /hbitmap/set/twice
PASS 15 test-hbitmap /hbitmap/set/overlap
PASS 16 test-hbitmap /hbitmap/reset/empty
==6744==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 17 test-hbitmap /hbitmap/reset/general
PASS 18 test-hbitmap /hbitmap/reset/all
PASS 19 test-hbitmap /hbitmap/truncate/nop
---
PASS 28 test-hbitmap /hbitmap/truncate/shrink/medium
PASS 29 test-hbitmap /hbitmap/truncate/shrink/large
PASS 30 test-hbitmap /hbitmap/meta/zero
==6750==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 31 test-hbitmap /hbitmap/meta/one
PASS 32 test-hbitmap /hbitmap/meta/byte
PASS 33 test-hbitmap /hbitmap/meta/word
---
PASS 44 test-hbitmap /hbitmap/next_dirty_area/next_dirty_area_4
PASS 45 test-hbitmap /hbitmap/next_dirty_area/next_dirty_area_after_truncate
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-bdrv-drain -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bdrv-drain"
==6757==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bdrv-drain /bdrv-drain/nested
PASS 2 test-bdrv-drain /bdrv-drain/multiparent
PASS 3 test-bdrv-drain /bdrv-drain/set_aio_context
---
PASS 41 test-bdrv-drain /bdrv-drain/bdrv_drop_intermediate/poll
PASS 42 test-bdrv-drain /bdrv-drain/replace_child/mid-drain
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-bdrv-graph-mod -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bdrv-graph-mod"
==6796==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bdrv-graph-mod /bdrv-graph-mod/update-perm-tree
PASS 2 test-bdrv-graph-mod /bdrv-graph-mod/should-update-child
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-blockjob -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-blockjob"
==6802==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-blockjob /blockjob/ids
PASS 2 test-blockjob /blockjob/cancel/created
PASS 3 test-blockjob /blockjob/cancel/running
---
PASS 7 test-blockjob /blockjob/cancel/pending
PASS 8 test-blockjob /blockjob/cancel/concluded
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-blockjob-txn -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-blockjob-txn"
==6806==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-blockjob-txn /single/success
PASS 2 test-blockjob-txn /single/failure
PASS 3 test-blockjob-txn /single/cancel
---
PASS 6 test-blockjob-txn /pair/cancel
PASS 7 test-blockjob-txn /pair/fail-cancel-race
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-block-backend -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-block-backend"
==6798==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==6813==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-block-backend /block-backend/drain_aio_error
PASS 2 test-block-backend /block-backend/drain_all_aio_error
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-block-iothread -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-block-iothread"
==6818==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-block-iothread /sync-op/pread
PASS 2 test-block-iothread /sync-op/pwrite
PASS 3 test-block-iothread /sync-op/load_vmstate
---
PASS 15 test-block-iothread /propagate/diamond
PASS 16 test-block-iothread /propagate/mirror
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-image-locking -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-image-locking"
==6838==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-image-locking /image-locking/basic
PASS 2 test-image-locking /image-locking/set-perm-abort
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-x86-cpuid -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-x86-cpuid"
---
PASS 1 rcutorture /rcu/torture/1reader
PASS 2 rcutorture /rcu/torture/10readers
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-rcu-list -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-list"
==6896==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-rcu-list /rcu/qlist/single-threaded
PASS 2 test-rcu-list /rcu/qlist/short-few
PASS 3 test-rcu-list /rcu/qlist/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-rcu-simpleq -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-simpleq"
PASS 1 test-rcu-simpleq /rcu/qsimpleq/single-threaded
PASS 2 test-rcu-simpleq /rcu/qsimpleq/short-few
==6941==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-rcu-simpleq /rcu/qsimpleq/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-rcu-tailq -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-tailq"
PASS 1 test-rcu-tailq /rcu/qtailq/single-threaded
PASS 2 test-rcu-tailq /rcu/qtailq/short-few
==7001==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-rcu-tailq /rcu/qtailq/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-rcu-slist -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-slist"
PASS 1 test-rcu-slist /rcu/qslist/single-threaded
---
PASS 7 test-qdist /qdist/binning/expand
PASS 8 test-qdist /qdist/binning/shrink
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-qht -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qht"
==7040==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 ide-test /x86_64/ide/bmdma/various_prdts
==7053==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7053==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe76b05000; bottom 0x7f1498dba000; size: 0x00e9ddd4b000 (1004449083392)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 6 ide-test /x86_64/ide/bmdma/no_busmaster
PASS 7 ide-test /x86_64/ide/flush/nodev
==7064==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 ide-test /x86_64/ide/flush/empty_drive
==7069==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 ide-test /x86_64/ide/flush/retry_pci
==7075==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 ide-test /x86_64/ide/flush/retry_isa
==7081==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 ide-test /x86_64/ide/cdrom/pio
==7087==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 ide-test /x86_64/ide/cdrom/pio_large
==7093==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 ide-test /x86_64/ide/cdrom/dma
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/ahci-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ahci-test" ==7107==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 ahci-test /x86_64/ahci/sanity
PASS 1 test-qht /qht/mode/default
PASS 2 test-qht /qht/mode/resize
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-qht-par -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qht-par"
==7113==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 ahci-test /x86_64/ahci/pci_spec
==7128==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-qht-par /qht/parallel/2threads-0%updates-1s
PASS 3 ahci-test /x86_64/ahci/pci_enable
==7135==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 ahci-test /x86_64/ahci/hba_spec
PASS 2 test-qht-par /qht/parallel/2threads-20%updates-1s
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-bitops -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bitops"
==7146==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bitops /bitops/sextract32
PASS 2 test-bitops /bitops/sextract64
PASS 3 test-bitops /bitops/half_shuffle32
---
PASS 1 check-qom-interface /qom/interface/direct_impl
PASS 2 check-qom-interface /qom/interface/intermediate_impl
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/check-qom-proplist -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="check-qom-proplist"
==7165==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 check-qom-proplist /qom/proplist/createlist
PASS 2 check-qom-proplist /qom/proplist/createv
PASS 3 check-qom-proplist /qom/proplist/createcmdline
---
PASS 9 test-keyval /keyval/visit/alternate
PASS 10 test-keyval /keyval/visit/any
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-write-threshold -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-write-threshold"
==7190==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-write-threshold /write-threshold/not-set-on-init
PASS 2 test-write-threshold /write-threshold/set-get
PASS 3 test-write-threshold /write-threshold/multi-set-get
---
PASS 27 test-crypto-cipher /crypto/cipher/null-iv
PASS 28 test-crypto-cipher /crypto/cipher/short-plaintext
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-crypto-secret -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-secret"
==7212==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-secret /crypto/secret/direct
PASS 2 test-crypto-secret /crypto/secret/indirect/good
PASS 3 test-crypto-secret /crypto/secret/indirect/badfile
---
PASS 16 test-crypto-secret /crypto/secret/crypt/badiv
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-crypto-tlscredsx509 -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-tlscredsx509"
PASS 8 ahci-test /x86_64/ahci/reset
==7230==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7230==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc51ae2000; bottom 0x7f6d621fe000; size: 0x008eef8e4000 (613904433152)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 9 ahci-test /x86_64/ahci/io/pio/lba28/simple/zero
==7236==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7236==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe26b87000; bottom 0x7f8d137fe000; size: 0x007113389000 (485653778432)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 10 ahci-test /x86_64/ahci/io/pio/lba28/simple/low
PASS 1 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/perfectserver
PASS 2 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/perfectclient
==7242==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca1
==7242==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc11fa1000; bottom 0x7f75df9fe000; size: 0x0086325a3000 (576370388992)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 11 ahci-test /x86_64/ahci/io/pio/lba28/simple/high
==7248==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7248==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe02735000; bottom 0x7f4483ffe000; size: 0x00b97e737000 (796690444288)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 12 ahci-test /x86_64/ahci/io/pio/lba28/double/zero
==7254==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7254==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe1712e000; bottom 0x7f3f7fdfe000; size: 0x00be97330000 (818580488192)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 13 ahci-test /x86_64/ahci/io/pio/lba28/double/low
==7260==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7260==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffe6041000; bottom 0x7f4f0d3fe000; size: 0x00b0d8c43000 (759550980096)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 14 ahci-test /x86_64/ahci/io/pio/lba28/double/high
==7266==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca2
==7266==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffed3ab6000; bottom 0x7f48dd1fe000; size: 0x00b5f68b8000 (781525417984)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 5 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca3
---
PASS 7 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca2
PASS 8 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca3
PASS 15 ahci-test /x86_64/ahci/io/pio/lba28/long/zero
==7272==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver1
==7272==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffca8b66000; bottom 0x7f4e72124000; size: 0x00ae36a42000 (748241035264)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 16 ahci-test /x86_64/ahci/io/pio/lba28/long/low
PASS 10 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver2
==7278==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver3
PASS 12 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver4
==7278==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffedeac4000; bottom 0x7f1878724000; size: 0x00e6663a0000 (989557555200)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 13 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver5
PASS 17 ahci-test /x86_64/ahci/io/pio/lba28/long/high
==7284==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 18 ahci-test /x86_64/ahci/io/pio/lba28/short/zero
PASS 14 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver6
==7290==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 15 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver7
PASS 16 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badserver1
PASS 17 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badserver2
---
PASS 38 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingserver
PASS 39 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingclient
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-crypto-tlssession -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-tlssession"
==7296==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-tlssession /qcrypto/tlssession/psk
PASS 20 ahci-test /x86_64/ahci/io/pio/lba28/short/high
PASS 2 test-crypto-tlssession /qcrypto/tlssession/basicca
==7306==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7306==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd948d5000; bottom 0x7f4766bfe000; size: 0x00b62dcd7000 (782452486144)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 21 ahci-test /x86_64/ahci/io/pio/lba48/simple/zero
PASS 3 test-crypto-tlssession /qcrypto/tlssession/differentca
PASS 4 test-crypto-tlssession /qcrypto/tlssession/altname1
==7312==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 test-crypto-tlssession /qcrypto/tlssession/altname2
==7312==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffcbacd7000; bottom 0x7f62ef9fe000; size: 0x0099cb2d9000 (660538757120)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 22 ahci-test /x86_64/ahci/io/pio/lba48/simple/low
==7318==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 test-crypto-tlssession /qcrypto/tlssession/altname3
==7318==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe5eb70000; bottom 0x7f990d9fe000; size: 0x006551172000 (435152166912)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 23 ahci-test /x86_64/ahci/io/pio/lba48/simple/high
PASS 7 test-crypto-tlssession /qcrypto/tlssession/altname4
PASS 8 test-crypto-tlssession /qcrypto/tlssession/altname5
==7324==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7324==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffcb2aed000; bottom 0x7facf81fe000; size: 0x004fba8ef000 (342432346112)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 24 ahci-test /x86_64/ahci/io/pio/lba48/double/zero
PASS 9 test-crypto-tlssession /qcrypto/tlssession/altname6
==7330==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 test-crypto-tlssession /qcrypto/tlssession/wildcard1
==7330==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff4563b000; bottom 0x7f1ad27fe000; size: 0x00e472e3d000 (981180076032)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 11 test-crypto-tlssession /qcrypto/tlssession/wildcard2
PASS 25 ahci-test /x86_64/ahci/io/pio/lba48/double/low
PASS 12 test-crypto-tlssession /qcrypto/tlssession/wildcard3
==7336==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7336==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffe2c1b000; bottom 0x7f1b397fe000; size: 0x00e4a941d000 (982092206080)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 26 ahci-test /x86_64/ahci/io/pio/lba48/double/high
==7342==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7342==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc68a70000; bottom 0x7f3fbd724000; size: 0x00bcab34c000 (810326212608)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 13 test-crypto-tlssession /qcrypto/tlssession/wildcard4
PASS 27 ahci-test /x86_64/ahci/io/pio/lba48/long/zero
PASS 14 test-crypto-tlssession /qcrypto/tlssession/wildcard5
PASS 15 test-crypto-tlssession /qcrypto/tlssession/wildcard6
==7348==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7348==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff7a69e000; bottom 0x7fbff3724000; size: 0x003f86f7a000 (272847314944)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 16 test-crypto-tlssession /qcrypto/tlssession/cachain
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-qga -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qga"
PASS 28 ahci-test /x86_64/ahci/io/pio/lba48/long/low
==7362==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-qga /qga/sync-delimited
PASS 2 test-qga /qga/sync
PASS 3 test-qga /qga/ping
==7362==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffefec96000; bottom 0x7fcb86d7c000; size: 0x003377f1a000 (221055655936)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 4 test-qga /qga/info
---
PASS 16 test-qga /qga/invalid-args
PASS 17 test-qga /qga/fsfreeze-status
PASS 29 ahci-test /x86_64/ahci/io/pio/lba48/long/high
==7371==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 18 test-qga /qga/blacklist
PASS 19 test-qga /qga/config
PASS 20 test-qga /qga/guest-exec
PASS 21 test-qga /qga/guest-exec-invalid
PASS 30 ahci-test /x86_64/ahci/io/pio/lba48/short/zero
==7389==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 31 ahci-test /x86_64/ahci/io/pio/lba48/short/low
PASS 22 test-qga /qga/guest-get-osinfo
PASS 23 test-qga /qga/guest-get-host-name
PASS 24 test-qga /qga/guest-get-timezone
PASS 25 test-qga /qga/guest-get-users
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-timed-average -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-timed-average"
==7395==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-timed-average /timed-average/average
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-util-filemonitor -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-util-filemonitor"
PASS 1 test-util-filemonitor /util/filemonitor
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-authz-simple -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-authz-simple"
PASS 1 test-authz-simple /authz/simple
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-authz-list -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-authz-list"
==7415==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-authz-list /auth/list/complex
PASS 2 test-authz-list /auth/list/add-remove
PASS 3 test-authz-list /auth/list/default/deny
---
PASS 4 test-io-channel-file /io/channel/pipe/sync
PASS 5 test-io-channel-file /io/channel/pipe/async
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-io-channel-tls -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-tls"
==7445==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 34 ahci-test /x86_64/ahci/io/dma/lba28/retry
PASS 1 test-io-channel-tls /qio/channel/tls/basic
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-io-channel-command -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-command"
==7497==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-io-channel-command /io/channel/command/fifo/sync
PASS 2 test-io-channel-command /io/channel/command/fifo/async
PASS 3 test-io-channel-command /io/channel/command/echo/sync
---
PASS 17 test-crypto-pbkdf /crypto/pbkdf/nonrfc/sha384/iter1200
PASS 18 test-crypto-pbkdf /crypto/pbkdf/nonrfc/ripemd160/iter1200
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-crypto-ivgen -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-ivgen"
==7515==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-ivgen /crypto/ivgen/plain/1
PASS 2 test-crypto-ivgen /crypto/ivgen/plain/1f2e3d4c
PASS 3 test-crypto-ivgen /crypto/ivgen/plain/1f2e3d4c5b6a7988
---
PASS 17 test-crypto-xts /crypto/xts/t-21-key-32-ptx-31/basic
PASS 18 test-crypto-xts /crypto/xts/t-21-key-32-ptx-31/unaligned
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-crypto-block -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-block"
==7536==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-block /crypto/block/qcow
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-logging -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-logging"
PASS 1 test-logging /logging/parse_range
---
PASS 4 test-logging /logging/logfile_lock_path
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-replication -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-replication"
PASS 37 ahci-test /x86_64/ahci/io/dma/lba28/simple/high
==7555==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-replication /replication/primary/read
PASS 2 test-replication /replication/primary/write
==7557==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 38 ahci-test /x86_64/ahci/io/dma/lba28/double/zero
==7565==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-replication /replication/primary/start
PASS 4 test-replication /replication/primary/stop
PASS 5 test-replication /replication/primary/do_checkpoint
PASS 6 test-replication /replication/primary/get_error_all
PASS 39 ahci-test /x86_64/ahci/io/dma/lba28/double/low
==7571==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 test-replication /replication/secondary/read
PASS 40 ahci-test /x86_64/ahci/io/dma/lba28/double/high
==7577==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 test-replication /replication/secondary/write
==7577==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd71930000; bottom 0x7f05765fd000; size: 0x00f7fb333000 (1065071357952)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 41 ahci-test /x86_64/ahci/io/dma/lba28/long/zero
==7584==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7584==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff8e6eb000; bottom 0x7f4040b23000; size: 0x00bf4dbc8000 (821642952704)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 42 ahci-test /x86_64/ahci/io/dma/lba28/long/low
==7591==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7591==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff08c6c000; bottom 0x7f700877b000; size: 0x008f004f1000 (614185504768)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 43 ahci-test /x86_64/ahci/io/dma/lba28/long/high
==7555==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd043bf000; bottom 0x7fb224d2b000; size: 0x004adf694000 (321575796736)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
==7618==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-replication /replication/secondary/start
PASS 44 ahci-test /x86_64/ahci/io/dma/lba28/short/zero
==7624==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 45 ahci-test /x86_64/ahci/io/dma/lba28/short/low
==7630==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 46 ahci-test /x86_64/ahci/io/dma/lba28/short/high
==7636==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 47 ahci-test /x86_64/ahci/io/dma/lba48/simple/zero
PASS 10 test-replication /replication/secondary/stop
==7642==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 48 ahci-test /x86_64/ahci/io/dma/lba48/simple/low
==7648==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 49 ahci-test /x86_64/ahci/io/dma/lba48/simple/high
==7654==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 50 ahci-test /x86_64/ahci/io/dma/lba48/double/zero
PASS 11 test-replication /replication/secondary/continuous_replication
==7660==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 51 ahci-test /x86_64/ahci/io/dma/lba48/double/low
==7666==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 52 ahci-test /x86_64/ahci/io/dma/lba48/double/high
==7672==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7672==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffda35f4000; bottom 0x7f8143723000; size: 0x007c5fed1000 (534185316352)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 12 test-replication /replication/secondary/do_checkpoint
PASS 53 ahci-test /x86_64/ahci/io/dma/lba48/long/zero
==7679==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7679==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc92939000; bottom 0x7f6def723000; size: 0x008ea3216000 (612622229504)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 13 test-replication /replication/secondary/get_error_all
PASS 54 ahci-test /x86_64/ahci/io/dma/lba48/long/low
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} tests/test-bufferiszero -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bufferiszero"
==7686==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7686==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffebefd000; bottom 0x7fa9ce123000; size: 0x00561ddda000 (369868251136)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 55 ahci-test /x86_64/ahci/io/dma/lba48/long/high
==7696==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 56 ahci-test /x86_64/ahci/io/dma/lba48/short/zero
==7702==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 57 ahci-test /x86_64/ahci/io/dma/lba48/short/low
==7708==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 58 ahci-test /x86_64/ahci/io/dma/lba48/short/high
==7714==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 59 ahci-test /x86_64/ahci/io/ncq/simple
==7720==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 60 ahci-test /x86_64/ahci/io/ncq/retry
==7726==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 61 ahci-test /x86_64/ahci/flush/simple
==7732==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 62 ahci-test /x86_64/ahci/flush/retry
==7738==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7744==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 63 ahci-test /x86_64/ahci/flush/migrate
==7752==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7758==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 64 ahci-test /x86_64/ahci/migrate/sanity
==7766==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7772==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 65 ahci-test /x86_64/ahci/migrate/dma/simple
==7780==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7786==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 66 ahci-test /x86_64/ahci/migrate/dma/halted
==7794==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7800==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 67 ahci-test /x86_64/ahci/migrate/ncq/simple
==7808==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7814==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 68 ahci-test /x86_64/ahci/migrate/ncq/halted
==7822==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 69 ahci-test /x86_64/ahci/cdrom/eject
==7827==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 70 ahci-test /x86_64/ahci/cdrom/dma/single
==7833==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 71 ahci-test /x86_64/ahci/cdrom/dma/multi
==7839==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 72 ahci-test /x86_64/ahci/cdrom/pio/single
==7845==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7845==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc97b69000; bottom 0x7f317a19a000; size: 0x00cb1d9cf000 (872375185408)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 73 ahci-test /x86_64/ahci/cdrom/pio/multi
==7851==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 74 ahci-test /x86_64/ahci/cdrom/pio/bcl
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/hd-geo-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="hd-geo-test" PASS 1 test-bufferiszero /cutils/bufferiszero
---
PASS 21 test-qgraph /qgraph/test_two_test_same_interface
PASS 22 test-qgraph /qgraph/test_test_in_path
PASS 23 test-qgraph /qgraph/test_double_edge
==7871==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 hd-geo-test /x86_64/hd-geo/ide/drive/cd_0
==7884==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/blank
==7890==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/lba
==7896==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/chs
==7902==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 hd-geo-test /x86_64/hd-geo/ide/device/mbr/blank
==7908==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 hd-geo-test /x86_64/hd-geo/ide/device/mbr/lba
==7914==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 hd-geo-test /x86_64/hd-geo/ide/device/mbr/chs
==7920==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 hd-geo-test /x86_64/hd-geo/ide/device/user/chs
==7925==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 hd-geo-test /x86_64/hd-geo/ide/device/user/chst
==7931==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7935==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7939==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7943==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7947==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7951==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7955==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7959==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7962==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 hd-geo-test /x86_64/hd-geo/override/ide
==7969==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7973==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7977==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7981==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7985==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7989==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7993==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==7997==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8000==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 hd-geo-test /x86_64/hd-geo/override/scsi
==8007==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8011==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8015==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8019==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8023==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8027==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8031==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8035==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8038==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 hd-geo-test /x86_64/hd-geo/override/scsi_2_controllers
==8045==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8049==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8053==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8057==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8060==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 hd-geo-test /x86_64/hd-geo/override/virtio_blk
==8067==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8071==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8074==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 15 hd-geo-test /x86_64/hd-geo/override/zero_chs
==8081==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8085==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8089==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8093==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8096==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 16 hd-geo-test /x86_64/hd-geo/override/scsi_hot_unplug
==8103==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8107==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8111==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8115==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8118==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 17 hd-geo-test /x86_64/hd-geo/override/virtio_hot_unplug
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/boot-order-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="boot-order-test" PASS 1 boot-order-test /x86_64/boot-order/pc
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8187==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP'
Using expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8193==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP'
Using expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8199==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.bridge'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8205==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.ipmikcs'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8211==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.cphp'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8218==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.memhp'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8224==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.numamem'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8230==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.dimmpxm'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8239==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.acpihmat'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8246==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.bridge'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8252==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.mmio64'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8258==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.ipmibt'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8264==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.cphp'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8271==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.memhp'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8277==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.numamem'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8283==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.dimmpxm'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==8292==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.acpihmat'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
PASS 1 i440fx-test /x86_64/i440fx/defaults
PASS 2 i440fx-test /x86_64/i440fx/pam
PASS 3 i440fx-test /x86_64/i440fx/firmware/bios
==8384==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 i440fx-test /x86_64/i440fx/firmware/pflash
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/fw_cfg-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="fw_cfg-test" PASS 1 fw_cfg-test /x86_64/fw_cfg/signature
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/drive_del-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="drive_del-test" PASS 1 drive_del-test /x86_64/drive_del/without-dev
PASS 2 drive_del-test /x86_64/drive_del/after_failed_device_add
==8477==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 drive_del-test /x86_64/blockdev/drive_del_device_del
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))} QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/wdt_ib700-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="wdt_ib700-test" PASS 1 wdt_ib700-test /x86_64/wdt_ib700/pause
---
dbus-daemon[8647]: Could not get password database information for UID of current process: User "???" unknown or no memory to allocate password entry

**
ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
cleaning up pid 8647
ERROR - Bail out! ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
make: *** [/tmp/qemu-test/src/tests/Makefile.include:632: check-qtest-x86_64] Error 1
make: *** Waiting for unfinished jobs....
Traceback (most recent call last):
File "./tests/docker/docker.py", line 664, in <module>
---
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=2843f59fdd114d41b3ab39a05a6c5610', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=x86_64-softmmu', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-fpwla0ln/src/docker-src.2020-03-10-06.57.36.6251:/var/tmp/qemu:z,ro', 'qemu:fedora', '/var/tmp/qemu/run', 'test-debug']' returned non-zero exit status 2. filter=--filter=label=com.qemu.instance.uuid=2843f59fdd114d41b3ab39a05a6c5610
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-fpwla0ln/src'
make: *** [docker-run-test-debug@fedora] Error 2

real 28m5.103s
user 0m8.537s

The full log is available at
http://patchew.org/logs/[email protected]/testing.asan/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to [email protected]

#28 lore raw
In reply to Laurent Vivier

Le 10/03/2020 à 11:33, Laurent Vivier a écrit :

Quoted 236 lines

This series copies the files syscall.tbl from linux v5.5 and generates the file syscall_nr.h from them.

This is done for all the QEMU targets that have a syscall.tbl in the linux source tree: mips, mips64, i386, x86_64, sparc, s390x, ppc, arm, microblaze, sh4, xtensa, m68k, hppa and alpha.

tilegx and cris are depecrated in linux (tilegx has no maintainer in QEMU)

aarch64, nios2, openrisc and riscv have no syscall.tbl in linux and files are generated manually with the help of a script from the asm-generic/unistd.h

Define do_arch_prctl() with -TARGET_ENOSYS for i386 as the syscall number is defined now.

I have also removed all syscalls in s390x/syscall_nr.h defined for !defined(TARGET_S390X).

I have added a script to copy all these files from linux and updated them at the end of the series with their latest version for today.

Two patches manage the special case for mips O32 that needs to know the number of arguments. We find them in strace sources.

v4:
generate syscall_nr.h for hppa32, not 64

v3:
Add a patch to define do_arch_prctl() for i386

v2:
fix a typo (double comma) in $(call quiet-command)
add a script to remove dependencies to syscall_nr.h in source directory

ppc, mips64:

we don't need to split syscall_nr.h as it is generated according TARGET_SYSTBL_ABI to TARGET_ABI_DIR
and generated values are incorrect according to the file name.

arm:

manage TARGET_NR_arm_sync_file_range

Once the syscall_nr.h are built in the build directory, the following script allows to compare them with the original one (first argument is the path to build directory), it must be run from the source directory:

cat > check_syscall_nr.sh <<EOF
BUILD="$1"

ARCHS="i386 alpha arm hppa i386 m68k microblaze s390x sh4 sparc sparc64 xtensa ppc"

syscall_nr_diff()

{
        arch=$1
        target=$2
        syscall_nr=linux-user/$arch/syscall_nr.h
        offset=$3
        REFERENCE=$(git log -1 --format=format:%h -- $syscall_nr)^
        if [ "$offset" = "" ] ; then
                git show $REFERENCE:$syscall_nr | \
                        sed 's/[[:blank:]]\/\*[^*]*\*\///' | \
                        sed 's/(\([^)]*\))/\1/'  > /tmp/old
        else
                git show $REFERENCE:$syscall_nr | \
                        sed 's/[[:blank:]]\/\*[^*]*\*\///' | \
                        sed "s/TARGET_NR_Linux/$offset/" > /tmp/old
        fi
        diff -wu --color=always /tmp/old \
                                $BUILD/$target/$syscall_nr | less -R
}

for arch in $ARCHS ; do
syscall_nr_diff $arch $arch-linux-user
done

syscall_nr_diff ppc ppc64-linux-user

syscall_nr_diff mips mips-linux-user 4000
syscall_nr_diff mips64 mips64-linux-user 5000
syscall_nr_diff mips64 mipsn32-linux-user 6000
EOF

Laurent Vivier (21):
linux-user: introduce parameters to generate syscall_nr.h linux-user,alpha: add syscall table generation support linux-user,hppa: add syscall table generation support linux-user,m68k: add syscall table generation support linux-user,xtensa: add syscall table generation support linux-user,sh4: add syscall table generation support linux-user,microblaze: add syscall table generation support linux-user,arm: add syscall table generation support linux-user,ppc: add syscall table generation support linux-user,s390x: remove syscall definitions for !TARGET_S390X linux-user,s390x: add syscall table generation support linux-user,sparc,sparc64: add syscall table generation support linux-user,x86_64,i386: cleanup TARGET_NR_arch_prctl linux-user,i386: add syscall table generation support linux-user,x86_64: add syscall table generation support linux-user,mips: add syscall table generation support linux-user,mips64: add syscall table generation support linux-user,scripts: add a script to update syscall.tbl
linux-user: update syscall.tbl from linux 0bf999f9c5e7 linux-user,mips: move content of mips_syscall_args linux-user,mips: update syscall-args-o32.c.inc

 MAINTAINERS                            |   1 +
 Makefile.target                        |   3 +-
 configure                              |  35 ++
 linux-user/Makefile.objs               |  19 +-
 linux-user/alpha/Makefile.objs         |   5 +
 linux-user/alpha/syscall.tbl           | 479 ++++++++++++++++
 linux-user/alpha/syscall_nr.h          | 492 -----------------
 linux-user/alpha/syscallhdr.sh         |  32 ++
 linux-user/arm/Makefile.objs           |   8 +
 linux-user/arm/syscall.tbl             | 453 +++++++++++++++
 linux-user/arm/syscall_nr.h            | 447 ---------------
 linux-user/arm/syscallhdr.sh           |  31 ++
 linux-user/hppa/Makefile.objs          |   5 +
 linux-user/hppa/syscall.tbl            | 437 +++++++++++++++
 linux-user/hppa/syscall_nr.h           | 358 ------------
 linux-user/hppa/syscallhdr.sh          |  32 ++
 linux-user/i386/Makefile.objs          |   5 +
 linux-user/i386/syscall_32.tbl         | 444 +++++++++++++++
 linux-user/i386/syscall_nr.h           | 387 -------------
 linux-user/i386/syscallhdr.sh          |  28 +
 linux-user/i386/target_cpu.h           |   4 +-
 linux-user/m68k/Makefile.objs          |   5 +
 linux-user/m68k/syscall.tbl            | 439 +++++++++++++++
 linux-user/m68k/syscall_nr.h           | 434 ---------------
 linux-user/m68k/syscallhdr.sh          |  32 ++
 linux-user/microblaze/Makefile.objs    |   5 +
 linux-user/microblaze/syscall.tbl      | 445 +++++++++++++++
 linux-user/microblaze/syscall_nr.h     | 442 ---------------
 linux-user/microblaze/syscallhdr.sh    |  32 ++
 linux-user/mips/Makefile.objs          |   5 +
 linux-user/mips/cpu_loop.c             | 440 +--------------
 linux-user/mips/syscall-args-o32.c.inc | 436 +++++++++++++++
 linux-user/mips/syscall_nr.h           | 425 ---------------
 linux-user/mips/syscall_o32.tbl        | 427 +++++++++++++++
 linux-user/mips/syscallhdr.sh          |  36 ++
 linux-user/mips64/Makefile.objs        |  12 +
 linux-user/mips64/syscall_n32.tbl      | 378 +++++++++++++
 linux-user/mips64/syscall_n64.tbl      | 354 ++++++++++++
 linux-user/mips64/syscall_nr.h         | 725 -------------------------
 linux-user/mips64/syscallhdr.sh        |  33 ++
 linux-user/ppc/Makefile.objs           |   6 +
 linux-user/ppc/signal.c                |   2 +-
 linux-user/ppc/syscall.tbl             | 521 ++++++++++++++++++
 linux-user/ppc/syscall_nr.h            | 402 --------------
 linux-user/ppc/syscallhdr.sh           |  34 ++
 linux-user/s390x/Makefile.objs         |   5 +
 linux-user/s390x/syscall.tbl           | 442 +++++++++++++++
 linux-user/s390x/syscall_nr.h          | 398 --------------
 linux-user/s390x/syscallhdr.sh         |  32 ++
 linux-user/sh4/Makefile.objs           |   5 +
 linux-user/sh4/syscall.tbl             | 442 +++++++++++++++
 linux-user/sh4/syscall_nr.h            | 441 ---------------
 linux-user/sh4/syscallhdr.sh           |  32 ++
 linux-user/sparc/Makefile.objs         |   5 +
 linux-user/sparc/syscall.tbl           | 485 +++++++++++++++++
 linux-user/sparc/syscall_nr.h          | 363 -------------
 linux-user/sparc/syscallhdr.sh         |  32 ++
 linux-user/sparc64/Makefile.objs       |   5 +
 linux-user/sparc64/syscall.tbl         | 485 +++++++++++++++++
 linux-user/sparc64/syscall_nr.h        | 366 -------------
 linux-user/sparc64/syscallhdr.sh       |  32 ++
 linux-user/syscall.c                   |  25 +-
 linux-user/x86_64/Makefile.objs        |   5 +
 linux-user/x86_64/syscall_64.tbl       | 404 ++++++++++++++
 linux-user/x86_64/syscall_nr.h         | 356 ------------
 linux-user/x86_64/syscallhdr.sh        |  28 +
 linux-user/xtensa/Makefile.objs        |   5 +
 linux-user/xtensa/syscall.tbl          | 410 ++++++++++++++
 linux-user/xtensa/syscall_nr.h         | 469 ----------------
 linux-user/xtensa/syscallhdr.sh        |  32 ++
 scripts/update-mips-syscall-args.sh    |  57 ++
 scripts/update-syscalltbl.sh           |  49 ++
 72 files changed, 8227 insertions(+), 6958 deletions(-)
 create mode 100644 linux-user/alpha/Makefile.objs
 create mode 100644 linux-user/alpha/syscall.tbl
 delete mode 100644 linux-user/alpha/syscall_nr.h
 create mode 100644 linux-user/alpha/syscallhdr.sh
 create mode 100644 linux-user/arm/Makefile.objs
 create mode 100644 linux-user/arm/syscall.tbl
 delete mode 100644 linux-user/arm/syscall_nr.h
 create mode 100644 linux-user/arm/syscallhdr.sh
 create mode 100644 linux-user/hppa/Makefile.objs
 create mode 100644 linux-user/hppa/syscall.tbl
 delete mode 100644 linux-user/hppa/syscall_nr.h
 create mode 100644 linux-user/hppa/syscallhdr.sh
 create mode 100644 linux-user/i386/Makefile.objs
 create mode 100644 linux-user/i386/syscall_32.tbl
 delete mode 100644 linux-user/i386/syscall_nr.h
 create mode 100644 linux-user/i386/syscallhdr.sh
 create mode 100644 linux-user/m68k/Makefile.objs
 create mode 100644 linux-user/m68k/syscall.tbl
 delete mode 100644 linux-user/m68k/syscall_nr.h
 create mode 100644 linux-user/m68k/syscallhdr.sh
 create mode 100644 linux-user/microblaze/Makefile.objs
 create mode 100644 linux-user/microblaze/syscall.tbl
 delete mode 100644 linux-user/microblaze/syscall_nr.h
 create mode 100644 linux-user/microblaze/syscallhdr.sh
 create mode 100644 linux-user/mips/Makefile.objs
 create mode 100644 linux-user/mips/syscall-args-o32.c.inc
 delete mode 100644 linux-user/mips/syscall_nr.h
 create mode 100644 linux-user/mips/syscall_o32.tbl
 create mode 100644 linux-user/mips/syscallhdr.sh
 create mode 100644 linux-user/mips64/Makefile.objs
 create mode 100644 linux-user/mips64/syscall_n32.tbl
 create mode 100644 linux-user/mips64/syscall_n64.tbl
 delete mode 100644 linux-user/mips64/syscall_nr.h
 create mode 100644 linux-user/mips64/syscallhdr.sh
 create mode 100644 linux-user/ppc/Makefile.objs
 create mode 100644 linux-user/ppc/syscall.tbl
 delete mode 100644 linux-user/ppc/syscall_nr.h
 create mode 100644 linux-user/ppc/syscallhdr.sh
 create mode 100644 linux-user/s390x/Makefile.objs
 create mode 100644 linux-user/s390x/syscall.tbl
 delete mode 100644 linux-user/s390x/syscall_nr.h
 create mode 100755 linux-user/s390x/syscallhdr.sh
 create mode 100644 linux-user/sh4/Makefile.objs
 create mode 100644 linux-user/sh4/syscall.tbl
 delete mode 100644 linux-user/sh4/syscall_nr.h
 create mode 100644 linux-user/sh4/syscallhdr.sh
 create mode 100644 linux-user/sparc/Makefile.objs
 create mode 100644 linux-user/sparc/syscall.tbl
 delete mode 100644 linux-user/sparc/syscall_nr.h
 create mode 100644 linux-user/sparc/syscallhdr.sh
 create mode 100644 linux-user/sparc64/Makefile.objs
 create mode 100644 linux-user/sparc64/syscall.tbl
 delete mode 100644 linux-user/sparc64/syscall_nr.h
 create mode 100644 linux-user/sparc64/syscallhdr.sh
 create mode 100644 linux-user/x86_64/Makefile.objs
 create mode 100644 linux-user/x86_64/syscall_64.tbl
Quoted 9 lines
 delete mode 100644 linux-user/x86_64/syscall_nr.h
 create mode 100644 linux-user/x86_64/syscallhdr.sh
 create mode 100644 linux-user/xtensa/Makefile.objs
 create mode 100644 linux-user/xtensa/syscall.tbl
 delete mode 100644 linux-user/xtensa/syscall_nr.h
 create mode 100644 linux-user/xtensa/syscallhdr.sh
 create mode 100755 scripts/update-mips-syscall-args.sh
 create mode 100755 scripts/update-syscalltbl.sh

Applied the whole series to my linux-user branch.

Thanks,
Laurent