mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
UPSTREAM: arm64: kasan: Use actual memory node when populating the kernel image shadow
With the 16KB or 64KB page configurations, the generic vmemmap_populate() implementation warns on potential offnode page_structs via vmemmap_verify() because the arm64 kasan_init() passes NUMA_NO_NODE instead of the actual node for the kernel image memory. Fixes:f9040773b7("arm64: move kernel image to base of vmalloc area") Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Reported-by: James Morse <james.morse@arm.com> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Bug: 30369029 Patchset: kaslr-arm64-4.4 (cherry picked from commit2f76969f2e) Signed-off-by: Jeff Vander Stoep <jeffv@google.com> Change-Id: I8985e5b4628a9c7076767d4565f7633635813b5c
This commit is contained in:
committed by
Jeff Vander Stoep
parent
391ba6bf3e
commit
1d2e2e3c0f
@@ -152,7 +152,8 @@ void __init kasan_init(void)
|
||||
|
||||
clear_pgds(KASAN_SHADOW_START, KASAN_SHADOW_END);
|
||||
|
||||
vmemmap_populate(kimg_shadow_start, kimg_shadow_end, NUMA_NO_NODE);
|
||||
vmemmap_populate(kimg_shadow_start, kimg_shadow_end,
|
||||
pfn_to_nid(virt_to_pfn(_text)));
|
||||
|
||||
/*
|
||||
* vmemmap_populate() has populated the shadow region that covers the
|
||||
|
||||
Reference in New Issue
Block a user