Message ID | 20140922080008.GB12362@mwanda (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Hi Dan, Thanks for the patch! On Mon, Sep 22, 2014 at 9:00 AM, Dan Carpenter <dan.carpenter@oracle.com> wrote: > We don't need to check "ret", we know it's zero. > > Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Regards, --Prabhakar Lad > > diff --git a/drivers/media/platform/davinci/vpfe_capture.c b/drivers/media/platform/davinci/vpfe_capture.c > index c557eb5..3eb6e4b 100644 > --- a/drivers/media/platform/davinci/vpfe_capture.c > +++ b/drivers/media/platform/davinci/vpfe_capture.c > @@ -442,11 +442,10 @@ static int vpfe_config_image_format(struct vpfe_device *vpfe_dev, > return ret; > > /* Update the values of sizeimage and bytesperline */ > - if (!ret) { > - pix->bytesperline = ccdc_dev->hw_ops.get_line_length(); > - pix->sizeimage = pix->bytesperline * pix->height; > - } > - return ret; > + pix->bytesperline = ccdc_dev->hw_ops.get_line_length(); > + pix->sizeimage = pix->bytesperline * pix->height; > + > + return 0; > } > > static int vpfe_initialize_device(struct vpfe_device *vpfe_dev) -- 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
diff --git a/drivers/media/platform/davinci/vpfe_capture.c b/drivers/media/platform/davinci/vpfe_capture.c index c557eb5..3eb6e4b 100644 --- a/drivers/media/platform/davinci/vpfe_capture.c +++ b/drivers/media/platform/davinci/vpfe_capture.c @@ -442,11 +442,10 @@ static int vpfe_config_image_format(struct vpfe_device *vpfe_dev, return ret; /* Update the values of sizeimage and bytesperline */ - if (!ret) { - pix->bytesperline = ccdc_dev->hw_ops.get_line_length(); - pix->sizeimage = pix->bytesperline * pix->height; - } - return ret; + pix->bytesperline = ccdc_dev->hw_ops.get_line_length(); + pix->sizeimage = pix->bytesperline * pix->height; + + return 0; } static int vpfe_initialize_device(struct vpfe_device *vpfe_dev)
We don't need to check "ret", we know it's zero. 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