From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 512E0A00E6 for ; Tue, 16 Apr 2019 16:38:41 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B36011B4F9; Tue, 16 Apr 2019 16:38:35 +0200 (CEST) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id C98A41B4D3 for ; Tue, 16 Apr 2019 16:38:34 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3E7A2D4015; Tue, 16 Apr 2019 14:38:34 +0000 (UTC) Received: from rh.redhat.com (ovpn-117-214.ams2.redhat.com [10.36.117.214]) by smtp.corp.redhat.com (Postfix) with ESMTP id 716231001E92; Tue, 16 Apr 2019 14:38:33 +0000 (UTC) From: Kevin Traynor To: Andrew Rybchenko Cc: dpdk stable Date: Tue, 16 Apr 2019 15:36:54 +0100 Message-Id: <20190416143719.21601-36-ktraynor@redhat.com> In-Reply-To: <20190416143719.21601-1-ktraynor@redhat.com> References: <20190416143719.21601-1-ktraynor@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Tue, 16 Apr 2019 14:38:34 +0000 (UTC) Subject: [dpdk-stable] patch 'net/sfc: fix speed capabilities reported in device info' has been queued to LTS release 18.11.2 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi, FYI, your patch has been queued to LTS release 18.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 04/24/19. 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. Thanks. Kevin Traynor --- >From 78ce47dad62e02247c3fdc669b02b49194e0cab7 Mon Sep 17 00:00:00 2001 From: Andrew Rybchenko Date: Tue, 19 Mar 2019 16:36:00 +0000 Subject: [PATCH] net/sfc: fix speed capabilities reported in device info [ upstream commit cf6a73fc3fb774477feea692e90d2976a8f91cd8 ] Phy capabilities are bit offsets in libefx, but was used as bit masks. Fixes: d23f3a89ab54 ("net/sfc: support link speed and duplex settings") Fixes: f82e33afbbb9 ("net/sfc: support link speeds up to 100G") Signed-off-by: Andrew Rybchenko --- drivers/net/sfc/sfc_ethdev.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c index 10e032400..83dd088cf 100644 --- a/drivers/net/sfc/sfc_ethdev.c +++ b/drivers/net/sfc/sfc_ethdev.c @@ -95,15 +95,15 @@ sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) /* Autonegotiation may be disabled */ dev_info->speed_capa = ETH_LINK_SPEED_FIXED; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_1000FDX) + if (sa->port.phy_adv_cap_mask & (1u << EFX_PHY_CAP_1000FDX)) dev_info->speed_capa |= ETH_LINK_SPEED_1G; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_10000FDX) + if (sa->port.phy_adv_cap_mask & (1u << EFX_PHY_CAP_10000FDX)) dev_info->speed_capa |= ETH_LINK_SPEED_10G; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_25000FDX) + if (sa->port.phy_adv_cap_mask & (1u << EFX_PHY_CAP_25000FDX)) dev_info->speed_capa |= ETH_LINK_SPEED_25G; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_40000FDX) + if (sa->port.phy_adv_cap_mask & (1u << EFX_PHY_CAP_40000FDX)) dev_info->speed_capa |= ETH_LINK_SPEED_40G; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_50000FDX) + if (sa->port.phy_adv_cap_mask & (1u << EFX_PHY_CAP_50000FDX)) dev_info->speed_capa |= ETH_LINK_SPEED_50G; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_100000FDX) + if (sa->port.phy_adv_cap_mask & (1u << EFX_PHY_CAP_100000FDX)) dev_info->speed_capa |= ETH_LINK_SPEED_100G; -- 2.20.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2019-04-16 15:34:26.793029519 +0100 +++ 0036-net-sfc-fix-speed-capabilities-reported-in-device-in.patch 2019-04-16 15:34:25.188179772 +0100 @@ -1,13 +1,14 @@ -From cf6a73fc3fb774477feea692e90d2976a8f91cd8 Mon Sep 17 00:00:00 2001 +From 78ce47dad62e02247c3fdc669b02b49194e0cab7 Mon Sep 17 00:00:00 2001 From: Andrew Rybchenko Date: Tue, 19 Mar 2019 16:36:00 +0000 Subject: [PATCH] net/sfc: fix speed capabilities reported in device info +[ upstream commit cf6a73fc3fb774477feea692e90d2976a8f91cd8 ] + Phy capabilities are bit offsets in libefx, but was used as bit masks. Fixes: d23f3a89ab54 ("net/sfc: support link speed and duplex settings") Fixes: f82e33afbbb9 ("net/sfc: support link speeds up to 100G") -Cc: stable@dpdk.org Signed-off-by: Andrew Rybchenko --- @@ -15,10 +16,10 @@ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c -index e7bfd8917..2675d4a8c 100644 +index 10e032400..83dd088cf 100644 --- a/drivers/net/sfc/sfc_ethdev.c +++ b/drivers/net/sfc/sfc_ethdev.c -@@ -97,15 +97,15 @@ sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) +@@ -95,15 +95,15 @@ sfc_dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) /* Autonegotiation may be disabled */ dev_info->speed_capa = ETH_LINK_SPEED_FIXED; - if (sa->port.phy_adv_cap_mask & EFX_PHY_CAP_1000FDX)