linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Vitaly Kuznetsov <vkuznets@redhat.com>, kvm@vger.kernel.org
Cc: Sean Christopherson <seanjc@google.com>,
	Wanpeng Li <wanpengli@tencent.com>,
	Jim Mattson <jmattson@google.com>,
	Marcelo Tosatti <mtosatti@redhat.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 0/2] KVM: x86: hyper-v: Fix TSC page update after KVM_SET_CLOCK(0) call
Date: Wed, 31 Mar 2021 17:08:40 +0200	[thread overview]
Message-ID: <dd1b6f3e-273a-8162-9937-428ae2237254@redhat.com> (raw)
In-Reply-To: <20210331124130.337992-1-vkuznets@redhat.com>

On 31/03/21 14:41, Vitaly Kuznetsov wrote:
> Changes since v2:
> - Fix the issue by using master_kernel_ns/get_kvmclock_base_ns() instead of
>   get_kvmclock_ns() when handling KVM_SET_CLOCK.
> - Rebase on Paolo's "KVM: x86: fix lockdep splat due to Xen runstate
>   update" series and use spin_lock_irq()/spin_unlock_irq() [Paolo]
> 
> Original description:
> 
> I discovered that after KVM_SET_CLOCK(0) TSC page value in the guest can
> go through the roof and apparently we have a signedness issue when the
> update is performed. Fix the issue and add a selftest.
> 
> Vitaly Kuznetsov (2):
>    KVM: x86: Prevent 'hv_clock->system_time' from going negative in
>      kvm_guest_time_update()
>    selftests: kvm: Check that TSC page value is small after
>      KVM_SET_CLOCK(0)
> 
>   arch/x86/kvm/x86.c                            | 19 +++++++++++++++++--
>   .../selftests/kvm/x86_64/hyperv_clock.c       | 13 +++++++++++--
>   2 files changed, 28 insertions(+), 4 deletions(-)
> 

Queued, thanks.

Paolo


      parent reply	other threads:[~2021-03-31 15:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-31 12:41 [PATCH v3 0/2] KVM: x86: hyper-v: Fix TSC page update after KVM_SET_CLOCK(0) call Vitaly Kuznetsov
2021-03-31 12:41 ` [PATCH v3 1/2] KVM: x86: Prevent 'hv_clock->system_time' from going negative in kvm_guest_time_update() Vitaly Kuznetsov
2021-03-31 12:41 ` [PATCH v3 2/2] selftests: kvm: Check that TSC page value is small after KVM_SET_CLOCK(0) Vitaly Kuznetsov
2021-03-31 15:08 ` Paolo Bonzini [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=dd1b6f3e-273a-8162-9937-428ae2237254@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=jmattson@google.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mtosatti@redhat.com \
    --cc=seanjc@google.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 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).