X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/e776bb16043e55b91fdd3654f005dd8f00c9fb12..80890b99fec2630ef0a1a0805d894c3d86c16506:/lunaix-os/hal/ioapic.c diff --git a/lunaix-os/hal/ioapic.c b/lunaix-os/hal/ioapic.c index 80ab13b..de4be2a 100644 --- a/lunaix-os/hal/ioapic.c +++ b/lunaix-os/hal/ioapic.c @@ -22,8 +22,14 @@ ioapic_init() { // The ioapic_get_irq is to make sure we capture those overriden IRQs + // grab ourselves these irq numbers + uint8_t irq_rtc = ioapic_get_irq(acpi_ctx, PC_AT_IRQ_RTC); + uint8_t irq_kbd = ioapic_get_irq(acpi_ctx, PC_AT_IRQ_KBD); + // PC_AT_IRQ_RTC -> RTC_TIMER_IV, fixed, edge trigged, polarity=high, physical, APIC ID 0 - ioapic_redirect(ioapic_get_irq(acpi_ctx, PC_AT_IRQ_RTC), RTC_TIMER_IV, 0, IOAPIC_DELMOD_FIXED); + ioapic_redirect(irq_rtc, RTC_TIMER_IV, 0, IOAPIC_DELMOD_FIXED); + + ioapic_redirect(irq_kbd, PC_KBD_IV, 0, IOAPIC_DELMOD_FIXED); } uint8_t