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

Commit f85a40b2 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ASoC: wcd9320: Fix for VI feedback underflow errors"

parents 8d900e0f ebf640f5
Loading
Loading
Loading
Loading
+18 −1
Original line number Original line Diff line number Diff line
@@ -2220,6 +2220,8 @@ static const struct snd_kcontrol_new lineout4_ground_switch =
static const struct snd_kcontrol_new aif4_mad_switch =
static const struct snd_kcontrol_new aif4_mad_switch =
	SOC_DAPM_SINGLE("Switch", TAIKO_A_CDC_CLK_OTHR_CTL, 4, 1, 0);
	SOC_DAPM_SINGLE("Switch", TAIKO_A_CDC_CLK_OTHR_CTL, 4, 1, 0);


static const struct snd_kcontrol_new aif4_vi_switch =
	SOC_DAPM_SINGLE("Switch", TAIKO_A_SPKR_PROT_EN, 3, 1, 0);
/* virtual port entries */
/* virtual port entries */
static int slim_tx_mixer_get(struct snd_kcontrol *kcontrol,
static int slim_tx_mixer_get(struct snd_kcontrol *kcontrol,
			     struct snd_ctl_elem_value *ucontrol)
			     struct snd_ctl_elem_value *ucontrol)
@@ -3677,7 +3679,9 @@ static const struct snd_soc_dapm_route audio_map[] = {
	{"AIF1 CAP", NULL, "AIF1_CAP Mixer"},
	{"AIF1 CAP", NULL, "AIF1_CAP Mixer"},
	{"AIF2 CAP", NULL, "AIF2_CAP Mixer"},
	{"AIF2 CAP", NULL, "AIF2_CAP Mixer"},
	{"AIF3 CAP", NULL, "AIF3_CAP Mixer"},
	{"AIF3 CAP", NULL, "AIF3_CAP Mixer"},
	{"AIF4 VI", NULL, "SPK_OUT"},
	/* VI Feedback */
	{"AIF4 VI", NULL, "VIONOFF"},
	{"VIONOFF", "Switch", "VIINPUT"},


	/* MAD */
	/* MAD */
	{"AIF4 MAD", NULL, "CDC_CONN"},
	{"AIF4 MAD", NULL, "CDC_CONN"},
@@ -5356,6 +5360,15 @@ static int taiko_codec_enable_slimvi_feedback(struct snd_soc_dapm_widget *w,
		if (ret)
		if (ret)
			pr_err("%s error in close_slim_sch_tx %d\n",
			pr_err("%s error in close_slim_sch_tx %d\n",
				__func__, ret);
				__func__, ret);
		ret = taiko_codec_enable_slim_chmask(dai, false);
		if (ret < 0) {
			ret = wcd9xxx_disconnect_port(core,
						      &dai->wcd9xxx_ch_list,
						      dai->grph);
			pr_debug("%s: Disconnect RX port, ret = %d\n",
				 __func__, ret);
		}

		snd_soc_update_bits(codec, TAIKO_A_CDC_CLK_TX_CLK_EN_B2_CTL,
		snd_soc_update_bits(codec, TAIKO_A_CDC_CLK_TX_CLK_EN_B2_CTL,
				0xC, 0x0);
				0xC, 0x0);
		/*Disable V&I sensing*/
		/*Disable V&I sensing*/
@@ -6047,6 +6060,10 @@ static const struct snd_soc_dapm_widget taiko_dapm_widgets[] = {


	SND_SOC_DAPM_MIXER("LINEOUT4_PA_MIXER", SND_SOC_NOPM, 0, 0,
	SND_SOC_DAPM_MIXER("LINEOUT4_PA_MIXER", SND_SOC_NOPM, 0, 0,
		lineout4_pa_mix, ARRAY_SIZE(lineout4_pa_mix)),
		lineout4_pa_mix, ARRAY_SIZE(lineout4_pa_mix)),
	SND_SOC_DAPM_SWITCH("VIONOFF", SND_SOC_NOPM, 0, 0,
			    &aif4_vi_switch),
	SND_SOC_DAPM_INPUT("VIINPUT"),

};
};


static irqreturn_t taiko_slimbus_irq(int irq, void *data)
static irqreturn_t taiko_slimbus_irq(int irq, void *data)