ftrace: fix check for return value of register_module_notifier in event_trace_init

register_module_notifier() returns zero in the success case.
So fix the inverted fail case check in trace events modules
handler.

[ Impact: fix spurious warning on ftrace initialization]

Reported-by: Li Zefan <lizf@cn.fujitsu.com>
Signed-off-by: Ming Lei <tom.leiming@gmail.com>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
This commit is contained in:
Ming Lei 2009-05-18 23:04:46 +08:00 committed by Frederic Weisbecker
parent fd51d251e4
commit 5537937696

View File

@ -1174,7 +1174,7 @@ static __init int event_trace_init(void)
}
ret = register_module_notifier(&trace_module_nb);
if (!ret)
if (ret)
pr_warning("Failed to register trace events module notifier\n");
return 0;