diff options
author | Olivier Galibert <galibert@pobox.com> | 2018-04-19 18:51:35 +0200 |
---|---|---|
committer | Olivier Galibert <galibert@pobox.com> | 2018-04-19 23:04:30 +0200 |
commit | 47ccf152b24557040b593c60ccf7896da88726a0 (patch) | |
tree | 7ee0b1d848473b707d4f45c037577efc02ab6b63 /src/devices/machine/upd765.cpp | |
parent | c8c43bfb5346d4de440f63e97487324d61235953 (diff) |
maps: Finish map.m() (nw)
Diffstat (limited to 'src/devices/machine/upd765.cpp')
-rw-r--r-- | src/devices/machine/upd765.cpp | 118 |
1 files changed, 63 insertions, 55 deletions
diff --git a/src/devices/machine/upd765.cpp b/src/devices/machine/upd765.cpp index 28ce1cd8126..d8ae17ecd31 100644 --- a/src/devices/machine/upd765.cpp +++ b/src/devices/machine/upd765.cpp @@ -22,78 +22,86 @@ DEFINE_DEVICE_TYPE(WD37C65C, wd37c65c_device, "wd37c65c", "Wes DEFINE_DEVICE_TYPE(MCS3201, mcs3201_device, "mcs3201", "Motorola MCS3201 FDC") DEFINE_DEVICE_TYPE(TC8566AF, tc8566af_device, "tc8566af", "Toshiba TC8566AF FDC") -ADDRESS_MAP_START(upd765a_device::map) - AM_RANGE(0x0, 0x0) AM_READ(msr_r) - AM_RANGE(0x1, 0x1) AM_READWRITE(fifo_r, fifo_w) -ADDRESS_MAP_END +void upd765a_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(upd765a_device::msr_r)); + map(0x1, 0x1).rw(this, FUNC(upd765a_device::fifo_r), FUNC(upd765a_device::fifo_w)); +} ADDRESS_MAP_START(upd765b_device::map) AM_RANGE(0x0, 0x0) AM_READ(msr_r) AM_RANGE(0x1, 0x1) AM_READWRITE(fifo_r, fifo_w) ADDRESS_MAP_END -ADDRESS_MAP_START(i8272a_device::map) - AM_RANGE(0x0, 0x0) AM_READ(msr_r) - AM_RANGE(0x1, 0x1) AM_READWRITE(fifo_r, fifo_w) -ADDRESS_MAP_END +void i8272a_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(i8272a_device::msr_r)); + map(0x1, 0x1).rw(this, FUNC(i8272a_device::fifo_r), FUNC(i8272a_device::fifo_w)); +} -ADDRESS_MAP_START(upd72065_device::map) - AM_RANGE(0x0, 0x0) AM_READ(msr_r) - AM_RANGE(0x1, 0x1) AM_READWRITE(fifo_r, fifo_w) -ADDRESS_MAP_END +void upd72065_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(upd72065_device::msr_r)); + map(0x1, 0x1).rw(this, FUNC(upd72065_device::fifo_r), FUNC(upd72065_device::fifo_w)); +} ADDRESS_MAP_START(i82072_device::map) AM_RANGE(0x0, 0x0) AM_READWRITE(msr_r, dsr_w) AM_RANGE(0x1, 0x1) AM_READWRITE(fifo_r, fifo_w) ADDRESS_MAP_END -ADDRESS_MAP_START(smc37c78_device::map) - AM_RANGE(0x2, 0x2) AM_READWRITE(dor_r, dor_w) - AM_RANGE(0x3, 0x3) AM_READWRITE(tdr_r, tdr_w) - AM_RANGE(0x4, 0x4) AM_READWRITE(msr_r, dsr_w) - AM_RANGE(0x5, 0x5) AM_READWRITE(fifo_r, fifo_w) - AM_RANGE(0x7, 0x7) AM_READWRITE(dir_r, ccr_w) -ADDRESS_MAP_END +void smc37c78_device::map(address_map &map) +{ + map(0x2, 0x2).rw(this, FUNC(smc37c78_device::dor_r), FUNC(smc37c78_device::dor_w)); + map(0x3, 0x3).rw(this, FUNC(smc37c78_device::tdr_r), FUNC(smc37c78_device::tdr_w)); + map(0x4, 0x4).rw(this, FUNC(smc37c78_device::msr_r), FUNC(smc37c78_device::dsr_w)); + map(0x5, 0x5).rw(this, FUNC(smc37c78_device::fifo_r), FUNC(smc37c78_device::fifo_w)); + map(0x7, 0x7).rw(this, FUNC(smc37c78_device::dir_r), FUNC(smc37c78_device::ccr_w)); +} -ADDRESS_MAP_START(n82077aa_device::map) - AM_RANGE(0x0, 0x0) AM_READ(sra_r) - AM_RANGE(0x1, 0x1) AM_READ(srb_r) - AM_RANGE(0x2, 0x2) AM_READWRITE(dor_r, dor_w) - AM_RANGE(0x3, 0x3) AM_READWRITE(tdr_r, tdr_w) - AM_RANGE(0x4, 0x4) AM_READWRITE(msr_r, dsr_w) - AM_RANGE(0x5, 0x5) AM_READWRITE(fifo_r, fifo_w) - AM_RANGE(0x7, 0x7) AM_READWRITE(dir_r, ccr_w) -ADDRESS_MAP_END +void n82077aa_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(n82077aa_device::sra_r)); + map(0x1, 0x1).r(this, FUNC(n82077aa_device::srb_r)); + map(0x2, 0x2).rw(this, FUNC(n82077aa_device::dor_r), FUNC(n82077aa_device::dor_w)); + map(0x3, 0x3).rw(this, FUNC(n82077aa_device::tdr_r), FUNC(n82077aa_device::tdr_w)); + map(0x4, 0x4).rw(this, FUNC(n82077aa_device::msr_r), FUNC(n82077aa_device::dsr_w)); + map(0x5, 0x5).rw(this, FUNC(n82077aa_device::fifo_r), FUNC(n82077aa_device::fifo_w)); + map(0x7, 0x7).rw(this, FUNC(n82077aa_device::dir_r), FUNC(n82077aa_device::ccr_w)); +} -ADDRESS_MAP_START(pc_fdc_superio_device::map) - AM_RANGE(0x0, 0x0) AM_READ(sra_r) - AM_RANGE(0x1, 0x1) AM_READ(srb_r) - AM_RANGE(0x2, 0x2) AM_READWRITE(dor_r, dor_w) - AM_RANGE(0x3, 0x3) AM_READWRITE(tdr_r, tdr_w) - AM_RANGE(0x4, 0x4) AM_READWRITE(msr_r, dsr_w) - AM_RANGE(0x5, 0x5) AM_READWRITE(fifo_r, fifo_w) - AM_RANGE(0x7, 0x7) AM_READWRITE(dir_r, ccr_w) -ADDRESS_MAP_END +void pc_fdc_superio_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(pc_fdc_superio_device::sra_r)); + map(0x1, 0x1).r(this, FUNC(pc_fdc_superio_device::srb_r)); + map(0x2, 0x2).rw(this, FUNC(pc_fdc_superio_device::dor_r), FUNC(pc_fdc_superio_device::dor_w)); + map(0x3, 0x3).rw(this, FUNC(pc_fdc_superio_device::tdr_r), FUNC(pc_fdc_superio_device::tdr_w)); + map(0x4, 0x4).rw(this, FUNC(pc_fdc_superio_device::msr_r), FUNC(pc_fdc_superio_device::dsr_w)); + map(0x5, 0x5).rw(this, FUNC(pc_fdc_superio_device::fifo_r), FUNC(pc_fdc_superio_device::fifo_w)); + map(0x7, 0x7).rw(this, FUNC(pc_fdc_superio_device::dir_r), FUNC(pc_fdc_superio_device::ccr_w)); +} -ADDRESS_MAP_START(dp8473_device::map) - AM_RANGE(0x0, 0x0) AM_READ(sra_r) - AM_RANGE(0x1, 0x1) AM_READ(srb_r) - AM_RANGE(0x2, 0x2) AM_READWRITE(dor_r, dor_w) - AM_RANGE(0x3, 0x3) AM_READWRITE(tdr_r, tdr_w) - AM_RANGE(0x4, 0x4) AM_READWRITE(msr_r, dsr_w) - AM_RANGE(0x5, 0x5) AM_READWRITE(fifo_r, fifo_w) - AM_RANGE(0x7, 0x7) AM_READWRITE(dir_r, ccr_w) -ADDRESS_MAP_END +void dp8473_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(dp8473_device::sra_r)); + map(0x1, 0x1).r(this, FUNC(dp8473_device::srb_r)); + map(0x2, 0x2).rw(this, FUNC(dp8473_device::dor_r), FUNC(dp8473_device::dor_w)); + map(0x3, 0x3).rw(this, FUNC(dp8473_device::tdr_r), FUNC(dp8473_device::tdr_w)); + map(0x4, 0x4).rw(this, FUNC(dp8473_device::msr_r), FUNC(dp8473_device::dsr_w)); + map(0x5, 0x5).rw(this, FUNC(dp8473_device::fifo_r), FUNC(dp8473_device::fifo_w)); + map(0x7, 0x7).rw(this, FUNC(dp8473_device::dir_r), FUNC(dp8473_device::ccr_w)); +} -ADDRESS_MAP_START(pc8477a_device::map) - AM_RANGE(0x0, 0x0) AM_READ(sra_r) - AM_RANGE(0x1, 0x1) AM_READ(srb_r) - AM_RANGE(0x2, 0x2) AM_READWRITE(dor_r, dor_w) - AM_RANGE(0x3, 0x3) AM_READWRITE(tdr_r, tdr_w) - AM_RANGE(0x4, 0x4) AM_READWRITE(msr_r, dsr_w) - AM_RANGE(0x5, 0x5) AM_READWRITE(fifo_r, fifo_w) - AM_RANGE(0x7, 0x7) AM_READWRITE(dir_r, ccr_w) -ADDRESS_MAP_END +void pc8477a_device::map(address_map &map) +{ + map(0x0, 0x0).r(this, FUNC(pc8477a_device::sra_r)); + map(0x1, 0x1).r(this, FUNC(pc8477a_device::srb_r)); + map(0x2, 0x2).rw(this, FUNC(pc8477a_device::dor_r), FUNC(pc8477a_device::dor_w)); + map(0x3, 0x3).rw(this, FUNC(pc8477a_device::tdr_r), FUNC(pc8477a_device::tdr_w)); + map(0x4, 0x4).rw(this, FUNC(pc8477a_device::msr_r), FUNC(pc8477a_device::dsr_w)); + map(0x5, 0x5).rw(this, FUNC(pc8477a_device::fifo_r), FUNC(pc8477a_device::fifo_w)); + map(0x7, 0x7).rw(this, FUNC(pc8477a_device::dir_r), FUNC(pc8477a_device::ccr_w)); +} ADDRESS_MAP_START(wd37c65c_device::map) AM_RANGE(0x0, 0x0) AM_READ(msr_r) |