- Timestamp:
- Oct 21, 2021 3:52:28 PM (3 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/EFI/DevEFI.cpp
r91897 r91968 1649 1649 * CPU frequencies. 1650 1650 */ 1651 pThisCC->u64TscFrequency = TMCpuTicksPerSecond(PDMDevHlpGetVM(pDevIns));1651 pThisCC->u64TscFrequency = PDMDevHlpTMCpuTicksPerSecond(pDevIns); 1652 1652 pThisCC->u64CpuFrequency = pThisCC->u64TscFrequency; 1653 pThisCC->u64FsbFrequency = CPUMGetGuestScalableBusFrequency(PDMDevHlpGetVM(pDevIns));1653 pThisCC->u64FsbFrequency = PDMDevHlpCpuGetGuestScalableBusFrequency(pDevIns); 1654 1654 1655 1655 /* -
trunk/src/VBox/Devices/GIMDev/GIMDev.cpp
r82968 r91968 265 265 * Get debug setup requirements from GIM. 266 266 */ 267 PVMCC pVM = PDMDevHlpGetVM(pDevIns); 268 int rc = GIMR3GetDebugSetup(pVM, &pThis->DbgSetup); 267 int rc = PDMDevHlpGIMGetDebugSetup(pDevIns, &pThis->DbgSetup); 269 268 if ( RT_SUCCESS(rc) 270 269 && pThis->DbgSetup.cbDbgRecvBuf > 0) … … 336 335 * Register this device with the GIM component. 337 336 */ 338 GIMR3GimDeviceRegister(pVM,pDevIns, pThis->DbgSetup.cbDbgRecvBuf ? &pThis->Dbg : NULL);337 PDMDevHlpGIMDeviceRegister(pDevIns, pThis->DbgSetup.cbDbgRecvBuf ? &pThis->Dbg : NULL); 339 338 340 339 /* … … 343 342 /** @todo r=bird: consider ditching this as GIM doesn't actually make use of it */ 344 343 uint32_t cRegions = 0; 345 PGIMMMIO2REGION paRegions = GIMGetMmio2Regions(pVM, &cRegions);344 PGIMMMIO2REGION paRegions = PDMDevHlpGIMGetMmio2Regions(pDevIns, &cRegions); 346 345 if ( cRegions 347 346 && paRegions) -
trunk/src/VBox/Devices/Makefile.kmk
r91768 r91968 875 875 VBoxDD_LIBS += \ 876 876 $(PATH_STAGE_LIB)/VgaDefBiosLogo$(VBOX_SUFF_LIB) \ 877 $(LIB_VMM) \878 877 $(LIB_RUNTIME) 879 878 ifeq ($(KBUILD_TARGET),win) -
trunk/src/VBox/Devices/PC/DevFwCommon.cpp
r91897 r91968 943 943 pOEMSpecific->header.u8Length = sizeof(*pOEMSpecific); 944 944 pOEMSpecific->header.u16Handle = 0x0008; /* Just next free handle */ 945 pOEMSpecific->u32CpuFreqKHz = RT_H2LE_U32((uint32_t)((uint64_t) TMCpuTicksPerSecond(PDMDevHlpGetVM(pDevIns)) / 1000));945 pOEMSpecific->u32CpuFreqKHz = RT_H2LE_U32((uint32_t)((uint64_t)PDMDevHlpTMCpuTicksPerSecond(pDevIns) / 1000)); 946 946 DMI_TERM_STRUCT; 947 947 -
trunk/src/VBox/VMM/VMMR3/PDMDevHlp.cpp
r91960 r91968 754 754 755 755 756 /** @interface_method_impl{PDMDEVHLPR3,pfnTMCpuTicksPerSecond} */ 757 static DECLCALLBACK(uint64_t) pdmR3DevHlp_TMCpuTicksPerSecond(PPDMDEVINS pDevIns) 758 { 759 PDMDEV_ASSERT_DEVINS(pDevIns); 760 LogFlow(("pdmR3DevHlp_TMCpuTicksPerSecond: caller='%s'/%d\n", 761 pDevIns->pReg->szName, pDevIns->iInstance)); 762 763 uint64_t u64CpuTicksPerSec = TMCpuTicksPerSecond(pDevIns->Internal.s.pVMR3); 764 765 LogFlow(("pdmR3DevHlp_TMCpuTicksPerSecond: caller='%s'/%d: returns %RU64\n", pDevIns->pReg->szName, pDevIns->iInstance, u64CpuTicksPerSec)); 766 return u64CpuTicksPerSec; 767 } 768 769 756 770 /** @interface_method_impl{PDMDEVHLPR3,pfnGetSupDrvSession} */ 757 771 static DECLCALLBACK(PSUPDRVSESSION) pdmR3DevHlp_GetSupDrvSession(PPDMDEVINS pDevIns) … … 1132 1146 1133 1147 Log(("pdmR3DevHlp_CpuGetGuestAddrWidths: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance)); 1148 } 1149 1150 1151 /** @interface_method_impl{PDMDEVHLPR3,pfnCpuGuestScalableBusFrequency} */ 1152 static DECLCALLBACK(uint64_t) pdmR3DevHlp_CpuGetGuestScalableBusFrequency(PPDMDEVINS pDevIns) 1153 { 1154 PDMDEV_ASSERT_DEVINS(pDevIns); 1155 LogFlow(("pdmR3DevHlp_CpuGetGuestScalableBusFrequency: caller='%s'/%d\n", 1156 pDevIns->pReg->szName, pDevIns->iInstance)); 1157 1158 uint64_t u64Fsb = CPUMGetGuestScalableBusFrequency(pDevIns->Internal.s.pVMR3); 1159 1160 Log(("pdmR3DevHlp_CpuGetGuestScalableBusFrequency: caller='%s'/%d: returns %#RX64\n", pDevIns->pReg->szName, pDevIns->iInstance, u64Fsb)); 1161 return u64Fsb; 1134 1162 } 1135 1163 … … 4670 4698 4671 4699 /** @interface_method_impl{PDMDEVHLPR3,pfnQueryLun} */ 4672 static DECLCALLBACK(int) pdmR3DevHlp_ pfnQueryLun(PPDMDEVINS pDevIns, const char *pszDevice,4700 static DECLCALLBACK(int) pdmR3DevHlp_QueryLun(PPDMDEVINS pDevIns, const char *pszDevice, 4673 4701 unsigned iInstance, unsigned iLun, PPDMIBASE *ppBase) 4674 4702 { 4675 4703 PDMDEV_ASSERT_DEVINS(pDevIns); 4676 4704 4677 LogFlow(("pdmR3DevHlp_ pfnQueryLun: caller='%s'/%d: pszDevice=%p:{%s} iInstance=%u iLun=%u ppBase=%p\n",4705 LogFlow(("pdmR3DevHlp_QueryLun: caller='%s'/%d: pszDevice=%p:{%s} iInstance=%u iLun=%u ppBase=%p\n", 4678 4706 pDevIns->pReg->szName, pDevIns->iInstance, pszDevice, pszDevice, iInstance, iLun, ppBase)); 4679 4707 4680 4708 int rc = PDMR3QueryLun(pDevIns->Internal.s.pVMR3->pUVM, pszDevice, iInstance, iLun, ppBase); 4681 4709 4682 LogFlow(("pdmR3DevHlp_pfnQueryLun: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc)); 4683 return rc; 4710 LogFlow(("pdmR3DevHlp_QueryLun: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc)); 4711 return rc; 4712 } 4713 4714 4715 /** @interface_method_impl{PDMDEVHLPR3,pfnGIMDeviceRegister} */ 4716 static DECLCALLBACK(void) pdmR3DevHlp_GIMDeviceRegister(PPDMDEVINS pDevIns, PGIMDEBUG pDbg) 4717 { 4718 PDMDEV_ASSERT_DEVINS(pDevIns); 4719 4720 LogFlow(("pdmR3DevHlp_GIMDeviceRegister: caller='%s'/%d: pDbg=%p\n", 4721 pDevIns->pReg->szName, pDevIns->iInstance, pDbg)); 4722 4723 GIMR3GimDeviceRegister(pDevIns->Internal.s.pVMR3, pDevIns, pDbg); 4724 4725 LogFlow(("pdmR3DevHlp_GIMDeviceRegister: caller='%s'/%d: returns\n", pDevIns->pReg->szName, pDevIns->iInstance)); 4726 } 4727 4728 4729 /** @interface_method_impl{PDMDEVHLPR3,pfnGIMGetDebugSetup} */ 4730 static DECLCALLBACK(int) pdmR3DevHlp_GIMGetDebugSetup(PPDMDEVINS pDevIns, PGIMDEBUGSETUP pDbgSetup) 4731 { 4732 PDMDEV_ASSERT_DEVINS(pDevIns); 4733 4734 LogFlow(("pdmR3DevHlp_GIMGetDebugSetup: caller='%s'/%d: pDbgSetup=%p\n", 4735 pDevIns->pReg->szName, pDevIns->iInstance, pDbgSetup)); 4736 4737 int rc = GIMR3GetDebugSetup(pDevIns->Internal.s.pVMR3, pDbgSetup); 4738 4739 LogFlow(("pdmR3DevHlp_GIMGetDebugSetup: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc)); 4740 return rc; 4741 } 4742 4743 4744 /** @interface_method_impl{PDMDEVHLPR3,pfnGIMGetMmio2Regions} */ 4745 static DECLCALLBACK(PGIMMMIO2REGION) pdmR3DevHlp_GIMGetMmio2Regions(PPDMDEVINS pDevIns, uint32_t *pcRegions) 4746 { 4747 PDMDEV_ASSERT_DEVINS(pDevIns); 4748 4749 LogFlow(("pdmR3DevHlp_GIMGetMmio2Regions: caller='%s'/%d: pcRegions=%p\n", 4750 pDevIns->pReg->szName, pDevIns->iInstance, pcRegions)); 4751 4752 PGIMMMIO2REGION pRegion = GIMGetMmio2Regions(pDevIns->Internal.s.pVMR3, pcRegions); 4753 4754 LogFlow(("pdmR3DevHlp_GIMGetMmio2Regions: caller='%s'/%d: returns %p\n", pDevIns->pReg->szName, pDevIns->iInstance, pRegion)); 4755 return pRegion; 4684 4756 } 4685 4757 … … 5028 5100 pdmR3DevHlp_CpuGetGuestMicroarch, 5029 5101 pdmR3DevHlp_CpuGetGuestAddrWidths, 5102 pdmR3DevHlp_CpuGetGuestScalableBusFrequency, 5030 5103 pdmR3DevHlp_STAMDeregisterByPrefix, 5031 5104 0, … … 5054 5127 pdmR3DevHlp_TMTimeVirtGetFreq, 5055 5128 pdmR3DevHlp_TMTimeVirtGetNano, 5129 pdmR3DevHlp_TMCpuTicksPerSecond, 5056 5130 pdmR3DevHlp_GetSupDrvSession, 5057 5131 pdmR3DevHlp_QueryGenericUserObject, … … 5067 5141 pdmR3DevHlp_SharedModuleGetPageState, 5068 5142 pdmR3DevHlp_SharedModuleCheckAll, 5069 pdmR3DevHlp_pfnQueryLun, 5143 pdmR3DevHlp_QueryLun, 5144 pdmR3DevHlp_GIMDeviceRegister, 5145 pdmR3DevHlp_GIMGetDebugSetup, 5146 pdmR3DevHlp_GIMGetMmio2Regions, 5070 5147 PDM_DEVHLPR3_VERSION /* the end */ 5071 5148 }; … … 5416 5493 pdmR3DevHlp_CpuGetGuestMicroarch, 5417 5494 pdmR3DevHlp_CpuGetGuestAddrWidths, 5495 pdmR3DevHlp_CpuGetGuestScalableBusFrequency, 5418 5496 pdmR3DevHlp_STAMDeregisterByPrefix, 5419 5497 0, … … 5442 5520 pdmR3DevHlp_TMTimeVirtGetFreq, 5443 5521 pdmR3DevHlp_TMTimeVirtGetNano, 5522 pdmR3DevHlp_TMCpuTicksPerSecond, 5444 5523 pdmR3DevHlp_GetSupDrvSession, 5445 5524 pdmR3DevHlp_QueryGenericUserObject, … … 5455 5534 pdmR3DevHlp_SharedModuleGetPageState, 5456 5535 pdmR3DevHlp_SharedModuleCheckAll, 5457 pdmR3DevHlp_pfnQueryLun, 5536 pdmR3DevHlp_QueryLun, 5537 pdmR3DevHlp_GIMDeviceRegister, 5538 pdmR3DevHlp_GIMGetDebugSetup, 5539 pdmR3DevHlp_GIMGetMmio2Regions, 5458 5540 PDM_DEVHLPR3_VERSION /* the end */ 5459 5541 }; … … 5732 5814 5733 5815 5734 /** @interface_method_impl{PDMDEVHLPR3,pfnQ UeryLun} */5816 /** @interface_method_impl{PDMDEVHLPR3,pfnQueryLun} */ 5735 5817 static DECLCALLBACK(int) pdmR3DevHlp_Untrusted_QueryLun(PPDMDEVINS pDevIns, const char *pszDevice, unsigned iInstance, unsigned iLun, PPDMIBASE *ppBase) 5736 5818 { … … 5740 5822 pDevIns->pReg->szName, pDevIns->iInstance)); 5741 5823 return VERR_ACCESS_DENIED; 5824 } 5825 5826 5827 /** @interface_method_impl{PDMDEVHLPR3,pfnGIMDeviceRegister} */ 5828 static DECLCALLBACK(void) pdmR3DevHlp_Untrusted_GIMDeviceRegister(PPDMDEVINS pDevIns, PGIMDEBUG pDbg) 5829 { 5830 PDMDEV_ASSERT_DEVINS(pDevIns); 5831 RT_NOREF(pDbg); 5832 AssertReleaseMsgFailed(("Untrusted device called trusted helper! '%s'/%d\n", 5833 pDevIns->pReg->szName, pDevIns->iInstance)); 5834 } 5835 5836 5837 /** @interface_method_impl{PDMDEVHLPR3,pfnGIMGetDebugSetup} */ 5838 static DECLCALLBACK(int) pdmR3DevHlp_Untrusted_GIMGetDebugSetup(PPDMDEVINS pDevIns, PGIMDEBUGSETUP pDbgSetup) 5839 { 5840 PDMDEV_ASSERT_DEVINS(pDevIns); 5841 RT_NOREF(pDbgSetup); 5842 AssertReleaseMsgFailed(("Untrusted device called trusted helper! '%s'/%d\n", 5843 pDevIns->pReg->szName, pDevIns->iInstance)); 5844 return VERR_ACCESS_DENIED; 5845 } 5846 5847 5848 /** @interface_method_impl{PDMDEVHLPR3,pfnGIMGetMmio2Regions} */ 5849 static DECLCALLBACK(PGIMMMIO2REGION) pdmR3DevHlp_Untrusted_GIMGetMmio2Regions(PPDMDEVINS pDevIns, uint32_t *pcRegions) 5850 { 5851 PDMDEV_ASSERT_DEVINS(pDevIns); 5852 RT_NOREF(pcRegions); 5853 AssertReleaseMsgFailed(("Untrusted device called trusted helper! '%s'/%d\n", 5854 pDevIns->pReg->szName, pDevIns->iInstance)); 5855 return NULL; 5742 5856 } 5743 5857 … … 6086 6200 pdmR3DevHlp_CpuGetGuestMicroarch, 6087 6201 pdmR3DevHlp_CpuGetGuestAddrWidths, 6202 pdmR3DevHlp_CpuGetGuestScalableBusFrequency, 6088 6203 pdmR3DevHlp_STAMDeregisterByPrefix, 6089 6204 0, … … 6112 6227 pdmR3DevHlp_TMTimeVirtGetFreq, 6113 6228 pdmR3DevHlp_TMTimeVirtGetNano, 6229 pdmR3DevHlp_TMCpuTicksPerSecond, 6114 6230 pdmR3DevHlp_Untrusted_GetSupDrvSession, 6115 6231 pdmR3DevHlp_Untrusted_QueryGenericUserObject, … … 6126 6242 pdmR3DevHlp_Untrusted_SharedModuleCheckAll, 6127 6243 pdmR3DevHlp_Untrusted_QueryLun, 6244 pdmR3DevHlp_Untrusted_GIMDeviceRegister, 6245 pdmR3DevHlp_Untrusted_GIMGetDebugSetup, 6246 pdmR3DevHlp_Untrusted_GIMGetMmio2Regions, 6128 6247 PDM_DEVHLPR3_VERSION /* the end */ 6129 6248 };
Note:
See TracChangeset
for help on using the changeset viewer.