Changeset 20753 in vbox
- Timestamp:
- Jun 21, 2009 11:11:24 PM (15 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
include/VBox/pdmcritsect.h (modified) (1 diff)
-
src/VBox/VMM/PDMCritSect.cpp (modified) (2 diffs)
-
src/VBox/VMM/VMMAll/PDMAllCritSect.cpp (modified) (1 diff)
-
src/VBox/VMM/VMMGuruMeditation.cpp (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/pdmcritsect.h
r20374 r20753 71 71 VMMDECL(void) PDMCritSectFF(PVMCPU pVCpu); 72 72 VMMR3DECL(uint32_t) PDMR3CritSectCountOwned(PVM pVM, char *pszNames, size_t cbNames); 73 VMMR3DECL(void) PDMR3CritSectLeaveAll(PVM pVM); 73 74 74 75 /** @} */ -
trunk/src/VBox/VMM/PDMCritSect.cpp
r20087 r20753 26 26 #define LOG_GROUP LOG_GROUP_PDM//_CRITSECT 27 27 #include "PDMInternal.h" 28 #include <VBox/pdm .h>28 #include <VBox/pdmcritsect.h> 29 29 #include <VBox/mm.h> 30 30 #include <VBox/vm.h> … … 476 476 return cCritSects; 477 477 } 478 479 480 /** 481 * Leave all critical sections the calling thread owns. 482 * 483 * @param pVM The VM handle. 484 */ 485 void PDMR3CritSectLeaveAll(PVM pVM) 486 { 487 RTNATIVETHREAD const hNativeSelf = RTThreadNativeSelf(); 488 489 RTCritSectEnter(&pVM->pdm.s.MiscCritSect); 490 for (PPDMCRITSECTINT pCur = pVM->pdm.s.pCritSects; 491 pCur; 492 pCur = pCur->pNext) 493 { 494 while ( pCur->Core.NativeThreadOwner == hNativeSelf 495 && pCur->Core.cNestings > 0) 496 PDMCritSectLeave((PPDMCRITSECT)pCur); 497 } 498 RTCritSectLeave(&pVM->pdm.s.MiscCritSect); 499 } 500 -
trunk/src/VBox/VMM/VMMAll/PDMAllCritSect.cpp
r20702 r20753 26 26 #define LOG_GROUP LOG_GROUP_PDM//_CRITSECT 27 27 #include "PDMInternal.h" 28 #include <VBox/pdm .h>28 #include <VBox/pdmcritsect.h> 29 29 #include <VBox/mm.h> 30 30 #include <VBox/vm.h> -
trunk/src/VBox/VMM/VMMGuruMeditation.cpp
r19797 r20753 26 26 #include <VBox/vmm.h> 27 27 #include <VBox/pdmapi.h> 28 #include <VBox/pdmcritsect.h> 28 29 #include <VBox/trpm.h> 29 30 #include <VBox/dbgf.h> … … 213 214 214 215 /* Release owned locks to make sure other VCPUs can continue in case they were waiting for one. */ 216 #if 1 217 PDMR3CritSectLeaveAll(pVM); 218 #else 215 219 MMR3ReleaseOwnedLocks(pVM); 216 220 PGMR3ReleaseOwnedLocks(pVM); … … 218 222 IOMR3ReleaseOwnedLocks(pVM); 219 223 EMR3ReleaseOwnedLocks(pVM); 224 #endif 220 225 221 226 /*
Note:
See TracChangeset
for help on using the changeset viewer.

