Skip to contentSkip to conversation

stm32f4: fix serial output

PATCH New kunhuahuang 2 participants 2 messages Apr 27, 2015 – May 10, 2015 Arm STM32

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 stm32f4: fix serial output

This patch fix the serial output.
The source is from Kamil Lulko's "stm32f429-discovery board support"

Thanks, Varcain. I learned a lot.

---
 drivers/serial/serial_stm32.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/serial/serial_stm32.c +4 -0
index 3c80096..8c613db 100644
@@ -81,6 +81,10 @@ static int stm32_serial_getc(void)
 static void stm32_serial_putc(const char c)
 {
 	struct stm32_serial *usart = (struct stm32_serial *)USART_BASE;
+
+	if (c == '\n')
+		stm32_serial_putc('\r');
+
 	while ((readl(&usart->sr) & USART_SR_FLAG_TXE) == 0)
 		;
 	writel(c, &usart->dr);
Signature · 1 line
1.9.1
#1 lore raw

PATCH v2 1/1 stm32f4: fix serial output

Quoted 6 lines · kunhuahuang

This patch fix the serial output.
The source is from Kamil Lulko's "stm32f429-discovery board support"

Thanks, Varcain. I learned a lot.

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20150510/d91de6d4/attachment.sig>