Commit a1cd7e80 authored by Kuninori Morimoto's avatar Kuninori Morimoto Committed by Mark Brown

ASoC: audio-graph-card2: switch to use c2c_params instead of params

ASoC is now using c2c_params instead of params. This patch replace it.
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87mt3pc2la.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 7ddc7f91
...@@ -920,8 +920,8 @@ int audio_graph2_link_c2c(struct asoc_simple_priv *priv, ...@@ -920,8 +920,8 @@ int audio_graph2_link_c2c(struct asoc_simple_priv *priv,
c2c_conf->channels_min = c2c_conf->channels_min =
c2c_conf->channels_max = 2; /* update ME */ c2c_conf->channels_max = 2; /* update ME */
dai_link->params = c2c_conf; dai_link->c2c_params = c2c_conf;
dai_link->num_params = 1; dai_link->num_c2c_params = 1;
} }
ep0 = port_to_endpoint(port0); ep0 = port_to_endpoint(port0);
......
...@@ -562,12 +562,12 @@ static int asoc_simple_init_for_codec2codec(struct snd_soc_pcm_runtime *rtd, ...@@ -562,12 +562,12 @@ static int asoc_simple_init_for_codec2codec(struct snd_soc_pcm_runtime *rtd,
{ {
struct snd_soc_dai_link *dai_link = rtd->dai_link; struct snd_soc_dai_link *dai_link = rtd->dai_link;
struct snd_soc_component *component; struct snd_soc_component *component;
struct snd_soc_pcm_stream *params; struct snd_soc_pcm_stream *c2c_params;
struct snd_pcm_hardware hw; struct snd_pcm_hardware hw;
int i, ret, stream; int i, ret, stream;
/* Do nothing if it already has Codec2Codec settings */ /* Do nothing if it already has Codec2Codec settings */
if (dai_link->params) if (dai_link->c2c_params)
return 0; return 0;
/* Do nothing if it was DPCM :: BE */ /* Do nothing if it was DPCM :: BE */
...@@ -592,19 +592,19 @@ static int asoc_simple_init_for_codec2codec(struct snd_soc_pcm_runtime *rtd, ...@@ -592,19 +592,19 @@ static int asoc_simple_init_for_codec2codec(struct snd_soc_pcm_runtime *rtd,
return ret; return ret;
} }
params = devm_kzalloc(rtd->dev, sizeof(*params), GFP_KERNEL); c2c_params = devm_kzalloc(rtd->dev, sizeof(*c2c_params), GFP_KERNEL);
if (!params) if (!c2c_params)
return -ENOMEM; return -ENOMEM;
params->formats = hw.formats; c2c_params->formats = hw.formats;
params->rates = hw.rates; c2c_params->rates = hw.rates;
params->rate_min = hw.rate_min; c2c_params->rate_min = hw.rate_min;
params->rate_max = hw.rate_max; c2c_params->rate_max = hw.rate_max;
params->channels_min = hw.channels_min; c2c_params->channels_min = hw.channels_min;
params->channels_max = hw.channels_max; c2c_params->channels_max = hw.channels_max;
dai_link->params = params; dai_link->c2c_params = c2c_params;
dai_link->num_params = 1; dai_link->num_c2c_params = 1;
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment