]> xenbits.xensource.com Git - libvirt.git/commitdiff
virpcimock: Introduce NVMe driver and devices
authorMichal Privoznik <mprivozn@redhat.com>
Fri, 14 Jun 2019 12:32:10 +0000 (14:32 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Tue, 17 Dec 2019 09:04:43 +0000 (10:04 +0100)
The device configs (which are actually the same one config)
come from a NVMe disk of mine.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
ACKed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Cole Robinson <crobinso@redhat.com>
tests/virpcimock.c
tests/virpcitestdata/0000-01-00.0.config [new file with mode: 0644]
tests/virpcitestdata/0000-02-00.0.config [new file with mode: 0644]

index cd6ae1cff688198ab83c6aa36d29cc2f85ad7425..6048118d5cff27c40781436bbe88bef1727979dd 100644 (file)
@@ -980,6 +980,7 @@ init_env(void)
     MAKE_PCI_DRIVER("iwlwifi", 0x8086, 0x0044);
     MAKE_PCI_DRIVER("i915", 0x8086, 0x0046, 0x8086, 0x0047);
     MAKE_PCI_DRIVER("vfio-pci", -1, -1);
+    MAKE_PCI_DRIVER("nvme", 0x1cc1, 0x8201);
 
 # define MAKE_PCI_DEVICE(Id, Vendor, Device, IommuGroup, ...) \
     do { \
@@ -1015,6 +1016,8 @@ init_env(void)
     MAKE_PCI_DEVICE("0021:de:1f.1", 0x8086, 0x0047, 13,
                     .physfn = "0021:de:1f.0"); /* Virtual Function */
 
+    MAKE_PCI_DEVICE("0000:01:00.0", 0x1cc1, 0x8201, 14, .klass = 0x010802);
+    MAKE_PCI_DEVICE("0000:02:00.0", 0x1cc1, 0x8201, 15, .klass = 0x010802);
 }
 
 
diff --git a/tests/virpcitestdata/0000-01-00.0.config b/tests/virpcitestdata/0000-01-00.0.config
new file mode 100644 (file)
index 0000000..f92455e
Binary files /dev/null and b/tests/virpcitestdata/0000-01-00.0.config differ
diff --git a/tests/virpcitestdata/0000-02-00.0.config b/tests/virpcitestdata/0000-02-00.0.config
new file mode 100644 (file)
index 0000000..ebb44d8
Binary files /dev/null and b/tests/virpcitestdata/0000-02-00.0.config differ