diff options
author | Grazvydas Ignotas <notasas@gmail.com> | 2010-02-17 17:09:24 -0500 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2010-02-17 20:23:20 -0500 |
commit | 7b097896e4a5b5ea4798db806e63a1138b1b8eb8 (patch) | |
tree | 149bd36578d279761cbccad66274a132899544d8 /arch/arm/mach-omap2/board-omap3pandora.c | |
parent | 87520aae7c46a725835f5761feca0f794e2eff9e (diff) |
OMAP: pandora: add DSS2 support and related regulators
This patch adds configuration data for DSS2 and sets up
display related regulators.
Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Acked-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2/board-omap3pandora.c')
-rw-r--r-- | arch/arm/mach-omap2/board-omap3pandora.c | 111 |
1 files changed, 111 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/board-omap3pandora.c b/arch/arm/mach-omap2/board-omap3pandora.c index 9967b5d24b50..7ea389412b2a 100644 --- a/arch/arm/mach-omap2/board-omap3pandora.c +++ b/arch/arm/mach-omap2/board-omap3pandora.c | |||
@@ -40,6 +40,7 @@ | |||
40 | #include <mach/hardware.h> | 40 | #include <mach/hardware.h> |
41 | #include <plat/mcspi.h> | 41 | #include <plat/mcspi.h> |
42 | #include <plat/usb.h> | 42 | #include <plat/usb.h> |
43 | #include <plat/display.h> | ||
43 | 44 | ||
44 | #include "mux.h" | 45 | #include "mux.h" |
45 | #include "sdram-micron-mt46h32m32lf-6.h" | 46 | #include "sdram-micron-mt46h32m32lf-6.h" |
@@ -192,6 +193,61 @@ static struct twl4030_keypad_data pandora_kp_data = { | |||
192 | .rep = 1, | 193 | .rep = 1, |
193 | }; | 194 | }; |
194 | 195 | ||
196 | static struct omap_dss_device pandora_lcd_device = { | ||
197 | .name = "lcd", | ||
198 | .driver_name = "tpo_td043mtea1_panel", | ||
199 | .type = OMAP_DISPLAY_TYPE_DPI, | ||
200 | .phy.dpi.data_lines = 24, | ||
201 | .reset_gpio = 157, | ||
202 | }; | ||
203 | |||
204 | static struct omap_dss_device pandora_tv_device = { | ||
205 | .name = "tv", | ||
206 | .driver_name = "venc", | ||
207 | .type = OMAP_DISPLAY_TYPE_VENC, | ||
208 | .phy.venc.type = OMAP_DSS_VENC_TYPE_SVIDEO, | ||
209 | }; | ||
210 | |||
211 | static struct omap_dss_device *pandora_dss_devices[] = { | ||
212 | &pandora_lcd_device, | ||
213 | &pandora_tv_device, | ||
214 | }; | ||
215 | |||
216 | static struct omap_dss_board_info pandora_dss_data = { | ||
217 | .num_devices = ARRAY_SIZE(pandora_dss_devices), | ||
218 | .devices = pandora_dss_devices, | ||
219 | .default_device = &pandora_lcd_device, | ||
220 | }; | ||
221 | |||
222 | static struct platform_device pandora_dss_device = { | ||
223 | .name = "omapdss", | ||
224 | .id = -1, | ||
225 | .dev = { | ||
226 | .platform_data = &pandora_dss_data, | ||
227 | }, | ||
228 | }; | ||
229 | |||
230 | static struct regulator_consumer_supply pandora_vcc_lcd_supply = { | ||
231 | .supply = "vcc", | ||
232 | .dev = &pandora_lcd_device.dev, | ||
233 | }; | ||
234 | |||
235 | static struct regulator_consumer_supply pandora_vdda_dac_supply = { | ||
236 | .supply = "vdda_dac", | ||
237 | .dev = &pandora_dss_device.dev, | ||
238 | }; | ||
239 | |||
240 | static struct regulator_consumer_supply pandora_vdds_supplies[] = { | ||
241 | { | ||
242 | .supply = "vdds_sdi", | ||
243 | .dev = &pandora_dss_device.dev, | ||
244 | }, | ||
245 | { | ||
246 | .supply = "vdds_dsi", | ||
247 | .dev = &pandora_dss_device.dev, | ||
248 | }, | ||
249 | }; | ||
250 | |||
195 | static struct omap2_hsmmc_info omap3pandora_mmc[] = { | 251 | static struct omap2_hsmmc_info omap3pandora_mmc[] = { |
196 | { | 252 | { |
197 | .mmc = 1, | 253 | .mmc = 1, |
@@ -277,6 +333,51 @@ static struct regulator_init_data pandora_vmmc2 = { | |||
277 | .consumer_supplies = &pandora_vmmc2_supply, | 333 | .consumer_supplies = &pandora_vmmc2_supply, |
278 | }; | 334 | }; |
279 | 335 | ||
336 | /* VDAC for DSS driving S-Video */ | ||
337 | static struct regulator_init_data pandora_vdac = { | ||
338 | .constraints = { | ||
339 | .min_uV = 1800000, | ||
340 | .max_uV = 1800000, | ||
341 | .apply_uV = true, | ||
342 | .valid_modes_mask = REGULATOR_MODE_NORMAL | ||
343 | | REGULATOR_MODE_STANDBY, | ||
344 | .valid_ops_mask = REGULATOR_CHANGE_MODE | ||
345 | | REGULATOR_CHANGE_STATUS, | ||
346 | }, | ||
347 | .num_consumer_supplies = 1, | ||
348 | .consumer_supplies = &pandora_vdda_dac_supply, | ||
349 | }; | ||
350 | |||
351 | /* VPLL2 for digital video outputs */ | ||
352 | static struct regulator_init_data pandora_vpll2 = { | ||
353 | .constraints = { | ||
354 | .min_uV = 1800000, | ||
355 | .max_uV = 1800000, | ||
356 | .apply_uV = true, | ||
357 | .valid_modes_mask = REGULATOR_MODE_NORMAL | ||
358 | | REGULATOR_MODE_STANDBY, | ||
359 | .valid_ops_mask = REGULATOR_CHANGE_MODE | ||
360 | | REGULATOR_CHANGE_STATUS, | ||
361 | }, | ||
362 | .num_consumer_supplies = ARRAY_SIZE(pandora_vdds_supplies), | ||
363 | .consumer_supplies = pandora_vdds_supplies, | ||
364 | }; | ||
365 | |||
366 | /* VAUX1 for LCD */ | ||
367 | static struct regulator_init_data pandora_vaux1 = { | ||
368 | .constraints = { | ||
369 | .min_uV = 3000000, | ||
370 | .max_uV = 3000000, | ||
371 | .apply_uV = true, | ||
372 | .valid_modes_mask = REGULATOR_MODE_NORMAL | ||
373 | | REGULATOR_MODE_STANDBY, | ||
374 | .valid_ops_mask = REGULATOR_CHANGE_MODE | ||
375 | | REGULATOR_CHANGE_STATUS, | ||
376 | }, | ||
377 | .num_consumer_supplies = 1, | ||
378 | .consumer_supplies = &pandora_vcc_lcd_supply, | ||
379 | }; | ||
380 | |||
280 | static struct twl4030_usb_data omap3pandora_usb_data = { | 381 | static struct twl4030_usb_data omap3pandora_usb_data = { |
281 | .usb_mode = T2_USB_MODE_ULPI, | 382 | .usb_mode = T2_USB_MODE_ULPI, |
282 | }; | 383 | }; |
@@ -298,6 +399,9 @@ static struct twl4030_platform_data omap3pandora_twldata = { | |||
298 | .codec = &omap3pandora_codec_data, | 399 | .codec = &omap3pandora_codec_data, |
299 | .vmmc1 = &pandora_vmmc1, | 400 | .vmmc1 = &pandora_vmmc1, |
300 | .vmmc2 = &pandora_vmmc2, | 401 | .vmmc2 = &pandora_vmmc2, |
402 | .vdac = &pandora_vdac, | ||
403 | .vpll2 = &pandora_vpll2, | ||
404 | .vaux1 = &pandora_vaux1, | ||
301 | .keypad = &pandora_kp_data, | 405 | .keypad = &pandora_kp_data, |
302 | }; | 406 | }; |
303 | 407 | ||
@@ -365,6 +469,12 @@ static struct spi_board_info omap3pandora_spi_board_info[] __initdata = { | |||
365 | .controller_data = &ads7846_mcspi_config, | 469 | .controller_data = &ads7846_mcspi_config, |
366 | .irq = OMAP_GPIO_IRQ(OMAP3_PANDORA_TS_GPIO), | 470 | .irq = OMAP_GPIO_IRQ(OMAP3_PANDORA_TS_GPIO), |
367 | .platform_data = &ads7846_config, | 471 | .platform_data = &ads7846_config, |
472 | }, { | ||
473 | .modalias = "tpo_td043mtea1_panel_spi", | ||
474 | .bus_num = 1, | ||
475 | .chip_select = 1, | ||
476 | .max_speed_hz = 375000, | ||
477 | .platform_data = &pandora_lcd_device, | ||
368 | } | 478 | } |
369 | }; | 479 | }; |
370 | 480 | ||
@@ -379,6 +489,7 @@ static void __init omap3pandora_init_irq(void) | |||
379 | static struct platform_device *omap3pandora_devices[] __initdata = { | 489 | static struct platform_device *omap3pandora_devices[] __initdata = { |
380 | &pandora_leds_gpio, | 490 | &pandora_leds_gpio, |
381 | &pandora_keys_gpio, | 491 | &pandora_keys_gpio, |
492 | &pandora_dss_device, | ||
382 | }; | 493 | }; |
383 | 494 | ||
384 | static struct ehci_hcd_omap_platform_data ehci_pdata __initconst = { | 495 | static struct ehci_hcd_omap_platform_data ehci_pdata __initconst = { |