ASoC: Intel: sof_sdw_rt700: remap buttons
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Fri, 15 May 2020 21:07:30 +0000 (16:07 -0500)
committerMark Brown <broonie@kernel.org>
Mon, 18 May 2020 13:01:47 +0000 (14:01 +0100)
Use same mapping as in all other machine drivers:

BTN_0 : KEY_PLAYPAUSE
BTN_1 : KEY_VOICECOMMAND
BTN_2 : KEY_VOLUMEUP
BTN_3 : KEY_VOLUMEDOWN

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Link: https://lore.kernel.org/r/20200515210731.10942-5-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/boards/sof_sdw_rt700.c

index 5515f397a3ddf6c0960dab4d42f52560978670aa..5f50491ba5ee41a875993ddd2d0282fb79bcc665 100644 (file)
@@ -95,10 +95,10 @@ static int rt700_rtd_init(struct snd_soc_pcm_runtime *rtd)
 
        jack = &ctx->sdw_headset;
 
-       snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_VOLUMEUP);
-       snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_PLAYPAUSE);
-       snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEDOWN);
-       snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOICECOMMAND);
+       snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_PLAYPAUSE);
+       snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOICECOMMAND);
+       snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEUP);
+       snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOLUMEDOWN);
 
        ret = snd_soc_component_set_jack(component, jack, NULL);
        if (ret)