Struct pic8259::ChainedPics[][src]

pub struct ChainedPics { /* fields omitted */ }
Expand description

A pair of chained PIC controllers. This is the standard setup on x86.

Implementations

impl ChainedPics[src]

pub const unsafe fn new(offset1: u8, offset2: u8) -> ChainedPics[src]

Create a new interface for the standard PIC1 and PIC2 controllers, specifying the desired interrupt offsets.

pub unsafe fn initialize(&mut self)[src]

Initialize both our PICs. We initialize them together, at the same time, because it’s traditional to do so, and because I/O operations might not be instantaneous on older processors.

pub unsafe fn read_masks(&mut self) -> [u8; 2][src]

Reads the interrupt masks of both PICs.

pub unsafe fn write_masks(&mut self, mask1: u8, mask2: u8)[src]

Writes the interrupt masks of both PICs.

pub unsafe fn disable(&mut self)[src]

Disables both PICs by masking all interrupts.

pub fn handles_interrupt(&self, interrupt_id: u8) -> bool[src]

Do we handle this interrupt?

pub unsafe fn notify_end_of_interrupt(&mut self, interrupt_id: u8)[src]

Figure out which (if any) PICs in our chain need to know about this interrupt. This is tricky, because all interrupts from pics[1] get chained through pics[0].

Auto Trait Implementations

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

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

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

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

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

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

pub fn into(self) -> U[src]

Performs the conversion.

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.

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

Performs the conversion.

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.

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

Performs the conversion.