Commit 9e0db41e authored by Jisheng Zhang's avatar Jisheng Zhang Committed by David S. Miller

net: stmmac: dwmac-sun8i: use return val of readl_poll_timeout()

When readl_poll_timeout() timeout, we'd better directly use its return
value.

Before this patch:
[    2.145528] dwmac-sun8i: probe of 4500000.ethernet failed with error -14

After this patch:
[    2.138520] dwmac-sun8i: probe of 4500000.ethernet failed with error -110
Signed-off-by: default avatarJisheng Zhang <jszhang@kernel.org>
Acked-by: default avatarJernej Skrabec <jernej.skrabec@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent dcb2c5c6
......@@ -756,7 +756,7 @@ static int sun8i_dwmac_reset(struct stmmac_priv *priv)
if (err) {
dev_err(priv->device, "EMAC reset timeout\n");
return -EFAULT;
return err;
}
return 0;
}
......
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