[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <bea04294-3302-42f1-ade1-e4ec6aa80b99@linux.alibaba.com>
Date: Tue, 22 Jul 2025 13:59:42 +0800
From: Baolin Wang <baolin.wang@...ux.alibaba.com>
To: Lorenzo Stoakes <lorenzo.stoakes@...cle.com>,
Andrew Morton <akpm@...ux-foundation.org>
Cc: David Hildenbrand <david@...hat.com>, Zi Yan <ziy@...dia.com>,
"Liam R . Howlett" <Liam.Howlett@...cle.com>, Nico Pache
<npache@...hat.com>, Ryan Roberts <ryan.roberts@....com>,
Dev Jain <dev.jain@....com>, Barry Song <baohua@...nel.org>,
Jonathan Corbet <corbet@....net>, linux-mm@...ck.org,
linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] docs: update THP documentation to clarify sysfs "never"
setting
On 2025/7/22 13:34, Lorenzo Stoakes wrote:
> Hi Andrew,
>
> Could you apply this fix-patch? It adds the caveat regarding MADV_COLLAPSE in a
> couple other places whwere the sysfs 'never' mode is mentioned.
>
> Thanks, Lorenzo
>
> ----8<----
> From 7c0bdda6a633bc38e7d5a3b0acf2cef7bdc961af Mon Sep 17 00:00:00 2001
> From: Lorenzo Stoakes <lorenzo.stoakes@...cle.com>
> Date: Tue, 22 Jul 2025 06:32:18 +0100
> Subject: [PATCH] docs: update admin guide transhuge page to mention
> MADV_COLLAPSE everywhere
>
> We previously missed a couple places where the 'never' mode was described,
> put the caveat regarding MADV_COLLAPSE in these locations also.
>
> Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@...cle.com>
Thanks.
Reviewed-by: Baolin Wang <baolin.wang@...ux.alibaba.com>
> ---
> Documentation/admin-guide/mm/transhuge.rst | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/admin-guide/mm/transhuge.rst b/Documentation/admin-guide/mm/transhuge.rst
> index 182519197ef7..370fba113460 100644
> --- a/Documentation/admin-guide/mm/transhuge.rst
> +++ b/Documentation/admin-guide/mm/transhuge.rst
> @@ -385,7 +385,9 @@ always
> Attempt to allocate huge pages every time we need a new page;
>
> never
> - Do not allocate huge pages;
> + Do not allocate huge pages. Note that ``madvise(..., MADV_COLLAPSE)``
> + can still cause transparent huge pages to be obtained even if this mode
> + is specified everywhere;
>
> within_size
> Only allocate huge page if it will be fully within i_size.
> @@ -441,7 +443,9 @@ inherit
> have enabled="inherit" and all other hugepage sizes have enabled="never";
>
> never
> - Do not allocate <size> huge pages;
> + Do not allocate <size> huge pages. Note that ``madvise(...,
> + MADV_COLLAPSE)`` can still cause transparent huge pages to be obtained
> + even if this mode is specified everywhere;
>
> within_size
> Only allocate <size> huge page if it will be fully within i_size.
> --
> 2.50.1
Powered by blists - more mailing lists