Skip to content

Commit 8586ca8

Browse files
committed
Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 fixes from Ingo Molnar: "Three fixes: a boot parameter re-(re-)fix, a retpoline build artifact fix and an LLVM workaround" * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/vdso: Drop implicit common-page-size linker flag x86/build: Fix compiler support check for CONFIG_RETPOLINE x86/boot: Clear RSDP address in boot_params for broken loaders
2 parents ebbd300 + ac3e233 commit 8586ca8

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

arch/x86/Makefile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -220,9 +220,6 @@ KBUILD_CFLAGS += -fno-asynchronous-unwind-tables
220220

221221
# Avoid indirect branches in kernel to deal with Spectre
222222
ifdef CONFIG_RETPOLINE
223-
ifeq ($(RETPOLINE_CFLAGS),)
224-
$(error You are building kernel with non-retpoline compiler, please update your compiler.)
225-
endif
226223
KBUILD_CFLAGS += $(RETPOLINE_CFLAGS)
227224
endif
228225

@@ -307,6 +304,13 @@ ifndef CC_HAVE_ASM_GOTO
307304
@echo Compiler lacks asm-goto support.
308305
@exit 1
309306
endif
307+
ifdef CONFIG_RETPOLINE
308+
ifeq ($(RETPOLINE_CFLAGS),)
309+
@echo "You are building kernel with non-retpoline compiler." >&2
310+
@echo "Please update your compiler." >&2
311+
@false
312+
endif
313+
endif
310314

311315
archclean:
312316
$(Q)rm -rf $(objtree)/arch/i386

arch/x86/entry/vdso/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ targets += $(vdso_img_sodbg) $(vdso_img-y:%=vdso%.so)
4747
CPPFLAGS_vdso.lds += -P -C
4848

4949
VDSO_LDFLAGS_vdso.lds = -m elf_x86_64 -soname linux-vdso.so.1 --no-undefined \
50-
-z max-page-size=4096 -z common-page-size=4096
50+
-z max-page-size=4096
5151

5252
$(obj)/vdso64.so.dbg: $(obj)/vdso.lds $(vobjs) FORCE
5353
$(call if_changed,vdso)
@@ -98,7 +98,7 @@ CFLAGS_REMOVE_vvar.o = -pg
9898

9999
CPPFLAGS_vdsox32.lds = $(CPPFLAGS_vdso.lds)
100100
VDSO_LDFLAGS_vdsox32.lds = -m elf32_x86_64 -soname linux-vdso.so.1 \
101-
-z max-page-size=4096 -z common-page-size=4096
101+
-z max-page-size=4096
102102

103103
# x32-rebranded versions
104104
vobjx32s-y := $(vobjs-y:.o=-x32.o)

arch/x86/include/asm/bootparam_utils.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ static void sanitize_boot_params(struct boot_params *boot_params)
3636
*/
3737
if (boot_params->sentinel) {
3838
/* fields in boot_params are left uninitialized, clear them */
39+
boot_params->acpi_rsdp_addr = 0;
3940
memset(&boot_params->ext_ramdisk_image, 0,
4041
(char *)&boot_params->efi_info -
4142
(char *)&boot_params->ext_ramdisk_image);

0 commit comments

Comments
 (0)