Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5c591304 authored by Robin Murphy's avatar Robin Murphy Committed by Will Deacon
Browse files

perf/arm-cci: Remove unnecessary period adjustment



Since sampling events are rejected up-front by cci_pmu_event_init(), it
doesn't make much sense to go fiddling with the sampling period later.
This would seem to be just another leftover artefact of the arm_pmu
framwork, and as such can go.

Acked-by: default avatarMark Rutland <mark.rutland@arm.com>
Signed-off-by: default avatarRobin Murphy <robin.murphy@arm.com>
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
parent d0f2e423
Loading
Loading
Loading
Loading
+0 −9
Original line number Diff line number Diff line
@@ -1304,15 +1304,6 @@ static int __hw_perf_event_init(struct perf_event *event)
	 */
	hwc->config_base	    |= (unsigned long)mapping;

	/*
	 * Limit the sample_period to half of the counter width. That way, the
	 * new counter value is far less likely to overtake the previous one
	 * unless you have some serious IRQ latency issues.
	 */
	hwc->sample_period  = CCI_PMU_CNTR_MASK >> 1;
	hwc->last_period    = hwc->sample_period;
	local64_set(&hwc->period_left, hwc->sample_period);

	if (event->group_leader != event) {
		if (validate_group(event) != 0)
			return -EINVAL;