aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-mxs/mach-mx28evk.c23
1 files changed, 11 insertions, 12 deletions
diff --git a/arch/arm/mach-mxs/mach-mx28evk.c b/arch/arm/mach-mxs/mach-mx28evk.c
index 3f86e7a4d2cc..8b3aa7afdae0 100644
--- a/arch/arm/mach-mxs/mach-mx28evk.c
+++ b/arch/arm/mach-mxs/mach-mx28evk.c
@@ -351,6 +351,11 @@ static struct mxs_mmc_platform_data mx28evk_mmc_pdata[] __initdata = {
351 }, 351 },
352}; 352};
353 353
354static struct gpio mx28evk_lcd_gpios[] = {
355 { MX28EVK_LCD_ENABLE, GPIOF_OUT_INIT_HIGH, "lcd-enable" },
356 { MX28EVK_BL_ENABLE, GPIOF_OUT_INIT_HIGH, "bl-enable" },
357};
358
354static void __init mx28evk_init(void) 359static void __init mx28evk_init(void)
355{ 360{
356 int ret; 361 int ret;
@@ -377,19 +382,12 @@ static void __init mx28evk_init(void)
377 mx28_add_flexcan(1, &mx28evk_flexcan_pdata[1]); 382 mx28_add_flexcan(1, &mx28evk_flexcan_pdata[1]);
378 } 383 }
379 384
380 ret = gpio_request_one(MX28EVK_LCD_ENABLE, GPIOF_DIR_OUT, "lcd-enable"); 385 ret = gpio_request_array(mx28evk_lcd_gpios,
386 ARRAY_SIZE(mx28evk_lcd_gpios));
381 if (ret) 387 if (ret)
382 pr_warn("failed to request gpio lcd-enable: %d\n", ret); 388 pr_warn("failed to request gpio pins for lcd: %d\n", ret);
383 else 389 else
384 gpio_set_value(MX28EVK_LCD_ENABLE, 1); 390 mx28_add_mxsfb(&mx28evk_mxsfb_pdata);
385
386 ret = gpio_request_one(MX28EVK_BL_ENABLE, GPIOF_DIR_OUT, "bl-enable");
387 if (ret)
388 pr_warn("failed to request gpio bl-enable: %d\n", ret);
389 else
390 gpio_set_value(MX28EVK_BL_ENABLE, 1);
391
392 mx28_add_mxsfb(&mx28evk_mxsfb_pdata);
393 391
394 /* power on mmc slot by writing 0 to the gpio */ 392 /* power on mmc slot by writing 0 to the gpio */
395 ret = gpio_request_one(MX28EVK_MMC0_SLOT_POWER, GPIOF_OUT_INIT_LOW, 393 ret = gpio_request_one(MX28EVK_MMC0_SLOT_POWER, GPIOF_OUT_INIT_LOW,
@@ -402,7 +400,8 @@ static void __init mx28evk_init(void)
402 "mmc1-slot-power"); 400 "mmc1-slot-power");
403 if (ret) 401 if (ret)
404 pr_warn("failed to request gpio mmc1-slot-power: %d\n", ret); 402 pr_warn("failed to request gpio mmc1-slot-power: %d\n", ret);
405 mx28_add_mxs_mmc(1, &mx28evk_mmc_pdata[1]); 403 else
404 mx28_add_mxs_mmc(1, &mx28evk_mmc_pdata[1]);
406 405
407 gpio_led_register_device(0, &mx28evk_led_data); 406 gpio_led_register_device(0, &mx28evk_led_data);
408} 407}