summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/machine/rf5c296.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/machine/rf5c296.h')
-rw-r--r--src/devices/machine/rf5c296.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/devices/machine/rf5c296.h b/src/devices/machine/rf5c296.h
index 47ebf683cf3..fc95d3fdc4f 100644
--- a/src/devices/machine/rf5c296.h
+++ b/src/devices/machine/rf5c296.h
@@ -8,7 +8,7 @@
#include "pccard.h"
#define MCFG_RF5C296_SLOT(name) \
- downcast<rf5c296_device &>(*device).set_pccard_name(name);
+ downcast<rf5c296_device &>(*device).set_pccard(name);
class rf5c296_device : public device_t
{
@@ -16,7 +16,7 @@ public:
rf5c296_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
// configuration helpers
- void set_pccard_name(const char *name) { m_pccard_name = name; }
+ template <typename T> void set_pccard(T &&tag) { m_pccard.set_tag(std::forward<T>(tag)); }
DECLARE_WRITE16_MEMBER(io_w);
DECLARE_READ16_MEMBER(io_r);
@@ -32,8 +32,7 @@ private:
uint8_t reg_r(ATTR_UNUSED uint8_t reg);
unsigned char m_rf5c296_reg;
- pccard_slot_device *m_pccard;
- const char *m_pccard_name;
+ required_device<pccard_slot_device> m_pccard;
};
DECLARE_DEVICE_TYPE(RF5C296, rf5c296_device)