|
IgrOS-Kernel 0.1.34.545
Simple C++20 Kernel for i386/x86_64
|
Interrupts low-level operations. More...


Go to the source code of this file.
Classes | |
| class | igros::x86::irq |
| IRQ structure. More... | |
| class | igros::x86::irq::guard |
| Disable interrupts in scope (restores previous state on exit). More... | |
Namespaces | |
| namespace | igros |
| IgrOS kernel: common types and literals. | |
| namespace | igros::x86 |
| Code shared by i386 and x86_64: ports, interrupts, exceptions, paging. | |
Enumerations | |
| enum class | igros::x86::irq_t : igros_dword_t { PIT = 0_u32 , KEYBOARD = 1_u32 , igros::x86::CASCADE = 2_u32 , UART2 = 3_u32 , UART1 = 4_u32 , LPT2 = 5_u32 , FLOPPY = 6_u32 , igros::x86::LPT1 = 7_u32 , RTC = 8_u32 , ACPI = 9_u32 , FREE_10 = 10_u32 , FREE_11 = 11_u32 , MOUSE = 12_u32 , FPU = 13_u32 , ATA_PRIMARY = 14_u32 , igros::x86::ATA_SECONDARY = 15_u32 } |
| Interrupts number enumeration (PIC lines). More... | |
Functions | |
| auto | irqSave () noexcept -> igros::igros_usize_t |
| Save flags and disable interrupts. | |
| void | irqRestore (const igros::igros_usize_t flags) noexcept |
| Restore flags (interrupts state). | |
| constexpr auto | igros::x86::irqVector (const irq_t line) noexcept -> igros_usize_t |
| Interrupt vector of IRQ line. | |
| constexpr auto | igros::x86::isIrqVector (const igros_usize_t vector) noexcept -> bool |
| Check if interrupt vector belongs to IRQ line. | |
| constexpr auto | igros::x86::irqFromVector (const igros_usize_t vector) noexcept -> irq_t |
| IRQ line of interrupt vector (vector must be IRQ vector). | |
Variables | |
| const std::add_pointer_t< void() noexcept > | irqHandlerTable [16] |
| IRQ handlers addresses, indexed by IRQ line (irq.s). | |
| constexpr auto | igros::x86::PIC_MASTER_CONTROL {static_cast<port_t>(0x0020_u16)} |
| Master PIC command port. | |
| constexpr auto | igros::x86::PIC_MASTER_DATA {static_cast<port_t>(PIC_MASTER_CONTROL + 1_u16)} |
| Master PIC data (mask) port. | |
| constexpr auto | igros::x86::PIC_SLAVE_CONTROL {static_cast<port_t>(0x00A0_u16)} |
| Slave PIC command port. | |
| constexpr auto | igros::x86::PIC_SLAVE_DATA {static_cast<port_t>(PIC_SLAVE_CONTROL + 1_u16)} |
| Slave PIC data (mask) port. | |
| constexpr auto | igros::x86::IRQ_LINES {16_usize} |
| Number of PIC interrupt lines. | |
Interrupts low-level operations.
Definition in file irq.hpp.
|
noexcept |
Restore flags (interrupts state).
| flags | Flags register saved by irqSave() |
|
nodiscardnoexcept |
Save flags and disable interrupts.