use ofproto.OFP_NO_BUFFER in some places
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
parent
9104a8e7d4
commit
b2636e0cc1
@ -958,5 +958,5 @@ class GRETunnel(app_manager.RyuApp):
|
|||||||
# for debug
|
# for debug
|
||||||
msg = ev.msg
|
msg = ev.msg
|
||||||
self.logger.debug('packet in ev %s msg %s', ev, ev.msg)
|
self.logger.debug('packet in ev %s msg %s', ev, ev.msg)
|
||||||
if msg.buffer_id != 0xffffffff: # TODO:XXX use constant instead of -1
|
if msg.buffer_id != msg.datapath.ofproto.OFP_NO_BUFFER:
|
||||||
msg.datapath.send_packet_out(msg.buffer_id, msg.in_port, [])
|
msg.datapath.send_packet_out(msg.buffer_id, msg.in_port, [])
|
||||||
|
@ -74,7 +74,7 @@ class SimpleIsolation(app_manager.RyuApp):
|
|||||||
rule=rule, cookie=0, command=datapath.ofproto.OFPFC_ADD,
|
rule=rule, cookie=0, command=datapath.ofproto.OFPFC_ADD,
|
||||||
idle_timeout=0, hard_timeout=0,
|
idle_timeout=0, hard_timeout=0,
|
||||||
priority=ofproto.OFP_DEFAULT_PRIORITY,
|
priority=ofproto.OFP_DEFAULT_PRIORITY,
|
||||||
buffer_id=0xffffffff, out_port=ofproto.OFPP_NONE,
|
buffer_id=ofproto.OFP_NO_BUFFER, out_port=ofproto.OFPP_NONE,
|
||||||
flags=ofproto.OFPFF_SEND_FLOW_REM, actions=actions)
|
flags=ofproto.OFPFF_SEND_FLOW_REM, actions=actions)
|
||||||
|
|
||||||
datapath.send_packet_out(msg.buffer_id, msg.in_port, actions)
|
datapath.send_packet_out(msg.buffer_id, msg.in_port, actions)
|
||||||
|
@ -244,7 +244,7 @@ def mod_flow_entry(dp, flow, cmd):
|
|||||||
idle_timeout = int(flow.get('idle_timeout', 0))
|
idle_timeout = int(flow.get('idle_timeout', 0))
|
||||||
hard_timeout = int(flow.get('hard_timeout', 0))
|
hard_timeout = int(flow.get('hard_timeout', 0))
|
||||||
priority = int(flow.get('priority', 0))
|
priority = int(flow.get('priority', 0))
|
||||||
buffer_id = int(flow.get('buffer_id', 0xffffffff))
|
buffer_id = int(flow.get('buffer_id', dp.ofproto.OFP_NO_BUFFER))
|
||||||
out_port = int(flow.get('out_port', dp.ofproto.OFPP_ANY))
|
out_port = int(flow.get('out_port', dp.ofproto.OFPP_ANY))
|
||||||
out_group = int(flow.get('out_group', dp.ofproto.OFPG_ANY))
|
out_group = int(flow.get('out_group', dp.ofproto.OFPG_ANY))
|
||||||
flags = int(flow.get('flags', 0))
|
flags = int(flow.get('flags', 0))
|
||||||
|
@ -632,8 +632,8 @@ class Switches(app_manager.RyuApp):
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def _drop_packet(msg):
|
def _drop_packet(msg):
|
||||||
buffer_id = msg.buffer_id
|
buffer_id = msg.buffer_id
|
||||||
if buffer_id == 0xffffffff:
|
if buffer_id == msg.datapath.ofproto.OFP_NO_BUFFER:
|
||||||
return # TODO:use constant instead of -1
|
return
|
||||||
|
|
||||||
dp = msg.datapath
|
dp = msg.datapath
|
||||||
# TODO:XXX
|
# TODO:XXX
|
||||||
|
Loading…
x
Reference in New Issue
Block a user