diff options
Diffstat (limited to 'drivers/char/synclink.c')
-rw-r--r-- | drivers/char/synclink.c | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/drivers/char/synclink.c b/drivers/char/synclink.c index fb2e6b5e0ef1..ac9f21e18c3f 100644 --- a/drivers/char/synclink.c +++ b/drivers/char/synclink.c | |||
@@ -3298,6 +3298,18 @@ static int carrier_raised(struct tty_port *port) | |||
3298 | return (info->serial_signals & SerialSignal_DCD) ? 1 : 0; | 3298 | return (info->serial_signals & SerialSignal_DCD) ? 1 : 0; |
3299 | } | 3299 | } |
3300 | 3300 | ||
3301 | static void raise_dtr_rts(struct tty_port *port) | ||
3302 | { | ||
3303 | struct mgsl_struct *info = container_of(port, struct mgsl_struct, port); | ||
3304 | unsigned long flags; | ||
3305 | |||
3306 | spin_lock_irqsave(&info->irq_spinlock,flags); | ||
3307 | info->serial_signals |= SerialSignal_RTS + SerialSignal_DTR; | ||
3308 | usc_set_serial_signals(info); | ||
3309 | spin_unlock_irqrestore(&info->irq_spinlock,flags); | ||
3310 | } | ||
3311 | |||
3312 | |||
3301 | /* block_til_ready() | 3313 | /* block_til_ready() |
3302 | * | 3314 | * |
3303 | * Block the current process until the specified port | 3315 | * Block the current process until the specified port |
@@ -3358,12 +3370,8 @@ static int block_til_ready(struct tty_struct *tty, struct file * filp, | |||
3358 | port->blocked_open++; | 3370 | port->blocked_open++; |
3359 | 3371 | ||
3360 | while (1) { | 3372 | while (1) { |
3361 | if (tty->termios->c_cflag & CBAUD) { | 3373 | if (tty->termios->c_cflag & CBAUD) |
3362 | spin_lock_irqsave(&info->irq_spinlock,flags); | 3374 | tty_port_raise_dtr_rts(port); |
3363 | info->serial_signals |= SerialSignal_RTS + SerialSignal_DTR; | ||
3364 | usc_set_serial_signals(info); | ||
3365 | spin_unlock_irqrestore(&info->irq_spinlock,flags); | ||
3366 | } | ||
3367 | 3375 | ||
3368 | set_current_state(TASK_INTERRUPTIBLE); | 3376 | set_current_state(TASK_INTERRUPTIBLE); |
3369 | 3377 | ||
@@ -4321,6 +4329,7 @@ static void mgsl_add_device( struct mgsl_struct *info ) | |||
4321 | 4329 | ||
4322 | static const struct tty_port_operations mgsl_port_ops = { | 4330 | static const struct tty_port_operations mgsl_port_ops = { |
4323 | .carrier_raised = carrier_raised, | 4331 | .carrier_raised = carrier_raised, |
4332 | .raise_dtr_rts = raise_dtr_rts, | ||
4324 | }; | 4333 | }; |
4325 | 4334 | ||
4326 | 4335 | ||