xref: /linux/arch/arm64/boot/dts/xilinx/zynqmp-sm-k26-revA.dts (revision db4a3f0fbedb0398f77b9047e8b8bb2b49f355bb)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * dts file for Xilinx ZynqMP SM-K26 rev2/1/B/A
4 *
5 * (C) Copyright 2020 - 2021, Xilinx, Inc.
6 * (C) Copyright 2023 - 2024, Advanced Micro Devices, Inc.
7 *
8 * Michal Simek <michal.simek@amd.com>
9 */
10
11/dts-v1/;
12
13#include "zynqmp.dtsi"
14#include "zynqmp-clk-ccf.dtsi"
15#include <dt-bindings/input/input.h>
16#include <dt-bindings/gpio/gpio.h>
17#include <dt-bindings/phy/phy.h>
18#include <dt-bindings/pinctrl/pinctrl-zynqmp.h>
19
20/ {
21	model = "ZynqMP SM-K26 Rev2/1/B/A";
22	compatible = "xlnx,zynqmp-sm-k26-rev2",
23		     "xlnx,zynqmp-sm-k26-rev1", "xlnx,zynqmp-sm-k26-revB",
24		     "xlnx,zynqmp-sm-k26-revA", "xlnx,zynqmp-sm-k26",
25		     "xlnx,zynqmp";
26
27	aliases {
28		i2c0 = &i2c0;
29		i2c1 = &i2c1;
30		mmc0 = &sdhci0;
31		mmc1 = &sdhci1;
32		nvmem0 = &eeprom;
33		nvmem1 = &eeprom_cc;
34		rtc0 = &rtc;
35		serial0 = &uart0;
36		serial1 = &uart1;
37		serial2 = &dcc;
38		spi0 = &qspi;
39		spi1 = &spi0;
40		spi2 = &spi1;
41		usb0 = &usb0;
42		usb1 = &usb1;
43	};
44
45	chosen {
46		bootargs = "earlycon";
47		stdout-path = "serial1:115200n8";
48	};
49
50	memory@0 {
51		device_type = "memory"; /* 4GB */
52		reg = <0x0 0x0 0x0 0x80000000>, <0x8 0x00000000 0x0 0x80000000>;
53	};
54
55	reserved-memory {
56		#address-cells = <2>;
57		#size-cells = <2>;
58		ranges;
59
60		pmu_region: pmu@7ff00000 {
61			reg = <0x0 0x7ff00000 0x0 0x100000>;
62			no-map;
63		};
64	};
65
66	gpio-keys {
67		compatible = "gpio-keys";
68		autorepeat;
69		key-fwuen {
70			label = "fwuen";
71			gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
72			linux,code = <BTN_MISC>;
73			wakeup-source;
74			autorepeat;
75		};
76	};
77
78	leds {
79		compatible = "gpio-leds";
80		ds35-led {
81			label = "heartbeat";
82			gpios = <&gpio 7 GPIO_ACTIVE_HIGH>;
83			linux,default-trigger = "heartbeat";
84		};
85
86		ds36-led {
87			label = "vbus_det";
88			gpios = <&gpio 8 GPIO_ACTIVE_HIGH>;
89			default-state = "on";
90		};
91	};
92
93	pwm_fan: pwm-fan {
94		compatible = "pwm-fan";
95		status = "okay";
96		pwms = <&ttc0 2 40000 1>;
97	};
98};
99
100&modepin_gpio {
101	label = "modepin";
102};
103
104&ttc0 {
105	status = "okay";
106	#pwm-cells = <3>;
107};
108
109&uart1 { /* MIO36/MIO37 */
110	status = "okay";
111};
112
113&pinctrl0 {
114	status = "okay";
115	pinctrl_sdhci0_default: sdhci0-default {
116		conf {
117			groups = "sdio0_0_grp";
118			slew-rate = <SLEW_RATE_SLOW>;
119			power-source = <IO_STANDARD_LVCMOS18>;
120			bias-disable;
121		};
122
123		mux {
124			groups = "sdio0_0_grp";
125			function = "sdio0";
126		};
127	};
128};
129
130&qspi { /* MIO 0-5 - U143 */
131	status = "okay";
132	spi_flash: flash@0 { /* MT25QU512A */
133		compatible = "jedec,spi-nor"; /* 64MB */
134		reg = <0>;
135		spi-tx-bus-width = <4>;
136		spi-rx-bus-width = <4>;
137		spi-max-frequency = <40000000>; /* 40MHz */
138
139		partitions {
140			compatible = "fixed-partitions";
141			#address-cells = <1>;
142			#size-cells = <1>;
143
144			partition@0 {
145				label = "Image Selector";
146				reg = <0x0 0x80000>; /* 512KB */
147				read-only;
148				lock;
149			};
150			partition@80000 {
151				label = "Image Selector Golden";
152				reg = <0x80000 0x80000>; /* 512KB */
153				read-only;
154				lock;
155			};
156			partition@100000 {
157				label = "Persistent Register";
158				reg = <0x100000 0x20000>; /* 128KB */
159			};
160			partition@120000 {
161				label = "Persistent Register Backup";
162				reg = <0x120000 0x20000>; /* 128KB */
163			};
164			partition@140000 {
165				label = "Open_1";
166				reg = <0x140000 0xC0000>; /* 768KB */
167			};
168			partition@200000 {
169				label = "Image A (FSBL, PMU, ATF, U-Boot)";
170				reg = <0x200000 0xD00000>; /* 13MB */
171			};
172			partition@f00000 {
173				label = "ImgSel Image A Catch";
174				reg = <0xF00000 0x80000>; /* 512KB */
175				read-only;
176				lock;
177			};
178			partition@f80000 {
179				label = "Image B (FSBL, PMU, ATF, U-Boot)";
180				reg = <0xF80000 0xD00000>; /* 13MB */
181			};
182			partition@1c80000 {
183				label = "ImgSel Image B Catch";
184				reg = <0x1C80000 0x80000>; /* 512KB */
185				read-only;
186				lock;
187			};
188			partition@1d00000 {
189				label = "Open_2";
190				reg = <0x1D00000 0x100000>; /* 1MB */
191			};
192			partition@1e00000 {
193				label = "Recovery Image";
194				reg = <0x1E00000 0x200000>; /* 2MB */
195				read-only;
196				lock;
197			};
198			partition@2000000 {
199				label = "Recovery Image Backup";
200				reg = <0x2000000 0x200000>; /* 2MB */
201				read-only;
202				lock;
203			};
204			partition@2200000 {
205				label = "U-Boot storage variables";
206				reg = <0x2200000 0x20000>; /* 128KB */
207			};
208			partition@2220000 {
209				label = "U-Boot storage variables backup";
210				reg = <0x2220000 0x20000>; /* 128KB */
211			};
212			partition@2240000 {
213				label = "SHA256";
214				reg = <0x2240000 0x40000>; /* 256B but 256KB sector */
215				read-only;
216				lock;
217			};
218			partition@2280000 {
219				label = "Secure OS Storage";
220				reg = <0x2280000 0x20000>; /* 128KB */
221			};
222			partition@22a0000 {
223				label = "User";
224				reg = <0x22a0000 0x1d60000>; /* 29.375 MB */
225			};
226		};
227	};
228};
229
230&sdhci0 { /* MIO13-23 - 16GB emmc MTFC16GAPALBH-IT - U133A */
231	status = "okay";
232	pinctrl-names = "default";
233	pinctrl-0 = <&pinctrl_sdhci0_default>;
234	non-removable;
235	disable-wp;
236	no-sd;
237	no-sdio;
238	cap-mmc-hw-reset;
239	bus-width = <8>;
240	xlnx,mio-bank = <0>;
241	assigned-clock-rates = <187498123>;
242};
243
244&spi1 { /* MIO6, 9-11 */
245	status = "okay";
246	label = "TPM";
247	num-cs = <1>;
248	tpm@0 { /* slm9670 - U144 */
249		compatible = "infineon,slb9670", "tcg,tpm_tis-spi";
250		reg = <0>;
251		spi-max-frequency = <18500000>;
252	};
253};
254
255&i2c1 {
256	status = "okay";
257	bootph-all;
258	clock-frequency = <400000>;
259	scl-gpios = <&gpio 24 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
260	sda-gpios = <&gpio 25 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
261
262	eeprom: eeprom@50 { /* u46 - also at address 0x58 */
263		bootph-all;
264		compatible = "st,24c64", "atmel,24c64"; /* st m24c64 */
265		reg = <0x50>;
266		/* WP pin EE_WP_EN connected to slg7x644092@68 */
267	};
268
269	eeprom_cc: eeprom@51 { /* required by spec - also at address 0x59 */
270		bootph-all;
271		compatible = "st,24c64", "atmel,24c64"; /* st m24c64 */
272		reg = <0x51>;
273	};
274
275	/* da9062@30 - u170 - also at address 0x31 */
276	/* da9131@33 - u167 */
277	da9131: pmic@33 {
278		compatible = "dlg,da9131";
279		reg = <0x33>;
280		regulators {
281			da9131_buck1: buck1 {
282				regulator-name = "da9131_buck1";
283				regulator-boot-on;
284				regulator-always-on;
285			};
286			da9131_buck2: buck2 {
287				regulator-name = "da9131_buck2";
288				regulator-boot-on;
289				regulator-always-on;
290			};
291		};
292	};
293
294	/* da9130@32 - u166 */
295	da9130: pmic@32 {
296		compatible = "dlg,da9130";
297		reg = <0x32>;
298		regulators {
299			da9130_buck1: buck1 {
300				regulator-name = "da9130_buck1";
301				regulator-boot-on;
302				regulator-always-on;
303			};
304		};
305	};
306
307	/* slg7x644091@70 - u168 NOT accessible due to address conflict with stdp4320 */
308	/*
309	 * stdp4320 - u27 FW has below two issues to be fixed in next board revision.
310	 * Device acknowledging to addresses 0x5C, 0x5D, 0x70, 0x72, 0x76.
311	 * Address conflict with slg7x644091@70 making both the devices NOT accessible.
312	 * With the FW fix, stdp4320 should respond to address 0x73 only.
313	 */
314	/* slg7x644092@68 - u169 */
315	/* Also connected via JA1C as C23/C24 */
316};
317
318&gpio {
319	status = "okay";
320	gpio-line-names = "QSPI_CLK", "QSPI_DQ1", "QSPI_DQ2", "QSPI_DQ3", "QSPI_DQ0", /* 0 - 4 */
321			  "QSPI_CS_B", "SPI_CLK", "LED1", "LED2", "SPI_CS_B", /* 5 - 9 */
322			  "SPI_MISO", "SPI_MOSI", "FWUEN", "EMMC_DAT0", "EMMC_DAT1", /* 10 - 14 */
323			  "EMMC_DAT2", "EMMC_DAT3", "EMMC_DAT4", "EMMC_DAT5", "EMMC_DAT6", /* 15 - 19 */
324			  "EMMC_DAT7", "EMMC_CMD", "EMMC_CLK", "EMMC_RST", "I2C1_SCL", /* 20 - 24 */
325			  "I2C1_SDA", "", "", "", "", /* 25 - 29 */
326			  "", "", "", "", "", /* 30 - 34 */
327			  "", "", "", "", "", /* 35 - 39 */
328			  "", "", "", "", "", /* 40 - 44 */
329			  "", "", "", "", "", /* 45 - 49 */
330			  "", "", "", "", "", /* 50 - 54 */
331			  "", "", "", "", "", /* 55 - 59 */
332			  "", "", "", "", "", /* 60 - 64 */
333			  "", "", "", "", "", /* 65 - 69 */
334			  "", "", "", "", "", /* 70 - 74 */
335			  "", "", "", /* 75 - 77, MIO end and EMIO start */
336			  "", "", /* 78 - 79 */
337			  "", "", "", "", "", /* 80 - 84 */
338			  "", "", "", "", "", /* 85 - 89 */
339			  "", "", "", "", "", /* 90 - 94 */
340			  "", "", "", "", "", /* 95 - 99 */
341			  "", "", "", "", "", /* 100 - 104 */
342			  "", "", "", "", "", /* 105 - 109 */
343			  "", "", "", "", "", /* 110 - 114 */
344			  "", "", "", "", "", /* 115 - 119 */
345			  "", "", "", "", "", /* 120 - 124 */
346			  "", "", "", "", "", /* 125 - 129 */
347			  "", "", "", "", "", /* 130 - 134 */
348			  "", "", "", "", "", /* 135 - 139 */
349			  "", "", "", "", "", /* 140 - 144 */
350			  "", "", "", "", "", /* 145 - 149 */
351			  "", "", "", "", "", /* 150 - 154 */
352			  "", "", "", "", "", /* 155 - 159 */
353			  "", "", "", "", "", /* 160 - 164 */
354			  "", "", "", "", "", /* 165 - 169 */
355			  "", "", "", ""; /* 170 - 173 */
356};
357
358&ams_ps {
359	status = "okay";
360};
361
362&ams_pl {
363	status = "okay";
364};
365
366&zynqmp_dpsub {
367	status = "okay";
368};
369
370&rtc {
371	status = "okay";
372};
373
374&lpd_dma_chan1 {
375	status = "okay";
376};
377
378&lpd_dma_chan2 {
379	status = "okay";
380};
381
382&lpd_dma_chan3 {
383	status = "okay";
384};
385
386&lpd_dma_chan4 {
387	status = "okay";
388};
389
390&lpd_dma_chan5 {
391	status = "okay";
392};
393
394&lpd_dma_chan6 {
395	status = "okay";
396};
397
398&lpd_dma_chan7 {
399	status = "okay";
400};
401
402&lpd_dma_chan8 {
403	status = "okay";
404};
405
406&fpd_dma_chan1 {
407	status = "okay";
408};
409
410&fpd_dma_chan2 {
411	status = "okay";
412};
413
414&fpd_dma_chan3 {
415	status = "okay";
416};
417
418&fpd_dma_chan4 {
419	status = "okay";
420};
421
422&fpd_dma_chan5 {
423	status = "okay";
424};
425
426&fpd_dma_chan6 {
427	status = "okay";
428};
429
430&fpd_dma_chan7 {
431	status = "okay";
432};
433
434&fpd_dma_chan8 {
435	status = "okay";
436};
437
438&gpu {
439	status = "okay";
440};
441
442&lpd_watchdog {
443	status = "okay";
444};
445
446&watchdog0 {
447	status = "okay";
448};
449
450&cpu_opp_table {
451	opp00 {
452		opp-hz = /bits/ 64 <1333333333>;
453	};
454	opp01 {
455		opp-hz = /bits/ 64 <666666666>;
456	};
457	opp02 {
458		opp-hz = /bits/ 64 <444444444>;
459	};
460	opp03 {
461		opp-hz = /bits/ 64 <333333333>;
462	};
463};
464