From 5fe5b767dc6fb3df6fa6eaa8e05b727914f2bb4c Mon Sep 17 00:00:00 2001 From: Lars-Peter Clausen Date: Sat, 25 Oct 2014 17:41:58 +0200 Subject: [PATCH] ASoC: dapm: Do not pretend to support controls for non mixer/mux widgets Controls on a path only have an effect if the sink on the path is either a mixer or mux widget. Currently we sort of silently ignore controls on other paths, but since they don't do anything having them on other paths does not make much sense and it is probably safe to assume that if we see such a path it is a mistake in the driver that registered the path. This patch modifies snd_soc_dapm_add_path() to report an error if a path with and control is encountered where we didn't expect a control. This also allows to simplify the code quite a bit. The patch also moves the connecting of the path lists out of dapm_connect_mux() and dapm_connect_mixer() into snd_soc_dapm_add_path(). Signed-off-by: Lars-Peter Clausen Signed-off-by: Mark Brown --- Reading git-format-patch failed