[alsa-devel] ASoC: Failed to create component debugfs directory

Mark Brown broonie at kernel.org
Wed Feb 21 14:02:41 CET 2018


On Tue, Feb 20, 2018 at 04:37:33PM -0300, Fabio Estevam wrote:

> Thanks for your clarification.

> What is the best way to avoid the "Failed to create
> component debugfs directory" warning?

It's a legit warning - we shouldn't really be creating two components
for the same device.  However this is a bit of a corner case as it's the
dmaengine platform driver which is kind of a virtual device, it's not
really the device that we use with DMA that's being represented but
rather the link between that and the DMA controller.

Does the below patch (completely untested) help here?  It adds a prefix
to the name for deduplication.  

diff --git a/sound/soc/soc-generic-dmaengine-pcm.c b/sound/soc/soc-generic-dmaengine-pcm.c
index d53786498b61..d5a6eea64036 100644
--- a/sound/soc/soc-generic-dmaengine-pcm.c
+++ b/sound/soc/soc-generic-dmaengine-pcm.c
@@ -431,6 +431,7 @@ int snd_dmaengine_pcm_register(struct device *dev,
 	if (!pcm)
 		return -ENOMEM;
 
+	pcm->platform.component.name_prefix = "dma";
 	pcm->config = config;
 	pcm->flags = flags;
 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20180221/b3670354/attachment.sig>


More information about the Alsa-devel mailing list