From: Sean Christopherson <seanjc@google.com>
To: David Woodhouse <dwmw2@infradead.org>
Cc: kvm <kvm@vger.kernel.org>, Paolo Bonzini <pbonzini@redhat.com>,
Vitaly Kuznetsov <vkuznets@redhat.com>,
Wanpeng Li <wanpengli@tencent.com>,
Jim Mattson <jmattson@google.com>, Joerg Roedel <joro@8bytes.org>,
mtosatti <mtosatti@redhat.com>
Subject: Re: [PATCH] KVM: x86: Take srcu lock in post_kvm_run_save()
Date: Tue, 26 Oct 2021 16:05:41 +0000 [thread overview]
Message-ID: <YXgnVdHCMZQDFRx6@google.com> (raw)
In-Reply-To: <f1dcf1af7e50649c66054ccf04c0052bb09d7f71.camel@infradead.org>
On Tue, Oct 26, 2021, David Woodhouse wrote:
> On Tue, 2021-10-26 at 14:42 +0000, Sean Christopherson wrote:
> > What about taking the lock well early on so that the tail doesn't need to juggle
> > errors? Dropping the lock for the KVM_MP_STATE_UNINITIALIZED case is a little
> > unfortunate, but that at least pairs with similar logic in x86's other call to
> > kvm_vcpu_block(). Relocking if xfer_to_guest_mode_handle_work() triggers an exit
> > to userspace is also unfortunate but it's not the end of the world.
> >
> > On the plus side, the complete_userspace_io() callback doesn't need to worry
> > about taking the lock.
>
> Yeah, that seems sensible for master, but I suspect I'd err on the side
> of caution for backporting to stable first?
Agreed, dirty-but-simple for stable.
next prev parent reply other threads:[~2021-10-26 16:05 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-26 3:12 [PATCH] KVM: x86: Take srcu lock in post_kvm_run_save() David Woodhouse
2021-10-26 14:42 ` Sean Christopherson
2021-10-26 16:00 ` David Woodhouse
2021-10-26 16:05 ` Sean Christopherson [this message]
2021-10-28 14:11 ` Paolo Bonzini
2021-10-28 14:23 ` David Woodhouse
2021-10-28 16:15 ` Paolo Bonzini
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=YXgnVdHCMZQDFRx6@google.com \
--to=seanjc@google.com \
--cc=dwmw2@infradead.org \
--cc=jmattson@google.com \
--cc=joro@8bytes.org \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.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.