From: Zi Yan <ziy@nvidia.com>
To: Baolin Wang <baolin.wang@linux.alibaba.com>
Cc: akpm@linux-foundation.org, willy@infradead.org, david@redhat.com,
hannes@cmpxchg.org, lorenzo.stoakes@oracle.com,
Liam.Howlett@oracle.com, npache@redhat.com, ryan.roberts@arm.com,
dev.jain@arm.com, vbabka@suse.cz, rppt@kernel.org,
surenb@google.com, mhocko@suse.com, linux-mm@kvack.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 2/2] mm: convert do_set_pmd() to take a folio
Date: Fri, 09 May 2025 11:01:24 -0400 [thread overview]
Message-ID: <BED8382C-D28E-4A23-BB60-D26A36DC531B@nvidia.com> (raw)
In-Reply-To: <87097d3d5ef1d46959d09cfc7e192c4551b87771.1746795452.git.baolin.wang@linux.alibaba.com>
On 9 May 2025, at 9:01, Baolin Wang wrote:
> In do_set_pmd(), we always use the folio->page to build PMD mappings for
> the entire folio. Since all callers of do_set_pmd() already hold a stable
> folio, converting do_set_pmd() to take a folio is safe and more straightforward.
>
> In addition, to ensure the extensibility of do_set_pmd() for supporting
> larger folios beyond PMD size, we keep the 'page' parameter to specify
> which page within the folio should be mapped.
>
> No functional changes expected.
>
> Signed-off-by: Baolin Wang <baolin.wang@linux.alibaba.com>
> ---
> Changes from v1:
> - Keep the 'page' parameter of the do_set_pmd().
>
> Note: I did mm selftests and built kernel on tmpfs/xfs filesystems, and
> did not find any regression.
> ---
> include/linux/mm.h | 2 +-
> mm/filemap.c | 2 +-
> mm/khugepaged.c | 2 +-
> mm/memory.c | 11 +++++------
> 4 files changed, 8 insertions(+), 9 deletions(-)
>
LGTM. Reviewed-by: Zi Yan <ziy@nvidia.com>
--
Best Regards,
Yan, Zi
next prev parent reply other threads:[~2025-05-09 15:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-09 13:01 [PATCH v2 1/2] mm: khugepaged: convert set_huge_pmd() " Baolin Wang
2025-05-09 13:01 ` [PATCH v2 2/2] mm: convert do_set_pmd() " Baolin Wang
2025-05-09 15:01 ` Zi Yan [this message]
2025-05-09 14:58 ` [PATCH v2 1/2] mm: khugepaged: convert set_huge_pmd() " David Hildenbrand
2025-05-12 2:17 ` Baolin Wang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=BED8382C-D28E-4A23-BB60-D26A36DC531B@nvidia.com \
--to=ziy@nvidia.com \
--cc=Liam.Howlett@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=baolin.wang@linux.alibaba.com \
--cc=david@redhat.com \
--cc=dev.jain@arm.com \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lorenzo.stoakes@oracle.com \
--cc=mhocko@suse.com \
--cc=npache@redhat.com \
--cc=rppt@kernel.org \
--cc=ryan.roberts@arm.com \
--cc=surenb@google.com \
--cc=vbabka@suse.cz \
--cc=willy@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox