summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorVegard Nossum <vegard.nossum@gmail.com>2008-11-18 19:22:13 +0100
committerIngo Molnar <mingo@elte.hu>2008-11-18 21:37:15 +0100
commit641d2f63cfe24539e154efa2f932937934c27dde (patch)
treefdd8dce64b14efecffb062480ad02bf2e57ac041 /kernel
parent5177dc3f2b3220b2dcfcf35eb9e6ec53ee818231 (diff)
trace: introduce missing mutex_unlock()
Impact: fix tracing buffer mutex leak in case of allocation failure This error was spotted by this semantic patch: http://www.emn.fr/x-info/coccinelle/mut.html It looks correct as far as I can tell. Please review. Signed-off-by: Vegard Nossum <vegard.nossum@gmail.com> Signed-off-by: Steven Rostedt <srostedt@redhat.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/ring_buffer.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c
index 036456cbb4f7..f780e9552f91 100644
--- a/kernel/trace/ring_buffer.c
+++ b/kernel/trace/ring_buffer.c
@@ -617,6 +617,7 @@ int ring_buffer_resize(struct ring_buffer *buffer, unsigned long size)
list_del_init(&page->list);
free_buffer_page(page);
}
+ mutex_unlock(&buffer->mutex);
return -ENOMEM;
}