[U-Boot] [PATCH 7/7] mx35: Add cpu_mmc_init()
Benoît Thébaudeau
benoit.thebaudeau at advansee.com
Tue Aug 14 22:33:48 CEST 2012
Add cpu_mmc_init() function to make it easy to init a single eSDHC instance.
Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau at advansee.com>
Cc: Stefano Babic <sbabic at denx.de>
---
.../arch/arm/cpu/arm1136/mx35/generic.c | 19 ++++++++++++++++++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git u-boot-4d3c95f.orig/arch/arm/cpu/arm1136/mx35/generic.c u-boot-4d3c95f/arch/arm/cpu/arm1136/mx35/generic.c
index 15a0098..7b643b7 100644
--- u-boot-4d3c95f.orig/arch/arm/cpu/arm1136/mx35/generic.c
+++ u-boot-4d3c95f/arch/arm/cpu/arm1136/mx35/generic.c
@@ -31,6 +31,9 @@
#include <asm/arch/crm_regs.h>
#include <asm/arch/clock.h>
#include <asm/arch/sys_proto.h>
+#ifdef CONFIG_FSL_ESDHC
+#include <fsl_esdhc.h>
+#endif
#include <netdev.h>
#define CLK_CODE(arm, ahb, sel) (((arm) << 16) + ((ahb) << 8) + (sel))
@@ -458,7 +461,6 @@ int print_cpuinfo(void)
* Initializes on-chip ethernet controllers.
* to override, implement board_eth_init()
*/
-
int cpu_eth_init(bd_t *bis)
{
int rc = -ENODEV;
@@ -470,6 +472,21 @@ int cpu_eth_init(bd_t *bis)
return rc;
}
+/*
+ * Initializes on-chip MMC controllers.
+ * to override, implement board_mmc_init()
+ */
+int cpu_mmc_init(bd_t * bis)
+{
+ int rc = -ENODEV;
+
+#ifdef CONFIG_FSL_ESDHC
+ rc = fsl_esdhc_mmc_init(bis);
+#endif
+
+ return rc;
+}
+
int get_clocks(void)
{
#ifdef CONFIG_FSL_ESDHC
More information about the U-Boot
mailing list