From 200036a8e802dee09103031eeeaea91dd212ec99 Mon Sep 17 00:00:00 2001 From: Helge Deller Date: Tue, 14 May 2019 21:40:53 +0200 Subject: parisc: Allow building 64-bit kernel without -mlong-calls compiler option A 64-bit kernel built without CONFIG_MLONGCALLS (-mlong-calls compiler option) usually fails to link because of unreachable functions. Try to work around that linking issue by moving the *.init and *.exit text segments closer to the main text segment. With that change those segments now don't get freed at runtime any longer, but since we in most cases run with huge-page enabled, we ignore the lost memory in preference of better performance. This change will not guarantee that every kernel config will now sucessfully build with short calls and without linking issues. Signed-off-by: Helge Deller --- arch/parisc/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'arch/parisc/Kconfig') diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig index 13b9512527c7..4860efa91d7b 100644 --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig @@ -194,7 +194,8 @@ config PREFETCH config MLONGCALLS bool "Enable the -mlong-calls compiler option for big kernels" - default y + default y if !MODULES || UBSAN || FTRACE + default n depends on PA8X00 help If you configure the kernel to include many drivers built-in instead -- cgit v1.2.3