summaryrefslogtreecommitdiff
path: root/arch/x86/boot/compressed/Makefile
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2022-11-22 19:10:16 +0300
committerBorislav Petkov <bp@suse.de>2022-11-24 10:57:41 +0300
commit61de13df95901bc58456bc5acdbd3c18c66cf859 (patch)
tree01af1293f208236bd1d16b177fe1256b33ccb83c /arch/x86/boot/compressed/Makefile
parent30c9ca16a5271ba6f8ad9c86507ff1c789c94677 (diff)
downloadlinux-61de13df95901bc58456bc5acdbd3c18c66cf859.tar.xz
x86/boot/compressed: Only build mem_encrypt.S if AMD_MEM_ENCRYPT=y
Avoid building the mem_encrypt.o object if memory encryption support is not enabled to begin with. Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Borislav Petkov <bp@suse.de> Link: https://lore.kernel.org/r/20221122161017.2426828-17-ardb@kernel.org
Diffstat (limited to 'arch/x86/boot/compressed/Makefile')
-rw-r--r--arch/x86/boot/compressed/Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/boot/compressed/Makefile b/arch/x86/boot/compressed/Makefile
index cd1a6295b957..3dc5db651dd0 100644
--- a/arch/x86/boot/compressed/Makefile
+++ b/arch/x86/boot/compressed/Makefile
@@ -100,7 +100,7 @@ vmlinux-objs-$(CONFIG_RANDOMIZE_BASE) += $(obj)/kaslr.o
ifdef CONFIG_X86_64
vmlinux-objs-y += $(obj)/ident_map_64.o
vmlinux-objs-y += $(obj)/idt_64.o $(obj)/idt_handlers_64.o
- vmlinux-objs-y += $(obj)/mem_encrypt.o
+ vmlinux-objs-$(CONFIG_AMD_MEM_ENCRYPT) += $(obj)/mem_encrypt.o
vmlinux-objs-y += $(obj)/pgtable_64.o
vmlinux-objs-$(CONFIG_AMD_MEM_ENCRYPT) += $(obj)/sev.o
endif