aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mx5/board-mx51_babbage.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-mx5/board-mx51_babbage.c')
-rw-r--r--arch/arm/mach-mx5/board-mx51_babbage.c22
1 files changed, 20 insertions, 2 deletions
diff --git a/arch/arm/mach-mx5/board-mx51_babbage.c b/arch/arm/mach-mx5/board-mx51_babbage.c
index e54e4bf61cfd..15c600026aee 100644
--- a/arch/arm/mach-mx5/board-mx51_babbage.c
+++ b/arch/arm/mach-mx5/board-mx51_babbage.c
@@ -41,6 +41,10 @@
41#define BABBAGE_POWER_KEY IMX_GPIO_NR(2, 21) 41#define BABBAGE_POWER_KEY IMX_GPIO_NR(2, 21)
42#define BABBAGE_ECSPI1_CS0 IMX_GPIO_NR(4, 24) 42#define BABBAGE_ECSPI1_CS0 IMX_GPIO_NR(4, 24)
43#define BABBAGE_ECSPI1_CS1 IMX_GPIO_NR(4, 25) 43#define BABBAGE_ECSPI1_CS1 IMX_GPIO_NR(4, 25)
44#define BABBAGE_SD1_CD IMX_GPIO_NR(1, 0)
45#define BABBAGE_SD1_WP IMX_GPIO_NR(1, 1)
46#define BABBAGE_SD2_CD IMX_GPIO_NR(1, 6)
47#define BABBAGE_SD2_WP IMX_GPIO_NR(1, 5)
44 48
45/* USB_CTRL_1 */ 49/* USB_CTRL_1 */
46#define MX51_USB_CTRL_1_OFFSET 0x10 50#define MX51_USB_CTRL_1_OFFSET 0x10
@@ -142,6 +146,8 @@ static iomux_v3_cfg_t mx51babbage_pads[] = {
142 MX51_PAD_SD1_DATA1__SD1_DATA1, 146 MX51_PAD_SD1_DATA1__SD1_DATA1,
143 MX51_PAD_SD1_DATA2__SD1_DATA2, 147 MX51_PAD_SD1_DATA2__SD1_DATA2,
144 MX51_PAD_SD1_DATA3__SD1_DATA3, 148 MX51_PAD_SD1_DATA3__SD1_DATA3,
149 MX51_PAD_GPIO1_0__GPIO1_0,
150 MX51_PAD_GPIO1_1__GPIO1_1,
145 151
146 /* SD 2 */ 152 /* SD 2 */
147 MX51_PAD_SD2_CMD__SD2_CMD, 153 MX51_PAD_SD2_CMD__SD2_CMD,
@@ -150,6 +156,8 @@ static iomux_v3_cfg_t mx51babbage_pads[] = {
150 MX51_PAD_SD2_DATA1__SD2_DATA1, 156 MX51_PAD_SD2_DATA1__SD2_DATA1,
151 MX51_PAD_SD2_DATA2__SD2_DATA2, 157 MX51_PAD_SD2_DATA2__SD2_DATA2,
152 MX51_PAD_SD2_DATA3__SD2_DATA3, 158 MX51_PAD_SD2_DATA3__SD2_DATA3,
159 MX51_PAD_GPIO1_6__GPIO1_6,
160 MX51_PAD_GPIO1_5__GPIO1_5,
153 161
154 /* eCSPI1 */ 162 /* eCSPI1 */
155 MX51_PAD_CSPI1_MISO__ECSPI1_MISO, 163 MX51_PAD_CSPI1_MISO__ECSPI1_MISO,
@@ -331,6 +339,16 @@ static const struct spi_imx_master mx51_babbage_spi_pdata __initconst = {
331 .num_chipselect = ARRAY_SIZE(mx51_babbage_spi_cs), 339 .num_chipselect = ARRAY_SIZE(mx51_babbage_spi_cs),
332}; 340};
333 341
342static const struct esdhc_platform_data mx51_babbage_sd1_data __initconst = {
343 .cd_gpio = BABBAGE_SD1_CD,
344 .wp_gpio = BABBAGE_SD1_WP,
345};
346
347static const struct esdhc_platform_data mx51_babbage_sd2_data __initconst = {
348 .cd_gpio = BABBAGE_SD2_CD,
349 .wp_gpio = BABBAGE_SD2_WP,
350};
351
334/* 352/*
335 * Board specific initialization. 353 * Board specific initialization.
336 */ 354 */
@@ -376,8 +394,8 @@ static void __init mx51_babbage_init(void)
376 mxc_iomux_v3_setup_pad(usbh1stp); 394 mxc_iomux_v3_setup_pad(usbh1stp);
377 babbage_usbhub_reset(); 395 babbage_usbhub_reset();
378 396
379 imx51_add_sdhci_esdhc_imx(0, NULL); 397 imx51_add_sdhci_esdhc_imx(0, &mx51_babbage_sd1_data);
380 imx51_add_sdhci_esdhc_imx(1, NULL); 398 imx51_add_sdhci_esdhc_imx(1, &mx51_babbage_sd2_data);
381 399
382 spi_register_board_info(mx51_babbage_spi_board_info, 400 spi_register_board_info(mx51_babbage_spi_board_info,
383 ARRAY_SIZE(mx51_babbage_spi_board_info)); 401 ARRAY_SIZE(mx51_babbage_spi_board_info));