ASoC: soc-pcm: cleanup dpcm_dai_trigger_fe_be()
DPCM is already difficult to read, but now dpcm_dai_trigger_fe_be() even
difficult to read.
static int dpcm_dai_trigger_fe_be(.., fe_first)
{
^ if (fe_first) {
(A) ...
|(x) goto end;
v }
^
(B) ...
v
end:
return ...
}
It want to switch function call order by using "fe_first" for fe->be
order part (A), or be->fe order part (B). But the code is using "goto"
in last of (A) (=x).
Just use "if..else" for (A) (B) is easy to read and understand what it
want to do.
static int dpcm_dai_trigger_fe_be(.., fe_first)
{
^ if (fe_first) {
(A) ...
v }
^ else {
(B) ...
v }
return ...
}
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://patch.msgid.link/87ikpfyjyo.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>