summaryrefslogtreecommitdiffstats
path: root/kernel/profile.c
diff options
context:
space:
mode:
authorAkinobu Mita <akinobu.mita@gmail.com>2010-05-26 23:43:32 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2010-05-27 18:12:48 +0200
commit80b5184cc537718122e036afe7e62d202b70d077 (patch)
treed4e2b400f0e951156d64d546fd563fa5a8ab02d3 /kernel/profile.c
parenttopology: convert cpu notifier to return encapsulate errno value (diff)
downloadlinux-80b5184cc537718122e036afe7e62d202b70d077.tar.xz
linux-80b5184cc537718122e036afe7e62d202b70d077.zip
kernel/: convert cpu notifier to return encapsulate errno value
By the previous modification, the cpu notifier can return encapsulate errno value. This converts the cpu notifiers for kernel/*.c Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/profile.c')
-rw-r--r--kernel/profile.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/profile.c b/kernel/profile.c
index dfadc5b729f1..1e6a0d94ea63 100644
--- a/kernel/profile.c
+++ b/kernel/profile.c
@@ -372,7 +372,7 @@ static int __cpuinit profile_cpu_callback(struct notifier_block *info,
GFP_KERNEL | __GFP_ZERO,
0);
if (!page)
- return NOTIFY_BAD;
+ return notifier_from_errno(-ENOMEM);
per_cpu(cpu_profile_hits, cpu)[1] = page_address(page);
}
if (!per_cpu(cpu_profile_hits, cpu)[0]) {
@@ -388,7 +388,7 @@ out_free:
page = virt_to_page(per_cpu(cpu_profile_hits, cpu)[1]);
per_cpu(cpu_profile_hits, cpu)[1] = NULL;
__free_page(page);
- return NOTIFY_BAD;
+ return notifier_from_errno(-ENOMEM);
case CPU_ONLINE:
case CPU_ONLINE_FROZEN:
if (prof_cpu_mask != NULL)