[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b606b44d-6b2f-4b0f-912d-b73847073616@linaro.org>
Date: Wed, 29 Nov 2023 11:16:34 +0100
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Geert Uytterhoeven <geert@...ux-m68k.org>
Cc: Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Conor Dooley <conor+dt@...nel.org>,
Matthias Brugger <matthias.bgg@...il.com>,
AngeloGioacchino Del Regno
<angelogioacchino.delregno@...labora.com>,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org, Andrew Davis <afd@...com>,
Andrew Lunn <andrew@...n.ch>, Arnd Bergmann <arnd@...db.de>,
Bjorn Andersson <andersson@...nel.org>,
Chen-Yu Tsai <wens@...nel.org>,
Dmitry Baryshkov <dmitry.baryshkov@...aro.org>,
Geert Uytterhoeven <geert+renesas@...der.be>,
Heiko Stuebner <heiko@...ech.de>,
Jonathan Corbet <corbet@....net>,
Konrad Dybcio <konrad.dybcio@...aro.org>,
Michal Simek <michal.simek@....com>,
Neil Armstrong <neil.armstrong@...aro.org>,
Nishanth Menon <nm@...com>, Olof Johansson <olof@...om.net>,
Rafał Miłecki <zajec5@...il.com>,
linux-rockchip@...ts.infradead.org,
linux-samsung-soc@...r.kernel.org,
linux-amlogic@...ts.infradead.org, linux-arm-msm@...r.kernel.org,
workflows@...r.kernel.org, linux-doc@...r.kernel.org
Subject: Re: [PATCH v3] docs: dt-bindings: add DTS Coding Style document
On 27/11/2023 15:19, Geert Uytterhoeven wrote:
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/dts-coding-style.rst
>
>> + /* SoC DTSI */
>> +
>> + / {
>> + cpus {
>> + /* ... */
>> + };
>> +
>> + psci {
>> + /* ... */
>> + };
>> +
>> + soc@ {
>
> "soc@" is invalid, that should be "soc".
soc@0 is valid.
>
> As the "soc" node is special, you may want to elaborate:
>
> compatible = "simple-bus";
> #address-cells = <1>;
> #size-cells = <1>;
> ranges;
but then we go to missing address/size cells in root node. Your comment
is in general correct, but what you propose here is not a coding style,
but DTS correctness and I only wanted to show the order of nodes. dtc
already enforces the proper unit addresses, ranges and cells.
>
>> + dma: dma-controller@...00 {
>> + /* ... */
>> + };
>> +
>> + clk: clock-controller@...00 {
>> + /* ... */
>> + };
>> + };
>> + };
>> +
>> + /* Board DTS - alphabetical order */
>> +
>> + &clk {
>> + /* ... */
>> + };
>> +
>> + &dma {
>> + /* ... */
>> + };
>> +
>> + /* Board DTS - alternative order, keep as DTSI */
>> +
>> + &dma {
>> + /* ... */
>> + };
>> +
>> + &clk {
>> + /* ... */
>> + };
>
> IMO that alternative order is hard to review: you need to have multiple
> files open. It will also make validation hard, as you can only validate
> the end result, not individual files.
Rob commented on this - tools (will) solve the issue. :)
>
> Anyway, this is already quite usable so
> Reviewed-by: Geert Uytterhoeven <geert+renesas@...der.be>
>
> Gr{oetje,eeting}s,
>
> Geert
>
Best regards,
Krzysztof
Powered by blists - more mailing lists