summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorWu, Josh <Josh.wu@atmel.com>2012-09-13 22:22:05 +0000
committerAndreas Bießmann <andreas.devel@googlemail.com>2012-10-17 11:29:25 +0200
commit3a49cd7e1a26af6708b05d4877bb0254a08dded3 (patch)
tree5e6b6cc2910901a8b1fdb616b0c5604e8b1e71a1 /arch
parent1db7377a70a8d931c32648e717695133120d5456 (diff)
downloadu-boot-imx-3a49cd7e1a26af6708b05d4877bb0254a08dded3.zip
u-boot-imx-3a49cd7e1a26af6708b05d4877bb0254a08dded3.tar.gz
u-boot-imx-3a49cd7e1a26af6708b05d4877bb0254a08dded3.tar.bz2
ARM: at91sam9x5: enable MCI0 support for 9x5ek board.
Signed-off-by: Josh Wu <josh.wu@atmel.com> Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/cpu/arm926ejs/at91/at91sam9x5_devices.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/arm/cpu/arm926ejs/at91/at91sam9x5_devices.c b/arch/arm/cpu/arm926ejs/at91/at91sam9x5_devices.c
index 6d77219..9348552 100644
--- a/arch/arm/cpu/arm926ejs/at91/at91sam9x5_devices.c
+++ b/arch/arm/cpu/arm926ejs/at91/at91sam9x5_devices.c
@@ -118,6 +118,21 @@ void at91_serial2_hw_init(void)
writel(1 << ATMEL_ID_USART2, &pmc->pcer);
}
+void at91_mci_hw_init(void)
+{
+ /* Initialize the MCI0 */
+ at91_set_a_periph(AT91_PIO_PORTA, 17, 1); /* MCCK */
+ at91_set_a_periph(AT91_PIO_PORTA, 16, 1); /* MCCDA */
+ at91_set_a_periph(AT91_PIO_PORTA, 15, 1); /* MCDA0 */
+ at91_set_a_periph(AT91_PIO_PORTA, 18, 1); /* MCDA1 */
+ at91_set_a_periph(AT91_PIO_PORTA, 19, 1); /* MCDA2 */
+ at91_set_a_periph(AT91_PIO_PORTA, 20, 1); /* MCDA3 */
+
+ /* Enable clock for MCI0 */
+ struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC;
+ writel(1 << ATMEL_ID_HSMCI0, &pmc->pcer);
+}
+
#ifdef CONFIG_ATMEL_SPI
void at91_spi0_hw_init(unsigned long cs_mask)
{