devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] dt-bindings: usb: Document the Microchip USB2514 hub
@ 2024-04-05 12:01 Fabio Estevam
  2024-04-05 15:45 ` Krzysztof Kozlowski
  0 siblings, 1 reply; 2+ messages in thread
From: Fabio Estevam @ 2024-04-05 12:01 UTC (permalink / raw)
  To: gregkh; +Cc: robh, krzk+dt, conor+dt, linux-usb, devicetree, Fabio Estevam

From: Fabio Estevam <festevam@denx.de>

Document the Microchip USB2412, USB2417, and USB2514 USB hubs.

The existing usb251xb.yaml describes Microchip USB251x hubs that are
connected under I2C bus. Here, the hub is under the USB bus and use
the on-board-hub interface instead.

Signed-off-by: Fabio Estevam <festevam@denx.de>
---
Changes since v1:
- Improve commit log to explain why usb251xb.yaml cannot be reused.
- Keep the compatible entries sorted.
- Pass maxItems to clocks.
- Use unevaluatedProperties: false after passing $ref: usb-hcd.yaml#.
- Drop dr_mode = "host".
- Fix example dts indentation.
- Improve the example by adding a USB Ethernet device connected
to the hub. Such example can be found at:
arch/arm64/boot/dts/freescale/imx8mm-kontron-bl-osm-s.dts
arch/arm/boot/dts/broadcom/bcm283x-rpi-lan7515.dtsi

 .../bindings/usb/microchip,usb2514.yaml       | 63 +++++++++++++++++++
 1 file changed, 63 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/usb/microchip,usb2514.yaml

diff --git a/Documentation/devicetree/bindings/usb/microchip,usb2514.yaml b/Documentation/devicetree/bindings/usb/microchip,usb2514.yaml
new file mode 100644
index 000000000000..783c27591e56
--- /dev/null
+++ b/Documentation/devicetree/bindings/usb/microchip,usb2514.yaml
@@ -0,0 +1,63 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/usb/microchip,usb2514.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Microchip USB2514 Hub Controller
+
+maintainers:
+  - Fabio Estevam <festevam@gmail.com>
+
+allOf:
+  - $ref: usb-hcd.yaml#
+
+properties:
+  compatible:
+    enum:
+      - usb424,2412
+      - usb424,2417
+      - usb424,2514
+
+  reg: true
+
+  reset-gpios:
+    description: GPIO connected to the RESET_N pin.
+
+  vdd-supply:
+    description: 3.3V power supply.
+
+  clocks:
+    description: External 24MHz clock connected to the CLKIN pin.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+unevaluatedProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/clock/imx6qdl-clock.h>
+    #include <dt-bindings/gpio/gpio.h>
+
+    usb {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        usb-hub@1 {
+            compatible = "usb424,2514";
+            reg = <1>;
+            clocks = <&clks IMX6QDL_CLK_CKO>;
+            reset-gpios = <&gpio7 12 GPIO_ACTIVE_LOW>;
+            vdd-supply = <&reg_3v3_hub>;
+            #address-cells = <1>;
+            #size-cells = <0>;
+
+            ethernet@1 {
+                compatible = "usbb95,772b";
+                reg = <1>;
+            };
+        };
+    };
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v2] dt-bindings: usb: Document the Microchip USB2514 hub
  2024-04-05 12:01 [PATCH v2] dt-bindings: usb: Document the Microchip USB2514 hub Fabio Estevam
@ 2024-04-05 15:45 ` Krzysztof Kozlowski
  0 siblings, 0 replies; 2+ messages in thread
From: Krzysztof Kozlowski @ 2024-04-05 15:45 UTC (permalink / raw)
  To: Fabio Estevam, gregkh
  Cc: robh, krzk+dt, conor+dt, linux-usb, devicetree, Fabio Estevam

On 05/04/2024 14:01, Fabio Estevam wrote:
> From: Fabio Estevam <festevam@denx.de>
> 
> Document the Microchip USB2412, USB2417, and USB2514 USB hubs.
> 
> The existing usb251xb.yaml describes Microchip USB251x hubs that are
> connected under I2C bus. Here, the hub is under the USB bus and use
> the on-board-hub interface instead.
> 
> Signed-off-by: Fabio Estevam <festevam@denx.de>


Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-04-05 15:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-05 12:01 [PATCH v2] dt-bindings: usb: Document the Microchip USB2514 hub Fabio Estevam
2024-04-05 15:45 ` Krzysztof Kozlowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).