perf cs-etm: Introducing function cs_etm__init_trace_params()
authorMathieu Poirier <mathieu.poirier@linaro.org>
Tue, 12 Feb 2019 17:16:11 +0000 (10:16 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 14 Feb 2019 18:18:06 +0000 (15:18 -0300)
commit2507a3d982f2968168b53f4d1e67774d68f79b0c
tree63d3eb66ee94b99bf4895ec87c79a0ef724a9cd5
parentae4d9f5236439ef08f9963f39d5984959b1ae04d
perf cs-etm: Introducing function cs_etm__init_trace_params()

The trace parameter initialisation code is repeated in two different
places, something that bloats the file and can lead to errors.  This
is fixed by introducing a helper function and calling the right
protocol initialisation code when required.

Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Leo Yan <leo.yan@linaro.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Suzuki K Poulouse <suzuki.poulose@arm.com>
Cc: linux-arm-kernel@lists.infradead.org
Link: http://lkml.kernel.org/r/20190212171618.25355-7-mathieu.poirier@linaro.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/cs-etm.c
tools/perf/util/cs-etm.h