[media] gspca_stv06xx: remove redundant check for err < 0
authorColin Ian King <colin.king@canonical.com>
Wed, 11 Jan 2017 16:24:33 +0000 (14:24 -0200)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Fri, 3 Feb 2017 13:18:33 +0000 (11:18 -0200)
The comparison of err < 0 is redundant as err has been previously
been assigned to 0 and has not changed.  Remove the redundant check.

Fixes CoverityScan CID#703363 ("Logically dead code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c

index 9f490f55d3673c7965007f3e23603458063b6602..d265e6b0099477c6251bc03a17e4a42fc4223be1 100644 (file)
@@ -116,9 +116,6 @@ static int vv6410_init(struct sd *sd)
        for (i = 0; i < ARRAY_SIZE(stv_bridge_init); i++)
                stv06xx_write_bridge(sd, stv_bridge_init[i].addr, stv_bridge_init[i].data);
 
-       if (err < 0)
-               return err;
-
        err = stv06xx_write_sensor_bytes(sd, (u8 *) vv6410_sensor_init,
                                         ARRAY_SIZE(vv6410_sensor_init));
        return (err < 0) ? err : 0;