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

Commit 57e66c02 authored by Laxminath Kasam's avatar Laxminath Kasam
Browse files

asoc: wcd937x: Fix compile error in wcd937x codec driver



Update codec to component param for 4.19 kernel compatible.

Change-Id: Ia08283de4b01b45a6cd96c7f488f55bb0d4a5a53
Signed-off-by: default avatarLaxminath Kasam <lkasam@codeaurora.org>
parent ae5dca48
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -1309,7 +1309,7 @@ static int wcd937x_codec_enable_adc(struct snd_soc_dapm_widget *w,
		/* Enable BCS for Headset mic */
		/* Enable BCS for Headset mic */
		if (w->shift == 1 && !(snd_soc_component_read32(component,
		if (w->shift == 1 && !(snd_soc_component_read32(component,
				WCD937X_TX_NEW_TX_CH2_SEL) & 0x80)) {
				WCD937X_TX_NEW_TX_CH2_SEL) & 0x80)) {
			wcd937x_tx_connect_port(codec, MBHC, true);
			wcd937x_tx_connect_port(component, MBHC, true);
			set_bit(AMIC2_BCS_ENABLE, &wcd937x->status_mask);
			set_bit(AMIC2_BCS_ENABLE, &wcd937x->status_mask);
		}
		}
		wcd937x_tx_connect_port(component, ADC1 + (w->shift), true);
		wcd937x_tx_connect_port(component, ADC1 + (w->shift), true);
@@ -1318,7 +1318,7 @@ static int wcd937x_codec_enable_adc(struct snd_soc_dapm_widget *w,
		wcd937x_tx_connect_port(component, ADC1 + (w->shift), false);
		wcd937x_tx_connect_port(component, ADC1 + (w->shift), false);
		if (w->shift == 1 &&
		if (w->shift == 1 &&
			test_bit(AMIC2_BCS_ENABLE, &wcd937x->status_mask)) {
			test_bit(AMIC2_BCS_ENABLE, &wcd937x->status_mask)) {
			wcd937x_tx_connect_port(codec, MBHC, false);
			wcd937x_tx_connect_port(component, MBHC, false);
			clear_bit(AMIC2_BCS_ENABLE, &wcd937x->status_mask);
			clear_bit(AMIC2_BCS_ENABLE, &wcd937x->status_mask);
		}
		}
		snd_soc_component_update_bits(component,
		snd_soc_component_update_bits(component,