Skip to content

Commit 908bfda

Browse files
committed
Merge branch 'x86/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 fixes from Peter Anvin: "This is a pretty small batch: The biggest single change is to stop using EFI time services on 32-bit platforms. This matches our current behavior on 64-bit platforms as we already had ruled them out there as being too unreliable. Turns out that affects 32-bit platforms, too. One NULL pointer fix for SGI UV. Two minor build fixes, one of which only affects icc and the other which affects icc and future versions or nonstandard default settings of gcc" * 'x86/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86, efi: Don't use (U)EFI time services on 32 bit x86, build, icc: Remove uninitialized_var() from compiler-intel.h x86/UV: Fix NULL pointer dereference in uv_flush_tlb_others() if the 'nobau' boot option is used x86, build: Pass in additional -mno-mmx, -mno-sse options
2 parents 9199c4c + 04bf9ba commit 908bfda

File tree

7 files changed

+13
-19
lines changed

7 files changed

+13
-19
lines changed

arch/x86/Makefile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ ifeq ($(CONFIG_X86_32),y)
3131

3232
KBUILD_CFLAGS += -msoft-float -mregparm=3 -freg-struct-return
3333

34-
# Don't autogenerate SSE instructions
35-
KBUILD_CFLAGS += -mno-sse
34+
# Don't autogenerate MMX or SSE instructions
35+
KBUILD_CFLAGS += -mno-mmx -mno-sse
3636

3737
# Never want PIC in a 32-bit kernel, prevent breakage with GCC built
3838
# with nonstandard options
@@ -60,8 +60,8 @@ else
6060
KBUILD_AFLAGS += -m64
6161
KBUILD_CFLAGS += -m64
6262

63-
# Don't autogenerate SSE instructions
64-
KBUILD_CFLAGS += -mno-sse
63+
# Don't autogenerate MMX or SSE instructions
64+
KBUILD_CFLAGS += -mno-mmx -mno-sse
6565

6666
# Use -mpreferred-stack-boundary=3 if supported.
6767
KBUILD_CFLAGS += $(call cc-option,-mpreferred-stack-boundary=3)

arch/x86/boot/Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,18 +53,18 @@ $(obj)/cpustr.h: $(obj)/mkcpustr FORCE
5353

5454
# How to compile the 16-bit code. Note we always compile for -march=i386,
5555
# that way we can complain to the user if the CPU is insufficient.
56-
KBUILD_CFLAGS := $(USERINCLUDE) -g -Os -D_SETUP -D__KERNEL__ \
56+
KBUILD_CFLAGS := $(USERINCLUDE) -m32 -g -Os -D_SETUP -D__KERNEL__ \
5757
-DDISABLE_BRANCH_PROFILING \
5858
-Wall -Wstrict-prototypes \
5959
-march=i386 -mregparm=3 \
6060
-include $(srctree)/$(src)/code16gcc.h \
6161
-fno-strict-aliasing -fomit-frame-pointer -fno-pic \
62+
-mno-mmx -mno-sse \
6263
$(call cc-option, -ffreestanding) \
6364
$(call cc-option, -fno-toplevel-reorder,\
64-
$(call cc-option, -fno-unit-at-a-time)) \
65+
$(call cc-option, -fno-unit-at-a-time)) \
6566
$(call cc-option, -fno-stack-protector) \
6667
$(call cc-option, -mpreferred-stack-boundary=2)
67-
KBUILD_CFLAGS += $(call cc-option, -m32)
6868
KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__
6969
GCOV_PROFILE := n
7070

arch/x86/boot/compressed/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ KBUILD_CFLAGS += -DDISABLE_BRANCH_PROFILING
1313
cflags-$(CONFIG_X86_32) := -march=i386
1414
cflags-$(CONFIG_X86_64) := -mcmodel=small
1515
KBUILD_CFLAGS += $(cflags-y)
16+
KBUILD_CFLAGS += -mno-mmx -mno-sse
1617
KBUILD_CFLAGS += $(call cc-option,-ffreestanding)
1718
KBUILD_CFLAGS += $(call cc-option,-fno-stack-protector)
1819

arch/x86/platform/efi/efi.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -690,13 +690,6 @@ void __init efi_init(void)
690690

691691
set_bit(EFI_MEMMAP, &x86_efi_facility);
692692

693-
#ifdef CONFIG_X86_32
694-
if (efi_is_native()) {
695-
x86_platform.get_wallclock = efi_get_time;
696-
x86_platform.set_wallclock = efi_set_rtc_mmss;
697-
}
698-
#endif
699-
700693
#if EFI_DEBUG
701694
print_efi_memmap();
702695
#endif

arch/x86/platform/uv/tlb_uv.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1070,12 +1070,13 @@ const struct cpumask *uv_flush_tlb_others(const struct cpumask *cpumask,
10701070
unsigned long status;
10711071

10721072
bcp = &per_cpu(bau_control, cpu);
1073-
stat = bcp->statp;
1074-
stat->s_enters++;
10751073

10761074
if (bcp->nobau)
10771075
return cpumask;
10781076

1077+
stat = bcp->statp;
1078+
stat->s_enters++;
1079+
10791080
if (bcp->busy) {
10801081
descriptor_status =
10811082
read_lmmr(UVH_LB_BAU_SB_ACTIVATION_STATUS_0);

arch/x86/realmode/rm/Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,10 @@ KBUILD_CFLAGS := $(LINUXINCLUDE) -m32 -g -Os -D_SETUP -D__KERNEL__ -D_WAKEUP \
7373
-march=i386 -mregparm=3 \
7474
-include $(srctree)/$(src)/../../boot/code16gcc.h \
7575
-fno-strict-aliasing -fomit-frame-pointer -fno-pic \
76+
-mno-mmx -mno-sse \
7677
$(call cc-option, -ffreestanding) \
7778
$(call cc-option, -fno-toplevel-reorder,\
78-
$(call cc-option, -fno-unit-at-a-time)) \
79+
$(call cc-option, -fno-unit-at-a-time)) \
7980
$(call cc-option, -fno-stack-protector) \
8081
$(call cc-option, -mpreferred-stack-boundary=2)
8182
KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__

include/linux/compiler-intel.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@
2828

2929
#endif
3030

31-
#define uninitialized_var(x) x
32-
3331
#ifndef __HAVE_BUILTIN_BSWAP16__
3432
/* icc has this, but it's called _bswap16 */
3533
#define __HAVE_BUILTIN_BSWAP16__

0 commit comments

Comments
 (0)