fsl,gianfar-mdio.yaml 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
  2. %YAML 1.2
  3. ---
  4. $id: http://devicetree.org/schemas/net/fsl,gianfar-mdio.yaml#
  5. $schema: http://devicetree.org/meta-schemas/core.yaml#
  6. title: Freescale Gianfar (TSEC) MDIO Device
  7. description:
  8. This binding describes the MDIO is a bus to which the PHY devices are
  9. connected. For each device that exists on this bus, a child node should be
  10. created.
  11. Some TSECs are associated with an internal Ten-Bit Interface (TBI) PHY. This
  12. PHY is accessed through the local MDIO bus. These buses are defined similarly
  13. to the mdio buses, except they are compatible with "fsl,gianfar-tbi". The TBI
  14. PHYs underneath them are similar to normal PHYs, but the reg property is
  15. considered instructive, rather than descriptive. The reg property should be
  16. chosen so it doesn't interfere with other PHYs on the bus.
  17. maintainers:
  18. - J. Neuschäfer <j.ne@posteo.net>
  19. # This is needed to distinguish gianfar.yaml and gianfar-mdio.yaml, because
  20. # both use compatible = "gianfar" (with different device_type values)
  21. select:
  22. oneOf:
  23. - properties:
  24. compatible:
  25. contains:
  26. const: gianfar
  27. device_type:
  28. const: mdio
  29. required:
  30. - device_type
  31. - properties:
  32. compatible:
  33. contains:
  34. enum:
  35. - fsl,gianfar-tbi
  36. - fsl,gianfar-mdio
  37. - fsl,etsec2-tbi
  38. - fsl,etsec2-mdio
  39. - fsl,ucc-mdio
  40. - ucc_geth_phy
  41. required:
  42. - compatible
  43. properties:
  44. compatible:
  45. enum:
  46. - fsl,gianfar-tbi
  47. - fsl,gianfar-mdio
  48. - fsl,etsec2-tbi
  49. - fsl,etsec2-mdio
  50. - fsl,ucc-mdio
  51. - gianfar
  52. - ucc_geth_phy
  53. reg:
  54. minItems: 1
  55. items:
  56. - description:
  57. Offset and length of the register set for the device
  58. - description:
  59. Optionally, the offset and length of the TBIPA register (TBI PHY
  60. address register). If TBIPA register is not specified, the driver
  61. will attempt to infer it from the register set specified (your
  62. mileage may vary).
  63. device_type:
  64. const: mdio
  65. required:
  66. - reg
  67. - "#address-cells"
  68. - "#size-cells"
  69. allOf:
  70. - $ref: mdio.yaml#
  71. - if:
  72. properties:
  73. compatible:
  74. contains:
  75. const: ucc_geth_phy
  76. then:
  77. required:
  78. - device_type
  79. unevaluatedProperties: false
  80. examples:
  81. - |
  82. soc {
  83. #address-cells = <1>;
  84. #size-cells = <1>;
  85. mdio@24520 {
  86. reg = <0x24520 0x20>;
  87. compatible = "fsl,gianfar-mdio";
  88. #address-cells = <1>;
  89. #size-cells = <0>;
  90. ethernet-phy@0 {
  91. reg = <0>;
  92. };
  93. };
  94. };