Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: codecs: jz4760: 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/87h5v15sfc.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Kuninori Morimoto and committed by
Mark Brown
f7e9d040 f4435734

+4 -3
+4 -3
sound/soc/codecs/jz4760.c
··· 197 197 struct snd_soc_dai *dai) 198 198 { 199 199 struct snd_soc_component *codec = dai->component; 200 - struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(codec); 200 + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(codec); 201 201 int ret = 0; 202 202 203 203 /* ··· 214 214 struct snd_soc_dai *dai) 215 215 { 216 216 struct snd_soc_component *codec = dai->component; 217 - struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(codec); 217 + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(codec); 218 218 219 219 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) 220 220 snd_soc_dapm_disable_pin(dapm, "SYSCLK"); ··· 225 225 int cmd, struct snd_soc_dai *dai) 226 226 { 227 227 struct snd_soc_component *codec = dai->component; 228 + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(codec); 228 229 int ret = 0; 229 230 230 231 switch (cmd) { ··· 233 232 case SNDRV_PCM_TRIGGER_RESUME: 234 233 case SNDRV_PCM_TRIGGER_PAUSE_RELEASE: 235 234 if (substream->stream != SNDRV_PCM_STREAM_PLAYBACK) 236 - snd_soc_component_force_bias_level(codec, SND_SOC_BIAS_ON); 235 + snd_soc_dapm_force_bias_level(dapm, SND_SOC_BIAS_ON); 237 236 break; 238 237 case SNDRV_PCM_TRIGGER_STOP: 239 238 case SNDRV_PCM_TRIGGER_SUSPEND: