Commit 84c7991059c9c4530cc911137c5bf508a41ed129
Committed by
Robert Richter
1 parent
3bf101ba42
perf: New helper function for pmu name
Introduce perf_pmu_name() helper function that returns the name of the pmu. This gives us a generic way to get the name of a pmu regardless of how an architecture identifies it internally. Signed-off-by: Matt Fleming <matt@console-pimps.org> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Robert Richter <robert.richter@amd.com>
Showing 3 changed files with 15 additions and 0 deletions Side-by-side Diff
arch/sh/kernel/perf_event.c
include/linux/perf_event.h
... | ... | @@ -850,6 +850,7 @@ |
850 | 850 | extern const struct pmu *hw_perf_event_init(struct perf_event *event); |
851 | 851 | |
852 | 852 | extern int perf_num_counters(void); |
853 | +extern const char *perf_pmu_name(void); | |
853 | 854 | extern void perf_event_task_sched_in(struct task_struct *task); |
854 | 855 | extern void perf_event_task_sched_out(struct task_struct *task, struct task_struct *next); |
855 | 856 | extern void perf_event_task_tick(struct task_struct *task); |
kernel/perf_event.c