patches for DPDK stable branches
 help / color / mirror / Atom feed
* patch 'dmadev: add missing header include' has been queued to stable release 21.11.1
@ 2022-03-01 10:41 Kevin Traynor
  2022-03-01 10:41 ` patch 'eal: add missing C++ guards' " Kevin Traynor
                   ` (102 more replies)
  0 siblings, 103 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Bruce Richardson, Conor Walsh, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/81c40b01d010e36ea7aca8bac9b3afd8fc9b1638

Thanks.

Kevin

---
From 81c40b01d010e36ea7aca8bac9b3afd8fc9b1638 Mon Sep 17 00:00:00 2001
From: Thomas Monjalon <thomas@monjalon.net>
Date: Tue, 22 Feb 2022 12:26:10 +0100
Subject: [PATCH] dmadev: add missing header include
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit e904fd77d88666f1a4270b1380f2661c9195f012 ]

When checking C++ compatibility of SDK headers,
an error is detected by the compiler:

lib/dmadev/rte_dmadev_pmd.h:95:23: error:
‘RTE_DEV_NAME_MAX_LEN’ undeclared here (not in a function)

The header file rte_dev.h must be included.

Fixes: b36970f2e13e ("dmadev: introduce DMA device library")

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Conor Walsh <conor.walsh@intel.com>
---
 lib/dmadev/rte_dmadev_pmd.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/dmadev/rte_dmadev_pmd.h b/lib/dmadev/rte_dmadev_pmd.h
index 5316ad5b5f..82ab7a8cc7 100644
--- a/lib/dmadev/rte_dmadev_pmd.h
+++ b/lib/dmadev/rte_dmadev_pmd.h
@@ -15,4 +15,6 @@
  */
 
+#include <rte_dev.h>
+
 #include "rte_dmadev.h"
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.506587514 +0000
+++ 0001-dmadev-add-missing-header-include.patch	2022-03-01 10:41:01.232244083 +0000
@@ -1 +1 @@
-From e904fd77d88666f1a4270b1380f2661c9195f012 Mon Sep 17 00:00:00 2001
+From 81c40b01d010e36ea7aca8bac9b3afd8fc9b1638 Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit e904fd77d88666f1a4270b1380f2661c9195f012 ]
+
@@ -18 +19,0 @@
-Cc: stable@dpdk.org


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

* patch 'eal: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'telemetry: " Kevin Traynor
                   ` (101 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From b2f85a808aef62fee67300f7b37307f92183dc0c Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:46 +0000
Subject: [PATCH] eal: add missing C++ guards

[ upstream commit d7e9c02ccad8928b6b804049ced9a3ce6172d81e ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: af75078fece3 ("first public release")
Fixes: 7f3aa0863903 ("eal: introduce bit operations API")
Fixes: 166a743c53fa ("compat: add infrastructure to support symbol versioning")
Fixes: 8f40ee0734c8 ("eal/x86: get hypervisor name")
Fixes: 75583b0d1efd ("eal: add keep alive monitoring")
Fixes: 88701645c98c ("eal: move interrupt type out of igb_uio")
Fixes: f04519d8092e ("lib: add missing include dependencies")
Fixes: f58880682c81 ("trace: implement register API")
Fixes: 428eb983f5f7 ("eal: add OS specific header file")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/eal/include/rte_bitops.h               | 8 ++++++++
 lib/eal/include/rte_branch_prediction.h    | 8 ++++++++
 lib/eal/include/rte_compat.h               | 8 ++++++++
 lib/eal/include/rte_hypervisor.h           | 8 ++++++++
 lib/eal/include/rte_keepalive.h            | 8 ++++++++
 lib/eal/include/rte_pci_dev_feature_defs.h | 8 ++++++++
 lib/eal/include/rte_pci_dev_features.h     | 8 ++++++++
 lib/eal/include/rte_time.h                 | 8 ++++++++
 lib/eal/include/rte_trace_point_register.h | 8 ++++++++
 lib/eal/linux/include/rte_os.h             | 8 ++++++++
 10 files changed, 80 insertions(+)

diff --git a/lib/eal/include/rte_bitops.h b/lib/eal/include/rte_bitops.h
index 141e8ea730..f50dbe4388 100644
--- a/lib/eal/include/rte_bitops.h
+++ b/lib/eal/include/rte_bitops.h
@@ -18,4 +18,8 @@
 #include <rte_compat.h>
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * Get the uint64_t value for a specified bit set.
@@ -272,3 +276,7 @@ rte_bit_relaxed_test_and_clear64(unsigned int nr, volatile uint64_t *addr)
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_BITOPS_H_ */
diff --git a/lib/eal/include/rte_branch_prediction.h b/lib/eal/include/rte_branch_prediction.h
index 854ef9e5dd..0256a9de60 100644
--- a/lib/eal/include/rte_branch_prediction.h
+++ b/lib/eal/include/rte_branch_prediction.h
@@ -11,4 +11,8 @@
 #define _RTE_BRANCH_PREDICTION_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * Check if a branch is likely to be taken.
@@ -39,3 +43,7 @@
 #endif /* unlikely */
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_BRANCH_PREDICTION_H_ */
diff --git a/lib/eal/include/rte_compat.h b/lib/eal/include/rte_compat.h
index 2718612cce..a7dbe23449 100644
--- a/lib/eal/include/rte_compat.h
+++ b/lib/eal/include/rte_compat.h
@@ -7,4 +7,8 @@
 #define _RTE_COMPAT_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #ifndef ALLOW_EXPERIMENTAL_API
 
@@ -44,3 +48,7 @@ __attribute__((section(".text.internal")))
 #endif
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_COMPAT_H_ */
diff --git a/lib/eal/include/rte_hypervisor.h b/lib/eal/include/rte_hypervisor.h
index 5fe719c1d4..1666431ce3 100644
--- a/lib/eal/include/rte_hypervisor.h
+++ b/lib/eal/include/rte_hypervisor.h
@@ -6,4 +6,8 @@
 #define RTE_HYPERVISOR_H
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * @file
@@ -31,3 +35,7 @@ const char *
 rte_hypervisor_get_name(enum rte_hypervisor id);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* RTE_HYPERVISOR_H */
diff --git a/lib/eal/include/rte_keepalive.h b/lib/eal/include/rte_keepalive.h
index bd25508da8..538fb09095 100644
--- a/lib/eal/include/rte_keepalive.h
+++ b/lib/eal/include/rte_keepalive.h
@@ -12,4 +12,8 @@
 #define _KEEPALIVE_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <rte_config.h>
 #include <rte_memory.h>
@@ -140,3 +144,7 @@ rte_keepalive_register_relay_callback(struct rte_keepalive *keepcfg,
 	void *data);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _KEEPALIVE_H_ */
diff --git a/lib/eal/include/rte_pci_dev_feature_defs.h b/lib/eal/include/rte_pci_dev_feature_defs.h
index e12c22081f..c5bb631286 100644
--- a/lib/eal/include/rte_pci_dev_feature_defs.h
+++ b/lib/eal/include/rte_pci_dev_feature_defs.h
@@ -6,4 +6,8 @@
 #define _RTE_PCI_DEV_DEFS_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /* interrupt mode */
 enum rte_intr_mode {
@@ -14,3 +18,7 @@ enum rte_intr_mode {
 };
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_PCI_DEV_DEFS_H_ */
diff --git a/lib/eal/include/rte_pci_dev_features.h b/lib/eal/include/rte_pci_dev_features.h
index 6104123d27..ee6e10590c 100644
--- a/lib/eal/include/rte_pci_dev_features.h
+++ b/lib/eal/include/rte_pci_dev_features.h
@@ -6,4 +6,8 @@
 #define _RTE_PCI_DEV_FEATURES_H
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <rte_pci_dev_feature_defs.h>
 
@@ -13,3 +17,7 @@
 #define RTE_INTR_MODE_MSIX_NAME "msix"
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif
diff --git a/lib/eal/include/rte_time.h b/lib/eal/include/rte_time.h
index 5ad7c8841a..ec25f7b93d 100644
--- a/lib/eal/include/rte_time.h
+++ b/lib/eal/include/rte_time.h
@@ -6,4 +6,8 @@
 #define _RTE_TIME_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <stdint.h>
 #include <time.h>
@@ -99,3 +103,7 @@ rte_ns_to_timespec(uint64_t nsec)
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_TIME_H_ */
diff --git a/lib/eal/include/rte_trace_point_register.h b/lib/eal/include/rte_trace_point_register.h
index 4f5c86552d..2e61439940 100644
--- a/lib/eal/include/rte_trace_point_register.h
+++ b/lib/eal/include/rte_trace_point_register.h
@@ -6,4 +6,8 @@
 #define _RTE_TRACE_POINT_REGISTER_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #ifdef _RTE_TRACE_POINT_H_
 #error for registration, include this file first before <rte_trace_point.h>
@@ -43,3 +47,7 @@ do { \
 } while (0)
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_TRACE_POINT_REGISTER_H_ */
diff --git a/lib/eal/linux/include/rte_os.h b/lib/eal/linux/include/rte_os.h
index 35c07c70cb..c72bf5b7e6 100644
--- a/lib/eal/linux/include/rte_os.h
+++ b/lib/eal/linux/include/rte_os.h
@@ -6,4 +6,8 @@
 #define _RTE_OS_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * This header should contain any definition
@@ -43,3 +47,7 @@ typedef cpu_set_t rte_cpuset_t;
 #endif
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_OS_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.527664557 +0000
+++ 0002-eal-add-missing-C-guards.patch	2022-03-01 10:41:01.235244084 +0000
@@ -1 +1 @@
-From d7e9c02ccad8928b6b804049ced9a3ce6172d81e Mon Sep 17 00:00:00 2001
+From b2f85a808aef62fee67300f7b37307f92183dc0c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d7e9c02ccad8928b6b804049ced9a3ce6172d81e ]
+
@@ -18 +19,0 @@
-Cc: stable@dpdk.org
@@ -79 +80 @@
-index 9556bbf4d0..fc9fbaaab2 100644
+index 2718612cce..a7dbe23449 100644
@@ -91 +92 @@
-@@ -47,3 +51,7 @@ __attribute__((section(".text.internal")))
+@@ -44,3 +48,7 @@ __attribute__((section(".text.internal")))


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

* patch 'telemetry: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
  2022-03-01 10:41 ` patch 'eal: add missing C++ guards' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'ethdev: " Kevin Traynor
                   ` (100 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e7291176c2cc7a97336c013499a25e3c135d5685 Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:47 +0000
Subject: [PATCH] telemetry: add missing C++ guards

[ upstream commit cf8e6263647d217ad5c9bdfa2c3275f71bd19f64 ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: 8877ac688b52 ("telemetry: introduce infrastructure")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/telemetry/rte_telemetry.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/telemetry/rte_telemetry.h b/lib/telemetry/rte_telemetry.h
index 7bca8a9a49..3372b32f38 100644
--- a/lib/telemetry/rte_telemetry.h
+++ b/lib/telemetry/rte_telemetry.h
@@ -10,4 +10,8 @@
 #define _RTE_TELEMETRY_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /** Maximum length for string used in object. */
 #define RTE_TEL_MAX_STRING_LEN 128
@@ -295,3 +299,7 @@ void
 rte_tel_data_free(struct rte_tel_data *data);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.552379950 +0000
+++ 0003-telemetry-add-missing-C-guards.patch	2022-03-01 10:41:01.236244084 +0000
@@ -1 +1 @@
-From cf8e6263647d217ad5c9bdfa2c3275f71bd19f64 Mon Sep 17 00:00:00 2001
+From e7291176c2cc7a97336c013499a25e3c135d5685 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit cf8e6263647d217ad5c9bdfa2c3275f71bd19f64 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'ethdev: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
  2022-03-01 10:41 ` patch 'eal: add missing C++ guards' " Kevin Traynor
  2022-03-01 10:41 ` patch 'telemetry: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'metrics: " Kevin Traynor
                   ` (99 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From b99a45df054af0cb5b847e7d9b87bf95c2e345d4 Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:48 +0000
Subject: [PATCH] ethdev: add missing C++ guards

[ upstream commit dbf9fc1dac70b64dd1ed9a3ffd6997838fbf170e ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: 7a3f27cbf59b ("ethdev: add access to specific device info")
Fixes: dcd5c8112bc3 ("ethdev: add PCI driver helpers")
Fixes: 7f0a669e7b04 ("ethdev: add allocation helper for virtual drivers")
Fixes: 7a3357205755 ("lib: remove C++ include guard from private headers")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/ethdev/ethdev_driver.h | 8 ++++++++
 lib/ethdev/ethdev_pci.h    | 8 ++++++++
 lib/ethdev/ethdev_vdev.h   | 8 ++++++++
 lib/ethdev/rte_dev_info.h  | 8 ++++++++
 4 files changed, 32 insertions(+)

diff --git a/lib/ethdev/ethdev_driver.h b/lib/ethdev/ethdev_driver.h
index 0dac55f9c8..2822fd8c72 100644
--- a/lib/ethdev/ethdev_driver.h
+++ b/lib/ethdev/ethdev_driver.h
@@ -6,4 +6,8 @@
 #define _RTE_ETHDEV_DRIVER_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * @file
@@ -1769,3 +1773,7 @@ struct rte_eth_tunnel_filter_conf {
 };
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ETHDEV_DRIVER_H_ */
diff --git a/lib/ethdev/ethdev_pci.h b/lib/ethdev/ethdev_pci.h
index 71aa4b2e98..6130bcbd1f 100644
--- a/lib/ethdev/ethdev_pci.h
+++ b/lib/ethdev/ethdev_pci.h
@@ -7,4 +7,8 @@
 #define _RTE_ETHDEV_PCI_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <rte_malloc.h>
 #include <rte_pci.h>
@@ -172,3 +176,7 @@ rte_eth_dev_pci_generic_remove(struct rte_pci_device *pci_dev,
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ETHDEV_PCI_H_ */
diff --git a/lib/ethdev/ethdev_vdev.h b/lib/ethdev/ethdev_vdev.h
index 2b49e9665b..f5f536ce64 100644
--- a/lib/ethdev/ethdev_vdev.h
+++ b/lib/ethdev/ethdev_vdev.h
@@ -7,4 +7,8 @@
 #define _RTE_ETHDEV_VDEV_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <rte_config.h>
 #include <rte_malloc.h>
@@ -53,3 +57,7 @@ rte_eth_vdev_allocate(struct rte_vdev_device *dev, size_t private_data_size)
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ETHDEV_VDEV_H_ */
diff --git a/lib/ethdev/rte_dev_info.h b/lib/ethdev/rte_dev_info.h
index cb2fe0ae97..67cf0ae526 100644
--- a/lib/ethdev/rte_dev_info.h
+++ b/lib/ethdev/rte_dev_info.h
@@ -6,4 +6,8 @@
 #define _RTE_DEV_INFO_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <stdint.h>
 
@@ -49,3 +53,7 @@ struct rte_eth_dev_module_info {
 #define RTE_ETH_MODULE_SFF_8436_MAX_LEN     640
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_DEV_INFO_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.574860994 +0000
+++ 0004-ethdev-add-missing-C-guards.patch	2022-03-01 10:41:01.241244085 +0000
@@ -1 +1 @@
-From dbf9fc1dac70b64dd1ed9a3ffd6997838fbf170e Mon Sep 17 00:00:00 2001
+From b99a45df054af0cb5b847e7d9b87bf95c2e345d4 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit dbf9fc1dac70b64dd1ed9a3ffd6997838fbf170e ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -26 +27 @@
-index 6d697a879a..5ec00e533e 100644
+index 0dac55f9c8..2822fd8c72 100644
@@ -38 +39 @@
-@@ -1882,3 +1886,7 @@ struct rte_eth_tunnel_filter_conf {
+@@ -1769,3 +1773,7 @@ struct rte_eth_tunnel_filter_conf {


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

* patch 'metrics: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (2 preceding siblings ...)
  2022-03-01 10:41 ` patch 'ethdev: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'acl: " Kevin Traynor
                   ` (98 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/447210e07c60732669a14fe09021ae39deb191ae

Thanks.

Kevin

---
From 447210e07c60732669a14fe09021ae39deb191ae Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:49 +0000
Subject: [PATCH] metrics: add missing C++ guards

[ upstream commit 4e90b3a3d6cc476ee1a39be7368675c31a28b093 ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: c5b7197f662e ("telemetry: move some functions to metrics library")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/metrics/rte_metrics_telemetry.h | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/lib/metrics/rte_metrics_telemetry.h b/lib/metrics/rte_metrics_telemetry.h
index 2b6eb1ccc8..09b14d9336 100644
--- a/lib/metrics/rte_metrics_telemetry.h
+++ b/lib/metrics/rte_metrics_telemetry.h
@@ -14,4 +14,7 @@
 #define _RTE_METRICS_TELEMETRY_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
 
 enum rte_telemetry_stats_type {
@@ -61,3 +64,7 @@ int32_t
 rte_metrics_tel_extract_data(struct telemetry_encode_param *ep, json_t *data);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.598034067 +0000
+++ 0005-metrics-add-missing-C-guards.patch	2022-03-01 10:41:01.241244085 +0000
@@ -1 +1 @@
-From 4e90b3a3d6cc476ee1a39be7368675c31a28b093 Mon Sep 17 00:00:00 2001
+From 447210e07c60732669a14fe09021ae39deb191ae Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4e90b3a3d6cc476ee1a39be7368675c31a28b093 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'acl: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (3 preceding siblings ...)
  2022-03-01 10:41 ` patch 'metrics: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'compressdev: " Kevin Traynor
                   ` (97 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 6fca954338f7eec8f5bd3bb49a1327dcd563b632 Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:50 +0000
Subject: [PATCH] acl: add missing C++ guards

[ upstream commit bfec92e3821f57200f7e956f39745303f995531d ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: dc276b5780c2 ("acl: new library")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/acl/rte_acl_osdep.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/acl/rte_acl_osdep.h b/lib/acl/rte_acl_osdep.h
index b2c262dee7..3c1dc402ca 100644
--- a/lib/acl/rte_acl_osdep.h
+++ b/lib/acl/rte_acl_osdep.h
@@ -6,4 +6,8 @@
 #define _RTE_ACL_OSDEP_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * @file
@@ -46,3 +50,7 @@
 #include <rte_debug.h>
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_ACL_OSDEP_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.619410010 +0000
+++ 0006-acl-add-missing-C-guards.patch	2022-03-01 10:41:01.242244085 +0000
@@ -1 +1 @@
-From bfec92e3821f57200f7e956f39745303f995531d Mon Sep 17 00:00:00 2001
+From 6fca954338f7eec8f5bd3bb49a1327dcd563b632 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit bfec92e3821f57200f7e956f39745303f995531d ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'compressdev: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (4 preceding siblings ...)
  2022-03-01 10:41 ` patch 'acl: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'eventdev: " Kevin Traynor
                   ` (96 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/3d1746c9ac4bc2e58eb14e34a882506d659e909e

Thanks.

Kevin

---
From 3d1746c9ac4bc2e58eb14e34a882506d659e909e Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:51 +0000
Subject: [PATCH] compressdev: add missing C++ guards

[ upstream commit ef64c2f311f66bf8fe563bf7777e5dba72fc57e6 ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: ed7dd94f7f66 ("compressdev: add basic device management")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/compressdev/rte_compressdev_internal.h | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/lib/compressdev/rte_compressdev_internal.h b/lib/compressdev/rte_compressdev_internal.h
index 22ceac66e2..888c8f5c5c 100644
--- a/lib/compressdev/rte_compressdev_internal.h
+++ b/lib/compressdev/rte_compressdev_internal.h
@@ -6,4 +6,8 @@
 #define _RTE_COMPRESSDEV_INTERNAL_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /* rte_compressdev_internal.h
  * This file holds Compressdev private data structures.
@@ -112,3 +116,8 @@ struct rte_compressdev_data {
 	/**< PMD-specific private data */
 } __rte_cache_aligned;
+
+#ifdef __cplusplus
+}
+#endif
+
 #endif
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.641824917 +0000
+++ 0007-compressdev-add-missing-C-guards.patch	2022-03-01 10:41:01.242244085 +0000
@@ -1 +1 @@
-From ef64c2f311f66bf8fe563bf7777e5dba72fc57e6 Mon Sep 17 00:00:00 2001
+From 3d1746c9ac4bc2e58eb14e34a882506d659e909e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ef64c2f311f66bf8fe563bf7777e5dba72fc57e6 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'eventdev: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (5 preceding siblings ...)
  2022-03-01 10:41 ` patch 'compressdev: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'kni: " Kevin Traynor
                   ` (95 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e4dbb6873a841365bd0002da3e0825dccdba3b97 Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:52 +0000
Subject: [PATCH] eventdev: add missing C++ guards

[ upstream commit 2c552933ba453984c26262136150d75235f6aabe ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: dc39e2f359b5 ("eventdev: add ring structure for events")
Fixes: 7a3357205755 ("lib: remove C++ include guard from private headers")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/eventdev/eventdev_pmd.h      | 4 ++++
 lib/eventdev/eventdev_pmd_pci.h  | 8 ++++++++
 lib/eventdev/eventdev_pmd_vdev.h | 8 ++++++++
 lib/eventdev/rte_event_ring.h    | 9 +++++++++
 4 files changed, 29 insertions(+)

diff --git a/lib/eventdev/eventdev_pmd.h b/lib/eventdev/eventdev_pmd.h
index d0b0c00a60..ce469d47a6 100644
--- a/lib/eventdev/eventdev_pmd.h
+++ b/lib/eventdev/eventdev_pmd.h
@@ -6,4 +6,8 @@
 #define _RTE_EVENTDEV_PMD_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /** @file
  * RTE Event PMD APIs
diff --git a/lib/eventdev/eventdev_pmd_pci.h b/lib/eventdev/eventdev_pmd_pci.h
index 499852db16..24b56faaa9 100644
--- a/lib/eventdev/eventdev_pmd_pci.h
+++ b/lib/eventdev/eventdev_pmd_pci.h
@@ -6,4 +6,8 @@
 #define _RTE_EVENTDEV_PMD_PCI_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /** @file
  * RTE Eventdev PCI PMD APIs
@@ -151,3 +155,7 @@ rte_event_pmd_pci_remove(struct rte_pci_device *pci_dev,
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_EVENTDEV_PMD_PCI_H_ */
diff --git a/lib/eventdev/eventdev_pmd_vdev.h b/lib/eventdev/eventdev_pmd_vdev.h
index d9ee7277dd..77904910a2 100644
--- a/lib/eventdev/eventdev_pmd_vdev.h
+++ b/lib/eventdev/eventdev_pmd_vdev.h
@@ -6,4 +6,8 @@
 #define _RTE_EVENTDEV_PMD_VDEV_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /** @file
  * RTE Eventdev VDEV PMD APIs
@@ -100,3 +104,7 @@ rte_event_pmd_vdev_uninit(const char *name)
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_EVENTDEV_PMD_VDEV_H_ */
diff --git a/lib/eventdev/rte_event_ring.h b/lib/eventdev/rte_event_ring.h
index c0861b0ec2..0b9aefb000 100644
--- a/lib/eventdev/rte_event_ring.h
+++ b/lib/eventdev/rte_event_ring.h
@@ -15,4 +15,8 @@
 #define _RTE_EVENT_RING_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <stdint.h>
 
@@ -267,3 +271,8 @@ rte_event_ring_get_capacity(const struct rte_event_ring *r)
 	return rte_ring_get_capacity(&r->r);
 }
+
+#ifdef __cplusplus
+}
+#endif
+
 #endif
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.663458435 +0000
+++ 0008-eventdev-add-missing-C-guards.patch	2022-03-01 10:41:01.244244086 +0000
@@ -1 +1 @@
-From 2c552933ba453984c26262136150d75235f6aabe Mon Sep 17 00:00:00 2001
+From e4dbb6873a841365bd0002da3e0825dccdba3b97 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 2c552933ba453984c26262136150d75235f6aabe ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -17 +18 @@
- lib/eventdev/eventdev_pmd.h      | 8 ++++++++
+ lib/eventdev/eventdev_pmd.h      | 4 ++++
@@ -21 +22 @@
- 4 files changed, 33 insertions(+)
+ 4 files changed, 29 insertions(+)
@@ -24 +25 @@
-index b05ffce549..ce469d47a6 100644
+index d0b0c00a60..ce469d47a6 100644
@@ -36,8 +36,0 @@
-@@ -1367,3 +1371,7 @@ event_dev_fp_ops_set(struct rte_event_fp_ops *fp_ops,
- 		     const struct rte_eventdev *dev);
- 
-+#ifdef __cplusplus
-+}
-+#endif
-+
- #endif /* _RTE_EVENTDEV_PMD_H_ */
@@ -87 +80 @@
-index 0a54f7fde2..0101cc0aa2 100644
+index c0861b0ec2..0b9aefb000 100644
@@ -99 +92 @@
-@@ -265,3 +269,8 @@ rte_event_ring_get_capacity(const struct rte_event_ring *r)
+@@ -267,3 +271,8 @@ rte_event_ring_get_capacity(const struct rte_event_ring *r)


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

* patch 'kni: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (6 preceding siblings ...)
  2022-03-01 10:41 ` patch 'eventdev: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'vhost: " Kevin Traynor
                   ` (94 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From fb37e2b3ae1f559296ea780e340a3599a65e9b9f Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:53 +0000
Subject: [PATCH] kni: add missing C++ guards

[ upstream commit e90df35c7a0328f7ad5bfc4d2d9968ff774d7f77 ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: 3fc5ca2f6352 ("kni: initial import")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/kni/rte_kni_common.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/kni/rte_kni_common.h b/lib/kni/rte_kni_common.h
index b547ea5501..8d3ee0fa4f 100644
--- a/lib/kni/rte_kni_common.h
+++ b/lib/kni/rte_kni_common.h
@@ -7,4 +7,8 @@
 #define _RTE_KNI_COMMON_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #ifdef __KERNEL__
 #include <linux/if.h>
@@ -137,3 +141,7 @@ struct rte_kni_device_info {
 #define RTE_KNI_IOCTL_RELEASE _IOWR(0, 3, struct rte_kni_device_info)
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_KNI_COMMON_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.687024700 +0000
+++ 0009-kni-add-missing-C-guards.patch	2022-03-01 10:41:01.245244086 +0000
@@ -1 +1 @@
-From e90df35c7a0328f7ad5bfc4d2d9968ff774d7f77 Mon Sep 17 00:00:00 2001
+From fb37e2b3ae1f559296ea780e340a3599a65e9b9f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e90df35c7a0328f7ad5bfc4d2d9968ff774d7f77 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'vhost: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (7 preceding siblings ...)
  2022-03-01 10:41 ` patch 'kni: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'bpf: " Kevin Traynor
                   ` (93 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Chenbo Xia, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/362921a8e3e57d7c0175bd39932c42c639154362

Thanks.

Kevin

---
From 362921a8e3e57d7c0175bd39932c42c639154362 Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:54 +0000
Subject: [PATCH] vhost: add missing C++ guards

[ upstream commit cedca4084a61e85323800022974c1fde5027cbb4 ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: d7280c9fffcb ("vhost: support selective datapath")
Fixes: 78639d54563a ("vhost: introduce async enqueue registration API")
Fixes: 3bb595ecd682 ("vhost/crypto: add request handler")
Fixes: 94c16e89d779 ("vhost: mark vDPA driver API as internal")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/vhost/rte_vdpa.h         | 9 +++++++++
 lib/vhost/rte_vhost_async.h  | 8 ++++++++
 lib/vhost/rte_vhost_crypto.h | 8 ++++++++
 lib/vhost/vdpa_driver.h      | 8 ++++++++
 4 files changed, 33 insertions(+)

diff --git a/lib/vhost/rte_vdpa.h b/lib/vhost/rte_vdpa.h
index 1437f400bf..6ac85d1bbf 100644
--- a/lib/vhost/rte_vdpa.h
+++ b/lib/vhost/rte_vdpa.h
@@ -6,4 +6,8 @@
 #define _RTE_VDPA_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * @file
@@ -184,3 +188,8 @@ rte_vdpa_get_stats(struct rte_vdpa_device *dev, uint16_t qid,
 int
 rte_vdpa_reset_stats(struct rte_vdpa_device *dev, uint16_t qid);
+
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_VDPA_H_ */
diff --git a/lib/vhost/rte_vhost_async.h b/lib/vhost/rte_vhost_async.h
index a87ea6ba37..d20152ca7a 100644
--- a/lib/vhost/rte_vhost_async.h
+++ b/lib/vhost/rte_vhost_async.h
@@ -6,4 +6,8 @@
 #define _RTE_VHOST_ASYNC_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include "rte_vhost.h"
 
@@ -243,3 +247,7 @@ uint16_t rte_vhost_clear_queue_thread_unsafe(int vid, uint16_t queue_id,
 		struct rte_mbuf **pkts, uint16_t count);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _RTE_VHOST_ASYNC_H_ */
diff --git a/lib/vhost/rte_vhost_crypto.h b/lib/vhost/rte_vhost_crypto.h
index f54d731139..b49e389579 100644
--- a/lib/vhost/rte_vhost_crypto.h
+++ b/lib/vhost/rte_vhost_crypto.h
@@ -6,4 +6,8 @@
 #define _VHOST_CRYPTO_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <stdint.h>
 
@@ -133,3 +137,7 @@ rte_vhost_crypto_finalize_requests(struct rte_crypto_op **ops,
 		uint16_t nb_ops, int *callfds, uint16_t *nb_callfds);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /**< _VHOST_CRYPTO_H_ */
diff --git a/lib/vhost/vdpa_driver.h b/lib/vhost/vdpa_driver.h
index fc2d6acedd..7ba9e28e57 100644
--- a/lib/vhost/vdpa_driver.h
+++ b/lib/vhost/vdpa_driver.h
@@ -6,4 +6,8 @@
 #define _VDPA_DRIVER_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #include <stdbool.h>
 
@@ -142,3 +146,7 @@ int
 rte_vdpa_relay_vring_used(int vid, uint16_t qid, void *vring_m);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _VDPA_DRIVER_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.708301988 +0000
+++ 0010-vhost-add-missing-C-guards.patch	2022-03-01 10:41:01.246244086 +0000
@@ -1 +1 @@
-From cedca4084a61e85323800022974c1fde5027cbb4 Mon Sep 17 00:00:00 2001
+From 362921a8e3e57d7c0175bd39932c42c639154362 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit cedca4084a61e85323800022974c1fde5027cbb4 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -49 +50 @@
-index 838c4778cc..f1293c6a9d 100644
+index a87ea6ba37..d20152ca7a 100644
@@ -59 +60 @@
- #include <stdint.h>
+ #include "rte_vhost.h"
@@ -61,2 +62,2 @@
-@@ -184,3 +188,7 @@ __rte_experimental
- int rte_vhost_async_dma_configure(int16_t dma_id, uint16_t vchan_id);
+@@ -243,3 +247,7 @@ uint16_t rte_vhost_clear_queue_thread_unsafe(int vid, uint16_t queue_id,
+ 		struct rte_mbuf **pkts, uint16_t count);
@@ -91 +92 @@
-index fddbd50652..88138be34a 100644
+index fc2d6acedd..7ba9e28e57 100644
@@ -103 +104 @@
-@@ -145,3 +149,7 @@ int
+@@ -142,3 +146,7 @@ int


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

* patch 'bpf: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (8 preceding siblings ...)
  2022-03-01 10:41 ` patch 'vhost: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'cryptodev: " Kevin Traynor
                   ` (92 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From c02f5bcfe98001875650f36c9980209044a46e49 Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:55 +0000
Subject: [PATCH] bpf: add missing C++ guards

[ upstream commit 5a6632d15582d70a8c8952071361b61c1e08cc7f ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: 7a3357205755 ("lib: remove C++ include guard from private headers")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/bpf/bpf_def.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/bpf/bpf_def.h b/lib/bpf/bpf_def.h
index fa9125307e..f08cd9106b 100644
--- a/lib/bpf/bpf_def.h
+++ b/lib/bpf/bpf_def.h
@@ -8,4 +8,8 @@
 #define _RTE_BPF_DEF_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /**
  * @file
@@ -141,3 +145,7 @@ struct ebpf_insn {
 #define	EBPF_FUNC_MAX_ARGS	(EBPF_REG_6 - EBPF_REG_1)
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* RTE_BPF_DEF_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.730579971 +0000
+++ 0011-bpf-add-missing-C-guards.patch	2022-03-01 10:41:01.247244086 +0000
@@ -1 +1 @@
-From 5a6632d15582d70a8c8952071361b61c1e08cc7f Mon Sep 17 00:00:00 2001
+From c02f5bcfe98001875650f36c9980209044a46e49 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 5a6632d15582d70a8c8952071361b61c1e08cc7f ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'cryptodev: add missing C++ guards' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (9 preceding siblings ...)
  2022-03-01 10:41 ` patch 'bpf: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'ethdev: fix cast for C++ compatibility' " Kevin Traynor
                   ` (91 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Bruce Richardson, Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 5d75eb0924538ed6b309e134bb313260ad88615b Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Wed, 16 Feb 2022 15:14:56 +0000
Subject: [PATCH] cryptodev: add missing C++ guards

[ upstream commit a43e3969513cbc0bc0ae83e7b474f6e335486538 ]

Some public header files were missing 'extern "C"' C++ guards,
and couldn't be used by C++ applications. Add the missing guards.

Fixes: 7a3357205755 ("lib: remove C++ include guard from private headers")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/cryptodev/cryptodev_pmd.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/lib/cryptodev/cryptodev_pmd.h b/lib/cryptodev/cryptodev_pmd.h
index b9146f652c..56e659b474 100644
--- a/lib/cryptodev/cryptodev_pmd.h
+++ b/lib/cryptodev/cryptodev_pmd.h
@@ -6,4 +6,8 @@
 #define _CRYPTODEV_PMD_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /** @file
  * RTE Crypto PMD APIs
@@ -641,3 +645,7 @@ set_asym_session_private_data(struct rte_cryptodev_asym_session *sess,
 }
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _CRYPTODEV_PMD_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.751578005 +0000
+++ 0012-cryptodev-add-missing-C-guards.patch	2022-03-01 10:41:01.248244086 +0000
@@ -1 +1 @@
-From a43e3969513cbc0bc0ae83e7b474f6e335486538 Mon Sep 17 00:00:00 2001
+From 5d75eb0924538ed6b309e134bb313260ad88615b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a43e3969513cbc0bc0ae83e7b474f6e335486538 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 8bbb9caeae..2b1ce2da2d 100644
+index b9146f652c..56e659b474 100644
@@ -32,2 +33,2 @@
-@@ -637,3 +641,7 @@ RTE_STD_C11 struct rte_cryptodev_asym_session {
- };
+@@ -641,3 +645,7 @@ set_asym_session_private_data(struct rte_cryptodev_asym_session *sess,
+ }


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

* patch 'ethdev: fix cast for C++ compatibility' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (10 preceding siblings ...)
  2022-03-01 10:41 ` patch 'cryptodev: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'dma/hisilicon: use common PCI device naming' " Kevin Traynor
                   ` (90 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: Tyler Retzlaff, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/56d6e5b091b3dff4c9b1471fe2310b7e60dfebfa

Thanks.

Kevin

---
From 56d6e5b091b3dff4c9b1471fe2310b7e60dfebfa Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Tue, 15 Feb 2022 17:30:27 +0000
Subject: [PATCH] ethdev: fix cast for C++ compatibility

[ upstream commit 5ed2a2d4fdb696727b614f881f263851fad8832c ]

C++ does not allow implicit conversion to/from void*,
so we need an explicit cast to allow the driver SDK header
to be included from C++ code.

Fixes: e489007a411c ("ethdev: add generic create/destroy ethdev APIs")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/ethdev/ethdev_pci.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/ethdev/ethdev_pci.h b/lib/ethdev/ethdev_pci.h
index 6130bcbd1f..0549842709 100644
--- a/lib/ethdev/ethdev_pci.h
+++ b/lib/ethdev/ethdev_pci.h
@@ -51,6 +51,7 @@ rte_eth_copy_pci_info(struct rte_eth_dev *eth_dev,
 
 static inline int
-eth_dev_pci_specific_init(struct rte_eth_dev *eth_dev, void *bus_device) {
-	struct rte_pci_device *pci_dev = bus_device;
+eth_dev_pci_specific_init(struct rte_eth_dev *eth_dev, void *bus_device)
+{
+	struct rte_pci_device *pci_dev = (struct rte_pci_device *)bus_device;
 
 	if (!pci_dev)
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.774394531 +0000
+++ 0013-ethdev-fix-cast-for-C-compatibility.patch	2022-03-01 10:41:01.248244086 +0000
@@ -1 +1 @@
-From 5ed2a2d4fdb696727b614f881f263851fad8832c Mon Sep 17 00:00:00 2001
+From 56d6e5b091b3dff4c9b1471fe2310b7e60dfebfa Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 5ed2a2d4fdb696727b614f881f263851fad8832c ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org


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

* patch 'dma/hisilicon: use common PCI device naming' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (11 preceding siblings ...)
  2022-03-01 10:41 ` patch 'ethdev: fix cast for C++ compatibility' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'test/dma: fix missing checks for device capacity' " Kevin Traynor
                   ` (89 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Chengwen Feng; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From c6aea57d9987b032f47ddb8ffbd4d848db28804b Mon Sep 17 00:00:00 2001
From: Chengwen Feng <fengchengwen@huawei.com>
Date: Thu, 17 Feb 2022 10:59:11 +0800
Subject: [PATCH] dma/hisilicon: use common PCI device naming

[ upstream commit 033904450b1d52fd3d09e2bb53e529e3ba0ecf77 ]

For DMA device 0000:7d:0.0, the original generated dmadev name starts
with the "7d:0.0", which is not expected.
This patch uses rte_pci_device_name API to generates the dmadev name.

Signed-off-by: Chengwen Feng <fengchengwen@huawei.com>
---
 doc/guides/dmadevs/hisilicon.rst    |  4 ++--
 drivers/dma/hisilicon/hisi_dmadev.c | 23 +++++++----------------
 2 files changed, 9 insertions(+), 18 deletions(-)

diff --git a/doc/guides/dmadevs/hisilicon.rst b/doc/guides/dmadevs/hisilicon.rst
index 191e56f2f7..974bc49376 100644
--- a/doc/guides/dmadevs/hisilicon.rst
+++ b/doc/guides/dmadevs/hisilicon.rst
@@ -30,6 +30,6 @@ which can be accessed using API from the ``rte_dmadev`` library.
 The name of the ``dmadev`` created is like "B:D.F-chX", e.g. DMA 0000:7b:00.0
 will create four ``dmadev``,
-the 1st ``dmadev`` name is "7b:00.0-ch0",
-and the 2nd ``dmadev`` name is "7b:00.0-ch1".
+the 1st ``dmadev`` name is "0000:7b:00.0-ch0",
+and the 2nd ``dmadev`` name is "0000:7b:00.0-ch1".
 
 Device Configuration
diff --git a/drivers/dma/hisilicon/hisi_dmadev.c b/drivers/dma/hisilicon/hisi_dmadev.c
index 05066b4d0e..ff80622ec0 100644
--- a/drivers/dma/hisilicon/hisi_dmadev.c
+++ b/drivers/dma/hisilicon/hisi_dmadev.c
@@ -732,22 +732,13 @@ hisi_dma_burst_capacity(const void *dev_private, uint16_t vchan)
 }
 
-static void
-hisi_dma_gen_pci_device_name(const struct rte_pci_device *pci_dev,
-			     char *name, size_t size)
-{
-	memset(name, 0, size);
-	(void)snprintf(name, size, "%x:%x.%x",
-		 pci_dev->addr.bus, pci_dev->addr.devid,
-		 pci_dev->addr.function);
-}
-
 static void
 hisi_dma_gen_dev_name(const struct rte_pci_device *pci_dev,
-		      uint8_t queue_id, char *name, size_t size)
+		      uint8_t queue_id, char *dev_name, size_t size)
 {
-	memset(name, 0, size);
-	(void)snprintf(name, size, "%x:%x.%x-ch%u",
-		 pci_dev->addr.bus, pci_dev->addr.devid,
-		 pci_dev->addr.function, queue_id);
+	char name[RTE_DEV_NAME_MAX_LEN] = { 0 };
+
+	memset(dev_name, 0, size);
+	rte_pci_device_name(&pci_dev->addr, name, sizeof(name));
+	(void)snprintf(dev_name, size, "%s-ch%u", name, queue_id);
 }
 
@@ -865,5 +856,5 @@ hisi_dma_probe(struct rte_pci_driver *pci_drv __rte_unused,
 	int ret;
 
-	hisi_dma_gen_pci_device_name(pci_dev, name, sizeof(name));
+	rte_pci_device_name(&pci_dev->addr, name, sizeof(name));
 
 	if (pci_dev->mem_resource[2].addr == NULL) {
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.795372577 +0000
+++ 0014-dma-hisilicon-use-common-PCI-device-naming.patch	2022-03-01 10:41:01.249244087 +0000
@@ -1 +1 @@
-From 033904450b1d52fd3d09e2bb53e529e3ba0ecf77 Mon Sep 17 00:00:00 2001
+From c6aea57d9987b032f47ddb8ffbd4d848db28804b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 033904450b1d52fd3d09e2bb53e529e3ba0ecf77 ]
+
@@ -10,2 +11,0 @@
-Cc: stable@dpdk.org
-
@@ -19 +19 @@
-index 81bf090311..8c1f0f8886 100644
+index 191e56f2f7..974bc49376 100644
@@ -22 +22 @@
-@@ -31,6 +31,6 @@ which can be accessed using API from the ``rte_dmadev`` library.
+@@ -30,6 +30,6 @@ which can be accessed using API from the ``rte_dmadev`` library.
@@ -32 +32 @@
-index c36acf01be..9cef2cbfbe 100644
+index 05066b4d0e..ff80622ec0 100644
@@ -35 +35 @@
-@@ -785,22 +785,13 @@ hisi_dma_burst_capacity(const void *dev_private, uint16_t vchan)
+@@ -732,22 +732,13 @@ hisi_dma_burst_capacity(const void *dev_private, uint16_t vchan)
@@ -64 +64 @@
-@@ -918,5 +909,5 @@ hisi_dma_probe(struct rte_pci_driver *pci_drv __rte_unused,
+@@ -865,5 +856,5 @@ hisi_dma_probe(struct rte_pci_driver *pci_drv __rte_unused,


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

* patch 'test/dma: fix missing checks for device capacity' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (12 preceding siblings ...)
  2022-03-01 10:41 ` patch 'dma/hisilicon: use common PCI device naming' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'dma/idxd: configure maximum batch size to high value' " Kevin Traynor
                   ` (88 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: Conor Walsh, Kevin Laatz, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From ebc0188ccb8bca848a75ec0e1a268829ca92319c Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Wed, 16 Feb 2022 16:06:07 +0000
Subject: [PATCH] test/dma: fix missing checks for device capacity

[ upstream commit 727e6b784087306801d487590e03d00b4e6e2485 ]

For some DMA HW devices, e.g. those using the idxd driver, the maximum
burst size is configurable, which can lead to test failures if the value
is set too small. Add explicit check for this to give reasonable error
messages for devices which need their config adjusted.

Fixes: 1b86a66a30c2 ("test/dma: add more comprehensive copy tests")
Fixes: 8fa5d2683940 ("test/dma: add burst capacity test")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: Conor Walsh <conor.walsh@intel.com>
Reviewed-by: Kevin Laatz <kevin.laatz@intel.com>
---
 app/test/test_dmadev.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/app/test/test_dmadev.c b/app/test/test_dmadev.c
index b206db27ae..e40c29c23b 100644
--- a/app/test/test_dmadev.c
+++ b/app/test/test_dmadev.c
@@ -775,4 +775,7 @@ test_dmadev_instance(int16_t dev_id)
 		ERR_RETURN("Error with rte_dma_stats_get()\n");
 
+	if (rte_dma_burst_capacity(dev_id, vchan) < 32)
+		ERR_RETURN("Error: Device does not have sufficient burst capacity to run tests");
+
 	if (stats.completed != 0 || stats.submitted != 0 || stats.errors != 0)
 		ERR_RETURN("Error device stats are not all zero: completed = %"PRIu64", "
@@ -796,5 +799,8 @@ test_dmadev_instance(int16_t dev_id)
 
 	/* run some burst capacity tests */
-	if (runtest("burst capacity", test_burst_capacity, 1, dev_id, vchan, CHECK_ERRS) < 0)
+	if (rte_dma_burst_capacity(dev_id, vchan) < 64)
+		printf("DMA Dev %u: insufficient burst capacity (64 required), skipping tests\n",
+				dev_id);
+	else if (runtest("burst capacity", test_burst_capacity, 1, dev_id, vchan, CHECK_ERRS) < 0)
 		goto err;
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.818237132 +0000
+++ 0015-test-dma-fix-missing-checks-for-device-capacity.patch	2022-03-01 10:41:01.251244087 +0000
@@ -1 +1 @@
-From 727e6b784087306801d487590e03d00b4e6e2485 Mon Sep 17 00:00:00 2001
+From ebc0188ccb8bca848a75ec0e1a268829ca92319c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 727e6b784087306801d487590e03d00b4e6e2485 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index db5aff701c..2b097e0f47 100644
+index b206db27ae..e40c29c23b 100644
@@ -26 +27 @@
-@@ -776,4 +776,7 @@ test_dmadev_instance(int16_t dev_id)
+@@ -775,4 +775,7 @@ test_dmadev_instance(int16_t dev_id)
@@ -34 +35 @@
-@@ -797,5 +800,8 @@ test_dmadev_instance(int16_t dev_id)
+@@ -796,5 +799,8 @@ test_dmadev_instance(int16_t dev_id)


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

* patch 'dma/idxd: configure maximum batch size to high value' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (13 preceding siblings ...)
  2022-03-01 10:41 ` patch 'test/dma: fix missing checks for device capacity' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'doc: improve configuration examples in idxd guide' " Kevin Traynor
                   ` (87 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: Kevin Laatz, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From b254386fadae12b61245707e0a189dad7fa75447 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Wed, 16 Feb 2022 16:06:08 +0000
Subject: [PATCH] dma/idxd: configure maximum batch size to high value

[ upstream commit 6a87d036a7ced87ba39406032c42ec2749b2cb88 ]

When configuring an Intel DSA instance using the utility script
dpdk_idxd_cfg.py, explicitly set the max supported batch size value to a
high value, to ensure large bursts are supported if so desired. The
default in the linux kernel is now just 32 [1], which may not be
sufficient for all DPDK apps.

[1] https://lore.kernel.org/r/163528473483.3926048.7950067926287180976.stgit@djiang5-desk3.ch.intel.com

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: Kevin Laatz <kevin.laatz@intel.com>
---
 drivers/dma/idxd/dpdk_idxd_cfg.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/dma/idxd/dpdk_idxd_cfg.py b/drivers/dma/idxd/dpdk_idxd_cfg.py
index 34537cb980..3f5d5ee752 100755
--- a/drivers/dma/idxd/dpdk_idxd_cfg.py
+++ b/drivers/dma/idxd/dpdk_idxd_cfg.py
@@ -90,4 +90,5 @@ def configure_dsa(dsa_id, queues, prefix):
                              "name": f"{prefix}_wq{dsa_id}.{q}",
                              "priority": 1,
+                             "max_batch_size": 1024,
                              "size": int(max_work_queues_size / nb_queues)})
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.840139980 +0000
+++ 0016-dma-idxd-configure-maximum-batch-size-to-high-value.patch	2022-03-01 10:41:01.251244087 +0000
@@ -1 +1 @@
-From 6a87d036a7ced87ba39406032c42ec2749b2cb88 Mon Sep 17 00:00:00 2001
+From b254386fadae12b61245707e0a189dad7fa75447 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6a87d036a7ced87ba39406032c42ec2749b2cb88 ]
+
@@ -13,2 +14,0 @@
-
-Cc: stable@dpdk.org


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

* patch 'doc: improve configuration examples in idxd guide' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (14 preceding siblings ...)
  2022-03-01 10:41 ` patch 'dma/idxd: configure maximum batch size to high value' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'examples/qos_sched: fix core mask overflow' " Kevin Traynor
                   ` (86 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: Kevin Laatz, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/9970eab8c427905c6189ea4e1de0b56395fdc855

Thanks.

Kevin

---
From 9970eab8c427905c6189ea4e1de0b56395fdc855 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Wed, 16 Feb 2022 16:06:09 +0000
Subject: [PATCH] doc: improve configuration examples in idxd guide

[ upstream commit 7a8a886f38a5a6dfc0bc42fe46ae1feb45d805b8 ]

The documentation on how to configure device instances using
accel-config can be improved by a number of changes:

* For initial example, when only configuring one queue, omit
  configuration of a second engine, which is unused later.
* Add the "max-batch-size" setting to the options being configured for
  each queue
* Add a final, more complete example, showing configuration of multiple
  queues on a device.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: Kevin Laatz <kevin.laatz@intel.com>
---
 doc/guides/dmadevs/idxd.rst | 29 +++++++++++++++++++++++++++--
 1 file changed, 27 insertions(+), 2 deletions(-)

diff --git a/doc/guides/dmadevs/idxd.rst b/doc/guides/dmadevs/idxd.rst
index d4a210b854..81451afd4d 100644
--- a/doc/guides/dmadevs/idxd.rst
+++ b/doc/guides/dmadevs/idxd.rst
@@ -56,5 +56,4 @@ To assign an engine to a group::
 
         $ accel-config config-engine dsa0/engine0.0 --group-id=0
-        $ accel-config config-engine dsa0/engine0.1 --group-id=1
 
 To assign work queues to groups for passing descriptors to the engines a similar accel-config command can be used.
@@ -72,5 +71,5 @@ Example configuration for a work queue::
         $ accel-config config-wq dsa0/wq0.0 --group-id=0 \
            --mode=dedicated --priority=10 --wq-size=8 \
-           --type=user --name=dpdk_app1
+           --max-batch-size=512 --type=user --name=dpdk_app1
 
 Once the devices have been configured, they need to be enabled::
@@ -83,4 +82,30 @@ Check the device configuration::
         $ accel-config list
 
+Every Intel\ |reg| DSA instance supports multiple queues and each should be similarly configured.
+As a further example, the following set of commands will configure and enable 4 queues on instance 0,
+giving each an equal share of resources::
+
+        # configure 4 groups, each with one engine
+        accel-config config-engine dsa0/engine0.0 --group-id=0
+        accel-config config-engine dsa0/engine0.1 --group-id=1
+        accel-config config-engine dsa0/engine0.2 --group-id=2
+        accel-config config-engine dsa0/engine0.3 --group-id=3
+
+        # configure 4 queues, putting each in a different group, so each
+        # is backed by a single engine
+        accel-config config-wq dsa0/wq0.0 --group-id=0 --type=user --wq-size=32 \
+            --priority=10 --max-batch-size=1024 --mode=dedicated --name=dpdk_app1
+        accel-config config-wq dsa0/wq0.1 --group-id=1 --type=user --wq-size=32 \
+            --priority=10 --max-batch-size=1024 --mode=dedicated --name=dpdk_app1
+        accel-config config-wq dsa0/wq0.2 --group-id=2 --type=user --wq-size=32 \
+            --priority=10 --max-batch-size=1024 --mode=dedicated --name=dpdk_app1
+        accel-config config-wq dsa0/wq0.3 --group-id=3 --type=user --wq-size=32 \
+            --priority=10 --max-batch-size=1024 --mode=dedicated --name=dpdk_app1
+
+        # enable device and queues
+        accel-config enable-device dsa0
+        accel-config enable-wq dsa0/wq0.0 dsa0/wq0.1 dsa0/wq0.2 dsa0/wq0.3
+
+
 Devices using VFIO/UIO drivers
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.862405548 +0000
+++ 0017-doc-improve-configuration-examples-in-idxd-guide.patch	2022-03-01 10:41:01.252244087 +0000
@@ -1 +1 @@
-From 7a8a886f38a5a6dfc0bc42fe46ae1feb45d805b8 Mon Sep 17 00:00:00 2001
+From 9970eab8c427905c6189ea4e1de0b56395fdc855 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 7a8a886f38a5a6dfc0bc42fe46ae1feb45d805b8 ]
+
@@ -16,2 +17,0 @@
-Cc: stable@dpdk.org
-
@@ -25 +25 @@
-index 8d7cea6583..bdfd3e78ad 100644
+index d4a210b854..81451afd4d 100644


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

* patch 'examples/qos_sched: fix core mask overflow' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (15 preceding siblings ...)
  2022-03-01 10:41 ` patch 'doc: improve configuration examples in idxd guide' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 18:28   ` Ajmera, Megha
  2022-03-01 10:41 ` patch 'eventdev/eth_rx: fix parameters parsing memory leak' " Kevin Traynor
                   ` (85 subsequent siblings)
  102 siblings, 1 reply; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Megha Ajmera; +Cc: Morten Brørup, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From d33bb6bd28406944b31ad53ba90199ca5f2f114f Mon Sep 17 00:00:00 2001
From: Megha Ajmera <megha.ajmera@intel.com>
Date: Wed, 23 Feb 2022 17:36:30 +0000
Subject: [PATCH] examples/qos_sched: fix core mask overflow
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 9c9fad3dfa042ae4b7a045cb1731f8701f8210e6 ]

Masking of core mask was incorrect. Instead of using 1U for shifting, it
should be using 1LU as the result is assigned to uint64.

CID 375859: Potentially overflowing expression "1U << app_main_core" with
type "unsigned int" (32 bits, unsigned) is evaluated using 32-bit
arithmetic, and then used in a context that expects an expression of
type "uint64_t" (64 bits, unsigned).

Coverity issue: 375859
Fixes: de3cfa2c9823 ("sched: initial import")

Signed-off-by: Megha Ajmera <megha.ajmera@intel.com>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
---
 examples/qos_sched/args.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/examples/qos_sched/args.c b/examples/qos_sched/args.c
index 10ca7bea61..ff51d0215a 100644
--- a/examples/qos_sched/args.c
+++ b/examples/qos_sched/args.c
@@ -12,4 +12,5 @@
 #include <getopt.h>
 
+#include <rte_bitops.h>
 #include <rte_log.h>
 #include <rte_eal.h>
@@ -428,5 +429,5 @@ app_parse_args(int argc, char **argv)
 	/* check main core index validity */
 	for (i = 0; i <= app_main_core; i++) {
-		if (app_used_core_mask & (1u << app_main_core)) {
+		if (app_used_core_mask & RTE_BIT64(app_main_core)) {
 			RTE_LOG(ERR, APP, "Main core index is not configured properly\n");
 			app_usage(prgname);
@@ -434,5 +435,5 @@ app_parse_args(int argc, char **argv)
 		}
 	}
-	app_used_core_mask |= 1u << app_main_core;
+	app_used_core_mask |= RTE_BIT64(app_main_core);
 
 	if ((app_used_core_mask != app_eal_core_mask()) ||
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.884306256 +0000
+++ 0018-examples-qos_sched-fix-core-mask-overflow.patch	2022-03-01 10:41:01.252244087 +0000
@@ -1 +1 @@
-From 9c9fad3dfa042ae4b7a045cb1731f8701f8210e6 Mon Sep 17 00:00:00 2001
+From d33bb6bd28406944b31ad53ba90199ca5f2f114f Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 9c9fad3dfa042ae4b7a045cb1731f8701f8210e6 ]
+
@@ -19 +20,0 @@
-Cc: stable@dpdk.org
@@ -24,2 +25,2 @@
- examples/qos_sched/args.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
+ examples/qos_sched/args.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
@@ -28 +29 @@
-index 10ca7bea61..b2959499ae 100644
+index 10ca7bea61..ff51d0215a 100644
@@ -31 +32,7 @@
-@@ -428,5 +428,5 @@ app_parse_args(int argc, char **argv)
+@@ -12,4 +12,5 @@
+ #include <getopt.h>
+ 
++#include <rte_bitops.h>
+ #include <rte_log.h>
+ #include <rte_eal.h>
+@@ -428,5 +429,5 @@ app_parse_args(int argc, char **argv)
@@ -38 +45 @@
-@@ -434,5 +434,5 @@ app_parse_args(int argc, char **argv)
+@@ -434,5 +435,5 @@ app_parse_args(int argc, char **argv)


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

* patch 'eventdev/eth_rx: fix parameters parsing memory leak' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (16 preceding siblings ...)
  2022-03-01 10:41 ` patch 'examples/qos_sched: fix core mask overflow' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'eventdev/eth_rx: fix queue config query' " Kevin Traynor
                   ` (84 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Weiguo Li; +Cc: Ganapati Kundapura, Jay Jayatheerthan, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/529f3a735e4eb837049e340c1334ea6a6355397b

Thanks.

Kevin

---
From 529f3a735e4eb837049e340c1334ea6a6355397b Mon Sep 17 00:00:00 2001
From: Weiguo Li <liwg06@foxmail.com>
Date: Fri, 4 Feb 2022 16:21:28 +0800
Subject: [PATCH] eventdev/eth_rx: fix parameters parsing memory leak

[ upstream commit 74b034ff817239b1a5dcf4dfd7d33ccd5684996a ]

The memory get from strdup should be freed when parameter parsing
finished, and also should be freed when error occurs.

Fixes: 814d01709328 ("eventdev/eth_rx: support telemetry")
Fixes: 9e583185318f ("eventdev/eth_rx: support telemetry")

Signed-off-by: Weiguo Li <liwg06@foxmail.com>
Acked-by: Ganapati Kundapura <ganapati.kundapura@intel.com>
Acked-by: Jay Jayatheerthan <jay.jayatheerthan@intel.com>
---
 lib/eventdev/rte_event_eth_rx_adapter.c | 96 ++++++++++++++++++-------
 1 file changed, 72 insertions(+), 24 deletions(-)

diff --git a/lib/eventdev/rte_event_eth_rx_adapter.c b/lib/eventdev/rte_event_eth_rx_adapter.c
index f946137b25..ce94999738 100644
--- a/lib/eventdev/rte_event_eth_rx_adapter.c
+++ b/lib/eventdev/rte_event_eth_rx_adapter.c
@@ -294,4 +294,28 @@ rxa_event_buf_get(struct event_eth_rx_adapter *rx_adapter, uint16_t eth_dev_id,
 } while (0)
 
+#define RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_GOTO_ERR_RET(id, retval) do { \
+	if (!rxa_validate_id(id)) { \
+		RTE_EDEV_LOG_ERR("Invalid eth Rx adapter id = %d\n", id); \
+		ret = retval; \
+		goto error; \
+	} \
+} while (0)
+
+#define RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, retval) do { \
+	if ((token) == NULL || strlen(token) == 0 || !isdigit(*token)) { \
+		RTE_EDEV_LOG_ERR("Invalid eth Rx adapter token\n"); \
+		ret = retval; \
+		goto error; \
+	} \
+} while (0)
+
+#define RTE_ETH_VALID_PORTID_OR_GOTO_ERR_RET(port_id, retval) do { \
+	if (!rte_eth_dev_is_valid_port(port_id)) { \
+		RTE_ETHDEV_LOG(ERR, "Invalid port_id=%u\n", port_id); \
+		ret = retval; \
+		goto error; \
+	} \
+} while (0)
+
 static inline int
 rxa_sw_adapter_queue_count(struct event_eth_rx_adapter *rx_adapter)
@@ -3304,5 +3328,5 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
 	uint8_t rx_adapter_id;
 	uint16_t rx_queue_id;
-	int eth_dev_id;
+	int eth_dev_id, ret = -1;
 	char *token, *l_params;
 	struct rte_event_eth_rx_adapter_queue_conf queue_conf;
@@ -3313,19 +3337,20 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
 	/* Get Rx adapter ID from parameter string */
 	l_params = strdup(params);
+	if (l_params == NULL)
+		return -ENOMEM;
 	token = strtok(l_params, ",");
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 	rx_adapter_id = strtoul(token, NULL, 10);
-	RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_ERR_RET(rx_adapter_id, -EINVAL);
+	RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_GOTO_ERR_RET(rx_adapter_id, -EINVAL);
 
 	token = strtok(NULL, ",");
-	if (token == NULL || strlen(token) == 0 || !isdigit(*token))
-		return -1;
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 
 	/* Get device ID from parameter string */
 	eth_dev_id = strtoul(token, NULL, 10);
-	RTE_EVENTDEV_VALID_DEVID_OR_ERR_RET(eth_dev_id, -EINVAL);
+	RTE_ETH_VALID_PORTID_OR_GOTO_ERR_RET(eth_dev_id, -EINVAL);
 
 	token = strtok(NULL, ",");
-	if (token == NULL || strlen(token) == 0 || !isdigit(*token))
-		return -1;
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 
 	/* Get Rx queue ID from parameter string */
@@ -3333,5 +3358,6 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
 	if (rx_queue_id >= rte_eth_devices[eth_dev_id].data->nb_rx_queues) {
 		RTE_EDEV_LOG_ERR("Invalid rx queue_id %u", rx_queue_id);
-		return -EINVAL;
+		ret = -EINVAL;
+		goto error;
 	}
 
@@ -3340,4 +3366,6 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
 		RTE_EDEV_LOG_ERR("Extra parameters passed to eventdev"
 				 " telemetry command, ignoring");
+	/* Parsing parameter finished */
+	free(l_params);
 
 	if (rte_event_eth_rx_adapter_queue_conf_get(rx_adapter_id, eth_dev_id,
@@ -3359,4 +3387,8 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
 
 	return 0;
+
+error:
+	free(l_params);
+	return ret;
 }
 
@@ -3368,5 +3400,5 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
 	uint8_t rx_adapter_id;
 	uint16_t rx_queue_id;
-	int eth_dev_id;
+	int eth_dev_id, ret = -1;
 	char *token, *l_params;
 	struct rte_event_eth_rx_adapter_queue_stats q_stats;
@@ -3377,19 +3409,20 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
 	/* Get Rx adapter ID from parameter string */
 	l_params = strdup(params);
+	if (l_params == NULL)
+		return -ENOMEM;
 	token = strtok(l_params, ",");
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 	rx_adapter_id = strtoul(token, NULL, 10);
-	RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_ERR_RET(rx_adapter_id, -EINVAL);
+	RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_GOTO_ERR_RET(rx_adapter_id, -EINVAL);
 
 	token = strtok(NULL, ",");
-	if (token == NULL || strlen(token) == 0 || !isdigit(*token))
-		return -1;
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 
 	/* Get device ID from parameter string */
 	eth_dev_id = strtoul(token, NULL, 10);
-	RTE_EVENTDEV_VALID_DEVID_OR_ERR_RET(eth_dev_id, -EINVAL);
+	RTE_ETH_VALID_PORTID_OR_GOTO_ERR_RET(eth_dev_id, -EINVAL);
 
 	token = strtok(NULL, ",");
-	if (token == NULL || strlen(token) == 0 || !isdigit(*token))
-		return -1;
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 
 	/* Get Rx queue ID from parameter string */
@@ -3397,5 +3430,6 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
 	if (rx_queue_id >= rte_eth_devices[eth_dev_id].data->nb_rx_queues) {
 		RTE_EDEV_LOG_ERR("Invalid rx queue_id %u", rx_queue_id);
-		return -EINVAL;
+		ret = -EINVAL;
+		goto error;
 	}
 
@@ -3404,4 +3438,6 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
 		RTE_EDEV_LOG_ERR("Extra parameters passed to eventdev"
 				 " telemetry command, ignoring");
+	/* Parsing parameter finished */
+	free(l_params);
 
 	if (rte_event_eth_rx_adapter_queue_stats_get(rx_adapter_id, eth_dev_id,
@@ -3422,4 +3458,8 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
 
 	return 0;
+
+error:
+	free(l_params);
+	return ret;
 }
 
@@ -3431,5 +3471,5 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
 	uint8_t rx_adapter_id;
 	uint16_t rx_queue_id;
-	int eth_dev_id;
+	int eth_dev_id, ret = -1;
 	char *token, *l_params;
 
@@ -3439,19 +3479,20 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
 	/* Get Rx adapter ID from parameter string */
 	l_params = strdup(params);
+	if (l_params == NULL)
+		return -ENOMEM;
 	token = strtok(l_params, ",");
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 	rx_adapter_id = strtoul(token, NULL, 10);
-	RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_ERR_RET(rx_adapter_id, -EINVAL);
+	RTE_EVENT_ETH_RX_ADAPTER_ID_VALID_OR_GOTO_ERR_RET(rx_adapter_id, -EINVAL);
 
 	token = strtok(NULL, ",");
-	if (token == NULL || strlen(token) == 0 || !isdigit(*token))
-		return -1;
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 
 	/* Get device ID from parameter string */
 	eth_dev_id = strtoul(token, NULL, 10);
-	RTE_EVENTDEV_VALID_DEVID_OR_ERR_RET(eth_dev_id, -EINVAL);
+	RTE_ETH_VALID_PORTID_OR_GOTO_ERR_RET(eth_dev_id, -EINVAL);
 
 	token = strtok(NULL, ",");
-	if (token == NULL || strlen(token) == 0 || !isdigit(*token))
-		return -1;
+	RTE_EVENT_ETH_RX_ADAPTER_TOKEN_VALID_OR_GOTO_ERR_RET(token, -1);
 
 	/* Get Rx queue ID from parameter string */
@@ -3459,5 +3500,6 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
 	if (rx_queue_id >= rte_eth_devices[eth_dev_id].data->nb_rx_queues) {
 		RTE_EDEV_LOG_ERR("Invalid rx queue_id %u", rx_queue_id);
-		return -EINVAL;
+		ret = -EINVAL;
+		goto error;
 	}
 
@@ -3466,4 +3508,6 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
 		RTE_EDEV_LOG_ERR("Extra parameters passed to eventdev"
 				 " telemetry command, ignoring");
+	/* Parsing parameter finished */
+	free(l_params);
 
 	if (rte_event_eth_rx_adapter_queue_stats_reset(rx_adapter_id,
@@ -3475,4 +3519,8 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
 
 	return 0;
+
+error:
+	free(l_params);
+	return ret;
 }
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.906616705 +0000
+++ 0019-eventdev-eth_rx-fix-parameters-parsing-memory-leak.patch	2022-03-01 10:41:01.256244088 +0000
@@ -1 +1 @@
-From 74b034ff817239b1a5dcf4dfd7d33ccd5684996a Mon Sep 17 00:00:00 2001
+From 529f3a735e4eb837049e340c1334ea6a6355397b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 74b034ff817239b1a5dcf4dfd7d33ccd5684996a ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index ae1e260c08..4da6f1ff90 100644
+index f946137b25..ce94999738 100644
@@ -53 +54 @@
-@@ -3324,5 +3348,5 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
+@@ -3304,5 +3328,5 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
@@ -60 +61 @@
-@@ -3333,19 +3357,20 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
+@@ -3313,19 +3337,20 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
@@ -87 +88 @@
-@@ -3353,5 +3378,6 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
+@@ -3333,5 +3358,6 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
@@ -95 +96 @@
-@@ -3360,4 +3386,6 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
+@@ -3340,4 +3366,6 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
@@ -102 +103 @@
-@@ -3379,4 +3407,8 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
+@@ -3359,4 +3387,8 @@ handle_rxa_get_queue_conf(const char *cmd __rte_unused,
@@ -111 +112 @@
-@@ -3388,5 +3420,5 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
+@@ -3368,5 +3400,5 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
@@ -118 +119 @@
-@@ -3397,19 +3429,20 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
+@@ -3377,19 +3409,20 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
@@ -145 +146 @@
-@@ -3417,5 +3450,6 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
+@@ -3397,5 +3430,6 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
@@ -153 +154 @@
-@@ -3424,4 +3458,6 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
+@@ -3404,4 +3438,6 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
@@ -160 +161 @@
-@@ -3442,4 +3478,8 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
+@@ -3422,4 +3458,8 @@ handle_rxa_get_queue_stats(const char *cmd __rte_unused,
@@ -169 +170 @@
-@@ -3451,5 +3491,5 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
+@@ -3431,5 +3471,5 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
@@ -176 +177 @@
-@@ -3459,19 +3499,20 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
+@@ -3439,19 +3479,20 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
@@ -203 +204 @@
-@@ -3479,5 +3520,6 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
+@@ -3459,5 +3500,6 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
@@ -211 +212 @@
-@@ -3486,4 +3528,6 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
+@@ -3466,4 +3508,6 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
@@ -218 +219 @@
-@@ -3495,4 +3539,8 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,
+@@ -3475,4 +3519,8 @@ handle_rxa_queue_stats_reset(const char *cmd __rte_unused,


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

* patch 'eventdev/eth_rx: fix queue config query' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (17 preceding siblings ...)
  2022-03-01 10:41 ` patch 'eventdev/eth_rx: fix parameters parsing memory leak' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'event/dlb2: update rolling mask used for dequeue' " Kevin Traynor
                   ` (83 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Naga Harish K S V; +Cc: Jay Jayatheerthan, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 7d7a9f161d0d95c8d241c574e901826ad3a8c4be Mon Sep 17 00:00:00 2001
From: Naga Harish K S V <s.v.naga.harish.k@intel.com>
Date: Mon, 14 Feb 2022 11:10:16 -0600
Subject: [PATCH] eventdev/eth_rx: fix queue config query

[ upstream commit 95138712c5e76e43c6268835342ab7ca9ac3692e ]

Remove the memcpy usage in queue config get function for
`event` variable which is 8 byte size and use direct copy.
Also provide vector information and event buffer size in the
queue config info.

Fixes: da781e6488 ("eventdev/eth_rx: support Rx queue config get")

Signed-off-by: Naga Harish K S V <s.v.naga.harish.k@intel.com>
Acked-by: Jay Jayatheerthan <jay.jayatheerthan@intel.com>
---
 lib/eventdev/rte_event_eth_rx_adapter.c | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)

diff --git a/lib/eventdev/rte_event_eth_rx_adapter.c b/lib/eventdev/rte_event_eth_rx_adapter.c
index ce94999738..4b46e9b6c6 100644
--- a/lib/eventdev/rte_event_eth_rx_adapter.c
+++ b/lib/eventdev/rte_event_eth_rx_adapter.c
@@ -3199,9 +3199,9 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
 			struct rte_event_eth_rx_adapter_queue_conf *queue_conf)
 {
+#define TICK2NSEC(_ticks, _freq) (((_ticks) * (1E9)) / (_freq))
 	struct rte_eventdev *dev;
 	struct event_eth_rx_adapter *rx_adapter;
 	struct eth_device_info *dev_info;
 	struct eth_rx_queue_info *queue_info;
-	struct rte_event *qi_ev;
 	int ret;
 
@@ -3234,5 +3234,4 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
 
 	queue_info = &dev_info->rx_queue[rx_queue_id];
-	qi_ev = (struct rte_event *)&queue_info->event;
 
 	memset(queue_conf, 0, sizeof(*queue_conf));
@@ -3243,5 +3242,16 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
 	queue_conf->servicing_weight = queue_info->wt;
 
-	memcpy(&queue_conf->ev, qi_ev, sizeof(*qi_ev));
+	queue_conf->ev.event = queue_info->event;
+
+	queue_conf->vector_sz = queue_info->vector_data.max_vector_count;
+	queue_conf->vector_mp = queue_info->vector_data.vector_pool;
+	/* need to be converted from ticks to ns */
+	queue_conf->vector_timeout_ns = TICK2NSEC(
+		queue_info->vector_data.vector_timeout_ticks, rte_get_timer_hz());
+
+	if (queue_info->event_buf != NULL)
+		queue_conf->event_buf_size = queue_info->event_buf->events_size;
+	else
+		queue_conf->event_buf_size = 0;
 
 	dev = &rte_eventdevs[rx_adapter->eventdev_id];
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.932555403 +0000
+++ 0020-eventdev-eth_rx-fix-queue-config-query.patch	2022-03-01 10:41:01.260244089 +0000
@@ -1 +1 @@
-From 95138712c5e76e43c6268835342ab7ca9ac3692e Mon Sep 17 00:00:00 2001
+From 7d7a9f161d0d95c8d241c574e901826ad3a8c4be Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 95138712c5e76e43c6268835342ab7ca9ac3692e ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 4da6f1ff90..ff83ce8b67 100644
+index ce94999738..4b46e9b6c6 100644
@@ -24 +25 @@
-@@ -3219,9 +3219,9 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
+@@ -3199,9 +3199,9 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
@@ -35 +36 @@
-@@ -3254,5 +3254,4 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
+@@ -3234,5 +3234,4 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
@@ -41 +42 @@
-@@ -3263,5 +3262,16 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,
+@@ -3243,5 +3242,16 @@ rte_event_eth_rx_adapter_queue_conf_get(uint8_t id,


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

* patch 'event/dlb2: update rolling mask used for dequeue' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (18 preceding siblings ...)
  2022-03-01 10:41 ` patch 'eventdev/eth_rx: fix queue config query' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'event/dlb2: poll HW CQ inflights before mapping queue' " Kevin Traynor
                   ` (82 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Timothy McDaniel; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/720fb431b46a03ccfdd8c080ce11d322f174a377

Thanks.

Kevin

---
From 720fb431b46a03ccfdd8c080ce11d322f174a377 Mon Sep 17 00:00:00 2001
From: Timothy McDaniel <timothy.mcdaniel@intel.com>
Date: Wed, 16 Feb 2022 13:38:26 -0600
Subject: [PATCH] event/dlb2: update rolling mask used for dequeue

[ upstream commit e697f35dbdd1f4868b452d17a0cb11783f61690d ]

Update the rolling mask used in dequeue operations to
fix the vector optimized dequeue.

Fixes: 000a7b8e7582 ("event/dlb2: optimize dequeue operation")

Signed-off-by: Timothy McDaniel <timothy.mcdaniel@intel.com>
---
 drivers/event/dlb2/dlb2.c | 28 +++++++++++++++++++++-------
 1 file changed, 21 insertions(+), 7 deletions(-)

diff --git a/drivers/event/dlb2/dlb2.c b/drivers/event/dlb2/dlb2.c
index d75f12e382..09abdd1660 100644
--- a/drivers/event/dlb2/dlb2.c
+++ b/drivers/event/dlb2/dlb2.c
@@ -3898,29 +3898,43 @@ dlb2_hw_dequeue_sparse(struct dlb2_eventdev *dlb2,
 		struct dlb2_dequeue_qe qes[DLB2_NUM_QES_PER_CACHE_LINE];
 		int num_avail;
+
 		if (use_scalar) {
+			int n_iter = 0;
+			uint64_t m_rshift, m_lshift, m2_rshift, m2_lshift;
+
 			num_avail = dlb2_recv_qe_sparse(qm_port, qes);
 			num_avail = RTE_MIN(num_avail, max_num - num);
 			dlb2_inc_cq_idx(qm_port, num_avail << 2);
 			if (num_avail == DLB2_NUM_QES_PER_CACHE_LINE)
-				num += dlb2_process_dequeue_four_qes(ev_port,
-								  qm_port,
-								  &events[num],
-								  &qes[0]);
+				n_iter = dlb2_process_dequeue_four_qes(ev_port,
+								qm_port,
+								&events[num],
+								&qes[0]);
 			else if (num_avail)
-				num += dlb2_process_dequeue_qes(ev_port,
+				n_iter = dlb2_process_dequeue_qes(ev_port,
 								qm_port,
 								&events[num],
 								&qes[0],
 								num_avail);
+			num += n_iter;
+			/* update rolling_mask for vector code support */
+			m_rshift = qm_port->cq_rolling_mask >> n_iter;
+			m_lshift = qm_port->cq_rolling_mask << (64 - n_iter);
+			m2_rshift = qm_port->cq_rolling_mask_2 >> n_iter;
+			m2_lshift = qm_port->cq_rolling_mask_2 <<
+					(64 - n_iter);
+			qm_port->cq_rolling_mask = (m_rshift | m2_lshift);
+			qm_port->cq_rolling_mask_2 = (m2_rshift | m_lshift);
 		} else { /* !use_scalar */
 			num_avail = dlb2_recv_qe_sparse_vec(qm_port,
 							    &events[num],
 							    max_num - num);
+			dlb2_inc_cq_idx(qm_port, num_avail << 2);
 			num += num_avail;
-			dlb2_inc_cq_idx(qm_port, num_avail << 2);
 			DLB2_INC_STAT(ev_port->stats.traffic.rx_ok, num_avail);
 		}
 		if (!num_avail) {
-			if (num > 0)
+			if ((timeout == 0) || (num > 0))
+				/* Not waiting in any form or 1+ events recd */
 				break;
 			else if (dlb2_dequeue_wait(dlb2, ev_port, qm_port,
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.956050319 +0000
+++ 0021-event-dlb2-update-rolling-mask-used-for-dequeue.patch	2022-03-01 10:41:01.265244090 +0000
@@ -1 +1 @@
-From e697f35dbdd1f4868b452d17a0cb11783f61690d Mon Sep 17 00:00:00 2001
+From 720fb431b46a03ccfdd8c080ce11d322f174a377 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e697f35dbdd1f4868b452d17a0cb11783f61690d ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'event/dlb2: poll HW CQ inflights before mapping queue' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (19 preceding siblings ...)
  2022-03-01 10:41 ` patch 'event/dlb2: update rolling mask used for dequeue' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'event/cnxk: fix variables casting' " Kevin Traynor
                   ` (81 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Timothy McDaniel; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 9a552423fd5d7a226fe55cdf509312c221e03e6a Mon Sep 17 00:00:00 2001
From: Timothy McDaniel <timothy.mcdaniel@intel.com>
Date: Wed, 16 Feb 2022 13:38:27 -0600
Subject: [PATCH] event/dlb2: poll HW CQ inflights before mapping queue

[ upstream commit f6ed136aaea6b9f237670891df9c0b8a4b97d6d3 ]

When attempting to link a port and queue immediately after unlinking,
the CQ inflights may not all be processed. Poll the h/w register for
outstanding inflights instead of reading once, in case the inflights
are still being processed. Also return EBUSY if the inflight
processing is not completed in a suitable amount of time.

Fixes: 1857f1922ce2 ("event/dlb2: use new implementation of resource file")

Signed-off-by: Timothy McDaniel <timothy.mcdaniel@intel.com>
---
 drivers/event/dlb2/pf/base/dlb2_resource.c | 23 ++++++++++++++++++----
 1 file changed, 19 insertions(+), 4 deletions(-)

diff --git a/drivers/event/dlb2/pf/base/dlb2_resource.c b/drivers/event/dlb2/pf/base/dlb2_resource.c
index 3661b940c3..d4c49c2992 100644
--- a/drivers/event/dlb2/pf/base/dlb2_resource.c
+++ b/drivers/event/dlb2/pf/base/dlb2_resource.c
@@ -2357,4 +2357,6 @@ static bool dlb2_domain_finish_unmap_port(struct dlb2_hw *hw,
 	u32 infl_cnt;
 	int i;
+	const int max_iters = 1000;
+	const int iter_poll_us = 100;
 
 	if (port->num_pending_removals == 0)
@@ -2363,8 +2365,16 @@ static bool dlb2_domain_finish_unmap_port(struct dlb2_hw *hw,
 	/*
 	 * The unmap requires all the CQ's outstanding inflights to be
-	 * completed.
+	 * completed. Poll up to 100ms.
 	 */
-	infl_cnt = DLB2_CSR_RD(hw, DLB2_LSP_CQ_LDB_INFL_CNT(hw->ver,
+	for (i = 0; i < max_iters; i++) {
+		infl_cnt = DLB2_CSR_RD(hw, DLB2_LSP_CQ_LDB_INFL_CNT(hw->ver,
 						       port->id.phys_id));
+
+		if (DLB2_BITS_GET(infl_cnt,
+				  DLB2_LSP_CQ_LDB_INFL_CNT_COUNT) == 0)
+			break;
+		rte_delay_us_sleep(iter_poll_us);
+	}
+
 	if (DLB2_BITS_GET(infl_cnt, DLB2_LSP_CQ_LDB_INFL_CNT_COUNT) > 0)
 		return false;
@@ -5317,4 +5327,5 @@ static void dlb2_log_map_qid(struct dlb2_hw *hw,
  *	    the domain is not configured.
  * EFAULT - Internal error (resp->status not set).
+ * EBUSY  - The requested port has outstanding detach operations.
  */
 int dlb2_hw_map_qid(struct dlb2_hw *hw,
@@ -5357,6 +5368,10 @@ int dlb2_hw_map_qid(struct dlb2_hw *hw,
 	 * slot for this requested mapping.
 	 */
-	if (port->num_pending_removals)
-		dlb2_domain_finish_unmap_port(hw, domain, port);
+	if (port->num_pending_removals) {
+		bool bool_ret;
+		bool_ret = dlb2_domain_finish_unmap_port(hw, domain, port);
+		if (!bool_ret)
+			return -EBUSY;
+	}
 
 	ret = dlb2_verify_map_qid_slot_available(port, queue, resp);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:01.981030878 +0000
+++ 0022-event-dlb2-poll-HW-CQ-inflights-before-mapping-queue.patch	2022-03-01 10:41:01.269244091 +0000
@@ -1 +1 @@
-From f6ed136aaea6b9f237670891df9c0b8a4b97d6d3 Mon Sep 17 00:00:00 2001
+From 9a552423fd5d7a226fe55cdf509312c221e03e6a Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit f6ed136aaea6b9f237670891df9c0b8a4b97d6d3 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org


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

* patch 'event/cnxk: fix variables casting' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (20 preceding siblings ...)
  2022-03-01 10:41 ` patch 'event/dlb2: poll HW CQ inflights before mapping queue' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'event/cnxk: fix uninitialized local variables' " Kevin Traynor
                   ` (80 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/52d824d106ee34fc52ba603c06b4c69b3a7911a8

Thanks.

Kevin

---
From 52d824d106ee34fc52ba603c06b4c69b3a7911a8 Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Sat, 12 Feb 2022 18:09:46 +0530
Subject: [PATCH] event/cnxk: fix variables casting

[ upstream commit 894851527eb08c153b13e7385d02d138b57a6c43 ]

Fix incompatible casting on variables reported by coverity scan.

Coverity issue: 370582 370584
Fixes: 6223ede2036 ("event/cnxk: add event port link and unlink")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
---
 drivers/event/cnxk/cn10k_eventdev.c |  4 ++--
 drivers/event/cnxk/cn9k_eventdev.c  | 11 ++++-------
 2 files changed, 6 insertions(+), 9 deletions(-)

diff --git a/drivers/event/cnxk/cn10k_eventdev.c b/drivers/event/cnxk/cn10k_eventdev.c
index c5a8c1ae8f..4d878fc2b7 100644
--- a/drivers/event/cnxk/cn10k_eventdev.c
+++ b/drivers/event/cnxk/cn10k_eventdev.c
@@ -112,8 +112,8 @@ cn10k_sso_hws_release(void *arg, void *hws)
 	struct cnxk_sso_evdev *dev = arg;
 	struct cn10k_sso_hws *ws = hws;
-	int i;
+	uint16_t i;
 
 	for (i = 0; i < dev->nb_event_queues; i++)
-		roc_sso_hws_unlink(&dev->sso, ws->hws_id, (uint16_t *)&i, 1);
+		roc_sso_hws_unlink(&dev->sso, ws->hws_id, &i, 1);
 	memset(ws, 0, sizeof(*ws));
 }
diff --git a/drivers/event/cnxk/cn9k_eventdev.c b/drivers/event/cnxk/cn9k_eventdev.c
index b68ce6c0a4..d2ec4aedd7 100644
--- a/drivers/event/cnxk/cn9k_eventdev.c
+++ b/drivers/event/cnxk/cn9k_eventdev.c
@@ -110,5 +110,5 @@ cn9k_sso_hws_release(void *arg, void *hws)
 	struct cn9k_sso_hws_dual *dws;
 	struct cn9k_sso_hws *ws;
-	int i;
+	uint16_t i;
 
 	if (dev->dual_ws) {
@@ -116,9 +116,7 @@ cn9k_sso_hws_release(void *arg, void *hws)
 		for (i = 0; i < dev->nb_event_queues; i++) {
 			roc_sso_hws_unlink(&dev->sso,
-					   CN9K_DUAL_WS_PAIR_ID(dws->hws_id, 0),
-					   (uint16_t *)&i, 1);
+					   CN9K_DUAL_WS_PAIR_ID(dws->hws_id, 0), &i, 1);
 			roc_sso_hws_unlink(&dev->sso,
-					   CN9K_DUAL_WS_PAIR_ID(dws->hws_id, 1),
-					   (uint16_t *)&i, 1);
+					   CN9K_DUAL_WS_PAIR_ID(dws->hws_id, 1), &i, 1);
 		}
 		memset(dws, 0, sizeof(*dws));
@@ -126,6 +124,5 @@ cn9k_sso_hws_release(void *arg, void *hws)
 		ws = hws;
 		for (i = 0; i < dev->nb_event_queues; i++)
-			roc_sso_hws_unlink(&dev->sso, ws->hws_id,
-					   (uint16_t *)&i, 1);
+			roc_sso_hws_unlink(&dev->sso, ws->hws_id, &i, 1);
 		memset(ws, 0, sizeof(*ws));
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.006497226 +0000
+++ 0023-event-cnxk-fix-variables-casting.patch	2022-03-01 10:41:01.272244091 +0000
@@ -1 +1 @@
-From 894851527eb08c153b13e7385d02d138b57a6c43 Mon Sep 17 00:00:00 2001
+From 52d824d106ee34fc52ba603c06b4c69b3a7911a8 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 894851527eb08c153b13e7385d02d138b57a6c43 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 26d65e3568..249688b6d7 100644
+index c5a8c1ae8f..4d878fc2b7 100644
@@ -22 +23 @@
-@@ -102,8 +102,8 @@ cn10k_sso_hws_release(void *arg, void *hws)
+@@ -112,8 +112,8 @@ cn10k_sso_hws_release(void *arg, void *hws)
@@ -34 +35 @@
-index 6d3d03c97c..ccd98c27fb 100644
+index b68ce6c0a4..d2ec4aedd7 100644
@@ -37 +38 @@
-@@ -99,5 +99,5 @@ cn9k_sso_hws_release(void *arg, void *hws)
+@@ -110,5 +110,5 @@ cn9k_sso_hws_release(void *arg, void *hws)
@@ -44 +45 @@
-@@ -105,9 +105,7 @@ cn9k_sso_hws_release(void *arg, void *hws)
+@@ -116,9 +116,7 @@ cn9k_sso_hws_release(void *arg, void *hws)
@@ -56 +57 @@
-@@ -115,6 +113,5 @@ cn9k_sso_hws_release(void *arg, void *hws)
+@@ -126,6 +124,5 @@ cn9k_sso_hws_release(void *arg, void *hws)


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

* patch 'event/cnxk: fix uninitialized local variables' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (21 preceding siblings ...)
  2022-03-01 10:41 ` patch 'event/cnxk: fix variables casting' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: remove useless check' " Kevin Traynor
                   ` (79 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From fec66e64e5a90aff71931d728cf6adb349b344a6 Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Sat, 12 Feb 2022 18:09:48 +0530
Subject: [PATCH] event/cnxk: fix uninitialized local variables

[ upstream commit de3f033e5462fb1a0cad3c94c51fd79b5bf1b33f ]

Fix uninitialized local variable as reported in coverity scan.

Coverity issue: 370578, 370579, 370587
Fixes: 300b796262a ("event/cnxk: add timer arm routine")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
---
 drivers/event/cnxk/cnxk_tim_worker.c | 2 +-
 drivers/event/cnxk/cnxk_tim_worker.h | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/event/cnxk/cnxk_tim_worker.c b/drivers/event/cnxk/cnxk_tim_worker.c
index 3ce99864a6..dfcfbdc797 100644
--- a/drivers/event/cnxk/cnxk_tim_worker.c
+++ b/drivers/event/cnxk/cnxk_tim_worker.c
@@ -64,5 +64,5 @@ cnxk_tim_timer_arm_burst(const struct rte_event_timer_adapter *adptr,
 	struct cnxk_tim_ent entry;
 	uint16_t index;
-	int ret;
+	int ret = 0;
 
 	cnxk_tim_sync_start_cyc(tim_ring);
diff --git a/drivers/event/cnxk/cnxk_tim_worker.h b/drivers/event/cnxk/cnxk_tim_worker.h
index 78e36ffafe..0c9f29cfbe 100644
--- a/drivers/event/cnxk/cnxk_tim_worker.h
+++ b/drivers/event/cnxk/cnxk_tim_worker.h
@@ -234,6 +234,6 @@ cnxk_tim_add_entry_sp(struct cnxk_tim_ring *const tim_ring,
 		      const uint8_t flags)
 {
+	struct cnxk_tim_ent *chunk = NULL;
 	struct cnxk_tim_bkt *mirr_bkt;
-	struct cnxk_tim_ent *chunk;
 	struct cnxk_tim_bkt *bkt;
 	uint64_t lock_sema;
@@ -317,6 +317,6 @@ cnxk_tim_add_entry_mp(struct cnxk_tim_ring *const tim_ring,
 		      const uint8_t flags)
 {
+	struct cnxk_tim_ent *chunk = NULL;
 	struct cnxk_tim_bkt *mirr_bkt;
-	struct cnxk_tim_ent *chunk;
 	struct cnxk_tim_bkt *bkt;
 	uint64_t lock_sema;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.029368069 +0000
+++ 0024-event-cnxk-fix-uninitialized-local-variables.patch	2022-03-01 10:41:01.273244091 +0000
@@ -1 +1 @@
-From de3f033e5462fb1a0cad3c94c51fd79b5bf1b33f Mon Sep 17 00:00:00 2001
+From fec66e64e5a90aff71931d728cf6adb349b344a6 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit de3f033e5462fb1a0cad3c94c51fd79b5bf1b33f ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'crypto/ipsec_mb: remove useless check' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (22 preceding siblings ...)
  2022-03-01 10:41 ` patch 'event/cnxk: fix uninitialized local variables' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'cryptodev: fix RSA key type name' " Kevin Traynor
                   ` (78 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Ciara Power; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From c8bcbe8b682c1a894dc2e632a584d215e4950b7b Mon Sep 17 00:00:00 2001
From: Ciara Power <ciara.power@intel.com>
Date: Tue, 15 Feb 2022 11:07:58 +0000
Subject: [PATCH] crypto/ipsec_mb: remove useless check

[ upstream commit f819a1629b1ccc9ed74e17374e26507a490058ac ]

The qp is never NULL when it reaches the qp_setup_cleanup error handling
code. This is due to checks earlier in the function that return an error
if qp is NULL.

Coverity issue: 375013
Fixes: 581c39b1cb7d ("crypto/ipsec_mb: fix queue cleanup null pointer dereference")

Signed-off-by: Ciara Power <ciara.power@intel.com>
---
 drivers/crypto/ipsec_mb/ipsec_mb_ops.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/crypto/ipsec_mb/ipsec_mb_ops.c b/drivers/crypto/ipsec_mb/ipsec_mb_ops.c
index 1ebd23e8f0..58ea4ee476 100644
--- a/drivers/crypto/ipsec_mb/ipsec_mb_ops.c
+++ b/drivers/crypto/ipsec_mb/ipsec_mb_ops.c
@@ -286,6 +286,4 @@ ipsec_mb_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
 
 qp_setup_cleanup:
-	if (qp == NULL)
-		return ret;
 #if IMB_VERSION(1, 1, 0) > IMB_VERSION_NUM
 	if (qp->mb_mgr)
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.051013528 +0000
+++ 0025-crypto-ipsec_mb-remove-useless-check.patch	2022-03-01 10:41:01.273244091 +0000
@@ -1 +1 @@
-From f819a1629b1ccc9ed74e17374e26507a490058ac Mon Sep 17 00:00:00 2001
+From c8bcbe8b682c1a894dc2e632a584d215e4950b7b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit f819a1629b1ccc9ed74e17374e26507a490058ac ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 1cf37e9836..7e8396b4a3 100644
+index 1ebd23e8f0..58ea4ee476 100644
@@ -23 +24 @@
-@@ -285,6 +285,4 @@ ipsec_mb_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,
+@@ -286,6 +286,4 @@ ipsec_mb_qp_setup(struct rte_cryptodev *dev, uint16_t qp_id,


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

* patch 'cryptodev: fix RSA key type name' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (23 preceding siblings ...)
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: remove useless check' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'examples/ipsec-secgw: fix buffer freeing in vector mode' " Kevin Traynor
                   ` (77 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Arek Kusztal; +Cc: Akhil Goyal, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From f092922c3674c6b5fa5e9b6806abc9dbdf0e106c Mon Sep 17 00:00:00 2001
From: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Date: Fri, 18 Feb 2022 07:53:32 +0000
Subject: [PATCH] cryptodev: fix RSA key type name

[ upstream commit 3387912f5cacd934594f2c7a0c34eda7279419a8 ]

This patch fixes misspelled RTE_RSA_KEY_TYPE_QT,
this will prevent checkpach from complaining wherever
change to RSA is being made.

Fixes: 26008aaed14c ("cryptodev: add asymmetric xform and op definitions")

Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
---
 app/test/test_cryptodev_asym.c             | 2 +-
 app/test/test_cryptodev_rsa_test_vectors.h | 2 +-
 drivers/crypto/qat/qat_asym.c              | 4 ++--
 lib/cryptodev/rte_crypto_asym.h            | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c
index 9d19a6d6d9..1131290e88 100644
--- a/app/test/test_cryptodev_asym.c
+++ b/app/test/test_cryptodev_asym.c
@@ -559,5 +559,5 @@ test_one_case(const void *test_case, int sessionless)
 							&testsuite_params,
 							&tc, test_msg, sessionless, i,
-							RTE_RSA_KET_TYPE_QT);
+							RTE_RSA_KEY_TYPE_QT);
 					}
 					if (status)
diff --git a/app/test/test_cryptodev_rsa_test_vectors.h b/app/test/test_cryptodev_rsa_test_vectors.h
index 48a72e1492..04539a1ecf 100644
--- a/app/test/test_cryptodev_rsa_test_vectors.h
+++ b/app/test/test_cryptodev_rsa_test_vectors.h
@@ -379,5 +379,5 @@ struct rte_crypto_asym_xform rsa_xform_crt = {
 			.length = sizeof(rsa_e)
 		},
-		.key_type = RTE_RSA_KET_TYPE_QT,
+		.key_type = RTE_RSA_KEY_TYPE_QT,
 		.qt = {
 			.p = {
diff --git a/drivers/crypto/qat/qat_asym.c b/drivers/crypto/qat/qat_asym.c
index 09d8761c5f..bd0bf5f0cb 100644
--- a/drivers/crypto/qat/qat_asym.c
+++ b/drivers/crypto/qat/qat_asym.c
@@ -98,5 +98,5 @@ static void qat_clear_arrays_by_alg(struct qat_asym_op_cookie *cookie,
 				QAT_ASYM_MODINV_NUM_OUT_PARAMS, alg_size);
 	else if (xform->xform_type == RTE_CRYPTO_ASYM_XFORM_RSA) {
-		if (xform->rsa.key_type == RTE_RSA_KET_TYPE_QT)
+		if (xform->rsa.key_type == RTE_RSA_KEY_TYPE_QT)
 			qat_clear_arrays_crt(cookie, alg_size);
 		else {
@@ -371,5 +371,5 @@ qat_asym_fill_arrays(struct rte_crypto_asym_op *asym_op,
 				}
 			}
-			if (xform->rsa.key_type == RTE_RSA_KET_TYPE_QT) {
+			if (xform->rsa.key_type == RTE_RSA_KEY_TYPE_QT) {
 
 				qat_req->input_param_count =
diff --git a/lib/cryptodev/rte_crypto_asym.h b/lib/cryptodev/rte_crypto_asym.h
index 9c866f553f..9c5bb9233a 100644
--- a/lib/cryptodev/rte_crypto_asym.h
+++ b/lib/cryptodev/rte_crypto_asym.h
@@ -147,5 +147,5 @@ enum rte_crypto_rsa_priv_key_type {
 	RTE_RSA_KEY_TYPE_EXP,
 	/**< RSA private key is an exponent */
-	RTE_RSA_KET_TYPE_QT,
+	RTE_RSA_KEY_TYPE_QT,
 	/**< RSA private key is in quintuple format
 	 * See rte_crypto_rsa_priv_key_qt
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.073161922 +0000
+++ 0026-cryptodev-fix-RSA-key-type-name.patch	2022-03-01 10:41:01.277244092 +0000
@@ -1 +1 @@
-From 3387912f5cacd934594f2c7a0c34eda7279419a8 Mon Sep 17 00:00:00 2001
+From f092922c3674c6b5fa5e9b6806abc9dbdf0e106c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3387912f5cacd934594f2c7a0c34eda7279419a8 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index 7cda8bb081..573af2a537 100644
+index 9d19a6d6d9..1131290e88 100644
@@ -26 +27 @@
-@@ -550,5 +550,5 @@ test_one_case(const void *test_case, int sessionless)
+@@ -559,5 +559,5 @@ test_one_case(const void *test_case, int sessionless)
@@ -45 +46 @@
-index f46eefd4b3..27ce0337a7 100644
+index 09d8761c5f..bd0bf5f0cb 100644
@@ -63 +64 @@
-index 2eb0f001e3..cd24d4b07b 100644
+index 9c866f553f..9c5bb9233a 100644
@@ -66 +67 @@
-@@ -146,5 +146,5 @@ enum rte_crypto_rsa_priv_key_type {
+@@ -147,5 +147,5 @@ enum rte_crypto_rsa_priv_key_type {


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

* patch 'examples/ipsec-secgw: fix buffer freeing in vector mode' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (24 preceding siblings ...)
  2022-03-01 10:41 ` patch 'cryptodev: fix RSA key type name' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'doc: fix FIPS guide' " Kevin Traynor
                   ` (76 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Nithin Dabilpuram; +Cc: Akhil Goyal, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From ad76dc4e91a5efa1cb6583e5ec1f3fc7b471fa29 Mon Sep 17 00:00:00 2001
From: Nithin Dabilpuram <ndabilpuram@marvell.com>
Date: Wed, 23 Feb 2022 15:23:52 +0530
Subject: [PATCH] examples/ipsec-secgw: fix buffer freeing in vector mode

[ upstream commit 5fb245ba6d8234f10a785d00f63434545a1ddc48 ]

Fix packet processing to skip after mbuf is freed instead of
touching and Tx'ing it.

Also free vector event buffer in event worker when after processing
there is no pkt to be enqueued to Tx adapter.

Fixes: 86738ebe1e3d ("examples/ipsec-secgw: support event vector")

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
---
 examples/ipsec-secgw/ipsec_worker.c | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

diff --git a/examples/ipsec-secgw/ipsec_worker.c b/examples/ipsec-secgw/ipsec_worker.c
index 7419e85db2..5fe91b62e4 100644
--- a/examples/ipsec-secgw/ipsec_worker.c
+++ b/examples/ipsec-secgw/ipsec_worker.c
@@ -206,10 +206,14 @@ check_sp_sa_bulk(struct sp_ctx *sp, struct sa_ctx *sa_ctx,
 		else {
 			sa = *(struct ipsec_sa **)rte_security_dynfield(m);
-			if (sa == NULL)
+			if (sa == NULL) {
 				free_pkts(&m, 1);
+				continue;
+			}
 
 			/* SPI on the packet should match with the one in SA */
-			if (unlikely(sa->spi != sa_ctx->sa[res - 1].spi))
+			if (unlikely(sa->spi != sa_ctx->sa[res - 1].spi)) {
 				free_pkts(&m, 1);
+				continue;
+			}
 
 			ip->pkts[j++] = m;
@@ -536,4 +540,5 @@ ipsec_ev_route_pkts(struct rte_event_vector *vec, struct route_table *rt,
 				RTE_LOG(ERR, IPSEC, "SA type not supported\n");
 				free_pkts(&pkt, 1);
+				continue;
 			}
 			rte_security_set_pkt_metadata(sess->security.ctx,
@@ -694,9 +699,11 @@ ipsec_ev_vector_process(struct lcore_conf_ev_tx_int_port_wrkr *lconf,
 						       &lconf->rt, vec);
 
-	if (ret > 0) {
+	if (likely(ret > 0)) {
 		vec->nb_elem = ret;
 		rte_event_eth_tx_adapter_enqueue(links[0].eventdev_id,
 						 links[0].event_port_id,
 						 ev, 1, 0);
+	} else {
+		rte_mempool_put(rte_mempool_from_obj(vec), vec);
 	}
 }
@@ -719,4 +726,6 @@ ipsec_ev_vector_drv_mode_process(struct eh_event_link_info *links,
 						 links[0].event_port_id,
 						 ev, 1, 0);
+	else
+		rte_mempool_put(rte_mempool_from_obj(vec), vec);
 }
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.098834028 +0000
+++ 0027-examples-ipsec-secgw-fix-buffer-freeing-in-vector-mo.patch	2022-03-01 10:41:01.278244093 +0000
@@ -1 +1 @@
-From 5fb245ba6d8234f10a785d00f63434545a1ddc48 Mon Sep 17 00:00:00 2001
+From ad76dc4e91a5efa1cb6583e5ec1f3fc7b471fa29 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 5fb245ba6d8234f10a785d00f63434545a1ddc48 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index e9493c56ae..8639426c5c 100644
+index 7419e85db2..5fe91b62e4 100644
@@ -42 +43 @@
-@@ -537,4 +541,5 @@ ipsec_ev_route_pkts(struct rte_event_vector *vec, struct route_table *rt,
+@@ -536,4 +540,5 @@ ipsec_ev_route_pkts(struct rte_event_vector *vec, struct route_table *rt,
@@ -48 +49 @@
-@@ -696,9 +701,11 @@ ipsec_ev_vector_process(struct lcore_conf_ev_tx_int_port_wrkr *lconf,
+@@ -694,9 +699,11 @@ ipsec_ev_vector_process(struct lcore_conf_ev_tx_int_port_wrkr *lconf,
@@ -61 +62 @@
-@@ -721,4 +728,6 @@ ipsec_ev_vector_drv_mode_process(struct eh_event_link_info *links,
+@@ -719,4 +726,6 @@ ipsec_ev_vector_drv_mode_process(struct eh_event_link_info *links,


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

* patch 'doc: fix FIPS guide' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (25 preceding siblings ...)
  2022-03-01 10:41 ` patch 'examples/ipsec-secgw: fix buffer freeing in vector mode' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'examples/l2fwd-crypto: fix port mask overflow' " Kevin Traynor
                   ` (75 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Jakub Poczatek; +Cc: Fan Zhang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/5772c7b32e7c65ccd2c0f3d1c3eb77bb044eb7dc

Thanks.

Kevin

---
From 5772c7b32e7c65ccd2c0f3d1c3eb77bb044eb7dc Mon Sep 17 00:00:00 2001
From: Jakub Poczatek <jakub.poczatek@intel.com>
Date: Wed, 9 Feb 2022 11:36:23 +0000
Subject: [PATCH] doc: fix FIPS guide

[ upstream commit 1998071cb654e06573181c9420ec3766e9518fa5 ]

Added missing step for converting SHA request files to correct
format. Replaced AES_GCM with GCM to follow the correct
naming format.

Fixes: 3d0fad56b74 ("examples/fips_validation: add crypto FIPS application")

Signed-off-by: Jakub Poczatek <jakub.poczatek@intel.com>
Acked-by: Fan Zhang <roy.fan.zhang@intel.com>
---
 doc/guides/sample_app_ug/fips_validation.rst | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/doc/guides/sample_app_ug/fips_validation.rst b/doc/guides/sample_app_ug/fips_validation.rst
index 56df434215..39baea3346 100644
--- a/doc/guides/sample_app_ug/fips_validation.rst
+++ b/doc/guides/sample_app_ug/fips_validation.rst
@@ -78,9 +78,10 @@ Compiling the Application
 
          dos2unix AES/req/*
-         dos2unix AES_GCM/req/*
+         dos2unix GCM/req/*
          dos2unix CCM/req/*
          dos2unix CMAC/req/*
          dos2unix HMAC/req/*
          dos2unix TDES/req/*
+         dos2unix SHA/req/*
 
 Running the Application
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.121391963 +0000
+++ 0028-doc-fix-FIPS-guide.patch	2022-03-01 10:41:01.278244093 +0000
@@ -1 +1 @@
-From 1998071cb654e06573181c9420ec3766e9518fa5 Mon Sep 17 00:00:00 2001
+From 5772c7b32e7c65ccd2c0f3d1c3eb77bb044eb7dc Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 1998071cb654e06573181c9420ec3766e9518fa5 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org


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

* patch 'examples/l2fwd-crypto: fix port mask overflow' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (26 preceding siblings ...)
  2022-03-01 10:41 ` patch 'doc: fix FIPS guide' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'baseband/acc100: avoid out-of-bounds access' " Kevin Traynor
                   ` (74 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Akhil Goyal, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/79247ddc0dbe3789d61051fed677ed73860848ab

Thanks.

Kevin

---
From 79247ddc0dbe3789d61051fed677ed73860848ab Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Mon, 21 Feb 2022 18:06:58 +0000
Subject: [PATCH] examples/l2fwd-crypto: fix port mask overflow

[ upstream commit aaf4ac404362752e9c8effa4641bb480187d04ec ]

Coverity flags an issue with 32-bit value. If max ethports value is
configured with a value larger than 32 there will be an issue.
Coverity issue: 375863 Unintentional integer overflow

Fixes: 387259bd6c67 ("examples/l2fwd-crypto: add sample application")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
---
 examples/l2fwd-crypto/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/l2fwd-crypto/main.c b/examples/l2fwd-crypto/main.c
index 4d9f8861af..bbdb263143 100644
--- a/examples/l2fwd-crypto/main.c
+++ b/examples/l2fwd-crypto/main.c
@@ -2720,5 +2720,5 @@ initialize_ports(struct l2fwd_crypto_options *options)
 		}
 
-		l2fwd_enabled_port_mask |= (1 << portid);
+		l2fwd_enabled_port_mask |= (1ULL << portid);
 		enabled_portcount++;
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.143189494 +0000
+++ 0029-examples-l2fwd-crypto-fix-port-mask-overflow.patch	2022-03-01 10:41:01.280244093 +0000
@@ -1 +1 @@
-From aaf4ac404362752e9c8effa4641bb480187d04ec Mon Sep 17 00:00:00 2001
+From 79247ddc0dbe3789d61051fed677ed73860848ab Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit aaf4ac404362752e9c8effa4641bb480187d04ec ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org


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

* patch 'baseband/acc100: avoid out-of-bounds access' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (27 preceding siblings ...)
  2022-03-01 10:41 ` patch 'examples/l2fwd-crypto: fix port mask overflow' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'crypto/virtio: fix " Kevin Traynor
                   ` (73 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Nicolas Chautru; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/301ee2f3787f4b7501fe91a33010a30316336b4b

Thanks.

Kevin

---
From 301ee2f3787f4b7501fe91a33010a30316336b4b Mon Sep 17 00:00:00 2001
From: Nicolas Chautru <nicolas.chautru@intel.com>
Date: Tue, 22 Feb 2022 15:43:36 -0800
Subject: [PATCH] baseband/acc100: avoid out-of-bounds access

[ upstream commit fb6996eec066dc7fa0eda951e492a65c8380d930 ]

The actual maximum number of gather pointers should have been limited

Coverity issue: 375803, 375813, 375819, 375827, 375831
Fixes: 5ad5060f8f7a ("baseband/acc100: add LDPC processing functions")

Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
---
 drivers/baseband/acc100/rte_acc100_pmd.c | 3 +--
 drivers/baseband/acc100/rte_acc100_pmd.h | 1 +
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/baseband/acc100/rte_acc100_pmd.c b/drivers/baseband/acc100/rte_acc100_pmd.c
index 1c6080f2f8..cc69c76d54 100644
--- a/drivers/baseband/acc100/rte_acc100_pmd.c
+++ b/drivers/baseband/acc100/rte_acc100_pmd.c
@@ -1461,6 +1461,5 @@ acc100_dma_fill_blk_type_in(struct acc100_dma_req_desc *desc,
 
 	while (cb_len > 0) {
-		if (next_triplet < ACC100_DMA_MAX_NUM_POINTERS &&
-				m->next != NULL) {
+		if (next_triplet < ACC100_DMA_MAX_NUM_POINTERS_IN && m->next != NULL) {
 
 			m = m->next;
diff --git a/drivers/baseband/acc100/rte_acc100_pmd.h b/drivers/baseband/acc100/rte_acc100_pmd.h
index 03ed0b3e1a..cbcece2966 100644
--- a/drivers/baseband/acc100/rte_acc100_pmd.h
+++ b/drivers/baseband/acc100/rte_acc100_pmd.h
@@ -114,4 +114,5 @@
 #define ACC100_MAX_QUEUE_DEPTH            1024
 #define ACC100_DMA_MAX_NUM_POINTERS       14
+#define ACC100_DMA_MAX_NUM_POINTERS_IN    7
 #define ACC100_DMA_DESC_PADDING           8
 #define ACC100_FCW_PADDING                12
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.166273648 +0000
+++ 0030-baseband-acc100-avoid-out-of-bounds-access.patch	2022-03-01 10:41:01.284244094 +0000
@@ -1 +1 @@
-From fb6996eec066dc7fa0eda951e492a65c8380d930 Mon Sep 17 00:00:00 2001
+From 301ee2f3787f4b7501fe91a33010a30316336b4b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit fb6996eec066dc7fa0eda951e492a65c8380d930 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index f86474f7e0..de7e4bcef4 100644
+index 1c6080f2f8..cc69c76d54 100644


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

* patch 'crypto/virtio: fix out-of-bounds access' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (28 preceding siblings ...)
  2022-03-01 10:41 ` patch 'baseband/acc100: avoid out-of-bounds access' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: check missing operation types' " Kevin Traynor
                   ` (72 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Brian Dooley; +Cc: Fan Zhang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 9c67637c8cd498e9275572170b5595c3c824015f Mon Sep 17 00:00:00 2001
From: Brian Dooley <brian.dooley@intel.com>
Date: Tue, 22 Feb 2022 09:54:51 +0000
Subject: [PATCH] crypto/virtio: fix out-of-bounds access

[ upstream commit a965e768065ae496c9a1c7a77545bc0f0f0e38e2 ]

Coverity flags an untrusted loop bound. Check length of session iv.

Coverity issue: 375802
Fixes: b063e843fa03 ("crypto/virtio: fix IV physical address")

Signed-off-by: Brian Dooley <brian.dooley@intel.com>
Acked-by: Fan Zhang <roy.fan.zhang@intel.com>
---
 drivers/crypto/virtio/virtio_rxtx.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/crypto/virtio/virtio_rxtx.c b/drivers/crypto/virtio/virtio_rxtx.c
index a65524a306..08359b3a39 100644
--- a/drivers/crypto/virtio/virtio_rxtx.c
+++ b/drivers/crypto/virtio/virtio_rxtx.c
@@ -265,4 +265,7 @@ virtqueue_crypto_sym_enqueue_xmit(
 			desc[idx].addr = cop->phys_addr + session->iv.offset;
 		else {
+			if (session->iv.length > VIRTIO_CRYPTO_MAX_IV_SIZE)
+				return -ENOMEM;
+
 			rte_memcpy(crypto_op_cookie->iv,
 					rte_crypto_op_ctod_offset(cop,
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.192034135 +0000
+++ 0031-crypto-virtio-fix-out-of-bounds-access.patch	2022-03-01 10:41:01.285244094 +0000
@@ -1 +1 @@
-From a965e768065ae496c9a1c7a77545bc0f0f0e38e2 Mon Sep 17 00:00:00 2001
+From 9c67637c8cd498e9275572170b5595c3c824015f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a965e768065ae496c9a1c7a77545bc0f0f0e38e2 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'crypto/ipsec_mb: check missing operation types' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (29 preceding siblings ...)
  2022-03-01 10:41 ` patch 'crypto/virtio: fix " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix ZUC authentication verify' " Kevin Traynor
                   ` (71 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From bbc596578afe0eba3cfb29792eae278800c4e661 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Wed, 23 Feb 2022 16:01:13 +0000
Subject: [PATCH] crypto/ipsec_mb: check missing operation types

[ upstream commit cfb566048ee729969d982a0c6020148d69f585fc ]

When processing crypto operations in ZUC PMD,
there were two operation types that were set at session level,
but not checked when the operations are enqueued and processed,
leaving the buffers untouched silently.

Fixes: cde8df1bda9d ("crypto/ipsec_mb: move zuc PMD")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 drivers/crypto/ipsec_mb/pmd_zuc.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/crypto/ipsec_mb/pmd_zuc.c b/drivers/crypto/ipsec_mb/pmd_zuc.c
index 2eae1d1ec7..ec83d96dfc 100644
--- a/drivers/crypto/ipsec_mb/pmd_zuc.c
+++ b/drivers/crypto/ipsec_mb/pmd_zuc.c
@@ -199,5 +199,5 @@ process_ops(struct rte_crypto_op **ops, enum ipsec_mb_operation op_type,
 {
 	unsigned int i;
-	unsigned int processed_ops;
+	unsigned int processed_ops = 0;
 
 	switch (op_type) {
@@ -213,4 +213,5 @@ process_ops(struct rte_crypto_op **ops, enum ipsec_mb_operation op_type,
 		break;
 	case IPSEC_MB_OP_ENCRYPT_THEN_HASH_GEN:
+	case IPSEC_MB_OP_DECRYPT_THEN_HASH_VERIFY:
 		processed_ops = process_zuc_cipher_op(qp, ops, sessions,
 				num_ops);
@@ -218,4 +219,5 @@ process_ops(struct rte_crypto_op **ops, enum ipsec_mb_operation op_type,
 		break;
 	case IPSEC_MB_OP_HASH_VERIFY_THEN_DECRYPT:
+	case IPSEC_MB_OP_HASH_GEN_THEN_ENCRYPT:
 		processed_ops = process_zuc_hash_op(qp, ops, sessions,
 				num_ops);
@@ -224,5 +226,6 @@ process_ops(struct rte_crypto_op **ops, enum ipsec_mb_operation op_type,
 	default:
 		/* Operation not supported. */
-		processed_ops = 0;
+		for (i = 0; i < num_ops; i++)
+			ops[i]->status = RTE_CRYPTO_OP_STATUS_INVALID_SESSION;
 	}
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.213507766 +0000
+++ 0032-crypto-ipsec_mb-check-missing-operation-types.patch	2022-03-01 10:41:01.285244094 +0000
@@ -1 +1 @@
-From cfb566048ee729969d982a0c6020148d69f585fc Mon Sep 17 00:00:00 2001
+From bbc596578afe0eba3cfb29792eae278800c4e661 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit cfb566048ee729969d982a0c6020148d69f585fc ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org


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

* patch 'crypto/ipsec_mb: fix ZUC authentication verify' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (30 preceding siblings ...)
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: check missing operation types' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix ZUC operation overwrite' " Kevin Traynor
                   ` (70 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/1170e24b20f8117145f05f6785afe45d1bf389f6

Thanks.

Kevin

---
From 1170e24b20f8117145f05f6785afe45d1bf389f6 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Wed, 23 Feb 2022 16:01:14 +0000
Subject: [PATCH] crypto/ipsec_mb: fix ZUC authentication verify

[ upstream commit bd3769739b3897865b1f0d2886ce1fe8a88eac75 ]

ZUC authentication is done over multiple buffers at a time.
When authentication verification is done, multiple scratch buffers
are using to generate the tags that will be compared afterwards.
However, the same scratch buffer was used always, instead of having
different ones for each crypto operation.

Fixes: 0b133c36ad7d ("crypto/zuc: support IPsec Multi-buffer lib v0.54")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 drivers/crypto/ipsec_mb/pmd_zuc.c      | 2 +-
 drivers/crypto/ipsec_mb/pmd_zuc_priv.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/crypto/ipsec_mb/pmd_zuc.c b/drivers/crypto/ipsec_mb/pmd_zuc.c
index ec83d96dfc..07cf1462d2 100644
--- a/drivers/crypto/ipsec_mb/pmd_zuc.c
+++ b/drivers/crypto/ipsec_mb/pmd_zuc.c
@@ -167,5 +167,5 @@ process_zuc_hash_op(struct ipsec_mb_qp *qp, struct rte_crypto_op **ops,
 		hash_keys[i] = sess->pKey_hash;
 		if (sess->auth_op == RTE_CRYPTO_AUTH_OP_VERIFY)
-			dst[i] = (uint32_t *)qp_data->temp_digest;
+			dst[i] = (uint32_t *)qp_data->temp_digest[i];
 		else
 			dst[i] = (uint32_t *)ops[i]->sym->auth.digest.data;
diff --git a/drivers/crypto/ipsec_mb/pmd_zuc_priv.h b/drivers/crypto/ipsec_mb/pmd_zuc_priv.h
index 46d5bfae37..76fd6758c2 100644
--- a/drivers/crypto/ipsec_mb/pmd_zuc_priv.h
+++ b/drivers/crypto/ipsec_mb/pmd_zuc_priv.h
@@ -76,5 +76,5 @@ struct zuc_session {
 struct zuc_qp_data {
 
-	uint8_t temp_digest[ZUC_DIGEST_LENGTH];
+	uint8_t temp_digest[ZUC_MAX_BURST][ZUC_DIGEST_LENGTH];
 	/* *< Buffers used to store the digest generated
 	 * by the driver when verifying a digest provided
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.235999248 +0000
+++ 0033-crypto-ipsec_mb-fix-ZUC-authentication-verify.patch	2022-03-01 10:41:01.286244094 +0000
@@ -1 +1 @@
-From bd3769739b3897865b1f0d2886ce1fe8a88eac75 Mon Sep 17 00:00:00 2001
+From 1170e24b20f8117145f05f6785afe45d1bf389f6 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit bd3769739b3897865b1f0d2886ce1fe8a88eac75 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org


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

* patch 'crypto/ipsec_mb: fix ZUC operation overwrite' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (31 preceding siblings ...)
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix ZUC authentication verify' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix length and offset settings' " Kevin Traynor
                   ` (69 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From cfa7703c8e58d2610c8ff87f0247e20cfe03597e Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Wed, 23 Feb 2022 16:01:15 +0000
Subject: [PATCH] crypto/ipsec_mb: fix ZUC operation overwrite

[ upstream commit 96d0dc2a3cd21d6f392347ae1d2ff3c21e27231a ]

ZUC PMD batches crypto operations depending on their type
(encryption + tag generation, tag verification + decryption, etc),
to allow parallelization.
The array used to store the pointers to these operations was
always the same array provided by dequeue_burst() function,
and it was looping around the same positions (from 0 to ZUC_MAX_BURST - 1).

A new internal array is used to avoid overwriting the pointers
of the array provided by dequeue_burst() function.

Fixes: cf7685d68f00 ("crypto/zuc: add driver for ZUC library")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 drivers/crypto/ipsec_mb/pmd_zuc.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/drivers/crypto/ipsec_mb/pmd_zuc.c b/drivers/crypto/ipsec_mb/pmd_zuc.c
index 07cf1462d2..e36c7092d6 100644
--- a/drivers/crypto/ipsec_mb/pmd_zuc.c
+++ b/drivers/crypto/ipsec_mb/pmd_zuc.c
@@ -260,4 +260,5 @@ zuc_pmd_dequeue_burst(void *queue_pair,
 	struct zuc_session *curr_sess;
 	struct zuc_session *sessions[ZUC_MAX_BURST];
+	struct rte_crypto_op *int_c_ops[ZUC_MAX_BURST];
 	enum ipsec_mb_operation prev_zuc_op = IPSEC_MB_OP_NOT_SUPPORTED;
 	enum ipsec_mb_operation curr_zuc_op;
@@ -291,9 +292,9 @@ zuc_pmd_dequeue_burst(void *queue_pair,
 		if (burst_size == 0) {
 			prev_zuc_op = curr_zuc_op;
-			c_ops[0] = curr_c_op;
+			int_c_ops[0] = curr_c_op;
 			sessions[0] = curr_sess;
 			burst_size++;
 		} else if (curr_zuc_op == prev_zuc_op) {
-			c_ops[burst_size] = curr_c_op;
+			int_c_ops[burst_size] = curr_c_op;
 			sessions[burst_size] = curr_sess;
 			burst_size++;
@@ -303,5 +304,5 @@ zuc_pmd_dequeue_burst(void *queue_pair,
 			 */
 			if (burst_size == ZUC_MAX_BURST) {
-				processed_ops = process_ops(c_ops, curr_zuc_op,
+				processed_ops = process_ops(int_c_ops, curr_zuc_op,
 						sessions, qp, burst_size);
 				if (processed_ops < burst_size) {
@@ -317,5 +318,5 @@ zuc_pmd_dequeue_burst(void *queue_pair,
 			 * of the previous type.
 			 */
-			processed_ops = process_ops(c_ops, prev_zuc_op,
+			processed_ops = process_ops(int_c_ops, prev_zuc_op,
 					sessions, qp, burst_size);
 			if (processed_ops < burst_size) {
@@ -327,5 +328,5 @@ zuc_pmd_dequeue_burst(void *queue_pair,
 			prev_zuc_op = curr_zuc_op;
 
-			c_ops[0] = curr_c_op;
+			int_c_ops[0] = curr_c_op;
 			sessions[0] = curr_sess;
 			burst_size++;
@@ -335,5 +336,5 @@ zuc_pmd_dequeue_burst(void *queue_pair,
 	if (burst_size != 0) {
 		/* Process the crypto ops of the last operation type. */
-		processed_ops = process_ops(c_ops, prev_zuc_op,
+		processed_ops = process_ops(int_c_ops, prev_zuc_op,
 				sessions, qp, burst_size);
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.257350828 +0000
+++ 0034-crypto-ipsec_mb-fix-ZUC-operation-overwrite.patch	2022-03-01 10:41:01.286244094 +0000
@@ -1 +1 @@
-From 96d0dc2a3cd21d6f392347ae1d2ff3c21e27231a Mon Sep 17 00:00:00 2001
+From cfa7703c8e58d2610c8ff87f0247e20cfe03597e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 96d0dc2a3cd21d6f392347ae1d2ff3c21e27231a ]
+
@@ -17 +18,0 @@
-Cc: stable@dpdk.org


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

* patch 'crypto/ipsec_mb: fix length and offset settings' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (32 preceding siblings ...)
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix ZUC operation overwrite' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/nfb: fix array indexes in deinit functions' " Kevin Traynor
                   ` (68 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From daf06c45e8576d8a2a86455e33e2bc4574f8f8b4 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Wed, 23 Feb 2022 16:01:16 +0000
Subject: [PATCH] crypto/ipsec_mb: fix length and offset settings

[ upstream commit a501609ea6466ed8526c0dfadedee332a4d4a451 ]

KASUMI, SNOW3G and ZUC require lengths and offsets to
be set in bits or bytes depending on the algorithm.
There were some algorithms that were mixing these two,
so this commit is fixing this issue.

Fixes: ae8e085c608d ("crypto/aesni_mb: support KASUMI F8/F9")
Fixes: 6c42e0cf4d12 ("crypto/aesni_mb: support SNOW3G-UEA2/UIA2")
Fixes: fd8df85487c4 ("crypto/aesni_mb: support ZUC-EEA3/EIA3")
Fixes: 8c835018de84 ("crypto/ipsec_mb: support ZUC-256 for aesni_mb")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 drivers/crypto/ipsec_mb/pmd_aesni_mb.c | 93 ++++++++++++++++----------
 1 file changed, 57 insertions(+), 36 deletions(-)

diff --git a/drivers/crypto/ipsec_mb/pmd_aesni_mb.c b/drivers/crypto/ipsec_mb/pmd_aesni_mb.c
index a308d42ffa..748382320b 100644
--- a/drivers/crypto/ipsec_mb/pmd_aesni_mb.c
+++ b/drivers/crypto/ipsec_mb/pmd_aesni_mb.c
@@ -919,5 +919,7 @@ error_exit:
 static inline uint64_t
 auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
-		uint32_t oop)
+		uint32_t oop, const uint32_t auth_offset,
+		const uint32_t cipher_offset, const uint32_t auth_length,
+		const uint32_t cipher_length)
 {
 	struct rte_mbuf *m_src, *m_dst;
@@ -928,5 +930,5 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
 	/* Only cipher then hash needs special calculation. */
 	if (!oop || session->chain_order != IMB_ORDER_CIPHER_HASH)
-		return op->sym->auth.data.offset;
+		return auth_offset;
 
 	m_src = op->sym->m_src;
@@ -936,5 +938,5 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
 	p_dst = rte_pktmbuf_mtod(m_dst, uint8_t *);
 	u_src = (uintptr_t)p_src;
-	u_dst = (uintptr_t)p_dst + op->sym->auth.data.offset;
+	u_dst = (uintptr_t)p_dst + auth_offset;
 
 	/**
@@ -942,9 +944,9 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
 	 * correct digest.
 	 */
-	if (op->sym->cipher.data.offset > op->sym->auth.data.offset)
-		memcpy(p_dst + op->sym->auth.data.offset,
-				p_src + op->sym->auth.data.offset,
-				op->sym->cipher.data.offset -
-				op->sym->auth.data.offset);
+	if (cipher_offset > auth_offset)
+		memcpy(p_dst + auth_offset,
+				p_src + auth_offset,
+				cipher_offset -
+				auth_offset);
 
 	/**
@@ -952,6 +954,6 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
 	 * length) for generating correct digest
 	 */
-	cipher_end = op->sym->cipher.data.offset + op->sym->cipher.data.length;
-	auth_end = op->sym->auth.data.offset + op->sym->auth.data.length;
+	cipher_end = cipher_offset + cipher_length;
+	auth_end = auth_offset + auth_length;
 	if (cipher_end < auth_end)
 		memcpy(p_dst + cipher_end, p_src + cipher_end,
@@ -1100,4 +1102,8 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 	struct aesni_mb_session *session;
 	uint32_t m_offset, oop;
+	uint32_t auth_off_in_bytes;
+	uint32_t ciph_off_in_bytes;
+	uint32_t auth_len_in_bytes;
+	uint32_t ciph_len_in_bytes;
 
 	session = ipsec_mb_get_session_private(qp, op);
@@ -1208,4 +1214,5 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 		job->enc_keys = session->cipher.zuc_cipher_key;
 		job->dec_keys = session->cipher.zuc_cipher_key;
+		m_offset >>= 3;
 	} else if (job->cipher_mode == IMB_CIPHER_SNOW3G_UEA2_BITLEN) {
 		job->enc_keys = &session->cipher.pKeySched_snow3g_cipher;
@@ -1265,7 +1272,4 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 	switch (job->hash_alg) {
 	case IMB_AUTH_AES_CCM:
-		job->cipher_start_src_offset_in_bytes =
-				op->sym->aead.data.offset;
-		job->msg_len_to_cipher_in_bytes = op->sym->aead.data.length;
 		job->hash_start_src_offset_in_bytes = op->sym->aead.data.offset;
 		job->msg_len_to_hash_in_bytes = op->sym->aead.data.length;
@@ -1277,17 +1281,9 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 	case IMB_AUTH_AES_GMAC:
 		if (session->cipher.mode == IMB_CIPHER_GCM) {
-			job->cipher_start_src_offset_in_bytes =
-					op->sym->aead.data.offset;
 			job->hash_start_src_offset_in_bytes =
 					op->sym->aead.data.offset;
-			job->msg_len_to_cipher_in_bytes =
-					op->sym->aead.data.length;
 			job->msg_len_to_hash_in_bytes =
 					op->sym->aead.data.length;
 		} else {
-			job->cipher_start_src_offset_in_bytes =
-					op->sym->auth.data.offset;
-			job->hash_start_src_offset_in_bytes =
-					op->sym->auth.data.offset;
 			job->msg_len_to_cipher_in_bytes = 0;
 			job->msg_len_to_hash_in_bytes = 0;
@@ -1299,10 +1295,6 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 
 	case IMB_AUTH_CHACHA20_POLY1305:
-		job->cipher_start_src_offset_in_bytes =
-			op->sym->aead.data.offset;
 		job->hash_start_src_offset_in_bytes =
 			op->sym->aead.data.offset;
-		job->msg_len_to_cipher_in_bytes =
-				op->sym->aead.data.length;
 		job->msg_len_to_hash_in_bytes =
 					op->sym->aead.data.length;
@@ -1311,12 +1303,46 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 				session->iv.offset);
 		break;
+	/* ZUC and SNOW3G require length in bits and offset in bytes */
+	case IMB_AUTH_ZUC_EIA3_BITLEN:
+	case IMB_AUTH_ZUC256_EIA3_BITLEN:
+	case IMB_AUTH_SNOW3G_UIA2_BITLEN:
+		auth_off_in_bytes = op->sym->auth.data.offset >> 3;
+		ciph_off_in_bytes = op->sym->cipher.data.offset >> 3;
+		auth_len_in_bytes = op->sym->auth.data.length >> 3;
+		ciph_len_in_bytes = op->sym->cipher.data.length >> 3;
+
+		job->hash_start_src_offset_in_bytes = auth_start_offset(op,
+				session, oop, auth_off_in_bytes,
+				ciph_off_in_bytes, auth_len_in_bytes,
+				ciph_len_in_bytes);
+		job->msg_len_to_hash_in_bits = op->sym->auth.data.length;
+
+		job->iv = rte_crypto_op_ctod_offset(op, uint8_t *,
+			session->iv.offset);
+		break;
+
+	/* KASUMI requires lengths and offset in bytes */
+	case IMB_AUTH_KASUMI_UIA1:
+		auth_off_in_bytes = op->sym->auth.data.offset >> 3;
+		ciph_off_in_bytes = op->sym->cipher.data.offset >> 3;
+		auth_len_in_bytes = op->sym->auth.data.length >> 3;
+		ciph_len_in_bytes = op->sym->cipher.data.length >> 3;
+
+		job->hash_start_src_offset_in_bytes = auth_start_offset(op,
+				session, oop, auth_off_in_bytes,
+				ciph_off_in_bytes, auth_len_in_bytes,
+				ciph_len_in_bytes);
+		job->msg_len_to_hash_in_bytes = auth_len_in_bytes;
+
+		job->iv = rte_crypto_op_ctod_offset(op, uint8_t *,
+			session->iv.offset);
+		break;
+
 	default:
-		/* For SNOW3G, length and offsets are already in bits */
-		job->cipher_start_src_offset_in_bytes =
-				op->sym->cipher.data.offset;
-		job->msg_len_to_cipher_in_bytes = op->sym->cipher.data.length;
-
 		job->hash_start_src_offset_in_bytes = auth_start_offset(op,
-				session, oop);
+				session, oop, op->sym->auth.data.offset,
+				op->sym->cipher.data.offset,
+				op->sym->auth.data.length,
+				op->sym->cipher.data.length);
 		job->msg_len_to_hash_in_bytes = op->sym->auth.data.length;
 
@@ -1325,9 +1351,4 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
 	}
 
-	if (job->cipher_mode == IMB_CIPHER_ZUC_EEA3)
-		job->msg_len_to_cipher_in_bytes >>= 3;
-	else if (job->hash_alg == IMB_AUTH_KASUMI_UIA1)
-		job->msg_len_to_hash_in_bytes >>= 3;
-
 	/* Set user data to be crypto operation data struct */
 	job->user_data = op;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.279858967 +0000
+++ 0035-crypto-ipsec_mb-fix-length-and-offset-settings.patch	2022-03-01 10:41:01.288244095 +0000
@@ -1 +1 @@
-From a501609ea6466ed8526c0dfadedee332a4d4a451 Mon Sep 17 00:00:00 2001
+From daf06c45e8576d8a2a86455e33e2bc4574f8f8b4 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a501609ea6466ed8526c0dfadedee332a4d4a451 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -19,2 +20,2 @@
- drivers/crypto/ipsec_mb/pmd_aesni_mb.c | 122 +++++++++++++++++--------
- 1 file changed, 86 insertions(+), 36 deletions(-)
+ drivers/crypto/ipsec_mb/pmd_aesni_mb.c | 93 ++++++++++++++++----------
+ 1 file changed, 57 insertions(+), 36 deletions(-)
@@ -23 +24 @@
-index 0111c6f540..c974886032 100644
+index a308d42ffa..748382320b 100644
@@ -26 +27 @@
-@@ -931,5 +931,7 @@ error_exit:
+@@ -919,5 +919,7 @@ error_exit:
@@ -35 +36 @@
-@@ -940,5 +942,5 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
+@@ -928,5 +930,5 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
@@ -42 +43 @@
-@@ -948,5 +950,5 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
+@@ -936,5 +938,5 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
@@ -49 +50 @@
-@@ -954,9 +956,9 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
+@@ -942,9 +944,9 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
@@ -64 +65 @@
-@@ -964,6 +966,6 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
+@@ -952,6 +954,6 @@ auth_start_offset(struct rte_crypto_op *op, struct aesni_mb_session *session,
@@ -73 +74 @@
-@@ -1112,4 +1114,8 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1100,4 +1102,8 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
@@ -82 +83 @@
-@@ -1220,4 +1226,5 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1208,4 +1214,5 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
@@ -88 +89 @@
-@@ -1277,7 +1284,4 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1265,7 +1272,4 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
@@ -96 +97 @@
-@@ -1289,17 +1293,9 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1277,17 +1281,9 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
@@ -114 +115 @@
-@@ -1311,10 +1307,6 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1299,10 +1295,6 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
@@ -125 +126 @@
-@@ -1323,12 +1315,46 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1311,12 +1303,46 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
@@ -178,35 +179 @@
-@@ -1337,4 +1363,33 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
- 	}
- 
-+	switch (job->cipher_mode) {
-+	/* ZUC requires length and offset in bytes */
-+	case IMB_CIPHER_ZUC_EEA3:
-+		job->cipher_start_src_offset_in_bytes =
-+					op->sym->cipher.data.offset >> 3;
-+		job->msg_len_to_cipher_in_bytes =
-+					op->sym->cipher.data.length >> 3;
-+		break;
-+	/* ZUC and SNOW3G require length and offset in bits */
-+	case IMB_CIPHER_SNOW3G_UEA2_BITLEN:
-+	case IMB_CIPHER_KASUMI_UEA1_BITLEN:
-+		job->cipher_start_src_offset_in_bits =
-+					op->sym->cipher.data.offset;
-+		job->msg_len_to_cipher_in_bits =
-+					op->sym->cipher.data.length;
-+		break;
-+	case IMB_CIPHER_CCM:
-+	case IMB_CIPHER_GCM:
-+	case IMB_CIPHER_CHACHA20_POLY1305:
-+		job->cipher_start_src_offset_in_bytes =
-+				op->sym->aead.data.offset;
-+		job->msg_len_to_cipher_in_bytes = op->sym->aead.data.length;
-+		break;
-+	default:
-+		job->cipher_start_src_offset_in_bytes =
-+					op->sym->cipher.data.offset;
-+		job->msg_len_to_cipher_in_bytes = op->sym->cipher.data.length;
-+	}
-+
- 	if (job->cipher_mode == IMB_CIPHER_NULL && oop) {
- 		memcpy(job->dst + job->cipher_start_src_offset_in_bytes,
-@@ -1343,9 +1398,4 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,
+@@ -1325,9 +1351,4 @@ set_mb_job_params(IMB_JOB *job, struct ipsec_mb_qp *qp,


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

* patch 'net/nfb: fix array indexes in deinit functions' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (33 preceding siblings ...)
  2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix length and offset settings' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/nfb: fix multicast/promiscuous mode switching' " Kevin Traynor
                   ` (67 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Martin Spinler; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From afe8e58fed1606d67a88281a184e77ce1c538c01 Mon Sep 17 00:00:00 2001
From: Martin Spinler <spinler@cesnet.cz>
Date: Tue, 15 Feb 2022 13:55:39 +0100
Subject: [PATCH] net/nfb: fix array indexes in deinit functions

[ upstream commit 8a4c8edb1154a58bad807cdc2ca947773e2ee8f1 ]

The indexes in the for cycle were wrongly used and
the code accessed outside of the rxmac/txmac array.

Fixes: 6435f9a0ac22 ("net/nfb: add new netcope driver")

Signed-off-by: Martin Spinler <spinler@cesnet.cz>
---
 drivers/net/nfb/nfb_ethdev.c | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/drivers/net/nfb/nfb_ethdev.c b/drivers/net/nfb/nfb_ethdev.c
index 3c39937816..0b27fe78cc 100644
--- a/drivers/net/nfb/nfb_ethdev.c
+++ b/drivers/net/nfb/nfb_ethdev.c
@@ -78,7 +78,8 @@ nfb_nc_rxmac_deinit(struct nc_rxmac *rxmac[RTE_MAX_NC_RXMAC],
 	uint16_t max_rxmac)
 {
-	for (; max_rxmac > 0; --max_rxmac) {
-		nc_rxmac_close(rxmac[max_rxmac]);
-		rxmac[max_rxmac] = NULL;
+	uint16_t i;
+	for (i = 0; i < max_rxmac; i++) {
+		nc_rxmac_close(rxmac[i]);
+		rxmac[i] = NULL;
 	}
 }
@@ -96,7 +97,8 @@ nfb_nc_txmac_deinit(struct nc_txmac *txmac[RTE_MAX_NC_TXMAC],
 	uint16_t max_txmac)
 {
-	for (; max_txmac > 0; --max_txmac) {
-		nc_txmac_close(txmac[max_txmac]);
-		txmac[max_txmac] = NULL;
+	uint16_t i;
+	for (i = 0; i < max_txmac; i++) {
+		nc_txmac_close(txmac[i]);
+		txmac[i] = NULL;
 	}
 }
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.303000685 +0000
+++ 0036-net-nfb-fix-array-indexes-in-deinit-functions.patch	2022-03-01 10:41:01.289244095 +0000
@@ -1 +1 @@
-From 8a4c8edb1154a58bad807cdc2ca947773e2ee8f1 Mon Sep 17 00:00:00 2001
+From afe8e58fed1606d67a88281a184e77ce1c538c01 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 8a4c8edb1154a58bad807cdc2ca947773e2ee8f1 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/nfb: fix multicast/promiscuous mode switching' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (34 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/nfb: fix array indexes in deinit functions' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/ixgbe: reset security context pointer on close' " Kevin Traynor
                   ` (66 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Martin Spinler; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/967cb497480d8cefb63eec51b4705ce647175ff8

Thanks.

Kevin

---
From 967cb497480d8cefb63eec51b4705ce647175ff8 Mon Sep 17 00:00:00 2001
From: Martin Spinler <spinler@cesnet.cz>
Date: Tue, 15 Feb 2022 13:55:42 +0100
Subject: [PATCH] net/nfb: fix multicast/promiscuous mode switching

[ upstream commit 6685343c4805fcae80bad449903d848409193bd8 ]

In the firmware, the promisc mode overrides the multicast mode.
So when the promisc mode is turned off, driver must check if the
multicast mode was active before and conditionally reactivate it.

Fixes: 6435f9a0ac22 ("net/nfb: add new netcope driver")

Signed-off-by: Martin Spinler <spinler@cesnet.cz>
---
 drivers/net/nfb/nfb.h        |  4 ----
 drivers/net/nfb/nfb_ethdev.c |  1 -
 drivers/net/nfb/nfb_rxmode.c | 20 ++++++++------------
 3 files changed, 8 insertions(+), 17 deletions(-)

diff --git a/drivers/net/nfb/nfb.h b/drivers/net/nfb/nfb.h
index 59d3ab4986..96c44c3a45 100644
--- a/drivers/net/nfb/nfb.h
+++ b/drivers/net/nfb/nfb.h
@@ -49,8 +49,4 @@ struct pmd_internals {
 	char             nfb_dev[PATH_MAX];
 	struct nfb_device *nfb;
-	/* Place to remember if filter was promiscuous or filtering by table,
-	 * when disabling allmulticast
-	 */
-	enum nc_rxmac_mac_filter rx_filter_original;
 };
 
diff --git a/drivers/net/nfb/nfb_ethdev.c b/drivers/net/nfb/nfb_ethdev.c
index 0b27fe78cc..d9e43bc027 100644
--- a/drivers/net/nfb/nfb_ethdev.c
+++ b/drivers/net/nfb/nfb_ethdev.c
@@ -517,5 +517,4 @@ nfb_eth_dev_init(struct rte_eth_dev *dev)
 	data->promiscuous = nfb_eth_promiscuous_get(dev);
 	data->all_multicast = nfb_eth_allmulticast_get(dev);
-	internals->rx_filter_original = data->promiscuous;
 
 	dev->data->dev_flags |= RTE_ETH_DEV_AUTOFILL_QUEUE_XSTATS;
diff --git a/drivers/net/nfb/nfb_rxmode.c b/drivers/net/nfb/nfb_rxmode.c
index 2d0b613d21..ca6e4d5578 100644
--- a/drivers/net/nfb/nfb_rxmode.c
+++ b/drivers/net/nfb/nfb_rxmode.c
@@ -15,6 +15,4 @@ nfb_eth_promiscuous_enable(struct rte_eth_dev *dev)
 	uint16_t i;
 
-	internals->rx_filter_original = RXMAC_MAC_FILTER_PROMISCUOUS;
-
 	for (i = 0; i < internals->max_rxmac; ++i) {
 		nc_rxmac_mac_filter_enable(internals->rxmac[i],
@@ -31,14 +29,11 @@ nfb_eth_promiscuous_disable(struct rte_eth_dev *dev)
 		dev->data->dev_private;
 	uint16_t i;
+	enum nc_rxmac_mac_filter filter = RXMAC_MAC_FILTER_TABLE_BCAST;
 
-	internals->rx_filter_original = RXMAC_MAC_FILTER_TABLE;
-
-	/* if promisc is not enabled, do nothing */
-	if (!nfb_eth_promiscuous_get(dev))
-		return 0;
+	if (dev->data->all_multicast)
+		filter = RXMAC_MAC_FILTER_TABLE_BCAST_MCAST;
 
 	for (i = 0; i < internals->max_rxmac; ++i) {
-		nc_rxmac_mac_filter_enable(internals->rxmac[i],
-			RXMAC_MAC_FILTER_TABLE);
+		nc_rxmac_mac_filter_enable(internals->rxmac[i], filter);
 	}
 
@@ -68,4 +63,6 @@ nfb_eth_allmulticast_enable(struct rte_eth_dev *dev)
 
 	uint16_t i;
+	if (dev->data->promiscuous)
+		return 0;
 	for (i = 0; i < internals->max_rxmac; ++i) {
 		nc_rxmac_mac_filter_enable(internals->rxmac[i],
@@ -84,11 +81,10 @@ nfb_eth_allmulticast_disable(struct rte_eth_dev *dev)
 	uint16_t i;
 
-	/* if multicast is not enabled do nothing */
-	if (!nfb_eth_allmulticast_get(dev))
+	if (dev->data->promiscuous)
 		return 0;
 
 	for (i = 0; i < internals->max_rxmac; ++i) {
 		nc_rxmac_mac_filter_enable(internals->rxmac[i],
-			internals->rx_filter_original);
+			RXMAC_MAC_FILTER_TABLE_BCAST);
 	}
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.325049159 +0000
+++ 0037-net-nfb-fix-multicast-promiscuous-mode-switching.patch	2022-03-01 10:41:01.290244095 +0000
@@ -1 +1 @@
-From 6685343c4805fcae80bad449903d848409193bd8 Mon Sep 17 00:00:00 2001
+From 967cb497480d8cefb63eec51b4705ce647175ff8 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6685343c4805fcae80bad449903d848409193bd8 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 4de9006ac0..7dc5bd29e4 100644
+index 59d3ab4986..96c44c3a45 100644
@@ -24 +25 @@
-@@ -48,8 +48,4 @@ struct pmd_internals {
+@@ -49,8 +49,4 @@ struct pmd_internals {
@@ -34 +35 @@
-index 53a98642b3..5d503e131a 100644
+index 0b27fe78cc..d9e43bc027 100644
@@ -37 +38 @@
-@@ -535,5 +535,4 @@ nfb_eth_dev_init(struct rte_eth_dev *dev)
+@@ -517,5 +517,4 @@ nfb_eth_dev_init(struct rte_eth_dev *dev)


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

* patch 'net/ixgbe: reset security context pointer on close' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (35 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/nfb: fix multicast/promiscuous mode switching' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/txgbe: " Kevin Traynor
                   ` (65 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Yunjian Wang; +Cc: Haiyue Wang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/223010f1da4421945201d5fe2119097dc6411b01

Thanks.

Kevin

---
From 223010f1da4421945201d5fe2119097dc6411b01 Mon Sep 17 00:00:00 2001
From: Yunjian Wang <wangyunjian@huawei.com>
Date: Tue, 15 Feb 2022 21:01:51 +0800
Subject: [PATCH] net/ixgbe: reset security context pointer on close

[ upstream commit 848a37cead7bd604d51b5f04507fea3e59e9088e ]

When ixgbe_dev_close() is cleaning up, it does not correctly set
the security_ctx variable to NULL, which will lead to wild pointer.

Fixes: 9a0752f498d2 ("net/ixgbe: enable inline IPsec")

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Acked-by: Haiyue Wang <haiyue.wang@intel.com>
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c
index 2f4ebb4e59..d1d0bd13df 100644
--- a/drivers/net/ixgbe/ixgbe_ethdev.c
+++ b/drivers/net/ixgbe/ixgbe_ethdev.c
@@ -3043,4 +3043,5 @@ ixgbe_dev_close(struct rte_eth_dev *dev)
 #ifdef RTE_LIB_SECURITY
 	rte_free(dev->security_ctx);
+	dev->security_ctx = NULL;
 #endif
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.347297343 +0000
+++ 0038-net-ixgbe-reset-security-context-pointer-on-close.patch	2022-03-01 10:41:01.297244097 +0000
@@ -1 +1 @@
-From 848a37cead7bd604d51b5f04507fea3e59e9088e Mon Sep 17 00:00:00 2001
+From 223010f1da4421945201d5fe2119097dc6411b01 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 848a37cead7bd604d51b5f04507fea3e59e9088e ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 3d799d2187..7643842560 100644
+index 2f4ebb4e59..d1d0bd13df 100644
@@ -22 +23 @@
-@@ -3039,4 +3039,5 @@ ixgbe_dev_close(struct rte_eth_dev *dev)
+@@ -3043,4 +3043,5 @@ ixgbe_dev_close(struct rte_eth_dev *dev)


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

* patch 'net/txgbe: reset security context pointer on close' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (36 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/ixgbe: reset security context pointer on close' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/iavf: reset security context pointer on stop' " Kevin Traynor
                   ` (64 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Yunjian Wang; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/496747d3895896c0f1e3de07c384517216dbd90e

Thanks.

Kevin

---
From 496747d3895896c0f1e3de07c384517216dbd90e Mon Sep 17 00:00:00 2001
From: Yunjian Wang <wangyunjian@huawei.com>
Date: Tue, 15 Feb 2022 21:02:01 +0800
Subject: [PATCH] net/txgbe: reset security context pointer on close

[ upstream commit 6d498b853fe3110013fbfb69f8bc05d8de509f88 ]

When txgbe_dev_close() is cleaning up, it does not correctly set
the security_ctx variable to NULL, which will lead to wild pointer.

Fixes: f437d97c3df1 ("net/txgbe: add IPsec context creation")

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/txgbe/txgbe_ethdev.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/txgbe/txgbe_ethdev.c b/drivers/net/txgbe/txgbe_ethdev.c
index e2fcf87fe7..1d1dd430dc 100644
--- a/drivers/net/txgbe/txgbe_ethdev.c
+++ b/drivers/net/txgbe/txgbe_ethdev.c
@@ -2037,4 +2037,5 @@ txgbe_dev_close(struct rte_eth_dev *dev)
 #ifdef RTE_LIB_SECURITY
 	rte_free(dev->security_ctx);
+	dev->security_ctx = NULL;
 #endif
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.374671202 +0000
+++ 0039-net-txgbe-reset-security-context-pointer-on-close.patch	2022-03-01 10:41:01.301244097 +0000
@@ -1 +1 @@
-From 6d498b853fe3110013fbfb69f8bc05d8de509f88 Mon Sep 17 00:00:00 2001
+From 496747d3895896c0f1e3de07c384517216dbd90e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6d498b853fe3110013fbfb69f8bc05d8de509f88 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 7b42285b9e..19d4444748 100644
+index e2fcf87fe7..1d1dd430dc 100644
@@ -22 +23 @@
-@@ -2033,4 +2033,5 @@ txgbe_dev_close(struct rte_eth_dev *dev)
+@@ -2037,4 +2037,5 @@ txgbe_dev_close(struct rte_eth_dev *dev)


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

* patch 'net/iavf: reset security context pointer on stop' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (37 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/txgbe: " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'ethdev: fix MAC address in telemetry device info' " Kevin Traynor
                   ` (63 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Yunjian Wang; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From a42a8745993eb2627c6b60406e25de6926037627 Mon Sep 17 00:00:00 2001
From: Yunjian Wang <wangyunjian@huawei.com>
Date: Tue, 15 Feb 2022 21:02:27 +0800
Subject: [PATCH] net/iavf: reset security context pointer on stop

[ upstream commit 23abab4f14d3e2425e74c296769d21b79d696096 ]

When iavf_security_ctx_destroy() is cleaning up, it does not correctly
set the security_ctx variable to NULL, which will lead to wild pointer.

Fixes: 6bc987ecb860 ("net/iavf: support IPsec inline crypto")

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/iavf/iavf_ipsec_crypto.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/iavf/iavf_ipsec_crypto.c b/drivers/net/iavf/iavf_ipsec_crypto.c
index 6ac1b213db..a63e42f29a 100644
--- a/drivers/net/iavf/iavf_ipsec_crypto.c
+++ b/drivers/net/iavf/iavf_ipsec_crypto.c
@@ -1554,6 +1554,6 @@ iavf_security_ctx_destroy(struct iavf_adapter *adapter)
 	rte_free(sctx);
 
-	iavf_sctx = NULL;
-	sctx = NULL;
+	adapter->security_ctx = NULL;
+	adapter->vf.eth_dev->security_ctx = NULL;
 
 	return 0;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.400013874 +0000
+++ 0040-net-iavf-reset-security-context-pointer-on-stop.patch	2022-03-01 10:41:01.302244097 +0000
@@ -1 +1 @@
-From 23abab4f14d3e2425e74c296769d21b79d696096 Mon Sep 17 00:00:00 2001
+From a42a8745993eb2627c6b60406e25de6926037627 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 23abab4f14d3e2425e74c296769d21b79d696096 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'ethdev: fix MAC address in telemetry device info' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (38 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/iavf: reset security context pointer on stop' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/cnxk: fix mbuf data length' " Kevin Traynor
                   ` (62 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: David Marchand; +Cc: Christophe Fontaine, Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/116bfaa14e1db21c3d3fbd2ec4cfd125c790bded

Thanks.

Kevin

---
From 116bfaa14e1db21c3d3fbd2ec4cfd125c790bded Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Wed, 16 Feb 2022 15:13:16 +0100
Subject: [PATCH] ethdev: fix MAC address in telemetry device info

[ upstream commit ffe77e911f6a3d62757bc740670c4fda28f882f2 ]

The right size for a human readable MAC is RTE_ETHER_ADDR_FMT_SIZE.
While at it, the net library provides a helper for MAC address
formatting. Prefer it.

Fixes: 58b43c1ddfd1 ("ethdev: add telemetry endpoint for device info")

Reported-by: Christophe Fontaine <cfontain@redhat.com>
Signed-off-by: David Marchand <david.marchand@redhat.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 lib/ethdev/rte_ethdev.c | 11 +++--------
 1 file changed, 3 insertions(+), 8 deletions(-)

diff --git a/lib/ethdev/rte_ethdev.c b/lib/ethdev/rte_ethdev.c
index e59958e6f5..bf93534b90 100644
--- a/lib/ethdev/rte_ethdev.c
+++ b/lib/ethdev/rte_ethdev.c
@@ -6307,5 +6307,5 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,
 {
 	struct rte_tel_data *rxq_state, *txq_state;
-	char mac_addr[RTE_ETHER_ADDR_LEN];
+	char mac_addr[RTE_ETHER_ADDR_FMT_SIZE];
 	struct rte_eth_dev *eth_dev;
 	char *end_param;
@@ -6348,11 +6348,6 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,
 	rte_tel_data_add_dict_int(d, "rx_mbuf_alloc_fail",
 			eth_dev->data->rx_mbuf_alloc_failed);
-	snprintf(mac_addr, RTE_ETHER_ADDR_LEN, "%02x:%02x:%02x:%02x:%02x:%02x",
-			 eth_dev->data->mac_addrs->addr_bytes[0],
-			 eth_dev->data->mac_addrs->addr_bytes[1],
-			 eth_dev->data->mac_addrs->addr_bytes[2],
-			 eth_dev->data->mac_addrs->addr_bytes[3],
-			 eth_dev->data->mac_addrs->addr_bytes[4],
-			 eth_dev->data->mac_addrs->addr_bytes[5]);
+	rte_ether_format_addr(mac_addr, sizeof(mac_addr),
+			eth_dev->data->mac_addrs);
 	rte_tel_data_add_dict_string(d, "mac_addr", mac_addr);
 	rte_tel_data_add_dict_int(d, "promiscuous",
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.422757833 +0000
+++ 0041-ethdev-fix-MAC-address-in-telemetry-device-info.patch	2022-03-01 10:41:01.308244099 +0000
@@ -1 +1 @@
-From ffe77e911f6a3d62757bc740670c4fda28f882f2 Mon Sep 17 00:00:00 2001
+From 116bfaa14e1db21c3d3fbd2ec4cfd125c790bded Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ffe77e911f6a3d62757bc740670c4fda28f882f2 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 70c850a2f1..29a3d80466 100644
+index e59958e6f5..bf93534b90 100644
@@ -24 +25 @@
-@@ -5632,5 +5632,5 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,
+@@ -6307,5 +6307,5 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,
@@ -31 +32 @@
-@@ -5673,11 +5673,6 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,
+@@ -6348,11 +6348,6 @@ eth_dev_handle_port_info(const char *cmd __rte_unused,


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

* patch 'net/cnxk: fix mbuf data length' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (39 preceding siblings ...)
  2022-03-01 10:41 ` patch 'ethdev: fix MAC address in telemetry device info' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:41 ` patch 'net/bonding: fix slaves initializing on MTU setting' " Kevin Traynor
                   ` (61 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Rahul Bhansali; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From c93302dd4f481d60a53fc03298dda05ab3a719e7 Mon Sep 17 00:00:00 2001
From: Rahul Bhansali <rbhansali@marvell.com>
Date: Wed, 19 Jan 2022 16:22:03 +0530
Subject: [PATCH] net/cnxk: fix mbuf data length

[ upstream commit 4e00823dcc66c64e9462f7af09af22276ca36cce ]

If multi-segment is enabled and single segment/packet
is received, then mbuf data_len is not updated in
cn9k_nix_cqe_to_mbuf() function.
Also, in case of timestamp is enabled, mbuf data_len
and pkt_len will be updated for all packets including
multi segmented packets.

Fixes: 7c6bee34064f ("net/cnxk: enable PTP processing in vector Rx")

Signed-off-by: Rahul Bhansali <rbhansali@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/event/cnxk/cn10k_worker.h |  2 --
 drivers/event/cnxk/cn9k_worker.h  |  2 --
 drivers/net/cnxk/cn10k_rx.h       |  9 +++++++--
 drivers/net/cnxk/cn9k_rx.h        | 14 +++++++++-----
 drivers/net/cnxk/cnxk_ethdev.h    |  9 +++------
 5 files changed, 19 insertions(+), 17 deletions(-)

diff --git a/drivers/event/cnxk/cn10k_worker.h b/drivers/event/cnxk/cn10k_worker.h
index f8331e88d7..340708aae5 100644
--- a/drivers/event/cnxk/cn10k_worker.h
+++ b/drivers/event/cnxk/cn10k_worker.h
@@ -170,5 +170,4 @@ cn10k_process_vwqe(uintptr_t vwqe, uint16_t port_id, const uint32_t flags,
 		cnxk_nix_mbuf_to_tstamp((struct rte_mbuf *)mbuf, tstamp,
 					flags & NIX_RX_OFFLOAD_TSTAMP_F,
-					flags & NIX_RX_MULTI_SEG_F,
 					(uint64_t *)tstamp_ptr);
 		wqe[0] = (uint64_t *)mbuf;
@@ -262,5 +261,4 @@ cn10k_sso_hws_get_work(struct cn10k_sso_hws *ws, struct rte_event *ev,
 						ws->tstamp,
 						flags & NIX_RX_OFFLOAD_TSTAMP_F,
-						flags & NIX_RX_MULTI_SEG_F,
 						(uint64_t *)tstamp_ptr);
 			gw.u64[1] = mbuf;
diff --git a/drivers/event/cnxk/cn9k_worker.h b/drivers/event/cnxk/cn9k_worker.h
index 9377fa50e7..8abdd13b66 100644
--- a/drivers/event/cnxk/cn9k_worker.h
+++ b/drivers/event/cnxk/cn9k_worker.h
@@ -210,5 +210,4 @@ cn9k_sso_hws_dual_get_work(uint64_t base, uint64_t pair_base,
 			cnxk_nix_mbuf_to_tstamp((struct rte_mbuf *)mbuf, tstamp,
 						flags & NIX_RX_OFFLOAD_TSTAMP_F,
-						flags & NIX_RX_MULTI_SEG_F,
 						(uint64_t *)tstamp_ptr);
 			gw.u64[1] = mbuf;
@@ -289,5 +288,4 @@ cn9k_sso_hws_get_work(struct cn9k_sso_hws *ws, struct rte_event *ev,
 						ws->tstamp,
 						flags & NIX_RX_OFFLOAD_TSTAMP_F,
-						flags & NIX_RX_MULTI_SEG_F,
 						(uint64_t *)tstamp_ptr);
 			gw.u64[1] = mbuf;
diff --git a/drivers/net/cnxk/cn10k_rx.h b/drivers/net/cnxk/cn10k_rx.h
index fe408907a6..9d969cee87 100644
--- a/drivers/net/cnxk/cn10k_rx.h
+++ b/drivers/net/cnxk/cn10k_rx.h
@@ -364,5 +364,11 @@ cn10k_nix_cqe_to_mbuf(const struct nix_cqe_hdr_s *cq, const uint32_t tag,
 
 	if (flag & NIX_RX_MULTI_SEG_F)
-		nix_cqe_xtract_mseg(rx, mbuf, val, flag);
+		/*
+		 * For multi segment packets, mbuf length correction according
+		 * to Rx timestamp length will be handled later during
+		 * timestamp data process.
+		 * Hence, flag argument is not required.
+		 */
+		nix_cqe_xtract_mseg(rx, mbuf, val, 0);
 	else
 		mbuf->next = NULL;
@@ -452,5 +458,4 @@ cn10k_nix_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t pkts,
 		cnxk_nix_mbuf_to_tstamp(mbuf, rxq->tstamp,
 					(flags & NIX_RX_OFFLOAD_TSTAMP_F),
-					(flags & NIX_RX_MULTI_SEG_F),
 					(uint64_t *)((uint8_t *)mbuf
 								+ data_off));
diff --git a/drivers/net/cnxk/cn9k_rx.h b/drivers/net/cnxk/cn9k_rx.h
index 225bb4197c..848df4190c 100644
--- a/drivers/net/cnxk/cn9k_rx.h
+++ b/drivers/net/cnxk/cn9k_rx.h
@@ -342,12 +342,17 @@ skip_parse:
 			nix_update_match_id(rx->cn9k.match_id, ol_flags, mbuf);
 
+	mbuf->ol_flags = ol_flags;
+	*(uint64_t *)(&mbuf->rearm_data) = val;
 	mbuf->pkt_len = len;
 	mbuf->data_len = len;
-	*(uint64_t *)(&mbuf->rearm_data) = val;
-
-	mbuf->ol_flags = ol_flags;
 
 	if (flag & NIX_RX_MULTI_SEG_F)
-		nix_cqe_xtract_mseg(rx, mbuf, val, flag);
+		/*
+		 * For multi segment packets, mbuf length correction according
+		 * to Rx timestamp length will be handled later during
+		 * timestamp data process.
+		 * Hence, flag argument is not required.
+		 */
+		nix_cqe_xtract_mseg(rx, mbuf, val, 0);
 	else
 		mbuf->next = NULL;
@@ -414,5 +419,4 @@ cn9k_nix_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t pkts,
 		cnxk_nix_mbuf_to_tstamp(mbuf, rxq->tstamp,
 					(flags & NIX_RX_OFFLOAD_TSTAMP_F),
-					(flags & NIX_RX_MULTI_SEG_F),
 					(uint64_t *)((uint8_t *)mbuf
 								+ data_off));
diff --git a/drivers/net/cnxk/cnxk_ethdev.h b/drivers/net/cnxk/cnxk_ethdev.h
index 5bfda3d815..480cc6dfa4 100644
--- a/drivers/net/cnxk/cnxk_ethdev.h
+++ b/drivers/net/cnxk/cnxk_ethdev.h
@@ -686,12 +686,9 @@ static __rte_always_inline void
 cnxk_nix_mbuf_to_tstamp(struct rte_mbuf *mbuf,
 			struct cnxk_timesync_info *tstamp,
-			const uint8_t ts_enable, const uint8_t mseg_enable,
-			uint64_t *tstamp_ptr)
+			const uint8_t ts_enable, uint64_t *tstamp_ptr)
 {
 	if (ts_enable) {
-		if (!mseg_enable) {
-			mbuf->pkt_len -= CNXK_NIX_TIMESYNC_RX_OFFSET;
-			mbuf->data_len -= CNXK_NIX_TIMESYNC_RX_OFFSET;
-		}
+		mbuf->pkt_len -= CNXK_NIX_TIMESYNC_RX_OFFSET;
+		mbuf->data_len -= CNXK_NIX_TIMESYNC_RX_OFFSET;
 
 		/* Reading the rx timestamp inserted by CGX, viz at
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.448728856 +0000
+++ 0042-net-cnxk-fix-mbuf-data-length.patch	2022-03-01 10:41:01.312244099 +0000
@@ -1 +1 @@
-From 4e00823dcc66c64e9462f7af09af22276ca36cce Mon Sep 17 00:00:00 2001
+From c93302dd4f481d60a53fc03298dda05ab3a719e7 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 4e00823dcc66c64e9462f7af09af22276ca36cce ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
- drivers/net/cnxk/cn9k_rx.h        | 16 ++++++++++------
+ drivers/net/cnxk/cn9k_rx.h        | 14 +++++++++-----
@@ -24 +25 @@
- 5 files changed, 20 insertions(+), 18 deletions(-)
+ 5 files changed, 19 insertions(+), 17 deletions(-)
@@ -27 +28 @@
-index bb32ef75ef..56e84bd599 100644
+index f8331e88d7..340708aae5 100644
@@ -30 +31 @@
-@@ -175,5 +175,4 @@ cn10k_process_vwqe(uintptr_t vwqe, uint16_t port_id, const uint32_t flags,
+@@ -170,5 +170,4 @@ cn10k_process_vwqe(uintptr_t vwqe, uint16_t port_id, const uint32_t flags,
@@ -36 +37 @@
-@@ -267,5 +266,4 @@ cn10k_sso_hws_get_work(struct cn10k_sso_hws *ws, struct rte_event *ev,
+@@ -262,5 +261,4 @@ cn10k_sso_hws_get_work(struct cn10k_sso_hws *ws, struct rte_event *ev,
@@ -43 +44 @@
-index 79b2b3809f..385cc656cb 100644
+index 9377fa50e7..8abdd13b66 100644
@@ -46,2 +47,2 @@
-@@ -232,5 +232,4 @@ cn9k_sso_hws_dual_get_work(uint64_t base, uint64_t pair_base,
- 						dws->tstamp,
+@@ -210,5 +210,4 @@ cn9k_sso_hws_dual_get_work(uint64_t base, uint64_t pair_base,
+ 			cnxk_nix_mbuf_to_tstamp((struct rte_mbuf *)mbuf, tstamp,
@@ -52 +53 @@
-@@ -309,5 +308,4 @@ cn9k_sso_hws_get_work(struct cn9k_sso_hws *ws, struct rte_event *ev,
+@@ -289,5 +288,4 @@ cn9k_sso_hws_get_work(struct cn9k_sso_hws *ws, struct rte_event *ev,
@@ -59 +60 @@
-index 564e50f0af..0c9fe4af6d 100644
+index fe408907a6..9d969cee87 100644
@@ -62 +63 @@
-@@ -365,5 +365,11 @@ cn10k_nix_cqe_to_mbuf(const struct nix_cqe_hdr_s *cq, const uint32_t tag,
+@@ -364,5 +364,11 @@ cn10k_nix_cqe_to_mbuf(const struct nix_cqe_hdr_s *cq, const uint32_t tag,
@@ -75 +76 @@
-@@ -453,5 +459,4 @@ cn10k_nix_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t pkts,
+@@ -452,5 +458,4 @@ cn10k_nix_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t pkts,
@@ -82 +83 @@
-index d36f292c95..6b6c5bfbc2 100644
+index 225bb4197c..848df4190c 100644
@@ -85,2 +86,5 @@
-@@ -392,11 +392,16 @@ skip_parse:
- 	*(uint64_t *)(&mbuf->rearm_data) = val;
+@@ -342,12 +342,17 @@ skip_parse:
+ 			nix_update_match_id(rx->cn9k.match_id, ol_flags, mbuf);
+ 
++	mbuf->ol_flags = ol_flags;
++	*(uint64_t *)(&mbuf->rearm_data) = val;
@@ -88 +92,4 @@
-+	mbuf->data_len = len;
+ 	mbuf->data_len = len;
+-	*(uint64_t *)(&mbuf->rearm_data) = val;
+-
+-	mbuf->ol_flags = ol_flags;
@@ -90 +97 @@
--	if (flag & NIX_RX_MULTI_SEG_F) {
+ 	if (flag & NIX_RX_MULTI_SEG_F)
@@ -92,3 +98,0 @@
--	} else {
--		mbuf->data_len = len;
-+	if (flag & NIX_RX_MULTI_SEG_F)
@@ -102 +106 @@
-+	else
+ 	else
@@ -104,4 +108 @@
--	}
- }
- 
-@@ -461,5 +466,4 @@ cn9k_nix_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t pkts,
+@@ -414,5 +419,4 @@ cn9k_nix_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t pkts,
@@ -114 +115 @@
-index fadc8aaf45..ad568c9fcd 100644
+index 5bfda3d815..480cc6dfa4 100644
@@ -117 +118 @@
-@@ -697,12 +697,9 @@ static __rte_always_inline void
+@@ -686,12 +686,9 @@ static __rte_always_inline void


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

* patch 'net/bonding: fix slaves initializing on MTU setting' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (40 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/cnxk: fix mbuf data length' " Kevin Traynor
@ 2022-03-01 10:41 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'app/testpmd: check starting port is not in bonding' " Kevin Traynor
                   ` (60 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:41 UTC (permalink / raw)
  To: Junjie Wan; +Cc: Ferruh Yigit, Min Hu, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/387187932f2b578f1a714ce06d099358a72b54b2

Thanks.

Kevin

---
From 387187932f2b578f1a714ce06d099358a72b54b2 Mon Sep 17 00:00:00 2001
From: Junjie Wan <wanjunjie@bytedance.com>
Date: Tue, 15 Feb 2022 18:59:40 +0800
Subject: [PATCH] net/bonding: fix slaves initializing on MTU setting

[ upstream commit b3eaaf1d08ec70646bdd69416253dfb355480492 ]

If a initial process for the bonding device is like:
rte_eth_dev_configure
rte_eth_dev_set_mtu
queue setup and start, etc.

Pass the vdev args to application, and init bonding device only.
-a 0000:af:00.0 --vdev="net_bonding0,mode=2,slave=0000:af:00.0"

It will fail and complain for the slave device
"Port 0 must be configured before MTU set"

Test can be reproduced with ovs.

Fixes: b26bee10ee37 ("ethdev: forbid MTU set before device configure")

Signed-off-by: Junjie Wan <wanjunjie@bytedance.com>
Tested-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Min Hu (Connor) <humin29@huawei.com>
---
 app/test/test_link_bonding.c           |  4 +++
 app/test/test_link_bonding_rssconf.c   |  4 +++
 drivers/net/bonding/eth_bond_private.h |  4 +++
 drivers/net/bonding/rte_eth_bond_api.c |  6 ++++
 drivers/net/bonding/rte_eth_bond_pmd.c | 43 ++++++++++++++++++++++----
 5 files changed, 55 insertions(+), 6 deletions(-)

diff --git a/app/test/test_link_bonding.c b/app/test/test_link_bonding.c
index dc6fc46b9c..12c50ef393 100644
--- a/app/test/test_link_bonding.c
+++ b/app/test/test_link_bonding.c
@@ -182,4 +182,8 @@ configure_ethdev(uint16_t port_id, uint8_t start, uint8_t en_isr)
 			"rte_eth_dev_configure for port %d failed", port_id);
 
+	int ret = rte_eth_dev_set_mtu(port_id, 1550);
+	RTE_TEST_ASSERT(ret == 0 || ret == -ENOTSUP,
+			"rte_eth_dev_set_mtu for port %d failed", port_id);
+
 	for (q_id = 0; q_id < test_params->nb_rx_q; q_id++)
 		TEST_ASSERT_SUCCESS(rte_eth_rx_queue_setup(port_id, q_id, RX_RING_SIZE,
diff --git a/app/test/test_link_bonding_rssconf.c b/app/test/test_link_bonding_rssconf.c
index f9eae93973..7228965ced 100644
--- a/app/test/test_link_bonding_rssconf.c
+++ b/app/test/test_link_bonding_rssconf.c
@@ -129,4 +129,8 @@ configure_ethdev(uint16_t port_id, struct rte_eth_conf *eth_conf,
 			port_id);
 
+	int ret = rte_eth_dev_set_mtu(port_id, 1550);
+	RTE_TEST_ASSERT(ret == 0 || ret == -ENOTSUP,
+			"rte_eth_dev_set_mtu for port %d failed", port_id);
+
 	for (rxq = 0; rxq < RXTX_QUEUE_COUNT; rxq++) {
 		TEST_ASSERT(rte_eth_rx_queue_setup(port_id, rxq, RXTX_RING_SIZE,
diff --git a/drivers/net/bonding/eth_bond_private.h b/drivers/net/bonding/eth_bond_private.h
index 156335c425..8222e3cd38 100644
--- a/drivers/net/bonding/eth_bond_private.h
+++ b/drivers/net/bonding/eth_bond_private.h
@@ -247,4 +247,8 @@ slave_configure(struct rte_eth_dev *bonded_eth_dev,
 		struct rte_eth_dev *slave_eth_dev);
 
+int
+slave_start(struct rte_eth_dev *bonded_eth_dev,
+		struct rte_eth_dev *slave_eth_dev);
+
 void
 slave_remove(struct bond_dev_private *internals,
diff --git a/drivers/net/bonding/rte_eth_bond_api.c b/drivers/net/bonding/rte_eth_bond_api.c
index 8840d9e17b..919c580fb8 100644
--- a/drivers/net/bonding/rte_eth_bond_api.c
+++ b/drivers/net/bonding/rte_eth_bond_api.c
@@ -567,4 +567,10 @@ __eth_bond_slave_add_lock_free(uint16_t bonded_port_id, uint16_t slave_port_id)
 			return -1;
 		}
+		if (slave_start(bonded_eth_dev, slave_eth_dev) != 0) {
+			internals->slave_count--;
+			RTE_BOND_LOG(ERR, "rte_bond_slaves_start: port=%d",
+					slave_port_id);
+			return -1;
+		}
 	}
 
diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index bfa931098e..58dad0a0e3 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -1679,12 +1679,8 @@ slave_configure(struct rte_eth_dev *bonded_eth_dev,
 		struct rte_eth_dev *slave_eth_dev)
 {
-	struct bond_rx_queue *bd_rx_q;
-	struct bond_tx_queue *bd_tx_q;
 	uint16_t nb_rx_queues;
 	uint16_t nb_tx_queues;
 
 	int errval;
-	uint16_t q_id;
-	struct rte_flow_error flow_error;
 
 	struct bond_dev_private *internals = bonded_eth_dev->data->dev_private;
@@ -1759,4 +1755,17 @@ slave_configure(struct rte_eth_dev *bonded_eth_dev,
 		return errval;
 	}
+	return 0;
+}
+
+int
+slave_start(struct rte_eth_dev *bonded_eth_dev,
+		struct rte_eth_dev *slave_eth_dev)
+{
+	int errval = 0;
+	struct bond_rx_queue *bd_rx_q;
+	struct bond_tx_queue *bd_tx_q;
+	uint16_t q_id;
+	struct rte_flow_error flow_error;
+	struct bond_dev_private *internals = bonded_eth_dev->data->dev_private;
 
 	/* Setup Rx Queues */
@@ -1807,8 +1816,11 @@ slave_configure(struct rte_eth_dev *bonded_eth_dev,
 		}
 
-		if (internals->mode4.dedicated_queues.flow[slave_eth_dev->data->port_id] != NULL)
-			rte_flow_destroy(slave_eth_dev->data->port_id,
+		if (internals->mode4.dedicated_queues.flow[slave_eth_dev->data->port_id] != NULL) {
+			errval = rte_flow_destroy(slave_eth_dev->data->port_id,
 					internals->mode4.dedicated_queues.flow[slave_eth_dev->data->port_id],
 					&flow_error);
+			RTE_BOND_LOG(ERR, "bond_ethdev_8023ad_flow_destroy: port=%d, err (%d)",
+				slave_eth_dev->data->port_id, errval);
+		}
 
 		errval = bond_ethdev_8023ad_flow_set(bonded_eth_dev,
@@ -2002,4 +2014,11 @@ bond_ethdev_start(struct rte_eth_dev *eth_dev)
 			goto out_err;
 		}
+		if (slave_start(eth_dev, slave_ethdev) != 0) {
+			RTE_BOND_LOG(ERR,
+				"bonded port (%d) failed to start slave device (%d)",
+				eth_dev->data->port_id,
+				internals->slaves[i].port_id);
+			goto out_err;
+		}
 		/* We will need to poll for link status if any slave doesn't
 		 * support interrupts
@@ -3848,4 +3867,16 @@ bond_ethdev_configure(struct rte_eth_dev *dev)
 	}
 
+	/* configure slaves so we can pass mtu setting */
+	for (i = 0; i < internals->slave_count; i++) {
+		struct rte_eth_dev *slave_ethdev =
+				&(rte_eth_devices[internals->slaves[i].port_id]);
+		if (slave_configure(dev, slave_ethdev) != 0) {
+			RTE_BOND_LOG(ERR,
+				"bonded port (%d) failed to configure slave device (%d)",
+				dev->data->port_id,
+				internals->slaves[i].port_id);
+			return -1;
+		}
+	}
 	return 0;
 }
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.474376869 +0000
+++ 0043-net-bonding-fix-slaves-initializing-on-MTU-setting.patch	2022-03-01 10:41:01.320244101 +0000
@@ -1 +1 @@
-From b3eaaf1d08ec70646bdd69416253dfb355480492 Mon Sep 17 00:00:00 2001
+From 387187932f2b578f1a714ce06d099358a72b54b2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b3eaaf1d08ec70646bdd69416253dfb355480492 ]
+
@@ -20 +21,0 @@
-Cc: stable@dpdk.org
@@ -34 +35 @@
-index 82a9b8e01a..194ed5a7ec 100644
+index dc6fc46b9c..12c50ef393 100644
@@ -73 +74 @@
-index b78867b125..4ac191c468 100644
+index 8840d9e17b..919c580fb8 100644
@@ -88 +89 @@
-index 846a131916..b305b6a35b 100644
+index bfa931098e..58dad0a0e3 100644
@@ -148 +149 @@
-@@ -3849,4 +3868,16 @@ bond_ethdev_configure(struct rte_eth_dev *dev)
+@@ -3848,4 +3867,16 @@ bond_ethdev_configure(struct rte_eth_dev *dev)


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

* patch 'app/testpmd: check starting port is not in bonding' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (41 preceding siblings ...)
  2022-03-01 10:41 ` patch 'net/bonding: fix slaves initializing on MTU setting' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk: fix flow deletion' " Kevin Traynor
                   ` (59 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Min Hu (Connor); +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/450ee57e5fb4c073e478471877d7984f271a0289

Thanks.

Kevin

---
From 450ee57e5fb4c073e478471877d7984f271a0289 Mon Sep 17 00:00:00 2001
From: "Min Hu (Connor)" <humin29@huawei.com>
Date: Thu, 17 Feb 2022 19:36:55 +0800
Subject: [PATCH] app/testpmd: check starting port is not in bonding

[ upstream commit d8c079a572f3b76ca22fbfe665fb2e5e578ba881 ]

In bond, start or stop slave port should be operated by bonding port.
This patch add port_is_bonding_slave in start_port function.

Fixes: 0e545d3047fe ("app/testpmd: check stopping port is not in bonding")

Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 app/test-pmd/testpmd.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index e1da961311..2387cc1d9e 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -2728,4 +2728,11 @@ start_port(portid_t pid)
 			continue;
 
+		if (port_is_bonding_slave(pi)) {
+			fprintf(stderr,
+				"Please remove port %d from bonded device.\n",
+				pi);
+			continue;
+		}
+
 		need_check_link_status = 0;
 		port = &ports[pi];
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.502889716 +0000
+++ 0044-app-testpmd-check-starting-port-is-not-in-bonding.patch	2022-03-01 10:41:01.324244102 +0000
@@ -1 +1 @@
-From d8c079a572f3b76ca22fbfe665fb2e5e578ba881 Mon Sep 17 00:00:00 2001
+From 450ee57e5fb4c073e478471877d7984f271a0289 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d8c079a572f3b76ca22fbfe665fb2e5e578ba881 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 6d2e52c790..fe2ce19f99 100644
+index e1da961311..2387cc1d9e 100644
@@ -22 +23 @@
-@@ -2727,4 +2727,11 @@ start_port(portid_t pid)
+@@ -2728,4 +2728,11 @@ start_port(portid_t pid)


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

* patch 'common/cnxk: fix flow deletion' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (42 preceding siblings ...)
  2022-03-01 10:42 ` patch 'app/testpmd: check starting port is not in bonding' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk: fix log level during MCAM allocation' " Kevin Traynor
                   ` (58 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Satheesh Paul; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From d91869302fa2f79eefbc0ce02d52de54fdcd55de Mon Sep 17 00:00:00 2001
From: Satheesh Paul <psatheesh@marvell.com>
Date: Tue, 25 Jan 2022 09:45:26 +0530
Subject: [PATCH] common/cnxk: fix flow deletion

[ upstream commit 40257b81b8ae239c630e27cfa81e136ad3a25dc3 ]

When a flow is deleted, the counters are deleted without
being cleared first. This results in counter values being
retained and shown in flows created later. Hence, counter
is cleared before being deleted.

Updated driver to clear and delete counters upon flow deletion.

Fixes: a07f7ced436d ("common/cnxk: add NPC init and fini")

Signed-off-by: Satheesh Paul <psatheesh@marvell.com>
Reviewed-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/common/cnxk/roc_npc.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/drivers/common/cnxk/roc_npc.c b/drivers/common/cnxk/roc_npc.c
index 503c74748f..8386e0e956 100644
--- a/drivers/common/cnxk/roc_npc.c
+++ b/drivers/common/cnxk/roc_npc.c
@@ -1247,4 +1247,14 @@ roc_npc_flow_destroy(struct roc_npc *roc_npc, struct roc_npc_flow *flow)
 	}
 
+	if (flow->ctr_id != NPC_COUNTER_NONE) {
+		rc = roc_npc_mcam_clear_counter(roc_npc, flow->ctr_id);
+		if (rc != 0)
+			return rc;
+
+		rc = npc_mcam_free_counter(npc, flow->ctr_id);
+		if (rc != 0)
+			return rc;
+	}
+
 	rc = npc_mcam_free_entry(npc, flow->mcam_id);
 	if (rc != 0)
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.527405706 +0000
+++ 0045-common-cnxk-fix-flow-deletion.patch	2022-03-01 10:41:01.325244102 +0000
@@ -1 +1 @@
-From 40257b81b8ae239c630e27cfa81e136ad3a25dc3 Mon Sep 17 00:00:00 2001
+From d91869302fa2f79eefbc0ce02d52de54fdcd55de Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 40257b81b8ae239c630e27cfa81e136ad3a25dc3 ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index e3961bfbc6..df3016f538 100644
+index 503c74748f..8386e0e956 100644
@@ -26 +27 @@
-@@ -1260,4 +1260,14 @@ roc_npc_flow_destroy(struct roc_npc *roc_npc, struct roc_npc_flow *flow)
+@@ -1247,4 +1247,14 @@ roc_npc_flow_destroy(struct roc_npc *roc_npc, struct roc_npc_flow *flow)


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

* patch 'common/cnxk: fix log level during MCAM allocation' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (43 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk: fix flow deletion' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk: fix base rule merge' " Kevin Traynor
                   ` (57 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Satheesh Paul; +Cc: Kiran Kumar K, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/1751e87f515213e80f69418d62687ec51ec947ab

Thanks.

Kevin

---
From 1751e87f515213e80f69418d62687ec51ec947ab Mon Sep 17 00:00:00 2001
From: Satheesh Paul <psatheesh@marvell.com>
Date: Tue, 25 Jan 2022 09:46:43 +0530
Subject: [PATCH] common/cnxk: fix log level during MCAM allocation

[ upstream commit 542e27e99b16509e3a545048d0ae3f5bd38e43e9 ]

Changed log level from info to debug for a couple of log
messages printed during MCAM allocation.

Fixes: 1f66919817ee ("common/cnxk: improve MCAM entries management")

Signed-off-by: Satheesh Paul <psatheesh@marvell.com>
Reviewed-by: Kiran Kumar K <kirankumark@marvell.com>
---
 drivers/common/cnxk/roc_npc_utils.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/common/cnxk/roc_npc_utils.c b/drivers/common/cnxk/roc_npc_utils.c
index ed0ef5c462..26e104c39f 100644
--- a/drivers/common/cnxk/roc_npc_utils.c
+++ b/drivers/common/cnxk/roc_npc_utils.c
@@ -665,5 +665,5 @@ npc_get_free_mcam_entry(struct mbox *mbox, struct roc_npc_flow *flow,
 	new_entry->flow = flow;
 
-	plt_info("npc: kernel allocated MCAM entry %d", rsp_local.entry);
+	plt_npc_dbg("kernel allocated MCAM entry %d", rsp_local.entry);
 
 	rc = npc_sort_mcams_by_user_prio_level(mbox, new_entry, npc,
@@ -672,5 +672,5 @@ npc_get_free_mcam_entry(struct mbox *mbox, struct roc_npc_flow *flow,
 		goto err;
 
-	plt_info("npc: allocated MCAM entry after sorting %d", rsp_local.entry);
+	plt_npc_dbg("allocated MCAM entry after sorting %d", rsp_local.entry);
 	flow->mcam_id = rsp_local.entry;
 	npc_insert_into_flow_list(npc, new_entry);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.549968203 +0000
+++ 0046-common-cnxk-fix-log-level-during-MCAM-allocation.patch	2022-03-01 10:41:01.325244102 +0000
@@ -1 +1 @@
-From 542e27e99b16509e3a545048d0ae3f5bd38e43e9 Mon Sep 17 00:00:00 2001
+From 1751e87f515213e80f69418d62687ec51ec947ab Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 542e27e99b16509e3a545048d0ae3f5bd38e43e9 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'common/cnxk: fix base rule merge' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (44 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk: fix log level during MCAM allocation' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'vhost: fix field naming in guest page struct' " Kevin Traynor
                   ` (56 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Satheesh Paul; +Cc: Kiran Kumar K, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e09a0094a6025aed8cbe52b1a7b27280629dbb82 Mon Sep 17 00:00:00 2001
From: Satheesh Paul <psatheesh@marvell.com>
Date: Tue, 25 Jan 2022 09:47:59 +0530
Subject: [PATCH] common/cnxk: fix base rule merge

[ upstream commit 0fb2b46be79a6558efd39c7a2e1d55402c958081 ]

Egress rules do not have a base steering rule and the
current base steering rule is applicable only for ingress
rules. Hence, when creating a flow rule, merge base steering
rule only for ingress rules.

Fixes: f9af90807466 ("common/cnxk: add mcam utility API")

Signed-off-by: Satheesh Paul <psatheesh@marvell.com>
Reviewed-by: Kiran Kumar K <kirankumark@marvell.com>
---
 drivers/common/cnxk/roc_npc_mcam.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/common/cnxk/roc_npc_mcam.c b/drivers/common/cnxk/roc_npc_mcam.c
index 82014a2ca0..a16ba3f7be 100644
--- a/drivers/common/cnxk/roc_npc_mcam.c
+++ b/drivers/common/cnxk/roc_npc_mcam.c
@@ -671,5 +671,5 @@ npc_program_mcam(struct npc *npc, struct npc_parse_state *pst, bool mcam_alloc)
 	memcpy(pst->flow->mcam_mask, key_mask, key_len);
 
-	if (pst->is_vf) {
+	if (pst->is_vf && pst->flow->nix_intf == NIX_INTF_RX) {
 		(void)mbox_alloc_msg_npc_read_base_steer_rule(npc->mbox);
 		rc = mbox_process_msg(npc->mbox, (void *)&base_rule_rsp);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.572041011 +0000
+++ 0047-common-cnxk-fix-base-rule-merge.patch	2022-03-01 10:41:01.326244102 +0000
@@ -1 +1 @@
-From 0fb2b46be79a6558efd39c7a2e1d55402c958081 Mon Sep 17 00:00:00 2001
+From e09a0094a6025aed8cbe52b1a7b27280629dbb82 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0fb2b46be79a6558efd39c7a2e1d55402c958081 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index b251f643bc..7a3a8944f5 100644
+index 82014a2ca0..a16ba3f7be 100644
@@ -24,2 +25,2 @@
-@@ -753,5 +753,5 @@ npc_program_mcam(struct npc *npc, struct npc_parse_state *pst, bool mcam_alloc)
- 		npc_set_ipv6ext_ltype_mask(pst);
+@@ -671,5 +671,5 @@ npc_program_mcam(struct npc *npc, struct npc_parse_state *pst, bool mcam_alloc)
+ 	memcpy(pst->flow->mcam_mask, key_mask, key_len);


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

* patch 'vhost: fix field naming in guest page struct' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (45 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk: fix base rule merge' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'vhost: fix unsafe vring addresses modifications' " Kevin Traynor
                   ` (55 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Xuan Ding; +Cc: Maxime Coquelin, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/01e3dee29c02e68a2ed395185ca89faab11246d3

Thanks.

Kevin

---
From 01e3dee29c02e68a2ed395185ca89faab11246d3 Mon Sep 17 00:00:00 2001
From: Xuan Ding <xuan.ding@intel.com>
Date: Tue, 15 Feb 2022 15:02:25 +0000
Subject: [PATCH] vhost: fix field naming in guest page struct

[ upstream commit 2ec359747e61db15ab18a78fa35f503a4f647463 ]

This patch renames the host_phys_addr to host_iova in guest_page
struct. The host_phys_addr is iova, it depends on the DPDK
IOVA mode.

Fixes: e246896178e6 ("vhost: get guest/host physical address mappings")

Signed-off-by: Xuan Ding <xuan.ding@intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
 lib/vhost/vhost.h      | 10 +++++-----
 lib/vhost/vhost_user.c | 20 ++++++++++----------
 lib/vhost/virtio_net.c | 11 ++++++-----
 3 files changed, 21 insertions(+), 20 deletions(-)

diff --git a/lib/vhost/vhost.h b/lib/vhost/vhost.h
index b3f0c1d07c..c5d8b84320 100644
--- a/lib/vhost/vhost.h
+++ b/lib/vhost/vhost.h
@@ -355,5 +355,5 @@ struct vring_packed_desc_event {
 struct guest_page {
 	uint64_t guest_phys_addr;
-	uint64_t host_phys_addr;
+	uint64_t host_iova;
 	uint64_t size;
 };
@@ -619,5 +619,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
 					page->guest_phys_addr + page->size) {
 				return gpa - page->guest_phys_addr +
-					page->host_phys_addr;
+					page->host_iova;
 			} else if (gpa < page->guest_phys_addr +
 						page->size) {
@@ -625,5 +625,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
 					page->size - gpa;
 				return gpa - page->guest_phys_addr +
-					page->host_phys_addr;
+					page->host_iova;
 			}
 		}
@@ -636,5 +636,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
 					page->guest_phys_addr + page->size) {
 					return gpa - page->guest_phys_addr +
-						page->host_phys_addr;
+						page->host_iova;
 				} else if (gpa < page->guest_phys_addr +
 							page->size) {
@@ -642,5 +642,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
 						page->size - gpa;
 					return gpa - page->guest_phys_addr +
-						page->host_phys_addr;
+						page->host_iova;
 				}
 			}
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 5eb1dd6812..14ba3365c7 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost/vhost_user.c
@@ -979,5 +979,5 @@ vhost_user_set_vring_base(struct virtio_net **pdev,
 static int
 add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
-		   uint64_t host_phys_addr, uint64_t size)
+		   uint64_t host_iova, uint64_t size)
 {
 	struct guest_page *page, *last_page;
@@ -1000,5 +1000,5 @@ add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
 		last_page = &dev->guest_pages[dev->nr_guest_pages - 1];
 		/* merge if the two pages are continuous */
-		if (host_phys_addr == last_page->host_phys_addr +
+		if (host_iova == last_page->host_iova +
 				      last_page->size) {
 			last_page->size += size;
@@ -1009,5 +1009,5 @@ add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
 	page = &dev->guest_pages[dev->nr_guest_pages++];
 	page->guest_phys_addr = guest_phys_addr;
-	page->host_phys_addr  = host_phys_addr;
+	page->host_iova  = host_iova;
 	page->size = size;
 
@@ -1022,12 +1022,12 @@ add_guest_pages(struct virtio_net *dev, struct rte_vhost_mem_region *reg,
 	uint64_t host_user_addr  = reg->host_user_addr;
 	uint64_t guest_phys_addr = reg->guest_phys_addr;
-	uint64_t host_phys_addr;
+	uint64_t host_iova;
 	uint64_t size;
 
-	host_phys_addr = rte_mem_virt2iova((void *)(uintptr_t)host_user_addr);
+	host_iova = rte_mem_virt2iova((void *)(uintptr_t)host_user_addr);
 	size = page_size - (guest_phys_addr & (page_size - 1));
 	size = RTE_MIN(size, reg_size);
 
-	if (add_one_guest_page(dev, guest_phys_addr, host_phys_addr, size) < 0)
+	if (add_one_guest_page(dev, guest_phys_addr, host_iova, size) < 0)
 		return -1;
 
@@ -1038,7 +1038,7 @@ add_guest_pages(struct virtio_net *dev, struct rte_vhost_mem_region *reg,
 	while (reg_size > 0) {
 		size = RTE_MIN(reg_size, page_size);
-		host_phys_addr = rte_mem_virt2iova((void *)(uintptr_t)
+		host_iova = rte_mem_virt2iova((void *)(uintptr_t)
 						  host_user_addr);
-		if (add_one_guest_page(dev, guest_phys_addr, host_phys_addr,
+		if (add_one_guest_page(dev, guest_phys_addr, host_iova,
 				size) < 0)
 			return -1;
@@ -1072,9 +1072,9 @@ dump_guest_pages(struct virtio_net *dev)
 			"guest physical page region %u\n"
 			"\t guest_phys_addr: %" PRIx64 "\n"
-			"\t host_phys_addr : %" PRIx64 "\n"
+			"\t host_iova      : %" PRIx64 "\n"
 			"\t size           : %" PRIx64 "\n",
 			i,
 			page->guest_phys_addr,
-			page->host_phys_addr,
+			page->host_iova,
 			page->size);
 	}
diff --git a/lib/vhost/virtio_net.c b/lib/vhost/virtio_net.c
index b3d954aab4..568d6538ed 100644
--- a/lib/vhost/virtio_net.c
+++ b/lib/vhost/virtio_net.c
@@ -871,11 +871,12 @@ async_mbuf_to_desc_seg(struct virtio_net *dev, struct vhost_virtqueue *vq,
 	uint64_t mapped_len;
 	uint32_t buf_offset = 0;
-	void *hpa;
+	void *host_iova;
 
 	while (cpy_len) {
-		hpa = (void *)(uintptr_t)gpa_to_first_hpa(dev,
+		host_iova = (void *)(uintptr_t)gpa_to_first_hpa(dev,
 				buf_iova + buf_offset, cpy_len, &mapped_len);
-		if (unlikely(!hpa)) {
-			VHOST_LOG_DATA(ERR, "(%d) %s: failed to get hpa.\n", dev->vid, __func__);
+		if (unlikely(!host_iova)) {
+			VHOST_LOG_DATA(ERR, "(%d) %s: failed to get host_iova.\n",
+				       dev->vid, __func__);
 			return -1;
 		}
@@ -884,5 +885,5 @@ async_mbuf_to_desc_seg(struct virtio_net *dev, struct vhost_virtqueue *vq,
 						(void *)(uintptr_t)rte_pktmbuf_iova_offset(m,
 							mbuf_offset),
-						hpa, (size_t)mapped_len)))
+						host_iova, (size_t)mapped_len)))
 			return -1;
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.660612129 +0000
+++ 0048-vhost-fix-field-naming-in-guest-page-struct.patch	2022-03-01 10:41:01.331244103 +0000
@@ -1 +1 @@
-From 2ec359747e61db15ab18a78fa35f503a4f647463 Mon Sep 17 00:00:00 2001
+From 01e3dee29c02e68a2ed395185ca89faab11246d3 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 2ec359747e61db15ab18a78fa35f503a4f647463 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 64ec76b80e..5606360414 100644
+index b3f0c1d07c..c5d8b84320 100644
@@ -25 +26 @@
-@@ -425,5 +425,5 @@ struct vring_packed_desc_event {
+@@ -355,5 +355,5 @@ struct vring_packed_desc_event {
@@ -32 +33 @@
-@@ -688,5 +688,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
+@@ -619,5 +619,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
@@ -39 +40 @@
-@@ -694,5 +694,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
+@@ -625,5 +625,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
@@ -46 +47 @@
-@@ -705,5 +705,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
+@@ -636,5 +636,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
@@ -53 +54 @@
-@@ -711,5 +711,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
+@@ -642,5 +642,5 @@ gpa_to_first_hpa(struct virtio_net *dev, uint64_t gpa,
@@ -61 +62 @@
-index 4f135f1f72..8257a92e12 100644
+index 5eb1dd6812..14ba3365c7 100644
@@ -64 +65 @@
-@@ -987,5 +987,5 @@ vhost_user_set_vring_base(struct virtio_net **pdev,
+@@ -979,5 +979,5 @@ vhost_user_set_vring_base(struct virtio_net **pdev,
@@ -71 +72 @@
-@@ -1008,5 +1008,5 @@ add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
+@@ -1000,5 +1000,5 @@ add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
@@ -78 +79 @@
-@@ -1017,5 +1017,5 @@ add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
+@@ -1009,5 +1009,5 @@ add_one_guest_page(struct virtio_net *dev, uint64_t guest_phys_addr,
@@ -85 +86 @@
-@@ -1030,12 +1030,12 @@ add_guest_pages(struct virtio_net *dev, struct rte_vhost_mem_region *reg,
+@@ -1022,12 +1022,12 @@ add_guest_pages(struct virtio_net *dev, struct rte_vhost_mem_region *reg,
@@ -101 +102 @@
-@@ -1046,7 +1046,7 @@ add_guest_pages(struct virtio_net *dev, struct rte_vhost_mem_region *reg,
+@@ -1038,7 +1038,7 @@ add_guest_pages(struct virtio_net *dev, struct rte_vhost_mem_region *reg,
@@ -111,9 +112,12 @@
-@@ -1081,6 +1081,6 @@ dump_guest_pages(struct virtio_net *dev)
- 		VHOST_LOG_CONFIG(INFO, "(%s)\tguest_phys_addr: %" PRIx64 "\n",
- 				dev->ifname, page->guest_phys_addr);
--		VHOST_LOG_CONFIG(INFO, "(%s)\thost_phys_addr : %" PRIx64 "\n",
--				dev->ifname, page->host_phys_addr);
-+		VHOST_LOG_CONFIG(INFO, "(%s)\thost_iova : %" PRIx64 "\n",
-+				dev->ifname, page->host_iova);
- 		VHOST_LOG_CONFIG(INFO, "(%s)\tsize           : %" PRIx64 "\n",
- 				dev->ifname, page->size);
+@@ -1072,9 +1072,9 @@ dump_guest_pages(struct virtio_net *dev)
+ 			"guest physical page region %u\n"
+ 			"\t guest_phys_addr: %" PRIx64 "\n"
+-			"\t host_phys_addr : %" PRIx64 "\n"
++			"\t host_iova      : %" PRIx64 "\n"
+ 			"\t size           : %" PRIx64 "\n",
+ 			i,
+ 			page->guest_phys_addr,
+-			page->host_phys_addr,
++			page->host_iova,
+ 			page->size);
+ 	}
@@ -121 +125 @@
-index 886e076b28..5f432b0d77 100644
+index b3d954aab4..568d6538ed 100644
@@ -124 +128 @@
-@@ -1005,11 +1005,12 @@ async_mbuf_to_desc_seg(struct virtio_net *dev, struct vhost_virtqueue *vq,
+@@ -871,11 +871,12 @@ async_mbuf_to_desc_seg(struct virtio_net *dev, struct vhost_virtqueue *vq,
@@ -135 +139 @@
--			VHOST_LOG_DATA(ERR, "(%s) %s: failed to get hpa.\n", dev->ifname, __func__);
+-			VHOST_LOG_DATA(ERR, "(%d) %s: failed to get hpa.\n", dev->vid, __func__);
@@ -137,2 +141,2 @@
-+			VHOST_LOG_DATA(ERR, "(%s) %s: failed to get host iova.\n",
-+				       dev->ifname, __func__);
++			VHOST_LOG_DATA(ERR, "(%d) %s: failed to get host_iova.\n",
++				       dev->vid, __func__);
@@ -141 +145 @@
-@@ -1018,5 +1019,5 @@ async_mbuf_to_desc_seg(struct virtio_net *dev, struct vhost_virtqueue *vq,
+@@ -884,5 +885,5 @@ async_mbuf_to_desc_seg(struct virtio_net *dev, struct vhost_virtqueue *vq,


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

* patch 'vhost: fix unsafe vring addresses modifications' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (46 preceding siblings ...)
  2022-03-01 10:42 ` patch 'vhost: fix field naming in guest page struct' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk: fix NPC key extraction validation' " Kevin Traynor
                   ` (54 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Maxime Coquelin; +Cc: Chenbo Xia, David Marchand, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/87b639b4ed00c813627c5ce39d3eda8945d4a62d

Thanks.

Kevin

---
From 87b639b4ed00c813627c5ce39d3eda8945d4a62d Mon Sep 17 00:00:00 2001
From: Maxime Coquelin <maxime.coquelin@redhat.com>
Date: Thu, 27 Jan 2022 12:09:53 +0100
Subject: [PATCH] vhost: fix unsafe vring addresses modifications

[ upstream commit 04c27cb673b983ce2580731c0afc4b0e815fd658 ]

This patch adds missing protection around vring_invalidate
and translate_ring_addresses calls in vhost_user_iotlb_msg.

Fixes: eefac9536a90 ("vhost: postpone device creation until rings are mapped")

Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Reviewed-by: Chenbo Xia <chenbo.xia@intel.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
---
 lib/vhost/vhost_user.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 14ba3365c7..f8ca03835f 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost/vhost_user.c
@@ -2567,6 +2567,9 @@ vhost_user_iotlb_msg(struct virtio_net **pdev, struct VhostUserMsg *msg,
 					len, imsg->perm);
 
-			if (is_vring_iotlb(dev, vq, imsg))
+			if (is_vring_iotlb(dev, vq, imsg)) {
+				rte_spinlock_lock(&vq->access_lock);
 				*pdev = dev = translate_ring_addresses(dev, i);
+				rte_spinlock_unlock(&vq->access_lock);
+			}
 		}
 		break;
@@ -2581,6 +2584,9 @@ vhost_user_iotlb_msg(struct virtio_net **pdev, struct VhostUserMsg *msg,
 					imsg->size);
 
-			if (is_vring_iotlb(dev, vq, imsg))
+			if (is_vring_iotlb(dev, vq, imsg)) {
+				rte_spinlock_lock(&vq->access_lock);
 				vring_invalidate(dev, vq);
+				rte_spinlock_unlock(&vq->access_lock);
+			}
 		}
 		break;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.709305339 +0000
+++ 0049-vhost-fix-unsafe-vring-addresses-modifications.patch	2022-03-01 10:41:01.333244104 +0000
@@ -1 +1 @@
-From 04c27cb673b983ce2580731c0afc4b0e815fd658 Mon Sep 17 00:00:00 2001
+From 87b639b4ed00c813627c5ce39d3eda8945d4a62d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 04c27cb673b983ce2580731c0afc4b0e815fd658 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 8ee9c3e2db..723c6890c3 100644
+index 14ba3365c7..f8ca03835f 100644
@@ -23 +24 @@
-@@ -2565,6 +2565,9 @@ vhost_user_iotlb_msg(struct virtio_net **pdev,
+@@ -2567,6 +2567,9 @@ vhost_user_iotlb_msg(struct virtio_net **pdev, struct VhostUserMsg *msg,
@@ -34 +35 @@
-@@ -2579,6 +2582,9 @@ vhost_user_iotlb_msg(struct virtio_net **pdev,
+@@ -2581,6 +2584,9 @@ vhost_user_iotlb_msg(struct virtio_net **pdev, struct VhostUserMsg *msg,


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

* patch 'common/cnxk: fix NPC key extraction validation' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (47 preceding siblings ...)
  2022-03-01 10:42 ` patch 'vhost: fix unsafe vring addresses modifications' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/af_xdp: add missing trailing newline in logs' " Kevin Traynor
                   ` (53 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Ankur Dwivedi; +Cc: Kiran Kumar K, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 6a9b64907ede442468bf05e06f21ca7f1834ecaa Mon Sep 17 00:00:00 2001
From: Ankur Dwivedi <adwivedi@marvell.com>
Date: Mon, 7 Feb 2022 11:42:46 +0530
Subject: [PATCH] common/cnxk: fix NPC key extraction validation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 8540d7dbfcbe463c2ae988f92339a8486c5c0587 ]

The x->len is passed as argument to npc_prep_mcam_ldata().
In the function, the len is used to reference elements of
int_info and int_info_mask array.
The arrays are of length NPC_MAX_EXTRACT_DATA_LEN.

Validating the x->len value so that it is not greater than
NPC_MAX_EXTRACT_DATA_LEN.

This patch also resolves warning observed with gcc 12 compiler.

log:
 ../drivers/common/cnxk/roc_npc_utils.c:13:26: warning: writing 16 bytes
 into a region of size 0 [-Wstringop-overflow=]
 ptr[idx] = data[len - 1 - idx];

 ../drivers/common/cnxk/roc_npc_utils.c:163:17: note: at offset 64 into
 destination object ‘int_info’ of size 64
 uint8_t int_info[NPC_MAX_EXTRACT_DATA_LEN];

Bugzilla ID: 854
Fixes: 665b6a7400bf ("common/cnxk: add NPC helper API")

Signed-off-by: Ankur Dwivedi <adwivedi@marvell.com>
Reviewed-by: Kiran Kumar K <kirankumark@marvell.com>
---
 drivers/common/cnxk/roc_npc_utils.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/common/cnxk/roc_npc_utils.c b/drivers/common/cnxk/roc_npc_utils.c
index 26e104c39f..f9768ea3cf 100644
--- a/drivers/common/cnxk/roc_npc_utils.c
+++ b/drivers/common/cnxk/roc_npc_utils.c
@@ -167,4 +167,7 @@ npc_update_extraction_data(struct npc_parse_state *pst,
 
 	x = xinfo;
+	if (x->len > NPC_MAX_EXTRACT_DATA_LEN)
+		return NPC_ERR_INVALID_SIZE;
+
 	len = x->len;
 	hdr_off = x->hdr_off;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.742747294 +0000
+++ 0050-common-cnxk-fix-NPC-key-extraction-validation.patch	2022-03-01 10:41:01.333244104 +0000
@@ -1 +1 @@
-From 8540d7dbfcbe463c2ae988f92339a8486c5c0587 Mon Sep 17 00:00:00 2001
+From 6a9b64907ede442468bf05e06f21ca7f1834ecaa Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 8540d7dbfcbe463c2ae988f92339a8486c5c0587 ]
+
@@ -30 +31,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/af_xdp: add missing trailing newline in logs' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (48 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk: fix NPC key extraction validation' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk: add missing checks of return values' " Kevin Traynor
                   ` (52 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: David Marchand; +Cc: Ciara Loftus, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From dd1851c1de7ecfd64e6c8263fcec73f3bda24ff6 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand@redhat.com>
Date: Thu, 17 Feb 2022 14:06:14 +0100
Subject: [PATCH] net/af_xdp: add missing trailing newline in logs

[ upstream commit 744fd4126937b7f195fac38ae24cab52d0922b04 ]

Caught while trying --in-memory mode, some log messages in this driver
are not terminated with a newline:
rte_pmd_af_xdp_probe(): net_af_xdp: Failed to register multi-process IPC
callback: Operation not supportedvdev_probe(): failed to initialize
net_af_xdp device

Other locations in this driver had the same issue, fix all at once.

Fixes: f1debd77efaf ("net/af_xdp: introduce AF_XDP PMD")
Fixes: d8a210774e1d ("net/af_xdp: support unaligned umem chunks")
Fixes: 9876cf8316b3 ("net/af_xdp: re-enable secondary process support")

Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Ciara Loftus <ciara.loftus@intel.com>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index b3ed704b36..d7e46c0aa5 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -1052,5 +1052,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
 					  rte_socket_id());
 		if (umem == NULL) {
-			AF_XDP_LOG(ERR, "Failed to allocate umem info");
+			AF_XDP_LOG(ERR, "Failed to allocate umem info\n");
 			return NULL;
 		}
@@ -1065,5 +1065,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
 				&rxq->fq, &rxq->cq, &usr_config);
 		if (ret) {
-			AF_XDP_LOG(ERR, "Failed to create umem");
+			AF_XDP_LOG(ERR, "Failed to create umem\n");
 			goto err;
 		}
@@ -1099,5 +1099,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
 	umem = rte_zmalloc_socket("umem", sizeof(*umem), 0, rte_socket_id());
 	if (umem == NULL) {
-		AF_XDP_LOG(ERR, "Failed to allocate umem info");
+		AF_XDP_LOG(ERR, "Failed to allocate umem info\n");
 		return NULL;
 	}
@@ -1135,5 +1135,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
 
 	if (ret) {
-		AF_XDP_LOG(ERR, "Failed to create umem");
+		AF_XDP_LOG(ERR, "Failed to create umem\n");
 		goto err;
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.772756235 +0000
+++ 0051-net-af_xdp-add-missing-trailing-newline-in-logs.patch	2022-03-01 10:41:01.334244104 +0000
@@ -1 +1 @@
-From 744fd4126937b7f195fac38ae24cab52d0922b04 Mon Sep 17 00:00:00 2001
+From dd1851c1de7ecfd64e6c8263fcec73f3bda24ff6 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 744fd4126937b7f195fac38ae24cab52d0922b04 ]
+
@@ -17 +18,0 @@
-Cc: stable@dpdk.org
@@ -22,2 +23,2 @@
- drivers/net/af_xdp/rte_eth_af_xdp.c | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
+ drivers/net/af_xdp/rte_eth_af_xdp.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
@@ -26 +27 @@
-index 2163df7c5c..69dfa1b898 100644
+index b3ed704b36..d7e46c0aa5 100644
@@ -29 +30 @@
-@@ -1072,5 +1072,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
+@@ -1052,5 +1052,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
@@ -36 +37 @@
-@@ -1085,5 +1085,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
+@@ -1065,5 +1065,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
@@ -43 +44 @@
-@@ -1125,5 +1125,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
+@@ -1099,5 +1099,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
@@ -50 +51 @@
-@@ -1161,5 +1161,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
+@@ -1135,5 +1135,5 @@ xsk_umem_info *xdp_umem_configure(struct pmd_internals *internals,
@@ -57,14 +57,0 @@
-@@ -1848,5 +1848,5 @@ afxdp_mp_request_fds(const char *name, struct rte_eth_dev *dev)
- 	ret = rte_mp_request_sync(&request, &replies, &timeout);
- 	if (ret < 0 || replies.nb_received != 1) {
--		AF_XDP_LOG(ERR, "Failed to request fds from primary: %d",
-+		AF_XDP_LOG(ERR, "Failed to request fds from primary: %d\n",
- 			   rte_errno);
- 		return -1;
-@@ -1997,5 +1997,5 @@ rte_pmd_af_xdp_probe(struct rte_vdev_device *dev)
- 		ret = rte_mp_action_register(ETH_AF_XDP_MP_KEY, afxdp_mp_send_fds);
- 		if (ret < 0 && rte_errno != ENOTSUP) {
--			AF_XDP_LOG(ERR, "%s: Failed to register multi-process IPC callback: %s",
-+			AF_XDP_LOG(ERR, "%s: Failed to register multi-process IPC callback: %s\n",
- 				   name, strerror(rte_errno));
- 			return -1;


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

* patch 'common/cnxk: add missing checks of return values' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (49 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/af_xdp: add missing trailing newline in logs' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk fix unintended sign extension' " Kevin Traynor
                   ` (51 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 7eeb8d37ed5884fce3d62c9fd7459b1ceb503f58 Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Sat, 12 Feb 2022 18:08:18 +0530
Subject: [PATCH] common/cnxk: add missing checks of return values

[ upstream commit 14f7e5d4bf2d2c90c715b7d1cf1a973829289499 ]

This patch fixes coverity issue by adding checks on return values.

Coverity issue: 373628, 374858, 370213, 370215
Fixes: af75aac78978 ("common/cnxk: support telemetry for NIX")
Fixes: d61138d4f0e2 ("drivers: remove direct access to interrupt handle")
Fixes: fcdef46b6698 ("common/cnxk: support NIX TM debug and misc utils")
Fixes: df405df95eeb ("common/cnxk: add NIX TM helper to alloc/free resource")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/common/cnxk/cnxk_telemetry_nix.c | 3 +++
 drivers/common/cnxk/roc_irq.c            | 5 ++++-
 drivers/common/cnxk/roc_nix_debug.c      | 4 +++-
 drivers/common/cnxk/roc_nix_tm.c         | 6 ++++--
 4 files changed, 14 insertions(+), 4 deletions(-)

diff --git a/drivers/common/cnxk/cnxk_telemetry_nix.c b/drivers/common/cnxk/cnxk_telemetry_nix.c
index df6458039d..4119e9ee4f 100644
--- a/drivers/common/cnxk/cnxk_telemetry_nix.c
+++ b/drivers/common/cnxk/cnxk_telemetry_nix.c
@@ -766,4 +766,7 @@ cnxk_nix_tel_handle_info_x(const char *cmd, const char *params,
 	plt_strlcpy(buf, params, PCI_PRI_STR_SIZE + 1);
 	name = strtok(buf, ",");
+	if (name == NULL)
+		goto exit;
+
 	param = strtok(NULL, "\0");
 
diff --git a/drivers/common/cnxk/roc_irq.c b/drivers/common/cnxk/roc_irq.c
index 7a24297d72..010b121176 100644
--- a/drivers/common/cnxk/roc_irq.c
+++ b/drivers/common/cnxk/roc_irq.c
@@ -161,5 +161,8 @@ dev_irq_register(struct plt_intr_handle *intr_handle, plt_intr_callback_fn cb,
 	}
 
-	plt_intr_efds_index_set(intr_handle, vec, fd);
+	rc = plt_intr_efds_index_set(intr_handle, vec, fd);
+	if (rc)
+		return rc;
+
 	nb_efd = (vec > (uint32_t)plt_intr_nb_efd_get(intr_handle)) ?
 		vec : (uint32_t)plt_intr_nb_efd_get(intr_handle);
diff --git a/drivers/common/cnxk/roc_nix_debug.c b/drivers/common/cnxk/roc_nix_debug.c
index 7dc54f3845..9829c13b69 100644
--- a/drivers/common/cnxk/roc_nix_debug.c
+++ b/drivers/common/cnxk/roc_nix_debug.c
@@ -53,5 +53,7 @@ nix_bitmap_dump(struct plt_bitmap *bmp)
 
 	plt_bitmap_scan_init(bmp);
-	plt_bitmap_scan(bmp, &pos, &slab);
+	if (!plt_bitmap_scan(bmp, &pos, &slab))
+		return;
+
 	start_pos = pos;
 
diff --git a/drivers/common/cnxk/roc_nix_tm.c b/drivers/common/cnxk/roc_nix_tm.c
index ebb27a3106..e765fe703c 100644
--- a/drivers/common/cnxk/roc_nix_tm.c
+++ b/drivers/common/cnxk/roc_nix_tm.c
@@ -1017,6 +1017,8 @@ nix_tm_assign_hw_id(struct nix *nix, struct nix_tm_node *parent,
 		}
 
-		if (!slab)
-			plt_bitmap_scan(bmp, &pos, &slab);
+		if (!slab) {
+			if (!plt_bitmap_scan(bmp, &pos, &slab))
+				return -ENOENT;
+		}
 
 		if (child->priority == parent->rr_prio && spare_schq != -1) {
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.803239831 +0000
+++ 0052-common-cnxk-add-missing-checks-of-return-values.patch	2022-03-01 10:41:01.337244105 +0000
@@ -1 +1 @@
-From 14f7e5d4bf2d2c90c715b7d1cf1a973829289499 Mon Sep 17 00:00:00 2001
+From 7eeb8d37ed5884fce3d62c9fd7459b1ceb503f58 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 14f7e5d4bf2d2c90c715b7d1cf1a973829289499 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -51 +52 @@
-index d5143882f5..1ae045172e 100644
+index 7dc54f3845..9829c13b69 100644
@@ -64 +65 @@
-index a0448bec61..517502b1af 100644
+index ebb27a3106..e765fe703c 100644


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

* patch 'common/cnxk fix unintended sign extension' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (50 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk: add missing checks of return values' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/cnxk: fix uninitialized pointer read' " Kevin Traynor
                   ` (50 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 2f61027cda110f1fe3a1006171768cf1b37cf752 Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Sat, 12 Feb 2022 18:08:19 +0530
Subject: [PATCH] common/cnxk fix unintended sign extension

[ upstream commit 2447b0b6695d4cecb8606d4c069564f35c31b1d4 ]

This patch fixes unintended sign extensions reported in coverity
scan.

Coverity issue: 373258
Fixes: 8ca851cdc598 ("common/cnxk: support dual VLAN insert and strip actions")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/common/cnxk/roc_npc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/common/cnxk/roc_npc.c b/drivers/common/cnxk/roc_npc.c
index 8386e0e956..5ee7ff5e41 100644
--- a/drivers/common/cnxk/roc_npc.c
+++ b/drivers/common/cnxk/roc_npc.c
@@ -970,5 +970,5 @@ npc_vtag_insert_action_configure(struct mbox *mbox, struct roc_npc_flow *flow,
 	vtag_cfg->vtag_size = NIX_VTAGSIZE_T4;
 	vtag_cfg->tx.vtag0 =
-		((vlan_info[0].vlan_ethtype << 16) |
+		(((uint32_t)vlan_info[0].vlan_ethtype << 16) |
 		 (vlan_info[0].vlan_pcp << 13) | vlan_info[0].vlan_id);
 
@@ -977,5 +977,5 @@ npc_vtag_insert_action_configure(struct mbox *mbox, struct roc_npc_flow *flow,
 	if (flow->vtag_insert_count == 2) {
 		vtag_cfg->tx.vtag1 =
-			((vlan_info[1].vlan_ethtype << 16) |
+			(((uint32_t)vlan_info[1].vlan_ethtype << 16) |
 			 (vlan_info[1].vlan_pcp << 13) | vlan_info[1].vlan_id);
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.836453043 +0000
+++ 0053-common-cnxk-fix-unintended-sign-extension.patch	2022-03-01 10:41:01.338244105 +0000
@@ -1 +1 @@
-From 2447b0b6695d4cecb8606d4c069564f35c31b1d4 Mon Sep 17 00:00:00 2001
+From 2f61027cda110f1fe3a1006171768cf1b37cf752 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 2447b0b6695d4cecb8606d4c069564f35c31b1d4 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index df3016f538..245eb8b74f 100644
+index 8386e0e956..5ee7ff5e41 100644


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

* patch 'common/cnxk: fix uninitialized pointer read' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (51 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk fix unintended sign extension' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/cnxk: fix uninitialized local variable' " Kevin Traynor
                   ` (49 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From f0cfb0e3d1be408568122ac971800375ec47e37c Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Sat, 12 Feb 2022 18:08:20 +0530
Subject: [PATCH] common/cnxk: fix uninitialized pointer read

[ upstream commit 244a996f0149c2c3ae82e0bc6cc2abc4eb87656b ]

Fix uninitialized pointer read reported in coverity scan.

Coverity issue: 370214, 370217, 370219, 370220, 370221
Coverity issue: 370223, 370224, 370225, 372065
Fixes: c34ea71b878d ("common/cnxk: add NPC parsing API")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/common/cnxk/roc_npc_parse.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/drivers/common/cnxk/roc_npc_parse.c b/drivers/common/cnxk/roc_npc_parse.c
index 8125035dd8..4f915f3692 100644
--- a/drivers/common/cnxk/roc_npc_parse.c
+++ b/drivers/common/cnxk/roc_npc_parse.c
@@ -39,4 +39,5 @@ npc_parse_cpt_hdr(struct npc_parse_state *pst)
 
 	/* Prepare for parsing the item */
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.len = pst->pattern->size;
@@ -76,4 +77,5 @@ npc_parse_higig2_hdr(struct npc_parse_state *pst)
 
 	/* Prepare for parsing the item */
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.len = pst->pattern->size;
@@ -122,4 +124,5 @@ npc_parse_la(struct npc_parse_state *pst)
 
 	/* Prepare for parsing the item */
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.len = pst->pattern->size;
@@ -180,4 +183,5 @@ npc_parse_lb(struct npc_parse_state *pst)
 	int rc;
 
+	info.def_mask = NULL;
 	info.spec = NULL;
 	info.mask = NULL;
@@ -308,4 +312,5 @@ npc_parse_mpls_label_stack(struct npc_parse_state *pst, int *flag)
 	 * that subsequent labels do not have anything to match.
 	 */
+	info.def_mask = NULL;
 	info.hw_mask = NULL;
 	info.len = pattern->size;
@@ -313,5 +318,4 @@ npc_parse_mpls_label_stack(struct npc_parse_state *pst, int *flag)
 	info.mask = NULL;
 	info.hw_hdr_len = 0;
-	info.def_mask = NULL;
 
 	while (pattern->type == ROC_NPC_ITEM_TYPE_MPLS) {
@@ -359,4 +363,5 @@ npc_parse_mpls(struct npc_parse_state *pst, int lid)
 	info.spec = NULL;
 	info.mask = NULL;
+	info.def_mask = NULL;
 	info.hw_hdr_len = 0;
 
@@ -406,4 +411,5 @@ npc_parse_lc(struct npc_parse_state *pst)
 		return npc_parse_mpls(pst, NPC_LID_LC);
 
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.spec = NULL;
@@ -493,8 +499,8 @@ npc_parse_ld(struct npc_parse_state *pst)
 		return 0;
 	}
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.spec = NULL;
 	info.mask = NULL;
-	info.def_mask = NULL;
 	info.len = 0;
 	info.hw_hdr_len = 0;
@@ -652,4 +658,5 @@ npc_parse_lf(struct npc_parse_state *pst)
 
 	/* No match support for vlan tags */
+	info.def_mask = NULL;
 	info.hw_mask = NULL;
 	info.len = pst->pattern->size;
@@ -710,4 +717,5 @@ npc_parse_lg(struct npc_parse_state *pst)
 		return 0;
 
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.spec = NULL;
@@ -746,4 +754,5 @@ npc_parse_lh(struct npc_parse_state *pst)
 		return 0;
 
+	info.def_mask = NULL;
 	info.hw_mask = &hw_mask;
 	info.spec = NULL;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.866989486 +0000
+++ 0054-common-cnxk-fix-uninitialized-pointer-read.patch	2022-03-01 10:41:01.339244105 +0000
@@ -1 +1 @@
-From 244a996f0149c2c3ae82e0bc6cc2abc4eb87656b Mon Sep 17 00:00:00 2001
+From f0cfb0e3d1be408568122ac971800375ec47e37c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 244a996f0149c2c3ae82e0bc6cc2abc4eb87656b ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 302ab66efc..b849326a19 100644
+index 8125035dd8..4f915f3692 100644
@@ -23 +24 @@
-@@ -113,4 +113,5 @@ npc_parse_cpt_hdr(struct npc_parse_state *pst)
+@@ -39,4 +39,5 @@ npc_parse_cpt_hdr(struct npc_parse_state *pst)
@@ -29 +30 @@
-@@ -150,4 +151,5 @@ npc_parse_higig2_hdr(struct npc_parse_state *pst)
+@@ -76,4 +77,5 @@ npc_parse_higig2_hdr(struct npc_parse_state *pst)
@@ -35 +36 @@
-@@ -199,4 +201,5 @@ npc_parse_la(struct npc_parse_state *pst)
+@@ -122,4 +124,5 @@ npc_parse_la(struct npc_parse_state *pst)
@@ -40,2 +41,2 @@
- 	info.len = sizeof(eth_item->hdr);
-@@ -237,4 +240,5 @@ npc_parse_lb(struct npc_parse_state *pst)
+ 	info.len = pst->pattern->size;
+@@ -180,4 +183,5 @@ npc_parse_lb(struct npc_parse_state *pst)
@@ -47 +48 @@
-@@ -397,4 +401,5 @@ npc_parse_mpls_label_stack(struct npc_parse_state *pst, int *flag)
+@@ -308,4 +312,5 @@ npc_parse_mpls_label_stack(struct npc_parse_state *pst, int *flag)
@@ -53 +54 @@
-@@ -402,5 +407,4 @@ npc_parse_mpls_label_stack(struct npc_parse_state *pst, int *flag)
+@@ -313,5 +318,4 @@ npc_parse_mpls_label_stack(struct npc_parse_state *pst, int *flag)
@@ -59 +60 @@
-@@ -448,4 +452,5 @@ npc_parse_mpls(struct npc_parse_state *pst, int lid)
+@@ -359,4 +363,5 @@ npc_parse_mpls(struct npc_parse_state *pst, int lid)
@@ -65 +66 @@
-@@ -548,4 +553,5 @@ npc_parse_lc(struct npc_parse_state *pst)
+@@ -406,4 +411,5 @@ npc_parse_lc(struct npc_parse_state *pst)
@@ -71 +72 @@
-@@ -641,8 +647,8 @@ npc_parse_ld(struct npc_parse_state *pst)
+@@ -493,8 +499,8 @@ npc_parse_ld(struct npc_parse_state *pst)
@@ -81 +82 @@
-@@ -800,4 +806,5 @@ npc_parse_lf(struct npc_parse_state *pst)
+@@ -652,4 +658,5 @@ npc_parse_lf(struct npc_parse_state *pst)
@@ -87 +88 @@
-@@ -858,4 +865,5 @@ npc_parse_lg(struct npc_parse_state *pst)
+@@ -710,4 +717,5 @@ npc_parse_lg(struct npc_parse_state *pst)
@@ -93 +94 @@
-@@ -894,4 +902,5 @@ npc_parse_lh(struct npc_parse_state *pst)
+@@ -746,4 +754,5 @@ npc_parse_lh(struct npc_parse_state *pst)


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

* patch 'net/cnxk: fix uninitialized local variable' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (52 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/cnxk: fix uninitialized pointer read' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/sfc_efx/base: fix recirculation ID set in outer rules' " Kevin Traynor
                   ` (48 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e4b43ee28c8b470b31deeb0af78561a9c121c5ef Mon Sep 17 00:00:00 2001
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Date: Sat, 12 Feb 2022 18:11:00 +0530
Subject: [PATCH] net/cnxk: fix uninitialized local variable

[ upstream commit e8cda505fa7ba143de816b08b0237cff0c8111dd ]

Fix uninitialized local variable as reported by coverity scan.

Coverity issue: 373630
Fixes: 6af19a9d89bf ("net/cnxk: support meter action to flow destroy")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/net/cnxk/cnxk_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/cnxk/cnxk_ethdev.c b/drivers/net/cnxk/cnxk_ethdev.c
index 74f625553d..a90c2ae321 100644
--- a/drivers/net/cnxk/cnxk_ethdev.c
+++ b/drivers/net/cnxk/cnxk_ethdev.c
@@ -178,5 +178,5 @@ nix_meter_fini(struct cnxk_eth_dev *dev)
 	struct roc_nix_rq *rq;
 	uint32_t i;
-	int rc;
+	int rc = 0;
 
 	RTE_TAILQ_FOREACH_SAFE(mtr, fms, next, next_mtr) {
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.896035799 +0000
+++ 0055-net-cnxk-fix-uninitialized-local-variable.patch	2022-03-01 10:41:01.340244105 +0000
@@ -1 +1 @@
-From e8cda505fa7ba143de816b08b0237cff0c8111dd Mon Sep 17 00:00:00 2001
+From e4b43ee28c8b470b31deeb0af78561a9c121c5ef Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e8cda505fa7ba143de816b08b0237cff0c8111dd ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 27751a6956..4ab87e49ea 100644
+index 74f625553d..a90c2ae321 100644


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

* patch 'common/sfc_efx/base: fix recirculation ID set in outer rules' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (53 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/cnxk: fix uninitialized local variable' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/sfc_efx/base: add missing handler for 1-byte fields' " Kevin Traynor
                   ` (47 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Ivan Malov; +Cc: Andy Moreton, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/4874f1d005ca2c6491cdd6dfcc3654e430bb165f

Thanks.

Kevin

---
From 4874f1d005ca2c6491cdd6dfcc3654e430bb165f Mon Sep 17 00:00:00 2001
From: Ivan Malov <ivan.malov@oktetlabs.ru>
Date: Fri, 18 Feb 2022 01:25:07 +0300
Subject: [PATCH] common/sfc_efx/base: fix recirculation ID set in outer rules

[ upstream commit b4dd34c7f751a516b08139784b9ef8ece04fc659 ]

Recirculation ID field of MAE outer rule insert MCDI is
part of the lookup control structure and it has non-zero
bit offset relative to the byte offset of the structure.

Fixes: 5cf153e79c6c ("common/sfc_efx/base: support recirculation ID in outer rules")

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Reviewed-by: Andy Moreton <amoreton@xilinx.com>
---
 drivers/common/sfc_efx/base/efx_mae.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/common/sfc_efx/base/efx_mae.c b/drivers/common/sfc_efx/base/efx_mae.c
index 7b24e3fee4..7d48b5787e 100644
--- a/drivers/common/sfc_efx/base/efx_mae.c
+++ b/drivers/common/sfc_efx/base/efx_mae.c
@@ -2243,5 +2243,6 @@ efx_mae_outer_rule_insert(
 	    MAE_ENC_FIELD_PAIRS_LEN);
 
-	MCDI_IN_SET_BYTE(req, MAE_OUTER_RULE_INSERT_IN_RECIRC_ID,
+	MCDI_IN_SET_DWORD_FIELD(req, MAE_OUTER_RULE_INSERT_IN_LOOKUP_CONTROL,
+	    MAE_OUTER_RULE_INSERT_IN_RECIRC_ID,
 	    spec->emms_outer_rule_recirc_id);
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.923259937 +0000
+++ 0056-common-sfc_efx-base-fix-recirculation-ID-set-in-oute.patch	2022-03-01 10:41:01.342244106 +0000
@@ -1 +1 @@
-From b4dd34c7f751a516b08139784b9ef8ece04fc659 Mon Sep 17 00:00:00 2001
+From 4874f1d005ca2c6491cdd6dfcc3654e430bb165f Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b4dd34c7f751a516b08139784b9ef8ece04fc659 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org


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

* patch 'common/sfc_efx/base: add missing handler for 1-byte fields' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (54 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/sfc_efx/base: fix recirculation ID set in outer rules' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/sfc: fix flow tunnel support detection' " Kevin Traynor
                   ` (46 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Ivan Malov; +Cc: Andrew Rybchenko, Andy Moreton, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From a58ae9af989c3697f911cbc0f01d83949c54fd9c Mon Sep 17 00:00:00 2001
From: Ivan Malov <ivan.malov@oktetlabs.ru>
Date: Fri, 18 Feb 2022 01:25:08 +0300
Subject: [PATCH] common/sfc_efx/base: add missing handler for 1-byte fields

[ upstream commit a3b2ade480f659f580aa7095e7f8d0d5810236ea ]

One may set RECIRC_ID in a MAE action rule specification.
This field is not a network one, and its handling goes
to the code snippet which does not recognise field
sizes other than 4 bytes. Add the missing handler.

Fixes: 3a73dcfdb255 ("common/sfc_efx/base: match on recirc ID in action rules")

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Reviewed-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Reviewed-by: Andy Moreton <amoreton@xilinx.com>
---
 drivers/common/sfc_efx/base/efx_mae.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/common/sfc_efx/base/efx_mae.c b/drivers/common/sfc_efx/base/efx_mae.c
index 7d48b5787e..31f51b5548 100644
--- a/drivers/common/sfc_efx/base/efx_mae.c
+++ b/drivers/common/sfc_efx/base/efx_mae.c
@@ -1028,4 +1028,8 @@ efx_mae_match_spec_field_set(
 			    &dword, sizeof (dword));
 			break;
+		case 1:
+			memcpy(mvp + descp->emmd_value_offset,
+			    value, 1);
+			break;
 		default:
 			EFSYS_ASSERT(B_FALSE);
@@ -1040,4 +1044,8 @@ efx_mae_match_spec_field_set(
 			    &dword, sizeof (dword));
 			break;
+		case 1:
+			memcpy(mvp + descp->emmd_mask_offset,
+			    mask, 1);
+			break;
 		default:
 			EFSYS_ASSERT(B_FALSE);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.952706890 +0000
+++ 0057-common-sfc_efx-base-add-missing-handler-for-1-byte-f.patch	2022-03-01 10:41:01.343244106 +0000
@@ -1 +1 @@
-From a3b2ade480f659f580aa7095e7f8d0d5810236ea Mon Sep 17 00:00:00 2001
+From a58ae9af989c3697f911cbc0f01d83949c54fd9c Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a3b2ade480f659f580aa7095e7f8d0d5810236ea ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/sfc: fix flow tunnel support detection' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (55 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/sfc_efx/base: add missing handler for 1-byte fields' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/sfc: fix memory allocation size for cache' " Kevin Traynor
                   ` (45 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Ivan Malov; +Cc: Andrew Rybchenko, Andy Moreton, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From ea21c6bf4ee80c65f0afabfa94cbd2087782abc2 Mon Sep 17 00:00:00 2001
From: Ivan Malov <ivan.malov@oktetlabs.ru>
Date: Fri, 18 Feb 2022 01:25:09 +0300
Subject: [PATCH] net/sfc: fix flow tunnel support detection

[ upstream commit de32ec32d720ca3070a48a24da1a18eb315003fe ]

The condition for that must use the new MAE admin status.

Fixes: 2f577f0ea1a3 ("net/sfc: allow ports without MAE privilege")

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Reviewed-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Reviewed-by: Andy Moreton <amoreton@xilinx.com>
---
 drivers/net/sfc/sfc_flow_tunnel.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/sfc/sfc_flow_tunnel.c b/drivers/net/sfc/sfc_flow_tunnel.c
index 463b01c596..e9eca90012 100644
--- a/drivers/net/sfc/sfc_flow_tunnel.c
+++ b/drivers/net/sfc/sfc_flow_tunnel.c
@@ -22,5 +22,5 @@ sfc_flow_tunnel_is_supported(struct sfc_adapter *sa)
 
 	return ((sa->priv.dp_rx->features & SFC_DP_RX_FEAT_FLOW_MARK) != 0 &&
-		sa->mae.status == SFC_MAE_STATUS_SUPPORTED);
+		sa->mae.status == SFC_MAE_STATUS_ADMIN);
 }
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:02.981335532 +0000
+++ 0058-net-sfc-fix-flow-tunnel-support-detection.patch	2022-03-01 10:41:01.344244106 +0000
@@ -1 +1 @@
-From de32ec32d720ca3070a48a24da1a18eb315003fe Mon Sep 17 00:00:00 2001
+From ea21c6bf4ee80c65f0afabfa94cbd2087782abc2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit de32ec32d720ca3070a48a24da1a18eb315003fe ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/sfc: fix memory allocation size for cache' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (56 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/sfc: fix flow tunnel support detection' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/af_xdp: ensure socket is deleted on Rx queue setup error' " Kevin Traynor
                   ` (44 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Weiguo Li; +Cc: Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From ae2f030ad19a8b3d452cea3c73422dce35c6ed20 Mon Sep 17 00:00:00 2001
From: Weiguo Li <liwg06@foxmail.com>
Date: Tue, 21 Dec 2021 14:41:22 +0800
Subject: [PATCH] net/sfc: fix memory allocation size for cache

[ upstream commit b0fed38467713807ac03d50ae7c02ef4c320470a ]

The size of unit cache should be sizeof(**cache) instead of
sizeof(*cache). Memory reallocation is inadequate by sizeof(*cache)
for the platform whose size of pointer is 32-bits. Found by coccinelle
(see https://coccinelle.gitlabpages.inria.fr/website) script.

Fixes: 63abf8d29225 ("net/sfc: support SW stats groups")

Signed-off-by: Weiguo Li <liwg06@foxmail.com>
Reviewed-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
---
 drivers/net/sfc/sfc_sw_stats.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/sfc/sfc_sw_stats.c b/drivers/net/sfc/sfc_sw_stats.c
index 70259660c0..81f5aa3cc4 100644
--- a/drivers/net/sfc/sfc_sw_stats.c
+++ b/drivers/net/sfc/sfc_sw_stats.c
@@ -778,5 +778,5 @@ sfc_sw_xstats_configure(struct sfc_adapter *sa)
 	memset(*reset_vals, 0, nb_supported * sizeof(**reset_vals));
 
-	*cache = rte_realloc(*cache, cache_count * sizeof(*cache), 0);
+	*cache = rte_realloc(*cache, cache_count * sizeof(**cache), 0);
 	if (*cache == NULL) {
 		rc = ENOMEM;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.007120920 +0000
+++ 0059-net-sfc-fix-memory-allocation-size-for-cache.patch	2022-03-01 10:41:01.345244106 +0000
@@ -1 +1 @@
-From b0fed38467713807ac03d50ae7c02ef4c320470a Mon Sep 17 00:00:00 2001
+From ae2f030ad19a8b3d452cea3c73422dce35c6ed20 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b0fed38467713807ac03d50ae7c02ef4c320470a ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/af_xdp: ensure socket is deleted on Rx queue setup error' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (57 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/sfc: fix memory allocation size for cache' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ice: fix overwriting of LSE bit by DCF' " Kevin Traynor
                   ` (43 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Ciara Loftus; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From a628e2bf191fcceceab538aa40750d75fec4f5fd Mon Sep 17 00:00:00 2001
From: Ciara Loftus <ciara.loftus@intel.com>
Date: Fri, 18 Feb 2022 11:20:36 +0000
Subject: [PATCH] net/af_xdp: ensure socket is deleted on Rx queue setup error

[ upstream commit b26431a617e4039e6c0f65c5ee56f62f347b686b ]

The Rx queue setup can fail for many reasons eg. failure to setup the
custom program, failure to allocate or reserve fill queue buffers,
failure to configure busy polling etc. When a failure like one of these
occurs, if the xsk is already set up it should be deleted before
returning. This commit ensures this happens.

Fixes: d8a210774e1d ("net/af_xdp: support unaligned umem chunks")
Fixes: 288a85aef192 ("net/af_xdp: enable custom XDP program loading")
Fixes: 055a393626ed ("net/af_xdp: prefer busy polling")
Fixes: 01fa83c94d7e ("net/af_xdp: workaround custom program loading")

Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index d7e46c0aa5..958f18e6d5 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -1277,5 +1277,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
 			AF_XDP_LOG(ERR, "Failed to load custom XDP program %s\n",
 					internals->prog_path);
-			goto err;
+			goto out_umem;
 		}
 		internals->custom_prog_configured = 1;
@@ -1294,5 +1294,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
 	if (ret) {
 		AF_XDP_LOG(ERR, "Failed to create xsk socket.\n");
-		goto err;
+		goto out_umem;
 	}
 
@@ -1306,5 +1306,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
 		if (err) {
 			AF_XDP_LOG(ERR, "Failed to insert xsk in map.\n");
-			goto err;
+			goto out_xsk;
 		}
 	}
@@ -1314,5 +1314,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
 	if (ret) {
 		AF_XDP_LOG(DEBUG, "Failed to get enough buffers for fq.\n");
-		goto err;
+		goto out_xsk;
 	}
 #endif
@@ -1322,5 +1322,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
 		if (ret) {
 			AF_XDP_LOG(ERR, "Failed configure busy polling.\n");
-			goto err;
+			goto out_xsk;
 		}
 	}
@@ -1328,12 +1328,13 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
 	ret = reserve_fill_queue(rxq->umem, reserve_size, fq_bufs, &rxq->fq);
 	if (ret) {
-		xsk_socket__delete(rxq->xsk);
 		AF_XDP_LOG(ERR, "Failed to reserve fill queue.\n");
-		goto err;
+		goto out_xsk;
 	}
 
 	return 0;
 
-err:
+out_xsk:
+	xsk_socket__delete(rxq->xsk);
+out_umem:
 	if (__atomic_sub_fetch(&rxq->umem->refcnt, 1, __ATOMIC_ACQUIRE) == 0)
 		xdp_umem_destroy(rxq->umem);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.033249882 +0000
+++ 0060-net-af_xdp-ensure-socket-is-deleted-on-Rx-queue-setu.patch	2022-03-01 10:41:01.346244106 +0000
@@ -1 +1 @@
-From b26431a617e4039e6c0f65c5ee56f62f347b686b Mon Sep 17 00:00:00 2001
+From a628e2bf191fcceceab538aa40750d75fec4f5fd Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b26431a617e4039e6c0f65c5ee56f62f347b686b ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -24 +25 @@
-index 2477f31c7b..7d5e2887b8 100644
+index d7e46c0aa5..958f18e6d5 100644
@@ -27 +28 @@
-@@ -1302,5 +1302,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
+@@ -1277,5 +1277,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
@@ -34 +35 @@
-@@ -1319,5 +1319,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
+@@ -1294,5 +1294,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
@@ -41 +42 @@
-@@ -1331,5 +1331,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
+@@ -1306,5 +1306,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
@@ -48 +49 @@
-@@ -1339,5 +1339,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
+@@ -1314,5 +1314,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
@@ -55 +56 @@
-@@ -1347,5 +1347,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
+@@ -1322,5 +1322,5 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
@@ -62 +63 @@
-@@ -1353,12 +1353,13 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,
+@@ -1328,12 +1328,13 @@ xsk_configure(struct pmd_internals *internals, struct pkt_rx_queue *rxq,


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

* patch 'net/ice: fix overwriting of LSE bit by DCF' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (58 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/af_xdp: ensure socket is deleted on Rx queue setup error' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/iavf: fix segmentation offload condition' " Kevin Traynor
                   ` (42 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Wilczynski; +Cc: Haiyue Wang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From d75be6c28dbf71900fbdc6a57f7d5e692179c35d Mon Sep 17 00:00:00 2001
From: Michal Wilczynski <michal.wilczynski@intel.com>
Date: Fri, 18 Feb 2022 12:57:19 +0100
Subject: [PATCH] net/ice: fix overwriting of LSE bit by DCF

[ upstream commit ea9fac93e1ca1f0684b2ccdad9467a7760b4a3eb ]

After enabling DCF on a VF, the ice driver stops receiving
link updates on it's Admin Receive Queue. During the init
of DCF ice_aqc_opc_get_link_status command is send to the
firmware without LSE (Link Status Event) bit set. This prevents
the ice driver from receiving up/down events, and correspondingly
updating netdev.

Fixes: 0b02c9519432 ("net/ice: handle PF initialization by DCF")

Signed-off-by: Michal Wilczynski <michal.wilczynski@intel.com>
Acked-by: Haiyue Wang <haiyue.wang@intel.com>
---
 drivers/net/ice/ice_dcf_parent.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ice/ice_dcf_parent.c b/drivers/net/ice/ice_dcf_parent.c
index 0c8c2ed6c7..2f96dedcce 100644
--- a/drivers/net/ice/ice_dcf_parent.c
+++ b/drivers/net/ice/ice_dcf_parent.c
@@ -341,5 +341,5 @@ ice_dcf_init_parent_hw(struct ice_hw *hw)
 
 	/* Initialize port_info struct with link information */
-	status = ice_aq_get_link_info(hw->port_info, false, NULL, NULL);
+	status = ice_aq_get_link_info(hw->port_info, true, NULL, NULL);
 	if (status)
 		goto err_unroll_alloc;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.059975257 +0000
+++ 0061-net-ice-fix-overwriting-of-LSE-bit-by-DCF.patch	2022-03-01 10:41:01.346244106 +0000
@@ -1 +1 @@
-From ea9fac93e1ca1f0684b2ccdad9467a7760b4a3eb Mon Sep 17 00:00:00 2001
+From d75be6c28dbf71900fbdc6a57f7d5e692179c35d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ea9fac93e1ca1f0684b2ccdad9467a7760b4a3eb ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/iavf: fix segmentation offload condition' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (59 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ice: fix overwriting of LSE bit by DCF' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/iavf: fix segmentation offload buffer size' " Kevin Traynor
                   ` (41 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From dbb1c537251dea2dba61bdf91cb0e74aa408f920 Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Mon, 22 Nov 2021 15:30:00 +0000
Subject: [PATCH] net/iavf: fix segmentation offload condition

[ upstream commit ff8b8bcd2ebef5d951bf442c44a71b0b3a0413c9 ]

Apply segmentation offload when requested for non tunneled
packets e.g. IPsec transport mode.

Fixes: 1e728b01120c ("net/iavf: rework Tx path")

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Reviewed-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/iavf/iavf_rxtx.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/net/iavf/iavf_rxtx.c b/drivers/net/iavf/iavf_rxtx.c
index ba272bb211..b0fed1b992 100644
--- a/drivers/net/iavf/iavf_rxtx.c
+++ b/drivers/net/iavf/iavf_rxtx.c
@@ -2465,8 +2465,7 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
 
 	/* calculate data buffer size less set header lengths */
-	if ((m->ol_flags & RTE_MBUF_F_TX_TUNNEL_MASK) &&
-			(m->ol_flags & (RTE_MBUF_F_TX_TCP_SEG |
-					RTE_MBUF_F_TX_UDP_SEG))) {
-		hdrlen += m->outer_l3_len;
+	if (m->ol_flags & (RTE_MBUF_F_TX_TCP_SEG | RTE_MBUF_F_TX_UDP_SEG)) {
+		if (m->ol_flags & RTE_MBUF_F_TX_TUNNEL_MASK)
+			hdrlen += m->outer_l3_len;
 		if (m->ol_flags & RTE_MBUF_F_TX_L4_MASK)
 			hdrlen += m->l3_len + m->l4_len;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.085602512 +0000
+++ 0062-net-iavf-fix-segmentation-offload-condition.patch	2022-03-01 10:41:01.349244107 +0000
@@ -1 +1 @@
-From ff8b8bcd2ebef5d951bf442c44a71b0b3a0413c9 Mon Sep 17 00:00:00 2001
+From dbb1c537251dea2dba61bdf91cb0e74aa408f920 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ff8b8bcd2ebef5d951bf442c44a71b0b3a0413c9 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 59623ac820..94819e59b2 100644
+index ba272bb211..b0fed1b992 100644
@@ -22 +23 @@
-@@ -2429,8 +2429,7 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
+@@ -2465,8 +2465,7 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,


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

* patch 'net/iavf: fix segmentation offload buffer size' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (60 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/iavf: fix segmentation offload condition' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/i40e: enable maximum frame size at port level' " Kevin Traynor
                   ` (40 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Radu Nicolau; +Cc: Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/15ff989ca85ff5a4b6b9520224c8bd68247e456e

Thanks.

Kevin

---
From 15ff989ca85ff5a4b6b9520224c8bd68247e456e Mon Sep 17 00:00:00 2001
From: Radu Nicolau <radu.nicolau@intel.com>
Date: Tue, 15 Feb 2022 15:50:23 +0000
Subject: [PATCH] net/iavf: fix segmentation offload buffer size

[ upstream commit 6a28563d1f86d8c51d8ec4a5f3d9bbd30514c20e ]

This fix commit ff8b8bcd2ebe, which resulted in incorrect buffer size
being computed for non IPses TSO packets.

Fixes: ff8b8bcd2ebe ("net/iavf: fix segmentation offload condition")

Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/iavf/iavf_rxtx.c | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

diff --git a/drivers/net/iavf/iavf_rxtx.c b/drivers/net/iavf/iavf_rxtx.c
index b0fed1b992..29ab1b84f2 100644
--- a/drivers/net/iavf/iavf_rxtx.c
+++ b/drivers/net/iavf/iavf_rxtx.c
@@ -2465,7 +2465,8 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
 
 	/* calculate data buffer size less set header lengths */
-	if (m->ol_flags & (RTE_MBUF_F_TX_TCP_SEG | RTE_MBUF_F_TX_UDP_SEG)) {
-		if (m->ol_flags & RTE_MBUF_F_TX_TUNNEL_MASK)
-			hdrlen += m->outer_l3_len;
+	if ((m->ol_flags & RTE_MBUF_F_TX_TUNNEL_MASK) &&
+			(m->ol_flags & (RTE_MBUF_F_TX_TCP_SEG |
+					RTE_MBUF_F_TX_UDP_SEG))) {
+		hdrlen += m->outer_l3_len;
 		if (m->ol_flags & RTE_MBUF_F_TX_L4_MASK)
 			hdrlen += m->l3_len + m->l4_len;
@@ -2475,4 +2476,12 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
 			hdrlen += ipseclen;
 		bufsz = hdrlen + tlen;
+	} else if ((m->ol_flags & RTE_MBUF_F_TX_SEC_OFFLOAD) &&
+			(m->ol_flags & (RTE_MBUF_F_TX_TCP_SEG |
+					RTE_MBUF_F_TX_UDP_SEG))) {
+		hdrlen += m->outer_l3_len + m->l3_len + ipseclen;
+		if (m->ol_flags & RTE_MBUF_F_TX_L4_MASK)
+			hdrlen += m->l4_len;
+		bufsz = hdrlen + tlen;
+
 	} else {
 		bufsz = m->data_len;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.114010793 +0000
+++ 0063-net-iavf-fix-segmentation-offload-buffer-size.patch	2022-03-01 10:41:01.351244108 +0000
@@ -1 +1 @@
-From 6a28563d1f86d8c51d8ec4a5f3d9bbd30514c20e Mon Sep 17 00:00:00 2001
+From 15ff989ca85ff5a4b6b9520224c8bd68247e456e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6a28563d1f86d8c51d8ec4a5f3d9bbd30514c20e ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index 41244055e5..ca54c70dd0 100644
+index b0fed1b992..29ab1b84f2 100644
@@ -22 +23 @@
-@@ -2464,7 +2464,8 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
+@@ -2465,7 +2465,8 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
@@ -34 +35 @@
-@@ -2474,4 +2475,12 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,
+@@ -2475,4 +2476,12 @@ iavf_fill_data_desc(volatile struct iavf_tx_desc *desc,


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

* patch 'net/i40e: enable maximum frame size at port level' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (61 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/iavf: fix segmentation offload buffer size' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix sibling device config check' " Kevin Traynor
                   ` (39 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Dapeng Yu; +Cc: Peng Zhang, Qi Zhang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e68285796ca68b34fb0f7a10a391957e825b1a04 Mon Sep 17 00:00:00 2001
From: Dapeng Yu <dapengx.yu@intel.com>
Date: Tue, 7 Dec 2021 16:59:46 +0800
Subject: [PATCH] net/i40e: enable maximum frame size at port level

[ upstream commit a4ba773679231264e4077824358260c6583cc874 ]

Currently max frame size is set at queue level, which makes the values
of the following counters wrong when a jumbo frame is received.

The expected value:
rx_good_bytes: 0
rx_errors: 1
rx_oversize_errors: 1

The actual value:
rx_good_bytes: 1626
rx_errors: 0
rx_oversize_errors: 0

This patch enables setting max frame size at port level, and makes the
values above right.

Signed-off-by: Dapeng Yu <dapengx.yu@intel.com>
Tested-by: Peng Zhang <peng1x.zhang@intel.com>
Reviewed-by: Qi Zhang <qi.z.zhang@intel.com>
---
 drivers/net/i40e/i40e_ethdev.c | 41 ++++++++++++++++++++++++++++------
 1 file changed, 34 insertions(+), 7 deletions(-)

diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c
index 1d417dbf8a..4ac31c2fec 100644
--- a/drivers/net/i40e/i40e_ethdev.c
+++ b/drivers/net/i40e/i40e_ethdev.c
@@ -387,4 +387,5 @@ static int i40e_set_default_mac_addr(struct rte_eth_dev *dev,
 
 static int i40e_dev_mtu_set(struct rte_eth_dev *dev, uint16_t mtu);
+static void i40e_set_mac_max_frame(struct rte_eth_dev *dev, uint16_t size);
 
 static int i40e_ethertype_filter_convert(
@@ -1710,9 +1711,4 @@ eth_i40e_dev_init(struct rte_eth_dev *dev, void *init_params __rte_unused)
 	i40e_add_tx_flow_control_drop_filter(pf);
 
-	/* Set the max frame size to 0x2600 by default,
-	 * in case other drivers changed the default value.
-	 */
-	i40e_aq_set_mac_config(hw, I40E_FRAME_SIZE_MAX, TRUE, false, 0, NULL);
-
 	/* initialize RSS rule list */
 	TAILQ_INIT(&pf->rss_config_list);
@@ -2365,4 +2361,5 @@ i40e_dev_start(struct rte_eth_dev *dev)
 	struct i40e_vsi *vsi;
 	uint16_t nb_rxq, nb_txq;
+	uint16_t max_frame_size;
 
 	hw->adapter_stopped = 0;
@@ -2503,4 +2500,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
 			    "before starting the port");
 
+	max_frame_size = dev->data->mtu + I40E_ETH_OVERHEAD;
+	i40e_set_mac_max_frame(dev, max_frame_size);
+
 	return I40E_SUCCESS;
 
@@ -2849,4 +2849,7 @@ i40e_dev_set_link_down(struct rte_eth_dev *dev)
 }
 
+#define CHECK_INTERVAL             100  /* 100ms */
+#define MAX_REPEAT_TIME            10  /* 1s (10 * 100ms) in total */
+
 static __rte_always_inline void
 update_link_reg(struct i40e_hw *hw, struct rte_eth_link *link)
@@ -2915,6 +2918,4 @@ update_link_aq(struct i40e_hw *hw, struct rte_eth_link *link,
 	bool enable_lse, int wait_to_complete)
 {
-#define CHECK_INTERVAL             100  /* 100ms */
-#define MAX_REPEAT_TIME            10  /* 1s (10 * 100ms) in total */
 	uint32_t rep_cnt = MAX_REPEAT_TIME;
 	struct i40e_link_status link_status;
@@ -6720,4 +6721,5 @@ i40e_dev_handle_aq_msg(struct rte_eth_dev *dev)
 				rte_eth_dev_callback_process(dev,
 					RTE_ETH_EVENT_INTR_LSC, NULL);
+
 			break;
 		default:
@@ -12104,4 +12106,29 @@ i40e_cloud_filter_qinq_create(struct i40e_pf *pf)
 }
 
+static void
+i40e_set_mac_max_frame(struct rte_eth_dev *dev, uint16_t size)
+{
+	struct i40e_hw *hw = I40E_DEV_PRIVATE_TO_HW(dev->data->dev_private);
+	uint32_t rep_cnt = MAX_REPEAT_TIME;
+	struct rte_eth_link link;
+	enum i40e_status_code status;
+
+	do {
+		update_link_reg(hw, &link);
+		if (link.link_status)
+			break;
+
+		rte_delay_ms(CHECK_INTERVAL);
+	} while (--rep_cnt);
+
+	if (link.link_status) {
+		status = i40e_aq_set_mac_config(hw, size, TRUE, 0, false, NULL);
+		if (status != I40E_SUCCESS)
+			PMD_DRV_LOG(ERR, "Failed to set max frame size at port level");
+	} else {
+		PMD_DRV_LOG(ERR, "Set max frame size at port level not applicable on link down");
+	}
+}
+
 RTE_LOG_REGISTER_SUFFIX(i40e_logtype_init, init, NOTICE);
 RTE_LOG_REGISTER_SUFFIX(i40e_logtype_driver, driver, NOTICE);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.142787342 +0000
+++ 0064-net-i40e-enable-maximum-frame-size-at-port-level.patch	2022-03-01 10:41:01.360244109 +0000
@@ -1 +1 @@
-From a4ba773679231264e4077824358260c6583cc874 Mon Sep 17 00:00:00 2001
+From e68285796ca68b34fb0f7a10a391957e825b1a04 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit a4ba773679231264e4077824358260c6583cc874 ]
+
@@ -22,2 +23,0 @@
-Cc: stable@dpdk.org
-
@@ -32 +32 @@
-index ecfa3c94db..755786dc10 100644
+index 1d417dbf8a..4ac31c2fec 100644
@@ -51 +51 @@
-@@ -2356,4 +2352,5 @@ i40e_dev_start(struct rte_eth_dev *dev)
+@@ -2365,4 +2361,5 @@ i40e_dev_start(struct rte_eth_dev *dev)
@@ -57 +57 @@
-@@ -2494,4 +2491,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
+@@ -2503,4 +2500,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
@@ -65 +65 @@
-@@ -2840,4 +2840,7 @@ i40e_dev_set_link_down(struct rte_eth_dev *dev)
+@@ -2849,4 +2849,7 @@ i40e_dev_set_link_down(struct rte_eth_dev *dev)
@@ -73 +73 @@
-@@ -2906,6 +2909,4 @@ update_link_aq(struct i40e_hw *hw, struct rte_eth_link *link,
+@@ -2915,6 +2918,4 @@ update_link_aq(struct i40e_hw *hw, struct rte_eth_link *link,
@@ -80 +80 @@
-@@ -6711,4 +6712,5 @@ i40e_dev_handle_aq_msg(struct rte_eth_dev *dev)
+@@ -6720,4 +6721,5 @@ i40e_dev_handle_aq_msg(struct rte_eth_dev *dev)
@@ -86 +86 @@
-@@ -12095,4 +12097,29 @@ i40e_cloud_filter_qinq_create(struct i40e_pf *pf)
+@@ -12104,4 +12106,29 @@ i40e_cloud_filter_qinq_create(struct i40e_pf *pf)


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

* patch 'net/mlx5: fix sibling device config check' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (62 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/i40e: enable maximum frame size at port level' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix ineffective metadata argument adjustment' " Kevin Traynor
                   ` (38 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/50f3a03f7555ad22852c64d0ee60bd18c4188dd2

Thanks.

Kevin

---
From 50f3a03f7555ad22852c64d0ee60bd18c4188dd2 Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Mon, 14 Feb 2022 11:34:52 +0200
Subject: [PATCH] net/mlx5: fix sibling device config check

[ upstream commit dcbaafdc8f70987c6b610af7d43817b560fb646b ]

The MLX5 net driver supports "probe again". In probing again, it
creates a new ethdev under an existing infiniband device context.

Sibling devices sharing infiniband device context should have compatible
configurations, so some of the devargs given in the probe again, the
ones that are mainly relevant to the sharing device context are sent to
the mlx5_dev_check_sibling_config function which makes sure that they
compatible its siblings.
However, the arguments are adjusted according to the capability of the
device, and the function compares the arguments of the probe again
before the adjustment with the arguments of the siblings after the
adjustment. A user who sends the same values to all siblings may fail in
this comparison if he requested something that the device does not
support and adjusted.

This patch moves the call to the mlx5_dev_check_sibling_config function
after the relevant adjustments.

Fixes: 92d5dd483450 ("net/mlx5: check sibling device configurations mismatch")
Fixes: 2d241515ebaf ("net/mlx5: add devarg for extensive metadata support")

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/linux/mlx5_os.c   | 41 ++++++++++++++++--------------
 drivers/net/mlx5/windows/mlx5_os.c | 28 ++++++++++++--------
 2 files changed, 39 insertions(+), 30 deletions(-)

diff --git a/drivers/net/mlx5/linux/mlx5_os.c b/drivers/net/mlx5/linux/mlx5_os.c
index aecdc5a68a..de0bb87460 100644
--- a/drivers/net/mlx5/linux/mlx5_os.c
+++ b/drivers/net/mlx5/linux/mlx5_os.c
@@ -1242,4 +1242,26 @@ err_secondary:
 	/* Override some values set by hardware configuration. */
 	mlx5_args(config, dpdk_dev->devargs);
+	/* Update final values for devargs before check sibling config. */
+#if !defined(HAVE_IBV_FLOW_DV_SUPPORT) || !defined(HAVE_MLX5DV_DR)
+	if (config->dv_flow_en) {
+		DRV_LOG(WARNING, "DV flow is not supported.");
+		config->dv_flow_en = 0;
+	}
+#endif
+#ifdef HAVE_MLX5DV_DR_ESWITCH
+	if (!(sh->cdev->config.hca_attr.eswitch_manager && config->dv_flow_en &&
+	      (switch_info->representor || switch_info->master)))
+		config->dv_esw_en = 0;
+#else
+	config->dv_esw_en = 0;
+#endif
+	if (!priv->config.dv_esw_en &&
+	    priv->config.dv_xmeta_en != MLX5_XMETA_MODE_LEGACY) {
+		DRV_LOG(WARNING,
+			"Metadata mode %u is not supported (no E-Switch).",
+			priv->config.dv_xmeta_en);
+		priv->config.dv_xmeta_en = MLX5_XMETA_MODE_LEGACY;
+	}
+	/* Check sibling device configurations. */
 	err = mlx5_dev_check_sibling_config(priv, config, dpdk_dev);
 	if (err)
@@ -1252,10 +1274,4 @@ err_secondary:
 	!defined(HAVE_IBV_DEVICE_COUNTERS_SET_V45)
 	DRV_LOG(DEBUG, "counters are not supported");
-#endif
-#if !defined(HAVE_IBV_FLOW_DV_SUPPORT) || !defined(HAVE_MLX5DV_DR)
-	if (config->dv_flow_en) {
-		DRV_LOG(WARNING, "DV flow is not supported");
-		config->dv_flow_en = 0;
-	}
 #endif
 	config->ind_table_max_size =
@@ -1653,11 +1669,4 @@ err_secondary:
 	 */
 	mlx5_link_update(eth_dev, 0);
-#ifdef HAVE_MLX5DV_DR_ESWITCH
-	if (!(config->hca_attr.eswitch_manager && config->dv_flow_en &&
-	      (switch_info->representor || switch_info->master)))
-		config->dv_esw_en = 0;
-#else
-	config->dv_esw_en = 0;
-#endif
 	/* Detect minimal data bytes to inline. */
 	mlx5_set_min_inline(spawn, config);
@@ -1726,10 +1735,4 @@ err_secondary:
 		goto error;
 	}
-	if (!priv->config.dv_esw_en &&
-	    priv->config.dv_xmeta_en != MLX5_XMETA_MODE_LEGACY) {
-		DRV_LOG(WARNING, "metadata mode %u is not supported "
-				 "(no E-Switch)", priv->config.dv_xmeta_en);
-		priv->config.dv_xmeta_en = MLX5_XMETA_MODE_LEGACY;
-	}
 	mlx5_set_metadata_mask(eth_dev);
 	if (priv->config.dv_xmeta_en != MLX5_XMETA_MODE_LEGACY &&
diff --git a/drivers/net/mlx5/windows/mlx5_os.c b/drivers/net/mlx5/windows/mlx5_os.c
index f143724990..d358317996 100644
--- a/drivers/net/mlx5/windows/mlx5_os.c
+++ b/drivers/net/mlx5/windows/mlx5_os.c
@@ -424,4 +424,19 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
 	/* Override some values set by hardware configuration. */
 	mlx5_args(config, dpdk_dev->devargs);
+	/* Update final values for devargs before check sibling config. */
+	config->dv_esw_en = 0;
+	if (!config->dv_flow_en) {
+		DRV_LOG(ERR, "Windows flow mode must be DV flow enable.");
+		err = ENOTSUP;
+		goto error;
+	}
+	if (!priv->config.dv_esw_en &&
+	    priv->config.dv_xmeta_en != MLX5_XMETA_MODE_LEGACY) {
+		DRV_LOG(WARNING,
+			"Metadata mode %u is not supported (no E-Switch).",
+			priv->config.dv_xmeta_en);
+		priv->config.dv_xmeta_en = MLX5_XMETA_MODE_LEGACY;
+	}
+	/* Check sibling device configurations. */
 	err = mlx5_dev_check_sibling_config(priv, config, dpdk_dev);
 	if (err)
@@ -585,5 +600,4 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
 	 */
 	mlx5_link_update(eth_dev, 0);
-	config->dv_esw_en = 0;
 	/* Detect minimal data bytes to inline. */
 	mlx5_set_min_inline(spawn, config);
@@ -607,10 +621,4 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
 	/* No supported flow priority number detection. */
 	priv->sh->flow_max_priority = -1;
-	if (!priv->config.dv_esw_en &&
-	    priv->config.dv_xmeta_en != MLX5_XMETA_MODE_LEGACY) {
-		DRV_LOG(WARNING, "metadata mode %u is not supported "
-				 "(no E-Switch)", priv->config.dv_xmeta_en);
-		priv->config.dv_xmeta_en = MLX5_XMETA_MODE_LEGACY;
-	}
 	mlx5_set_metadata_mask(eth_dev);
 	if (priv->config.dv_xmeta_en != MLX5_XMETA_MODE_LEGACY &&
@@ -646,10 +654,8 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
 		}
 	}
-	if (sh->devx && config->dv_flow_en) {
+	if (sh->devx) {
 		priv->obj_ops = devx_obj_ops;
 	} else {
-		DRV_LOG(ERR, "Flow mode %u is not supported "
-				"(Windows flow must be DevX with DV flow enabled).",
-				priv->config.dv_flow_en);
+		DRV_LOG(ERR, "Windows flow must be DevX.");
 		err = ENOTSUP;
 		goto error;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.178539143 +0000
+++ 0065-net-mlx5-fix-sibling-device-config-check.patch	2022-03-01 10:41:01.363244110 +0000
@@ -1 +1 @@
-From dcbaafdc8f70987c6b610af7d43817b560fb646b Mon Sep 17 00:00:00 2001
+From 50f3a03f7555ad22852c64d0ee60bd18c4188dd2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit dcbaafdc8f70987c6b610af7d43817b560fb646b ]
+
@@ -26 +27,0 @@
-Cc: stable@dpdk.org
@@ -36 +37 @@
-index bbe05bb837..e157795b63 100644
+index aecdc5a68a..de0bb87460 100644
@@ -101 +102 @@
-index 7f3532426f..3db33cd0cf 100644
+index f143724990..d358317996 100644
@@ -104 +105 @@
-@@ -440,4 +440,19 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
+@@ -424,4 +424,19 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
@@ -124 +125 @@
-@@ -601,5 +616,4 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
+@@ -585,5 +600,4 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
@@ -130 +131 @@
-@@ -623,10 +637,4 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
+@@ -607,10 +621,4 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
@@ -141 +142 @@
-@@ -662,10 +670,8 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,
+@@ -646,10 +654,8 @@ mlx5_dev_spawn(struct rte_device *dpdk_dev,


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

* patch 'net/mlx5: fix ineffective metadata argument adjustment' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (63 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix sibling device config check' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix ASO CT object release' " Kevin Traynor
                   ` (37 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/49257a939413b811cd16e693416ce151d42634d3

Thanks.

Kevin

---
From 49257a939413b811cd16e693416ce151d42634d3 Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Mon, 14 Feb 2022 11:34:53 +0200
Subject: [PATCH] net/mlx5: fix ineffective metadata argument adjustment

[ upstream commit ad9d0c6395abf9793f328f571338fbe6a61f5ebe ]

In "dv_xmeta_en" devarg there is an option of dv_xmeta_en=3 which
engages tunnel offload mode. In E-Switch configuration, that mode
implicitly activates dv_xmeta_en=1.

The update according to E-switch support is done immediately after the
first parsing of the devargs, but there is another adjustment later.

This patch moves the adjustment after the second parsing.

Fixes: 4ec6360de37d ("net/mlx5: implement tunnel offload")

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/linux/mlx5_os.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/mlx5/linux/mlx5_os.c b/drivers/net/mlx5/linux/mlx5_os.c
index de0bb87460..e45e56f4b6 100644
--- a/drivers/net/mlx5/linux/mlx5_os.c
+++ b/drivers/net/mlx5/linux/mlx5_os.c
@@ -978,8 +978,4 @@ err_secondary:
 		goto error;
 	}
-	if (config->dv_miss_info) {
-		if (switch_info->master || switch_info->representor)
-			config->dv_xmeta_en = MLX5_XMETA_MODE_META16;
-	}
 	sh = mlx5_alloc_shared_dev_ctx(spawn, config);
 	if (!sh)
@@ -1243,4 +1239,8 @@ err_secondary:
 	mlx5_args(config, dpdk_dev->devargs);
 	/* Update final values for devargs before check sibling config. */
+	if (config->dv_miss_info) {
+		if (switch_info->master || switch_info->representor)
+			config->dv_xmeta_en = MLX5_XMETA_MODE_META16;
+	}
 #if !defined(HAVE_IBV_FLOW_DV_SUPPORT) || !defined(HAVE_MLX5DV_DR)
 	if (config->dv_flow_en) {
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.208015445 +0000
+++ 0066-net-mlx5-fix-ineffective-metadata-argument-adjustmen.patch	2022-03-01 10:41:01.365244110 +0000
@@ -1 +1 @@
-From ad9d0c6395abf9793f328f571338fbe6a61f5ebe Mon Sep 17 00:00:00 2001
+From 49257a939413b811cd16e693416ce151d42634d3 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ad9d0c6395abf9793f328f571338fbe6a61f5ebe ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -25 +26 @@
-index e157795b63..69d3e1e3ad 100644
+index de0bb87460..e45e56f4b6 100644


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

* patch 'net/mlx5: fix ASO CT object release' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (64 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix ineffective metadata argument adjustment' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix errno update in shared context creation' " Kevin Traynor
                   ` (36 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From b6b1c3ad5df57eadada10b0957ff05c89d394e27 Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Mon, 14 Feb 2022 11:34:54 +0200
Subject: [PATCH] net/mlx5: fix ASO CT object release

[ upstream commit ce12974cce72b416135d16a5fa1f4d41cd1d4163 ]

The ASO connection tracking structure is initialized once for sharing
device context.

Its release takes place in the close function which is called for each
ethdev individually. i.e. when there is more than one ethdev under the
same sharing device context, it will be destroyed when one of them is
closed. If the other wants to use it later, it may cause it to crash.

In addition, the creation of this structure is performed in the spawn
function. If one of the creations of the objects following it fails, it
is supposed to be destroyed but this does not happen.

This patch moves its release to the sharing device context free function
and thus solves both problems.

Fixes: 0af8a2298a42 ("net/mlx5: release connection tracking management")
Fixes: ee9e5fad03eb ("net/mlx5: initialize connection tracking management")

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

diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c
index 67eda41a60..d1d398f49a 100644
--- a/drivers/net/mlx5/mlx5.c
+++ b/drivers/net/mlx5/mlx5.c
@@ -1322,4 +1322,6 @@ mlx5_free_shared_dev_ctx(struct mlx5_dev_ctx_shared *sh)
 	 **/
 	mlx5_flow_counters_mng_close(sh);
+	if (sh->ct_mng)
+		mlx5_flow_aso_ct_mng_close(sh);
 	if (sh->aso_age_mng) {
 		mlx5_flow_aso_age_mng_close(sh);
@@ -1595,6 +1597,4 @@ mlx5_dev_close(struct rte_eth_dev *dev)
 		mlx5_hlist_destroy(priv->mreg_cp_tbl);
 	mlx5_mprq_free_mp(dev);
-	if (priv->sh->ct_mng)
-		mlx5_flow_aso_ct_mng_close(priv->sh);
 	mlx5_os_free_shared_dr(priv);
 	if (priv->rss_conf.rss_key != NULL)
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.236599948 +0000
+++ 0067-net-mlx5-fix-ASO-CT-object-release.patch	2022-03-01 10:41:01.367244111 +0000
@@ -1 +1 @@
-From ce12974cce72b416135d16a5fa1f4d41cd1d4163 Mon Sep 17 00:00:00 2001
+From b6b1c3ad5df57eadada10b0957ff05c89d394e27 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ce12974cce72b416135d16a5fa1f4d41cd1d4163 ]
+
@@ -23 +24,0 @@
-Cc: stable@dpdk.org
@@ -32 +33 @@
-index 5571e90677..cde8d022cd 100644
+index 67eda41a60..d1d398f49a 100644


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

* patch 'net/mlx5: fix errno update in shared context creation' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (65 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix ASO CT object release' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'app/testpmd: fix GENEVE parsing in checksum mode' " Kevin Traynor
                   ` (35 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/036993974f3a885c6ace0b9edd736cd21734b814

Thanks.

Kevin

---
From 036993974f3a885c6ace0b9edd736cd21734b814 Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Mon, 14 Feb 2022 11:34:55 +0200
Subject: [PATCH] net/mlx5: fix errno update in shared context creation

[ upstream commit 6be4c57add872cfd5f430977a1be2701a951ef90 ]

The mlx5_alloc_shared_dev_ctx() function has a local variable named
"err" which contains the errno value in case of failure.

When functions called by this function are failed, this variable is
updated with their return value (that should be a positive errno value).
However, some functions doesn't update errno value by themselves or
return negative errno value. If one of them fails, the "err" variable
contains negative value what cause to assertion failure.

This patch updates all functions uses by mlx5_alloc_shared_dev_ctx()
function to update rte_errno and take this value instead of "err" value.

Fixes: 5dfa003db53f ("common/mlx5: fix post doorbell barrier")
Fixes: 5d55a494f4e6 ("net/mlx5: split multi-thread flow handling per OS")

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/net/mlx5/linux/mlx5_flow_os.c   |  3 ++-
 drivers/net/mlx5/linux/mlx5_os.c        | 16 ++++++++++------
 drivers/net/mlx5/mlx5.c                 | 24 +++++++++++-------------
 drivers/net/mlx5/windows/mlx5_flow_os.c |  2 +-
 drivers/net/mlx5/windows/mlx5_os.c      | 24 ++++++++++++------------
 5 files changed, 36 insertions(+), 33 deletions(-)

diff --git a/drivers/net/mlx5/linux/mlx5_flow_os.c b/drivers/net/mlx5/linux/mlx5_flow_os.c
index 893f00b824..a5956c255a 100644
--- a/drivers/net/mlx5/linux/mlx5_flow_os.c
+++ b/drivers/net/mlx5/linux/mlx5_flow_os.c
@@ -15,5 +15,6 @@ mlx5_flow_os_init_workspace_once(void)
 	if (rte_thread_key_create(&key_workspace, flow_release_workspace)) {
 		DRV_LOG(ERR, "Can't create flow workspace data thread key.");
-		return -ENOMEM;
+		rte_errno = ENOMEM;
+		return -rte_errno;
 	}
 	return 0;
diff --git a/drivers/net/mlx5/linux/mlx5_os.c b/drivers/net/mlx5/linux/mlx5_os.c
index e45e56f4b6..f587a47f6e 100644
--- a/drivers/net/mlx5/linux/mlx5_os.c
+++ b/drivers/net/mlx5/linux/mlx5_os.c
@@ -139,5 +139,5 @@ mlx5_os_set_nonblock_channel_fd(int fd)
  *
  * @return
- *   0 on success, non zero error number otherwise
+ *   0 on success, a negative errno value otherwise and rte_errno is set.
  */
 int
@@ -151,6 +151,8 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
 	memset(device_attr, 0, sizeof(*device_attr));
 	err = mlx5_glue->query_device_ex(ctx, NULL, &attr_ex);
-	if (err)
-		return err;
+	if (err) {
+		rte_errno = errno;
+		return -rte_errno;
+	}
 	device_attr->device_cap_flags_ex = attr_ex.device_cap_flags_ex;
 	device_attr->max_qp_wr = attr_ex.orig_attr.max_qp_wr;
@@ -171,6 +173,8 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
 	struct mlx5dv_context dv_attr = { .comp_mask = 0 };
 	err = mlx5_glue->dv_query_device(ctx, &dv_attr);
-	if (err)
-		return err;
+	if (err) {
+		rte_errno = errno;
+		return -rte_errno;
+	}
 
 	device_attr->flags = dv_attr.flags;
@@ -196,5 +200,5 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
 		sizeof(device_attr->fw_ver));
 
-	return err;
+	return 0;
 }
 
diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c
index d1d398f49a..25d4d2082b 100644
--- a/drivers/net/mlx5/mlx5.c
+++ b/drivers/net/mlx5/mlx5.c
@@ -1173,10 +1173,9 @@ mlx5_alloc_shared_dev_ctx(const struct mlx5_dev_spawn_data *spawn,
 	sh = mlx5_malloc(MLX5_MEM_ZERO | MLX5_MEM_RTE,
 			 sizeof(struct mlx5_dev_ctx_shared) +
-			 spawn->max_port *
-			 sizeof(struct mlx5_dev_shared_port),
+			 spawn->max_port * sizeof(struct mlx5_dev_shared_port),
 			 RTE_CACHE_LINE_SIZE, SOCKET_ID_ANY);
 	if (!sh) {
-		DRV_LOG(ERR, "shared context allocation failure");
-		rte_errno  = ENOMEM;
+		DRV_LOG(ERR, "Shared context allocation failure.");
+		rte_errno = ENOMEM;
 		goto exit;
 	}
@@ -1200,7 +1199,6 @@ mlx5_alloc_shared_dev_ctx(const struct mlx5_dev_spawn_data *spawn,
 		sizeof(sh->ibdev_path) - 1);
 	/*
-	 * Setting port_id to max unallowed value means
-	 * there is no interrupt subhandler installed for
-	 * the given port index i.
+	 * Setting port_id to max unallowed value means there is no interrupt
+	 * subhandler installed for the given port index i.
 	 */
 	for (i = 0; i < sh->max_port; i++) {
@@ -1212,10 +1210,10 @@ mlx5_alloc_shared_dev_ctx(const struct mlx5_dev_spawn_data *spawn,
 		if (!sh->td) {
 			DRV_LOG(ERR, "TD allocation failure");
-			err = ENOMEM;
+			rte_errno = ENOMEM;
 			goto error;
 		}
 		if (mlx5_setup_tis(sh)) {
 			DRV_LOG(ERR, "TIS allocation failure");
-			err = ENOMEM;
+			rte_errno = ENOMEM;
 			goto error;
 		}
@@ -1247,9 +1245,9 @@ exit:
 	return sh;
 error:
+	err = rte_errno;
 	pthread_mutex_destroy(&sh->txpp.mutex);
 	pthread_mutex_unlock(&mlx5_dev_ctx_list_mutex);
 	MLX5_ASSERT(sh);
-	if (sh->td)
-		claim_zero(mlx5_devx_cmd_destroy(sh->td));
+	mlx5_rxtx_uars_release(sh);
 	i = 0;
 	do {
@@ -1257,7 +1255,7 @@ error:
 			claim_zero(mlx5_devx_cmd_destroy(sh->tis[i]));
 	} while (++i < (uint32_t)sh->bond.n_port);
-	mlx5_rxtx_uars_release(sh);
+	if (sh->td)
+		claim_zero(mlx5_devx_cmd_destroy(sh->td));
 	mlx5_free(sh);
-	MLX5_ASSERT(err > 0);
 	rte_errno = err;
 	return NULL;
diff --git a/drivers/net/mlx5/windows/mlx5_flow_os.c b/drivers/net/mlx5/windows/mlx5_flow_os.c
index 7bb4c4590a..f5e3893ed4 100644
--- a/drivers/net/mlx5/windows/mlx5_flow_os.c
+++ b/drivers/net/mlx5/windows/mlx5_flow_os.c
@@ -373,5 +373,5 @@ mlx5_flow_os_init_workspace_once(void)
 	if (err) {
 		DRV_LOG(ERR, "Can't create flow workspace data thread key.");
-		return err;
+		return -rte_errno;
 	}
 	pthread_mutex_init(&lock_thread_list, NULL);
diff --git a/drivers/net/mlx5/windows/mlx5_os.c b/drivers/net/mlx5/windows/mlx5_os.c
index d358317996..ba99901c5c 100644
--- a/drivers/net/mlx5/windows/mlx5_os.c
+++ b/drivers/net/mlx5/windows/mlx5_os.c
@@ -137,5 +137,5 @@ mlx5_init_once(void)
  *
  * @return
- *   0 on success, non zero error number otherwise.
+ *   0 on success, a negative errno value otherwise and rte_errno is set.
  */
 int
@@ -146,8 +146,9 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
 	void *pv_iseg = NULL;
 	u32 cb_iseg = 0;
-	int err = 0;
 
-	if (!cdev || !cdev->ctx)
-		return -EINVAL;
+	if (!cdev || !cdev->ctx) {
+		rte_errno = EINVAL;
+		return -rte_errno;
+	}
 	mlx5_ctx = (struct mlx5_context *)cdev->ctx;
 	memset(device_attr, 0, sizeof(*device_attr));
@@ -172,13 +173,12 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
 	if (pv_iseg == NULL) {
 		DRV_LOG(ERR, "Failed to get device hca_iseg");
-		return errno;
+		rte_errno = errno;
+		return -rte_errno;
 	}
-	if (!err) {
-		snprintf(device_attr->fw_ver, 64, "%x.%x.%04x",
-			MLX5_GET(initial_seg, pv_iseg, fw_rev_major),
-			MLX5_GET(initial_seg, pv_iseg, fw_rev_minor),
-			MLX5_GET(initial_seg, pv_iseg, fw_rev_subminor));
-	}
-	return err;
+	snprintf(device_attr->fw_ver, 64, "%x.%x.%04x",
+		 MLX5_GET(initial_seg, pv_iseg, fw_rev_major),
+		 MLX5_GET(initial_seg, pv_iseg, fw_rev_minor),
+		 MLX5_GET(initial_seg, pv_iseg, fw_rev_subminor));
+	return 0;
 }
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.264488760 +0000
+++ 0068-net-mlx5-fix-errno-update-in-shared-context-creation.patch	2022-03-01 10:41:01.372244112 +0000
@@ -1 +1 @@
-From 6be4c57add872cfd5f430977a1be2701a951ef90 Mon Sep 17 00:00:00 2001
+From 036993974f3a885c6ace0b9edd736cd21734b814 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6be4c57add872cfd5f430977a1be2701a951ef90 ]
+
@@ -20 +21,0 @@
-Cc: stable@dpdk.org
@@ -45 +46 @@
-index 69d3e1e3ad..faab310b11 100644
+index e45e56f4b6..f587a47f6e 100644
@@ -85 +86 @@
-index cde8d022cd..0e154b88ed 100644
+index d1d398f49a..25d4d2082b 100644
@@ -159 +160 @@
-index 3db33cd0cf..a9619e5bda 100644
+index d358317996..ba99901c5c 100644
@@ -162 +163 @@
-@@ -153,5 +153,5 @@ mlx5_init_once(void)
+@@ -137,5 +137,5 @@ mlx5_init_once(void)
@@ -169 +170 @@
-@@ -162,8 +162,9 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
+@@ -146,8 +146,9 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
@@ -182 +183 @@
-@@ -188,13 +189,12 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,
+@@ -172,13 +173,12 @@ mlx5_os_get_dev_attr(struct mlx5_common_device *cdev,


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

* patch 'app/testpmd: fix GENEVE parsing in checksum mode' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (66 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix errno update in shared context creation' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ngbe: fix debug logs' " Kevin Traynor
                   ` (34 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Raja Zidane; +Cc: Aman Singh, Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From c1cf1a97351afb85863187a7439dda4dc5938a65 Mon Sep 17 00:00:00 2001
From: Raja Zidane <rzidane@nvidia.com>
Date: Mon, 21 Feb 2022 15:24:23 +0200
Subject: [PATCH] app/testpmd: fix GENEVE parsing in checksum mode

[ upstream commit 993677affe391be8bb390c2625bc3d8bb857f0a5 ]

The csum FWD mode parses any received packet to set mbuf offloads for
the transmitting burst, mainly in the checksum/TSO areas.
In the case of a tunnel header, the csum FWD tries to detect known
tunnels by the standard definition using the header's data and fallback
to check the packet type in the mbuf to see if the Rx port driver
already sign the packet as a tunnel.
In the fallback case, the csum assumes the tunnel is VXLAN and parses
the tunnel as VXLAN.
When the GENEVE tunnel was added to the known tunnels in csum, its
parsing trial was wrongly located after the pkt type detection, causing
the csum to parse the GENEVE header as VXLAN when the Rx port set the
tunnel packet type.

Remove the fall back case to VXLAN.
Log error of unrecognized tunnel if no tunnel was parsed successfully.

Fixes: c10a026c3b03 ("app/testpmd: introduce vxlan parsing function in csum fwd engine")

Signed-off-by: Raja Zidane <rzidane@nvidia.com>
Acked-by: Aman Singh <aman.deep.singh@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 app/test-pmd/csumonly.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c
index 0177284d9c..fb559e4ac2 100644
--- a/app/test-pmd/csumonly.c
+++ b/app/test-pmd/csumonly.c
@@ -258,6 +258,5 @@ parse_gtp(struct rte_udp_hdr *udp_hdr,
 static void
 parse_vxlan(struct rte_udp_hdr *udp_hdr,
-	    struct testpmd_offload_info *info,
-	    uint32_t pkt_type)
+	    struct testpmd_offload_info *info)
 {
 	struct rte_ether_hdr *eth_hdr;
@@ -267,6 +266,5 @@ parse_vxlan(struct rte_udp_hdr *udp_hdr,
 	 * (i40e only currently)
 	 */
-	if (udp_hdr->dst_port != _htons(RTE_VXLAN_DEFAULT_PORT) &&
-		RTE_ETH_IS_TUNNEL_PKT(pkt_type) == 0)
+	if (udp_hdr->dst_port != _htons(RTE_VXLAN_DEFAULT_PORT))
 		return;
 
@@ -913,6 +911,5 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)
 					goto tunnel_update;
 				}
-				parse_vxlan(udp_hdr, &info,
-					    m->packet_type);
+				parse_vxlan(udp_hdr, &info);
 				if (info.is_tunnel) {
 					tx_ol_flags |=
@@ -926,4 +923,10 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)
 					goto tunnel_update;
 				}
+				/* Always keep last. */
+				if (unlikely(RTE_ETH_IS_TUNNEL_PKT(
+							m->packet_type) != 0)) {
+					TESTPMD_LOG(DEBUG, "Unknown tunnel packet. UDP dst port: %hu",
+						udp_hdr->dst_port);
+				}
 			} else if (info.l4_proto == IPPROTO_GRE) {
 				struct simple_gre_hdr *gre_hdr;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.296998993 +0000
+++ 0069-app-testpmd-fix-GENEVE-parsing-in-checksum-mode.patch	2022-03-01 10:41:01.373244112 +0000
@@ -1 +1 @@
-From 993677affe391be8bb390c2625bc3d8bb857f0a5 Mon Sep 17 00:00:00 2001
+From c1cf1a97351afb85863187a7439dda4dc5938a65 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 993677affe391be8bb390c2625bc3d8bb857f0a5 ]
+
@@ -23 +24,0 @@
-Cc: stable@dpdk.org
@@ -33 +34 @@
-index 02bc3929c7..5274d498ee 100644
+index 0177284d9c..fb559e4ac2 100644
@@ -36 +37 @@
-@@ -259,6 +259,5 @@ parse_gtp(struct rte_udp_hdr *udp_hdr,
+@@ -258,6 +258,5 @@ parse_gtp(struct rte_udp_hdr *udp_hdr,
@@ -44 +45 @@
-@@ -268,6 +267,5 @@ parse_vxlan(struct rte_udp_hdr *udp_hdr,
+@@ -267,6 +266,5 @@ parse_vxlan(struct rte_udp_hdr *udp_hdr,
@@ -52 +53 @@
-@@ -923,6 +921,5 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)
+@@ -913,6 +911,5 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)
@@ -60 +61 @@
-@@ -936,4 +933,10 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)
+@@ -926,4 +923,10 @@ pkt_burst_checksum_forward(struct fwd_stream *fs)


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

* patch 'net/ngbe: fix debug logs' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (67 preceding siblings ...)
  2022-03-01 10:42 ` patch 'app/testpmd: fix GENEVE parsing in checksum mode' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/txgbe: " Kevin Traynor
                   ` (33 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Jiawen Wu; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From a8be311dd15259201f229522e67fff9a1d49bdf7 Mon Sep 17 00:00:00 2001
From: Jiawen Wu <jiawenwu@trustnetic.com>
Date: Wed, 23 Feb 2022 18:28:56 +0800
Subject: [PATCH] net/ngbe: fix debug logs

[ upstream commit c811e6a492affd55a1c02b13e93591214be2dd1f ]

Remove 'DEBUGFUNC' due to too many invalid debug log prints, unify the
DEBUG level macros.

Fixes: cc934df178ab ("net/ngbe: add log and error types")

Signed-off-by: Jiawen Wu <jiawenwu@trustnetic.com>
---
 drivers/net/ngbe/base/ngbe_eeprom.c  |  22 +---
 drivers/net/ngbe/base/ngbe_hw.c      | 150 +++++++--------------------
 drivers/net/ngbe/base/ngbe_mbx.c     |  22 ----
 drivers/net/ngbe/base/ngbe_mng.c     |  14 +--
 drivers/net/ngbe/base/ngbe_phy.c     |  30 ++----
 drivers/net/ngbe/base/ngbe_phy_mvl.c |  13 +--
 drivers/net/ngbe/base/ngbe_phy_rtl.c |  10 +-
 drivers/net/ngbe/base/ngbe_phy_yt.c  |  16 +--
 drivers/net/ngbe/ngbe_logs.h         |   7 +-
 9 files changed, 57 insertions(+), 227 deletions(-)

diff --git a/drivers/net/ngbe/base/ngbe_eeprom.c b/drivers/net/ngbe/base/ngbe_eeprom.c
index f9a876e9bd..6375ee9b29 100644
--- a/drivers/net/ngbe/base/ngbe_eeprom.c
+++ b/drivers/net/ngbe/base/ngbe_eeprom.c
@@ -21,6 +21,4 @@ s32 ngbe_init_eeprom_params(struct ngbe_hw *hw)
 	u16 eeprom_size;
 
-	DEBUGFUNC("ngbe_init_eeprom_params");
-
 	if (eeprom->type != ngbe_eeprom_unknown)
 		return 0;
@@ -53,6 +51,6 @@ s32 ngbe_init_eeprom_params(struct ngbe_hw *hw)
 	eeprom->sw_addr = 0x80;
 
-	DEBUGOUT("eeprom params: type = %d, size = %d, address bits: "
-		  "%d %d\n", eeprom->type, eeprom->word_size,
+	DEBUGOUT("eeprom params: type = %d, size = %d, address bits: %d %d",
+		  eeprom->type, eeprom->word_size,
 		  eeprom->address_bits, eeprom->sw_addr);
 
@@ -73,7 +71,4 @@ s32 ngbe_get_eeprom_semaphore(struct ngbe_hw *hw)
 	u32 swsm;
 
-	DEBUGFUNC("ngbe_get_eeprom_semaphore");
-
-
 	/* Get SMBI software semaphore between device drivers first */
 	for (i = 0; i < timeout; i++) {
@@ -91,6 +86,5 @@ s32 ngbe_get_eeprom_semaphore(struct ngbe_hw *hw)
 
 	if (i == timeout) {
-		DEBUGOUT("Driver can't access the eeprom - SMBI Semaphore "
-			 "not granted.\n");
+		DEBUGOUT("Driver can't access the eeprom - SMBI Semaphore not granted.");
 		/*
 		 * this release is particularly important because our attempts
@@ -135,11 +129,10 @@ s32 ngbe_get_eeprom_semaphore(struct ngbe_hw *hw)
 		 */
 		if (i >= timeout) {
-			DEBUGOUT("SWESMBI Software EEPROM semaphore not granted.\n");
+			DEBUGOUT("SWESMBI Software EEPROM semaphore not granted.");
 			ngbe_release_eeprom_semaphore(hw);
 			status = NGBE_ERR_EEPROM;
 		}
 	} else {
-		DEBUGOUT("Software semaphore SMBI between device drivers "
-			 "not granted.\n");
+		DEBUGOUT("Software semaphore SMBI between device drivers not granted.");
 	}
 
@@ -155,6 +148,4 @@ s32 ngbe_get_eeprom_semaphore(struct ngbe_hw *hw)
 void ngbe_release_eeprom_semaphore(struct ngbe_hw *hw)
 {
-	DEBUGFUNC("ngbe_release_eeprom_semaphore");
-
 	wr32m(hw, NGBE_MNGSWSYNC, NGBE_MNGSWSYNC_REQ, 0);
 	wr32m(hw, NGBE_SWSEM, NGBE_SWSEM_PF, 0);
@@ -277,5 +268,4 @@ s32 ngbe_validate_eeprom_checksum_em(struct ngbe_hw *hw,
 	int err = 0;
 
-	DEBUGFUNC("ngbe_validate_eeprom_checksum_em");
 	UNREFERENCED_PARAMETER(checksum_val);
 
@@ -316,6 +306,4 @@ s32 ngbe_save_eeprom_version(struct ngbe_hw *hw)
 	u32 offset = (hw->rom.sw_addr + NGBE_EEPROM_VERSION_L) << 1;
 
-	DEBUGFUNC("ngbe_save_eeprom_version");
-
 	if (hw->bus.lan_id == 0) {
 		hw->rom.read32(hw, offset, &eeprom_verl);
diff --git a/drivers/net/ngbe/base/ngbe_hw.c b/drivers/net/ngbe/base/ngbe_hw.c
index 782fd71d29..c462fec9f9 100644
--- a/drivers/net/ngbe/base/ngbe_hw.c
+++ b/drivers/net/ngbe/base/ngbe_hw.c
@@ -21,6 +21,4 @@ s32 ngbe_start_hw(struct ngbe_hw *hw)
 	s32 err;
 
-	DEBUGFUNC("ngbe_start_hw");
-
 	/* Clear the VLAN filter table */
 	hw->mac.clear_vfta(hw);
@@ -32,5 +30,5 @@ s32 ngbe_start_hw(struct ngbe_hw *hw)
 	err = hw->mac.setup_fc(hw);
 	if (err != 0 && err != NGBE_NOT_IMPLEMENTED) {
-		DEBUGOUT("Flow control setup failed, returning %d\n", err);
+		DEBUGOUT("Flow control setup failed, returning %d", err);
 		return err;
 	}
@@ -56,6 +54,4 @@ s32 ngbe_init_hw(struct ngbe_hw *hw)
 	s32 status;
 
-	DEBUGFUNC("ngbe_init_hw");
-
 	ngbe_save_eeprom_version(hw);
 
@@ -68,5 +64,5 @@ s32 ngbe_init_hw(struct ngbe_hw *hw)
 
 	if (status != 0)
-		DEBUGOUT("Failed to initialize HW, STATUS = %d\n", status);
+		DEBUGOUT("Failed to initialize HW, STATUS = %d", status);
 
 	return status;
@@ -157,6 +153,4 @@ s32 ngbe_reset_hw_em(struct ngbe_hw *hw)
 	s32 status;
 
-	DEBUGFUNC("ngbe_reset_hw_em");
-
 	/* Call adapter stop to disable tx/rx and clear interrupts */
 	status = hw->mac.stop_hw(hw);
@@ -206,6 +200,4 @@ s32 ngbe_clear_hw_cntrs(struct ngbe_hw *hw)
 	u16 i = 0;
 
-	DEBUGFUNC("ngbe_clear_hw_cntrs");
-
 	/* QP Stats */
 	/* don't write clear queue stats */
@@ -306,6 +298,4 @@ s32 ngbe_get_mac_addr(struct ngbe_hw *hw, u8 *mac_addr)
 	u16 i;
 
-	DEBUGFUNC("ngbe_get_mac_addr");
-
 	wr32(hw, NGBE_ETHADDRIDX, 0);
 	rar_high = rd32(hw, NGBE_ETHADDRH);
@@ -333,6 +323,4 @@ void ngbe_set_lan_id_multi_port(struct ngbe_hw *hw)
 	u32 reg = 0;
 
-	DEBUGFUNC("ngbe_set_lan_id_multi_port");
-
 	reg = rd32(hw, NGBE_PORTSTAT);
 	bus->lan_id = NGBE_PORTSTAT_ID(reg);
@@ -354,6 +342,4 @@ s32 ngbe_stop_hw(struct ngbe_hw *hw)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_stop_hw");
-
 	/*
 	 * Set the adapter_stopped flag so other driver functions stop touching
@@ -411,6 +397,4 @@ s32 ngbe_led_on(struct ngbe_hw *hw, u32 index)
 	u32 led_reg = rd32(hw, NGBE_LEDCTL);
 
-	DEBUGFUNC("ngbe_led_on");
-
 	if (index > 3)
 		return NGBE_ERR_PARAM;
@@ -433,6 +417,4 @@ s32 ngbe_led_off(struct ngbe_hw *hw, u32 index)
 	u32 led_reg = rd32(hw, NGBE_LEDCTL);
 
-	DEBUGFUNC("ngbe_led_off");
-
 	if (index > 3)
 		return NGBE_ERR_PARAM;
@@ -456,6 +438,4 @@ s32 ngbe_validate_mac_addr(u8 *mac_addr)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_validate_mac_addr");
-
 	/* Make sure it is not a multicast address */
 	if (NGBE_IS_MULTICAST((struct rte_ether_addr *)mac_addr)) {
@@ -488,9 +468,7 @@ s32 ngbe_set_rar(struct ngbe_hw *hw, u32 index, u8 *addr, u32 vmdq,
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("ngbe_set_rar");
-
 	/* Make sure we are using a valid rar index range */
 	if (index >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", index);
+		DEBUGOUT("RAR index %d is out of range.", index);
 		return NGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -540,9 +518,7 @@ s32 ngbe_clear_rar(struct ngbe_hw *hw, u32 index)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("ngbe_clear_rar");
-
 	/* Make sure we are using a valid rar index range */
 	if (index >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", index);
+		DEBUGOUT("RAR index %d is out of range.", index);
 		return NGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -580,6 +556,4 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("ngbe_init_rx_addrs");
-
 	/*
 	 * If the current mac address is valid, assume it is a software override
@@ -592,16 +566,16 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
 		hw->mac.get_mac_addr(hw, hw->mac.addr);
 
-		DEBUGOUT(" Keeping Current RAR0 Addr =%.2X %.2X %.2X ",
+		DEBUGOUT(" Keeping Current RAR0 Addr = "
+			  RTE_ETHER_ADDR_PRT_FMT,
 			  hw->mac.addr[0], hw->mac.addr[1],
-			  hw->mac.addr[2]);
-		DEBUGOUT("%.2X %.2X %.2X\n", hw->mac.addr[3],
+			  hw->mac.addr[2], hw->mac.addr[3],
 			  hw->mac.addr[4], hw->mac.addr[5]);
 	} else {
 		/* Setup the receive address. */
-		DEBUGOUT("Overriding MAC Address in RAR[0]\n");
-		DEBUGOUT(" New MAC Addr =%.2X %.2X %.2X ",
+		DEBUGOUT("Overriding MAC Address in RAR[0]");
+		DEBUGOUT(" New MAC Addr = "
+			  RTE_ETHER_ADDR_PRT_FMT,
 			  hw->mac.addr[0], hw->mac.addr[1],
-			  hw->mac.addr[2]);
-		DEBUGOUT("%.2X %.2X %.2X\n", hw->mac.addr[3],
+			  hw->mac.addr[2], hw->mac.addr[3],
 			  hw->mac.addr[4], hw->mac.addr[5]);
 
@@ -613,5 +587,5 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
 
 	/* Zero out the other receive addresses. */
-	DEBUGOUT("Clearing RAR[1-%d]\n", rar_entries - 1);
+	DEBUGOUT("Clearing RAR[1-%d]", rar_entries - 1);
 	for (i = 1; i < rar_entries; i++) {
 		wr32(hw, NGBE_ETHADDRIDX, i);
@@ -627,5 +601,5 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
 	wr32(hw, NGBE_PSRCTL, psrctl);
 
-	DEBUGOUT(" Clearing MTA\n");
+	DEBUGOUT(" Clearing MTA");
 	for (i = 0; i < hw->mac.mcft_size; i++)
 		wr32(hw, NGBE_MCADDRTBL(i), 0);
@@ -652,6 +626,4 @@ static s32 ngbe_mta_vector(struct ngbe_hw *hw, u8 *mc_addr)
 	u32 vector = 0;
 
-	DEBUGFUNC("ngbe_mta_vector");
-
 	switch (hw->mac.mc_filter_type) {
 	case 0:   /* use bits [47:36] of the address */
@@ -668,5 +640,5 @@ static s32 ngbe_mta_vector(struct ngbe_hw *hw, u8 *mc_addr)
 		break;
 	default:  /* Invalid mc_filter_type */
-		DEBUGOUT("MC filter type param set incorrectly\n");
+		DEBUGOUT("MC filter type param set incorrectly");
 		ASSERT(0);
 		break;
@@ -691,10 +663,8 @@ void ngbe_set_mta(struct ngbe_hw *hw, u8 *mc_addr)
 	u32 vector_reg;
 
-	DEBUGFUNC("ngbe_set_mta");
-
 	hw->addr_ctrl.mta_in_use++;
 
 	vector = ngbe_mta_vector(hw, mc_addr);
-	DEBUGOUT(" bit-vector = 0x%03X\n", vector);
+	DEBUGOUT(" bit-vector = 0x%03X", vector);
 
 	/*
@@ -730,6 +700,4 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
 	u32 vmdq;
 
-	DEBUGFUNC("ngbe_update_mc_addr_list");
-
 	/*
 	 * Set the new number of MC addresses that we are being requested to
@@ -741,5 +709,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
 	/* Clear mta_shadow */
 	if (clear) {
-		DEBUGOUT(" Clearing MTA\n");
+		DEBUGOUT(" Clearing MTA");
 		memset(&hw->mac.mta_shadow, 0, sizeof(hw->mac.mta_shadow));
 	}
@@ -747,5 +715,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
 	/* Update mta_shadow */
 	for (i = 0; i < mc_addr_count; i++) {
-		DEBUGOUT(" Adding the multicast addresses:\n");
+		DEBUGOUT(" Adding the multicast addresses:");
 		ngbe_set_mta(hw, next(hw, &mc_addr_list, &vmdq));
 	}
@@ -764,5 +732,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
 	}
 
-	DEBUGOUT("ngbe update mc addr list complete\n");
+	DEBUGOUT("ngbe update mc addr list complete");
 	return 0;
 }
@@ -779,9 +747,7 @@ s32 ngbe_setup_fc_em(struct ngbe_hw *hw)
 	u16 reg_cu = 0;
 
-	DEBUGFUNC("ngbe_setup_fc");
-
 	/* Validate the requested mode */
 	if (hw->fc.strict_ieee && hw->fc.requested_mode == ngbe_fc_rx_pause) {
-		DEBUGOUT("ngbe_fc_rx_pause not valid in strict IEEE mode\n");
+		DEBUGOUT("ngbe_fc_rx_pause not valid in strict IEEE mode");
 		err = NGBE_ERR_INVALID_LINK_SETTINGS;
 		goto out;
@@ -839,5 +805,5 @@ s32 ngbe_setup_fc_em(struct ngbe_hw *hw)
 		break;
 	default:
-		DEBUGOUT("Flow control param set incorrectly\n");
+		DEBUGOUT("Flow control param set incorrectly");
 		err = NGBE_ERR_CONFIG;
 		goto out;
@@ -863,6 +829,4 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
 	u32 fcrtl, fcrth;
 
-	DEBUGFUNC("ngbe_fc_enable");
-
 	/* Validate the water mark configuration */
 	if (!hw->fc.pause_time) {
@@ -875,5 +839,5 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
 		if (!hw->fc.low_water ||
 			hw->fc.low_water >= hw->fc.high_water) {
-			DEBUGOUT("Invalid water mark configuration\n");
+			DEBUGOUT("Invalid water mark configuration");
 			err = NGBE_ERR_INVALID_LINK_SETTINGS;
 			goto out;
@@ -931,5 +895,5 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
 		break;
 	default:
-		DEBUGOUT("Flow control param set incorrectly\n");
+		DEBUGOUT("Flow control param set incorrectly");
 		err = NGBE_ERR_CONFIG;
 		goto out;
@@ -989,6 +953,5 @@ s32 ngbe_negotiate_fc(struct ngbe_hw *hw, u32 adv_reg, u32 lp_reg,
 {
 	if ((!(adv_reg)) ||  (!(lp_reg))) {
-		DEBUGOUT("Local or link partner's advertised flow control "
-			 "settings are NULL. Local: %x, link partner: %x\n",
+		DEBUGOUT("Local or link partner's advertised flow control settings are NULL. Local: %x, link partner: %x",
 			      adv_reg, lp_reg);
 		return NGBE_ERR_FC_NOT_NEGOTIATED;
@@ -1005,20 +968,20 @@ s32 ngbe_negotiate_fc(struct ngbe_hw *hw, u32 adv_reg, u32 lp_reg,
 		if (hw->fc.requested_mode == ngbe_fc_full) {
 			hw->fc.current_mode = ngbe_fc_full;
-			DEBUGOUT("Flow Control = FULL.\n");
+			DEBUGOUT("Flow Control = FULL.");
 		} else {
 			hw->fc.current_mode = ngbe_fc_rx_pause;
-			DEBUGOUT("Flow Control=RX PAUSE frames only\n");
+			DEBUGOUT("Flow Control=RX PAUSE frames only");
 		}
 	} else if (!(adv_reg & adv_sym) && (adv_reg & adv_asm) &&
 		   (lp_reg & lp_sym) && (lp_reg & lp_asm)) {
 		hw->fc.current_mode = ngbe_fc_tx_pause;
-		DEBUGOUT("Flow Control = TX PAUSE frames only.\n");
+		DEBUGOUT("Flow Control = TX PAUSE frames only.");
 	} else if ((adv_reg & adv_sym) && (adv_reg & adv_asm) &&
 		   !(lp_reg & lp_sym) && (lp_reg & lp_asm)) {
 		hw->fc.current_mode = ngbe_fc_rx_pause;
-		DEBUGOUT("Flow Control = RX PAUSE frames only.\n");
+		DEBUGOUT("Flow Control = RX PAUSE frames only.");
 	} else {
 		hw->fc.current_mode = ngbe_fc_none;
-		DEBUGOUT("Flow Control = NONE.\n");
+		DEBUGOUT("Flow Control = NONE.");
 	}
 	return 0;
@@ -1058,6 +1021,4 @@ void ngbe_fc_autoneg(struct ngbe_hw *hw)
 	bool link_up;
 
-	DEBUGFUNC("ngbe_fc_autoneg");
-
 	/*
 	 * AN should have completed when the cable was plugged in.
@@ -1103,6 +1064,4 @@ s32 ngbe_set_pcie_master(struct ngbe_hw *hw, bool enable)
 	u32 data, i;
 
-	DEBUGFUNC("ngbe_set_pcie_master");
-
 	ngbe_hic_pcie_read(hw, addr, &data, 4);
 	if (enable)
@@ -1128,5 +1087,5 @@ s32 ngbe_set_pcie_master(struct ngbe_hw *hw, bool enable)
 	}
 
-	DEBUGOUT("PCIe transaction pending bit also did not clear.\n");
+	DEBUGOUT("PCIe transaction pending bit also did not clear.");
 	status = NGBE_ERR_MASTER_REQUESTS_PENDING;
 
@@ -1151,6 +1110,4 @@ s32 ngbe_acquire_swfw_sync(struct ngbe_hw *hw, u32 mask)
 	u32 i;
 
-	DEBUGFUNC("ngbe_acquire_swfw_sync");
-
 	for (i = 0; i < timeout; i++) {
 		/*
@@ -1195,6 +1152,4 @@ void ngbe_release_swfw_sync(struct ngbe_hw *hw, u32 mask)
 	u32 swmask = mask;
 
-	DEBUGFUNC("ngbe_release_swfw_sync");
-
 	ngbe_get_eeprom_semaphore(hw);
 
@@ -1220,7 +1175,4 @@ s32 ngbe_disable_sec_rx_path(struct ngbe_hw *hw)
 	u32 secrxreg;
 
-	DEBUGFUNC("ngbe_disable_sec_rx_path");
-
-
 	secrxreg = rd32(hw, NGBE_SECRXCTL);
 	secrxreg |= NGBE_SECRXCTL_XDSA;
@@ -1237,6 +1189,5 @@ s32 ngbe_disable_sec_rx_path(struct ngbe_hw *hw)
 	/* For informational purposes only */
 	if (i >= NGBE_MAX_SECRX_POLL)
-		DEBUGOUT("Rx unit being enabled before security "
-			 "path fully disabled.  Continuing with init.\n");
+		DEBUGOUT("Rx unit being enabled before security path fully disabled.  Continuing with init.");
 
 	return 0;
@@ -1253,6 +1204,4 @@ s32 ngbe_enable_sec_rx_path(struct ngbe_hw *hw)
 	u32 secrxreg;
 
-	DEBUGFUNC("ngbe_enable_sec_rx_path");
-
 	secrxreg = rd32(hw, NGBE_SECRXCTL);
 	secrxreg &= ~NGBE_SECRXCTL_XDSA;
@@ -1274,9 +1223,7 @@ s32 ngbe_clear_vmdq(struct ngbe_hw *hw, u32 rar, u32 vmdq)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("ngbe_clear_vmdq");
-
 	/* Make sure we are using a valid rar index range */
 	if (rar >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", rar);
+		DEBUGOUT("RAR index %d is out of range.", rar);
 		return NGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -1312,9 +1259,7 @@ s32 ngbe_set_vmdq(struct ngbe_hw *hw, u32 rar, u32 vmdq)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("ngbe_set_vmdq");
-
 	/* Make sure we are using a valid rar index range */
 	if (rar >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", rar);
+		DEBUGOUT("RAR index %d is out of range.", rar);
 		return NGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -1337,6 +1282,5 @@ s32 ngbe_init_uta_tables(struct ngbe_hw *hw)
 	int i;
 
-	DEBUGFUNC("ngbe_init_uta_tables");
-	DEBUGOUT(" Clearing UTA\n");
+	DEBUGOUT(" Clearing UTA");
 
 	for (i = 0; i < 128; i++)
@@ -1393,5 +1337,5 @@ s32 ngbe_find_vlvf_slot(struct ngbe_hw *hw, u32 vlan, bool vlvf_bypass)
 	 */
 	if (!first_empty_slot)
-		DEBUGOUT("No space in VLVF.\n");
+		DEBUGOUT("No space in VLVF.");
 
 	return first_empty_slot ? first_empty_slot : NGBE_ERR_NO_SPACE;
@@ -1414,6 +1358,4 @@ s32 ngbe_set_vfta(struct ngbe_hw *hw, u32 vlan, u32 vind,
 	s32 err;
 
-	DEBUGFUNC("ngbe_set_vfta");
-
 	if (vlan > 4095 || vind > 63)
 		return NGBE_ERR_PARAM;
@@ -1483,6 +1425,4 @@ s32 ngbe_set_vlvf(struct ngbe_hw *hw, u32 vlan, u32 vind,
 	s32 vlvf_index;
 
-	DEBUGFUNC("ngbe_set_vlvf");
-
 	if (vlan > 4095 || vind > 63)
 		return NGBE_ERR_PARAM;
@@ -1564,6 +1504,4 @@ s32 ngbe_clear_vfta(struct ngbe_hw *hw)
 	u32 offset;
 
-	DEBUGFUNC("ngbe_clear_vfta");
-
 	for (offset = 0; offset < hw->mac.vft_size; offset++)
 		wr32(hw, NGBE_VLANTBL(offset), 0);
@@ -1593,6 +1531,4 @@ s32 ngbe_check_mac_link_em(struct ngbe_hw *hw, u32 *speed,
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_check_mac_link_em");
-
 	reg = rd32(hw, NGBE_GPIOINTSTAT);
 	wr32(hw, NGBE_GPIOEOI, reg);
@@ -1618,5 +1554,4 @@ s32 ngbe_get_link_capabilities_em(struct ngbe_hw *hw,
 	s32 status = 0;
 
-	DEBUGFUNC("\n");
 
 	hw->mac.autoneg = *autoneg;
@@ -1641,6 +1576,4 @@ s32 ngbe_setup_mac_link_em(struct ngbe_hw *hw,
 	s32 status;
 
-	DEBUGFUNC("\n");
-
 	/* Setup the PHY according to input speed */
 	status = hw->phy.setup_link(hw, speed, autoneg_wait_to_complete);
@@ -1722,6 +1655,4 @@ s32 ngbe_init_thermal_sensor_thresh(struct ngbe_hw *hw)
 	struct ngbe_thermal_sensor_data *data = &hw->mac.thermal_sensor_data;
 
-	DEBUGFUNC("ngbe_init_thermal_sensor_thresh");
-
 	memset(data, 0, sizeof(struct ngbe_thermal_sensor_data));
 
@@ -1747,6 +1678,4 @@ s32 ngbe_mac_check_overtemp(struct ngbe_hw *hw)
 	u32 ts_state;
 
-	DEBUGFUNC("ngbe_mac_check_overtemp");
-
 	/* Check that the LASI temp alarm status was triggered */
 	ts_state = rd32(hw, NGBE_TSALM);
@@ -1803,6 +1732,4 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("ngbe_set_mac_type");
-
 	if (hw->vendor_id != PCI_VENDOR_ID_WANGXUN) {
 		DEBUGOUT("Unsupported vendor id: %x", hw->vendor_id);
@@ -1833,5 +1760,5 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
 	}
 
-	DEBUGOUT("found mac: %d media: %d, returns: %d\n",
+	DEBUGOUT("found mac: %d media: %d, returns: %d",
 		  hw->mac.type, hw->phy.media_type, err);
 	return err;
@@ -1847,6 +1774,4 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
 s32 ngbe_enable_rx_dma(struct ngbe_hw *hw, u32 regval)
 {
-	DEBUGFUNC("ngbe_enable_rx_dma");
-
 	/*
 	 * Workaround silicon errata when enabling the Rx datapath.
@@ -1855,5 +1780,4 @@ s32 ngbe_enable_rx_dma(struct ngbe_hw *hw, u32 regval)
 	 * completely disabled prior to enabling the Rx unit.
 	 */
-
 	hw->mac.disable_sec_rx_path(hw);
 
@@ -1936,6 +1860,4 @@ s32 ngbe_init_ops_pf(struct ngbe_hw *hw)
 	struct ngbe_mbx_info *mbx = &hw->mbx;
 
-	DEBUGFUNC("ngbe_init_ops_pf");
-
 	/* BUS */
 	bus->set_lan_id = ngbe_set_lan_id_multi_port;
@@ -2039,6 +1961,4 @@ s32 ngbe_init_shared_code(struct ngbe_hw *hw)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_init_shared_code");
-
 	/*
 	 * Set the mac type
diff --git a/drivers/net/ngbe/base/ngbe_mbx.c b/drivers/net/ngbe/base/ngbe_mbx.c
index 764ae81319..bc0adbb3ec 100644
--- a/drivers/net/ngbe/base/ngbe_mbx.c
+++ b/drivers/net/ngbe/base/ngbe_mbx.c
@@ -22,6 +22,4 @@ s32 ngbe_read_mbx(struct ngbe_hw *hw, u32 *msg, u16 size, u16 mbx_id)
 	s32 ret_val = NGBE_ERR_MBX;
 
-	DEBUGFUNC("ngbe_read_mbx");
-
 	/* limit read to size of mailbox */
 	if (size > mbx->size)
@@ -48,6 +46,4 @@ s32 ngbe_write_mbx(struct ngbe_hw *hw, u32 *msg, u16 size, u16 mbx_id)
 	s32 ret_val = 0;
 
-	DEBUGFUNC("ngbe_write_mbx");
-
 	if (size > mbx->size) {
 		ret_val = NGBE_ERR_MBX;
@@ -72,6 +68,4 @@ s32 ngbe_check_for_msg(struct ngbe_hw *hw, u16 mbx_id)
 	s32 ret_val = NGBE_ERR_MBX;
 
-	DEBUGFUNC("ngbe_check_for_msg");
-
 	if (mbx->check_for_msg)
 		ret_val = mbx->check_for_msg(hw, mbx_id);
@@ -92,6 +86,4 @@ s32 ngbe_check_for_ack(struct ngbe_hw *hw, u16 mbx_id)
 	s32 ret_val = NGBE_ERR_MBX;
 
-	DEBUGFUNC("ngbe_check_for_ack");
-
 	if (mbx->check_for_ack)
 		ret_val = mbx->check_for_ack(hw, mbx_id);
@@ -112,6 +104,4 @@ s32 ngbe_check_for_rst(struct ngbe_hw *hw, u16 mbx_id)
 	s32 ret_val = NGBE_ERR_MBX;
 
-	DEBUGFUNC("ngbe_check_for_rst");
-
 	if (mbx->check_for_rst)
 		ret_val = mbx->check_for_rst(hw, mbx_id);
@@ -145,6 +135,4 @@ s32 ngbe_check_for_msg_pf(struct ngbe_hw *hw, u16 vf_number)
 	u32 vf_bit = vf_number;
 
-	DEBUGFUNC("ngbe_check_for_msg_pf");
-
 	if (!ngbe_check_for_bit_pf(hw, NGBE_MBVFICR_VFREQ_VF1 << vf_bit)) {
 		ret_val = 0;
@@ -167,6 +155,4 @@ s32 ngbe_check_for_ack_pf(struct ngbe_hw *hw, u16 vf_number)
 	u32 vf_bit = vf_number;
 
-	DEBUGFUNC("ngbe_check_for_ack_pf");
-
 	if (!ngbe_check_for_bit_pf(hw, NGBE_MBVFICR_VFACK_VF1 << vf_bit)) {
 		ret_val = 0;
@@ -189,6 +175,4 @@ s32 ngbe_check_for_rst_pf(struct ngbe_hw *hw, u16 vf_number)
 	s32 ret_val = NGBE_ERR_MBX;
 
-	DEBUGFUNC("ngbe_check_for_rst_pf");
-
 	vflre = rd32(hw, NGBE_FLRVFE);
 	if (vflre & (1 << vf_number)) {
@@ -213,6 +197,4 @@ STATIC s32 ngbe_obtain_mbx_lock_pf(struct ngbe_hw *hw, u16 vf_number)
 	u32 p2v_mailbox;
 
-	DEBUGFUNC("ngbe_obtain_mbx_lock_pf");
-
 	/* Take ownership of the buffer */
 	wr32(hw, NGBE_MBCTL(vf_number), NGBE_MBCTL_PFU);
@@ -243,6 +225,4 @@ s32 ngbe_write_mbx_pf(struct ngbe_hw *hw, u32 *msg, u16 size, u16 vf_number)
 	u16 i;
 
-	DEBUGFUNC("ngbe_write_mbx_pf");
-
 	/* lock the mailbox to prevent pf/vf race condition */
 	ret_val = ngbe_obtain_mbx_lock_pf(hw, vf_number);
@@ -284,6 +264,4 @@ s32 ngbe_read_mbx_pf(struct ngbe_hw *hw, u32 *msg, u16 size, u16 vf_number)
 	u16 i;
 
-	DEBUGFUNC("ngbe_read_mbx_pf");
-
 	/* lock the mailbox to prevent pf/vf race condition */
 	ret_val = ngbe_obtain_mbx_lock_pf(hw, vf_number);
diff --git a/drivers/net/ngbe/base/ngbe_mng.c b/drivers/net/ngbe/base/ngbe_mng.c
index 68e06e2c24..dd32644bfe 100644
--- a/drivers/net/ngbe/base/ngbe_mng.c
+++ b/drivers/net/ngbe/base/ngbe_mng.c
@@ -27,8 +27,6 @@ ngbe_hic_unlocked(struct ngbe_hw *hw, u32 *buffer, u32 length, u32 timeout)
 	u16 i, dword_len;
 
-	DEBUGFUNC("ngbe_hic_unlocked");
-
 	if (!length || length > NGBE_PMMBX_BSIZE) {
-		DEBUGOUT("Buffer length failure buffersize=%d.\n", length);
+		DEBUGOUT("Buffer length failure buffersize=%d.", length);
 		return NGBE_ERR_HOST_INTERFACE_COMMAND;
 	}
@@ -60,5 +58,5 @@ ngbe_hic_unlocked(struct ngbe_hw *hw, u32 *buffer, u32 length, u32 timeout)
 		&value, timeout, 1000);
 	if (!loop || !(value & NGBE_MNGMBXCTL_FWACK)) {
-		DEBUGOUT("Command has failed with no status valid.\n");
+		DEBUGOUT("Command has failed with no status valid.");
 		return NGBE_ERR_HOST_INTERFACE_COMMAND;
 	}
@@ -96,8 +94,6 @@ ngbe_host_interface_command(struct ngbe_hw *hw, u32 *buffer,
 	u32 dword_len;
 
-	DEBUGFUNC("ngbe_host_interface_command");
-
 	if (length == 0 || length > NGBE_PMMBX_BSIZE) {
-		DEBUGOUT("Buffer length failure buffersize=%d.\n", length);
+		DEBUGOUT("Buffer length failure buffersize=%d.", length);
 		return NGBE_ERR_HOST_INTERFACE_COMMAND;
 	}
@@ -141,5 +137,5 @@ ngbe_host_interface_command(struct ngbe_hw *hw, u32 *buffer,
 
 	if (length < buf_len + hdr_size) {
-		DEBUGOUT("Buffer not large enough for reply message.\n");
+		DEBUGOUT("Buffer not large enough for reply message.");
 		err = NGBE_ERR_HOST_INTERFACE_COMMAND;
 		goto rel_out;
@@ -307,6 +303,4 @@ s32 ngbe_hic_check_cap(struct ngbe_hw *hw)
 	int i;
 
-	DEBUGFUNC("\n");
-
 	command.hdr.req.cmd = FW_EEPROM_CHECK_STATUS;
 	command.hdr.req.buf_lenh = 0;
diff --git a/drivers/net/ngbe/base/ngbe_phy.c b/drivers/net/ngbe/base/ngbe_phy.c
index 51b0a2ec60..7a0ebba98c 100644
--- a/drivers/net/ngbe/base/ngbe_phy.c
+++ b/drivers/net/ngbe/base/ngbe_phy.c
@@ -47,5 +47,5 @@ static bool ngbe_probe_phy(struct ngbe_hw *hw, u16 phy_addr)
 {
 	if (!ngbe_validate_phy_addr(hw, phy_addr)) {
-		DEBUGOUT("Unable to validate PHY address 0x%04X\n",
+		DEBUGOUT("Unable to validate PHY address 0x%04X",
 			phy_addr);
 		return false;
@@ -73,6 +73,4 @@ s32 ngbe_identify_phy(struct ngbe_hw *hw)
 	u16 phy_addr;
 
-	DEBUGFUNC("ngbe_identify_phy");
-
 	if (hw->phy.type != ngbe_phy_unknown)
 		return 0;
@@ -104,9 +102,7 @@ s32 ngbe_check_reset_blocked(struct ngbe_hw *hw)
 	u32 mmngc;
 
-	DEBUGFUNC("ngbe_check_reset_blocked");
-
 	mmngc = rd32(hw, NGBE_STAT);
 	if (mmngc & NGBE_STAT_MNGVETO) {
-		DEBUGOUT("MNG_VETO bit detected.\n");
+		DEBUGOUT("MNG_VETO bit detected.");
 		return true;
 	}
@@ -126,6 +122,4 @@ bool ngbe_validate_phy_addr(struct ngbe_hw *hw, u32 phy_addr)
 	bool valid = false;
 
-	DEBUGFUNC("ngbe_validate_phy_addr");
-
 	if (hw->sub_device_id == NGBE_SUB_DEV_ID_EM_YT8521S_SFP)
 		return true;
@@ -138,5 +132,5 @@ bool ngbe_validate_phy_addr(struct ngbe_hw *hw, u32 phy_addr)
 		valid = true;
 
-	DEBUGOUT("PHY ID HIGH is 0x%04X\n", phy_id);
+	DEBUGOUT("PHY ID HIGH is 0x%04X", phy_id);
 
 	return valid;
@@ -154,6 +148,4 @@ s32 ngbe_get_phy_id(struct ngbe_hw *hw)
 	u16 phy_id_low = 0;
 
-	DEBUGFUNC("ngbe_get_phy_id");
-
 	err = hw->phy.read_reg(hw, NGBE_MD_PHY_ID_HIGH,
 				      NGBE_MD_DEV_PMA_PMD,
@@ -167,5 +159,5 @@ s32 ngbe_get_phy_id(struct ngbe_hw *hw)
 	hw->phy.revision = (u32)(phy_id_low & ~NGBE_PHY_REVISION_MASK);
 
-	DEBUGOUT("PHY_ID_HIGH 0x%04X, PHY_ID_LOW 0x%04X\n",
+	DEBUGOUT("PHY_ID_HIGH 0x%04X, PHY_ID_LOW 0x%04X",
 		  phy_id_high, phy_id_low);
 
@@ -182,6 +174,4 @@ enum ngbe_phy_type ngbe_get_phy_type_from_id(struct ngbe_hw *hw)
 	enum ngbe_phy_type phy_type;
 
-	DEBUGFUNC("ngbe_get_phy_type_from_id");
-
 	switch (hw->phy.id) {
 	case NGBE_PHYID_RTL:
@@ -216,6 +206,4 @@ s32 ngbe_reset_phy(struct ngbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("ngbe_reset_phy");
-
 	if (hw->phy.type == ngbe_phy_unknown)
 		err = ngbe_identify_phy(hw);
@@ -282,5 +270,5 @@ s32 ngbe_read_phy_reg_mdi(struct ngbe_hw *hw, u32 reg_addr, u32 device_type,
 	if (!po32m(hw, NGBE_MDIOSCD, NGBE_MDIOSCD_BUSY,
 		0, NULL, 100, 100)) {
-		DEBUGOUT("PHY address command did not complete\n");
+		DEBUGOUT("PHY address command did not complete");
 		return NGBE_ERR_PHY;
 	}
@@ -306,6 +294,4 @@ s32 ngbe_read_phy_reg(struct ngbe_hw *hw, u32 reg_addr,
 	u32 gssr = hw->phy.phy_semaphore_mask;
 
-	DEBUGFUNC("ngbe_read_phy_reg");
-
 	if (hw->mac.acquire_swfw_sync(hw, gssr))
 		return NGBE_ERR_SWFW_SYNC;
@@ -347,5 +333,5 @@ s32 ngbe_write_phy_reg_mdi(struct ngbe_hw *hw, u32 reg_addr,
 	if (!po32m(hw, NGBE_MDIOSCD, NGBE_MDIOSCD_BUSY,
 		0, NULL, 100, 100)) {
-		TLOG_DEBUG("PHY write cmd didn't complete\n");
+		DEBUGOUT("PHY write cmd didn't complete");
 		return NGBE_ERR_PHY;
 	}
@@ -368,6 +354,4 @@ s32 ngbe_write_phy_reg(struct ngbe_hw *hw, u32 reg_addr,
 	u32 gssr = hw->phy.phy_semaphore_mask;
 
-	DEBUGFUNC("ngbe_write_phy_reg");
-
 	if (hw->mac.acquire_swfw_sync(hw, gssr))
 		err = NGBE_ERR_SWFW_SYNC;
@@ -395,6 +379,4 @@ s32 ngbe_init_phy(struct ngbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("ngbe_init_phy");
-
 	hw->phy.addr = 0;
 
diff --git a/drivers/net/ngbe/base/ngbe_phy_mvl.c b/drivers/net/ngbe/base/ngbe_phy_mvl.c
index 2eb351d258..b1da0e3167 100644
--- a/drivers/net/ngbe/base/ngbe_phy_mvl.c
+++ b/drivers/net/ngbe/base/ngbe_phy_mvl.c
@@ -55,6 +55,4 @@ s32 ngbe_init_phy_mvl(struct ngbe_hw *hw)
 	int i;
 
-	DEBUGFUNC("ngbe_init_phy_mvl");
-
 	/* enable interrupts, only link status change and an done is allowed */
 	ngbe_write_phy_reg_mdi(hw, MVL_PAGE_SEL, 0, 2);
@@ -74,5 +72,5 @@ s32 ngbe_init_phy_mvl(struct ngbe_hw *hw)
 
 	if (i == 15) {
-		DEBUGOUT("phy reset exceeds maximum waiting period.\n");
+		DEBUGOUT("phy reset exceeds maximum waiting period.");
 		return NGBE_ERR_TIMEOUT;
 	}
@@ -120,5 +118,4 @@ s32 ngbe_setup_phy_link_mvl(struct ngbe_hw *hw, u32 speed,
 	u16 value;
 
-	DEBUGFUNC("ngbe_setup_phy_link_mvl");
 	UNREFERENCED_PARAMETER(autoneg_wait_to_complete);
 
@@ -177,6 +174,4 @@ s32 ngbe_reset_phy_mvl(struct ngbe_hw *hw)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_reset_phy_mvl");
-
 	if (hw->phy.type != ngbe_phy_mvl && hw->phy.type != ngbe_phy_mvl_sfi)
 		return NGBE_ERR_PHY_TYPE;
@@ -203,5 +198,5 @@ s32 ngbe_reset_phy_mvl(struct ngbe_hw *hw)
 
 	if (i == MVL_PHY_RST_WAIT_PERIOD) {
-		DEBUGOUT("PHY reset polling failed to complete.\n");
+		DEBUGOUT("PHY reset polling failed to complete.");
 		return NGBE_ERR_RESET_FAILED;
 	}
@@ -251,6 +246,4 @@ s32 ngbe_set_phy_pause_adv_mvl(struct ngbe_hw *hw, u16 pause_bit)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_set_phy_pause_adv_mvl");
-
 	if (hw->phy.type == ngbe_phy_mvl) {
 		status = hw->phy.read_reg(hw, MVL_ANA, 0, &value);
@@ -276,6 +269,4 @@ s32 ngbe_check_phy_link_mvl(struct ngbe_hw *hw,
 	u16 insr = 0;
 
-	DEBUGFUNC("ngbe_check_phy_link_mvl");
-
 	/* Initialize speed and link to default case */
 	*link_up = false;
diff --git a/drivers/net/ngbe/base/ngbe_phy_rtl.c b/drivers/net/ngbe/base/ngbe_phy_rtl.c
index 7b08b7a46c..a95efcbab6 100644
--- a/drivers/net/ngbe/base/ngbe_phy_rtl.c
+++ b/drivers/net/ngbe/base/ngbe_phy_rtl.c
@@ -58,5 +58,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
 	}
 	if (i == 15) {
-		DEBUGOUT("GPhy reset exceeds maximum times.\n");
+		DEBUGOUT("GPhy reset exceeds maximum times.");
 		return NGBE_ERR_PHY_TIMEOUT;
 	}
@@ -109,6 +109,4 @@ s32 ngbe_setup_phy_link_rtl(struct ngbe_hw *hw,
 	u16 value = 0;
 
-	DEBUGFUNC("ngbe_setup_phy_link_rtl");
-
 	UNREFERENCED_PARAMETER(autoneg_wait_to_complete);
 
@@ -130,5 +128,5 @@ s32 ngbe_setup_phy_link_rtl(struct ngbe_hw *hw,
 		default:
 			value = RTL_BMCR_SPEED_SELECT1 | RTL_BMCR_SPEED_SELECT0;
-			DEBUGOUT("unknown speed = 0x%x.\n", speed);
+			DEBUGOUT("unknown speed = 0x%x.", speed);
 			break;
 		}
@@ -230,6 +228,4 @@ s32 ngbe_reset_phy_rtl(struct ngbe_hw *hw)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_reset_phy_rtl");
-
 	value |= RTL_BMCR_RESET;
 	status = hw->phy.write_reg(hw, RTL_BMCR, RTL_DEV_ZERO, value);
@@ -300,6 +296,4 @@ s32 ngbe_check_phy_link_rtl(struct ngbe_hw *hw, u32 *speed, bool *link_up)
 	u16 insr = 0;
 
-	DEBUGFUNC("ngbe_check_phy_link_rtl");
-
 	hw->phy.read_reg(hw, RTL_INSR, 0xa43, &insr);
 
diff --git a/drivers/net/ngbe/base/ngbe_phy_yt.c b/drivers/net/ngbe/base/ngbe_phy_yt.c
index 8db0f9ce48..40f1725f61 100644
--- a/drivers/net/ngbe/base/ngbe_phy_yt.c
+++ b/drivers/net/ngbe/base/ngbe_phy_yt.c
@@ -103,6 +103,4 @@ s32 ngbe_init_phy_yt(struct ngbe_hw *hw)
 	u16 value = 0;
 
-	DEBUGFUNC("ngbe_init_phy_yt");
-
 	if (hw->phy.type != ngbe_phy_yt8521s_sfi)
 		return 0;
@@ -132,5 +130,4 @@ s32 ngbe_setup_phy_link_yt(struct ngbe_hw *hw, u32 speed,
 	u16 value;
 
-	DEBUGFUNC("ngbe_setup_phy_link_yt");
 	UNREFERENCED_PARAMETER(autoneg_wait_to_complete);
 
@@ -209,6 +206,4 @@ s32 ngbe_reset_phy_yt(struct ngbe_hw *hw)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_reset_phy_yt");
-
 	if (hw->phy.type != ngbe_phy_yt8521s &&
 		hw->phy.type != ngbe_phy_yt8521s_sfi)
@@ -228,5 +223,5 @@ s32 ngbe_reset_phy_yt(struct ngbe_hw *hw)
 
 	if (i == YT_PHY_RST_WAIT_PERIOD) {
-		DEBUGOUT("PHY reset polling failed to complete.\n");
+		DEBUGOUT("PHY reset polling failed to complete.");
 		return NGBE_ERR_RESET_FAILED;
 	}
@@ -240,6 +235,4 @@ s32 ngbe_get_phy_advertised_pause_yt(struct ngbe_hw *hw, u8 *pause_bit)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_get_phy_advertised_pause_yt");
-
 	status = hw->phy.read_reg(hw, YT_ANA, 0, &value);
 	value &= YT_FANA_PAUSE_MASK;
@@ -254,6 +247,4 @@ s32 ngbe_get_phy_lp_advertised_pause_yt(struct ngbe_hw *hw, u8 *pause_bit)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_get_phy_lp_advertised_pause_yt");
-
 	status = hw->phy.read_reg(hw, YT_LPAR, 0, &value);
 	value &= YT_FLPAR_PAUSE_MASK;
@@ -268,7 +259,4 @@ s32 ngbe_set_phy_pause_adv_yt(struct ngbe_hw *hw, u16 pause_bit)
 	s32 status = 0;
 
-	DEBUGFUNC("ngbe_set_phy_pause_adv_yt");
-
-
 	status = hw->phy.read_reg(hw, YT_ANA, 0, &value);
 	value &= ~YT_FANA_PAUSE_MASK;
@@ -288,6 +276,4 @@ s32 ngbe_check_phy_link_yt(struct ngbe_hw *hw,
 	u16 insr = 0;
 
-	DEBUGFUNC("ngbe_check_phy_link_yt");
-
 	/* Initialize speed and link to default case */
 	*link_up = false;
diff --git a/drivers/net/ngbe/ngbe_logs.h b/drivers/net/ngbe/ngbe_logs.h
index fd306419e6..e5165ffd60 100644
--- a/drivers/net/ngbe/ngbe_logs.h
+++ b/drivers/net/ngbe/ngbe_logs.h
@@ -38,9 +38,6 @@ extern int ngbe_logtype_tx;
 #endif
 
-#define TLOG_DEBUG(fmt, args...)  PMD_DRV_LOG(DEBUG, fmt, ##args)
-
-#define DEBUGOUT(fmt, args...)    TLOG_DEBUG(fmt, ##args)
-#define PMD_INIT_FUNC_TRACE()     TLOG_DEBUG(" >>")
-#define DEBUGFUNC(fmt)            TLOG_DEBUG(fmt)
+#define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
+#define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
 #endif /* _NGBE_LOGS_H_ */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.323583411 +0000
+++ 0070-net-ngbe-fix-debug-logs.patch	2022-03-01 10:41:01.377244113 +0000
@@ -1 +1 @@
-From c811e6a492affd55a1c02b13e93591214be2dd1f Mon Sep 17 00:00:00 2001
+From a8be311dd15259201f229522e67fff9a1d49bdf7 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit c811e6a492affd55a1c02b13e93591214be2dd1f ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -15 +16 @@
- drivers/net/ngbe/base/ngbe_hw.c      | 152 +++++++--------------------
+ drivers/net/ngbe/base/ngbe_hw.c      | 150 +++++++--------------------
@@ -17 +18 @@
- drivers/net/ngbe/base/ngbe_mng.c     |  16 +--
+ drivers/net/ngbe/base/ngbe_mng.c     |  14 +--
@@ -19,3 +20,3 @@
- drivers/net/ngbe/base/ngbe_phy_mvl.c |  17 +--
- drivers/net/ngbe/base/ngbe_phy_rtl.c |  18 ++--
- drivers/net/ngbe/base/ngbe_phy_yt.c  |  18 +---
+ drivers/net/ngbe/base/ngbe_phy_mvl.c |  13 +--
+ drivers/net/ngbe/base/ngbe_phy_rtl.c |  10 +-
+ drivers/net/ngbe/base/ngbe_phy_yt.c  |  16 +--
@@ -23 +24 @@
- 9 files changed, 65 insertions(+), 237 deletions(-)
+ 9 files changed, 57 insertions(+), 227 deletions(-)
@@ -96 +97 @@
-index 931fe8c8cb..fa2d749240 100644
+index 782fd71d29..c462fec9f9 100644
@@ -127 +128 @@
-@@ -156,6 +152,4 @@ s32 ngbe_reset_hw_em(struct ngbe_hw *hw)
+@@ -157,6 +153,4 @@ s32 ngbe_reset_hw_em(struct ngbe_hw *hw)
@@ -134 +135 @@
-@@ -205,6 +199,4 @@ s32 ngbe_clear_hw_cntrs(struct ngbe_hw *hw)
+@@ -206,6 +200,4 @@ s32 ngbe_clear_hw_cntrs(struct ngbe_hw *hw)
@@ -141 +142 @@
-@@ -305,6 +297,4 @@ s32 ngbe_get_mac_addr(struct ngbe_hw *hw, u8 *mac_addr)
+@@ -306,6 +298,4 @@ s32 ngbe_get_mac_addr(struct ngbe_hw *hw, u8 *mac_addr)
@@ -148 +149 @@
-@@ -332,6 +322,4 @@ void ngbe_set_lan_id_multi_port(struct ngbe_hw *hw)
+@@ -333,6 +323,4 @@ void ngbe_set_lan_id_multi_port(struct ngbe_hw *hw)
@@ -155 +156 @@
-@@ -353,6 +341,4 @@ s32 ngbe_stop_hw(struct ngbe_hw *hw)
+@@ -354,6 +342,4 @@ s32 ngbe_stop_hw(struct ngbe_hw *hw)
@@ -162 +163 @@
-@@ -410,6 +396,4 @@ s32 ngbe_led_on(struct ngbe_hw *hw, u32 index)
+@@ -411,6 +397,4 @@ s32 ngbe_led_on(struct ngbe_hw *hw, u32 index)
@@ -169 +170 @@
-@@ -432,6 +416,4 @@ s32 ngbe_led_off(struct ngbe_hw *hw, u32 index)
+@@ -433,6 +417,4 @@ s32 ngbe_led_off(struct ngbe_hw *hw, u32 index)
@@ -176 +177 @@
-@@ -455,6 +437,4 @@ s32 ngbe_validate_mac_addr(u8 *mac_addr)
+@@ -456,6 +438,4 @@ s32 ngbe_validate_mac_addr(u8 *mac_addr)
@@ -183 +184 @@
-@@ -487,9 +467,7 @@ s32 ngbe_set_rar(struct ngbe_hw *hw, u32 index, u8 *addr, u32 vmdq,
+@@ -488,9 +468,7 @@ s32 ngbe_set_rar(struct ngbe_hw *hw, u32 index, u8 *addr, u32 vmdq,
@@ -194 +195 @@
-@@ -539,9 +517,7 @@ s32 ngbe_clear_rar(struct ngbe_hw *hw, u32 index)
+@@ -540,9 +518,7 @@ s32 ngbe_clear_rar(struct ngbe_hw *hw, u32 index)
@@ -205 +206 @@
-@@ -579,6 +555,4 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
+@@ -580,6 +556,4 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
@@ -212 +213 @@
-@@ -591,16 +565,16 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
+@@ -592,16 +566,16 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
@@ -236 +237 @@
-@@ -612,5 +586,5 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
+@@ -613,5 +587,5 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
@@ -243 +244 @@
-@@ -626,5 +600,5 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
+@@ -627,5 +601,5 @@ s32 ngbe_init_rx_addrs(struct ngbe_hw *hw)
@@ -250 +251 @@
-@@ -651,6 +625,4 @@ static s32 ngbe_mta_vector(struct ngbe_hw *hw, u8 *mc_addr)
+@@ -652,6 +626,4 @@ static s32 ngbe_mta_vector(struct ngbe_hw *hw, u8 *mc_addr)
@@ -257 +258 @@
-@@ -667,5 +639,5 @@ static s32 ngbe_mta_vector(struct ngbe_hw *hw, u8 *mc_addr)
+@@ -668,5 +640,5 @@ static s32 ngbe_mta_vector(struct ngbe_hw *hw, u8 *mc_addr)
@@ -264 +265 @@
-@@ -690,10 +662,8 @@ void ngbe_set_mta(struct ngbe_hw *hw, u8 *mc_addr)
+@@ -691,10 +663,8 @@ void ngbe_set_mta(struct ngbe_hw *hw, u8 *mc_addr)
@@ -276 +277 @@
-@@ -729,6 +699,4 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
+@@ -730,6 +700,4 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
@@ -283 +284 @@
-@@ -740,5 +708,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
+@@ -741,5 +709,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
@@ -290 +291 @@
-@@ -746,5 +714,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
+@@ -747,5 +715,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
@@ -297 +298 @@
-@@ -763,5 +731,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
+@@ -764,5 +732,5 @@ s32 ngbe_update_mc_addr_list(struct ngbe_hw *hw, u8 *mc_addr_list,
@@ -304 +305 @@
-@@ -778,9 +746,7 @@ s32 ngbe_setup_fc_em(struct ngbe_hw *hw)
+@@ -779,9 +747,7 @@ s32 ngbe_setup_fc_em(struct ngbe_hw *hw)
@@ -315 +316 @@
-@@ -838,5 +804,5 @@ s32 ngbe_setup_fc_em(struct ngbe_hw *hw)
+@@ -839,5 +805,5 @@ s32 ngbe_setup_fc_em(struct ngbe_hw *hw)
@@ -322 +323 @@
-@@ -862,6 +828,4 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
+@@ -863,6 +829,4 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
@@ -329 +330 @@
-@@ -874,5 +838,5 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
+@@ -875,5 +839,5 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
@@ -336 +337 @@
-@@ -930,5 +894,5 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
+@@ -931,5 +895,5 @@ s32 ngbe_fc_enable(struct ngbe_hw *hw)
@@ -343 +344 @@
-@@ -988,6 +952,5 @@ s32 ngbe_negotiate_fc(struct ngbe_hw *hw, u32 adv_reg, u32 lp_reg,
+@@ -989,6 +953,5 @@ s32 ngbe_negotiate_fc(struct ngbe_hw *hw, u32 adv_reg, u32 lp_reg,
@@ -351 +352 @@
-@@ -1004,20 +967,20 @@ s32 ngbe_negotiate_fc(struct ngbe_hw *hw, u32 adv_reg, u32 lp_reg,
+@@ -1005,20 +968,20 @@ s32 ngbe_negotiate_fc(struct ngbe_hw *hw, u32 adv_reg, u32 lp_reg,
@@ -377 +378 @@
-@@ -1057,6 +1020,4 @@ void ngbe_fc_autoneg(struct ngbe_hw *hw)
+@@ -1058,6 +1021,4 @@ void ngbe_fc_autoneg(struct ngbe_hw *hw)
@@ -384 +385 @@
-@@ -1102,6 +1063,4 @@ s32 ngbe_set_pcie_master(struct ngbe_hw *hw, bool enable)
+@@ -1103,6 +1064,4 @@ s32 ngbe_set_pcie_master(struct ngbe_hw *hw, bool enable)
@@ -391 +392 @@
-@@ -1127,5 +1086,5 @@ s32 ngbe_set_pcie_master(struct ngbe_hw *hw, bool enable)
+@@ -1128,5 +1087,5 @@ s32 ngbe_set_pcie_master(struct ngbe_hw *hw, bool enable)
@@ -405,7 +405,0 @@
-@@ -1175,5 +1132,5 @@ s32 ngbe_acquire_swfw_sync(struct ngbe_hw *hw, u32 mask)
- 
- 	fwsm = rd32(hw, NGBE_MNGFWSYNC);
--	DEBUGOUT("SWFW semaphore not granted: MNG_SWFW_SYNC = 0x%x, MNG_FW_SM = 0x%x\n",
-+	DEBUGOUT("SWFW semaphore not granted: MNG_SWFW_SYNC = 0x%x, MNG_FW_SM = 0x%x",
- 			mngsem, fwsm);
- 
@@ -509 +503 @@
- 	u16 value = 0;
+ 
@@ -513 +507 @@
-@@ -1643,6 +1578,4 @@ s32 ngbe_setup_mac_link_em(struct ngbe_hw *hw,
+@@ -1641,6 +1576,4 @@ s32 ngbe_setup_mac_link_em(struct ngbe_hw *hw,
@@ -520 +514 @@
-@@ -1724,6 +1657,4 @@ s32 ngbe_init_thermal_sensor_thresh(struct ngbe_hw *hw)
+@@ -1722,6 +1655,4 @@ s32 ngbe_init_thermal_sensor_thresh(struct ngbe_hw *hw)
@@ -527 +521 @@
-@@ -1749,6 +1680,4 @@ s32 ngbe_mac_check_overtemp(struct ngbe_hw *hw)
+@@ -1747,6 +1678,4 @@ s32 ngbe_mac_check_overtemp(struct ngbe_hw *hw)
@@ -534 +528 @@
-@@ -1805,6 +1734,4 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
+@@ -1803,6 +1732,4 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
@@ -541 +535 @@
-@@ -1847,5 +1774,5 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
+@@ -1833,5 +1760,5 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
@@ -548 +542 @@
-@@ -1861,6 +1788,4 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
+@@ -1847,6 +1774,4 @@ s32 ngbe_set_mac_type(struct ngbe_hw *hw)
@@ -555 +549 @@
-@@ -1869,5 +1794,4 @@ s32 ngbe_enable_rx_dma(struct ngbe_hw *hw, u32 regval)
+@@ -1855,5 +1780,4 @@ s32 ngbe_enable_rx_dma(struct ngbe_hw *hw, u32 regval)
@@ -561 +555 @@
-@@ -1961,6 +1885,4 @@ s32 ngbe_init_ops_pf(struct ngbe_hw *hw)
+@@ -1936,6 +1860,4 @@ s32 ngbe_init_ops_pf(struct ngbe_hw *hw)
@@ -568 +562 @@
-@@ -2065,6 +1987,4 @@ s32 ngbe_init_shared_code(struct ngbe_hw *hw)
+@@ -2039,6 +1961,4 @@ s32 ngbe_init_shared_code(struct ngbe_hw *hw)
@@ -657 +651 @@
-index c6f4dc2e0b..ad9372bec2 100644
+index 68e06e2c24..dd32644bfe 100644
@@ -701,7 +694,0 @@
-@@ -346,6 +340,4 @@ s32 ngbe_phy_led_oem_chk(struct ngbe_hw *hw, u32 *data)
- 	int i;
- 
--	DEBUGFUNC("\n");
--
- 	command.hdr.req.cmd = FW_PHY_LED_CONF;
- 	command.hdr.req.buf_lenh = 0;
@@ -709 +696 @@
-index 93450b2977..3d5093ec7e 100644
+index 51b0a2ec60..7a0ebba98c 100644
@@ -719 +706 @@
-@@ -72,6 +72,4 @@ s32 ngbe_identify_phy(struct ngbe_hw *hw)
+@@ -73,6 +73,4 @@ s32 ngbe_identify_phy(struct ngbe_hw *hw)
@@ -726 +713 @@
-@@ -103,9 +101,7 @@ s32 ngbe_check_reset_blocked(struct ngbe_hw *hw)
+@@ -104,9 +102,7 @@ s32 ngbe_check_reset_blocked(struct ngbe_hw *hw)
@@ -737 +724 @@
-@@ -125,6 +121,4 @@ bool ngbe_validate_phy_addr(struct ngbe_hw *hw, u32 phy_addr)
+@@ -126,6 +122,4 @@ bool ngbe_validate_phy_addr(struct ngbe_hw *hw, u32 phy_addr)
@@ -744 +731 @@
-@@ -137,5 +131,5 @@ bool ngbe_validate_phy_addr(struct ngbe_hw *hw, u32 phy_addr)
+@@ -138,5 +132,5 @@ bool ngbe_validate_phy_addr(struct ngbe_hw *hw, u32 phy_addr)
@@ -751 +738 @@
-@@ -153,6 +147,4 @@ s32 ngbe_get_phy_id(struct ngbe_hw *hw)
+@@ -154,6 +148,4 @@ s32 ngbe_get_phy_id(struct ngbe_hw *hw)
@@ -758 +745 @@
-@@ -166,5 +158,5 @@ s32 ngbe_get_phy_id(struct ngbe_hw *hw)
+@@ -167,5 +159,5 @@ s32 ngbe_get_phy_id(struct ngbe_hw *hw)
@@ -765,2 +752,2 @@
-@@ -180,6 +172,4 @@ s32 ngbe_get_phy_type_from_id(struct ngbe_hw *hw)
- 	s32 status = 0;
+@@ -182,6 +174,4 @@ enum ngbe_phy_type ngbe_get_phy_type_from_id(struct ngbe_hw *hw)
+ 	enum ngbe_phy_type phy_type;
@@ -772 +759 @@
-@@ -217,6 +207,4 @@ s32 ngbe_reset_phy(struct ngbe_hw *hw)
+@@ -216,6 +206,4 @@ s32 ngbe_reset_phy(struct ngbe_hw *hw)
@@ -779 +766 @@
-@@ -283,5 +271,5 @@ s32 ngbe_read_phy_reg_mdi(struct ngbe_hw *hw, u32 reg_addr, u32 device_type,
+@@ -282,5 +270,5 @@ s32 ngbe_read_phy_reg_mdi(struct ngbe_hw *hw, u32 reg_addr, u32 device_type,
@@ -786 +773 @@
-@@ -307,6 +295,4 @@ s32 ngbe_read_phy_reg(struct ngbe_hw *hw, u32 reg_addr,
+@@ -306,6 +294,4 @@ s32 ngbe_read_phy_reg(struct ngbe_hw *hw, u32 reg_addr,
@@ -793 +780 @@
-@@ -348,5 +334,5 @@ s32 ngbe_write_phy_reg_mdi(struct ngbe_hw *hw, u32 reg_addr,
+@@ -347,5 +333,5 @@ s32 ngbe_write_phy_reg_mdi(struct ngbe_hw *hw, u32 reg_addr,
@@ -800 +787 @@
-@@ -369,6 +355,4 @@ s32 ngbe_write_phy_reg(struct ngbe_hw *hw, u32 reg_addr,
+@@ -368,6 +354,4 @@ s32 ngbe_write_phy_reg(struct ngbe_hw *hw, u32 reg_addr,
@@ -807 +794 @@
-@@ -396,6 +380,4 @@ s32 ngbe_init_phy(struct ngbe_hw *hw)
+@@ -395,6 +379,4 @@ s32 ngbe_init_phy(struct ngbe_hw *hw)
@@ -815 +802 @@
-index 01cb6b9bb3..a828597e7b 100644
+index 2eb351d258..b1da0e3167 100644
@@ -818,8 +805 @@
-@@ -67,5 +67,5 @@ s32 ngbe_check_phy_mode_mvl(struct ngbe_hw *hw)
- 		hw->mac.link_type = ngbe_link_fiber;
- 	} else {
--		DEBUGOUT("marvell 88E1512 mode %x is not supported.\n", value);
-+		DEBUGOUT("marvell 88E1512 mode %x is not supported.", value);
- 		return NGBE_ERR_DEVICE_NOT_SUPPORTED;
- 	}
-@@ -80,6 +80,4 @@ s32 ngbe_init_phy_mvl(struct ngbe_hw *hw)
+@@ -55,6 +55,4 @@ s32 ngbe_init_phy_mvl(struct ngbe_hw *hw)
@@ -832 +812 @@
-@@ -99,5 +97,5 @@ s32 ngbe_init_phy_mvl(struct ngbe_hw *hw)
+@@ -74,5 +72,5 @@ s32 ngbe_init_phy_mvl(struct ngbe_hw *hw)
@@ -839 +819 @@
-@@ -138,5 +136,4 @@ s32 ngbe_setup_phy_link_mvl(struct ngbe_hw *hw, u32 speed,
+@@ -120,5 +118,4 @@ s32 ngbe_setup_phy_link_mvl(struct ngbe_hw *hw, u32 speed,
@@ -845,8 +825 @@
-@@ -171,5 +168,5 @@ s32 ngbe_setup_phy_link_mvl(struct ngbe_hw *hw, u32 speed,
- 				value = MVL_CTRL_SPEED_SELECT0 |
- 					MVL_CTRL_SPEED_SELECT1;
--				DEBUGOUT("unknown speed = 0x%x.\n", speed);
-+				DEBUGOUT("unknown speed = 0x%x.", speed);
- 				break;
- 			}
-@@ -236,6 +233,4 @@ s32 ngbe_reset_phy_mvl(struct ngbe_hw *hw)
+@@ -177,6 +174,4 @@ s32 ngbe_reset_phy_mvl(struct ngbe_hw *hw)
@@ -859 +832 @@
-@@ -262,5 +257,5 @@ s32 ngbe_reset_phy_mvl(struct ngbe_hw *hw)
+@@ -203,5 +198,5 @@ s32 ngbe_reset_phy_mvl(struct ngbe_hw *hw)
@@ -866 +839 @@
-@@ -310,6 +305,4 @@ s32 ngbe_set_phy_pause_adv_mvl(struct ngbe_hw *hw, u16 pause_bit)
+@@ -251,6 +246,4 @@ s32 ngbe_set_phy_pause_adv_mvl(struct ngbe_hw *hw, u16 pause_bit)
@@ -873 +846 @@
-@@ -335,6 +328,4 @@ s32 ngbe_check_phy_link_mvl(struct ngbe_hw *hw,
+@@ -276,6 +269,4 @@ s32 ngbe_check_phy_link_mvl(struct ngbe_hw *hw,
@@ -881 +854 @@
-index f49d829dff..3a2d624ddb 100644
+index 7b08b7a46c..a95efcbab6 100644
@@ -884 +857 @@
-@@ -80,5 +80,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
+@@ -58,5 +58,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
@@ -891,29 +864 @@
-@@ -87,5 +87,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
- 	hw->phy.read_reg(hw, RTL_SCR, 0xa46, &value);
- 	if (!(value & RTL_SCR_EFUSE)) {
--		DEBUGOUT("Write EFUSE failed.\n");
-+		DEBUGOUT("Write EFUSE failed.");
- 		return NGBE_ERR_PHY_TIMEOUT;
- 	}
-@@ -98,5 +98,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
- 	}
- 	if (i == 1000)
--		DEBUGOUT("PHY wait mdio 1 access timeout.\n");
-+		DEBUGOUT("PHY wait mdio 1 access timeout.");
- 
- 
-@@ -104,5 +104,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
- 	hw->phy.read_reg(hw, RTL_SCR, 0xa46, &value);
- 	if (!(value & RTL_SCR_EXTINI)) {
--		DEBUGOUT("Write EXIINI failed.\n");
-+		DEBUGOUT("Write EXIINI failed.");
- 		return NGBE_ERR_PHY_TIMEOUT;
- 	}
-@@ -115,5 +115,5 @@ s32 ngbe_init_phy_rtl(struct ngbe_hw *hw)
- 	}
- 	if (i == 1000)
--		DEBUGOUT("PHY wait mdio 2 access timeout.\n");
-+		DEBUGOUT("PHY wait mdio 2 access timeout.");
- 
- 	for (i = 0; i < 1000; i++) {
-@@ -141,6 +141,4 @@ s32 ngbe_setup_phy_link_rtl(struct ngbe_hw *hw,
+@@ -109,6 +109,4 @@ s32 ngbe_setup_phy_link_rtl(struct ngbe_hw *hw,
@@ -926 +871 @@
-@@ -162,5 +160,5 @@ s32 ngbe_setup_phy_link_rtl(struct ngbe_hw *hw,
+@@ -130,5 +128,5 @@ s32 ngbe_setup_phy_link_rtl(struct ngbe_hw *hw,
@@ -933 +878 @@
-@@ -254,6 +252,4 @@ s32 ngbe_reset_phy_rtl(struct ngbe_hw *hw)
+@@ -230,6 +228,4 @@ s32 ngbe_reset_phy_rtl(struct ngbe_hw *hw)
@@ -940 +885 @@
-@@ -314,6 +310,4 @@ s32 ngbe_check_phy_link_rtl(struct ngbe_hw *hw, u32 *speed, bool *link_up)
+@@ -300,6 +296,4 @@ s32 ngbe_check_phy_link_rtl(struct ngbe_hw *hw, u32 *speed, bool *link_up)
@@ -948 +893 @@
-index 2d184a1c30..34d69707dd 100644
+index 8db0f9ce48..40f1725f61 100644
@@ -956,3 +901,3 @@
- 	/* close sds area register */
- 	ngbe_write_phy_reg_ext_yt(hw, YT_SMI_PHY, 0, 0);
-@@ -131,5 +129,4 @@ s32 ngbe_setup_phy_link_yt(struct ngbe_hw *hw, u32 speed,
+ 	if (hw->phy.type != ngbe_phy_yt8521s_sfi)
+ 		return 0;
+@@ -132,5 +130,4 @@ s32 ngbe_setup_phy_link_yt(struct ngbe_hw *hw, u32 speed,
@@ -964,8 +909 @@
-@@ -154,5 +151,5 @@ s32 ngbe_setup_phy_link_yt(struct ngbe_hw *hw, u32 speed,
- 				value = YT_BCR_SPEED_SELECT0 |
- 					YT_BCR_SPEED_SELECT1;
--				DEBUGOUT("unknown speed = 0x%x.\n",
-+				DEBUGOUT("unknown speed = 0x%x.",
- 					speed);
- 				break;
-@@ -325,6 +322,4 @@ s32 ngbe_reset_phy_yt(struct ngbe_hw *hw)
+@@ -209,6 +206,4 @@ s32 ngbe_reset_phy_yt(struct ngbe_hw *hw)
@@ -978 +916 @@
-@@ -362,5 +357,5 @@ s32 ngbe_reset_phy_yt(struct ngbe_hw *hw)
+@@ -228,5 +223,5 @@ s32 ngbe_reset_phy_yt(struct ngbe_hw *hw)
@@ -985 +923 @@
-@@ -374,6 +369,4 @@ s32 ngbe_get_phy_advertised_pause_yt(struct ngbe_hw *hw, u8 *pause_bit)
+@@ -240,6 +235,4 @@ s32 ngbe_get_phy_advertised_pause_yt(struct ngbe_hw *hw, u8 *pause_bit)
@@ -992 +930 @@
-@@ -388,6 +381,4 @@ s32 ngbe_get_phy_lp_advertised_pause_yt(struct ngbe_hw *hw, u8 *pause_bit)
+@@ -254,6 +247,4 @@ s32 ngbe_get_phy_lp_advertised_pause_yt(struct ngbe_hw *hw, u8 *pause_bit)
@@ -999 +937 @@
-@@ -402,7 +393,4 @@ s32 ngbe_set_phy_pause_adv_yt(struct ngbe_hw *hw, u16 pause_bit)
+@@ -268,7 +259,4 @@ s32 ngbe_set_phy_pause_adv_yt(struct ngbe_hw *hw, u16 pause_bit)
@@ -1007 +945 @@
-@@ -422,6 +410,4 @@ s32 ngbe_check_phy_link_yt(struct ngbe_hw *hw,
+@@ -288,6 +276,4 @@ s32 ngbe_check_phy_link_yt(struct ngbe_hw *hw,


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

* patch 'net/txgbe: fix debug logs' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (68 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ngbe: fix debug logs' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: remove unused enumeration' " Kevin Traynor
                   ` (32 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Jiawen Wu; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/399b4893281c5d2bbf48e46f968cdf5476676d03

Thanks.

Kevin

---
From 399b4893281c5d2bbf48e46f968cdf5476676d03 Mon Sep 17 00:00:00 2001
From: Jiawen Wu <jiawenwu@trustnetic.com>
Date: Wed, 23 Feb 2022 18:28:57 +0800
Subject: [PATCH] net/txgbe: fix debug logs

[ upstream commit 75c85e39652ef2eb54dd07b8f3d6b42b3930e8fe ]

Remove 'DEBUGFUNC' due to too many invalid debug log prints, unify the
DEBUG level macros.

Fixes: 7dc117068a7c ("net/txgbe: support probe and remove")

Signed-off-by: Jiawen Wu <jiawenwu@trustnetic.com>
---
 drivers/net/txgbe/base/meson.build    |   2 +-
 drivers/net/txgbe/base/txgbe_eeprom.c |  41 ++----
 drivers/net/txgbe/base/txgbe_hw.c     | 202 ++++++--------------------
 drivers/net/txgbe/base/txgbe_mbx.c    |  38 -----
 drivers/net/txgbe/base/txgbe_mng.c    |  15 +-
 drivers/net/txgbe/base/txgbe_osdep.h  |   1 +
 drivers/net/txgbe/base/txgbe_phy.c    |  84 ++---------
 drivers/net/txgbe/base/txgbe_vf.c     |  12 +-
 drivers/net/txgbe/txgbe_logs.h        |   7 +-
 9 files changed, 78 insertions(+), 324 deletions(-)

diff --git a/drivers/net/txgbe/base/meson.build b/drivers/net/txgbe/base/meson.build
index 7a30191472..a81d6890fe 100644
--- a/drivers/net/txgbe/base/meson.build
+++ b/drivers/net/txgbe/base/meson.build
@@ -23,5 +23,5 @@ endforeach
 
 base_lib = static_library('txgbe_base', sources,
-    dependencies: static_rte_eal,
+    dependencies: [static_rte_eal, static_rte_net],
     c_args: c_args)
 base_objs = base_lib.extract_all_objects(recursive: true)
diff --git a/drivers/net/txgbe/base/txgbe_eeprom.c b/drivers/net/txgbe/base/txgbe_eeprom.c
index 72901cd0b0..4ed6bd6728 100644
--- a/drivers/net/txgbe/base/txgbe_eeprom.c
+++ b/drivers/net/txgbe/base/txgbe_eeprom.c
@@ -22,6 +22,4 @@ s32 txgbe_init_eeprom_params(struct txgbe_hw *hw)
 	int err = 0;
 
-	DEBUGFUNC("txgbe_init_eeprom_params");
-
 	if (eeprom->type != txgbe_eeprom_unknown)
 		return 0;
@@ -55,10 +53,10 @@ s32 txgbe_init_eeprom_params(struct txgbe_hw *hw)
 	err = eeprom->read32(hw, TXGBE_SW_REGION_PTR << 1, &eeprom->sw_addr);
 	if (err) {
-		DEBUGOUT("EEPROM read failed.\n");
+		DEBUGOUT("EEPROM read failed.");
 		return err;
 	}
 
-	DEBUGOUT("eeprom params: type = %d, size = %d, address bits: "
-		  "%d %d\n", eeprom->type, eeprom->word_size,
+	DEBUGOUT("eeprom params: type = %d, size = %d, address bits: %d %d",
+		  eeprom->type, eeprom->word_size,
 		  eeprom->address_bits, eeprom->sw_addr);
 
@@ -79,7 +77,4 @@ s32 txgbe_get_eeprom_semaphore(struct txgbe_hw *hw)
 	u32 swsm;
 
-	DEBUGFUNC("txgbe_get_eeprom_semaphore");
-
-
 	/* Get SMBI software semaphore between device drivers first */
 	for (i = 0; i < timeout; i++) {
@@ -97,6 +92,5 @@ s32 txgbe_get_eeprom_semaphore(struct txgbe_hw *hw)
 
 	if (i == timeout) {
-		DEBUGOUT("Driver can't access the eeprom - SMBI Semaphore "
-			 "not granted.\n");
+		DEBUGOUT("Driver can't access the eeprom - SMBI Semaphore not granted.");
 		/*
 		 * this release is particularly important because our attempts
@@ -141,11 +135,10 @@ s32 txgbe_get_eeprom_semaphore(struct txgbe_hw *hw)
 		 */
 		if (i >= timeout) {
-			DEBUGOUT("SWESMBI Software EEPROM semaphore not granted.\n");
+			DEBUGOUT("SWESMBI Software EEPROM semaphore not granted.");
 			txgbe_release_eeprom_semaphore(hw);
 			status = TXGBE_ERR_EEPROM;
 		}
 	} else {
-		DEBUGOUT("Software semaphore SMBI between device drivers "
-			 "not granted.\n");
+		DEBUGOUT("Software semaphore SMBI between device drivers not granted.");
 	}
 
@@ -161,6 +154,4 @@ s32 txgbe_get_eeprom_semaphore(struct txgbe_hw *hw)
 void txgbe_release_eeprom_semaphore(struct txgbe_hw *hw)
 {
-	DEBUGFUNC("txgbe_release_eeprom_semaphore");
-
 	wr32m(hw, TXGBE_MNGSWSYNC, TXGBE_MNGSWSYNC_REQ, 0);
 	wr32m(hw, TXGBE_SWSEM, TXGBE_SWSEM_PF, 0);
@@ -291,6 +282,4 @@ s32 txgbe_ee_write16(struct txgbe_hw *hw, u32 offset,
 	int err;
 
-	DEBUGFUNC("\n");
-
 	err = hw->mac.acquire_swfw_sync(hw, mask);
 	if (err)
@@ -349,6 +338,4 @@ s32 txgbe_ee_writew_sw(struct txgbe_hw *hw, u32 offset,
 	int err;
 
-	DEBUGFUNC("\n");
-
 	err = hw->mac.acquire_swfw_sync(hw, mask);
 	if (err)
@@ -400,9 +387,7 @@ s32 txgbe_calc_eeprom_checksum(struct txgbe_hw *hw)
 	u16 buffer[BUFF_SIZE];
 
-	DEBUGFUNC("txgbe_calc_eeprom_checksum");
-
 	err = hw->rom.readw_sw(hw, TXGBE_EEPROM_CHECKSUM, &read_checksum);
 	if (err) {
-		DEBUGOUT("EEPROM read failed\n");
+		DEBUGOUT("EEPROM read failed");
 		return err;
 	}
@@ -438,6 +423,4 @@ s32 txgbe_validate_eeprom_checksum(struct txgbe_hw *hw,
 	int err;
 
-	DEBUGFUNC("txgbe_validate_eeprom_checksum");
-
 	/* Read the first word from the EEPROM. If this times out or fails, do
 	 * not continue or we could be in for a very long wait while every
@@ -446,5 +429,5 @@ s32 txgbe_validate_eeprom_checksum(struct txgbe_hw *hw,
 	err = hw->rom.read16(hw, 0, &checksum);
 	if (err) {
-		DEBUGOUT("EEPROM read failed\n");
+		DEBUGOUT("EEPROM read failed");
 		return err;
 	}
@@ -458,5 +441,5 @@ s32 txgbe_validate_eeprom_checksum(struct txgbe_hw *hw,
 	err = hw->rom.readw_sw(hw, TXGBE_EEPROM_CHECKSUM, &read_checksum);
 	if (err) {
-		DEBUGOUT("EEPROM read failed\n");
+		DEBUGOUT("EEPROM read failed");
 		return err;
 	}
@@ -467,5 +450,5 @@ s32 txgbe_validate_eeprom_checksum(struct txgbe_hw *hw,
 	if (read_checksum != checksum) {
 		err = TXGBE_ERR_EEPROM_CHECKSUM;
-		DEBUGOUT("EEPROM checksum error\n");
+		DEBUGOUT("EEPROM checksum error");
 	}
 
@@ -486,6 +469,4 @@ s32 txgbe_update_eeprom_checksum(struct txgbe_hw *hw)
 	u16 checksum;
 
-	DEBUGFUNC("txgbe_update_eeprom_checksum");
-
 	/* Read the first word from the EEPROM. If this times out or fails, do
 	 * not continue or we could be in for a very long wait while every
@@ -494,5 +475,5 @@ s32 txgbe_update_eeprom_checksum(struct txgbe_hw *hw)
 	status = hw->rom.read16(hw, 0, &checksum);
 	if (status) {
-		DEBUGOUT("EEPROM read failed\n");
+		DEBUGOUT("EEPROM read failed");
 		return status;
 	}
diff --git a/drivers/net/txgbe/base/txgbe_hw.c b/drivers/net/txgbe/base/txgbe_hw.c
index 00a8db78bf..776891ee7e 100644
--- a/drivers/net/txgbe/base/txgbe_hw.c
+++ b/drivers/net/txgbe/base/txgbe_hw.c
@@ -43,6 +43,4 @@ bool txgbe_device_supports_autoneg_fc(struct txgbe_hw *hw)
 	bool link_up;
 
-	DEBUGFUNC("txgbe_device_supports_autoneg_fc");
-
 	switch (hw->phy.media_type) {
 	case txgbe_media_type_fiber_qsfp:
@@ -94,9 +92,7 @@ s32 txgbe_setup_fc(struct txgbe_hw *hw)
 	u64 reg_bp = 0;
 
-	DEBUGFUNC("txgbe_setup_fc");
-
 	/* Validate the requested mode */
 	if (hw->fc.strict_ieee && hw->fc.requested_mode == txgbe_fc_rx_pause) {
-		DEBUGOUT("txgbe_fc_rx_pause not valid in strict IEEE mode\n");
+		DEBUGOUT("txgbe_fc_rx_pause not valid in strict IEEE mode");
 		err = TXGBE_ERR_INVALID_LINK_SETTINGS;
 		goto out;
@@ -150,5 +146,5 @@ s32 txgbe_setup_fc(struct txgbe_hw *hw)
 		break;
 	default:
-		DEBUGOUT("Flow control param set incorrectly\n");
+		DEBUGOUT("Flow control param set incorrectly");
 		err = TXGBE_ERR_CONFIG;
 		goto out;
@@ -181,5 +177,5 @@ s32 txgbe_setup_fc(struct txgbe_hw *hw)
 	}
 
-	DEBUGOUT("Set up FC; reg = 0x%08X\n", reg);
+	DEBUGOUT("Set up FC; reg = 0x%08X", reg);
 out:
 	return err;
@@ -200,6 +196,4 @@ s32 txgbe_start_hw(struct txgbe_hw *hw)
 	u16 device_caps;
 
-	DEBUGFUNC("txgbe_start_hw");
-
 	/* Set the media type */
 	hw->phy.media_type = hw->phy.get_media_type(hw);
@@ -214,5 +208,5 @@ s32 txgbe_start_hw(struct txgbe_hw *hw)
 	err = txgbe_setup_fc(hw);
 	if (err != 0 && err != TXGBE_NOT_IMPLEMENTED) {
-		DEBUGOUT("Flow control setup failed, returning %d\n", err);
+		DEBUGOUT("Flow control setup failed, returning %d", err);
 		return err;
 	}
@@ -276,6 +270,4 @@ s32 txgbe_init_hw(struct txgbe_hw *hw)
 	s32 status;
 
-	DEBUGFUNC("txgbe_init_hw");
-
 	/* Get firmware version */
 	hw->phy.get_fw_version(hw, &hw->fw_version);
@@ -289,5 +281,5 @@ s32 txgbe_init_hw(struct txgbe_hw *hw)
 
 	if (status != 0)
-		DEBUGOUT("Failed to initialize HW, STATUS = %d\n", status);
+		DEBUGOUT("Failed to initialize HW, STATUS = %d", status);
 
 	return status;
@@ -305,6 +297,4 @@ s32 txgbe_clear_hw_cntrs(struct txgbe_hw *hw)
 	u16 i = 0;
 
-	DEBUGFUNC("txgbe_clear_hw_cntrs");
-
 	/* QP Stats */
 	/* don't write clear queue stats */
@@ -426,6 +416,4 @@ s32 txgbe_get_mac_addr(struct txgbe_hw *hw, u8 *mac_addr)
 	u16 i;
 
-	DEBUGFUNC("txgbe_get_mac_addr");
-
 	wr32(hw, TXGBE_ETHADDRIDX, 0);
 	rar_high = rd32(hw, TXGBE_ETHADDRH);
@@ -453,6 +441,4 @@ void txgbe_set_lan_id_multi_port(struct txgbe_hw *hw)
 	u32 reg;
 
-	DEBUGFUNC("txgbe_set_lan_id_multi_port_pcie");
-
 	reg = rd32(hw, TXGBE_PORTSTAT);
 	bus->lan_id = TXGBE_PORTSTAT_ID(reg);
@@ -480,6 +466,4 @@ s32 txgbe_stop_hw(struct txgbe_hw *hw)
 	u16 i;
 
-	DEBUGFUNC("txgbe_stop_hw");
-
 	/*
 	 * Set the adapter_stopped flag so other driver functions stop touching
@@ -528,6 +512,4 @@ s32 txgbe_led_on(struct txgbe_hw *hw, u32 index)
 	u32 led_reg = rd32(hw, TXGBE_LEDCTL);
 
-	DEBUGFUNC("txgbe_led_on");
-
 	if (index > 4)
 		return TXGBE_ERR_PARAM;
@@ -551,6 +533,4 @@ s32 txgbe_led_off(struct txgbe_hw *hw, u32 index)
 	u32 led_reg = rd32(hw, TXGBE_LEDCTL);
 
-	DEBUGFUNC("txgbe_led_off");
-
 	if (index > 4)
 		return TXGBE_ERR_PARAM;
@@ -575,6 +555,4 @@ s32 txgbe_validate_mac_addr(u8 *mac_addr)
 	s32 status = 0;
 
-	DEBUGFUNC("txgbe_validate_mac_addr");
-
 	/* Make sure it is not a multicast address */
 	if (TXGBE_IS_MULTICAST(mac_addr)) {
@@ -607,9 +585,7 @@ s32 txgbe_set_rar(struct txgbe_hw *hw, u32 index, u8 *addr, u32 vmdq,
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("txgbe_set_rar");
-
 	/* Make sure we are using a valid rar index range */
 	if (index >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", index);
+		DEBUGOUT("RAR index %d is out of range.", index);
 		return TXGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -659,9 +635,7 @@ s32 txgbe_clear_rar(struct txgbe_hw *hw, u32 index)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("txgbe_clear_rar");
-
 	/* Make sure we are using a valid rar index range */
 	if (index >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", index);
+		DEBUGOUT("RAR index %d is out of range.", index);
 		return TXGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -699,6 +673,4 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("txgbe_init_rx_addrs");
-
 	/*
 	 * If the current mac address is valid, assume it is a software override
@@ -711,16 +683,16 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
 		hw->mac.get_mac_addr(hw, hw->mac.addr);
 
-		DEBUGOUT(" Keeping Current RAR0 Addr =%.2X %.2X %.2X ",
+		DEBUGOUT(" Keeping Current RAR0 Addr = "
+			  RTE_ETHER_ADDR_PRT_FMT,
 			  hw->mac.addr[0], hw->mac.addr[1],
-			  hw->mac.addr[2]);
-		DEBUGOUT("%.2X %.2X %.2X\n", hw->mac.addr[3],
+			  hw->mac.addr[2], hw->mac.addr[3],
 			  hw->mac.addr[4], hw->mac.addr[5]);
 	} else {
 		/* Setup the receive address. */
-		DEBUGOUT("Overriding MAC Address in RAR[0]\n");
-		DEBUGOUT(" New MAC Addr =%.2X %.2X %.2X ",
+		DEBUGOUT("Overriding MAC Address in RAR[0]");
+		DEBUGOUT(" New MAC Addr = "
+			  RTE_ETHER_ADDR_PRT_FMT,
 			  hw->mac.addr[0], hw->mac.addr[1],
-			  hw->mac.addr[2]);
-		DEBUGOUT("%.2X %.2X %.2X\n", hw->mac.addr[3],
+			  hw->mac.addr[2], hw->mac.addr[3],
 			  hw->mac.addr[4], hw->mac.addr[5]);
 
@@ -736,5 +708,5 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
 
 	/* Zero out the other receive addresses. */
-	DEBUGOUT("Clearing RAR[1-%d]\n", rar_entries - 1);
+	DEBUGOUT("Clearing RAR[1-%d]", rar_entries - 1);
 	for (i = 1; i < rar_entries; i++) {
 		wr32(hw, TXGBE_ETHADDRIDX, i);
@@ -750,5 +722,5 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
 	wr32(hw, TXGBE_PSRCTL, psrctl);
 
-	DEBUGOUT(" Clearing MTA\n");
+	DEBUGOUT(" Clearing MTA");
 	for (i = 0; i < hw->mac.mcft_size; i++)
 		wr32(hw, TXGBE_MCADDRTBL(i), 0);
@@ -775,6 +747,4 @@ static s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
 	u32 vector = 0;
 
-	DEBUGFUNC("txgbe_mta_vector");
-
 	switch (hw->mac.mc_filter_type) {
 	case 0:   /* use bits [47:36] of the address */
@@ -791,5 +761,5 @@ static s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
 		break;
 	default:  /* Invalid mc_filter_type */
-		DEBUGOUT("MC filter type param set incorrectly\n");
+		DEBUGOUT("MC filter type param set incorrectly");
 		ASSERT(0);
 		break;
@@ -814,10 +784,8 @@ void txgbe_set_mta(struct txgbe_hw *hw, u8 *mc_addr)
 	u32 vector_reg;
 
-	DEBUGFUNC("txgbe_set_mta");
-
 	hw->addr_ctrl.mta_in_use++;
 
 	vector = txgbe_mta_vector(hw, mc_addr);
-	DEBUGOUT(" bit-vector = 0x%03X\n", vector);
+	DEBUGOUT(" bit-vector = 0x%03X", vector);
 
 	/*
@@ -853,6 +821,4 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
 	u32 vmdq;
 
-	DEBUGFUNC("txgbe_update_mc_addr_list");
-
 	/*
 	 * Set the new number of MC addresses that we are being requested to
@@ -864,5 +830,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
 	/* Clear mta_shadow */
 	if (clear) {
-		DEBUGOUT(" Clearing MTA\n");
+		DEBUGOUT(" Clearing MTA");
 		memset(&hw->mac.mta_shadow, 0, sizeof(hw->mac.mta_shadow));
 	}
@@ -870,5 +836,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
 	/* Update mta_shadow */
 	for (i = 0; i < mc_addr_count; i++) {
-		DEBUGOUT(" Adding the multicast addresses:\n");
+		DEBUGOUT(" Adding the multicast addresses:");
 		txgbe_set_mta(hw, next(hw, &mc_addr_list, &vmdq));
 	}
@@ -887,5 +853,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
 	}
 
-	DEBUGOUT("txgbe update mc addr list complete\n");
+	DEBUGOUT("txgbe update mc addr list complete");
 	return 0;
 }
@@ -905,6 +871,4 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
 	int i;
 
-	DEBUGFUNC("txgbe_fc_enable");
-
 	/* Validate the water mark configuration */
 	if (!hw->fc.pause_time) {
@@ -919,5 +883,5 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
 			if (!hw->fc.low_water[i] ||
 			    hw->fc.low_water[i] >= hw->fc.high_water[i]) {
-				DEBUGOUT("Invalid water mark configuration\n");
+				DEBUGOUT("Invalid water mark configuration");
 				err = TXGBE_ERR_INVALID_LINK_SETTINGS;
 				goto out;
@@ -977,5 +941,5 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
 		break;
 	default:
-		DEBUGOUT("Flow control param set incorrectly\n");
+		DEBUGOUT("Flow control param set incorrectly");
 		err = TXGBE_ERR_CONFIG;
 		goto out;
@@ -1038,6 +1002,5 @@ s32 txgbe_negotiate_fc(struct txgbe_hw *hw, u32 adv_reg, u32 lp_reg,
 {
 	if ((!(adv_reg)) ||  (!(lp_reg))) {
-		DEBUGOUT("Local or link partner's advertised flow control "
-			      "settings are NULL. Local: %x, link partner: %x\n",
+		DEBUGOUT("Local or link partner's advertised flow control settings are NULL. Local: %x, link partner: %x",
 			      adv_reg, lp_reg);
 		return TXGBE_ERR_FC_NOT_NEGOTIATED;
@@ -1054,20 +1017,20 @@ s32 txgbe_negotiate_fc(struct txgbe_hw *hw, u32 adv_reg, u32 lp_reg,
 		if (hw->fc.requested_mode == txgbe_fc_full) {
 			hw->fc.current_mode = txgbe_fc_full;
-			DEBUGOUT("Flow Control = FULL.\n");
+			DEBUGOUT("Flow Control = FULL.");
 		} else {
 			hw->fc.current_mode = txgbe_fc_rx_pause;
-			DEBUGOUT("Flow Control=RX PAUSE frames only\n");
+			DEBUGOUT("Flow Control=RX PAUSE frames only");
 		}
 	} else if (!(adv_reg & adv_sym) && (adv_reg & adv_asm) &&
 		   (lp_reg & lp_sym) && (lp_reg & lp_asm)) {
 		hw->fc.current_mode = txgbe_fc_tx_pause;
-		DEBUGOUT("Flow Control = TX PAUSE frames only.\n");
+		DEBUGOUT("Flow Control = TX PAUSE frames only.");
 	} else if ((adv_reg & adv_sym) && (adv_reg & adv_asm) &&
 		   !(lp_reg & lp_sym) && (lp_reg & lp_asm)) {
 		hw->fc.current_mode = txgbe_fc_rx_pause;
-		DEBUGOUT("Flow Control = RX PAUSE frames only.\n");
+		DEBUGOUT("Flow Control = RX PAUSE frames only.");
 	} else {
 		hw->fc.current_mode = txgbe_fc_none;
-		DEBUGOUT("Flow Control = NONE.\n");
+		DEBUGOUT("Flow Control = NONE.");
 	}
 	return 0;
@@ -1169,6 +1132,4 @@ void txgbe_fc_autoneg(struct txgbe_hw *hw)
 	bool link_up;
 
-	DEBUGFUNC("txgbe_fc_autoneg");
-
 	/*
 	 * AN should have completed when the cable was plugged in.
@@ -1236,6 +1197,4 @@ s32 txgbe_acquire_swfw_sync(struct txgbe_hw *hw, u32 mask)
 	u32 i;
 
-	DEBUGFUNC("txgbe_acquire_swfw_sync");
-
 	for (i = 0; i < timeout; i++) {
 		/*
@@ -1280,6 +1239,4 @@ void txgbe_release_swfw_sync(struct txgbe_hw *hw, u32 mask)
 	u32 swmask = mask;
 
-	DEBUGFUNC("txgbe_release_swfw_sync");
-
 	txgbe_get_eeprom_semaphore(hw);
 
@@ -1305,6 +1262,4 @@ s32 txgbe_disable_sec_rx_path(struct txgbe_hw *hw)
 	u32 secrxreg;
 
-	DEBUGFUNC("txgbe_disable_sec_rx_path");
-
 	secrxreg = rd32(hw, TXGBE_SECRXCTL);
 	secrxreg |= TXGBE_SECRXCTL_XDSA;
@@ -1321,6 +1276,5 @@ s32 txgbe_disable_sec_rx_path(struct txgbe_hw *hw)
 	/* For informational purposes only */
 	if (i >= TXGBE_MAX_SECRX_POLL)
-		DEBUGOUT("Rx unit being enabled before security "
-			 "path fully disabled.  Continuing with init.\n");
+		DEBUGOUT("Rx unit being enabled before security path fully disabled.  Continuing with init.");
 
 	return 0;
@@ -1337,6 +1291,4 @@ s32 txgbe_enable_sec_rx_path(struct txgbe_hw *hw)
 	u32 secrxreg;
 
-	DEBUGFUNC("txgbe_enable_sec_rx_path");
-
 	secrxreg = rd32(hw, TXGBE_SECRXCTL);
 	secrxreg &= ~TXGBE_SECRXCTL_XDSA;
@@ -1374,6 +1326,5 @@ int txgbe_disable_sec_tx_path(struct txgbe_hw *hw)
 	/* For informational purposes only */
 	if (i >= TXGBE_MAX_SECTX_POLL)
-		PMD_DRV_LOG(DEBUG, "Tx unit being enabled before security "
-			 "path fully disabled.  Continuing with init.");
+		DEBUGOUT("Tx unit being enabled before security path fully disabled.  Continuing with init.");
 
 	return 0;
@@ -1412,6 +1363,4 @@ static s32 txgbe_get_san_mac_addr_offset(struct txgbe_hw *hw,
 	s32 err;
 
-	DEBUGFUNC("txgbe_get_san_mac_addr_offset");
-
 	/*
 	 * First read the EEPROM pointer to see if the MAC addresses are
@@ -1444,6 +1393,4 @@ s32 txgbe_get_san_mac_addr(struct txgbe_hw *hw, u8 *san_mac_addr)
 	s32 err;
 
-	DEBUGFUNC("txgbe_get_san_mac_addr");
-
 	/*
 	 * First read the EEPROM pointer to see if the MAC addresses are
@@ -1494,6 +1441,4 @@ s32 txgbe_set_san_mac_addr(struct txgbe_hw *hw, u8 *san_mac_addr)
 	u8 i;
 
-	DEBUGFUNC("txgbe_set_san_mac_addr");
-
 	/* Look for SAN mac address pointer.  If not defined, return */
 	err = txgbe_get_san_mac_addr_offset(hw, &san_mac_offset);
@@ -1526,9 +1471,7 @@ s32 txgbe_clear_vmdq(struct txgbe_hw *hw, u32 rar, u32 vmdq)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("txgbe_clear_vmdq");
-
 	/* Make sure we are using a valid rar index range */
 	if (rar >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", rar);
+		DEBUGOUT("RAR index %d is out of range.", rar);
 		return TXGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -1580,9 +1523,7 @@ s32 txgbe_set_vmdq(struct txgbe_hw *hw, u32 rar, u32 vmdq)
 	u32 rar_entries = hw->mac.num_rar_entries;
 
-	DEBUGFUNC("txgbe_set_vmdq");
-
 	/* Make sure we are using a valid rar index range */
 	if (rar >= rar_entries) {
-		DEBUGOUT("RAR index %d is out of range.\n", rar);
+		DEBUGOUT("RAR index %d is out of range.", rar);
 		return TXGBE_ERR_INVALID_ARGUMENT;
 	}
@@ -1609,6 +1550,5 @@ s32 txgbe_init_uta_tables(struct txgbe_hw *hw)
 	int i;
 
-	DEBUGFUNC("txgbe_init_uta_tables");
-	DEBUGOUT(" Clearing UTA\n");
+	DEBUGOUT(" Clearing UTA");
 
 	for (i = 0; i < 128; i++)
@@ -1665,5 +1605,5 @@ s32 txgbe_find_vlvf_slot(struct txgbe_hw *hw, u32 vlan, bool vlvf_bypass)
 	 */
 	if (!first_empty_slot)
-		DEBUGOUT("No space in VLVF.\n");
+		DEBUGOUT("No space in VLVF.");
 
 	return first_empty_slot ? first_empty_slot : TXGBE_ERR_NO_SPACE;
@@ -1686,6 +1626,4 @@ s32 txgbe_set_vfta(struct txgbe_hw *hw, u32 vlan, u32 vind,
 	s32 err;
 
-	DEBUGFUNC("txgbe_set_vfta");
-
 	if (vlan > 4095 || vind > 63)
 		return TXGBE_ERR_PARAM;
@@ -1755,6 +1693,4 @@ s32 txgbe_set_vlvf(struct txgbe_hw *hw, u32 vlan, u32 vind,
 	s32 vlvf_index;
 
-	DEBUGFUNC("txgbe_set_vlvf");
-
 	if (vlan > 4095 || vind > 63)
 		return TXGBE_ERR_PARAM;
@@ -1836,6 +1772,4 @@ s32 txgbe_clear_vfta(struct txgbe_hw *hw)
 	u32 offset;
 
-	DEBUGFUNC("txgbe_clear_vfta");
-
 	for (offset = 0; offset < hw->mac.vft_size; offset++)
 		wr32(hw, TXGBE_VLANTBL(offset), 0);
@@ -1891,6 +1825,4 @@ s32 txgbe_check_mac_link(struct txgbe_hw *hw, u32 *speed,
 	u32 i;
 
-	DEBUGFUNC("txgbe_check_mac_link");
-
 	/* If Crosstalk fix enabled do the sanity check of making sure
 	 * the SFP+ cage is full.
@@ -1923,5 +1855,5 @@ s32 txgbe_check_mac_link(struct txgbe_hw *hw, u32 *speed,
 
 	if (links_orig != links_reg) {
-		DEBUGOUT("LINKS changed from %08X to %08X\n",
+		DEBUGOUT("LINKS changed from %08X to %08X",
 			  links_orig, links_reg);
 	}
@@ -1978,6 +1910,4 @@ s32 txgbe_get_wwn_prefix(struct txgbe_hw *hw, u16 *wwnn_prefix,
 	u16 alt_san_mac_blk_offset;
 
-	DEBUGFUNC("txgbe_get_wwn_prefix");
-
 	/* clear output first */
 	*wwnn_prefix = 0xFFFF;
@@ -2069,6 +1999,4 @@ void txgbe_set_ethertype_anti_spoofing(struct txgbe_hw *hw,
 s32 txgbe_get_device_caps(struct txgbe_hw *hw, u16 *device_caps)
 {
-	DEBUGFUNC("txgbe_get_device_caps");
-
 	hw->rom.readw_sw(hw, TXGBE_DEVICE_CAPS, device_caps);
 
@@ -2192,6 +2120,4 @@ s32 txgbe_get_thermal_sensor_data(struct txgbe_hw *hw)
 	u32 ts_stat;
 
-	DEBUGFUNC("txgbe_get_thermal_sensor_data");
-
 	/* Only support thermal sensors attached to physical port 0 */
 	if (hw->bus.lan_id != 0)
@@ -2224,6 +2150,4 @@ s32 txgbe_init_thermal_sensor_thresh(struct txgbe_hw *hw)
 	struct txgbe_thermal_sensor_data *data = &hw->mac.thermal_sensor_data;
 
-	DEBUGFUNC("txgbe_init_thermal_sensor_thresh");
-
 	memset(data, 0, sizeof(struct txgbe_thermal_sensor_data));
 
@@ -2296,6 +2220,4 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
 	bool autoneg, link_up = false;
 
-	DEBUGFUNC("txgbe_setup_mac_link_multispeed_fiber");
-
 	/* Mask off requested but non-supported speeds */
 	status = hw->mac.get_link_capabilities(hw, &link_speed, &autoneg);
@@ -2322,5 +2244,5 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
 			break;
 		default:
-			DEBUGOUT("Unexpected media type.\n");
+			DEBUGOUT("Unexpected media type.");
 			break;
 		}
@@ -2372,5 +2294,5 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
 			break;
 		default:
-			DEBUGOUT("Unexpected media type.\n");
+			DEBUGOUT("Unexpected media type.");
 			break;
 		}
@@ -2438,6 +2360,4 @@ s32 txgbe_init_shared_code(struct txgbe_hw *hw)
 	s32 status;
 
-	DEBUGFUNC("txgbe_init_shared_code");
-
 	/*
 	 * Set the mac type
@@ -2475,6 +2395,4 @@ s32 txgbe_set_mac_type(struct txgbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("txgbe_set_mac_type");
-
 	if (hw->vendor_id != PCI_VENDOR_ID_WANGXUN) {
 		DEBUGOUT("Unsupported vendor id: %x", hw->vendor_id);
@@ -2498,5 +2416,5 @@ s32 txgbe_set_mac_type(struct txgbe_hw *hw)
 	}
 
-	DEBUGOUT("found mac: %d, returns: %d\n",
+	DEBUGOUT("found mac: %d, returns: %d",
 		  hw->mac.type, err);
 	return err;
@@ -2507,6 +2425,4 @@ void txgbe_init_mac_link_ops(struct txgbe_hw *hw)
 	struct txgbe_mac_info *mac = &hw->mac;
 
-	DEBUGFUNC("txgbe_init_mac_link_ops");
-
 	/*
 	 * enable the laser control functions for SFP+ fiber
@@ -2551,6 +2467,4 @@ s32 txgbe_init_phy_raptor(struct txgbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("txgbe_init_phy_raptor");
-
 	if ((hw->device_id & 0xFF) == TXGBE_DEV_ID_QSFP) {
 		/* Store flag indicating I2C bus access control unit. */
@@ -2599,6 +2513,4 @@ s32 txgbe_setup_sfp_modules(struct txgbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("txgbe_setup_sfp_modules");
-
 	if (hw->phy.sfp_type == txgbe_sfp_type_unknown)
 		return 0;
@@ -2620,5 +2532,5 @@ s32 txgbe_setup_sfp_modules(struct txgbe_hw *hw)
 
 	if (err) {
-		DEBUGOUT("sfp module setup not complete\n");
+		DEBUGOUT("sfp module setup not complete");
 		return TXGBE_ERR_SFP_SETUP_NOT_COMPLETE;
 	}
@@ -2718,6 +2630,4 @@ s32 txgbe_init_ops_pf(struct txgbe_hw *hw)
 	struct txgbe_mbx_info *mbx = &hw->mbx;
 
-	DEBUGFUNC("txgbe_init_ops_pf");
-
 	/* BUS */
 	bus->set_lan_id = txgbe_set_lan_id_multi_port;
@@ -2846,6 +2756,4 @@ s32 txgbe_get_link_capabilities_raptor(struct txgbe_hw *hw,
 	u32 autoc = 0;
 
-	DEBUGFUNC("txgbe_get_link_capabilities_raptor");
-
 	/* Check if 1G SFP module. */
 	if (hw->phy.sfp_type == txgbe_sfp_type_1g_cu_core0 ||
@@ -2951,6 +2859,4 @@ u32 txgbe_get_media_type_raptor(struct txgbe_hw *hw)
 	u32 media_type;
 
-	DEBUGFUNC("txgbe_get_media_type_raptor");
-
 	if (hw->phy.ffe_set)
 		txgbe_bp_mode_set(hw);
@@ -3011,6 +2917,4 @@ s32 txgbe_start_mac_link_raptor(struct txgbe_hw *hw,
 	bool got_lock = false;
 
-	DEBUGFUNC("txgbe_start_mac_link_raptor");
-
 	UNREFERENCED_PARAMETER(autoneg_wait_to_complete);
 
@@ -3095,6 +2999,4 @@ void txgbe_enable_tx_laser_multispeed_fiber(struct txgbe_hw *hw)
 void txgbe_flap_tx_laser_multispeed_fiber(struct txgbe_hw *hw)
 {
-	DEBUGFUNC("txgbe_flap_tx_laser_multispeed_fiber");
-
 	/* Blocked by MNG FW so bail */
 	if (txgbe_check_reset_blocked(hw))
@@ -3128,5 +3030,5 @@ void txgbe_set_hard_rate_select_speed(struct txgbe_hw *hw,
 		break;
 	default:
-		DEBUGOUT("Invalid fixed module speed\n");
+		DEBUGOUT("Invalid fixed module speed");
 		return;
 	}
@@ -3154,6 +3056,4 @@ s32 txgbe_setup_mac_link_smartspeed(struct txgbe_hw *hw,
 	u32 autoc_reg = rd32_epcs(hw, SR_AN_MMD_ADV_REG1);
 
-	DEBUGFUNC("txgbe_setup_mac_link_smartspeed");
-
 	 /* Set autoneg_advertised value based on input link speed */
 	hw->phy.autoneg_advertised = 0;
@@ -3244,6 +3144,5 @@ s32 txgbe_setup_mac_link_smartspeed(struct txgbe_hw *hw,
 out:
 	if (link_up && link_speed == TXGBE_LINK_SPEED_1GB_FULL)
-		DEBUGOUT("Smartspeed has downgraded the link speed "
-		"from the maximum advertised\n");
+		DEBUGOUT("Smartspeed has downgraded the link speed from the maximum advertised");
 	return status;
 }
@@ -3271,5 +3170,4 @@ s32 txgbe_setup_mac_link(struct txgbe_hw *hw,
 	u32 link_capabilities = TXGBE_LINK_SPEED_UNKNOWN;
 
-	DEBUGFUNC("txgbe_setup_mac_link");
 	UNREFERENCED_PARAMETER(autoneg_wait_to_complete);
 
@@ -3358,6 +3256,4 @@ static s32 txgbe_setup_copper_link_raptor(struct txgbe_hw *hw,
 	s32 status;
 
-	DEBUGFUNC("txgbe_setup_copper_link_raptor");
-
 	/* Setup the PHY according to input speed */
 	status = hw->phy.setup_link_speed(hw, speed,
@@ -3468,6 +3364,4 @@ s32 txgbe_reset_hw(struct txgbe_hw *hw)
 	u32 autoc;
 
-	DEBUGFUNC("txgbe_reset_hw");
-
 	/* Call adapter stop to disable tx/rx and clear interrupts */
 	status = hw->mac.stop_hw(hw);
@@ -3625,6 +3519,4 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
 	fdirctrl &= ~TXGBE_FDIRCTL_INITDONE;
 
-	DEBUGFUNC("txgbe_reinit_fdir_tables");
-
 	/*
 	 * Before starting reinitialization process,
@@ -3633,5 +3525,5 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
 	err = txgbe_fdir_check_cmd_complete(hw, &fdircmd);
 	if (err) {
-		DEBUGOUT("Flow Director previous command did not complete, aborting table re-initialization.\n");
+		DEBUGOUT("Flow Director previous command did not complete, aborting table re-initialization.");
 		return err;
 	}
@@ -3667,5 +3559,5 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
 	}
 	if (i >= TXGBE_FDIR_INIT_DONE_POLL) {
-		DEBUGOUT("Flow Director Signature poll time exceeded!\n");
+		DEBUGOUT("Flow Director Signature poll time exceeded!");
 		return TXGBE_ERR_FDIR_REINIT_FAILED;
 	}
@@ -3693,6 +3585,4 @@ s32 txgbe_start_hw_raptor(struct txgbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("txgbe_start_hw_raptor");
-
 	err = txgbe_start_hw(hw);
 	if (err != 0)
@@ -3719,6 +3609,4 @@ out:
 s32 txgbe_enable_rx_dma_raptor(struct txgbe_hw *hw, u32 regval)
 {
-	DEBUGFUNC("txgbe_enable_rx_dma_raptor");
-
 	/*
 	 * Workaround silicon errata when enabling the Rx datapath.
@@ -3753,6 +3641,4 @@ bool txgbe_verify_lesm_fw_enabled_raptor(struct txgbe_hw *hw)
 	s32 status;
 
-	DEBUGFUNC("txgbe_verify_lesm_fw_enabled_raptor");
-
 	/* get the offset to the Firmware Module block */
 	status = hw->rom.read16(hw, TXGBE_FW_PTR, &fw_offset);
diff --git a/drivers/net/txgbe/base/txgbe_mbx.c b/drivers/net/txgbe/base/txgbe_mbx.c
index 4d64c6c3e9..7f2489a13f 100644
--- a/drivers/net/txgbe/base/txgbe_mbx.c
+++ b/drivers/net/txgbe/base/txgbe_mbx.c
@@ -22,6 +22,4 @@ s32 txgbe_read_mbx(struct txgbe_hw *hw, u32 *msg, u16 size, u16 mbx_id)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_read_mbx");
-
 	/* limit read to size of mailbox */
 	if (size > mbx->size)
@@ -48,6 +46,4 @@ s32 txgbe_write_mbx(struct txgbe_hw *hw, u32 *msg, u16 size, u16 mbx_id)
 	s32 ret_val = 0;
 
-	DEBUGFUNC("txgbe_write_mbx");
-
 	if (size > mbx->size) {
 		ret_val = TXGBE_ERR_MBX;
@@ -72,6 +68,4 @@ s32 txgbe_check_for_msg(struct txgbe_hw *hw, u16 mbx_id)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_check_for_msg");
-
 	if (mbx->check_for_msg)
 		ret_val = mbx->check_for_msg(hw, mbx_id);
@@ -92,6 +86,4 @@ s32 txgbe_check_for_ack(struct txgbe_hw *hw, u16 mbx_id)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_check_for_ack");
-
 	if (mbx->check_for_ack)
 		ret_val = mbx->check_for_ack(hw, mbx_id);
@@ -112,6 +104,4 @@ s32 txgbe_check_for_rst(struct txgbe_hw *hw, u16 mbx_id)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_check_for_rst");
-
 	if (mbx->check_for_rst)
 		ret_val = mbx->check_for_rst(hw, mbx_id);
@@ -132,6 +122,4 @@ STATIC s32 txgbe_poll_for_msg(struct txgbe_hw *hw, u16 mbx_id)
 	int countdown = mbx->timeout;
 
-	DEBUGFUNC("txgbe_poll_for_msg");
-
 	if (!countdown || !mbx->check_for_msg)
 		goto out;
@@ -163,6 +151,4 @@ STATIC s32 txgbe_poll_for_ack(struct txgbe_hw *hw, u16 mbx_id)
 	int countdown = mbx->timeout;
 
-	DEBUGFUNC("txgbe_poll_for_ack");
-
 	if (!countdown || !mbx->check_for_ack)
 		goto out;
@@ -197,6 +183,4 @@ s32 txgbe_read_posted_mbx(struct txgbe_hw *hw, u32 *msg, u16 size, u16 mbx_id)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_read_posted_mbx");
-
 	if (!mbx->read)
 		goto out;
@@ -227,6 +211,4 @@ s32 txgbe_write_posted_mbx(struct txgbe_hw *hw, u32 *msg, u16 size,
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_write_posted_mbx");
-
 	/* exit if either we can't write or there isn't a defined timeout */
 	if (!mbx->write || !mbx->timeout)
@@ -293,5 +275,4 @@ s32 txgbe_check_for_msg_vf(struct txgbe_hw *hw, u16 mbx_id)
 
 	UNREFERENCED_PARAMETER(mbx_id);
-	DEBUGFUNC("txgbe_check_for_msg_vf");
 
 	if (!txgbe_check_for_bit_vf(hw, TXGBE_VFMBCTL_PFSTS)) {
@@ -315,5 +296,4 @@ s32 txgbe_check_for_ack_vf(struct txgbe_hw *hw, u16 mbx_id)
 
 	UNREFERENCED_PARAMETER(mbx_id);
-	DEBUGFUNC("txgbe_check_for_ack_vf");
 
 	if (!txgbe_check_for_bit_vf(hw, TXGBE_VFMBCTL_PFACK)) {
@@ -337,5 +317,4 @@ s32 txgbe_check_for_rst_vf(struct txgbe_hw *hw, u16 mbx_id)
 
 	UNREFERENCED_PARAMETER(mbx_id);
-	DEBUGFUNC("txgbe_check_for_rst_vf");
 
 	if (!txgbe_check_for_bit_vf(hw, (TXGBE_VFMBCTL_RSTD |
@@ -358,6 +337,4 @@ STATIC s32 txgbe_obtain_mbx_lock_vf(struct txgbe_hw *hw)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_obtain_mbx_lock_vf");
-
 	/* Take ownership of the buffer */
 	wr32(hw, TXGBE_VFMBCTL, TXGBE_VFMBCTL_VFU);
@@ -387,6 +364,4 @@ s32 txgbe_write_mbx_vf(struct txgbe_hw *hw, u32 *msg, u16 size,
 	UNREFERENCED_PARAMETER(mbx_id);
 
-	DEBUGFUNC("txgbe_write_mbx_vf");
-
 	/* lock the mailbox to prevent pf/vf race condition */
 	ret_val = txgbe_obtain_mbx_lock_vf(hw);
@@ -427,5 +402,4 @@ s32 txgbe_read_mbx_vf(struct txgbe_hw *hw, u32 *msg, u16 size,
 	u16 i;
 
-	DEBUGFUNC("txgbe_read_mbx_vf");
 	UNREFERENCED_PARAMETER(mbx_id);
 
@@ -500,6 +474,4 @@ s32 txgbe_check_for_msg_pf(struct txgbe_hw *hw, u16 vf_number)
 	u32 vf_bit = vf_number % 16;
 
-	DEBUGFUNC("txgbe_check_for_msg_pf");
-
 	if (!txgbe_check_for_bit_pf(hw, TXGBE_MBVFICR_VFREQ_VF1 << vf_bit,
 				    index)) {
@@ -524,6 +496,4 @@ s32 txgbe_check_for_ack_pf(struct txgbe_hw *hw, u16 vf_number)
 	u32 vf_bit = vf_number % 16;
 
-	DEBUGFUNC("txgbe_check_for_ack_pf");
-
 	if (!txgbe_check_for_bit_pf(hw, TXGBE_MBVFICR_VFACK_VF1 << vf_bit,
 				    index)) {
@@ -549,6 +519,4 @@ s32 txgbe_check_for_rst_pf(struct txgbe_hw *hw, u16 vf_number)
 	s32 ret_val = TXGBE_ERR_MBX;
 
-	DEBUGFUNC("txgbe_check_for_rst_pf");
-
 	vflre = rd32(hw, TXGBE_FLRVFE(reg_offset));
 	if (vflre & (1 << vf_shift)) {
@@ -573,6 +541,4 @@ STATIC s32 txgbe_obtain_mbx_lock_pf(struct txgbe_hw *hw, u16 vf_number)
 	u32 p2v_mailbox;
 
-	DEBUGFUNC("txgbe_obtain_mbx_lock_pf");
-
 	/* Take ownership of the buffer */
 	wr32(hw, TXGBE_MBCTL(vf_number), TXGBE_MBCTL_PFU);
@@ -603,6 +569,4 @@ s32 txgbe_write_mbx_pf(struct txgbe_hw *hw, u32 *msg, u16 size, u16 vf_number)
 	u16 i;
 
-	DEBUGFUNC("txgbe_write_mbx_pf");
-
 	/* lock the mailbox to prevent pf/vf race condition */
 	ret_val = txgbe_obtain_mbx_lock_pf(hw, vf_number);
@@ -644,6 +608,4 @@ s32 txgbe_read_mbx_pf(struct txgbe_hw *hw, u32 *msg, u16 size, u16 vf_number)
 	u16 i;
 
-	DEBUGFUNC("txgbe_read_mbx_pf");
-
 	/* lock the mailbox to prevent pf/vf race condition */
 	ret_val = txgbe_obtain_mbx_lock_pf(hw, vf_number);
diff --git a/drivers/net/txgbe/base/txgbe_mng.c b/drivers/net/txgbe/base/txgbe_mng.c
index dbe512122c..045a2f5de0 100644
--- a/drivers/net/txgbe/base/txgbe_mng.c
+++ b/drivers/net/txgbe/base/txgbe_mng.c
@@ -46,8 +46,6 @@ txgbe_hic_unlocked(struct txgbe_hw *hw, u32 *buffer, u32 length, u32 timeout)
 	u16 i, dword_len;
 
-	DEBUGFUNC("txgbe_hic_unlocked");
-
 	if (!length || length > TXGBE_PMMBX_BSIZE) {
-		DEBUGOUT("Buffer length failure buffersize=%d.\n", length);
+		DEBUGOUT("Buffer length failure buffersize=%d.", length);
 		return TXGBE_ERR_HOST_INTERFACE_COMMAND;
 	}
@@ -79,5 +77,5 @@ txgbe_hic_unlocked(struct txgbe_hw *hw, u32 *buffer, u32 length, u32 timeout)
 		&value, timeout, 1000);
 	if (!loop || !(value & TXGBE_MNGMBXCTL_FWACK)) {
-		DEBUGOUT("Command has failed with no status valid.\n");
+		DEBUGOUT("Command has failed with no status valid.");
 		return TXGBE_ERR_HOST_INTERFACE_COMMAND;
 	}
@@ -115,8 +113,6 @@ txgbe_host_interface_command(struct txgbe_hw *hw, u32 *buffer,
 	u32 dword_len;
 
-	DEBUGFUNC("txgbe_host_interface_command");
-
 	if (length == 0 || length > TXGBE_PMMBX_BSIZE) {
-		DEBUGOUT("Buffer length failure buffersize=%d.\n", length);
+		DEBUGOUT("Buffer length failure buffersize=%d.", length);
 		return TXGBE_ERR_HOST_INTERFACE_COMMAND;
 	}
@@ -160,5 +156,5 @@ txgbe_host_interface_command(struct txgbe_hw *hw, u32 *buffer,
 
 	if (length < buf_len + hdr_size) {
-		DEBUGOUT("Buffer not large enough for reply message.\n");
+		DEBUGOUT("Buffer not large enough for reply message.");
 		err = TXGBE_ERR_HOST_INTERFACE_COMMAND;
 		goto rel_out;
@@ -286,5 +282,4 @@ s32 txgbe_hic_set_drv_ver(struct txgbe_hw *hw, u8 maj, u8 min,
 	s32 ret_val = 0;
 
-	DEBUGFUNC("txgbe_hic_set_drv_ver");
 	UNREFERENCED_PARAMETER(len, driver_ver);
 
@@ -339,6 +334,4 @@ txgbe_hic_reset(struct txgbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("\n");
-
 	reset_cmd.hdr.cmd = FW_RESET_CMD;
 	reset_cmd.hdr.buf_len = FW_RESET_LEN;
diff --git a/drivers/net/txgbe/base/txgbe_osdep.h b/drivers/net/txgbe/base/txgbe_osdep.h
index 11fcf7e8fe..b62c0b0824 100644
--- a/drivers/net/txgbe/base/txgbe_osdep.h
+++ b/drivers/net/txgbe/base/txgbe_osdep.h
@@ -19,4 +19,5 @@
 #include <rte_config.h>
 #include <rte_io.h>
+#include <rte_ether.h>
 
 #include "../txgbe_logs.h"
diff --git a/drivers/net/txgbe/base/txgbe_phy.c b/drivers/net/txgbe/base/txgbe_phy.c
index 3fb929f37a..da2bbc43e0 100644
--- a/drivers/net/txgbe/base/txgbe_phy.c
+++ b/drivers/net/txgbe/base/txgbe_phy.c
@@ -36,5 +36,5 @@ static bool txgbe_identify_extphy(struct txgbe_hw *hw)
 
 	if (!txgbe_validate_phy_addr(hw, phy_addr)) {
-		DEBUGOUT("Unable to validate PHY address 0x%04X\n",
+		DEBUGOUT("Unable to validate PHY address 0x%04X",
 			phy_addr);
 		return false;
@@ -101,6 +101,4 @@ s32 txgbe_identify_phy(struct txgbe_hw *hw)
 	s32 err = TXGBE_ERR_PHY_ADDR_INVALID;
 
-	DEBUGFUNC("txgbe_identify_phy");
-
 	txgbe_read_phy_if(hw);
 
@@ -138,9 +136,7 @@ s32 txgbe_check_reset_blocked(struct txgbe_hw *hw)
 	u32 mmngc;
 
-	DEBUGFUNC("txgbe_check_reset_blocked");
-
 	mmngc = rd32(hw, TXGBE_STAT);
 	if (mmngc & TXGBE_STAT_MNGVETO) {
-		DEBUGOUT("MNG_VETO bit detected.\n");
+		DEBUGOUT("MNG_VETO bit detected.");
 		return true;
 	}
@@ -160,6 +156,4 @@ bool txgbe_validate_phy_addr(struct txgbe_hw *hw, u32 phy_addr)
 	bool valid = false;
 
-	DEBUGFUNC("txgbe_validate_phy_addr");
-
 	hw->phy.addr = phy_addr;
 	hw->phy.read_reg(hw, TXGBE_MD_PHY_ID_HIGH,
@@ -169,5 +163,5 @@ bool txgbe_validate_phy_addr(struct txgbe_hw *hw, u32 phy_addr)
 		valid = true;
 
-	DEBUGOUT("PHY ID HIGH is 0x%04X\n", phy_id);
+	DEBUGOUT("PHY ID HIGH is 0x%04X", phy_id);
 
 	return valid;
@@ -185,6 +179,4 @@ s32 txgbe_get_phy_id(struct txgbe_hw *hw)
 	u16 phy_id_low = 0;
 
-	DEBUGFUNC("txgbe_get_phy_id");
-
 	err = hw->phy.read_reg(hw, TXGBE_MD_PHY_ID_HIGH,
 				      TXGBE_MD_DEV_PMA_PMD,
@@ -199,5 +191,5 @@ s32 txgbe_get_phy_id(struct txgbe_hw *hw)
 		hw->phy.revision = (u32)(phy_id_low & ~TXGBE_PHY_REVISION_MASK);
 	}
-	DEBUGOUT("PHY_ID_HIGH 0x%04X, PHY_ID_LOW 0x%04X\n",
+	DEBUGOUT("PHY_ID_HIGH 0x%04X, PHY_ID_LOW 0x%04X",
 		  phy_id_high, phy_id_low);
 
@@ -214,6 +206,4 @@ enum txgbe_phy_type txgbe_get_phy_type_from_id(u32 phy_id)
 	enum txgbe_phy_type phy_type;
 
-	DEBUGFUNC("txgbe_get_phy_type_from_id");
-
 	switch (phy_id) {
 	case TXGBE_PHYID_TN1010:
@@ -273,5 +263,5 @@ txgbe_reset_extphy(struct txgbe_hw *hw)
 	if (ctrl & TXGBE_MD_PORT_CTRL_RESET) {
 		err = TXGBE_ERR_RESET_FAILED;
-		DEBUGOUT("PHY reset polling failed to complete.\n");
+		DEBUGOUT("PHY reset polling failed to complete.");
 	}
 
@@ -287,6 +277,4 @@ s32 txgbe_reset_phy(struct txgbe_hw *hw)
 	s32 err = 0;
 
-	DEBUGFUNC("txgbe_reset_phy");
-
 	if (hw->phy.type == txgbe_phy_unknown)
 		err = txgbe_identify_phy(hw);
@@ -344,5 +332,5 @@ s32 txgbe_read_phy_reg_mdi(struct txgbe_hw *hw, u32 reg_addr, u32 device_type,
 	if (!po32m(hw, TXGBE_MDIOSCD, TXGBE_MDIOSCD_BUSY,
 		0, NULL, 100, 100)) {
-		DEBUGOUT("PHY address command did not complete\n");
+		DEBUGOUT("PHY address command did not complete");
 		return TXGBE_ERR_PHY;
 	}
@@ -368,6 +356,4 @@ s32 txgbe_read_phy_reg(struct txgbe_hw *hw, u32 reg_addr,
 	u32 gssr = hw->phy.phy_semaphore_mask;
 
-	DEBUGFUNC("txgbe_read_phy_reg");
-
 	if (hw->mac.acquire_swfw_sync(hw, gssr))
 		return TXGBE_ERR_SWFW_SYNC;
@@ -407,5 +393,5 @@ s32 txgbe_write_phy_reg_mdi(struct txgbe_hw *hw, u32 reg_addr,
 	if (!po32m(hw, TXGBE_MDIOSCD, TXGBE_MDIOSCD_BUSY,
 		0, NULL, 100, 100)) {
-		TLOG_DEBUG("PHY write cmd didn't complete\n");
+		DEBUGOUT("PHY write cmd didn't complete");
 		return -TERR_PHY;
 	}
@@ -428,6 +414,4 @@ s32 txgbe_write_phy_reg(struct txgbe_hw *hw, u32 reg_addr,
 	u32 gssr = hw->phy.phy_semaphore_mask;
 
-	DEBUGFUNC("txgbe_write_phy_reg");
-
 	if (hw->mac.acquire_swfw_sync(hw, gssr))
 		err = TXGBE_ERR_SWFW_SYNC;
@@ -453,6 +437,4 @@ s32 txgbe_setup_phy_link(struct txgbe_hw *hw)
 	u32 speed;
 
-	DEBUGFUNC("txgbe_setup_phy_link");
-
 	txgbe_get_copper_link_capabilities(hw, &speed, &autoneg);
 
@@ -540,6 +522,4 @@ s32 txgbe_setup_phy_link_speed(struct txgbe_hw *hw,
 	UNREFERENCED_PARAMETER(autoneg_wait_to_complete);
 
-	DEBUGFUNC("txgbe_setup_phy_link_speed");
-
 	/*
 	 * Clear autoneg_advertised and set new values based on input link
@@ -624,6 +604,4 @@ s32 txgbe_get_copper_link_capabilities(struct txgbe_hw *hw,
 	s32 err = 0;
 
-	DEBUGFUNC("txgbe_get_copper_link_capabilities");
-
 	*autoneg = true;
 	if (!hw->phy.speeds_supported)
@@ -653,6 +631,4 @@ s32 txgbe_check_phy_link_tnx(struct txgbe_hw *hw, u32 *speed,
 	u16 phy_data = 0;
 
-	DEBUGFUNC("txgbe_check_phy_link_tnx");
-
 	/* Initialize speed and link to default case */
 	*link_up = false;
@@ -698,6 +674,4 @@ s32 txgbe_setup_phy_link_tnx(struct txgbe_hw *hw)
 	u32 speed;
 
-	DEBUGFUNC("txgbe_setup_phy_link_tnx");
-
 	txgbe_get_copper_link_capabilities(hw, &speed, &autoneg);
 
@@ -773,6 +747,4 @@ s32 txgbe_identify_module(struct txgbe_hw *hw)
 	s32 err = TXGBE_ERR_SFP_NOT_PRESENT;
 
-	DEBUGFUNC("txgbe_identify_module");
-
 	switch (hw->phy.media_type) {
 	case txgbe_media_type_fiber:
@@ -812,6 +784,4 @@ s32 txgbe_identify_sfp_module(struct txgbe_hw *hw)
 	u16 enforce_sfp = 0;
 
-	DEBUGFUNC("txgbe_identify_sfp_module");
-
 	if (hw->phy.media_type != txgbe_media_type_fiber) {
 		hw->phy.sfp_type = txgbe_sfp_type_not_present;
@@ -993,5 +963,5 @@ ERR_I2C:
 	      hw->phy.sfp_type == txgbe_sfp_type_1g_sx_core0 ||
 	      hw->phy.sfp_type == txgbe_sfp_type_1g_sx_core1)) {
-		DEBUGOUT("SFP+ module not supported\n");
+		DEBUGOUT("SFP+ module not supported");
 		hw->phy.type = txgbe_phy_sfp_unsupported;
 		return TXGBE_ERR_SFP_NOT_SUPPORTED;
@@ -1022,6 +992,4 @@ s32 txgbe_identify_qsfp_module(struct txgbe_hw *hw)
 	bool active_cable = false;
 
-	DEBUGFUNC("txgbe_identify_qsfp_module");
-
 	if (hw->phy.media_type != txgbe_media_type_fiber_qsfp) {
 		hw->phy.sfp_type = txgbe_sfp_type_not_present;
@@ -1166,8 +1134,8 @@ ERR_I2C:
 					DEBUGOUT("WARNING: Wangxun (R) Network Connections are quality tested using Wangxun (R) Ethernet Optics. "
 						"Using untested modules is not supported and may cause unstable operation or damage to the module or the adapter. "
-						"Wangxun Corporation is not responsible for any harm caused by using untested modules.\n");
+						"Wangxun Corporation is not responsible for any harm caused by using untested modules.");
 					err = 0;
 				} else {
-					DEBUGOUT("QSFP module not supported\n");
+					DEBUGOUT("QSFP module not supported");
 					hw->phy.type =
 						txgbe_phy_sfp_unsupported;
@@ -1195,6 +1163,4 @@ s32 txgbe_read_i2c_eeprom(struct txgbe_hw *hw, u8 byte_offset,
 				  u8 *eeprom_data)
 {
-	DEBUGFUNC("txgbe_read_i2c_eeprom");
-
 	return hw->phy.read_i2c_byte(hw, byte_offset,
 					 TXGBE_I2C_EEPROM_DEV_ADDR,
@@ -1229,6 +1195,4 @@ s32 txgbe_write_i2c_eeprom(struct txgbe_hw *hw, u8 byte_offset,
 				   u8 eeprom_data)
 {
-	DEBUGFUNC("txgbe_write_i2c_eeprom");
-
 	return hw->phy.write_i2c_byte(hw, byte_offset,
 					  TXGBE_I2C_EEPROM_DEV_ADDR,
@@ -1249,6 +1213,4 @@ s32 txgbe_read_i2c_byte_unlocked(struct txgbe_hw *hw, u8 byte_offset,
 					   u8 dev_addr, u8 *data)
 {
-	DEBUGFUNC("txgbe_read_i2c_byte");
-
 	txgbe_i2c_start(hw, dev_addr);
 
@@ -1313,6 +1275,4 @@ s32 txgbe_write_i2c_byte_unlocked(struct txgbe_hw *hw, u8 byte_offset,
 					    u8 dev_addr, u8 data)
 {
-	DEBUGFUNC("txgbe_write_i2c_byte");
-
 	txgbe_i2c_start(hw, dev_addr);
 
@@ -1368,6 +1328,4 @@ s32 txgbe_write_i2c_byte(struct txgbe_hw *hw, u8 byte_offset,
 static void txgbe_i2c_start(struct txgbe_hw *hw, u8 dev_addr)
 {
-	DEBUGFUNC("txgbe_i2c_start");
-
 	wr32(hw, TXGBE_I2CENA, 0);
 
@@ -1397,10 +1355,8 @@ static void txgbe_i2c_start(struct txgbe_hw *hw, u8 dev_addr)
 static void txgbe_i2c_stop(struct txgbe_hw *hw)
 {
-	DEBUGFUNC("txgbe_i2c_stop");
-
 	/* wait for completion */
 	if (!po32m(hw, TXGBE_I2CSTAT, TXGBE_I2CSTAT_MST,
 		0, NULL, 100, 100)) {
-		DEBUGFUNC("i2c stop timeout.");
+		DEBUGOUT("i2c stop timeout.");
 	}
 
@@ -2421,6 +2377,4 @@ s32 txgbe_kr_handle(struct txgbe_hw *hw)
 	s32 status = 0;
 
-	DEBUGFUNC("txgbe_kr_handle");
-
 	value = rd32_epcs(hw, VR_AN_INTR);
 	BP_LOG("AN INTERRUPT!! value: 0x%x\n", value);
@@ -2446,6 +2400,4 @@ static s32 txgbe_handle_bp_flow(u32 link_mode, struct txgbe_hw *hw)
 	struct txgbe_backplane_ability local_ability, lp_ability;
 
-	DEBUGFUNC("txgbe_handle_bp_flow");
-
 	local_ability.current_link_mode = link_mode;
 
@@ -2549,6 +2501,4 @@ static void txgbe_get_bp_ability(struct txgbe_backplane_ability *ability,
 	u32 value = 0;
 
-	DEBUGFUNC("txgbe_get_bp_ability");
-
 	/* Link Partner Base Page */
 	if (link_partner == 1) {
@@ -2622,6 +2572,4 @@ static s32 txgbe_check_bp_ability(struct txgbe_backplane_ability *local_ability,
 	s32 ret = 0;
 
-	DEBUGFUNC("txgbe_check_bp_ability");
-
 	com_link_abi = local_ability->link_ability & lp_ability->link_ability;
 	BP_LOG("com_link_abi = 0x%x, local_ability = 0x%x, lp_ability = 0x%x\n",
@@ -2679,6 +2627,4 @@ static void txgbe_clear_bp_intr(u32 bit, u32 bit_high, struct txgbe_hw *hw)
 	u32 rdata = 0, wdata, i;
 
-	DEBUGFUNC("txgbe_clear_bp_intr");
-
 	rdata = rd32_epcs(hw, VR_AN_INTR);
 	BP_LOG("[Before clear]Read VR AN MMD Interrupt Register: 0x%x\n",
@@ -2705,6 +2651,4 @@ static s32 txgbe_enable_kr_training(struct txgbe_hw *hw)
 	u32 value = 0;
 
-	DEBUGFUNC("txgbe_enable_kr_training");
-
 	BP_LOG("Enable Clause 72 KR Training ...\n");
 
@@ -2750,6 +2694,4 @@ static s32 txgbe_disable_kr_training(struct txgbe_hw *hw, s32 post, s32 mode)
 	s32 status = 0;
 
-	DEBUGFUNC("txgbe_disable_kr_training");
-
 	BP_LOG("Disable Clause 72 KR Training ...\n");
 	/* Read PHY Lane0 TX EQ before Clause 72 KR Training. */
@@ -2768,6 +2710,4 @@ static s32 txgbe_check_kr_training(struct txgbe_hw *hw)
 	int times = hw->devarg.poll ? 35 : 20;
 
-	DEBUGFUNC("txgbe_check_kr_training");
-
 	for (i = 0; i < times; i++) {
 		value = rd32_epcs(hw, SR_PMA_KR_LP_CEU);
@@ -2827,6 +2767,4 @@ static void txgbe_read_phy_lane_tx_eq(u16 lane, struct txgbe_hw *hw,
 	u32 tx_main_cursor, tx_pre_cursor, tx_post_cursor, lmain;
 
-	DEBUGFUNC("txgbe_read_phy_lane_tx_eq");
-
 	addr = TXGBE_PHY_LANE0_TX_EQ_CTL1 | (lane << 8);
 	value = rd32_ephy(hw, addr);
diff --git a/drivers/net/txgbe/base/txgbe_vf.c b/drivers/net/txgbe/base/txgbe_vf.c
index fb6d6d90ea..a73502351e 100644
--- a/drivers/net/txgbe/base/txgbe_vf.c
+++ b/drivers/net/txgbe/base/txgbe_vf.c
@@ -108,6 +108,4 @@ s32 txgbe_reset_hw_vf(struct txgbe_hw *hw)
 	u8 *addr = (u8 *)(&msgbuf[1]);
 
-	DEBUGFUNC("txgbevf_reset_hw_vf");
-
 	/* Call adapter stop to disable tx/rx and clear interrupts */
 	hw->mac.stop_hw(hw);
@@ -122,5 +120,5 @@ s32 txgbe_reset_hw_vf(struct txgbe_hw *hw)
 	msec_delay(10);
 
-	DEBUGOUT("Issuing a function level reset to MAC\n");
+	DEBUGOUT("Issuing a function level reset to MAC");
 	wr32(hw, TXGBE_VFRST, TXGBE_VFRST_SET);
 	txgbe_flush(hw);
@@ -239,5 +237,5 @@ STATIC s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
 		break;
 	default:  /* Invalid mc_filter_type */
-		DEBUGOUT("MC filter type param set incorrectly\n");
+		DEBUGOUT("MC filter type param set incorrectly");
 		ASSERT(0);
 		break;
@@ -317,6 +315,4 @@ s32 txgbe_update_mc_addr_list_vf(struct txgbe_hw *hw, u8 *mc_addr_list,
 	UNREFERENCED_PARAMETER(clear);
 
-	DEBUGFUNC("txgbe_update_mc_addr_list_vf");
-
 	/* Each entry in the list uses 1 16 bit word.  We have 30
 	 * 16 bit words available in our HW msg buffer (minus 1 for the
@@ -328,5 +324,5 @@ s32 txgbe_update_mc_addr_list_vf(struct txgbe_hw *hw, u8 *mc_addr_list,
 	 */
 
-	DEBUGOUT("MC Addr Count = %d\n", mc_addr_count);
+	DEBUGOUT("MC Addr Count = %d", mc_addr_count);
 
 	cnt = (mc_addr_count > 30) ? 30 : mc_addr_count;
@@ -336,5 +332,5 @@ s32 txgbe_update_mc_addr_list_vf(struct txgbe_hw *hw, u8 *mc_addr_list,
 	for (i = 0; i < cnt; i++) {
 		vector = txgbe_mta_vector(hw, next(hw, &mc_addr_list, &vmdq));
-		DEBUGOUT("Hash value = 0x%03X\n", vector);
+		DEBUGOUT("Hash value = 0x%03X", vector);
 		vector_list[i] = (u16)vector;
 	}
diff --git a/drivers/net/txgbe/txgbe_logs.h b/drivers/net/txgbe/txgbe_logs.h
index 67e9bfb3af..74f49ab9ef 100644
--- a/drivers/net/txgbe/txgbe_logs.h
+++ b/drivers/net/txgbe/txgbe_logs.h
@@ -49,9 +49,6 @@ extern int txgbe_logtype_tx_free;
 #endif
 
-#define TLOG_DEBUG(fmt, args...)  PMD_DRV_LOG(DEBUG, fmt, ##args)
-
-#define DEBUGOUT(fmt, args...)    TLOG_DEBUG(fmt, ##args)
-#define PMD_INIT_FUNC_TRACE()     TLOG_DEBUG(" >>")
-#define DEBUGFUNC(fmt)            TLOG_DEBUG(fmt)
+#define DEBUGOUT(fmt, args...)    PMD_DRV_LOG(DEBUG, fmt, ##args)
+#define PMD_INIT_FUNC_TRACE()     PMD_DRV_LOG(DEBUG, ">>")
 
 extern int txgbe_logtype_bp;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.356696731 +0000
+++ 0071-net-txgbe-fix-debug-logs.patch	2022-03-01 10:41:01.383244114 +0000
@@ -1 +1 @@
-From 75c85e39652ef2eb54dd07b8f3d6b42b3930e8fe Mon Sep 17 00:00:00 2001
+From 399b4893281c5d2bbf48e46f968cdf5476676d03 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 75c85e39652ef2eb54dd07b8f3d6b42b3930e8fe ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -18 +19 @@
- drivers/net/txgbe/base/txgbe_mng.c    |  21 +--
+ drivers/net/txgbe/base/txgbe_mng.c    |  15 +-
@@ -23 +24 @@
- 9 files changed, 79 insertions(+), 329 deletions(-)
+ 9 files changed, 78 insertions(+), 324 deletions(-)
@@ -166 +167 @@
-index db8ffe61a4..6a045cba79 100644
+index 00a8db78bf..776891ee7e 100644
@@ -262,3 +263,3 @@
- 	/* To turn on the LED, set mode to ON. */
- 	led_reg |= index << TXGBE_LEDCTL_ORD_SHIFT;
-@@ -548,6 +530,4 @@ s32 txgbe_led_off(struct txgbe_hw *hw, u32 index)
+ 	if (index > 4)
+ 		return TXGBE_ERR_PARAM;
+@@ -551,6 +533,4 @@ s32 txgbe_led_off(struct txgbe_hw *hw, u32 index)
@@ -269,3 +270,3 @@
- 	/* To turn off the LED, set mode to OFF. */
- 	led_reg &= ~(index << TXGBE_LEDCTL_ORD_SHIFT);
-@@ -569,6 +549,4 @@ s32 txgbe_validate_mac_addr(u8 *mac_addr)
+ 	if (index > 4)
+ 		return TXGBE_ERR_PARAM;
+@@ -575,6 +555,4 @@ s32 txgbe_validate_mac_addr(u8 *mac_addr)
@@ -278 +279 @@
-@@ -601,9 +579,7 @@ s32 txgbe_set_rar(struct txgbe_hw *hw, u32 index, u8 *addr, u32 vmdq,
+@@ -607,9 +585,7 @@ s32 txgbe_set_rar(struct txgbe_hw *hw, u32 index, u8 *addr, u32 vmdq,
@@ -289 +290 @@
-@@ -653,9 +629,7 @@ s32 txgbe_clear_rar(struct txgbe_hw *hw, u32 index)
+@@ -659,9 +635,7 @@ s32 txgbe_clear_rar(struct txgbe_hw *hw, u32 index)
@@ -300 +301 @@
-@@ -693,6 +667,4 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
+@@ -699,6 +673,4 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
@@ -307 +308 @@
-@@ -705,16 +677,16 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
+@@ -711,16 +683,16 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
@@ -331 +332 @@
-@@ -730,5 +702,5 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
+@@ -736,5 +708,5 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
@@ -338 +339 @@
-@@ -744,5 +716,5 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
+@@ -750,5 +722,5 @@ s32 txgbe_init_rx_addrs(struct txgbe_hw *hw)
@@ -345 +346 @@
-@@ -769,6 +741,4 @@ static s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
+@@ -775,6 +747,4 @@ static s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
@@ -352 +353 @@
-@@ -785,5 +755,5 @@ static s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
+@@ -791,5 +761,5 @@ static s32 txgbe_mta_vector(struct txgbe_hw *hw, u8 *mc_addr)
@@ -359 +360 @@
-@@ -808,10 +778,8 @@ void txgbe_set_mta(struct txgbe_hw *hw, u8 *mc_addr)
+@@ -814,10 +784,8 @@ void txgbe_set_mta(struct txgbe_hw *hw, u8 *mc_addr)
@@ -371 +372 @@
-@@ -847,6 +815,4 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
+@@ -853,6 +821,4 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
@@ -378 +379 @@
-@@ -858,5 +824,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
+@@ -864,5 +830,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
@@ -385 +386 @@
-@@ -864,5 +830,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
+@@ -870,5 +836,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
@@ -392 +393 @@
-@@ -881,5 +847,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
+@@ -887,5 +853,5 @@ s32 txgbe_update_mc_addr_list(struct txgbe_hw *hw, u8 *mc_addr_list,
@@ -399 +400 @@
-@@ -899,6 +865,4 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
+@@ -905,6 +871,4 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
@@ -406 +407 @@
-@@ -913,5 +877,5 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
+@@ -919,5 +883,5 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
@@ -413 +414 @@
-@@ -971,5 +935,5 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
+@@ -977,5 +941,5 @@ s32 txgbe_fc_enable(struct txgbe_hw *hw)
@@ -420 +421 @@
-@@ -1032,6 +996,5 @@ s32 txgbe_negotiate_fc(struct txgbe_hw *hw, u32 adv_reg, u32 lp_reg,
+@@ -1038,6 +1002,5 @@ s32 txgbe_negotiate_fc(struct txgbe_hw *hw, u32 adv_reg, u32 lp_reg,
@@ -428 +429 @@
-@@ -1048,20 +1011,20 @@ s32 txgbe_negotiate_fc(struct txgbe_hw *hw, u32 adv_reg, u32 lp_reg,
+@@ -1054,20 +1017,20 @@ s32 txgbe_negotiate_fc(struct txgbe_hw *hw, u32 adv_reg, u32 lp_reg,
@@ -454 +455 @@
-@@ -1163,6 +1126,4 @@ void txgbe_fc_autoneg(struct txgbe_hw *hw)
+@@ -1169,6 +1132,4 @@ void txgbe_fc_autoneg(struct txgbe_hw *hw)
@@ -461 +462 @@
-@@ -1230,6 +1191,4 @@ s32 txgbe_acquire_swfw_sync(struct txgbe_hw *hw, u32 mask)
+@@ -1236,6 +1197,4 @@ s32 txgbe_acquire_swfw_sync(struct txgbe_hw *hw, u32 mask)
@@ -468 +469 @@
-@@ -1274,6 +1233,4 @@ void txgbe_release_swfw_sync(struct txgbe_hw *hw, u32 mask)
+@@ -1280,6 +1239,4 @@ void txgbe_release_swfw_sync(struct txgbe_hw *hw, u32 mask)
@@ -475 +476 @@
-@@ -1299,6 +1256,4 @@ s32 txgbe_disable_sec_rx_path(struct txgbe_hw *hw)
+@@ -1305,6 +1262,4 @@ s32 txgbe_disable_sec_rx_path(struct txgbe_hw *hw)
@@ -482 +483 @@
-@@ -1315,6 +1270,5 @@ s32 txgbe_disable_sec_rx_path(struct txgbe_hw *hw)
+@@ -1321,6 +1276,5 @@ s32 txgbe_disable_sec_rx_path(struct txgbe_hw *hw)
@@ -490 +491 @@
-@@ -1331,6 +1285,4 @@ s32 txgbe_enable_sec_rx_path(struct txgbe_hw *hw)
+@@ -1337,6 +1291,4 @@ s32 txgbe_enable_sec_rx_path(struct txgbe_hw *hw)
@@ -497 +498 @@
-@@ -1368,6 +1320,5 @@ int txgbe_disable_sec_tx_path(struct txgbe_hw *hw)
+@@ -1374,6 +1326,5 @@ int txgbe_disable_sec_tx_path(struct txgbe_hw *hw)
@@ -505 +506 @@
-@@ -1406,6 +1357,4 @@ static s32 txgbe_get_san_mac_addr_offset(struct txgbe_hw *hw,
+@@ -1412,6 +1363,4 @@ static s32 txgbe_get_san_mac_addr_offset(struct txgbe_hw *hw,
@@ -512 +513 @@
-@@ -1438,6 +1387,4 @@ s32 txgbe_get_san_mac_addr(struct txgbe_hw *hw, u8 *san_mac_addr)
+@@ -1444,6 +1393,4 @@ s32 txgbe_get_san_mac_addr(struct txgbe_hw *hw, u8 *san_mac_addr)
@@ -519 +520 @@
-@@ -1488,6 +1435,4 @@ s32 txgbe_set_san_mac_addr(struct txgbe_hw *hw, u8 *san_mac_addr)
+@@ -1494,6 +1441,4 @@ s32 txgbe_set_san_mac_addr(struct txgbe_hw *hw, u8 *san_mac_addr)
@@ -526 +527 @@
-@@ -1520,9 +1465,7 @@ s32 txgbe_clear_vmdq(struct txgbe_hw *hw, u32 rar, u32 vmdq)
+@@ -1526,9 +1471,7 @@ s32 txgbe_clear_vmdq(struct txgbe_hw *hw, u32 rar, u32 vmdq)
@@ -537 +538 @@
-@@ -1574,9 +1517,7 @@ s32 txgbe_set_vmdq(struct txgbe_hw *hw, u32 rar, u32 vmdq)
+@@ -1580,9 +1523,7 @@ s32 txgbe_set_vmdq(struct txgbe_hw *hw, u32 rar, u32 vmdq)
@@ -548 +549 @@
-@@ -1603,6 +1544,5 @@ s32 txgbe_init_uta_tables(struct txgbe_hw *hw)
+@@ -1609,6 +1550,5 @@ s32 txgbe_init_uta_tables(struct txgbe_hw *hw)
@@ -556 +557 @@
-@@ -1659,5 +1599,5 @@ s32 txgbe_find_vlvf_slot(struct txgbe_hw *hw, u32 vlan, bool vlvf_bypass)
+@@ -1665,5 +1605,5 @@ s32 txgbe_find_vlvf_slot(struct txgbe_hw *hw, u32 vlan, bool vlvf_bypass)
@@ -563 +564 @@
-@@ -1680,6 +1620,4 @@ s32 txgbe_set_vfta(struct txgbe_hw *hw, u32 vlan, u32 vind,
+@@ -1686,6 +1626,4 @@ s32 txgbe_set_vfta(struct txgbe_hw *hw, u32 vlan, u32 vind,
@@ -570 +571 @@
-@@ -1749,6 +1687,4 @@ s32 txgbe_set_vlvf(struct txgbe_hw *hw, u32 vlan, u32 vind,
+@@ -1755,6 +1693,4 @@ s32 txgbe_set_vlvf(struct txgbe_hw *hw, u32 vlan, u32 vind,
@@ -577 +578 @@
-@@ -1830,6 +1766,4 @@ s32 txgbe_clear_vfta(struct txgbe_hw *hw)
+@@ -1836,6 +1772,4 @@ s32 txgbe_clear_vfta(struct txgbe_hw *hw)
@@ -584 +585 @@
-@@ -1885,6 +1819,4 @@ s32 txgbe_check_mac_link(struct txgbe_hw *hw, u32 *speed,
+@@ -1891,6 +1825,4 @@ s32 txgbe_check_mac_link(struct txgbe_hw *hw, u32 *speed,
@@ -591 +592 @@
-@@ -1917,5 +1849,5 @@ s32 txgbe_check_mac_link(struct txgbe_hw *hw, u32 *speed,
+@@ -1923,5 +1855,5 @@ s32 txgbe_check_mac_link(struct txgbe_hw *hw, u32 *speed,
@@ -598 +599 @@
-@@ -1972,6 +1904,4 @@ s32 txgbe_get_wwn_prefix(struct txgbe_hw *hw, u16 *wwnn_prefix,
+@@ -1978,6 +1910,4 @@ s32 txgbe_get_wwn_prefix(struct txgbe_hw *hw, u16 *wwnn_prefix,
@@ -605 +606 @@
-@@ -2063,6 +1993,4 @@ void txgbe_set_ethertype_anti_spoofing(struct txgbe_hw *hw,
+@@ -2069,6 +1999,4 @@ void txgbe_set_ethertype_anti_spoofing(struct txgbe_hw *hw,
@@ -612 +613 @@
-@@ -2186,6 +2114,4 @@ s32 txgbe_get_thermal_sensor_data(struct txgbe_hw *hw)
+@@ -2192,6 +2120,4 @@ s32 txgbe_get_thermal_sensor_data(struct txgbe_hw *hw)
@@ -619 +620 @@
-@@ -2218,6 +2144,4 @@ s32 txgbe_init_thermal_sensor_thresh(struct txgbe_hw *hw)
+@@ -2224,6 +2150,4 @@ s32 txgbe_init_thermal_sensor_thresh(struct txgbe_hw *hw)
@@ -626 +627 @@
-@@ -2290,6 +2214,4 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
+@@ -2296,6 +2220,4 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
@@ -633 +634 @@
-@@ -2316,5 +2238,5 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
+@@ -2322,5 +2244,5 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
@@ -640 +641 @@
-@@ -2366,5 +2288,5 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
+@@ -2372,5 +2294,5 @@ s32 txgbe_setup_mac_link_multispeed_fiber(struct txgbe_hw *hw,
@@ -647 +648 @@
-@@ -2432,6 +2354,4 @@ s32 txgbe_init_shared_code(struct txgbe_hw *hw)
+@@ -2438,6 +2360,4 @@ s32 txgbe_init_shared_code(struct txgbe_hw *hw)
@@ -654 +655 @@
-@@ -2469,6 +2389,4 @@ s32 txgbe_set_mac_type(struct txgbe_hw *hw)
+@@ -2475,6 +2395,4 @@ s32 txgbe_set_mac_type(struct txgbe_hw *hw)
@@ -661 +662 @@
-@@ -2492,5 +2410,5 @@ s32 txgbe_set_mac_type(struct txgbe_hw *hw)
+@@ -2498,5 +2416,5 @@ s32 txgbe_set_mac_type(struct txgbe_hw *hw)
@@ -668 +669 @@
-@@ -2501,6 +2419,4 @@ void txgbe_init_mac_link_ops(struct txgbe_hw *hw)
+@@ -2507,6 +2425,4 @@ void txgbe_init_mac_link_ops(struct txgbe_hw *hw)
@@ -675 +676 @@
-@@ -2545,6 +2461,4 @@ s32 txgbe_init_phy_raptor(struct txgbe_hw *hw)
+@@ -2551,6 +2467,4 @@ s32 txgbe_init_phy_raptor(struct txgbe_hw *hw)
@@ -682 +683 @@
-@@ -2593,6 +2507,4 @@ s32 txgbe_setup_sfp_modules(struct txgbe_hw *hw)
+@@ -2599,6 +2513,4 @@ s32 txgbe_setup_sfp_modules(struct txgbe_hw *hw)
@@ -689 +690 @@
-@@ -2614,5 +2526,5 @@ s32 txgbe_setup_sfp_modules(struct txgbe_hw *hw)
+@@ -2620,5 +2532,5 @@ s32 txgbe_setup_sfp_modules(struct txgbe_hw *hw)
@@ -696 +697 @@
-@@ -2712,6 +2624,4 @@ s32 txgbe_init_ops_pf(struct txgbe_hw *hw)
+@@ -2718,6 +2630,4 @@ s32 txgbe_init_ops_pf(struct txgbe_hw *hw)
@@ -703 +704 @@
-@@ -2840,6 +2750,4 @@ s32 txgbe_get_link_capabilities_raptor(struct txgbe_hw *hw,
+@@ -2846,6 +2756,4 @@ s32 txgbe_get_link_capabilities_raptor(struct txgbe_hw *hw,
@@ -710 +711 @@
-@@ -2945,6 +2853,4 @@ u32 txgbe_get_media_type_raptor(struct txgbe_hw *hw)
+@@ -2951,6 +2859,4 @@ u32 txgbe_get_media_type_raptor(struct txgbe_hw *hw)
@@ -717 +718 @@
-@@ -3005,6 +2911,4 @@ s32 txgbe_start_mac_link_raptor(struct txgbe_hw *hw,
+@@ -3011,6 +2917,4 @@ s32 txgbe_start_mac_link_raptor(struct txgbe_hw *hw,
@@ -724 +725 @@
-@@ -3096,6 +3000,4 @@ void txgbe_enable_tx_laser_multispeed_fiber(struct txgbe_hw *hw)
+@@ -3095,6 +2999,4 @@ void txgbe_enable_tx_laser_multispeed_fiber(struct txgbe_hw *hw)
@@ -731 +732 @@
-@@ -3129,5 +3031,5 @@ void txgbe_set_hard_rate_select_speed(struct txgbe_hw *hw,
+@@ -3128,5 +3030,5 @@ void txgbe_set_hard_rate_select_speed(struct txgbe_hw *hw,
@@ -738 +739 @@
-@@ -3155,6 +3057,4 @@ s32 txgbe_setup_mac_link_smartspeed(struct txgbe_hw *hw,
+@@ -3154,6 +3056,4 @@ s32 txgbe_setup_mac_link_smartspeed(struct txgbe_hw *hw,
@@ -745 +746 @@
-@@ -3245,6 +3145,5 @@ s32 txgbe_setup_mac_link_smartspeed(struct txgbe_hw *hw,
+@@ -3244,6 +3144,5 @@ s32 txgbe_setup_mac_link_smartspeed(struct txgbe_hw *hw,
@@ -753 +754 @@
-@@ -3272,5 +3171,4 @@ s32 txgbe_setup_mac_link(struct txgbe_hw *hw,
+@@ -3271,5 +3170,4 @@ s32 txgbe_setup_mac_link(struct txgbe_hw *hw,
@@ -759 +760 @@
-@@ -3359,6 +3257,4 @@ static s32 txgbe_setup_copper_link_raptor(struct txgbe_hw *hw,
+@@ -3358,6 +3256,4 @@ static s32 txgbe_setup_copper_link_raptor(struct txgbe_hw *hw,
@@ -766 +767 @@
-@@ -3469,6 +3365,4 @@ s32 txgbe_reset_hw(struct txgbe_hw *hw)
+@@ -3468,6 +3364,4 @@ s32 txgbe_reset_hw(struct txgbe_hw *hw)
@@ -773 +774 @@
-@@ -3626,6 +3520,4 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
+@@ -3625,6 +3519,4 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
@@ -780 +781 @@
-@@ -3634,5 +3526,5 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
+@@ -3633,5 +3525,5 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
@@ -787 +788 @@
-@@ -3668,5 +3560,5 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
+@@ -3667,5 +3559,5 @@ s32 txgbe_reinit_fdir_tables(struct txgbe_hw *hw)
@@ -794 +795 @@
-@@ -3694,6 +3586,4 @@ s32 txgbe_start_hw_raptor(struct txgbe_hw *hw)
+@@ -3693,6 +3585,4 @@ s32 txgbe_start_hw_raptor(struct txgbe_hw *hw)
@@ -801 +802 @@
-@@ -3720,6 +3610,4 @@ out:
+@@ -3719,6 +3609,4 @@ out:
@@ -808 +809 @@
-@@ -3754,6 +3642,4 @@ bool txgbe_verify_lesm_fw_enabled_raptor(struct txgbe_hw *hw)
+@@ -3753,6 +3641,4 @@ bool txgbe_verify_lesm_fw_enabled_raptor(struct txgbe_hw *hw)
@@ -963 +964 @@
-index d0aa665d4a..07bbfe8142 100644
+index dbe512122c..045a2f5de0 100644
@@ -976 +977 @@
-@@ -79,10 +77,10 @@ txgbe_hic_unlocked(struct txgbe_hw *hw, u32 *buffer, u32 length, u32 timeout)
+@@ -79,5 +77,5 @@ txgbe_hic_unlocked(struct txgbe_hw *hw, u32 *buffer, u32 length, u32 timeout)
@@ -983,7 +984 @@
- 
- 	if ((rd32(hw, TXGBE_MNGMBX) & 0xff0000) >> 16 == 0x80) {
--		DEBUGOUT("It's unknown command.\n");
-+		DEBUGOUT("It's unknown command.");
- 		return TXGBE_ERR_MNG_ACCESS_FAILED;
- 	}
-@@ -120,8 +118,6 @@ txgbe_host_interface_command(struct txgbe_hw *hw, u32 *buffer,
+@@ -115,8 +113,6 @@ txgbe_host_interface_command(struct txgbe_hw *hw, u32 *buffer,
@@ -999 +994 @@
-@@ -165,5 +161,5 @@ txgbe_host_interface_command(struct txgbe_hw *hw, u32 *buffer,
+@@ -160,5 +156,5 @@ txgbe_host_interface_command(struct txgbe_hw *hw, u32 *buffer,
@@ -1006,15 +1001 @@
-@@ -274,6 +270,4 @@ s32 txgbe_close_notify(struct txgbe_hw *hw)
- 	struct txgbe_hic_write_shadow_ram buffer;
- 
--	DEBUGFUNC("txgbe_close_notify");
--
- 	buffer.hdr.req.cmd = FW_DW_CLOSE_NOTIFY;
- 	buffer.hdr.req.buf_lenh = 0;
-@@ -306,6 +300,4 @@ s32 txgbe_open_notify(struct txgbe_hw *hw)
- 	struct txgbe_hic_write_shadow_ram buffer;
- 
--	DEBUGFUNC("txgbe_open_notify");
--
- 	buffer.hdr.req.cmd = FW_DW_OPEN_NOTIFY;
- 	buffer.hdr.req.buf_lenh = 0;
-@@ -355,5 +347,4 @@ s32 txgbe_hic_set_drv_ver(struct txgbe_hw *hw, u8 maj, u8 min,
+@@ -286,5 +282,4 @@ s32 txgbe_hic_set_drv_ver(struct txgbe_hw *hw, u8 maj, u8 min,
@@ -1026 +1007 @@
-@@ -408,6 +399,4 @@ txgbe_hic_reset(struct txgbe_hw *hw)
+@@ -339,6 +334,4 @@ txgbe_hic_reset(struct txgbe_hw *hw)


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

* patch 'net/ena: remove unused enumeration' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (69 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/txgbe: " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: remove unused offload variables' " Kevin Traynor
                   ` (31 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Krawczyk
  Cc: Artur Rojek, Dawid Gorecki, Igor Chauskin, Shai Brandes, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e63e5c79ce402b50515b604876be01f22d47ad96 Mon Sep 17 00:00:00 2001
From: Michal Krawczyk <mk@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:26 +0100
Subject: [PATCH] net/ena: remove unused enumeration

[ upstream commit 0f135d2fe2644182ce1ad92ab4f2311a50bfb267 ]

The enumeration seems to be leftover from porting the Linux driver to
the DPDK. It was used nowhere and refers to the ethtool which is not
present in the DPDK.

Fixes: 372c1af5ed8f ("net/ena: add dedicated memory area for extra device info")

Signed-off-by: Michal Krawczyk <mk@semihalf.com>
Reviewed-by: Artur Rojek <ar@semihalf.com>
Reviewed-by: Dawid Gorecki <dgr@semihalf.com>
Reviewed-by: Igor Chauskin <igorch@amazon.com>
Reviewed-by: Shai Brandes <shaibran@amazon.com>
---
 drivers/net/ena/ena_ethdev.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index dce26cfa48..100acde9c2 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -39,9 +39,4 @@
 #define ENA_PTYPE_HAS_HASH	(RTE_PTYPE_L4_TCP | RTE_PTYPE_L4_UDP)
 
-enum ethtool_stringset {
-	ETH_SS_TEST             = 0,
-	ETH_SS_STATS,
-};
-
 struct ena_stats {
 	char name[ETH_GSTRING_LEN];
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.392841306 +0000
+++ 0072-net-ena-remove-unused-enumeration.patch	2022-03-01 10:41:01.385244114 +0000
@@ -1 +1 @@
-From 0f135d2fe2644182ce1ad92ab4f2311a50bfb267 Mon Sep 17 00:00:00 2001
+From e63e5c79ce402b50515b604876be01f22d47ad96 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0f135d2fe2644182ce1ad92ab4f2311a50bfb267 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index 34fb43cb00..2de2dcf12f 100644
+index dce26cfa48..100acde9c2 100644


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

* patch 'net/ena: remove unused offload variables' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (70 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: remove unused enumeration' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: skip timer if reset is triggered' " Kevin Traynor
                   ` (30 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Krawczyk
  Cc: Artur Rojek, Dawid Gorecki, Igor Chauskin, Shai Brandes, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 4e9e9e29c4b45a9f919d0d00767cdd93907c0bae Mon Sep 17 00:00:00 2001
From: Michal Krawczyk <mk@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:27 +0100
Subject: [PATCH] net/ena: remove unused offload variables

[ upstream commit fa11980449c225a217bf6923e79924edf991cb27 ]

Those variables are being set, but never read. As they seem to be
leftover from the old offloads API and don't have any purpose right
now, they are simply being removed.

Fixes: a4996bd89c42 ("ethdev: new Rx/Tx offloads API")

Signed-off-by: Michal Krawczyk <mk@semihalf.com>
Reviewed-by: Artur Rojek <ar@semihalf.com>
Reviewed-by: Dawid Gorecki <dgr@semihalf.com>
Reviewed-by: Igor Chauskin <igorch@semihalf.com>
Reviewed-by: Shai Brandes <shaibran@amazon.com>
---
 drivers/net/ena/ena_ethdev.c | 3 ---
 drivers/net/ena/ena_ethdev.h | 5 -----
 2 files changed, 8 deletions(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index 100acde9c2..0b7699454b 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -2024,7 +2024,4 @@ static int ena_dev_configure(struct rte_eth_dev *dev)
 	adapter->tx_cleanup_stall_delay = adapter->missing_tx_completion_to / 2;
 
-	adapter->tx_selected_offloads = dev->data->dev_conf.txmode.offloads;
-	adapter->rx_selected_offloads = dev->data->dev_conf.rxmode.offloads;
-
 	return 0;
 }
diff --git a/drivers/net/ena/ena_ethdev.h b/drivers/net/ena/ena_ethdev.h
index f99e4f3984..0632f793d0 100644
--- a/drivers/net/ena/ena_ethdev.h
+++ b/drivers/net/ena/ena_ethdev.h
@@ -281,9 +281,4 @@ struct ena_adapter {
 	enum ena_adapter_state state;
 
-	uint64_t tx_supported_offloads;
-	uint64_t tx_selected_offloads;
-	uint64_t rx_supported_offloads;
-	uint64_t rx_selected_offloads;
-
 	bool link_status;
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.421439072 +0000
+++ 0073-net-ena-remove-unused-offload-variables.patch	2022-03-01 10:41:01.388244115 +0000
@@ -1 +1 @@
-From fa11980449c225a217bf6923e79924edf991cb27 Mon Sep 17 00:00:00 2001
+From 4e9e9e29c4b45a9f919d0d00767cdd93907c0bae Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit fa11980449c225a217bf6923e79924edf991cb27 ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -24 +25 @@
-index 2de2dcf12f..de5fdb8f1d 100644
+index 100acde9c2..0b7699454b 100644
@@ -27 +28 @@
-@@ -2016,7 +2016,4 @@ static int ena_dev_configure(struct rte_eth_dev *dev)
+@@ -2024,7 +2024,4 @@ static int ena_dev_configure(struct rte_eth_dev *dev)
@@ -36 +37 @@
-index f47ba3fb02..4dfa604d51 100644
+index f99e4f3984..0632f793d0 100644
@@ -39 +40 @@
-@@ -279,9 +279,4 @@ struct ena_adapter {
+@@ -281,9 +281,4 @@ struct ena_adapter {


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

* patch 'net/ena: skip timer if reset is triggered' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (71 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: remove unused offload variables' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: fix reset reason being overwritten' " Kevin Traynor
                   ` (29 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Krawczyk; +Cc: Shai Brandes, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From c443512e3de007f49b5d0a5313d73c20d5e13d3d Mon Sep 17 00:00:00 2001
From: Michal Krawczyk <mk@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:30 +0100
Subject: [PATCH] net/ena: skip timer if reset is triggered

[ upstream commit e2174a54469febb2905f06d5c942ff76c492c2ff ]

Some user applications may not support PMD reset handling. If they will
support timer service it could cause a situation, when information
about the reset trigger is being showed every time the timer service is
being called.

Timer service is now being skipped if the reset was already triggered.

Fixes: d9b8b106bf9d ("net/ena: add watchdog and keep alive AENQ handler")

Signed-off-by: Michal Krawczyk <mk@semihalf.com>
Reviewed-by: Shai Brandes <shaibran@amazon.com>
---
 drivers/net/ena/ena_ethdev.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index 0b7699454b..b3a9cccd40 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -1628,4 +1628,7 @@ static void ena_timer_wd_callback(__rte_unused struct rte_timer *timer,
 	struct ena_adapter *adapter = dev->data->dev_private;
 
+	if (unlikely(adapter->trigger_reset))
+		return;
+
 	check_for_missing_keep_alive(adapter);
 	check_for_admin_com_state(adapter);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.450899717 +0000
+++ 0074-net-ena-skip-timer-if-reset-is-triggered.patch	2022-03-01 10:41:01.390244115 +0000
@@ -1 +1 @@
-From e2174a54469febb2905f06d5c942ff76c492c2ff Mon Sep 17 00:00:00 2001
+From c443512e3de007f49b5d0a5313d73c20d5e13d3d Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit e2174a54469febb2905f06d5c942ff76c492c2ff ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -23 +24 @@
-index a2793f13cd..4b82372155 100644
+index 0b7699454b..b3a9cccd40 100644
@@ -26 +27 @@
-@@ -1625,4 +1625,7 @@ static void ena_timer_wd_callback(__rte_unused struct rte_timer *timer,
+@@ -1628,4 +1628,7 @@ static void ena_timer_wd_callback(__rte_unused struct rte_timer *timer,


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

* patch 'net/ena: fix reset reason being overwritten' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (72 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: skip timer if reset is triggered' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: fix meta descriptor DF flag setup' " Kevin Traynor
                   ` (28 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Dawid Gorecki; +Cc: Michal Krawczyk, Shai Brandes, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From caae58d539a2f97671b86c5f1e611d2557ed973a Mon Sep 17 00:00:00 2001
From: Dawid Gorecki <dgr@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:38 +0100
Subject: [PATCH] net/ena: fix reset reason being overwritten

[ upstream 2bae75eaa2e036020b726f61bc607a8f4142c3a8 ]

When triggering the reset, no check was performed to see if the reset
was already triggered. This could result in original reset reason being
overwritten. Add ena_trigger_reset helper function, which checks if the
reset was triggered and only sets the reset reason if the reset wasn't
triggered yet. Replace all occurrences of manually setting the reset
with ena_trigger_reset call.

Fixes: 2081d5e2e92d ("net/ena: add reset routine")
Cc: stable@dpdk.org

Signed-off-by: Dawid Gorecki <dgr@semihalf.com>
Reviewed-by: Michal Krawczyk <mk@semihalf.com>
Reviewed-by: Shai Brandes <shaibran@amazon.com>
---
 drivers/net/ena/ena_ethdev.c | 32 ++++++++++++++++++--------------
 1 file changed, 18 insertions(+), 14 deletions(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index b3a9cccd40..a3c073a95e 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -276,4 +276,13 @@ static const struct eth_dev_ops ena_dev_ops = {
 };
 
+static inline void ena_trigger_reset(struct ena_adapter *adapter,
+				     enum ena_regs_reset_reason_types reason)
+{
+	if (likely(!adapter->trigger_reset)) {
+		adapter->reset_reason = reason;
+		adapter->trigger_reset = true;
+	}
+}
+
 static inline void ena_rx_mbuf_prepare(struct rte_mbuf *mbuf,
 				       struct ena_com_rx_ctx *ena_rx_ctx,
@@ -395,6 +404,5 @@ static int validate_tx_req_id(struct ena_ring *tx_ring, u16 req_id)
 	/* Trigger device reset */
 	++tx_ring->tx_stats.bad_req_id;
-	tx_ring->adapter->reset_reason = ENA_REGS_RESET_INV_TX_REQ_ID;
-	tx_ring->adapter->trigger_reset	= true;
+	ena_trigger_reset(tx_ring->adapter, ENA_REGS_RESET_INV_TX_REQ_ID);
 	return -EFAULT;
 }
@@ -1525,6 +1533,5 @@ static void check_for_missing_keep_alive(struct ena_adapter *adapter)
 	    adapter->keep_alive_timeout)) {
 		PMD_DRV_LOG(ERR, "Keep alive timeout\n");
-		adapter->reset_reason = ENA_REGS_RESET_KEEP_ALIVE_TO;
-		adapter->trigger_reset = true;
+		ena_trigger_reset(adapter, ENA_REGS_RESET_KEEP_ALIVE_TO);
 		++adapter->dev_stats.wd_expired;
 	}
@@ -1536,6 +1543,5 @@ static void check_for_admin_com_state(struct ena_adapter *adapter)
 	if (unlikely(!ena_com_get_admin_running_state(&adapter->ena_dev))) {
 		PMD_DRV_LOG(ERR, "ENA admin queue is not in running state\n");
-		adapter->reset_reason = ENA_REGS_RESET_ADMIN_TO;
-		adapter->trigger_reset = true;
+		ena_trigger_reset(adapter, ENA_REGS_RESET_ADMIN_TO);
 	}
 }
@@ -2321,12 +2327,11 @@ static uint16_t eth_ena_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
 			if (rc == ENA_COM_NO_SPACE) {
 				++rx_ring->rx_stats.bad_desc_num;
-				rx_ring->adapter->reset_reason =
-					ENA_REGS_RESET_TOO_MANY_RX_DESCS;
+				ena_trigger_reset(rx_ring->adapter,
+					ENA_REGS_RESET_TOO_MANY_RX_DESCS);
 			} else {
 				++rx_ring->rx_stats.bad_req_id;
-				rx_ring->adapter->reset_reason =
-					ENA_REGS_RESET_INV_RX_REQ_ID;
+				ena_trigger_reset(rx_ring->adapter,
+					ENA_REGS_RESET_INV_RX_REQ_ID);
 			}
-			rx_ring->adapter->trigger_reset = true;
 			return 0;
 		}
@@ -2728,7 +2733,6 @@ static int ena_xmit_mbuf(struct ena_ring *tx_ring, struct rte_mbuf *mbuf)
 		PMD_DRV_LOG(ERR, "Failed to prepare Tx buffers, rc: %d\n", rc);
 		++tx_ring->tx_stats.prepare_ctx_err;
-		tx_ring->adapter->reset_reason =
-		    ENA_REGS_RESET_DRIVER_INVALID_STATE;
-		tx_ring->adapter->trigger_reset = true;
+		ena_trigger_reset(tx_ring->adapter,
+			ENA_REGS_RESET_DRIVER_INVALID_STATE);
 		return rc;
 	}
-- 
2.34.1


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

* patch 'net/ena: fix meta descriptor DF flag setup' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (73 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: fix reset reason being overwritten' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: check memory BAR before initializing LLQ' " Kevin Traynor
                   ` (27 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Krawczyk; +Cc: Dawid Gorecki, Shai Brandes, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/762277232c6cfef28380ce48630e94225a9f25e3

Thanks.

Kevin

---
From 762277232c6cfef28380ce48630e94225a9f25e3 Mon Sep 17 00:00:00 2001
From: Michal Krawczyk <mk@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:40 +0100
Subject: [PATCH] net/ena: fix meta descriptor DF flag setup

[ upstream commit 022fb61b62623868db2ec9dbe5b1ee43a4d6cbfb ]

Whenever Tx checksum offload is being used, the meta descriptor content
is taken into consideration. Setting DF field properly in the meta
descriptor may have huge impact on the performance both for the IPv4 and
IPv6 packets.

The requirements for the df field are as below:
* No offload used - value doesn't matter
* IPv4 - 0 or 1, depending on the DF flag in the IPv4 header
* IPv6 - 1

Setting DF to 0 causes the packet to enter the slow-path in the HW and
as a result can noticeable impact the performance.

Moreover, as 'true' may not always be mapped to 1 depending on it's
definition for the given platform/compiler, for safety DF field is being
set explicitly to 1.

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

Signed-off-by: Michal Krawczyk <mk@semihalf.com>
Reviewed-by: Dawid Gorecki <dgr@semihalf.com>
Reviewed-by: Shai Brandes <shaibran@amazon.com>
---
 drivers/net/ena/ena_ethdev.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index a3c073a95e..87eef882db 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -349,4 +349,6 @@ static inline void ena_tx_mbuf_prepare(struct rte_mbuf *mbuf,
 		if (mbuf->ol_flags & RTE_MBUF_F_TX_IPV6) {
 			ena_tx_ctx->l3_proto = ENA_ETH_IO_L3_PROTO_IPV6;
+			/* For the IPv6 packets, DF always needs to be true. */
+			ena_tx_ctx->df = 1;
 		} else {
 			ena_tx_ctx->l3_proto = ENA_ETH_IO_L3_PROTO_IPV4;
@@ -356,5 +358,5 @@ static inline void ena_tx_mbuf_prepare(struct rte_mbuf *mbuf,
 				(RTE_PTYPE_L4_NONFRAG
 				 | RTE_PTYPE_INNER_L4_NONFRAG))
-				ena_tx_ctx->df = true;
+				ena_tx_ctx->df = 1;
 		}
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.502431727 +0000
+++ 0076-net-ena-fix-meta-descriptor-DF-flag-setup.patch	2022-03-01 10:41:01.395244117 +0000
@@ -1 +1 @@
-From 022fb61b62623868db2ec9dbe5b1ee43a4d6cbfb Mon Sep 17 00:00:00 2001
+From 762277232c6cfef28380ce48630e94225a9f25e3 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 022fb61b62623868db2ec9dbe5b1ee43a4d6cbfb ]
+
@@ -24 +25,0 @@
-Cc: stable@dpdk.org
@@ -34 +35 @@
-index 0ca4269522..53a8071968 100644
+index a3c073a95e..87eef882db 100644
@@ -37 +38 @@
-@@ -625,4 +625,6 @@ static inline void ena_tx_mbuf_prepare(struct rte_mbuf *mbuf,
+@@ -349,4 +349,6 @@ static inline void ena_tx_mbuf_prepare(struct rte_mbuf *mbuf,
@@ -44 +45 @@
-@@ -632,5 +634,5 @@ static inline void ena_tx_mbuf_prepare(struct rte_mbuf *mbuf,
+@@ -356,5 +358,5 @@ static inline void ena_tx_mbuf_prepare(struct rte_mbuf *mbuf,


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

* patch 'net/ena: check memory BAR before initializing LLQ' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (74 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: fix meta descriptor DF flag setup' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/ena: fix checksum flag for L4' " Kevin Traynor
                   ` (26 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Dawid Gorecki; +Cc: Michal Krawczyk, Shai Brandes, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 9ec0a2b6cf2eee8e416f08538656ad2017054439 Mon Sep 17 00:00:00 2001
From: Dawid Gorecki <dgr@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:42 +0100
Subject: [PATCH] net/ena: check memory BAR before initializing LLQ

[ upstream commit 9ae7a13f8247319f63402107c8304ba57c3f4308 ]

The ena_com_config_dev_mode() performs many calculations related to LLQ
and then performs an admin queue call to configure LLQ in the device.

All of the operations performed by ena_com_config_dev_mode() are
unnecessary if membar hasn't been found. Move the dev_mem_base check
before ena_com_config_dev_mode() call. This prevents the unnecessary
operations from being performed.

Fixes: 2fca2a98c0d1 ("net/ena: support LLQv2")

Signed-off-by: Dawid Gorecki <dgr@semihalf.com>
Reviewed-by: Michal Krawczyk <mk@semihalf.com>
Reviewed-by: Shai Brandes <shaibran@amazon.com>
---
 drivers/net/ena/ena_ethdev.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index 87eef882db..80fcaf300a 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -1689,4 +1689,11 @@ ena_set_queues_placement_policy(struct ena_adapter *adapter,
 	}
 
+	if (adapter->dev_mem_base == NULL) {
+		PMD_DRV_LOG(ERR,
+			"LLQ is advertised as supported, but device doesn't expose mem bar\n");
+		ena_dev->tx_mem_queue_type = ENA_ADMIN_PLACEMENT_POLICY_HOST;
+		return 0;
+	}
+
 	rc = ena_com_config_dev_mode(ena_dev, llq, llq_default_configurations);
 	if (unlikely(rc)) {
@@ -1701,11 +1708,4 @@ ena_set_queues_placement_policy(struct ena_adapter *adapter,
 		return 0;
 
-	if (!adapter->dev_mem_base) {
-		PMD_DRV_LOG(ERR,
-			"Unable to access LLQ BAR resource. Fallback to host mode policy.\n");
-		ena_dev->tx_mem_queue_type = ENA_ADMIN_PLACEMENT_POLICY_HOST;
-		return 0;
-	}
-
 	ena_dev->mem_bar = adapter->dev_mem_base;
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.531597487 +0000
+++ 0077-net-ena-check-memory-BAR-before-initializing-LLQ.patch	2022-03-01 10:41:01.397244117 +0000
@@ -1 +1 @@
-From 9ae7a13f8247319f63402107c8304ba57c3f4308 Mon Sep 17 00:00:00 2001
+From 9ec0a2b6cf2eee8e416f08538656ad2017054439 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 9ae7a13f8247319f63402107c8304ba57c3f4308 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -25 +26 @@
-index b471102ea9..151c688eec 100644
+index 87eef882db..80fcaf300a 100644
@@ -28 +29 @@
-@@ -1954,4 +1954,11 @@ ena_set_queues_placement_policy(struct ena_adapter *adapter,
+@@ -1689,4 +1689,11 @@ ena_set_queues_placement_policy(struct ena_adapter *adapter,
@@ -40 +41 @@
-@@ -1966,11 +1973,4 @@ ena_set_queues_placement_policy(struct ena_adapter *adapter,
+@@ -1701,11 +1708,4 @@ ena_set_queues_placement_policy(struct ena_adapter *adapter,


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

* patch 'net/ena: fix checksum flag for L4' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (75 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: check memory BAR before initializing LLQ' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'common/mlx5: fix queue pair ack timeout configuration' " Kevin Traynor
                   ` (25 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Krawczyk; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From dd246a2e8f2b6f043999c1b8336a1bbc7ef996f5 Mon Sep 17 00:00:00 2001
From: Michal Krawczyk <mk@semihalf.com>
Date: Wed, 23 Feb 2022 13:19:43 +0100
Subject: [PATCH] net/ena: fix checksum flag for L4

[ upstream commit b2d2f1cf89a6c3661e68b750364e4a7018f954ba ]

Some HW may invalidly set checksum error bit for the valid L4 checksum.
To avoid drop of the packets in that situation, do not indicate bad
checksum for L4 Rx csum offloads. Instead, set it as unknown, so the
application will re-verify this value.

The statistics counters will still work as previously.

Fixes: 05817057faba ("net/ena: fix indication of bad L4 Rx checksums")

Signed-off-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/net/ena/ena_ethdev.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ena/ena_ethdev.c b/drivers/net/ena/ena_ethdev.c
index 80fcaf300a..770b101688 100644
--- a/drivers/net/ena/ena_ethdev.c
+++ b/drivers/net/ena/ena_ethdev.c
@@ -311,5 +311,11 @@ static inline void ena_rx_mbuf_prepare(struct rte_mbuf *mbuf,
 	else
 		if (unlikely(ena_rx_ctx->l4_csum_err))
-			ol_flags |= RTE_MBUF_F_RX_L4_CKSUM_BAD;
+			/*
+			 * For the L4 Rx checksum offload the HW may indicate
+			 * bad checksum although it's valid. Because of that,
+			 * we're setting the UNKNOWN flag to let the app
+			 * re-verify the checksum.
+			 */
+			ol_flags |= RTE_MBUF_F_RX_L4_CKSUM_UNKNOWN;
 		else
 			ol_flags |= RTE_MBUF_F_RX_L4_CKSUM_GOOD;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.560437171 +0000
+++ 0078-net-ena-fix-checksum-flag-for-L4.patch	2022-03-01 10:41:01.400244117 +0000
@@ -1 +1 @@
-From b2d2f1cf89a6c3661e68b750364e4a7018f954ba Mon Sep 17 00:00:00 2001
+From dd246a2e8f2b6f043999c1b8336a1bbc7ef996f5 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b2d2f1cf89a6c3661e68b750364e4a7018f954ba ]
+
@@ -14 +15,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 151c688eec..4b58dcda74 100644
+index 80fcaf300a..770b101688 100644
@@ -25,3 +26,3 @@
-@@ -584,5 +584,11 @@ static inline void ena_rx_mbuf_prepare(struct ena_ring *rx_ring,
- 		if (unlikely(ena_rx_ctx->l4_csum_err)) {
- 			++rx_stats->l4_csum_bad;
+@@ -311,5 +311,11 @@ static inline void ena_rx_mbuf_prepare(struct rte_mbuf *mbuf,
+ 	else
+ 		if (unlikely(ena_rx_ctx->l4_csum_err))
@@ -36,2 +37,2 @@
- 		} else {
- 			++rx_stats->l4_csum_good;
+ 		else
+ 			ol_flags |= RTE_MBUF_F_RX_L4_CKSUM_GOOD;


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

* patch 'common/mlx5: fix queue pair ack timeout configuration' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (76 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/ena: fix checksum flag for L4' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: set flow error for hash list create' " Kevin Traynor
                   ` (24 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Yajun Wu; +Cc: Matan Azrad, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From b8bc6f4256a25a01c7ac787b68823c6e95a9e7b9 Mon Sep 17 00:00:00 2001
From: Yajun Wu <yajunw@nvidia.com>
Date: Mon, 14 Feb 2022 08:03:19 +0200
Subject: [PATCH] common/mlx5: fix queue pair ack timeout configuration
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 05b54bf0892dcd1e3698ba86a297722b7566cc10 ]

VDPA driver creates two QPs(1 queue pair include 1 send queue
and 1 receive queue) per virtio queue to get traffic events
from NIC to SW.
Two QPs(called FW QP and SW QP) are created as loopback QP
and FW QP'SQ is connected to SW QP'RQ internally.

When packet receive or send out, HW will send WQE by FW QP'SQ,
then SW will get CQE from the CQ of SW QP.

With large scale and heavy traffic, the SQ's request may fail
to get ACK from RQ HW, because HW is busy.
SQ will retry the request with qpc.retry_count times and each time
wait for 4.096 uS *2^(ack_timeout) for the response. If still can’t
get RQ’s HW response, SQ will go to an error state.

16 is experienced value. It should not be too high or too low.
Too high will make QP waits too long in case it’s packet drop.
Too low will cause QP to go to an error state(retry-exceeded) easily.

Fixes: 15c3807e86ab ("common/mlx5: support DevX QP operations")

Signed-off-by: Yajun Wu <yajunw@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
---
 drivers/common/mlx5/mlx5_devx_cmds.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/common/mlx5/mlx5_devx_cmds.c b/drivers/common/mlx5/mlx5_devx_cmds.c
index 2e807a0829..7732613c69 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.c
+++ b/drivers/common/mlx5/mlx5_devx_cmds.c
@@ -2280,5 +2280,5 @@ mlx5_devx_cmd_modify_qp_state(struct mlx5_devx_obj *qp, uint32_t qp_st_mod_op,
 		qpc = MLX5_ADDR_OF(rtr2rts_qp_in, &in, qpc);
 		MLX5_SET(rtr2rts_qp_in, &in, qpn, qp->id);
-		MLX5_SET(qpc, qpc, primary_address_path.ack_timeout, 14);
+		MLX5_SET(qpc, qpc, primary_address_path.ack_timeout, 16);
 		MLX5_SET(qpc, qpc, log_ack_req_freq, 0);
 		MLX5_SET(qpc, qpc, retry_count, 7);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.588435064 +0000
+++ 0079-common-mlx5-fix-queue-pair-ack-timeout-configuration.patch	2022-03-01 10:41:01.401244118 +0000
@@ -1 +1 @@
-From 05b54bf0892dcd1e3698ba86a297722b7566cc10 Mon Sep 17 00:00:00 2001
+From b8bc6f4256a25a01c7ac787b68823c6e95a9e7b9 Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 05b54bf0892dcd1e3698ba86a297722b7566cc10 ]
+
@@ -29 +30,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/mlx5: set flow error for hash list create' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (77 preceding siblings ...)
  2022-03-01 10:42 ` patch 'common/mlx5: fix queue pair ack timeout configuration' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: remove unused function' " Kevin Traynor
                   ` (23 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Suanming Mou; +Cc: Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/383f7b7f800a445f546e977667334b9f1700814e

Thanks.

Kevin

---
From 383f7b7f800a445f546e977667334b9f1700814e Mon Sep 17 00:00:00 2001
From: Suanming Mou <suanmingm@nvidia.com>
Date: Tue, 15 Feb 2022 12:10:52 +0200
Subject: [PATCH] net/mlx5: set flow error for hash list create

[ upstream commit 0c5d3e4cdf1bbc92d138bce1f98f0b260a10b8fc ]

While mlx5_hlist_create() failed, the rte_flow_error was not filled
with the corresponding error information.

This commit adds the missing rte_flow_error_set() for the failure case.

Fixes: f3020a331dca ("net/mlx5: optimize hash list table allocate on demand")

Signed-off-by: Suanming Mou <suanmingm@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_dv.c | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index 10ef2af06a..c7f43c9ab4 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -313,5 +313,6 @@ flow_dv_hlist_prepare(struct mlx5_dev_ctx_shared *sh, struct mlx5_hlist **phl,
 		     mlx5_list_remove_cb cb_remove,
 		     mlx5_list_clone_cb cb_clone,
-		     mlx5_list_clone_free_cb cb_clone_free)
+		     mlx5_list_clone_free_cb cb_clone_free,
+		     struct rte_flow_error *error)
 {
 	struct mlx5_hlist *hl;
@@ -328,5 +329,7 @@ flow_dv_hlist_prepare(struct mlx5_dev_ctx_shared *sh, struct mlx5_hlist **phl,
 	if (!hl) {
 		DRV_LOG(ERR, "%s hash creation failed", name);
-		rte_errno = ENOMEM;
+		rte_flow_error_set(error, ENOMEM,
+				   RTE_FLOW_ERROR_TYPE_UNSPECIFIED, NULL,
+				   "cannot allocate resource memory");
 		return NULL;
 	}
@@ -3732,5 +3735,6 @@ flow_dv_encap_decap_resource_register
 				flow_dv_encap_decap_remove_cb,
 				flow_dv_encap_decap_clone_cb,
-				flow_dv_encap_decap_clone_free_cb);
+				flow_dv_encap_decap_clone_free_cb,
+				error);
 	if (unlikely(!encaps_decaps))
 		return -rte_errno;
@@ -5828,5 +5832,6 @@ flow_dv_modify_hdr_resource_register
 				flow_dv_modify_remove_cb,
 				flow_dv_modify_clone_cb,
-				flow_dv_modify_clone_free_cb);
+				flow_dv_modify_clone_free_cb,
+				error);
 	if (unlikely(!modify_cmds))
 		return -rte_errno;
@@ -10765,5 +10770,6 @@ flow_dv_tag_resource_register
 				      flow_dv_tag_remove_cb,
 				      flow_dv_tag_clone_cb,
-				      flow_dv_tag_clone_free_cb);
+				      flow_dv_tag_clone_free_cb,
+				      error);
 	if (unlikely(!tag_table))
 		return -rte_errno;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.616418159 +0000
+++ 0080-net-mlx5-set-flow-error-for-hash-list-create.patch	2022-03-01 10:41:01.415244121 +0000
@@ -1 +1 @@
-From 0c5d3e4cdf1bbc92d138bce1f98f0b260a10b8fc Mon Sep 17 00:00:00 2001
+From 383f7b7f800a445f546e977667334b9f1700814e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0c5d3e4cdf1bbc92d138bce1f98f0b260a10b8fc ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index c30cb4c203..ce69b6ff3a 100644
+index 10ef2af06a..c7f43c9ab4 100644
@@ -41 +42 @@
-@@ -3728,5 +3731,6 @@ flow_dv_encap_decap_resource_register
+@@ -3732,5 +3735,6 @@ flow_dv_encap_decap_resource_register
@@ -49 +50 @@
-@@ -5826,5 +5830,6 @@ flow_dv_modify_hdr_resource_register
+@@ -5828,5 +5832,6 @@ flow_dv_modify_hdr_resource_register
@@ -57 +58 @@
-@@ -10758,5 +10763,6 @@ flow_dv_tag_resource_register
+@@ -10765,5 +10770,6 @@ flow_dv_tag_resource_register


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

* patch 'net/mlx5: remove unused function' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (78 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: set flow error for hash list create' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix meter sub-policy creation' " Kevin Traynor
                   ` (22 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Suanming Mou; +Cc: Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From b362035a7e69c1e6cd65b4d94043a70cb2e2561e Mon Sep 17 00:00:00 2001
From: Suanming Mou <suanmingm@nvidia.com>
Date: Tue, 15 Feb 2022 11:46:23 +0200
Subject: [PATCH] net/mlx5: remove unused function

[ upstream commit ad98ff6c500ad99a68b3e3f0a2cdabad5ee7d769 ]

The mlx5_l3t_prepare_entry() function is not used anymore.
This commit removes the unused mlx5_l3t_prepare_entry() function.

Fixes: 92ef4b8f1688 ("ethdev: remove deprecated shared counter attribute")

Signed-off-by: Suanming Mou <suanmingm@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 drivers/net/mlx5/mlx5_utils.c | 41 -----------------------------------
 drivers/net/mlx5/mlx5_utils.h | 28 ------------------------
 2 files changed, 69 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_utils.c b/drivers/net/mlx5/mlx5_utils.c
index e4e66ae4c5..be33af96fe 100644
--- a/drivers/net/mlx5/mlx5_utils.c
+++ b/drivers/net/mlx5/mlx5_utils.c
@@ -1185,43 +1185,2 @@ mlx5_l3t_set_entry(struct mlx5_l3t_tbl *tbl, uint32_t idx,
 	return ret;
 }
-
-int32_t
-mlx5_l3t_prepare_entry(struct mlx5_l3t_tbl *tbl, uint32_t idx,
-		       union mlx5_l3t_data *data,
-		       mlx5_l3t_alloc_callback_fn cb, void *ctx)
-{
-	int32_t ret;
-
-	rte_spinlock_lock(&tbl->sl);
-	/* Check if entry data is ready. */
-	ret = __l3t_get_entry(tbl, idx, data);
-	if (!ret) {
-		switch (tbl->type) {
-		case MLX5_L3T_TYPE_WORD:
-			if (data->word)
-				goto out;
-			break;
-		case MLX5_L3T_TYPE_DWORD:
-			if (data->dword)
-				goto out;
-			break;
-		case MLX5_L3T_TYPE_QWORD:
-			if (data->qword)
-				goto out;
-			break;
-		default:
-			if (data->ptr)
-				goto out;
-			break;
-		}
-	}
-	/* Entry data is not ready, use user callback to create it. */
-	ret = cb(ctx, data);
-	if (ret)
-		goto out;
-	/* Save the new allocated data to entry. */
-	ret = __l3t_set_entry(tbl, idx, data);
-out:
-	rte_spinlock_unlock(&tbl->sl);
-	return ret;
-}
diff --git a/drivers/net/mlx5/mlx5_utils.h b/drivers/net/mlx5/mlx5_utils.h
index e2dcbafc0a..254c879d1a 100644
--- a/drivers/net/mlx5/mlx5_utils.h
+++ b/drivers/net/mlx5/mlx5_utils.h
@@ -460,32 +460,4 @@ int32_t mlx5_l3t_get_entry(struct mlx5_l3t_tbl *tbl, uint32_t idx,
 			    union mlx5_l3t_data *data);
 
-/**
- * This function gets the index entry from Three-level table.
- *
- * If the index entry is not available, allocate new one by callback
- * function and fill in the entry.
- *
- * @param tbl
- *   Pointer to the l3t.
- * @param idx
- *   Index to the entry.
- * @param data
- *   Pointer to the memory which saves the entry data.
- *   When function call returns 0, data contains the entry data get from
- *   l3t.
- *   When function call returns -1, data is not modified.
- * @param cb
- *   Callback function to allocate new data.
- * @param ctx
- *   Context for callback function.
- *
- * @return
- *   0 if success, -1 on error.
- */
-
-int32_t mlx5_l3t_prepare_entry(struct mlx5_l3t_tbl *tbl, uint32_t idx,
-			       union mlx5_l3t_data *data,
-			       mlx5_l3t_alloc_callback_fn cb, void *ctx);
-
 /**
  * This function decreases and clear index entry if reference
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.656724182 +0000
+++ 0081-net-mlx5-remove-unused-function.patch	2022-03-01 10:41:01.416244121 +0000
@@ -1 +1 @@
-From ad98ff6c500ad99a68b3e3f0a2cdabad5ee7d769 Mon Sep 17 00:00:00 2001
+From b362035a7e69c1e6cd65b4d94043a70cb2e2561e Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ad98ff6c500ad99a68b3e3f0a2cdabad5ee7d769 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/mlx5: fix meter sub-policy creation' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (79 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: remove unused function' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix entry in shared Rx queues list' " Kevin Traynor
                   ` (21 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Shun Hao; +Cc: Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e311e6045e4f7e9a44a6feda81ffe39fe1f1a8a9 Mon Sep 17 00:00:00 2001
From: Shun Hao <shunh@nvidia.com>
Date: Fri, 18 Feb 2022 09:43:08 +0200
Subject: [PATCH] net/mlx5: fix meter sub-policy creation

[ upstream commit 94112badf6f579ac76e96bda3b015ffee95a2c68 ]

If meter policy action was RSS, the correct items were not provided
for sub-policy creation.

This fixes the issue by providing original items in meter split, so
the sub-policy creation gets the correct items.

Fixes: 3c481324baf3 ("net/mlx5: fix meter flow direction check")

Signed-off-by: Shun Hao <shunh@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c
index d7cb1eb89b..5d56ce96ea 100644
--- a/drivers/net/mlx5/mlx5_flow.c
+++ b/drivers/net/mlx5/mlx5_flow.c
@@ -5023,4 +5023,5 @@ flow_meter_split_prep(struct rte_eth_dev *dev,
 	struct rte_flow_item *vlan_item_dst = NULL;
 	const struct rte_flow_item *vlan_item_src = NULL;
+	const struct rte_flow_item *orig_items = items;
 	struct rte_flow_action *hw_mtr_action;
 	struct rte_flow_action *action_pre_head = NULL;
@@ -5147,5 +5148,6 @@ flow_meter_split_prep(struct rte_eth_dev *dev,
 		if (!fm->def_policy) {
 			sub_policy = get_meter_sub_policy(dev, flow, wks,
-							  attr, items, error);
+							  attr, orig_items,
+							  error);
 			if (!sub_policy)
 				return -rte_errno;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.684193512 +0000
+++ 0082-net-mlx5-fix-meter-sub-policy-creation.patch	2022-03-01 10:41:01.425244123 +0000
@@ -1 +1 @@
-From 94112badf6f579ac76e96bda3b015ffee95a2c68 Mon Sep 17 00:00:00 2001
+From e311e6045e4f7e9a44a6feda81ffe39fe1f1a8a9 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 94112badf6f579ac76e96bda3b015ffee95a2c68 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 5b5b00cc3e..1c3f648491 100644
+index d7cb1eb89b..5d56ce96ea 100644
@@ -25 +26 @@
-@@ -5022,4 +5022,5 @@ flow_meter_split_prep(struct rte_eth_dev *dev,
+@@ -5023,4 +5023,5 @@ flow_meter_split_prep(struct rte_eth_dev *dev,
@@ -31 +32 @@
-@@ -5146,5 +5147,6 @@ flow_meter_split_prep(struct rte_eth_dev *dev,
+@@ -5147,5 +5148,6 @@ flow_meter_split_prep(struct rte_eth_dev *dev,


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

* patch 'net/mlx5: fix entry in shared Rx queues list' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (80 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix meter sub-policy creation' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/mlx5: fix E-Switch manager vport ID' " Kevin Traynor
                   ` (20 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From cd74ed097520c4b534390b96decabdf3f7772059 Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Mon, 14 Feb 2022 11:00:09 +0200
Subject: [PATCH] net/mlx5: fix entry in shared Rx queues list

[ upstream commit 0ad12a8090d4f34b0308cdbb4cd34750f841d7f9 ]

The mlx5_rxq_new function creates control structure and if it from
shared group, it is inserted into the shared RXQs list.

After that, there are some validations which in case they fail, RxQ
control object is released.
In these cases, invalid pointer to the object still in the list, and
access it may cause a crash.

Move the list insertion to the end of the function where the RxQ control
object is surely valid.

Fixes: 09c2555303be ("net/mlx5: support shared Rx queue")

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 drivers/net/mlx5/mlx5_rxq.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_rxq.c b/drivers/net/mlx5/mlx5_rxq.c
index 580d7ae868..fe72cf49d3 100644
--- a/drivers/net/mlx5/mlx5_rxq.c
+++ b/drivers/net/mlx5/mlx5_rxq.c
@@ -1720,10 +1720,4 @@ mlx5_rxq_new(struct rte_eth_dev *dev, struct mlx5_rxq_priv *rxq,
 	}
 	LIST_INIT(&tmpl->owners);
-	if (conf->share_group > 0) {
-		tmpl->rxq.shared = 1;
-		tmpl->share_group = conf->share_group;
-		tmpl->share_qid = conf->share_qid;
-		LIST_INSERT_HEAD(&priv->sh->shared_rxqs, tmpl, share_entry);
-	}
 	rxq->ctrl = tmpl;
 	LIST_INSERT_HEAD(&tmpl->owners, rxq, owner_entry);
@@ -1934,4 +1928,10 @@ mlx5_rxq_new(struct rte_eth_dev *dev, struct mlx5_rxq_priv *rxq,
 		(struct mlx5_mprq_buf *(*)[desc])(*tmpl->rxq.elts + desc_n);
 	tmpl->rxq.idx = idx;
+	if (conf->share_group > 0) {
+		tmpl->rxq.shared = 1;
+		tmpl->share_group = conf->share_group;
+		tmpl->share_qid = conf->share_qid;
+		LIST_INSERT_HEAD(&priv->sh->shared_rxqs, tmpl, share_entry);
+	}
 	LIST_INSERT_HEAD(&priv->rxqsctrl, tmpl, next);
 	return tmpl;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.716922727 +0000
+++ 0083-net-mlx5-fix-entry-in-shared-Rx-queues-list.patch	2022-03-01 10:41:01.428244123 +0000
@@ -1 +1 @@
-From 0ad12a8090d4f34b0308cdbb4cd34750f841d7f9 Mon Sep 17 00:00:00 2001
+From cd74ed097520c4b534390b96decabdf3f7772059 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 0ad12a8090d4f34b0308cdbb4cd34750f841d7f9 ]
+
@@ -18 +19,0 @@
-Cc: stable@dpdk.org
@@ -27 +28 @@
-index 2625fa3308..d1476b4115 100644
+index 580d7ae868..fe72cf49d3 100644
@@ -30 +31 @@
-@@ -1721,10 +1721,4 @@ mlx5_rxq_new(struct rte_eth_dev *dev, struct mlx5_rxq_priv *rxq,
+@@ -1720,10 +1720,4 @@ mlx5_rxq_new(struct rte_eth_dev *dev, struct mlx5_rxq_priv *rxq,
@@ -41 +42 @@
-@@ -1935,4 +1929,10 @@ mlx5_rxq_new(struct rte_eth_dev *dev, struct mlx5_rxq_priv *rxq,
+@@ -1934,4 +1928,10 @@ mlx5_rxq_new(struct rte_eth_dev *dev, struct mlx5_rxq_priv *rxq,


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

* patch 'net/mlx5: fix E-Switch manager vport ID' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (81 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix entry in shared Rx queues list' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'doc: remove obsolete vector Tx explanations from mlx5 guide' " Kevin Traynor
                   ` (19 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Shun Hao; +Cc: Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/036220c967eee9a9638b06fc1cb64590b52c91a6

Thanks.

Kevin

---
From 036220c967eee9a9638b06fc1cb64590b52c91a6 Mon Sep 17 00:00:00 2001
From: Shun Hao <shunh@nvidia.com>
Date: Tue, 22 Feb 2022 17:07:16 +0200
Subject: [PATCH] net/mlx5: fix E-Switch manager vport ID

[ upstream commit 38eb5c9f35433f5d133f6490d97319e05bde317d ]

One of the E-Switch vports plays the special role - it is assigned as
"E-Switch manager" and has some special exclusive rights and duties - it
maintains all the representors, manages FDB domain flows, etc. By
default, the E-Switch vport index was supposed to be zero on standalone
NICs (regular ConnectX) and 0xFFFE SmartNIC (BlueField), but that was
not always correct - this index can be assigned with any value by
kernel/hypervisor.

Currently the E-Switch manager vport id is supposed to be default - 0
for standalone NICs, and 0xFFFE for the SmartNICs, and is deduced from
the device PCI id.

To handle this and do not suggest any default values, can use DevX API
to query E-Switch manager vport ID directly from the firmware during
initialization, and use that value by default. If the new method is not
provided (legacy firmware), fallback to use the PCI id approach.

Fixes: a564038699f9 ("net/mlx5: support E-Switch manager egress traffic match")

Signed-off-by: Shun Hao <shunh@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 drivers/common/mlx5/mlx5_devx_cmds.c | 12 ++++++++++++
 drivers/common/mlx5/mlx5_devx_cmds.h |  2 ++
 drivers/common/mlx5/mlx5_prm.h       | 12 ++++++++++++
 drivers/net/mlx5/mlx5_flow_dv.c      |  4 ++++
 4 files changed, 30 insertions(+)

diff --git a/drivers/common/mlx5/mlx5_devx_cmds.c b/drivers/common/mlx5/mlx5_devx_cmds.c
index 7732613c69..70a430f134 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.c
+++ b/drivers/common/mlx5/mlx5_devx_cmds.c
@@ -1131,4 +1131,16 @@ mlx5_devx_cmd_query_hca_attr(void *ctx,
 		}
 	}
+	if (attr->eswitch_manager) {
+		hcattr = mlx5_devx_get_hca_cap(ctx, in, out, &rc,
+				MLX5_SET_HCA_CAP_OP_MOD_ESW |
+				MLX5_HCA_CAP_OPMOD_GET_CUR);
+		if (!hcattr)
+			return rc;
+		attr->esw_mgr_vport_id_valid =
+			MLX5_GET(esw_cap, hcattr,
+				 esw_manager_vport_number_valid);
+		attr->esw_mgr_vport_id =
+			MLX5_GET(esw_cap, hcattr, esw_manager_vport_number);
+	}
 	return 0;
 error:
diff --git a/drivers/common/mlx5/mlx5_devx_cmds.h b/drivers/common/mlx5/mlx5_devx_cmds.h
index 37821b493e..4373761c29 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.h
+++ b/drivers/common/mlx5/mlx5_devx_cmds.h
@@ -253,4 +253,6 @@ struct mlx5_hca_attr {
 	uint32_t umr_indirect_mkey_disabled:1;
 	uint32_t log_min_stride_wqe_sz:5;
+	uint32_t esw_mgr_vport_id_valid:1; /* E-Switch Mgr vport ID is valid. */
+	uint16_t esw_mgr_vport_id; /* E-Switch Mgr vport ID . */
 	uint16_t max_wqe_sz_sq;
 };
diff --git a/drivers/common/mlx5/mlx5_prm.h b/drivers/common/mlx5/mlx5_prm.h
index 495b63191a..b9e39aa717 100644
--- a/drivers/common/mlx5/mlx5_prm.h
+++ b/drivers/common/mlx5/mlx5_prm.h
@@ -1265,4 +1265,5 @@ enum {
 	MLX5_GET_HCA_CAP_OP_MOD_ROCE = 0x4 << 1,
 	MLX5_GET_HCA_CAP_OP_MOD_NIC_FLOW_TABLE = 0x7 << 1,
+	MLX5_SET_HCA_CAP_OP_MOD_ESW = 0x9 << 1,
 	MLX5_GET_HCA_CAP_OP_MOD_VDPA_EMULATION = 0x13 << 1,
 	MLX5_GET_HCA_CAP_OP_MOD_PARSE_GRAPH_NODE_CAP = 0x1C << 1,
@@ -1927,4 +1928,14 @@ struct mlx5_ifc_cmd_hca_cap_2_bits {
 };
 
+struct mlx5_ifc_esw_cap_bits {
+	u8 reserved_at_0[0x60];
+
+	u8 esw_manager_vport_number_valid[0x1];
+	u8 reserved_at_61[0xf];
+	u8 esw_manager_vport_number[0x10];
+
+	u8 reserved_at_80[0x780];
+};
+
 union mlx5_ifc_hca_cap_union_bits {
 	struct mlx5_ifc_cmd_hca_cap_bits cmd_hca_cap;
@@ -1935,4 +1946,5 @@ union mlx5_ifc_hca_cap_union_bits {
 	struct mlx5_ifc_virtio_emulation_cap_bits vdpa_caps;
 	struct mlx5_ifc_flow_table_nic_cap_bits flow_table_nic_cap;
+	struct mlx5_ifc_esw_cap_bits esw_cap;
 	struct mlx5_ifc_roce_caps_bits roce_caps;
 	u8 reserved_at_0[0x8000];
diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index c7f43c9ab4..5225978a3b 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -98,4 +98,8 @@ flow_dv_get_esw_manager_vport_id(struct rte_eth_dev *dev)
 {
 	struct mlx5_priv *priv = dev->data->dev_private;
+	struct mlx5_common_device *cdev = priv->sh->cdev;
+
+	if (cdev->config.hca_attr.esw_mgr_vport_id_valid)
+		return (int16_t)cdev->config.hca_attr.esw_mgr_vport_id;
 
 	if (priv->pci_dev == NULL)
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.744905033 +0000
+++ 0084-net-mlx5-fix-E-Switch-manager-vport-ID.patch	2022-03-01 10:41:01.447244127 +0000
@@ -1 +1 @@
-From 38eb5c9f35433f5d133f6490d97319e05bde317d Mon Sep 17 00:00:00 2001
+From 036220c967eee9a9638b06fc1cb64590b52c91a6 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 38eb5c9f35433f5d133f6490d97319e05bde317d ]
+
@@ -24 +25,0 @@
-Cc: stable@dpdk.org
@@ -99 +100 @@
-index 689b191748..abd1c27538 100644
+index c7f43c9ab4..5225978a3b 100644


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

* patch 'doc: remove obsolete vector Tx explanations from mlx5 guide' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (82 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/mlx5: fix E-Switch manager vport ID' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'doc: replace broken links in mlx guides' " Kevin Traynor
                   ` (18 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Raslan Darawsheh, Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/97cf74ba16c0865564b3f19ce273fd19b6bcb411

Thanks.

Kevin

---
From 97cf74ba16c0865564b3f19ce273fd19b6bcb411 Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Wed, 23 Feb 2022 15:48:30 +0200
Subject: [PATCH] doc: remove obsolete vector Tx explanations from mlx5 guide

[ upstream commit 9c7dc70265696ef402ed6f54a2552ed7684560aa ]

Vectorized routines were removed in result of Tx datapath refactoring,
and devarg keys documentation was updated.

However, more updating should have been done. In environment variables
doc, there was explanation according to vectorized Tx which isn't
relevant anymore.

This patch removes this irrelevant explanation.

Fixes: a6bd4911ad93 ("net/mlx5: remove Tx implementation")

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Reviewed-by: Raslan Darawsheh <rasland@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 doc/guides/nics/mlx5.rst | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst
index daa7f2affb..002c89e9bc 100644
--- a/doc/guides/nics/mlx5.rst
+++ b/doc/guides/nics/mlx5.rst
@@ -555,13 +555,4 @@ Environment variables
   becomes full, but it depends on CPU design.
 
-  Except for vectorized Tx burst routines, a write memory barrier is enforced
-  after updating the register so that the update can be immediately visible to
-  HW.
-
-  When vectorized Tx burst is called, the barrier is set only if the burst size
-  is not aligned to MLX5_VPMD_TX_MAX_BURST. However, setting this environmental
-  variable will bring better latency even though the maximum throughput can
-  slightly decline.
-
 Run-time configuration
 ~~~~~~~~~~~~~~~~~~~~~~
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.785573139 +0000
+++ 0085-doc-remove-obsolete-vector-Tx-explanations-from-mlx5.patch	2022-03-01 10:41:01.450244128 +0000
@@ -1 +1 @@
-From 9c7dc70265696ef402ed6f54a2552ed7684560aa Mon Sep 17 00:00:00 2001
+From 97cf74ba16c0865564b3f19ce273fd19b6bcb411 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 9c7dc70265696ef402ed6f54a2552ed7684560aa ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org
@@ -26 +27 @@
-index c3cc0c0f41..3f5c8bb303 100644
+index daa7f2affb..002c89e9bc 100644
@@ -29 +30 @@
-@@ -558,13 +558,4 @@ Environment variables
+@@ -555,13 +555,4 @@ Environment variables


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

* patch 'doc: replace broken links in mlx guides' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (83 preceding siblings ...)
  2022-03-01 10:42 ` patch 'doc: remove obsolete vector Tx explanations from mlx5 guide' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'doc: correct name of BlueField-2 in mlx5 guide' " Kevin Traynor
                   ` (17 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Raslan Darawsheh, Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/01a4e400639652c7d72117b91fc224d1e1e477ba

Thanks.

Kevin

---
From 01a4e400639652c7d72117b91fc224d1e1e477ba Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Wed, 23 Feb 2022 15:48:31 +0200
Subject: [PATCH] doc: replace broken links in mlx guides

[ upstream commit ec49089884628892ba8e6ece7ec545f069e2d9e3 ]

Update links in both mlx4 and mlx5 doc.

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Reviewed-by: Raslan Darawsheh <rasland@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 doc/guides/nics/mlx4.rst | 4 ++--
 doc/guides/nics/mlx5.rst | 6 +++---
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/doc/guides/nics/mlx4.rst b/doc/guides/nics/mlx4.rst
index c81105730d..66493a1157 100644
--- a/doc/guides/nics/mlx4.rst
+++ b/doc/guides/nics/mlx4.rst
@@ -15,5 +15,5 @@ the `Mellanox community <http://community.mellanox.com/welcome>`_.
 
 There is also a `section dedicated to this poll mode driver
-<http://www.mellanox.com/page/products_dyn?product_family=209&mtag=pmd_for_dpdk>`_.
+<https://developer.nvidia.com/networking/dpdk>`_.
 
 
@@ -220,5 +220,5 @@ Mellanox OFED as a fallback
 - firmware version: **2.42.5000** and above.
 
-.. _`Mellanox OFED`: http://www.mellanox.com/page/products_dyn?product_family=26&mtag=linux_sw_drivers
+.. _`Mellanox OFED`: https://network.nvidia.com/products/infiniband-drivers/linux/mlnx_ofed/
 
 .. note::
diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst
index 002c89e9bc..60f6c8b7cd 100644
--- a/doc/guides/nics/mlx5.rst
+++ b/doc/guides/nics/mlx5.rst
@@ -20,5 +20,5 @@ Information and documentation about these adapters can be found on the
 
 There is also a `section dedicated to this poll mode driver
-<http://www.mellanox.com/page/products_dyn?product_family=209&mtag=pmd_for_dpdk>`__.
+<https://developer.nvidia.com/networking/dpdk>`_.
 
 
@@ -1374,7 +1374,7 @@ may not be supported at the moment (this is a work in progress).
 
 `Mellanox OFED
-<http://www.mellanox.com/page/products_dyn?product_family=26&mtag=linux>`__ and
+<https://network.nvidia.com/products/infiniband-drivers/linux/mlnx_ofed/>`__ and
 `Mellanox EN
-<http://www.mellanox.com/page/products_dyn?product_family=27&mtag=linux>`__
+<https://network.nvidia.com/products/ethernet-drivers/linux/mlnx_en/>`__
 include the necessary support and should be used in the meantime. For DPDK,
 only libibverbs, libmlx5, mlnx-ofed-kernel packages and firmware updates are
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.806830939 +0000
+++ 0086-doc-replace-broken-links-in-mlx-guides.patch	2022-03-01 10:41:01.452244128 +0000
@@ -1 +1 @@
-From ec49089884628892ba8e6ece7ec545f069e2d9e3 Mon Sep 17 00:00:00 2001
+From 01a4e400639652c7d72117b91fc224d1e1e477ba Mon Sep 17 00:00:00 2001
@@ -6 +6 @@
-Update links in both mlx4 and mlx5 doc.
+[ upstream commit ec49089884628892ba8e6ece7ec545f069e2d9e3 ]
@@ -8 +8 @@
-Cc: stable@dpdk.org
+Update links in both mlx4 and mlx5 doc.
@@ -37 +37 @@
-index 3f5c8bb303..c9defd0c60 100644
+index 002c89e9bc..60f6c8b7cd 100644
@@ -47 +47 @@
-@@ -1377,7 +1377,7 @@ may not be supported at the moment (this is a work in progress).
+@@ -1374,7 +1374,7 @@ may not be supported at the moment (this is a work in progress).


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

* patch 'doc: correct name of BlueField-2 in mlx5 guide' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (84 preceding siblings ...)
  2022-03-01 10:42 ` patch 'doc: replace broken links in mlx guides' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'mempool/cnxk: fix batch allocation failure path' " Kevin Traynor
                   ` (16 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michael Baum; +Cc: Raslan Darawsheh, Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 0c1e19f714718396fab4c8a064b9337af3c74a3a Mon Sep 17 00:00:00 2001
From: Michael Baum <michaelba@nvidia.com>
Date: Wed, 23 Feb 2022 15:48:32 +0200
Subject: [PATCH] doc: correct name of BlueField-2 in mlx5 guide

[ upstream commit 67e1bb42b95047b8edfdf86bd3cbd6916eeb36d6 ]

Update "BlueField 2" -> "BlueField-2" in mlx5 docs.

Signed-off-by: Michael Baum <michaelba@nvidia.com>
Reviewed-by: Raslan Darawsheh <rasland@nvidia.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 doc/guides/compressdevs/mlx5.rst | 6 +++---
 doc/guides/cryptodevs/mlx5.rst   | 6 +++---
 doc/guides/nics/mlx5.rst         | 2 +-
 doc/guides/regexdevs/mlx5.rst    | 8 ++++----
 4 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/doc/guides/compressdevs/mlx5.rst b/doc/guides/compressdevs/mlx5.rst
index a4e17f65b3..7f2d6bdfff 100644
--- a/doc/guides/compressdevs/mlx5.rst
+++ b/doc/guides/compressdevs/mlx5.rst
@@ -8,5 +8,5 @@ MLX5 compress driver
 
 The MLX5 compress driver library
-(**librte_compress_mlx5**) provides support for **Mellanox BlueField 2**
+(**librte_compress_mlx5**) provides support for **Mellanox BlueField-2**
 families of 25/50/100/200 Gb/s adapters.
 
@@ -22,5 +22,5 @@ such they do not use NIC related resources (e.g. RX/TX bandwidth).
 They do share the same PCI and memory bandwidth.
 
-So, using the BlueField device (starting from BlueField 2), the compress
+So, using the BlueField device (starting from BlueField-2), the compress
 class operations can be supported in parallel to the net, vDPA and
 RegEx class operations.
@@ -96,5 +96,5 @@ Supported NICs
 --------------
 
-* Mellanox\ |reg| BlueField 2 SmartNIC
+* Mellanox\ |reg| BlueField-2 SmartNIC
 
 Prerequisites
diff --git a/doc/guides/cryptodevs/mlx5.rst b/doc/guides/cryptodevs/mlx5.rst
index e86a6205e8..9936556cc9 100644
--- a/doc/guides/cryptodevs/mlx5.rst
+++ b/doc/guides/cryptodevs/mlx5.rst
@@ -89,5 +89,5 @@ The mlxreg dedicated tool should be used as follows:
 
   All the device ports should set it in order to move to operational mode.
-  For BlueField 2, the internal ports in the ARM system should also be set.
+  For BlueField-2, the internal ports in the ARM system should also be set.
 
 - Query CRYPTO_OPERATIONAL register to make sure the device is in Operational
@@ -143,5 +143,5 @@ Supported NICs
 
 * Mellanox\ |reg| ConnectX\ |reg|-6 200G MCX654106A-HCAT (2x200G)
-* Mellanox\ |reg| BlueField 2 SmartNIC
+* Mellanox\ |reg| BlueField-2 SmartNIC
 * Mellanox\ |reg| ConnectX\ |reg|-6 Dx
 
@@ -163,5 +163,5 @@ FW Prerequisites
 
 - xx.31.0328 for ConnectX-6.
-- xx.32.0108 for ConnectX-6 Dx and BlueField 2.
+- xx.32.0108 for ConnectX-6 Dx and BlueField-2.
 
 Linux Prerequisites
diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst
index 60f6c8b7cd..e3242a6bd4 100644
--- a/doc/guides/nics/mlx5.rst
+++ b/doc/guides/nics/mlx5.rst
@@ -251,5 +251,5 @@ Limitations
 - Flex item:
 
-  - Hardware support: BlueField 2.
+  - Hardware support: BlueField-2.
   - Flex item is supported on PF only.
   - Hardware limits ``header_length_mask_width`` up to 6 bits.
diff --git a/doc/guides/regexdevs/mlx5.rst b/doc/guides/regexdevs/mlx5.rst
index b2bf0afd01..fc2cacba60 100644
--- a/doc/guides/regexdevs/mlx5.rst
+++ b/doc/guides/regexdevs/mlx5.rst
@@ -8,5 +8,5 @@ MLX5 RegEx driver
 
 The MLX5 RegEx (Regular Expression) driver library
-(**librte_regex_mlx5**) provides support for **Mellanox BlueField 2**
+(**librte_regex_mlx5**) provides support for **Mellanox BlueField-2**
 families of 25/50/100/200 Gb/s adapters.
 
@@ -44,11 +44,11 @@ Supported NICs
 --------------
 
-* Mellanox\ |reg| BlueField 2 SmartNIC
+* Mellanox\ |reg| BlueField-2 SmartNIC
 
 Prerequisites
 -------------
 
-- BlueField 2 running Mellanox supported kernel.
-- Enable the RegEx capabilities using system call from the BlueField 2.
+- BlueField-2 running Mellanox supported kernel.
+- Enable the RegEx capabilities using system call from the BlueField-2.
 - Official support is not yet released.
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.827174008 +0000
+++ 0087-doc-correct-name-of-BlueField-2-in-mlx5-guide.patch	2022-03-01 10:41:01.455244129 +0000
@@ -1 +1 @@
-From 67e1bb42b95047b8edfdf86bd3cbd6916eeb36d6 Mon Sep 17 00:00:00 2001
+From 0c1e19f714718396fab4c8a064b9337af3c74a3a Mon Sep 17 00:00:00 2001
@@ -6 +6 @@
-Update "BlueField 2" -> "BlueField-2" in mlx5 docs.
+[ upstream commit 67e1bb42b95047b8edfdf86bd3cbd6916eeb36d6 ]
@@ -8 +8 @@
-Cc: stable@dpdk.org
+Update "BlueField 2" -> "BlueField-2" in mlx5 docs.
@@ -71 +71 @@
-index c9defd0c60..b7ad55561c 100644
+index 60f6c8b7cd..e3242a6bd4 100644
@@ -74 +74 @@
-@@ -254,5 +254,5 @@ Limitations
+@@ -251,5 +251,5 @@ Limitations


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

* patch 'mempool/cnxk: fix batch allocation failure path' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (85 preceding siblings ...)
  2022-03-01 10:42 ` patch 'doc: correct name of BlueField-2 in mlx5 guide' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/cnxk: fix inline device RQ tag mask' " Kevin Traynor
                   ` (15 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Ashwin Sekhar T K; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From dbafc478b0524db951f89162ba53331dc76b65bd Mon Sep 17 00:00:00 2001
From: Ashwin Sekhar T K <asekhar@marvell.com>
Date: Fri, 18 Feb 2022 12:57:12 +0530
Subject: [PATCH] mempool/cnxk: fix batch allocation failure path

[ upstream commit 5582a60effbb8599ad7be827abe4d06ca436b04b ]

Fix bug in batch alloc issue failure path where it was
enqueuing invalid pointers back to the pool. The code
should rightly be falling back to default dequeue path
in such cases.

Fixes: 91531e63f43b ("mempool/cnxk: add cn10k batch dequeue")

Signed-off-by: Ashwin Sekhar T K <asekhar@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/mempool/cnxk/cn10k_mempool_ops.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mempool/cnxk/cn10k_mempool_ops.c b/drivers/mempool/cnxk/cn10k_mempool_ops.c
index 4c669b878f..6ebbf91de5 100644
--- a/drivers/mempool/cnxk/cn10k_mempool_ops.c
+++ b/drivers/mempool/cnxk/cn10k_mempool_ops.c
@@ -203,5 +203,5 @@ cn10k_mempool_deq(struct rte_mempool *mp, void **obj_table, unsigned int n)
 		/* If issue fails, try falling back to default alloc */
 		if (unlikely(rc))
-			return cn10k_mempool_enq(mp, obj_table, n);
+			return cnxk_mempool_deq(mp, obj_table, n);
 		mem->status = BATCH_ALLOC_OP_ISSUED;
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.848142855 +0000
+++ 0088-mempool-cnxk-fix-batch-allocation-failure-path.patch	2022-03-01 10:41:01.456244129 +0000
@@ -1 +1 @@
-From 5582a60effbb8599ad7be827abe4d06ca436b04b Mon Sep 17 00:00:00 2001
+From dbafc478b0524db951f89162ba53331dc76b65bd Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 5582a60effbb8599ad7be827abe4d06ca436b04b ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org


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

* patch 'net/cnxk: fix inline device RQ tag mask' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (86 preceding siblings ...)
  2022-03-01 10:42 ` patch 'mempool/cnxk: fix batch allocation failure path' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/cnxk: register callback early to handle initial packets' " Kevin Traynor
                   ` (14 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Nithin Dabilpuram; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/12640e77b816edb6a2e74b9d672c3500d8c1a275

Thanks.

Kevin

---
From 12640e77b816edb6a2e74b9d672c3500d8c1a275 Mon Sep 17 00:00:00 2001
From: Nithin Dabilpuram <ndabilpuram@marvell.com>
Date: Wed, 23 Feb 2022 01:05:03 +0530
Subject: [PATCH] net/cnxk: fix inline device RQ tag mask

[ upstream commit 82529cff18df734262077661c6a91560b1fd8833 ]

Fix inline device RQ  tagmask to get packets with receive errors
as type ETHDEV packets to callback handler so that packet buffers
can get freed. Currently only IPsec denied packets get the right
tag mask.

Fixes: ee48f711f3b0 ("common/cnxk: support NIX inline inbound and outbound setup")

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/common/cnxk/roc_nix_inl.c | 2 +-
 drivers/net/cnxk/cnxk_ethdev.c    | 9 +++++++++
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/drivers/common/cnxk/roc_nix_inl.c b/drivers/common/cnxk/roc_nix_inl.c
index e8981c4aa4..e71774cf4a 100644
--- a/drivers/common/cnxk/roc_nix_inl.c
+++ b/drivers/common/cnxk/roc_nix_inl.c
@@ -534,5 +534,5 @@ roc_nix_inl_dev_rq_get(struct roc_nix_rq *rq)
 	inl_rq->flow_tag_width = 20;
 	/* Special tag mask */
-	inl_rq->tag_mask = 0xFFF00000;
+	inl_rq->tag_mask = rq->tag_mask;
 	inl_rq->tt = SSO_TT_ORDERED;
 	inl_rq->hwgrp = 0;
diff --git a/drivers/net/cnxk/cnxk_ethdev.c b/drivers/net/cnxk/cnxk_ethdev.c
index a90c2ae321..0c38f013c2 100644
--- a/drivers/net/cnxk/cnxk_ethdev.c
+++ b/drivers/net/cnxk/cnxk_ethdev.c
@@ -4,4 +4,6 @@
 #include <cnxk_ethdev.h>
 
+#include <rte_eventdev.h>
+
 static inline uint64_t
 nix_get_rx_offload_capa(struct cnxk_eth_dev *dev)
@@ -598,4 +600,11 @@ cnxk_nix_rx_queue_setup(struct rte_eth_dev *eth_dev, uint16_t qid,
 
 	if (dev->rx_offloads & RTE_ETH_RX_OFFLOAD_SECURITY) {
+		/* Pass a tagmask used to handle error packets in inline device.
+		 * Ethdev rq's tag_mask field will be overwritten later
+		 * when sso is setup.
+		 */
+		rq->tag_mask =
+			0x0FF00000 | ((uint32_t)RTE_EVENT_TYPE_ETHDEV << 28);
+
 		/* Setup rq reference for inline dev if present */
 		rc = roc_nix_inl_dev_rq_get(rq);
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.867351456 +0000
+++ 0089-net-cnxk-fix-inline-device-RQ-tag-mask.patch	2022-03-01 10:41:01.458244129 +0000
@@ -1 +1 @@
-From 82529cff18df734262077661c6a91560b1fd8833 Mon Sep 17 00:00:00 2001
+From 12640e77b816edb6a2e74b9d672c3500d8c1a275 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 82529cff18df734262077661c6a91560b1fd8833 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index 003f972aeb..11a169137b 100644
+index e8981c4aa4..e71774cf4a 100644
@@ -25 +26 @@
-@@ -585,5 +585,5 @@ roc_nix_inl_dev_rq_get(struct roc_nix_rq *rq)
+@@ -534,5 +534,5 @@ roc_nix_inl_dev_rq_get(struct roc_nix_rq *rq)
@@ -33 +34 @@
-index 0558bc3eed..a2b2679398 100644
+index a90c2ae321..0c38f013c2 100644


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

* patch 'net/cnxk: register callback early to handle initial packets' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (87 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/cnxk: fix inline device RQ tag mask' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/cnxk: fix inline IPsec security error handling' " Kevin Traynor
                   ` (13 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Nithin Dabilpuram; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/667b3995446d943219c906bde6d13f10f2aeff5b

Thanks.

Kevin

---
From 667b3995446d943219c906bde6d13f10f2aeff5b Mon Sep 17 00:00:00 2001
From: Nithin Dabilpuram <ndabilpuram@marvell.com>
Date: Wed, 23 Feb 2022 01:05:04 +0530
Subject: [PATCH] net/cnxk: register callback early to handle initial packets

[ upstream commit fb35a2c703ca5e05067a2f94965a06da8626875d ]

Register callback early to handle initial error packets from
inline device.

Fixes: 69daa9e5022b ("net/cnxk: support inline security setup for cn10k")

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/net/cnxk/cn10k_ethdev.c     | 6 ++++++
 drivers/net/cnxk/cn10k_ethdev.h     | 3 +++
 drivers/net/cnxk/cn10k_ethdev_sec.c | 5 +----
 3 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/drivers/net/cnxk/cn10k_ethdev.c b/drivers/net/cnxk/cn10k_ethdev.c
index 8378cbffc2..c36b858110 100644
--- a/drivers/net/cnxk/cn10k_ethdev.c
+++ b/drivers/net/cnxk/cn10k_ethdev.c
@@ -314,4 +314,10 @@ cn10k_nix_configure(struct rte_eth_dev *eth_dev)
 		return rc;
 
+	if (dev->tx_offloads & RTE_ETH_TX_OFFLOAD_SECURITY ||
+	    dev->rx_offloads & RTE_ETH_RX_OFFLOAD_SECURITY) {
+		/* Register callback to handle security error work */
+		roc_nix_inl_cb_register(cn10k_eth_sec_sso_work_cb, NULL);
+	}
+
 	/* Update offload flags */
 	dev->rx_offload_flags = nix_rx_offload_flags(eth_dev);
diff --git a/drivers/net/cnxk/cn10k_ethdev.h b/drivers/net/cnxk/cn10k_ethdev.h
index 0982158c62..13403e14c4 100644
--- a/drivers/net/cnxk/cn10k_ethdev.h
+++ b/drivers/net/cnxk/cn10k_ethdev.h
@@ -83,4 +83,7 @@ void cn10k_eth_set_tx_function(struct rte_eth_dev *eth_dev);
 void cn10k_eth_sec_ops_override(void);
 
+/* SSO Work callback */
+void cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args);
+
 #define LMT_OFF(lmt_addr, lmt_num, offset)                                     \
 	(void *)((uintptr_t)(lmt_addr) +                                       \
diff --git a/drivers/net/cnxk/cn10k_ethdev_sec.c b/drivers/net/cnxk/cn10k_ethdev_sec.c
index 235c16840e..a517421b12 100644
--- a/drivers/net/cnxk/cn10k_ethdev_sec.c
+++ b/drivers/net/cnxk/cn10k_ethdev_sec.c
@@ -139,5 +139,5 @@ static const struct rte_security_capability cn10k_eth_sec_capabilities[] = {
 };
 
-static void
+void
 cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args)
 {
@@ -250,7 +250,4 @@ cn10k_eth_sec_session_create(void *device,
 		return -ENOTSUP;
 
-	if (rte_eal_process_type() == RTE_PROC_PRIMARY)
-		roc_nix_inl_cb_register(cn10k_eth_sec_sso_work_cb, NULL);
-
 	ipsec = &conf->ipsec;
 	crypto = conf->crypto_xform;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.887217543 +0000
+++ 0090-net-cnxk-register-callback-early-to-handle-initial-p.patch	2022-03-01 10:41:01.459244130 +0000
@@ -1 +1 @@
-From fb35a2c703ca5e05067a2f94965a06da8626875d Mon Sep 17 00:00:00 2001
+From 667b3995446d943219c906bde6d13f10f2aeff5b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit fb35a2c703ca5e05067a2f94965a06da8626875d ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 03ca1abe45..c6890f3699 100644
+index 8378cbffc2..c36b858110 100644
@@ -24 +25 @@
-@@ -295,4 +295,10 @@ cn10k_nix_configure(struct rte_eth_dev *eth_dev)
+@@ -314,4 +314,10 @@ cn10k_nix_configure(struct rte_eth_dev *eth_dev)
@@ -36 +37 @@
-index ec40e53152..fd7273078a 100644
+index 0982158c62..13403e14c4 100644
@@ -39 +40 @@
-@@ -82,4 +82,7 @@ void cn10k_eth_set_tx_function(struct rte_eth_dev *eth_dev);
+@@ -83,4 +83,7 @@ void cn10k_eth_set_tx_function(struct rte_eth_dev *eth_dev);
@@ -48 +49 @@
-index 6fbf444038..ac45056936 100644
+index 235c16840e..a517421b12 100644
@@ -58 +59 @@
-@@ -252,7 +252,4 @@ cn10k_eth_sec_session_create(void *device,
+@@ -250,7 +250,4 @@ cn10k_eth_sec_session_create(void *device,


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

* patch 'net/cnxk: fix inline IPsec security error handling' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (88 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/cnxk: register callback early to handle initial packets' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/cnxk: fix build with GCC 12' " Kevin Traynor
                   ` (12 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Nithin Dabilpuram; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 9e10cdbd2d28c66b036c3c4221ebba553817c5ac Mon Sep 17 00:00:00 2001
From: Nithin Dabilpuram <ndabilpuram@marvell.com>
Date: Wed, 23 Feb 2022 01:05:06 +0530
Subject: [PATCH] net/cnxk: fix inline IPsec security error handling

[ upstream commit ea695031a73ce0e61b9055860eb967406ef8c004 ]

Use raw mbuf free on inline security error to simulate
HW NPA free instead of doing rte_pktmbuf_free(). This
is needed as the callback will not be called from
DPDK lcore.

Fixes: 69daa9e5022b ("net/cnxk: support inline security setup for cn10k")

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/net/cnxk/cn10k_ethdev_sec.c | 37 +++++++++++++++++++++++++----
 1 file changed, 32 insertions(+), 5 deletions(-)

diff --git a/drivers/net/cnxk/cn10k_ethdev_sec.c b/drivers/net/cnxk/cn10k_ethdev_sec.c
index a517421b12..f84a0fe80c 100644
--- a/drivers/net/cnxk/cn10k_ethdev_sec.c
+++ b/drivers/net/cnxk/cn10k_ethdev_sec.c
@@ -139,4 +139,18 @@ static const struct rte_security_capability cn10k_eth_sec_capabilities[] = {
 };
 
+static inline void
+cnxk_pktmbuf_free_no_cache(struct rte_mbuf *mbuf)
+{
+	struct rte_mbuf *next;
+
+	if (!mbuf)
+		return;
+	do {
+		next = mbuf->next;
+		roc_npa_aura_op_free(mbuf->pool->pool_id, 1, (rte_iova_t)mbuf);
+		mbuf = next;
+	} while (mbuf != NULL);
+}
+
 void
 cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args)
@@ -149,4 +163,5 @@ cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args)
 	struct rte_eth_dev *eth_dev;
 	struct cnxk_eth_dev *dev;
+	static uint64_t warn_cnt;
 	uint16_t dlen_adj, rlen;
 	struct rte_mbuf *mbuf;
@@ -162,5 +177,5 @@ cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args)
 		mbuf = (struct rte_mbuf *)(gw[1] - sizeof(struct rte_mbuf));
 		plt_nix_dbg("Received mbuf %p from inline dev inbound", mbuf);
-		rte_pktmbuf_free(mbuf);
+		cnxk_pktmbuf_free_no_cache(mbuf);
 		return;
 	case RTE_EVENT_TYPE_CPU:
@@ -213,8 +228,20 @@ cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args)
 		desc.subtype = RTE_ETH_EVENT_IPSEC_ESN_OVERFLOW;
 		break;
+	case ROC_IE_OT_UCC_ERR_PKT_IP:
+		warn_cnt++;
+		if (warn_cnt % 10000 == 0)
+			plt_warn("Outbound error, bad ip pkt, mbuf %p,"
+				 " sa_index %u (total warnings %" PRIu64 ")",
+				 mbuf, sess_priv.sa_idx, warn_cnt);
+		desc.subtype = RTE_ETH_EVENT_IPSEC_UNKNOWN;
+		break;
 	default:
-		plt_warn("Outbound error, mbuf %p, sa_index %u, "
-			 "compcode %x uc %x", mbuf, sess_priv.sa_idx,
-			 res->compcode, res->uc_compcode);
+		warn_cnt++;
+		if (warn_cnt % 10000 == 0)
+			plt_warn("Outbound error, mbuf %p, sa_index %u,"
+				 " compcode %x uc %x,"
+				 " (total warnings %" PRIu64 ")",
+				 mbuf, sess_priv.sa_idx, res->compcode,
+				 res->uc_compcode, warn_cnt);
 		desc.subtype = RTE_ETH_EVENT_IPSEC_UNKNOWN;
 		break;
@@ -223,5 +250,5 @@ cn10k_eth_sec_sso_work_cb(uint64_t *gw, void *args)
 	desc.metadata = (uint64_t)priv->userdata;
 	rte_eth_dev_callback_process(eth_dev, RTE_ETH_EVENT_IPSEC, &desc);
-	rte_pktmbuf_free(mbuf);
+	cnxk_pktmbuf_free_no_cache(mbuf);
 }
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.908029567 +0000
+++ 0091-net-cnxk-fix-inline-IPsec-security-error-handling.patch	2022-03-01 10:41:01.459244130 +0000
@@ -1 +1 @@
-From ea695031a73ce0e61b9055860eb967406ef8c004 Mon Sep 17 00:00:00 2001
+From 9e10cdbd2d28c66b036c3c4221ebba553817c5ac Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ea695031a73ce0e61b9055860eb967406ef8c004 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index ac45056936..044b20c637 100644
+index a517421b12..f84a0fe80c 100644


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

* patch 'net/cnxk: fix build with GCC 12' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (89 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/cnxk: fix inline IPsec security error handling' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/cnxk: fix RSS RETA table update' " Kevin Traynor
                   ` (11 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Rakesh Kudurumalla; +Cc: Ferruh Yigit, Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 9a8eca798335e2afb3999f2f7a2f3e2a8292ce84 Mon Sep 17 00:00:00 2001
From: Rakesh Kudurumalla <rkudurumalla@marvell.com>
Date: Wed, 23 Feb 2022 15:25:40 +0530
Subject: [PATCH] net/cnxk: fix build with GCC 12

[ upstream commit b526599020ef06811dd08c4f15c0cdf049d7f9f2 ]

Resolve following compilation error with gcc 12 version.
error: storing the address of local variable message in *error.message

Fixes: 26b034f78ca7 ("net/cnxk: support to validate meter policy")

Reported-by: Ferruh Yigit <ferruh.yigit@intel.com>
Signed-off-by: Rakesh Kudurumalla <rkudurumalla@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/net/cnxk/cnxk_ethdev_mtr.c | 59 ++++++++++++++++++++++--------
 1 file changed, 44 insertions(+), 15 deletions(-)

diff --git a/drivers/net/cnxk/cnxk_ethdev_mtr.c b/drivers/net/cnxk/cnxk_ethdev_mtr.c
index 39d8563826..6d14c88e7d 100644
--- a/drivers/net/cnxk/cnxk_ethdev_mtr.c
+++ b/drivers/net/cnxk/cnxk_ethdev_mtr.c
@@ -278,4 +278,45 @@ cnxk_nix_mtr_profile_delete(struct rte_eth_dev *eth_dev, uint32_t profile_id,
 }
 
+static int
+update_mtr_err(uint32_t act_color, struct rte_mtr_error *error, bool action)
+{
+	const char *str;
+	switch (act_color) {
+	case RTE_COLOR_GREEN:
+		if (action) {
+			str = "Green action is not valid";
+			goto notsup;
+		} else {
+			str = "Green action is null";
+			goto notvalid;
+		}
+		break;
+	case RTE_COLOR_YELLOW:
+		if (action) {
+			str = "Yellow action is not valid";
+			goto notsup;
+		} else {
+			str = "Yellow action is null";
+			goto notvalid;
+		}
+		break;
+	case RTE_COLOR_RED:
+		if (action) {
+			str = "Red action is not valid";
+			goto notsup;
+		} else {
+			str = "Red action is null";
+			goto notvalid;
+		}
+		break;
+	}
+notsup:
+	return -rte_mtr_error_set(error, ENOTSUP,
+				  RTE_MTR_ERROR_TYPE_METER_POLICY, NULL, str);
+notvalid:
+	return -rte_mtr_error_set(error, EINVAL,
+				  RTE_MTR_ERROR_TYPE_METER_POLICY, NULL, str);
+}
+
 static int
 cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,
@@ -283,8 +324,6 @@ cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,
 			     struct rte_mtr_error *error)
 {
-	static const char *const action_color[] = {"Green", "Yellow", "Red"};
 	bool supported[RTE_COLORS] = {false, false, false};
 	const struct rte_flow_action *action;
-	char message[1024];
 	uint32_t i;
 
@@ -305,19 +344,9 @@ cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,
 					supported[i] = true;
 
-				if (!supported[i]) {
-					sprintf(message,
-						"%s action is not valid",
-						action_color[i]);
-					return -rte_mtr_error_set(error,
-					  ENOTSUP,
-					  RTE_MTR_ERROR_TYPE_METER_POLICY, NULL,
-					  message);
-				}
+				if (!supported[i])
+					return update_mtr_err(i, error, true);
 			}
 		} else {
-			sprintf(message, "%s action is null", action_color[i]);
-			return -rte_mtr_error_set(error, EINVAL,
-				RTE_MTR_ERROR_TYPE_METER_POLICY, NULL,
-				message);
+			return update_mtr_err(i, error, false);
 		}
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.926973761 +0000
+++ 0092-net-cnxk-fix-build-with-GCC-12.patch	2022-03-01 10:41:01.460244130 +0000
@@ -1 +1 @@
-From b526599020ef06811dd08c4f15c0cdf049d7f9f2 Mon Sep 17 00:00:00 2001
+From 9a8eca798335e2afb3999f2f7a2f3e2a8292ce84 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit b526599020ef06811dd08c4f15c0cdf049d7f9f2 ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index cc783e5f86..c8183aa12d 100644
+index 39d8563826..6d14c88e7d 100644
@@ -23 +24 @@
-@@ -286,4 +286,45 @@ cnxk_nix_mtr_profile_delete(struct rte_eth_dev *eth_dev, uint32_t profile_id,
+@@ -278,4 +278,45 @@ cnxk_nix_mtr_profile_delete(struct rte_eth_dev *eth_dev, uint32_t profile_id,
@@ -69 +70 @@
-@@ -291,8 +332,6 @@ cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,
+@@ -283,8 +324,6 @@ cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,
@@ -78 +79 @@
-@@ -316,19 +355,9 @@ cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,
+@@ -305,19 +344,9 @@ cnxk_nix_mtr_policy_validate(struct rte_eth_dev *dev,


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

* patch 'net/cnxk: fix RSS RETA table update' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (90 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/cnxk: fix build with GCC 12' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'net/i40e: fix unintentional integer overflow' " Kevin Traynor
                   ` (10 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Rakesh Kudurumalla; +Cc: Jerin Jacob, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From d9af841e5a2ad902db734c152288eed0933463af Mon Sep 17 00:00:00 2001
From: Rakesh Kudurumalla <rkudurumalla@marvell.com>
Date: Thu, 24 Feb 2022 14:05:28 +0530
Subject: [PATCH] net/cnxk: fix RSS RETA table update

[ upstream commit fe3833ed2222c369f9b60c0be520dee6e875dcdf ]

RSS reta table is corrupted during rte_eth_dev_rss_reta_update().
Fix it by restoring previous table entries before updating.

Fixes: 00242a687de6 ("net/cnxk: support RETA and RSS hash")

Signed-off-by: Rakesh Kudurumalla <rkudurumalla@marvell.com>
Acked-by: Jerin Jacob <jerinj@marvell.com>
---
 drivers/net/cnxk/cnxk_ethdev_ops.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/cnxk/cnxk_ethdev_ops.c b/drivers/net/cnxk/cnxk_ethdev_ops.c
index 34e4809650..f1d13c5004 100644
--- a/drivers/net/cnxk/cnxk_ethdev_ops.c
+++ b/drivers/net/cnxk/cnxk_ethdev_ops.c
@@ -748,4 +748,6 @@ cnxk_nix_reta_update(struct rte_eth_dev *eth_dev,
 	}
 
+	roc_nix_rss_reta_get(nix, 0, reta);
+
 	/* Copy RETA table */
 	for (i = 0; i < (int)(dev->nix.reta_sz / RTE_ETH_RETA_GROUP_SIZE); i++) {
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.947126607 +0000
+++ 0093-net-cnxk-fix-RSS-RETA-table-update.patch	2022-03-01 10:41:01.461244130 +0000
@@ -1 +1 @@
-From fe3833ed2222c369f9b60c0be520dee6e875dcdf Mon Sep 17 00:00:00 2001
+From d9af841e5a2ad902db734c152288eed0933463af Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit fe3833ed2222c369f9b60c0be520dee6e875dcdf ]
+
@@ -10 +11,0 @@
-Cc: stable@dpdk.org
@@ -19 +20 @@
-index b0a16f3c56..f4a0562475 100644
+index 34e4809650..f1d13c5004 100644
@@ -22 +23 @@
-@@ -858,4 +858,6 @@ cnxk_nix_reta_update(struct rte_eth_dev *eth_dev,
+@@ -748,4 +748,6 @@ cnxk_nix_reta_update(struct rte_eth_dev *eth_dev,


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

* patch 'net/i40e: fix unintentional integer overflow' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (91 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/cnxk: fix RSS RETA table update' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'app/testpmd: fix raw encap of GENEVE option' " Kevin Traynor
                   ` (9 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Steve Yang; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/7565e1a51fdb4940e70d7f8ab15fac6ab048e192

Thanks.

Kevin

---
From 7565e1a51fdb4940e70d7f8ab15fac6ab048e192 Mon Sep 17 00:00:00 2001
From: Steve Yang <stevex.yang@intel.com>
Date: Fri, 25 Feb 2022 02:39:47 +0000
Subject: [PATCH] net/i40e: fix unintentional integer overflow

[ upstream commit df5807658026e7b18493a6c8ebf0e47adee26b4d ]

Cast 1 to type uint64_t to avoid overflow.

CID 375812 (#1 of 1):
Unintentional integer overflow (OVERFLOW_BEFORE_WIDEN)
overflow_before_widen: Potentially overflowing expression 1 << 2 * i + 1
with type int (32 bits, signed) is evaluated using 32-bit arithmetic, and
then used in a context that expects an expression of type uint64_t
(64 bits, unsigned).

Coverity issue: 375812
Fixes: 5fec01c35c49 ("net/i40e: support Linux VF to configure IRQ link list")

Signed-off-by: Steve Yang <stevex.yang@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/i40e/i40e_pf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_pf.c b/drivers/net/i40e/i40e_pf.c
index 2435a8a070..15d9ff868f 100644
--- a/drivers/net/i40e/i40e_pf.c
+++ b/drivers/net/i40e/i40e_pf.c
@@ -598,5 +598,5 @@ i40e_pf_config_irq_link_list(struct i40e_pf_vf *vf,
 	for (i = 0; i < sizeof(vvm->rxq_map) * BITS_PER_CHAR; i++) {
 		if (tempmap & 0x1)
-			linklistmap |= (1 << (2 * i));
+			linklistmap |= RTE_BIT64(2 * i);
 		tempmap >>= 1;
 	}
@@ -605,5 +605,5 @@ i40e_pf_config_irq_link_list(struct i40e_pf_vf *vf,
 	for (i = 0; i < sizeof(vvm->txq_map) * BITS_PER_CHAR; i++) {
 		if (tempmap & 0x1)
-			linklistmap |= (1 << (2 * i + 1));
+			linklistmap |= RTE_BIT64(2 * i + 1);
 		tempmap >>= 1;
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.966377531 +0000
+++ 0094-net-i40e-fix-unintentional-integer-overflow.patch	2022-03-01 10:41:01.462244130 +0000
@@ -1 +1 @@
-From df5807658026e7b18493a6c8ebf0e47adee26b4d Mon Sep 17 00:00:00 2001
+From 7565e1a51fdb4940e70d7f8ab15fac6ab048e192 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit df5807658026e7b18493a6c8ebf0e47adee26b4d ]
+
@@ -17 +18,0 @@
-Cc: stable@dpdk.org


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

* patch 'app/testpmd: fix raw encap of GENEVE option' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (92 preceding siblings ...)
  2022-03-01 10:42 ` patch 'net/i40e: fix unintentional integer overflow' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'app/testpmd: fix build without drivers' " Kevin Traynor
                   ` (8 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Bing Zhao; +Cc: Viacheslav Ovsiienko, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From a0a07048f33ea47cf8d4ac34e1d8c7d60d8c0aa9 Mon Sep 17 00:00:00 2001
From: Bing Zhao <bingz@nvidia.com>
Date: Thu, 24 Feb 2022 09:02:14 +0200
Subject: [PATCH] app/testpmd: fix raw encap of GENEVE option

[ upstream commit d9e597141fd3a69278c31b1daf6da7ce54de3b8e ]

The structure "rte_flow_item_geneve_opt" is not a protocol header of
geneve tunnel option from rfc8926. The field "data" is a pointer
which points to the actual variable-length option data. So the
structure is not packed.

There is 4 bytes hole before the pointer in a 64-bit system. The
option header is just 4 bytes. When using offsetof() to get the
fixed part's size of option header, the wrong value 8 was got. When
constructing the encap header, a wrong size and offset was used due
to this hole.

With this commit, the fixed part's size is calculated explicitly
based on all fields.

Fixes: 55c074f3ba1d ("app/testpmd: support GENEVE option item")

Signed-off-by: Bing Zhao <bingz@nvidia.com>
Reviewed-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
---
 app/test-pmd/cmdline_flow.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/app/test-pmd/cmdline_flow.c b/app/test-pmd/cmdline_flow.c
index bbaf18d76e..a8140eda92 100644
--- a/app/test-pmd/cmdline_flow.c
+++ b/app/test-pmd/cmdline_flow.c
@@ -9156,5 +9156,6 @@ cmd_set_raw_parsed(const struct buffer *in)
 			opt = (const struct rte_flow_item_geneve_opt *)
 								item->spec;
-			size = offsetof(struct rte_flow_item_geneve_opt, data);
+			size = offsetof(struct rte_flow_item_geneve_opt,
+					option_len) + sizeof(uint8_t);
 			if (opt->option_len && opt->data) {
 				*total_size += opt->option_len *
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:03.986381410 +0000
+++ 0095-app-testpmd-fix-raw-encap-of-GENEVE-option.patch	2022-03-01 10:41:01.468244132 +0000
@@ -1 +1 @@
-From d9e597141fd3a69278c31b1daf6da7ce54de3b8e Mon Sep 17 00:00:00 2001
+From a0a07048f33ea47cf8d4ac34e1d8c7d60d8c0aa9 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d9e597141fd3a69278c31b1daf6da7ce54de3b8e ]
+
@@ -21 +22,0 @@
-Cc: stable@dpdk.org
@@ -30 +31 @@
-index b5f1191e55..4f7a9f17f9 100644
+index bbaf18d76e..a8140eda92 100644
@@ -33 +34 @@
-@@ -10967,5 +10967,6 @@ cmd_set_raw_parsed(const struct buffer *in)
+@@ -9156,5 +9156,6 @@ cmd_set_raw_parsed(const struct buffer *in)


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

* patch 'app/testpmd: fix build without drivers' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (93 preceding siblings ...)
  2022-03-01 10:42 ` patch 'app/testpmd: fix raw encap of GENEVE option' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'doc: add CUDA driver features' " Kevin Traynor
                   ` (7 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Bruce Richardson, Ajit Khaparde, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/460bf32d2d5557748e7bccf85a2156817299ecbc

Thanks.

Kevin

---
From 460bf32d2d5557748e7bccf85a2156817299ecbc Mon Sep 17 00:00:00 2001
From: Thomas Monjalon <thomas@monjalon.net>
Date: Fri, 25 Feb 2022 16:26:53 +0100
Subject: [PATCH] app/testpmd: fix build without drivers

[ upstream commit 1a2eaefa47ba1e0e199cfe8a4653a5023425bce5 ]

When ixgbe and bnxt are disabled, compilation was failing:

app/test-pmd/cmdline.c:9396:11: error:
	variable 'vf_rxmode' set but not used

Fixes: 4cfe399f6550 ("net/bnxt: support to set VF rxmode")

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 app/test-pmd/cmdline.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index 16ad4be005..69501d0deb 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -9287,4 +9287,5 @@ cmd_set_vf_rxmode_parsed(void *parsed_result,
 
 	RTE_SET_USED(is_on);
+	RTE_SET_USED(vf_rxmode);
 
 #ifdef RTE_NET_IXGBE
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.011077927 +0000
+++ 0096-app-testpmd-fix-build-without-drivers.patch	2022-03-01 10:41:01.481244134 +0000
@@ -1 +1 @@
-From 1a2eaefa47ba1e0e199cfe8a4653a5023425bce5 Mon Sep 17 00:00:00 2001
+From 460bf32d2d5557748e7bccf85a2156817299ecbc Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 1a2eaefa47ba1e0e199cfe8a4653a5023425bce5 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index b4ba8da2b0..7ab0575e64 100644
+index 16ad4be005..69501d0deb 100644
@@ -25 +26 @@
-@@ -9410,4 +9410,5 @@ cmd_set_vf_rxmode_parsed(void *parsed_result,
+@@ -9287,4 +9287,5 @@ cmd_set_vf_rxmode_parsed(void *parsed_result,


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

* patch 'doc: add CUDA driver features' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (94 preceding siblings ...)
  2022-03-01 10:42 ` patch 'app/testpmd: fix build without drivers' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'test/efd: fix sockets mask size' " Kevin Traynor
                   ` (6 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Elena Agostini; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 5ac4050f2760e2a5fa2e1348ccfac2d0d556130b Mon Sep 17 00:00:00 2001
From: Elena Agostini <eagostini@nvidia.com>
Date: Fri, 25 Feb 2022 03:12:25 +0000
Subject: [PATCH] doc: add CUDA driver features

[ upstream commit 8b6502f28685eb6395292470ff28e1ff3271aa32 ]

The features list were missed when introducing the driver.

Fixes: 1306a73b1958 ("gpu/cuda: introduce CUDA driver")

Signed-off-by: Elena Agostini <eagostini@nvidia.com>
---
 doc/guides/gpus/features/cuda.ini | 10 ++++++++++
 1 file changed, 10 insertions(+)
 create mode 100644 doc/guides/gpus/features/cuda.ini

diff --git a/doc/guides/gpus/features/cuda.ini b/doc/guides/gpus/features/cuda.ini
new file mode 100644
index 0000000000..9d587eed6e
--- /dev/null
+++ b/doc/guides/gpus/features/cuda.ini
@@ -0,0 +1,10 @@
+;
+; Supported features of the 'cuda' gpu driver.
+;
+; Refer to default.ini for the full list of available PMD features.
+;
+[Features]
+Get device info                = Y
+Share CPU memory with device   = Y
+Allocate device memory         = Y
+Free memory                    = Y
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.041533067 +0000
+++ 0097-doc-add-CUDA-driver-features.patch	2022-03-01 10:41:01.482244134 +0000
@@ -1 +1 @@
-From 8b6502f28685eb6395292470ff28e1ff3271aa32 Mon Sep 17 00:00:00 2001
+From 5ac4050f2760e2a5fa2e1348ccfac2d0d556130b Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 8b6502f28685eb6395292470ff28e1ff3271aa32 ]
+
@@ -9 +10,0 @@
-Cc: stable@dpdk.org


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

* patch 'test/efd: fix sockets mask size' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (95 preceding siblings ...)
  2022-03-01 10:42 ` patch 'doc: add CUDA driver features' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'efd: fix uninitialized structure' " Kevin Traynor
                   ` (5 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: Yipeng Wang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From 8fdb8b8a7d8a0bba1c1ee57e6253f5b64b0b3af2 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Fri, 25 Feb 2022 09:27:44 +0000
Subject: [PATCH] test/efd: fix sockets mask size

[ upstream commit 3b0e34e80b55bbd683f4aa8257e25cbea029489b ]

Constant value 1 has a size of 32 bits, and shifting it more than 32 bits
to the left overflows. 1ULL is needed to be able to get a 64-bit value.

Coverity ID: 375846
Fixes: 8751a7e9832b ("efd: allow more CPU sockets in table creation")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Yipeng Wang <yipeng1.wang@intel.com>
---
 app/test/test_efd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/test/test_efd.c b/app/test/test_efd.c
index 1b249e0447..c10c48cf37 100644
--- a/app/test/test_efd.c
+++ b/app/test/test_efd.c
@@ -99,5 +99,5 @@ static inline uint64_t efd_get_all_sockets_bitmask(void)
 	const int val_true = 1, val_false = 0;
 	for (i = 0; i < rte_lcore_count(); i++) {
-		all_cpu_sockets_bitmask |= 1 << rte_lcore_to_socket_id(next_lcore);
+		all_cpu_sockets_bitmask |= 1ULL << rte_lcore_to_socket_id(next_lcore);
 		next_lcore = rte_get_next_lcore(next_lcore, val_false, val_true);
 	}
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.060784594 +0000
+++ 0098-test-efd-fix-sockets-mask-size.patch	2022-03-01 10:41:01.482244134 +0000
@@ -1 +1 @@
-From 3b0e34e80b55bbd683f4aa8257e25cbea029489b Mon Sep 17 00:00:00 2001
+From 8fdb8b8a7d8a0bba1c1ee57e6253f5b64b0b3af2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 3b0e34e80b55bbd683f4aa8257e25cbea029489b ]
+
@@ -11 +12,0 @@
-Cc: stable@dpdk.org
@@ -20 +21 @@
-index 7bea674086..fa29e8f97a 100644
+index 1b249e0447..c10c48cf37 100644
@@ -23 +24 @@
-@@ -108,5 +108,5 @@ static inline uint64_t efd_get_all_sockets_bitmask(void)
+@@ -99,5 +99,5 @@ static inline uint64_t efd_get_all_sockets_bitmask(void)


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

* patch 'efd: fix uninitialized structure' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (96 preceding siblings ...)
  2022-03-01 10:42 ` patch 'test/efd: fix sockets mask size' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'distributor: fix potential overflow' " Kevin Traynor
                   ` (4 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: Yipeng Wang, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/30b5a4b8889977dc4adf1f5bd906a530634f0db4

Thanks.

Kevin

---
From 30b5a4b8889977dc4adf1f5bd906a530634f0db4 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Fri, 25 Feb 2022 09:27:45 +0000
Subject: [PATCH] efd: fix uninitialized structure

[ upstream commit ecda2c40ac549f2ebd1e8be6bf0a96c4aba6bf36 ]

Coverity flags that both elements of efd_online_group_entry
are used uninitialized. This is OK because this structure
is initially used for starting values, so any value is OK.

Coverity ID: 375868
Fixes: 56b6ef874f80 ("efd: new Elastic Flow Distributor library")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Yipeng Wang <yipeng1.wang@intel.com>
---
 lib/efd/rte_efd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/efd/rte_efd.c b/lib/efd/rte_efd.c
index 86ef46863c..6c794d7750 100644
--- a/lib/efd/rte_efd.c
+++ b/lib/efd/rte_efd.c
@@ -1166,5 +1166,5 @@ rte_efd_update(struct rte_efd_table * const table, const unsigned int socket_id,
 	uint32_t chunk_id = 0, group_id = 0, bin_id = 0;
 	uint8_t new_bin_choice = 0;
-	struct efd_online_group_entry entry;
+	struct efd_online_group_entry entry = {{0}};
 
 	int status = efd_compute_update(table, socket_id, key, value,
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.080055199 +0000
+++ 0099-efd-fix-uninitialized-structure.patch	2022-03-01 10:41:01.483244134 +0000
@@ -1 +1 @@
-From ecda2c40ac549f2ebd1e8be6bf0a96c4aba6bf36 Mon Sep 17 00:00:00 2001
+From 30b5a4b8889977dc4adf1f5bd906a530634f0db4 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit ecda2c40ac549f2ebd1e8be6bf0a96c4aba6bf36 ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 560cd78961..bbc6fc585d 100644
+index 86ef46863c..6c794d7750 100644
@@ -24 +25 @@
-@@ -1163,5 +1163,5 @@ rte_efd_update(struct rte_efd_table * const table, const unsigned int socket_id,
+@@ -1166,5 +1166,5 @@ rte_efd_update(struct rte_efd_table * const table, const unsigned int socket_id,


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

* patch 'distributor: fix potential overflow' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (97 preceding siblings ...)
  2022-03-01 10:42 ` patch 'efd: fix uninitialized structure' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'eal/linux: fix illegal memory access in uevent handler' " Kevin Traynor
                   ` (3 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Bruce Richardson; +Cc: David Hunt, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/32f77d388449d619264babe3e64d0aeca0a25c58

Thanks.

Kevin

---
From 32f77d388449d619264babe3e64d0aeca0a25c58 Mon Sep 17 00:00:00 2001
From: Bruce Richardson <bruce.richardson@intel.com>
Date: Thu, 17 Feb 2022 15:02:39 +0000
Subject: [PATCH] distributor: fix potential overflow

[ upstream commit 9699b09803b799ddc11abedffb17af059c992e9a ]

Coverity flags the fact that the tag values used in distributor are
32-bit, which means that when we use bit-manipulation to convert a tag
match/no-match to a bit in an array, we need to typecast to a 64-bit
type before shifting past 32 bits.

Coverity issue: 375808
Fixes: 08ccf3faa6a9 ("distributor: new packet distributor library")

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: David Hunt <david.hunt@intel.com>
---
 lib/distributor/rte_distributor_single.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/distributor/rte_distributor_single.c b/lib/distributor/rte_distributor_single.c
index b653620688..60ca86152f 100644
--- a/lib/distributor/rte_distributor_single.c
+++ b/lib/distributor/rte_distributor_single.c
@@ -248,6 +248,5 @@ rte_distributor_process_single(struct rte_distributor_single *d,
 			 */
 			for (i = 0; i < d->num_workers; i++)
-				match |= (!(d->in_flight_tags[i] ^ new_tag)
-					<< i);
+				match |= ((uint64_t)!(d->in_flight_tags[i] ^ new_tag) << i);
 
 			/* Only turned-on bits are considered as match */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.099678834 +0000
+++ 0100-distributor-fix-potential-overflow.patch	2022-03-01 10:41:01.484244135 +0000
@@ -1 +1 @@
-From 9699b09803b799ddc11abedffb17af059c992e9a Mon Sep 17 00:00:00 2001
+From 32f77d388449d619264babe3e64d0aeca0a25c58 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 9699b09803b799ddc11abedffb17af059c992e9a ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -22 +23 @@
-index de90aa8bb5..2c77ac454a 100644
+index b653620688..60ca86152f 100644
@@ -25 +26 @@
-@@ -246,6 +246,5 @@ rte_distributor_process_single(struct rte_distributor_single *d,
+@@ -248,6 +248,5 @@ rte_distributor_process_single(struct rte_distributor_single *d,


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

* patch 'eal/linux: fix illegal memory access in uevent handler' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (98 preceding siblings ...)
  2022-03-01 10:42 ` patch 'distributor: fix potential overflow' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'devargs: fix crash with uninitialized parsing' " Kevin Traynor
                   ` (2 subsequent siblings)
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Steve Yang; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/411a43ea5d58e27534b5a7615448b70eaddd93a7

Thanks.

Kevin

---
From 411a43ea5d58e27534b5a7615448b70eaddd93a7 Mon Sep 17 00:00:00 2001
From: Steve Yang <stevex.yang@intel.com>
Date: Wed, 23 Feb 2022 08:49:50 +0000
Subject: [PATCH] eal/linux: fix illegal memory access in uevent handler

[ upstream commit 1a287fc9c95bd6245c119b20f07382cf4b8fefa4 ]

'recv()' fills the 'buf', later 'strlcpy()' used to copy from this buffer.
But as coverity warns 'recv()' doesn't guarantee that 'buf' is
null-terminated, but 'strlcpy()' requires it.

Enlarge 'buf' size to 'EAL_UEV_MSG_LEN + 1' and ensure the last one can
be set to 0 when received buffer size is EAL_UEV_MSG_LEN.

CID 375864:  Memory - illegal accesses  (STRING_NULL)
Passing unterminated string "buf" to "dev_uev_parse", which expects
a null-terminated string.

Coverity issue: 375864
Fixes: 0d0f478d0483 ("eal/linux: add uevent parse and process")

Signed-off-by: Steve Yang <stevex.yang@intel.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 lib/eal/linux/eal_dev.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/eal/linux/eal_dev.c b/lib/eal/linux/eal_dev.c
index bde55a3d92..851789e85c 100644
--- a/lib/eal/linux/eal_dev.c
+++ b/lib/eal/linux/eal_dev.c
@@ -232,5 +232,5 @@ dev_uev_handler(__rte_unused void *param)
 	struct rte_dev_event uevent;
 	int ret;
-	char buf[EAL_UEV_MSG_LEN];
+	char buf[EAL_UEV_MSG_LEN + 1];
 	struct rte_bus *bus;
 	struct rte_device *dev;
@@ -238,5 +238,5 @@ dev_uev_handler(__rte_unused void *param)
 
 	memset(&uevent, 0, sizeof(struct rte_dev_event));
-	memset(buf, 0, EAL_UEV_MSG_LEN);
+	memset(buf, 0, EAL_UEV_MSG_LEN + 1);
 
 	if (rte_intr_fd_get(intr_handle) < 0)
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.118987672 +0000
+++ 0101-eal-linux-fix-illegal-memory-access-in-uevent-handle.patch	2022-03-01 10:41:01.484244135 +0000
@@ -1 +1 @@
-From 1a287fc9c95bd6245c119b20f07382cf4b8fefa4 Mon Sep 17 00:00:00 2001
+From 411a43ea5d58e27534b5a7615448b70eaddd93a7 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 1a287fc9c95bd6245c119b20f07382cf4b8fefa4 ]
+
@@ -19 +20,0 @@
-Cc: stable@dpdk.org
@@ -28 +29 @@
-index f6e5861221..e6f509bcff 100644
+index bde55a3d92..851789e85c 100644
@@ -31 +32 @@
-@@ -228,5 +228,5 @@ dev_uev_handler(__rte_unused void *param)
+@@ -232,5 +232,5 @@ dev_uev_handler(__rte_unused void *param)
@@ -38 +39 @@
-@@ -234,5 +234,5 @@ dev_uev_handler(__rte_unused void *param)
+@@ -238,5 +238,5 @@ dev_uev_handler(__rte_unused void *param)


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

* patch 'devargs: fix crash with uninitialized parsing' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (99 preceding siblings ...)
  2022-03-01 10:42 ` patch 'eal/linux: fix illegal memory access in uevent handler' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:42 ` patch 'bus/pci: assign driver pointer before mapping' " Kevin Traynor
  2022-03-01 10:43 ` patch 'kni: fix freeing order in device release' " Kevin Traynor
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Madhuker Mythri; +Cc: Gaetan Rivet, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From d3e4a2c2e6c897b944c459c8b09e9f4ceab4e956 Mon Sep 17 00:00:00 2001
From: Madhuker Mythri <madhuker.mythri@oracle.com>
Date: Mon, 14 Feb 2022 22:38:11 +0530
Subject: [PATCH] devargs: fix crash with uninitialized parsing

[ upstream commit 356a2aa054a9e803782ee8380a7ab1a53aecd1e3 ]

The function rte_devargs_parse() previously was safe to call with
non-initialized devargs structure as parameter.

When adding the support for the global device syntax,
this assumption was broken.
Restore it by forcing memset as part of the call itself.

Bugzilla ID: 933
Fixes: b344eb5d941a ("devargs: parse global device syntax")

Signed-off-by: Madhuker Mythri <madhuker.mythri@oracle.com>
Signed-off-by: Gaetan Rivet <grive@u256.net>
---
 lib/eal/common/eal_common_devargs.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/eal/common/eal_common_devargs.c b/lib/eal/common/eal_common_devargs.c
index 8c7650cf6c..184fe676aa 100644
--- a/lib/eal/common/eal_common_devargs.c
+++ b/lib/eal/common/eal_common_devargs.c
@@ -192,4 +192,5 @@ rte_devargs_parse(struct rte_devargs *da, const char *dev)
 	if (da == NULL)
 		return -EINVAL;
+	memset(da, 0, sizeof(*da));
 
 	/* First parse according global device syntax. */
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.137334324 +0000
+++ 0102-devargs-fix-crash-with-uninitialized-parsing.patch	2022-03-01 10:41:01.485244135 +0000
@@ -1 +1 @@
-From 356a2aa054a9e803782ee8380a7ab1a53aecd1e3 Mon Sep 17 00:00:00 2001
+From d3e4a2c2e6c897b944c459c8b09e9f4ceab4e956 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 356a2aa054a9e803782ee8380a7ab1a53aecd1e3 ]
+
@@ -15 +16,0 @@
-Cc: stable@dpdk.org
@@ -24 +25 @@
-index 8da3ba3879..d5833af373 100644
+index 8c7650cf6c..184fe676aa 100644
@@ -27 +28 @@
-@@ -190,4 +190,5 @@ rte_devargs_parse(struct rte_devargs *da, const char *dev)
+@@ -192,4 +192,5 @@ rte_devargs_parse(struct rte_devargs *da, const char *dev)


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

* patch 'bus/pci: assign driver pointer before mapping' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (100 preceding siblings ...)
  2022-03-01 10:42 ` patch 'devargs: fix crash with uninitialized parsing' " Kevin Traynor
@ 2022-03-01 10:42 ` Kevin Traynor
  2022-03-01 10:43 ` patch 'kni: fix freeing order in device release' " Kevin Traynor
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:42 UTC (permalink / raw)
  To: Michal Krawczyk; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable/commit/86598c1b6ff6f92be28ca692d4c75bd0e74a74d2

Thanks.

Kevin

---
From 86598c1b6ff6f92be28ca692d4c75bd0e74a74d2 Mon Sep 17 00:00:00 2001
From: Michal Krawczyk <mk@semihalf.com>
Date: Wed, 19 Jan 2022 15:50:37 +0100
Subject: [PATCH] bus/pci: assign driver pointer before mapping

[ upstream commit 6b92f184680283b4b3da4ebc722b5feb7ef280fb ]

Patch changing the way of accessing interrupt handle also changed order
of the rte_pci_map_device() call and rte_pci_device:driver assignment.
It was causing issues with Write Combine mapping on the Linux platform
if it was used with the igb_uio module.

Linux implementation of pci_uio_map_resource_by_index(), which is called
by rte_pci_map_device(), needs access to the device's driver. Otherwise
it won't be able to check the driver's flags and won't respect them.

Fixes: d61138d4f0e2 ("drivers: remove direct access to interrupt handle")

Signed-off-by: Michal Krawczyk <mk@semihalf.com>
---
 drivers/bus/pci/pci_common.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/bus/pci/pci_common.c b/drivers/bus/pci/pci_common.c
index 4a3a87f24f..def372b67e 100644
--- a/drivers/bus/pci/pci_common.c
+++ b/drivers/bus/pci/pci_common.c
@@ -248,7 +248,10 @@ rte_pci_probe_one_driver(struct rte_pci_driver *dr,
 		}
 
+		dev->driver = dr;
+
 		if (dr->drv_flags & RTE_PCI_DRV_NEED_MAPPING) {
 			ret = rte_pci_map_device(dev);
 			if (ret != 0) {
+				dev->driver = NULL;
 				rte_intr_instance_free(dev->vfio_req_intr_handle);
 				dev->vfio_req_intr_handle = NULL;
@@ -258,6 +261,4 @@ rte_pci_probe_one_driver(struct rte_pci_driver *dr,
 			}
 		}
-
-		dev->driver = dr;
 	}
 
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.157113135 +0000
+++ 0103-bus-pci-assign-driver-pointer-before-mapping.patch	2022-03-01 10:41:01.485244135 +0000
@@ -1 +1 @@
-From 6b92f184680283b4b3da4ebc722b5feb7ef280fb Mon Sep 17 00:00:00 2001
+From 86598c1b6ff6f92be28ca692d4c75bd0e74a74d2 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 6b92f184680283b4b3da4ebc722b5feb7ef280fb ]
+
@@ -16 +17,0 @@
-Cc: stable@dpdk.org


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

* patch 'kni: fix freeing order in device release' has been queued to stable release 21.11.1
  2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
                   ` (101 preceding siblings ...)
  2022-03-01 10:42 ` patch 'bus/pci: assign driver pointer before mapping' " Kevin Traynor
@ 2022-03-01 10:43 ` Kevin Traynor
  102 siblings, 0 replies; 105+ messages in thread
From: Kevin Traynor @ 2022-03-01 10:43 UTC (permalink / raw)
  To: Huisong Li; +Cc: Min Hu, Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to stable release 21.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable

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

Thanks.

Kevin

---
From e253ba61da1e047ea2061d4ec700d32e9f43db48 Mon Sep 17 00:00:00 2001
From: Huisong Li <lihuisong@huawei.com>
Date: Wed, 9 Feb 2022 15:35:25 +0800
Subject: [PATCH] kni: fix freeing order in device release

[ upstream commit d57f2899e29a74fffeb876863e1f570084d6437b ]

The "kni_dev" is the private data of the "net_device" in kni, and allocated
with the "net_device" by calling "alloc_netdev()". The "net_device" is
freed by calling "free_netdev()" when kni release. The freed memory
includes the "kni_dev". So after "kni_dev" should not be accessed after
"net_device" is released.

Fixes: e77fec694936 ("kni: fix possible mbuf leaks and speed up port release")

KASAN trace:

[   85.263717] ==========================================================
[   85.264418] BUG: KASAN: use-after-free in kni_net_release_fifo_phy+
		0x30/0x84 [rte_kni]
[   85.265139] Read of size 8 at addr ffff000260668d60 by task kni/341
[   85.265703]
[   85.265857] CPU: 0 PID: 341 Comm: kni Tainted: G     U     O
		5.15.0-rc4+ #1
[   85.266525] Hardware name: linux,dummy-virt (DT)
[   85.266968] Call trace:
[   85.267220]  dump_backtrace+0x0/0x2d0
[   85.267591]  show_stack+0x24/0x30
[   85.267924]  dump_stack_lvl+0x8c/0xb8
[   85.268294]  print_address_description.constprop.0+0x74/0x2b8
[   85.268855]  kasan_report+0x1e4/0x200
[   85.269224]  __asan_load8+0x98/0xd4
[   85.269577]  kni_net_release_fifo_phy+0x30/0x84 [rte_kni]
[   85.270116]  kni_dev_remove.isra.0+0x50/0x64 [rte_kni]
[   85.270630]  kni_ioctl_release+0x254/0x320 [rte_kni]
[   85.271136]  kni_ioctl+0x64/0xb0 [rte_kni]
[   85.271553]  __arm64_sys_ioctl+0xdc/0x120
[   85.271955]  invoke_syscall+0x68/0x1a0
[   85.272332]  el0_svc_common.constprop.0+0x90/0x200
[   85.272807]  do_el0_svc+0x94/0xa4
[   85.273144]  el0_svc+0x78/0x240
[   85.273463]  el0t_64_sync_handler+0x1a8/0x1b0
[   85.273895]  el0t_64_sync+0x1a0/0x1a4
[   85.274264]
[   85.274427] Allocated by task 341:
[   85.274767]  kasan_save_stack+0x2c/0x60
[   85.275157]  __kasan_kmalloc+0x90/0xb4
[   85.275533]  __kmalloc_node+0x230/0x594
[   85.275917]  kvmalloc_node+0x8c/0x190
[   85.276286]  alloc_netdev_mqs+0x70/0x6b0
[   85.276678]  kni_ioctl_create+0x224/0xf40 [rte_kni]
[   85.277166]  kni_ioctl+0x9c/0xb0 [rte_kni]
[   85.277581]  __arm64_sys_ioctl+0xdc/0x120
[   85.277980]  invoke_syscall+0x68/0x1a0
[   85.278357]  el0_svc_common.constprop.0+0x90/0x200
[   85.278830]  do_el0_svc+0x94/0xa4
[   85.279172]  el0_svc+0x78/0x240
[   85.279491]  el0t_64_sync_handler+0x1a8/0x1b0
[   85.279925]  el0t_64_sync+0x1a0/0x1a4
[   85.280292]
[   85.280454] Freed by task 341:
[   85.280763]  kasan_save_stack+0x2c/0x60
[   85.281147]  kasan_set_track+0x2c/0x40
[   85.281522]  kasan_set_free_info+0x2c/0x50
[   85.281930]  __kasan_slab_free+0xdc/0x140
[   85.282331]  slab_free_freelist_hook+0x90/0x250
[   85.282782]  kfree+0x128/0x580
[   85.283099]  kvfree+0x48/0x60
[   85.283402]  netdev_freemem+0x34/0x44
[   85.283770]  netdev_release+0x50/0x64
[   85.284138]  device_release+0xa0/0x120
[   85.284516]  kobject_put+0xf8/0x160
[   85.284867]  put_device+0x20/0x30
[   85.285204]  free_netdev+0x22c/0x310
[   85.285562]  kni_dev_remove.isra.0+0x48/0x64 [rte_kni]
[   85.286076]  kni_ioctl_release+0x254/0x320 [rte_kni]
[   85.286573]  kni_ioctl+0x64/0xb0 [rte_kni]
[   85.286992]  __arm64_sys_ioctl+0xdc/0x120
[   85.287392]  invoke_syscall+0x68/0x1a0
[   85.287769]  el0_svc_common.constprop.0+0x90/0x200
[   85.288243]  do_el0_svc+0x94/0xa4
[   85.288579]  el0_svc+0x78/0x240
[   85.288899]  el0t_64_sync_handler+0x1a8/0x1b0
[   85.289332]  el0t_64_sync+0x1a0/0x1a4
[   85.289699]
[   85.289862] The buggy address belongs to the object at ffff000260668000
[   85.289862]  which belongs to the cache kmalloc-cg-8k of size 8192
[   85.291079] The buggy address is located 3424 bytes inside of
[   85.291079]  8192-byte region [ffff000260668000, ffff00026066a000)
[   85.292213] The buggy address belongs to the page:
[   85.292684] page:(____ptrval____) refcount:1 mapcount:0 mapping:
		0000000000000000 index:0x0 pfn:0x2a0668
[   85.293585] head:(____ptrval____) order:3 compound_mapcount:0
		compound_pincount:0
[   85.294305] flags: 0xbfff80000010200(slab|head|node=0|zone=2|
		lastcpupid=0x7fff)
[   85.295020] raw: 0bfff80000010200 0000000000000000 dead000000000122
		ffff0000c000d680
[   85.295767] raw: 0000000000000000 0000000080020002 00000001ffffffff
		0000000000000000
[   85.296512] page dumped because: kasan: bad access detected
[   85.297054]
[   85.297217] Memory state around the buggy address:
[   85.297688]  ffff000260668c00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb
		fb fb
[   85.298384]  ffff000260668c80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb
		fb fb
[   85.299088] >ffff000260668d00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb
		fb fb
[   85.299781]                                                        ^
[   85.300396]  ffff000260668d80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb
		fb fb
[   85.301092]  ffff000260668e00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb
		fb fb
[   85.301787] ===========================================================

Signed-off-by: Huisong Li <lihuisong@huawei.com>
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 kernel/linux/kni/kni_misc.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/kernel/linux/kni/kni_misc.c b/kernel/linux/kni/kni_misc.c
index f10dcd069d..ad1582d911 100644
--- a/kernel/linux/kni/kni_misc.c
+++ b/kernel/linux/kni/kni_misc.c
@@ -185,4 +185,10 @@ kni_dev_remove(struct kni_dev *dev)
 		return -ENODEV;
 
+	/*
+	 * The memory of kni device is allocated and released together
+	 * with net device. Release mbuf before freeing net device.
+	 */
+	kni_net_release_fifo_phy(dev);
+
 	if (dev->net_dev) {
 		unregister_netdev(dev->net_dev);
@@ -190,6 +196,4 @@ kni_dev_remove(struct kni_dev *dev)
 	}
 
-	kni_net_release_fifo_phy(dev);
-
 	return 0;
 }
@@ -221,6 +225,6 @@ kni_release(struct inode *inode, struct file *file)
 		}
 
-		kni_dev_remove(dev);
 		list_del(&dev->list);
+		kni_dev_remove(dev);
 	}
 	up_write(&knet->kni_list_lock);
@@ -471,6 +475,6 @@ kni_ioctl_release(struct net *net, uint32_t ioctl_num,
 		}
 
-		kni_dev_remove(dev);
 		list_del(&dev->list);
+		kni_dev_remove(dev);
 		ret = 0;
 		break;
-- 
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-03-01 10:41:04.176198173 +0000
+++ 0104-kni-fix-freeing-order-in-device-release.patch	2022-03-01 10:41:01.486244135 +0000
@@ -1 +1 @@
-From d57f2899e29a74fffeb876863e1f570084d6437b Mon Sep 17 00:00:00 2001
+From e253ba61da1e047ea2061d4ec700d32e9f43db48 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit d57f2899e29a74fffeb876863e1f570084d6437b ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org
@@ -124 +125 @@
-index ec70190042..780187d8bf 100644
+index f10dcd069d..ad1582d911 100644
@@ -127 +128 @@
-@@ -183,4 +183,10 @@ kni_dev_remove(struct kni_dev *dev)
+@@ -185,4 +185,10 @@ kni_dev_remove(struct kni_dev *dev)
@@ -138 +139 @@
-@@ -188,6 +194,4 @@ kni_dev_remove(struct kni_dev *dev)
+@@ -190,6 +196,4 @@ kni_dev_remove(struct kni_dev *dev)
@@ -145 +146 @@
-@@ -219,6 +223,6 @@ kni_release(struct inode *inode, struct file *file)
+@@ -221,6 +225,6 @@ kni_release(struct inode *inode, struct file *file)
@@ -153 +154 @@
-@@ -469,6 +473,6 @@ kni_ioctl_release(struct net *net, uint32_t ioctl_num,
+@@ -471,6 +475,6 @@ kni_ioctl_release(struct net *net, uint32_t ioctl_num,


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

* RE: patch 'examples/qos_sched: fix core mask overflow' has been queued to stable release 21.11.1
  2022-03-01 10:41 ` patch 'examples/qos_sched: fix core mask overflow' " Kevin Traynor
@ 2022-03-01 18:28   ` Ajmera, Megha
  0 siblings, 0 replies; 105+ messages in thread
From: Ajmera, Megha @ 2022-03-01 18:28 UTC (permalink / raw)
  To: Kevin Traynor; +Cc: Morten Brørup, dpdk stable

Please go ahead and apply to the branch.

Regards,
Megha

> -----Original Message-----
> From: Kevin Traynor <ktraynor@redhat.com>
> Sent: Tuesday, March 01, 2022 4:12 PM
> To: Ajmera, Megha <megha.ajmera@intel.com>
> Cc: Morten Brørup <mb@smartsharesystems.com>; dpdk stable
> <stable@dpdk.org>
> Subject: patch 'examples/qos_sched: fix core mask overflow' has been queued
> to stable release 21.11.1
> 
> Hi,
> 
> FYI, your patch has been queued to stable release 21.11.1
> 
> Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
> It will be pushed if I get no objections before 03/06/22. 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/kevintraynor/dpdk-stable
> 
> This queued commit can be viewed at:
> https://github.com/kevintraynor/dpdk-
> stable/commit/d33bb6bd28406944b31ad53ba90199ca5f2f114f
> 
> Thanks.
> 
> Kevin
> 
> ---
> From d33bb6bd28406944b31ad53ba90199ca5f2f114f Mon Sep 17 00:00:00
> 2001
> From: Megha Ajmera <megha.ajmera@intel.com>
> Date: Wed, 23 Feb 2022 17:36:30 +0000
> Subject: [PATCH] examples/qos_sched: fix core mask overflow
> MIME-Version: 1.0
> Content-Type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: 8bit
> 
> [ upstream commit 9c9fad3dfa042ae4b7a045cb1731f8701f8210e6 ]
> 
> Masking of core mask was incorrect. Instead of using 1U for shifting, it should
> be using 1LU as the result is assigned to uint64.
> 
> CID 375859: Potentially overflowing expression "1U << app_main_core" with
> type "unsigned int" (32 bits, unsigned) is evaluated using 32-bit arithmetic, and
> then used in a context that expects an expression of type "uint64_t" (64 bits,
> unsigned).
> 
> Coverity issue: 375859
> Fixes: de3cfa2c9823 ("sched: initial import")
> 
> Signed-off-by: Megha Ajmera <megha.ajmera@intel.com>
> Acked-by: Morten Brørup <mb@smartsharesystems.com>
> ---
>  examples/qos_sched/args.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/examples/qos_sched/args.c b/examples/qos_sched/args.c index
> 10ca7bea61..ff51d0215a 100644
> --- a/examples/qos_sched/args.c
> +++ b/examples/qos_sched/args.c
> @@ -12,4 +12,5 @@
>  #include <getopt.h>
> 
> +#include <rte_bitops.h>
>  #include <rte_log.h>
>  #include <rte_eal.h>
> @@ -428,5 +429,5 @@ app_parse_args(int argc, char **argv)
>  	/* check main core index validity */
>  	for (i = 0; i <= app_main_core; i++) {
> -		if (app_used_core_mask & (1u << app_main_core)) {
> +		if (app_used_core_mask & RTE_BIT64(app_main_core)) {
>  			RTE_LOG(ERR, APP, "Main core index is not configured
> properly\n");
>  			app_usage(prgname);
> @@ -434,5 +435,5 @@ app_parse_args(int argc, char **argv)
>  		}
>  	}
> -	app_used_core_mask |= 1u << app_main_core;
> +	app_used_core_mask |= RTE_BIT64(app_main_core);
> 
>  	if ((app_used_core_mask != app_eal_core_mask()) ||
> --
> 2.34.1
> 
> ---
>   Diff of the applied patch vs upstream commit (please double-check if non-
> empty:
> ---
> --- -	2022-03-01 10:41:01.884306256 +0000
> +++ 0018-examples-qos_sched-fix-core-mask-overflow.patch	2022-03-01
> 10:41:01.252244087 +0000
> @@ -1 +1 @@
> -From 9c9fad3dfa042ae4b7a045cb1731f8701f8210e6 Mon Sep 17 00:00:00
> 2001
> +From d33bb6bd28406944b31ad53ba90199ca5f2f114f Mon Sep 17 00:00:00
> 2001
> @@ -8,0 +9,2 @@
> +[ upstream commit 9c9fad3dfa042ae4b7a045cb1731f8701f8210e6 ]
> +
> @@ -19 +20,0 @@
> -Cc: stable@dpdk.org
> @@ -24,2 +25,2 @@
> - examples/qos_sched/args.c | 4 ++--
> - 1 file changed, 2 insertions(+), 2 deletions(-)
> + examples/qos_sched/args.c | 5 +++--
> + 1 file changed, 3 insertions(+), 2 deletions(-)
> @@ -28 +29 @@
> -index 10ca7bea61..b2959499ae 100644
> +index 10ca7bea61..ff51d0215a 100644
> @@ -31 +32,7 @@
> -@@ -428,5 +428,5 @@ app_parse_args(int argc, char **argv)
> +@@ -12,4 +12,5 @@
> + #include <getopt.h>
> +
> ++#include <rte_bitops.h>
> + #include <rte_log.h>
> + #include <rte_eal.h>
> +@@ -428,5 +429,5 @@ app_parse_args(int argc, char **argv)
> @@ -38 +45 @@
> -@@ -434,5 +434,5 @@ app_parse_args(int argc, char **argv)
> +@@ -434,5 +435,5 @@ app_parse_args(int argc, char **argv)


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

end of thread, other threads:[~2022-03-01 18:28 UTC | newest]

Thread overview: 105+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-01 10:41 patch 'dmadev: add missing header include' has been queued to stable release 21.11.1 Kevin Traynor
2022-03-01 10:41 ` patch 'eal: add missing C++ guards' " Kevin Traynor
2022-03-01 10:41 ` patch 'telemetry: " Kevin Traynor
2022-03-01 10:41 ` patch 'ethdev: " Kevin Traynor
2022-03-01 10:41 ` patch 'metrics: " Kevin Traynor
2022-03-01 10:41 ` patch 'acl: " Kevin Traynor
2022-03-01 10:41 ` patch 'compressdev: " Kevin Traynor
2022-03-01 10:41 ` patch 'eventdev: " Kevin Traynor
2022-03-01 10:41 ` patch 'kni: " Kevin Traynor
2022-03-01 10:41 ` patch 'vhost: " Kevin Traynor
2022-03-01 10:41 ` patch 'bpf: " Kevin Traynor
2022-03-01 10:41 ` patch 'cryptodev: " Kevin Traynor
2022-03-01 10:41 ` patch 'ethdev: fix cast for C++ compatibility' " Kevin Traynor
2022-03-01 10:41 ` patch 'dma/hisilicon: use common PCI device naming' " Kevin Traynor
2022-03-01 10:41 ` patch 'test/dma: fix missing checks for device capacity' " Kevin Traynor
2022-03-01 10:41 ` patch 'dma/idxd: configure maximum batch size to high value' " Kevin Traynor
2022-03-01 10:41 ` patch 'doc: improve configuration examples in idxd guide' " Kevin Traynor
2022-03-01 10:41 ` patch 'examples/qos_sched: fix core mask overflow' " Kevin Traynor
2022-03-01 18:28   ` Ajmera, Megha
2022-03-01 10:41 ` patch 'eventdev/eth_rx: fix parameters parsing memory leak' " Kevin Traynor
2022-03-01 10:41 ` patch 'eventdev/eth_rx: fix queue config query' " Kevin Traynor
2022-03-01 10:41 ` patch 'event/dlb2: update rolling mask used for dequeue' " Kevin Traynor
2022-03-01 10:41 ` patch 'event/dlb2: poll HW CQ inflights before mapping queue' " Kevin Traynor
2022-03-01 10:41 ` patch 'event/cnxk: fix variables casting' " Kevin Traynor
2022-03-01 10:41 ` patch 'event/cnxk: fix uninitialized local variables' " Kevin Traynor
2022-03-01 10:41 ` patch 'crypto/ipsec_mb: remove useless check' " Kevin Traynor
2022-03-01 10:41 ` patch 'cryptodev: fix RSA key type name' " Kevin Traynor
2022-03-01 10:41 ` patch 'examples/ipsec-secgw: fix buffer freeing in vector mode' " Kevin Traynor
2022-03-01 10:41 ` patch 'doc: fix FIPS guide' " Kevin Traynor
2022-03-01 10:41 ` patch 'examples/l2fwd-crypto: fix port mask overflow' " Kevin Traynor
2022-03-01 10:41 ` patch 'baseband/acc100: avoid out-of-bounds access' " Kevin Traynor
2022-03-01 10:41 ` patch 'crypto/virtio: fix " Kevin Traynor
2022-03-01 10:41 ` patch 'crypto/ipsec_mb: check missing operation types' " Kevin Traynor
2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix ZUC authentication verify' " Kevin Traynor
2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix ZUC operation overwrite' " Kevin Traynor
2022-03-01 10:41 ` patch 'crypto/ipsec_mb: fix length and offset settings' " Kevin Traynor
2022-03-01 10:41 ` patch 'net/nfb: fix array indexes in deinit functions' " Kevin Traynor
2022-03-01 10:41 ` patch 'net/nfb: fix multicast/promiscuous mode switching' " Kevin Traynor
2022-03-01 10:41 ` patch 'net/ixgbe: reset security context pointer on close' " Kevin Traynor
2022-03-01 10:41 ` patch 'net/txgbe: " Kevin Traynor
2022-03-01 10:41 ` patch 'net/iavf: reset security context pointer on stop' " Kevin Traynor
2022-03-01 10:41 ` patch 'ethdev: fix MAC address in telemetry device info' " Kevin Traynor
2022-03-01 10:41 ` patch 'net/cnxk: fix mbuf data length' " Kevin Traynor
2022-03-01 10:41 ` patch 'net/bonding: fix slaves initializing on MTU setting' " Kevin Traynor
2022-03-01 10:42 ` patch 'app/testpmd: check starting port is not in bonding' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk: fix flow deletion' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk: fix log level during MCAM allocation' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk: fix base rule merge' " Kevin Traynor
2022-03-01 10:42 ` patch 'vhost: fix field naming in guest page struct' " Kevin Traynor
2022-03-01 10:42 ` patch 'vhost: fix unsafe vring addresses modifications' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk: fix NPC key extraction validation' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/af_xdp: add missing trailing newline in logs' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk: add missing checks of return values' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk fix unintended sign extension' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/cnxk: fix uninitialized pointer read' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/cnxk: fix uninitialized local variable' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/sfc_efx/base: fix recirculation ID set in outer rules' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/sfc_efx/base: add missing handler for 1-byte fields' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/sfc: fix flow tunnel support detection' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/sfc: fix memory allocation size for cache' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/af_xdp: ensure socket is deleted on Rx queue setup error' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ice: fix overwriting of LSE bit by DCF' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/iavf: fix segmentation offload condition' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/iavf: fix segmentation offload buffer size' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/i40e: enable maximum frame size at port level' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix sibling device config check' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix ineffective metadata argument adjustment' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix ASO CT object release' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix errno update in shared context creation' " Kevin Traynor
2022-03-01 10:42 ` patch 'app/testpmd: fix GENEVE parsing in checksum mode' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ngbe: fix debug logs' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/txgbe: " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: remove unused enumeration' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: remove unused offload variables' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: skip timer if reset is triggered' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: fix reset reason being overwritten' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: fix meta descriptor DF flag setup' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: check memory BAR before initializing LLQ' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/ena: fix checksum flag for L4' " Kevin Traynor
2022-03-01 10:42 ` patch 'common/mlx5: fix queue pair ack timeout configuration' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: set flow error for hash list create' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: remove unused function' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix meter sub-policy creation' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix entry in shared Rx queues list' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/mlx5: fix E-Switch manager vport ID' " Kevin Traynor
2022-03-01 10:42 ` patch 'doc: remove obsolete vector Tx explanations from mlx5 guide' " Kevin Traynor
2022-03-01 10:42 ` patch 'doc: replace broken links in mlx guides' " Kevin Traynor
2022-03-01 10:42 ` patch 'doc: correct name of BlueField-2 in mlx5 guide' " Kevin Traynor
2022-03-01 10:42 ` patch 'mempool/cnxk: fix batch allocation failure path' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/cnxk: fix inline device RQ tag mask' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/cnxk: register callback early to handle initial packets' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/cnxk: fix inline IPsec security error handling' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/cnxk: fix build with GCC 12' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/cnxk: fix RSS RETA table update' " Kevin Traynor
2022-03-01 10:42 ` patch 'net/i40e: fix unintentional integer overflow' " Kevin Traynor
2022-03-01 10:42 ` patch 'app/testpmd: fix raw encap of GENEVE option' " Kevin Traynor
2022-03-01 10:42 ` patch 'app/testpmd: fix build without drivers' " Kevin Traynor
2022-03-01 10:42 ` patch 'doc: add CUDA driver features' " Kevin Traynor
2022-03-01 10:42 ` patch 'test/efd: fix sockets mask size' " Kevin Traynor
2022-03-01 10:42 ` patch 'efd: fix uninitialized structure' " Kevin Traynor
2022-03-01 10:42 ` patch 'distributor: fix potential overflow' " Kevin Traynor
2022-03-01 10:42 ` patch 'eal/linux: fix illegal memory access in uevent handler' " Kevin Traynor
2022-03-01 10:42 ` patch 'devargs: fix crash with uninitialized parsing' " Kevin Traynor
2022-03-01 10:42 ` patch 'bus/pci: assign driver pointer before mapping' " Kevin Traynor
2022-03-01 10:43 ` patch 'kni: fix freeing order in device release' " Kevin Traynor

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).