KVM: PPC: Avoid lockdep debugging in TCE realmode handlers
Quoted 10 lines · Alexey Kardashevskiy
The
kvmppc_tce_to_ua()helper is called from real and virtual modes and it works fine as long asCONFIG_DEBUG_LOCKDEPis not enabled. However if the lockdep debugging is on, the lockdep will most likely break inkvm_memslots()because ofsrcu_dereference_check()so we need to use PPC-ownkvm_memslots_raw()which uses realmode safercu_dereference_raw_notrace().This creates a realmode copy of
kvmppc_tce_to_ua()which replaceskvm_memslots()withkvm_memslots_raw().
Quoted 8 lines
Since
kvmppc_rm_tce_to_ua()becomes static and can only be used inside HV KVM, this moves it earlier underCONFIG_KVM_BOOK3S_HV_POSSIBLE.This moves truly virtual-mode
kvmppc_tce_to_ua()to where it belongs and drops the prmap parameter which was never used in the virtual mode.Fixes d3695aa4f452 ("KVM: PPC: Add support for multiple-TCE hcalls", 2016-02-15)Signed-off-by Alexey Kardashevskiy <[email protected]>
Thanks, patch applied to my kvm-ppc-next tree.
Paul.