]> www.infradead.org Git - users/jedix/linux-maple.git/commit
kaslr: rename physmem_end and PHYSMEM_END to direct_map_physmem_end
authorJohn Hubbard <jhubbard@nvidia.com>
Wed, 9 Oct 2024 02:50:24 +0000 (19:50 -0700)
committerAndrew Morton <akpm@linux-foundation.org>
Fri, 1 Nov 2024 04:29:04 +0000 (21:29 -0700)
commit40ee360e292dc412e9e548a9a004061f4c77c135
treeb2d6b343a9e9f471ab1c8a23bf301d3cb325619d
parent4d806f128d5041e6ca571f7a98f33a35b6f39288
kaslr: rename physmem_end and PHYSMEM_END to direct_map_physmem_end

For clarity.  It's increasingly hard to reason about the code, when KASLR
is moving around the boundaries.  In this case where KASLR is randomizing
the location of the kernel image within physical memory, the maximum
number of address bits for physical memory has not changed.

What has changed is the ending address of memory that is allowed to be
directly mapped by the kernel.

Let's name the variable, and the associated macro accordingly.

Also, enhance the comment above the direct_map_physmem_end definition,
to further clarify how this all works.

Link: https://lkml.kernel.org/r/20241009025024.89813-1-jhubbard@nvidia.com
Signed-off-by: John Hubbard <jhubbard@nvidia.com>
Reviewed-by: Pankaj Gupta <pankaj.gupta@amd.com>
Acked-by: David Hildenbrand <david@redhat.com>
Acked-by: Will Deacon <will@kernel.org>
Reviewed-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Alistair Popple <apopple@nvidia.com>
Cc: Jordan Niethe <jniethe@nvidia.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/arm64/include/asm/memory.h
arch/x86/include/asm/page_64.h
arch/x86/include/asm/pgtable_64_types.h
arch/x86/mm/init_64.c
arch/x86/mm/kaslr.c
include/linux/mm.h
kernel/resource.c
mm/memory_hotplug.c
mm/sparse.c