From 7983c8a335dd09fec49f99a44d4404aa87828c0a Mon Sep 17 00:00:00 2001 From: Andreas Färber Date: Wed, 9 Jan 2013 03:58:10 +0100 Subject: qdev: Fold state enum into bool realized MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Whether the device was initialized or not is QOM-level information and currently unused. Drop it from device. This leaves the boolean state of whether or not DeviceClass::init was called or not, a.k.a. "realized". Suggested-by: Anthony Liguori Signed-off-by: Andreas Färber Signed-off-by: Anthony Liguori --- hw/qdev-addr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'hw/qdev-addr.c') diff --git a/hw/qdev-addr.c b/hw/qdev-addr.c index 3bfe101d79..b4388f6a66 100644 --- a/hw/qdev-addr.c +++ b/hw/qdev-addr.c @@ -40,7 +40,7 @@ static void set_taddr(Object *obj, Visitor *v, void *opaque, Error *local_err = NULL; int64_t value; - if (dev->state != DEV_STATE_CREATED) { + if (dev->realized) { error_set(errp, QERR_PERMISSION_DENIED); return; } -- cgit 1.4.1