mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 21:59:12 -04:00
ASoC: wsa883x: Avoid temperature read during playback
Avoid reading temperature during playback usecase. Change-Id: If471e19ea0ca5856d17f694ce084145d7132e365 Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
This commit is contained in:
parent
d187ddf230
commit
aea784377c
1 changed files with 6 additions and 1 deletions
|
|
@ -599,9 +599,14 @@ static int wsa_get_temp(struct snd_kcontrol *kcontrol,
|
|||
{
|
||||
struct snd_soc_component *component =
|
||||
snd_soc_kcontrol_component(kcontrol);
|
||||
struct wsa883x_priv *wsa883x = snd_soc_component_get_drvdata(component);
|
||||
int temp = 0;
|
||||
|
||||
wsa883x_get_temperature(component, &temp);
|
||||
if (test_bit(SPKR_STATUS, &wsa883x->status_mask))
|
||||
temp = wsa883x->curr_temp;
|
||||
else
|
||||
wsa883x_get_temperature(component, &temp);
|
||||
|
||||
ucontrol->value.integer.value[0] = temp;
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue