summaryrefslogtreecommitdiffstats
path: root/include/linux/perf_event.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2015-02-26 12:24:50 +0100
committerIngo Molnar <mingo@kernel.org>2015-02-26 12:24:50 +0100
commite9e4e44309f866b115d08ab4a54834008c50a8a4 (patch)
treeae9f91e682a4d6592ef263f30a4a0b1a862b7987 /include/linux/perf_event.h
parent8a26ce4e544659256349551283414df504889a59 (diff)
parentc517d838eb7d07bbe9507871fab3931deccff539 (diff)
downloadblackbird-op-linux-e9e4e44309f866b115d08ab4a54834008c50a8a4.tar.gz
blackbird-op-linux-e9e4e44309f866b115d08ab4a54834008c50a8a4.zip
Merge tag 'v4.0-rc1' into perf/core, to refresh the tree
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/perf_event.h')
-rw-r--r--include/linux/perf_event.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h
index 724d3720c9b1..a503100388cc 100644
--- a/include/linux/perf_event.h
+++ b/include/linux/perf_event.h
@@ -928,12 +928,22 @@ struct perf_pmu_events_attr {
const char *event_str;
};
+ssize_t perf_event_sysfs_show(struct device *dev, struct device_attribute *attr,
+ char *page);
+
#define PMU_EVENT_ATTR(_name, _var, _id, _show) \
static struct perf_pmu_events_attr _var = { \
.attr = __ATTR(_name, 0444, _show, NULL), \
.id = _id, \
};
+#define PMU_EVENT_ATTR_STRING(_name, _var, _str) \
+static struct perf_pmu_events_attr _var = { \
+ .attr = __ATTR(_name, 0444, perf_event_sysfs_show, NULL), \
+ .id = 0, \
+ .event_str = _str, \
+};
+
#define PMU_FORMAT_ATTR(_name, _format) \
static ssize_t \
_name##_show(struct device *dev, \
OpenPOWER on IntegriCloud