]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: add null_snd_soc_ops and reduce NULL ops check
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Tue, 26 Sep 2017 00:40:42 +0000 (00:40 +0000)
committerMark Brown <broonie@kernel.org>
Tue, 26 Sep 2017 16:19:33 +0000 (09:19 -0700)
commit506b9f999e672254a899682f1ac940e83625b28e
tree22a53174bcd06a07710e8c17f521017f21a03994
parent9375b1243b18a593ca98359a6f2393f9de324156
ASoC: add null_snd_soc_ops and reduce NULL ops check

Double NULL pointer check for ops and ops->func is difficult to read
and might be forget to check it if new func was add.
This patch adds new null_snd_soc_ops and use it if rtd->dai_link didn't
have it to avoid NULL ops, and reduces ops NULL check.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/soc-core.c
sound/soc/soc-pcm.c