[dpdk-stable] patch 'net/hns3: fix device capabilities for copper media type' has been queued to stable release 20.11.2

Xueming Li xuemingl at nvidia.com
Mon May 10 17:59:35 CEST 2021


Hi,

FYI, your patch has been queued to stable release 20.11.2

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

This queued commit can be viewed at:
https://github.com/steevenlee/dpdk/commit/e4e0a6505d77bec24938065bc77ecd0a74e02ae8

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From e4e0a6505d77bec24938065bc77ecd0a74e02ae8 Mon Sep 17 00:00:00 2001
From: Huisong Li <lihuisong at huawei.com>
Date: Thu, 4 Mar 2021 15:44:47 +0800
Subject: [PATCH] net/hns3: fix device capabilities for copper media type
Cc: Luca Boccassi <bluca at debian.org>

[ upstream commit 68ed5ee49de7f6e3a57c5ecca812b3bbcced6bbf ]

The configuration operation for PHY is implemented by firmware. And
a capability flag will be report to driver, which means the firmware
supports the PHY driver.  However, the current implementation only
supports obtaining the capability bit, but some basic functions of
copper ports in driver, such as, the query of link status and link
info, are not supported.

Therefore, it is necessary for driver to set the copper capability
bit to zero when the firmware supports the configuration of the PHY.

Fixes: 438752358158 ("net/hns3: get device capability from firmware")
Fixes: 95e50325864c ("net/hns3: support copper media type")

Signed-off-by: Huisong Li <lihuisong at huawei.com>
---
 drivers/net/hns3/hns3_cmd.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/net/hns3/hns3_cmd.c b/drivers/net/hns3/hns3_cmd.c
index 76d16a5a92..7f115d37ef 100644
--- a/drivers/net/hns3/hns3_cmd.c
+++ b/drivers/net/hns3/hns3_cmd.c
@@ -424,8 +424,14 @@ static void hns3_parse_capability(struct hns3_hw *hw,
 		hns3_set_bit(hw->capability, HNS3_DEV_SUPPORT_PTP_B, 1);
 	if (hns3_get_bit(caps, HNS3_CAPS_TX_PUSH_B))
 		hns3_set_bit(hw->capability, HNS3_DEV_SUPPORT_TX_PUSH_B, 1);
+	/*
+	 * Currently, the query of link status and link info on copper ports
+	 * are not supported. So it is necessary for driver to set the copper
+	 * capability bit to zero when the firmware supports the configuration
+	 * of the PHY.
+	 */
 	if (hns3_get_bit(caps, HNS3_CAPS_PHY_IMP_B))
-		hns3_set_bit(hw->capability, HNS3_DEV_SUPPORT_COPPER_B, 1);
+		hns3_set_bit(hw->capability, HNS3_DEV_SUPPORT_COPPER_B, 0);
 	if (hns3_get_bit(caps, HNS3_CAPS_TQP_TXRX_INDEP_B))
 		hns3_set_bit(hw->capability, HNS3_DEV_SUPPORT_INDEP_TXRX_B, 1);
 	if (hns3_get_bit(caps, HNS3_CAPS_STASH_B))
-- 
2.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-05-10 23:59:27.383658500 +0800
+++ 0027-net-hns3-fix-device-capabilities-for-copper-media-ty.patch	2021-05-10 23:59:26.350000000 +0800
@@ -1 +1 @@
-From 68ed5ee49de7f6e3a57c5ecca812b3bbcced6bbf Mon Sep 17 00:00:00 2001
+From e4e0a6505d77bec24938065bc77ecd0a74e02ae8 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Luca Boccassi <bluca at debian.org>
+
+[ upstream commit 68ed5ee49de7f6e3a57c5ecca812b3bbcced6bbf ]
@@ -18 +20,0 @@
-Cc: stable at dpdk.org
@@ -26 +28 @@
-index 32cd56b478..ec34615558 100644
+index 76d16a5a92..7f115d37ef 100644
@@ -29 +31 @@
-@@ -423,8 +423,14 @@ static void hns3_parse_capability(struct hns3_hw *hw,
+@@ -424,8 +424,14 @@ static void hns3_parse_capability(struct hns3_hw *hw,


More information about the stable mailing list