hw/nvme: Move NVMe emulation out of hw/block/ directory
RFC PATCH 1/1 hw/nvme: Move NVMe emulation out of hw/block/ directory
As IDE used to be, NVMe emulation is becoming an active subsystem. Move it into its own namespace.
Signed-off-by Philippe Mathieu-Daudé <[email protected]>
---
sent as RFC, it case it helps NVMe developers. As nvme-next has patches queues, if the idea of moving seems useful, this patch can resend later.
---
meson.build | 1 +
hw/{block/nvme.h => nvme/nvme-internal.h} | 4 +-
hw/{block/nvme.c => nvme/core.c} | 2 +-
MAINTAINERS | 2 +-
hw/Kconfig | 1 +
hw/block/Kconfig | 5 -
hw/block/meson.build | 1 -
hw/block/trace-events | 124 ---------------------
hw/meson.build | 1 +
hw/nvme/Kconfig | 4 +
hw/nvme/meson.build | 1 +
hw/nvme/trace-events | 125 ++++++++++++++++++++++
12 files changed, 137 insertions(+), 134 deletions(-)
rename hw/{block/nvme.h => nvme/nvme-internal.h} (98%)
rename hw/{block/nvme.c => nvme/core.c} (99%)
create mode 100644 hw/nvme/Kconfig
create mode 100644 hw/nvme/meson.build
create mode 100644 hw/nvme/trace-eventsmeson.build +1 -0
@@ -1356,6 +1356,7 @@ 'hw/misc', 'hw/misc/macio', 'hw/net', + 'hw/nvme', 'hw/nvram', 'hw/pci', 'hw/pci-host',
hw/nvme/nvme-internal.h renamed from hw/block/nvme.h +2 -2
@@ -1,5 +1,5 @@ -#ifndef HW_NVME_H -#define HW_NVME_H +#ifndef HW_NVME_INTERNAL_H +#define HW_NVME_INTERNAL_H #include "block/nvme.h"
hw/nvme/core.c renamed from hw/block/nvme.c +1 -1
@@ -67,8 +67,8 @@#include "qemu/log.h" #include "qemu/module.h" #include "qemu/cutils.h" +#include "nvme-internal.h" #include "trace.h" -#include "nvme.h" #define NVME_MAX_IOQPAIRS 0xffff#define NVME_DB_SIZE 4
MAINTAINERS +1 -1
@@ -1875,7 +1875,7 @@ M: Keith Busch <[email protected]> M: Klaus Jensen <[email protected]> L: [email protected] S: Supported -F: hw/block/nvme* +F: hw/nvme/ F: tests/qtest/nvme-test.c T: git git://git.infradead.org/qemu-nvme.git nvme-next
hw/Kconfig +1 -0
@@ -21,6 +21,7 @@ source mem/Kconfig source misc/Kconfig source net/Kconfig source nubus/Kconfig +source nvme/Kconfig source nvram/Kconfig source pci-bridge/Kconfig source pci-host/Kconfig
hw/block/Kconfig +0 -5
@@ -22,11 +22,6 @@ config ECC config ONENAND bool -config NVME_PCI - bool - default y if PCI_DEVICES - depends on PCI - config VIRTIO_BLK bool default y
hw/block/meson.build +0 -1
@@ -13,7 +13,6 @@ softmmu_ss.add(when: 'CONFIG_SWIM', if_true: files('swim.c')) softmmu_ss.add(when: 'CONFIG_XEN', if_true: files('xen-block.c')) softmmu_ss.add(when: 'CONFIG_SH4', if_true: files('tc58128.c')) -softmmu_ss.add(when: 'CONFIG_NVME_PCI', if_true: files('nvme.c')) specific_ss.add(when: 'CONFIG_VIRTIO_BLK', if_true: files('virtio-blk.c')) specific_ss.add(when: 'CONFIG_VHOST_USER_BLK', if_true: files('vhost-user-blk.c'))
hw/block/trace-events +0 -124
130 lines not on this page · raw message
hw/meson.build +1 -0
@@ -21,6 +21,7 @@ subdir('misc') subdir('net') subdir('nubus') +subdir('nvme') subdir('nvram') subdir('pci') subdir('pci-bridge')
hw/nvme/Kconfig new file +4 -0
@@ -0,0 +1,4 @@ +config NVME_PCI + bool + default y if PCI_DEVICES + depends on PCI
hw/nvme/meson.build new file +1 -0
@@ -0,0 +1 @@ +softmmu_ss.add(when: 'CONFIG_NVME_PCI', if_true: files('core.c'))
hw/nvme/trace-events new file +125 -0
125 lines not on this page · raw message
Signature · 1 line
2.26.2