diff options
author | Adrian Hunter <adrian.hunter@intel.com> | 2019-02-06 13:39:45 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-03-23 15:19:53 +0300 |
commit | d07d516086a40905ef27b3859bc9c5c763beb5f1 (patch) | |
tree | 3ba2d967af92112ca5645c60bd5c29bb996752d9 /tools/perf/util | |
parent | 7fb9a25c159c4c408879bba20ffd7c592ce5e957 (diff) | |
download | linux-d07d516086a40905ef27b3859bc9c5c763beb5f1.tar.xz |
perf intel-pt: Fix CYC timestamp calculation after OVF
commit 03997612904866abe7cdcc992784ef65cb3a4b81 upstream.
CYC packet timestamp calculation depends upon CBR which was being
cleared upon overflow (OVF). That can cause errors due to failing to
synchronize with sideband events. Even if a CBR change has been lost,
the old CBR is still a better estimate than zero. So remove the clearing
of CBR.
Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: stable@vger.kernel.org
Link: http://lkml.kernel.org/r/20190206103947.15750-4-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/util')
-rw-r--r-- | tools/perf/util/intel-pt-decoder/intel-pt-decoder.c | 1 |
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 d27715ff9a5f..f64c62e20540 100644 --- a/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c +++ b/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c @@ -1311,7 +1311,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->cbr = 0; decoder->timestamp_insn_cnt = 0; decoder->pkt_state = INTEL_PT_STATE_ERR_RESYNC; decoder->overflow = true; |