Thread (10 messages) 10 messages, 3 authors, 2024-02-29

Re: [PATCH 0/5] mm/treewide: Replace pXd_large() with pXd_leaf()

From: Peter Xu <peterx@redhat.com>
Date: 2024-02-28 10:24:13
Also in: lkml

On Wed, Feb 28, 2024 at 09:50:52AM +0000, Christophe Leroy wrote:
Le 28/02/2024 à 09:53, peterx@redhat.com a écrit :
quoted
From: Peter Xu <peterx@redhat.com>

[based on latest akpm/mm-unstable, commit 1274e7646240]

These two APIs are mostly always the same.  It's confusing to have both of
them.  Merge them into one.  Here I used pXd_leaf() only because pXd_leaf()
is a global API which is always defined, while pXd_large() is not.

We have yet one more API that is similar which is pXd_huge(), but that's
even trickier, so let's do it step by step.

Some cautions are needed on either x86 or ppc: x86 is currently the only
user of p4d_large(), while ppc used to define pXd_large() only with THP,
while it is not the case for pXd_leaf().  For the rest archs, afaict
they're 100% identical.
Maybe would also be a good opportunity to replace pmd_is_leaf() by 
pmd_leaf() and the same for pud_is_leaf()
Sure, while I'll wait for some more comments, I can add one on top when
repost.  Thanks,

-- 
Peter Xu
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help