mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@kernel.org>
To: Oleg Nesterov <oleg@redhat.com>
Cc: Steven Rostedt <rostedt@goodmis.org>,
	Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>,
	Srikar Dronamraju <srikar@linux.vnet.ibm.com>,
	Tom Zanussi <tom.zanussi@linux.intel.com>,
	"zhangwei(Jovi)" <jovi.zhangwei@huawei.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 7/7] tracing: change filter_free_subsystem_*() to check ->subsystem rather then ->name
Date: Mon, 14 Jul 2014 22:58:19 +0900	[thread overview]
Message-ID: <1405346299.1745.21.camel@leonhard> (raw)
In-Reply-To: <20140711190655.GA19549@redhat.com>

2014-07-11 (금), 21:06 +0200, Oleg Nesterov:
> filter_free_subsystem_preds() and filter_free_subsystem_filters()
> can rely on file->system->subsystem and avoid strcmp().

I guess the same can go to the replace_system_preds() too.

Thanks,
Namhyung


> 
> Signed-off-by: Oleg Nesterov <oleg@redhat.com>
> ---
>  kernel/trace/trace_events_filter.c |    9 ++-------
>  1 files changed, 2 insertions(+), 7 deletions(-)
> 
> diff --git a/kernel/trace/trace_events_filter.c b/kernel/trace/trace_events_filter.c
> index 54a125c..59655bc 100644
> --- a/kernel/trace/trace_events_filter.c
> +++ b/kernel/trace/trace_events_filter.c
> @@ -846,13 +846,10 @@ static void filter_free_subsystem_preds(struct event_subsystem *system,
>  					struct trace_array *tr)
>  {
>  	struct ftrace_event_file *file;
> -	struct ftrace_event_call *call;
>  
>  	list_for_each_entry(file, &tr->events, list) {
> -		call = file->event_call;
> -		if (strcmp(call->class->system, system->name) != 0)
> +		if (file->system->subsystem != system)
>  			continue;
> -
>  		__remove_filter(file);
>  	}
>  }
> @@ -874,11 +871,9 @@ static void filter_free_subsystem_filters(struct event_subsystem *system,
>  					  struct trace_array *tr)
>  {
>  	struct ftrace_event_file *file;
> -	struct ftrace_event_call *call;
>  
>  	list_for_each_entry(file, &tr->events, list) {
> -		call = file->event_call;
> -		if (strcmp(call->class->system, system->name) != 0)
> +		if (file->system->subsystem != system)
>  			continue;
>  		__free_subsystem_filter(file);
>  	}




  reply	other threads:[~2014-07-14 13:58 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-11 19:06 [PATCH 0/7] tracing: instance_rmdir() leaks ftrace_event_file->filter Oleg Nesterov
2014-07-11 19:06 ` [PATCH 1/7] " Oleg Nesterov
2014-07-14 18:35   ` Steven Rostedt
2014-07-14 19:03     ` Oleg Nesterov
2014-07-11 19:06 ` [PATCH 2/7] tracing: kill destroy_preds() and destroy_file_preds() Oleg Nesterov
2014-07-11 19:06 ` [PATCH 3/7] tracing: kill destroy_call_preds() Oleg Nesterov
2014-07-11 19:06 ` [PATCH 4/7] tracing: kill call_filter_disable() Oleg Nesterov
2014-07-14 19:03   ` Steven Rostedt
2014-07-11 19:06 ` [PATCH 5/7] tracing/uprobes: kill the dead TRACE_EVENT_FL_USE_CALL_FILTER logic Oleg Nesterov
2014-07-14 19:04   ` Steven Rostedt
2014-07-15  0:18   ` Srikar Dronamraju
2014-07-11 19:06 ` [PATCH 6/7] tracing: kill ftrace_event_call->files Oleg Nesterov
2014-07-14 19:06   ` Steven Rostedt
2014-07-11 19:06 ` [PATCH 7/7] tracing: change filter_free_subsystem_*() to check ->subsystem rather then ->name Oleg Nesterov
2014-07-14 13:58   ` Namhyung Kim [this message]
2014-07-14 16:02     ` Oleg Nesterov
2014-07-14 19:21     ` Steven Rostedt
2014-07-14 19:20   ` Steven Rostedt
2014-07-14 19:23     ` Oleg Nesterov
2014-07-14 13:54 ` [PATCH 0/7] tracing: instance_rmdir() leaks ftrace_event_file->filter Namhyung Kim
2014-07-14 16:15   ` Oleg Nesterov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1405346299.1745.21.camel@leonhard \
    --to=namhyung@kernel.org \
    --cc=jovi.zhangwei@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=oleg@redhat.com \
    --cc=rostedt@goodmis.org \
    --cc=srikar@linux.vnet.ibm.com \
    --cc=tom.zanussi@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome