arm_interface: Add missing fpsr/tpidr members to the ThreadContext struct

Internally within the kernel, it also includes a member variable for the
floating-point status register, and TPIDR, so we should do the same here to match
it.

While we're at it, also fix up the size of the struct and add a static
assertion to ensure it always stays the correct size.
This commit is contained in:
Lioncash 2018-09-29 17:58:26 -04:00
parent 334090fe6f
commit 16145e2f21
3 changed files with 15 additions and 5 deletions

View file

@ -250,7 +250,7 @@ static void RegWrite(std::size_t id, u64 val, Kernel::Thread* thread = nullptr)
} else if (id == PC_REGISTER) {
thread->context.pc = val;
} else if (id == PSTATE_REGISTER) {
thread->context.pstate = val;
thread->context.pstate = static_cast<u32>(val);
} else if (id > PSTATE_REGISTER && id < FPCR_REGISTER) {
thread->context.vector_registers[id - (PSTATE_REGISTER + 1)][0] = val;
}