media: gspca: remove redundant initialization of variable status
authorColin Ian King <colin.king@canonical.com>
Wed, 1 Jul 2020 13:56:52 +0000 (15:56 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Sun, 19 Jul 2020 05:44:37 +0000 (07:44 +0200)
The variable status 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>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/usb/gspca/sn9c2028.c

index aff01b7..dbd1d6d 100644 (file)
@@ -215,7 +215,7 @@ static int sd_config(struct gspca_dev *gspca_dev,
 /* this function is called at probe and resume time */
 static int sd_init(struct gspca_dev *gspca_dev)
 {
-       int status = -1;
+       int status;
 
        sn9c2028_read1(gspca_dev);
        sn9c2028_read1(gspca_dev);