mirror of
				https://xff.cz/git/u-boot/
				synced 2025-10-31 18:35:42 +01:00 
			
		
		
		
	serial: mxc: have putc use the TXFIFO
only waiting for TXEMPTY leads to corrupted messages going over the wire - which is fixed by making use of the FIFO this change is following the linux kernel uart driver (drivers/tty/serial/imx.c), which also checks UTS_TXFULL instead of UTS_TXEMPTY Signed-off-by: Johannes Schneider <johannes.schneider@leica-geosystems.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Fabio Estevam <festevam@denx.de>
This commit is contained in:
		
				
					committed by
					
						 Stefano Babic
						Stefano Babic
					
				
			
			
				
	
			
			
			
						parent
						
							25b7ce3287
						
					
				
				
					commit
					c7878a0483
				
			| @@ -311,7 +311,7 @@ static int mxc_serial_putc(struct udevice *dev, const char ch) | ||||
| 	struct mxc_serial_plat *plat = dev_get_plat(dev); | ||||
| 	struct mxc_uart *const uart = plat->reg; | ||||
|  | ||||
| 	if (!(readl(&uart->ts) & UTS_TXEMPTY)) | ||||
| 	if (readl(&uart->ts) & UTS_TXFULL) | ||||
| 		return -EAGAIN; | ||||
|  | ||||
| 	writel(ch, &uart->txd); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user