nvme: use TYPE_NVME instead of constant string

Signed-off-by: Li Qiang <liq3ea@163.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-id: 20190120055558.32984-2-liq3ea@163.com
Signed-off-by: Max Reitz <mreitz@redhat.com>
This commit is contained in:
Li Qiang 2019-01-19 21:55:56 -08:00 committed by Max Reitz
parent d339d766d1
commit 08db59e188

View File

@ -1381,7 +1381,7 @@ static void nvme_instance_init(Object *obj)
} }
static const TypeInfo nvme_info = { static const TypeInfo nvme_info = {
.name = "nvme", .name = TYPE_NVME,
.parent = TYPE_PCI_DEVICE, .parent = TYPE_PCI_DEVICE,
.instance_size = sizeof(NvmeCtrl), .instance_size = sizeof(NvmeCtrl),
.class_init = nvme_class_init, .class_init = nvme_class_init,