From b76b3f8ef8dfaea047177b67ebdea512bb1eda7a Mon Sep 17 00:00:00 2001 From: Eric Miao Date: Wed, 23 Nov 2011 22:37:00 +0800 Subject: [PATCH] --- yaml --- r: 276284 b: refs/heads/master c: 5ff1ddf22b2584d00d7e0ba5a8eab07b5338bd84 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/sound/soc/soc-core.c | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 0f1bcf0e9e73..7fef5f012a81 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: b284362b6b45150d171ff5bed92bc416b040aead +refs/heads/master: 5ff1ddf22b2584d00d7e0ba5a8eab07b5338bd84 diff --git a/trunk/sound/soc/soc-core.c b/trunk/sound/soc/soc-core.c index a5d3685a5d38..a25fa63ce9a2 100644 --- a/trunk/sound/soc/soc-core.c +++ b/trunk/sound/soc/soc-core.c @@ -709,6 +709,12 @@ int snd_soc_resume(struct device *dev) struct snd_soc_card *card = dev_get_drvdata(dev); int i, ac97_control = 0; + /* If the initialization of this soc device failed, there is no codec + * associated with it. Just bail out in this case. + */ + if (list_empty(&card->codec_dev_list)) + return 0; + /* AC97 devices might have other drivers hanging off them so * need to resume immediately. Other drivers don't have that * problem and may take a substantial amount of time to resume