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] linux: Fix IRQ disable/enable logic acros

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] linux: Fix IRQ disable/enable logic across save/restore.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 10 Apr 2007 14:00:57 -0700
Delivery-date: Tue, 10 Apr 2007 14:00:45 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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 kfraser@xxxxxxxxxxxxxxxxxxxxx
# Date 1176227360 -3600
# Node ID 4dc14c591e6cf5177974f244db9ae4f609521417
# Parent  e8caf7802f3feede444dcf33a4cc1629dd359249
linux: Fix IRQ disable/enable logic across save/restore.
stop_machine_run() executes our callback function with interrupts
disabled.
Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>
---
 linux-2.6-xen-sparse/drivers/xen/core/machine_reboot.c |   14 +++++++++-----
 1 files changed, 9 insertions(+), 5 deletions(-)

diff -r e8caf7802f3f -r 4dc14c591e6c 
linux-2.6-xen-sparse/drivers/xen/core/machine_reboot.c
--- a/linux-2.6-xen-sparse/drivers/xen/core/machine_reboot.c    Tue Apr 10 
17:29:16 2007 +0100
+++ b/linux-2.6-xen-sparse/drivers/xen/core/machine_reboot.c    Tue Apr 10 
18:49:20 2007 +0100
@@ -127,8 +127,10 @@ static int take_machine_down(void *p_fas
        extern void time_resume(void);
 
        if (fast_suspend) {
-               preempt_disable();
-       } else {
+               BUG_ON(!irqs_disabled());
+       } else {
+               BUG_ON(irqs_disabled());
+
                for (;;) {
                        err = smp_suspend();
                        if (err)
@@ -143,11 +145,11 @@ static int take_machine_down(void *p_fas
                        preempt_enable();
                        xenbus_suspend_cancel();
                }
+
+               local_irq_disable();
        }
 
        mm_pin_all();
-       local_irq_disable();
-       preempt_enable();
        gnttab_suspend();
        pre_suspend();
 
@@ -178,7 +180,9 @@ static int take_machine_down(void *p_fas
 #endif
        }
        time_resume();
-       local_irq_enable();
+
+       if (!fast_suspend)
+               local_irq_enable();
 
        return suspend_cancelled;
 }

_______________________________________________
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] linux: Fix IRQ disable/enable logic across save/restore., Xen patchbot-unstable <=