diff options
author | Alan Cox <alan@lxorguk.ukuu.org.uk> | 2008-04-30 07:53:22 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-30 15:29:39 (GMT) |
commit | 638157bc1461f6718eeca06bedd9a09cf1f35c36 (patch) | |
tree | a8ef1f3ecbe0904f5c1341438bd3b079c8ff0eb7 /drivers/char/serial167.c | |
parent | bdf183aa47dcb46782e22ebd4d1061e47ad74b14 (diff) | |
download | linux-fsl-qoriq-638157bc1461f6718eeca06bedd9a09cf1f35c36.tar.xz |
serial167: prepare to push BKL down into drivers
Kill the softcar handlers again, wrap the ioctl handler in the BKL
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/serial167.c')
-rw-r--r-- | drivers/char/serial167.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/drivers/char/serial167.c b/drivers/char/serial167.c index df8cd0c..f62fb93 100644 --- a/drivers/char/serial167.c +++ b/drivers/char/serial167.c @@ -1539,6 +1539,8 @@ cy_ioctl(struct tty_struct *tty, struct file *file, printk("cy_ioctl %s, cmd = %x arg = %lx\n", tty->name, cmd, arg); /* */ #endif + lock_kernel(); + switch (cmd) { case CYGETMON: ret_val = get_mon_info(info, argp); @@ -1584,18 +1586,6 @@ cy_ioctl(struct tty_struct *tty, struct file *file, break; /* The following commands are incompletely implemented!!! */ - case TIOCGSOFTCAR: - ret_val = - put_user(C_CLOCAL(tty) ? 1 : 0, - (unsigned long __user *)argp); - break; - case TIOCSSOFTCAR: - ret_val = get_user(val, (unsigned long __user *)argp); - if (ret_val) - break; - tty->termios->c_cflag = - ((tty->termios->c_cflag & ~CLOCAL) | (val ? CLOCAL : 0)); - break; case TIOCGSERIAL: ret_val = get_serial_info(info, argp); break; @@ -1605,6 +1595,7 @@ cy_ioctl(struct tty_struct *tty, struct file *file, default: ret_val = -ENOIOCTLCMD; } + unlock_kernel(); #ifdef SERIAL_DEBUG_OTHER printk("cy_ioctl done\n"); |