Received: from eggs.gnu.org ([2001:4830:134:3::10]:38991) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZIDyP-0006cM-3F for qemu-devel@nongnu.org; Thu, 23 Jul 2015 06:43:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZIDyK-0006IV-HK for qemu-devel@nongnu.org; Thu, 23 Jul 2015 06:43:33 -0400 Received: from e06smtp16.uk.ibm.com ([195.75.94.112]:52505) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZIDyK-0006I8-8R for qemu-devel@nongnu.org; Thu, 23 Jul 2015 06:43:28 -0400 Received: from /spool/local by e06smtp16.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 23 Jul 2015 11:43:23 +0100 Date: Thu, 23 Jul 2015 12:43:13 +0200 From: Cornelia Huck Message-ID: <20150723124313.4fa37208.cornelia.huck@de.ibm.com> In-Reply-To: <1437557634-13210-1-git-send-email-mst@redhat.com> References: <1437557634-13210-1-git-send-email-mst@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH RFC] virtio: set any_layout in virtio core List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: Kevin Wolf , qemu-block@nongnu.org, Jason Wang , qemu-devel@nongnu.org, Stefan Hajnoczi , Paolo Bonzini On Wed, 22 Jul 2015 12:36:22 +0300 "Michael S. Tsirkin" wrote: > Virtio 1 requires this, and all devices are clean by now, > so let's do it! > > Exceptions: > - virtio-blk > - compat machine types > > Signed-off-by: Michael S. Tsirkin > --- > > Untested - consider this pseudo-code - it just seems easier to write it > in C than try to explain it. > > include/hw/compat.h | 22 +++++++++++++++++++++- > include/hw/virtio/virtio.h | 4 +++- > hw/block/virtio-blk.c | 1 + > hw/net/virtio-net.c | 2 -- > hw/scsi/virtio-scsi.c | 2 -- > 5 files changed, 25 insertions(+), 6 deletions(-) > > diff --git a/include/hw/compat.h b/include/hw/compat.h > index 4a43466..94c8097 100644 > --- a/include/hw/compat.h > +++ b/include/hw/compat.h > @@ -2,7 +2,27 @@ > #define HW_COMPAT_H > > #define HW_COMPAT_2_3 \ > - /* empty */ > + {\ > + .driver = "virtio-blk-pci",\ > + .property = "any_layout",\ > + .value = "off",\ > + },{\ > + .driver = "virtio-balloon-pci",\ > + .property = "any_layout",\ > + .value = "off",\ > + },{\ > + .driver = "virtio-serial-pci",\ > + .property = "any_layout",\ > + .value = "off",\ > + },{\ > + .driver = "virtio-9p-pci",\ > + .property = "any_layout",\ > + .value = "off",\ > + },{\ > + .driver = "virtio-rng-pci",\ > + .property = "any_layout",\ > + .value = "off",\ > + }, Isn't that a bit late for 2.4? Especially as not all devices are clean yet, as Jason pointed out. If we do this for 2.5, we'll also need compat handlers for ccw. > > #define HW_COMPAT_2_2 \ > /* empty */