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 3CA75A04B1; Mon, 14 Sep 2020 14:26:09 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 17D9FFFA; Mon, 14 Sep 2020 14:26:09 +0200 (CEST) Received: from new4-smtp.messagingengine.com (new4-smtp.messagingengine.com [66.111.4.230]) by dpdk.org (Postfix) with ESMTP id 2F23DE07 for ; Mon, 14 Sep 2020 14:26:08 +0200 (CEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailnew.nyi.internal (Postfix) with ESMTP id C744B5801F6; Mon, 14 Sep 2020 08:26:07 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute7.internal (MEProxy); Mon, 14 Sep 2020 08:26:07 -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=DU06Ptaq4XAsY 8vTZUnC35B7HTAzROH3yee9XmAehv0=; b=ipv8BsFA6RlWvTtHu5ZWmxzC1vGRi y1xD9rB2G5qYgxsyjy4K/KKKScG+G8qMwhHuvYmd1Cz95NFLj0mu0uslvHVCAARw N9uxm4fN1veT+ImF2+PGveY8g5o1FdiwaI5fyMU0HDjdfixD8TIjrWSKYVGQ9vy8 ZQ3BPaHGkqu4x/8SaFitOn84LTo+dBaySQBwdBr52spbSiB3hXDcTDb1l3chqRxS n4qKlmBLQjsEUrhll+67fd2KS+puPg+xbGfWqAyVBUdGhfQxs6uktmM4ErBmCkCD GekolgIqd3nmEryUtuDQKlgqSDiMo7vaB290b7oMCCaGPGnvE0hpZIIEg== 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= fm3; bh=DU06Ptaq4XAsY8vTZUnC35B7HTAzROH3yee9XmAehv0=; b=tsyFxVY1 Esr9+KoijjgLVPNnI9KTtvukCWZTISDnjdpXGnCqhzTE+urIQiEq6CDnGKAplkHW 7SJluVB+yw0mAhtgvwhGs7awblxqFdGlFE8mtymiAS9HHiBIILUtrfbW3PlphiFc mNtINwUxBJ5zNPVU4FETRUzpXjV/qO3/yLJeeM/uRvJOKNdZNzTKYP9lVj5sjaOi 7Yh9vvQIaYSll9oyehiU2yJOetj75+jRYre4bnHP4MlFy/Q3/rWFZwO4ZjzeiYlw OoLEvjEwmStAKh019CduHlHBr295aHFIm4w4aa1gFkGUjDdl4roBpWFZyuEWmbhv yOXD49bofcCg+A== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduiedrudeiiedghedvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepvdehgfeivdejgedtveehfefhteelfefgieevgfffveefjeegtdfg uedthedtgeevnecukfhppeejjedrudefgedrvddtfedrudekgeenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghl ohhnrdhnvght X-ME-Proxy: Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 992473280066; Mon, 14 Sep 2020 08:26:05 -0400 (EDT) From: Thomas Monjalon To: dev@dpdk.org Cc: konstantin.ananyev@intel.com, david.marchand@redhat.com, honnappa.nagarahalli@arm.com, nd@arm.com, Phil Yang , Ruifeng wang , Ray Kinsella , Neil Horman , John McNamara , Marko Kovacevic , Olivier Matz Date: Mon, 14 Sep 2020 14:25:57 +0200 Message-Id: <20200914122557.95278-1-thomas@monjalon.net> X-Mailer: git-send-email 2.28.0 In-Reply-To: <1599809752-25256-1-git-send-email-phil.yang@arm.com> References: <1599809752-25256-1-git-send-email-phil.yang@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v3] mbuf: remove atomic reference counters X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" From: Phil Yang Remove the deprecated refcnt_atomic union fields in rte_mbuf and rte_mbuf_ext_shared_info structures. Signed-off-by: Phil Yang Reviewed-by: Ruifeng wang Signed-off-by: Thomas Monjalon --- v2: - squashed - removed deprecation notice - updated release notes (in API section) v3: - re-sent with --in-reply-to - added Andrew's ack --- doc/guides/rel_notes/deprecation.rst | 8 +------- doc/guides/rel_notes/release_20_11.rst | 4 ++++ lib/librte_mbuf/rte_mbuf_core.h | 13 ++----------- 3 files changed, 7 insertions(+), 18 deletions(-) diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index 88d7d07613..52168f7751 100644 --- a/doc/guides/rel_notes/deprecation.rst +++ b/doc/guides/rel_notes/deprecation.rst @@ -148,13 +148,7 @@ Deprecation Notices avoiding impact on vectorized implementation of the driver datapaths, while evaluating performance gains of a better use of the first cache line. - The deprecated unioned fields ``buf_physaddr`` and ``refcnt_atomic`` - (as explained below) will be removed in DPDK 20.11. - -* mbuf: ``refcnt_atomic`` member in structures ``rte_mbuf`` and - ``rte_mbuf_ext_shared_info`` is of type ``rte_atomic16_t``. - Due to adoption of C11 atomic builtins, the field ``refcnt_atomic`` - will be replaced with ``refcnt`` of type ``uint16_t`` in DPDK 20.11. + The deprecated unioned field ``buf_physaddr`` will be removed in DPDK 20.11. * ethdev: Split the ``struct eth_dev_ops`` struct to hide it as much as possible will be done in 20.11. diff --git a/doc/guides/rel_notes/release_20_11.rst b/doc/guides/rel_notes/release_20_11.rst index 667e3d54ad..b729bdf200 100644 --- a/doc/guides/rel_notes/release_20_11.rst +++ b/doc/guides/rel_notes/release_20_11.rst @@ -84,6 +84,10 @@ API Changes Also, make sure to start the actual text at the margin. ======================================================= +* mbuf: Removed the unioned field ``refcnt_atomic`` from + the structures ``rte_mbuf`` and ``rte_mbuf_ext_shared_info``. + The field ``refcnt`` is remaining from the old unions. + * rawdev: Added a structure size parameter to the functions ``rte_rawdev_queue_setup()``, ``rte_rawdev_queue_conf_get()``, ``rte_rawdev_info_get()`` and ``rte_rawdev_configure()``, diff --git a/lib/librte_mbuf/rte_mbuf_core.h b/lib/librte_mbuf/rte_mbuf_core.h index 8cd7137ac5..cee3d5aff5 100644 --- a/lib/librte_mbuf/rte_mbuf_core.h +++ b/lib/librte_mbuf/rte_mbuf_core.h @@ -495,12 +495,7 @@ struct rte_mbuf { * or non-atomic) is controlled by the CONFIG_RTE_MBUF_REFCNT_ATOMIC * config option. */ - RTE_STD_C11 - union { - rte_atomic16_t refcnt_atomic; /**< Atomically accessed refcnt */ - /** Non-atomically accessed refcnt */ - uint16_t refcnt; - }; + uint16_t refcnt; uint16_t nb_segs; /**< Number of segments. */ /** Input port (16 bits to support more than 256 virtual ports). @@ -679,11 +674,7 @@ typedef void (*rte_mbuf_extbuf_free_callback_t)(void *addr, void *opaque); struct rte_mbuf_ext_shared_info { rte_mbuf_extbuf_free_callback_t free_cb; /**< Free callback function */ void *fcb_opaque; /**< Free callback argument */ - RTE_STD_C11 - union { - rte_atomic16_t refcnt_atomic; /**< Atomically accessed refcnt */ - uint16_t refcnt; - }; + uint16_t refcnt; }; /**< Maximum number of nb_segs allowed. */ -- 2.28.0