syscall: retor_mem: switch to client in hosted mode

Switch to the message client when returning memory in Hosted mode. This
properly marks a process as ready-to-run, which was otherwise not
correctly done.

Signed-off-by: Sean Cross <sean@xobs.io>
This commit is contained in:
Sean Cross 2021-06-21 20:04:22 +08:00
parent 86dd38f7fa
commit 4901453e3d

View file

@ -368,7 +368,8 @@ fn return_memory(
// Send a message to the client, in order to wake it up
// print!(" [waking up PID {}:{}]", client_pid, client_tid);
ss.ready_thread(client_pid, client_tid)?;
// ss.switch_to_thread(client_pid, Some(client_tid))?;
#[cfg(not(baremetal))]
ss.switch_to_thread(client_pid, Some(client_tid))?;
ss.set_thread_result(
client_pid,
client_tid,