From: Christian Borntraeger <borntraeger@de.ibm.com>
To: Wanpeng Li <kernellwp@gmail.com>,
linux-kernel@vger.kernel.org, kvm@vger.kernel.org
Cc: "Paolo Bonzini" <pbonzini@redhat.com>,
"Radim Krčmář" <rkrcmar@redhat.com>,
"Janosch Frank" <frankja@linux.ibm.com>,
linux-s390 <linux-s390@vger.kernel.org>,
"Michael Mueller" <mimu@linux.ibm.com>
Subject: Re: [PATCH v2 2/2] KVM:390: Use kvm_vcpu_wake_up in kvm_s390_vcpu_wakeup
Date: Thu, 18 Jul 2019 14:09:13 +0200 [thread overview]
Message-ID: <3072d776-847e-fc69-28b9-f3d29d6eab17@de.ibm.com> (raw)
In-Reply-To: <1563449947-7749-2-git-send-email-wanpengli@tencent.com>
On 18.07.19 13:39, Wanpeng Li wrote:
> From: Wanpeng Li <wanpengli@tencent.com>
>
> Use kvm_vcpu_wake_up() in kvm_s390_vcpu_wakeup().
>
> Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Radim Krčmář <rkrcmar@redhat.com>
> Cc: Christian Borntraeger <borntraeger@de.ibm.com>
> Signed-off-by: Wanpeng Li <wanpengli@tencent.com>
with patch1 this looks good.
> ---
> arch/s390/kvm/interrupt.c | 15 +--------------
> 1 file changed, 1 insertion(+), 14 deletions(-)
>
> diff --git a/arch/s390/kvm/interrupt.c b/arch/s390/kvm/interrupt.c
> index 26f8bf4..881cc5a 100644
> --- a/arch/s390/kvm/interrupt.c
> +++ b/arch/s390/kvm/interrupt.c
> @@ -1229,21 +1229,8 @@ void kvm_s390_vcpu_wakeup(struct kvm_vcpu *vcpu)
> * in kvm_vcpu_block without having the waitqueue set (polling)
> */
> vcpu->valid_wakeup = true;
> - /*
> - * This is mostly to document, that the read in swait_active could
> - * be moved before other stores, leading to subtle races.
> - * All current users do not store or use an atomic like update
> - */
> - smp_mb__after_atomic();
> - if (swait_active(&vcpu->wq)) {
> - /*
> - * The vcpu gave up the cpu voluntarily, mark it as a good
> - * yield-candidate.
> - */
> + if (kvm_vcpu_wake_up(vcpu))
> vcpu->ready = true;
> - swake_up_one(&vcpu->wq);
> - vcpu->stat.halt_wakeup++;
> - }
> /*
> * The VCPU might not be sleeping but is executing the VSIE. Let's
> * kick it, so it leaves the SIE to process the request.
>
next prev parent reply other threads:[~2019-07-18 12:09 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-18 11:39 [PATCH v2 1/2] KVM: Boosting vCPUs that are delivering interrupts Wanpeng Li
2019-07-18 11:39 ` [PATCH v2 2/2] KVM:390: Use kvm_vcpu_wake_up in kvm_s390_vcpu_wakeup Wanpeng Li
2019-07-18 12:09 ` Christian Borntraeger [this message]
2019-07-18 13:30 ` [PATCH v2 1/2] KVM: Boosting vCPUs that are delivering interrupts 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=3072d776-847e-fc69-28b9-f3d29d6eab17@de.ibm.com \
--to=borntraeger@de.ibm.com \
--cc=frankja@linux.ibm.com \
--cc=kernellwp@gmail.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=mimu@linux.ibm.com \
--cc=pbonzini@redhat.com \
--cc=rkrcmar@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).