]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/perf: Don't enable if we have zero events
authorMichael Ellerman <michael@ellerman.id.au>
Fri, 28 Jun 2013 08:15:14 +0000 (18:15 +1000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Mon, 1 Jul 2013 01:50:03 +0000 (11:50 +1000)
commitfa87480cc3c0b45ed10263534505ebf590b6d561
treea92aee5cfb16a4d48a6845cea84b55df7460fb63
parent67faec276f605b6ab5340898f4a1a3c4e7a1661c
powerpc/perf: Don't enable if we have zero events

In power_pmu_enable() we still enable the PMU even if we have zero
events. This should have no effect but doesn't make much sense. Instead
just return after telling the hypervisor that we are not using the PMCs.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
CC: <stable@vger.kernel.org> [v3.10]
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/perf/core-book3s.c