summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuxi Sun <b36102@freescale.com>2012-04-12 15:23:08 +0800
committerXinyu Chen <xinyu.chen@freescale.com>2012-04-12 16:03:40 +0800
commitaba0f4e0b130f359697081b7cc488fecbb2da2d1 (patch)
treecab54f132ff285aa734e5accbb57a74c7fe96fb3
parent5c11b15d849829fb52522eeeba7c088757870569 (diff)
ENGR00179510 ipu capture: fix system hang when running capture
Add _ipu_get() and _ipu_put() when calling ipu_csi_get_sensor_protocol function. Signed-off-by: Yuxi Sun <b36102@freescale.com>
-rw-r--r--drivers/mxc/ipu3/ipu_capture.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/mxc/ipu3/ipu_capture.c b/drivers/mxc/ipu3/ipu_capture.c
index 2b818a0276a0..c4eac45a6152 100644
--- a/drivers/mxc/ipu3/ipu_capture.c
+++ b/drivers/mxc/ipu3/ipu_capture.c
@@ -215,9 +215,13 @@ EXPORT_SYMBOL(ipu_csi_init_interface);
*/
int32_t ipu_csi_get_sensor_protocol(struct ipu_soc *ipu, uint32_t csi)
{
- return (ipu_csi_read(ipu, csi, CSI_SENS_CONF) &
+ int ret;
+ _ipu_get(ipu);
+ ret = (ipu_csi_read(ipu, csi, CSI_SENS_CONF) &
CSI_SENS_CONF_SENS_PRTCL_MASK) >>
CSI_SENS_CONF_SENS_PRTCL_SHIFT;
+ _ipu_put(ipu);
+ return ret;
}
EXPORT_SYMBOL(ipu_csi_get_sensor_protocol);