From 0956f1c0d13067f3aec8836eb842ec9094fc1dfb Mon Sep 17 00:00:00 2001 From: Sanghoon Lee Date: Wed, 2 May 2018 14:33:26 +0900 Subject: [PATCH] Revert "[HACK][COMMON] media: fimc-is2: set stream off call only vvalid region" This reverts commit 2d06cbf9452772189daaacd0b91d8d25dee31569. Change-Id: I41aa9e0ec8241c2eec7644636f4d5db7814a2b75 --- .../exynos/fimc-is2/fimc-is-device-csi.h | 1 - .../exynos/fimc-is2/fimc-is-device-csi_v4.c | 4 ---- .../exynos/fimc-is2/fimc-is-device-sensor_v2.c | 16 ---------------- 3 files changed, 21 deletions(-) diff --git a/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi.h b/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi.h index 824ee9e63994..6392984010fd 100644 --- a/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi.h +++ b/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi.h @@ -116,7 +116,6 @@ struct fimc_is_device_csi { atomic_t vvalid; /* set 1 while vvalid period */ #endif - wait_queue_head_t wait_queue; }; struct fimc_is_device_csi_dma { diff --git a/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi_v4.c b/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi_v4.c index 2564c95eaed7..8cb252ee31e5 100644 --- a/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi_v4.c +++ b/drivers/media/platform/exynos/fimc-is2/fimc-is-device-csi_v4.c @@ -63,8 +63,6 @@ inline void csi_frame_start_inline(struct fimc_is_device_csi *csi) v4l2_subdev_notify(*csi->subdev, CSI_NOTIFY_VSYNC, &vsync_cnt); } - wake_up(&csi->wait_queue); - tasklet_schedule(&csi->tasklet_csis_str); } @@ -2058,8 +2056,6 @@ int fimc_is_csi_probe(void *parent, u32 instance) if (!csi->workqueue) probe_warn("failed to alloc CSI own workqueue, will be use global one"); - init_waitqueue_head(&csi->wait_queue); - v4l2_subdev_init(subdev_csi, &subdev_ops); v4l2_set_subdevdata(subdev_csi, csi); v4l2_set_subdev_hostdata(subdev_csi, device); diff --git a/drivers/media/platform/exynos/fimc-is2/fimc-is-device-sensor_v2.c b/drivers/media/platform/exynos/fimc-is2/fimc-is-device-sensor_v2.c index 248002d4ce3c..8d2dc963f25b 100644 --- a/drivers/media/platform/exynos/fimc-is2/fimc-is-device-sensor_v2.c +++ b/drivers/media/platform/exynos/fimc-is2/fimc-is-device-sensor_v2.c @@ -881,8 +881,6 @@ static int fimc_is_sensor_stop(struct fimc_is_device_sensor *device) int retry = 10; struct v4l2_subdev *subdev_module; - struct fimc_is_device_csi *csi; - long timetowait; FIMC_BUG(!device); @@ -910,20 +908,6 @@ static int fimc_is_sensor_stop(struct fimc_is_device_sensor *device) subdev_module = device->subdev_module; if (subdev_module) { - csi = v4l2_get_subdevdata(device->subdev_csi); - if (!csi) { - merr("CSI is NULL", device); - return -EINVAL; - } - - /* HACK: if sensor stop called at Vblank time, - * wait for next vvalid time for prevent sensor malfunction - */ - timetowait = wait_event_timeout(csi->wait_queue, - atomic_read(&csi->vvalid), 30); - if (!timetowait) - mwarn("wait CSI VVALID timeout (%ld)", csi, timetowait); - ret = v4l2_subdev_call(subdev_module, video, s_stream, false); if (ret) merr("v4l2_subdev_call(s_stream) is fail(%d)", device, ret); -- 2.20.1