[][src]Enum kernel::procs::FaultResponse

pub enum FaultResponse {
    Panic,
    Restart(&'static dyn ProcessRestartPolicy),
    Stop,
}

The reaction the kernel should take when an app encounters a fault.

When an exception occurs during an app's execution (a common example is an app trying to access memory outside of its allowed regions) the system will trap back to the kernel, and the kernel has to decide what to do with the app at that point.

Variants

Panic

Generate a panic!() call and crash the entire system. This is useful for debugging applications as the error is displayed immediately after it occurs.

Restart(&'static dyn ProcessRestartPolicy)

Attempt to cleanup and restart the app which caused the fault. This resets the app's memory to how it was when the app was started and schedules the app to run again from its init function.

The provided restart policy is used to determine whether to reset the app, and can be specified on a per-app basis.

Stop

Stop the app by no longer scheduling it to run.

Trait Implementations

impl Clone for FaultResponse[src]

impl Copy for FaultResponse[src]

Auto Trait Implementations

impl !Send for FaultResponse

impl !Sync for FaultResponse

impl Unpin for FaultResponse

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.