Received: by 2002:a05:7412:a9a3:b0:f9:327e:43ab with SMTP id o35csp14555rdh; Mon, 18 Dec 2023 02:58:21 -0800 (PST) X-Google-Smtp-Source: AGHT+IESQSOrQrGXyr2X17idrzx7lG87t1WhiJiqa4xOIWZdHtkoVNJVkOGSOQ2SUXIc4vG/1CcJ X-Received: by 2002:a05:6870:f60b:b0:1fa:3685:1cae with SMTP id ek11-20020a056870f60b00b001fa36851caemr9405814oab.6.1702897101525; Mon, 18 Dec 2023 02:58:21 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1702897101; cv=pass; d=google.com; s=arc-20160816; b=Tw7cYJgtSwEU0oJ3w5pMtOO0wZR1fAYJlc6HP9Is/BN3Gbcbi31T/OPUT3iVqNpNfC OIttA9CCzNW4gQMuEXGZaL5DNCB2j6wS5T+TYFc+s/cbH4yzYBDzdW3mGbLYKT11m9Ce 5sJq8RMWRgx1XzY6fBkWht0U4T67uqJtfnbrOjbX1bs7XCL5yMcbnl6VRVvRcMRsgCSL RfAvE0y4LQ6Jaa2HfaRV4ciAvPrhumN5S2YBx/HYRSnyKu4vTm7ZnRv7dshJOj2fwuaI 3+fxWdIRvpqY+av50+HlxroFjJnUw6B1gigEI6wV6IN1zOAsZFuA4gfUtON0WjZZKZ/J ERyg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:dkim-signature:dkim-signature; bh=U0UapUlvZAiZ2vADG8RSbN1Y4V7bjNd3k9xavKTkZ5s=; fh=HJaHQ3SkhD3bnR+rAhnJDorZO3lmP0UsFsQARA6A/yw=; b=AW0uvlvIfTcrpQGzd6Wtgjuybis18b0zpsUI/PGz+nxK1LP5RfenbgvJXonX5q7oFa e3RXdaZ/BEz8Lapqo9Kn9gDMASRzSSCAix9JjyiXqkmyRpuKu4nZc6RMpSrm42OGzpq/ FPszyD9yPeh6sGg09kdHT/+EU0IDseEHFJXzxFLQfVdzGcbTXt6H3DCIGuxw6LrJSa66 Hn3gdSeyU8D2avNzWFa8OROoKVErAArYhnBiZuVEE/d9TikcTnjLUvfNHIccDrIhpQd/ a1mlC0vhdl9shb5I8L1QkObi9DHr6uWX/IiWJBTpW2N73xdG1a5WOBHPING22S0+loUh O/hw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@goldelico.com header.s=strato-dkim-0002 header.b=tkTaI0Oh; dkim=neutral (no key) header.i=@goldelico.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-3393-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3393-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id t16-20020a639550000000b005cd825eac20si3746689pgn.897.2023.12.18.02.58.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 02:58:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-3393-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@goldelico.com header.s=strato-dkim-0002 header.b=tkTaI0Oh; dkim=neutral (no key) header.i=@goldelico.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-3393-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3393-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 283582840D1 for ; Mon, 18 Dec 2023 10:58:21 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 105D218E00; Mon, 18 Dec 2023 10:58:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="tkTaI0Oh"; dkim=permerror (0-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="fEGF1X4Q" X-Original-To: linux-kernel@vger.kernel.org Received: from mo4-p02-ob.smtp.rzone.de (mo4-p02-ob.smtp.rzone.de [85.215.255.82]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C1E9F1944C; Mon, 18 Dec 2023 10:58:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=goldelico.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=goldelico.com ARC-Seal: i=1; a=rsa-sha256; t=1702896901; cv=none; d=strato.com; s=strato-dkim-0002; b=C+GcctB2GqhE5bop8Aj9RGm+kcjJWxVV/3heaXkTv9vhTX7eyAZlOcaqHGA2PXXyyC lncH83/+HUJhRoraNL5YjtAQ8VBop+EUAqtfc2t67jwP3g0W914C4oK3X7V+5WO09hta LQ4GLgh5QUS2ZhiRMpIHKX2KLiT9ykHpUUMikDC5Meqe2ApH+Eg73YlJW/vPsLdjLfsf Gop5pGEWaRtX/tTXiRTC1HlrUE5g3saGPjWEDOIxYTf53qWf5Q7gkLEgx6dUD9XwSVs7 J561q2I2vony5qF9aUCiRO4YKqTKK+ZuL/Gs3BzVFR2dCPGfggC8HNtqW5kPtrp1JMy6 c6lw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; t=1702896901; s=strato-dkim-0002; d=strato.com; h=To:References:Message-Id:Cc:Date:In-Reply-To:From:Subject:Cc:Date: From:Subject:Sender; bh=U0UapUlvZAiZ2vADG8RSbN1Y4V7bjNd3k9xavKTkZ5s=; b=SqXimfrdqSbDrbIcTsW9GvZlZ4BKJ8VOGJXQ9zoEtMDpW2sYYZYxERuqMSj7GZyHtM wq8lhT9DPu3BP3WeEdSBxnWfakbXMv4aSHL5mOvaHT4Fxdo+pAhx68u6HMT3p1BhCj1g dq48iPBC1YQb2OlRfk+4yRqIbUJQQFlcf5bro+3jRWu04J2ADoWeGJqnkkkUa0Vk3SzV 3x23HKoW6FK4/p1k6VUfof+DiyBR9TQk/jZjNR5CKOZnNh/iHMMem+UglLcGwWoniP7m /shsqGAdI4YsbUtAEWiB4Muo2s/5WC3ZZRh5udrpvJTLx4nTvSHcdYd5bDX/v+0MpQNW d1Jw== ARC-Authentication-Results: i=1; strato.com; arc=none; dkim=none X-RZG-CLASS-ID: mo02 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1702896901; s=strato-dkim-0002; d=goldelico.com; h=To:References:Message-Id:Cc:Date:In-Reply-To:From:Subject:Cc:Date: From:Subject:Sender; bh=U0UapUlvZAiZ2vADG8RSbN1Y4V7bjNd3k9xavKTkZ5s=; b=tkTaI0OhlJnGUpdWsmYDXz3rc4fbPUDshnl007mxxpaFyOcDPo4Jjm8icZ07wJ1duH 331yCr6XMhsFtR7JeCGIu8PNznLr3nUVBLprXLQpsJkq6IsSGeQ1LLGcX9OA3KqQMxTo QPMhDPvsB8QctNdfPlELTimAW/GriyrBhT86vhk1VPk9HLM0IrnMpd1o63J5byOiK9iM B3tI2jAMJFnwHmFp6eN9cGXuLDmAp3lO1B5bo3huqZLsizXqPxje8zyvhvxGgwdRjpDb 8pPbfMda7f34XKf6r3Kv4emZyi4Bv+Ac1i+TXvIUeLv4i+vYDndrd61Jl4i8DbsCaMCW UQcQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; t=1702896901; s=strato-dkim-0003; d=goldelico.com; h=To:References:Message-Id:Cc:Date:In-Reply-To:From:Subject:Cc:Date: From:Subject:Sender; bh=U0UapUlvZAiZ2vADG8RSbN1Y4V7bjNd3k9xavKTkZ5s=; b=fEGF1X4Qn4cXKR2AN33frlccmWNT6IjflrJ4mcAVngWY8hfloycKBf45tTF+K8JX8a skRkNOcU6ku1DV0LdhCQ== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMgPgp8VKxflSZ1P34KBj5Apz9PSN6LgsXcGZiDY=" Received: from smtpclient.apple by smtp.strato.de (RZmta 49.10.0 DYNA|AUTH) with ESMTPSA id wfeb35zBIAswzma (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve X9_62_prime256v1 with 256 ECDH bits, eq. 3072 bits RSA)) (Client did not present a certificate); Mon, 18 Dec 2023 11:54:58 +0100 (CET) Content-Type: text/plain; charset=us-ascii Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.300.61.1.2\)) Subject: Re: [PATCH RFC 01/10] dt-bindings: gpu: Add PowerVR Series5 SGX GPUs From: "H. Nikolaus Schaller" In-Reply-To: <22cny5aumc5wafsrjd3j55zcjbjf2viip64kfbjiqis2grtd6t@wg5dxeuzil6l> Date: Mon, 18 Dec 2023 11:54:47 +0100 Cc: Andrew Davis , Frank Binns , Donald Robson , Matt Coster , Adam Ford , Ivaylo Dimitrov , Maarten Lankhorst , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , =?utf-8?Q?Beno=C3=AEt_Cousson?= , Tony Lindgren , Nishanth Menon , Vignesh Raghavendra , Tero Kristo , Paul Cercueil , dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-omap@vger.kernel.org, linux-mips@vger.kernel.org Content-Transfer-Encoding: quoted-printable Message-Id: <3E03E913-48E1-49EC-A6C9-EAC1612E65E7@goldelico.com> References: <20231204182245.33683-1-afd@ti.com> <20231204182245.33683-2-afd@ti.com> <23livt5mcc64bb6lkeec2uxp5cyn4wfekwaj6wzrjnrkndvwgj@6tveqglqpr4v> <6BC60156-89E2-4734-BD00-B49A9A6C1D7A@goldelico.com> <6gpehpoz54f5lxhmvirqbfwmq7dpgiroy27cljpvu66wtn7aqy@lgrh7wysyxnp> <22cny5aumc5wafsrjd3j55zcjbjf2viip64kfbjiqis2grtd6t@wg5dxeuzil6l> To: Maxime Ripard X-Mailer: Apple Mail (2.3774.300.61.1.2) > Am 18.12.2023 um 11:14 schrieb Maxime Ripard : >=20 > On Mon, Dec 18, 2023 at 10:28:09AM +0100, H. Nikolaus Schaller wrote: >> Hi Maxime, >>=20 >>> Am 15.12.2023 um 14:33 schrieb Maxime Ripard : >>>=20 >>>>>=20 >>>>> It's for a separate architecture, with a separate driver, = maintained out >>>>> of tree by a separate community, with a separate set of = requirements as >>>>> evidenced by the other thread. And that's all fine in itself, but >>>>> there's very little reason to put these two bindings in the same = file. >>>>>=20 >>>>> We could also turn this around, why is it important that it's in = the >>>>> same file? >>>>=20 >>>> Same vendor. And enough similarity in architectures, even a logical = sequence >>>> of development of versions (SGX =3D Version 5, Rogue =3D Version = 6+) behind. >>>> (SGX and Rogue seem to be just trade names for their architecture = development). >>>=20 >>> Again, none of that matters for *where* the binding is stored. >>=20 >> So what then speaks against extending the existing bindings file as = proposed >> here? >=20 > I mean, apart from everything you quoted, then sure, nothing speaks > against it. >=20 >>>> AFAIK bindings should describe hardware and not communities or = drivers >>>> or who is currently maintaining it. The latter can change, the = first not. >>>=20 >>> Bindings are supposed to describe hardware indeed. Nothing was ever = said >>> about where those bindings are supposed to be located. >>>=20 >>> There's hundreds of other YAML bindings describing devices of the = same >>> vendors and different devices from the same generation. >>=20 >> Usually SoC seem to be split over multiple files by subsystem. Not by = versions >> or generations. If the subsystems are similar enough they share the = same bindings >> doc instead of having one for each generation duplicating a lot of = code. >>=20 >> Here is a comparable example that combines multiple vendors and = generations: >>=20 >> Documentation/devicetree/bindings/usb/generic-ehci.yaml >=20 > EHCI is a single interface for USB2.0 controllers. It's a standard = API, > and is made of a single driver that requires minor modifications to = deal > with multiple devices. >=20 > We're very far from the same situation here. How far are we really? And, it is the purpose of the driver to handle = different cases. That there are currently two drivers is just a matter of history and not = a necessity. >=20 >>> If anything it'll make it easier for you. I'm really not sure why it = is >>> controversial and you're fighting this so hard. >>=20 >> Well, you made it controversial by proposing to split what IMHO = belongs together. >=20 > No, reviews aren't controversial. > The controversy started when you chose > to oppose it while you could have just rolled with it. Well, you asked "I think it would be best to have a separate file for this, img,sgx.yaml maybe?" and "Because it's more convenient?" I understood that as an invitation for discussing the pros and cons and = working out the most convenient solution. And that involves playing the devil's advocate = which of course is controversial by principle. Now, IMHO all the pros and cons are on the table and the question is who = makes a decision how to go. >=20 >> I feel that the original patch is good enough for its purpose and = follows >> some design pattern that can be deduced from other binding docs. >=20 > [citation needed] Joke: Documentation/devicetree/bindings/* - I am not aware of a formal = analysis of course. But see my example for ehci. It follows the pattern I mean. If clocks, = regs, interrupts, resets, and more properties are (almost) the same, then group them and = just differentiate by different compatible strings. If necessary use some - if: clauses. It is the task of drivers to handle the details. As my other (maybe more important) comment to this patch did indicate we = IMHO can easily live with something like + - items: + - enum: + - ti,am62-gpu # IMG AXE GPU model/revision is fully = discoverable + - ti,omap3430-gpu # sgx530 Rev 121 + - ti,omap3630-gpu # sgx530 Rev 125 + - ingenic,jz4780-gpu # sgx540 Rev 130 + - ti,omap4430-gpu # sgx540 Rev 120 + - allwinner,sun6i-a31-gpu # sgx544 MP2 Rev 115 + - ti,omap4470-gpu # sgx544 MP1 Rev 112 + - ti,omap5432-gpu # sgx544 MP2 Rev 105 + - ti,am5728-gpu # sgx544 MP2 Rev 116 + - ti,am6548-gpu # sgx544 MP1 Rev 117 And leave it to drivers using a table to deduce the generation and revision or read it out from the chip. And there can even be different drivers handling only a subset of the potential compatibles. Then the currently-out-of-tree driver for the sgx5 can be reworked in less than half an hour without loosing functionality. BR, Nikolaus