alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: dapm - fix prefix for DAPM muxes
@ 2011-05-24 16:39 Liam Girdwood
  2011-05-24 18:45 ` Jarkko Nikula
  0 siblings, 1 reply; 4+ messages in thread
From: Liam Girdwood @ 2011-05-24 16:39 UTC (permalink / raw)
  To: Mark Brown; +Cc: alsa-devel, Liam Girdwood

Make sure DAPM muxes have a valid kcontrol name instead of NULL.

Signed-off-by: Liam Girdwood <lrg@ti.com>
---
 sound/soc/soc-dapm.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c
index 456617e..c5d98e3 100644
--- a/sound/soc/soc-dapm.c
+++ b/sound/soc/soc-dapm.c
@@ -489,10 +489,10 @@ static int dapm_new_mux(struct snd_soc_dapm_context *dapm,
 	wlist->widgets[wlistentries - 1] = w;
 
 	if (!kcontrol) {
-		if (dapm->codec)
+		if (dapm->codec && dapm->codec->name_prefix)
 			prefix = dapm->codec->name_prefix;
 		else
-			prefix = NULL;
+			prefix = w->name;
 
 		if (shared) {
 			name = w->kcontrol_news[0].name;
-- 
1.7.4.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-05-24 19:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-24 16:39 [PATCH] ASoC: dapm - fix prefix for DAPM muxes Liam Girdwood
2011-05-24 18:45 ` Jarkko Nikula
2011-05-24 19:37   ` Stephen Warren
2011-05-24 19:40     ` Liam Girdwood

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).