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 BFD30455C3; Mon, 8 Jul 2024 07:59:43 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8002940E2E; Mon, 8 Jul 2024 07:59:26 +0200 (CEST) Received: from NAM02-BN1-obe.outbound.protection.outlook.com (mail-bn1nam02on2122.outbound.protection.outlook.com [40.107.212.122]) by mails.dpdk.org (Postfix) with ESMTP id 2E4FF40E32 for ; Mon, 8 Jul 2024 07:59:25 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PFdt2rSSY/PkT/IIV3ctEvo4mo/hzkIKUe2b7Bw+/G3mDP+yOqExsH5AQwF3+l+I0h0uMURqdTY+keyWAbgmXUMrHLbyCHC54KLj/DhFncAqiszaQhyIVqNyucdJp5GyaND9FUgolbP+XcLP5YozJU8FTP2V5t7/mcfhTFBVbOMAebTsMQiFGZ3cfgj54ajMKLU9ay7EzGPvnOJM1aWd0kFx+w9mnHHuWa/Hsa/wjpFqj2LUUM6gy9yEQrxKVJ0mx588m4lgYD61QPvSvSUaZgalx9RgxXHldHA3ZnQT7Ud0XHUX4IcTtgFnGsTCHGNjJdmOvzouRyMsy4A9P91y0A== 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=p64hUxkicniOAYwq8iKQMxOI6MhjeHh5BudBbr/9XQA=; b=F+pkWUSKu6qfYbkj9bTvOleZko08BFh3V3qZdpf8yDHGD67X1UIsdkBqAo9VUzi0HdK4S1qYTfcilwlHwm/SL3ScjGyTewWgwDRBlj8dNiY0IMUbyYTrLAgg9K2KGG/MkyT4W1bjfnbIntCGqeeeI1M4uDWwhwnivVl5poDAPhs0Qjc4EJsFc2bo3BGV7UCL2R2N7SYRd1NYX7xmacLbCHp9rT9xzivC2w60p48tU3XEITt6xEjtOxUNjWNZmQDxxDPDS8Wk15xh8Bvdlckp50Gpaj0ogO6jbXIeaBzI89spbIqYpVjF1hGX/kLIZlzxtZCCJqog/zb41J+7T0Zq2A== 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=p64hUxkicniOAYwq8iKQMxOI6MhjeHh5BudBbr/9XQA=; b=QkWmE3N5QjDdfEO4s9FzioYvR7ahZLu9HDQSRLVeQDWXFtdIl7FFNl9wtMLtCNTF0lQOd1l/6muTk4xmexAbJ0EIYsJcCLY87sZsjdHzKaO6CKqP/5OA47YCL4jwBjp+1TqvQ6BTjJQUU9y9jTGA3BTR0CDUx+N9luHCpoDwsMI= 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 SJ0PR13MB5452.namprd13.prod.outlook.com (2603:10b6:a03:421::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7741.34; Mon, 8 Jul 2024 05:59:21 +0000 Received: from SJ0PR13MB5545.namprd13.prod.outlook.com ([fe80::b900:5f05:766f:833]) by SJ0PR13MB5545.namprd13.prod.outlook.com ([fe80::b900:5f05:766f:833%4]) with mapi id 15.20.7741.033; Mon, 8 Jul 2024 05:59:20 +0000 From: Chaoyong He To: dev@dpdk.org Cc: oss-drivers@corigine.com, Long Wu , Chaoyong He Subject: [PATCH v2 4/4] net/nfp: vector Rx function supports parsing ptype Date: Mon, 8 Jul 2024 13:58:54 +0800 Message-Id: <20240708055854.107739-5-chaoyong.he@corigine.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20240708055854.107739-1-chaoyong.he@corigine.com> References: <20240619025914.3216054-1-chaoyong.he@corigine.com> <20240708055854.107739-1-chaoyong.he@corigine.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SJ0PR05CA0168.namprd05.prod.outlook.com (2603:10b6:a03:339::23) To SJ0PR13MB5545.namprd13.prod.outlook.com (2603:10b6:a03:424::5) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ0PR13MB5545:EE_|SJ0PR13MB5452:EE_ X-MS-Office365-Filtering-Correlation-Id: 58c66fbd-a85f-43da-6bf9-08dc9f131c2c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|52116014|1800799024|366016|376014|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?0LJIuxrBtXE3jKliflt7BJFNNUzgRAKRvJqF9MkAdw7wIAG1meGjwvMU2HSU?= =?us-ascii?Q?HIoqMtWE1dhsQTQuDTpxiRrK56GW/cuQYKiEmPduMfrq21+pRuzh3p09Hld6?= =?us-ascii?Q?EQkz2tnxhEMHvYaUOoNYsuHTcJVybT+PcVVJPa13Hi6lKNWyd8djRyKzpyIc?= =?us-ascii?Q?ohvyMv6s5fpt38Ttty/EJncJchOjic/4/UAudgIu6CYEmDhi/5sg3blVjnye?= =?us-ascii?Q?KsuvhqKFlsZYsXBuXfPj9JmIT4nHhP0et+D171YF5Ep6bQdOuf63665vC0BS?= =?us-ascii?Q?dXqLIQ5ITCz7ek9offAsKuHLD3IZaIEIjMqGzR1wsUKJ4bxw4Kms1EAkm4lO?= =?us-ascii?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KkfdOm5z2MOH?= =?us-ascii?Q?f6ydfLTuroValpWyROGVdieFidxxri77Py8iMYkkovx5oKX45nUrk1RbgxEu?= =?us-ascii?Q?I5XArbhwsAXLOstbOeqvd005qQhfzH71Bx1SJgPqfePY9Ls6SrM0+eH4p0P4?= =?us-ascii?Q?1JUCGsMyAbWY/EahBpLt6Ln3LCHErvWx8YvZ8d/vXdKIJ7FTSg=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SJ0PR13MB5545.namprd13.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(52116014)(1800799024)(366016)(376014)(38350700014); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?jDqDAn4BeDJguggTCpLNJ9ZujPYgOizSSXf0HO7EGeWj7tf0ICl7uHA4XeOr?= =?us-ascii?Q?4AysZsjWhVRfpCTSvowwBA7e6kBrJYx47ns4+voeZAZWSSorX2STMH6d7zam?= =?us-ascii?Q?vp6ttV9F7u0lJvTbqD6TcVNOzJ2OBWRhGIhqpC6ncjr7ucJaZhlOJ+p0ZMR/?= =?us-ascii?Q?7OZdLdM7C/Sw/NiYPt9Fb7W9i6iWziH3EOLN76QSm5Ux8grcz2M9N8ecKY/2?= =?us-ascii?Q?OtycC2bvBJv/z5tTPoLNz+GzMWSYB2RH/LY8MJ1NnziZ7iiedWe7Ff/ft/jp?= =?us-ascii?Q?yXXdpKHVtmMKXXwc58VmpwOeHHxFo/upvag4XfLP4C7pt3sTSrfjaedaC6rH?= =?us-ascii?Q?Cr+pZRG2ce1M+j8KAzSTPBjS4a35Sv9qQHKe84Kd5vqfCbHG4xSdyk8hYPYo?= =?us-ascii?Q?mvfJTKDE6HUmiCZnIWAnktqk9Fjh3aCUy+/PpW/tAii9oy9gNGFVF1itd6+z?= =?us-ascii?Q?l54lrfHzkbyadZ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ascii?Q?3iOeosie25DVljWA0WPxW2OgVmOtOlzxV1mJ4hmHzjxehol76uURQIX2uUVh?= =?us-ascii?Q?OT9Wd0ZgfLJnY6XYoQ/gPLoTgSLocgg1qdlO9rTgNF91EwrYSdlTxTJ54Kb5?= =?us-ascii?Q?cQuKrkeNb2aHRbKDWznGQUM6prD/KvTI4BTrn/NktRM+NRYVDZpKmhcpAgs+?= =?us-ascii?Q?tLcFAV9eb3taUb7HqnZFJ51KQ6J2hxkTwUamTyQxFCELzejeyplJZvGnoF7H?= =?us-ascii?Q?aw=3D=3D?= X-OriginatorOrg: corigine.com X-MS-Exchange-CrossTenant-Network-Message-Id: 58c66fbd-a85f-43da-6bf9-08dc9f131c2c X-MS-Exchange-CrossTenant-AuthSource: SJ0PR13MB5545.namprd13.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Jul 2024 05:59:20.8874 (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: Xb8sNvRu0RxUZGm2uSCfHxd7aOk8f1CRTMA+++bpCag7CJxtHUWJuKwA74Bg3/+Vu+iKz9cqEN20SNNsBu0A7peTl0+bq5pyWyu0Q4jPD24= X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR13MB5452 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: Long Wu Vector AVX2 Rx function supports parsing packet type and set it to mbuf. Signed-off-by: Long Wu Reviewed-by: Chaoyong He --- drivers/net/nfp/nfp_net_common.c | 2 +- drivers/net/nfp/nfp_rxtx.c | 2 +- drivers/net/nfp/nfp_rxtx.h | 3 +++ drivers/net/nfp/nfp_rxtx_vec_avx2.c | 2 ++ 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/net/nfp/nfp_net_common.c b/drivers/net/nfp/nfp_net_common.c index 08693d5fba..3d916cd147 100644 --- a/drivers/net/nfp/nfp_net_common.c +++ b/drivers/net/nfp/nfp_net_common.c @@ -1455,7 +1455,7 @@ nfp_net_supported_ptypes_get(struct rte_eth_dev *dev, size_t *no_of_elements) RTE_PTYPE_INNER_L4_SCTP, }; - if (dev->rx_pkt_burst != nfp_net_recv_pkts) + if (dev->rx_pkt_burst == NULL) return NULL; net_hw = dev->data->dev_private; diff --git a/drivers/net/nfp/nfp_rxtx.c b/drivers/net/nfp/nfp_rxtx.c index 4fc3374987..da41a0e663 100644 --- a/drivers/net/nfp/nfp_rxtx.c +++ b/drivers/net/nfp/nfp_rxtx.c @@ -350,7 +350,7 @@ nfp_net_set_ptype(const struct nfp_ptype_parsed *nfp_ptype, * @param mb * Mbuf to set the packet type. */ -static void +void nfp_net_parse_ptype(struct nfp_net_rxq *rxq, struct nfp_net_rx_desc *rxds, struct rte_mbuf *mb) diff --git a/drivers/net/nfp/nfp_rxtx.h b/drivers/net/nfp/nfp_rxtx.h index fff8371991..c717d97003 100644 --- a/drivers/net/nfp/nfp_rxtx.h +++ b/drivers/net/nfp/nfp_rxtx.h @@ -245,5 +245,8 @@ void nfp_net_tx_queue_info_get(struct rte_eth_dev *dev, uint16_t queue_id, struct rte_eth_txq_info *qinfo); void nfp_net_recv_pkts_set(struct rte_eth_dev *eth_dev); +void nfp_net_parse_ptype(struct nfp_net_rxq *rxq, + struct nfp_net_rx_desc *rxds, + struct rte_mbuf *mb); #endif /* __NFP_RXTX_H__ */ diff --git a/drivers/net/nfp/nfp_rxtx_vec_avx2.c b/drivers/net/nfp/nfp_rxtx_vec_avx2.c index 7c18213624..508ec7faa5 100644 --- a/drivers/net/nfp/nfp_rxtx_vec_avx2.c +++ b/drivers/net/nfp/nfp_rxtx_vec_avx2.c @@ -111,6 +111,8 @@ nfp_vec_avx2_recv_set_rxpkt1(struct nfp_net_rxq *rxq, nfp_net_meta_parse(rxds, rxq, hw, rx_pkt, &meta); + nfp_net_parse_ptype(rxq, rxds, rx_pkt); + /* Checking the checksum flag */ nfp_net_rx_cksum(rxq, rxds, rx_pkt); } -- 2.39.1