Check active region instead of pc for BIOS loads
Jeffrey Pfau jeffrey@endrift.com
Fri, 29 Aug 2014 01:46:46 -0700
1 files changed,
3 insertions(+),
3 deletions(-)
jump to
M
src/gba/gba-memory.c
→
src/gba/gba-memory.c
@@ -165,7 +165,7 @@ int wait = 0;
switch (address & ~OFFSET_MASK) { case BASE_BIOS: - if (cpu->gprs[ARM_PC] >> BASE_OFFSET == REGION_BIOS) { + if (memory->activeRegion == REGION_BIOS) { if (address < SIZE_BIOS) { LOAD_32(value, address, memory->bios); } else {@@ -239,7 +239,7 @@ int wait = 0;
switch (address & ~OFFSET_MASK) { case BASE_BIOS: - if (cpu->gprs[ARM_PC] >> BASE_OFFSET == REGION_BIOS) { + if (memory->activeRegion == REGION_BIOS) { if (address < SIZE_BIOS) { LOAD_16(value, address, memory->bios); } else {@@ -316,7 +316,7 @@ int wait = 0;
switch (address & ~OFFSET_MASK) { case BASE_BIOS: - if (cpu->gprs[ARM_PC] >> BASE_OFFSET == REGION_BIOS) { + if (memory->activeRegion == REGION_BIOS) { if (address < SIZE_BIOS) { value = ((int8_t*) memory->bios)[address]; } else {