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 CD5BEA034F; Fri, 12 Nov 2021 15:48:19 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B5AB641153; Fri, 12 Nov 2021 15:48:19 +0100 (CET) Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2058.outbound.protection.outlook.com [40.107.244.58]) by mails.dpdk.org (Postfix) with ESMTP id 20B1E410F5 for ; Fri, 12 Nov 2021 15:48:18 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YPDOEe7R7cCja8B2dtaI3zTYPn7x2eniv9fC2UQerJYU9GuIzn2t7rQQZY/vnhBij8bYh4X+YI6LHuIKSfMiAap9socWZsTYiMO2r63MjCL0GEh07676CrA372OiHvUPKD72fiYsezfPoKV6FfRO/1OzSB2+X/y/5ffvWwq7Tyg2F/uDd8uOSDjJlt94S0yxSZi4298cSnMin0JpjDEjTpy75CllGxtWd307afzMfkFxzbCKND4V9XwPjC80ccSwAN9W935xPU0nfLVFATZnXAxkdjYglLUm9EGhAl42/gnAXGOM+q3Z7IpQsC395ept48d6xKkcxlxU+YNIsBfqRA== 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=dLgMfPknWA41Asc+cHKRpwJgPcIvIPyiJVw5l+vjJo0=; b=HRJGQfJCSAyfZaR3jGlqvYcHIkOYV2/4V1oCFs5r4Gttuo0xoxSDgAPAR1WBn2uAP8r2MJwpP+7RWsG71UBhbHwoFhADBP/xdyy4SNIVkHSspRNRmPK2Cwulrt1MDPJp7mfX87csgDs/uf3UYWp7SXun3GTHTog0gS859OfXRq5adbCnRJUwJQhKChHzhprlMH6GT0SnmlGaYOr4ExLudbCaS48UFbleNmXvdtIN9vtWXCTKVP1ku6dE1x5NZOguI8W5yRCZirQHmwXKfdHlEnNJxffQl/M0NXUpjG0GOD22aYCJ2u2/V7GlWEeJGCz8mWz4brB+ZmPhhz25qU6tPg== 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=dLgMfPknWA41Asc+cHKRpwJgPcIvIPyiJVw5l+vjJo0=; b=oUgmeTYg+bOkS4nYRrOfT0TOxYd2XouTbF+t8X9mhNWY0KeESPUoPgIrqpaNBbfUkQoZJjH0NZdr9b8m3FkeMNJiJgwZ7kknJBZrCGub0WrjGbIjbnf18I6zoWjcyCNB3VvTCYADSWf/2KEE7a2VmqfsLjl/zBAK+VM2IgTy6l8= Received: from DM4PR12MB5344.namprd12.prod.outlook.com (2603:10b6:5:39f::11) by DM8PR12MB5431.namprd12.prod.outlook.com (2603:10b6:8:34::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4669.10; Fri, 12 Nov 2021 14:48:15 +0000 Received: from DM4PR12MB5344.namprd12.prod.outlook.com ([fe80::64f6:a606:bfce:abe3]) by DM4PR12MB5344.namprd12.prod.outlook.com ([fe80::64f6:a606:bfce:abe3%3]) with mapi id 15.20.4690.025; Fri, 12 Nov 2021 14:48:15 +0000 From: "Namburu, Chandu-babu" To: "Arsalan H. Awan" , "dev@dpdk.org" CC: "Somalapuram, Amaranath" , "Sebastian, Selwin" , "Giriyapura, Maheshwaramurthy" Subject: RE: [PATCH] net/axgbe: fix PCI ID to distinguish v1000 vs e3000 Thread-Topic: [PATCH] net/axgbe: fix PCI ID to distinguish v1000 vs e3000 Thread-Index: AQHX1iiJV8q+ALSOzEaloXAtM6obMqv/+Tdg Date: Fri, 12 Nov 2021 14:48:14 +0000 Message-ID: References: <20211110114519.8216-1-Arsalan_Awan@mentor.com> In-Reply-To: <20211110114519.8216-1-Arsalan_Awan@mentor.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_ActionId=a1f9d1a9-d3e3-426e-8e84-4fd9f15ce1af; MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_ContentBits=0; MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_Enabled=true; MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_Method=Standard; MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_Name=AMD Official Use Only-AIP 2.0; MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_SetDate=2021-11-12T14:37:06Z; MSIP_Label_88914ebd-7e6c-4e12-a031-a9906be2db14_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; authentication-results: mentor.com; dkim=none (message not signed) header.d=none;mentor.com; dmarc=none action=none header.from=amd.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 9ab52424-0680-4816-193b-08d9a5eb7519 x-ms-traffictypediagnostic: DM8PR12MB5431: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:10000; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: ojvM9QsKn/sq6MmHr3U7xLPdaKa6JIcRHkLvnhEiGVU8/sYEG3pxEQrI5q0sWIAzUiaPOCRGYDF/2t449/8wGF4xfdtBF9+p+IXdXQ+AgMZMPL3QhGMrISQkXgRfs+1FQWwwYMo8q46kbBWmOjqCBhp1rOPu9cSnizWmbZJxhw7126fSyHieeMobEmWsxEkOQUNKShvYDVmGAeoiEkbpJk7njhqCjkEeGf33xm+tsognoYN330FfPUILwV96y5sRdKllCr7ecGnz481DfWcC+l0b6YW9JeaOUhoHw5eRJ1UZ4b8LmkWpPb4kGjpaJCWAjzWb79ZvvASiJ3p7wgyqenRUscnoVSEjRTerZH9qYQZP/JybG6TDCZbAuRRQ8rfNkv8KcBTJ+AwSF+EPWptQPPRS80qH/J77R/8pTq6Nu83MG/E5EU9rBg/woAmLEhHvAeNadnFGI0KOQYvw8a3VbDfNwllG9Bh8ydRSXBTWLXu/3py7pmJV6ZVTzCn4ZEKgaUDCufo+gdZq9wgNbQKGolk44df8QshlCh3B5L8xP0BQ8PF6+9tBimH56AXR6NKYKeb9k5fqlAWE5H2ccsBCRXU3HO9FTUA3yE0KVmk7JR1eCF+RmegwYnNsEOom6/8Umlnlu6lz1OKhxuApQT4t8sOzjSWM0glLAzWnGo8ojkBIrWrylPfEasd+tSzBg1ulXe+hqQW613FR+KZnR4gseg== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM4PR12MB5344.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(8936002)(8676002)(5660300002)(64756008)(186003)(52536014)(122000001)(66946007)(33656002)(71200400001)(26005)(6506007)(86362001)(53546011)(7696005)(66446008)(2906002)(83380400001)(38070700005)(508600001)(110136005)(54906003)(66556008)(66476007)(76116006)(55016002)(316002)(9686003)(38100700002)(4326008); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?59AdMJrrUunY+zSaNYaq+KmhZGkVr5tvI2q1ITysxVCsHzKmfyPZQQYZeiEK?= =?us-ascii?Q?0ScJ1S42sESYLk/s4oN76mLwN+u56BUDSuk8q/ESengfcS0qc4twdJfjp3je?= =?us-ascii?Q?jkv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0z6OnNDsIxU?= =?us-ascii?Q?19GZoRnGKWVyQsiCNIoA4Z6svaGcU+0IbQMC93wDpw1uGRZAXLyFkLMiBmd4?= =?us-ascii?Q?guAvd8oGVz42rfgRV3EPF9SWw/clldZs+HRUwKSiwTnUfFze+pGxmWEdNM5x?= =?us-ascii?Q?xClnXfjVXSnVLGk2pf9PlXmX7Xw7vovFGxMI3S8F+AOQXPLYod417qzZTHiI?= =?us-ascii?Q?TWWnQAaExgesi2oGvOFYR0p8okY0RLjqj8UfhNPyNZWplWq7f31TqB0wEiKv?= =?us-ascii?Q?sSBB5ohUOEvfNc/+o3CO9hYIvDveTNbL1+060ZDhlI0SYSfajelbSptGCv4I?= =?us-ascii?Q?OR4Bpb/V0gvyRDx1jVedhj/QtMmTyoOP67opY70kBckaKb7A4cFCRsroUn7l?= =?us-ascii?Q?fnytrF7T604R70c9SaQTwVyTL1Ja1Gfx2qB/LVFjthqVRlBeP7ADQ7D8RVRo?= =?us-ascii?Q?n9cc8B6UL86M0YGxbdZXypn8/SW2o1mTihsSScqEcgcMouw590aBXBlpuM3I?= =?us-ascii?Q?dMTpVxELn7tOlOIBJ4ajluXRdwUPC1vCEDVsdSc1CQP+gW4hr6oBU1LnL2Jv?= =?us-ascii?Q?yHBlMBLsB+l/U4necagVmQ55Dn9w+LR0Vkp3u5REPYCP4nfrUKbiSCIJ225G?= =?us-ascii?Q?bH6Ky8nHiuKYgWWtrWNGqnY=3D?= 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: DM4PR12MB5344.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9ab52424-0680-4816-193b-08d9a5eb7519 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Nov 2021 14:48:14.8967 (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: /bNzlDIddesT6uep+gup1T28K12lE0RQhwpmQOXUOgFUWMgNA7s9fFHvEcWZ2QWqSOrI1HZHeEDFsmC9qxNWGQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM8PR12MB5431 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 [AMD Official Use Only] Hi Arsalan Awan, Thank you for sharing the patch. DPDK not working on V1000 is regression du= e to "bus/pci: optimize bus scan" patch. As RV Root Complex device does not= have any Linux kernel driver assigned, this device is removed from PCI sca= n list and not found using pcie_search_device() routine. Patch submitted is potential fix for the issue, but we are checking if this= is the best way to fix regression. Will update you soon on the fix shared. Regards, Chandu -----Original Message----- From: Arsalan H. Awan Sent: Wednesday, November 10, 2021 5:15 PM To: dev@dpdk.org Cc: Namburu, Chandu-babu ; Somalapuram, Amaranath ; Sebastian, Selwin ; Giriy= apura, Maheshwaramurthy ; Arsalan H. A= wan Subject: [PATCH] net/axgbe: fix PCI ID to distinguish v1000 vs e3000 The RV PCI Root Complex Device is not visible to DPDK on the PCI bus via pc= i_search_device on some OSs including Ubuntu and Yocto. This makes it impos= sible to determine which machine DPDK/axgbe is running on. As a result, DPD= K/axgbe does not work on v1000. Let's use the Raven Internal PCIe GPP Bridge ID that DPDK can see on the PC= I bus that exists on the v1000 to differentiate between RV AXGBE and SNOWY = AXGBE, and set the registers accordingly. This fixes DPDK not working on v1= 000 platform. Signed-off-by: Arsalan H. Awan --- drivers/net/axgbe/axgbe_ethdev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/axgbe/axgbe_ethdev.c b/drivers/net/axgbe/axgbe_eth= dev.c index 7d40c18a86..7b1b46990f 100644 --- a/drivers/net/axgbe/axgbe_ethdev.c +++ b/drivers/net/axgbe/axgbe_ethdev.c @@ -170,7 +170,7 @@ static const struct axgbe_xstats axgbe_xstats_strings[]= =3D { /* The set of PCI devices this driver supports */ #define AMD_PCI_VENDOR_ID 0x1022 -#define AMD_PCI_RV_ROOT_COMPLEX_ID 0x15d0 +#define AMD_PCI_RV_INTERNAL_PCIE_GPP_BRIDGE_ID 0x15db #define AMD_PCI_AXGBE_DEVICE_V2A 0x1458 #define AMD_PCI_AXGBE_DEVICE_V2B = 0x1459 @@ -2178,9 +2178,9 @@ eth_axgbe_dev_init(struct rte_eth_dev *eth_dev) pdata->pci_dev =3D pci_dev; /* - * Use root complex device ID to differentiate RV AXGBE vs SNOWY AX= GBE + * Use Raven Internal PCIe GPP Bridge device ID to differentiate RV +AXGBE vs SNOWY AXGBE */ - if (pci_search_device(AMD_PCI_RV_ROOT_COMPLEX_ID)) { + if (pci_search_device(AMD_PCI_RV_INTERNAL_PCIE_GPP_BRIDGE_ID)) { pdata->xpcs_window_def_reg =3D PCS_V2_RV_WINDOW_DEF; pdata->xpcs_window_sel_reg =3D PCS_V2_RV_WINDOW_SELECT; } else { -- 2.17.1