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] Fix calling point for do_softirq, which should only be c

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Fix calling point for do_softirq, which should only be checked
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 03 Aug 2005 05:26:30 -0400
Delivery-date: Wed, 03 Aug 2005 09:29:03 +0000
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/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/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 fred@xxxxxxxxxxxxxxxxxxxxx
# Node ID 9be7fe98a5565bf8f6297332e0367cd6904f52af
# Parent  bd77de43ed4ad21f0bf96afc58f1dce0695df12f
Fix calling point for do_softirq, which should only be checked
at the very point back to guest domain. Or else unexpected domain
switch may happen in nested interrupt in Xen.

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

diff -r bd77de43ed4a -r 9be7fe98a556 xen/arch/ia64/patch/linux-2.6.11/irq_ia64.c
--- a/xen/arch/ia64/patch/linux-2.6.11/irq_ia64.c       Tue Aug  2 10:13:02 2005
+++ b/xen/arch/ia64/patch/linux-2.6.11/irq_ia64.c       Tue Aug  2 10:47:41 2005
@@ -20,11 +20,19 @@
                        __do_IRQ(local_vector_to_irq(vector), regs);
  
                        /*
-@@ -167,6 +173,95 @@
+@@ -167,6 +173,103 @@
        irq_exit();
  }
  
 +#ifdef  CONFIG_VTI
++#define vmx_irq_enter()               \
++      add_preempt_count(HARDIRQ_OFFSET);
++
++/* Now softirq will be checked when leaving hypervisor, or else
++ * scheduler irq will be executed too early.
++ */
++#define vmx_irq_exit(void)    \
++      sub_preempt_count(HARDIRQ_OFFSET);
 +/*
 + * That's where the IVT branches when we get an external
 + * interrupt. This branches to the correct hardware IRQ handler via
@@ -72,7 +80,7 @@
 +       * 16 (without this, it would be ~240, which could easily lead
 +       * to kernel stack overflows).
 +       */
-+      irq_enter();
++      vmx_irq_enter();
 +      saved_tpr = ia64_getreg(_IA64_REG_CR_TPR);
 +      ia64_srlz_d();
 +      while (vector != IA64_SPURIOUS_INT_VECTOR) {
@@ -106,7 +114,7 @@
 +       * handler needs to be able to wait for further keyboard interrupts, 
which can't
 +       * come through until ia64_eoi() has been done.
 +       */
-+      irq_exit();
++      vmx_irq_exit();
 +      if ( wake_dom0 && current != dom0 ) 
 +              domain_wake(dom0->vcpu[0]);
 +}

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Fix calling point for do_softirq, which should only be checked, Xen patchbot -unstable <=