[PATCH 0/3] KVM: Clean up guest/host cache read/write code

From: Sean Christopherson
Date: Thu Jan 09 2020 - 18:56:24 EST


Minor cleanup to fix the underlying crustiness that led to an uninitialized
variable warning reported by Barret.

The first two patches are tagged with Fixes:, but I don't know that they're
actually worth backporting to stable. Functionally, everthing works, it's
just a bit weird and AFAICT not what is intended. It might be preferable
to take Barret's patch[*] first and only mark that for stable, as it fixes
the immediate issue without revamping __kvm_gfn_to_hva_cache_init().

[*] https://lkml.kernel.org/r/20200109195855.17353-1-brho@xxxxxxxxxx

Sean Christopherson (3):
KVM: Check for a bad hva before dropping into the ghc slow path
KVM: Clean up __kvm_gfn_to_hva_cache_init() and its callers
KVM: Return immediately if __kvm_gfn_to_hva_cache_init() fails

virt/kvm/kvm_main.c | 45 ++++++++++++++++++++++++++-------------------
1 file changed, 26 insertions(+), 19 deletions(-)

--
2.24.1