From: Roman Kagan Subject: Re: [PATCH v2 3/4] x86/kvm/hyper-v: direct mode for synthetic timers Date: Mon, 3 Dec 2018 17:12:24 +0000 Message-ID: <20181203171220.GA2886@rkaganb.sw.ru> References: <20181126154732.23025-1-vkuznets@redhat.com> <20181126154732.23025-4-vkuznets@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable Cc: "kvm@vger.kernel.org" , Paolo Bonzini , =?iso-8859-2?Q?Radim_Kr=E8m=E1=F8?= , "linux-kernel@vger.kernel.org" , "K. Y. Srinivasan" , Haiyang Zhang , Stephen Hemminger , "x86@kernel.org" , "Michael Kelley (EOSG)" To: Vitaly Kuznetsov Return-path: In-Reply-To: <20181126154732.23025-4-vkuznets@redhat.com> Content-Language: en-US Content-ID: Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On Mon, Nov 26, 2018 at 04:47:31PM +0100, Vitaly Kuznetsov wrote: > @@ -379,6 +398,14 @@ void kvm_hv_synic_send_eoi(struct kvm_vcpu *vcpu, in= t vector) > for (i =3D 0; i < ARRAY_SIZE(synic->sint); i++) > if (synic_get_sint_vector(synic_read_sint(synic, i)) =3D=3D vector) > kvm_hv_notify_acked_sint(vcpu, i); > + > + for (i =3D 0; i < ARRAY_SIZE(hv_vcpu->stimer); i++) { > + stimer =3D &hv_vcpu->stimer[i]; > + if (stimer->msg_pending && stimer->config.enable && > + stimer->config.direct_mode && > + stimer->config.apic_vector =3D=3D vector) > + stimer_mark_pending(stimer, false); > + } > } While debugging another issue with synic timers, it just occurred to me that with direct timers no extra processing is necessary on EOI: unlike traditional synic timers which may have failed to deliver a message and want to be notified when they can retry, direct timers just set the irq directly in the apic. So this hunk shouldn't be needed, should it? Roman.