Commit 4d507dff authored by Markus Pargmann's avatar Markus Pargmann Committed by David S. Miller
Browse files

net: cpsw: Add missing return value

ret is set 0 at this point, so jumping to that error label would result
in a return value of 0. Set ret to -ENOMEM to return a proper error
Signed-off-by: default avatarMarkus Pargmann <>
Reviewed-by: default avatarWolfram Sang <>
Signed-off-by: default avatarDavid S. Miller <>
parent e4a9839b
......@@ -2123,6 +2123,7 @@ static int cpsw_probe(struct platform_device *pdev)
priv->irq_enabled = true;
if (!priv->cpts) {
dev_err(&pdev->dev, "error allocating cpts\n");
ret = -ENOMEM;
goto clean_ndev_ret;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment