coresight: etb10: Add support for CPU-wide trace scenarios
authorMathieu Poirier <mathieu.poirier@linaro.org>
Thu, 25 Apr 2019 19:53:10 +0000 (13:53 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Apr 2019 20:00:18 +0000 (22:00 +0200)
commit75d7dbd3882450c7b6602d234b3b31864dbc356d
treeb3be9af04b248b9271d4384573c15c520ef0d044
parent880af782c6e81cccf507f5a1cf4b23fbb471c39f
coresight: etb10: Add support for CPU-wide trace scenarios

This patch adds support for CPU-wide trace scenarios by making sure that
only the sources monitoring the same process have access to a common sink.
Because the sink is shared between sources, the first source to use the
sink switches it on while the last one does the cleanup.  Any attempt to
modify the HW is overlooked for as long as more than one source is using
a sink.

Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Tested-by: Leo Yan <leo.yan@linaro.org>
Tested-by: Robert Walker <robert.walker@arm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hwtracing/coresight/coresight-etb10.c