From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Lalancette Subject: [PATCH 2/5] Remove KVM_REQ_PENDING_TIMER. Date: Tue, 27 Oct 2009 17:41:04 +0100 Message-ID: <1256661667-9298-3-git-send-email-clalance@redhat.com> References: <1256661667-9298-1-git-send-email-clalance@redhat.com> Cc: Chris Lalancette To: kvm@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:4293 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756111AbZJ0QlG (ORCPT ); Tue, 27 Oct 2009 12:41:06 -0400 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n9RGfBXC007619 for ; Tue, 27 Oct 2009 12:41:12 -0400 In-Reply-To: <1256661667-9298-1-git-send-email-clalance@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: KVM_REQ_PENDING_TIMER is set and cleared in a couple of places, but it never seems to be actually checked. Remove it. Signed-off-by: Chris Lalancette --- :100644 100644 eea4043... 72b5144... M arch/x86/kvm/timer.c :100644 100644 2ef39062.. 93a65b4... M arch/x86/kvm/x86.c :100644 100644 bd5a616... 053e49f... M include/linux/kvm_host.h arch/x86/kvm/timer.c | 5 +---- arch/x86/kvm/x86.c | 1 - include/linux/kvm_host.h | 1 - 3 files changed, 1 insertions(+), 6 deletions(-) diff --git a/arch/x86/kvm/timer.c b/arch/x86/kvm/timer.c index eea4043..72b5144 100644 --- a/arch/x86/kvm/timer.c +++ b/arch/x86/kvm/timer.c @@ -14,11 +14,8 @@ static int __kvm_timer_fn(struct kvm_vcpu *vcpu, struct kvm_timer *ktimer) * not care about potentially loosing timer events in the !reinject * case anyway. */ - if (ktimer->reinject || !atomic_read(&ktimer->pending)) { + if (ktimer->reinject || !atomic_read(&ktimer->pending)) atomic_inc(&ktimer->pending); - /* FIXME: this code should not know anything about vcpus */ - set_bit(KVM_REQ_PENDING_TIMER, &vcpu->requests); - } if (waitqueue_active(q)) wake_up_interruptible(q); diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 2ef3906..93a65b4 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -3906,7 +3906,6 @@ static int __vcpu_run(struct kvm_vcpu *vcpu) if (r <= 0) break; - clear_bit(KVM_REQ_PENDING_TIMER, &vcpu->requests); if (kvm_cpu_has_pending_timer(vcpu)) kvm_inject_pending_timer_irqs(vcpu); diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index bd5a616..053e49f 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h @@ -33,7 +33,6 @@ #define KVM_REQ_REPORT_TPR_ACCESS 2 #define KVM_REQ_MMU_RELOAD 3 #define KVM_REQ_TRIPLE_FAULT 4 -#define KVM_REQ_PENDING_TIMER 5 #define KVM_REQ_UNHALT 6 #define KVM_REQ_MMU_SYNC 7 #define KVM_REQ_KVMCLOCK_UPDATE 8 -- 1.6.0.6