mirror of
https://github.com/torvalds/linux.git
synced 2024-11-16 17:12:06 +00:00
crisv10: prepare for BKL push down
Just the modem bits this time Signed-off-by: Alan Cox <alan@redhat.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
f85e7cdc3f
commit
032c17e8af
@ -3582,6 +3582,8 @@ rs_tiocmset(struct tty_struct *tty, struct file *file,
|
|||||||
{
|
{
|
||||||
struct e100_serial *info = (struct e100_serial *)tty->driver_data;
|
struct e100_serial *info = (struct e100_serial *)tty->driver_data;
|
||||||
|
|
||||||
|
lock_kernel();
|
||||||
|
|
||||||
if (clear & TIOCM_RTS)
|
if (clear & TIOCM_RTS)
|
||||||
e100_rts(info, 0);
|
e100_rts(info, 0);
|
||||||
if (clear & TIOCM_DTR)
|
if (clear & TIOCM_DTR)
|
||||||
@ -3601,6 +3603,8 @@ rs_tiocmset(struct tty_struct *tty, struct file *file,
|
|||||||
e100_ri_out(info, 1);
|
e100_ri_out(info, 1);
|
||||||
if (set & TIOCM_CD)
|
if (set & TIOCM_CD)
|
||||||
e100_cd_out(info, 1);
|
e100_cd_out(info, 1);
|
||||||
|
|
||||||
|
unlock_kernel();
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3610,6 +3614,7 @@ rs_tiocmget(struct tty_struct *tty, struct file *file)
|
|||||||
struct e100_serial *info = (struct e100_serial *)tty->driver_data;
|
struct e100_serial *info = (struct e100_serial *)tty->driver_data;
|
||||||
unsigned int result;
|
unsigned int result;
|
||||||
|
|
||||||
|
lock_kernel();
|
||||||
result =
|
result =
|
||||||
(!E100_RTS_GET(info) ? TIOCM_RTS : 0)
|
(!E100_RTS_GET(info) ? TIOCM_RTS : 0)
|
||||||
| (!E100_DTR_GET(info) ? TIOCM_DTR : 0)
|
| (!E100_DTR_GET(info) ? TIOCM_DTR : 0)
|
||||||
@ -3618,6 +3623,8 @@ rs_tiocmget(struct tty_struct *tty, struct file *file)
|
|||||||
| (!E100_CD_GET(info) ? TIOCM_CAR : 0)
|
| (!E100_CD_GET(info) ? TIOCM_CAR : 0)
|
||||||
| (!E100_CTS_GET(info) ? TIOCM_CTS : 0);
|
| (!E100_CTS_GET(info) ? TIOCM_CTS : 0);
|
||||||
|
|
||||||
|
unlock_kernel();
|
||||||
|
|
||||||
#ifdef SERIAL_DEBUG_IO
|
#ifdef SERIAL_DEBUG_IO
|
||||||
printk(KERN_DEBUG "ser%i: modem state: %i 0x%08X\n",
|
printk(KERN_DEBUG "ser%i: modem state: %i 0x%08X\n",
|
||||||
info->line, result, result);
|
info->line, result, result);
|
||||||
|
Loading…
Reference in New Issue
Block a user