aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/board-4430sdp.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap2/board-4430sdp.c')
-rw-r--r--arch/arm/mach-omap2/board-4430sdp.c55
1 files changed, 55 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/board-4430sdp.c b/arch/arm/mach-omap2/board-4430sdp.c
index a7c0b31fd084..c7cef44c75d4 100644
--- a/arch/arm/mach-omap2/board-4430sdp.c
+++ b/arch/arm/mach-omap2/board-4430sdp.c
@@ -345,11 +345,40 @@ static struct platform_device sdp4430_lcd_device = {
345 .id = -1, 345 .id = -1,
346}; 346};
347 347
348static struct regulator_consumer_supply sdp4430_vbat_supply[] = {
349 REGULATOR_SUPPLY("vddvibl", "twl6040-vibra"),
350 REGULATOR_SUPPLY("vddvibr", "twl6040-vibra"),
351};
352
353static struct regulator_init_data sdp4430_vbat_data = {
354 .constraints = {
355 .always_on = 1,
356 },
357 .num_consumer_supplies = ARRAY_SIZE(sdp4430_vbat_supply),
358 .consumer_supplies = sdp4430_vbat_supply,
359};
360
361static struct fixed_voltage_config sdp4430_vbat_pdata = {
362 .supply_name = "VBAT",
363 .microvolts = 3750000,
364 .init_data = &sdp4430_vbat_data,
365 .gpio = -EINVAL,
366};
367
368static struct platform_device sdp4430_vbat = {
369 .name = "reg-fixed-voltage",
370 .id = -1,
371 .dev = {
372 .platform_data = &sdp4430_vbat_pdata,
373 },
374};
375
348static struct platform_device *sdp4430_devices[] __initdata = { 376static struct platform_device *sdp4430_devices[] __initdata = {
349 &sdp4430_lcd_device, 377 &sdp4430_lcd_device,
350 &sdp4430_gpio_keys_device, 378 &sdp4430_gpio_keys_device,
351 &sdp4430_leds_gpio, 379 &sdp4430_leds_gpio,
352 &sdp4430_leds_pwm, 380 &sdp4430_leds_pwm,
381 &sdp4430_vbat,
353}; 382};
354 383
355static struct omap_lcd_config sdp4430_lcd_config __initdata = { 384static struct omap_lcd_config sdp4430_lcd_config __initdata = {
@@ -505,7 +534,33 @@ static struct regulator_init_data sdp4430_vusim = {
505 }, 534 },
506}; 535};
507 536
537static struct twl4030_codec_data twl6040_codec = {
538 /* single-step ramp for headset and handsfree */
539 .hs_left_step = 0x0f,
540 .hs_right_step = 0x0f,
541 .hf_left_step = 0x1d,
542 .hf_right_step = 0x1d,
543};
544
545static struct twl4030_vibra_data twl6040_vibra = {
546 .vibldrv_res = 8,
547 .vibrdrv_res = 3,
548 .viblmotor_res = 10,
549 .vibrmotor_res = 10,
550 .vddvibl_uV = 0, /* fixed volt supply - VBAT */
551 .vddvibr_uV = 0, /* fixed volt supply - VBAT */
552};
553
554static struct twl4030_audio_data twl6040_audio = {
555 .codec = &twl6040_codec,
556 .vibra = &twl6040_vibra,
557 .audpwron_gpio = 127,
558 .naudint_irq = OMAP44XX_IRQ_SYS_2N,
559 .irq_base = TWL6040_CODEC_IRQ_BASE,
560};
561
508static struct twl4030_platform_data sdp4430_twldata = { 562static struct twl4030_platform_data sdp4430_twldata = {
563 .audio = &twl6040_audio,
509 /* Regulators */ 564 /* Regulators */
510 .vusim = &sdp4430_vusim, 565 .vusim = &sdp4430_vusim,
511 .vaux1 = &sdp4430_vaux1, 566 .vaux1 = &sdp4430_vaux1,