linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/12] mm/sparse: remove SECTION_MARKED_PRESENT and further cleanups
@ 2026-09-09 13:32 David Hildenbrand (Arm)
  2026-09-09 13:32 ` [PATCH 01/12] mm/sparse: move mem_section init to sparse_extreme_init() David Hildenbrand (Arm)
                   ` (11 more replies)
  0 siblings, 12 replies; 51+ messages in thread
From: David Hildenbrand (Arm) @ 2026-09-09 13:32 UTC (permalink / raw)
  To: Andrew Morton, Lorenzo Stoakes, Liam R. Howlett, Vlastimil Babka,
	Mike Rapoport, Suren Baghdasaryan, Michal Hocko, Kairui Song,
	Qi Zheng, Shakeel Butt, Barry Song, Axel Rasmussen, Yuanchu Xie,
	Wei Xu, Baoquan He, Baolin Wang, Brendan Jackman, Johannes Weiner,
	Zi Yan, Oscar Salvador, Greg Kroah-Hartman, Rafael J. Wysocki,
	Danilo Krummrich, Jan Kiszka, Kieran Bingham
  Cc: linux-kernel, linux-mm, linux-cxl, driver-core, linux-fsdevel,
	David Hildenbrand (Arm)

SECTION_MARKED_PRESENT is really only needed during boot, where we
can instead just rely on SECTION_IS_EARLY_BIT by setting that flag
earlier.

Some preparations for doing that conversion and some cleanups in the same
(sparse) area.

Tested on x86 with and without memory hotplug through virtio-mem.

This is based on mm-unstable which carries Muchun's

	"[PATCH v5 00/17] mm: Introduce section-based vmemmap optimization
	 for HugeTLB" [1]

A (possible) resend from Muchun should only result in smaller conflicts.

[1] https://lore.kernel.org/r/20260825084608.47437-1-songmuchun@bytedance.com 

Signed-off-by: David Hildenbrand (Arm) <david@kernel.org>
---
David Hildenbrand (Arm) (12):
      mm/sparse: move mem_section init to sparse_extreme_init()
      mm/sparse: refactor sparse_sections_init()
      mm/sparse: move initialization of section metadata to sparse_metadata_init()
      mm/sparse: rename and cleanup sparse_init_nid()
      mm/sparse: cleanup sparse_init_one_section()
      mm/sparse: rename __highest_present_section_nr to __highest_used_section_nr
      mm/sparse: remove pfn_in_present_section()
      mm/sparse: move __highest_used_section_nr handling
      mm/sparse: remove SECTION_MARKED_PRESENT
      mm/sparse: remove flags parameter from sparse_init_one_section()
      fs/proc/page: clarify comment in get_max_dump_pfn()
      mm/memory_hotplug: drop CONFIG_HAVE_ARCH_PFN_VALID handling from pfn_to_online_page()

 drivers/base/memory.c   |   2 +-
 fs/proc/page.c          |   7 +--
 include/linux/cache.h   |   1 +
 include/linux/mmzone.h  |  43 ++++---------
 mm/compaction.c         |   2 +-
 mm/memory_hotplug.c     |   9 +--
 mm/sparse-vmemmap.c     |   3 +-
 mm/sparse.c             | 160 +++++++++++++++++++++++-------------------------
 mm/sparse.h             |  21 +++----
 scripts/gdb/linux/mm.py |   2 +-
 10 files changed, 107 insertions(+), 143 deletions(-)

---

base-commit: b02c77c78ff74d3d88ea614335ae833e01ed5d30

change-id: 20260814-b4-sparsemem_cleanups-8bc4b47014c3

--

Cheers,

David


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

end of thread, other threads:[~2026-09-10 15:15 UTC | newest]

