1 // SPDX-License-Identifier: GPL-2.0-only
3 * Devicetree for the Samsung XCover 2 GT-S7710 also known as Skomer.
7 #include "ste-db8500.dtsi"
8 #include "ste-ab8505.dtsi"
9 #include "ste-dbx5x0-pinctrl.dtsi"
10 #include <dt-bindings/gpio/gpio.h>
11 #include <dt-bindings/leds/common.h>
12 #include <dt-bindings/input/input.h>
13 #include <dt-bindings/interrupt-controller/irq.h>
16 model = "Samsung XCover 2 (GT-S7710)";
17 compatible = "samsung,skomer", "st-ericsson,u8500";
20 stdout-path = &serial2;
23 /* TI TXS0206 level translator for 2.9 V */
24 sd_level_translator: regulator-gpio {
25 compatible = "regulator-fixed";
28 gpios = <&gpio2 23 GPIO_ACTIVE_HIGH>;
31 regulator-name = "sd-level-translator";
32 regulator-min-microvolt = <2900000>;
33 regulator-max-microvolt = <2900000>;
34 regulator-type = "voltage";
36 startup-delay-us = <200>;
38 pinctrl-names = "default";
39 pinctrl-0 = <&sd_level_translator_default>;
42 /* External LDO MIC5366-3.3YMT for eMMC */
43 ldo_3v3_reg: regulator-gpio-ldo-3v3 {
44 compatible = "regulator-fixed";
45 regulator-name = "en-3v3-fixed-supply";
46 regulator-min-microvolt = <3300000>;
47 regulator-max-microvolt = <3300000>;
48 gpio = <&gpio6 31 GPIO_ACTIVE_HIGH>;
49 startup-delay-us = <5000>;
51 pinctrl-names = "default";
52 pinctrl-0 = <&emmc_ldo_en_default_mode>;
55 wlan_en: regulator-gpio-wlan-en {
56 compatible = "regulator-fixed";
57 regulator-name = "wl-reg-on";
58 regulator-min-microvolt = <3000000>;
59 regulator-max-microvolt = <3000000>;
60 startup-delay-us = <200000>;
62 gpio = <&gpio6 23 GPIO_ACTIVE_HIGH>;
64 pinctrl-names = "default";
65 pinctrl-0 = <&wlan_en_default_mode>;
69 compatible = "gpio-vibrator";
70 enable-gpios = <&gpio6 3 GPIO_ACTIVE_HIGH>;
71 pinctrl-names = "default";
72 pinctrl-0 = <&vibrator_default>;
76 compatible = "gpio-keys";
77 pinctrl-names = "default";
78 pinctrl-0 = <&gpio_keys_default_mode>;
81 linux,code = <KEY_HOME>;
84 gpios = <&gpio2 27 GPIO_ACTIVE_LOW>;
87 linux,code = <KEY_VOLUMEUP>;
90 gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
93 linux,code = <KEY_VOLUMEDOWN>;
96 gpios = <&gpio2 28 GPIO_ACTIVE_LOW>;
99 linux,code = <KEY_MENU>;
102 gpios = <&gpio6 12 GPIO_ACTIVE_LOW>;
105 linux,code = <KEY_BACK>;
108 gpios = <&gpio6 13 GPIO_ACTIVE_LOW>;
113 compatible = "kinetic,ktd253";
115 enable-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
116 /* Default to 13/32 brightness */
117 default-brightness = <13>;
118 pinctrl-names = "default";
119 pinctrl-0 = <&gpio_backlight_default_mode>;
122 /* Richtek RT8515GQW Flash LED Driver IC */
124 compatible = "richtek,rt8515";
126 enf-gpios = <&gpio4 12 GPIO_ACTIVE_HIGH>;
128 ent-gpios = <&gpio4 13 GPIO_ACTIVE_HIGH>;
130 * RFS is 16 kOhm and RTS is 100 kOhm giving
131 * the flash max current 343mA and torch max
134 richtek,rfs-ohms = <16000>;
135 richtek,rts-ohms = <100000>;
136 pinctrl-names = "default";
137 pinctrl-0 = <&gpio_flash_default_mode>;
140 function = LED_FUNCTION_FLASH;
141 color = <LED_COLOR_ID_WHITE>;
142 flash-max-timeout-us = <250000>;
143 flash-max-microamp = <343750>;
144 led-max-microamp = <55000>;
149 compatible = "i2c-gpio";
150 sda-gpios = <&gpio4 16 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
151 scl-gpios = <&gpio4 15 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
152 pinctrl-names = "default";
153 pinctrl-0 = <&i2c_gpio_0_default>;
154 #address-cells = <1>;
156 /* TODO: this should be used by the NCP6914 Camera power management unit */
160 compatible = "i2c-gpio";
161 sda-gpios = <&gpio4 24 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
162 scl-gpios = <&gpio4 23 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
163 pinctrl-names = "default";
164 pinctrl-0 = <&i2c_gpio_1_default>;
165 #address-cells = <1>;
168 compatible = "alps,hscdtd008a";
170 avdd-supply = <&ab8500_ldo_aux1_reg>;
171 dvdd-supply = <&ab8500_ldo_aux8_reg>;
176 // External Micro SD slot
178 arm,primecell-periphid = <0x10480180>;
179 max-frequency = <100000000>;
183 /* All direction control is used */
186 vmmc-supply = <&ab8500_ldo_aux3_reg>;
187 vqmmc-supply = <&sd_level_translator>;
188 pinctrl-names = "default", "sleep";
189 pinctrl-0 = <&mc0_a_1_default>;
190 pinctrl-1 = <&mc0_a_1_sleep>;
196 arm,primecell-periphid = <0x10480180>;
197 max-frequency = <50000000>;
201 vmmc-supply = <&wlan_en>;
202 pinctrl-names = "default", "sleep";
203 pinctrl-0 = <&mc1_a_2_default>;
204 pinctrl-1 = <&mc1_a_2_sleep>;
206 #address-cells = <1>;
210 compatible = "brcm,bcm4334-fmac", "brcm,bcm4329-fmac";
212 /* GPIO216 WL_HOST_WAKE */
213 interrupt-parent = <&gpio6>;
214 interrupts = <24 IRQ_TYPE_EDGE_FALLING>;
215 interrupt-names = "host-wake";
216 pinctrl-names = "default";
217 pinctrl-0 = <&wlan_default_mode>;
223 arm,primecell-periphid = <0x10480180>;
224 max-frequency = <100000000>;
231 vmmc-supply = <&ldo_3v3_reg>;
232 pinctrl-names = "default", "sleep";
233 pinctrl-0 = <&mc2_a_1_default>;
234 pinctrl-1 = <&mc2_a_1_sleep>;
239 /* GBF (Bluetooth) UART */
241 pinctrl-names = "default", "sleep";
242 pinctrl-0 = <&u0_a_1_default>;
243 pinctrl-1 = <&u0_a_1_sleep>;
246 /* FIXME: not quite working yet, probably needs regulators */
248 /* BCM4334B0 actually */
249 compatible = "brcm,bcm4330-bt";
250 shutdown-gpios = <&gpio6 30 GPIO_ACTIVE_HIGH>;
251 device-wakeup-gpios = <&gpio6 7 GPIO_ACTIVE_HIGH>;
252 host-wakeup-gpios = <&gpio3 1 GPIO_ACTIVE_HIGH>;
253 pinctrl-names = "default";
254 pinctrl-0 = <&bluetooth_default_mode>;
261 pinctrl-names = "default", "sleep";
262 pinctrl-0 = <&u1rxtx_a_1_default &u1ctsrts_a_1_default>;
263 pinctrl-1 = <&u1rxtx_a_1_sleep &u1ctsrts_a_1_sleep>;
266 /* Debugging console UART connected to AB8505 USB */
269 pinctrl-names = "default", "sleep";
270 pinctrl-0 = <&u2rxtx_c_1_default>;
271 pinctrl-1 = <&u2rxtx_c_1_sleep>;
277 pinctrl-names = "default", "sleep";
278 pinctrl-0 = <&usb_a_1_default>;
279 pinctrl-1 = <&usb_a_1_sleep>;
284 /* Used for VDD for sensors */
285 regulator-name = "AUX1";
286 regulator-min-microvolt = <3000000>;
287 regulator-max-microvolt = <3300000>;
291 /* Supplies the Cypress TMA140 touchscreen only with 3.0V */
292 regulator-name = "AUX2";
293 regulator-min-microvolt = <3000000>;
294 regulator-max-microvolt = <3000000>;
298 /* Used for voltage for external MMC/SD card */
299 regulator-name = "AUX3";
300 regulator-min-microvolt = <1100000>;
301 regulator-max-microvolt = <3300000>;
305 regulator-name = "AUX4";
306 /* Hammer to 3.0V for the display */
307 regulator-min-microvolt = <3000000>;
308 regulator-max-microvolt = <3000000>;
312 regulator-name = "AUX5";
313 /* Intended for 1V8 for touchscreen but actually left unused */
314 regulator-min-microvolt = <1050000>;
315 regulator-max-microvolt = <2790000>;
319 regulator-name = "AUX6";
320 /* Hammer to 1.8V for the display */
321 regulator-min-microvolt = <1800000>;
322 regulator-max-microvolt = <1800000>;
326 /* Mostly VIO for sensors */
327 regulator-name = "AUX8";
337 pinctrl-names = "default", "sleep";
338 pinctrl-0 = <&i2c0_a_1_default>;
339 pinctrl-1 = <&i2c0_a_1_sleep>;
342 compatible = "sharp,gp2ap002s00f";
343 clock-frequency = <400000>;
346 interrupt-parent = <&gpio4>;
347 interrupts = <18 IRQ_TYPE_EDGE_FALLING>;
348 vdd-supply = <&ab8500_ldo_aux1_reg>;
349 vio-supply = <&ab8500_ldo_aux8_reg>;
350 pinctrl-names = "default";
351 pinctrl-0 = <&gp2ap002_skomer_default>;
352 sharp,proximity-far-hysteresis = /bits/ 8 <0x2f>;
353 sharp,proximity-close-hysteresis = /bits/ 8 <0x0f>;
362 pinctrl-names = "default", "sleep";
363 pinctrl-0 = <&i2c2_b_2_default>;
364 pinctrl-1 = <&i2c2_b_2_sleep>;
367 compatible = "bosch,bma254";
368 clock-frequency = <400000>;
371 /* GPIO224 used as "smart alert" interrupt */
372 interrupt-parent = <&gpio7>;
373 interrupts = <0 IRQ_TYPE_EDGE_RISING>;
375 mount-matrix = "0", "-1", "0",
378 vdd-supply = <&ab8500_ldo_aux1_reg>;
379 vddio-supply = <&ab8500_ldo_aux8_reg>;
380 pinctrl-names = "default";
381 pinctrl-0 = <&bma254_skomer_default>;
389 pinctrl-names = "default", "sleep";
390 pinctrl-0 = <&i2c3_c_2_default>;
391 pinctrl-1 = <&i2c3_c_2_sleep>;
393 /* Cypress CY8CTMA140 touchscreen */
395 compatible = "cypress,cy8ctma140";
396 clock-frequency = <400000>;
399 touchscreen-size-x = <480>;
400 touchscreen-size-y = <800>;
401 touchscreen-max-pressure = <255>;
403 /* GPIO218 for IRQ */
404 interrupt-parent = <&gpio6>;
405 interrupts = <26 IRQ_TYPE_EDGE_FALLING>;
407 /* VDD is "digital supply" nominally 1.71-3.6V */
408 vdd-supply = <&ab8500_ldo_aux2_reg>;
409 /* VCPIN is "analog supply", 2.7-3.6 V */
410 vcpin-supply = <&ab8500_ldo_aux2_reg>;
412 pinctrl-names = "default";
413 pinctrl-0 = <&tma140_skomer_default>;
419 pinctrl-names = "default";
420 pinctrl-0 = <&dsi_default_mode>;
424 /* NT35510-based Hydis HVA40WV1 */
425 compatible = "hydis,hva40wv1", "novatek,nt35510";
427 /* v_lcd_3v0 2.3-4.8V */
428 vdd-supply = <&ab8500_ldo_aux4_reg>;
429 /* v_lcd_1v8 1.65-3.3V */
430 vddi-supply = <&ab8500_ldo_aux6_reg>;
432 reset-gpios = <&gpio4 11 GPIO_ACTIVE_LOW>;
433 pinctrl-names = "default";
434 pinctrl-0 = <&display_default_mode>;
435 backlight = <&ktd253>;
444 * This extends the MC0 default config to include DAT32DIR
445 * which is used by this machine. If we don't do this the
446 * SD card does not work.
452 /* This machine uses the DAT31 pin */
453 groups = "mc0_a_1", "mc0dat31dir_a_1";
456 pins = "GPIO21_AB3"; /* DAT31DIR */
457 ste,config = <&out_hi>;
462 /* The unused FBCLK needs to be pulled down on this machine */
466 pins = "GPIO130_C8"; /* FBCLK */
467 ste,config = <&in_pd>;
473 dsi_default_mode: dsi_default {
475 /* Mux in VSI0 used for DSI TE */
477 groups = "lcdvsi0_a_1"; /* VSI0 for LCD */
480 pins = "GPIO68_E1"; /* VSI0 */
481 ste,config = <&in_nopull>;
486 /* Two GPIO lines used by the display */
488 display_default_mode: display_default {
491 * OLED DETECT or check_pba, this appears to be high
492 * on "PBA" which I guess is "prototype board A".
495 ste,config = <&gpio_in_nopull>;
500 * MIPI_DSI0_RESET_N resets the display, leave high
501 * (de-asserted) so we only assert reset explicitly
502 * from the display driver.
504 ste,config = <&gpio_out_hi>;
509 gpio_backlight_default_mode: backlight_default {
511 pins = "GPIO69_E2"; /* LCD_BL_CTRL */
512 ste,config = <&gpio_out_lo>;
517 gpio_flash_default_mode: flash_default {
519 pins = "GPIO140_B11", "GPIO141_C12";
520 ste,config = <&gpio_out_lo>;
524 /* GPIO that enables the 2.9V SD card level translator */
525 sd-level-translator {
526 sd_level_translator_default: sd_level_translator_default {
527 /* level shifter on GPIO87 */
530 ste,config = <&gpio_out_hi>;
534 /* GPIO that enables the LDO regulator for the eMMC */
536 emmc_ldo_en_default_mode: emmc_ldo_default {
537 /* LDO enable on GPIO223 */
539 pins = "GPIO223_AH9";
540 ste,config = <&gpio_out_hi>;
546 gpio_keys_default_mode: gpio_keys_default {
548 pins = "GPIO67_G2", /* VOL UP */
549 "GPIO91_B6", /* HOME */
550 "GPIO92_D6", /* VOL DOWN */
551 "GPIO204_AF23", /* MENU */
552 "GPIO205_AG23"; /* BACK */
553 ste,config = <&gpio_in_pu>;
557 /* Interrupt line for BMA254 */
559 bma254_skomer_default: bma254_skomer {
561 pins = "GPIO224_AG9";
562 ste,config = <&gpio_in_pd>;
566 /* Interrupt line for light/proximity sensor GP2AP002 */
568 gp2ap002_skomer_default: gp2ap002_skomer {
570 pins = "GPIO146_D13";
571 ste,config = <&gpio_in_nopull>;
575 /* GPIO-based I2C bus for NCP6914 */
577 i2c_gpio_0_default: i2c_gpio_0 {
579 pins = "GPIO143_D12", "GPIO144_B13";
580 ste,config = <&gpio_in_nopull>;
584 /* GPIO-based I2C bus for ALPS HSCD compass */
586 i2c_gpio_1_default: i2c_gpio_1 {
588 pins = "GPIO151_B17", "GPIO152_D16";
589 ste,config = <&gpio_in_nopull>;
594 wlan_default_mode: wlan_default {
596 pins = "GPIO216_AG12";
597 ste,config = <&gpio_in_pd>;
600 wlan_en_default_mode: wlan_en_default {
602 pins = "GPIO215_AH13";
603 ste,config = <&gpio_out_lo>;
608 bluetooth_default_mode: bluetooth_default {
610 pins = "GPIO199_AH23", "GPIO222_AJ9";
611 ste,config = <&gpio_out_lo>;
615 ste,config = <&gpio_in_nopull>;
620 vibrator_default: vibrator_default {
622 pins = "GPIO195_AG28"; /* MOT_EN */
623 ste,config = <&gpio_out_lo>;
627 /* Interrupt line for the Cypress TMA140 touchscreen */
629 tma140_skomer_default: tma140_skomer {
631 pins = "GPIO218_AH11";
632 ste,config = <&gpio_in_nopull>;
639 /* Hog a few default settings */
640 pinctrl-names = "default";
641 pinctrl-0 = <&gpio_default>;
644 gpio_default: gpio_default {
646 /* Change unused pins to GPIO mode */
648 groups = "gpio3_a_1", /* default: SysClkReq4 */
649 "gpio14_a_1"; /* default: PWMOut1 */
652 pins = "GPIO11_B17", "GPIO13_D17", "GPIO50_L4";