12d87061eSNishanth Menon// SPDX-License-Identifier: GPL-2.0
22d87061eSNishanth Menon/*
32d87061eSNishanth Menon * Device Tree Source for J721E SoC Family
42d87061eSNishanth Menon *
5303d6f62SAlexander A. Klimov * Copyright (C) 2016-2019 Texas Instruments Incorporated - https://www.ti.com/
62d87061eSNishanth Menon */
72d87061eSNishanth Menon
82d87061eSNishanth Menon#include <dt-bindings/interrupt-controller/irq.h>
92d87061eSNishanth Menon#include <dt-bindings/interrupt-controller/arm-gic.h>
10bf146a1aSLokesh Vutla#include <dt-bindings/soc/ti,sci_pm_domain.h>
112d87061eSNishanth Menon
12fe49f2d7SNishanth Menon#include "k3-pinctrl.h"
13fe49f2d7SNishanth Menon
142d87061eSNishanth Menon/ {
152d87061eSNishanth Menon	model = "Texas Instruments K3 J721E SoC";
162d87061eSNishanth Menon	compatible = "ti,j721e";
172d87061eSNishanth Menon	interrupt-parent = <&gic500>;
182d87061eSNishanth Menon	#address-cells = <2>;
192d87061eSNishanth Menon	#size-cells = <2>;
202d87061eSNishanth Menon
212d87061eSNishanth Menon	aliases {
222d87061eSNishanth Menon		serial0 = &wkup_uart0;
232d87061eSNishanth Menon		serial1 = &mcu_uart0;
242d87061eSNishanth Menon		serial2 = &main_uart0;
252d87061eSNishanth Menon		serial3 = &main_uart1;
262d87061eSNishanth Menon		serial4 = &main_uart2;
272d87061eSNishanth Menon		serial5 = &main_uart3;
282d87061eSNishanth Menon		serial6 = &main_uart4;
292d87061eSNishanth Menon		serial7 = &main_uart5;
302d87061eSNishanth Menon		serial8 = &main_uart6;
312d87061eSNishanth Menon		serial9 = &main_uart7;
322d87061eSNishanth Menon		serial10 = &main_uart8;
332d87061eSNishanth Menon		serial11 = &main_uart9;
34ae7fdac8SGrygorii Strashko		ethernet0 = &cpsw_port1;
35f54e1a97SNishanth Menon		mmc0 = &main_sdhci0;
36f54e1a97SNishanth Menon		mmc1 = &main_sdhci1;
37f54e1a97SNishanth Menon		mmc2 = &main_sdhci2;
382d87061eSNishanth Menon	};
392d87061eSNishanth Menon
402d87061eSNishanth Menon	chosen { };
412d87061eSNishanth Menon
422d87061eSNishanth Menon	cpus {
432d87061eSNishanth Menon		#address-cells = <1>;
442d87061eSNishanth Menon		#size-cells = <0>;
452d87061eSNishanth Menon		cpu-map {
462d87061eSNishanth Menon			cluster0: cluster0 {
472d87061eSNishanth Menon				core0 {
482d87061eSNishanth Menon					cpu = <&cpu0>;
492d87061eSNishanth Menon				};
502d87061eSNishanth Menon
512d87061eSNishanth Menon				core1 {
522d87061eSNishanth Menon					cpu = <&cpu1>;
532d87061eSNishanth Menon				};
542d87061eSNishanth Menon			};
552d87061eSNishanth Menon
562d87061eSNishanth Menon		};
572d87061eSNishanth Menon
582d87061eSNishanth Menon		cpu0: cpu@0 {
592d87061eSNishanth Menon			compatible = "arm,cortex-a72";
602d87061eSNishanth Menon			reg = <0x000>;
612d87061eSNishanth Menon			device_type = "cpu";
622d87061eSNishanth Menon			enable-method = "psci";
632d87061eSNishanth Menon			i-cache-size = <0xC000>;
642d87061eSNishanth Menon			i-cache-line-size = <64>;
652d87061eSNishanth Menon			i-cache-sets = <256>;
662d87061eSNishanth Menon			d-cache-size = <0x8000>;
672d87061eSNishanth Menon			d-cache-line-size = <64>;
687a0df1f9SPeng Fan			d-cache-sets = <256>;
692d87061eSNishanth Menon			next-level-cache = <&L2_0>;
702d87061eSNishanth Menon		};
712d87061eSNishanth Menon
722d87061eSNishanth Menon		cpu1: cpu@1 {
732d87061eSNishanth Menon			compatible = "arm,cortex-a72";
742d87061eSNishanth Menon			reg = <0x001>;
752d87061eSNishanth Menon			device_type = "cpu";
762d87061eSNishanth Menon			enable-method = "psci";
772d87061eSNishanth Menon			i-cache-size = <0xC000>;
782d87061eSNishanth Menon			i-cache-line-size = <64>;
792d87061eSNishanth Menon			i-cache-sets = <256>;
802d87061eSNishanth Menon			d-cache-size = <0x8000>;
812d87061eSNishanth Menon			d-cache-line-size = <64>;
827a0df1f9SPeng Fan			d-cache-sets = <256>;
832d87061eSNishanth Menon			next-level-cache = <&L2_0>;
842d87061eSNishanth Menon		};
852d87061eSNishanth Menon	};
862d87061eSNishanth Menon
872d87061eSNishanth Menon	L2_0: l2-cache0 {
882d87061eSNishanth Menon		compatible = "cache";
892d87061eSNishanth Menon		cache-level = <2>;
90880932e6SPierre Gondois		cache-unified;
912d87061eSNishanth Menon		cache-size = <0x100000>;
922d87061eSNishanth Menon		cache-line-size = <64>;
93e9ba3a5bSNishanth Menon		cache-sets = <1024>;
942d87061eSNishanth Menon		next-level-cache = <&msmc_l3>;
952d87061eSNishanth Menon	};
962d87061eSNishanth Menon
972d87061eSNishanth Menon	msmc_l3: l3-cache0 {
982d87061eSNishanth Menon		compatible = "cache";
992d87061eSNishanth Menon		cache-level = <3>;
1002d87061eSNishanth Menon	};
1012d87061eSNishanth Menon
1022d87061eSNishanth Menon	firmware {
1032d87061eSNishanth Menon		optee {
1042d87061eSNishanth Menon			compatible = "linaro,optee-tz";
1052d87061eSNishanth Menon			method = "smc";
1062d87061eSNishanth Menon		};
1072d87061eSNishanth Menon
1082d87061eSNishanth Menon		psci: psci {
1092d87061eSNishanth Menon			compatible = "arm,psci-1.0";
1102d87061eSNishanth Menon			method = "smc";
1112d87061eSNishanth Menon		};
1122d87061eSNishanth Menon	};
1132d87061eSNishanth Menon
1142d87061eSNishanth Menon	a72_timer0: timer-cl0-cpu0 {
1152d87061eSNishanth Menon		compatible = "arm,armv8-timer";
1162d87061eSNishanth Menon		interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_LOW>, /* cntpsirq */
1172d87061eSNishanth Menon			     <GIC_PPI 14 IRQ_TYPE_LEVEL_LOW>, /* cntpnsirq */
1182d87061eSNishanth Menon			     <GIC_PPI 11 IRQ_TYPE_LEVEL_LOW>, /* cntvirq */
1192d87061eSNishanth Menon			     <GIC_PPI 10 IRQ_TYPE_LEVEL_LOW>; /* cnthpirq */
1202d87061eSNishanth Menon	};
1212d87061eSNishanth Menon
1222d87061eSNishanth Menon	pmu: pmu {
123ae10ce93SNishanth Menon		compatible = "arm,cortex-a72-pmu";
1242d87061eSNishanth Menon		/* Recommendation from GIC500 TRM Table A.3 */
1252d87061eSNishanth Menon		interrupts = <GIC_PPI 7 IRQ_TYPE_LEVEL_HIGH>;
1262d87061eSNishanth Menon	};
1272d87061eSNishanth Menon
128995504b6SSuman Anna	cbass_main: bus@100000 {
1292d87061eSNishanth Menon		compatible = "simple-bus";
1302d87061eSNishanth Menon		#address-cells = <2>;
1312d87061eSNishanth Menon		#size-cells = <2>;
1322d87061eSNishanth Menon		ranges = <0x00 0x00100000 0x00 0x00100000 0x00 0x00020000>, /* ctrl mmr */
1332d87061eSNishanth Menon			 <0x00 0x00600000 0x00 0x00600000 0x00 0x00031100>, /* GPIO */
1342d87061eSNishanth Menon			 <0x00 0x00900000 0x00 0x00900000 0x00 0x00012000>, /* serdes */
1351aedefe1SNishanth Menon			 <0x00 0x00a40000 0x00 0x00a40000 0x00 0x00000800>, /* timesync router */
136451555c8SRoger Quadros			 <0x00 0x06000000 0x00 0x06000000 0x00 0x00400000>, /* USBSS0 */
137451555c8SRoger Quadros			 <0x00 0x06400000 0x00 0x06400000 0x00 0x00400000>, /* USBSS1 */
1382d87061eSNishanth Menon			 <0x00 0x01000000 0x00 0x01000000 0x00 0x0af02400>, /* Most peripherals */
139*a2ff7f11SSiddharth Vadapalli			 <0x00 0x0c000000 0x00 0x0c000000 0x00 0x0d000000>, /* CPSW9G */
1408c0deacaSPeter Ujfalusi			 <0x00 0x30000000 0x00 0x30000000 0x00 0x0c400000>, /* MAIN NAVSS */
1414e583388SKishon Vijay Abraham I			 <0x00 0x0d000000 0x00 0x0d000000 0x00 0x01800000>, /* PCIe Core*/
1424e583388SKishon Vijay Abraham I			 <0x00 0x0e000000 0x00 0x0e000000 0x00 0x01800000>, /* PCIe Core*/
1432d87061eSNishanth Menon			 <0x00 0x10000000 0x00 0x10000000 0x00 0x10000000>, /* PCIe DAT */
1442d87061eSNishanth Menon			 <0x00 0x64800000 0x00 0x64800000 0x00 0x00800000>, /* C71 */
145a06ed27fSNishanth Menon			 <0x00 0x6f000000 0x00 0x6f000000 0x00 0x00310000>, /* A72 PERIPHBASE */
1464e583388SKishon Vijay Abraham I			 <0x44 0x00000000 0x44 0x00000000 0x00 0x08000000>, /* PCIe2 DAT */
1474e583388SKishon Vijay Abraham I			 <0x44 0x10000000 0x44 0x10000000 0x00 0x08000000>, /* PCIe3 DAT */
1482d87061eSNishanth Menon			 <0x4d 0x80800000 0x4d 0x80800000 0x00 0x00800000>, /* C66_0 */
1492d87061eSNishanth Menon			 <0x4d 0x81800000 0x4d 0x81800000 0x00 0x00800000>, /* C66_1 */
1502d87061eSNishanth Menon			 <0x4e 0x20000000 0x4e 0x20000000 0x00 0x00080000>, /* GPU */
1512d87061eSNishanth Menon			 <0x00 0x70000000 0x00 0x70000000 0x00 0x00800000>, /* MSMC RAM */
1522d87061eSNishanth Menon
1532d87061eSNishanth Menon			 /* MCUSS_WKUP Range */
1542d87061eSNishanth Menon			 <0x00 0x28380000 0x00 0x28380000 0x00 0x03880000>,
1552d87061eSNishanth Menon			 <0x00 0x40200000 0x00 0x40200000 0x00 0x00998400>,
1562d87061eSNishanth Menon			 <0x00 0x40f00000 0x00 0x40f00000 0x00 0x00020000>,
1572d87061eSNishanth Menon			 <0x00 0x41000000 0x00 0x41000000 0x00 0x00020000>,
1582d87061eSNishanth Menon			 <0x00 0x41400000 0x00 0x41400000 0x00 0x00020000>,
1592d87061eSNishanth Menon			 <0x00 0x41c00000 0x00 0x41c00000 0x00 0x00100000>,
1602d87061eSNishanth Menon			 <0x00 0x42040000 0x00 0x42040000 0x00 0x03ac2400>,
1612d87061eSNishanth Menon			 <0x00 0x45100000 0x00 0x45100000 0x00 0x00c24000>,
1622d87061eSNishanth Menon			 <0x00 0x46000000 0x00 0x46000000 0x00 0x00200000>,
1632d87061eSNishanth Menon			 <0x00 0x47000000 0x00 0x47000000 0x00 0x00068400>,
1642d87061eSNishanth Menon			 <0x00 0x50000000 0x00 0x50000000 0x00 0x10000000>,
1652d87061eSNishanth Menon			 <0x05 0x00000000 0x05 0x00000000 0x01 0x00000000>,
1662d87061eSNishanth Menon			 <0x07 0x00000000 0x07 0x00000000 0x01 0x00000000>;
1672d87061eSNishanth Menon
168995504b6SSuman Anna		cbass_mcu_wakeup: bus@28380000 {
1692d87061eSNishanth Menon			compatible = "simple-bus";
1702d87061eSNishanth Menon			#address-cells = <2>;
1712d87061eSNishanth Menon			#size-cells = <2>;
1722d87061eSNishanth Menon			ranges = <0x00 0x28380000 0x00 0x28380000 0x00 0x03880000>, /* MCU NAVSS*/
1732d87061eSNishanth Menon				 <0x00 0x40200000 0x00 0x40200000 0x00 0x00998400>, /* First peripheral window */
1742d87061eSNishanth Menon				 <0x00 0x40f00000 0x00 0x40f00000 0x00 0x00020000>, /* CTRL_MMR0 */
1752d87061eSNishanth Menon				 <0x00 0x41000000 0x00 0x41000000 0x00 0x00020000>, /* MCU R5F Core0 */
1762d87061eSNishanth Menon				 <0x00 0x41400000 0x00 0x41400000 0x00 0x00020000>, /* MCU R5F Core1 */
1772d87061eSNishanth Menon				 <0x00 0x41c00000 0x00 0x41c00000 0x00 0x00100000>, /* MCU SRAM */
1782d87061eSNishanth Menon				 <0x00 0x42040000 0x00 0x42040000 0x00 0x03ac2400>, /* WKUP peripheral window */
1792d87061eSNishanth Menon				 <0x00 0x45100000 0x00 0x45100000 0x00 0x00c24000>, /* MMRs, remaining NAVSS */
1802d87061eSNishanth Menon				 <0x00 0x46000000 0x00 0x46000000 0x00 0x00200000>, /* CPSW */
1812d87061eSNishanth Menon				 <0x00 0x47000000 0x00 0x47000000 0x00 0x00068400>, /* OSPI register space */
1822d87061eSNishanth Menon				 <0x00 0x50000000 0x00 0x50000000 0x00 0x10000000>, /* FSS OSPI0/1 data region 0 */
1832d87061eSNishanth Menon				 <0x05 0x00000000 0x05 0x00000000 0x01 0x00000000>, /* FSS OSPI0 data region 3 */
1842d87061eSNishanth Menon				 <0x07 0x00000000 0x07 0x00000000 0x01 0x00000000>; /* FSS OSPI1 data region 3*/
1852d87061eSNishanth Menon		};
1862d87061eSNishanth Menon	};
1872d87061eSNishanth Menon};
1882d87061eSNishanth Menon
1892d87061eSNishanth Menon/* Now include the peripherals for each bus segments */
1902d87061eSNishanth Menon#include "k3-j721e-main.dtsi"
1912d87061eSNishanth Menon#include "k3-j721e-mcu-wakeup.dtsi"
192