Module kernel::process[][src]

Expand description

Types for Tock-compatible processes.

Structs

Struct that defines a upcall that can be passed to a process. The upcall takes four arguments that are Driver and upcall specific, so they are represented generically here.

Simply panic the entire board if a process faults.

Collection of process state information related to the memory addresses of different elements of the process.

Opaque identifier for custom grants allocated dynamically from a process’s grant region.

Userspace process identifier.

A context token that the caller must pass back to us. This allows us to track where we are in the print operation.

A Process Printer that displays a process as a human-readable string.

Collection of process state related to the size in memory of various process structures.

A type for userspace processes in Tock.

Always restart the process if it faults.

Simply stop the process and no longer schedule it if a process faults.

Stop the process and no longer schedule it if a process faults, but also print a debug message notifying the user that the process faulted and stopped.

Implementation of ProcessFaultPolicy that uses a threshold to decide whether to restart a process when it faults. If the process has been restarted more times than the threshold then the process will be stopped and no longer scheduled.

Implementation of ProcessFaultPolicy that uses a threshold to decide whether to restart a process when it faults. If the process has been restarted more times than the threshold then the board will panic.

Enums

The action the kernel should take when a process encounters a fault.

Enumeration to identify whether a function call for a process comes directly from the kernel or from a upcall subscribed through a Driver implementation.

Errors that can occur when trying to load and create processes.

Various states a process can be in.

Tasks that can be enqueued for a process.

Traits

This trait represents a generic process that the Tock scheduler can schedule.

Generic trait for implementing a policy on what to do when a process faults.

Trait for creating a custom “process printer” that formats process state in some sort of presentable format.

Functions

This is a wrapper function for load_processes_advanced that uses the default arguments that mainstream boards should provide.

Helper function to load processes from flash into an array of active processes. This is the default template for loading processes, but a board is able to create its own load_processes() function and use that instead.