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 9517DA034C; Tue, 11 Jan 2022 19:44:46 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0F6CE42749; Tue, 11 Jan 2022 19:44:46 +0100 (CET) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by mails.dpdk.org (Postfix) with ESMTP id BD6E7410F1 for ; Tue, 11 Jan 2022 19:44:43 +0100 (CET) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.1.2/8.16.1.2) with ESMTP id 20BB239N012021; Tue, 11 Jan 2022 10:44:42 -0800 Received: from nam10-dm6-obe.outbound.protection.outlook.com (mail-dm6nam10lp2104.outbound.protection.outlook.com [104.47.58.104]) by mx0b-0016f401.pphosted.com (PPS) with ESMTPS id 3dh8nm1nar-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 11 Jan 2022 10:44:42 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AQzJ22tEGB5CZdYqSpVkIcvT7ZoGmCWRXguq5crPOq0/iDFz0rdqviCj/1zGAEzPvP34xFHG9gsBQUO2czUSQiYbZZNEXoGUmLYzMuImIZ2PUOS3ebNRzvqS0e69SkGAlyHxCUSLRvBO9dJrGRWtHMn/7UeIsaIzFMbX/OnIMBJRMLy79SDAgWGiRu0IN+8KlPKjk5pirK6GWlM480xFzLDvkBTXSixkoUMaVFe7xEveih267NnJfCJ7rvw+teU1kv8+J2Q1Dk5S8iHqXdRH32Pfto5skL2MxYfnfs+zbFgqJa5CKUJMvNGBQCbdr0yIRPg+6L4WKHfYXLTbiBrUFA== 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=Ss4UdftUwXa7xG9Z391gyP4Eax2rxzo+q/k3I5/x2s0=; b=WBCJ/fsUdvsa3ShfCN02K7+txDOca6hwqn8rP4VnAg7na2lquq3mRyhfsoow2s+fJ13rvD1fRk84FRDfAi5lwRpIlUFGphrmV2+mVubwFO26QyTMQ8F9565lYR9F0k+7Rip7Jz+2dIoOePhpg2SsjZlXKoRziIM4CCaLxHrMUfFFG0joOdd4DNuw9GCmFPa55xzQ/6qRpdO5UzWgVGZG2vwxeIbfKdwEC0eb1+apoTeV893QTeAEji4VvDZGOOVBY654mUEL3gsoNIgbIATUX0mwL3Jn3N/AhjuLCQGtBNtWFOsrSvAnZWEAPv6j0Q9A9gs3SBuHTVAugvtD18Cz5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=marvell.com; dmarc=pass action=none header.from=marvell.com; dkim=pass header.d=marvell.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector1-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Ss4UdftUwXa7xG9Z391gyP4Eax2rxzo+q/k3I5/x2s0=; b=O4NLHUdJE1L2YbiHOqvlTmfLGv0V76rB38af+FP5AcNb3+AXQDrv9TjUPrgp301Cif/p8bND9wsvPrahh7jvVqJ+SIJWceCaPQLQQApsJyrArSInFRpnDlhvOPVWpDGs3sj5vmuTrM5u9gUs/iCRHqb+9kLawq2fXT2pIjX8CIY= Received: from CO6PR18MB4484.namprd18.prod.outlook.com (2603:10b6:5:359::9) by CO1PR18MB4779.namprd18.prod.outlook.com (2603:10b6:303:ee::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4888.9; Tue, 11 Jan 2022 18:44:40 +0000 Received: from CO6PR18MB4484.namprd18.prod.outlook.com ([fe80::ecd1:2b8:57bd:7780]) by CO6PR18MB4484.namprd18.prod.outlook.com ([fe80::ecd1:2b8:57bd:7780%7]) with mapi id 15.20.4888.009; Tue, 11 Jan 2022 18:44:40 +0000 From: Akhil Goyal To: "Ananyev, Konstantin" , "dev@dpdk.org" CC: Anoob Joseph , "Nicolau, Radu" , "Doherty, Declan" , "hemant.agrawal@nxp.com" , "matan@nvidia.com" , "thomas@monjalon.net" , "Yigit, Ferruh" , "andrew.rybchenko@oktetlabs.ru" , "olivier.matz@6wind.com" , "Xu, Rosen" Subject: RE: [PATCH 3/8] ethdev: add mbuf dynfield for incomplete IP reassembly Thread-Topic: [PATCH 3/8] ethdev: add mbuf dynfield for incomplete IP reassembly Thread-Index: AQHYALPPmu8JVnwqYk2KffUFopwd36xeGRCAgAAa47A= Date: Tue, 11 Jan 2022 18:44:40 +0000 Message-ID: References: <20210823100259.1619886-1-gakhil@marvell.com> <20220103150813.1694888-1-gakhil@marvell.com> <20220103150813.1694888-4-gakhil@marvell.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 22adc43f-8728-4b3f-3641-08d9d5326cf6 x-ms-traffictypediagnostic: CO1PR18MB4779:EE_ x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: bMVkgZbimA5dk694e4adBtbPMVX1CH7lXJCZ6UfyZrzmI7JgL9t9csFkkGV5qCvQ13xvPZmJmWuAm86eUEiP8LyBs34/NUpGDdJV0isi52izTKvURTRZPttMFL0w7zVCXW4LXtKO6jhD01q+mqUIPToaRGvT60mOm6aWWqXIjEtuf1asxqGC/d83TqAyJgUFW4Tu/HVSmrzQGVAcO5Ghx6S+Njdwxnb3D1AN81mcWdlPLVpIS//t7YGcY1ogqmuZ3mFLcT5XiCAzAaeMPaa1OHwHRm/DMGyrcBKer3rLAGQa3z/XsnO2BUr+8B5XVDSyKNTfziNesv17gp4teqvzhAGtODzX0zh63IMOXMlNg8guFep1MV8TpiGIAfuZi0uW43yWsqSCbX6avoIHI0w20OvPsdQjjBzjanqlflWU3lfhQP3BOS5xDdU7FrragFvBaAMA8sSTpGEc+X6ZTJh5CVs/oaxOcPe2TQiPe+NJVdaaMfxQZ5YYnrzWxhuTx71PEjKGUFzmI0v5xD3nyKd4ufBfAN7hDwcJ86SrgmqyUg2XGq133DWCY6VvKg/qqC3btIOI03CqWFeH9JOnmil802jkb8Yue4J+MK9IBz8Cm61Oz0gDhRWre1Ru3kAVPGdbgY09bNobNah8k7PoHAiTuti4mxZLmH73YDY1ArdA16bVD8odZgZhOsLSsD4PzGGd+RQl3fY5tdj/L2iKcmhANQ== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CO6PR18MB4484.namprd18.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(54906003)(110136005)(38100700002)(8676002)(55016003)(122000001)(8936002)(71200400001)(316002)(26005)(186003)(508600001)(83380400001)(55236004)(4326008)(66446008)(38070700005)(86362001)(33656002)(6506007)(66556008)(66476007)(66946007)(7696005)(2906002)(76116006)(64756008)(9686003)(5660300002)(7416002)(52536014); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?6v6+U3wkBvaVwPRBIVq57Hy4UxvIECDBr5oBL9enrP/YD7U/TagRvqBmrnAP?= =?us-ascii?Q?PnnAaFXM2eJcvI08mpiJ0wXOjDoCTQzqL5uz9V6JIQ8evrb/ZEUqdiFWgy6G?= =?us-ascii?Q?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wTr1SU06U9VXkXXy?= =?us-ascii?Q?lk0R5pp4H90etbQVBRMUqRZ+rWgxDPDaNzBmgIuHoeo39Ci2F1U7YmK4re0E?= =?us-ascii?Q?YslDjhda8d7yTtHEYi4xAMVpqsNznxZX+kwTuT1qQ1D8yeJosm7n1BJVT2Bj?= =?us-ascii?Q?FAQ6vNzMjCFr0SVg141p8sYy38fj83QwHcX6DbRiwV8306kXh+8afE5Yr/wP?= =?us-ascii?Q?rf42yd2aQZ6VSGiDs6mV6IvGCM8Gia0X3oQ3D7wqMxz+XlQG05du8MHlU4nY?= =?us-ascii?Q?YbXglG5BTAaEUWyekb3ZA9HMh7n0fouO1tIbmEWsdQfTTSXCtVP/mcyKeWuR?= =?us-ascii?Q?kiJg9DocGg6LJb1I41/Z6g4zk4UMjsL5atFFRVKv1hiFH0scTIYVs+ZZMNbS?= =?us-ascii?Q?ZGYNO1s33toqsJIItAxYM7pZFoz7FC6IWctdPJmdhAUMD81r5Lyx4Sy0IGHv?= =?us-ascii?Q?U+Qm0FgLMfz722iroHnX/B0U1M2Awn7DNXJ95yFR+kvFsq/1IbDMtLOgrUYa?= =?us-ascii?Q?xSgGgi/CIw3i5bUNT0Xdup5cdm/Dv59DxhCEYJuqXlxWXbyDkDNuPy/WP5BU?= =?us-ascii?Q?HnziRcuww6RdHi7t9P5U4pwIaaIh062N/9zpM6dS+hljoJIK30ndeV28RbnW?= =?us-ascii?Q?6PT+HZ+ppklbbq2MqJ9gSpQ=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: marvell.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: CO6PR18MB4484.namprd18.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 22adc43f-8728-4b3f-3641-08d9d5326cf6 X-MS-Exchange-CrossTenant-originalarrivaltime: 11 Jan 2022 18:44:40.1229 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: +1JL7VD2HJLHZaSMYjHZdcrSIv1zWcyzcJ7laVeNalcPyPa46iSCkLN3LLTDEiCFb0ePSdbBEgtYEes+r7VhAg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR18MB4779 X-Proofpoint-GUID: zjNQC8-AuUeYiq_H9uvCYB-QXqPGfruu X-Proofpoint-ORIG-GUID: zjNQC8-AuUeYiq_H9uvCYB-QXqPGfruu X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.11.62.513 definitions=2022-01-11_04,2022-01-11_01,2021-12-02_01 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 >=20 > > Hardware IP reassembly may be incomplete for multiple reasons like > > reassembly timeout reached, duplicate fragments, etc. > > To save application cycles to process these packets again, a new > > mbuf ol_flag (RTE_MBUF_F_RX_IPREASSEMBLY_INCOMPLETE) is added to > > show that the mbuf received is not reassembled properly. >=20 > If we use dynfiled for data, why not use dynflag for > RTE_MBUF_F_RX_IPREASSEMBLY_INCOMPLETE? > That way we can avoid introduced hardcoded (always defined) flags for tha= t > case. I have not looked into using dynflag. Will explore if it can be used. > > > > +/** > > + * In case of IP reassembly offload failure, ol_flags in mbuf will be = set > > + * with RTE_MBUF_F_RX_IPREASSEMBLY_INCOMPLETE and packets will be > returned > > + * without alteration. The application can retrieve the attached fragm= ents > > + * using mbuf dynamic field. > > + */ > > +typedef struct { > > + /** > > + * Next fragment packet. Application should fetch dynamic field of > > + * each fragment until a NULL is received and nb_frags is 0. > > + */ > > + struct rte_mbuf *next_frag; > > + /** Time spent(in ms) by HW in waiting for further fragments. */ > > + uint16_t time_spent; > > + /** Number of more fragments attached in mbuf dynamic fields. */ > > + uint16_t nb_frags; > > +} rte_eth_ip_reass_dynfield_t; >=20 >=20 > Looks like a bit of overkill to me: > We do already have 'next' and 'nb_frags' fields inside mbuf, > why can't they be used here? Why a separate ones are necessary? >=20 The next and nb_frags in mbuf is for segmented buffers and not IP fragments= . But here we will have separate mbufs in each dynfield denoting each of the fragments which may have further segmented buffers.