summaryrefslogtreecommitdiffstats
path: root/kernel/trace/ftrace.c
diff options
context:
space:
mode:
authorSteven Rostedt (Red Hat) <rostedt@goodmis.org>2015-01-20 17:14:16 +0100
committerSteven Rostedt <rostedt@goodmis.org>2015-01-22 17:19:49 +0100
commit14a5ae40f0def33a422a45b2ed09198adb7bf11c (patch)
tree59fbab59a2c6519b5c95feda7174e58311e3aa2a /kernel/trace/ftrace.c
parenttracing: Remove unneeded includes of debugfs.h and fs.h (diff)
downloadlinux-14a5ae40f0def33a422a45b2ed09198adb7bf11c.tar.xz
linux-14a5ae40f0def33a422a45b2ed09198adb7bf11c.zip
tracing: Use IS_ERR() check for return value of tracing_init_dentry()
tracing_init_dentry() will soon return NULL as a valid pointer for the top level tracing directroy. NULL can not be used as an error value. Instead, switch to ERR_PTR() and check the return status with IS_ERR(). Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/ftrace.c')
-rw-r--r--kernel/trace/ftrace.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 929a733d302e..80c9d34540dd 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -5419,7 +5419,7 @@ static __init int ftrace_init_debugfs(void)
struct dentry *d_tracer;
d_tracer = tracing_init_dentry();
- if (!d_tracer)
+ if (IS_ERR(d_tracer))
return 0;
ftrace_init_dyn_debugfs(d_tracer);