mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-27 11:23:25 +00:00
11 lines
256 B
Rust
11 lines
256 B
Rust
// SPDX-License-Identifier: MPL-2.0
|
|
|
|
use super::SyscallReturn;
|
|
use crate::prelude::*;
|
|
|
|
pub fn sys_gettid() -> Result<SyscallReturn> {
|
|
let current_thread = current_thread!();
|
|
let tid = current_thread.tid();
|
|
Ok(SyscallReturn::Return(tid as _))
|
|
}
|