mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
serial: bfin-uart: Enable hardware automatic CTS only when CTS pin is available.
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
5c2f37dddd
commit
b48dc711c3
1 changed files with 10 additions and 9 deletions
|
@ -726,16 +726,17 @@ static int bfin_serial_startup(struct uart_port *port)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifdef CONFIG_SERIAL_BFIN_HARD_CTSRTS
|
#ifdef CONFIG_SERIAL_BFIN_HARD_CTSRTS
|
||||||
if (uart->cts_pin >= 0 && request_irq(uart->status_irq,
|
if (uart->cts_pin >= 0) {
|
||||||
bfin_serial_mctrl_cts_int,
|
if (request_irq(uart->status_irq, bfin_serial_mctrl_cts_int,
|
||||||
0, "BFIN_UART_MODEM_STATUS", uart)) {
|
IRQF_DISABLED, "BFIN_UART_MODEM_STATUS", uart)) {
|
||||||
uart->cts_pin = -1;
|
uart->cts_pin = -1;
|
||||||
pr_info("Unable to attach BlackFin UART Modem Status interrupt.\n");
|
dev_info(port->dev, "Unable to attach BlackFin UART Modem Status interrupt.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* CTS RTS PINs are negative assertive. */
|
/* CTS RTS PINs are negative assertive. */
|
||||||
UART_PUT_MCR(uart, ACTS);
|
UART_PUT_MCR(uart, ACTS);
|
||||||
UART_SET_IER(uart, EDSSI);
|
UART_SET_IER(uart, EDSSI);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
UART_SET_IER(uart, ERBFI);
|
UART_SET_IER(uart, ERBFI);
|
||||||
|
|
Loading…
Reference in a new issue