kontron,sl28cpld.yaml 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
  2. %YAML 1.2
  3. ---
  4. $id: http://devicetree.org/schemas/mfd/kontron,sl28cpld.yaml#
  5. $schema: http://devicetree.org/meta-schemas/core.yaml#
  6. title: Kontron's sl28cpld board management controller
  7. maintainers:
  8. - Michael Walle <michael@walle.cc>
  9. description: |
  10. The board management controller may contain different IP blocks like
  11. watchdog, fan monitoring, PWM controller, interrupt controller and a
  12. GPIO controller.
  13. properties:
  14. compatible:
  15. const: kontron,sl28cpld
  16. reg:
  17. description:
  18. I2C device address.
  19. maxItems: 1
  20. "#address-cells":
  21. const: 1
  22. "#size-cells":
  23. const: 0
  24. "#interrupt-cells":
  25. const: 2
  26. interrupts:
  27. maxItems: 1
  28. interrupt-controller: true
  29. patternProperties:
  30. "^gpio(@[0-9a-f]+)?$":
  31. $ref: /schemas/gpio/kontron,sl28cpld-gpio.yaml
  32. "^hwmon(@[0-9a-f]+)?$":
  33. $ref: /schemas/hwmon/kontron,sl28cpld-hwmon.yaml
  34. "^interrupt-controller(@[0-9a-f]+)?$":
  35. $ref: /schemas/interrupt-controller/kontron,sl28cpld-intc.yaml
  36. "^pwm(@[0-9a-f]+)?$":
  37. $ref: /schemas/pwm/kontron,sl28cpld-pwm.yaml
  38. "^watchdog(@[0-9a-f]+)?$":
  39. $ref: /schemas/watchdog/kontron,sl28cpld-wdt.yaml
  40. required:
  41. - "#address-cells"
  42. - "#size-cells"
  43. - compatible
  44. - reg
  45. additionalProperties: false
  46. examples:
  47. - |
  48. #include <dt-bindings/interrupt-controller/irq.h>
  49. i2c {
  50. #address-cells = <1>;
  51. #size-cells = <0>;
  52. sl28cpld@4a {
  53. compatible = "kontron,sl28cpld";
  54. reg = <0x4a>;
  55. #address-cells = <1>;
  56. #size-cells = <0>;
  57. watchdog@4 {
  58. compatible = "kontron,sl28cpld-wdt";
  59. reg = <0x4>;
  60. kontron,assert-wdt-timeout-pin;
  61. };
  62. hwmon@b {
  63. compatible = "kontron,sl28cpld-fan";
  64. reg = <0xb>;
  65. };
  66. pwm@c {
  67. compatible = "kontron,sl28cpld-pwm";
  68. reg = <0xc>;
  69. #pwm-cells = <2>;
  70. };
  71. pwm@e {
  72. compatible = "kontron,sl28cpld-pwm";
  73. reg = <0xe>;
  74. #pwm-cells = <2>;
  75. };
  76. gpio@10 {
  77. compatible = "kontron,sl28cpld-gpio";
  78. reg = <0x10>;
  79. interrupts-extended = <&gpio2 6
  80. IRQ_TYPE_EDGE_FALLING>;
  81. gpio-controller;
  82. #gpio-cells = <2>;
  83. gpio-line-names = "a", "b", "c";
  84. interrupt-controller;
  85. #interrupt-cells = <2>;
  86. };
  87. gpio@15 {
  88. compatible = "kontron,sl28cpld-gpio";
  89. reg = <0x15>;
  90. interrupts-extended = <&gpio2 6
  91. IRQ_TYPE_EDGE_FALLING>;
  92. gpio-controller;
  93. #gpio-cells = <2>;
  94. interrupt-controller;
  95. #interrupt-cells = <2>;
  96. };
  97. gpio@1a {
  98. compatible = "kontron,sl28cpld-gpo";
  99. reg = <0x1a>;
  100. gpio-controller;
  101. #gpio-cells = <2>;
  102. };
  103. gpio@1b {
  104. compatible = "kontron,sl28cpld-gpi";
  105. reg = <0x1b>;
  106. gpio-controller;
  107. #gpio-cells = <2>;
  108. };
  109. interrupt-controller@1c {
  110. compatible = "kontron,sl28cpld-intc";
  111. reg = <0x1c>;
  112. interrupts-extended = <&gpio2 6
  113. IRQ_TYPE_EDGE_FALLING>;
  114. interrupt-controller;
  115. #interrupt-cells = <2>;
  116. };
  117. };
  118. };