Message ID | 147927f0-9ada-45cc-81ff-75a19dd30b76@moroto.mountain |
---|---|
State | New |
Headers | show |
Series | [net] net: usb: smsc95xx: Fix an error code in smsc95xx_reset() | expand |
Hello: This patch was applied to netdev/net.git (main) by Jakub Kicinski <kuba@kernel.org>: On Mon, 16 Oct 2023 20:28:10 +0300 you wrote: > Return a negative error code instead of success. > > Fixes: 2f7ca802bdae ("net: Add SMSC LAN9500 USB2.0 10/100 ethernet adapter driver") > Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> > --- > drivers/net/usb/smsc95xx.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Here is the summary with links: - [net] net: usb: smsc95xx: Fix an error code in smsc95xx_reset() https://git.kernel.org/netdev/net/c/c53647a5df9e You are awesome, thank you!
diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c index 563ecd27b93e..17da42fe605c 100644 --- a/drivers/net/usb/smsc95xx.c +++ b/drivers/net/usb/smsc95xx.c @@ -897,7 +897,7 @@ static int smsc95xx_reset(struct usbnet *dev) if (timeout >= 100) { netdev_warn(dev->net, "timeout waiting for completion of Lite Reset\n"); - return ret; + return -ETIMEDOUT; } ret = smsc95xx_set_mac_address(dev);
Return a negative error code instead of success. Fixes: 2f7ca802bdae ("net: Add SMSC LAN9500 USB2.0 10/100 ethernet adapter driver") Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> --- drivers/net/usb/smsc95xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)