diff options
-rw-r--r-- | drivers/tty/serial/amba-pl011.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c index 0faee493eff..5bbd97e61ff 100644 --- a/drivers/tty/serial/amba-pl011.c +++ b/drivers/tty/serial/amba-pl011.c @@ -1120,6 +1120,10 @@ static void pl011_lockup_wa(unsigned long data) int buf_empty_retries = 200; int loop; + /* Exit early if there is no tty */ + if (!tty) + return; + /* Stop HCI layer from submitting data for tx */ tty->hw_stopped = 1; while (!uart_circ_empty(xmit)) { |