diff mbox series

[02/14] dt-bindings: display: panel: allow ilitek, ili9341 in isolation

Message ID 20220618123035.563070-3-mail@conchuod.ie (mailing list archive)
State New, archived
Headers show
Series Canaan devicetree fixes | expand

Commit Message

Conor Dooley June 18, 2022, 12:30 p.m. UTC
From: Conor Dooley <conor.dooley@microchip.com>

The dt-binding for the ilitek,ili9341 does not allow it to be used as a
compatible in isolation. This generates a warning for the Canaan kd233
devicetree:
arch/riscv/boot/dts/canaan/canaan_kd233.dtb: panel@0: compatible:0: 'ilitek,ili9341' is not one of ['st,sf-tc240t-9370-t']
        From schema: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
arch/riscv/boot/dts/canaan/canaan_kd233.dtb: panel@0: compatible: ['ilitek,ili9341'] is too short
        From schema: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
Allow ilitek,ili9341 to be selected in isolation.

Signed-off-by: Conor Dooley <conor.dooley@microchip.com>
---
 .../bindings/display/panel/ilitek,ili9341.yaml     | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

Comments

Rob Herring (Arm) June 27, 2022, 11:17 p.m. UTC | #1
On Sat, Jun 18, 2022 at 01:30:24PM +0100, Conor Dooley wrote:
> From: Conor Dooley <conor.dooley@microchip.com>
> 
> The dt-binding for the ilitek,ili9341 does not allow it to be used as a
> compatible in isolation. This generates a warning for the Canaan kd233
> devicetree:
> arch/riscv/boot/dts/canaan/canaan_kd233.dtb: panel@0: compatible:0: 'ilitek,ili9341' is not one of ['st,sf-tc240t-9370-t']
>         From schema: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
> arch/riscv/boot/dts/canaan/canaan_kd233.dtb: panel@0: compatible: ['ilitek,ili9341'] is too short
>         From schema: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
> Allow ilitek,ili9341 to be selected in isolation.

Just because you get a warning doesn't mean it is right. ili9341 is a 
panel driver IC, not a complete panel. It needs a more specific 
compatible.

Rob
Conor Dooley June 28, 2022, 6:26 a.m. UTC | #2
On 28/06/2022 00:17, Rob Herring wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
> 
> On Sat, Jun 18, 2022 at 01:30:24PM +0100, Conor Dooley wrote:
>> From: Conor Dooley <conor.dooley@microchip.com>
>>
>> The dt-binding for the ilitek,ili9341 does not allow it to be used as a
>> compatible in isolation. This generates a warning for the Canaan kd233
>> devicetree:
>> arch/riscv/boot/dts/canaan/canaan_kd233.dtb: panel@0: compatible:0: 'ilitek,ili9341' is not one of ['st,sf-tc240t-9370-t']
>>          From schema: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
>> arch/riscv/boot/dts/canaan/canaan_kd233.dtb: panel@0: compatible: ['ilitek,ili9341'] is too short
>>          From schema: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
>> Allow ilitek,ili9341 to be selected in isolation.
> 
> Just because you get a warning doesn't mean it is right. ili9341 is a
> panel driver IC, not a complete panel. It needs a more specific
> compatible.

pff, makes sense. I'll conjure one up.
Thanks,
Conor.
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml b/Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
index 94ca92878434..c402bedaa37a 100644
--- a/Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
+++ b/Documentation/devicetree/bindings/display/panel/ilitek,ili9341.yaml
@@ -19,12 +19,14 @@  allOf:
 
 properties:
   compatible:
-    items:
-      - enum:
-          # ili9341 240*320 Color on stm32f429-disco board
-          - st,sf-tc240t-9370-t
-          - adafruit,yx240qv29
-      - const: ilitek,ili9341
+    oneOf:
+      - items:
+          - const: ilitek,ili9341
+      - items:
+          - enum:
+              - st,sf-tc240t-9370-t
+              - adafruit,yx240qv29
+          - const: ilitek,ili9341
 
   reg: true