mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 19:42:57 +00:00
[NTOSKRNL] Handle the PIN_WAIT flag in CcPinMappedData()
This commit is contained in:
parent
469e15c7ae
commit
c1dd4c142f
1 changed files with 5 additions and 4 deletions
|
@ -161,6 +161,7 @@ CcPinMappedData (
|
||||||
IN ULONG Flags,
|
IN ULONG Flags,
|
||||||
OUT PVOID * Bcb)
|
OUT PVOID * Bcb)
|
||||||
{
|
{
|
||||||
|
BOOLEAN Result;
|
||||||
PINTERNAL_BCB iBcb;
|
PINTERNAL_BCB iBcb;
|
||||||
PROS_SHARED_CACHE_MAP SharedCacheMap;
|
PROS_SHARED_CACHE_MAP SharedCacheMap;
|
||||||
|
|
||||||
|
@ -181,16 +182,16 @@ CcPinMappedData (
|
||||||
iBcb->Pinned = TRUE;
|
iBcb->Pinned = TRUE;
|
||||||
iBcb->Vacb->PinCount++;
|
iBcb->Vacb->PinCount++;
|
||||||
|
|
||||||
if (Flags & PIN_EXCLUSIVE)
|
if (BooleanFlagOn(Flags, PIN_EXCLUSIVE))
|
||||||
{
|
{
|
||||||
ExAcquireResourceExclusiveLite(&iBcb->Lock, TRUE);
|
Result = ExAcquireResourceExclusiveLite(&iBcb->Lock, BooleanFlagOn(Flags, PIN_WAIT));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ExAcquireResourceSharedLite(&iBcb->Lock, TRUE);
|
Result = ExAcquireResourceSharedLite(&iBcb->Lock, BooleanFlagOn(Flags, PIN_WAIT));
|
||||||
}
|
}
|
||||||
|
|
||||||
return TRUE;
|
return Result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue