aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/pci/ac97/ac97_codec.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sound/pci/ac97/ac97_codec.c b/sound/pci/ac97/ac97_codec.c
index 9faeaefc8e6e..abc83fa85bcd 100644
--- a/sound/pci/ac97/ac97_codec.c
+++ b/sound/pci/ac97/ac97_codec.c
@@ -2186,6 +2186,8 @@ static void snd_ac97_powerdown(struct snd_ac97 *ac97)
2186 */ 2186 */
2187void snd_ac97_suspend(struct snd_ac97 *ac97) 2187void snd_ac97_suspend(struct snd_ac97 *ac97)
2188{ 2188{
2189 if (! ac97)
2190 return;
2189 if (ac97->build_ops->suspend) 2191 if (ac97->build_ops->suspend)
2190 ac97->build_ops->suspend(ac97); 2192 ac97->build_ops->suspend(ac97);
2191 snd_ac97_powerdown(ac97); 2193 snd_ac97_powerdown(ac97);
@@ -2242,6 +2244,9 @@ void snd_ac97_resume(struct snd_ac97 *ac97)
2242{ 2244{
2243 unsigned long end_time; 2245 unsigned long end_time;
2244 2246
2247 if (! ac97)
2248 return;
2249
2245 if (ac97->bus->ops->reset) { 2250 if (ac97->bus->ops->reset) {
2246 ac97->bus->ops->reset(ac97); 2251 ac97->bus->ops->reset(ac97);
2247 goto __reset_ready; 2252 goto __reset_ready;