[alsa-devel] Linux Kernel-3.5 crashed as dapm is not supported by codec

Rajeev kumar rajeev-dlh.kumar at st.com
Tue Nov 6 11:40:41 CET 2012

Hello Mark,

On 9/21/2012 9:27 AM, Rajeev kumar wrote:
> Hello Mark,
> On 9/20/2012 5:19 PM, Mark Brown wrote:
>> On Thu, Sep 20, 2012 at 04:46:27PM +0530, Rajeev kumar wrote:
>>> I have not provided the dapm support in codec. When the system goes
>>> in hibernation state it gets crashed. command for putting the system
>>> in hibernation:
>> DAPM is mandatory now, though any device with an audio interface
>> connected should have some DAPM widgets added transparently so its not
>> always explicitly present in the CODEC driver. It's just causing too
>> much pain to special case non-DAPM devices and theres really not any
>> cases where there's no need for widgets.

Once again I am raising this issue. Sorry for that.
First time I have implemented dapm support for my codec driver (sta529), 
but still crash is there. There is no any asynchronous events, so 
platform/Machine driver does not contains any dapm widgets.

Please find below the implementation for dapm.

static const struct snd_soc_dapm_widget sta529_dapm_widgets[] = {
         SND_SOC_DAPM_DAC("DAC", "Play", SND_SOC_NOPM , 0, 0),
         SND_SOC_DAPM_ADC("ADC", "Capture", SND_SOC_NOPM, 0, 0),

static const struct snd_soc_dapm_route sta529_audio_map[] = {
         {"DAC", NULL, "output"},
         {"ADC", NULL, "input"},
         {"HPL", NULL, "HP Left Out"},
         {"HPR", NULL, "HP Right Out"},
         {"SPKL", NULL, "SPK Left Out"},
         {"SPKR", NULL, "SPK Right Out"},
struct snd_soc_codec_driver sta529_codec_driver = {
         .probe = sta529_probe,
         .remove = sta529_remove,
         .set_bias_level = sta529_set_bias_level,
         .suspend = sta529_suspend,
         .resume = sta529_resume,
         .controls = sta529_snd_controls,
         .num_controls = ARRAY_SIZE(sta529_snd_controls),
         .dapm_widgets = sta529_dapm_widgets,
         .num_dapm_widgets = ARRAY_SIZE(sta529_dapm_widgets),
         .dapm_routes = sta529_audio_map,
         .num_dapm_routes = ARRAY_SIZE(sta529_audio_map),

Could you please suggest me, is there any thing more I need to do to 
make it work or I am missing something.

For reference, please find crash log also.

snd_soc_dapm_shutdown+0x4c/0x11c) from [<803ce05c>] 
[<803ce05c>] (snd_soc_poweroff+0x68/0x70) from [<80288b1c>] 
[<80288b1c>] (platform_pm_poweroff+0x40/0x58) from [<8028d1a8>] 
[<8028d1a8>] (dpm_run_callback.isra.4+0x3c/0x74) from [<8028dbcc>] 
[<8028dbcc>] (__device_suspend+0x180/0x228) from [<8028e5d4>] 
[<8028e5d4>] (dpm_suspend+0xb4/0x220) from [<8028e97c>] 
[<8028e97c>] (dpm_suspend_start+0x6c/0x74) from [<8005b778>] 
[<8005b778>] (hibernation_platform_enter+0x48/0x128) from [<8005b9ac>] 
[<8005b9ac>] (hibernate+0x154/0x21c) from [<80059b10>] 
[<80059b10>] (state_store+0xbc/0xd0) from [<801f093c>] 
[<801f093c>] (kobj_attr_store+0x1c/0x28) from [<80127bd0>] 
[<80127bd0>] (sysfs_write_file+0x118/0x14c) from [<800d2640>] 
[<800d2640>] (vfs_write+0xc4/0x140) from [<800d28bc>] (sys_write+0x4c/0x78)
[<800d28bc>] (sys_write+0x4c/0x78) from [<8000de20>] 
Code: e59350f8 e3a03000 e2455014 ea00000f (e595201c)

Best Regards

> Best Regards
> Rajeev

More information about the Alsa-devel mailing list