linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [Patch v3 0/2] mm/pageblock: improve readability of some pageblock handling
@ 2025-08-27  7:01 Wei Yang
  2025-08-27  7:01 ` [Patch v3 1/2] mm/page_alloc: use xxx_pageblock_isolate() for better reading Wei Yang
  2025-08-27  7:01 ` [Patch v3 2/2] mm/pageblock-flags: remove PB_migratetype_bits/PB_migrate_end Wei Yang
  0 siblings, 2 replies; 4+ messages in thread
From: Wei Yang @ 2025-08-27  7:01 UTC (permalink / raw)
  To: akpm, david, lorenzo.stoakes, vbabka; +Cc: linux-mm, Wei Yang

During code reading, found two possible points to improve the readability of
pageblock handling.

Patch 1: isolate bit is standalone and there are dedicated helpers. Instead of
check the bit directly, we could use the helper to do it.

Patch 2: remove PB_migratetype_bits and PB_migrate_end to reduce magical
computation.

v2->v3:
    fix the definition of MIGRATETYPE_MASK, thanks ziy

v1->v2:
    remove PB_migratetype_bits and PB_migrate_end

Wei Yang (2):
  mm/page_alloc: use xxx_pageblock_isolate() for better reading
  mm/pageblock-flags: remove PB_migratetype_bits/PB_migrate_end

 include/linux/pageblock-flags.h | 12 +++++-------
 mm/page_alloc.c                 | 11 +++++------
 2 files changed, 10 insertions(+), 13 deletions(-)

-- 
2.34.1



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2025-08-27 11:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-27  7:01 [Patch v3 0/2] mm/pageblock: improve readability of some pageblock handling Wei Yang
2025-08-27  7:01 ` [Patch v3 1/2] mm/page_alloc: use xxx_pageblock_isolate() for better reading Wei Yang
2025-08-27  7:01 ` [Patch v3 2/2] mm/pageblock-flags: remove PB_migratetype_bits/PB_migrate_end Wei Yang
2025-08-27 11:30   ` David Hildenbrand

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).