]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
mailbox: pcc: don't zero error register
authorJamie Iles <jamie.iles@oss.qualcomm.com>
Wed, 5 Nov 2025 14:42:29 +0000 (14:42 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 6 Dec 2025 21:24:56 +0000 (06:24 +0900)
commit1080ed39eae393bf5b82ab9b40501022cf484948
treeaa18835d7ba51dcd8c20a5bd0324e0e52ac17bb6
parent733e3d0c1ab37f593cc984854de9b1e9dd104a3b
mailbox: pcc: don't zero error register

[ Upstream commit ff0e4d4c97c94af34cc9cad37b5a5cdbe597a3b0 ]

The error status mask for a type 3/4 subspace is used for reading the
error status, and the bitwise inverse is used for clearing the error
with the intent being to preserve any of the non-error bits.  However,
we were previously applying the mask to extract the status and then
applying the inverse to the result which ended up clearing all bits.

Instead, store the inverse mask in the preserve mask and then use that
on the original value read from the error status so that only the error
is cleared.

Fixes: c45ded7e1135 ("mailbox: pcc: Add support for PCCT extended PCC subspaces(type 3/4)")
Signed-off-by: Jamie Iles <jamie.iles@oss.qualcomm.com>
Signed-off-by: Punit Agrawal <punit.agrawal@oss.qualcomm.com>
Signed-off-by: Jassi Brar <jassisinghbrar@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/mailbox/pcc.c