]> git.baikalelectronics.ru Git - kernel.git/commit
ring-buffer: check for swapped buffers in start of committing
authorSteven Rostedt <srostedt@redhat.com>
Fri, 4 Sep 2009 18:11:34 +0000 (14:11 -0400)
committerSteven Rostedt <rostedt@goodmis.org>
Fri, 4 Sep 2009 23:38:42 +0000 (19:38 -0400)
commitdca3aae5b49121ca96926dde98145948f49f1e4a
tree344b3b8f55e6162f7fa08316aa6fde333b304c04
parent831c59076cc7597429cf7efcaa17afb60cd375a3
ring-buffer: check for swapped buffers in start of committing

Because the irqsoff tracer can swap an internal CPU buffer, it is possible
that a swap happens between the start of the write and before the committing
bit is set (the committing bit will disable swapping).

This patch adds a check for this and will fail the write if it detects it.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
kernel/trace/ring_buffer.c