aboutsummaryrefslogtreecommitdiff
path: root/libpcsxcore/sio.c
diff options
context:
space:
mode:
authornotaz2011-07-26 19:45:03 +0300
committernotaz2011-07-26 19:45:03 +0300
commitaa35134a834ff7e98b5a474c3db399a3d660da22 (patch)
treeb3dcbc04e4aa5a84f8e3632c444de92d6134619a /libpcsxcore/sio.c
parent22d3b3499d08635151a20206b8bc508169920a7a (diff)
downloadpcsx_rearmed-aa35134a834ff7e98b5a474c3db399a3d660da22.tar.gz
pcsx_rearmed-aa35134a834ff7e98b5a474c3db399a3d660da22.tar.bz2
pcsx_rearmed-aa35134a834ff7e98b5a474c3db399a3d660da22.zip
sio: only do IRQ if it's bit has been cleared
tested on the real thing.
Diffstat (limited to 'libpcsxcore/sio.c')
-rw-r--r--libpcsxcore/sio.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libpcsxcore/sio.c b/libpcsxcore/sio.c
index 4a0a73c..81fe0ea 100644
--- a/libpcsxcore/sio.c
+++ b/libpcsxcore/sio.c
@@ -386,8 +386,10 @@ void sioInterrupt() {
PAD_LOG("Sio Interrupt (CP0.Status = %x)\n", psxRegs.CP0.n.Status);
#endif
// SysPrintf("Sio Interrupt\n");
- StatReg |= IRQ;
- psxHu32ref(0x1070) |= SWAPu32(0x80);
+ if (!(StatReg & IRQ)) {
+ StatReg |= IRQ;
+ psxHu32ref(0x1070) |= SWAPu32(0x80);
+ }
}
void LoadMcd(int mcd, char *str) {