ARM: 6521/1: perf: use raw_spinlock_t for pmu_lock
authorWill Deacon <will.deacon@arm.com>
Thu, 2 Dec 2010 17:01:49 +0000 (18:01 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Sat, 4 Dec 2010 11:18:08 +0000 (11:18 +0000)
For kernels built with PREEMPT_RT, critical sections protected
by standard spinlocks are preemptible. This is not acceptable
on perf as (a) we may be scheduled onto a different CPU whilst
reading/writing banked PMU registers and (b) the latency when
reading the PMU registers becomes unpredictable.

This patch upgrades the pmu_lock spinlock to a raw_spinlock
instead.

Reported-by: Jamie Iles <jamie@jamieiles.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>

No differences found