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-4.0-testing] x86: don't crash when a CPU cannot be

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-4.0-testing] x86: don't crash when a CPU cannot be brought online during boot
From: "Xen patchbot-4.0-testing" <patchbot-4.0-testing@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 17 Jan 2011 07:52:27 -0800
Delivery-date: Mon, 17 Jan 2011 07:53:47 -0800
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 Keir Fraser <keir@xxxxxxx>
# Date 1294742461 0
# Node ID 7a203c60d588a7a15a28a6fb16c69feafd157e0d
# Parent  64bb7d9904a64cc4561c6d541d857acf46e42180
x86: don't crash when a CPU cannot be brought online during boot

x86_cpu_to_apicid[] gets set to BAD_APICID when bringup of a secondary
CPU fails, yet srat_detect_node() wants to use this as array index.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
 xen/arch/x86/setup.c |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff -r 64bb7d9904a6 -r 7a203c60d588 xen/arch/x86/setup.c
--- a/xen/arch/x86/setup.c      Tue Jan 11 10:40:17 2011 +0000
+++ b/xen/arch/x86/setup.c      Tue Jan 11 10:41:01 2011 +0000
@@ -1098,10 +1098,13 @@ void __init __start_xen(unsigned long mb
             __cpu_up(i);
         }
 
-        /* Set up cpu_to_node[]. */
-        srat_detect_node(i);
-        /* Set up node_to_cpumask based on cpu_to_node[]. */
-        numa_add_cpu(i);        
+        if ( cpu_online(i) )
+        {
+            /* Set up cpu_to_node[]. */
+            srat_detect_node(i);
+            /* Set up node_to_cpumask based on cpu_to_node[]. */
+            numa_add_cpu(i);
+        }
     }
 
     printk("Brought up %ld CPUs\n", (long)num_online_cpus());

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-4.0-testing] x86: don't crash when a CPU cannot be brought online during boot, Xen patchbot-4.0-testing <=