diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/arm/interpreter/arm_interpreter.cpp | 2 | ||||
| -rw-r--r-- | src/core/hle/kernel/thread.cpp | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/core/arm/interpreter/arm_interpreter.cpp b/src/core/arm/interpreter/arm_interpreter.cpp index d35a3ae17..0842d2f8e 100644 --- a/src/core/arm/interpreter/arm_interpreter.cpp +++ b/src/core/arm/interpreter/arm_interpreter.cpp | |||
| @@ -27,7 +27,7 @@ ARM_Interpreter::ARM_Interpreter() { | |||
| 27 | // Reset the core to initial state | 27 | // Reset the core to initial state |
| 28 | ARMul_CoProInit(state); | 28 | ARMul_CoProInit(state); |
| 29 | ARMul_Reset(state); | 29 | ARMul_Reset(state); |
| 30 | state->NextInstr = RESUME; | 30 | state->NextInstr = RESUME; // NOTE: This will be overwritten by LoadContext |
| 31 | state->Emulate = 3; | 31 | state->Emulate = 3; |
| 32 | 32 | ||
| 33 | state->pc = state->Reg[15] = 0x00000000; | 33 | state->pc = state->Reg[15] = 0x00000000; |
diff --git a/src/core/hle/kernel/thread.cpp b/src/core/hle/kernel/thread.cpp index 554ec9756..8bd9ca1a1 100644 --- a/src/core/hle/kernel/thread.cpp +++ b/src/core/hle/kernel/thread.cpp | |||
| @@ -117,6 +117,11 @@ void ResetThread(Thread* t, u32 arg, s32 lowest_priority) { | |||
| 117 | t->context.sp = t->stack_top; | 117 | t->context.sp = t->stack_top; |
| 118 | t->context.cpsr = 0x1F; // Usermode | 118 | t->context.cpsr = 0x1F; // Usermode |
| 119 | 119 | ||
| 120 | // TODO(bunnei): This instructs the CPU core to start the execution as if it is "resuming" a | ||
| 121 | // thread. This is somewhat Sky-Eye specific, and should be re-architected in the future to be | ||
| 122 | // agnostic of the CPU core. | ||
| 123 | t->context.mode = 8; | ||
| 124 | |||
| 120 | if (t->current_priority < lowest_priority) { | 125 | if (t->current_priority < lowest_priority) { |
| 121 | t->current_priority = t->initial_priority; | 126 | t->current_priority = t->initial_priority; |
| 122 | } | 127 | } |