From 35d46f44df59aefadfccc5f0767e11355a33b4e1 Mon Sep 17 00:00:00 2001 From: AJR Date: Sun, 18 Feb 2018 23:08:00 -0500 Subject: taito_en.cpp: Regression fix (nw) --- src/mame/audio/taito_en.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/mame/audio/taito_en.cpp b/src/mame/audio/taito_en.cpp index 5fdbac91aae..d02fdaad95d 100644 --- a/src/mame/audio/taito_en.cpp +++ b/src/mame/audio/taito_en.cpp @@ -56,9 +56,10 @@ void taito_en_device::device_start() void taito_en_device::device_reset() { /* Sound cpu program loads to 0xc00000 so we use a bank */ + uint32_t max = (m_osrom->bytes() - 0x100000) / 0x20000; for (int i = 0; i < 3; i++) - m_cpubank[i]->set_entry(i); - + m_cpubank[i]->set_entry(i % max); + uint16_t *ROM = (uint16_t *)m_osrom->base(); std::copy(&ROM[0x80000], &ROM[0x80004], &m_osram[0]); /* Stack and Reset vectors */ -- cgit v1.2.3