Merge branch 'linus' into x86/urgent
[cascardo/linux.git] / drivers / char / n_r3964.c
index c1d8b54..88dda0c 100644 (file)
@@ -4,7 +4,6 @@
  * Copyright by 
  * Philips Automation Projects
  * Kassel (Germany)
- * http://www.pap-philips.de
  * -----------------------------------------------------------
  * This software may be used and distributed according to the terms of
  * the GNU General Public License, incorporated herein by reference.
@@ -1067,7 +1066,7 @@ static ssize_t r3964_read(struct tty_struct *tty, struct file *file,
 
        TRACE_L("read()");
 
-       lock_kernel();
+       tty_lock();
 
        pClient = findClient(pInfo, task_pid(current));
        if (pClient) {
@@ -1079,7 +1078,7 @@ static ssize_t r3964_read(struct tty_struct *tty, struct file *file,
                                goto unlock;
                        }
                        /* block until there is a message: */
-                       wait_event_interruptible(pInfo->read_wait,
+                       wait_event_interruptible_tty(pInfo->read_wait,
                                        (pMsg = remove_msg(pInfo, pClient)));
                }
 
@@ -1109,7 +1108,7 @@ static ssize_t r3964_read(struct tty_struct *tty, struct file *file,
        }
        ret = -EPERM;
 unlock:
-       unlock_kernel();
+       tty_unlock();
        return ret;
 }
 
@@ -1158,7 +1157,7 @@ static ssize_t r3964_write(struct tty_struct *tty, struct file *file,
        pHeader->locks = 0;
        pHeader->owner = NULL;
 
-       lock_kernel();
+       tty_lock();
 
        pClient = findClient(pInfo, task_pid(current));
        if (pClient) {
@@ -1177,7 +1176,7 @@ static ssize_t r3964_write(struct tty_struct *tty, struct file *file,
        add_tx_queue(pInfo, pHeader);
        trigger_transmit(pInfo);
 
-       unlock_kernel();
+       tty_unlock();
 
        return 0;
 }