ia64/xen-unstable

changeset 3739:4412ac39cc85

bitkeeper revision 1.1159.255.1 (420911c0Dpqzcuh7CS1OpkVP4miSbQ)

misc debug audit cleanups
Signed-off-by: ian.pratt@cl.cam.ac.uk
author iap10@freefall.cl.cam.ac.uk
date Tue Feb 08 19:23:44 2005 +0000 (2005-02-08)
parents a00d7a994a59
children 872ae5bed5f4
files xen/arch/x86/domain.c xen/arch/x86/mm.c
line diff
     1.1 --- a/xen/arch/x86/domain.c	Tue Feb 08 15:45:45 2005 +0000
     1.2 +++ b/xen/arch/x86/domain.c	Tue Feb 08 19:23:44 2005 +0000
     1.3 @@ -783,6 +783,7 @@ void domain_relinquish_memory(struct dom
     1.4          if ( pagetable_val(ed->arch.pagetable) != 0 )
     1.5              put_page_and_type(&frame_table[pagetable_val(ed->arch.pagetable) >>
     1.6                                             PAGE_SHIFT]);
     1.7 +        ed->arch.pagetable = mk_pagetable(0);
     1.8      }
     1.9  
    1.10  #ifdef CONFIG_VMX
     2.1 --- a/xen/arch/x86/mm.c	Tue Feb 08 15:45:45 2005 +0000
     2.2 +++ b/xen/arch/x86/mm.c	Tue Feb 08 19:23:44 2005 +0000
     2.3 @@ -2320,8 +2320,9 @@ void audit_domain(struct domain *d)
     2.4  
     2.5  
     2.6      /* PHASE 1 */
     2.7 -
     2.8 -    adjust(&frame_table[pagetable_val(d->exec_domain[0]->arch.pagetable)>>PAGE_SHIFT], -1, 1);
     2.9 +    if ( pagetable_val(d->exec_domain[0]->arch.pagetable) )
    2.10 +        adjust(&frame_table[pagetable_val(d->exec_domain[0]->arch.pagetable)
    2.11 +                           >>PAGE_SHIFT], -1, 1);
    2.12  
    2.13      list_ent = d->page_list.next;
    2.14      for ( i = 0; (list_ent != &d->page_list); i++ )
    2.15 @@ -2574,10 +2575,11 @@ void audit_domain(struct domain *d)
    2.16  
    2.17      spin_unlock(&d->page_alloc_lock);
    2.18  
    2.19 -    adjust(&frame_table[pagetable_val(
    2.20 -        d->exec_domain[0]->arch.pagetable)>>PAGE_SHIFT], 1, 1);
    2.21 -
    2.22 -    printk("Audit %d: Done. ctot=%d ttot=%d\n", d->id, ctot, ttot );
    2.23 +    if ( pagetable_val(d->exec_domain[0]->arch.pagetable) )
    2.24 +        adjust(&frame_table[pagetable_val(
    2.25 +            d->exec_domain[0]->arch.pagetable)>>PAGE_SHIFT], 1, 1);
    2.26 +
    2.27 +    printk("Audit %d: Done. pages=%d ctot=%d ttot=%d\n", d->id, i, ctot, ttot );
    2.28  
    2.29      if ( d != current->domain )
    2.30          domain_unpause(d);