[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [patch] pagetable cleanups


  • To: Gerd Knorr <kraxel@xxxxxxxxxxx>
  • From: Christian Limpach <christian.limpach@xxxxxxxxx>
  • Date: Thu, 14 Apr 2005 09:47:49 -0700
  • Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
  • Delivery-date: Thu, 14 Apr 2005 16:47:45 +0000
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=hGRZ0bbRPYK4wq0fCHqmk+Tjm/t0xdYGFwfUFCkpOXeYDtMGJl4CKBM4e2efNM/xvepG8gQPuq0ttibgPi0j4dANDRRIXstcekEVbQutCupirnmxNMZK31IG1cUcpT5Rw85ZJHmd1D+S5fC4cHivZ/xMVgpXqZ8C5llc4O+hB5U=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

On 4/12/05, Gerd Knorr <kraxel@xxxxxxxxxxx> wrote:
> Index: xen/arch/x86/shadow.c
> ===================================================================
> --- xen.orig/arch/x86/shadow.c  2005-04-12 17:01:41.000000000 +0200
> +++ xen/arch/x86/shadow.c       2005-04-12 17:33:01.000000000 +0200
> @@ -333,9 +333,8 @@ free_shadow_hl2_table(struct domain *d,
> 
>     for ( i = 0; i < limit; i++ )
>     {
> -        unsigned long hl2e = l1_pgentry_val(hl2[i]);
> -        if ( hl2e & _PAGE_PRESENT )
> -            put_page(pfn_to_page(hl2e >> PAGE_SHIFT));
> +        if ( l1e_get_flags(*hl2) & _PAGE_PRESENT )
> +            put_page(pfn_to_page(l1e_get_pfn(*hl2)));
>     }
> 
>     unmap_domain_mem(hl2);

This hunk seems incorrect, you need to use hl2[i] instead of *hl2.
We need to be careful not to introduce bugs when making cleanups like
this one...  It would be good if a few more people looked through the
patch before we commit it, thanks!

    christian

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.