mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
x86/setup: Read CR4 earlier in __start_xen()
This is necessary for read_cr4() to function correctly. Move the EFER caching
at the same time.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
(cherry picked from commit 9851bc4939)
This commit is contained in:
1 parent
d220178b3c
commit
6c932a788c
1 file changed
+3
-3
@@ -851,6 +851,9 @@ void __init noreturn __start_xen(unsigned long mbi_p)
|
||||
|
||||
/* Full exception support from here on in. */
|
||||
|
||||
rdmsrl(MSR_EFER, this_cpu(efer));
|
||||
asm volatile ( "mov %%cr4,%0" : "=r" (get_cpu_info()->cr4) );
|
||||
|
||||
/* Enable NMIs. Our loader (e.g. Tboot) may have left them disabled. */
|
||||
enable_nmis();
|
||||
|
||||
@@ -897,9 +900,6 @@ void __init noreturn __start_xen(unsigned long mbi_p)
|
||||
|
||||
parse_video_info();
|
||||
|
||||
rdmsrl(MSR_EFER, this_cpu(efer));
|
||||
asm volatile ( "mov %%cr4,%0" : "=r" (get_cpu_info()->cr4) );
|
||||
|
||||
/* We initialise the serial devices very early so we can get debugging. */
|
||||
ns16550.io_base = 0x3f8;
|
||||
ns16550.irq = 4;
|
||||
|
||||