]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
enosys: add support for MIPS, PowerPC and ARC
authorThomas Weißschuh <thomas@t-8ch.de>
Wed, 17 May 2023 15:00:31 +0000 (17:00 +0200)
committerThomas Weißschuh <thomas@t-8ch.de>
Thu, 18 May 2023 22:14:24 +0000 (00:14 +0200)
Co-developed-by: Hauke Mertens <hauke@hauke-m.de>
Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
misc-utils/enosys.c

index 1aa673717c917b32f8d9c070cf7d4eff352ff82e..bd30baaa3fe2fd41965cbea6780e2e645e1ed3fd 100644 (file)
 #    else
 #       define SECCOMP_ARCH_NATIVE AUDIT_ARCH_PPC64LE
 #    endif
+#elif __powerpc__
+#    define SECCOMP_ARCH_NATIVE AUDIT_ARCH_PPC
+#elif __mips__
+#    if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
+#       define SECCOMP_ARCH_NATIVE AUDIT_ARCH_MIPS
+#    else
+#       define SECCOMP_ARCH_NATIVE AUDIT_ARCH_MIPSEL
+#    endif
+#elif __arc__
+#    if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
+#       define SECCOMP_ARCH_NATIVE AUDIT_ARCH_ARCV2BE
+#    else
+#       define SECCOMP_ARCH_NATIVE AUDIT_ARCH_ARCV2
+#    endif
 #else
 #    error Unknown target architecture
 #endif