Skip to content

Commit

Permalink
Merge branch 'tip/perf/core' of git://git.kernel.org/pub/scm/linux/ke…
Browse files Browse the repository at this point in the history
…rnel/git/rostedt/linux-trace into perf/core

Pull tracing fix from Steve Rostedt.

Signed-off-by: Ingo Molnar <mingo@kernel.org>
  • Loading branch information
Ingo Molnar committed Jul 18, 2012
2 parents a2fe194 + 93574fc commit 6e0f17b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions kernel/trace/trace.c
Original file line number Diff line number Diff line change
Expand Up @@ -2390,6 +2390,9 @@ __tracing_open(struct inode *inode, struct file *file)

iter->buffer_iter = kzalloc(sizeof(*iter->buffer_iter) * num_possible_cpus(),
GFP_KERNEL);
if (!iter->buffer_iter)
goto release;

/*
* We make a copy of the current tracer to avoid concurrent
* changes on it while we are reading.
Expand Down Expand Up @@ -2451,6 +2454,7 @@ __tracing_open(struct inode *inode, struct file *file)
mutex_unlock(&trace_types_lock);
kfree(iter->trace);
kfree(iter->buffer_iter);
release:
seq_release_private(inode, file);
return ERR_PTR(-ENOMEM);
}
Expand Down

0 comments on commit 6e0f17b

Please sign in to comment.