]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
ASoC: rt5645: fix wrong mask for button report
authorBard Liao <bardliao@realtek.com>
Thu, 30 Apr 2015 10:18:46 +0000 (18:18 +0800)
committerMark Brown <broonie@kernel.org>
Fri, 1 May 2015 16:33:47 +0000 (17:33 +0100)
rt5645->btn_jack is for jack button report. So the mask should be
SND_JACK_BTN_0 | SND_JACK_BTN_1 | SND_JACK_BTN_2 | SND_JACK_BTN_3.

Signed-off-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5645.c

index 346ac45bfb68d0ab0adf15f229cc7cd9801cd7bd..b7b095994a75397722ebd3460ee1da77fda2cd01 100644 (file)
@@ -2693,7 +2693,8 @@ static int rt5645_irq_detection(struct rt5645_priv *rt5645)
        snd_soc_jack_report(rt5645->mic_jack, report, SND_JACK_MICROPHONE);
        if (rt5645->en_button_func)
                snd_soc_jack_report(rt5645->btn_jack,
-                       report, SND_JACK_MICROPHONE);
+                       report, SND_JACK_BTN_0 | SND_JACK_BTN_1 |
+                               SND_JACK_BTN_2 | SND_JACK_BTN_3);
 
        return report;
 }