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 D3BB8A0C43; Mon, 18 Oct 2021 16:49:49 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E69FB41145; Mon, 18 Oct 2021 16:49:40 +0200 (CEST) Received: from shelob.oktetlabs.ru (shelob.oktetlabs.ru [91.220.146.113]) by mails.dpdk.org (Postfix) with ESMTP id 3AF5C410DA for ; Mon, 18 Oct 2021 16:49:40 +0200 (CEST) Received: by shelob.oktetlabs.ru (Postfix, from userid 122) id 0997C7F6FD; Mon, 18 Oct 2021 17:49:40 +0300 (MSK) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shelob.oktetlabs.ru X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=ALL_TRUSTED, DKIM_ADSP_DISCARD, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.2 Received: from aros.oktetlabs.ru (aros.oktetlabs.ru [192.168.38.17]) by shelob.oktetlabs.ru (Postfix) with ESMTP id 6D0EC7F6FB; Mon, 18 Oct 2021 17:49:12 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 shelob.oktetlabs.ru 6D0EC7F6FB Authentication-Results: shelob.oktetlabs.ru/6D0EC7F6FB; dkim=none; dkim-atps=neutral From: Andrew Rybchenko To: Olivier Matz , David Marchand , Ray Kinsella Cc: dev@dpdk.org Date: Mon, 18 Oct 2021 17:49:07 +0300 Message-Id: <20211018144907.1145028-7-andrew.rybchenko@oktetlabs.ru> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211018144907.1145028-1-andrew.rybchenko@oktetlabs.ru> References: <20211018144907.1145028-1-andrew.rybchenko@oktetlabs.ru> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 6/6] mempool: deprecate unused defines 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 Sender: "dev" MEMPOOL_PG_NUM_DEFAULT and MEMPOOL_PG_SHIFT_MAX are not used. Signed-off-by: Andrew Rybchenko --- doc/guides/contributing/documentation.rst | 4 ++-- doc/guides/rel_notes/deprecation.rst | 3 +++ doc/guides/rel_notes/release_21_11.rst | 3 +++ lib/mempool/rte_mempool.h | 7 ++++--- 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/doc/guides/contributing/documentation.rst b/doc/guides/contributing/documentation.rst index 8cbd4a0f6f..7fcbb7fc43 100644 --- a/doc/guides/contributing/documentation.rst +++ b/doc/guides/contributing/documentation.rst @@ -705,7 +705,7 @@ The following are some guidelines for use of Doxygen in the DPDK API documentati /**< Virtual address of the first mempool object. */ uintptr_t elt_va_end; /**< Virtual address of the mempool object. */ - phys_addr_t elt_pa[MEMPOOL_PG_NUM_DEFAULT]; + phys_addr_t elt_pa[1]; /**< Array of physical page addresses for the mempool buffer. */ This doesn't have an effect on the rendered documentation but it is confusing for the developer reading the code. @@ -724,7 +724,7 @@ The following are some guidelines for use of Doxygen in the DPDK API documentati /** Virtual address of the mempool object. */ uintptr_t elt_va_end; /** Array of physical page addresses for the mempool buffer. */ - phys_addr_t elt_pa[MEMPOOL_PG_NUM_DEFAULT]; + phys_addr_t elt_pa[1]; * Read the rendered section of the documentation that you have added for correctness, clarity and consistency with the surrounding text. diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index f75b23ef03..c2bd0cd736 100644 --- a/doc/guides/rel_notes/deprecation.rst +++ b/doc/guides/rel_notes/deprecation.rst @@ -51,6 +51,9 @@ Deprecation Notices deprecated and will be removed in DPDK 22.11. Use replacement macro ``RTE_MEMPOOL_REGISTER_OPS()``. +* mempool: The mempool API macros ``MEMPOOL_PG_*`` are deprecated and + will be removed in DPDK 22.11. + * mbuf: The mbuf offload flags ``PKT_*`` will be renamed as ``RTE_MBUF_F_*``. A compatibility layer will be kept until DPDK 22.11, except for the flags that are already deprecated (``PKT_RX_L4_CKSUM_BAD``, ``PKT_RX_IP_CKSUM_BAD``, diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst index a679bb90e3..c302d9e664 100644 --- a/doc/guides/rel_notes/release_21_11.rst +++ b/doc/guides/rel_notes/release_21_11.rst @@ -273,6 +273,9 @@ API Changes * mempool: Macro to register mempool driver ``MEMPOOL_REGISTER_OPS()`` is deprecated. Use replacement ``RTE_MEMPOOL_REGISTER_OPS()``. +* mempool: The mempool API macros ``MEMPOOL_PG_*`` are deprecated and + will be removed in DPDK 22.11. + * net: Renamed ``s_addr`` and ``d_addr`` fields of ``rte_ether_hdr`` structure to ``src_addr`` and ``dst_addr``, respectively. diff --git a/lib/mempool/rte_mempool.h b/lib/mempool/rte_mempool.h index eea91b20fb..4bb7349322 100644 --- a/lib/mempool/rte_mempool.h +++ b/lib/mempool/rte_mempool.h @@ -116,10 +116,11 @@ struct rte_mempool_objsz { /* "MP_" */ #define RTE_MEMPOOL_MZ_FORMAT RTE_MEMPOOL_MZ_PREFIX "%s" -#define MEMPOOL_PG_SHIFT_MAX (sizeof(uintptr_t) * CHAR_BIT - 1) +#define MEMPOOL_PG_SHIFT_MAX \ + RTE_DEPRECATED(sizeof(uintptr_t) * CHAR_BIT - 1) -/** Mempool over one chunk of physically continuous memory */ -#define MEMPOOL_PG_NUM_DEFAULT 1 +/** Deprecated. Mempool over one chunk of physically continuous memory */ +#define MEMPOOL_PG_NUM_DEFAULT RTE_DEPRECATED(1) #ifndef RTE_MEMPOOL_ALIGN /** -- 2.30.2