Searched defs:pCritSect (Results 1 - 20 of 20) sorted by relevance

/vbox/src/VBox/VMM/VMMAll/
H A DPDMAllCritSectBoth.cpp85 PPDMCRITSECT pCritSect = pVCpu->pdm.s.apQueuedCritSectLeaves[i]; local
87 PPDMCRITSECT pCritSect = (PPDMCRITSECT)MMHyperR3ToCC(pVCpu->CTX_SUFF(pVM), pVCpu->pdm.s.apQueuedCritSectLeaves[i]);
90 PDMCritSectLeave(pCritSect);
91 LogFlow(("PDMR3CritSectFF: %p\n", pCritSect));
H A DPDMAllCritSect.cpp64 * @param pCritSect The critical section. This is used in R0 and RC.
66 DECL_FORCE_INLINE(RTNATIVETHREAD) pdmCritSectGetNativeSelf(PCPDMCRITSECT pCritSect) argument
69 NOREF(pCritSect);
72 AssertMsgReturn(pCritSect->s.Core.u32Magic == RTCRITSECT_MAGIC, ("%RX32\n", pCritSect->s.Core.u32Magic),
74 PVM pVM = pCritSect->s.CTX_SUFF(pVM); AssertPtr(pVM);
87 * @param pCritSect The critical section.
90 DECL_FORCE_INLINE(int) pdmCritSectEnterFirst(PPDMCRITSECT pCritSect, RTNATIVETHREAD hNativeSelf, PCRTLOCKVALSRCPOS pSrcPos) argument
92 AssertMsg(pCritSect->s.Core.NativeThreadOwner == NIL_RTNATIVETHREAD, ("NativeThreadOwner=%p\n", pCritSect
120 pdmR3R0CritSectEnterContended(PPDMCRITSECT pCritSect, RTNATIVETHREAD hNativeSelf, PCRTLOCKVALSRCPOS pSrcPos) argument
215 pdmCritSectEnter(PPDMCRITSECT pCritSect, int rcBusy, PCRTLOCKVALSRCPOS pSrcPos) argument
355 PDMCritSectEnter(PPDMCRITSECT pCritSect, int rcBusy) argument
387 PDMCritSectEnterDebug(PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL) argument
410 pdmCritSectTryEnter(PPDMCRITSECT pCritSect, PCRTLOCKVALSRCPOS pSrcPos) argument
466 PDMCritSectTryEnter(PPDMCRITSECT pCritSect) argument
495 PDMCritSectTryEnterDebug(PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL) argument
519 PDMR3CritSectEnterEx(PPDMCRITSECT pCritSect, bool fCallRing3) argument
542 PDMCritSectLeave(PPDMCRITSECT pCritSect) argument
682 PDMCritSectIsOwner(PCPDMCRITSECT pCritSect) argument
705 PDMCritSectIsOwnerEx(PCPDMCRITSECT pCritSect, PVMCPU pVCpu) argument
727 PDMCritSectHasWaiters(PCPDMCRITSECT pCritSect) argument
742 PDMCritSectIsInitialized(PCPDMCRITSECT pCritSect) argument
754 PDMCritSectGetRecursion(PCPDMCRITSECT pCritSect) argument
[all...]
/vbox/include/VBox/vmm/
H A Dpdmcritsect.h61 VMMR3DECL(int) PDMR3CritSectInit(PVM pVM, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...);
62 VMMR3DECL(int) PDMR3CritSectEnterEx(PPDMCRITSECT pCritSect, bool fCallRing3);
63 VMMR3DECL(bool) PDMR3CritSectYield(PPDMCRITSECT pCritSect); variable
64 VMMR3DECL(const char *) PDMR3CritSectName(PCPDMCRITSECT pCritSect); variable
65 VMMR3DECL(int) PDMR3CritSectScheduleExitEvent(PPDMCRITSECT pCritSect, RTSEMEVENT EventToSignal);
66 VMMR3DECL(int) PDMR3CritSectDelete(PPDMCRITSECT pCritSect); variable
68 VMMDECL(int) PDMCritSectEnter(PPDMCRITSECT pCritSect, int rcBusy);
69 VMMDECL(int) PDMCritSectEnterDebug(PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL);
70 VMMDECL(int) PDMCritSectTryEnter(PPDMCRITSECT pCritSect); variable
71 VMMDECL(int) PDMCritSectTryEnterDebug(PPDMCRITSECT pCritSect, RTHCUINTPT
72 VMMDECL(int) PDMCritSectLeave(PPDMCRITSECT pCritSect); variable
74 VMMDECL(bool) PDMCritSectIsOwner(PCPDMCRITSECT pCritSect); variable
76 VMMDECL(bool) PDMCritSectIsInitialized(PCPDMCRITSECT pCritSect); variable
77 VMMDECL(bool) PDMCritSectHasWaiters(PCPDMCRITSECT pCritSect); variable
78 VMMDECL(uint32_t) PDMCritSectGetRecursion(PCPDMCRITSECT pCritSect); variable
[all...]
H A Dpdmcritsectrw.h53 VMMR3DECL(int) PDMR3CritSectRwInit(PVM pVM, PPDMCRITSECTRW pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...);
54 VMMR3DECL(int) PDMR3CritSectRwDelete(PPDMCRITSECTRW pCritSect); variable
55 VMMR3DECL(const char *) PDMR3CritSectRwName(PCPDMCRITSECTRW pCritSect); variable
59 VMMDECL(int) PDMCritSectRwEnterShared(PPDMCRITSECTRW pCritSect, int rcBusy);
60 VMMDECL(int) PDMCritSectRwEnterSharedDebug(PPDMCRITSECTRW pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL);
61 VMMDECL(int) PDMCritSectRwTryEnterShared(PPDMCRITSECTRW pCritSect); variable
62 VMMDECL(int) PDMCritSectRwTryEnterSharedDebug(PPDMCRITSECTRW pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL);
63 VMMDECL(int) PDMCritSectRwLeaveShared(PPDMCRITSECTRW pCritSect); variable
64 VMMDECL(int) PDMCritSectRwEnterExcl(PPDMCRITSECTRW pCritSect, int rcBusy);
65 VMMDECL(int) PDMCritSectRwEnterExclDebug(PPDMCRITSECTRW pCritSect, in
66 VMMDECL(int) PDMCritSectRwTryEnterExcl(PPDMCRITSECTRW pCritSect); variable
68 VMMDECL(int) PDMCritSectRwLeaveExcl(PPDMCRITSECTRW pCritSect); variable
70 VMMDECL(bool) PDMCritSectRwIsWriteOwner(PPDMCRITSECTRW pCritSect); variable
72 VMMDECL(uint32_t) PDMCritSectRwGetWriteRecursion(PPDMCRITSECTRW pCritSect); variable
73 VMMDECL(uint32_t) PDMCritSectRwGetWriterReadRecursion(PPDMCRITSECTRW pCritSect); variable
74 VMMDECL(uint32_t) PDMCritSectRwGetReadCount(PPDMCRITSECTRW pCritSect); variable
75 VMMDECL(bool) PDMCritSectRwIsInitialized(PCPDMCRITSECTRW pCritSect); variable
[all...]
H A Dpdmdrv.h1244 * @param pCritSect Pointer to the critical section.
1252 DECLR3CALLBACKMEMBER(int, pfnCritSectInit,(PPDMDRVINS pDrvIns, PPDMCRITSECT pCritSect,
1787 DECLINLINE(int) PDMDrvHlpCritSectInit(PPDMDRVINS pDrvIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszName) argument
1789 return pDrvIns->pHlpR3->pfnCritSectInit(pDrvIns, pCritSect, RT_SRC_POS_ARGS, pszName);
H A Dpdmdev.h3092 * @param pCritSect Pointer to the critical section.
3098 DECLR3CALLBACKMEMBER(int, pfnCritSectInit,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL,
3131 * @param pCritSect The critical section to use. NULL is not
3135 DECLR3CALLBACKMEMBER(int, pfnSetDeviceCritSect,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect));
4922 * @param pCritSect Pointer to the critical section.
4928 DECLINLINE(int) PDMDevHlpCritSectInit(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...) argument
4933 rc = pDevIns->pHlpR3->pfnCritSectInit(pDevIns, pCritSect, RT_SRC_POS_ARGS, pszNameFmt, va);
4965 DECLINLINE(int) PDMDevHlpSetDeviceCritSect(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) argument
4967 return pDevIns->pHlpR3->pfnSetDeviceCritSect(pDevIns, pCritSect);
/vbox/src/VBox/Runtime/generic/
H A Dsemfastmutex-generic.cpp42 PRTCRITSECT pCritSect = (PRTCRITSECT)RTMemAlloc(sizeof(RTCRITSECT)); local
43 if (!pCritSect)
46 int rc = RTCritSectInitEx(pCritSect, RTCRITSECT_FLAGS_NO_NESTING,
49 *phFastMtx = (RTSEMFASTMUTEX)pCritSect;
51 RTMemFree(pCritSect);
61 PRTCRITSECT pCritSect = (PRTCRITSECT)hFastMtx;
62 int rc = RTCritSectDelete(pCritSect);
64 RTMemFree(pCritSect);
H A Dcritsect-generic.cpp44 RTDECL(int) RTCritSectInit(PRTCRITSECT pCritSect) argument
46 return RTCritSectInitEx(pCritSect, 0, NIL_RTLOCKVALCLASS, RTLOCKVAL_SUB_CLASS_NONE, "RTCritSect");
51 RTDECL(int) RTCritSectInitEx(PRTCRITSECT pCritSect, uint32_t fFlags, RTLOCKVALCLASS hClass, uint32_t uSubClass, argument
60 pCritSect->u32Magic = RTCRITSECT_MAGIC;
62 pCritSect->fFlags = fFlags | RTCRITSECT_FLAGS_RING0;
64 pCritSect->fFlags = fFlags & ~RTCRITSECT_FLAGS_RING0;
66 pCritSect->cNestings = 0;
67 pCritSect->cLockers = -1;
68 pCritSect->NativeThreadOwner = NIL_RTNATIVETHREAD;
69 pCritSect
119 RTCritSectSetSubClass(PRTCRITSECT pCritSect, uint32_t uSubClass) argument
132 rtCritSectTryEnter(PRTCRITSECT pCritSect, PCRTLOCKVALSRCPOS pSrcPos) argument
190 RTCritSectTryEnter(PRTCRITSECT pCritSect) argument
202 RTCritSectTryEnterDebug(PRTCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL) argument
210 rtCritSectEnter(PRTCRITSECT pCritSect, PCRTLOCKVALSRCPOS pSrcPos) argument
320 RTCritSectEnter(PRTCRITSECT pCritSect) argument
332 RTCritSectEnterDebug(PRTCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL) argument
340 RTCritSectLeave(PRTCRITSECT pCritSect) argument
511 RTCritSectDelete(PRTCRITSECT pCritSect) argument
[all...]
/vbox/src/VBox/Runtime/r3/generic/
H A Dsemspinmutex-r3-generic.cpp46 PRTCRITSECT pCritSect = (PRTCRITSECT)RTMemAlloc(sizeof(RTCRITSECT)); local
47 if (!pCritSect)
49 int rc = RTCritSectInitEx(pCritSect, RTCRITSECT_FLAGS_NO_NESTING | RTCRITSECT_FLAGS_NO_LOCK_VAL,
52 *phSpinMtx = (RTSEMSPINMUTEX)pCritSect;
54 RTMemFree(pCritSect);
64 PRTCRITSECT pCritSect = (PRTCRITSECT)hSpinMtx;
65 int rc = RTCritSectDelete(pCritSect);
67 RTMemFree(pCritSect);
/vbox/src/VBox/Runtime/r3/win/
H A Dvcc100-kernel32-fakes.cpp82 InitializeCriticalSectionAndSpinCount(LPCRITICAL_SECTION pCritSect, DWORD cSpin) argument
88 InitializeCriticalSection(pCritSect);
/vbox/src/VBox/Runtime/testcase/
H A DtstRTCritSect.cpp62 DECLINLINE(int) RTCritSectInit(PCRITICAL_SECTION pCritSect) argument
64 InitializeCriticalSection(pCritSect);
68 DECLINLINE(int) RTCritSectEnter(PCRITICAL_SECTION pCritSect) argument
70 EnterCriticalSection(pCritSect);
74 DECLINLINE(int) RTCritSectLeave(PCRITICAL_SECTION pCritSect) argument
76 LeaveCriticalSection(pCritSect);
80 DECLINLINE(int) RTCritSectDelete(PCRITICAL_SECTION pCritSect) argument
82 DeleteCriticalSection(pCritSect);
98 PRTCRITSECT pCritSect; member in struct:THREADTEST1ARGS
112 PRTCRITSECT pCritSect; member in struct:THREADTEST2ARGS
[all...]
H A DtstRTLockValidator.cpp127 PRTCRITSECT pCritSect = (PRTCRITSECT)pvWhat; local
128 if (!RTCritSectIsInitialized(pCritSect))
130 if (RTCritSectIsOwned(pCritSect))
136 static int testWaitForCritSectToBeOwned(PRTCRITSECT pCritSect) argument
138 return testWaitForSomethingToBeOwned(testCheckIfCritSectIsOwned, pCritSect);
/vbox/include/iprt/
H A Dcritsect.h120 RTDECL(int) RTCritSectInit(PRTCRITSECT pCritSect); variable
126 * @param pCritSect Pointer to the critical section structure.
138 RTDECL(int) RTCritSectInitEx(PRTCRITSECT pCritSect, uint32_t fFlags,
150 * @param pCritSect The critical section.
153 RTDECL(uint32_t) RTCritSectSetSubClass(PRTCRITSECT pCritSect, uint32_t uSubClass);
162 * @param pCritSect The critical section.
164 RTDECL(int) RTCritSectEnter(PRTCRITSECT pCritSect); variable
175 * @param pCritSect The critical section.
181 RTDECL(int) RTCritSectEnterDebug(PRTCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL);
192 * @param pCritSect Th
194 RTDECL(int) RTCritSectTryEnter(PRTCRITSECT pCritSect); variable
262 RTDECL(int) RTCritSectLeave(PRTCRITSECT pCritSect); variable
279 RTDECL(int) RTCritSectDelete(PRTCRITSECT pCritSect); variable
288 RTCritSectIsOwner(PCRTCRITSECT pCritSect) argument
302 RTCritSectIsOwned(PCRTCRITSECT pCritSect) argument
314 RTCritSectGetOwner(PCRTCRITSECT pCritSect) argument
326 RTCritSectIsInitialized(PCRTCRITSECT pCritSect) argument
337 RTCritSectGetRecursion(PCRTCRITSECT pCritSect) argument
348 RTCritSectGetWaiters(PCRTCRITSECT pCritSect) argument
[all...]
/vbox/src/VBox/VMM/include/
H A DSSMInternal.h230 PPDMCRITSECT pCritSect; member in struct:SSMUNIT
H A DTMInternal.h194 R3PTRTYPE(PPDMCRITSECT) pCritSect; member in struct:TMTIMER
/vbox/src/VBox/VMM/VMMR3/
H A DPDMCritSect.cpp43 static int pdmR3CritSectDeleteOne(PVM pVM, PUVM pUVM, PPDMCRITSECTINT pCritSect, PPDMCRITSECTINT pPrev, bool fFinal);
44 static int pdmR3CritSectRwDeleteOne(PVM pVM, PUVM pUVM, PPDMCRITSECTRWINT pCritSect, PPDMCRITSECTRWINT pPrev, bool fFinal);
132 * @param pCritSect The critical section.
140 static int pdmR3CritSectInitOne(PVM pVM, PPDMCRITSECTINT pCritSect, void *pvKey, RT_SRC_POS_DECL, argument
144 Assert(pCritSect->Core.u32Magic != RTCRITSECT_MAGIC);
149 AssertCompile(sizeof(SUPSEMEVENT) == sizeof(pCritSect->Core.EventSem));
150 int rc = SUPSemEventCreate(pVM->pSession, (PSUPSEMEVENT)&pCritSect->Core.EventSem);
158 pCritSect->Core.pValidatorRec = NULL;
160 rc = RTLockValidatorRecExclCreate(&pCritSect->Core.pValidatorRec,
167 pCritSect, tru
227 pdmR3CritSectRwInitOne(PVM pVM, PPDMCRITSECTRWINT pCritSect, void *pvKey, RT_SRC_POS_DECL, const char *pszNameFmt, va_list va) argument
333 PDMR3CritSectInit(PVM pVM, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...) argument
363 PDMR3CritSectRwInit(PVM pVM, PPDMCRITSECTRW pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...) argument
388 pdmR3CritSectInitDevice(PVM pVM, PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, va_list va) argument
406 pdmR3CritSectRwInitDevice(PVM pVM, PPDMDEVINS pDevIns, PPDMCRITSECTRW pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, va_list va) argument
421 pdmR3CritSectInitDeviceAuto(PVM pVM, PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...) argument
445 pdmR3CritSectInitDriver(PVM pVM, PPDMDRVINS pDrvIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...) argument
467 pdmR3CritSectRwInitDriver(PVM pVM, PPDMDRVINS pDrvIns, PPDMCRITSECTRW pCritSect, RT_SRC_POS_DECL, const char *pszNameFmt, ...) argument
490 pdmR3CritSectDeleteOne(PVM pVM, PUVM pUVM, PPDMCRITSECTINT pCritSect, PPDMCRITSECTINT pPrev, bool fFinal) argument
547 pdmR3CritSectRwDeleteOne(PVM pVM, PUVM pUVM, PPDMCRITSECTRWINT pCritSect, PPDMCRITSECTRWINT pPrev, bool fFinal) argument
722 PDMR3CritSectDelete(PPDMCRITSECT pCritSect) argument
761 PDMR3CritSectRwDelete(PPDMCRITSECTRW pCritSect) argument
802 PDMR3CritSectName(PCPDMCRITSECT pCritSect) argument
818 PDMR3CritSectRwName(PCPDMCRITSECTRW pCritSect) argument
836 PDMR3CritSectYield(PPDMCRITSECT pCritSect) argument
897 PDMR3CritSectScheduleExitEvent(PPDMCRITSECT pCritSect, RTSEMEVENT EventToSignal) argument
[all...]
H A DPDMDevice.cpp311 PPDMCRITSECT pCritSect; local
313 rc = MMHyperAlloc(pVM, sizeof(*pCritSect), 0, MM_TAG_PDM_DEVICE, (void **)&pCritSect);
315 rc = MMR3HeapAllocZEx(pVM, MM_TAG_PDM_DEVICE, sizeof(*pCritSect), (void **)&pCritSect);
353 pDevIns->pCritSectRoR3 = pCritSect;
355 ? MMHyperR3ToRC(pVM, pCritSect) : NIL_RTRCPTR;
357 ? MMHyperR3ToR0(pVM, pCritSect) : NIL_RTR0PTR;
359 rc = pdmR3CritSectInitDeviceAuto(pVM, pDevIns, pCritSect, RT_SRC_POS,
874 PPDMCRITSECT pCritSect local
[all...]
H A DPDMDriver.cpp1666 static DECLCALLBACK(int) pdmR3DrvHlp_CritSectInit(PPDMDRVINS pDrvIns, PPDMCRITSECT pCritSect, argument
1672 LogFlow(("pdmR3DrvHlp_CritSectInit: caller='%s'/%d: pCritSect=%p pszName=%s\n",
1673 pDrvIns->pReg->szName, pDrvIns->iInstance, pCritSect, pszName));
1675 int rc = pdmR3CritSectInitDriver(pVM, pDrvIns, pCritSect, RT_SRC_POS_ARGS, "%s_%u", pszName, pDrvIns->iInstance);
H A DTM.cpp1412 pTimer->pCritSect = NULL;
1463 (*ppTimer)->pCritSect = PDMR3DevGetCritSect(pVM, pDevIns);
1506 // (*ppTimer)->pCritSect = pUsbIns->pCritSectR3;
1508 // (*ppTimer)->pCritSect = IOMR3GetCritSect(pVM);
1637 AssertMsg( !pTimer->pCritSect
1639 || PDMCritSectIsOwner(pTimer->pCritSect), ("%s\n", pTimer->pszDesc));
2110 PPDMCRITSECT pCritSect = pTimer->pCritSect; local
2111 if (pCritSect)
2112 PDMCritSectEnter(pCritSect, VERR_IGNORE
2297 PPDMCRITSECT pCritSect = pTimer->pCritSect; local
2617 PPDMCRITSECT pCritSect = pTimer->pCritSect; local
2688 TMR3TimerSetCritSect(PTMTIMERR3 pTimer, PPDMCRITSECT pCritSect) argument
[all...]
/vbox/src/VBox/Runtime/r3/
H A Dstream.cpp95 PRTCRITSECT pCritSect; member in struct:RTSTREAM
164 Assert(pStream->pCritSect == NULL);
166 PRTCRITSECT pCritSect = (PRTCRITSECT)RTMemAlloc(sizeof(*pCritSect)); local
167 if (!pCritSect)
171 int rc = RTCritSectInitEx(pCritSect, RTCRITSECT_FLAGS_NO_NESTING,
175 rc = RTCritSectEnter(pCritSect);
178 if (RT_LIKELY(ASMAtomicCmpXchgPtr(&pStream->pCritSect, pCritSect, NULL)))
181 RTCritSectLeave(pCritSect);
[all...]

Completed in 119 milliseconds