]> git.proxmox.com Git - mirror_libseccomp.git/commitdiff
Merge branch 'working-ppc64'
authorPaul Moore <pmoore@redhat.com>
Wed, 5 Aug 2015 16:00:34 +0000 (12:00 -0400)
committerPaul Moore <pmoore@redhat.com>
Wed, 5 Aug 2015 16:00:34 +0000 (12:00 -0400)
Mike Strosaker <strosake@linux.vnet.ibm.com> reports that the
working-ppc64 branch is working for both 'make check' and './regression
-T live'.

15 files changed:
1  2 
include/seccomp.h.in
src/Makefile.am
src/arch-aarch64-syscalls.c
src/arch-arm-syscalls.c
src/arch-mips-syscalls.c
src/arch-mips64-syscalls.c
src/arch-mips64n32-syscalls.c
src/arch-syscall-validate
src/arch-x32-syscalls.c
src/arch-x86-syscalls.c
src/arch-x86_64-syscalls.c
src/arch.c
src/python/seccomp.pyx
tests/regression
tools/util.h

index 4cfc17c6bb90f5ff8e882aa178c78ef95e489588,3af4c2bc0f73a63baa79be4b2aa5f658472ccfe7..d100dc86f6617672729ed99fc168d6691fba1059
@@@ -155,13 -148,18 +155,23 @@@ struct scmp_arg_cmp 
  #define AUDIT_ARCH_MIPSEL64N32        (EM_MIPS|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE|\
                                 __AUDIT_ARCH_CONVENTION_MIPS64_N32)
  #endif
 +#define SCMP_ARCH_MIPS                AUDIT_ARCH_MIPS
 +#define SCMP_ARCH_MIPS64      AUDIT_ARCH_MIPS64
 +#define SCMP_ARCH_MIPS64N32   AUDIT_ARCH_MIPS64N32
 +#define SCMP_ARCH_MIPSEL      AUDIT_ARCH_MIPSEL
 +#define SCMP_ARCH_MIPSEL64    AUDIT_ARCH_MIPSEL64
  #define SCMP_ARCH_MIPSEL64N32 AUDIT_ARCH_MIPSEL64N32
  
+ /**
+  * The PowerPC architecture tokens
+  */
+ #define SCMP_ARCH_PPC         AUDIT_ARCH_PPC
+ #define SCMP_ARCH_PPC64               AUDIT_ARCH_PPC64
+ #ifndef AUDIT_ARCH_PPC64LE
+ #define AUDIT_ARCH_PPC64LE    (EM_PPC64|__AUDIT_ARCH_64BIT|__AUDIT_ARCH_LE)
+ #endif
+ #define SCMP_ARCH_PPC64LE     AUDIT_ARCH_PPC64LE
  /**
   * Convert a syscall name into the associated syscall number
   * @param x the syscall name
@@@ -1438,44 -1434,41 +1448,79 @@@ int seccomp_export_bpf(const scmp_filte
  #define __NR_utimes           __PNR_utimes
  #endif /* __NR_utimes */
  
 -#define __PNR_multiplexer     -10180
 +#define __PNR_getrlimit               -10180
 +#ifndef __NR_getrlimit
 +#define __NR_getrlimit                __PNR_getrlimit
 +#endif /* __NR_utimes */
 +
 +#define __PNR_mmap            -10181
 +#ifndef __NR_mmap
 +#define __NR_mmap             __PNR_mmap
 +#endif /* __NR_utimes */
 +
 +#define __PNR_breakpoint      -10182
 +#ifdef __ARM_NR_breakpoint
 +#define __NR_breakpoint               __ARM_NR_breakpoint
 +#else
 +#define __NR_breakpoint               __PNR_breakpoint
 +#endif /* __ARM_NR_breakpoint */
 +
 +#define __PNR_set_tls         -10183
 +#ifdef __ARM_NR_set_tls
 +#define __NR_set_tls          __ARM_NR_set_tls
 +#else
 +#define __NR_set_tls          __PNR_set_tls
 +#endif /* __ARM_NR_set_tls */
 +
 +#define __PNR_usr26           -10184
 +#ifdef __ARM_NR_usr26
 +#define __NR_usr26            __ARM_NR_usr26
 +#else
 +#define __NR_usr26            __PNR_usr26
 +#endif /* __ARM_NR_usr26 */
 +
 +#define __PNR_usr32           -10185
 +#ifdef __ARM_NR_usr32
 +#define __NR_usr32            __ARM_NR_usr32
 +#else
 +#define __NR_usr32            __PNR_usr32
 +#endif /* __ARM_NR_usr32 */
 +
++#define __PNR_multiplexer     -10186
+ #ifndef __NR_multiplexer
+ #define __NR_multiplexer      __PNR_multiplexer
+ #endif /* __NR_multiplexer */
 -#define __PNR_rtas            -10181
++#define __PNR_rtas            -10187
+ #ifndef __NR_rtas
+ #define __NR_rtas             __PNR_rtas
+ #endif /* __NR_rtas */
 -#define __PNR_spu_create      -10182
