From patchwork Thu Aug 23 13:08:27 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ezequiel Garcia X-Patchwork-Id: 1367021 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 5CE47DF2AB for ; Thu, 23 Aug 2012 13:09:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758858Ab2HWNJK (ORCPT ); Thu, 23 Aug 2012 09:09:10 -0400 Received: from mail-yx0-f174.google.com ([209.85.213.174]:47914 "EHLO mail-yx0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758852Ab2HWNJI (ORCPT ); Thu, 23 Aug 2012 09:09:08 -0400 Received: by mail-yx0-f174.google.com with SMTP id l14so168915yen.19 for ; Thu, 23 Aug 2012 06:09:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; bh=0mNHDooLOvwZZbuXPhzDKT1iR2gCqExYVWoM9bCQHbE=; b=fI7iam+DsQYq08ntwjPLwS+mnPz1oAEHc1n7XhfdZwXxDpdoZfws9/d+BKUhieLTKl 6OMtISYnK2N9hO1gT1jP+YzfcZ3q9cLrPTKInUvbH5m6/EoRu2vtIghtTP4LBntAqcDp esE+/+POv6maUQNHYry6PyBpbG63SduLtA9jPUyKnnOpcZ5nv8PIhHVd3nKA/cFHUtW1 5mTi27zct9UxO707OsMzWiY3noioIh+OJauqooi4T74Cs7A2uz/34R59zByZPMNY//HO BqzS6484gwN4khTHpjPPD9LY/wINQWS6fj9JenRaixfdulFRkLy/yOT6/DHy2OX93rNq dkxw== Received: by 10.236.177.70 with SMTP id c46mr1174392yhm.33.1345727348008; Thu, 23 Aug 2012 06:09:08 -0700 (PDT) Received: from localhost.cpe.express.com.ar ([200.81.126.15]) by mx.google.com with ESMTPS id v5sm6703664anj.16.2012.08.23.06.09.05 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 23 Aug 2012 06:09:07 -0700 (PDT) From: Ezequiel Garcia To: Mauro Carvalho Chehab , Cc: Ezequiel Garcia , Javier Martin Subject: [PATCH 06/10] mem2mem-deinterlace: Remove unneeded struct vb2_queue clear on queue_init() Date: Thu, 23 Aug 2012 10:08:27 -0300 Message-Id: <1345727311-27478-6-git-send-email-elezegarcia@gmail.com> X-Mailer: git-send-email 1.7.8.6 In-Reply-To: <1345727311-27478-1-git-send-email-elezegarcia@gmail.com> References: <1345727311-27478-1-git-send-email-elezegarcia@gmail.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org queue_init() is always called by v4l2_m2m_ctx_init(), which allocates a context struct v4l2_m2m_ctx with kzalloc. Therefore, there is no need to clear vb2_queue src/dst structs. Cc: Javier Martin Signed-off-by: Ezequiel Garcia --- drivers/media/platform/m2m-deinterlace.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/m2m-deinterlace.c b/drivers/media/platform/m2m-deinterlace.c index a38c152..9afd930 100644 --- a/drivers/media/platform/m2m-deinterlace.c +++ b/drivers/media/platform/m2m-deinterlace.c @@ -861,7 +861,6 @@ static int queue_init(void *priv, struct vb2_queue *src_vq, struct deinterlace_ctx *ctx = priv; int ret; - memset(src_vq, 0, sizeof(*src_vq)); src_vq->type = V4L2_BUF_TYPE_VIDEO_OUTPUT; src_vq->io_modes = VB2_MMAP | VB2_USERPTR; src_vq->drv_priv = ctx; @@ -878,7 +877,6 @@ static int queue_init(void *priv, struct vb2_queue *src_vq, if (ret) return ret; - memset(dst_vq, 0, sizeof(*dst_vq)); dst_vq->type = V4L2_BUF_TYPE_VIDEO_CAPTURE; dst_vq->io_modes = VB2_MMAP | VB2_USERPTR; dst_vq->drv_priv = ctx;