480 lines
9 KiB
Text
480 lines
9 KiB
Text
// SPDX-License-Identifier: (GPL-2.0 OR MIT)
|
|
/*
|
|
* Copyright (C) 2022 MediaTek Inc.
|
|
*/
|
|
/dts-v1/;
|
|
/plugin/;
|
|
#include <dt-bindings/interrupt-controller/arm-gic.h>
|
|
#include <dt-bindings/interrupt-controller/irq.h>
|
|
#include <dt-bindings/pinctrl/mt6985-pinfunc.h>
|
|
#include <dt-bindings/phy/phy.h>
|
|
|
|
&chosen {
|
|
bootargs_ext = "console=tty0 root=/dev/ram vmalloc=400M \
|
|
androidboot.hardware=mt6985 \
|
|
8250.nr_uarts=4";
|
|
};
|
|
|
|
&mtk_leds {
|
|
compatible = "mediatek,i2c-leds";
|
|
|
|
backlight {
|
|
led_mode = <6>;
|
|
gate_enable = <1>;
|
|
pwm_config = <0 1 0 0 0>;
|
|
};
|
|
};
|
|
|
|
&connfem {
|
|
/* Support Wifi & BT ePA/eLNA FEM on customer load */
|
|
epa_elna {
|
|
parts = <&qm42639 &qm45639>;
|
|
|
|
common {
|
|
flags-0 {
|
|
rx-mode = [81];
|
|
fe-ant-cnt = [82];
|
|
fe-main-bt-share-lp2g = [81];
|
|
fe-conn-spdt = [8F];
|
|
fe-reserved = [82];
|
|
};
|
|
};
|
|
|
|
wifi {
|
|
flags-0 {
|
|
epa-option = [AA];
|
|
/* open-loop; */
|
|
};
|
|
};
|
|
|
|
bt {
|
|
flags-0 {
|
|
/* choose one of: epa_elna/epa/elna/bypass */
|
|
epa_elna;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
&pio {
|
|
mtkfb_pins_lcd_bias_enp1: lcd_bias_enp1_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO84__FUNC_GPIO84>;
|
|
slew-rate = <1>;
|
|
output-high;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcd_bias_enp0: lcd_bias_enp0_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO84__FUNC_GPIO84>;
|
|
slew-rate = <1>;
|
|
output-low;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcd_bias_enn1: lcd_bias_enn1_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO84__FUNC_GPIO84>;
|
|
slew-rate = <1>;
|
|
output-high;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcd_bias_enn0: lcd_bias_enn0_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO84__FUNC_GPIO84>;
|
|
slew-rate = <1>;
|
|
output-low;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_rst_out1_gpio: lcm_rst_out1_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO86__FUNC_GPIO86>;
|
|
slew-rate = <1>;
|
|
output-high;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_rst_out0_gpio: lcm_rst_out0_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO86__FUNC_GPIO86>;
|
|
slew-rate = <1>;
|
|
output-low;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_dsi_te: lcm_dsi_te {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO85__FUNC_DSI_TE>;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_led_en1: lcm_led_en1_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO68__FUNC_GPIO68>;
|
|
slew-rate = <1>;
|
|
output-high;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_led_en0: lcm_led_en0_gpio {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO68__FUNC_GPIO68>;
|
|
slew-rate = <1>;
|
|
output-low;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_dsi1_te: lcm-dsi1-te {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO74__FUNC_DSI1_TE>;
|
|
};
|
|
};
|
|
|
|
mtkfb_pins_lcm_dsi_gpio: lcm-dsi-gpio {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO85__FUNC_GPIO85>;
|
|
};
|
|
};
|
|
mtkfb_pins_lcm_dsi1_gpio: lcm-dsi1-gpio {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO74__FUNC_GPIO74>;
|
|
};
|
|
};
|
|
|
|
};
|
|
|
|
&mtkfb {
|
|
pinctrl-names = "lcd_bias_enp1_gpio", "lcd_bias_enp0_gpio",
|
|
"lcd_bias_enn1_gpio", "lcd_bias_enn0_gpio",
|
|
"lcm_rst_out1_gpio", "lcm_rst_out0_gpio",
|
|
"mode_te_te", "lcm_led_en1_gpio", "lcm_led_en0_gpio",
|
|
"mode_te_te1";
|
|
pinctrl-0 = <&mtkfb_pins_lcd_bias_enp1>;
|
|
pinctrl-1 = <&mtkfb_pins_lcd_bias_enp0>;
|
|
pinctrl-2 = <&mtkfb_pins_lcd_bias_enn1>;
|
|
pinctrl-3 = <&mtkfb_pins_lcd_bias_enn0>;
|
|
pinctrl-4 = <&mtkfb_pins_lcm_rst_out1_gpio>;
|
|
pinctrl-5 = <&mtkfb_pins_lcm_rst_out0_gpio>;
|
|
pinctrl-6 = <&mtkfb_pins_lcm_dsi_te>;
|
|
pinctrl-7 = <&mtkfb_pins_lcm_led_en1>;
|
|
pinctrl-8 = <&mtkfb_pins_lcm_led_en0>;
|
|
pinctrl-9 = <&mtkfb_pins_lcm_dsi1_te>;
|
|
|
|
status = "okay";
|
|
};
|
|
|
|
&dispsys_config {
|
|
pinctrl-names = "mode_te_te", "mode_te_te1";
|
|
pinctrl-0 = <&mtkfb_pins_lcm_dsi_te>;
|
|
pinctrl-1 = <&mtkfb_pins_lcm_dsi1_te>;
|
|
status = "okay";
|
|
};
|
|
|
|
&dsi1 {
|
|
// status = "okay";
|
|
#address-cells = <1>;
|
|
#size-cells = <0>;
|
|
panel21@0 {
|
|
compatible = "jdi,nt36672e,vdo,60hz";
|
|
reg = <0>;
|
|
pm-enable-gpios = <&pio 68 0>;
|
|
reset-gpios = <&pio 75 0>;
|
|
gate-ic = <4831>;
|
|
// swap-from-dts;
|
|
lane-swap-setting = <1 2 0 3 4 2>;
|
|
pn-swap-setting = <1 1 1 1 1 1>;
|
|
pinctrl-names = "default";
|
|
port {
|
|
panel21_in: endpoint {
|
|
remote-endpoint = <&dsi1_out>;
|
|
};
|
|
};
|
|
};
|
|
ports {
|
|
port {
|
|
dsi1_out: endpoint {
|
|
remote-endpoint = <&panel21_in>;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
&dsi1_te {
|
|
interrupt-parent = <&pio>;
|
|
interrupts = <74 1 74 1>;
|
|
status = "okay";
|
|
};
|
|
|
|
&dsi0 {
|
|
status = "okay";
|
|
#address-cells = <1>;
|
|
#size-cells = <0>;
|
|
panel1@0 {
|
|
compatible = "jdi,nt36672e,vdo,120hz";
|
|
reg = <0>;
|
|
pm-enable-gpios = <&pio 68 0>;
|
|
reset-gpios = <&pio 86 0>;
|
|
gate-ic = <4831>;
|
|
pinctrl-names = "default";
|
|
port {
|
|
panel_in1: endpoint {
|
|
remote-endpoint = <&dsi_out>;
|
|
};
|
|
};
|
|
};
|
|
panel2@1 {
|
|
compatible = "truly,td4330,cmd";
|
|
reg = <1>;
|
|
pm-enable-gpios = <&pio 68 0>;
|
|
reset-gpios = <&pio 86 0>;
|
|
gate-ic = <4831>;
|
|
// swap-from-dts;
|
|
lane-swap-setting = <1 2 0 3 4 2>;
|
|
pn-swap-setting = <1 1 1 1 1 1>;
|
|
pinctrl-names = "default";
|
|
port {
|
|
panel_in2: endpoint {
|
|
remote-endpoint = <&dsi_out2>;
|
|
};
|
|
};
|
|
};
|
|
panel3@2 {
|
|
compatible = "tianma,nt36672e,vdo,120hz";
|
|
reg = <2>;
|
|
pm-enable-gpios = <&pio 68 0>;
|
|
reset-gpios = <&pio 86 0>;
|
|
gate-ic = <4831>;
|
|
pinctrl-names = "default";
|
|
port {
|
|
panel_in3: endpoint {
|
|
remote-endpoint = <&dsi_out3>;
|
|
};
|
|
};
|
|
};
|
|
panel4@3 {
|
|
compatible = "nt37801,cmd,fhd";
|
|
reg = <3>;
|
|
pm-enable-gpios = <&pio 68 0>;
|
|
reset-gpios = <&pio 86 0>;
|
|
gate-ic = <4831>;
|
|
pinctrl-names = "default";
|
|
port {
|
|
panel_in4: endpoint {
|
|
remote-endpoint = <&dsi_out4>;
|
|
};
|
|
};
|
|
};
|
|
ports {
|
|
port {
|
|
dsi_out: endpoint {
|
|
remote-endpoint = <&panel_in1>;
|
|
};
|
|
|
|
dsi_out2: endpoint2 {
|
|
remote-endpoint = <&panel_in2>;
|
|
};
|
|
|
|
dsi_out3: endpoint3 {
|
|
remote-endpoint = <&panel_in3>;
|
|
};
|
|
|
|
dsi_out4: endpoint4 {
|
|
remote-endpoint = <&panel_in4>;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
/* GPS GPIO standardization start */
|
|
&pio {
|
|
gps_pins_default: gps_default {
|
|
};
|
|
gps_l1_lna_pins_ol: gps-l1-lna0 {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO16__FUNC_GPIO16>;
|
|
output-low;
|
|
};
|
|
};
|
|
gps_l1_lna_pins_dsp_ctrl: gps-l1-lna1 {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO16__FUNC_GPS_L1_ELNA_EN>;
|
|
};
|
|
};
|
|
gps_l1_lna_pins_oh: gps-l1-lna2 {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO16__FUNC_GPIO16>;
|
|
output-high;
|
|
};
|
|
};
|
|
gps_l5_lna_pins_ol: gps-l5-lna0 {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO17__FUNC_GPIO17>;
|
|
output-low;
|
|
};
|
|
};
|
|
gps_l5_lna_pins_dsp_ctrl: gps-l5-lna1 {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO17__FUNC_GPS_L5_ELNA_EN>;
|
|
};
|
|
};
|
|
gps_l5_lna_pins_oh: gps-l5-lna2 {
|
|
pins-cmd-dat {
|
|
pinmux = <PINMUX_GPIO17__FUNC_GPIO17>;
|
|
output-high;
|
|
};
|
|
};
|
|
};
|
|
|
|
&gps {
|
|
pinctrl-names = "default",
|
|
"gps_l1_lna_disable",
|
|
"gps_l1_lna_dsp_ctrl",
|
|
"gps_l1_lna_enable",
|
|
"gps_l5_lna_disable",
|
|
"gps_l5_lna_dsp_ctrl",
|
|
"gps_l5_lna_enable";
|
|
pinctrl-0 = <&gps_pins_default>;
|
|
pinctrl-1 = <&gps_l1_lna_pins_ol>;
|
|
pinctrl-2 = <&gps_l1_lna_pins_dsp_ctrl>;
|
|
pinctrl-3 = <&gps_l1_lna_pins_oh>;
|
|
pinctrl-4 = <&gps_l5_lna_pins_ol>;
|
|
pinctrl-5 = <&gps_l5_lna_pins_dsp_ctrl>;
|
|
pinctrl-6 = <&gps_l5_lna_pins_oh>;
|
|
status = "okay";
|
|
};
|
|
/* GPS GPIO standardization end */
|
|
|
|
/* PCIe pinmux start */
|
|
&pcie0 {
|
|
pinctrl-names = "default", "sleep";
|
|
pinctrl-0 = <&pcie0_pins_default>;
|
|
pinctrl-1 = <&pcie0_pins_sleep>;
|
|
status = "okay";
|
|
};
|
|
|
|
&pcie1 {
|
|
pinctrl-names = "default";
|
|
pinctrl-0 = <&pcie1_pins_default>;
|
|
status = "disabled";
|
|
};
|
|
|
|
&pio {
|
|
pcie0_pins_default: pcie0-default {
|
|
pins_cmd_dat {
|
|
/* PINMUX_GPIO231__FUNC_PCIE_WAKEN for Falcon */
|
|
pinmux = <PINMUX_GPIO230__FUNC_PCIE_PERSTN>,
|
|
<PINMUX_GPIO232__FUNC_PCIE_CLKREQN>;
|
|
bias-pull-up;
|
|
};
|
|
};
|
|
|
|
pcie0_pins_sleep: pcie0-sleep {
|
|
pins_cmd_dat {
|
|
/* PINMUX_GPIO231__FUNC_GPIO231 for Falcon */
|
|
pinmux = <PINMUX_GPIO230__FUNC_GPIO230>,
|
|
<PINMUX_GPIO232__FUNC_GPIO232>;
|
|
bias-pull-down;
|
|
input-enable;
|
|
};
|
|
};
|
|
|
|
pcie1_pins_default: pcie1-default {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO0__FUNC_PCIE_PERSTN_P1>,
|
|
<PINMUX_GPIO1__FUNC_PCIE_WAKEN_P1>,
|
|
<PINMUX_GPIO2__FUNC_PCIE_CLKREQN_P1>;
|
|
bias-pull-up;
|
|
};
|
|
};
|
|
};
|
|
/* PCIe pinmux end */
|
|
|
|
/* usb typec mux start */
|
|
&pio {
|
|
|
|
ps_enable: ps_enable {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO204__FUNC_GPIO204>;
|
|
output-high;
|
|
};
|
|
};
|
|
|
|
ps_disable: ps_disable {
|
|
pins_cmd_dat {
|
|
pinmux = <PINMUX_GPIO204__FUNC_GPIO204>;
|
|
output-low;
|
|
};
|
|
};
|
|
|
|
};
|
|
|
|
&mt6375_typec {
|
|
port {
|
|
tcpc_typec_usb: endpoint {
|
|
remote-endpoint = <&ssusb_mux>;
|
|
};
|
|
};
|
|
};
|
|
|
|
&typec_mux_switch {
|
|
orientation-switch;
|
|
mode-switch;
|
|
accessory;
|
|
port {
|
|
ssusb_mux: endpoint {
|
|
remote-endpoint = <&tcpc_typec_usb>;
|
|
};
|
|
};
|
|
};
|
|
|
|
&ps5170 {
|
|
pinctrl-names = "enable", "disable";
|
|
pinctrl-0 = <&ps_enable>;
|
|
pinctrl-1 = <&ps_disable>;
|
|
status = "okay";
|
|
};
|
|
|
|
&usb_dp_selector {
|
|
status = "okay";
|
|
};
|
|
/* usb typec mux end */
|
|
|
|
#include "mediatek/cust_mt6985_touch_1080x2400.dtsi"
|
|
|
|
&i2c6 {
|
|
spk1: speaker_amp@5c {
|
|
compatible = "richtek,rt5512";
|
|
#sound-dai-cells = <0>;
|
|
reg = <0x5c>;
|
|
status = "okay";
|
|
sound-name-prefix = "Left";
|
|
};
|
|
|
|
spk2: speaker_amp@5d {
|
|
compatible = "richtek,rt5512";
|
|
#sound-dai-cells = <0>;
|
|
reg = <0x5d>;
|
|
status = "okay";
|
|
sound-name-prefix = "Right";
|
|
};
|
|
};
|
|
|
|
&sound {
|
|
mediatek,spk-i2s = <3 9>;
|
|
mediatek,speaker-codec {
|
|
sound-dai = <&spk1>, <&spk2>;
|
|
};
|
|
};
|
|
|
|
&pdc {
|
|
pd-vbus-upper-bound = <9000000>;
|
|
};
|
|
|
|
#include "mediatek/cust_k6985_connfem.dtsi"
|
|
#include "mediatek/cust_mt6985_camera_v4l2.dtsi"
|
|
#include <k6985v1_64/cust.dtsi>
|
|
/*End of this file, DO NOT ADD ANYTHING HERE*/
|
|
|