[PATCH 8/9] Samsung/serial: unify UCON register settings
Juergen Beisert
jbe at pengutronix.de
Fri Jul 20 15:29:44 EDT 2012
This should work on S3C24XX and S3C64XX SoCs.
Tested at runtime on a Mini2440 and Mini6410.
Signed-off-by: Juergen Beisert <jbe at pengutronix.de>
---
drivers/serial/serial_s3c.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/drivers/serial/serial_s3c.c b/drivers/serial/serial_s3c.c
index 01f2246..39680ae 100644
--- a/drivers/serial/serial_s3c.c
+++ b/drivers/serial/serial_s3c.c
@@ -102,9 +102,13 @@ static int s3c_serial_init_port(struct console_device *cdev)
/* Normal,No parity,1 stop,8 bit */
writeb(0x03, base + ULCON);
- /* tx=level,rx=edge,disable timeout int.,enable rx error int.,
- * normal, interrupt or polling, no pre-divider */
- writew(0x0245 | UCON_SET_CLK_SRC(S3C_UART_CLKSEL),
+ /*
+ * S3C2440 SoC:
+ * - no clock divider
+ * all SoCs:
+ * - enable receive and transmit mode
+ */
+ writew(0x0005 | UCON_SET_CLK_SRC(S3C_UART_CLKSEL),
base + UCON);
if (IS_ENABLED(CONFIG_SAMSUNG_IMPROVED_UART))
--
1.7.10.4
More information about the barebox
mailing list