aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/cpu/perf_counter.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/kernel/cpu/perf_counter.c')
-rw-r--r--arch/x86/kernel/cpu/perf_counter.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/x86/kernel/cpu/perf_counter.c b/arch/x86/kernel/cpu/perf_counter.c
index 316b0c995f38..ec06aa5e9282 100644
--- a/arch/x86/kernel/cpu/perf_counter.c
+++ b/arch/x86/kernel/cpu/perf_counter.c
@@ -290,11 +290,11 @@ static int __hw_perf_counter_init(struct perf_counter *counter)
290 hwc->nmi = 1; 290 hwc->nmi = 1;
291 hw_event->nmi = 1; 291 hw_event->nmi = 1;
292 292
293 if (!hwc->irq_period) 293 if (!hwc->sample_period)
294 hwc->irq_period = x86_pmu.max_period; 294 hwc->sample_period = x86_pmu.max_period;
295 295
296 atomic64_set(&hwc->period_left, 296 atomic64_set(&hwc->period_left,
297 min(x86_pmu.max_period, hwc->irq_period)); 297 min(x86_pmu.max_period, hwc->sample_period));
298 298
299 /* 299 /*
300 * Raw event type provide the config in the event structure 300 * Raw event type provide the config in the event structure
@@ -462,7 +462,7 @@ x86_perf_counter_set_period(struct perf_counter *counter,
462 struct hw_perf_counter *hwc, int idx) 462 struct hw_perf_counter *hwc, int idx)
463{ 463{
464 s64 left = atomic64_read(&hwc->period_left); 464 s64 left = atomic64_read(&hwc->period_left);
465 s64 period = min(x86_pmu.max_period, hwc->irq_period); 465 s64 period = min(x86_pmu.max_period, hwc->sample_period);
466 int err; 466 int err;
467 467
468 /* 468 /*