- add a note about type and type_.
- change 0xffffffff into OFP_NO_BUFFER.

Signed-off-by: Yoshihiro Kaneko <[email protected]>
---
 ryu/ofproto/ofproto_v1_2_parser.py |   14 +++++++++++---
 ryu/ofproto/ofproto_v1_3_parser.py |   12 +++++++++---
 2 files changed, 20 insertions(+), 6 deletions(-)

diff --git a/ryu/ofproto/ofproto_v1_2_parser.py 
b/ryu/ofproto/ofproto_v1_2_parser.py
index 382cc32..0f37ca5 100644
--- a/ryu/ofproto/ofproto_v1_2_parser.py
+++ b/ryu/ofproto/ofproto_v1_2_parser.py
@@ -83,6 +83,8 @@ class OFPErrorMsg(MsgBase):
     data       Variable length data depending on the type and code
     ========== =========================================================
 
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
+
     Types and codes are defined in ``ryu.ofproto.ofproto_v1_2``.
 
     ============================= ===========
@@ -757,7 +759,7 @@ class OFPPacketOut(MsgBase):
     ================ ======================================================
     Attribute        Description
     ================ ======================================================
-    buffer_id        ID assigned by datapath (0xffffffff if none)
+    buffer_id        ID assigned by datapath (OFP_NO_BUFFER if none)
     in_port          Packet's input port or ``OFPP_CONTROLLER``
     actions          list of OpenFlow action class
     data             Packet data
@@ -829,7 +831,7 @@ class OFPFlowMod(MsgBase):
     idle_timeout     Idle time before discarding (seconds)
     hard_timeout     Max time before discarding (seconds)
     priority         Priority level of flow entry
-    buffer_id        Buffered packet to apply to (or 0xffffffff)
+    buffer_id        Buffered packet to apply to (or OFP_NO_BUFFER)
     out_port         For ``OFPFC_DELETE*`` commands, require matching
                      entries to include this as an output port
     out_group        For ``OFPFC_DELETE*`` commands, require matching
@@ -852,7 +854,7 @@ class OFPFlowMod(MsgBase):
             table_id = 0
             idle_timeout = hard_timeout = 0
             priority = 32768
-            buffer_id = 0xffffffff
+            buffer_id = ofp.OFP_NO_BUFFER
             match = ofp_parser.OFPMatch(in_port=1, eth_dst='ff:ff:ff:ff:ff:ff')
             actions = [ofp_parser.OFPActionOutput(ofp.OFPP_NORMAL, 0)]
             inst = [ofp_parser.OFPInstructionActions(ofp.OFPIT_APPLY_ACTIONS,
@@ -1014,6 +1016,8 @@ class OFPInstructionActions(StringifyMixin):
                      OFPIT_CLEAR_ACTIONS
     actions          list of OpenFlow action class
     ================ ======================================================
+
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
     """
     _base_attributes = ['len']
 
@@ -1639,6 +1643,8 @@ class OFPGroupMod(MsgBase):
     buckets          list of ``OFPBucket``
     ================ ======================================================
 
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
+
     Example::
 
         def send_group_mod(self, datapath):
@@ -2692,6 +2698,8 @@ class OFPGroupDescStats(StringifyMixin):
     buckets          List of ``OFPBucket`` instance
     ================ ======================================================
 
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
+
     Example::
 
         @set_ev_cls(ofp_event.EventOFPStatsReply, MAIN_DISPATCHER)
diff --git a/ryu/ofproto/ofproto_v1_3_parser.py 
b/ryu/ofproto/ofproto_v1_3_parser.py
index 3b5a4b4..b29b282 100644
--- a/ryu/ofproto/ofproto_v1_3_parser.py
+++ b/ryu/ofproto/ofproto_v1_3_parser.py
@@ -155,6 +155,8 @@ class OFPErrorMsg(MsgBase):
     data       Variable length data depending on the type and code
     ========== =========================================================
 
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
+
     Types and codes are defined in ``ryu.ofproto.ofproto_v1_3``.
 
     ============================= ===========
@@ -2189,7 +2191,7 @@ class OFPPacketOut(MsgBase):
     ================ ======================================================
     Attribute        Description
     ================ ======================================================
-    buffer_id        ID assigned by datapath (0xffffffff if none)
+    buffer_id        ID assigned by datapath (OFP_NO_BUFFER if none)
     in_port          Packet's input port or ``OFPP_CONTROLLER``
     actions          list of OpenFlow action class
     data             Packet data
@@ -2258,7 +2260,7 @@ class OFPFlowMod(MsgBase):
     idle_timeout     Idle time before discarding (seconds)
     hard_timeout     Max time before discarding (seconds)
     priority         Priority level of flow entry
-    buffer_id        Buffered packet to apply to (or 0xffffffff)
+    buffer_id        Buffered packet to apply to (or OFP_NO_BUFFER)
     out_port         For ``OFPFC_DELETE*`` commands, require matching
                      entries to include this as an output port
     out_group        For ``OFPFC_DELETE*`` commands, require matching
@@ -2283,7 +2285,7 @@ class OFPFlowMod(MsgBase):
             table_id = 0
             idle_timeout = hard_timeout = 0
             priority = 32768
-            buffer_id = 0xffffffff
+            buffer_id = ofp.OFP_NO_BUFFER
             match = ofp_parser.OFPMatch(in_port=1, eth_dst='ff:ff:ff:ff:ff:ff')
             actions = [ofp_parser.OFPActionOutput(ofp.OFPP_NORMAL, 0)]
             inst = [ofp_parser.OFPInstructionActions(ofp.OFPIT_APPLY_ACTIONS,
@@ -2445,6 +2447,8 @@ class OFPInstructionActions(StringifyMixin):
                      OFPIT_CLEAR_ACTIONS
     actions          list of OpenFlow action class
     ================ ======================================================
+
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
     """
     _base_attributes = ['len']
 
@@ -3086,6 +3090,8 @@ class OFPGroupMod(MsgBase):
     buckets          list of ``OFPBucket``
     ================ ======================================================
 
+    ``type`` attribute corresponds to ``type_`` parameter of __init__.
+
     Example::
 
         def send_group_mod(self, datapath):
-- 
1.7.9.5


------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to