diff options
| author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2025-11-11 03:37:07 +0300 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2025-11-17 03:18:43 +0300 |
| commit | 9b5a1d32da7e343e8fbdfbc536770544551ef59b (patch) | |
| tree | 8c4f2b1272da65b275a30d7acaca759bddb09d9f | |
| parent | a3fc90c52ad0d525918aa5039cb07d937dc1d841 (diff) | |
| download | linux-9b5a1d32da7e343e8fbdfbc536770544551ef59b.tar.xz | |
ASoC: ti: n810: 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/87tsz1s8ul.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
| -rw-r--r-- | sound/soc/ti/n810.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/sound/soc/ti/n810.c b/sound/soc/ti/n810.c index 345c98765380..242b07034816 100644 --- a/sound/soc/ti/n810.c +++ b/sound/soc/ti/n810.c @@ -85,10 +85,11 @@ static int n810_startup(struct snd_pcm_substream *substream) { struct snd_pcm_runtime *runtime = substream->runtime; struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream); + struct snd_soc_dapm_context *dapm = snd_soc_card_to_dapm(rtd->card); snd_pcm_hw_constraint_single(runtime, SNDRV_PCM_HW_PARAM_CHANNELS, 2); - n810_ext_control(&rtd->card->dapm); + n810_ext_control(dapm); return clk_prepare_enable(sys_clkout2); } @@ -129,12 +130,13 @@ static int n810_set_spk(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) { struct snd_soc_card *card = snd_kcontrol_chip(kcontrol); + struct snd_soc_dapm_context *dapm = snd_soc_card_to_dapm(card); if (n810_spk_func == ucontrol->value.enumerated.item[0]) return 0; n810_spk_func = ucontrol->value.enumerated.item[0]; - n810_ext_control(&card->dapm); + n810_ext_control(dapm); return 1; } @@ -151,12 +153,13 @@ static int n810_set_jack(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) { struct snd_soc_card *card = snd_kcontrol_chip(kcontrol); + struct snd_soc_dapm_context *dapm = snd_soc_card_to_dapm(card); if (n810_jack_func == ucontrol->value.enumerated.item[0]) return 0; n810_jack_func = ucontrol->value.enumerated.item[0]; - n810_ext_control(&card->dapm); + n810_ext_control(dapm); return 1; } @@ -173,12 +176,13 @@ static int n810_set_input(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol) { struct snd_soc_card *card = snd_kcontrol_chip(kcontrol); + struct snd_soc_dapm_context *dapm = snd_soc_card_to_dapm(card); if (n810_dmic_func == ucontrol->value.enumerated.item[0]) return 0; n810_dmic_func = ucontrol->value.enumerated.item[0]; - n810_ext_control(&card->dapm); + n810_ext_control(dapm); return 1; } |
