static void __exit cleanup_opl3sa2(void) { if(cfg_mpu.slots[1] != -1) { unload_opl3sa2_mpu(&cfg_mpu); } unload_opl3sa2_mss(&cfg2); unload_opl3sa2(&cfg); }
void cleanup_module(void) { #if (defined(CONFIG_MPU401) || defined(CONFIG_MPU_EMU)) && defined(CONFIG_MIDI) if(mpu_cfg.slots[1] != -1) { unload_opl3sa2_mpu(&mpu_cfg); } #endif unload_opl3sa2_mss(&mss_cfg); unload_opl3sa2(&cfg); SOUND_LOCK_END; }
/* * Uninstall OPL3-SA2 based card(s). */ static void __exit cleanup_opl3sa2(void) { int card; for(card = 0; card < opl3sa2_cards_num; card++) { if(cfg_mpu[card].slots[1] != -1) { unload_opl3sa2_mpu(&cfg_mpu[card]); } unload_opl3sa2_mss(&cfg_mss[card]); unload_opl3sa2(&cfg[card], card); #if defined CONFIG_ISAPNP || defined CONFIG_ISAPNP_MODULE if(opl3sa2_activated[card] && opl3sa2_dev[card]) { opl3sa2_dev[card]->deactivate(opl3sa2_dev[card]); printk(KERN_DEBUG "opl3sa2: Deactivated ISA PnP card %d (active=%d)\n", card, opl3sa2_dev[card]->active); } #endif } }