Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 14388a69 authored by Mark Brown's avatar Mark Brown
Browse files

Merge remote-tracking branch 'asoc/fix/dapm' into asoc-linus

parents c200d888 fe581391
Loading
Loading
Loading
Loading
+4 −3
Original line number Original line Diff line number Diff line
@@ -679,13 +679,14 @@ static int dapm_new_mux(struct snd_soc_dapm_widget *w)
		return -EINVAL;
		return -EINVAL;
	}
	}


	path = list_first_entry(&w->sources, struct snd_soc_dapm_path,
	if (list_empty(&w->sources)) {
				list_sink);
	if (!path) {
		dev_err(dapm->dev, "ASoC: mux %s has no paths\n", w->name);
		dev_err(dapm->dev, "ASoC: mux %s has no paths\n", w->name);
		return -EINVAL;
		return -EINVAL;
	}
	}


	path = list_first_entry(&w->sources, struct snd_soc_dapm_path,
				list_sink);

	ret = dapm_create_or_share_mixmux_kcontrol(w, 0, path);
	ret = dapm_create_or_share_mixmux_kcontrol(w, 0, path);
	if (ret < 0)
	if (ret < 0)
		return ret;
		return ret;