Skip to content

Commit

Permalink
amba-pl011: Don't send a character during startup
Browse files Browse the repository at this point in the history
This causes a corrupted character to be sent and
there's no explanation for why it is required.

If it worked correctly it would send an extra 0x00
which isn't appropriate either.

Signed-off-by: Simon Arlott <sa.me.uk>
  • Loading branch information
nomis committed Jun 9, 2012
1 parent cc77aa1 commit d5a48d1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/tty/serial/amba-pl011.c
Original file line number Diff line number Diff line change
Expand Up @@ -1338,6 +1338,11 @@ static int pl011_startup(struct uart_port *port)

writew(uap->vendor->ifls, uap->port.membase + UART011_IFLS);

/*
* The write to UART01x_DR causes a corrupted character to be sent
* - why is it required?
*/
#if 0
/*
* Provoke TX FIFO interrupt into asserting.
*/
Expand All @@ -1359,6 +1364,7 @@ static int pl011_startup(struct uart_port *port)
writew(0, uap->port.membase + UART01x_DR);
while (readw(uap->port.membase + UART01x_FR) & UART01x_FR_BUSY)
barrier();
#endif

/* restore RTS and DTR */
cr = uap->old_cr & (UART011_CR_RTS | UART011_CR_DTR);
Expand Down

0 comments on commit d5a48d1

Please sign in to comment.