From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo Tosatti Subject: KVM: x86: document KVM_REQ_PENDING_TIMER usage Date: Tue, 23 Mar 2010 14:15:53 -0300 Message-ID: <20100323171553.GA20283@amt.cnet> References: <1269055202-3195-1-git-send-email-sirouni@gmail.com> <4BA6125E.80006@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Xiao Wang , kvm@vger.kernel.org, akong@redhat.com To: Avi Kivity Return-path: Received: from mx1.redhat.com ([209.132.183.28]:14095 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752019Ab0CWRQw (ORCPT ); Tue, 23 Mar 2010 13:16:52 -0400 Content-Disposition: inline In-Reply-To: <4BA6125E.80006@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Document that KVM_REQ_PENDING_TIMER is implicitly used during guest entry. Signed-off-by: Marcelo Tosatti diff --git a/arch/x86/kvm/timer.c b/arch/x86/kvm/timer.c index eea4043..9805f05 100644 --- a/arch/x86/kvm/timer.c +++ b/arch/x86/kvm/timer.c @@ -12,7 +12,8 @@ static int __kvm_timer_fn(struct kvm_vcpu *vcpu, struct kvm_timer *ktimer) /* * There is a race window between reading and incrementing, but we do * not care about potentially loosing timer events in the !reinject - * case anyway. + * case anyway. Note: KVM_REQ_PENDING_TIMER is implicitly checked + * in vcpu_enter_guest. */ if (ktimer->reinject || !atomic_read(&ktimer->pending)) { atomic_inc(&ktimer->pending);