This is my interpretation of a
missing piece of "Alternate approach to MPLS"

Signed-off-by: Simon Horman <ho...@verge.net.au>
---
 lib/match.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/match.c b/lib/match.c
index c35f310..7cb6073 100644
--- a/lib/match.c
+++ b/lib/match.c
@@ -509,6 +509,14 @@ match_set_mpls_bos(struct match *match, int idx, uint8_t 
mpls_bos)
     flow_set_mpls_bos(&match->flow, idx, mpls_bos);
 }
 
+/* Modifies 'match' so that the MPLS LSE is wildcarded. */
+void
+match_set_any_mpls_lse(struct match *match, int idx)
+{
+    match->wc.masks.mpls_lse[idx] = htonl(0);
+    flow_set_mpls_lse(&match->flow, idx, htonl(0));
+}
+
 /* Modifies 'match' so that it matches only packets with an MPLS header whose
  * LSE equals 'mpls_lse' */
 void
-- 
1.8.4

_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to