summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJaejoong Kim <climbbb.kim@gmail.com>2017-10-20 10:25:27 +0300
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2017-12-08 19:32:03 +0300
commit5ba3dff4f3f4b0a3c8775d6ea48c07b11a7ad790 (patch)
tree1337b3e9279a779de72ffe98d858c97256b1c91c /drivers
parente96cdc9a0aa2fcaa276a76e8ffa86fc10a1d3d99 (diff)
downloadlinux-5ba3dff4f3f4b0a3c8775d6ea48c07b11a7ad790.tar.xz
media: uvcvideo: Remove duplicate & operation
usb_endpoint_maxp() has an inline keyword and searches for bits[10:0] by & operation with 0x7ff. So, we can remove the duplicate & operation with 0x7ff. Signed-off-by: Jaejoong Kim <climbbb.kim@gmail.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/usb/uvc/uvc_video.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/usb/uvc/uvc_video.c b/drivers/media/usb/uvc/uvc_video.c
index fb86d6af398d..f4ace6352520 100644
--- a/drivers/media/usb/uvc/uvc_video.c
+++ b/drivers/media/usb/uvc/uvc_video.c
@@ -1469,13 +1469,13 @@ static unsigned int uvc_endpoint_max_bpi(struct usb_device *dev,
case USB_SPEED_HIGH:
psize = usb_endpoint_maxp(&ep->desc);
mult = usb_endpoint_maxp_mult(&ep->desc);
- return (psize & 0x07ff) * mult;
+ return psize * mult;
case USB_SPEED_WIRELESS:
psize = usb_endpoint_maxp(&ep->desc);
return psize;
default:
psize = usb_endpoint_maxp(&ep->desc);
- return psize & 0x07ff;
+ return psize;
}
}