mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 17:23:56 -06:00
mac_via: move ADB variables to MOS6522Q800VIA1State
The ADB is accessed using clock and data pins on q800 VIA1 port B and so can be moved to MOS6522Q800VIA1State. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Reviewed-by: Laurent Vivier <laurent@vivier.eu> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20210830102447.10806-6-mark.cave-ayland@ilande.co.uk> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
This commit is contained in:
parent
741258b06c
commit
5f083d4224
3 changed files with 96 additions and 99 deletions
|
@ -225,7 +225,7 @@ static void q800_init(MachineState *machine)
|
|||
hwaddr parameters_base;
|
||||
CPUState *cs;
|
||||
DeviceState *dev;
|
||||
DeviceState *via_dev;
|
||||
DeviceState *via_dev, *via1_dev;
|
||||
DeviceState *escc_orgate;
|
||||
SysBusESPState *sysbus_esp;
|
||||
ESPState *esp;
|
||||
|
@ -285,8 +285,8 @@ static void q800_init(MachineState *machine)
|
|||
qdev_connect_gpio_out_named(DEVICE(sysbus), "irq", 1,
|
||||
qdev_get_gpio_in(glue, 1));
|
||||
|
||||
|
||||
adb_bus = qdev_get_child_bus(via_dev, "adb.0");
|
||||
via1_dev = DEVICE(MOS6522_Q800_VIA1(&MAC_VIA(via_dev)->mos6522_via1));
|
||||
adb_bus = qdev_get_child_bus(DEVICE(via1_dev), "adb.0");
|
||||
dev = qdev_new(TYPE_ADB_KEYBOARD);
|
||||
qdev_realize_and_unref(dev, adb_bus, &error_fatal);
|
||||
dev = qdev_new(TYPE_ADB_MOUSE);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue