[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <bbbd30c4-75ca-4d04-ac07-1b458ee543b7@linaro.org>
Date: Sat, 18 Nov 2023 00:53:42 +0100
From: Konrad Dybcio <konrad.dybcio@...aro.org>
To: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Conor Dooley <conor+dt@...nel.org>, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org
Cc: AngeloGioacchino Del Regno
<angelogioacchino.delregno@...labora.com>,
Arnd Bergmann <arnd@...db.de>,
Bjorn Andersson <andersson@...nel.org>,
Geert Uytterhoeven <geert+renesas@...der.be>,
Heiko Stuebner <heiko@...ech.de>,
Matthias Brugger <matthias.bgg@...il.com>,
Michal Simek <michal.simek@....com>,
Neil Armstrong <neil.armstrong@...aro.org>,
Nishanth Menon <nm@...com>, Olof Johansson <olof@...om.net>
Subject: Re: [PATCH] docs: dt-bindings: add DTS Coding Style document
On 16.11.2023 19:12, Krzysztof Kozlowski wrote:
> Document preferred coding style for Devicetree sources (DTS and DTSI),
> to bring consistency among all (sub)architectures and ease in reviews.
>
> Cc: AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>
> Cc: Arnd Bergmann <arnd@...db.de>
> Cc: Bjorn Andersson <andersson@...nel.org>
> Cc: Geert Uytterhoeven <geert+renesas@...der.be>
> Cc: Heiko Stuebner <heiko@...ech.de>
> Cc: Konrad Dybcio <konrad.dybcio@...aro.org>
> Cc: Matthias Brugger <matthias.bgg@...il.com>
> Cc: Michal Simek <michal.simek@....com>
> Cc: Neil Armstrong <neil.armstrong@...aro.org>
> Cc: Nishanth Menon <nm@...com>
> Cc: Olof Johansson <olof@...om.net>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
>
> ---
[...]
> +Order of Nodes
> +--------------
> +
> +1. Nodes within any bus, thus using unit addresses for children, shall be
> + ordered incrementally by unit address.
> +
> +2. Nodes without unit addresses should be ordered alpha-numerically.
I largely agree with all this given our fight for some level of
tidyness across linux-msm, but there's one specific case where I think
it would make sense to break this ordering, and that's GPIO states:
&pinctrl {
xyz-active-state {
pins ="gpio0";
...
};
abc-active-state {
pins ="gpio1";
...
};
qwe-active-state {
pins ="gpio2";
...
};
};
looks so much more readable to me than
&pinctrl {
abc-active-state {
pins ="gpio1";
...
};
qwe-active-state {
pins ="gpio2";
...
};
xyz-active-state {
pins ="gpio0";
...
};
};
Konrad
Powered by blists - more mailing lists