diff options
author | Avi Kivity <avi@qumranet.com> | 2007-02-01 02:48:13 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-01 19:22:41 -0500 |
commit | 432bd6cbf9f016f5480153b1cdfbd046f8d4fb1e (patch) | |
tree | 0398665da71dc09ec7d9f97f627d20e9ba06d658 /drivers | |
parent | 6a4c24ec52128c1f57b7d2d24cf4dd13fc23f474 (diff) |
[PATCH] KVM: fix lockup on 32-bit intel hosts with nx disabled in the bios
Intel hosts, without long mode, and with nx support disabled in the bios
have an efer that is readable but not writable. This causes a lockup on
switch to guest mode (even though it should exit with reason 34 according
to the documentation).
Signed-off-by: Avi Kivity <avi@qumranet.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/kvm/vmx.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c index 27f2751c3baa..54c35c0b3181 100644 --- a/drivers/kvm/vmx.c +++ b/drivers/kvm/vmx.c | |||
@@ -1116,6 +1116,8 @@ static int vmx_vcpu_setup(struct kvm_vcpu *vcpu) | |||
1116 | 1116 | ||
1117 | if (rdmsr_safe(index, &data_low, &data_high) < 0) | 1117 | if (rdmsr_safe(index, &data_low, &data_high) < 0) |
1118 | continue; | 1118 | continue; |
1119 | if (wrmsr_safe(index, data_low, data_high) < 0) | ||
1120 | continue; | ||
1119 | data = data_low | ((u64)data_high << 32); | 1121 | data = data_low | ((u64)data_high << 32); |
1120 | vcpu->host_msrs[j].index = index; | 1122 | vcpu->host_msrs[j].index = index; |
1121 | vcpu->host_msrs[j].reserved = 0; | 1123 | vcpu->host_msrs[j].reserved = 0; |