From: Sasha Levin Date: Wed, 6 Aug 2014 23:08:14 +0000 (-0700) Subject: kernel/smp.c:on_each_cpu_cond(): fix warning in fallback path X-Git-Tag: firefly_0821_release~176^2~3462^2~91 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=618fde872163e782183ce574c77f1123e2be8887;p=firefly-linux-kernel-4.4.55.git kernel/smp.c:on_each_cpu_cond(): fix warning in fallback path The rarely-executed memry-allocation-failed callback path generates a WARN_ON_ONCE() when smp_call_function_single() succeeds. Presumably it's supposed to warn on failures. Signed-off-by: Sasha Levin Cc: Christoph Lameter Cc: Gilad Ben-Yossef Cc: David Rientjes Cc: Joonsoo Kim Cc: Tejun Heo Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/kernel/smp.c b/kernel/smp.c index 487653b5844f..aff8aa14f547 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(); }