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 3F03045CC9; Sun, 17 Nov 2024 20:11:49 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2B381402B1; Sun, 17 Nov 2024 20:11:49 +0100 (CET) Received: from mail.lysator.liu.se (mail.lysator.liu.se [130.236.254.3]) by mails.dpdk.org (Postfix) with ESMTP id 2A0D840281 for ; Sun, 17 Nov 2024 20:11:48 +0100 (CET) Received: from mail.lysator.liu.se (localhost [127.0.0.1]) by mail.lysator.liu.se (Postfix) with ESMTP id 8BF7124ED for ; Sun, 17 Nov 2024 20:11:47 +0100 (CET) Received: by mail.lysator.liu.se (Postfix, from userid 1004) id 801B62562; Sun, 17 Nov 2024 20:11:47 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on hermod.lysator.liu.se X-Spam-Level: X-Spam-Status: No, score=-1.2 required=5.0 tests=ALL_TRUSTED,AWL, T_SCC_BODY_TEXT_LINE autolearn=disabled version=4.0.0 X-Spam-Score: -1.2 Received: from [192.168.1.85] (h-62-63-215-114.A163.priv.bahnhof.se [62.63.215.114]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mail.lysator.liu.se (Postfix) with ESMTPSA id A433E2614; Sun, 17 Nov 2024 20:11:44 +0100 (CET) Message-ID: <82fc429d-8a0a-4c51-a68d-90eb7e4cc397@lysator.liu.se> Date: Sun, 17 Nov 2024 20:11:43 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] eal: fix lcore variables documentation To: Thomas Monjalon , dev@dpdk.org Cc: =?UTF-8?Q?Mattias_R=C3=B6nnblom?= , Tyler Retzlaff , Chengwen Feng , Konstantin Ananyev , Stephen Hemminger , =?UTF-8?Q?Morten_Br=C3=B8rup?= , David Marchand References: <20241114170947.35359-1-thomas@monjalon.net> Content-Language: en-US From: =?UTF-8?Q?Mattias_R=C3=B6nnblom?= In-Reply-To: <20241114170947.35359-1-thomas@monjalon.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP 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 On 2024-11-14 18:09, Thomas Monjalon wrote: > The lcore variables API is new in DPDK 24.11, > that's why the function rte_lcore_var_alloc() was marked experimental. > To be clearer, the whole header file (including all macros) > is marked experimental. > > A change decreased the default buffer size from 1 MB to 128 kB, > missing to update the documentation, which is fixed here. > > Fixes: 5bce9bed67ad ("eal: add static per-lcore memory allocation facility") > Fixes: f2fd6c2e080c ("config: limit lcore variable maximum size to 128k") > > Signed-off-by: Thomas Monjalon > --- > doc/guides/prog_guide/lcore_var.rst | 2 +- > lib/eal/include/rte_lcore_var.h | 2 ++ > 2 files changed, 3 insertions(+), 1 deletion(-) > > diff --git a/doc/guides/prog_guide/lcore_var.rst b/doc/guides/prog_guide/lcore_var.rst > index b492ad12c6..3d9384bc33 100644 > --- a/doc/guides/prog_guide/lcore_var.rst > +++ b/doc/guides/prog_guide/lcore_var.rst > @@ -240,7 +240,7 @@ and huge pages for lcore variables: > and their use would result in a significant amount of memory going to waste. > An example: ~256 kB worth of lcore variables are allocated > by DPDK libraries, PMDs and the application. > - ``RTE_MAX_LCORE_VAR`` is set to 1 MB and ``RTE_MAX_LCORE`` to 128. > + ``RTE_MAX_LCORE_VAR`` is set to 128 kB and ``RTE_MAX_LCORE`` to 128. > With 4 kB OS pages, only the first ~64 pages of each of the 128 per-lcore id slices > in the (only) ``lcore_var_buffer`` will actually be resident (paged in). > Here, demand paging saves ~98 MB of memory. > diff --git a/lib/eal/include/rte_lcore_var.h b/lib/eal/include/rte_lcore_var.h > index 28d88cd89b..0216a67cab 100644 > --- a/lib/eal/include/rte_lcore_var.h > +++ b/lib/eal/include/rte_lcore_var.h > @@ -15,6 +15,8 @@ > * > * Please refer to the lcore variables' programmer's guide > * for an overview of this API and its implementation. > + * > + * EXPERIMENTAL: this API may change, or be removed, without prior notice. > */ > > #include Acked-by: Mattias Rönnblom Thanks!