Bluetooth: Release BTM while sleeping to avoid deadlock
authorVladislav P <vladisslav@inbox.ru>
Mon, 14 Feb 2011 17:21:50 +0000 (15:21 -0200)
committerGustavo F. Padovan <padovan@profusion.mobi>
Wed, 16 Feb 2011 18:54:11 +0000 (15:54 -0300)
Signed-off-by: Vladislav P <vladisslav@inbox.ru>
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
net/bluetooth/rfcomm/tty.c

index 2575c2db64047021080131d47d37a9f5ad49584a..d7b9af4703d02718c512cb9bca4a99913532f630 100644 (file)
@@ -727,7 +727,9 @@ static int rfcomm_tty_open(struct tty_struct *tty, struct file *filp)
                        break;
                }
 
+               tty_unlock();
                schedule();
+               tty_lock();
        }
        set_current_state(TASK_RUNNING);
        remove_wait_queue(&dev->wait, &wait);