1 /* Generated by ./xlat/gen.sh from ./xlat/seccomp_ops.in; do not edit. */ 2 3 #include "gcc_compat.h" 4 #include "static_assert.h" 5 6 #if defined(SECCOMP_SET_MODE_STRICT) || (defined(HAVE_DECL_SECCOMP_SET_MODE_STRICT) && HAVE_DECL_SECCOMP_SET_MODE_STRICT) 7 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 8 static_assert((SECCOMP_SET_MODE_STRICT) == (0), "SECCOMP_SET_MODE_STRICT != 0"); 9 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 10 #else 11 # define SECCOMP_SET_MODE_STRICT 0 12 #endif 13 #if defined(SECCOMP_SET_MODE_FILTER) || (defined(HAVE_DECL_SECCOMP_SET_MODE_FILTER) && HAVE_DECL_SECCOMP_SET_MODE_FILTER) 14 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 15 static_assert((SECCOMP_SET_MODE_FILTER) == (1), "SECCOMP_SET_MODE_FILTER != 1"); 16 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 17 #else 18 # define SECCOMP_SET_MODE_FILTER 1 19 #endif 20 #if defined(SECCOMP_GET_ACTION_AVAIL) || (defined(HAVE_DECL_SECCOMP_GET_ACTION_AVAIL) && HAVE_DECL_SECCOMP_GET_ACTION_AVAIL) 21 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 22 static_assert((SECCOMP_GET_ACTION_AVAIL) == (2), "SECCOMP_GET_ACTION_AVAIL != 2"); 23 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 24 #else 25 # define SECCOMP_GET_ACTION_AVAIL 2 26 #endif 27 28 #ifndef XLAT_MACROS_ONLY 29 30 # ifdef IN_MPERS 31 32 # error static const struct xlat seccomp_ops in mpers mode 33 34 # else 35 36 static 37 const struct xlat seccomp_ops[] = { 38 XLAT(SECCOMP_SET_MODE_STRICT), 39 XLAT(SECCOMP_SET_MODE_FILTER), 40 XLAT(SECCOMP_GET_ACTION_AVAIL), 41 XLAT_END 42 }; 43 44 # endif /* !IN_MPERS */ 45 46 #endif /* !XLAT_MACROS_ONLY */ 47