From patchwork Tue Oct 30 12:16:35 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Martin X-Patchwork-Id: 1670171 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 2AA76DF264 for ; Tue, 30 Oct 2012 12:17:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933562Ab2J3MRO (ORCPT ); Tue, 30 Oct 2012 08:17:14 -0400 Received: from mail-ea0-f174.google.com ([209.85.215.174]:58820 "EHLO mail-ea0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932930Ab2J3MQy (ORCPT ); Tue, 30 Oct 2012 08:16:54 -0400 Received: by mail-ea0-f174.google.com with SMTP id c13so82741eaa.19 for ; Tue, 30 Oct 2012 05:16:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=In/8lUCbNtzSMGuj+GnuZtvXVTLCY1kslhnlqb9Lrx0=; b=ZqbCnxh67bymph+mAfBpIvKnFbKafcVwrQxu/TjKaM12Lecs9HTx5TJ3B+3iZWXnfl F8aOS61boZEqTwN+vDx0d/YOXS1XzCodHkXDzJ2t8U1N+4XVyR31R2kOyuz5ZHMwVrdD 8YrtUbfXuvRzXnVvkFc8oxGUoJ46wSPQunL8spyjeSFz4clFdK8qSByCDNFKKssiXEQs qoHKj0jf6mhAW9xegC3kI2Ztr8CPVXlcKLPJXRGD/dFSgMJKQtuUBW/+Sf2uxxyTK7BP a3nwGjiGMqD/Okq8ZErtLh6ntd66dHp2keF4PYwzsZAaru7BZ4QVnRlUjecHDDtQpqKP idyQ== Received: by 10.14.203.69 with SMTP id e45mr72795054eeo.38.1351599412829; Tue, 30 Oct 2012 05:16:52 -0700 (PDT) Received: from piscis.vsilicon.net (149.93.18.95.dynamic.jazztel.es. [95.18.93.149]) by mx.google.com with ESMTPS id f3sm1139497eeo.13.2012.10.30.05.16.51 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 30 Oct 2012 05:16:52 -0700 (PDT) From: Javier Martin To: linux-media@vger.kernel.org Cc: g.liakhovetski@gmx.de, fabio.estevam@freescale.com, Javier Martin Subject: [PATCH 4/4] media: mx2_camera: Remove buffer states. Date: Tue, 30 Oct 2012 13:16:35 +0100 Message-Id: <1351599395-16833-5-git-send-email-javier.martin@vista-silicon.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1351599395-16833-1-git-send-email-javier.martin@vista-silicon.com> References: <1351599395-16833-1-git-send-email-javier.martin@vista-silicon.com> X-Gm-Message-State: ALoCoQk6rWnD/A9sJzelqJC5tCEeeD/TZinupizsCaYeKcqLobS2VDHcNwoKAsUSNiLMVIP1K7ZV Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org After removing i.mx25 support and buf_cleanup() callback, buffer states are not used in the code any longer. Signed-off-by: Javier Martin --- drivers/media/platform/soc_camera/mx2_camera.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/drivers/media/platform/soc_camera/mx2_camera.c b/drivers/media/platform/soc_camera/mx2_camera.c index 8202cb9..a672475 100644 --- a/drivers/media/platform/soc_camera/mx2_camera.c +++ b/drivers/media/platform/soc_camera/mx2_camera.c @@ -233,12 +233,6 @@ struct mx2_fmt_cfg { struct mx2_prp_cfg cfg; }; -enum mx2_buffer_state { - MX2_STATE_QUEUED, - MX2_STATE_ACTIVE, - MX2_STATE_DONE, -}; - struct mx2_buf_internal { struct list_head queue; int bufnum; @@ -249,7 +243,6 @@ struct mx2_buf_internal { struct mx2_buffer { /* common v4l buffer stuff -- must be first */ struct vb2_buffer vb; - enum mx2_buffer_state state; struct mx2_buf_internal internal; }; @@ -545,7 +538,6 @@ static void mx2_videobuf_queue(struct vb2_buffer *vb) spin_lock_irqsave(&pcdev->lock, flags); - buf->state = MX2_STATE_QUEUED; list_add_tail(&buf->internal.queue, &pcdev->capture); spin_unlock_irqrestore(&pcdev->lock, flags); @@ -669,7 +661,6 @@ static int mx2_start_streaming(struct vb2_queue *q, unsigned int count) internal.queue); buf->internal.bufnum = 0; vb = &buf->vb; - buf->state = MX2_STATE_ACTIVE; phys = vb2_dma_contig_plane_dma_addr(vb, 0); mx27_update_emma_buf(pcdev, phys, buf->internal.bufnum); @@ -679,7 +670,6 @@ static int mx2_start_streaming(struct vb2_queue *q, unsigned int count) internal.queue); buf->internal.bufnum = 1; vb = &buf->vb; - buf->state = MX2_STATE_ACTIVE; phys = vb2_dma_contig_plane_dma_addr(vb, 0); mx27_update_emma_buf(pcdev, phys, buf->internal.bufnum); @@ -1368,7 +1358,6 @@ static void mx27_camera_frame_done_emma(struct mx2_camera_dev *pcdev, list_move_tail(pcdev->capture.next, &pcdev->active_bufs); vb = &buf->vb; - buf->state = MX2_STATE_ACTIVE; phys = vb2_dma_contig_plane_dma_addr(vb, 0); mx27_update_emma_buf(pcdev, phys, bufnum);