From mboxrd@z Thu Jan 1 00:00:00 1970 From: Keir Fraser Subject: Re: [PATCH 2 of 4] x86: make the pv-only e820 array be dynamic Date: Tue, 12 Apr 2011 14:06:05 +0100 Message-ID: References: <20110412125317.GA19198@dumpdata.com> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20110412125317.GA19198@dumpdata.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Konrad Rzeszutek Wilk Cc: xen-devel@lists.xensource.com, Ian Jackson , Ian.Campbell@citrix.com, Tim.Deegan@citrix.com List-Id: xen-devel@lists.xenproject.org On 12/04/2011 13:53, "Konrad Rzeszutek Wilk" wrote: >> How cunning. >> >> Why wouldn't you just allocate exactly the right size of array in >> XENMEM_set_memory_map? > > I was thinking about it, but the mm.c code did not have the > xen/xmalloc.h header, nor any references to xmalloc_array. > > Is it OK to make an xmalloc_array during a hypercall? Yes. I think the toolstack should be able to clean up on the newly-possible ENOMEM return from this hypercall. -- Keir