> -----Original Message----- > From: Somisetty, Pranavi <pranavi.somisetty@xxxxxxx> > Sent: Monday, July 24, 2023 6:47 PM > To: Rob Herring <robh@xxxxxxxxxx> > Cc: davem@xxxxxxxxxxxxx; edumazet@xxxxxxxxxx; kuba@xxxxxxxxxx; > krzysztof.kozlowski+dt@xxxxxxxxxx; conor+dt@xxxxxxxxxx; Simek, Michal > <michal.simek@xxxxxxx>; Katakam, Harini <harini.katakam@xxxxxxx>; > git (AMD-Xilinx) <git@xxxxxxx>; Pandey, Radhey Shyam > <radhey.shyam.pandey@xxxxxxx>; netdev@xxxxxxxxxxxxxxx; linux- > kernel@xxxxxxxxxxxxxxx; devicetree@xxxxxxxxxxxxxxx; linux-arm- > kernel@xxxxxxxxxxxxxxxxxxx > Subject: RE: [PATCH v2] dt-bindings: net: xilinx_gmii2rgmii: Convert to json > schema > > > > > -----Original Message----- > > From: Rob Herring <robh@xxxxxxxxxx> > > Sent: Wednesday, July 19, 2023 11:52 PM > > To: Somisetty, Pranavi <pranavi.somisetty@xxxxxxx> > > Cc: davem@xxxxxxxxxxxxx; edumazet@xxxxxxxxxx; kuba@xxxxxxxxxx; > > krzysztof.kozlowski+dt@xxxxxxxxxx; conor+dt@xxxxxxxxxx; Simek, Michal > > <michal.simek@xxxxxxx>; Katakam, Harini <harini.katakam@xxxxxxx>; > git > > (AMD-Xilinx) <git@xxxxxxx>; Pandey, Radhey Shyam > > <radhey.shyam.pandey@xxxxxxx>; netdev@xxxxxxxxxxxxxxx; linux- > > kernel@xxxxxxxxxxxxxxx; devicetree@xxxxxxxxxxxxxxx; linux-arm- > > kernel@xxxxxxxxxxxxxxxxxxx > > Subject: Re: [PATCH v2] dt-bindings: net: xilinx_gmii2rgmii: Convert > > to json schema > > <snip> > > > + > > > + phy-handle: > > > + $ref: ethernet-controller.yaml#/properties/phy-handle > > > > Don't reference individual properties like this. Instead add a $ref at > > the top level to just "ethernet-controller.yaml#". Since this is the > > only property you want from there, put a 'phy-handle: true' here and > > use additionalProperties instead of unevaluatedProperties below. > > > > Adding a top level $ref to ethernet-controller, implies, DT for gmii2rgmii, > follows the schema in ethernet-controller.yaml. This is incorrect since > gmii2rgmii IP isn't an ethernet controller. > I'm not sure how to reference ethernet-controller.yaml from this schema. > Would it be okay to add a description to the phy-handle property instead of > referencing the description in ethernet-controller.yaml? > > Regards > Pranavi Just FYI, when I add a $ref pointing to ethernet-controller.yaml, this is the error I'm seeing: Documentation/devicetree/bindings/net/xlnx,gmii-to-rgmii.example.dtb: gmiitorgmii@8: $nodename:0: 'gmiitorgmii@8' does not match '^ethernet(@.*)?$' Regards, Pranavi > > > +required: > > > + - compatible > > > + - reg > > > + - phy-handle > > > + > > > +unevaluatedProperties: false > > > + > > > +examples: > > > + - | > > > + mdio { > > > + #address-cells = <1>; > > > + #size-cells = <0>; > > > + phy: ethernet-phy@0 { > > > + reg = <0>; > > > + }; > > > + gmiitorgmii@8 { > > > + compatible = "xlnx,gmii-to-rgmii-1.0"; > > > + reg = <8>; > > > + phy-handle = <&phy>; > > > + }; > > > + }; > > > -- > > > 2.36.1 > > >