From a9d2ba1444b0af6c2d8534f0b306660ffc045bc6 Mon Sep 17 00:00:00 2001 From: Ian Wisbon Date: Thu, 10 Feb 2011 17:15:15 -0500 Subject: Linux 2.6.31 Release for Digi ConnectCore Wi-i.MX boards --- drivers/media/video/mxs_pxp.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'drivers/media/video/mxs_pxp.c') diff --git a/drivers/media/video/mxs_pxp.c b/drivers/media/video/mxs_pxp.c index 83c9c52c3b0c..017d22458a22 100644 --- a/drivers/media/video/mxs_pxp.c +++ b/drivers/media/video/mxs_pxp.c @@ -31,6 +31,7 @@ #include #include #include +#include #include #include @@ -671,6 +672,7 @@ static int pxp_streamon(struct file *file, void *priv, enum v4l2_buf_type t) pxp_set_outbuf(pxp); ret = videobuf_streamon(&pxp->s0_vbq); + msleep(20); if (!ret && (pxp->output == 0)) mxsfb_cfg_pxp(1, pxp->outb_phys); @@ -686,7 +688,9 @@ static int pxp_streamoff(struct file *file, void *priv, enum v4l2_buf_type t) if ((t != V4L2_BUF_TYPE_VIDEO_OUTPUT)) return -EINVAL; + cancel_work_sync(&pxp->work); ret = videobuf_streamoff(&pxp->s0_vbq); + msleep(20); if (!ret) mxsfb_cfg_pxp(0, 0); @@ -1101,8 +1105,10 @@ static int pxp_close(struct file *file) { struct pxps *pxp = video_get_drvdata(video_devdata(file)); - if (pxp->workqueue) + if (pxp->workqueue) { + flush_workqueue(pxp->workqueue); destroy_workqueue(pxp->workqueue); + } videobuf_stop(&pxp->s0_vbq); videobuf_mmap_free(&pxp->s0_vbq); -- cgit v1.2.3