KVM: MMU: simplify folding of dirty bit into accessed_dirty
authorGleb Natapov <gleb@redhat.com>
Thu, 27 Dec 2012 12:44:58 +0000 (14:44 +0200)
committerMarcelo Tosatti <mtosatti@redhat.com>
Mon, 7 Jan 2013 22:31:35 +0000 (20:31 -0200)
commit908e7d7999bcce70ac52e7f390a8f5cbc55948de
tree8d0a2b246e40d49e583d3ad04dd1d9f363ab1f7a
parentee04e0cea8b170ae9c8542162091c716de36666b
KVM: MMU: simplify folding of dirty bit into accessed_dirty

MMU code tries to avoid if()s HW is not able to predict reliably by using
bitwise operation to streamline code execution, but in case of a dirty bit
folding this gives us nothing since write_fault is checked right before
the folding code. Lets just piggyback onto the if() to make code more clear.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/x86/kvm/paging_tmpl.h