summaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm
diff options
context:
space:
mode:
authorIzik Eidus <izike@qumranet.com>2008-04-28 18:23:52 +0300
committerAvi Kivity <avi@qumranet.com>2008-05-04 14:44:43 +0300
commit3fe913e7c550a869e250d04c34410f7a6e263f7c (patch)
tree557f9a5011ea5440fd95e4fd41183bda204b270b /arch/x86/kvm
parent1439442c7b257b47a83aea4daed8fbf4a32cdff9 (diff)
downloadblackbird-op-linux-3fe913e7c550a869e250d04c34410f7a6e263f7c.tar.gz
blackbird-op-linux-3fe913e7c550a869e250d04c34410f7a6e263f7c.zip
KVM: x86: task switch: fix wrong bit setting for the busy flag
The busy bit is bit 1 of the type field, not bit 8. Signed-off-by: Izik Eidus <izike@qumranet.com> Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'arch/x86/kvm')
-rw-r--r--arch/x86/kvm/x86.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index 1842a86f7c33..017daa2561f4 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -3484,7 +3484,7 @@ int kvm_task_switch(struct kvm_vcpu *vcpu, u16 tss_selector, int reason)
}
if (reason == TASK_SWITCH_IRET || reason == TASK_SWITCH_JMP) {
- cseg_desc.type &= ~(1 << 8); //clear the B flag
+ cseg_desc.type &= ~(1 << 1); //clear the B flag
save_guest_segment_descriptor(vcpu, tr_seg.selector,
&cseg_desc);
}
@@ -3510,7 +3510,7 @@ int kvm_task_switch(struct kvm_vcpu *vcpu, u16 tss_selector, int reason)
}
if (reason != TASK_SWITCH_IRET) {
- nseg_desc.type |= (1 << 8);
+ nseg_desc.type |= (1 << 1);
save_guest_segment_descriptor(vcpu, tss_selector,
&nseg_desc);
}
OpenPOWER on IntegriCloud