sun50i-h6.dtsi 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128
  1. // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
  2. // Copyright (C) 2017 Icenowy Zheng <[email protected]>
  3. #include <dt-bindings/interrupt-controller/arm-gic.h>
  4. #include <dt-bindings/clock/sun50i-h6-ccu.h>
  5. #include <dt-bindings/clock/sun50i-h6-r-ccu.h>
  6. #include <dt-bindings/clock/sun6i-rtc.h>
  7. #include <dt-bindings/clock/sun8i-de2.h>
  8. #include <dt-bindings/clock/sun8i-tcon-top.h>
  9. #include <dt-bindings/reset/sun50i-h6-ccu.h>
  10. #include <dt-bindings/reset/sun50i-h6-r-ccu.h>
  11. #include <dt-bindings/reset/sun8i-de2.h>
  12. #include <dt-bindings/thermal/thermal.h>
  13. / {
  14. interrupt-parent = <&gic>;
  15. #address-cells = <1>;
  16. #size-cells = <1>;
  17. cpus {
  18. #address-cells = <1>;
  19. #size-cells = <0>;
  20. cpu0: cpu@0 {
  21. compatible = "arm,cortex-a53";
  22. device_type = "cpu";
  23. reg = <0>;
  24. enable-method = "psci";
  25. clocks = <&ccu CLK_CPUX>;
  26. clock-latency-ns = <244144>; /* 8 32k periods */
  27. #cooling-cells = <2>;
  28. };
  29. cpu1: cpu@1 {
  30. compatible = "arm,cortex-a53";
  31. device_type = "cpu";
  32. reg = <1>;
  33. enable-method = "psci";
  34. clocks = <&ccu CLK_CPUX>;
  35. clock-latency-ns = <244144>; /* 8 32k periods */
  36. #cooling-cells = <2>;
  37. };
  38. cpu2: cpu@2 {
  39. compatible = "arm,cortex-a53";
  40. device_type = "cpu";
  41. reg = <2>;
  42. enable-method = "psci";
  43. clocks = <&ccu CLK_CPUX>;
  44. clock-latency-ns = <244144>; /* 8 32k periods */
  45. #cooling-cells = <2>;
  46. };
  47. cpu3: cpu@3 {
  48. compatible = "arm,cortex-a53";
  49. device_type = "cpu";
  50. reg = <3>;
  51. enable-method = "psci";
  52. clocks = <&ccu CLK_CPUX>;
  53. clock-latency-ns = <244144>; /* 8 32k periods */
  54. #cooling-cells = <2>;
  55. };
  56. };
  57. de: display-engine {
  58. compatible = "allwinner,sun50i-h6-display-engine";
  59. allwinner,pipelines = <&mixer0>;
  60. status = "disabled";
  61. };
  62. osc24M: osc24M_clk {
  63. #clock-cells = <0>;
  64. compatible = "fixed-clock";
  65. clock-frequency = <24000000>;
  66. clock-output-names = "osc24M";
  67. };
  68. pmu {
  69. compatible = "arm,cortex-a53-pmu";
  70. interrupts = <GIC_SPI 140 IRQ_TYPE_LEVEL_HIGH>,
  71. <GIC_SPI 141 IRQ_TYPE_LEVEL_HIGH>,
  72. <GIC_SPI 142 IRQ_TYPE_LEVEL_HIGH>,
  73. <GIC_SPI 143 IRQ_TYPE_LEVEL_HIGH>;
  74. interrupt-affinity = <&cpu0>, <&cpu1>, <&cpu2>, <&cpu3>;
  75. };
  76. psci {
  77. compatible = "arm,psci-0.2";
  78. method = "smc";
  79. };
  80. timer {
  81. compatible = "arm,armv8-timer";
  82. arm,no-tick-in-suspend;
  83. interrupts = <GIC_PPI 13
  84. (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>,
  85. <GIC_PPI 14
  86. (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>,
  87. <GIC_PPI 11
  88. (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>,
  89. <GIC_PPI 10
  90. (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
  91. };
  92. soc {
  93. compatible = "simple-bus";
  94. #address-cells = <1>;
  95. #size-cells = <1>;
  96. ranges;
  97. bus@1000000 {
  98. compatible = "allwinner,sun50i-h6-de3",
  99. "allwinner,sun50i-a64-de2";
  100. reg = <0x1000000 0x400000>;
  101. allwinner,sram = <&de2_sram 1>;
  102. #address-cells = <1>;
  103. #size-cells = <1>;
  104. ranges = <0 0x1000000 0x400000>;
  105. display_clocks: clock@0 {
  106. compatible = "allwinner,sun50i-h6-de3-clk";
  107. reg = <0x0 0x10000>;
  108. clocks = <&ccu CLK_BUS_DE>,
  109. <&ccu CLK_DE>;
  110. clock-names = "bus",
  111. "mod";
  112. resets = <&ccu RST_BUS_DE>;
  113. #clock-cells = <1>;
  114. #reset-cells = <1>;
  115. };
  116. mixer0: mixer@100000 {
  117. compatible = "allwinner,sun50i-h6-de3-mixer-0";
  118. reg = <0x100000 0x100000>;
  119. clocks = <&display_clocks CLK_BUS_MIXER0>,
  120. <&display_clocks CLK_MIXER0>;
  121. clock-names = "bus",
  122. "mod";
  123. resets = <&display_clocks RST_MIXER0>;
  124. iommus = <&iommu 0>;
  125. ports {
  126. #address-cells = <1>;
  127. #size-cells = <0>;
  128. mixer0_out: port@1 {
  129. reg = <1>;
  130. mixer0_out_tcon_top_mixer0: endpoint {
  131. remote-endpoint = <&tcon_top_mixer0_in_mixer0>;
  132. };
  133. };
  134. };
  135. };
  136. };
  137. video-codec-g2@1c00000 {
  138. compatible = "allwinner,sun50i-h6-vpu-g2";
  139. reg = <0x01c00000 0x1000>;
  140. interrupts = <GIC_SPI 90 IRQ_TYPE_LEVEL_HIGH>;
  141. clocks = <&ccu CLK_BUS_VP9>, <&ccu CLK_VP9>;
  142. clock-names = "bus", "mod";
  143. resets = <&ccu RST_BUS_VP9>;
  144. iommus = <&iommu 5>;
  145. };
  146. video-codec@1c0e000 {
  147. compatible = "allwinner,sun50i-h6-video-engine";
  148. reg = <0x01c0e000 0x2000>;
  149. clocks = <&ccu CLK_BUS_VE>, <&ccu CLK_VE>,
  150. <&ccu CLK_MBUS_VE>;
  151. clock-names = "ahb", "mod", "ram";
  152. resets = <&ccu RST_BUS_VE>;
  153. interrupts = <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>;
  154. allwinner,sram = <&ve_sram 1>;
  155. iommus = <&iommu 3>;
  156. };
  157. gpu: gpu@1800000 {
  158. compatible = "allwinner,sun50i-h6-mali",
  159. "arm,mali-t720";
  160. reg = <0x01800000 0x4000>;
  161. interrupts = <GIC_SPI 84 IRQ_TYPE_LEVEL_HIGH>,
  162. <GIC_SPI 85 IRQ_TYPE_LEVEL_HIGH>,
  163. <GIC_SPI 83 IRQ_TYPE_LEVEL_HIGH>;
  164. interrupt-names = "job", "mmu", "gpu";
  165. clocks = <&ccu CLK_GPU>, <&ccu CLK_BUS_GPU>;
  166. clock-names = "core", "bus";
  167. resets = <&ccu RST_BUS_GPU>;
  168. #cooling-cells = <2>;
  169. status = "disabled";
  170. };
  171. crypto: crypto@1904000 {
  172. compatible = "allwinner,sun50i-h6-crypto";
  173. reg = <0x01904000 0x1000>;
  174. interrupts = <GIC_SPI 87 IRQ_TYPE_LEVEL_HIGH>;
  175. clocks = <&ccu CLK_BUS_CE>, <&ccu CLK_CE>, <&ccu CLK_MBUS_CE>;
  176. clock-names = "bus", "mod", "ram";
  177. resets = <&ccu RST_BUS_CE>;
  178. };
  179. syscon: syscon@3000000 {
  180. compatible = "allwinner,sun50i-h6-system-control",
  181. "allwinner,sun50i-a64-system-control";
  182. reg = <0x03000000 0x1000>;
  183. #address-cells = <1>;
  184. #size-cells = <1>;
  185. ranges;
  186. sram_c: sram@28000 {
  187. compatible = "mmio-sram";
  188. reg = <0x00028000 0x1e000>;
  189. #address-cells = <1>;
  190. #size-cells = <1>;
  191. ranges = <0 0x00028000 0x1e000>;
  192. de2_sram: sram-section@0 {
  193. compatible = "allwinner,sun50i-h6-sram-c",
  194. "allwinner,sun50i-a64-sram-c";
  195. reg = <0x0000 0x1e000>;
  196. };
  197. };
  198. sram_c1: sram@1a00000 {
  199. compatible = "mmio-sram";
  200. reg = <0x01a00000 0x200000>;
  201. #address-cells = <1>;
  202. #size-cells = <1>;
  203. ranges = <0 0x01a00000 0x200000>;
  204. ve_sram: sram-section@0 {
  205. compatible = "allwinner,sun50i-h6-sram-c1",
  206. "allwinner,sun4i-a10-sram-c1";
  207. reg = <0x000000 0x200000>;
  208. };
  209. };
  210. };
  211. ccu: clock@3001000 {
  212. compatible = "allwinner,sun50i-h6-ccu";
  213. reg = <0x03001000 0x1000>;
  214. clocks = <&osc24M>, <&rtc CLK_OSC32K>, <&rtc CLK_IOSC>;
  215. clock-names = "hosc", "losc", "iosc";
  216. #clock-cells = <1>;
  217. #reset-cells = <1>;
  218. };
  219. dma: dma-controller@3002000 {
  220. compatible = "allwinner,sun50i-h6-dma";
  221. reg = <0x03002000 0x1000>;
  222. interrupts = <GIC_SPI 43 IRQ_TYPE_LEVEL_HIGH>;
  223. clocks = <&ccu CLK_BUS_DMA>, <&ccu CLK_MBUS_DMA>;
  224. clock-names = "bus", "mbus";
  225. dma-channels = <16>;
  226. dma-requests = <46>;
  227. resets = <&ccu RST_BUS_DMA>;
  228. #dma-cells = <1>;
  229. };
  230. msgbox: mailbox@3003000 {
  231. compatible = "allwinner,sun50i-h6-msgbox",
  232. "allwinner,sun6i-a31-msgbox";
  233. reg = <0x03003000 0x1000>;
  234. clocks = <&ccu CLK_BUS_MSGBOX>;
  235. resets = <&ccu RST_BUS_MSGBOX>;
  236. interrupts = <GIC_SPI 44 IRQ_TYPE_LEVEL_HIGH>;
  237. #mbox-cells = <1>;
  238. };
  239. sid: efuse@3006000 {
  240. compatible = "allwinner,sun50i-h6-sid";
  241. reg = <0x03006000 0x400>;
  242. #address-cells = <1>;
  243. #size-cells = <1>;
  244. ths_calibration: thermal-sensor-calibration@14 {
  245. reg = <0x14 0x8>;
  246. };
  247. cpu_speed_grade: cpu-speed-grade@1c {
  248. reg = <0x1c 0x4>;
  249. };
  250. };
  251. timer@3009000 {
  252. compatible = "allwinner,sun50i-h6-timer",
  253. "allwinner,sun8i-a23-timer";
  254. reg = <0x03009000 0xa0>;
  255. interrupts = <GIC_SPI 48 IRQ_TYPE_LEVEL_HIGH>,
  256. <GIC_SPI 49 IRQ_TYPE_LEVEL_HIGH>;
  257. clocks = <&osc24M>;
  258. };
  259. watchdog: watchdog@30090a0 {
  260. compatible = "allwinner,sun50i-h6-wdt",
  261. "allwinner,sun6i-a31-wdt";
  262. reg = <0x030090a0 0x20>;
  263. interrupts = <GIC_SPI 50 IRQ_TYPE_LEVEL_HIGH>;
  264. clocks = <&osc24M>;
  265. /* Broken on some H6 boards */
  266. status = "disabled";
  267. };
  268. pwm: pwm@300a000 {
  269. compatible = "allwinner,sun50i-h6-pwm";
  270. reg = <0x0300a000 0x400>;
  271. clocks = <&osc24M>, <&ccu CLK_BUS_PWM>;
  272. clock-names = "mod", "bus";
  273. resets = <&ccu RST_BUS_PWM>;
  274. #pwm-cells = <3>;
  275. status = "disabled";
  276. };
  277. pio: pinctrl@300b000 {
  278. compatible = "allwinner,sun50i-h6-pinctrl";
  279. reg = <0x0300b000 0x400>;
  280. interrupt-parent = <&r_intc>;
  281. interrupts = <GIC_SPI 51 IRQ_TYPE_LEVEL_HIGH>,
  282. <GIC_SPI 53 IRQ_TYPE_LEVEL_HIGH>,
  283. <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>,
  284. <GIC_SPI 59 IRQ_TYPE_LEVEL_HIGH>;
  285. clocks = <&ccu CLK_APB1>, <&osc24M>, <&rtc CLK_OSC32K>;
  286. clock-names = "apb", "hosc", "losc";
  287. gpio-controller;
  288. #gpio-cells = <3>;
  289. interrupt-controller;
  290. #interrupt-cells = <3>;
  291. ext_rgmii_pins: rgmii-pins {
  292. pins = "PD0", "PD1", "PD2", "PD3", "PD4",
  293. "PD5", "PD7", "PD8", "PD9", "PD10",
  294. "PD11", "PD12", "PD13", "PD19", "PD20";
  295. function = "emac";
  296. drive-strength = <40>;
  297. };
  298. hdmi_pins: hdmi-pins {
  299. pins = "PH8", "PH9", "PH10";
  300. function = "hdmi";
  301. };
  302. i2c0_pins: i2c0-pins {
  303. pins = "PD25", "PD26";
  304. function = "i2c0";
  305. };
  306. i2c1_pins: i2c1-pins {
  307. pins = "PH5", "PH6";
  308. function = "i2c1";
  309. };
  310. i2c2_pins: i2c2-pins {
  311. pins = "PD23", "PD24";
  312. function = "i2c2";
  313. };
  314. mmc0_pins: mmc0-pins {
  315. pins = "PF0", "PF1", "PF2", "PF3",
  316. "PF4", "PF5";
  317. function = "mmc0";
  318. drive-strength = <30>;
  319. bias-pull-up;
  320. };
  321. /omit-if-no-ref/
  322. mmc1_pins: mmc1-pins {
  323. pins = "PG0", "PG1", "PG2", "PG3",
  324. "PG4", "PG5";
  325. function = "mmc1";
  326. drive-strength = <30>;
  327. bias-pull-up;
  328. };
  329. mmc2_pins: mmc2-pins {
  330. pins = "PC1", "PC4", "PC5", "PC6",
  331. "PC7", "PC8", "PC9", "PC10",
  332. "PC11", "PC12", "PC13", "PC14";
  333. function = "mmc2";
  334. drive-strength = <30>;
  335. bias-pull-up;
  336. };
  337. /omit-if-no-ref/
  338. spi0_pins: spi0-pins {
  339. pins = "PC0", "PC2", "PC3";
  340. function = "spi0";
  341. };
  342. /* pin shared with MMC2-CMD (eMMC) */
  343. /omit-if-no-ref/
  344. spi0_cs_pin: spi0-cs-pin {
  345. pins = "PC5";
  346. function = "spi0";
  347. };
  348. /omit-if-no-ref/
  349. spi1_pins: spi1-pins {
  350. pins = "PH4", "PH5", "PH6";
  351. function = "spi1";
  352. };
  353. /omit-if-no-ref/
  354. spi1_cs_pin: spi1-cs-pin {
  355. pins = "PH3";
  356. function = "spi1";
  357. };
  358. spdif_tx_pin: spdif-tx-pin {
  359. pins = "PH7";
  360. function = "spdif";
  361. };
  362. uart0_ph_pins: uart0-ph-pins {
  363. pins = "PH0", "PH1";
  364. function = "uart0";
  365. };
  366. uart1_pins: uart1-pins {
  367. pins = "PG6", "PG7";
  368. function = "uart1";
  369. };
  370. uart1_rts_cts_pins: uart1-rts-cts-pins {
  371. pins = "PG8", "PG9";
  372. function = "uart1";
  373. };
  374. };
  375. gic: interrupt-controller@3021000 {
  376. compatible = "arm,gic-400";
  377. reg = <0x03021000 0x1000>,
  378. <0x03022000 0x2000>,
  379. <0x03024000 0x2000>,
  380. <0x03026000 0x2000>;
  381. interrupts = <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
  382. interrupt-controller;
  383. #interrupt-cells = <3>;
  384. };
  385. iommu: iommu@30f0000 {
  386. compatible = "allwinner,sun50i-h6-iommu";
  387. reg = <0x030f0000 0x10000>;
  388. interrupts = <GIC_SPI 57 IRQ_TYPE_LEVEL_HIGH>;
  389. clocks = <&ccu CLK_BUS_IOMMU>;
  390. resets = <&ccu RST_BUS_IOMMU>;
  391. #iommu-cells = <1>;
  392. };
  393. mmc0: mmc@4020000 {
  394. compatible = "allwinner,sun50i-h6-mmc",
  395. "allwinner,sun50i-a64-mmc";
  396. reg = <0x04020000 0x1000>;
  397. clocks = <&ccu CLK_BUS_MMC0>, <&ccu CLK_MMC0>;
  398. clock-names = "ahb", "mmc";
  399. resets = <&ccu RST_BUS_MMC0>;
  400. reset-names = "ahb";
  401. interrupts = <GIC_SPI 35 IRQ_TYPE_LEVEL_HIGH>;
  402. pinctrl-names = "default";
  403. pinctrl-0 = <&mmc0_pins>;
  404. max-frequency = <150000000>;
  405. status = "disabled";
  406. #address-cells = <1>;
  407. #size-cells = <0>;
  408. };
  409. mmc1: mmc@4021000 {
  410. compatible = "allwinner,sun50i-h6-mmc",
  411. "allwinner,sun50i-a64-mmc";
  412. reg = <0x04021000 0x1000>;
  413. clocks = <&ccu CLK_BUS_MMC1>, <&ccu CLK_MMC1>;
  414. clock-names = "ahb", "mmc";
  415. resets = <&ccu RST_BUS_MMC1>;
  416. reset-names = "ahb";
  417. interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
  418. pinctrl-names = "default";
  419. pinctrl-0 = <&mmc1_pins>;
  420. max-frequency = <150000000>;
  421. status = "disabled";
  422. #address-cells = <1>;
  423. #size-cells = <0>;
  424. };
  425. mmc2: mmc@4022000 {
  426. compatible = "allwinner,sun50i-h6-emmc",
  427. "allwinner,sun50i-a64-emmc";
  428. reg = <0x04022000 0x1000>;
  429. clocks = <&ccu CLK_BUS_MMC2>, <&ccu CLK_MMC2>;
  430. clock-names = "ahb", "mmc";
  431. resets = <&ccu RST_BUS_MMC2>;
  432. reset-names = "ahb";
  433. interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
  434. pinctrl-names = "default";
  435. pinctrl-0 = <&mmc2_pins>;
  436. max-frequency = <150000000>;
  437. status = "disabled";
  438. #address-cells = <1>;
  439. #size-cells = <0>;
  440. };
  441. uart0: serial@5000000 {
  442. compatible = "snps,dw-apb-uart";
  443. reg = <0x05000000 0x400>;
  444. interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
  445. reg-shift = <2>;
  446. reg-io-width = <4>;
  447. clocks = <&ccu CLK_BUS_UART0>;
  448. resets = <&ccu RST_BUS_UART0>;
  449. status = "disabled";
  450. };
  451. uart1: serial@5000400 {
  452. compatible = "snps,dw-apb-uart";
  453. reg = <0x05000400 0x400>;
  454. interrupts = <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>;
  455. reg-shift = <2>;
  456. reg-io-width = <4>;
  457. clocks = <&ccu CLK_BUS_UART1>;
  458. resets = <&ccu RST_BUS_UART1>;
  459. status = "disabled";
  460. };
  461. uart2: serial@5000800 {
  462. compatible = "snps,dw-apb-uart";
  463. reg = <0x05000800 0x400>;
  464. interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
  465. reg-shift = <2>;
  466. reg-io-width = <4>;
  467. clocks = <&ccu CLK_BUS_UART2>;
  468. resets = <&ccu RST_BUS_UART2>;
  469. status = "disabled";
  470. };
  471. uart3: serial@5000c00 {
  472. compatible = "snps,dw-apb-uart";
  473. reg = <0x05000c00 0x400>;
  474. interrupts = <GIC_SPI 3 IRQ_TYPE_LEVEL_HIGH>;
  475. reg-shift = <2>;
  476. reg-io-width = <4>;
  477. clocks = <&ccu CLK_BUS_UART3>;
  478. resets = <&ccu RST_BUS_UART3>;
  479. status = "disabled";
  480. };
  481. i2c0: i2c@5002000 {
  482. compatible = "allwinner,sun50i-h6-i2c",
  483. "allwinner,sun6i-a31-i2c";
  484. reg = <0x05002000 0x400>;
  485. interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>;
  486. clocks = <&ccu CLK_BUS_I2C0>;
  487. resets = <&ccu RST_BUS_I2C0>;
  488. pinctrl-names = "default";
  489. pinctrl-0 = <&i2c0_pins>;
  490. status = "disabled";
  491. #address-cells = <1>;
  492. #size-cells = <0>;
  493. };
  494. i2c1: i2c@5002400 {
  495. compatible = "allwinner,sun50i-h6-i2c",
  496. "allwinner,sun6i-a31-i2c";
  497. reg = <0x05002400 0x400>;
  498. interrupts = <GIC_SPI 5 IRQ_TYPE_LEVEL_HIGH>;
  499. clocks = <&ccu CLK_BUS_I2C1>;
  500. resets = <&ccu RST_BUS_I2C1>;
  501. pinctrl-names = "default";
  502. pinctrl-0 = <&i2c1_pins>;
  503. status = "disabled";
  504. #address-cells = <1>;
  505. #size-cells = <0>;
  506. };
  507. i2c2: i2c@5002800 {
  508. compatible = "allwinner,sun50i-h6-i2c",
  509. "allwinner,sun6i-a31-i2c";
  510. reg = <0x05002800 0x400>;
  511. interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
  512. clocks = <&ccu CLK_BUS_I2C2>;
  513. resets = <&ccu RST_BUS_I2C2>;
  514. pinctrl-names = "default";
  515. pinctrl-0 = <&i2c2_pins>;
  516. status = "disabled";
  517. #address-cells = <1>;
  518. #size-cells = <0>;
  519. };
  520. spi0: spi@5010000 {
  521. compatible = "allwinner,sun50i-h6-spi",
  522. "allwinner,sun8i-h3-spi";
  523. reg = <0x05010000 0x1000>;
  524. interrupts = <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
  525. clocks = <&ccu CLK_BUS_SPI0>, <&ccu CLK_SPI0>;
  526. clock-names = "ahb", "mod";
  527. dmas = <&dma 22>, <&dma 22>;
  528. dma-names = "rx", "tx";
  529. resets = <&ccu RST_BUS_SPI0>;
  530. status = "disabled";
  531. #address-cells = <1>;
  532. #size-cells = <0>;
  533. };
  534. spi1: spi@5011000 {
  535. compatible = "allwinner,sun50i-h6-spi",
  536. "allwinner,sun8i-h3-spi";
  537. reg = <0x05011000 0x1000>;
  538. interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
  539. clocks = <&ccu CLK_BUS_SPI1>, <&ccu CLK_SPI1>;
  540. clock-names = "ahb", "mod";
  541. dmas = <&dma 23>, <&dma 23>;
  542. dma-names = "rx", "tx";
  543. resets = <&ccu RST_BUS_SPI1>;
  544. status = "disabled";
  545. #address-cells = <1>;
  546. #size-cells = <0>;
  547. };
  548. emac: ethernet@5020000 {
  549. compatible = "allwinner,sun50i-h6-emac",
  550. "allwinner,sun50i-a64-emac";
  551. syscon = <&syscon>;
  552. reg = <0x05020000 0x10000>;
  553. interrupts = <GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>;
  554. interrupt-names = "macirq";
  555. resets = <&ccu RST_BUS_EMAC>;
  556. reset-names = "stmmaceth";
  557. clocks = <&ccu CLK_BUS_EMAC>;
  558. clock-names = "stmmaceth";
  559. status = "disabled";
  560. mdio: mdio {
  561. compatible = "snps,dwmac-mdio";
  562. #address-cells = <1>;
  563. #size-cells = <0>;
  564. };
  565. };
  566. i2s1: i2s@5091000 {
  567. #sound-dai-cells = <0>;
  568. compatible = "allwinner,sun50i-h6-i2s";
  569. reg = <0x05091000 0x1000>;
  570. interrupts = <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>;
  571. clocks = <&ccu CLK_BUS_I2S1>, <&ccu CLK_I2S1>;
  572. clock-names = "apb", "mod";
  573. dmas = <&dma 4>, <&dma 4>;
  574. resets = <&ccu RST_BUS_I2S1>;
  575. dma-names = "rx", "tx";
  576. status = "disabled";
  577. };
  578. spdif: spdif@5093000 {
  579. #sound-dai-cells = <0>;
  580. compatible = "allwinner,sun50i-h6-spdif";
  581. reg = <0x05093000 0x400>;
  582. interrupts = <GIC_SPI 21 IRQ_TYPE_LEVEL_HIGH>;
  583. clocks = <&ccu CLK_BUS_SPDIF>, <&ccu CLK_SPDIF>;
  584. clock-names = "apb", "spdif";
  585. resets = <&ccu RST_BUS_SPDIF>;
  586. dmas = <&dma 2>;
  587. dma-names = "tx";
  588. pinctrl-names = "default";
  589. pinctrl-0 = <&spdif_tx_pin>;
  590. status = "disabled";
  591. };
  592. usb2otg: usb@5100000 {
  593. compatible = "allwinner,sun50i-h6-musb",
  594. "allwinner,sun8i-a33-musb";
  595. reg = <0x05100000 0x0400>;
  596. clocks = <&ccu CLK_BUS_OTG>;
  597. resets = <&ccu RST_BUS_OTG>;
  598. interrupts = <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH>;
  599. interrupt-names = "mc";
  600. phys = <&usb2phy 0>;
  601. phy-names = "usb";
  602. extcon = <&usb2phy 0>;
  603. status = "disabled";
  604. };
  605. usb2phy: phy@5100400 {
  606. compatible = "allwinner,sun50i-h6-usb-phy";
  607. reg = <0x05100400 0x24>,
  608. <0x05101800 0x4>,
  609. <0x05311800 0x4>;
  610. reg-names = "phy_ctrl",
  611. "pmu0",
  612. "pmu3";
  613. clocks = <&ccu CLK_USB_PHY0>,
  614. <&ccu CLK_USB_PHY3>;
  615. clock-names = "usb0_phy",
  616. "usb3_phy";
  617. resets = <&ccu RST_USB_PHY0>,
  618. <&ccu RST_USB_PHY3>;
  619. reset-names = "usb0_reset",
  620. "usb3_reset";
  621. status = "disabled";
  622. #phy-cells = <1>;
  623. };
  624. ehci0: usb@5101000 {
  625. compatible = "allwinner,sun50i-h6-ehci", "generic-ehci";
  626. reg = <0x05101000 0x100>;
  627. interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>;
  628. clocks = <&ccu CLK_BUS_OHCI0>,
  629. <&ccu CLK_BUS_EHCI0>,
  630. <&ccu CLK_USB_OHCI0>;
  631. resets = <&ccu RST_BUS_OHCI0>,
  632. <&ccu RST_BUS_EHCI0>;
  633. phys = <&usb2phy 0>;
  634. phy-names = "usb";
  635. status = "disabled";
  636. };
  637. ohci0: usb@5101400 {
  638. compatible = "allwinner,sun50i-h6-ohci", "generic-ohci";
  639. reg = <0x05101400 0x100>;
  640. interrupts = <GIC_SPI 25 IRQ_TYPE_LEVEL_HIGH>;
  641. clocks = <&ccu CLK_BUS_OHCI0>,
  642. <&ccu CLK_USB_OHCI0>;
  643. resets = <&ccu RST_BUS_OHCI0>;
  644. phys = <&usb2phy 0>;
  645. phy-names = "usb";
  646. status = "disabled";
  647. };
  648. dwc3: usb@5200000 {
  649. compatible = "snps,dwc3";
  650. reg = <0x05200000 0x10000>;
  651. interrupts = <GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>;
  652. clocks = <&ccu CLK_BUS_XHCI>,
  653. <&ccu CLK_BUS_XHCI>,
  654. <&rtc CLK_OSC32K>;
  655. clock-names = "ref", "bus_early", "suspend";
  656. resets = <&ccu RST_BUS_XHCI>;
  657. /*
  658. * The datasheet of the chip doesn't declare the
  659. * peripheral function, and there's no boards known
  660. * to have a USB Type-B port routed to the port.
  661. * In addition, no one has tested the peripheral
  662. * function yet.
  663. * So set the dr_mode to "host" in the DTSI file.
  664. */
  665. dr_mode = "host";
  666. phys = <&usb3phy>;
  667. phy-names = "usb3-phy";
  668. status = "disabled";
  669. };
  670. usb3phy: phy@5210000 {
  671. compatible = "allwinner,sun50i-h6-usb3-phy";
  672. reg = <0x5210000 0x10000>;
  673. clocks = <&ccu CLK_USB_PHY1>;
  674. resets = <&ccu RST_USB_PHY1>;
  675. #phy-cells = <0>;
  676. status = "disabled";
  677. };
  678. ehci3: usb@5311000 {
  679. compatible = "allwinner,sun50i-h6-ehci", "generic-ehci";
  680. reg = <0x05311000 0x100>;
  681. interrupts = <GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>;
  682. clocks = <&ccu CLK_BUS_OHCI3>,
  683. <&ccu CLK_BUS_EHCI3>,
  684. <&ccu CLK_USB_OHCI3>;
  685. resets = <&ccu RST_BUS_OHCI3>,
  686. <&ccu RST_BUS_EHCI3>;
  687. phys = <&usb2phy 3>;
  688. phy-names = "usb";
  689. status = "disabled";
  690. };
  691. ohci3: usb@5311400 {
  692. compatible = "allwinner,sun50i-h6-ohci", "generic-ohci";
  693. reg = <0x05311400 0x100>;
  694. interrupts = <GIC_SPI 29 IRQ_TYPE_LEVEL_HIGH>;
  695. clocks = <&ccu CLK_BUS_OHCI3>,
  696. <&ccu CLK_USB_OHCI3>;
  697. resets = <&ccu RST_BUS_OHCI3>;
  698. phys = <&usb2phy 3>;
  699. phy-names = "usb";
  700. status = "disabled";
  701. };
  702. hdmi: hdmi@6000000 {
  703. compatible = "allwinner,sun50i-h6-dw-hdmi";
  704. reg = <0x06000000 0x10000>;
  705. reg-io-width = <1>;
  706. interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>;
  707. clocks = <&ccu CLK_BUS_HDMI>, <&ccu CLK_HDMI_SLOW>,
  708. <&ccu CLK_HDMI>, <&ccu CLK_HDMI_CEC>,
  709. <&ccu CLK_HDCP>, <&ccu CLK_BUS_HDCP>;
  710. clock-names = "iahb", "isfr", "tmds", "cec", "hdcp",
  711. "hdcp-bus";
  712. resets = <&ccu RST_BUS_HDMI_SUB>, <&ccu RST_BUS_HDCP>;
  713. reset-names = "ctrl", "hdcp";
  714. phys = <&hdmi_phy>;
  715. phy-names = "phy";
  716. pinctrl-names = "default";
  717. pinctrl-0 = <&hdmi_pins>;
  718. status = "disabled";
  719. ports {
  720. #address-cells = <1>;
  721. #size-cells = <0>;
  722. hdmi_in: port@0 {
  723. reg = <0>;
  724. hdmi_in_tcon_top: endpoint {
  725. remote-endpoint = <&tcon_top_hdmi_out_hdmi>;
  726. };
  727. };
  728. hdmi_out: port@1 {
  729. reg = <1>;
  730. };
  731. };
  732. };
  733. hdmi_phy: hdmi-phy@6010000 {
  734. compatible = "allwinner,sun50i-h6-hdmi-phy";
  735. reg = <0x06010000 0x10000>;
  736. clocks = <&ccu CLK_BUS_HDMI>, <&ccu CLK_HDMI_SLOW>;
  737. clock-names = "bus", "mod";
  738. resets = <&ccu RST_BUS_HDMI>;
  739. reset-names = "phy";
  740. #phy-cells = <0>;
  741. };
  742. tcon_top: tcon-top@6510000 {
  743. compatible = "allwinner,sun50i-h6-tcon-top";
  744. reg = <0x06510000 0x1000>;
  745. clocks = <&ccu CLK_BUS_TCON_TOP>,
  746. <&ccu CLK_TCON_TV0>;
  747. clock-names = "bus",
  748. "tcon-tv0";
  749. clock-output-names = "tcon-top-tv0";
  750. resets = <&ccu RST_BUS_TCON_TOP>;
  751. #clock-cells = <1>;
  752. ports {
  753. #address-cells = <1>;
  754. #size-cells = <0>;
  755. tcon_top_mixer0_in: port@0 {
  756. #address-cells = <1>;
  757. #size-cells = <0>;
  758. reg = <0>;
  759. tcon_top_mixer0_in_mixer0: endpoint@0 {
  760. reg = <0>;
  761. remote-endpoint = <&mixer0_out_tcon_top_mixer0>;
  762. };
  763. };
  764. tcon_top_mixer0_out: port@1 {
  765. #address-cells = <1>;
  766. #size-cells = <0>;
  767. reg = <1>;
  768. tcon_top_mixer0_out_tcon_tv: endpoint@2 {
  769. reg = <2>;
  770. remote-endpoint = <&tcon_tv_in_tcon_top_mixer0>;
  771. };
  772. };
  773. tcon_top_hdmi_in: port@4 {
  774. #address-cells = <1>;
  775. #size-cells = <0>;
  776. reg = <4>;
  777. tcon_top_hdmi_in_tcon_tv: endpoint@0 {
  778. reg = <0>;
  779. remote-endpoint = <&tcon_tv_out_tcon_top>;
  780. };
  781. };
  782. tcon_top_hdmi_out: port@5 {
  783. reg = <5>;
  784. tcon_top_hdmi_out_hdmi: endpoint {
  785. remote-endpoint = <&hdmi_in_tcon_top>;
  786. };
  787. };
  788. };
  789. };
  790. tcon_tv: lcd-controller@6515000 {
  791. compatible = "allwinner,sun50i-h6-tcon-tv",
  792. "allwinner,sun8i-r40-tcon-tv";
  793. reg = <0x06515000 0x1000>;
  794. interrupts = <GIC_SPI 66 IRQ_TYPE_LEVEL_HIGH>;
  795. clocks = <&ccu CLK_BUS_TCON_TV0>,
  796. <&tcon_top CLK_TCON_TOP_TV0>;
  797. clock-names = "ahb",
  798. "tcon-ch1";
  799. resets = <&ccu RST_BUS_TCON_TV0>;
  800. reset-names = "lcd";
  801. ports {
  802. #address-cells = <1>;
  803. #size-cells = <0>;
  804. tcon_tv_in: port@0 {
  805. reg = <0>;
  806. tcon_tv_in_tcon_top_mixer0: endpoint {
  807. remote-endpoint = <&tcon_top_mixer0_out_tcon_tv>;
  808. };
  809. };
  810. tcon_tv_out: port@1 {
  811. #address-cells = <1>;
  812. #size-cells = <0>;
  813. reg = <1>;
  814. tcon_tv_out_tcon_top: endpoint@1 {
  815. reg = <1>;
  816. remote-endpoint = <&tcon_top_hdmi_in_tcon_tv>;
  817. };
  818. };
  819. };
  820. };
  821. rtc: rtc@7000000 {
  822. compatible = "allwinner,sun50i-h6-rtc";
  823. reg = <0x07000000 0x400>;
  824. interrupt-parent = <&r_intc>;
  825. interrupts = <GIC_SPI 101 IRQ_TYPE_LEVEL_HIGH>,
  826. <GIC_SPI 102 IRQ_TYPE_LEVEL_HIGH>;
  827. clock-output-names = "osc32k", "osc32k-out", "iosc";
  828. #clock-cells = <1>;
  829. };
  830. r_ccu: clock@7010000 {
  831. compatible = "allwinner,sun50i-h6-r-ccu";
  832. reg = <0x07010000 0x400>;
  833. clocks = <&osc24M>, <&rtc CLK_OSC32K>, <&rtc CLK_IOSC>,
  834. <&ccu CLK_PLL_PERIPH0>;
  835. clock-names = "hosc", "losc", "iosc", "pll-periph";
  836. #clock-cells = <1>;
  837. #reset-cells = <1>;
  838. };
  839. r_watchdog: watchdog@7020400 {
  840. compatible = "allwinner,sun50i-h6-wdt",
  841. "allwinner,sun6i-a31-wdt";
  842. reg = <0x07020400 0x20>;
  843. interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_HIGH>;
  844. clocks = <&osc24M>;
  845. };
  846. r_intc: interrupt-controller@7021000 {
  847. compatible = "allwinner,sun50i-h6-r-intc";
  848. interrupt-controller;
  849. #interrupt-cells = <3>;
  850. reg = <0x07021000 0x400>;
  851. interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>;
  852. };
  853. r_pio: pinctrl@7022000 {
  854. compatible = "allwinner,sun50i-h6-r-pinctrl";
  855. reg = <0x07022000 0x400>;
  856. interrupt-parent = <&r_intc>;
  857. interrupts = <GIC_SPI 105 IRQ_TYPE_LEVEL_HIGH>,
  858. <GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH>;
  859. clocks = <&r_ccu CLK_R_APB1>, <&osc24M>,
  860. <&rtc CLK_OSC32K>;
  861. clock-names = "apb", "hosc", "losc";
  862. gpio-controller;
  863. #gpio-cells = <3>;
  864. interrupt-controller;
  865. #interrupt-cells = <3>;
  866. r_i2c_pins: r-i2c-pins {
  867. pins = "PL0", "PL1";
  868. function = "s_i2c";
  869. };
  870. r_ir_rx_pin: r-ir-rx-pin {
  871. pins = "PL9";
  872. function = "s_cir_rx";
  873. };
  874. r_rsb_pins: r-rsb-pins {
  875. pins = "PL0", "PL1";
  876. function = "s_rsb";
  877. };
  878. };
  879. r_ir: ir@7040000 {
  880. compatible = "allwinner,sun50i-h6-ir",
  881. "allwinner,sun6i-a31-ir";
  882. reg = <0x07040000 0x400>;
  883. interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>;
  884. clocks = <&r_ccu CLK_R_APB1_IR>,
  885. <&r_ccu CLK_IR>;
  886. clock-names = "apb", "ir";
  887. resets = <&r_ccu RST_R_APB1_IR>;
  888. pinctrl-names = "default";
  889. pinctrl-0 = <&r_ir_rx_pin>;
  890. status = "disabled";
  891. };
  892. r_i2c: i2c@7081400 {
  893. compatible = "allwinner,sun50i-h6-i2c",
  894. "allwinner,sun6i-a31-i2c";
  895. reg = <0x07081400 0x400>;
  896. interrupts = <GIC_SPI 107 IRQ_TYPE_LEVEL_HIGH>;
  897. clocks = <&r_ccu CLK_R_APB2_I2C>;
  898. resets = <&r_ccu RST_R_APB2_I2C>;
  899. pinctrl-names = "default";
  900. pinctrl-0 = <&r_i2c_pins>;
  901. status = "disabled";
  902. #address-cells = <1>;
  903. #size-cells = <0>;
  904. };
  905. r_rsb: rsb@7083000 {
  906. compatible = "allwinner,sun8i-a23-rsb";
  907. reg = <0x07083000 0x400>;
  908. interrupts = <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>;
  909. clocks = <&r_ccu CLK_R_APB2_RSB>;
  910. clock-frequency = <3000000>;
  911. resets = <&r_ccu RST_R_APB2_RSB>;
  912. pinctrl-names = "default";
  913. pinctrl-0 = <&r_rsb_pins>;
  914. status = "disabled";
  915. #address-cells = <1>;
  916. #size-cells = <0>;
  917. };
  918. ths: thermal-sensor@5070400 {
  919. compatible = "allwinner,sun50i-h6-ths";
  920. reg = <0x05070400 0x100>;
  921. interrupts = <GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>;
  922. clocks = <&ccu CLK_BUS_THS>;
  923. clock-names = "bus";
  924. resets = <&ccu RST_BUS_THS>;
  925. nvmem-cells = <&ths_calibration>;
  926. nvmem-cell-names = "calibration";
  927. #thermal-sensor-cells = <1>;
  928. };
  929. };
  930. thermal-zones {
  931. cpu-thermal {
  932. polling-delay-passive = <0>;
  933. polling-delay = <0>;
  934. thermal-sensors = <&ths 0>;
  935. trips {
  936. cpu_alert: cpu-alert {
  937. temperature = <85000>;
  938. hysteresis = <2000>;
  939. type = "passive";
  940. };
  941. cpu-crit {
  942. temperature = <100000>;
  943. hysteresis = <0>;
  944. type = "critical";
  945. };
  946. };
  947. cooling-maps {
  948. map0 {
  949. trip = <&cpu_alert>;
  950. cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
  951. <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
  952. <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
  953. <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
  954. };
  955. };
  956. };
  957. gpu-thermal {
  958. polling-delay-passive = <1000>;
  959. polling-delay = <2000>;
  960. thermal-sensors = <&ths 1>;
  961. trips {
  962. gpu_alert0: gpu-alert-0 {
  963. temperature = <95000>;
  964. hysteresis = <2000>;
  965. type = "passive";
  966. };
  967. gpu_alert1: gpu-alert-1 {
  968. temperature = <100000>;
  969. hysteresis = <2000>;
  970. type = "passive";
  971. };
  972. gpu_alert2: gpu-alert-2 {
  973. temperature = <105000>;
  974. hysteresis = <2000>;
  975. type = "passive";
  976. };
  977. gpu-crit {
  978. temperature = <115000>;
  979. hysteresis = <0>;
  980. type = "critical";
  981. };
  982. };
  983. cooling-maps {
  984. // Forbid the GPU to go over 756MHz
  985. map0 {
  986. trip = <&gpu_alert0>;
  987. cooling-device = <&gpu 1 THERMAL_NO_LIMIT>;
  988. };
  989. // Forbid the GPU to go over 624MHz
  990. map1 {
  991. trip = <&gpu_alert1>;
  992. cooling-device = <&gpu 2 THERMAL_NO_LIMIT>;
  993. };
  994. // Forbid the GPU to go over 576MHz
  995. map2 {
  996. trip = <&gpu_alert2>;
  997. cooling-device = <&gpu 3 THERMAL_NO_LIMIT>;
  998. };
  999. };
  1000. };
  1001. };
  1002. };