From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9FCC944077 for ; Mon, 20 May 2024 12:42:24 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 896DF40A75; Mon, 20 May 2024 12:42:23 +0200 (CEST) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2042.outbound.protection.outlook.com [40.107.220.42]) by mails.dpdk.org (Postfix) with ESMTP id 062E240A4B; Mon, 20 May 2024 12:42:21 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=SQwPbpl7n33k2txVnZpOoV1Qn1Ygvoc256QapRKIN7/tLzhNs/fiQSOKDepwZRhm1mXNsOh6vyNQYfPq2RFnt4SV6jSnAfKr3HqmazeNb+e9ASRppSsTCRgfaKFfbDXaQMwWYmehi/Bz/AyPR4d5GeiU0dmIe4kAAOlAPbH5Kszm0QVThIrJsW+ii9qAih77b1PZhF+WFX34oZH4a13ZFcs5P+otSbsi+vztDRxUe5wZ3t8nCsGK8xVLi6zGqqFmQ42cBfrQeskI0QdXMBmnCgAptgxi2hSkOk3M4iGmozOXgxuDo/5jEmCcBa68EBlqvgCtr19qxKQQYPJJmHyaCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=iSrQKKWXLh1orc9lpn1QmUptnXH8OFoYloJY22EhOrU=; b=B0n+kq7XazUPOJAEFwlL1l3EtANeEYakFggc8SznJ+aMI5iJ0PyUO3BDit0BjpqJ5R/ACqw4VI6nuj4J/ZkpIspNd3ogrosE3gzpnHpHdURAhYPXIke7U3g0wlk/WPFflkOeHFw2qks10dkrM31Ct6okRVA2FL1gIvzEBn3raJjoNakAzPQGHNdccv+lHViAtIPP3Lq1pRi5dT1+Gus8nWhNurvatIDkSka7M2IYYwK++KSDBUq2hBMSHo1/PBYAeWCs1I1klNaLj3glJWNvsMXO+KiDZeZrfNq7Y89mCC43hcH3gEgkxTCQj0K0BhFgDg4F0ZEWlgkcpuhKGXPL/w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=iSrQKKWXLh1orc9lpn1QmUptnXH8OFoYloJY22EhOrU=; b=CHA7Ox1ILBinprFZeHuMxGuvpCHXnyzcnz/Q+q2KE3VcyJIBQPHyNrBJH84QHQiw7xS7kHA2Rk3eH3LAATmqqzbG7OAvsw+4TdFufSDrI00WRZEm8+kaLMb6sxsTPtlHkOLVLE4S70pThOxRyaYasSKkSZMZbxzn7f8ssQ8If4c= Received: from DM4PR12MB5055.namprd12.prod.outlook.com (2603:10b6:5:39a::20) by CY8PR12MB7123.namprd12.prod.outlook.com (2603:10b6:930:60::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7587.35; Mon, 20 May 2024 10:42:18 +0000 Received: from DM4PR12MB5055.namprd12.prod.outlook.com ([fe80::acbd:ea93:4496:51a5]) by DM4PR12MB5055.namprd12.prod.outlook.com ([fe80::acbd:ea93:4496:51a5%7]) with mapi id 15.20.7587.035; Mon, 20 May 2024 10:42:18 +0000 From: "Sebastian, Selwin" To: "Ande, Venkat Kumar" , "dev@dpdk.org" CC: "stable@dpdk.org" Subject: RE: [PATCH v2 10/25] net/axgbe: check only the minimum speed for cables Thread-Topic: [PATCH v2 10/25] net/axgbe: check only the minimum speed for cables Thread-Index: AQHaoHw/Of6UCwJwlUmTSU81XybpabGgA8lw Date: Mon, 20 May 2024 10:42:18 +0000 Message-ID: References: <20240412125013.10498-1-VenkatKumar.Ande@amd.com> <20240507124305.2318-1-venkatkumar.ande@amd.com> <20240507124305.2318-10-venkatkumar.ande@amd.com> In-Reply-To: <20240507124305.2318-10-venkatkumar.ande@amd.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_ActionId=a737f9bc-a412-4c15-b031-83fc93584fae; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_ContentBits=0; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_Enabled=true; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_Method=Standard; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_Name=AMD Internal Distribution Only; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_SetDate=2024-05-20T10:42:14Z; MSIP_Label_dce362fe-1558-4fb5-9f64-8a6240d76441_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: DM4PR12MB5055:EE_|CY8PR12MB7123:EE_ x-ms-office365-filtering-correlation-id: 69780fd6-7b97-4e5b-1ee7-08dc78b985c7 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; ARA:13230031|1800799015|366007|376005|38070700009; x-microsoft-antispam-message-info: =?us-ascii?Q?zwI/mZMRbTAHpiNc5W8QQok8n24GTPy6lwzL+A7gNeAY9LVdUT4luytD1ObH?= =?us-ascii?Q?bQXUS55kgr0yyTgOBDqsp00YXr3zKwL4uoFaqPRozLxZFEGHM/6jnXJmwHR0?= =?us-ascii?Q?VFiDh2s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yNtj60KrD+Fh7av?= =?us-ascii?Q?evlxA8Zj7taKEXdUrDKRXFZk05iBgNW27b/zlDF7TnpyOMPM3/G9MbJ3rk1H?= =?us-ascii?Q?H/T1e8cZFwTpO/bExALQNWmAVreY+CQXJ/tvYY8et7sosp8Um4zofUVHq+Sk?= =?us-ascii?Q?HgXMl8QLl5iHIuyRXcrzeodDPjpTKCNotudolbESkT8uE2tjx6ZWX/wSmIEc?= =?us-ascii?Q?xsD/L0vIMmtBhqvRherWrNyXZAsAjRBdRp7R0Atqr7BgS6sAD3kHceZ2l1Bp?= =?us-ascii?Q?VhpCaRKs0DHeZxiClhDOAuikigCQluPhzMcsZjripe6nOkitQgoY59XLeFyK?= =?us-ascii?Q?oC5lwX5bm9zCS3+G/QVSZG5HgsPRt65PeQY0lLxo0+/Jjg=3D=3D?= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM4PR12MB5055.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(1800799015)(366007)(376005)(38070700009); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?JVwGbG0K+x2XVt9QSHVqUiShXztUilHYFGkAyxtkNC6p55rlj6nuX2LjeUU2?= =?us-ascii?Q?EmcvqI3+XFF4fRADzMCr1xX6+RDLq93qYNwrlnIRG858hlsfo3SKxu53rb3B?= =?us-ascii?Q?MNCVIhWLJMQILwZTZCZknxWQZpSEDPX58Hyp2K6i1hx6W51d0LHBqUaVLMp6?= =?us-ascii?Q?2b8WDAuLzBk6BlCOaUuS4eJvB9z4BeBq/xVMOS0Zdie/xysJAJ1Y8MllRHcB?= =?us-ascii?Q?jJdKz5lq0cZvCw+bsEsoSGdWISLfVokY0Qymf6e5MDldKxSnkF4xc44AJBiO?= =?us-ascii?Q?FRXcSM2BxTVOeqFi2DgzlyIJJaBTc+BqvIStPDGMhqS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aTOXS13ZzY54q0D6NqEfZguFbMUouMO9cj7xkwM6/WPkfMB5?= =?us-ascii?Q?f4SQwp5qV1ritr9XBSTzYjYUClZqOTUP/0W1uDrkeivpolXvjGOIZIt8/rH7?= =?us-ascii?Q?WsrbCDlzQ6yzC6Fwuc+nwG6RfZ9iQhYEIwGKYWeTe2tjg5XHx4Xn9WxQOnhR?= =?us-ascii?Q?DeX8/osMK9pFgfrslgiLwQJT05EIVh50AH+CzHSR48JY/4JJF0J/AK9CcIMp?= =?us-ascii?Q?Ki8Ek2KCEvov/TFb0ZgleLufqQeCnCRro9BWk6IjNn2M0+t5qP62aUjthpVg?= =?us-ascii?Q?fU1QErxkpL6WYJ32GpUzQ4z1aqpcI6Qf7ZY4prIw/Rmvymj7DUs9wxYI2ZdA?= =?us-ascii?Q?AN/U2ueVdSfFFLvep9uzja4pzRD6J7oQhOMHNIYR?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM4PR12MB5055.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 69780fd6-7b97-4e5b-1ee7-08dc78b985c7 X-MS-Exchange-CrossTenant-originalarrivaltime: 20 May 2024 10:42:18.7871 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: U79ZNOHMMUKJgB9fADKvMj8IqyeiMq1+RDyD2ioGv3++NIjxmm82hoSr4G4ctnpUg/tH3Rb+UZZBX4v/APeMLA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY8PR12MB7123 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 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 [AMD Official Use Only - AMD Internal Distribution Only] Acked-by: Selwin Sebastian -----Original Message----- From: Ande, Venkat Kumar Sent: Tuesday, May 7, 2024 6:13 PM To: dev@dpdk.org Cc: Sebastian, Selwin ; Ande, Venkat Kumar ; stable@dpdk.org Subject: [PATCH v2 10/25] net/axgbe: check only the minimum speed for cable= s There are cables that exist that can support speeds in excess of 10GbE. The driver, however, restricts the EEPROM advertised nominal bitrate to a s= pecific range, which can prevent usage of cables that can support, for exam= ple, up to 25GbE. Rather than checking that an active or passive cable supports a specific ra= nge, only check for a minimum supported speed. Fixes: a5c7273771e8 ("net/axgbe: add phy programming APIs") Cc: stable@dpdk.org Signed-off-by: Venkat Kumar Ande --- drivers/net/axgbe/axgbe_phy_impl.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/drivers/net/axgbe/axgbe_phy_impl.c b/drivers/net/axgbe/axgbe_p= hy_impl.c index 8b66def631..0ad5b4ba85 100644 --- a/drivers/net/axgbe/axgbe_phy_impl.c +++ b/drivers/net/axgbe/axgbe_phy_impl.c @@ -117,9 +117,7 @@ enum axgbe_sfp_speed { #define AXGBE_SFP_BASE_BR 12 #define AXGBE_SFP_BASE_BR_1GBE_MIN 0x0a -#define AXGBE_SFP_BASE_BR_1GBE_MAX 0x0d #define AXGBE_SFP_BASE_BR_10GBE_MIN 0x64 -#define AXGBE_SFP_BASE_BR_10GBE_MAX 0x68 #define AXGBE_SFP_BASE_CU_CABLE_LEN 18 @@ -536,25 +534,22 @@ static void axgbe_phy_sfp_phy_settings(struct axgbe_p= ort *pdata) static bool axgbe_phy_sfp_bit_rate(struct axgbe_sfp_eeprom *sf= p_eeprom, enum axgbe_sfp_speed sfp_speed) { - u8 *sfp_base, min, max; + u8 *sfp_base, min; sfp_base =3D sfp_eeprom->base; switch (sfp_speed) { case AXGBE_SFP_SPEED_1000: min =3D AXGBE_SFP_BASE_BR_1GBE_MIN; - max =3D AXGBE_SFP_BASE_BR_1GBE_MAX; break; case AXGBE_SFP_SPEED_10000: min =3D AXGBE_SFP_BASE_BR_10GBE_MIN; - max =3D AXGBE_SFP_BASE_BR_10GBE_MAX; break; default: return false; } - return ((sfp_base[AXGBE_SFP_BASE_BR] >=3D min) && - (sfp_base[AXGBE_SFP_BASE_BR] <=3D max)); + return sfp_base[AXGBE_SFP_BASE_BR] >=3D min; } static void axgbe_phy_sfp_external_phy(struct axgbe_port *pdata) -- 2.34.1