aboutsummaryrefslogtreecommitdiffstats
path: root/net/openvswitch/flow.c
diff options
context:
space:
mode:
authorMichał Mirosław <mirq-linux@rere.qmqm.pl>2018-11-08 12:44:50 -0500
committerDavid S. Miller <davem@davemloft.net>2018-11-08 22:49:31 -0500
commit9df46aefafa6dee81a27c2a9d8ba360abd8c5fe3 (patch)
treef2d3fc7dd5fa9ce4d97af32546be5e1815b3658f /net/openvswitch/flow.c
parentf723a1a293deefa7f25b3833266fa7eb18d877f7 (diff)
OVS: remove use of VLAN_TAG_PRESENT
This is a minimal change to allow removing of VLAN_TAG_PRESENT. It leaves OVS unable to use CFI bit, as fixing this would need a deeper surgery involving userspace interface. Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/openvswitch/flow.c')
-rw-r--r--net/openvswitch/flow.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/openvswitch/flow.c b/net/openvswitch/flow.c
index 35966da84769..fa393815991e 100644
--- a/net/openvswitch/flow.c
+++ b/net/openvswitch/flow.c
@@ -325,7 +325,7 @@ static int parse_vlan_tag(struct sk_buff *skb, struct vlan_head *key_vh,
325 return -ENOMEM; 325 return -ENOMEM;
326 326
327 vh = (struct vlan_head *)skb->data; 327 vh = (struct vlan_head *)skb->data;
328 key_vh->tci = vh->tci | htons(VLAN_TAG_PRESENT); 328 key_vh->tci = vh->tci | htons(VLAN_CFI_MASK);
329 key_vh->tpid = vh->tpid; 329 key_vh->tpid = vh->tpid;
330 330
331 if (unlikely(untag_vlan)) { 331 if (unlikely(untag_vlan)) {
@@ -358,7 +358,7 @@ static int parse_vlan(struct sk_buff *skb, struct sw_flow_key *key)
358 int res; 358 int res;
359 359
360 if (skb_vlan_tag_present(skb)) { 360 if (skb_vlan_tag_present(skb)) {
361 key->eth.vlan.tci = htons(skb->vlan_tci); 361 key->eth.vlan.tci = htons(skb->vlan_tci) | htons(VLAN_CFI_MASK);
362 key->eth.vlan.tpid = skb->vlan_proto; 362 key->eth.vlan.tpid = skb->vlan_proto;
363 } else { 363 } else {
364 /* Parse outer vlan tag in the non-accelerated case. */ 364 /* Parse outer vlan tag in the non-accelerated case. */