Thread overview: 51+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-09 13:32 [PATCH 00/12] mm/sparse: remove SECTION_MARKED_PRESENT and further cleanups David Hildenbrand (Arm)
2026-09-09 13:32 ` [PATCH 01/12] mm/sparse: move mem_section init to sparse_extreme_init() David Hildenbrand (Arm)
2026-09-09 17:02   ` Oscar Salvador (SUSE)
2026-09-10 12:52   ` Lorenzo Stoakes (ARM)
2026-09-10 13:13     ` David Hildenbrand (Arm)
2026-09-10 13:33       ` Lorenzo Stoakes (ARM)
2026-09-09 13:32 ` [PATCH 02/12] mm/sparse: refactor sparse_sections_init() David Hildenbrand (Arm)
2026-09-09 17:09   ` Oscar Salvador (SUSE)
2026-09-09 17:18     ` David Hildenbrand (Arm)
2026-09-10 13:29   ` Lorenzo Stoakes (ARM)
2026-09-10 14:30     ` David Hildenbrand (Arm)
2026-09-10 14:38       ` Lorenzo Stoakes (ARM)
2026-09-09 13:32 ` [PATCH 03/12] mm/sparse: move initialization of section metadata to sparse_metadata_init() David Hildenbrand (Arm)
2026-09-09 17:22   ` Oscar Salvador (SUSE)
2026-09-10 13:43   ` Lorenzo Stoakes (ARM)
2026-09-09 13:32 ` [PATCH 04/12] mm/sparse: rename and cleanup sparse_init_nid() David Hildenbrand (Arm)
2026-09-10  7:41   ` Oscar Salvador (SUSE)
2026-09-10 13:46   ` Lorenzo Stoakes (ARM)
2026-09-10 14:29     ` David Hildenbrand (Arm)
2026-09-09 13:32 ` [PATCH 05/12] mm/sparse: cleanup sparse_init_one_section() David Hildenbrand (Arm)
2026-09-10  7:45   ` Oscar Salvador (SUSE)
2026-09-10 13:47   ` Lorenzo Stoakes (ARM)
2026-09-09 13:32 ` [PATCH 06/12] mm/sparse: rename __highest_present_section_nr to __highest_used_section_nr David Hildenbrand (Arm)
2026-09-10  7:56   ` Oscar Salvador (SUSE)
2026-09-10 13:49   ` Lorenzo Stoakes (ARM)
2026-09-09 13:33 ` [PATCH 07/12] mm/sparse: remove pfn_in_present_section() David Hildenbrand (Arm)
2026-09-10  7:59   ` Oscar Salvador (SUSE)
2026-09-10 13:50   ` Lorenzo Stoakes (ARM)
2026-09-09 13:33 ` [PATCH 08/12] mm/sparse: move __highest_used_section_nr handling David Hildenbrand (Arm)
2026-09-09 14:44   ` David Hildenbrand (Arm)
2026-09-10  8:33   ` Oscar Salvador (SUSE)
2026-09-10  9:13     ` David Hildenbrand (Arm)
2026-09-10 12:08       ` Oscar Salvador (SUSE)
2026-09-10 13:33         ` David Hildenbrand (Arm)
2026-09-10 14:16   ` Lorenzo Stoakes (ARM)
2026-09-10 14:29     ` David Hildenbrand (Arm)
2026-09-10 14:51       ` Lorenzo Stoakes (ARM)
2026-09-09 13:33 ` [PATCH 09/12] mm/sparse: remove SECTION_MARKED_PRESENT David Hildenbrand (Arm)
2026-09-10 12:15   ` Oscar Salvador (SUSE)
2026-09-10 14:32   ` Lorenzo Stoakes (ARM)
2026-09-10 15:11     ` David Hildenbrand (Arm)
2026-09-09 13:33 ` [PATCH 10/12] mm/sparse: remove flags parameter from sparse_init_one_section() David Hildenbrand (Arm)
2026-09-10 12:34   ` Oscar Salvador (SUSE)
2026-09-10 14:34   ` Lorenzo Stoakes (ARM)
2026-09-09 13:33 ` [PATCH 11/12] fs/proc/page: clarify comment in get_max_dump_pfn() David Hildenbrand (Arm)
2026-09-10 12:46   ` Oscar Salvador (SUSE)
2026-09-10 14:41   ` Lorenzo Stoakes (ARM)
2026-09-10 15:14     ` David Hildenbrand (Arm)
2026-09-09 13:33 ` [PATCH 12/12] mm/memory_hotplug: drop CONFIG_HAVE_ARCH_PFN_VALID handling from pfn_to_online_page() David Hildenbrand (Arm)
2026-09-10 14:47   ` Lorenzo Stoakes (ARM)
2026-09-10 15:15     ` David Hildenbrand (Arm)

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).