Skip to contentSkip to conversation

phy: cadence-torrent: Fix error code in cdns_torrent_phy_probe()

PATCH Applied Dan Carpenter 2 participants 2 messages Dec 17, 2020 – Jan 13, 2021

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 phy: cadence-torrent: Fix error code in cdns_torrent_phy_probe()

This error path should return -EINVAL, but currently it returns success.

Fixes d09945eacad0 ("phy: cadence-torrent: Check total lane count for all subnodes is within limit")
---
 drivers/phy/cadence/phy-cadence-torrent.c | 1 +
 1 file changed, 1 insertion(+)
drivers/phy/cadence/phy-cadence-torrent.c +1 -0
index f310e15d94cb..591a15834b48 100644
@@ -2298,6 +2298,7 @@ static int cdns_torrent_phy_probe(struct platform_device *pdev)
 
 	if (total_num_lanes > MAX_NUM_LANES) {
 		dev_err(dev, "Invalid lane configuration\n");
+		ret = -EINVAL;
 		goto put_lnk_rst;
 	}
 
Signature · 1 line
2.29.2
maintainer Applied
#1 lore raw
Quoted 2 lines · Dan Carpenter

This error path should return -EINVAL, but currently it returns success.

Applied, thanks

Signature · 1 line
~Vinod