xlnx,xps-timer.yaml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. # SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause
  2. %YAML 1.2
  3. ---
  4. $id: http://devicetree.org/schemas/timer/xlnx,xps-timer.yaml#
  5. $schema: http://devicetree.org/meta-schemas/core.yaml#
  6. title: Xilinx LogiCORE IP AXI Timer
  7. maintainers:
  8. - Sean Anderson <sean.anderson@seco.com>
  9. properties:
  10. compatible:
  11. contains:
  12. const: xlnx,xps-timer-1.00.a
  13. clocks:
  14. maxItems: 1
  15. clock-names:
  16. const: s_axi_aclk
  17. interrupts:
  18. maxItems: 1
  19. reg:
  20. maxItems: 1
  21. '#pwm-cells': true
  22. xlnx,count-width:
  23. $ref: /schemas/types.yaml#/definitions/uint32
  24. enum: [8, 16, 32]
  25. default: 32
  26. description:
  27. The width of the counter(s), in bits.
  28. xlnx,one-timer-only:
  29. $ref: /schemas/types.yaml#/definitions/uint32
  30. enum: [ 0, 1 ]
  31. description:
  32. Whether only one timer is present in this block.
  33. required:
  34. - compatible
  35. - reg
  36. - xlnx,one-timer-only
  37. allOf:
  38. - if:
  39. required:
  40. - '#pwm-cells'
  41. then:
  42. allOf:
  43. - required:
  44. - clocks
  45. - properties:
  46. xlnx,one-timer-only:
  47. const: 0
  48. else:
  49. required:
  50. - interrupts
  51. - if:
  52. required:
  53. - clocks
  54. then:
  55. required:
  56. - clock-names
  57. additionalProperties: false
  58. examples:
  59. - |
  60. timer@800e0000 {
  61. clock-names = "s_axi_aclk";
  62. clocks = <&zynqmp_clk 71>;
  63. compatible = "xlnx,xps-timer-1.00.a";
  64. reg = <0x800e0000 0x10000>;
  65. interrupts = <0 39 2>;
  66. xlnx,count-width = <16>;
  67. xlnx,one-timer-only = <0x0>;
  68. };
  69. timer@800f0000 {
  70. #pwm-cells = <0>;
  71. clock-names = "s_axi_aclk";
  72. clocks = <&zynqmp_clk 71>;
  73. compatible = "xlnx,xps-timer-1.00.a";
  74. reg = <0x800e0000 0x10000>;
  75. xlnx,count-width = <32>;
  76. xlnx,one-timer-only = <0x0>;
  77. };