Re: [PATCH 5.10] arm: remove CONFIG_ARCH_HAS_HOLES_MEMORYMODEL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, May 10, 2022 at 08:15:23PM +0300, Mike Rapoport wrote:
> From: Mike Rapoport <rppt@xxxxxxxxxxxxx>
> 
> commit 5e545df3292fbd3d5963c68980f1527ead2a2b3f upstream.
> 
> ARM is the only architecture that defines CONFIG_ARCH_HAS_HOLES_MEMORYMODEL
> which in turn enables memmap_valid_within() function that is intended to
> verify existence  of struct page associated with a pfn when there are holes
> in the memory map.
> 
> However, the ARCH_HAS_HOLES_MEMORYMODEL also enables HAVE_ARCH_PFN_VALID
> and arch-specific pfn_valid() implementation that also deals with the holes
> in the memory map.
> 
> The only two users of memmap_valid_within() call this function after
> a call to pfn_valid() so the memmap_valid_within() check becomes redundant.
> 
> Remove CONFIG_ARCH_HAS_HOLES_MEMORYMODEL and memmap_valid_within() and rely
> entirely on ARM's implementation of pfn_valid() that is now enabled
> unconditionally.
> 
> Link: https://lkml.kernel.org/r/20201101170454.9567-9-rppt@xxxxxxxxxx
> Signed-off-by: Mike Rapoport <rppt@xxxxxxxxxxxxx>
> Cc: Alexey Dobriyan <adobriyan@xxxxxxxxx>
> Cc: Catalin Marinas <catalin.marinas@xxxxxxx>
> Cc: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
> Cc: Greg Ungerer <gerg@xxxxxxxxxxxxxx>
> Cc: John Paul Adrian Glaubitz <glaubitz@xxxxxxxxxxxxxxxxxxx>
> Cc: Jonathan Corbet <corbet@xxxxxxx>
> Cc: Matt Turner <mattst88@xxxxxxxxx>
> Cc: Meelis Roos <mroos@xxxxxxxx>
> Cc: Michael Schmitz <schmitzmic@xxxxxxxxx>
> Cc: Russell King <linux@xxxxxxxxxxxxxxx>
> Cc: Tony Luck <tony.luck@xxxxxxxxx>
> Cc: Vineet Gupta <vgupta@xxxxxxxxxxxx>
> Cc: Will Deacon <will@xxxxxxxxxx>
> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
> Signed-off-by: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Fixes: 8dd559d53b3b ("arm: ioremap: don't abuse pfn_valid() to check if pfn is in RAM")
> Signed-off-by: Mike Rapoport <rppt@xxxxxxxxxxxxx>
> ---
>  Documentation/vm/memory-model.rst |  3 +--
>  arch/arm/Kconfig                  |  8 ++------
>  arch/arm/mach-bcm/Kconfig         |  1 -
>  arch/arm/mach-davinci/Kconfig     |  1 -
>  arch/arm/mach-exynos/Kconfig      |  1 -
>  arch/arm/mach-highbank/Kconfig    |  1 -
>  arch/arm/mach-omap2/Kconfig       |  1 -
>  arch/arm/mach-s5pv210/Kconfig     |  1 -
>  arch/arm/mach-tango/Kconfig       |  1 -
>  fs/proc/kcore.c                   |  2 --
>  include/linux/mmzone.h            | 31 -------------------------------
>  mm/mmzone.c                       | 14 --------------
>  mm/vmstat.c                       |  4 ----
>  13 files changed, 3 insertions(+), 66 deletions(-)

Both now queued up, thanks.

greg k-h



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux