phy: bcm63xx-usbh: Add BCM63xx USBH driver
Subsystems (2)
v2 cover phy: bcm63xx-usbh: Add BCM63xx USBH driver
Add BCM63xx USBH PHY driver for BMIPS.
v2: introduce changes suggested by Florian:
- phy-cells changed to 1.
- Drop OF dependency (use device_get_match_data).
- Drop __initconst from variant tables.
- Use devm_clk_get_optional.
Álvaro Fernández Rojas (2):
dt-bindings: phy: add bcm63xx-usbh bindings
phy: bcm63xx-usbh: Add BCM63xx USBH driver
.../bindings/phy/brcm,bcm63xx-usbh-phy.yaml | 72 +++ drivers/phy/broadcom/Kconfig | 9 + drivers/phy/broadcom/Makefile | 1 + drivers/phy/broadcom/phy-bcm63xx-usbh.c | 433 ++++++++++++++++++ 4 files changed, 515 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.yaml create mode 100644 drivers/phy/broadcom/phy-bcm63xx-usbh.c
Signature · 1 line
2.27.0
PATCH v2 1/2 dt-bindings: phy: add bcm63xx-usbh bindings
Document BCM63xx USBH PHY bindings.
---
v2: phy-cells changed to 1.
.../bindings/phy/brcm,bcm63xx-usbh-phy.yaml | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.yaml
Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.yaml new file +72 -0
@@ -0,0 +1,72 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: "http://devicetree.org/schemas/phy/brcm,bcm63xx-usbh-phy.yaml#" +$schema: "http://devicetree.org/meta-schemas/core.yaml#" + +title: BCM63xx USBH PHY + +maintainers: + - Álvaro Fernández Rojas <[email protected]> + +properties: + compatible: + enum: + - brcm,bcm6318-usbh-phy + - brcm,bcm6328-usbh-phy + - brcm,bcm6358-usbh-phy + - brcm,bcm6362-usbh-phy + - brcm,bcm6368-usbh-phy + - brcm,bcm63268-usbh-phy + + reg: + maxItems: 1 + + clocks: + maxItems: 2 + + clock-names: + items: + - const: usbh + - const: usb_ref + + resets: + maxItems: 1 + + "#phy-cells": + const: 1 + +required: + - compatible + - reg + - clocks + - clock-names + - resets + - "#phy-cells" + +if: + properties: + compatible: + enum: + - brcm,bcm6318-usbh-phy + - brcm,bcm6328-usbh-phy + - brcm,bcm6362-usbh-phy + - brcm,bcm63268-usbh-phy + +then: + properties: + power-domains: + maxItems: 1 + required: + - power-domains + +examples: + - | + usbh: usb-phy@10001700 { + compatible = "brcm,bcm6368-usbh-phy"; + reg = <0x10001700 0x38>; + clocks = <&periph_clk BCM6368_CLK_USBH>; + clock-names = "usbh"; + resets = <&periph_rst BCM6368_RST_USBH>; + #phy-cells = <1>; + };
Signature · 1 line
2.27.0
Rob Herring
maintainerRe: [PATCH v2 1/2] dt-bindings: phy: add bcm63xx-usbh bindings
Quoted 10 lines · Álvaro Fernández Rojas
Document BCM63xx USBH PHY bindings.
Signed-off-by Álvaro Fernández Rojas <[email protected]>---
v2: phy-cells changed to 1..../bindings/phy/brcm,bcm63xx-usbh-phy.yaml | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.yaml
My bot found errors running 'make dt_binding_check' on your patch:
Error: Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.example.dts:22.33-34 syntax error
FATAL ERROR: Unable to parse input treescripts/Makefile.lib:315: recipe for target 'Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.example.dt.yaml' failed make[1]: *** [Documentation/devicetree/bindings/phy/brcm,bcm63xx-usbh-phy.example.dt.yaml] Error 1
make[1]: *** Waiting for unfinished jobs....
Makefile:1347: recipe for target 'dt_binding_check' failed
make: *** [dt_binding_check] Error 2
See https://patchwork.ozlabs.org/patch/1310646
If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure dt-schema is up to date:
pip3 install git+https://github.com/devicetree-org/dt-schema.git@master --upgrade
Please check and re-submit.
PATCH v2 2/2 phy: bcm63xx-usbh: Add BCM63xx USBH driver
In reply to Álvaro Fernández RojasAdd BCM63xx USBH PHY driver for BMIPS.
---
v2: introduce changes suggested by Florian:
- Drop OF dependency (use device_get_match_data).
- Drop __initconst from variant tables.
- Use devm_clk_get_optional.
drivers/phy/broadcom/Kconfig | 9 + drivers/phy/broadcom/Makefile | 1 + drivers/phy/broadcom/phy-bcm63xx-usbh.c | 433 ++++++++++++++++++++++++ 3 files changed, 443 insertions(+) create mode 100644 drivers/phy/broadcom/phy-bcm63xx-usbh.c
drivers/phy/broadcom/Kconfig +9 -0
@@ -2,6 +2,15 @@ # # Phy drivers for Broadcom platforms # +config PHY_BCM63XX_USBH + tristate "BCM63xx USBH PHY driver" + depends on BMIPS_GENERIC || COMPILE_TEST + select GENERIC_PHY + default BMIPS_GENERIC + help + Enable this to support the BCM63xx USBH PHY driver. + If unsure, say N. + config PHY_CYGNUS_PCIE tristate "Broadcom Cygnus PCIe PHY driver" depends on OF && (ARCH_BCM_CYGNUS || COMPILE_TEST)
drivers/phy/broadcom/Makefile +1 -0
@@ -1,4 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 +obj-$(CONFIG_PHY_BCM63XX_USBH) += phy-bcm63xx-usbh.o obj-$(CONFIG_PHY_CYGNUS_PCIE) += phy-bcm-cygnus-pcie.o obj-$(CONFIG_BCM_KONA_USB2_PHY) += phy-bcm-kona-usb2.o obj-$(CONFIG_PHY_BCM_NS_USB2) += phy-bcm-ns-usb2.o
drivers/phy/broadcom/phy-bcm63xx-usbh.c new file +433 -0
433 lines not on this page · raw message
Signature · 1 line
2.27.0