summaryrefslogtreecommitdiff
path: root/arch/powerpc/cpu/mpc8xx
diff options
context:
space:
mode:
authorMarek Vasut <marex@denx.de>2012-09-12 13:50:56 +0200
committerTom Rini <trini@ti.com>2012-10-15 11:53:49 -0700
commitf0eb1f61b02ebd5c86c1db4399f7d78518377910 (patch)
treeabf6f43d93e9e2b19acde4947df6148316bbd076 /arch/powerpc/cpu/mpc8xx
parent2a333aeb8ff4e7b05c47bfaec1816fc2eb8e0198 (diff)
downloadu-boot-imx-f0eb1f61b02ebd5c86c1db4399f7d78518377910.zip
u-boot-imx-f0eb1f61b02ebd5c86c1db4399f7d78518377910.tar.gz
u-boot-imx-f0eb1f61b02ebd5c86c1db4399f7d78518377910.tar.bz2
serial: mpc8xx: Move serial registration from serial_initialize()
Move the registration of serial_smc and serial_scc ports from default serial_initialize() into CPU specific function called from serial_initialize(). This slims down the serial_initialize() call to a bare tracker of all possible serial port registration routines in U-Boot. The exports of both serial_scc_device and serial_smc_device can not yet be removed as they are still used in default_serial_console() calls. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Tom Rini <trini@ti.com> Cc: Anatolij Gustschin <agust@denx.de> Cc: Stefan Roese <sr@denx.de> Cc: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'arch/powerpc/cpu/mpc8xx')
-rw-r--r--arch/powerpc/cpu/mpc8xx/serial.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/powerpc/cpu/mpc8xx/serial.c b/arch/powerpc/cpu/mpc8xx/serial.c
index dc9b323..00888e9 100644
--- a/arch/powerpc/cpu/mpc8xx/serial.c
+++ b/arch/powerpc/cpu/mpc8xx/serial.c
@@ -681,6 +681,17 @@ __weak struct serial_device *default_serial_console(void)
#endif
}
+void mpc8xx_serial_initialize(void)
+{
+#if defined(CONFIG_8xx_CONS_SMC1) || defined(CONFIG_8xx_CONS_SMC2)
+ serial_register(&serial_smc_device);
+#endif
+#if defined(CONFIG_8xx_CONS_SCC1) || defined(CONFIG_8xx_CONS_SCC2) || \
+ defined(CONFIG_8xx_CONS_SCC3) || defined(CONFIG_8xx_CONS_SCC4)
+ serial_register(&serial_scc_device);
+#endif
+}
+
#ifdef CONFIG_MODEM_SUPPORT
void disable_putc(void)
{