Skip to content

Commit b201929

Browse files
committed
ASoC: mt6358: Fixes from an initial glance at a
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.
2 parents e3e3299 + 8cbd727 commit b201929

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

sound/soc/codecs/mt6358.c

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -560,13 +560,18 @@ static int mt6358_put_wov(struct snd_kcontrol *kcontrol,
560560
struct mt6358_priv *priv = snd_soc_component_get_drvdata(c);
561561
int enabled = ucontrol->value.integer.value[0];
562562

563+
if (enabled < 0 || enabled > 1)
564+
return -EINVAL;
565+
563566
if (priv->wov_enabled != enabled) {
564567
if (enabled)
565568
mt6358_enable_wov_phase2(priv);
566569
else
567570
mt6358_disable_wov_phase2(priv);
568571

569572
priv->wov_enabled = enabled;
573+
574+
return 1;
570575
}
571576

572577
return 0;
@@ -632,9 +637,6 @@ static const char * const hp_in_mux_map[] = {
632637
"Audio Playback",
633638
"Test Mode",
634639
"HP Impedance",
635-
"undefined1",
636-
"undefined2",
637-
"undefined3",
638640
};
639641

640642
static int hp_in_mux_map_value[] = {
@@ -643,9 +645,6 @@ static int hp_in_mux_map_value[] = {
643645
HP_MUX_HP,
644646
HP_MUX_TEST_MODE,
645647
HP_MUX_HP_IMPEDANCE,
646-
HP_MUX_OPEN,
647-
HP_MUX_OPEN,
648-
HP_MUX_OPEN,
649648
};
650649

651650
static SOC_VALUE_ENUM_SINGLE_DECL(hpl_in_mux_map_enum,

0 commit comments

Comments
 (0)