Refactor CPU mutex code
This commit is contained in:
@@ -42,7 +42,7 @@ void exception_trigger(rv32_cpu_t* cpu, uint32_t scause, uint32_t tval)
|
||||
cpu->pc = cpu->csr[CSR_STVEC] & 0xFFFFFFFC;
|
||||
|
||||
// Unlock cpu mutex, cpu_loop will lock it just after
|
||||
pthread_mutex_unlock(&cpu0_mutex);
|
||||
pthread_mutex_unlock(&cpu->mutex);
|
||||
|
||||
// cpu loop (attribute noreturn should erase previous stack)
|
||||
cpu_loop(cpu);
|
||||
|
Reference in New Issue
Block a user