summaryrefslogtreecommitdiffstats
path: root/kernel/events
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2015-04-14 23:09:03 +0200
committerThomas Gleixner <tglx@linutronix.de>2015-04-22 17:06:51 +0200
commit3497d206c4d9b266d2e56c8b20e51b2f0e6a3c72 (patch)
treefef0b357e9bc4da31bf9c822ca1a597c84045df1 /kernel/events
parentx86: perf: uncore: Use hrtimer_start() (diff)
downloadlinux-3497d206c4d9b266d2e56c8b20e51b2f0e6a3c72.tar.xz
linux-3497d206c4d9b266d2e56c8b20e51b2f0e6a3c72.zip
perf: core: Use hrtimer_start()
hrtimer_start() does not longer defer already expired timers to the softirq. Get rid of the __hrtimer_start_range_ns() invocation. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: Preeti U Murthy <preeti@linux.vnet.ibm.com> Cc: Viresh Kumar <viresh.kumar@linaro.org> Cc: Marcelo Tosatti <mtosatti@redhat.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Link: http://lkml.kernel.org/r/20150414203502.452104213@linutronix.de Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/events')
-rw-r--r--kernel/events/core.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/kernel/events/core.c b/kernel/events/core.c
index 81aa3a4ece9f..05309fdba2a4 100644
--- a/kernel/events/core.c
+++ b/kernel/events/core.c
@@ -834,9 +834,7 @@ static void perf_cpu_hrtimer_restart(struct perf_cpu_context *cpuctx)
if (hrtimer_active(hr))
return;
- if (!hrtimer_callback_running(hr))
- __hrtimer_start_range_ns(hr, cpuctx->hrtimer_interval,
- 0, HRTIMER_MODE_REL_PINNED, 0);
+ hrtimer_start(hr, cpuctx->hrtimer_interval, HRTIMER_MODE_REL_PINNED);
}
void perf_pmu_disable(struct pmu *pmu)
@@ -6843,9 +6841,8 @@ static void perf_swevent_start_hrtimer(struct perf_event *event)
} else {
period = max_t(u64, 10000, hwc->sample_period);
}
- __hrtimer_start_range_ns(&hwc->hrtimer,
- ns_to_ktime(period), 0,
- HRTIMER_MODE_REL_PINNED, 0);
+ hrtimer_start(&hwc->hrtimer, ns_to_ktime(period),
+ HRTIMER_MODE_REL_PINNED);
}
static void perf_swevent_cancel_hrtimer(struct perf_event *event)