From: Sakari Ailus Date: Fri, 17 Jan 2025 14:04:02 +0000 (+0200) Subject: media: i2c: ov7251: Introduce 1 ms delay between regulators and en GPIO X-Git-Tag: v5.10.237~220 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0463b05a700bfe15fef0d67bfac187ea043c31cb;p=thirdparty%2Fkernel%2Fstable.git media: i2c: ov7251: Introduce 1 ms delay between regulators and en GPIO commit 3d391292cdd53984ec1b9a1f6182a62a62751e03 upstream. Lift the xshutdown (enable) GPIO 1 ms after enabling the regulators, as required by the sensor's power-up sequence. Fixes: d30bb512da3d ("media: Add a driver for the ov7251 camera sensor") Cc: stable@vger.kernel.org Signed-off-by: Sakari Ailus Reviewed-by: Dave Stevenson Signed-off-by: Hans Verkuil Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/media/i2c/ov7251.c b/drivers/media/i2c/ov7251.c index 503a974ee76d5..aab6ea94e5ae3 100644 --- a/drivers/media/i2c/ov7251.c +++ b/drivers/media/i2c/ov7251.c @@ -748,6 +748,8 @@ static int ov7251_set_power_on(struct ov7251 *ov7251) return ret; } + usleep_range(1000, 1100); + gpiod_set_value_cansleep(ov7251->enable_gpio, 1); /* wait at least 65536 external clock cycles */