qcom-ipq8064-c2600.dts 8.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479
  1. #include "qcom-ipq8064-v2.0.dtsi"
  2. #include <dt-bindings/input/input.h>
  3. / {
  4. model = "TP-Link Archer C2600";
  5. compatible = "tplink,c2600", "qcom,ipq8064";
  6. memory@0 {
  7. reg = <0x42000000 0x1e000000>;
  8. device_type = "memory";
  9. };
  10. reserved-memory {
  11. #address-cells = <1>;
  12. #size-cells = <1>;
  13. ranges;
  14. rsvd@41200000 {
  15. reg = <0x41200000 0x300000>;
  16. no-map;
  17. };
  18. };
  19. aliases {
  20. serial0 = &gsbi4_serial;
  21. mdio-gpio0 = &mdio0;
  22. led-boot = &power;
  23. led-failsafe = &general;
  24. led-running = &power;
  25. led-upgrade = &general;
  26. label-mac-device = &gmac2;
  27. };
  28. chosen {
  29. stdout-path = "serial0:115200n8";
  30. };
  31. soc {
  32. pinmux@800000 {
  33. button_pins: button_pins {
  34. mux {
  35. pins = "gpio16", "gpio54", "gpio65";
  36. function = "gpio";
  37. drive-strength = <2>;
  38. bias-pull-up;
  39. };
  40. };
  41. i2c4_pins: i2c4_pinmux {
  42. mux {
  43. pins = "gpio12", "gpio13";
  44. function = "gsbi4";
  45. drive-strength = <12>;
  46. bias-disable;
  47. };
  48. };
  49. led_pins: led_pins {
  50. mux {
  51. pins = "gpio6", "gpio7", "gpio8", "gpio9", "gpio26", "gpio33",
  52. "gpio53", "gpio66";
  53. function = "gpio";
  54. drive-strength = <2>;
  55. bias-pull-up;
  56. };
  57. };
  58. spi_pins: spi_pins {
  59. mux {
  60. pins = "gpio18", "gpio19", "gpio21";
  61. function = "gsbi5";
  62. bias-pull-down;
  63. };
  64. data {
  65. pins = "gpio18", "gpio19";
  66. drive-strength = <10>;
  67. };
  68. cs {
  69. pins = "gpio20";
  70. function = "gpio";
  71. drive-strength = <10>;
  72. bias-pull-up;
  73. };
  74. clk {
  75. pins = "gpio21";
  76. drive-strength = <12>;
  77. };
  78. };
  79. mdio0_pins: mdio0_pins {
  80. mux {
  81. pins = "gpio0", "gpio1";
  82. function = "gpio";
  83. drive-strength = <8>;
  84. bias-disable;
  85. };
  86. };
  87. rgmii2_pins: rgmii2_pins {
  88. mux {
  89. pins = "gpio27", "gpio28", "gpio29", "gpio30", "gpio31", "gpio32",
  90. "gpio51", "gpio52", "gpio59", "gpio60", "gpio61", "gpio62" ;
  91. function = "rgmii2";
  92. drive-strength = <8>;
  93. bias-disable;
  94. };
  95. };
  96. usb0_pwr_en_pin: usb0_pwr_en_pin {
  97. mux {
  98. pins = "gpio25";
  99. function = "gpio";
  100. drive-strength = <10>;
  101. bias-pull-up;
  102. output-high;
  103. };
  104. };
  105. usb1_pwr_en_pin: usb1_pwr_en_pin {
  106. mux {
  107. pins = "gpio23";
  108. function = "gpio";
  109. drive-strength = <10>;
  110. bias-pull-up;
  111. output-high;
  112. };
  113. };
  114. };
  115. gsbi@16300000 {
  116. qcom,mode = <GSBI_PROT_I2C_UART>;
  117. status = "okay";
  118. serial@16340000 {
  119. status = "okay";
  120. };
  121. /*
  122. * The i2c device on gsbi4 should not be enabled.
  123. * On ipq806x designs gsbi4 i2c is meant for exclusive
  124. * RPM usage. Turning this on in kernel manifests as
  125. * i2c failure for the RPM.
  126. */
  127. };
  128. gsbi5: gsbi@1a200000 {
  129. qcom,mode = <GSBI_PROT_SPI>;
  130. status = "okay";
  131. spi5: spi@1a280000 {
  132. status = "okay";
  133. pinctrl-0 = <&spi_pins>;
  134. pinctrl-names = "default";
  135. cs-gpios = <&qcom_pinmux 20 GPIO_ACTIVE_HIGH>;
  136. flash: m25p80@0 {
  137. compatible = "jedec,spi-nor";
  138. #address-cells = <1>;
  139. #size-cells = <1>;
  140. spi-max-frequency = <50000000>;
  141. reg = <0>;
  142. SBL1@0 {
  143. label = "SBL1";
  144. reg = <0x0 0x20000>;
  145. read-only;
  146. };
  147. MIBIB@20000 {
  148. label = "MIBIB";
  149. reg = <0x20000 0x20000>;
  150. read-only;
  151. };
  152. SBL2@40000 {
  153. label = "SBL2";
  154. reg = <0x40000 0x20000>;
  155. read-only;
  156. };
  157. SBL3@60000 {
  158. label = "SBL3";
  159. reg = <0x60000 0x30000>;
  160. read-only;
  161. };
  162. DDRCONFIG@90000 {
  163. label = "DDRCONFIG";
  164. reg = <0x90000 0x10000>;
  165. read-only;
  166. };
  167. SSD@a0000 {
  168. label = "SSD";
  169. reg = <0xa0000 0x10000>;
  170. read-only;
  171. };
  172. TZ@b0000 {
  173. label = "TZ";
  174. reg = <0xb0000 0x30000>;
  175. read-only;
  176. };
  177. RPM@e0000 {
  178. label = "RPM";
  179. reg = <0xe0000 0x20000>;
  180. read-only;
  181. };
  182. fs-uboot@100000 {
  183. label = "fs-uboot";
  184. reg = <0x100000 0x70000>;
  185. read-only;
  186. };
  187. uboot-env@170000 {
  188. label = "uboot-env";
  189. reg = <0x170000 0x40000>;
  190. read-only;
  191. };
  192. radio@1b0000 {
  193. label = "radio";
  194. reg = <0x1b0000 0x40000>;
  195. read-only;
  196. };
  197. os-image@1f0000 {
  198. label = "os-image";
  199. reg = <0x1f0000 0x400000>;
  200. };
  201. rootfs@5f0000 {
  202. label = "rootfs";
  203. reg = <0x5f0000 0x1900000>;
  204. };
  205. defaultmac: default-mac@1ef0000 {
  206. label = "default-mac";
  207. reg = <0x1ef0000 0x00200>;
  208. read-only;
  209. };
  210. pin@1ef0200 {
  211. label = "pin";
  212. reg = <0x1ef0200 0x00200>;
  213. read-only;
  214. };
  215. product-info@1ef0400 {
  216. label = "product-info";
  217. reg = <0x1ef0400 0x0fc00>;
  218. read-only;
  219. };
  220. partition-table@1f00000 {
  221. label = "partition-table";
  222. reg = <0x1f00000 0x10000>;
  223. read-only;
  224. };
  225. soft-version@1f10000 {
  226. label = "soft-version";
  227. reg = <0x1f10000 0x10000>;
  228. read-only;
  229. };
  230. support-list@1f20000 {
  231. label = "support-list";
  232. reg = <0x1f20000 0x10000>;
  233. read-only;
  234. };
  235. profile@1f30000 {
  236. label = "profile";
  237. reg = <0x1f30000 0x10000>;
  238. read-only;
  239. };
  240. default-config@1f40000 {
  241. label = "default-config";
  242. reg = <0x1f40000 0x10000>;
  243. read-only;
  244. };
  245. user-config@1f50000 {
  246. label = "user-config";
  247. reg = <0x1f50000 0x40000>;
  248. read-only;
  249. };
  250. qos-db@1f90000 {
  251. label = "qos-db";
  252. reg = <0x1f90000 0x40000>;
  253. read-only;
  254. };
  255. usb-config@1fd0000 {
  256. label = "usb-config";
  257. reg = <0x1fd0000 0x10000>;
  258. read-only;
  259. };
  260. log@1fe0000 {
  261. label = "log";
  262. reg = <0x1fe0000 0x20000>;
  263. read-only;
  264. };
  265. };
  266. };
  267. };
  268. usb3_0: usb3@110f8800 {
  269. status = "okay";
  270. pinctrl-0 = <&usb0_pwr_en_pin>;
  271. pinctrl-names = "default";
  272. };
  273. usb3_1: usb3@100f8800 {
  274. status = "okay";
  275. pinctrl-0 = <&usb1_pwr_en_pin>;
  276. pinctrl-names = "default";
  277. };
  278. pcie0: pci@1b500000 {
  279. status = "okay";
  280. };
  281. pcie1: pci@1b700000 {
  282. status = "okay";
  283. force_gen1 = <1>;
  284. };
  285. mdio0: mdio {
  286. compatible = "virtual,mdio-gpio";
  287. #address-cells = <1>;
  288. #size-cells = <0>;
  289. gpios = <&qcom_pinmux 1 GPIO_ACTIVE_HIGH>,
  290. <&qcom_pinmux 0 GPIO_ACTIVE_HIGH>;
  291. pinctrl-0 = <&mdio0_pins>;
  292. pinctrl-names = "default";
  293. phy0: ethernet-phy@0 {
  294. reg = <0>;
  295. qca,ar8327-initvals = <
  296. 0x00004 0x7600000 /* PAD0_MODE */
  297. 0x00008 0x1000000 /* PAD5_MODE */
  298. 0x0000c 0x80 /* PAD6_MODE */
  299. 0x000e4 0x6a545 /* MAC_POWER_SEL */
  300. 0x000e0 0xc74164de /* SGMII_CTRL */
  301. 0x0007c 0x4e /* PORT0_STATUS */
  302. 0x00094 0x4e /* PORT6_STATUS */
  303. >;
  304. };
  305. phy4: ethernet-phy@4 {
  306. reg = <4>;
  307. };
  308. };
  309. gmac1: ethernet@37200000 {
  310. status = "okay";
  311. phy-mode = "rgmii";
  312. qcom,id = <1>;
  313. pinctrl-0 = <&rgmii2_pins>;
  314. pinctrl-names = "default";
  315. mtd-mac-address = <&defaultmac 0x8>;
  316. mtd-mac-address-increment = <1>;
  317. fixed-link {
  318. speed = <1000>;
  319. full-duplex;
  320. };
  321. };
  322. gmac2: ethernet@37400000 {
  323. status = "okay";
  324. phy-mode = "sgmii";
  325. qcom,id = <2>;
  326. mtd-mac-address = <&defaultmac 0x8>;
  327. fixed-link {
  328. speed = <1000>;
  329. full-duplex;
  330. };
  331. };
  332. };
  333. keys {
  334. compatible = "gpio-keys";
  335. pinctrl-0 = <&button_pins>;
  336. pinctrl-names = "default";
  337. wifi {
  338. label = "wifi";
  339. gpios = <&qcom_pinmux 49 GPIO_ACTIVE_LOW>;
  340. linux,code = <KEY_RFKILL>;
  341. };
  342. reset {
  343. label = "reset";
  344. gpios = <&qcom_pinmux 64 GPIO_ACTIVE_LOW>;
  345. linux,code = <KEY_RESTART>;
  346. };
  347. wps {
  348. label = "wps";
  349. gpios = <&qcom_pinmux 65 GPIO_ACTIVE_LOW>;
  350. linux,code = <KEY_WPS_BUTTON>;
  351. };
  352. ledswitch {
  353. label = "ledswitch";
  354. gpios = <&qcom_pinmux 16 GPIO_ACTIVE_LOW>;
  355. linux,code = <KEY_LIGHTS_TOGGLE>;
  356. };
  357. };
  358. leds {
  359. compatible = "gpio-leds";
  360. pinctrl-0 = <&led_pins>;
  361. pinctrl-names = "default";
  362. lan {
  363. label = "white:lan";
  364. gpios = <&qcom_pinmux 6 GPIO_ACTIVE_HIGH>;
  365. };
  366. usb4 {
  367. label = "white:usb_4";
  368. gpios = <&qcom_pinmux 7 GPIO_ACTIVE_HIGH>;
  369. };
  370. usb2 {
  371. label = "white:usb_2";
  372. gpios = <&qcom_pinmux 8 GPIO_ACTIVE_HIGH>;
  373. };
  374. wps {
  375. label = "white:wps";
  376. gpios = <&qcom_pinmux 9 GPIO_ACTIVE_HIGH>;
  377. };
  378. wan_amber {
  379. label = "amber:wan";
  380. gpios = <&qcom_pinmux 26 GPIO_ACTIVE_LOW>;
  381. };
  382. wan_white {
  383. label = "white:wan";
  384. gpios = <&qcom_pinmux 33 GPIO_ACTIVE_LOW>;
  385. };
  386. power: power {
  387. label = "white:power";
  388. gpios = <&qcom_pinmux 53 GPIO_ACTIVE_HIGH>;
  389. default-state = "keep";
  390. };
  391. general: general {
  392. label = "white:general";
  393. gpios = <&qcom_pinmux 66 GPIO_ACTIVE_HIGH>;
  394. };
  395. };
  396. };
  397. &adm_dma {
  398. status = "okay";
  399. };