summaryrefslogtreecommitdiff
path: root/drivers/media
diff options
context:
space:
mode:
authorJacek Anaszewski <j.anaszewski@samsung.com>2016-01-18 19:10:27 +0300
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2016-01-25 15:30:12 +0300
commita13ddcae4f0bc5e1de761895d0cae2010e1934af (patch)
tree402a16ece75cbdb6151322ced5fd17131652fd59 /drivers/media
parent76775776a6e3dbe2dc8a84345dca4540969bc014 (diff)
downloadlinux-a13ddcae4f0bc5e1de761895d0cae2010e1934af.tar.xz
[media] exynos4-is: Wait for 100us before opening sensor
Some user space use cases result in kernel hangup on the HIC_OPEN_SENSOR command write. In case when a minimalistic application is used for setting up the streaming, the hangups occur only occasionally. In case of GStreamer use cases it is always the case. Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> Acked-by: Kyungmin Park <kyungmin.park@samsung.com> Cc: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/platform/exynos4-is/fimc-is.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/media/platform/exynos4-is/fimc-is.c b/drivers/media/platform/exynos4-is/fimc-is.c
index 49658ca39e51..979c388ebf60 100644
--- a/drivers/media/platform/exynos4-is/fimc-is.c
+++ b/drivers/media/platform/exynos4-is/fimc-is.c
@@ -631,6 +631,12 @@ static int fimc_is_hw_open_sensor(struct fimc_is *is,
fimc_is_mem_barrier();
+ /*
+ * Some user space use cases hang up here without this
+ * empirically chosen delay.
+ */
+ udelay(100);
+
mcuctl_write(HIC_OPEN_SENSOR, is, MCUCTL_REG_ISSR(0));
mcuctl_write(is->sensor_index, is, MCUCTL_REG_ISSR(1));
mcuctl_write(sensor->drvdata->id, is, MCUCTL_REG_ISSR(2));