nvidia,tegra124-car.txt 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. NVIDIA Tegra124 and Tegra132 Clock And Reset Controller
  2. This binding uses the common clock binding:
  3. Documentation/devicetree/bindings/clock/clock-bindings.txt
  4. The CAR (Clock And Reset) Controller on Tegra is the HW module responsible
  5. for muxing and gating Tegra's clocks, and setting their rates.
  6. Required properties :
  7. - compatible : Should be "nvidia,tegra124-car" or "nvidia,tegra132-car"
  8. - reg : Should contain CAR registers location and length
  9. - clocks : Should contain phandle and clock specifiers for two clocks:
  10. the 32 KHz "32k_in", and the board-specific oscillator "osc".
  11. - #clock-cells : Should be 1.
  12. In clock consumers, this cell represents the clock ID exposed by the
  13. CAR. The assignments may be found in the header files
  14. <dt-bindings/clock/tegra124-car-common.h> (which covers IDs common
  15. to Tegra124 and Tegra132) and <dt-bindings/clock/tegra124-car.h>
  16. (for Tegra124-specific clocks).
  17. - #reset-cells : Should be 1.
  18. In clock consumers, this cell represents the bit number in the CAR's
  19. array of CLK_RST_CONTROLLER_RST_DEVICES_* registers.
  20. - nvidia,external-memory-controller : phandle of the EMC driver.
  21. The node should contain a "emc-timings" subnode for each supported RAM type (see
  22. field RAM_CODE in register PMC_STRAPPING_OPT_A).
  23. Required properties for "emc-timings" nodes :
  24. - nvidia,ram-code : Should contain the value of RAM_CODE this timing set
  25. is used for.
  26. Each "emc-timings" node should contain a "timing" subnode for every supported
  27. EMC clock rate.
  28. Required properties for "timing" nodes :
  29. - clock-frequency : Should contain the memory clock rate to which this timing
  30. relates.
  31. - nvidia,parent-clock-frequency : Should contain the rate at which the current
  32. parent of the EMC clock should be running at this timing.
  33. - clocks : Must contain an entry for each entry in clock-names.
  34. See ../clocks/clock-bindings.txt for details.
  35. - clock-names : Must include the following entries:
  36. - emc-parent : the clock that should be the parent of the EMC clock at this
  37. timing.
  38. Example SoC include file:
  39. / {
  40. tegra_car: clock@60006000 {
  41. compatible = "nvidia,tegra124-car";
  42. reg = <0x60006000 0x1000>;
  43. #clock-cells = <1>;
  44. #reset-cells = <1>;
  45. nvidia,external-memory-controller = <&emc>;
  46. };
  47. usb@c5004000 {
  48. clocks = <&tegra_car TEGRA124_CLK_USB2>;
  49. };
  50. };
  51. Example board file:
  52. / {
  53. clocks {
  54. compatible = "simple-bus";
  55. #address-cells = <1>;
  56. #size-cells = <0>;
  57. osc: clock@0 {
  58. compatible = "fixed-clock";
  59. reg = <0>;
  60. #clock-cells = <0>;
  61. clock-frequency = <112400000>;
  62. };
  63. clk_32k: clock@1 {
  64. compatible = "fixed-clock";
  65. reg = <1>;
  66. #clock-cells = <0>;
  67. clock-frequency = <32768>;
  68. };
  69. };
  70. &tegra_car {
  71. clocks = <&clk_32k> <&osc>;
  72. };
  73. clock@60006000 {
  74. emc-timings-3 {
  75. nvidia,ram-code = <3>;
  76. timing-12750000 {
  77. clock-frequency = <12750000>;
  78. nvidia,parent-clock-frequency = <408000000>;
  79. clocks = <&tegra_car TEGRA124_CLK_PLL_P>;
  80. clock-names = "emc-parent";
  81. };
  82. timing-20400000 {
  83. clock-frequency = <20400000>;
  84. nvidia,parent-clock-frequency = <408000000>;
  85. clocks = <&tegra_car TEGRA124_CLK_PLL_P>;
  86. clock-names = "emc-parent";
  87. };
  88. };
  89. };
  90. };