mbox series

[v2,0/2] Minor memoryhotplug refactoring

Message ID 20220621041717.6355-1-osalvador@suse.de (mailing list archive)
Headers show
Series Minor memoryhotplug refactoring | expand

Message

Oscar Salvador June 21, 2022, 4:17 a.m. UTC
Hi,

these are a few cleanups.

The first one is to spare us with some operations when dealing with empty nodes,
and the second one is to refactor memory-hotplug code taking advantatge of the
fact that we initialize all nodes (empty or not) when booting the system.
That gives us the chance to only have to reset some fields when the node
goes offline again.

More information can be found in the respective patches.

v1 -> v2:
          - Addressed feedback from David

Oscar Salvador (2):
  mm/page_alloc: Do not calculate node's total pages and memmap pages
    when empty
  mm/memory_hotplug: Reset node's state when empty during offline

 include/linux/memory_hotplug.h |  2 +-
 mm/memory_hotplug.c            | 54 ++++++++++++++++------------
 mm/page_alloc.c                | 65 +++++++++++-----------------------
 3 files changed, 53 insertions(+), 68 deletions(-)