From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 351D2A0352 for ; Thu, 16 Jan 2020 09:52:10 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 751801C130; Thu, 16 Jan 2020 09:52:09 +0100 (CET) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 10B111C128 for ; Thu, 16 Jan 2020 09:52:07 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 16 Jan 2020 00:52:06 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,325,1574150400"; d="scan'208";a="273914227" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by FMSMGA003.fm.intel.com with ESMTP; 16 Jan 2020 00:52:05 -0800 Received: from fmsmsx117.amr.corp.intel.com (10.18.116.17) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 16 Jan 2020 00:51:54 -0800 Received: from FMSEDG001.ED.cps.intel.com (10.1.192.133) by fmsmsx117.amr.corp.intel.com (10.18.116.17) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 16 Jan 2020 00:51:54 -0800 Received: from NAM11-BN8-obe.outbound.protection.outlook.com (104.47.58.170) by edgegateway.intel.com (192.55.55.68) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 16 Jan 2020 00:51:54 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=S2Risw2zeAHz4KR0EQF0nQtExXXBYyI5VyfvV+/ZNSbPELUHwNS0NmpD0Ilum3fHs3bkki7PZLNDFXYc/Gnhd0Xnehra/YLeKkAtRb96t+ILtA0iADx21fCa16L8KERhxjwv3E3FooeJFa7Ctwde4ACt4gi4cNuUdQ5tyjLtoO2bxzrXHdGsvxAztpJwNJm9iOxIEHsJsftpHBe8joOoS3tSS6ay6hngbi04ItX2QwWR3SmN4+VPjGSPVVwgOCFF39r1PJoaNTMNpn6fj1m41F/FwzmSzhc/VyhCmN0EfjsNdY8z28a0xRFmqwq/8PLv4PD/hdpdvqlKn8NA703FAQ== 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-SenderADCheck; bh=Pbs4w7nfw2IVanJUXaRCQG9vLNVgKJWNm0UIN0PA724=; b=mL3nodUXMvou4uddZ+cv4lB4t4s614RKEfyxKE1SlrfEqst7HTc0oiMJAnoy4J1zYOU5CPp9HPGYdr2suChoB64PEWGN8Dhfe2rgcXu0BxqKEOGqUNyKSA6LvXKSlM1d8MUuH8WHjMId1WndC0CKXZBhHxp3N9dVWRu/GcB/QiNRdSmKK7pzM7p5zikKA8mp18P1VsdOy+n46oQcIhMGPHjFvmurjN5fEgIfDouHSGM8YoM/Y4b+fbq8xItEsVLLsQYwjO+n1VAVbU7lxwuXdNEYsF7wHb7aWQ2GBPQYPafm1sGgua2CBSoAkkW7Rs1t43KFPNTTLKBfibX9J3xTmg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Pbs4w7nfw2IVanJUXaRCQG9vLNVgKJWNm0UIN0PA724=; b=m/uLl9muu8NddAHa2sSoFIiQRA5N9xyfZKudZR4drU+zNc6mdD9Wz7MRYhpF+npBFSaQG46HwndJiLvInxnR1FUY+hlB9nOse+wZlEwe2IXC9n1xN0DzpFYvx1JcfP+DrWeaOBndAmr3ZwTAGzC5l3aTOMSbfuF6K2aGFc+2zJA= Received: from BL0PR11MB3268.namprd11.prod.outlook.com (10.167.234.158) by BL0PR11MB2963.namprd11.prod.outlook.com (20.177.204.220) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2644.20; Thu, 16 Jan 2020 08:51:53 +0000 Received: from BL0PR11MB3268.namprd11.prod.outlook.com ([fe80::e531:ec27:a648:56d4]) by BL0PR11MB3268.namprd11.prod.outlook.com ([fe80::e531:ec27:a648:56d4%4]) with mapi id 15.20.2623.017; Thu, 16 Jan 2020 08:51:53 +0000 From: "Girard, Guillaume" To: Stephen Hemminger CC: "users@dpdk.org" Thread-Topic: [dpdk-users] rte_pktmbuf_free does not reset headroom Thread-Index: AdXLwFbHYUX8kwe5Sua3Y5gffsLXqwAEWGkAAB4N7PA= Date: Thu, 16 Jan 2020 08:51:52 +0000 Message-ID: References: <20200115102928.64c865da@hermes.lan> In-Reply-To: <20200115102928.64c865da@hermes.lan> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMmY0ZTY4MmUtNzg4NC00MWUwLThiY2MtNTgwMjVkNjZkNWVkIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiUGdpZHhaTFozSXRZd3NENU5aaXZZeWw3VitOb3dORitOdUJPMkNVM2hmM0hUMnI0MlwvMW5WbjdKaUxveThydHEifQ== dlp-version: 11.2.0.6 dlp-product: dlpe-windows x-ctpclassification: CTP_NT dlp-reaction: no-action authentication-results: spf=none (sender IP is ) smtp.mailfrom=guillaume.girard@intel.com; x-originating-ip: [134.191.221.96] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 5d61bdc3-af7a-4aaa-0956-08d79a615559 x-ms-traffictypediagnostic: BL0PR11MB2963: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:9508; x-forefront-prvs: 02843AA9E0 x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(396003)(39860400002)(346002)(136003)(376002)(366004)(189003)(199004)(316002)(186003)(8936002)(86362001)(81166006)(81156014)(8676002)(4326008)(52536014)(478600001)(71200400001)(6916009)(7696005)(2906002)(26005)(15974865002)(6506007)(53546011)(55016002)(5660300002)(9686003)(33656002)(66446008)(64756008)(66556008)(66476007)(66946007)(76116006); DIR:OUT; SFP:1102; SCL:1; SRVR:BL0PR11MB2963; H:BL0PR11MB3268.namprd11.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: KL15JLx94fBvL75nIjukA8r6eiAr5tD7XDIwvnN2WJMJsBM5LkY/SQPMpguXoJywaaFJjoTEbVWnQYnqhwNS2W3k49NApWr/iZBi3riGBq6yw8G5CrePDDnXnbI/Y8m/tmNMPJguMvk61AlQIm9TQcQiVkRHhPty5rJVzmBo0pCIekSYisoBRSAHtKjOBdPDfWeuDedpEB7WHrGzJtfBYof3JSwBG+jK5RVW2vZp3KQ45sqeg6OmsenNRAmRlEohmolWUMpjzit/0nVebp2PZ5YgnJENbUAPrVjxHSrRUi/GzaVCiiWZERK1PcS+vC0g0M9OsHWYQuSLPpsT+wNeG5ylk4DYwO/VlkYiJMHjeg8J3ey9dkICBZQZeiwqDVTz4Amle9kAqeu0RQb7dbxblkGu1mNwAjrrSQJq+2iTVBr1ER0ob5VjRm4HUSxKqCPCyoh8dOQdAUF2PE3Yor6XDNQYZwY5HE4PTtsS56yPe5Yod3937jpMunA5xNlRUy83F9KyUWap6Whvf1AmP3mUVQ== x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 5d61bdc3-af7a-4aaa-0956-08d79a615559 X-MS-Exchange-CrossTenant-originalarrivaltime: 16 Jan 2020 08:51:52.9658 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: yem7jKtlgdWVgck6oOaIp/jk2+f3UbU60bFwByCiEvNKnLYbu5WjQ7BfcO2lv1qNVLWMrq4joqyc6gbrk82+eeF1309Opt/0odCQutj/TQU= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR11MB2963 X-OriginatorOrg: intel.com Content-Transfer-Encoding: quoted-printable Subject: Re: [dpdk-users] rte_pktmbuf_free does not reset headroom X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: users-bounces@dpdk.org Sender: "users" > From: Stephen Hemminger > Sent: Wednesday, 15 January 2020 19:29 > To: Girard, Guillaume > Cc: users@dpdk.org > Subject: Re: [dpdk-users] rte_pktmbuf_free does not reset headroom > = > On Wed, 15 Jan 2020 16:40:47 +0000 > "Girard, Guillaume" wrote: > = > > Hi, > > > > From my experiments prepending data to an mbuf, rte_pktmbuf_free() does > not reset the headroom. Is that intended? > > > > Thanks, > > Guillaume > > > > Intel Deutschland GmbH > > Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany > > Tel: +49 89 99 8853-0, www.intel.de > > Managing Directors: Christin Eisenschmid, Gary Kershaw Chairperson of > > the Supervisory Board: Nicole Lau Registered Office: Munich Commercial > > Register: Amtsgericht Muenchen HRB 186928 > > > = > Free doesn't need to do anything to the mbuf. After free the state of the= mbuf is > indeterminate (ie. it can be what ever rte_mbuf code wants). > = > The headroom is reset in rte_pktmbuf_reset() which is called by > rte_pktmbuf_alloc(). Thank you, that makes sense. In that case, I was fetching mbufs directly fr= om the pool, which is why I saw that behavior. I will change my code. Best regards, Guillaume Intel Deutschland GmbH Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany Tel: +49 89 99 8853-0, www.intel.de Managing Directors: Christin Eisenschmid, Gary Kershaw Chairperson of the Supervisory Board: Nicole Lau Registered Office: Munich Commercial Register: Amtsgericht Muenchen HRB 186928