1 /* Generated by ./xlat/gen.sh from ./xlat/sock_tcp_options.in; do not edit. */ 2 3 #include "gcc_compat.h" 4 #include "static_assert.h" 5 6 #if defined(TCP_NODELAY) || (defined(HAVE_DECL_TCP_NODELAY) && HAVE_DECL_TCP_NODELAY) 7 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 8 static_assert((TCP_NODELAY) == (1), "TCP_NODELAY != 1"); 9 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 10 #else 11 # define TCP_NODELAY 1 12 #endif 13 #if defined(TCP_MAXSEG) || (defined(HAVE_DECL_TCP_MAXSEG) && HAVE_DECL_TCP_MAXSEG) 14 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 15 static_assert((TCP_MAXSEG) == (2), "TCP_MAXSEG != 2"); 16 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 17 #else 18 # define TCP_MAXSEG 2 19 #endif 20 #if defined(TCP_CORK) || (defined(HAVE_DECL_TCP_CORK) && HAVE_DECL_TCP_CORK) 21 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 22 static_assert((TCP_CORK) == (3), "TCP_CORK != 3"); 23 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 24 #else 25 # define TCP_CORK 3 26 #endif 27 #if defined(TCP_KEEPIDLE) || (defined(HAVE_DECL_TCP_KEEPIDLE) && HAVE_DECL_TCP_KEEPIDLE) 28 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 29 static_assert((TCP_KEEPIDLE) == (4), "TCP_KEEPIDLE != 4"); 30 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 31 #else 32 # define TCP_KEEPIDLE 4 33 #endif 34 #if defined(TCP_KEEPINTVL) || (defined(HAVE_DECL_TCP_KEEPINTVL) && HAVE_DECL_TCP_KEEPINTVL) 35 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 36 static_assert((TCP_KEEPINTVL) == (5), "TCP_KEEPINTVL != 5"); 37 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 38 #else 39 # define TCP_KEEPINTVL 5 40 #endif 41 #if defined(TCP_KEEPCNT) || (defined(HAVE_DECL_TCP_KEEPCNT) && HAVE_DECL_TCP_KEEPCNT) 42 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 43 static_assert((TCP_KEEPCNT) == (6), "TCP_KEEPCNT != 6"); 44 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 45 #else 46 # define TCP_KEEPCNT 6 47 #endif 48 #if defined(TCP_SYNCNT) || (defined(HAVE_DECL_TCP_SYNCNT) && HAVE_DECL_TCP_SYNCNT) 49 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 50 static_assert((TCP_SYNCNT) == (7), "TCP_SYNCNT != 7"); 51 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 52 #else 53 # define TCP_SYNCNT 7 54 #endif 55 #if defined(TCP_LINGER2) || (defined(HAVE_DECL_TCP_LINGER2) && HAVE_DECL_TCP_LINGER2) 56 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 57 static_assert((TCP_LINGER2) == (8), "TCP_LINGER2 != 8"); 58 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 59 #else 60 # define TCP_LINGER2 8 61 #endif 62 #if defined(TCP_DEFER_ACCEPT) || (defined(HAVE_DECL_TCP_DEFER_ACCEPT) && HAVE_DECL_TCP_DEFER_ACCEPT) 63 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 64 static_assert((TCP_DEFER_ACCEPT) == (9), "TCP_DEFER_ACCEPT != 9"); 65 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 66 #else 67 # define TCP_DEFER_ACCEPT 9 68 #endif 69 #if defined(TCP_WINDOW_CLAMP) || (defined(HAVE_DECL_TCP_WINDOW_CLAMP) && HAVE_DECL_TCP_WINDOW_CLAMP) 70 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 71 static_assert((TCP_WINDOW_CLAMP) == (10), "TCP_WINDOW_CLAMP != 10"); 72 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 73 #else 74 # define TCP_WINDOW_CLAMP 10 75 #endif 76 #if defined(TCP_INFO) || (defined(HAVE_DECL_TCP_INFO) && HAVE_DECL_TCP_INFO) 77 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 78 static_assert((TCP_INFO) == (11), "TCP_INFO != 11"); 79 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 80 #else 81 # define TCP_INFO 11 82 #endif 83 #if defined(TCP_QUICKACK) || (defined(HAVE_DECL_TCP_QUICKACK) && HAVE_DECL_TCP_QUICKACK) 84 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 85 static_assert((TCP_QUICKACK) == (12), "TCP_QUICKACK != 12"); 86 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 87 #else 88 # define TCP_QUICKACK 12 89 #endif 90 #if defined(TCP_CONGESTION) || (defined(HAVE_DECL_TCP_CONGESTION) && HAVE_DECL_TCP_CONGESTION) 91 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 92 static_assert((TCP_CONGESTION) == (13), "TCP_CONGESTION != 13"); 93 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 94 #else 95 # define TCP_CONGESTION 13 96 #endif 97 #if defined(TCP_MD5SIG) || (defined(HAVE_DECL_TCP_MD5SIG) && HAVE_DECL_TCP_MD5SIG) 98 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 99 static_assert((TCP_MD5SIG) == (14), "TCP_MD5SIG != 14"); 100 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 101 #else 102 # define TCP_MD5SIG 14 103 #endif 104 #if defined(TCP_COOKIE_TRANSACTIONS) || (defined(HAVE_DECL_TCP_COOKIE_TRANSACTIONS) && HAVE_DECL_TCP_COOKIE_TRANSACTIONS) 105 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 106 static_assert((TCP_COOKIE_TRANSACTIONS) == (15), "TCP_COOKIE_TRANSACTIONS != 15"); 107 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 108 #else 109 # define TCP_COOKIE_TRANSACTIONS 15 110 #endif 111 #if defined(TCP_THIN_LINEAR_TIMEOUTS) || (defined(HAVE_DECL_TCP_THIN_LINEAR_TIMEOUTS) && HAVE_DECL_TCP_THIN_LINEAR_TIMEOUTS) 112 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 113 static_assert((TCP_THIN_LINEAR_TIMEOUTS) == (16), "TCP_THIN_LINEAR_TIMEOUTS != 16"); 114 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 115 #else 116 # define TCP_THIN_LINEAR_TIMEOUTS 16 117 #endif 118 #if defined(TCP_THIN_DUPACK) || (defined(HAVE_DECL_TCP_THIN_DUPACK) && HAVE_DECL_TCP_THIN_DUPACK) 119 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 120 static_assert((TCP_THIN_DUPACK) == (17), "TCP_THIN_DUPACK != 17"); 121 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 122 #else 123 # define TCP_THIN_DUPACK 17 124 #endif 125 #if defined(TCP_USER_TIMEOUT) || (defined(HAVE_DECL_TCP_USER_TIMEOUT) && HAVE_DECL_TCP_USER_TIMEOUT) 126 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 127 static_assert((TCP_USER_TIMEOUT) == (18), "TCP_USER_TIMEOUT != 18"); 128 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 129 #else 130 # define TCP_USER_TIMEOUT 18 131 #endif 132 #if defined(TCP_REPAIR) || (defined(HAVE_DECL_TCP_REPAIR) && HAVE_DECL_TCP_REPAIR) 133 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 134 static_assert((TCP_REPAIR) == (19), "TCP_REPAIR != 19"); 135 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 136 #else 137 # define TCP_REPAIR 19 138 #endif 139 #if defined(TCP_REPAIR_QUEUE) || (defined(HAVE_DECL_TCP_REPAIR_QUEUE) && HAVE_DECL_TCP_REPAIR_QUEUE) 140 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 141 static_assert((TCP_REPAIR_QUEUE) == (20), "TCP_REPAIR_QUEUE != 20"); 142 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 143 #else 144 # define TCP_REPAIR_QUEUE 20 145 #endif 146 #if defined(TCP_QUEUE_SEQ) || (defined(HAVE_DECL_TCP_QUEUE_SEQ) && HAVE_DECL_TCP_QUEUE_SEQ) 147 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 148 static_assert((TCP_QUEUE_SEQ) == (21), "TCP_QUEUE_SEQ != 21"); 149 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 150 #else 151 # define TCP_QUEUE_SEQ 21 152 #endif 153 #if defined(TCP_REPAIR_OPTIONS) || (defined(HAVE_DECL_TCP_REPAIR_OPTIONS) && HAVE_DECL_TCP_REPAIR_OPTIONS) 154 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 155 static_assert((TCP_REPAIR_OPTIONS) == (22), "TCP_REPAIR_OPTIONS != 22"); 156 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 157 #else 158 # define TCP_REPAIR_OPTIONS 22 159 #endif 160 #if defined(TCP_FASTOPEN) || (defined(HAVE_DECL_TCP_FASTOPEN) && HAVE_DECL_TCP_FASTOPEN) 161 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 162 static_assert((TCP_FASTOPEN) == (23), "TCP_FASTOPEN != 23"); 163 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 164 #else 165 # define TCP_FASTOPEN 23 166 #endif 167 #if defined(TCP_TIMESTAMP) || (defined(HAVE_DECL_TCP_TIMESTAMP) && HAVE_DECL_TCP_TIMESTAMP) 168 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 169 static_assert((TCP_TIMESTAMP) == (24), "TCP_TIMESTAMP != 24"); 170 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 171 #else 172 # define TCP_TIMESTAMP 24 173 #endif 174 #if defined(TCP_NOTSENT_LOWAT) || (defined(HAVE_DECL_TCP_NOTSENT_LOWAT) && HAVE_DECL_TCP_NOTSENT_LOWAT) 175 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 176 static_assert((TCP_NOTSENT_LOWAT) == (25), "TCP_NOTSENT_LOWAT != 25"); 177 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 178 #else 179 # define TCP_NOTSENT_LOWAT 25 180 #endif 181 #if defined(TCP_CC_INFO) || (defined(HAVE_DECL_TCP_CC_INFO) && HAVE_DECL_TCP_CC_INFO) 182 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 183 static_assert((TCP_CC_INFO) == (26), "TCP_CC_INFO != 26"); 184 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 185 #else 186 # define TCP_CC_INFO 26 187 #endif 188 #if defined(TCP_SAVE_SYN) || (defined(HAVE_DECL_TCP_SAVE_SYN) && HAVE_DECL_TCP_SAVE_SYN) 189 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 190 static_assert((TCP_SAVE_SYN) == (27), "TCP_SAVE_SYN != 27"); 191 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 192 #else 193 # define TCP_SAVE_SYN 27 194 #endif 195 #if defined(TCP_SAVED_SYN) || (defined(HAVE_DECL_TCP_SAVED_SYN) && HAVE_DECL_TCP_SAVED_SYN) 196 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 197 static_assert((TCP_SAVED_SYN) == (28), "TCP_SAVED_SYN != 28"); 198 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 199 #else 200 # define TCP_SAVED_SYN 28 201 #endif 202 #if defined(TCP_REPAIR_WINDOW) || (defined(HAVE_DECL_TCP_REPAIR_WINDOW) && HAVE_DECL_TCP_REPAIR_WINDOW) 203 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 204 static_assert((TCP_REPAIR_WINDOW) == (29), "TCP_REPAIR_WINDOW != 29"); 205 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 206 #else 207 # define TCP_REPAIR_WINDOW 29 208 #endif 209 #if defined(TCP_FASTOPEN_CONNECT) || (defined(HAVE_DECL_TCP_FASTOPEN_CONNECT) && HAVE_DECL_TCP_FASTOPEN_CONNECT) 210 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 211 static_assert((TCP_FASTOPEN_CONNECT) == (30), "TCP_FASTOPEN_CONNECT != 30"); 212 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 213 #else 214 # define TCP_FASTOPEN_CONNECT 30 215 #endif 216 #if defined(TCP_ULP) || (defined(HAVE_DECL_TCP_ULP) && HAVE_DECL_TCP_ULP) 217 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 218 static_assert((TCP_ULP) == (31), "TCP_ULP != 31"); 219 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 220 #else 221 # define TCP_ULP 31 222 #endif 223 #if defined(TCP_MD5SIG_EXT) || (defined(HAVE_DECL_TCP_MD5SIG_EXT) && HAVE_DECL_TCP_MD5SIG_EXT) 224 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 225 static_assert((TCP_MD5SIG_EXT) == (32), "TCP_MD5SIG_EXT != 32"); 226 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 227 #else 228 # define TCP_MD5SIG_EXT 32 229 #endif 230 #if defined(TCP_FASTOPEN_KEY) || (defined(HAVE_DECL_TCP_FASTOPEN_KEY) && HAVE_DECL_TCP_FASTOPEN_KEY) 231 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 232 static_assert((TCP_FASTOPEN_KEY) == (33), "TCP_FASTOPEN_KEY != 33"); 233 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 234 #else 235 # define TCP_FASTOPEN_KEY 33 236 #endif 237 #if defined(TCP_FASTOPEN_NO_COOKIE) || (defined(HAVE_DECL_TCP_FASTOPEN_NO_COOKIE) && HAVE_DECL_TCP_FASTOPEN_NO_COOKIE) 238 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 239 static_assert((TCP_FASTOPEN_NO_COOKIE) == (34), "TCP_FASTOPEN_NO_COOKIE != 34"); 240 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 241 #else 242 # define TCP_FASTOPEN_NO_COOKIE 34 243 #endif 244 #if defined(TCP_ZEROCOPY_RECEIVE) || (defined(HAVE_DECL_TCP_ZEROCOPY_RECEIVE) && HAVE_DECL_TCP_ZEROCOPY_RECEIVE) 245 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 246 static_assert((TCP_ZEROCOPY_RECEIVE) == (35), "TCP_ZEROCOPY_RECEIVE != 35"); 247 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 248 #else 249 # define TCP_ZEROCOPY_RECEIVE 35 250 #endif 251 #if defined(TCP_INQ) || (defined(HAVE_DECL_TCP_INQ) && HAVE_DECL_TCP_INQ) 252 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE 253 static_assert((TCP_INQ) == (36), "TCP_INQ != 36"); 254 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE 255 #else 256 # define TCP_INQ 36 257 #endif 258 259 #ifndef XLAT_MACROS_ONLY 260 261 # ifdef IN_MPERS 262 263 # error static const struct xlat sock_tcp_options in mpers mode 264 265 # else 266 267 static 268 const struct xlat sock_tcp_options[] = { 269 [TCP_NODELAY] = XLAT(TCP_NODELAY), 270 [TCP_MAXSEG] = XLAT(TCP_MAXSEG), 271 [TCP_CORK] = XLAT(TCP_CORK), 272 [TCP_KEEPIDLE] = XLAT(TCP_KEEPIDLE), 273 [TCP_KEEPINTVL] = XLAT(TCP_KEEPINTVL), 274 [TCP_KEEPCNT] = XLAT(TCP_KEEPCNT), 275 [TCP_SYNCNT] = XLAT(TCP_SYNCNT), 276 [TCP_LINGER2] = XLAT(TCP_LINGER2), 277 [TCP_DEFER_ACCEPT] = XLAT(TCP_DEFER_ACCEPT), 278 [TCP_WINDOW_CLAMP] = XLAT(TCP_WINDOW_CLAMP), 279 [TCP_INFO] = XLAT(TCP_INFO), 280 [TCP_QUICKACK] = XLAT(TCP_QUICKACK), 281 [TCP_CONGESTION] = XLAT(TCP_CONGESTION), 282 [TCP_MD5SIG] = XLAT(TCP_MD5SIG), 283 [TCP_COOKIE_TRANSACTIONS] = XLAT(TCP_COOKIE_TRANSACTIONS), 284 [TCP_THIN_LINEAR_TIMEOUTS] = XLAT(TCP_THIN_LINEAR_TIMEOUTS), 285 [TCP_THIN_DUPACK] = XLAT(TCP_THIN_DUPACK), 286 [TCP_USER_TIMEOUT] = XLAT(TCP_USER_TIMEOUT), 287 [TCP_REPAIR] = XLAT(TCP_REPAIR), 288 [TCP_REPAIR_QUEUE] = XLAT(TCP_REPAIR_QUEUE), 289 [TCP_QUEUE_SEQ] = XLAT(TCP_QUEUE_SEQ), 290 [TCP_REPAIR_OPTIONS] = XLAT(TCP_REPAIR_OPTIONS), 291 [TCP_FASTOPEN] = XLAT(TCP_FASTOPEN), 292 [TCP_TIMESTAMP] = XLAT(TCP_TIMESTAMP), 293 [TCP_NOTSENT_LOWAT] = XLAT(TCP_NOTSENT_LOWAT), 294 [TCP_CC_INFO] = XLAT(TCP_CC_INFO), 295 [TCP_SAVE_SYN] = XLAT(TCP_SAVE_SYN), 296 [TCP_SAVED_SYN] = XLAT(TCP_SAVED_SYN), 297 [TCP_REPAIR_WINDOW] = XLAT(TCP_REPAIR_WINDOW), 298 [TCP_FASTOPEN_CONNECT] = XLAT(TCP_FASTOPEN_CONNECT), 299 [TCP_ULP] = XLAT(TCP_ULP), 300 [TCP_MD5SIG_EXT] = XLAT(TCP_MD5SIG_EXT), 301 [TCP_FASTOPEN_KEY] = XLAT(TCP_FASTOPEN_KEY), 302 [TCP_FASTOPEN_NO_COOKIE] = XLAT(TCP_FASTOPEN_NO_COOKIE), 303 [TCP_ZEROCOPY_RECEIVE] = XLAT(TCP_ZEROCOPY_RECEIVE), 304 [TCP_INQ] = XLAT(TCP_INQ), 305 XLAT_END 306 }; 307 308 # endif /* !IN_MPERS */ 309 310 #endif /* !XLAT_MACROS_ONLY */ 311