X-Git-Url: http://git.cascardo.eti.br/?a=blobdiff_plain;f=sound%2Fsoc%2Fsoc-core.c;h=4afa8dba5e982f664b1a214226688c50dfee1212;hb=e8f0f8aa4eb356bd729f15be8827db2558ea1ae6;hp=16369cad480388c326f2463273e17ebef0324924;hpb=99eb45f98c1355998bc2b0bd83e51f79e6d2d0b4;p=cascardo%2Flinux.git diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 16369cad4803..4afa8dba5e98 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -1056,7 +1056,7 @@ static int soc_bind_dai_link(struct snd_soc_card *card, if (!rtd->platform) { dev_err(card->dev, "ASoC: platform %s not registered\n", dai_link->platform_name); - return -EPROBE_DEFER; + goto _err_defer; } soc_add_pcm_runtime(card, rtd); @@ -2083,14 +2083,13 @@ static int soc_cleanup_card_resources(struct snd_soc_card *card) /* remove auxiliary devices */ soc_remove_aux_devices(card); + snd_soc_dapm_free(&card->dapm); soc_cleanup_card_debugfs(card); /* remove the card */ if (card->remove) card->remove(card); - snd_soc_dapm_free(&card->dapm); - snd_card_free(card->snd_card); return 0;