Skip to main content Skip to main content
Pigweed's logo Pigweed
code_xml
  1. Home
  2. Reference
  3. Rust
  4. pw_kernel
  5. kernel
  6. SyscallArgs

SyscallArgs

Trait SyscallArgs 

Source
pub trait SyscallArgs<'a> {
    // Required methods
    fn next_usize(&mut self) -> Result<usize>;
    fn next_u64(&mut self) -> Result<u64>;

    // Provided methods
    fn next_u32(&mut self) -> Result<u32> { ... }
    fn next_instant<C: Clock>(&mut self) -> Result<Instant<C>> { ... }
}
Expand description

An arch-specific collection of syscall arguments

Since architectures ABI, calling, and syscall conventions can differ, this trait provides a common API for extracting syscall arguments. The API does not provide any index based methods for retrieving arguments because, on some architectures, the location of an argument can depend of the size of the preceding arguments.

Required Methods§

Source

fn next_usize(&mut self) -> Result<usize>

Return the next usize argument.

Source

fn next_u64(&mut self) -> Result<u64>

Return the next u64 argument.

Provided Methods§

Source

fn next_u32(&mut self) -> Result<u32>

Return the next u32 argument.

Source

fn next_instant<C: Clock>(&mut self) -> Result<Instant<C>>

Return the next Instant argument.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§