don't walk all the timers as they're sorted.

svn path=/trunk/; revision=13568
This commit is contained in:
Thomas Bluemel 2005-02-14 17:03:16 +00:00
parent f9f5d87742
commit 2e2b7b4073

View file

@ -245,15 +245,14 @@ KiExpireTimers(PKDPC Dpc,
Timer = CONTAINING_RECORD(CurrentEntry, KTIMER, TimerListEntry);
DPRINT("Looping for Timer: %x. Duetime: %I64d. InterruptTime %I64d \n", Timer, Timer->DueTime.QuadPart, InterruptTime);
CurrentEntry = CurrentEntry->Flink;
/* Check if we have to Expire it */
if (InterruptTime >= Timer->DueTime.QuadPart) {
if (InterruptTime < Timer->DueTime.QuadPart) break;
CurrentEntry = CurrentEntry->Flink;
/* Remove it from the Timer List, add it to the Expired List */
RemoveEntryList(&Timer->TimerListEntry);
InsertTailList(&ExpiredTimerList, &Timer->TimerListEntry);
}
/* Remove it from the Timer List, add it to the Expired List */
RemoveEntryList(&Timer->TimerListEntry);
InsertTailList(&ExpiredTimerList, &Timer->TimerListEntry);
}
/* Expire the Timers */