Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp3222147rdh; Mon, 27 Nov 2023 08:56:30 -0800 (PST) X-Google-Smtp-Source: AGHT+IHCMVVh87+iLVJoxeTcZJXfbxzd8rZeZvNySgpOsNJ63l8LiRl8BMGTcKaxiR6aIn2riFdY X-Received: by 2002:a17:902:e543:b0:1cf:5197:25ac with SMTP id n3-20020a170902e54300b001cf519725acmr21868807plf.12.1701104190383; Mon, 27 Nov 2023 08:56:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701104190; cv=none; d=google.com; s=arc-20160816; b=Ke4p3p1sl4Ctv1bteVI1aiF2a+cXzgV3jRNox7g37pR5x7WPy28cOcfnAww2NDkm/6 k0feDTKYiP+7xzIEq5y5DDu1x8gfqlQweGCZI8TqmtSv2iKexuUB/4Pyj/DwlYOB/P6B gOXHnf4gWG8wVjRz0DxyZdZsZY+UrbqzSGqrIzT/rW35u+t7h1N85baUL6WqzFZB/bw2 3A7zYEHEzrfOc33lhICwAlQoqKCsbLGhMWe7rC1u8W3lWJTNWHOAMF+OlXJ28C6QMosK VXiqXIkGmUReNGHWZFEwu1HYsXawERHZ8+ztyWh3VC6Rp/0SsKx9dPQlJtUuilc8qqPc nvpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=69GNzU8E63rekDh2ISr4W/HGvGSMPIVwrWRPEEl79Qo=; fh=4DqQzjgLUBPepKVvQj3wI6wj/GVnu7m58RDvugRHeZI=; b=umFcU2yU1I6FR+Wmo4dAvQNspeR2vdPXTv8elaKvKW7KGN76lIXy+LPk7pnJQzAJjY xunTIdCVna0mqTeDM29qKYNZs1nFaajdh1jwyUCuq05w64r+psMQU8nGSMLHw+DUsQ2U t3plT+jVa1ZFfcTTkdNoZQLIF5dIRsnx/VbjTD8MnUFs8/gE0UAOlaMq0DG05TTqRYRR AzGVllKdCjVi2cUZ4gAnQM4CkFCSuDkp0PUYM2+fQpWd81XAtXb3ng8Ank4bjEhE5ODW RJzPDoAyYH55/BFwsNYHLctbp+RoPk6VVCgStXiqJczCmciNN8qj7hmExIoUshbJoWV0 6ZVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=UyygRunY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id a18-20020a170902ecd200b001cfaba632ecsi7321302plh.340.2023.11.27.08.56.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 Nov 2023 08:56:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=UyygRunY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 21F0B80779AA; Mon, 27 Nov 2023 08:55:38 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234280AbjK0QzS (ORCPT + 99 others); Mon, 27 Nov 2023 11:55:18 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46680 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234220AbjK0QzG (ORCPT ); Mon, 27 Nov 2023 11:55:06 -0500 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F313919B; Mon, 27 Nov 2023 08:55:12 -0800 (PST) Received: from benjamin-XPS-13-9310.. (ec2-34-240-57-77.eu-west-1.compute.amazonaws.com [34.240.57.77]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: benjamin.gaignard) by madras.collabora.co.uk (Postfix) with ESMTPSA id E9E7766072EC; Mon, 27 Nov 2023 16:55:10 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1701104111; bh=/omb2mE5oy70HH/kBxdqmwaLlWf6cHg+GYUl9K/Xqzo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UyygRunYjRkADBLKm+WPF/uWjoPZcVap4oKYXcLdaRC88jMZmnDU+EfLGW7qTd5PE ymFjgeVJlgGiAt59YziOGCV821Io/7/yu4OJGU1nOEfM1ZSR6lPcRQrZBofG0xAPNR RloGvqNXRoGjpoYltJJjTGRAtwvYlE4QxeV4LuBYrfuZHzyrx0tFB8qlLsHOK/zfx4 4eWJByOcHtfS4j3e8OgsW2eHI/aeJMJG0wyasx+YcTt6eH2+YE3xejO5KPWkBBj2tX bxwCjvK2sJrjCcZg+0TxE8KqYmnHZwT+1oYFYFL3zb+V2DKWurp/PSI1g3bZVRB4wF ww/bxPqt7IzEQ== From: Benjamin Gaignard To: hverkuil@xs4all.nl, mchehab@kernel.org, tfiga@chromium.org, m.szyprowski@samsung.com, matt.ranostay@konsulko.com Cc: linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linux-staging@lists.linux.dev, kernel@collabora.com, Benjamin Gaignard , Rui Miguel Silva , Laurent Pinchart , Martin Kepplinger , Purism Kernel Team , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team Subject: [PATCH 08/55] media: imx7-media-csi: Stop abusing of min_buffers_needed field Date: Mon, 27 Nov 2023 17:54:07 +0100 Message-Id: <20231127165454.166373-9-benjamin.gaignard@collabora.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231127165454.166373-1-benjamin.gaignard@collabora.com> References: <20231127165454.166373-1-benjamin.gaignard@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Mon, 27 Nov 2023 08:55:38 -0800 (PST) 'min_buffers_needed' is suppose to be used to indicate the number of buffers needed by DMA engine to start streaming. imx7-media-csi driver doesn't use DMA engine and just want to specify the minimum number of buffers to allocate when calling VIDIOC_REQBUFS. That 'min_reqbufs_allocation' field purpose so use it. Signed-off-by: Benjamin Gaignard CC: Rui Miguel Silva CC: Laurent Pinchart CC: Martin Kepplinger CC: Purism Kernel Team CC: Mauro Carvalho Chehab CC: Shawn Guo CC: Sascha Hauer CC: Pengutronix Kernel Team CC: Fabio Estevam CC: NXP Linux Team --- drivers/media/platform/nxp/imx7-media-csi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/platform/nxp/imx7-media-csi.c b/drivers/media/platform/nxp/imx7-media-csi.c index 1d2464ca59b8..dcc8c54228e4 100644 --- a/drivers/media/platform/nxp/imx7-media-csi.c +++ b/drivers/media/platform/nxp/imx7-media-csi.c @@ -1676,7 +1676,7 @@ static int imx7_csi_video_init(struct imx7_csi *csi) vq->mem_ops = &vb2_dma_contig_memops; vq->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC; vq->lock = &csi->vdev_mutex; - vq->min_buffers_needed = 2; + vq->min_reqbufs_allocation = 2; vq->dev = csi->dev; ret = vb2_queue_init(vq); -- 2.39.2