Re: [RFC PATCH 1/2] dt-bindings: phy: convert phy-rockchip-inno-usb2 bindings to yaml

From: Johan Jonker
Date: Thu Mar 19 2020 - 08:12:20 EST


Hi,

A test with the command below gives this error:

DTC Documentation/devicetree/bindings/phy/
phy-rockchip-inno-usb2.example.dt.yaml
CHECK Documentation/devicetree/bindings/phy/
phy-rockchip-inno-usb2.example.dt.yaml
Documentation/devicetree/bindings/phy/
phy-rockchip-inno-usb2.example.dt.yaml: usb2-phy@e450:
'#phy-cells' is a required property

'phy-provider.yaml' uses regex pattern:

"^(|usb-|usb2-|usb3-|pci-|pcie-|sata-)phy(@[0-9a-f,]+)*$"

in combination with nodename 'usb2-phy' gives a full match.
'#phy-cells' is only for subnodes I think.

Question:
Should we:
1: rename all 'usb2-phy' nodes in dtsi, then please advise what name
should be used.

Or:
2: add '#phy-cells' to 'usb2-phy' nodes? Please advice.

make -k ARCH=arm dt_binding_check

> +examples:
> + - |
> + #include <dt-bindings/clock/rk3399-cru.h>
> + #include <dt-bindings/interrupt-controller/arm-gic.h>
> + #include <dt-bindings/interrupt-controller/irq.h>

> + u2phy0: usb2-phy@e450 {

Regex gives a full match.

> + compatible = "rockchip,rk3399-usb2phy";
> + reg = <0xe450 0x10>;
> + clocks = <&cru SCLK_USB2PHY0_REF>;
> + clock-names = "phyclk";
> + clock-output-names = "clk_usbphy0_480m";
> + #clock-cells = <0>;
> +
> + u2phy0_host: host-port {
> + #phy-cells = <0>;
> + interrupts = <GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH 0>;
> + interrupt-names = "linestate";
> + };
> +
> + u2phy0_otg: otg-port {
> + #phy-cells = <0>;
> + interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_HIGH 0>,
> + <GIC_SPI 104 IRQ_TYPE_LEVEL_HIGH 0>,
> + <GIC_SPI 106 IRQ_TYPE_LEVEL_HIGH 0>;
> + interrupt-names = "otg-bvalid", "otg-id", "linestate";
> + };
> + };