diff options
author | Takashi Iwai <tiwai@suse.de> | 2006-11-08 09:41:29 -0500 |
---|---|---|
committer | Jaroslav Kysela <perex@suse.cz> | 2006-11-28 07:46:38 -0500 |
commit | de1b8b93a0ba016b07d13086a15ad692536e6995 (patch) | |
tree | 840f0b486009d1ddd5c38fd57bc49e2f749253a1 /sound/usb | |
parent | 282e0c87f223afbe8b182197eb06c127a66353ce (diff) |
[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.c | 3 |
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) | |||
1469 | subs->cur_audiofmt = NULL; | 1469 | subs->cur_audiofmt = NULL; |
1470 | subs->cur_rate = 0; | 1470 | subs->cur_rate = 0; |
1471 | subs->period_bytes = 0; | 1471 | subs->period_bytes = 0; |
1472 | release_substream_urbs(subs, 0); | 1472 | if (!subs->stream->chip->shutdown) |
1473 | release_substream_urbs(subs, 0); | ||
1473 | return snd_pcm_free_vmalloc_buffer(substream); | 1474 | return snd_pcm_free_vmalloc_buffer(substream); |
1474 | } | 1475 | } |
1475 | 1476 | ||