Struct x86::bits64::irq::IdtEntry [] [src]

pub struct IdtEntry {
    pub base_lo: u16,
    pub selector: u16,
    pub reserved0: u8,
    pub flags: Flags,
    pub base_hi: u64,
    pub reserved1: u16,
}

An interrupt gate descriptor.

See Intel manual 3a for details, specifically section "6.14.1 64-Bit Mode IDT" and "Table 3-2. System-Segment and Gate-Descriptor Types".

Fields

base_lo: u16

Lower 16 bits of ISR.

selector: u16

Segment selector.

reserved0: u8

This must always be zero.

flags: Flags

Flags.

base_hi: u64

The upper 48 bits of ISR (the last 16 bits must be zero).

reserved1: u16

Must be zero.

Methods

impl IdtEntry
[src]

const MISSING: IdtEntry = IdtEntry{base_lo: 0, selector: 0, reserved0: 0, flags: Flags::BLANK, base_hi: 0, reserved1: 0,}

A "missing" IdtEntry.

If the CPU tries to invoke a missing interrupt, it will instead send a General Protection fault (13), with the interrupt number and some other data stored in the error code.

const fn new(handler: VAddr, gdt_code_selector: u16, dpl: PrivilegeLevel, block: bool) -> IdtEntry

Create a new IdtEntry pointing at handler, which must be a function with interrupt calling conventions. (This must be currently defined in assembly language.) The gdt_code_selector value must be the offset of code segment entry in the GDT.

The "Present" flag set, which is the most common case. If you need something else, you can construct it manually.

Trait Implementations

impl Copy for IdtEntry
[src]

impl Clone for IdtEntry
[src]

fn clone(&self) -> IdtEntry

Returns a copy of the value. Read more

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

Performs copy-assignment from source. Read more

impl Debug for IdtEntry
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.