alistair23-linux/drivers/hwtracing
Yabin Cui bbedcb91cc coresight: tmc-etr: Fix perf_data check
When tracing etm data of multiple threads on multiple cpus through
perf interface, each cpu has a unique etr_perf_buffer while sharing
the same etr device. There is no guarantee that the last cpu starts
etm tracing also stops last. This makes perf_data check fail.

Fix it by checking etr_buf instead of etr_perf_buffer.
Also move the code setting and clearing perf_buf to more suitable
places.

Fixes: 3147da92a8 ("coresight: tmc-etr: Allocate and free ETR memory buffers for CPU-wide scenarios")
Signed-off-by: Yabin Cui <yabinc@google.com>
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Link: https://lore.kernel.org/r/20190829202842.580-15-mathieu.poirier@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-03 22:01:17 +02:00
..
coresight coresight: tmc-etr: Fix perf_data check 2019-09-03 22:01:17 +02:00
intel_th Merge 5.3-rc7 into char-misc-next 2019-09-02 19:30:09 +02:00
stm stm class: Fix a double free of stm_source_device 2019-08-28 22:29:01 +02:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00