linux/drivers/media
Jacopo Mondi 2b821698dc media: i2c: rdacm21: Power up OV10640 before OV490
The current RDACM21 initialization routine powers up the OV10640 image
sensor after the OV490 ISP. The ISP is programmed with a firmware loaded
from an embedded serial flash that (most probably) tries to interact and
program also the image sensor connected to the ISP.

As described in commit "media: i2c: rdacm21: Fix OV10640 powerup" the
image sensor powerdown signal is kept high by an internal pull up
resistor and occasionally fails to startup correctly if the powerdown
line is not asserted explicitly. Failures in the OV10640 startup causes
the OV490 firmware to fail to boot correctly resulting in the camera
module initialization to fail consequentially.

Fix this by powering up the OV10640 image sensor before testing the
OV490 firmware boot completion, by splitting the ov10640_initialize()
function in an ov10640_power_up() one and an ov10640_check_id() one.

Also make sure the OV10640 identification procedure gives enough time to
the image sensor to resume after the programming phase performed by the
OV490 firmware by repeating the ID read procedure.

This commit fixes a sporadic start-up error triggered by a failure to
detect the OV490 firmware boot completion:
rdacm21 8-0054: Timeout waiting for firmware boot

[hverkuil: fixed two typos in commit log]

Fixes: a59f853b3b ("media: i2c: Add driver for RDACM21 camera module")
Signed-off-by: Jacopo Mondi <jacopo+renesas@jmondi.org>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
2021-06-17 11:31:45 +02:00
..
cec media: s5p: fix pm_runtime_get_sync() usage count 2021-05-10 11:36:33 +02:00
common media: siano: fix device register error path 2021-06-17 09:27:08 +02:00
dvb-core media: dvb-core: frontend: make GET/SET safer 2021-06-17 09:29:11 +02:00
dvb-frontends media: mxl692: make a const array static, makes object smaller 2021-06-08 15:50:38 +02:00
firewire module: remove never implemented MODULE_SUPPORTED_DEVICE 2021-03-17 13:16:18 -07:00
i2c media: i2c: rdacm21: Power up OV10640 before OV490 2021-06-17 11:31:45 +02:00
mc media: mc-request.c: allow object_bind in QUEUED state 2021-06-02 11:41:54 +02:00
mmc media updates for v5.8-rc1 2020-06-03 20:59:38 -07:00
pci media: pci: cx88: switch from 'pci_' to 'dma_' API 2021-06-17 10:24:41 +02:00
platform media: mtk-vcodec: fix kerneldoc warnings 2021-06-17 10:25:59 +02:00
radio media: radio: si4713: constify static struct v4l2_ioctl_ops 2021-06-02 13:26:11 +02:00
rc media: imon: use DEVICE_ATTR_RW() helper macro 2021-06-08 15:57:51 +02:00
spi media: cxd2880-spi: Fix some error messages 2021-06-08 15:51:35 +02:00
test-drivers media: v4l2-subdev: add subdev-wide state struct 2021-06-17 10:01:27 +02:00
tuners media: m88rs6000t: avoid potential out-of-bounds reads on arrays 2021-03-22 17:41:39 +01:00
usb media: usb: cpia2: Fixed Coding Style issues 2021-06-17 10:22:33 +02:00
v4l2-core media: v4l2-event: Modified variable type 'unsigned' to 'unsigned int' 2021-06-17 10:22:59 +02:00
Kconfig media: Correct 'so' 2021-03-22 11:52:09 +01:00
Makefile media: media/test_drivers: rename to test-drivers 2020-04-16 10:38:31 +02:00