KVM: VMX: allow rmode_tss_base() to work with >2G of guest memory

Signed-off-by: Izik Eidus <izike@qumranet.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
This commit is contained in:
Izik Eidus 2007-08-19 22:24:58 +03:00 committed by Avi Kivity
parent 7e778161fb
commit 33f5fa1664
1 changed files with 1 additions and 1 deletions

View File

@ -1030,7 +1030,7 @@ static void enter_pmode(struct kvm_vcpu *vcpu)
vmcs_write32(GUEST_CS_AR_BYTES, 0x9b); vmcs_write32(GUEST_CS_AR_BYTES, 0x9b);
} }
static int rmode_tss_base(struct kvm* kvm) static gva_t rmode_tss_base(struct kvm* kvm)
{ {
gfn_t base_gfn = kvm->memslots[0].base_gfn + kvm->memslots[0].npages - 3; gfn_t base_gfn = kvm->memslots[0].base_gfn + kvm->memslots[0].npages - 3;
return base_gfn << PAGE_SHIFT; return base_gfn << PAGE_SHIFT;