Browse Source

asoc: use BIAS_LEVEL_OFF for LPM trigger

Use BIAS_LEVEL_OFF trigger from ASoC to mark the wcd/wsa power
supplies to LPM (if supported).

Change-Id: I89f232f9338168b99ae03f84318c21734b592f82
Signed-off-by: Prasad Kumpatla <quic_pkumpatl@quicinc.com>
Prasad Kumpatla 2 years ago
parent
commit
5d647662c7
1 changed files with 3 additions and 1 deletions
  1. 3 1
      asoc/codecs/wcd939x/wcd939x.c

+ 3 - 1
asoc/codecs/wcd939x/wcd939x.c

@@ -4482,7 +4482,9 @@ static int wcd939x_suspend(struct device *dev)
 		}
 		clear_bit(ALLOW_BUCK_DISABLE, &wcd939x->status_mask);
 	}
-	if (wcd939x->dapm_bias_off) {
+	if (wcd939x->dapm_bias_off ||
+		(snd_soc_component_get_bias_level(wcd939x->component) ==
+		SND_SOC_BIAS_OFF)) {
 		msm_cdc_set_supplies_lpm_mode(wcd939x->dev,
 					      wcd939x->supplies,
 					      pdata->regulator,