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

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

Merge "ASoC: msm8x16-wcd: remove pdm and mclk disable for tx path"

parents eb978953 fbee6e07
Loading
Loading
Loading
Loading
+2 −23
Original line number Diff line number Diff line
/* Copyright (c) 2014, The Linux Foundation. All rights reserved.
/* Copyright (c) 2014-2015, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -1953,27 +1953,6 @@ static int msm8x16_wcd_codec_enable_spk_pa(struct snd_soc_dapm_widget *w,
	return 0;
}

static int msm8x16_wcd_tx_disable_pdm_clk(struct snd_soc_dapm_widget *w,
				struct snd_kcontrol *kcontrol, int event)
{
	struct snd_soc_codec *codec = w->codec;
	struct msm8916_asoc_mach_data *pdata = NULL;

	pdata = snd_soc_card_get_drvdata(codec->card);

	dev_dbg(w->codec->dev, "%s event %d w->name %s\n", __func__,
			event, w->name);
	switch (event) {
	case SND_SOC_DAPM_POST_PMD:
		if (atomic_read(&pdata->mclk_rsc_ref) == 0)
			snd_soc_update_bits(codec,
				MSM8X16_WCD_A_CDC_CLK_PDM_CTL,
				0x03, 0x00);
		break;
	}
	return 0;
}

static int msm8x16_wcd_codec_enable_dig_clk(struct snd_soc_dapm_widget *w,
				     struct snd_kcontrol *kcontrol, int event)
{
@@ -3526,7 +3505,7 @@ static const struct snd_soc_dapm_widget msm8x16_wcd_dapm_widgets[] = {
		MSM8X16_WCD_A_CDC_CLK_RX_I2S_CTL,	4, 0, NULL, 0),
	SND_SOC_DAPM_SUPPLY("TX_I2S_CLK",
		MSM8X16_WCD_A_CDC_CLK_TX_I2S_CTL, 4, 0,
		msm8x16_wcd_tx_disable_pdm_clk, SND_SOC_DAPM_POST_PMD),
		NULL, 0),
};

static const struct msm8x16_wcd_reg_mask_val msm8x16_wcd_reg_defaults[] = {