]> git.baikalelectronics.ru Git - kernel.git/commit
gcc-4.6: printk: use stable variable to dump kmsg buffer
authorAndi Kleen <andi@firstfloor.org>
Tue, 10 Aug 2010 00:20:36 +0000 (17:20 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 10 Aug 2010 03:45:06 +0000 (20:45 -0700)
commit01d9b9a3fce85a8c840ea7d3f79d331227a0bc15
tree17671814cc7afb4e5eaafad32f0ed0c428764515
parentaaf633e9bdeb15b39bfeb24eaba61fa929563a61
gcc-4.6: printk: use stable variable to dump kmsg buffer

kmsg_dump takes care to sample the global variables
inside a spinlock, but then goes on to use the same
variables outside the spinlock region too.

Use the correct variable. This will make the race
window smaller.

Found by gcc 4.6's new warnings.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
kernel/printk.c