From f24633afc2f2b21e4e347587bb93a9bd2c17fd7c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Th=C3=A9baudeau?= Date: Mon, 18 Jun 2012 22:41:28 +0200 Subject: [PATCH] --- yaml --- r: 316279 b: refs/heads/master c: 8a720718b37d00cf8ab311902705ae7c7890bb95 h: refs/heads/master i: 316277: 6dc5d3c53e432a6ca45c79cc45c4012fbe9435c4 316275: 3470dc2564494e0e78bd68e3c862a73b92f94f04 316271: 1593e523d0c3f1ca3a8264e032b6246448fbc552 v: v3 --- [refs] | 2 +- trunk/sound/soc/soc-dapm.c | 8 +------- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/[refs] b/[refs] index f0417245c722..16e1a8e3b3ee 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: adf643aba8ed620f8c8e2533f4ace3a90e5daecf +refs/heads/master: 8a720718b37d00cf8ab311902705ae7c7890bb95 diff --git a/trunk/sound/soc/soc-dapm.c b/trunk/sound/soc/soc-dapm.c index c2206bc835da..967066873aad 100644 --- a/trunk/sound/soc/soc-dapm.c +++ b/trunk/sound/soc/soc-dapm.c @@ -2515,19 +2515,13 @@ int snd_soc_dapm_put_volsw(struct snd_kcontrol *kcontrol, int wi; val = (ucontrol->value.integer.value[0] & mask); + connect = !!val; if (invert) val = max - val; mask = mask << shift; val = val << shift; - if (val) - /* new connection */ - connect = invert ? 0 : 1; - else - /* old connection must be powered down */ - connect = invert ? 1 : 0; - mutex_lock_nested(&card->dapm_mutex, SND_SOC_DAPM_CLASS_RUNTIME); change = snd_soc_test_bits(widget->codec, reg, mask, val);