/* Generated by ./xlat/gen.sh from ./xlat/bpf_map_types.in; do not edit. */ #include "gcc_compat.h" #include "static_assert.h" #if defined(BPF_MAP_TYPE_UNSPEC) || (defined(HAVE_DECL_BPF_MAP_TYPE_UNSPEC) && HAVE_DECL_BPF_MAP_TYPE_UNSPEC) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_UNSPEC) == (0), "BPF_MAP_TYPE_UNSPEC != 0"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_UNSPEC 0 #endif #if defined(BPF_MAP_TYPE_HASH) || (defined(HAVE_DECL_BPF_MAP_TYPE_HASH) && HAVE_DECL_BPF_MAP_TYPE_HASH) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_HASH) == (1), "BPF_MAP_TYPE_HASH != 1"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_HASH 1 #endif #if defined(BPF_MAP_TYPE_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_ARRAY) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_ARRAY) == (2), "BPF_MAP_TYPE_ARRAY != 2"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_ARRAY 2 #endif #if defined(BPF_MAP_TYPE_PROG_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_PROG_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_PROG_ARRAY) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_PROG_ARRAY) == (3), "BPF_MAP_TYPE_PROG_ARRAY != 3"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_PROG_ARRAY 3 #endif #if defined(BPF_MAP_TYPE_PERF_EVENT_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_PERF_EVENT_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_PERF_EVENT_ARRAY) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_PERF_EVENT_ARRAY) == (4), "BPF_MAP_TYPE_PERF_EVENT_ARRAY != 4"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_PERF_EVENT_ARRAY 4 #endif #if defined(BPF_MAP_TYPE_PERCPU_HASH) || (defined(HAVE_DECL_BPF_MAP_TYPE_PERCPU_HASH) && HAVE_DECL_BPF_MAP_TYPE_PERCPU_HASH) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_PERCPU_HASH) == (5), "BPF_MAP_TYPE_PERCPU_HASH != 5"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_PERCPU_HASH 5 #endif #if defined(BPF_MAP_TYPE_PERCPU_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_PERCPU_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_PERCPU_ARRAY) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_PERCPU_ARRAY) == (6), "BPF_MAP_TYPE_PERCPU_ARRAY != 6"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_PERCPU_ARRAY 6 #endif #if defined(BPF_MAP_TYPE_STACK_TRACE) || (defined(HAVE_DECL_BPF_MAP_TYPE_STACK_TRACE) && HAVE_DECL_BPF_MAP_TYPE_STACK_TRACE) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_STACK_TRACE) == (7), "BPF_MAP_TYPE_STACK_TRACE != 7"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_STACK_TRACE 7 #endif #if defined(BPF_MAP_TYPE_CGROUP_ARRAY) || (defined(HAVE_DECL_BPF_MAP_TYPE_CGROUP_ARRAY) && HAVE_DECL_BPF_MAP_TYPE_CGROUP_ARRAY) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_CGROUP_ARRAY) == (8), "BPF_MAP_TYPE_CGROUP_ARRAY != 8"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_CGROUP_ARRAY 8 #endif #if defined(BPF_MAP_TYPE_LRU_HASH) || (defined(HAVE_DECL_BPF_MAP_TYPE_LRU_HASH) && HAVE_DECL_BPF_MAP_TYPE_LRU_HASH) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_LRU_HASH) == (9), "BPF_MAP_TYPE_LRU_HASH != 9"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_LRU_HASH 9 #endif #if defined(BPF_MAP_TYPE_LRU_PERCPU_HASH) || (defined(HAVE_DECL_BPF_MAP_TYPE_LRU_PERCPU_HASH) && HAVE_DECL_BPF_MAP_TYPE_LRU_PERCPU_HASH) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_LRU_PERCPU_HASH) == (10), "BPF_MAP_TYPE_LRU_PERCPU_HASH != 10"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_LRU_PERCPU_HASH 10 #endif #if defined(BPF_MAP_TYPE_LPM_TRIE) || (defined(HAVE_DECL_BPF_MAP_TYPE_LPM_TRIE) && HAVE_DECL_BPF_MAP_TYPE_LPM_TRIE) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_LPM_TRIE) == (11), "BPF_MAP_TYPE_LPM_TRIE != 11"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_LPM_TRIE 11 #endif #if defined(BPF_MAP_TYPE_ARRAY_OF_MAPS) || (defined(HAVE_DECL_BPF_MAP_TYPE_ARRAY_OF_MAPS) && HAVE_DECL_BPF_MAP_TYPE_ARRAY_OF_MAPS) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_ARRAY_OF_MAPS) == (12), "BPF_MAP_TYPE_ARRAY_OF_MAPS != 12"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_ARRAY_OF_MAPS 12 #endif #if defined(BPF_MAP_TYPE_HASH_OF_MAPS) || (defined(HAVE_DECL_BPF_MAP_TYPE_HASH_OF_MAPS) && HAVE_DECL_BPF_MAP_TYPE_HASH_OF_MAPS) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_HASH_OF_MAPS) == (13), "BPF_MAP_TYPE_HASH_OF_MAPS != 13"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_HASH_OF_MAPS 13 #endif #if defined(BPF_MAP_TYPE_DEVMAP) || (defined(HAVE_DECL_BPF_MAP_TYPE_DEVMAP) && HAVE_DECL_BPF_MAP_TYPE_DEVMAP) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_DEVMAP) == (14), "BPF_MAP_TYPE_DEVMAP != 14"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_DEVMAP 14 #endif #if defined(BPF_MAP_TYPE_SOCKMAP) || (defined(HAVE_DECL_BPF_MAP_TYPE_SOCKMAP) && HAVE_DECL_BPF_MAP_TYPE_SOCKMAP) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_SOCKMAP) == (15), "BPF_MAP_TYPE_SOCKMAP != 15"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_SOCKMAP 15 #endif #if defined(BPF_MAP_TYPE_CPUMAP) || (defined(HAVE_DECL_BPF_MAP_TYPE_CPUMAP) && HAVE_DECL_BPF_MAP_TYPE_CPUMAP) DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE static_assert((BPF_MAP_TYPE_CPUMAP) == (16), "BPF_MAP_TYPE_CPUMAP != 16"); DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE #else # define BPF_MAP_TYPE_CPUMAP 16 #endif #ifndef XLAT_MACROS_ONLY # ifdef IN_MPERS # error static const struct xlat bpf_map_types in mpers mode # else static const struct xlat bpf_map_types[] = { [BPF_MAP_TYPE_UNSPEC] = XLAT(BPF_MAP_TYPE_UNSPEC), [BPF_MAP_TYPE_HASH] = XLAT(BPF_MAP_TYPE_HASH), [BPF_MAP_TYPE_ARRAY] = XLAT(BPF_MAP_TYPE_ARRAY), [BPF_MAP_TYPE_PROG_ARRAY] = XLAT(BPF_MAP_TYPE_PROG_ARRAY), [BPF_MAP_TYPE_PERF_EVENT_ARRAY] = XLAT(BPF_MAP_TYPE_PERF_EVENT_ARRAY), [BPF_MAP_TYPE_PERCPU_HASH] = XLAT(BPF_MAP_TYPE_PERCPU_HASH), [BPF_MAP_TYPE_PERCPU_ARRAY] = XLAT(BPF_MAP_TYPE_PERCPU_ARRAY), [BPF_MAP_TYPE_STACK_TRACE] = XLAT(BPF_MAP_TYPE_STACK_TRACE), [BPF_MAP_TYPE_CGROUP_ARRAY] = XLAT(BPF_MAP_TYPE_CGROUP_ARRAY), [BPF_MAP_TYPE_LRU_HASH] = XLAT(BPF_MAP_TYPE_LRU_HASH), [BPF_MAP_TYPE_LRU_PERCPU_HASH] = XLAT(BPF_MAP_TYPE_LRU_PERCPU_HASH), [BPF_MAP_TYPE_LPM_TRIE] = XLAT(BPF_MAP_TYPE_LPM_TRIE), [BPF_MAP_TYPE_ARRAY_OF_MAPS] = XLAT(BPF_MAP_TYPE_ARRAY_OF_MAPS), [BPF_MAP_TYPE_HASH_OF_MAPS] = XLAT(BPF_MAP_TYPE_HASH_OF_MAPS), [BPF_MAP_TYPE_DEVMAP] = XLAT(BPF_MAP_TYPE_DEVMAP), [BPF_MAP_TYPE_SOCKMAP] = XLAT(BPF_MAP_TYPE_SOCKMAP), [BPF_MAP_TYPE_CPUMAP] = XLAT(BPF_MAP_TYPE_CPUMAP), XLAT_END }; # endif /* !IN_MPERS */ #endif /* !XLAT_MACROS_ONLY */