From cd0f8911c5d0cc04763f87cf118c66b867e2e6d2 Mon Sep 17 00:00:00 2001 From: Liam Girdwood Date: Mon, 30 Apr 2012 11:05:30 +0100 Subject: [PATCH] ASoC: core: Fix dai_link dereference. We should check dailess before dereferencing. Reported-by: Dan Carpenter Signed-off-by: Liam Girdwood Signed-off-by: Mark Brown --- sound/soc/soc-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 4d8869852ad6..a61671b89e9b 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -1218,7 +1218,7 @@ static int soc_post_component_init(struct snd_soc_card *card, #ifdef CONFIG_DEBUG_FS /* add DPCM sysfs entries */ - if (!dai_link->dynamic) + if (!dailess && !dai_link->dynamic) goto out; ret = soc_dpcm_debugfs_add(rtd); -- 2.20.1