Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211915
b: refs/heads/master
c: 84c7991
h: refs/heads/master
i:
  211913: 96e505f
  211911: 2010597
v: v3
  • Loading branch information
Matt Fleming authored and Robert Richter committed Oct 11, 2010
1 parent 9592f18 commit 62588df
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3bf101ba42a1c89b5afbc7492e7647dae5e18735
refs/heads/master: 84c7991059c9c4530cc911137c5bf508a41ed129
9 changes: 9 additions & 0 deletions trunk/arch/sh/kernel/perf_event.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,15 @@ static inline int sh_pmu_initialized(void)
return !!sh_pmu;
}

const char *perf_pmu_name(void)
{
if (!sh_pmu)
return NULL;

return sh_pmu->name;
}
EXPORT_SYMBOL_GPL(perf_pmu_name);

int perf_num_counters(void)
{
if (!sh_pmu)
Expand Down
1 change: 1 addition & 0 deletions trunk/include/linux/perf_event.h
Original file line number Diff line number Diff line change
Expand Up @@ -850,6 +850,7 @@ extern int perf_max_events;
extern const struct pmu *hw_perf_event_init(struct perf_event *event);

extern int perf_num_counters(void);
extern const char *perf_pmu_name(void);
extern void perf_event_task_sched_in(struct task_struct *task);
extern void perf_event_task_sched_out(struct task_struct *task, struct task_struct *next);
extern void perf_event_task_tick(struct task_struct *task);
Expand Down
5 changes: 5 additions & 0 deletions trunk/kernel/perf_event.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ void __weak hw_perf_enable(void) { barrier(); }

void __weak perf_event_print_debug(void) { }

extern __weak const char *perf_pmu_name(void)
{
return "pmu";
}

static DEFINE_PER_CPU(int, perf_disable_count);

void perf_disable(void)
Expand Down

0 comments on commit 62588df

Please sign in to comment.