[PATCH] MIPS: asm/debug_ll_ns16550.h: add nop in delay slot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In the debug_ll_outc_a0 macro, a0 is written to the uart data
register many times in a delay slot when the uart is not ready
to send data. insert a nop to avoid this.

Signed-off-by: Du Huanpeng <u74147@xxxxxxxxx>
---
 arch/mips/include/asm/debug_ll_ns16550.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/mips/include/asm/debug_ll_ns16550.h b/arch/mips/include/asm/debug_ll_ns16550.h
index df58c4c..cf666d1 100644
--- a/arch/mips/include/asm/debug_ll_ns16550.h
+++ b/arch/mips/include/asm/debug_ll_ns16550.h
@@ -88,6 +88,7 @@ static inline void PUTC_LL(char ch)
 201:	lbu	t1, UART_LSR(t0)	/* get line status */
 	andi	t1, t1, UART_LSR_THRE	/* check for transmitter empty */
 	beqz	t1, 201b			/* try again */
+	nop
 
 	sb	a0, UART_THR(t0)	/* write the character */
 
-- 
2.7.4


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux