提交 633ddaa7 编写于 作者: S Steven Rostedt

tracing: fix return value to registering events

The registering of events had the return value check backwards.
A zero returned is success, the check had it as a failure.

This patch also fixes a missing "\n" in the warning that the check
failed.
Reported-by: NIngo Molnar <mingo@elte.hu>
Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
上级 c79a61f5
无相关合并请求
......@@ -120,9 +120,9 @@ static int ftrace_reg_event_##call(void) \
int ret; \
\
ret = register_trace_##call(ftrace_event_##call); \
if (!ret) \
if (ret) \
pr_info("event trace: Could not activate trace point " \
"probe to " #call); \
"probe to " #call "\n"); \
return ret; \
} \
\
......@@ -195,9 +195,9 @@ static int ftrace_raw_reg_event_##call(void) \
int ret; \
\
ret = register_trace_##call(ftrace_raw_event_##call); \
if (!ret) \
if (ret) \
pr_info("event trace: Could not activate trace point " \
"probe to " #call); \
"probe to " #call "\n"); \
return ret; \
} \
\
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册
反馈
建议
客服 返回
顶部