From 6ce45939debcd3166d4d2fc532c8de298a27032d Mon Sep 17 00:00:00 2001 From: Sriram Natarajan Date: Fri, 21 Mar 2014 14:59:44 +0900 Subject: rest_router: fix OFPSetAsync bit mask Signed-off-by: FUJITA Tomonori --- ryu/app/rest_router.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/ryu/app/rest_router.py b/ryu/app/rest_router.py index e502d89d..fb1e7d6d 100644 --- a/ryu/app/rest_router.py +++ b/ryu/app/rest_router.py @@ -1818,14 +1818,14 @@ class OfCtl_v1_3(OfCtl_after_v1_2): super(OfCtl_v1_3, self).__init__(dp, logger) def set_sw_config_for_ttl(self): - packet_in_mask = (self.dp.ofproto.OFPR_ACTION | - self.dp.ofproto.OFPR_INVALID_TTL) - port_status_mask = (self.dp.ofproto.OFPPR_ADD | - self.dp.ofproto.OFPPR_DELETE | - self.dp.ofproto.OFPPR_MODIFY) - flow_removed_mask = (self.dp.ofproto.OFPRR_IDLE_TIMEOUT | - self.dp.ofproto.OFPRR_HARD_TIMEOUT | - self.dp.ofproto.OFPRR_DELETE) + packet_in_mask = (1 << self.dp.ofproto.OFPR_ACTION | + 1 << self.dp.ofproto.OFPR_INVALID_TTL) + port_status_mask = (1 << self.dp.ofproto.OFPPR_ADD | + 1 << self.dp.ofproto.OFPPR_DELETE | + 1 << self.dp.ofproto.OFPPR_MODIFY) + flow_removed_mask = (1 << self.dp.ofproto.OFPRR_IDLE_TIMEOUT | + 1 << self.dp.ofproto.OFPRR_HARD_TIMEOUT | + 1 << self.dp.ofproto.OFPRR_DELETE) m = self.dp.ofproto_parser.OFPSetAsync( self.dp, [packet_in_mask, 0], [port_status_mask, 0], [flow_removed_mask, 0]) -- cgit v1.2.3