Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

media: pwc-ctl: remove redundant assignment to variable ret

The variable ret is being initialized with a value that is never read
and it is being updated later with a new value. The initialization is
redundant and can be removed.

Addresses-Coverity: ("Unused value")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Ezequiel Garcia <ezequiel@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>

authored by

Colin Ian King and committed by
Mauro Carvalho Chehab
03f56d99 757570f1

+1 -1
+1 -1
drivers/media/usb/pwc/pwc-ctrl.c
··· 523 523 #ifdef CONFIG_USB_PWC_DEBUG 524 524 int pwc_get_cmos_sensor(struct pwc_device *pdev, int *sensor) 525 525 { 526 - int ret = -1, request; 526 + int ret, request; 527 527 528 528 if (pdev->type < 675) 529 529 request = SENSOR_TYPE_FORMATTER1;