From: Wei Liu Date: Tue, 5 Feb 2019 13:51:12 +0000 (+0000) Subject: x86/smpboot: remove lXe_to_lYe in cleanup_cpu_root_pgt X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=25973999ef66e61b3732c0e464e21cd66ec2d75d;p=people%2Fliuw%2Fxen.git x86/smpboot: remove lXe_to_lYe in cleanup_cpu_root_pgt Signed-off-by: Wei Liu --- diff --git a/xen/arch/x86/smpboot.c b/xen/arch/x86/smpboot.c index 3560176601..241da6bc1a 100644 --- a/xen/arch/x86/smpboot.c +++ b/xen/arch/x86/smpboot.c @@ -951,11 +951,17 @@ static void cleanup_cpu_root_pgt(unsigned int cpu) /* Also zap the stub mapping for this CPU. */ if ( stub_linear ) { - l3_pgentry_t *l3t = l4e_to_l3e(common_pgt); - l2_pgentry_t *l2t = l3e_to_l2e(l3t[l3_table_offset(stub_linear)]); - l1_pgentry_t *l1t = l2e_to_l1e(l2t[l2_table_offset(stub_linear)]); + l3_pgentry_t *l3t = map_xen_pagetable_new(l4e_get_mfn(common_pgt)); + l2_pgentry_t *l2t = map_xen_pagetable_new( + l3e_get_mfn(l3t[l3_table_offset(stub_linear)])); + l1_pgentry_t *l1t = map_xen_pagetable_new( + l2e_get_mfn(l2t[l2_table_offset(stub_linear)])); l1t[l1_table_offset(stub_linear)] = l1e_empty(); + + unmap_xen_pagetable_new(l1t); + unmap_xen_pagetable_new(l2t); + unmap_xen_pagetable_new(l3t); } }