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