]>
Commit | Line | Data |
---|---|---|
ffc20820 GKH |
1 | From foo@baz Fri 31 May 2019 03:16:39 PM PDT |
2 | From: Raju Rangoju <rajur@chelsio.com> | |
3 | Date: Thu, 23 May 2019 20:41:44 +0530 | |
4 | Subject: cxgb4: offload VLAN flows regardless of VLAN ethtype | |
5 | ||
6 | From: Raju Rangoju <rajur@chelsio.com> | |
7 | ||
8 | [ Upstream commit b5730061d1056abf317caea823b94d6e12b5b4f6 ] | |
9 | ||
10 | VLAN flows never get offloaded unless ivlan_vld is set in filter spec. | |
11 | It's not compulsory for vlan_ethtype to be set. | |
12 | ||
13 | So, always enable ivlan_vld bit for offloading VLAN flows regardless of | |
14 | vlan_ethtype is set or not. | |
15 | ||
16 | Fixes: ad9af3e09c (cxgb4: add tc flower match support for vlan) | |
17 | Signed-off-by: Raju Rangoju <rajur@chelsio.com> | |
18 | Signed-off-by: David S. Miller <davem@davemloft.net> | |
19 | Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | |
20 | --- | |
21 | drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_flower.c | 5 +++-- | |
22 | 1 file changed, 3 insertions(+), 2 deletions(-) | |
23 | ||
24 | --- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_flower.c | |
25 | +++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_tc_flower.c | |
26 | @@ -197,6 +197,9 @@ static void cxgb4_process_flow_match(str | |
27 | fs->val.ivlan = vlan_tci; | |
28 | fs->mask.ivlan = vlan_tci_mask; | |
29 | ||
30 | + fs->val.ivlan_vld = 1; | |
31 | + fs->mask.ivlan_vld = 1; | |
32 | + | |
33 | /* Chelsio adapters use ivlan_vld bit to match vlan packets | |
34 | * as 802.1Q. Also, when vlan tag is present in packets, | |
35 | * ethtype match is used then to match on ethtype of inner | |
36 | @@ -207,8 +210,6 @@ static void cxgb4_process_flow_match(str | |
37 | * ethtype value with ethtype of inner header. | |
38 | */ | |
39 | if (fs->val.ethtype == ETH_P_8021Q) { | |
40 | - fs->val.ivlan_vld = 1; | |
41 | - fs->mask.ivlan_vld = 1; | |
42 | fs->val.ethtype = 0; | |
43 | fs->mask.ethtype = 0; | |
44 | } |