Skip to content
This repository was archived by the owner on Apr 22, 2024. It is now read-only.

Commit b00d501

Browse files
committed
Add missing details from the spec in v0x04
1 parent 163032c commit b00d501

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

pyof/v0x04/common/constants.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
"""Here we have the constants related to v0x04 version."""
22
OFP_VERSION = 0x04
3+
OFP_NO_BUFFER = 0xffffffff

pyof/v0x04/controller2switch/flow_mod.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
# Local source tree imports
77
from pyof.foundation.base import GenericBitMask, GenericMessage
88
from pyof.foundation.basic_types import Pad, UBInt8, UBInt16, UBInt32, UBInt64
9+
from pyof.v0x04.common.flow_instructions import ListOfInstruction
910
from pyof.v0x04.common.flow_match import Match
1011
from pyof.v0x04.common.header import Header, Type
1112

@@ -64,11 +65,12 @@ class FlowMod(GenericMessage):
6465
flags = UBInt16(enum_ref=FlowModFlags)
6566
pad = Pad(2)
6667
match = Match()
68+
instructions = ListOfInstruction()
6769

6870
def __init__(self, xid=None, cookie=None, cookie_mask=None, table_id=None,
6971
command=None, idle_timeout=None, hard_timeout=None,
7072
priority=None, buffer_id=None, out_port=None, out_group=None,
71-
flags=None, match=None):
73+
flags=None, match=None, instructions=None):
7274
"""Create a FlowMod with the optional parameters below.
7375
7476
Args:
@@ -111,3 +113,4 @@ def __init__(self, xid=None, cookie=None, cookie_mask=None, table_id=None,
111113
self.out_group = out_group
112114
self.flags = flags
113115
self.match = match
116+
self.instructions = instructions

0 commit comments

Comments
 (0)