From: "Nadav Har'El" <nyh@math.technion.ac.il>
To: Avi Kivity <avi@redhat.com>
Cc: Chris Wright <chrisw@redhat.com>, kvm@vger.kernel.org
Subject: Re: KVM call minutes for Nov 30
Date: Tue, 7 Dec 2010 14:49:07 +0200 [thread overview]
Message-ID: <20101207124907.GA25485@fermat.math.technion.ac.il> (raw)
In-Reply-To: <4CFDF19D.70505@redhat.com>
On Tue, Dec 07, 2010, Avi Kivity wrote about "Re: KVM call minutes for Nov 30":
>...
> All it requires is a
> kvm_set_cr3() which will load the PDPTEs into the PDPTRs if PAE is
> enabled. You may need to order the loading of CR0, CR3, CR4, and EFER
> to achieve the desired effect.
I did this more explicitly as:
vmcs_writel(GUEST_CR3, get_vmcs12_fields(vcpu)->guest_cr3);
vcpu->arch.cr3 = get_vmcs12_fields(vcpu)->guest_cr3;
load_pdptrs(vcpu, vcpu->arch.walk_mmu, vcpu->arch.cr3);
vmcs_write64(GUEST_PDPTR0, vcpu->arch.mmu.pdptrs[0]);
vmcs_write64(GUEST_PDPTR1, vcpu->arch.mmu.pdptrs[1]);
vmcs_write64(GUEST_PDPTR2, vcpu->arch.mmu.pdptrs[2]);
vmcs_write64(GUEST_PDPTR3, vcpu->arch.mmu.pdptrs[3]);
I'm still working on trying to simplify this code - I'll indeed try to see if
I can use kvm_set_cr3 instead. Thanks for the suggestion.
However, Even if it works, I have a concern on how nested vmx might brake in
the future if kvm_set_cr3 is changed in some way that is irrelevant to nested.
Nadav.
--
Nadav Har'El | Tuesday, Dec 7 2010, 30 Kislev 5771
nyh@math.technion.ac.il |-----------------------------------------
Phone +972-523-790466, ICQ 13349191 |We could wipe out world hunger if we knew
http://nadav.harel.org.il |how to make AOL's Free CD's edible!
next prev parent reply other threads:[~2010-12-07 12:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-30 15:53 KVM call minutes for Nov 30 Chris Wright
2010-11-30 15:59 ` Anthony Liguori
2010-12-01 9:27 ` Nadav Har'El
2010-12-01 10:28 ` Avi Kivity
2010-12-06 19:39 ` Nadav Har'El
2010-12-07 8:34 ` Avi Kivity
2010-12-07 12:49 ` Nadav Har'El [this message]
2010-12-07 13:10 ` Avi Kivity
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20101207124907.GA25485@fermat.math.technion.ac.il \
--to=nyh@math.technion.ac.il \
--cc=avi@redhat.com \
--cc=chrisw@redhat.com \
--cc=kvm@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.