Skip to content

Commit

Permalink
IOS: Avoid ppcState global.
Browse files Browse the repository at this point in the history
  • Loading branch information
AdmiralCurtiss committed Jan 27, 2023
1 parent 0a0b4d3 commit ed63347
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Source/Core/Core/IOS/IOS.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ static void ResetAndPausePPC()
auto& memory = system.GetMemory();
memory.Write_U32(0x48000000, 0x00000000); // b 0x0
PowerPC::Reset();
PowerPC::ppcState.pc = 0;
system.GetPPCState().pc = 0;
}

static void ReleasePPC()
Expand All @@ -212,7 +212,7 @@ static void ReleasePPC()
// NAND titles start with address translation off at 0x3400 (via the PPC bootstub)
// The state of other CPU registers (like the BAT registers) doesn't matter much
// because the realmode code at 0x3400 initializes everything itself anyway.
PowerPC::ppcState.pc = 0x3400;
system.GetPPCState().pc = 0x3400;
}

static void ReleasePPCAncast()
Expand All @@ -223,7 +223,7 @@ static void ReleasePPCAncast()
// On a real console the Espresso verifies and decrypts the Ancast image,
// then jumps to the decrypted ancast body.
// The Ancast loader already did this, so just jump to the decrypted body.
PowerPC::ppcState.pc = ESPRESSO_ANCAST_LOCATION_VIRT + sizeof(EspressoAncastHeader);
system.GetPPCState().pc = ESPRESSO_ANCAST_LOCATION_VIRT + sizeof(EspressoAncastHeader);
}

void RAMOverrideForIOSMemoryValues(MemorySetupType setup_type)
Expand Down

0 comments on commit ed63347

Please sign in to comment.