aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCatalin Marinas <catalin.marinas@arm.com>2016-07-26 13:16:55 -0400
committerCatalin Marinas <catalin.marinas@arm.com>2016-07-26 19:20:32 -0400
commitb9c220b589daaf140f5b8ebe502c98745b94e65c (patch)
tree3a7ba9514464f78b110cd6b032bd2d6c0962f741
parent1378dc3d4ba07ccd295b04ef59e943162531ad25 (diff)
arm64: Only select ARM64_MODULE_PLTS if MODULES=y
Selecting CONFIG_RANDOMIZE_BASE=y and CONFIG_MODULES=n fails to build the module PLTs support: CC arch/arm64/kernel/module-plts.o /work/Linux/linux-2.6-aarch64/arch/arm64/kernel/module-plts.c: In function ‘module_emit_plt_entry’: /work/Linux/linux-2.6-aarch64/arch/arm64/kernel/module-plts.c:32:49: error: dereferencing pointer to incomplete type ‘struct module’ This patch selects ARM64_MODULE_PLTS conditionally only if MODULES is enabled. Fixes: f80fb3a3d508 ("arm64: add support for kernel ASLR") Cc: <stable@vger.kernel.org> # 4.6+ Reported-by: Jeff Vander Stoep <jeffv@google.com> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
-rw-r--r--arch/arm64/Kconfig2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
index ac4746f454ed..effc9f33ade0 100644
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig
@@ -886,7 +886,7 @@ config RELOCATABLE
886 886
887config RANDOMIZE_BASE 887config RANDOMIZE_BASE
888 bool "Randomize the address of the kernel image" 888 bool "Randomize the address of the kernel image"
889 select ARM64_MODULE_PLTS 889 select ARM64_MODULE_PLTS if MODULES
890 select RELOCATABLE 890 select RELOCATABLE
891 help 891 help
892 Randomizes the virtual address at which the kernel image is 892 Randomizes the virtual address at which the kernel image is