summaryrefslogtreecommitdiff
path: root/hw/char/pl011.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/char/pl011.c')
-rw-r--r--hw/char/pl011.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/hw/char/pl011.c b/hw/char/pl011.c
index 0a451150e5..eac6fac093 100644
--- a/hw/char/pl011.c
+++ b/hw/char/pl011.c
@@ -293,6 +293,7 @@ static void pl011_realize(DeviceState *dev, Error **errp)
{
PL011State *s = PL011(dev);
+ /* FIXME use a qdev chardev prop instead of qemu_char_get_next_serial() */
s->chr = qemu_char_get_next_serial();
if (s->chr) {
@@ -307,6 +308,8 @@ static void pl011_class_init(ObjectClass *oc, void *data)
dc->realize = pl011_realize;
dc->vmsd = &vmstate_pl011;
+ /* Reason: realize() method uses qemu_char_get_next_serial() */
+ dc->cannot_instantiate_with_device_add_yet = true;
}
static const TypeInfo pl011_arm_info = {