aboutsummaryrefslogtreecommitdiff
path: root/hw/misc/pci-testdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/misc/pci-testdev.c')
-rw-r--r--hw/misc/pci-testdev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/misc/pci-testdev.c b/hw/misc/pci-testdev.c
index fb9a58c..8b0b73f 100644
--- a/hw/misc/pci-testdev.c
+++ b/hw/misc/pci-testdev.c
@@ -236,9 +236,9 @@ static int pci_testdev_init(PCIDevice *pci_dev)
pci_conf[PCI_INTERRUPT_PIN] = 0; /* no interrupt pin */
- memory_region_init_io(&d->mmio, NULL, &pci_testdev_mmio_ops, d,
+ memory_region_init_io(&d->mmio, OBJECT(d), &pci_testdev_mmio_ops, d,
"pci-testdev-mmio", IOTEST_MEMSIZE * 2);
- memory_region_init_io(&d->portio, NULL, &pci_testdev_pio_ops, d,
+ memory_region_init_io(&d->portio, OBJECT(d), &pci_testdev_pio_ops, d,
"pci-testdev-portio", IOTEST_IOSIZE * 2);
pci_register_bar(&d->dev, 0, PCI_BASE_ADDRESS_SPACE_MEMORY, &d->mmio);
pci_register_bar(&d->dev, 1, PCI_BASE_ADDRESS_SPACE_IO, &d->portio);