Rich Lane | ca3da27 | 2013-05-05 09:07:33 -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. |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 4 | # See the file LICENSE.pyloxi which should have been included in the source distribution |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 5 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 6 | # Automatically generated by LOXI from template module.py |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 7 | # Do not modify |
| 8 | |
| 9 | import struct |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 10 | import loxi |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 11 | import const |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 12 | import common |
| 13 | import action |
| 14 | import instruction |
| 15 | import oxm |
| 16 | import action_id |
| 17 | import instruction_id |
| 18 | import meter_band |
Rich Lane | 5454b68 | 2014-01-14 17:07:36 -0800 | [diff] [blame] | 19 | import bsn_tlv |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 20 | import util |
| 21 | import loxi.generic_util |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 22 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 23 | class instruction(loxi.OFObject): |
| 24 | subtypes = {} |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 25 | |
Rich Lane | 95f7fc9 | 2014-01-27 17:08:16 -0800 | [diff] [blame] | 26 | |
| 27 | def __init__(self, type=None): |
| 28 | if type != None: |
| 29 | self.type = type |
| 30 | else: |
| 31 | self.type = 0 |
| 32 | return |
| 33 | |
| 34 | def pack(self): |
| 35 | packed = [] |
| 36 | packed.append(struct.pack("!H", self.type)) |
| 37 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 38 | length = sum([len(x) for x in packed]) |
| 39 | packed[1] = struct.pack("!H", length) |
| 40 | return ''.join(packed) |
| 41 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 42 | @staticmethod |
| 43 | def unpack(reader): |
| 44 | subtype, = reader.peek('!H', 0) |
Rich Lane | 95f7fc9 | 2014-01-27 17:08:16 -0800 | [diff] [blame] | 45 | subclass = instruction.subtypes.get(subtype) |
| 46 | if subclass: |
| 47 | return subclass.unpack(reader) |
| 48 | |
| 49 | obj = instruction() |
| 50 | obj.type = reader.read("!H")[0] |
| 51 | _len = reader.read("!H")[0] |
| 52 | orig_reader = reader |
| 53 | reader = orig_reader.slice(_len - (2 + 2)) |
| 54 | return obj |
| 55 | |
| 56 | def __eq__(self, other): |
| 57 | if type(self) != type(other): return False |
| 58 | if self.type != other.type: return False |
| 59 | return True |
| 60 | |
| 61 | def pretty_print(self, q): |
| 62 | q.text("instruction {") |
| 63 | with q.group(): |
| 64 | with q.indent(2): |
| 65 | q.breakable() |
| 66 | q.breakable() |
| 67 | q.text('}') |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 68 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 69 | |
| 70 | class apply_actions(instruction): |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 71 | type = 4 |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 72 | |
| 73 | def __init__(self, actions=None): |
| 74 | if actions != None: |
| 75 | self.actions = actions |
| 76 | else: |
| 77 | self.actions = [] |
| 78 | return |
| 79 | |
| 80 | def pack(self): |
| 81 | packed = [] |
| 82 | packed.append(struct.pack("!H", self.type)) |
| 83 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 84 | packed.append('\x00' * 4) |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 85 | packed.append(loxi.generic_util.pack_list(self.actions)) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 86 | length = sum([len(x) for x in packed]) |
| 87 | packed[1] = struct.pack("!H", length) |
| 88 | return ''.join(packed) |
| 89 | |
| 90 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 91 | def unpack(reader): |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 92 | obj = apply_actions() |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 93 | _type = reader.read("!H")[0] |
| 94 | assert(_type == 4) |
| 95 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 96 | orig_reader = reader |
| 97 | reader = orig_reader.slice(_len - (2 + 2)) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 98 | reader.skip(4) |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 99 | obj.actions = loxi.generic_util.unpack_list(reader, action.action.unpack) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 100 | return obj |
| 101 | |
| 102 | def __eq__(self, other): |
| 103 | if type(self) != type(other): return False |
| 104 | if self.actions != other.actions: return False |
| 105 | return True |
| 106 | |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 107 | def pretty_print(self, q): |
| 108 | q.text("apply_actions {") |
| 109 | with q.group(): |
| 110 | with q.indent(2): |
| 111 | q.breakable() |
| 112 | q.text("actions = "); |
| 113 | q.pp(self.actions) |
| 114 | q.breakable() |
| 115 | q.text('}') |
| 116 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 117 | instruction.subtypes[4] = apply_actions |
| 118 | |
| 119 | class experimenter(instruction): |
| 120 | subtypes = {} |
| 121 | |
Rich Lane | 95f7fc9 | 2014-01-27 17:08:16 -0800 | [diff] [blame] | 122 | type = 65535 |
| 123 | |
| 124 | def __init__(self, experimenter=None, data=None): |
| 125 | if experimenter != None: |
| 126 | self.experimenter = experimenter |
| 127 | else: |
| 128 | self.experimenter = 0 |
| 129 | if data != None: |
| 130 | self.data = data |
| 131 | else: |
| 132 | self.data = '' |
| 133 | return |
| 134 | |
| 135 | def pack(self): |
| 136 | packed = [] |
| 137 | packed.append(struct.pack("!H", self.type)) |
| 138 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 139 | packed.append(struct.pack("!L", self.experimenter)) |
| 140 | packed.append(self.data) |
| 141 | length = sum([len(x) for x in packed]) |
| 142 | packed[1] = struct.pack("!H", length) |
| 143 | return ''.join(packed) |
| 144 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 145 | @staticmethod |
| 146 | def unpack(reader): |
| 147 | subtype, = reader.peek('!L', 4) |
Rich Lane | 95f7fc9 | 2014-01-27 17:08:16 -0800 | [diff] [blame] | 148 | subclass = experimenter.subtypes.get(subtype) |
| 149 | if subclass: |
| 150 | return subclass.unpack(reader) |
| 151 | |
| 152 | obj = experimenter() |
| 153 | _type = reader.read("!H")[0] |
| 154 | assert(_type == 65535) |
| 155 | _len = reader.read("!H")[0] |
| 156 | orig_reader = reader |
| 157 | reader = orig_reader.slice(_len - (2 + 2)) |
| 158 | obj.experimenter = reader.read("!L")[0] |
| 159 | obj.data = str(reader.read_all()) |
| 160 | return obj |
| 161 | |
| 162 | def __eq__(self, other): |
| 163 | if type(self) != type(other): return False |
| 164 | if self.experimenter != other.experimenter: return False |
| 165 | if self.data != other.data: return False |
| 166 | return True |
| 167 | |
| 168 | def pretty_print(self, q): |
| 169 | q.text("experimenter {") |
| 170 | with q.group(): |
| 171 | with q.indent(2): |
| 172 | q.breakable() |
| 173 | q.text("data = "); |
| 174 | q.pp(self.data) |
| 175 | q.breakable() |
| 176 | q.text('}') |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 177 | |
| 178 | instruction.subtypes[65535] = experimenter |
| 179 | |
| 180 | class bsn(experimenter): |
| 181 | subtypes = {} |
| 182 | |
Rich Lane | 95f7fc9 | 2014-01-27 17:08:16 -0800 | [diff] [blame] | 183 | type = 65535 |
| 184 | experimenter = 6035143 |
| 185 | |
| 186 | def __init__(self, subtype=None): |
| 187 | if subtype != None: |
| 188 | self.subtype = subtype |
| 189 | else: |
| 190 | self.subtype = 0 |
| 191 | return |
| 192 | |
| 193 | def pack(self): |
| 194 | packed = [] |
| 195 | packed.append(struct.pack("!H", self.type)) |
| 196 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 197 | packed.append(struct.pack("!L", self.experimenter)) |
| 198 | packed.append(struct.pack("!L", self.subtype)) |
| 199 | packed.append('\x00' * 4) |
| 200 | length = sum([len(x) for x in packed]) |
| 201 | packed[1] = struct.pack("!H", length) |
| 202 | return ''.join(packed) |
| 203 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 204 | @staticmethod |
| 205 | def unpack(reader): |
| 206 | subtype, = reader.peek('!L', 8) |
Rich Lane | 95f7fc9 | 2014-01-27 17:08:16 -0800 | [diff] [blame] | 207 | subclass = bsn.subtypes.get(subtype) |
| 208 | if subclass: |
| 209 | return subclass.unpack(reader) |
| 210 | |
| 211 | obj = bsn() |
| 212 | _type = reader.read("!H")[0] |
| 213 | assert(_type == 65535) |
| 214 | _len = reader.read("!H")[0] |
| 215 | orig_reader = reader |
| 216 | reader = orig_reader.slice(_len - (2 + 2)) |
| 217 | _experimenter = reader.read("!L")[0] |
| 218 | assert(_experimenter == 6035143) |
| 219 | obj.subtype = reader.read("!L")[0] |
| 220 | reader.skip(4) |
| 221 | return obj |
| 222 | |
| 223 | def __eq__(self, other): |
| 224 | if type(self) != type(other): return False |
| 225 | if self.subtype != other.subtype: return False |
| 226 | return True |
| 227 | |
| 228 | def pretty_print(self, q): |
| 229 | q.text("bsn {") |
| 230 | with q.group(): |
| 231 | with q.indent(2): |
| 232 | q.breakable() |
| 233 | q.breakable() |
| 234 | q.text('}') |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 235 | |
| 236 | experimenter.subtypes[6035143] = bsn |
| 237 | |
Rich Lane | 5454b68 | 2014-01-14 17:07:36 -0800 | [diff] [blame] | 238 | class bsn_arp_offload(bsn): |
| 239 | type = 65535 |
| 240 | experimenter = 6035143 |
| 241 | subtype = 1 |
| 242 | |
| 243 | def __init__(self): |
| 244 | return |
| 245 | |
| 246 | def pack(self): |
| 247 | packed = [] |
| 248 | packed.append(struct.pack("!H", self.type)) |
| 249 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 250 | packed.append(struct.pack("!L", self.experimenter)) |
| 251 | packed.append(struct.pack("!L", self.subtype)) |
| 252 | packed.append('\x00' * 4) |
| 253 | length = sum([len(x) for x in packed]) |
| 254 | packed[1] = struct.pack("!H", length) |
| 255 | return ''.join(packed) |
| 256 | |
| 257 | @staticmethod |
| 258 | def unpack(reader): |
| 259 | obj = bsn_arp_offload() |
| 260 | _type = reader.read("!H")[0] |
| 261 | assert(_type == 65535) |
| 262 | _len = reader.read("!H")[0] |
| 263 | orig_reader = reader |
| 264 | reader = orig_reader.slice(_len - (2 + 2)) |
| 265 | _experimenter = reader.read("!L")[0] |
| 266 | assert(_experimenter == 6035143) |
| 267 | _subtype = reader.read("!L")[0] |
| 268 | assert(_subtype == 1) |
| 269 | reader.skip(4) |
| 270 | return obj |
| 271 | |
| 272 | def __eq__(self, other): |
| 273 | if type(self) != type(other): return False |
| 274 | return True |
| 275 | |
| 276 | def pretty_print(self, q): |
| 277 | q.text("bsn_arp_offload {") |
| 278 | with q.group(): |
| 279 | with q.indent(2): |
| 280 | q.breakable() |
| 281 | q.breakable() |
| 282 | q.text('}') |
| 283 | |
| 284 | bsn.subtypes[1] = bsn_arp_offload |
| 285 | |
Rich Lane | 9ec3fca | 2014-02-26 16:22:56 -0800 | [diff] [blame] | 286 | class bsn_deny(bsn): |
| 287 | type = 65535 |
| 288 | experimenter = 6035143 |
| 289 | subtype = 5 |
| 290 | |
| 291 | def __init__(self): |
| 292 | return |
| 293 | |
| 294 | def pack(self): |
| 295 | packed = [] |
| 296 | packed.append(struct.pack("!H", self.type)) |
| 297 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 298 | packed.append(struct.pack("!L", self.experimenter)) |
| 299 | packed.append(struct.pack("!L", self.subtype)) |
| 300 | packed.append('\x00' * 4) |
| 301 | length = sum([len(x) for x in packed]) |
| 302 | packed[1] = struct.pack("!H", length) |
| 303 | return ''.join(packed) |
| 304 | |
| 305 | @staticmethod |
| 306 | def unpack(reader): |
| 307 | obj = bsn_deny() |
| 308 | _type = reader.read("!H")[0] |
| 309 | assert(_type == 65535) |
| 310 | _len = reader.read("!H")[0] |
| 311 | orig_reader = reader |
| 312 | reader = orig_reader.slice(_len - (2 + 2)) |
| 313 | _experimenter = reader.read("!L")[0] |
| 314 | assert(_experimenter == 6035143) |
| 315 | _subtype = reader.read("!L")[0] |
| 316 | assert(_subtype == 5) |
| 317 | reader.skip(4) |
| 318 | return obj |
| 319 | |
| 320 | def __eq__(self, other): |
| 321 | if type(self) != type(other): return False |
| 322 | return True |
| 323 | |
| 324 | def pretty_print(self, q): |
| 325 | q.text("bsn_deny {") |
| 326 | with q.group(): |
| 327 | with q.indent(2): |
| 328 | q.breakable() |
| 329 | q.breakable() |
| 330 | q.text('}') |
| 331 | |
| 332 | bsn.subtypes[5] = bsn_deny |
| 333 | |
Rich Lane | 1b75abf | 2014-02-05 11:23:20 -0800 | [diff] [blame] | 334 | class bsn_dhcp_offload(bsn): |
| 335 | type = 65535 |
| 336 | experimenter = 6035143 |
| 337 | subtype = 2 |
| 338 | |
| 339 | def __init__(self): |
| 340 | return |
| 341 | |
| 342 | def pack(self): |
| 343 | packed = [] |
| 344 | packed.append(struct.pack("!H", self.type)) |
| 345 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 346 | packed.append(struct.pack("!L", self.experimenter)) |
| 347 | packed.append(struct.pack("!L", self.subtype)) |
| 348 | packed.append('\x00' * 4) |
| 349 | length = sum([len(x) for x in packed]) |
| 350 | packed[1] = struct.pack("!H", length) |
| 351 | return ''.join(packed) |
| 352 | |
| 353 | @staticmethod |
| 354 | def unpack(reader): |
| 355 | obj = bsn_dhcp_offload() |
| 356 | _type = reader.read("!H")[0] |
| 357 | assert(_type == 65535) |
| 358 | _len = reader.read("!H")[0] |
| 359 | orig_reader = reader |
| 360 | reader = orig_reader.slice(_len - (2 + 2)) |
| 361 | _experimenter = reader.read("!L")[0] |
| 362 | assert(_experimenter == 6035143) |
| 363 | _subtype = reader.read("!L")[0] |
| 364 | assert(_subtype == 2) |
| 365 | reader.skip(4) |
| 366 | return obj |
| 367 | |
| 368 | def __eq__(self, other): |
| 369 | if type(self) != type(other): return False |
| 370 | return True |
| 371 | |
| 372 | def pretty_print(self, q): |
| 373 | q.text("bsn_dhcp_offload {") |
| 374 | with q.group(): |
| 375 | with q.indent(2): |
| 376 | q.breakable() |
| 377 | q.breakable() |
| 378 | q.text('}') |
| 379 | |
| 380 | bsn.subtypes[2] = bsn_dhcp_offload |
| 381 | |
Rich Lane | 9ec3fca | 2014-02-26 16:22:56 -0800 | [diff] [blame] | 382 | class bsn_disable_split_horizon_check(bsn): |
| 383 | type = 65535 |
| 384 | experimenter = 6035143 |
| 385 | subtype = 3 |
| 386 | |
| 387 | def __init__(self): |
| 388 | return |
| 389 | |
| 390 | def pack(self): |
| 391 | packed = [] |
| 392 | packed.append(struct.pack("!H", self.type)) |
| 393 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 394 | packed.append(struct.pack("!L", self.experimenter)) |
| 395 | packed.append(struct.pack("!L", self.subtype)) |
| 396 | packed.append('\x00' * 4) |
| 397 | length = sum([len(x) for x in packed]) |
| 398 | packed[1] = struct.pack("!H", length) |
| 399 | return ''.join(packed) |
| 400 | |
| 401 | @staticmethod |
| 402 | def unpack(reader): |
| 403 | obj = bsn_disable_split_horizon_check() |
| 404 | _type = reader.read("!H")[0] |
| 405 | assert(_type == 65535) |
| 406 | _len = reader.read("!H")[0] |
| 407 | orig_reader = reader |
| 408 | reader = orig_reader.slice(_len - (2 + 2)) |
| 409 | _experimenter = reader.read("!L")[0] |
| 410 | assert(_experimenter == 6035143) |
| 411 | _subtype = reader.read("!L")[0] |
| 412 | assert(_subtype == 3) |
| 413 | reader.skip(4) |
| 414 | return obj |
| 415 | |
| 416 | def __eq__(self, other): |
| 417 | if type(self) != type(other): return False |
| 418 | return True |
| 419 | |
| 420 | def pretty_print(self, q): |
| 421 | q.text("bsn_disable_split_horizon_check {") |
| 422 | with q.group(): |
| 423 | with q.indent(2): |
| 424 | q.breakable() |
| 425 | q.breakable() |
| 426 | q.text('}') |
| 427 | |
| 428 | bsn.subtypes[3] = bsn_disable_split_horizon_check |
| 429 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 430 | class bsn_disable_src_mac_check(bsn): |
Rich Lane | 7b0f201 | 2013-11-22 14:15:26 -0800 | [diff] [blame] | 431 | type = 65535 |
| 432 | experimenter = 6035143 |
| 433 | subtype = 0 |
| 434 | |
| 435 | def __init__(self): |
| 436 | return |
| 437 | |
| 438 | def pack(self): |
| 439 | packed = [] |
| 440 | packed.append(struct.pack("!H", self.type)) |
| 441 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 442 | packed.append(struct.pack("!L", self.experimenter)) |
| 443 | packed.append(struct.pack("!L", self.subtype)) |
| 444 | packed.append('\x00' * 4) |
| 445 | length = sum([len(x) for x in packed]) |
| 446 | packed[1] = struct.pack("!H", length) |
| 447 | return ''.join(packed) |
| 448 | |
| 449 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 450 | def unpack(reader): |
Rich Lane | 7b0f201 | 2013-11-22 14:15:26 -0800 | [diff] [blame] | 451 | obj = bsn_disable_src_mac_check() |
Rich Lane | 7b0f201 | 2013-11-22 14:15:26 -0800 | [diff] [blame] | 452 | _type = reader.read("!H")[0] |
| 453 | assert(_type == 65535) |
| 454 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 455 | orig_reader = reader |
| 456 | reader = orig_reader.slice(_len - (2 + 2)) |
Rich Lane | 7b0f201 | 2013-11-22 14:15:26 -0800 | [diff] [blame] | 457 | _experimenter = reader.read("!L")[0] |
| 458 | assert(_experimenter == 6035143) |
| 459 | _subtype = reader.read("!L")[0] |
| 460 | assert(_subtype == 0) |
| 461 | reader.skip(4) |
| 462 | return obj |
| 463 | |
| 464 | def __eq__(self, other): |
| 465 | if type(self) != type(other): return False |
| 466 | return True |
| 467 | |
Rich Lane | 7b0f201 | 2013-11-22 14:15:26 -0800 | [diff] [blame] | 468 | def pretty_print(self, q): |
| 469 | q.text("bsn_disable_src_mac_check {") |
| 470 | with q.group(): |
| 471 | with q.indent(2): |
| 472 | q.breakable() |
| 473 | q.breakable() |
| 474 | q.text('}') |
| 475 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 476 | bsn.subtypes[0] = bsn_disable_src_mac_check |
| 477 | |
Harshmeet Singh | c0378a9 | 2014-07-22 17:09:36 -0700 | [diff] [blame] | 478 | class bsn_disable_vlan_counters(bsn): |
| 479 | type = 65535 |
| 480 | experimenter = 6035143 |
| 481 | subtype = 9 |
| 482 | |
| 483 | def __init__(self): |
| 484 | return |
| 485 | |
| 486 | def pack(self): |
| 487 | packed = [] |
| 488 | packed.append(struct.pack("!H", self.type)) |
| 489 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 490 | packed.append(struct.pack("!L", self.experimenter)) |
| 491 | packed.append(struct.pack("!L", self.subtype)) |
| 492 | packed.append('\x00' * 4) |
| 493 | length = sum([len(x) for x in packed]) |
| 494 | packed[1] = struct.pack("!H", length) |
| 495 | return ''.join(packed) |
| 496 | |
| 497 | @staticmethod |
| 498 | def unpack(reader): |
| 499 | obj = bsn_disable_vlan_counters() |
| 500 | _type = reader.read("!H")[0] |
| 501 | assert(_type == 65535) |
| 502 | _len = reader.read("!H")[0] |
| 503 | orig_reader = reader |
| 504 | reader = orig_reader.slice(_len - (2 + 2)) |
| 505 | _experimenter = reader.read("!L")[0] |
| 506 | assert(_experimenter == 6035143) |
| 507 | _subtype = reader.read("!L")[0] |
| 508 | assert(_subtype == 9) |
| 509 | reader.skip(4) |
| 510 | return obj |
| 511 | |
| 512 | def __eq__(self, other): |
| 513 | if type(self) != type(other): return False |
| 514 | return True |
| 515 | |
| 516 | def pretty_print(self, q): |
| 517 | q.text("bsn_disable_vlan_counters {") |
| 518 | with q.group(): |
| 519 | with q.indent(2): |
| 520 | q.breakable() |
| 521 | q.breakable() |
| 522 | q.text('}') |
| 523 | |
| 524 | bsn.subtypes[9] = bsn_disable_vlan_counters |
| 525 | |
Rich Lane | f50b7c3 | 2014-03-20 11:38:02 -0700 | [diff] [blame] | 526 | class bsn_packet_of_death(bsn): |
| 527 | type = 65535 |
| 528 | experimenter = 6035143 |
| 529 | subtype = 6 |
| 530 | |
| 531 | def __init__(self): |
| 532 | return |
| 533 | |
| 534 | def pack(self): |
| 535 | packed = [] |
| 536 | packed.append(struct.pack("!H", self.type)) |
| 537 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 538 | packed.append(struct.pack("!L", self.experimenter)) |
| 539 | packed.append(struct.pack("!L", self.subtype)) |
| 540 | packed.append('\x00' * 4) |
| 541 | length = sum([len(x) for x in packed]) |
| 542 | packed[1] = struct.pack("!H", length) |
| 543 | return ''.join(packed) |
| 544 | |
| 545 | @staticmethod |
| 546 | def unpack(reader): |
| 547 | obj = bsn_packet_of_death() |
| 548 | _type = reader.read("!H")[0] |
| 549 | assert(_type == 65535) |
| 550 | _len = reader.read("!H")[0] |
| 551 | orig_reader = reader |
| 552 | reader = orig_reader.slice(_len - (2 + 2)) |
| 553 | _experimenter = reader.read("!L")[0] |
| 554 | assert(_experimenter == 6035143) |
| 555 | _subtype = reader.read("!L")[0] |
| 556 | assert(_subtype == 6) |
| 557 | reader.skip(4) |
| 558 | return obj |
| 559 | |
| 560 | def __eq__(self, other): |
| 561 | if type(self) != type(other): return False |
| 562 | return True |
| 563 | |
| 564 | def pretty_print(self, q): |
| 565 | q.text("bsn_packet_of_death {") |
| 566 | with q.group(): |
| 567 | with q.indent(2): |
| 568 | q.breakable() |
| 569 | q.breakable() |
| 570 | q.text('}') |
| 571 | |
| 572 | bsn.subtypes[6] = bsn_packet_of_death |
| 573 | |
Rich Lane | 9ec3fca | 2014-02-26 16:22:56 -0800 | [diff] [blame] | 574 | class bsn_permit(bsn): |
| 575 | type = 65535 |
| 576 | experimenter = 6035143 |
| 577 | subtype = 4 |
| 578 | |
| 579 | def __init__(self): |
| 580 | return |
| 581 | |
| 582 | def pack(self): |
| 583 | packed = [] |
| 584 | packed.append(struct.pack("!H", self.type)) |
| 585 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 586 | packed.append(struct.pack("!L", self.experimenter)) |
| 587 | packed.append(struct.pack("!L", self.subtype)) |
| 588 | packed.append('\x00' * 4) |
| 589 | length = sum([len(x) for x in packed]) |
| 590 | packed[1] = struct.pack("!H", length) |
| 591 | return ''.join(packed) |
| 592 | |
| 593 | @staticmethod |
| 594 | def unpack(reader): |
| 595 | obj = bsn_permit() |
| 596 | _type = reader.read("!H")[0] |
| 597 | assert(_type == 65535) |
| 598 | _len = reader.read("!H")[0] |
| 599 | orig_reader = reader |
| 600 | reader = orig_reader.slice(_len - (2 + 2)) |
| 601 | _experimenter = reader.read("!L")[0] |
| 602 | assert(_experimenter == 6035143) |
| 603 | _subtype = reader.read("!L")[0] |
| 604 | assert(_subtype == 4) |
| 605 | reader.skip(4) |
| 606 | return obj |
| 607 | |
| 608 | def __eq__(self, other): |
| 609 | if type(self) != type(other): return False |
| 610 | return True |
| 611 | |
| 612 | def pretty_print(self, q): |
| 613 | q.text("bsn_permit {") |
| 614 | with q.group(): |
| 615 | with q.indent(2): |
| 616 | q.breakable() |
| 617 | q.breakable() |
| 618 | q.text('}') |
| 619 | |
| 620 | bsn.subtypes[4] = bsn_permit |
| 621 | |
Rich Lane | 78d9bcb | 2014-05-12 13:27:44 -0700 | [diff] [blame] | 622 | class bsn_prioritize_pdus(bsn): |
| 623 | type = 65535 |
| 624 | experimenter = 6035143 |
| 625 | subtype = 7 |
| 626 | |
| 627 | def __init__(self): |
| 628 | return |
| 629 | |
| 630 | def pack(self): |
| 631 | packed = [] |
| 632 | packed.append(struct.pack("!H", self.type)) |
| 633 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 634 | packed.append(struct.pack("!L", self.experimenter)) |
| 635 | packed.append(struct.pack("!L", self.subtype)) |
| 636 | packed.append('\x00' * 4) |
| 637 | length = sum([len(x) for x in packed]) |
| 638 | packed[1] = struct.pack("!H", length) |
| 639 | return ''.join(packed) |
| 640 | |
| 641 | @staticmethod |
| 642 | def unpack(reader): |
| 643 | obj = bsn_prioritize_pdus() |
| 644 | _type = reader.read("!H")[0] |
| 645 | assert(_type == 65535) |
| 646 | _len = reader.read("!H")[0] |
| 647 | orig_reader = reader |
| 648 | reader = orig_reader.slice(_len - (2 + 2)) |
| 649 | _experimenter = reader.read("!L")[0] |
| 650 | assert(_experimenter == 6035143) |
| 651 | _subtype = reader.read("!L")[0] |
| 652 | assert(_subtype == 7) |
| 653 | reader.skip(4) |
| 654 | return obj |
| 655 | |
| 656 | def __eq__(self, other): |
| 657 | if type(self) != type(other): return False |
| 658 | return True |
| 659 | |
| 660 | def pretty_print(self, q): |
| 661 | q.text("bsn_prioritize_pdus {") |
| 662 | with q.group(): |
| 663 | with q.indent(2): |
| 664 | q.breakable() |
| 665 | q.breakable() |
| 666 | q.text('}') |
| 667 | |
| 668 | bsn.subtypes[7] = bsn_prioritize_pdus |
| 669 | |
Rich Lane | 5587ab1 | 2014-06-30 11:19:09 -0700 | [diff] [blame] | 670 | class bsn_require_vlan_xlate(bsn): |
| 671 | type = 65535 |
| 672 | experimenter = 6035143 |
| 673 | subtype = 8 |
| 674 | |
| 675 | def __init__(self): |
| 676 | return |
| 677 | |
| 678 | def pack(self): |
| 679 | packed = [] |
| 680 | packed.append(struct.pack("!H", self.type)) |
| 681 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 682 | packed.append(struct.pack("!L", self.experimenter)) |
| 683 | packed.append(struct.pack("!L", self.subtype)) |
| 684 | packed.append('\x00' * 4) |
| 685 | length = sum([len(x) for x in packed]) |
| 686 | packed[1] = struct.pack("!H", length) |
| 687 | return ''.join(packed) |
| 688 | |
| 689 | @staticmethod |
| 690 | def unpack(reader): |
| 691 | obj = bsn_require_vlan_xlate() |
| 692 | _type = reader.read("!H")[0] |
| 693 | assert(_type == 65535) |
| 694 | _len = reader.read("!H")[0] |
| 695 | orig_reader = reader |
| 696 | reader = orig_reader.slice(_len - (2 + 2)) |
| 697 | _experimenter = reader.read("!L")[0] |
| 698 | assert(_experimenter == 6035143) |
| 699 | _subtype = reader.read("!L")[0] |
| 700 | assert(_subtype == 8) |
| 701 | reader.skip(4) |
| 702 | return obj |
| 703 | |
| 704 | def __eq__(self, other): |
| 705 | if type(self) != type(other): return False |
| 706 | return True |
| 707 | |
| 708 | def pretty_print(self, q): |
| 709 | q.text("bsn_require_vlan_xlate {") |
| 710 | with q.group(): |
| 711 | with q.indent(2): |
| 712 | q.breakable() |
| 713 | q.breakable() |
| 714 | q.text('}') |
| 715 | |
| 716 | bsn.subtypes[8] = bsn_require_vlan_xlate |
| 717 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 718 | class clear_actions(instruction): |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 719 | type = 5 |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 720 | |
| 721 | def __init__(self): |
| 722 | return |
| 723 | |
| 724 | def pack(self): |
| 725 | packed = [] |
| 726 | packed.append(struct.pack("!H", self.type)) |
| 727 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 728 | packed.append('\x00' * 4) |
| 729 | length = sum([len(x) for x in packed]) |
| 730 | packed[1] = struct.pack("!H", length) |
| 731 | return ''.join(packed) |
| 732 | |
| 733 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 734 | def unpack(reader): |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 735 | obj = clear_actions() |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 736 | _type = reader.read("!H")[0] |
| 737 | assert(_type == 5) |
| 738 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 739 | orig_reader = reader |
| 740 | reader = orig_reader.slice(_len - (2 + 2)) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 741 | reader.skip(4) |
| 742 | return obj |
| 743 | |
| 744 | def __eq__(self, other): |
| 745 | if type(self) != type(other): return False |
| 746 | return True |
| 747 | |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 748 | def pretty_print(self, q): |
| 749 | q.text("clear_actions {") |
| 750 | with q.group(): |
| 751 | with q.indent(2): |
| 752 | q.breakable() |
| 753 | q.breakable() |
| 754 | q.text('}') |
| 755 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 756 | instruction.subtypes[5] = clear_actions |
| 757 | |
| 758 | class goto_table(instruction): |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 759 | type = 1 |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 760 | |
| 761 | def __init__(self, table_id=None): |
| 762 | if table_id != None: |
| 763 | self.table_id = table_id |
| 764 | else: |
| 765 | self.table_id = 0 |
| 766 | return |
| 767 | |
| 768 | def pack(self): |
| 769 | packed = [] |
| 770 | packed.append(struct.pack("!H", self.type)) |
| 771 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 772 | packed.append(struct.pack("!B", self.table_id)) |
| 773 | packed.append('\x00' * 3) |
| 774 | length = sum([len(x) for x in packed]) |
| 775 | packed[1] = struct.pack("!H", length) |
| 776 | return ''.join(packed) |
| 777 | |
| 778 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 779 | def unpack(reader): |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 780 | obj = goto_table() |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 781 | _type = reader.read("!H")[0] |
| 782 | assert(_type == 1) |
| 783 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 784 | orig_reader = reader |
| 785 | reader = orig_reader.slice(_len - (2 + 2)) |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 786 | obj.table_id = reader.read("!B")[0] |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 787 | reader.skip(3) |
| 788 | return obj |
| 789 | |
| 790 | def __eq__(self, other): |
| 791 | if type(self) != type(other): return False |
| 792 | if self.table_id != other.table_id: return False |
| 793 | return True |
| 794 | |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 795 | def pretty_print(self, q): |
| 796 | q.text("goto_table {") |
| 797 | with q.group(): |
| 798 | with q.indent(2): |
| 799 | q.breakable() |
| 800 | q.text("table_id = "); |
| 801 | q.text("%#x" % self.table_id) |
| 802 | q.breakable() |
| 803 | q.text('}') |
| 804 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 805 | instruction.subtypes[1] = goto_table |
| 806 | |
| 807 | class meter(instruction): |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 808 | type = 6 |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 809 | |
| 810 | def __init__(self, meter_id=None): |
| 811 | if meter_id != None: |
| 812 | self.meter_id = meter_id |
| 813 | else: |
| 814 | self.meter_id = 0 |
| 815 | return |
| 816 | |
| 817 | def pack(self): |
| 818 | packed = [] |
| 819 | packed.append(struct.pack("!H", self.type)) |
| 820 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 821 | packed.append(struct.pack("!L", self.meter_id)) |
| 822 | length = sum([len(x) for x in packed]) |
| 823 | packed[1] = struct.pack("!H", length) |
| 824 | return ''.join(packed) |
| 825 | |
| 826 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 827 | def unpack(reader): |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 828 | obj = meter() |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 829 | _type = reader.read("!H")[0] |
| 830 | assert(_type == 6) |
| 831 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 832 | orig_reader = reader |
| 833 | reader = orig_reader.slice(_len - (2 + 2)) |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 834 | obj.meter_id = reader.read("!L")[0] |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 835 | return obj |
| 836 | |
| 837 | def __eq__(self, other): |
| 838 | if type(self) != type(other): return False |
| 839 | if self.meter_id != other.meter_id: return False |
| 840 | return True |
| 841 | |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 842 | def pretty_print(self, q): |
| 843 | q.text("meter {") |
| 844 | with q.group(): |
| 845 | with q.indent(2): |
| 846 | q.breakable() |
| 847 | q.text("meter_id = "); |
| 848 | q.text("%#x" % self.meter_id) |
| 849 | q.breakable() |
| 850 | q.text('}') |
| 851 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 852 | instruction.subtypes[6] = meter |
| 853 | |
| 854 | class write_actions(instruction): |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 855 | type = 3 |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 856 | |
| 857 | def __init__(self, actions=None): |
| 858 | if actions != None: |
| 859 | self.actions = actions |
| 860 | else: |
| 861 | self.actions = [] |
| 862 | return |
| 863 | |
| 864 | def pack(self): |
| 865 | packed = [] |
| 866 | packed.append(struct.pack("!H", self.type)) |
| 867 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 868 | packed.append('\x00' * 4) |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 869 | packed.append(loxi.generic_util.pack_list(self.actions)) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 870 | length = sum([len(x) for x in packed]) |
| 871 | packed[1] = struct.pack("!H", length) |
| 872 | return ''.join(packed) |
| 873 | |
| 874 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 875 | def unpack(reader): |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 876 | obj = write_actions() |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 877 | _type = reader.read("!H")[0] |
| 878 | assert(_type == 3) |
| 879 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 880 | orig_reader = reader |
| 881 | reader = orig_reader.slice(_len - (2 + 2)) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 882 | reader.skip(4) |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 883 | obj.actions = loxi.generic_util.unpack_list(reader, action.action.unpack) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 884 | return obj |
| 885 | |
| 886 | def __eq__(self, other): |
| 887 | if type(self) != type(other): return False |
| 888 | if self.actions != other.actions: return False |
| 889 | return True |
| 890 | |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 891 | def pretty_print(self, q): |
| 892 | q.text("write_actions {") |
| 893 | with q.group(): |
| 894 | with q.indent(2): |
| 895 | q.breakable() |
| 896 | q.text("actions = "); |
| 897 | q.pp(self.actions) |
| 898 | q.breakable() |
| 899 | q.text('}') |
| 900 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 901 | instruction.subtypes[3] = write_actions |
| 902 | |
| 903 | class write_metadata(instruction): |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 904 | type = 2 |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 905 | |
| 906 | def __init__(self, metadata=None, metadata_mask=None): |
| 907 | if metadata != None: |
| 908 | self.metadata = metadata |
| 909 | else: |
| 910 | self.metadata = 0 |
| 911 | if metadata_mask != None: |
| 912 | self.metadata_mask = metadata_mask |
| 913 | else: |
| 914 | self.metadata_mask = 0 |
| 915 | return |
| 916 | |
| 917 | def pack(self): |
| 918 | packed = [] |
| 919 | packed.append(struct.pack("!H", self.type)) |
| 920 | packed.append(struct.pack("!H", 0)) # placeholder for len at index 1 |
| 921 | packed.append('\x00' * 4) |
| 922 | packed.append(struct.pack("!Q", self.metadata)) |
| 923 | packed.append(struct.pack("!Q", self.metadata_mask)) |
| 924 | length = sum([len(x) for x in packed]) |
| 925 | packed[1] = struct.pack("!H", length) |
| 926 | return ''.join(packed) |
| 927 | |
| 928 | @staticmethod |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 929 | def unpack(reader): |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 930 | obj = write_metadata() |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 931 | _type = reader.read("!H")[0] |
| 932 | assert(_type == 2) |
| 933 | _len = reader.read("!H")[0] |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 934 | orig_reader = reader |
| 935 | reader = orig_reader.slice(_len - (2 + 2)) |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 936 | reader.skip(4) |
Dan Talayco | f620225 | 2013-07-02 01:00:29 -0700 | [diff] [blame] | 937 | obj.metadata = reader.read("!Q")[0] |
| 938 | obj.metadata_mask = reader.read("!Q")[0] |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 939 | return obj |
| 940 | |
| 941 | def __eq__(self, other): |
| 942 | if type(self) != type(other): return False |
| 943 | if self.metadata != other.metadata: return False |
| 944 | if self.metadata_mask != other.metadata_mask: return False |
| 945 | return True |
| 946 | |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 947 | def pretty_print(self, q): |
| 948 | q.text("write_metadata {") |
| 949 | with q.group(): |
| 950 | with q.indent(2): |
| 951 | q.breakable() |
| 952 | q.text("metadata = "); |
| 953 | q.text("%#x" % self.metadata) |
| 954 | q.text(","); q.breakable() |
| 955 | q.text("metadata_mask = "); |
| 956 | q.text("%#x" % self.metadata_mask) |
| 957 | q.breakable() |
| 958 | q.text('}') |
| 959 | |
Rich Lane | 7dcdf02 | 2013-12-11 14:45:27 -0800 | [diff] [blame] | 960 | instruction.subtypes[2] = write_metadata |
Rich Lane | ca3da27 | 2013-05-05 09:07:33 -0700 | [diff] [blame] | 961 | |
Rich Lane | 7b0f201 | 2013-11-22 14:15:26 -0800 | [diff] [blame] | 962 | |