summaryrefslogtreecommitdiffstats
path: root/sound/isa/sb/emu8000.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/isa/sb/emu8000.c')
-rw-r--r--sound/isa/sb/emu8000.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/sound/isa/sb/emu8000.c b/sound/isa/sb/emu8000.c
index 5375705c054b..95540f133199 100644
--- a/sound/isa/sb/emu8000.c
+++ b/sound/isa/sb/emu8000.c
@@ -1054,18 +1054,9 @@ __error:
*/
static int snd_emu8000_free(emu8000_t *hw)
{
- if (hw->res_port1) {
- release_resource(hw->res_port1);
- kfree_nocheck(hw->res_port1);
- }
- if (hw->res_port2) {
- release_resource(hw->res_port2);
- kfree_nocheck(hw->res_port2);
- }
- if (hw->res_port3) {
- release_resource(hw->res_port3);
- kfree_nocheck(hw->res_port3);
- }
+ release_and_free_resource(hw->res_port1);
+ release_and_free_resource(hw->res_port2);
+ release_and_free_resource(hw->res_port3);
kfree(hw);
return 0;
}
OpenPOWER on IntegriCloud