OSDN Git Service

media: uvcvideo: Use DIV_ROUND_CLOSEST directly to make it readable
authorzhong jiang <zhongjiang@huawei.com>
Wed, 9 Oct 2019 14:55:24 +0000 (16:55 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Fri, 27 Nov 2020 09:19:29 +0000 (10:19 +0100)
commit7ae53081901b52cebfdd5b39b373abaac5d1d4ef
tree780c82cd89af1b34bbbd05443067b483d5816304
parenteeb76afbe8d91e112396c6281cd020725160f006
media: uvcvideo: Use DIV_ROUND_CLOSEST directly to make it readable

The kernel.h macro DIV_ROUND_CLOSEST performs the computation (x + d/2)/d
but is perhaps more readable.

Signed-off-by: zhong jiang <zhongjiang@huawei.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/usb/uvc/uvc_ctrl.c