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 55E6942DF6; Fri, 7 Jul 2023 10:35:17 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D497E406B5; Fri, 7 Jul 2023 10:35:16 +0200 (CEST) Received: from NAM04-BN8-obe.outbound.protection.outlook.com (mail-bn8nam04on2083.outbound.protection.outlook.com [40.107.100.83]) by mails.dpdk.org (Postfix) with ESMTP id 46B0740685 for ; Fri, 7 Jul 2023 10:35:15 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CehGBHxLX54qcrJl7/p7SWNd/DBDVeDV9+32qkhpYzOeY1DLCAyKsvedKuWq6K5JOGVdAwzfOM1gBRqxEZNwSVQj696b9yICCyag2oMH2kzEdbIhNK2gd+yKxeBdOJARcC6aYI3OErhWPjKMhRdUp48C8J8YF2Bu175sau2eLGE/5ZQPD2a2Ya7NOosucU6YPzp33AIAq7FZVJm+td83xMqdzKGqDcfNdUaj5XEySVjUXdRhmPxnvrlsfOjmiMk+SUPzdHr2sgTk0UgT/xBn3sLJ7tzxr+mIsmmlQm8A+i6dfCJwr04kpNvoph6zIIsA8hfX1N7FB5j9eSiVOrYi4g== 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=lSpiX9cWjsumThvYBesxyCeu/GP1csCD1dXgP07HTvU=; b=J5Fx1CphJk3gVjb2K+ZFZ8jxLLS7xNZajcHaVg1gWxF1vsEOf4K/ucqz1xJhg6lMKgIs0eqiSzjkQ6dyEmGRX6Ml2vCEwvWLPblQ6cvvjLTqcM7kCto2cUpyXi1hzl8TpFW+2MvT1CONCh1eyvyHaVoYGhMQs/oxOUt4pLUEEodq/DsGdwKhb2aG88SNae3+O5O2EdNJbb65essJ5Aa6QtoCImnNcVsqEhh8A61LUml5tAftAvWvSUVXT0Y1e9lZtBk3TcyLuY6QOKTIgZXhQl1OxdUapt1b7KVZklefFGwKB3ntIUmd75HHJotDbGen3HVj5MgExK5y/Kpdy3z4Cw== 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=lSpiX9cWjsumThvYBesxyCeu/GP1csCD1dXgP07HTvU=; b=dRcmtg00iqU3INjweakW6EJIm/MnJCskdaLpcMYW/TF6j7la48IRkqQ6blnj4J7EKQuRfLyHRzQ2Oed5HvbeiuLyFgM+czuSqbpKpWRv4ARWuqMQ71y+QQvVNQtTjtsepogANNpo/5cBWNYJYUcs//g7BSfwVJkBbH0gVzYDLHA= Received: from CH3PR12MB8308.namprd12.prod.outlook.com (2603:10b6:610:131::8) by CH2PR12MB4277.namprd12.prod.outlook.com (2603:10b6:610:ae::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6565.25; Fri, 7 Jul 2023 08:35:13 +0000 Received: from CH3PR12MB8308.namprd12.prod.outlook.com ([fe80::72a7:19eb:4df8:efea]) by CH3PR12MB8308.namprd12.prod.outlook.com ([fe80::72a7:19eb:4df8:efea%2]) with mapi id 15.20.6565.019; Fri, 7 Jul 2023 08:35:13 +0000 From: "Gupta, Nipun" To: "Gangurde, Abhijit" , "Agarwal, Nikhil" CC: "dev@dpdk.org" , "david.marchand@redhat.com" , "Yigit, Ferruh" , "Gangurde, Abhijit" Subject: RE: [PATCH] bus/cdx: provide driver flag for optional resource mapping Thread-Topic: [PATCH] bus/cdx: provide driver flag for optional resource mapping Thread-Index: AQHZqBqZ0w4ROkWrfEa1XBKW8uhFC6+uC18A Date: Fri, 7 Jul 2023 08:35:12 +0000 Message-ID: References: <20230626103958.3139-1-abhijit.gangurde@amd.com> In-Reply-To: <20230626103958.3139-1-abhijit.gangurde@amd.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_ActionId=6c09081b-30c6-44d0-98e3-b8ab24b0e1e4; MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_ContentBits=0; MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_Enabled=true; MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_Method=Privileged; MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_Name=Non-Business-AIP 2.0; MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_SetDate=2023-07-07T08:34:13Z; MSIP_Label_64e4cbe8-b4f6-45dc-bcba-6123dfd2d8bf_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: CH3PR12MB8308:EE_|CH2PR12MB4277:EE_ x-ms-office365-filtering-correlation-id: 0edfb4ed-f364-40fc-4252-08db7ec51500 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: wojt8HaRLVlZGqDTUaFL58lkhAflx4cqnlQ8JmJI0r5HiNQ1uRaIKT4D0ciwsKi7F/PR5Aro9CsZG1FrxK6Li5ZhT7fc5fRwZ9itdni9mOfFYih5tGB7OU8l8R9syQ5T4gnodwf28WdyKA3gy3SwS6q7lk5bZb6Tk6Vnh4+bDPahFIdrGGi0x36Gi12qDliV257fno8cBDft6okYcw/+I3DQjS4vmau+4WS82+rQUQo/jb6XwuX+zRLy9yIcI5sQRjtxXDDagVdyQSaoKer+nus/+bkyYDCKejG6NHGMsly6oVXN1xNAL3pecHEcgMtSZTUi0n0zCWz79/LHBjKupDvtt7fqd9B4tNnQCURmYzuDsPiTKMKpq5tmZpV/UuEjoKPrcVxogO9gVoNnDt6sgDIfmfRl/plP1ik+Mhva/+Q/vP8KJswICrb3h7pew1wRBNIwa+/DoVhVH+Ji6CReV/kH8W+dkAyKhpH462RivcW7yB9Onudavwjl9vrvZYIgVV/HEmMDFCODTQvMfojNB01KFlheMNQuu8Jd3ffDim4B2387uYf+oeF2zx/V/rSbCHq5vQgnd6FVtlK5qfiOWgoklSOiZJ+WEB2zwuTva28rcQYJehnRwVdhXVGEGqFu x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH3PR12MB8308.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(4636009)(136003)(39860400002)(366004)(346002)(376002)(396003)(451199021)(71200400001)(122000001)(7696005)(478600001)(110136005)(54906003)(52536014)(5660300002)(8676002)(8936002)(2906002)(38070700005)(33656002)(38100700002)(76116006)(66446008)(66476007)(66556008)(55016003)(66946007)(4326008)(64756008)(6636002)(316002)(41300700001)(6506007)(86362001)(83380400001)(186003)(53546011)(9686003); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?JaTHShXgB92UiHTN+HyipHePkokwKU+a05xGQWHLYIP7/AY6jsv2QBPEQkFv?= =?us-ascii?Q?ixo4DG3hRvd4dHh24ubkHRf4kmOMkl7II9KNY+XM5ZXxl64utS5LX4xC9fha?= =?us-ascii?Q?LTAmecCrJwX44XFVt2LIYBURYnwLrdul+KDpI/KqXRa/RnZfxmvx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zuw7voAyhvM17ygfGATgu/lxmfcoUarW7kcDIr?= =?us-ascii?Q?620fi6MFfPnS4cyJGohEp/pWB68lvrCUyhy5mmEdzF0V4Tk4wAc1l/KVy9+e?= =?us-ascii?Q?y+4r+eM6kVq6rSleBZ5/wpI75yW6O8NEYabm0mF3zF1PSVolDw7eLxYquv6E?= =?us-ascii?Q?bblA9Y/tmmIk64nHjVq/EzkiYiTKWGADMs5QBlius0VmBxRgDYoI+hZt/HWg?= =?us-ascii?Q?fn9bJVYs+kMl87dyRrbniEeUAQkzEPKjCHUvj+YBFmh2IqTqW/wgWASb/biC?= =?us-ascii?Q?fPIQ4s3vDstdz8jLGw1APwo0xlW3FuT/uSxcn0C/5RNPNsaLxfkSVEj+h5UT?= =?us-ascii?Q?sR79Nz9X0ZMwvifTm7TcdEX3sdzdg2fZLWOLEj706Re+6PM55bmpAyfgGauj?= =?us-ascii?Q?roX2pJM6A25ikCoyrGlGWYAQ0SIwWhvsSL9JuSOM5VN8f9d3BTMdAygP9ZV0?= =?us-ascii?Q?e82J+MRjysDBOwMxeTx9v6PjQbufyixzJD+N51qauCILo7w52dFxmNKzz4Rd?= =?us-ascii?Q?u7IRgtKtyNgLf/Y6BFaUKaz6FupcTXLpn54eKcRKjwfiObjRQK/MIABBGdxr?= =?us-ascii?Q?hxthgaBb/MCGxLwhiYaLFhs=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: CH3PR12MB8308.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0edfb4ed-f364-40fc-4252-08db7ec51500 X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Jul 2023 08:35:12.8707 (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: NzAs+npLdMlXIxmXsUHmcUD4Wga4ujGYm3YNjCIS9PyLqsRQNNDlH4GtmVx8izjA X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH2PR12MB4277 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 > -----Original Message----- > From: Abhijit Gangurde > Sent: Monday, June 26, 2023 4:10 PM > To: Gupta, Nipun ; Agarwal, Nikhil > > Cc: dev@dpdk.org; david.marchand@redhat.com; Yigit, Ferruh > ; Gangurde, Abhijit > Subject: [PATCH] bus/cdx: provide driver flag for optional resource mappi= ng >=20 > Provide driver flag which gives an option to map the cdx > device resource before probing the device driver. > Also, make rte_cdx_map_device() API as public to map > device resource separately. >=20 > Signed-off-by: Abhijit Gangurde > --- > drivers/bus/cdx/bus_cdx_driver.h | 26 ++--------------- > drivers/bus/cdx/cdx.c | 11 ++++--- > drivers/bus/cdx/rte_bus_cdx.h | 50 ++++++++++++++++++++++++++++++++ > drivers/bus/cdx/version.map | 11 +++++-- > 4 files changed, 69 insertions(+), 29 deletions(-) > create mode 100644 drivers/bus/cdx/rte_bus_cdx.h >=20 > +/* Forward declarations */ > +struct rte_cdx_device; > + > +/** > + * Map the CDX device resources in user space virtual memory address > + * > + * Note that driver should not call this function when flag > + * RTE_CDX_DRV_NEED_MAPPING is set, as EAL will do that for > + * you when it's on. > + * > + * @param dev > + * A pointer to a rte_cdx_device structure describing the device > + * to use > + * > + * @return > + * 0 on success, negative on error and positive if no driver > + * is found for the device. > + */ > +int rte_cdx_map_device(struct rte_cdx_device *dev); rte_experimental?