patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8
@ 2018-07-24 16:07 luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: change memory type' " luca.boccassi
                   ` (32 more replies)
  0 siblings, 33 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Rafal Kozik; +Cc: Michal Krawczyk, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 8cc1278eaeb0eb07513ebc7e76e4c7d907da44a2 Mon Sep 17 00:00:00 2001
From: Rafal Kozik <rk@semihalf.com>
Date: Thu, 7 Jun 2018 11:43:18 +0200
Subject: [PATCH] net/ena: check pointer before memset

[ upstream commit 46916aa17d4b2007df8c0454f99ba0ca8b8cb93b ]

Need to check if memory allocation succeed before using it.
Using memset on NULL pointer cause segfault.

Fixes: 9ba7981ec992 ("ena: add communication layer for DPDK")

Signed-off-by: Rafal Kozik <rk@semihalf.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/net/ena/base/ena_plat_dpdk.h | 21 ++++++++++++++++-----
 1 file changed, 16 insertions(+), 5 deletions(-)

diff --git a/drivers/net/ena/base/ena_plat_dpdk.h b/drivers/net/ena/base/ena_plat_dpdk.h
index 87c3bf13b..aa242204c 100644
--- a/drivers/net/ena/base/ena_plat_dpdk.h
+++ b/drivers/net/ena/base/ena_plat_dpdk.h
@@ -188,10 +188,15 @@ typedef uint64_t dma_addr_t;
 		snprintf(z_name, sizeof(z_name),			\
 				"ena_alloc_%d", ena_alloc_cnt++);	\
 		mz = rte_memzone_reserve(z_name, size, SOCKET_ID_ANY, 0); \
-		memset(mz->addr, 0, size);				\
-		virt = mz->addr;					\
-		phys = mz->phys_addr;					\
 		handle = mz;						\
+		if (mz == NULL) {					\
+			virt = NULL;					\
+			phys = 0;					\
+		} else {						\
+			memset(mz->addr, 0, size);			\
+			virt = mz->addr;				\
+			phys = mz->phys_addr;				\
+		}							\
 	} while (0)
 #define ENA_MEM_FREE_COHERENT(dmadev, size, virt, phys, handle) 	\
 		({ ENA_TOUCH(size); ENA_TOUCH(phys);			\
@@ -206,8 +211,14 @@ typedef uint64_t dma_addr_t;
 		snprintf(z_name, sizeof(z_name),			\
 				"ena_alloc_%d", ena_alloc_cnt++);	\
 		mz = rte_memzone_reserve(z_name, size, node, 0); \
-		virt = mz->addr;					\
-		phys = mz->phys_addr;					\
+		if (mz == NULL) {					\
+			virt = NULL;					\
+			phys = 0;					\
+		} else {						\
+			memset(mz->addr, 0, size);			\
+			virt = mz->addr;				\
+			phys = mz->phys_addr;				\
+		}							\
 	} while (0)
 
 #define ENA_MEM_ALLOC_NODE(dmadev, size, virt, node, dev_node) \
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ena: change memory type' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: fix GENMASK_ULL macro' " luca.boccassi
                   ` (31 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Rafal Kozik; +Cc: Michal Krawczyk, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 2da2a62cfbf5c6785ffb2a8dade83e37ea271d25 Mon Sep 17 00:00:00 2001
From: Rafal Kozik <rk@semihalf.com>
Date: Thu, 7 Jun 2018 11:43:19 +0200
Subject: [PATCH] net/ena: change memory type

[ upstream commit 9f32c7e7e6ce58ab772913f54f8328c1c0186a17 ]

ENA_MEM_ALLOC_NODE not need to use contiguous physical memory.
Also using memset without checking if allocation succeed can cause
segmentation fault.

To avoid both issue use rte_zmalloc_socket.

Fixes: 3d3edc265fc8 ("net/ena: make coherent memory allocation NUMA-aware")

Signed-off-by: Rafal Kozik <rk@semihalf.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/net/ena/base/ena_plat_dpdk.h | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/net/ena/base/ena_plat_dpdk.h b/drivers/net/ena/base/ena_plat_dpdk.h
index aa242204c..ff873e807 100644
--- a/drivers/net/ena/base/ena_plat_dpdk.h
+++ b/drivers/net/ena/base/ena_plat_dpdk.h
@@ -223,13 +223,8 @@ typedef uint64_t dma_addr_t;
 
 #define ENA_MEM_ALLOC_NODE(dmadev, size, virt, node, dev_node) \
 	do {								\
-		const struct rte_memzone *mz;				\
-		char z_name[RTE_MEMZONE_NAMESIZE];			\
 		ENA_TOUCH(dmadev); ENA_TOUCH(dev_node);			\
-		snprintf(z_name, sizeof(z_name),			\
-				"ena_alloc_%d", ena_alloc_cnt++);	\
-		mz = rte_memzone_reserve(z_name, size, node, 0); \
-		virt = mz->addr;					\
+		virt = rte_zmalloc_socket(NULL, size, 0, node);		\
 	} while (0)
 
 #define ENA_MEM_ALLOC(dmadev, size) rte_zmalloc(NULL, size, 1)
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ena: fix GENMASK_ULL macro' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: change memory type' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: set link speed as none' " luca.boccassi
                   ` (30 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Rafal Kozik; +Cc: Michal Krawczyk, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 7f1e6913eafb541a24f1d390b886167215eea5df Mon Sep 17 00:00:00 2001
From: Rafal Kozik <rk@semihalf.com>
Date: Thu, 7 Jun 2018 11:43:20 +0200
Subject: [PATCH] net/ena: fix GENMASK_ULL macro

[ upstream commit 7544aee8d0b4ae0262b1ba7e1539cf8171664df7 ]

When use GENMASK_ULL(63,0) left shift by 64 bits is performed.
Shifting by number greater or equal then word length
is undefined operation and failed on some platforms.

Fixes: 9ba7981ec992 ("ena: add communication layer for DPDK")

Signed-off-by: Rafal Kozik <rk@semihalf.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/net/ena/base/ena_plat_dpdk.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ena/base/ena_plat_dpdk.h b/drivers/net/ena/base/ena_plat_dpdk.h
index ff873e807..791b44ff7 100644
--- a/drivers/net/ena/base/ena_plat_dpdk.h
+++ b/drivers/net/ena/base/ena_plat_dpdk.h
@@ -115,11 +115,13 @@ typedef uint64_t dma_addr_t;
 #define ENA_MIN16(x, y) RTE_MIN((x), (y))
 #define ENA_MIN8(x, y) RTE_MIN((x), (y))
 
+#define BITS_PER_LONG_LONG (__SIZEOF_LONG_LONG__ * 8)
 #define U64_C(x) x ## ULL
 #define BIT(nr)         (1UL << (nr))
 #define BITS_PER_LONG	(__SIZEOF_LONG__ * 8)
 #define GENMASK(h, l)	(((~0UL) << (l)) & (~0UL >> (BITS_PER_LONG - 1 - (h))))
-#define GENMASK_ULL(h, l) (((U64_C(1) << ((h) - (l) + 1)) - 1) << (l))
+#define GENMASK_ULL(h, l) (((~0ULL) - (1ULL << (l)) + 1) & \
+			  (~0ULL >> (BITS_PER_LONG_LONG - 1 - (h))))
 
 #ifdef RTE_LIBRTE_ENA_COM_DEBUG
 #define ena_trc_dbg(format, arg...)					\
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ena: set link speed as none' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: change memory type' " luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: fix GENMASK_ULL macro' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/nfp: fix field initialization in Tx descriptor' " luca.boccassi
                   ` (29 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Rafal Kozik; +Cc: Michal Krawczyk, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 3e827bce5db253623074c89f26dbe1141e393979 Mon Sep 17 00:00:00 2001
From: Rafal Kozik <rk@semihalf.com>
Date: Thu, 7 Jun 2018 11:43:22 +0200
Subject: [PATCH] net/ena: set link speed as none

[ upstream commit 41e59028dd8ab2038a7655c6fc3098222661aa53 ]

Link speed should is not limited to 10Gb/s and it shouldn't be hardcoded.

They link speed is set to none instead and the applications shouldn't
rely on this value when using ENA PMD.

Fixes: 1173fca25af9 ("ena: add polling-mode driver")

Signed-off-by: Rafal Kozik <rk@semihalf.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/net/ena/ena_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index 63c423627..2bb8655a1 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -697,7 +697,7 @@ static int ena_link_update(struct rte_eth_dev *dev,
 	struct rte_eth_link *link = &dev->data->dev_link;
 
 	link->link_status = 1;
-	link->link_speed = ETH_SPEED_NUM_10G;
+	link->link_speed = ETH_SPEED_NUM_NONE;
 	link->link_duplex = ETH_LINK_FULL_DUPLEX;
 
 	return 0;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/nfp: fix field initialization in Tx descriptor' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (2 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: set link speed as none' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bonding: fix MAC address reset' " luca.boccassi
                   ` (28 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Alejandro Lucero; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 014c7deb627bbc57d887c4cf1e39b342e6aed320 Mon Sep 17 00:00:00 2001
From: Alejandro Lucero <alejandro.lucero@netronome.com>
Date: Mon, 11 Jun 2018 10:50:37 +0100
Subject: [PATCH] net/nfp: fix field initialization in Tx descriptor

[ upstream commit 01f65293ceb94921a35554fa7b17bc0ec1764c96 ]

TX descriptor eop_offset field is not initialized and it could
contain garbage. This patch fixes the potential problem setting
EOP as the only subfield. The other subfield, data offset, is
not used by now.

Fixes: b812daadad0d ("nfp: add Rx and Tx")

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
---
 drivers/net/nfp/nfp_net.c | 14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

diff --git a/drivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c
index 458114982..0f0589e06 100644
--- a/drivers/net/nfp/nfp_net.c
+++ b/drivers/net/nfp/nfp_net.c
@@ -2023,11 +2023,15 @@ nfp_net_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
 				txq->tail = 0;
 
 			pkt_size -= dma_size;
-			if (!pkt_size) {
-				/* End of packet */
-				txds->offset_eop |= PCIE_DESC_TX_EOP;
-			} else {
-				txds->offset_eop &= PCIE_DESC_TX_OFFSET_MASK;
+
+			/*
+			 * Making the EOP, packets with just one segment
+			 * the priority
+			 */
+			if (likely(!pkt_size))
+				txds->offset_eop = PCIE_DESC_TX_EOP;
+			else {
+				txds->offset_eop = 0;
 				pkt = pkt->next;
 			}
 			/* Referencing next free TX descriptor */
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bonding: fix MAC address reset' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (3 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/nfp: fix field initialization in Tx descriptor' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'mbuf: fix typo in IPv6 macro comment' " luca.boccassi
                   ` (27 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Kiran Kumar; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 66b2caa33cda07f5593bec4f59d16990be638d3b Mon Sep 17 00:00:00 2001
From: Kiran Kumar <kiran.kokkilagadda@caviumnetworks.com>
Date: Wed, 23 May 2018 14:41:21 +0530
Subject: [PATCH] net/bonding: fix MAC address reset

[ upstream commit fb6eb1e69c499feb5f36193b906c910553835cc6 ]

Currently when resetting bond mac address, we are getting the
persisted mac address from slave info considering primary port
as index. But we need to compare the port id from slave info
with the primary port to get the primary slave index and get
the persisted mac address. Without this fix, persisted mac addr
will be zero and rte_eth_dev_default_mac_addr_set will fail.

Fixes: a45b288ef21a ("bond: support link status polling")

Signed-off-by: Kiran Kumar <kiran.kokkilagadda@caviumnetworks.com>
---
 drivers/net/bonding/rte_eth_bond_api.c | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/drivers/net/bonding/rte_eth_bond_api.c b/drivers/net/bonding/rte_eth_bond_api.c
index 7bb2fe1ec..fa6f9582d 100644
--- a/drivers/net/bonding/rte_eth_bond_api.c
+++ b/drivers/net/bonding/rte_eth_bond_api.c
@@ -780,9 +780,21 @@ rte_eth_bond_mac_address_reset(uint8_t bonded_port_id)
 	internals->user_defined_mac = 0;
 
 	if (internals->slave_count > 0) {
+		int slave_port;
+		/* Get the primary slave location based on the primary port
+		 * number as, while slave_add(), we will keep the primary
+		 * slave based on slave_count,but not based on the primary port.
+		 */
+		for (slave_port = 0; slave_port < internals->slave_count;
+		     slave_port++) {
+			if (internals->slaves[slave_port].port_id ==
+			    internals->primary_port)
+				break;
+		}
+
 		/* Set MAC Address of Bonded Device */
 		if (mac_address_set(bonded_eth_dev,
-				&internals->slaves[internals->primary_port].persisted_mac_addr)
+			&internals->slaves[slave_port].persisted_mac_addr)
 				!= 0) {
 			RTE_BOND_LOG(ERR, "Failed to set MAC address on bonded device");
 			return -1;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'mbuf: fix typo in IPv6 macro comment' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (4 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bonding: fix MAC address reset' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'kni: fix build with gcc 8.1' " luca.boccassi
                   ` (26 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Haiyue Wang; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 45b83c26d72a3a65caac92f464961aa0b6e8b56e Mon Sep 17 00:00:00 2001
From: Haiyue Wang <haiyue.wang@intel.com>
Date: Thu, 14 Jun 2018 11:09:49 +0800
Subject: [PATCH] mbuf: fix typo in IPv6 macro comment

[ upstream commit af87183b82da32b2ca832a51acdb5a2a6117c718 ]

Comment should mention IPv6, not IPv4.

Fixes: f295a00a2b44 ("mbuf: add definitions of unified packet types")

Signed-off-by: Haiyue Wang <haiyue.wang@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 lib/librte_mbuf/rte_mbuf_ptype.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/librte_mbuf/rte_mbuf_ptype.h b/lib/librte_mbuf/rte_mbuf_ptype.h
index acd70bb6b..606434960 100644
--- a/lib/librte_mbuf/rte_mbuf_ptype.h
+++ b/lib/librte_mbuf/rte_mbuf_ptype.h
@@ -566,9 +566,9 @@ extern "C" {
 #define  RTE_ETH_IS_IPV4_HDR(ptype) ((ptype) & RTE_PTYPE_L3_IPV4)
 
 /**
- * Check if the (outer) L3 header is IPv4. To avoid comparing IPv4 types one by
- * one, bit 6 is selected to be used for IPv4 only. Then checking bit 6 can
- * determine if it is an IPV4 packet.
+ * Check if the (outer) L3 header is IPv6. To avoid comparing IPv6 types one by
+ * one, bit 6 is selected to be used for IPv6 only. Then checking bit 6 can
+ * determine if it is an IPV6 packet.
  */
 #define  RTE_ETH_IS_IPV6_HDR(ptype) ((ptype) & RTE_PTYPE_L3_IPV6)
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'kni: fix build with gcc 8.1' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (5 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'mbuf: fix typo in IPv6 macro comment' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net: rename u16 to fix shadowed declaration' " luca.boccassi
                   ` (25 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Ferruh Yigit; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From b0d01dc7e4fc20d7e5ec0ba2546bb9b11d0ffb7d Mon Sep 17 00:00:00 2001
From: Ferruh Yigit <ferruh.yigit@intel.com>
Date: Tue, 26 Jun 2018 12:38:07 +0100
Subject: [PATCH] kni: fix build with gcc 8.1
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit a36b40dd8ecfb61648045e418551f75055ca77f9 ]

Error observed when CONFIG_RTE_KNI_KMOD_ETHTOOL config option is
enabled.

build error:
In function ‘strncpy’,
    inlined from ‘igb_get_drvinfo’ at
    kernel/linux/kni/igb_ethtool.c:814:2:
    include/linux/string.h:246:9: error: ‘__builtin_strncpy’ output
    may be truncated copying 31 bytes from a string of length 42
    [-Werror=stringop-truncation]
      return __builtin_strncpy(p, q, size);
               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Fixed by using strlcpy instead of strncpy.

adapter->fw_version size kept same because of
c3698192940c ("kni: fix build with gcc 7.1")

Also next line strncpy usage replaced with strlcpy while arround.

Fixes: c3698192940c ("kni: fix build with gcc 7.1")

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c b/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
index d7a987d54..1110bef87 100644
--- a/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
+++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/igb_ethtool.c
@@ -826,9 +826,10 @@ static void igb_get_drvinfo(struct net_device *netdev,
 	strncpy(drvinfo->driver,  igb_driver_name, sizeof(drvinfo->driver) - 1);
 	strncpy(drvinfo->version, igb_driver_version, sizeof(drvinfo->version) - 1);
 
-	strncpy(drvinfo->fw_version, adapter->fw_version,
-		sizeof(drvinfo->fw_version) - 1);
-	strncpy(drvinfo->bus_info, pci_name(adapter->pdev), sizeof(drvinfo->bus_info) -1);
+	strlcpy(drvinfo->fw_version, adapter->fw_version,
+		sizeof(drvinfo->fw_version));
+	strlcpy(drvinfo->bus_info, pci_name(adapter->pdev),
+		sizeof(drvinfo->bus_info));
 	drvinfo->n_stats = IGB_STATS_LEN;
 	drvinfo->testinfo_len = IGB_TEST_LEN;
 	drvinfo->regdump_len = igb_get_regs_len(netdev);
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net: rename u16 to fix shadowed declaration' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (6 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'kni: fix build with gcc 8.1' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix tunnel id format error for FDIR' " luca.boccassi
                   ` (24 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Gage Eads; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From e1c736f81ba27736f5faf3236dfd89550bef4a34 Mon Sep 17 00:00:00 2001
From: Gage Eads <gage.eads@intel.com>
Date: Mon, 4 Jun 2018 14:40:00 -0500
Subject: [PATCH] net: rename u16 to fix shadowed declaration

[ upstream commit 68248ad1b9a8a5e84611346b699dd5d4f1bbe37d ]

This patch renames u16 to u16_buf. u16 as a variable name causes a shadowed
declaration warning if, for example, the application also typedefs u16
(e.g. by including a header containing "typedef unsigned short u16") and
the application is built with -Wshadow.

Signed-off-by: Gage Eads <gage.eads@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_net/rte_ip.h | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
index 19d6c95c8..5234663e5 100644
--- a/lib/librte_net/rte_ip.h
+++ b/lib/librte_net/rte_ip.h
@@ -170,25 +170,25 @@ __rte_raw_cksum(const void *buf, size_t len, uint32_t sum)
 	/* workaround gcc strict-aliasing warning */
 	uintptr_t ptr = (uintptr_t)buf;
 	typedef uint16_t __attribute__((__may_alias__)) u16_p;
-	const u16_p *u16 = (const u16_p *)ptr;
+	const u16_p *u16_buf = (const u16_p *)ptr;
 
-	while (len >= (sizeof(*u16) * 4)) {
-		sum += u16[0];
-		sum += u16[1];
-		sum += u16[2];
-		sum += u16[3];
-		len -= sizeof(*u16) * 4;
-		u16 += 4;
+	while (len >= (sizeof(*u16_buf) * 4)) {
+		sum += u16_buf[0];
+		sum += u16_buf[1];
+		sum += u16_buf[2];
+		sum += u16_buf[3];
+		len -= sizeof(*u16_buf) * 4;
+		u16_buf += 4;
 	}
-	while (len >= sizeof(*u16)) {
-		sum += *u16;
-		len -= sizeof(*u16);
-		u16 += 1;
+	while (len >= sizeof(*u16_buf)) {
+		sum += *u16_buf;
+		len -= sizeof(*u16_buf);
+		u16_buf += 1;
 	}
 
 	/* if length is in odd bytes */
 	if (len == 1)
-		sum += *((const uint8_t *)u16);
+		sum += *((const uint8_t *)u16_buf);
 
 	return sum;
 }
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ixgbe: fix tunnel id format error for FDIR' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (7 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net: rename u16 to fix shadowed declaration' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix tunnel type set " luca.boccassi
                   ` (23 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Wei Zhao; +Cc: Wenzhuo Lu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 0c3664c1924af9c5e505eda1f5712d830d66e255 Mon Sep 17 00:00:00 2001
From: Wei Zhao <wei.zhao1@intel.com>
Date: Wed, 13 Jun 2018 16:11:22 +0800
Subject: [PATCH] net/ixgbe: fix tunnel id format error for FDIR

[ upstream commit e7d406851909b1c3cc24ee8c61044dccf9902559 ]

In cloud mode for FDIR, tunnel id should be set as protocol
request, the lower 8 bits should be set as reserved.

Fixes: 82fb702077f6 ("ixgbe: support new flow director modes for X550")
Fixes: 11777435c727 ("net/ixgbe: parse flow director filter")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
---
 drivers/net/ixgbe/ixgbe_fdir.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ixgbe/ixgbe_fdir.c b/drivers/net/ixgbe/ixgbe_fdir.c
index 4b81ee379..351167a64 100644
--- a/drivers/net/ixgbe/ixgbe_fdir.c
+++ b/drivers/net/ixgbe/ixgbe_fdir.c
@@ -723,7 +723,7 @@ ixgbe_fdir_filter_to_atr_input(const struct rte_eth_fdir_filter *fdir_filter,
 		input->formatted.tunnel_type =
 			fdir_filter->input.flow.tunnel_flow.tunnel_type;
 		input->formatted.tni_vni =
-			fdir_filter->input.flow.tunnel_flow.tunnel_id;
+			fdir_filter->input.flow.tunnel_flow.tunnel_id >> 8;
 	}
 
 	return 0;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ixgbe: fix tunnel type set error for FDIR' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (8 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix tunnel id format error for FDIR' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix mask bits register " luca.boccassi
                   ` (22 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Wei Zhao; +Cc: Wenzhuo Lu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 5ec767e444ef4fd4a96aa2dd0ec2efcf5d735eaa Mon Sep 17 00:00:00 2001
From: Wei Zhao <wei.zhao1@intel.com>
Date: Thu, 14 Jun 2018 16:17:28 +0800
Subject: [PATCH] net/ixgbe: fix tunnel type set error for FDIR

[ upstream commit 876b450ed99d2c96c5b71360cc84f7b0b8f506f4 ]

Tunnel type format should be translated to ixgbe required format
before register set in FDIR cloud mode, Ans also some register
not useful in cloud mode but only useful in IP mode should be set
to zero as datasheet request.

Fixes: 82fb702077f6 ("ixgbe: support new flow director modes for X550")
Fixes: 11777435c727 ("net/ixgbe: parse flow director filter")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.h |  5 +++++
 drivers/net/ixgbe/ixgbe_fdir.c   | 19 +++++++++++++++----
 2 files changed, 20 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.h b/drivers/net/ixgbe/ixgbe_ethdev.h
index a4e2996a4..e1a97ea37 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.h
+++ b/drivers/net/ixgbe/ixgbe_ethdev.h
@@ -113,6 +113,11 @@
 #define IXGBE_5TUPLE_MAX_PRI            7
 #define IXGBE_5TUPLE_MIN_PRI            1
 
+/* bit of VXLAN tunnel type | 7 bits of zeros  | 8 bits of zeros*/
+#define IXGBE_FDIR_VXLAN_TUNNEL_TYPE    0x8000
+/* bit of NVGRE tunnel type | 7 bits of zeros  | 8 bits of zeros*/
+#define IXGBE_FDIR_NVGRE_TUNNEL_TYPE    0x0
+
 #define IXGBE_RSS_OFFLOAD_ALL ( \
 	ETH_RSS_IPV4 | \
 	ETH_RSS_NONFRAG_IPV4_TCP | \
diff --git a/drivers/net/ixgbe/ixgbe_fdir.c b/drivers/net/ixgbe/ixgbe_fdir.c
index 351167a64..62955bb75 100644
--- a/drivers/net/ixgbe/ixgbe_fdir.c
+++ b/drivers/net/ixgbe/ixgbe_fdir.c
@@ -720,8 +720,17 @@ ixgbe_fdir_filter_to_atr_input(const struct rte_eth_fdir_filter *fdir_filter,
 			input->formatted.inner_mac,
 			fdir_filter->input.flow.tunnel_flow.mac_addr.addr_bytes,
 			sizeof(input->formatted.inner_mac));
-		input->formatted.tunnel_type =
-			fdir_filter->input.flow.tunnel_flow.tunnel_type;
+		if (fdir_filter->input.flow.tunnel_flow.tunnel_type ==
+				RTE_FDIR_TUNNEL_TYPE_VXLAN)
+			input->formatted.tunnel_type =
+					IXGBE_FDIR_VXLAN_TUNNEL_TYPE;
+		else if (fdir_filter->input.flow.tunnel_flow.tunnel_type ==
+				RTE_FDIR_TUNNEL_TYPE_NVGRE)
+			input->formatted.tunnel_type =
+					IXGBE_FDIR_NVGRE_TUNNEL_TYPE;
+		else
+			PMD_DRV_LOG(ERR, " invalid tunnel type arguments.");
+
 		input->formatted.tni_vni =
 			fdir_filter->input.flow.tunnel_flow.tunnel_id >> 8;
 	}
@@ -950,8 +959,7 @@ fdir_write_perfect_filter_82599(struct ixgbe_hw *hw,
 			IXGBE_WRITE_REG(hw, IXGBE_FDIRSIPv6(2), 0);
 		} else {
 			/* tunnel mode */
-			if (input->formatted.tunnel_type !=
-				RTE_FDIR_TUNNEL_TYPE_NVGRE)
+			if (input->formatted.tunnel_type)
 				tunnel_type = 0x80000000;
 			tunnel_type |= addr_high;
 			IXGBE_WRITE_REG(hw, IXGBE_FDIRSIPv6(0), addr_low);
@@ -959,6 +967,9 @@ fdir_write_perfect_filter_82599(struct ixgbe_hw *hw,
 			IXGBE_WRITE_REG(hw, IXGBE_FDIRSIPv6(2),
 					input->formatted.tni_vni);
 		}
+		IXGBE_WRITE_REG(hw, IXGBE_FDIRIPSA, 0);
+		IXGBE_WRITE_REG(hw, IXGBE_FDIRIPDA, 0);
+		IXGBE_WRITE_REG(hw, IXGBE_FDIRPORT, 0);
 	}
 
 	/* record vlan (little-endian) and flex_bytes(big-endian) */
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ixgbe: fix mask bits register set error for FDIR' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (9 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix tunnel type set " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: fix shifts of 32-bit value' " luca.boccassi
                   ` (21 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Wei Zhao; +Cc: Wenzhuo Lu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From bb55f1087e9ed15ce27c5adcc74f6a3b72f95c43 Mon Sep 17 00:00:00 2001
From: Wei Zhao <wei.zhao1@intel.com>
Date: Fri, 15 Jun 2018 14:08:03 +0800
Subject: [PATCH] net/ixgbe: fix mask bits register set error for FDIR

[ upstream commit 5dadd757188e68260880924dea38c22858ac2ca9 ]

MAC address bits in mask registers should be set to zero
when the is mac mask is 0xFF, otherwise if it is 0x0
these bits should be to 0x3F.

Fixes: 82fb702077f6 ("ixgbe: support new flow director modes for X550")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
---
 drivers/net/ixgbe/ixgbe_fdir.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ixgbe/ixgbe_fdir.c b/drivers/net/ixgbe/ixgbe_fdir.c
index 62955bb75..2a6f754b3 100644
--- a/drivers/net/ixgbe/ixgbe_fdir.c
+++ b/drivers/net/ixgbe/ixgbe_fdir.c
@@ -433,10 +433,12 @@ fdir_set_input_mask_x550(struct rte_eth_dev *dev,
 				IXGBE_FDIRIP6M_TNI_VNI;
 
 	if (mode == RTE_FDIR_MODE_PERFECT_TUNNEL) {
-		mac_mask = input_mask->mac_addr_byte_mask;
-		fdiripv6m |= (mac_mask << IXGBE_FDIRIP6M_INNER_MAC_SHIFT)
-				& IXGBE_FDIRIP6M_INNER_MAC;
-		info->mask.mac_addr_byte_mask = input_mask->mac_addr_byte_mask;
+		fdiripv6m |= IXGBE_FDIRIP6M_INNER_MAC;
+		mac_mask = input_mask->mac_addr_byte_mask &
+			(IXGBE_FDIRIP6M_INNER_MAC >>
+			IXGBE_FDIRIP6M_INNER_MAC_SHIFT);
+		fdiripv6m &= ~((mac_mask << IXGBE_FDIRIP6M_INNER_MAC_SHIFT) &
+				IXGBE_FDIRIP6M_INNER_MAC);
 
 		switch (input_mask->tunnel_type_mask) {
 		case 0:
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/i40e: fix shifts of 32-bit value' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (10 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix mask bits register " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'app/testpmd: fix VLAN TCI mask set error for FDIR' " luca.boccassi
                   ` (20 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Beilei Xing; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From a898a787de86541b1cfc96a2fbde09c4c7d9ec65 Mon Sep 17 00:00:00 2001
From: Beilei Xing <beilei.xing@intel.com>
Date: Wed, 23 May 2018 15:46:46 +0800
Subject: [PATCH] net/i40e: fix shifts of 32-bit value

[ upstream commit bc98bf3a2d0301a17707bc04e95fc32746a397c4 ]

Cppcheck reports following error,
(error) Shifting 32-bit value by 36 bits is undefined behaviour

According to datasheet, there's PHY type and PHY type extension
in setting PHY config command, should exclude PHY type extension
when setting PHY type.

Fixes: 1bb8f661168d ("net/i40e: fix link down and negotiation")

Signed-off-by: Beilei Xing <beilei.xing@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_ethdev.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 7e93c3e1a..d9fff5c4d 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -1747,8 +1747,8 @@ i40e_phy_conf_link(struct i40e_hw *hw,
 
 
 
-	/* To enable link, phy_type mask needs to include each type */
-	for (cnt = I40E_PHY_TYPE_SGMII; cnt < I40E_PHY_TYPE_MAX; cnt++)
+	/* PHY type mask needs to include each type except PHY type extension */
+	for (cnt = I40E_PHY_TYPE_SGMII; cnt < I40E_PHY_TYPE_25GBASE_KR; cnt++)
 		phy_type_mask |= 1 << cnt;
 
 	/* use get_phy_abilities_resp value for the rest */
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'app/testpmd: fix VLAN TCI mask set error for FDIR' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (11 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: fix shifts of 32-bit value' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: workaround performance degradation' " luca.boccassi
                   ` (19 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Wei Zhao; +Cc: Wenzhuo Lu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 2fe9a0f7743e140076c91c3241d1ff89facbc8d9 Mon Sep 17 00:00:00 2001
From: Wei Zhao <wei.zhao1@intel.com>
Date: Tue, 5 Jun 2018 17:12:11 +0800
Subject: [PATCH] app/testpmd: fix VLAN TCI mask set error for FDIR

[ upstream commit 26f579aa274b46f42d77228dd6628c951cba05a1 ]

The vlan tci mask should be set to 0xEFFF, not 0x0,
the wrong mask will cause mask error for register set.

Fixes: d9d5e6f2f0ba ("app/testpmd: set default flow director mask")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
---
 app/test-pmd/testpmd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index 4512ba92d..64e14cee2 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -291,7 +291,7 @@ struct rte_fdir_conf fdir_conf = {
 	.pballoc = RTE_FDIR_PBALLOC_64K,
 	.status = RTE_FDIR_REPORT_STATUS,
 	.mask = {
-		.vlan_tci_mask = 0x0,
+		.vlan_tci_mask = 0xFFEF,
 		.ipv4_mask     = {
 			.src_ip = 0xFFFFFFFF,
 			.dst_ip = 0xFFFFFFFF,
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/i40e: workaround performance degradation' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (12 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'app/testpmd: fix VLAN TCI mask set error for FDIR' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: do not reset device info data' " luca.boccassi
                   ` (18 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Haiyue Wang; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 2d5a7c1f330815a74a86cf64257631e1b2b3be53 Mon Sep 17 00:00:00 2001
From: Haiyue Wang <haiyue.wang@intel.com>
Date: Wed, 13 Jun 2018 13:52:41 +0800
Subject: [PATCH] net/i40e: workaround performance degradation

[ upstream commit 3320d4a240daab15559d3e671bd44573a89cf017 ]

The GL_SWR_PM_UP_THR value is not impacted from the link speed, its
value is set according to the total number of ports for a better
pipe-monitor configuration.

All bellowing relevant device IDs are considered (NICs, LOMs, Mezz
and Backplane):

Device-ID  Value        Comments
0x1572     0x03030303   10G SFI
0x1581     0x03030303   10G Backplane
0x1586     0x03030303   10G BaseT
0x1589     0x03030303   10G BaseT (FortPond)
0x1580     0x06060606   40G Backplane
0x1583     0x06060606   2x40G QSFP
0x1584     0x06060606   1x40G QSFP
0x1587     0x06060606   20G Backplane (HP)
0x1588     0x06060606   20G KR2 (HP)
0x158A     0x06060606   25G Backplane
0x158B     0x06060606   25G SFP28

Fixes: c9223a2bf53c ("i40e: workaround for XL710 performance")
Fixes: 75d133dd3296 ("net/i40e: enable 25G device")

Signed-off-by: Haiyue Wang <haiyue.wang@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_ethdev.c | 71 ++++++++++++++++++++++++++++++----
 1 file changed, 64 insertions(+), 7 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index d9fff5c4d..2eeb472d0 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -8669,6 +8669,60 @@ i40e_pctype_to_flowtype(enum i40e_filter_pctype pctype)
 #define I40E_GL_SWR_PM_UP_THR_SF_VALUE   0x06060606
 #define I40E_GL_SWR_PM_UP_THR            0x269FBC
 
+/*
+ * GL_SWR_PM_UP_THR:
+ * The value is not impacted from the link speed, its value is set according
+ * to the total number of ports for a better pipe-monitor configuration.
+ */
+static bool
+i40e_get_swr_pm_cfg(struct i40e_hw *hw, uint32_t *value)
+{
+#define I40E_GL_SWR_PM_EF_DEVICE(dev) \
+		.device_id = (dev),   \
+		.val = I40E_GL_SWR_PM_UP_THR_EF_VALUE
+
+#define I40E_GL_SWR_PM_SF_DEVICE(dev) \
+		.device_id = (dev),   \
+		.val = I40E_GL_SWR_PM_UP_THR_SF_VALUE
+
+	static const struct {
+		uint16_t device_id;
+		uint32_t val;
+	} swr_pm_table[] = {
+		{ I40E_GL_SWR_PM_EF_DEVICE(I40E_DEV_ID_SFP_XL710) },
+		{ I40E_GL_SWR_PM_EF_DEVICE(I40E_DEV_ID_KX_C) },
+		{ I40E_GL_SWR_PM_EF_DEVICE(I40E_DEV_ID_10G_BASE_T) },
+		{ I40E_GL_SWR_PM_EF_DEVICE(I40E_DEV_ID_10G_BASE_T4) },
+
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_KX_B) },
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_QSFP_A) },
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_QSFP_B) },
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_20G_KR2) },
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_20G_KR2_A) },
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_25G_B) },
+		{ I40E_GL_SWR_PM_SF_DEVICE(I40E_DEV_ID_25G_SFP28) },
+	};
+	uint32_t i;
+
+	if (value == NULL) {
+		PMD_DRV_LOG(ERR, "value is NULL");
+		return false;
+	}
+
+	for (i = 0; i < RTE_DIM(swr_pm_table); i++) {
+		if (hw->device_id == swr_pm_table[i].device_id) {
+			*value = swr_pm_table[i].val;
+
+			PMD_DRV_LOG(DEBUG, "Device 0x%x with GL_SWR_PM_UP_THR "
+				    "value - 0x%08x",
+				    hw->device_id, *value);
+			return true;
+		}
+	}
+
+	return false;
+}
+
 static int
 i40e_dev_sync_phy_type(struct i40e_hw *hw)
 {
@@ -8724,13 +8778,16 @@ i40e_configure_registers(struct i40e_hw *hw)
 		}
 
 		if (reg_table[i].addr == I40E_GL_SWR_PM_UP_THR) {
-			if (I40E_PHY_TYPE_SUPPORT_40G(hw->phy.phy_types) || /* For XL710 */
-			    I40E_PHY_TYPE_SUPPORT_25G(hw->phy.phy_types)) /* For XXV710 */
-				reg_table[i].val =
-					I40E_GL_SWR_PM_UP_THR_SF_VALUE;
-			else /* For X710 */
-				reg_table[i].val =
-					I40E_GL_SWR_PM_UP_THR_EF_VALUE;
+			uint32_t cfg_val;
+
+			if (!i40e_get_swr_pm_cfg(hw, &cfg_val)) {
+				PMD_DRV_LOG(DEBUG, "Device 0x%x skips "
+					    "GL_SWR_PM_UP_THR value fixup",
+					    hw->device_id);
+				continue;
+			}
+
+			reg_table[i].val = cfg_val;
 		}
 
 		ret = i40e_aq_debug_read_register(hw, reg_table[i].addr,
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/i40e: do not reset device info data' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (13 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: workaround performance degradation' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/pcap: fix multiple queues' " luca.boccassi
                   ` (17 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Damjan Marion; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 4215329e926479b67db24eca05c4e719a3c6609b Mon Sep 17 00:00:00 2001
From: Damjan Marion <damarion@cisco.com>
Date: Wed, 6 Jun 2018 22:31:25 +0200
Subject: [PATCH] net/i40e: do not reset device info data

[ upstream commit 2a4ed72338d7030ce1bbb0cee8aa213cdae6b54c ]

At this point valid data is already set by rte_eth_get_device_info.
device field becomes zero and consumer is not able to retrieve pci data.

Fixes: 4861cde46116 ("i40e: new poll mode driver")

Signed-off-by: Damjan Marion <damarion@cisco.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_ethdev_vf.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/i40e/i40e_ethdev_vf.c b/drivers/net/i40e/i40e_ethdev_vf.c
index b19224d96..0ffd9f3aa 100644
--- a/drivers/net/i40e/i40e_ethdev_vf.c
+++ b/drivers/net/i40e/i40e_ethdev_vf.c
@@ -2313,7 +2313,6 @@ i40evf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
 {
 	struct i40e_vf *vf = I40EVF_DEV_PRIVATE_TO_VF(dev->data->dev_private);
 
-	memset(dev_info, 0, sizeof(*dev_info));
 	dev_info->max_rx_queues = vf->vsi_res->num_queue_pairs;
 	dev_info->max_tx_queues = vf->vsi_res->num_queue_pairs;
 	dev_info->min_rx_bufsize = I40E_BUF_SIZE_MIN;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/pcap: fix multiple queues' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (14 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: do not reset device info data' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/thunderx: fix build with gcc optimization on' " luca.boccassi
                   ` (16 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Ido Goshen; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 30756d9baf3aa68250881f29ec1eea2362c1aa3c Mon Sep 17 00:00:00 2001
From: Ido Goshen <ido@cgstowernetworks.com>
Date: Tue, 19 Jun 2018 17:37:25 +0300
Subject: [PATCH] net/pcap: fix multiple queues

[ upstream commit 8ffda7673fa71e6a666963fc0ea4969d65dd09da ]

Change open_rx/tx_pcap/iface functions to open only a single pcap/dumper
and not loop num_of_queue times
The num_of_queue loop is already achieved by the
caller rte_kvargs_process

Fixing:
1. Opens N requested pcaps/dumpers instead of N^2
2. Leak of pcap/dumper's which are being overwritten by
   the sequential calls to open_rx/tx_pcap/iface functions
3. Use the filename/iface args per queue and not just the last one
   that overwrites the previous names

Fixes: 4c173302c307 ("pcap: add new driver")

Signed-off-by: Ido Goshen <ido@cgstowernetworks.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/pcap/rte_eth_pcap.c | 86 ++++++++++++++-------------------
 1 file changed, 36 insertions(+), 50 deletions(-)

diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c
index 27590d39d..deca553ee 100644
--- a/drivers/net/pcap/rte_eth_pcap.c
+++ b/drivers/net/pcap/rte_eth_pcap.c
@@ -687,19 +687,19 @@ static const struct eth_dev_ops ops = {
 static int
 open_rx_pcap(const char *key, const char *value, void *extra_args)
 {
-	unsigned int i;
 	const char *pcap_filename = value;
 	struct pmd_devargs *rx = extra_args;
 	pcap_t *pcap = NULL;
 
-	for (i = 0; i < rx->num_of_queue; i++) {
-		if (open_single_rx_pcap(pcap_filename, &pcap) < 0)
-			return -1;
+	if (rx->num_of_queue >= RTE_PMD_PCAP_MAX_QUEUES)
+		return -1;
+	if (open_single_rx_pcap(pcap_filename, &pcap) < 0)
+		return -1;
 
-		rx->queue[i].pcap = pcap;
-		rx->queue[i].name = pcap_filename;
-		rx->queue[i].type = key;
-	}
+	rx->queue[rx->num_of_queue].pcap = pcap;
+	rx->queue[rx->num_of_queue].name = pcap_filename;
+	rx->queue[rx->num_of_queue].type = key;
+	rx->num_of_queue++;
 
 	return 0;
 }
@@ -711,19 +711,19 @@ open_rx_pcap(const char *key, const char *value, void *extra_args)
 static int
 open_tx_pcap(const char *key, const char *value, void *extra_args)
 {
-	unsigned int i;
 	const char *pcap_filename = value;
 	struct pmd_devargs *dumpers = extra_args;
 	pcap_dumper_t *dumper;
 
-	for (i = 0; i < dumpers->num_of_queue; i++) {
-		if (open_single_tx_pcap(pcap_filename, &dumper) < 0)
-			return -1;
+	if (dumpers->num_of_queue >= RTE_PMD_PCAP_MAX_QUEUES)
+		return -1;
+	if (open_single_tx_pcap(pcap_filename, &dumper) < 0)
+		return -1;
 
-		dumpers->queue[i].dumper = dumper;
-		dumpers->queue[i].name = pcap_filename;
-		dumpers->queue[i].type = key;
-	}
+	dumpers->queue[dumpers->num_of_queue].dumper = dumper;
+	dumpers->queue[dumpers->num_of_queue].name = pcap_filename;
+	dumpers->queue[dumpers->num_of_queue].type = key;
+	dumpers->num_of_queue++;
 
 	return 0;
 }
@@ -754,18 +754,18 @@ open_rx_tx_iface(const char *key, const char *value, void *extra_args)
 static inline int
 open_rx_iface(const char *key, const char *value, void *extra_args)
 {
-	unsigned int i;
 	const char *iface = value;
 	struct pmd_devargs *rx = extra_args;
 	pcap_t *pcap = NULL;
 
-	for (i = 0; i < rx->num_of_queue; i++) {
-		if (open_single_iface(iface, &pcap) < 0)
-			return -1;
-		rx->queue[i].pcap = pcap;
-		rx->queue[i].name = iface;
-		rx->queue[i].type = key;
-	}
+	if (rx->num_of_queue >= RTE_PMD_PCAP_MAX_QUEUES)
+		return -1;
+	if (open_single_iface(iface, &pcap) < 0)
+		return -1;
+	rx->queue[rx->num_of_queue].pcap = pcap;
+	rx->queue[rx->num_of_queue].name = iface;
+	rx->queue[rx->num_of_queue].type = key;
+	rx->num_of_queue++;
 
 	return 0;
 }
@@ -776,18 +776,18 @@ open_rx_iface(const char *key, const char *value, void *extra_args)
 static int
 open_tx_iface(const char *key, const char *value, void *extra_args)
 {
-	unsigned int i;
 	const char *iface = value;
 	struct pmd_devargs *tx = extra_args;
 	pcap_t *pcap;
 
-	for (i = 0; i < tx->num_of_queue; i++) {
-		if (open_single_iface(iface, &pcap) < 0)
-			return -1;
-		tx->queue[i].pcap = pcap;
-		tx->queue[i].name = iface;
-		tx->queue[i].type = key;
-	}
+	if (tx->num_of_queue >= RTE_PMD_PCAP_MAX_QUEUES)
+		return -1;
+	if (open_single_iface(iface, &pcap) < 0)
+		return -1;
+	tx->queue[tx->num_of_queue].pcap = pcap;
+	tx->queue[tx->num_of_queue].name = iface;
+	tx->queue[tx->num_of_queue].type = key;
+	tx->num_of_queue++;
 
 	return 0;
 }
@@ -983,15 +983,8 @@ pmd_pcap_probe(const char *name, const char *params)
 	 * We check whether we want to open a RX stream from a real NIC or a
 	 * pcap file
 	 */
-	pcaps.num_of_queue = rte_kvargs_count(kvlist, ETH_PCAP_RX_PCAP_ARG);
-	if (pcaps.num_of_queue)
-		is_rx_pcap = 1;
-	else
-		pcaps.num_of_queue = rte_kvargs_count(kvlist,
-				ETH_PCAP_RX_IFACE_ARG);
-
-	if (pcaps.num_of_queue > RTE_PMD_PCAP_MAX_QUEUES)
-		pcaps.num_of_queue = RTE_PMD_PCAP_MAX_QUEUES;
+	is_rx_pcap = rte_kvargs_count(kvlist, ETH_PCAP_RX_PCAP_ARG) ? 1 : 0;
+	pcaps.num_of_queue = 0;
 
 	if (is_rx_pcap)
 		ret = rte_kvargs_process(kvlist, ETH_PCAP_RX_PCAP_ARG,
@@ -1007,15 +1000,8 @@ pmd_pcap_probe(const char *name, const char *params)
 	 * We check whether we want to open a TX stream to a real NIC or a
 	 * pcap file
 	 */
-	dumpers.num_of_queue = rte_kvargs_count(kvlist, ETH_PCAP_TX_PCAP_ARG);
-	if (dumpers.num_of_queue)
-		is_tx_pcap = 1;
-	else
-		dumpers.num_of_queue = rte_kvargs_count(kvlist,
-				ETH_PCAP_TX_IFACE_ARG);
-
-	if (dumpers.num_of_queue > RTE_PMD_PCAP_MAX_QUEUES)
-		dumpers.num_of_queue = RTE_PMD_PCAP_MAX_QUEUES;
+	is_tx_pcap = rte_kvargs_count(kvlist, ETH_PCAP_TX_PCAP_ARG) ? 1 : 0;
+	dumpers.num_of_queue = 0;
 
 	if (is_tx_pcap)
 		ret = rte_kvargs_process(kvlist, ETH_PCAP_TX_PCAP_ARG,
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/thunderx: fix build with gcc optimization on' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (15 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/pcap: fix multiple queues' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: fix SIGFPE with 0 Rx queue' " luca.boccassi
                   ` (15 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Ferruh Yigit; +Cc: Richard Walsh, Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 751700cb71459d5b2a70a2b3d1cdd0dce429f287 Mon Sep 17 00:00:00 2001
From: Ferruh Yigit <ferruh.yigit@intel.com>
Date: Thu, 21 Jun 2018 19:14:50 +0100
Subject: [PATCH] net/thunderx: fix build with gcc optimization on
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit d90141961b9acead2a3cfacc7547ac1a256979eb ]

build error gcc version 6.3.1 20161221 (Red Hat 6.3.1-1),
with EXTRA_CFLAGS="-O3":

.../drivers/net/thunderx/nicvf_ethdev.c:907:9:
   error: ‘txq’ may be used uninitialized in this function
   [-Werror=maybe-uninitialized]
  if (txq->pool_free == nicvf_single_pool_free_xmited_buffers)
      ~~~^~~~~~~~~~~
.../drivers/net/thunderx/nicvf_ethdev.c:886:20:
   note: ‘txq’ was declared here
  struct nicvf_txq *txq;
                    ^~~

Same error on function 'nicvf_eth_dev_init' and 'nicvf_dev_start', it
seems 'nicvf_set_tx_function' inlined when optimization enabled.

Initialize the txq and add NULL check before using it to fix.

Fixes: 7413feee662d ("net/thunderx: add device start/stop and close")

Reported-by: Richard Walsh <richard.walsh@intel.com>
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
---
 drivers/net/thunderx/nicvf_ethdev.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/net/thunderx/nicvf_ethdev.c b/drivers/net/thunderx/nicvf_ethdev.c
index d0f0d52dd..82106a78b 100644
--- a/drivers/net/thunderx/nicvf_ethdev.c
+++ b/drivers/net/thunderx/nicvf_ethdev.c
@@ -879,7 +879,7 @@ nicvf_dev_tx_queue_release(void *sq)
 static void
 nicvf_set_tx_function(struct rte_eth_dev *dev)
 {
-	struct nicvf_txq *txq;
+	struct nicvf_txq *txq = NULL;
 	size_t i;
 	bool multiseg = false;
 
@@ -900,6 +900,9 @@ nicvf_set_tx_function(struct rte_eth_dev *dev)
 		dev->tx_pkt_burst = nicvf_xmit_pkts;
 	}
 
+	if (!txq)
+		return;
+
 	if (txq->pool_free == nicvf_single_pool_free_xmited_buffers)
 		PMD_DRV_LOG(DEBUG, "Using single-mempool tx free method");
 	else
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/ena: fix SIGFPE with 0 Rx queue' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (16 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/thunderx: fix build with gcc optimization on' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/qede: fix default extended VLAN offload config' " luca.boccassi
                   ` (14 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Daria Kolistratova; +Cc: Michal Krawczyk, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From e814b5fd1a54a0ff9213611815e4b690f08d4d06 Mon Sep 17 00:00:00 2001
From: Daria Kolistratova <daria.kolistratova@intel.com>
Date: Tue, 26 Jun 2018 18:38:56 +0100
Subject: [PATCH] net/ena: fix SIGFPE with 0 Rx queue

[ upstream commit 361913ad6f8c05fc541fe4bfdae3b0dc095ae3af ]

When the number of rx queues is 0 (what can be when application does
not receive) failed with SIGFPE.
It happens when the application is also requesting ETH_MQ_RX_RSS_FLAG
in the rte_dev->data->dev_conf.rxmode.mq_mode.
Fixed adding zero rx queues check.

Signed-off-by: Daria Kolistratova <daria.kolistratova@intel.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/net/ena/ena_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index 2bb8655a1..1511c6a0d 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -894,7 +894,7 @@ static int ena_start(struct rte_eth_dev *dev)
 		return rc;
 
 	if (adapter->rte_dev->data->dev_conf.rxmode.mq_mode &
-	    ETH_MQ_RX_RSS_FLAG) {
+	    ETH_MQ_RX_RSS_FLAG && adapter->rte_dev->data->nb_rx_queues > 0) {
 		rc = ena_rss_init_default(adapter);
 		if (rc)
 			return rc;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/qede: fix default extended VLAN offload config' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (17 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: fix SIGFPE with 0 Rx queue' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix HW Tx checksum offload check' " luca.boccassi
                   ` (13 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Rasesh Mody; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From d8d23688fbf20b2c04e8379757bc0975cfdc57dc Mon Sep 17 00:00:00 2001
From: Rasesh Mody <rasesh.mody@cavium.com>
Date: Wed, 27 Jun 2018 23:01:57 -0700
Subject: [PATCH] net/qede: fix default extended VLAN offload config

[ upstream commit c6dd1eb8a55c1f66da8398508ea8a749799eef18 ]

This patch disables extended VLAN offload by default as PMD does not
support it.

Fixes: d87246a43759 ("net/qede: enable and disable VLAN filtering")

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
---
 drivers/net/qede/qede_ethdev.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.c
index ce3a0936d..17931020f 100644
--- a/drivers/net/qede/qede_ethdev.c
+++ b/drivers/net/qede/qede_ethdev.c
@@ -797,8 +797,7 @@ static int qede_dev_configure(struct rte_eth_dev *eth_dev)
 
 	/* Enable VLAN offloads by default */
 	qede_vlan_offload_set(eth_dev, ETH_VLAN_STRIP_MASK  |
-				       ETH_VLAN_FILTER_MASK |
-				       ETH_VLAN_EXTEND_MASK);
+				       ETH_VLAN_FILTER_MASK);
 
 	qdev->state = QEDE_DEV_CONFIG;
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix HW Tx checksum offload check' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (18 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/qede: fix default extended VLAN offload config' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix Tx with multiple mbuf' " luca.boccassi
                   ` (12 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: Xiaoxin Peng, Jason He, Qingmin Liu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 64ca8ec98c5c6c748127cf1878cab2d56e92694b Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Thu, 28 Jun 2018 13:15:33 -0700
Subject: [PATCH] net/bnxt: fix HW Tx checksum offload check

[ upstream commit f10258e39ec2a08d79585ecaf494198ba49bc6eb ]

Add more checks for checksum calculation offload.
Also check for tunnel frames and select the proper
buffer descriptor size.

Fixes: 6eb3cc2294fd ("net/bnxt: add initial Tx code")

Signed-off-by: Xiaoxin Peng <xiaoxin.peng@broadcom.com>
Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Jason He <jason.he@broadcom.com>
Reviewed-by: Qingmin Liu <qingmin.liu@broadcom.com>
---
 drivers/net/bnxt/bnxt_txr.c | 51 ++++++++++++++++++++++++++++++++++---
 drivers/net/bnxt/bnxt_txr.h | 10 ++++++++
 2 files changed, 58 insertions(+), 3 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_txr.c b/drivers/net/bnxt/bnxt_txr.c
index 9cd44a93c..2854b9f55 100644
--- a/drivers/net/bnxt/bnxt_txr.c
+++ b/drivers/net/bnxt/bnxt_txr.c
@@ -161,7 +161,9 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 
 	if (tx_pkt->ol_flags & (PKT_TX_TCP_SEG | PKT_TX_TCP_CKSUM |
 				PKT_TX_UDP_CKSUM | PKT_TX_IP_CKSUM |
-				PKT_TX_VLAN_PKT | PKT_TX_OUTER_IP_CKSUM))
+				PKT_TX_VLAN_PKT | PKT_TX_OUTER_IP_CKSUM |
+				PKT_TX_TUNNEL_GRE | PKT_TX_TUNNEL_VXLAN |
+				PKT_TX_TUNNEL_GENEVE))
 		long_bd = true;
 
 	tx_buf = &txr->tx_buf_ring[txr->tx_prod];
@@ -221,16 +223,46 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 			/* Outer IP, Inner IP, Inner TCP/UDP CSO */
 			txbd1->lflags |= TX_BD_FLG_TIP_IP_TCP_UDP_CHKSUM;
 			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_OIP_IIP_TCP_CKSUM) ==
+			   PKT_TX_OIP_IIP_TCP_CKSUM) {
+			/* Outer IP, Inner IP, Inner TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_FLG_TIP_IP_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_OIP_IIP_UDP_CKSUM) ==
+			   PKT_TX_OIP_IIP_UDP_CKSUM) {
+			/* Outer IP, Inner IP, Inner TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_FLG_TIP_IP_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
 		} else if ((tx_pkt->ol_flags & PKT_TX_IIP_TCP_UDP_CKSUM) ==
 			   PKT_TX_IIP_TCP_UDP_CKSUM) {
 			/* (Inner) IP, (Inner) TCP/UDP CSO */
 			txbd1->lflags |= TX_BD_FLG_IP_TCP_UDP_CHKSUM;
 			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_IIP_UDP_CKSUM) ==
+			   PKT_TX_IIP_UDP_CKSUM) {
+			/* (Inner) IP, (Inner) TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_FLG_IP_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_IIP_TCP_CKSUM) ==
+			   PKT_TX_IIP_TCP_CKSUM) {
+			/* (Inner) IP, (Inner) TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_FLG_IP_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
 		} else if ((tx_pkt->ol_flags & PKT_TX_OIP_TCP_UDP_CKSUM) ==
 			   PKT_TX_OIP_TCP_UDP_CKSUM) {
 			/* Outer IP, (Inner) TCP/UDP CSO */
 			txbd1->lflags |= TX_BD_FLG_TIP_TCP_UDP_CHKSUM;
 			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_OIP_UDP_CKSUM) ==
+			   PKT_TX_OIP_UDP_CKSUM) {
+			/* Outer IP, (Inner) TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_FLG_TIP_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_OIP_TCP_CKSUM) ==
+			   PKT_TX_OIP_TCP_CKSUM) {
+			/* Outer IP, (Inner) TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_FLG_TIP_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
 		} else if ((tx_pkt->ol_flags & PKT_TX_OIP_IIP_CKSUM) ==
 			   PKT_TX_OIP_IIP_CKSUM) {
 			/* Outer IP, Inner IP CSO */
@@ -241,11 +273,23 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 			/* TCP/UDP CSO */
 			txbd1->lflags |= TX_BD_LONG_LFLAGS_TCP_UDP_CHKSUM;
 			txbd1->mss = 0;
-		} else if (tx_pkt->ol_flags & PKT_TX_IP_CKSUM) {
+		} else if ((tx_pkt->ol_flags & PKT_TX_TCP_CKSUM) ==
+			   PKT_TX_TCP_CKSUM) {
+			/* TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_LONG_LFLAGS_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_UDP_CKSUM) ==
+			   PKT_TX_UDP_CKSUM) {
+			/* TCP/UDP CSO */
+			txbd1->lflags |= TX_BD_LONG_LFLAGS_TCP_UDP_CHKSUM;
+			txbd1->mss = 0;
+		} else if ((tx_pkt->ol_flags & PKT_TX_IP_CKSUM) ==
+			   PKT_TX_IP_CKSUM) {
 			/* IP CSO */
 			txbd1->lflags |= TX_BD_LONG_LFLAGS_IP_CHKSUM;
 			txbd1->mss = 0;
-		} else if (tx_pkt->ol_flags & PKT_TX_OUTER_IP_CKSUM) {
+		} else if ((tx_pkt->ol_flags & PKT_TX_OUTER_IP_CKSUM) ==
+			   PKT_TX_OUTER_IP_CKSUM) {
 			/* IP CSO */
 			txbd1->lflags |= TX_BD_LONG_LFLAGS_T_IP_CHKSUM;
 			txbd1->mss = 0;
@@ -269,6 +313,7 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 	}
 
 	txbd->flags_type |= TX_BD_LONG_FLAGS_PACKET_END;
+	txbd1->lflags = rte_cpu_to_le_32(txbd1->lflags);
 
 	txr->tx_prod = RING_NEXT(txr->tx_ring_struct, txr->tx_prod);
 
diff --git a/drivers/net/bnxt/bnxt_txr.h b/drivers/net/bnxt/bnxt_txr.h
index cb961f1b9..d9013991b 100644
--- a/drivers/net/bnxt/bnxt_txr.h
+++ b/drivers/net/bnxt/bnxt_txr.h
@@ -71,10 +71,20 @@ uint16_t bnxt_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts,
 
 #define PKT_TX_OIP_IIP_TCP_UDP_CKSUM	(PKT_TX_TCP_CKSUM | PKT_TX_UDP_CKSUM | \
 					PKT_TX_IP_CKSUM | PKT_TX_OUTER_IP_CKSUM)
+#define PKT_TX_OIP_IIP_UDP_CKSUM	(PKT_TX_UDP_CKSUM | \
+					PKT_TX_IP_CKSUM | PKT_TX_OUTER_IP_CKSUM)
+#define PKT_TX_OIP_IIP_TCP_CKSUM	(PKT_TX_TCP_CKSUM | \
+					PKT_TX_IP_CKSUM | PKT_TX_OUTER_IP_CKSUM)
 #define PKT_TX_IIP_TCP_UDP_CKSUM	(PKT_TX_TCP_CKSUM | PKT_TX_UDP_CKSUM | \
 					PKT_TX_IP_CKSUM)
+#define PKT_TX_IIP_TCP_CKSUM		(PKT_TX_TCP_CKSUM | PKT_TX_IP_CKSUM)
+#define PKT_TX_IIP_UDP_CKSUM		(PKT_TX_UDP_CKSUM | PKT_TX_IP_CKSUM)
 #define PKT_TX_OIP_TCP_UDP_CKSUM	(PKT_TX_TCP_CKSUM | PKT_TX_UDP_CKSUM | \
 					PKT_TX_OUTER_IP_CKSUM)
+#define PKT_TX_OIP_UDP_CKSUM		(PKT_TX_UDP_CKSUM | \
+					PKT_TX_OUTER_IP_CKSUM)
+#define PKT_TX_OIP_TCP_CKSUM		(PKT_TX_TCP_CKSUM | \
+					PKT_TX_OUTER_IP_CKSUM)
 #define PKT_TX_OIP_IIP_CKSUM		(PKT_TX_IP_CKSUM |	\
 					 PKT_TX_OUTER_IP_CKSUM)
 #define PKT_TX_TCP_UDP_CKSUM		(PKT_TX_TCP_CKSUM | PKT_TX_UDP_CKSUM)
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix Tx with multiple mbuf' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (19 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix HW Tx checksum offload check' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix incorrect IO address handling in Tx' " luca.boccassi
                   ` (11 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Xiaoxin Peng
  Cc: Herry Chen, Jason He, Scott Branden, Ajit Khaparde, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 7ba8cc1fda6cb7bef64d53194355ea9476d165a6 Mon Sep 17 00:00:00 2001
From: Xiaoxin Peng <xiaoxin.peng@broadcom.com>
Date: Thu, 28 Jun 2018 13:15:40 -0700
Subject: [PATCH] net/bnxt: fix Tx with multiple mbuf

[ upstream commit b2a4a69f7b663f712437c7c31dc0916ffe4ad84b ]

When using multi-mbuf to xmit large packets, we need to use total
packet lengths (sum of all segments) to set txbd->flags_type.
Packets will not be sent when using tx_pkt->data_len(The first
segment of packets).

Fixes: 6eb3cc2294fd ("net/bnxt: add initial Tx code")

Signed-off-by: Xiaoxin Peng <xiaoxin.peng@broadcom.com>
Reviewed-by: Herry Chen <herry.chen@broadcom.com>
Reviewed-by: Jason He <jason.he@broadcom.com>
Reviewed-by: Scott Branden <scott.branden@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_txr.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_txr.c b/drivers/net/bnxt/bnxt_txr.c
index 2854b9f55..54618b9f5 100644
--- a/drivers/net/bnxt/bnxt_txr.c
+++ b/drivers/net/bnxt/bnxt_txr.c
@@ -179,10 +179,10 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 	txbd->opaque = txr->tx_prod;
 	txbd->flags_type = tx_buf->nr_bds << TX_BD_LONG_FLAGS_BD_CNT_SFT;
 	txbd->len = tx_pkt->data_len;
-	if (txbd->len >= 2014)
+	if (tx_pkt->pkt_len >= 2014)
 		txbd->flags_type |= TX_BD_LONG_FLAGS_LHINT_GTE2K;
 	else
-		txbd->flags_type |= lhint_arr[txbd->len >> 9];
+		txbd->flags_type |= lhint_arr[tx_pkt->pkt_len >> 9];
 	txbd->addr = rte_cpu_to_le_32(RTE_MBUF_DATA_DMA_ADDR(tx_buf->mbuf));
 
 	if (long_bd) {
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix incorrect IO address handling in Tx' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (20 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix Tx with multiple mbuf' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix Rx ring count limitation' " luca.boccassi
                   ` (10 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From cac5eb366fdab6c478db98bf16e97aa6e6f1ac40 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Thu, 28 Jun 2018 13:15:44 -0700
Subject: [PATCH] net/bnxt: fix incorrect IO address handling in Tx

[ upstream commit 90362583e21407272d85882b4ff01fd2ca3f0ac7 ]

rte_mbuf_data_iova returns a 64-bit address. But we are incorrectly
using only 32-bits of that. Use rte_cpu_to_le_64 instead of
rte_cpu_to_le_32

Fixes: 6eb3cc2294fd ("net/bnxt: add initial Tx code")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_txr.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_txr.c b/drivers/net/bnxt/bnxt_txr.c
index 54618b9f5..ff24e2323 100644
--- a/drivers/net/bnxt/bnxt_txr.c
+++ b/drivers/net/bnxt/bnxt_txr.c
@@ -183,7 +183,7 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 		txbd->flags_type |= TX_BD_LONG_FLAGS_LHINT_GTE2K;
 	else
 		txbd->flags_type |= lhint_arr[tx_pkt->pkt_len >> 9];
-	txbd->addr = rte_cpu_to_le_32(RTE_MBUF_DATA_DMA_ADDR(tx_buf->mbuf));
+	txbd->addr = rte_cpu_to_le_64(RTE_MBUF_DATA_DMA_ADDR(tx_buf->mbuf));
 
 	if (long_bd) {
 		txbd->flags_type |= TX_BD_LONG_TYPE_TX_BD_LONG;
@@ -305,7 +305,7 @@ static uint16_t bnxt_start_xmit(struct rte_mbuf *tx_pkt,
 		tx_buf = &txr->tx_buf_ring[txr->tx_prod];
 
 		txbd = &txr->tx_desc_ring[txr->tx_prod];
-		txbd->addr = rte_cpu_to_le_32(RTE_MBUF_DATA_DMA_ADDR(m_seg));
+		txbd->addr = rte_cpu_to_le_64(RTE_MBUF_DATA_DMA_ADDR(m_seg));
 		txbd->flags_type = TX_BD_SHORT_TYPE_TX_BD_SHORT;
 		txbd->len = m_seg->data_len;
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix Rx ring count limitation' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (21 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix incorrect IO address handling in Tx' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bonding: do not clear active slave count' " luca.boccassi
                   ` (9 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 0f38b0f096eaf089a955e59c2af98e93d6acdba8 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Thu, 28 Jun 2018 13:15:48 -0700
Subject: [PATCH] net/bnxt: fix Rx ring count limitation

[ upstream commit 0a256e4a548b849be5c13f5c18046f3910584245 ]

Fixed size of fw_grp_ids in VNIC is limiting the number of Rx rings
being created. With this patch we are allocating fw_grp_ids dynamically,
allowing us to get over this artificial limit.

Fixes: 9738793f28ec ("net/bnxt: add VNIC functions and structs")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_ethdev.c | 11 +++++++++++
 drivers/net/bnxt/bnxt_hwrm.c   |  4 +++-
 drivers/net/bnxt/bnxt_vnic.c   |  5 +----
 drivers/net/bnxt/bnxt_vnic.h   |  6 +-----
 4 files changed, 16 insertions(+), 10 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c
index 3a0b1ce44..0aef27ae7 100644
--- a/drivers/net/bnxt/bnxt_ethdev.c
+++ b/drivers/net/bnxt/bnxt_ethdev.c
@@ -222,6 +222,17 @@ static int bnxt_init_chip(struct bnxt *bp)
 	/* VNIC configuration */
 	for (i = 0; i < bp->nr_vnics; i++) {
 		struct bnxt_vnic_info *vnic = &bp->vnic_info[i];
+		uint32_t size = sizeof(*vnic->fw_grp_ids) * bp->max_ring_grps;
+
+		vnic->fw_grp_ids = rte_zmalloc("vnic_fw_grp_ids", size, 0);
+		if (!vnic->fw_grp_ids) {
+			RTE_LOG(ERR, PMD,
+				    "Failed to alloc %d bytes for group ids\n",
+				    size);
+			rc = -ENOMEM;
+			goto err_out;
+		}
+		memset(vnic->fw_grp_ids, -1, size);
 
 		rc = bnxt_hwrm_vnic_alloc(bp, vnic);
 		if (rc) {
diff --git a/drivers/net/bnxt/bnxt_hwrm.c b/drivers/net/bnxt/bnxt_hwrm.c
index d790b991c..5d85eeda3 100644
--- a/drivers/net/bnxt/bnxt_hwrm.c
+++ b/drivers/net/bnxt/bnxt_hwrm.c
@@ -837,7 +837,7 @@ int bnxt_hwrm_vnic_alloc(struct bnxt *bp, struct bnxt_vnic_info *vnic)
 	struct hwrm_vnic_alloc_output *resp = bp->hwrm_cmd_resp_addr;
 
 	/* map ring groups to this vnic */
-	for (i = vnic->start_grp_id, j = 0; i <= vnic->end_grp_id; i++, j++) {
+	for (i = vnic->start_grp_id, j = 0; i < vnic->end_grp_id; i++, j++) {
 		if (bp->grp_info[i].fw_grp_id == (uint16_t)HWRM_NA_SIGNATURE) {
 			RTE_LOG(ERR, PMD,
 				"Not enough ring groups avail:%x req:%x\n", j,
@@ -1271,6 +1271,8 @@ void bnxt_free_all_hwrm_resources(struct bnxt *bp)
 
 		bnxt_hwrm_vnic_ctx_free(bp, vnic);
 		bnxt_hwrm_vnic_free(bp, vnic);
+
+		rte_free(vnic->fw_grp_ids);
 	}
 	/* Ring resources */
 	bnxt_free_all_hwrm_rings(bp);
diff --git a/drivers/net/bnxt/bnxt_vnic.c b/drivers/net/bnxt/bnxt_vnic.c
index 33fdde2fc..58fa4beec 100644
--- a/drivers/net/bnxt/bnxt_vnic.c
+++ b/drivers/net/bnxt/bnxt_vnic.c
@@ -67,7 +67,7 @@ void bnxt_init_vnics(struct bnxt *bp)
 {
 	struct bnxt_vnic_info *vnic;
 	uint16_t max_vnics;
-	int i, j;
+	int i;
 
 	if (BNXT_PF(bp)) {
 		struct bnxt_pf_info *pf = &bp->pf;
@@ -85,9 +85,6 @@ void bnxt_init_vnics(struct bnxt *bp)
 		vnic->fw_rss_cos_lb_ctx = (uint16_t)HWRM_NA_SIGNATURE;
 		vnic->ctx_is_rss_cos_lb = HW_CONTEXT_NONE;
 
-		for (j = 0; j < MAX_QUEUES_PER_VNIC; j++)
-			vnic->fw_grp_ids[j] = (uint16_t)HWRM_NA_SIGNATURE;
-
 		prandom_bytes(vnic->rss_hash_key, HW_HASH_KEY_SIZE);
 		STAILQ_INIT(&vnic->filter);
 		STAILQ_INSERT_TAIL(&bp->free_vnic_list, vnic, next);
diff --git a/drivers/net/bnxt/bnxt_vnic.h b/drivers/net/bnxt/bnxt_vnic.h
index 9671ba42a..1f9e19389 100644
--- a/drivers/net/bnxt/bnxt_vnic.h
+++ b/drivers/net/bnxt/bnxt_vnic.h
@@ -44,13 +44,9 @@ struct bnxt_vnic_info {
 	uint16_t	fw_vnic_id; /* returned by Chimp during alloc */
 	uint16_t	fw_rss_cos_lb_ctx;
 	uint16_t	ctx_is_rss_cos_lb;
-#define MAX_NUM_TRAFFIC_CLASSES		8
-#define MAX_NUM_RSS_QUEUES_PER_VNIC	16
-#define MAX_QUEUES_PER_VNIC	(MAX_NUM_RSS_QUEUES_PER_VNIC + \
-				 MAX_NUM_TRAFFIC_CLASSES)
 	uint16_t	start_grp_id;
 	uint16_t	end_grp_id;
-	uint16_t	fw_grp_ids[MAX_QUEUES_PER_VNIC];
+	uint16_t	*fw_grp_ids;
 	uint16_t	hash_type;
 	phys_addr_t	rss_table_dma_addr;
 	uint16_t	*rss_table;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bonding: do not clear active slave count' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (22 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix Rx ring count limitation' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'test/crypto: fix device id when stopping port' " luca.boccassi
                   ` (8 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Chas Williams; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 61a342dbaac59371580d6bf5e14aed71639d570a Mon Sep 17 00:00:00 2001
From: Chas Williams <chas3@att.com>
Date: Tue, 3 Jul 2018 22:28:32 -0400
Subject: [PATCH] net/bonding: do not clear active slave count

[ upstream commit 69bce062132bd2b4a943fafbb710215a7999d198 ]

When the bond PMD is stopped, the active slave count is reset.
For 802.3ad mode this potentially leaks memory and clears state since
a second sequential activate_slave() will occur when the bond PMD is
restarted and the LSC callback is triggered while the active slave
count is 0. To fix this, don't clear the active slave count when
stopping. Only deactivate_slave() should be used to clear the slaves.

Fixes: 2efb58cbab6e ("bond: new link bonding library")

Signed-off-by: Chas Williams <chas3@att.com>
---
 drivers/net/bonding/rte_eth_bond_pmd.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index 6f8931ef9..5905c7070 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -1649,7 +1649,6 @@ bond_ethdev_stop(struct rte_eth_dev *eth_dev)
 			tlb_last_obytets[internals->active_slaves[i]] = 0;
 	}
 
-	internals->active_slave_count = 0;
 	internals->link_status_polling_enabled = 0;
 	for (i = 0; i < internals->slave_count; i++)
 		internals->slaves[i].last_link_status = 0;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test/crypto: fix device id when stopping port' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (23 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'net/bonding: do not clear active slave count' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'maintainers: update for Mellanox PMDs' " luca.boccassi
                   ` (7 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From e4008997025a32b3290208fea4b325bcebc6398b Mon Sep 17 00:00:00 2001
From: Hemant Agrawal <hemant.agrawal@nxp.com>
Date: Wed, 4 Jul 2018 15:19:38 +0530
Subject: [PATCH] test/crypto: fix device id when stopping port

[ upstream commit bb6f0b734f306c48bedac0df66cc9b8f62b595aa ]

dev_id is valid, while ts_params->valid_devs[devid] may
result a different value in case multiple devices are present
and any of the device is being used.

Fixes: 202d375c60bc ("app/test: add cryptodev unit and performance tests")

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 app/test/test_cryptodev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index 24c729639..a1f8717be 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -516,7 +516,7 @@ test_device_configure_invalid_dev_id(void)
 	dev_id = ts_params->valid_devs[ts_params->valid_dev_count - 1];
 
 	/* Stop the device in case it's started so it can be configured */
-	rte_cryptodev_stop(ts_params->valid_devs[dev_id]);
+	rte_cryptodev_stop(dev_id);
 
 	TEST_ASSERT_SUCCESS(rte_cryptodev_configure(dev_id, &ts_params->conf),
 			"Failed test for rte_cryptodev_configure: "
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'maintainers: update for Mellanox PMDs' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (24 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'test/crypto: fix device id when stopping port' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'examples/multi_process: build l2fwd_fork app' " luca.boccassi
                   ` (6 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Adrien Mazarguil
  Cc: Nelio Laranjeiro, Shahaf Shuler, Matan Azrad, Yongseok Koh,
	Jing Chen, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 7015bb0c4930b1553ddc063e73d8613b0d413ceb Mon Sep 17 00:00:00 2001
From: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Date: Thu, 5 Jul 2018 11:19:46 +0200
Subject: [PATCH] maintainers: update for Mellanox PMDs
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit c754c7d809347e264cc305b1e389cb322e1e1ab3 ]

Shahaf and Matan volunteered to replace Nélio and myself as maintainers for
mlx4 and mlx5 PMDs. Cheers!

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>
Acked-by: Shahaf Shuler <shahafs@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
Acked-by: Yongseok Koh <yskoh@mellanox.com>
---
 MAINTAINERS | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index a380b5d62..17bbf48b2 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -335,12 +335,14 @@ M: Jing Chen <jing.d.chen@intel.com>
 F: drivers/net/fm10k/
 
 Mellanox mlx4
-M: Adrien Mazarguil <adrien.mazarguil@6wind.com>
+M: Matan Azrad <matan@mellanox.com>
+M: Shahaf Shuler <shahafs@mellanox.com>
 F: drivers/net/mlx4/
 F: doc/guides/nics/mlx4.rst
 
 Mellanox mlx5
-M: Adrien Mazarguil <adrien.mazarguil@6wind.com>
+M: Shahaf Shuler <shahafs@mellanox.com>
+M: Yongseok Koh <yskoh@mellanox.com>
 F: drivers/net/mlx5/
 F: doc/guides/nics/mlx5.rst
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'examples/multi_process: build l2fwd_fork app' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (25 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'maintainers: update for Mellanox PMDs' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix multiwriter lock memory allocation' " luca.boccassi
                   ` (5 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Emma Kenny; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 31d2f878d40282d935a9590e4c6e6edc7e0d5c83 Mon Sep 17 00:00:00 2001
From: Emma Kenny <emma.kenny@intel.com>
Date: Tue, 3 Jul 2018 17:16:45 +0100
Subject: [PATCH] examples/multi_process: build l2fwd_fork app

[ upstream commit 26fd4b73125ca77690f7a97423e6b031ea98835d ]

l2fwd_fork is not complied by default, this will make it compile

Fixes: 95e8005a56e8 ("examples/l2fwd_fork: new app")

Signed-off-by: Emma Kenny <emma.kenny@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 examples/multi_process/Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/examples/multi_process/Makefile b/examples/multi_process/Makefile
index 6b315cc0e..39306f307 100644
--- a/examples/multi_process/Makefile
+++ b/examples/multi_process/Makefile
@@ -41,5 +41,6 @@ include $(RTE_SDK)/mk/rte.vars.mk
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += client_server_mp
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += simple_mp
 DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += symmetric_mp
+DIRS-$(CONFIG_RTE_EXEC_ENV_LINUXAPP) += l2fwd_fork
 
 include $(RTE_SDK)/mk/rte.extsubdir.mk
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'hash: fix multiwriter lock memory allocation' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (26 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'examples/multi_process: build l2fwd_fork app' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix a multi-writer race condition' " luca.boccassi
                   ` (4 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Yipeng Wang; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 4c56b4113f37cb7d0332dceb98108014de628ce5 Mon Sep 17 00:00:00 2001
From: Yipeng Wang <yipeng1.wang@intel.com>
Date: Tue, 10 Jul 2018 09:59:54 -0700
Subject: [PATCH] hash: fix multiwriter lock memory allocation

[ upstream commit 27c813679ea961b94d3184c09e50a055ad726da3 ]

When malloc for multiwriter_lock, the align should be
RTE_CACHE_LINE_SIZE rather than LCORE_CACHE_SIZE.

Also there should be check to verify the success of
rte_malloc.

Fixes: be856325cba3 ("hash: add scalable multi-writer insertion with Intel TSX")

Signed-off-by: Yipeng Wang <yipeng1.wang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 lib/librte_hash/rte_cuckoo_hash.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/lib/librte_hash/rte_cuckoo_hash.c b/lib/librte_hash/rte_cuckoo_hash.c
index fb462d69e..bfc6f9773 100644
--- a/lib/librte_hash/rte_cuckoo_hash.c
+++ b/lib/librte_hash/rte_cuckoo_hash.c
@@ -303,7 +303,10 @@ rte_hash_create(const struct rte_hash_parameters *params)
 			h->add_key = ADD_KEY_MULTIWRITER;
 			h->multiwriter_lock = rte_malloc(NULL,
 							sizeof(rte_spinlock_t),
-							LCORE_CACHE_SIZE);
+							RTE_CACHE_LINE_SIZE);
+			if (h->multiwriter_lock == NULL)
+				goto err_unlock;
+
 			rte_spinlock_init(h->multiwriter_lock);
 		}
 	} else
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'hash: fix a multi-writer race condition' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (27 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix multiwriter lock memory allocation' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix key slot size accuracy' " luca.boccassi
                   ` (3 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Yipeng Wang; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From e26dac448835a5a3f7c213cd797e96e0f7bda599 Mon Sep 17 00:00:00 2001
From: Yipeng Wang <yipeng1.wang@intel.com>
Date: Tue, 10 Jul 2018 09:59:55 -0700
Subject: [PATCH] hash: fix a multi-writer race condition

[ upstream commit eb067d431d9411a0054bc3ec084b0e9eadbb0a16 ]

Current multi-writer implementation uses Intel TSX to
protect the cuckoo path moving but not the cuckoo
path searching. After searching, we need to verify again if
the same empty slot still exists at the beginning of the TSX
region. Otherwise another writer could occupy the empty slot
before the TSX region. Current code does not verify.

Fixes: be856325cba3 ("hash: add scalable multi-writer insertion with Intel TSX")

Signed-off-by: Yipeng Wang <yipeng1.wang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 lib/librte_hash/rte_cuckoo_hash_x86.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/librte_hash/rte_cuckoo_hash_x86.h b/lib/librte_hash/rte_cuckoo_hash_x86.h
index 0c94244a6..a2f1663ec 100644
--- a/lib/librte_hash/rte_cuckoo_hash_x86.h
+++ b/lib/librte_hash/rte_cuckoo_hash_x86.h
@@ -95,6 +95,9 @@ rte_hash_cuckoo_move_insert_mw_tm(const struct rte_hash *h,
 	while (try < RTE_HASH_TSX_MAX_RETRY) {
 		status = rte_xbegin();
 		if (likely(status == RTE_XBEGIN_STARTED)) {
+			/* In case empty slot was gone before entering TSX */
+			if (curr_bkt->key_idx[curr_slot] != EMPTY_SLOT)
+				rte_xabort(RTE_XABORT_CUCKOO_PATH_INVALIDED);
 			while (likely(curr_node->prev != NULL)) {
 				prev_node = curr_node->prev;
 				prev_bkt = prev_node->bkt;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'hash: fix key slot size accuracy' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (28 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix a multi-writer race condition' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'eal: fix return codes on thread naming failure' " luca.boccassi
                   ` (2 subsequent siblings)
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Yipeng Wang; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 00431fffc36d49bc8f209751d90127f40611a647 Mon Sep 17 00:00:00 2001
From: Yipeng Wang <yipeng1.wang@intel.com>
Date: Tue, 10 Jul 2018 09:59:56 -0700
Subject: [PATCH] hash: fix key slot size accuracy

[ upstream commit 575a48c961f47f1078bd1ceacf8484fb1038f7f8 ]

This commit calculates the needed key slot size more
accurately. The previous local cache fix requires
the free slot ring to be larger than actually needed.
The calculation of the value is inaccurate.

Fixes: 5915699153d7 ("hash: fix scaling by reducing contention")

Signed-off-by: Yipeng Wang <yipeng1.wang@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 lib/librte_hash/rte_cuckoo_hash.c | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

diff --git a/lib/librte_hash/rte_cuckoo_hash.c b/lib/librte_hash/rte_cuckoo_hash.c
index bfc6f9773..049ff9884 100644
--- a/lib/librte_hash/rte_cuckoo_hash.c
+++ b/lib/librte_hash/rte_cuckoo_hash.c
@@ -155,13 +155,13 @@ rte_hash_create(const struct rte_hash_parameters *params)
 		 * except for the first cache
 		 */
 		num_key_slots = params->entries + (RTE_MAX_LCORE - 1) *
-					LCORE_CACHE_SIZE + 1;
+					(LCORE_CACHE_SIZE - 1) + 1;
 	else
 		num_key_slots = params->entries + 1;
 
 	snprintf(ring_name, sizeof(ring_name), "HT_%s", params->name);
 	/* Create ring (Dummy slot index is not enqueued) */
-	r = rte_ring_create(ring_name, rte_align32pow2(num_key_slots - 1),
+	r = rte_ring_create(ring_name, rte_align32pow2(num_key_slots),
 			params->socket_id, 0);
 	if (r == NULL) {
 		RTE_LOG(ERR, HASH, "memory allocation failed\n");
@@ -313,7 +313,7 @@ rte_hash_create(const struct rte_hash_parameters *params)
 		h->add_key = ADD_KEY_SINGLEWRITER;
 
 	/* Populate free slots ring. Entry zero is reserved for key misses. */
-	for (i = 1; i < params->entries + 1; i++)
+	for (i = 1; i < num_key_slots; i++)
 		rte_ring_sp_enqueue(r, (void *)((uintptr_t) i));
 
 	te->data = (void *) h;
@@ -395,7 +395,7 @@ void
 rte_hash_reset(struct rte_hash *h)
 {
 	void *ptr;
-	unsigned i;
+	uint32_t tot_ring_cnt, i;
 
 	if (h == NULL)
 		return;
@@ -408,7 +408,13 @@ rte_hash_reset(struct rte_hash *h)
 		rte_pause();
 
 	/* Repopulate the free slots ring. Entry zero is reserved for key misses */
-	for (i = 1; i < h->entries + 1; i++)
+	if (h->hw_trans_mem_support)
+		tot_ring_cnt = h->entries + (RTE_MAX_LCORE - 1) *
+					(LCORE_CACHE_SIZE - 1);
+	else
+		tot_ring_cnt = h->entries;
+
+	for (i = 1; i < tot_ring_cnt + 1; i++)
 		rte_ring_sp_enqueue(h->free_slots, (void *)((uintptr_t) i));
 
 	if (h->hw_trans_mem_support) {
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'eal: fix return codes on thread naming failure' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (29 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix key slot size accuracy' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'eal/linux: fix invalid syntax in interrupts' " luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'ethdev: check queue stats mapping input arguments' " luca.boccassi
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Dariusz Stojaczyk; +Cc: Anatoly Burakov, Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 77391432e13177760caa74d6b430f75fdb66cd01 Mon Sep 17 00:00:00 2001
From: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Date: Tue, 10 Jul 2018 12:44:46 +0200
Subject: [PATCH] eal: fix return codes on thread naming failure

[ upstream commit 82dcc8b4bcb8adcb7fc819839833e74a3d0ad497 ]

The doc says this function returns negative errno
on error, but it currently returns either -1 or
positive errno.

It was incorrectly assumed that pthread_setname_np()
returns negative error numbers. It always returns
positive ones, so this patch negates its return value
before returning.

Fixes: 3901ed99c2f8 ("eal: fix thread naming on FreeBSD")

Signed-off-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
Reviewed-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_eal/linuxapp/eal/eal_thread.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/librte_eal/linuxapp/eal/eal_thread.c b/lib/librte_eal/linuxapp/eal/eal_thread.c
index 9f88530ea..da7dd69aa 100644
--- a/lib/librte_eal/linuxapp/eal/eal_thread.c
+++ b/lib/librte_eal/linuxapp/eal/eal_thread.c
@@ -200,7 +200,7 @@ int rte_sys_gettid(void)
 
 int rte_thread_setname(pthread_t id, const char *name)
 {
-	int ret = -1;
+	int ret = ENOSYS;
 #if defined(__GLIBC__) && defined(__GLIBC_PREREQ)
 #if __GLIBC_PREREQ(2, 12)
 	ret = pthread_setname_np(id, name);
@@ -208,5 +208,5 @@ int rte_thread_setname(pthread_t id, const char *name)
 #endif
 	RTE_SET_USED(id);
 	RTE_SET_USED(name);
-	return ret;
+	return -ret;
 }
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'eal/linux: fix invalid syntax in interrupts' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (30 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'eal: fix return codes on thread naming failure' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-24 16:07 ` [dpdk-stable] patch 'ethdev: check queue stats mapping input arguments' " luca.boccassi
  32 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Anatoly Burakov; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 7be96545dcf05023ef27cfb0f76db856b03280bb Mon Sep 17 00:00:00 2001
From: Anatoly Burakov <anatoly.burakov@intel.com>
Date: Fri, 1 Jun 2018 10:08:10 +0100
Subject: [PATCH] eal/linux: fix invalid syntax in interrupts

[ upstream commit 462dd3722eb7dec0db5833fbccb044e06d2a8e50 ]

Parentheses were missing. It worked because macro is enclosed in
parentheses, so syntax was valid after macro expansion.

Bugzilla ID: 58
Fixes: 0a45657a6794 ("pci: rework interrupt handling")

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
---
 lib/librte_eal/linuxapp/eal/eal_interrupts.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/linuxapp/eal/eal_interrupts.c b/lib/librte_eal/linuxapp/eal/eal_interrupts.c
index 368863f9b..7f739140a 100644
--- a/lib/librte_eal/linuxapp/eal/eal_interrupts.c
+++ b/lib/librte_eal/linuxapp/eal/eal_interrupts.c
@@ -451,7 +451,7 @@ rte_intr_callback_register(struct rte_intr_handle *intr_handle,
 	TAILQ_FOREACH(src, &intr_sources, next) {
 		if (src->intr_handle.fd == intr_handle->fd) {
 			/* we had no interrupts for this */
-			if TAILQ_EMPTY(&src->callbacks)
+			if (TAILQ_EMPTY(&src->callbacks))
 				wake_thread = 1;
 
 			TAILQ_INSERT_TAIL(&(src->callbacks), callback, next);
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'ethdev: check queue stats mapping input arguments' has been queued to LTS release 16.11.8
  2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
                   ` (31 preceding siblings ...)
  2018-07-24 16:07 ` [dpdk-stable] patch 'eal/linux: fix invalid syntax in interrupts' " luca.boccassi
@ 2018-07-24 16:07 ` luca.boccassi
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
  32 siblings, 1 reply; 66+ messages in thread
From: luca.boccassi @ 2018-07-24 16:07 UTC (permalink / raw)
  To: Kiran Kumar; +Cc: Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 7e0f3ceda8a6a58107ee9ab8618ffc07edeb4d2e Mon Sep 17 00:00:00 2001
From: Kiran Kumar <kkokkilagadda@caviumnetworks.com>
Date: Wed, 11 Jul 2018 14:11:59 +0530
Subject: [PATCH] ethdev: check queue stats mapping input arguments

[ upstream commit de9c75a5485832104d2a0c246544ba3a511802b4 ]

With current implementation, we are not checking for queue_id range
and stat_idx range in stats mapping function. This patch will add
check for queue_id and stat_idx range.

Fixes: 5de201df892 ("ethdev: add stats per queue")

Signed-off-by: Kiran Kumar <kkokkilagadda@caviumnetworks.com>
Acked-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 lib/librte_ether/rte_ethdev.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/lib/librte_ether/rte_ethdev.c b/lib/librte_ether/rte_ethdev.c
index a698fc00a..9b28e95ae 100644
--- a/lib/librte_ether/rte_ethdev.c
+++ b/lib/librte_ether/rte_ethdev.c
@@ -1598,6 +1598,16 @@ set_queue_stats_mapping(uint8_t port_id, uint16_t queue_id, uint8_t stat_idx,
 	dev = &rte_eth_devices[port_id];
 
 	RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->queue_stats_mapping_set, -ENOTSUP);
+
+	if (is_rx && (queue_id >= dev->data->nb_rx_queues))
+		return -EINVAL;
+
+	if (!is_rx && (queue_id >= dev->data->nb_tx_queues))
+		return -EINVAL;
+
+	if (stat_idx >= RTE_ETHDEV_QUEUE_STAT_CNTRS)
+		return -EINVAL;
+
 	return (*dev->dev_ops->queue_stats_mapping_set)
 			(dev, queue_id, stat_idx, is_rx);
 }
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' has been queued to LTS release 16.11.8
  2018-07-24 16:07 ` [dpdk-stable] patch 'ethdev: check queue stats mapping input arguments' " luca.boccassi
@ 2018-07-27 10:17   ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/ipsec-secgw: fix bypass rule processing' " luca.boccassi
                       ` (11 more replies)
  0 siblings, 12 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Konstantin Ananyev; +Cc: Radu Nicolau, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From c7789b4609705ea3cc6e1774856641896fa1a34f Mon Sep 17 00:00:00 2001
From: Konstantin Ananyev <konstantin.ananyev@intel.com>
Date: Wed, 6 Jun 2018 13:04:01 +0100
Subject: [PATCH] examples/ipsec-secgw: fix IPv4 checksum at Tx

[ upstream commit b45be46dfd4548acd8f130841d02e97ab7bc7eb8 ]

For ESP transport and BYPASS mode the app might generate output
packets with invalid IPv4 header checksum.
At least such behavior was observed on few Intel NICs.
The reason is that the app didn't set ipv4 header checksum to zero
before passing it to the HW.

Fixes: 906257e965b7 ("examples/ipsec-secgw: support IPv6")

Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Radu Nicolau <radu.nicolau@intel.com>
---
 examples/ipsec-secgw/ipsec-secgw.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c
index 3c1ea16d5..315a68074 100644
--- a/examples/ipsec-secgw/ipsec-secgw.c
+++ b/examples/ipsec-secgw/ipsec-secgw.c
@@ -304,6 +304,7 @@ prepare_tx_pkt(struct rte_mbuf *pkt, uint8_t port)
 		pkt->l3_len = sizeof(struct ip);
 		pkt->l2_len = ETHER_HDR_LEN;
 
+		ip->ip_sum = 0;
 		ethhdr->ether_type = rte_cpu_to_be_16(ETHER_TYPE_IPv4);
 	} else {
 		pkt->ol_flags |= PKT_TX_IPV6;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'examples/ipsec-secgw: fix bypass rule processing' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'net/i40e: fix link speed' " luca.boccassi
                       ` (10 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Konstantin Ananyev; +Cc: Akhil Goyal, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 3ad29c23287477c8f2ad8e803954b70a6dca443c Mon Sep 17 00:00:00 2001
From: Konstantin Ananyev <konstantin.ananyev@intel.com>
Date: Tue, 5 Jun 2018 15:16:02 +0100
Subject: [PATCH] examples/ipsec-secgw: fix bypass rule processing

[ upstream commit c1fe6dbfcec2b17dd5fd115dcdec2ea573c4de0d ]

For outbound ports BYPASS rule is erroneously treated as PROTECT one
with SA idx zero.

Fixes: 2a5106af132b ("examples/ipsec-secgw: fix corner case for SPI value")

Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
---
 examples/ipsec-secgw/ipsec-secgw.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c
index 315a68074..05c76459b 100644
--- a/examples/ipsec-secgw/ipsec-secgw.c
+++ b/examples/ipsec-secgw/ipsec-secgw.c
@@ -478,11 +478,13 @@ outbound_sp(struct sp_ctx *sp, struct traffic_type *ip,
 		sa_idx = ip->res[i] & PROTECT_MASK;
 		if (ip->res[i] & DISCARD)
 			rte_pktmbuf_free(m);
+		else if (ip->res[i] & BYPASS)
+			ip->pkts[j++] = m;
 		else if (sa_idx < IPSEC_SA_MAX_ENTRIES) {
 			ipsec->res[ipsec->num] = sa_idx;
 			ipsec->pkts[ipsec->num++] = m;
-		} else /* BYPASS */
-			ip->pkts[j++] = m;
+		} else /* invalid SA idx */
+			rte_pktmbuf_free(m);
 	}
 	ip->num = j;
 }
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/i40e: fix link speed' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/ipsec-secgw: fix bypass rule processing' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'net/i40e: fix check of flow director programming status' " luca.boccassi
                       ` (9 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Xiaoyun Li; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From f3dbe50c474771cf688f2dac948e67bcbbd107d9 Mon Sep 17 00:00:00 2001
From: Xiaoyun Li <xiaoyun.li@intel.com>
Date: Tue, 10 Jul 2018 17:30:54 +0800
Subject: [PATCH] net/i40e: fix link speed

[ upstream commit 9214ee18eef97709eca481998cf7dca50520896c ]

When link needs to go up, I40E_AQ_PHY_AN_ENABLED is always be set in DPDK.
So all speeds are always set. This causes speed config never works.

This patch fixes this issue and only allows to set available speeds. If
link needs to go up and speed setting is not supported, it will print
warning and set default available speeds. And when link needs to go down,
link speed field should be set to non-zero to avoid link down issue when
binding back to kernel driver.

Fixes: ca7e599d4506 ("net/i40e: fix link management")
Fixes: 1bb8f661168d ("net/i40e: fix link down and negotiation")

Signed-off-by: Xiaoyun Li <xiaoyun.li@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_ethdev.c | 67 +++++++++++++++++++++-------------
 1 file changed, 41 insertions(+), 26 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 2eeb472d0..01f473c2b 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -1708,27 +1708,40 @@ i40e_phy_conf_link(struct i40e_hw *hw,
 	struct i40e_aq_get_phy_abilities_resp phy_ab;
 	struct i40e_aq_set_phy_config phy_conf;
 	enum i40e_aq_phy_type cnt;
+	uint8_t avail_speed;
 	uint32_t phy_type_mask = 0;
 
 	const uint8_t mask = I40E_AQ_PHY_FLAG_PAUSE_TX |
 			I40E_AQ_PHY_FLAG_PAUSE_RX |
 			I40E_AQ_PHY_FLAG_PAUSE_RX |
 			I40E_AQ_PHY_FLAG_LOW_POWER;
-	const uint8_t advt = I40E_LINK_SPEED_40GB |
-			I40E_LINK_SPEED_25GB |
-			I40E_LINK_SPEED_10GB |
-			I40E_LINK_SPEED_1GB |
-			I40E_LINK_SPEED_100MB;
 	int ret = -ENOTSUP;
 
+	/* To get phy capabilities of available speeds. */
+	status = i40e_aq_get_phy_capabilities(hw, false, true, &phy_ab,
+					      NULL);
+	if (status) {
+		PMD_DRV_LOG(ERR, "Failed to get PHY capabilities: %d\n",
+				status);
+		return ret;
+	}
+	avail_speed = phy_ab.link_speed;
 
+	/* To get the current phy config. */
 	status = i40e_aq_get_phy_capabilities(hw, false, false, &phy_ab,
 					      NULL);
-	if (status)
+	if (status) {
+		PMD_DRV_LOG(ERR, "Failed to get the current PHY config: %d\n",
+				status);
 		return ret;
+	}
 
-	/* If link already up, no need to set up again */
-	if (is_up && phy_ab.phy_type != 0)
+	/* If link needs to go up and it is in autoneg mode the speed is OK,
+	 * no need to set up again.
+	 */
+	if (is_up && phy_ab.phy_type != 0 &&
+		     abilities & I40E_AQ_PHY_AN_ENABLED &&
+		     phy_ab.link_speed != 0)
 		return I40E_SUCCESS;
 
 	memset(&phy_conf, 0, sizeof(phy_conf));
@@ -1737,15 +1750,17 @@ i40e_phy_conf_link(struct i40e_hw *hw,
 	abilities &= ~mask;
 	abilities |= phy_ab.abilities & mask;
 
-	/* update ablities and speed */
-	if (abilities & I40E_AQ_PHY_AN_ENABLED)
-		phy_conf.link_speed = advt;
-	else
-		phy_conf.link_speed = is_up ? force_speed : phy_ab.link_speed;
-
 	phy_conf.abilities = abilities;
 
-
+	/* If link needs to go up, but the force speed is not supported,
+	 * Warn users and config the default available speeds.
+	 */
+	if (is_up && !(force_speed & avail_speed)) {
+		PMD_DRV_LOG(WARNING, "Invalid speed setting, set to default!\n");
+		phy_conf.link_speed = avail_speed;
+	} else {
+		phy_conf.link_speed = is_up ? force_speed : avail_speed;
+	}
 
 	/* PHY type mask needs to include each type except PHY type extension */
 	for (cnt = I40E_PHY_TYPE_SGMII; cnt < I40E_PHY_TYPE_25GBASE_KR; cnt++)
@@ -1781,11 +1796,18 @@ i40e_apply_link_speed(struct rte_eth_dev *dev)
 	struct i40e_hw *hw = I40E_DEV_PRIVATE_TO_HW(dev->data->dev_private);
 	struct rte_eth_conf *conf = &dev->data->dev_conf;
 
+	if (conf->link_speeds == ETH_LINK_SPEED_AUTONEG) {
+		conf->link_speeds = ETH_LINK_SPEED_40G |
+				    ETH_LINK_SPEED_25G |
+				    ETH_LINK_SPEED_20G |
+				    ETH_LINK_SPEED_10G |
+				    ETH_LINK_SPEED_1G |
+				    ETH_LINK_SPEED_100M;
+	}
 	speed = i40e_parse_link_speeds(conf->link_speeds);
-	abilities |= I40E_AQ_PHY_ENABLE_ATOMIC_LINK;
-	if (!(conf->link_speeds & ETH_LINK_SPEED_FIXED))
-		abilities |= I40E_AQ_PHY_AN_ENABLED;
-	abilities |= I40E_AQ_PHY_LINK_ENABLED;
+	abilities |= I40E_AQ_PHY_ENABLE_ATOMIC_LINK |
+		     I40E_AQ_PHY_AN_ENABLED |
+		     I40E_AQ_PHY_LINK_ENABLED;
 
 	return i40e_phy_conf_link(hw, abilities, speed, true);
 }
@@ -1876,13 +1898,6 @@ i40e_dev_start(struct rte_eth_dev *dev)
 	}
 
 	/* Apply link configure */
-	if (dev->data->dev_conf.link_speeds & ~(ETH_LINK_SPEED_100M |
-				ETH_LINK_SPEED_1G | ETH_LINK_SPEED_10G |
-				ETH_LINK_SPEED_20G | ETH_LINK_SPEED_25G |
-				ETH_LINK_SPEED_40G)) {
-		PMD_DRV_LOG(ERR, "Invalid link setting");
-		goto err_up;
-	}
 	ret = i40e_apply_link_speed(dev);
 	if (I40E_SUCCESS != ret) {
 		PMD_DRV_LOG(ERR, "Fail to apply link setting");
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/i40e: fix check of flow director programming status' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/ipsec-secgw: fix bypass rule processing' " luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'net/i40e: fix link speed' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'ethdev: fix queue statistics mapping documentation' " luca.boccassi
                       ` (8 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Wei Zhao; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From dd07790ba3868d42faf03efd5c51856c4fc99b3b Mon Sep 17 00:00:00 2001
From: Wei Zhao <wei.zhao1@intel.com>
Date: Fri, 13 Jul 2018 11:16:33 +0800
Subject: [PATCH] net/i40e: fix check of flow director programming status

[ upstream commit 7546dc4a1331340ecb665af9af0a005bb8b657c8 ]

In i40e FDIR PMD code for checking programming status
function i40e_check_fdir_programming_status(), the initial value
of return value ret should be set to -1 not 0, because if DD bit of
I40E_RX_DESC_STATUS_DD is not write back, this function will return
0 to upper function, this give an error info to upper function, the
fact for this is it is time out for DD write back and it should return
-1.

Fixes: 05999aab4ca6 ("i40e: add or delete flow director")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_fdir.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/i40e/i40e_fdir.c b/drivers/net/i40e/i40e_fdir.c
index e25b8e0c4..25578257d 100644
--- a/drivers/net/i40e/i40e_fdir.c
+++ b/drivers/net/i40e/i40e_fdir.c
@@ -1020,6 +1020,8 @@ i40e_check_fdir_programming_status(struct i40e_rx_queue *rxq)
 			I40E_PCI_REG_WRITE(rxq->qrx_tail, rxq->nb_rx_desc - 1);
 		else
 			I40E_PCI_REG_WRITE(rxq->qrx_tail, rxq->rx_tail - 1);
+	} else {
+		ret = -1;
 	}
 
 	return ret;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'ethdev: fix queue statistics mapping documentation' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (2 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'net/i40e: fix check of flow director programming status' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'net/thunderx: avoid sq door bell write on zero packet' " luca.boccassi
                       ` (7 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Jerin Jacob; +Cc: Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From af53cc748280ed3d36b73c910def3bd45c7dd414 Mon Sep 17 00:00:00 2001
From: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Date: Fri, 29 Jun 2018 15:14:43 +0530
Subject: [PATCH] ethdev: fix queue statistics mapping documentation

[ upstream commit 97f5f8cbadbeb47cc283251564e56a6c20ceec00 ]

The RTE_MAX_ETHPORT_QUEUE_STATS_MAPS does not exists, change
to the correct definition(RTE_ETHDEV_QUEUE_STAT_CNTRS)

Fixes: 5de201df8927 ("ethdev: add stats per queue")

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Reviewed-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 lib/librte_ether/rte_ethdev.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index da33b9d50..1b6d2187b 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -2325,7 +2325,7 @@ void rte_eth_xstats_reset(uint8_t port_id);
  * @param stat_idx
  *   The per-queue packet statistics functionality number that the transmit
  *   queue is to be assigned.
- *   The value must be in the range [0, RTE_MAX_ETHPORT_QUEUE_STATS_MAPS - 1].
+ *   The value must be in the range [0, RTE_ETHDEV_QUEUE_STAT_CNTRS - 1].
  * @return
  *   Zero if successful. Non-zero otherwise.
  */
@@ -2345,7 +2345,7 @@ int rte_eth_dev_set_tx_queue_stats_mapping(uint8_t port_id,
  * @param stat_idx
  *   The per-queue packet statistics functionality number that the receive
  *   queue is to be assigned.
- *   The value must be in the range [0, RTE_MAX_ETHPORT_QUEUE_STATS_MAPS - 1].
+ *   The value must be in the range [0, RTE_ETHDEV_QUEUE_STAT_CNTRS - 1].
  * @return
  *   Zero if successful. Non-zero otherwise.
  */
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/thunderx: avoid sq door bell write on zero packet' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (3 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'ethdev: fix queue statistics mapping documentation' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/exception_path: fix out-of-bounds read' " luca.boccassi
                       ` (6 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Kiran Kumar; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 85310ef9d404c03b932314fe91f3897401d89f24 Mon Sep 17 00:00:00 2001
From: Kiran Kumar <kkokkilagadda@caviumnetworks.com>
Date: Wed, 11 Jul 2018 13:54:36 +0530
Subject: [PATCH] net/thunderx: avoid sq door bell write on zero packet

[ upstream commit 47636efe878dd8885bb47b142765c9ccae6babe3 ]

Avoid sq door bell write on zero packet case to reduce additional
traffic on register bus.

Fixes: 1c421f18e0 ("net/thunderx: add single and multi-segment Tx")

Signed-off-by: Kiran Kumar <kkokkilagadda@caviumnetworks.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
---
 drivers/net/thunderx/nicvf_rxtx.c | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/drivers/net/thunderx/nicvf_rxtx.c b/drivers/net/thunderx/nicvf_rxtx.c
index 275adb31c..4b9b2932c 100644
--- a/drivers/net/thunderx/nicvf_rxtx.c
+++ b/drivers/net/thunderx/nicvf_rxtx.c
@@ -190,12 +190,14 @@ nicvf_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts)
 		free_desc -= TX_DESC_PER_PKT;
 	}
 
-	sq->tail = tail;
-	sq->xmit_bufs += i;
-	rte_wmb();
+	if (likely(i)) {
+		sq->tail = tail;
+		sq->xmit_bufs += i;
+		rte_wmb();
 
-	/* Inform HW to xmit the packets */
-	nicvf_addr_write(sq->sq_door, i * TX_DESC_PER_PKT);
+		/* Inform HW to xmit the packets */
+		nicvf_addr_write(sq->sq_door, i * TX_DESC_PER_PKT);
+	}
 	return i;
 }
 
@@ -246,12 +248,14 @@ nicvf_xmit_pkts_multiseg(void *tx_queue, struct rte_mbuf **tx_pkts,
 		}
 	}
 
-	sq->tail = tail;
-	sq->xmit_bufs += used_bufs;
-	rte_wmb();
+	if (likely(used_desc)) {
+		sq->tail = tail;
+		sq->xmit_bufs += used_bufs;
+		rte_wmb();
 
-	/* Inform HW to xmit the packets */
-	nicvf_addr_write(sq->sq_door, used_desc);
+		/* Inform HW to xmit the packets */
+		nicvf_addr_write(sq->sq_door, used_desc);
+	}
 	return i;
 }
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'examples/exception_path: fix out-of-bounds read' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (4 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'net/thunderx: avoid sq door bell write on zero packet' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/l3fwd: remove useless include' " luca.boccassi
                       ` (5 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 80b172eae686ac21e880b13d36edad8c7cf3db96 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Mon, 16 Jul 2018 17:03:47 +0100
Subject: [PATCH] examples/exception_path: fix out-of-bounds read

[ upstream commit 4341adf272144689540a8e0f615f12eef7e21109 ]

When printing out stats from the exception_path app, all possible
lcore_ids are iterated. However, the app only supports up to 64 cores.
To prevent possible errors, and to remove coverity warnings,
explicitly check for out-of-range lcore ids before printing.

Coverity issue: 268335
Fixes: af75078fece3 ("first public release")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
 examples/exception_path/main.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/examples/exception_path/main.c b/examples/exception_path/main.c
index e70549bee..9ab5054e3 100644
--- a/examples/exception_path/main.c
+++ b/examples/exception_path/main.c
@@ -165,6 +165,9 @@ print_stats(void)
 	       " Lcore    Port            RX            TX    Dropped on TX\n"
 	       "-------  ------  ------------  ------------  ---------------\n");
 	RTE_LCORE_FOREACH(i) {
+		/* limit ourselves to application supported cores only */
+		if (i >= APP_MAX_LCORE)
+			break;
 		printf("%6u %7u %13"PRIu64" %13"PRIu64" %16"PRIu64"\n",
 		       i, (unsigned)port_ids[i],
 		       lcore_stats[i].rx, lcore_stats[i].tx,
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'examples/l3fwd: remove useless include' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (5 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/exception_path: fix out-of-bounds read' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'test: fix EAL flags autotest on FreeBSD' " luca.boccassi
                       ` (4 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Rami Rosen; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 7fc25a02f7aac105015e0d31a6a9c3241b0f766f Mon Sep 17 00:00:00 2001
From: Rami Rosen <rami.rosen@intel.com>
Date: Mon, 2 Jul 2018 20:55:23 +0300
Subject: [PATCH] examples/l3fwd: remove useless include

[ upstream commit 8dedd737452fe2c8d74cce786aa6cc0ea91ed5c0 ]

This patch removes unneeded include of rte_mempool.h in
two modules in examples/l3fwd.

Fixes: 268888b5b020 ("examples/l3fwd: modularize")

Signed-off-by: Rami Rosen <rami.rosen@intel.com>
---
 examples/l3fwd/l3fwd_em.c  | 1 -
 examples/l3fwd/l3fwd_lpm.c | 1 -
 2 files changed, 2 deletions(-)

diff --git a/examples/l3fwd/l3fwd_em.c b/examples/l3fwd/l3fwd_em.c
index 46b327e16..6410e3cda 100644
--- a/examples/l3fwd/l3fwd_em.c
+++ b/examples/l3fwd/l3fwd_em.c
@@ -47,7 +47,6 @@
 #include <rte_debug.h>
 #include <rte_ether.h>
 #include <rte_ethdev.h>
-#include <rte_mempool.h>
 #include <rte_cycles.h>
 #include <rte_mbuf.h>
 #include <rte_ip.h>
diff --git a/examples/l3fwd/l3fwd_lpm.c b/examples/l3fwd/l3fwd_lpm.c
index f6212697a..ef65f9c3a 100644
--- a/examples/l3fwd/l3fwd_lpm.c
+++ b/examples/l3fwd/l3fwd_lpm.c
@@ -46,7 +46,6 @@
 #include <rte_debug.h>
 #include <rte_ether.h>
 #include <rte_ethdev.h>
-#include <rte_mempool.h>
 #include <rte_cycles.h>
 #include <rte_mbuf.h>
 #include <rte_ip.h>
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test: fix EAL flags autotest on FreeBSD' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (6 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'examples/l3fwd: remove useless include' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'test/hash: fix multiwriter with non consecutive cores' " luca.boccassi
                       ` (3 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Anatoly Burakov; +Cc: Changqing Wu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 0dba56e259801e01eec77dc2a4b073c07d6a961e Mon Sep 17 00:00:00 2001
From: Anatoly Burakov <anatoly.burakov@intel.com>
Date: Mon, 16 Jul 2018 17:34:04 +0100
Subject: [PATCH] test: fix EAL flags autotest on FreeBSD

[ upstream commit b5d878e6db56c76ffe5e8c69b6c19faac4e97d80 ]

FreeBSD does not support running multiple primary processes
concurrently, because all DPDK instances will allocate memory
from the same place (memory provided by contigmem driver).
While it is technically possible to launch a DPDK process
using no-shconf switch, it will actually corrupt main process'
for the above reason.

Fix EAL flags autotest to not run primary processes unless
both no-shconf and no-huge are specified.

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Tested-by: Changqing Wu <changqingx.wu@intel.com>
---
 app/test/test_eal_flags.c | 33 +++++++++++++++++----------------
 1 file changed, 17 insertions(+), 16 deletions(-)

diff --git a/app/test/test_eal_flags.c b/app/test/test_eal_flags.c
index 15248ea28..b66132285 100644
--- a/app/test/test_eal_flags.c
+++ b/app/test/test_eal_flags.c
@@ -409,17 +409,17 @@ test_invalid_vdev_flag(void)
 #endif
 
 	/* Test with invalid vdev option */
-	const char *vdevinval[] = {prgname, prefix, "-n", "1",
+	const char *vdevinval[] = {prgname, prefix, no_huge, "-n", "1",
 				"-c", "1", vdev, "eth_dummy"};
 
 	/* Test with valid vdev option */
-	const char *vdevval1[] = {prgname, prefix, "-n", "1",
+	const char *vdevval1[] = {prgname, prefix, no_huge, "-n", "1",
 	"-c", "1", vdev, "net_ring0"};
 
-	const char *vdevval2[] = {prgname, prefix, "-n", "1",
+	const char *vdevval2[] = {prgname, prefix, no_huge, "-n", "1",
 	"-c", "1", vdev, "net_ring0,args=test"};
 
-	const char *vdevval3[] = {prgname, prefix, "-n", "1",
+	const char *vdevval3[] = {prgname, prefix, no_huge, "-n", "1",
 	"-c", "1", vdev, "net_ring0,nodeaction=r1:0:CREATE"};
 
 	if (launch_proc(vdevinval) == 0) {
@@ -948,13 +948,10 @@ test_misc_flags(void)
 	const char *argv4[] = {prgname, prefix, mp_flag, "-c", "1", "--syslog"};
 	/* With invalid --syslog */
 	const char *argv5[] = {prgname, prefix, mp_flag, "-c", "1", "--syslog", "error"};
-	/* With no-sh-conf */
+	/* With no-sh-conf, also use no-huge to ensure this test runs on BSD */
 	const char *argv6[] = {prgname, "-c", "1", "-n", "2", "-m", DEFAULT_MEM_SIZE,
-			no_shconf, nosh_prefix };
+			no_shconf, nosh_prefix, no_huge};
 
-#ifdef RTE_EXEC_ENV_BSDAPP
-	return 0;
-#endif
 	/* With --huge-dir */
 	const char *argv7[] = {prgname, "-c", "1", "-n", "2", "-m", DEFAULT_MEM_SIZE,
 			"--file-prefix=hugedir", "--huge-dir", hugepath};
@@ -988,6 +985,7 @@ test_misc_flags(void)
 	const char *argv15[] = {prgname, "--file-prefix=intr",
 			"-c", "1", "-n", "2", "--vfio-intr=invalid"};
 
+	/* run all tests also applicable to FreeBSD first */
 
 	if (launch_proc(argv0) == 0) {
 		printf("Error - process ran ok with invalid flag\n");
@@ -1001,6 +999,16 @@ test_misc_flags(void)
 		printf("Error - process did not run ok with -v flag\n");
 		return -1;
 	}
+	if (launch_proc(argv6) != 0) {
+		printf("Error - process did not run ok with --no-shconf flag\n");
+		return -1;
+	}
+
+#ifdef RTE_EXEC_ENV_BSDAPP
+	/* no more tests to be done on FreeBSD */
+	return 0;
+#endif
+
 	if (launch_proc(argv3) != 0) {
 		printf("Error - process did not run ok with --syslog flag\n");
 		return -1;
@@ -1013,13 +1021,6 @@ test_misc_flags(void)
 		printf("Error - process run ok with invalid --syslog flag\n");
 		return -1;
 	}
-	if (launch_proc(argv6) != 0) {
-		printf("Error - process did not run ok with --no-shconf flag\n");
-		return -1;
-	}
-#ifdef RTE_EXEC_ENV_BSDAPP
-	return 0;
-#endif
 	if (launch_proc(argv7) != 0) {
 		printf("Error - process did not run ok with --huge-dir flag\n");
 		return -1;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test/hash: fix multiwriter with non consecutive cores' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (7 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'test: fix EAL flags autotest on FreeBSD' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'test/hash: fix potential memory leak' " luca.boccassi
                       ` (2 subsequent siblings)
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From dc829c2fe2bcef723c3a3c5301aaf93f192042a1 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Tue, 17 Jul 2018 14:31:50 +0100
Subject: [PATCH] test/hash: fix multiwriter with non consecutive cores

[ upstream commit 0c992822901464d440534d337838fd08acf233d4 ]

When non consecutive cores are passed into the test application,
the distribution of the keys that each thread needs to insert
is not correct, since it assumes that there are no cores skipped
between the master core and the worker core.

Fixes: be856325cba3 ("hash: add scalable multi-writer insertion with Intel TSX")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 app/test/test_hash_multiwriter.c | 41 ++++++++++++++++++++++++++++----
 1 file changed, 36 insertions(+), 5 deletions(-)

diff --git a/app/test/test_hash_multiwriter.c b/app/test/test_hash_multiwriter.c
index 4dcbd9d56..951c3e743 100644
--- a/app/test/test_hash_multiwriter.c
+++ b/app/test/test_hash_multiwriter.c
@@ -76,18 +76,29 @@ static rte_atomic64_t ginsertions;
 static int use_htm;
 
 static int
-test_hash_multiwriter_worker(__attribute__((unused)) void *arg)
+test_hash_multiwriter_worker(void *arg)
 {
 	uint64_t i, offset;
+	uint16_t pos_core;
 	uint32_t lcore_id = rte_lcore_id();
 	uint64_t begin, cycles;
+	uint16_t *enabled_core_ids = (uint16_t *)arg;
 
-	offset = (lcore_id - rte_get_master_lcore())
-		* tbl_multiwriter_test_params.nb_tsx_insertion;
+	for (pos_core = 0; pos_core < rte_lcore_count(); pos_core++) {
+		if (enabled_core_ids[pos_core] == lcore_id)
+			break;
+	}
+
+	/*
+	 * Calculate offset for entries based on the position of the
+	 * logical core, from the master core (not counting not enabled cores)
+	 */
+	offset = pos_core * tbl_multiwriter_test_params.nb_tsx_insertion;
 
 	printf("Core #%d inserting %d: %'"PRId64" - %'"PRId64"\n",
 	       lcore_id, tbl_multiwriter_test_params.nb_tsx_insertion,
-	       offset, offset + tbl_multiwriter_test_params.nb_tsx_insertion);
+	       offset,
+	       offset + tbl_multiwriter_test_params.nb_tsx_insertion - 1);
 
 	begin = rte_rdtsc_precise();
 
@@ -116,6 +127,8 @@ test_hash_multiwriter(void)
 {
 	unsigned int i, rounded_nb_total_tsx_insertion;
 	static unsigned calledCount = 1;
+	uint16_t enabled_core_ids[RTE_MAX_LCORE];
+	uint16_t core_id;
 
 	uint32_t *keys;
 	uint32_t *found;
@@ -186,9 +199,27 @@ test_hash_multiwriter(void)
 	rte_atomic64_init(&ginsertions);
 	rte_atomic64_clear(&ginsertions);
 
+	/* Get list of enabled cores */
+	i = 0;
+	for (core_id = 0; core_id < RTE_MAX_LCORE; core_id++) {
+		if (i == rte_lcore_count())
+			break;
+
+		if (rte_lcore_is_enabled(core_id)) {
+			enabled_core_ids[i] = core_id;
+			i++;
+		}
+	}
+
+	if (i != rte_lcore_count()) {
+		printf("Number of enabled cores in list is different from "
+				"number given by rte_lcore_count()\n");
+		goto err3;
+	}
+
 	/* Fire all threads. */
 	rte_eal_mp_remote_launch(test_hash_multiwriter_worker,
-				 NULL, CALL_MASTER);
+				 enabled_core_ids, CALL_MASTER);
 	rte_eal_mp_wait_lcore();
 
 	while (rte_hash_iterate(handle, &next_key, &next_data, &iter) >= 0) {
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test/hash: fix potential memory leak' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (8 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'test/hash: fix multiwriter with non consecutive cores' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-07-27 10:17     ` [dpdk-stable] patch 'doc: fix bonding command in testpmd' " luca.boccassi
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From 825668ecf07f719abe8e8c389a175e38d37b4ad1 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Tue, 17 Jul 2018 14:31:51 +0100
Subject: [PATCH] test/hash: fix potential memory leak

[ upstream commit a4492ab49ec3b829745c9060a1719354e0a572b7 ]

In the multiwriter test, if "found" array allocation failed,
the memory of "keys" array, which was successfully allocated
could not be freed, since by this time, tbl_multiwriter_test_params.keys
was not set to this array, which is the pointer freed when finishing
the test or when a failure happens.

To solve this, tbl_multiwriter_test_params.keys is set to the "keys"
address, just after allocating and filling the array.

Fixes: be856325cba3 ("hash: add scalable multi-writer insertion with Intel TSX")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 app/test/test_hash_multiwriter.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/app/test/test_hash_multiwriter.c b/app/test/test_hash_multiwriter.c
index 951c3e743..0e9ac7162 100644
--- a/app/test/test_hash_multiwriter.c
+++ b/app/test/test_hash_multiwriter.c
@@ -181,16 +181,17 @@ test_hash_multiwriter(void)
 		goto err1;
 	}
 
+	for (i = 0; i < nb_entries; i++)
+		keys[i] = i;
+
+	tbl_multiwriter_test_params.keys = keys;
+
 	found = rte_zmalloc(NULL, sizeof(uint32_t) * nb_entries, 0);
 	if (found == NULL) {
 		printf("RTE_ZMALLOC failed\n");
 		goto err2;
 	}
 
-	for (i = 0; i < nb_entries; i++)
-		keys[i] = i;
-
-	tbl_multiwriter_test_params.keys = keys;
 	tbl_multiwriter_test_params.found = found;
 
 	rte_atomic64_init(&gcycles);
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'doc: fix bonding command in testpmd' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (9 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'test/hash: fix potential memory leak' " luca.boccassi
@ 2018-07-27 10:17     ` luca.boccassi
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
  11 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-07-27 10:17 UTC (permalink / raw)
  To: Shreyansh Jain; +Cc: Ferruh Yigit, Bernard Iremonger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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

Thanks.

Luca Boccassi

---
>From aa899f2d3f4ce3e8ae45cfb2f12f426df19ae7fb Mon Sep 17 00:00:00 2001
From: Shreyansh Jain <shreyansh.jain@nxp.com>
Date: Wed, 25 Jul 2018 17:01:32 +0530
Subject: [PATCH] doc: fix bonding command in testpmd

[ upstream commit 0c00abfd85448449d73acc09cc6fe445dba37b50 ]

Fixes: ac718398f477 ("doc: testpmd application user guide")

Signed-off-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
---
 doc/guides/testpmd_app_ug/testpmd_funcs.rst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
index 70d2e4d72..a906974f7 100644
--- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst
+++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
@@ -1439,7 +1439,7 @@ Create a new bonding device::
 
 For example, to create a bonded device in mode 1 on socket 0::
 
-   testpmd> create bonded 1 0
+   testpmd> create bonded device 1 0
    created new bonded device (port X)
 
 add bonding slave
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test: fix uninitialized port configuration' has been queued to LTS release 16.11.8
  2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
                       ` (10 preceding siblings ...)
  2018-07-27 10:17     ` [dpdk-stable] patch 'doc: fix bonding command in testpmd' " luca.boccassi
@ 2018-08-06 10:56     ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'app/testpmd: fix DCB config' " luca.boccassi
                         ` (9 more replies)
  11 siblings, 10 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Bernard Iremonger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From e452ea4e1ac53017937aa8360beccdad4ff8dede Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Tue, 31 Jul 2018 15:16:21 +0100
Subject: [PATCH] test: fix uninitialized port configuration

[ upstream commit f5929159465772a1284e9ea1b87462ef2ab90e94 ]

test_pmd_ring_pair_create_attach() uses an uninitialized
struct rte_eth_conf object

Fixes: 51f567129c94 ("app/test: add pmd_ring")

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
---
 app/test/test_pmd_ring.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/app/test/test_pmd_ring.c b/app/test/test_pmd_ring.c
index 2cdf60d103..8d5813cf09 100644
--- a/app/test/test_pmd_ring.c
+++ b/app/test/test_pmd_ring.c
@@ -247,6 +247,8 @@ test_pmd_ring_pair_create_attach(int portd, int porte)
 	struct rte_mbuf buf, *pbuf = &buf;
 	struct rte_eth_conf null_conf;
 
+	memset(&null_conf, 0, sizeof(struct rte_eth_conf));
+
 	if ((rte_eth_dev_configure(portd, 1, 1, &null_conf) < 0)
 		|| (rte_eth_dev_configure(porte, 1, 1, &null_conf) < 0)) {
 		printf("Configure failed for port\n");
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'app/testpmd: fix DCB config' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnxt: check access denied for HWRM commands' " luca.boccassi
                         ` (8 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Konstantin Ananyev; +Cc: Bernard Iremonger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From d79ab5481fa497535c23b89e0a9fa50aa8fd720b Mon Sep 17 00:00:00 2001
From: Konstantin Ananyev <konstantin.ananyev@intel.com>
Date: Tue, 31 Jul 2018 15:43:34 +0100
Subject: [PATCH] app/testpmd: fix DCB config

[ upstream commit ac7c491c3fecb835d637e867467dcf7cc8736828 ]

After adding RSS hash offload check, default rss_hf will fail on devices
that do not support all bits. This will lead to dcb config failure. The
patch fixes this issue by reading current valid rss_conf from the device.

Fixes: 8863a1fbfc66 ("ethdev: add supported hash function check")
Fixes: 1a572499beb6 ("app/testpmd: setup DCB forwarding based on traffic class")

Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
---
 app/test-pmd/testpmd.c | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index 64e14cee2f..e48cf8a1ab 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -1905,12 +1905,14 @@ const uint16_t vlan_tags[] = {
 };
 
 static  int
-get_eth_dcb_conf(struct rte_eth_conf *eth_conf,
+get_eth_dcb_conf(portid_t pid, struct rte_eth_conf *eth_conf,
 		 enum dcb_mode_enable dcb_mode,
 		 enum rte_eth_nb_tcs num_tcs,
 		 uint8_t pfc_en)
 {
 	uint8_t i;
+	int32_t rc;
+	struct rte_eth_rss_conf rss_conf;
 
 	/*
 	 * Builds up the correct configuration for dcb+vt based on the vlan tags array
@@ -1950,6 +1952,10 @@ get_eth_dcb_conf(struct rte_eth_conf *eth_conf,
 		struct rte_eth_dcb_tx_conf *tx_conf =
 				&eth_conf->tx_adv_conf.dcb_tx_conf;
 
+		rc = rte_eth_dev_rss_hash_conf_get(pid, &rss_conf);
+		if (rc != 0)
+			return rc;
+
 		rx_conf->nb_tcs = num_tcs;
 		tx_conf->nb_tcs = num_tcs;
 
@@ -1957,8 +1963,9 @@ get_eth_dcb_conf(struct rte_eth_conf *eth_conf,
 			rx_conf->dcb_tc[i] = i % num_tcs;
 			tx_conf->dcb_tc[i] = i % num_tcs;
 		}
+
 		eth_conf->rxmode.mq_mode = ETH_MQ_RX_DCB_RSS;
-		eth_conf->rx_adv_conf.rss_conf.rss_hf = rss_hf;
+		eth_conf->rx_adv_conf.rss_conf = rss_conf;
 		eth_conf->txmode.mq_mode = ETH_MQ_TX_DCB;
 	}
 
@@ -1989,7 +1996,7 @@ init_port_dcb_config(portid_t pid,
 	dcb_config = 1;
 
 	/*set configuration of DCB in vt mode and DCB in non-vt mode*/
-	retval = get_eth_dcb_conf(&port_conf, dcb_mode, num_tcs, pfc_en);
+	retval = get_eth_dcb_conf(pid, &port_conf, dcb_mode, num_tcs, pfc_en);
 	if (retval < 0)
 		return retval;
 	port_conf.rxmode.hw_vlan_filter = 1;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnxt: check access denied for HWRM commands' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'app/testpmd: fix DCB config' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnxt: fix RETA size' " luca.boccassi
                         ` (7 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From 071c03e261bba0e88bd15036fd0a1f20e1df1008 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Wed, 25 Jul 2018 18:15:47 -0700
Subject: [PATCH] net/bnxt: check access denied for HWRM commands

[ upstream commit 6dc875ab5ff76377376906aa6d05d95ffd34b9f9 ]

Firmware can restrict access to certain resources in the hardware
depending on various factors. In such cases when the PMD tries to
configure these resources the firmware will return
HWRM_ERR_CODE_RESOURCE_ACCESS_DENIED error. Parse this and return
the standard EACCES error to the applications.

Fixes: 804e746c7b73 ("net/bnxt: add hardware resource manager init code")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_hwrm.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/bnxt/bnxt_hwrm.c b/drivers/net/bnxt/bnxt_hwrm.c
index 5d85eeda32..d65e28bec8 100644
--- a/drivers/net/bnxt/bnxt_hwrm.c
+++ b/drivers/net/bnxt/bnxt_hwrm.c
@@ -134,11 +134,19 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg, uint32_t msg_len)
 		if (rc) { \
 			RTE_LOG(ERR, PMD, "%s failed rc:%d\n", \
 				__func__, rc); \
+			if (rc == HWRM_ERR_CODE_RESOURCE_ACCESS_DENIED) \
+				rc = -EACCES; \
+			else if (rc > 0) \
+				rc = -EINVAL; \
 			return rc; \
 		} \
 		if (resp->error_code) { \
 			rc = rte_le_to_cpu_16(resp->error_code); \
 			RTE_LOG(ERR, PMD, "%s error %d\n", __func__, rc); \
+			if (rc == HWRM_ERR_CODE_RESOURCE_ACCESS_DENIED) \
+				rc = -EACCES; \
+			else if (rc > 0) \
+				rc = -EINVAL; \
 			return rc; \
 		} \
 	}
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix RETA size' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'app/testpmd: fix DCB config' " luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnxt: check access denied for HWRM commands' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/qede/base: fix GRC attention callback' " luca.boccassi
                         ` (6 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: Scott Branden, Randy Schacher, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From 3b449e6988c6a2b31aae68d03a076f3f119704f4 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Wed, 25 Jul 2018 18:15:48 -0700
Subject: [PATCH] net/bnxt: fix RETA size

[ upstream commit 7f675c27d9c80bc6ff3793140fa3215671b295d6 ]

The reta_size being indicated in the bnxt_dev_info_get_op was incorrect.
Set it to the value supported by the hardware.

Fixes: 0a6d2a720078 ("net/bnxt: get device infos")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Scott Branden <scott.branden@broadcom.com>
Reviewed-by: Randy Schacher <stuart.schacher@broadcom.com>
Tested-by: Randy Schacher <stuart.schacher@broadcom.com>
---
 drivers/net/bnxt/bnxt_ethdev.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c
index 0aef27ae73..86c2a81086 100644
--- a/drivers/net/bnxt/bnxt_ethdev.c
+++ b/drivers/net/bnxt/bnxt_ethdev.c
@@ -358,12 +358,12 @@ static void bnxt_dev_info_get_op(struct rte_eth_dev *eth_dev,
 		dev_info->max_rx_queues = bp->pf.max_rx_rings;
 		dev_info->max_tx_queues = bp->pf.max_tx_rings;
 		dev_info->max_vfs = bp->pf.active_vfs;
-		dev_info->reta_size = bp->pf.max_rsscos_ctx;
+		dev_info->reta_size = HW_HASH_INDEX_SIZE;
 		max_vnics = bp->pf.max_vnics;
 	} else {
 		dev_info->max_rx_queues = bp->vf.max_rx_rings;
 		dev_info->max_tx_queues = bp->vf.max_tx_rings;
-		dev_info->reta_size = bp->vf.max_rsscos_ctx;
+		dev_info->reta_size = HW_HASH_INDEX_SIZE;
 		max_vnics = bp->vf.max_vnics;
 	}
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/qede/base: fix GRC attention callback' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (2 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnxt: fix RETA size' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/qede: fix MAC address removal failure message' " luca.boccassi
                         ` (5 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Rasesh Mody; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From beb1ecba673727d4e981ec91e27032d2f025df7a Mon Sep 17 00:00:00 2001
From: Rasesh Mody <rasesh.mody@cavium.com>
Date: Tue, 24 Jul 2018 15:18:43 -0700
Subject: [PATCH] net/qede/base: fix GRC attention callback

[ upstream commit 538bcb378af5d1750a6831efeea4d9565a3267f0 ]

Treat any attention which is not for timeout event as invalid
and return status accordingly. The HW error handler logs and clears
the HW attention. Without this fix we can see flood of GRC attentions.

Fixes: e6051bd6b07d ("qede: add interrupt handling support")

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
---
 drivers/net/qede/base/ecore_int.c | 14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

diff --git a/drivers/net/qede/base/ecore_int.c b/drivers/net/qede/base/ecore_int.c
index 207b01b9ae..8ddfdeef97 100644
--- a/drivers/net/qede/base/ecore_int.c
+++ b/drivers/net/qede/base/ecore_int.c
@@ -229,15 +229,19 @@ static const char *grc_timeout_attn_master_to_str(u8 master)
 
 static enum _ecore_status_t ecore_grc_attn_cb(struct ecore_hwfn *p_hwfn)
 {
+	enum _ecore_status_t rc = ECORE_SUCCESS;
 	u32 tmp, tmp2;
 
 	/* We've already cleared the timeout interrupt register, so we learn
-	 * of interrupts via the validity register
+	 * of interrupts via the validity register.
+	 * Any attention which is not for a timeout event is treated as fatal.
 	 */
 	tmp = ecore_rd(p_hwfn, p_hwfn->p_dpc_ptt,
 		       GRC_REG_TIMEOUT_ATTN_ACCESS_VALID);
-	if (!(tmp & ECORE_GRC_ATTENTION_VALID_BIT))
+	if (!(tmp & ECORE_GRC_ATTENTION_VALID_BIT)) {
+		rc = ECORE_INVAL;
 		goto out;
+	}
 
 	/* Read the GRC timeout information */
 	tmp = ecore_rd(p_hwfn, p_hwfn->p_dpc_ptt,
@@ -261,11 +265,11 @@ static enum _ecore_status_t ecore_grc_attn_cb(struct ecore_hwfn *p_hwfn)
 		(tmp2 & ECORE_GRC_ATTENTION_VF_MASK) >>
 		ECORE_GRC_ATTENTION_VF_SHIFT);
 
-out:
-	/* Regardles of anything else, clean the validity bit */
+	/* Clean the validity bit */
 	ecore_wr(p_hwfn, p_hwfn->p_dpc_ptt,
 		 GRC_REG_TIMEOUT_ATTN_ACCESS_VALID, 0);
-	return ECORE_SUCCESS;
+out:
+	return rc;
 }
 
 #define ECORE_PGLUE_ATTENTION_VALID (1 << 29)
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/qede: fix MAC address removal failure message' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (3 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/qede/base: fix GRC attention callback' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnx2x: fix FW command timeout during stop' " luca.boccassi
                         ` (4 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Shahed Shaikh; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From de9c4dccfdf5cb1da68ed442f8dd4c12a0bbf6ad Mon Sep 17 00:00:00 2001
From: Shahed Shaikh <shahed.shaikh@cavium.com>
Date: Tue, 24 Jul 2018 15:18:44 -0700
Subject: [PATCH] net/qede: fix MAC address removal failure message

[ upstream commit 7e3060a3704e21ab63e9f1b4338be2fed9a345d1 ]

Don't treat MAC address removal failure as a fatal error
and print in logs.

Fixes: 77fac1b54fc9 ("net/qede: fix filtering code")

Signed-off-by: Shahed Shaikh <shahed.shaikh@cavium.com>
---
 drivers/net/qede/qede_ethdev.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.c
index 17931020f7..679599f8b0 100644
--- a/drivers/net/qede/qede_ethdev.c
+++ b/drivers/net/qede/qede_ethdev.c
@@ -441,7 +441,10 @@ qede_mac_int_ops(struct rte_eth_dev *eth_dev, struct ecore_filter_ucast *ucast,
 		if (rc == 0)
 			rc = ecore_filter_ucast_cmd(edev, ucast,
 						    ECORE_SPQ_MODE_CB, NULL);
-		if (rc != ECORE_SUCCESS) {
+		/* Indicate error only for add filter operation.
+		 * Delete filter operations are not severe.
+		 */
+		if ((rc != ECORE_SUCCESS) && add) {
 			DP_ERR(edev, "MAC filter failed, rc = %d, op = %d\n",
 			       rc, add);
 		}
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bnx2x: fix FW command timeout during stop' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (4 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/qede: fix MAC address removal failure message' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/i40e: revert fix of flow director check' " luca.boccassi
                         ` (3 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Rasesh Mody; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From ad96fd0e21c84114d59c8bf673c0c5be558c63e1 Mon Sep 17 00:00:00 2001
From: Rasesh Mody <rasesh.mody@cavium.com>
Date: Wed, 1 Aug 2018 11:19:20 -0700
Subject: [PATCH] net/bnx2x: fix FW command timeout during stop

[ upstream commit 4a4607bb9cadcc49a062a46588dbdcc873dfe27a ]

This patch fixes firmware command timeout error seen during device stop
while stopping queues. It patially reverts an earlier preventive change
commit 91b7e432bcef ("net/bnx2x: disable fast path interrupts") to now
enable fast path interrupts.

The original issue of performance degradation is not observed anymore,
with or without the fix.

Fixes: 91b7e432bcef ("net/bnx2x: disable fast path interrupts")

Signed-off-by: Rasesh Mody <rasesh.mody@cavium.com>
---
 drivers/net/bnx2x/bnx2x.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/net/bnx2x/bnx2x.c b/drivers/net/bnx2x/bnx2x.c
index c2842e3a25..f1de336224 100644
--- a/drivers/net/bnx2x/bnx2x.c
+++ b/drivers/net/bnx2x/bnx2x.c
@@ -4492,6 +4492,8 @@ static void bnx2x_handle_fp_tq(struct bnx2x_fastpath *fp, int scan_fp)
 	struct bnx2x_softc *sc = fp->sc;
 	uint8_t more_rx = FALSE;
 
+	PMD_DRV_LOG(DEBUG, "---> FP TASK QUEUE (%d) <--", fp->index);
+
 	/* update the fastpath index */
 	bnx2x_update_fp_sb_idx(fp);
 
@@ -4508,7 +4510,7 @@ static void bnx2x_handle_fp_tq(struct bnx2x_fastpath *fp, int scan_fp)
 	}
 
 	bnx2x_ack_sb(sc, fp->igu_sb_id, USTORM_ID,
-		   le16toh(fp->fp_hc_idx), IGU_INT_DISABLE, 1);
+		   le16toh(fp->fp_hc_idx), IGU_INT_ENABLE, 1);
 }
 
 /*
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/i40e: revert fix of flow director check' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (5 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnx2x: fix FW command timeout during stop' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bonding: fix race condition' " luca.boccassi
                         ` (2 subsequent siblings)
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Wei Zhao; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From 52ccb927ed1565778331c5e3085a874b70d2736a Mon Sep 17 00:00:00 2001
From: Wei Zhao <wei.zhao1@intel.com>
Date: Wed, 1 Aug 2018 10:54:50 +0800
Subject: [PATCH] net/i40e: revert fix of flow director check

[ upstream commit 21ecd2d7ab59060e3123261d1d62a53182029dd0 ]

This reverts commit 7546dc4a1331340ecb665af9af0a005bb8b657c8.

In i40e FDIR PMD code for checking programming status,
when the action of add FDIR filter is ok, i40e NIC will
not write back to programming status descriptor, so if
PMD code check DD is not done after period of time dealy,
it means the add or remove filter action is ok. It only write
back descriptor when fail. So, there is no issue for the original
code.

Fixes: 7546dc4a1331 ("net/i40e: fix check of flow director programming status")

Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_fdir.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_fdir.c b/drivers/net/i40e/i40e_fdir.c
index 25578257d5..e25b8e0c43 100644
--- a/drivers/net/i40e/i40e_fdir.c
+++ b/drivers/net/i40e/i40e_fdir.c
@@ -1020,8 +1020,6 @@ i40e_check_fdir_programming_status(struct i40e_rx_queue *rxq)
 			I40E_PCI_REG_WRITE(rxq->qrx_tail, rxq->nb_rx_desc - 1);
 		else
 			I40E_PCI_REG_WRITE(rxq->qrx_tail, rxq->rx_tail - 1);
-	} else {
-		ret = -1;
 	}
 
 	return ret;
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/bonding: fix race condition' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (6 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/i40e: revert fix of flow director check' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-06 10:56       ` [dpdk-stable] patch 'eal: fix bitmap documentation' " luca.boccassi
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Chas Williams, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From 64463044f24ff88b30f153df2b9451698e8fafbc Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Wed, 25 Jul 2018 10:39:40 +0100
Subject: [PATCH] net/bonding: fix race condition

[ upstream commit 5922ff069fb910946f97780754ad4b66b987d5b6 ]

Race condition can appear in the bond_mode_8023ad_periodic_cb()
callback when bonding port is stopped, reconfigured and restarted.

Re-ordered calls in bond_ethdev_start() to have callback alarm set
after slave ports are reconfigured.

Fixes: 2efb58cbab6e ("bond: new link bonding library")

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Acked-by: Chas Williams <chas3@att.com>
---
 drivers/net/bonding/rte_eth_bond_pmd.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index 5905c70707..6081918e79 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -1545,10 +1545,6 @@ bond_ethdev_start(struct rte_eth_dev *eth_dev)
 		}
 	}
 
-	/* Update all slave devices MACs*/
-	if (mac_address_slaves_update(eth_dev) != 0)
-		goto out_err;
-
 	/* If bonded device is configure in promiscuous mode then re-apply config */
 	if (internals->promiscuous_en)
 		bond_ethdev_promiscuous_enable(eth_dev);
@@ -1577,6 +1573,10 @@ bond_ethdev_start(struct rte_eth_dev *eth_dev)
 			(void *)&rte_eth_devices[internals->port_id]);
 	}
 
+	/* Update all slave devices MACs*/
+	if (mac_address_slaves_update(eth_dev) != 0)
+		goto out_err;
+
 	if (internals->user_defined_primary_port)
 		bond_ethdev_primary_set(internals, internals->primary_port);
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'eal: fix bitmap documentation' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (7 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'net/bonding: fix race condition' " luca.boccassi
@ 2018-08-06 10:56       ` luca.boccassi
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
  9 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-06 10:56 UTC (permalink / raw)
  To: Jerin Jacob; +Cc: Cristian Dumitrescu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/08/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From a6bc78ba2c1600c1743344e157f22655ebb4947b Mon Sep 17 00:00:00 2001
From: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Date: Tue, 17 Jul 2018 22:44:17 +0530
Subject: [PATCH] eal: fix bitmap documentation

[ upstream commit ebaa25f0700e95063d783911d30c476a1c86d336 ]

n_bits comes as first argument, align doxygen comment.

n_bit need to not be multiple of 512 as n_bits
are rounding to RTE_BITMAP_CL_BIT_SIZE.

Fixes: 14456f59e9f7 ("doc: fix doxygen warnings in QoS API")
Fixes: de3cfa2c9823 ("sched: initial import")

Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
---
 lib/librte_sched/rte_bitmap.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/lib/librte_sched/rte_bitmap.h b/lib/librte_sched/rte_bitmap.h
index 010d752c2f..bbf4da94be 100644
--- a/lib/librte_sched/rte_bitmap.h
+++ b/lib/librte_sched/rte_bitmap.h
@@ -226,12 +226,12 @@ rte_bitmap_get_memory_footprint(uint32_t n_bits) {
 /**
  * Bitmap initialization
  *
- * @param mem_size
- *   Minimum expected size of bitmap.
+ * @param n_bits
+ *   Number of pre-allocated bits in array2.
  * @param mem
  *   Base address of array1 and array2.
- * @param n_bits
- *   Number of pre-allocated bits in array2. Must be non-zero and multiple of 512.
+ * @param mem_size
+ *   Minimum expected size of bitmap.
  * @return
  *   Handle to bitmap instance.
  */
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'hash: fix doxygen of return values' has been queued to LTS release 16.11.8
  2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
                         ` (8 preceding siblings ...)
  2018-08-06 10:56       ` [dpdk-stable] patch 'eal: fix bitmap documentation' " luca.boccassi
@ 2018-08-10  9:06       ` luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix crash with null name' " luca.boccassi
                           ` (5 more replies)
  9 siblings, 6 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-10  9:06 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: Petr Houska, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/12/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From b785d6d5d2448c0f91ec489c34df1a440166d1fc Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Tue, 7 Aug 2018 03:00:04 +0100
Subject: [PATCH] hash: fix doxygen of return values

[ upstream commit f9975d333a8d51e4c15961f56a554914288768aa ]

rte_hash_lookup_data() and rte_hash_lookup_with_hash_data()
functions return the index of the table where the key is stored
when this is found, and not 0 as the Doxygen currently states.

Also, these functions, and rte_hash_get_key_with_position()
return negative values when keys are not found (-EINVAL and -ENOENT),
where the minus sign was missing.

Bugzilla ID: 78
Fixes: 473d1bebce43 ("hash: allow to store data in hash table")
Fixes: 6dc34e0afe7a ("hash: retrieve a key given its position")

Reported-by: Petr Houska <t-pehous@microsoft.com>
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 lib/librte_hash/rte_hash.h | 20 ++++++++++++--------
 1 file changed, 12 insertions(+), 8 deletions(-)

diff --git a/lib/librte_hash/rte_hash.h b/lib/librte_hash/rte_hash.h
index f29de81aec..8da2afa3f5 100644
--- a/lib/librte_hash/rte_hash.h
+++ b/lib/librte_hash/rte_hash.h
@@ -283,8 +283,8 @@ rte_hash_del_key_with_hash(const struct rte_hash *h, const void *key, hash_sig_t
  *   Output containing a pointer to the key
  * @return
  *   - 0 if retrieved successfully
- *   - EINVAL if the parameters are invalid.
- *   - ENOENT if no valid key is found in the given position.
+ *   - -EINVAL if the parameters are invalid.
+ *   - -ENOENT if no valid key is found in the given position.
  */
 int
 rte_hash_get_key_with_position(const struct rte_hash *h, const int32_t position,
@@ -301,9 +301,11 @@ rte_hash_get_key_with_position(const struct rte_hash *h, const int32_t position,
  * @param data
  *   Output with pointer to data returned from the hash table.
  * @return
- *   0 if successful lookup
- *   - EINVAL if the parameters are invalid.
- *   - ENOENT if the key is not found.
+ *   - A positive value that can be used by the caller as an offset into an
+ *     array of user data. This value is unique for this key, and is the same
+ *     value that was returned when the key was added.
+ *   - -EINVAL if the parameters are invalid.
+ *   - -ENOENT if the key is not found.
  */
 int
 rte_hash_lookup_data(const struct rte_hash *h, const void *key, void **data);
@@ -322,9 +324,11 @@ rte_hash_lookup_data(const struct rte_hash *h, const void *key, void **data);
  * @param data
  *   Output with pointer to data returned from the hash table.
  * @return
- *   0 if successful lookup
- *   - EINVAL if the parameters are invalid.
- *   - ENOENT if the key is not found.
+ *   - A positive value that can be used by the caller as an offset into an
+ *     array of user data. This value is unique for this key, and is the same
+ *     value that was returned when the key was added.
+ *   - -EINVAL if the parameters are invalid.
+ *   - -ENOENT if the key is not found.
  */
 int
 rte_hash_lookup_with_hash_data(const struct rte_hash *h, const void *key,
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'kni: fix crash with null name' has been queued to LTS release 16.11.8
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
@ 2018-08-10  9:06         ` luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix build on RHEL 7.5' " luca.boccassi
                           ` (4 subsequent siblings)
  5 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-10  9:06 UTC (permalink / raw)
  To: Dan Gora; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/12/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From 4599762e58b07baac76656b9c89929841cb432c8 Mon Sep 17 00:00:00 2001
From: Dan Gora <dg@adax.com>
Date: Thu, 28 Jun 2018 15:58:38 -0700
Subject: [PATCH] kni: fix crash with null name

[ upstream commit e716b639856cc4baa46bc6d5bc63bcc1d6bd9cf9 ]

Fix a segmentation fault which occurs when the kni_autotest is run
in the 'test' application.

This segmenation fault occurs when rte_kni_get() is called with a
NULL value for 'name'.

Fixes: 0c6bc8ef70ba ("kni: memzone pool for alloc and release")

Signed-off-by: Dan Gora <dg@adax.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 lib/librte_kni/rte_kni.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/librte_kni/rte_kni.c b/lib/librte_kni/rte_kni.c
index c3f9208c12..0c6641bfa4 100644
--- a/lib/librte_kni/rte_kni.c
+++ b/lib/librte_kni/rte_kni.c
@@ -678,6 +678,9 @@ rte_kni_get(const char *name)
 	struct rte_kni_memzone_slot *it;
 	struct rte_kni *kni;
 
+	if (name == NULL || name[0] == '\0')
+		return NULL;
+
 	/* Note: could be improved perf-wise if necessary */
 	for (i = 0; i < kni_memzone_pool.max_ifaces; i++) {
 		it = &kni_memzone_pool.slots[i];
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'kni: fix build on RHEL 7.5' has been queued to LTS release 16.11.8
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix crash with null name' " luca.boccassi
@ 2018-08-10  9:06         ` luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'ethdev: fix a doxygen comment for port allocation' " luca.boccassi
                           ` (3 subsequent siblings)
  5 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-10  9:06 UTC (permalink / raw)
  To: Drocula Lambda; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/12/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From bea638fbdff6ba624c9515d5d04e806fc83608e4 Mon Sep 17 00:00:00 2001
From: Drocula Lambda <quzeyao@gmail.com>
Date: Thu, 9 Aug 2018 12:09:06 +0000
Subject: [PATCH] kni: fix build on RHEL 7.5

[ upstream commit 3639c91df43d7cfa29cf4d419a2c56c45f6fcf26 ]

This patch fixes compilation errors on Centos 7.5 when
CONFIG_RTE_KNI_KMOD_ETHTOOL is set to 'y'.
On RHEL75 ndo_change_mtu has changed to ndo_change_mtu_rh74.

See commit 37d477b6863e5c06 ("kni: fix build on RHEL 7.5")

Signed-off-by: Drocula Lambda <quzeyao@gmail.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
index 88bd18eca0..9e4798efcc 100644
--- a/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
+++ b/lib/librte_eal/linuxapp/kni/ethtool/igb/kcompat.h
@@ -3933,6 +3933,11 @@ skb_set_hash(struct sk_buff *skb, __u32 hash, __always_unused int type)
 #define HAVE_VF_VLAN_PROTO
 #endif /* >= 4.9.0 */
 
+#if (defined(RHEL_RELEASE_CODE) && \
+	(RHEL_RELEASE_VERSION(7, 5) <= RHEL_RELEASE_CODE))
+#define ndo_change_mtu ndo_change_mtu_rh74
+#endif
+
 #if LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0)
 #define HAVE_PCI_ENABLE_MSIX
 #endif
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'ethdev: fix a doxygen comment for port allocation' has been queued to LTS release 16.11.8
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix crash with null name' " luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix build on RHEL 7.5' " luca.boccassi
@ 2018-08-10  9:06         ` luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'mk: fix permissions when using make install' " luca.boccassi
                           ` (2 subsequent siblings)
  5 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-10  9:06 UTC (permalink / raw)
  To: Rami Rosen; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/12/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From 88a33ba454883f8f531e1706cbaaa9bb3440da4e Mon Sep 17 00:00:00 2001
From: Rami Rosen <rami.rosen@intel.com>
Date: Sun, 5 Aug 2018 23:03:28 +0300
Subject: [PATCH] ethdev: fix a doxygen comment for port allocation

[ upstream commit 2da7f0146e47833215e68f2c658b4275b8d609fc ]

This patch fixes a doxygen comment of the rte_eth_dev_allocate()
method. There is no parameter named "type" for this
method; so this patch removes the doxygen comment about it.

Fixes: 6751f6deb798 ("ethdev: get rid of device type")

Signed-off-by: Rami Rosen <rami.rosen@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 lib/librte_ether/rte_ethdev.h | 1 -
 1 file changed, 1 deletion(-)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index 1b6d2187b9..981e05770f 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -1742,7 +1742,6 @@ struct rte_eth_dev *rte_eth_dev_allocated(const char *name);
  * to that slot for the driver to use.
  *
  * @param	name	Unique identifier name for each Ethernet device
- * @param	type	Device type of this Ethernet device
  * @return
  *   - Slot in the rte_dev_devices array for a new device;
  */
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'mk: fix permissions when using make install' has been queued to LTS release 16.11.8
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
                           ` (2 preceding siblings ...)
  2018-08-10  9:06         ` [dpdk-stable] patch 'ethdev: fix a doxygen comment for port allocation' " luca.boccassi
@ 2018-08-10  9:06         ` luca.boccassi
  2018-08-10  9:06         ` [dpdk-stable] patch 'maintainers: claim maintainership for ARM v7 and v8' " luca.boccassi
  2018-08-28 10:25         ` [dpdk-stable] patch 'net/null: add MAC address setting fake operation' " Luca Boccassi
  5 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-10  9:06 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: Thomas Monjalon, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/12/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From d006ac1f6414a7540115f356fb536199c73eba33 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Thu, 9 Aug 2018 16:22:35 +0100
Subject: [PATCH] mk: fix permissions when using make install

[ upstream commit 2a1a8a5f766a10ecb86514b7dbefd41694f7e47a ]

When using make install, the permissions of the resulting file should be
those of the user using make install, not those of the user who ran the
build. This would not be the case when a user explicitly runs:

   "make && sudo make install"

Fix this by changing "cp -a", which preserves all attributes, to
"cp -dR --preserve=timestamp", and by adding the flags
"--no-same-owner --no-same-permissions" to the calls to tar.

Fixes: 1fa0fd9d6b42 ("mk: allow to specify DESTDIR in build rule")
Fixes: 6b62a72a70d0 ("mk: install a standard cutomizable tree")
Fixes: 576de42b83e5 ("doc: render and install man pages")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
---
 mk/rte.sdkinstall.mk | 36 +++++++++++++++++++-----------------
 1 file changed, 19 insertions(+), 17 deletions(-)

diff --git a/mk/rte.sdkinstall.mk b/mk/rte.sdkinstall.mk
index 7b0d8b5211..713c69dcb1 100644
--- a/mk/rte.sdkinstall.mk
+++ b/mk/rte.sdkinstall.mk
@@ -113,18 +113,22 @@ else
 	@echo Installation in $(DESTDIR)$(prefix)/ complete
 endif
 
+# when installing we want recursive copies preserving timestamps only, no
+# preservation of user/group ids or permissions
+CP_FLAGS=-dR --preserve=timestamps
+TAR_X_FLAGS=--strip-components=1 --keep-newer-files --no-same-owner --no-same-permissions
+
 install-runtime:
 	$(Q)$(call rte_mkdir, $(DESTDIR)$(libdir))
-	$(Q)cp -a    $O/lib/* $(DESTDIR)$(libdir)
+	$(Q)cp $(CP_FLAGS)    $O/lib/* $(DESTDIR)$(libdir)
 	$(Q)$(call rte_mkdir, $(DESTDIR)$(bindir))
 	$(Q)tar -cf -      -C $O --exclude 'app/*.map' \
 		--exclude app/dpdk-pmdinfogen \
 		--exclude 'app/cmdline*' --exclude app/test \
 		--exclude app/testacl --exclude app/testpipeline app | \
-	    tar -xf -      -C $(DESTDIR)$(bindir) --strip-components=1 \
-		--keep-newer-files
+	    tar -xf -      -C $(DESTDIR)$(bindir) $(TAR_X_FLAGS)
 	$(Q)$(call rte_mkdir,      $(DESTDIR)$(datadir))
-	$(Q)cp -a $(RTE_SDK)/tools $(DESTDIR)$(datadir)
+	$(Q)cp $(CP_FLAGS) $(RTE_SDK)/tools $(DESTDIR)$(datadir)
 	$(Q)$(call rte_symlink,    $(DESTDIR)$(datadir)/tools/dpdk-setup.sh, \
 	                           $(DESTDIR)$(datadir)/tools/setup.sh)
 	$(Q)$(call rte_symlink,    $(DESTDIR)$(datadir)/tools/dpdk-devbind.py, \
@@ -136,30 +140,29 @@ install-runtime:
 	                           $(DESTDIR)$(bindir)/dpdk-pmdinfo)
 ifneq ($(wildcard $O/doc/man/*/*.1),)
 	$(Q)$(call rte_mkdir,      $(DESTDIR)$(mandir)/man1)
-	$(Q)cp -a $O/doc/man/*/*.1 $(DESTDIR)$(mandir)/man1
+	$(Q)cp $(CP_FLAGS) $O/doc/man/*/*.1 $(DESTDIR)$(mandir)/man1
 endif
 ifneq ($(wildcard $O/doc/man/*/*.8),)
 	$(Q)$(call rte_mkdir,      $(DESTDIR)$(mandir)/man8)
-	$(Q)cp -a $O/doc/man/*/*.8 $(DESTDIR)$(mandir)/man8
+	$(Q)cp $(CP_FLAGS) $O/doc/man/*/*.8 $(DESTDIR)$(mandir)/man8
 endif
 
 install-kmod:
 ifneq ($(wildcard $O/kmod/*),)
 	$(Q)$(call rte_mkdir, $(DESTDIR)$(kerneldir))
-	$(Q)cp -a   $O/kmod/* $(DESTDIR)$(kerneldir)
+	$(Q)cp $(CP_FLAGS)   $O/kmod/* $(DESTDIR)$(kerneldir)
 endif
 
 install-sdk:
 	$(Q)$(call rte_mkdir, $(DESTDIR)$(includedir))
 	$(Q)tar -chf -     -C $O include | \
-	    tar -xf -      -C $(DESTDIR)$(includedir) --strip-components=1 \
-		--keep-newer-files
+	    tar -xf -      -C $(DESTDIR)$(includedir) $(TAR_X_FLAGS)
 	$(Q)$(call rte_mkdir,                            $(DESTDIR)$(sdkdir))
-	$(Q)cp -a               $(RTE_SDK)/mk            $(DESTDIR)$(sdkdir)
-	$(Q)cp -a               $(RTE_SDK)/scripts       $(DESTDIR)$(sdkdir)
+	$(Q)cp $(CP_FLAGS)      $(RTE_SDK)/mk            $(DESTDIR)$(sdkdir)
+	$(Q)cp $(CP_FLAGS)      $(RTE_SDK)/scripts       $(DESTDIR)$(sdkdir)
 	$(Q)$(call rte_mkdir,                            $(DESTDIR)$(targetdir)/app)
-	$(Q)cp -a               $O/.config               $(DESTDIR)$(targetdir)
-	$(Q)cp -a               $O/app/dpdk-pmdinfogen   $(DESTDIR)$(targetdir)/app
+	$(Q)cp $(CP_FLAGS)      $O/.config               $(DESTDIR)$(targetdir)
+	$(Q)cp $(CP_FLAGS)      $O/app/dpdk-pmdinfogen   $(DESTDIR)$(targetdir)/app
 	$(Q)$(call rte_symlink, $(DESTDIR)$(includedir), $(DESTDIR)$(targetdir)/include)
 	$(Q)$(call rte_symlink, $(DESTDIR)$(libdir),     $(DESTDIR)$(targetdir)/lib)
 
@@ -167,12 +170,11 @@ install-doc:
 ifneq ($(wildcard $O/doc/html),)
 	$(Q)$(call rte_mkdir, $(DESTDIR)$(docdir))
 	$(Q)tar -cf -      -C $O/doc html --exclude 'html/guides/.*' | \
-	    tar -xf -      -C $(DESTDIR)$(docdir) --strip-components=1 \
-		--keep-newer-files
+	    tar -xf -      -C $(DESTDIR)$(docdir) $(TAR_X_FLAGS)
 endif
 ifneq ($(wildcard $O/doc/*/*/*pdf),)
 	$(Q)$(call rte_mkdir,     $(DESTDIR)$(docdir)/guides)
-	$(Q)cp -a $O/doc/*/*/*pdf $(DESTDIR)$(docdir)/guides
+	$(Q)cp $(CP_FLAGS) $O/doc/*/*/*pdf $(DESTDIR)$(docdir)/guides
 endif
 	$(Q)$(call rte_mkdir,         $(DESTDIR)$(datadir))
-	$(Q)cp -a $(RTE_SDK)/examples $(DESTDIR)$(datadir)
+	$(Q)cp $(CP_FLAGS) $(RTE_SDK)/examples $(DESTDIR)$(datadir)
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'maintainers: claim maintainership for ARM v7 and v8' has been queued to LTS release 16.11.8
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
                           ` (3 preceding siblings ...)
  2018-08-10  9:06         ` [dpdk-stable] patch 'mk: fix permissions when using make install' " luca.boccassi
@ 2018-08-10  9:06         ` luca.boccassi
  2018-08-28 10:25         ` [dpdk-stable] patch 'net/null: add MAC address setting fake operation' " Luca Boccassi
  5 siblings, 0 replies; 66+ messages in thread
From: luca.boccassi @ 2018-08-10  9:06 UTC (permalink / raw)
  To: Gavin Hu
  Cc: Song Zhu, Honnappa Nagarahalli, Jerin Jacob, Jan Viktorin,
	Jianbo Liu, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/12/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From a8669f83c2f87d2c8b0c4aac1a818216de4e4909 Mon Sep 17 00:00:00 2001
From: Gavin Hu <gavin.hu@arm.com>
Date: Thu, 9 Aug 2018 09:58:03 +0800
Subject: [PATCH] maintainers: claim maintainership for ARM v7 and v8

[ upstream commit 94110dc0d8842bf72088250706b8483fad6edf48 ]

Claim the maintainership as Jianbo Liu is not working on this any more.
Aslo remove the co-maintainership for Marvel mvpp2 amd mrvl crypto driver
and doc.

Signed-off-by: Gavin Hu <gavin.hu@arm.com>
Reviewed-by: Song Zhu <song.zhu@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
---
 MAINTAINERS | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index 17bbf48b29..1775e3ffed 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -140,13 +140,13 @@ F: doc/guides/sample_app_ug/multi_process.rst
 
 ARM v7
 M: Jan Viktorin <viktorin@rehivetech.com>
-M: Jianbo Liu <jianbo.liu@linaro.org>
+M: Gavin Hu <gavin.hu@arm.com>
 F: lib/librte_eal/common/arch/arm/
 F: lib/librte_eal/common/include/arch/arm/
 
 ARM v8
 M: Jerin Jacob <jerin.jacob@caviumnetworks.com>
-M: Jianbo Liu <jianbo.liu@linaro.org>
+M: Gavin Hu <gavin.hu@arm.com>
 F: lib/librte_eal/common/include/arch/arm/*_64.h
 F: lib/librte_acl/acl_run_neon.*
 F: lib/librte_lpm/rte_lpm_neon.h
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'net/null: add MAC address setting fake operation' has been queued to LTS release 16.11.8
  2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
                           ` (4 preceding siblings ...)
  2018-08-10  9:06         ` [dpdk-stable] patch 'maintainers: claim maintainership for ARM v7 and v8' " luca.boccassi
@ 2018-08-28 10:25         ` Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'test/virtual_pmd: add MAC address setting fake op' " Luca Boccassi
                             ` (2 more replies)
  5 siblings, 3 replies; 66+ messages in thread
From: Luca Boccassi @ 2018-08-28 10:25 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/29/18. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Luca Boccassi

---
>From df9ce0455772f1f3b4250e81a64d2183fd8200ec Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Thu, 1 Feb 2018 10:47:07 +0000
Subject: [PATCH] net/null: add MAC address setting fake operation

[ backported from commit c5ac7748fd6bfd86b6fb4432b6792733cf32c94c ]

Needed if used with net/bonding

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/null/rte_eth_null.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/net/null/rte_eth_null.c b/drivers/net/null/rte_eth_null.c
index 067ee29392..620f09a550 100644
--- a/drivers/net/null/rte_eth_null.c
+++ b/drivers/net/null/rte_eth_null.c
@@ -462,6 +462,12 @@ eth_rss_hash_conf_get(struct rte_eth_dev *dev,
 	return 0;
 }
 
+static void
+eth_mac_address_set(__rte_unused struct rte_eth_dev *dev,
+		    __rte_unused struct ether_addr *addr)
+{
+}
+
 static const struct eth_dev_ops ops = {
 	.dev_start = eth_dev_start,
 	.dev_stop = eth_dev_stop,
@@ -472,6 +478,7 @@ static const struct eth_dev_ops ops = {
 	.rx_queue_release = eth_queue_release,
 	.tx_queue_release = eth_queue_release,
 	.link_update = eth_link_update,
+	.mac_addr_set = eth_mac_address_set,
 	.stats_get = eth_stats_get,
 	.stats_reset = eth_stats_reset,
 	.reta_update = eth_rss_reta_update,
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test/virtual_pmd: add MAC address setting fake op' has been queued to LTS release 16.11.8
  2018-08-28 10:25         ` [dpdk-stable] patch 'net/null: add MAC address setting fake operation' " Luca Boccassi
@ 2018-08-28 10:25           ` Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'test/bonding: assign non-zero MAC to null devices' " Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'Revert "net/i40e: fix packet count for PF"' " Luca Boccassi
  2 siblings, 0 replies; 66+ messages in thread
From: Luca Boccassi @ 2018-08-28 10:25 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/29/18. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Luca Boccassi

---
>From 63c009e4f2ea9461b821dd949df1b7b2142b4cd6 Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Thu, 1 Feb 2018 10:48:57 +0000
Subject: [PATCH] test/virtual_pmd: add MAC address setting fake op

[ backported from commit c23fc36284e26fca9b52641118ad76a4da99d7af ]

Needed if used with net/bonding

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 app/test/virtual_pmd.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/app/test/virtual_pmd.c b/app/test/virtual_pmd.c
index 65b44c64a3..02ac4851b0 100644
--- a/app/test/virtual_pmd.c
+++ b/app/test/virtual_pmd.c
@@ -241,6 +241,11 @@ static void
 virtual_ethdev_promiscuous_mode_disable(struct rte_eth_dev *dev __rte_unused)
 {}
 
+static void
+virtual_ethdev_mac_address_set(__rte_unused struct rte_eth_dev *dev,
+			       __rte_unused struct ether_addr *addr)
+{
+}
 
 static const struct eth_dev_ops virtual_ethdev_default_dev_ops = {
 	.dev_configure = virtual_ethdev_configure_success,
@@ -253,13 +258,13 @@ static const struct eth_dev_ops virtual_ethdev_default_dev_ops = {
 	.rx_queue_release = virtual_ethdev_rx_queue_release,
 	.tx_queue_release = virtual_ethdev_tx_queue_release,
 	.link_update = virtual_ethdev_link_update_success,
+	.mac_addr_set = virtual_ethdev_mac_address_set,
 	.stats_get = virtual_ethdev_stats_get,
 	.stats_reset = virtual_ethdev_stats_reset,
 	.promiscuous_enable = virtual_ethdev_promiscuous_mode_enable,
 	.promiscuous_disable = virtual_ethdev_promiscuous_mode_disable
 };
 
-
 void
 virtual_ethdev_start_fn_set_success(uint8_t port_id, uint8_t success)
 {
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'test/bonding: assign non-zero MAC to null devices' has been queued to LTS release 16.11.8
  2018-08-28 10:25         ` [dpdk-stable] patch 'net/null: add MAC address setting fake operation' " Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'test/virtual_pmd: add MAC address setting fake op' " Luca Boccassi
@ 2018-08-28 10:25           ` Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'Revert "net/i40e: fix packet count for PF"' " Luca Boccassi
  2 siblings, 0 replies; 66+ messages in thread
From: Luca Boccassi @ 2018-08-28 10:25 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/29/18. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Luca Boccassi

---
>From 9a334025ba6241b9692bf428c2d747122866c95a Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Thu, 1 Feb 2018 11:06:18 +0000
Subject: [PATCH] test/bonding: assign non-zero MAC to null devices

[ backported from commit e8df563bac263e55b7dd9d45a00417aa92ef66cb ]

Prevent failure in rte_eth_dev_default_mac_addr_set() that
results in bonding add slave failure.

Fixes: aa7791ba8de0 ("net/bonding: fix setting slave MAC addresses")

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 app/test/test_link_bonding_rssconf.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/app/test/test_link_bonding_rssconf.c b/app/test/test_link_bonding_rssconf.c
index 23052a2cb7..e7a565001b 100644
--- a/app/test/test_link_bonding_rssconf.c
+++ b/app/test/test_link_bonding_rssconf.c
@@ -533,6 +533,7 @@ test_setup(void)
 	int port_id;
 	char name[256];
 	struct slave_conf *port;
+	struct ether_addr mac_addr = { .addr_bytes = {0} };
 
 	if (test_params.mbuf_pool == NULL) {
 
@@ -565,6 +566,10 @@ test_setup(void)
 		TEST_ASSERT_SUCCESS(retval, "Failed to configure virtual ethdev %s\n",
 				name);
 
+		/* assign a non-zero MAC */
+		mac_addr.addr_bytes[5] = 0x10 + port->port_id;
+		rte_eth_dev_default_mac_addr_set(port->port_id, &mac_addr);
+
 		rte_eth_dev_info_get(port->port_id, &port->dev_info);
 	}
 
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [dpdk-stable] patch 'Revert "net/i40e: fix packet count for PF"' has been queued to LTS release 16.11.8
  2018-08-28 10:25         ` [dpdk-stable] patch 'net/null: add MAC address setting fake operation' " Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'test/virtual_pmd: add MAC address setting fake op' " Luca Boccassi
  2018-08-28 10:25           ` [dpdk-stable] patch 'test/bonding: assign non-zero MAC to null devices' " Luca Boccassi
@ 2018-08-28 10:25           ` Luca Boccassi
  2 siblings, 0 replies; 66+ messages in thread
From: Luca Boccassi @ 2018-08-28 10:25 UTC (permalink / raw)
  To: qi.z.zhang; +Cc: dpdk stable, Luca Boccassi

Hi,

FYI, your patch has been queued to LTS release 16.11.8

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/29/18. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Luca Boccassi

---
>From 2a7790e63aaa7ba16d7f8e0d71655228b9b53c03 Mon Sep 17 00:00:00 2001
From: Luca Boccassi <bluca@debian.org>
Date: Mon, 27 Aug 2018 10:44:36 +0100
Subject: [PATCH] Revert "net/i40e: fix packet count for PF"

This patch introduced a regression in the Fortville regression tests.
>From the tester's report:

1.FVL function test: still have 7 failed.
 These 7 failed cases are the similar issue: it will send blank packet
 when it send packet, it caused the packet validate failed.
  Jumboframes/jumboframes_jumbo_jumbo: could pass with
  dpdk-stable-16.11.4
  Jumboframes/jumboframes_normal_jumbo: same with above
  Jumboframes/jumboframes_normal_nojumbo: same with above
  dynamic_config/dynamic_config_enable_promiscuous: same with above
  pmd/checksum_checking: could pass with dpdk-stable-16.11.3, failed
  with dpdk-stable-16.11.4 and later versions
  pmd/packet_checking: same with above

This reverts commit 4bf705a7d74b0b4c1d82ad0821c43e32be15a5e5.

Signed-off-by: Luca Boccassi <bluca@debian.org>
---
 drivers/net/i40e/i40e_ethdev.c | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 01f473c2bb..3061296340 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -2578,14 +2578,13 @@ i40e_dev_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
 	/* call read registers - updates values, now write them to struct */
 	i40e_read_stats_registers(pf, hw);
 
-	stats->ipackets = ns->eth.rx_unicast +
-			ns->eth.rx_multicast +
-			ns->eth.rx_broadcast -
-			ns->eth.rx_discards -
+	stats->ipackets = pf->main_vsi->eth_stats.rx_unicast +
+			pf->main_vsi->eth_stats.rx_multicast +
+			pf->main_vsi->eth_stats.rx_broadcast -
 			pf->main_vsi->eth_stats.rx_discards;
-	stats->opackets = ns->eth.tx_unicast +
-			ns->eth.tx_multicast +
-			ns->eth.tx_broadcast;
+	stats->opackets = pf->main_vsi->eth_stats.tx_unicast +
+			pf->main_vsi->eth_stats.tx_multicast +
+			pf->main_vsi->eth_stats.tx_broadcast;
 	stats->ibytes   = ns->eth.rx_bytes;
 	stats->obytes   = ns->eth.tx_bytes;
 	stats->oerrors  = ns->eth.tx_errors +
-- 
2.18.0

^ permalink raw reply	[flat|nested] 66+ messages in thread

end of thread, other threads:[~2018-08-28 10:25 UTC | newest]

Thread overview: 66+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-24 16:07 [dpdk-stable] patch 'net/ena: check pointer before memset' has been queued to LTS release 16.11.8 luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: change memory type' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: fix GENMASK_ULL macro' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: set link speed as none' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/nfp: fix field initialization in Tx descriptor' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/bonding: fix MAC address reset' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'mbuf: fix typo in IPv6 macro comment' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'kni: fix build with gcc 8.1' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net: rename u16 to fix shadowed declaration' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix tunnel id format error for FDIR' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix tunnel type set " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ixgbe: fix mask bits register " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: fix shifts of 32-bit value' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'app/testpmd: fix VLAN TCI mask set error for FDIR' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: workaround performance degradation' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/i40e: do not reset device info data' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/pcap: fix multiple queues' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/thunderx: fix build with gcc optimization on' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/ena: fix SIGFPE with 0 Rx queue' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/qede: fix default extended VLAN offload config' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix HW Tx checksum offload check' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix Tx with multiple mbuf' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix incorrect IO address handling in Tx' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/bnxt: fix Rx ring count limitation' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'net/bonding: do not clear active slave count' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'test/crypto: fix device id when stopping port' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'maintainers: update for Mellanox PMDs' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'examples/multi_process: build l2fwd_fork app' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix multiwriter lock memory allocation' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix a multi-writer race condition' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'hash: fix key slot size accuracy' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'eal: fix return codes on thread naming failure' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'eal/linux: fix invalid syntax in interrupts' " luca.boccassi
2018-07-24 16:07 ` [dpdk-stable] patch 'ethdev: check queue stats mapping input arguments' " luca.boccassi
2018-07-27 10:17   ` [dpdk-stable] patch 'examples/ipsec-secgw: fix IPv4 checksum at Tx' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'examples/ipsec-secgw: fix bypass rule processing' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'net/i40e: fix link speed' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'net/i40e: fix check of flow director programming status' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'ethdev: fix queue statistics mapping documentation' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'net/thunderx: avoid sq door bell write on zero packet' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'examples/exception_path: fix out-of-bounds read' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'examples/l3fwd: remove useless include' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'test: fix EAL flags autotest on FreeBSD' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'test/hash: fix multiwriter with non consecutive cores' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'test/hash: fix potential memory leak' " luca.boccassi
2018-07-27 10:17     ` [dpdk-stable] patch 'doc: fix bonding command in testpmd' " luca.boccassi
2018-08-06 10:56     ` [dpdk-stable] patch 'test: fix uninitialized port configuration' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'app/testpmd: fix DCB config' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnxt: check access denied for HWRM commands' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnxt: fix RETA size' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/qede/base: fix GRC attention callback' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/qede: fix MAC address removal failure message' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/bnx2x: fix FW command timeout during stop' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/i40e: revert fix of flow director check' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'net/bonding: fix race condition' " luca.boccassi
2018-08-06 10:56       ` [dpdk-stable] patch 'eal: fix bitmap documentation' " luca.boccassi
2018-08-10  9:06       ` [dpdk-stable] patch 'hash: fix doxygen of return values' " luca.boccassi
2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix crash with null name' " luca.boccassi
2018-08-10  9:06         ` [dpdk-stable] patch 'kni: fix build on RHEL 7.5' " luca.boccassi
2018-08-10  9:06         ` [dpdk-stable] patch 'ethdev: fix a doxygen comment for port allocation' " luca.boccassi
2018-08-10  9:06         ` [dpdk-stable] patch 'mk: fix permissions when using make install' " luca.boccassi
2018-08-10  9:06         ` [dpdk-stable] patch 'maintainers: claim maintainership for ARM v7 and v8' " luca.boccassi
2018-08-28 10:25         ` [dpdk-stable] patch 'net/null: add MAC address setting fake operation' " Luca Boccassi
2018-08-28 10:25           ` [dpdk-stable] patch 'test/virtual_pmd: add MAC address setting fake op' " Luca Boccassi
2018-08-28 10:25           ` [dpdk-stable] patch 'test/bonding: assign non-zero MAC to null devices' " Luca Boccassi
2018-08-28 10:25           ` [dpdk-stable] patch 'Revert "net/i40e: fix packet count for PF"' " Luca Boccassi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).