at91-natte.dtsi 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244
  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * at91-natte.dts - Device Tree include file for the Natte board
  4. *
  5. * Copyright (C) 2017 Axentia Technologies AB
  6. *
  7. * Author: Peter Rosin <[email protected]>
  8. */
  9. / {
  10. mux: mux-controller {
  11. compatible = "gpio-mux";
  12. #mux-control-cells = <0>;
  13. mux-gpios = <&ioexp 0 GPIO_ACTIVE_HIGH>,
  14. <&ioexp 1 GPIO_ACTIVE_HIGH>,
  15. <&ioexp 2 GPIO_ACTIVE_HIGH>;
  16. };
  17. batntc-mux {
  18. compatible = "io-channel-mux";
  19. io-channels = <&adc 5>;
  20. io-channel-names = "parent";
  21. mux-controls = <&mux>;
  22. channels =
  23. "batntc0", "batntc1", "batntc2", "batntc3",
  24. "batntc4", "batntc5", "batntc6", "batntc7";
  25. };
  26. batv-mux {
  27. compatible = "io-channel-mux";
  28. io-channels = <&adc 6>;
  29. io-channel-names = "parent";
  30. mux-controls = <&mux>;
  31. channels =
  32. "batv0", "batv1", "batv2", "batv3",
  33. "batv4", "batv5", "batv6", "batv7";
  34. };
  35. iout-mux {
  36. compatible = "io-channel-mux";
  37. io-channels = <&adc 7>;
  38. io-channel-names = "parent";
  39. mux-controls = <&mux>;
  40. channels =
  41. "iout0", "iout1", "iout2", "iout3",
  42. "iout4", "iout5", "iout6", "iout7";
  43. };
  44. i2c-mux {
  45. compatible = "i2c-mux";
  46. mux-locked;
  47. i2c-parent = <&i2c0>;
  48. mux-controls = <&mux>;
  49. #address-cells = <1>;
  50. #size-cells = <0>;
  51. i2c@0 {
  52. reg = <0>;
  53. #address-cells = <1>;
  54. #size-cells = <0>;
  55. charger@9 {
  56. compatible = "ti,bq24735";
  57. reg = <0x9>;
  58. ti,charge-current = <2000>;
  59. ti,charge-voltage = <16800>;
  60. poll-interval = <20000>;
  61. };
  62. };
  63. i2c@1 {
  64. reg = <1>;
  65. #address-cells = <1>;
  66. #size-cells = <0>;
  67. charger@9 {
  68. compatible = "ti,bq24735";
  69. reg = <0x9>;
  70. ti,charge-current = <2000>;
  71. ti,charge-voltage = <16800>;
  72. poll-interval = <20000>;
  73. };
  74. };
  75. i2c@2 {
  76. reg = <2>;
  77. #address-cells = <1>;
  78. #size-cells = <0>;
  79. charger@9 {
  80. compatible = "ti,bq24735";
  81. reg = <0x9>;
  82. ti,charge-current = <2000>;
  83. ti,charge-voltage = <16800>;
  84. poll-interval = <20000>;
  85. };
  86. };
  87. i2c@3 {
  88. reg = <3>;
  89. #address-cells = <1>;
  90. #size-cells = <0>;
  91. charger@9 {
  92. compatible = "ti,bq24735";
  93. reg = <0x9>;
  94. ti,charge-current = <2000>;
  95. ti,charge-voltage = <16800>;
  96. poll-interval = <20000>;
  97. };
  98. };
  99. i2c@4 {
  100. reg = <4>;
  101. #address-cells = <1>;
  102. #size-cells = <0>;
  103. charger@9 {
  104. compatible = "ti,bq24735";
  105. reg = <0x9>;
  106. ti,charge-current = <2000>;
  107. ti,charge-voltage = <16800>;
  108. poll-interval = <20000>;
  109. };
  110. };
  111. i2c@5 {
  112. reg = <5>;
  113. #address-cells = <1>;
  114. #size-cells = <0>;
  115. charger@9 {
  116. compatible = "ti,bq24735";
  117. reg = <0x9>;
  118. ti,charge-current = <2000>;
  119. ti,charge-voltage = <16800>;
  120. poll-interval = <20000>;
  121. };
  122. };
  123. i2c@6 {
  124. reg = <6>;
  125. #address-cells = <1>;
  126. #size-cells = <0>;
  127. charger@9 {
  128. compatible = "ti,bq24735";
  129. reg = <0x9>;
  130. ti,charge-current = <2000>;
  131. ti,charge-voltage = <16800>;
  132. poll-interval = <20000>;
  133. };
  134. };
  135. i2c@7 {
  136. reg = <7>;
  137. #address-cells = <1>;
  138. #size-cells = <0>;
  139. charger@9 {
  140. compatible = "ti,bq24735";
  141. reg = <0x9>;
  142. ti,charge-current = <2000>;
  143. ti,charge-voltage = <16800>;
  144. poll-interval = <20000>;
  145. };
  146. };
  147. };
  148. };
  149. &i2c0 {
  150. status = "okay";
  151. ioexp: ioexp@20 {
  152. #gpio-cells = <2>;
  153. compatible = "semtech,sx1502q";
  154. reg = <0x20>;
  155. gpio-controller;
  156. ngpios = <8>;
  157. pinctrl-names = "default";
  158. pinctrl-0 = <&gpio3_cfg_pins>;
  159. gpio3_cfg_pins: gpio3_cfg {
  160. pins = "gpio3";
  161. bias-pull-up;
  162. };
  163. };
  164. adc: adc@48 {
  165. compatible = "ti,ads1015";
  166. reg = <0x48>;
  167. #io-channel-cells = <1>;
  168. #address-cells = <1>;
  169. #size-cells = <0>;
  170. channel@4 {
  171. reg = <4>;
  172. ti,gain = <2>;
  173. ti,datarate = <4>;
  174. };
  175. channel@5 {
  176. reg = <5>;
  177. ti,gain = <2>;
  178. ti,datarate = <4>;
  179. };
  180. channel@6 {
  181. reg = <6>;
  182. ti,gain = <1>;
  183. ti,datarate = <4>;
  184. };
  185. channel@7 {
  186. reg = <7>;
  187. ti,gain = <3>;
  188. ti,datarate = <4>;
  189. };
  190. };
  191. };