Skip to content

Commit 316fb19

Browse files
nomispopcornmix
authored andcommitted
amba-pl011: Don't send a character during startup
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>
1 parent 5892cce commit 316fb19

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

drivers/tty/serial/amba-pl011.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1350,6 +1350,11 @@ static int pl011_startup(struct uart_port *port)
13501350

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

1353+
/*
1354+
* The write to UART01x_DR causes a corrupted character to be sent
1355+
* - why is it required?
1356+
*/
1357+
#if 0
13531358
/*
13541359
* Provoke TX FIFO interrupt into asserting.
13551360
*/
@@ -1371,6 +1376,7 @@ static int pl011_startup(struct uart_port *port)
13711376
writew(0, uap->port.membase + UART01x_DR);
13721377
while (readw(uap->port.membase + UART01x_FR) & UART01x_FR_BUSY)
13731378
barrier();
1379+
#endif
13741380

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

0 commit comments

Comments
 (0)