diff options
Diffstat (limited to 'arch')
23 files changed, 801 insertions, 116 deletions
diff --git a/arch/arm/configs/omap2plus_defconfig b/arch/arm/configs/omap2plus_defconfig index 019fb7c67dc3..076db52ff672 100644 --- a/arch/arm/configs/omap2plus_defconfig +++ b/arch/arm/configs/omap2plus_defconfig | |||
@@ -193,6 +193,17 @@ CONFIG_FIRMWARE_EDID=y | |||
193 | CONFIG_FB_MODE_HELPERS=y | 193 | CONFIG_FB_MODE_HELPERS=y |
194 | CONFIG_FB_TILEBLITTING=y | 194 | CONFIG_FB_TILEBLITTING=y |
195 | CONFIG_FB_OMAP_LCD_VGA=y | 195 | CONFIG_FB_OMAP_LCD_VGA=y |
196 | CONFIG_OMAP2_DSS=m | ||
197 | CONFIG_OMAP2_DSS_RFBI=y | ||
198 | CONFIG_OMAP2_DSS_SDI=y | ||
199 | CONFIG_OMAP2_DSS_DSI=y | ||
200 | CONFIG_FB_OMAP2=m | ||
201 | CONFIG_PANEL_GENERIC_DPI=m | ||
202 | CONFIG_PANEL_SHARP_LS037V7DW01=m | ||
203 | CONFIG_PANEL_NEC_NL8048HL11_01B=m | ||
204 | CONFIG_PANEL_TAAL=m | ||
205 | CONFIG_PANEL_TPO_TD043MTEA1=m | ||
206 | CONFIG_PANEL_ACX565AKM=m | ||
196 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | 207 | CONFIG_BACKLIGHT_LCD_SUPPORT=y |
197 | CONFIG_LCD_CLASS_DEVICE=y | 208 | CONFIG_LCD_CLASS_DEVICE=y |
198 | CONFIG_LCD_PLATFORM=y | 209 | CONFIG_LCD_PLATFORM=y |
diff --git a/arch/arm/mach-omap2/board-3430sdp.c b/arch/arm/mach-omap2/board-3430sdp.c index c06eb423c4e4..9afd087cc29c 100644 --- a/arch/arm/mach-omap2/board-3430sdp.c +++ b/arch/arm/mach-omap2/board-3430sdp.c | |||
@@ -307,9 +307,6 @@ static struct omap_dss_board_info sdp3430_dss_data = { | |||
307 | .default_device = &sdp3430_lcd_device, | 307 | .default_device = &sdp3430_lcd_device, |
308 | }; | 308 | }; |
309 | 309 | ||
310 | static struct regulator_consumer_supply sdp3430_vdda_dac_supply = | ||
311 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | ||
312 | |||
313 | static struct omap_board_config_kernel sdp3430_config[] __initdata = { | 310 | static struct omap_board_config_kernel sdp3430_config[] __initdata = { |
314 | }; | 311 | }; |
315 | 312 | ||
@@ -398,12 +395,13 @@ static struct regulator_consumer_supply sdp3430_vaux3_supplies[] = { | |||
398 | }; | 395 | }; |
399 | 396 | ||
400 | static struct regulator_consumer_supply sdp3430_vdda_dac_supplies[] = { | 397 | static struct regulator_consumer_supply sdp3430_vdda_dac_supplies[] = { |
401 | REGULATOR_SUPPLY("vdda_dac", "omapdss"), | 398 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"), |
402 | }; | 399 | }; |
403 | 400 | ||
404 | /* VPLL2 for digital video outputs */ | 401 | /* VPLL2 for digital video outputs */ |
405 | static struct regulator_consumer_supply sdp3430_vpll2_supplies[] = { | 402 | static struct regulator_consumer_supply sdp3430_vpll2_supplies[] = { |
406 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), | 403 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
404 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
407 | }; | 405 | }; |
408 | 406 | ||
409 | static struct regulator_consumer_supply sdp3430_vmmc1_supplies[] = { | 407 | static struct regulator_consumer_supply sdp3430_vmmc1_supplies[] = { |
diff --git a/arch/arm/mach-omap2/board-4430sdp.c b/arch/arm/mach-omap2/board-4430sdp.c index 333ceb2c8fb0..62c78de1aa51 100644 --- a/arch/arm/mach-omap2/board-4430sdp.c +++ b/arch/arm/mach-omap2/board-4430sdp.c | |||
@@ -36,6 +36,7 @@ | |||
36 | #include <plat/usb.h> | 36 | #include <plat/usb.h> |
37 | #include <plat/mmc.h> | 37 | #include <plat/mmc.h> |
38 | #include <plat/omap4-keypad.h> | 38 | #include <plat/omap4-keypad.h> |
39 | #include <plat/display.h> | ||
39 | 40 | ||
40 | #include "mux.h" | 41 | #include "mux.h" |
41 | #include "hsmmc.h" | 42 | #include "hsmmc.h" |
@@ -47,6 +48,8 @@ | |||
47 | #define ETH_KS8851_QUART 138 | 48 | #define ETH_KS8851_QUART 138 |
48 | #define OMAP4_SFH7741_SENSOR_OUTPUT_GPIO 184 | 49 | #define OMAP4_SFH7741_SENSOR_OUTPUT_GPIO 184 |
49 | #define OMAP4_SFH7741_ENABLE_GPIO 188 | 50 | #define OMAP4_SFH7741_ENABLE_GPIO 188 |
51 | #define HDMI_GPIO_HPD 60 /* Hot plug pin for HDMI */ | ||
52 | #define HDMI_GPIO_LS_OE 41 /* Level shifter for HDMI */ | ||
50 | 53 | ||
51 | static const int sdp4430_keymap[] = { | 54 | static const int sdp4430_keymap[] = { |
52 | KEY(0, 0, KEY_E), | 55 | KEY(0, 0, KEY_E), |
@@ -621,6 +624,76 @@ static void __init omap_sfh7741prox_init(void) | |||
621 | } | 624 | } |
622 | } | 625 | } |
623 | 626 | ||
627 | static void sdp4430_hdmi_mux_init(void) | ||
628 | { | ||
629 | /* PAD0_HDMI_HPD_PAD1_HDMI_CEC */ | ||
630 | omap_mux_init_signal("hdmi_hpd", | ||
631 | OMAP_PIN_INPUT_PULLUP); | ||
632 | omap_mux_init_signal("hdmi_cec", | ||
633 | OMAP_PIN_INPUT_PULLUP); | ||
634 | /* PAD0_HDMI_DDC_SCL_PAD1_HDMI_DDC_SDA */ | ||
635 | omap_mux_init_signal("hdmi_ddc_scl", | ||
636 | OMAP_PIN_INPUT_PULLUP); | ||
637 | omap_mux_init_signal("hdmi_ddc_sda", | ||
638 | OMAP_PIN_INPUT_PULLUP); | ||
639 | } | ||
640 | |||
641 | static int sdp4430_panel_enable_hdmi(struct omap_dss_device *dssdev) | ||
642 | { | ||
643 | int status; | ||
644 | |||
645 | status = gpio_request_one(HDMI_GPIO_HPD, GPIOF_OUT_INIT_HIGH, | ||
646 | "hdmi_gpio_hpd"); | ||
647 | if (status) { | ||
648 | pr_err("Cannot request GPIO %d\n", HDMI_GPIO_HPD); | ||
649 | return status; | ||
650 | } | ||
651 | status = gpio_request_one(HDMI_GPIO_LS_OE, GPIOF_OUT_INIT_HIGH, | ||
652 | "hdmi_gpio_ls_oe"); | ||
653 | if (status) { | ||
654 | pr_err("Cannot request GPIO %d\n", HDMI_GPIO_LS_OE); | ||
655 | goto error1; | ||
656 | } | ||
657 | |||
658 | return 0; | ||
659 | |||
660 | error1: | ||
661 | gpio_free(HDMI_GPIO_HPD); | ||
662 | |||
663 | return status; | ||
664 | } | ||
665 | |||
666 | static void sdp4430_panel_disable_hdmi(struct omap_dss_device *dssdev) | ||
667 | { | ||
668 | gpio_free(HDMI_GPIO_LS_OE); | ||
669 | gpio_free(HDMI_GPIO_HPD); | ||
670 | } | ||
671 | |||
672 | static struct omap_dss_device sdp4430_hdmi_device = { | ||
673 | .name = "hdmi", | ||
674 | .driver_name = "hdmi_panel", | ||
675 | .type = OMAP_DISPLAY_TYPE_HDMI, | ||
676 | .platform_enable = sdp4430_panel_enable_hdmi, | ||
677 | .platform_disable = sdp4430_panel_disable_hdmi, | ||
678 | .channel = OMAP_DSS_CHANNEL_DIGIT, | ||
679 | }; | ||
680 | |||
681 | static struct omap_dss_device *sdp4430_dss_devices[] = { | ||
682 | &sdp4430_hdmi_device, | ||
683 | }; | ||
684 | |||
685 | static struct omap_dss_board_info sdp4430_dss_data = { | ||
686 | .num_devices = ARRAY_SIZE(sdp4430_dss_devices), | ||
687 | .devices = sdp4430_dss_devices, | ||
688 | .default_device = &sdp4430_hdmi_device, | ||
689 | }; | ||
690 | |||
691 | void omap_4430sdp_display_init(void) | ||
692 | { | ||
693 | sdp4430_hdmi_mux_init(); | ||
694 | omap_display_init(&sdp4430_dss_data); | ||
695 | } | ||
696 | |||
624 | #ifdef CONFIG_OMAP_MUX | 697 | #ifdef CONFIG_OMAP_MUX |
625 | static struct omap_board_mux board_mux[] __initdata = { | 698 | static struct omap_board_mux board_mux[] __initdata = { |
626 | OMAP4_MUX(USBB2_ULPITLL_CLK, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT), | 699 | OMAP4_MUX(USBB2_ULPITLL_CLK, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT), |
@@ -729,6 +802,8 @@ static void __init omap_4430sdp_init(void) | |||
729 | status = omap4_keyboard_init(&sdp4430_keypad_data); | 802 | status = omap4_keyboard_init(&sdp4430_keypad_data); |
730 | if (status) | 803 | if (status) |
731 | pr_err("Keypad initialization failed: %d\n", status); | 804 | pr_err("Keypad initialization failed: %d\n", status); |
805 | |||
806 | omap_4430sdp_display_init(); | ||
732 | } | 807 | } |
733 | 808 | ||
734 | static void __init omap_4430sdp_map_io(void) | 809 | static void __init omap_4430sdp_map_io(void) |
diff --git a/arch/arm/mach-omap2/board-cm-t35.c b/arch/arm/mach-omap2/board-cm-t35.c index 7b5647954c13..02a12b41c0ff 100644 --- a/arch/arm/mach-omap2/board-cm-t35.c +++ b/arch/arm/mach-omap2/board-cm-t35.c | |||
@@ -488,7 +488,7 @@ static struct regulator_consumer_supply cm_t35_vsim_supply = { | |||
488 | }; | 488 | }; |
489 | 489 | ||
490 | static struct regulator_consumer_supply cm_t35_vdac_supply = | 490 | static struct regulator_consumer_supply cm_t35_vdac_supply = |
491 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 491 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
492 | 492 | ||
493 | static struct regulator_consumer_supply cm_t35_vdvi_supply = | 493 | static struct regulator_consumer_supply cm_t35_vdvi_supply = |
494 | REGULATOR_SUPPLY("vdvi", "omapdss"); | 494 | REGULATOR_SUPPLY("vdvi", "omapdss"); |
diff --git a/arch/arm/mach-omap2/board-devkit8000.c b/arch/arm/mach-omap2/board-devkit8000.c index aa27483c493e..65f9fde2c567 100644 --- a/arch/arm/mach-omap2/board-devkit8000.c +++ b/arch/arm/mach-omap2/board-devkit8000.c | |||
@@ -196,7 +196,7 @@ static struct omap_dss_board_info devkit8000_dss_data = { | |||
196 | }; | 196 | }; |
197 | 197 | ||
198 | static struct regulator_consumer_supply devkit8000_vdda_dac_supply = | 198 | static struct regulator_consumer_supply devkit8000_vdda_dac_supply = |
199 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 199 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
200 | 200 | ||
201 | static uint32_t board_keymap[] = { | 201 | static uint32_t board_keymap[] = { |
202 | KEY(0, 0, KEY_1), | 202 | KEY(0, 0, KEY_1), |
@@ -277,8 +277,10 @@ static struct twl4030_gpio_platform_data devkit8000_gpio_data = { | |||
277 | .setup = devkit8000_twl_gpio_setup, | 277 | .setup = devkit8000_twl_gpio_setup, |
278 | }; | 278 | }; |
279 | 279 | ||
280 | static struct regulator_consumer_supply devkit8000_vpll1_supply = | 280 | static struct regulator_consumer_supply devkit8000_vpll1_supplies[] = { |
281 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"); | 281 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
282 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
283 | }; | ||
282 | 284 | ||
283 | /* VMMC1 for MMC1 pins CMD, CLK, DAT0..DAT3 (20 mA, plus card == max 220 mA) */ | 285 | /* VMMC1 for MMC1 pins CMD, CLK, DAT0..DAT3 (20 mA, plus card == max 220 mA) */ |
284 | static struct regulator_init_data devkit8000_vmmc1 = { | 286 | static struct regulator_init_data devkit8000_vmmc1 = { |
@@ -319,8 +321,8 @@ static struct regulator_init_data devkit8000_vpll1 = { | |||
319 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 321 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
320 | | REGULATOR_CHANGE_STATUS, | 322 | | REGULATOR_CHANGE_STATUS, |
321 | }, | 323 | }, |
322 | .num_consumer_supplies = 1, | 324 | .num_consumer_supplies = ARRAY_SIZE(devkit8000_vpll1_supplies), |
323 | .consumer_supplies = &devkit8000_vpll1_supply, | 325 | .consumer_supplies = devkit8000_vpll1_supplies, |
324 | }; | 326 | }; |
325 | 327 | ||
326 | /* VAUX4 for ads7846 and nubs */ | 328 | /* VAUX4 for ads7846 and nubs */ |
diff --git a/arch/arm/mach-omap2/board-igep0020.c b/arch/arm/mach-omap2/board-igep0020.c index d3199b4ecdb6..5f8a2fd06337 100644 --- a/arch/arm/mach-omap2/board-igep0020.c +++ b/arch/arm/mach-omap2/board-igep0020.c | |||
@@ -485,8 +485,10 @@ static struct omap_dss_board_info igep2_dss_data = { | |||
485 | .default_device = &igep2_dvi_device, | 485 | .default_device = &igep2_dvi_device, |
486 | }; | 486 | }; |
487 | 487 | ||
488 | static struct regulator_consumer_supply igep2_vpll2_supply = | 488 | static struct regulator_consumer_supply igep2_vpll2_supplies[] = { |
489 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"); | 489 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
490 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
491 | }; | ||
490 | 492 | ||
491 | static struct regulator_init_data igep2_vpll2 = { | 493 | static struct regulator_init_data igep2_vpll2 = { |
492 | .constraints = { | 494 | .constraints = { |
@@ -499,8 +501,8 @@ static struct regulator_init_data igep2_vpll2 = { | |||
499 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 501 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
500 | | REGULATOR_CHANGE_STATUS, | 502 | | REGULATOR_CHANGE_STATUS, |
501 | }, | 503 | }, |
502 | .num_consumer_supplies = 1, | 504 | .num_consumer_supplies = ARRAY_SIZE(igep2_vpll2_supplies), |
503 | .consumer_supplies = &igep2_vpll2_supply, | 505 | .consumer_supplies = igep2_vpll2_supplies, |
504 | }; | 506 | }; |
505 | 507 | ||
506 | static void __init igep2_display_init(void) | 508 | static void __init igep2_display_init(void) |
diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c index 7640c054f43b..33007fd4a083 100644 --- a/arch/arm/mach-omap2/board-omap3beagle.c +++ b/arch/arm/mach-omap2/board-omap3beagle.c | |||
@@ -232,10 +232,12 @@ static struct omap_dss_board_info beagle_dss_data = { | |||
232 | }; | 232 | }; |
233 | 233 | ||
234 | static struct regulator_consumer_supply beagle_vdac_supply = | 234 | static struct regulator_consumer_supply beagle_vdac_supply = |
235 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 235 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
236 | 236 | ||
237 | static struct regulator_consumer_supply beagle_vdvi_supply = | 237 | static struct regulator_consumer_supply beagle_vdvi_supplies[] = { |
238 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"); | 238 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
239 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
240 | }; | ||
239 | 241 | ||
240 | static void __init beagle_display_init(void) | 242 | static void __init beagle_display_init(void) |
241 | { | 243 | { |
@@ -422,8 +424,8 @@ static struct regulator_init_data beagle_vpll2 = { | |||
422 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 424 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
423 | | REGULATOR_CHANGE_STATUS, | 425 | | REGULATOR_CHANGE_STATUS, |
424 | }, | 426 | }, |
425 | .num_consumer_supplies = 1, | 427 | .num_consumer_supplies = ARRAY_SIZE(beagle_vdvi_supplies), |
426 | .consumer_supplies = &beagle_vdvi_supply, | 428 | .consumer_supplies = beagle_vdvi_supplies, |
427 | }; | 429 | }; |
428 | 430 | ||
429 | static struct twl4030_usb_data beagle_usb_data = { | 431 | static struct twl4030_usb_data beagle_usb_data = { |
diff --git a/arch/arm/mach-omap2/board-omap3evm.c b/arch/arm/mach-omap2/board-omap3evm.c index 0fa2c7b208b1..5a1a916e5cc8 100644 --- a/arch/arm/mach-omap2/board-omap3evm.c +++ b/arch/arm/mach-omap2/board-omap3evm.c | |||
@@ -542,7 +542,7 @@ static struct twl4030_codec_data omap3evm_codec_data = { | |||
542 | }; | 542 | }; |
543 | 543 | ||
544 | static struct regulator_consumer_supply omap3_evm_vdda_dac_supply = | 544 | static struct regulator_consumer_supply omap3_evm_vdda_dac_supply = |
545 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 545 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
546 | 546 | ||
547 | /* VDAC for DSS driving S-Video */ | 547 | /* VDAC for DSS driving S-Video */ |
548 | static struct regulator_init_data omap3_evm_vdac = { | 548 | static struct regulator_init_data omap3_evm_vdac = { |
@@ -560,8 +560,10 @@ static struct regulator_init_data omap3_evm_vdac = { | |||
560 | }; | 560 | }; |
561 | 561 | ||
562 | /* VPLL2 for digital video outputs */ | 562 | /* VPLL2 for digital video outputs */ |
563 | static struct regulator_consumer_supply omap3_evm_vpll2_supply = | 563 | static struct regulator_consumer_supply omap3_evm_vpll2_supplies[] = { |
564 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"); | 564 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
565 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
566 | }; | ||
565 | 567 | ||
566 | static struct regulator_init_data omap3_evm_vpll2 = { | 568 | static struct regulator_init_data omap3_evm_vpll2 = { |
567 | .constraints = { | 569 | .constraints = { |
@@ -573,8 +575,8 @@ static struct regulator_init_data omap3_evm_vpll2 = { | |||
573 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 575 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
574 | | REGULATOR_CHANGE_STATUS, | 576 | | REGULATOR_CHANGE_STATUS, |
575 | }, | 577 | }, |
576 | .num_consumer_supplies = 1, | 578 | .num_consumer_supplies = ARRAY_SIZE(omap3_evm_vpll2_supplies), |
577 | .consumer_supplies = &omap3_evm_vpll2_supply, | 579 | .consumer_supplies = omap3_evm_vpll2_supplies, |
578 | }; | 580 | }; |
579 | 581 | ||
580 | /* ads7846 on SPI */ | 582 | /* ads7846 on SPI */ |
diff --git a/arch/arm/mach-omap2/board-omap3pandora.c b/arch/arm/mach-omap2/board-omap3pandora.c index 2e5dc21e3477..07dba888f450 100644 --- a/arch/arm/mach-omap2/board-omap3pandora.c +++ b/arch/arm/mach-omap2/board-omap3pandora.c | |||
@@ -342,11 +342,12 @@ static struct regulator_consumer_supply pandora_vmmc3_supply = | |||
342 | REGULATOR_SUPPLY("vmmc", "omap_hsmmc.2"); | 342 | REGULATOR_SUPPLY("vmmc", "omap_hsmmc.2"); |
343 | 343 | ||
344 | static struct regulator_consumer_supply pandora_vdda_dac_supply = | 344 | static struct regulator_consumer_supply pandora_vdda_dac_supply = |
345 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 345 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
346 | 346 | ||
347 | static struct regulator_consumer_supply pandora_vdds_supplies[] = { | 347 | static struct regulator_consumer_supply pandora_vdds_supplies[] = { |
348 | REGULATOR_SUPPLY("vdds_sdi", "omapdss"), | 348 | REGULATOR_SUPPLY("vdds_sdi", "omapdss"), |
349 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), | 349 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
350 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
350 | }; | 351 | }; |
351 | 352 | ||
352 | static struct regulator_consumer_supply pandora_vcc_lcd_supply = | 353 | static struct regulator_consumer_supply pandora_vcc_lcd_supply = |
diff --git a/arch/arm/mach-omap2/board-omap3stalker.c b/arch/arm/mach-omap2/board-omap3stalker.c index 8ebdbc38b9de..a6e0b9161c99 100644 --- a/arch/arm/mach-omap2/board-omap3stalker.c +++ b/arch/arm/mach-omap2/board-omap3stalker.c | |||
@@ -439,7 +439,7 @@ static struct twl4030_codec_data omap3stalker_codec_data = { | |||
439 | }; | 439 | }; |
440 | 440 | ||
441 | static struct regulator_consumer_supply omap3_stalker_vdda_dac_supply = | 441 | static struct regulator_consumer_supply omap3_stalker_vdda_dac_supply = |
442 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 442 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
443 | 443 | ||
444 | /* VDAC for DSS driving S-Video */ | 444 | /* VDAC for DSS driving S-Video */ |
445 | static struct regulator_init_data omap3_stalker_vdac = { | 445 | static struct regulator_init_data omap3_stalker_vdac = { |
@@ -457,8 +457,10 @@ static struct regulator_init_data omap3_stalker_vdac = { | |||
457 | }; | 457 | }; |
458 | 458 | ||
459 | /* VPLL2 for digital video outputs */ | 459 | /* VPLL2 for digital video outputs */ |
460 | static struct regulator_consumer_supply omap3_stalker_vpll2_supply = | 460 | static struct regulator_consumer_supply omap3_stalker_vpll2_supplies[] = { |
461 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"); | 461 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
462 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
463 | }; | ||
462 | 464 | ||
463 | static struct regulator_init_data omap3_stalker_vpll2 = { | 465 | static struct regulator_init_data omap3_stalker_vpll2 = { |
464 | .constraints = { | 466 | .constraints = { |
@@ -471,8 +473,8 @@ static struct regulator_init_data omap3_stalker_vpll2 = { | |||
471 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 473 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
472 | | REGULATOR_CHANGE_STATUS, | 474 | | REGULATOR_CHANGE_STATUS, |
473 | }, | 475 | }, |
474 | .num_consumer_supplies = 1, | 476 | .num_consumer_supplies = ARRAY_SIZE(omap3_stalker_vpll2_supplies), |
475 | .consumer_supplies = &omap3_stalker_vpll2_supply, | 477 | .consumer_supplies = omap3_stalker_vpll2_supplies, |
476 | }; | 478 | }; |
477 | 479 | ||
478 | static struct twl4030_platform_data omap3stalker_twldata = { | 480 | static struct twl4030_platform_data omap3stalker_twldata = { |
diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c index 0f4d8a762a70..209cffbee4e0 100644 --- a/arch/arm/mach-omap2/board-omap4panda.c +++ b/arch/arm/mach-omap2/board-omap4panda.c | |||
@@ -34,11 +34,13 @@ | |||
34 | #include <asm/mach-types.h> | 34 | #include <asm/mach-types.h> |
35 | #include <asm/mach/arch.h> | 35 | #include <asm/mach/arch.h> |
36 | #include <asm/mach/map.h> | 36 | #include <asm/mach/map.h> |
37 | #include <plat/display.h> | ||
37 | 38 | ||
38 | #include <plat/board.h> | 39 | #include <plat/board.h> |
39 | #include <plat/common.h> | 40 | #include <plat/common.h> |
40 | #include <plat/usb.h> | 41 | #include <plat/usb.h> |
41 | #include <plat/mmc.h> | 42 | #include <plat/mmc.h> |
43 | #include <plat/panel-generic-dpi.h> | ||
42 | #include "timer-gp.h" | 44 | #include "timer-gp.h" |
43 | 45 | ||
44 | #include "hsmmc.h" | 46 | #include "hsmmc.h" |
@@ -49,6 +51,8 @@ | |||
49 | #define GPIO_HUB_NRESET 62 | 51 | #define GPIO_HUB_NRESET 62 |
50 | #define GPIO_WIFI_PMENA 43 | 52 | #define GPIO_WIFI_PMENA 43 |
51 | #define GPIO_WIFI_IRQ 53 | 53 | #define GPIO_WIFI_IRQ 53 |
54 | #define HDMI_GPIO_HPD 60 /* Hot plug pin for HDMI */ | ||
55 | #define HDMI_GPIO_LS_OE 41 /* Level shifter for HDMI */ | ||
52 | 56 | ||
53 | /* wl127x BT, FM, GPS connectivity chip */ | 57 | /* wl127x BT, FM, GPS connectivity chip */ |
54 | static int wl1271_gpios[] = {46, -1, -1}; | 58 | static int wl1271_gpios[] = {46, -1, -1}; |
@@ -433,6 +437,17 @@ static struct i2c_board_info __initdata omap4_panda_i2c_boardinfo[] = { | |||
433 | .platform_data = &omap4_panda_twldata, | 437 | .platform_data = &omap4_panda_twldata, |
434 | }, | 438 | }, |
435 | }; | 439 | }; |
440 | |||
441 | /* | ||
442 | * Display monitor features are burnt in their EEPROM as EDID data. The EEPROM | ||
443 | * is connected as I2C slave device, and can be accessed at address 0x50 | ||
444 | */ | ||
445 | static struct i2c_board_info __initdata panda_i2c_eeprom[] = { | ||
446 | { | ||
447 | I2C_BOARD_INFO("eeprom", 0x50), | ||
448 | }, | ||
449 | }; | ||
450 | |||
436 | static int __init omap4_panda_i2c_init(void) | 451 | static int __init omap4_panda_i2c_init(void) |
437 | { | 452 | { |
438 | /* | 453 | /* |
@@ -442,7 +457,12 @@ static int __init omap4_panda_i2c_init(void) | |||
442 | omap_register_i2c_bus(1, 400, omap4_panda_i2c_boardinfo, | 457 | omap_register_i2c_bus(1, 400, omap4_panda_i2c_boardinfo, |
443 | ARRAY_SIZE(omap4_panda_i2c_boardinfo)); | 458 | ARRAY_SIZE(omap4_panda_i2c_boardinfo)); |
444 | omap_register_i2c_bus(2, 400, NULL, 0); | 459 | omap_register_i2c_bus(2, 400, NULL, 0); |
445 | omap_register_i2c_bus(3, 400, NULL, 0); | 460 | /* |
461 | * Bus 3 is attached to the DVI port where devices like the pico DLP | ||
462 | * projector don't work reliably with 400kHz | ||
463 | */ | ||
464 | omap_register_i2c_bus(3, 100, panda_i2c_eeprom, | ||
465 | ARRAY_SIZE(panda_i2c_eeprom)); | ||
446 | omap_register_i2c_bus(4, 400, NULL, 0); | 466 | omap_register_i2c_bus(4, 400, NULL, 0); |
447 | return 0; | 467 | return 0; |
448 | } | 468 | } |
@@ -462,6 +482,64 @@ static struct omap_board_mux board_mux[] __initdata = { | |||
462 | OMAP4_MUX(SDMMC5_DAT1, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), | 482 | OMAP4_MUX(SDMMC5_DAT1, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), |
463 | OMAP4_MUX(SDMMC5_DAT2, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), | 483 | OMAP4_MUX(SDMMC5_DAT2, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), |
464 | OMAP4_MUX(SDMMC5_DAT3, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), | 484 | OMAP4_MUX(SDMMC5_DAT3, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), |
485 | /* gpio 0 - TFP410 PD */ | ||
486 | OMAP4_MUX(KPD_COL1, OMAP_PIN_OUTPUT | OMAP_MUX_MODE3), | ||
487 | /* dispc2_data23 */ | ||
488 | OMAP4_MUX(USBB2_ULPITLL_STP, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
489 | /* dispc2_data22 */ | ||
490 | OMAP4_MUX(USBB2_ULPITLL_DIR, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
491 | /* dispc2_data21 */ | ||
492 | OMAP4_MUX(USBB2_ULPITLL_NXT, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
493 | /* dispc2_data20 */ | ||
494 | OMAP4_MUX(USBB2_ULPITLL_DAT0, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
495 | /* dispc2_data19 */ | ||
496 | OMAP4_MUX(USBB2_ULPITLL_DAT1, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
497 | /* dispc2_data18 */ | ||
498 | OMAP4_MUX(USBB2_ULPITLL_DAT2, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
499 | /* dispc2_data15 */ | ||
500 | OMAP4_MUX(USBB2_ULPITLL_DAT3, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
501 | /* dispc2_data14 */ | ||
502 | OMAP4_MUX(USBB2_ULPITLL_DAT4, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
503 | /* dispc2_data13 */ | ||
504 | OMAP4_MUX(USBB2_ULPITLL_DAT5, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
505 | /* dispc2_data12 */ | ||
506 | OMAP4_MUX(USBB2_ULPITLL_DAT6, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
507 | /* dispc2_data11 */ | ||
508 | OMAP4_MUX(USBB2_ULPITLL_DAT7, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
509 | /* dispc2_data10 */ | ||
510 | OMAP4_MUX(DPM_EMU3, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
511 | /* dispc2_data9 */ | ||
512 | OMAP4_MUX(DPM_EMU4, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
513 | /* dispc2_data16 */ | ||
514 | OMAP4_MUX(DPM_EMU5, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
515 | /* dispc2_data17 */ | ||
516 | OMAP4_MUX(DPM_EMU6, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
517 | /* dispc2_hsync */ | ||
518 | OMAP4_MUX(DPM_EMU7, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
519 | /* dispc2_pclk */ | ||
520 | OMAP4_MUX(DPM_EMU8, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
521 | /* dispc2_vsync */ | ||
522 | OMAP4_MUX(DPM_EMU9, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
523 | /* dispc2_de */ | ||
524 | OMAP4_MUX(DPM_EMU10, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
525 | /* dispc2_data8 */ | ||
526 | OMAP4_MUX(DPM_EMU11, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
527 | /* dispc2_data7 */ | ||
528 | OMAP4_MUX(DPM_EMU12, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
529 | /* dispc2_data6 */ | ||
530 | OMAP4_MUX(DPM_EMU13, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
531 | /* dispc2_data5 */ | ||
532 | OMAP4_MUX(DPM_EMU14, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
533 | /* dispc2_data4 */ | ||
534 | OMAP4_MUX(DPM_EMU15, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
535 | /* dispc2_data3 */ | ||
536 | OMAP4_MUX(DPM_EMU16, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
537 | /* dispc2_data2 */ | ||
538 | OMAP4_MUX(DPM_EMU17, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
539 | /* dispc2_data1 */ | ||
540 | OMAP4_MUX(DPM_EMU18, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
541 | /* dispc2_data0 */ | ||
542 | OMAP4_MUX(DPM_EMU19, OMAP_PIN_OUTPUT | OMAP_MUX_MODE5), | ||
465 | { .reg_offset = OMAP_MUX_TERMINATOR }, | 543 | { .reg_offset = OMAP_MUX_TERMINATOR }, |
466 | }; | 544 | }; |
467 | 545 | ||
@@ -535,6 +613,128 @@ static inline void board_serial_init(void) | |||
535 | } | 613 | } |
536 | #endif | 614 | #endif |
537 | 615 | ||
616 | /* Display DVI */ | ||
617 | #define PANDA_DVI_TFP410_POWER_DOWN_GPIO 0 | ||
618 | |||
619 | static int omap4_panda_enable_dvi(struct omap_dss_device *dssdev) | ||
620 | { | ||
621 | gpio_set_value(dssdev->reset_gpio, 1); | ||
622 | return 0; | ||
623 | } | ||
624 | |||
625 | static void omap4_panda_disable_dvi(struct omap_dss_device *dssdev) | ||
626 | { | ||
627 | gpio_set_value(dssdev->reset_gpio, 0); | ||
628 | } | ||
629 | |||
630 | /* Using generic display panel */ | ||
631 | static struct panel_generic_dpi_data omap4_dvi_panel = { | ||
632 | .name = "generic", | ||
633 | .platform_enable = omap4_panda_enable_dvi, | ||
634 | .platform_disable = omap4_panda_disable_dvi, | ||
635 | }; | ||
636 | |||
637 | struct omap_dss_device omap4_panda_dvi_device = { | ||
638 | .type = OMAP_DISPLAY_TYPE_DPI, | ||
639 | .name = "dvi", | ||
640 | .driver_name = "generic_dpi_panel", | ||
641 | .data = &omap4_dvi_panel, | ||
642 | .phy.dpi.data_lines = 24, | ||
643 | .reset_gpio = PANDA_DVI_TFP410_POWER_DOWN_GPIO, | ||
644 | .channel = OMAP_DSS_CHANNEL_LCD2, | ||
645 | }; | ||
646 | |||
647 | int __init omap4_panda_dvi_init(void) | ||
648 | { | ||
649 | int r; | ||
650 | |||
651 | /* Requesting TFP410 DVI GPIO and disabling it, at bootup */ | ||
652 | r = gpio_request_one(omap4_panda_dvi_device.reset_gpio, | ||
653 | GPIOF_OUT_INIT_LOW, "DVI PD"); | ||
654 | if (r) | ||
655 | pr_err("Failed to get DVI powerdown GPIO\n"); | ||
656 | |||
657 | return r; | ||
658 | } | ||
659 | |||
660 | |||
661 | static void omap4_panda_hdmi_mux_init(void) | ||
662 | { | ||
663 | /* PAD0_HDMI_HPD_PAD1_HDMI_CEC */ | ||
664 | omap_mux_init_signal("hdmi_hpd", | ||
665 | OMAP_PIN_INPUT_PULLUP); | ||
666 | omap_mux_init_signal("hdmi_cec", | ||
667 | OMAP_PIN_INPUT_PULLUP); | ||
668 | /* PAD0_HDMI_DDC_SCL_PAD1_HDMI_DDC_SDA */ | ||
669 | omap_mux_init_signal("hdmi_ddc_scl", | ||
670 | OMAP_PIN_INPUT_PULLUP); | ||
671 | omap_mux_init_signal("hdmi_ddc_sda", | ||
672 | OMAP_PIN_INPUT_PULLUP); | ||
673 | } | ||
674 | |||
675 | static int omap4_panda_panel_enable_hdmi(struct omap_dss_device *dssdev) | ||
676 | { | ||
677 | int status; | ||
678 | |||
679 | status = gpio_request_one(HDMI_GPIO_HPD, GPIOF_OUT_INIT_HIGH, | ||
680 | "hdmi_gpio_hpd"); | ||
681 | if (status) { | ||
682 | pr_err("Cannot request GPIO %d\n", HDMI_GPIO_HPD); | ||
683 | return status; | ||
684 | } | ||
685 | status = gpio_request_one(HDMI_GPIO_LS_OE, GPIOF_OUT_INIT_HIGH, | ||
686 | "hdmi_gpio_ls_oe"); | ||
687 | if (status) { | ||
688 | pr_err("Cannot request GPIO %d\n", HDMI_GPIO_LS_OE); | ||
689 | goto error1; | ||
690 | } | ||
691 | |||
692 | return 0; | ||
693 | |||
694 | error1: | ||
695 | gpio_free(HDMI_GPIO_HPD); | ||
696 | |||
697 | return status; | ||
698 | } | ||
699 | |||
700 | static void omap4_panda_panel_disable_hdmi(struct omap_dss_device *dssdev) | ||
701 | { | ||
702 | gpio_free(HDMI_GPIO_LS_OE); | ||
703 | gpio_free(HDMI_GPIO_HPD); | ||
704 | } | ||
705 | |||
706 | static struct omap_dss_device omap4_panda_hdmi_device = { | ||
707 | .name = "hdmi", | ||
708 | .driver_name = "hdmi_panel", | ||
709 | .type = OMAP_DISPLAY_TYPE_HDMI, | ||
710 | .platform_enable = omap4_panda_panel_enable_hdmi, | ||
711 | .platform_disable = omap4_panda_panel_disable_hdmi, | ||
712 | .channel = OMAP_DSS_CHANNEL_DIGIT, | ||
713 | }; | ||
714 | |||
715 | static struct omap_dss_device *omap4_panda_dss_devices[] = { | ||
716 | &omap4_panda_dvi_device, | ||
717 | &omap4_panda_hdmi_device, | ||
718 | }; | ||
719 | |||
720 | static struct omap_dss_board_info omap4_panda_dss_data = { | ||
721 | .num_devices = ARRAY_SIZE(omap4_panda_dss_devices), | ||
722 | .devices = omap4_panda_dss_devices, | ||
723 | .default_device = &omap4_panda_dvi_device, | ||
724 | }; | ||
725 | |||
726 | void omap4_panda_display_init(void) | ||
727 | { | ||
728 | int r; | ||
729 | |||
730 | r = omap4_panda_dvi_init(); | ||
731 | if (r) | ||
732 | pr_err("error initializing panda DVI\n"); | ||
733 | |||
734 | omap4_panda_hdmi_mux_init(); | ||
735 | omap_display_init(&omap4_panda_dss_data); | ||
736 | } | ||
737 | |||
538 | static void __init omap4_panda_init(void) | 738 | static void __init omap4_panda_init(void) |
539 | { | 739 | { |
540 | int package = OMAP_PACKAGE_CBS; | 740 | int package = OMAP_PACKAGE_CBS; |
@@ -553,6 +753,7 @@ static void __init omap4_panda_init(void) | |||
553 | omap4_twl6030_hsmmc_init(mmc); | 753 | omap4_twl6030_hsmmc_init(mmc); |
554 | omap4_ehci_init(); | 754 | omap4_ehci_init(); |
555 | usb_musb_init(&musb_board_data); | 755 | usb_musb_init(&musb_board_data); |
756 | omap4_panda_display_init(); | ||
556 | } | 757 | } |
557 | 758 | ||
558 | static void __init omap4_panda_map_io(void) | 759 | static void __init omap4_panda_map_io(void) |
diff --git a/arch/arm/mach-omap2/board-overo.c b/arch/arm/mach-omap2/board-overo.c index d0961945c65a..59ca33326b8c 100644 --- a/arch/arm/mach-omap2/board-overo.c +++ b/arch/arm/mach-omap2/board-overo.c | |||
@@ -28,6 +28,8 @@ | |||
28 | #include <linux/platform_device.h> | 28 | #include <linux/platform_device.h> |
29 | #include <linux/i2c/twl.h> | 29 | #include <linux/i2c/twl.h> |
30 | #include <linux/regulator/machine.h> | 30 | #include <linux/regulator/machine.h> |
31 | #include <linux/regulator/fixed.h> | ||
32 | #include <linux/spi/spi.h> | ||
31 | 33 | ||
32 | #include <linux/mtd/mtd.h> | 34 | #include <linux/mtd/mtd.h> |
33 | #include <linux/mtd/nand.h> | 35 | #include <linux/mtd/nand.h> |
@@ -41,10 +43,14 @@ | |||
41 | 43 | ||
42 | #include <plat/board.h> | 44 | #include <plat/board.h> |
43 | #include <plat/common.h> | 45 | #include <plat/common.h> |
46 | #include <plat/display.h> | ||
47 | #include <plat/panel-generic-dpi.h> | ||
44 | #include <mach/gpio.h> | 48 | #include <mach/gpio.h> |
45 | #include <plat/gpmc.h> | 49 | #include <plat/gpmc.h> |
46 | #include <mach/hardware.h> | 50 | #include <mach/hardware.h> |
47 | #include <plat/nand.h> | 51 | #include <plat/nand.h> |
52 | #include <plat/mcspi.h> | ||
53 | #include <plat/mux.h> | ||
48 | #include <plat/usb.h> | 54 | #include <plat/usb.h> |
49 | 55 | ||
50 | #include "mux.h" | 56 | #include "mux.h" |
@@ -68,8 +74,6 @@ | |||
68 | #if defined(CONFIG_TOUCHSCREEN_ADS7846) || \ | 74 | #if defined(CONFIG_TOUCHSCREEN_ADS7846) || \ |
69 | defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE) | 75 | defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE) |
70 | 76 | ||
71 | #include <plat/mcspi.h> | ||
72 | #include <linux/spi/spi.h> | ||
73 | #include <linux/spi/ads7846.h> | 77 | #include <linux/spi/ads7846.h> |
74 | 78 | ||
75 | static struct omap2_mcspi_device_config ads7846_mcspi_config = { | 79 | static struct omap2_mcspi_device_config ads7846_mcspi_config = { |
@@ -94,16 +98,32 @@ static struct ads7846_platform_data ads7846_config = { | |||
94 | .keep_vref_on = 1, | 98 | .keep_vref_on = 1, |
95 | }; | 99 | }; |
96 | 100 | ||
97 | static struct spi_board_info overo_spi_board_info[] __initdata = { | 101 | /* fixed regulator for ads7846 */ |
98 | { | 102 | static struct regulator_consumer_supply ads7846_supply = |
99 | .modalias = "ads7846", | 103 | REGULATOR_SUPPLY("vcc", "spi1.0"); |
100 | .bus_num = 1, | 104 | |
101 | .chip_select = 0, | 105 | static struct regulator_init_data vads7846_regulator = { |
102 | .max_speed_hz = 1500000, | 106 | .constraints = { |
103 | .controller_data = &ads7846_mcspi_config, | 107 | .valid_ops_mask = REGULATOR_CHANGE_STATUS, |
104 | .irq = OMAP_GPIO_IRQ(OVERO_GPIO_PENDOWN), | 108 | }, |
105 | .platform_data = &ads7846_config, | 109 | .num_consumer_supplies = 1, |
106 | } | 110 | .consumer_supplies = &ads7846_supply, |
111 | }; | ||
112 | |||
113 | static struct fixed_voltage_config vads7846 = { | ||
114 | .supply_name = "vads7846", | ||
115 | .microvolts = 3300000, /* 3.3V */ | ||
116 | .gpio = -EINVAL, | ||
117 | .startup_delay = 0, | ||
118 | .init_data = &vads7846_regulator, | ||
119 | }; | ||
120 | |||
121 | static struct platform_device vads7846_device = { | ||
122 | .name = "reg-fixed-voltage", | ||
123 | .id = 1, | ||
124 | .dev = { | ||
125 | .platform_data = &vads7846, | ||
126 | }, | ||
107 | }; | 127 | }; |
108 | 128 | ||
109 | static void __init overo_ads7846_init(void) | 129 | static void __init overo_ads7846_init(void) |
@@ -116,8 +136,7 @@ static void __init overo_ads7846_init(void) | |||
116 | return; | 136 | return; |
117 | } | 137 | } |
118 | 138 | ||
119 | spi_register_board_info(overo_spi_board_info, | 139 | platform_device_register(&vads7846_device); |
120 | ARRAY_SIZE(overo_spi_board_info)); | ||
121 | } | 140 | } |
122 | 141 | ||
123 | #else | 142 | #else |
@@ -233,6 +252,137 @@ static inline void __init overo_init_smsc911x(void) | |||
233 | static inline void __init overo_init_smsc911x(void) { return; } | 252 | static inline void __init overo_init_smsc911x(void) { return; } |
234 | #endif | 253 | #endif |
235 | 254 | ||
255 | /* DSS */ | ||
256 | static int lcd_enabled; | ||
257 | static int dvi_enabled; | ||
258 | |||
259 | #define OVERO_GPIO_LCD_EN 144 | ||
260 | #define OVERO_GPIO_LCD_BL 145 | ||
261 | |||
262 | static void __init overo_display_init(void) | ||
263 | { | ||
264 | if ((gpio_request(OVERO_GPIO_LCD_EN, "OVERO_GPIO_LCD_EN") == 0) && | ||
265 | (gpio_direction_output(OVERO_GPIO_LCD_EN, 1) == 0)) | ||
266 | gpio_export(OVERO_GPIO_LCD_EN, 0); | ||
267 | else | ||
268 | printk(KERN_ERR "could not obtain gpio for " | ||
269 | "OVERO_GPIO_LCD_EN\n"); | ||
270 | |||
271 | if ((gpio_request(OVERO_GPIO_LCD_BL, "OVERO_GPIO_LCD_BL") == 0) && | ||
272 | (gpio_direction_output(OVERO_GPIO_LCD_BL, 1) == 0)) | ||
273 | gpio_export(OVERO_GPIO_LCD_BL, 0); | ||
274 | else | ||
275 | printk(KERN_ERR "could not obtain gpio for " | ||
276 | "OVERO_GPIO_LCD_BL\n"); | ||
277 | } | ||
278 | |||
279 | static int overo_panel_enable_dvi(struct omap_dss_device *dssdev) | ||
280 | { | ||
281 | if (lcd_enabled) { | ||
282 | printk(KERN_ERR "cannot enable DVI, LCD is enabled\n"); | ||
283 | return -EINVAL; | ||
284 | } | ||
285 | dvi_enabled = 1; | ||
286 | |||
287 | return 0; | ||
288 | } | ||
289 | |||
290 | static void overo_panel_disable_dvi(struct omap_dss_device *dssdev) | ||
291 | { | ||
292 | dvi_enabled = 0; | ||
293 | } | ||
294 | |||
295 | static struct panel_generic_dpi_data dvi_panel = { | ||
296 | .name = "generic", | ||
297 | .platform_enable = overo_panel_enable_dvi, | ||
298 | .platform_disable = overo_panel_disable_dvi, | ||
299 | }; | ||
300 | |||
301 | static struct omap_dss_device overo_dvi_device = { | ||
302 | .name = "dvi", | ||
303 | .type = OMAP_DISPLAY_TYPE_DPI, | ||
304 | .driver_name = "generic_dpi_panel", | ||
305 | .data = &dvi_panel, | ||
306 | .phy.dpi.data_lines = 24, | ||
307 | }; | ||
308 | |||
309 | static struct omap_dss_device overo_tv_device = { | ||
310 | .name = "tv", | ||
311 | .driver_name = "venc", | ||
312 | .type = OMAP_DISPLAY_TYPE_VENC, | ||
313 | .phy.venc.type = OMAP_DSS_VENC_TYPE_SVIDEO, | ||
314 | }; | ||
315 | |||
316 | static int overo_panel_enable_lcd(struct omap_dss_device *dssdev) | ||
317 | { | ||
318 | if (dvi_enabled) { | ||
319 | printk(KERN_ERR "cannot enable LCD, DVI is enabled\n"); | ||
320 | return -EINVAL; | ||
321 | } | ||
322 | |||
323 | gpio_set_value(OVERO_GPIO_LCD_EN, 1); | ||
324 | gpio_set_value(OVERO_GPIO_LCD_BL, 1); | ||
325 | lcd_enabled = 1; | ||
326 | return 0; | ||
327 | } | ||
328 | |||
329 | static void overo_panel_disable_lcd(struct omap_dss_device *dssdev) | ||
330 | { | ||
331 | gpio_set_value(OVERO_GPIO_LCD_EN, 0); | ||
332 | gpio_set_value(OVERO_GPIO_LCD_BL, 0); | ||
333 | lcd_enabled = 0; | ||
334 | } | ||
335 | |||
336 | static struct panel_generic_dpi_data lcd43_panel = { | ||
337 | .name = "samsung_lte430wq_f0c", | ||
338 | .platform_enable = overo_panel_enable_lcd, | ||
339 | .platform_disable = overo_panel_disable_lcd, | ||
340 | }; | ||
341 | |||
342 | static struct omap_dss_device overo_lcd43_device = { | ||
343 | .name = "lcd43", | ||
344 | .type = OMAP_DISPLAY_TYPE_DPI, | ||
345 | .driver_name = "generic_dpi_panel", | ||
346 | .data = &lcd43_panel, | ||
347 | .phy.dpi.data_lines = 24, | ||
348 | }; | ||
349 | |||
350 | #if defined(CONFIG_PANEL_LGPHILIPS_LB035Q02) || \ | ||
351 | defined(CONFIG_PANEL_LGPHILIPS_LB035Q02_MODULE) | ||
352 | static struct omap_dss_device overo_lcd35_device = { | ||
353 | .type = OMAP_DISPLAY_TYPE_DPI, | ||
354 | .name = "lcd35", | ||
355 | .driver_name = "lgphilips_lb035q02_panel", | ||
356 | .phy.dpi.data_lines = 24, | ||
357 | .platform_enable = overo_panel_enable_lcd, | ||
358 | .platform_disable = overo_panel_disable_lcd, | ||
359 | }; | ||
360 | #endif | ||
361 | |||
362 | static struct omap_dss_device *overo_dss_devices[] = { | ||
363 | &overo_dvi_device, | ||
364 | &overo_tv_device, | ||
365 | #if defined(CONFIG_PANEL_LGPHILIPS_LB035Q02) || \ | ||
366 | defined(CONFIG_PANEL_LGPHILIPS_LB035Q02_MODULE) | ||
367 | &overo_lcd35_device, | ||
368 | #endif | ||
369 | &overo_lcd43_device, | ||
370 | }; | ||
371 | |||
372 | static struct omap_dss_board_info overo_dss_data = { | ||
373 | .num_devices = ARRAY_SIZE(overo_dss_devices), | ||
374 | .devices = overo_dss_devices, | ||
375 | .default_device = &overo_dvi_device, | ||
376 | }; | ||
377 | |||
378 | static struct regulator_consumer_supply overo_vdda_dac_supply = | ||
379 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); | ||
380 | |||
381 | static struct regulator_consumer_supply overo_vdds_dsi_supply[] = { | ||
382 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), | ||
383 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
384 | }; | ||
385 | |||
236 | static struct mtd_partition overo_nand_partitions[] = { | 386 | static struct mtd_partition overo_nand_partitions[] = { |
237 | { | 387 | { |
238 | .name = "xloader", | 388 | .name = "xloader", |
@@ -323,6 +473,93 @@ static struct regulator_consumer_supply overo_vmmc1_supply = { | |||
323 | .supply = "vmmc", | 473 | .supply = "vmmc", |
324 | }; | 474 | }; |
325 | 475 | ||
476 | #if defined(CONFIG_LEDS_GPIO) || defined(CONFIG_LEDS_GPIO_MODULE) | ||
477 | #include <linux/leds.h> | ||
478 | |||
479 | static struct gpio_led gpio_leds[] = { | ||
480 | { | ||
481 | .name = "overo:red:gpio21", | ||
482 | .default_trigger = "heartbeat", | ||
483 | .gpio = 21, | ||
484 | .active_low = true, | ||
485 | }, | ||
486 | { | ||
487 | .name = "overo:blue:gpio22", | ||
488 | .default_trigger = "none", | ||
489 | .gpio = 22, | ||
490 | .active_low = true, | ||
491 | }, | ||
492 | { | ||
493 | .name = "overo:blue:COM", | ||
494 | .default_trigger = "mmc0", | ||
495 | .gpio = -EINVAL, /* gets replaced */ | ||
496 | .active_low = true, | ||
497 | }, | ||
498 | }; | ||
499 | |||
500 | static struct gpio_led_platform_data gpio_leds_pdata = { | ||
501 | .leds = gpio_leds, | ||
502 | .num_leds = ARRAY_SIZE(gpio_leds), | ||
503 | }; | ||
504 | |||
505 | static struct platform_device gpio_leds_device = { | ||
506 | .name = "leds-gpio", | ||
507 | .id = -1, | ||
508 | .dev = { | ||
509 | .platform_data = &gpio_leds_pdata, | ||
510 | }, | ||
511 | }; | ||
512 | |||
513 | static void __init overo_init_led(void) | ||
514 | { | ||
515 | platform_device_register(&gpio_leds_device); | ||
516 | } | ||
517 | |||
518 | #else | ||
519 | static inline void __init overo_init_led(void) { return; } | ||
520 | #endif | ||
521 | |||
522 | #if defined(CONFIG_KEYBOARD_GPIO) || defined(CONFIG_KEYBOARD_GPIO_MODULE) | ||
523 | #include <linux/input.h> | ||
524 | #include <linux/gpio_keys.h> | ||
525 | |||
526 | static struct gpio_keys_button gpio_buttons[] = { | ||
527 | { | ||
528 | .code = BTN_0, | ||
529 | .gpio = 23, | ||
530 | .desc = "button0", | ||
531 | .wakeup = 1, | ||
532 | }, | ||
533 | { | ||
534 | .code = BTN_1, | ||
535 | .gpio = 14, | ||
536 | .desc = "button1", | ||
537 | .wakeup = 1, | ||
538 | }, | ||
539 | }; | ||
540 | |||
541 | static struct gpio_keys_platform_data gpio_keys_pdata = { | ||
542 | .buttons = gpio_buttons, | ||
543 | .nbuttons = ARRAY_SIZE(gpio_buttons), | ||
544 | }; | ||
545 | |||
546 | static struct platform_device gpio_keys_device = { | ||
547 | .name = "gpio-keys", | ||
548 | .id = -1, | ||
549 | .dev = { | ||
550 | .platform_data = &gpio_keys_pdata, | ||
551 | }, | ||
552 | }; | ||
553 | |||
554 | static void __init overo_init_keys(void) | ||
555 | { | ||
556 | platform_device_register(&gpio_keys_device); | ||
557 | } | ||
558 | |||
559 | #else | ||
560 | static inline void __init overo_init_keys(void) { return; } | ||
561 | #endif | ||
562 | |||
326 | static int overo_twl_gpio_setup(struct device *dev, | 563 | static int overo_twl_gpio_setup(struct device *dev, |
327 | unsigned gpio, unsigned ngpio) | 564 | unsigned gpio, unsigned ngpio) |
328 | { | 565 | { |
@@ -330,6 +567,11 @@ static int overo_twl_gpio_setup(struct device *dev, | |||
330 | 567 | ||
331 | overo_vmmc1_supply.dev = mmc[0].dev; | 568 | overo_vmmc1_supply.dev = mmc[0].dev; |
332 | 569 | ||
570 | #if defined(CONFIG_LEDS_GPIO) || defined(CONFIG_LEDS_GPIO_MODULE) | ||
571 | /* TWL4030_GPIO_MAX + 1 == ledB, PMU_STAT (out, active low LED) */ | ||
572 | gpio_leds[2].gpio = gpio + TWL4030_GPIO_MAX + 1; | ||
573 | #endif | ||
574 | |||
333 | return 0; | 575 | return 0; |
334 | } | 576 | } |
335 | 577 | ||
@@ -337,6 +579,7 @@ static struct twl4030_gpio_platform_data overo_gpio_data = { | |||
337 | .gpio_base = OMAP_MAX_GPIO_LINES, | 579 | .gpio_base = OMAP_MAX_GPIO_LINES, |
338 | .irq_base = TWL4030_GPIO_IRQ_BASE, | 580 | .irq_base = TWL4030_GPIO_IRQ_BASE, |
339 | .irq_end = TWL4030_GPIO_IRQ_END, | 581 | .irq_end = TWL4030_GPIO_IRQ_END, |
582 | .use_leds = true, | ||
340 | .setup = overo_twl_gpio_setup, | 583 | .setup = overo_twl_gpio_setup, |
341 | }; | 584 | }; |
342 | 585 | ||
@@ -358,6 +601,35 @@ static struct regulator_init_data overo_vmmc1 = { | |||
358 | .consumer_supplies = &overo_vmmc1_supply, | 601 | .consumer_supplies = &overo_vmmc1_supply, |
359 | }; | 602 | }; |
360 | 603 | ||
604 | /* VDAC for DSS driving S-Video (8 mA unloaded, max 65 mA) */ | ||
605 | static struct regulator_init_data overo_vdac = { | ||
606 | .constraints = { | ||
607 | .min_uV = 1800000, | ||
608 | .max_uV = 1800000, | ||
609 | .valid_modes_mask = REGULATOR_MODE_NORMAL | ||
610 | | REGULATOR_MODE_STANDBY, | ||
611 | .valid_ops_mask = REGULATOR_CHANGE_MODE | ||
612 | | REGULATOR_CHANGE_STATUS, | ||
613 | }, | ||
614 | .num_consumer_supplies = 1, | ||
615 | .consumer_supplies = &overo_vdda_dac_supply, | ||
616 | }; | ||
617 | |||
618 | /* VPLL2 for digital video outputs */ | ||
619 | static struct regulator_init_data overo_vpll2 = { | ||
620 | .constraints = { | ||
621 | .name = "VDVI", | ||
622 | .min_uV = 1800000, | ||
623 | .max_uV = 1800000, | ||
624 | .valid_modes_mask = REGULATOR_MODE_NORMAL | ||
625 | | REGULATOR_MODE_STANDBY, | ||
626 | .valid_ops_mask = REGULATOR_CHANGE_MODE | ||
627 | | REGULATOR_CHANGE_STATUS, | ||
628 | }, | ||
629 | .num_consumer_supplies = ARRAY_SIZE(overo_vdds_dsi_supply), | ||
630 | .consumer_supplies = overo_vdds_dsi_supply, | ||
631 | }; | ||
632 | |||
361 | static struct twl4030_codec_audio_data overo_audio_data; | 633 | static struct twl4030_codec_audio_data overo_audio_data; |
362 | 634 | ||
363 | static struct twl4030_codec_data overo_codec_data = { | 635 | static struct twl4030_codec_data overo_codec_data = { |
@@ -365,8 +637,6 @@ static struct twl4030_codec_data overo_codec_data = { | |||
365 | .audio = &overo_audio_data, | 637 | .audio = &overo_audio_data, |
366 | }; | 638 | }; |
367 | 639 | ||
368 | /* mmc2 (WLAN) and Bluetooth don't use twl4030 regulators */ | ||
369 | |||
370 | static struct twl4030_platform_data overo_twldata = { | 640 | static struct twl4030_platform_data overo_twldata = { |
371 | .irq_base = TWL4030_IRQ_BASE, | 641 | .irq_base = TWL4030_IRQ_BASE, |
372 | .irq_end = TWL4030_IRQ_END, | 642 | .irq_end = TWL4030_IRQ_END, |
@@ -374,6 +644,8 @@ static struct twl4030_platform_data overo_twldata = { | |||
374 | .usb = &overo_usb_data, | 644 | .usb = &overo_usb_data, |
375 | .codec = &overo_codec_data, | 645 | .codec = &overo_codec_data, |
376 | .vmmc1 = &overo_vmmc1, | 646 | .vmmc1 = &overo_vmmc1, |
647 | .vdac = &overo_vdac, | ||
648 | .vpll2 = &overo_vpll2, | ||
377 | }; | 649 | }; |
378 | 650 | ||
379 | static struct i2c_board_info __initdata overo_i2c_boardinfo[] = { | 651 | static struct i2c_board_info __initdata overo_i2c_boardinfo[] = { |
@@ -394,18 +666,38 @@ static int __init overo_i2c_init(void) | |||
394 | return 0; | 666 | return 0; |
395 | } | 667 | } |
396 | 668 | ||
397 | static struct platform_device overo_lcd_device = { | 669 | static struct spi_board_info overo_spi_board_info[] __initdata = { |
398 | .name = "overo_lcd", | 670 | #if defined(CONFIG_TOUCHSCREEN_ADS7846) || \ |
399 | .id = -1, | 671 | defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE) |
400 | }; | 672 | { |
401 | 673 | .modalias = "ads7846", | |
402 | static struct omap_lcd_config overo_lcd_config __initdata = { | 674 | .bus_num = 1, |
403 | .ctrl_name = "internal", | 675 | .chip_select = 0, |
676 | .max_speed_hz = 1500000, | ||
677 | .controller_data = &ads7846_mcspi_config, | ||
678 | .irq = OMAP_GPIO_IRQ(OVERO_GPIO_PENDOWN), | ||
679 | .platform_data = &ads7846_config, | ||
680 | }, | ||
681 | #endif | ||
682 | #if defined(CONFIG_PANEL_LGPHILIPS_LB035Q02) || \ | ||
683 | defined(CONFIG_PANEL_LGPHILIPS_LB035Q02_MODULE) | ||
684 | { | ||
685 | .modalias = "lgphilips_lb035q02_panel-spi", | ||
686 | .bus_num = 1, | ||
687 | .chip_select = 1, | ||
688 | .max_speed_hz = 500000, | ||
689 | .mode = SPI_MODE_3, | ||
690 | }, | ||
691 | #endif | ||
404 | }; | 692 | }; |
405 | 693 | ||
406 | static struct omap_board_config_kernel overo_config[] __initdata = { | 694 | static int __init overo_spi_init(void) |
407 | { OMAP_TAG_LCD, &overo_lcd_config }, | 695 | { |
408 | }; | 696 | overo_ads7846_init(); |
697 | spi_register_board_info(overo_spi_board_info, | ||
698 | ARRAY_SIZE(overo_spi_board_info)); | ||
699 | return 0; | ||
700 | } | ||
409 | 701 | ||
410 | static void __init overo_init_early(void) | 702 | static void __init overo_init_early(void) |
411 | { | 703 | { |
@@ -414,15 +706,10 @@ static void __init overo_init_early(void) | |||
414 | mt46h32m32lf6_sdrc_params); | 706 | mt46h32m32lf6_sdrc_params); |
415 | } | 707 | } |
416 | 708 | ||
417 | static struct platform_device *overo_devices[] __initdata = { | ||
418 | &overo_lcd_device, | ||
419 | }; | ||
420 | |||
421 | static const struct usbhs_omap_board_data usbhs_bdata __initconst = { | 709 | static const struct usbhs_omap_board_data usbhs_bdata __initconst = { |
422 | .port_mode[0] = OMAP_USBHS_PORT_MODE_UNUSED, | 710 | .port_mode[0] = OMAP_USBHS_PORT_MODE_UNUSED, |
423 | .port_mode[1] = OMAP_EHCI_PORT_MODE_PHY, | 711 | .port_mode[1] = OMAP_EHCI_PORT_MODE_PHY, |
424 | .port_mode[2] = OMAP_USBHS_PORT_MODE_UNUSED, | 712 | .port_mode[2] = OMAP_USBHS_PORT_MODE_UNUSED, |
425 | |||
426 | .phy_reset = true, | 713 | .phy_reset = true, |
427 | .reset_gpio_port[0] = -EINVAL, | 714 | .reset_gpio_port[0] = -EINVAL, |
428 | .reset_gpio_port[1] = OVERO_GPIO_USBH_NRESET, | 715 | .reset_gpio_port[1] = OVERO_GPIO_USBH_NRESET, |
@@ -444,16 +731,18 @@ static struct omap_musb_board_data musb_board_data = { | |||
444 | static void __init overo_init(void) | 731 | static void __init overo_init(void) |
445 | { | 732 | { |
446 | omap3_mux_init(board_mux, OMAP_PACKAGE_CBB); | 733 | omap3_mux_init(board_mux, OMAP_PACKAGE_CBB); |
447 | omap_board_config = overo_config; | ||
448 | omap_board_config_size = ARRAY_SIZE(overo_config); | ||
449 | overo_i2c_init(); | 734 | overo_i2c_init(); |
450 | platform_add_devices(overo_devices, ARRAY_SIZE(overo_devices)); | 735 | omap_display_init(&overo_dss_data); |
451 | omap_serial_init(); | 736 | omap_serial_init(); |
452 | overo_flash_init(); | 737 | overo_flash_init(); |
453 | usb_musb_init(&musb_board_data); | 738 | usb_musb_init(&musb_board_data); |
454 | usbhs_init(&usbhs_bdata); | 739 | usbhs_init(&usbhs_bdata); |
740 | overo_spi_init(); | ||
455 | overo_ads7846_init(); | 741 | overo_ads7846_init(); |
456 | overo_init_smsc911x(); | 742 | overo_init_smsc911x(); |
743 | overo_display_init(); | ||
744 | overo_init_led(); | ||
745 | overo_init_keys(); | ||
457 | 746 | ||
458 | /* Ensure SDRC pins are mux'd for self-refresh */ | 747 | /* Ensure SDRC pins are mux'd for self-refresh */ |
459 | omap_mux_init_signal("sdrc_cke0", OMAP_PIN_OUTPUT); | 748 | omap_mux_init_signal("sdrc_cke0", OMAP_PIN_OUTPUT); |
diff --git a/arch/arm/mach-omap2/board-rx51-peripherals.c b/arch/arm/mach-omap2/board-rx51-peripherals.c index 5f1900c532ec..bbcb6775a6a3 100644 --- a/arch/arm/mach-omap2/board-rx51-peripherals.c +++ b/arch/arm/mach-omap2/board-rx51-peripherals.c | |||
@@ -372,7 +372,7 @@ static struct regulator_consumer_supply rx51_vaux1_consumers[] = { | |||
372 | }; | 372 | }; |
373 | 373 | ||
374 | static struct regulator_consumer_supply rx51_vdac_supply[] = { | 374 | static struct regulator_consumer_supply rx51_vdac_supply[] = { |
375 | REGULATOR_SUPPLY("vdda_dac", "omapdss"), | 375 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"), |
376 | }; | 376 | }; |
377 | 377 | ||
378 | static struct regulator_init_data rx51_vaux1 = { | 378 | static struct regulator_init_data rx51_vaux1 = { |
diff --git a/arch/arm/mach-omap2/board-zoom-peripherals.c b/arch/arm/mach-omap2/board-zoom-peripherals.c index 448ab60195d5..8dee7549fbdf 100644 --- a/arch/arm/mach-omap2/board-zoom-peripherals.c +++ b/arch/arm/mach-omap2/board-zoom-peripherals.c | |||
@@ -226,11 +226,13 @@ static struct omap2_hsmmc_info mmc[] = { | |||
226 | {} /* Terminator */ | 226 | {} /* Terminator */ |
227 | }; | 227 | }; |
228 | 228 | ||
229 | static struct regulator_consumer_supply zoom_vpll2_supply = | 229 | static struct regulator_consumer_supply zoom_vpll2_supplies[] = { |
230 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"); | 230 | REGULATOR_SUPPLY("vdds_dsi", "omapdss"), |
231 | REGULATOR_SUPPLY("vdds_dsi", "omapdss_dsi1"), | ||
232 | }; | ||
231 | 233 | ||
232 | static struct regulator_consumer_supply zoom_vdda_dac_supply = | 234 | static struct regulator_consumer_supply zoom_vdda_dac_supply = |
233 | REGULATOR_SUPPLY("vdda_dac", "omapdss"); | 235 | REGULATOR_SUPPLY("vdda_dac", "omapdss_venc"); |
234 | 236 | ||
235 | static struct regulator_init_data zoom_vpll2 = { | 237 | static struct regulator_init_data zoom_vpll2 = { |
236 | .constraints = { | 238 | .constraints = { |
@@ -241,8 +243,8 @@ static struct regulator_init_data zoom_vpll2 = { | |||
241 | .valid_ops_mask = REGULATOR_CHANGE_MODE | 243 | .valid_ops_mask = REGULATOR_CHANGE_MODE |
242 | | REGULATOR_CHANGE_STATUS, | 244 | | REGULATOR_CHANGE_STATUS, |
243 | }, | 245 | }, |
244 | .num_consumer_supplies = 1, | 246 | .num_consumer_supplies = ARRAY_SIZE(zoom_vpll2_supplies), |
245 | .consumer_supplies = &zoom_vpll2_supply, | 247 | .consumer_supplies = zoom_vpll2_supplies, |
246 | }; | 248 | }; |
247 | 249 | ||
248 | static struct regulator_init_data zoom_vdac = { | 250 | static struct regulator_init_data zoom_vdac = { |
diff --git a/arch/arm/mach-omap2/clock2420_data.c b/arch/arm/mach-omap2/clock2420_data.c index b6f65d4ac97d..2926d028b6e9 100644 --- a/arch/arm/mach-omap2/clock2420_data.c +++ b/arch/arm/mach-omap2/clock2420_data.c | |||
@@ -1804,10 +1804,10 @@ static struct omap_clk omap2420_clks[] = { | |||
1804 | CLK(NULL, "gfx_2d_fck", &gfx_2d_fck, CK_242X), | 1804 | CLK(NULL, "gfx_2d_fck", &gfx_2d_fck, CK_242X), |
1805 | CLK(NULL, "gfx_ick", &gfx_ick, CK_242X), | 1805 | CLK(NULL, "gfx_ick", &gfx_ick, CK_242X), |
1806 | /* DSS domain clocks */ | 1806 | /* DSS domain clocks */ |
1807 | CLK("omapdss", "ick", &dss_ick, CK_242X), | 1807 | CLK("omapdss_dss", "ick", &dss_ick, CK_242X), |
1808 | CLK("omapdss", "dss1_fck", &dss1_fck, CK_242X), | 1808 | CLK("omapdss_dss", "fck", &dss1_fck, CK_242X), |
1809 | CLK("omapdss", "dss2_fck", &dss2_fck, CK_242X), | 1809 | CLK("omapdss_dss", "sys_clk", &dss2_fck, CK_242X), |
1810 | CLK("omapdss", "tv_fck", &dss_54m_fck, CK_242X), | 1810 | CLK("omapdss_dss", "tv_clk", &dss_54m_fck, CK_242X), |
1811 | /* L3 domain clocks */ | 1811 | /* L3 domain clocks */ |
1812 | CLK(NULL, "core_l3_ck", &core_l3_ck, CK_242X), | 1812 | CLK(NULL, "core_l3_ck", &core_l3_ck, CK_242X), |
1813 | CLK(NULL, "ssi_fck", &ssi_ssr_sst_fck, CK_242X), | 1813 | CLK(NULL, "ssi_fck", &ssi_ssr_sst_fck, CK_242X), |
diff --git a/arch/arm/mach-omap2/clock2430_data.c b/arch/arm/mach-omap2/clock2430_data.c index bba018331a71..0c79d39e3021 100644 --- a/arch/arm/mach-omap2/clock2430_data.c +++ b/arch/arm/mach-omap2/clock2430_data.c | |||
@@ -1894,10 +1894,10 @@ static struct omap_clk omap2430_clks[] = { | |||
1894 | CLK(NULL, "mdm_ick", &mdm_ick, CK_243X), | 1894 | CLK(NULL, "mdm_ick", &mdm_ick, CK_243X), |
1895 | CLK(NULL, "mdm_osc_ck", &mdm_osc_ck, CK_243X), | 1895 | CLK(NULL, "mdm_osc_ck", &mdm_osc_ck, CK_243X), |
1896 | /* DSS domain clocks */ | 1896 | /* DSS domain clocks */ |
1897 | CLK("omapdss", "ick", &dss_ick, CK_243X), | 1897 | CLK("omapdss_dss", "ick", &dss_ick, CK_243X), |
1898 | CLK("omapdss", "dss1_fck", &dss1_fck, CK_243X), | 1898 | CLK("omapdss_dss", "fck", &dss1_fck, CK_243X), |
1899 | CLK("omapdss", "dss2_fck", &dss2_fck, CK_243X), | 1899 | CLK("omapdss_dss", "sys_clk", &dss2_fck, CK_243X), |
1900 | CLK("omapdss", "tv_fck", &dss_54m_fck, CK_243X), | 1900 | CLK("omapdss_dss", "tv_clk", &dss_54m_fck, CK_243X), |
1901 | /* L3 domain clocks */ | 1901 | /* L3 domain clocks */ |
1902 | CLK(NULL, "core_l3_ck", &core_l3_ck, CK_243X), | 1902 | CLK(NULL, "core_l3_ck", &core_l3_ck, CK_243X), |
1903 | CLK(NULL, "ssi_fck", &ssi_ssr_sst_fck, CK_243X), | 1903 | CLK(NULL, "ssi_fck", &ssi_ssr_sst_fck, CK_243X), |
diff --git a/arch/arm/mach-omap2/clock3xxx_data.c b/arch/arm/mach-omap2/clock3xxx_data.c index fcb321a64f13..75b119bd9cda 100644 --- a/arch/arm/mach-omap2/clock3xxx_data.c +++ b/arch/arm/mach-omap2/clock3xxx_data.c | |||
@@ -3356,13 +3356,13 @@ static struct omap_clk omap3xxx_clks[] = { | |||
3356 | CLK("omap_rng", "ick", &rng_ick, CK_34XX | CK_36XX), | 3356 | CLK("omap_rng", "ick", &rng_ick, CK_34XX | CK_36XX), |
3357 | CLK(NULL, "sha11_ick", &sha11_ick, CK_34XX | CK_36XX), | 3357 | CLK(NULL, "sha11_ick", &sha11_ick, CK_34XX | CK_36XX), |
3358 | CLK(NULL, "des1_ick", &des1_ick, CK_34XX | CK_36XX), | 3358 | CLK(NULL, "des1_ick", &des1_ick, CK_34XX | CK_36XX), |
3359 | CLK("omapdss", "dss1_fck", &dss1_alwon_fck_3430es1, CK_3430ES1), | 3359 | CLK("omapdss_dss", "fck", &dss1_alwon_fck_3430es1, CK_3430ES1), |
3360 | CLK("omapdss", "dss1_fck", &dss1_alwon_fck_3430es2, CK_3430ES2PLUS | CK_AM35XX | CK_36XX), | 3360 | CLK("omapdss_dss", "fck", &dss1_alwon_fck_3430es2, CK_3430ES2PLUS | CK_AM35XX | CK_36XX), |
3361 | CLK("omapdss", "tv_fck", &dss_tv_fck, CK_3XXX), | 3361 | CLK("omapdss_dss", "tv_clk", &dss_tv_fck, CK_3XXX), |
3362 | CLK("omapdss", "video_fck", &dss_96m_fck, CK_3XXX), | 3362 | CLK("omapdss_dss", "video_clk", &dss_96m_fck, CK_3XXX), |
3363 | CLK("omapdss", "dss2_fck", &dss2_alwon_fck, CK_3XXX), | 3363 | CLK("omapdss_dss", "sys_clk", &dss2_alwon_fck, CK_3XXX), |
3364 | CLK("omapdss", "ick", &dss_ick_3430es1, CK_3430ES1), | 3364 | CLK("omapdss_dss", "ick", &dss_ick_3430es1, CK_3430ES1), |
3365 | CLK("omapdss", "ick", &dss_ick_3430es2, CK_3430ES2PLUS | CK_AM35XX | CK_36XX), | 3365 | CLK("omapdss_dss", "ick", &dss_ick_3430es2, CK_3430ES2PLUS | CK_AM35XX | CK_36XX), |
3366 | CLK(NULL, "cam_mclk", &cam_mclk, CK_34XX | CK_36XX), | 3366 | CLK(NULL, "cam_mclk", &cam_mclk, CK_34XX | CK_36XX), |
3367 | CLK(NULL, "cam_ick", &cam_ick, CK_34XX | CK_36XX), | 3367 | CLK(NULL, "cam_ick", &cam_ick, CK_34XX | CK_36XX), |
3368 | CLK(NULL, "csi2_96m_fck", &csi2_96m_fck, CK_34XX | CK_36XX), | 3368 | CLK(NULL, "csi2_96m_fck", &csi2_96m_fck, CK_34XX | CK_36XX), |
diff --git a/arch/arm/mach-omap2/clock44xx_data.c b/arch/arm/mach-omap2/clock44xx_data.c index d32ed979a8da..276992d3b7fb 100644 --- a/arch/arm/mach-omap2/clock44xx_data.c +++ b/arch/arm/mach-omap2/clock44xx_data.c | |||
@@ -3114,11 +3114,16 @@ static struct omap_clk omap44xx_clks[] = { | |||
3114 | CLK(NULL, "dmic_sync_mux_ck", &dmic_sync_mux_ck, CK_443X), | 3114 | CLK(NULL, "dmic_sync_mux_ck", &dmic_sync_mux_ck, CK_443X), |
3115 | CLK(NULL, "dmic_fck", &dmic_fck, CK_443X), | 3115 | CLK(NULL, "dmic_fck", &dmic_fck, CK_443X), |
3116 | CLK(NULL, "dsp_fck", &dsp_fck, CK_443X), | 3116 | CLK(NULL, "dsp_fck", &dsp_fck, CK_443X), |
3117 | CLK(NULL, "dss_sys_clk", &dss_sys_clk, CK_443X), | 3117 | CLK("omapdss_dss", "sys_clk", &dss_sys_clk, CK_443X), |
3118 | CLK(NULL, "dss_tv_clk", &dss_tv_clk, CK_443X), | 3118 | CLK("omapdss_dss", "tv_clk", &dss_tv_clk, CK_443X), |
3119 | CLK(NULL, "dss_dss_clk", &dss_dss_clk, CK_443X), | 3119 | CLK("omapdss_dss", "dss_clk", &dss_dss_clk, CK_443X), |
3120 | CLK(NULL, "dss_48mhz_clk", &dss_48mhz_clk, CK_443X), | 3120 | CLK("omapdss_dss", "video_clk", &dss_48mhz_clk, CK_443X), |
3121 | CLK(NULL, "dss_fck", &dss_fck, CK_443X), | 3121 | CLK("omapdss_dss", "fck", &dss_fck, CK_443X), |
3122 | /* | ||
3123 | * On OMAP4, DSS ick is a dummy clock; this is needed for compatibility | ||
3124 | * with OMAP2/3. | ||
3125 | */ | ||
3126 | CLK("omapdss_dss", "ick", &dummy_ck, CK_443X), | ||
3122 | CLK(NULL, "efuse_ctrl_cust_fck", &efuse_ctrl_cust_fck, CK_443X), | 3127 | CLK(NULL, "efuse_ctrl_cust_fck", &efuse_ctrl_cust_fck, CK_443X), |
3123 | CLK(NULL, "emif1_fck", &emif1_fck, CK_443X), | 3128 | CLK(NULL, "emif1_fck", &emif1_fck, CK_443X), |
3124 | CLK(NULL, "emif2_fck", &emif2_fck, CK_443X), | 3129 | CLK(NULL, "emif2_fck", &emif2_fck, CK_443X), |
diff --git a/arch/arm/mach-omap2/display.c b/arch/arm/mach-omap2/display.c index b18db84b0349..256d23fb79ab 100644 --- a/arch/arm/mach-omap2/display.c +++ b/arch/arm/mach-omap2/display.c | |||
@@ -23,6 +23,8 @@ | |||
23 | #include <linux/err.h> | 23 | #include <linux/err.h> |
24 | 24 | ||
25 | #include <plat/display.h> | 25 | #include <plat/display.h> |
26 | #include <plat/omap_hwmod.h> | ||
27 | #include <plat/omap_device.h> | ||
26 | 28 | ||
27 | static struct platform_device omap_display_device = { | 29 | static struct platform_device omap_display_device = { |
28 | .name = "omapdss", | 30 | .name = "omapdss", |
@@ -32,9 +34,87 @@ static struct platform_device omap_display_device = { | |||
32 | }, | 34 | }, |
33 | }; | 35 | }; |
34 | 36 | ||
37 | static struct omap_device_pm_latency omap_dss_latency[] = { | ||
38 | [0] = { | ||
39 | .deactivate_func = omap_device_idle_hwmods, | ||
40 | .activate_func = omap_device_enable_hwmods, | ||
41 | .flags = OMAP_DEVICE_LATENCY_AUTO_ADJUST, | ||
42 | }, | ||
43 | }; | ||
44 | |||
45 | /* oh_core is used for getting opt-clocks */ | ||
46 | static struct omap_hwmod *oh_core; | ||
47 | |||
48 | static bool opt_clock_available(const char *clk_role) | ||
49 | { | ||
50 | int i; | ||
51 | |||
52 | for (i = 0; i < oh_core->opt_clks_cnt; i++) { | ||
53 | if (!strcmp(oh_core->opt_clks[i].role, clk_role)) | ||
54 | return true; | ||
55 | } | ||
56 | return false; | ||
57 | } | ||
58 | |||
35 | int __init omap_display_init(struct omap_dss_board_info *board_data) | 59 | int __init omap_display_init(struct omap_dss_board_info *board_data) |
36 | { | 60 | { |
37 | int r = 0; | 61 | int r = 0; |
62 | struct omap_hwmod *oh; | ||
63 | struct omap_device *od; | ||
64 | int i; | ||
65 | struct omap_display_platform_data pdata; | ||
66 | |||
67 | /* | ||
68 | * omap: valid DSS hwmod names | ||
69 | * omap2,3,4: dss_core, dss_dispc, dss_rfbi, dss_venc | ||
70 | * omap3,4: dss_dsi1 | ||
71 | * omap4: dss_dsi2, dss_hdmi | ||
72 | */ | ||
73 | char *oh_name[] = { "dss_core", "dss_dispc", "dss_rfbi", "dss_venc", | ||
74 | "dss_dsi1", "dss_dsi2", "dss_hdmi" }; | ||
75 | char *dev_name[] = { "omapdss_dss", "omapdss_dispc", "omapdss_rfbi", | ||
76 | "omapdss_venc", "omapdss_dsi1", "omapdss_dsi2", | ||
77 | "omapdss_hdmi" }; | ||
78 | int oh_count; | ||
79 | |||
80 | memset(&pdata, 0, sizeof(pdata)); | ||
81 | |||
82 | if (cpu_is_omap24xx()) | ||
83 | oh_count = ARRAY_SIZE(oh_name) - 3; | ||
84 | /* last 3 hwmod dev in oh_name are not available for omap2 */ | ||
85 | else if (cpu_is_omap44xx()) | ||
86 | oh_count = ARRAY_SIZE(oh_name); | ||
87 | else | ||
88 | oh_count = ARRAY_SIZE(oh_name) - 2; | ||
89 | /* last 2 hwmod dev in oh_name are not available for omap3 */ | ||
90 | |||
91 | /* opt_clks are always associated with dss hwmod */ | ||
92 | oh_core = omap_hwmod_lookup("dss_core"); | ||
93 | if (!oh_core) { | ||
94 | pr_err("Could not look up dss_core.\n"); | ||
95 | return -ENODEV; | ||
96 | } | ||
97 | |||
98 | pdata.board_data = board_data; | ||
99 | pdata.board_data->get_last_off_on_transaction_id = NULL; | ||
100 | pdata.opt_clock_available = opt_clock_available; | ||
101 | |||
102 | for (i = 0; i < oh_count; i++) { | ||
103 | oh = omap_hwmod_lookup(oh_name[i]); | ||
104 | if (!oh) { | ||
105 | pr_err("Could not look up %s\n", oh_name[i]); | ||
106 | return -ENODEV; | ||
107 | } | ||
108 | |||
109 | od = omap_device_build(dev_name[i], -1, oh, &pdata, | ||
110 | sizeof(struct omap_display_platform_data), | ||
111 | omap_dss_latency, | ||
112 | ARRAY_SIZE(omap_dss_latency), 0); | ||
113 | |||
114 | if (WARN((IS_ERR(od)), "Could not build omap_device for %s\n", | ||
115 | oh_name[i])) | ||
116 | return -ENODEV; | ||
117 | } | ||
38 | omap_display_device.dev.platform_data = board_data; | 118 | omap_display_device.dev.platform_data = board_data; |
39 | 119 | ||
40 | r = platform_device_register(&omap_display_device); | 120 | r = platform_device_register(&omap_display_device); |
diff --git a/arch/arm/mach-omap2/omap_hwmod_2420_data.c b/arch/arm/mach-omap2/omap_hwmod_2420_data.c index 62823467163b..8eb3ce1bbfbe 100644 --- a/arch/arm/mach-omap2/omap_hwmod_2420_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_2420_data.c | |||
@@ -1168,11 +1168,6 @@ static struct omap_hwmod_class omap2420_dss_hwmod_class = { | |||
1168 | .sysc = &omap2420_dss_sysc, | 1168 | .sysc = &omap2420_dss_sysc, |
1169 | }; | 1169 | }; |
1170 | 1170 | ||
1171 | /* dss */ | ||
1172 | static struct omap_hwmod_irq_info omap2420_dss_irqs[] = { | ||
1173 | { .irq = 25 }, | ||
1174 | }; | ||
1175 | |||
1176 | static struct omap_hwmod_dma_info omap2420_dss_sdma_chs[] = { | 1171 | static struct omap_hwmod_dma_info omap2420_dss_sdma_chs[] = { |
1177 | { .name = "dispc", .dma_req = 5 }, | 1172 | { .name = "dispc", .dma_req = 5 }, |
1178 | }; | 1173 | }; |
@@ -1221,8 +1216,6 @@ static struct omap_hwmod omap2420_dss_core_hwmod = { | |||
1221 | .name = "dss_core", | 1216 | .name = "dss_core", |
1222 | .class = &omap2420_dss_hwmod_class, | 1217 | .class = &omap2420_dss_hwmod_class, |
1223 | .main_clk = "dss1_fck", /* instead of dss_fck */ | 1218 | .main_clk = "dss1_fck", /* instead of dss_fck */ |
1224 | .mpu_irqs = omap2420_dss_irqs, | ||
1225 | .mpu_irqs_cnt = ARRAY_SIZE(omap2420_dss_irqs), | ||
1226 | .sdma_reqs = omap2420_dss_sdma_chs, | 1219 | .sdma_reqs = omap2420_dss_sdma_chs, |
1227 | .sdma_reqs_cnt = ARRAY_SIZE(omap2420_dss_sdma_chs), | 1220 | .sdma_reqs_cnt = ARRAY_SIZE(omap2420_dss_sdma_chs), |
1228 | .prcm = { | 1221 | .prcm = { |
@@ -1265,6 +1258,10 @@ static struct omap_hwmod_class omap2420_dispc_hwmod_class = { | |||
1265 | .sysc = &omap2420_dispc_sysc, | 1258 | .sysc = &omap2420_dispc_sysc, |
1266 | }; | 1259 | }; |
1267 | 1260 | ||
1261 | static struct omap_hwmod_irq_info omap2420_dispc_irqs[] = { | ||
1262 | { .irq = 25 }, | ||
1263 | }; | ||
1264 | |||
1268 | static struct omap_hwmod_addr_space omap2420_dss_dispc_addrs[] = { | 1265 | static struct omap_hwmod_addr_space omap2420_dss_dispc_addrs[] = { |
1269 | { | 1266 | { |
1270 | .pa_start = 0x48050400, | 1267 | .pa_start = 0x48050400, |
@@ -1297,6 +1294,8 @@ static struct omap_hwmod_ocp_if *omap2420_dss_dispc_slaves[] = { | |||
1297 | static struct omap_hwmod omap2420_dss_dispc_hwmod = { | 1294 | static struct omap_hwmod omap2420_dss_dispc_hwmod = { |
1298 | .name = "dss_dispc", | 1295 | .name = "dss_dispc", |
1299 | .class = &omap2420_dispc_hwmod_class, | 1296 | .class = &omap2420_dispc_hwmod_class, |
1297 | .mpu_irqs = omap2420_dispc_irqs, | ||
1298 | .mpu_irqs_cnt = ARRAY_SIZE(omap2420_dispc_irqs), | ||
1300 | .main_clk = "dss1_fck", | 1299 | .main_clk = "dss1_fck", |
1301 | .prcm = { | 1300 | .prcm = { |
1302 | .omap2 = { | 1301 | .omap2 = { |
diff --git a/arch/arm/mach-omap2/omap_hwmod_2430_data.c b/arch/arm/mach-omap2/omap_hwmod_2430_data.c index 0fdf2cabfb12..a860fb5024c2 100644 --- a/arch/arm/mach-omap2/omap_hwmod_2430_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_2430_data.c | |||
@@ -1268,10 +1268,6 @@ static struct omap_hwmod_class omap2430_dss_hwmod_class = { | |||
1268 | .sysc = &omap2430_dss_sysc, | 1268 | .sysc = &omap2430_dss_sysc, |
1269 | }; | 1269 | }; |
1270 | 1270 | ||
1271 | /* dss */ | ||
1272 | static struct omap_hwmod_irq_info omap2430_dss_irqs[] = { | ||
1273 | { .irq = 25 }, | ||
1274 | }; | ||
1275 | static struct omap_hwmod_dma_info omap2430_dss_sdma_chs[] = { | 1271 | static struct omap_hwmod_dma_info omap2430_dss_sdma_chs[] = { |
1276 | { .name = "dispc", .dma_req = 5 }, | 1272 | { .name = "dispc", .dma_req = 5 }, |
1277 | }; | 1273 | }; |
@@ -1314,8 +1310,6 @@ static struct omap_hwmod omap2430_dss_core_hwmod = { | |||
1314 | .name = "dss_core", | 1310 | .name = "dss_core", |
1315 | .class = &omap2430_dss_hwmod_class, | 1311 | .class = &omap2430_dss_hwmod_class, |
1316 | .main_clk = "dss1_fck", /* instead of dss_fck */ | 1312 | .main_clk = "dss1_fck", /* instead of dss_fck */ |
1317 | .mpu_irqs = omap2430_dss_irqs, | ||
1318 | .mpu_irqs_cnt = ARRAY_SIZE(omap2430_dss_irqs), | ||
1319 | .sdma_reqs = omap2430_dss_sdma_chs, | 1313 | .sdma_reqs = omap2430_dss_sdma_chs, |
1320 | .sdma_reqs_cnt = ARRAY_SIZE(omap2430_dss_sdma_chs), | 1314 | .sdma_reqs_cnt = ARRAY_SIZE(omap2430_dss_sdma_chs), |
1321 | .prcm = { | 1315 | .prcm = { |
@@ -1358,6 +1352,10 @@ static struct omap_hwmod_class omap2430_dispc_hwmod_class = { | |||
1358 | .sysc = &omap2430_dispc_sysc, | 1352 | .sysc = &omap2430_dispc_sysc, |
1359 | }; | 1353 | }; |
1360 | 1354 | ||
1355 | static struct omap_hwmod_irq_info omap2430_dispc_irqs[] = { | ||
1356 | { .irq = 25 }, | ||
1357 | }; | ||
1358 | |||
1361 | static struct omap_hwmod_addr_space omap2430_dss_dispc_addrs[] = { | 1359 | static struct omap_hwmod_addr_space omap2430_dss_dispc_addrs[] = { |
1362 | { | 1360 | { |
1363 | .pa_start = 0x48050400, | 1361 | .pa_start = 0x48050400, |
@@ -1384,6 +1382,8 @@ static struct omap_hwmod_ocp_if *omap2430_dss_dispc_slaves[] = { | |||
1384 | static struct omap_hwmod omap2430_dss_dispc_hwmod = { | 1382 | static struct omap_hwmod omap2430_dss_dispc_hwmod = { |
1385 | .name = "dss_dispc", | 1383 | .name = "dss_dispc", |
1386 | .class = &omap2430_dispc_hwmod_class, | 1384 | .class = &omap2430_dispc_hwmod_class, |
1385 | .mpu_irqs = omap2430_dispc_irqs, | ||
1386 | .mpu_irqs_cnt = ARRAY_SIZE(omap2430_dispc_irqs), | ||
1387 | .main_clk = "dss1_fck", | 1387 | .main_clk = "dss1_fck", |
1388 | .prcm = { | 1388 | .prcm = { |
1389 | .omap2 = { | 1389 | .omap2 = { |
diff --git a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c index c819c306693a..b98e2dfcba28 100644 --- a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c | |||
@@ -1480,11 +1480,6 @@ static struct omap_hwmod_class omap3xxx_dss_hwmod_class = { | |||
1480 | .sysc = &omap3xxx_dss_sysc, | 1480 | .sysc = &omap3xxx_dss_sysc, |
1481 | }; | 1481 | }; |
1482 | 1482 | ||
1483 | /* dss */ | ||
1484 | static struct omap_hwmod_irq_info omap3xxx_dss_irqs[] = { | ||
1485 | { .irq = 25 }, | ||
1486 | }; | ||
1487 | |||
1488 | static struct omap_hwmod_dma_info omap3xxx_dss_sdma_chs[] = { | 1483 | static struct omap_hwmod_dma_info omap3xxx_dss_sdma_chs[] = { |
1489 | { .name = "dispc", .dma_req = 5 }, | 1484 | { .name = "dispc", .dma_req = 5 }, |
1490 | { .name = "dsi1", .dma_req = 74 }, | 1485 | { .name = "dsi1", .dma_req = 74 }, |
@@ -1548,7 +1543,7 @@ static struct omap_hwmod_ocp_if *omap3xxx_dss_slaves[] = { | |||
1548 | 1543 | ||
1549 | static struct omap_hwmod_opt_clk dss_opt_clks[] = { | 1544 | static struct omap_hwmod_opt_clk dss_opt_clks[] = { |
1550 | { .role = "tv_clk", .clk = "dss_tv_fck" }, | 1545 | { .role = "tv_clk", .clk = "dss_tv_fck" }, |
1551 | { .role = "dssclk", .clk = "dss_96m_fck" }, | 1546 | { .role = "video_clk", .clk = "dss_96m_fck" }, |
1552 | { .role = "sys_clk", .clk = "dss2_alwon_fck" }, | 1547 | { .role = "sys_clk", .clk = "dss2_alwon_fck" }, |
1553 | }; | 1548 | }; |
1554 | 1549 | ||
@@ -1556,8 +1551,6 @@ static struct omap_hwmod omap3430es1_dss_core_hwmod = { | |||
1556 | .name = "dss_core", | 1551 | .name = "dss_core", |
1557 | .class = &omap3xxx_dss_hwmod_class, | 1552 | .class = &omap3xxx_dss_hwmod_class, |
1558 | .main_clk = "dss1_alwon_fck", /* instead of dss_fck */ | 1553 | .main_clk = "dss1_alwon_fck", /* instead of dss_fck */ |
1559 | .mpu_irqs = omap3xxx_dss_irqs, | ||
1560 | .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dss_irqs), | ||
1561 | .sdma_reqs = omap3xxx_dss_sdma_chs, | 1554 | .sdma_reqs = omap3xxx_dss_sdma_chs, |
1562 | .sdma_reqs_cnt = ARRAY_SIZE(omap3xxx_dss_sdma_chs), | 1555 | .sdma_reqs_cnt = ARRAY_SIZE(omap3xxx_dss_sdma_chs), |
1563 | 1556 | ||
@@ -1584,8 +1577,6 @@ static struct omap_hwmod omap3xxx_dss_core_hwmod = { | |||
1584 | .name = "dss_core", | 1577 | .name = "dss_core", |
1585 | .class = &omap3xxx_dss_hwmod_class, | 1578 | .class = &omap3xxx_dss_hwmod_class, |
1586 | .main_clk = "dss1_alwon_fck", /* instead of dss_fck */ | 1579 | .main_clk = "dss1_alwon_fck", /* instead of dss_fck */ |
1587 | .mpu_irqs = omap3xxx_dss_irqs, | ||
1588 | .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dss_irqs), | ||
1589 | .sdma_reqs = omap3xxx_dss_sdma_chs, | 1580 | .sdma_reqs = omap3xxx_dss_sdma_chs, |
1590 | .sdma_reqs_cnt = ARRAY_SIZE(omap3xxx_dss_sdma_chs), | 1581 | .sdma_reqs_cnt = ARRAY_SIZE(omap3xxx_dss_sdma_chs), |
1591 | 1582 | ||
@@ -1631,6 +1622,10 @@ static struct omap_hwmod_class omap3xxx_dispc_hwmod_class = { | |||
1631 | .sysc = &omap3xxx_dispc_sysc, | 1622 | .sysc = &omap3xxx_dispc_sysc, |
1632 | }; | 1623 | }; |
1633 | 1624 | ||
1625 | static struct omap_hwmod_irq_info omap3xxx_dispc_irqs[] = { | ||
1626 | { .irq = 25 }, | ||
1627 | }; | ||
1628 | |||
1634 | static struct omap_hwmod_addr_space omap3xxx_dss_dispc_addrs[] = { | 1629 | static struct omap_hwmod_addr_space omap3xxx_dss_dispc_addrs[] = { |
1635 | { | 1630 | { |
1636 | .pa_start = 0x48050400, | 1631 | .pa_start = 0x48050400, |
@@ -1664,6 +1659,8 @@ static struct omap_hwmod_ocp_if *omap3xxx_dss_dispc_slaves[] = { | |||
1664 | static struct omap_hwmod omap3xxx_dss_dispc_hwmod = { | 1659 | static struct omap_hwmod omap3xxx_dss_dispc_hwmod = { |
1665 | .name = "dss_dispc", | 1660 | .name = "dss_dispc", |
1666 | .class = &omap3xxx_dispc_hwmod_class, | 1661 | .class = &omap3xxx_dispc_hwmod_class, |
1662 | .mpu_irqs = omap3xxx_dispc_irqs, | ||
1663 | .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dispc_irqs), | ||
1667 | .main_clk = "dss1_alwon_fck", | 1664 | .main_clk = "dss1_alwon_fck", |
1668 | .prcm = { | 1665 | .prcm = { |
1669 | .omap2 = { | 1666 | .omap2 = { |
@@ -1689,6 +1686,10 @@ static struct omap_hwmod_class omap3xxx_dsi_hwmod_class = { | |||
1689 | .name = "dsi", | 1686 | .name = "dsi", |
1690 | }; | 1687 | }; |
1691 | 1688 | ||
1689 | static struct omap_hwmod_irq_info omap3xxx_dsi1_irqs[] = { | ||
1690 | { .irq = 25 }, | ||
1691 | }; | ||
1692 | |||
1692 | /* dss_dsi1 */ | 1693 | /* dss_dsi1 */ |
1693 | static struct omap_hwmod_addr_space omap3xxx_dss_dsi1_addrs[] = { | 1694 | static struct omap_hwmod_addr_space omap3xxx_dss_dsi1_addrs[] = { |
1694 | { | 1695 | { |
@@ -1722,6 +1723,8 @@ static struct omap_hwmod_ocp_if *omap3xxx_dss_dsi1_slaves[] = { | |||
1722 | static struct omap_hwmod omap3xxx_dss_dsi1_hwmod = { | 1723 | static struct omap_hwmod omap3xxx_dss_dsi1_hwmod = { |
1723 | .name = "dss_dsi1", | 1724 | .name = "dss_dsi1", |
1724 | .class = &omap3xxx_dsi_hwmod_class, | 1725 | .class = &omap3xxx_dsi_hwmod_class, |
1726 | .mpu_irqs = omap3xxx_dsi1_irqs, | ||
1727 | .mpu_irqs_cnt = ARRAY_SIZE(omap3xxx_dsi1_irqs), | ||
1725 | .main_clk = "dss1_alwon_fck", | 1728 | .main_clk = "dss1_alwon_fck", |
1726 | .prcm = { | 1729 | .prcm = { |
1727 | .omap2 = { | 1730 | .omap2 = { |
diff --git a/arch/arm/plat-omap/include/plat/display.h b/arch/arm/plat-omap/include/plat/display.h index 0f140ecedb01..5e04ddc18fa8 100644 --- a/arch/arm/plat-omap/include/plat/display.h +++ b/arch/arm/plat-omap/include/plat/display.h | |||
@@ -58,6 +58,7 @@ enum omap_display_type { | |||
58 | OMAP_DISPLAY_TYPE_SDI = 1 << 2, | 58 | OMAP_DISPLAY_TYPE_SDI = 1 << 2, |
59 | OMAP_DISPLAY_TYPE_DSI = 1 << 3, | 59 | OMAP_DISPLAY_TYPE_DSI = 1 << 3, |
60 | OMAP_DISPLAY_TYPE_VENC = 1 << 4, | 60 | OMAP_DISPLAY_TYPE_VENC = 1 << 4, |
61 | OMAP_DISPLAY_TYPE_HDMI = 1 << 5, | ||
61 | }; | 62 | }; |
62 | 63 | ||
63 | enum omap_plane { | 64 | enum omap_plane { |
@@ -237,6 +238,13 @@ static inline int omap_display_init(struct omap_dss_board_info *board_data) | |||
237 | } | 238 | } |
238 | #endif | 239 | #endif |
239 | 240 | ||
241 | struct omap_display_platform_data { | ||
242 | struct omap_dss_board_info *board_data; | ||
243 | /* TODO: Additional members to be added when PM is considered */ | ||
244 | |||
245 | bool (*opt_clock_available)(const char *clk_role); | ||
246 | }; | ||
247 | |||
240 | struct omap_video_timings { | 248 | struct omap_video_timings { |
241 | /* Unit: pixels */ | 249 | /* Unit: pixels */ |
242 | u16 x_res; | 250 | u16 x_res; |
@@ -396,8 +404,8 @@ struct omap_dss_device { | |||
396 | struct { | 404 | struct { |
397 | u16 regn; | 405 | u16 regn; |
398 | u16 regm; | 406 | u16 regm; |
399 | u16 regm3; | 407 | u16 regm_dispc; |
400 | u16 regm4; | 408 | u16 regm_dsi; |
401 | 409 | ||
402 | u16 lp_clk_div; | 410 | u16 lp_clk_div; |
403 | 411 | ||
@@ -555,6 +563,9 @@ int omap_dsi_update(struct omap_dss_device *dssdev, | |||
555 | int channel, | 563 | int channel, |
556 | u16 x, u16 y, u16 w, u16 h, | 564 | u16 x, u16 y, u16 w, u16 h, |
557 | void (*callback)(int, void *), void *data); | 565 | void (*callback)(int, void *), void *data); |
566 | int omap_dsi_request_vc(struct omap_dss_device *dssdev, int *channel); | ||
567 | int omap_dsi_set_vc_id(struct omap_dss_device *dssdev, int channel, int vc_id); | ||
568 | void omap_dsi_release_vc(struct omap_dss_device *dssdev, int channel); | ||
558 | 569 | ||
559 | int omapdss_dsi_display_enable(struct omap_dss_device *dssdev); | 570 | int omapdss_dsi_display_enable(struct omap_dss_device *dssdev); |
560 | void omapdss_dsi_display_disable(struct omap_dss_device *dssdev); | 571 | void omapdss_dsi_display_disable(struct omap_dss_device *dssdev); |