116 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2# Copyright (c) 2020 MediaTek3%YAML 1.24---5$id: http://devicetree.org/schemas/usb/mediatek,musb.yaml#6$schema: http://devicetree.org/meta-schemas/core.yaml#7 8title: MediaTek MUSB DRD/OTG Controller9 10maintainers:11 - Min Guo <min.guo@mediatek.com>12 13properties:14 $nodename:15 pattern: '^usb@[0-9a-f]+$'16 17 compatible:18 items:19 - enum:20 - mediatek,mt8516-musb21 - mediatek,mt2701-musb22 - mediatek,mt7623-musb23 - const: mediatek,mtk-musb24 25 reg:26 maxItems: 127 28 interrupts:29 maxItems: 130 31 interrupt-names:32 items:33 - const: mc34 35 clocks:36 items:37 - description: The main/core clock38 - description: The system bus clock39 - description: The 48Mhz clock40 41 clock-names:42 items:43 - const: main44 - const: mcu45 - const: univpll46 47 phys:48 maxItems: 149 50 usb-role-switch:51 $ref: /schemas/types.yaml#/definitions/flag52 description: Support role switch. See usb/generic.txt53 type: boolean54 55 dr_mode:56 enum:57 - host58 - otg59 - peripheral60 61 power-domains:62 description: A phandle to USB power domain node to control USB's MTCMOS63 maxItems: 164 65 connector:66 $ref: /schemas/connector/usb-connector.yaml#67 description: Connector for dual role switch68 type: object69 70dependencies:71 usb-role-switch: [ connector ]72 connector: [ usb-role-switch ]73 74required:75 - compatible76 - reg77 - interrupts78 - interrupt-names79 - phys80 - clocks81 - clock-names82 83additionalProperties: false84 85examples:86 - |87 #include <dt-bindings/clock/mt2701-clk.h>88 #include <dt-bindings/gpio/gpio.h>89 #include <dt-bindings/interrupt-controller/arm-gic.h>90 #include <dt-bindings/interrupt-controller/irq.h>91 #include <dt-bindings/phy/phy.h>92 #include <dt-bindings/power/mt2701-power.h>93 94 usb@11200000 {95 compatible = "mediatek,mt2701-musb", "mediatek,mtk-musb";96 reg = <0x11200000 0x1000>;97 interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_LOW>;98 interrupt-names = "mc";99 phys = <&u2port2 PHY_TYPE_USB2>;100 dr_mode = "otg";101 clocks = <&pericfg CLK_PERI_USB0>,102 <&pericfg CLK_PERI_USB0_MCU>,103 <&pericfg CLK_PERI_USB_SLV>;104 clock-names = "main","mcu","univpll";105 power-domains = <&scpsys MT2701_POWER_DOMAIN_IFR_MSC>;106 usb-role-switch;107 108 connector {109 compatible = "gpio-usb-b-connector", "usb-b-connector";110 type = "micro";111 id-gpios = <&pio 44 GPIO_ACTIVE_HIGH>;112 vbus-supply = <&usb_vbus>;113 };114 };115...116