Commit 2d6064e9 authored by Raphael Gallais-Pou's avatar Raphael Gallais-Pou Committed by Vinod Koul
Browse files

dt-bindings: phy: st: convert phy-stih407-usb to DT schema



Convert the st,stih407-usb2-phy binding to DT schema format.

Signed-off-by: default avatarRaphael Gallais-Pou <rgallaispou@gmail.com>
Reviewed-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230823132224.111326-1-rgallaispou@gmail.com


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 2be22aae
Loading
Loading
Loading
Loading
+0 −24
Original line number Diff line number Diff line
ST STiH407 USB PHY controller

This file documents the dt bindings for the usb picoPHY driver which is the PHY for both USB2 and USB3
host controllers (when controlling usb2/1.1 devices) available on STiH407 SoC family from STMicroelectronics.

Required properties:
- compatible		: should be "st,stih407-usb2-phy"
- st,syscfg		: phandle of sysconfig bank plus integer array containing phyparam and phyctrl register offsets
- resets		: list of phandle and reset specifier pairs. There should be two entries, one
			  for the whole phy and one for the port
- reset-names		: list of reset signal names. Should be "global" and "port"
See: Documentation/devicetree/bindings/reset/st,stih407-powerdown.yaml
See: Documentation/devicetree/bindings/reset/reset.txt

Example:

usb2_picophy0: usbpicophy@f8 {
	compatible	= "st,stih407-usb2-phy";
	#phy-cells	= <0>;
	st,syscfg	= <&syscfg_core 0x100 0xf4>;
	resets		= <&softreset STIH407_PICOPHY_SOFTRESET>,
			  <&picophyreset STIH407_PICOPHY0_RESET>;
	reset-names	= "global", "port";
};
+63 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/phy/st,stih407-usb2-phy.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: STMicroelectronics STiH407 USB PHY controller

maintainers:
  - Patrice Chotard <patrice.chotard@foss.st.com>

description:
  The USB picoPHY device is the PHY for both USB2 and USB3 host controllers
  (when controlling usb2/1.1 devices) available on STiH407 SoC family from
  STMicroelectronics.

properties:
  compatible:
    const: st,stih407-usb2-phy

  st,syscfg:
    description: Phandle to the syscfg bank
    $ref: /schemas/types.yaml#/definitions/phandle-array
    items:
      - items:
          - description: phandle to syscfg
          - description: phyparam register offset
          - description: phyctrl register offset

  resets:
    items:
      - description: Phandle and reset specifier pair for the whole phy.
      - description: Phandle and reset specifier pair for the port.

  reset-names:
    items:
      - const: global
      - const: port

  "#phy-cells":
    const: 0

required:
  - compatible
  - st,syscfg
  - resets
  - reset-names
  - "#phy-cells"

additionalProperties: false

examples:
  - |
    #include <dt-bindings/reset/stih407-resets.h>
    usb-phy {
        compatible = "st,stih407-usb2-phy";
        #phy-cells = <0>;
        st,syscfg = <&syscfg_core 0x100 0xf4>;
        resets = <&softreset STIH407_PICOPHY_SOFTRESET>,
                 <&picophyreset STIH407_PICOPHY0_RESET>;
        reset-names = "global", "port";
    };
...