LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] staging: vc04_services: bcm2835-camera: remove redundant assignment to variable ret
@ 2019-05-11 13:48 Colin King
  2019-05-13  6:49 ` Stefan Wahren
  0 siblings, 1 reply; 2+ messages in thread
From: Colin King @ 2019-05-11 13:48 UTC (permalink / raw)
  To: Eric Anholt, Stefan Wahren, Greg Kroah-Hartman, Florian Fainelli,
	Ray Jui, Scott Branden, bcm-kernel-feedback-list,
	linux-rpi-kernel, linux-arm-kernel, devel
  Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

The variable ret is being initialized however this is never read and later
it is being reassigned to a new value. The initialization is redundant and
hence can be removed.

Addresses-Coverity: ("Unused Value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 drivers/staging/vc04_services/bcm2835-camera/controls.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/vc04_services/bcm2835-camera/controls.c b/drivers/staging/vc04_services/bcm2835-camera/controls.c
index 9841c30450ce..74410fedffad 100644
--- a/drivers/staging/vc04_services/bcm2835-camera/controls.c
+++ b/drivers/staging/vc04_services/bcm2835-camera/controls.c
@@ -579,7 +579,7 @@ static int ctrl_set_colfx(struct bm2835_mmal_dev *dev,
 			  struct v4l2_ctrl *ctrl,
 			  const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl)
 {
-	int ret = -EINVAL;
+	int ret;
 	struct vchiq_mmal_port *control;
 
 	control = &dev->component[MMAL_COMPONENT_CAMERA]->control;
-- 
2.20.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-05-13  6:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-11 13:48 [PATCH] staging: vc04_services: bcm2835-camera: remove redundant assignment to variable ret Colin King
2019-05-13  6:49 ` Stefan Wahren

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).