diff options
author | Mark Brown <broonie@kernel.org> | 2018-10-21 16:59:23 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-10-21 16:59:23 +0100 |
commit | 65dfb6d6dd2850f3f99f08536d2b14190350c854 (patch) | |
tree | e8b0468b3e4d4d54dbea68c9ffce9fd8648be2aa /sound/soc/mediatek/mt2701/mt2701-wm8960.c | |
parent | 576b354ac25b544a31f27c365410d59fcbfee064 (diff) | |
parent | 7f91e2af1a4a2c34fc2e8fb046c722e1a9c85399 (diff) | |
download | talos-obmc-linux-65dfb6d6dd2850f3f99f08536d2b14190350c854.tar.gz talos-obmc-linux-65dfb6d6dd2850f3f99f08536d2b14190350c854.zip |
Merge branch 'asoc-4.20' into asoc-next
Diffstat (limited to 'sound/soc/mediatek/mt2701/mt2701-wm8960.c')
-rw-r--r-- | sound/soc/mediatek/mt2701/mt2701-wm8960.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sound/soc/mediatek/mt2701/mt2701-wm8960.c b/sound/soc/mediatek/mt2701/mt2701-wm8960.c index 89f34efd9747..6bc1d3d58e64 100644 --- a/sound/soc/mediatek/mt2701/mt2701-wm8960.c +++ b/sound/soc/mediatek/mt2701/mt2701-wm8960.c @@ -97,6 +97,7 @@ static int mt2701_wm8960_machine_probe(struct platform_device *pdev) { struct snd_soc_card *card = &mt2701_wm8960_card; struct device_node *platform_node, *codec_node; + struct snd_soc_dai_link *dai_link; int ret, i; platform_node = of_parse_phandle(pdev->dev.of_node, @@ -105,10 +106,10 @@ static int mt2701_wm8960_machine_probe(struct platform_device *pdev) dev_err(&pdev->dev, "Property 'platform' missing or invalid\n"); return -EINVAL; } - for (i = 0; i < card->num_links; i++) { - if (mt2701_wm8960_dai_links[i].platform_name) + for_each_card_prelinks(card, i, dai_link) { + if (dai_link->platform_name) continue; - mt2701_wm8960_dai_links[i].platform_of_node = platform_node; + dai_link->platform_of_node = platform_node; } card->dev = &pdev->dev; @@ -120,10 +121,10 @@ static int mt2701_wm8960_machine_probe(struct platform_device *pdev) "Property 'audio-codec' missing or invalid\n"); return -EINVAL; } - for (i = 0; i < card->num_links; i++) { - if (mt2701_wm8960_dai_links[i].codec_name) + for_each_card_prelinks(card, i, dai_link) { + if (dai_link->codec_name) continue; - mt2701_wm8960_dai_links[i].codec_of_node = codec_node; + dai_link->codec_of_node = codec_node; } ret = snd_soc_of_parse_audio_routing(card, "audio-routing"); @@ -150,7 +151,6 @@ static const struct of_device_id mt2701_wm8960_machine_dt_match[] = { static struct platform_driver mt2701_wm8960_machine = { .driver = { .name = "mt2701-wm8960", - .owner = THIS_MODULE, #ifdef CONFIG_OF .of_match_table = mt2701_wm8960_machine_dt_match, #endif |