Re: [PATCH v2 2/2] leds: add sgm3140 driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Luca

On 4/4/20 4:36 AM, Luca Weiss wrote:
+ fled_cdev, NULL,
<snip>
+					   &v4l2_sd_cfg);
+	if (IS_ERR(priv->v4l2_flash)) {
+		ret = PTR_ERR(priv->v4l2_flash);
+		goto err;
Not sure why this is here you are not in a for loop and this will fall
through anyway to the err label.

I kept the goto in, in case more code is added below that statement so the
author doesn't forget that this error needs to be handled.
If wanted I can remove it of course.

I am ok with all the reasoning in the previous comments.  This one I would say just fall through to out.

If there is other code added after this then it can be added in.

Dan




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux