]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
KVM: MMU: Simplify walk_addr_generic() loop
authorAvi Kivity <avi@redhat.com>
Wed, 12 Sep 2012 12:12:09 +0000 (15:12 +0300)
committerAvi Kivity <avi@redhat.com>
Thu, 20 Sep 2012 10:00:08 +0000 (13:00 +0300)
commit13d22b6aebb000aeaf137862c6c0e0c4d138d798
treee643caac077496bdaaeaf7c12101b43f62b34393
parent97d64b788114be1c4dc4bfe7a8ba2bf9643fe6af
KVM: MMU: Simplify walk_addr_generic() loop

The page table walk is coded as an infinite loop, with a special
case on the last pte.

Code it as an ordinary loop with a termination condition on the last
pte (large page or walk length exhausted), and put the last pte handling
code after the loop where it belongs.

Reviewed-by: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/kvm/paging_tmpl.h