diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2021-02-22 01:47:26 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-03-10 14:06:46 +0100 |
commit | 5f53898af1a2bf753f111ec1c7ed668fe6557b76 (patch) | |
tree | cecba03cb233d66c4d09b1d3ef64d208842bbb8c /crypto | |
parent | ASoC: soc-pcm: unpack dpcm_init_runtime_hw() (diff) | |
download | linux-5f53898af1a2bf753f111ec1c7ed668fe6557b76.tar.xz linux-5f53898af1a2bf753f111ec1c7ed668fe6557b76.zip |
ASoC: soc-pcm: add dpcm_runtime_setup_fe()
dpcm_fe_dai_startup() (= A) calls dpcm_set_fe_runtime() (= B) to setup
DPCM runtime. From *naming point of view*, it sounds like setup function
for FE.
(A) static int dpcm_fe_dai_startup(...)
{
...
(B) dpcm_set_fe_runtime(...);
...
}
But in dpcm_set_fe_runtime() (= B),
It setups FE by for_each loop (= X),
and setups BE by dpcm_runtime_merge_xxx() (= Y).
(B) static void dpcm_set_fe_runtime(...)
{
...
^ for_each_rtd_cpu_dais(...) {
| ...
(X) soc_pcm_hw_update_rate(...);
| soc_pcm_hw_update_chan(...);
| soc_pcm_hw_update_format(...);
v }
^ dpcm_runtime_merge_format(...);
(Y) dpcm_runtime_merge_chan(...);
v dpcm_runtime_merge_rate(...);
}
These means that the function which is called as xxx_fe_xxx()
is setups both FE and BE. This is confusable and can be hot bed for bug.
To tidyup it, as 1st step, this patch adds new dpcm_runtime_setup_fe()
for (X).
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87pn0tvsgx.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'crypto')
0 files changed, 0 insertions, 0 deletions