diff options
author | Michael Ellerman <mpe@ellerman.id.au> | 2023-11-30 14:44:32 +0300 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2023-12-01 13:15:33 +0300 |
commit | d8c3f243d4db24675b653f0568bb65dae34e6455 (patch) | |
tree | d38b9072e0344d7e6b779701884aaf8ff32fad3d /arch/powerpc/include/asm/mmzone.h | |
parent | ede66cd22441820cbd399936bf84fdc4294bc7fa (diff) | |
download | linux-d8c3f243d4db24675b653f0568bb65dae34e6455.tar.xz |
powerpc/mm: Fix build failures due to arch_reserved_kernel_pages()
With NUMA=n and FA_DUMP=y or PRESERVE_FA_DUMP=y the build fails with:
arch/powerpc/kernel/fadump.c:1739:22: error: no previous prototype for ‘arch_reserved_kernel_pages’ [-Werror=missing-prototypes]
1739 | unsigned long __init arch_reserved_kernel_pages(void)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
The prototype for arch_reserved_kernel_pages() is in include/linux/mm.h,
but it's guarded by __HAVE_ARCH_RESERVED_KERNEL_PAGES. The powerpc
headers define __HAVE_ARCH_RESERVED_KERNEL_PAGES in asm/mmzone.h, which
is not included into the generic headers when NUMA=n.
Move the definition of __HAVE_ARCH_RESERVED_KERNEL_PAGES into asm/mmu.h
which is included regardless of NUMA=n.
Additionally the ifdef around __HAVE_ARCH_RESERVED_KERNEL_PAGES needs to
also check for CONFIG_PRESERVE_FA_DUMP.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20231130114433.3053544-1-mpe@ellerman.id.au
Diffstat (limited to 'arch/powerpc/include/asm/mmzone.h')
-rw-r--r-- | arch/powerpc/include/asm/mmzone.h | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/arch/powerpc/include/asm/mmzone.h b/arch/powerpc/include/asm/mmzone.h index 4740ca230d36..da827d2d0866 100644 --- a/arch/powerpc/include/asm/mmzone.h +++ b/arch/powerpc/include/asm/mmzone.h @@ -42,9 +42,6 @@ u64 memory_hotplug_max(void); #else #define memory_hotplug_max() memblock_end_of_DRAM() #endif /* CONFIG_NUMA */ -#ifdef CONFIG_FA_DUMP -#define __HAVE_ARCH_RESERVED_KERNEL_PAGES -#endif #endif /* __KERNEL__ */ #endif /* _ASM_MMZONE_H_ */ |