summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdrian Hunter <adrian.hunter@intel.com>2018-05-31 13:23:44 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-07-03 11:23:15 +0200
commit4213d9b8cdb10d4d29fd232898692a1a56c1fd58 (patch)
tree10d34a68cd8fcd73a081d3039aac90b6bc46538f
parent282f1f66b5a0f4875f2562144f5e5c80bc86dfc1 (diff)
downloadlinux-stable-4213d9b8cdb10d4d29fd232898692a1a56c1fd58.tar.gz
linux-stable-4213d9b8cdb10d4d29fd232898692a1a56c1fd58.tar.bz2
linux-stable-4213d9b8cdb10d4d29fd232898692a1a56c1fd58.zip
perf intel-pt: Fix MTC timing after overflow
commit dd27b87ab5fcf3ea1c060b5e3ab5d31cc78e9f4c upstream. On some platforms, overflows will clear before MTC wraparound, and there is no following TSC/TMA packet. In that case the previous TMA is valid. Since there will be a valid TMA either way, stop setting 'have_tma' to false upon overflow. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: stable@vger.kernel.org Link: http://lkml.kernel.org/r/1527762225-26024-4-git-send-email-adrian.hunter@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--tools/perf/util/intel-pt-decoder/intel-pt-decoder.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c b/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c
index 0fd7697b9d35..21c81da190b2 100644
--- a/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c
+++ b/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c
@@ -1298,7 +1298,6 @@ static int intel_pt_overflow(struct intel_pt_decoder *decoder)
{
intel_pt_log("ERROR: Buffer overflow\n");
intel_pt_clear_tx_flags(decoder);
- decoder->have_tma = false;
decoder->cbr = 0;
decoder->timestamp_insn_cnt = 0;
decoder->pkt_state = INTEL_PT_STATE_ERR_RESYNC;