summaryrefslogtreecommitdiffstats
path: root/sound/usb
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2006-11-08 15:41:29 +0100
committerJaroslav Kysela <perex@suse.cz>2006-11-28 13:46:38 +0100
commitde1b8b93a0ba016b07d13086a15ad692536e6995 (patch)
tree840f0b486009d1ddd5c38fd57bc49e2f749253a1 /sound/usb
parent[ALSA] hda: fix typo for xw4400 PCI sub-ID (diff)
downloadlinux-de1b8b93a0ba016b07d13086a15ad692536e6995.tar.xz
linux-de1b8b93a0ba016b07d13086a15ad692536e6995.zip
[ALSA] Fix hang-up at disconnection of usb-audio
Fix hang-up at disconnection of usb-audio devices while accessing PCM. Don't handle PCM operations any more after shutdown flag is set. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/usb')
-rw-r--r--sound/usb/usbaudio.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sound/usb/usbaudio.c b/sound/usb/usbaudio.c
index c82b01c7ad3a..67202b9eeb77 100644
--- a/sound/usb/usbaudio.c
+++ b/sound/usb/usbaudio.c
@@ -1469,7 +1469,8 @@ static int snd_usb_hw_free(struct snd_pcm_substream *substream)
subs->cur_audiofmt = NULL;
subs->cur_rate = 0;
subs->period_bytes = 0;
- release_substream_urbs(subs, 0);
+ if (!subs->stream->chip->shutdown)
+ release_substream_urbs(subs, 0);
return snd_pcm_free_vmalloc_buffer(substream);
}