Re: [PATCH 22/38] arm: dts: qcom: ipq8064: Break long property array data
From: Krzysztof Kozlowski
Date: Fri Oct 16 2026 - 11:07:08 EST
On 16/10/2026 16:15, Waqar Hameed wrote:
> Yeah, as I responded in patch 19, this is hard and needs some
> discussions. Having the braces on separate lines like this is one way to
> do it, and in fact that's how `black` for Python does it. `rustfmt` also
> chooses this but first tries to fit it on one line with a newline after
> the assignment:
>
> interrupts =
> <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_HIGH)>;
>
> If it still doesn't fit 100 chars (like here), it then formats long
> arrays as
>
> interrupts = <
> GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_HIGH)
> >;
>
> This still doesn't fit 100 chars. Maybe we could then wrap the
> individual items like:
>
> interrupts = <
> GIC_PPI 10
> (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_HIGH)
> >;
>
> I think that's a reasonable algorithm to have in dtfmt for wrapping
> arrays, or?
The code should be:
interrupts = <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_HIGH)
it fits within reasonable limits. Why would you wrap it?
Best regards,
Krzysztof