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 A0ACD42600; Tue, 19 Sep 2023 11:55:25 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 28D9340275; Tue, 19 Sep 2023 11:55:25 +0200 (CEST) Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on2101.outbound.protection.outlook.com [40.107.96.101]) by mails.dpdk.org (Postfix) with ESMTP id B74064026E for ; Tue, 19 Sep 2023 11:55:23 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JuoJBYSSMULCdylmNZS88pTkZFfB3NLn6/WCZhvl55XXHmEv+kHrXtYlQc+RL5+S8OlOwNhM/x9H7oSWFYDvdOMex9EJGD/4jKqraKTqv7o5BY1UXtl3ZwwSgL9C8ciQv7oI5f+LFz02h4cfGTAsFlQv9pxxNcLz3Bj4Qrf08WauMLoRyMjy17RFt0TUGvYrhnZPfcT11YxauZ5X4awp73BUNzbOOeDwRwzK8bWYnkXYE0oIVVuBRXxxGd5DJPeFik2JUB2lCBQu8f6cMXV5De0NGawqPArO1mnaGh4gL4toQ2B5uaA36A+edKS6aMqHh7O8coxGib3t2PbfTDGsLQ== 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=u951jOVjH3R2EQDVPvu5tUT3mnPdTILJTU6YZ/+MkQA=; b=MfGzf0vKhwfQKH8hLPqr6KzayIyKTemqdyd9gC+5HPfQQi9FPW169VY/0+q1HXpcrPhsLdpKqHdCNJf2ppKkvDzu1KLWvm2AdQ0nGbDsYBBiW/8oB/n8BrzZoze8bOZigvdXU7tLUFsJRUXEW+YnY30+21fRAQda4dUihlA07yrg2jdShroc5+j4DGh0ycxtm1oaRPlLYsxSsEwWLTYbrr/YqrSZfFfsXhJH05ijvNypd/580SWjtRWpOYo894ZOMRSZWh2wbo9WMDOogRTHcl+UocQaT2iZtQUKtQPfDdzSmbPGJTUlohGltfP7+FtJa8ir3H+/oppYEXywo81lzQ== 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=u951jOVjH3R2EQDVPvu5tUT3mnPdTILJTU6YZ/+MkQA=; b=UsQjYraE8cxbQzIXM9IAyLCFYfl5q3TaeR+xM8Mfyr4yqA6enAmyZJm4tYhBDba0hYk7Iiybq3dsI4lI9C4iDEaG9pLFZQp8LDr2Gq7tGpX/dripUO6D4a5o38rRDHyENQp1NVe93JRE4JMnuKW9vi3TheW3RIpi+AAUP7eo+T0= 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 PH7PR13MB5868.namprd13.prod.outlook.com (2603:10b6:510:15a::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6792.26; Tue, 19 Sep 2023 09:55:19 +0000 Received: from SJ0PR13MB5545.namprd13.prod.outlook.com ([fe80::7a1c:2887:348a:84bd]) by SJ0PR13MB5545.namprd13.prod.outlook.com ([fe80::7a1c:2887:348a:84bd%6]) with mapi id 15.20.6792.026; Tue, 19 Sep 2023 09:55:19 +0000 From: Chaoyong He To: dev@dpdk.org Cc: oss-drivers@corigine.com, Chaoyong He Subject: [PATCH v5 00/26] refact the nfpcore module Date: Tue, 19 Sep 2023 17:54:14 +0800 Message-Id: <20230919095440.45445-1-chaoyong.he@corigine.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230918024612.1600536-1-chaoyong.he@corigine.com> References: <20230918024612.1600536-1-chaoyong.he@corigine.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: BY5PR04CA0014.namprd04.prod.outlook.com (2603:10b6:a03:1d0::24) To SJ0PR13MB5545.namprd13.prod.outlook.com (2603:10b6:a03:424::5) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ0PR13MB5545:EE_|PH7PR13MB5868:EE_ X-MS-Office365-Filtering-Correlation-Id: 7d207023-953e-4426-76cd-08dbb8f68815 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: JZoLkjgemSK31ER95pR/14XtXx3k4ioQanQL8K37db6K0zHCLAY9ZFeDSWqcS9K25Z0N7doSQebsr9ACbdrwmrNNhR7hLvFtv0kg7B3aR9/ZbNtJwfwPw964VP5L2ZvYjbfa4VhGiQ+qsw5xcBIH/wl+uNsYiYMMRIVXb1GYCqN9GO70MZ9uU00HkugJ8bke/RtQpVNOCWn9xcHZlYex9UUu00+95H/bioANZ+4HQPazs0VqBL60IglGQbKWcRNJKaHvZ6NFwylCtNOchVDEd6aLcRl03Ng/ZbQsx3R4ueu+k0lv6UENBAKlhyK1mJTtAWh1mxiRTcNcavKZhLZRW6IgHTUdtBDrEtcUf4sFLQbqQi7tpCaXxxqWbGBQ3vumkoWT1y3Lbhh8PLX/CNvBIjRl0lnQHaTg7K3kI8bPnNSsuBxtRZ4Ge65xLiZG4pnLe2vExmrRQa7b7gnc2mX/aKFxMBpsgxOv3Ms1ITOlWP55NnYSfnHnnahoEZA8/jyZYOsqVKqIrwSdcTNhP25Vz2akeGsKXAAZBHlaqaG432BqgZVtdBWuCU26U0nZgkJRS8ttnw0ezGd6rx//+W7RdxIva7LlEmAdUrrQPipejcQZUHgSD31F07WXcMY7xiN6qsDyFJY/MIirw/5mK+reGYoczxWsbXiaEGbPVgLUVrg= 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)(136003)(39830400003)(366004)(346002)(376002)(396003)(1800799009)(186009)(451199024)(26005)(8936002)(2616005)(1076003)(8676002)(4326008)(107886003)(83380400001)(2906002)(36756003)(44832011)(86362001)(52116002)(6506007)(6486002)(478600001)(5660300002)(6666004)(6916009)(316002)(6512007)(38100700002)(66946007)(66476007)(41300700001)(66556008)(38350700002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?UMgvXhkLArsGGkTlBzz939eDAmoMQlsh6xjR1DpsY9nDY0zRyt0CRD3yL4l3?= =?us-ascii?Q?5SCiiT5wmDTfWrBMdMXjh2Qd0SeurBv9E3odPYjSLn2+Itr6FoTLnzGXXSvc?= =?us-ascii?Q?bZilyVjZb1Kpq6JcwQgD+XwSuVwjPFOu19AYv2HcDxQa5fwkvVvYtDW072Yq?= =?us-ascii?Q?HF2lMBronQUx5lzyAjyyzcKWCpTx01GT0/i9Ju91IqHaUze+gQ79yq/fe4Vm?= =?us-ascii?Q?qymTi+zNnVGlmfCU7dCvIgvBG+j/bNRXFdYEw0jeLAUDkqNefQdRuKuL1gde?= =?us-ascii?Q?7v/h4Zjabv3Eqekcd6JN3Won6RVJ0LAIFAb1BXvfCOqrgQ/rnE+3qsUBJM3c?= =?us-ascii?Q?vHgOFmY7SSh4ujNkspCbUI6T0k5mWs7D335c9Ypqcz7Rj2AIISku34Htfp8B?= =?us-ascii?Q?5b9KscrDX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CSQLQUdHL2sKP?= =?us-ascii?Q?14uLYTUK9yF/qfkIX2qiLX0d4e2yrPPkIgjPxoI6v0kONJWolpeyQOSn4LTJ?= =?us-ascii?Q?+H89H12593GefEtrSVF+kbDSYwC8CKkE951DaNdY3AR/YPjquqVGpP6sdlrW?= =?us-ascii?Q?ej4tZPwv8B0IfgWYdA7HjPz80YBUvWqcatPTugaK04MYcghyR8XpTqn+yiK9?= =?us-ascii?Q?baOJqmRojvcUL8wg2O9dmobZjK8lwm44+dvROT0g8uoM2Bts3e88ZifObcXS?= =?us-ascii?Q?AgcMIySkYAdPmShiF/eQFRCCzCbmMgTK33AgzJLGhlAE3ur2y+u8bF3OYOD3?= =?us-ascii?Q?jg=3D=3D?= X-OriginatorOrg: corigine.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7d207023-953e-4426-76cd-08dbb8f68815 X-MS-Exchange-CrossTenant-AuthSource: SJ0PR13MB5545.namprd13.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Sep 2023 09:55:19.3210 (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: q6zDVU7ShZP+EvGmCTR1U30ROVBLfriCONQmp95Jc7n2s1XnIZ0lVSglRHUkb7ucnbkAeju3dBBzj6u/1awbMi1yrfCtfRAm+EW2fj+yZZc= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR13MB5868 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 This patch series aims to: - Make the coding style satisfy with DPDK. - Sync the logic with kernel driver. - Make the sub-module more modular. - Extend the nfp configure BAR from 8 to 24. --- v5: * Fix one bug in the logic of VF using dev module. * Remove the R-b tag as the requirement of Niklas. * Revise logic follow the advice of reviewer. v4: * Drop the commit 'using the DPDK memory management API'. * Modify the commit message of 'standard the comment style'. * Revise some comment logic as the advice of reviewer. v3: * Fix one bug in the BAR find logic. * Modify more coding style. v2: * Fix the compile error in Fodora 37 environment. --- Chaoyong He (26): net/nfp: explicitly compare to null and 0 net/nfp: unify the indent coding style net/nfp: unify the type of integer variable net/nfp: remove the unneeded logic net/nfp: standard the local variable coding style net/nfp: adjust the log statement net/nfp: standard the comment style net/nfp: standard the blank character net/nfp: unify the guide line of header file net/nfp: rename some parameter and variable net/nfp: refact the hwinfo module net/nfp: refact the nffw module net/nfp: refact the mip module net/nfp: refact the rtsym module net/nfp: refact the resource module net/nfp: refact the target module net/nfp: add a new header file net/nfp: refact the nsp module net/nfp: refact the mutex module net/nfp: rename data field to sync with kernel driver net/nfp: add the dev module net/nfp: add header file for PCIe module net/nfp: refact the cppcore module net/nfp: refact the PCIe module net/nfp: refact the cppcore and PCIe module net/nfp: extend the usage of nfp BAR from 8 to 24 drivers/net/nfp/flower/nfp_flower.c | 17 +- drivers/net/nfp/flower/nfp_flower.h | 3 +- .../net/nfp/flower/nfp_flower_representor.c | 6 +- drivers/net/nfp/meson.build | 3 +- drivers/net/nfp/nfd3/nfp_nfd3_dp.c | 5 +- drivers/net/nfp/nfdk/nfp_nfdk_dp.c | 5 +- drivers/net/nfp/nfp_common.c | 50 +- drivers/net/nfp/nfp_common.h | 52 +- drivers/net/nfp/nfp_cpp_bridge.c | 2 +- drivers/net/nfp/nfp_ethdev.c | 106 +- drivers/net/nfp/nfp_ethdev_vf.c | 25 +- drivers/net/nfp/nfp_rxtx.c | 5 +- drivers/net/nfp/nfp_rxtx.h | 12 - drivers/net/nfp/nfpcore/nfp6000/nfp6000.h | 20 - drivers/net/nfp/nfpcore/nfp6000_pcie.c | 1035 ++++++++++++++++ drivers/net/nfp/nfpcore/nfp6000_pcie.h | 20 + drivers/net/nfp/nfpcore/nfp_cpp.h | 776 +++--------- drivers/net/nfp/nfpcore/nfp_cpp_pcie_ops.c | 824 ------------- drivers/net/nfp/nfpcore/nfp_cppcore.c | 1080 +++++++++++------ drivers/net/nfp/nfpcore/nfp_crc.c | 23 +- drivers/net/nfp/nfpcore/nfp_dev.c | 81 ++ drivers/net/nfp/nfpcore/nfp_dev.h | 44 + drivers/net/nfp/nfpcore/nfp_hwinfo.c | 193 ++- drivers/net/nfp/nfpcore/nfp_hwinfo.h | 74 +- drivers/net/nfp/nfpcore/nfp_mip.c | 97 +- drivers/net/nfp/nfpcore/nfp_mip.h | 7 +- drivers/net/nfp/nfpcore/nfp_mutex.c | 379 +++--- drivers/net/nfp/nfpcore/nfp_mutex.h | 25 + drivers/net/nfp/nfpcore/nfp_nffw.c | 202 +-- drivers/net/nfp/nfpcore/nfp_nffw.h | 66 +- drivers/net/nfp/nfpcore/nfp_nsp.c | 574 ++++++--- drivers/net/nfp/nfpcore/nfp_nsp.h | 336 ++--- drivers/net/nfp/nfpcore/nfp_nsp_cmds.c | 19 +- drivers/net/nfp/nfpcore/nfp_nsp_eth.c | 518 ++++---- drivers/net/nfp/nfpcore/nfp_platform.h | 42 + drivers/net/nfp/nfpcore/nfp_resource.c | 208 ++-- drivers/net/nfp/nfpcore/nfp_resource.h | 36 +- drivers/net/nfp/nfpcore/nfp_rtsym.c | 452 +++++-- drivers/net/nfp/nfpcore/nfp_rtsym.h | 67 +- drivers/net/nfp/nfpcore/nfp_target.c | 9 +- drivers/net/nfp/nfpcore/nfp_target.h | 597 +-------- 41 files changed, 4083 insertions(+), 4012 deletions(-) create mode 100644 drivers/net/nfp/nfpcore/nfp6000_pcie.c create mode 100644 drivers/net/nfp/nfpcore/nfp6000_pcie.h delete mode 100644 drivers/net/nfp/nfpcore/nfp_cpp_pcie_ops.c create mode 100644 drivers/net/nfp/nfpcore/nfp_dev.c create mode 100644 drivers/net/nfp/nfpcore/nfp_dev.h create mode 100644 drivers/net/nfp/nfpcore/nfp_mutex.h create mode 100644 drivers/net/nfp/nfpcore/nfp_platform.h -- 2.39.1