Changeset 78237 in vbox for trunk/src/VBox
- Timestamp:
- Apr 22, 2019 4:35:20 AM (6 years ago)
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAll.cpp
r77898 r78237 986 986 IEM_STATIC VBOXSTRICTRC iemVmxVmexitNmi(PVMCPU pVCpu); 987 987 IEM_STATIC VBOXSTRICTRC iemVmxVmexitStartupIpi(PVMCPU pVCpu, uint8_t uVector); 988 IEM_STATIC VBOXSTRICTRC iemVmxVmexitInitIpi(PVMCPU pVCpu); 989 IEM_STATIC VBOXSTRICTRC iemVmxVmexitIntWindow(PVMCPU pVCpu); 990 IEM_STATIC VBOXSTRICTRC iemVmxVmexitNmiWindow(PVMCPU pVCpu); 991 IEM_STATIC VBOXSTRICTRC iemVmxVmexitMtf(PVMCPU pVCpu); 988 IEM_STATIC VBOXSTRICTRC iemVmxVmexit(PVMCPU pVCpu, uint32_t uExitReason); 992 989 IEM_STATIC VBOXSTRICTRC iemVmxVirtApicAccessMem(PVMCPU pVCpu, uint16_t offAccess, size_t cbAccess, void *pvData, uint32_t fAccess); 993 990 IEM_STATIC VBOXSTRICTRC iemVmxVmexitApicAccess(PVMCPU pVCpu, uint16_t offAccess, uint32_t fAccess); … … 14066 14063 else if (VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_VMX_MTF)) 14067 14064 { 14068 rcStrict = iemVmxVmexit Mtf(pVCpu);14065 rcStrict = iemVmxVmexit(pVCpu, VMX_EXIT_MTF); 14069 14066 Assert(!VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_INHIBIT_INTERRUPTS)); 14070 14067 Assert(!VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_VMX_MTF)); … … 14085 14082 else if (VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_VMX_NMI_WINDOW)) 14086 14083 { 14087 rcStrict = iemVmxVmexit NmiWindow(pVCpu);14084 rcStrict = iemVmxVmexit(pVCpu, VMX_EXIT_NMI_WINDOW); 14088 14085 Assert(!VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_VMX_NMI_WINDOW)); 14089 14086 } … … 15913 15910 15914 15911 /** 15915 * Interface for HM and EM to emulate VM-exit due to init-IPI (INIT). 15912 * Interface for HM and EM to emulate a VM-exit. 15913 * 15914 * If a specialized version of a VM-exit handler exists, that must be used instead. 15916 15915 * 15917 15916 * @returns Strict VBox status code. 15918 15917 * @param pVCpu The cross context virtual CPU structure of the calling EMT. 15918 * @param uExitReason The VM-exit reason. 15919 15919 * @thread EMT(pVCpu) 15920 */ 15921 VMM_INT_DECL(VBOXSTRICTRC) IEMExecVmxVmexitInitIpi(PVMCPU pVCpu) 15922 { 15923 VBOXSTRICTRC rcStrict = iemVmxVmexitInitIpi(pVCpu); 15924 if (pVCpu->iem.s.cActiveMappings) 15925 iemMemRollback(pVCpu); 15926 return iemExecStatusCodeFiddling(pVCpu, rcStrict); 15927 } 15928 15929 15930 /** 15931 * Interface for HM and EM to emulate VM-exits for interrupt-windows. 15932 * 15933 * @returns Strict VBox status code. 15934 * @param pVCpu The cross context virtual CPU structure of the calling EMT. 15935 * @thread EMT(pVCpu) 15936 */ 15937 VMM_INT_DECL(VBOXSTRICTRC) IEMExecVmxVmexitIntWindow(PVMCPU pVCpu) 15938 { 15939 VBOXSTRICTRC rcStrict = iemVmxVmexitIntWindow(pVCpu); 15940 if (pVCpu->iem.s.cActiveMappings) 15941 iemMemRollback(pVCpu); 15942 return iemExecStatusCodeFiddling(pVCpu, rcStrict); 15943 } 15944 15945 15946 /** 15947 * Interface for HM and EM to emulate VM-exits for NMI-windows. 15948 * 15949 * @returns Strict VBox status code. 15950 * @param pVCpu The cross context virtual CPU structure of the calling EMT. 15951 * @thread EMT(pVCpu) 15952 */ 15953 VMM_INT_DECL(VBOXSTRICTRC) IEMExecVmxVmexitNmiWindow(PVMCPU pVCpu) 15954 { 15955 VBOXSTRICTRC rcStrict = iemVmxVmexitNmiWindow(pVCpu); 15956 if (pVCpu->iem.s.cActiveMappings) 15957 iemMemRollback(pVCpu); 15958 return iemExecStatusCodeFiddling(pVCpu, rcStrict); 15959 } 15960 15961 15962 /** 15963 * Interface for HM and EM to emulate VM-exits Monitor-Trap Flag (MTF). 15964 * 15965 * @returns Strict VBox status code. 15966 * @param pVCpu The cross context virtual CPU structure of the calling EMT. 15967 * @thread EMT(pVCpu) 15968 */ 15969 VMM_INT_DECL(VBOXSTRICTRC) IEMExecVmxVmexitMtf(PVMCPU pVCpu) 15970 { 15971 VBOXSTRICTRC rcStrict = iemVmxVmexitMtf(pVCpu); 15920 * 15921 * @remarks It is the responsibility of the caller to ensure VM-exit qualification 15922 * is updated prior to calling this function! 15923 */ 15924 VMM_INT_DECL(VBOXSTRICTRC) IEMExecVmxVmexit(PVMCPU pVCpu, uint32_t uExitReason) 15925 { 15926 VBOXSTRICTRC rcStrict = iemVmxVmexit(pVCpu, uExitReason); 15972 15927 if (pVCpu->iem.s.cActiveMappings) 15973 15928 iemMemRollback(pVCpu); -
trunk/src/VBox/VMM/VMMAll/IEMAllCImplVmxInstr.cpp.h
r78220 r78237 3072 3072 3073 3073 /** 3074 * VMX VM-exit handler for VM-exits due to Monitor-Trap Flag (MTF).3075 *3076 * @returns Strict VBox status code.3077 * @param pVCpu The cross context virtual CPU structure.3078 */3079 IEM_STATIC VBOXSTRICTRC iemVmxVmexitMtf(PVMCPU pVCpu)3080 {3081 /*3082 * The MTF VM-exit can occur even when the MTF VM-execution control is3083 * not set (e.g. when VM-entry injects an MTF pending event), so do not3084 * check for the intercept here.3085 */3086 return iemVmxVmexit(pVCpu, VMX_EXIT_MTF);3087 }3088 3089 3090 /**3091 3074 * VMX VM-exit handler for VM-exits due to INVLPG. 3092 3075 * … … 3921 3904 iemVmxVmcsSetExitQual(pVCpu, uVector); 3922 3905 return iemVmxVmexit(pVCpu, VMX_EXIT_SIPI); 3923 }3924 3925 3926 /**3927 * VMX VM-exit handler for VM-exits due to init-IPIs (INIT).3928 *3929 * @returns VBox strict status code.3930 * @param pVCpu The cross context virtual CPU structure.3931 */3932 IEM_STATIC VBOXSTRICTRC iemVmxVmexitInitIpi(PVMCPU pVCpu)3933 {3934 return iemVmxVmexit(pVCpu, VMX_EXIT_INIT_SIGNAL);3935 }3936 3937 3938 /**3939 * VMX VM-exit handler for interrupt-window VM-exits.3940 *3941 * @returns VBox strict status code.3942 * @param pVCpu The cross context virtual CPU structure.3943 */3944 IEM_STATIC VBOXSTRICTRC iemVmxVmexitIntWindow(PVMCPU pVCpu)3945 {3946 return iemVmxVmexit(pVCpu, VMX_EXIT_INT_WINDOW);3947 }3948 3949 3950 /**3951 * VMX VM-exit handler for NMI-window VM-exits.3952 *3953 * @returns VBox strict status code.3954 * @param pVCpu The cross context virtual CPU structure.3955 */3956 IEM_STATIC VBOXSTRICTRC iemVmxVmexitNmiWindow(PVMCPU pVCpu)3957 {3958 return iemVmxVmexit(pVCpu, VMX_EXIT_NMI_WINDOW);3959 3906 } 3960 3907 -
trunk/src/VBox/VMM/VMMR3/EM.cpp
r78220 r78237 1729 1729 && CPUMIsGuestVmxProcCtlsSet(pVCpu, &pVCpu->cpum.GstCtx, VMX_PROC_CTLS_INT_WINDOW_EXIT)) 1730 1730 { 1731 VBOXSTRICTRC rcStrict = IEMExecVmxVmexit IntWindow(pVCpu);1731 VBOXSTRICTRC rcStrict = IEMExecVmxVmexit(pVCpu, VMX_EXIT_INT_WINDOW); 1732 1732 if (RT_SUCCESS(rcStrict)) 1733 1733 { … … 2157 2157 if (VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_VMX_MTF)) 2158 2158 { 2159 rc2 = VBOXSTRICTRC_VAL(IEMExecVmxVmexit Mtf(pVCpu));2159 rc2 = VBOXSTRICTRC_VAL(IEMExecVmxVmexit(pVCpu, VMX_EXIT_MTF)); 2160 2160 Assert(rc2 != VINF_VMX_INTERCEPT_NOT_ACTIVE); 2161 2161 UPDATE_RC(); … … 2179 2179 if (VMCPU_FF_IS_SET(pVCpu, VMCPU_FF_VMX_NMI_WINDOW)) 2180 2180 { 2181 rc2 = VBOXSTRICTRC_VAL(IEMExecVmxVmexit NmiWindow(pVCpu));2181 rc2 = VBOXSTRICTRC_VAL(IEMExecVmxVmexit(pVCpu, VMX_EXIT_NMI_WINDOW)); 2182 2182 Assert(rc2 != VINF_VMX_INTERCEPT_NOT_ACTIVE); 2183 2183 UPDATE_RC(); -
trunk/src/VBox/VMM/VMMR3/VMM.cpp
r76553 r78237 1647 1647 PCCPUMCTX pCtx = CPUMQueryGuestCtxPtr(pVCpu); 1648 1648 if (CPUMIsGuestInVmxNonRootMode(pCtx)) 1649 return VBOXSTRICTRC_TODO(IEMExecVmxVmexit InitIpi(pVCpu));1649 return VBOXSTRICTRC_TODO(IEMExecVmxVmexit(pVCpu, VMX_EXIT_INIT_SIGNAL)); 1650 1650 #endif 1651 1651
Note:
See TracChangeset
for help on using the changeset viewer.