xref: /openbmc/linux/arch/arm/boot/dts/st/ste-ux500-samsung-skomer.dts (revision 2612e3bbc0386368a850140a6c9b990cd496a5ec)
1*724ba675SRob Herring// SPDX-License-Identifier: GPL-2.0-only
2*724ba675SRob Herring/*
3*724ba675SRob Herring * Devicetree for the Samsung XCover 2 GT-S7710 also known as Skomer.
4*724ba675SRob Herring */
5*724ba675SRob Herring
6*724ba675SRob Herring/dts-v1/;
7*724ba675SRob Herring#include "ste-db8500.dtsi"
8*724ba675SRob Herring#include "ste-ab8505.dtsi"
9*724ba675SRob Herring#include "ste-dbx5x0-pinctrl.dtsi"
10*724ba675SRob Herring#include <dt-bindings/gpio/gpio.h>
11*724ba675SRob Herring#include <dt-bindings/leds/common.h>
12*724ba675SRob Herring#include <dt-bindings/input/input.h>
13*724ba675SRob Herring#include <dt-bindings/interrupt-controller/irq.h>
14*724ba675SRob Herring
15*724ba675SRob Herring/ {
16*724ba675SRob Herring	model = "Samsung XCover 2 (GT-S7710)";
17*724ba675SRob Herring	compatible = "samsung,skomer", "st-ericsson,u8500";
18*724ba675SRob Herring
19*724ba675SRob Herring	chosen {
20*724ba675SRob Herring		stdout-path = &serial2;
21*724ba675SRob Herring	};
22*724ba675SRob Herring
23*724ba675SRob Herring	battery: battery {
24*724ba675SRob Herring		compatible = "samsung,eb485159lu";
25*724ba675SRob Herring	};
26*724ba675SRob Herring
27*724ba675SRob Herring	thermal-zones {
28*724ba675SRob Herring		battery-thermal {
29*724ba675SRob Herring			/* This zone will be polled by the battery temperature code */
30*724ba675SRob Herring			polling-delay = <0>;
31*724ba675SRob Herring			polling-delay-passive = <0>;
32*724ba675SRob Herring			thermal-sensors = <&bat_therm>;
33*724ba675SRob Herring
34*724ba675SRob Herring			trips {
35*724ba675SRob Herring				battery-crit-hi {
36*724ba675SRob Herring					temperature = <70000>;
37*724ba675SRob Herring					hysteresis = <2000>;
38*724ba675SRob Herring					type = "critical";
39*724ba675SRob Herring				};
40*724ba675SRob Herring			};
41*724ba675SRob Herring		};
42*724ba675SRob Herring	};
43*724ba675SRob Herring
44*724ba675SRob Herring	bat_therm: thermistor {
45*724ba675SRob Herring		compatible = "samsung,1404-001221";
46*724ba675SRob Herring		io-channels = <&gpadc 0x02>; /* BatTemp */
47*724ba675SRob Herring		pullup-uv = <1800000>;
48*724ba675SRob Herring		pullup-ohm = <230000>;
49*724ba675SRob Herring		pulldown-ohm = <0>;
50*724ba675SRob Herring		#thermal-sensor-cells = <0>;
51*724ba675SRob Herring	};
52*724ba675SRob Herring
53*724ba675SRob Herring	/* TI TXS0206 level translator for 2.9 V */
54*724ba675SRob Herring	sd_level_translator: regulator-gpio {
55*724ba675SRob Herring		compatible = "regulator-fixed";
56*724ba675SRob Herring
57*724ba675SRob Herring		/* GPIO87 EN */
58*724ba675SRob Herring		gpios = <&gpio2 23 GPIO_ACTIVE_HIGH>;
59*724ba675SRob Herring		enable-active-high;
60*724ba675SRob Herring
61*724ba675SRob Herring		regulator-name = "sd-level-translator";
62*724ba675SRob Herring		regulator-min-microvolt = <2900000>;
63*724ba675SRob Herring		regulator-max-microvolt = <2900000>;
64*724ba675SRob Herring		regulator-type = "voltage";
65*724ba675SRob Herring
66*724ba675SRob Herring		startup-delay-us = <200>;
67*724ba675SRob Herring
68*724ba675SRob Herring		pinctrl-names = "default";
69*724ba675SRob Herring		pinctrl-0 = <&sd_level_translator_default>;
70*724ba675SRob Herring	};
71*724ba675SRob Herring
72*724ba675SRob Herring	/* External LDO MIC5366-3.3YMT for eMMC */
73*724ba675SRob Herring	ldo_3v3_reg: regulator-gpio-ldo-3v3 {
74*724ba675SRob Herring		compatible = "regulator-fixed";
75*724ba675SRob Herring		regulator-name = "en-3v3-fixed-supply";
76*724ba675SRob Herring		regulator-min-microvolt = <3300000>;
77*724ba675SRob Herring		regulator-max-microvolt = <3300000>;
78*724ba675SRob Herring		gpio = <&gpio6 31 GPIO_ACTIVE_HIGH>;
79*724ba675SRob Herring		startup-delay-us = <5000>;
80*724ba675SRob Herring		enable-active-high;
81*724ba675SRob Herring		pinctrl-names = "default";
82*724ba675SRob Herring		pinctrl-0 = <&emmc_ldo_en_default_mode>;
83*724ba675SRob Herring	};
84*724ba675SRob Herring
85*724ba675SRob Herring	wlan_en: regulator-gpio-wlan-en {
86*724ba675SRob Herring		compatible = "regulator-fixed";
87*724ba675SRob Herring		regulator-name = "wl-reg-on";
88*724ba675SRob Herring		regulator-min-microvolt = <3000000>;
89*724ba675SRob Herring		regulator-max-microvolt = <3000000>;
90*724ba675SRob Herring		startup-delay-us = <200000>;
91*724ba675SRob Herring		/* GPIO215 WLAN_EN */
92*724ba675SRob Herring		gpio = <&gpio6 23 GPIO_ACTIVE_HIGH>;
93*724ba675SRob Herring		enable-active-high;
94*724ba675SRob Herring		pinctrl-names = "default";
95*724ba675SRob Herring		pinctrl-0 = <&wlan_en_default_mode>;
96*724ba675SRob Herring	};
97*724ba675SRob Herring
98*724ba675SRob Herring	vibrator {
99*724ba675SRob Herring		compatible = "gpio-vibrator";
100*724ba675SRob Herring		enable-gpios = <&gpio6 3 GPIO_ACTIVE_HIGH>;
101*724ba675SRob Herring		pinctrl-names = "default";
102*724ba675SRob Herring		pinctrl-0 = <&vibrator_default>;
103*724ba675SRob Herring	};
104*724ba675SRob Herring
105*724ba675SRob Herring	gpio-keys {
106*724ba675SRob Herring		compatible = "gpio-keys";
107*724ba675SRob Herring		pinctrl-names = "default";
108*724ba675SRob Herring		pinctrl-0 = <&gpio_keys_default_mode>;
109*724ba675SRob Herring
110*724ba675SRob Herring		button-home {
111*724ba675SRob Herring			linux,code = <KEY_HOME>;
112*724ba675SRob Herring			label = "HOME";
113*724ba675SRob Herring			/* GPIO91 */
114*724ba675SRob Herring			gpios = <&gpio2 27 GPIO_ACTIVE_LOW>;
115*724ba675SRob Herring		};
116*724ba675SRob Herring		button-volup {
117*724ba675SRob Herring			linux,code = <KEY_VOLUMEUP>;
118*724ba675SRob Herring			label = "VOL+";
119*724ba675SRob Herring			/* GPIO67 */
120*724ba675SRob Herring			gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
121*724ba675SRob Herring		};
122*724ba675SRob Herring		button-voldown {
123*724ba675SRob Herring			linux,code = <KEY_VOLUMEDOWN>;
124*724ba675SRob Herring			label = "VOL-";
125*724ba675SRob Herring			/* GPIO92 */
126*724ba675SRob Herring			gpios = <&gpio2 28 GPIO_ACTIVE_LOW>;
127*724ba675SRob Herring		};
128*724ba675SRob Herring		button-menu {
129*724ba675SRob Herring			linux,code = <KEY_MENU>;
130*724ba675SRob Herring			label = "MENU";
131*724ba675SRob Herring			/* GPIO204 */
132*724ba675SRob Herring			gpios = <&gpio6 12 GPIO_ACTIVE_LOW>;
133*724ba675SRob Herring		};
134*724ba675SRob Herring		button-back {
135*724ba675SRob Herring			linux,code = <KEY_BACK>;
136*724ba675SRob Herring			label = "BACK";
137*724ba675SRob Herring			/* GPIO205 */
138*724ba675SRob Herring			gpios = <&gpio6 13 GPIO_ACTIVE_LOW>;
139*724ba675SRob Herring		};
140*724ba675SRob Herring	};
141*724ba675SRob Herring
142*724ba675SRob Herring	ktd253: backlight {
143*724ba675SRob Herring		compatible = "kinetic,ktd253";
144*724ba675SRob Herring		/* GPIO 69 */
145*724ba675SRob Herring		enable-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
146*724ba675SRob Herring		/* Default to 13/32 brightness */
147*724ba675SRob Herring		default-brightness = <13>;
148*724ba675SRob Herring		pinctrl-names = "default";
149*724ba675SRob Herring		pinctrl-0 = <&gpio_backlight_default_mode>;
150*724ba675SRob Herring	};
151*724ba675SRob Herring
152*724ba675SRob Herring	/* Richtek RT8515GQW Flash LED Driver IC */
153*724ba675SRob Herring	flash {
154*724ba675SRob Herring		compatible = "richtek,rt8515";
155*724ba675SRob Herring		/* GPIO 140 */
156*724ba675SRob Herring		enf-gpios = <&gpio4 12 GPIO_ACTIVE_HIGH>;
157*724ba675SRob Herring		/* GPIO 141 */
158*724ba675SRob Herring		ent-gpios = <&gpio4 13 GPIO_ACTIVE_HIGH>;
159*724ba675SRob Herring		/*
160*724ba675SRob Herring		 * RFS is 16 kOhm and RTS is 100 kOhm giving
161*724ba675SRob Herring		 * the flash max current 343mA and torch max
162*724ba675SRob Herring		 * current 55 mA.
163*724ba675SRob Herring		 */
164*724ba675SRob Herring		richtek,rfs-ohms = <16000>;
165*724ba675SRob Herring		richtek,rts-ohms = <100000>;
166*724ba675SRob Herring		pinctrl-names = "default";
167*724ba675SRob Herring		pinctrl-0 = <&gpio_flash_default_mode>;
168*724ba675SRob Herring
169*724ba675SRob Herring		led {
170*724ba675SRob Herring			function = LED_FUNCTION_FLASH;
171*724ba675SRob Herring			color = <LED_COLOR_ID_WHITE>;
172*724ba675SRob Herring			flash-max-timeout-us = <250000>;
173*724ba675SRob Herring			flash-max-microamp = <343750>;
174*724ba675SRob Herring			led-max-microamp = <55000>;
175*724ba675SRob Herring		};
176*724ba675SRob Herring	};
177*724ba675SRob Herring
178*724ba675SRob Herring	i2c-gpio-0 {
179*724ba675SRob Herring		compatible = "i2c-gpio";
180*724ba675SRob Herring		sda-gpios = <&gpio4 16 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
181*724ba675SRob Herring		scl-gpios = <&gpio4 15 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
182*724ba675SRob Herring		pinctrl-names = "default";
183*724ba675SRob Herring		pinctrl-0 = <&i2c_gpio_0_default>;
184*724ba675SRob Herring		#address-cells = <1>;
185*724ba675SRob Herring		#size-cells = <0>;
186*724ba675SRob Herring		/* TODO: this should be used by the NCP6914 Camera power management unit */
187*724ba675SRob Herring	};
188*724ba675SRob Herring
189*724ba675SRob Herring	i2c-gpio-1 {
190*724ba675SRob Herring		compatible = "i2c-gpio";
191*724ba675SRob Herring		sda-gpios = <&gpio4 24 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
192*724ba675SRob Herring		scl-gpios = <&gpio4 23 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
193*724ba675SRob Herring		pinctrl-names = "default";
194*724ba675SRob Herring		pinctrl-0 = <&i2c_gpio_1_default>;
195*724ba675SRob Herring		#address-cells = <1>;
196*724ba675SRob Herring		#size-cells = <0>;
197*724ba675SRob Herring		magnetometer@c {
198*724ba675SRob Herring			compatible = "alps,hscdtd008a";
199*724ba675SRob Herring			reg = <0x0c>;
200*724ba675SRob Herring			avdd-supply = <&ab8500_ldo_aux1_reg>;
201*724ba675SRob Herring			dvdd-supply = <&ab8500_ldo_aux8_reg>;
202*724ba675SRob Herring		};
203*724ba675SRob Herring	};
204*724ba675SRob Herring
205*724ba675SRob Herring	soc {
206*724ba675SRob Herring		// External Micro SD slot
207*724ba675SRob Herring		mmc@80126000 {
208*724ba675SRob Herring			arm,primecell-periphid = <0x10480180>;
209*724ba675SRob Herring			max-frequency = <100000000>;
210*724ba675SRob Herring			bus-width = <4>;
211*724ba675SRob Herring			cap-sd-highspeed;
212*724ba675SRob Herring			cap-mmc-highspeed;
213*724ba675SRob Herring			/* All direction control is used */
214*724ba675SRob Herring			st,sig-pin-fbclk;
215*724ba675SRob Herring			full-pwr-cycle;
216*724ba675SRob Herring			vmmc-supply = <&ab8500_ldo_aux3_reg>;
217*724ba675SRob Herring			vqmmc-supply = <&sd_level_translator>;
218*724ba675SRob Herring			pinctrl-names = "default", "sleep";
219*724ba675SRob Herring			pinctrl-0 = <&mc0_a_1_default>;
220*724ba675SRob Herring			pinctrl-1 = <&mc0_a_1_sleep>;
221*724ba675SRob Herring			status = "okay";
222*724ba675SRob Herring		};
223*724ba675SRob Herring
224*724ba675SRob Herring		// WLAN SDIO channel
225*724ba675SRob Herring		mmc@80118000 {
226*724ba675SRob Herring			arm,primecell-periphid = <0x10480180>;
227*724ba675SRob Herring			max-frequency = <50000000>;
228*724ba675SRob Herring			bus-width = <4>;
229*724ba675SRob Herring			non-removable;
230*724ba675SRob Herring			cap-sd-highspeed;
231*724ba675SRob Herring			vmmc-supply = <&wlan_en>;
232*724ba675SRob Herring			pinctrl-names = "default", "sleep";
233*724ba675SRob Herring			pinctrl-0 = <&mc1_a_2_default>;
234*724ba675SRob Herring			pinctrl-1 = <&mc1_a_2_sleep>;
235*724ba675SRob Herring			status = "okay";
236*724ba675SRob Herring			#address-cells = <1>;
237*724ba675SRob Herring			#size-cells = <0>;
238*724ba675SRob Herring
239*724ba675SRob Herring			wifi@1 {
240*724ba675SRob Herring				compatible = "brcm,bcm4334-fmac", "brcm,bcm4329-fmac";
241*724ba675SRob Herring				reg = <1>;
242*724ba675SRob Herring				/* GPIO216 WL_HOST_WAKE */
243*724ba675SRob Herring				interrupt-parent = <&gpio6>;
244*724ba675SRob Herring				interrupts = <24 IRQ_TYPE_EDGE_FALLING>;
245*724ba675SRob Herring				interrupt-names = "host-wake";
246*724ba675SRob Herring				pinctrl-names = "default";
247*724ba675SRob Herring				pinctrl-0 = <&wlan_default_mode>;
248*724ba675SRob Herring			};
249*724ba675SRob Herring		};
250*724ba675SRob Herring
251*724ba675SRob Herring		/*
252*724ba675SRob Herring		 * eMMC seems to be mostly Samsung KLM4G1YE4C "4YMD1R"
253*724ba675SRob Herring		 */
254*724ba675SRob Herring		mmc@80005000 {
255*724ba675SRob Herring			arm,primecell-periphid = <0x10480180>;
256*724ba675SRob Herring		        max-frequency = <100000000>;
257*724ba675SRob Herring			bus-width = <8>;
258*724ba675SRob Herring			non-removable;
259*724ba675SRob Herring			cap-mmc-highspeed;
260*724ba675SRob Herring			mmc-ddr-1_8v;
261*724ba675SRob Herring			no-sdio;
262*724ba675SRob Herring			no-sd;
263*724ba675SRob Herring			/* From datasheet page 26 figure 9: 300 ms set-up time for 4GB */
264*724ba675SRob Herring			post-power-on-delay-ms = <300>;
265*724ba675SRob Herring			vmmc-supply = <&ldo_3v3_reg>;
266*724ba675SRob Herring			pinctrl-names = "default", "sleep";
267*724ba675SRob Herring			pinctrl-0 = <&mc2_a_1_default>;
268*724ba675SRob Herring			pinctrl-1 = <&mc2_a_1_sleep>;
269*724ba675SRob Herring
270*724ba675SRob Herring			status = "okay";
271*724ba675SRob Herring		};
272*724ba675SRob Herring
273*724ba675SRob Herring		/* GBF (Bluetooth) UART */
274*724ba675SRob Herring		serial@80120000 {
275*724ba675SRob Herring			pinctrl-names = "default", "sleep";
276*724ba675SRob Herring			pinctrl-0 = <&u0_a_1_default>;
277*724ba675SRob Herring			pinctrl-1 = <&u0_a_1_sleep>;
278*724ba675SRob Herring			status = "okay";
279*724ba675SRob Herring
280*724ba675SRob Herring			/* FIXME: not quite working yet, probably needs regulators */
281*724ba675SRob Herring			bluetooth {
282*724ba675SRob Herring				/* BCM4334B0 actually */
283*724ba675SRob Herring				compatible = "brcm,bcm4330-bt";
284*724ba675SRob Herring				shutdown-gpios = <&gpio6 30 GPIO_ACTIVE_HIGH>;
285*724ba675SRob Herring				device-wakeup-gpios = <&gpio6 7 GPIO_ACTIVE_HIGH>;
286*724ba675SRob Herring				host-wakeup-gpios = <&gpio3 1 GPIO_ACTIVE_HIGH>;
287*724ba675SRob Herring				pinctrl-names = "default";
288*724ba675SRob Herring				pinctrl-0 = <&bluetooth_default_mode>;
289*724ba675SRob Herring			};
290*724ba675SRob Herring		};
291*724ba675SRob Herring
292*724ba675SRob Herring		/* GPS UART */
293*724ba675SRob Herring		serial@80121000 {
294*724ba675SRob Herring			status = "okay";
295*724ba675SRob Herring			pinctrl-names = "default", "sleep";
296*724ba675SRob Herring			pinctrl-0 = <&u1rxtx_a_1_default &u1ctsrts_a_1_default>;
297*724ba675SRob Herring			pinctrl-1 = <&u1rxtx_a_1_sleep &u1ctsrts_a_1_sleep>;
298*724ba675SRob Herring
299*724ba675SRob Herring			gnss {
300*724ba675SRob Herring				/* The CSRG05TA03-ICJE-R is a SirfStarV 5t chip */
301*724ba675SRob Herring				compatible = "csr,csrg05ta03-icje-r";
302*724ba675SRob Herring				/* GPS_RSTN on GPIO209 */
303*724ba675SRob Herring				reset-gpios = <&gpio6 17 GPIO_ACTIVE_LOW>;
304*724ba675SRob Herring				/* GPS_ON_OFF on GPIO86 */
305*724ba675SRob Herring				sirf,onoff-gpios = <&gpio2 22 GPIO_ACTIVE_HIGH>;
306*724ba675SRob Herring				/* GPS_1V8 (VSMPS2) */
307*724ba675SRob Herring				vcc-supply = <&db8500_vsmps2_reg>;
308*724ba675SRob Herring				pinctrl-names = "default";
309*724ba675SRob Herring				pinctrl-0 = <&g05ta03_skomer_default>;
310*724ba675SRob Herring				/* According to /etc/sirfgps.conf */
311*724ba675SRob Herring				current-speed = <460800>;
312*724ba675SRob Herring			};
313*724ba675SRob Herring		};
314*724ba675SRob Herring
315*724ba675SRob Herring		/* Debugging console UART connected to AB8505 USB */
316*724ba675SRob Herring		serial@80007000 {
317*724ba675SRob Herring			status = "okay";
318*724ba675SRob Herring			pinctrl-names = "default", "sleep";
319*724ba675SRob Herring			pinctrl-0 = <&u2rxtx_c_1_default>;
320*724ba675SRob Herring			pinctrl-1 = <&u2rxtx_c_1_sleep>;
321*724ba675SRob Herring		};
322*724ba675SRob Herring
323*724ba675SRob Herring		prcmu@80157000 {
324*724ba675SRob Herring			ab8505 {
325*724ba675SRob Herring				phy {
326*724ba675SRob Herring					pinctrl-names = "default", "sleep";
327*724ba675SRob Herring					pinctrl-0 = <&usb_a_1_default>;
328*724ba675SRob Herring					pinctrl-1 = <&usb_a_1_sleep>;
329*724ba675SRob Herring				};
330*724ba675SRob Herring
331*724ba675SRob Herring				ab8500_fg {
332*724ba675SRob Herring					line-impedance-micro-ohms = <16000>;
333*724ba675SRob Herring				};
334*724ba675SRob Herring
335*724ba675SRob Herring				regulator {
336*724ba675SRob Herring					ab8500_ldo_aux1 {
337*724ba675SRob Herring						/* Used for VDD for sensors */
338*724ba675SRob Herring						regulator-name = "AUX1";
339*724ba675SRob Herring						regulator-min-microvolt = <3000000>;
340*724ba675SRob Herring						regulator-max-microvolt = <3300000>;
341*724ba675SRob Herring					};
342*724ba675SRob Herring
343*724ba675SRob Herring					ab8500_ldo_aux2 {
344*724ba675SRob Herring						/* Supplies the Cypress TMA140 touchscreen only with 3.0V */
345*724ba675SRob Herring						regulator-name = "AUX2";
346*724ba675SRob Herring						regulator-min-microvolt = <3000000>;
347*724ba675SRob Herring						regulator-max-microvolt = <3000000>;
348*724ba675SRob Herring					};
349*724ba675SRob Herring
350*724ba675SRob Herring					ab8500_ldo_aux3 {
351*724ba675SRob Herring						/* Used for voltage for external MMC/SD card */
352*724ba675SRob Herring						regulator-name = "AUX3";
353*724ba675SRob Herring						regulator-min-microvolt = <1100000>;
354*724ba675SRob Herring						regulator-max-microvolt = <3300000>;
355*724ba675SRob Herring					};
356*724ba675SRob Herring
357*724ba675SRob Herring					ab8500_ldo_aux4 {
358*724ba675SRob Herring						regulator-name = "AUX4";
359*724ba675SRob Herring						/* Hammer to 3.0V for the display */
360*724ba675SRob Herring						regulator-min-microvolt = <3000000>;
361*724ba675SRob Herring						regulator-max-microvolt = <3000000>;
362*724ba675SRob Herring					};
363*724ba675SRob Herring
364*724ba675SRob Herring					ab8500_ldo_aux5 {
365*724ba675SRob Herring						regulator-name = "AUX5";
366*724ba675SRob Herring						/* Intended for 1V8 for touchscreen but actually left unused */
367*724ba675SRob Herring						regulator-min-microvolt = <1050000>;
368*724ba675SRob Herring						regulator-max-microvolt = <2790000>;
369*724ba675SRob Herring					};
370*724ba675SRob Herring
371*724ba675SRob Herring					ab8500_ldo_aux6 {
372*724ba675SRob Herring						regulator-name = "AUX6";
373*724ba675SRob Herring						/* Hammer to 1.8V for the display */
374*724ba675SRob Herring						regulator-min-microvolt = <1800000>;
375*724ba675SRob Herring						regulator-max-microvolt = <1800000>;
376*724ba675SRob Herring					};
377*724ba675SRob Herring
378*724ba675SRob Herring					ab8500_ldo_aux8 {
379*724ba675SRob Herring						/* Mostly VIO for sensors */
380*724ba675SRob Herring						regulator-name = "AUX8";
381*724ba675SRob Herring					};
382*724ba675SRob Herring				};
383*724ba675SRob Herring			};
384*724ba675SRob Herring		};
385*724ba675SRob Herring
386*724ba675SRob Herring		/* I2C0 */
387*724ba675SRob Herring		i2c@80004000 {
388*724ba675SRob Herring			status = "okay";
389*724ba675SRob Herring
390*724ba675SRob Herring			pinctrl-names = "default", "sleep";
391*724ba675SRob Herring			pinctrl-0 = <&i2c0_a_1_default>;
392*724ba675SRob Herring			pinctrl-1 = <&i2c0_a_1_sleep>;
393*724ba675SRob Herring
394*724ba675SRob Herring			proximity@44 {
395*724ba675SRob Herring				compatible = "sharp,gp2ap002s00f";
396*724ba675SRob Herring				clock-frequency = <400000>;
397*724ba675SRob Herring				reg = <0x44>;
398*724ba675SRob Herring
399*724ba675SRob Herring				interrupt-parent = <&gpio4>;
400*724ba675SRob Herring				interrupts = <18 IRQ_TYPE_EDGE_FALLING>;
401*724ba675SRob Herring				vdd-supply = <&ab8500_ldo_aux1_reg>;
402*724ba675SRob Herring				vio-supply = <&ab8500_ldo_aux8_reg>;
403*724ba675SRob Herring				pinctrl-names = "default";
404*724ba675SRob Herring				pinctrl-0 = <&gp2ap002_skomer_default>;
405*724ba675SRob Herring				sharp,proximity-far-hysteresis = /bits/ 8 <0x2f>;
406*724ba675SRob Herring				sharp,proximity-close-hysteresis = /bits/ 8 <0x0f>;
407*724ba675SRob Herring			};
408*724ba675SRob Herring		};
409*724ba675SRob Herring
410*724ba675SRob Herring
411*724ba675SRob Herring		/* I2C2 */
412*724ba675SRob Herring		i2c@80128000 {
413*724ba675SRob Herring			status = "okay";
414*724ba675SRob Herring
415*724ba675SRob Herring			pinctrl-names = "default", "sleep";
416*724ba675SRob Herring			pinctrl-0 = <&i2c2_b_2_default>;
417*724ba675SRob Herring			pinctrl-1 = <&i2c2_b_2_sleep>;
418*724ba675SRob Herring
419*724ba675SRob Herring			accel@18 {
420*724ba675SRob Herring				compatible = "bosch,bma254";
421*724ba675SRob Herring				clock-frequency = <400000>;
422*724ba675SRob Herring				reg = <0x18>;
423*724ba675SRob Herring
424*724ba675SRob Herring				/* GPIO224 used as "smart alert" interrupt */
425*724ba675SRob Herring				interrupt-parent = <&gpio7>;
426*724ba675SRob Herring				interrupts = <0 IRQ_TYPE_EDGE_RISING>;
427*724ba675SRob Herring
428*724ba675SRob Herring				mount-matrix = "0", "-1", "0",
429*724ba675SRob Herring					      "1", "0", "0",
430*724ba675SRob Herring					       "0", "0", "1";
431*724ba675SRob Herring				vdd-supply = <&ab8500_ldo_aux1_reg>;
432*724ba675SRob Herring				vddio-supply = <&ab8500_ldo_aux8_reg>;
433*724ba675SRob Herring				pinctrl-names = "default";
434*724ba675SRob Herring				pinctrl-0 = <&bma254_skomer_default>;
435*724ba675SRob Herring			};
436*724ba675SRob Herring		};
437*724ba675SRob Herring
438*724ba675SRob Herring		/* I2C3 */
439*724ba675SRob Herring		i2c@80110000 {
440*724ba675SRob Herring			status = "okay";
441*724ba675SRob Herring
442*724ba675SRob Herring			pinctrl-names = "default", "sleep";
443*724ba675SRob Herring			pinctrl-0 = <&i2c3_c_2_default>;
444*724ba675SRob Herring			pinctrl-1 = <&i2c3_c_2_sleep>;
445*724ba675SRob Herring
446*724ba675SRob Herring			/* Cypress CY8CTMA140 touchscreen */
447*724ba675SRob Herring			touchscreen@20 {
448*724ba675SRob Herring				compatible = "cypress,cy8ctma140";
449*724ba675SRob Herring				clock-frequency = <400000>;
450*724ba675SRob Herring				reg = <0x20>;
451*724ba675SRob Herring
452*724ba675SRob Herring				touchscreen-size-x = <480>;
453*724ba675SRob Herring				touchscreen-size-y = <800>;
454*724ba675SRob Herring				touchscreen-max-pressure = <255>;
455*724ba675SRob Herring
456*724ba675SRob Herring				/* GPIO218 for IRQ */
457*724ba675SRob Herring				interrupt-parent = <&gpio6>;
458*724ba675SRob Herring				interrupts = <26 IRQ_TYPE_EDGE_FALLING>;
459*724ba675SRob Herring
460*724ba675SRob Herring				/* VDD is "digital supply" nominally 1.71-3.6V */
461*724ba675SRob Herring				vdd-supply = <&ab8500_ldo_aux2_reg>;
462*724ba675SRob Herring				/* VCPIN is "analog supply", 2.7-3.6 V */
463*724ba675SRob Herring				vcpin-supply = <&ab8500_ldo_aux2_reg>;
464*724ba675SRob Herring
465*724ba675SRob Herring				pinctrl-names = "default";
466*724ba675SRob Herring				pinctrl-0 = <&tma140_skomer_default>;
467*724ba675SRob Herring			};
468*724ba675SRob Herring		};
469*724ba675SRob Herring
470*724ba675SRob Herring		mcde@a0350000 {
471*724ba675SRob Herring			status = "okay";
472*724ba675SRob Herring			pinctrl-names = "default";
473*724ba675SRob Herring			pinctrl-0 = <&dsi_default_mode>;
474*724ba675SRob Herring
475*724ba675SRob Herring			dsi@a0351000 {
476*724ba675SRob Herring				panel {
477*724ba675SRob Herring					/* NT35510-based Hydis HVA40WV1 */
478*724ba675SRob Herring					compatible = "hydis,hva40wv1", "novatek,nt35510";
479*724ba675SRob Herring					reg = <0>;
480*724ba675SRob Herring					/* v_lcd_3v0 2.3-4.8V */
481*724ba675SRob Herring					vdd-supply = <&ab8500_ldo_aux4_reg>;
482*724ba675SRob Herring					/* v_lcd_1v8 1.65-3.3V */
483*724ba675SRob Herring					vddi-supply = <&ab8500_ldo_aux6_reg>;
484*724ba675SRob Herring					/* GPIO 139 */
485*724ba675SRob Herring					reset-gpios = <&gpio4 11 GPIO_ACTIVE_LOW>;
486*724ba675SRob Herring					pinctrl-names = "default";
487*724ba675SRob Herring					pinctrl-0 = <&display_default_mode>;
488*724ba675SRob Herring					backlight = <&ktd253>;
489*724ba675SRob Herring				};
490*724ba675SRob Herring			};
491*724ba675SRob Herring		};
492*724ba675SRob Herring	};
493*724ba675SRob Herring};
494*724ba675SRob Herring
495*724ba675SRob Herring&pinctrl {
496*724ba675SRob Herring	sdi0 {
497*724ba675SRob Herring		mc0_a_1_default {
498*724ba675SRob Herring			default_cfg1 {
499*724ba675SRob Herring				/* GPIO18, 19 & 20 unused so pull down */
500*724ba675SRob Herring				ste,config = <&gpio_in_pd>;
501*724ba675SRob Herring			};
502*724ba675SRob Herring		};
503*724ba675SRob Herring	};
504*724ba675SRob Herring
505*724ba675SRob Herring	/* This is a reset line for the eMMC */
506*724ba675SRob Herring	sdi2 {
507*724ba675SRob Herring		mc2_a_1_default {
508*724ba675SRob Herring			default_cfg2 {
509*724ba675SRob Herring				pins = "GPIO130_C8"; /* FBCLK */
510*724ba675SRob Herring				ste,config = <&gpio_in_pd>;
511*724ba675SRob Herring			};
512*724ba675SRob Herring		};
513*724ba675SRob Herring	};
514*724ba675SRob Herring
515*724ba675SRob Herring	mcde {
516*724ba675SRob Herring		dsi_default_mode: dsi_default {
517*724ba675SRob Herring			default_mux1 {
518*724ba675SRob Herring				/* Mux in VSI0 used for DSI TE */
519*724ba675SRob Herring				function = "lcd";
520*724ba675SRob Herring				groups = "lcdvsi0_a_1"; /* VSI0 for LCD */
521*724ba675SRob Herring			};
522*724ba675SRob Herring			default_cfg1 {
523*724ba675SRob Herring				pins = "GPIO68_E1"; /* VSI0 */
524*724ba675SRob Herring				ste,config = <&in_nopull>;
525*724ba675SRob Herring			};
526*724ba675SRob Herring		};
527*724ba675SRob Herring	};
528*724ba675SRob Herring
529*724ba675SRob Herring	/* Two GPIO lines used by the display */
530*724ba675SRob Herring	display {
531*724ba675SRob Herring		display_default_mode: display_default {
532*724ba675SRob Herring			skomer_cfg1 {
533*724ba675SRob Herring				/*
534*724ba675SRob Herring				 * OLED DETECT or check_pba, this appears to be high
535*724ba675SRob Herring				 * on "PBA" which I guess is "prototype board A".
536*724ba675SRob Herring				 */
537*724ba675SRob Herring				pins = "GPIO93_B7";
538*724ba675SRob Herring				ste,config = <&gpio_in_nopull>;
539*724ba675SRob Herring			};
540*724ba675SRob Herring			skomer_cfg2 {
541*724ba675SRob Herring				pins = "GPIO139_C9";
542*724ba675SRob Herring				/*
543*724ba675SRob Herring				 * MIPI_DSI0_RESET_N resets the display, leave high
544*724ba675SRob Herring				 * (de-asserted) so we only assert reset explicitly
545*724ba675SRob Herring				 * from the display driver.
546*724ba675SRob Herring				 */
547*724ba675SRob Herring				ste,config = <&gpio_out_hi>;
548*724ba675SRob Herring			};
549*724ba675SRob Herring		};
550*724ba675SRob Herring	};
551*724ba675SRob Herring	backlight {
552*724ba675SRob Herring		gpio_backlight_default_mode: backlight_default {
553*724ba675SRob Herring			skomer_cfg1 {
554*724ba675SRob Herring				pins = "GPIO69_E2"; /* LCD_BL_CTRL */
555*724ba675SRob Herring				ste,config = <&gpio_out_lo>;
556*724ba675SRob Herring			};
557*724ba675SRob Herring		};
558*724ba675SRob Herring	};
559*724ba675SRob Herring	flash {
560*724ba675SRob Herring		gpio_flash_default_mode: flash_default {
561*724ba675SRob Herring			skomer_cfg1 {
562*724ba675SRob Herring				pins = "GPIO140_B11", "GPIO141_C12";
563*724ba675SRob Herring				ste,config = <&gpio_out_lo>;
564*724ba675SRob Herring			};
565*724ba675SRob Herring		};
566*724ba675SRob Herring	};
567*724ba675SRob Herring	/* GPIO that enables the 2.9V SD card level translator */
568*724ba675SRob Herring	sd-level-translator {
569*724ba675SRob Herring		sd_level_translator_default: sd_level_translator_default {
570*724ba675SRob Herring			/* level shifter on GPIO87 */
571*724ba675SRob Herring			skomer_cfg1 {
572*724ba675SRob Herring				pins = "GPIO87_B3";
573*724ba675SRob Herring				ste,config = <&gpio_out_hi>;
574*724ba675SRob Herring			};
575*724ba675SRob Herring		};
576*724ba675SRob Herring	};
577*724ba675SRob Herring	/* GPIO that enables the LDO regulator for the eMMC */
578*724ba675SRob Herring	emmc-ldo {
579*724ba675SRob Herring		emmc_ldo_en_default_mode: emmc_ldo_default {
580*724ba675SRob Herring			/* LDO enable on GPIO223 */
581*724ba675SRob Herring			skomer_cfg1 {
582*724ba675SRob Herring				pins = "GPIO223_AH9";
583*724ba675SRob Herring				ste,config = <&gpio_out_hi>;
584*724ba675SRob Herring			};
585*724ba675SRob Herring		};
586*724ba675SRob Herring	};
587*724ba675SRob Herring	/* GPIO keys */
588*724ba675SRob Herring	gpio-keys {
589*724ba675SRob Herring		gpio_keys_default_mode: gpio_keys_default {
590*724ba675SRob Herring			skomer_cfg1 {
591*724ba675SRob Herring				pins = "GPIO67_G2", /* VOL UP */
592*724ba675SRob Herring				       "GPIO91_B6", /* HOME */
593*724ba675SRob Herring				       "GPIO92_D6", /* VOL DOWN */
594*724ba675SRob Herring				       "GPIO204_AF23", /* MENU */
595*724ba675SRob Herring				       "GPIO205_AG23"; /* BACK */
596*724ba675SRob Herring					ste,config = <&gpio_in_pu>;
597*724ba675SRob Herring			};
598*724ba675SRob Herring		};
599*724ba675SRob Herring	};
600*724ba675SRob Herring	/* Interrupt line for BMA254 */
601*724ba675SRob Herring	bma254 {
602*724ba675SRob Herring		bma254_skomer_default: bma254_skomer {
603*724ba675SRob Herring			skomer_cfg1 {
604*724ba675SRob Herring				pins = "GPIO224_AG9";
605*724ba675SRob Herring				ste,config = <&gpio_in_pd>;
606*724ba675SRob Herring			};
607*724ba675SRob Herring		};
608*724ba675SRob Herring	};
609*724ba675SRob Herring	/* Interrupt line for light/proximity sensor GP2AP002 */
610*724ba675SRob Herring	gp2ap002 {
611*724ba675SRob Herring		gp2ap002_skomer_default: gp2ap002_skomer {
612*724ba675SRob Herring			skomer_cfg1 {
613*724ba675SRob Herring				pins = "GPIO146_D13";
614*724ba675SRob Herring				ste,config = <&gpio_in_nopull>;
615*724ba675SRob Herring			};
616*724ba675SRob Herring		};
617*724ba675SRob Herring	};
618*724ba675SRob Herring	/* GPIO-based I2C bus for NCP6914 */
619*724ba675SRob Herring	i2c-gpio-0 {
620*724ba675SRob Herring		i2c_gpio_0_default: i2c_gpio_0 {
621*724ba675SRob Herring			skomer_cfg1 {
622*724ba675SRob Herring				pins = "GPIO143_D12", "GPIO144_B13";
623*724ba675SRob Herring				ste,config = <&gpio_in_nopull>;
624*724ba675SRob Herring			};
625*724ba675SRob Herring		};
626*724ba675SRob Herring	};
627*724ba675SRob Herring	/* GPIO-based I2C bus for ALPS HSCD compass */
628*724ba675SRob Herring	i2c-gpio-1 {
629*724ba675SRob Herring		i2c_gpio_1_default: i2c_gpio_1 {
630*724ba675SRob Herring			skomer_cfg1 {
631*724ba675SRob Herring				pins = "GPIO151_B17", "GPIO152_D16";
632*724ba675SRob Herring				ste,config = <&gpio_in_nopull>;
633*724ba675SRob Herring			};
634*724ba675SRob Herring		};
635*724ba675SRob Herring	};
636*724ba675SRob Herring	wlan {
637*724ba675SRob Herring		wlan_default_mode: wlan_default {
638*724ba675SRob Herring			skomer_cfg1 {
639*724ba675SRob Herring				pins = "GPIO216_AG12";
640*724ba675SRob Herring				ste,config = <&gpio_in_pd>;
641*724ba675SRob Herring			};
642*724ba675SRob Herring		};
643*724ba675SRob Herring		wlan_en_default_mode: wlan_en_default {
644*724ba675SRob Herring			skomer_cfg2 {
645*724ba675SRob Herring				pins = "GPIO215_AH13";
646*724ba675SRob Herring				ste,config = <&gpio_out_lo>;
647*724ba675SRob Herring			};
648*724ba675SRob Herring		};
649*724ba675SRob Herring	};
650*724ba675SRob Herring	bluetooth {
651*724ba675SRob Herring		bluetooth_default_mode: bluetooth_default {
652*724ba675SRob Herring			skomer_cfg1 {
653*724ba675SRob Herring				pins = "GPIO199_AH23", "GPIO222_AJ9";
654*724ba675SRob Herring				ste,config = <&gpio_out_lo>;
655*724ba675SRob Herring			};
656*724ba675SRob Herring			skomer_cfg2 {
657*724ba675SRob Herring				pins = "GPIO97_D9";
658*724ba675SRob Herring				ste,config = <&gpio_in_nopull>;
659*724ba675SRob Herring			};
660*724ba675SRob Herring		};
661*724ba675SRob Herring	};
662*724ba675SRob Herring	vibrator {
663*724ba675SRob Herring		vibrator_default: vibrator_default {
664*724ba675SRob Herring			skomer_cfg1 {
665*724ba675SRob Herring				pins = "GPIO195_AG28";	/* MOT_EN */
666*724ba675SRob Herring				ste,config = <&gpio_out_lo>;
667*724ba675SRob Herring			};
668*724ba675SRob Herring		};
669*724ba675SRob Herring	};
670*724ba675SRob Herring	/* Interrupt line for the Cypress TMA140 touchscreen */
671*724ba675SRob Herring	touchscreen {
672*724ba675SRob Herring		tma140_skomer_default: tma140_skomer {
673*724ba675SRob Herring			skomer_cfg1 {
674*724ba675SRob Herring				pins = "GPIO218_AH11";
675*724ba675SRob Herring				ste,config = <&gpio_in_nopull>;
676*724ba675SRob Herring			};
677*724ba675SRob Herring		};
678*724ba675SRob Herring	};
679*724ba675SRob Herring	g05ta03 {
680*724ba675SRob Herring		g05ta03_skomer_default: g05ta03 {
681*724ba675SRob Herring			/* Reset line, start out de-asserted */
682*724ba675SRob Herring			skomer_cfg1 {
683*724ba675SRob Herring				pins = "GPIO209_AG15";
684*724ba675SRob Herring				ste,config = <&gpio_out_hi>;
685*724ba675SRob Herring			};
686*724ba675SRob Herring			/* GPS_ON_OFF, start out deasserted (off) */
687*724ba675SRob Herring			skomer_cfg2 {
688*724ba675SRob Herring				pins = "GPIO86_C6";
689*724ba675SRob Herring				ste,config = <&gpio_out_lo>;
690*724ba675SRob Herring			};
691*724ba675SRob Herring		};
692*724ba675SRob Herring	};
693*724ba675SRob Herring};
694*724ba675SRob Herring
695*724ba675SRob Herring&ab8505_gpio {
696*724ba675SRob Herring	/* Hog a few default settings */
697*724ba675SRob Herring	pinctrl-names = "default";
698*724ba675SRob Herring	pinctrl-0 = <&gpio_default>;
699*724ba675SRob Herring
700*724ba675SRob Herring	gpio {
701*724ba675SRob Herring		gpio_default: gpio_default {
702*724ba675SRob Herring			skomer_mux {
703*724ba675SRob Herring				/* Change unused pins to GPIO mode */
704*724ba675SRob Herring				function = "gpio";
705*724ba675SRob Herring				groups = "gpio3_a_1",	/* default: SysClkReq4 */
706*724ba675SRob Herring					 "gpio14_a_1";	/* default: PWMOut1 */
707*724ba675SRob Herring			};
708*724ba675SRob Herring			skomer_cfg1 {
709*724ba675SRob Herring				pins = "GPIO11_B17", "GPIO13_D17", "GPIO50_L4";
710*724ba675SRob Herring				bias-disable;
711*724ba675SRob Herring			};
712*724ba675SRob Herring		};
713*724ba675SRob Herring	};
714*724ba675SRob Herring};
715