[PATCH] powerpc: don't enable cpu hotplug on mpic-based pseries

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Olof Johansson
Date: Tuesday, October 9, 2007 - 5:08 pm

Don't allow cpu hotplug on systems lacking XICS interrupt controller,
since current platform code is hardcoded for it.


Signed-off-by: Olof Johansson <olof@lixom.net>


diff --git a/arch/powerpc/platforms/pseries/hotplug-cpu.c b/arch/powerpc/platforms/pseries/hotplug-cpu.c
index 9711eb0..e29b890 100644
--- a/arch/powerpc/platforms/pseries/hotplug-cpu.c
+++ b/arch/powerpc/platforms/pseries/hotplug-cpu.c
@@ -252,6 +252,19 @@ static struct notifier_block pseries_smp_nb = {
 
 static int __init pseries_cpu_hotplug_init(void)
 {
+	struct device_node *np;
+	const char *typep;
+
+	for (np = NULL; (np = of_find_node_by_name(np,
+						   "interrupt-controller"));) {
+		typep = of_get_property(np, "compatible", NULL);
+		if (strstr(typep, "open-pic")) {
+			printk(KERN_INFO "CPU Hotplug not supported on "
+				"systems using MPIC\n");
+			return 0;
+		}
+	}
+
 	rtas_stop_self_args.token = rtas_token("stop-self");
 	qcss_tok = rtas_token("query-cpu-stopped-state");
 
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[patch 00/12] 2.6.22.10 -stable review, Greg KH, (Mon Oct 8, 11:05 am)
[patch 03/12] sky2: fix VLAN receive processing, Greg KH, (Mon Oct 8, 11:06 am)
[patch 04/12] sky2: fix transmit state on resume, Greg KH, (Mon Oct 8, 11:06 am)
[patch 05/12] libata: update drive blacklists, Greg KH, (Mon Oct 8, 11:06 am)
[patch 06/12] Fix ppp_mppe kernel stack usage., Greg KH, (Mon Oct 8, 11:06 am)
[patch 09/12] Fix SMP poweroff hangs, Greg KH, (Mon Oct 8, 11:06 am)
Re: [patch 00/12] 2.6.22.10 -stable review, Greg KH, (Mon Oct 8, 11:09 am)
Re: [patch 09/12] Fix SMP poweroff hangs, Olof Johansson, (Tue Oct 9, 8:17 am)
Re: [stable] [patch 09/12] Fix SMP poweroff hangs, Thomas Gleixner, (Tue Oct 9, 4:21 pm)
Re: [stable] [patch 09/12] Fix SMP poweroff hangs, Linus Torvalds, (Tue Oct 9, 4:27 pm)
Re: [stable] [patch 09/12] Fix SMP poweroff hangs, Thomas Gleixner, (Tue Oct 9, 4:35 pm)
Re: [stable] [patch 09/12] Fix SMP poweroff hangs, Olof Johansson, (Tue Oct 9, 5:03 pm)
[PATCH] powerpc: don't enable cpu hotplug on mpic-based ps ..., Olof Johansson, (Tue Oct 9, 5:08 pm)
Re: [stable] [patch 09/12] Fix SMP poweroff hangs, Linus Torvalds, (Tue Oct 9, 10:29 pm)
Re: [stable] [patch 09/12] Fix SMP poweroff hangs, Paul Mackerras, (Wed Oct 10, 5:24 pm)