[idd] common: use CSRWLock throughout the drivers

Make CSRWLock own the native lock and provide scoped guards for shared,
exclusive, early-unlock, and non-blocking use.

Replace direct SRW lock management throughout the IDD, input driver,
and helper while preserving the existing lock scopes.
This commit is contained in:
Geoffrey McRae
2026-08-11 22:06:31 +10:00
parent 2543366f5f
commit 61a49ebaba
37 changed files with 576 additions and 525 deletions

View File

@@ -575,7 +575,7 @@ void CD3D12CommandQueue::WaitForIdle()
bool CD3D12CommandQueue::Submit(CD3D12CommandSlot& slot)
{
bool result = false;
AcquireSRWLockExclusive(&m_submitLock);
CSRWExclusiveLock lock(m_submitLock);
do
{
@@ -636,7 +636,6 @@ bool CD3D12CommandQueue::Submit(CD3D12CommandSlot& slot)
}
while (false);
ReleaseSRWLockExclusive(&m_submitLock);
return result;
}