mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 19:08:57 +09:00
soc: rockchip: rk_fiq_debugger: remove debug_port_init of uart putc and flush
If uart is busy all the time, which may call debug_port_init and reset uart, but this can't clear the USR busy status. The LCR can't be writed if UART is busy.UART can't be reinited ok. This issue is tested by open and close wifi, and start logcat. A lot of android log is outputed by uart,uart is always busy,maybe it triggers reinit process, and cause the issue. It is unnecessary to call debug_port_init, because we have make sure uart is ok all the time. Change-Id: I1ef06e2a913d7045e86fe75a48a152c04e7e96a7 Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
This commit is contained in:
@@ -185,9 +185,6 @@ static void debug_putc(struct platform_device *pdev, unsigned int c)
|
||||
|
||||
while (!(rk_fiq_read(t, UART_USR) & UART_USR_TX_FIFO_NOT_FULL) && count--)
|
||||
udelay(10);
|
||||
/* If uart is always busy, maybe it is abnormal, reinit it */
|
||||
if ((count == 0) && (rk_fiq_read(t, UART_USR) & UART_USR_BUSY))
|
||||
debug_port_init(pdev);
|
||||
|
||||
rk_fiq_write(t, c, UART_TX);
|
||||
}
|
||||
@@ -200,9 +197,6 @@ static void debug_flush(struct platform_device *pdev)
|
||||
|
||||
while (!(rk_fiq_read_lsr(t) & UART_LSR_TEMT) && count--)
|
||||
udelay(10);
|
||||
/* If uart is always busy, maybe it is abnormal, reinit it */
|
||||
if ((count == 0) && (rk_fiq_read(t, UART_USR) & UART_USR_BUSY))
|
||||
debug_port_init(pdev);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_RK_CONSOLE_THREAD
|
||||
@@ -223,9 +217,6 @@ static void console_putc(struct platform_device *pdev, unsigned int c)
|
||||
while (!(rk_fiq_read(t, UART_USR) & UART_USR_TX_FIFO_NOT_FULL) &&
|
||||
count--)
|
||||
usleep_range(200, 210);
|
||||
/* If uart is always busy, maybe it is abnormal, reinit it */
|
||||
if ((count == 0) && (rk_fiq_read(t, UART_USR) & UART_USR_BUSY))
|
||||
debug_port_init(pdev);
|
||||
|
||||
rk_fiq_write(t, c, UART_TX);
|
||||
}
|
||||
@@ -239,9 +230,6 @@ static void console_flush(struct platform_device *pdev)
|
||||
|
||||
while (!(rk_fiq_read_lsr(t) & UART_LSR_TEMT) && count--)
|
||||
usleep_range(200, 210);
|
||||
/* If uart is always busy, maybe it is abnormal, reinit it */
|
||||
if ((count == 0) && (rk_fiq_read(t, UART_USR) & UART_USR_BUSY))
|
||||
debug_port_init(pdev);
|
||||
}
|
||||
|
||||
static void console_put(struct platform_device *pdev,
|
||||
|
||||
Reference in New Issue
Block a user