diff options
Diffstat (limited to 'drivers/usb/serial/airprime.c')
-rw-r--r-- | drivers/usb/serial/airprime.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/usb/serial/airprime.c b/drivers/usb/serial/airprime.c index 77bb893bf2e9..f156dba0300f 100644 --- a/drivers/usb/serial/airprime.c +++ b/drivers/usb/serial/airprime.c | |||
@@ -217,7 +217,10 @@ static void airprime_close(struct usb_serial_port *port, struct file * filp) | |||
217 | priv->rts_state = 0; | 217 | priv->rts_state = 0; |
218 | priv->dtr_state = 0; | 218 | priv->dtr_state = 0; |
219 | 219 | ||
220 | airprime_send_setup(port); | 220 | mutex_lock(&port->serial->disc_mutex); |
221 | if (!port->serial->disconnected) | ||
222 | airprime_send_setup(port); | ||
223 | mutex_lock(&port->serial->disc_mutex); | ||
221 | 224 | ||
222 | for (i = 0; i < NUM_READ_URBS; ++i) { | 225 | for (i = 0; i < NUM_READ_URBS; ++i) { |
223 | usb_kill_urb (priv->read_urbp[i]); | 226 | usb_kill_urb (priv->read_urbp[i]); |