Merge branch 'pm-cpufreq'
[cascardo/linux.git] / arch / arm / boot / dts / dm816x.dtsi
1 /*
2  * This file is licensed under the terms of the GNU General Public License
3  * version 2.  This program is licensed "as is" without any warranty of any
4  * kind, whether express or implied.
5  */
6
7 #include <dt-bindings/gpio/gpio.h>
8 #include <dt-bindings/pinctrl/omap.h>
9
10 / {
11         compatible = "ti,dm816";
12         interrupt-parent = <&intc>;
13         #address-cells = <1>;
14         #size-cells = <1>;
15
16         aliases {
17                 i2c0 = &i2c1;
18                 i2c1 = &i2c2;
19                 serial0 = &uart1;
20                 serial1 = &uart2;
21                 serial2 = &uart3;
22                 ethernet0 = &eth0;
23                 ethernet1 = &eth1;
24         };
25
26         cpus {
27                 #address-cells = <1>;
28                 #size-cells = <0>;
29                 cpu@0 {
30                         compatible = "arm,cortex-a8";
31                         device_type = "cpu";
32                         reg = <0>;
33                 };
34         };
35
36         pmu {
37                 compatible = "arm,cortex-a8-pmu";
38                 interrupts = <3>;
39         };
40
41         /*
42          * The soc node represents the soc top level view. It is used for IPs
43          * that are not memory mapped in the MPU view or for the MPU itself.
44          */
45         soc {
46                 compatible = "ti,omap-infra";
47                 mpu {
48                         compatible = "ti,omap3-mpu";
49                         ti,hwmods = "mpu";
50                 };
51         };
52
53         /*
54          * XXX: Use a flat representation of the dm816x interconnect.
55          * The real dm816x interconnect network is quite complex. Since
56          * it will not bring real advantage to represent that in DT
57          * for the moment, just use a fake OCP bus entry to represent
58          * the whole bus hierarchy.
59          */
60         ocp {
61                 compatible = "simple-bus";
62                 reg = <0x44000000 0x10000>;
63                 interrupts = <9 10>;
64                 #address-cells = <1>;
65                 #size-cells = <1>;
66                 ranges;
67
68                 prcm: prcm@48180000 {
69                         compatible = "ti,dm816-prcm";
70                         reg = <0x48180000 0x4000>;
71
72                         prcm_clocks: clocks {
73                                 #address-cells = <1>;
74                                 #size-cells = <0>;
75                         };
76
77                         prcm_clockdomains: clockdomains {
78                         };
79                 };
80
81                 scrm: scrm@48140000 {
82                         compatible = "ti,dm816-scrm", "simple-bus";
83                         reg = <0x48140000 0x21000>;
84                         #address-cells = <1>;
85                         #size-cells = <1>;
86                         ranges = <0 0x48140000 0x21000>;
87
88                         dm816x_pinmux: pinmux@800 {
89                                 compatible = "pinctrl-single";
90                                 reg = <0x800 0x50a>;
91                                 #address-cells = <1>;
92                                 #size-cells = <0>;
93                                 pinctrl-single,register-width = <16>;
94                                 pinctrl-single,function-mask = <0xf>;
95                         };
96
97                         /* Device Configuration Registers */
98                         scm_conf: syscon@600 {
99                                 compatible = "syscon", "simple-bus";
100                                 reg = <0x600 0x110>;
101                                 #address-cells = <1>;
102                                 #size-cells = <1>;
103                                 ranges = <0 0x600 0x110>;
104
105                                 usb_phy0: usb-phy@20 {
106                                         compatible = "ti,dm8168-usb-phy";
107                                         reg = <0x20 0x8>;
108                                         reg-names = "phy";
109                                         clocks = <&main_fapll 6>;
110                                         clock-names = "refclk";
111                                         #phy-cells = <0>;
112                                         syscon = <&scm_conf>;
113                                 };
114
115                                 usb_phy1: usb-phy@28 {
116                                         compatible = "ti,dm8168-usb-phy";
117                                         reg = <0x28 0x8>;
118                                         reg-names = "phy";
119                                         clocks = <&main_fapll 6>;
120                                         clock-names = "refclk";
121                                         #phy-cells = <0>;
122                                         syscon = <&scm_conf>;
123                                 };
124                         };
125
126                         scrm_clocks: clocks {
127                                 #address-cells = <1>;
128                                 #size-cells = <0>;
129                         };
130
131                         scrm_clockdomains: clockdomains {
132                         };
133                 };
134
135                 edma: edma@49000000 {
136                         compatible = "ti,edma3";
137                         ti,hwmods = "tpcc", "tptc0", "tptc1", "tptc2", "tptc3";
138                         reg =   <0x49000000 0x10000>,
139                                 <0x44e10f90 0x40>;
140                         interrupts = <12 13 14>;
141                         #dma-cells = <1>;
142                 };
143
144                 elm: elm@48080000 {
145                         compatible = "ti,816-elm";
146                         ti,hwmods = "elm";
147                         reg = <0x48080000 0x2000>;
148                         interrupts = <4>;
149                 };
150
151                 gpio1: gpio@48032000 {
152                         compatible = "ti,omap4-gpio";
153                         ti,hwmods = "gpio1";
154                         ti,gpio-always-on;
155                         reg = <0x48032000 0x1000>;
156                         interrupts = <96>;
157                         gpio-controller;
158                         #gpio-cells = <2>;
159                         interrupt-controller;
160                         #interrupt-cells = <2>;
161                 };
162
163                 gpio2: gpio@4804c000 {
164                         compatible = "ti,omap4-gpio";
165                         ti,hwmods = "gpio2";
166                         ti,gpio-always-on;
167                         reg = <0x4804c000 0x1000>;
168                         interrupts = <98>;
169                         gpio-controller;
170                         #gpio-cells = <2>;
171                         interrupt-controller;
172                         #interrupt-cells = <2>;
173                 };
174
175                 gpmc: gpmc@50000000 {
176                         compatible = "ti,am3352-gpmc";
177                         ti,hwmods = "gpmc";
178                         reg = <0x50000000 0x2000>;
179                         #address-cells = <2>;
180                         #size-cells = <1>;
181                         interrupts = <100>;
182                         dmas = <&edma 52>;
183                         dma-names = "rxtx";
184                         gpmc,num-cs = <6>;
185                         gpmc,num-waitpins = <2>;
186                         interrupt-controller;
187                         #interrupt-cells = <2>;
188                         gpio-controller;
189                         #gpio-cells = <2>;
190                 };
191
192                 i2c1: i2c@48028000 {
193                         compatible = "ti,omap4-i2c";
194                         ti,hwmods = "i2c1";
195                         reg = <0x48028000 0x1000>;
196                         #address-cells = <1>;
197                         #size-cells = <0>;
198                         interrupts = <70>;
199                         dmas = <&edma 58 &edma 59>;
200                         dma-names = "tx", "rx";
201                 };
202
203                 i2c2: i2c@4802a000 {
204                         compatible = "ti,omap4-i2c";
205                         ti,hwmods = "i2c2";
206                         reg = <0x4802a000 0x1000>;
207                         #address-cells = <1>;
208                         #size-cells = <0>;
209                         interrupts = <71>;
210                         dmas = <&edma 60 &edma 61>;
211                         dma-names = "tx", "rx";
212                 };
213
214                 intc: interrupt-controller@48200000 {
215                         compatible = "ti,dm816-intc";
216                         interrupt-controller;
217                         #interrupt-cells = <1>;
218                         reg = <0x48200000 0x1000>;
219                 };
220
221                 rtc: rtc@480c0000 {
222                         compatible = "ti,am3352-rtc", "ti,da830-rtc";
223                         reg = <0x480c0000 0x1000>;
224                         interrupts = <75 76>;
225                         ti,hwmods = "rtc";
226                 };
227
228                 mailbox: mailbox@480c8000 {
229                         compatible = "ti,omap4-mailbox";
230                         reg = <0x480c8000 0x2000>;
231                         interrupts = <77>;
232                         ti,hwmods = "mailbox";
233                         #mbox-cells = <1>;
234                         ti,mbox-num-users = <4>;
235                         ti,mbox-num-fifos = <12>;
236                         mbox_dsp: mbox_dsp {
237                                 ti,mbox-tx = <3 0 0>;
238                                 ti,mbox-rx = <0 0 0>;
239                         };
240                 };
241
242                 spinbox: spinbox@480ca000 {
243                         compatible = "ti,omap4-hwspinlock";
244                         reg = <0x480ca000 0x2000>;
245                         ti,hwmods = "spinbox";
246                         #hwlock-cells = <1>;
247                 };
248
249                 mdio: mdio@4a100800 {
250                         compatible = "ti,davinci_mdio";
251                         #address-cells = <1>;
252                         #size-cells = <0>;
253                         reg = <0x4a100800 0x100>;
254                         ti,hwmods = "davinci_mdio";
255                         bus_freq = <1000000>;
256                         phy0: ethernet-phy@0 {
257                                 reg = <1>;
258                         };
259                         phy1: ethernet-phy@1 {
260                                 reg = <2>;
261                         };
262                 };
263
264                 eth0: ethernet@4a100000 {
265                         compatible = "ti,dm816-emac";
266                         ti,hwmods = "emac0";
267                         reg = <0x4a100000 0x800
268                                0x4a100900 0x3700>;
269                         clocks = <&sysclk24_ck>;
270                         syscon = <&scm_conf>;
271                         ti,davinci-ctrl-reg-offset = <0>;
272                         ti,davinci-ctrl-mod-reg-offset = <0x900>;
273                         ti,davinci-ctrl-ram-offset = <0x2000>;
274                         ti,davinci-ctrl-ram-size = <0x2000>;
275                         interrupts = <40 41 42 43>;
276                         phy-handle = <&phy0>;
277                 };
278
279                 eth1: ethernet@4a120000 {
280                         compatible = "ti,dm816-emac";
281                         ti,hwmods = "emac1";
282                         reg = <0x4a120000 0x4000>;
283                         clocks = <&sysclk24_ck>;
284                         syscon = <&scm_conf>;
285                         ti,davinci-ctrl-reg-offset = <0>;
286                         ti,davinci-ctrl-mod-reg-offset = <0x900>;
287                         ti,davinci-ctrl-ram-offset = <0x2000>;
288                         ti,davinci-ctrl-ram-size = <0x2000>;
289                         interrupts = <44 45 46 47>;
290                         phy-handle = <&phy1>;
291                 };
292
293                 mcspi1: spi@48030000 {
294                         compatible = "ti,omap4-mcspi";
295                         reg = <0x48030000 0x1000>;
296                         #address-cells = <1>;
297                         #size-cells = <0>;
298                         interrupts = <65>;
299                         ti,spi-num-cs = <4>;
300                         ti,hwmods = "mcspi1";
301                         dmas = <&edma 16 &edma 17
302                                 &edma 18 &edma 19
303                                 &edma 20 &edma 21
304                                 &edma 22 &edma 23>;
305                         dma-names = "tx0", "rx0", "tx1", "rx1",
306                                     "tx2", "rx2", "tx3", "rx3";
307                 };
308
309                 mmc1: mmc@48060000 {
310                         compatible = "ti,omap4-hsmmc";
311                         reg = <0x48060000 0x11000>;
312                         ti,hwmods = "mmc1";
313                         interrupts = <64>;
314                         dmas = <&edma 24 &edma 25>;
315                         dma-names = "tx", "rx";
316                 };
317
318                 timer1: timer@4802e000 {
319                         compatible = "ti,dm816-timer";
320                         reg = <0x4802e000 0x2000>;
321                         interrupts = <67>;
322                         ti,hwmods = "timer1";
323                         ti,timer-alwon;
324                 };
325
326                 timer2: timer@48040000 {
327                         compatible = "ti,dm816-timer";
328                         reg = <0x48040000 0x2000>;
329                         interrupts = <68>;
330                         ti,hwmods = "timer2";
331                 };
332
333                 timer3: timer@48042000 {
334                         compatible = "ti,dm816-timer";
335                         reg = <0x48042000 0x2000>;
336                         interrupts = <69>;
337                         ti,hwmods = "timer3";
338                 };
339
340                 timer4: timer@48044000 {
341                         compatible = "ti,dm816-timer";
342                         reg = <0x48044000 0x2000>;
343                         interrupts = <92>;
344                         ti,hwmods = "timer4";
345                         ti,timer-pwm;
346                 };
347
348                 timer5: timer@48046000 {
349                         compatible = "ti,dm816-timer";
350                         reg = <0x48046000 0x2000>;
351                         interrupts = <93>;
352                         ti,hwmods = "timer5";
353                         ti,timer-pwm;
354                 };
355
356                 timer6: timer@48048000 {
357                         compatible = "ti,dm816-timer";
358                         reg = <0x48048000 0x2000>;
359                         interrupts = <94>;
360                         ti,hwmods = "timer6";
361                         ti,timer-pwm;
362                 };
363
364                 timer7: timer@4804a000 {
365                         compatible = "ti,dm816-timer";
366                         reg = <0x4804a000 0x2000>;
367                         interrupts = <95>;
368                         ti,hwmods = "timer7";
369                         ti,timer-pwm;
370                 };
371
372                 uart1: uart@48020000 {
373                         compatible = "ti,omap3-uart";
374                         ti,hwmods = "uart1";
375                         reg = <0x48020000 0x2000>;
376                         clock-frequency = <48000000>;
377                         interrupts = <72>;
378                         dmas = <&edma 26 &edma 27>;
379                         dma-names = "tx", "rx";
380                 };
381
382                 uart2: uart@48022000 {
383                         compatible = "ti,omap3-uart";
384                         ti,hwmods = "uart2";
385                         reg = <0x48022000 0x2000>;
386                         clock-frequency = <48000000>;
387                         interrupts = <73>;
388                         dmas = <&edma 28 &edma 29>;
389                         dma-names = "tx", "rx";
390                 };
391
392                 uart3: uart@48024000 {
393                         compatible = "ti,omap3-uart";
394                         ti,hwmods = "uart3";
395                         reg = <0x48024000 0x2000>;
396                         clock-frequency = <48000000>;
397                         interrupts = <74>;
398                         dmas = <&edma 30 &edma 31>;
399                         dma-names = "tx", "rx";
400                 };
401
402                 /* NOTE: USB needs a transceiver driver for phys to work */
403                 usb: usb_otg_hs@47401000 {
404                         compatible = "ti,am33xx-usb";
405                         reg = <0x47401000 0x400000>;
406                         ranges;
407                         #address-cells = <1>;
408                         #size-cells = <1>;
409                         ti,hwmods = "usb_otg_hs";
410
411                         usb0: usb@47401000 {
412                                 compatible = "ti,musb-dm816";
413                                 reg = <0x47401400 0x400
414                                        0x47401000 0x200>;
415                                 reg-names = "mc", "control";
416                                 interrupts = <18>;
417                                 interrupt-names = "mc";
418                                 dr_mode = "host";
419                                 interface-type = <0>;
420                                 phys = <&usb_phy0>;
421                                 phy-names = "usb2-phy";
422                                 mentor,multipoint = <1>;
423                                 mentor,num-eps = <16>;
424                                 mentor,ram-bits = <12>;
425                                 mentor,power = <500>;
426
427                                 dmas = <&cppi41dma  0 0 &cppi41dma  1 0
428                                         &cppi41dma  2 0 &cppi41dma  3 0
429                                         &cppi41dma  4 0 &cppi41dma  5 0
430                                         &cppi41dma  6 0 &cppi41dma  7 0
431                                         &cppi41dma  8 0 &cppi41dma  9 0
432                                         &cppi41dma 10 0 &cppi41dma 11 0
433                                         &cppi41dma 12 0 &cppi41dma 13 0
434                                         &cppi41dma 14 0 &cppi41dma  0 1
435                                         &cppi41dma  1 1 &cppi41dma  2 1
436                                         &cppi41dma  3 1 &cppi41dma  4 1
437                                         &cppi41dma  5 1 &cppi41dma  6 1
438                                         &cppi41dma  7 1 &cppi41dma  8 1
439                                         &cppi41dma  9 1 &cppi41dma 10 1
440                                         &cppi41dma 11 1 &cppi41dma 12 1
441                                         &cppi41dma 13 1 &cppi41dma 14 1>;
442                                 dma-names =
443                                         "rx1", "rx2", "rx3", "rx4", "rx5", "rx6", "rx7",
444                                         "rx8", "rx9", "rx10", "rx11", "rx12", "rx13",
445                                         "rx14", "rx15",
446                                         "tx1", "tx2", "tx3", "tx4", "tx5", "tx6", "tx7",
447                                         "tx8", "tx9", "tx10", "tx11", "tx12", "tx13",
448                                         "tx14", "tx15";
449                         };
450
451                         usb1: usb@47401800 {
452                                 compatible = "ti,musb-dm816";
453                                 reg = <0x47401c00 0x400
454                                        0x47401800 0x200>;
455                                 reg-names = "mc", "control";
456                                 interrupts = <19>;
457                                 interrupt-names = "mc";
458                                 dr_mode = "host";
459                                 interface-type = <0>;
460                                 phys = <&usb_phy1>;
461                                 phy-names = "usb2-phy";
462                                 mentor,multipoint = <1>;
463                                 mentor,num-eps = <16>;
464                                 mentor,ram-bits = <12>;
465                                 mentor,power = <500>;
466
467                                 dmas = <&cppi41dma 15 0 &cppi41dma 16 0
468                                         &cppi41dma 17 0 &cppi41dma 18 0
469                                         &cppi41dma 19 0 &cppi41dma 20 0
470                                         &cppi41dma 21 0 &cppi41dma 22 0
471                                         &cppi41dma 23 0 &cppi41dma 24 0
472                                         &cppi41dma 25 0 &cppi41dma 26 0
473                                         &cppi41dma 27 0 &cppi41dma 28 0
474                                         &cppi41dma 29 0 &cppi41dma 15 1
475                                         &cppi41dma 16 1 &cppi41dma 17 1
476                                         &cppi41dma 18 1 &cppi41dma 19 1
477                                         &cppi41dma 20 1 &cppi41dma 21 1
478                                         &cppi41dma 22 1 &cppi41dma 23 1
479                                         &cppi41dma 24 1 &cppi41dma 25 1
480                                         &cppi41dma 26 1 &cppi41dma 27 1
481                                         &cppi41dma 28 1 &cppi41dma 29 1>;
482                                 dma-names =
483                                         "rx1", "rx2", "rx3", "rx4", "rx5", "rx6", "rx7",
484                                         "rx8", "rx9", "rx10", "rx11", "rx12", "rx13",
485                                         "rx14", "rx15",
486                                         "tx1", "tx2", "tx3", "tx4", "tx5", "tx6", "tx7",
487                                         "tx8", "tx9", "tx10", "tx11", "tx12", "tx13",
488                                         "tx14", "tx15";
489                         };
490
491                         cppi41dma: dma-controller@47402000 {
492                                 compatible = "ti,am3359-cppi41";
493                                 reg =  <0x47400000 0x1000
494                                         0x47402000 0x1000
495                                         0x47403000 0x1000
496                                         0x47404000 0x4000>;
497                                 reg-names = "glue", "controller", "scheduler", "queuemgr";
498                                 interrupts = <17>;
499                                 interrupt-names = "glue";
500                                 #dma-cells = <2>;
501                                 #dma-channels = <30>;
502                                 #dma-requests = <256>;
503                         };
504                 };
505
506                 wd_timer2: wd_timer@480c2000 {
507                         compatible = "ti,omap3-wdt";
508                         ti,hwmods = "wd_timer";
509                         reg = <0x480c2000 0x1000>;
510                         interrupts = <0>;
511                 };
512         };
513 };
514
515 #include "dm816x-clocks.dtsi"