Skip to content

Commit

Permalink
3.8: add 2 hacks for the camera cape
Browse files Browse the repository at this point in the history
One increases the delay so the clock can stabilize, the other forward ports the sensor hacks

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
  • Loading branch information
koenkooi committed May 2, 2013
1 parent ca3adc6 commit fd1dd2c
Show file tree
Hide file tree
Showing 2 changed files with 626 additions and 0 deletions.
@@ -0,0 +1,36 @@
From d9c8f1ea6f9ba421ace58b71cd48fa9c494b93ef Mon Sep 17 00:00:00 2001
From: Koen Kooi <koen@dominion.thruhere.net>
Date: Thu, 2 May 2013 12:06:12 +0200
Subject: [PATCH 1/2] cssp_camera: increase delays make sensor detection work
better

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
---
drivers/media/platform/soc_camera/cssp_camera.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/media/platform/soc_camera/cssp_camera.c b/drivers/media/platform/soc_camera/cssp_camera.c
index 0bc6a28..0a0cd8f 100644
--- a/drivers/media/platform/soc_camera/cssp_camera.c
+++ b/drivers/media/platform/soc_camera/cssp_camera.c
@@ -471,7 +471,7 @@ static int configure_camera_sensor(struct cssp_cam_dev *cam)
/* Enable the clock just for the time of loading the camera driver and disable after that */
/* It is going to be be re-enabled later, when camera will be in use */
clk_enable(cam->camera_clk);
- udelay(5); // let the clock stabilize
+ mdelay(50); // let the clock stabilize

adapter = i2c_get_adapter(((struct soc_camera_link *)(info->platform_data))->i2c_adapter_id);
if (!adapter) {
@@ -504,7 +504,7 @@ static int configure_camera_sensor(struct cssp_cam_dev *cam)
static int start_camera_sensor(struct cssp_cam_dev *cam)
{
clk_enable(cam->camera_clk);
- udelay(5); /* let the clock stabilize */
+ mdelay(100); /* let the clock stabilize */

v4l2_subdev_call(cam->subdev, video, s_stream, 1);

--
1.8.1.4

0 comments on commit fd1dd2c

Please sign in to comment.