]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
usb: chipidea: ci_hdrc_imx: implement usb_phy_init() error handling
authorFedor Pchelkin <pchelkin@ispras.ru>
Sun, 16 Mar 2025 10:26:56 +0000 (13:26 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 2 May 2025 05:50:50 +0000 (07:50 +0200)
commit23d4bb3b06989b3902be28d48c0043511bbb5f61
treeafb477b337f7956c655519505136d06b985d8a3b
parent15120673da696621936b85a84ea46ba1f45b9a02
usb: chipidea: ci_hdrc_imx: implement usb_phy_init() error handling

commit 8c531e0a8c2d82509ad97c6d3a1e6217c7ed136d upstream.

usb_phy_init() may return an error code if e.g. its implementation fails
to prepare/enable some clocks. And properly rollback on probe error path
by calling the counterpart usb_phy_shutdown().

Found by Linux Verification Center (linuxtesting.org).

Fixes: be9cae2479f4 ("usb: chipidea: imx: Fix ULPI on imx53")
Cc: stable <stable@kernel.org>
Signed-off-by: Fedor Pchelkin <pchelkin@ispras.ru>
Acked-by: Peter Chen <peter.chen@kernel.org>
Link: https://lore.kernel.org/r/20250316102658.490340-4-pchelkin@ispras.ru
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/chipidea/ci_hdrc_imx.c