coresight: associating path with session rather than tracer
authorMathieu Poirier <mathieu.poirier@linaro.org>
Thu, 18 Feb 2016 00:51:45 +0000 (17:51 -0700)
committerMathieu Poirier <mathieu.poirier@linaro.org>
Wed, 1 Jun 2016 21:30:11 +0000 (15:30 -0600)
commitfde79d4de7443a7e3cca1dd05d4a789ebc490a53
tree15fc95147c887bfe6a2a0663c79cefe91608bc54
parente1e8321c38b7e47ca9b8095b584dc89bef46504c
coresight: associating path with session rather than tracer

When using the Coresight framework from the sysFS interface a
tracer is always handling a single session and as such, a path
can be associated with a tracer.  But when supporting multiple
session per tracer there is no guarantee that sessions will always
have the same path from source to sink.

This patch is removing the automatic association between path and
tracers.  The building of a path and enablement of the components
in the path are decoupled, allowing for the association of a path
with a session rather than a tracer.

To keep backward functionality with the current sysFS access methods
a per-cpu place holder is used to keep a handle on the path built when
tracers are enabled.  Lastly APIs to build paths and enable tracers are
made public so that other subsystem can interact with the Coresight
framework.

Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit b3e94405941e6916d5e365454d74560c2bea47ca)
drivers/hwtracing/coresight/coresight-priv.h
drivers/hwtracing/coresight/coresight.c
include/linux/coresight.h