xref: /OK3568_Linux_fs/kernel/arch/arm/boot/dts/alpine.dtsi (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun/*
2*4882a593Smuzhiyun * Copyright 2015 Annapurna Labs Ltd.
3*4882a593Smuzhiyun *
4*4882a593Smuzhiyun * This program is free software; you can redistribute it and/or modify it
5*4882a593Smuzhiyun * under the terms and conditions of the GNU General Public License,
6*4882a593Smuzhiyun * version 2, as published by the Free Software Foundation.
7*4882a593Smuzhiyun *
8*4882a593Smuzhiyun * Alternatively, redistribution and use in source and binary forms, with or
9*4882a593Smuzhiyun * without modification, are permitted provided that the following conditions
10*4882a593Smuzhiyun * are met:
11*4882a593Smuzhiyun *
12*4882a593Smuzhiyun *   *   Redistributions of source code must retain the above copyright notice,
13*4882a593Smuzhiyun *       this list of conditions and the following disclaimer.
14*4882a593Smuzhiyun *
15*4882a593Smuzhiyun *   *   Redistributions in binary form must reproduce the above copyright
16*4882a593Smuzhiyun *       notice, this list of conditions and the following disclaimer in
17*4882a593Smuzhiyun *       the documentation and/or other materials provided with the
18*4882a593Smuzhiyun *       distribution.
19*4882a593Smuzhiyun *
20*4882a593Smuzhiyun * This program is distributed in the hope it will be useful, but WITHOUT
21*4882a593Smuzhiyun * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
22*4882a593Smuzhiyun * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
23*4882a593Smuzhiyun * more details.
24*4882a593Smuzhiyun *
25*4882a593Smuzhiyun */
26*4882a593Smuzhiyun
27*4882a593Smuzhiyun#include <dt-bindings/interrupt-controller/arm-gic.h>
28*4882a593Smuzhiyun
29*4882a593Smuzhiyun/ {
30*4882a593Smuzhiyun	#address-cells = <2>;
31*4882a593Smuzhiyun	#size-cells = <2>;
32*4882a593Smuzhiyun	/* SOC compatibility */
33*4882a593Smuzhiyun	compatible = "al,alpine";
34*4882a593Smuzhiyun
35*4882a593Smuzhiyun	memory {
36*4882a593Smuzhiyun		device_type = "memory";
37*4882a593Smuzhiyun		reg = <0 0 0 0>;
38*4882a593Smuzhiyun	};
39*4882a593Smuzhiyun
40*4882a593Smuzhiyun	/* CPU Configuration */
41*4882a593Smuzhiyun	cpus {
42*4882a593Smuzhiyun		#address-cells = <1>;
43*4882a593Smuzhiyun		#size-cells = <0>;
44*4882a593Smuzhiyun		enable-method = "al,alpine-smp";
45*4882a593Smuzhiyun
46*4882a593Smuzhiyun		cpu@0 {
47*4882a593Smuzhiyun			compatible = "arm,cortex-a15";
48*4882a593Smuzhiyun			device_type = "cpu";
49*4882a593Smuzhiyun			reg = <0>;
50*4882a593Smuzhiyun			clock-frequency = <1700000000>;
51*4882a593Smuzhiyun		};
52*4882a593Smuzhiyun
53*4882a593Smuzhiyun		cpu@1 {
54*4882a593Smuzhiyun			compatible = "arm,cortex-a15";
55*4882a593Smuzhiyun			device_type = "cpu";
56*4882a593Smuzhiyun			reg = <1>;
57*4882a593Smuzhiyun			clock-frequency = <1700000000>;
58*4882a593Smuzhiyun		};
59*4882a593Smuzhiyun
60*4882a593Smuzhiyun		cpu@2 {
61*4882a593Smuzhiyun			compatible = "arm,cortex-a15";
62*4882a593Smuzhiyun			device_type = "cpu";
63*4882a593Smuzhiyun			reg = <2>;
64*4882a593Smuzhiyun			clock-frequency = <1700000000>;
65*4882a593Smuzhiyun		};
66*4882a593Smuzhiyun
67*4882a593Smuzhiyun		cpu@3 {
68*4882a593Smuzhiyun			compatible = "arm,cortex-a15";
69*4882a593Smuzhiyun			device_type = "cpu";
70*4882a593Smuzhiyun			reg = <3>;
71*4882a593Smuzhiyun			clock-frequency = <1700000000>;
72*4882a593Smuzhiyun		};
73*4882a593Smuzhiyun	};
74*4882a593Smuzhiyun
75*4882a593Smuzhiyun	soc {
76*4882a593Smuzhiyun		#address-cells = <2>;
77*4882a593Smuzhiyun		#size-cells = <2>;
78*4882a593Smuzhiyun		compatible = "simple-bus";
79*4882a593Smuzhiyun		interrupt-parent = <&gic>;
80*4882a593Smuzhiyun		ranges;
81*4882a593Smuzhiyun
82*4882a593Smuzhiyun		arch-timer {
83*4882a593Smuzhiyun			compatible = "arm,cortex-a15-timer",
84*4882a593Smuzhiyun				     "arm,armv7-timer";
85*4882a593Smuzhiyun			interrupts =
86*4882a593Smuzhiyun				<GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
87*4882a593Smuzhiyun				<GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
88*4882a593Smuzhiyun				<GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
89*4882a593Smuzhiyun				<GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
90*4882a593Smuzhiyun			clock-frequency = <50000000>;
91*4882a593Smuzhiyun		};
92*4882a593Smuzhiyun
93*4882a593Smuzhiyun		/* Interrupt Controller */
94*4882a593Smuzhiyun		gic: interrupt-controller@fb001000 {
95*4882a593Smuzhiyun			compatible = "arm,cortex-a15-gic";
96*4882a593Smuzhiyun			#interrupt-cells = <3>;
97*4882a593Smuzhiyun			#size-cells = <0>;
98*4882a593Smuzhiyun			#address-cells = <0>;
99*4882a593Smuzhiyun			interrupt-controller;
100*4882a593Smuzhiyun			reg = <0x0 0xfb001000 0x0 0x1000>,
101*4882a593Smuzhiyun			      <0x0 0xfb002000 0x0 0x2000>,
102*4882a593Smuzhiyun			      <0x0 0xfb004000 0x0 0x2000>,
103*4882a593Smuzhiyun			      <0x0 0xfb006000 0x0 0x2000>;
104*4882a593Smuzhiyun			interrupts =
105*4882a593Smuzhiyun				<GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
106*4882a593Smuzhiyun		};
107*4882a593Smuzhiyun
108*4882a593Smuzhiyun		/* CPU Resume registers */
109*4882a593Smuzhiyun		cpu-resume@fbff5ec0 {
110*4882a593Smuzhiyun			compatible = "al,alpine-cpu-resume";
111*4882a593Smuzhiyun			reg = <0x0 0xfbff5ec0 0x0 0x30>;
112*4882a593Smuzhiyun		};
113*4882a593Smuzhiyun
114*4882a593Smuzhiyun		/* North Bridge Service Registers */
115*4882a593Smuzhiyun		sysfabric-service@fb070000 {
116*4882a593Smuzhiyun			compatible = "al,alpine-sysfabric-service", "syscon";
117*4882a593Smuzhiyun			reg = <0x0 0xfb070000 0x0 0x10000>;
118*4882a593Smuzhiyun		};
119*4882a593Smuzhiyun
120*4882a593Smuzhiyun		/* Performance Monitor Unit */
121*4882a593Smuzhiyun		pmu {
122*4882a593Smuzhiyun			compatible = "arm,cortex-a15-pmu";
123*4882a593Smuzhiyun			interrupts = <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>,
124*4882a593Smuzhiyun				     <GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>,
125*4882a593Smuzhiyun				     <GIC_SPI 70 IRQ_TYPE_LEVEL_HIGH>,
126*4882a593Smuzhiyun				     <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
127*4882a593Smuzhiyun		};
128*4882a593Smuzhiyun
129*4882a593Smuzhiyun		uart0: uart@fd883000 {
130*4882a593Smuzhiyun			compatible = "ns16550a";
131*4882a593Smuzhiyun			reg = <0x0 0xfd883000 0x0 0x1000>;
132*4882a593Smuzhiyun			clock-frequency = <375000000>;
133*4882a593Smuzhiyun			interrupts = <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
134*4882a593Smuzhiyun			reg-shift = <2>;
135*4882a593Smuzhiyun			reg-io-width = <4>;
136*4882a593Smuzhiyun		};
137*4882a593Smuzhiyun
138*4882a593Smuzhiyun		uart1: uart@fd884000 {
139*4882a593Smuzhiyun			compatible = "ns16550a";
140*4882a593Smuzhiyun			reg = <0x0 0xfd884000 0x0 0x1000>;
141*4882a593Smuzhiyun			clock-frequency = <375000000>;
142*4882a593Smuzhiyun			interrupts = <GIC_SPI 18 IRQ_TYPE_LEVEL_HIGH>;
143*4882a593Smuzhiyun			reg-shift = <2>;
144*4882a593Smuzhiyun			reg-io-width = <4>;
145*4882a593Smuzhiyun		};
146*4882a593Smuzhiyun
147*4882a593Smuzhiyun		/* Internal PCIe Controller */
148*4882a593Smuzhiyun		pcie@fbc00000 {
149*4882a593Smuzhiyun			compatible = "pci-host-ecam-generic";
150*4882a593Smuzhiyun			device_type = "pci";
151*4882a593Smuzhiyun			#size-cells = <2>;
152*4882a593Smuzhiyun			#address-cells = <3>;
153*4882a593Smuzhiyun			#interrupt-cells = <1>;
154*4882a593Smuzhiyun			reg = <0x0 0xfbc00000 0x0 0x100000>;
155*4882a593Smuzhiyun			interrupt-map-mask = <0xf800 0 0 7>;
156*4882a593Smuzhiyun			/* Add legacy interrupts for SATA devices only */
157*4882a593Smuzhiyun			interrupt-map =	<0x4000 0 0 1 &gic 0 43 4>,
158*4882a593Smuzhiyun					<0x4800 0 0 1 &gic 0 44 4>;
159*4882a593Smuzhiyun
160*4882a593Smuzhiyun			/* 32 bit non prefetchable memory space */
161*4882a593Smuzhiyun			ranges = <0x02000000 0x0 0xfe000000 0x0 0xfe000000 0x0 0x1000000>;
162*4882a593Smuzhiyun
163*4882a593Smuzhiyun			bus-range = <0x00 0x00>;
164*4882a593Smuzhiyun			msi-parent = <&msix>;
165*4882a593Smuzhiyun		};
166*4882a593Smuzhiyun
167*4882a593Smuzhiyun		msix: msix@fbe00000 {
168*4882a593Smuzhiyun			compatible = "al,alpine-msix";
169*4882a593Smuzhiyun			reg = <0x0 0xfbe00000 0x0 0x100000>;
170*4882a593Smuzhiyun			interrupt-controller;
171*4882a593Smuzhiyun			msi-controller;
172*4882a593Smuzhiyun			al,msi-base-spi = <96>;
173*4882a593Smuzhiyun			al,msi-num-spis = <64>;
174*4882a593Smuzhiyun		};
175*4882a593Smuzhiyun	};
176*4882a593Smuzhiyun};
177