[ovs-dev] [PATCH v2 09/11] ofp-actions: Allow pop_mpls on MPLS packets

Simon Horman horms at verge.net.au
Wed Apr 16 06:30:07 UTC 2014


With recirculation in place this should be safe.

XXX: What if recirculation is disabled???

Signed-off-by: Simon Horman <horms at verge.net.au>
---
 lib/ofp-actions.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/lib/ofp-actions.c b/lib/ofp-actions.c
index ce14004..69d6505 100644
--- a/lib/ofp-actions.c
+++ b/lib/ofp-actions.c
@@ -492,9 +492,6 @@ ofpact_from_nxast(const union ofp_action *a, enum ofputil_action_code code,
         break;
 
     case OFPUTIL_NXAST_POP_MPLS:
-        if (eth_type_mpls(a->pop_mpls.ethertype)) {
-            return OFPERR_OFPBAC_BAD_ARGUMENT;
-        }
         ofpact_put_POP_MPLS(out)->ethertype = a->pop_mpls.ethertype;
         break;
 
@@ -1259,9 +1256,6 @@ ofpact_from_openflow11(const union ofp_action *a, enum ofp_version version,
         break;
 
     case OFPUTIL_OFPAT11_POP_MPLS:
-        if (eth_type_mpls(a->ofp11_pop_mpls.ethertype)) {
-            return OFPERR_OFPBAC_BAD_ARGUMENT;
-        }
         ofpact_put_POP_MPLS(out)->ethertype = a->ofp11_pop_mpls.ethertype;
         break;
 
-- 
1.8.5.2




More information about the dev mailing list