From 35098755c90373eb932f02f71ec986e9d4a6f49b Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Sat, 16 Dec 2006 17:05:07 -0200 Subject: Backported several changes from kernel 2.6.19-git series From: Mauro Carvalho Chehab Main changes: - There were several checks for usb release routines that were removed, since the routine itself checks for null values: usb_free_urb, usb_kill_urb, usb_unlink_urb Should be checked if this really happens on older kernels. - updated sound/oss/btaudio.c - replaced SLAB_ATOMIC to GFP_ATOMIC Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/pwc/pwc-if.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'linux/drivers/media/video/pwc') diff --git a/linux/drivers/media/video/pwc/pwc-if.c b/linux/drivers/media/video/pwc/pwc-if.c index 3592202c1..39aca8e12 100644 --- a/linux/drivers/media/video/pwc/pwc-if.c +++ b/linux/drivers/media/video/pwc/pwc-if.c @@ -904,8 +904,7 @@ int pwc_isoc_init(struct pwc_device *pdev) if (ret) { /* De-allocate in reverse order */ while (i--) { - if (pdev->sbuf[i].urb != NULL) - usb_free_urb(pdev->sbuf[i].urb); + usb_free_urb(pdev->sbuf[i].urb); pdev->sbuf[i].urb = NULL; } return ret; @@ -1131,8 +1130,7 @@ static int pwc_video_open(struct inode *inode, struct file *file) PWC_DEBUG_OPEN(">> video_open called(vdev = 0x%p).\n", vdev); pdev = (struct pwc_device *)vdev->priv; - if (pdev == NULL) - BUG(); + BUG_ON(!pdev); if (pdev->vopen) { PWC_DEBUG_OPEN("I'm busy, someone is using the device.\n"); return -EBUSY; -- cgit v1.2.3