summaryrefslogtreecommitdiffstats
path: root/Documentation/cpu-hotplug.txt
diff options
context:
space:
mode:
authorJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-08-06 12:42:33 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-08-06 12:42:33 -0500
commit00dd7b7d26a3bf3780cfcebfdde2b86126b3a082 (patch)
tree5129fd1abc99d0c58a520938f28bf330ae94ef30 /Documentation/cpu-hotplug.txt
parent58b3ac07fed31ffc1349380b78305af6522fe1f4 (diff)
parent6e1e63259b1e01f047796e7985d960ca040993e6 (diff)
downloadop-kernel-dev-00dd7b7d26a3bf3780cfcebfdde2b86126b3a082.zip
op-kernel-dev-00dd7b7d26a3bf3780cfcebfdde2b86126b3a082.tar.gz
Merge ../linux-2.6
Conflicts: arch/ia64/hp/sim/simscsi.c Stylistic differences in two separate fixes for buffer->request_buffer problem. Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'Documentation/cpu-hotplug.txt')
-rw-r--r--Documentation/cpu-hotplug.txt12
1 files changed, 10 insertions, 2 deletions
diff --git a/Documentation/cpu-hotplug.txt b/Documentation/cpu-hotplug.txt
index 1bcf699..bc107cb 100644
--- a/Documentation/cpu-hotplug.txt
+++ b/Documentation/cpu-hotplug.txt
@@ -251,16 +251,24 @@ A: This is what you would need in your kernel code to receive notifications.
return NOTIFY_OK;
}
- static struct notifier_block foobar_cpu_notifer =
+ static struct notifier_block __cpuinitdata foobar_cpu_notifer =
{
.notifier_call = foobar_cpu_callback,
};
+You need to call register_cpu_notifier() from your init function.
+Init functions could be of two types:
+1. early init (init function called when only the boot processor is online).
+2. late init (init function called _after_ all the CPUs are online).
-In your init function,
+For the first case, you should add the following to your init function
register_cpu_notifier(&foobar_cpu_notifier);
+For the second case, you should add the following to your init function
+
+ register_hotcpu_notifier(&foobar_cpu_notifier);
+
You can fail PREPARE notifiers if something doesn't work to prepare resources.
This will stop the activity and send a following CANCELED event back.
OpenPOWER on IntegriCloud