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;
24 compatible = "samsung,eb485159lu";
29 /* This zone will be polled by the battery temperature code */
31 polling-delay-passive = <0>;
32 thermal-sensors = <&bat_therm>;
36 bat_therm: thermistor {
37 compatible = "samsung,1404-001221";
38 io-channels = <&gpadc 0x02>; /* BatTemp */
39 pullup-uv = <1800000>;
40 pullup-ohm = <230000>;
42 #thermal-sensor-cells = <0>;
45 /* TI TXS0206 level translator for 2.9 V */
46 sd_level_translator: regulator-gpio {
47 compatible = "regulator-fixed";
50 gpios = <&gpio2 23 GPIO_ACTIVE_HIGH>;
53 regulator-name = "sd-level-translator";
54 regulator-min-microvolt = <2900000>;
55 regulator-max-microvolt = <2900000>;
56 regulator-type = "voltage";
58 startup-delay-us = <200>;
60 pinctrl-names = "default";
61 pinctrl-0 = <&sd_level_translator_default>;
64 /* External LDO MIC5366-3.3YMT for eMMC */
65 ldo_3v3_reg: regulator-gpio-ldo-3v3 {
66 compatible = "regulator-fixed";
67 regulator-name = "en-3v3-fixed-supply";
68 regulator-min-microvolt = <3300000>;
69 regulator-max-microvolt = <3300000>;
70 gpio = <&gpio6 31 GPIO_ACTIVE_HIGH>;
71 startup-delay-us = <5000>;
73 pinctrl-names = "default";
74 pinctrl-0 = <&emmc_ldo_en_default_mode>;
77 wlan_en: regulator-gpio-wlan-en {
78 compatible = "regulator-fixed";
79 regulator-name = "wl-reg-on";
80 regulator-min-microvolt = <3000000>;
81 regulator-max-microvolt = <3000000>;
82 startup-delay-us = <200000>;
84 gpio = <&gpio6 23 GPIO_ACTIVE_HIGH>;
86 pinctrl-names = "default";
87 pinctrl-0 = <&wlan_en_default_mode>;
91 compatible = "gpio-vibrator";
92 enable-gpios = <&gpio6 3 GPIO_ACTIVE_HIGH>;
93 pinctrl-names = "default";
94 pinctrl-0 = <&vibrator_default>;
98 compatible = "gpio-keys";
99 pinctrl-names = "default";
100 pinctrl-0 = <&gpio_keys_default_mode>;
103 linux,code = <KEY_HOME>;
106 gpios = <&gpio2 27 GPIO_ACTIVE_LOW>;
109 linux,code = <KEY_VOLUMEUP>;
112 gpios = <&gpio2 3 GPIO_ACTIVE_LOW>;
115 linux,code = <KEY_VOLUMEDOWN>;
118 gpios = <&gpio2 28 GPIO_ACTIVE_LOW>;
121 linux,code = <KEY_MENU>;
124 gpios = <&gpio6 12 GPIO_ACTIVE_LOW>;
127 linux,code = <KEY_BACK>;
130 gpios = <&gpio6 13 GPIO_ACTIVE_LOW>;
135 compatible = "kinetic,ktd253";
137 enable-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
138 /* Default to 13/32 brightness */
139 default-brightness = <13>;
140 pinctrl-names = "default";
141 pinctrl-0 = <&gpio_backlight_default_mode>;
144 /* Richtek RT8515GQW Flash LED Driver IC */
146 compatible = "richtek,rt8515";
148 enf-gpios = <&gpio4 12 GPIO_ACTIVE_HIGH>;
150 ent-gpios = <&gpio4 13 GPIO_ACTIVE_HIGH>;
152 * RFS is 16 kOhm and RTS is 100 kOhm giving
153 * the flash max current 343mA and torch max
156 richtek,rfs-ohms = <16000>;
157 richtek,rts-ohms = <100000>;
158 pinctrl-names = "default";
159 pinctrl-0 = <&gpio_flash_default_mode>;
162 function = LED_FUNCTION_FLASH;
163 color = <LED_COLOR_ID_WHITE>;
164 flash-max-timeout-us = <250000>;
165 flash-max-microamp = <343750>;
166 led-max-microamp = <55000>;
171 compatible = "i2c-gpio";
172 sda-gpios = <&gpio4 16 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
173 scl-gpios = <&gpio4 15 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
174 pinctrl-names = "default";
175 pinctrl-0 = <&i2c_gpio_0_default>;
176 #address-cells = <1>;
178 /* TODO: this should be used by the NCP6914 Camera power management unit */
182 compatible = "i2c-gpio";
183 sda-gpios = <&gpio4 24 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
184 scl-gpios = <&gpio4 23 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
185 pinctrl-names = "default";
186 pinctrl-0 = <&i2c_gpio_1_default>;
187 #address-cells = <1>;
190 compatible = "alps,hscdtd008a";
192 avdd-supply = <&ab8500_ldo_aux1_reg>;
193 dvdd-supply = <&ab8500_ldo_aux8_reg>;
198 // External Micro SD slot
200 arm,primecell-periphid = <0x10480180>;
201 max-frequency = <100000000>;
205 /* All direction control is used */
208 vmmc-supply = <&ab8500_ldo_aux3_reg>;
209 vqmmc-supply = <&sd_level_translator>;
210 pinctrl-names = "default", "sleep";
211 pinctrl-0 = <&mc0_a_1_default>;
212 pinctrl-1 = <&mc0_a_1_sleep>;
218 arm,primecell-periphid = <0x10480180>;
219 max-frequency = <50000000>;
223 vmmc-supply = <&wlan_en>;
224 pinctrl-names = "default", "sleep";
225 pinctrl-0 = <&mc1_a_2_default>;
226 pinctrl-1 = <&mc1_a_2_sleep>;
228 #address-cells = <1>;
232 compatible = "brcm,bcm4334-fmac", "brcm,bcm4329-fmac";
234 /* GPIO216 WL_HOST_WAKE */
235 interrupt-parent = <&gpio6>;
236 interrupts = <24 IRQ_TYPE_EDGE_FALLING>;
237 interrupt-names = "host-wake";
238 pinctrl-names = "default";
239 pinctrl-0 = <&wlan_default_mode>;
244 * eMMC seems to be mostly Samsung KLM4G1YE4C "4YMD1R"
247 arm,primecell-periphid = <0x10480180>;
248 max-frequency = <100000000>;
255 /* From datasheet page 26 figure 9: 300 ms set-up time for 4GB */
256 post-power-on-delay-ms = <300>;
257 vmmc-supply = <&ldo_3v3_reg>;
258 pinctrl-names = "default", "sleep";
259 pinctrl-0 = <&mc2_a_1_default>;
260 pinctrl-1 = <&mc2_a_1_sleep>;
265 /* GBF (Bluetooth) UART */
267 pinctrl-names = "default", "sleep";
268 pinctrl-0 = <&u0_a_1_default>;
269 pinctrl-1 = <&u0_a_1_sleep>;
272 /* FIXME: not quite working yet, probably needs regulators */
274 /* BCM4334B0 actually */
275 compatible = "brcm,bcm4330-bt";
276 shutdown-gpios = <&gpio6 30 GPIO_ACTIVE_HIGH>;
277 device-wakeup-gpios = <&gpio6 7 GPIO_ACTIVE_HIGH>;
278 host-wakeup-gpios = <&gpio3 1 GPIO_ACTIVE_HIGH>;
279 pinctrl-names = "default";
280 pinctrl-0 = <&bluetooth_default_mode>;
287 pinctrl-names = "default", "sleep";
288 pinctrl-0 = <&u1rxtx_a_1_default &u1ctsrts_a_1_default>;
289 pinctrl-1 = <&u1rxtx_a_1_sleep &u1ctsrts_a_1_sleep>;
292 /* The CSRG05TA03-ICJE-R is a SirfStarV 5t chip */
293 compatible = "csr,csrg05ta03-icje-r";
294 /* GPS_RSTN on GPIO209 */
295 reset-gpios = <&gpio6 17 GPIO_ACTIVE_LOW>;
296 /* GPS_ON_OFF on GPIO86 */
297 sirf,onoff-gpios = <&gpio2 22 GPIO_ACTIVE_HIGH>;
298 /* GPS_1V8 (VSMPS2) */
299 vcc-supply = <&db8500_vsmps2_reg>;
300 pinctrl-names = "default";
301 pinctrl-0 = <&g05ta03_skomer_default>;
302 /* According to /etc/sirfgps.conf */
303 current-speed = <460800>;
307 /* Debugging console UART connected to AB8505 USB */
310 pinctrl-names = "default", "sleep";
311 pinctrl-0 = <&u2rxtx_c_1_default>;
312 pinctrl-1 = <&u2rxtx_c_1_sleep>;
318 pinctrl-names = "default", "sleep";
319 pinctrl-0 = <&usb_a_1_default>;
320 pinctrl-1 = <&usb_a_1_sleep>;
324 line-impedance-micro-ohms = <16000>;
329 /* Used for VDD for sensors */
330 regulator-name = "AUX1";
331 regulator-min-microvolt = <3000000>;
332 regulator-max-microvolt = <3300000>;
336 /* Supplies the Cypress TMA140 touchscreen only with 3.0V */
337 regulator-name = "AUX2";
338 regulator-min-microvolt = <3000000>;
339 regulator-max-microvolt = <3000000>;
343 /* Used for voltage for external MMC/SD card */
344 regulator-name = "AUX3";
345 regulator-min-microvolt = <1100000>;
346 regulator-max-microvolt = <3300000>;
350 regulator-name = "AUX4";
351 /* Hammer to 3.0V for the display */
352 regulator-min-microvolt = <3000000>;
353 regulator-max-microvolt = <3000000>;
357 regulator-name = "AUX5";
358 /* Intended for 1V8 for touchscreen but actually left unused */
359 regulator-min-microvolt = <1050000>;
360 regulator-max-microvolt = <2790000>;
364 regulator-name = "AUX6";
365 /* Hammer to 1.8V for the display */
366 regulator-min-microvolt = <1800000>;
367 regulator-max-microvolt = <1800000>;
371 /* Mostly VIO for sensors */
372 regulator-name = "AUX8";
382 pinctrl-names = "default", "sleep";
383 pinctrl-0 = <&i2c0_a_1_default>;
384 pinctrl-1 = <&i2c0_a_1_sleep>;
387 compatible = "sharp,gp2ap002s00f";
388 clock-frequency = <400000>;
391 interrupt-parent = <&gpio4>;
392 interrupts = <18 IRQ_TYPE_EDGE_FALLING>;
393 vdd-supply = <&ab8500_ldo_aux1_reg>;
394 vio-supply = <&ab8500_ldo_aux8_reg>;
395 pinctrl-names = "default";
396 pinctrl-0 = <&gp2ap002_skomer_default>;
397 sharp,proximity-far-hysteresis = /bits/ 8 <0x2f>;
398 sharp,proximity-close-hysteresis = /bits/ 8 <0x0f>;
407 pinctrl-names = "default", "sleep";
408 pinctrl-0 = <&i2c2_b_2_default>;
409 pinctrl-1 = <&i2c2_b_2_sleep>;
412 compatible = "bosch,bma254";
413 clock-frequency = <400000>;
416 /* GPIO224 used as "smart alert" interrupt */
417 interrupt-parent = <&gpio7>;
418 interrupts = <0 IRQ_TYPE_EDGE_RISING>;
420 mount-matrix = "0", "-1", "0",
423 vdd-supply = <&ab8500_ldo_aux1_reg>;
424 vddio-supply = <&ab8500_ldo_aux8_reg>;
425 pinctrl-names = "default";
426 pinctrl-0 = <&bma254_skomer_default>;
434 pinctrl-names = "default", "sleep";
435 pinctrl-0 = <&i2c3_c_2_default>;
436 pinctrl-1 = <&i2c3_c_2_sleep>;
438 /* Cypress CY8CTMA140 touchscreen */
440 compatible = "cypress,cy8ctma140";
441 clock-frequency = <400000>;
444 touchscreen-size-x = <480>;
445 touchscreen-size-y = <800>;
446 touchscreen-max-pressure = <255>;
448 /* GPIO218 for IRQ */
449 interrupt-parent = <&gpio6>;
450 interrupts = <26 IRQ_TYPE_EDGE_FALLING>;
452 /* VDD is "digital supply" nominally 1.71-3.6V */
453 vdd-supply = <&ab8500_ldo_aux2_reg>;
454 /* VCPIN is "analog supply", 2.7-3.6 V */
455 vcpin-supply = <&ab8500_ldo_aux2_reg>;
457 pinctrl-names = "default";
458 pinctrl-0 = <&tma140_skomer_default>;
464 pinctrl-names = "default";
465 pinctrl-0 = <&dsi_default_mode>;
469 /* NT35510-based Hydis HVA40WV1 */
470 compatible = "hydis,hva40wv1", "novatek,nt35510";
472 /* v_lcd_3v0 2.3-4.8V */
473 vdd-supply = <&ab8500_ldo_aux4_reg>;
474 /* v_lcd_1v8 1.65-3.3V */
475 vddi-supply = <&ab8500_ldo_aux6_reg>;
477 reset-gpios = <&gpio4 11 GPIO_ACTIVE_LOW>;
478 pinctrl-names = "default";
479 pinctrl-0 = <&display_default_mode>;
480 backlight = <&ktd253>;
491 /* GPIO18, 19 & 20 unused so pull down */
492 ste,config = <&gpio_in_pd>;
497 /* This is a reset line for the eMMC */
501 pins = "GPIO130_C8"; /* FBCLK */
502 ste,config = <&gpio_in_pd>;
508 dsi_default_mode: dsi_default {
510 /* Mux in VSI0 used for DSI TE */
512 groups = "lcdvsi0_a_1"; /* VSI0 for LCD */
515 pins = "GPIO68_E1"; /* VSI0 */
516 ste,config = <&in_nopull>;
521 /* Two GPIO lines used by the display */
523 display_default_mode: display_default {
526 * OLED DETECT or check_pba, this appears to be high
527 * on "PBA" which I guess is "prototype board A".
530 ste,config = <&gpio_in_nopull>;
535 * MIPI_DSI0_RESET_N resets the display, leave high
536 * (de-asserted) so we only assert reset explicitly
537 * from the display driver.
539 ste,config = <&gpio_out_hi>;
544 gpio_backlight_default_mode: backlight_default {
546 pins = "GPIO69_E2"; /* LCD_BL_CTRL */
547 ste,config = <&gpio_out_lo>;
552 gpio_flash_default_mode: flash_default {
554 pins = "GPIO140_B11", "GPIO141_C12";
555 ste,config = <&gpio_out_lo>;
559 /* GPIO that enables the 2.9V SD card level translator */
560 sd-level-translator {
561 sd_level_translator_default: sd_level_translator_default {
562 /* level shifter on GPIO87 */
565 ste,config = <&gpio_out_hi>;
569 /* GPIO that enables the LDO regulator for the eMMC */
571 emmc_ldo_en_default_mode: emmc_ldo_default {
572 /* LDO enable on GPIO223 */
574 pins = "GPIO223_AH9";
575 ste,config = <&gpio_out_hi>;
581 gpio_keys_default_mode: gpio_keys_default {
583 pins = "GPIO67_G2", /* VOL UP */
584 "GPIO91_B6", /* HOME */
585 "GPIO92_D6", /* VOL DOWN */
586 "GPIO204_AF23", /* MENU */
587 "GPIO205_AG23"; /* BACK */
588 ste,config = <&gpio_in_pu>;
592 /* Interrupt line for BMA254 */
594 bma254_skomer_default: bma254_skomer {
596 pins = "GPIO224_AG9";
597 ste,config = <&gpio_in_pd>;
601 /* Interrupt line for light/proximity sensor GP2AP002 */
603 gp2ap002_skomer_default: gp2ap002_skomer {
605 pins = "GPIO146_D13";
606 ste,config = <&gpio_in_nopull>;
610 /* GPIO-based I2C bus for NCP6914 */
612 i2c_gpio_0_default: i2c_gpio_0 {
614 pins = "GPIO143_D12", "GPIO144_B13";
615 ste,config = <&gpio_in_nopull>;
619 /* GPIO-based I2C bus for ALPS HSCD compass */
621 i2c_gpio_1_default: i2c_gpio_1 {
623 pins = "GPIO151_B17", "GPIO152_D16";
624 ste,config = <&gpio_in_nopull>;
629 wlan_default_mode: wlan_default {
631 pins = "GPIO216_AG12";
632 ste,config = <&gpio_in_pd>;
635 wlan_en_default_mode: wlan_en_default {
637 pins = "GPIO215_AH13";
638 ste,config = <&gpio_out_lo>;
643 bluetooth_default_mode: bluetooth_default {
645 pins = "GPIO199_AH23", "GPIO222_AJ9";
646 ste,config = <&gpio_out_lo>;
650 ste,config = <&gpio_in_nopull>;
655 vibrator_default: vibrator_default {
657 pins = "GPIO195_AG28"; /* MOT_EN */
658 ste,config = <&gpio_out_lo>;
662 /* Interrupt line for the Cypress TMA140 touchscreen */
664 tma140_skomer_default: tma140_skomer {
666 pins = "GPIO218_AH11";
667 ste,config = <&gpio_in_nopull>;
672 g05ta03_skomer_default: g05ta03 {
673 /* Reset line, start out de-asserted */
675 pins = "GPIO209_AG15";
676 ste,config = <&gpio_out_hi>;
678 /* GPS_ON_OFF, start out deasserted (off) */
681 ste,config = <&gpio_out_lo>;
688 /* Hog a few default settings */
689 pinctrl-names = "default";
690 pinctrl-0 = <&gpio_default>;
693 gpio_default: gpio_default {
695 /* Change unused pins to GPIO mode */
697 groups = "gpio3_a_1", /* default: SysClkReq4 */
698 "gpio14_a_1"; /* default: PWMOut1 */
701 pins = "GPIO11_B17", "GPIO13_D17", "GPIO50_L4";