Changeset 61794 in vbox for trunk/src/VBox/VMM
- Timestamp:
- Jun 21, 2016 2:11:06 PM (8 years ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/APICAll.cpp
r61776 r61794 529 529 { 530 530 Log2(("APIC%u: apicSignalNextPendingIntr: Signaling pending interrupt. uVector=%#x\n", pVCpu->idCpu, uVector)); 531 APICSetInterruptFF(pVCpu, PDMAPICIRQ_HARDWARE);531 apicSetInterruptFF(pVCpu, PDMAPICIRQ_HARDWARE); 532 532 } 533 533 else … … 541 541 { 542 542 Log2(("APIC%u: apicSignalNextPendingIntr: APIC software-disabled, clearing pending interrupt\n", pVCpu->idCpu)); 543 APICClearInterruptFF(pVCpu, PDMAPICIRQ_HARDWARE);543 apicClearInterruptFF(pVCpu, PDMAPICIRQ_HARDWARE); 544 544 } 545 545 } … … 614 614 if ( VMCPUSET_IS_PRESENT(pDestCpuSet, idCpu) 615 615 && apicIsEnabled(&pVM->aCpus[idCpu])) 616 APICPostInterrupt(&pVM->aCpus[idCpu], uVector, enmTriggerMode);616 apicPostInterrupt(&pVM->aCpus[idCpu], uVector, enmTriggerMode); 617 617 } 618 618 break; … … 624 624 if ( idCpu < pVM->cCpus 625 625 && apicIsEnabled(&pVM->aCpus[idCpu])) 626 APICPostInterrupt(&pVM->aCpus[idCpu], uVector, enmTriggerMode);626 apicPostInterrupt(&pVM->aCpus[idCpu], uVector, enmTriggerMode); 627 627 else 628 628 Log2(("APIC: apicSendIntr: No CPU found for lowest-priority delivery mode!\n")); … … 637 637 { 638 638 Log2(("APIC: apicSendIntr: Raising SMI on VCPU%u\n", idCpu)); 639 APICSetInterruptFF(&pVM->aCpus[idCpu], PDMAPICIRQ_SMI);639 apicSetInterruptFF(&pVM->aCpus[idCpu], PDMAPICIRQ_SMI); 640 640 } 641 641 } … … 651 651 { 652 652 Log2(("APIC: apicSendIntr: Raising NMI on VCPU%u\n", idCpu)); 653 APICSetInterruptFF(&pVM->aCpus[idCpu], PDMAPICIRQ_NMI);653 apicSetInterruptFF(&pVM->aCpus[idCpu], PDMAPICIRQ_NMI); 654 654 } 655 655 } … … 696 696 { 697 697 Log2(("APIC: apicSendIntr: Raising EXTINT on VCPU%u\n", idCpu)); 698 APICSetInterruptFF(&pVM->aCpus[idCpu], PDMAPICIRQ_EXTINT);698 apicSetInterruptFF(&pVM->aCpus[idCpu], PDMAPICIRQ_EXTINT); 699 699 } 700 700 break; … … 1419 1419 pXApicPage->timer_ccr.u32CurrentCount = uInitialCount; 1420 1420 if (uInitialCount) 1421 APICStartTimer(pVCpu, uInitialCount);1421 apicStartTimer(pVCpu, uInitialCount); 1422 1422 else 1423 APICStopTimer(pVCpu);1423 apicStopTimer(pVCpu); 1424 1424 TMTimerUnlock(pTimer); 1425 1425 } … … 1793 1793 * @interface_method_impl{PDMAPICREG,pfnReadMsrR3} 1794 1794 */ 1795 VMM DECL(VBOXSTRICTRC) APICReadMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t *pu64Value)1795 VMM_INT_DECL(VBOXSTRICTRC) apicReadMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t *pu64Value) 1796 1796 { 1797 1797 /* … … 1900 1900 * @interface_method_impl{PDMAPICREG,pfnWriteMsrR3} 1901 1901 */ 1902 VMM DECL(VBOXSTRICTRC) APICWriteMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t u64Value)1902 VMM_INT_DECL(VBOXSTRICTRC) apicWriteMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t u64Value) 1903 1903 { 1904 1904 /* … … 1990 1990 { 1991 1991 uint8_t const uVector = XAPIC_SELF_IPI_GET_VECTOR(u32Value); 1992 APICPostInterrupt(pVCpu, uVector, XAPICTRIGGERMODE_EDGE);1992 apicPostInterrupt(pVCpu, uVector, XAPICTRIGGERMODE_EDGE); 1993 1993 rcStrict = VINF_SUCCESS; 1994 1994 break; … … 2037 2037 * @interface_method_impl{PDMAPICREG,pfnSetBaseMsrR3} 2038 2038 */ 2039 VMMDECL(VBOXSTRICTRC) APICSetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint64_t u64BaseMsr)2039 VMMDECL(VBOXSTRICTRC) apicSetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint64_t u64BaseMsr) 2040 2040 { 2041 2041 Assert(pVCpu); … … 2094 2094 * need to update the CPUID leaf ourselves. 2095 2095 */ 2096 APICR3Reset(pVCpu, false /* fResetApicBaseMsr */);2096 apicR3ResetEx(pVCpu, false /* fResetApicBaseMsr */); 2097 2097 uBaseMsr &= ~(MSR_IA32_APICBASE_EN | MSR_IA32_APICBASE_EXTD); 2098 2098 CPUMSetGuestCpuIdPerCpuApicFeature(pVCpu, false /*fVisible*/); … … 2174 2174 * @interface_method_impl{PDMAPICREG,pfnGetBaseMsrR3} 2175 2175 */ 2176 VMM DECL(uint64_t) APICGetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu)2176 VMM_INT_DECL(uint64_t) apicGetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu) 2177 2177 { 2178 2178 VMCPU_ASSERT_EMT_OR_NOT_RUNNING(pVCpu); … … 2186 2186 * @interface_method_impl{PDMAPICREG,pfnSetTprR3} 2187 2187 */ 2188 VMM DECL(void) APICSetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Tpr)2188 VMM_INT_DECL(void) apicSetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Tpr) 2189 2189 { 2190 2190 apicSetTpr(pVCpu, u8Tpr); … … 2218 2218 * @interface_method_impl{PDMAPICREG,pfnGetTprR3} 2219 2219 */ 2220 VMMDECL(uint8_t) APICGetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, bool *pfPending, uint8_t *pu8PendingIntr)2220 VMMDECL(uint8_t) apicGetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, bool *pfPending, uint8_t *pu8PendingIntr) 2221 2221 { 2222 2222 VMCPU_ASSERT_EMT(pVCpu); … … 2239 2239 * @interface_method_impl{PDMAPICREG,pfnGetTimerFreqR3} 2240 2240 */ 2241 VMM DECL(uint64_t) APICGetTimerFreq(PPDMDEVINS pDevIns)2241 VMM_INT_DECL(uint64_t) apicGetTimerFreq(PPDMDEVINS pDevIns) 2242 2242 { 2243 2243 PVM pVM = PDMDevHlpGetVM(pDevIns); … … 2253 2253 * @remarks This is a private interface between the IOAPIC and the APIC. 2254 2254 */ 2255 VMM DECL(int) APICBusDeliver(PPDMDEVINS pDevIns, uint8_t uDest, uint8_t uDestMode, uint8_t uDeliveryMode, uint8_t uVector,2255 VMM_INT_DECL(int) apicBusDeliver(PPDMDEVINS pDevIns, uint8_t uDest, uint8_t uDestMode, uint8_t uDeliveryMode, uint8_t uVector, 2256 2256 uint8_t uPolarity, uint8_t uTriggerMode, uint32_t uTagSrc) 2257 2257 { … … 2287 2287 * @remarks This is a private interface between the PIC and the APIC. 2288 2288 */ 2289 VMM DECL(VBOXSTRICTRC) APICLocalInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Pin, uint8_t u8Level, int rcRZ)2289 VMM_INT_DECL(VBOXSTRICTRC) apicLocalInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Pin, uint8_t u8Level, int rcRZ) 2290 2290 { 2291 2291 NOREF(pDevIns); … … 2401 2401 u8Level ? "Raising" : "Lowering", u8Pin)); 2402 2402 if (u8Level) 2403 APICSetInterruptFF(pVCpu, PDMAPICIRQ_EXTINT);2403 apicSetInterruptFF(pVCpu, PDMAPICIRQ_EXTINT); 2404 2404 else 2405 APICClearInterruptFF(pVCpu, PDMAPICIRQ_EXTINT);2405 apicClearInterruptFF(pVCpu, PDMAPICIRQ_EXTINT); 2406 2406 break; 2407 2407 } … … 2429 2429 u8Level ? "raising" : "lowering")); 2430 2430 if (u8Level) 2431 APICSetInterruptFF(pVCpu, PDMAPICIRQ_EXTINT);2431 apicSetInterruptFF(pVCpu, PDMAPICIRQ_EXTINT); 2432 2432 else 2433 APICClearInterruptFF(pVCpu, PDMAPICIRQ_EXTINT);2433 apicClearInterruptFF(pVCpu, PDMAPICIRQ_EXTINT); 2434 2434 } 2435 2435 else … … 2437 2437 /* LINT1 behaves as NMI. */ 2438 2438 Log2(("APIC%u: APICLocalInterrupt: APIC hardware-disabled, raising NMI\n", pVCpu->idCpu)); 2439 APICSetInterruptFF(pVCpu, PDMAPICIRQ_NMI);2439 apicSetInterruptFF(pVCpu, PDMAPICIRQ_NMI); 2440 2440 } 2441 2441 } … … 2448 2448 * @interface_method_impl{PDMAPICREG,pfnGetInterruptR3} 2449 2449 */ 2450 VMM DECL(int) APICGetInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t *pu8Vector, uint32_t *pu32TagSrc)2450 VMM_INT_DECL(int) apicGetInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t *pu8Vector, uint32_t *pu32TagSrc) 2451 2451 { 2452 2452 VMCPU_ASSERT_EMT(pVCpu); … … 2520 2520 * @callback_method_impl{FNIOMMMIOREAD} 2521 2521 */ 2522 VMM DECL(int) APICReadMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void *pv, unsigned cb)2522 VMM_INT_DECL(int) apicReadMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void *pv, unsigned cb) 2523 2523 { 2524 2524 NOREF(pvUser); … … 2544 2544 * @callback_method_impl{FNIOMMMIOWRITE} 2545 2545 */ 2546 VMM DECL(int) APICWriteMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void const *pv, unsigned cb)2546 VMM_INT_DECL(int) apicWriteMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void const *pv, unsigned cb) 2547 2547 { 2548 2548 NOREF(pvUser); … … 2557 2557 STAM_COUNTER_INC(&pVCpu->apic.s.CTX_SUFF(StatMmioWrite)); 2558 2558 2559 Log2(("APIC%u: APICWriteMmio: offReg=%#RX16 uValue=%#RX32\n", pVCpu->idCpu, offReg, uValue));2559 Log2(("APIC%u: apicWriteMmio: offReg=%#RX16 uValue=%#RX32\n", pVCpu->idCpu, offReg, uValue)); 2560 2560 2561 2561 int rc = VBOXSTRICTRC_VAL(apicWriteRegister(pApicDev, pVCpu, offReg, uValue)); … … 2570 2570 * @param enmType The IRQ type. 2571 2571 */ 2572 VMM DECL(void) APICSetInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType)2572 VMM_INT_DECL(void) apicSetInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType) 2573 2573 { 2574 2574 PVM pVM = pVCpu->CTX_SUFF(pVM); … … 2584 2584 * @param enmType The IRQ type. 2585 2585 */ 2586 VMM DECL(void) APICClearInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType)2586 VMM_INT_DECL(void) apicClearInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType) 2587 2587 { 2588 2588 PVM pVM = pVCpu->CTX_SUFF(pVM); … … 2606 2606 * @thread Any. 2607 2607 */ 2608 VMM_INT_DECL(void) APICPostInterrupt(PVMCPU pVCpu, uint8_t uVector, XAPICTRIGGERMODE enmTriggerMode)2608 VMM_INT_DECL(void) apicPostInterrupt(PVMCPU pVCpu, uint8_t uVector, XAPICTRIGGERMODE enmTriggerMode) 2609 2609 { 2610 2610 Assert(pVCpu); … … 2642 2642 { 2643 2643 Log2(("APIC: APICPostInterrupt: Setting UPDATE_APIC FF for edge-triggered intr. uVector=%#x\n", uVector)); 2644 APICSetInterruptFF(pVCpu, PDMAPICIRQ_UPDATE_PENDING);2644 apicSetInterruptFF(pVCpu, PDMAPICIRQ_UPDATE_PENDING); 2645 2645 } 2646 2646 } … … 2657 2657 { 2658 2658 Log2(("APIC: APICPostInterrupt: Setting UPDATE_APIC FF for level-triggered intr. uVector=%#x\n", uVector)); 2659 APICSetInterruptFF(pVCpu, PDMAPICIRQ_UPDATE_PENDING);2659 apicSetInterruptFF(pVCpu, PDMAPICIRQ_UPDATE_PENDING); 2660 2660 } 2661 2661 } … … 2683 2683 * @thread Any. 2684 2684 */ 2685 VMM_INT_DECL(void) APICStartTimer(PVMCPU pVCpu, uint32_t uInitialCount)2685 VMM_INT_DECL(void) apicStartTimer(PVMCPU pVCpu, uint32_t uInitialCount) 2686 2686 { 2687 2687 Assert(pVCpu); … … 2715 2715 * @thread Any. 2716 2716 */ 2717 VMM_INT_DECL(void) APICStopTimer(PVMCPU pVCpu)2717 VMM_INT_DECL(void) apicStopTimer(PVMCPU pVCpu) 2718 2718 { 2719 2719 Assert(pVCpu); -
trunk/src/VBox/VMM/VMMR3/APIC.cpp
r61777 r61794 292 292 * @param fResetApicBaseMsr Whether to reset the APIC base MSR. 293 293 */ 294 VMMR3_INT_DECL(void) APICR3Reset(PVMCPU pVCpu, bool fResetApicBaseMsr)294 VMMR3_INT_DECL(void) apicR3ResetEx(PVMCPU pVCpu, bool fResetApicBaseMsr) 295 295 { 296 296 VMCPU_ASSERT_EMT_OR_NOT_RUNNING(pVCpu); … … 1246 1246 uint8_t uVector = XAPIC_LVT_GET_VECTOR(uLvtTimer); 1247 1247 Log2(("APIC%u: apicR3TimerCallback: Raising timer interrupt. uVector=%#x\n", pVCpu->idCpu, uVector)); 1248 APICPostInterrupt(pVCpu, uVector, XAPICTRIGGERMODE_EDGE);1248 apicPostInterrupt(pVCpu, uVector, XAPICTRIGGERMODE_EDGE); 1249 1249 } 1250 1250 … … 1260 1260 { 1261 1261 Log2(("APIC%u: apicR3TimerCallback: Re-arming timer. uInitialCount=%#RX32\n", pVCpu->idCpu, uInitialCount)); 1262 APICStartTimer(pVCpu, uInitialCount);1262 apicStartTimer(pVCpu, uInitialCount); 1263 1263 } 1264 1264 break; … … 1301 1301 TMTimerStop(pApicCpu->pTimerR3); 1302 1302 1303 APICR3Reset(pVCpuDest, true /* fResetApicBaseMsr */);1303 apicR3ResetEx(pVCpuDest, true /* fResetApicBaseMsr */); 1304 1304 1305 1305 /* Clear the interrupt pending force flag. */ 1306 APICClearInterruptFF(pVCpuDest, PDMAPICIRQ_HARDWARE);1306 apicClearInterruptFF(pVCpuDest, PDMAPICIRQ_HARDWARE); 1307 1307 } 1308 1308 } … … 1505 1505 /* Initialize the virtual-APIC state. */ 1506 1506 RT_BZERO(pApicCpu->pvApicPageR3, pApicCpu->cbApicPage); 1507 APICR3Reset(pVCpu, true /* fResetApicBaseMsr */);1507 apicR3ResetEx(pVCpu, true /* fResetApicBaseMsr */); 1508 1508 1509 1509 #ifdef DEBUG_ramshankar … … 1655 1655 RT_ZERO(ApicReg); 1656 1656 ApicReg.u32Version = PDM_APICREG_VERSION; 1657 ApicReg.pfnGetInterruptR3 = APICGetInterrupt;1658 ApicReg.pfnSetBaseMsrR3 = APICSetBaseMsr;1659 ApicReg.pfnGetBaseMsrR3 = APICGetBaseMsr;1660 ApicReg.pfnSetTprR3 = APICSetTpr;1661 ApicReg.pfnGetTprR3 = APICGetTpr;1662 ApicReg.pfnWriteMsrR3 = APICWriteMsr;1663 ApicReg.pfnReadMsrR3 = APICReadMsr;1664 ApicReg.pfnBusDeliverR3 = APICBusDeliver;1665 ApicReg.pfnLocalInterruptR3 = APICLocalInterrupt;1666 ApicReg.pfnGetTimerFreqR3 = APICGetTimerFreq;1657 ApicReg.pfnGetInterruptR3 = apicGetInterrupt; 1658 ApicReg.pfnSetBaseMsrR3 = apicSetBaseMsr; 1659 ApicReg.pfnGetBaseMsrR3 = apicGetBaseMsr; 1660 ApicReg.pfnSetTprR3 = apicSetTpr; 1661 ApicReg.pfnGetTprR3 = apicGetTpr; 1662 ApicReg.pfnWriteMsrR3 = apicWriteMsr; 1663 ApicReg.pfnReadMsrR3 = apicReadMsr; 1664 ApicReg.pfnBusDeliverR3 = apicBusDeliver; 1665 ApicReg.pfnLocalInterruptR3 = apicLocalInterrupt; 1666 ApicReg.pfnGetTimerFreqR3 = apicGetTimerFreq; 1667 1667 1668 1668 /* … … 1672 1672 */ 1673 1673 { 1674 ApicReg.pszGetInterruptRC = " APICGetInterrupt";1675 ApicReg.pszSetBaseMsrRC = " APICSetBaseMsr";1676 ApicReg.pszGetBaseMsrRC = " APICGetBaseMsr";1677 ApicReg.pszSetTprRC = " APICSetTpr";1678 ApicReg.pszGetTprRC = " APICGetTpr";1679 ApicReg.pszWriteMsrRC = " APICWriteMsr";1680 ApicReg.pszReadMsrRC = " APICReadMsr";1681 ApicReg.pszBusDeliverRC = " APICBusDeliver";1682 ApicReg.pszLocalInterruptRC = " APICLocalInterrupt";1683 ApicReg.pszGetTimerFreqRC = " APICGetTimerFreq";1684 1685 ApicReg.pszGetInterruptR0 = " APICGetInterrupt";1686 ApicReg.pszSetBaseMsrR0 = " APICSetBaseMsr";1687 ApicReg.pszGetBaseMsrR0 = " APICGetBaseMsr";1688 ApicReg.pszSetTprR0 = " APICSetTpr";1689 ApicReg.pszGetTprR0 = " APICGetTpr";1690 ApicReg.pszWriteMsrR0 = " APICWriteMsr";1691 ApicReg.pszReadMsrR0 = " APICReadMsr";1692 ApicReg.pszBusDeliverR0 = " APICBusDeliver";1693 ApicReg.pszLocalInterruptR0 = " APICLocalInterrupt";1694 ApicReg.pszGetTimerFreqR0 = " APICGetTimerFreq";1674 ApicReg.pszGetInterruptRC = "apicGetInterrupt"; 1675 ApicReg.pszSetBaseMsrRC = "apicSetBaseMsr"; 1676 ApicReg.pszGetBaseMsrRC = "apicGetBaseMsr"; 1677 ApicReg.pszSetTprRC = "apicSetTpr"; 1678 ApicReg.pszGetTprRC = "apicGetTpr"; 1679 ApicReg.pszWriteMsrRC = "apicWriteMsr"; 1680 ApicReg.pszReadMsrRC = "apicReadMsr"; 1681 ApicReg.pszBusDeliverRC = "apicBusDeliver"; 1682 ApicReg.pszLocalInterruptRC = "apicLocalInterrupt"; 1683 ApicReg.pszGetTimerFreqRC = "apicGetTimerFreq"; 1684 1685 ApicReg.pszGetInterruptR0 = "apicGetInterrupt"; 1686 ApicReg.pszSetBaseMsrR0 = "apicSetBaseMsr"; 1687 ApicReg.pszGetBaseMsrR0 = "apicGetBaseMsr"; 1688 ApicReg.pszSetTprR0 = "apicSetTpr"; 1689 ApicReg.pszGetTprR0 = "apicGetTpr"; 1690 ApicReg.pszWriteMsrR0 = "apicWriteMsr"; 1691 ApicReg.pszReadMsrR0 = "apicReadMsr"; 1692 ApicReg.pszBusDeliverR0 = "apicBusDeliver"; 1693 ApicReg.pszLocalInterruptR0 = "apicLocalInterrupt"; 1694 ApicReg.pszGetTimerFreqR0 = "apicGetTimerFreq"; 1695 1695 } 1696 1696 … … 1724 1724 rc = PDMDevHlpMMIORegister(pDevIns, GCPhysApicBase, sizeof(XAPICPAGE), NULL /* pvUser */, 1725 1725 IOMMMIO_FLAGS_READ_DWORD | IOMMMIO_FLAGS_WRITE_DWORD_ZEROED, 1726 APICWriteMmio, APICReadMmio, "APIC");1726 apicWriteMmio, apicReadMmio, "APIC"); 1727 1727 if (RT_FAILURE(rc)) 1728 1728 return rc; … … 1733 1733 pApicDev->pCritSectRC = pApicDev->pApicHlpR3->pfnGetRCCritSect(pDevIns); 1734 1734 rc = PDMDevHlpMMIORegisterRC(pDevIns, GCPhysApicBase, sizeof(XAPICPAGE), NIL_RTRCPTR /*pvUser*/, 1735 " APICWriteMmio", "APICReadMmio");1735 "apicWriteMmio", "apicReadMmio"); 1736 1736 if (RT_FAILURE(rc)) 1737 1737 return rc; … … 1740 1740 pApicDev->pCritSectR0 = pApicDev->pApicHlpR3->pfnGetR0CritSect(pDevIns); 1741 1741 rc = PDMDevHlpMMIORegisterR0(pDevIns, GCPhysApicBase, sizeof(XAPICPAGE), NIL_RTR0PTR /*pvUser*/, 1742 " APICWriteMmio", "APICReadMmio");1742 "apicWriteMmio", "apicReadMmio"); 1743 1743 if (RT_FAILURE(rc)) 1744 1744 return rc; -
trunk/src/VBox/VMM/include/APICInternal.h
r61776 r61794 1408 1408 RT_C_DECLS_BEGIN 1409 1409 1410 const char *apicGetModeName(APICMODE enmMode); 1411 const char *apicGetDestFormatName(XAPICDESTFORMAT enmDestFormat); 1412 const char *apicGetDeliveryModeName(XAPICDELIVERYMODE enmDeliveryMode); 1413 const char *apicGetDestModeName(XAPICDESTMODE enmDestMode); 1414 const char *apicGetTriggerModeName(XAPICTRIGGERMODE enmTriggerMode); 1415 const char *apicGetDestShorthandName(XAPICDESTSHORTHAND enmDestShorthand); 1416 const char *apicGetTimerModeName(XAPICTIMERMODE enmTimerMode); 1417 void apicHintTimerFreq(PAPICCPU pApicCpu, uint32_t uInitialCount, uint8_t uTimerShift); 1418 APICMODE apicGetMode(uint64_t uApicBaseMsr); 1419 1420 VMMDECL(uint64_t) APICGetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu); 1421 VMMDECL(VBOXSTRICTRC) APICSetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint64_t uBase); 1422 VMMDECL(uint8_t) APICGetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, bool *pfPending, uint8_t *pu8PendingIntr); 1423 VMMDECL(void) APICSetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Tpr); 1424 VMMDECL(uint64_t) APICGetTimerFreq(PPDMDEVINS pDevIns); 1425 VMMDECL(int) APICReadMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void *pv, unsigned cb); 1426 VMMDECL(int) APICWriteMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void const *pv, unsigned cb); 1427 VMMDECL(VBOXSTRICTRC) APICReadMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t *pu64Val); 1428 VMMDECL(VBOXSTRICTRC) APICWriteMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t u64Val); 1429 VMMDECL(int) APICGetInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t *puVector, uint32_t *puTagSrc); 1430 VMMDECL(void) APICSetInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType); 1431 VMMDECL(void) APICClearInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType); 1432 VMMDECL(VBOXSTRICTRC) APICLocalInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Pin, uint8_t u8Level, int rcRZ); 1433 VMMDECL(int) APICBusDeliver(PPDMDEVINS pDevIns, uint8_t uDest, uint8_t uDestMode, uint8_t uDeliveryMode, 1434 uint8_t uVector, uint8_t uPolarity, uint8_t uTriggerMode, uint32_t uTagSrc); 1435 1436 VMM_INT_DECL(void) APICPostInterrupt(PVMCPU pVCpu, uint8_t uVector, XAPICTRIGGERMODE enmTriggerMode); 1437 VMM_INT_DECL(void) APICStartTimer(PVMCPU pVCpu, uint32_t uInitialCount); 1438 VMM_INT_DECL(void) APICStopTimer(PVMCPU pVCpu); 1410 const char *apicGetModeName(APICMODE enmMode); 1411 const char *apicGetDestFormatName(XAPICDESTFORMAT enmDestFormat); 1412 const char *apicGetDeliveryModeName(XAPICDELIVERYMODE enmDeliveryMode); 1413 const char *apicGetDestModeName(XAPICDESTMODE enmDestMode); 1414 const char *apicGetTriggerModeName(XAPICTRIGGERMODE enmTriggerMode); 1415 const char *apicGetDestShorthandName(XAPICDESTSHORTHAND enmDestShorthand); 1416 const char *apicGetTimerModeName(XAPICTIMERMODE enmTimerMode); 1417 void apicHintTimerFreq(PAPICCPU pApicCpu, uint32_t uInitialCount, uint8_t uTimerShift); 1418 APICMODE apicGetMode(uint64_t uApicBaseMsr); 1419 1420 DECLCALLBACK(uint64_t) apicGetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu); 1421 DECLCALLBACK(VBOXSTRICTRC) apicSetBaseMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint64_t uBase); 1422 DECLCALLBACK(uint8_t) apicGetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, bool *pfPending, uint8_t *pu8PendingIntr); 1423 DECLCALLBACK(void) apicSetTpr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Tpr); 1424 DECLCALLBACK(uint64_t) apicGetTimerFreq(PPDMDEVINS pDevIns); 1425 DECLCALLBACK(int) apicReadMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void *pv, unsigned cb); 1426 DECLCALLBACK(int) apicWriteMmio(PPDMDEVINS pDevIns, void *pvUser, RTGCPHYS GCPhysAddr, void const *pv, unsigned cb); 1427 DECLCALLBACK(VBOXSTRICTRC) apicReadMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t *pu64Val); 1428 DECLCALLBACK(VBOXSTRICTRC) apicWriteMsr(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint32_t u32Reg, uint64_t u64Val); 1429 DECLCALLBACK(int) apicGetInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t *puVector, uint32_t *puTagSrc); 1430 DECLCALLBACK(VBOXSTRICTRC) apicLocalInterrupt(PPDMDEVINS pDevIns, PVMCPU pVCpu, uint8_t u8Pin, uint8_t u8Level, int rcRZ); 1431 DECLCALLBACK(int) apicBusDeliver(PPDMDEVINS pDevIns, uint8_t uDest, uint8_t uDestMode, uint8_t uDeliveryMode, 1432 uint8_t uVector, uint8_t uPolarity, uint8_t uTriggerMode, uint32_t uTagSrc); 1433 1434 VMM_INT_DECL(void) apicPostInterrupt(PVMCPU pVCpu, uint8_t uVector, XAPICTRIGGERMODE enmTriggerMode); 1435 VMM_INT_DECL(void) apicStartTimer(PVMCPU pVCpu, uint32_t uInitialCount); 1436 VMM_INT_DECL(void) apicStopTimer(PVMCPU pVCpu); 1437 VMM_INT_DECL(void) apicSetInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType); 1438 VMM_INT_DECL(void) apicClearInterruptFF(PVMCPU pVCpu, PDMAPICIRQ enmType); 1439 1440 #ifdef IN_RING3 1441 VMMR3_INT_DECL(void) apicR3ResetEx(PVMCPU pVCpu, bool fResetApicBaseMsr); 1442 #endif 1439 1443 1440 1444 RT_C_DECLS_END
Note:
See TracChangeset
for help on using the changeset viewer.