xref: /linux/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts (revision 7d8c36674b965fca5ed4a112bc9642703fa657b6)
135ca8168SChen Feng/*
235ca8168SChen Feng * dts file for Hisilicon HiKey960 Development Board
335ca8168SChen Feng *
435ca8168SChen Feng * Copyright (C) 2016, Hisilicon Ltd.
535ca8168SChen Feng *
635ca8168SChen Feng */
735ca8168SChen Feng
835ca8168SChen Feng/dts-v1/;
935ca8168SChen Feng
1035ca8168SChen Feng#include "hi3660.dtsi"
11d4e1eaeeSWang Xiaoyin#include "hikey960-pinctrl.dtsi"
122e9b4447SGuodong Xu#include <dt-bindings/gpio/gpio.h>
138cb53a8dSChen Jun#include <dt-bindings/input/input.h>
148cb53a8dSChen Jun#include <dt-bindings/interrupt-controller/irq.h>
1535ca8168SChen Feng
1635ca8168SChen Feng/ {
1735ca8168SChen Feng	model = "HiKey960";
18b6c93186SGuodong Xu	compatible = "hisilicon,hi3660-hikey960", "hisilicon,hi3660";
1935ca8168SChen Feng
2035ca8168SChen Feng	aliases {
21804d7d7aSLi Wei		mshc1 = &dwmmc1;
22804d7d7aSLi Wei		mshc2 = &dwmmc2;
23254b07b2SChen Feng		serial0 = &uart0;
24254b07b2SChen Feng		serial1 = &uart1;
25254b07b2SChen Feng		serial2 = &uart2;
26254b07b2SChen Feng		serial3 = &uart3;
27254b07b2SChen Feng		serial4 = &uart4;
28254b07b2SChen Feng		serial5 = &uart5;
29254b07b2SChen Feng		serial6 = &uart6;
3035ca8168SChen Feng	};
3135ca8168SChen Feng
3235ca8168SChen Feng	chosen {
33254b07b2SChen Feng		stdout-path = "serial6:115200n8";
3435ca8168SChen Feng	};
3535ca8168SChen Feng
3635ca8168SChen Feng	memory@0 {
3735ca8168SChen Feng		device_type = "memory";
3835ca8168SChen Feng		/* rewrite this at bootloader */
3935ca8168SChen Feng		reg = <0x0 0x0 0x0 0x0>;
4035ca8168SChen Feng	};
418cb53a8dSChen Jun
428cb53a8dSChen Jun	keys {
438cb53a8dSChen Jun		compatible = "gpio-keys";
448cb53a8dSChen Jun		pinctrl-names = "default";
458cb53a8dSChen Jun		pinctrl-0 = <&pwr_key_pmx_func &pwr_key_cfg_func>;
468cb53a8dSChen Jun
478cb53a8dSChen Jun		power {
488cb53a8dSChen Jun			wakeup-source;
498cb53a8dSChen Jun			gpios = <&gpio4 2 GPIO_ACTIVE_LOW>;
508cb53a8dSChen Jun			label = "GPIO Power";
518cb53a8dSChen Jun			linux,code = <KEY_POWER>;
528cb53a8dSChen Jun		};
538cb53a8dSChen Jun	};
54fc5f2ed6SGuodong Xu
55fc5f2ed6SGuodong Xu	leds {
56fc5f2ed6SGuodong Xu		compatible = "gpio-leds";
57fc5f2ed6SGuodong Xu
58fc5f2ed6SGuodong Xu		user_led1 {
59fc5f2ed6SGuodong Xu			label = "user_led1";
60fc5f2ed6SGuodong Xu			/* gpio_150_user_led1 */
61fc5f2ed6SGuodong Xu			gpios = <&gpio18 6 0>;
62fc5f2ed6SGuodong Xu			linux,default-trigger = "heartbeat";
63fc5f2ed6SGuodong Xu		};
64fc5f2ed6SGuodong Xu
65fc5f2ed6SGuodong Xu		user_led2 {
66fc5f2ed6SGuodong Xu			label = "user_led2";
67fc5f2ed6SGuodong Xu			/* gpio_151_user_led2 */
68fc5f2ed6SGuodong Xu			gpios = <&gpio18 7 0>;
69fc5f2ed6SGuodong Xu			linux,default-trigger = "mmc0";
70fc5f2ed6SGuodong Xu		};
71fc5f2ed6SGuodong Xu
72fc5f2ed6SGuodong Xu		user_led3 {
73fc5f2ed6SGuodong Xu			label = "user_led3";
74fc5f2ed6SGuodong Xu			/* gpio_189_user_led3 */
75fc5f2ed6SGuodong Xu			gpios = <&gpio23 5 0>;
76fc5f2ed6SGuodong Xu			default-state = "off";
77fc5f2ed6SGuodong Xu		};
78fc5f2ed6SGuodong Xu
79fc5f2ed6SGuodong Xu		user_led4 {
80fc5f2ed6SGuodong Xu			label = "user_led4";
81fc5f2ed6SGuodong Xu			/* gpio_190_user_led4 */
82fc5f2ed6SGuodong Xu			gpios = <&gpio23 6 0>;
83fc5f2ed6SGuodong Xu			linux,default-trigger = "cpu0";
84fc5f2ed6SGuodong Xu		};
85fc5f2ed6SGuodong Xu
86fc5f2ed6SGuodong Xu		wlan_active_led {
87fc5f2ed6SGuodong Xu			label = "wifi_active";
88fc5f2ed6SGuodong Xu			/* gpio_205_wifi_active */
89fc5f2ed6SGuodong Xu			gpios = <&gpio25 5 0>;
90fc5f2ed6SGuodong Xu			linux,default-trigger = "phy0tx";
91fc5f2ed6SGuodong Xu			default-state = "off";
92fc5f2ed6SGuodong Xu		};
93fc5f2ed6SGuodong Xu
94fc5f2ed6SGuodong Xu		bt_active_led {
95fc5f2ed6SGuodong Xu			label = "bt_active";
96fc5f2ed6SGuodong Xu			gpios = <&gpio25 7 0>;
97fc5f2ed6SGuodong Xu			/* gpio_207_user_led1 */
98fc5f2ed6SGuodong Xu			linux,default-trigger = "hci0-power";
99fc5f2ed6SGuodong Xu			default-state = "off";
100fc5f2ed6SGuodong Xu		};
101fc5f2ed6SGuodong Xu	};
102e02045aaSWang Xiaoyin
103e02045aaSWang Xiaoyin	pmic: pmic@fff34000 {
104e02045aaSWang Xiaoyin		compatible = "hisilicon,hi6421v530-pmic";
105e02045aaSWang Xiaoyin		reg = <0x0 0xfff34000 0x0 0x1000>;
106e02045aaSWang Xiaoyin		interrupt-controller;
107e02045aaSWang Xiaoyin		#interrupt-cells = <2>;
108e02045aaSWang Xiaoyin
109e02045aaSWang Xiaoyin		regulators {
110e02045aaSWang Xiaoyin			ldo3: LDO3 { /* HDMI */
111e02045aaSWang Xiaoyin				regulator-name = "VOUT3_1V85";
112e02045aaSWang Xiaoyin				regulator-min-microvolt = <1800000>;
113e02045aaSWang Xiaoyin				regulator-max-microvolt = <2200000>;
114e02045aaSWang Xiaoyin				regulator-enable-ramp-delay = <120>;
115e02045aaSWang Xiaoyin			};
116e02045aaSWang Xiaoyin
117e02045aaSWang Xiaoyin			ldo9: LDO9 { /* SDCARD I/O */
118e02045aaSWang Xiaoyin				regulator-name = "VOUT9_1V8_2V95";
119e02045aaSWang Xiaoyin				regulator-min-microvolt = <1750000>;
120e02045aaSWang Xiaoyin				regulator-max-microvolt = <3300000>;
121e02045aaSWang Xiaoyin				regulator-enable-ramp-delay = <240>;
122e02045aaSWang Xiaoyin			};
123e02045aaSWang Xiaoyin
124e02045aaSWang Xiaoyin			ldo11: LDO11 { /* Low Speed Connector */
125e02045aaSWang Xiaoyin				regulator-name = "VOUT11_1V8_2V95";
126e02045aaSWang Xiaoyin				regulator-min-microvolt = <1750000>;
127e02045aaSWang Xiaoyin				regulator-max-microvolt = <3300000>;
128e02045aaSWang Xiaoyin				regulator-enable-ramp-delay = <240>;
129e02045aaSWang Xiaoyin			};
130e02045aaSWang Xiaoyin
131e02045aaSWang Xiaoyin			ldo15: LDO15 { /* UFS VCC */
132e02045aaSWang Xiaoyin				regulator-name = "VOUT15_3V0";
133e02045aaSWang Xiaoyin				regulator-min-microvolt = <1750000>;
134e02045aaSWang Xiaoyin				regulator-max-microvolt = <3000000>;
135e02045aaSWang Xiaoyin				regulator-boot-on;
136e02045aaSWang Xiaoyin				regulator-always-on;
137e02045aaSWang Xiaoyin				regulator-enable-ramp-delay = <120>;
138e02045aaSWang Xiaoyin			};
139e02045aaSWang Xiaoyin
140e02045aaSWang Xiaoyin			ldo16: LDO16 { /* SD VDD */
141e02045aaSWang Xiaoyin				regulator-name = "VOUT16_2V95";
142e02045aaSWang Xiaoyin				regulator-min-microvolt = <1750000>;
143e02045aaSWang Xiaoyin				regulator-max-microvolt = <3000000>;
144e02045aaSWang Xiaoyin				regulator-enable-ramp-delay = <360>;
145e02045aaSWang Xiaoyin			};
146e02045aaSWang Xiaoyin		};
147e02045aaSWang Xiaoyin	};
148*7d8c3667SGuodong Xu
149*7d8c3667SGuodong Xu	wlan_en: wlan-en-1-8v {
150*7d8c3667SGuodong Xu		compatible = "regulator-fixed";
151*7d8c3667SGuodong Xu		regulator-name = "wlan-en-regulator";
152*7d8c3667SGuodong Xu		regulator-min-microvolt = <1800000>;
153*7d8c3667SGuodong Xu		regulator-max-microvolt = <1800000>;
154*7d8c3667SGuodong Xu
155*7d8c3667SGuodong Xu		/* GPIO_051_WIFI_EN */
156*7d8c3667SGuodong Xu		gpio = <&gpio6 3 0>;
157*7d8c3667SGuodong Xu
158*7d8c3667SGuodong Xu		/* WLAN card specific delay */
159*7d8c3667SGuodong Xu		startup-delay-us = <70000>;
160*7d8c3667SGuodong Xu		enable-active-high;
161*7d8c3667SGuodong Xu	};
16235ca8168SChen Feng};
16335ca8168SChen Feng
1645f8a3b77SZhangfei Gao&i2c0 {
1655f8a3b77SZhangfei Gao	/* On Low speed expansion */
1665f8a3b77SZhangfei Gao	label = "LS-I2C0";
1675f8a3b77SZhangfei Gao	status = "okay";
1685f8a3b77SZhangfei Gao};
1695f8a3b77SZhangfei Gao
1705f8a3b77SZhangfei Gao&i2c1 {
1715f8a3b77SZhangfei Gao	status = "okay";
1725f8a3b77SZhangfei Gao
1735f8a3b77SZhangfei Gao	adv7533: adv7533@39 {
1745f8a3b77SZhangfei Gao		status = "ok";
1755f8a3b77SZhangfei Gao		compatible = "adi,adv7533";
1765f8a3b77SZhangfei Gao		reg = <0x39>;
1775f8a3b77SZhangfei Gao	};
1785f8a3b77SZhangfei Gao};
1795f8a3b77SZhangfei Gao
1805f8a3b77SZhangfei Gao&i2c7 {
1815f8a3b77SZhangfei Gao	/* On Low speed expansion */
1825f8a3b77SZhangfei Gao	label = "LS-I2C1";
1835f8a3b77SZhangfei Gao	status = "okay";
1845f8a3b77SZhangfei Gao};
1855f8a3b77SZhangfei Gao
186254b07b2SChen Feng&uart3 {
187254b07b2SChen Feng	/* On Low speed expansion */
188254b07b2SChen Feng	label = "LS-UART0";
189254b07b2SChen Feng	status = "okay";
190254b07b2SChen Feng};
191254b07b2SChen Feng
1922e9b4447SGuodong Xu&uart4 {
1932e9b4447SGuodong Xu	status = "okay";
1942e9b4447SGuodong Xu
1952e9b4447SGuodong Xu	bluetooth {
1962e9b4447SGuodong Xu		compatible = "ti,wl1837-st";
1972e9b4447SGuodong Xu		enable-gpios = <&gpio15 6 GPIO_ACTIVE_HIGH>;
1982e9b4447SGuodong Xu		max-speed = <921600>;
1992e9b4447SGuodong Xu	};
2002e9b4447SGuodong Xu};
2012e9b4447SGuodong Xu
202254b07b2SChen Feng&uart6 {
203254b07b2SChen Feng	/* On Low speed expansion */
204254b07b2SChen Feng	label = "LS-UART1";
20535ca8168SChen Feng	status = "okay";
20635ca8168SChen Feng};
20738810497SWang Xiaoyin
20838810497SWang Xiaoyin&spi2 {
20938810497SWang Xiaoyin	/* On Low speed expansion */
21038810497SWang Xiaoyin	label = "LS-SPI0";
21138810497SWang Xiaoyin	status = "okay";
21238810497SWang Xiaoyin};
21338810497SWang Xiaoyin
21438810497SWang Xiaoyin&spi3 {
21538810497SWang Xiaoyin	/* On High speed expansion */
21638810497SWang Xiaoyin	label = "HS-SPI1";
21738810497SWang Xiaoyin	status = "okay";
21838810497SWang Xiaoyin};
219804d7d7aSLi Wei
220804d7d7aSLi Wei&dwmmc1 {
221804d7d7aSLi Wei	vmmc-supply = <&ldo16>;
222804d7d7aSLi Wei	vqmmc-supply = <&ldo9>;
223804d7d7aSLi Wei	status = "okay";
224804d7d7aSLi Wei};
225*7d8c3667SGuodong Xu
226*7d8c3667SGuodong Xu&dwmmc2 { /* WIFI */
227*7d8c3667SGuodong Xu	broken-cd;
228*7d8c3667SGuodong Xu	/* WL_EN */
229*7d8c3667SGuodong Xu	vmmc-supply = <&wlan_en>;
230*7d8c3667SGuodong Xu	ti,non-removable;
231*7d8c3667SGuodong Xu	non-removable;
232*7d8c3667SGuodong Xu	#address-cells = <0x1>;
233*7d8c3667SGuodong Xu	#size-cells = <0x0>;
234*7d8c3667SGuodong Xu	status = "ok";
235*7d8c3667SGuodong Xu
236*7d8c3667SGuodong Xu	wlcore: wlcore@2 {
237*7d8c3667SGuodong Xu		compatible = "ti,wl1837";
238*7d8c3667SGuodong Xu		reg = <2>;      /* sdio func num */
239*7d8c3667SGuodong Xu		/* WL_IRQ, GPIO_179_WL_WAKEUP_AP */
240*7d8c3667SGuodong Xu		interrupt-parent = <&gpio22>;
241*7d8c3667SGuodong Xu		interrupts = <3 IRQ_TYPE_EDGE_RISING>;
242*7d8c3667SGuodong Xu	};
243*7d8c3667SGuodong Xu};
244