Skip to content

Commit

Permalink
ASoC: mt6358: Fixes from an initial glance at a
Browse files Browse the repository at this point in the history
Merge series from Mark Brown <broonie@kernel.org>:

This is a collection of fixes I came up after glancing through an
initial test run with the snappily named Kukui Jacuzzi SKU16 Chromebook
on KernelCI.  There are more issues flagged, this is just what I fixed
thus far.
  • Loading branch information
Mark Brown committed Feb 28, 2023
2 parents e3e3299 + 8cbd727 commit b201929
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions sound/soc/codecs/mt6358.c
Original file line number Diff line number Diff line change
Expand Up @@ -560,13 +560,18 @@ static int mt6358_put_wov(struct snd_kcontrol *kcontrol,
struct mt6358_priv *priv = snd_soc_component_get_drvdata(c);
int enabled = ucontrol->value.integer.value[0];

if (enabled < 0 || enabled > 1)
return -EINVAL;

if (priv->wov_enabled != enabled) {
if (enabled)
mt6358_enable_wov_phase2(priv);
else
mt6358_disable_wov_phase2(priv);

priv->wov_enabled = enabled;

return 1;
}

return 0;
Expand Down Expand Up @@ -632,9 +637,6 @@ static const char * const hp_in_mux_map[] = {
"Audio Playback",
"Test Mode",
"HP Impedance",
"undefined1",
"undefined2",
"undefined3",
};

static int hp_in_mux_map_value[] = {
Expand All @@ -643,9 +645,6 @@ static int hp_in_mux_map_value[] = {
HP_MUX_HP,
HP_MUX_TEST_MODE,
HP_MUX_HP_IMPEDANCE,
HP_MUX_OPEN,
HP_MUX_OPEN,
HP_MUX_OPEN,
};

static SOC_VALUE_ENUM_SINGLE_DECL(hpl_in_mux_map_enum,
Expand Down

0 comments on commit b201929

Please sign in to comment.