From 0310261e5ebe9632d80d0d40b1486ccdb67c0fe2 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 30 May 2005 20:33:44 +0200 Subject: [PATCH] --- yaml --- r: 2641 b: refs/heads/master c: ce43fbaececc82196d321671159483b3287de128 h: refs/heads/master i: 2639: 6ca26060a7fcfa9aee6b1941210eda8deb92a180 v: v3 --- [refs] | 2 +- trunk/sound/pci/hda/hda_intel.c | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index da0da471c42c..df15953d9ce7 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: b6a969155b04416185f368bd4e2f1d49b17c1ee1 +refs/heads/master: ce43fbaececc82196d321671159483b3287de128 diff --git a/trunk/sound/pci/hda/hda_intel.c b/trunk/sound/pci/hda/hda_intel.c index f05a6384b9c0..0d546addc091 100644 --- a/trunk/sound/pci/hda/hda_intel.c +++ b/trunk/sound/pci/hda/hda_intel.c @@ -286,6 +286,7 @@ struct snd_azx { /* flags */ int position_fix; + unsigned int initialized: 1; }; /* @@ -1235,7 +1236,7 @@ static int azx_resume(snd_card_t *card) */ static int azx_free(azx_t *chip) { - if (chip->remap_addr) { + if (chip->initialized) { int i; for (i = 0; i < MAX_ICH6_DEV; i++) @@ -1361,6 +1362,8 @@ static int __devinit azx_create(snd_card_t *card, struct pci_dev *pci, /* initialize chip */ azx_init_chip(chip); + chip->initialized = 1; + /* codec detection */ if (! chip->codec_mask) { snd_printk(KERN_ERR SFX "no codecs found!\n");