Skip to content

Commit

Permalink
xen: set up mmu_ops before trying to set any ptes
Browse files Browse the repository at this point in the history
xen_setup_stackprotector() ends up trying to set page protections,
so we need to have vm_mmu_ops set up before trying to do so.
Failing to do so causes an early boot crash.

[ Impact: Fix early crash under Xen. ]

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
  • Loading branch information
Jeremy Fitzhardinge committed Oct 27, 2009
1 parent 964fe08 commit 973df35
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/x86/xen/enlighten.c
Original file line number Diff line number Diff line change
Expand Up @@ -1075,6 +1075,8 @@ asmlinkage void __init xen_start_kernel(void)
* Set up some pagetable state before starting to set any ptes.
*/

xen_init_mmu_ops();

/* Prevent unwanted bits from being set in PTEs. */
__supported_pte_mask &= ~_PAGE_GLOBAL;
if (!xen_initial_domain())
Expand All @@ -1099,7 +1101,6 @@ asmlinkage void __init xen_start_kernel(void)
*/
xen_setup_stackprotector();

xen_init_mmu_ops();
xen_init_irq_ops();
xen_init_cpuid_mask();

Expand Down

0 comments on commit 973df35

Please sign in to comment.