From patchwork Thu Dec 15 12:16:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 33590 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp315983wrn; Thu, 15 Dec 2022 04:18:53 -0800 (PST) X-Google-Smtp-Source: AA0mqf4kQtrWMhjDbjsIXIbHZ4DuMsMZlaxdSIx/mTWTmpUWiFCwnvcsvaq8dhV53ZmBTPOSOpKF X-Received: by 2002:a05:6a20:bf19:b0:ad:2abb:5a5b with SMTP id gc25-20020a056a20bf1900b000ad2abb5a5bmr29261669pzb.9.1671106733118; Thu, 15 Dec 2022 04:18:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671106733; cv=none; d=google.com; s=arc-20160816; b=ZHtE6ByQa1uTswi0RT6WXn4gMWmAuvT0YB3vYZx/kv/R8ORw4iU02nZdmZlfYiO7RL udK3PjmFbChe7TXMxgW0X9+uF36hoao9urQ7cGvdBxLtB3Y9q8fHIXJmVueAYvqi8nEs 9/3zlVupYONory+X0LyQU0G+r1vfIeLjdIfQz2tQUYZsy1cwmE51tmEynixB/ff7hA5r zQ56X4O5lYKPw0R8oo4FrB6MsYR29m6daH8KXaSxbLaAJTbIiQ4B9JqcQ7sTJz4Riaej /Ww8xOwbEPIk9+jlpXWbsKKi0A9KhIVBY1H7TxpXIJ/QWdv8aIaMV4QZPAfAJtk4lu/9 iMQw== 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=Cxj//Vyg/LtUPJ2/Wq39BX4YMn5jim0sj49GJ3sp5CE=; b=L2yuoc3cYPu67HBZCWjADl0f9NNOEYq60hPMafvKQMGKNRMrNuC14Czzb5M8aqlmKw Crm5xrNYbGQvZyIpdgIXSd0ZyBYojycsz5CVAXyY0eJffx62CaCYzuJ0egATSSF/O9iJ KNU3C2eHqW+NiuHQ8VIKJUaWlLk4ByrMt6GWtPuJyr2Pn4Vxym2UZrFxYkYsJrI/Aa6Y cR56GMHKEX2Pu5KcNmvZOMzWI9iU3fbOyDj9Lcdpqysqr9CwvOyth8oeZazYT33MhNhZ SlcX1WIQPSYKXdqm/Z+ihCoW3p7Degg9nonJx/I8H/Rrj8MJ3oDSEkVgreOrXdmFDuTh HZdw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=sxQm40+d; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u30-20020a056a00099e00b00557a43656c6si2955042pfg.109.2022.12.15.04.18.38; Thu, 15 Dec 2022 04:18:53 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=sxQm40+d; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230029AbiLOMRV (ORCPT + 99 others); Thu, 15 Dec 2022 07:17:21 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40332 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230160AbiLOMRL (ORCPT ); Thu, 15 Dec 2022 07:17:11 -0500 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8574523178; Thu, 15 Dec 2022 04:17:10 -0800 (PST) Received: from desky.lan (91-154-32-225.elisa-laajakaista.fi [91.154.32.225]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 4D0C112EF; Thu, 15 Dec 2022 13:17:07 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1671106627; bh=y/7z+exO+3f1Axqi62tJwCC4d2zlinCaszJ+iZVM2HQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=sxQm40+dUXFZC+9IauWEXMecv+PvTb9oTjOAf/PzrQEVs5TFUnvhsVUaDIbSvpj/p dyHYr+say1Du6XHw3uoBtj3UCBOR/nv06HXA+ncZ6mBezaGDgtW9qGzwrp1W85b+fE rGSr9eo7InysXwRLCDVODgeojwGf8+Dv1f0Aa+KE= From: Tomi Valkeinen To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, sakari.ailus@linux.intel.com, Jacopo Mondi , Laurent Pinchart , niklas.soderlund+renesas@ragnatech.se, Mauro Carvalho Chehab , Hans Verkuil , satish.nagireddy@getcruise.com, Tomasz Figa Cc: Tomi Valkeinen Subject: [PATCH v16 02/20] media: add V4L2_SUBDEV_FL_STREAMS Date: Thu, 15 Dec 2022 14:16:16 +0200 Message-Id: <20221215121634.287100-3-tomi.valkeinen@ideasonboard.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221215121634.287100-1-tomi.valkeinen@ideasonboard.com> References: <20221215121634.287100-1-tomi.valkeinen@ideasonboard.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS 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-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752282413913790302?= X-GMAIL-MSGID: =?utf-8?q?1752282413913790302?= Add subdev flag V4L2_SUBDEV_FL_STREAMS. It is used to indicate that the subdev supports the new API with multiplexed streams (routing, stream configs). Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart --- include/media/v4l2-subdev.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/include/media/v4l2-subdev.h b/include/media/v4l2-subdev.h index 2f80c9c818ed..4be0a590c7c7 100644 --- a/include/media/v4l2-subdev.h +++ b/include/media/v4l2-subdev.h @@ -879,6 +879,17 @@ struct v4l2_subdev_internal_ops { * should set this flag. */ #define V4L2_SUBDEV_FL_HAS_EVENTS (1U << 3) +/* + * Set this flag if this subdev supports multiplexed streams. This means + * that the driver supports routing and handles the stream parameter in its + * v4l2_subdev_pad_ops handlers. More specifically, this means: + * + * - Centrally managed subdev active state is enabled + * - Legacy pad config is _not_ supported (state->pads is NULL) + * - Routing ioctls are available + * - Multiple streams per pad are supported + */ +#define V4L2_SUBDEV_FL_STREAMS (1U << 4) struct regulator_bulk_data;