1 /* Generated by ./xlat/gen.sh from ./xlat/bpf_mode.in; do not edit. */
2 
3 #include "gcc_compat.h"
4 #include "static_assert.h"
5 
6 #if defined(BPF_IMM) || (defined(HAVE_DECL_BPF_IMM) && HAVE_DECL_BPF_IMM)
7 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
8 static_assert((BPF_IMM) == (0x00), "BPF_IMM != 0x00");
9 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
10 #else
11 # define BPF_IMM 0x00
12 #endif
13 #if defined(BPF_ABS) || (defined(HAVE_DECL_BPF_ABS) && HAVE_DECL_BPF_ABS)
14 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
15 static_assert((BPF_ABS) == (0x20), "BPF_ABS != 0x20");
16 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
17 #else
18 # define BPF_ABS 0x20
19 #endif
20 #if defined(BPF_IND) || (defined(HAVE_DECL_BPF_IND) && HAVE_DECL_BPF_IND)
21 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
22 static_assert((BPF_IND) == (0x40), "BPF_IND != 0x40");
23 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
24 #else
25 # define BPF_IND 0x40
26 #endif
27 #if defined(BPF_MEM) || (defined(HAVE_DECL_BPF_MEM) && HAVE_DECL_BPF_MEM)
28 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
29 static_assert((BPF_MEM) == (0x60), "BPF_MEM != 0x60");
30 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
31 #else
32 # define BPF_MEM 0x60
33 #endif
34 #if defined(BPF_LEN) || (defined(HAVE_DECL_BPF_LEN) && HAVE_DECL_BPF_LEN)
35 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
36 static_assert((BPF_LEN) == (0x80), "BPF_LEN != 0x80");
37 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
38 #else
39 # define BPF_LEN 0x80
40 #endif
41 #if defined(BPF_MSH) || (defined(HAVE_DECL_BPF_MSH) && HAVE_DECL_BPF_MSH)
42 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
43 static_assert((BPF_MSH) == (0xa0), "BPF_MSH != 0xa0");
44 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
45 #else
46 # define BPF_MSH 0xa0
47 #endif
48 #if defined(BPF_XADD) || (defined(HAVE_DECL_BPF_XADD) && HAVE_DECL_BPF_XADD)
49 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
50 static_assert((BPF_XADD) == (0xc0), "BPF_XADD != 0xc0");
51 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
52 #else
53 # define BPF_XADD 0xc0
54 #endif
55 
56 #ifndef XLAT_MACROS_ONLY
57 
58 # ifdef IN_MPERS
59 
60 #  error static const struct xlat bpf_mode in mpers mode
61 
62 # else
63 
64 static
65 const struct xlat bpf_mode[] = {
66  XLAT(BPF_IMM),
67  XLAT(BPF_ABS),
68  XLAT(BPF_IND),
69  XLAT(BPF_MEM),
70  XLAT(BPF_LEN),
71  XLAT(BPF_MSH),
72  XLAT(BPF_XADD),
73  XLAT_END
74 };
75 
76 # endif /* !IN_MPERS */
77 
78 #endif /* !XLAT_MACROS_ONLY */
79