aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/ymfpci/ymfpci_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/ymfpci/ymfpci_main.c')
-rw-r--r--sound/pci/ymfpci/ymfpci_main.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/sound/pci/ymfpci/ymfpci_main.c b/sound/pci/ymfpci/ymfpci_main.c
index 2e671ee438c6..c0aaade772d4 100644
--- a/sound/pci/ymfpci/ymfpci_main.c
+++ b/sound/pci/ymfpci/ymfpci_main.c
@@ -2151,14 +2151,8 @@ static int snd_ymfpci_free(ymfpci_t *chip)
2151#ifdef CONFIG_PM 2151#ifdef CONFIG_PM
2152 vfree(chip->saved_regs); 2152 vfree(chip->saved_regs);
2153#endif 2153#endif
2154 if (chip->mpu_res) { 2154 release_and_free_resource(chip->mpu_res);
2155 release_resource(chip->mpu_res); 2155 release_and_free_resource(chip->fm_res);
2156 kfree_nocheck(chip->mpu_res);
2157 }
2158 if (chip->fm_res) {
2159 release_resource(chip->fm_res);
2160 kfree_nocheck(chip->fm_res);
2161 }
2162 snd_ymfpci_free_gameport(chip); 2156 snd_ymfpci_free_gameport(chip);
2163 if (chip->reg_area_virt) 2157 if (chip->reg_area_virt)
2164 iounmap(chip->reg_area_virt); 2158 iounmap(chip->reg_area_virt);
@@ -2167,10 +2161,7 @@ static int snd_ymfpci_free(ymfpci_t *chip)
2167 2161
2168 if (chip->irq >= 0) 2162 if (chip->irq >= 0)
2169 free_irq(chip->irq, (void *)chip); 2163 free_irq(chip->irq, (void *)chip);
2170 if (chip->res_reg_area) { 2164 release_and_free_resource(chip->res_reg_area);
2171 release_resource(chip->res_reg_area);
2172 kfree_nocheck(chip->res_reg_area);
2173 }
2174 2165
2175 pci_write_config_word(chip->pci, 0x40, chip->old_legacy_ctrl); 2166 pci_write_config_word(chip->pci, 0x40, chip->old_legacy_ctrl);
2176 2167