Skip to content

Commit

Permalink
KVM: SVM: Set the 'busy' flag of the TR selector
Browse files Browse the repository at this point in the history
The busy flag of the TR selector is not set by the hardware. This breaks
migration from amd hosts to intel hosts.

Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
  • Loading branch information
Amit Shah authored and Avi Kivity committed Dec 31, 2008
1 parent 25022ac commit c0d0982
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions arch/x86/kvm/svm.c
Original file line number Diff line number Diff line change
Expand Up @@ -781,6 +781,13 @@ static void svm_get_segment(struct kvm_vcpu *vcpu,
if (seg == VCPU_SREG_CS)
var->g = s->limit > 0xfffff;

/*
* Work around a bug where the busy flag in the tr selector
* isn't exposed
*/
if (seg == VCPU_SREG_TR)
var->type |= 0x2;

var->unusable = !var->present;
}

Expand Down

0 comments on commit c0d0982

Please sign in to comment.