From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 03D1EC07E9C for ; Tue, 6 Jul 2021 16:13:00 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A913861A11 for ; Tue, 6 Jul 2021 16:12:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A913861A11 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=cerno.tech Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 12AB289FBC; Tue, 6 Jul 2021 16:12:59 +0000 (UTC) Received: from new3-smtp.messagingengine.com (new3-smtp.messagingengine.com [66.111.4.229]) by gabe.freedesktop.org (Postfix) with ESMTPS id E29D689FBC for ; Tue, 6 Jul 2021 16:12:57 +0000 (UTC) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailnew.nyi.internal (Postfix) with ESMTP id 1823358050E; Tue, 6 Jul 2021 12:12:56 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Tue, 06 Jul 2021 12:12:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; s=fm3; bh=qn7dpQZ55SUQEOBzkrP6w9EUZY ix4DKNCT0/czlLkVI=; b=PRoKgkspfHqZl6441cnwEQgpo59mdQaPIfD6vmgf3o f8jb6qaVVENX7jKk4CNSpjQHx99+7IBU30DtAsbKQ3eC/Eken+Yc+4w7JDfJucPC pPgivWhTd+1jd1lbRmZeaB+rsMauRbn52PuT6L2UpBzI9+SQcBhhh/cgWYReF3Ku VEXFgt6bDR2SpKUL/H0w+mEaJxixD5wDF/lWllJ6X3Yl8bDgLsHsZOoRL+OfRrBC LxGLQnguCbFq2wRLd4C6qDBGjLbBzAu5BEyl67LmH9iBHsoZ+PHdkCmRgq+/HNBE 7iFXmG+utbhDcX7gb9zLfrgh70Vtm8iE+UVTgY/ipfBg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:message-id:mime-version:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=qn7dpQ Z55SUQEOBzkrP6w9EUZYix4DKNCT0/czlLkVI=; b=ZmbPNn//B0h31Ia+Y9oL+C ShuQOkiILu0sl8hMJJXYpxXK/RDhXLFPrmBHt9kHBamdg48DSEjo+5jGrMz++Umd yvHuusSBLNuUt/8/cO/Ng3oiZI48TC9kwKtZNmzmufsCxveopPq7VXNUZbIFIqxd yJw3hW1fUvdb1pbZDW1Q322Q5XrWrmRt6lhI+dLnRGXxvW6ZN87Wg7RUNIfLmnAS X6sU0hewvMh4f4JoBPpa7f2hpzc5xZxc/6Ox2W+ZYpAH+tOixBEnZUYAsY3CZIPj kiCSa3TVjEUN+N8ihy4s0HVhtxvkaAwJmkY4DtjfB+DW1KrRTYuL/gOG5IAq8TLg == X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvtddrtddtgdehiecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkofggtgfgsehtkeertdertdejnecuhfhrohhmpeforgigihhmvgcu tfhiphgrrhguuceomhgrgihimhgvsegtvghrnhhordhtvggthheqnecuggftrfgrthhtvg hrnhephedvgfeujefgfefhleefjedtteduvdfftdetgffgfedtgfffkeelfeejvdegiefh necuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepmhgrgi himhgvsegtvghrnhhordhtvggthh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 6 Jul 2021 12:12:46 -0400 (EDT) From: Maxime Ripard To: dri-devel@lists.freedesktop.org, Daniel Vetter , David Airlie , Maarten Lankhorst , Thomas Zimmermann , Maxime Ripard Subject: [PATCH v5] Documentation: gpu: Mention the requirements for new properties Date: Tue, 6 Jul 2021 18:12:44 +0200 Message-Id: <20210706161244.1038592-1-maxime@cerno.tech> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Xinliang Liu , Anitha Chrisanthus , Jonathan Hunter , Jerome Brunet , Kevin Hilman , Ludovic Desroches , NXP Linux Team , Sascha Hauer , Roland Scheidegger , Sean Paul , Hyun Kwon , Andrew Jeffery , Seung-Woo Kim , =?UTF-8?q?Noralf=20Tr=C3=B8nnes?= , Pengutronix Kernel Team , Alex Deucher , Laurent Pinchart , Alexandre Belloni , linux-doc@vger.kernel.org, Edmund Dea , Eric Anholt , Thierry Reding , Krzysztof Kozlowski , Steven Price , VMware Graphics , Ben Skeggs , Martin Blumenstingl , Rodrigo Siqueira , Boris Brezillon , Sandy Huang , Kyungmin Park , Maxime Coquelin , Haneen Mohammed , Neil Armstrong , Melissa Wen , Gerd Hoffmann , Benjamin Gaignard , Sam Ravnborg , Jonathan Corbet , Xinwei Kong , Chen-Yu Tsai , Alyssa Rosenzweig , Chun-Kuang Hu , Jonas Karlman , Chen Feng , Alison Wang , Rodrigo Vivi , Tomeu Vizoso , Tomi Valkeinen , Kieran Bingham , Tian Tao , Shawn Guo , =?UTF-8?q?Christian=20K=C3=B6nig?= , Daniel Vetter , Liviu Dudau , Alexandre Torgue , Paul Cercueil , Andrzej Hajda , Huang Rui , Marek Vasut , Joonyoung Shim , Oleksandr Andrushchenko , Russell King , Philippe Cornu , Hans de Goede , Matthias Brugger , Jernej Skrabec , Pekka Paalanen , Yannick Fertre , Nicolas Ferre , Robert Foss , Qiang Yu , Jyri Sarha Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" New KMS properties come with a bunch of requirements to avoid each driver from running their own, inconsistent, set of properties, eventually leading to issues like property conflicts, inconsistencies between drivers and semantics, etc. Let's document what we expect. Cc: Alexandre Belloni Cc: Alexandre Torgue Cc: Alex Deucher Cc: Alison Wang Cc: Alyssa Rosenzweig Cc: Andrew Jeffery Cc: Andrzej Hajda Cc: Anitha Chrisanthus Cc: Benjamin Gaignard Cc: Ben Skeggs Cc: Boris Brezillon Cc: Brian Starkey Cc: Chen Feng Cc: Chen-Yu Tsai Cc: Christian Gmeiner Cc: "Christian König" Cc: Chun-Kuang Hu Cc: Edmund Dea Cc: Eric Anholt Cc: Fabio Estevam Cc: Gerd Hoffmann Cc: Haneen Mohammed Cc: Hans de Goede Cc: "Heiko Stübner" Cc: Huang Rui Cc: Hyun Kwon Cc: Inki Dae Cc: Jani Nikula Cc: Jernej Skrabec Cc: Jerome Brunet Cc: John Stultz Cc: Jonas Karlman Cc: Jonathan Hunter Cc: Joonas Lahtinen Cc: Joonyoung Shim Cc: Jyri Sarha Cc: Kevin Hilman Cc: Kieran Bingham Cc: Krzysztof Kozlowski Cc: Kyungmin Park Cc: Laurent Pinchart Cc: Linus Walleij Cc: Liviu Dudau Cc: Lucas Stach Cc: Ludovic Desroches Cc: Marek Vasut Cc: Martin Blumenstingl Cc: Matthias Brugger Cc: Maxime Coquelin Cc: Maxime Ripard Cc: Melissa Wen Cc: Neil Armstrong Cc: Nicolas Ferre Cc: "Noralf Trønnes" Cc: NXP Linux Team Cc: Oleksandr Andrushchenko Cc: Patrik Jakobsson Cc: Paul Cercueil Cc: Pekka Paalanen Cc: Pengutronix Kernel Team Cc: Philippe Cornu Cc: Philipp Zabel Cc: Qiang Yu Cc: Rob Clark Cc: Robert Foss Cc: Rob Herring Cc: Rodrigo Siqueira Cc: Rodrigo Vivi Cc: Roland Scheidegger Cc: Russell King Cc: Sam Ravnborg Cc: Sandy Huang Cc: Sascha Hauer Cc: Sean Paul Cc: Seung-Woo Kim Cc: Shawn Guo Cc: Simon Ser Cc: Stefan Agner Cc: Steven Price Cc: Sumit Semwal Cc: Thierry Reding Cc: Tian Tao Cc: Tomeu Vizoso Cc: Tomi Valkeinen Cc: VMware Graphics Cc: Xinliang Liu Cc: Xinwei Kong Cc: Yannick Fertre Cc: Zack Rusin Reviewed-by: Daniel Vetter Signed-off-by: Maxime Ripard --- Changes from v4: - Changes suggested by Pekka Changes from v3: - Roll back to the v2 - Add Simon and Pekka in Cc Changes from v2: - Take into account the feedback from Laurent and Lidiu to no longer force generic properties, but prefix vendor-specific properties with the vendor name Changes from v1: - Typos and wording reported by Daniel and Alex --- Documentation/gpu/drm-kms.rst | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/Documentation/gpu/drm-kms.rst b/Documentation/gpu/drm-kms.rst index 87e5023e3f55..47994890fd1e 100644 --- a/Documentation/gpu/drm-kms.rst +++ b/Documentation/gpu/drm-kms.rst @@ -463,6 +463,36 @@ KMS Properties This section of the documentation is primarily aimed at user-space developers. For the driver APIs, see the other sections. +Requirements +------------ + +KMS drivers might need to add extra properties to support new features. +Each new property introduced in a driver need to meet a few +requirements, in addition to the one mentioned above: + +* It must be standardized, documenting: + + * The full, exact, name string; + * If the property is an enum, all the valid variants name; + * What values are accepted, and what these values mean; + * What the property does and how it can be used; + * How the property might interact with other, existing properties. + +* It must provide a generic helper in the core code to register that + property on the object it attaches to. + +* Its content must be decoded by the core and provided in the object's + associated state structure. That includes anything drivers might want + to precompute, like :c:type:`struct drm_clip_rect ` for + planes. + +* Its initial state must match the behavior prior to the property + introduction. This might be a fixed value matching what the hardware + does, or it may be inherited from the state the firmware left the + system in during boot. + +* An IGT test must be submitted where reasonable. + Property Types and Blob Property Support ---------------------------------------- -- 2.31.1