diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2017-03-30 11:55:30 +0200 |
---|---|---|
committer | Radim Krčmář <rkrcmar@redhat.com> | 2017-04-07 16:49:00 +0200 |
commit | ae1e2d1082ae6969ff8c626ef80804d950bf256b (patch) | |
tree | 221bc3b5c7e8352cf07c56418ed61d42a558923c /virt/lib | |
parent | 86407bcb5c8320add17b57dc6af1586ff8e14bc0 (diff) | |
download | linux-ae1e2d1082ae6969ff8c626ef80804d950bf256b.tar.bz2 |
kvm: nVMX: support EPT accessed/dirty bits
Now use bit 6 of EPTP to optionally enable A/D bits for EPTP. Another
thing to change is that, when EPT accessed and dirty bits are not in use,
VMX treats accesses to guest paging structures as data reads. When they
are in use (bit 6 of EPTP is set), they are treated as writes and the
corresponding EPT dirty bit is set. The MMU didn't know this detail,
so this patch adds it.
We also have to fix up the exit qualification. It may be wrong because
KVM sets bit 6 but the guest might not.
L1 emulates EPT A/D bits using write permissions, so in principle it may
be possible for EPT A/D bits to be used by L1 even though not available
in hardware. The problem is that guest page-table walks will be treated
as reads rather than writes, so they would not cause an EPT violation.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
[Fixed typo in walk_addr_generic() comment and changed bit clear +
conditional-set pattern in handle_ept_violation() to conditional-clear]
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Diffstat (limited to 'virt/lib')
0 files changed, 0 insertions, 0 deletions