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

Re: [Xen-devel] [PATCH] linux: fix grant table bug


  • To: Michael Abd-El-Malek <mabdelmalek@xxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
  • From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
  • Date: Mon, 31 Mar 2008 10:53:04 +0100
  • Delivery-date: Mon, 31 Mar 2008 03:12:08 -0700
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>
  • Thread-index: AciTFQNbQcN8Nv8IEdy9kgAX8io7RQ==
  • Thread-topic: [Xen-devel] [PATCH] linux: fix grant table bug

On 31/3/08 04:42, "Michael Abd-El-Malek" <mabdelmalek@xxxxxxx> wrote:

> A PV OS has two grant table data structures: the grant table itself and a free
> list.  The free list is composed of an array of pages, which grow dynamically
> as 
> the guest OS requires more grants.  While the grant table contains 8-byte
> entries, the free list contains 4-byte entries.  So we have half as many pages
> in the free list than in the grant table.
> 
> There was a bug in the free list allocation code. The free list was indexed as
> if it was the same size as the grant table.  But it's only half as large.  So
> memory got corrupted, and I was seeing crashes in the slab allocator later on.

Nice catch. That code is a bit confusing!

 -- Keir



_______________________________________________
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®.