提交 b97971be 编写于 作者: M Mike Leach 提交者: Greg Kroah-Hartman

coresight: pmu: Adds return stack option to perf coresight pmu

Return stack is a programmable option on some ETM and PTM hardware.
Adds the option flags to enable this from the perf event command line.
Signed-off-by: NMike Leach <mike.leach@linaro.org>
Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 89f00a1a
...@@ -53,10 +53,12 @@ static DEFINE_PER_CPU(struct coresight_device *, csdev_src); ...@@ -53,10 +53,12 @@ static DEFINE_PER_CPU(struct coresight_device *, csdev_src);
/* ETMv3.5/PTM's ETMCR is 'config' */ /* ETMv3.5/PTM's ETMCR is 'config' */
PMU_FORMAT_ATTR(cycacc, "config:" __stringify(ETM_OPT_CYCACC)); PMU_FORMAT_ATTR(cycacc, "config:" __stringify(ETM_OPT_CYCACC));
PMU_FORMAT_ATTR(timestamp, "config:" __stringify(ETM_OPT_TS)); PMU_FORMAT_ATTR(timestamp, "config:" __stringify(ETM_OPT_TS));
PMU_FORMAT_ATTR(retstack, "config:" __stringify(ETM_OPT_RETSTK));
static struct attribute *etm_config_formats_attr[] = { static struct attribute *etm_config_formats_attr[] = {
&format_attr_cycacc.attr, &format_attr_cycacc.attr,
&format_attr_timestamp.attr, &format_attr_timestamp.attr,
&format_attr_retstack.attr,
NULL, NULL,
}; };
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
/* ETMv3.5/PTM's ETMCR config bit */ /* ETMv3.5/PTM's ETMCR config bit */
#define ETM_OPT_CYCACC 12 #define ETM_OPT_CYCACC 12
#define ETM_OPT_TS 28 #define ETM_OPT_TS 28
#define ETM_OPT_RETSTK 29
static inline int coresight_get_trace_id(int cpu) static inline int coresight_get_trace_id(int cpu)
{ {
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
/* ETMv3.5/PTM's ETMCR config bit */ /* ETMv3.5/PTM's ETMCR config bit */
#define ETM_OPT_CYCACC 12 #define ETM_OPT_CYCACC 12
#define ETM_OPT_TS 28 #define ETM_OPT_TS 28
#define ETM_OPT_RETSTK 29
static inline int coresight_get_trace_id(int cpu) static inline int coresight_get_trace_id(int cpu)
{ {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册