]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
phy: rockchip-inno-usb2: Fix muxed interrupt support
authorSamuel Holland <samuel@sholland.org>
Thu, 14 Apr 2022 03:22:52 +0000 (22:22 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 14 Jun 2022 16:44:46 +0000 (18:44 +0200)
commit5bc9dd160de1055bf313b66ad5419c20a8e3624f
tree22277d50290ab3da5cad83def5e7378f417eb429
parent82740b4f0c7be7ee790af42c9645b19807d329ec
phy: rockchip-inno-usb2: Fix muxed interrupt support

[ Upstream commit 6a98df08ccd55e87947d253b19925691763e755c ]

This commit fixes two issues with the muxed interrupt handler. First,
the OTG port has the "bvalid" interrupt enabled, not "linestate". Since
only the linestate interrupt was handled, and not the bvalid interrupt,
plugging in a cable to the OTG port caused an interrupt storm.

Second, the return values from the individual port IRQ handlers need to
be OR-ed together. Otherwise, the lack of an interrupt from the last
port would cause the handler to erroneously return IRQ_NONE.

Fixes: ed2b5a8e6b98 ("phy: phy-rockchip-inno-usb2: support muxed interrupts")
Signed-off-by: Samuel Holland <samuel@sholland.org>
Tested-by: Michael Riesch <michael.riesch@wolfvision.net>
Link: https://lore.kernel.org/r/20220414032258.40984-2-samuel@sholland.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/phy/rockchip/phy-rockchip-inno-usb2.c