aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1/board-ams-delta.c
diff options
context:
space:
mode:
authorJanusz Krzysztofik <jmkrzyszt@gmail.com>2012-10-03 06:46:57 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-10-04 13:50:36 -0400
commitb764de2d8bafff3a52aa6ee66cedf435486974f4 (patch)
tree7f0713d5ab53f7df3c25bfe0f05a2a3d78b4b945 /arch/arm/mach-omap1/board-ams-delta.c
parent68214d998a2e3102854cf10ebe505243035702fc (diff)
ASoC: ams-delta: Convert to use snd_soc_register_card()
The old method of registering with the ASoC core by creating a "soc-audio" platform device no longer works for Amstrad Delta sound card after recent changes to drvdata handling (commit 0998d0631001288a5974afc0b2a5f568bcdecb4d, 'device-core: Ensure drvdata = NULL when no driver is bound'. Use snd_soc_register_card() method instead, as suggested by the ASoC core generated warning message, and move both the card and codec platform device registration to the arch board file where those belong. Created and tested against linux-3.6-rc5. Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'arch/arm/mach-omap1/board-ams-delta.c')
-rw-r--r--arch/arm/mach-omap1/board-ams-delta.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c
index c53469802c03..5ab9c6bdce84 100644
--- a/arch/arm/mach-omap1/board-ams-delta.c
+++ b/arch/arm/mach-omap1/board-ams-delta.c
@@ -444,16 +444,28 @@ static struct omap1_cam_platform_data ams_delta_camera_platform_data = {
444 .lclk_khz_max = 1334, /* results in 5fps CIF, 10fps QCIF */ 444 .lclk_khz_max = 1334, /* results in 5fps CIF, 10fps QCIF */
445}; 445};
446 446
447static struct platform_device ams_delta_audio_device = {
448 .name = "ams-delta-audio",
449 .id = -1,
450};
451
452static struct platform_device cx20442_codec_device = {
453 .name = "cx20442-codec",
454 .id = -1,
455};
456
447static struct platform_device *ams_delta_devices[] __initdata = { 457static struct platform_device *ams_delta_devices[] __initdata = {
448 &latch1_gpio_device, 458 &latch1_gpio_device,
449 &latch2_gpio_device, 459 &latch2_gpio_device,
450 &ams_delta_kp_device, 460 &ams_delta_kp_device,
451 &ams_delta_camera_device, 461 &ams_delta_camera_device,
462 &ams_delta_audio_device,
452}; 463};
453 464
454static struct platform_device *late_devices[] __initdata = { 465static struct platform_device *late_devices[] __initdata = {
455 &ams_delta_nand_device, 466 &ams_delta_nand_device,
456 &ams_delta_lcd_device, 467 &ams_delta_lcd_device,
468 &cx20442_codec_device,
457}; 469};
458 470
459static void __init ams_delta_init(void) 471static void __init ams_delta_init(void)