Minor cleanup
Jeffrey Pfau jeffrey@endrift.com
Mon, 20 Jan 2014 18:01:49 -0800
2 files changed,
4 insertions(+),
5 deletions(-)
M
src/gba/gba-io.c
→
src/gba/gba-io.c
@@ -263,7 +263,7 @@ break;
case REG_IME: GBAWriteIME(gba, value); break; - case 0x20A: + case REG_MAX: // Some bad interrupt libraries will write to this break; default:@@ -402,7 +402,7 @@ case REG_WAITCNT:
case REG_IME: // Handled transparently by registers break; - case 0x20A: + case REG_MAX: // Some bad interrupt libraries will read from this break; default:@@ -424,7 +424,6 @@ }
} void GBAIODeserialize(struct GBA* gba, struct GBASerializedState* state) { - // TODO: Actually fill this out int i; for (i = 0; i < REG_MAX; i += 2) { if (_isSpecialRegister[i >> 1]) {
M
src/gba/gba-memory.c
→
src/gba/gba-memory.c
@@ -762,9 +762,9 @@
if (info->doIrq) { info->nextIRQ = memory->p->cpu.cycles + 2; info->nextIRQ += (width == 4 ? memory->waitstates32[sourceRegion] + memory->waitstates32[destRegion] - : memory->waitstates16[sourceRegion] + memory->waitstates16[destRegion]); + : memory->waitstates16[sourceRegion] + memory->waitstates16[destRegion]); info->nextIRQ += (info->count - 1) * (width == 4 ? memory->waitstatesSeq32[sourceRegion] + memory->waitstatesSeq32[destRegion] - : memory->waitstatesSeq16[sourceRegion] + memory->waitstatesSeq16[destRegion]); + : memory->waitstatesSeq16[sourceRegion] + memory->waitstatesSeq16[destRegion]); } info->nextSource = source;