Skip to content
Commit 98db8df7 authored by Steven Rostedt's avatar Steven Rostedt Committed by Ingo Molnar
Browse files

ring-buffer: prevent false positive warning



Impact: eliminate false WARN_ON message

If an interrupt goes off after the setting of the local variable
tail_page and before incrementing the write index of that page,
the interrupt could push the commit forward to the next page.

Later a check is made to see if interrupts pushed the buffer around
the entire ring buffer by comparing the next page to the last commited
page. This can produce a false positive if the interrupt had pushed
the commit page forward as stated above.

Thanks to Jiaying Zhang for finding this race.

Reported-by: default avatarJiaying Zhang <jiayingz@google.com>
Signed-off-by: default avatarSteven Rostedt <srostedt@redhat.com>
Cc: <stable@kernel.org>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent a8ccf1d6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment