]> Git Repo - linux.git/commit
mm: remove pfn_valid_within() and CONFIG_HOLES_IN_ZONE
authorMike Rapoport <[email protected]>
Wed, 8 Sep 2021 02:54:52 +0000 (19:54 -0700)
committerLinus Torvalds <[email protected]>
Wed, 8 Sep 2021 18:50:22 +0000 (11:50 -0700)
commit859a85ddf90e714092dea71a0e54c7b9896621be
treef5f795c1211064f086a4d4e51052109df740303c
parentac3332c44767b17b761b703523ac4ae9b2bcd227
mm: remove pfn_valid_within() and CONFIG_HOLES_IN_ZONE

Patch series "mm: remove pfn_valid_within() and CONFIG_HOLES_IN_ZONE".

After recent updates to freeing unused parts of the memory map, no
architecture can have holes in the memory map within a pageblock.  This
makes pfn_valid_within() check and CONFIG_HOLES_IN_ZONE configuration
option redundant.

The first patch removes them both in a mechanical way and the second patch
simplifies memory_hotplug::test_pages_in_a_zone() that had
pfn_valid_within() surrounded by more logic than simple if.

This patch (of 2):

After recent changes in freeing of the unused parts of the memory map and
rework of pfn_valid() in arm and arm64 there are no architectures that can
have holes in the memory map within a pageblock and so nothing can enable
CONFIG_HOLES_IN_ZONE which guards non trivial implementation of
pfn_valid_within().

With that, pfn_valid_within() is always hardwired to 1 and can be
completely removed.

Remove calls to pfn_valid_within() and CONFIG_HOLES_IN_ZONE.

Link: https://lkml.kernel.org/r/[email protected]
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Mike Rapoport <[email protected]>
Acked-by: David Hildenbrand <[email protected]>
Cc: Greg Kroah-Hartman <[email protected]>
Cc: "Rafael J. Wysocki" <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
drivers/base/node.c
include/linux/mmzone.h
mm/Kconfig
mm/compaction.c
mm/memory_hotplug.c
mm/page_alloc.c
mm/page_isolation.c
mm/page_owner.c
This page took 0.051957 seconds and 4 git commands to generate.