1. 27 12月, 2009 1 次提交
    • M
      KVM: MMU: remove prefault from invlpg handler · fb341f57
      Marcelo Tosatti 提交于
      The invlpg prefault optimization breaks Windows 2008 R2 occasionally.
      
      The visible effect is that the invlpg handler instantiates a pte which
      is, microseconds later, written with a different gfn by another vcpu.
      
      The OS could have other mechanisms to prevent a present translation from
      being used, which the hypervisor is unaware of.
      
      While the documentation states that the cpu is at liberty to prefetch tlb
      entries, it looks like this is not heeded, so remove tlb prefetch from
      invlpg.
      
      Cc: stable@kernel.org
      Signed-off-by: NMarcelo Tosatti <mtosatti@redhat.com>
      Signed-off-by: NAvi Kivity <avi@redhat.com>
      fb341f57
  2. 03 12月, 2009 1 次提交
  3. 04 10月, 2009 1 次提交
  4. 10 9月, 2009 9 次提交
  5. 28 6月, 2009 1 次提交
  6. 10 6月, 2009 4 次提交
  7. 24 3月, 2009 5 次提交
  8. 31 12月, 2008 3 次提交
  9. 26 11月, 2008 1 次提交
  10. 15 10月, 2008 8 次提交
  11. 25 8月, 2008 1 次提交
  12. 29 7月, 2008 1 次提交
  13. 20 7月, 2008 1 次提交
  14. 07 6月, 2008 1 次提交
  15. 27 4月, 2008 2 次提交
    • A
      KVM: MMU: Don't assume struct page for x86 · 35149e21
      Anthony Liguori 提交于
      This patch introduces a gfn_to_pfn() function and corresponding functions like
      kvm_release_pfn_dirty().  Using these new functions, we can modify the x86
      MMU to no longer assume that it can always get a struct page for any given gfn.
      
      We don't want to eliminate gfn_to_page() entirely because a number of places
      assume they can do gfn_to_page() and then kmap() the results.  When we support
      IO memory, gfn_to_page() will fail for IO pages although gfn_to_pfn() will
      succeed.
      
      This does not implement support for avoiding reference counting for reserved
      RAM or for IO memory.  However, it should make those things pretty straight
      forward.
      
      Since we're only introducing new common symbols, I don't think it will break
      the non-x86 architectures but I haven't tested those.  I've tested Intel,
      AMD, NPT, and hugetlbfs with Windows and Linux guests.
      
      [avi: fix overflow when shifting left pfns by adding casts]
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      Signed-off-by: NAvi Kivity <avi@qumranet.com>
      35149e21
    • M
      KVM: MMU: unify slots_lock usage · 3200f405
      Marcelo Tosatti 提交于
      Unify slots_lock acquision around vcpu_run(). This is simpler and less
      error-prone.
      
      Also fix some callsites that were not grabbing the lock properly.
      
      [avi: drop slots_lock while in guest mode to avoid holding the lock
            for indefinite periods]
      Signed-off-by: NMarcelo Tosatti <mtosatti@redhat.com>
      Signed-off-by: NAvi Kivity <avi@qumranet.com>
      3200f405