intrng: Releasing interrupt source should clear interrupt table full state.
The first release of an interrupt in a situation where the interrupt table is full should schedule a full table check the next time an interrupt is allocated. A full check is necessary to ensure maximum separation between the order of allocation and the order of release. Submitted by: ehem_freebsd@m5p.com (initial version) Discussed in: https://reviews.freebsd.org/D29310 MFC after: 4 weeks
This commit is contained in:
parent
f39dd6a978
commit
a49f208d94
@ -447,6 +447,16 @@ isrc_free_irq(struct intr_irqsrc *isrc)
|
||||
|
||||
irq_sources[isrc->isrc_irq] = NULL;
|
||||
isrc->isrc_irq = INTR_IRQ_INVALID; /* just to be safe */
|
||||
|
||||
/*
|
||||
* If we are recovering from the state irq_sources table is full,
|
||||
* then the following allocation should check the entire table. This
|
||||
* will ensure maximum separation of allocation order from release
|
||||
* order.
|
||||
*/
|
||||
if (irq_next_free >= intr_nirq)
|
||||
irq_next_free = 0;
|
||||
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user