]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: MMU: Atomically check for accessed bit when dropping an spte
authorAvi Kivity <avi@redhat.com>
Sun, 6 Jun 2010 11:48:06 +0000 (14:48 +0300)
committerAvi Kivity <avi@redhat.com>
Mon, 2 Aug 2010 03:40:20 +0000 (06:40 +0300)
commit2dfd4f012f024d17a3a611da89ad768aeb27ef99
tree148607c0424c4ec993b55dd85eec69332a775b22
parent2899b9d818f1da316e314aa55ac747d2f161b798
KVM: MMU: Atomically check for accessed bit when dropping an spte

Currently, in the window between the check for the accessed bit, and actually
dropping the spte, a vcpu can access the page through the spte and set the bit,
which will be ignored by the mmu.

Fix by using an exchange operation to atmoically fetch the spte and drop it.

Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/kvm/mmu.c