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

Re: [Xen-devel] [PATCH V2 3/5] libxl: Specify the target ram size to Qemu (new) when calling it



On Mon, 13 Dec 2010, Ian Campbell wrote:
> On Mon, 2010-12-13 at 14:14 +0000, Anthony Perard wrote:
> > On Mon, 13 Dec 2010, Ian Campbell wrote:
> > 
> > > On Mon, 2010-12-13 at 13:15 +0000, anthony.perard@xxxxxxxxxx wrote:
> > > >
> > > > +    dm_info->target_ram = b_info->target_memkb / 1024;
> > > >      dm_info->videoram = b_info->video_memkb / 1024;
> > >
> > > Both of these end up rounding down, is that desirable?
> > 
> > They are both multiplied by 1024 from the config file before they are
> > stored in the b_info->*_memkb variables. So have them rounding down or
> > up will not change anything.
> 
> Fair enough. 
> 
> Makes me wonder if b_info->foo_memkb has the correct units. Also since
> libxl is supposed to be usable by other than xl relying on particular
> subtle behaviour like this seems unwise. This patch does make things any
> worse though I guess.

I think we should define a macro or a simple inline function to do kb to
mb conversions, rounding up the result.

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