diff options
| author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2025-11-11 00:23:40 +0000 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2025-11-17 00:15:37 +0000 |
| commit | 46fb094b54c89ddf314f7e807e5457be9b185bbc (patch) | |
| tree | d6adfc78be4f3d39676c7d9e530bfe754ba5d48f | |
| parent | a7ab96cf1366f2e35d05b1e773db2a4c1b5e4a45 (diff) | |
ASoC: codecs: max9867: convert to snd_soc_dapm_xxx()
This patch converts below functions.
dapm->dev -> snd_soc_dapm_to_dev()
dapm->card -> snd_soc_dapm_to_card()
dapm->component -> snd_soc_dapm_to_component()
dapm_kcontrol_get_value() -> snd_soc_dapm_kcontrol_get_value()
snd_soc_component_enable_pin() -> snd_soc_dapm_enable_pin()
snd_soc_component_enable_pin_unlocked() -> snd_soc_dapm_enable_pin_unlocked()
snd_soc_component_disable_pin() -> snd_soc_dapm_disable_pin()
snd_soc_component_disable_pin_unlocked() -> snd_soc_dapm_disable_pin_unlocked()
snd_soc_component_nc_pin() -> snd_soc_dapm_nc_pin()
snd_soc_component_nc_pin_unlocked() -> snd_soc_dapm_nc_pin_unlocked()
snd_soc_component_get_pin_status() -> snd_soc_dapm_get_pin_status()
snd_soc_component_force_enable_pin() -> snd_soc_dapm_force_enable_pin()
snd_soc_component_force_enable_pin_unlocked() -> snd_soc_dapm_force_enable_pin_unlocked()
snd_soc_component_force_bias_level() -> snd_soc_dapm_force_bias_level()
snd_soc_component_get_bias_level() -> snd_soc_dapm_get_bias_level()
snd_soc_component_init_bias_level() -> snd_soc_dapm_init_bias_level()
snd_soc_component_get_dapm() -> snd_soc_component_to_dapm()
snd_soc_dapm_kcontrol_component() -> snd_soc_dapm_kcontrol_to_component()
snd_soc_dapm_kcontrol_widget() -> snd_soc_dapm_kcontrol_to_widget()
snd_soc_dapm_kcontrol_dapm() -> snd_soc_dapm_kcontrol_to_dapm()
snd_soc_dapm_np_pin() -> snd_soc_dapm_disable_pin()
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://patch.msgid.link/87v7jh4dtf.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
| -rw-r--r-- | sound/soc/codecs/max9867.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/sound/soc/codecs/max9867.c b/sound/soc/codecs/max9867.c index 35ec9c1b18f9..9cad9b698cf2 100644 --- a/sound/soc/codecs/max9867.c +++ b/sound/soc/codecs/max9867.c @@ -556,14 +556,18 @@ static struct snd_soc_dai_driver max9867_dai[] = { #ifdef CONFIG_PM static int max9867_suspend(struct snd_soc_component *component) { - snd_soc_component_force_bias_level(component, SND_SOC_BIAS_OFF); + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(component); + + snd_soc_dapm_force_bias_level(dapm, SND_SOC_BIAS_OFF); return 0; } static int max9867_resume(struct snd_soc_component *component) { - snd_soc_component_force_bias_level(component, SND_SOC_BIAS_STANDBY); + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(component); + + snd_soc_dapm_force_bias_level(dapm, SND_SOC_BIAS_STANDBY); return 0; } @@ -577,6 +581,7 @@ static int max9867_set_bias_level(struct snd_soc_component *component, { int err; struct max9867_priv *max9867 = snd_soc_component_get_drvdata(component); + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(component); switch (level) { case SND_SOC_BIAS_ON: @@ -585,7 +590,7 @@ static int max9867_set_bias_level(struct snd_soc_component *component, return err; break; case SND_SOC_BIAS_STANDBY: - if (snd_soc_component_get_bias_level(component) == SND_SOC_BIAS_OFF) { + if (snd_soc_dapm_get_bias_level(dapm) == SND_SOC_BIAS_OFF) { err = regcache_sync(max9867->regmap); if (err) return err; |