Rich Lane | c2ee4b8 | 2013-04-24 17:12:38 -0700 | [diff] [blame] | 1 | # Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University |
| 2 | # Copyright (c) 2011, 2012 Open Networking Foundation |
| 3 | # Copyright (c) 2012, 2013 Big Switch Networks, Inc. |
| 4 | |
| 5 | # Automatically generated by LOXI from template const.py |
| 6 | # Do not modify |
| 7 | |
| 8 | OFP_VERSION = 4 |
| 9 | |
| 10 | # Identifiers from group macro_definitions |
| 11 | OFP_VLAN_NONE = 0 |
| 12 | OFP_FLOW_PERMANENT = 0 |
| 13 | OFP_ETH_ALEN = 6 |
| 14 | OFP_MAX_PORT_NAME_LEN = 16 |
| 15 | OFP_MAX_TABLE_NAME_LEN = 32 |
| 16 | SERIAL_NUM_LEN = 32 |
| 17 | OFP_DEFAULT_MISS_SEND_LEN = 128 |
| 18 | DESC_STR_LEN = 256 |
| 19 | OFP_TCP_PORT = 6633 |
| 20 | OFP_SSL_PORT = 6633 |
| 21 | OFP_DEFAULT_PRIORITY = 32768 |
| 22 | OFPQ_MIN_RATE_UNCFG = 65535 |
| 23 | OFPQ_MAX_RATE_UNCFG = 65535 |
| 24 | OFPQ_ALL = 4294967295 |
| 25 | OFP_NO_BUFFER = 4294967295 |
| 26 | |
| 27 | # Identifiers from group ofp_action_type |
| 28 | OFPAT_OUTPUT = 0 |
| 29 | OFPAT_COPY_TTL_OUT = 11 |
| 30 | OFPAT_COPY_TTL_IN = 12 |
| 31 | OFPAT_SET_MPLS_TTL = 15 |
| 32 | OFPAT_DEC_MPLS_TTL = 16 |
| 33 | OFPAT_PUSH_VLAN = 17 |
| 34 | OFPAT_POP_VLAN = 18 |
| 35 | OFPAT_PUSH_MPLS = 19 |
| 36 | OFPAT_POP_MPLS = 20 |
| 37 | OFPAT_SET_QUEUE = 21 |
| 38 | OFPAT_GROUP = 22 |
| 39 | OFPAT_SET_NW_TTL = 23 |
| 40 | OFPAT_DEC_NW_TTL = 24 |
| 41 | OFPAT_SET_FIELD = 25 |
| 42 | OFPAT_PUSH_PBB = 26 |
| 43 | OFPAT_POP_PBB = 27 |
| 44 | OFPAT_EXPERIMENTER = 65535 |
| 45 | |
| 46 | ofp_action_type_map = { |
| 47 | 0: 'OFPAT_OUTPUT', |
| 48 | 11: 'OFPAT_COPY_TTL_OUT', |
| 49 | 12: 'OFPAT_COPY_TTL_IN', |
| 50 | 15: 'OFPAT_SET_MPLS_TTL', |
| 51 | 16: 'OFPAT_DEC_MPLS_TTL', |
| 52 | 17: 'OFPAT_PUSH_VLAN', |
| 53 | 18: 'OFPAT_POP_VLAN', |
| 54 | 19: 'OFPAT_PUSH_MPLS', |
| 55 | 20: 'OFPAT_POP_MPLS', |
| 56 | 21: 'OFPAT_SET_QUEUE', |
| 57 | 22: 'OFPAT_GROUP', |
| 58 | 23: 'OFPAT_SET_NW_TTL', |
| 59 | 24: 'OFPAT_DEC_NW_TTL', |
| 60 | 25: 'OFPAT_SET_FIELD', |
| 61 | 26: 'OFPAT_PUSH_PBB', |
| 62 | 27: 'OFPAT_POP_PBB', |
| 63 | 65535: 'OFPAT_EXPERIMENTER', |
| 64 | } |
| 65 | |
| 66 | # Identifiers from group ofp_bad_action_code |
| 67 | OFPBAC_BAD_TYPE = 0 |
| 68 | OFPBAC_BAD_LEN = 1 |
| 69 | OFPBAC_BAD_EXPERIMENTER = 2 |
| 70 | OFPBAC_BAD_EXP_TYPE = 3 |
| 71 | OFPBAC_BAD_OUT_PORT = 4 |
| 72 | OFPBAC_BAD_ARGUMENT = 5 |
| 73 | OFPBAC_EPERM = 6 |
| 74 | OFPBAC_TOO_MANY = 7 |
| 75 | OFPBAC_BAD_QUEUE = 8 |
| 76 | OFPBAC_BAD_OUT_GROUP = 9 |
| 77 | OFPBAC_MATCH_INCONSISTENT = 10 |
| 78 | OFPBAC_UNSUPPORTED_ORDER = 11 |
| 79 | OFPBAC_BAD_TAG = 12 |
| 80 | OFPBAC_BAD_SET_TYPE = 13 |
| 81 | OFPBAC_BAD_SET_LEN = 14 |
| 82 | OFPBAC_BAD_SET_ARGUMENT = 15 |
| 83 | |
| 84 | ofp_bad_action_code_map = { |
| 85 | 0: 'OFPBAC_BAD_TYPE', |
| 86 | 1: 'OFPBAC_BAD_LEN', |
| 87 | 2: 'OFPBAC_BAD_EXPERIMENTER', |
| 88 | 3: 'OFPBAC_BAD_EXP_TYPE', |
| 89 | 4: 'OFPBAC_BAD_OUT_PORT', |
| 90 | 5: 'OFPBAC_BAD_ARGUMENT', |
| 91 | 6: 'OFPBAC_EPERM', |
| 92 | 7: 'OFPBAC_TOO_MANY', |
| 93 | 8: 'OFPBAC_BAD_QUEUE', |
| 94 | 9: 'OFPBAC_BAD_OUT_GROUP', |
| 95 | 10: 'OFPBAC_MATCH_INCONSISTENT', |
| 96 | 11: 'OFPBAC_UNSUPPORTED_ORDER', |
| 97 | 12: 'OFPBAC_BAD_TAG', |
| 98 | 13: 'OFPBAC_BAD_SET_TYPE', |
| 99 | 14: 'OFPBAC_BAD_SET_LEN', |
| 100 | 15: 'OFPBAC_BAD_SET_ARGUMENT', |
| 101 | } |
| 102 | |
| 103 | # Identifiers from group ofp_bad_instruction_code |
| 104 | OFPBIC_UNKNOWN_INST = 0 |
| 105 | OFPBIC_UNSUP_INST = 1 |
| 106 | OFPBIC_BAD_TABLE_ID = 2 |
| 107 | OFPBIC_UNSUP_METADATA = 3 |
| 108 | OFPBIC_UNSUP_METADATA_MASK = 4 |
| 109 | OFPBIC_BAD_EXPERIMENTER = 5 |
| 110 | OFPBIC_BAD_EXP_TYPE = 6 |
| 111 | OFPBIC_BAD_LEN = 7 |
| 112 | OFPBIC_EPERM = 8 |
| 113 | |
| 114 | ofp_bad_instruction_code_map = { |
| 115 | 0: 'OFPBIC_UNKNOWN_INST', |
| 116 | 1: 'OFPBIC_UNSUP_INST', |
| 117 | 2: 'OFPBIC_BAD_TABLE_ID', |
| 118 | 3: 'OFPBIC_UNSUP_METADATA', |
| 119 | 4: 'OFPBIC_UNSUP_METADATA_MASK', |
| 120 | 5: 'OFPBIC_BAD_EXPERIMENTER', |
| 121 | 6: 'OFPBIC_BAD_EXP_TYPE', |
| 122 | 7: 'OFPBIC_BAD_LEN', |
| 123 | 8: 'OFPBIC_EPERM', |
| 124 | } |
| 125 | |
| 126 | # Identifiers from group ofp_bad_match_code |
| 127 | OFPBMC_BAD_TYPE = 0 |
| 128 | OFPBMC_BAD_LEN = 1 |
| 129 | OFPBMC_BAD_TAG = 2 |
| 130 | OFPBMC_BAD_DL_ADDR_MASK = 3 |
| 131 | OFPBMC_BAD_NW_ADDR_MASK = 4 |
| 132 | OFPBMC_BAD_WILDCARDS = 5 |
| 133 | OFPBMC_BAD_FIELD = 6 |
| 134 | OFPBMC_BAD_VALUE = 7 |
| 135 | OFPBMC_BAD_MASK = 8 |
| 136 | OFPBMC_BAD_PREREQ = 9 |
| 137 | OFPBMC_DUP_FIELD = 10 |
| 138 | OFPBMC_EPERM = 11 |
| 139 | |
| 140 | ofp_bad_match_code_map = { |
| 141 | 0: 'OFPBMC_BAD_TYPE', |
| 142 | 1: 'OFPBMC_BAD_LEN', |
| 143 | 2: 'OFPBMC_BAD_TAG', |
| 144 | 3: 'OFPBMC_BAD_DL_ADDR_MASK', |
| 145 | 4: 'OFPBMC_BAD_NW_ADDR_MASK', |
| 146 | 5: 'OFPBMC_BAD_WILDCARDS', |
| 147 | 6: 'OFPBMC_BAD_FIELD', |
| 148 | 7: 'OFPBMC_BAD_VALUE', |
| 149 | 8: 'OFPBMC_BAD_MASK', |
| 150 | 9: 'OFPBMC_BAD_PREREQ', |
| 151 | 10: 'OFPBMC_DUP_FIELD', |
| 152 | 11: 'OFPBMC_EPERM', |
| 153 | } |
| 154 | |
| 155 | # Identifiers from group ofp_bad_request_code |
| 156 | OFPBRC_BAD_VERSION = 0 |
| 157 | OFPBRC_BAD_TYPE = 1 |
| 158 | OFPBRC_BAD_MULTIPART = 2 |
| 159 | OFPBRC_BAD_EXPERIMENTER = 3 |
| 160 | OFPBRC_BAD_EXP_TYPE = 4 |
| 161 | OFPBRC_EPERM = 5 |
| 162 | OFPBRC_BAD_LEN = 6 |
| 163 | OFPBRC_BUFFER_EMPTY = 7 |
| 164 | OFPBRC_BUFFER_UNKNOWN = 8 |
| 165 | OFPBRC_BAD_TABLE_ID = 9 |
| 166 | OFPBRC_IS_SLAVE = 10 |
| 167 | OFPBRC_BAD_PORT = 11 |
| 168 | OFPBRC_BAD_PACKET = 12 |
| 169 | OFPBRC_MULTIPART_BUFFER_OVERFLOW = 13 |
| 170 | |
| 171 | ofp_bad_request_code_map = { |
| 172 | 0: 'OFPBRC_BAD_VERSION', |
| 173 | 1: 'OFPBRC_BAD_TYPE', |
| 174 | 2: 'OFPBRC_BAD_MULTIPART', |
| 175 | 3: 'OFPBRC_BAD_EXPERIMENTER', |
| 176 | 4: 'OFPBRC_BAD_EXP_TYPE', |
| 177 | 5: 'OFPBRC_EPERM', |
| 178 | 6: 'OFPBRC_BAD_LEN', |
| 179 | 7: 'OFPBRC_BUFFER_EMPTY', |
| 180 | 8: 'OFPBRC_BUFFER_UNKNOWN', |
| 181 | 9: 'OFPBRC_BAD_TABLE_ID', |
| 182 | 10: 'OFPBRC_IS_SLAVE', |
| 183 | 11: 'OFPBRC_BAD_PORT', |
| 184 | 12: 'OFPBRC_BAD_PACKET', |
| 185 | 13: 'OFPBRC_MULTIPART_BUFFER_OVERFLOW', |
| 186 | } |
| 187 | |
| 188 | # Identifiers from group ofp_capabilities |
| 189 | OFPC_FLOW_STATS = 1 |
| 190 | OFPC_TABLE_STATS = 2 |
| 191 | OFPC_PORT_STATS = 4 |
| 192 | OFPC_GROUP_STATS = 8 |
| 193 | OFPC_IP_REASM = 32 |
| 194 | OFPC_QUEUE_STATS = 64 |
| 195 | OFPC_PORT_BLOCKED = 256 |
| 196 | |
| 197 | ofp_capabilities_map = { |
| 198 | 1: 'OFPC_FLOW_STATS', |
| 199 | 2: 'OFPC_TABLE_STATS', |
| 200 | 4: 'OFPC_PORT_STATS', |
| 201 | 8: 'OFPC_GROUP_STATS', |
| 202 | 32: 'OFPC_IP_REASM', |
| 203 | 64: 'OFPC_QUEUE_STATS', |
| 204 | 256: 'OFPC_PORT_BLOCKED', |
| 205 | } |
| 206 | |
| 207 | # Identifiers from group ofp_config_flags |
| 208 | OFPC_FRAG_NORMAL = 0 |
| 209 | OFPC_FRAG_DROP = 1 |
| 210 | OFPC_FRAG_REASM = 2 |
| 211 | OFPC_FRAG_MASK = 3 |
| 212 | |
| 213 | ofp_config_flags_map = { |
| 214 | 0: 'OFPC_FRAG_NORMAL', |
| 215 | 1: 'OFPC_FRAG_DROP', |
| 216 | 2: 'OFPC_FRAG_REASM', |
| 217 | 3: 'OFPC_FRAG_MASK', |
| 218 | } |
| 219 | |
| 220 | # Identifiers from group ofp_controller_max_len |
| 221 | OFPCML_MAX = 65509 |
| 222 | OFPCML_NO_BUFFER = 65535 |
| 223 | |
| 224 | ofp_controller_max_len_map = { |
| 225 | 65509: 'OFPCML_MAX', |
| 226 | 65535: 'OFPCML_NO_BUFFER', |
| 227 | } |
| 228 | |
| 229 | # Identifiers from group ofp_controller_role |
| 230 | OFPCR_ROLE_NOCHANGE = 0 |
| 231 | OFPCR_ROLE_EQUAL = 1 |
| 232 | OFPCR_ROLE_MASTER = 2 |
| 233 | OFPCR_ROLE_SLAVE = 3 |
| 234 | |
| 235 | ofp_controller_role_map = { |
| 236 | 0: 'OFPCR_ROLE_NOCHANGE', |
| 237 | 1: 'OFPCR_ROLE_EQUAL', |
| 238 | 2: 'OFPCR_ROLE_MASTER', |
| 239 | 3: 'OFPCR_ROLE_SLAVE', |
| 240 | } |
| 241 | |
| 242 | # Identifiers from group ofp_error_type |
| 243 | OFPET_HELLO_FAILED = 0 |
| 244 | OFPET_BAD_REQUEST = 1 |
| 245 | OFPET_BAD_ACTION = 2 |
| 246 | OFPET_BAD_INSTRUCTION = 3 |
| 247 | OFPET_BAD_MATCH = 4 |
| 248 | OFPET_FLOW_MOD_FAILED = 5 |
| 249 | OFPET_GROUP_MOD_FAILED = 6 |
| 250 | OFPET_PORT_MOD_FAILED = 7 |
| 251 | OFPET_TABLE_MOD_FAILED = 8 |
| 252 | OFPET_QUEUE_OP_FAILED = 9 |
| 253 | OFPET_SWITCH_CONFIG_FAILED = 10 |
| 254 | OFPET_ROLE_REQUEST_FAILED = 11 |
| 255 | OFPET_METER_MOD_FAILED = 12 |
| 256 | OFPET_TABLE_FEATURES_FAILED = 13 |
| 257 | OFPET_EXPERIMENTER = 65535 |
| 258 | |
| 259 | ofp_error_type_map = { |
| 260 | 0: 'OFPET_HELLO_FAILED', |
| 261 | 1: 'OFPET_BAD_REQUEST', |
| 262 | 2: 'OFPET_BAD_ACTION', |
| 263 | 3: 'OFPET_BAD_INSTRUCTION', |
| 264 | 4: 'OFPET_BAD_MATCH', |
| 265 | 5: 'OFPET_FLOW_MOD_FAILED', |
| 266 | 6: 'OFPET_GROUP_MOD_FAILED', |
| 267 | 7: 'OFPET_PORT_MOD_FAILED', |
| 268 | 8: 'OFPET_TABLE_MOD_FAILED', |
| 269 | 9: 'OFPET_QUEUE_OP_FAILED', |
| 270 | 10: 'OFPET_SWITCH_CONFIG_FAILED', |
| 271 | 11: 'OFPET_ROLE_REQUEST_FAILED', |
| 272 | 12: 'OFPET_METER_MOD_FAILED', |
| 273 | 13: 'OFPET_TABLE_FEATURES_FAILED', |
| 274 | 65535: 'OFPET_EXPERIMENTER', |
| 275 | } |
| 276 | |
| 277 | # Identifiers from group ofp_flow_mod_command |
| 278 | OFPFC_ADD = 0 |
| 279 | OFPFC_MODIFY = 1 |
| 280 | OFPFC_MODIFY_STRICT = 2 |
| 281 | OFPFC_DELETE = 3 |
| 282 | OFPFC_DELETE_STRICT = 4 |
| 283 | |
| 284 | ofp_flow_mod_command_map = { |
| 285 | 0: 'OFPFC_ADD', |
| 286 | 1: 'OFPFC_MODIFY', |
| 287 | 2: 'OFPFC_MODIFY_STRICT', |
| 288 | 3: 'OFPFC_DELETE', |
| 289 | 4: 'OFPFC_DELETE_STRICT', |
| 290 | } |
| 291 | |
| 292 | # Identifiers from group ofp_flow_mod_failed_code |
| 293 | OFPFMFC_UNKNOWN = 0 |
| 294 | OFPFMFC_TABLE_FULL = 1 |
| 295 | OFPFMFC_BAD_TABLE_ID = 2 |
| 296 | OFPFMFC_OVERLAP = 3 |
| 297 | OFPFMFC_EPERM = 4 |
| 298 | OFPFMFC_BAD_TIMEOUT = 5 |
| 299 | OFPFMFC_BAD_COMMAND = 6 |
| 300 | OFPFMFC_BAD_FLAGS = 7 |
| 301 | |
| 302 | ofp_flow_mod_failed_code_map = { |
| 303 | 0: 'OFPFMFC_UNKNOWN', |
| 304 | 1: 'OFPFMFC_TABLE_FULL', |
| 305 | 2: 'OFPFMFC_BAD_TABLE_ID', |
| 306 | 3: 'OFPFMFC_OVERLAP', |
| 307 | 4: 'OFPFMFC_EPERM', |
| 308 | 5: 'OFPFMFC_BAD_TIMEOUT', |
| 309 | 6: 'OFPFMFC_BAD_COMMAND', |
| 310 | 7: 'OFPFMFC_BAD_FLAGS', |
| 311 | } |
| 312 | |
| 313 | # Identifiers from group ofp_flow_mod_flags |
| 314 | OFPFF_SEND_FLOW_REM = 1 |
| 315 | OFPFF_CHECK_OVERLAP = 2 |
| 316 | OFPFF_RESET_COUNTS = 4 |
| 317 | OFPFF_NO_PKT_COUNTS = 8 |
| 318 | OFPFF_NO_BYT_COUNTS = 16 |
| 319 | |
| 320 | ofp_flow_mod_flags_map = { |
| 321 | 1: 'OFPFF_SEND_FLOW_REM', |
| 322 | 2: 'OFPFF_CHECK_OVERLAP', |
| 323 | 4: 'OFPFF_RESET_COUNTS', |
| 324 | 8: 'OFPFF_NO_PKT_COUNTS', |
| 325 | 16: 'OFPFF_NO_BYT_COUNTS', |
| 326 | } |
| 327 | |
| 328 | # Identifiers from group ofp_flow_removed_reason |
| 329 | OFPRR_IDLE_TIMEOUT = 0 |
| 330 | OFPRR_HARD_TIMEOUT = 1 |
| 331 | OFPRR_DELETE = 2 |
| 332 | OFPRR_GROUP_DELETE = 3 |
| 333 | |
| 334 | ofp_flow_removed_reason_map = { |
| 335 | 0: 'OFPRR_IDLE_TIMEOUT', |
| 336 | 1: 'OFPRR_HARD_TIMEOUT', |
| 337 | 2: 'OFPRR_DELETE', |
| 338 | 3: 'OFPRR_GROUP_DELETE', |
| 339 | } |
| 340 | |
| 341 | # Identifiers from group ofp_group |
| 342 | OFPG_MAX = 4294967040 |
| 343 | OFPG_ALL = 4294967292 |
| 344 | OFPG_ANY = 4294967295 |
| 345 | |
| 346 | ofp_group_map = { |
| 347 | 4294967040: 'OFPG_MAX', |
| 348 | 4294967292: 'OFPG_ALL', |
| 349 | 4294967295: 'OFPG_ANY', |
| 350 | } |
| 351 | |
| 352 | # Identifiers from group ofp_group_capabilities |
| 353 | OFPGFC_SELECT_WEIGHT = 1 |
| 354 | OFPGFC_SELECT_LIVENESS = 2 |
| 355 | OFPGFC_CHAINING = 4 |
| 356 | OFPGFC_CHAINING_CHECKS = 8 |
| 357 | |
| 358 | ofp_group_capabilities_map = { |
| 359 | 1: 'OFPGFC_SELECT_WEIGHT', |
| 360 | 2: 'OFPGFC_SELECT_LIVENESS', |
| 361 | 4: 'OFPGFC_CHAINING', |
| 362 | 8: 'OFPGFC_CHAINING_CHECKS', |
| 363 | } |
| 364 | |
| 365 | # Identifiers from group ofp_group_mod_command |
| 366 | OFPGC_ADD = 0 |
| 367 | OFPGC_MODIFY = 1 |
| 368 | OFPGC_DELETE = 2 |
| 369 | |
| 370 | ofp_group_mod_command_map = { |
| 371 | 0: 'OFPGC_ADD', |
| 372 | 1: 'OFPGC_MODIFY', |
| 373 | 2: 'OFPGC_DELETE', |
| 374 | } |
| 375 | |
| 376 | # Identifiers from group ofp_group_mod_failed_code |
| 377 | OFPGMFC_GROUP_EXISTS = 0 |
| 378 | OFPGMFC_INVALID_GROUP = 1 |
| 379 | OFPGMFC_WEIGHT_UNSUPPORTED = 2 |
| 380 | OFPGMFC_OUT_OF_GROUPS = 3 |
| 381 | OFPGMFC_OUT_OF_BUCKETS = 4 |
| 382 | OFPGMFC_CHAINING_UNSUPPORTED = 5 |
| 383 | OFPGMFC_WATCH_UNSUPPORTED = 6 |
| 384 | OFPGMFC_LOOP = 7 |
| 385 | OFPGMFC_UNKNOWN_GROUP = 8 |
| 386 | OFPGMFC_CHAINED_GROUP = 9 |
| 387 | OFPGMFC_BAD_TYPE = 10 |
| 388 | OFPGMFC_BAD_COMMAND = 11 |
| 389 | OFPGMFC_BAD_BUCKET = 12 |
| 390 | OFPGMFC_BAD_WATCH = 13 |
| 391 | OFPGMFC_EPERM = 14 |
| 392 | |
| 393 | ofp_group_mod_failed_code_map = { |
| 394 | 0: 'OFPGMFC_GROUP_EXISTS', |
| 395 | 1: 'OFPGMFC_INVALID_GROUP', |
| 396 | 2: 'OFPGMFC_WEIGHT_UNSUPPORTED', |
| 397 | 3: 'OFPGMFC_OUT_OF_GROUPS', |
| 398 | 4: 'OFPGMFC_OUT_OF_BUCKETS', |
| 399 | 5: 'OFPGMFC_CHAINING_UNSUPPORTED', |
| 400 | 6: 'OFPGMFC_WATCH_UNSUPPORTED', |
| 401 | 7: 'OFPGMFC_LOOP', |
| 402 | 8: 'OFPGMFC_UNKNOWN_GROUP', |
| 403 | 9: 'OFPGMFC_CHAINED_GROUP', |
| 404 | 10: 'OFPGMFC_BAD_TYPE', |
| 405 | 11: 'OFPGMFC_BAD_COMMAND', |
| 406 | 12: 'OFPGMFC_BAD_BUCKET', |
| 407 | 13: 'OFPGMFC_BAD_WATCH', |
| 408 | 14: 'OFPGMFC_EPERM', |
| 409 | } |
| 410 | |
| 411 | # Identifiers from group ofp_group_type |
| 412 | OFPGT_ALL = 0 |
| 413 | OFPGT_SELECT = 1 |
| 414 | OFPGT_INDIRECT = 2 |
| 415 | OFPGT_FF = 3 |
| 416 | |
| 417 | ofp_group_type_map = { |
| 418 | 0: 'OFPGT_ALL', |
| 419 | 1: 'OFPGT_SELECT', |
| 420 | 2: 'OFPGT_INDIRECT', |
| 421 | 3: 'OFPGT_FF', |
| 422 | } |
| 423 | |
| 424 | # Identifiers from group ofp_hello_elem_type |
| 425 | OFPHET_VERSIONBITMAP = 1 |
| 426 | |
| 427 | ofp_hello_elem_type_map = { |
| 428 | 1: 'OFPHET_VERSIONBITMAP', |
| 429 | } |
| 430 | |
| 431 | # Identifiers from group ofp_hello_failed_code |
| 432 | OFPHFC_INCOMPATIBLE = 0 |
| 433 | OFPHFC_EPERM = 1 |
| 434 | |
| 435 | ofp_hello_failed_code_map = { |
| 436 | 0: 'OFPHFC_INCOMPATIBLE', |
| 437 | 1: 'OFPHFC_EPERM', |
| 438 | } |
| 439 | |
| 440 | # Identifiers from group ofp_instruction_type |
| 441 | OFPIT_GOTO_TABLE = 1 |
| 442 | OFPIT_WRITE_METADATA = 2 |
| 443 | OFPIT_WRITE_ACTIONS = 3 |
| 444 | OFPIT_APPLY_ACTIONS = 4 |
| 445 | OFPIT_CLEAR_ACTIONS = 5 |
| 446 | OFPIT_METER = 6 |
| 447 | OFPIT_EXPERIMENTER = 65535 |
| 448 | |
| 449 | ofp_instruction_type_map = { |
| 450 | 1: 'OFPIT_GOTO_TABLE', |
| 451 | 2: 'OFPIT_WRITE_METADATA', |
| 452 | 3: 'OFPIT_WRITE_ACTIONS', |
| 453 | 4: 'OFPIT_APPLY_ACTIONS', |
| 454 | 5: 'OFPIT_CLEAR_ACTIONS', |
| 455 | 6: 'OFPIT_METER', |
| 456 | 65535: 'OFPIT_EXPERIMENTER', |
| 457 | } |
| 458 | |
| 459 | # Identifiers from group ofp_ipv6exthdr_flags |
| 460 | OFPIEH_NONEXT = 1 |
| 461 | OFPIEH_ESP = 2 |
| 462 | OFPIEH_AUTH = 4 |
| 463 | OFPIEH_DEST = 8 |
| 464 | OFPIEH_FRAG = 16 |
| 465 | OFPIEH_ROUTER = 32 |
| 466 | OFPIEH_HOP = 64 |
| 467 | OFPIEH_UNREP = 128 |
| 468 | OFPIEH_UNSEQ = 256 |
| 469 | |
| 470 | ofp_ipv6exthdr_flags_map = { |
| 471 | 1: 'OFPIEH_NONEXT', |
| 472 | 2: 'OFPIEH_ESP', |
| 473 | 4: 'OFPIEH_AUTH', |
| 474 | 8: 'OFPIEH_DEST', |
| 475 | 16: 'OFPIEH_FRAG', |
| 476 | 32: 'OFPIEH_ROUTER', |
| 477 | 64: 'OFPIEH_HOP', |
| 478 | 128: 'OFPIEH_UNREP', |
| 479 | 256: 'OFPIEH_UNSEQ', |
| 480 | } |
| 481 | |
| 482 | # Identifiers from group ofp_match_type |
| 483 | OFPMT_STANDARD = 0 |
| 484 | OFPMT_OXM = 1 |
| 485 | |
| 486 | ofp_match_type_map = { |
| 487 | 0: 'OFPMT_STANDARD', |
| 488 | 1: 'OFPMT_OXM', |
| 489 | } |
| 490 | |
| 491 | # Identifiers from group ofp_meter |
| 492 | OFPM_MAX = 4294901760 |
| 493 | OFPM_SLOWPATH = 4294967293 |
| 494 | OFPM_CONTROLLER = 4294967294 |
| 495 | OFPM_ALL = 4294967295 |
| 496 | |
| 497 | ofp_meter_map = { |
| 498 | 4294901760: 'OFPM_MAX', |
| 499 | 4294967293: 'OFPM_SLOWPATH', |
| 500 | 4294967294: 'OFPM_CONTROLLER', |
| 501 | 4294967295: 'OFPM_ALL', |
| 502 | } |
| 503 | |
| 504 | # Identifiers from group ofp_meter_band_type |
| 505 | OFPMBT_DROP = 1 |
| 506 | OFPMBT_DSCP_REMARK = 2 |
| 507 | OFPMBT_EXPERIMENTER = 65535 |
| 508 | |
| 509 | ofp_meter_band_type_map = { |
| 510 | 1: 'OFPMBT_DROP', |
| 511 | 2: 'OFPMBT_DSCP_REMARK', |
| 512 | 65535: 'OFPMBT_EXPERIMENTER', |
| 513 | } |
| 514 | |
| 515 | # Identifiers from group ofp_meter_flags |
| 516 | OFPMF_KBPS = 1 |
| 517 | OFPMF_PKTPS = 2 |
| 518 | OFPMF_BURST = 4 |
| 519 | OFPMF_STATS = 8 |
| 520 | |
| 521 | ofp_meter_flags_map = { |
| 522 | 1: 'OFPMF_KBPS', |
| 523 | 2: 'OFPMF_PKTPS', |
| 524 | 4: 'OFPMF_BURST', |
| 525 | 8: 'OFPMF_STATS', |
| 526 | } |
| 527 | |
| 528 | # Identifiers from group ofp_meter_mod_command |
| 529 | OFPMC_ADD = 0 |
| 530 | OFPMC_MODIFY = 1 |
| 531 | OFPMC_DELETE = 2 |
| 532 | |
| 533 | ofp_meter_mod_command_map = { |
| 534 | 0: 'OFPMC_ADD', |
| 535 | 1: 'OFPMC_MODIFY', |
| 536 | 2: 'OFPMC_DELETE', |
| 537 | } |
| 538 | |
| 539 | # Identifiers from group ofp_meter_mod_failed_code |
| 540 | OFPMMFC_UNKNOWN = 0 |
| 541 | OFPMMFC_METER_EXISTS = 1 |
| 542 | OFPMMFC_INVALID_METER = 2 |
| 543 | OFPMMFC_UNKNOWN_METER = 3 |
| 544 | OFPMMFC_BAD_COMMAND = 4 |
| 545 | OFPMMFC_BAD_FLAGS = 5 |
| 546 | OFPMMFC_BAD_RATE = 6 |
| 547 | OFPMMFC_BAD_BURST = 7 |
| 548 | OFPMMFC_BAD_BAND = 8 |
| 549 | OFPMMFC_BAD_BAND_VALUE = 9 |
| 550 | OFPMMFC_OUT_OF_METERS = 10 |
| 551 | OFPMMFC_OUT_OF_BANDS = 11 |
| 552 | |
| 553 | ofp_meter_mod_failed_code_map = { |
| 554 | 0: 'OFPMMFC_UNKNOWN', |
| 555 | 1: 'OFPMMFC_METER_EXISTS', |
| 556 | 2: 'OFPMMFC_INVALID_METER', |
| 557 | 3: 'OFPMMFC_UNKNOWN_METER', |
| 558 | 4: 'OFPMMFC_BAD_COMMAND', |
| 559 | 5: 'OFPMMFC_BAD_FLAGS', |
| 560 | 6: 'OFPMMFC_BAD_RATE', |
| 561 | 7: 'OFPMMFC_BAD_BURST', |
| 562 | 8: 'OFPMMFC_BAD_BAND', |
| 563 | 9: 'OFPMMFC_BAD_BAND_VALUE', |
| 564 | 10: 'OFPMMFC_OUT_OF_METERS', |
| 565 | 11: 'OFPMMFC_OUT_OF_BANDS', |
| 566 | } |
| 567 | |
| 568 | # Identifiers from group ofp_multipart_reply_flags |
| 569 | OFPMPF_REPLY_MORE = 1 |
| 570 | |
| 571 | ofp_multipart_reply_flags_map = { |
| 572 | 1: 'OFPMPF_REPLY_MORE', |
| 573 | } |
| 574 | |
| 575 | # Identifiers from group ofp_multipart_request_flags |
| 576 | OFPMPF_REQ_MORE = 1 |
| 577 | |
| 578 | ofp_multipart_request_flags_map = { |
| 579 | 1: 'OFPMPF_REQ_MORE', |
| 580 | } |
| 581 | |
| 582 | # Identifiers from group ofp_multipart_types |
| 583 | OFPMP_DESC = 0 |
| 584 | OFPMP_FLOW = 1 |
| 585 | OFPMP_AGGREGATE = 2 |
| 586 | OFPMP_TABLE = 3 |
| 587 | OFPMP_PORT_STATS = 4 |
| 588 | OFPMP_QUEUE = 5 |
| 589 | OFPMP_GROUP = 6 |
| 590 | OFPMP_GROUP_DESC = 7 |
| 591 | OFPMP_GROUP_FEATURES = 8 |
| 592 | OFPMP_METER = 9 |
| 593 | OFPMP_METER_CONFIG = 10 |
| 594 | OFPMP_METER_FEATURES = 11 |
| 595 | OFPMP_TABLE_FEATURES = 12 |
| 596 | OFPMP_PORT_DESC = 13 |
| 597 | OFPMP_EXPERIMENTER = 65535 |
| 598 | |
| 599 | ofp_multipart_types_map = { |
| 600 | 0: 'OFPMP_DESC', |
| 601 | 1: 'OFPMP_FLOW', |
| 602 | 2: 'OFPMP_AGGREGATE', |
| 603 | 3: 'OFPMP_TABLE', |
| 604 | 4: 'OFPMP_PORT_STATS', |
| 605 | 5: 'OFPMP_QUEUE', |
| 606 | 6: 'OFPMP_GROUP', |
| 607 | 7: 'OFPMP_GROUP_DESC', |
| 608 | 8: 'OFPMP_GROUP_FEATURES', |
| 609 | 9: 'OFPMP_METER', |
| 610 | 10: 'OFPMP_METER_CONFIG', |
| 611 | 11: 'OFPMP_METER_FEATURES', |
| 612 | 12: 'OFPMP_TABLE_FEATURES', |
| 613 | 13: 'OFPMP_PORT_DESC', |
| 614 | 65535: 'OFPMP_EXPERIMENTER', |
| 615 | } |
| 616 | |
| 617 | # Identifiers from group ofp_oxm_class |
| 618 | OFPXMC_NXM_0 = 0 |
| 619 | OFPXMC_NXM_1 = 1 |
| 620 | OFPXMC_OPENFLOW_BASIC = 32768 |
| 621 | OFPXMC_EXPERIMENTER = 65535 |
| 622 | |
| 623 | ofp_oxm_class_map = { |
| 624 | 0: 'OFPXMC_NXM_0', |
| 625 | 1: 'OFPXMC_NXM_1', |
| 626 | 32768: 'OFPXMC_OPENFLOW_BASIC', |
| 627 | 65535: 'OFPXMC_EXPERIMENTER', |
| 628 | } |
| 629 | |
| 630 | # Identifiers from group ofp_packet_in_reason |
| 631 | OFPR_NO_MATCH = 0 |
| 632 | OFPR_ACTION = 1 |
| 633 | OFPR_INVALID_TTL = 2 |
| 634 | |
| 635 | ofp_packet_in_reason_map = { |
| 636 | 0: 'OFPR_NO_MATCH', |
| 637 | 1: 'OFPR_ACTION', |
| 638 | 2: 'OFPR_INVALID_TTL', |
| 639 | } |
| 640 | |
| 641 | # Identifiers from group ofp_port |
| 642 | OFPP_MAX = 4294967040 |
| 643 | OFPP_IN_PORT = 4294967288 |
| 644 | OFPP_TABLE = 4294967289 |
| 645 | OFPP_NORMAL = 4294967290 |
| 646 | OFPP_FLOOD = 4294967291 |
| 647 | OFPP_ALL = 4294967292 |
| 648 | OFPP_CONTROLLER = 4294967293 |
| 649 | OFPP_LOCAL = 4294967294 |
| 650 | |
| 651 | ofp_port_map = { |
| 652 | 4294967040: 'OFPP_MAX', |
| 653 | 4294967288: 'OFPP_IN_PORT', |
| 654 | 4294967289: 'OFPP_TABLE', |
| 655 | 4294967290: 'OFPP_NORMAL', |
| 656 | 4294967291: 'OFPP_FLOOD', |
| 657 | 4294967292: 'OFPP_ALL', |
| 658 | 4294967293: 'OFPP_CONTROLLER', |
| 659 | 4294967294: 'OFPP_LOCAL', |
| 660 | } |
| 661 | |
| 662 | # Identifiers from group ofp_port_config |
| 663 | OFPPC_PORT_DOWN = 1 |
| 664 | OFPPC_NO_RECV = 4 |
| 665 | OFPPC_NO_FWD = 32 |
| 666 | OFPPC_NO_PACKET_IN = 64 |
| 667 | |
| 668 | ofp_port_config_map = { |
| 669 | 1: 'OFPPC_PORT_DOWN', |
| 670 | 4: 'OFPPC_NO_RECV', |
| 671 | 32: 'OFPPC_NO_FWD', |
| 672 | 64: 'OFPPC_NO_PACKET_IN', |
| 673 | } |
| 674 | |
| 675 | # Identifiers from group ofp_port_features |
| 676 | OFPPF_10MB_HD = 1 |
| 677 | OFPPF_10MB_FD = 2 |
| 678 | OFPPF_100MB_HD = 4 |
| 679 | OFPPF_100MB_FD = 8 |
| 680 | OFPPF_1GB_HD = 16 |
| 681 | OFPPF_1GB_FD = 32 |
| 682 | OFPPF_10GB_FD = 64 |
| 683 | OFPPF_40GB_FD = 128 |
| 684 | OFPPF_100GB_FD = 256 |
| 685 | OFPPF_1TB_FD = 512 |
| 686 | OFPPF_OTHER = 1024 |
| 687 | OFPPF_COPPER = 2048 |
| 688 | OFPPF_FIBER = 4096 |
| 689 | OFPPF_AUTONEG = 8192 |
| 690 | OFPPF_PAUSE = 16384 |
| 691 | OFPPF_PAUSE_ASYM = 32768 |
| 692 | |
| 693 | ofp_port_features_map = { |
| 694 | 1: 'OFPPF_10MB_HD', |
| 695 | 2: 'OFPPF_10MB_FD', |
| 696 | 4: 'OFPPF_100MB_HD', |
| 697 | 8: 'OFPPF_100MB_FD', |
| 698 | 16: 'OFPPF_1GB_HD', |
| 699 | 32: 'OFPPF_1GB_FD', |
| 700 | 64: 'OFPPF_10GB_FD', |
| 701 | 128: 'OFPPF_40GB_FD', |
| 702 | 256: 'OFPPF_100GB_FD', |
| 703 | 512: 'OFPPF_1TB_FD', |
| 704 | 1024: 'OFPPF_OTHER', |
| 705 | 2048: 'OFPPF_COPPER', |
| 706 | 4096: 'OFPPF_FIBER', |
| 707 | 8192: 'OFPPF_AUTONEG', |
| 708 | 16384: 'OFPPF_PAUSE', |
| 709 | 32768: 'OFPPF_PAUSE_ASYM', |
| 710 | } |
| 711 | |
| 712 | # Identifiers from group ofp_port_mod_failed_code |
| 713 | OFPPMFC_BAD_PORT = 0 |
| 714 | OFPPMFC_BAD_HW_ADDR = 1 |
| 715 | OFPPMFC_BAD_CONFIG = 2 |
| 716 | OFPPMFC_BAD_ADVERTISE = 3 |
| 717 | OFPPMFC_EPERM = 4 |
| 718 | |
| 719 | ofp_port_mod_failed_code_map = { |
| 720 | 0: 'OFPPMFC_BAD_PORT', |
| 721 | 1: 'OFPPMFC_BAD_HW_ADDR', |
| 722 | 2: 'OFPPMFC_BAD_CONFIG', |
| 723 | 3: 'OFPPMFC_BAD_ADVERTISE', |
| 724 | 4: 'OFPPMFC_EPERM', |
| 725 | } |
| 726 | |
| 727 | # Identifiers from group ofp_port_no |
| 728 | OFPP_ANY = 4294967295 |
| 729 | |
| 730 | ofp_port_no_map = { |
| 731 | 4294967295: 'OFPP_ANY', |
| 732 | } |
| 733 | |
| 734 | # Identifiers from group ofp_port_reason |
| 735 | OFPPR_ADD = 0 |
| 736 | OFPPR_DELETE = 1 |
| 737 | OFPPR_MODIFY = 2 |
| 738 | |
| 739 | ofp_port_reason_map = { |
| 740 | 0: 'OFPPR_ADD', |
| 741 | 1: 'OFPPR_DELETE', |
| 742 | 2: 'OFPPR_MODIFY', |
| 743 | } |
| 744 | |
| 745 | # Identifiers from group ofp_port_state |
| 746 | OFPPS_LINK_DOWN = 1 |
| 747 | OFPPS_BLOCKED = 2 |
| 748 | OFPPS_LIVE = 4 |
| 749 | |
| 750 | ofp_port_state_map = { |
| 751 | 1: 'OFPPS_LINK_DOWN', |
| 752 | 2: 'OFPPS_BLOCKED', |
| 753 | 4: 'OFPPS_LIVE', |
| 754 | } |
| 755 | |
| 756 | # Identifiers from group ofp_queue_op_failed_code |
| 757 | OFPQOFC_BAD_PORT = 0 |
| 758 | OFPQOFC_BAD_QUEUE = 1 |
| 759 | OFPQOFC_EPERM = 2 |
| 760 | |
| 761 | ofp_queue_op_failed_code_map = { |
| 762 | 0: 'OFPQOFC_BAD_PORT', |
| 763 | 1: 'OFPQOFC_BAD_QUEUE', |
| 764 | 2: 'OFPQOFC_EPERM', |
| 765 | } |
| 766 | |
| 767 | # Identifiers from group ofp_queue_properties |
| 768 | OFPQT_MIN_RATE = 1 |
| 769 | OFPQT_MAX_RATE = 2 |
| 770 | OFPQT_EXPERIMENTER = 65535 |
| 771 | |
| 772 | ofp_queue_properties_map = { |
| 773 | 1: 'OFPQT_MIN_RATE', |
| 774 | 2: 'OFPQT_MAX_RATE', |
| 775 | 65535: 'OFPQT_EXPERIMENTER', |
| 776 | } |
| 777 | |
| 778 | # Identifiers from group ofp_role_request_failed_code |
| 779 | OFPRRFC_STALE = 0 |
| 780 | OFPRRFC_UNSUP = 1 |
| 781 | OFPRRFC_BAD_ROLE = 2 |
| 782 | |
| 783 | ofp_role_request_failed_code_map = { |
| 784 | 0: 'OFPRRFC_STALE', |
| 785 | 1: 'OFPRRFC_UNSUP', |
| 786 | 2: 'OFPRRFC_BAD_ROLE', |
| 787 | } |
| 788 | |
| 789 | # Identifiers from group ofp_switch_config_failed_code |
| 790 | OFPSCFC_BAD_FLAGS = 0 |
| 791 | OFPSCFC_BAD_LEN = 1 |
| 792 | OFPSCFC_EPERM = 2 |
| 793 | |
| 794 | ofp_switch_config_failed_code_map = { |
| 795 | 0: 'OFPSCFC_BAD_FLAGS', |
| 796 | 1: 'OFPSCFC_BAD_LEN', |
| 797 | 2: 'OFPSCFC_EPERM', |
| 798 | } |
| 799 | |
| 800 | # Identifiers from group ofp_table |
| 801 | OFPTT_MAX = 254 |
| 802 | OFPTT_ALL = 255 |
| 803 | |
| 804 | ofp_table_map = { |
| 805 | 254: 'OFPTT_MAX', |
| 806 | 255: 'OFPTT_ALL', |
| 807 | } |
| 808 | |
| 809 | # Identifiers from group ofp_table_config |
| 810 | OFPTC_DEPRECATED_MASK = 3 |
| 811 | |
| 812 | ofp_table_config_map = { |
| 813 | 3: 'OFPTC_DEPRECATED_MASK', |
| 814 | } |
| 815 | |
| 816 | # Identifiers from group ofp_table_feature_prop_type |
| 817 | OFPTFPT_INSTRUCTIONS = 0 |
| 818 | OFPTFPT_INSTRUCTIONS_MISS = 1 |
| 819 | OFPTFPT_NEXT_TABLES = 2 |
| 820 | OFPTFPT_NEXT_TABLES_MISS = 3 |
| 821 | OFPTFPT_WRITE_ACTIONS = 4 |
| 822 | OFPTFPT_WRITE_ACTIONS_MISS = 5 |
| 823 | OFPTFPT_APPLY_ACTIONS = 6 |
| 824 | OFPTFPT_APPLY_ACTIONS_MISS = 7 |
| 825 | OFPTFPT_MATCH = 8 |
| 826 | OFPTFPT_WILDCARDS = 10 |
| 827 | OFPTFPT_WRITE_SETFIELD = 12 |
| 828 | OFPTFPT_WRITE_SETFIELD_MISS = 13 |
| 829 | OFPTFPT_APPLY_SETFIELD = 14 |
| 830 | OFPTFPT_APPLY_SETFIELD_MISS = 15 |
| 831 | OFPTFPT_EXPERIMENTER = 65534 |
| 832 | OFPTFPT_EXPERIMENTER_MISS = 65535 |
| 833 | |
| 834 | ofp_table_feature_prop_type_map = { |
| 835 | 0: 'OFPTFPT_INSTRUCTIONS', |
| 836 | 1: 'OFPTFPT_INSTRUCTIONS_MISS', |
| 837 | 2: 'OFPTFPT_NEXT_TABLES', |
| 838 | 3: 'OFPTFPT_NEXT_TABLES_MISS', |
| 839 | 4: 'OFPTFPT_WRITE_ACTIONS', |
| 840 | 5: 'OFPTFPT_WRITE_ACTIONS_MISS', |
| 841 | 6: 'OFPTFPT_APPLY_ACTIONS', |
| 842 | 7: 'OFPTFPT_APPLY_ACTIONS_MISS', |
| 843 | 8: 'OFPTFPT_MATCH', |
| 844 | 10: 'OFPTFPT_WILDCARDS', |
| 845 | 12: 'OFPTFPT_WRITE_SETFIELD', |
| 846 | 13: 'OFPTFPT_WRITE_SETFIELD_MISS', |
| 847 | 14: 'OFPTFPT_APPLY_SETFIELD', |
| 848 | 15: 'OFPTFPT_APPLY_SETFIELD_MISS', |
| 849 | 65534: 'OFPTFPT_EXPERIMENTER', |
| 850 | 65535: 'OFPTFPT_EXPERIMENTER_MISS', |
| 851 | } |
| 852 | |
| 853 | # Identifiers from group ofp_table_features_failed_code |
| 854 | OFPTFFC_BAD_TABLE = 0 |
| 855 | OFPTFFC_BAD_METADATA = 1 |
| 856 | OFPTFFC_BAD_TYPE = 2 |
| 857 | OFPTFFC_BAD_LEN = 3 |
| 858 | OFPTFFC_BAD_ARGUMENT = 4 |
| 859 | OFPTFFC_EPERM = 5 |
| 860 | |
| 861 | ofp_table_features_failed_code_map = { |
| 862 | 0: 'OFPTFFC_BAD_TABLE', |
| 863 | 1: 'OFPTFFC_BAD_METADATA', |
| 864 | 2: 'OFPTFFC_BAD_TYPE', |
| 865 | 3: 'OFPTFFC_BAD_LEN', |
| 866 | 4: 'OFPTFFC_BAD_ARGUMENT', |
| 867 | 5: 'OFPTFFC_EPERM', |
| 868 | } |
| 869 | |
| 870 | # Identifiers from group ofp_table_mod_failed_code |
| 871 | OFPTMFC_BAD_TABLE = 0 |
| 872 | OFPTMFC_BAD_CONFIG = 1 |
| 873 | OFPTMFC_EPERM = 2 |
| 874 | |
| 875 | ofp_table_mod_failed_code_map = { |
| 876 | 0: 'OFPTMFC_BAD_TABLE', |
| 877 | 1: 'OFPTMFC_BAD_CONFIG', |
| 878 | 2: 'OFPTMFC_EPERM', |
| 879 | } |
| 880 | |
| 881 | # Identifiers from group ofp_type |
| 882 | OFPT_HELLO = 0 |
| 883 | OFPT_ERROR = 1 |
| 884 | OFPT_ECHO_REQUEST = 2 |
| 885 | OFPT_ECHO_REPLY = 3 |
| 886 | OFPT_EXPERIMENTER = 4 |
| 887 | OFPT_FEATURES_REQUEST = 5 |
| 888 | OFPT_FEATURES_REPLY = 6 |
| 889 | OFPT_GET_CONFIG_REQUEST = 7 |
| 890 | OFPT_GET_CONFIG_REPLY = 8 |
| 891 | OFPT_SET_CONFIG = 9 |
| 892 | OFPT_PACKET_IN = 10 |
| 893 | OFPT_FLOW_REMOVED = 11 |
| 894 | OFPT_PORT_STATUS = 12 |
| 895 | OFPT_PACKET_OUT = 13 |
| 896 | OFPT_FLOW_MOD = 14 |
| 897 | OFPT_GROUP_MOD = 15 |
| 898 | OFPT_PORT_MOD = 16 |
| 899 | OFPT_TABLE_MOD = 17 |
| 900 | OFPT_MULTIPART_REQUEST = 18 |
| 901 | OFPT_MULTIPART_REPLY = 19 |
| 902 | OFPT_BARRIER_REQUEST = 20 |
| 903 | OFPT_BARRIER_REPLY = 21 |
| 904 | OFPT_QUEUE_GET_CONFIG_REQUEST = 22 |
| 905 | OFPT_QUEUE_GET_CONFIG_REPLY = 23 |
| 906 | OFPT_ROLE_REQUEST = 24 |
| 907 | OFPT_ROLE_REPLY = 25 |
| 908 | OFPT_GET_ASYNC_REQUEST = 26 |
| 909 | OFPT_GET_ASYNC_REPLY = 27 |
| 910 | OFPT_SET_ASYNC = 28 |
| 911 | OFPT_METER_MOD = 29 |
| 912 | |
| 913 | ofp_type_map = { |
| 914 | 0: 'OFPT_HELLO', |
| 915 | 1: 'OFPT_ERROR', |
| 916 | 2: 'OFPT_ECHO_REQUEST', |
| 917 | 3: 'OFPT_ECHO_REPLY', |
| 918 | 4: 'OFPT_EXPERIMENTER', |
| 919 | 5: 'OFPT_FEATURES_REQUEST', |
| 920 | 6: 'OFPT_FEATURES_REPLY', |
| 921 | 7: 'OFPT_GET_CONFIG_REQUEST', |
| 922 | 8: 'OFPT_GET_CONFIG_REPLY', |
| 923 | 9: 'OFPT_SET_CONFIG', |
| 924 | 10: 'OFPT_PACKET_IN', |
| 925 | 11: 'OFPT_FLOW_REMOVED', |
| 926 | 12: 'OFPT_PORT_STATUS', |
| 927 | 13: 'OFPT_PACKET_OUT', |
| 928 | 14: 'OFPT_FLOW_MOD', |
| 929 | 15: 'OFPT_GROUP_MOD', |
| 930 | 16: 'OFPT_PORT_MOD', |
| 931 | 17: 'OFPT_TABLE_MOD', |
| 932 | 18: 'OFPT_MULTIPART_REQUEST', |
| 933 | 19: 'OFPT_MULTIPART_REPLY', |
| 934 | 20: 'OFPT_BARRIER_REQUEST', |
| 935 | 21: 'OFPT_BARRIER_REPLY', |
| 936 | 22: 'OFPT_QUEUE_GET_CONFIG_REQUEST', |
| 937 | 23: 'OFPT_QUEUE_GET_CONFIG_REPLY', |
| 938 | 24: 'OFPT_ROLE_REQUEST', |
| 939 | 25: 'OFPT_ROLE_REPLY', |
| 940 | 26: 'OFPT_GET_ASYNC_REQUEST', |
| 941 | 27: 'OFPT_GET_ASYNC_REPLY', |
| 942 | 28: 'OFPT_SET_ASYNC', |
| 943 | 29: 'OFPT_METER_MOD', |
| 944 | } |
| 945 | |
| 946 | # Identifiers from group ofp_vlan_id |
| 947 | OFPVID_NONE = 0 |
| 948 | OFPVID_PRESENT = 4096 |
| 949 | |
| 950 | ofp_vlan_id_map = { |
| 951 | 0: 'OFPVID_NONE', |
| 952 | 4096: 'OFPVID_PRESENT', |
| 953 | } |
| 954 | |