[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <f0fe943d-bdd0-1150-6d22-e7e48416da6d@redhat.com>
Date: Mon, 2 Mar 2020 19:22:08 +0100
From: Paolo Bonzini <pbonzini@...hat.com>
To: Vitaly Kuznetsov <vkuznets@...hat.com>,
Wanpeng Li <kernellwp@...il.com>
Cc: Sean Christopherson <sean.j.christopherson@...el.com>,
Wanpeng Li <wanpengli@...cent.com>,
Jim Mattson <jmattson@...gle.com>,
Joerg Roedel <joro@...tes.org>, linux-kernel@...r.kernel.org,
kvm@...r.kernel.org
Subject: Re: [PATCH v3] KVM: X86: Just one leader to trigger kvmclock sync
request
On 02/03/20 14:01, Vitaly Kuznetsov wrote:
> --- a/arch/x86/kvm/x86.c
> +++ b/arch/x86/kvm/x86.c
> @@ -9389,11 +9389,9 @@ void kvm_arch_vcpu_postcreate(struct kvm_vcpu *vcpu)
>
> mutex_unlock(&vcpu->mutex);
>
> - if (!kvmclock_periodic_sync)
> - return;
> -
> - schedule_delayed_work(&kvm->arch.kvmclock_sync_work,
> - KVMCLOCK_SYNC_PERIOD);
> + if (vcpu->vcpu_idx == 0 && kvmclock_periodic_sync)
> + schedule_delayed_work(&kvm->arch.kvmclock_sync_work,
> + KVMCLOCK_SYNC_PERIOD);
> }
> Reviewed-by: Vitaly Kuznetsov <vkuznets@...hat.com>
Good idea, I squashed the change.
Paolo
Powered by blists - more mailing lists