summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <m.chehab@samsung.com>2014-01-12 22:14:05 +0100
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-01-14 17:36:29 +0100
commit1fe2e3bff4f862d971207c846e4df61160c0e858 (patch)
treee1cc009c7ff16197f711de5aa299e3cf07b9a237 /drivers
parent[media] em28xx-audio: simplify error handling (diff)
downloadlinux-1fe2e3bff4f862d971207c846e4df61160c0e858.tar.xz
linux-1fe2e3bff4f862d971207c846e4df61160c0e858.zip
[media] em28xx-audio: disconnect before freeing URBs
URBs might be in usage. Disconnect the device before freeing them. Reviewed-by: Frank Schäfer <fschaefer.oss@googlemail.com> Tested-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/usb/em28xx/em28xx-audio.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/media/usb/em28xx/em28xx-audio.c b/drivers/media/usb/em28xx/em28xx-audio.c
index 97d9105e6830..7f762db94b5f 100644
--- a/drivers/media/usb/em28xx/em28xx-audio.c
+++ b/drivers/media/usb/em28xx/em28xx-audio.c
@@ -956,6 +956,7 @@ static int em28xx_audio_fini(struct em28xx *dev)
return 0;
}
+ snd_card_disconnect(dev->adev.sndcard);
em28xx_audio_free_urb(dev);
if (dev->adev.sndcard) {