diff options
-rw-r--r-- | arch/x86/kernel/cpu/perf_counter.c | 8 | ||||
-rw-r--r-- | include/linux/perf_counter.h | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/arch/x86/kernel/cpu/perf_counter.c b/arch/x86/kernel/cpu/perf_counter.c index f7fd4a355159..d8beebeb270f 100644 --- a/arch/x86/kernel/cpu/perf_counter.c +++ b/arch/x86/kernel/cpu/perf_counter.c | |||
@@ -459,7 +459,7 @@ static void hw_perf_disable(int idx, u64 config) | |||
459 | 459 | ||
460 | static inline void | 460 | static inline void |
461 | __pmc_fixed_disable(struct perf_counter *counter, | 461 | __pmc_fixed_disable(struct perf_counter *counter, |
462 | struct hw_perf_counter *hwc, unsigned int __idx) | 462 | struct hw_perf_counter *hwc, int __idx) |
463 | { | 463 | { |
464 | int idx = __idx - X86_PMC_IDX_FIXED; | 464 | int idx = __idx - X86_PMC_IDX_FIXED; |
465 | u64 ctrl_val, mask; | 465 | u64 ctrl_val, mask; |
@@ -474,7 +474,7 @@ __pmc_fixed_disable(struct perf_counter *counter, | |||
474 | 474 | ||
475 | static inline void | 475 | static inline void |
476 | __x86_pmu_disable(struct perf_counter *counter, | 476 | __x86_pmu_disable(struct perf_counter *counter, |
477 | struct hw_perf_counter *hwc, unsigned int idx) | 477 | struct hw_perf_counter *hwc, int idx) |
478 | { | 478 | { |
479 | if (unlikely(hwc->config_base == MSR_ARCH_PERFMON_FIXED_CTR_CTRL)) | 479 | if (unlikely(hwc->config_base == MSR_ARCH_PERFMON_FIXED_CTR_CTRL)) |
480 | __pmc_fixed_disable(counter, hwc, idx); | 480 | __pmc_fixed_disable(counter, hwc, idx); |
@@ -523,7 +523,7 @@ x86_perf_counter_set_period(struct perf_counter *counter, | |||
523 | 523 | ||
524 | static inline void | 524 | static inline void |
525 | __pmc_fixed_enable(struct perf_counter *counter, | 525 | __pmc_fixed_enable(struct perf_counter *counter, |
526 | struct hw_perf_counter *hwc, unsigned int __idx) | 526 | struct hw_perf_counter *hwc, int __idx) |
527 | { | 527 | { |
528 | int idx = __idx - X86_PMC_IDX_FIXED; | 528 | int idx = __idx - X86_PMC_IDX_FIXED; |
529 | u64 ctrl_val, bits, mask; | 529 | u64 ctrl_val, bits, mask; |
@@ -691,7 +691,7 @@ static void x86_pmu_disable(struct perf_counter *counter) | |||
691 | { | 691 | { |
692 | struct cpu_hw_counters *cpuc = &__get_cpu_var(cpu_hw_counters); | 692 | struct cpu_hw_counters *cpuc = &__get_cpu_var(cpu_hw_counters); |
693 | struct hw_perf_counter *hwc = &counter->hw; | 693 | struct hw_perf_counter *hwc = &counter->hw; |
694 | unsigned int idx = hwc->idx; | 694 | int idx = hwc->idx; |
695 | 695 | ||
696 | /* | 696 | /* |
697 | * Must be done before we disable, otherwise the nmi handler | 697 | * Must be done before we disable, otherwise the nmi handler |
diff --git a/include/linux/perf_counter.h b/include/linux/perf_counter.h index c3db52dc876a..41aed4270057 100644 --- a/include/linux/perf_counter.h +++ b/include/linux/perf_counter.h | |||
@@ -318,7 +318,7 @@ struct hw_perf_counter { | |||
318 | unsigned long config_base; | 318 | unsigned long config_base; |
319 | unsigned long counter_base; | 319 | unsigned long counter_base; |
320 | int nmi; | 320 | int nmi; |
321 | unsigned int idx; | 321 | int idx; |
322 | }; | 322 | }; |
323 | union { /* software */ | 323 | union { /* software */ |
324 | atomic64_t count; | 324 | atomic64_t count; |