Struct arm_gic::GicV3

source ·
pub struct GicV3 { /* private fields */ }
Expand description

Driver for an Arm Generic Interrupt Controller version 3 (or 4).

Implementations§

source§

impl GicV3

source

pub const fn new(gicd: *mut u8, gicr: *mut u8) -> Self

Constructs a new instance of the driver for a GIC with the given distributor and redistributor base addresses.

Safety

The given base addresses must point to the GIC distributor and redistributor registers respectively. These regions must be mapped into the address space of the process as device memory, and not have any other aliases, either via another instance of this driver or otherwise.

Trait Implementations§

source§

impl Clone for GicV3

source§

fn clone(&self) -> GicV3

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for GicV3

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl GenericArmGic for GicV3

source§

fn init_primary(&mut self)

Initialises the GIC.

source§

fn enable_interrupt(&mut self, intid: IntId)

Enables the interrupt with the given ID.

source§

fn set_trigger(&mut self, intid: IntId, tm: TriggerMode)

Configures the trigger type for the interrupt with the given ID.

source§

fn get_and_acknowledge_interrupt(&self) -> Option<IntId>

Gets the ID of the highest priority signalled interrupt, and acknowledges it.

Returns None if there is no pending interrupt of sufficient priority.

source§

fn end_interrupt(&self, intid: IntId)

Informs the interrupt controller that the CPU has completed processing the given interrupt. This drops the interrupt priority and deactivates the interrupt.

source§

fn per_cpu_init(&mut self)

Initialises the GIC for the current CPU core.
source§

fn disable_interrupt(&mut self, intid: IntId)

Disable the interrupt with the given ID.
source§

impl Copy for GicV3

Auto Trait Implementations§

§

impl !RefUnwindSafe for GicV3

§

impl Send for GicV3

§

impl Sync for GicV3

§

impl Unpin for GicV3

§

impl !UnwindSafe for GicV3

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.