From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <dev-bounces@dpdk.org>
Received: from dpdk.org (dpdk.org [92.243.14.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 2B0D6A04DD;
	Mon, 26 Oct 2020 23:20:28 +0100 (CET)
Received: from [92.243.14.124] (localhost [127.0.0.1])
	by dpdk.org (Postfix) with ESMTP id 7DE571E2B;
	Mon, 26 Oct 2020 23:20:26 +0100 (CET)
Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com
 [66.111.4.27]) by dpdk.org (Postfix) with ESMTP id 6BF0D100C
 for <dev@dpdk.org>; Mon, 26 Oct 2020 23:20:24 +0100 (CET)
Received: from compute2.internal (compute2.nyi.internal [10.202.2.42])
 by mailout.nyi.internal (Postfix) with ESMTP id 0BFB55C0060;
 Mon, 26 Oct 2020 18:20:22 -0400 (EDT)
Received: from mailfrontend2 ([10.202.2.163])
 by compute2.internal (MEProxy); Mon, 26 Oct 2020 18:20:22 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h=
 from:to:cc:subject:date:message-id:in-reply-to:references
 :mime-version:content-transfer-encoding; s=fm2; bh=efm9kXYZBrnwG
 ZP9NM6rTJPcRWwPyAXhxsW+xDukr7U=; b=B3UKA+5qOzKYM/4ZCZntPMcjtpsBA
 aQNhV6bSKWxLvcxkM+CTtqxHzBaMCjLJXEqpfV6q/1neeEqzBZjCNUcWYYdAkR55
 bUjdNIxqcmxE7d1PUSFyiytm5Zeqv0teS8mNn/XPYMqfQvCpJNfnMG2C8O5/XMox
 qHAHKlNrht22Be6cEo4iJO4ReaHREFBcMy5F4HHMfgb3ZAh466UIMZiPjq06Q/r7
 t2uEPW3IxwuYM5jR7Ijjs/jtyrbxMCCB2sBbLgNJyBOsAB5YgxcgdlPAn9vbMNhN
 VTrMgWvXxRM9bb4po3NU41bLdd9/pM8my1qSKBxe/kXOd6Yl5kyPZY68A==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=
 messagingengine.com; h=cc:content-transfer-encoding:date:from
 :in-reply-to:message-id:mime-version:references:subject:to
 :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=
 fm1; bh=efm9kXYZBrnwGZP9NM6rTJPcRWwPyAXhxsW+xDukr7U=; b=cBx4I+dg
 9GgXCjiLYAMRv70u7LmeRD0vUXTu5VfCXFsT+e89t+oqrc7B36K7ZMv7SueaoEno
 jmvr02IOEZabts0hLWXPClPYRcoEKqVRK0KerUCqLCH1C/ruHB/ovw0aTYBvOVAS
 qFrcLJ6VMLNKz9tQmxvscW/Jlx4RNV0YZgZEkRZGpAikZA/+94L32fZgdJotqD7j
 I2US43tmLFpYAZIqfkp/ORA9ntsBkxlqHQ7WwTiihJr9dWJGnIrme3ZGYsaOxdza
 XMwWEoGIh847DCO/V7n31+NLib6be/dpHYobe1ygD3wvVVzDBfToZ7KWr5N+5txP
 SjpG0Bg/IYzvpA==
X-ME-Sender: <xms:pUuXXwqh3fq4ZusnKBK1_C4QFXKo32I86cLF6xOjMHz35Hm7QLoAPA>
 <xme:pUuXX2qpOlg_hmsVeV7Awmc9_J_6uIqe-9hRD30eG1EhNi-9SuKzMduo8o7vlGF-F
 5K1AcyOXoKRGtc9mA>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrkeejgdduvdegucetufdoteggodetrfdotf
 fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen
 uceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkofgjfhgggfestdekre
 dtredttdenucfhrhhomhepvfhhohhmrghsucfoohhnjhgrlhhonhcuoehthhhomhgrshes
 mhhonhhjrghlohhnrdhnvghtqeenucggtffrrghtthgvrhhnpedvhefgiedvjeegtdevhe
 efhfetleefgfeivefgffevfeejgedtgfeutdehtdegveenucfkphepjeejrddufeegrddv
 tdefrddukeegnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrh
 homhepthhhohhmrghssehmohhnjhgrlhhonhdrnhgvth
X-ME-Proxy: <xmx:pUuXX1O2R1YXNwY-J-XFLORXpGiAUU8IqHO4_kpRuHuLZIqNejaE8Q>
 <xmx:pUuXX36fvn1fElaZwY1N0OoyC3Ux5MEaFWGPz-debfOUM38B7laHtA>
 <xmx:pUuXX_7g4FWDr5wKMdbskcSvbJytQ4QPYpnmBG9imI_Fg-a591w9RA>
 <xmx:pkuXXy3FB6rnBPDkdGvdbo7wy2XtVSYHDqPShkyFVACKPk4OsJROZQ>
Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184])
 by mail.messagingengine.com (Postfix) with ESMTPA id 3B801306467D;
 Mon, 26 Oct 2020 18:20:20 -0400 (EDT)
From: Thomas Monjalon <thomas@monjalon.net>
To: dev@dpdk.org
Cc: ferruh.yigit@intel.com, david.marchand@redhat.com,
 bruce.richardson@intel.com, olivier.matz@6wind.com,
 andrew.rybchenko@oktetlabs.ru, akhil.goyal@nxp.com
