summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/cpu/adsp2100/adsp2100.c
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2012-09-19 19:48:09 +0000
committer Aaron Giles <aaron@aarongiles.com>2012-09-19 19:48:09 +0000
commit621ac620ae1ca743a66bb52aaf5478da01c3bac6 (patch)
tree2743a87e9077417af7546970d1ea1cc3b8781a63 /src/emu/cpu/adsp2100/adsp2100.c
parent33c77e65bbd4513957f2ece623cee476cf439248 (diff)
Since nobody checks for NULLs anyway, make
device_memory_interface::space() assert against NULL and return a reference, and pushed references throughout all address space usage in the system. Added a has_space() method to check for those rare case when it is ambiguous. [Aaron Giles] Also reinstated the generic space and added fatal error handlers if anyone tries to actually read/write from it.
Diffstat (limited to 'src/emu/cpu/adsp2100/adsp2100.c')
-rw-r--r--src/emu/cpu/adsp2100/adsp2100.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/emu/cpu/adsp2100/adsp2100.c b/src/emu/cpu/adsp2100/adsp2100.c
index bdc335e1057..95e2e31f852 100644
--- a/src/emu/cpu/adsp2100/adsp2100.c
+++ b/src/emu/cpu/adsp2100/adsp2100.c
@@ -445,10 +445,10 @@ UINT16 adsp2181_device::idma_data_r()
void adsp21xx_device::device_start()
{
// get our address spaces
- m_program = space(AS_PROGRAM);
+ m_program = &space(AS_PROGRAM);
m_direct = &m_program->direct();
- m_data = space(AS_DATA);
- m_io = space(AS_IO);
+ m_data = &space(AS_DATA);
+ m_io = has_space(AS_IO) ? &space(AS_IO) : NULL;
// "core"
save_item(NAME(m_core.ax0.u));