Thread (138 messages) 138 messages, 5 authors, 2025-07-03

Re: [PATCH v1 23/29] mm/page-alloc: remove PageMappingFlags()

From: David Hildenbrand <hidden>
Date: 2025-07-01 19:34:48
Also in: linux-doc, linux-fsdevel, linux-mm, lkml, virtualization

On 01.07.25 15:02, Lorenzo Stoakes wrote:
On Mon, Jun 30, 2025 at 03:00:04PM +0200, David Hildenbrand wrote:
quoted
We can now simply check for PageAnon() and remove PageMappingFlags().

... and while at it, use the folio instead and operate on
folio->mapping.
Probably worth mentioning to be super crystal clear that this is because
now it's either an anon folio or a KSM folio, both of which set the
FOLIO_MAPPING_ANON flag.
"As PageMappingFlags() now only indicates anon (incl. ksm) folios, we 
can now simply check for PageAnon() and remove PageMappingFlags()."

I wonder if there's other places that could be fixed up similarly that do
folio_test_anon() || folio_test_ksm() or equivalent?
I think you spotted the one in patch #25 :)

I looked for others while crafting this patch, but there might be more 
hiding that I didn't catch.
quoted
Reviewed-by: Zi Yan <ziy@nvidia.com>
Signed-off-by: David Hildenbrand <redacted>
LGTM, so:

Reviewed-by: Lorenzo Stoakes <redacted>
Thanks!

-- 
Cheers,

David / dhildenb

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