Re: [PATCH] KVM: x86: Check for invalid/obsolete root *after* making MMU pages available
Sergey Senozhatsky <[email protected]>
| Newsgroups | org.kernel.vger.stable |
|---|---|
| Message-ID | <[email protected]> |
On (26/08/10 15:47), Sean Christopherson wrote:
[..]
> is_page_fault_stale() needs be checked for the TDP MMU as well. I had the
> pleasure of doing this cherry-pick for an internal kernel, this is what I thought
> yielded the easiest-to-read sequence:
I knew it!
> if (is_tdp_mmu_fault) {
> read_lock(&vcpu->kvm->mmu_lock);
> } else {
> write_lock(&vcpu->kvm->mmu_lock);
>
> r = make_mmu_pages_available(vcpu);
> if (r)
> goto out_unlock;
> }
>
> if (is_page_fault_stale(vcpu, fault, mmu_seq)) {
> r = RET_PF_RETRY;
> goto out_unlock;
> }
>
> if (is_tdp_mmu_fault)
> r = kvm_tdp_mmu_map(vcpu, fault);
> else
> r = __direct_map(vcpu, fault);
>
> As a diff...
Sean, can I trouble you with a request to submit your cherry-pick to 6.1.y?