Skip to contentSkip to conversation

staging: media: atomisp: ov2722: clean up ov2722_startup()

PATCH In review auth 2 participants 2 messages Apr 29

Subsystems (4)
lore
Share & tools
lore

auth

author
#0 lore raw

PATCH 1/1 staging: media: atomisp: ov2722: clean up ov2722_startup()

Replace misleading comment with description of the function's purpose. Also replace return ret with return 0 since ret is guaranteed to be zero at that point.

---
 drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/media/atomisp/i2c/atomisp-ov2722.c +2 -2
index 2c41c496daa6..5f3712d6b81f 100644
@@ -599,7 +599,7 @@ static int ov2722_s_power(struct v4l2_subdev *sd, int on)
 	return ret;
 }
 
-/* TODO: remove it. */
+/* Initialize OV2722 sensor */
 static int ov2722_startup(struct v4l2_subdev *sd)
 {
 	struct ov2722_device *dev = to_ov2722_sensor(sd);
@@ -619,7 +619,7 @@ static int ov2722_startup(struct v4l2_subdev *sd)
 		return ret;
 	}
 
-	return ret;
+	return 0;
 }
 
 static int ov2722_set_fmt(struct v4l2_subdev *sd,
Signature · 1 line
2.54.0
#1 lore raw
Quoted 2 lines · auth

Replace misleading comment with description of the function's purpose. Also replace return ret with return 0 since ret is guaranteed to be zero at that point.

First of all, wrap the commit message to the ~72 characters per line. Second, Why do you think the comment is misleading? It's a TODO item. Perhaps the better change is to address that?

Quoted 1 line

Last but not least, use your real name.

Signature · 2 lines
With Best Regards,
Andy Shevchenko