Skip to content

Commit 3190dad

Browse files
committed
Merge branch 'fix/asoc' into for-linus
2 parents 157186b + ea02c63 commit 3190dad

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

sound/soc/codecs/wm_hubs.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -215,23 +215,23 @@ static const struct snd_kcontrol_new analogue_snd_controls[] = {
215215
SOC_SINGLE_TLV("IN1L Volume", WM8993_LEFT_LINE_INPUT_1_2_VOLUME, 0, 31, 0,
216216
inpga_tlv),
217217
SOC_SINGLE("IN1L Switch", WM8993_LEFT_LINE_INPUT_1_2_VOLUME, 7, 1, 1),
218-
SOC_SINGLE("IN1L ZC Switch", WM8993_LEFT_LINE_INPUT_1_2_VOLUME, 7, 1, 0),
218+
SOC_SINGLE("IN1L ZC Switch", WM8993_LEFT_LINE_INPUT_1_2_VOLUME, 6, 1, 0),
219219

220220
SOC_SINGLE_TLV("IN1R Volume", WM8993_RIGHT_LINE_INPUT_1_2_VOLUME, 0, 31, 0,
221221
inpga_tlv),
222222
SOC_SINGLE("IN1R Switch", WM8993_RIGHT_LINE_INPUT_1_2_VOLUME, 7, 1, 1),
223-
SOC_SINGLE("IN1R ZC Switch", WM8993_RIGHT_LINE_INPUT_1_2_VOLUME, 7, 1, 0),
223+
SOC_SINGLE("IN1R ZC Switch", WM8993_RIGHT_LINE_INPUT_1_2_VOLUME, 6, 1, 0),
224224

225225

226226
SOC_SINGLE_TLV("IN2L Volume", WM8993_LEFT_LINE_INPUT_3_4_VOLUME, 0, 31, 0,
227227
inpga_tlv),
228228
SOC_SINGLE("IN2L Switch", WM8993_LEFT_LINE_INPUT_3_4_VOLUME, 7, 1, 1),
229-
SOC_SINGLE("IN2L ZC Switch", WM8993_LEFT_LINE_INPUT_3_4_VOLUME, 7, 1, 0),
229+
SOC_SINGLE("IN2L ZC Switch", WM8993_LEFT_LINE_INPUT_3_4_VOLUME, 6, 1, 0),
230230

231231
SOC_SINGLE_TLV("IN2R Volume", WM8993_RIGHT_LINE_INPUT_3_4_VOLUME, 0, 31, 0,
232232
inpga_tlv),
233233
SOC_SINGLE("IN2R Switch", WM8993_RIGHT_LINE_INPUT_3_4_VOLUME, 7, 1, 1),
234-
SOC_SINGLE("IN2R ZC Switch", WM8993_RIGHT_LINE_INPUT_3_4_VOLUME, 7, 1, 0),
234+
SOC_SINGLE("IN2R ZC Switch", WM8993_RIGHT_LINE_INPUT_3_4_VOLUME, 6, 1, 0),
235235

236236
SOC_SINGLE_TLV("MIXINL IN2L Volume", WM8993_INPUT_MIXER3, 7, 1, 0,
237237
inmix_sw_tlv),

sound/soc/soc-dapm.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,7 @@ static int dapm_connect_mixer(struct snd_soc_dapm_context *dapm,
325325
}
326326

327327
static int dapm_is_shared_kcontrol(struct snd_soc_dapm_context *dapm,
328+
struct snd_soc_dapm_widget *kcontrolw,
328329
const struct snd_kcontrol_new *kcontrol_new,
329330
struct snd_kcontrol **kcontrol)
330331
{
@@ -334,6 +335,8 @@ static int dapm_is_shared_kcontrol(struct snd_soc_dapm_context *dapm,
334335
*kcontrol = NULL;
335336

336337
list_for_each_entry(w, &dapm->card->widgets, list) {
338+
if (w == kcontrolw || w->dapm != kcontrolw->dapm)
339+
continue;
337340
for (i = 0; i < w->num_kcontrols; i++) {
338341
if (&w->kcontrol_news[i] == kcontrol_new) {
339342
if (w->kcontrols)
@@ -468,7 +471,7 @@ static int dapm_new_mux(struct snd_soc_dapm_context *dapm,
468471
return -EINVAL;
469472
}
470473

471-
shared = dapm_is_shared_kcontrol(dapm, &w->kcontrol_news[0],
474+
shared = dapm_is_shared_kcontrol(dapm, w, &w->kcontrol_news[0],
472475
&kcontrol);
473476
if (kcontrol) {
474477
wlist = kcontrol->private_data;

0 commit comments

Comments
 (0)