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 59D6AA0093; Thu, 8 Sep 2022 15:56:39 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EC1AD40DDC; Thu, 8 Sep 2022 15:56:38 +0200 (CEST) Received: from NAM04-BN8-obe.outbound.protection.outlook.com (mail-bn8nam04on2055.outbound.protection.outlook.com [40.107.100.55]) by mails.dpdk.org (Postfix) with ESMTP id 6C30B4021F; Thu, 8 Sep 2022 15:56:37 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Eb1qOlfcI+ZgKphudPVtteng3C9fkzGR6ujuaWjRMKKojCkXORUrDsUTMAbk7walmudWZPz7Q3lU32/OHABYCDMKS5G8pBZyGjTM9IVqqSfKGHtegAhSnbB/Y61J3kGB11kq02RJNPzONsEDkH6cKB0LSR0he5EyIr17bTqehjQmk5Og7Wxwhx/thfXtG2OX7Ot+W8QM825cdAIxq/oNMFgryJHZ6Yyqp/ABvqPvXeVjhJuGvo1OxMsbOcNa2auOri4g7ppgZXZ9YqgiFlGQiPHJz0sJF+WnYyJKnVQ97Re0s8ABGH93EV5Kktz7JfvtDbb3VhzW3iqrkxLL/cgvwg== 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=kN7hZi9+8CpDeS6d0bl0Gn2gHdPL426Q/oM3vEpDHtg=; b=ePF4V3kHsAFO4aPEoVeAa9rC3V2pk+hQg4QitNsWkkzQS3KhCQdMeck4X8K7mSCZo2WVj2pyKFXbc4FqsaCNhr4gzrY4uKkWHYgmoqQUPSUHbQb+Gt2AOJ5DmwZaND4vGkffK2tDiMGvAYA4bB9qk/KqRy8Lz9XFdbJeGPWjtTW0bVtmWRCyCDMi3eu+NLoZ6ffG/WUqSfe5rjc5tifm2aXHXCZStVXOJoUV6tl9eF3dsJJdRo32DOkE4b06nhZJyTw3S2WZbm7oWfxisY05UDKkdskE1Ko2H5jH15HUy3x2rNfv6UEgS5NqM8tcxhHBJfXhuwXz9RJwJe0b6Ectug== 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=kN7hZi9+8CpDeS6d0bl0Gn2gHdPL426Q/oM3vEpDHtg=; b=cJNtbdlGLAEqwooTKUzDt4STwhv06mmQgZU1+oqia85BkyMYm0o7oQzu27zcCcVaBSGu0V3CjhgkFKWhQkoMODzJz5TmliU/mVz+jD/Jq+FHYcDIHKsCuTBk+knf7CQ/hHQlYmfZ5sXw45jxX9nlh3WRC30d54iVAMrfM6X1ePo= Received: from MW2PR12MB2538.namprd12.prod.outlook.com (2603:10b6:907:5::14) by PH8PR12MB6820.namprd12.prod.outlook.com (2603:10b6:510:1cb::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5588.17; Thu, 8 Sep 2022 13:56:35 +0000 Received: from MW2PR12MB2538.namprd12.prod.outlook.com ([fe80::c57e:5ef8:1335:e1f4]) by MW2PR12MB2538.namprd12.prod.outlook.com ([fe80::c57e:5ef8:1335:e1f4%6]) with mapi id 15.20.5588.018; Thu, 8 Sep 2022 13:56:35 +0000 From: "Namburu, Chandu-babu" To: "Modali, Bhagyada" , "Yigit, Ferruh" CC: "dev@dpdk.org" , "stable@dpdk.org" Subject: RE: [PATCH v2 1/3] net/axgbe: reset the end of packet in scattered rx Thread-Topic: [PATCH v2 1/3] net/axgbe: reset the end of packet in scattered rx Thread-Index: AQHYwzOhWXGe05+3iEKuxTFt26QVzK3Vju9w Date: Thu, 8 Sep 2022 13:56:35 +0000 Message-ID: References: <20220907173326.124914-1-bhagyada.modali@amd.com> <20220908033109.126547-1-bhagyada.modali@amd.com> In-Reply-To: <20220908033109.126547-1-bhagyada.modali@amd.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_Enabled=true; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_SetDate=2022-09-08T13:55:42Z; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_Method=Privileged; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_Name=Public-AIP 2.0; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_ActionId=69edb2c1-6034-4f21-94c0-6d79817f3573; MSIP_Label_d4243a53-6221-4f75-8154-e4b33a5707a1_ContentBits=1 msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_enabled: true msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_setdate: 2022-09-08T13:56:33Z msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_method: Privileged msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_name: Public-AIP 2.0 msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_siteid: 3dd8961f-e488-4e60-8e11-a82d994e183d msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_actionid: 779af9f7-ef12-4522-bcfc-11c521834af5 msip_label_d4243a53-6221-4f75-8154-e4b33a5707a1_contentbits: 0 authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 350bc153-06b5-4b93-cca3-08da91a1f187 x-ms-traffictypediagnostic: PH8PR12MB6820:EE_ x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: UajyG2e1p1V3QjN1kz04JdvARXWm8HUD79dbtFLsQycFSyWoSuEAT0iFTbgZMlR03daAGZlrKm92t4wMg9Piw6P76RfsdMnVGesEqEpyBTiMAhI1c1eT33HFg7/mng7XkWABLzcus6CO83x3jF9P8dj3HPE9wLKuaecmZGNrOToHlghqOlAuruUqd9Mg0kA1DHY93EtsN6rksLIjxOAy7cvNEJ0oovoDcXzHfj0l3IrwxuN+w3U0YUuAqMPtnM6nLQD0W46HPm8K4c1iElZVW5Kl5l+6/LVWMwV/Uu/RUcl8Qdt1SRtXWL32gEE9BKF2GKh7Bn4qtL1+XCrH2coGI1OQRK6INxnpI9rkbFhJiaBcz8ggvA6pR3MFcHIDl8hlqSSUQ2SpKUnenCBYYpMwMiOMAvmZ9C7OmukxlV8jHQQbxMxtkIcjeVUd6ratpRwa+Cjzmw1g2F5IKmG8BehWGYho+pcKk+VFKaW39NwY3AXEkLs/AaqrMMcRvIoXbZgHZF3xhORIlCCzGYmLs7ezSvqjHtctl/7Glppu1xhy4dg1yoGv0vfWpF7HmrWdk5Pn5Qf9ORB+adXZIdbtlIF/lzdP8BTcA+3ZySEVovERBqhqWY4wAvmWmZ8HiccKmr6NBdnOamwiyNRLevOJu8F3SWKYFcZwOrKB9G8IQx7rWvzHhVntXOTAhVVQp6qUn3ZT3eNJJixB0iS9KIFBQUwdOqW4Z0FDp1t8FxZGipzyKTRMqAJS0BEyYRjshN5EWfOLy/bwrgChUps9P8q2PMkDLF7knN/adMMIaUCR/CY4NkM= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MW2PR12MB2538.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230016)(4636009)(346002)(396003)(39860400002)(376002)(136003)(366004)(186003)(55016003)(52536014)(7696005)(5660300002)(53546011)(6506007)(26005)(33656002)(41300700001)(9686003)(71200400001)(478600001)(316002)(38100700002)(38070700005)(83380400001)(122000001)(2906002)(6636002)(66476007)(54906003)(86362001)(66446008)(64756008)(8676002)(110136005)(450100002)(8936002)(66556008)(66946007)(4326008)(76116006)(83323001); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?Eed35EUna195rmV3CWFT1xI+Q0e924PlbK7fQrynNfdXiqtc8hUFgKZBtw/x?= =?us-ascii?Q?V999h+lfuqA197FFxhAE0w66LkS/D6B5fwNVRQyNgak9qVTtLlAp3FhZ7GrV?= =?us-ascii?Q?fI8FeQgth4yVz8PVv9u4DvMKnXcLXS+7VJSLZGKknXl9nL8UgyPhTS0KcsRC?= =?us-ascii?Q?E9lJiQOE0zt+MpJ19OUs3mctC0C7Z25dV0W8yFznMRZOkbwXH3ZS7mDyIX/a?= =?us-ascii?Q?9HONMd3gsGWwJ1fpwT/OMPAlM7E++Abh+cx04idlG4WSdMczcj/7Jqd017OO?= =?us-ascii?Q?n8NqJZyO/6joyNzf9q3E2zBYKuYU7dE7OXrB1YGQrOfsrRRbjFxjv1RBHMg5?= =?us-ascii?Q?mQymjlO+0av+wZ2uCk04q3D/fb3ihtvukDYhS3PzjtqlN9dhI6+V5wbh0KJw?= =?us-ascii?Q?T+b0MFmt/AB9C5AJG9A8Akq2FG5lJz2B9nyjVu6XCYsLbc5dtDDMo5frVC7f?= =?us-ascii?Q?pg/wL8op6qeQw8c5r3/+VMMweRsg+uLuhsirbj6T6LeApBDUyclyeUb/+tRl?= =?us-ascii?Q?B47B4z1zPwlxLRuYe8VEu1oCC8PLBnQbpYWH7PCba5v5Ex76AxfyP4v4qcwz?= =?us-ascii?Q?6wd8MnsGtm1Hlo+AFTyfkbblX5pbG2ofe0416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6qcxPGa9QUprKmiQIVymbHfuUJBbqyBQ9gkfbXhOJfCurgv?= =?us-ascii?Q?B9eBfmkjRWNUfPai+nc=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: MW2PR12MB2538.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 350bc153-06b5-4b93-cca3-08da91a1f187 X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Sep 2022 13:56:35.3692 (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: fA2z0sDsW1En5KpswCmcdOvc/827MKXNkSuiKTYRlD8U5/+xDf7A1v/3uuIoa1cu5x0/Ts5pLyvgVOd3Dscz+Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH8PR12MB6820 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 [Public] For the series, Acked-by: Chandubabu Namburu -----Original Message----- From: Modali, Bhagyada =20 Sent: Thursday, September 8, 2022 9:01 AM To: Namburu, Chandu-babu ; Yigit, Ferruh Cc: dev@dpdk.org; stable@dpdk.org; Modali, Bhagyada Subject: [PATCH v2 1/3] net/axgbe: reset the end of packet in scattered rx Reset the eop in the failure scenario and also after the last segment. Removed the packet length updation explicitly as it is done in Chaining. Fixes: 965b3127d425 ("net/axgbe: support scattered Rx") Cc: stable@dpdk.org Signed-off-by: Bhagyada Modali --- drivers/net/axgbe/axgbe_rxtx.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/drivers/net/axgbe/axgbe_rxtx.c b/drivers/net/axgbe/axgbe_rxtx.= c index 8b43e8160b..e1488483bc 100644 --- a/drivers/net/axgbe/axgbe_rxtx.c +++ b/drivers/net/axgbe/axgbe_rxtx.c @@ -346,10 +346,11 @@ uint16_t eth_axgbe_recv_scattered_pkts(void *rx_queue= , uint32_t error_status =3D 0; uint16_t idx, pidx, data_len =3D 0, pkt_len =3D 0; uint64_t offloads; + bool eop =3D 0; =20 idx =3D AXGBE_GET_DESC_IDX(rxq, rxq->cur); + while (nb_rx < nb_pkts) { - bool eop =3D 0; next_desc: idx =3D AXGBE_GET_DESC_IDX(rxq, rxq->cur); =20 @@ -416,9 +417,12 @@ uint16_t eth_axgbe_recv_scattered_pkts(void *rx_queue, mbuf->pkt_len =3D data_len; =20 if (first_seg !=3D NULL) { - if (rte_pktmbuf_chain(first_seg, mbuf) !=3D 0) + if (rte_pktmbuf_chain(first_seg, mbuf) !=3D 0) { rte_mempool_put(rxq->mb_pool, first_seg); + eop =3D 0; + break; + } } else { first_seg =3D mbuf; } @@ -462,8 +466,8 @@ uint16_t eth_axgbe_recv_scattered_pkts(void *rx_queue, rte_pktmbuf_free(mbuf); goto next_desc; } + eop =3D 0; =20 - first_seg->pkt_len =3D pkt_len; rxq->bytes +=3D pkt_len; mbuf->next =3D NULL; =20 -- 2.25.1