[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <7ea9fb0f-f7bc-49bf-965f-631514abf9fe@gmail.com>
Date: Mon, 3 Mar 2025 22:27:17 -0300
From: Leonardo Felipe Takao Hirata <leo.fthirata@...il.com>
To: Vladimir Zapolskiy <vz@...ia.com>, tglx@...utronix.de, robh@...nel.org,
krzk+dt@...nel.org, conor+dt@...nel.org
Cc: linux-kernel@...r.kernel.org, devicetree@...r.kernel.org,
skhan@...uxfoundation.org, linux-kernel-mentees@...ts.linuxfoundation.org
Subject: Re: [PATCH v3] dt-bindings: interrupt-controller: Convert
nxp,lpc3220-mic.txt to yaml format
Hi Vladimir.
On 03/03/2025 1:27 AM, Vladimir Zapolskiy wrote:
> Hello Leonardo.
>
> On 2/28/25 05:39, Leonardo Felipe Takao Hirata wrote:
>> Convert NXP LPC3220-MIC to DT schema.
>>
>> Signed-off-by: Leonardo Felipe Takao Hirata <leo.fthirata@...il.com>
>> ---
>> Changes in v3:
>> - Add interrupts property description
>> - Fix interrupts items descriptions
>> - Remove else condition
>> ---
>
> <snip>
>
>> diff --git a/Documentation/devicetree/bindings/interrupt-controller/
>> nxp,lpc3220-mic.yaml b/Documentation/devicetree/bindings/interrupt-controller/
>> nxp,lpc3220-mic.yaml
>> new file mode 100644
>> index 000000000000..59e8814a15b7
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/interrupt-controller/nxp,lpc3220-mic.yaml
>> @@ -0,0 +1,69 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/interrupt-controller/nxp,lpc3220-mic.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: NXP LPC32xx MIC, SIC1 and SIC2 Interrupt Controllers
>> +
>> +maintainers:
>> + - Vladimir Zapolskiy <vz@...ia.com>
>> +
>> +properties:
>> + compatible:
>> + enum:
>> + - nxp,lpc3220-mic
>> + - nxp,lpc3220-sic
>> +
>> + reg:
>> + maxItems: 1
>> +
>> + interrupt-controller: true
>> +
>> + '#interrupt-cells':
>> + const: 2
>> +
>> + interrupts:
>
> Please put here
>
> minItems: 2
> maxItems: 2
>
I didn't add them in this patch because example-schema.yaml states that minItems
and maxItems are already implied. The following code is taken from the
example-schema.yaml.
items:
- description: core registers
- description: aux registers
# minItems/maxItems equal to 2 is implied
Besides, adding minItems and maxItems triggers the respective warnings:
- "minItems" is only needed if less than the "items" list length
- "maxItems" is not needed with an "items" list
>> + items:
>> + - description: Regular interrupt request
>> + - description: Fast interrupt request
>> + description: IRQ and FIQ outputs of SIC1/SIC2 to the MIC.
>
> Having both two descriptions under 'items:' and another description is
> excessive, please leave only one of two.
>
>> +
>> +required:
>> + - compatible
>> + - reg
>> + - interrupt-controller
>> + - '#interrupt-cells'
>> +
>> +allOf:
>> + - if:
>> + properties:
>> + compatible:
>> + contains:
>> + const: nxp,lpc3220-sic
>> + then:
>> + required:
>> + - interrupts
>> +
>> +additionalProperties: false
>> +
>> +examples:
>> + - |
>> + #include <dt-bindings/interrupt-controller/irq.h>
>> +
>> + mic: interrupt-controller@...08000 {
>> + compatible = "nxp,lpc3220-mic";
>> + reg = <0x40008000 0x4000>;
>> + interrupt-controller;
>> + #interrupt-cells = <2>;
>> + };
>> +
>> + sic1: interrupt-controller@...0c000 {
>
> Here sic1 label is not used, please remove.
>
>> + compatible = "nxp,lpc3220-sic";
>> + reg = <0x4000c000 0x4000>;
>> + interrupt-controller;
>> + #interrupt-cells = <2>;
>> + interrupt-parent = <&mic>;
>> + interrupts = <0 IRQ_TYPE_LEVEL_LOW>,
>> + <30 IRQ_TYPE_LEVEL_LOW>;
>> + };
>
> After the fixes please feel free to add the tag:
>
> Reviewed-by: Vladimir Zapolskiy <vz@...ia.com>
>
> --
> Best wishes,
> Vladimir
Rob,
Do you want these changes on top of what was applied or a complete patch?
Best regards,
Leonardo Hirata
Powered by blists - more mailing lists