.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
---|
1 | 2 | /* |
---|
2 | 3 | * Copyright (C) 2000 Takashi Iwai <tiwai@suse.de> |
---|
3 | 4 | * |
---|
4 | 5 | * Routines for control of EMU WaveTable chip |
---|
5 | | - * |
---|
6 | | - * This program is free software; you can redistribute it and/or modify |
---|
7 | | - * it under the terms of the GNU General Public License as published by |
---|
8 | | - * the Free Software Foundation; either version 2 of the License, or |
---|
9 | | - * (at your option) any later version. |
---|
10 | | - * |
---|
11 | | - * This program is distributed in the hope that it will be useful, |
---|
12 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
13 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
14 | | - * GNU General Public License for more details. |
---|
15 | | - * |
---|
16 | | - * You should have received a copy of the GNU General Public License |
---|
17 | | - * along with this program; if not, write to the Free Software |
---|
18 | | - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
---|
19 | 6 | */ |
---|
20 | 7 | |
---|
21 | 8 | #include <linux/wait.h> |
---|
.. | .. |
---|
138 | 125 | */ |
---|
139 | 126 | int snd_emux_free(struct snd_emux *emu) |
---|
140 | 127 | { |
---|
141 | | - unsigned long flags; |
---|
142 | | - |
---|
143 | 128 | if (! emu) |
---|
144 | 129 | return -EINVAL; |
---|
145 | 130 | |
---|
146 | | - spin_lock_irqsave(&emu->voice_lock, flags); |
---|
147 | | - if (emu->timer_active) |
---|
148 | | - del_timer(&emu->tlist); |
---|
149 | | - spin_unlock_irqrestore(&emu->voice_lock, flags); |
---|
| 131 | + del_timer_sync(&emu->tlist); |
---|
150 | 132 | |
---|
151 | 133 | snd_emux_proc_free(emu); |
---|
152 | 134 | snd_emux_delete_virmidi(emu); |
---|