Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7267fa68 authored by Steven Rostedt's avatar Steven Rostedt Committed by Ingo Molnar
Browse files

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: default avatarSteven Rostedt <rostedt@goodmis.org>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent 09106974
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -3448,6 +3448,7 @@ tracing_buffers_splice_read(struct file *file, loff_t *ppos,
		if (!ref)
		if (!ref)
			break;
			break;


		ref->ref = 1;
		ref->buffer = info->tr->buffer;
		ref->buffer = info->tr->buffer;
		ref->page = ring_buffer_alloc_read_page(ref->buffer);
		ref->page = ring_buffer_alloc_read_page(ref->buffer);
		if (!ref->page) {
		if (!ref->page) {