KVM: Trace irq level and source id
Avi Kivity [Wed, 1 Jul 2009 09:09:41 +0000 (12:09 +0300)]
Signed-off-by: Avi Kivity <avi@redhat.com>

include/trace/events/kvm.h
virt/kvm/irq_comm.c

index d74b23d..035232d 100644 (file)
@@ -9,18 +9,23 @@
 
 #if defined(__KVM_HAVE_IOAPIC)
 TRACE_EVENT(kvm_set_irq,
-       TP_PROTO(unsigned int gsi),
-       TP_ARGS(gsi),
+       TP_PROTO(unsigned int gsi, int level, int irq_source_id),
+       TP_ARGS(gsi, level, irq_source_id),
 
        TP_STRUCT__entry(
                __field(        unsigned int,   gsi             )
+               __field(        int,            level           )
+               __field(        int,            irq_source_id   )
        ),
 
        TP_fast_assign(
                __entry->gsi            = gsi;
+               __entry->level          = level;
+               __entry->irq_source_id  = irq_source_id;
        ),
 
-       TP_printk("gsi %u", __entry->gsi)
+       TP_printk("gsi %u level %d source %d",
+                 __entry->gsi, __entry->level, __entry->irq_source_id)
 );
 
 
index 94759ed..56e6961 100644 (file)
@@ -126,7 +126,7 @@ int kvm_set_irq(struct kvm *kvm, int irq_source_id, int irq, int level)
        unsigned long *irq_state, sig_level;
        int ret = -1;
 
-       trace_kvm_set_irq(irq);
+       trace_kvm_set_irq(irq, level, irq_source_id);
 
        WARN_ON(!mutex_is_locked(&kvm->irq_lock));