ia64/xen-unstable

changeset 8397:e7977d6aa6ba

Unmap io shared page only if it is properly initialized.

Signed-off-by: Xin Li <xin.b.li@intel.com>
author kaf24@firebug.cl.cam.ac.uk
date Thu Dec 15 20:43:44 2005 +0100 (2005-12-15)
parents fb1f2498ce1e
children 803d5e9ae5f4
files xen/arch/x86/vmx.c
line diff
     1.1 --- a/xen/arch/x86/vmx.c	Thu Dec 15 20:42:09 2005 +0100
     1.2 +++ b/xen/arch/x86/vmx.c	Thu Dec 15 20:43:44 2005 +0100
     1.3 @@ -102,7 +102,8 @@ void vmx_relinquish_resources(struct vcp
     1.4      if (v->vcpu_id == 0) {
     1.5          /* unmap IO shared page */
     1.6          struct domain *d = v->domain;
     1.7 -        unmap_domain_page((void *)d->arch.vmx_platform.shared_page_va);
     1.8 +        if ( d->arch.vmx_platform.shared_page_va )
     1.9 +            unmap_domain_page((void *)d->arch.vmx_platform.shared_page_va);
    1.10      }
    1.11  
    1.12      destroy_vmcs(&v->arch.arch_vmx);