tracing: A minor cleanup for create_system_filter()
The first two parameters should be reduced to one, as @tr is simply @dir->tr. Link: https://lkml.kernel.org/r/20210324205642.65e03248@oasis.local.home Link: https://lkml.kernel.org/r/20210325163752.128407-1-hqjagain@gmail.com Suggested-by: Steven Rostedt (VMware) <rostedt@goodmis.org> Signed-off-by: Qiujun Huang <hqjagain@gmail.com> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
This commit is contained in:
parent
4613bdcc12
commit
30c3d39f7f
|
@ -1750,7 +1750,6 @@ int create_event_filter(struct trace_array *tr,
|
|||
* and always remembers @filter_str.
|
||||
*/
|
||||
static int create_system_filter(struct trace_subsystem_dir *dir,
|
||||
struct trace_array *tr,
|
||||
char *filter_str, struct event_filter **filterp)
|
||||
{
|
||||
struct filter_parse_error *pe = NULL;
|
||||
|
@ -1758,13 +1757,13 @@ static int create_system_filter(struct trace_subsystem_dir *dir,
|
|||
|
||||
err = create_filter_start(filter_str, true, &pe, filterp);
|
||||
if (!err) {
|
||||
err = process_system_preds(dir, tr, pe, filter_str);
|
||||
err = process_system_preds(dir, dir->tr, pe, filter_str);
|
||||
if (!err) {
|
||||
/* System filters just show a default message */
|
||||
kfree((*filterp)->filter_string);
|
||||
(*filterp)->filter_string = NULL;
|
||||
} else {
|
||||
append_filter_err(tr, pe, *filterp);
|
||||
append_filter_err(dir->tr, pe, *filterp);
|
||||
}
|
||||
}
|
||||
create_filter_finish(pe);
|
||||
|
@ -1852,7 +1851,7 @@ int apply_subsystem_event_filter(struct trace_subsystem_dir *dir,
|
|||
goto out_unlock;
|
||||
}
|
||||
|
||||
err = create_system_filter(dir, tr, filter_string, &filter);
|
||||
err = create_system_filter(dir, filter_string, &filter);
|
||||
if (filter) {
|
||||
/*
|
||||
* No event actually uses the system filter
|
||||
|
|
Loading…
Reference in New Issue