summaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial/mct_u232.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2012-07-11 16:08:35 +0100
committerGrant Likely <grant.likely@secretlab.ca>2012-07-11 16:08:35 +0100
commit80c1834fc86c2bbacb54a8fc3c04a8b0066b0996 (patch)
tree8200248706960af8b779e9144f5b51c670602228 /drivers/usb/serial/mct_u232.c
parent22076c7712be29a602de45b1c573f31adbd428a9 (diff)
parentbd0a521e88aa7a06ae7aabaed7ae196ed4ad867a (diff)
downloadop-kernel-dev-80c1834fc86c2bbacb54a8fc3c04a8b0066b0996.zip
op-kernel-dev-80c1834fc86c2bbacb54a8fc3c04a8b0066b0996.tar.gz
Merge tag 'v3.5-rc6' into irqdomain/next
Linux 3.5-rc6
Diffstat (limited to 'drivers/usb/serial/mct_u232.c')
-rw-r--r--drivers/usb/serial/mct_u232.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/usb/serial/mct_u232.c b/drivers/usb/serial/mct_u232.c
index d0ec1aa..a71fa0a 100644
--- a/drivers/usb/serial/mct_u232.c
+++ b/drivers/usb/serial/mct_u232.c
@@ -309,13 +309,16 @@ static int mct_u232_set_modem_ctrl(struct usb_serial *serial,
MCT_U232_SET_REQUEST_TYPE,
0, 0, buf, MCT_U232_SET_MODEM_CTRL_SIZE,
WDR_TIMEOUT);
- if (rc < 0)
- dev_err(&serial->dev->dev,
- "Set MODEM CTRL 0x%x failed (error = %d)\n", mcr, rc);
+ kfree(buf);
+
dbg("set_modem_ctrl: state=0x%x ==> mcr=0x%x", control_state, mcr);
- kfree(buf);
- return rc;
+ if (rc < 0) {
+ dev_err(&serial->dev->dev,
+ "Set MODEM CTRL 0x%x failed (error = %d)\n", mcr, rc);
+ return rc;
+ }
+ return 0;
} /* mct_u232_set_modem_ctrl */
static int mct_u232_get_modem_stat(struct usb_serial *serial,
OpenPOWER on IntegriCloud