xref: /freebsd-src/sys/contrib/device-tree/src/arm/ti/keystone/keystone-k2l-netcp.dtsi (revision 01950c46b8155250f64374fb72fc11faa44bf099)
1f126890aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0
2f126890aSEmmanuel Vadot/*
3f126890aSEmmanuel Vadot * Device Tree Source for Keystone 2 Lamarr Netcp driver
4f126890aSEmmanuel Vadot *
5*01950c46SEmmanuel Vadot * Copyright (C) 2015-2017 Texas Instruments Incorporated - https://www.ti.com/
6f126890aSEmmanuel Vadot */
7f126890aSEmmanuel Vadot
8f126890aSEmmanuel Vadotqmss: qmss@2a40000 {
9f126890aSEmmanuel Vadot	compatible = "ti,keystone-navigator-qmss";
10f126890aSEmmanuel Vadot	dma-coherent;
11f126890aSEmmanuel Vadot	#address-cells = <1>;
12f126890aSEmmanuel Vadot	#size-cells = <1>;
13f126890aSEmmanuel Vadot	clocks = <&chipclk13>;
14f126890aSEmmanuel Vadot	ranges;
15f126890aSEmmanuel Vadot	queue-range = <0 0x2000>;
16f126890aSEmmanuel Vadot	linkram0 = <0x100000 0x4000>;
17f126890aSEmmanuel Vadot	linkram1 = <0x70000000 0x10000>; /* 1MB OSR mem */
18f126890aSEmmanuel Vadot
19f126890aSEmmanuel Vadot	qmgrs {
20f126890aSEmmanuel Vadot		#address-cells = <1>;
21f126890aSEmmanuel Vadot		#size-cells = <1>;
22f126890aSEmmanuel Vadot		ranges;
23f126890aSEmmanuel Vadot		qmgr0 {
24f126890aSEmmanuel Vadot			managed-queues = <0 0x2000>;
25f126890aSEmmanuel Vadot			reg = <0x2a40000 0x20000>,
26f126890aSEmmanuel Vadot			      <0x2a06000 0x400>,
27f126890aSEmmanuel Vadot			      <0x2a02000 0x1000>,
28f126890aSEmmanuel Vadot			      <0x2a03000 0x1000>,
29f126890aSEmmanuel Vadot			      <0x23a80000 0x20000>,
30f126890aSEmmanuel Vadot			      <0x2a80000 0x20000>;
31f126890aSEmmanuel Vadot			reg-names = "peek", "status", "config",
32f126890aSEmmanuel Vadot				    "region", "push", "pop";
33f126890aSEmmanuel Vadot		};
34f126890aSEmmanuel Vadot	};
35f126890aSEmmanuel Vadot	queue-pools {
36f126890aSEmmanuel Vadot		qpend {
37f126890aSEmmanuel Vadot			qpend-0 {
38f126890aSEmmanuel Vadot				qrange = <658 8>;
39f126890aSEmmanuel Vadot				interrupts = <0 40 0xf04 0 41 0xf04 0 42 0xf04
40f126890aSEmmanuel Vadot					      0 43 0xf04 0 44 0xf04 0 45 0xf04
41f126890aSEmmanuel Vadot					      0 46 0xf04 0 47 0xf04>;
42f126890aSEmmanuel Vadot			};
43f126890aSEmmanuel Vadot			qpend-1 {
44f126890aSEmmanuel Vadot				qrange = <528 16>;
45f126890aSEmmanuel Vadot				interrupts = <0 48 0xf04 0 49 0xf04 0 50 0xf04
46f126890aSEmmanuel Vadot					      0 51 0xf04 0 52 0xf04 0 53 0xf04
47f126890aSEmmanuel Vadot					      0 54 0xf04 0 55 0xf04 0 56 0xf04
48f126890aSEmmanuel Vadot					      0 57 0xf04 0 58 0xf04 0 59 0xf04
49f126890aSEmmanuel Vadot					      0 60 0xf04 0 61 0xf04 0 62 0xf04
50f126890aSEmmanuel Vadot					      0 63 0xf04>;
51f126890aSEmmanuel Vadot				qalloc-by-id;
52f126890aSEmmanuel Vadot			};
53f126890aSEmmanuel Vadot			qpend-2 {
54f126890aSEmmanuel Vadot				qrange = <544 16>;
55f126890aSEmmanuel Vadot				interrupts = <0 64 0xf04 0 65 0xf04 0 66 0xf04
56f126890aSEmmanuel Vadot					      0 59 0xf04 0 68 0xf04 0 69 0xf04
57f126890aSEmmanuel Vadot					      0 70 0xf04 0 71 0xf04 0 72 0xf04
58f126890aSEmmanuel Vadot					      0 73 0xf04 0 74 0xf04 0 75 0xf04
59f126890aSEmmanuel Vadot					      0 76 0xf04 0 77 0xf04 0 78 0xf04
60f126890aSEmmanuel Vadot					      0 79 0xf04>;
61f126890aSEmmanuel Vadot			};
62f126890aSEmmanuel Vadot		};
63f126890aSEmmanuel Vadot		general-purpose {
64f126890aSEmmanuel Vadot			gp-0 {
65f126890aSEmmanuel Vadot				qrange = <4000 64>;
66f126890aSEmmanuel Vadot			};
67f126890aSEmmanuel Vadot			netcp-tx {
68f126890aSEmmanuel Vadot				qrange = <896 128>;
69f126890aSEmmanuel Vadot				qalloc-by-id;
70f126890aSEmmanuel Vadot			};
71f126890aSEmmanuel Vadot		};
72f126890aSEmmanuel Vadot		accumulator {
73f126890aSEmmanuel Vadot			acc-low-0 {
74f126890aSEmmanuel Vadot				qrange = <480 32>;
75f126890aSEmmanuel Vadot				accumulator = <0 47 16 2 50>;
76f126890aSEmmanuel Vadot				interrupts = <0 226 0xf01>;
77f126890aSEmmanuel Vadot				multi-queue;
78f126890aSEmmanuel Vadot			};
79f126890aSEmmanuel Vadot		};
80f126890aSEmmanuel Vadot	};
81f126890aSEmmanuel Vadot
82f126890aSEmmanuel Vadot	descriptor-regions {
83f126890aSEmmanuel Vadot		#address-cells = <1>;
84f126890aSEmmanuel Vadot		#size-cells = <1>;
85f126890aSEmmanuel Vadot		ranges;
86f126890aSEmmanuel Vadot		region-12 {
87f126890aSEmmanuel Vadot			id = <12>;
88f126890aSEmmanuel Vadot			region-spec = <8192 128>;	/* num_desc desc_size */
89f126890aSEmmanuel Vadot			link-index = <0x4000>;
90f126890aSEmmanuel Vadot		};
91f126890aSEmmanuel Vadot	};
92f126890aSEmmanuel Vadot
93f126890aSEmmanuel Vadot	pdsps {
94f126890aSEmmanuel Vadot		#address-cells = <1>;
95f126890aSEmmanuel Vadot		#size-cells = <1>;
96f126890aSEmmanuel Vadot		ranges;
97f126890aSEmmanuel Vadot		pdsp0@2a10000 {
98f126890aSEmmanuel Vadot			reg = <0x2a10000 0x1000    /*iram */
99f126890aSEmmanuel Vadot			       0x2a0f000 0x100     /*reg*/
100f126890aSEmmanuel Vadot			       0x2a0c000 0x3c8	   /*intd */
101f126890aSEmmanuel Vadot			       0x2a20000 0x4000>;  /*cmd*/
102f126890aSEmmanuel Vadot			id = <0>;
103f126890aSEmmanuel Vadot		};
104f126890aSEmmanuel Vadot	};
105f126890aSEmmanuel Vadot
106f126890aSEmmanuel Vadot}; /* qmss */
107f126890aSEmmanuel Vadot
108f126890aSEmmanuel Vadotknav_dmas: knav_dmas@0 {
109f126890aSEmmanuel Vadot	compatible = "ti,keystone-navigator-dma";
110f126890aSEmmanuel Vadot	clocks = <&papllclk>;
111f126890aSEmmanuel Vadot	#address-cells = <1>;
112f126890aSEmmanuel Vadot	#size-cells = <1>;
113f126890aSEmmanuel Vadot	ranges;
114f126890aSEmmanuel Vadot	ti,navigator-cloud-address = <0x23a80000 0x23a90000>;
115f126890aSEmmanuel Vadot
116f126890aSEmmanuel Vadot	dma_gbe: dma_gbe@0 {
117f126890aSEmmanuel Vadot		reg = <0x26186000 0x100>,
118f126890aSEmmanuel Vadot			  <0x26187000 0x2a0>,
119f126890aSEmmanuel Vadot			  <0x26188000 0xb60>,
120f126890aSEmmanuel Vadot			  <0x26186100 0x80>,
121f126890aSEmmanuel Vadot			  <0x26189000 0x1000>;
122f126890aSEmmanuel Vadot		reg-names = "global", "txchan", "rxchan",
123f126890aSEmmanuel Vadot				"txsched", "rxflow";
124f126890aSEmmanuel Vadot	};
125f126890aSEmmanuel Vadot};
126f126890aSEmmanuel Vadot
127f126890aSEmmanuel Vadotnetcp: netcp@26000000 {
128f126890aSEmmanuel Vadot	reg = <0x2620110 0x8>;
129f126890aSEmmanuel Vadot	reg-names = "efuse";
130f126890aSEmmanuel Vadot	compatible = "ti,netcp-1.0";
131f126890aSEmmanuel Vadot	#address-cells = <1>;
132f126890aSEmmanuel Vadot	#size-cells = <1>;
133f126890aSEmmanuel Vadot
134f126890aSEmmanuel Vadot	/* NetCP address range */
135f126890aSEmmanuel Vadot	ranges = <0 0x26000000 0x1000000>;
136f126890aSEmmanuel Vadot
137f126890aSEmmanuel Vadot	clocks = <&clkpa>, <&clkcpgmac>;
138f126890aSEmmanuel Vadot	clock-names = "pa_clk", "ethss_clk";
139f126890aSEmmanuel Vadot	dma-coherent;
140f126890aSEmmanuel Vadot
141f126890aSEmmanuel Vadot	ti,navigator-dmas = <&dma_gbe 0>,
142f126890aSEmmanuel Vadot			<&dma_gbe 8>,
143f126890aSEmmanuel Vadot			<&dma_gbe 0>;
144f126890aSEmmanuel Vadot	ti,navigator-dma-names = "netrx0", "netrx1", "nettx";
145f126890aSEmmanuel Vadot
146f126890aSEmmanuel Vadot	netcp-devices {
147f126890aSEmmanuel Vadot		#address-cells = <1>;
148f126890aSEmmanuel Vadot		#size-cells = <1>;
149f126890aSEmmanuel Vadot		ranges;
150f126890aSEmmanuel Vadot		gbe@200000 { /* ETHSS */
151f126890aSEmmanuel Vadot			label = "netcp-gbe";
152f126890aSEmmanuel Vadot			compatible = "ti,netcp-gbe-5";
153f126890aSEmmanuel Vadot			reg = <0x200000 0x900>, <0x220000 0x20000>;
154f126890aSEmmanuel Vadot			/* enable-ale; */
155f126890aSEmmanuel Vadot			tx-queue = <896>;
156f126890aSEmmanuel Vadot			tx-channel = "nettx";
157f126890aSEmmanuel Vadot
158f126890aSEmmanuel Vadot			cpts {
159f126890aSEmmanuel Vadot				clocks = <&cpts_refclk_mux>;
160f126890aSEmmanuel Vadot				clock-names = "cpts";
161f126890aSEmmanuel Vadot
162f126890aSEmmanuel Vadot				cpts_refclk_mux: cpts-refclk-mux {
163f126890aSEmmanuel Vadot					#clock-cells = <0>;
164f126890aSEmmanuel Vadot					clocks = <&chipclk12>, <&chipclk13>,
165f126890aSEmmanuel Vadot						 <&timi0>, <&timi1>,
166f126890aSEmmanuel Vadot						 <&tsrefclk>;
167f126890aSEmmanuel Vadot					ti,mux-tbl = <0x0>, <0x1>, <0x2>,
168f126890aSEmmanuel Vadot						<0x3>, <0x8>;
169f126890aSEmmanuel Vadot					assigned-clocks = <&cpts_refclk_mux>;
170f126890aSEmmanuel Vadot					assigned-clock-parents = <&chipclk12>;
171f126890aSEmmanuel Vadot				};
172f126890aSEmmanuel Vadot			};
173f126890aSEmmanuel Vadot
174f126890aSEmmanuel Vadot			interfaces {
175f126890aSEmmanuel Vadot				gbe0: interface-0 {
176f126890aSEmmanuel Vadot					slave-port = <0>;
177f126890aSEmmanuel Vadot					link-interface = <1>;
178f126890aSEmmanuel Vadot					phy-handle = <&ethphy0>;
179f126890aSEmmanuel Vadot				};
180f126890aSEmmanuel Vadot				gbe1: interface-1 {
181f126890aSEmmanuel Vadot					slave-port = <1>;
182f126890aSEmmanuel Vadot					link-interface = <1>;
183f126890aSEmmanuel Vadot					phy-handle = <&ethphy1>;
184f126890aSEmmanuel Vadot				};
185f126890aSEmmanuel Vadot			};
186f126890aSEmmanuel Vadot
187f126890aSEmmanuel Vadot			secondary-slave-ports {
188f126890aSEmmanuel Vadot				port-2 {
189f126890aSEmmanuel Vadot					slave-port = <2>;
190f126890aSEmmanuel Vadot					link-interface = <2>;
191f126890aSEmmanuel Vadot				};
192f126890aSEmmanuel Vadot				port-3 {
193f126890aSEmmanuel Vadot					slave-port = <3>;
194f126890aSEmmanuel Vadot					link-interface = <2>;
195f126890aSEmmanuel Vadot				};
196f126890aSEmmanuel Vadot			};
197f126890aSEmmanuel Vadot		};
198f126890aSEmmanuel Vadot	};
199f126890aSEmmanuel Vadot
200f126890aSEmmanuel Vadot	netcp-interfaces {
201f126890aSEmmanuel Vadot		interface-0 {
202f126890aSEmmanuel Vadot			rx-channel = "netrx0";
203f126890aSEmmanuel Vadot			rx-pool = <1024 12>;
204f126890aSEmmanuel Vadot			tx-pool = <1024 12>;
205f126890aSEmmanuel Vadot			rx-queue-depth = <128 128 0 0>;
206f126890aSEmmanuel Vadot			rx-buffer-size = <1518 4096 0 0>;
207f126890aSEmmanuel Vadot			rx-queue = <528>;
208f126890aSEmmanuel Vadot			tx-completion-queue = <530>;
209f126890aSEmmanuel Vadot			efuse-mac = <1>;
210f126890aSEmmanuel Vadot			netcp-gbe = <&gbe0>;
211f126890aSEmmanuel Vadot
212f126890aSEmmanuel Vadot		};
213f126890aSEmmanuel Vadot		interface-1 {
214f126890aSEmmanuel Vadot			rx-channel = "netrx1";
215f126890aSEmmanuel Vadot			rx-pool = <1024 12>;
216f126890aSEmmanuel Vadot			tx-pool = <1024 12>;
217f126890aSEmmanuel Vadot			rx-queue-depth = <128 128 0 0>;
218f126890aSEmmanuel Vadot			rx-buffer-size = <1518 4096 0 0>;
219f126890aSEmmanuel Vadot			rx-queue = <529>;
220f126890aSEmmanuel Vadot			tx-completion-queue = <531>;
221f126890aSEmmanuel Vadot			efuse-mac = <0>;
222f126890aSEmmanuel Vadot			local-mac-address = [02 18 31 7e 3e 7f];
223f126890aSEmmanuel Vadot			netcp-gbe = <&gbe1>;
224f126890aSEmmanuel Vadot		};
225f126890aSEmmanuel Vadot	};
226f126890aSEmmanuel Vadot};
227f126890aSEmmanuel Vadot
228f126890aSEmmanuel Vadotsa_subsys: subsys@26080000 {
229f126890aSEmmanuel Vadot	#address-cells = <1>;
230f126890aSEmmanuel Vadot	#size-cells = <1>;
231f126890aSEmmanuel Vadot	compatible = "simple-bus";
232f126890aSEmmanuel Vadot	ranges = <0 0x26080000 0x40000>;
233f126890aSEmmanuel Vadot
234f126890aSEmmanuel Vadot	sa_config: subsys@0 {
235f126890aSEmmanuel Vadot		compatible = "syscon";
236f126890aSEmmanuel Vadot		reg = <0x0 0x100>;
237f126890aSEmmanuel Vadot	};
238f126890aSEmmanuel Vadot
239f126890aSEmmanuel Vadot	rng@24000 {
240f126890aSEmmanuel Vadot		compatible = "ti,keystone-rng";
241f126890aSEmmanuel Vadot		reg = <0x24000 0x1000>;
242f126890aSEmmanuel Vadot		ti,syscon-sa-cfg = <&sa_config>;
243f126890aSEmmanuel Vadot		clocks = <&clksa>;
244f126890aSEmmanuel Vadot		clock-names = "fck";
245f126890aSEmmanuel Vadot	};
246f126890aSEmmanuel Vadot};
247