diff options
Diffstat (limited to 'arch')
| -rw-r--r-- | arch/sparc/kernel/perf_counter.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/sparc/kernel/perf_counter.c b/arch/sparc/kernel/perf_counter.c index d86009fa6f8d..0cd5487b3413 100644 --- a/arch/sparc/kernel/perf_counter.c +++ b/arch/sparc/kernel/perf_counter.c | |||
| @@ -78,6 +78,7 @@ struct sparc_pmu { | |||
| 78 | int lower_shift; | 78 | int lower_shift; |
| 79 | int event_mask; | 79 | int event_mask; |
| 80 | int hv_bit; | 80 | int hv_bit; |
| 81 | int irq_bit; | ||
| 81 | }; | 82 | }; |
| 82 | 83 | ||
| 83 | static const struct perf_event_map ultra3i_perfmon_event_map[] = { | 84 | static const struct perf_event_map ultra3i_perfmon_event_map[] = { |
| @@ -179,7 +180,8 @@ void hw_perf_disable(void) | |||
| 179 | cpuc->enabled = 0; | 180 | cpuc->enabled = 0; |
| 180 | 181 | ||
| 181 | val = pcr_ops->read(); | 182 | val = pcr_ops->read(); |
| 182 | val &= ~(PCR_UTRACE | PCR_STRACE | sparc_pmu->hv_bit); | 183 | val &= ~(PCR_UTRACE | PCR_STRACE | |
| 184 | sparc_pmu->hv_bit | sparc_pmu->irq_bit); | ||
| 183 | pcr_ops->write(val); | 185 | pcr_ops->write(val); |
| 184 | } | 186 | } |
| 185 | 187 | ||
| @@ -373,7 +375,7 @@ static int __hw_perf_counter_init(struct perf_counter *counter) | |||
| 373 | * turn off sampling just write 'config', and to enable | 375 | * turn off sampling just write 'config', and to enable |
| 374 | * things write 'config | config_base'. | 376 | * things write 'config | config_base'. |
| 375 | */ | 377 | */ |
| 376 | hwc->config_base = 0; | 378 | hwc->config_base = sparc_pmu->irq_bit; |
| 377 | if (!attr->exclude_user) | 379 | if (!attr->exclude_user) |
| 378 | hwc->config_base |= PCR_UTRACE; | 380 | hwc->config_base |= PCR_UTRACE; |
| 379 | if (!attr->exclude_kernel) | 381 | if (!attr->exclude_kernel) |
