From: Avi Kivity <avi@redhat.com>
To: Adam Litke <agl@us.ibm.com>
Cc: Anthony Liguori <aliguori@us.ibm.com>, qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: virtio: Report new guest memory statistics pertinent to memory ballooning (V4)
Date: Thu, 19 Nov 2009 17:19:34 +0200 [thread overview]
Message-ID: <4B056206.4090207@redhat.com> (raw)
In-Reply-To: <1258643169.3464.3.camel@aglitke>
On 11/19/2009 05:06 PM, Adam Litke wrote:
> Avi and Anthony,
> If you agree that I've addressed all outstanding issues, please consider this
> patch for inclusion. Thanks.
>
>
I'd like to see this (and all other virtio-ABI-modifying patches) first
go into the virtio pci spec, then propagated to guest and host.
> Changes since V3:
> - Increase stat field size to 64 bits
> - Report all sizes in kb (not pages)
>
Why not bytes? It's the most natural unit.
> -static ram_addr_t virtio_balloon_to_target(void *opaque, ram_addr_t target)
> +static void request_stats(VirtIOBalloon *vb)
> +{
> + vb->stats_requested = 1;
> + reset_stats(vb);
> + monitor_suspend(cur_mon);
>
You allow the guest to kill a monitor here.
> + virtqueue_push(vb->svq,&vb->stats_vq_elem, vb->stats_vq_offset);
> + virtio_notify(&vb->vdev, vb->svq);
> +}
> +
>
> +typedef struct VirtIOBalloonStat {
> + uint16_t tag;
> + uint64_t val;
> +} VirtIOBalloonStat;
>
Alignment here depends on word size. This needs to be padded to be
aligned the same way on 32 and 64 bit hosts and guests.
--
error compiling committee.c: too many arguments to function
next prev parent reply other threads:[~2009-11-19 15:19 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-19 15:06 [Qemu-devel] virtio: Report new guest memory statistics pertinent to memory ballooning (V4) Adam Litke
2009-11-19 15:19 ` [Qemu-devel] virtio: Add memory statistics reporting to the balloon driver (V3) Adam Litke
2009-11-19 15:22 ` [Qemu-devel] " Avi Kivity
2009-11-19 15:58 ` Adam Litke
2009-11-19 16:13 ` Avi Kivity
2009-11-19 16:29 ` Adam Litke
2009-11-19 23:53 ` Rusty Russell
2009-11-23 9:44 ` Michael S. Tsirkin
2009-11-23 11:00 ` Dor Laor
2009-11-23 11:31 ` Vadim Rozenfeld
2009-11-19 15:19 ` Avi Kivity [this message]
2009-11-19 15:56 ` [Qemu-devel] Re: virtio: Report new guest memory statistics pertinent to memory ballooning (V4) Adam Litke
2009-11-19 16:02 ` Avi Kivity
2009-11-23 18:47 ` Anthony Liguori
2009-11-20 1:24 ` Jamie Lokier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B056206.4090207@redhat.com \
--to=avi@redhat.com \
--cc=agl@us.ibm.com \
--cc=aliguori@us.ibm.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).