projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
69449bb
)
ftrace: Remove an unneeded NULL check
author
Dan Carpenter
<dan.carpenter@oracle.com>
Wed, 12 Jul 2017 07:33:40 +0000
(10:33 +0300)
committer
Steven Rostedt (VMware)
<rostedt@goodmis.org>
Wed, 12 Jul 2017 13:45:42 +0000
(09:45 -0400)
"func" can't be NULL and it doesn't make sense to check because we've
already derefenced it.
Link:
http://lkml.kernel.org/r/20170712073340.4enzeojeoupuds5a@mwanda
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
kernel/trace/ftrace.c
patch
|
blob
|
history
diff --git
a/kernel/trace/ftrace.c
b/kernel/trace/ftrace.c
index
4706f0e
..
5fb5b40
100644
(file)
--- a/
kernel/trace/ftrace.c
+++ b/
kernel/trace/ftrace.c
@@
-3950,7
+3950,7
@@
static int cache_mod(struct trace_array *tr,
continue;
/* no func matches all */
- if (
!func ||
strcmp(func, "*") == 0 ||
+ if (strcmp(func, "*") == 0 ||
(ftrace_mod->func &&
strcmp(ftrace_mod->func, func) == 0)) {
ret = 0;