KVM: i8254: remove pointless dereference of PIT
authorRadim Krčmář <rkrcmar@redhat.com>
Wed, 2 Mar 2016 21:56:49 +0000 (22:56 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 4 Mar 2016 08:30:15 +0000 (09:30 +0100)
PIT is known at that point.

Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/i8254.c

index 37e665c..964902b 100644 (file)
@@ -267,8 +267,8 @@ static void pit_do_work(struct kthread_work *work)
        if (ps->reinject && !atomic_xchg(&ps->irq_ack, 0))
                return;
 
-       kvm_set_irq(kvm, kvm->arch.vpit->irq_source_id, 0, 1, false);
-       kvm_set_irq(kvm, kvm->arch.vpit->irq_source_id, 0, 0, false);
+       kvm_set_irq(kvm, pit->irq_source_id, 0, 1, false);
+       kvm_set_irq(kvm, pit->irq_source_id, 0, 0, false);
 
        /*
         * Provides NMI watchdog support via Virtual Wire mode.