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 77526A0093; Mon, 7 Mar 2022 23:34:58 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6945D41238; Mon, 7 Mar 2022 23:34:58 +0100 (CET) Received: from EUR02-HE1-obe.outbound.protection.outlook.com (mail-eopbgr10098.outbound.protection.outlook.com [40.107.1.98]) by mails.dpdk.org (Postfix) with ESMTP id 2AE494122E for ; Mon, 7 Mar 2022 23:34:57 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CXj5oDqZImXg6I17FpJPpI2PskRK7H5hPZkMI5NSqj5dGElFUA1/q/lUe/sc4P7Mj++qkWqnpwHAtP2DS1MOkdytSNiO2nIbe8VKy30NVa5soB+xGGPf1wX/JYJs8wTl6VF+G0u6JW2MAtFuFkLyC2vfEvtQIA4J6bTgdm/ThqfpbyquH6IpKvI66aFCwKrwu8Gu/z06Ijm/TGe29fVcQV6aHkmAH7SGU7WDQsIDzIlU6hBO6rKfjQNENZwNpW3qmdEL59TfZwo9r+7Zp5vOlF9SpHRHufwO2wx1v1BLD+0x8R2FxqmlyqDXDgrK6mLsiVehA+rDD8mM2MKheogvMg== 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=rMypJxxSeBMGWcpopsOP9Cb5YiiXRorQNVu7TO6WOMo=; b=NbaUeTyjz7H8wEi3mv2ARE/5hBh9SR2wHeEdDkAnbRTFGNGqZ4rww4oq6bbzWO41SEs6CNJs5neRzh3qNRX9SxySC4dSlLCSeesl2FkZvDyIm/IlDOEKexIr+/ejjb0BRNWojkClRbxCf00g9cg5KWZrsfQEYzr1z4da13CuzPupjJYgVGjiVSbDLwYGUZseYbK/BiXvTUbdOciRiH9GqAtw/C6k+cnnUQ1OCONtFSvdMM1cXNgJlW9j26qcBAz3Yt5OYLrCbnh8QWU7xQkwDVvDapqqe23xF0Jdu8fgFM1+xM2+ywBeiNFWbG75vYntI2fLy765kz6j1LZVCVeJsQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=silicom-usa.com; dmarc=pass action=none header.from=silicom-usa.com; dkim=pass header.d=silicom-usa.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=SILICOMLTD.onmicrosoft.com; s=selector2-SILICOMLTD-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=rMypJxxSeBMGWcpopsOP9Cb5YiiXRorQNVu7TO6WOMo=; b=ZwID8HBJnj862tjviGztpMsDXfeLpHhHztOz0uWtGQ2fg9R34puakIk00/VX7FqoYWtHTi2F0RFY6a1LvhkP9JntLQrzVA6rJE+cOY04nj8mxRA6ZkZKB3Eu1fwbQAEJv/eWfoP9BUuCXz1lU1UC6Y8ICMUgnE5YDyCvgIz1vXI= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=silicom-usa.com; Received: from VI1PR0402MB3517.eurprd04.prod.outlook.com (2603:10a6:803:b::16) by AM0PR04MB6819.eurprd04.prod.outlook.com (2603:10a6:208:17f::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5038.16; Mon, 7 Mar 2022 22:34:56 +0000 Received: from VI1PR0402MB3517.eurprd04.prod.outlook.com ([fe80::a0f5:7a14:c41a:7d62]) by VI1PR0402MB3517.eurprd04.prod.outlook.com ([fe80::a0f5:7a14:c41a:7d62%3]) with mapi id 15.20.5038.027; Mon, 7 Mar 2022 22:34:56 +0000 From: jeffd@silicom-usa.com To: dev@dpdk.org Cc: Stephen Douthit , Jeff Daly , Haiyue Wang Subject: [PATCH] net/ixgbe: Treat 1G Cu SFPs as 1G SX on the X550 devices Date: Mon, 7 Mar 2022 17:34:42 -0500 Message-Id: <20220307223442.28012-1-jeffd@silicom-usa.com> X-Mailer: git-send-email 2.25.1 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: BN6PR2001CA0032.namprd20.prod.outlook.com (2603:10b6:405:16::18) To VI1PR0402MB3517.eurprd04.prod.outlook.com (2603:10a6:803:b::16) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 160119cd-a405-4717-f9d2-08da008ab45e X-MS-TrafficTypeDiagnostic: AM0PR04MB6819:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: DJsrxOX4OdLajLJOhNN8WlO/ukoD5U2/hBUg9Cs2pmbwgr8vkt8P5DJucLk0qIro3BgHkx22LHrrv+fPzt+Hdc3nzPb/iIgJr8ZNDD+s1vVX1tc5HZOxkjexNjk2IKyFDxCnMcJrvtCiCRh0+wnwFwTPa+SS3h8YJbfNUdF+Z/HmSIUCNvZu5rsWvT8de/nH13zppxo7mhM12JymqgIZWcctjhvKrM9vwIpbUYF0mQCZY8/k1oOB/9DaTKe5pxowo1h6c2bnPPoUoq52ln8rO+eGQVnmBG3CEWZKqkBxPl8EqtdNm0Tm5Zg+eb6DNO0eXtKDpLdhvwXfJ7DG9FV82zDFdfUaYsFSZ5kW34lApid6sbAByXlatZvx/pAv0an5eWQmkBxMg1cAKNIMaQQy1RujjligkMnkwqZc3d5br5K9uHM6txsFpbNo6z8TP6is7pu3NmRLSmW0uwd4uIQ3doFf46SHIsLQabwFD+2bj6pY9Dwfuh+MPrNHASsRKNECnVDkYb4P7uKPO4D1H0nwpn6FThMOancY/ldEjAkdgAX78MNeoJwVE+IOOK4XfBP7n3G24OhAB65B3eAepUfCWeWU37VNYSl02T48P8q+rGNq2i0Bi52ZAVj6txZiSjwizSIJ56kRSAvlBSUojTGIejLJe323BLJfmOM6Y4mwcI4SvN+LMrMB3Puw/e1A1Q7eTadW/2RatNktiXZh+caXTw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VI1PR0402MB3517.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(4636009)(366004)(86362001)(8936002)(6512007)(6506007)(6486002)(6666004)(9686003)(5660300002)(6916009)(316002)(36756003)(52116002)(2906002)(38350700002)(1076003)(4326008)(186003)(8676002)(2616005)(83380400001)(508600001)(54906003)(66556008)(66476007)(66946007)(26005)(38100700002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?D9n4Ch+lELARCHnHd7cWx+4SZXICkckEZPzIrRnc/92ae2u0WJrMPy8lysXr?= =?us-ascii?Q?+xvPY2uYbHipicKKQpavVePxv4xmNpEllTzHmbpwchZPpftBeE0vm2z0S/yg?= =?us-ascii?Q?fj4eb0ngjiMMR/biKKNHxQr9dt5CR/MBlULGcyRQJho+fWj7YE7y6XYORBgg?= =?us-ascii?Q?o/Ia/owDNyb9pIS1qNObuRLyiLN6xqSXw3Y7C3pM/Nk9zVmWP95uClY+aNd6?= =?us-ascii?Q?SuTBR8QDA0jR+z++Eoa3+tJSh/2Ll07NzcrzBTBHrwr4m9ewQHlSrV9YE9jq?= =?us-ascii?Q?8Ukqpbd1OXFFSSRShOarEnrIOdzg0a1iQSy8xOZx3G8AjQFbw94z7z5q2q0a?= =?us-ascii?Q?jmUsrBgiGSd14CXsI1oEDSQhZp6NpJDLYaHf2/7ueXojKjcKByZ1Cncp4BXM?= =?us-ascii?Q?sIc09Q7xaodOa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igty4LA?= =?us-ascii?Q?IjDlCxIq6eaLRHGg2H7KZGVZXq6lJac4+6Y1vbHdVSfdJ4POyk+jBTWJ0XJD?= =?us-ascii?Q?61918GDSj4xmwAdrvg8gS5RZdeOM9eIdKrowsPX11K47qVbKHXqbPG4iTPzL?= =?us-ascii?Q?cAw2TngfGKpojfwHZEJS4zXg0LgHQeoSBDtpIr5y/ZAUfn5Y0j+Gi7+/rP+T?= =?us-ascii?Q?rOg13YL5L6gEWjtTnqAWJ+B2eRjsxVCiDpPLJ4p5/vNMaNpVHjdJ+c8Lw3bX?= =?us-ascii?Q?Iny2BowJDesSECPNmHac0aa7qqMSCzm6XFeL0hk0c9Q//9Q/xWW4uq3HtRlU?= =?us-ascii?Q?yw=3D=3D?= X-OriginatorOrg: silicom-usa.com X-MS-Exchange-CrossTenant-Network-Message-Id: 160119cd-a405-4717-f9d2-08da008ab45e X-MS-Exchange-CrossTenant-AuthSource: VI1PR0402MB3517.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Mar 2022 22:34:55.9362 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: c9e326d8-ce47-4930-8612-cc99d3c87ad1 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: hAOzCnmx86Rlp5QudoZasStcyyJjDQlY6rDhUYrD2zYdKFqdu8fpIWsxGiGp2mBCWctk2Dy6ce+GrZZVVRt9Sg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR04MB6819 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Stephen Douthit 1G Cu SFPs are not officially supported on the X552/X553 family of devices but treat them as 1G SX modules since they usually work. Print a warning though since support isn't validated, similar to what already happens for other unofficially supported SFPs enabled via the allow_unsupported_sfps parameter inherited from the mainline Linux driver. Signed-off-by: Stephen Douthit Signed-off-by: Jeff Daly --- drivers/net/ixgbe/base/ixgbe_x550.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/drivers/net/ixgbe/base/ixgbe_x550.c b/drivers/net/ixgbe/base/ixgbe_x550.c index 8810d1658e..8d1bc6c80d 100644 --- a/drivers/net/ixgbe/base/ixgbe_x550.c +++ b/drivers/net/ixgbe/base/ixgbe_x550.c @@ -1538,9 +1538,21 @@ STATIC s32 ixgbe_supported_sfp_modules_X550em(struct ixgbe_hw *hw, bool *linear) case ixgbe_sfp_type_1g_lha_core1: *linear = false; break; - case ixgbe_sfp_type_unknown: + /* Copper SFPs are not officially supported for x550em devices, but can + * often be made to work at fixed 1G speeds. Pretend they're 1g_sx + * modules here to allow g.Fast DSL SFPs to work. + */ case ixgbe_sfp_type_1g_cu_core0: + EWARN(hw, "Pretending that unsupported 1g_cu SFP is 1g_sx\n"); + *linear = false; + hw->phy.sfp_type = ixgbe_sfp_type_1g_sx_core0; + break; case ixgbe_sfp_type_1g_cu_core1: + EWARN(hw, "Pretending that unsupported 1g_cu SFP is 1g_sx\n"); + *linear = false; + hw->phy.sfp_type = ixgbe_sfp_type_1g_sx_core1; + break; + case ixgbe_sfp_type_unknown: default: return IXGBE_ERR_SFP_NOT_SUPPORTED; } -- 2.25.1