qcom-ipq8065-r7800.dts 9.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525
  1. #include "qcom-ipq8065.dtsi"
  2. #include <dt-bindings/input/input.h>
  3. / {
  4. model = "Netgear Nighthawk X4S R7800";
  5. compatible = "netgear,r7800", "qcom,ipq8065", "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. rsvd@5fe00000 {
  19. reg = <0x5fe00000 0x200000>;
  20. reusable;
  21. };
  22. };
  23. aliases {
  24. serial0 = &gsbi4_serial;
  25. mdio-gpio0 = &mdio0;
  26. led-boot = &power_white;
  27. led-failsafe = &power_amber;
  28. led-running = &power_white;
  29. led-upgrade = &power_amber;
  30. };
  31. chosen {
  32. linux,stdout-path = "serial0:115200n8";
  33. };
  34. soc {
  35. pinmux@800000 {
  36. button_pins: button_pins {
  37. mux {
  38. pins = "gpio6", "gpio54", "gpio65";
  39. function = "gpio";
  40. drive-strength = <2>;
  41. bias-pull-up;
  42. };
  43. };
  44. i2c4_pins: i2c4_pinmux {
  45. mux {
  46. pins = "gpio12", "gpio13";
  47. function = "gsbi4";
  48. drive-strength = <12>;
  49. bias-disable;
  50. };
  51. };
  52. led_pins: led_pins {
  53. pins = "gpio7", "gpio8", "gpio9", "gpio22", "gpio23",
  54. "gpio24","gpio26", "gpio53", "gpio64";
  55. function = "gpio";
  56. drive-strength = <2>;
  57. bias-pull-down;
  58. };
  59. nand_pins: nand_pins {
  60. mux {
  61. pins = "gpio34", "gpio35", "gpio36",
  62. "gpio37", "gpio38", "gpio39",
  63. "gpio40", "gpio41", "gpio42",
  64. "gpio43", "gpio44", "gpio45",
  65. "gpio46", "gpio47";
  66. function = "nand";
  67. drive-strength = <10>;
  68. bias-disable;
  69. };
  70. pullups {
  71. pins = "gpio39";
  72. bias-pull-up;
  73. };
  74. hold {
  75. pins = "gpio40", "gpio41", "gpio42",
  76. "gpio43", "gpio44", "gpio45",
  77. "gpio46", "gpio47";
  78. bias-bus-hold;
  79. };
  80. };
  81. mdio0_pins: mdio0_pins {
  82. mux {
  83. pins = "gpio0", "gpio1";
  84. function = "gpio";
  85. drive-strength = <8>;
  86. bias-disable;
  87. };
  88. clk {
  89. pins = "gpio1";
  90. input-disable;
  91. };
  92. };
  93. rgmii2_pins: rgmii2_pins {
  94. mux {
  95. pins = "gpio27", "gpio28", "gpio29", "gpio30", "gpio31", "gpio32",
  96. "gpio51", "gpio52", "gpio59", "gpio60", "gpio61", "gpio62" ;
  97. function = "rgmii2";
  98. drive-strength = <8>;
  99. bias-disable;
  100. };
  101. tx {
  102. pins = "gpio27", "gpio28", "gpio29", "gpio30", "gpio31", "gpio32" ;
  103. input-disable;
  104. };
  105. };
  106. spi_pins: spi_pins {
  107. mux {
  108. pins = "gpio18", "gpio19", "gpio21";
  109. function = "gsbi5";
  110. bias-pull-down;
  111. };
  112. data {
  113. pins = "gpio18", "gpio19";
  114. drive-strength = <10>;
  115. };
  116. cs {
  117. pins = "gpio20";
  118. drive-strength = <10>;
  119. bias-pull-up;
  120. };
  121. clk {
  122. pins = "gpio21";
  123. drive-strength = <12>;
  124. };
  125. };
  126. spi6_pins: spi6_pins {
  127. mux {
  128. pins = "gpio55", "gpio56", "gpio58";
  129. function = "gsbi6";
  130. bias-pull-down;
  131. };
  132. mosi {
  133. pins = "gpio55";
  134. drive-strength = <12>;
  135. };
  136. miso {
  137. pins = "gpio56";
  138. drive-strength = <14>;
  139. };
  140. cs {
  141. pins = "gpio57";
  142. drive-strength = <12>;
  143. bias-pull-up;
  144. };
  145. clk {
  146. pins = "gpio58";
  147. drive-strength = <12>;
  148. };
  149. reset {
  150. pins = "gpio33";
  151. drive-strength = <10>;
  152. bias-pull-down;
  153. output-high;
  154. };
  155. };
  156. usb0_pwr_en_pins: usb0_pwr_en_pins {
  157. mux {
  158. pins = "gpio15";
  159. function = "gpio";
  160. drive-strength = <12>;
  161. bias-pull-down;
  162. output-high;
  163. };
  164. };
  165. usb1_pwr_en_pins: usb1_pwr_en_pins {
  166. mux {
  167. pins = "gpio16", "gpio68";
  168. function = "gpio";
  169. drive-strength = <12>;
  170. bias-pull-down;
  171. output-high;
  172. };
  173. };
  174. };
  175. gsbi@16300000 {
  176. qcom,mode = <GSBI_PROT_I2C_UART>;
  177. status = "ok";
  178. serial@16340000 {
  179. status = "ok";
  180. };
  181. /*
  182. * The i2c device on gsbi4 should not be enabled.
  183. * On ipq806x designs gsbi4 i2c is meant for exclusive
  184. * RPM usage. Turning this on in kernel manifests as
  185. * i2c failure for the RPM.
  186. */
  187. };
  188. sata-phy@1b400000 {
  189. status = "ok";
  190. };
  191. sata@29000000 {
  192. ports-implemented = <0x1>;
  193. status = "ok";
  194. };
  195. phy@100f8800 { /* USB3 port 1 HS phy */
  196. status = "ok";
  197. };
  198. phy@100f8830 { /* USB3 port 1 SS phy */
  199. status = "ok";
  200. };
  201. phy@110f8800 { /* USB3 port 0 HS phy */
  202. status = "ok";
  203. };
  204. phy@110f8830 { /* USB3 port 0 SS phy */
  205. status = "ok";
  206. };
  207. usb30@0 {
  208. status = "ok";
  209. pinctrl-0 = <&usb0_pwr_en_pins>;
  210. pinctrl-names = "default";
  211. };
  212. usb30@1 {
  213. status = "ok";
  214. pinctrl-0 = <&usb1_pwr_en_pins>;
  215. pinctrl-names = "default";
  216. };
  217. pcie0: pci@1b500000 {
  218. status = "ok";
  219. };
  220. pcie1: pci@1b700000 {
  221. status = "ok";
  222. force_gen1 = <1>;
  223. };
  224. nand@1ac00000 {
  225. status = "ok";
  226. pinctrl-0 = <&nand_pins>;
  227. pinctrl-names = "default";
  228. cs0 {
  229. reg = <0>;
  230. compatible = "qcom,nandcs";
  231. nand-ecc-strength = <4>;
  232. nand-bus-width = <8>;
  233. nand-ecc-step-size = <512>;
  234. partitions {
  235. compatible = "fixed-partitions";
  236. #address-cells = <1>;
  237. #size-cells = <1>;
  238. qcadata@0 {
  239. label = "qcadata";
  240. reg = <0x0000000 0x0c80000>;
  241. read-only;
  242. };
  243. APPSBL@c80000 {
  244. label = "APPSBL";
  245. reg = <0x0c80000 0x0500000>;
  246. read-only;
  247. };
  248. APPSBLENV@1180000 {
  249. label = "APPSBLENV";
  250. reg = <0x1180000 0x0080000>;
  251. read-only;
  252. };
  253. art: art@1200000 {
  254. label = "art";
  255. reg = <0x1200000 0x0140000>;
  256. read-only;
  257. };
  258. artbak: art@1340000 {
  259. label = "artbak";
  260. reg = <0x1340000 0x0140000>;
  261. read-only;
  262. };
  263. kernel@1480000 {
  264. label = "kernel";
  265. reg = <0x1480000 0x0400000>;
  266. };
  267. ubi@1880000 {
  268. label = "ubi";
  269. reg = <0x1880000 0x1C00000>;
  270. };
  271. netgear@3480000 {
  272. label = "netgear";
  273. reg = <0x3480000 0x4480000>;
  274. read-only;
  275. };
  276. reserve@7900000 {
  277. label = "reserve";
  278. reg = <0x7900000 0x0700000>;
  279. read-only;
  280. };
  281. firmware@1480000 {
  282. label = "firmware";
  283. reg = <0x1480000 0x2000000>;
  284. };
  285. };
  286. };
  287. };
  288. mdio0: mdio {
  289. compatible = "virtual,mdio-gpio";
  290. #address-cells = <1>;
  291. #size-cells = <0>;
  292. gpios = <&qcom_pinmux 1 GPIO_ACTIVE_HIGH &qcom_pinmux 0 GPIO_ACTIVE_HIGH>;
  293. pinctrl-0 = <&mdio0_pins>;
  294. pinctrl-names = "default";
  295. phy0: ethernet-phy@0 {
  296. device_type = "ethernet-phy";
  297. reg = <0>;
  298. qca,ar8327-initvals = <
  299. 0x00004 0x7600000 /* PAD0_MODE */
  300. 0x00008 0x1000000 /* PAD5_MODE */
  301. 0x0000c 0x80 /* PAD6_MODE */
  302. 0x000e4 0xaa545 /* MAC_POWER_SEL */
  303. 0x000e0 0xc74164de /* SGMII_CTRL */
  304. 0x0007c 0x4e /* PORT0_STATUS */
  305. 0x00094 0x4e /* PORT6_STATUS */
  306. 0x00970 0x1e864443 /* QM_PORT0_CTRL0 */
  307. 0x00974 0x000001c6 /* QM_PORT0_CTRL1 */
  308. 0x00978 0x19008643 /* QM_PORT1_CTRL0 */
  309. 0x0097c 0x000001c6 /* QM_PORT1_CTRL1 */
  310. 0x00980 0x19008643 /* QM_PORT2_CTRL0 */
  311. 0x00984 0x000001c6 /* QM_PORT2_CTRL1 */
  312. 0x00988 0x19008643 /* QM_PORT3_CTRL0 */
  313. 0x0098c 0x000001c6 /* QM_PORT3_CTRL1 */
  314. 0x00990 0x19008643 /* QM_PORT4_CTRL0 */
  315. 0x00994 0x000001c6 /* QM_PORT4_CTRL1 */
  316. 0x00998 0x1e864443 /* QM_PORT5_CTRL0 */
  317. 0x0099c 0x000001c6 /* QM_PORT5_CTRL1 */
  318. 0x009a0 0x1e864443 /* QM_PORT6_CTRL0 */
  319. 0x009a4 0x000001c6 /* QM_PORT6_CTRL1 */
  320. >;
  321. qca,ar8327-vlans = <
  322. 0x1 0x5e /* VLAN1 Ports 1/2/3/4/6 */
  323. 0x2 0x21 /* VLAN2 Ports 0/5 */
  324. >;
  325. };
  326. phy4: ethernet-phy@4 {
  327. device_type = "ethernet-phy";
  328. reg = <4>;
  329. qca,ar8327-initvals = <
  330. 0x000e4 0x6a545 /* MAC_POWER_SEL */
  331. 0x0000c 0x80 /* PAD6_MODE */
  332. >;
  333. };
  334. };
  335. gmac1: ethernet@37200000 {
  336. status = "ok";
  337. phy-mode = "rgmii";
  338. qcom,id = <1>;
  339. qcom,phy_mdio_addr = <4>;
  340. qcom,poll_required = <0>;
  341. qcom,rgmii_delay = <1>;
  342. qcom,phy_mii_type = <0>;
  343. qcom,emulation = <0>;
  344. qcom,irq = <255>;
  345. mdiobus = <&mdio0>;
  346. pinctrl-0 = <&rgmii2_pins>;
  347. pinctrl-names = "default";
  348. mtd-mac-address = <&art 6>;
  349. fixed-link {
  350. speed = <1000>;
  351. full-duplex;
  352. };
  353. };
  354. gmac2: ethernet@37400000 {
  355. status = "ok";
  356. phy-mode = "sgmii";
  357. qcom,id = <2>;
  358. qcom,phy_mdio_addr = <0>; /* none */
  359. qcom,poll_required = <0>; /* no polling */
  360. qcom,rgmii_delay = <0>;
  361. qcom,phy_mii_type = <1>;
  362. qcom,emulation = <0>;
  363. qcom,irq = <258>;
  364. mdiobus = <&mdio0>;
  365. mtd-mac-address = <&art 0>;
  366. fixed-link {
  367. speed = <1000>;
  368. full-duplex;
  369. };
  370. };
  371. };
  372. gpio-keys {
  373. compatible = "gpio-keys";
  374. pinctrl-0 = <&button_pins>;
  375. pinctrl-names = "default";
  376. wifi {
  377. label = "wifi";
  378. gpios = <&qcom_pinmux 6 GPIO_ACTIVE_LOW>;
  379. linux,code = <KEY_RFKILL>;
  380. debounce-interval = <60>;
  381. wakeup-source;
  382. };
  383. reset {
  384. label = "reset";
  385. gpios = <&qcom_pinmux 54 GPIO_ACTIVE_LOW>;
  386. linux,code = <KEY_RESTART>;
  387. debounce-interval = <60>;
  388. wakeup-source;
  389. };
  390. wps {
  391. label = "wps";
  392. gpios = <&qcom_pinmux 65 GPIO_ACTIVE_LOW>;
  393. linux,code = <KEY_WPS_BUTTON>;
  394. debounce-interval = <60>;
  395. wakeup-source;
  396. };
  397. };
  398. gpio-leds {
  399. compatible = "gpio-leds";
  400. pinctrl-0 = <&led_pins>;
  401. pinctrl-names = "default";
  402. power_white: power_white {
  403. label = "r7800:white:power";
  404. gpios = <&qcom_pinmux 53 GPIO_ACTIVE_HIGH>;
  405. default-state = "keep";
  406. };
  407. power_amber: power_amber {
  408. label = "r7800:amber:power";
  409. gpios = <&qcom_pinmux 9 GPIO_ACTIVE_HIGH>;
  410. };
  411. wan_white {
  412. label = "r7800:white:wan";
  413. gpios = <&qcom_pinmux 22 GPIO_ACTIVE_HIGH>;
  414. };
  415. wan_amber {
  416. label = "r7800:amber:wan";
  417. gpios = <&qcom_pinmux 23 GPIO_ACTIVE_HIGH>;
  418. };
  419. usb1 {
  420. label = "r7800:white:usb1";
  421. gpios = <&qcom_pinmux 7 GPIO_ACTIVE_HIGH>;
  422. };
  423. usb2 {
  424. label = "r7800:white:usb2";
  425. gpios = <&qcom_pinmux 8 GPIO_ACTIVE_HIGH>;
  426. };
  427. esata {
  428. label = "r7800:white:esata";
  429. gpios = <&qcom_pinmux 26 GPIO_ACTIVE_HIGH>;
  430. };
  431. wifi {
  432. label = "r7800:white:wifi";
  433. gpios = <&qcom_pinmux 64 GPIO_ACTIVE_HIGH>;
  434. };
  435. wps {
  436. label = "r7800:white:wps";
  437. gpios = <&qcom_pinmux 24 GPIO_ACTIVE_HIGH>;
  438. };
  439. };
  440. };
  441. &adm_dma {
  442. status = "ok";
  443. };