diff options
author | Olivier Galibert <galibert@pobox.com> | 2018-04-19 21:45:12 +0200 |
---|---|---|
committer | Olivier Galibert <galibert@pobox.com> | 2018-04-19 23:04:31 +0200 |
commit | c6c737de5933cef418e64198d7865d8c8f1cd775 (patch) | |
tree | 361afcd3cec4811b297e291e28d83e0e1d70ba29 | |
parent | 47ccf152b24557040b593c60ccf7896da88726a0 (diff) |
maps: Finish mame/machine (nw)
-rw-r--r-- | src/mame/machine/abc1600mac.cpp | 5 | ||||
-rw-r--r-- | src/mame/machine/apricotkb.cpp | 19 | ||||
-rw-r--r-- | src/mame/machine/cammu.cpp | 96 | ||||
-rw-r--r-- | src/mame/machine/fd1089.cpp | 7 | ||||
-rw-r--r-- | src/mame/machine/interpro_ioga.cpp | 24 | ||||
-rw-r--r-- | src/mame/machine/iteagle_fpga.cpp | 37 | ||||
-rw-r--r-- | src/mame/machine/mega32x.cpp | 78 | ||||
-rw-r--r-- | src/mame/machine/megadriv.cpp | 9 | ||||
-rw-r--r-- | src/mame/machine/namco_c139.cpp | 7 | ||||
-rw-r--r-- | src/mame/machine/naomim1.cpp | 9 | ||||
-rw-r--r-- | src/mame/machine/naomim4.cpp | 9 | ||||
-rw-r--r-- | src/mame/machine/prof80mmu.cpp | 5 | ||||
-rw-r--r-- | src/mame/machine/segabb.cpp | 15 | ||||
-rw-r--r-- | src/mame/machine/seicop.cpp | 23 | ||||
-rw-r--r-- | src/mame/machine/st0016.cpp | 36 | ||||
-rw-r--r-- | src/mame/machine/xbox_pci.cpp | 107 |
16 files changed, 263 insertions, 223 deletions
diff --git a/src/mame/machine/abc1600mac.cpp b/src/mame/machine/abc1600mac.cpp index 18591c6428c..cd546fc1229 100644 --- a/src/mame/machine/abc1600mac.cpp +++ b/src/mame/machine/abc1600mac.cpp @@ -63,8 +63,9 @@ void abc1600_mac_device::map(address_map &map) } -ADDRESS_MAP_START(abc1600_mac_device::program_map) -ADDRESS_MAP_END +void abc1600_mac_device::program_map(address_map &map) +{ +} MACHINE_CONFIG_START(abc1600_mac_device::device_add_mconfig) diff --git a/src/mame/machine/apricotkb.cpp b/src/mame/machine/apricotkb.cpp index dd96ff8430e..e3dd5d20d83 100644 --- a/src/mame/machine/apricotkb.cpp +++ b/src/mame/machine/apricotkb.cpp @@ -51,15 +51,16 @@ const tiny_rom_entry *apricot_keyboard_device::device_rom_region() const //------------------------------------------------- #ifdef UPD7507_EMULATED -ADDRESS_MAP_START(apricot_keyboard_device::apricot_keyboard_io) - AM_RANGE(0x00, 0x00) AM_READ(kb_lo_r) - AM_RANGE(0x01, 0x01) AM_READ(kb_hi_r) - AM_RANGE(0x03, 0x03) AM_WRITE(kb_p3_w) - AM_RANGE(0x04, 0x04) AM_WRITE(kb_y0_w) - AM_RANGE(0x05, 0x05) AM_WRITE(kb_y4_w) - AM_RANGE(0x06, 0x06) AM_READWRITE(kb_p6_r, kb_yc_w) - AM_RANGE(0x07, 0x07) AM_WRITE(kb_y8_w) -ADDRESS_MAP_END +void apricot_keyboard_device::apricot_keyboard_io(address_map &map) +{ + map(0x00, 0x00).r(this, FUNC(apricot_keyboard_device::kb_lo_r)); + map(0x01, 0x01).r(this, FUNC(apricot_keyboard_device::kb_hi_r)); + map(0x03, 0x03).w(this, FUNC(apricot_keyboard_device::kb_p3_w)); + map(0x04, 0x04).w(this, FUNC(apricot_keyboard_device::kb_y0_w)); + map(0x05, 0x05).w(this, FUNC(apricot_keyboard_device::kb_y4_w)); + map(0x06, 0x06).rw(this, FUNC(apricot_keyboard_device::kb_p6_r), FUNC(apricot_keyboard_device::kb_yc_w)); + map(0x07, 0x07).w(this, FUNC(apricot_keyboard_device::kb_y8_w)); +} #endif diff --git a/src/mame/machine/cammu.cpp b/src/mame/machine/cammu.cpp index f5922012d27..3a8c0156075 100644 --- a/src/mame/machine/cammu.cpp +++ b/src/mame/machine/cammu.cpp @@ -42,53 +42,55 @@ #include "logmacro.h" // each variant of the cammu has different registers and a different addressing map -ADDRESS_MAP_START(cammu_c4t_device::map) - AM_RANGE(0x008, 0x00b) AM_READWRITE(ram_line_r, ram_line_w) - AM_RANGE(0x010, 0x013) AM_READWRITE(s_pdo_r, s_pdo_w) - AM_RANGE(0x018, 0x01b) AM_READWRITE(u_pdo_r, u_pdo_w) - AM_RANGE(0x020, 0x023) AM_READWRITE(htlb_offset_r, htlb_offset_w) - AM_RANGE(0x028, 0x02b) AM_READWRITE(i_fault_r, i_fault_w) - AM_RANGE(0x030, 0x033) AM_READWRITE(fault_address_1_r, fault_address_1_w) - AM_RANGE(0x038, 0x03b) AM_READWRITE(fault_address_2_r, fault_address_2_w) - AM_RANGE(0x040, 0x043) AM_READWRITE(fault_data_1_lo_r, fault_data_1_lo_w) - AM_RANGE(0x048, 0x04b) AM_READWRITE(fault_data_1_hi_r, fault_data_1_hi_w) - AM_RANGE(0x050, 0x053) AM_READWRITE(fault_data_2_lo_r, fault_data_2_lo_w) - AM_RANGE(0x058, 0x05b) AM_READWRITE(fault_data_2_hi_r, fault_data_2_hi_w) - AM_RANGE(0x060, 0x063) AM_READWRITE(c4_bus_poll_r, c4_bus_poll_w) - AM_RANGE(0x068, 0x06b) AM_READWRITE(control_r, control_w) - AM_RANGE(0x070, 0x073) AM_READWRITE(bio_control_r, bio_control_w) - AM_RANGE(0x078, 0x07b) AM_READWRITE(bio_address_tag_r, bio_address_tag_w) - - AM_RANGE(0x100, 0x103) AM_READWRITE(cache_data_lo_r, cache_data_lo_w) - AM_RANGE(0x104, 0x107) AM_READWRITE(cache_data_hi_r, cache_data_hi_w) - AM_RANGE(0x108, 0x10b) AM_READWRITE(cache_cpu_tag_r, cache_cpu_tag_w) - AM_RANGE(0x10c, 0x10f) AM_READWRITE(cache_system_tag_valid_r, cache_system_tag_valid_w) - AM_RANGE(0x110, 0x113) AM_READWRITE(cache_system_tag_r, cache_system_tag_w) - AM_RANGE(0x118, 0x11b) AM_READWRITE(tlb_va_line_r, tlb_va_line_w) - AM_RANGE(0x11c, 0x11f) AM_READWRITE(tlb_ra_line_r, tlb_ra_line_w) -ADDRESS_MAP_END - -ADDRESS_MAP_START(cammu_c4i_device::map) - AM_RANGE(0x000, 0x003) AM_READWRITE(reset_r, reset_w) - AM_RANGE(0x010, 0x013) AM_READWRITE(s_pdo_r, s_pdo_w) - AM_RANGE(0x018, 0x01b) AM_READWRITE(u_pdo_r, u_pdo_w) - AM_RANGE(0x020, 0x023) AM_READWRITE(clr_s_data_tlb_r, clr_s_data_tlb_w) - AM_RANGE(0x028, 0x02b) AM_READWRITE(clr_u_data_tlb_r, clr_u_data_tlb_w) - AM_RANGE(0x030, 0x033) AM_READWRITE(clr_s_insn_tlb_r, clr_s_insn_tlb_w) - AM_RANGE(0x038, 0x03b) AM_READWRITE(clr_u_insn_tlb_r, clr_u_insn_tlb_w) - - AM_RANGE(0x068, 0x06b) AM_READWRITE(control_r, control_w) - - AM_RANGE(0x080, 0x083) AM_READWRITE(test_data_r, test_data_w) - AM_RANGE(0x088, 0x08b) AM_READWRITE(i_fault_r, i_fault_w) - AM_RANGE(0x090, 0x093) AM_READWRITE(fault_address_1_r, fault_address_1_w) - AM_RANGE(0x098, 0x09b) AM_READWRITE(fault_address_2_r, fault_address_2_w) - AM_RANGE(0x0a0, 0x0a3) AM_READWRITE(fault_data_1_lo_r, fault_data_1_lo_w) - AM_RANGE(0x0a8, 0x0ab) AM_READWRITE(fault_data_1_hi_r, fault_data_1_hi_w) - AM_RANGE(0x0b0, 0x0b3) AM_READWRITE(fault_data_2_lo_r, fault_data_2_lo_w) - AM_RANGE(0x0b8, 0x0bb) AM_READWRITE(fault_data_2_hi_r, fault_data_2_hi_w) - AM_RANGE(0x0c0, 0x0c3) AM_READWRITE(test_address_r, test_address_w) -ADDRESS_MAP_END +void cammu_c4t_device::map(address_map &map) +{ + map(0x008, 0x00b).rw(this, FUNC(cammu_c4t_device::ram_line_r), FUNC(cammu_c4t_device::ram_line_w)); + map(0x010, 0x013).rw(this, FUNC(cammu_c4t_device::s_pdo_r), FUNC(cammu_c4t_device::s_pdo_w)); + map(0x018, 0x01b).rw(this, FUNC(cammu_c4t_device::u_pdo_r), FUNC(cammu_c4t_device::u_pdo_w)); + map(0x020, 0x023).rw(this, FUNC(cammu_c4t_device::htlb_offset_r), FUNC(cammu_c4t_device::htlb_offset_w)); + map(0x028, 0x02b).rw(this, FUNC(cammu_c4t_device::i_fault_r), FUNC(cammu_c4t_device::i_fault_w)); + map(0x030, 0x033).rw(this, FUNC(cammu_c4t_device::fault_address_1_r), FUNC(cammu_c4t_device::fault_address_1_w)); + map(0x038, 0x03b).rw(this, FUNC(cammu_c4t_device::fault_address_2_r), FUNC(cammu_c4t_device::fault_address_2_w)); + map(0x040, 0x043).rw(this, FUNC(cammu_c4t_device::fault_data_1_lo_r), FUNC(cammu_c4t_device::fault_data_1_lo_w)); + map(0x048, 0x04b).rw(this, FUNC(cammu_c4t_device::fault_data_1_hi_r), FUNC(cammu_c4t_device::fault_data_1_hi_w)); + map(0x050, 0x053).rw(this, FUNC(cammu_c4t_device::fault_data_2_lo_r), FUNC(cammu_c4t_device::fault_data_2_lo_w)); + map(0x058, 0x05b).rw(this, FUNC(cammu_c4t_device::fault_data_2_hi_r), FUNC(cammu_c4t_device::fault_data_2_hi_w)); + map(0x060, 0x063).rw(this, FUNC(cammu_c4t_device::c4_bus_poll_r), FUNC(cammu_c4t_device::c4_bus_poll_w)); + map(0x068, 0x06b).rw(this, FUNC(cammu_c4t_device::control_r), FUNC(cammu_c4t_device::control_w)); + map(0x070, 0x073).rw(this, FUNC(cammu_c4t_device::bio_control_r), FUNC(cammu_c4t_device::bio_control_w)); + map(0x078, 0x07b).rw(this, FUNC(cammu_c4t_device::bio_address_tag_r), FUNC(cammu_c4t_device::bio_address_tag_w)); + + map(0x100, 0x103).rw(this, FUNC(cammu_c4t_device::cache_data_lo_r), FUNC(cammu_c4t_device::cache_data_lo_w)); + map(0x104, 0x107).rw(this, FUNC(cammu_c4t_device::cache_data_hi_r), FUNC(cammu_c4t_device::cache_data_hi_w)); + map(0x108, 0x10b).rw(this, FUNC(cammu_c4t_device::cache_cpu_tag_r), FUNC(cammu_c4t_device::cache_cpu_tag_w)); + map(0x10c, 0x10f).rw(this, FUNC(cammu_c4t_device::cache_system_tag_valid_r), FUNC(cammu_c4t_device::cache_system_tag_valid_w)); + map(0x110, 0x113).rw(this, FUNC(cammu_c4t_device::cache_system_tag_r), FUNC(cammu_c4t_device::cache_system_tag_w)); + map(0x118, 0x11b).rw(this, FUNC(cammu_c4t_device::tlb_va_line_r), FUNC(cammu_c4t_device::tlb_va_line_w)); + map(0x11c, 0x11f).rw(this, FUNC(cammu_c4t_device::tlb_ra_line_r), FUNC(cammu_c4t_device::tlb_ra_line_w)); +} + +void cammu_c4i_device::map(address_map &map) +{ + map(0x000, 0x003).rw(this, FUNC(cammu_c4i_device::reset_r), FUNC(cammu_c4i_device::reset_w)); + map(0x010, 0x013).rw(this, FUNC(cammu_c4i_device::s_pdo_r), FUNC(cammu_c4i_device::s_pdo_w)); + map(0x018, 0x01b).rw(this, FUNC(cammu_c4i_device::u_pdo_r), FUNC(cammu_c4i_device::u_pdo_w)); + map(0x020, 0x023).rw(this, FUNC(cammu_c4i_device::clr_s_data_tlb_r), FUNC(cammu_c4i_device::clr_s_data_tlb_w)); + map(0x028, 0x02b).rw(this, FUNC(cammu_c4i_device::clr_u_data_tlb_r), FUNC(cammu_c4i_device::clr_u_data_tlb_w)); + map(0x030, 0x033).rw(this, FUNC(cammu_c4i_device::clr_s_insn_tlb_r), FUNC(cammu_c4i_device::clr_s_insn_tlb_w)); + map(0x038, 0x03b).rw(this, FUNC(cammu_c4i_device::clr_u_insn_tlb_r), FUNC(cammu_c4i_device::clr_u_insn_tlb_w)); + + map(0x068, 0x06b).rw(this, FUNC(cammu_c4i_device::control_r), FUNC(cammu_c4i_device::control_w)); + + map(0x080, 0x083).rw(this, FUNC(cammu_c4i_device::test_data_r), FUNC(cammu_c4i_device::test_data_w)); + map(0x088, 0x08b).rw(this, FUNC(cammu_c4i_device::i_fault_r), FUNC(cammu_c4i_device::i_fault_w)); + map(0x090, 0x093).rw(this, FUNC(cammu_c4i_device::fault_address_1_r), FUNC(cammu_c4i_device::fault_address_1_w)); + map(0x098, 0x09b).rw(this, FUNC(cammu_c4i_device::fault_address_2_r), FUNC(cammu_c4i_device::fault_address_2_w)); + map(0x0a0, 0x0a3).rw(this, FUNC(cammu_c4i_device::fault_data_1_lo_r), FUNC(cammu_c4i_device::fault_data_1_lo_w)); + map(0x0a8, 0x0ab).rw(this, FUNC(cammu_c4i_device::fault_data_1_hi_r), FUNC(cammu_c4i_device::fault_data_1_hi_w)); + map(0x0b0, 0x0b3).rw(this, FUNC(cammu_c4i_device::fault_data_2_lo_r), FUNC(cammu_c4i_device::fault_data_2_lo_w)); + map(0x0b8, 0x0bb).rw(this, FUNC(cammu_c4i_device::fault_data_2_hi_r), FUNC(cammu_c4i_device::fault_data_2_hi_w)); + map(0x0c0, 0x0c3).rw(this, FUNC(cammu_c4i_device::test_address_r), FUNC(cammu_c4i_device::test_address_w)); +} void cammu_c3_device::map(address_map &map) { diff --git a/src/mame/machine/fd1089.cpp b/src/mame/machine/fd1089.cpp index e7318a3de61..286391d458e 100644 --- a/src/mame/machine/fd1089.cpp +++ b/src/mame/machine/fd1089.cpp @@ -208,9 +208,10 @@ const fd1089_base_device::decrypt_parameters fd1089_base_device::s_data_params_a { 0xac, 1,6,3,5,0,7,4,2 }, }; -ADDRESS_MAP_START(fd1089_base_device::decrypted_opcodes_map) - AM_RANGE(0x00000, 0xfffff) AM_ROM AM_SHARE(":fd1089_decrypted_opcodes") -ADDRESS_MAP_END +void fd1089_base_device::decrypted_opcodes_map(address_map &map) +{ + map(0x00000, 0xfffff).rom().share(":fd1089_decrypted_opcodes"); +} //************************************************************************** diff --git a/src/mame/machine/interpro_ioga.cpp b/src/mame/machine/interpro_ioga.cpp index 548a568e1d2..25af9add1c1 100644 --- a/src/mame/machine/interpro_ioga.cpp +++ b/src/mame/machine/interpro_ioga.cpp @@ -135,20 +135,22 @@ void interpro_ioga_device::map(address_map &map) //c0, c4, c8 -ethernet address a,b,c? } -ADDRESS_MAP_START(turquoise_ioga_device::map) - AM_IMPORT_FROM(interpro_ioga_device::map) +void turquoise_ioga_device::map(address_map &map) +{ + interpro_ioga_device::map(map); - AM_RANGE(0x00, 0x03) AM_READWRITE(eth_base_r, eth_base_w) - AM_RANGE(0x04, 0x07) AM_READWRITE16(eth_control_r, eth_control_w, 0xffff) -ADDRESS_MAP_END + map(0x00, 0x03).rw(this, FUNC(turquoise_ioga_device::eth_base_r), FUNC(turquoise_ioga_device::eth_base_w)); + map(0x04, 0x05).rw(this, FUNC(turquoise_ioga_device::eth_control_r), FUNC(turquoise_ioga_device::eth_control_w)); +} -ADDRESS_MAP_START(sapphire_ioga_device::map) - AM_IMPORT_FROM(interpro_ioga_device::map) +void sapphire_ioga_device::map(address_map &map) +{ + interpro_ioga_device::map(map); - AM_RANGE(0x00, 0x03) AM_READWRITE(eth_remap_r, eth_remap_w) - AM_RANGE(0x04, 0x07) AM_READWRITE(eth_mappg_r, eth_mappg_w) - AM_RANGE(0x08, 0x0b) AM_READWRITE(eth_control_r, eth_control_w) -ADDRESS_MAP_END + map(0x00, 0x03).rw(this, FUNC(sapphire_ioga_device::eth_remap_r), FUNC(sapphire_ioga_device::eth_remap_w)); + map(0x04, 0x07).rw(this, FUNC(sapphire_ioga_device::eth_mappg_r), FUNC(sapphire_ioga_device::eth_mappg_w)); + map(0x08, 0x0b).rw(this, FUNC(sapphire_ioga_device::eth_control_r), FUNC(sapphire_ioga_device::eth_control_w)); +} static INPUT_PORTS_START(interpro_mouse) PORT_START("mouse_buttons") diff --git a/src/mame/machine/iteagle_fpga.cpp b/src/mame/machine/iteagle_fpga.cpp index 81aeec15293..2df0987eabf 100644 --- a/src/mame/machine/iteagle_fpga.cpp +++ b/src/mame/machine/iteagle_fpga.cpp @@ -17,18 +17,21 @@ DEFINE_DEVICE_TYPE(ITEAGLE_FPGA, iteagle_fpga_device, "iteagle_fpga", "ITEagle FPGA") -ADDRESS_MAP_START(iteagle_fpga_device::fpga_map) - AM_RANGE(0x000, 0x01f) AM_READWRITE(fpga_r, fpga_w) -ADDRESS_MAP_END +void iteagle_fpga_device::fpga_map(address_map &map) +{ + map(0x000, 0x01f).rw(this, FUNC(iteagle_fpga_device::fpga_r), FUNC(iteagle_fpga_device::fpga_w)); +} -ADDRESS_MAP_START(iteagle_fpga_device::rtc_map) - AM_RANGE(0x000, 0x7ff) AM_READWRITE(rtc_r, rtc_w) -ADDRESS_MAP_END +void iteagle_fpga_device::rtc_map(address_map &map) +{ + map(0x000, 0x7ff).rw(this, FUNC(iteagle_fpga_device::rtc_r), FUNC(iteagle_fpga_device::rtc_w)); +} -ADDRESS_MAP_START(iteagle_fpga_device::ram_map) - AM_RANGE(0x00000, 0x3f) AM_READWRITE(e1_nvram_r, e1_nvram_w) - AM_RANGE(0x10000, 0x1ffff) AM_READWRITE(e1_ram_r, e1_ram_w) -ADDRESS_MAP_END +void iteagle_fpga_device::ram_map(address_map &map) +{ + map(0x00000, 0x3f).rw(this, FUNC(iteagle_fpga_device::e1_nvram_r), FUNC(iteagle_fpga_device::e1_nvram_w)); + map(0x10000, 0x1ffff).rw(this, FUNC(iteagle_fpga_device::e1_ram_r), FUNC(iteagle_fpga_device::e1_ram_w)); +} iteagle_fpga_device::iteagle_fpga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, ITEAGLE_FPGA, tag, owner, clock), @@ -643,9 +646,10 @@ WRITE32_MEMBER( iteagle_fpga_device::e1_ram_w ) DEFINE_DEVICE_TYPE(ITEAGLE_EEPROM, iteagle_eeprom_device, "iteagle_eeprom", "ITEagle EEPROM AT93C46") -ADDRESS_MAP_START(iteagle_eeprom_device::eeprom_map) - AM_RANGE(0x0000, 0x000F) AM_READWRITE(eeprom_r, eeprom_w) -ADDRESS_MAP_END +void iteagle_eeprom_device::eeprom_map(address_map &map) +{ + map(0x0000, 0x000F).rw(this, FUNC(iteagle_eeprom_device::eeprom_r), FUNC(iteagle_eeprom_device::eeprom_w)); +} MACHINE_CONFIG_START(iteagle_eeprom_device::device_add_mconfig) MCFG_EEPROM_SERIAL_93C46_ADD("eeprom") @@ -767,9 +771,10 @@ MACHINE_CONFIG_END DEFINE_DEVICE_TYPE(ITEAGLE_PERIPH, iteagle_periph_device, "iteagle_periph", "ITEagle Peripheral Controller") -ADDRESS_MAP_START(iteagle_periph_device::ctrl_map) - AM_RANGE(0x000, 0x0cf) AM_READWRITE(ctrl_r, ctrl_w) -ADDRESS_MAP_END +void iteagle_periph_device::ctrl_map(address_map &map) +{ + map(0x000, 0x0cf).rw(this, FUNC(iteagle_periph_device::ctrl_r), FUNC(iteagle_periph_device::ctrl_w)); +} iteagle_periph_device::iteagle_periph_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, ITEAGLE_PERIPH, tag, owner, clock), diff --git a/src/mame/machine/mega32x.cpp b/src/mame/machine/mega32x.cpp index 91f6a66ebb8..402aff23d58 100644 --- a/src/mame/machine/mega32x.cpp +++ b/src/mame/machine/mega32x.cpp @@ -1492,63 +1492,65 @@ _32X_MAP_WRITEHANDLERS(slave_401c,slave_401e) // _32x_sh2_slave_401c_slave_401e_ // SH2 memory maps /**********************************************************************************************/ -ADDRESS_MAP_START(sega_32x_device::sh2_main_map) - AM_RANGE(0x00000000, 0x00003fff) AM_ROMBANK("masterbios") +void sega_32x_device::sh2_main_map(address_map &map) +{ + map(0x00000000, 0x00003fff).bankr("masterbios"); - AM_RANGE(0x00004000, 0x00004003) AM_READWRITE(_32x_sh2_master_4000_common_4002_r, _32x_sh2_master_4000_common_4002_w ) - AM_RANGE(0x00004004, 0x00004007) AM_READWRITE(_32x_sh2_common_4004_common_4006_r, _32x_sh2_common_4004_common_4006_w) + map(0x00004000, 0x00004003).rw(this, FUNC(sega_32x_device::_32x_sh2_master_4000_common_4002_r), FUNC(sega_32x_device::_32x_sh2_master_4000_common_4002_w)); + map(0x00004004, 0x00004007).rw(this, FUNC(sega_32x_device::_32x_sh2_common_4004_common_4006_r), FUNC(sega_32x_device::_32x_sh2_common_4004_common_4006_w)); - AM_RANGE(0x00004008, 0x00004013) AM_READWRITE16(_32x_dreq_common_r, _32x_dreq_common_w, 0xffffffff ) + map(0x00004008, 0x00004013).rw(this, FUNC(sega_32x_device::_32x_dreq_common_r), FUNC(sega_32x_device::_32x_dreq_common_w)); - AM_RANGE(0x00004014, 0x00004017) AM_READNOP AM_WRITE(_32x_sh2_master_4014_master_4016_w ) // IRQ clear - AM_RANGE(0x00004018, 0x0000401b) AM_READNOP AM_WRITE(_32x_sh2_master_4018_master_401a_w ) // IRQ clear - AM_RANGE(0x0000401c, 0x0000401f) AM_READNOP AM_WRITE(_32x_sh2_master_401c_master_401e_w ) // IRQ clear + map(0x00004014, 0x00004017).nopr().w(this, FUNC(sega_32x_device::_32x_sh2_master_4014_master_4016_w)); // IRQ clear + map(0x00004018, 0x0000401b).nopr().w(this, FUNC(sega_32x_device::_32x_sh2_master_4018_master_401a_w)); // IRQ clear + map(0x0000401c, 0x0000401f).nopr().w(this, FUNC(sega_32x_device::_32x_sh2_master_401c_master_401e_w)); // IRQ clear - AM_RANGE(0x00004020, 0x0000402f) AM_READWRITE16(_32x_68k_m_commsram_r, _32x_68k_m_commsram_w, 0xffffffff ) - AM_RANGE(0x00004030, 0x0000403f) AM_READWRITE16(_32x_pwm_r, _32x_pwm_w, 0xffffffff ) + map(0x00004020, 0x0000402f).rw(this, FUNC(sega_32x_device::_32x_68k_m_commsram_r), FUNC(sega_32x_device::_32x_68k_m_commsram_w)); + map(0x00004030, 0x0000403f).rw(this, FUNC(sega_32x_device::_32x_pwm_r), FUNC(sega_32x_device::_32x_pwm_w)); - AM_RANGE(0x00004100, 0x0000410b) AM_READWRITE16(_32x_common_vdp_regs_r, _32x_common_vdp_regs_w , 0xffffffff) - AM_RANGE(0x00004200, 0x000043ff) AM_READWRITE16(_32x_68k_palette_r, _32x_68k_palette_w, 0xffffffff) + map(0x00004100, 0x0000410b).rw(this, FUNC(sega_32x_device::_32x_common_vdp_regs_r), FUNC(sega_32x_device::_32x_common_vdp_regs_w)); + map(0x00004200, 0x000043ff).rw(this, FUNC(sega_32x_device::_32x_68k_palette_r), FUNC(sega_32x_device::_32x_68k_palette_w)); - AM_RANGE(0x04000000, 0x0401ffff) AM_READWRITE16(_32x_68k_dram_r, _32x_68k_dram_w, 0xffffffff) - AM_RANGE(0x04020000, 0x0403ffff) AM_READWRITE16(_32x_68k_dram_overwrite_r, _32x_68k_dram_overwrite_w, 0xffffffff) + map(0x04000000, 0x0401ffff).rw(this, FUNC(sega_32x_device::_32x_68k_dram_r), FUNC(sega_32x_device::_32x_68k_dram_w)); + map(0x04020000, 0x0403ffff).rw(this, FUNC(sega_32x_device::_32x_68k_dram_overwrite_r), FUNC(sega_32x_device::_32x_68k_dram_overwrite_w)); - AM_RANGE(0x06000000, 0x0603ffff) AM_RAM AM_SHARE("sh2_shared") - AM_RANGE(0x02000000, 0x023fffff) AM_ROM AM_REGION(":gamecart_sh2", 0) // program is writeable (wwfraw) + map(0x06000000, 0x0603ffff).ram().share("sh2_shared"); + map(0x02000000, 0x023fffff).rom().region(":gamecart_sh2", 0); // program is writeable (wwfraw) - AM_RANGE(0x22000000, 0x223fffff) AM_ROM AM_REGION(":gamecart_sh2", 0) // cart mirror (fifa96) + map(0x22000000, 0x223fffff).rom().region(":gamecart_sh2", 0); // cart mirror (fifa96) - AM_RANGE(0xc0000000, 0xc0000fff) AM_RAM -ADDRESS_MAP_END + map(0xc0000000, 0xc0000fff).ram(); +} -ADDRESS_MAP_START(sega_32x_device::sh2_slave_map) - AM_RANGE(0x00000000, 0x00003fff) AM_ROMBANK("slavebios") +void sega_32x_device::sh2_slave_map(address_map &map) +{ + map(0x00000000, 0x00003fff).bankr("slavebios"); - AM_RANGE(0x00004000, 0x00004003) AM_READWRITE(_32x_sh2_slave_4000_common_4002_r, _32x_sh2_slave_4000_common_4002_w ) - AM_RANGE(0x00004004, 0x00004007) AM_READWRITE(_32x_sh2_common_4004_common_4006_r, _32x_sh2_common_4004_common_4006_w) + map(0x00004000, 0x00004003).rw(this, FUNC(sega_32x_device::_32x_sh2_slave_4000_common_4002_r), FUNC(sega_32x_device::_32x_sh2_slave_4000_common_4002_w)); + map(0x00004004, 0x00004007).rw(this, FUNC(sega_32x_device::_32x_sh2_common_4004_common_4006_r), FUNC(sega_32x_device::_32x_sh2_common_4004_common_4006_w)); - AM_RANGE(0x00004008, 0x00004013) AM_READWRITE16(_32x_dreq_common_r, _32x_dreq_common_w, 0xffffffff ) + map(0x00004008, 0x00004013).rw(this, FUNC(sega_32x_device::_32x_dreq_common_r), FUNC(sega_32x_device::_32x_dreq_common_w)); - AM_RANGE(0x00004014, 0x00004017) AM_READNOP AM_WRITE(_32x_sh2_slave_4014_slave_4016_w ) // IRQ clear - AM_RANGE(0x00004018, 0x0000401b) AM_READNOP AM_WRITE(_32x_sh2_slave_4018_slave_401a_w ) // IRQ clear - AM_RANGE(0x0000401c, 0x0000401f) AM_READNOP AM_WRITE(_32x_sh2_slave_401c_slave_401e_w ) // IRQ clear + map(0x00004014, 0x00004017).nopr().w(this, FUNC(sega_32x_device::_32x_sh2_slave_4014_slave_4016_w)); // IRQ clear + map(0x00004018, 0x0000401b).nopr().w(this, FUNC(sega_32x_device::_32x_sh2_slave_4018_slave_401a_w)); // IRQ clear + map(0x0000401c, 0x0000401f).nopr().w(this, FUNC(sega_32x_device::_32x_sh2_slave_401c_slave_401e_w)); // IRQ clear - AM_RANGE(0x00004020, 0x0000402f) AM_READWRITE16(_32x_68k_m_commsram_r, _32x_68k_m_commsram_w, 0xffffffff ) - AM_RANGE(0x00004030, 0x0000403f) AM_READWRITE16(_32x_pwm_r, _32x_pwm_w, 0xffffffff ) + map(0x00004020, 0x0000402f).rw(this, FUNC(sega_32x_device::_32x_68k_m_commsram_r), FUNC(sega_32x_device::_32x_68k_m_commsram_w)); + map(0x00004030, 0x0000403f).rw(this, FUNC(sega_32x_device::_32x_pwm_r), FUNC(sega_32x_device::_32x_pwm_w)); - AM_RANGE(0x00004100, 0x0000410b) AM_READWRITE16(_32x_common_vdp_regs_r, _32x_common_vdp_regs_w , 0xffffffff) - AM_RANGE(0x00004200, 0x000043ff) AM_READWRITE16(_32x_68k_palette_r, _32x_68k_palette_w, 0xffffffff) + map(0x00004100, 0x0000410b).rw(this, FUNC(sega_32x_device::_32x_common_vdp_regs_r), FUNC(sega_32x_device::_32x_common_vdp_regs_w)); + map(0x00004200, 0x000043ff).rw(this, FUNC(sega_32x_device::_32x_68k_palette_r), FUNC(sega_32x_device::_32x_68k_palette_w)); - AM_RANGE(0x04000000, 0x0401ffff) AM_READWRITE16(_32x_68k_dram_r, _32x_68k_dram_w, 0xffffffff) - AM_RANGE(0x04020000, 0x0403ffff) AM_READWRITE16(_32x_68k_dram_overwrite_r, _32x_68k_dram_overwrite_w, 0xffffffff) + map(0x04000000, 0x0401ffff).rw(this, FUNC(sega_32x_device::_32x_68k_dram_r), FUNC(sega_32x_device::_32x_68k_dram_w)); + map(0x04020000, 0x0403ffff).rw(this, FUNC(sega_32x_device::_32x_68k_dram_overwrite_r), FUNC(sega_32x_device::_32x_68k_dram_overwrite_w)); - AM_RANGE(0x06000000, 0x0603ffff) AM_RAM AM_SHARE("sh2_shared") - AM_RANGE(0x02000000, 0x023fffff) AM_ROM AM_REGION(":gamecart_sh2", 0) // program is writeable (wwfraw) + map(0x06000000, 0x0603ffff).ram().share("sh2_shared"); + map(0x02000000, 0x023fffff).rom().region(":gamecart_sh2", 0); // program is writeable (wwfraw) - AM_RANGE(0x22000000, 0x223fffff) AM_ROM AM_REGION(":gamecart_sh2", 0) // cart mirror (fifa96) + map(0x22000000, 0x223fffff).rom().region(":gamecart_sh2", 0); // cart mirror (fifa96) - AM_RANGE(0xc0000000, 0xc0000fff) AM_RAM -ADDRESS_MAP_END + map(0xc0000000, 0xc0000fff).ram(); +} /****************************************** END 32X related *************************************/ diff --git a/src/mame/machine/megadriv.cpp b/src/mame/machine/megadriv.cpp index 2ebef72e48f..9eb0ea259c4 100644 --- a/src/mame/machine/megadriv.cpp +++ b/src/mame/machine/megadriv.cpp @@ -468,10 +468,11 @@ void md_base_state::megadriv_map(address_map &map) } -ADDRESS_MAP_START(md_base_state::dcat16_megadriv_map) - AM_IMPORT_FROM(megadriv_map) - AM_RANGE(0x000000, 0x7fffff) AM_ROM -ADDRESS_MAP_END +void md_base_state::dcat16_megadriv_map(address_map &map) +{ + megadriv_map(map); + map(0x000000, 0x7fffff).rom(); +} /* z80 sounds/sub CPU */ diff --git a/src/mame/machine/namco_c139.cpp b/src/mame/machine/namco_c139.cpp index d28104dddb5..8ef4bf26271 100644 --- a/src/mame/machine/namco_c139.cpp +++ b/src/mame/machine/namco_c139.cpp @@ -28,9 +28,10 @@ DEFINE_DEVICE_TYPE(NAMCO_C139, namco_c139_device, "namco_c139", "Namco C139 Seri // LIVE DEVICE //************************************************************************** -ADDRESS_MAP_START(namco_c139_device::data_map) - AM_RANGE(0x0000, 0x3fff) AM_RAM AM_SHARE("sharedram") -ADDRESS_MAP_END +void namco_c139_device::data_map(address_map &map) +{ + map(0x0000, 0x3fff).ram().share("sharedram"); +} void namco_c139_device::regs_map(address_map &map) { diff --git a/src/mame/machine/naomim1.cpp b/src/mame/machine/naomim1.cpp index dfc89fc3c01..e20717b6c27 100644 --- a/src/mame/machine/naomim1.cpp +++ b/src/mame/machine/naomim1.cpp @@ -6,10 +6,11 @@ DEFINE_DEVICE_TYPE(NAOMI_M1_BOARD, naomi_m1_board, "naomi_m1_board", "Sega NAOMI M1 Board") -ADDRESS_MAP_START(naomi_m1_board::submap) - AM_IMPORT_FROM(naomi_board::submap) - AM_RANGE(0x0a, 0x0b) AM_READ(actel_id_r) -ADDRESS_MAP_END +void naomi_m1_board::submap(address_map &map) +{ + naomi_board::submap(map); + map(0x0a, 0x0b).r(this, FUNC(naomi_m1_board::actel_id_r)); +} naomi_m1_board::naomi_m1_board(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : naomi_board(mconfig, NAOMI_M1_BOARD, tag, owner, clock) diff --git a/src/mame/machine/naomim4.cpp b/src/mame/machine/naomim4.cpp index 90839878a31..dedb44ea195 100644 --- a/src/mame/machine/naomim4.cpp +++ b/src/mame/machine/naomim4.cpp @@ -40,10 +40,11 @@ static uint8_t cfidata[] = { 0x01,0x00 }; -ADDRESS_MAP_START(naomi_m4_board::submap) - AM_IMPORT_FROM(naomi_board::submap) - AM_RANGE(0x1a, 0x1b) AM_READ(m4_id_r) // Read: bits 8-15 - 0x55, bit 7 - 1 if IC7 EPR rom enabled; Write: bit 0 - master/slave board selection. -ADDRESS_MAP_END +void naomi_m4_board::submap(address_map &map) +{ + naomi_board::submap(map); + map(0x1a, 0x1b).r(this, FUNC(naomi_m4_board::m4_id_r)); // Read: bits 8-15 - 0x55, bit 7 - 1 if IC7 EPR rom enabled; Write: bit 0 - master/slave board selection. +} naomi_m4_board::naomi_m4_board(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : naomi_board(mconfig, NAOMI_M4_BOARD, tag, owner, clock) diff --git a/src/mame/machine/prof80mmu.cpp b/src/mame/machine/prof80mmu.cpp index 3e5409b7680..bf6d7044e08 100644 --- a/src/mame/machine/prof80mmu.cpp +++ b/src/mame/machine/prof80mmu.cpp @@ -23,8 +23,9 @@ void prof80_mmu_device::z80_program_map(address_map &map) map(0x0000, 0xffff).rw(this, FUNC(prof80_mmu_device::program_r), FUNC(prof80_mmu_device::program_w)); } -ADDRESS_MAP_START(prof80_mmu_device::program_map) -ADDRESS_MAP_END +void prof80_mmu_device::program_map(address_map &map) +{ +} diff --git a/src/mame/machine/segabb.cpp b/src/mame/machine/segabb.cpp index 30cc2eb6f11..b297d1916e3 100644 --- a/src/mame/machine/segabb.cpp +++ b/src/mame/machine/segabb.cpp @@ -5,14 +5,17 @@ DEFINE_DEVICE_TYPE(SEGA_LINDBERGH_BASEBOARD, sega_lindbergh_baseboard_device, "lindbergh_baseboard", "Sega Lindbergh Baseboard") -ADDRESS_MAP_START(sega_lindbergh_baseboard_device::map1) -ADDRESS_MAP_END +void sega_lindbergh_baseboard_device::map1(address_map &map) +{ +} -ADDRESS_MAP_START(sega_lindbergh_baseboard_device::map2) -ADDRESS_MAP_END +void sega_lindbergh_baseboard_device::map2(address_map &map) +{ +} -ADDRESS_MAP_START(sega_lindbergh_baseboard_device::map3) -ADDRESS_MAP_END +void sega_lindbergh_baseboard_device::map3(address_map &map) +{ +} sega_lindbergh_baseboard_device::sega_lindbergh_baseboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, SEGA_LINDBERGH_BASEBOARD, tag, owner, clock) diff --git a/src/mame/machine/seicop.cpp b/src/mame/machine/seicop.cpp index 47bc52ebe48..f0aa292915a 100644 --- a/src/mame/machine/seicop.cpp +++ b/src/mame/machine/seicop.cpp @@ -233,17 +233,18 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::d104_move_w) } // anything that is read thru ROM range 0xc**** is replacement code, therefore on this HW they are latches. -ADDRESS_MAP_START(seibu_cop_bootleg_device::seibucopbl_map) - AM_RANGE(0x01e, 0x01f) AM_RAM // angle step, PC=0xc0186 - AM_RANGE(0x046, 0x049) AM_READWRITE(d104_move_r,d104_move_w) - AM_RANGE(0x070, 0x07f) AM_RAM // DMA registers, PC=0xc0034 - AM_RANGE(0x0a0, 0x0af) AM_READWRITE(reg_hi_addr_r,reg_hi_addr_w) - AM_RANGE(0x0c0, 0x0cf) AM_READWRITE(reg_lo_addr_r,reg_lo_addr_w) - AM_RANGE(0x100, 0x105) AM_WRITE(cmd_trigger_w) - AM_RANGE(0x1b0, 0x1b1) AM_READ(status_r) - AM_RANGE(0x1b2, 0x1b3) AM_READ(dist_r) - AM_RANGE(0x1b4, 0x1b5) AM_READ(angle_r) -ADDRESS_MAP_END +void seibu_cop_bootleg_device::seibucopbl_map(address_map &map) +{ + map(0x01e, 0x01f).ram(); // angle step, PC=0xc0186 + map(0x046, 0x049).rw(this, FUNC(seibu_cop_bootleg_device::d104_move_r), FUNC(seibu_cop_bootleg_device::d104_move_w)); + map(0x070, 0x07f).ram(); // DMA registers, PC=0xc0034 + map(0x0a0, 0x0af).rw(this, FUNC(seibu_cop_bootleg_device::reg_hi_addr_r), FUNC(seibu_cop_bootleg_device::reg_hi_addr_w)); + map(0x0c0, 0x0cf).rw(this, FUNC(seibu_cop_bootleg_device::reg_lo_addr_r), FUNC(seibu_cop_bootleg_device::reg_lo_addr_w)); + map(0x100, 0x105).w(this, FUNC(seibu_cop_bootleg_device::cmd_trigger_w)); + map(0x1b0, 0x1b1).r(this, FUNC(seibu_cop_bootleg_device::status_r)); + map(0x1b2, 0x1b3).r(this, FUNC(seibu_cop_bootleg_device::dist_r)); + map(0x1b4, 0x1b5).r(this, FUNC(seibu_cop_bootleg_device::angle_r)); +} seibu_cop_bootleg_device::seibu_cop_bootleg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : device_t(mconfig, SEIBU_COP_BOOTLEG, tag, owner, clock), diff --git a/src/mame/machine/st0016.cpp b/src/mame/machine/st0016.cpp index d9dfce67473..120e4877f8c 100644 --- a/src/mame/machine/st0016.cpp +++ b/src/mame/machine/st0016.cpp @@ -9,23 +9,25 @@ DEFINE_DEVICE_TYPE(ST0016_CPU, st0016_cpu_device, "st0016_cpu", "ST0016") -ADDRESS_MAP_START(st0016_cpu_device::st0016_cpu_internal_map) - AM_RANGE(0xc000, 0xcfff) AM_READ(st0016_sprite_ram_r) AM_WRITE(st0016_sprite_ram_w) - AM_RANGE(0xd000, 0xdfff) AM_READ(st0016_sprite2_ram_r) AM_WRITE(st0016_sprite2_ram_w) - AM_RANGE(0xea00, 0xebff) AM_READ(st0016_palette_ram_r) AM_WRITE(st0016_palette_ram_w) - AM_RANGE(0xec00, 0xec1f) AM_READ(st0016_character_ram_r) AM_WRITE(st0016_character_ram_w) - AM_RANGE(0xe900, 0xe9ff) AM_DEVREADWRITE("stsnd", st0016_device, st0016_snd_r, st0016_snd_w) /* sound regs 8 x $20 bytes, see notes */ -ADDRESS_MAP_END - - -ADDRESS_MAP_START(st0016_cpu_device::st0016_cpu_internal_io_map) - ADDRESS_MAP_GLOBAL_MASK(0xff) - AM_RANGE(0x00, 0xbf) AM_READ(st0016_vregs_r) AM_WRITE(st0016_vregs_w) /* video/crt regs ? */ - AM_RANGE(0xe2, 0xe2) AM_WRITE(st0016_sprite_bank_w) - AM_RANGE(0xe3, 0xe4) AM_WRITE(st0016_character_bank_w) - AM_RANGE(0xe5, 0xe5) AM_WRITE(st0016_palette_bank_w) - AM_RANGE(0xf0, 0xf0) AM_READ(st0016_dma_r) -ADDRESS_MAP_END +void st0016_cpu_device::st0016_cpu_internal_map(address_map &map) +{ + map(0xc000, 0xcfff).r(this, FUNC(st0016_cpu_device::st0016_sprite_ram_r)).w(this, FUNC(st0016_cpu_device::st0016_sprite_ram_w)); + map(0xd000, 0xdfff).r(this, FUNC(st0016_cpu_device::st0016_sprite2_ram_r)).w(this, FUNC(st0016_cpu_device::st0016_sprite2_ram_w)); + map(0xea00, 0xebff).r(this, FUNC(st0016_cpu_device::st0016_palette_ram_r)).w(this, FUNC(st0016_cpu_device::st0016_palette_ram_w)); + map(0xec00, 0xec1f).r(this, FUNC(st0016_cpu_device::st0016_character_ram_r)).w(this, FUNC(st0016_cpu_device::st0016_character_ram_w)); + map(0xe900, 0xe9ff).rw("stsnd", FUNC(st0016_device::st0016_snd_r), FUNC(st0016_device::st0016_snd_w)); /* sound regs 8 x $20 bytes, see notes */ +} + + +void st0016_cpu_device::st0016_cpu_internal_io_map(address_map &map) +{ + map.global_mask(0xff); + map(0x00, 0xbf).r(this, FUNC(st0016_cpu_device::st0016_vregs_r)).w(this, FUNC(st0016_cpu_device::st0016_vregs_w)); /* video/crt regs ? */ + map(0xe2, 0xe2).w(this, FUNC(st0016_cpu_device::st0016_sprite_bank_w)); + map(0xe3, 0xe4).w(this, FUNC(st0016_cpu_device::st0016_character_bank_w)); + map(0xe5, 0xe5).w(this, FUNC(st0016_cpu_device::st0016_palette_bank_w)); + map(0xf0, 0xf0).r(this, FUNC(st0016_cpu_device::st0016_dma_r)); +} // note: a lot of bits are left uninitialized by the games, the default values are uncertain diff --git a/src/mame/machine/xbox_pci.cpp b/src/mame/machine/xbox_pci.cpp index 962f574c06b..b33f4d6ab42 100644 --- a/src/mame/machine/xbox_pci.cpp +++ b/src/mame/machine/xbox_pci.cpp @@ -61,10 +61,11 @@ void nv2a_host_device::device_reset() DEFINE_DEVICE_TYPE(NV2A_RAM, nv2a_ram_device, "nv2a_ram", "NV2A Memory Controller - SDRAM") -ADDRESS_MAP_START(nv2a_ram_device::config_map) - AM_IMPORT_FROM(pci_device::config_map) - AM_RANGE(0x6c, 0x6f) AM_READWRITE(config_register_r, config_register_w) -ADDRESS_MAP_END +void nv2a_ram_device::config_map(address_map &map) +{ + pci_device::config_map(map); + map(0x6c, 0x6f).rw(this, FUNC(nv2a_ram_device::config_register_r), FUNC(nv2a_ram_device::config_register_w)); +} nv2a_ram_device::nv2a_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, NV2A_RAM, tag, owner, clock) @@ -86,9 +87,10 @@ WRITE32_MEMBER(nv2a_ram_device::config_register_w) DEFINE_DEVICE_TYPE(MCPX_LPC, mcpx_lpc_device, "mcpx_lpc", "MCPX HUB Interface - ISA Bridge") -ADDRESS_MAP_START(mcpx_lpc_device::lpc_io) - AM_RANGE(0x00000000, 0x000000ff) AM_READWRITE(lpc_r, lpc_w) -ADDRESS_MAP_END +void mcpx_lpc_device::lpc_io(address_map &map) +{ + map(0x00000000, 0x000000ff).rw(this, FUNC(mcpx_lpc_device::lpc_r), FUNC(mcpx_lpc_device::lpc_w)); +} mcpx_lpc_device::mcpx_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_LPC, tag, owner, clock) @@ -122,17 +124,20 @@ WRITE32_MEMBER(mcpx_lpc_device::lpc_w) DEFINE_DEVICE_TYPE(MCPX_SMBUS, mcpx_smbus_device, "mcpx_smbus", "MCPX SMBus Controller") -ADDRESS_MAP_START(mcpx_smbus_device::smbus_io0) - AM_RANGE(0x00000000, 0x0000000f) AM_NOP -ADDRESS_MAP_END +void mcpx_smbus_device::smbus_io0(address_map &map) +{ + map(0x00000000, 0x0000000f).noprw(); +} -ADDRESS_MAP_START(mcpx_smbus_device::smbus_io1) - AM_RANGE(0x00000000, 0x0000000f) AM_READWRITE(smbus_r, smbus_w) -ADDRESS_MAP_END +void mcpx_smbus_device::smbus_io1(address_map &map) +{ + map(0x00000000, 0x0000000f).rw(this, FUNC(mcpx_smbus_device::smbus_r), FUNC(mcpx_smbus_device::smbus_w)); +} -ADDRESS_MAP_START(mcpx_smbus_device::smbus_io2) - AM_RANGE(0x00000000, 0x0000001f) AM_NOP -ADDRESS_MAP_END +void mcpx_smbus_device::smbus_io2(address_map &map) +{ + map(0x00000000, 0x0000001f).noprw(); +} mcpx_smbus_device::mcpx_smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_SMBUS, tag, owner, clock), @@ -221,9 +226,10 @@ WRITE32_MEMBER(mcpx_smbus_device::smbus_w) DEFINE_DEVICE_TYPE(MCPX_OHCI, mcpx_ohci_device, "mcpx_ohci", "MCPX OHCI USB Controller") -ADDRESS_MAP_START(mcpx_ohci_device::ohci_mmio) - AM_RANGE(0x00000000, 0x00000fff) AM_READWRITE(ohci_r, ohci_w) -ADDRESS_MAP_END +void mcpx_ohci_device::ohci_mmio(address_map &map) +{ + map(0x00000000, 0x00000fff).rw(this, FUNC(mcpx_ohci_device::ohci_r), FUNC(mcpx_ohci_device::ohci_w)); +} mcpx_ohci_device::mcpx_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_OHCI, tag, owner, clock), @@ -318,13 +324,15 @@ WRITE32_MEMBER(mcpx_ohci_device::ohci_w) DEFINE_DEVICE_TYPE(MCPX_ETH, mcpx_eth_device, "mcpx_eth", "MCP Networking Adapter") -ADDRESS_MAP_START(mcpx_eth_device::eth_mmio) - AM_RANGE(0x00000000, 0x0000003ff) AM_READWRITE(eth_r, eth_w) -ADDRESS_MAP_END +void mcpx_eth_device::eth_mmio(address_map &map) +{ + map(0x00000000, 0x0000003ff).rw(this, FUNC(mcpx_eth_device::eth_r), FUNC(mcpx_eth_device::eth_w)); +} -ADDRESS_MAP_START(mcpx_eth_device::eth_io) - AM_RANGE(0x00000000, 0x000000007) AM_READWRITE(eth_io_r, eth_io_w) -ADDRESS_MAP_END +void mcpx_eth_device::eth_io(address_map &map) +{ + map(0x00000000, 0x000000007).rw(this, FUNC(mcpx_eth_device::eth_io_r), FUNC(mcpx_eth_device::eth_io_w)); +} mcpx_eth_device::mcpx_eth_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_ETH, tag, owner, clock) @@ -369,9 +377,10 @@ WRITE32_MEMBER(mcpx_eth_device::eth_io_w) DEFINE_DEVICE_TYPE(MCPX_APU, mcpx_apu_device, "mcpx_apu", "MCP APU") -ADDRESS_MAP_START(mcpx_apu_device::apu_mmio) - AM_RANGE(0x00000000, 0x00007ffff) AM_READWRITE(apu_r, apu_w) -ADDRESS_MAP_END +void mcpx_apu_device::apu_mmio(address_map &map) +{ + map(0x00000000, 0x00007ffff).rw(this, FUNC(mcpx_apu_device::apu_r), FUNC(mcpx_apu_device::apu_w)); +} mcpx_apu_device::mcpx_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_APU, tag, owner, clock), @@ -562,17 +571,20 @@ WRITE32_MEMBER(mcpx_apu_device::apu_w) DEFINE_DEVICE_TYPE(MCPX_AC97_AUDIO, mcpx_ac97_audio_device, "mcpx_ac97_audio", "MCPX AC'97 Audio Codec Interface") -ADDRESS_MAP_START(mcpx_ac97_audio_device::ac97_mmio) - AM_RANGE(0x00000000, 0x000000fff) AM_READWRITE(ac97_audio_r, ac97_audio_w) -ADDRESS_MAP_END +void mcpx_ac97_audio_device::ac97_mmio(address_map &map) +{ + map(0x00000000, 0x000000fff).rw(this, FUNC(mcpx_ac97_audio_device::ac97_audio_r), FUNC(mcpx_ac97_audio_device::ac97_audio_w)); +} -ADDRESS_MAP_START(mcpx_ac97_audio_device::ac97_io0) - AM_RANGE(0x00000000, 0x0000000ff) AM_READWRITE(ac97_audio_io0_r, ac97_audio_io0_w) -ADDRESS_MAP_END +void mcpx_ac97_audio_device::ac97_io0(address_map &map) +{ + map(0x00000000, 0x0000000ff).rw(this, FUNC(mcpx_ac97_audio_device::ac97_audio_io0_r), FUNC(mcpx_ac97_audio_device::ac97_audio_io0_w)); +} -ADDRESS_MAP_START(mcpx_ac97_audio_device::ac97_io1) - AM_RANGE(0x00000000, 0x00000007f) AM_READWRITE(ac97_audio_io1_r, ac97_audio_io1_w) -ADDRESS_MAP_END +void mcpx_ac97_audio_device::ac97_io1(address_map &map) +{ + map(0x00000000, 0x00000007f).rw(this, FUNC(mcpx_ac97_audio_device::ac97_audio_io1_r), FUNC(mcpx_ac97_audio_device::ac97_audio_io1_w)); +} mcpx_ac97_audio_device::mcpx_ac97_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_AC97_AUDIO, tag, owner, clock) @@ -678,9 +690,10 @@ mcpx_ac97_modem_device::mcpx_ac97_modem_device(const machine_config &mconfig, co DEFINE_DEVICE_TYPE(MCPX_IDE, mcpx_ide_device, "mcpx_ide", "MCPX IDE Controller") -ADDRESS_MAP_START(mcpx_ide_device::mcpx_ide_io) - AM_RANGE(0x0000, 0x000f) AM_DEVREADWRITE("ide", bus_master_ide_controller_device, bmdma_r, bmdma_w) -ADDRESS_MAP_END +void mcpx_ide_device::mcpx_ide_io(address_map &map) +{ + map(0x0000, 0x000f).rw("ide", FUNC(bus_master_ide_controller_device::bmdma_r), FUNC(bus_master_ide_controller_device::bmdma_w)); +} mcpx_ide_device::mcpx_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, MCPX_IDE, tag, owner, clock), @@ -739,13 +752,15 @@ void nv2a_agp_device::device_reset() DEFINE_DEVICE_TYPE(NV2A_GPU, nv2a_gpu_device, "nv2a_gpu", "NVIDIA NV2A GPU") -ADDRESS_MAP_START(nv2a_gpu_device::nv2a_mmio) - AM_RANGE(0x00000000, 0x00ffffff) AM_RAM AM_READWRITE(geforce_r, geforce_w) -ADDRESS_MAP_END +void nv2a_gpu_device::nv2a_mmio(address_map &map) +{ + map(0x00000000, 0x00ffffff).ram().rw(this, FUNC(nv2a_gpu_device::geforce_r), FUNC(nv2a_gpu_device::geforce_w)); +} -ADDRESS_MAP_START(nv2a_gpu_device::nv2a_mirror) - AM_RANGE(0x00000000, 0x07ffffff) AM_RAM AM_READWRITE(nv2a_mirror_r, nv2a_mirror_w) -ADDRESS_MAP_END +void nv2a_gpu_device::nv2a_mirror(address_map &map) +{ + map(0x00000000, 0x07ffffff).ram().rw(this, FUNC(nv2a_gpu_device::nv2a_mirror_r), FUNC(nv2a_gpu_device::nv2a_mirror_w)); +} nv2a_gpu_device::nv2a_gpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pci_device(mconfig, NV2A_GPU, tag, owner, clock), |