diff options
author | Richard Henderson <rth@twiddle.net> | 2015-07-02 15:57:14 +0100 |
---|---|---|
committer | Richard Henderson <rth@twiddle.net> | 2016-02-13 07:59:59 +1100 |
commit | f4f1110e4b34797ddfa87bb28f9518b9256778be (patch) | |
tree | f88a66e3425e0e9d616200c2e566bd07a65dc44d /target-i386/kvm.c | |
parent | c9cfe8f9fb21f086e24b3a8f7ccd9c06e4d8d9d6 (diff) | |
download | qemu-f4f1110e4b34797ddfa87bb28f9518b9256778be.zip qemu-f4f1110e4b34797ddfa87bb28f9518b9256778be.tar.gz qemu-f4f1110e4b34797ddfa87bb28f9518b9256778be.tar.bz2 |
target-i386: Enable control registers for MPX
Enable and disable at CPL changes, MSR changes, and XRSTOR changes.
Signed-off-by: Richard Henderson <rth@twiddle.net>
Diffstat (limited to 'target-i386/kvm.c')
-rw-r--r-- | target-i386/kvm.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/target-i386/kvm.c b/target-i386/kvm.c index fca0314..7974acb 100644 --- a/target-i386/kvm.c +++ b/target-i386/kvm.c @@ -2588,41 +2588,44 @@ int kvm_arch_get_registers(CPUState *cs) ret = kvm_getput_regs(cpu, 0); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_xsave(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_xcrs(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_sregs(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_msrs(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_mp_state(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_apic(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_vcpu_events(cpu); if (ret < 0) { - return ret; + goto out; } ret = kvm_get_debugregs(cpu); if (ret < 0) { - return ret; + goto out; } - return 0; + ret = 0; + out: + cpu_sync_bndcs_hflags(&cpu->env); + return ret; } void kvm_arch_pre_run(CPUState *cpu, struct kvm_run *run) |