]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
Bluetooth: btmtksdio: mask out interrupt status
authorSean Wang <sean.wang@mediatek.com>
Wed, 12 Jan 2022 07:39:17 +0000 (15:39 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Apr 2022 11:57:57 +0000 (13:57 +0200)
commit43f3937325ee61233d37d25acc6ed56a56a8dfc2
tree43bfd365bef465d5595a550c7ca1c917d15a30f9
parentd02375eca312b8957224645311cb589bcd2ad999
Bluetooth: btmtksdio: mask out interrupt status

[ Upstream commit db3f1f9b5d88d8d7f9eaa486f71784dd319285ff ]

Currently, there is a loop in btmtksdio_txrx_work() which iteratively
executes until the variable int_status is zero.

But the variable int_status should be masked out with the actual interrupt
sources (MTK_REG_CHISR bit 0-15) before we check the loop condition.
Otherwise, RX_PKT_LEN (MTK_REG_CHISR bit 16-31) which is read-only and
unclearable would cause the loop to get stuck on some chipsets like
MT7663s.

Fixes: 26270bc189ea ("Bluetooth: btmtksdio: move interrupt service to work")
Signed-off-by: Sean Wang <sean.wang@mediatek.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/bluetooth/btmtksdio.c