Merge tag 'for-4.21/libata-20190102' of git://git.kernel.dk/linux-block
[sfrench/cifs-2.6.git] / arch / arm / boot / dts / aspeed-bmc-opp-lanyang.dts
1 // SPDX-License-Identifier: GPL-2.0+
2 // Copyright (c) 2018 Inventec Corporation
3 /dts-v1/;
4
5 #include "aspeed-g5.dtsi"
6 #include <dt-bindings/gpio/aspeed-gpio.h>
7
8 / {
9         model = "Lanyang BMC";
10         compatible = "inventec,lanyang-bmc", "aspeed,ast2500";
11
12         chosen {
13                 stdout-path = &uart5;
14                 bootargs = "console=ttyS4,115200 earlyprintk";
15         };
16
17         memory@80000000 {
18                 reg = <0x80000000 0x40000000>;
19         };
20
21         reserved-memory {
22                 #address-cells = <1>;
23                 #size-cells = <1>;
24                 ranges;
25
26                 flash_memory: region@98000000 {
27                         no-map;
28                         reg = <0x98000000 0x04000000>; /* 64M */
29                 };
30         };
31
32         leds {
33                 compatible = "gpio-leds";
34
35                 sys_boot_status {
36                         label = "System_boot_status";
37                         gpios = <&gpio ASPEED_GPIO(B, 6) GPIO_ACTIVE_LOW>;
38                 };
39
40                 attention {
41                         label = "Attention_locator";
42                         gpios = <&gpio ASPEED_GPIO(B, 7) GPIO_ACTIVE_HIGH>;
43                 };
44
45                 plt_fault {
46                         label = "Platform_fault";
47                         gpios = <&gpio ASPEED_GPIO(B, 1) GPIO_ACTIVE_HIGH>;
48                 };
49
50                 hdd_fault {
51                         label = "Onboard_drive_fault";
52                         gpios = <&gpio ASPEED_GPIO(B, 3) GPIO_ACTIVE_HIGH>;
53                 };
54                 bmc_err {
55                         lable = "BMC_fault";
56                         gpios = <&gpio ASPEED_GPIO(H, 6) GPIO_ACTIVE_HIGH>;
57                 };
58
59                 sys_err {
60                         lable = "Sys_fault";
61                         gpios = <&gpio ASPEED_GPIO(H, 7) GPIO_ACTIVE_HIGH>;
62                 };
63         };
64
65         fsi: gpio-fsi {
66                 compatible = "fsi-master-gpio", "fsi-master";
67                 #address-cells = <2>;
68                 #size-cells = <0>;
69
70                 clock-gpios = <&gpio ASPEED_GPIO(J, 0) GPIO_ACTIVE_HIGH>;
71                 data-gpios = <&gpio ASPEED_GPIO(J, 1) GPIO_ACTIVE_HIGH>;
72                 trans-gpios = <&gpio ASPEED_GPIO(D, 5) GPIO_ACTIVE_HIGH>;
73                 enable-gpios = <&gpio ASPEED_GPIO(D, 0) GPIO_ACTIVE_HIGH>;
74                 mux-gpios = <&gpio ASPEED_GPIO(H, 2) GPIO_ACTIVE_HIGH>;
75         };
76
77         iio-hwmon {
78                 compatible = "iio-hwmon";
79                 io-channels = <&adc 0>, <&adc 1>, <&adc 2>, <&adc 3>,
80                         <&adc 4>, <&adc 5>, <&adc 6>, <&adc 7>,
81                         <&adc 8>, <&adc 9>, <&adc 10>, <&adc 11>,
82                         <&adc 13>, <&adc 14>, <&adc 15>;
83         };
84
85         iio-hwmon-battery {
86                 compatible = "iio-hwmon";
87                 io-channels = <&adc 12>;
88         };
89 };
90
91 &pwm_tacho {
92         status = "okay";
93         pinctrl-names = "default";
94         pinctrl-0 = <&pinctrl_pwm0_default &pinctrl_pwm1_default
95                 &pinctrl_pwm2_default &pinctrl_pwm3_default>;
96
97         fan@0 {
98                 reg = <0x00>;
99                 aspeed,fan-tach-ch = /bits/ 8 <0x00>;
100         };
101
102         fan@1 {
103                 reg = <0x01>;
104                 aspeed,fan-tach-ch = /bits/ 8 <0x01>;
105         };
106
107         fan@2 {
108                 reg = <0x02>;
109                 aspeed,fan-tach-ch = /bits/ 8 <0x02>;
110         };
111
112         fan@3 {
113                 reg = <0x03>;
114                 aspeed,fan-tach-ch = /bits/ 8 <0x03>;
115         };
116 };
117
118 &fmc {
119         status = "okay";
120         flash@0 {
121                 status = "okay";
122                 m25p,fast-read;
123                 label = "bmc";
124 #include "openbmc-flash-layout.dtsi"
125         };
126 };
127
128 &spi1 {
129         status = "okay";
130         pinctrl-names = "default";
131         pinctrl-0 = <&pinctrl_spi1_default>;
132
133         flash@0 {
134                 status = "okay";
135                 label = "pnor";
136                 m25p,fast-read;
137         };
138 };
139
140 &spi2 {
141         status = "okay";
142         pinctrl-names = "default";
143         pinctrl-0 = <&pinctrl_spi2ck_default
144                      &pinctrl_spi2cs0_default
145                      &pinctrl_spi2cs1_default
146                      &pinctrl_spi2miso_default
147                      &pinctrl_spi2mosi_default>;
148
149         flash@0 {
150                 status = "okay";
151         };
152 };
153
154 &uart1 {
155         status = "okay";
156         pinctrl-names = "default";
157         pinctrl-0 = <&pinctrl_txd1_default
158                      &pinctrl_rxd1_default>;
159 };
160
161 &lpc_ctrl {
162         status = "okay";
163         memory-region = <&flash_memory>;
164         flash = <&spi1>;
165 };
166
167 &lpc_snoop {
168         status = "okay";
169         snoop-ports = <0x80>;
170 };
171
172 &uart5 {
173         status = "okay";
174 };
175
176 &mac0 {
177         status = "okay";
178
179         pinctrl-names = "default";
180         pinctrl-0 = <&pinctrl_rmii1_default>;
181         use-ncsi;
182 };
183
184 &mac1 {
185         status = "okay";
186
187         pinctrl-names = "default";
188         pinctrl-0 = <&pinctrl_rgmii2_default &pinctrl_mdio2_default>;
189 };
190
191 &i2c0 {
192         status = "okay";
193
194         eeprom@55 {
195                 compatible = "atmel,24c64";
196                 reg = <0x55>;
197                 pagesize = <32>;
198         };
199
200         rtc@68 {
201                 compatible = "nxp,pcf8523";
202                 reg = <0x68>;
203         };
204
205         tmp75@48 {
206                 compatible = "ti,tmp75";
207                 reg = <0x48>;
208         };
209 };
210
211 &i2c1 {
212         status = "okay";
213 };
214
215 &i2c2 {
216         status = "okay";
217 };
218
219 &i2c3 {
220         status = "okay";
221 };
222
223 &i2c4 {
224         status = "okay";
225 };
226
227 &i2c5 {
228         status = "okay";
229 };
230
231 &i2c6 {
232         status = "okay";
233 };
234
235 &i2c7 {
236         status = "okay";
237 };
238
239 &i2c8 {
240         status = "okay";
241 };
242
243 &i2c9 {
244         status = "okay";
245 };
246
247 &i2c10 {
248         status = "okay";
249 };
250
251 &i2c11 {
252         status = "okay";
253 };
254
255 &vuart {
256         status = "okay";
257 };
258
259 &gfx {
260         status = "okay";
261 };
262
263 &pinctrl {
264         aspeed,external-nodes = <&gfx &lhc>;
265 };
266
267 &gpio {
268         pin_gpio_b0 {
269                 gpio-hog;
270                 gpios = <ASPEED_GPIO(B, 0) GPIO_ACTIVE_HIGH>;
271                 output-high;
272                 line-name = "BMC_HDD1_PWR_EN";
273         };
274
275         pin_gpio_b5 {
276                 gpio-hog;
277                 gpios = <ASPEED_GPIO(B, 5) GPIO_ACTIVE_HIGH>;
278                 input;
279                 line-name = "BMC_USB1_OCI2";
280         };
281
282         pin_gpio_h5 {
283                 gpio-hog;
284                 gpios = <ASPEED_GPIO(H, 5) GPIO_ACTIVE_HIGH>;
285                 output-high;
286                 line-name = "BMC_CP0_PERST_ENABLE_R";
287         };
288
289         pin_gpio_z2 {
290                 gpio-hog;
291                 gpios = <ASPEED_GPIO(Z, 2) GPIO_ACTIVE_HIGH>;
292                 output-high;
293                 line-name = "RST_PCA9546_U177_N";
294         };
295
296         pin_gpio_aa6 {
297                 gpio-hog;
298                 gpios = <ASPEED_GPIO(AA, 6) GPIO_ACTIVE_HIGH>;
299                 output-high;
300                 line-name = "BMC_CP0_RESET_N";
301         };
302
303         pin_gpio_aa7 {
304                 gpio-hog;
305                 gpios = <ASPEED_GPIO(AA, 7) GPIO_ACTIVE_HIGH>;
306                 output-high;
307                 line-name = "BMC_TPM_RESET_N";
308         };
309
310         pin_gpio_ab0 {
311                 gpio-hog;
312                 gpios = <ASPEED_GPIO(AB, 0) GPIO_ACTIVE_LOW>;
313                 output-high;
314                 line-name = "BMC_USB_PWRON_N";
315         };
316 };
317
318 &ibt {
319         status = "okay";
320 };
321
322 &adc {
323         status = "okay";
324 };