aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/pseries/dlpar.c
diff options
context:
space:
mode:
authorRobert Jennings <rcj@linux.vnet.ibm.com>2010-07-22 12:43:44 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2010-07-31 01:05:19 -0400
commitceddee23be9fda04b928aa309fd95931bc4efb96 (patch)
treeb20e27b1932523ca44790a7ea033e7d31d69aed8 /arch/powerpc/platforms/pseries/dlpar.c
parentff4bb7cb9feea3d8851c0e7837dce15822acf11b (diff)
powerpc: ONLINE to OFFLINE CPU state transition during removal
If a CPU remove is attempted using the 'release' interface on hardware which supports extended cede, the CPU will be put in the INACTIVE state rather than the OFFLINE state due to the default preferred_offline_state in that situation. In the INACTIVE state it will fail to be removed. This patch changes the preferred offline state to OFFLINE when an CPU is in the ONLINE state. After cpu_down() is called in dlpar_offline_cpu() the CPU will be OFFLINE and CPU removal can continue. Signed-off-by: Robert Jennings <rcj@linux.vnet.ibm.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/platforms/pseries/dlpar.c')
-rw-r--r--arch/powerpc/platforms/pseries/dlpar.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/pseries/dlpar.c b/arch/powerpc/platforms/pseries/dlpar.c
index d71e58584086..227c1c3d585e 100644
--- a/arch/powerpc/platforms/pseries/dlpar.c
+++ b/arch/powerpc/platforms/pseries/dlpar.c
@@ -463,6 +463,7 @@ static int dlpar_offline_cpu(struct device_node *dn)
463 break; 463 break;
464 464
465 if (get_cpu_current_state(cpu) == CPU_STATE_ONLINE) { 465 if (get_cpu_current_state(cpu) == CPU_STATE_ONLINE) {
466 set_preferred_offline_state(cpu, CPU_STATE_OFFLINE);
466 cpu_maps_update_done(); 467 cpu_maps_update_done();
467 rc = cpu_down(cpu); 468 rc = cpu_down(cpu);
468 if (rc) 469 if (rc)