]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/perf: Fix unit_sel/cache_sel checks
authorMadhavan Srinivasan <maddy@linux.vnet.ibm.com>
Mon, 9 Oct 2017 14:12:40 +0000 (19:42 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 20 Dec 2018 09:53:11 +0000 (20:53 +1100)
commitb7ac3cfea6841e074fbd6b4f72fcd3a8930b77b0
treeab63b2fd93f73819eaaa4e2a59962f4e0b405f88
parent1a3de54691224210c65a8df426fdfa34e9f7e025
powerpc/perf: Fix unit_sel/cache_sel checks

Raw event code has couple of fields "unit" and "cache" in it, to capture
the "unit" to monitor for a given pmcxsel and cache reload qualifier to
program in MMCR1.

isa207_get_constraint() refers "unit" field to update the MMCRC (L2/L3)
Event bus control fields with "cache" bits of the raw event code.
These are power8 specific and not supported by PowerISA v3.0 pmu. So wrap
the checks to be power8 specific. Also, "cache" bit field is referred to
update MMCR1[16:17] and this check can be power8 specific.

Fixes: f2f0fe46fd75a ('powerpc/perf: factor out power8 pmu functions')
Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/perf/isa207-common.c
arch/powerpc/perf/isa207-common.h