mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 09:43:56 -06:00
i8254: QOM'ify some more
Introduce type constant and avoid DO_UPCAST(). Prepares for PIT realizefn. Signed-off-by: Andreas Färber <afaerber@suse.de>
This commit is contained in:
parent
db895a1e6a
commit
3afe7e14a4
2 changed files with 13 additions and 9 deletions
|
@ -265,7 +265,7 @@ static void pit_irq_timer(void *opaque)
|
|||
|
||||
static void pit_reset(DeviceState *dev)
|
||||
{
|
||||
PITCommonState *pit = DO_UPCAST(PITCommonState, dev.qdev, dev);
|
||||
PITCommonState *pit = PIT_COMMON(dev);
|
||||
PITChannelState *s;
|
||||
|
||||
pit_reset_common(pit);
|
||||
|
@ -348,7 +348,7 @@ static void pit_class_initfn(ObjectClass *klass, void *data)
|
|||
}
|
||||
|
||||
static const TypeInfo pit_info = {
|
||||
.name = "isa-pit",
|
||||
.name = TYPE_I8254,
|
||||
.parent = TYPE_PIT_COMMON,
|
||||
.instance_size = sizeof(PITCommonState),
|
||||
.class_init = pit_class_initfn,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue