On boards which have more than one soc-audio device, the initialization
of the first device will create a sysfs directory named
/sys/devices/platform/soc-audio and subsequent soc-audio devices will
fail to init because they try to create another sysfs directory of the
same name.
The solution is to have a unique number for each device such that
different boards having combinations will be OK.
Signed-off-by: Alan Tull <alan.tull@freescale.com>
else
imx_sgtl5000_dai[0].codec_name = "sgtl5000.1-000a";
- imx_sgtl5000_snd_device = platform_device_alloc("soc-audio", -1);
+ imx_sgtl5000_snd_device = platform_device_alloc("soc-audio", 1);
if (!imx_sgtl5000_snd_device)
return -ENOMEM;
return -ENOMEM;
}
- imx_spdif_snd_device = platform_device_alloc("soc-audio", -1);
+ imx_spdif_snd_device = platform_device_alloc("soc-audio", 3);
if (!imx_spdif_snd_device) {
pr_err("%s - failed platform_device_alloc\n", __func__);
return -ENOMEM;