#[repr(usize)]pub enum SyscallId {
Show 19 variants
Mkdir = 34,
Mount = 40,
Umount = 39,
Open = 56,
Close = 57,
Read = 63,
Write = 64,
Unlink = 35,
Lseek = 62,
Getdents = 78,
Stat = 1_038,
Dup2 = 1_041,
Pipe = 59,
Exit = 93,
GetPid = 172,
Fork = 220,
Exec = 221,
Wait = 260,
Unknown = 9_999,
}Expand description
系统调用号定义 兼容Linux RISC-V系统调用号
Variants§
Mkdir = 34
Mount = 40
Umount = 39
Open = 56
Close = 57
Read = 63
Write = 64
Unlink = 35
Lseek = 62
Getdents = 78
Stat = 1_038
Dup2 = 1_041
Pipe = 59
Exit = 93
GetPid = 172
Fork = 220
Exec = 221
Wait = 260
Unknown = 9_999
Implementations§
Source§impl SyscallId
impl SyscallId
Sourcepub const fn requires_live_trap_frame(self) -> bool
pub const fn requires_live_trap_frame(self) -> bool
Returns true for process-control syscalls that must be dispatched from the live user trap frame instead of the context-only dispatcher.
These calls mutate the current process, scheduler state, or saved user
registers. syscall_dispatcher() only receives a copied
SyscallContext, so it intentionally returns ENOSYS for this set.
Real user-mode traps enter through syscall_trap_dispatcher().
pub const fn process_name(self) -> Option<&'static str>
Trait Implementations§
impl Copy for SyscallId
impl Eq for SyscallId
impl StructuralPartialEq for SyscallId
Auto Trait Implementations§
impl Forget for SyscallId
impl Freeze for SyscallId
impl RefUnwindSafe for SyscallId
impl Send for SyscallId
impl Sync for SyscallId
impl Unpin for SyscallId
impl UnsafeUnpin for SyscallId
impl UnwindSafe for SyscallId
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more