]> git.baikalelectronics.ru Git - kernel.git/commit
arm_pmu: Introduce pmu_irq_ops
authorJulien Thierry <julien.thierry@arm.com>
Thu, 24 Sep 2020 11:07:05 +0000 (12:07 +0100)
committerWill Deacon <will@kernel.org>
Mon, 28 Sep 2020 18:00:17 +0000 (19:00 +0100)
commitb61181ee52e39058723a5d4ba8fe59a604181bd6
tree887167dc1c07521340b6825804bb13c63bf36a3b
parentf54d7eb8413389c4de7fcf0e4c0a9aad49baec8e
arm_pmu: Introduce pmu_irq_ops

Currently the PMU interrupt can either be a normal irq or a percpu irq.
Supporting NMI will introduce two cases for each existing one. It becomes
a mess of 'if's when managing the interrupt.

Define sets of callbacks for operations commonly done on the interrupt. The
appropriate set of callbacks is selected at interrupt request time and
simplifies interrupt enabling/disabling and freeing.

Signed-off-by: Julien Thierry <julien.thierry@arm.com>
Signed-off-by: Alexandru Elisei <alexandru.elisei@arm.com>
Tested-by: Sumit Garg <sumit.garg@linaro.org> (Developerbox)
Cc: Julien Thierry <julien.thierry.kdev@gmail.com>
Cc: Will Deacon <will.deacon@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20200924110706.254996-7-alexandru.elisei@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
drivers/perf/arm_pmu.c