mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-16 08:38:26 +00:00
Merge branch 'main' of github.com:betrusted-io/xous-core into main
This commit is contained in:
commit
2a6679668b
1 changed files with 5 additions and 1 deletions
|
|
@ -587,7 +587,11 @@ impl SystemServices {
|
|||
let mut current = self
|
||||
.get_process_mut(current_pid)
|
||||
.expect("couldn't get current PID");
|
||||
assert!(arch::process::current_tid() == current.current_thread);
|
||||
// The current thread should never be 0, but for some reason it ends up
|
||||
// as 0 after resuming from suspend. It's unclear how this happens.
|
||||
if current.current_thread == 0 {
|
||||
current.current_thread = arch::process::current_tid();
|
||||
}
|
||||
// let old_state = current.state;
|
||||
current.state = match current.state {
|
||||
ProcessState::Running(x) => ProcessState::Ready(x | (1 << current.current_thread)),
|
||||
|
|
|
|||
Loading…
Reference in a new issue