]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/perf: Fix Threshold Event Counter Multiplier width for P10
authorMadhavan Srinivasan <maddy@linux.ibm.com>
Tue, 15 Dec 2020 08:56:18 +0000 (03:56 -0500)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 15 Dec 2020 11:50:04 +0000 (22:50 +1100)
commitf69bc2ee5b8dc43d25186b477d32be45160f7247
tree892a0952d86faa63082d135b8b51d3891421128c
parent80dfd8b8e6be3afba3c5358b31770a5b49a97ec2
powerpc/perf: Fix Threshold Event Counter Multiplier width for P10

Threshold Event Counter Multiplier (TECM) is part of Monitor Mode
Control Register A (MMCRA). This field along with Threshold Event
Counter Exponent (TECE) is used to get threshould counter value.
In Power10, this is a 8bit field, so patch fixes the
current code to modify the MMCRA[TECM] extraction macro to
handle this change. ISA v3.1 says this is a 7 bit field but
POWER10 it's actually 8 bits which will hopefully be fixed
in ISA v3.1 update.

Fixes: 5296cefb7779 ("powerpc/perf: Support to export MMCRA[TEC*] field to userspace")
Signed-off-by: Madhavan Srinivasan <maddy@linux.ibm.com>
Signed-off-by: Athira Rajeev <atrajeev@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/1608022578-1532-1-git-send-email-atrajeev@linux.vnet.ibm.com
arch/powerpc/perf/isa207-common.c
arch/powerpc/perf/isa207-common.h