[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/3] virtio-balloon: note optional features
From: |
Michael S. Tsirkin |
Subject: |
Re: [Qemu-devel] [PATCH 2/3] virtio-balloon: note optional features |
Date: |
Tue, 6 Mar 2012 16:55:31 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Tue, Mar 06, 2012 at 01:22:06PM +0100, Paolo Bonzini wrote:
> It is not a problem if the destination does not have
> VIRTIO_BALLOON_F_MUST_TELL_HOST. In that case, the guest
> will simply do useless virtqueue traffic, but the destination
> does not have a problem.
> (In fact, it _is_ a problem if the destination has
> VIRTIO_BALLOON_F_MUST_TELL_HOST but the source does not.
> The feature bit should have been backwards! Luckily,
> our implementation is free from this problem).
>
> Signed-off-by: Paolo Bonzini <address@hidden>
Can't we just add a flag to control this feature?
> ---
> hw/virtio-balloon.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c
> index 0ade8b0..d10df2e 100644
> --- a/hw/virtio-balloon.c
> +++ b/hw/virtio-balloon.c
> @@ -216,7 +216,7 @@ static int virtio_balloon_load(QEMUFile *f, void *opaque,
> int version_id)
> if (version_id != 1)
> return -EINVAL;
>
> - ret = virtio_load(&s->vdev, f, 0);
> + ret = virtio_load(&s->vdev, f, VIRTIO_BALLOON_F_MUST_TELL_HOST);
> if (ret) {
> return ret;
> }
> --
> 1.7.7.6
>
[Qemu-devel] [PATCH 1/3] virtio: let devices be permissive on enabled features, Paolo Bonzini, 2012/03/06