Struct arm_gic::gic_v2::GicDistributor
source · pub struct GicDistributor { /* private fields */ }
Expand description
The GIC distributor.
The Distributor block performs interrupt prioritization and distribution to the CPU interface blocks that connect to the processors in the system.
The Distributor provides a programming interface for:
- Globally enabling the forwarding of interrupts to the CPU interfaces.
- Enabling or disabling each interrupt.
- Setting the priority level of each interrupt.
- Setting the target processor list of each interrupt.
- Setting each peripheral interrupt to be level-sensitive or edge-triggered.
- Setting each interrupt as either Group 0 or Group 1.
- Forwarding an SGI to one or more target processors.
In addition, the Distributor provides:
- visibility of the state of each interrupt
- a mechanism for software to set or clear the pending state of a peripheral interrupt.
Implementations§
source§impl GicDistributor
impl GicDistributor
sourcepub const fn new(base: *mut u8) -> Self
pub const fn new(base: *mut u8) -> Self
Construct a new GIC distributor instance from the base address.
sourcepub fn configure_interrupt(&mut self, vector: usize, tm: TriggerMode)
pub fn configure_interrupt(&mut self, vector: usize, tm: TriggerMode)
Configures the trigger mode for the given interrupt.
sourcepub fn set_enable(&mut self, vector: usize, enable: bool)
pub fn set_enable(&mut self, vector: usize, enable: bool)
Enables or disables the given interrupt.
Trait Implementations§
impl Send for GicDistributor
impl Sync for GicDistributor
Auto Trait Implementations§
impl !RefUnwindSafe for GicDistributor
impl Unpin for GicDistributor
impl !UnwindSafe for GicDistributor
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more