]> git.karo-electronics.de Git - karo-tx-linux.git/commit
printk: avoid double lock acquire
authorPeter Zijlstra <peterz@infradead.org>
Fri, 2 Dec 2011 03:06:49 +0000 (14:06 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 6 Dec 2011 03:51:00 +0000 (14:51 +1100)
commitd425cfaa6a9568c8875b0e3bef3f09c375cc8f5f
treea030ab92550a078ecce5bb508c83f44bc11578e4
parent6e7c456b1d1e8f30c02c201beb4d47bb48d14da3
printk: avoid double lock acquire

Commit 4f2a8d3cf5e ("printk: Fix console_sem vs logbuf_lock unlock race")
introduced another silly bug where we would want to acquire an already
held lock.  Avoid this.

Reported-by: Andrea Arcangeli <aarcange@redhat.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
kernel/printk.c