From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:40014) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UT7ZV-0006TH-L5 for qemu-devel@nongnu.org; Fri, 19 Apr 2013 05:25:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UT7ZU-0001O0-1z for qemu-devel@nongnu.org; Fri, 19 Apr 2013 05:25:33 -0400 Received: from mail-we0-x236.google.com ([2a00:1450:400c:c03::236]:41401) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UT7ZT-0001Nv-Rz for qemu-devel@nongnu.org; Fri, 19 Apr 2013 05:25:31 -0400 Received: by mail-we0-f182.google.com with SMTP id m1so3285378wea.41 for ; Fri, 19 Apr 2013 02:25:31 -0700 (PDT) Date: Fri, 19 Apr 2013 11:25:28 +0200 From: Stefan Hajnoczi Message-ID: <20130419092528.GA29826@stefanha-thinkpad.redhat.com> References: <1365624994-10219-1-git-send-email-keith.busch@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1365624994-10219-1-git-send-email-keith.busch@intel.com> Subject: Re: [Qemu-devel] [PATCH] NVMe: Initial commit List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Keith Busch Cc: qemu-devel@nongnu.org, Keith Busch On Wed, Apr 10, 2013 at 02:16:34PM -0600, Keith Busch wrote: > Initial commit for emulated nvme pci storage device. Implements the > minimum from the specification to work with existing drivers. > > Cc: Keith Busch > Signed-off-by: Keith Busch > > A lot of people are very interested in this, so I should have more time > to dedicate working on submitting this upstream. Thanks for the feedback > on the last round. Only difference here besides the merge-up is making > the serial option mandatory and a fix for > 4GB backing storage. > --- > MAINTAINERS | 5 + > default-configs/pci.mak | 1 + > hw/block/Makefile.objs | 1 + > hw/block/nvme.c | 944 ++++++++++++++++++++++++++++++++++++++++++++++ > hw/block/nvme.h | 712 ++++++++++++++++++++++++++++++++++ > include/hw/pci/pci_ids.h | 1 + > 6 files changed, 1664 insertions(+), 0 deletions(-) > create mode 100644 hw/block/nvme.c > create mode 100644 hw/block/nvme.h I don't see bdrv_aio_flush() in this patch. How does the guest ensure that data is safely on persistent storage (e.g. protected against data loss by power failure). > diff --git a/MAINTAINERS b/MAINTAINERS > index 4dfd8bf..fbd973e 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -609,6 +609,11 @@ S: Supported > F: hw/char/virtio-serial-bus.c > F: hw/char/virtio-console.c > > +nvme > +M: Keith Busch > +S: Supported > +F: hw/nvme* hw/block/nvme* > +static void nvme_class_init(ObjectClass *oc, void *data) > +{ > + DeviceClass *dc = DEVICE_CLASS(oc); > + PCIDeviceClass *pc = PCI_DEVICE_CLASS(oc); > + > + pc->init = nvme_init; > + pc->exit = nvme_exit; > + pc->class_id = PCI_CLASS_STORAGE_EXPRESS; > + pc->vendor_id = PCI_VENDOR_ID_INTEL; > + pc->device_id = 0x5845; > + pc->subsystem_vendor_id = PCI_VENDOR_ID_INTEL; > + pc->subsystem_id = 0x1234; 0x1234?