]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/perf: Clear all MMCR settings before calling compute_mmcr()
authorMichael Ellerman <mpe@ellerman.id.au>
Wed, 23 Jul 2014 11:12:36 +0000 (21:12 +1000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Mon, 28 Jul 2014 04:11:34 +0000 (14:11 +1000)
commit633e58524a0fab03bcfda48a185d2e6fc90832a5
tree388b27000174cadcbead484da5c5f8a4398f0d46
parent5877453b5bd768b4262f4b976e5c70fd68e8ffbb
powerpc/perf: Clear all MMCR settings before calling compute_mmcr()

Because we reuse cpuhw->mmcr on each call to compute_mmcr() there's a
risk that we could forget to set one of the values and use whatever
value was in there previously.

Currently all the implementations are careful to set all the values, but
it's safer to clear them all before we call compute_mmcr().

Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/perf/core-book3s.c