tty: release BTM while sleeping in block_til_ready
[linux-2.6-block.git] / drivers / serial / 68360serial.c
index edcf1cc089d11edccbd1f4e82d40617db3b570ff..0dff3bbddc8b34eb98136380ba909f8009fd3f24 100644 (file)
@@ -1860,7 +1860,9 @@ static int block_til_ready(struct tty_struct *tty, struct file * filp,
                printk("block_til_ready blocking: ttys%d, count = %d\n",
                       info->line, state->count);
 #endif
+               tty_unlock();
                schedule();
+               tty_lock();
        }
        current->state = TASK_RUNNING;
        remove_wait_queue(&info->open_wait, &wait);