lkml.org 
[lkml]   [2022]   [Apr]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 1/1] dt-bindings: timer: mediatek: Convert binding to YAML
From
On 22/04/2022 15:13, Allen-KH Cheng wrote:

You should also fix the DTSes to match the new schema.

> +$id: http://devicetree.org/schemas/timer/mediatek,mtk-timer.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: MediaTek SoCs timers bindings
> +
> +description:
> + MediaTek SoCs have two different timers on different platforms,
> + - GPT (General Purpose Timer)
> + - SYST (System Timer)
> +
> +maintainers:
> + - Fengquan Chen <fengquan.chen@mediatek.com>
> + - Allen-KH Cheng <allen-kh.cheng@mediatek.com>
> +
> +properties:
> + $nodename:
> + pattern: '^timer@[a-f0-9]+$'
> +
> + compatible:
> + oneOf:
> + - const: mediatek,mt6577-timer
> + - const: mediatek,mt6765-timer

These two entries should be an enum.

> + - items:
> + - enum:
> + - mediatek,mt2701-timer
> + - mediatek,mt6580-timer
> + - mediatek,mt6582-timer
> + - mediatek,mt6589-timer
> + - mediatek,mt7623-timer
> + - mediatek,mt8127-timer
> + - mediatek,mt8135-timer
> + - mediatek,mt8173-timer
> + - mediatek,mt8516-timer
> + - const: mediatek,mt6577-timer
> + - items:
> + - enum:
> + - mediatek,mt7629-timer
> + - mediatek,mt8183-timer
> + - mediatek,mt8186-timer
> + - mediatek,mt8192-timer
> + - mediatek,mt8195-timer
> + - const: mediatek,mt6765-timer
> +
> + reg:
> + maxItems: 1
> +
> + interrupts:
> + maxItems: 1
> +
> + clocks:
> + minItems: 1
> + maxItems: 2
> +
> + clock-names:
> + minItems: 1
> + items:
> + - const: clk13m
> + - const: bus

When is the bus clock optional?

> +
> +required:
> + - compatible
> + - reg

clocks are required in the old bindings

> + - interrupts
> +
> +additionalProperties: false
> +
> +examples:
> + - |
> + timer@10008000 {
> + compatible = "mediatek,mt6577-timer";
> + reg = <0xd4014000 0x100>;

reg does not match unit address.


> + interrupts = <13>;
> + clocks = <&coreclk 2>;
> + };
> +
> +...


Best regards,
Krzysztof

\
 
 \ /
  Last update: 2022-04-24 16:51    [W:0.049 / U:0.244 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site