Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 339176
b: refs/heads/master
c: c7d059c
h: refs/heads/master
v: v3
  • Loading branch information
Russell King committed Nov 4, 2012
1 parent eeb6a8f commit 11614fb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 18 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 18f360f865cffde44b112577fed1a6a0dd2740dc
refs/heads/master: c7d059cae31f328bbe2be6ab737226d338f22486
28 changes: 11 additions & 17 deletions trunk/drivers/tty/serial/omap-serial.c
Original file line number Diff line number Diff line change
Expand Up @@ -898,31 +898,30 @@ serial_omap_set_termios(struct uart_port *port, struct ktermios *termios,
else
serial_out(up, UART_OMAP_MDR1, up->mdr1);

/* Hardware Flow Control Configuration */
/* Enable access to TCR/TLR */
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_B);
serial_out(up, UART_EFR, up->efr | UART_EFR_ECB);
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_A);
serial_out(up, UART_MCR, up->mcr | UART_MCR_TCRTLR);

if (termios->c_cflag & CRTSCTS && up->port.flags & UPF_HARD_FLOW) {
/* Enable access to TCR/TLR */
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_B);
serial_out(up, UART_EFR, up->efr | UART_EFR_ECB);
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_A);
serial_out(up, UART_MCR, up->mcr | UART_MCR_TCRTLR);
serial_out(up, UART_TI752_TCR, OMAP_UART_TCR_TRIG);

serial_out(up, UART_TI752_TCR, OMAP_UART_TCR_TRIG);
/* Hardware Flow Control Configuration */

if (termios->c_cflag & CRTSCTS && up->port.flags & UPF_HARD_FLOW) {
/* Enable AUTORTS and AUTOCTS */
up->efr |= UART_EFR_CTS | UART_EFR_RTS;

/* Ensure MCR RTS is asserted */
up->mcr |= UART_MCR_RTS;

/* Disable access to TCR/TLR */
serial_out(up, UART_MCR, up->mcr);
} else {
/* Disable AUTORTS and AUTOCTS */
up->efr &= ~(UART_EFR_CTS | UART_EFR_RTS);
}

if (up->port.flags & UPF_SOFT_FLOW) {
/* Disable access to TCR/TLR */
serial_out(up, UART_MCR, up->mcr);
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_B);
serial_out(up, UART_EFR, up->efr);

Expand Down Expand Up @@ -961,14 +960,9 @@ serial_omap_set_termios(struct uart_port *port, struct ktermios *termios,
up->mcr |= UART_MCR_XONANY;
else
up->mcr &= ~UART_MCR_XONANY;

serial_out(up, UART_MCR, up->mcr | UART_MCR_TCRTLR);
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_B);
serial_out(up, UART_TI752_TCR, OMAP_UART_TCR_TRIG);
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_A);
serial_out(up, UART_MCR, up->mcr);
}

serial_out(up, UART_MCR, up->mcr);
serial_out(up, UART_LCR, UART_LCR_CONF_MODE_B);
serial_out(up, UART_EFR, up->efr);
serial_out(up, UART_LCR, up->lcr);
Expand Down

0 comments on commit 11614fb

Please sign in to comment.