Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755367AbdDGITN (ORCPT ); Fri, 7 Apr 2017 04:19:13 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52678 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755569AbdDGISW (ORCPT ); Fri, 7 Apr 2017 04:18:22 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 257EE3D95F Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=david@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 257EE3D95F Subject: Re: [PATCH 3/6] KVM: x86: use kvm_make_request instead of set_bit To: =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , linux-kernel@vger.kernel.org, kvm@vger.kernel.org References: <20170406202056.18379-1-rkrcmar@redhat.com> <20170406202056.18379-4-rkrcmar@redhat.com> Cc: Christoffer Dall , Andrew Jones , Marc Zyngier , Paolo Bonzini , Christian Borntraeger , Cornelia Huck , James Hogan , Paul Mackerras From: David Hildenbrand Organization: Red Hat GmbH Message-ID: <25c9ac4f-2de9-36d8-231e-e78bbe2956ae@redhat.com> Date: Fri, 7 Apr 2017 10:18:18 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <20170406202056.18379-4-rkrcmar@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Fri, 07 Apr 2017 08:18:21 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1536 Lines: 50 On 06.04.2017 22:20, Radim Krčmář wrote: > Signed-off-by: Radim Krčmář > --- > arch/x86/kvm/x86.c | 10 ++-------- > 1 file changed, 2 insertions(+), 8 deletions(-) > > diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c > index 71a019832df9..57e9989232e5 100644 > --- a/arch/x86/kvm/x86.c > +++ b/arch/x86/kvm/x86.c > @@ -2229,8 +2229,7 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info) > bool tmp = (msr == MSR_KVM_SYSTEM_TIME); > > if (ka->boot_vcpu_runs_old_kvmclock != tmp) > - set_bit(KVM_REQ_MASTERCLOCK_UPDATE, > - &vcpu->requests); > + kvm_make_request(KVM_REQ_MASTERCLOCK_UPDATE, vcpu); > > ka->boot_vcpu_runs_old_kvmclock = tmp; > } > @@ -2803,11 +2802,6 @@ static bool need_emulate_wbinvd(struct kvm_vcpu *vcpu) > return kvm_arch_has_noncoherent_dma(vcpu->kvm); > } > > -static inline void kvm_migrate_timers(struct kvm_vcpu *vcpu) > -{ > - set_bit(KVM_REQ_MIGRATE_TIMER, &vcpu->requests); > -} > - > void kvm_arch_vcpu_load(struct kvm_vcpu *vcpu, int cpu) > { > /* Address WBINVD may be executed by guest */ > @@ -2851,7 +2845,7 @@ void kvm_arch_vcpu_load(struct kvm_vcpu *vcpu, int cpu) > if (!vcpu->kvm->arch.use_master_clock || vcpu->cpu == -1) > kvm_make_request(KVM_REQ_GLOBAL_CLOCK_UPDATE, vcpu); > if (vcpu->cpu != cpu) > - kvm_migrate_timers(vcpu); > + kvm_make_request(KVM_REQ_MIGRATE_TIMER, vcpu); > vcpu->cpu = cpu; > } > > Reviewed-by: David Hildenbrand -- Thanks, David