++#define __PNR_spu_create      -10188
+ #ifndef __NR_spu_create
+ #define __NR_spu_create               __PNR_spu_create
+ #endif /* __NR_spu_create */
 -#define __PNR_spu_run         -10183
++#define __PNR_spu_run         -10189
+ #ifndef __NR_spu_run
+ #define __NR_spu_run          __PNR_spu_run
+ #endif /* __NR_spu_run */
 -#define __PNR_subpage_prot    -10184
++#define __PNR_subpage_prot    -10189
+ #ifndef __NR_subpage_prot
+ #define __NR_subpage_prot     __PNR_subpage_prot
+ #endif /* __NR_subpage_prot */
 -#define __PNR_swapcontext     -10185
++#define __PNR_swapcontext     -10190
+ #ifndef __NR_swapcontext
+ #define __NR_swapcontext      __PNR_swapcontext
+ #endif /* __NR_swapcontext */
 -#define __PNR_sys_debug_setcontext    -10186
++#define __PNR_sys_debug_setcontext    -10191
+ #ifndef __NR_sys_debug_setcontext
+ #define __NR_sys_debug_setcontext     __PNR_sys_debug_setcontext
+ #endif /* __NR_sys_debug_setcontext */
  #ifdef __cplusplus
  }
  #endif
diff --cc src/Makefile.am
Simple merge
Simple merge
index c47825689bccbf4c82fc578cefd3775ad7efe734,b9400a3c740aa2b8b0e42f3a05d8ad1ae226c1e1..3d750627009d3479654d01c4a42cf0188da6976d
@@@ -381,16 -380,20 +383,20 @@@ const struct arch_syscall_def arm_sysca
        { "sigreturn", (__NR_SYSCALL_BASE + 119) },
        { "sigsuspend", (__NR_SYSCALL_BASE + 72) },
        { "socket", (__NR_SYSCALL_BASE + 281) },
 -      { "socketcall", (__NR_SYSCALL_BASE + 102) },
 +      { "socketcall", __PNR_socketcall },
        { "socketpair", (__NR_SYSCALL_BASE + 288) },
        { "splice", (__NR_SYSCALL_BASE + 340) },
+       { "spu_create", __PNR_spu_create },
+       { "spu_run", __PNR_spu_run },
        { "ssetmask", __PNR_ssetmask },
        { "stat", (__NR_SYSCALL_BASE + 106) },
        { "stat64", (__NR_SYSCALL_BASE + 195) },
        { "statfs", (__NR_SYSCALL_BASE + 99) },
        { "statfs64", (__NR_SYSCALL_BASE + 266) },
 -      { "stime", (__NR_SYSCALL_BASE + 25) },
 +      { "stime", __PNR_stime },
        { "stty", __PNR_stty },
+       { "subpage_prot", __PNR_subpage_prot },
+       { "swapcontext", __PNR_swapcontext },
        { "swapoff", (__NR_SYSCALL_BASE + 115) },
        { "swapon", (__NR_SYSCALL_BASE + 87) },
        { "symlink", (__NR_SYSCALL_BASE + 83) },
Simple merge
Simple merge
Simple merge
index 7cf7b8ba3a2b519ee8b20e3bffc378689b673fb7,595dfef34a005caaabfb4b15b8aeb99a390f6ecc..ba5cd8934ad319732064f350102eb07d0c2aaf03
@@@ -370,29 -406,35 +422,35 @@@ function dump_sys() 
  function dump_lib() {
        case $1 in
        x86)
 -              dump_lib_x86 "$2"
 +              dump_lib_x86
                ;;
        x86_64)
 -              dump_lib_x86_64 "$2"
 +              dump_lib_x86_64
                ;;
        x32)
 -              dump_lib_x32 "$2"
 +              dump_lib_x32
                ;;
        arm)
 -              dump_lib_arm "$2"
 +              dump_lib_arm
                ;;
        aarch64)
 -              dump_lib_aarch64 "$2"
 +              dump_lib_aarch64
                ;;
        mips)
 -              dump_lib_mips "$2"
 +              dump_lib_mips
                ;;
        mips64)
 -              dump_lib_mips64 "$2"
 +              dump_lib_mips64
                ;;
        mips64n32)
 -              dump_lib_mips64n32 "$2"
 +              dump_lib_mips64n32
                ;;
+       ppc64)
+               dump_lib_ppc64 "$2"
+               ;;
+       ppc)
+               dump_lib_ppc "$2"
+               ;;
        *)
                echo ""
                ;;
@@@ -438,8 -470,8 +496,8 @@@ don
  shift $(($OPTIND - 1))
  
  # defaults
 -if [[ $arches == "" ]]; then
 -      arches="x86 x86_64 x32 arm aarch64 mips mips64 mips64n32 ppc64 ppc"
 +if [[ $opt_arches == "" ]]; then
-       opt_arches="x86 x86_64 x32 arm aarch64 mips mips64 mips64n32"
++      opt_arches="x86 x86_64 x32 arm aarch64 mips mips64 mips64n32 ppc pcc64"
  fi
  
  # sanity checks
Simple merge
Simple merge
Simple merge
diff --cc src/arch.c
Simple merge
Simple merge
Simple merge
diff --cc tools/util.h
Simple merge