ASoC: Intel: byt-max98090: Fix jack type in order to report correctly
authorJarkko Nikula <jarkko.nikula@linux.intel.com>
Mon, 23 Jun 2014 13:29:40 +0000 (16:29 +0300)
committerMark Brown <broonie@linaro.org>
Tue, 24 Jun 2014 15:20:43 +0000 (16:20 +0100)
Pass actual jack type bitmask to snd_soc_jack_new() in order to report
also microphone detections and not only headphone. While at it change also
jack name and pass also SND_JACK_LINEOUT type.

Reported-by: Jin Yao <yao.jin@intel.com>
Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
sound/soc/intel/byt-max98090.c

index 165ab6d..3e2e715 100644 (file)
@@ -108,7 +108,8 @@ static int byt_max98090_init(struct snd_soc_pcm_runtime *runtime)
        }
 
        /* Enable jack detection */
-       ret = snd_soc_jack_new(codec, "Headphone", SND_JACK_HEADPHONE, jack);
+       ret = snd_soc_jack_new(codec, "Headset",
+                              SND_JACK_LINEOUT | SND_JACK_HEADSET, jack);
        if (ret)
                return ret;