summaryrefslogtreecommitdiffstats
path: root/src/devices/machine/am9517a.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/machine/am9517a.h')
-rw-r--r--src/devices/machine/am9517a.h51
1 files changed, 6 insertions, 45 deletions
diff --git a/src/devices/machine/am9517a.h b/src/devices/machine/am9517a.h
index a1e9215d125..37390a930d3 100644
--- a/src/devices/machine/am9517a.h
+++ b/src/devices/machine/am9517a.h
@@ -61,8 +61,8 @@ public:
template <unsigned C> auto out_iow_callback() { return m_out_iow_cb[C].bind(); }
template <unsigned C> auto out_dack_callback() { return m_out_dack_cb[C].bind(); }
- virtual uint8_t read(offs_t offset);
- virtual void write(offs_t offset, uint8_t data);
+ virtual DECLARE_READ8_MEMBER( read );
+ virtual DECLARE_WRITE8_MEMBER( write );
DECLARE_WRITE_LINE_MEMBER( hack_w );
DECLARE_WRITE_LINE_MEMBER( ready_w );
@@ -95,9 +95,9 @@ protected:
struct
{
uint32_t m_address;
- uint32_t m_count;
+ uint16_t m_count;
uint32_t m_base_address;
- uint32_t m_base_count;
+ uint16_t m_base_count;
uint8_t m_mode;
} m_channel[4];
@@ -149,8 +149,8 @@ public:
template <unsigned C> auto in_io16r_callback() { return m_in_io16r_cb[C].bind(); }
template <unsigned C> auto out_io16w_callback() { return m_out_io16w_cb[C].bind(); }
- virtual uint8_t read(offs_t offset) override;
- virtual void write(offs_t offset, uint8_t data) override;
+ virtual DECLARE_READ8_MEMBER( read ) override;
+ virtual DECLARE_WRITE8_MEMBER( write ) override;
protected:
// device-level overrides
@@ -186,50 +186,11 @@ protected:
virtual void end_of_process() override;
};
-class eisa_dma_device : public am9517a_device
-{
-public:
- eisa_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
-
- template <unsigned Channel> u8 get_address_page() { return m_channel[Channel].m_address >> 16; }
- template <unsigned Channel> void set_address_page(u8 data)
- {
- m_channel[Channel].m_base_address = (m_channel[Channel].m_base_address & 0x0000ffffU) | (u32(data) << 16);
- m_channel[Channel].m_address = (m_channel[Channel].m_address & 0x0000ffffU) | (u32(data) << 16);
- }
-
- template <unsigned Channel> u8 get_address_page_high() { return m_channel[Channel].m_address >> 24; }
- template <unsigned Channel> void set_address_page_high(u8 data)
- {
- m_channel[Channel].m_base_address = (m_channel[Channel].m_base_address & 0x00ffffffU) | (u32(data) << 24);
- m_channel[Channel].m_address = (m_channel[Channel].m_address & 0x00ffffffU) | (u32(data) << 24);
- }
-
- template <unsigned Channel> u8 get_count_high() { return m_channel[Channel].m_count >> 16; }
- template <unsigned Channel> void set_count_high(u8 data)
- {
- m_channel[Channel].m_base_count = (m_channel[Channel].m_base_count & 0x0000ffffU) | (u32(data) << 16);
- m_channel[Channel].m_count = (m_channel[Channel].m_count & 0x0000ffffU) | (u32(data) << 16);
- }
- template <unsigned Channel> u32 get_stop() { return m_stop[Channel]; }
- template <unsigned Channel> void set_stop(offs_t offset, u32 data, u32 mem_mask)
- {
- mem_mask &= 0x00fffffcU;
- COMBINE_DATA(&m_stop[Channel]);
- }
-
-protected:
- virtual void device_start() override;
-
-private:
- u32 m_stop[4];
-};
// device type definition
DECLARE_DEVICE_TYPE(AM9517A, am9517a_device)
DECLARE_DEVICE_TYPE(V5X_DMAU, v5x_dmau_device)
DECLARE_DEVICE_TYPE(PCXPORT_DMAC, pcxport_dmac_device)
-DECLARE_DEVICE_TYPE(EISA_DMA, eisa_dma_device)
#endif // MAME_MACHINE_AM9517_H