Signed-off-by: Laszlo Ersek <ler...@redhat.com> --- hw/qdev-monitor.h | 3 ++- hw/qdev-monitor.c | 4 ++-- vl.c | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/hw/qdev-monitor.h b/hw/qdev-monitor.h index 9ec4850..3760bf5 100644 --- a/hw/qdev-monitor.h +++ b/hw/qdev-monitor.h @@ -3,6 +3,7 @@ #include "qdev-core.h" #include "monitor/monitor.h" +#include "qapi/error.h" /*** monitor commands ***/ @@ -11,6 +12,6 @@ void do_info_qdm(Monitor *mon, const QDict *qdict); int do_device_add(Monitor *mon, const QDict *qdict, QObject **ret_data); int do_device_del(Monitor *mon, const QDict *qdict, QObject **ret_data); int qdev_device_help(QemuOpts *opts); -DeviceState *qdev_device_add(QemuOpts *opts); +DeviceState *qdev_device_add(QemuOpts *opts, Error **errp); #endif diff --git a/hw/qdev-monitor.c b/hw/qdev-monitor.c index 80fc9f8..a7f73dc 100644 --- a/hw/qdev-monitor.c +++ b/hw/qdev-monitor.c @@ -453,7 +453,7 @@ static BusState *qbus_find(const char *path, Error **errp) } } -DeviceState *qdev_device_add(QemuOpts *opts) +DeviceState *qdev_device_add(QemuOpts *opts, Error **errp) { ObjectClass *obj; DeviceClass *k; @@ -666,7 +666,7 @@ int do_device_add(Monitor *mon, const QDict *qdict, QObject **ret_data) qemu_opts_del(opts); return 0; } - dev = qdev_device_add(opts); + dev = qdev_device_add(opts, NULL); if (!dev) { qemu_opts_del(opts); return -1; diff --git a/vl.c b/vl.c index 059e512..1860662 100644 --- a/vl.c +++ b/vl.c @@ -2280,7 +2280,7 @@ static int device_init_func(QemuOpts *opts, void *opaque) { DeviceState *dev; - dev = qdev_device_add(opts); + dev = qdev_device_add(opts, NULL); if (!dev) return -1; object_unref(OBJECT(dev)); -- 1.7.1