On 11.06.24 21:41, Tim Chen wrote:
On Fri, 2024-06-07 at 11:09 +0200, David Hildenbrand wrote:
In preparation for further changes, let's teach __free_pages_core()
about the differences of memory hotplug handling.

Move the memory hotplug specific handling from generic_online_page() to
__free_pages_core(), use adjust_managed_page_count() on the memory
hotplug path, and spell out why memory freed via memblock
cannot currently use adjust_managed_page_count().

Signed-off-by: David Hildenbrand <da...@redhat.com>
---
  mm/internal.h       |  3 ++-
  mm/kmsan/init.c     |  2 +-
  mm/memory_hotplug.c |  9 +--------
  mm/mm_init.c        |  4 ++--
  mm/page_alloc.c     | 17 +++++++++++++++--
  5 files changed, 21 insertions(+), 14 deletions(-)

diff --git a/mm/internal.h b/mm/internal.h
index 12e95fdf61e90..3fdee779205ab 100644
--- a/mm/internal.h
+++ b/mm/internal.h
@@ -604,7 +604,8 @@ extern void __putback_isolated_page(struct page *page, 
unsigned int order,
                                    int mt);
  extern void memblock_free_pages(struct page *page, unsigned long pfn,
                                        unsigned int order);
-extern void __free_pages_core(struct page *page, unsigned int order);
+extern void __free_pages_core(struct page *page, unsigned int order,
+               enum meminit_context);

Shouldn't the above be
                enum meminit_context context);

Although C allows parameters without names in declarations, this was unintended.

Thanks!

--
Cheers,

David / dhildenb


Reply via email to