Re: [PATCH 1/7] tracing: instance_rmdir() leaks ftrace_event_file->filter
From: Steven Rostedt
Date: Mon Jul 14 2014 - 14:36:02 EST
On Fri, 11 Jul 2014 21:06:38 +0200
Oleg Nesterov <oleg@xxxxxxxxxx> wrote:
> instance_rmdir() path destroys the event files but forgets to free
> file->filter. Change remove_event_file_dir() to free_event_filter().
>
> Signed-off-by: Oleg Nesterov <oleg@xxxxxxxxxx>
> ---
> kernel/trace/trace_events.c | 1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
>
> diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
> index fdb2271..735608e 100644
> --- a/kernel/trace/trace_events.c
> +++ b/kernel/trace/trace_events.c
> @@ -470,6 +470,7 @@ static void remove_event_file_dir(struct ftrace_event_file *file)
>
> list_del(&file->list);
> remove_subsystem(file->system);
> + free_event_filter(file->filter);
> kmem_cache_free(file_cachep, file);
> }
>
Thanks, looks like this goes back to 3.11. I'll start testing this and
get it out for stable as well.
-- Steve
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/