diff options
Diffstat (limited to 'hw/pl181.c')
-rw-r--r-- | hw/pl181.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/hw/pl181.c b/hw/pl181.c index 973d3fcf0e..ae636e220e 100644 --- a/hw/pl181.c +++ b/hw/pl181.c @@ -490,22 +490,24 @@ static int pl181_init(SysBusDevice *dev) static void pl181_class_init(ObjectClass *klass, void *data) { SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass); + DeviceClass *k = DEVICE_CLASS(klass); sdc->init = pl181_init; + k->vmsd = &vmstate_pl181; + k->reset = pl181_reset; + k->no_user = 1; } -static DeviceInfo pl181_info = { - .name = "pl181", - .size = sizeof(pl181_state), - .class_init = pl181_class_init, - .vmsd = &vmstate_pl181, - .reset = pl181_reset, - .no_user = 1, +static TypeInfo pl181_info = { + .name = "pl181", + .parent = TYPE_SYS_BUS_DEVICE, + .instance_size = sizeof(pl181_state), + .class_init = pl181_class_init, }; static void pl181_register_devices(void) { - sysbus_qdev_register(&pl181_info); + type_register_static(&pl181_info); } device_init(pl181_register_devices) |