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

[Xen-devel] [PATCH] xen: arm: perfc: count individual SGIs and PPIs



SPIs are too numerous and not indivcidually as interesting.

Make the exists #IPIS counter x86 specific.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Cc: jbeulich@xxxxxxxx
---
 xen/arch/arm/gic.c               | 2 +-
 xen/arch/arm/irq.c               | 4 ++--
 xen/include/asm-arm/perfc_defn.h | 3 ++-
 xen/include/asm-x86/perfc_defn.h | 1 +
 xen/include/xen/perfc_defn.h     | 1 -
 5 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/xen/arch/arm/gic.c b/xen/arch/arm/gic.c
index 1e1e5ba..b0b0999 100644
--- a/xen/arch/arm/gic.c
+++ b/xen/arch/arm/gic.c
@@ -609,7 +609,7 @@ static void do_sgi(struct cpu_user_regs *regs, enum gic_sgi 
sgi)
     /* Lower the priority */
     struct irq_desc *desc = irq_to_desc(sgi);
 
-    perfc_incr(ipis);
+    perfc_incra(sgis, sgi);
 
     /* Lower the priority */
     gic_hw_ops->eoi_irq(desc);
diff --git a/xen/arch/arm/irq.c b/xen/arch/arm/irq.c
index 1f38605..5031777 100644
--- a/xen/arch/arm/irq.c
+++ b/xen/arch/arm/irq.c
@@ -192,8 +192,8 @@ void do_IRQ(struct cpu_user_regs *regs, unsigned int irq, 
int is_fiq)
 
     ASSERT(irq >= 16); /* SGIs do not come down this path */
 
-    if (irq < 32)
-        perfc_incr(ppis);
+    if ( irq < 32 )
+        perfc_incra(ppis, irq - 16);
     else
         perfc_incr(spis);
 
diff --git a/xen/include/asm-arm/perfc_defn.h b/xen/include/asm-arm/perfc_defn.h
index 69fabe7..3e21590 100644
--- a/xen/include/asm-arm/perfc_defn.h
+++ b/xen/include/asm-arm/perfc_defn.h
@@ -62,7 +62,8 @@ PERFCOUNTER(vtimer_phys_inject,   "vtimer: phys expired, 
injected")
 PERFCOUNTER(vtimer_phys_masked,   "vtimer: phys expired, masked")
 PERFCOUNTER(vtimer_virt_inject,   "vtimer: virt expired, injected")
 
-PERFCOUNTER(ppis,                 "#PPIs")
+PERFCOUNTER_ARRAY(sgis,           "#SGIs", 16)
+PERFCOUNTER_ARRAY(ppis,           "#PPIs", 16)
 PERFCOUNTER(spis,                 "#SPIs")
 PERFCOUNTER(guest_irqs,           "#GUEST-IRQS")
 
diff --git a/xen/include/asm-x86/perfc_defn.h b/xen/include/asm-x86/perfc_defn.h
index 9ef092e..c96a3f0 100644
--- a/xen/include/asm-x86/perfc_defn.h
+++ b/xen/include/asm-x86/perfc_defn.h
@@ -3,6 +3,7 @@
 /*#define __XEN_PERFC_DEFN_H__*/
 
 PERFCOUNTER_ARRAY(exceptions,           "exceptions", 32)
+PERFCOUNTER(ipis,                       "#IPIs")
 
 #define VMX_PERF_EXIT_REASON_SIZE 56
 #define VMX_PERF_VECTOR_SIZE 0x20
diff --git a/xen/include/xen/perfc_defn.h b/xen/include/xen/perfc_defn.h
index 034c7d3..2b39fa9 100644
--- a/xen/include/xen/perfc_defn.h
+++ b/xen/include/xen/perfc_defn.h
@@ -10,7 +10,6 @@ PERFCOUNTER(calls_to_multicall,         "calls to multicall")
 PERFCOUNTER(calls_from_multicall,       "calls from multicall")
 
 PERFCOUNTER(irqs,                   "#interrupts")
-PERFCOUNTER(ipis,                   "#IPIs")
 
 /* Generic scheduler counters (applicable to all schedulers) */
 PERFCOUNTER(sched_irq,              "sched: timer")
-- 
2.1.4


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


 


Rackspace

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