xous-core/xous-rs/src/process.rs
Sean Cross 071f2047f8 xous: return TID and PID from current_tid() and current_pid()
These should return the raw values, rather than the Result values.

Signed-off-by: Sean Cross <sean@xobs.io>
2021-03-18 20:10:01 +08:00

9 lines
158 B
Rust

pub fn id() -> u32 {
if let Ok(pid) = crate::syscall::current_pid() {
pid.get() as u32
} else {
0
}
}
pub fn set_id(_id: u32) {}