Re: [PATCH v3 1/4] KVM: nVMX: fix CR3 load if L2 uses PAE paging and EPT

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2016-12-21 16:09 GMT+08:00 Ladi Prosek <lprosek@xxxxxxxxxx>:
> On Wed, Dec 21, 2016 at 8:31 AM, Wanpeng Li <kernellwp@xxxxxxxxx> wrote:
>> 2016-11-30 23:03 GMT+08:00 Ladi Prosek <lprosek@xxxxxxxxxx>:
>>> KVM does not correctly handle L1 hypervisors that emulate L2 real mode with
>>> PAE and EPT, such as Hyper-V. In this mode, the L1 hypervisor populates guest
>>> PDPTE VMCS fields and leaves guest CR3 uninitialized because it is not used
>>
>> How L1 hypervisor populates guest PDPTE VMCS fields if undereference CR3?
>
> L2 is free to write anything to CR3. From its perspective it's still
> running in real mode so CR3 is effectively a general purpose register.
> If L1 intercepts CR3 accesses, it just shadows the value in the guest
> CR3 VMCS field so it's preserved across vmexists. It does not and
> should not dereference it.
>
> Let me know if I misunderstood the question.

I just confuse how PDPTE VMCS field is set when CR3 is uninitialized,
I think it should be from something like ept_identity_map_addr in
Hyper-V.

Regards,
Wanpeng Li
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux