ia64/xen-unstable

changeset 8058:549130374cfa

In shadow-external mode, every VCPU must free its own
monitor pagetable.

Signed-off-by: Xin Li <xin.b.li@intel.com>
author kaf24@firebug.cl.cam.ac.uk
date Fri Nov 25 17:58:36 2005 +0100 (2005-11-25)
parents d46553f73c6f
children c3cfc4ff3b08
files xen/arch/x86/shadow32.c xen/arch/x86/shadow_public.c
line diff
     1.1 --- a/xen/arch/x86/shadow32.c	Fri Nov 25 17:53:41 2005 +0100
     1.2 +++ b/xen/arch/x86/shadow32.c	Fri Nov 25 17:58:36 2005 +0100
     1.3 @@ -800,13 +800,10 @@ void free_monitor_pagetable(struct vcpu 
     1.4  
     1.5      /*
     1.6       * Then free monitor_table.
     1.7 -     * Note: for VMX guest, only BSP need do this free.
     1.8       */
     1.9 -    if (!(VMX_DOMAIN(v) && v->vcpu_id)) {
    1.10 -        mfn = pagetable_get_pfn(v->arch.monitor_table);
    1.11 -        unmap_domain_page(v->arch.monitor_vtable);
    1.12 -        free_domheap_page(&frame_table[mfn]);
    1.13 -    }
    1.14 +    mfn = pagetable_get_pfn(v->arch.monitor_table);
    1.15 +    unmap_domain_page(v->arch.monitor_vtable);
    1.16 +    free_domheap_page(&frame_table[mfn]);
    1.17  
    1.18      v->arch.monitor_table = mk_pagetable(0);
    1.19      v->arch.monitor_vtable = 0;
     2.1 --- a/xen/arch/x86/shadow_public.c	Fri Nov 25 17:53:41 2005 +0100
     2.2 +++ b/xen/arch/x86/shadow_public.c	Fri Nov 25 17:58:36 2005 +0100
     2.3 @@ -297,13 +297,11 @@ void free_monitor_pagetable(struct vcpu 
     2.4  
     2.5      /*
     2.6       * free monitor_table.
     2.7 -     * Note: for VMX guest, only BSP need do this free.
     2.8       */
     2.9 -    if (!(VMX_DOMAIN(v) && v->vcpu_id)) {
    2.10 -        mfn = pagetable_get_pfn(v->arch.monitor_table);
    2.11 -        unmap_domain_page(v->arch.monitor_vtable);
    2.12 -        free_domheap_page(&frame_table[mfn]);
    2.13 -    }
    2.14 +    mfn = pagetable_get_pfn(v->arch.monitor_table);
    2.15 +    unmap_domain_page(v->arch.monitor_vtable);
    2.16 +    free_domheap_page(&frame_table[mfn]);
    2.17 +
    2.18      v->arch.monitor_table = mk_pagetable(0);
    2.19      v->arch.monitor_vtable = 0;
    2.20  }
    2.21 @@ -396,18 +394,15 @@ void free_monitor_pagetable(struct vcpu 
    2.22  
    2.23      /*
    2.24       * Then free monitor_table.
    2.25 -     * Note: for VMX guest, only BSP need do this free.
    2.26       */
    2.27 -    if (!(VMX_DOMAIN(v) && v->vcpu_id)) {
    2.28 -        mfn = pagetable_get_pfn(v->arch.monitor_table);
    2.29 -        unmap_domain_page(v->arch.monitor_vtable);
    2.30 -        free_domheap_page(&frame_table[mfn]);
    2.31 -    }
    2.32 +    mfn = pagetable_get_pfn(v->arch.monitor_table);
    2.33 +    unmap_domain_page(v->arch.monitor_vtable);
    2.34 +    free_domheap_page(&frame_table[mfn]);
    2.35  
    2.36      v->arch.monitor_table = mk_pagetable(0);
    2.37      v->arch.monitor_vtable = 0;
    2.38  }
    2.39 -#endif 
    2.40 +#endif
    2.41  
    2.42  static void
    2.43  shadow_free_snapshot(struct domain *d, struct out_of_sync_entry *entry)