[LIBS] Use KeClearEvent instead of KeResetEvent where the previous state is not needed.

This commit is contained in:
Thomas Faber 2017-12-30 11:46:57 +01:00
parent 2cb0c129a6
commit 008e035b7e
No known key found for this signature in database
GPG key ID: 076E7C3D44720826
3 changed files with 4 additions and 4 deletions

View file

@ -81,7 +81,7 @@ BOOLEAN ChewCreate(VOID (*Worker)(PVOID), PVOID WorkerContext)
Item->Worker = Worker; Item->Worker = Worker;
Item->WorkerContext = WorkerContext; Item->WorkerContext = WorkerContext;
ExInterlockedInsertTailList(&WorkQueue, &Item->Entry, &WorkQueueLock); ExInterlockedInsertTailList(&WorkQueue, &Item->Entry, &WorkQueueLock);
KeResetEvent(&WorkQueueClear); KeClearEvent(&WorkQueueClear);
IoQueueWorkItem(Item->WorkItem, ChewWorkItem, DelayedWorkQueue, Item); IoQueueWorkItem(Item->WorkItem, ChewWorkItem, DelayedWorkQueue, Item);
return TRUE; return TRUE;

View file

@ -4451,7 +4451,7 @@ RxCommonWrite(
1, 1,
&RxStrucSupSpinLock) == 0) &RxStrucSupSpinLock) == 0)
{ {
KeResetEvent(Fcb->NonPaged->OutstandingAsyncEvent); KeClearEvent(Fcb->NonPaged->OutstandingAsyncEvent);
} }
UnwindOutstandingAsync = TRUE; UnwindOutstandingAsync = TRUE;

View file

@ -7894,7 +7894,7 @@ RxScavengerTimerRoutine(
{ {
/* Done */ /* Done */
Scavenger->State = RDBSS_SCAVENGER_ACTIVE; Scavenger->State = RDBSS_SCAVENGER_ACTIVE;
KeResetEvent(&Scavenger->ScavengeEvent); KeClearEvent(&Scavenger->ScavengeEvent);
/* Scavenger the entries */ /* Scavenger the entries */
RxReleaseScavengerMutex(); RxReleaseScavengerMutex();
@ -7982,7 +7982,7 @@ RxSpinUpRequestsDispatcher(
{ {
ListEntry = &RxDispatcher->SpinUpRequests; ListEntry = &RxDispatcher->SpinUpRequests;
} }
KeResetEvent(&RxDispatcher->SpinUpRequestsEvent); KeClearEvent(&RxDispatcher->SpinUpRequestsEvent);
KeReleaseSpinLock(&RxDispatcher->SpinUpRequestsLock, OldIrql); KeReleaseSpinLock(&RxDispatcher->SpinUpRequestsLock, OldIrql);
while (ListEntry != &RxDispatcher->SpinUpRequests) while (ListEntry != &RxDispatcher->SpinUpRequests)