[PATCH] staging: media: atomisp: ov2722: clean up ov2722_startup()

auth posted 1 patch 1 month, 2 weeks ago
There is a newer version of this series
drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
[PATCH] staging: media: atomisp: ov2722: clean up ov2722_startup()
Posted by auth 1 month, 2 weeks ago
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.

Signed-off-by: auth <skunkolee@gmail.com>
---
 drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
index 2c41c496daa6..5f3712d6b81f 100644
--- a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
+++ b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c
@@ -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,
-- 
2.54.0
Re: [PATCH] staging: media: atomisp: ov2722: clean up ov2722_startup()
Posted by Andy Shevchenko 1 month, 2 weeks ago
On Wed, Apr 29, 2026 at 5:04 AM auth <skunkolee@gmail.com> wrote:
>
> 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?

> Signed-off-by: auth <skunkolee@gmail.com>

Last but not least, use your real name.

-- 
With Best Regards,
Andy Shevchenko