]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
coresight: Only check bottom two claim bits
authorJames Clark <james.clark@linaro.org>
Tue, 25 Mar 2025 11:58:47 +0000 (11:58 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 10 Jul 2025 13:57:33 +0000 (15:57 +0200)
commitfd72dd6a82e206b71a15815e740a3dd34f49f9b8
tree8f9eaa44a25078b26fa728eecaea806fd1e3b08b
parentbe620f25161f60b11b277d8ac6f23d8f0f16665c
coresight: Only check bottom two claim bits

[ Upstream commit a4e65842e1142aa18ef36113fbd81d614eaefe5a ]

The use of the whole register and == could break the claim mechanism if
any of the other bits are used in the future. The referenced doc "PSCI -
ARM DEN 0022D" also says to only read and clear the bottom two bits.

Use FIELD_GET() to extract only the relevant part.

Reviewed-by: Leo Yan <leo.yan@arm.com>
Reviewed-by: Yeoreum Yun <yeoreum.yun@arm.com>
Signed-off-by: James Clark <james.clark@linaro.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Link: https://lore.kernel.org/r/20250325-james-coresight-claim-tags-v4-2-dfbd3822b2e5@linaro.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/hwtracing/coresight/coresight-core.c
drivers/hwtracing/coresight/coresight-priv.h