From mboxrd@z Thu Jan 1 00:00:00 1970 From: Guanqun Lu Subject: [PATCH 3 of 3] fix S3 resume error Date: Mon, 23 Feb 2009 23:27:49 +0800 Message-ID: <04e7e4e8519fbbd2ec14.1235402869@localhost.localdomain> References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org # HG changeset patch # User Guanqun Lu # Date 1235401627 -28800 # Node ID 04e7e4e8519fbbd2ec141875d466ea8ca038d553 # Parent 0e17f070db2aa92bc74f29245cdb8528aa72bbe3 fix S3 resume error spin_lock() usage in do_settime() in this situation is invoked when irq is disabled, which causes check_lock() BUG_ON(). We bypass the check by using spin_debug_disable(). It's safe since no other CPUs are online yet at this moment. Signed-off-by: Guanqun Lu diff -r 0e17f070db2a -r 04e7e4e8519f xen/arch/x86/time.c --- a/xen/arch/x86/time.c Mon Feb 23 23:07:01 2009 +0800 +++ b/xen/arch/x86/time.c Mon Feb 23 23:07:07 2009 +0800 @@ -1300,7 +1300,9 @@ int time_resume(void) init_percpu_time(); + spin_debug_disable(); do_settime(get_cmos_time() + cmos_utc_offset, 0, NOW()); + spin_debug_enable(); update_vcpu_system_time(current);