diff options
Diffstat (limited to 'drivers/net/can/slcan.c')
-rw-r--r-- | drivers/net/can/slcan.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/can/slcan.c b/drivers/net/can/slcan.c index f5b16e0e3a12..dcf9196f6316 100644 --- a/drivers/net/can/slcan.c +++ b/drivers/net/can/slcan.c | |||
@@ -322,13 +322,13 @@ static void slcan_write_wakeup(struct tty_struct *tty) | |||
322 | if (!sl || sl->magic != SLCAN_MAGIC || !netif_running(sl->dev)) | 322 | if (!sl || sl->magic != SLCAN_MAGIC || !netif_running(sl->dev)) |
323 | return; | 323 | return; |
324 | 324 | ||
325 | spin_lock(&sl->lock); | 325 | spin_lock_bh(&sl->lock); |
326 | if (sl->xleft <= 0) { | 326 | if (sl->xleft <= 0) { |
327 | /* Now serial buffer is almost free & we can start | 327 | /* Now serial buffer is almost free & we can start |
328 | * transmission of another packet */ | 328 | * transmission of another packet */ |
329 | sl->dev->stats.tx_packets++; | 329 | sl->dev->stats.tx_packets++; |
330 | clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); | 330 | clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); |
331 | spin_unlock(&sl->lock); | 331 | spin_unlock_bh(&sl->lock); |
332 | netif_wake_queue(sl->dev); | 332 | netif_wake_queue(sl->dev); |
333 | return; | 333 | return; |
334 | } | 334 | } |
@@ -336,7 +336,7 @@ static void slcan_write_wakeup(struct tty_struct *tty) | |||
336 | actual = tty->ops->write(tty, sl->xhead, sl->xleft); | 336 | actual = tty->ops->write(tty, sl->xhead, sl->xleft); |
337 | sl->xleft -= actual; | 337 | sl->xleft -= actual; |
338 | sl->xhead += actual; | 338 | sl->xhead += actual; |
339 | spin_unlock(&sl->lock); | 339 | spin_unlock_bh(&sl->lock); |
340 | } | 340 | } |
341 | 341 | ||
342 | /* Send a can_frame to a TTY queue. */ | 342 | /* Send a can_frame to a TTY queue. */ |