cellGameContentPermit: extremely DANGEROUS bug fixed

And few tiny changes.
This commit is contained in:
Nekotekina 2014-11-29 20:41:18 +03:00
parent a7e659abd1
commit 9fc7197c4f
9 changed files with 64 additions and 33 deletions

View file

@ -102,6 +102,33 @@ void ARMv7Thread::DoCode()
{
}
void ARMv7Thread::FastCall(u32 addr)
{
auto old_status = m_status;
auto old_PC = PC;
auto old_stack = SP;
auto old_LR = LR;
auto old_thread = GetCurrentNamedThread();
m_status = Running;
PC = addr;
LR = Emu.m_cpu_thr_stop;
SetCurrentNamedThread(this);
CPUThread::Task();
m_status = old_status;
PC = old_PC;
SP = old_stack;
LR = old_LR;
SetCurrentNamedThread(old_thread);
}
void ARMv7Thread::FastStop()
{
m_status = Stopped;
}
arm7_thread::arm7_thread(u32 entry, const std::string& name, u32 stack_size, u32 prio)
{
thread = &Emu.GetCPU().AddThread(CPU_THREAD_ARMv7);
@ -112,4 +139,4 @@ arm7_thread::arm7_thread(u32 entry, const std::string& name, u32 stack_size, u32
thread->SetPrio(prio ? prio : Emu.GetInfo().GetProcParam().primary_prio);
argc = 0;
}
}