diff options
author | vboxsync <vboxsync@cfe28804-0f27-0410-a406-dd0f0b0b656f> | 2018-06-06 14:24:04 +0000 |
---|---|---|
committer | vboxsync <vboxsync@cfe28804-0f27-0410-a406-dd0f0b0b656f> | 2018-06-06 14:24:04 +0000 |
commit | ab73b54b012603800ff219dd802f5fee9b654024 (patch) | |
tree | 914ffd2f8ebf2e923890e75f881987cb2c38ead3 /src/VBox/VMM/VMMAll/GIMAllHv.cpp | |
parent | f3d2ce674111d61a25779fc9dccc182839a155c5 (diff) | |
download | VirtualBox-svn-ab73b54b012603800ff219dd802f5fee9b654024.tar.gz |
EM,IEM,HM: Consolidated VMMHypercallsDisable/VMMHypercallsEnable into EMSetHypercallInstructionsEnabled and made the information available thru EMAreHypercallInstructionsEnabled(). Adjusted the vmmcall implementation so it works without HM. bugref:9044
git-svn-id: https://www.virtualbox.org/svn/vbox/trunk@72462 cfe28804-0f27-0410-a406-dd0f0b0b656f
Diffstat (limited to 'src/VBox/VMM/VMMAll/GIMAllHv.cpp')
-rw-r--r-- | src/VBox/VMM/VMMAll/GIMAllHv.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/VBox/VMM/VMMAll/GIMAllHv.cpp b/src/VBox/VMM/VMMAll/GIMAllHv.cpp index 4dd9b822b7b..8ebd35615c5 100644 --- a/src/VBox/VMM/VMMAll/GIMAllHv.cpp +++ b/src/VBox/VMM/VMMAll/GIMAllHv.cpp @@ -29,6 +29,7 @@ #include <VBox/vmm/pdmapi.h> #include <VBox/vmm/pgm.h> #include <VBox/vmm/apic.h> +#include <VBox/vmm/em.h> #include "GIMHvInternal.h" #include "GIMInternal.h" #include <VBox/vmm/vm.h> @@ -792,15 +793,14 @@ VMM_INT_DECL(VBOXSTRICTRC) gimHvWriteMsr(PVMCPU pVCpu, uint32_t idMsr, PCCPUMMSR pHv->u64GuestOsIdMsr = uRawValue; /* - * Notify VMM that hypercalls are now disabled/enabled. + * Update EM on hypercall instruction enabled state. */ - for (VMCPUID i = 0; i < pVM->cCpus; i++) - { - if (uRawValue) - VMMHypercallsEnable(&pVM->aCpus[i]); - else - VMMHypercallsDisable(&pVM->aCpus[i]); - } + if (uRawValue) + for (VMCPUID i = 0; i < pVM->cCpus; i++) + EMSetHypercallInstructionsEnabled(&pVM->aCpus[i], true); + else + for (VMCPUID i = 0; i < pVM->cCpus; i++) + EMSetHypercallInstructionsEnabled(&pVM->aCpus[i], false); return VINF_SUCCESS; #endif /* IN_RING3 */ |