diff options
author | Peter Ujfalusi <peter.ujfalusi@ti.com> | 2011-06-07 09:28:54 +0200 |
---|---|---|
committer | Peter Ujfalusi <peter.ujfalusi@ti.com> | 2011-07-04 17:43:38 +0200 |
commit | 827ed9aef2f13000d58616384ea6a22497e787b6 (patch) | |
tree | fd6d117feaa7ac9c9e6195224efff07f230e867a /arch/arm/mach-omap2/board-omap3touchbook.c | |
parent | OMAP4: Move common twl6030 configuration to twl-common (diff) | |
download | linux-827ed9aef2f13000d58616384ea6a22497e787b6.tar.xz linux-827ed9aef2f13000d58616384ea6a22497e787b6.zip |
OMAP3: Move common twl configuration to twl-common
Reduce the amount of duplicated code by moving the common
configuration for twl4030/5030/tpsxx to the twl-common file.
Use the omap3_pmic_get_config function from board files to
properly configure the PMIC with the common fields.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2/board-omap3touchbook.c')
-rw-r--r-- | arch/arm/mach-omap2/board-omap3touchbook.c | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/arch/arm/mach-omap2/board-omap3touchbook.c b/arch/arm/mach-omap2/board-omap3touchbook.c index 57e6ed34ebbc..717972c5ce3e 100644 --- a/arch/arm/mach-omap2/board-omap3touchbook.c +++ b/arch/arm/mach-omap2/board-omap3touchbook.c @@ -235,25 +235,9 @@ static struct regulator_init_data touchbook_vpll2 = { .consumer_supplies = touchbook_vdvi_supply, }; -static struct twl4030_usb_data touchbook_usb_data = { - .usb_mode = T2_USB_MODE_ULPI, -}; - -static struct twl4030_codec_audio_data touchbook_audio_data; - -static struct twl4030_codec_data touchbook_codec_data = { - .audio_mclk = 26000000, - .audio = &touchbook_audio_data, -}; - static struct twl4030_platform_data touchbook_twldata = { - .irq_base = TWL4030_IRQ_BASE, - .irq_end = TWL4030_IRQ_END, - /* platform_data for children goes here */ - .usb = &touchbook_usb_data, .gpio = &touchbook_gpio_data, - .codec = &touchbook_codec_data, .vmmc1 = &touchbook_vmmc1, .vsim = &touchbook_vsim, .vdac = &touchbook_vdac, @@ -269,8 +253,9 @@ static struct i2c_board_info __initdata touchBook_i2c_boardinfo[] = { static int __init omap3_touchbook_i2c_init(void) { /* Standard TouchBook bus */ + omap3_pmic_get_config(&touchbook_twldata, + TWL_COMMON_PDATA_USB | TWL_COMMON_PDATA_AUDIO, 0); omap3_pmic_init("twl4030", &touchbook_twldata); - /* Additional TouchBook bus */ omap_register_i2c_bus(3, 100, touchBook_i2c_boardinfo, ARRAY_SIZE(touchBook_i2c_boardinfo)); |