2 * Copyright (c) 2015, The Linux Foundation. All rights reserved.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 and
6 * only version 2 as published by the Free Software Foundation.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
14 #include "msm8916.dtsi"
15 #include "pm8916.dtsi"
16 #include "apq8016-sbc-soc-pins.dtsi"
17 #include "apq8016-sbc-pmic-pins.dtsi"
18 #include <dt-bindings/gpio/gpio.h>
19 #include <dt-bindings/input/input.h>
20 #include <dt-bindings/sound/apq8016-lpass.h>
23 * GPIO name legend: proper name = the GPIO line is used as GPIO
24 * NC = not connected (pin out but not routed from the chip to
26 * "[PER]" = pin is muxed for [peripheral] (not GPIO)
27 * LSEC = Low Speed External Connector
28 * HSEC = High Speed External Connector
30 * Line names are taken from the schematic "DragonBoard410c"
31 * dated monday, august 31, 2015. Page 5 in particular.
33 * For the lines routed to the external connectors the
34 * lines are named after the 96Boards CE Specification 1.0,
35 * Appendix "Expansion Connector Signal Description".
37 * When the 96Board naming of a line and the schematic name of
38 * the same line are in conflict, the 96Board specification
39 * takes precedence, which means that the external UART on the
40 * LSEC is named UART0 while the schematic and SoC names this
41 * UART3. This is only for the informational lines i.e. "[FOO]",
42 * the GPIO named lines "GPIO-A" thru "GPIO-L" are the only
43 * ones actually used for GPIO.
48 serial0 = &blsp1_uart2;
49 serial1 = &blsp1_uart1;
59 stdout-path = "serial0";
64 compatible = "ramoops";
65 reg = <0x0 0xbff00000 0x0 0x100000>;
67 record-size = <0x20000>;
68 console-size = <0x20000>;
69 ftrace-size = <0x20000>;
76 "[UART0_TX]", /* GPIO_0, LSEC pin 5 */
77 "[UART0_RX]", /* GPIO_1, LSEC pin 7 */
78 "[UART0_CTS_N]", /* GPIO_2, LSEC pin 3 */
79 "[UART0_RTS_N]", /* GPIO_3, LSEC pin 9 */
80 "[UART1_TX]", /* GPIO_4, LSEC pin 11 */
81 "[UART1_RX]", /* GPIO_5, LSEC pin 13 */
82 "[I2C0_SDA]", /* GPIO_8, LSEC pin 17 */
83 "[I2C0_SCL]", /* GPIO_7, LSEC pin 15 */
84 "[SPI1_DOUT]", /* SPI1_MOSI, HSEC pin 1 */
85 "[SPI1_DIN]", /* SPI1_MISO, HSEC pin 11 */
86 "[SPI1_CS]", /* SPI1_CS_N, HSEC pin 7 */
87 "[SPI1_SCLK]", /* SPI1_CLK, HSEC pin 9 */
88 "GPIO-B", /* LS_EXP_GPIO_B, LSEC pin 24 */
89 "GPIO-C", /* LS_EXP_GPIO_C, LSEC pin 25 */
90 "[I2C3_SDA]", /* HSEC pin 38 */
91 "[I2C3_SCL]", /* HSEC pin 36 */
92 "[SPI0_MOSI]", /* LSEC pin 14 */
93 "[SPI0_MISO]", /* LSEC pin 10 */
94 "[SPI0_CS_N]", /* LSEC pin 12 */
95 "[SPI0_CLK]", /* LSEC pin 8 */
96 "HDMI_HPD_N", /* GPIO 20 */
98 "[I2C1_SDA]", /* GPIO_22, LSEC pin 21 */
99 "[I2C1_SCL]", /* GPIO_23, LSEC pin 19 */
100 "GPIO-G", /* LS_EXP_GPIO_G, LSEC pin 29 */
101 "GPIO-H", /* LS_EXP_GPIO_H, LSEC pin 30 */
102 "[CSI0_MCLK]", /* HSEC pin 15 */
103 "[CSI1_MCLK]", /* HSEC pin 17 */
104 "GPIO-K", /* LS_EXP_GPIO_K, LSEC pin 33 */
105 "[I2C2_SDA]", /* HSEC pin 34 */
106 "[I2C2_SCL]", /* HSEC pin 32 */
109 "GPIO-L", /* LS_EXP_GPIO_L, LSEC pin 34 */
110 "GPIO-J", /* LS_EXP_GPIO_J, LSEC pin 32 */
111 "GPIO-I", /* LS_EXP_GPIO_I, LSEC pin 31 */
112 "GPIO-A", /* LS_EXP_GPIO_A, LSEC pin 23 */
116 "[WCSS_WLAN_DATA_2]", /* GPIO 40 */
117 "[WCSS_WLAN_DATA_1]",
118 "[WCSS_WLAN_DATA_0]",
145 "GPIO-D", /* LS_EXP_GPIO_D, LSEC pin 26 */
156 "BOOT_CONFIG_0", /* GPIO 80 */
186 "[LS_EXP_MI2S_WS]", /* GPIO 110 */
190 "[LS_EXP_MI2S_DATA0]",
191 "GPIO-E", /* LS_EXP_GPIO_E, LSEC pin 27 */
193 "[DSI2HDMI_MI2S_WS]",
194 "[DSI2HDMI_MI2S_SCK]",
195 "[DSI2HDMI_MI2S_DATA0]",
196 "USR_LED_2_CTRL", /* GPIO 120 */
207 pinctrl-names = "default", "sleep";
208 pinctrl-0 = <&blsp1_uart1_default>;
209 pinctrl-1 = <&blsp1_uart1_sleep>;
215 pinctrl-names = "default", "sleep";
216 pinctrl-0 = <&blsp1_uart2_default>;
217 pinctrl-1 = <&blsp1_uart2_sleep>;
221 /* On Low speed expansion */
227 /* On High speed expansion */
231 adv_bridge: bridge@39 {
234 compatible = "adi,adv7533";
237 interrupt-parent = <&msmgpio>;
241 clocks = <&rpmcc RPM_SMD_BB_CLK2>;
244 pd-gpios = <&msmgpio 32 0>;
246 avdd-supply = <&pm8916_l6>;
247 v1p2-supply = <&pm8916_l6>;
248 v3p3-supply = <&pm8916_l17>;
250 pinctrl-names = "default","sleep";
251 pinctrl-0 = <&adv7533_int_active &adv7533_switch_active>;
252 pinctrl-1 = <&adv7533_int_suspend &adv7533_switch_suspend>;
253 #sound-dai-cells = <1>;
256 #address-cells = <1>;
261 adv7533_in: endpoint {
262 remote-endpoint = <&dsi0_out>;
268 adv7533_out: endpoint {
269 remote-endpoint = <&hdmi_con>;
277 /* On Low speed expansion */
283 /* On High speed expansion */
289 /* On Low speed expansion */
295 pinctrl-names = "default";
296 pinctrl-0 = <&msmgpio_leds>,
297 <&pm8916_gpios_leds>,
300 compatible = "gpio-leds";
303 label = "apq8016-sbc:green:user1";
304 gpios = <&msmgpio 21 GPIO_ACTIVE_HIGH>;
305 linux,default-trigger = "heartbeat";
306 default-state = "off";
310 label = "apq8016-sbc:green:user2";
311 gpios = <&msmgpio 120 GPIO_ACTIVE_HIGH>;
312 linux,default-trigger = "mmc0";
313 default-state = "off";
317 label = "apq8016-sbc:green:user3";
318 gpios = <&pm8916_gpios 1 GPIO_ACTIVE_HIGH>;
319 linux,default-trigger = "mmc1";
320 default-state = "off";
324 label = "apq8016-sbc:green:user4";
325 gpios = <&pm8916_gpios 2 GPIO_ACTIVE_HIGH>;
326 linux,default-trigger = "none";
328 default-state = "off";
332 label = "apq8016-sbc:yellow:wlan";
333 gpios = <&pm8916_mpps 2 GPIO_ACTIVE_HIGH>;
334 linux,default-trigger = "phy0tx";
335 default-state = "off";
339 label = "apq8016-sbc:blue:bt";
340 gpios = <&pm8916_mpps 3 GPIO_ACTIVE_HIGH>;
341 linux,default-trigger = "bt";
342 default-state = "off";
347 vmmc-supply = <&pm8916_l8>;
348 vqmmc-supply = <&pm8916_l5>;
350 pinctrl-names = "default", "sleep";
351 pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>;
352 pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>;
357 vmmc-supply = <&pm8916_l11>;
358 vqmmc-supply = <&pm8916_l12>;
360 pinctrl-names = "default", "sleep";
361 pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on &sdc2_cd_on>;
362 pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off &sdc2_cd_off>;
364 cd-gpios = <&msmgpio 38 0x1>;
375 pinctrl-names = "default";
376 pinctrl-0 = <&usb_sw_sel_pm>;
379 v1p8-supply = <&pm8916_l7>;
380 v3p3-supply = <&pm8916_l13>;
400 vdda-supply = <&pm8916_l2>;
401 vddio-supply = <&pm8916_l6>;
406 remote-endpoint = <&adv7533_in>;
407 data-lanes = <0 1 2 3>;
416 vddio-supply = <&pm8916_l6>;
426 playback - Primary MI2S
430 playback - secondary MI2S
440 compatible = "qcom,apq8016-sbc-sndcard";
441 reg = <0x07702000 0x4>, <0x07702004 0x4>;
442 reg-names = "mic-iomux", "spkr-iomux";
445 pinctrl-0 = <&cdc_pdm_lines_act &ext_sec_tlmm_lines_act &ext_mclk_tlmm_lines_act>;
446 pinctrl-1 = <&cdc_pdm_lines_sus &ext_sec_tlmm_lines_sus &ext_mclk_tlmm_lines_sus>;
447 pinctrl-names = "default", "sleep";
448 qcom,model = "DB410c";
450 "AMIC2", "MIC BIAS Internal2",
451 "AMIC3", "MIC BIAS External1";
452 external-dai-link@0 {
453 link-name = "ADV7533";
455 sound-dai = <&lpass MI2S_QUATERNARY>;
458 sound-dai = <&adv_bridge 0>;
462 internal-codec-playback-dai-link@0 { /* I2S - Internal codec */
465 sound-dai = <&lpass MI2S_PRIMARY>;
468 sound-dai = <&lpass_codec 0>, <&wcd_codec 0>;
472 internal-codec-capture-dai-link@0 { /* I2S - Internal codec */
473 link-name = "WCD-Capture";
475 sound-dai = <&lpass MI2S_TERTIARY>;
478 sound-dai = <&lpass_codec 1>, <&wcd_codec 1>;
489 "USB_HUB_RESET_N_PM",
497 "GPIO-F"; /* LS_EXP_GPIO_F, LSEC pin 28 */
508 compatible = "smsc,usb3503";
509 reset-gpios = <&pm8916_gpios 3 GPIO_ACTIVE_LOW>;
514 compatible = "linux,extcon-usb-gpio";
515 vbus-gpio = <&msmgpio 121 GPIO_ACTIVE_HIGH>;
516 pinctrl-names = "default";
517 pinctrl-0 = <&usb_id_default>;
521 compatible = "hdmi-connector";
526 remote-endpoint = <&adv7533_out>;
532 compatible = "gpio-keys";
533 #address-cells = <1>;
537 pinctrl-names = "default";
538 pinctrl-0 = <&msm_key_volp_n_default>;
542 linux,code = <KEY_VOLUMEUP>;
543 gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>;
550 clocks = <&gcc GCC_CODEC_DIGCODEC_CLK>;
551 clock-names = "mclk";
552 qcom,mbhc-vthreshold-low = <75 150 237 450 500>;
553 qcom,mbhc-vthreshold-high = <75 150 237 450 500>;
556 &smd_rpm_regulators {
557 vdd_l1_l2_l3-supply = <&pm8916_s3>;
558 vdd_l5-supply = <&pm8916_s3>;
559 vdd_l4_l5_l6-supply = <&pm8916_s4>;
560 vdd_l7-supply = <&pm8916_s4>;
563 regulator-min-microvolt = <375000>;
564 regulator-max-microvolt = <1562000>;
568 regulator-min-microvolt = <375000>;
569 regulator-max-microvolt = <1562000>;
573 regulator-min-microvolt = <1800000>;
574 regulator-max-microvolt = <1800000>;
581 regulator-min-microvolt = <375000>;
582 regulator-max-microvolt = <1525000>;
586 regulator-min-microvolt = <1200000>;
587 regulator-max-microvolt = <1200000>;
591 regulator-min-microvolt = <375000>;
592 regulator-max-microvolt = <1525000>;
596 regulator-min-microvolt = <1750000>;
597 regulator-max-microvolt = <3337000>;
601 regulator-min-microvolt = <1750000>;
602 regulator-max-microvolt = <3337000>;
606 regulator-min-microvolt = <1800000>;
607 regulator-max-microvolt = <1800000>;
611 regulator-min-microvolt = <1750000>;
612 regulator-max-microvolt = <3337000>;
616 regulator-min-microvolt = <1750000>;
617 regulator-max-microvolt = <3337000>;
621 regulator-min-microvolt = <1750000>;
622 regulator-max-microvolt = <3337000>;
626 regulator-min-microvolt = <1750000>;
627 regulator-max-microvolt = <3337000>;
631 regulator-min-microvolt = <1750000>;
632 regulator-max-microvolt = <3337000>;
636 regulator-min-microvolt = <1750000>;
637 regulator-max-microvolt = <3337000>;
641 regulator-min-microvolt = <1750000>;
642 regulator-max-microvolt = <3337000>;
646 regulator-min-microvolt = <1750000>;
647 regulator-max-microvolt = <3337000>;
651 * 1.8v required on LS expansion
652 * for mezzanine boards
655 regulator-min-microvolt = <1750000>;
656 regulator-max-microvolt = <3337000>;
661 regulator-min-microvolt = <1750000>;
662 regulator-max-microvolt = <3337000>;
666 regulator-min-microvolt = <3300000>;
667 regulator-max-microvolt = <3300000>;
671 regulator-min-microvolt = <1750000>;
672 regulator-max-microvolt = <3337000>;