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

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

Merge "ASoC: wcd9xxx: Avoid enabling button polling from event notify handler"

parents 4f5fadc7 2426d927
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -188,7 +188,7 @@ static void wcd9xxx_mbhc_calc_thres(struct wcd9xxx_mbhc *mbhc);

static bool wcd9xxx_mbhc_polling(struct wcd9xxx_mbhc *mbhc)
{
	return mbhc->polling_active;
	return snd_soc_read(mbhc->codec, WCD9XXX_A_CDC_MBHC_EN_CTL) & 0x1;
}

static void wcd9xxx_turn_onoff_override(struct wcd9xxx_mbhc *mbhc, bool on)
@@ -542,13 +542,13 @@ static void wcd9xxx_codec_switch_cfilt_mode(struct wcd9xxx_mbhc *mbhc,

	if (cfilt_mode.cur_mode_val
			!= cfilt_mode.reg_mode_val) {
		if (mbhc->polling_active)
		if (mbhc->polling_active && wcd9xxx_mbhc_polling(mbhc))
			wcd9xxx_pause_hs_polling(mbhc);
		snd_soc_update_bits(codec,
				    mbhc->mbhc_bias_regs.cfilt_ctl,
					cfilt_mode.reg_mask,
					cfilt_mode.reg_mode_val);
		if (mbhc->polling_active)
		if (mbhc->polling_active && wcd9xxx_mbhc_polling(mbhc))
			wcd9xxx_start_hs_polling(mbhc);
		pr_debug("%s: CFILT mode change (%x to %x)\n", __func__,
			cfilt_mode.cur_mode_val,