tracing/trivial: Consolidate error return condition

Consolidate the checks for !enabled and !param to return -EINVAL
in event_enable_func().

Link: http://lkml.kernel.org/r/[email protected]

Signed-off-by: Harsh Prateek Bora <[email protected]>
Signed-off-by: Steven Rostedt <[email protected]>
This commit is contained in:
Harsh Prateek Bora 2013-05-24 12:52:17 +05:30 • committed by Steven Rostedt
commit 8092e808a3

View file

@ -2011,10 +2011,7 @@ event_enable_func(struct ftrace_hash *hash,
int ret;
/* hash funcs only work with set_ftrace_filter */
if (!enabled)
return -EINVAL;
if (!param)
if (!enabled || !param)
return -EINVAL;
system = strsep(&param, ":");