patch 'common/cnxk: fix Tx MTU configuration' has been queued to stable release 22.11.5

luca.boccassi at gmail.com luca.boccassi at gmail.com
Thu Mar 14 01:09:25 CET 2024


Hi,

FYI, your patch has been queued to stable release 22.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

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

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

Thanks.

Luca Boccassi

---
>From edf3fc5d23dbf1be447fe71d5c5274977ceb19a1 Mon Sep 17 00:00:00 2001
From: Nithin Dabilpuram <ndabilpuram at marvell.com>
Date: Mon, 26 Feb 2024 19:05:29 +0530
Subject: [PATCH] common/cnxk: fix Tx MTU configuration

[ upstream commit cc9f534f60815d858b946062cb1d9701c91b9b58 ]

Skip setting Tx MTU separately as now the Tx credit configuration
is based on max MTU possible for that link.

Also, initialize  MTU with max value for that port.

Fixes: 8589ec212e80 ("net/cnxk: support MTU set")

Signed-off-by: Nithin Dabilpuram <ndabilpuram at marvell.com>
---
 drivers/common/cnxk/roc_nix.c      |  2 +-
 drivers/common/cnxk/roc_nix.h      |  2 --
 drivers/net/cnxk/cnxk_ethdev_ops.c | 12 +-----------
 3 files changed, 2 insertions(+), 14 deletions(-)

diff --git a/drivers/common/cnxk/roc_nix.c b/drivers/common/cnxk/roc_nix.c
index 2a320cc291..b5c87e8056 100644
--- a/drivers/common/cnxk/roc_nix.c
+++ b/drivers/common/cnxk/roc_nix.c
@@ -426,7 +426,7 @@ skip_dev_init:
 	sdp_lbk_id_update(pci_dev, nix);
 	nix->pci_dev = pci_dev;
 	nix->reta_sz = reta_sz;
-	nix->mtu = ROC_NIX_DEFAULT_HW_FRS;
+	nix->mtu = roc_nix_max_pkt_len(roc_nix);
 
 	/* Always start with full FC for LBK */
 	if (nix->lbk_link) {
diff --git a/drivers/common/cnxk/roc_nix.h b/drivers/common/cnxk/roc_nix.h
index 6654a2df78..1125fff020 100644
--- a/drivers/common/cnxk/roc_nix.h
+++ b/drivers/common/cnxk/roc_nix.h
@@ -236,8 +236,6 @@ struct roc_nix_eeprom_info {
 #define ROC_NIX_RSS_KEY_LEN	     48 /* 352 Bits */
 #define ROC_NIX_RSS_MCAM_IDX_DEFAULT (-1)
 
-#define ROC_NIX_DEFAULT_HW_FRS 1514
-
 #define ROC_NIX_VWQE_MAX_SIZE_LOG2 11
 #define ROC_NIX_VWQE_MIN_SIZE_LOG2 2
 
diff --git a/drivers/net/cnxk/cnxk_ethdev_ops.c b/drivers/net/cnxk/cnxk_ethdev_ops.c
index 8008f5e4f3..c13ef26c5d 100644
--- a/drivers/net/cnxk/cnxk_ethdev_ops.c
+++ b/drivers/net/cnxk/cnxk_ethdev_ops.c
@@ -574,19 +574,9 @@ skip_buffsz_check:
 
 	frame_size -= RTE_ETHER_CRC_LEN;
 
-	/* Update mtu on Tx */
-	rc = roc_nix_mac_mtu_set(nix, frame_size);
-	if (rc) {
-		plt_err("Failed to set MTU, rc=%d", rc);
-		goto exit;
-	}
-
-	/* Sync same frame size on Rx */
+	/* Set frame size on Rx */
 	rc = roc_nix_mac_max_rx_len_set(nix, frame_size);
 	if (rc) {
-		/* Rollback to older mtu */
-		roc_nix_mac_mtu_set(nix,
-				    old_frame_size - RTE_ETHER_CRC_LEN);
 		plt_err("Failed to max Rx frame length, rc=%d", rc);
 		goto exit;
 	}
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-03-14 00:09:22.060850014 +0000
+++ 0029-common-cnxk-fix-Tx-MTU-configuration.patch	2024-03-14 00:09:20.613615221 +0000
@@ -1 +1 @@
-From cc9f534f60815d858b946062cb1d9701c91b9b58 Mon Sep 17 00:00:00 2001
+From edf3fc5d23dbf1be447fe71d5c5274977ceb19a1 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit cc9f534f60815d858b946062cb1d9701c91b9b58 ]
+
@@ -12 +13,0 @@
-Cc: stable at dpdk.org
@@ -22 +23 @@
-index 97c0ae3e25..90ccb260fb 100644
+index 2a320cc291..b5c87e8056 100644
@@ -25 +26 @@
-@@ -484,7 +484,7 @@ skip_dev_init:
+@@ -426,7 +426,7 @@ skip_dev_init:
@@ -31 +31,0 @@
- 	nix->dmac_flt_idx = -1;
@@ -33 +33,2 @@
- 	/* Register error and ras interrupts */
+ 	/* Always start with full FC for LBK */
+ 	if (nix->lbk_link) {
@@ -35 +36 @@
-index 2a198de458..4db71544f0 100644
+index 6654a2df78..1125fff020 100644
@@ -38 +39 @@
-@@ -267,8 +267,6 @@ struct roc_nix_eeprom_info {
+@@ -236,8 +236,6 @@ struct roc_nix_eeprom_info {
@@ -48 +49 @@
-index e816884d47..4962f3bced 100644
+index 8008f5e4f3..c13ef26c5d 100644
@@ -51 +52 @@
-@@ -610,19 +610,9 @@ skip_buffsz_check:
+@@ -574,19 +574,9 @@ skip_buffsz_check:


More information about the stable mailing list