]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
media: i2c: ov01a10: Replace exposure->min/step with direct define use
authorHans de Goede <hansg@kernel.org>
Tue, 14 Oct 2025 17:40:26 +0000 (19:40 +0200)
committerHans Verkuil <hverkuil+cisco@kernel.org>
Tue, 13 Jan 2026 11:28:49 +0000 (12:28 +0100)
The exposure minimum and step are constant use the defines for this
instead of retrieving these from the exposure-control.

Signed-off-by: Hans de Goede <hansg@kernel.org>
Tested-by: Mehdi Djait <mehdi.djait@linux.intel.com> # Dell XPS 9315
Reviewed-by: Mehdi Djait <mehdi.djait@linux.intel.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
drivers/media/i2c/ov01a10.c

index 1af0af00df24c30c7d68e2c588c22493c37c5ab7..76c75da4d7c8a2e8c24d91aefe906134ddde7e23 100644 (file)
@@ -366,9 +366,8 @@ static int ov01a10_set_ctrl(struct v4l2_ctrl *ctrl)
                exposure_max = fmt->height + ctrl->val -
                               OV01A10_EXPOSURE_MAX_MARGIN;
                __v4l2_ctrl_modify_range(ov01a10->exposure,
-                                        ov01a10->exposure->minimum,
-                                        exposure_max, ov01a10->exposure->step,
-                                        exposure_max);
+                                        OV01A10_EXPOSURE_MIN, exposure_max,
+                                        OV01A10_EXPOSURE_STEP, exposure_max);
        }
 
        if (!pm_runtime_get_if_in_use(ov01a10->dev))