mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-21 18:00:16 +00:00
Interrupts: Handle spurious IRQs from eoi() method
This commit is contained in:
parent
8d9b6c57b5
commit
5f579904c1
Notes:
sideshowbarker
2024-07-19 08:08:51 +09:00
Author: https://github.com/supercomputer7
Commit: 5f579904c1
Pull-request: https://github.com/SerenityOS/serenity/pull/1361
Reviewed-by: https://github.com/awesomekling
2 changed files with 8 additions and 3 deletions
|
@ -137,8 +137,13 @@ void PIC::eoi(const GenericInterruptHandler& handler) const
|
|||
{
|
||||
InterruptDisabler disabler;
|
||||
ASSERT(!is_hard_disabled());
|
||||
ASSERT(handler.interrupt_number() >= gsi_base() && handler.interrupt_number() < interrupt_vectors_count());
|
||||
eoi_interrupt(handler.interrupt_number());
|
||||
u8 irq = handler.interrupt_number();
|
||||
ASSERT(irq >= gsi_base() && irq < interrupt_vectors_count());
|
||||
if ((1 << irq) & m_cached_irq_mask) {
|
||||
spurious_eoi(handler);
|
||||
return;
|
||||
}
|
||||
eoi_interrupt(irq);
|
||||
}
|
||||
|
||||
void PIC::eoi_interrupt(u8 irq) const
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue