On Fri, Jul 02, 2021 at 06:41:29PM +0900, Ohhoon Kwon wrote: > 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 > find_memory_block(). > > PATCH 1 & 2 changes both functions to use section_nr instead of > mem_section. > 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(-) > > -- > 2.17.1 For the series: Acked-by: Mike Rapoport <rppt@xxxxxxxxxxxxx> -- Sincerely yours, Mike.