[lkml]   [2021]   [Jul]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Subject[PATCH 0/3] mm: sparse: remove __section_nr() function
This series contains cleanups to remove __section_nr().

When CONFIG_SPARSEMEM_EXTREME is enabled, __section_nr() could be
costly since it iterates all section roots to check if the given
mem_section is in its range.

On the other hand, __nr_to_section which converts section_nr to
mem_section can be done in O(1).

The only users of __section_nr() was section_mark_present() and

PATCH 1 & 2 changes both functions to use section_nr instead of
PATCH 3 finally removes __section_nr() function.

More details can be found in each changelogs.

Ohhoon Kwon (3):
mm: sparse: pass section_nr to section_mark_present
mm: sparse: pass section_nr to find_memory_block
mm: sparse: remove __section_nr() function

.../platforms/pseries/hotplug-memory.c | 4 +--
drivers/base/memory.c | 4 +--
include/linux/memory.h | 2 +-
include/linux/mmzone.h | 1 -
mm/sparse.c | 35 +++----------------
5 files changed, 9 insertions(+), 37 deletions(-)


 \ /
  Last update: 2021-07-02 11:45    [W:0.191 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site