From: Sean Christopherson <seanjc@google.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Mingwei Zhang <mizhang@google.com>,
Vitaly Kuznetsov <vkuznets@redhat.com>,
Wanpeng Li <wanpengli@tencent.com>,
Jim Mattson <jmattson@google.com>, Joerg Roedel <joro@8bytes.org>,
kvm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] KVM: x86/mmu: fix potential races when walking host page table
Date: Fri, 29 Apr 2022 14:35:43 +0000 [thread overview]
Message-ID: <Ymv3vwBEgCH0CMPH@google.com> (raw)
In-Reply-To: <4b0936bf-fd3e-950a-81af-fd393475553f@redhat.com>
On Fri, Apr 29, 2022, Paolo Bonzini wrote:
> > +out:
> > + local_irq_restore(flags);
> > + return level;
> > +}
> > +EXPORT_SYMBOL_GPL(kvm_lookup_address_level_in_mm);
>
> Exporting is not needed.
>
> Thanks for writing the walk code though. I'll adapt it and integrate the
> patch.
But why are we fixing this only in KVM? I liked the idea of stealing perf's
implementation because it was a seemlingly perfect fit and wouldn't introduce
new code (ignoring wrappers, etc...).
We _know_ that at least one subsystem is misusing lookup_address_in_pgd() and
given that its wrappers are exported, I highly doubt KVM is the only offender.
It really feels like we're passing the buck here by burying the fix in KVM.
next prev parent reply other threads:[~2022-04-29 14:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-29 3:17 [PATCH] KVM: x86/mmu: fix potential races when walking host page table Mingwei Zhang
2022-04-29 9:10 ` Paolo Bonzini
2022-04-29 14:35 ` Sean Christopherson [this message]
2022-04-29 14:45 ` Paolo Bonzini
2022-04-29 15:47 ` Sean Christopherson
2022-04-29 15:33 ` Sean Christopherson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Ymv3vwBEgCH0CMPH@google.com \
--to=seanjc@google.com \
--cc=jmattson@google.com \
--cc=joro@8bytes.org \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mizhang@google.com \
--cc=pbonzini@redhat.com \
--cc=vkuznets@redhat.com \
--cc=wanpengli@tencent.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.