patches for DPDK stable branches
 help / color / mirror / Atom feed
* patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6
@ 2024-06-24 23:57 luca.boccassi
  2024-06-24 23:57 ` patch 'bus/pci: fix build with musl 1.2.4 / Alpine 3.19' " luca.boccassi
                   ` (79 more replies)
  0 siblings, 80 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Christian Ehrhardt; +Cc: Luca Boccassi, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/9dc3826a4a05b41de3325af68b61cb00599f4e90

Thanks.

Luca Boccassi

---
From 9dc3826a4a05b41de3325af68b61cb00599f4e90 Mon Sep 17 00:00:00 2001
From: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Date: Tue, 28 Nov 2023 15:40:45 +0100
Subject: [PATCH] test: force IOVA mode on PPC64 without huge pages

[ upstream commit 6b07762e949036389030cf5a1a9bb8a1e4d6ee2d ]

On ppc64, without huge pages, pa would be the default but fails like:
  EAL: Cannot use IOVA as 'PA' since physical addresses are not available

On a normal system setup we'd expect an admin to set up huge pages
and for the unlikely case that they do not do that set iova=va themselves.
But the testing infrastructure does not have this conscious
admin that will do that, so fix test execution that by adjusting the
tests arguments accordingly if the conditions are met.

Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Acked-by: Luca Boccassi <bluca@debian.org>
---
 app/test/meson.build | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/app/test/meson.build b/app/test/meson.build
index 4e39c9e7cf..eee02cd8ff 100644
--- a/app/test/meson.build
+++ b/app/test/meson.build
@@ -474,15 +474,21 @@ dpdk_test = executable('dpdk-test',
              driver_install_path),
         install: true)
 
-has_hugepage = run_command(py3, 'has_hugepage.py', check: true).stdout().strip() != '0'
-message('hugepage availability: @0@'.format(has_hugepage))
-
 # some perf tests (eg: memcpy perf autotest)take very long
 # to complete, so timeout to 10 minutes
 timeout_seconds = 600
 timeout_seconds_fast = 10
 
 test_no_huge_args = ['--no-huge', '-m', '2048']
+has_hugepage = run_command(py3, 'has_hugepage.py', check: true).stdout().strip() != '0'
+message('hugepage availability: @0@'.format(has_hugepage))
+if not has_hugepage
+    if arch_subdir == 'ppc'
+        # On ppc64, without huge pages, PA would be the default but fails like:
+        # EAL: Cannot use IOVA as 'PA' since physical addresses are not available
+        test_no_huge_args += '--iova-mode=va'
+    endif
+endif
 
 foreach arg : fast_tests
     test_args = []
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.345210209 +0100
+++ 0001-test-force-IOVA-mode-on-PPC64-without-huge-pages.patch	2024-06-25 00:22:13.053182958 +0100
@@ -1 +1 @@
-From 6b07762e949036389030cf5a1a9bb8a1e4d6ee2d Mon Sep 17 00:00:00 2001
+From 9dc3826a4a05b41de3325af68b61cb00599f4e90 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6b07762e949036389030cf5a1a9bb8a1e4d6ee2d ]
+
@@ -18,2 +20,2 @@
- app/test/suites/meson.build | 7 +++++++
- 1 file changed, 7 insertions(+)
+ app/test/meson.build | 12 +++++++++---
+ 1 file changed, 9 insertions(+), 3 deletions(-)
@@ -21,5 +23,16 @@
-diff --git a/app/test/suites/meson.build b/app/test/suites/meson.build
-index 478f245a54..191702cf76 100644
---- a/app/test/suites/meson.build
-+++ b/app/test/suites/meson.build
-@@ -9,6 +9,13 @@ timeout_seconds_fast = 10
+diff --git a/app/test/meson.build b/app/test/meson.build
+index 4e39c9e7cf..eee02cd8ff 100644
+--- a/app/test/meson.build
++++ b/app/test/meson.build
+@@ -474,15 +474,21 @@ dpdk_test = executable('dpdk-test',
+              driver_install_path),
+         install: true)
+ 
+-has_hugepage = run_command(py3, 'has_hugepage.py', check: true).stdout().strip() != '0'
+-message('hugepage availability: @0@'.format(has_hugepage))
+-
+ # some perf tests (eg: memcpy perf autotest)take very long
+ # to complete, so timeout to 10 minutes
+ timeout_seconds = 600
+ timeout_seconds_fast = 10
+ 
@@ -27,2 +40,2 @@
- has_hugepage = run_command(has_hugepages_cmd, check: true).stdout().strip() != '0'
- message('hugepage availability: @0@'.format(has_hugepage))
++has_hugepage = run_command(py3, 'has_hugepage.py', check: true).stdout().strip() != '0'
++message('hugepage availability: @0@'.format(has_hugepage))
@@ -37,2 +50,2 @@
- # process source files to determine the different unit test suites
- # - fast_tests
+ foreach arg : fast_tests
+     test_args = []

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

* patch 'bus/pci: fix build with musl 1.2.4 / Alpine 3.19' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'eal/unix: support ZSTD compression for firmware' " luca.boccassi
                   ` (78 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: David Marchand
  Cc: Bruce Richardson, Patrick Robb, Thomas Monjalon, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/502049c8b3e997a10a3e77ad87d714ec2df63235

Thanks.

Luca Boccassi

---
From 502049c8b3e997a10a3e77ad87d714ec2df63235 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Mon, 29 Apr 2024 12:00:59 +0200
Subject: [PATCH] bus/pci: fix build with musl 1.2.4 / Alpine 3.19

[ upstream commit 884f83ccf74b5364430d3b21c653d5f6e359e091 ]

Following an upgrade of musl, pread64/pwrite64 wrappers are not provided
anymore. Switch to POSIX pread/pwrite.

Bugzilla ID: 1422

Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Tested-by: Patrick Robb <probb@iol.unh.edu>
Tested-by: Thomas Monjalon <thomas@monjalon.net>
---
 drivers/bus/pci/linux/pci_vfio.c | 28 ++++++++++++++--------------
 1 file changed, 14 insertions(+), 14 deletions(-)

diff --git a/drivers/bus/pci/linux/pci_vfio.c b/drivers/bus/pci/linux/pci_vfio.c
index fe83e1a04e..44c132ae8a 100644
--- a/drivers/bus/pci/linux/pci_vfio.c
+++ b/drivers/bus/pci/linux/pci_vfio.c
@@ -53,7 +53,7 @@ pci_vfio_read_config(const struct rte_intr_handle *intr_handle,
 	if (vfio_dev_fd < 0)
 		return -1;
 
-	return pread64(vfio_dev_fd, buf, len,
+	return pread(vfio_dev_fd, buf, len,
 	       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) + offs);
 }
 
@@ -66,7 +66,7 @@ pci_vfio_write_config(const struct rte_intr_handle *intr_handle,
 	if (vfio_dev_fd < 0)
 		return -1;
 
-	return pwrite64(vfio_dev_fd, buf, len,
+	return pwrite(vfio_dev_fd, buf, len,
 	       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) + offs);
 }
 
@@ -80,7 +80,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
 	uint8_t cap_id, cap_offset;
 
 	/* read PCI capability pointer from config space */
-	ret = pread64(fd, &reg, sizeof(reg),
+	ret = pread(fd, &reg, sizeof(reg),
 			VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 			PCI_CAPABILITY_LIST);
 	if (ret != sizeof(reg)) {
@@ -95,7 +95,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
 	while (cap_offset) {
 
 		/* read PCI capability ID */
-		ret = pread64(fd, &reg, sizeof(reg),
+		ret = pread(fd, &reg, sizeof(reg),
 				VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 				cap_offset);
 		if (ret != sizeof(reg)) {
@@ -109,7 +109,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
 
 		/* if we haven't reached MSI-X, check next capability */
 		if (cap_id != PCI_CAP_ID_MSIX) {
-			ret = pread64(fd, &reg, sizeof(reg),
+			ret = pread(fd, &reg, sizeof(reg),
 					VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 					cap_offset);
 			if (ret != sizeof(reg)) {
@@ -126,7 +126,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
 		/* else, read table offset */
 		else {
 			/* table offset resides in the next 4 bytes */
-			ret = pread64(fd, &reg, sizeof(reg),
+			ret = pread(fd, &reg, sizeof(reg),
 					VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 					cap_offset + 4);
 			if (ret != sizeof(reg)) {
@@ -135,7 +135,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
 				return -1;
 			}
 
-			ret = pread64(fd, &flags, sizeof(flags),
+			ret = pread(fd, &flags, sizeof(flags),
 					VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 					cap_offset + 2);
 			if (ret != sizeof(flags)) {
@@ -162,7 +162,7 @@ pci_vfio_enable_bus_memory(int dev_fd)
 	uint16_t cmd;
 	int ret;
 
-	ret = pread64(dev_fd, &cmd, sizeof(cmd),
+	ret = pread(dev_fd, &cmd, sizeof(cmd),
 		      VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 		      PCI_COMMAND);
 
@@ -175,7 +175,7 @@ pci_vfio_enable_bus_memory(int dev_fd)
 		return 0;
 
 	cmd |= PCI_COMMAND_MEMORY;
-	ret = pwrite64(dev_fd, &cmd, sizeof(cmd),
+	ret = pwrite(dev_fd, &cmd, sizeof(cmd),
 		       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 		       PCI_COMMAND);
 
@@ -194,7 +194,7 @@ pci_vfio_set_bus_master(int dev_fd, bool op)
 	uint16_t reg;
 	int ret;
 
-	ret = pread64(dev_fd, &reg, sizeof(reg),
+	ret = pread(dev_fd, &reg, sizeof(reg),
 			VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 			PCI_COMMAND);
 	if (ret != sizeof(reg)) {
@@ -208,7 +208,7 @@ pci_vfio_set_bus_master(int dev_fd, bool op)
 	else
 		reg &= ~(PCI_COMMAND_MASTER);
 
-	ret = pwrite64(dev_fd, &reg, sizeof(reg),
+	ret = pwrite(dev_fd, &reg, sizeof(reg),
 			VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
 			PCI_COMMAND);
 
@@ -464,7 +464,7 @@ pci_vfio_is_ioport_bar(int vfio_dev_fd, int bar_index)
 	uint32_t ioport_bar;
 	int ret;
 
-	ret = pread64(vfio_dev_fd, &ioport_bar, sizeof(ioport_bar),
+	ret = pread(vfio_dev_fd, &ioport_bar, sizeof(ioport_bar),
 			  VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX)
 			  + PCI_BASE_ADDRESS_0 + bar_index*4);
 	if (ret != sizeof(ioport_bar)) {
@@ -1133,7 +1133,7 @@ pci_vfio_ioport_read(struct rte_pci_ioport *p,
 	if (vfio_dev_fd < 0)
 		return;
 
-	if (pread64(vfio_dev_fd, data,
+	if (pread(vfio_dev_fd, data,
 		    len, p->base + offset) <= 0)
 		RTE_LOG(ERR, EAL,
 			"Can't read from PCI bar (%" PRIu64 ") : offset (%x)\n",
@@ -1150,7 +1150,7 @@ pci_vfio_ioport_write(struct rte_pci_ioport *p,
 	if (vfio_dev_fd < 0)
 		return;
 
-	if (pwrite64(vfio_dev_fd, data,
+	if (pwrite(vfio_dev_fd, data,
 		     len, p->base + offset) <= 0)
 		RTE_LOG(ERR, EAL,
 			"Can't write to PCI bar (%" PRIu64 ") : offset (%x)\n",
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.380509740 +0100
+++ 0002-bus-pci-fix-build-with-musl-1.2.4-Alpine-3.19.patch	2024-06-25 00:22:13.057183040 +0100
@@ -1 +1 @@
-From 884f83ccf74b5364430d3b21c653d5f6e359e091 Mon Sep 17 00:00:00 2001
+From 502049c8b3e997a10a3e77ad87d714ec2df63235 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 884f83ccf74b5364430d3b21c653d5f6e359e091 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -17,2 +18,2 @@
- drivers/bus/pci/linux/pci_vfio.c | 18 +++++++++---------
- 1 file changed, 9 insertions(+), 9 deletions(-)
+ drivers/bus/pci/linux/pci_vfio.c | 28 ++++++++++++++--------------
+ 1 file changed, 14 insertions(+), 14 deletions(-)
@@ -21 +22 @@
-index 87c16e6603..05b03a9667 100644
+index fe83e1a04e..44c132ae8a 100644
@@ -24,2 +25,2 @@
-@@ -80,7 +80,7 @@ pci_vfio_read_config(const struct rte_pci_device *dev,
- 	if ((uint64_t)len + offs > size)
+@@ -53,7 +53,7 @@ pci_vfio_read_config(const struct rte_intr_handle *intr_handle,
+ 	if (vfio_dev_fd < 0)
@@ -28,2 +29,3 @@
--	return pread64(fd, buf, len, offset + offs);
-+	return pread(fd, buf, len, offset + offs);
+-	return pread64(vfio_dev_fd, buf, len,
++	return pread(vfio_dev_fd, buf, len,
+ 	       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) + offs);
@@ -32,3 +34,2 @@
- int
-@@ -101,7 +101,7 @@ pci_vfio_write_config(const struct rte_pci_device *dev,
- 	if ((uint64_t)len + offs > size)
+@@ -66,7 +66,7 @@ pci_vfio_write_config(const struct rte_intr_handle *intr_handle,
+ 	if (vfio_dev_fd < 0)
@@ -37,2 +38,3 @@
--	return pwrite64(fd, buf, len, offset + offs);
-+	return pwrite(fd, buf, len, offset + offs);
+-	return pwrite64(vfio_dev_fd, buf, len,
++	return pwrite(vfio_dev_fd, buf, len,
+ 	       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) + offs);
@@ -41,4 +43,2 @@
- /* get PCI BAR number where MSI-X interrupts are */
-@@ -155,7 +155,7 @@ pci_vfio_enable_bus_memory(struct rte_pci_device *dev, int dev_fd)
- 		return -1;
- 	}
+@@ -80,7 +80,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
+ 	uint8_t cap_id, cap_offset;
@@ -46,2 +46,50 @@
--	ret = pread64(dev_fd, &cmd, sizeof(cmd), offset + RTE_PCI_COMMAND);
-+	ret = pread(dev_fd, &cmd, sizeof(cmd), offset + RTE_PCI_COMMAND);
+ 	/* read PCI capability pointer from config space */
+-	ret = pread64(fd, &reg, sizeof(reg),
++	ret = pread(fd, &reg, sizeof(reg),
+ 			VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 			PCI_CAPABILITY_LIST);
+ 	if (ret != sizeof(reg)) {
+@@ -95,7 +95,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
+ 	while (cap_offset) {
+ 
+ 		/* read PCI capability ID */
+-		ret = pread64(fd, &reg, sizeof(reg),
++		ret = pread(fd, &reg, sizeof(reg),
+ 				VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 				cap_offset);
+ 		if (ret != sizeof(reg)) {
+@@ -109,7 +109,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
+ 
+ 		/* if we haven't reached MSI-X, check next capability */
+ 		if (cap_id != PCI_CAP_ID_MSIX) {
+-			ret = pread64(fd, &reg, sizeof(reg),
++			ret = pread(fd, &reg, sizeof(reg),
+ 					VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 					cap_offset);
+ 			if (ret != sizeof(reg)) {
+@@ -126,7 +126,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
+ 		/* else, read table offset */
+ 		else {
+ 			/* table offset resides in the next 4 bytes */
+-			ret = pread64(fd, &reg, sizeof(reg),
++			ret = pread(fd, &reg, sizeof(reg),
+ 					VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 					cap_offset + 4);
+ 			if (ret != sizeof(reg)) {
+@@ -135,7 +135,7 @@ pci_vfio_get_msix_bar(int fd, struct pci_msix_table *msix_table)
+ 				return -1;
+ 			}
+ 
+-			ret = pread64(fd, &flags, sizeof(flags),
++			ret = pread(fd, &flags, sizeof(flags),
+ 					VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 					cap_offset + 2);
+ 			if (ret != sizeof(flags)) {
+@@ -162,7 +162,7 @@ pci_vfio_enable_bus_memory(int dev_fd)
+ 	uint16_t cmd;
+ 	int ret;
+ 
+-	ret = pread64(dev_fd, &cmd, sizeof(cmd),
++	ret = pread(dev_fd, &cmd, sizeof(cmd),
+ 		      VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 		      PCI_COMMAND);
@@ -49,3 +97 @@
- 	if (ret != sizeof(cmd)) {
- 		RTE_LOG(ERR, EAL, "Cannot read command from PCI config space!\n");
-@@ -166,7 +166,7 @@ pci_vfio_enable_bus_memory(struct rte_pci_device *dev, int dev_fd)
+@@ -175,7 +175,7 @@ pci_vfio_enable_bus_memory(int dev_fd)
@@ -54,9 +100,27 @@
- 	cmd |= RTE_PCI_COMMAND_MEMORY;
--	ret = pwrite64(dev_fd, &cmd, sizeof(cmd), offset + RTE_PCI_COMMAND);
-+	ret = pwrite(dev_fd, &cmd, sizeof(cmd), offset + RTE_PCI_COMMAND);
- 
- 	if (ret != sizeof(cmd)) {
- 		RTE_LOG(ERR, EAL, "Cannot write command to PCI config space!\n");
-@@ -425,7 +425,7 @@ pci_vfio_is_ioport_bar(const struct rte_pci_device *dev, int vfio_dev_fd,
- 		return -1;
- 	}
+ 	cmd |= PCI_COMMAND_MEMORY;
+-	ret = pwrite64(dev_fd, &cmd, sizeof(cmd),
++	ret = pwrite(dev_fd, &cmd, sizeof(cmd),
+ 		       VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 		       PCI_COMMAND);
+ 
+@@ -194,7 +194,7 @@ pci_vfio_set_bus_master(int dev_fd, bool op)
+ 	uint16_t reg;
+ 	int ret;
+ 
+-	ret = pread64(dev_fd, &reg, sizeof(reg),
++	ret = pread(dev_fd, &reg, sizeof(reg),
+ 			VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 			PCI_COMMAND);
+ 	if (ret != sizeof(reg)) {
+@@ -208,7 +208,7 @@ pci_vfio_set_bus_master(int dev_fd, bool op)
+ 	else
+ 		reg &= ~(PCI_COMMAND_MASTER);
+ 
+-	ret = pwrite64(dev_fd, &reg, sizeof(reg),
++	ret = pwrite(dev_fd, &reg, sizeof(reg),
+ 			VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX) +
+ 			PCI_COMMAND);
+ 
+@@ -464,7 +464,7 @@ pci_vfio_is_ioport_bar(int vfio_dev_fd, int bar_index)
+ 	uint32_t ioport_bar;
+ 	int ret;
@@ -66 +130,2 @@
- 			  offset + RTE_PCI_BASE_ADDRESS_0 + bar_index * 4);
+ 			  VFIO_GET_REGION_ADDR(VFIO_PCI_CONFIG_REGION_INDEX)
+ 			  + PCI_BASE_ADDRESS_0 + bar_index*4);
@@ -68,2 +133 @@
- 		RTE_LOG(ERR, EAL, "Cannot read command (%x) from config space!\n",
-@@ -1276,7 +1276,7 @@ pci_vfio_ioport_read(struct rte_pci_ioport *p,
+@@ -1133,7 +1133,7 @@ pci_vfio_ioport_read(struct rte_pci_ioport *p,
@@ -78 +142 @@
-@@ -1293,7 +1293,7 @@ pci_vfio_ioport_write(struct rte_pci_ioport *p,
+@@ -1150,7 +1150,7 @@ pci_vfio_ioport_write(struct rte_pci_ioport *p,
@@ -87,18 +150,0 @@
-@@ -1324,7 +1324,7 @@ pci_vfio_mmio_read(const struct rte_pci_device *dev, int bar,
- 	if ((uint64_t)len + offs > size)
- 		return -1;
- 
--	return pread64(fd, buf, len, offset + offs);
-+	return pread(fd, buf, len, offset + offs);
- }
- 
- int
-@@ -1344,7 +1344,7 @@ pci_vfio_mmio_write(const struct rte_pci_device *dev, int bar,
- 	if ((uint64_t)len + offs > size)
- 		return -1;
- 
--	return pwrite64(fd, buf, len, offset + offs);
-+	return pwrite(fd, buf, len, offset + offs);
- }
- 
- int

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

* patch 'eal/unix: support ZSTD compression for firmware' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
  2024-06-24 23:57 ` patch 'bus/pci: fix build with musl 1.2.4 / Alpine 3.19' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'pcapng: add memcpy check' " luca.boccassi
                   ` (77 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: David Marchand; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/73c189a0674d34b631241c3757e0a1ec13809c00

Thanks.

Luca Boccassi

---
From 73c189a0674d34b631241c3757e0a1ec13809c00 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Tue, 7 May 2024 13:01:53 +0200
Subject: [PATCH] eal/unix: support ZSTD compression for firmware

[ upstream commit 6f80df8cb0f889203d7cd27766abcc6ebc720e33 ]

Ubuntu 24.04 started to compress firmware files with ZSTD compression.

Bugzilla ID: 1437

Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/eal/unix/eal_firmware.c | 23 +++++++++++++++++------
 1 file changed, 17 insertions(+), 6 deletions(-)

diff --git a/lib/eal/unix/eal_firmware.c b/lib/eal/unix/eal_firmware.c
index 1a7cf8e7b7..9fc2f7763a 100644
--- a/lib/eal/unix/eal_firmware.c
+++ b/lib/eal/unix/eal_firmware.c
@@ -15,6 +15,8 @@
 
 #include "eal_firmware.h"
 
+static const char * const compression_suffixes[] = { "xz", "zst" };
+
 #ifdef RTE_HAS_LIBARCHIVE
 
 struct firmware_read_ctx {
@@ -36,7 +38,11 @@ firmware_open(struct firmware_read_ctx *ctx, const char *name, size_t blocksize)
 
 	err = archive_read_support_filter_xz(ctx->a);
 	if (err != ARCHIVE_OK && err != ARCHIVE_WARN)
-		goto error;
+		RTE_LOG(DEBUG, EAL, "could not initialise libarchive for xz compression\n");
+
+	err = archive_read_support_filter_zstd(ctx->a);
+	if (err != ARCHIVE_OK && err != ARCHIVE_WARN)
+		RTE_LOG(DEBUG, EAL, "could not initialise libarchive for zstd compression\n");
 
 	if (archive_read_open_filename(ctx->a, name, blocksize) != ARCHIVE_OK)
 		goto error;
@@ -147,16 +153,21 @@ rte_firmware_read(const char *name, void **buf, size_t *bufsz)
 
 	ret = firmware_read(name, buf, bufsz);
 	if (ret < 0) {
-		snprintf(path, sizeof(path), "%s.xz", name);
-		path[PATH_MAX - 1] = '\0';
+		unsigned int i;
+
+		for (i = 0; i < RTE_DIM(compression_suffixes); i++) {
+			snprintf(path, sizeof(path), "%s.%s", name, compression_suffixes[i]);
+			path[PATH_MAX - 1] = '\0';
+			if (access(path, F_OK) != 0)
+				continue;
 #ifndef RTE_HAS_LIBARCHIVE
-		if (access(path, F_OK) == 0) {
 			RTE_LOG(WARNING, EAL, "libarchive not linked, %s cannot be decompressed\n",
 				path);
-		}
 #else
-		ret = firmware_read(path, buf, bufsz);
+			ret = firmware_read(path, buf, bufsz);
 #endif
+			break;
+		}
 	}
 	return ret;
 }
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.416458958 +0100
+++ 0003-eal-unix-support-ZSTD-compression-for-firmware.patch	2024-06-25 00:22:13.061183121 +0100
@@ -1 +1 @@
-From 6f80df8cb0f889203d7cd27766abcc6ebc720e33 Mon Sep 17 00:00:00 2001
+From 73c189a0674d34b631241c3757e0a1ec13809c00 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6f80df8cb0f889203d7cd27766abcc6ebc720e33 ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
-index 1d47e879c8..0d69b1e3f0 100644
+index 1a7cf8e7b7..9fc2f7763a 100644
@@ -21 +22,2 @@
-@@ -16,6 +16,8 @@
+@@ -15,6 +15,8 @@
+ 
@@ -23 +24,0 @@
- #include "eal_private.h"
@@ -30 +31 @@
-@@ -37,7 +39,11 @@ firmware_open(struct firmware_read_ctx *ctx, const char *name, size_t blocksize)
+@@ -36,7 +38,11 @@ firmware_open(struct firmware_read_ctx *ctx, const char *name, size_t blocksize)
@@ -35 +36 @@
-+		EAL_LOG(DEBUG, "could not initialise libarchive for xz compression");
++		RTE_LOG(DEBUG, EAL, "could not initialise libarchive for xz compression\n");
@@ -39 +40 @@
-+		EAL_LOG(DEBUG, "could not initialise libarchive for zstd compression");
++		RTE_LOG(DEBUG, EAL, "could not initialise libarchive for zstd compression\n");
@@ -43 +44 @@
-@@ -148,16 +154,21 @@ rte_firmware_read(const char *name, void **buf, size_t *bufsz)
+@@ -147,16 +153,21 @@ rte_firmware_read(const char *name, void **buf, size_t *bufsz)
@@ -58 +59 @@
- 			EAL_LOG(WARNING, "libarchive not linked, %s cannot be decompressed",
+ 			RTE_LOG(WARNING, EAL, "libarchive not linked, %s cannot be decompressed\n",

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

* patch 'pcapng: add memcpy check' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
  2024-06-24 23:57 ` patch 'bus/pci: fix build with musl 1.2.4 / Alpine 3.19' " luca.boccassi
  2024-06-24 23:57 ` patch 'eal/unix: support ZSTD compression for firmware' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/virtio-user: " luca.boccassi
                   ` (76 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/461739eed3b49b2106ec8c8074f04daaa00d4a95

Thanks.

Luca Boccassi

---
From 461739eed3b49b2106ec8c8074f04daaa00d4a95 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Mon, 20 May 2024 18:01:03 -0700
Subject: [PATCH] pcapng: add memcpy check

[ upstream commit 06f69f8fdbd218ed7a7d664ee49bd27ee1641cdd ]

When adding option with no data, the rte_pcapng_add_option would
call memcpy with src of NULL and size of zero. This generates a
warning if fortify is enabled.

Bugzilla ID: 1446
Fixes: 8d23ce8f5ee9 ("pcapng: add new library for writing pcapng files")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/pcapng/rte_pcapng.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/pcapng/rte_pcapng.c b/lib/pcapng/rte_pcapng.c
index 80d08e1a3b..d8fd36799b 100644
--- a/lib/pcapng/rte_pcapng.c
+++ b/lib/pcapng/rte_pcapng.c
@@ -110,7 +110,8 @@ pcapng_add_option(struct pcapng_option *popt, uint16_t code,
 {
 	popt->code = code;
 	popt->length = len;
-	memcpy(popt->data, data, len);
+	if (len > 0)
+		memcpy(popt->data, data, len);
 
 	return (struct pcapng_option *)((uint8_t *)popt + pcapng_optlen(len));
 }
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.451616314 +0100
+++ 0004-pcapng-add-memcpy-check.patch	2024-06-25 00:22:13.061183121 +0100
@@ -1 +1 @@
-From 06f69f8fdbd218ed7a7d664ee49bd27ee1641cdd Mon Sep 17 00:00:00 2001
+From 461739eed3b49b2106ec8c8074f04daaa00d4a95 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 06f69f8fdbd218ed7a7d664ee49bd27ee1641cdd ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index f74ec939a9..7254defce7 100644
+index 80d08e1a3b..d8fd36799b 100644
@@ -23 +24 @@
-@@ -128,7 +128,8 @@ pcapng_add_option(struct pcapng_option *popt, uint16_t code,
+@@ -110,7 +110,8 @@ pcapng_add_option(struct pcapng_option *popt, uint16_t code,

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

* patch 'net/virtio-user: add memcpy check' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (2 preceding siblings ...)
  2024-06-24 23:57 ` patch 'pcapng: add memcpy check' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'eal/windows: install sched.h file' " luca.boccassi
                   ` (75 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/7cc8737e523e7d68601dda1fe40aa3205cb0a8b9

Thanks.

Luca Boccassi

---
From 7cc8737e523e7d68601dda1fe40aa3205cb0a8b9 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Mon, 20 May 2024 18:01:04 -0700
Subject: [PATCH] net/virtio-user: add memcpy check

[ upstream commit 0ad961387e94a9ccfc1484a1d742d6f79eda9cd9 ]

If fortify is enabled, it will generate a warning if memcpy
src is NULL even if size is zero. This happens if the MP message
sync is called with no file descriptors.

Bugzilla ID: 1446
Fixes: 6a84c37e3975 ("net/virtio-user: add vhost-user adapter layer")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/virtio/virtio_user/vhost_user.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/virtio/virtio_user/vhost_user.c b/drivers/net/virtio/virtio_user/vhost_user.c
index 3c05ac9cc0..c10252506b 100644
--- a/drivers/net/virtio/virtio_user/vhost_user.c
+++ b/drivers/net/virtio/virtio_user/vhost_user.c
@@ -128,7 +128,8 @@ vhost_user_write(int fd, struct vhost_user_msg *msg, int *fds, int fd_num)
 	cmsg->cmsg_len = CMSG_LEN(fd_size);
 	cmsg->cmsg_level = SOL_SOCKET;
 	cmsg->cmsg_type = SCM_RIGHTS;
-	memcpy(CMSG_DATA(cmsg), fds, fd_size);
+	if (fd_size > 0)
+		memcpy(CMSG_DATA(cmsg), fds, fd_size);
 
 	do {
 		r = sendmsg(fd, &msgh, 0);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.587408350 +0100
+++ 0005-net-virtio-user-add-memcpy-check.patch	2024-06-25 00:22:13.065183203 +0100
@@ -1 +1 @@
-From 0ad961387e94a9ccfc1484a1d742d6f79eda9cd9 Mon Sep 17 00:00:00 2001
+From 7cc8737e523e7d68601dda1fe40aa3205cb0a8b9 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0ad961387e94a9ccfc1484a1d742d6f79eda9cd9 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org

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

* patch 'eal/windows: install sched.h file' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (3 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/virtio-user: " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'latencystats: fix literal float suffix' " luca.boccassi
                   ` (74 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Tyler Retzlaff; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/9957ef4a31aa489fc58c0a6c0ce79f73a7f62379

Thanks.

Luca Boccassi

---
From 9957ef4a31aa489fc58c0a6c0ce79f73a7f62379 Mon Sep 17 00:00:00 2001
From: Tyler Retzlaff <roretzla@linux.microsoft.com>
Date: Tue, 12 Mar 2024 10:54:37 -0700
Subject: [PATCH] eal/windows: install sched.h file

[ upstream commit ad645a9317bc93c7e4921afa7bf33e1415b531cd ]

rte_os.h includes sched.h so install sched.h to allow DPDK installed to
DESTDIR to be usable.

Fixes: e8428a9d89f1 ("eal/windows: add some basic functions and macros")

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/eal/windows/include/meson.build | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/eal/windows/include/meson.build b/lib/eal/windows/include/meson.build
index 5fb1962ac7..e985a77d58 100644
--- a/lib/eal/windows/include/meson.build
+++ b/lib/eal/windows/include/meson.build
@@ -6,4 +6,5 @@ includes += include_directories('.')
 headers += files(
         'rte_os.h',
         'rte_windows.h',
+        'sched.h',
 )
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.631020404 +0100
+++ 0006-eal-windows-install-sched.h-file.patch	2024-06-25 00:22:13.065183203 +0100
@@ -1 +1 @@
-From ad645a9317bc93c7e4921afa7bf33e1415b531cd Mon Sep 17 00:00:00 2001
+From 9957ef4a31aa489fc58c0a6c0ce79f73a7f62379 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ad645a9317bc93c7e4921afa7bf33e1415b531cd ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org

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

* patch 'latencystats: fix literal float suffix' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (4 preceding siblings ...)
  2024-06-24 23:57 ` patch 'eal/windows: install sched.h file' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/nfp: fix representor port queue release' " luca.boccassi
                   ` (73 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Tyler Retzlaff; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/0257b6327a34cb112afbc349468a275aa839875d

Thanks.

Luca Boccassi

---
From 0257b6327a34cb112afbc349468a275aa839875d Mon Sep 17 00:00:00 2001
From: Tyler Retzlaff <roretzla@linux.microsoft.com>
Date: Mon, 15 Apr 2024 14:32:26 -0700
Subject: [PATCH] latencystats: fix literal float suffix

[ upstream commit 792cb874db647e31183ab6680922cd293dd5bfa6 ]

Add missing f suffix to floating point literal to avoid warning about
truncation from double to float.

Fixes: 5cd3cac9ed22 ("latency: added new library for latency stats")

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/latencystats/rte_latencystats.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/latencystats/rte_latencystats.c b/lib/latencystats/rte_latencystats.c
index 8985a377db..e47eac2cf8 100644
--- a/lib/latencystats/rte_latencystats.c
+++ b/lib/latencystats/rte_latencystats.c
@@ -164,7 +164,7 @@ calc_latency(uint16_t pid __rte_unused,
 	 * a constant smoothing factor between 0 and 1. The value
 	 * is used below for measuring average latency.
 	 */
-	const float alpha = 0.2;
+	const float alpha = 0.2f;
 
 	now = rte_rdtsc();
 	for (i = 0; i < nb_pkts; i++) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.754169540 +0100
+++ 0007-latencystats-fix-literal-float-suffix.patch	2024-06-25 00:22:13.065183203 +0100
@@ -1 +1 @@
-From 792cb874db647e31183ab6680922cd293dd5bfa6 Mon Sep 17 00:00:00 2001
+From 0257b6327a34cb112afbc349468a275aa839875d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 792cb874db647e31183ab6680922cd293dd5bfa6 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
-index 4ea9b0d75b..cae4b50878 100644
+index 8985a377db..e47eac2cf8 100644
@@ -21 +22 @@
-@@ -166,7 +166,7 @@ calc_latency(uint16_t pid __rte_unused,
+@@ -164,7 +164,7 @@ calc_latency(uint16_t pid __rte_unused,

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

* patch 'net/nfp: fix representor port queue release' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (5 preceding siblings ...)
  2024-06-24 23:57 ` patch 'latencystats: fix literal float suffix' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/bonding: fix failover time of LACP with mode 4' " luca.boccassi
                   ` (72 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Long Wu; +Cc: Chaoyong He, Peng Zhang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/541c30f3d18029161a14c356ba88a5c8d2d16b82

Thanks.

Luca Boccassi

---
From 541c30f3d18029161a14c356ba88a5c8d2d16b82 Mon Sep 17 00:00:00 2001
From: Long Wu <long.wu@corigine.com>
Date: Tue, 19 Mar 2024 15:07:54 +0800
Subject: [PATCH] net/nfp: fix representor port queue release

[ upstream commit 57f62be098be4c95964691183504c77e31797a42 ]

The PF representor port's queue is different from the VF/physical
representor port. So the release process in close port should
be different too.

Fixes: a256a1227dbe ("net/nfp: fix resource leak for exit of flower firmware")

Signed-off-by: Long Wu <long.wu@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
Reviewed-by: Peng Zhang <peng.zhang@corigine.com>
---
 .../net/nfp/flower/nfp_flower_representor.c   | 69 ++++++++++++++-----
 1 file changed, 50 insertions(+), 19 deletions(-)

diff --git a/drivers/net/nfp/flower/nfp_flower_representor.c b/drivers/net/nfp/flower/nfp_flower_representor.c
index 4b8b02321c..090c828c18 100644
--- a/drivers/net/nfp/flower/nfp_flower_representor.c
+++ b/drivers/net/nfp/flower/nfp_flower_representor.c
@@ -524,6 +524,54 @@ nfp_flower_repr_tx_burst(void *tx_queue,
 	return sent;
 }
 
+static void
+nfp_flower_repr_free_queue(struct nfp_flower_representor *repr)
+{
+	uint16_t i;
+	struct rte_eth_dev *eth_dev = repr->eth_dev;
+
+	for (i = 0; i < eth_dev->data->nb_tx_queues; i++)
+		rte_free(eth_dev->data->tx_queues[i]);
+
+	for (i = 0; i < eth_dev->data->nb_rx_queues; i++)
+		rte_free(eth_dev->data->rx_queues[i]);
+}
+
+static void
+nfp_flower_pf_repr_close_queue(struct nfp_flower_representor *repr)
+{
+	struct rte_eth_dev *eth_dev = repr->eth_dev;
+
+	/*
+	 * We assume that the DPDK application is stopping all the
+	 * threads/queues before calling the device close function.
+	 */
+	nfp_net_disable_queues(eth_dev);
+
+	/* Clear queues */
+	nfp_net_close_tx_queue(eth_dev);
+	nfp_net_close_rx_queue(eth_dev);
+}
+
+static void
+nfp_flower_repr_close_queue(struct nfp_flower_representor *repr)
+{
+	switch (repr->repr_type) {
+	case NFP_REPR_TYPE_PHYS_PORT:
+		nfp_flower_repr_free_queue(repr);
+		break;
+	case NFP_REPR_TYPE_PF:
+		nfp_flower_pf_repr_close_queue(repr);
+		break;
+	case NFP_REPR_TYPE_VF:
+		nfp_flower_repr_free_queue(repr);
+		break;
+	default:
+		PMD_DRV_LOG(ERR, "Unsupported repr port type.");
+		break;
+	}
+}
+
 static int
 nfp_flower_repr_uninit(struct rte_eth_dev *eth_dev)
 {
@@ -581,8 +629,6 @@ nfp_flower_repr_dev_close(struct rte_eth_dev *dev)
 	uint16_t i;
 	struct nfp_net_hw *hw;
 	struct nfp_pf_dev *pf_dev;
-	struct nfp_net_txq *this_tx_q;
-	struct nfp_net_rxq *this_rx_q;
 	struct nfp_flower_representor *repr;
 	struct nfp_app_fw_flower *app_fw_flower;
 
@@ -594,26 +640,11 @@ nfp_flower_repr_dev_close(struct rte_eth_dev *dev)
 	hw = app_fw_flower->pf_hw;
 	pf_dev = hw->pf_dev;
 
-	/*
-	 * We assume that the DPDK application is stopping all the
-	 * threads/queues before calling the device close function.
-	 */
-	nfp_net_disable_queues(dev);
-
-	/* Clear queues */
-	for (i = 0; i < dev->data->nb_tx_queues; i++) {
-		this_tx_q = dev->data->tx_queues[i];
-		nfp_net_reset_tx_queue(this_tx_q);
-	}
-
-	for (i = 0; i < dev->data->nb_rx_queues; i++) {
-		this_rx_q = dev->data->rx_queues[i];
-		nfp_net_reset_rx_queue(this_rx_q);
-	}
-
 	if (pf_dev->app_fw_id != NFP_APP_FW_FLOWER_NIC)
 		return -EINVAL;
 
+	nfp_flower_repr_close_queue(repr);
+
 	nfp_flower_repr_free(repr, repr->repr_type);
 
 	for (i = 0; i < MAX_FLOWER_VFS; i++) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:13.882323625 +0100
+++ 0008-net-nfp-fix-representor-port-queue-release.patch	2024-06-25 00:22:13.069183284 +0100
@@ -1 +1 @@
-From 57f62be098be4c95964691183504c77e31797a42 Mon Sep 17 00:00:00 2001
+From 541c30f3d18029161a14c356ba88a5c8d2d16b82 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 57f62be098be4c95964691183504c77e31797a42 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index b2c55879ca..d4c3c30682 100644
+index 4b8b02321c..090c828c18 100644
@@ -24 +25 @@
-@@ -305,6 +305,54 @@ nfp_flower_repr_tx_burst(void *tx_queue,
+@@ -524,6 +524,54 @@ nfp_flower_repr_tx_burst(void *tx_queue,
@@ -79 +80 @@
-@@ -362,8 +410,6 @@ nfp_flower_repr_dev_close(struct rte_eth_dev *dev)
+@@ -581,8 +629,6 @@ nfp_flower_repr_dev_close(struct rte_eth_dev *dev)
@@ -88 +89 @@
-@@ -375,26 +421,11 @@ nfp_flower_repr_dev_close(struct rte_eth_dev *dev)
+@@ -594,26 +640,11 @@ nfp_flower_repr_dev_close(struct rte_eth_dev *dev)

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

* patch 'net/bonding: fix failover time of LACP with mode 4' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (6 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/nfp: fix representor port queue release' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/hns3: fix offload flag of IEEE 1588' " luca.boccassi
                   ` (71 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Gaoxiang Liu; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/6282bde96dc3f9d60c67eaaf4a340a20c3347829

Thanks.

Luca Boccassi

---
From 6282bde96dc3f9d60c67eaaf4a340a20c3347829 Mon Sep 17 00:00:00 2001
From: Gaoxiang Liu <liugaoxiang@huawei.com>
Date: Mon, 6 Jun 2022 22:34:45 +0800
Subject: [PATCH] net/bonding: fix failover time of LACP with mode 4

[ upstream commit a78a1ed8ba6ae7666d13fee1895badb8eb2abf5f ]

When the primary port of bond member with bond mode 4 linked down,
the system id of the other member ports changed.
It may cause some switches to renegotiate, and the process takes a few
seconds. It is not acceptable for any Telcos.
We need sub-second switch-over time like in Linux.

Set the MAC of the bond port to the member port's system to solve the
problem.

Bugzilla ID: 551
Fixes: 46fb43683679 ("bond: add mode 4")

Signed-off-by: Gaoxiang Liu <liugaoxiang@huawei.com>
---
 drivers/net/bonding/rte_eth_bond_8023ad.c | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c b/drivers/net/bonding/rte_eth_bond_8023ad.c
index 928dfca7af..2a81ab5bf3 100644
--- a/drivers/net/bonding/rte_eth_bond_8023ad.c
+++ b/drivers/net/bonding/rte_eth_bond_8023ad.c
@@ -865,7 +865,6 @@ bond_mode_8023ad_periodic_cb(void *arg)
 	struct bond_dev_private *internals = bond_dev->data->dev_private;
 	struct port *port;
 	struct rte_eth_link link_info;
-	struct rte_ether_addr slave_addr;
 	struct rte_mbuf *lacp_pkt = NULL;
 	uint16_t slave_id;
 	uint16_t i;
@@ -892,7 +891,6 @@ bond_mode_8023ad_periodic_cb(void *arg)
 			key = 0;
 		}
 
-		rte_eth_macaddr_get(slave_id, &slave_addr);
 		port = &bond_mode_8023ad_ports[slave_id];
 
 		key = rte_cpu_to_be_16(key);
@@ -904,8 +902,8 @@ bond_mode_8023ad_periodic_cb(void *arg)
 			SM_FLAG_SET(port, NTT);
 		}
 
-		if (!rte_is_same_ether_addr(&port->actor.system, &slave_addr)) {
-			rte_ether_addr_copy(&slave_addr, &port->actor.system);
+		if (!rte_is_same_ether_addr(&internals->mode4.mac_addr, &port->actor.system)) {
+			rte_ether_addr_copy(&internals->mode4.mac_addr, &port->actor.system);
 			if (port->aggregator_port_id == slave_id)
 				SM_FLAG_SET(port, NTT);
 		}
@@ -1171,21 +1169,20 @@ void
 bond_mode_8023ad_mac_address_update(struct rte_eth_dev *bond_dev)
 {
 	struct bond_dev_private *internals = bond_dev->data->dev_private;
-	struct rte_ether_addr slave_addr;
 	struct port *slave, *agg_slave;
 	uint16_t slave_id, i, j;
 
 	bond_mode_8023ad_stop(bond_dev);
 
+	rte_eth_macaddr_get(internals->port_id, &internals->mode4.mac_addr);
 	for (i = 0; i < internals->active_slave_count; i++) {
 		slave_id = internals->active_slaves[i];
 		slave = &bond_mode_8023ad_ports[slave_id];
-		rte_eth_macaddr_get(slave_id, &slave_addr);
 
-		if (rte_is_same_ether_addr(&slave_addr, &slave->actor.system))
+		if (rte_is_same_ether_addr(&internals->mode4.mac_addr, &slave->actor.system))
 			continue;
 
-		rte_ether_addr_copy(&slave_addr, &slave->actor.system);
+		rte_ether_addr_copy(&internals->mode4.mac_addr, &slave->actor.system);
 		/* Do nothing if this port is not an aggregator. In other case
 		 * Set NTT flag on every port that use this aggregator. */
 		if (slave->aggregator_port_id != slave_id)
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.010325082 +0100
+++ 0009-net-bonding-fix-failover-time-of-LACP-with-mode-4.patch	2024-06-25 00:22:13.073183366 +0100
@@ -1 +1 @@
-From a78a1ed8ba6ae7666d13fee1895badb8eb2abf5f Mon Sep 17 00:00:00 2001
+From 6282bde96dc3f9d60c67eaaf4a340a20c3347829 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a78a1ed8ba6ae7666d13fee1895badb8eb2abf5f ]
+
@@ -17 +18,0 @@
-Cc: stable@dpdk.org
@@ -25 +26 @@
-index 79f1b3f1a0..06c21ebe6d 100644
+index 928dfca7af..2a81ab5bf3 100644
@@ -32 +33 @@
--	struct rte_ether_addr member_addr;
+-	struct rte_ether_addr slave_addr;
@@ -34 +35 @@
- 	uint16_t member_id;
+ 	uint16_t slave_id;
@@ -40,2 +41,2 @@
--		rte_eth_macaddr_get(member_id, &member_addr);
- 		port = &bond_mode_8023ad_ports[member_id];
+-		rte_eth_macaddr_get(slave_id, &slave_addr);
+ 		port = &bond_mode_8023ad_ports[slave_id];
@@ -48,2 +49,2 @@
--		if (!rte_is_same_ether_addr(&port->actor.system, &member_addr)) {
--			rte_ether_addr_copy(&member_addr, &port->actor.system);
+-		if (!rte_is_same_ether_addr(&port->actor.system, &slave_addr)) {
+-			rte_ether_addr_copy(&slave_addr, &port->actor.system);
@@ -52 +53 @@
- 			if (port->aggregator_port_id == member_id)
+ 			if (port->aggregator_port_id == slave_id)
@@ -55 +56 @@
-@@ -1173,21 +1171,20 @@ void
+@@ -1171,21 +1169,20 @@ void
@@ -59,3 +60,3 @@
--	struct rte_ether_addr member_addr;
- 	struct port *member, *agg_member;
- 	uint16_t member_id, i, j;
+-	struct rte_ether_addr slave_addr;
+ 	struct port *slave, *agg_slave;
+ 	uint16_t slave_id, i, j;
@@ -66,4 +67,4 @@
- 	for (i = 0; i < internals->active_member_count; i++) {
- 		member_id = internals->active_members[i];
- 		member = &bond_mode_8023ad_ports[member_id];
--		rte_eth_macaddr_get(member_id, &member_addr);
+ 	for (i = 0; i < internals->active_slave_count; i++) {
+ 		slave_id = internals->active_slaves[i];
+ 		slave = &bond_mode_8023ad_ports[slave_id];
+-		rte_eth_macaddr_get(slave_id, &slave_addr);
@@ -71,2 +72,2 @@
--		if (rte_is_same_ether_addr(&member_addr, &member->actor.system))
-+		if (rte_is_same_ether_addr(&internals->mode4.mac_addr, &member->actor.system))
+-		if (rte_is_same_ether_addr(&slave_addr, &slave->actor.system))
++		if (rte_is_same_ether_addr(&internals->mode4.mac_addr, &slave->actor.system))
@@ -75,2 +76,2 @@
--		rte_ether_addr_copy(&member_addr, &member->actor.system);
-+		rte_ether_addr_copy(&internals->mode4.mac_addr, &member->actor.system);
+-		rte_ether_addr_copy(&slave_addr, &slave->actor.system);
++		rte_ether_addr_copy(&internals->mode4.mac_addr, &slave->actor.system);
@@ -79 +80 @@
- 		if (member->aggregator_port_id != member_id)
+ 		if (slave->aggregator_port_id != slave_id)

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

* patch 'net/hns3: fix offload flag of IEEE 1588' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (7 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/bonding: fix failover time of LACP with mode 4' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/hns3: fix Rx timestamp flag' " luca.boccassi
                   ` (70 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Dengdui Huang; +Cc: Jie Hai, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/419ac23f30616787391300ed67909f9b1cad9b32

Thanks.

Luca Boccassi

---
From 419ac23f30616787391300ed67909f9b1cad9b32 Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Wed, 3 Apr 2024 18:16:19 +0800
Subject: [PATCH] net/hns3: fix offload flag of IEEE 1588

[ upstream commit bd8f90f0175914bc7df9ef2e9170a850faaa253b ]

Currently, the RTE_MBUF_F_RX_IEEE1588_TMST offload flag will
not be set when the scatter algorithm is used.
This patch fixes it.

Fixes: 4801f0403b58 ("net/hns3: fix IEEE 1588 PTP for scalar scattered Rx")

Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
 drivers/net/hns3/hns3_rxtx.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c
index bbb3b305d1..b87655c953 100644
--- a/drivers/net/hns3/hns3_rxtx.c
+++ b/drivers/net/hns3/hns3_rxtx.c
@@ -2671,6 +2671,7 @@ hns3_recv_scattered_pkts(void *rx_queue,
 			continue;
 		}
 
+		first_seg->ol_flags = 0;
 		if (unlikely(bd_base_info & BIT(HNS3_RXD_TS_VLD_B)))
 			hns3_rx_ptp_timestamp_handle(rxq, first_seg, timestamp);
 
@@ -2700,7 +2701,7 @@ hns3_recv_scattered_pkts(void *rx_queue,
 
 		first_seg->port = rxq->port_id;
 		first_seg->hash.rss = rte_le_to_cpu_32(rxd.rx.rss_hash);
-		first_seg->ol_flags = RTE_MBUF_F_RX_RSS_HASH;
+		first_seg->ol_flags |= RTE_MBUF_F_RX_RSS_HASH;
 		if (unlikely(bd_base_info & BIT(HNS3_RXD_LUM_B))) {
 			first_seg->hash.fdir.hi =
 				rte_le_to_cpu_16(rxd.rx.fd_id);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.133677285 +0100
+++ 0010-net-hns3-fix-offload-flag-of-IEEE-1588.patch	2024-06-25 00:22:13.077183447 +0100
@@ -1 +1 @@
-From bd8f90f0175914bc7df9ef2e9170a850faaa253b Mon Sep 17 00:00:00 2001
+From 419ac23f30616787391300ed67909f9b1cad9b32 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit bd8f90f0175914bc7df9ef2e9170a850faaa253b ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 73a388b2fe..e6d277ffad 100644
+index bbb3b305d1..b87655c953 100644
@@ -23 +24 @@
-@@ -2669,6 +2669,7 @@ hns3_recv_scattered_pkts(void *rx_queue,
+@@ -2671,6 +2671,7 @@ hns3_recv_scattered_pkts(void *rx_queue,
@@ -31 +32 @@
-@@ -2698,7 +2699,7 @@ hns3_recv_scattered_pkts(void *rx_queue,
+@@ -2700,7 +2701,7 @@ hns3_recv_scattered_pkts(void *rx_queue,

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

* patch 'net/hns3: fix Rx timestamp flag' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (8 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/hns3: fix offload flag of IEEE 1588' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/hns3: fix double free for Rx/Tx queue' " luca.boccassi
                   ` (69 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Dengdui Huang; +Cc: Jie Hai, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/afd6de50ebd4bd2d41abe98bf0aa2a3c8146bb36

Thanks.

Luca Boccassi

---
From afd6de50ebd4bd2d41abe98bf0aa2a3c8146bb36 Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Wed, 3 Apr 2024 18:16:20 +0800
Subject: [PATCH] net/hns3: fix Rx timestamp flag

[ upstream commit e7141041d3aa74ff49b703424f120a6e2c00dcb4 ]

The flag RTE_MBUF_F_RX_IEEE1588_PTP depends on the packet
type and does not need to be set when reading Rx timestamp.

Fixes: 38b539d96eb6 ("net/hns3: support IEEE 1588 PTP")

Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
 drivers/net/hns3/hns3_rxtx.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c
index b87655c953..392df0bae5 100644
--- a/drivers/net/hns3/hns3_rxtx.c
+++ b/drivers/net/hns3/hns3_rxtx.c
@@ -2392,8 +2392,7 @@ hns3_rx_ptp_timestamp_handle(struct hns3_rx_queue *rxq, struct rte_mbuf *mbuf,
 {
 	struct hns3_pf *pf = HNS3_DEV_PRIVATE_TO_PF(rxq->hns);
 
-	mbuf->ol_flags |= RTE_MBUF_F_RX_IEEE1588_PTP |
-			  RTE_MBUF_F_RX_IEEE1588_TMST;
+	mbuf->ol_flags |= RTE_MBUF_F_RX_IEEE1588_TMST;
 	if (hns3_timestamp_rx_dynflag > 0) {
 		*RTE_MBUF_DYNFIELD(mbuf, hns3_timestamp_dynfield_offset,
 			rte_mbuf_timestamp_t *) = timestamp;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.211019811 +0100
+++ 0011-net-hns3-fix-Rx-timestamp-flag.patch	2024-06-25 00:22:13.081183529 +0100
@@ -1 +1 @@
-From e7141041d3aa74ff49b703424f120a6e2c00dcb4 Mon Sep 17 00:00:00 2001
+From afd6de50ebd4bd2d41abe98bf0aa2a3c8146bb36 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e7141041d3aa74ff49b703424f120a6e2c00dcb4 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index e6d277ffad..55311402fe 100644
+index b87655c953..392df0bae5 100644
@@ -22 +23 @@
-@@ -2389,8 +2389,7 @@ hns3_rx_ptp_timestamp_handle(struct hns3_rx_queue *rxq, struct rte_mbuf *mbuf,
+@@ -2392,8 +2392,7 @@ hns3_rx_ptp_timestamp_handle(struct hns3_rx_queue *rxq, struct rte_mbuf *mbuf,

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

* patch 'net/hns3: fix double free for Rx/Tx queue' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (9 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/hns3: fix Rx timestamp flag' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:57 ` patch 'net/hns3: fix variable overflow' " luca.boccassi
                   ` (68 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Dengdui Huang; +Cc: Jie Hai, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/8ec7b95de7673fe8085ae92aa829a5e71b200211

Thanks.

Luca Boccassi

---
From 8ec7b95de7673fe8085ae92aa829a5e71b200211 Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Wed, 3 Apr 2024 18:16:21 +0800
Subject: [PATCH] net/hns3: fix double free for Rx/Tx queue

[ upstream commit bbf6fcc0cc62031a26517608a471873339423d8c ]

The Pointers to some resources on the Rx/Tx queue need to be set to NULL
after free inside the hns3_rx/tx_queue_release(), as this function is
called from multiple threads (reset thread, device config thread, etc),
leading to double memory free error.

Fixes: bba636698316 ("net/hns3: support Rx/Tx and related operations")

Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
 drivers/net/hns3/hns3_rxtx.c | 23 ++++++++++++++++++-----
 1 file changed, 18 insertions(+), 5 deletions(-)

diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c
index 392df0bae5..c0479a44dc 100644
--- a/drivers/net/hns3/hns3_rxtx.c
+++ b/drivers/net/hns3/hns3_rxtx.c
@@ -86,9 +86,14 @@ hns3_rx_queue_release(void *queue)
 	struct hns3_rx_queue *rxq = queue;
 	if (rxq) {
 		hns3_rx_queue_release_mbufs(rxq);
-		if (rxq->mz)
+		if (rxq->mz) {
 			rte_memzone_free(rxq->mz);
-		rte_free(rxq->sw_ring);
+			rxq->mz = NULL;
+		}
+		if (rxq->sw_ring) {
+			rte_free(rxq->sw_ring);
+			rxq->sw_ring = NULL;
+		}
 		rte_free(rxq);
 	}
 }
@@ -99,10 +104,18 @@ hns3_tx_queue_release(void *queue)
 	struct hns3_tx_queue *txq = queue;
 	if (txq) {
 		hns3_tx_queue_release_mbufs(txq);
-		if (txq->mz)
+		if (txq->mz) {
 			rte_memzone_free(txq->mz);
-		rte_free(txq->sw_ring);
-		rte_free(txq->free);
+			txq->mz = NULL;
+		}
+		if (txq->sw_ring) {
+			rte_free(txq->sw_ring);
+			txq->sw_ring = NULL;
+		}
+		if (txq->free) {
+			rte_free(txq->free);
+			txq->free = NULL;
+		}
 		rte_free(txq);
 	}
 }
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.280983267 +0100
+++ 0012-net-hns3-fix-double-free-for-Rx-Tx-queue.patch	2024-06-25 00:22:13.089183692 +0100
@@ -1 +1 @@
-From bbf6fcc0cc62031a26517608a471873339423d8c Mon Sep 17 00:00:00 2001
+From 8ec7b95de7673fe8085ae92aa829a5e71b200211 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit bbf6fcc0cc62031a26517608a471873339423d8c ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 55311402fe..bf10da1928 100644
+index 392df0bae5..c0479a44dc 100644

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

* patch 'net/hns3: fix variable overflow' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (10 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/hns3: fix double free for Rx/Tx queue' " luca.boccassi
@ 2024-06-24 23:57 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/hns3: disable SCTP verification tag for RSS hash input' " luca.boccassi
                   ` (67 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:57 UTC (permalink / raw)
  To: Dengdui Huang; +Cc: Jie Hai, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/f8aabaa13ad5f0ebd8aca476d5500153aeb9faa0

Thanks.

Luca Boccassi

---
From f8aabaa13ad5f0ebd8aca476d5500153aeb9faa0 Mon Sep 17 00:00:00 2001
From: Dengdui Huang <huangdengdui@huawei.com>
Date: Wed, 3 Apr 2024 18:16:22 +0800
Subject: [PATCH] net/hns3: fix variable overflow

[ upstream commit d7a0698ce704852cfb3b3b541107477d9b4bd2fd ]

The function strtoul() returns an unsigned long, which should
be received using the variable uint64_t.

Fixes: 2fc3e696a7f1 ("net/hns3: add runtime config for mailbox limit time")

Signed-off-by: Dengdui Huang <huangdengdui@huawei.com>
Signed-off-by: Jie Hai <haijie1@huawei.com>
---
 drivers/net/hns3/hns3_common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/hns3/hns3_common.c b/drivers/net/hns3/hns3_common.c
index 119c930b1a..c51af055d3 100644
--- a/drivers/net/hns3/hns3_common.c
+++ b/drivers/net/hns3/hns3_common.c
@@ -219,7 +219,7 @@ hns3_parse_dev_caps_mask(const char *key, const char *value, void *extra_args)
 static int
 hns3_parse_mbx_time_limit(const char *key, const char *value, void *extra_args)
 {
-	uint32_t val;
+	uint64_t val;
 
 	RTE_SET_USED(key);
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.349150622 +0100
+++ 0013-net-hns3-fix-variable-overflow.patch	2024-06-25 00:22:13.089183692 +0100
@@ -1 +1 @@
-From d7a0698ce704852cfb3b3b541107477d9b4bd2fd Mon Sep 17 00:00:00 2001
+From f8aabaa13ad5f0ebd8aca476d5500153aeb9faa0 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d7a0698ce704852cfb3b3b541107477d9b4bd2fd ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 28c26b049c..5e6cdfdaa0 100644
+index 119c930b1a..c51af055d3 100644
@@ -22 +23 @@
-@@ -224,7 +224,7 @@ hns3_parse_dev_caps_mask(const char *key, const char *value, void *extra_args)
+@@ -219,7 +219,7 @@ hns3_parse_dev_caps_mask(const char *key, const char *value, void *extra_args)

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

* patch 'net/hns3: disable SCTP verification tag for RSS hash input' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (11 preceding siblings ...)
  2024-06-24 23:57 ` patch 'net/hns3: fix variable overflow' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/af_packet: align Rx/Tx structs to cache line' " luca.boccassi
                   ` (66 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Jie Hai; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/ac72e810412dc6e55ff861377573e9f3e090ba04

Thanks.

Luca Boccassi

---
From ac72e810412dc6e55ff861377573e9f3e090ba04 Mon Sep 17 00:00:00 2001
From: Jie Hai <haijie1@huawei.com>
Date: Wed, 3 Apr 2024 18:16:23 +0800
Subject: [PATCH] net/hns3: disable SCTP verification tag for RSS hash input

[ upstream commit bb1f4717636f5b7d27f4f2fe30469b69d8910bd0 ]

When the symmetric RSS algorithm is used, the same packet is
expected to be hashed to the same queue in the upstream and
downstream directions.

The problem is that it could map the packets in the same SCTP
connection to different NIC RX queues depending on the direction
of packets. This is because the verification Tag is used as the
RSS hash input for the SCTP packets, and the value depends on the
peer end of the SCTP connection and could not be symmetrically
used in the hardware-implemented RSS algorithm.

In addition, the ethdev framework doesn't support setting SCTP
V-tag as the RSS hash input. So disable it for all RSS hash
algorithms.

Signed-off-by: Jie Hai <haijie1@huawei.com>
---
 drivers/net/hns3/hns3_rss.c | 6 ++----
 drivers/net/hns3/hns3_rss.h | 6 ++----
 2 files changed, 4 insertions(+), 8 deletions(-)

diff --git a/drivers/net/hns3/hns3_rss.c b/drivers/net/hns3/hns3_rss.c
index eeeca71a5c..ac88ca04ce 100644
--- a/drivers/net/hns3/hns3_rss.c
+++ b/drivers/net/hns3/hns3_rss.c
@@ -153,8 +153,7 @@ static const struct {
 	  BIT_ULL(HNS3_RSS_FIELD_IPV4_SCTP_EN_IP_S) |
 	  BIT_ULL(HNS3_RSS_FIELD_IPV4_SCTP_EN_IP_D) |
 	  BIT_ULL(HNS3_RSS_FIELD_IPV4_SCTP_EN_SCTP_S) |
-	  BIT_ULL(HNS3_RSS_FIELD_IPV4_SCTP_EN_SCTP_D) |
-	  BIT_ULL(HNS3_RSS_FIELD_IPV4_SCTP_EN_SCTP_VER),
+	  BIT_ULL(HNS3_RSS_FIELD_IPV4_SCTP_EN_SCTP_D),
 	  HNS3_RSS_TUPLE_IPV4_SCTP_M },
 
 	/* IPV6-FRAG */
@@ -274,8 +273,7 @@ static const struct {
 	  BIT_ULL(HNS3_RSS_FIELD_IPV6_SCTP_EN_IP_S) |
 	  BIT_ULL(HNS3_RSS_FIELD_IPV6_SCTP_EN_IP_D) |
 	  BIT_ULL(HNS3_RSS_FIELD_IPV6_SCTP_EN_SCTP_D) |
-	  BIT_ULL(HNS3_RSS_FIELD_IPV6_SCTP_EN_SCTP_S) |
-	  BIT_ULL(HNS3_RSS_FIELD_IPV6_SCTP_EN_SCTP_VER),
+	  BIT_ULL(HNS3_RSS_FIELD_IPV6_SCTP_EN_SCTP_S),
 	  HNS3_RSS_TUPLE_IPV6_SCTP_M },
 };
 
diff --git a/drivers/net/hns3/hns3_rss.h b/drivers/net/hns3/hns3_rss.h
index 9d182a8025..0755760b45 100644
--- a/drivers/net/hns3/hns3_rss.h
+++ b/drivers/net/hns3/hns3_rss.h
@@ -49,7 +49,6 @@ enum hns3_tuple_field {
 	HNS3_RSS_FIELD_IPV4_SCTP_EN_SCTP_S,
 	HNS3_RSS_FIELD_IPV4_SCTP_EN_IP_D,
 	HNS3_RSS_FIELD_IPV4_SCTP_EN_IP_S,
-	HNS3_RSS_FIELD_IPV4_SCTP_EN_SCTP_VER,
 
 	/* IPV4 ENABLE FIELD */
 	HNS3_RSS_FIELD_IPV4_EN_NONFRAG_IP_D = 24,
@@ -74,7 +73,6 @@ enum hns3_tuple_field {
 	HNS3_RSS_FIELD_IPV6_SCTP_EN_SCTP_S,
 	HNS3_RSS_FIELD_IPV6_SCTP_EN_IP_D,
 	HNS3_RSS_FIELD_IPV6_SCTP_EN_IP_S,
-	HNS3_RSS_FIELD_IPV6_SCTP_EN_SCTP_VER,
 
 	/* IPV6 ENABLE FIELD */
 	HNS3_RSS_FIELD_IPV6_NONFRAG_IP_D = 56,
@@ -96,12 +94,12 @@ enum hns3_tuple_field {
 
 #define HNS3_RSS_TUPLE_IPV4_TCP_M	GENMASK(3, 0)
 #define HNS3_RSS_TUPLE_IPV4_UDP_M	GENMASK(11, 8)
-#define HNS3_RSS_TUPLE_IPV4_SCTP_M	GENMASK(20, 16)
+#define HNS3_RSS_TUPLE_IPV4_SCTP_M	GENMASK(19, 16)
 #define HNS3_RSS_TUPLE_IPV4_NONF_M	GENMASK(25, 24)
 #define HNS3_RSS_TUPLE_IPV4_FLAG_M	GENMASK(27, 26)
 #define HNS3_RSS_TUPLE_IPV6_TCP_M	GENMASK(35, 32)
 #define HNS3_RSS_TUPLE_IPV6_UDP_M	GENMASK(43, 40)
-#define HNS3_RSS_TUPLE_IPV6_SCTP_M	GENMASK(52, 48)
+#define HNS3_RSS_TUPLE_IPV6_SCTP_M	GENMASK(51, 48)
 #define HNS3_RSS_TUPLE_IPV6_NONF_M	GENMASK(57, 56)
 #define HNS3_RSS_TUPLE_IPV6_FLAG_M	GENMASK(59, 58)
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.411982104 +0100
+++ 0014-net-hns3-disable-SCTP-verification-tag-for-RSS-hash-.patch	2024-06-25 00:22:13.089183692 +0100
@@ -1 +1 @@
-From bb1f4717636f5b7d27f4f2fe30469b69d8910bd0 Mon Sep 17 00:00:00 2001
+From ac72e810412dc6e55ff861377573e9f3e090ba04 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit bb1f4717636f5b7d27f4f2fe30469b69d8910bd0 ]
+
@@ -21,2 +22,0 @@
-Cc: stable@dpdk.org
-
@@ -30 +30 @@
-index 15feb26043..3eae4caf52 100644
+index eeeca71a5c..ac88ca04ce 100644

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

* patch 'net/af_packet: align Rx/Tx structs to cache line' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (12 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/hns3: disable SCTP verification tag for RSS hash input' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'doc: fix testpmd ring size command' " luca.boccassi
                   ` (65 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Mattias Rönnblom
  Cc: Morten Brørup, Stephen Hemminger, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/a7e4b44736fb43bf7a6d228df2fe7b6ca4ea7f36

Thanks.

Luca Boccassi

---
From a7e4b44736fb43bf7a6d228df2fe7b6ca4ea7f36 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Mattias=20R=C3=B6nnblom?= <mattias.ronnblom@ericsson.com>
Date: Fri, 26 Apr 2024 11:05:02 +0200
Subject: [PATCH] net/af_packet: align Rx/Tx structs to cache line
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit c7a2ce0c1b1bb526304f8875f68cab78f5a5d42c ]

Cache align Rx and Tx queue struct to avoid false sharing.

The RX struct happens to be 64 bytes on x86_64 already, so cache
alignment has no effect there, but it does on 32-bit ISAs.

The TX struct is 56 bytes on x86_64.

Both structs keep counters, and in the RX case they are updated even
for empty polls.

Fixes: 364e08f2bbc0 ("af_packet: add PMD for AF_PACKET-based virtual devices")

Signed-off-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>
Reviewed-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 drivers/net/af_packet/rte_eth_af_packet.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/af_packet/rte_eth_af_packet.c b/drivers/net/af_packet/rte_eth_af_packet.c
index 397a32db58..6b7b16f348 100644
--- a/drivers/net/af_packet/rte_eth_af_packet.c
+++ b/drivers/net/af_packet/rte_eth_af_packet.c
@@ -6,6 +6,7 @@
  * All rights reserved.
  */
 
+#include <rte_common.h>
 #include <rte_string_fns.h>
 #include <rte_mbuf.h>
 #include <ethdev_driver.h>
@@ -39,7 +40,7 @@
 #define DFLT_FRAME_SIZE		(1 << 11)
 #define DFLT_FRAME_COUNT	(1 << 9)
 
-struct pkt_rx_queue {
+struct __rte_cache_aligned pkt_rx_queue {
 	int sockfd;
 
 	struct iovec *rd;
@@ -55,7 +56,7 @@ struct pkt_rx_queue {
 	volatile unsigned long rx_bytes;
 };
 
-struct pkt_tx_queue {
+struct __rte_cache_aligned pkt_tx_queue {
 	int sockfd;
 	unsigned int frame_data_size;
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.475409131 +0100
+++ 0015-net-af_packet-align-Rx-Tx-structs-to-cache-line.patch	2024-06-25 00:22:13.093183774 +0100
@@ -1 +1 @@
-From c7a2ce0c1b1bb526304f8875f68cab78f5a5d42c Mon Sep 17 00:00:00 2001
+From a7e4b44736fb43bf7a6d228df2fe7b6ca4ea7f36 Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit c7a2ce0c1b1bb526304f8875f68cab78f5a5d42c ]
+
@@ -20 +21,0 @@
-Cc: stable@dpdk.org

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

* patch 'doc: fix testpmd ring size command' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (13 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/af_packet: align Rx/Tx structs to cache line' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/af_xdp: fix port ID in Rx mbuf' " luca.boccassi
                   ` (64 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Kevin Traynor; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/d00a311cfb26068fb30f44040f1e8430735d39d3

Thanks.

Luca Boccassi

---
From d00a311cfb26068fb30f44040f1e8430735d39d3 Mon Sep 17 00:00:00 2001
From: Kevin Traynor <ktraynor@redhat.com>
Date: Fri, 3 May 2024 09:51:29 +0100
Subject: [PATCH] doc: fix testpmd ring size command

[ upstream commit 7a30ea42fb6ef979768d39fc4e1dec7e2d9efe0d ]

The documentation is missing the 'config' word.

In app, 'help ports' shows the correct syntax:

port config (port_id) (rxq|txq) (queue_id) ring_size (value)

Fixes: 1a77cffa8143 ("app/testpmd: enable queue ring size configure")

Signed-off-by: Kevin Traynor <ktraynor@redhat.com>
Acked-by: Ferruh Yigit <ferruh.yigit@amd.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 0037506a79..8e7d4f1b86 100644
--- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst
+++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst
@@ -1995,7 +1995,7 @@ port config - queue ring size
 
 Configure a rx/tx queue ring size::
 
-   testpmd> port (port_id) (rxq|txq) (queue_id) ring_size (value)
+   testpmd> port config (port_id) (rxq|txq) (queue_id) ring_size (value)
 
 Only take effect after command that (re-)start the port or command that setup specific queue.
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.539608971 +0100
+++ 0016-doc-fix-testpmd-ring-size-command.patch	2024-06-25 00:22:13.097183855 +0100
@@ -1 +1 @@
-From 7a30ea42fb6ef979768d39fc4e1dec7e2d9efe0d Mon Sep 17 00:00:00 2001
+From d00a311cfb26068fb30f44040f1e8430735d39d3 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 7a30ea42fb6ef979768d39fc4e1dec7e2d9efe0d ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 2fbf9220d8..ecd040504e 100644
+index 0037506a79..8e7d4f1b86 100644
@@ -25 +26 @@
-@@ -2032,7 +2032,7 @@ port config - queue ring size
+@@ -1995,7 +1995,7 @@ port config - queue ring size

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

* patch 'net/af_xdp: fix port ID in Rx mbuf' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (14 preceding siblings ...)
  2024-06-24 23:58 ` patch 'doc: fix testpmd ring size command' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/af_xdp: count mbuf allocation failures' " luca.boccassi
                   ` (63 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Ciara Loftus; +Cc: Stephen Hemminger, Maryam Tahhan, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/20c39f6a1b472578edc5595d472c4e5416a584eb

Thanks.

Luca Boccassi

---
From 20c39f6a1b472578edc5595d472c4e5416a584eb Mon Sep 17 00:00:00 2001
From: Ciara Loftus <ciara.loftus@intel.com>
Date: Tue, 14 May 2024 08:41:52 +0000
Subject: [PATCH] net/af_xdp: fix port ID in Rx mbuf

[ upstream commit 9bab1d2667aec4942ae1d384671e5148960bd88f ]

Record the port id in the af_xdp rx queue structure and use it
to set the port id of the mbuf of a received packed.

Bugzilla ID: 1428
Fixes: f1debd77efaf ("net/af_xdp: introduce AF_XDP PMD")

Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
Acked-by: Maryam Tahhan <mtahhan@redhat.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index 3c976dd6e0..b28418234d 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -112,6 +112,7 @@ struct pkt_rx_queue {
 	struct xsk_umem_info *umem;
 	struct xsk_socket *xsk;
 	struct rte_mempool *mb_pool;
+	uint16_t port;
 
 	struct rx_stats stats;
 
@@ -338,6 +339,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		bufs[i]->data_off = offset - sizeof(struct rte_mbuf) -
 			rte_pktmbuf_priv_size(umem->mb_pool) -
 			umem->mb_pool->header_size;
+		bufs[i]->port = rxq->port;
 
 		rte_pktmbuf_pkt_len(bufs[i]) = len;
 		rte_pktmbuf_data_len(bufs[i]) = len;
@@ -404,6 +406,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		rte_pktmbuf_data_len(mbufs[i]) = len;
 		rx_bytes += len;
 		bufs[i] = mbufs[i];
+		bufs[i]->port = rxq->port;
 	}
 
 	xsk_ring_cons__release(rx, nb_pkts);
@@ -1495,6 +1498,8 @@ eth_rx_queue_setup(struct rte_eth_dev *dev,
 
 	process_private->rxq_xsk_fds[rx_queue_id] = rxq->fds[0].fd;
 
+	rxq->port = dev->data->port_id;
+
 	dev->data->rx_queues[rx_queue_id] = rxq;
 	return 0;
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.610814298 +0100
+++ 0017-net-af_xdp-fix-port-ID-in-Rx-mbuf.patch	2024-06-25 00:22:13.097183855 +0100
@@ -1 +1 @@
-From 9bab1d2667aec4942ae1d384671e5148960bd88f Mon Sep 17 00:00:00 2001
+From 20c39f6a1b472578edc5595d472c4e5416a584eb Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 9bab1d2667aec4942ae1d384671e5148960bd88f ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 2d6f64337e..0997543ee5 100644
+index 3c976dd6e0..b28418234d 100644
@@ -25 +26 @@
-@@ -133,6 +133,7 @@ struct pkt_rx_queue {
+@@ -112,6 +112,7 @@ struct pkt_rx_queue {
@@ -33 +34 @@
-@@ -368,6 +369,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -338,6 +339,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
@@ -41 +42 @@
-@@ -434,6 +436,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -404,6 +406,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
@@ -49 +50 @@
-@@ -1813,6 +1816,8 @@ eth_rx_queue_setup(struct rte_eth_dev *dev,
+@@ -1495,6 +1498,8 @@ eth_rx_queue_setup(struct rte_eth_dev *dev,

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

* patch 'net/af_xdp: count mbuf allocation failures' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (15 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/af_xdp: fix port ID in Rx mbuf' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/af_xdp: fix stats reset' " luca.boccassi
                   ` (62 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Ciara Loftus; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/13ac24282065220a4c3dbed9cc961a6a9b728421

Thanks.

Luca Boccassi

---
From 13ac24282065220a4c3dbed9cc961a6a9b728421 Mon Sep 17 00:00:00 2001
From: Ciara Loftus <ciara.loftus@intel.com>
Date: Tue, 14 May 2024 08:41:53 +0000
Subject: [PATCH] net/af_xdp: count mbuf allocation failures

[ upstream commit f294405ab98594aa41269507dde95cc89bb20a61 ]

Failures to allocate mbufs in the receive path were not being
accounted for in the ethdev statistics. Fix this.

Bugzilla ID: 1429
Fixes: f1debd77efaf ("net/af_xdp: introduce AF_XDP PMD")

Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index b28418234d..544ce40693 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -290,6 +290,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	unsigned long rx_bytes = 0;
 	int i;
 	struct rte_mbuf *fq_bufs[ETH_AF_XDP_RX_BATCH_SIZE];
+	struct rte_eth_dev *dev = &rte_eth_devices[rxq->port];
 
 	nb_pkts = xsk_ring_cons__peek(rx, nb_pkts, &idx_rx);
 
@@ -317,6 +318,8 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		 * xsk_ring_cons__peek
 		 */
 		rx->cached_cons -= nb_pkts;
+		dev->data->rx_mbuf_alloc_failed += nb_pkts;
+
 		return 0;
 	}
 
@@ -368,6 +371,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	int i;
 	uint32_t free_thresh = fq->size >> 1;
 	struct rte_mbuf *mbufs[ETH_AF_XDP_RX_BATCH_SIZE];
+	struct rte_eth_dev *dev = &rte_eth_devices[rxq->port];
 
 	if (xsk_prod_nb_free(fq, free_thresh) >= free_thresh)
 		(void)reserve_fill_queue(umem, nb_pkts, NULL, fq);
@@ -386,6 +390,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 		 * xsk_ring_cons__peek
 		 */
 		rx->cached_cons -= nb_pkts;
+		dev->data->rx_mbuf_alloc_failed += nb_pkts;
 		return 0;
 	}
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.676720415 +0100
+++ 0018-net-af_xdp-count-mbuf-allocation-failures.patch	2024-06-25 00:22:13.101183937 +0100
@@ -1 +1 @@
-From f294405ab98594aa41269507dde95cc89bb20a61 Mon Sep 17 00:00:00 2001
+From 13ac24282065220a4c3dbed9cc961a6a9b728421 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit f294405ab98594aa41269507dde95cc89bb20a61 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 0997543ee5..0db761a204 100644
+index b28418234d..544ce40693 100644
@@ -24 +25 @@
-@@ -320,6 +320,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -290,6 +290,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
@@ -32 +33 @@
-@@ -347,6 +348,8 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -317,6 +318,8 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
@@ -41 +42 @@
-@@ -398,6 +401,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -368,6 +371,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
@@ -49 +50 @@
-@@ -416,6 +420,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
+@@ -386,6 +390,7 @@ af_xdp_rx_cp(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)

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

* patch 'net/af_xdp: fix stats reset' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (16 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/af_xdp: count mbuf allocation failures' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/af_xdp: remove unused local statistic' " luca.boccassi
                   ` (61 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Ciara Loftus; +Cc: Stephen Hemminger, Maryam Tahhan, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/9e8bcd1f55c9ccde6ffcb82591538ea8230a96d5

Thanks.

Luca Boccassi

---
From 9e8bcd1f55c9ccde6ffcb82591538ea8230a96d5 Mon Sep 17 00:00:00 2001
From: Ciara Loftus <ciara.loftus@intel.com>
Date: Tue, 14 May 2024 08:41:54 +0000
Subject: [PATCH] net/af_xdp: fix stats reset

[ upstream commit 3577b1ee97dcfe9ff1b9e050bed55f17c435a93d ]

The imissed statistic was not properly reset because it was
read directly from the kernel statistics. To fix this, take note
of the kernel statistic when the stats are reset and deduct this
value from the kernel statistic read during statistics get.

Bugzilla ID: 1430
Fixes: f1debd77efaf ("net/af_xdp: introduce AF_XDP PMD")

Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
Acked-by: Maryam Tahhan <mtahhan@redhat.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 17 +++++++++++++++--
 1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index 544ce40693..df6ac7a4f2 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -105,6 +105,7 @@ struct rx_stats {
 	uint64_t rx_pkts;
 	uint64_t rx_bytes;
 	uint64_t rx_dropped;
+	uint64_t imissed_offset;
 };
 
 struct pkt_rx_queue {
@@ -862,7 +863,7 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
 			AF_XDP_LOG(ERR, "getsockopt() failed for XDP_STATISTICS.\n");
 			return -1;
 		}
-		stats->imissed += xdp_stats.rx_dropped;
+		stats->imissed += xdp_stats.rx_dropped - rxq->stats.imissed_offset;
 
 		stats->opackets += stats->q_opackets[i];
 		stats->obytes += stats->q_obytes[i];
@@ -875,13 +876,25 @@ static int
 eth_stats_reset(struct rte_eth_dev *dev)
 {
 	struct pmd_internals *internals = dev->data->dev_private;
-	int i;
+	struct pmd_process_private *process_private = dev->process_private;
+	struct xdp_statistics xdp_stats;
+	socklen_t optlen;
+	int i, ret, fd;
 
 	for (i = 0; i < internals->queue_cnt; i++) {
 		memset(&internals->rx_queues[i].stats, 0,
 					sizeof(struct rx_stats));
 		memset(&internals->tx_queues[i].stats, 0,
 					sizeof(struct tx_stats));
+		fd = process_private->rxq_xsk_fds[i];
+		optlen = sizeof(struct xdp_statistics);
+		ret = fd >= 0 ? getsockopt(fd, SOL_XDP, XDP_STATISTICS,
+					   &xdp_stats, &optlen) : -1;
+		if (ret != 0) {
+			AF_XDP_LOG(ERR, "getsockopt() failed for XDP_STATISTICS.\n");
+			return -1;
+		}
+		internals->rx_queues[i].stats.imissed_offset = xdp_stats.rx_dropped;
 	}
 
 	return 0;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.742605431 +0100
+++ 0019-net-af_xdp-fix-stats-reset.patch	2024-06-25 00:22:13.101183937 +0100
@@ -1 +1 @@
-From 3577b1ee97dcfe9ff1b9e050bed55f17c435a93d Mon Sep 17 00:00:00 2001
+From 9e8bcd1f55c9ccde6ffcb82591538ea8230a96d5 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3577b1ee97dcfe9ff1b9e050bed55f17c435a93d ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -24 +25 @@
-index 0db761a204..25e67851f6 100644
+index 544ce40693..df6ac7a4f2 100644
@@ -27 +28 @@
-@@ -126,6 +126,7 @@ struct rx_stats {
+@@ -105,6 +105,7 @@ struct rx_stats {
@@ -35 +36 @@
-@@ -892,7 +893,7 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
+@@ -862,7 +863,7 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
@@ -44 +45 @@
-@@ -905,13 +906,25 @@ static int
+@@ -875,13 +876,25 @@ static int

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

* patch 'net/af_xdp: remove unused local statistic' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (17 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/af_xdp: fix stats reset' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/tap: fix file descriptor check in isolated flow' " luca.boccassi
                   ` (60 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Ciara Loftus; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/19c6df9ce8fdb63c39c779b4adbd3b0bb5a90b3f

Thanks.

Luca Boccassi

---
From 19c6df9ce8fdb63c39c779b4adbd3b0bb5a90b3f Mon Sep 17 00:00:00 2001
From: Ciara Loftus <ciara.loftus@intel.com>
Date: Tue, 14 May 2024 08:41:55 +0000
Subject: [PATCH] net/af_xdp: remove unused local statistic

[ upstream commit abdabad636a54660f4a260e1e9dc573900582bd4 ]

The rx_dropped statistic is never incremented so its existence
is pointless. Remove it.

Fixes: f1debd77efaf ("net/af_xdp: introduce AF_XDP PMD")

Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index df6ac7a4f2..343b4c40c9 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -104,7 +104,6 @@ struct xsk_umem_info {
 struct rx_stats {
 	uint64_t rx_pkts;
 	uint64_t rx_bytes;
-	uint64_t rx_dropped;
 	uint64_t imissed_offset;
 };
 
@@ -854,7 +853,6 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
 
 		stats->ipackets += stats->q_ipackets[i];
 		stats->ibytes += stats->q_ibytes[i];
-		stats->imissed += rxq->stats.rx_dropped;
 		stats->oerrors += txq->stats.tx_dropped;
 		fd = process_private->rxq_xsk_fds[i];
 		ret = fd >= 0 ? getsockopt(fd, SOL_XDP, XDP_STATISTICS,
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.807938029 +0100
+++ 0020-net-af_xdp-remove-unused-local-statistic.patch	2024-06-25 00:22:13.105184018 +0100
@@ -1 +1 @@
-From abdabad636a54660f4a260e1e9dc573900582bd4 Mon Sep 17 00:00:00 2001
+From 19c6df9ce8fdb63c39c779b4adbd3b0bb5a90b3f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit abdabad636a54660f4a260e1e9dc573900582bd4 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 25e67851f6..4b282adb03 100644
+index df6ac7a4f2..343b4c40c9 100644
@@ -23 +24 @@
-@@ -125,7 +125,6 @@ struct xsk_umem_info {
+@@ -104,7 +104,6 @@ struct xsk_umem_info {
@@ -31 +32 @@
-@@ -884,7 +883,6 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)
+@@ -854,7 +853,6 @@ eth_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats)

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

* patch 'net/tap: fix file descriptor check in isolated flow' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (18 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/af_xdp: remove unused local statistic' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: fix MDIO access for non-zero ports and CL45 PHYs' " luca.boccassi
                   ` (59 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/2f9077766d3c0ab959a5bb9d896aceccf781527b

Thanks.

Luca Boccassi

---
From 2f9077766d3c0ab959a5bb9d896aceccf781527b Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Tue, 21 May 2024 13:12:46 -0700
Subject: [PATCH] net/tap: fix file descriptor check in isolated flow

[ upstream commit e9e6089a41c275f3dcd7491f4df903a284653bb9 ]

The check for receive queue FD in flow_isolate is incorrect.
If queue has not been setup then FD will be -1 not 0.

Fixes: f503d2694825 ("net/tap: support flow API isolated mode")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
---
 drivers/net/tap/tap_flow.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/tap/tap_flow.c b/drivers/net/tap/tap_flow.c
index 741ef09fc6..7468c3f0ea 100644
--- a/drivers/net/tap/tap_flow.c
+++ b/drivers/net/tap/tap_flow.c
@@ -1595,7 +1595,7 @@ tap_flow_isolate(struct rte_eth_dev *dev,
 	 * If netdevice is there, setup appropriate flow rules immediately.
 	 * Otherwise it will be set when bringing up the netdevice (tun_alloc).
 	 */
-	if (!process_private->rxq_fds[0])
+	if (process_private->rxq_fds[0] == -1)
 		return 0;
 	if (set) {
 		struct rte_flow *remote_flow;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:14.871775310 +0100
+++ 0021-net-tap-fix-file-descriptor-check-in-isolated-flow.patch	2024-06-25 00:22:13.105184018 +0100
@@ -1 +1 @@
-From e9e6089a41c275f3dcd7491f4df903a284653bb9 Mon Sep 17 00:00:00 2001
+From 2f9077766d3c0ab959a5bb9d896aceccf781527b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e9e6089a41c275f3dcd7491f4df903a284653bb9 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index fa50fe45d7..79cd6a12ca 100644
+index 741ef09fc6..7468c3f0ea 100644

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

* patch 'net/axgbe: fix MDIO access for non-zero ports and CL45 PHYs' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (19 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/tap: fix file descriptor check in isolated flow' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: reset link when link never comes back' " luca.boccassi
                   ` (58 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/b43c908eb24790a7e1150471f8f662fd9576a009

Thanks.

Luca Boccassi

---
From b43c908eb24790a7e1150471f8f662fd9576a009 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:33 +0530
Subject: [PATCH] net/axgbe: fix MDIO access for non-zero ports and CL45 PHYs

[ upstream commit d06394d2641e3fdc0538a23354d9ff7c5aa9b277 ]

The XGBE supports performing MDIO operations using an MDIO command
request. The driver mistakenly uses the mdio port address as the
MDIO command request device address instead of the MDIO command
request port address. Additionally, the driver does not properly check
for and create a clause 45 MDIO command

Without the fix PHY device is not detected and can't be usable.

Check the supplied MDIO register to determine if the request is a clause
45 operation (MII_ADDR_C45). For a clause 45 operation, extract device
address and register number from the supplied MDIO register and use them
to set the MDIO command request device address and register number
fields. For a clause 22 operation, the MDIO request device address is
set to zero and the MDIO command request register number is set to the
supplied MDIO register. In either case, the supplied MDIO port address
is used as the MDIO command request port address.

Fixes: 4ac7516b8b39 ("net/axgbe: add phy init and related APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_common.h |  2 --
 drivers/net/axgbe/axgbe_dev.c    | 22 ++++++++++++++++------
 2 files changed, 16 insertions(+), 8 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_common.h b/drivers/net/axgbe/axgbe_common.h
index a5d11c5832..51532fb34a 100644
--- a/drivers/net/axgbe/axgbe_common.h
+++ b/drivers/net/axgbe/axgbe_common.h
@@ -407,8 +407,6 @@
 #define MAC_MDIOSCAR_PA_WIDTH		5
 #define MAC_MDIOSCAR_RA_INDEX		0
 #define MAC_MDIOSCAR_RA_WIDTH		16
-#define MAC_MDIOSCAR_REG_INDEX		0
-#define MAC_MDIOSCAR_REG_WIDTH		21
 #define MAC_MDIOSCCDR_BUSY_INDEX	22
 #define MAC_MDIOSCCDR_BUSY_WIDTH	1
 #define MAC_MDIOSCCDR_CMD_INDEX		16
diff --git a/drivers/net/axgbe/axgbe_dev.c b/drivers/net/axgbe/axgbe_dev.c
index 6a7fddffca..3389954aa6 100644
--- a/drivers/net/axgbe/axgbe_dev.c
+++ b/drivers/net/axgbe/axgbe_dev.c
@@ -63,15 +63,27 @@ static int mdio_complete(struct axgbe_port *pdata)
 	return 0;
 }
 
+static unsigned int axgbe_create_mdio_sca(int port, int reg)
+{
+	unsigned int mdio_sca, da;
+
+	da = (reg & MII_ADDR_C45) ? reg >> 16 : 0;
+
+	mdio_sca = 0;
+	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, RA, reg);
+	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, PA, port);
+	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, DA, da);
+
+	return mdio_sca;
+}
+
 static int axgbe_write_ext_mii_regs(struct axgbe_port *pdata, int addr,
 				    int reg, u16 val)
 {
 	unsigned int mdio_sca, mdio_sccd;
 	uint64_t timeout;
 
-	mdio_sca = 0;
-	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, REG, reg);
-	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, DA, addr);
+	mdio_sca = axgbe_create_mdio_sca(addr, reg);
 	AXGMAC_IOWRITE(pdata, MAC_MDIOSCAR, mdio_sca);
 
 	mdio_sccd = 0;
@@ -97,9 +109,7 @@ static int axgbe_read_ext_mii_regs(struct axgbe_port *pdata, int addr,
 	unsigned int mdio_sca, mdio_sccd;
 	uint64_t timeout;
 
-	mdio_sca = 0;
-	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, REG, reg);
-	AXGMAC_SET_BITS(mdio_sca, MAC_MDIOSCAR, DA, addr);
+	mdio_sca = axgbe_create_mdio_sca(addr, reg);
 	AXGMAC_IOWRITE(pdata, MAC_MDIOSCAR, mdio_sca);
 
 	mdio_sccd = 0;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.002176787 +0100
+++ 0022-net-axgbe-fix-MDIO-access-for-non-zero-ports-and-CL4.patch	2024-06-25 00:22:13.105184018 +0100
@@ -1 +1 @@
-From d06394d2641e3fdc0538a23354d9ff7c5aa9b277 Mon Sep 17 00:00:00 2001
+From b43c908eb24790a7e1150471f8f662fd9576a009 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d06394d2641e3fdc0538a23354d9ff7c5aa9b277 ]
+
@@ -24 +25,0 @@
-Cc: stable@dpdk.org

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

* patch 'net/axgbe: reset link when link never comes back' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (20 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: fix MDIO access for non-zero ports and CL45 PHYs' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: fix fluctuations for 1G Bel Fuse SFP' " luca.boccassi
                   ` (57 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/ad99680c1dbef9bb02191465926b3c4df8fdf0f2

Thanks.

Luca Boccassi

---
From ad99680c1dbef9bb02191465926b3c4df8fdf0f2 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:34 +0530
Subject: [PATCH] net/axgbe: reset link when link never comes back

[ upstream commit edf463256dd35803aaa11b0da704a0542ad20071 ]

Normally, auto negotiation and reconnect should be automatically done by
the hardware. But there seems to be an issue where auto negotiation has
to be restarted manually. This happens because of link training and so
even though still connected to the partner the link never "comes back".
This needs an auto-negotiation restart.

Without the fix the user will not see the link up status

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_mdio.c     | 2 +-
 drivers/net/axgbe/axgbe_phy_impl.c | 7 +++++++
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/net/axgbe/axgbe_mdio.c b/drivers/net/axgbe/axgbe_mdio.c
index 913ceada0d..b03bc471cb 100644
--- a/drivers/net/axgbe/axgbe_mdio.c
+++ b/drivers/net/axgbe/axgbe_mdio.c
@@ -1051,7 +1051,7 @@ static void axgbe_phy_status(struct axgbe_port *pdata)
 							     &an_restart);
 	if (an_restart) {
 		axgbe_phy_config_aneg(pdata);
-		return;
+		goto adjust_link;
 	}
 
 	if (pdata->phy.link) {
diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index d97fbbfddd..87795c63c9 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -1697,6 +1697,13 @@ static int axgbe_phy_link_status(struct axgbe_port *pdata, int *an_restart)
 	if (reg & MDIO_STAT1_LSTATUS)
 		return 1;
 
+	if (pdata->phy.autoneg == AUTONEG_ENABLE &&
+			phy_data->port_mode == AXGBE_PORT_MODE_BACKPLANE) {
+		if (rte_bit_relaxed_get32(AXGBE_LINK_INIT, &pdata->dev_state)) {
+			*an_restart = 1;
+		}
+	}
+
 	/* No link, attempt a receiver reset cycle */
 	if (phy_data->rrc_count++) {
 		phy_data->rrc_count = 0;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.071800192 +0100
+++ 0023-net-axgbe-reset-link-when-link-never-comes-back.patch	2024-06-25 00:22:13.109184100 +0100
@@ -1 +1 @@
-From edf463256dd35803aaa11b0da704a0542ad20071 Mon Sep 17 00:00:00 2001
+From ad99680c1dbef9bb02191465926b3c4df8fdf0f2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit edf463256dd35803aaa11b0da704a0542ad20071 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -38 +39 @@
-index 44ff28517c..54fe9faae0 100644
+index d97fbbfddd..87795c63c9 100644

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

* patch 'net/axgbe: fix fluctuations for 1G Bel Fuse SFP' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (21 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: reset link when link never comes back' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: update DMA coherency values' " luca.boccassi
                   ` (56 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/fac582ee7d5f145928b28a81795c3364c96343c5

Thanks.

Luca Boccassi

---
From fac582ee7d5f145928b28a81795c3364c96343c5 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:35 +0530
Subject: [PATCH] net/axgbe: fix fluctuations for 1G Bel Fuse SFP

[ upstream commit 3abfda0f7d58b2eef20cdf8e102825678b150421 ]

Frequent link up/down events can happen when a Bel Fuse SFP part is
connected to the amd-xgbe device. Try to avoid the frequent link
issues by resetting the PHY as documented in Bel Fuse SFP datasheet.

Without the fix user will see continuous port link up and down.

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_phy_impl.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index 87795c63c9..8f8845a1c5 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -578,6 +578,9 @@ static bool axgbe_phy_belfuse_parse_quirks(struct axgbe_port *pdata)
 		   AXGBE_BEL_FUSE_VENDOR, strlen(AXGBE_BEL_FUSE_VENDOR)))
 		return false;
 
+	/* Reset PHY - wait for self-clearing reset bit to clear */
+	pdata->phy_if.phy_impl.reset(pdata);
+
 	if (!memcmp(&sfp_eeprom->base[AXGBE_SFP_BASE_VENDOR_PN],
 		    AXGBE_BEL_FUSE_PARTNO, strlen(AXGBE_BEL_FUSE_PARTNO))) {
 		phy_data->sfp_base = AXGBE_SFP_BASE_1000_SX;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.125520152 +0100
+++ 0024-net-axgbe-fix-fluctuations-for-1G-Bel-Fuse-SFP.patch	2024-06-25 00:22:13.109184100 +0100
@@ -1 +1 @@
-From 3abfda0f7d58b2eef20cdf8e102825678b150421 Mon Sep 17 00:00:00 2001
+From fac582ee7d5f145928b28a81795c3364c96343c5 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3abfda0f7d58b2eef20cdf8e102825678b150421 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 54fe9faae0..ee9dcbe3da 100644
+index 87795c63c9..8f8845a1c5 100644

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

* patch 'net/axgbe: update DMA coherency values' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (22 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: fix fluctuations for 1G Bel Fuse SFP' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: disable interrupts during device removal' " luca.boccassi
                   ` (55 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/6aad2db82c5f5e7c69e1efff79d3296002253e8e

Thanks.

Luca Boccassi

---
From 6aad2db82c5f5e7c69e1efff79d3296002253e8e Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:36 +0530
Subject: [PATCH] net/axgbe: update DMA coherency values

[ upstream commit 4e6d9f193d4fe5639a856cdb2dd0aa4a8726fe99 ]

Based on the IOMMU configuration, the current cache control settings can
result in possible coherency issues. The hardware team has recommended
new settings for the PCI device path to eliminate the issue.

Without the fix the user will get incorrect data in TSO functionality

Fixes: 7c4158a5b592 ("net/axgbe: add DMA programming and start/stop")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_dev.c | 20 +++++++++-----------
 1 file changed, 9 insertions(+), 11 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_dev.c b/drivers/net/axgbe/axgbe_dev.c
index 3389954aa6..9b0073eea6 100644
--- a/drivers/net/axgbe/axgbe_dev.c
+++ b/drivers/net/axgbe/axgbe_dev.c
@@ -647,23 +647,21 @@ static void axgbe_config_dma_cache(struct axgbe_port *pdata)
 	unsigned int arcache, awcache, arwcache;
 
 	arcache = 0;
-	AXGMAC_SET_BITS(arcache, DMA_AXIARCR, DRC, 0x3);
+	AXGMAC_SET_BITS(arcache, DMA_AXIARCR, DRC, 0xf);
+	AXGMAC_SET_BITS(arcache, DMA_AXIARCR, TEC, 0xf);
+	AXGMAC_SET_BITS(arcache, DMA_AXIARCR, THC, 0xf);
 	AXGMAC_IOWRITE(pdata, DMA_AXIARCR, arcache);
 
 	awcache = 0;
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, DWC, 0x3);
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RPC, 0x3);
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RPD, 0x1);
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RHC, 0x3);
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RHD, 0x1);
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RDC, 0x3);
-	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RDD, 0x1);
+	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, DWC, 0xf);
+	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RPC, 0xf);
+	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RHC, 0xf);
+	AXGMAC_SET_BITS(awcache, DMA_AXIAWCR, RDC, 0xf);
 	AXGMAC_IOWRITE(pdata, DMA_AXIAWCR, awcache);
 
 	arwcache = 0;
-	AXGMAC_SET_BITS(arwcache, DMA_AXIAWRCR, TDWD, 0x1);
-	AXGMAC_SET_BITS(arwcache, DMA_AXIAWRCR, TDWC, 0x3);
-	AXGMAC_SET_BITS(arwcache, DMA_AXIAWRCR, RDRC, 0x3);
+	AXGMAC_SET_BITS(arwcache, DMA_AXIAWRCR, TDWC, 0xf);
+	AXGMAC_SET_BITS(arwcache, DMA_AXIAWRCR, RDRC, 0xf);
 	AXGMAC_IOWRITE(pdata, DMA_AXIAWRCR, arwcache);
 }
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.176961043 +0100
+++ 0025-net-axgbe-update-DMA-coherency-values.patch	2024-06-25 00:22:13.113184181 +0100
@@ -1 +1 @@
-From 4e6d9f193d4fe5639a856cdb2dd0aa4a8726fe99 Mon Sep 17 00:00:00 2001
+From 6aad2db82c5f5e7c69e1efff79d3296002253e8e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4e6d9f193d4fe5639a856cdb2dd0aa4a8726fe99 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org

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

* patch 'net/axgbe: disable interrupts during device removal' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (23 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: update DMA coherency values' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: disable RRC for yellow carp devices' " luca.boccassi
                   ` (54 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/b07fc265f973fc695348b01163ff3ba23dc5de7d

Thanks.

Luca Boccassi

---
From b07fc265f973fc695348b01163ff3ba23dc5de7d Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:37 +0530
Subject: [PATCH] net/axgbe: disable interrupts during device removal

[ upstream commit 7b7288b08760204139085174ba00a2863dfdbbec ]

Hardware interrupts are enabled during the init, however, they are not
disabled during close.

Disable all hardware interrupts during close operation to avoid any
issues.

Fixes: 9e890103267e ("net/axgbe: add Rx/Tx setup")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_ethdev.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/net/axgbe/axgbe_ethdev.c b/drivers/net/axgbe/axgbe_ethdev.c
index da48a3ac42..30440e9e1d 100644
--- a/drivers/net/axgbe/axgbe_ethdev.c
+++ b/drivers/net/axgbe/axgbe_ethdev.c
@@ -2361,12 +2361,14 @@ static int
 axgbe_dev_close(struct rte_eth_dev *eth_dev)
 {
 	struct rte_pci_device *pci_dev;
+	struct axgbe_port *pdata;
 
 	PMD_INIT_FUNC_TRACE();
 
 	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
 		return 0;
 
+	pdata = eth_dev->data->dev_private;
 	pci_dev = RTE_DEV_TO_PCI(eth_dev->device);
 	axgbe_dev_clear_queues(eth_dev);
 
@@ -2376,6 +2378,9 @@ axgbe_dev_close(struct rte_eth_dev *eth_dev)
 				     axgbe_dev_interrupt_handler,
 				     (void *)eth_dev);
 
+	/* Disable all interrupts in the hardware */
+	XP_IOWRITE(pdata, XP_INT_EN, 0x0);
+
 	return 0;
 }
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.228850660 +0100
+++ 0026-net-axgbe-disable-interrupts-during-device-removal.patch	2024-06-25 00:22:13.113184181 +0100
@@ -1 +1 @@
-From 7b7288b08760204139085174ba00a2863dfdbbec Mon Sep 17 00:00:00 2001
+From b07fc265f973fc695348b01163ff3ba23dc5de7d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 7b7288b08760204139085174ba00a2863dfdbbec ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index dd681f15a0..e5d8f7db02 100644
+index da48a3ac42..30440e9e1d 100644
@@ -25 +26 @@
-@@ -2411,12 +2411,14 @@ static int
+@@ -2361,12 +2361,14 @@ static int
@@ -40 +41 @@
-@@ -2426,6 +2428,9 @@ axgbe_dev_close(struct rte_eth_dev *eth_dev)
+@@ -2376,6 +2378,9 @@ axgbe_dev_close(struct rte_eth_dev *eth_dev)

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

* patch 'net/axgbe: disable RRC for yellow carp devices' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (24 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: disable interrupts during device removal' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: enable PLL control for fixed PHY modes only' " luca.boccassi
                   ` (53 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/a1e4f462f35e4015d7f2de421d96fbd39ff42632

Thanks.

Luca Boccassi

---
From a1e4f462f35e4015d7f2de421d96fbd39ff42632 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:38 +0530
Subject: [PATCH] net/axgbe: disable RRC for yellow carp devices

[ upstream commit e82b0fe097da02eab8be924a28a0a4ca96bc3c69 ]

Link stability issues are noticed on Yellow carp platforms when Receiver
Reset Cycle is issued. Since the CDR workaround is disabled on these
platforms, the Receiver Reset Cycle is not needed.

So, avoid issuing rrc on Yellow carp platforms.

Without the fix the user will not get the link UP.

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_ethdev.c   | 5 +++++
 drivers/net/axgbe/axgbe_ethdev.h   | 1 +
 drivers/net/axgbe/axgbe_phy_impl.c | 2 +-
 3 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/net/axgbe/axgbe_ethdev.c b/drivers/net/axgbe/axgbe_ethdev.c
index 30440e9e1d..2156b1d17a 100644
--- a/drivers/net/axgbe/axgbe_ethdev.c
+++ b/drivers/net/axgbe/axgbe_ethdev.c
@@ -205,6 +205,7 @@ static struct axgbe_version_data axgbe_v2a = {
 	.ecc_support			= 1,
 	.i2c_support			= 1,
 	.an_cdr_workaround		= 1,
+	.enable_rrc			= 1,
 };
 
 static struct axgbe_version_data axgbe_v2b = {
@@ -217,6 +218,7 @@ static struct axgbe_version_data axgbe_v2b = {
 	.ecc_support			= 1,
 	.i2c_support			= 1,
 	.an_cdr_workaround		= 1,
+	.enable_rrc			= 1,
 };
 
 static const struct rte_eth_desc_lim rx_desc_lim = {
@@ -2224,6 +2226,9 @@ eth_axgbe_dev_init(struct rte_eth_dev *eth_dev)
 
 			/* Yellow Carp devices do not need cdr workaround */
 			pdata->vdata->an_cdr_workaround = 0;
+
+			/* Yellow Carp devices do not need rrc */
+			pdata->vdata->enable_rrc = 0;
 		} else {
 			unknown_cpu = 1;
 		}
diff --git a/drivers/net/axgbe/axgbe_ethdev.h b/drivers/net/axgbe/axgbe_ethdev.h
index 7f19321d88..ae57aeaa00 100644
--- a/drivers/net/axgbe/axgbe_ethdev.h
+++ b/drivers/net/axgbe/axgbe_ethdev.h
@@ -463,6 +463,7 @@ struct axgbe_version_data {
 	unsigned int ecc_support;
 	unsigned int i2c_support;
 	unsigned int an_cdr_workaround;
+	unsigned int enable_rrc;
 };
 
 struct axgbe_mmc_stats {
diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index 8f8845a1c5..46ee5f0617 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -1708,7 +1708,7 @@ static int axgbe_phy_link_status(struct axgbe_port *pdata, int *an_restart)
 	}
 
 	/* No link, attempt a receiver reset cycle */
-	if (phy_data->rrc_count++) {
+	if (pdata->vdata->enable_rrc && phy_data->rrc_count++) {
 		phy_data->rrc_count = 0;
 		axgbe_phy_rrc(pdata);
 	}
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.281453298 +0100
+++ 0027-net-axgbe-disable-RRC-for-yellow-carp-devices.patch	2024-06-25 00:22:13.117184263 +0100
@@ -1 +1 @@
-From e82b0fe097da02eab8be924a28a0a4ca96bc3c69 Mon Sep 17 00:00:00 2001
+From a1e4f462f35e4015d7f2de421d96fbd39ff42632 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e82b0fe097da02eab8be924a28a0a4ca96bc3c69 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -26 +27 @@
-index e5d8f7db02..86c2ec64e0 100644
+index 30440e9e1d..2156b1d17a 100644
@@ -29 +30 @@
-@@ -208,6 +208,7 @@ static struct axgbe_version_data axgbe_v2a = {
+@@ -205,6 +205,7 @@ static struct axgbe_version_data axgbe_v2a = {
@@ -37 +38 @@
-@@ -220,6 +221,7 @@ static struct axgbe_version_data axgbe_v2b = {
+@@ -217,6 +218,7 @@ static struct axgbe_version_data axgbe_v2b = {
@@ -45 +46 @@
-@@ -2269,6 +2271,9 @@ eth_axgbe_dev_init(struct rte_eth_dev *eth_dev)
+@@ -2224,6 +2226,9 @@ eth_axgbe_dev_init(struct rte_eth_dev *eth_dev)
@@ -56 +57 @@
-index df5d63c493..f122dfd516 100644
+index 7f19321d88..ae57aeaa00 100644
@@ -68 +69 @@
-index ee9dcbe3da..f51830f800 100644
+index 8f8845a1c5..46ee5f0617 100644

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

* patch 'net/axgbe: enable PLL control for fixed PHY modes only' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (25 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: disable RRC for yellow carp devices' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: fix SFP codes check for DAC cables' " luca.boccassi
                   ` (52 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/07b6c26ee2bbe092c60b96d2dc5d44e067fe1055

Thanks.

Luca Boccassi

---
From 07b6c26ee2bbe092c60b96d2dc5d44e067fe1055 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:39 +0530
Subject: [PATCH] net/axgbe: enable PLL control for fixed PHY modes only

[ upstream commit 1c68b393b8ba05b6ddb321e3632d45fc1021ed96 ]

PLL control setting is needed only in fixed PHY configuration to
fix the peer-peer issues. Without the PLL control setting, the link up
takes longer time in a fixed PHY configuration.

Without the fix the user will not get the link come UP.

Driver implements SW RRC for Autoneg On configuration, hence PLL control
setting is not needed for AN On configuration, and can be skipped.

Also, PLL re-initialization is not needed for PHY Power Off and RRC
commands. Otherwise, they lead to mailbox errors. Added the changes
accordingly.

Fixes: 09b0a36cc7ae ("net/axgbe: toggle PLL settings during rate change")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_phy_impl.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index 46ee5f0617..040176b8ef 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -1228,6 +1228,10 @@ static void axgbe_phy_rx_reset(struct axgbe_port *pdata)
 
 static void axgbe_phy_pll_ctrl(struct axgbe_port *pdata, bool enable)
 {
+	/* PLL_CTRL feature needs to be enabled for fixed PHY modes (Non-Autoneg) only */
+	if (pdata->phy.autoneg != AUTONEG_DISABLE)
+		return;
+
 	XMDIO_WRITE_BITS(pdata, MDIO_MMD_PMAPMD, MDIO_VEND2_PMA_MISC_CTRL0,
 			XGBE_PMA_PLL_CTRL_MASK,
 			enable ? XGBE_PMA_PLL_CTRL_SET
@@ -1272,8 +1276,9 @@ static void axgbe_phy_perform_ratechange(struct axgbe_port *pdata,
 	axgbe_phy_rx_reset(pdata);
 
 reenable_pll:
-	 /* Re-enable the PLL control */
-	axgbe_phy_pll_ctrl(pdata, true);
+	/* Enable PLL re-initialization, not needed for PHY Power Off and RRC cmds */
+	if (cmd != 0 && cmd != 5)
+		axgbe_phy_pll_ctrl(pdata, true);
 
 	PMD_DRV_LOG(NOTICE, "firmware mailbox command did not complete\n");
 }
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.336087708 +0100
+++ 0028-net-axgbe-enable-PLL-control-for-fixed-PHY-modes-onl.patch	2024-06-25 00:22:13.117184263 +0100
@@ -1 +1 @@
-From 1c68b393b8ba05b6ddb321e3632d45fc1021ed96 Mon Sep 17 00:00:00 2001
+From 07b6c26ee2bbe092c60b96d2dc5d44e067fe1055 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 1c68b393b8ba05b6ddb321e3632d45fc1021ed96 ]
+
@@ -20 +21,0 @@
-Cc: stable@dpdk.org
@@ -29 +30 @@
-index f51830f800..bcefbf28f2 100644
+index 46ee5f0617..040176b8ef 100644

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

* patch 'net/axgbe: fix SFP codes check for DAC cables' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (26 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: enable PLL control for fixed PHY modes only' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: fix connection for SFP+ active " luca.boccassi
                   ` (51 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/39527c017d64fc66cd911281f65ec93927adb6a2

Thanks.

Luca Boccassi

---
From 39527c017d64fc66cd911281f65ec93927adb6a2 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:40 +0530
Subject: [PATCH] net/axgbe: fix SFP codes check for DAC cables

[ upstream commit 4eefb1b16acaa69bd757057e0c54c58f11577ba3 ]

The current axgbe code assumes that offset 6 of EEPROM SFP DAC (passive)
cables is NULL. However, some cables (the 5 meter and 7 meter Molex
passive cables) have non-zero data at offset 6. Fix the logic by moving
the passive cable check above the active checks, so as not to be
improperly identified as an active cable. This will fix the issue for
any passive cable that advertises 1000Base-CX in offset 6.

Without the fix the user will not get link UP for few DAC cables.

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_phy_impl.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index 040176b8ef..9aadbefaba 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -625,7 +625,10 @@ static void axgbe_phy_sfp_parse_eeprom(struct axgbe_port *pdata)
 	}
 
 	/* Determine the type of SFP */
-	if (sfp_base[AXGBE_SFP_BASE_10GBE_CC] & AXGBE_SFP_BASE_10GBE_CC_SR)
+	if (phy_data->sfp_cable == AXGBE_SFP_CABLE_PASSIVE &&
+		 axgbe_phy_sfp_bit_rate(sfp_eeprom, AXGBE_SFP_SPEED_10000))
+		phy_data->sfp_base = AXGBE_SFP_BASE_10000_CR;
+	else if (sfp_base[AXGBE_SFP_BASE_10GBE_CC] & AXGBE_SFP_BASE_10GBE_CC_SR)
 		phy_data->sfp_base = AXGBE_SFP_BASE_10000_SR;
 	else if (sfp_base[AXGBE_SFP_BASE_10GBE_CC] & AXGBE_SFP_BASE_10GBE_CC_LR)
 		phy_data->sfp_base = AXGBE_SFP_BASE_10000_LR;
@@ -642,9 +645,6 @@ static void axgbe_phy_sfp_parse_eeprom(struct axgbe_port *pdata)
 		phy_data->sfp_base = AXGBE_SFP_BASE_1000_CX;
 	else if (sfp_base[AXGBE_SFP_BASE_1GBE_CC] & AXGBE_SFP_BASE_1GBE_CC_T)
 		phy_data->sfp_base = AXGBE_SFP_BASE_1000_T;
-	else if ((phy_data->sfp_cable == AXGBE_SFP_CABLE_PASSIVE) &&
-		 axgbe_phy_sfp_bit_rate(sfp_eeprom, AXGBE_SFP_SPEED_10000))
-		phy_data->sfp_base = AXGBE_SFP_BASE_10000_CR;
 
 	switch (phy_data->sfp_base) {
 	case AXGBE_SFP_BASE_1000_T:
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.388135617 +0100
+++ 0029-net-axgbe-fix-SFP-codes-check-for-DAC-cables.patch	2024-06-25 00:22:13.121184344 +0100
@@ -1 +1 @@
-From 4eefb1b16acaa69bd757057e0c54c58f11577ba3 Mon Sep 17 00:00:00 2001
+From 39527c017d64fc66cd911281f65ec93927adb6a2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4eefb1b16acaa69bd757057e0c54c58f11577ba3 ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -25 +26 @@
-index bcefbf28f2..10196cae94 100644
+index 040176b8ef..9aadbefaba 100644

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

* patch 'net/axgbe: fix connection for SFP+ active cables' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (27 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: fix SFP codes check for DAC cables' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: check only minimum speed for " luca.boccassi
                   ` (50 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/73e8b7893e102f3c4d01dd7b510b1c64e3e6171f

Thanks.

Luca Boccassi

---
From 73e8b7893e102f3c4d01dd7b510b1c64e3e6171f Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:41 +0530
Subject: [PATCH] net/axgbe: fix connection for SFP+ active cables

[ upstream commit 4823ccdbbd887bb84339a4d35febd92292d07b97 ]

SFP+ active and passive cables are copper cables with fixed SFP+ end
connectors. Due to a misinterpretation of this, SFP+ active cables could
end up not being recognized, causing the driver to fail to establish a
connection.

Introduce a new enum in SFP+ cable types, XGBE_SFP_CABLE_FIBER, that is
the default cable type, and handle active and passive cables when they
are specifically detected.

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_phy_impl.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index 9aadbefaba..85b01bfa10 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -69,6 +69,7 @@ enum axgbe_sfp_cable {
 	AXGBE_SFP_CABLE_UNKNOWN = 0,
 	AXGBE_SFP_CABLE_ACTIVE,
 	AXGBE_SFP_CABLE_PASSIVE,
+	AXGBE_SFP_CABLE_FIBER,
 };
 
 enum axgbe_sfp_base {
@@ -616,16 +617,18 @@ static void axgbe_phy_sfp_parse_eeprom(struct axgbe_port *pdata)
 
 	axgbe_phy_sfp_parse_quirks(pdata);
 
-	/* Assume ACTIVE cable unless told it is PASSIVE */
+	/* Assume FIBER cable unless told otherwise */
 	if (sfp_base[AXGBE_SFP_BASE_CABLE] & AXGBE_SFP_BASE_CABLE_PASSIVE) {
 		phy_data->sfp_cable = AXGBE_SFP_CABLE_PASSIVE;
 		phy_data->sfp_cable_len = sfp_base[AXGBE_SFP_BASE_CU_CABLE_LEN];
-	} else {
+	} else if (sfp_base[AXGBE_SFP_BASE_CABLE] & AXGBE_SFP_BASE_CABLE_ACTIVE) {
 		phy_data->sfp_cable = AXGBE_SFP_CABLE_ACTIVE;
+	} else {
+		phy_data->sfp_cable = AXGBE_SFP_CABLE_FIBER;
 	}
 
 	/* Determine the type of SFP */
-	if (phy_data->sfp_cable == AXGBE_SFP_CABLE_PASSIVE &&
+	if (phy_data->sfp_cable != AXGBE_SFP_CABLE_FIBER &&
 		 axgbe_phy_sfp_bit_rate(sfp_eeprom, AXGBE_SFP_SPEED_10000))
 		phy_data->sfp_base = AXGBE_SFP_BASE_10000_CR;
 	else if (sfp_base[AXGBE_SFP_BASE_10GBE_CC] & AXGBE_SFP_BASE_10GBE_CC_SR)
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.440216439 +0100
+++ 0030-net-axgbe-fix-connection-for-SFP-active-cables.patch	2024-06-25 00:22:13.121184344 +0100
@@ -1 +1 @@
-From 4823ccdbbd887bb84339a4d35febd92292d07b97 Mon Sep 17 00:00:00 2001
+From 73e8b7893e102f3c4d01dd7b510b1c64e3e6171f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4823ccdbbd887bb84339a4d35febd92292d07b97 ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -25 +26 @@
-index 10196cae94..d9585a7404 100644
+index 9aadbefaba..85b01bfa10 100644

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

* patch 'net/axgbe: check only minimum speed for cables' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (28 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: fix connection for SFP+ active " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: fix Tx flow on 30H HW' " luca.boccassi
                   ` (49 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/08c36b23fdd34beefd1421eb552b2c58c43ba52d

Thanks.

Luca Boccassi

---
From 08c36b23fdd34beefd1421eb552b2c58c43ba52d Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:42 +0530
Subject: [PATCH] net/axgbe: check only minimum speed for cables

[ upstream commit b5587a39dc94ee0bd055b515cc8c060923ed69b9 ]

There are cables that exist that can support speeds in excess of 10GbE.
The driver, however, restricts the EEPROM advertised nominal bitrate to
a specific range, which can prevent usage of cables that can support,
for example, up to 25GbE.

Rather than checking that an active or passive cable supports a specific
range, only check for a minimum supported speed.

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_phy_impl.c | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_phy_impl.c
index 85b01bfa10..12908d4e6f 100644
--- a/drivers/net/axgbe/axgbe_phy_impl.c
+++ b/drivers/net/axgbe/axgbe_phy_impl.c
@@ -117,9 +117,7 @@ enum axgbe_sfp_speed {
 
 #define AXGBE_SFP_BASE_BR			12
 #define AXGBE_SFP_BASE_BR_1GBE_MIN		0x0a
-#define AXGBE_SFP_BASE_BR_1GBE_MAX		0x0d
 #define AXGBE_SFP_BASE_BR_10GBE_MIN		0x64
-#define AXGBE_SFP_BASE_BR_10GBE_MAX		0x68
 
 #define AXGBE_SFP_BASE_CU_CABLE_LEN		18
 
@@ -536,25 +534,22 @@ static void axgbe_phy_sfp_phy_settings(struct axgbe_port *pdata)
 static bool axgbe_phy_sfp_bit_rate(struct axgbe_sfp_eeprom *sfp_eeprom,
 				   enum axgbe_sfp_speed sfp_speed)
 {
-	u8 *sfp_base, min, max;
+	u8 *sfp_base, min;
 
 	sfp_base = sfp_eeprom->base;
 
 	switch (sfp_speed) {
 	case AXGBE_SFP_SPEED_1000:
 		min = AXGBE_SFP_BASE_BR_1GBE_MIN;
-		max = AXGBE_SFP_BASE_BR_1GBE_MAX;
 		break;
 	case AXGBE_SFP_SPEED_10000:
 		min = AXGBE_SFP_BASE_BR_10GBE_MIN;
-		max = AXGBE_SFP_BASE_BR_10GBE_MAX;
 		break;
 	default:
 		return false;
 	}
 
-	return ((sfp_base[AXGBE_SFP_BASE_BR] >= min) &&
-		(sfp_base[AXGBE_SFP_BASE_BR] <= max));
+	return sfp_base[AXGBE_SFP_BASE_BR] >= min;
 }
 
 static void axgbe_phy_sfp_external_phy(struct axgbe_port *pdata)
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.492206733 +0100
+++ 0031-net-axgbe-check-only-minimum-speed-for-cables.patch	2024-06-25 00:22:13.125184426 +0100
@@ -1 +1 @@
-From b5587a39dc94ee0bd055b515cc8c060923ed69b9 Mon Sep 17 00:00:00 2001
+From 08c36b23fdd34beefd1421eb552b2c58c43ba52d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b5587a39dc94ee0bd055b515cc8c060923ed69b9 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -24 +25 @@
-index d9585a7404..b6a2a084aa 100644
+index 85b01bfa10..12908d4e6f 100644

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

* patch 'net/axgbe: fix Tx flow on 30H HW' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (29 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: check only minimum speed for " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: delay AN timeout during KR training' " luca.boccassi
                   ` (48 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/59767090cb7af04ec5fbdc8a443cd3da13f0207c

Thanks.

Luca Boccassi

---
From 59767090cb7af04ec5fbdc8a443cd3da13f0207c Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:43 +0530
Subject: [PATCH] net/axgbe: fix Tx flow on 30H HW

[ upstream commit b4b24f3e80f9b1bd2c56e1b56b8b8337748e15e6 ]

There is difference in the TX Flow Control registers (TFCR) between the
revisions of the hardware. The older revisions of hardware used to have
single register per queue. Whereas, the newer revision of hardware (from
ver 30H onwards) have one register per priority.

Without the fix the user will face problem in TX operation on new 30H HW

Fixes: 7c4158a5b592 ("net/axgbe: add DMA programming and start/stop")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_dev.c | 25 +++++++++++++++----------
 1 file changed, 15 insertions(+), 10 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_dev.c b/drivers/net/axgbe/axgbe_dev.c
index 9b0073eea6..5233633a53 100644
--- a/drivers/net/axgbe/axgbe_dev.c
+++ b/drivers/net/axgbe/axgbe_dev.c
@@ -269,20 +269,28 @@ static int axgbe_set_speed(struct axgbe_port *pdata, int speed)
 	return 0;
 }
 
+static unsigned int axgbe_get_fc_queue_count(struct axgbe_port *pdata)
+{
+	unsigned int max_q_count = AXGMAC_MAX_FLOW_CONTROL_QUEUES;
+
+	/* From MAC ver 30H the TFCR is per priority, instead of per queue */
+	if (AXGMAC_GET_BITS(pdata->hw_feat.version, MAC_VR, SNPSVER) >= 0x30)
+		return max_q_count;
+	else
+		return (RTE_MIN(pdata->tx_q_count, max_q_count));
+}
+
 static int axgbe_disable_tx_flow_control(struct axgbe_port *pdata)
 {
-	unsigned int max_q_count, q_count;
 	unsigned int reg, reg_val;
-	unsigned int i;
+	unsigned int i, q_count;
 
 	/* Clear MTL flow control */
 	for (i = 0; i < pdata->rx_q_count; i++)
 		AXGMAC_MTL_IOWRITE_BITS(pdata, i, MTL_Q_RQOMR, EHFC, 0);
 
 	/* Clear MAC flow control */
-	max_q_count = AXGMAC_MAX_FLOW_CONTROL_QUEUES;
-	q_count = RTE_MIN(pdata->tx_q_count,
-			max_q_count);
+	q_count = axgbe_get_fc_queue_count(pdata);
 	reg = MAC_Q0TFCR;
 	for (i = 0; i < q_count; i++) {
 		reg_val = AXGMAC_IOREAD(pdata, reg);
@@ -297,9 +305,8 @@ static int axgbe_disable_tx_flow_control(struct axgbe_port *pdata)
 
 static int axgbe_enable_tx_flow_control(struct axgbe_port *pdata)
 {
-	unsigned int max_q_count, q_count;
 	unsigned int reg, reg_val;
-	unsigned int i;
+	unsigned int i, q_count;
 
 	/* Set MTL flow control */
 	for (i = 0; i < pdata->rx_q_count; i++) {
@@ -316,9 +323,7 @@ static int axgbe_enable_tx_flow_control(struct axgbe_port *pdata)
 	}
 
 	/* Set MAC flow control */
-	max_q_count = AXGMAC_MAX_FLOW_CONTROL_QUEUES;
-	q_count = RTE_MIN(pdata->tx_q_count,
-			max_q_count);
+	q_count = axgbe_get_fc_queue_count(pdata);
 	reg = MAC_Q0TFCR;
 	for (i = 0; i < q_count; i++) {
 		reg_val = AXGMAC_IOREAD(pdata, reg);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.544399094 +0100
+++ 0032-net-axgbe-fix-Tx-flow-on-30H-HW.patch	2024-06-25 00:22:13.125184426 +0100
@@ -1 +1 @@
-From b4b24f3e80f9b1bd2c56e1b56b8b8337748e15e6 Mon Sep 17 00:00:00 2001
+From 59767090cb7af04ec5fbdc8a443cd3da13f0207c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b4b24f3e80f9b1bd2c56e1b56b8b8337748e15e6 ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org

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

* patch 'net/axgbe: delay AN timeout during KR training' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (30 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: fix Tx flow on 30H HW' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/axgbe: fix linkup in PHY status' " luca.boccassi
                   ` (47 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/e8615db99073af9bc4b4a1af9dbd1b051d2d54d8

Thanks.

Luca Boccassi

---
From e8615db99073af9bc4b4a1af9dbd1b051d2d54d8 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:44 +0530
Subject: [PATCH] net/axgbe: delay AN timeout during KR training

[ upstream commit 323e8c91a7c434915920fe8668ca5664b65ea198 ]

AN restart triggered during KR training not only aborts the KR training
process but also move the HW to unstable state. Driver has to wait up to
500ms or until the KR training is completed before restarting AN cycle.

Without the fix the user will face KR training failure issues.

Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_ethdev.h |  2 ++
 drivers/net/axgbe/axgbe_mdio.c   | 25 +++++++++++++++++++++++++
 2 files changed, 27 insertions(+)

diff --git a/drivers/net/axgbe/axgbe_ethdev.h b/drivers/net/axgbe/axgbe_ethdev.h
index ae57aeaa00..b4bd56e239 100644
--- a/drivers/net/axgbe/axgbe_ethdev.h
+++ b/drivers/net/axgbe/axgbe_ethdev.h
@@ -111,6 +111,7 @@
 /* Auto-negotiation */
 #define AXGBE_AN_MS_TIMEOUT		500
 #define AXGBE_LINK_TIMEOUT		5
+#define AXGBE_KR_TRAINING_WAIT_ITER	50
 
 #define AXGBE_SGMII_AN_LINK_STATUS	BIT(1)
 #define AXGBE_SGMII_AN_LINK_SPEED	(BIT(2) | BIT(3))
@@ -654,6 +655,7 @@ struct axgbe_port {
 	unsigned int parallel_detect;
 	unsigned int fec_ability;
 	unsigned long an_start;
+	unsigned long kr_start_time;
 	enum axgbe_an_mode an_mode;
 
 	/* I2C support */
diff --git a/drivers/net/axgbe/axgbe_mdio.c b/drivers/net/axgbe/axgbe_mdio.c
index b03bc471cb..e1a737cf62 100644
--- a/drivers/net/axgbe/axgbe_mdio.c
+++ b/drivers/net/axgbe/axgbe_mdio.c
@@ -357,6 +357,7 @@ static enum axgbe_an axgbe_an73_tx_training(struct axgbe_port *pdata,
 	reg |= AXGBE_KR_TRAINING_ENABLE;
 	reg |= AXGBE_KR_TRAINING_START;
 	XMDIO_WRITE(pdata, MDIO_MMD_PMAPMD, MDIO_PMA_10GBR_PMD_CTRL, reg);
+	pdata->kr_start_time = rte_get_timer_cycles();
 
 	PMD_DRV_LOG(DEBUG, "KR training initiated\n");
 	if (pdata->phy_if.phy_impl.kr_training_post)
@@ -487,6 +488,7 @@ static enum axgbe_an axgbe_an73_incompat_link(struct axgbe_port *pdata)
 
 	axgbe_an_disable(pdata);
 	axgbe_switch_mode(pdata);
+	pdata->an_result = AXGBE_AN_READY;
 	axgbe_an_restart(pdata);
 
 	return AXGBE_AN_INCOMPAT_LINK;
@@ -967,11 +969,34 @@ static void axgbe_check_link_timeout(struct axgbe_port *pdata)
 {
 	unsigned long link_timeout;
 	unsigned long ticks;
+	unsigned long kr_time;
+	int wait;
 
 	link_timeout = pdata->link_check + (AXGBE_LINK_TIMEOUT *
 					    2 *  rte_get_timer_hz());
 	ticks = rte_get_timer_cycles();
 	if (time_after(ticks, link_timeout)) {
+		if ((axgbe_cur_mode(pdata) == AXGBE_MODE_KR) &&
+		    pdata->phy.autoneg == AUTONEG_ENABLE) {
+			/* AN restart should not happen while KR training is in progress.
+			 * The while loop ensures no AN restart during KR training,
+			 * waits up to 500ms and AN restart is triggered only if KR
+			 * training is failed.
+			 */
+			wait = AXGBE_KR_TRAINING_WAIT_ITER;
+			while (wait--) {
+				kr_time = pdata->kr_start_time +
+					  msecs_to_timer_cycles(AXGBE_AN_MS_TIMEOUT);
+				ticks = rte_get_timer_cycles();
+				if (time_after(ticks, kr_time))
+					break;
+				/* AN restart is not required, if AN result is COMPLETE */
+				if (pdata->an_result == AXGBE_AN_COMPLETE)
+					return;
+				rte_delay_us(10500);
+			}
+		}
+
 		PMD_DRV_LOG(NOTICE, "AN link timeout\n");
 		axgbe_phy_config_aneg(pdata);
 	}
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.595687630 +0100
+++ 0033-net-axgbe-delay-AN-timeout-during-KR-training.patch	2024-06-25 00:22:13.125184426 +0100
@@ -1 +1 @@
-From 323e8c91a7c434915920fe8668ca5664b65ea198 Mon Sep 17 00:00:00 2001
+From e8615db99073af9bc4b4a1af9dbd1b051d2d54d8 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 323e8c91a7c434915920fe8668ca5664b65ea198 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index f122dfd516..d1fac667c2 100644
+index ae57aeaa00..b4bd56e239 100644
@@ -34 +35 @@
-@@ -661,6 +662,7 @@ struct axgbe_port {
+@@ -654,6 +655,7 @@ struct axgbe_port {

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

* patch 'net/axgbe: fix linkup in PHY status' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (31 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: delay AN timeout during KR training' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/ice: fix check for outer UDP checksum offload' " luca.boccassi
                   ` (46 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Venkat Kumar Ande; +Cc: Selwin Sebastian, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/ac5a8e2ab5732ba8872f34e2fbb199f10d067400

Thanks.

Luca Boccassi

---
From ac5a8e2ab5732ba8872f34e2fbb199f10d067400 Mon Sep 17 00:00:00 2001
From: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Date: Tue, 4 Jun 2024 17:41:45 +0530
Subject: [PATCH] net/axgbe: fix linkup in PHY status

[ upstream commit 50362d0e1f386563a026b314bd0a7eedcd188910 ]

In the event of a change in axgbe mode, the current auto-negotiation
needs to be reset and the AN cycle needs to be re-triggered. However,
the current code ignores the return value of axgbe_set_mode(), leading
to false information as the link is declared without checking the status
register.

Fix this by propagating the mode switch status information to
axgbe_phy_status().

Fixes: 102b6ec3d5c3 ("net/axgbe: support auto-negotiation for 1Gbps")

Signed-off-by: Venkat Kumar Ande <venkatkumar.ande@amd.com>
Acked-by: Selwin Sebastian <selwin.sebastian@amd.com>
---
 drivers/net/axgbe/axgbe_mdio.c | 17 ++++++++++++-----
 1 file changed, 12 insertions(+), 5 deletions(-)

diff --git a/drivers/net/axgbe/axgbe_mdio.c b/drivers/net/axgbe/axgbe_mdio.c
index e1a737cf62..d95a52659e 100644
--- a/drivers/net/axgbe/axgbe_mdio.c
+++ b/drivers/net/axgbe/axgbe_mdio.c
@@ -200,13 +200,14 @@ static void axgbe_switch_mode(struct axgbe_port *pdata)
 	axgbe_change_mode(pdata, pdata->phy_if.phy_impl.switch_mode(pdata));
 }
 
-static void axgbe_set_mode(struct axgbe_port *pdata,
+static bool axgbe_set_mode(struct axgbe_port *pdata,
 			   enum axgbe_mode mode)
 {
 	if (mode == axgbe_cur_mode(pdata))
-		return;
+		return false;
 
 	axgbe_change_mode(pdata, mode);
+	return true;
 }
 
 static bool axgbe_use_mode(struct axgbe_port *pdata,
@@ -1007,7 +1008,7 @@ static enum axgbe_mode axgbe_phy_status_aneg(struct axgbe_port *pdata)
 	return pdata->phy_if.phy_impl.an_outcome(pdata);
 }
 
-static void axgbe_phy_status_result(struct axgbe_port *pdata)
+static bool axgbe_phy_status_result(struct axgbe_port *pdata)
 {
 	enum axgbe_mode mode;
 
@@ -1041,7 +1042,10 @@ static void axgbe_phy_status_result(struct axgbe_port *pdata)
 
 	pdata->phy.duplex = DUPLEX_FULL;
 
-	axgbe_set_mode(pdata, mode);
+	if (axgbe_set_mode(pdata, mode))
+		return true;
+	else
+		return false;
 }
 
 static int autoneg_time_out(unsigned long autoneg_start_time)
@@ -1108,7 +1112,10 @@ static void axgbe_phy_status(struct axgbe_port *pdata)
 				return;
 			}
 		}
-		axgbe_phy_status_result(pdata);
+
+		if (axgbe_phy_status_result(pdata))
+			return;
+
 		if (rte_bit_relaxed_get32(AXGBE_LINK_INIT, &pdata->dev_state))
 			rte_bit_relaxed_clear32(AXGBE_LINK_INIT,
 						&pdata->dev_state);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.647808194 +0100
+++ 0034-net-axgbe-fix-linkup-in-PHY-status.patch	2024-06-25 00:22:13.125184426 +0100
@@ -1 +1 @@
-From 50362d0e1f386563a026b314bd0a7eedcd188910 Mon Sep 17 00:00:00 2001
+From ac5a8e2ab5732ba8872f34e2fbb199f10d067400 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 50362d0e1f386563a026b314bd0a7eedcd188910 ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org

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

* patch 'net/ice: fix check for outer UDP checksum offload' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (32 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/axgbe: fix linkup in PHY status' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'app/testpmd: fix outer IP " luca.boccassi
                   ` (45 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: David Marchand
  Cc: Bruce Richardson, Morten Brørup, Ali Alnubani, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/e48c8875998c04dbc83065bbed8139b74a26a16c

Thanks.

Luca Boccassi

---
From e48c8875998c04dbc83065bbed8139b74a26a16c Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 18 Apr 2024 10:20:15 +0200
Subject: [PATCH] net/ice: fix check for outer UDP checksum offload
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit f4eb07f031c4a6a0055f3b2773e031cd8000206e ]

ICE_TX_CTX_EIPT_NONE == 0.
There is a good chance that !(anything & 0) is true :-).

While removing this noop check is doable, let's check that the
descriptor does contain a outer ip type.

Fixes: 2ed011776334 ("net/ice: fix outer UDP Tx checksum offload")

Signed-off-by: David Marchand <david.marchand@redhat.com>
Reviewed-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
---
 drivers/net/ice/ice_rxtx.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c
index 9a653cbc4a..f73065b81c 100644
--- a/drivers/net/ice/ice_rxtx.c
+++ b/drivers/net/ice/ice_rxtx.c
@@ -2733,9 +2733,9 @@ ice_parse_tunneling_params(uint64_t ol_flags,
 	 * Calculate the tunneling UDP checksum.
 	 * Shall be set only if L4TUNT = 01b and EIPT is not zero
 	 */
-	if (!(*cd_tunneling & ICE_TX_CTX_EIPT_NONE) &&
-		(*cd_tunneling & ICE_TXD_CTX_UDP_TUNNELING) &&
-		(ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM))
+	if ((*cd_tunneling & ICE_TXD_CTX_QW0_EIPT_M) &&
+			(*cd_tunneling & ICE_TXD_CTX_UDP_TUNNELING) &&
+			(ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM))
 		*cd_tunneling |= ICE_TXD_CTX_QW0_L4T_CS_M;
 }
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.698246281 +0100
+++ 0035-net-ice-fix-check-for-outer-UDP-checksum-offload.patch	2024-06-25 00:22:13.129184507 +0100
@@ -1 +1 @@
-From f4eb07f031c4a6a0055f3b2773e031cd8000206e Mon Sep 17 00:00:00 2001
+From e48c8875998c04dbc83065bbed8139b74a26a16c Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit f4eb07f031c4a6a0055f3b2773e031cd8000206e ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -27 +28 @@
-index 95a2db3432..10babab231 100644
+index 9a653cbc4a..f73065b81c 100644
@@ -30 +31 @@
-@@ -2751,9 +2751,9 @@ ice_parse_tunneling_params(uint64_t ol_flags,
+@@ -2733,9 +2733,9 @@ ice_parse_tunneling_params(uint64_t ol_flags,

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

* patch 'app/testpmd: fix outer IP checksum offload' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (33 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/ice: fix check for outer UDP checksum offload' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net: fix outer UDP checksum in Intel prepare helper' " luca.boccassi
                   ` (44 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: David Marchand; +Cc: Ferruh Yigit, Ali Alnubani, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/0c72bf4c1d8e1382545da4a2b55dfcaa632b0ce3

Thanks.

Luca Boccassi

---
From 0c72bf4c1d8e1382545da4a2b55dfcaa632b0ce3 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 18 Apr 2024 10:20:17 +0200
Subject: [PATCH] app/testpmd: fix outer IP checksum offload

[ upstream commit b9d859d8a671ec4516face2eba24434b955a9ac1 ]

Resetting the outer IP checksum to 0 is not something mandated by the
mbuf API and is done by rte_eth_tx_prepare(), or per driver if needed.

Fixes: 4fb7e803eb1a ("ethdev: add Tx preparation")

Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
---
 app/test-pmd/csumonly.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c
index 6170728221..bfe1fc3ddc 100644
--- a/app/test-pmd/csumonly.c
+++ b/app/test-pmd/csumonly.c
@@ -574,15 +574,17 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
 	uint64_t ol_flags = 0;
 
 	if (info->outer_ethertype == _htons(RTE_ETHER_TYPE_IPV4)) {
-		ipv4_hdr->hdr_checksum = 0;
 		ol_flags |= RTE_MBUF_F_TX_OUTER_IPV4;
 
-		if (tx_offloads	& RTE_ETH_TX_OFFLOAD_OUTER_IPV4_CKSUM)
+		if (tx_offloads	& RTE_ETH_TX_OFFLOAD_OUTER_IPV4_CKSUM) {
 			ol_flags |= RTE_MBUF_F_TX_OUTER_IP_CKSUM;
-		else
+		} else {
+			ipv4_hdr->hdr_checksum = 0;
 			ipv4_hdr->hdr_checksum = rte_ipv4_cksum(ipv4_hdr);
-	} else
+		}
+	} else {
 		ol_flags |= RTE_MBUF_F_TX_OUTER_IPV6;
+	}
 
 	if (info->outer_l4_proto != IPPROTO_UDP)
 		return ol_flags;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.769222946 +0100
+++ 0036-app-testpmd-fix-outer-IP-checksum-offload.patch	2024-06-25 00:22:13.129184507 +0100
@@ -1 +1 @@
-From b9d859d8a671ec4516face2eba24434b955a9ac1 Mon Sep 17 00:00:00 2001
+From 0c72bf4c1d8e1382545da4a2b55dfcaa632b0ce3 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b9d859d8a671ec4516face2eba24434b955a9ac1 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 6711dda42e..f5125c2788 100644
+index 6170728221..bfe1fc3ddc 100644
@@ -23 +24 @@
-@@ -583,15 +583,17 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
+@@ -574,15 +574,17 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,

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

* patch 'net: fix outer UDP checksum in Intel prepare helper' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (34 preceding siblings ...)
  2024-06-24 23:58 ` patch 'app/testpmd: fix outer IP " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/i40e: fix outer UDP checksum offload for X710' " luca.boccassi
                   ` (43 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: David Marchand; +Cc: Ali Alnubani, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/b5fc38d53c9b4f682e0dd433063db14faaa6ae63

Thanks.

Luca Boccassi

---
From b5fc38d53c9b4f682e0dd433063db14faaa6ae63 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 18 Apr 2024 10:20:18 +0200
Subject: [PATCH] net: fix outer UDP checksum in Intel prepare helper

[ upstream commit f876dbef080932dbeb1de075d7ca3cbe2ed6d7eb ]

Setting a pseudo header checksum in the outer UDP checksum is a Intel
(and some other vendors) requirement.
Applications (like OVS) requesting outer UDP checksum without doing this
extra setup have broken outer UDP checksums.

Move this specific setup from testpmd to the "common" helper
rte_net_intel_cksum_flags_prepare().

net/hns3 can then be adjusted.

Bugzilla ID: 1406
Fixes: d8e5e69f3a9b ("app/testpmd: add GTP parsing and Tx checksum offload")

Signed-off-by: David Marchand <david.marchand@redhat.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
---
 app/test-pmd/csumonly.c      | 11 +----
 drivers/net/hns3/hns3_rxtx.c | 93 ++++++++++--------------------------
 lib/net/rte_net.h            | 17 ++++++-
 3 files changed, 43 insertions(+), 78 deletions(-)

diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c
index bfe1fc3ddc..161bbd4e14 100644
--- a/app/test-pmd/csumonly.c
+++ b/app/test-pmd/csumonly.c
@@ -568,8 +568,6 @@ static uint64_t
 process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
 	uint64_t tx_offloads, int tso_enabled, struct rte_mbuf *m)
 {
-	struct rte_ipv4_hdr *ipv4_hdr = outer_l3_hdr;
-	struct rte_ipv6_hdr *ipv6_hdr = outer_l3_hdr;
 	struct rte_udp_hdr *udp_hdr;
 	uint64_t ol_flags = 0;
 
@@ -579,6 +577,8 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
 		if (tx_offloads	& RTE_ETH_TX_OFFLOAD_OUTER_IPV4_CKSUM) {
 			ol_flags |= RTE_MBUF_F_TX_OUTER_IP_CKSUM;
 		} else {
+			struct rte_ipv4_hdr *ipv4_hdr = outer_l3_hdr;
+
 			ipv4_hdr->hdr_checksum = 0;
 			ipv4_hdr->hdr_checksum = rte_ipv4_cksum(ipv4_hdr);
 		}
@@ -597,13 +597,6 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
 
 	/* Skip SW outer UDP checksum generation if HW supports it */
 	if (tx_offloads & RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM) {
-		if (info->outer_ethertype == _htons(RTE_ETHER_TYPE_IPV4))
-			udp_hdr->dgram_cksum
-				= rte_ipv4_phdr_cksum(ipv4_hdr, ol_flags);
-		else
-			udp_hdr->dgram_cksum
-				= rte_ipv6_phdr_cksum(ipv6_hdr, ol_flags);
-
 		ol_flags |= RTE_MBUF_F_TX_OUTER_UDP_CKSUM;
 		return ol_flags;
 	}
diff --git a/drivers/net/hns3/hns3_rxtx.c b/drivers/net/hns3/hns3_rxtx.c
index c0479a44dc..4343a3e4df 100644
--- a/drivers/net/hns3/hns3_rxtx.c
+++ b/drivers/net/hns3/hns3_rxtx.c
@@ -3627,58 +3627,6 @@ hns3_pkt_need_linearized(struct rte_mbuf *tx_pkts, uint32_t bd_num,
 	return false;
 }
 
-static bool
-hns3_outer_ipv4_cksum_prepared(struct rte_mbuf *m, uint64_t ol_flags,
-				uint32_t *l4_proto)
-{
-	struct rte_ipv4_hdr *ipv4_hdr;
-	ipv4_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv4_hdr *,
-					   m->outer_l2_len);
-	if (ol_flags & RTE_MBUF_F_TX_OUTER_IP_CKSUM)
-		ipv4_hdr->hdr_checksum = 0;
-	if (ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM) {
-		struct rte_udp_hdr *udp_hdr;
-		/*
-		 * If OUTER_UDP_CKSUM is support, HW can calculate the pseudo
-		 * header for TSO packets
-		 */
-		if (ol_flags & RTE_MBUF_F_TX_TCP_SEG)
-			return true;
-		udp_hdr = rte_pktmbuf_mtod_offset(m, struct rte_udp_hdr *,
-				m->outer_l2_len + m->outer_l3_len);
-		udp_hdr->dgram_cksum = rte_ipv4_phdr_cksum(ipv4_hdr, ol_flags);
-
-		return true;
-	}
-	*l4_proto = ipv4_hdr->next_proto_id;
-	return false;
-}
-
-static bool
-hns3_outer_ipv6_cksum_prepared(struct rte_mbuf *m, uint64_t ol_flags,
-				uint32_t *l4_proto)
-{
-	struct rte_ipv6_hdr *ipv6_hdr;
-	ipv6_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv6_hdr *,
-					   m->outer_l2_len);
-	if (ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM) {
-		struct rte_udp_hdr *udp_hdr;
-		/*
-		 * If OUTER_UDP_CKSUM is support, HW can calculate the pseudo
-		 * header for TSO packets
-		 */
-		if (ol_flags & RTE_MBUF_F_TX_TCP_SEG)
-			return true;
-		udp_hdr = rte_pktmbuf_mtod_offset(m, struct rte_udp_hdr *,
-				m->outer_l2_len + m->outer_l3_len);
-		udp_hdr->dgram_cksum = rte_ipv6_phdr_cksum(ipv6_hdr, ol_flags);
-
-		return true;
-	}
-	*l4_proto = ipv6_hdr->proto;
-	return false;
-}
-
 static void
 hns3_outer_header_cksum_prepare(struct rte_mbuf *m)
 {
@@ -3686,29 +3634,38 @@ hns3_outer_header_cksum_prepare(struct rte_mbuf *m)
 	uint32_t paylen, hdr_len, l4_proto;
 	struct rte_udp_hdr *udp_hdr;
 
-	if (!(ol_flags & (RTE_MBUF_F_TX_OUTER_IPV4 | RTE_MBUF_F_TX_OUTER_IPV6)))
+	if (!(ol_flags & (RTE_MBUF_F_TX_OUTER_IPV4 | RTE_MBUF_F_TX_OUTER_IPV6)) &&
+			((ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM) ||
+			!(ol_flags & RTE_MBUF_F_TX_TCP_SEG)))
 		return;
 
 	if (ol_flags & RTE_MBUF_F_TX_OUTER_IPV4) {
-		if (hns3_outer_ipv4_cksum_prepared(m, ol_flags, &l4_proto))
-			return;
+		struct rte_ipv4_hdr *ipv4_hdr;
+
+		ipv4_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv4_hdr *,
+			m->outer_l2_len);
+		l4_proto = ipv4_hdr->next_proto_id;
 	} else {
-		if (hns3_outer_ipv6_cksum_prepared(m, ol_flags, &l4_proto))
-			return;
+		struct rte_ipv6_hdr *ipv6_hdr;
+
+		ipv6_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv6_hdr *,
+					   m->outer_l2_len);
+		l4_proto = ipv6_hdr->proto;
 	}
 
+	if (l4_proto != IPPROTO_UDP)
+		return;
+
 	/* driver should ensure the outer udp cksum is 0 for TUNNEL TSO */
-	if (l4_proto == IPPROTO_UDP && (ol_flags & RTE_MBUF_F_TX_TCP_SEG)) {
-		hdr_len = m->l2_len + m->l3_len + m->l4_len;
-		hdr_len += m->outer_l2_len + m->outer_l3_len;
-		paylen = m->pkt_len - hdr_len;
-		if (paylen <= m->tso_segsz)
-			return;
-		udp_hdr = rte_pktmbuf_mtod_offset(m, struct rte_udp_hdr *,
-						  m->outer_l2_len +
-						  m->outer_l3_len);
-		udp_hdr->dgram_cksum = 0;
-	}
+	hdr_len = m->l2_len + m->l3_len + m->l4_len;
+	hdr_len += m->outer_l2_len + m->outer_l3_len;
+	paylen = m->pkt_len - hdr_len;
+	if (paylen <= m->tso_segsz)
+		return;
+	udp_hdr = rte_pktmbuf_mtod_offset(m, struct rte_udp_hdr *,
+					  m->outer_l2_len +
+					  m->outer_l3_len);
+	udp_hdr->dgram_cksum = 0;
 }
 
 static int
diff --git a/lib/net/rte_net.h b/lib/net/rte_net.h
index 56611fc8f9..a94f6af717 100644
--- a/lib/net/rte_net.h
+++ b/lib/net/rte_net.h
@@ -121,7 +121,7 @@ rte_net_intel_cksum_flags_prepare(struct rte_mbuf *m, uint64_t ol_flags)
 	 * no offloads are requested.
 	 */
 	if (!(ol_flags & (RTE_MBUF_F_TX_IP_CKSUM | RTE_MBUF_F_TX_L4_MASK | RTE_MBUF_F_TX_TCP_SEG |
-			  RTE_MBUF_F_TX_OUTER_IP_CKSUM)))
+			  RTE_MBUF_F_TX_OUTER_IP_CKSUM | RTE_MBUF_F_TX_OUTER_UDP_CKSUM)))
 		return 0;
 
 	if (ol_flags & (RTE_MBUF_F_TX_OUTER_IPV4 | RTE_MBUF_F_TX_OUTER_IPV6)) {
@@ -135,6 +135,21 @@ rte_net_intel_cksum_flags_prepare(struct rte_mbuf *m, uint64_t ol_flags)
 					struct rte_ipv4_hdr *, m->outer_l2_len);
 			ipv4_hdr->hdr_checksum = 0;
 		}
+		if (ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM) {
+			if (ol_flags & RTE_MBUF_F_TX_OUTER_IPV4) {
+				ipv4_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv4_hdr *,
+					m->outer_l2_len);
+				udp_hdr = (struct rte_udp_hdr *)((char *)ipv4_hdr +
+					m->outer_l3_len);
+				udp_hdr->dgram_cksum = rte_ipv4_phdr_cksum(ipv4_hdr, m->ol_flags);
+			} else {
+				ipv6_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv6_hdr *,
+					m->outer_l2_len);
+				udp_hdr = rte_pktmbuf_mtod_offset(m, struct rte_udp_hdr *,
+					 m->outer_l2_len + m->outer_l3_len);
+				udp_hdr->dgram_cksum = rte_ipv6_phdr_cksum(ipv6_hdr, m->ol_flags);
+			}
+		}
 	}
 
 	/*
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.829676123 +0100
+++ 0037-net-fix-outer-UDP-checksum-in-Intel-prepare-helper.patch	2024-06-25 00:22:13.137184670 +0100
@@ -1 +1 @@
-From f876dbef080932dbeb1de075d7ca3cbe2ed6d7eb Mon Sep 17 00:00:00 2001
+From b5fc38d53c9b4f682e0dd433063db14faaa6ae63 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit f876dbef080932dbeb1de075d7ca3cbe2ed6d7eb ]
+
@@ -18 +19,0 @@
-Cc: stable@dpdk.org
@@ -25,2 +26,2 @@
- lib/net/rte_net.h            | 18 ++++++-
- 3 files changed, 44 insertions(+), 78 deletions(-)
+ lib/net/rte_net.h            | 17 ++++++-
+ 3 files changed, 43 insertions(+), 78 deletions(-)
@@ -29 +30 @@
-index f5125c2788..71add6ca47 100644
+index bfe1fc3ddc..161bbd4e14 100644
@@ -32 +33 @@
-@@ -577,8 +577,6 @@ static uint64_t
+@@ -568,8 +568,6 @@ static uint64_t
@@ -41 +42 @@
-@@ -588,6 +586,8 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
+@@ -579,6 +577,8 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
@@ -50 +51 @@
-@@ -608,13 +608,6 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
+@@ -597,13 +597,6 @@ process_outer_cksums(void *outer_l3_hdr, struct testpmd_offload_info *info,
@@ -65 +66 @@
-index bf10da1928..59a95aba7c 100644
+index c0479a44dc..4343a3e4df 100644
@@ -68 +69 @@
-@@ -3629,58 +3629,6 @@ hns3_pkt_need_linearized(struct rte_mbuf *tx_pkts, uint32_t bd_num,
+@@ -3627,58 +3627,6 @@ hns3_pkt_need_linearized(struct rte_mbuf *tx_pkts, uint32_t bd_num,
@@ -127 +128 @@
-@@ -3688,29 +3636,38 @@ hns3_outer_header_cksum_prepare(struct rte_mbuf *m)
+@@ -3686,29 +3634,38 @@ hns3_outer_header_cksum_prepare(struct rte_mbuf *m)
@@ -183 +184 @@
-index ef3ff4c6fd..efd9d5f5ee 100644
+index 56611fc8f9..a94f6af717 100644
@@ -186 +187 @@
-@@ -121,7 +121,8 @@ rte_net_intel_cksum_flags_prepare(struct rte_mbuf *m, uint64_t ol_flags)
+@@ -121,7 +121,7 @@ rte_net_intel_cksum_flags_prepare(struct rte_mbuf *m, uint64_t ol_flags)
@@ -190,3 +191,2 @@
--					RTE_MBUF_F_TX_UDP_SEG | RTE_MBUF_F_TX_OUTER_IP_CKSUM)))
-+					RTE_MBUF_F_TX_UDP_SEG | RTE_MBUF_F_TX_OUTER_IP_CKSUM |
-+					RTE_MBUF_F_TX_OUTER_UDP_CKSUM)))
+-			  RTE_MBUF_F_TX_OUTER_IP_CKSUM)))
++			  RTE_MBUF_F_TX_OUTER_IP_CKSUM | RTE_MBUF_F_TX_OUTER_UDP_CKSUM)))
@@ -196 +196 @@
-@@ -135,6 +136,21 @@ rte_net_intel_cksum_flags_prepare(struct rte_mbuf *m, uint64_t ol_flags)
+@@ -135,6 +135,21 @@ rte_net_intel_cksum_flags_prepare(struct rte_mbuf *m, uint64_t ol_flags)

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

* patch 'net/i40e: fix outer UDP checksum offload for X710' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (35 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net: fix outer UDP checksum in Intel prepare helper' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/iavf: remove outer UDP checksum offload for X710 VF' " luca.boccassi
                   ` (42 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: David Marchand; +Cc: Jun Wang, Ali Alnubani, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/9d02109d19544e9834902cdf7964165e25cc75f2

Thanks.

Luca Boccassi

---
From 9d02109d19544e9834902cdf7964165e25cc75f2 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 18 Apr 2024 10:20:19 +0200
Subject: [PATCH] net/i40e: fix outer UDP checksum offload for X710

[ upstream commit 6b5e31f7fbd71675c8f3f6d8c0f74fd1f3a0dff5 ]

According to the X710 datasheet (and confirmed on the field..), X710
devices do not support outer checksum offload.

"""
8.4.4.2 Transmit L3 and L4 Integrity Offload

Tunneling UDP headers and GRE header are not offloaded while the
X710/XXV710/XL710 leaves their checksum field as is.
If a checksum is required, software should provide it as well as the inner
checksum value(s) that are required for the outer checksum.
"""

Fix Tx offload capabilities according to the hardware.

X722 may support such offload by setting I40E_TXD_CTX_QW0_L4T_CS_MASK.

Bugzilla ID: 1406
Fixes: 8cc79a1636cd ("net/i40e: fix forward outer IPv6 VXLAN")

Reported-by: Jun Wang <junwang01@cestc.cn>
Signed-off-by: David Marchand <david.marchand@redhat.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
---
 .mailmap                       | 1 +
 drivers/net/i40e/i40e_ethdev.c | 6 +++++-
 drivers/net/i40e/i40e_rxtx.c   | 9 +++++++++
 3 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/.mailmap b/.mailmap
index 172e7f2692..8aca0a656e 100644
--- a/.mailmap
+++ b/.mailmap
@@ -686,6 +686,7 @@ Junjie Wan <wanjunjie@bytedance.com>
 Jun Qiu <jun.qiu@jaguarmicro.com>
 Jun W Zhou <junx.w.zhou@intel.com>
 Junxiao Shi <git@mail1.yoursunny.com>
+Jun Wang <junwang01@cestc.cn>
 Jun Yang <jun.yang@nxp.com>
 Junyu Jiang <junyux.jiang@intel.com>
 Juraj Linkeš <juraj.linkes@pantheon.tech>
diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 0ff334745d..2049c32c4e 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -3721,8 +3721,12 @@ i40e_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
 		RTE_ETH_TX_OFFLOAD_IPIP_TNL_TSO |
 		RTE_ETH_TX_OFFLOAD_GENEVE_TNL_TSO |
 		RTE_ETH_TX_OFFLOAD_MULTI_SEGS |
-		RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM |
 		dev_info->tx_queue_offload_capa;
+	if (hw->mac.type == I40E_MAC_X722) {
+		dev_info->tx_offload_capa |=
+			RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM;
+	}
+
 	dev_info->dev_capa =
 		RTE_ETH_DEV_CAPA_RUNTIME_RX_QUEUE_SETUP |
 		RTE_ETH_DEV_CAPA_RUNTIME_TX_QUEUE_SETUP;
diff --git a/drivers/net/i40e/i40e_rxtx.c b/drivers/net/i40e/i40e_rxtx.c
index d96bbbb677..6522f2b810 100644
--- a/drivers/net/i40e/i40e_rxtx.c
+++ b/drivers/net/i40e/i40e_rxtx.c
@@ -295,6 +295,15 @@ i40e_parse_tunneling_params(uint64_t ol_flags,
 	 */
 	*cd_tunneling |= (tx_offload.l2_len >> 1) <<
 		I40E_TXD_CTX_QW0_NATLEN_SHIFT;
+
+	/**
+	 * Calculate the tunneling UDP checksum (only supported with X722).
+	 * Shall be set only if L4TUNT = 01b and EIPT is not zero
+	 */
+	if ((*cd_tunneling & I40E_TXD_CTX_QW0_EXT_IP_MASK) &&
+			(*cd_tunneling & I40E_TXD_CTX_UDP_TUNNELING) &&
+			(ol_flags & RTE_MBUF_F_TX_OUTER_UDP_CKSUM))
+		*cd_tunneling |= I40E_TXD_CTX_QW0_L4T_CS_MASK;
 }
 
 static inline void
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.897075093 +0100
+++ 0038-net-i40e-fix-outer-UDP-checksum-offload-for-X710.patch	2024-06-25 00:22:13.153184996 +0100
@@ -1 +1 @@
-From 6b5e31f7fbd71675c8f3f6d8c0f74fd1f3a0dff5 Mon Sep 17 00:00:00 2001
+From 9d02109d19544e9834902cdf7964165e25cc75f2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6b5e31f7fbd71675c8f3f6d8c0f74fd1f3a0dff5 ]
+
@@ -24 +25,0 @@
-Cc: stable@dpdk.org
@@ -36 +37 @@
-index cb8d65bf0e..1aca379558 100644
+index 172e7f2692..8aca0a656e 100644
@@ -39 +40 @@
-@@ -720,6 +720,7 @@ Junjie Wan <wanjunjie@bytedance.com>
+@@ -686,6 +686,7 @@ Junjie Wan <wanjunjie@bytedance.com>
@@ -48 +49 @@
-index 801cc95607..c38515a758 100644
+index 0ff334745d..2049c32c4e 100644
@@ -51 +52 @@
-@@ -3862,8 +3862,12 @@ i40e_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
+@@ -3721,8 +3721,12 @@ i40e_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
@@ -66 +67 @@
-index 155f24377b..dc466ae371 100644
+index d96bbbb677..6522f2b810 100644

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

* patch 'net/iavf: remove outer UDP checksum offload for X710 VF' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (36 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/i40e: fix outer UDP checksum offload for X710' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'app/testpmd: fix lcore ID restriction' " luca.boccassi
                   ` (41 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: David Marchand; +Cc: Ali Alnubani, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/fe02a92fcc01da0abe0429e8c6e0168c0df2d238

Thanks.

Luca Boccassi

---
From fe02a92fcc01da0abe0429e8c6e0168c0df2d238 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 18 Apr 2024 10:20:20 +0200
Subject: [PATCH] net/iavf: remove outer UDP checksum offload for X710 VF

[ upstream commit 032ba1580bc36f31e431cf8d14dd3dec0079fa9c ]

According to the X710 datasheet, X710 devices do not support outer
checksum offload.

"""
8.4.4.2 Transmit L3 and L4 Integrity Offload

Tunneling UDP headers and GRE header are not offloaded while the
X710/XXV710/XL710 leaves their checksum field as is.
If a checksum is required, software should provide it as well as the inner
checksum value(s) that are required for the outer checksum.
"""

Fix Tx offload capabilities depending on the VF type.

Bugzilla ID: 1406
Fixes: f7c8c36fdeb7 ("net/iavf: enable inner and outer Tx checksum offload")

Signed-off-by: David Marchand <david.marchand@redhat.com>
Tested-by: Ali Alnubani <alialnu@nvidia.com>
---
 drivers/net/iavf/iavf_ethdev.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c
index b244d45abb..b6c3cd425d 100644
--- a/drivers/net/iavf/iavf_ethdev.c
+++ b/drivers/net/iavf/iavf_ethdev.c
@@ -1140,7 +1140,6 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
 		RTE_ETH_TX_OFFLOAD_TCP_CKSUM |
 		RTE_ETH_TX_OFFLOAD_SCTP_CKSUM |
 		RTE_ETH_TX_OFFLOAD_OUTER_IPV4_CKSUM |
-		RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM |
 		RTE_ETH_TX_OFFLOAD_TCP_TSO |
 		RTE_ETH_TX_OFFLOAD_VXLAN_TNL_TSO |
 		RTE_ETH_TX_OFFLOAD_GRE_TNL_TSO |
@@ -1149,6 +1148,10 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
 		RTE_ETH_TX_OFFLOAD_MULTI_SEGS |
 		RTE_ETH_TX_OFFLOAD_MBUF_FAST_FREE;
 
+	/* X710 does not support outer udp checksum */
+	if (adapter->hw.mac.type != IAVF_MAC_XL710)
+		dev_info->tx_offload_capa |= RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM;
+
 	if (vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_CRC)
 		dev_info->rx_offload_capa |= RTE_ETH_RX_OFFLOAD_KEEP_CRC;
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:15.972408422 +0100
+++ 0039-net-iavf-remove-outer-UDP-checksum-offload-for-X710-.patch	2024-06-25 00:22:13.153184996 +0100
@@ -1 +1 @@
-From 032ba1580bc36f31e431cf8d14dd3dec0079fa9c Mon Sep 17 00:00:00 2001
+From fe02a92fcc01da0abe0429e8c6e0168c0df2d238 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 032ba1580bc36f31e431cf8d14dd3dec0079fa9c ]
+
@@ -22 +23,0 @@
-Cc: stable@dpdk.org
@@ -27,17 +28,3 @@
- doc/guides/nics/features/iavf.ini | 2 +-
- drivers/net/iavf/iavf_ethdev.c    | 5 ++++-
- 2 files changed, 5 insertions(+), 2 deletions(-)
-
-diff --git a/doc/guides/nics/features/iavf.ini b/doc/guides/nics/features/iavf.ini
-index c59115ae15..ce9860e963 100644
---- a/doc/guides/nics/features/iavf.ini
-+++ b/doc/guides/nics/features/iavf.ini
-@@ -33,7 +33,7 @@ L3 checksum offload  = Y
- L4 checksum offload  = Y
- Timestamp offload    = Y
- Inner L3 checksum    = Y
--Inner L4 checksum    = Y
-+Inner L4 checksum    = P
- Packet type parsing  = Y
- Rx descriptor status = Y
- Tx descriptor status = Y
+ drivers/net/iavf/iavf_ethdev.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
@@ -45 +32 @@
-index 245b3cd854..bbf915097e 100644
+index b244d45abb..b6c3cd425d 100644
@@ -48 +35 @@
-@@ -1174,7 +1174,6 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
+@@ -1140,7 +1140,6 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
@@ -56 +43 @@
-@@ -1183,6 +1182,10 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)
+@@ -1149,6 +1148,10 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info)

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

* patch 'app/testpmd: fix lcore ID restriction' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (37 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/iavf: remove outer UDP checksum offload for X710 VF' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'hash: fix return code description in Doxygen' " luca.boccassi
                   ` (40 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Sivaprasad Tummala; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/a4a27aa3e0f8a870de14f33463180c3b9af4c8de

Thanks.

Luca Boccassi

---
From a4a27aa3e0f8a870de14f33463180c3b9af4c8de Mon Sep 17 00:00:00 2001
From: Sivaprasad Tummala <sivaprasad.tummala@amd.com>
Date: Thu, 6 Jun 2024 11:27:46 +0000
Subject: [PATCH] app/testpmd: fix lcore ID restriction

[ upstream commit 2bf44dd14fa50fa95e090058ec83c2eb96b64ac5 ]

With modern CPUs, it is possible to have higher
CPU count thus we can have higher RTE_MAX_LCORES.
In testpmd application, the current config forwarding
cores option "--nb-cores" is hard limited to 255.

The patch fixes this constraint and also adjusts the lcore
data structure to 32-bit to align with rte lcore APIs.

Fixes: af75078fece3 ("first public release")

Signed-off-by: Sivaprasad Tummala <sivaprasad.tummala@amd.com>
Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
---
 app/test-pmd/config.c     | 4 ++--
 app/test-pmd/parameters.c | 4 ++--
 app/test-pmd/testpmd.h    | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index dca5431b98..1a6d791129 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -4244,9 +4244,9 @@ fwd_stream_on_other_lcores(uint16_t domain_id, lcoreid_t src_lc,
 				continue;
 			printf("Shared Rx queue group %u queue %hu can't be scheduled on different cores:\n",
 			       share_group, share_rxq);
-			printf("  lcore %hhu Port %hu queue %hu\n",
+			printf("  lcore %u Port %hu queue %hu\n",
 			       src_lc, src_port, src_rxq);
-			printf("  lcore %hhu Port %hu queue %hu\n",
+			printf("  lcore %u Port %hu queue %hu\n",
 			       lc_id, fs->rx_port, fs->rx_queue);
 			printf("Please use --nb-cores=%hu to limit number of forwarding cores\n",
 			       nb_rxq);
diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
index 2d0a782ee0..d6f07df789 100644
--- a/app/test-pmd/parameters.c
+++ b/app/test-pmd/parameters.c
@@ -864,8 +864,8 @@ launch_args_parse(int argc, char** argv)
 			}
 			if (!strcmp(lgopts[opt_idx].name, "nb-cores")) {
 				n = atoi(optarg);
-				if (n > 0 && n <= nb_lcores)
-					nb_fwd_lcores = (uint8_t) n;
+				if (n > 0 && (lcoreid_t)n <= nb_lcores)
+					nb_fwd_lcores = (lcoreid_t) n;
 				else
 					rte_exit(EXIT_FAILURE,
 						 "nb-cores should be > 0 and <= %d\n",
diff --git a/app/test-pmd/testpmd.h b/app/test-pmd/testpmd.h
index 022210a7a9..f7f3587c83 100644
--- a/app/test-pmd/testpmd.h
+++ b/app/test-pmd/testpmd.h
@@ -84,7 +84,7 @@ extern volatile uint8_t f_quit;
 /* Maximum number of pools supported per Rx queue */
 #define MAX_MEMPOOL 8
 
-typedef uint8_t  lcoreid_t;
+typedef uint32_t lcoreid_t;
 typedef uint16_t portid_t;
 typedef uint16_t queueid_t;
 typedef uint16_t streamid_t;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.016814195 +0100
+++ 0040-app-testpmd-fix-lcore-ID-restriction.patch	2024-06-25 00:22:13.161185159 +0100
@@ -1 +1 @@
-From 2bf44dd14fa50fa95e090058ec83c2eb96b64ac5 Mon Sep 17 00:00:00 2001
+From a4a27aa3e0f8a870de14f33463180c3b9af4c8de Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 2bf44dd14fa50fa95e090058ec83c2eb96b64ac5 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -26 +27 @@
-index f62ba90c87..66c3a68c1d 100644
+index dca5431b98..1a6d791129 100644
@@ -29 +30 @@
-@@ -4782,9 +4782,9 @@ fwd_stream_on_other_lcores(uint16_t domain_id, lcoreid_t src_lc,
+@@ -4244,9 +4244,9 @@ fwd_stream_on_other_lcores(uint16_t domain_id, lcoreid_t src_lc,
@@ -42 +43 @@
-index c13f7564bf..22364e09ab 100644
+index 2d0a782ee0..d6f07df789 100644
@@ -45,11 +46,11 @@
-@@ -1071,8 +1071,8 @@ launch_args_parse(int argc, char** argv)
- 			break;
- 		case TESTPMD_OPT_NB_CORES_NUM:
- 			n = atoi(optarg);
--			if (n > 0 && n <= nb_lcores)
--				nb_fwd_lcores = (uint8_t) n;
-+			if (n > 0 && (lcoreid_t)n <= nb_lcores)
-+				nb_fwd_lcores = (lcoreid_t) n;
- 			else
- 				rte_exit(EXIT_FAILURE,
- 					"nb-cores should be > 0 and <= %d\n",
+@@ -864,8 +864,8 @@ launch_args_parse(int argc, char** argv)
+ 			}
+ 			if (!strcmp(lgopts[opt_idx].name, "nb-cores")) {
+ 				n = atoi(optarg);
+-				if (n > 0 && n <= nb_lcores)
+-					nb_fwd_lcores = (uint8_t) n;
++				if (n > 0 && (lcoreid_t)n <= nb_lcores)
++					nb_fwd_lcores = (lcoreid_t) n;
+ 				else
+ 					rte_exit(EXIT_FAILURE,
+ 						 "nb-cores should be > 0 and <= %d\n",
@@ -57 +58 @@
-index 0afae7d771..9facd7f281 100644
+index 022210a7a9..f7f3587c83 100644

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

* patch 'hash: fix return code description in Doxygen' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (38 preceding siblings ...)
  2024-06-24 23:58 ` patch 'app/testpmd: fix lcore ID restriction' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'hash: check name when creating a hash' " luca.boccassi
                   ` (39 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Chenming Chang; +Cc: Stephen Hemminger, Vladimir Medvedkin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/07f2ecf7b3283f3637198795ff78d34ebf70c594

Thanks.

Luca Boccassi

---
From 07f2ecf7b3283f3637198795ff78d34ebf70c594 Mon Sep 17 00:00:00 2001
From: Chenming Chang <ccm@ccm.ink>
Date: Mon, 27 Jun 2022 21:11:21 +0800
Subject: [PATCH] hash: fix return code description in Doxygen

[ upstream commit 78a632e6b52c29c5f297001181e870750eee02a7 ]

The rte_hash lookup can return ZERO which is not a positive value.

Fixes: af75078fece3 ("first public release")

Signed-off-by: Chenming Chang <ccm@ccm.ink>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
---
 .mailmap            |  1 +
 lib/hash/rte_hash.h | 16 ++++++++--------
 2 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/.mailmap b/.mailmap
index 8aca0a656e..7e7c1a75cb 100644
--- a/.mailmap
+++ b/.mailmap
@@ -215,6 +215,7 @@ Cheng Liu <liucheng11@huawei.com>
 Cheng Peng <cheng.peng5@zte.com.cn>
 Chengwen Feng <fengchengwen@huawei.com>
 Chenmin Sun <chenmin.sun@intel.com>
+Chenming Chang <ccm@ccm.ink>
 Chenxu Di <chenxux.di@intel.com>
 Cheryl Houser <chouser@vmware.com>
 Chinh T Cao <chinh.t.cao@intel.com>
diff --git a/lib/hash/rte_hash.h b/lib/hash/rte_hash.h
index a399346d02..51611e392b 100644
--- a/lib/hash/rte_hash.h
+++ b/lib/hash/rte_hash.h
@@ -287,7 +287,7 @@ rte_hash_add_key_with_hash_data(const struct rte_hash *h, const void *key,
  * @return
  *   - -EINVAL if the parameters are invalid.
  *   - -ENOSPC if there is no space in the hash for this key.
- *   - A positive value that can be used by the caller as an offset into an
+ *   - A non-negative value that can be used by the caller as an offset into an
  *     array of user data. This value is unique for this key. This
  *     unique key id may be larger than the user specified entry count
  *     when RTE_HASH_EXTRA_FLAGS_MULTI_WRITER_ADD flag is set.
@@ -311,7 +311,7 @@ rte_hash_add_key(const struct rte_hash *h, const void *key);
  * @return
  *   - -EINVAL if the parameters are invalid.
  *   - -ENOSPC if there is no space in the hash for this key.
- *   - A positive value that can be used by the caller as an offset into an
+ *   - A non-negative value that can be used by the caller as an offset into an
  *     array of user data. This value is unique for this key. This
  *     unique key ID may be larger than the user specified entry count
  *     when RTE_HASH_EXTRA_FLAGS_MULTI_WRITER_ADD flag is set.
@@ -342,7 +342,7 @@ rte_hash_add_key_with_hash(const struct rte_hash *h, const void *key, hash_sig_t
  * @return
  *   - -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
+ *   - A non-negative 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.
  */
@@ -374,7 +374,7 @@ rte_hash_del_key(const struct rte_hash *h, const void *key);
  * @return
  *   - -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
+ *   - A non-negative 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.
  */
@@ -441,7 +441,7 @@ rte_hash_free_key_with_position(const struct rte_hash *h,
  * @param data
  *   Output with pointer to data returned from the hash table.
  * @return
- *   - A positive value that can be used by the caller as an offset into an
+ *   - A non-negative 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.
@@ -466,7 +466,7 @@ 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
- *   - A positive value that can be used by the caller as an offset into an
+ *   - A non-negative 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.
@@ -489,7 +489,7 @@ rte_hash_lookup_with_hash_data(const struct rte_hash *h, const void *key,
  * @return
  *   - -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
+ *   - A non-negative 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.
  */
@@ -511,7 +511,7 @@ rte_hash_lookup(const struct rte_hash *h, const void *key);
  * @return
  *   - -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
+ *   - A non-negative 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.
  */
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.066778136 +0100
+++ 0041-hash-fix-return-code-description-in-Doxygen.patch	2024-06-25 00:22:13.165185241 +0100
@@ -1 +1 @@
-From 78a632e6b52c29c5f297001181e870750eee02a7 Mon Sep 17 00:00:00 2001
+From 07f2ecf7b3283f3637198795ff78d34ebf70c594 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 78a632e6b52c29c5f297001181e870750eee02a7 ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 1aca379558..111dbb0ac3 100644
+index 8aca0a656e..7e7c1a75cb 100644
@@ -23 +24 @@
-@@ -228,6 +228,7 @@ Cheng Liu <liucheng11@huawei.com>
+@@ -215,6 +215,7 @@ Cheng Liu <liucheng11@huawei.com>
@@ -29 +29,0 @@
- Chenyu Huang <chenyux.huang@intel.com>
@@ -30,0 +31 @@
+ Chinh T Cao <chinh.t.cao@intel.com>
@@ -32 +33 @@
-index 7ecc021111..ba96521529 100644
+index a399346d02..51611e392b 100644
@@ -35 +36 @@
-@@ -286,7 +286,7 @@ rte_hash_add_key_with_hash_data(const struct rte_hash *h, const void *key,
+@@ -287,7 +287,7 @@ rte_hash_add_key_with_hash_data(const struct rte_hash *h, const void *key,
@@ -44 +45 @@
-@@ -310,7 +310,7 @@ rte_hash_add_key(const struct rte_hash *h, const void *key);
+@@ -311,7 +311,7 @@ rte_hash_add_key(const struct rte_hash *h, const void *key);
@@ -53 +54 @@
-@@ -341,7 +341,7 @@ rte_hash_add_key_with_hash(const struct rte_hash *h, const void *key, hash_sig_t
+@@ -342,7 +342,7 @@ rte_hash_add_key_with_hash(const struct rte_hash *h, const void *key, hash_sig_t
@@ -62 +63 @@
-@@ -373,7 +373,7 @@ rte_hash_del_key(const struct rte_hash *h, const void *key);
+@@ -374,7 +374,7 @@ rte_hash_del_key(const struct rte_hash *h, const void *key);
@@ -71 +72 @@
-@@ -440,7 +440,7 @@ rte_hash_free_key_with_position(const struct rte_hash *h,
+@@ -441,7 +441,7 @@ rte_hash_free_key_with_position(const struct rte_hash *h,
@@ -80 +81 @@
-@@ -465,7 +465,7 @@ rte_hash_lookup_data(const struct rte_hash *h, const void *key, void **data);
+@@ -466,7 +466,7 @@ rte_hash_lookup_data(const struct rte_hash *h, const void *key, void **data);
@@ -89 +90 @@
-@@ -488,7 +488,7 @@ rte_hash_lookup_with_hash_data(const struct rte_hash *h, const void *key,
+@@ -489,7 +489,7 @@ rte_hash_lookup_with_hash_data(const struct rte_hash *h, const void *key,
@@ -98 +99 @@
-@@ -510,7 +510,7 @@ rte_hash_lookup(const struct rte_hash *h, const void *key);
+@@ -511,7 +511,7 @@ rte_hash_lookup(const struct rte_hash *h, const void *key);

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

* patch 'hash: check name when creating a hash' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (39 preceding siblings ...)
  2024-06-24 23:58 ` patch 'hash: fix return code description in Doxygen' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'mempool: replace GCC pragma with cast' " luca.boccassi
                   ` (38 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Conor Fogarty; +Cc: Vladimir Medvedkin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/a28f53ce9a26ccb18f747b8388f821c615e1d2a9

Thanks.

Luca Boccassi

---
From a28f53ce9a26ccb18f747b8388f821c615e1d2a9 Mon Sep 17 00:00:00 2001
From: Conor Fogarty <conor.fogarty@intel.com>
Date: Thu, 6 Jul 2023 16:26:26 +0100
Subject: [PATCH] hash: check name when creating a hash

[ upstream commit 8f36e53317ecf8384461e4f692e46beaaf6c4d2f ]

Add NULL pointer check to params->name, which is later
copied into the hash datastructure. Without this check
the code segfaults on the strlcpy() of a NULL pointer.

Fixes: 48a399119619 ("hash: replace with cuckoo hash implementation")

Signed-off-by: Conor Fogarty <conor.fogarty@intel.com>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
---
 lib/hash/rte_cuckoo_hash.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/hash/rte_cuckoo_hash.c b/lib/hash/rte_cuckoo_hash.c
index a08b5dd875..13c8337519 100644
--- a/lib/hash/rte_cuckoo_hash.c
+++ b/lib/hash/rte_cuckoo_hash.c
@@ -166,6 +166,7 @@ rte_hash_create(const struct rte_hash_parameters *params)
 	/* Check for valid parameters */
 	if ((params->entries > RTE_HASH_ENTRIES_MAX) ||
 			(params->entries < RTE_HASH_BUCKET_ENTRIES) ||
+			(params->name == NULL) ||
 			(params->key_len == 0)) {
 		rte_errno = EINVAL;
 		RTE_LOG(ERR, HASH, "rte_hash_create has invalid parameters\n");
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.110038637 +0100
+++ 0042-hash-check-name-when-creating-a-hash.patch	2024-06-25 00:22:13.165185241 +0100
@@ -1 +1 @@
-From 8f36e53317ecf8384461e4f692e46beaaf6c4d2f Mon Sep 17 00:00:00 2001
+From a28f53ce9a26ccb18f747b8388f821c615e1d2a9 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 8f36e53317ecf8384461e4f692e46beaaf6c4d2f ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index b31a3d973e..16c9c4c5c4 100644
+index a08b5dd875..13c8337519 100644
@@ -23 +24 @@
-@@ -173,6 +173,7 @@ rte_hash_create(const struct rte_hash_parameters *params)
+@@ -166,6 +166,7 @@ rte_hash_create(const struct rte_hash_parameters *params)
@@ -30 +31 @@
- 		HASH_LOG(ERR, "%s has invalid parameters", __func__);
+ 		RTE_LOG(ERR, HASH, "rte_hash_create has invalid parameters\n");

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

* patch 'mempool: replace GCC pragma with cast' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (40 preceding siblings ...)
  2024-06-24 23:58 ` patch 'hash: check name when creating a hash' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'vhost: fix build with GCC 13' " luca.boccassi
                   ` (37 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/9cdf5aecb261e85cc3ae75eda57a34c7a201b3d5

Thanks.

Luca Boccassi

---
From 9cdf5aecb261e85cc3ae75eda57a34c7a201b3d5 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Mon, 1 Apr 2024 10:01:52 -0700
Subject: [PATCH] mempool: replace GCC pragma with cast

[ upstream commit 23dc03f67279f6ced3dafd2e4c76c1b67a0102dc ]

Building mempool with MSVC generates a warning
because of this pragma (same with clang when debug is enabled).
The issue the pragma was working around can be better solved
by using an additional cast.

Fixes: af75078fece3 ("first public release")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/mempool/rte_mempool.c | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/lib/mempool/rte_mempool.c b/lib/mempool/rte_mempool.c
index 3de857abf5..258754cf67 100644
--- a/lib/mempool/rte_mempool.c
+++ b/lib/mempool/rte_mempool.c
@@ -1054,10 +1054,6 @@ rte_mempool_dump_cache(FILE *f, const struct rte_mempool *mp)
 	return count;
 }
 
-#ifndef __INTEL_COMPILER
-#pragma GCC diagnostic ignored "-Wcast-qual"
-#endif
-
 /* check and update cookies or panic (internal) */
 void rte_mempool_check_cookies(const struct rte_mempool *mp,
 	void * const *obj_table_const, unsigned n, int free)
@@ -1072,7 +1068,7 @@ void rte_mempool_check_cookies(const struct rte_mempool *mp,
 
 	/* Force to drop the "const" attribute. This is done only when
 	 * DEBUG is enabled */
-	tmp = (void *) obj_table_const;
+	tmp = (void *)(uintptr_t)obj_table_const;
 	obj_table = tmp;
 
 	while (n--) {
@@ -1181,10 +1177,6 @@ mempool_audit_cookies(struct rte_mempool *mp)
 #define mempool_audit_cookies(mp) do {} while(0)
 #endif
 
-#ifndef __INTEL_COMPILER
-#pragma GCC diagnostic error "-Wcast-qual"
-#endif
-
 /* check cookies before and after objects */
 static void
 mempool_audit_cache(const struct rte_mempool *mp)
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.153274784 +0100
+++ 0043-mempool-replace-GCC-pragma-with-cast.patch	2024-06-25 00:22:13.165185241 +0100
@@ -1 +1 @@
-From 23dc03f67279f6ced3dafd2e4c76c1b67a0102dc Mon Sep 17 00:00:00 2001
+From 9cdf5aecb261e85cc3ae75eda57a34c7a201b3d5 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 23dc03f67279f6ced3dafd2e4c76c1b67a0102dc ]
+
@@ -20 +22 @@
-index 7a98441a87..ff67fe4181 100644
+index 3de857abf5..258754cf67 100644
@@ -23 +25 @@
-@@ -1056,10 +1056,6 @@ rte_mempool_dump_cache(FILE *f, const struct rte_mempool *mp)
+@@ -1054,10 +1054,6 @@ rte_mempool_dump_cache(FILE *f, const struct rte_mempool *mp)
@@ -34 +36 @@
-@@ -1074,7 +1070,7 @@ void rte_mempool_check_cookies(const struct rte_mempool *mp,
+@@ -1072,7 +1068,7 @@ void rte_mempool_check_cookies(const struct rte_mempool *mp,
@@ -43 +45 @@
-@@ -1183,10 +1179,6 @@ mempool_audit_cookies(struct rte_mempool *mp)
+@@ -1181,10 +1177,6 @@ mempool_audit_cookies(struct rte_mempool *mp)

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

* patch 'vhost: fix build with GCC 13' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (41 preceding siblings ...)
  2024-06-24 23:58 ` patch 'mempool: replace GCC pragma with cast' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'vhost: cleanup resubmit info before inflight setup' " luca.boccassi
                   ` (36 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Luca Vizzarro
  Cc: Paul Szczepanek, Nick Connolly, Maxime Coquelin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/6267610fffce83f71ac52256964bb737b1d6400c

Thanks.

Luca Boccassi

---
From 6267610fffce83f71ac52256964bb737b1d6400c Mon Sep 17 00:00:00 2001
From: Luca Vizzarro <luca.vizzarro@arm.com>
Date: Wed, 10 Apr 2024 16:21:01 +0100
Subject: [PATCH] vhost: fix build with GCC 13
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 8db1acabeea3fa4b0c673588cfff2b01e0ae9615 ]

This patch resolves a build error with GCC 13 and arm/aarch32 as
targets:

In function ‘mbuf_to_desc’,
    inlined from ‘vhost_enqueue_async_packed’ at
      ../lib/vhost/virtio_net.c:1828:6,
    inlined from ‘virtio_dev_rx_async_packed’ at
      ../lib/vhost/virtio_net.c:1842:6,
    inlined from ‘virtio_dev_rx_async_submit_packed’ at
      ../lib/vhost/virtio_net.c:1900:7:
../lib/vhost/virtio_net.c:1159:18: error: ‘buf_vec[0].buf_addr’ may
    be used uninitialized [-Werror=maybe-uninitialized]
 1159 |         buf_addr = buf_vec[vec_idx].buf_addr;
      |         ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
<snip>
../lib/vhost/virtio_net.c:1160:18: error: ‘buf_vec[0].buf_iova’ may
    be used uninitialized [-Werror=maybe-uninitialized]
 1160 |         buf_iova = buf_vec[vec_idx].buf_iova;
      |         ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
<snip>
../lib/vhost/virtio_net.c:1161:35: error: ‘buf_vec[0].buf_len’ may
    be used uninitialized [-Werror=maybe-uninitialized]
 1161 |         buf_len = buf_vec[vec_idx].buf_len;
      |                   ~~~~~~~~~~~~~~~~^~~~~~~~

GCC complains about the possible runtime path where the while loop
which fills buf_vec (in vhost_enqueue_async_packed) is not run. As a
consequence it correctly thinks that buf_vec is not initialized while
being accessed anyways.

This scenario is actually very unlikely as the only way this can occur
is if size has overflowed to 0. Meaning that the total packet length
would be close to UINT64_MAX (or actually UINT32_MAX). At first glance,
the code suggests that this may never happen as the type of size has
been changed to 64-bit. For a 32-bit architecture such as arm
(e.g. armv7-a) and aarch32, this still happens because the operand types
(pkt->pkt_len and sizeof) are 32-bit wide, performing 32-bit arithmetic
first (where the overflow can happen) and widening to 64-bit later.

The proposed fix simply guarantees to the compiler that the scope which
fills buf_vec is accessed at least once, while not disrupting the actual
logic. This is based on the assumption that size will always be greater
than 0, as suggested by the sizeof, and the packet length will never be
as big as UINT32_MAX, and causing an overflow.

Fixes: 873e8dad6f49 ("vhost: support packed ring in async datapath")

Signed-off-by: Luca Vizzarro <luca.vizzarro@arm.com>
Reviewed-by: Paul Szczepanek <paul.szczepanek@arm.com>
Reviewed-by: Nick Connolly <nick.connolly@arm.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
 .mailmap               | 2 +-
 lib/vhost/virtio_net.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/.mailmap b/.mailmap
index 7e7c1a75cb..1c0d974460 100644
--- a/.mailmap
+++ b/.mailmap
@@ -983,7 +983,7 @@ Nemanja Marjanovic <nemanja.marjanovic@intel.com>
 Netanel Belgazal <netanel@amazon.com>
 Netanel Gonen <netanelg@mellanox.com>
 Niall Power <niall.power@intel.com>
-Nick Connolly <nick.connolly@mayadata.io>
+Nick Connolly <nick.connolly@arm.com> <nick.connolly@mayadata.io>
 Nick Nunley <nicholas.d.nunley@intel.com>
 Niclas Storm <niclas.storm@ericsson.com>
 Nicolas Chautru <nicolas.chautru@intel.com>
diff --git a/lib/vhost/virtio_net.c b/lib/vhost/virtio_net.c
index 3061275753..9f314f83c7 100644
--- a/lib/vhost/virtio_net.c
+++ b/lib/vhost/virtio_net.c
@@ -1796,7 +1796,7 @@ vhost_enqueue_async_packed(struct virtio_net *dev,
 	else
 		max_tries = 1;
 
-	while (size > 0) {
+	do {
 		/*
 		 * if we tried all available ring items, and still
 		 * can't get enough buf, it means something abnormal
@@ -1823,7 +1823,7 @@ vhost_enqueue_async_packed(struct virtio_net *dev,
 		avail_idx += desc_count;
 		if (avail_idx >= vq->size)
 			avail_idx -= vq->size;
-	}
+	} while (size > 0);
 
 	if (unlikely(mbuf_to_desc(dev, vq, pkt, buf_vec, nr_vec, *nr_buffers, true) < 0))
 		return -1;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.195109621 +0100
+++ 0044-vhost-fix-build-with-GCC-13.patch	2024-06-25 00:22:13.169185323 +0100
@@ -1 +1 @@
-From 8db1acabeea3fa4b0c673588cfff2b01e0ae9615 Mon Sep 17 00:00:00 2001
+From 6267610fffce83f71ac52256964bb737b1d6400c Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 8db1acabeea3fa4b0c673588cfff2b01e0ae9615 ]
+
@@ -55 +56,0 @@
-Cc: stable@dpdk.org
@@ -67 +68 @@
-index 111dbb0ac3..ed63605a15 100644
+index 7e7c1a75cb..1c0d974460 100644
@@ -70 +71,2 @@
-@@ -1030,7 +1030,7 @@ Netanel Belgazal <netanel@amazon.com>
+@@ -983,7 +983,7 @@ Nemanja Marjanovic <nemanja.marjanovic@intel.com>
+ Netanel Belgazal <netanel@amazon.com>
@@ -73 +74,0 @@
- Nicholas Pratte <npratte@iol.unh.edu>
@@ -80 +81 @@
-index b406b5d7d9..370402d849 100644
+index 3061275753..9f314f83c7 100644
@@ -83 +84 @@
-@@ -1935,7 +1935,7 @@ vhost_enqueue_async_packed(struct virtio_net *dev,
+@@ -1796,7 +1796,7 @@ vhost_enqueue_async_packed(struct virtio_net *dev,
@@ -92 +93 @@
-@@ -1962,7 +1962,7 @@ vhost_enqueue_async_packed(struct virtio_net *dev,
+@@ -1823,7 +1823,7 @@ vhost_enqueue_async_packed(struct virtio_net *dev,

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

* patch 'vhost: cleanup resubmit info before inflight setup' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (42 preceding siblings ...)
  2024-06-24 23:58 ` patch 'vhost: fix build with GCC 13' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/virtio: fix MAC table update' " luca.boccassi
                   ` (35 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Haoqian He; +Cc: Maxime Coquelin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/aff6953d46a68165eddc631154cb687e7f646cac

Thanks.

Luca Boccassi

---
From aff6953d46a68165eddc631154cb687e7f646cac Mon Sep 17 00:00:00 2001
From: Haoqian He <haoqian.he@smartx.com>
Date: Fri, 26 Apr 2024 07:09:46 -0400
Subject: [PATCH] vhost: cleanup resubmit info before inflight setup
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit e4a01eea66326c58593906e189b376605a0ec606 ]

This patch fixes a potential VM hang bug when the VM reboots after
vhost live recovery due to missing cleanup virtqueue resubmit info.

Specifically, if inflight IO that should be resubmitted during
the latest vhost reconnection has not been submitted yet while
VM rebooting, so GET_VRING_BASE would not wait for the inflight
IO, at this time the resubmit info has been.  When the VM restarts,
SET_VRING_KICK will resubmit the inflight IO (If resubmit info
is not null, function set_vring_kick will return without updating
resubmit info).

It’s an error, any stale inflight IO should not be resubmitted
after the VM restart.

The solution is to clean up virtqueue resubmit info when function
set_inflight_fd before function set_vring_kick.

Fixes: ad0a4ae491fe ("vhost: checkout resubmit inflight information")

Signed-off-by: Haoqian He <haoqian.he@smartx.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
 .mailmap               | 1 +
 lib/vhost/vhost_user.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/.mailmap b/.mailmap
index 1c0d974460..2724a689fd 100644
--- a/.mailmap
+++ b/.mailmap
@@ -473,6 +473,7 @@ Hanoch Haim <hhaim@cisco.com>
 Hanumanth Pothula <hpothula@marvell.com>
 Hao Chen <chenhao164@huawei.com>
 Hao Wu <hao.wu@intel.com>
+Haoqian He <haoqian.he@smartx.com>
 Hari Kumar Vemula <hari.kumarx.vemula@intel.com>
 Harini Ramakrishnan <harini.ramakrishnan@microsoft.com>
 Hariprasad Govindharajan <hariprasad.govindharajan@intel.com>
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 66ab68fa56..8d7d04059c 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost/vhost_user.c
@@ -1745,6 +1745,7 @@ vhost_user_set_inflight_fd(struct virtio_net **pdev,
 		if (!vq)
 			continue;
 
+		cleanup_vq_inflight(dev, vq);
 		if (vq_is_packed(dev)) {
 			vq->inflight_packed = addr;
 			vq->inflight_packed->desc_num = queue_size;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.241753554 +0100
+++ 0045-vhost-cleanup-resubmit-info-before-inflight-setup.patch	2024-06-25 00:22:13.173185404 +0100
@@ -1 +1 @@
-From e4a01eea66326c58593906e189b376605a0ec606 Mon Sep 17 00:00:00 2001
+From aff6953d46a68165eddc631154cb687e7f646cac Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit e4a01eea66326c58593906e189b376605a0ec606 ]
+
@@ -27 +28,0 @@
-Cc: stable@dpdk.org
@@ -37 +38 @@
-index ed63605a15..ff20619bfb 100644
+index 1c0d974460..2724a689fd 100644
@@ -40 +41 @@
-@@ -495,6 +495,7 @@ Hanoch Haim <hhaim@cisco.com>
+@@ -473,6 +473,7 @@ Hanoch Haim <hhaim@cisco.com>
@@ -42 +43 @@
- Hao Chen <chenh@yusur.tech> <chenhao164@huawei.com>
+ Hao Chen <chenhao164@huawei.com>
@@ -49 +50 @@
-index 414192500e..7c54afc5fb 100644
+index 66ab68fa56..8d7d04059c 100644
@@ -52 +53 @@
-@@ -1871,6 +1871,7 @@ vhost_user_set_inflight_fd(struct virtio_net **pdev,
+@@ -1745,6 +1745,7 @@ vhost_user_set_inflight_fd(struct virtio_net **pdev,

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

* patch 'net/virtio: fix MAC table update' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (43 preceding siblings ...)
  2024-06-24 23:58 ` patch 'vhost: cleanup resubmit info before inflight setup' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'baseband/acc: fix memory barrier' " luca.boccassi
                   ` (34 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Satha Rao; +Cc: Maxime Coquelin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/48fb2f00d848ab9e9dc5ef15f3e343034c5bcf94

Thanks.

Luca Boccassi

---
From 48fb2f00d848ab9e9dc5ef15f3e343034c5bcf94 Mon Sep 17 00:00:00 2001
From: Satha Rao <skoteshwar@marvell.com>
Date: Thu, 30 May 2024 13:40:39 -0400
Subject: [PATCH] net/virtio: fix MAC table update

[ upstream commit 7698e655516c54558a43b8aaed1bff69928d96fb ]

Don't send NULL MAC addresses in MAC table update.

Fixes: 1b306359e58c ("virtio: suport multiple MAC addresses")

Signed-off-by: Satha Rao <skoteshwar@marvell.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
 drivers/net/virtio/virtio_ethdev.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
index 073bbf482d..1d9a168f92 100644
--- a/drivers/net/virtio/virtio_ethdev.c
+++ b/drivers/net/virtio/virtio_ethdev.c
@@ -1320,6 +1320,8 @@ virtio_mac_addr_add(struct rte_eth_dev *dev, struct rte_ether_addr *mac_addr,
 		struct virtio_net_ctrl_mac *tbl
 			= rte_is_multicast_ether_addr(addr) ? mc : uc;
 
+		if (rte_is_zero_ether_addr(addr))
+			break;
 		memcpy(&tbl->macs[tbl->entries++], addr, RTE_ETHER_ADDR_LEN);
 	}
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.288104719 +0100
+++ 0046-net-virtio-fix-MAC-table-update.patch	2024-06-25 00:22:13.177185486 +0100
@@ -1 +1 @@
-From 7698e655516c54558a43b8aaed1bff69928d96fb Mon Sep 17 00:00:00 2001
+From 48fb2f00d848ab9e9dc5ef15f3e343034c5bcf94 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 7698e655516c54558a43b8aaed1bff69928d96fb ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
-index 517585740e..70d4839def 100644
+index 073bbf482d..1d9a168f92 100644
@@ -21 +22 @@
-@@ -913,6 +913,8 @@ virtio_mac_addr_add(struct rte_eth_dev *dev, struct rte_ether_addr *mac_addr,
+@@ -1320,6 +1320,8 @@ virtio_mac_addr_add(struct rte_eth_dev *dev, struct rte_ether_addr *mac_addr,

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

* patch 'baseband/acc: fix memory barrier' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (44 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/virtio: fix MAC table update' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'event/sw: fix warning from useless snprintf' " luca.boccassi
                   ` (33 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Hernan Vargas; +Cc: Maxime Coquelin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/d47135efe7ed109c90c806899b4a6c7f022388b4

Thanks.

Luca Boccassi

---
From d47135efe7ed109c90c806899b4a6c7f022388b4 Mon Sep 17 00:00:00 2001
From: Hernan Vargas <hernan.vargas@intel.com>
Date: Thu, 2 May 2024 13:45:44 -0700
Subject: [PATCH] baseband/acc: fix memory barrier

[ upstream commit 0a200a3a29017f6b01a481776a571a75e03a32ce ]

Moving memory barrier so that dequeue thread can be in sync with enqueue
thread.

Fixes: 32e8b7ea35dd ("baseband/acc100: refactor to segregate common code")

Signed-off-by: Hernan Vargas <hernan.vargas@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
 drivers/baseband/acc/acc_common.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/baseband/acc/acc_common.h b/drivers/baseband/acc/acc_common.h
index 9336d3fbcf..7ea3cc9a02 100644
--- a/drivers/baseband/acc/acc_common.h
+++ b/drivers/baseband/acc/acc_common.h
@@ -964,6 +964,9 @@ acc_dma_enqueue(struct acc_queue *q, uint16_t n,
 				req_elem_addr,
 				(void *)q->mmio_reg_enqueue);
 
+		q->aq_enqueued++;
+		q->sw_ring_head += enq_batch_size;
+
 		rte_wmb();
 
 #ifdef RTE_BBDEV_OFFLOAD_COST
@@ -978,8 +981,6 @@ acc_dma_enqueue(struct acc_queue *q, uint16_t n,
 				rte_rdtsc_precise() - start_time;
 #endif
 
-		q->aq_enqueued++;
-		q->sw_ring_head += enq_batch_size;
 		n -= enq_batch_size;
 
 	} while (n);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.331479882 +0100
+++ 0047-baseband-acc-fix-memory-barrier.patch	2024-06-25 00:22:13.177185486 +0100
@@ -1 +1 @@
-From 0a200a3a29017f6b01a481776a571a75e03a32ce Mon Sep 17 00:00:00 2001
+From d47135efe7ed109c90c806899b4a6c7f022388b4 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0a200a3a29017f6b01a481776a571a75e03a32ce ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index fddeb0737b..e249f37e38 100644
+index 9336d3fbcf..7ea3cc9a02 100644
@@ -22 +23 @@
-@@ -1112,6 +1112,9 @@ acc_dma_enqueue(struct acc_queue *q, uint16_t n,
+@@ -964,6 +964,9 @@ acc_dma_enqueue(struct acc_queue *q, uint16_t n,
@@ -31,4 +32,4 @@
- 		/* Start time measurement for enqueue function offload. */
-@@ -1122,8 +1125,6 @@ acc_dma_enqueue(struct acc_queue *q, uint16_t n,
- 
- 		queue_stats->acc_offload_cycles += rte_rdtsc_precise() - start_time;
+ #ifdef RTE_BBDEV_OFFLOAD_COST
+@@ -978,8 +981,6 @@ acc_dma_enqueue(struct acc_queue *q, uint16_t n,
+ 				rte_rdtsc_precise() - start_time;
+ #endif

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

* patch 'event/sw: fix warning from useless snprintf' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (45 preceding siblings ...)
  2024-06-24 23:58 ` patch 'baseband/acc: fix memory barrier' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'eventdev/crypto: fix opaque field handling' " luca.boccassi
                   ` (32 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: Harry van Haaren, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/ae651a5adb9e83ccef322c2a1f125585ab4dde74

Thanks.

Luca Boccassi

---
From ae651a5adb9e83ccef322c2a1f125585ab4dde74 Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Tue, 23 Apr 2024 20:45:40 -0700
Subject: [PATCH] event/sw: fix warning from useless snprintf

[ upstream commit 510e2b655b46d91d3cc189882e6392afdc0363ff ]

With GCC-14, this warning is generated:
drivers/event/sw/sw_evdev.c:263:3: warning:
    snprintf' will always be truncated;
    specified size is 12, but format string expands to at least 13
        snprintf(buf, sizeof(buf), "sw%d_iq_%d_rob", dev_id, i);
        ^

Yet the whole printf to the buf is unnecessary. The type string argument
has never been implemented, and should just be NULL.  Removing the
unnecessary snprintf, then means IQ_ROB_NAMESIZE can be removed.

Fixes: 5ffb2f142d95 ("event/sw: support event queues")

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Harry van Haaren <harry.van.haaren@intel.com>
---
 drivers/event/sw/iq_chunk.h | 2 --
 drivers/event/sw/sw_evdev.c | 5 +----
 2 files changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/event/sw/iq_chunk.h b/drivers/event/sw/iq_chunk.h
index 31d013eab7..7820815c38 100644
--- a/drivers/event/sw/iq_chunk.h
+++ b/drivers/event/sw/iq_chunk.h
@@ -9,8 +9,6 @@
 #include <stdbool.h>
 #include <rte_eventdev.h>
 
-#define IQ_ROB_NAMESIZE 12
-
 struct sw_queue_chunk {
 	struct rte_event events[SW_EVS_PER_Q_CHUNK];
 	struct sw_queue_chunk *next;
diff --git a/drivers/event/sw/sw_evdev.c b/drivers/event/sw/sw_evdev.c
index 2a2763ee9b..09200c9188 100644
--- a/drivers/event/sw/sw_evdev.c
+++ b/drivers/event/sw/sw_evdev.c
@@ -228,9 +228,7 @@ qid_init(struct sw_evdev *sw, unsigned int idx, int type,
 		const struct rte_event_queue_conf *queue_conf)
 {
 	unsigned int i;
-	int dev_id = sw->data->dev_id;
 	int socket_id = sw->data->socket_id;
-	char buf[IQ_ROB_NAMESIZE];
 	struct sw_qid *qid = &sw->qids[idx];
 
 	/* Initialize the FID structures to no pinning (-1), and zero packets */
@@ -260,8 +258,7 @@ qid_init(struct sw_evdev *sw, unsigned int idx, int type,
 			goto cleanup;
 		}
 
-		snprintf(buf, sizeof(buf), "sw%d_iq_%d_rob", dev_id, i);
-		qid->reorder_buffer = rte_zmalloc_socket(buf,
+		qid->reorder_buffer = rte_zmalloc_socket(NULL,
 				window_size * sizeof(qid->reorder_buffer[0]),
 				0, socket_id);
 		if (!qid->reorder_buffer) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.373261981 +0100
+++ 0048-event-sw-fix-warning-from-useless-snprintf.patch	2024-06-25 00:22:13.177185486 +0100
@@ -1 +1 @@
-From 510e2b655b46d91d3cc189882e6392afdc0363ff Mon Sep 17 00:00:00 2001
+From ae651a5adb9e83ccef322c2a1f125585ab4dde74 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 510e2b655b46d91d3cc189882e6392afdc0363ff ]
+
@@ -18 +19,0 @@
-Cc: stable@dpdk.org
@@ -28 +29 @@
-index 7a7a8782e6..e638142dbc 100644
+index 31d013eab7..7820815c38 100644
@@ -37 +38 @@
- struct __rte_cache_aligned sw_queue_chunk {
+ struct sw_queue_chunk {
@@ -41 +42 @@
-index 1c01b069fe..19a52afc7d 100644
+index 2a2763ee9b..09200c9188 100644

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

* patch 'eventdev/crypto: fix opaque field handling' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (46 preceding siblings ...)
  2024-06-24 23:58 ` patch 'event/sw: fix warning from useless snprintf' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'eal: fix logs for '--lcores'' " luca.boccassi
                   ` (31 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Ganapati Kundapura; +Cc: Abhinandan Gujjar, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/55754590621b079ecf0d2f458309c42be4c0907a

Thanks.

Luca Boccassi

---
From 55754590621b079ecf0d2f458309c42be4c0907a Mon Sep 17 00:00:00 2001
From: Ganapati Kundapura <ganapati.kundapura@intel.com>
Date: Thu, 6 Jun 2024 08:48:00 -0500
Subject: [PATCH] eventdev/crypto: fix opaque field handling

[ upstream commit ad12d08f05db8323ac1fb655b75dcef69e536a04 ]

For session-less crypto operations, event info is contained in
crypto op metadata for each event which is restored in event
from the crypto op metadata response info.

For session based crypto operations, crypto op contains per session
based event info in crypto op metadata. If any PMD passes any
implementation specific data in "struct rte_event::impl_opaque"
on each event, it's not getting restored.

This patch stores "struct rte_event::impl_opaque" in mbuf dynamic
field before enqueueing to cryptodev and restores
"struct rte_event::impl_opaque" from mbuf dynamic field after
dequeueing crypto op from cryptodev for session based crypto operations.

Fixes: 7901eac3409a ("eventdev: add crypto adapter implementation")

Signed-off-by: Ganapati Kundapura <ganapati.kundapura@intel.com>
Acked-by: Abhinandan Gujjar <abhinandan.gujjar@intel.com>
---
 lib/eventdev/rte_event_crypto_adapter.c | 68 +++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

diff --git a/lib/eventdev/rte_event_crypto_adapter.c b/lib/eventdev/rte_event_crypto_adapter.c
index a25316a43a..258be0f339 100644
--- a/lib/eventdev/rte_event_crypto_adapter.c
+++ b/lib/eventdev/rte_event_crypto_adapter.c
@@ -131,6 +131,28 @@ static struct event_crypto_adapter **event_crypto_adapter;
 	} \
 } while (0)
 
+#define ECA_DYNFIELD_NAME "eca_ev_opaque_data"
+/* Device-specific metadata field type */
+typedef uint8_t eca_dynfield_t;
+
+/* mbuf dynamic field offset for device-specific metadata */
+int eca_dynfield_offset = -1;
+
+static int
+eca_dynfield_register(void)
+{
+	static const struct rte_mbuf_dynfield eca_dynfield_desc = {
+		.name = ECA_DYNFIELD_NAME,
+		.size = sizeof(eca_dynfield_t),
+		.align = __alignof__(eca_dynfield_t),
+		.flags = 0,
+	};
+
+	eca_dynfield_offset =
+		rte_mbuf_dynfield_register(&eca_dynfield_desc);
+	return eca_dynfield_offset;
+}
+
 static inline int
 eca_valid_id(uint8_t id)
 {
@@ -492,6 +514,25 @@ eca_enq_to_cryptodev(struct event_crypto_adapter *adapter, struct rte_event *ev,
 		crypto_op = ev[i].event_ptr;
 		if (crypto_op == NULL)
 			continue;
+
+		/** "struct rte_event::impl_opaque" field passed on from
+		 *  eventdev PMD could have different value per event.
+		 *  For session-based crypto operations retain
+		 *  "struct rte_event::impl_opaque" into mbuf dynamic field and
+		 *  restore it back after copying event information from
+		 *  session event metadata.
+		 *  For session-less, each crypto operation carries event
+		 *  metadata and retains "struct rte_event:impl_opaque"
+		 *  information to be passed back to eventdev PMD.
+		 */
+		if (crypto_op->sess_type == RTE_CRYPTO_OP_WITH_SESSION) {
+			struct rte_mbuf *mbuf = crypto_op->sym->m_src;
+
+			*RTE_MBUF_DYNFIELD(mbuf,
+					eca_dynfield_offset,
+					eca_dynfield_t *) = ev[i].impl_opaque;
+		}
+
 		m_data = rte_cryptodev_session_event_mdata_get(crypto_op);
 		if (m_data == NULL) {
 			rte_pktmbuf_free(crypto_op->sym->m_src);
@@ -658,6 +699,21 @@ eca_ops_enqueue_burst(struct event_crypto_adapter *adapter,
 
 		rte_memcpy(ev, &m_data->response_info, sizeof(*ev));
 		ev->event_ptr = ops[i];
+
+		/** Restore "struct rte_event::impl_opaque" from mbuf
+		 *  dynamic field for session based crypto operation.
+		 *  For session-less, each crypto operations carries event
+		 *  metadata and retains "struct rte_event::impl_opaque"
+		 *  information to be passed back to eventdev PMD.
+		 */
+		if (ops[i]->sess_type == RTE_CRYPTO_OP_WITH_SESSION) {
+			struct rte_mbuf *mbuf = ops[i]->sym->m_src;
+
+			ev->impl_opaque = *RTE_MBUF_DYNFIELD(mbuf,
+							eca_dynfield_offset,
+							eca_dynfield_t *);
+		}
+
 		ev->event_type = RTE_EVENT_TYPE_CRYPTODEV;
 		if (adapter->implicit_release_disabled)
 			ev->op = RTE_EVENT_OP_FORWARD;
@@ -882,6 +938,18 @@ eca_init_service(struct event_crypto_adapter *adapter, uint8_t id)
 
 	adapter->max_nb = adapter_conf.max_nb;
 	adapter->event_port_id = adapter_conf.event_port_id;
+
+	/** Register for mbuf dyn field to store/restore
+	 *  "struct rte_event::impl_opaque"
+	 */
+	eca_dynfield_offset = eca_dynfield_register();
+	if (eca_dynfield_offset  < 0) {
+		RTE_EDEV_LOG_ERR("Failed to register eca mbuf dyn field");
+		eca_circular_buffer_free(&adapter->ebuf);
+		rte_free(adapter);
+		return -EINVAL;
+	}
+
 	adapter->service_inited = 1;
 
 	return ret;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.416677107 +0100
+++ 0049-eventdev-crypto-fix-opaque-field-handling.patch	2024-06-25 00:22:13.181185567 +0100
@@ -1 +1 @@
-From ad12d08f05db8323ac1fb655b75dcef69e536a04 Mon Sep 17 00:00:00 2001
+From 55754590621b079ecf0d2f458309c42be4c0907a Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ad12d08f05db8323ac1fb655b75dcef69e536a04 ]
+
@@ -21 +22,0 @@
-Cc: stable@dpdk.org
@@ -30 +31 @@
-index db1c7f3906..939ca1cad9 100644
+index a25316a43a..258be0f339 100644
@@ -33 +34 @@
-@@ -138,6 +138,28 @@ static struct event_crypto_adapter **event_crypto_adapter;
+@@ -131,6 +131,28 @@ static struct event_crypto_adapter **event_crypto_adapter;
@@ -50 +51 @@
-+		.align = alignof(eca_dynfield_t),
++		.align = __alignof__(eca_dynfield_t),
@@ -62 +63 @@
-@@ -491,6 +513,25 @@ eca_enq_to_cryptodev(struct event_crypto_adapter *adapter, struct rte_event *ev,
+@@ -492,6 +514,25 @@ eca_enq_to_cryptodev(struct event_crypto_adapter *adapter, struct rte_event *ev,
@@ -88 +89 @@
-@@ -657,6 +698,21 @@ eca_ops_enqueue_burst(struct event_crypto_adapter *adapter,
+@@ -658,6 +699,21 @@ eca_ops_enqueue_burst(struct event_crypto_adapter *adapter,
@@ -110,2 +111 @@
-@@ -895,6 +951,18 @@ eca_init_service(struct event_crypto_adapter *adapter, uint8_t id)
- 	}
+@@ -882,6 +938,18 @@ eca_init_service(struct event_crypto_adapter *adapter, uint8_t id)
@@ -113 +113,2 @@
- 	adapter->implicit_release_disabled = (uint8_t)impl_rel;
+ 	adapter->max_nb = adapter_conf.max_nb;
+ 	adapter->event_port_id = adapter_conf.event_port_id;

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

* patch 'eal: fix logs for '--lcores'' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (47 preceding siblings ...)
  2024-06-24 23:58 ` patch 'eventdev/crypto: fix opaque field handling' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/fm10k: fix cleanup during init failure' " luca.boccassi
                   ` (30 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Kevin Traynor; +Cc: David Marchand, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/4c07a5e8c1fecea606b82944dd743943ac589e94

Thanks.

Luca Boccassi

---
From 4c07a5e8c1fecea606b82944dd743943ac589e94 Mon Sep 17 00:00:00 2001
From: Kevin Traynor <ktraynor@redhat.com>
Date: Thu, 13 Jun 2024 17:14:29 +0100
Subject: [PATCH] eal: fix logs for '--lcores'

[ upstream commit 0f241cc22e30de0dfd7487dcfd6acde220b5e168 ]

The argument is '--lcores' but it is being logged as '--lcore'
in several places.

e.g.
$ dpdk-testpmd -l 8,10,12 --lcores 8,10,12
EAL: Option --lcore is ignored, because (-l) is set!

Fix the spelling in logs and tests.

Fixes: 117eaa70584b ("eal: add error check for core options")
Fixes: 128ee4c26d87 ("app/test: add unit tests for --lcores option")

Signed-off-by: Kevin Traynor <ktraynor@redhat.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
---
 app/test/test_eal_flags.c           | 2 +-
 lib/eal/common/eal_common_options.c | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/app/test/test_eal_flags.c b/app/test/test_eal_flags.c
index d2b91e2075..f4740ee6e5 100644
--- a/app/test/test_eal_flags.c
+++ b/app/test/test_eal_flags.c
@@ -671,7 +671,7 @@ test_missing_c_flag(void)
 	    launch_proc(argv26) == 0 || launch_proc(argv27) == 0 ||
 	    launch_proc(argv28) == 0 || launch_proc(argv30) == 0) {
 		printf("Error - "
-		       "process ran without error with invalid --lcore flag\n");
+		       "process ran without error with invalid --lcores flag\n");
 		return -1;
 	}
 
diff --git a/lib/eal/common/eal_common_options.c b/lib/eal/common/eal_common_options.c
index 18a50f7452..5312d03552 100644
--- a/lib/eal/common/eal_common_options.c
+++ b/lib/eal/common/eal_common_options.c
@@ -1686,7 +1686,7 @@ eal_parse_common_option(int opt, const char *optarg,
 		if (core_parsed) {
 			RTE_LOG(ERR, EAL, "Option -c is ignored, because (%s) is set!\n",
 				(core_parsed == LCORE_OPT_LST) ? "-l" :
-				(core_parsed == LCORE_OPT_MAP) ? "--lcore" :
+				(core_parsed == LCORE_OPT_MAP) ? "--lcores" :
 				"-c");
 			return -1;
 		}
@@ -1719,7 +1719,7 @@ eal_parse_common_option(int opt, const char *optarg,
 		if (core_parsed) {
 			RTE_LOG(ERR, EAL, "Option -l is ignored, because (%s) is set!\n",
 				(core_parsed == LCORE_OPT_MSK) ? "-c" :
-				(core_parsed == LCORE_OPT_MAP) ? "--lcore" :
+				(core_parsed == LCORE_OPT_MAP) ? "--lcores" :
 				"-l");
 			return -1;
 		}
@@ -1900,10 +1900,10 @@ eal_parse_common_option(int opt, const char *optarg,
 		}
 
 		if (core_parsed) {
-			RTE_LOG(ERR, EAL, "Option --lcore is ignored, because (%s) is set!\n",
+			RTE_LOG(ERR, EAL, "Option --lcores is ignored, because (%s) is set!\n",
 				(core_parsed == LCORE_OPT_LST) ? "-l" :
 				(core_parsed == LCORE_OPT_MSK) ? "-c" :
-				"--lcore");
+				"--lcores");
 			return -1;
 		}
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.458431083 +0100
+++ 0050-eal-fix-logs-for-lcores.patch	2024-06-25 00:22:13.181185567 +0100
@@ -1 +1 @@
-From 0f241cc22e30de0dfd7487dcfd6acde220b5e168 Mon Sep 17 00:00:00 2001
+From 4c07a5e8c1fecea606b82944dd743943ac589e94 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0f241cc22e30de0dfd7487dcfd6acde220b5e168 ]
+
@@ -26 +28 @@
-index 6cb4b06757..71d8dba731 100644
+index d2b91e2075..f4740ee6e5 100644
@@ -39 +41 @@
-index e541f07939..f1a5e329a5 100644
+index 18a50f7452..5312d03552 100644
@@ -42 +44 @@
-@@ -1687,7 +1687,7 @@ eal_parse_common_option(int opt, const char *optarg,
+@@ -1686,7 +1686,7 @@ eal_parse_common_option(int opt, const char *optarg,
@@ -44 +46 @@
- 			EAL_LOG(ERR, "Option -c is ignored, because (%s) is set!",
+ 			RTE_LOG(ERR, EAL, "Option -c is ignored, because (%s) is set!\n",
@@ -51 +53 @@
-@@ -1720,7 +1720,7 @@ eal_parse_common_option(int opt, const char *optarg,
+@@ -1719,7 +1719,7 @@ eal_parse_common_option(int opt, const char *optarg,
@@ -53 +55 @@
- 			EAL_LOG(ERR, "Option -l is ignored, because (%s) is set!",
+ 			RTE_LOG(ERR, EAL, "Option -l is ignored, because (%s) is set!\n",
@@ -60 +62 @@
-@@ -1901,10 +1901,10 @@ eal_parse_common_option(int opt, const char *optarg,
+@@ -1900,10 +1900,10 @@ eal_parse_common_option(int opt, const char *optarg,
@@ -64,2 +66,2 @@
--			EAL_LOG(ERR, "Option --lcore is ignored, because (%s) is set!",
-+			EAL_LOG(ERR, "Option --lcores is ignored, because (%s) is set!",
+-			RTE_LOG(ERR, EAL, "Option --lcore is ignored, because (%s) is set!\n",
++			RTE_LOG(ERR, EAL, "Option --lcores is ignored, because (%s) is set!\n",

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

* patch 'net/fm10k: fix cleanup during init failure' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (48 preceding siblings ...)
  2024-06-24 23:58 ` patch 'eal: fix logs for '--lcores'' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/ixgbe: do not update link status in secondary process' " luca.boccassi
                   ` (29 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Julien Meunier; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/f461c249ff19a1744dea7c2ab117fa6872e1d606

Thanks.

Luca Boccassi

---
From f461c249ff19a1744dea7c2ab117fa6872e1d606 Mon Sep 17 00:00:00 2001
From: Julien Meunier <julien.meunier@nokia.com>
Date: Wed, 3 Apr 2024 13:55:41 +0200
Subject: [PATCH] net/fm10k: fix cleanup during init failure

[ upstream commit cd7f5da2e7d647863a3d6552b6787f413bbd05f2 ]

Cleanup was not done on this PMD if a error is seen during the init:
- possible memory leak due to a missing free
- interrupt handler was not disabled: if an IRQ is received after the
  init, a SIGSEGV can be seen (private data stored in
  rte_eth_devices[port_id] is pointing to NULL)

Fixes: a6061d9e7075 ("fm10k: register PF driver")
Fixes: 4c287332c39a ("fm10k: add PF and VF interrupt handling")

Signed-off-by: Julien Meunier <julien.meunier@nokia.com>
Reviewed-by: Bruce Richardson <bruce.richardson@intel.com>
---
 drivers/net/fm10k/fm10k_ethdev.c | 39 +++++++++++++++++++++++++++-----
 1 file changed, 33 insertions(+), 6 deletions(-)

diff --git a/drivers/net/fm10k/fm10k_ethdev.c b/drivers/net/fm10k/fm10k_ethdev.c
index 8b83063f0a..a4e06a0cfa 100644
--- a/drivers/net/fm10k/fm10k_ethdev.c
+++ b/drivers/net/fm10k/fm10k_ethdev.c
@@ -3055,7 +3055,7 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
 	struct fm10k_hw *hw = FM10K_DEV_PRIVATE_TO_HW(dev->data->dev_private);
 	struct rte_pci_device *pdev = RTE_ETH_DEV_TO_PCI(dev);
 	struct rte_intr_handle *intr_handle = pdev->intr_handle;
-	int diag, i;
+	int diag, i, ret;
 	struct fm10k_macvlan_filter_info *macvlan;
 
 	PMD_INIT_FUNC_TRACE();
@@ -3144,21 +3144,24 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
 	diag = fm10k_stats_reset(dev);
 	if (diag != 0) {
 		PMD_INIT_LOG(ERR, "Stats reset failed: %d", diag);
-		return diag;
+		ret = diag;
+		goto err_stat;
 	}
 
 	/* Reset the hw */
 	diag = fm10k_reset_hw(hw);
 	if (diag != FM10K_SUCCESS) {
 		PMD_INIT_LOG(ERR, "Hardware reset failed: %d", diag);
-		return -EIO;
+		ret = -EIO;
+		goto err_reset_hw;
 	}
 
 	/* Setup mailbox service */
 	diag = fm10k_setup_mbx_service(hw);
 	if (diag != FM10K_SUCCESS) {
 		PMD_INIT_LOG(ERR, "Failed to setup mailbox: %d", diag);
-		return -EIO;
+		ret = -EIO;
+		goto err_mbx;
 	}
 
 	/*PF/VF has different interrupt handling mechanism */
@@ -3197,7 +3200,8 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
 
 		if (switch_ready == false) {
 			PMD_INIT_LOG(ERR, "switch is not ready");
-			return -1;
+			ret = -1;
+			goto err_switch_ready;
 		}
 	}
 
@@ -3232,7 +3236,8 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
 
 		if (!hw->mac.default_vid) {
 			PMD_INIT_LOG(ERR, "default VID is not ready");
-			return -1;
+			ret = -1;
+			goto err_vid;
 		}
 	}
 
@@ -3241,6 +3246,28 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
 		MAIN_VSI_POOL_NUMBER);
 
 	return 0;
+
+err_vid:
+err_switch_ready:
+	rte_intr_disable(intr_handle);
+
+	if (hw->mac.type == fm10k_mac_pf) {
+		fm10k_dev_disable_intr_pf(dev);
+		rte_intr_callback_unregister(intr_handle,
+			fm10k_dev_interrupt_handler_pf, (void *)dev);
+	} else {
+		fm10k_dev_disable_intr_vf(dev);
+		rte_intr_callback_unregister(intr_handle,
+			fm10k_dev_interrupt_handler_vf, (void *)dev);
+	}
+
+err_mbx:
+err_reset_hw:
+err_stat:
+	rte_free(dev->data->mac_addrs);
+	dev->data->mac_addrs = NULL;
+
+	return ret;
 }
 
 static int
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.503503953 +0100
+++ 0051-net-fm10k-fix-cleanup-during-init-failure.patch	2024-06-25 00:22:13.185185649 +0100
@@ -1 +1 @@
-From cd7f5da2e7d647863a3d6552b6787f413bbd05f2 Mon Sep 17 00:00:00 2001
+From f461c249ff19a1744dea7c2ab117fa6872e1d606 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit cd7f5da2e7d647863a3d6552b6787f413bbd05f2 ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index fa0d16277e..7b490bea17 100644
+index 8b83063f0a..a4e06a0cfa 100644
@@ -26 +27 @@
-@@ -3058,7 +3058,7 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
+@@ -3055,7 +3055,7 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
@@ -35 +36 @@
-@@ -3147,21 +3147,24 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
+@@ -3144,21 +3144,24 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
@@ -63 +64 @@
-@@ -3200,7 +3203,8 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
+@@ -3197,7 +3200,8 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
@@ -73 +74 @@
-@@ -3235,7 +3239,8 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
+@@ -3232,7 +3236,8 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
@@ -83 +84 @@
-@@ -3244,6 +3249,28 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)
+@@ -3241,6 +3246,28 @@ eth_fm10k_dev_init(struct rte_eth_dev *dev)

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

* patch 'net/ixgbe: do not update link status in secondary process' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (49 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/fm10k: fix cleanup during init failure' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/ixgbe: do not create delayed interrupt handler twice' " luca.boccassi
                   ` (28 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: Jun Wang, Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/23efe3ba7a60f0af5d654d49474a5dfc6f6dff0f

Thanks.

Luca Boccassi

---
From 23efe3ba7a60f0af5d654d49474a5dfc6f6dff0f Mon Sep 17 00:00:00 2001
From: Stephen Hemminger <stephen@networkplumber.org>
Date: Wed, 20 Mar 2024 10:33:04 -0700
Subject: [PATCH] net/ixgbe: do not update link status in secondary process

[ upstream commit 5ffd40b85febd2a80b88b4cfbf4e1dd7e5f059c5 ]

The code to update link status is not safe in secondary process.
If called from secondary it will crash, example from dumpcap:
	ixgbe_dev_link_update_share()
	ixgbe_dev_link_update()
	rte_eth_link_get()

Fixes: af75078fece3 ("first public release")

Reported-by: Jun Wang <junwang01@cestc.cn>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index 9c0e0efb66..311a6828a0 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -4283,6 +4283,9 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev,
 	int wait = 1;
 	u32 esdp_reg;
 
+	if (rte_eal_process_type() != RTE_PROC_PRIMARY)
+		return -1;
+
 	memset(&link, 0, sizeof(link));
 	link.link_status = RTE_ETH_LINK_DOWN;
 	link.link_speed = RTE_ETH_SPEED_NUM_NONE;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.549761459 +0100
+++ 0052-net-ixgbe-do-not-update-link-status-in-secondary-pro.patch	2024-06-25 00:22:13.193185812 +0100
@@ -1 +1 @@
-From 5ffd40b85febd2a80b88b4cfbf4e1dd7e5f059c5 Mon Sep 17 00:00:00 2001
+From 23efe3ba7a60f0af5d654d49474a5dfc6f6dff0f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 5ffd40b85febd2a80b88b4cfbf4e1dd7e5f059c5 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index bbdc996f31..a6916da0c5 100644
+index 9c0e0efb66..311a6828a0 100644
@@ -26 +27 @@
-@@ -4293,6 +4293,9 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev,
+@@ -4283,6 +4283,9 @@ ixgbe_dev_link_update_share(struct rte_eth_dev *dev,

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

* patch 'net/ixgbe: do not create delayed interrupt handler twice' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (50 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/ixgbe: do not update link status in secondary process' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/e1000/base: fix link power down' " luca.boccassi
                   ` (27 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Edwin Brossette; +Cc: Anatoly Burakov, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/b2e98edd71e3695d23c9f83840246099fb23f28d

Thanks.

Luca Boccassi

---
From b2e98edd71e3695d23c9f83840246099fb23f28d Mon Sep 17 00:00:00 2001
From: Edwin Brossette <edwin.brossette@6wind.com>
Date: Thu, 18 Apr 2024 15:53:07 +0200
Subject: [PATCH] net/ixgbe: do not create delayed interrupt handler twice

[ upstream commit 130ece79670d57760acd18c9671f91a4cd4e07a0 ]

Since link state may need some time to stabilize after a link state
change, we cannot update the link state right after one occurs. So link
state change interrupts (LSC) are handled after a delay. To do this, an
alarm to call a delayed handler is programmed. This delayed handler is
tasked with updating the link after a variable delay of one to four
seconds which should be enough time for the link state to become stable
again.

However, a problem can occur with some models of network cards. For
example, ixgbe_mac_X550EM_x may trigger this interrupt twice because
another interrupt signal is received on the General Purpose Interrupt
pin SPD0, which has the same interrupt handler. In such a case, the
delayed interrupt handler would be programmed to be executed twice.

Since we save the original interrupt mask value to restore it after the
delayed handler is done with its work, we end up overwriting its value
after the second alarm is programmed. Even worse: when restoring it the
first time, the saved original mask variable is reset to 0, so we end up
completely disabling all interrupts when trying to restore this mask
after the second time the delayed handler is executed.

Add a check on the interrupt mask value when programming the alarm for
the delayed handler. If the bit for LSC interrupts is unset, it means an
alarm was already programmed for the delayed handler. In this case, skip
the alarm creation.

Fixes: 9b667210700e ("net/ixgbe: fix blocked interrupts")

Signed-off-by: Edwin Brossette <edwin.brossette@6wind.com>
Reviewed-by: Anatoly Burakov <anatoly.burakov@intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 22 ++++++++++++++--------
 1 file changed, 14 insertions(+), 8 deletions(-)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index 311a6828a0..9e1a65a50a 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -4660,14 +4660,20 @@ ixgbe_dev_interrupt_action(struct rte_eth_dev *dev)
 			timeout = IXGBE_LINK_DOWN_CHECK_TIMEOUT;
 
 		ixgbe_dev_link_status_print(dev);
-		if (rte_eal_alarm_set(timeout * 1000,
-				      ixgbe_dev_interrupt_delayed_handler, (void *)dev) < 0)
-			PMD_DRV_LOG(ERR, "Error setting alarm");
-		else {
-			/* remember original mask */
-			intr->mask_original = intr->mask;
-			/* only disable lsc interrupt */
-			intr->mask &= ~IXGBE_EIMS_LSC;
+
+		/* Don't program delayed handler if LSC interrupt is disabled.
+		 * It means one is already programmed.
+		 */
+		if (intr->mask & IXGBE_EIMS_LSC) {
+			if (rte_eal_alarm_set(timeout * 1000,
+					      ixgbe_dev_interrupt_delayed_handler, (void *)dev) < 0)
+				PMD_DRV_LOG(ERR, "Error setting alarm");
+			else {
+				/* remember original mask */
+				intr->mask_original = intr->mask;
+				/* only disable lsc interrupt */
+				intr->mask &= ~IXGBE_EIMS_LSC;
+			}
 		}
 	}
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.589954884 +0100
+++ 0053-net-ixgbe-do-not-create-delayed-interrupt-handler-tw.patch	2024-06-25 00:22:13.197185893 +0100
@@ -1 +1 @@
-From 130ece79670d57760acd18c9671f91a4cd4e07a0 Mon Sep 17 00:00:00 2001
+From b2e98edd71e3695d23c9f83840246099fb23f28d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 130ece79670d57760acd18c9671f91a4cd4e07a0 ]
+
@@ -33 +34,0 @@
-Cc: stable@dpdk.org
@@ -42 +43 @@
-index a6916da0c5..1f93be98ca 100644
+index 311a6828a0..9e1a65a50a 100644
@@ -45 +46 @@
-@@ -4672,14 +4672,20 @@ ixgbe_dev_interrupt_action(struct rte_eth_dev *dev)
+@@ -4660,14 +4660,20 @@ ixgbe_dev_interrupt_action(struct rte_eth_dev *dev)

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

* patch 'net/e1000/base: fix link power down' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (51 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/ixgbe: do not create delayed interrupt handler twice' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/ixgbe/base: revert advertising for X550 2.5G/5G' " luca.boccassi
                   ` (26 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Anatoly Burakov; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/229bdd77bb5a0b0740caca211792eaaa577bebd4

Thanks.

Luca Boccassi

---
From 229bdd77bb5a0b0740caca211792eaaa577bebd4 Mon Sep 17 00:00:00 2001
From: Anatoly Burakov <anatoly.burakov@intel.com>
Date: Tue, 14 May 2024 16:17:16 +0100
Subject: [PATCH] net/e1000/base: fix link power down

[ upstream commit a8218d09e3aaae5307325ff4b2f92ed4a3c37a8c ]

Current code is a result of work to reduce duplication between various
device models. However, the logic that was replaced did not exactly
match the new logic, and as a result the link power down was not
working correctly for some NICs, and the link remained up even when
the interface is down.

Fix it to correctly power down the link under all circumstances that
were supported by old logic.

Fixes: 44dddd14059f ("net/e1000/base: remove duplicated codes")

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 drivers/net/e1000/base/e1000_base.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/e1000/base/e1000_base.c b/drivers/net/e1000/base/e1000_base.c
index ab73e1e59e..3ec32e7240 100644
--- a/drivers/net/e1000/base/e1000_base.c
+++ b/drivers/net/e1000/base/e1000_base.c
@@ -107,7 +107,7 @@ void e1000_power_down_phy_copper_base(struct e1000_hw *hw)
 		return;
 
 	/* If the management interface is not enabled, then power down */
-	if (phy->ops.check_reset_block(hw))
+	if (!(e1000_enable_mng_pass_thru(hw) || phy->ops.check_reset_block(hw)))
 		e1000_power_down_phy_copper(hw);
 }
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.628461719 +0100
+++ 0054-net-e1000-base-fix-link-power-down.patch	2024-06-25 00:22:13.197185893 +0100
@@ -1 +1 @@
-From a8218d09e3aaae5307325ff4b2f92ed4a3c37a8c Mon Sep 17 00:00:00 2001
+From 229bdd77bb5a0b0740caca211792eaaa577bebd4 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a8218d09e3aaae5307325ff4b2f92ed4a3c37a8c ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org

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

* patch 'net/ixgbe/base: revert advertising for X550 2.5G/5G' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (52 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/e1000/base: fix link power down' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/ixgbe/base: fix 5G link speed reported on VF' " luca.boccassi
                   ` (25 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Piotr Pietruszewski
  Cc: Piotr Skajewski, Marek Mical, Jeff Kirsher, Alice Michael, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/5e73514050ef0367456e035b851ef83edf86676b

Thanks.

Luca Boccassi

---
From 5e73514050ef0367456e035b851ef83edf86676b Mon Sep 17 00:00:00 2001
From: Piotr Pietruszewski <piotr.pietruszewski@intel.com>
Date: Thu, 30 May 2024 12:13:34 +0100
Subject: [PATCH] net/ixgbe/base: revert advertising for X550 2.5G/5G

[ upstream commit 9ac063a739b00188281ba4ef5c6a0e43cc59a3b8 ]

The commit removing advertising 2.5G and 5G speeds from
ixgbe_get_copper_speeds_supported() was supposed to disable 2.5G and 5G
during the autonegotiation with default settings. However, that change
prevented OS-specific part of the driver from forcing these speeds at
user request.

This change reverts the commit and adds 2.5G and 5G as speeds supported
by the X550.

Fixes: 13de2444449e ("net/ixgbe/base: remove default advertising for x550 2.5G/5G")

Signed-off-by: Piotr Pietruszewski <piotr.pietruszewski@intel.com>
Reviewed-by: Piotr Skajewski <piotrx.skajewski@intel.com>
Reviewed-by: Marek Mical <marekx.mical@intel.com>
Reviewed-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Reviewed-by: Alice Michael <alice.michael@intel.com>
---
 .mailmap                           | 1 +
 drivers/net/ixgbe/base/ixgbe_phy.c | 4 ++++
 2 files changed, 5 insertions(+)

diff --git a/.mailmap b/.mailmap
index 2724a689fd..4cdd9f04d9 100644
--- a/.mailmap
+++ b/.mailmap
@@ -845,6 +845,7 @@ Marcin Wojtas <mw@semihalf.com>
 Marcin Zapolski <marcinx.a.zapolski@intel.com>
 Marco Varlese <mvarlese@suse.de>
 Marc Sune <marcdevel@gmail.com> <marc.sune@bisdn.de>
+Marek Mical <marekx.mical@intel.com>
 Maria Lingemark <maria.lingemark@ericsson.com>
 Mario Carrillo <mario.alfredo.c.arevalo@intel.com>
 Mário Kuka <kuka@cesnet.cz>
diff --git a/drivers/net/ixgbe/base/ixgbe_phy.c b/drivers/net/ixgbe/base/ixgbe_phy.c
index 74c5db16fa..3a8e603472 100644
--- a/drivers/net/ixgbe/base/ixgbe_phy.c
+++ b/drivers/net/ixgbe/base/ixgbe_phy.c
@@ -915,6 +915,10 @@ static s32 ixgbe_get_copper_speeds_supported(struct ixgbe_hw *hw)
 		hw->phy.speeds_supported |= IXGBE_LINK_SPEED_100_FULL;
 
 	switch (hw->mac.type) {
+	case ixgbe_mac_X550:
+		hw->phy.speeds_supported |= IXGBE_LINK_SPEED_2_5GB_FULL;
+		hw->phy.speeds_supported |= IXGBE_LINK_SPEED_5GB_FULL;
+		break;
 	case ixgbe_mac_X550EM_x:
 	case ixgbe_mac_X550EM_a:
 		hw->phy.speeds_supported &= ~IXGBE_LINK_SPEED_100_FULL;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.661860969 +0100
+++ 0055-net-ixgbe-base-revert-advertising-for-X550-2.5G-5G.patch	2024-06-25 00:22:13.201185974 +0100
@@ -1 +1 @@
-From 9ac063a739b00188281ba4ef5c6a0e43cc59a3b8 Mon Sep 17 00:00:00 2001
+From 5e73514050ef0367456e035b851ef83edf86676b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 9ac063a739b00188281ba4ef5c6a0e43cc59a3b8 ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -29 +30 @@
-index 075ea40f17..508d4eba24 100644
+index 2724a689fd..4cdd9f04d9 100644
@@ -32 +33 @@
-@@ -892,6 +892,7 @@ Marcin Wojtas <mw@semihalf.com>
+@@ -845,6 +845,7 @@ Marcin Wojtas <mw@semihalf.com>

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

* patch 'net/ixgbe/base: fix 5G link speed reported on VF' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (53 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/ixgbe/base: revert advertising for X550 2.5G/5G' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/ixgbe/base: fix PHY ID for X550' " luca.boccassi
                   ` (24 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Piotr Skajewski
  Cc: Radoslaw Tyl, Slawomir Mrozowicz, Alice Michael, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/7b94a8b53e76bc9cdc14b5d423e3643318090e6a

Thanks.

Luca Boccassi

---
From 7b94a8b53e76bc9cdc14b5d423e3643318090e6a Mon Sep 17 00:00:00 2001
From: Piotr Skajewski <piotrx.skajewski@intel.com>
Date: Thu, 30 May 2024 12:13:35 +0100
Subject: [PATCH] net/ixgbe/base: fix 5G link speed reported on VF

[ upstream commit 9eb7fdbd47cf02068715a6e8bef767b0deea6f94 ]

When 5000 Base-T was set on PF the VF reported 100 Base-T. This patch
changes ixgbe_check_mac_link_vf function where there was an incorrect
conditional which checks using PF mac types, now it is correctly
using VF mac types.

Fixes: 12e20906905c ("net/ixgbe/base: include new speeds in VFLINK interpretation")

Signed-off-by: Piotr Skajewski <piotrx.skajewski@intel.com>
Reviewed-by: Radoslaw Tyl <radoslawx.tyl@intel.com>
Reviewed-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
Reviewed-by: Alice Michael <alice.michael@intel.com>
---
 .mailmap                          | 1 +
 drivers/net/ixgbe/base/ixgbe_vf.c | 6 +++---
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/.mailmap b/.mailmap
index 4cdd9f04d9..e8953af6f0 100644
--- a/.mailmap
+++ b/.mailmap
@@ -1112,6 +1112,7 @@ Quentin Armitage <quentin@armitage.org.uk>
 Qun Wan <qun.wan@intel.com>
 Radha Mohan Chintakuntla <radhac@marvell.com>
 Radoslaw Biernacki <rad@semihalf.com> <radoslaw.biernacki@linaro.org>
+Radoslaw Tyl <radoslawx.tyl@intel.com>
 Radu Bulie <radu-andrei.bulie@nxp.com>
 Radu Nicolau <radu.nicolau@intel.com>
 Rafael Ávila de Espíndola <espindola@scylladb.com>
diff --git a/drivers/net/ixgbe/base/ixgbe_vf.c b/drivers/net/ixgbe/base/ixgbe_vf.c
index 5e3ae1b519..11dbbe2a86 100644
--- a/drivers/net/ixgbe/base/ixgbe_vf.c
+++ b/drivers/net/ixgbe/base/ixgbe_vf.c
@@ -585,7 +585,7 @@ s32 ixgbe_check_mac_link_vf(struct ixgbe_hw *hw, ixgbe_link_speed *speed,
 	switch (links_reg & IXGBE_LINKS_SPEED_82599) {
 	case IXGBE_LINKS_SPEED_10G_82599:
 		*speed = IXGBE_LINK_SPEED_10GB_FULL;
-		if (hw->mac.type >= ixgbe_mac_X550) {
+		if (hw->mac.type >= ixgbe_mac_X550_vf) {
 			if (links_reg & IXGBE_LINKS_SPEED_NON_STD)
 				*speed = IXGBE_LINK_SPEED_2_5GB_FULL;
 		}
@@ -595,7 +595,7 @@ s32 ixgbe_check_mac_link_vf(struct ixgbe_hw *hw, ixgbe_link_speed *speed,
 		break;
 	case IXGBE_LINKS_SPEED_100_82599:
 		*speed = IXGBE_LINK_SPEED_100_FULL;
-		if (hw->mac.type == ixgbe_mac_X550) {
+		if (hw->mac.type == ixgbe_mac_X550_vf) {
 			if (links_reg & IXGBE_LINKS_SPEED_NON_STD)
 				*speed = IXGBE_LINK_SPEED_5GB_FULL;
 		}
@@ -603,7 +603,7 @@ s32 ixgbe_check_mac_link_vf(struct ixgbe_hw *hw, ixgbe_link_speed *speed,
 	case IXGBE_LINKS_SPEED_10_X550EM_A:
 		*speed = IXGBE_LINK_SPEED_UNKNOWN;
 		/* Since Reserved in older MAC's */
-		if (hw->mac.type >= ixgbe_mac_X550)
+		if (hw->mac.type >= ixgbe_mac_X550_vf)
 			*speed = IXGBE_LINK_SPEED_10_FULL;
 		break;
 	default:
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.698596890 +0100
+++ 0056-net-ixgbe-base-fix-5G-link-speed-reported-on-VF.patch	2024-06-25 00:22:13.205186057 +0100
@@ -1 +1 @@
-From 9eb7fdbd47cf02068715a6e8bef767b0deea6f94 Mon Sep 17 00:00:00 2001
+From 7b94a8b53e76bc9cdc14b5d423e3643318090e6a Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 9eb7fdbd47cf02068715a6e8bef767b0deea6f94 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -24 +25 @@
-index 508d4eba24..be16cabd07 100644
+index 4cdd9f04d9..e8953af6f0 100644
@@ -27 +28 @@
-@@ -1173,6 +1173,7 @@ Quentin Armitage <quentin@armitage.org.uk>
+@@ -1112,6 +1112,7 @@ Quentin Armitage <quentin@armitage.org.uk>

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

* patch 'net/ixgbe/base: fix PHY ID for X550' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (54 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/ixgbe/base: fix 5G link speed reported on VF' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/cnxk: fix RSS config' " luca.boccassi
                   ` (23 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Radoslaw Tyl; +Cc: Piotr Skajewski, Alice Michael, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/8873f14545fb51cc67f25d38f0eb7d3c1c5cc24b

Thanks.

Luca Boccassi

---
From 8873f14545fb51cc67f25d38f0eb7d3c1c5cc24b Mon Sep 17 00:00:00 2001
From: Radoslaw Tyl <radoslawx.tyl@intel.com>
Date: Thu, 30 May 2024 12:13:36 +0100
Subject: [PATCH] net/ixgbe/base: fix PHY ID for X550

[ upstream commit a9f5a3bd4c179e54b5ca95b0ce191bf4f33d2add ]

Function ixgbe_get_phy_type_from_id() for X550_PHY_ID2 and
X550_PHY_ID3 always return ixgbe_phy_unknown instead of ixgbe_phy_aq
because phy ID's last 4 bits are always masked, and should not be
taken into account when selecting phy type.

This patch adds default PHY ID for X550 devices with mask on last 4
bits (0xFFFFFFF0), and fixes the switch statement to use it.

Fixes: 58ddc803e412 ("ixgbe/base: add new X550 PHY ids")

Signed-off-by: Radoslaw Tyl <radoslawx.tyl@intel.com>
Reviewed-by: Piotr Skajewski <piotrx.skajewski@intel.com>
Reviewed-by: Alice Michael <alice.michael@intel.com>
---
 drivers/net/ixgbe/base/ixgbe_phy.c  | 3 +--
 drivers/net/ixgbe/base/ixgbe_type.h | 1 +
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ixgbe/base/ixgbe_phy.c b/drivers/net/ixgbe/base/ixgbe_phy.c
index 3a8e603472..56267bb00d 100644
--- a/drivers/net/ixgbe/base/ixgbe_phy.c
+++ b/drivers/net/ixgbe/base/ixgbe_phy.c
@@ -432,8 +432,7 @@ enum ixgbe_phy_type ixgbe_get_phy_type_from_id(u32 phy_id)
 	case TN1010_PHY_ID:
 		phy_type = ixgbe_phy_tn;
 		break;
-	case X550_PHY_ID2:
-	case X550_PHY_ID3:
+	case X550_PHY_ID:
 	case X540_PHY_ID:
 		phy_type = ixgbe_phy_aq;
 		break;
diff --git a/drivers/net/ixgbe/base/ixgbe_type.h b/drivers/net/ixgbe/base/ixgbe_type.h
index dc765f13c9..5973c60477 100644
--- a/drivers/net/ixgbe/base/ixgbe_type.h
+++ b/drivers/net/ixgbe/base/ixgbe_type.h
@@ -1663,6 +1663,7 @@ struct ixgbe_dmac_config {
 #define TN1010_PHY_ID	0x00A19410
 #define TNX_FW_REV	0xB
 #define X540_PHY_ID	0x01540200
+#define X550_PHY_ID	0x01540220
 #define X550_PHY_ID2	0x01540223
 #define X550_PHY_ID3	0x01540221
 #define X557_PHY_ID	0x01540240
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.733656108 +0100
+++ 0057-net-ixgbe-base-fix-PHY-ID-for-X550.patch	2024-06-25 00:22:13.209186138 +0100
@@ -1 +1 @@
-From a9f5a3bd4c179e54b5ca95b0ce191bf4f33d2add Mon Sep 17 00:00:00 2001
+From 8873f14545fb51cc67f25d38f0eb7d3c1c5cc24b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a9f5a3bd4c179e54b5ca95b0ce191bf4f33d2add ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -40 +41 @@
-index 35212a561b..f709681df2 100644
+index dc765f13c9..5973c60477 100644
@@ -43 +44 @@
-@@ -1664,6 +1664,7 @@ struct ixgbe_dmac_config {
+@@ -1663,6 +1663,7 @@ struct ixgbe_dmac_config {

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

* patch 'net/cnxk: fix RSS config' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (55 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/ixgbe/base: fix PHY ID for X550' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/cnxk: fix outbound security with higher packet burst' " luca.boccassi
                   ` (22 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Sunil Kumar Kori; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/d1c48d821e1b78aeafc0921710bcb28702c3f137

Thanks.

Luca Boccassi

---
From d1c48d821e1b78aeafc0921710bcb28702c3f137 Mon Sep 17 00:00:00 2001
From: Sunil Kumar Kori <skori@marvell.com>
Date: Thu, 23 May 2024 20:23:21 +0530
Subject: [PATCH] net/cnxk: fix RSS config

[ upstream commit d3654d35176dcc6e5ebb7bab00c7fdd6b61fc1f0 ]

Currently user passed RSS configuration is ignored via
rte_eth_dev_configure() API. Instead default RSS setup
is done by driver.

Adding handling for user passed RSS configuration too
via rte_eth_dev_configure().

Fixes: b75e0aca84b0 ("net/cnxk: add device configuration operation")

Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
---
 drivers/net/cnxk/cnxk_ethdev.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/net/cnxk/cnxk_ethdev.c b/drivers/net/cnxk/cnxk_ethdev.c
index f9245258cb..56b26a9650 100644
--- a/drivers/net/cnxk/cnxk_ethdev.c
+++ b/drivers/net/cnxk/cnxk_ethdev.c
@@ -1334,6 +1334,13 @@ cnxk_nix_configure(struct rte_eth_dev *eth_dev)
 		goto free_nix_lf;
 	}
 
+	/* Overwrite default RSS setup if requested by user */
+	rc = cnxk_nix_rss_hash_update(eth_dev, &conf->rx_adv_conf.rss_conf);
+	if (rc) {
+		plt_err("Failed to configure rss rc=%d", rc);
+		goto free_nix_lf;
+	}
+
 	/* Init the default TM scheduler hierarchy */
 	rc = roc_nix_tm_init(nix);
 	if (rc) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.773206636 +0100
+++ 0058-net-cnxk-fix-RSS-config.patch	2024-06-25 00:22:13.209186138 +0100
@@ -1 +1 @@
-From d3654d35176dcc6e5ebb7bab00c7fdd6b61fc1f0 Mon Sep 17 00:00:00 2001
+From d1c48d821e1b78aeafc0921710bcb28702c3f137 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d3654d35176dcc6e5ebb7bab00c7fdd6b61fc1f0 ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 6b37bd877f..95a3d8aaf9 100644
+index f9245258cb..56b26a9650 100644
@@ -25 +26 @@
-@@ -1384,6 +1384,13 @@ cnxk_nix_configure(struct rte_eth_dev *eth_dev)
+@@ -1334,6 +1334,13 @@ cnxk_nix_configure(struct rte_eth_dev *eth_dev)

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

* patch 'net/cnxk: fix outbound security with higher packet burst' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (56 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/cnxk: fix RSS config' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/cnxk: fix promiscuous state after MAC change' " luca.boccassi
                   ` (21 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Nithin Dabilpuram; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/d9d6771ebabe8fef3a5263a89ef81e44ff3806ca

Thanks.

Luca Boccassi

---
From d9d6771ebabe8fef3a5263a89ef81e44ff3806ca Mon Sep 17 00:00:00 2001
From: Nithin Dabilpuram <ndabilpuram@marvell.com>
Date: Tue, 28 May 2024 12:35:19 +0530
Subject: [PATCH] net/cnxk: fix outbound security with higher packet burst

[ upstream commit 062f6f652445a283a186dc6c62c692ba7c91cc3c ]

Fix issue with outbound security path while handling mixed traffic i.e
both plain and inline outbound packets being present as part of burst
and burst size is > 32. The loop needs to be broken when
we don't have space for 4 packets in LMT lines for CPT considering
both the full LMT lines and partial LMT lines used.

Fixes: 55bfac717c72 ("net/cnxk: support Tx security offload on cn10k")

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
---
 drivers/net/cnxk/cn10k_tx.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/cnxk/cn10k_tx.h b/drivers/net/cnxk/cn10k_tx.h
index 254ddf0536..e96030621b 100644
--- a/drivers/net/cnxk/cn10k_tx.h
+++ b/drivers/net/cnxk/cn10k_tx.h
@@ -1843,7 +1843,8 @@ again:
 	}
 
 	for (i = 0; i < burst; i += NIX_DESCS_PER_LOOP) {
-		if (flags & NIX_TX_OFFLOAD_SECURITY_F && c_lnum + 2 > 16) {
+		if (flags & NIX_TX_OFFLOAD_SECURITY_F &&
+		    (((int)((16 - c_lnum) << 1) - c_loff) < 4)) {
 			burst = i;
 			break;
 		}
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.807683374 +0100
+++ 0059-net-cnxk-fix-outbound-security-with-higher-packet-bu.patch	2024-06-25 00:22:13.213186220 +0100
@@ -1 +1 @@
-From 062f6f652445a283a186dc6c62c692ba7c91cc3c Mon Sep 17 00:00:00 2001
+From d9d6771ebabe8fef3a5263a89ef81e44ff3806ca Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 062f6f652445a283a186dc6c62c692ba7c91cc3c ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 5c4b9e559e..9ce41fe80f 100644
+index 254ddf0536..e96030621b 100644
@@ -24 +25 @@
-@@ -2272,7 +2272,8 @@ again:
+@@ -1843,7 +1843,8 @@ again:

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

* patch 'net/cnxk: fix promiscuous state after MAC change' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (57 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/cnxk: fix outbound security with higher packet burst' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'graph: fix ID collisions' " luca.boccassi
                   ` (20 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Rahul Bhansali; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/e0da7a253dbd6dac1cba895d81742a50313e44fc

Thanks.

Luca Boccassi

---
From e0da7a253dbd6dac1cba895d81742a50313e44fc Mon Sep 17 00:00:00 2001
From: Rahul Bhansali <rbhansali@marvell.com>
Date: Tue, 28 May 2024 14:02:46 +0530
Subject: [PATCH] net/cnxk: fix promiscuous state after MAC change

[ upstream commit 5f1bce00fddffc63e5634891df2b02859c010944 ]

If promiscuous mode is enabled and default MAC address is set
again then promiscuous mode gets disabled in hardware.

This change will restore promiscuous behavior after configuring
default MAC address.

Fixes: 5fe86db2a0dd ("net/cnxk: support MAC address set")

Signed-off-by: Rahul Bhansali <rbhansali@marvell.com>
---
 drivers/net/cnxk/cnxk_ethdev_ops.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/net/cnxk/cnxk_ethdev_ops.c b/drivers/net/cnxk/cnxk_ethdev_ops.c
index be29b385a4..5fd39149cb 100644
--- a/drivers/net/cnxk/cnxk_ethdev_ops.c
+++ b/drivers/net/cnxk/cnxk_ethdev_ops.c
@@ -413,6 +413,13 @@ cnxk_nix_mac_addr_set(struct rte_eth_dev *eth_dev, struct rte_ether_addr *addr)
 			roc_nix_npc_mac_addr_set(nix, dev->mac_addr);
 			goto exit;
 		}
+
+		if (eth_dev->data->promiscuous) {
+			rc = roc_nix_mac_promisc_mode_enable(nix, true);
+			if (rc)
+				plt_err("Failed to setup promisc mode in mac, rc=%d(%s)", rc,
+					roc_error_msg_get(rc));
+		}
 	}
 
 	/* Update mac address to cnxk ethernet device */
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.843038050 +0100
+++ 0060-net-cnxk-fix-promiscuous-state-after-MAC-change.patch	2024-06-25 00:22:13.213186220 +0100
@@ -1 +1 @@
-From 5f1bce00fddffc63e5634891df2b02859c010944 Mon Sep 17 00:00:00 2001
+From e0da7a253dbd6dac1cba895d81742a50313e44fc Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 5f1bce00fddffc63e5634891df2b02859c010944 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index c8260fcb9c..b1093dd584 100644
+index be29b385a4..5fd39149cb 100644
@@ -24 +25 @@
-@@ -451,6 +451,13 @@ cnxk_nix_mac_addr_set(struct rte_eth_dev *eth_dev, struct rte_ether_addr *addr)
+@@ -413,6 +413,13 @@ cnxk_nix_mac_addr_set(struct rte_eth_dev *eth_dev, struct rte_ether_addr *addr)

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

* patch 'graph: fix ID collisions' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (58 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/cnxk: fix promiscuous state after MAC change' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'bpf: disable on 32-bit x86' " luca.boccassi
                   ` (19 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Robin Jarry; +Cc: Kiran Kumar K, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/145220677b0b20859be722c4cc6f90d882ce395d

Thanks.

Luca Boccassi

---
From 145220677b0b20859be722c4cc6f90d882ce395d Mon Sep 17 00:00:00 2001
From: Robin Jarry <rjarry@redhat.com>
Date: Tue, 18 Jun 2024 11:23:25 +0200
Subject: [PATCH] graph: fix ID collisions

[ upstream commit d5c8b6bb74a06051232cbbd92d25220606b280c0 ]

The graph id is determined based on a global variable that is
incremented every time a graph is created, and decremented every time
a graph is destroyed. This only works if graphs are destroyed in the
reverse order in which they have been created.

The following code produces duplicate graph IDs which can lead to
use-after-free bugs and other undefined behaviours:

  a = rte_graph_create(...); // id=0 graph_id=1
  b = rte_graph_create(...); // id=1 graph_id=2
  rte_graph_destroy(a);      // graph_id=1
  c = rte_graph_create(...); // id=1 graph_id=2 (duplicate with b)
  rte_graph_destroy(c);      // frees memory still used by b

Remove the global counter. Make sure that the graph list is always
ordered by increasing graph ids. When creating a new graph, pick a free
id which is not allocated.

Update unit tests to ensure it works as expected.

Fixes: a91fecc19c5c ("graph: implement create and destroy")

Signed-off-by: Robin Jarry <rjarry@redhat.com>
Acked-by: Kiran Kumar K <kirankumark@marvell.com>
---
 lib/graph/graph.c | 72 +++++++++++++++++++++++++++++++++++++++--------
 1 file changed, 61 insertions(+), 11 deletions(-)

diff --git a/lib/graph/graph.c b/lib/graph/graph.c
index 3a617cc369..9027e62a26 100644
--- a/lib/graph/graph.c
+++ b/lib/graph/graph.c
@@ -18,11 +18,54 @@
 
 static struct graph_head graph_list = STAILQ_HEAD_INITIALIZER(graph_list);
 static rte_spinlock_t graph_lock = RTE_SPINLOCK_INITIALIZER;
-static rte_graph_t graph_id;
-
-#define GRAPH_ID_CHECK(id) ID_CHECK(id, graph_id)
 
 /* Private functions */
+static struct graph *
+graph_from_id(rte_graph_t id)
+{
+	struct graph *graph;
+	STAILQ_FOREACH(graph, &graph_list, next) {
+		if (graph->id == id)
+			return graph;
+	}
+	rte_errno = EINVAL;
+	return NULL;
+}
+
+static rte_graph_t
+graph_next_free_id(void)
+{
+	struct graph *graph;
+	rte_graph_t id = 0;
+
+	STAILQ_FOREACH(graph, &graph_list, next) {
+		if (id < graph->id)
+			break;
+		id = graph->id + 1;
+	}
+
+	return id;
+}
+
+static void
+graph_insert_ordered(struct graph *graph)
+{
+	struct graph *after, *g;
+
+	after = NULL;
+	STAILQ_FOREACH(g, &graph_list, next) {
+		if (g->id < graph->id)
+			after = g;
+		else if (g->id > graph->id)
+			break;
+	}
+	if (after == NULL) {
+		STAILQ_INSERT_HEAD(&graph_list, graph, next);
+	} else {
+		STAILQ_INSERT_AFTER(&graph_list, after, graph, next);
+	}
+}
+
 struct graph_head *
 graph_list_head_get(void)
 {
@@ -327,7 +370,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm)
 	graph->socket = prm->socket_id;
 	graph->src_node_count = src_node_count;
 	graph->node_count = graph_nodes_count(graph);
-	graph->id = graph_id;
+	graph->id = graph_next_free_id();
 
 	/* Allocate the Graph fast path memory and populate the data */
 	if (graph_fp_mem_create(graph))
@@ -338,8 +381,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm)
 		goto graph_mem_destroy;
 
 	/* All good, Lets add the graph to the list */
-	graph_id++;
-	STAILQ_INSERT_TAIL(&graph_list, graph, next);
+	graph_insert_ordered(graph);
 
 	graph_spinlock_unlock();
 	return graph->id;
@@ -378,7 +420,6 @@ rte_graph_destroy(rte_graph_t id)
 			graph_cleanup(graph);
 			STAILQ_REMOVE(&graph_list, graph, graph, next);
 			free(graph);
-			graph_id--;
 			goto done;
 		}
 		graph = tmp;
@@ -405,7 +446,8 @@ rte_graph_id_to_name(rte_graph_t id)
 {
 	struct graph *graph;
 
-	GRAPH_ID_CHECK(id);
+	if (graph_from_id(id) == NULL)
+		goto fail;
 	STAILQ_FOREACH(graph, &graph_list, next)
 		if (graph->id == id)
 			return graph->name;
@@ -422,7 +464,8 @@ rte_graph_node_get(rte_graph_t gid, uint32_t nid)
 	rte_graph_off_t off;
 	rte_node_t count;
 
-	GRAPH_ID_CHECK(gid);
+	if (graph_from_id(gid) == NULL)
+		goto fail;
 	STAILQ_FOREACH(graph, &graph_list, next)
 		if (graph->id == gid) {
 			rte_graph_foreach_node(count, off, graph->graph,
@@ -547,7 +590,8 @@ graph_scan_dump(FILE *f, rte_graph_t id, bool all)
 	struct graph *graph;
 
 	RTE_VERIFY(f);
-	GRAPH_ID_CHECK(id);
+	if (graph_from_id(id) == NULL)
+		goto fail;
 
 	STAILQ_FOREACH(graph, &graph_list, next) {
 		if (all == true) {
@@ -576,7 +620,13 @@ rte_graph_list_dump(FILE *f)
 rte_graph_t
 rte_graph_max_count(void)
 {
-	return graph_id;
+	struct graph *graph;
+	rte_graph_t count = 0;
+
+	STAILQ_FOREACH(graph, &graph_list, next)
+		count++;
+
+	return count;
 }
 
 RTE_LOG_REGISTER_DEFAULT(rte_graph_logtype, INFO);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.877740054 +0100
+++ 0061-graph-fix-ID-collisions.patch	2024-06-25 00:22:13.213186220 +0100
@@ -1 +1 @@
-From d5c8b6bb74a06051232cbbd92d25220606b280c0 Mon Sep 17 00:00:00 2001
+From 145220677b0b20859be722c4cc6f90d882ce395d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d5c8b6bb74a06051232cbbd92d25220606b280c0 ]
+
@@ -27 +28,0 @@
-Cc: stable@dpdk.org
@@ -32,3 +33,2 @@
- app/test/test_graph.c | 72 ++++++++++++++++++++++++++++++++++++
- lib/graph/graph.c     | 86 ++++++++++++++++++++++++++++++++++---------
- 2 files changed, 141 insertions(+), 17 deletions(-)
+ lib/graph/graph.c | 72 +++++++++++++++++++++++++++++++++++++++--------
+ 1 file changed, 61 insertions(+), 11 deletions(-)
@@ -36,90 +35,0 @@
-diff --git a/app/test/test_graph.c b/app/test/test_graph.c
-index b8409bc604..2840a25b13 100644
---- a/app/test/test_graph.c
-+++ b/app/test/test_graph.c
-@@ -696,6 +696,77 @@ test_graph_clone(void)
- 	return ret;
- }
- 
-+static int
-+test_graph_id_collisions(void)
-+{
-+	static const char *node_patterns[] = {"test_node_source1", "test_node00"};
-+	struct rte_graph_param gconf = {
-+		.socket_id = SOCKET_ID_ANY,
-+		.nb_node_patterns = 2,
-+		.node_patterns = node_patterns,
-+	};
-+	rte_graph_t g1, g2, g3, g4;
-+
-+	g1 = rte_graph_create("worker1", &gconf);
-+	if (g1 == RTE_GRAPH_ID_INVALID) {
-+		printf("Graph 1 creation failed with error = %d\n", rte_errno);
-+		return -1;
-+	}
-+	g2 = rte_graph_create("worker2", &gconf);
-+	if (g2 == RTE_GRAPH_ID_INVALID) {
-+		printf("Graph 2 creation failed with error = %d\n", rte_errno);
-+		return -1;
-+	}
-+	g3 = rte_graph_create("worker3", &gconf);
-+	if (g3 == RTE_GRAPH_ID_INVALID) {
-+		printf("Graph 3 creation failed with error = %d\n", rte_errno);
-+		return -1;
-+	}
-+	if (g1 == g2 || g2 == g3 || g1 == g3) {
-+		printf("Graph ids should be different\n");
-+		return -1;
-+	}
-+	if (rte_graph_destroy(g2) < 0) {
-+		printf("Graph 2 suppression failed\n");
-+		return -1;
-+	}
-+	g4 = rte_graph_create("worker4", &gconf);
-+	if (g4 == RTE_GRAPH_ID_INVALID) {
-+		printf("Graph 4 creation failed with error = %d\n", rte_errno);
-+		return -1;
-+	}
-+	if (g1 == g3 || g1 == g4 || g3 == g4) {
-+		printf("Graph ids should be different\n");
-+		return -1;
-+	}
-+	g2 = rte_graph_clone(g1, "worker2", &gconf);
-+	if (g2 == RTE_GRAPH_ID_INVALID) {
-+		printf("Graph 4 creation failed with error = %d\n", rte_errno);
-+		return -1;
-+	}
-+	if (g1 == g2 || g1 == g3 || g1 == g4 || g2 == g3 || g2 == g4 || g3 == g4) {
-+		printf("Graph ids should be different\n");
-+		return -1;
-+	}
-+	if (rte_graph_destroy(g1) < 0) {
-+		printf("Graph 1 suppression failed\n");
-+		return -1;
-+	}
-+	if (rte_graph_destroy(g2) < 0) {
-+		printf("Graph 2 suppression failed\n");
-+		return -1;
-+	}
-+	if (rte_graph_destroy(g3) < 0) {
-+		printf("Graph 3 suppression failed\n");
-+		return -1;
-+	}
-+	if (rte_graph_destroy(g4) < 0) {
-+		printf("Graph 4 suppression failed\n");
-+		return -1;
-+	}
-+	return 0;
-+}
-+
- static int
- test_graph_model_mcore_dispatch_node_lcore_affinity_set(void)
- {
-@@ -977,6 +1048,7 @@ static struct unit_test_suite graph_testsuite = {
- 		TEST_CASE(test_lookup_functions),
- 		TEST_CASE(test_create_graph),
- 		TEST_CASE(test_graph_clone),
-+		TEST_CASE(test_graph_id_collisions),
- 		TEST_CASE(test_graph_model_mcore_dispatch_node_lcore_affinity_set),
- 		TEST_CASE(test_graph_model_mcore_dispatch_core_bind_unbind),
- 		TEST_CASE(test_graph_worker_model_set_get),
@@ -127 +37 @@
-index 26f0968a97..8ea2109645 100644
+index 3a617cc369..9027e62a26 100644
@@ -130 +40 @@
-@@ -19,11 +19,54 @@
+@@ -18,11 +18,54 @@
@@ -188,21 +98 @@
-@@ -279,7 +322,8 @@ rte_graph_model_mcore_dispatch_core_bind(rte_graph_t id, int lcore)
- {
- 	struct graph *graph;
- 
--	GRAPH_ID_CHECK(id);
-+	if (graph_from_id(id) == NULL)
-+		goto fail;
- 	if (!rte_lcore_is_enabled(lcore))
- 		SET_ERR_JMP(ENOLINK, fail, "lcore %d not enabled", lcore);
- 
-@@ -309,7 +353,8 @@ rte_graph_model_mcore_dispatch_core_unbind(rte_graph_t id)
- {
- 	struct graph *graph;
- 
--	GRAPH_ID_CHECK(id);
-+	if (graph_from_id(id) == NULL)
-+		goto fail;
- 	STAILQ_FOREACH(graph, &graph_list, next)
- 		if (graph->id == id)
- 			break;
-@@ -406,7 +451,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm)
+@@ -327,7 +370,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm)
@@ -214,4 +104,4 @@
- 	graph->parent_id = RTE_GRAPH_ID_INVALID;
- 	graph->lcore_id = RTE_MAX_LCORE;
- 	graph->num_pkt_to_capture = prm->num_pkt_to_capture;
-@@ -422,8 +467,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm)
+ 
+ 	/* Allocate the Graph fast path memory and populate the data */
+ 	if (graph_fp_mem_create(graph))
+@@ -338,8 +381,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm)
@@ -227 +117 @@
-@@ -467,7 +511,6 @@ rte_graph_destroy(rte_graph_t id)
+@@ -378,7 +420,6 @@ rte_graph_destroy(rte_graph_t id)
@@ -235,30 +125 @@
-@@ -520,7 +563,7 @@ graph_clone(struct graph *parent_graph, const char *name, struct rte_graph_param
- 	graph->parent_id = parent_graph->id;
- 	graph->lcore_id = parent_graph->lcore_id;
- 	graph->socket = parent_graph->socket;
--	graph->id = graph_id;
-+	graph->id = graph_next_free_id();
- 
- 	/* Allocate the Graph fast path memory and populate the data */
- 	if (graph_fp_mem_create(graph))
-@@ -539,8 +582,7 @@ graph_clone(struct graph *parent_graph, const char *name, struct rte_graph_param
- 		goto graph_mem_destroy;
- 
- 	/* All good, Lets add the graph to the list */
--	graph_id++;
--	STAILQ_INSERT_TAIL(&graph_list, graph, next);
-+	graph_insert_ordered(graph);
- 
- 	graph_spinlock_unlock();
- 	return graph->id;
-@@ -561,7 +603,8 @@ rte_graph_clone(rte_graph_t id, const char *name, struct rte_graph_param *prm)
- {
- 	struct graph *graph;
- 
--	GRAPH_ID_CHECK(id);
-+	if (graph_from_id(id) == NULL)
-+		goto fail;
- 	STAILQ_FOREACH(graph, &graph_list, next)
- 		if (graph->id == id)
- 			return graph_clone(graph, name, prm);
-@@ -587,7 +630,8 @@ rte_graph_id_to_name(rte_graph_t id)
+@@ -405,7 +446,8 @@ rte_graph_id_to_name(rte_graph_t id)
@@ -274 +135 @@
-@@ -604,7 +648,8 @@ rte_graph_node_get(rte_graph_t gid, uint32_t nid)
+@@ -422,7 +464,8 @@ rte_graph_node_get(rte_graph_t gid, uint32_t nid)
@@ -284 +145 @@
-@@ -729,7 +774,8 @@ graph_scan_dump(FILE *f, rte_graph_t id, bool all)
+@@ -547,7 +590,8 @@ graph_scan_dump(FILE *f, rte_graph_t id, bool all)
@@ -294 +155 @@
-@@ -758,7 +804,13 @@ rte_graph_list_dump(FILE *f)
+@@ -576,7 +620,13 @@ rte_graph_list_dump(FILE *f)

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

* patch 'bpf: disable on 32-bit x86' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (59 preceding siblings ...)
  2024-06-24 23:58 ` patch 'graph: fix ID collisions' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'hash: fix RCU reclamation size' " luca.boccassi
                   ` (18 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Luca Boccassi; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/1f65019c2d7ff5396cb18a4ceeba231c6607b881

Thanks.

Luca Boccassi

---
From 1f65019c2d7ff5396cb18a4ceeba231c6607b881 Mon Sep 17 00:00:00 2001
From: Luca Boccassi <bluca@debian.org>
Date: Thu, 25 Apr 2024 16:05:58 +0100
Subject: [PATCH] bpf: disable on 32-bit x86

[ upstream commit 4edbcc7b5313949083f7694847342b1a45659d6b ]

As per Intel, this is not supported, and the librte-bpf test fails on
32bit x86 kernels, so disable the library and the pmd.

Signed-off-by: Luca Boccassi <bluca@debian.org>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
 app/test/meson.build           | 11 ++++++++---
 drivers/net/af_xdp/meson.build |  6 ++++++
 lib/bpf/meson.build            |  6 ++++++
 3 files changed, 20 insertions(+), 3 deletions(-)

diff --git a/app/test/meson.build b/app/test/meson.build
index eee02cd8ff..09cbe5e620 100644
--- a/app/test/meson.build
+++ b/app/test/meson.build
@@ -15,7 +15,6 @@ test_sources = files(
         'test_barrier.c',
         'test_bitops.c',
         'test_bitmap.c',
-        'test_bpf.c',
         'test_byteorder.c',
         'test_cksum.c',
         'test_cksum_perf.c',
@@ -161,8 +160,6 @@ fast_tests = [
         ['acl_autotest', true, true],
         ['atomic_autotest', false, true],
         ['bitmap_autotest', true, true],
-        ['bpf_autotest', true, true],
-        ['bpf_convert_autotest', true, true],
         ['bitops_autotest', true, true],
         ['byteorder_autotest', true, true],
         ['cksum_autotest', true, true],
@@ -430,6 +427,14 @@ if dpdk_conf.has('RTE_HAS_LIBPCAP')
     endif
 endif
 
+if arch_subdir != 'x86' or dpdk_conf.get('RTE_ARCH_64')
+    test_sources += 'test_bpf.c'
+    fast_tests += [
+        ['bpf_autotest', true, true],
+        ['bpf_convert_autotest', true, true],
+    ]
+endif
+
 if cc.has_argument('-Wno-format-truncation')
     cflags += '-Wno-format-truncation'
 endif
diff --git a/drivers/net/af_xdp/meson.build b/drivers/net/af_xdp/meson.build
index 979b914bb6..1182ce5325 100644
--- a/drivers/net/af_xdp/meson.build
+++ b/drivers/net/af_xdp/meson.build
@@ -7,6 +7,12 @@ if is_windows
     subdir_done()
 endif
 
+if arch_subdir == 'x86' and dpdk_conf.get('RTE_ARCH_32')
+    build = false
+    reason = 'not supported on 32-bit x86'
+    subdir_done()
+endif
+
 sources = files('rte_eth_af_xdp.c')
 
 libxdp_ver = '>=1.2.2'
diff --git a/lib/bpf/meson.build b/lib/bpf/meson.build
index cd739bb827..aa258a9061 100644
--- a/lib/bpf/meson.build
+++ b/lib/bpf/meson.build
@@ -7,6 +7,12 @@ if is_windows
     subdir_done()
 endif
 
+if arch_subdir == 'x86' and dpdk_conf.get('RTE_ARCH_32')
+    build = false
+    reason = 'not supported on 32-bit x86'
+    subdir_done()
+endif
+
 sources = files('bpf.c',
         'bpf_dump.c',
         'bpf_exec.c',
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.912750848 +0100
+++ 0062-bpf-disable-on-32-bit-x86.patch	2024-06-25 00:22:13.217186301 +0100
@@ -1 +1 @@
-From 4edbcc7b5313949083f7694847342b1a45659d6b Mon Sep 17 00:00:00 2001
+From 1f65019c2d7ff5396cb18a4ceeba231c6607b881 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4edbcc7b5313949083f7694847342b1a45659d6b ]
+
@@ -9,2 +10,0 @@
-Cc: stable@dpdk.org
-
@@ -14,4 +14,4 @@
- doc/guides/rel_notes/release_24_07.rst | 5 +++++
- drivers/net/af_xdp/meson.build         | 6 ++++++
- lib/bpf/meson.build                    | 6 ++++++
- 3 files changed, 17 insertions(+)
+ app/test/meson.build           | 11 ++++++++---
+ drivers/net/af_xdp/meson.build |  6 ++++++
+ lib/bpf/meson.build            |  6 ++++++
+ 3 files changed, 20 insertions(+), 3 deletions(-)
@@ -19,7 +19,24 @@
-diff --git a/doc/guides/rel_notes/release_24_07.rst b/doc/guides/rel_notes/release_24_07.rst
-index d4970cf6ec..1af7cb91a1 100644
---- a/doc/guides/rel_notes/release_24_07.rst
-+++ b/doc/guides/rel_notes/release_24_07.rst
-@@ -138,6 +138,11 @@ Removed Items
-    Also, make sure to start the actual text at the margin.
-    =======================================================
+diff --git a/app/test/meson.build b/app/test/meson.build
+index eee02cd8ff..09cbe5e620 100644
+--- a/app/test/meson.build
++++ b/app/test/meson.build
+@@ -15,7 +15,6 @@ test_sources = files(
+         'test_barrier.c',
+         'test_bitops.c',
+         'test_bitmap.c',
+-        'test_bpf.c',
+         'test_byteorder.c',
+         'test_cksum.c',
+         'test_cksum_perf.c',
+@@ -161,8 +160,6 @@ fast_tests = [
+         ['acl_autotest', true, true],
+         ['atomic_autotest', false, true],
+         ['bitmap_autotest', true, true],
+-        ['bpf_autotest', true, true],
+-        ['bpf_convert_autotest', true, true],
+         ['bitops_autotest', true, true],
+         ['byteorder_autotest', true, true],
+         ['cksum_autotest', true, true],
+@@ -430,6 +427,14 @@ if dpdk_conf.has('RTE_HAS_LIBPCAP')
+     endif
+ endif
@@ -27 +44,7 @@
-+* **Disabled the BPF library and net/af_xdp for 32-bit x86.**
++if arch_subdir != 'x86' or dpdk_conf.get('RTE_ARCH_64')
++    test_sources += 'test_bpf.c'
++    fast_tests += [
++        ['bpf_autotest', true, true],
++        ['bpf_convert_autotest', true, true],
++    ]
++endif
@@ -29,6 +52,3 @@
-+  BPF is not supported and the librte-bpf test fails on 32-bit x86 kernels.
-+  So disable the library and the pmd.
-+
- 
- API Changes
- -----------
+ if cc.has_argument('-Wno-format-truncation')
+     cflags += '-Wno-format-truncation'
+ endif
@@ -36 +56 @@
-index 280bfa8f80..69d109ff46 100644
+index 979b914bb6..1182ce5325 100644

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

* patch 'hash: fix RCU reclamation size' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (60 preceding siblings ...)
  2024-06-24 23:58 ` patch 'bpf: disable on 32-bit x86' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'common/mlx5: fix unsigned/signed mismatch' " luca.boccassi
                   ` (17 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Abdullah Ömer Yamaç; +Cc: Honnappa Nagarahalli, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/0ac140899be5dba341dc0438ada302b636fe2dce

Thanks.

Luca Boccassi

---
From 0ac140899be5dba341dc0438ada302b636fe2dce Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Abdullah=20=C3=96mer=20Yama=C3=A7?= <aomeryamac@gmail.com>
Date: Mon, 13 May 2024 16:35:53 +0000
Subject: [PATCH] hash: fix RCU reclamation size
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit d45a7eed07d6b024956d10af529fcdcdd798227f ]

Set the maximum reclamation size to user provided value.

Fixes: 769b2de7fb52 ("hash: implement RCU resources reclamation")

Signed-off-by: Abdullah Ömer Yamaç <aomeryamac@gmail.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
---
 .mailmap                   | 2 +-
 lib/hash/rte_cuckoo_hash.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.mailmap b/.mailmap
index e8953af6f0..6a7e64e72d 100644
--- a/.mailmap
+++ b/.mailmap
@@ -2,7 +2,7 @@ Aakash Sasidharan <asasidharan@marvell.com>
 Aaro Koskinen <aaro.koskinen@nsn.com>
 Aaron Campbell <aaron@arbor.net>
 Aaron Conole <aconole@redhat.com>
-Abdullah Ömer Yamaç <omer.yamac@ceng.metu.edu.tr>
+Abdullah Ömer Yamaç <omer.yamac@ceng.metu.edu.tr> <aomeryamac@gmail.com>
 Abdullah Sevincer <abdullah.sevincer@intel.com>
 Abed Kamaluddin <akamaluddin@marvell.com>
 Abhijit Sinha <abhijit.sinha@intel.com>
diff --git a/lib/hash/rte_cuckoo_hash.c b/lib/hash/rte_cuckoo_hash.c
index 13c8337519..7da32f1d49 100644
--- a/lib/hash/rte_cuckoo_hash.c
+++ b/lib/hash/rte_cuckoo_hash.c
@@ -1543,6 +1543,7 @@ rte_hash_rcu_qsbr_add(struct rte_hash *h, struct rte_hash_rcu_config *cfg)
 		if (params.size == 0)
 			params.size = total_entries;
 		params.trigger_reclaim_limit = cfg->trigger_reclaim_limit;
+		params.max_reclaim_size = cfg->max_reclaim_size;
 		if (params.max_reclaim_size == 0)
 			params.max_reclaim_size = RTE_HASH_RCU_DQ_RECLAIM_MAX;
 		params.esize = sizeof(struct __rte_hash_rcu_dq_entry);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.947801784 +0100
+++ 0063-hash-fix-RCU-reclamation-size.patch	2024-06-25 00:22:13.229186546 +0100
@@ -1 +1 @@
-From d45a7eed07d6b024956d10af529fcdcdd798227f Mon Sep 17 00:00:00 2001
+From 0ac140899be5dba341dc0438ada302b636fe2dce Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit d45a7eed07d6b024956d10af529fcdcdd798227f ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 3e73eec762..9013e15ea9 100644
+index e8953af6f0..6a7e64e72d 100644
@@ -33 +34 @@
- Abhijit Gangurde <abhijit.gangurde@amd.com>
+ Abhijit Sinha <abhijit.sinha@intel.com>
@@ -35 +36 @@
-index 16c9c4c5c4..265335f845 100644
+index 13c8337519..7da32f1d49 100644
@@ -38 +39 @@
-@@ -1558,6 +1558,7 @@ rte_hash_rcu_qsbr_add(struct rte_hash *h, struct rte_hash_rcu_config *cfg)
+@@ -1543,6 +1543,7 @@ rte_hash_rcu_qsbr_add(struct rte_hash *h, struct rte_hash_rcu_config *cfg)

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

* patch 'common/mlx5: fix unsigned/signed mismatch' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (61 preceding siblings ...)
  2024-06-24 23:58 ` patch 'hash: fix RCU reclamation size' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5/hws: decrease log level for creation failure' " luca.boccassi
                   ` (16 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Tyler Retzlaff; +Cc: Dariusz Sosnowski, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/17c527107800562b7a8f2bbbb5f78de78b7d2d65

Thanks.

Luca Boccassi

---
From 17c527107800562b7a8f2bbbb5f78de78b7d2d65 Mon Sep 17 00:00:00 2001
From: Tyler Retzlaff <roretzla@linux.microsoft.com>
Date: Mon, 15 Apr 2024 16:09:37 -0700
Subject: [PATCH] common/mlx5: fix unsigned/signed mismatch

[ upstream commit eec253d0a57d707306e4ac3128bc21f10bb8bc5f ]

Use unsigned int for 2 loop indexes that are being compared against an
unsigned int struct field to avoid signed/unsigned mismatch warning.

Fixes: 718d166e5504 ("net/mlx5: create advanced RxQ table via DevX")
Fixes: e1da60a8a6e9 ("common/mlx5: add DevX command to modify RQT")

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
 drivers/common/mlx5/mlx5_devx_cmds.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/common/mlx5/mlx5_devx_cmds.c b/drivers/common/mlx5/mlx5_devx_cmds.c
index c570323fa8..f44be4c230 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.c
+++ b/drivers/common/mlx5/mlx5_devx_cmds.c
@@ -1661,7 +1661,7 @@ mlx5_devx_cmd_create_rqt(void *ctx,
 	uint32_t out[MLX5_ST_SZ_DW(create_rqt_out)] = {0};
 	void *rqt_ctx;
 	struct mlx5_devx_obj *rqt = NULL;
-	int i;
+	unsigned int i;
 
 	in = mlx5_malloc(MLX5_MEM_ZERO, inlen, 0, SOCKET_ID_ANY);
 	if (!in) {
@@ -1714,7 +1714,7 @@ mlx5_devx_cmd_modify_rqt(struct mlx5_devx_obj *rqt,
 	uint32_t out[MLX5_ST_SZ_DW(modify_rqt_out)] = {0};
 	uint32_t *in = mlx5_malloc(MLX5_MEM_ZERO, inlen, 0, SOCKET_ID_ANY);
 	void *rqt_ctx;
-	int i;
+	unsigned int i;
 	int ret;
 
 	if (!in) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:16.984553137 +0100
+++ 0064-common-mlx5-fix-unsigned-signed-mismatch.patch	2024-06-25 00:22:13.229186546 +0100
@@ -1 +1 @@
-From eec253d0a57d707306e4ac3128bc21f10bb8bc5f Mon Sep 17 00:00:00 2001
+From 17c527107800562b7a8f2bbbb5f78de78b7d2d65 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit eec253d0a57d707306e4ac3128bc21f10bb8bc5f ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 9b7ababae7..9952733c90 100644
+index c570323fa8..f44be4c230 100644
@@ -23 +24 @@
-@@ -1816,7 +1816,7 @@ mlx5_devx_cmd_create_rqt(void *ctx,
+@@ -1661,7 +1661,7 @@ mlx5_devx_cmd_create_rqt(void *ctx,
@@ -32 +33 @@
-@@ -1869,7 +1869,7 @@ mlx5_devx_cmd_modify_rqt(struct mlx5_devx_obj *rqt,
+@@ -1714,7 +1714,7 @@ mlx5_devx_cmd_modify_rqt(struct mlx5_devx_obj *rqt,

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

* patch 'net/mlx5/hws: decrease log level for creation failure' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (62 preceding siblings ...)
  2024-06-24 23:58 ` patch 'common/mlx5: fix unsigned/signed mismatch' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'common/mlx5: fix PRM structs' " luca.boccassi
                   ` (15 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Erez Shitrit; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/a05258399acb2c3262b612ab6e8e94f4363d93ca

Thanks.

Luca Boccassi

---
From a05258399acb2c3262b612ab6e8e94f4363d93ca Mon Sep 17 00:00:00 2001
From: Erez Shitrit <erezsh@nvidia.com>
Date: Mon, 6 May 2024 14:44:04 +0300
Subject: [PATCH] net/mlx5/hws: decrease log level for creation failure

[ upstream commit e014d5e2e49994fbc504a49814ed480a60c85d63 ]

When the user tries to create a matcher and if failed  with specific
errno (E2BIG) the message will be in debug level and not in warning.
It is a part of a feature when the user re-try to insert a new matching
depends on that errno, no need the annoying message.

Fixes: c55c2bf35333 ("net/mlx5/hws: add definer layer")

Signed-off-by: Erez Shitrit <erezsh@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/hws/mlx5dr_definer.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/mlx5/hws/mlx5dr_definer.c b/drivers/net/mlx5/hws/mlx5dr_definer.c
index d81d66523a..bc1decbec9 100644
--- a/drivers/net/mlx5/hws/mlx5dr_definer.c
+++ b/drivers/net/mlx5/hws/mlx5dr_definer.c
@@ -1842,7 +1842,7 @@ mlx5dr_definer_find_best_hl_fit(struct mlx5dr_context *ctx,
 		return 0;
 	}
 
-	DR_LOG(ERR, "Unable to find supporting match/jumbo definer combination");
+	DR_LOG(DEBUG, "Unable to find supporting match/jumbo definer combination");
 	rte_errno = ENOTSUP;
 	return rte_errno;
 }
@@ -1934,7 +1934,7 @@ int mlx5dr_definer_get(struct mlx5dr_context *ctx,
 	/* Convert items to hl and allocate the field copy array (fc) */
 	ret = mlx5dr_definer_conv_items_to_hl(ctx, mt, hl);
 	if (ret) {
-		DR_LOG(ERR, "Failed to convert items to hl");
+		DR_LOG(DEBUG, "Failed to convert items to hl");
 		goto free_hl;
 	}
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.020521867 +0100
+++ 0065-net-mlx5-hws-decrease-log-level-for-creation-failure.patch	2024-06-25 00:22:13.233186627 +0100
@@ -1 +1 @@
-From e014d5e2e49994fbc504a49814ed480a60c85d63 Mon Sep 17 00:00:00 2001
+From a05258399acb2c3262b612ab6e8e94f4363d93ca Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e014d5e2e49994fbc504a49814ed480a60c85d63 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -17,3 +18,2 @@
- drivers/net/mlx5/hws/mlx5dr_definer.c | 6 +++---
- drivers/net/mlx5/hws/mlx5dr_matcher.c | 2 +-
- 2 files changed, 4 insertions(+), 4 deletions(-)
+ drivers/net/mlx5/hws/mlx5dr_definer.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
@@ -22 +22 @@
-index a0f95c6923..88be27dcbb 100644
+index d81d66523a..bc1decbec9 100644
@@ -25 +25 @@
-@@ -3539,7 +3539,7 @@ mlx5dr_definer_find_best_match_fit(struct mlx5dr_context *ctx,
+@@ -1842,7 +1842,7 @@ mlx5dr_definer_find_best_hl_fit(struct mlx5dr_context *ctx,
@@ -31 +31 @@
- 	rte_errno = E2BIG;
+ 	rte_errno = ENOTSUP;
@@ -34,25 +34,3 @@
-@@ -3694,7 +3694,7 @@ mlx5dr_definer_calc_layout(struct mlx5dr_matcher *matcher,
- 	/* Find the match definer layout for header layout match union */
- 	ret = mlx5dr_definer_find_best_match_fit(ctx, match_definer, match_hl);
- 	if (ret) {
--		DR_LOG(ERR, "Failed to create match definer from header layout");
-+		DR_LOG(DEBUG, "Failed to create match definer from header layout");
- 		goto free_fc;
- 	}
- 
-@@ -4046,7 +4046,7 @@ int mlx5dr_definer_matcher_init(struct mlx5dr_context *ctx,
- 
- 	ret = mlx5dr_definer_calc_layout(matcher, &match_layout, &range_layout);
- 	if (ret) {
--		DR_LOG(ERR, "Failed to calculate matcher definer layout");
-+		DR_LOG(DEBUG, "Failed to calculate matcher definer layout");
- 		return ret;
- 	}
- 
-diff --git a/drivers/net/mlx5/hws/mlx5dr_matcher.c b/drivers/net/mlx5/hws/mlx5dr_matcher.c
-index aeff300467..c9f5e46d24 100644
---- a/drivers/net/mlx5/hws/mlx5dr_matcher.c
-+++ b/drivers/net/mlx5/hws/mlx5dr_matcher.c
-@@ -877,7 +877,7 @@ static int mlx5dr_matcher_bind_mt(struct mlx5dr_matcher *matcher)
- 	/* Calculate match, range and hash definers */
- 	ret = mlx5dr_definer_matcher_init(ctx, matcher);
+@@ -1934,7 +1934,7 @@ int mlx5dr_definer_get(struct mlx5dr_context *ctx,
+ 	/* Convert items to hl and allocate the field copy array (fc) */
+ 	ret = mlx5dr_definer_conv_items_to_hl(ctx, mt, hl);
@@ -60,3 +38,3 @@
--		DR_LOG(ERR, "Failed to set matcher templates with match definers");
-+		DR_LOG(DEBUG, "Failed to set matcher templates with match definers");
- 		return ret;
+-		DR_LOG(ERR, "Failed to convert items to hl");
++		DR_LOG(DEBUG, "Failed to convert items to hl");
+ 		goto free_hl;

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

* patch 'common/mlx5: fix PRM structs' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (63 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5/hws: decrease log level for creation failure' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5/hws: fix function comment' " luca.boccassi
                   ` (14 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Yevgeny Kliteynik; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/06de40842ef37ce6b557e3186d493b219be492e4

Thanks.

Luca Boccassi

---
From 06de40842ef37ce6b557e3186d493b219be492e4 Mon Sep 17 00:00:00 2001
From: Yevgeny Kliteynik <kliteyn@nvidia.com>
Date: Mon, 6 May 2024 14:44:05 +0300
Subject: [PATCH] common/mlx5: fix PRM structs

[ upstream commit 39b1cce562a4e1fa3137fd91a3b1dfed98f23db4 ]

Fix wrong reserved size and add helpful comment

Fixes: 365cdf5f8ce7 ("net/mlx5/hws: add command layer")

Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/common/mlx5/mlx5_prm.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/common/mlx5/mlx5_prm.h b/drivers/common/mlx5/mlx5_prm.h
index dab70b9469..f2cd353672 100644
--- a/drivers/common/mlx5/mlx5_prm.h
+++ b/drivers/common/mlx5/mlx5_prm.h
@@ -2116,8 +2116,8 @@ struct mlx5_ifc_cmd_hca_cap_2_bits {
 	u8 reserved_at_d0[0x3];
 	u8 log_conn_track_max_alloc[0x5];
 	u8 reserved_at_d8[0x3];
-	u8 log_max_conn_track_offload[0x5];
-	u8 reserved_at_e0[0x20]; /* End of DW7. */
+	u8 log_max_conn_track_offload[0x5]; /* End of DW7. */
+	u8 reserved_at_e0[0x20];
 	u8 reserved_at_100[0x60];
 	u8 reserved_at_160[0x3];
 	u8 hairpin_sq_wqe_bb_size[0x5];
@@ -3311,7 +3311,7 @@ struct mlx5_ifc_stc_ste_param_vport_bits {
 	u8 eswitch_owner_vhca_id[0x10];
 	u8 vport_number[0x10];
 	u8 eswitch_owner_vhca_id_valid[0x1];
-	u8 reserved_at_21[0x59];
+	u8 reserved_at_21[0x5f];
 };
 
 union mlx5_ifc_stc_param_bits {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.058542614 +0100
+++ 0066-common-mlx5-fix-PRM-structs.patch	2024-06-25 00:22:13.237186709 +0100
@@ -1 +1 @@
-From 39b1cce562a4e1fa3137fd91a3b1dfed98f23db4 Mon Sep 17 00:00:00 2001
+From 06de40842ef37ce6b557e3186d493b219be492e4 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 39b1cce562a4e1fa3137fd91a3b1dfed98f23db4 ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
-index 2bbbc446fc..178a18a978 100644
+index dab70b9469..f2cd353672 100644
@@ -21 +22 @@
-@@ -2360,8 +2360,8 @@ struct mlx5_ifc_cmd_hca_cap_2_bits {
+@@ -2116,8 +2116,8 @@ struct mlx5_ifc_cmd_hca_cap_2_bits {
@@ -26 +27 @@
--	u8 cross_vhca_object_to_object_supported[0x20]; /* End of DW7. */
+-	u8 reserved_at_e0[0x20]; /* End of DW7. */
@@ -28,5 +29,5 @@
-+	u8 cross_vhca_object_to_object_supported[0x20];
- 	u8 allowed_object_for_other_vhca_access_high[0x20];
- 	u8 allowed_object_for_other_vhca_access[0x20];
- 	u8 reserved_at_140[0x20];
-@@ -3655,7 +3655,7 @@ struct mlx5_ifc_stc_ste_param_vport_bits {
++	u8 reserved_at_e0[0x20];
+ 	u8 reserved_at_100[0x60];
+ 	u8 reserved_at_160[0x3];
+ 	u8 hairpin_sq_wqe_bb_size[0x5];
+@@ -3311,7 +3311,7 @@ struct mlx5_ifc_stc_ste_param_vport_bits {

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

* patch 'net/mlx5/hws: fix function comment' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (64 preceding siblings ...)
  2024-06-24 23:58 ` patch 'common/mlx5: fix PRM structs' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5/hws: fix spinlock release on context open' " luca.boccassi
                   ` (13 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Yevgeny Kliteynik; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/ef9f7c1fd8bf43a5582e3aaca173da5c1c4bae56

Thanks.

Luca Boccassi

---
From ef9f7c1fd8bf43a5582e3aaca173da5c1c4bae56 Mon Sep 17 00:00:00 2001
From: Yevgeny Kliteynik <kliteyn@nvidia.com>
Date: Mon, 6 May 2024 14:44:06 +0300
Subject: [PATCH] net/mlx5/hws: fix function comment

[ upstream commit 735a47fb4ad305a7cc4a191d69afcc6d12763a5c ]

Remove comment that documents parameter that doesn't exist.

Fixes: 3eb748869d2d ("net/mlx5/hws: add send layer")

Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/hws/mlx5dr_send.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/mlx5/hws/mlx5dr_send.h b/drivers/net/mlx5/hws/mlx5dr_send.h
index 8d4769495d..28efd70c64 100644
--- a/drivers/net/mlx5/hws/mlx5dr_send.h
+++ b/drivers/net/mlx5/hws/mlx5dr_send.h
@@ -192,8 +192,6 @@ struct mlx5dr_send_ste_attr {
  *   value to write in CPU endian format.
  * @param addr
  *   Address to write to.
- * @param lock
- *   Address of the lock to use for that UAR access.
  */
 static __rte_always_inline void
 mlx5dr_uar_write64_relaxed(uint64_t val, void *addr)
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.096417144 +0100
+++ 0067-net-mlx5-hws-fix-function-comment.patch	2024-06-25 00:22:13.237186709 +0100
@@ -1 +1 @@
-From 735a47fb4ad305a7cc4a191d69afcc6d12763a5c Mon Sep 17 00:00:00 2001
+From ef9f7c1fd8bf43a5582e3aaca173da5c1c4bae56 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 735a47fb4ad305a7cc4a191d69afcc6d12763a5c ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
-index 0c67a9e12d..c4f5a96f9c 100644
+index 8d4769495d..28efd70c64 100644
@@ -21 +22 @@
-@@ -203,8 +203,6 @@ struct mlx5dr_send_ste_attr {
+@@ -192,8 +192,6 @@ struct mlx5dr_send_ste_attr {

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

* patch 'net/mlx5/hws: fix spinlock release on context open' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (65 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5/hws: fix function comment' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5/hws: add template match none flag' " luca.boccassi
                   ` (12 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Yevgeny Kliteynik; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/df1753ebe821021b54a0c3bddb33d6e20b72cdef

Thanks.

Luca Boccassi

---
From df1753ebe821021b54a0c3bddb33d6e20b72cdef Mon Sep 17 00:00:00 2001
From: Yevgeny Kliteynik <kliteyn@nvidia.com>
Date: Mon, 6 May 2024 14:44:10 +0300
Subject: [PATCH] net/mlx5/hws: fix spinlock release on context open

[ upstream commit 36ae32b64e607c788961ab48adf24ad1cdf38140 ]

Add missing spinlock destruction in error flow.

Fixes: b0290e56dd08 ("net/mlx5/hws: add context object")

Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/hws/mlx5dr_context.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/mlx5/hws/mlx5dr_context.c b/drivers/net/mlx5/hws/mlx5dr_context.c
index 76ada7bb7f..d1923a8e93 100644
--- a/drivers/net/mlx5/hws/mlx5dr_context.c
+++ b/drivers/net/mlx5/hws/mlx5dr_context.c
@@ -210,6 +210,7 @@ struct mlx5dr_context *mlx5dr_context_open(struct ibv_context *ibv_ctx,
 free_caps:
 	simple_free(ctx->caps);
 free_ctx:
+	pthread_spin_destroy(&ctx->ctrl_lock);
 	simple_free(ctx);
 	return NULL;
 }
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.130184759 +0100
+++ 0068-net-mlx5-hws-fix-spinlock-release-on-context-open.patch	2024-06-25 00:22:13.237186709 +0100
@@ -1 +1 @@
-From 36ae32b64e607c788961ab48adf24ad1cdf38140 Mon Sep 17 00:00:00 2001
+From df1753ebe821021b54a0c3bddb33d6e20b72cdef Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 36ae32b64e607c788961ab48adf24ad1cdf38140 ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
-index 15d53c578a..7f120b3b1b 100644
+index 76ada7bb7f..d1923a8e93 100644
@@ -21 +22 @@
-@@ -263,6 +263,7 @@ struct mlx5dr_context *mlx5dr_context_open(struct ibv_context *ibv_ctx,
+@@ -210,6 +210,7 @@ struct mlx5dr_context *mlx5dr_context_open(struct ibv_context *ibv_ctx,

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

* patch 'net/mlx5/hws: add template match none flag' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (66 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5/hws: fix spinlock release on context open' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5/hws: fix action template dump' " luca.boccassi
                   ` (11 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Yevgeny Kliteynik; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/4a75ad8a7ea487f596c9d943e2c8b38290ab80fd

Thanks.

Luca Boccassi

---
From 4a75ad8a7ea487f596c9d943e2c8b38290ab80fd Mon Sep 17 00:00:00 2001
From: Yevgeny Kliteynik <kliteyn@nvidia.com>
Date: Mon, 6 May 2024 14:44:11 +0300
Subject: [PATCH] net/mlx5/hws: add template match none flag

[ upstream commit 2471994eedab4090cb73173d9986834b15e98aad ]

Instead of passing 0 as an enum parameter, define flag NONE.
This resolves the following code analysis error: "enumerated
type mixed with another type".
This value is currently used in tests only, and will later
be used in backward-compatible steering API.

Fixes: 5cadd74fbc08 ("net/mlx5: add HW steering low-level abstract stub")

Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/hws/mlx5dr.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/mlx5/hws/mlx5dr.h b/drivers/net/mlx5/hws/mlx5dr.h
index f8de27c615..d570810e95 100644
--- a/drivers/net/mlx5/hws/mlx5dr.h
+++ b/drivers/net/mlx5/hws/mlx5dr.h
@@ -81,6 +81,7 @@ enum mlx5dr_action_aso_ct_flags {
 };
 
 enum mlx5dr_match_template_flags {
+	MLX5DR_MATCH_TEMPLATE_FLAG_NONE = 0,
 	/* Allow relaxed matching by skipping derived dependent match fields. */
 	MLX5DR_MATCH_TEMPLATE_FLAG_RELAXED_MATCH = 1,
 };
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.167257313 +0100
+++ 0069-net-mlx5-hws-add-template-match-none-flag.patch	2024-06-25 00:22:13.237186709 +0100
@@ -1 +1 @@
-From 2471994eedab4090cb73173d9986834b15e98aad Mon Sep 17 00:00:00 2001
+From 4a75ad8a7ea487f596c9d943e2c8b38290ab80fd Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 2471994eedab4090cb73173d9986834b15e98aad ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 36ecccf9ac..86cd4f1db5 100644
+index f8de27c615..d570810e95 100644

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

* patch 'net/mlx5/hws: fix action template dump' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (67 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5/hws: add template match none flag' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5: fix indexed pool with invalid index' " luca.boccassi
                   ` (10 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Hamdan Igbaria; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/06af59ff2f1c0a192134a097b64fce2f7c231b68

Thanks.

Luca Boccassi

---
From 06af59ff2f1c0a192134a097b64fce2f7c231b68 Mon Sep 17 00:00:00 2001
From: Hamdan Igbaria <hamdani@nvidia.com>
Date: Mon, 6 May 2024 14:44:19 +0300
Subject: [PATCH] net/mlx5/hws: fix action template dump

[ upstream commit 98638051a93963bde144b85e7621ca30252de384 ]

The debug print of only_term param in the action template
was printed incorrectly.

Fixes: 78580cf4e796 ("net/mlx5/hws: add debug layer")

Signed-off-by: Hamdan Igbaria <hamdani@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/hws/mlx5dr_debug.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/hws/mlx5dr_debug.c b/drivers/net/mlx5/hws/mlx5dr_debug.c
index 890a761c48..092a87921d 100644
--- a/drivers/net/mlx5/hws/mlx5dr_debug.c
+++ b/drivers/net/mlx5/hws/mlx5dr_debug.c
@@ -129,7 +129,7 @@ mlx5dr_debug_dump_matcher_action_template(FILE *f, struct mlx5dr_matcher *matche
 			      MLX5DR_DEBUG_RES_TYPE_MATCHER_ACTION_TEMPLATE,
 			      (uint64_t)(uintptr_t)at,
 			      (uint64_t)(uintptr_t)matcher,
-			      at->only_term ? 0 : 1,
+			      at->only_term,
 			      is_root ? 0 : at->num_of_action_stes,
 			      at->num_actions);
 		if (ret < 0) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.200184494 +0100
+++ 0070-net-mlx5-hws-fix-action-template-dump.patch	2024-06-25 00:22:13.241186790 +0100
@@ -1 +1 @@
-From 98638051a93963bde144b85e7621ca30252de384 Mon Sep 17 00:00:00 2001
+From 06af59ff2f1c0a192134a097b64fce2f7c231b68 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 98638051a93963bde144b85e7621ca30252de384 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 5ad4ca2da5..741a725842 100644
+index 890a761c48..092a87921d 100644
@@ -22 +23 @@
-@@ -153,7 +153,7 @@ mlx5dr_debug_dump_matcher_action_template(FILE *f, struct mlx5dr_matcher *matche
+@@ -129,7 +129,7 @@ mlx5dr_debug_dump_matcher_action_template(FILE *f, struct mlx5dr_matcher *matche

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

* patch 'net/mlx5: fix indexed pool with invalid index' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (68 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5/hws: fix action template dump' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5: fix hash Rx queue release in flow sample' " luca.boccassi
                   ` (9 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Haifei Luo; +Cc: Suanming Mou, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/a752b66a9a502642c47cb4d0f99efbbdc63e62a5

Thanks.

Luca Boccassi

---
From a752b66a9a502642c47cb4d0f99efbbdc63e62a5 Mon Sep 17 00:00:00 2001
From: Haifei Luo <haifeil@nvidia.com>
Date: Wed, 15 May 2024 12:36:53 +0300
Subject: [PATCH] net/mlx5: fix indexed pool with invalid index

[ upstream commit 16a7b5d14e3dfb4d3d385375b94bb2f360883cd6 ]

When _mlx5_ipool_get_cache is called, idx may be invalid and
the "trunk" is NULL in this case. Assert is not correct and add
checks that if trunk is NULL or not. Return NULL If trunk is NULL.

Fixes: 42f463395f8f ("net/mlx5: support indexed pool non-lcore operations")

Signed-off-by: Haifei Luo <haifeil@nvidia.com>
Acked-by: Suanming Mou <suanmingm@nvidia.com>
---
 drivers/net/mlx5/mlx5_utils.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_utils.c b/drivers/net/mlx5/mlx5_utils.c
index b295702fd4..bbe07cd7a3 100644
--- a/drivers/net/mlx5/mlx5_utils.c
+++ b/drivers/net/mlx5/mlx5_utils.c
@@ -379,7 +379,8 @@ _mlx5_ipool_get_cache(struct mlx5_indexed_pool *pool, int cidx, uint32_t idx)
 	idx -= 1;
 	trunk_idx = mlx5_trunk_idx_get(pool, idx);
 	trunk = lc->trunks[trunk_idx];
-	MLX5_ASSERT(trunk);
+	if (!trunk)
+		return NULL;
 	entry_idx = idx - mlx5_trunk_idx_offset_get(pool, trunk_idx);
 	return &trunk->data[entry_idx * pool->cfg.size];
 }
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.232911179 +0100
+++ 0071-net-mlx5-fix-indexed-pool-with-invalid-index.patch	2024-06-25 00:22:13.241186790 +0100
@@ -1 +1 @@
-From 16a7b5d14e3dfb4d3d385375b94bb2f360883cd6 Mon Sep 17 00:00:00 2001
+From a752b66a9a502642c47cb4d0f99efbbdc63e62a5 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 16a7b5d14e3dfb4d3d385375b94bb2f360883cd6 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index fc03cc054b..d52119f0be 100644
+index b295702fd4..bbe07cd7a3 100644

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

* patch 'net/mlx5: fix hash Rx queue release in flow sample' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (69 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5: fix indexed pool with invalid index' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:58 ` patch 'net/mlx5: fix flow template indirect action failure' " luca.boccassi
                   ` (8 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Jiawei Wang; +Cc: Bing Zhao, Dariusz Sosnowski, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/c8ee47f1a628a73945e85d5b7eaaf290dfeebf3e

Thanks.

Luca Boccassi

---
From c8ee47f1a628a73945e85d5b7eaaf290dfeebf3e Mon Sep 17 00:00:00 2001
From: Jiawei Wang <jiaweiw@nvidia.com>
Date: Mon, 20 May 2024 18:07:09 +0300
Subject: [PATCH] net/mlx5: fix hash Rx queue release in flow sample

[ upstream commit cf3f6ba146abe613c811a281ceadf7b22ef82ab6 ]

While the queue/RSS action was added to sample action lists,
the Rx hash queue resource was allocated in the sample action
translation to create the sample DR action later.

While there's a failure in the flow creation, the Rx hash queue
resource of the sample action list was destroyed in the wrong place.

This patch adds the checking to release the Rx hash queue
resource after the sample action release, to avoid one more
extra release if there's a failure.

Fixes: ca5eb60ecd5b ("net/mlx5: fix resource release for mirror flow")

Signed-off-by: Jiawei Wang <jiaweiw@nvidia.com>
Reviewed-by: Bing Zhao <bingz@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_dv.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index 1069b84157..f8431386e0 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -14882,7 +14882,8 @@ error:
 	SILIST_FOREACH(priv->sh->ipool[MLX5_IPOOL_MLX5_FLOW], flow->dev_handles,
 		       handle_idx, dh, next) {
 		/* hrxq is union, don't clear it if the flag is not set. */
-		if (dh->fate_action == MLX5_FLOW_FATE_QUEUE && dh->rix_hrxq) {
+		if (dh->fate_action == MLX5_FLOW_FATE_QUEUE && dh->rix_hrxq &&
+		    !dh->dvh.rix_sample && !dh->dvh.rix_dest_array) {
 			mlx5_hrxq_release(dev, dh->rix_hrxq);
 			dh->rix_hrxq = 0;
 		} else if (dh->fate_action == MLX5_FLOW_FATE_SHARED_RSS) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.266755069 +0100
+++ 0072-net-mlx5-fix-hash-Rx-queue-release-in-flow-sample.patch	2024-06-25 00:22:13.257187117 +0100
@@ -1 +1 @@
-From cf3f6ba146abe613c811a281ceadf7b22ef82ab6 Mon Sep 17 00:00:00 2001
+From c8ee47f1a628a73945e85d5b7eaaf290dfeebf3e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit cf3f6ba146abe613c811a281ceadf7b22ef82ab6 ]
+
@@ -18 +19,0 @@
-Cc: stable@dpdk.org
@@ -28 +29 @@
-index 04cb9291a8..7330e13787 100644
+index 1069b84157..f8431386e0 100644
@@ -31 +32 @@
-@@ -15668,7 +15668,8 @@ error:
+@@ -14882,7 +14882,8 @@ error:

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

* patch 'net/mlx5: fix flow template indirect action failure' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (70 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5: fix hash Rx queue release in flow sample' " luca.boccassi
@ 2024-06-24 23:58 ` luca.boccassi
  2024-06-24 23:59 ` patch 'net/mlx5: break flow resource release loop' " luca.boccassi
                   ` (7 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:58 UTC (permalink / raw)
  To: Maayan Kashani; +Cc: Suanming Mou, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/42e1eb6a45859dbc9b51f80ef7344747dfbaef78

Thanks.

Luca Boccassi

---
From 42e1eb6a45859dbc9b51f80ef7344747dfbaef78 Mon Sep 17 00:00:00 2001
From: Maayan Kashani <mkashani@nvidia.com>
Date: Sun, 26 May 2024 16:22:44 +0300
Subject: [PATCH] net/mlx5: fix flow template indirect action failure

[ upstream commit b79ac509105a2cf9fce1734a6798632a0414cd1c ]

For indirect action type, on  error case the function jumped to err
but returned zero cause rte_errno was not initialized before the jump.
It caused no error in table creation.

In case reaching an error, if rte_errno is not initialized,
it will be set to EINVAL.
Now table creation should fail if the translate of the action fails.
Added driver log warnings so it can be easy to track failure on shared
actions translate.

Fixes: 7ab3962d2d2b ("net/mlx5: add indirect HW steering action")

Signed-off-by: Maayan Kashani <mkashani@nvidia.com>
Acked-by: Suanming Mou <suanmingm@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_hw.c | 19 +++++++++++++++----
 1 file changed, 15 insertions(+), 4 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index fd3e51bf0d..5333495a59 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -769,15 +769,19 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
 		if (!shared_rss || __flow_hw_act_data_shared_rss_append
 		    (priv, acts,
 		    (enum rte_flow_action_type)MLX5_RTE_FLOW_ACTION_TYPE_RSS,
-		    action_src, action_dst, idx, shared_rss))
+		    action_src, action_dst, idx, shared_rss)) {
+			DRV_LOG(WARNING, "Indirect RSS action index %d translate failed", act_idx);
 			return -1;
+		}
 		break;
 	case MLX5_INDIRECT_ACTION_TYPE_COUNT:
 		if (__flow_hw_act_data_shared_cnt_append(priv, acts,
 			(enum rte_flow_action_type)
 			MLX5_RTE_FLOW_ACTION_TYPE_COUNT,
-			action_src, action_dst, act_idx))
+			action_src, action_dst, act_idx)) {
+			DRV_LOG(WARNING, "Indirect count action translate failed");
 			return -1;
+		}
 		break;
 	case MLX5_INDIRECT_ACTION_TYPE_AGE:
 		/* Not supported, prevent by validate function. */
@@ -785,15 +789,19 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
 		break;
 	case MLX5_INDIRECT_ACTION_TYPE_CT:
 		if (flow_hw_ct_compile(dev, MLX5_HW_INV_QUEUE,
-				       idx, &acts->rule_acts[action_dst]))
+				       idx, &acts->rule_acts[action_dst])) {
+			DRV_LOG(WARNING, "Indirect CT action translate failed");
 			return -1;
+		}
 		break;
 	case MLX5_INDIRECT_ACTION_TYPE_METER_MARK:
 		if (__flow_hw_act_data_shared_mtr_append(priv, acts,
 			(enum rte_flow_action_type)
 			MLX5_RTE_FLOW_ACTION_TYPE_METER_MARK,
-			action_src, action_dst, idx))
+			action_src, action_dst, idx)) {
+			DRV_LOG(WARNING, "Indirect meter mark action translate failed");
 			return -1;
+		}
 		break;
 	default:
 		DRV_LOG(WARNING, "Unsupported shared action type:%d", type);
@@ -1758,6 +1766,9 @@ __flow_hw_actions_translate(struct rte_eth_dev *dev,
 	}
 	return 0;
 err:
+	/* If rte_errno was not initialized and reached error state. */
+	if (!rte_errno)
+		rte_errno = EINVAL;
 	err = rte_errno;
 	__flow_hw_action_template_destroy(dev, acts);
 	return rte_flow_error_set(error, err,
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.314201284 +0100
+++ 0073-net-mlx5-fix-flow-template-indirect-action-failure.patch	2024-06-25 00:22:13.265187280 +0100
@@ -1 +1 @@
-From b79ac509105a2cf9fce1734a6798632a0414cd1c Mon Sep 17 00:00:00 2001
+From 42e1eb6a45859dbc9b51f80ef7344747dfbaef78 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b79ac509105a2cf9fce1734a6798632a0414cd1c ]
+
@@ -17 +18,0 @@
-Cc: stable@dpdk.org
@@ -26 +27 @@
-index d9140dbf23..463f7b87a3 100644
+index fd3e51bf0d..5333495a59 100644
@@ -29 +30 @@
-@@ -1106,15 +1106,19 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -769,15 +769,19 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -51 +52 @@
-@@ -1122,15 +1126,19 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
+@@ -785,15 +789,19 @@ flow_hw_shared_action_translate(struct rte_eth_dev *dev,
@@ -71,3 +72,3 @@
- 	case MLX5_INDIRECT_ACTION_TYPE_QUOTA:
- 		flow_hw_construct_quota(priv, &acts->rule_acts[action_dst], idx);
-@@ -2645,6 +2653,9 @@ __flow_hw_actions_translate(struct rte_eth_dev *dev,
+ 	default:
+ 		DRV_LOG(WARNING, "Unsupported shared action type:%d", type);
+@@ -1758,6 +1766,9 @@ __flow_hw_actions_translate(struct rte_eth_dev *dev,

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

* patch 'net/mlx5: break flow resource release loop' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (71 preceding siblings ...)
  2024-06-24 23:58 ` patch 'net/mlx5: fix flow template indirect action failure' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'net/mlx5: fix access to flow template operations' " luca.boccassi
                   ` (6 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: Alexander Kozyrev; +Cc: Dariusz Sosnowski, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/68b68c76e1f2f9112d5016c732a00e97a0e5460f

Thanks.

Luca Boccassi

---
From 68b68c76e1f2f9112d5016c732a00e97a0e5460f Mon Sep 17 00:00:00 2001
From: Alexander Kozyrev <akozyrev@nvidia.com>
Date: Thu, 30 May 2024 00:46:32 +0300
Subject: [PATCH] net/mlx5: break flow resource release loop

[ upstream commit 4fcb7a05e38172aed60f87a6287bb2ee3d9828fd ]

There is a loop inside the flow_hw_resource_release() function
that tries to free all the template patterns and tables until they
are successfully released. But some of the tables may be still in use
in case of the ungraceful application termination. Which causes the
forever loop in the app on the exit. Don't wait for the tables release
and try them to free only once and proceed with the exit.

Fixes: d1559d66ed2d ("net/mlx5: add table management")

Signed-off-by: Alexander Kozyrev <akozyrev@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_hw.c | 44 +++++++++++++++++++--------------
 1 file changed, 26 insertions(+), 18 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index 5333495a59..c902b35f0b 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -3407,7 +3407,7 @@ flow_hw_table_destroy(struct rte_eth_dev *dev,
 		return rte_flow_error_set(error, EBUSY,
 				   RTE_FLOW_ERROR_TYPE_UNSPECIFIED,
 				   NULL,
-				   "table in using");
+				   "table is in use");
 	}
 	LIST_REMOVE(table, next);
 	for (i = 0; i < table->nb_item_templates; i++)
@@ -4660,7 +4660,7 @@ flow_hw_actions_template_destroy(struct rte_eth_dev *dev __rte_unused,
 		return rte_flow_error_set(error, EBUSY,
 				   RTE_FLOW_ERROR_TYPE_UNSPECIFIED,
 				   NULL,
-				   "action template in using");
+				   "action template is in use");
 	}
 	LIST_REMOVE(template, next);
 	if (template->tmpl)
@@ -5013,7 +5013,7 @@ flow_hw_pattern_template_destroy(struct rte_eth_dev *dev __rte_unused,
 		return rte_flow_error_set(error, EBUSY,
 				   RTE_FLOW_ERROR_TYPE_UNSPECIFIED,
 				   NULL,
-				   "item template in using");
+				   "item template is in use");
 	}
 	LIST_REMOVE(template, next);
 	claim_zero(mlx5dr_match_template_destroy(template->mt));
@@ -7458,9 +7458,9 @@ void
 flow_hw_resource_release(struct rte_eth_dev *dev)
 {
 	struct mlx5_priv *priv = dev->data->dev_private;
-	struct rte_flow_template_table *tbl;
-	struct rte_flow_pattern_template *it;
-	struct rte_flow_actions_template *at;
+	struct rte_flow_template_table *tbl, *temp_tbl;
+	struct rte_flow_pattern_template *it, *temp_it;
+	struct rte_flow_actions_template *at, *temp_at;
 	uint32_t i;
 
 	if (!priv->dr_ctx)
@@ -7470,21 +7470,29 @@ flow_hw_resource_release(struct rte_eth_dev *dev)
 	flow_hw_cleanup_ctrl_fdb_tables(dev);
 	flow_hw_cleanup_tx_repr_tagging(dev);
 	flow_hw_cleanup_ctrl_rx_tables(dev);
-	while (!LIST_EMPTY(&priv->flow_hw_tbl_ongo)) {
-		tbl = LIST_FIRST(&priv->flow_hw_tbl_ongo);
-		flow_hw_table_destroy(dev, tbl, NULL);
+	tbl = LIST_FIRST(&priv->flow_hw_tbl_ongo);
+	while (tbl) {
+		temp_tbl = LIST_NEXT(tbl, next);
+		claim_zero(flow_hw_table_destroy(dev, tbl, NULL));
+		tbl = temp_tbl;
 	}
-	while (!LIST_EMPTY(&priv->flow_hw_tbl)) {
-		tbl = LIST_FIRST(&priv->flow_hw_tbl);
-		flow_hw_table_destroy(dev, tbl, NULL);
+	tbl = LIST_FIRST(&priv->flow_hw_tbl);
+	while (tbl) {
+		temp_tbl = LIST_NEXT(tbl, next);
+		claim_zero(flow_hw_table_destroy(dev, tbl, NULL));
+		tbl = temp_tbl;
 	}
-	while (!LIST_EMPTY(&priv->flow_hw_itt)) {
-		it = LIST_FIRST(&priv->flow_hw_itt);
-		flow_hw_pattern_template_destroy(dev, it, NULL);
+	it = LIST_FIRST(&priv->flow_hw_itt);
+	while (it) {
+		temp_it = LIST_NEXT(it, next);
+		claim_zero(flow_hw_pattern_template_destroy(dev, it, NULL));
+		it = temp_it;
 	}
-	while (!LIST_EMPTY(&priv->flow_hw_at)) {
-		at = LIST_FIRST(&priv->flow_hw_at);
-		flow_hw_actions_template_destroy(dev, at, NULL);
+	at = LIST_FIRST(&priv->flow_hw_at);
+	while (at) {
+		temp_at = LIST_NEXT(at, next);
+		claim_zero(flow_hw_actions_template_destroy(dev, at, NULL));
+		at = temp_at;
 	}
 	for (i = 0; i < MLX5_HW_ACTION_FLAG_MAX; i++) {
 		if (priv->hw_drop[i])
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.360608425 +0100
+++ 0074-net-mlx5-break-flow-resource-release-loop.patch	2024-06-25 00:22:13.273187443 +0100
@@ -1 +1 @@
-From 4fcb7a05e38172aed60f87a6287bb2ee3d9828fd Mon Sep 17 00:00:00 2001
+From 68b68c76e1f2f9112d5016c732a00e97a0e5460f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4fcb7a05e38172aed60f87a6287bb2ee3d9828fd ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -19,2 +20,2 @@
- drivers/net/mlx5/mlx5_flow_hw.c | 54 +++++++++++++++++++--------------
- 1 file changed, 32 insertions(+), 22 deletions(-)
+ drivers/net/mlx5/mlx5_flow_hw.c | 44 +++++++++++++++++++--------------
+ 1 file changed, 26 insertions(+), 18 deletions(-)
@@ -23 +24 @@
-index e8c06387f8..53c6cc5961 100644
+index 5333495a59..c902b35f0b 100644
@@ -26 +27 @@
-@@ -5062,7 +5062,7 @@ flow_hw_table_destroy(struct rte_eth_dev *dev,
+@@ -3407,7 +3407,7 @@ flow_hw_table_destroy(struct rte_eth_dev *dev,
@@ -30 +31 @@
--				   "table in use");
+-				   "table in using");
@@ -35 +36 @@
-@@ -7362,7 +7362,7 @@ flow_hw_actions_template_destroy(struct rte_eth_dev *dev,
+@@ -4660,7 +4660,7 @@ flow_hw_actions_template_destroy(struct rte_eth_dev *dev __rte_unused,
@@ -42,3 +43,3 @@
- 	if (template->action_flags & flag)
- 		mlx5_free_srh_flex_parser(dev);
-@@ -7986,7 +7986,7 @@ flow_hw_pattern_template_destroy(struct rte_eth_dev *dev,
+ 	LIST_REMOVE(template, next);
+ 	if (template->tmpl)
+@@ -5013,7 +5013,7 @@ flow_hw_pattern_template_destroy(struct rte_eth_dev *dev __rte_unused,
@@ -51,3 +52,3 @@
- 	if (template->item_flags & (MLX5_FLOW_ITEM_OUTER_IPV6_ROUTING_EXT |
- 				    MLX5_FLOW_ITEM_INNER_IPV6_ROUTING_EXT))
-@@ -10787,10 +10787,10 @@ void
+ 	LIST_REMOVE(template, next);
+ 	claim_zero(mlx5dr_match_template_destroy(template->mt));
+@@ -7458,9 +7458,9 @@ void
@@ -60 +60,0 @@
--	struct mlx5_flow_group *grp;
@@ -64 +63,0 @@
-+	struct mlx5_flow_group *grp, *temp_grp;
@@ -68 +67,2 @@
-@@ -10802,25 +10802,35 @@ flow_hw_resource_release(struct rte_eth_dev *dev)
+@@ -7470,21 +7470,29 @@ flow_hw_resource_release(struct rte_eth_dev *dev)
+ 	flow_hw_cleanup_ctrl_fdb_tables(dev);
@@ -71,10 +70,0 @@
- 	flow_hw_action_template_drop_release(dev);
--	while (!LIST_EMPTY(&priv->flow_hw_grp)) {
--		grp = LIST_FIRST(&priv->flow_hw_grp);
--		flow_hw_group_unset_miss_group(dev, grp, NULL);
-+	grp = LIST_FIRST(&priv->flow_hw_grp);
-+	while (grp) {
-+		temp_grp = LIST_NEXT(grp, next);
-+		claim_zero(flow_hw_group_unset_miss_group(dev, grp, NULL));
-+		grp = temp_grp;
- 	}

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

* patch 'net/mlx5: fix access to flow template operations' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (72 preceding siblings ...)
  2024-06-24 23:59 ` patch 'net/mlx5: break flow resource release loop' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'net/mlx5: support jump in meter hierarchy' " luca.boccassi
                   ` (5 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: Gregory Etelson; +Cc: Dariusz Sosnowski, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/739bd81a4664d03fc0357dab0de07e87d8896f4a

Thanks.

Luca Boccassi

---
From 739bd81a4664d03fc0357dab0de07e87d8896f4a Mon Sep 17 00:00:00 2001
From: Gregory Etelson <getelson@nvidia.com>
Date: Sun, 2 Jun 2024 09:00:49 +0300
Subject: [PATCH] net/mlx5: fix access to flow template operations

[ upstream commit acbb57b25d30147d1fd0edf1e8314a0a3d3c38c9 ]

PMD activates HWS template API context during port configuration.

There was no validation that the HWS context was activated before
the PMD tried to process other template function calls.

The patch adds HWS context validation.

Fixes: b401400db24e ("net/mlx5: add port flow configuration")

Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_hw.c | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index c902b35f0b..45709c9fd2 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -56,6 +56,20 @@
 #define MLX5_HW_VLAN_PUSH_VID_IDX 1
 #define MLX5_HW_VLAN_PUSH_PCP_IDX 2
 
+static bool
+mlx5_hw_ctx_validate(const struct rte_eth_dev *dev, struct rte_flow_error *error)
+{
+	const struct mlx5_priv *priv = dev->data->dev_private;
+
+	if (!priv->dr_ctx) {
+		rte_flow_error_set(error, EINVAL,
+				   RTE_FLOW_ERROR_TYPE_UNSPECIFIED, NULL,
+				   "non-template flow engine was not configured");
+		return false;
+	}
+	return true;
+}
+
 static int flow_hw_flush_all_ctrl_flows(struct rte_eth_dev *dev);
 static int flow_hw_translate_group(struct rte_eth_dev *dev,
 				   const struct mlx5_flow_template_table_cfg *cfg,
@@ -3965,6 +3979,8 @@ mlx5_flow_hw_actions_validate(struct rte_eth_dev *dev,
 	bool actions_end = false;
 	int ret;
 
+	if (!mlx5_hw_ctx_validate(dev, error))
+		return -rte_errno;
 	/* FDB actions are only valid to proxy port. */
 	if (attr->transfer && (!priv->sh->config.dv_esw_en || !priv->master))
 		return rte_flow_error_set(error, EINVAL,
@@ -4717,6 +4733,8 @@ flow_hw_pattern_validate(struct rte_eth_dev *dev,
 	bool items_end = false;
 	uint32_t tag_bitmap = 0;
 
+	if (!mlx5_hw_ctx_validate(dev, error))
+		return -rte_errno;
 	if (!attr->ingress && !attr->egress && !attr->transfer)
 		return rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ATTR, NULL,
 					  "at least one of the direction attributes"
@@ -7975,6 +7993,9 @@ flow_hw_action_handle_create(struct rte_eth_dev *dev, uint32_t queue,
 	bool push = true;
 	bool aso = false;
 
+	if (!mlx5_hw_ctx_validate(dev, error))
+		return NULL;
+
 	if (attr) {
 		MLX5_ASSERT(queue != MLX5_HW_INV_QUEUE);
 		if (unlikely(!priv->hw_q[queue].job_idx)) {
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.404405798 +0100
+++ 0075-net-mlx5-fix-access-to-flow-template-operations.patch	2024-06-25 00:22:13.281187606 +0100
@@ -1 +1 @@
-From acbb57b25d30147d1fd0edf1e8314a0a3d3c38c9 Mon Sep 17 00:00:00 2001
+From 739bd81a4664d03fc0357dab0de07e87d8896f4a Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit acbb57b25d30147d1fd0edf1e8314a0a3d3c38c9 ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -19,2 +20,2 @@
- drivers/net/mlx5/mlx5_flow_hw.c | 22 ++++++++++++++++++++++
- 1 file changed, 22 insertions(+)
+ drivers/net/mlx5/mlx5_flow_hw.c | 21 +++++++++++++++++++++
+ 1 file changed, 21 insertions(+)
@@ -23 +24 @@
-index 53c6cc5961..e97afb0c86 100644
+index c902b35f0b..45709c9fd2 100644
@@ -26,3 +27,3 @@
-@@ -206,6 +206,20 @@ mlx5_destroy_multi_pattern_segment(struct mlx5_multi_pattern_segment *segment);
- static __rte_always_inline enum mlx5_indirect_list_type
- flow_hw_inlist_type_get(const struct rte_flow_action *actions);
+@@ -56,6 +56,20 @@
+ #define MLX5_HW_VLAN_PUSH_VID_IDX 1
+ #define MLX5_HW_VLAN_PUSH_PCP_IDX 2
@@ -44,4 +45,5 @@
- static __rte_always_inline int
- mlx5_multi_pattern_reformat_to_index(enum mlx5dr_action_type type)
- {
-@@ -6399,6 +6413,8 @@ mlx5_flow_hw_actions_validate(struct rte_eth_dev *dev,
+ static int flow_hw_flush_all_ctrl_flows(struct rte_eth_dev *dev);
+ static int flow_hw_translate_group(struct rte_eth_dev *dev,
+ 				   const struct mlx5_flow_template_table_cfg *cfg,
+@@ -3965,6 +3979,8 @@ mlx5_flow_hw_actions_validate(struct rte_eth_dev *dev,
+ 	bool actions_end = false;
@@ -49 +50,0 @@
- 	const struct rte_flow_action_ipv6_ext_remove *remove_data;
@@ -56 +57,2 @@
-@@ -7528,6 +7544,8 @@ flow_hw_pattern_validate(struct rte_eth_dev *dev,
+@@ -4717,6 +4733,8 @@ flow_hw_pattern_validate(struct rte_eth_dev *dev,
+ 	bool items_end = false;
@@ -58 +59,0 @@
- 	int ret;
@@ -65 +66,2 @@
-@@ -11259,6 +11277,8 @@ flow_hw_action_handle_create(struct rte_eth_dev *dev, uint32_t queue,
+@@ -7975,6 +7993,9 @@ flow_hw_action_handle_create(struct rte_eth_dev *dev, uint32_t queue,
+ 	bool push = true;
@@ -67,10 +68,0 @@
- 	bool force_job = action->type == RTE_FLOW_ACTION_TYPE_METER_MARK;
- 
-+	if (!mlx5_hw_ctx_validate(dev, error))
-+		return NULL;
- 	if (attr || force_job) {
- 		job = flow_hw_action_job_init(priv, queue, NULL, user_data,
- 					      NULL, MLX5_HW_Q_JOB_TYPE_CREATE,
-@@ -12541,6 +12561,8 @@ flow_hw_async_action_list_handle_create(struct rte_eth_dev *dev, uint32_t queue,
- 		}
- 	};
@@ -80,3 +72,4 @@
- 	if (!actions) {
- 		rte_flow_error_set(error, EINVAL, RTE_FLOW_ERROR_TYPE_ACTION,
- 				   NULL, "No action list");
++
+ 	if (attr) {
+ 		MLX5_ASSERT(queue != MLX5_HW_INV_QUEUE);
+ 		if (unlikely(!priv->hw_q[queue].job_idx)) {

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

* patch 'net/mlx5: support jump in meter hierarchy' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (73 preceding siblings ...)
  2024-06-24 23:59 ` patch 'net/mlx5: fix access to flow template operations' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'net/mlx5: fix crash on counter pool destroy' " luca.boccassi
                   ` (4 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: Shun Hao; +Cc: Suanming Mou, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/aadaf7fe72821e2d27cbf4f95c25b909ededc49d

Thanks.

Luca Boccassi

---
From aadaf7fe72821e2d27cbf4f95c25b909ededc49d Mon Sep 17 00:00:00 2001
From: Shun Hao <shunh@nvidia.com>
Date: Tue, 4 Jun 2024 05:51:56 +0300
Subject: [PATCH] net/mlx5: support jump in meter hierarchy

[ upstream commit dc1d92a4f547f8af6eb9b8824257ab3fd8dfbc77 ]

Currently in meter hierarchy, only meter action is supported for green
and yellow policy flow.
This patch adds support of jump action for green or yellow policy flow.

Fixes: 96ca87da4f46 ("net/mlx5: validate yellow meter action")

Signed-off-by: Shun Hao <shunh@nvidia.com>
Acked-by: Suanming Mou <suanmingm@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_dv.c | 36 ++++++++++++++++++---------------
 1 file changed, 20 insertions(+), 16 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index f8431386e0..2bdca754bc 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -17173,7 +17173,7 @@ __flow_dv_create_policy_matcher(struct rte_eth_dev *dev,
 static int
 __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
 		struct mlx5_flow_meter_sub_policy *sub_policy,
-		uint8_t egress, uint8_t transfer, bool match_src_port,
+		uint8_t egress, uint8_t transfer, bool *match_src_port,
 		struct mlx5_meter_policy_acts acts[RTE_COLORS])
 {
 	struct mlx5_priv *priv = dev->data->dev_private;
@@ -17188,6 +17188,7 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
 		.reserved = 0,
 	};
 	int i;
+	uint16_t priority;
 	int ret = mlx5_flow_get_reg_id(dev, MLX5_MTR_COLOR, 0, &flow_err);
 	struct mlx5_sub_policy_color_rule *color_rule;
 	struct mlx5_sub_policy_color_rule *tmp_rules[RTE_COLORS] = {NULL};
@@ -17222,12 +17223,12 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
 		TAILQ_INSERT_TAIL(&sub_policy->color_rules[i],
 				  color_rule, next_port);
 		color_rule->src_port = priv->representor_id;
-		/* No use. */
-		attr.priority = i;
+		priority = (match_src_port[i] == match_src_port[RTE_COLOR_GREEN]) ?
+			   MLX5_MTR_POLICY_MATCHER_PRIO : (MLX5_MTR_POLICY_MATCHER_PRIO + 1);
 		/* Create matchers for colors. */
 		if (__flow_dv_create_policy_matcher(dev, color_reg_c_idx,
-				MLX5_MTR_POLICY_MATCHER_PRIO, sub_policy,
-				&attr, match_src_port, NULL,
+				priority, sub_policy,
+				&attr, match_src_port[i], NULL,
 				&color_rule->matcher, &flow_err)) {
 			DRV_LOG(ERR, "Failed to create color%u matcher.", i);
 			goto err_exit;
@@ -17237,7 +17238,7 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
 				color_reg_c_idx, (enum rte_color)i,
 				color_rule->matcher,
 				acts[i].actions_n, acts[i].dv_actions,
-				match_src_port, NULL, &color_rule->rule,
+				match_src_port[i], NULL, &color_rule->rule,
 				&attr)) {
 			DRV_LOG(ERR, "Failed to create color%u rule.", i);
 			goto err_exit;
@@ -17285,7 +17286,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
 	uint8_t egress = (domain == MLX5_MTR_DOMAIN_EGRESS) ? 1 : 0;
 	uint8_t transfer = (domain == MLX5_MTR_DOMAIN_TRANSFER) ? 1 : 0;
 	bool mtr_first = egress || (transfer && priv->representor_id != UINT16_MAX);
-	bool match_src_port = false;
+	bool match_src_port[RTE_COLORS] = {false};
 	int i;
 
 	/* If RSS or Queue, no previous actions / rules is created. */
@@ -17356,7 +17357,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
 				acts[i].dv_actions[acts[i].actions_n] =
 					port_action->action;
 				acts[i].actions_n++;
-				match_src_port = true;
+				match_src_port[i] = true;
 				break;
 			case MLX5_FLOW_FATE_DROP:
 			case MLX5_FLOW_FATE_JUMP:
@@ -17408,7 +17409,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
 				acts[i].dv_actions[acts[i].actions_n++] =
 							tbl_data->jump.action;
 				if (mtr_policy->act_cnt[i].modify_hdr)
-					match_src_port = !!transfer;
+					match_src_port[i] = !!transfer;
 				break;
 			default:
 				/*Queue action do nothing*/
@@ -17422,9 +17423,9 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
 			"Failed to create policy rules per domain.");
 		goto err_exit;
 	}
-	if (match_src_port) {
-		mtr_policy->match_port = match_src_port;
-		mtr_policy->hierarchy_match_port = match_src_port;
+	if (match_src_port[RTE_COLOR_GREEN] || match_src_port[RTE_COLOR_YELLOW]) {
+		mtr_policy->match_port = 1;
+		mtr_policy->hierarchy_match_port = 1;
 	}
 	return 0;
 err_exit:
@@ -17486,6 +17487,7 @@ __flow_dv_create_domain_def_policy(struct rte_eth_dev *dev, uint32_t domain)
 	uint8_t egress, transfer;
 	struct rte_flow_error error;
 	struct mlx5_meter_policy_acts acts[RTE_COLORS];
+	bool match_src_port[RTE_COLORS] = {false};
 	int ret;
 
 	egress = (domain == MLX5_MTR_DOMAIN_EGRESS) ? 1 : 0;
@@ -17561,7 +17563,7 @@ __flow_dv_create_domain_def_policy(struct rte_eth_dev *dev, uint32_t domain)
 		/* Create default policy rules. */
 		ret = __flow_dv_create_domain_policy_rules(dev,
 					&def_policy->sub_policy,
-					egress, transfer, false, acts);
+					egress, transfer, match_src_port, acts);
 		if (ret) {
 			DRV_LOG(ERR, "Failed to create default policy rules.");
 			goto def_policy_error;
@@ -19142,11 +19144,13 @@ flow_dv_validate_mtr_policy_acts(struct rte_eth_dev *dev,
 		}
 	}
 	if (next_mtr && *policy_mode == MLX5_MTR_POLICY_MODE_ALL) {
-		if (!(action_flags[RTE_COLOR_GREEN] & action_flags[RTE_COLOR_YELLOW] &
-		      MLX5_FLOW_ACTION_METER_WITH_TERMINATED_POLICY))
+		uint64_t hierarchy_type_flag =
+			MLX5_FLOW_ACTION_METER_WITH_TERMINATED_POLICY | MLX5_FLOW_ACTION_JUMP;
+		if (!(action_flags[RTE_COLOR_GREEN] & hierarchy_type_flag) ||
+		    !(action_flags[RTE_COLOR_YELLOW] & hierarchy_type_flag))
 			return -rte_mtr_error_set(error, EINVAL, RTE_MTR_ERROR_TYPE_METER_POLICY,
 						  NULL,
-						  "Meter hierarchy supports meter action only.");
+						  "Unsupported action in meter hierarchy.");
 	}
 	/* If both colors have RSS, the attributes should be the same. */
 	if (flow_dv_mtr_policy_rss_compare(rss_color[RTE_COLOR_GREEN],
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.447954111 +0100
+++ 0076-net-mlx5-support-jump-in-meter-hierarchy.patch	2024-06-25 00:22:13.297187932 +0100
@@ -1 +1 @@
-From dc1d92a4f547f8af6eb9b8824257ab3fd8dfbc77 Mon Sep 17 00:00:00 2001
+From aadaf7fe72821e2d27cbf4f95c25b909ededc49d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit dc1d92a4f547f8af6eb9b8824257ab3fd8dfbc77 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 99abb2f2fb..220d92b1a7 100644
+index f8431386e0..2bdca754bc 100644
@@ -23 +24 @@
-@@ -17963,7 +17963,7 @@ __flow_dv_create_policy_matcher(struct rte_eth_dev *dev,
+@@ -17173,7 +17173,7 @@ __flow_dv_create_policy_matcher(struct rte_eth_dev *dev,
@@ -32 +33 @@
-@@ -17978,6 +17978,7 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
+@@ -17188,6 +17188,7 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
@@ -40 +41 @@
-@@ -18012,12 +18013,12 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
+@@ -17222,12 +17223,12 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
@@ -57 +58 @@
-@@ -18027,7 +18028,7 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
+@@ -17237,7 +17238,7 @@ __flow_dv_create_domain_policy_rules(struct rte_eth_dev *dev,
@@ -66 +67 @@
-@@ -18075,7 +18076,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
+@@ -17285,7 +17286,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
@@ -75 +76 @@
-@@ -18146,7 +18147,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
+@@ -17356,7 +17357,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
@@ -84 +85 @@
-@@ -18198,7 +18199,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
+@@ -17408,7 +17409,7 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
@@ -93 +94 @@
-@@ -18212,9 +18213,9 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
+@@ -17422,9 +17423,9 @@ __flow_dv_create_policy_acts_rules(struct rte_eth_dev *dev,
@@ -106 +107 @@
-@@ -18276,6 +18277,7 @@ __flow_dv_create_domain_def_policy(struct rte_eth_dev *dev, uint32_t domain)
+@@ -17486,6 +17487,7 @@ __flow_dv_create_domain_def_policy(struct rte_eth_dev *dev, uint32_t domain)
@@ -114 +115 @@
-@@ -18351,7 +18353,7 @@ __flow_dv_create_domain_def_policy(struct rte_eth_dev *dev, uint32_t domain)
+@@ -17561,7 +17563,7 @@ __flow_dv_create_domain_def_policy(struct rte_eth_dev *dev, uint32_t domain)
@@ -123 +124 @@
-@@ -19934,11 +19936,13 @@ flow_dv_validate_mtr_policy_acts(struct rte_eth_dev *dev,
+@@ -19142,11 +19144,13 @@ flow_dv_validate_mtr_policy_acts(struct rte_eth_dev *dev,

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

* patch 'net/mlx5: fix crash on counter pool destroy' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (74 preceding siblings ...)
  2024-06-24 23:59 ` patch 'net/mlx5: support jump in meter hierarchy' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'test/crypto: fix enqueue/dequeue callback case' " luca.boccassi
                   ` (3 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: Maayan Kashani; +Cc: Dariusz Sosnowski, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/e12b4a47badb24b5b69c60fad22653aee3ee8869

Thanks.

Luca Boccassi

---
From e12b4a47badb24b5b69c60fad22653aee3ee8869 Mon Sep 17 00:00:00 2001
From: Maayan Kashani <mkashani@nvidia.com>
Date: Sun, 9 Jun 2024 14:01:02 +0300
Subject: [PATCH] net/mlx5: fix crash on counter pool destroy

[ upstream commit 3331d59551cdecd2db3a2064a7d6e4bf9396b849 ]

If the counter pool was not added to list,
and an error state was reached,
on attempt to destroy the counter pool,
segmentation fault was received during list remove action.

Added a check to verify the list is not empty before trying to
remove the cpool from the list.

Invalid state, leading to segfault,
can also be reached in the following scenario:
1.	mlx5_hws_cnt_pool_init() does a zmalloc and initializes most
        of the fields of cpool, but does not initialize the next field.
2.	mlx5_hws_cnt_pool_dcs_alloc() attempts to bulk allocate flow counters.
	If this fails, we skip straight to 4.
	In HW, this can fail simply if FW doesn't support bulk flow
	counter allocation.
3.	Right before the goto error, we insert the cpool to the hws_cpool_list.
	This is where the next field is initialized.
4.	mlx5_hws_cnt_pool_destroy() assumes the cpool's next field
	is initialized and SEGVs if not.

So, added a guard against cases where the entry was uninitialized
(checking le_prev field is not NULL).

Fixes: 6ac2104ac125 ("net/mlx5: fix counter query during port close")

Signed-off-by: Maayan Kashani <mkashani@nvidia.com>
Acked-by: Dariusz Sosnowski <dsosnowski@nvidia.com>
---
 drivers/net/mlx5/mlx5_hws_cnt.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_hws_cnt.c b/drivers/net/mlx5/mlx5_hws_cnt.c
index d4ef44d1a3..8415aa411f 100644
--- a/drivers/net/mlx5/mlx5_hws_cnt.c
+++ b/drivers/net/mlx5/mlx5_hws_cnt.c
@@ -717,7 +717,9 @@ mlx5_hws_cnt_pool_destroy(struct mlx5_dev_ctx_shared *sh,
 	 * Maybe blocked for at most 200ms here.
 	 */
 	rte_spinlock_lock(&sh->cpool_lock);
-	LIST_REMOVE(cpool, next);
+	/* Try to remove cpool before it was added to list caused segfault. */
+	if (!LIST_EMPTY(&sh->hws_cpool_list) && cpool->next.le_prev)
+		LIST_REMOVE(cpool, next);
 	rte_spinlock_unlock(&sh->cpool_lock);
 	if (--sh->cnt_svc->refcnt == 0)
 		mlx5_hws_cnt_svc_deinit(sh);
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.493745565 +0100
+++ 0077-net-mlx5-fix-crash-on-counter-pool-destroy.patch	2024-06-25 00:22:13.297187932 +0100
@@ -1 +1 @@
-From 3331d59551cdecd2db3a2064a7d6e4bf9396b849 Mon Sep 17 00:00:00 2001
+From e12b4a47badb24b5b69c60fad22653aee3ee8869 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3331d59551cdecd2db3a2064a7d6e4bf9396b849 ]
+
@@ -31 +32,0 @@
-Cc: stable@dpdk.org
@@ -40 +41 @@
-index 36d422bdfa..a46a4bd94e 100644
+index d4ef44d1a3..8415aa411f 100644
@@ -43 +44 @@
-@@ -718,7 +718,9 @@ mlx5_hws_cnt_pool_destroy(struct mlx5_dev_ctx_shared *sh,
+@@ -717,7 +717,9 @@ mlx5_hws_cnt_pool_destroy(struct mlx5_dev_ctx_shared *sh,
@@ -52,2 +53,2 @@
- 	if (cpool->cfg.host_cpool == NULL) {
- 		if (--sh->cnt_svc->refcnt == 0)
+ 	if (--sh->cnt_svc->refcnt == 0)
+ 		mlx5_hws_cnt_svc_deinit(sh);

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

* patch 'test/crypto: fix enqueue/dequeue callback case' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (75 preceding siblings ...)
  2024-06-24 23:59 ` patch 'net/mlx5: fix crash on counter pool destroy' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'telemetry: lower log level on socket error' " luca.boccassi
                   ` (2 subsequent siblings)
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: Akhil Goyal; +Cc: Ganapati Kundapura, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/5cbc25e40f540b3518433c420f947ce3842a8cfe

Thanks.

Luca Boccassi

---
From 5cbc25e40f540b3518433c420f947ce3842a8cfe Mon Sep 17 00:00:00 2001
From: Akhil Goyal <gakhil@marvell.com>
Date: Fri, 24 May 2024 22:43:27 +0530
Subject: [PATCH] test/crypto: fix enqueue/dequeue callback case

[ upstream commit 4ad17a1c8fb336a182f2c1b62127d8871d45f804 ]

The enqueue/dequeue callback test cases were using the
test_null_burst_operation() for doing enqueue/dequeue.
But this function is only designed to be run for NULL PMD.
Hence for other PMDs, the callback was not getting called.
Now, separate processing thread is removed, instead NULL crypto
operation is created and processed so that callbacks are called.
Also added a check on a global static variable to verify
that the callback is actually called and fail the case if
it is not getting called.

Fixes: 5523a75af539 ("test/crypto: add case for enqueue/dequeue callbacks")

Signed-off-by: Akhil Goyal <gakhil@marvell.com>
Acked-by: Ganapati Kundapura <ganapati.kundapura@intel.com>
---
 app/test/test_cryptodev.c | 106 ++++++++++++++++++++++++++++++++------
 1 file changed, 89 insertions(+), 17 deletions(-)

diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c
index b75edb2f2b..96cd9ef7dc 100644
--- a/app/test/test_cryptodev.c
+++ b/app/test/test_cryptodev.c
@@ -194,6 +194,8 @@ post_process_raw_dp_op(void *user_data,	uint32_t index __rte_unused,
 static struct crypto_testsuite_params testsuite_params = { NULL };
 struct crypto_testsuite_params *p_testsuite_params = &testsuite_params;
 static struct crypto_unittest_params unittest_params;
+static bool enq_cb_called;
+static bool deq_cb_called;
 
 void
 process_sym_raw_dp_op(uint8_t dev_id, uint16_t qp_id,
@@ -12607,6 +12609,7 @@ test_enq_callback(uint16_t dev_id, uint16_t qp_id, struct rte_crypto_op **ops,
 	RTE_SET_USED(ops);
 	RTE_SET_USED(user_param);
 
+	enq_cb_called = true;
 	printf("crypto enqueue callback called\n");
 	return nb_ops;
 }
@@ -12620,21 +12623,58 @@ test_deq_callback(uint16_t dev_id, uint16_t qp_id, struct rte_crypto_op **ops,
 	RTE_SET_USED(ops);
 	RTE_SET_USED(user_param);
 
+	deq_cb_called = true;
 	printf("crypto dequeue callback called\n");
 	return nb_ops;
 }
 
 /*
- * Thread using enqueue/dequeue callback with RCU.
+ * Process enqueue/dequeue NULL crypto request to verify callback with RCU.
  */
 static int
-test_enqdeq_callback_thread(void *arg)
+test_enqdeq_callback_null_cipher(void)
 {
-	RTE_SET_USED(arg);
-	/* DP thread calls rte_cryptodev_enqueue_burst()/
-	 * rte_cryptodev_dequeue_burst() and invokes callback.
-	 */
-	test_null_burst_operation();
+	struct crypto_testsuite_params *ts_params = &testsuite_params;
+	struct crypto_unittest_params *ut_params = &unittest_params;
+
+	/* Setup Cipher Parameters */
+	ut_params->cipher_xform.type = RTE_CRYPTO_SYM_XFORM_CIPHER;
+	ut_params->cipher_xform.next = &ut_params->auth_xform;
+
+	ut_params->cipher_xform.cipher.algo = RTE_CRYPTO_CIPHER_NULL;
+	ut_params->cipher_xform.cipher.op = RTE_CRYPTO_CIPHER_OP_ENCRYPT;
+
+	/* Setup Auth Parameters */
+	ut_params->auth_xform.type = RTE_CRYPTO_SYM_XFORM_AUTH;
+	ut_params->auth_xform.next = NULL;
+
+	ut_params->auth_xform.auth.algo = RTE_CRYPTO_AUTH_NULL;
+	ut_params->auth_xform.auth.op = RTE_CRYPTO_AUTH_OP_GENERATE;
+
+	/* Create Crypto session */
+	ut_params->sess = rte_cryptodev_sym_session_create(ts_params->valid_devs[0],
+				&ut_params->auth_xform, ts_params->session_mpool);
+	TEST_ASSERT_NOT_NULL(ut_params->sess, "Session creation failed");
+
+	ut_params->op = rte_crypto_op_alloc(ts_params->op_mpool, RTE_CRYPTO_OP_TYPE_SYMMETRIC);
+	TEST_ASSERT_NOT_NULL(ut_params->op, "Failed to allocate symmetric crypto op");
+
+	/* Allocate mbuf */
+	ut_params->ibuf = rte_pktmbuf_alloc(ts_params->mbuf_pool);
+	TEST_ASSERT_NOT_NULL(ut_params->ibuf, "Failed to allocate mbuf");
+
+	/* Append some random data */
+	TEST_ASSERT_NOT_NULL(rte_pktmbuf_append(ut_params->ibuf, sizeof(unsigned int)),
+			"no room to append data");
+
+	rte_crypto_op_attach_sym_session(ut_params->op, ut_params->sess);
+
+	ut_params->op->sym->m_src = ut_params->ibuf;
+
+	/* Process crypto operation */
+	TEST_ASSERT_NOT_NULL(process_crypto_request(ts_params->valid_devs[0], ut_params->op),
+			"failed to process sym crypto op");
+
 	return 0;
 }
 
@@ -12642,6 +12682,7 @@ static int
 test_enq_callback_setup(void)
 {
 	struct crypto_testsuite_params *ts_params = &testsuite_params;
+	struct rte_cryptodev_sym_capability_idx cap_idx;
 	struct rte_cryptodev_info dev_info;
 	struct rte_cryptodev_qp_conf qp_conf = {
 		.nb_descriptors = MAX_NUM_OPS_INFLIGHT
@@ -12649,6 +12690,19 @@ test_enq_callback_setup(void)
 
 	struct rte_cryptodev_cb *cb;
 	uint16_t qp_id = 0;
+	int j = 0;
+
+	/* Verify the crypto capabilities for which enqueue/dequeue is done. */
+	cap_idx.type = RTE_CRYPTO_SYM_XFORM_AUTH;
+	cap_idx.algo.auth = RTE_CRYPTO_AUTH_NULL;
+	if (rte_cryptodev_sym_capability_get(ts_params->valid_devs[0],
+			&cap_idx) == NULL)
+		return TEST_SKIPPED;
+	cap_idx.type = RTE_CRYPTO_SYM_XFORM_CIPHER;
+	cap_idx.algo.cipher = RTE_CRYPTO_CIPHER_NULL;
+	if (rte_cryptodev_sym_capability_get(ts_params->valid_devs[0],
+			&cap_idx) == NULL)
+		return TEST_SKIPPED;
 
 	/* Stop the device in case it's started so it can be configured */
 	rte_cryptodev_stop(ts_params->valid_devs[0]);
@@ -12672,6 +12726,7 @@ test_enq_callback_setup(void)
 			qp_conf.nb_descriptors, qp_id,
 			ts_params->valid_devs[0]);
 
+	enq_cb_called = false;
 	/* Test with invalid crypto device */
 	cb = rte_cryptodev_add_enq_callback(RTE_CRYPTO_MAX_DEVS,
 			qp_id, test_enq_callback, NULL);
@@ -12704,12 +12759,11 @@ test_enq_callback_setup(void)
 
 	rte_cryptodev_start(ts_params->valid_devs[0]);
 
-	/* Launch a thread */
-	rte_eal_remote_launch(test_enqdeq_callback_thread, NULL,
-				rte_get_next_lcore(-1, 1, 0));
+	TEST_ASSERT_SUCCESS(test_enqdeq_callback_null_cipher(), "Crypto Processing failed");
 
-	/* Wait until reader exited. */
-	rte_eal_mp_wait_lcore();
+	/* Wait until callback not called. */
+	while (!enq_cb_called && (j++ < 10))
+		rte_delay_ms(10);
 
 	/* Test with invalid crypto device */
 	TEST_ASSERT_FAIL(rte_cryptodev_remove_enq_callback(
@@ -12734,6 +12788,8 @@ test_enq_callback_setup(void)
 			"qp %u on cryptodev %u",
 			qp_id, ts_params->valid_devs[0]);
 
+	TEST_ASSERT(enq_cb_called == true, "Crypto enqueue callback not called");
+
 	return TEST_SUCCESS;
 }
 
@@ -12741,6 +12797,7 @@ static int
 test_deq_callback_setup(void)
 {
 	struct crypto_testsuite_params *ts_params = &testsuite_params;
+	struct rte_cryptodev_sym_capability_idx cap_idx;
 	struct rte_cryptodev_info dev_info;
 	struct rte_cryptodev_qp_conf qp_conf = {
 		.nb_descriptors = MAX_NUM_OPS_INFLIGHT
@@ -12748,6 +12805,19 @@ test_deq_callback_setup(void)
 
 	struct rte_cryptodev_cb *cb;
 	uint16_t qp_id = 0;
+	int j = 0;
+
+	/* Verify the crypto capabilities for which enqueue/dequeue is done. */
+	cap_idx.type = RTE_CRYPTO_SYM_XFORM_AUTH;
+	cap_idx.algo.auth = RTE_CRYPTO_AUTH_NULL;
+	if (rte_cryptodev_sym_capability_get(ts_params->valid_devs[0],
+			&cap_idx) == NULL)
+		return TEST_SKIPPED;
+	cap_idx.type = RTE_CRYPTO_SYM_XFORM_CIPHER;
+	cap_idx.algo.cipher = RTE_CRYPTO_CIPHER_NULL;
+	if (rte_cryptodev_sym_capability_get(ts_params->valid_devs[0],
+			&cap_idx) == NULL)
+		return TEST_SKIPPED;
 
 	/* Stop the device in case it's started so it can be configured */
 	rte_cryptodev_stop(ts_params->valid_devs[0]);
@@ -12771,6 +12841,7 @@ test_deq_callback_setup(void)
 			qp_conf.nb_descriptors, qp_id,
 			ts_params->valid_devs[0]);
 
+	deq_cb_called = false;
 	/* Test with invalid crypto device */
 	cb = rte_cryptodev_add_deq_callback(RTE_CRYPTO_MAX_DEVS,
 			qp_id, test_deq_callback, NULL);
@@ -12803,12 +12874,11 @@ test_deq_callback_setup(void)
 
 	rte_cryptodev_start(ts_params->valid_devs[0]);
 
-	/* Launch a thread */
-	rte_eal_remote_launch(test_enqdeq_callback_thread, NULL,
-				rte_get_next_lcore(-1, 1, 0));
+	TEST_ASSERT_SUCCESS(test_enqdeq_callback_null_cipher(), "Crypto processing failed");
 
-	/* Wait until reader exited. */
-	rte_eal_mp_wait_lcore();
+	/* Wait until callback not called. */
+	while (!deq_cb_called && (j++ < 10))
+		rte_delay_ms(10);
 
 	/* Test with invalid crypto device */
 	TEST_ASSERT_FAIL(rte_cryptodev_remove_deq_callback(
@@ -12833,6 +12903,8 @@ test_deq_callback_setup(void)
 			"qp %u on cryptodev %u",
 			qp_id, ts_params->valid_devs[0]);
 
+	TEST_ASSERT(deq_cb_called == true, "Crypto dequeue callback not called");
+
 	return TEST_SUCCESS;
 }
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.527652919 +0100
+++ 0078-test-crypto-fix-enqueue-dequeue-callback-case.patch	2024-06-25 00:22:13.309188176 +0100
@@ -1 +1 @@
-From 4ad17a1c8fb336a182f2c1b62127d8871d45f804 Mon Sep 17 00:00:00 2001
+From 5cbc25e40f540b3518433c420f947ce3842a8cfe Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4ad17a1c8fb336a182f2c1b62127d8871d45f804 ]
+
@@ -17 +18,0 @@
-Cc: stable@dpdk.org
@@ -26 +27 @@
-index f2d249f6b8..94438c587a 100644
+index b75edb2f2b..96cd9ef7dc 100644
@@ -29 +30 @@
-@@ -199,6 +199,8 @@ post_process_raw_dp_op(void *user_data,	uint32_t index __rte_unused,
+@@ -194,6 +194,8 @@ post_process_raw_dp_op(void *user_data,	uint32_t index __rte_unused,
@@ -36 +37 @@
- int
+ void
@@ -38 +39 @@
-@@ -14671,6 +14673,7 @@ test_enq_callback(uint16_t dev_id, uint16_t qp_id, struct rte_crypto_op **ops,
+@@ -12607,6 +12609,7 @@ test_enq_callback(uint16_t dev_id, uint16_t qp_id, struct rte_crypto_op **ops,
@@ -46 +47 @@
-@@ -14684,21 +14687,58 @@ test_deq_callback(uint16_t dev_id, uint16_t qp_id, struct rte_crypto_op **ops,
+@@ -12620,21 +12623,58 @@ test_deq_callback(uint16_t dev_id, uint16_t qp_id, struct rte_crypto_op **ops,
@@ -112 +113 @@
-@@ -14706,6 +14746,7 @@ static int
+@@ -12642,6 +12682,7 @@ static int
@@ -120 +121 @@
-@@ -14713,6 +14754,19 @@ test_enq_callback_setup(void)
+@@ -12649,6 +12690,19 @@ test_enq_callback_setup(void)
@@ -140 +141 @@
-@@ -14736,6 +14790,7 @@ test_enq_callback_setup(void)
+@@ -12672,6 +12726,7 @@ test_enq_callback_setup(void)
@@ -148 +149 @@
-@@ -14768,12 +14823,11 @@ test_enq_callback_setup(void)
+@@ -12704,12 +12759,11 @@ test_enq_callback_setup(void)
@@ -165 +166 @@
-@@ -14798,6 +14852,8 @@ test_enq_callback_setup(void)
+@@ -12734,6 +12788,8 @@ test_enq_callback_setup(void)
@@ -174 +175 @@
-@@ -14805,6 +14861,7 @@ static int
+@@ -12741,6 +12797,7 @@ static int
@@ -182 +183 @@
-@@ -14812,6 +14869,19 @@ test_deq_callback_setup(void)
+@@ -12748,6 +12805,19 @@ test_deq_callback_setup(void)
@@ -202 +203 @@
-@@ -14835,6 +14905,7 @@ test_deq_callback_setup(void)
+@@ -12771,6 +12841,7 @@ test_deq_callback_setup(void)
@@ -210 +211 @@
-@@ -14867,12 +14938,11 @@ test_deq_callback_setup(void)
+@@ -12803,12 +12874,11 @@ test_deq_callback_setup(void)
@@ -227 +228 @@
-@@ -14897,6 +14967,8 @@ test_deq_callback_setup(void)
+@@ -12833,6 +12903,8 @@ test_deq_callback_setup(void)

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

* patch 'telemetry: lower log level on socket error' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (76 preceding siblings ...)
  2024-06-24 23:59 ` patch 'test/crypto: fix enqueue/dequeue callback case' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'bus/vdev: revert fix devargs in secondary process' " luca.boccassi
  2024-06-24 23:59 ` patch 'doc: fix link to hugepage mapping from Linux guide' " luca.boccassi
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: David Marchand; +Cc: Christian Ehrhardt, Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/1620b6d7177b48d01411482465939166026af214

Thanks.

Luca Boccassi

---
From 1620b6d7177b48d01411482465939166026af214 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 6 Jun 2024 14:26:54 +0200
Subject: [PATCH] telemetry: lower log level on socket error

[ upstream commit 80b7993ba1b45d8aad7c294a7aaf66f4cdf860a5 ]

When starting two DPDK programs using the same DPDK prefix (like for
example OVS and testpmd, both running as primary processes in
--in-memory mode), the first DPDK process of the two spews some error
log when the second starts:

TELEMETRY: Socket write base info to client failed

This is because telemetry init involves trying to connect on existing
sockets to check if it can take over an existing socket file.

On the other hand, this error log provides no helpful information.
Lower this log to debug level.

Fixes: e14bb5f10509 ("telemetry: fix connected clients count")

Reported-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/telemetry/telemetry.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/telemetry/telemetry.c b/lib/telemetry/telemetry.c
index af5da11866..491c4d21dd 100644
--- a/lib/telemetry/telemetry.c
+++ b/lib/telemetry/telemetry.c
@@ -383,7 +383,7 @@ client_handler(void *sock_id)
 			"{\"version\":\"%s\",\"pid\":%d,\"max_output_len\":%d}",
 			telemetry_version, getpid(), MAX_OUTPUT_LEN);
 	if (write(s, info_str, strlen(info_str)) < 0) {
-		TMTY_LOG(ERR, "Socket write base info to client failed");
+		TMTY_LOG(DEBUG, "Socket write base info to client failed");
 		goto exit;
 	}
 
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.574495288 +0100
+++ 0079-telemetry-lower-log-level-on-socket-error.patch	2024-06-25 00:22:13.309188176 +0100
@@ -1 +1 @@
-From 80b7993ba1b45d8aad7c294a7aaf66f4cdf860a5 Mon Sep 17 00:00:00 2001
+From 1620b6d7177b48d01411482465939166026af214 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 80b7993ba1b45d8aad7c294a7aaf66f4cdf860a5 ]
+
@@ -20 +21,0 @@
-Cc: stable@dpdk.org
@@ -30 +31 @@
-index 1663bd8c68..509fae76ec 100644
+index af5da11866..491c4d21dd 100644
@@ -33 +34 @@
-@@ -382,7 +382,7 @@ client_handler(void *sock_id)
+@@ -383,7 +383,7 @@ client_handler(void *sock_id)
@@ -37,2 +38,2 @@
--		TMTY_LOG_LINE(ERR, "Socket write base info to client failed");
-+		TMTY_LOG_LINE(DEBUG, "Socket write base info to client failed");
+-		TMTY_LOG(ERR, "Socket write base info to client failed");
++		TMTY_LOG(DEBUG, "Socket write base info to client failed");

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

* patch 'bus/vdev: revert fix devargs in secondary process' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (77 preceding siblings ...)
  2024-06-24 23:59 ` patch 'telemetry: lower log level on socket error' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  2024-06-24 23:59 ` patch 'doc: fix link to hugepage mapping from Linux guide' " luca.boccassi
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: Mingjin Ye; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/6a3050209505a7b82cc8f20591a54fab5cd86bc2

Thanks.

Luca Boccassi

---
From 6a3050209505a7b82cc8f20591a54fab5cd86bc2 Mon Sep 17 00:00:00 2001
From: Mingjin Ye <mingjinx.ye@intel.com>
Date: Thu, 14 Mar 2024 09:36:28 +0000
Subject: [PATCH] bus/vdev: revert fix devargs in secondary process

[ upstream commit 22ce39b3aadb109cbefabb91aad44c94e8c2a5e6 ]

The ASan tool detected a memory leak in the vdev driver
alloc_devargs. The previous commit was that when inserting
a vdev device, the primary process alloc devargs and the
secondary process looks for devargs. This causes the
device to not be created if the secondary process does
not initialise the vdev device. And, this is not the
root cause.

Therefore the following commit was reverted accordingly.

After restoring this commit, the memory leak still exists.

Bugzilla ID: 1450
Fixes: 6666628362c9 ("bus/vdev: fix devargs in secondary process")

Signed-off-by: Mingjin Ye <mingjinx.ye@intel.com>
---
 drivers/bus/vdev/vdev.c | 21 +--------------------
 1 file changed, 1 insertion(+), 20 deletions(-)

diff --git a/drivers/bus/vdev/vdev.c b/drivers/bus/vdev/vdev.c
index 14cf856237..38d05a9fe9 100644
--- a/drivers/bus/vdev/vdev.c
+++ b/drivers/bus/vdev/vdev.c
@@ -263,22 +263,6 @@ alloc_devargs(const char *name, const char *args)
 	return devargs;
 }
 
-static struct rte_devargs *
-vdev_devargs_lookup(const char *name)
-{
-	struct rte_devargs *devargs;
-	char dev_name[32];
-
-	RTE_EAL_DEVARGS_FOREACH("vdev", devargs) {
-		devargs->bus->parse(devargs->name, &dev_name);
-		if (strcmp(dev_name, name) == 0) {
-			VDEV_LOG(INFO, "devargs matched %s", dev_name);
-			return devargs;
-		}
-	}
-	return NULL;
-}
-
 static int
 insert_vdev(const char *name, const char *args,
 		struct rte_vdev_device **p_dev,
@@ -291,10 +275,7 @@ insert_vdev(const char *name, const char *args,
 	if (name == NULL)
 		return -EINVAL;
 
-	if (rte_eal_process_type() == RTE_PROC_PRIMARY)
-		devargs = alloc_devargs(name, args);
-	else
-		devargs = vdev_devargs_lookup(name);
+	devargs = alloc_devargs(name, args);
 
 	if (!devargs)
 		return -ENOMEM;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.610348157 +0100
+++ 0080-bus-vdev-revert-fix-devargs-in-secondary-process.patch	2024-06-25 00:22:13.313188258 +0100
@@ -1 +1 @@
-From 22ce39b3aadb109cbefabb91aad44c94e8c2a5e6 Mon Sep 17 00:00:00 2001
+From 6a3050209505a7b82cc8f20591a54fab5cd86bc2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 22ce39b3aadb109cbefabb91aad44c94e8c2a5e6 ]
+
@@ -20 +21,0 @@
-Cc: stable@dpdk.org

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

* patch 'doc: fix link to hugepage mapping from Linux guide' has been queued to stable release 22.11.6
  2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
                   ` (78 preceding siblings ...)
  2024-06-24 23:59 ` patch 'bus/vdev: revert fix devargs in secondary process' " luca.boccassi
@ 2024-06-24 23:59 ` luca.boccassi
  79 siblings, 0 replies; 81+ messages in thread
From: luca.boccassi @ 2024-06-24 23:59 UTC (permalink / raw)
  To: David Marchand; +Cc: Alessio Igor Bogani, dpdk stable

Hi,

FYI, your patch has been queued to stable release 22.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/27/24. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/1a055be1a3756b5bc4cc814e939c81985cd59289

Thanks.

Luca Boccassi

---
From 1a055be1a3756b5bc4cc814e939c81985cd59289 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Mon, 17 Jun 2024 16:29:08 +0200
Subject: [PATCH] doc: fix link to hugepage mapping from Linux guide

[ upstream commit a886540e5ab5b6e342b628180a9d9a5379847087 ]

As reported by Alessio, the link to the hugepage mapping page is broken.

Fixes: 979bb5d493fb ("doc: add more instructions for running as non-root")

Reported-by: Alessio Igor Bogani <alessio.bogani@elettra.eu>
Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 .mailmap                             | 1 +
 doc/guides/linux_gsg/enable_func.rst | 3 +--
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/.mailmap b/.mailmap
index 6a7e64e72d..5941400f42 100644
--- a/.mailmap
+++ b/.mailmap
@@ -41,6 +41,7 @@ Aleksandr Miloshenko <a.miloshenko@f5.com>
 Aleksey Baulin <aleksey.baulin@gmail.com>
 Aleksey Katargin <gureedo@gmail.com>
 Ales Musil <amusil@redhat.com>
+Alessio Igor Bogani <alessio.bogani@elettra.eu>
 Alexander Bechikov <asb.tyum@gmail.com>
 Alexander Belyakov <abelyako@gmail.com>
 Alexander Chernavin <achernavin@netgate.com>
diff --git a/doc/guides/linux_gsg/enable_func.rst b/doc/guides/linux_gsg/enable_func.rst
index 2344d97403..5511640cb8 100644
--- a/doc/guides/linux_gsg/enable_func.rst
+++ b/doc/guides/linux_gsg/enable_func.rst
@@ -85,8 +85,7 @@ need to be adjusted in order to ensure normal DPDK operation:
 The above limits can usually be adjusted by editing
 ``/etc/security/limits.conf`` file, and rebooting.
 
-See `Hugepage Mapping <hugepage_mapping>`_
-section to learn how these limits affect EAL.
+See :ref:`Hugepage Mapping <hugepage_mapping>` section to learn how these limits affect EAL.
 
 Device Control
 ~~~~~~~~~~~~~~
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-06-25 00:22:17.646165163 +0100
+++ 0081-doc-fix-link-to-hugepage-mapping-from-Linux-guide.patch	2024-06-25 00:22:13.313188258 +0100
@@ -1 +1 @@
-From a886540e5ab5b6e342b628180a9d9a5379847087 Mon Sep 17 00:00:00 2001
+From 1a055be1a3756b5bc4cc814e939c81985cd59289 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a886540e5ab5b6e342b628180a9d9a5379847087 ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 3a10392e74..f76037213d 100644
+index 6a7e64e72d..5941400f42 100644
@@ -22 +23 @@
-@@ -44,6 +44,7 @@ Aleksandr Miloshenko <a.miloshenko@f5.com>
+@@ -41,6 +41,7 @@ Aleksandr Miloshenko <a.miloshenko@f5.com>

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

end of thread, other threads:[~2024-06-25  0:03 UTC | newest]

Thread overview: 81+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-06-24 23:57 patch 'test: force IOVA mode on PPC64 without huge pages' has been queued to stable release 22.11.6 luca.boccassi
2024-06-24 23:57 ` patch 'bus/pci: fix build with musl 1.2.4 / Alpine 3.19' " luca.boccassi
2024-06-24 23:57 ` patch 'eal/unix: support ZSTD compression for firmware' " luca.boccassi
2024-06-24 23:57 ` patch 'pcapng: add memcpy check' " luca.boccassi
2024-06-24 23:57 ` patch 'net/virtio-user: " luca.boccassi
2024-06-24 23:57 ` patch 'eal/windows: install sched.h file' " luca.boccassi
2024-06-24 23:57 ` patch 'latencystats: fix literal float suffix' " luca.boccassi
2024-06-24 23:57 ` patch 'net/nfp: fix representor port queue release' " luca.boccassi
2024-06-24 23:57 ` patch 'net/bonding: fix failover time of LACP with mode 4' " luca.boccassi
2024-06-24 23:57 ` patch 'net/hns3: fix offload flag of IEEE 1588' " luca.boccassi
2024-06-24 23:57 ` patch 'net/hns3: fix Rx timestamp flag' " luca.boccassi
2024-06-24 23:57 ` patch 'net/hns3: fix double free for Rx/Tx queue' " luca.boccassi
2024-06-24 23:57 ` patch 'net/hns3: fix variable overflow' " luca.boccassi
2024-06-24 23:58 ` patch 'net/hns3: disable SCTP verification tag for RSS hash input' " luca.boccassi
2024-06-24 23:58 ` patch 'net/af_packet: align Rx/Tx structs to cache line' " luca.boccassi
2024-06-24 23:58 ` patch 'doc: fix testpmd ring size command' " luca.boccassi
2024-06-24 23:58 ` patch 'net/af_xdp: fix port ID in Rx mbuf' " luca.boccassi
2024-06-24 23:58 ` patch 'net/af_xdp: count mbuf allocation failures' " luca.boccassi
2024-06-24 23:58 ` patch 'net/af_xdp: fix stats reset' " luca.boccassi
2024-06-24 23:58 ` patch 'net/af_xdp: remove unused local statistic' " luca.boccassi
2024-06-24 23:58 ` patch 'net/tap: fix file descriptor check in isolated flow' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: fix MDIO access for non-zero ports and CL45 PHYs' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: reset link when link never comes back' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: fix fluctuations for 1G Bel Fuse SFP' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: update DMA coherency values' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: disable interrupts during device removal' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: disable RRC for yellow carp devices' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: enable PLL control for fixed PHY modes only' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: fix SFP codes check for DAC cables' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: fix connection for SFP+ active " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: check only minimum speed for " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: fix Tx flow on 30H HW' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: delay AN timeout during KR training' " luca.boccassi
2024-06-24 23:58 ` patch 'net/axgbe: fix linkup in PHY status' " luca.boccassi
2024-06-24 23:58 ` patch 'net/ice: fix check for outer UDP checksum offload' " luca.boccassi
2024-06-24 23:58 ` patch 'app/testpmd: fix outer IP " luca.boccassi
2024-06-24 23:58 ` patch 'net: fix outer UDP checksum in Intel prepare helper' " luca.boccassi
2024-06-24 23:58 ` patch 'net/i40e: fix outer UDP checksum offload for X710' " luca.boccassi
2024-06-24 23:58 ` patch 'net/iavf: remove outer UDP checksum offload for X710 VF' " luca.boccassi
2024-06-24 23:58 ` patch 'app/testpmd: fix lcore ID restriction' " luca.boccassi
2024-06-24 23:58 ` patch 'hash: fix return code description in Doxygen' " luca.boccassi
2024-06-24 23:58 ` patch 'hash: check name when creating a hash' " luca.boccassi
2024-06-24 23:58 ` patch 'mempool: replace GCC pragma with cast' " luca.boccassi
2024-06-24 23:58 ` patch 'vhost: fix build with GCC 13' " luca.boccassi
2024-06-24 23:58 ` patch 'vhost: cleanup resubmit info before inflight setup' " luca.boccassi
2024-06-24 23:58 ` patch 'net/virtio: fix MAC table update' " luca.boccassi
2024-06-24 23:58 ` patch 'baseband/acc: fix memory barrier' " luca.boccassi
2024-06-24 23:58 ` patch 'event/sw: fix warning from useless snprintf' " luca.boccassi
2024-06-24 23:58 ` patch 'eventdev/crypto: fix opaque field handling' " luca.boccassi
2024-06-24 23:58 ` patch 'eal: fix logs for '--lcores'' " luca.boccassi
2024-06-24 23:58 ` patch 'net/fm10k: fix cleanup during init failure' " luca.boccassi
2024-06-24 23:58 ` patch 'net/ixgbe: do not update link status in secondary process' " luca.boccassi
2024-06-24 23:58 ` patch 'net/ixgbe: do not create delayed interrupt handler twice' " luca.boccassi
2024-06-24 23:58 ` patch 'net/e1000/base: fix link power down' " luca.boccassi
2024-06-24 23:58 ` patch 'net/ixgbe/base: revert advertising for X550 2.5G/5G' " luca.boccassi
2024-06-24 23:58 ` patch 'net/ixgbe/base: fix 5G link speed reported on VF' " luca.boccassi
2024-06-24 23:58 ` patch 'net/ixgbe/base: fix PHY ID for X550' " luca.boccassi
2024-06-24 23:58 ` patch 'net/cnxk: fix RSS config' " luca.boccassi
2024-06-24 23:58 ` patch 'net/cnxk: fix outbound security with higher packet burst' " luca.boccassi
2024-06-24 23:58 ` patch 'net/cnxk: fix promiscuous state after MAC change' " luca.boccassi
2024-06-24 23:58 ` patch 'graph: fix ID collisions' " luca.boccassi
2024-06-24 23:58 ` patch 'bpf: disable on 32-bit x86' " luca.boccassi
2024-06-24 23:58 ` patch 'hash: fix RCU reclamation size' " luca.boccassi
2024-06-24 23:58 ` patch 'common/mlx5: fix unsigned/signed mismatch' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5/hws: decrease log level for creation failure' " luca.boccassi
2024-06-24 23:58 ` patch 'common/mlx5: fix PRM structs' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5/hws: fix function comment' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5/hws: fix spinlock release on context open' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5/hws: add template match none flag' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5/hws: fix action template dump' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5: fix indexed pool with invalid index' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5: fix hash Rx queue release in flow sample' " luca.boccassi
2024-06-24 23:58 ` patch 'net/mlx5: fix flow template indirect action failure' " luca.boccassi
2024-06-24 23:59 ` patch 'net/mlx5: break flow resource release loop' " luca.boccassi
2024-06-24 23:59 ` patch 'net/mlx5: fix access to flow template operations' " luca.boccassi
2024-06-24 23:59 ` patch 'net/mlx5: support jump in meter hierarchy' " luca.boccassi
2024-06-24 23:59 ` patch 'net/mlx5: fix crash on counter pool destroy' " luca.boccassi
2024-06-24 23:59 ` patch 'test/crypto: fix enqueue/dequeue callback case' " luca.boccassi
2024-06-24 23:59 ` patch 'telemetry: lower log level on socket error' " luca.boccassi
2024-06-24 23:59 ` patch 'bus/vdev: revert fix devargs in secondary process' " luca.boccassi
2024-06-24 23:59 ` patch 'doc: fix link to hugepage mapping from Linux guide' " 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).