summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2016-12-12 15:52:43 +0000
committerMark Brown <broonie@kernel.org>2016-12-12 15:52:43 +0000
commit3f1b86139e94289289b00f745cc483b1fef5fd46 (patch)
tree884013efb30895984e9b37749851de3b2b796b0d /sound
parent66f89906f07e102aece00b80d99f6e1039529bc6 (diff)
parent06859fca4368c407d4acccf3948b8b825db5e569 (diff)
downloadlinux-3f1b86139e94289289b00f745cc483b1fef5fd46.tar.bz2
Merge remote-tracking branch 'asoc/topic/core' into asoc-next
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/soc-core.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
index f35ec5bf3b78..7c3bf160a1a1 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
@@ -993,6 +993,7 @@ static int soc_bind_dai_link(struct snd_soc_card *card,
struct snd_soc_dai_link_component cpu_dai_component;
struct snd_soc_dai **codec_dais;
struct snd_soc_platform *platform;
+ struct device_node *platform_of_node;
const char *platform_name;
int i;
@@ -1042,9 +1043,12 @@ static int soc_bind_dai_link(struct snd_soc_card *card,
/* find one from the set of registered platforms */
list_for_each_entry(platform, &platform_list, list) {
+ platform_of_node = platform->dev->of_node;
+ if (!platform_of_node && platform->dev->parent->of_node)
+ platform_of_node = platform->dev->parent->of_node;
+
if (dai_link->platform_of_node) {
- if (platform->dev->of_node !=
- dai_link->platform_of_node)
+ if (platform_of_node != dai_link->platform_of_node)
continue;
} else {
if (strcmp(platform->component.name, platform_name))