WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] x86: add irq count for IPIs

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] x86: add irq count for IPIs
From: Xen patchbot-unstable <patchbot@xxxxxxx>
Date: Fri, 02 Sep 2011 17:44:19 +0100
Delivery-date: Fri, 02 Sep 2011 09:44:51 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Kevin Tian <kevin.tian@xxxxxxxxx>
# Date 1314800303 -3600
# Node ID 42d76c68b2bfbedee3e5f79d32344e14bce48b0f
# Parent  51983821efa4db4040ae1c5063a4404791597699
x86: add irq count for IPIs

such count is useful to assist decision make in cpuidle governor,
while w/o this patch only device interrupts through do_IRQ is
currently counted.

Signed-off-by: Kevin Tian <kevin.tian@xxxxxxxxx>
---


diff -r 51983821efa4 -r 42d76c68b2bf xen/arch/x86/apic.c
--- a/xen/arch/x86/apic.c       Wed Aug 31 15:17:45 2011 +0100
+++ b/xen/arch/x86/apic.c       Wed Aug 31 15:18:23 2011 +0100
@@ -1332,6 +1332,7 @@
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
     ack_APIC_irq();
     perfc_incr(apic_timer);
+    this_cpu(irq_count)++;
     raise_softirq(TIMER_SOFTIRQ);
     set_irq_regs(old_regs);
 }
@@ -1353,6 +1354,7 @@
     unsigned long v;
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
 
+    this_cpu(irq_count)++;
     irq_enter();
 
     /*
@@ -1388,6 +1390,7 @@
     unsigned long v, v1;
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
 
+    this_cpu(irq_count)++;
     irq_enter();
     /* First tickle the hardware, only then report what went on. -- REW */
     v = apic_read(APIC_ESR);
@@ -1419,6 +1422,7 @@
 {
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
     ack_APIC_irq();
+    this_cpu(irq_count)++;
     hvm_do_pmu_interrupt(regs);
     set_irq_regs(old_regs);
 }
diff -r 51983821efa4 -r 42d76c68b2bf xen/arch/x86/cpu/mcheck/mce_intel.c
--- a/xen/arch/x86/cpu/mcheck/mce_intel.c       Wed Aug 31 15:17:45 2011 +0100
+++ b/xen/arch/x86/cpu/mcheck/mce_intel.c       Wed Aug 31 15:18:23 2011 +0100
@@ -77,6 +77,7 @@
 fastcall void smp_thermal_interrupt(struct cpu_user_regs *regs)
 {
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
+    this_cpu(irq_count)++;
     irq_enter();
     vendor_thermal_interrupt(regs);
     irq_exit();
@@ -1147,6 +1148,7 @@
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
 
     ack_APIC_irq();
+    this_cpu(irq_count)++;
     irq_enter();
 
     mctc = mcheck_mca_logout(
diff -r 51983821efa4 -r 42d76c68b2bf xen/arch/x86/io_apic.c
--- a/xen/arch/x86/io_apic.c    Wed Aug 31 15:17:45 2011 +0100
+++ b/xen/arch/x86/io_apic.c    Wed Aug 31 15:18:23 2011 +0100
@@ -441,6 +441,7 @@
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
 
     ack_APIC_irq();
+    this_cpu(irq_count)++;
     irq_enter();
 
     me = smp_processor_id();
diff -r 51983821efa4 -r 42d76c68b2bf xen/arch/x86/smp.c
--- a/xen/arch/x86/smp.c        Wed Aug 31 15:17:45 2011 +0100
+++ b/xen/arch/x86/smp.c        Wed Aug 31 15:18:23 2011 +0100
@@ -221,6 +221,7 @@
 {
     ack_APIC_irq();
     perfc_incr(ipis);
+    this_cpu(irq_count)++;
     irq_enter();
     if ( !__sync_local_execstate() ||
          (flush_flags & (FLUSH_TLB_GLOBAL | FLUSH_CACHE)) )
@@ -385,6 +386,7 @@
     struct cpu_user_regs *old_regs = set_irq_regs(regs);
     ack_APIC_irq();
     perfc_incr(ipis);
+    this_cpu(irq_count)++;
     set_irq_regs(old_regs);
 }
 
@@ -421,6 +423,7 @@
 
     ack_APIC_irq();
     perfc_incr(ipis);
+    this_cpu(irq_count)++;
     __smp_call_function_interrupt();
     set_irq_regs(old_regs);
 }

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] x86: add irq count for IPIs, Xen patchbot-unstable <=