aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2014-01-15 00:52:12 -0500
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-01-15 06:12:03 -0500
commitff0284cc0bf13f08e19fbf364fafabe9e61a7342 (patch)
treefdad1ca2350f1fb4d969106d430ffe525b5d2540
parent793708fffffad737d8b0113e41f0d14a38e8765e (diff)
[media] em28xx-audio: remove needless check before usb_free_coherent()
usb_free_coherent() is safe with NULL addr and this check is not required. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r--drivers/media/usb/em28xx/em28xx-audio.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/media/usb/em28xx/em28xx-audio.c b/drivers/media/usb/em28xx/em28xx-audio.c
index e57616ecd2cb..05e9bd11a3ff 100644
--- a/drivers/media/usb/em28xx/em28xx-audio.c
+++ b/drivers/media/usb/em28xx/em28xx-audio.c
@@ -711,11 +711,9 @@ static void em28xx_audio_free_urb(struct em28xx *dev)
711 if (!urb) 711 if (!urb)
712 continue; 712 continue;
713 713
714 if (dev->adev.transfer_buffer[i]) 714 usb_free_coherent(dev->udev, urb->transfer_buffer_length,
715 usb_free_coherent(dev->udev, 715 dev->adev.transfer_buffer[i],
716 urb->transfer_buffer_length, 716 urb->transfer_dma);
717 dev->adev.transfer_buffer[i],
718 urb->transfer_dma);
719 717
720 usb_free_urb(urb); 718 usb_free_urb(urb);
721 } 719 }