mirror of
https://github.com/torvalds/linux.git
synced 2024-09-20 23:13:00 +00:00
phy: rockchip: usbdp: fix uninitialized variable
The ret variable may not be initialized in rk_udphy_usb3_phy_init(), if
the PHY is not using USB3 mode.
Since the DisplayPort part is handled separately and the PHY does not
support USB2 (which is routed to another PHY on Rockchip RK3588), the
right exit code for this case is 0. Thus let's initialize the variable
accordingly.
Fixes: 2f70bbddeb
("phy: rockchip: add usbdp combo phy driver")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202404141048.qFAYDctQ-lkp@intel.com/
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Muhammad Usama Anjum <usama.anjum@collabora.com>
Link: https://lore.kernel.org/r/20240416145233.94687-1-sebastian.reichel@collabora.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
This commit is contained in:
parent
a1fe1eca0d
commit
c9342d1a35
|
@ -1285,7 +1285,7 @@ static const struct phy_ops rk_udphy_dp_phy_ops = {
|
|||
static int rk_udphy_usb3_phy_init(struct phy *phy)
|
||||
{
|
||||
struct rk_udphy *udphy = phy_get_drvdata(phy);
|
||||
int ret;
|
||||
int ret = 0;
|
||||
|
||||
mutex_lock(&udphy->mutex);
|
||||
/* DP only or high-speed, disable U3 port */
|
||||
|
|
Loading…
Reference in New Issue
Block a user