From: Wen Congyang Date: Sat, 23 Feb 2013 00:33:29 +0000 (-0800) Subject: cpu-hotplug, memory-hotplug: try offlining the node when hotremoving a cpu X-Git-Tag: MMI-PSA29.97-13-9~14973^2~103 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=76bba1423f6313ccf7bd7cd400f1f2049bbc740a;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git cpu-hotplug, memory-hotplug: try offlining the node when hotremoving a cpu The node will be offlined when all memory/cpu on the node is hotremoved. So we should try offline the node when hotremoving a cpu on the node. Signed-off-by: Wen Congyang Signed-off-by: Tang Chen Cc: Yasuaki Ishimatsu Cc: David Rientjes Cc: Jiang Liu Cc: Minchan Kim Cc: KOSAKI Motohiro Cc: Mel Gorman Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Len Brown Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/acpi/processor_driver.c b/drivers/acpi/processor_driver.c index cbf1f122666b..df34bd04ae62 100644 --- a/drivers/acpi/processor_driver.c +++ b/drivers/acpi/processor_driver.c @@ -45,6 +45,7 @@ #include #include #include +#include #include #include @@ -641,6 +642,7 @@ static int acpi_processor_remove(struct acpi_device *device) per_cpu(processors, pr->id) = NULL; per_cpu(processor_device_array, pr->id) = NULL; + try_offline_node(cpu_to_node(pr->id)); free: free_cpumask_var(pr->throttling.shared_cpu_map);