* [PATCH] kernel: smp: correct warning in on_each_cpu_cond
@ 2014-08-04 21:02 Sasha Levin
0 siblings, 0 replies; only message in thread
From: Sasha Levin @ 2014-08-04 21:02 UTC (permalink / raw)
To: gilad; +Cc: iamjoonsoo.kim, akpm, linux-kernel, Sasha Levin
smp_call_function_single() returns 0 on success, not the other
way around. Fix the warning to trigger on failure rather than
success.
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
---
kernel/smp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/smp.c b/kernel/smp.c
index 487653b..aff8aa1 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -670,7 +670,7 @@ void on_each_cpu_cond(bool (*cond_func)(int cpu, void *info),
if (cond_func(cpu, info)) {
ret = smp_call_function_single(cpu, func,
info, wait);
- WARN_ON_ONCE(!ret);
+ WARN_ON_ONCE(ret);
}
preempt_enable();
}
--
1.7.10.4
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2014-08-04 21:02 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-04 21:02 [PATCH] kernel: smp: correct warning in on_each_cpu_cond Sasha Levin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®