WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

RE: [Xen-devel] How to determine memory size in HVM

To: "Keir Fraser" <keir.fraser@xxxxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: RE: [Xen-devel] How to determine memory size in HVM
From: "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
Date: Tue, 9 Jun 2009 11:59:21 +1000
Cc:
Delivery-date: Mon, 08 Jun 2009 18:59:54 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C652DF7E.D024%keir.fraser@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <AEC6C66638C05B468B556EA548C1A77D016DD660@trantor> <C652DF7E.D024%keir.fraser@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcnoQyQ+SnpqPcQ3SyyBm4PWOeo0CwAAsYv+ABfoCiA=
Thread-topic: [Xen-devel] How to determine memory size in HVM
> 
> Hypercall XENMEM_current_reservation.
> 
> *But* be aware I'm not sure how that interacts with e.g., virtual
> framebuffer memory. Well, actually I know it will include the virtual
> framebuffer memory which is not actually really part of normal guest
RAM.
> The question will be: does the xenstore 'target' value also include
it? I
> guess you'll have to compare to create a HVM guest and compare the two
to
> decide.

Thanks for that.

Another question, if I do 'xm mem-set' (without any handling of the
memory/target value) and then reboot, the system reboots with the new
target memory value, making it impossible to add memory to the system
again (under Windows at least). The only way I can think of fixing that
is to write back to memory/target with the original value just before
rebooting, but even that could be prone to errors in case of an unclean
reboot or something... any way around this?

James


> 
>  -- Keir
> 
> On 08/06/2009 15:12, "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
wrote:
> 
> > How can I tell how much memory my VM has under HVM? I want to have
> > something concrete to compare the 'target' value in xenstore to for
> > ballooning so I am reluctant to ask Windows the question. There
seems to
> > be a nr_pages in start_info, but HVM doesn't have that...
> >
> > My reason for not wanting to ask Windows how much memory is that if
it
> > says we have 3.5G (reasonable without PAE) and xenstore says we have
4G
> > then I'm going to have to fudge things a bit to know whether we are
> > ballooning up or down etc.
> >
> > I could just read the initial target value from xenstore on boot,
but
> > even that could be changed before my drivers get to it.
> >
> > Thanks
> >
> > James
> >
> >
> > _______________________________________________
> > Xen-devel mailing list
> > Xen-devel@xxxxxxxxxxxxxxxxxxx
> > http://lists.xensource.com/xen-devel
> 


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