]> git.baikalelectronics.ru Git - kernel.git/commit
ring-buffer: Update write stamp with the correct ts
authorSteven Rostedt (VMware) <rostedt@goodmis.org>
Fri, 27 Nov 2020 16:20:58 +0000 (11:20 -0500)
committerSteven Rostedt (VMware) <rostedt@goodmis.org>
Mon, 30 Nov 2020 20:21:31 +0000 (15:21 -0500)
commit7acfe40930d70b9ed7f837d669f3da8828571bfa
tree90b6dd8bef31c53b59abbf0155a1a2aed9e597c4
parentdacc125e1bd588c64c624581930a5123de3ac2fd
ring-buffer: Update write stamp with the correct ts

The write stamp, used to calculate deltas between events, was updated with
the stale "ts" value in the "info" structure, and not with the updated "ts"
variable. This caused the deltas between events to be inaccurate, and when
crossing into a new sub buffer, had time go backwards.

Link: https://lkml.kernel.org/r/20201124223917.795844-1-elavila@google.com
Cc: stable@vger.kernel.org
Fixes: e6cc5f23410ef ("ring-buffer: Have nested events still record running time stamp")
Reported-by: "J. Avila" <elavila@google.com>
Tested-by: Daniel Mentz <danielmentz@google.com>
Tested-by: Will McVicker <willmcvicker@google.com>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
kernel/trace/ring_buffer.c