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 0D5D643220; Sat, 28 Oct 2023 08:17:42 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3829140E25; Sat, 28 Oct 2023 08:16:48 +0200 (CEST) Received: from NAM10-BN7-obe.outbound.protection.outlook.com (mail-bn7nam10on2109.outbound.protection.outlook.com [40.107.92.109]) by mails.dpdk.org (Postfix) with ESMTP id 920D840DF6 for ; Sat, 28 Oct 2023 08:16:44 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LGskYktEaaRZIGvuzjOU3OkIx8HopJfkJi89Jq7gfV3ck8F7qk1Il8hvMbAtHmgUjBHEfH6rCExfOLb02nSAAE2Z5UznA07a3QmCdIlhXz6dPoAf4+dMsTITWKxZno27a8PBzt1rlQcoEFcTzGpPJ1U4327taeWF3AGdVFQBHCM4Zs+RA6ZonFsWIdFIPc3afxBW4QK9JtQR9RQHYNyW0JzxA8l4UddcK36Cyx1JlItbuHS4p0UQ27lBLAl9yChKj6Y05ZOTb+x9R4I6VDiMG5QC0mjdJhR3xL/8ywgknn8T92QqLmmc55U8jXox15riHUgCPr3vGfWh6zyRgvlmHg== 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=PofJ0EvCuvUiUZ29v9ygiabDgSc1yjv4ARqSZBYsLs8=; b=P1hUyI5YAkyEkVKSqxuUCBEMkctL3wXXMut6b7wq4lqHXz+3Btoi5/WoYVCSy6oxrbZ6/+dpB69qww6PfuFiuHol1EobEPPS84PhX4XzuB+XDYt4Ds5WRENEGV4AnwRPgE2C77VPu6XKzw3k9k6uA1HM7MHjbNL2PIbWaL5kpudx0fJpavdDCx6fW0XN+cXyNwTiD5hNKCMLomugcCCdgKIpzSG0B7+H7rdtJXO/bStm6Az0kVR+N4INXHpkGun5PmwLivSOlqTJorvK8drQRVsofOY0DxWubiK4FDF+MiBe255GJbxaFkCPY5L+RzbeTM5KN96tYwa0Sf4KrOOGQw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=corigine.com; dmarc=pass action=none header.from=corigine.com; dkim=pass header.d=corigine.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=corigine.onmicrosoft.com; s=selector2-corigine-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=PofJ0EvCuvUiUZ29v9ygiabDgSc1yjv4ARqSZBYsLs8=; b=K+Cs1ycHL6rB3lXTCGCTcjPNReFwYp4bjt6VBbgcBZgWhuuG9eVGRctZE3VF6qUFjtBA0CEpo4+aIEsV43jaKmorRQXPXLEqIJjxfzCNS+3IMW8a0X6C18/0Of0MUnt5vnTGgGGVAHlbBhjanPBqNelFoadrPbv+3WNeKVeOl64= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=corigine.com; Received: from SJ0PR13MB5545.namprd13.prod.outlook.com (2603:10b6:a03:424::5) by PH7PR13MB6268.namprd13.prod.outlook.com (2603:10b6:510:24f::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6933.22; Sat, 28 Oct 2023 06:16:43 +0000 Received: from SJ0PR13MB5545.namprd13.prod.outlook.com ([fe80::45b3:d83c:cff2:4a1b]) by SJ0PR13MB5545.namprd13.prod.outlook.com ([fe80::45b3:d83c:cff2:4a1b%6]) with mapi id 15.20.6933.022; Sat, 28 Oct 2023 06:16:43 +0000 From: Chaoyong He To: dev@dpdk.org Cc: oss-drivers@corigine.com, Chaoyong He , Peng Zhang Subject: [PATCH 09/11] net/nfp: unify the PMD name with macro Date: Sat, 28 Oct 2023 14:15:56 +0800 Message-Id: <20231028061558.1842855-10-chaoyong.he@corigine.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20231028061558.1842855-1-chaoyong.he@corigine.com> References: <20231028061558.1842855-1-chaoyong.he@corigine.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SJ0PR03CA0246.namprd03.prod.outlook.com (2603:10b6:a03:3a0::11) To SJ0PR13MB5545.namprd13.prod.outlook.com (2603:10b6:a03:424::5) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ0PR13MB5545:EE_|PH7PR13MB6268:EE_ X-MS-Office365-Filtering-Correlation-Id: cf952f6a-ba7e-4d2a-9d1a-08dbd77d7496 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: NvfR1IX6bw6o1thZVLPmOVUTd2AhI3zYAnqLFLPbiKPBC/MebCOWES82FzUNii/FFi0TKo0Mmxk9jDjdUO2dVIAEWoHu4SDU/lMGKvBrg/iqHI4cSuwtSLS06eC/zzHzbU0V7yIzFDdCkvkAaf8llje6vOEjUP+2aft9nsM9RCLDv2b3+Rx9WZrmDVSElqDcyjTGa5QAcbsIqqwtqKmwZgLVY0EBWQde6LtnXlulOhM9nV3gB0OTvVKQmYyFgMlkYICKV8gSE9wXx71ERpE9P30Pn4QdMZyyVhNT1sjQNsRT4WCEpLyFejVModSOrDJhaerY8FsqnmvMVP4OIbtVP1o3kEylbSz8dBMZ7cVQzqEs3+CbYW6xkijfaLmnJrqB2jU8kzkuZ8aPxTC4JmlBbtVGSFIo+RdkxMucTUyJPzmwBcMWM/Cm+P6ffVBNY/Ea/0HpoVtH6r6cN+Ob7J2vDW+K5vKjQFEaRCiiYqImUoDHqvoLKX3Sca7QOihSkYfOlhtX0R4b4BDy7DTGZ2veVbGATugWwjKoTH8JWXpMUJX81Mt/UmyST3lLY+nNLLqNqmohXl52PL0GdZ81EJ9ONh+/fo+lzMvQyUioGGL5lCdQ1VgRiU1SFwSTWmsroG06294rBrpJv2AZTuZH33RWTaWo+rR/EicERqrDn0yz4Ho= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SJ0PR13MB5545.namprd13.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(396003)(39830400003)(366004)(346002)(376002)(136003)(230922051799003)(186009)(1800799009)(451199024)(64100799003)(2906002)(38100700002)(83380400001)(1076003)(107886003)(5660300002)(2616005)(86362001)(6512007)(41300700001)(44832011)(36756003)(38350700005)(66476007)(316002)(6916009)(66946007)(54906003)(66556008)(52116002)(6666004)(6506007)(6486002)(8676002)(26005)(478600001)(4326008)(8936002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?KepcfKPKySmyl9d1tH3kO2yij3EI2KchnDVpJKws5HEqjxc6Gw1BF4/1v9mJ?= =?us-ascii?Q?dUhG/4DmEgMBcmgtVwj7sVMTsv3Rqmapfs3lmaFYx2eS2HtWeoq7EpUO4at/?= =?us-ascii?Q?MiDYM97Uu2ylenpOzky9rGoPkyiZi0OG7Sbq+BmdSG16oxUNAHeUcHui/Q3f?= =?us-ascii?Q?xcoQ9nUSIeWeZb2rn9YAaD0St/iqqlkx1bwNTegxWlbtydL7ZMc4naKhp/53?= =?us-ascii?Q?2EpWiVkM7Q1gWAWlFiQ4pCutAyFZVvWFUyx5KFMmqHtR8WDAKsNNCGNCUrw2?= =?us-ascii?Q?hc/P7M9w+0B4h4MGUIVvJUHYlOqW22dnHudK4AWBrCfjPWYozppmfJWqqR9F?= =?us-ascii?Q?g1FOoSoa0PWUhoqjcYjRyTmT/c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?Q?xrFZ61UvnacIMaVKWMQxN7h2Vpr6cg1FKIqvsaaWfVIqvWtGMBdO3hPkv8wU?= =?us-ascii?Q?ybgeNlEzWssvLkDAeoHEUYLZwcWeDtv7LGYI++Pp9wHXh1YC2Vk50mrEw1Kd?= =?us-ascii?Q?YVHyqe5hsyR1p6CgWqGXYmhaWU8ui7ZWxe+ETReyyJSFyaGtXagBmlRmoDKG?= =?us-ascii?Q?ATEZxi54A6p0mnZSflp5Ocr5CbxDaqg4spIROgjV5FbH+o4whOUFRYDYGzxb?= =?us-ascii?Q?uDJ5m84wAjwdwgYWxO5AauO7nl3/EOnXYLUTb4ItrMEfP445zcLLY0TFQWqO?= =?us-ascii?Q?+h/WjyxzCnVPw3twFhDyT8Do6HdQGk9b/5mJ1K5sEX9fKboMWlkxoU253Q6y?= =?us-ascii?Q?wA=3D=3D?= X-OriginatorOrg: corigine.com X-MS-Exchange-CrossTenant-Network-Message-Id: cf952f6a-ba7e-4d2a-9d1a-08dbd77d7496 X-MS-Exchange-CrossTenant-AuthSource: SJ0PR13MB5545.namprd13.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Oct 2023 06:16:43.3141 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fe128f2c-073b-4c20-818e-7246a585940c X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: x6FmbY69lAAeY8/Dyo0tSHzqujX+pB0W7VGRPXPkdZNmLBhbKfUAIpWqSU2oNz5pIHRDMWV95F1S5VnD09OeHDEHVqBQZqa28bpa6ZDtAMc= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR13MB6268 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 Unify the PMD name with a string macro, make it more extendable. Signed-off-by: Chaoyong He Reviewed-by: Peng Zhang --- drivers/net/nfp/nfp_ethdev.c | 8 +++++--- drivers/net/nfp/nfp_ethdev_vf.c | 6 ++++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/drivers/net/nfp/nfp_ethdev.c b/drivers/net/nfp/nfp_ethdev.c index 8057452799..c4a36027b9 100644 --- a/drivers/net/nfp/nfp_ethdev.c +++ b/drivers/net/nfp/nfp_ethdev.c @@ -21,6 +21,8 @@ #include "nfp_ipsec.h" #include "nfp_logs.h" +#define NFP_PF_DRIVER_NAME net_nfp_pf + static void nfp_net_pf_read_mac(struct nfp_app_fw_nic *app_fw_nic, uint16_t port) @@ -1233,6 +1235,6 @@ static struct rte_pci_driver rte_nfp_net_pf_pmd = { .remove = eth_nfp_pci_remove, }; -RTE_PMD_REGISTER_PCI(net_nfp_pf, rte_nfp_net_pf_pmd); -RTE_PMD_REGISTER_PCI_TABLE(net_nfp_pf, pci_id_nfp_pf_net_map); -RTE_PMD_REGISTER_KMOD_DEP(net_nfp_pf, "* igb_uio | uio_pci_generic | vfio"); +RTE_PMD_REGISTER_PCI(NFP_PF_DRIVER_NAME, rte_nfp_net_pf_pmd); +RTE_PMD_REGISTER_PCI_TABLE(NFP_PF_DRIVER_NAME, pci_id_nfp_pf_net_map); +RTE_PMD_REGISTER_KMOD_DEP(NFP_PF_DRIVER_NAME, "* igb_uio | uio_pci_generic | vfio"); diff --git a/drivers/net/nfp/nfp_ethdev_vf.c b/drivers/net/nfp/nfp_ethdev_vf.c index cb8a37bce7..d0834ccb3e 100644 --- a/drivers/net/nfp/nfp_ethdev_vf.c +++ b/drivers/net/nfp/nfp_ethdev_vf.c @@ -15,6 +15,8 @@ #include "nfp_logs.h" #include "nfp_net_common.h" +#define NFP_VF_DRIVER_NAME net_nfp_vf + static int nfp_netvf_start(struct rte_eth_dev *dev) { @@ -416,5 +418,5 @@ RTE_INIT(rte_nfp_vf_pmd_init) nfp_class_driver_register(&rte_nfp_net_vf_pmd); } -RTE_PMD_REGISTER_PCI_TABLE(net_nfp_vf, pci_id_nfp_vf_net_map); -RTE_PMD_REGISTER_KMOD_DEP(net_nfp_vf, "* igb_uio | uio_pci_generic | vfio"); +RTE_PMD_REGISTER_PCI_TABLE(NFP_VF_DRIVER_NAME, pci_id_nfp_vf_net_map); +RTE_PMD_REGISTER_KMOD_DEP(NFP_VF_DRIVER_NAME, "* igb_uio | uio_pci_generic | vfio"); -- 2.39.1