From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:45957) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S4vnT-0007qG-BU for qemu-devel@nongnu.org; Tue, 06 Mar 2012 09:55:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S4vnO-0002YB-Fh for qemu-devel@nongnu.org; Tue, 06 Mar 2012 09:55:26 -0500 Received: from mx1.redhat.com ([209.132.183.28]:52371) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S4vnO-0002Y6-7t for qemu-devel@nongnu.org; Tue, 06 Mar 2012 09:55:22 -0500 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q26EtKff028719 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 6 Mar 2012 09:55:20 -0500 Date: Tue, 6 Mar 2012 16:55:31 +0200 From: "Michael S. Tsirkin" Message-ID: <20120306145529.GF12096@redhat.com> References: <1331036527-7651-1-git-send-email-pbonzini@redhat.com> <1331036527-7651-3-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1331036527-7651-3-git-send-email-pbonzini@redhat.com> Subject: Re: [Qemu-devel] [PATCH 2/3] virtio-balloon: note optional features List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: amit.shah@redhat.com, uobergfe@redhat.com, owasserm@redhat.com, qemu-devel@nongnu.org, armbru@redhat.com 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 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 >