- Timestamp:
- Sep 9, 2019 2:02:22 PM (5 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/vmm/pdmcritsect.h
r80268 r80673 65 65 const char *pszNameFmt, ...) RT_IPRT_FORMAT_ATTR(6, 7); 66 66 VMMR3DECL(int) PDMR3CritSectEnterEx(PPDMCRITSECT pCritSect, bool fCallRing3); 67 VMMR3DECL(bool) PDMR3CritSectYield(P PDMCRITSECT pCritSect);67 VMMR3DECL(bool) PDMR3CritSectYield(PVM pVM, PPDMCRITSECT pCritSect); 68 68 VMMR3DECL(const char *) PDMR3CritSectName(PCPDMCRITSECT pCritSect); 69 69 VMMR3DECL(int) PDMR3CritSectDelete(PPDMCRITSECT pCritSect); -
trunk/include/VBox/vmm/pdmdev.h
r80641 r80673 3579 3579 /** @name Exported PDM Critical Section Functions 3580 3580 * @{ */ 3581 DECLR3CALLBACKMEMBER(bool, pfnCritSectYield,(PPDM CRITSECT pCritSect));3582 DECLR3CALLBACKMEMBER(int, pfnCritSectEnter,(PPDM CRITSECT pCritSect, int rcBusy));3583 DECLR3CALLBACKMEMBER(int, pfnCritSectEnterDebug,(PPDM CRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL));3584 DECLR3CALLBACKMEMBER(int, pfnCritSectTryEnter,(PPDM CRITSECT pCritSect));3585 DECLR3CALLBACKMEMBER(int, pfnCritSectTryEnterDebug,(PPDM CRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL));3586 DECLR3CALLBACKMEMBER(int, pfnCritSectLeave,(PPDM CRITSECT pCritSect));3587 DECLR3CALLBACKMEMBER(bool, pfnCritSectIsOwner,(P CPDMCRITSECT pCritSect));3588 DECLR3CALLBACKMEMBER(bool, pfnCritSectIsInitialized,(P CPDMCRITSECT pCritSect));3589 DECLR3CALLBACKMEMBER(bool, pfnCritSectHasWaiters,(P CPDMCRITSECT pCritSect));3590 DECLR3CALLBACKMEMBER(uint32_t, pfnCritSectGetRecursion,(P CPDMCRITSECT pCritSect));3581 DECLR3CALLBACKMEMBER(bool, pfnCritSectYield,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 3582 DECLR3CALLBACKMEMBER(int, pfnCritSectEnter,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy)); 3583 DECLR3CALLBACKMEMBER(int, pfnCritSectEnterDebug,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL)); 3584 DECLR3CALLBACKMEMBER(int, pfnCritSectTryEnter,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 3585 DECLR3CALLBACKMEMBER(int, pfnCritSectTryEnterDebug,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL)); 3586 DECLR3CALLBACKMEMBER(int, pfnCritSectLeave,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 3587 DECLR3CALLBACKMEMBER(bool, pfnCritSectIsOwner,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 3588 DECLR3CALLBACKMEMBER(bool, pfnCritSectIsInitialized,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 3589 DECLR3CALLBACKMEMBER(bool, pfnCritSectHasWaiters,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 3590 DECLR3CALLBACKMEMBER(uint32_t, pfnCritSectGetRecursion,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 3591 3591 /** @} */ 3592 3592 … … 4547 4547 /** @name Exported PDM Critical Section Functions 4548 4548 * @{ */ 4549 DECLRCCALLBACKMEMBER(int, pfnCritSectEnter,(PPDM CRITSECT pCritSect, int rcBusy));4550 DECLRCCALLBACKMEMBER(int, pfnCritSectEnterDebug,(PPDM CRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL));4551 DECLRCCALLBACKMEMBER(int, pfnCritSectTryEnter,(PPDM CRITSECT pCritSect));4552 DECLRCCALLBACKMEMBER(int, pfnCritSectTryEnterDebug,(PPDM CRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL));4553 DECLRCCALLBACKMEMBER(int, pfnCritSectLeave,(PPDM CRITSECT pCritSect));4554 DECLRCCALLBACKMEMBER(bool, pfnCritSectIsOwner,(P CPDMCRITSECT pCritSect));4555 DECLRCCALLBACKMEMBER(bool, pfnCritSectIsInitialized,(P CPDMCRITSECT pCritSect));4556 DECLRCCALLBACKMEMBER(bool, pfnCritSectHasWaiters,(P CPDMCRITSECT pCritSect));4557 DECLRCCALLBACKMEMBER(uint32_t, pfnCritSectGetRecursion,(P CPDMCRITSECT pCritSect));4549 DECLRCCALLBACKMEMBER(int, pfnCritSectEnter,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy)); 4550 DECLRCCALLBACKMEMBER(int, pfnCritSectEnterDebug,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL)); 4551 DECLRCCALLBACKMEMBER(int, pfnCritSectTryEnter,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 4552 DECLRCCALLBACKMEMBER(int, pfnCritSectTryEnterDebug,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL)); 4553 DECLRCCALLBACKMEMBER(int, pfnCritSectLeave,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 4554 DECLRCCALLBACKMEMBER(bool, pfnCritSectIsOwner,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4555 DECLRCCALLBACKMEMBER(bool, pfnCritSectIsInitialized,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4556 DECLRCCALLBACKMEMBER(bool, pfnCritSectHasWaiters,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4557 DECLRCCALLBACKMEMBER(uint32_t, pfnCritSectGetRecursion,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4558 4558 /** @} */ 4559 4559 … … 4919 4919 /** @name Exported PDM Critical Section Functions 4920 4920 * @{ */ 4921 DECLR0CALLBACKMEMBER(int, pfnCritSectEnter,(PPDM CRITSECT pCritSect, int rcBusy));4922 DECLR0CALLBACKMEMBER(int, pfnCritSectEnterDebug,(PPDM CRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL));4923 DECLR0CALLBACKMEMBER(int, pfnCritSectTryEnter,(PPDM CRITSECT pCritSect));4924 DECLR0CALLBACKMEMBER(int, pfnCritSectTryEnterDebug,(PPDM CRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL));4925 DECLR0CALLBACKMEMBER(int, pfnCritSectLeave,(PPDM CRITSECT pCritSect));4926 DECLR0CALLBACKMEMBER(bool, pfnCritSectIsOwner,(P CPDMCRITSECT pCritSect));4927 DECLR0CALLBACKMEMBER(bool, pfnCritSectIsInitialized,(P CPDMCRITSECT pCritSect));4928 DECLR0CALLBACKMEMBER(bool, pfnCritSectHasWaiters,(P CPDMCRITSECT pCritSect));4929 DECLR0CALLBACKMEMBER(uint32_t, pfnCritSectGetRecursion,(P CPDMCRITSECT pCritSect));4921 DECLR0CALLBACKMEMBER(int, pfnCritSectEnter,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy)); 4922 DECLR0CALLBACKMEMBER(int, pfnCritSectEnterDebug,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL)); 4923 DECLR0CALLBACKMEMBER(int, pfnCritSectTryEnter,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 4924 DECLR0CALLBACKMEMBER(int, pfnCritSectTryEnterDebug,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL)); 4925 DECLR0CALLBACKMEMBER(int, pfnCritSectLeave,(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)); 4926 DECLR0CALLBACKMEMBER(bool, pfnCritSectIsOwner,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4927 DECLR0CALLBACKMEMBER(bool, pfnCritSectIsInitialized,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4928 DECLR0CALLBACKMEMBER(bool, pfnCritSectHasWaiters,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4929 DECLR0CALLBACKMEMBER(uint32_t, pfnCritSectGetRecursion,(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect)); 4930 4930 /** @} */ 4931 4931 … … 6509 6509 DECLINLINE(int) PDMDevHlpCritSectEnter(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy) 6510 6510 { 6511 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectEnter(p CritSect, rcBusy);6511 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectEnter(pDevIns, pCritSect, rcBusy); 6512 6512 } 6513 6513 … … 6518 6518 DECLINLINE(int) PDMDevHlpCritSectEnterDebug(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL) 6519 6519 { 6520 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectEnterDebug(p CritSect, rcBusy, uId, RT_SRC_POS_ARGS);6520 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectEnterDebug(pDevIns, pCritSect, rcBusy, uId, RT_SRC_POS_ARGS); 6521 6521 } 6522 6522 … … 6527 6527 DECLINLINE(int) PDMDevHlpCritSectTryEnter(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 6528 6528 { 6529 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectTryEnter(p CritSect);6529 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectTryEnter(pDevIns, pCritSect); 6530 6530 } 6531 6531 … … 6536 6536 DECLINLINE(int) PDMDevHlpCritSectTryEnterDebug(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL) 6537 6537 { 6538 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectTryEnterDebug(p CritSect, uId, RT_SRC_POS_ARGS);6538 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectTryEnterDebug(pDevIns, pCritSect, uId, RT_SRC_POS_ARGS); 6539 6539 } 6540 6540 … … 6545 6545 DECLINLINE(int) PDMDevHlpCritSectLeave(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 6546 6546 { 6547 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectLeave(p CritSect);6547 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectLeave(pDevIns, pCritSect); 6548 6548 } 6549 6549 … … 6554 6554 DECLINLINE(bool) PDMDevHlpCritSectIsOwner(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 6555 6555 { 6556 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectIsOwner(p CritSect);6556 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectIsOwner(pDevIns, pCritSect); 6557 6557 } 6558 6558 … … 6563 6563 DECLINLINE(bool) PDMDevHlpCritSectIsInitialized(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 6564 6564 { 6565 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectIsInitialized(p CritSect);6565 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectIsInitialized(pDevIns, pCritSect); 6566 6566 } 6567 6567 … … 6572 6572 DECLINLINE(bool) PDMDevHlpCritSectHasWaiters(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 6573 6573 { 6574 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectHasWaiters(p CritSect);6574 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectHasWaiters(pDevIns, pCritSect); 6575 6575 } 6576 6576 … … 6581 6581 DECLINLINE(uint32_t) PDMDevHlpCritSectGetRecursion(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 6582 6582 { 6583 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectGetRecursion(p CritSect);6583 return pDevIns->CTX_SUFF(pHlp)->pfnCritSectGetRecursion(pDevIns, pCritSect); 6584 6584 } 6585 6585 -
trunk/src/VBox/VMM/VMMR0/PDMR0Device.cpp
r80641 r80673 658 658 } 659 659 660 660 661 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectGetNop} */ 661 662 static DECLCALLBACK(PPDMCRITSECT) pdmR0DevHlp_CritSectGetNop(PPDMDEVINS pDevIns) … … 668 669 return pCritSect; 669 670 } 671 670 672 671 673 /** @interface_method_impl{PDMDEVHLPR0,pfnSetDeviceCritSect} */ … … 699 701 } 700 702 703 704 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectEnter} */ 705 static DECLCALLBACK(int) pdmR0DevHlp_CritSectEnter(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy) 706 { 707 PDMDEV_ASSERT_DEVINS(pDevIns); 708 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 709 return PDMCritSectEnter(pCritSect, rcBusy); 710 } 711 712 713 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectEnterDebug} */ 714 static DECLCALLBACK(int) pdmR0DevHlp_CritSectEnterDebug(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL) 715 { 716 PDMDEV_ASSERT_DEVINS(pDevIns); 717 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 718 return PDMCritSectEnterDebug(pCritSect, rcBusy, uId, RT_SRC_POS_ARGS); 719 } 720 721 722 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectTryEnter} */ 723 static DECLCALLBACK(int) pdmR0DevHlp_CritSectTryEnter(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 724 { 725 PDMDEV_ASSERT_DEVINS(pDevIns); 726 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 727 return PDMCritSectTryEnter(pCritSect); 728 } 729 730 731 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectTryEnterDebug} */ 732 static DECLCALLBACK(int) pdmR0DevHlp_CritSectTryEnterDebug(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL) 733 { 734 PDMDEV_ASSERT_DEVINS(pDevIns); 735 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 736 return PDMCritSectTryEnterDebug(pCritSect, uId, RT_SRC_POS_ARGS); 737 } 738 739 740 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectLeave} */ 741 static DECLCALLBACK(int) pdmR0DevHlp_CritSectLeave(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 742 { 743 PDMDEV_ASSERT_DEVINS(pDevIns); 744 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 745 return PDMCritSectLeave(pCritSect); 746 } 747 748 749 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectIsOwner} */ 750 static DECLCALLBACK(bool) pdmR0DevHlp_CritSectIsOwner(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 751 { 752 PDMDEV_ASSERT_DEVINS(pDevIns); 753 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 754 return PDMCritSectIsOwner(pCritSect); 755 } 756 757 758 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectIsOwnerEx} */ 759 static DECLCALLBACK(bool) pdmR0DevHlp_CritSectIsOwnerEx(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect, PVMCPUCC pVCpu) 760 { 761 PDMDEV_ASSERT_DEVINS(pDevIns); 762 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pGVM to the crit sect code. */ 763 return PDMCritSectIsOwnerEx(pCritSect, pVCpu); 764 } 765 766 767 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectIsInitialized} */ 768 static DECLCALLBACK(bool) pdmR0DevHlp_CritSectIsInitialized(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 769 { 770 PDMDEV_ASSERT_DEVINS(pDevIns); 771 RT_NOREF(pDevIns); 772 return PDMCritSectIsInitialized(pCritSect); 773 } 774 775 776 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectHasWaiters} */ 777 static DECLCALLBACK(bool) pdmR0DevHlp_CritSectHasWaiters(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 778 { 779 PDMDEV_ASSERT_DEVINS(pDevIns); 780 RT_NOREF(pDevIns); 781 return PDMCritSectHasWaiters(pCritSect); 782 } 783 784 785 /** @interface_method_impl{PDMDEVHLPR0,pfnCritSectGetRecursion} */ 786 static DECLCALLBACK(uint32_t) pdmR0DevHlp_CritSectGetRecursion(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 787 { 788 PDMDEV_ASSERT_DEVINS(pDevIns); 789 RT_NOREF(pDevIns); 790 return PDMCritSectGetRecursion(pCritSect); 791 } 792 793 701 794 /** @interface_method_impl{PDMDEVHLPR0,pfnDBGFTraceBuf} */ 702 795 static DECLCALLBACK(RTTRACEBUF) pdmR0DevHlp_DBGFTraceBuf(PPDMDEVINS pDevIns) … … 704 797 PDMDEV_ASSERT_DEVINS(pDevIns); 705 798 RTTRACEBUF hTraceBuf = pDevIns->Internal.s.pGVM->hTraceBufR0; 706 LogFlow(("pdmR 3DevHlp_DBGFTraceBuf: caller='%p'/%d: returns %p\n", pDevIns, pDevIns->iInstance, hTraceBuf));799 LogFlow(("pdmR0DevHlp_DBGFTraceBuf: caller='%p'/%d: returns %p\n", pDevIns, pDevIns->iInstance, hTraceBuf)); 707 800 return hTraceBuf; 708 801 } … … 756 849 pdmR0DevHlp_CritSectGetNop, 757 850 pdmR0DevHlp_SetDeviceCritSect, 758 PDMCritSectEnter,759 PDMCritSectEnterDebug,760 PDMCritSectTryEnter,761 PDMCritSectTryEnterDebug,762 PDMCritSectLeave,763 PDMCritSectIsOwner,764 PDMCritSectIsInitialized,765 PDMCritSectHasWaiters,766 PDMCritSectGetRecursion,851 pdmR0DevHlp_CritSectEnter, 852 pdmR0DevHlp_CritSectEnterDebug, 853 pdmR0DevHlp_CritSectTryEnter, 854 pdmR0DevHlp_CritSectTryEnterDebug, 855 pdmR0DevHlp_CritSectLeave, 856 pdmR0DevHlp_CritSectIsOwner, 857 pdmR0DevHlp_CritSectIsInitialized, 858 pdmR0DevHlp_CritSectHasWaiters, 859 pdmR0DevHlp_CritSectGetRecursion, 767 860 pdmR0DevHlp_DBGFTraceBuf, 768 861 NULL /*pfnReserved1*/, -
trunk/src/VBox/VMM/VMMR3/PDMCritSect.cpp
r80334 r80673 841 841 * @retval true if yielded. 842 842 * @retval false if not yielded. 843 * @param pVM The cross context VM structure. 843 844 * @param pCritSect The critical section. 844 845 */ 845 VMMR3DECL(bool) PDMR3CritSectYield(P PDMCRITSECT pCritSect)846 VMMR3DECL(bool) PDMR3CritSectYield(PVM pVM, PPDMCRITSECT pCritSect) 846 847 { 847 848 AssertPtrReturn(pCritSect, false); … … 849 850 Assert(pCritSect->s.Core.NativeThreadOwner == RTThreadNativeSelf()); 850 851 Assert(!(pCritSect->s.Core.fFlags & RTCRITSECT_FLAGS_NOP)); 852 RT_NOREF(pVM); 851 853 852 854 /* No recursion allowed here. */ -
trunk/src/VBox/VMM/VMMR3/PDMDevHlp.cpp
r80641 r80673 2488 2488 LogFlow(("pdmR3DevHlp_SetDeviceCritSect: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, VINF_SUCCESS)); 2489 2489 return VINF_SUCCESS; 2490 } 2491 2492 2493 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectYield} */ 2494 static DECLCALLBACK(bool) pdmR3DevHlp_CritSectYield(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 2495 { 2496 PDMDEV_ASSERT_DEVINS(pDevIns); 2497 return PDMR3CritSectYield(pDevIns->Internal.s.pVMR3, pCritSect); 2498 } 2499 2500 2501 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectEnter} */ 2502 static DECLCALLBACK(int) pdmR3DevHlp_CritSectEnter(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy) 2503 { 2504 PDMDEV_ASSERT_DEVINS(pDevIns); 2505 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2506 return PDMCritSectEnter(pCritSect, rcBusy); 2507 } 2508 2509 2510 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectEnterDebug} */ 2511 static DECLCALLBACK(int) pdmR3DevHlp_CritSectEnterDebug(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, int rcBusy, RTHCUINTPTR uId, RT_SRC_POS_DECL) 2512 { 2513 PDMDEV_ASSERT_DEVINS(pDevIns); 2514 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2515 return PDMCritSectEnterDebug(pCritSect, rcBusy, uId, RT_SRC_POS_ARGS); 2516 } 2517 2518 2519 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectTryEnter} */ 2520 static DECLCALLBACK(int) pdmR3DevHlp_CritSectTryEnter(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 2521 { 2522 PDMDEV_ASSERT_DEVINS(pDevIns); 2523 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2524 return PDMCritSectTryEnter(pCritSect); 2525 } 2526 2527 2528 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectTryEnterDebug} */ 2529 static DECLCALLBACK(int) pdmR3DevHlp_CritSectTryEnterDebug(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RTHCUINTPTR uId, RT_SRC_POS_DECL) 2530 { 2531 PDMDEV_ASSERT_DEVINS(pDevIns); 2532 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2533 return PDMCritSectTryEnterDebug(pCritSect, uId, RT_SRC_POS_ARGS); 2534 } 2535 2536 2537 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectLeave} */ 2538 static DECLCALLBACK(int) pdmR3DevHlp_CritSectLeave(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect) 2539 { 2540 PDMDEV_ASSERT_DEVINS(pDevIns); 2541 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2542 return PDMCritSectLeave(pCritSect); 2543 } 2544 2545 2546 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectIsOwner} */ 2547 static DECLCALLBACK(bool) pdmR3DevHlp_CritSectIsOwner(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 2548 { 2549 PDMDEV_ASSERT_DEVINS(pDevIns); 2550 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2551 return PDMCritSectIsOwner(pCritSect); 2552 } 2553 2554 2555 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectIsOwnerEx} */ 2556 static DECLCALLBACK(bool) pdmR3DevHlp_CritSectIsOwnerEx(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect, PVMCPUCC pVCpu) 2557 { 2558 PDMDEV_ASSERT_DEVINS(pDevIns); 2559 RT_NOREF(pDevIns); /** @todo pass pDevIns->Internal.s.pVMR3 to the crit sect code. */ 2560 return PDMCritSectIsOwnerEx(pCritSect, pVCpu); 2561 } 2562 2563 2564 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectIsInitialized} */ 2565 static DECLCALLBACK(bool) pdmR3DevHlp_CritSectIsInitialized(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 2566 { 2567 PDMDEV_ASSERT_DEVINS(pDevIns); 2568 RT_NOREF(pDevIns); 2569 return PDMCritSectIsInitialized(pCritSect); 2570 } 2571 2572 2573 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectHasWaiters} */ 2574 static DECLCALLBACK(bool) pdmR3DevHlp_CritSectHasWaiters(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 2575 { 2576 PDMDEV_ASSERT_DEVINS(pDevIns); 2577 RT_NOREF(pDevIns); 2578 return PDMCritSectHasWaiters(pCritSect); 2579 } 2580 2581 2582 /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectGetRecursion} */ 2583 static DECLCALLBACK(uint32_t) pdmR3DevHlp_CritSectGetRecursion(PPDMDEVINS pDevIns, PCPDMCRITSECT pCritSect) 2584 { 2585 PDMDEV_ASSERT_DEVINS(pDevIns); 2586 RT_NOREF(pDevIns); 2587 return PDMCritSectGetRecursion(pCritSect); 2490 2588 } 2491 2589 … … 4248 4346 pdmR3DevHlp_CritSectGetNopRC, 4249 4347 pdmR3DevHlp_SetDeviceCritSect, 4250 PDMR3CritSectYield,4251 PDMCritSectEnter,4252 PDMCritSectEnterDebug,4253 PDMCritSectTryEnter,4254 PDMCritSectTryEnterDebug,4255 PDMCritSectLeave,4256 PDMCritSectIsOwner,4257 PDMCritSectIsInitialized,4258 PDMCritSectHasWaiters,4259 PDMCritSectGetRecursion,4348 pdmR3DevHlp_CritSectYield, 4349 pdmR3DevHlp_CritSectEnter, 4350 pdmR3DevHlp_CritSectEnterDebug, 4351 pdmR3DevHlp_CritSectTryEnter, 4352 pdmR3DevHlp_CritSectTryEnterDebug, 4353 pdmR3DevHlp_CritSectLeave, 4354 pdmR3DevHlp_CritSectIsOwner, 4355 pdmR3DevHlp_CritSectIsInitialized, 4356 pdmR3DevHlp_CritSectHasWaiters, 4357 pdmR3DevHlp_CritSectGetRecursion, 4260 4358 pdmR3DevHlp_ThreadCreate, 4261 4359 pdmR3DevHlp_SetAsyncNotification, … … 4687 4785 pdmR3DevHlp_CritSectGetNopRC, 4688 4786 pdmR3DevHlp_SetDeviceCritSect, 4689 PDMR3CritSectYield,4690 PDMCritSectEnter,4691 PDMCritSectEnterDebug,4692 PDMCritSectTryEnter,4693 PDMCritSectTryEnterDebug,4694 PDMCritSectLeave,4695 PDMCritSectIsOwner,4696 PDMCritSectIsInitialized,4697 PDMCritSectHasWaiters,4698 PDMCritSectGetRecursion,4787 pdmR3DevHlp_CritSectYield, 4788 pdmR3DevHlp_CritSectEnter, 4789 pdmR3DevHlp_CritSectEnterDebug, 4790 pdmR3DevHlp_CritSectTryEnter, 4791 pdmR3DevHlp_CritSectTryEnterDebug, 4792 pdmR3DevHlp_CritSectLeave, 4793 pdmR3DevHlp_CritSectIsOwner, 4794 pdmR3DevHlp_CritSectIsInitialized, 4795 pdmR3DevHlp_CritSectHasWaiters, 4796 pdmR3DevHlp_CritSectGetRecursion, 4699 4797 pdmR3DevHlp_ThreadCreate, 4700 4798 pdmR3DevHlp_SetAsyncNotification, -
trunk/src/VBox/VMM/VMMR3/PGMDbg.cpp
r80333 r80673 1004 1004 if (!--cYieldCountDown) 1005 1005 { 1006 fFullWalk = PDMR3CritSectYield( &pVM->pgm.s.CritSectX);1006 fFullWalk = PDMR3CritSectYield(pVM, &pVM->pgm.s.CritSectX); 1007 1007 cYieldCountDown = cYieldCountDownReload; 1008 1008 } -
trunk/src/VBox/VMM/VMMR3/PGMSavedState.cpp
r80333 r80673 1372 1372 && (iPage & 0x7ff) == 0x100 1373 1373 #endif 1374 && PDMR3CritSectYield( &pVM->pgm.s.CritSectX)1374 && PDMR3CritSectYield(pVM, &pVM->pgm.s.CritSectX) 1375 1375 && pVM->pgm.s.idRamRangesGen != idRamRangesGen) 1376 1376 { … … 1584 1584 if ( uPass != SSM_PASS_FINAL 1585 1585 && (iPage & 0x7ff) == 0x100 1586 && PDMR3CritSectYield( &pVM->pgm.s.CritSectX)1586 && PDMR3CritSectYield(pVM, &pVM->pgm.s.CritSectX) 1587 1587 && pVM->pgm.s.idRamRangesGen != idRamRangesGen) 1588 1588 {
Note:
See TracChangeset
for help on using the changeset viewer.