[dpdk-stable] patch 'net/i40e: fix parsing QinQ pattern' has been queued to stable release 17.05.2

Yuanhan Liu yliu at fridaylinux.org
Mon Aug 21 11:31:02 CEST 2017


Hi,

FYI, your patch has been queued to stable release 17.05.2

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 08/24/17. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From fde5ad1665fb5fd99ed640719e5e069552031ba7 Mon Sep 17 00:00:00 2001
From: Kuba Kozak <kubax.kozak at intel.com>
Date: Thu, 27 Jul 2017 09:28:22 +0200
Subject: [PATCH] net/i40e: fix parsing QinQ pattern

[ upstream commit c2be7f9b232fd6730dcec83555af050941c7805f ]

Add check if o_vlan_mask and i_vlan_mask are not a NULL pointer.

Coverity issue: 143448
Coverity issue: 143449
Fixes: d37705068ee8 ("net/i40e: parse QinQ pattern")

Signed-off-by: Kuba Kozak <kubax.kozak at intel.com>
Acked-by: Jingjing Wu <jingjing.wu at intel.com>
---
 drivers/net/i40e/i40e_flow.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_flow.c b/drivers/net/i40e/i40e_flow.c
index 24e1c65..c1dac38 100644
--- a/drivers/net/i40e/i40e_flow.c
+++ b/drivers/net/i40e/i40e_flow.c
@@ -1821,8 +1821,10 @@ i40e_flow_parse_qinq_pattern(__rte_unused struct rte_eth_dev *dev,
 	}
 
 	/* Get filter specification */
-	if ((o_vlan_mask->tci == rte_cpu_to_be_16(I40E_TCI_MASK)) &&
-	    (i_vlan_mask->tci == rte_cpu_to_be_16(I40E_TCI_MASK))) {
+	if ((o_vlan_mask != NULL) && (o_vlan_mask->tci ==
+			rte_cpu_to_be_16(I40E_TCI_MASK)) &&
+			(i_vlan_mask != NULL) &&
+			(i_vlan_mask->tci == rte_cpu_to_be_16(I40E_TCI_MASK))) {
 		filter->outer_vlan = rte_be_to_cpu_16(o_vlan_spec->tci)
 			& I40E_TCI_MASK;
 		filter->inner_vlan = rte_be_to_cpu_16(i_vlan_spec->tci)
-- 
2.7.4



More information about the stable mailing list