aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorSteven Rostedt <srostedt@redhat.com>2009-04-29 00:16:21 -0400
committerIngo Molnar <mingo@elte.hu>2009-04-29 02:02:44 -0400
commit7267fa6819467669f5cc2ba81a615dcc88158b4b (patch)
tree281e3c2b9765c24364280f02fd9f9aa387c8aa6f /kernel
parent091069740304c979f957ceacec39c461d0192158 (diff)
tracing: fix ref count in splice pages
The pages allocated for the splice binary buffer did not initialize the ref count correctly. This caused pages not to be freed and causes a drastic memory leak. Thanks to logdev I was able to trace the tracer to find where the leak was. [ Impact: stop memory leak when using splice ] Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/trace.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index 1ce5dc6372b8..a884c09006c4 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -3448,6 +3448,7 @@ tracing_buffers_splice_read(struct file *file, loff_t *ppos,
3448 if (!ref) 3448 if (!ref)
3449 break; 3449 break;
3450 3450
3451 ref->ref = 1;
3451 ref->buffer = info->tr->buffer; 3452 ref->buffer = info->tr->buffer;
3452 ref->page = ring_buffer_alloc_read_page(ref->buffer); 3453 ref->page = ring_buffer_alloc_read_page(ref->buffer);
3453 if (!ref->page) { 3454 if (!ref->page) {