diff options
Diffstat (limited to 'hw/pci-host/gpex.c')
-rw-r--r-- | hw/pci-host/gpex.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/hw/pci-host/gpex.c b/hw/pci-host/gpex.c index 2583b151a4..1bafffcc34 100644 --- a/hw/pci-host/gpex.c +++ b/hw/pci-host/gpex.c @@ -29,6 +29,7 @@ * http://www.firmware.org/1275/practice/imap/imap0_9d.pdf */ #include "qemu/osdep.h" +#include "qapi/error.h" #include "hw/hw.h" #include "hw/pci-host/gpex.h" @@ -120,8 +121,8 @@ static void gpex_host_initfn(Object *obj) GPEXHost *s = GPEX_HOST(obj); GPEXRootState *root = &s->gpex_root; - object_initialize(root, sizeof(*root), TYPE_GPEX_ROOT_DEVICE); - object_property_add_child(obj, "gpex_root", OBJECT(root), NULL); + object_initialize_child(obj, "gpex_root", root, sizeof(*root), + TYPE_GPEX_ROOT_DEVICE, &error_abort, NULL); qdev_prop_set_int32(DEVICE(root), "addr", PCI_DEVFN(0, 0)); qdev_prop_set_bit(DEVICE(root), "multifunction", false); } |