KxWaitForLockOwnerShip

VOID __fastcall KxWaitForLockOwnerShip(INT64 a1){
  INT64 *v1; 
  UINT64 SpinCount; 

  *(_QWORD *)(a1 + 8) |= 1ui64;
  *v1 = a1;
  LODWORD(SpinCount) = 0;
  do
    KeYieldProcessorEx(&SpinCount);
  while( (*(_QWORD *)(a1 + 8) & 1) != 0 );
}

Referenced by:

CcCanIWrite
CcCanIWriteStreamEx
CcSetDirtyInMask
CcUnpinFileDataEx
ExReleaseResourceForThreadLite
ExReleaseResourceLite
ExpAcquireResourceExclusiveLite
ExpAcquireResourceSharedLite
ExpAcquireSharedStarveExclusive
ExpApplyPriorityBoost
ExpSetResourceOwnerPointerEx
ExpWorkerFactoryCheckCreate
ExpWorkerFactoryCompletionPacketRoutine
IoAcquireCancelSpinLock
IopCheckDeviceAndDriver
IopCheckVpbMounted
IopDecrementDeviceObjectRef
IopDereferenceVpbAndFree
IopGetMountFlag
IopIncrementDeviceObjectRefCount
IopfCompleteRequest
KeAcquireInStackQueuedSpinLock
KeAcquireInStackQueuedSpinLockAtDpcLevel
KeAcquireQueuedSpinLock
KxAcquireQueuedSpinLock
MiAddWorkingSetEntries
MiAgePte
MiAgeWorkingSet
MiCopyOnWrite
MiInsertPageInFreeOrZeroedList
MiInsertPageInList
MiInsertProtectedStandbyPage
MiLockPageTableInternal
MiLogPageAccess
MiProcessWorkingSets
MiRemoveWsle
MiSetVaAgeList
MiTrimOrAgeWorkingSet
MiUnlinkFreeOrZeroedPage
MiUnlinkPageFromList
MiZeroLargePageThread
NtReleaseWorkerFactoryWorker
NtSetInformationWorkerFactory
NtWaitForWorkViaWorkerFactory