]> git.baikalelectronics.ru Git - kernel.git/commit
perf intel-pt: Fix TSC slip
authorAdrian Hunter <adrian.hunter@intel.com>
Mon, 25 Mar 2019 13:51:35 +0000 (15:51 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 28 Mar 2019 17:31:55 +0000 (14:31 -0300)
commit62c182a1c9271f5ac8c393b7eb9f092f6a8721c1
tree795a322f98bd67431e16e096282784f56e3d26fe
parentbf7cfeb0a4f9a9faffe7b454ee480701d11cc49a
perf intel-pt: Fix TSC slip

A TSC packet can slip past MTC packets so that the timestamp appears to
go backwards. One estimate is that can be up to about 40 CPU cycles,
which is certainly less than 0x1000 TSC ticks, but accept slippage an
order of magnitude more to be on the safe side.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: stable@vger.kernel.org
Fixes: b6e5243c8ba85 ("perf tools: Add Intel PT support for decoding MTC packets")
Link: http://lkml.kernel.org/r/20190325135135.18348-1-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/intel-pt-decoder/intel-pt-decoder.c