From 36a3a21dc990137d9302caa33e776f1070cd50a7 Mon Sep 17 00:00:00 2001 From: Jan Blunck Date: Tue, 7 Apr 2009 23:58:56 +0000 Subject: [PATCH] --- yaml --- r: 146568 b: refs/heads/master c: 9b62e5b10ff0f98346bcbe4a4fe3a0ca8fa7be30 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/arch/x86/kvm/x86.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index d865ebdcf518..48a497c59c29 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 14d0bc1f7c8226d5088e7182c3b53e0c7e91d1af +refs/heads/master: 9b62e5b10ff0f98346bcbe4a4fe3a0ca8fa7be30 diff --git a/trunk/arch/x86/kvm/x86.c b/trunk/arch/x86/kvm/x86.c index 0f3e04b74a66..e2713716e732 100644 --- a/trunk/arch/x86/kvm/x86.c +++ b/trunk/arch/x86/kvm/x86.c @@ -4569,7 +4569,7 @@ static void vcpu_kick_intr(void *info) void kvm_vcpu_kick(struct kvm_vcpu *vcpu) { int ipi_pcpu = vcpu->cpu; - int cpu = get_cpu(); + int cpu; if (waitqueue_active(&vcpu->wq)) { wake_up_interruptible(&vcpu->wq); @@ -4579,6 +4579,7 @@ void kvm_vcpu_kick(struct kvm_vcpu *vcpu) * We may be called synchronously with irqs disabled in guest mode, * So need not to call smp_call_function_single() in that case. */ + cpu = get_cpu(); if (vcpu->guest_mode && vcpu->cpu != cpu) smp_call_function_single(ipi_pcpu, vcpu_kick_intr, vcpu, 0); put_cpu();