diff options
author | Chandra Seetharaman <sekharan@us.ibm.com> | 2006-07-30 06:03:37 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-07-31 16:28:39 -0400 |
commit | be6b5a3505fa0cd54c3b5959a39293f47c648980 (patch) | |
tree | a7171d3dc5acf71c21f954b5c4f4906904873a0b /arch/ia64/kernel/palinfo.c | |
parent | 7c7165c90801609b70492e50b2a9c69a677c573a (diff) |
[PATCH] cpu hotplug: use hotplug version of registration in late inits
Use hotplug version of register_cpu_notifier in late init functions.
Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Andi Kleen <ak@muc.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/ia64/kernel/palinfo.c')
-rw-r--r-- | arch/ia64/kernel/palinfo.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/arch/ia64/kernel/palinfo.c b/arch/ia64/kernel/palinfo.c index 3f5bac59209a..ab5b52413e91 100644 --- a/arch/ia64/kernel/palinfo.c +++ b/arch/ia64/kernel/palinfo.c | |||
@@ -958,9 +958,9 @@ remove_palinfo_proc_entries(unsigned int hcpu) | |||
958 | } | 958 | } |
959 | } | 959 | } |
960 | 960 | ||
961 | static int __cpuinit palinfo_cpu_callback(struct notifier_block *nfb, | 961 | #ifdef CONFIG_HOTPLUG_CPU |
962 | unsigned long action, | 962 | static int palinfo_cpu_callback(struct notifier_block *nfb, |
963 | void *hcpu) | 963 | unsigned long action, void *hcpu) |
964 | { | 964 | { |
965 | unsigned int hotcpu = (unsigned long)hcpu; | 965 | unsigned int hotcpu = (unsigned long)hcpu; |
966 | 966 | ||
@@ -968,20 +968,19 @@ static int __cpuinit palinfo_cpu_callback(struct notifier_block *nfb, | |||
968 | case CPU_ONLINE: | 968 | case CPU_ONLINE: |
969 | create_palinfo_proc_entries(hotcpu); | 969 | create_palinfo_proc_entries(hotcpu); |
970 | break; | 970 | break; |
971 | #ifdef CONFIG_HOTPLUG_CPU | ||
972 | case CPU_DEAD: | 971 | case CPU_DEAD: |
973 | remove_palinfo_proc_entries(hotcpu); | 972 | remove_palinfo_proc_entries(hotcpu); |
974 | break; | 973 | break; |
975 | #endif | ||
976 | } | 974 | } |
977 | return NOTIFY_OK; | 975 | return NOTIFY_OK; |
978 | } | 976 | } |
979 | 977 | ||
980 | static struct notifier_block __cpuinitdata palinfo_cpu_notifier = | 978 | static struct notifier_block palinfo_cpu_notifier = |
981 | { | 979 | { |
982 | .notifier_call = palinfo_cpu_callback, | 980 | .notifier_call = palinfo_cpu_callback, |
983 | .priority = 0, | 981 | .priority = 0, |
984 | }; | 982 | }; |
983 | #endif | ||
985 | 984 | ||
986 | static int __init | 985 | static int __init |
987 | palinfo_init(void) | 986 | palinfo_init(void) |
@@ -1020,7 +1019,7 @@ palinfo_exit(void) | |||
1020 | /* | 1019 | /* |
1021 | * Unregister from cpu notifier callbacks | 1020 | * Unregister from cpu notifier callbacks |
1022 | */ | 1021 | */ |
1023 | unregister_cpu_notifier(&palinfo_cpu_notifier); | 1022 | unregister_hotcpu_notifier(&palinfo_cpu_notifier); |
1024 | } | 1023 | } |
1025 | 1024 | ||
1026 | module_init(palinfo_init); | 1025 | module_init(palinfo_init); |