Message ID | 20231127165454.166373-31-benjamin.gaignard@collabora.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:ce62:0:b0:403:3b70:6f57 with SMTP id o2csp3287164vqx; Mon, 27 Nov 2023 08:57:40 -0800 (PST) X-Google-Smtp-Source: AGHT+IGVg4cRVWAD9wENBtrqxh8h2AQXSgzLoLIAOKY7FWXgO3YP3XsfiJNiUXUlhugB4fxhcI26 X-Received: by 2002:a05:6a20:231c:b0:18a:181b:146b with SMTP id n28-20020a056a20231c00b0018a181b146bmr10273994pzc.29.1701104260169; Mon, 27 Nov 2023 08:57:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701104260; cv=none; d=google.com; s=arc-20160816; b=i1qLBNkB4A2QF5wh7gt6BjBWSMCBrbBbfeuXJEWg4oXBTrW7dj1N03FAaow8eSoLtw daxsDoW7Y/SQWmd9ItmBfuUVMq/Vj8ERor7+SuZmUWWkPhpYIWFCC7vthLx4iFSCEiYx 5bDdsPz2EANEFEbQsa/LXgTEwehMIDM6Hi3sU8R7nYm8siC5BjKFA/M5eH5rxn+jINDk ozkTyNOtODk+YhkLEY76kUH4Ws/qmSdoF0IRSkkFy/ulzzbAf/utePl6xmse2ZWBDJxC EOIJ9r7QeokGqAP5kikW5zbQ44G8HOinmXDHQTCgDq/5s+MKGh73fqczzRHRprq9dt++ /Nvg== 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=YO8ZbCK4F96297U70V/VyU3CrIjv/eZj30bPJelfNO0=; fh=Ii5lzIwlPwiIG77j6pgmC0MBzqe9ZH9Q/2bd7fs8CXs=; b=mqYN3fwquuWqb+B+xRwKA7IzHfvJb2jUADll9uW67KQDsBvysxjQu5IUIRAiIVOa4v o7R67ulKKNRKFR2el6UST2G2/qfglwRNtbuulctVmPhTncYWSog+7tj//NAjgvJX2CG8 ZuTb9XvoWlzc0G4jRdhQvTOQ4wNhZ4nIOEHkdfD/AJbqo49+Ssxx+fudQAW95aGDXcEV ZzUi0DutwX+b3xOcHtVHNU7Eg67N1yv5+2MlUvbiv1zXF0hqPuKM2ncco5ElmpgE19jw MP4okOx6vAk5Zwh/nuZJ5J8frIY5v3OFhenjkgakv6jux+FuJXWDsLXbpDVSdxTXGH6I i8EA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=EYVQNlDh; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 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 howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id g10-20020a056a0023ca00b006b3aded7e97si10751351pfc.305.2023.11.27.08.57.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 Nov 2023 08:57:40 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=EYVQNlDh; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 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 howler.vger.email (Postfix) with ESMTP id 15930822D555; Mon, 27 Nov 2023 08:57:32 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234587AbjK0Q5V (ORCPT <rfc822;toshivichauhan@gmail.com> + 99 others); Mon, 27 Nov 2023 11:57:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51812 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234600AbjK0Qz6 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 27 Nov 2023 11:55:58 -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 E09A51FE0; Mon, 27 Nov 2023 08:55:30 -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 0844F66073D7; Mon, 27 Nov 2023 16:55:28 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1701104129; bh=3CZsTTbHLtC5vyOvtssRJvLsPSp78mQlLUyr4UEzOZ8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=EYVQNlDhTIxKDHnmG/Ekj99JD5kgVrukW22yr4FR3JKkFJU6WKYy2ELTie1khIxEW KyelEo7dOIjQRLCscyLgl3qFCVbux/fWK6ENMHTGzu0FdhiHrjucE1mvsXbMhWrGzL LGJ93g37lbE/Ky/0csRdacUDH2wGwJVi5FqvGJAl7Sy8EP2BoVrPew50Mmy29YMfN4 f7sDclJ3eyLKuP1Y7CHuq8iCBxqYBq9Cscoq7sAviNjetQpcbbBMizPSZev3xtnJBr T5IRo07rQWHE7usTvfd22nmZLmkOOGz86nuXUa8Y+evAoKVBarFSMqYIUBDH1HuSky 8/lu3VxwGRZ9A== From: Benjamin Gaignard <benjamin.gaignard@collabora.com> 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 <benjamin.gaignard@collabora.com>, Benoit Parrot <bparrot@ti.com> Subject: [PATCH 30/55] media: ti: cal: Stop abusing of min_buffers_needed field Date: Mon, 27 Nov 2023 17:54:29 +0100 Message-Id: <20231127165454.166373-31-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=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, 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 howler.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Mon, 27 Nov 2023 08:57:32 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1783737100636624130 X-GMAIL-MSGID: 1783737100636624130 |
Series |
Clean up queue_setup()/min_buffers_needed (ab)use
|
|
Commit Message
Benjamin Gaignard
Nov. 27, 2023, 4:54 p.m. UTC
'min_buffers_needed' is suppose to be used to indicate the number
of buffers needed by DMA engine to start streaming.
Cal 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 <benjamin.gaignard@collabora.com>
CC: Benoit Parrot <bparrot@ti.com>
---
drivers/media/platform/ti/cal/cal-video.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/media/platform/ti/cal/cal-video.c b/drivers/media/platform/ti/cal/cal-video.c index e1c5e68e945b..04709dac7221 100644 --- a/drivers/media/platform/ti/cal/cal-video.c +++ b/drivers/media/platform/ti/cal/cal-video.c @@ -1010,7 +1010,7 @@ int cal_ctx_v4l2_init(struct cal_ctx *ctx) q->mem_ops = &vb2_dma_contig_memops; q->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC; q->lock = &ctx->mutex; - q->min_buffers_needed = 3; + q->min_reqbufs_allocation = 3; q->dev = ctx->cal->dev; ret = vb2_queue_init(q);