[media] gspca_stv06xx: remove an unneeded check

Message ID 20140218150044.GC6914@elgon.mountain (mailing list archive)
State Accepted, archived
Delegated to: Hans de Goede
Headers

Commit Message

Dan Carpenter Feb. 18, 2014, 3 p.m. UTC
  "err" is zero here so we don't need to check again.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
  

Comments

Hans de Goede Feb. 23, 2014, 9:47 p.m. UTC | #1
Hi,

On 02/18/2014 04:00 PM, Dan Carpenter wrote:
> "err" is zero here so we don't need to check again.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> 
> diff --git a/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c b/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
> index bf3e5c317a26..e60cbb3aa609 100644
> --- a/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
> +++ b/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
> @@ -178,7 +178,7 @@ static int vv6410_stop(struct sd *sd)
>  
>  	PDEBUG(D_STREAM, "Halting stream");
>  
> -	return (err < 0) ? err : 0;
> +	return 0;
>  }
>  
>  static int vv6410_dump(struct sd *sd)
> 

Thanks I've added this to my gspca tree for 3.15.

Regards,

Hans
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
  

Patch

diff --git a/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c b/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
index bf3e5c317a26..e60cbb3aa609 100644
--- a/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
+++ b/drivers/media/usb/gspca/stv06xx/stv06xx_vv6410.c
@@ -178,7 +178,7 @@  static int vv6410_stop(struct sd *sd)
 
 	PDEBUG(D_STREAM, "Halting stream");
 
-	return (err < 0) ? err : 0;
+	return 0;
 }
 
 static int vv6410_dump(struct sd *sd)