ia64/xen-unstable

changeset 11301:a19dbbe4cff5

[IA64] Modify destroy code for PV-on-HVM on IPF

Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
Signed-off-by: Tomonari Horikoshi <t.horikoshi@jp.fujitsu.com>
author awilliam@xenbuild.aw
date Mon Aug 28 13:11:17 2006 -0600 (2006-08-28)
parents 40f6fdb68fa9
children 1317833f657b
files xen/arch/ia64/xen/domain.c
line diff
     1.1 --- a/xen/arch/ia64/xen/domain.c	Sun Aug 27 10:25:39 2006 -0600
     1.2 +++ b/xen/arch/ia64/xen/domain.c	Mon Aug 28 13:11:17 2006 -0600
     1.3 @@ -400,8 +400,16 @@ fail_nomem:
     1.4  void arch_domain_destroy(struct domain *d)
     1.5  {
     1.6  	BUG_ON(d->arch.mm.pgd != NULL);
     1.7 -	if (d->shared_info != NULL)
     1.8 -	    free_xenheap_pages(d->shared_info, get_order_from_shift(XSI_SHIFT));
     1.9 +	if (d->shared_info != NULL) {
    1.10 +		/* If this domain is domVTi, the shared_info page may
    1.11 +		 * be replaced with domheap. Then the shared_info page
    1.12 +		 * frees in relinquish_mm().
    1.13 +		 */
    1.14 +		if (IS_XEN_HEAP_FRAME(virt_to_page(d->shared_info))) {
    1.15 +			free_xenheap_pages(d->shared_info,
    1.16 +			                   get_order_from_shift(XSI_SHIFT));
    1.17 +		}
    1.18 +	}
    1.19  	if (d->arch.shadow_bitmap != NULL)
    1.20  		xfree(d->arch.shadow_bitmap);
    1.21