- Don't do the interrupt storm protection stuff for software interrupt

handlers.
- Use pause() when throtting during an interrupt storm.

Reported by:	kris (1)
This commit is contained in:
John Baldwin 2007-03-02 17:01:45 +00:00
parent 8dfa5ef704
commit e41bcf3cfc

View file

@ -696,14 +696,15 @@ ithread_execute_handlers(struct proc *p, struct intr_event *ie)
* number of back to back interrupts exceeds the storm threshold,
* then enter storming mode.
*/
if (intr_storm_threshold != 0 && ie->ie_count >= intr_storm_threshold) {
if (intr_storm_threshold != 0 && ie->ie_count >= intr_storm_threshold &&
!(ie->ie_flags & IE_SOFT)) {
if (ie->ie_warned == 0) {
printf(
"Interrupt storm detected on \"%s\"; throttling interrupt source\n",
ie->ie_name);
ie->ie_warned = 1;
}
tsleep(&ie->ie_count, 0, "istorm", 1);
pause("istorm", 1);
} else
ie->ie_count++;