ASoC: don't dereference NULL pcm_{new,free}
authorBrian Norris <briannorris@chromium.org>
Wed, 8 Mar 2017 23:18:54 +0000 (15:18 -0800)
committerMark Brown <broonie@kernel.org>
Thu, 9 Mar 2017 11:34:17 +0000 (12:34 +0100)
commitd6c098a1db468b7fd4635e831f276851dfd8852c
treeaf3ae09b6c0b16bb6bfcaeff38b3d4799cbe5629
parentc1ae3cfa0e89fa1a7ecc4c99031f5e9ae99d9201
ASoC: don't dereference NULL pcm_{new,free}

Not all platform drivers have pcm_{new,free} callbacks. Seen with a
"snd-soc-dummy" codec from sound/soc/rockchip/rk3399_gru_sound.c.

Fixes: 99b04f4c4051 ("ASoC: add Component level pcm_new/pcm_free")
Signed-off-by: Brian Norris <briannorris@chromium.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/soc-core.c