@@ -46,8 +46,6 @@ int ide_bus_init_ioport_isa(IDEBus *bus, ISADevice *dev,
{
int ret;
- /* ??? Assume only ISA and PCI configurations, and that the PCI-ISA
- bridge has been setup properly to always register with ISA. */
ret = isa_register_portio_list(dev, &bus->portio_list,
iobase, ide_portio_list, bus, "ide");
@@ -58,3 +56,13 @@ int ide_bus_init_ioport_isa(IDEBus *bus, ISADevice *dev,
return ret;
}
+
+void ide_bus_init_ioport(IDEBus *bus, Object *owner, MemoryRegion *io,
+ int iobase, int iobase2)
+{
+ portio_list_init(&bus->portio_list, owner, ide_portio_list, bus, "ide");
+ portio_list_add(&bus->portio_list, io, iobase);
+
+ portio_list_init(&bus->portio2_list, owner, ide_portio2_list, bus, "ide");
+ portio_list_add(&bus->portio2_list, io, iobase2);
+}
@@ -617,6 +617,8 @@ int ide_init_drive(IDEState *s, BlockBackend *blk, IDEDriveKind kind,
uint32_t cylinders, uint32_t heads, uint32_t secs,
int chs_trans, Error **errp);
void ide_exit(IDEState *s);
+void ide_bus_init_ioport(IDEBus *bus, Object *owner, MemoryRegion *io,
+ int iobase, int iobase2);
void ide_bus_init_output_irq(IDEBus *bus, qemu_irq irq_out);
void ide_bus_set_irq(IDEBus *bus);
void ide_bus_register_restart_cb(IDEBus *bus);