aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial/sierra.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/serial/sierra.c')
-rw-r--r--drivers/usb/serial/sierra.c24
1 files changed, 17 insertions, 7 deletions
diff --git a/drivers/usb/serial/sierra.c b/drivers/usb/serial/sierra.c
index d9bf9a5c20ec..913225c61610 100644
--- a/drivers/usb/serial/sierra.c
+++ b/drivers/usb/serial/sierra.c
@@ -14,7 +14,7 @@
14 Whom based his on the Keyspan driver by Hugh Blemings <hugh@blemings.org> 14 Whom based his on the Keyspan driver by Hugh Blemings <hugh@blemings.org>
15*/ 15*/
16 16
17#define DRIVER_VERSION "v.1.3.2" 17#define DRIVER_VERSION "v.1.3.3"
18#define DRIVER_AUTHOR "Kevin Lloyd <klloyd@sierrawireless.com>" 18#define DRIVER_AUTHOR "Kevin Lloyd <klloyd@sierrawireless.com>"
19#define DRIVER_DESC "USB Driver for Sierra Wireless USB modems" 19#define DRIVER_DESC "USB Driver for Sierra Wireless USB modems"
20 20
@@ -259,9 +259,21 @@ static int sierra_send_setup(struct tty_struct *tty,
259 val |= 0x02; 259 val |= 0x02;
260 260
261 /* If composite device then properly report interface */ 261 /* If composite device then properly report interface */
262 if (serial->num_ports == 1) 262 if (serial->num_ports == 1) {
263 interface = sierra_calc_interface(serial); 263 interface = sierra_calc_interface(serial);
264 264
265 /* Control message is sent only to interfaces with
266 * interrupt_in endpoints
267 */
268 if (port->interrupt_in_urb) {
269 /* send control message */
270 return usb_control_msg(serial->dev,
271 usb_rcvctrlpipe(serial->dev, 0),
272 0x22, 0x21, val, interface,
273 NULL, 0, USB_CTRL_SET_TIMEOUT);
274 }
275 }
276
265 /* Otherwise the need to do non-composite mapping */ 277 /* Otherwise the need to do non-composite mapping */
266 else { 278 else {
267 if (port->bulk_out_endpointAddress == 2) 279 if (port->bulk_out_endpointAddress == 2)
@@ -270,12 +282,13 @@ static int sierra_send_setup(struct tty_struct *tty,
270 interface = 1; 282 interface = 1;
271 else if (port->bulk_out_endpointAddress == 5) 283 else if (port->bulk_out_endpointAddress == 5)
272 interface = 2; 284 interface = 2;
273 }
274 285
275 return usb_control_msg(serial->dev, 286 return usb_control_msg(serial->dev,
276 usb_rcvctrlpipe(serial->dev, 0), 287 usb_rcvctrlpipe(serial->dev, 0),
277 0x22, 0x21, val, interface, 288 0x22, 0x21, val, interface,
278 NULL, 0, USB_CTRL_SET_TIMEOUT); 289 NULL, 0, USB_CTRL_SET_TIMEOUT);
290
291 }
279 } 292 }
280 293
281 return 0; 294 return 0;
@@ -585,9 +598,6 @@ static int sierra_open(struct tty_struct *tty,
585 } 598 }
586 } 599 }
587 600
588 if (tty)
589 tty->low_latency = 1;
590
591 sierra_send_setup(tty, port); 601 sierra_send_setup(tty, port);
592 602
593 /* start up the interrupt endpoint if we have one */ 603 /* start up the interrupt endpoint if we have one */