mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-11-01 08:58:07 +00:00
50f6c7dbd9
- Fix mitigation state sysfs output - Fix an FPU xstate/sxave code assumption bug triggered by Architectural LBR support - Fix Lightning Mountain SoC TSC frequency enumeration bug - Fix kexec debug output - Fix kexec memory range assumption bug - Fix a boundary condition in the crash kernel code - Optimize porgatory.ro generation a bit - Enable ACRN guests to use X2APIC mode - Reduce a __text_poke() IRQs-off critical section for the benefit of PREEMPT_RT Signed-off-by: Ingo Molnar <mingo@kernel.org> -----BEGIN PGP SIGNATURE----- iQJFBAABCgAvFiEEBpT5eoXrXCwVQwEKEnMQ0APhK1gFAl83ybgRHG1pbmdvQGtl cm5lbC5vcmcACgkQEnMQ0APhK1iJnQ/+OAkE5hiQ+F1ikQ4rKyjaT6FjvynReNUA ysQjcCypGB4x+slR8o3k5yrzYJ9WbDfOz7a0uekZtNHvJ80+3yheV5Yvf+Uz3EYM Jj/OubCNMNnvS5cJMNXs196SGd/ELLWBbCjwUWPsiWJ0ZMTgKmpZz1LgB1QZjhyw fbAc1WgTLVO+emE5FwBrmFzvgBxn5EtiFoLhegFtACHadNcJLiKpXpiK3NKkEirO owF1/Qg6mn6MowKDBDkWgmwi0HVYbraqu0hXRrCq9o105CVwgwUdORTwjK3rnUNs et10Zz2UmSpjXJOhKZdZLFCtYOmrADmS4pnoXF6W6cLLFvkq4b2ducnlFBtNKqMh ljPkIT04sF99gIKijEYWsru+MgS4qO1VNHtJxkr/ZCUjqahsa1nN9F0lP0QOXjwf hbK4h1NrML3UiCGAe2hjIh9zY2c8s2Q90PyCvZkKNKquSQ1E011hzcEE2RIoBBYB mc1d6lgfCFWVkbgRA5sx1CVtgnAvHk2wu9w/8N9XTGjPgiQJRr3I8cNUZw59gaMH 43auWyvpVAA4vdfbKJrPVrTLhTTnQYv0A966l7/i0d8MkGN4u09sAiB3ZevZMEK9 45b7IXWluCi0ikBAmCvQ+qEzhg7pApCziVKuaZ/4j+qPLTDAutGwz7YuaXyOKrUX Aj/uCev6D6c= =fvpv -----END PGP SIGNATURE----- Merge tag 'x86-urgent-2020-08-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Ingo Molnar: "Misc fixes and small updates all around the place: - Fix mitigation state sysfs output - Fix an FPU xstate/sxave code assumption bug triggered by Architectural LBR support - Fix Lightning Mountain SoC TSC frequency enumeration bug - Fix kexec debug output - Fix kexec memory range assumption bug - Fix a boundary condition in the crash kernel code - Optimize porgatory.ro generation a bit - Enable ACRN guests to use X2APIC mode - Reduce a __text_poke() IRQs-off critical section for the benefit of PREEMPT_RT" * tag 'x86-urgent-2020-08-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/alternatives: Acquire pte lock with interrupts enabled x86/bugs/multihit: Fix mitigation reporting when VMX is not in use x86/fpu/xstate: Fix an xstate size check warning with architectural LBRs x86/purgatory: Don't generate debug info for purgatory.ro x86/tsr: Fix tsc frequency enumeration bug on Lightning Mountain SoC kexec_file: Correctly output debugging information for the PT_LOAD ELF header kexec: Improve & fix crash_exclude_mem_range() to handle overlapping ranges x86/crash: Correct the address boundary of function parameters x86/acrn: Remove redundant chars from ACRN signature x86/acrn: Allow ACRN guest to use X2APIC mode
84 lines
2.6 KiB
Makefile
84 lines
2.6 KiB
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
OBJECT_FILES_NON_STANDARD := y
|
|
|
|
purgatory-y := purgatory.o stack.o setup-x86_$(BITS).o sha256.o entry64.o string.o
|
|
|
|
targets += $(purgatory-y)
|
|
PURGATORY_OBJS = $(addprefix $(obj)/,$(purgatory-y))
|
|
|
|
$(obj)/string.o: $(srctree)/arch/x86/boot/compressed/string.c FORCE
|
|
$(call if_changed_rule,cc_o_c)
|
|
|
|
$(obj)/sha256.o: $(srctree)/lib/crypto/sha256.c FORCE
|
|
$(call if_changed_rule,cc_o_c)
|
|
|
|
CFLAGS_sha256.o := -D__DISABLE_EXPORTS
|
|
|
|
# When linking purgatory.ro with -r unresolved symbols are not checked,
|
|
# also link a purgatory.chk binary without -r to check for unresolved symbols.
|
|
PURGATORY_LDFLAGS := -e purgatory_start -nostdlib -z nodefaultlib
|
|
LDFLAGS_purgatory.ro := -r $(PURGATORY_LDFLAGS)
|
|
LDFLAGS_purgatory.chk := $(PURGATORY_LDFLAGS)
|
|
targets += purgatory.ro purgatory.chk
|
|
|
|
# Sanitizer, etc. runtimes are unavailable and cannot be linked here.
|
|
GCOV_PROFILE := n
|
|
KASAN_SANITIZE := n
|
|
UBSAN_SANITIZE := n
|
|
KCSAN_SANITIZE := n
|
|
KCOV_INSTRUMENT := n
|
|
|
|
# These are adjustments to the compiler flags used for objects that
|
|
# make up the standalone purgatory.ro
|
|
|
|
PURGATORY_CFLAGS_REMOVE := -mcmodel=kernel
|
|
PURGATORY_CFLAGS := -mcmodel=large -ffreestanding -fno-zero-initialized-in-bss -g0
|
|
PURGATORY_CFLAGS += $(DISABLE_STACKLEAK_PLUGIN) -DDISABLE_BRANCH_PROFILING
|
|
PURGATORY_CFLAGS += -fno-stack-protector
|
|
|
|
# Default KBUILD_CFLAGS can have -pg option set when FTRACE is enabled. That
|
|
# in turn leaves some undefined symbols like __fentry__ in purgatory and not
|
|
# sure how to relocate those.
|
|
ifdef CONFIG_FUNCTION_TRACER
|
|
PURGATORY_CFLAGS_REMOVE += $(CC_FLAGS_FTRACE)
|
|
endif
|
|
|
|
ifdef CONFIG_STACKPROTECTOR
|
|
PURGATORY_CFLAGS_REMOVE += -fstack-protector
|
|
endif
|
|
|
|
ifdef CONFIG_STACKPROTECTOR_STRONG
|
|
PURGATORY_CFLAGS_REMOVE += -fstack-protector-strong
|
|
endif
|
|
|
|
ifdef CONFIG_RETPOLINE
|
|
PURGATORY_CFLAGS_REMOVE += $(RETPOLINE_CFLAGS)
|
|
endif
|
|
|
|
CFLAGS_REMOVE_purgatory.o += $(PURGATORY_CFLAGS_REMOVE)
|
|
CFLAGS_purgatory.o += $(PURGATORY_CFLAGS)
|
|
|
|
CFLAGS_REMOVE_sha256.o += $(PURGATORY_CFLAGS_REMOVE)
|
|
CFLAGS_sha256.o += $(PURGATORY_CFLAGS)
|
|
|
|
CFLAGS_REMOVE_string.o += $(PURGATORY_CFLAGS_REMOVE)
|
|
CFLAGS_string.o += $(PURGATORY_CFLAGS)
|
|
|
|
AFLAGS_REMOVE_setup-x86_$(BITS).o += -Wa,-gdwarf-2
|
|
AFLAGS_REMOVE_entry64.o += -Wa,-gdwarf-2
|
|
|
|
$(obj)/purgatory.ro: $(PURGATORY_OBJS) FORCE
|
|
$(call if_changed,ld)
|
|
|
|
$(obj)/purgatory.chk: $(obj)/purgatory.ro FORCE
|
|
$(call if_changed,ld)
|
|
|
|
targets += kexec-purgatory.c
|
|
|
|
quiet_cmd_bin2c = BIN2C $@
|
|
cmd_bin2c = $(objtree)/scripts/bin2c kexec_purgatory < $< > $@
|
|
|
|
$(obj)/kexec-purgatory.c: $(obj)/purgatory.ro $(obj)/purgatory.chk FORCE
|
|
$(call if_changed,bin2c)
|
|
|
|
obj-$(CONFIG_KEXEC_FILE) += kexec-purgatory.o
|