Message ID | 20240923151417.1665431-4-michal.vokac@ysoft.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | Add support for new IMX8MP based board | expand |
On 24-09-23, Michal Vokáč wrote: > From: Petr Benes <petr.benes@ysoft.com> > > Diodes Incorporated PI5USB30213A Type-C Controller supports host, > device, and dual-role mode based on voltage levels detected on CC > pin. Supports dual differential channel, 2:1 USB 3.0 Mux/Demux, > USB Type-C specification 1.1. > > Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> > Signed-off-by: Petr Benes <petr.benes@ysoft.com> > Signed-off-by: Michal Vokáč <michal.vokac@ysoft.com> > --- > v3: > - Collected R-b tag from Krzysztof. > v2: > - Moved maintainers before description: block. > - Used full paths for references. > - Removed unneeded items form connector property. > - Fixed example. > > .../bindings/usb/diodes,pi5usb30213a.yaml | 88 +++++++++++++++++++ I suppose the driver is part of an other patchset? Regards, Marco > 1 file changed, 88 insertions(+) > create mode 100644 Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml > > diff --git a/Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml b/Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml > new file mode 100644 > index 000000000000..054a5409bd15 > --- /dev/null > +++ b/Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml > @@ -0,0 +1,88 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/usb/diodes,pi5usb30213a.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: PI5USB30213A Type-C port controller > + > +maintainers: > + - Petr Benes <petr.benes@ysoft.com> > + > +description: > + Diodes Incorporated PI5USB30213A Type-C Controller supports host, > + device, and dual-role mode based on voltage levels detected on CC > + pin. Dual differential channel, 2:1 USB 3.0 Mux/Demux, USB Type-C > + specification 1.1 compliant. > + > +properties: > + compatible: > + enum: > + - diodes,pi5usb30213a > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + connector: > + type: object > + $ref: /schemas/connector/usb-connector.yaml# > + unevaluatedProperties: false > + > +required: > + - compatible > + - reg > + - interrupts > + - connector > + > +additionalProperties: false > + > +examples: > + - | > + #include <dt-bindings/interrupt-controller/irq.h> > + > + i2c { > + #address-cells = <1>; > + #size-cells = <0>; > + > + typec@d { > + compatible = "diodes,pi5usb30213a"; > + reg = <0xd>; > + pinctrl-names = "default"; > + pinctrl-0 = <&pinctrl_typec>; > + interrupts-extended = <&gpio1 5 IRQ_TYPE_LEVEL_LOW>; > + > + connector { > + compatible = "usb-c-connector"; > + label = "USB-C"; > + vbus-supply = <®_typec>; > + power-role = "source"; > + data-role = "dual"; > + typec-power-opmode = "default"; > + pd-disable; > + > + ports { > + #address-cells = <1>; > + #size-cells = <0>; > + > + port@0 { > + reg = <0>; > + > + usb_con_hs: endpoint { > + remote-endpoint = <&typec_hs>; > + }; > + }; > + > + port@1 { > + reg = <1>; > + > + usb_con_ss: endpoint { > + remote-endpoint = <&typec_ss>; > + }; > + }; > + }; > + }; > + }; > + }; > -- > 2.43.0 > > >
On Tue, Sep 24, 2024 at 09:24:36AM +0200, Marco Felsch wrote: > On 24-09-23, Michal Vokáč wrote: > > From: Petr Benes <petr.benes@ysoft.com> > > > > Diodes Incorporated PI5USB30213A Type-C Controller supports host, > > device, and dual-role mode based on voltage levels detected on CC > > pin. Supports dual differential channel, 2:1 USB 3.0 Mux/Demux, > > USB Type-C specification 1.1. > > > > Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> > > Signed-off-by: Petr Benes <petr.benes@ysoft.com> > > Signed-off-by: Michal Vokáč <michal.vokac@ysoft.com> > > --- > > v3: > > - Collected R-b tag from Krzysztof. > > v2: > > - Moved maintainers before description: block. > > - Used full paths for references. > > - Removed unneeded items form connector property. > > - Fixed example. > > > > .../bindings/usb/diodes,pi5usb30213a.yaml | 88 +++++++++++++++++++ > > I suppose the driver is part of an other patchset? Hm, indeed, where is the driver? This patch should not be here. Best regards, Krzysztof
On 24/09/2024 10:21, Krzysztof Kozlowski wrote: > On Tue, Sep 24, 2024 at 09:24:36AM +0200, Marco Felsch wrote: >> On 24-09-23, Michal Vokáč wrote: >>> From: Petr Benes <petr.benes@ysoft.com> >>> >>> Diodes Incorporated PI5USB30213A Type-C Controller supports host, >>> device, and dual-role mode based on voltage levels detected on CC >>> pin. Supports dual differential channel, 2:1 USB 3.0 Mux/Demux, >>> USB Type-C specification 1.1. >>> >>> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> >>> Signed-off-by: Petr Benes <petr.benes@ysoft.com> >>> Signed-off-by: Michal Vokáč <michal.vokac@ysoft.com> >>> --- >>> v3: >>> - Collected R-b tag from Krzysztof. >>> v2: >>> - Moved maintainers before description: block. >>> - Used full paths for references. >>> - Removed unneeded items form connector property. >>> - Fixed example. >>> >>> .../bindings/usb/diodes,pi5usb30213a.yaml | 88 +++++++++++++++++++ >> >> I suppose the driver is part of an other patchset? > > Hm, indeed, where is the driver? > > This patch should not be here. I found remark in the cover letter. It's fine. Best regards, Krzysztof
On 24-09-24, Krzysztof Kozlowski wrote: > On 24/09/2024 10:21, Krzysztof Kozlowski wrote: > > On Tue, Sep 24, 2024 at 09:24:36AM +0200, Marco Felsch wrote: > >> On 24-09-23, Michal Vokáč wrote: > >>> From: Petr Benes <petr.benes@ysoft.com> > >>> > >>> Diodes Incorporated PI5USB30213A Type-C Controller supports host, > >>> device, and dual-role mode based on voltage levels detected on CC > >>> pin. Supports dual differential channel, 2:1 USB 3.0 Mux/Demux, > >>> USB Type-C specification 1.1. > >>> > >>> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> > >>> Signed-off-by: Petr Benes <petr.benes@ysoft.com> > >>> Signed-off-by: Michal Vokáč <michal.vokac@ysoft.com> > >>> --- > >>> v3: > >>> - Collected R-b tag from Krzysztof. > >>> v2: > >>> - Moved maintainers before description: block. > >>> - Used full paths for references. > >>> - Removed unneeded items form connector property. > >>> - Fixed example. > >>> > >>> .../bindings/usb/diodes,pi5usb30213a.yaml | 88 +++++++++++++++++++ > >> > >> I suppose the driver is part of an other patchset? > > > > Hm, indeed, where is the driver? > > > > This patch should not be here. > > I found remark in the cover letter. It's fine. Thanks for the hint, should have read the cover letter more carefully :/ Regards, Marco
diff --git a/Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml b/Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml new file mode 100644 index 000000000000..054a5409bd15 --- /dev/null +++ b/Documentation/devicetree/bindings/usb/diodes,pi5usb30213a.yaml @@ -0,0 +1,88 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/usb/diodes,pi5usb30213a.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: PI5USB30213A Type-C port controller + +maintainers: + - Petr Benes <petr.benes@ysoft.com> + +description: + Diodes Incorporated PI5USB30213A Type-C Controller supports host, + device, and dual-role mode based on voltage levels detected on CC + pin. Dual differential channel, 2:1 USB 3.0 Mux/Demux, USB Type-C + specification 1.1 compliant. + +properties: + compatible: + enum: + - diodes,pi5usb30213a + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + connector: + type: object + $ref: /schemas/connector/usb-connector.yaml# + unevaluatedProperties: false + +required: + - compatible + - reg + - interrupts + - connector + +additionalProperties: false + +examples: + - | + #include <dt-bindings/interrupt-controller/irq.h> + + i2c { + #address-cells = <1>; + #size-cells = <0>; + + typec@d { + compatible = "diodes,pi5usb30213a"; + reg = <0xd>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_typec>; + interrupts-extended = <&gpio1 5 IRQ_TYPE_LEVEL_LOW>; + + connector { + compatible = "usb-c-connector"; + label = "USB-C"; + vbus-supply = <®_typec>; + power-role = "source"; + data-role = "dual"; + typec-power-opmode = "default"; + pd-disable; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + usb_con_hs: endpoint { + remote-endpoint = <&typec_hs>; + }; + }; + + port@1 { + reg = <1>; + + usb_con_ss: endpoint { + remote-endpoint = <&typec_ss>; + }; + }; + }; + }; + }; + };