linux/sound/soc/omap
Peter Ujfalusi 76836fd354
ASoC: omap-abe-twl6040: Fix missing audio card caused by deferred probing
The machine driver fails to probe in next-20181113 with:

[    2.539093] omap-abe-twl6040 sound: ASoC: CODEC DAI twl6040-legacy not registered
[    2.546630] omap-abe-twl6040 sound: devm_snd_soc_register_card() failed: -517
...
[    3.693206] omap-abe-twl6040 sound: ASoC: Both platform name/of_node are set for TWL6040
[    3.701446] omap-abe-twl6040 sound: ASoC: failed to init link TWL6040
[    3.708007] omap-abe-twl6040 sound: devm_snd_soc_register_card() failed: -22
[    3.715148] omap-abe-twl6040: probe of sound failed with error -22

Bisect pointed to a merge commit:
first bad commit: [0f688ab20a540aafa984c5dbd68a71debebf4d7f] Merge remote-tracking branch 'net-next/master'

and a diff between a working kernel does not reveal anything which would
explain the change in behavior.

Further investigation showed that on the second try of loading fails
because the dai_link->platform is no longer NULL and it might be pointing
to uninitialized memory.

The fix is to move the snd_soc_dai_link and snd_soc_card inside of the
abe_twl6040 struct, which is dynamically allocated every time the driver
probes.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
2018-11-14 14:07:52 -08:00
..
am3517evm.c ASoC: omap: constify snd_soc_ops structures 2017-03-20 11:26:37 +00:00
ams-delta.c ASoC: ams_delta: use GPIO lookup table 2018-05-23 11:47:32 -07:00
Kconfig ASoC: omap: fix compile-test building 2018-05-25 18:34:46 +01:00
Makefile ASoC: omap: Delete the obsolete omap-pcm 2018-05-11 11:26:25 +09:00
mcbsp.c treewide: Use DEVICE_ATTR_RW 2018-01-09 16:33:31 +01:00
mcbsp.h ASoC: omap-mcbsp: Add PM QoS support for McBSP to prevent glitches 2017-02-01 17:19:53 +00:00
n810.c ASoC: omap: n810: HS mic is not working, add a widget for it with comment 2018-04-27 11:58:15 +01:00
omap3pandora.c ASoC: omap: constify snd_soc_ops structures 2017-03-20 11:26:37 +00:00
omap-abe-twl6040.c ASoC: omap-abe-twl6040: Fix missing audio card caused by deferred probing 2018-11-14 14:07:52 -08:00
omap-dmic.c ASoC: omap-dmic: Mark expected switch fall-throughs 2018-08-03 17:59:25 +01:00
omap-dmic.h ASoC: OMAP4: omap-dmic: Initial support for OMAP DMIC 2011-11-28 17:21:44 +00:00
omap-hdmi-audio.c ASoC: omap: use devm_snd_soc_register_component() 2018-09-10 15:14:23 +01:00
omap-mcbsp.c ASoC: omap-mcbsp: Convert to use the sdma-pcm instead of omap-pcm 2018-05-09 18:22:00 +09:00
omap-mcbsp.h ASoC: omap: rx51: omap_mcbsp_st_add_controls: add id parameter 2014-05-01 10:54:34 -07:00
omap-mcpdm.c ASoC: omap-mcpdm: Mark expected switch fall-throughs 2018-08-03 17:42:32 +01:00
omap-mcpdm.h ASoC: omap-mcpdm: API to configure offset cancellation 2011-09-26 22:23:32 +01:00
omap-twl4030.c ASoC: omap: Remove superfluous snd_soc_jack_free_gpios() call 2017-08-22 13:38:53 +01:00
osk5912.c ASoC: omap: constify snd_soc_ops structures 2017-03-20 11:26:37 +00:00
rx51.c ASoC: omap: Remove superfluous snd_soc_jack_free_gpios() call 2017-08-22 13:38:53 +01:00
sdma-pcm.c ASoC: omap: sdma-pcm: Correction for the include files 2018-05-17 13:28:58 +09:00
sdma-pcm.h ASoC: omap: Introduce the generic_dmaengine_pcm based sdma-pcm 2018-05-09 18:22:00 +09:00