Since the debugfs directory is current per CODEC we should only init
it when the CODEC is initialised, otherwise we end up with errors
being generated when an attempt is made to add duplicate debugfs
entries.
Since most of this stuff is actually for the card we should refactor
but this can come later.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
return ret;
}
}
+
+ soc_init_codec_debugfs(codec);
+
/* mark codec as probed and add to card codec list */
codec->probed = 1;
list_add(&codec->card_list, &card->codec_dev_list);
if (ret < 0)
printk(KERN_WARNING "asoc: failed to add codec sysfs files\n");
- soc_init_codec_debugfs(codec);
-
/* create the pcm */
ret = soc_new_pcm(rtd, num);
if (ret < 0) {