summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/setup.c
diff options
context:
space:
mode:
authorJarkko Sakkinen <jarkko.sakkinen@intel.com>2012-05-08 21:22:46 +0300
committerH. Peter Anvin <hpa@linux.intel.com>2012-05-08 15:04:27 -0700
commitcda846f101fb1396b6924f1d9b68ac3d42de5403 (patch)
tree1fa8716c308b8e10156a1caf51d8ff6c98eceea9 /arch/x86/kernel/setup.c
parentbf8b88e97716feb750c3d34492f00d9c085e1183 (diff)
downloadlinux-cda846f101fb1396b6924f1d9b68ac3d42de5403.tar.gz
linux-cda846f101fb1396b6924f1d9b68ac3d42de5403.tar.xz
linux-cda846f101fb1396b6924f1d9b68ac3d42de5403.zip
x86, realmode: read cr4 and EFER from kernel for 64-bit trampoline
This patch changes 64-bit trampoline so that CR4 and EFER are provided by the kernel instead of using fixed values. Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@intel.com> Link: http://lkml.kernel.org/r/1336501366-28617-24-git-send-email-jarkko.sakkinen@intel.com Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'arch/x86/kernel/setup.c')
-rw-r--r--arch/x86/kernel/setup.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 7a14fece9cfc..efcf305210a4 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -975,6 +975,8 @@ void __init setup_arch(char **cmdline_p)
if (boot_cpu_data.cpuid_level >= 0) {
/* A CPU has %cr4 if and only if it has CPUID */
mmu_cr4_features = read_cr4();
+ if (trampoline_cr4_features)
+ *trampoline_cr4_features = mmu_cr4_features;
}
#ifdef CONFIG_X86_32