Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b23229e4 authored by Mark Brown's avatar Mark Brown
Browse files

Merge remote-tracking branches 'asoc/fix/samsung', 'asoc/fix/tlv320dac33',...

Merge remote-tracking branches 'asoc/fix/samsung', 'asoc/fix/tlv320dac33', 'asoc/fix/wl1273', 'asoc/fix/wm8753', 'asoc/fix/wm8904', 'asoc/fix/wm8958' and 'asoc/fix/wm8983' into asoc-linus
Loading
+4 −5
Original line number Diff line number Diff line
@@ -446,7 +446,7 @@ static int dac33_get_fifo_mode(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct tlv320dac33_priv *dac33 = snd_soc_codec_get_drvdata(codec);

	ucontrol->value.integer.value[0] = dac33->fifo_mode;
	ucontrol->value.enumerated.item[0] = dac33->fifo_mode;

	return 0;
}
@@ -458,17 +458,16 @@ static int dac33_set_fifo_mode(struct snd_kcontrol *kcontrol,
	struct tlv320dac33_priv *dac33 = snd_soc_codec_get_drvdata(codec);
	int ret = 0;

	if (dac33->fifo_mode == ucontrol->value.integer.value[0])
	if (dac33->fifo_mode == ucontrol->value.enumerated.item[0])
		return 0;
	/* Do not allow changes while stream is running*/
	if (snd_soc_codec_is_active(codec))
		return -EPERM;

	if (ucontrol->value.integer.value[0] < 0 ||
	    ucontrol->value.integer.value[0] >= DAC33_FIFO_LAST_MODE)
	if (ucontrol->value.enumerated.item[0] >= DAC33_FIFO_LAST_MODE)
		ret = -EINVAL;
	else
		dac33->fifo_mode = ucontrol->value.integer.value[0];
		dac33->fifo_mode = ucontrol->value.enumerated.item[0];

	return ret;
}
+6 −7
Original line number Diff line number Diff line
@@ -175,7 +175,7 @@ static int snd_wl1273_get_audio_route(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wl1273_priv *wl1273 = snd_soc_codec_get_drvdata(codec);

	ucontrol->value.integer.value[0] = wl1273->mode;
	ucontrol->value.enumerated.item[0] = wl1273->mode;

	return 0;
}
@@ -193,18 +193,17 @@ static int snd_wl1273_set_audio_route(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wl1273_priv *wl1273 = snd_soc_codec_get_drvdata(codec);

	if (wl1273->mode == ucontrol->value.integer.value[0])
	if (wl1273->mode == ucontrol->value.enumerated.item[0])
		return 0;

	/* Do not allow changes while stream is running */
	if (snd_soc_codec_is_active(codec))
		return -EPERM;

	if (ucontrol->value.integer.value[0] < 0 ||
	    ucontrol->value.integer.value[0] >=  ARRAY_SIZE(wl1273_audio_route))
	if (ucontrol->value.enumerated.item[0] >=  ARRAY_SIZE(wl1273_audio_route))
		return -EINVAL;

	wl1273->mode = ucontrol->value.integer.value[0];
	wl1273->mode = ucontrol->value.enumerated.item[0];

	return 1;
}
@@ -219,7 +218,7 @@ static int snd_wl1273_fm_audio_get(struct snd_kcontrol *kcontrol,

	dev_dbg(codec->dev, "%s: enter.\n", __func__);

	ucontrol->value.integer.value[0] = wl1273->core->audio_mode;
	ucontrol->value.enumerated.item[0] = wl1273->core->audio_mode;

	return 0;
}
@@ -233,7 +232,7 @@ static int snd_wl1273_fm_audio_put(struct snd_kcontrol *kcontrol,

	dev_dbg(codec->dev, "%s: enter.\n", __func__);

	val = ucontrol->value.integer.value[0];
	val = ucontrol->value.enumerated.item[0];
	if (wl1273->core->audio_mode == val)
		return 0;

+3 −3
Original line number Diff line number Diff line
@@ -233,7 +233,7 @@ static int wm8753_get_dai(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec);

	ucontrol->value.integer.value[0] = wm8753->dai_func;
	ucontrol->value.enumerated.item[0] = wm8753->dai_func;
	return 0;
}

@@ -244,7 +244,7 @@ static int wm8753_set_dai(struct snd_kcontrol *kcontrol,
	struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec);
	u16 ioctl;

	if (wm8753->dai_func == ucontrol->value.integer.value[0])
	if (wm8753->dai_func == ucontrol->value.enumerated.item[0])
		return 0;

	if (snd_soc_codec_is_active(codec))
@@ -252,7 +252,7 @@ static int wm8753_set_dai(struct snd_kcontrol *kcontrol,

	ioctl = snd_soc_read(codec, WM8753_IOCTL);

	wm8753->dai_func = ucontrol->value.integer.value[0];
	wm8753->dai_func = ucontrol->value.enumerated.item[0];

	if (((ioctl >> 2) & 0x3) == wm8753->dai_func)
		return 1;
+2 −2
Original line number Diff line number Diff line
@@ -396,7 +396,7 @@ static int wm8904_put_drc_enum(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8904_priv *wm8904 = snd_soc_codec_get_drvdata(codec);
	struct wm8904_pdata *pdata = wm8904->pdata;
	int value = ucontrol->value.integer.value[0];
	int value = ucontrol->value.enumerated.item[0];

	if (value >= pdata->num_drc_cfgs)
		return -EINVAL;
@@ -467,7 +467,7 @@ static int wm8904_put_retune_mobile_enum(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8904_priv *wm8904 = snd_soc_codec_get_drvdata(codec);
	struct wm8904_pdata *pdata = wm8904->pdata;
	int value = ucontrol->value.integer.value[0];
	int value = ucontrol->value.enumerated.item[0];

	if (value >= pdata->num_retune_mobile_cfgs)
		return -EINVAL;
+4 −4
Original line number Diff line number Diff line
@@ -459,7 +459,7 @@ static int wm8958_put_mbc_enum(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8994_priv *wm8994 = snd_soc_codec_get_drvdata(codec);
	struct wm8994 *control = wm8994->wm8994;
	int value = ucontrol->value.integer.value[0];
	int value = ucontrol->value.enumerated.item[0];
	int reg;

	/* Don't allow on the fly reconfiguration */
@@ -549,7 +549,7 @@ static int wm8958_put_vss_enum(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8994_priv *wm8994 = snd_soc_codec_get_drvdata(codec);
	struct wm8994 *control = wm8994->wm8994;
	int value = ucontrol->value.integer.value[0];
	int value = ucontrol->value.enumerated.item[0];
	int reg;

	/* Don't allow on the fly reconfiguration */
@@ -582,7 +582,7 @@ static int wm8958_put_vss_hpf_enum(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8994_priv *wm8994 = snd_soc_codec_get_drvdata(codec);
	struct wm8994 *control = wm8994->wm8994;
	int value = ucontrol->value.integer.value[0];
	int value = ucontrol->value.enumerated.item[0];
	int reg;

	/* Don't allow on the fly reconfiguration */
@@ -749,7 +749,7 @@ static int wm8958_put_enh_eq_enum(struct snd_kcontrol *kcontrol,
	struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
	struct wm8994_priv *wm8994 = snd_soc_codec_get_drvdata(codec);
	struct wm8994 *control = wm8994->wm8994;
	int value = ucontrol->value.integer.value[0];
	int value = ucontrol->value.enumerated.item[0];
	int reg;

	/* Don't allow on the fly reconfiguration */
Loading