openflow-common: Change flow removal reason codes.
authorJarno Rajahalme <jarno.rajahalme@nsn.com>
Wed, 26 Jun 2013 22:39:48 +0000 (01:39 +0300)
committerBen Pfaff <blp@nicira.com>
Wed, 26 Jun 2013 22:49:58 +0000 (15:49 -0700)
Swap places of OFPRR_METER_DELETE and OFPRR_EVICTION in enumeration to be
compatible with OpenFlow 1.4.

Prior to OpenFlow 1.4 OFPRR_EVICTION was a Nicira specific flow removal reason
code.  OpenFlow 1.3 added support for meters, which require dependent flow
removal when meters are deleted.  The reason code for this is also added in
OpenFlow 1.4, but OFPRR_METER_DELETE now has the value OVS previously had for
OFPRR_EVICTION.

Signed-off-by: Jarno Rajahalme <jarno.rajahalme@nsn.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
include/openflow/openflow-common.h
tests/ofp-print.at

index d3b4e61..a9e5a76 100644 (file)
@@ -374,8 +374,8 @@ enum ofp_flow_removed_reason {
     OFPRR_HARD_TIMEOUT,         /* Time exceeded hard_timeout. */
     OFPRR_DELETE,               /* Evicted by a DELETE flow mod. */
     OFPRR_GROUP_DELETE,         /* Group was removed. */
-    OFPRR_EVICTION,             /* Switch eviction to free resources. */
     OFPRR_METER_DELETE,         /* Meter was removed. */
+    OFPRR_EVICTION,             /* Switch eviction to free resources. */
 };
 
 /* What changed about the physical port */
index b3e3eb5..a7fef55 100644 (file)
@@ -2179,7 +2179,7 @@ AT_SETUP([NXST_FLOW_MONITOR reply])
 AT_KEYWORDS([ofp-print OFPT_STATS_REPLY])
 AT_CHECK([ovs-ofctl ofp-print "\
 01 11 00 40 00 00 00 04 ff ff 00 00 00 00 23 20 00 00 00 02 00 00 00 00 \
-00 20 00 01 00 04 80 00 00 05 00 10 00 06 01 00 12 34 56 78 9a bc de f0 \
+00 20 00 01 00 05 80 00 00 05 00 10 00 06 01 00 12 34 56 78 9a bc de f0 \
 00 00 00 02 00 01 00 00 \
 00 08 00 03 00 01 86 a0 \
 "], [0], [dnl