Skip to content

Commit

Permalink
[PATCH] generate hotplug events for cpu online
Browse files Browse the repository at this point in the history
We already do kobject_hotplug for cpu offline; this adds a kobject_hotplug
call for the online case.  This is being requested by developers of an
application which wants to be notified about both kinds of events.

Signed-off-by: Nathan Lynch <ntl@pobox.com>
Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Nathan Lynch authored and Linus Torvalds committed Jun 25, 2005
1 parent a9fa06c commit fb69c39
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/base/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ static ssize_t store_online(struct sys_device *dev, const char *buf,
ret = smp_prepare_cpu(cpu->sysdev.id);
if (!ret)
ret = cpu_up(cpu->sysdev.id);
if (!ret)
kobject_hotplug(&dev->kobj, KOBJ_ONLINE);
break;
default:
ret = -EINVAL;
Expand Down

0 comments on commit fb69c39

Please sign in to comment.