summaryrefslogtreecommitdiffstats
path: root/cpu/mcf52x2/serial.c
diff options
context:
space:
mode:
authorMarian Balakowicz <m8@semihalf.com>2006-04-27 19:12:19 +0200
committerMarian Balakowicz <m8@semihalf.com>2006-04-27 19:12:19 +0200
commit7a635e004ec12bd2a0bae9f90fbb5769b524a42e (patch)
tree9c0b3d146c12454e95395411094d420bc5b4a3d3 /cpu/mcf52x2/serial.c
parent76544f80e476a7a0cc3a0bbce853354f2c6a61e2 (diff)
parentf8c3b4f310a36e19d00d0f87fb37587abb65621d (diff)
downloadblackbird-obmc-uboot-7a635e004ec12bd2a0bae9f90fbb5769b524a42e.tar.gz
blackbird-obmc-uboot-7a635e004ec12bd2a0bae9f90fbb5769b524a42e.zip
Add support for Freescale M5271: Merge with /work/u-boot.mcf5271
Diffstat (limited to 'cpu/mcf52x2/serial.c')
-rw-r--r--cpu/mcf52x2/serial.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/cpu/mcf52x2/serial.c b/cpu/mcf52x2/serial.c
index 79628d03e6..8fbfad47bf 100644
--- a/cpu/mcf52x2/serial.c
+++ b/cpu/mcf52x2/serial.c
@@ -26,6 +26,10 @@
#include <asm/mcfuart.h>
+#ifdef CONFIG_M5271
+#include <asm/m5271.h>
+#endif
+
#ifdef CONFIG_M5272
#include <asm/m5272.h>
#endif
@@ -48,7 +52,7 @@ DECLARE_GLOBAL_DATA_PTR;
void rs_serial_setbaudrate(int port,int baudrate)
{
-#if defined(CONFIG_M5272) || defined(CONFIG_M5249)
+#if defined(CONFIG_M5272) || defined(CONFIG_M5249) || defined(CONFIG_M5271)
volatile unsigned char *uartp;
double clock, fraction;
@@ -63,8 +67,10 @@ void rs_serial_setbaudrate(int port,int baudrate)
uartp[MCFUART_UBG1] = (((int)clock >> 8) & 0xff); /* set msb baud */
uartp[MCFUART_UBG2] = ((int)clock & 0xff); /* set lsb baud */
+#ifndef CONFIG_M5271
uartp[MCFUART_UFPD] = ((int)fraction & 0xf); /* set baud fraction adjust */
#endif
+#endif
};
void rs_serial_init(int port,int baudrate)
OpenPOWER on IntegriCloud