Skip to content

Commit

Permalink
phy: sunplus: return negative error code in sp_usb_phy_probe
Browse files Browse the repository at this point in the history
[ Upstream commit 2a9c713 ]

devm_phy_create() return negative error code, 'ret' should be
'PTR_ERR(phy)' rather than '-PTR_ERR(phy)'.

Fixes: 99d9ccd ("phy: usb: Add USB2.0 phy driver for Sunplus SP7021")
Signed-off-by: Su Hui <suhui@nfschina.com>
Link: https://lore.kernel.org/r/20231120091046.163781-1-suhui@nfschina.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Su Hui authored and gregkh committed Jan 10, 2024
1 parent c7573ba commit 09aa95c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/phy/sunplus/phy-sunplus-usb2.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ static int sp_usb_phy_probe(struct platform_device *pdev)

phy = devm_phy_create(&pdev->dev, NULL, &sp_uphy_ops);
if (IS_ERR(phy)) {
ret = -PTR_ERR(phy);
ret = PTR_ERR(phy);
return ret;
}

Expand Down

0 comments on commit 09aa95c

Please sign in to comment.