aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorAndrew Morton <akpm@osdl.org>2004-10-22 00:29:57 -0700
committerGreg Kroah-Hartman <greg@kroah.com>2004-10-22 00:29:57 -0700
commit28b5fd2263de53d325c84b6b3c3a5ef55263c5aa (patch)
tree7c5799748a388eeb1f47778da1479e5593b8a135 /kernel
parentbbf210d9acfc3d8c75369e8a74111a44784f4d1d (diff)
downloadhistory-28b5fd2263de53d325c84b6b3c3a5ef55263c5aa.tar.gz
[PATCH] remove cpu_run_sbin_hotplug()
From: Keshavamurthy Anil S <anil.s.keshavamurthy@intel.com> Remove cpu_run_sbin_hotplug() - use kobject_hotplug() instead. Signed-off-by: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/cpu.c35
1 files changed, 0 insertions, 35 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c
index 719ba42ff5ee27..52fdf97749a278 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -57,34 +57,6 @@ static inline void check_for_tasks(int cpu)
write_unlock_irq(&tasklist_lock);
}
-/* Notify userspace when a cpu event occurs, by running '/sbin/hotplug
- * cpu' with certain environment variables set. */
-static int cpu_run_sbin_hotplug(unsigned int cpu, const char *action)
-{
- char *argv[3], *envp[6], cpu_str[12], action_str[32], devpath_str[40];
- int i;
-
- sprintf(cpu_str, "CPU=%d", cpu);
- sprintf(action_str, "ACTION=%s", action);
- sprintf(devpath_str, "DEVPATH=devices/system/cpu/cpu%d", cpu);
-
- i = 0;
- argv[i++] = hotplug_path;
- argv[i++] = "cpu";
- argv[i] = NULL;
-
- i = 0;
- /* minimal command environment */
- envp[i++] = "HOME=/";
- envp[i++] = "PATH=/sbin:/bin:/usr/sbin:/usr/bin";
- envp[i++] = cpu_str;
- envp[i++] = action_str;
- envp[i++] = devpath_str;
- envp[i] = NULL;
-
- return call_usermodehelper(argv[0], argv, envp, 0);
-}
-
/* Take this CPU down. */
static int take_cpu_down(void *unused)
{
@@ -170,8 +142,6 @@ int cpu_down(unsigned int cpu)
check_for_tasks(cpu);
- cpu_run_sbin_hotplug(cpu, "offline");
-
out_thread:
err = kthread_stop(p);
out_allowed:
@@ -180,11 +150,6 @@ out:
unlock_cpu_hotplug();
return err;
}
-#else
-static inline int cpu_run_sbin_hotplug(unsigned int cpu, const char *action)
-{
- return 0;
-}
#endif /*CONFIG_HOTPLUG_CPU*/
int __devinit cpu_up(unsigned int cpu)