summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/machine/pci-ide.cpp
diff options
context:
space:
mode:
author mooglyguy <therealmogminer@gmail.com>2018-08-15 18:37:51 +0200
committer mooglyguy <therealmogminer@gmail.com>2018-08-15 18:38:07 +0200
commit1db10c9857414d0d8528b86400de08ee67df21f8 (patch)
tree6b9351909184f454f841aad4e870836c799959c6 /src/devices/machine/pci-ide.cpp
parentd0d5aac29b938970a4e85640e2514af8b028e356 (diff)
-amigafdc, at29x, at45dbxx, at_keybc, ataintf, atmel_arm_aic, pci-ide: MCFG removal, nw
Diffstat (limited to 'src/devices/machine/pci-ide.cpp')
-rw-r--r--src/devices/machine/pci-ide.cpp24
1 files changed, 13 insertions, 11 deletions
diff --git a/src/devices/machine/pci-ide.cpp b/src/devices/machine/pci-ide.cpp
index 3b24f4f5964..39d359a2905 100644
--- a/src/devices/machine/pci-ide.cpp
+++ b/src/devices/machine/pci-ide.cpp
@@ -11,7 +11,9 @@ ide_pci_device::ide_pci_device(const machine_config &mconfig, const char *tag, d
m_ide2(*this, "ide2"),
m_irq_handler(*this),
m_legacy_top(0x000),
- m_pif(0x8a)
+ m_pif(0x8a),
+ m_bus_master_tag(":pci:00.0"),
+ m_bus_master_space(AS_DATA)
{
}
@@ -52,16 +54,16 @@ void ide_pci_device::bus_master_map(address_map &map)
map(0x8, 0xf).rw("ide2", FUNC(bus_master_ide_controller_device::bmdma_r), FUNC(bus_master_ide_controller_device::bmdma_w));
}
-MACHINE_CONFIG_START(ide_pci_device::device_add_mconfig)
- MCFG_BUS_MASTER_IDE_CONTROLLER_ADD("ide", ata_devices, "hdd", "cdrom", true)
- MCFG_ATA_INTERFACE_IRQ_HANDLER(WRITELINE(*this, ide_pci_device, ide_interrupt))
- //MCFG_BUS_MASTER_IDE_CONTROLLER_SPACE(":maincpu", AS_PROGRAM)
- MCFG_BUS_MASTER_IDE_CONTROLLER_SPACE(":pci:00.0", AS_DATA)
- MCFG_BUS_MASTER_IDE_CONTROLLER_ADD("ide2", ata_devices, "hdd", "cdrom", true)
- MCFG_ATA_INTERFACE_IRQ_HANDLER(WRITELINE(*this, ide_pci_device, ide_interrupt))
- //MCFG_BUS_MASTER_IDE_CONTROLLER_SPACE(":maincpu", AS_PROGRAM)
- MCFG_BUS_MASTER_IDE_CONTROLLER_SPACE(":pci:00.0", AS_DATA)
-MACHINE_CONFIG_END
+void ide_pci_device::device_add_mconfig(machine_config &config)
+{
+ BUS_MASTER_IDE_CONTROLLER(config, m_ide).options(ata_devices, "hdd", "cdrom", true);
+ m_ide->irq_handler().set(FUNC(ide_pci_device::ide_interrupt));
+ m_ide->set_bus_master_space(m_bus_master_tag, m_bus_master_space);
+
+ BUS_MASTER_IDE_CONTROLLER(config, m_ide2).options(ata_devices, "hdd", "cdrom", true);
+ m_ide2->irq_handler().set(FUNC(ide_pci_device::ide_interrupt));
+ m_ide2->set_bus_master_space(m_bus_master_tag, m_bus_master_space);
+}
void ide_pci_device::device_start()
{