[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH 07/15] tools: tracing: handle IRQs on/off events in xentrace and xenalyze



so the trace will show properly decoded info,
rather than just a bunch of hex codes.

Signed-off-by: Dario Faggioli <dario.faggioli@xxxxxxxxxx>
---
Cc: George Dunlap <george.dunlap@xxxxxxxxxxxxx>
Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
Cc: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
Cc: Wei Liu <wei.liu2@xxxxxxxxxx>
Cc: Jennifer Herbert <jennifer.herbert@xxxxxxxxxx>
---
 tools/xentrace/formats    |    2 ++
 tools/xentrace/xenalyze.c |   16 ++++++++++++++++
 2 files changed, 18 insertions(+)

diff --git a/tools/xentrace/formats b/tools/xentrace/formats
index 00c29b8..2e653ca 100644
--- a/tools/xentrace/formats
+++ b/tools/xentrace/formats
@@ -202,6 +202,8 @@
 0x0080200a  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  do_irq [ irq = %(1)d ]
 0x0080200b  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  do_guest_irq [ irq = %(1)d ]
 0x0080200c  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  irq_exit [ irq = %(1)d, status 
= 0x%(2)x, in_irq = %(3)d ]
+0x0080200d  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  irq_disable [ from = 
0x%(2)08x%(1)08x ]
+0x0080200e  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  irq_enable  [ from = 
0x%(2)08x%(1)08x ]
 
 0x00084001  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  hpet create [ tn = %(1)d, irq 
= %(2)d, delta = 0x%(4)08x%(3)08x, period = 0x%(6)08x%(5)08x ]
 0x00084002  CPU%(cpu)d  %(tsc)d (+%(reltsc)8d)  pit create [ delta = 
0x%(1)016x, period = 0x%(2)016x ]
diff --git a/tools/xentrace/xenalyze.c b/tools/xentrace/xenalyze.c
index 3c2f600..c4a8340 100644
--- a/tools/xentrace/xenalyze.c
+++ b/tools/xentrace/xenalyze.c
@@ -8562,6 +8562,22 @@ void irq_process(struct pcpu_info *p) {
         }
         break;
     }
+    case TRC_HW_IRQ_DISABLE:
+    case TRC_HW_IRQ_ENABLE:
+    {
+        struct {
+            uint64_t addr;
+        } *r = (typeof(r))ri->d;
+
+        if ( opt.dump_all )
+        {
+            printf(" %s irq_%s, from %p\n",
+                   ri->dump_header,
+                   ri->event == TRC_HW_IRQ_DISABLE ? "disable" : "enable",
+                   (void*)r->addr);
+        }
+        break;
+    }
     case TRC_HW_IRQ_CLEAR_VECTOR:
     case TRC_HW_IRQ_MOVE_FINISH :
     default:


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.