From patchwork Fri Dec 17 09:40:50 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anatolij Gustschin X-Patchwork-Id: 415131 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oBH9euJT013621 for ; Fri, 17 Dec 2010 09:40:56 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752055Ab0LQJkl (ORCPT ); Fri, 17 Dec 2010 04:40:41 -0500 Received: from mail-out.m-online.net ([212.18.0.9]:42490 "EHLO mail-out.m-online.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751842Ab0LQJkk (ORCPT ); Fri, 17 Dec 2010 04:40:40 -0500 Received: from frontend1.mail.m-online.net (unknown [192.168.8.180]) by mail-out.m-online.net (Postfix) with ESMTP id E034E1C088BE; Fri, 17 Dec 2010 10:40:38 +0100 (CET) X-Auth-Info: pee+p1Jr6PLLGeVdyLOlvJpmvF0Ig6UwXvk7JosqKdQ= Received: from localhost (p4FE3F269.dip.t-dialin.net [79.227.242.105]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA id B59521C00194; Fri, 17 Dec 2010 10:40:38 +0100 (CET) From: Anatolij Gustschin To: linux-media@vger.kernel.org Cc: Mauro Carvalho Chehab , Detlev Zundel Subject: [PATCH] media: fsl-viu: fix support for streaming with mmap method Date: Fri, 17 Dec 2010 10:40:50 +0100 Message-Id: <1292578850-7392-1-git-send-email-agust@denx.de> X-Mailer: git-send-email 1.7.1 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Fri, 17 Dec 2010 09:40:57 +0000 (UTC) diff --git a/drivers/media/video/fsl-viu.c b/drivers/media/video/fsl-viu.c index c9eb161..483a5ed 100644 --- a/drivers/media/video/fsl-viu.c +++ b/drivers/media/video/fsl-viu.c @@ -917,6 +917,8 @@ static int vidioc_streamon(struct file *file, void *priv, enum v4l2_buf_type i) if (fh->type != i) return -EINVAL; + viu_start_dma(fh->dev); + return videobuf_streamon(&fh->vb_vidq); } @@ -929,6 +931,8 @@ static int vidioc_streamoff(struct file *file, void *priv, enum v4l2_buf_type i) if (fh->type != i) return -EINVAL; + viu_stop_dma(fh->dev); + return videobuf_streamoff(&fh->vb_vidq); } @@ -1350,6 +1354,7 @@ static int viu_release(struct file *file) viu_stop_dma(dev); videobuf_stop(&fh->vb_vidq); + videobuf_mmap_free(&fh->vb_vidq); kfree(fh);