Date: Mon, 26 Oct 2020 23:19:58 +0100
Message-Id: <20201026222013.2147904-1-thomas@monjalon.net>
X-Mailer: git-send-email 2.28.0
In-Reply-To: <20201026052105.1561859-1-thomas@monjalon.net>
References: <20201026052105.1561859-1-thomas@monjalon.net>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Subject: [dpdk-dev] [PATCH v2 00/15] remove mbuf userdata
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
Errors-To: dev-bounces@dpdk.org
Sender: "dev" <dev-bounces@dpdk.org>

The mbuf field userdata (aliased as udata64)
was announced to be removed for two reasons:
  - applications, libraries and drivers used the same field
    for different purposes, with a risk of usage conflict.
  - this field always used 8 bytes even if unneeded

Some dynamic fields are created when needed to replace
the big static userdata field.
As a consequence, 8 bytes can be re-allocated to dynamic fields.

This mbuf layout change is important to allow adding more features
(consuming more dynamic fields) during the next year.


v2 (thanks David & Andrew):
- fix some indentations
- return -rte_errno consistently
- make some type casts more precise
- define dynfield types in macros
- hide field description in rte_security
- do not lookup security dynfield in ipsec-secgw
- do not use the existing timestamp field for other purpose


Thomas Monjalon (15):
  examples: enclose DPDK includes with angle brackets
  kni: move header file from EAL
  mbuf: fix typo in dynamic field convention note
  node: switch IPv4 metadata to dynamic mbuf field
  security: switch metadata to dynamic mbuf field
  event/sw: switch test counter to dynamic mbuf field
  net/ark: ignore user data
  net/bnxt: switch CFA code to dynamic mbuf field
  net/vmxnet3: switch MSS hint to dynamic mbuf field
  test/distributor: switch sequence to dynamic mbuf field
  test/graph: switch user data to dynamic mbuf field
  app/eventdev: switch flow ID to dynamic mbuf field
  examples/bbdev: switch to dynamic mbuf field
  examples/rxtx_callbacks: switch to dynamic mbuf field
  mbuf: remove userdata field

 app/test-eventdev/test_order_atq.c            |  4 +-
 app/test-eventdev/test_order_common.c         | 16 +++-
 app/test-eventdev/test_order_common.h         |  6 ++
 app/test-eventdev/test_order_queue.c          |  4 +-
 app/test/test_distributor.c                   | 28 +++++-
 app/test/test_graph.c                         | 94 +++++++++++--------
 doc/guides/prog_guide/rte_security.rst        |  9 +-
 doc/guides/rel_notes/deprecation.rst          |  1 -
 doc/guides/rel_notes/release_20_11.rst        |  3 +
 doc/guides/sample_app_ug/rxtx_callbacks.rst   |  4 +-
 drivers/crypto/octeontx2/otx2_cryptodev_sec.c |  5 +-
 drivers/event/sw/sw_evdev_selftest.c          | 23 ++++-
 drivers/net/ark/ark_ddm.h                     |  2 +-
 drivers/net/ark/ark_ethdev_rx.c               |  1 -
 drivers/net/ark/ark_ethdev_tx.c               |  1 -
 drivers/net/ark/ark_udm.h                     |  2 +-
 drivers/net/bnxt/bnxt_ethdev.c                | 19 ++++
 drivers/net/bnxt/bnxt_rxr.c                   |  2 +-
 drivers/net/bnxt/bnxt_rxr.h                   |  5 +
 drivers/net/bnxt/rte_pmd_bnxt.h               |  3 +
 drivers/net/ixgbe/ixgbe_ipsec.c               |  5 +-
 drivers/net/ixgbe/ixgbe_rxtx.c                |  6 +-
 drivers/net/octeontx2/otx2_ethdev.h           |  1 +
 drivers/net/octeontx2/otx2_ethdev_sec.c       |  5 +-
 drivers/net/octeontx2/otx2_ethdev_sec_tx.h    |  2 +-
 drivers/net/octeontx2/otx2_rx.h               |  2 +-
 drivers/net/vmxnet3/vmxnet3_ethdev.c          | 15 +++
 drivers/net/vmxnet3/vmxnet3_ethdev.h          |  6 ++
 drivers/net/vmxnet3/vmxnet3_rxtx.c            |  9 +-
 examples/bbdev_app/main.c                     | 68 +++++++++-----
 examples/bond/main.c                          | 11 +--
 examples/ipsec-secgw/ipsec-secgw.c            |  9 +-
 examples/ipsec-secgw/ipsec_worker.c           | 12 ++-
 examples/rxtx_callbacks/main.c                | 20 +++-
 examples/tep_termination/vxlan_setup.c        |  2 +-
 kernel/linux/kni/meson.build                  |  2 +-
 lib/librte_eal/linux/include/meson.build      |  1 -
 lib/librte_kni/meson.build                    |  2 +-
 .../include => librte_kni}/rte_kni_common.h   |  3 +-
 lib/librte_mbuf/rte_mbuf_core.h               |  8 +-
 lib/librte_mbuf/rte_mbuf_dyn.h                |  2 +-
 lib/librte_node/ip4_lookup.c                  |  7 ++
 lib/librte_node/ip4_rewrite.c                 | 10 ++
 lib/librte_node/node_private.h                | 12 ++-
 lib/librte_security/rte_security.c            | 22 +++++
 lib/librte_security/rte_security.h            | 32 +++++++
 lib/librte_security/rte_security_driver.h     |  3 +
 lib/librte_security/version.map               |  3 +
 48 files changed, 379 insertions(+), 133 deletions(-)
 rename lib/{librte_eal/linux/include => librte_kni}/rte_kni_common.h (97%)

-- 
2.28.0