diff options
author | Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com> | 2014-12-03 09:30:30 +0300 |
---|---|---|
committer | Nobuhiro Iwamatsu <iwamatsu@nigauri.org> | 2014-12-10 08:32:22 +0300 |
commit | 2b8c0814f88fa2d6fd8a1ac994e4396b39a0eac8 (patch) | |
tree | f05d7feb055b28596d9d81718d293919a13de5b2 /board/renesas/alt | |
parent | d7916b1d38c20a55ca7248742dd0bdf049deb7e4 (diff) | |
download | u-boot-2b8c0814f88fa2d6fd8a1ac994e4396b39a0eac8.tar.xz |
arm: rmobile: alt: Add support MMC and MMC command
Alt board has been connected to eMMC of 8GB to MMC port.
This enables MMC port and MMC command.
Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Diffstat (limited to 'board/renesas/alt')
-rw-r--r-- | board/renesas/alt/alt.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/board/renesas/alt/alt.c b/board/renesas/alt/alt.c index c794d43ee4..8cc17e9581 100644 --- a/board/renesas/alt/alt.c +++ b/board/renesas/alt/alt.c @@ -16,6 +16,7 @@ #include <asm/gpio.h> #include <asm/arch/rmobile.h> #include <asm/arch/rcar-mstp.h> +#include <asm/arch/mmc.h> #include <netdev.h> #include <miiphy.h> #include <i2c.h> @@ -42,6 +43,7 @@ void s_init(void) #define SCIF2_MSTP719 (1 << 19) #define ETHER_MSTP813 (1 << 13) #define IIC1_MSTP323 (1 << 23) +#define MMC0_MSTP315 (1 << 15) int board_early_init_f(void) { @@ -57,6 +59,10 @@ int board_early_init_f(void) /* IIC1 / sh-i2c ch1 */ mstp_clrbits_le32(MSTPSR3, SMSTPCR3, IIC1_MSTP323); +#ifdef CONFIG_SH_MMCIF + /* MMC */ + mstp_clrbits_le32(MSTPSR3, SMSTPCR3, MMC0_MSTP315); +#endif return 0; } @@ -120,6 +126,19 @@ int board_eth_init(bd_t *bis) #endif } +int board_mmc_init(bd_t *bis) +{ + int ret = 0; + +#ifdef CONFIG_SH_MMCIF + gpio_request(GPIO_GP_4_31, NULL); + gpio_set_value(GPIO_GP_4_31, 1); + + ret = mmcif_mmc_init(); +#endif + return ret; +} + int dram_init(void) { gd->ram_size = CONFIG_SYS_SDRAM_SIZE; |