From c929d074dc888a737b40581ca01a0eb8fb5b895d Mon Sep 17 00:00:00 2001 From: MooglyGuy Date: Mon, 14 Jan 2019 23:36:20 +0100 Subject: [PATCH] spg2xx: Only flag sprite DMA done IRQ if it is enabled. Gets mattelcs to boot. nw --- src/devices/machine/spg2xx.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/devices/machine/spg2xx.cpp b/src/devices/machine/spg2xx.cpp index 755c9bc9120..c9eba98f2cb 100644 --- a/src/devices/machine/spg2xx.cpp +++ b/src/devices/machine/spg2xx.cpp @@ -688,7 +688,14 @@ void spg2xx_device::do_sprite_dma(uint32_t len) } m_video_regs[0x72] = 0; - VIDEO_IRQ_STATUS |= 4; + if (VIDEO_IRQ_ENABLE & 4) + { + const uint16_t old = VIDEO_IRQ_STATUS; + VIDEO_IRQ_STATUS |= 4; + const uint16_t changed = old ^ (VIDEO_IRQ_ENABLE & VIDEO_IRQ_STATUS); + if (changed) + check_video_irq(); + } } READ16_MEMBER(spg2xx_device::video_r)