linux/arch/x86
H. Peter Anvin 5a5a51db78 x86-32: Start out eflags and cr4 clean
%cr4 is supposed to reflect a set of features into which the operating
system is opting in.  If the BIOS or bootloader leaks bits here, this
is not desirable.  Consider a bootloader passing in %cr4.pae set to a
legacy paging kernel, for example -- it will not have any immediate
effect, but the kernel would crash when turning paging on.

A similar argument applies to %eflags, and since we have to look for
%eflags.id being settable we can use a sequence which clears %eflags
as a side effect.

Note that we already do this for x86-64.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Link: http://lkml.kernel.org/r/1348529239-17943-1-git-send-email-hpa@linux.intel.com
2012-09-26 15:06:22 -07:00
..
boot x86, build: Globally set -fno-pic 2012-08-10 16:12:30 -07:00
configs
crypto crypto: twofish-avx - remove useless instruction 2012-07-11 11:08:30 +08:00
ia32 Merge branch 'x86/fpu' into x86/smap 2012-09-21 17:18:44 -07:00
include/asm x86, smap: Do not abuse the [f][x]rstor_checking() functions for user space 2012-09-25 15:42:18 -07:00
kernel x86-32: Start out eflags and cr4 clean 2012-09-26 15:06:22 -07:00
kvm x86, kvm: fix kvm's usage of kernel_fpu_begin/end() 2012-09-21 16:59:04 -07:00
lguest
lib x86, smap: Add STAC and CLAC instructions to control user space access 2012-09-21 12:45:27 -07:00
math-emu
mm x86, smap: A page fault due to SMAP is an oops 2012-09-21 12:45:27 -07:00
net
oprofile perf/x86/amd: Unify AMD's generic and family 15h pmus 2012-07-05 21:19:41 +02:00
pci Merge branch 'pci/myron-pcibios_setup' into next 2012-07-05 15:31:05 -06:00
platform Revert "x86-64/efi: Use EFI to deal with platform wall clock" 2012-08-14 09:58:25 -07:00
power
realmode x86, build: Globally set -fno-pic 2012-08-10 16:12:30 -07:00
syscalls x32: Use compat shims for {g,s}etsockopt 2012-08-18 14:15:39 -07:00
tools
um um: switch UPT_SET_RETURN_VALUE and regs_return_value to pt_regs 2012-08-01 23:33:16 +02:00
vdso
video
xen Three bug-fixes: 2012-08-25 17:31:59 -07:00
.gitignore
Kbuild
Kconfig x86, smap: Add a header file with macros for STAC/CLAC 2012-09-21 12:45:26 -07:00
Kconfig.cpu
Kconfig.debug x86/tlb: add tlb_flushall_shift knob into debugfs 2012-06-27 19:29:10 -07:00
Makefile x86, build: Globally set -fno-pic 2012-08-10 16:12:30 -07:00
Makefile_32.cpu
Makefile.um