From patchwork Tue Oct 30 14:29:02 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Martin X-Patchwork-Id: 1670481 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id B10333FC36 for ; Tue, 30 Oct 2012 14:29:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932407Ab2J3O3V (ORCPT ); Tue, 30 Oct 2012 10:29:21 -0400 Received: from mail-we0-f174.google.com ([74.125.82.174]:35560 "EHLO mail-we0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932305Ab2J3O3S (ORCPT ); Tue, 30 Oct 2012 10:29:18 -0400 Received: by mail-we0-f174.google.com with SMTP id t9so153345wey.19 for ; Tue, 30 Oct 2012 07:29:16 -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=FK4m/G7fM65uVadJDBZDGBvm+VCDL+FHgtwqGkzIQeFPAehlEMlMNZXJgkOukXh149 v6y4GHKrhfBAo3CHV5NPe/TFPpe4oxMnKnrqP2doO4sJ7al3bSd8aMTRGQVOtO5KKTHD Qgbtej9vaXw0NcC9LjDkhenNtgPZrdOGrCB4pTMk68sbFvVtMI5UAPHzprhyPxlz4hqM m4BbCRiplq6dX2TPV80vh3ruZqimRg3lWjBFbDz6bJHQ6kgfu/lQiqcjt/HAGALrw/4G Iy7Km/t4tsjUHS+sI47vFZ9HY/B2OwWJjck0UTOs9kGw6UXIuquDA0/5cZ3xko+ciacp PFSQ== Received: by 10.216.218.73 with SMTP id j51mr15593586wep.161.1351607356868; Tue, 30 Oct 2012 07:29:16 -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 v3sm1455206wiy.5.2012.10.30.07.29.15 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 30 Oct 2012 07:29:16 -0700 (PDT) From: Javier Martin To: linux-media@vger.kernel.org Cc: g.liakhovetski@gmx.de, fabio.estevam@freescale.com, Javier Martin Subject: [PATCH v2 4/4] media: mx2_camera: Remove buffer states. Date: Tue, 30 Oct 2012 15:29:02 +0100 Message-Id: <1351607342-18030-5-git-send-email-javier.martin@vista-silicon.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1351607342-18030-1-git-send-email-javier.martin@vista-silicon.com> References: <1351607342-18030-1-git-send-email-javier.martin@vista-silicon.com> X-Gm-Message-State: ALoCoQkA8MRH3T8hz4fJ3Mhn0xLmebz9xkJ1aG79YK28LSdeBmbSvjYSSabFbrNnLAFlH+odbjLv 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);