1 // SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (c) 2015, The Linux Foundation. All rights reserved.
6 #include "msm8916.dtsi"
8 #include <dt-bindings/gpio/gpio.h>
9 #include <dt-bindings/input/input.h>
10 #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
11 #include <dt-bindings/pinctrl/qcom,pmic-mpp.h>
12 #include <dt-bindings/sound/apq8016-lpass.h>
15 * GPIO name legend: proper name = the GPIO line is used as GPIO
16 * NC = not connected (pin out but not routed from the chip to
18 * "[PER]" = pin is muxed for [peripheral] (not GPIO)
19 * LSEC = Low Speed External Connector
20 * HSEC = High Speed External Connector
22 * Line names are taken from the schematic "DragonBoard410c"
23 * dated monday, august 31, 2015. Page 5 in particular.
25 * For the lines routed to the external connectors the
26 * lines are named after the 96Boards CE Specification 1.0,
27 * Appendix "Expansion Connector Signal Description".
29 * When the 96Board naming of a line and the schematic name of
30 * the same line are in conflict, the 96Board specification
31 * takes precedence, which means that the external UART on the
32 * LSEC is named UART0 while the schematic and SoC names this
33 * UART3. This is only for the informational lines i.e. "[FOO]",
34 * the GPIO named lines "GPIO-A" thru "GPIO-L" are the only
35 * ones actually used for GPIO.
40 serial0 = &blsp1_uart2;
41 serial1 = &blsp1_uart1;
51 stdout-path = "serial0";
54 camera_vdddo_1v8: camera-vdddo-1v8 {
55 compatible = "regulator-fixed";
56 regulator-name = "camera_vdddo";
57 regulator-min-microvolt = <1800000>;
58 regulator-max-microvolt = <1800000>;
62 camera_vdda_2v8: camera-vdda-2v8 {
63 compatible = "regulator-fixed";
64 regulator-name = "camera_vdda";
65 regulator-min-microvolt = <2800000>;
66 regulator-max-microvolt = <2800000>;
70 camera_vddd_1v5: camera-vddd-1v5 {
71 compatible = "regulator-fixed";
72 regulator-name = "camera_vddd";
73 regulator-min-microvolt = <1500000>;
74 regulator-max-microvolt = <1500000>;
80 compatible = "ramoops";
81 reg = <0x0 0xbff00000 0x0 0x100000>;
83 record-size = <0x20000>;
84 console-size = <0x20000>;
85 ftrace-size = <0x20000>;
92 "[UART0_TX]", /* GPIO_0, LSEC pin 5 */
93 "[UART0_RX]", /* GPIO_1, LSEC pin 7 */
94 "[UART0_CTS_N]", /* GPIO_2, LSEC pin 3 */
95 "[UART0_RTS_N]", /* GPIO_3, LSEC pin 9 */
96 "[UART1_TX]", /* GPIO_4, LSEC pin 11 */
97 "[UART1_RX]", /* GPIO_5, LSEC pin 13 */
98 "[I2C0_SDA]", /* GPIO_8, LSEC pin 17 */
99 "[I2C0_SCL]", /* GPIO_7, LSEC pin 15 */
100 "[SPI1_DOUT]", /* SPI1_MOSI, HSEC pin 1 */
101 "[SPI1_DIN]", /* SPI1_MISO, HSEC pin 11 */
102 "[SPI1_CS]", /* SPI1_CS_N, HSEC pin 7 */
103 "[SPI1_SCLK]", /* SPI1_CLK, HSEC pin 9 */
104 "GPIO-B", /* LS_EXP_GPIO_B, LSEC pin 24 */
105 "GPIO-C", /* LS_EXP_GPIO_C, LSEC pin 25 */
106 "[I2C3_SDA]", /* HSEC pin 38 */
107 "[I2C3_SCL]", /* HSEC pin 36 */
108 "[SPI0_MOSI]", /* LSEC pin 14 */
109 "[SPI0_MISO]", /* LSEC pin 10 */
110 "[SPI0_CS_N]", /* LSEC pin 12 */
111 "[SPI0_CLK]", /* LSEC pin 8 */
112 "HDMI_HPD_N", /* GPIO 20 */
114 "[I2C1_SDA]", /* GPIO_22, LSEC pin 21 */
115 "[I2C1_SCL]", /* GPIO_23, LSEC pin 19 */
116 "GPIO-G", /* LS_EXP_GPIO_G, LSEC pin 29 */
117 "GPIO-H", /* LS_EXP_GPIO_H, LSEC pin 30 */
118 "[CSI0_MCLK]", /* HSEC pin 15 */
119 "[CSI1_MCLK]", /* HSEC pin 17 */
120 "GPIO-K", /* LS_EXP_GPIO_K, LSEC pin 33 */
121 "[I2C2_SDA]", /* HSEC pin 34 */
122 "[I2C2_SCL]", /* HSEC pin 32 */
125 "GPIO-L", /* LS_EXP_GPIO_L, LSEC pin 34 */
126 "GPIO-J", /* LS_EXP_GPIO_J, LSEC pin 32 */
127 "GPIO-I", /* LS_EXP_GPIO_I, LSEC pin 31 */
128 "GPIO-A", /* LS_EXP_GPIO_A, LSEC pin 23 */
132 "[WCSS_WLAN_DATA_2]", /* GPIO 40 */
133 "[WCSS_WLAN_DATA_1]",
134 "[WCSS_WLAN_DATA_0]",
161 "GPIO-D", /* LS_EXP_GPIO_D, LSEC pin 26 */
172 "BOOT_CONFIG_0", /* GPIO 80 */
202 "[LS_EXP_MI2S_WS]", /* GPIO 110 */
206 "[LS_EXP_MI2S_DATA0]",
207 "GPIO-E", /* LS_EXP_GPIO_E, LSEC pin 27 */
209 "[DSI2HDMI_MI2S_WS]",
210 "[DSI2HDMI_MI2S_SCK]",
211 "[DSI2HDMI_MI2S_DATA0]",
212 "USR_LED_2_CTRL", /* GPIO 120 */
223 pinctrl-names = "default", "sleep";
224 pinctrl-0 = <&blsp1_uart1_default>;
225 pinctrl-1 = <&blsp1_uart1_sleep>;
231 pinctrl-names = "default", "sleep";
232 pinctrl-0 = <&blsp1_uart2_default>;
233 pinctrl-1 = <&blsp1_uart2_sleep>;
237 /* On Low speed expansion */
243 /* On High speed expansion */
247 adv_bridge: bridge@39 {
250 compatible = "adi,adv7533";
253 interrupt-parent = <&msmgpio>;
257 clocks = <&rpmcc RPM_SMD_BB_CLK2>;
260 pd-gpios = <&msmgpio 32 0>;
262 avdd-supply = <&pm8916_l6>;
263 v1p2-supply = <&pm8916_l6>;
264 v3p3-supply = <&pm8916_l17>;
266 pinctrl-names = "default","sleep";
267 pinctrl-0 = <&adv7533_int_active &adv7533_switch_active>;
268 pinctrl-1 = <&adv7533_int_suspend &adv7533_switch_suspend>;
269 #sound-dai-cells = <1>;
272 #address-cells = <1>;
277 adv7533_in: endpoint {
278 remote-endpoint = <&dsi0_out>;
284 adv7533_out: endpoint {
285 remote-endpoint = <&hdmi_con>;
293 /* On Low speed expansion */
299 /* On High speed expansion */
305 /* On Low speed expansion */
311 pinctrl-names = "default";
312 pinctrl-0 = <&msmgpio_leds>,
313 <&pm8916_gpios_leds>,
316 compatible = "gpio-leds";
319 label = "apq8016-sbc:green:user1";
320 gpios = <&msmgpio 21 GPIO_ACTIVE_HIGH>;
321 linux,default-trigger = "heartbeat";
322 default-state = "off";
326 label = "apq8016-sbc:green:user2";
327 gpios = <&msmgpio 120 GPIO_ACTIVE_HIGH>;
328 linux,default-trigger = "mmc0";
329 default-state = "off";
333 label = "apq8016-sbc:green:user3";
334 gpios = <&pm8916_gpios 1 GPIO_ACTIVE_HIGH>;
335 linux,default-trigger = "mmc1";
336 default-state = "off";
340 label = "apq8016-sbc:green:user4";
341 gpios = <&pm8916_gpios 2 GPIO_ACTIVE_HIGH>;
342 linux,default-trigger = "none";
344 default-state = "off";
348 label = "apq8016-sbc:yellow:wlan";
349 gpios = <&pm8916_mpps 2 GPIO_ACTIVE_HIGH>;
350 linux,default-trigger = "phy0tx";
351 default-state = "off";
355 label = "apq8016-sbc:blue:bt";
356 gpios = <&pm8916_mpps 3 GPIO_ACTIVE_HIGH>;
357 linux,default-trigger = "bluetooth-power";
358 default-state = "off";
363 vmmc-supply = <&pm8916_l8>;
364 vqmmc-supply = <&pm8916_l5>;
366 pinctrl-names = "default", "sleep";
367 pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>;
368 pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>;
373 vmmc-supply = <&pm8916_l11>;
374 vqmmc-supply = <&pm8916_l12>;
376 pinctrl-names = "default", "sleep";
377 pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on &sdc2_cd_on>;
378 pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off &sdc2_cd_off>;
380 cd-gpios = <&msmgpio 38 0x1>;
385 extcon = <&usb_id>, <&usb_id>;
391 pinctrl-names = "default", "device";
392 pinctrl-0 = <&usb_sw_sel_pm &usb_hub_reset_pm>;
393 pinctrl-1 = <&usb_sw_sel_pm_device &usb_hub_reset_pm_device>;
396 v1p8-supply = <&pm8916_l7>;
397 v3p3-supply = <&pm8916_l13>;
417 vdda-supply = <&pm8916_l2>;
418 vddio-supply = <&pm8916_l6>;
423 remote-endpoint = <&adv7533_in>;
424 data-lanes = <0 1 2 3>;
433 vddio-supply = <&pm8916_l6>;
443 playback - Primary MI2S
447 playback - secondary MI2S
457 compatible = "qcom,apq8016-sbc-sndcard";
458 reg = <0x07702000 0x4>, <0x07702004 0x4>;
459 reg-names = "mic-iomux", "spkr-iomux";
462 pinctrl-0 = <&cdc_pdm_lines_act &ext_sec_tlmm_lines_act &ext_mclk_tlmm_lines_act>;
463 pinctrl-1 = <&cdc_pdm_lines_sus &ext_sec_tlmm_lines_sus &ext_mclk_tlmm_lines_sus>;
464 pinctrl-names = "default", "sleep";
465 qcom,model = "DB410c";
467 "AMIC2", "MIC BIAS Internal2",
468 "AMIC3", "MIC BIAS External1";
469 external-dai-link@0 {
470 link-name = "ADV7533";
472 sound-dai = <&lpass MI2S_QUATERNARY>;
475 sound-dai = <&adv_bridge 0>;
479 internal-codec-playback-dai-link@0 { /* I2S - Internal codec */
482 sound-dai = <&lpass MI2S_PRIMARY>;
485 sound-dai = <&lpass_codec 0>, <&wcd_codec 0>;
489 internal-codec-capture-dai-link@0 { /* I2S - Internal codec */
490 link-name = "WCD-Capture";
492 sound-dai = <&lpass MI2S_TERTIARY>;
495 sound-dai = <&lpass_codec 1>, <&wcd_codec 1>;
506 "USB_HUB_RESET_N_PM",
514 "GPIO-F"; /* LS_EXP_GPIO_F, LSEC pin 28 */
523 tpiu@820000 { status = "okay"; };
524 funnel@821000 { status = "okay"; };
525 replicator@824000 { status = "okay"; };
526 etf@825000 { status = "okay"; };
527 etr@826000 { status = "okay"; };
528 funnel@841000 { status = "okay"; };
529 debug@850000 { status = "okay"; };
530 debug@852000 { status = "okay"; };
531 debug@854000 { status = "okay"; };
532 debug@856000 { status = "okay"; };
533 etm@85c000 { status = "okay"; };
534 etm@85d000 { status = "okay"; };
535 etm@85e000 { status = "okay"; };
536 etm@85f000 { status = "okay"; };
537 cti@810000 { status = "okay"; };
538 cti@811000 { status = "okay"; };
539 cti@858000 { status = "okay"; };
540 cti@859000 { status = "okay"; };
541 cti@85a000 { status = "okay"; };
542 cti@85b000 { status = "okay"; };
546 compatible = "smsc,usb3503";
547 reset-gpios = <&pm8916_gpios 3 GPIO_ACTIVE_LOW>;
552 compatible = "linux,extcon-usb-gpio";
553 id-gpio = <&msmgpio 121 GPIO_ACTIVE_HIGH>;
554 pinctrl-names = "default";
555 pinctrl-0 = <&usb_id_default>;
559 compatible = "hdmi-connector";
564 remote-endpoint = <&adv7533_out>;
570 compatible = "gpio-keys";
571 #address-cells = <1>;
575 pinctrl-names = "default";
576 pinctrl-0 = <&msm_key_volp_n_default>;
580 linux,code = <KEY_VOLUMEUP>;
581 gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>;
589 #address-cells = <1>;
593 csiphy0_ep: endpoint {
596 remote-endpoint = <&ov5640_ep>;
609 compatible = "ovti,ov5640";
612 enable-gpios = <&msmgpio 34 GPIO_ACTIVE_HIGH>;
613 reset-gpios = <&msmgpio 35 GPIO_ACTIVE_LOW>;
614 pinctrl-names = "default";
615 pinctrl-0 = <&camera_rear_default>;
617 clocks = <&gcc GCC_CAMSS_MCLK0_CLK>;
618 clock-names = "xclk";
619 clock-frequency = <23880000>;
621 vdddo-supply = <&camera_vdddo_1v8>;
622 vdda-supply = <&camera_vdda_2v8>;
623 vddd-supply = <&camera_vddd_1v5>;
625 /* No camera mezzanine by default */
629 ov5640_ep: endpoint {
632 remote-endpoint = <&csiphy0_ep>;
642 compatible = "qcom,pm8941-resin";
643 interrupts = <0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
646 linux,code = <KEY_VOLUMEDOWN>;
654 clocks = <&gcc GCC_CODEC_DIGCODEC_CLK>;
655 clock-names = "mclk";
656 qcom,mbhc-vthreshold-low = <75 150 237 450 500>;
657 qcom,mbhc-vthreshold-high = <75 150 237 450 500>;
660 &smd_rpm_regulators {
661 vdd_l1_l2_l3-supply = <&pm8916_s3>;
662 vdd_l4_l5_l6-supply = <&pm8916_s4>;
663 vdd_l7-supply = <&pm8916_s4>;
666 regulator-min-microvolt = <375000>;
667 regulator-max-microvolt = <1562000>;
671 regulator-min-microvolt = <375000>;
672 regulator-max-microvolt = <1562000>;
676 regulator-min-microvolt = <1800000>;
677 regulator-max-microvolt = <1800000>;
684 regulator-min-microvolt = <375000>;
685 regulator-max-microvolt = <1525000>;
689 regulator-min-microvolt = <1200000>;
690 regulator-max-microvolt = <1200000>;
694 regulator-min-microvolt = <375000>;
695 regulator-max-microvolt = <1525000>;
699 regulator-min-microvolt = <1750000>;
700 regulator-max-microvolt = <3337000>;
704 regulator-min-microvolt = <1750000>;
705 regulator-max-microvolt = <3337000>;
709 regulator-min-microvolt = <1800000>;
710 regulator-max-microvolt = <1800000>;
714 regulator-min-microvolt = <1750000>;
715 regulator-max-microvolt = <3337000>;
719 regulator-min-microvolt = <1750000>;
720 regulator-max-microvolt = <3337000>;
724 regulator-min-microvolt = <1750000>;
725 regulator-max-microvolt = <3337000>;
729 regulator-min-microvolt = <1750000>;
730 regulator-max-microvolt = <3337000>;
734 regulator-min-microvolt = <1750000>;
735 regulator-max-microvolt = <3337000>;
736 regulator-allow-set-load;
737 regulator-system-load = <200000>;
741 regulator-min-microvolt = <1750000>;
742 regulator-max-microvolt = <3337000>;
746 regulator-min-microvolt = <1750000>;
747 regulator-max-microvolt = <3337000>;
751 regulator-min-microvolt = <1750000>;
752 regulator-max-microvolt = <3337000>;
756 * 1.8v required on LS expansion
757 * for mezzanine boards
760 regulator-min-microvolt = <1750000>;
761 regulator-max-microvolt = <3337000>;
766 regulator-min-microvolt = <1750000>;
767 regulator-max-microvolt = <3337000>;
771 regulator-min-microvolt = <3300000>;
772 regulator-max-microvolt = <3300000>;
776 regulator-min-microvolt = <1750000>;
777 regulator-max-microvolt = <3337000>;
782 msmgpio_leds: msmgpio-leds {
784 pins = "gpio21", "gpio120";
790 usb_id_default: usb-id-default {
798 drive-strength = <8>;
804 adv7533_int_active: adv533-int-active {
811 drive-strength = <16>;
816 adv7533_int_suspend: adv7533-int-suspend {
823 drive-strength = <2>;
828 adv7533_switch_active: adv7533-switch-active {
835 drive-strength = <16>;
840 adv7533_switch_suspend: adv7533-switch-suspend {
847 drive-strength = <2>;
852 msm_key_volp_n_default: msm-key-volp-n-default {
859 drive-strength = <8>;
867 usb_hub_reset_pm: usb-hub-reset-pm {
870 function = PMIC_GPIO_FUNC_NORMAL;
876 usb_hub_reset_pm_device: usb-hub-reset-pm-device {
879 function = PMIC_GPIO_FUNC_NORMAL;
884 usb_sw_sel_pm: usb-sw-sel-pm {
887 function = PMIC_GPIO_FUNC_NORMAL;
888 power-source = <PM8916_GPIO_VPH>;
894 usb_sw_sel_pm_device: usb-sw-sel-pm-device {
897 function = PMIC_GPIO_FUNC_NORMAL;
898 power-source = <PM8916_GPIO_VPH>;
904 pm8916_gpios_leds: pm8916-gpios-leds {
906 pins = "gpio1", "gpio2";
907 function = PMIC_GPIO_FUNC_NORMAL;
914 pinctrl-names = "default";
915 pinctrl-0 = <&ls_exp_gpio_f>;
917 ls_exp_gpio_f: pm8916-mpp4 {
920 function = "digital";
922 power-source = <PM8916_MPP_L5>; // 1.8V
926 pm8916_mpps_leds: pm8916-mpps-leds {
928 pins = "mpp2", "mpp3";
929 function = "digital";