Commit d1222a0e5f93d2a5d3b3b69699f79f2c62ce1d7c
1 parent
c54e5cd381
Exists in
smarc_8mm_imx_4.14.98_2.0.0_ga
and in
4 other branches
MLK-21440-4: ASoC: imx-cs42888: remove snd_soc_find_dai
Previously we add snd_soc_find_dai to check if the codec is probed or not, but this bring kernel dump issue when CONFIG_LOCKDEP=y. [ 2.823379] WARNING: CPU: 2 PID: 1 at sound/soc/soc-core.c:1016 snd_soc_find_dai+0x144/0x150 [ 2.831827] Modules linked in: [ 2.834907] CPU: 2 PID: 1 Comm: swapper/0 Not tainted 4.14.78-00007-g524e1b1f0b3f #18 [ 2.842748] Hardware name: FSL i.MX8MM EVK board (DT) [ 2.847811] task: ffff8000624f0000 task.stack: ffff000008078000 [ 2.853745] PC is at snd_soc_find_dai+0x144/0x150 [ 2.858462] LR is at snd_soc_find_dai+0x140/0x150 ... [ 3.469675] Call trace: [ 3.472135] Exception stack(0xffff00000807ba40 to 0xffff00000807bb80) [ 3.478590] ba40: 0000000000000000 00000000ffffffff 0000000000000000 0000000000000002 [ 3.4864333.596564] [<ffff00000883f2a8>] bus_add_driver+0x110/0x230 [ 3.602149] [<ffff0000088412e8>] driver_register+0x68/0x100 [ 3.607735] [<ffff0000088426dc>] __platform_driver_register+0x54/0x60 [ 3.614191] [<ffff0000097e4cc8>] imx_rpmsg_driver_init+0x20/0x28 [ 3.620213] [<ffff0000080844c4>] do_one_initcall+0x44/0x130 [ 3.625801] [<ffff000009760ef8>] kernel_init_freeable+0x1e0/0x280 [ 3.631909] [<ffff00000908c3f8>] kernel_init+0x18/0x110 [ 3.637148] [<ffff000008085a4c>] ret_from_fork+0x10/0x1c So we could't resolve the warning "snd_soc_register_card failed (-517)". Fixes: 2bf5f9704785 ("MLK-19854-1: ASoC: imx-cs42888: fix error when m4 image is not loaded") Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> (cherry picked from commit 58ffdf239288cfa6904640fc8432c182cf56589b)
Showing 1 changed file with 0 additions and 8 deletions Side-by-side Diff
sound/soc/fsl/imx-cs42888.c
... | ... | @@ -318,8 +318,6 @@ |
318 | 318 | struct platform_device *esai_pdev; |
319 | 319 | struct platform_device *asrc_pdev = NULL; |
320 | 320 | struct imx_priv *priv = &card_priv; |
321 | - struct snd_soc_dai_link_component dlc = { 0 }; | |
322 | - struct snd_soc_dai *codec_dai; | |
323 | 321 | int ret; |
324 | 322 | u32 width; |
325 | 323 | |
... | ... | @@ -388,12 +386,6 @@ |
388 | 386 | if (priv->is_codec_rpmsg) { |
389 | 387 | imx_cs42888_dai[0].codec_name = "rpmsg-audio-codec-cs42888"; |
390 | 388 | imx_cs42888_dai[0].codec_dai_name = "cs42888"; |
391 | - | |
392 | - dlc.name = "rpmsg-audio-codec-cs42888"; | |
393 | - dlc.dai_name = "cs42888"; | |
394 | - codec_dai = snd_soc_find_dai(&dlc); | |
395 | - if (!codec_dai) | |
396 | - return -ENODEV; | |
397 | 389 | } else { |
398 | 390 | imx_cs42888_dai[0].codec_of_node = codec_np; |
399 | 391 | } |