#[repr(u16)]pub enum SyscallNum {
Show 35 variants
SysPExit = 0,
SysTYield = 1,
SysOpenAll = 2,
SysOpen = 25,
SysRemovePath = 28,
SysDirIterOpen = 8,
SysDestroyResource = 5,
SysDirIterClose = 9,
SysDirIterNext = 10,
SysWrite = 3,
SysRead = 4,
SysCreate = 6,
SysCreateDir = 7,
SysSync = 16,
SysTruncate = 17,
SysCtl = 12,
SysDup = 26,
SysFSize = 22,
SysFAttrs = 24,
SysGetDirEntry = 23,
SysCHDir = 14,
SysGetCWD = 15,
SysSbrk = 18,
SysPSpawn = 19,
SysTSpawn = 29,
SysTExit = 30,
SysTSleep = 31,
SysPWait = 11,
SysTWait = 32,
SysPTryCleanUp = 33,
SysTFutWait = 34,
SysTFutWake = 35,
SysShutdown = 20,
SysReboot = 21,
SysUptime = 27,
}Expand description
defines Syscall numbers
Variants§
SysPExit = 0
SysTYield = 1
SysOpenAll = 2
Opens a file or directory with all permissions
SysOpen = 25
Opens a file or directory with given mode (permissions and flags)
SysRemovePath = 28
Deletes a path
SysDirIterOpen = 8
SysDestroyResource = 5
Destroys (closes) an open resource whether it is a file, directory, directory iterator, or any other resource
SysDirIterClose = 9
Legacy system call to close a directory iterator, use [SysDestroy] instead
SysDirIterNext = 10
SysWrite = 3
SysRead = 4
SysCreate = 6
SysCreateDir = 7
SysSync = 16
SysTruncate = 17
SysCtl = 12
SysDup = 26
SysFSize = 22
SysFAttrs = 24
SysGetDirEntry = 23
SysCHDir = 14
SysGetCWD = 15
SysSbrk = 18
SysPSpawn = 19
Spawns a process (process)
SysTSpawn = 29
Spawns a thread (context) inside the current process (process) with the given entry point
SysTExit = 30
SysTSleep = 31
SysPWait = 11
Waits for a child process with a given PID to exit, cleans it up and returns the exit code
SysTWait = 32
Waits for a child thread with a given TID to exit
SysPTryCleanUp = 33
like [SysPWait] without the waiting part, cleans up the given process and returns the exit code
returns crate::errors::ErrorStatus::InvalidPid if the process doesn’t exist
returns crate::errors::ErrorStatus::Generic if the process exists but hasn’t exited yet
SysTFutWait = 34
Performs a WAIT(addr, val) on the current thread, also takes a timeout
SysTFutWake = 35
Performs a WAKE(addr, n) on the current thread, wakes n threads waiting on the given address
SysShutdown = 20
SysReboot = 21
SysUptime = 27
returns the Uptime of the system in milliseconds
Trait Implementations§
Source§impl Clone for SyscallTable
impl Clone for SyscallTable
Source§fn clone(&self) -> SyscallTable
fn clone(&self) -> SyscallTable
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more