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

Commit b36abb19 authored by Ben Romberger's avatar Ben Romberger Committed by Gerrit - the friendly Code Review server
Browse files

ASoC: msm: On set FB spkr prot check new mode.



When FB spkr. prot. calibration is set check
the mode flag received from userspace instead
of the stale mode in the local structure.

Change-Id: I4fa2074d19a1c8eb1341eaca5405d4183ea9f848
Signed-off-by: default avatarBen Romberger <bromberg@codeaurora.org>
parent 4c5e5900
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -4658,7 +4658,7 @@ static int afe_set_cal_fb_spkr_prot(int32_t cal_type, size_t data_size,
	if (data_size != sizeof(*cal_data))
		goto done;

	if (this_afe.prot_cfg.mode == MSM_SPKR_PROT_CALIBRATION_IN_PROGRESS)
	if (cal_data->cal_info.mode == MSM_SPKR_PROT_CALIBRATION_IN_PROGRESS)
		__pm_wakeup_event(&wl.ws, jiffies_to_msecs(WAKELOCK_TIMEOUT));
	mutex_lock(&this_afe.cal_data[AFE_FB_SPKR_PROT_CAL]->lock);
	memcpy(&this_afe.prot_cfg, &cal_data->cal_info,