[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1354125469-29671-1-git-send-email-steve.glendinning@shawell.net>
Date: Wed, 28 Nov 2012 17:57:49 +0000
From: Steve Glendinning <steve.glendinning@...well.net>
To: netdev@...r.kernel.org
Cc: Steve Glendinning <steve.glendinning@...well.net>
Subject: [PATCH] smsc75xx: don't call usbnet_resume if usbnet_suspend fails
If usbnet_suspend returns an error we don't want to call
usbnet_resume to clean up, but instead just return the error.
If usbnet_suspend *does* succeed, and we have a problem further
on, the desired behaviour is still to call usbnet_resume
to clean up before returning.
Signed-off-by: Steve Glendinning <steve.glendinning@...well.net>
---
drivers/net/usb/smsc75xx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/usb/smsc75xx.c b/drivers/net/usb/smsc75xx.c
index 1823806..86d9249 100644
--- a/drivers/net/usb/smsc75xx.c
+++ b/drivers/net/usb/smsc75xx.c
@@ -1411,7 +1411,7 @@ static int smsc75xx_suspend(struct usb_interface *intf, pm_message_t message)
int ret;
ret = usbnet_suspend(intf, message);
- check_warn_goto_done(ret, "usbnet_suspend error\n");
+ check_warn_return(ret, "usbnet_suspend error\n");
if (pdata->suspend_flags) {
netdev_warn(dev->net, "error during last resume\n");
--
1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists