From: Greg KH <gregkh@linuxfoundation.org>
To: Tudor Ambarus <tudor.ambarus@linaro.org>
Cc: pbonzini@redhat.com, stable@vger.kernel.org, seanjc@google.com,
joro@8bytes.org, vkuznets@redhat.com, wanpengli@tencent.com,
jmattson@google.com, suravee.suthikulpanit@amd.com,
kvm@vger.kernel.org, iommu@lists.linux-foundation.org,
linux-kernel@vger.kernel.org, mlevitsk@redhat.com,
joneslee@google.com,
syzbot+b6a74be92b5063a0f1ff@syzkaller.appspotmail.com
Subject: Re: [PATCH][for stable/linux-5.15.y] KVM: VMX: Move preemption timer <=> hrtimer dance to common x86
Date: Mon, 3 Apr 2023 15:08:44 +0200 [thread overview]
Message-ID: <2023040335-backlash-tubeless-7d21@gregkh> (raw)
In-Reply-To: <20230329151747.2938509-1-tudor.ambarus@linaro.org>
On Wed, Mar 29, 2023 at 03:17:47PM +0000, Tudor Ambarus wrote:
> From: Sean Christopherson <seanjc@google.com>
>
> commit 98c25ead5eda5e9d41abe57839ad3e8caf19500c upstream.
>
> Handle the switch to/from the hypervisor/software timer when a vCPU is
> blocking in common x86 instead of in VMX. Even though VMX is the only
> user of a hypervisor timer, the logic and all functions involved are
> generic x86 (unless future CPUs do something completely different and
> implement a hypervisor timer that runs regardless of mode).
>
> Handling the switch in common x86 will allow for the elimination of the
> pre/post_blocks hooks, and also lets KVM switch back to the hypervisor
> timer if and only if it was in use (without additional params). Add a
> comment explaining why the switch cannot be deferred to kvm_sched_out()
> or kvm_vcpu_block().
>
> Signed-off-by: Sean Christopherson <seanjc@google.com>
> Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
> Message-Id: <20211208015236.1616697-8-seanjc@google.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> [ta: Fix conflicts in vmx_pre_block and vmx_post_block as per Paolo's
> suggestion. Add Reported-by and Link tags.]
> Reported-by: syzbot+b6a74be92b5063a0f1ff@syzkaller.appspotmail.com
> Link: https://syzkaller.appspot.com/bug?id=489beb3d76ef14cc6cd18125782dc6f86051a605
> Tested-by: Tudor Ambarus <tudor.ambarus@linaro.org>
> Signed-off-by: Tudor Ambarus <tudor.ambarus@linaro.org>
> ---
> arch/x86/kvm/vmx/vmx.c | 6 ------
> arch/x86/kvm/x86.c | 21 +++++++++++++++++++++
> 2 files changed, 21 insertions(+), 6 deletions(-)
Now queued up, thanks.
greg k-h
prev parent reply other threads:[~2023-04-03 13:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-29 15:17 [PATCH][for stable/linux-5.15.y] KVM: VMX: Move preemption timer <=> hrtimer dance to common x86 Tudor Ambarus
2023-03-29 15:21 ` Paolo Bonzini
2023-04-03 13:08 ` Greg KH [this message]
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=2023040335-backlash-tubeless-7d21@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=iommu@lists.linux-foundation.org \
--cc=jmattson@google.com \
--cc=joneslee@google.com \
--cc=joro@8bytes.org \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mlevitsk@redhat.com \
--cc=pbonzini@redhat.com \
--cc=seanjc@google.com \
--cc=stable@vger.kernel.org \
--cc=suravee.suthikulpanit@amd.com \
--cc=syzbot+b6a74be92b5063a0f1ff@syzkaller.appspotmail.com \
--cc=tudor.ambarus@linaro.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox