[PATCH 10/14] ASoC: rsnd: use DAI driver ID instead of DAI ID

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Current rsnd is using DAI ID to get own priv data without setting
driver->id. It was no problem for Single Component, but will be problem
in case of Multi Component, because it is not a DAI serial number.

	struct snd_soc_dai *snd_soc_register_dai(...)
	{
		...
		if (dai_drv->id)
			dai->id = dai_drv->id;
		else
			dai->id = component->num_dai;
		...
	}

This patch sets driver->id, and get serial number.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@xxxxxxxxxxx>
---
 sound/soc/sh/rcar/core.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/sh/rcar/core.c b/sound/soc/sh/rcar/core.c
index 6a522e6dd85a..f3f17b784025 100644
--- a/sound/soc/sh/rcar/core.c
+++ b/sound/soc/sh/rcar/core.c
@@ -1378,6 +1378,7 @@ static void __rsnd_dai_probe(struct rsnd_priv *priv,
 	drv->name	= rdai->name;
 	drv->ops	= &rsnd_soc_dai_ops;
 	drv->pcm_new	= rsnd_pcm_new;
+	drv->id		= dai_i;
 
 	io_playback->rdai		= rdai;
 	io_capture->rdai		= rdai;
-- 
2.25.1




[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux