summaryrefslogtreecommitdiff
path: root/arch/arm/mach-omap2/twl-common.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap2/twl-common.c')
-rw-r--r--arch/arm/mach-omap2/twl-common.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/arch/arm/mach-omap2/twl-common.c b/arch/arm/mach-omap2/twl-common.c
index cd1cba84bcd9..931495a25872 100644
--- a/arch/arm/mach-omap2/twl-common.c
+++ b/arch/arm/mach-omap2/twl-common.c
@@ -529,28 +529,28 @@ void __init omap4_pmic_get_config(struct twl4030_platform_data *pmic_data,
#include <linux/platform_data/omap-twl4030.h>
/* Commonly used configuration */
-static struct omap_tw4030_pdata omap_twl4030_audio_data = {
- .has_hs = OMAP_TWL4030_LEFT | OMAP_TWL4030_RIGHT,
- .has_hf = OMAP_TWL4030_LEFT | OMAP_TWL4030_RIGHT,
- .has_linein = OMAP_TWL4030_LEFT | OMAP_TWL4030_RIGHT,
-};
+static struct omap_tw4030_pdata omap_twl4030_audio_data;
static struct platform_device audio_device = {
.name = "omap-twl4030",
.id = -1,
- .dev = {
- .platform_data = &omap_twl4030_audio_data,
- },
};
-void __init omap_twl4030_audio_init(char *card_name)
+void __init omap_twl4030_audio_init(char *card_name,
+ struct omap_tw4030_pdata *pdata)
{
- omap_twl4030_audio_data.card_name = card_name;
+ if (!pdata)
+ pdata = &omap_twl4030_audio_data;
+
+ pdata->card_name = card_name;
+
+ audio_device.dev.platform_data = pdata;
platform_device_register(&audio_device);
}
#else /* SOC_OMAP_TWL4030 */
-void __init omap_twl4030_audio_init(char *card_name)
+void __init omap_twl4030_audio_init(char *card_name,
+ struct omap_tw4030_pdata *pdata)
{
return;
}