From 029d0dfc86b2099bc0f2565dd66028c3bc370f71 Mon Sep 17 00:00:00 2001 From: Guochun Huang Date: Thu, 25 Oct 2018 20:21:37 +0800 Subject: [PATCH] arm64: dts: rockchip: rk3399: separate android firmware - Split DT source files to separate out android firmware specific DT bindings - Add an alias for firmware_android in rk3399-android.dtsi Change-Id: If3ae952c61ff01903ea990c6430255af27f5a432 Signed-off-by: Guochun Huang --- .../boot/dts/rockchip/rk3399-android.dtsi | 21 +- arch/arm64/boot/dts/rockchip/rk3399-box.dtsi | 21 + .../dts/rockchip/rk3399-evb-rev1-android.dts | 21 + .../dts/rockchip/rk3399-evb-rev2-android.dts | 21 + .../rockchip/rk3399-evb-rev3-android-edp.dts | 20 + .../rockchip/rk3399-evb-rev3-android-lp4.dts | 21 + .../rk3399-evb-rev3-android-mipi-edp.dts | 21 + .../dts/rockchip/rk3399-evb-rev3-android.dts | 21 + .../dts/rockchip/rk3399-mid-818-android.dts | 21 + .../rk3399-sapphire-excavator-box.dts | 21 + .../rk3399-sapphire-excavator-edp.dts | 376 +--------------- .../rk3399-sapphire-excavator-edp.dtsi | 407 ++++++++++++++++++ .../boot/dts/rockchip/rk3399-tve1030g.dts | 21 + .../boot/dts/rockchip/rk3399-tve1205g.dts | 21 + .../boot/dts/rockchip/rk3399pro-evb-v10.dts | 21 + 15 files changed, 677 insertions(+), 378 deletions(-) create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dtsi diff --git a/arch/arm64/boot/dts/rockchip/rk3399-android.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-android.dtsi index b9f5ad1857b6..aa531070282f 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-android.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-android.dtsi @@ -260,26 +260,7 @@ }; firmware { - android { - compatible = "android,firmware"; - fstab { - compatible = "android,fstab"; - system { - compatible = "android,system"; - dev = "/dev/block/by-name/system"; - type = "ext4"; - mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; - fsmgr_flags = "wait,verify"; - }; - vendor { - compatible = "android,vendor"; - dev = "/dev/block/by-name/vendor"; - type = "ext4"; - mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; - fsmgr_flags = "wait,verify"; - }; - }; - }; + firmware_android: android {}; }; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-box.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-box.dtsi index 9a8db8feb1c9..3ff1c59a0c35 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-box.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-box.dtsi @@ -516,6 +516,27 @@ cpu-supply = <&vdd_cpu_b>; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + &gpu { status = "okay"; mali-supply = <&vdd_gpu>; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts index 0a042206b74d..0a24ef84a166 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts @@ -98,3 +98,24 @@ &route_dsi { status = "okay"; }; + +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts index 890ef6747fc6..7808fbdda3b0 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts @@ -109,3 +109,24 @@ &route_dsi { status = "okay"; }; + +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-edp.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-edp.dts index 99af3488efad..7f730f5633dd 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-edp.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-edp.dts @@ -104,3 +104,23 @@ status = "okay"; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-lp4.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-lp4.dts index 3afffea7b071..5b370eaaed17 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-lp4.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-lp4.dts @@ -171,3 +171,24 @@ status = "disabled"; }; }; + +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-mipi-edp.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-mipi-edp.dts index 51e8837e1368..a3094b54f63a 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-mipi-edp.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android-mipi-edp.dts @@ -248,6 +248,27 @@ connect = <&vopl_out_edp>; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + >9xx { status = "disabled"; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android.dts index 28c66587d757..435e161aa720 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev3-android.dts @@ -129,3 +129,24 @@ &route_dsi { status = "okay"; }; + +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts index 7dd00bc6c4b6..a63cd8a64479 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts @@ -257,6 +257,27 @@ }; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + &rk_key { compatible = "rockchip,key"; status = "okay"; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-box.dts b/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-box.dts index f01fb0cece95..3106512b87cd 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-box.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-box.dts @@ -54,6 +54,27 @@ }; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + &hdmi_dp_sound { status = "okay"; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dts b/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dts index 98b6f352de77..bd6356423c3b 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dts @@ -41,370 +41,30 @@ */ /dts-v1/; - -#include "rk3399-excavator-sapphire.dtsi" -#include "rk3399-android.dtsi" -#include "rk3399-vop-clk-set.dtsi" +#include "rk3399-sapphire-excavator-edp.dtsi" / { model = "Rockchip RK3399 Excavator Board edp (Android)"; compatible = "rockchip,android", "rockchip,rk3399-excavator-edp", "rockchip,rk3399"; - - vcc_lcd: vcc-lcd { - compatible = "regulator-fixed"; - regulator-name = "vcc_lcd"; - gpio = <&gpio4 30 GPIO_ACTIVE_HIGH>; - startup-delay-us = <20000>; - enable-active-high; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; - regulator-boot-on; - vin-supply = <&vcc5v0_sys>; - }; - - panel: panel { - compatible = "simple-panel"; - backlight = <&backlight>; - power-supply = <&vcc_lcd>; - enable-gpios = <&gpio1 13 GPIO_ACTIVE_HIGH>; - prepare-delay-ms = <20>; - enable-delay-ms = <20>; - - display-timings { - native-mode = <&timing0>; - - timing0: timing0 { - clock-frequency = <200000000>; - hactive = <1536>; - vactive = <2048>; - hfront-porch = <12>; - hsync-len = <16>; - hback-porch = <48>; - vfront-porch = <8>; - vsync-len = <4>; - vback-porch = <8>; - hsync-active = <0>; - vsync-active = <0>; - de-active = <0>; - pixelclk-active = <0>; - }; - }; - - ports { - panel_in: endpoint { - remote-endpoint = <&edp_out>; - }; - }; - }; - - test-power { - status = "okay"; - }; - - rt5651-sound { - status = "disabled"; - }; - - hdmiin-sound { - compatible = "rockchip,rockchip-rt5651-tc358749x-sound"; - rockchip,cpu = <&i2s0>; - rockchip,codec = <&rt5651 &rt5651 &tc358749x>; - status = "okay"; - }; }; -&backlight { - status = "okay"; - enable-gpios = <&gpio4 29 GPIO_ACTIVE_HIGH>; -}; - -&edp { - status = "okay"; - force-hpd; - - ports { - port@1 { - reg = <1>; - - edp_out: endpoint { - remote-endpoint = <&panel_in>; - }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; }; }; }; - -&edp_in_vopl { - status = "disabled"; -}; - -&hdmi { - status = "okay"; -}; - -&hdmi_in_vopb { - status = "disabled"; -}; - -&rt5651 { - status = "okay"; -}; - -&cdn_dp { - status = "okay"; - extcon = <&fusb0>; - phys = <&tcphy0_dp>; -}; - -&hdmi_dp_sound { - status = "okay"; -}; - -&dp_in_vopb { - status = "disabled"; -}; - -&i2s2 { - status = "okay"; -}; - -&i2c1 { - status = "okay"; - - gsl3673: gsl3673@40 { - compatible = "GSL,GSL3673"; - reg = <0x40>; - screen_max_x = <1536>; - screen_max_y = <2048>; - irq_gpio_number = <&gpio1 20 IRQ_TYPE_LEVEL_LOW>; - rst_gpio_number = <&gpio4 22 GPIO_ACTIVE_HIGH>; - }; - - tc358749x: tc358749x@0f { - compatible = "toshiba,tc358749x"; - reg = <0x0f>; - power-gpios = <&gpio2 6 GPIO_ACTIVE_HIGH>; - power18-gpios = <&gpio2 9 GPIO_ACTIVE_HIGH>; - power33-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>; - csi-ctl-gpios = <&gpio2 10 GPIO_ACTIVE_HIGH>; - stanby-gpios = <&gpio2 8 GPIO_ACTIVE_HIGH>; - reset-gpios = <&gpio2 7 GPIO_ACTIVE_HIGH>; - int-gpios = <&gpio2 12 GPIO_ACTIVE_HIGH>; - pinctrl-names = "default"; - pinctrl-0 = <&hdmiin_gpios>; - status = "okay"; - }; - - ov13850: ov13850@10 { - compatible = "ovti,ov13850"; - status = "disabled"; - reg = <0x10>; - clocks = <&cru SCLK_CIF_OUT>; - clock-names = "xvclk"; - /* avdd-supply = <>; */ - /* dvdd-supply = <>; */ - /* dovdd-supply = <>; */ - /* reset-gpios = <>; */ - reset-gpios = <&gpio2 10 GPIO_ACTIVE_HIGH>; // conflict with csi-ctl-gpios - pwdn-gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>; - pinctrl-names = "rockchip,camera_default"; - pinctrl-0 = <&cif_clkout>; - port { - ucam_out0: endpoint { - remote-endpoint = <&mipi_in_ucam0>; - //remote-endpoint = <&mipi_in_ucam1>; - data-lanes = <1 2>; - }; - }; - }; - - ov4689: ov4689@36 { - compatible = "ovti,ov4689"; - status = "disabled"; - reg = <0x36>; - clocks = <&cru SCLK_CIF_OUT>; - clock-names = "xvclk"; - /* avdd-supply = <>; */ - /* dvdd-supply = <>; */ - /* dovdd-supply = <>; */ - /* reset-gpios = <>; */ - pwdn-gpios = <&gpio4 29 GPIO_ACTIVE_HIGH>; // conflict with backlight - pinctrl-names = "rockchip,camera_default"; - pinctrl-0 = <&cif_clkout>; - port { - ucam_out1: endpoint { - //remote-endpoint = <&mipi_in_ucam0>; - remote-endpoint = <&mipi_in_ucam1>; - data-lanes = <1 2>; - }; - }; - }; -}; - -&i2c6 { - cw2015@62 { - status = "disabled"; - compatible = "cw201x"; - reg = <0x62>; - bat_config_info = <0x15 0x42 0x60 0x59 0x52 0x58 0x4D 0x48 - 0x48 0x44 0x44 0x46 0x49 0x48 0x32 0x24 - 0x20 0x17 0x13 0x0F 0x19 0x3E 0x51 0x45 - 0x08 0x76 0x0B 0x85 0x0E 0x1C 0x2E 0x3E - 0x4D 0x52 0x52 0x57 0x3D 0x1B 0x6A 0x2D - 0x25 0x43 0x52 0x87 0x8F 0x91 0x94 0x52 - 0x82 0x8C 0x92 0x96 0xFF 0x7B 0xBB 0xCB - 0x2F 0x7D 0x72 0xA5 0xB5 0xC1 0x46 0xAE>; - monitor_sec = <5>; - virtual_power = <0>; - }; -}; - -&isp0 { - status = "okay"; -}; - -&isp1 { - status = "okay"; -}; - -&isp0_mmu { - status = "okay"; -}; - -&isp1_mmu { - status = "okay"; -}; - -&mipi_dphy_rx0 { - status = "disabled"; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - #address-cells = <1>; - #size-cells = <0>; - - mipi_in_ucam0: endpoint@1 { - reg = <1>; - remote-endpoint = <&ucam_out0>; - data-lanes = <1 2>; - }; - }; - - port@1 { - reg = <1>; - #address-cells = <1>; - #size-cells = <0>; - - dphy_rx0_out: endpoint@0 { - reg = <0>; - remote-endpoint = <&isp0_mipi_in>; - }; - }; - }; -}; - -&mipi_dphy_tx1rx1 { - status = "disabled"; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - #address-cells = <1>; - #size-cells = <0>; - - mipi_in_ucam1: endpoint@1 { - reg = <1>; - remote-endpoint = <&ucam_out1>; - data-lanes = <1 2>; - }; - }; - - port@1 { - reg = <1>; - #address-cells = <1>; - #size-cells = <0>; - - dphy_tx1rx1_out: endpoint@0 { - reg = <0>; - remote-endpoint = <&isp1_mipi_in>; - }; - }; - }; -}; - -&vopb { - assigned-clocks = <&cru DCLK_VOP0_DIV>; - assigned-clock-parents = <&cru PLL_CPLL>; -}; - -&vopl { - assigned-clocks = <&cru DCLK_VOP1_DIV>; - assigned-clock-parents = <&cru PLL_VPLL>; -}; - -&pcie_phy { - status = "okay"; -}; - -&pcie0 { - status = "okay"; -}; - -&rkisp1_0 { - status = "disabled"; - - port { - #address-cells = <1>; - #size-cells = <0>; - - isp0_mipi_in: endpoint@0 { - reg = <0>; - remote-endpoint = <&dphy_rx0_out>; - }; - }; -}; - -&rkisp1_1 { - status = "disabled"; - - port { - #address-cells = <1>; - #size-cells = <0>; - - isp1_mipi_in: endpoint@0 { - reg = <0>; - remote-endpoint = <&dphy_tx1rx1_out>; - }; - }; -}; - -&route_edp { - status = "okay"; -}; - -&pinctrl { - lcd-panel { - lcd_panel_reset: lcd-panel-reset { - rockchip,pins = <4 30 RK_FUNC_GPIO &pcfg_pull_up>; - }; - }; - - hdmiin { - hdmiin_gpios: hdmiin_gpios { - rockchip,pins = - <2 5 RK_FUNC_GPIO &pcfg_pull_none>, - <2 6 RK_FUNC_GPIO &pcfg_pull_none>, - <2 7 RK_FUNC_GPIO &pcfg_pull_none>, - <2 8 RK_FUNC_GPIO &pcfg_pull_none>, - <2 9 RK_FUNC_GPIO &pcfg_pull_none>, - <2 12 RK_FUNC_GPIO &pcfg_pull_none>; - }; - }; -}; - diff --git a/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dtsi new file mode 100644 index 000000000000..2af6f3d6ca39 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3399-sapphire-excavator-edp.dtsi @@ -0,0 +1,407 @@ +/* + * Copyright (c) 2018 Fuzhou Rockchip Electronics Co., Ltd + * + * This file is dual-licensed: you can use it either under the terms + * of the GPL or the X11 license, at your option. Note that this dual + * licensing only applies to this file, and not this project as a + * whole. + * + * a) This file is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * This file is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * Or, alternatively, + * + * b) Permission is hereby granted, free of charge, to any person + * obtaining a copy of this software and associated documentation + * files (the "Software"), to deal in the Software without + * restriction, including without limitation the rights to use, + * copy, modify, merge, publish, distribute, sublicense, and/or + * sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following + * conditions: + * + * The above copyright notice and this permission notice shall be + * included in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES + * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT + * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR + * OTHER DEALINGS IN THE SOFTWARE. + */ + +/dts-v1/; + +#include "rk3399-excavator-sapphire.dtsi" +#include "rk3399-android.dtsi" +#include "rk3399-vop-clk-set.dtsi" + +/ { + vcc_lcd: vcc-lcd { + compatible = "regulator-fixed"; + regulator-name = "vcc_lcd"; + gpio = <&gpio4 30 GPIO_ACTIVE_HIGH>; + startup-delay-us = <20000>; + enable-active-high; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-boot-on; + vin-supply = <&vcc5v0_sys>; + }; + + panel: panel { + compatible = "simple-panel"; + backlight = <&backlight>; + power-supply = <&vcc_lcd>; + enable-gpios = <&gpio1 13 GPIO_ACTIVE_HIGH>; + prepare-delay-ms = <20>; + enable-delay-ms = <20>; + + display-timings { + native-mode = <&timing0>; + + timing0: timing0 { + clock-frequency = <200000000>; + hactive = <1536>; + vactive = <2048>; + hfront-porch = <12>; + hsync-len = <16>; + hback-porch = <48>; + vfront-porch = <8>; + vsync-len = <4>; + vback-porch = <8>; + hsync-active = <0>; + vsync-active = <0>; + de-active = <0>; + pixelclk-active = <0>; + }; + }; + + ports { + panel_in: endpoint { + remote-endpoint = <&edp_out>; + }; + }; + }; + + test-power { + status = "okay"; + }; + + rt5651-sound { + status = "disabled"; + }; + + hdmiin-sound { + compatible = "rockchip,rockchip-rt5651-tc358749x-sound"; + rockchip,cpu = <&i2s0>; + rockchip,codec = <&rt5651 &rt5651 &tc358749x>; + status = "okay"; + }; +}; + +&backlight { + status = "okay"; + enable-gpios = <&gpio4 29 GPIO_ACTIVE_HIGH>; +}; + +&edp { + status = "okay"; + force-hpd; + + ports { + port@1 { + reg = <1>; + + edp_out: endpoint { + remote-endpoint = <&panel_in>; + }; + }; + }; +}; + +&edp_in_vopl { + status = "disabled"; +}; + +&hdmi { + status = "okay"; +}; + +&hdmi_in_vopb { + status = "disabled"; +}; + +&rt5651 { + status = "okay"; +}; + +&cdn_dp { + status = "okay"; + extcon = <&fusb0>; + phys = <&tcphy0_dp>; +}; + +&hdmi_dp_sound { + status = "okay"; +}; + +&dp_in_vopb { + status = "disabled"; +}; + +&i2s2 { + status = "okay"; +}; + +&i2c1 { + status = "okay"; + + gsl3673: gsl3673@40 { + compatible = "GSL,GSL3673"; + reg = <0x40>; + screen_max_x = <1536>; + screen_max_y = <2048>; + irq_gpio_number = <&gpio1 20 IRQ_TYPE_LEVEL_LOW>; + rst_gpio_number = <&gpio4 22 GPIO_ACTIVE_HIGH>; + }; + + tc358749x: tc358749x@0f { + compatible = "toshiba,tc358749x"; + reg = <0x0f>; + power-gpios = <&gpio2 6 GPIO_ACTIVE_HIGH>; + power18-gpios = <&gpio2 9 GPIO_ACTIVE_HIGH>; + power33-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>; + csi-ctl-gpios = <&gpio2 10 GPIO_ACTIVE_HIGH>; + stanby-gpios = <&gpio2 8 GPIO_ACTIVE_HIGH>; + reset-gpios = <&gpio2 7 GPIO_ACTIVE_HIGH>; + int-gpios = <&gpio2 12 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&hdmiin_gpios>; + status = "okay"; + }; + + ov13850: ov13850@10 { + compatible = "ovti,ov13850"; + status = "disabled"; + reg = <0x10>; + clocks = <&cru SCLK_CIF_OUT>; + clock-names = "xvclk"; + /* avdd-supply = <>; */ + /* dvdd-supply = <>; */ + /* dovdd-supply = <>; */ + /* reset-gpios = <>; */ + reset-gpios = <&gpio2 10 GPIO_ACTIVE_HIGH>; // conflict with csi-ctl-gpios + pwdn-gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>; + pinctrl-names = "rockchip,camera_default"; + pinctrl-0 = <&cif_clkout>; + port { + ucam_out0: endpoint { + remote-endpoint = <&mipi_in_ucam0>; + //remote-endpoint = <&mipi_in_ucam1>; + data-lanes = <1 2>; + }; + }; + }; + + ov4689: ov4689@36 { + compatible = "ovti,ov4689"; + status = "disabled"; + reg = <0x36>; + clocks = <&cru SCLK_CIF_OUT>; + clock-names = "xvclk"; + /* avdd-supply = <>; */ + /* dvdd-supply = <>; */ + /* dovdd-supply = <>; */ + /* reset-gpios = <>; */ + pwdn-gpios = <&gpio4 29 GPIO_ACTIVE_HIGH>; // conflict with backlight + pinctrl-names = "rockchip,camera_default"; + pinctrl-0 = <&cif_clkout>; + port { + ucam_out1: endpoint { + //remote-endpoint = <&mipi_in_ucam0>; + remote-endpoint = <&mipi_in_ucam1>; + data-lanes = <1 2>; + }; + }; + }; +}; + +&i2c6 { + cw2015@62 { + status = "disabled"; + compatible = "cw201x"; + reg = <0x62>; + bat_config_info = <0x15 0x42 0x60 0x59 0x52 0x58 0x4D 0x48 + 0x48 0x44 0x44 0x46 0x49 0x48 0x32 0x24 + 0x20 0x17 0x13 0x0F 0x19 0x3E 0x51 0x45 + 0x08 0x76 0x0B 0x85 0x0E 0x1C 0x2E 0x3E + 0x4D 0x52 0x52 0x57 0x3D 0x1B 0x6A 0x2D + 0x25 0x43 0x52 0x87 0x8F 0x91 0x94 0x52 + 0x82 0x8C 0x92 0x96 0xFF 0x7B 0xBB 0xCB + 0x2F 0x7D 0x72 0xA5 0xB5 0xC1 0x46 0xAE>; + monitor_sec = <5>; + virtual_power = <0>; + }; +}; + +&isp0 { + status = "okay"; +}; + +&isp1 { + status = "okay"; +}; + +&isp0_mmu { + status = "okay"; +}; + +&isp1_mmu { + status = "okay"; +}; + +&mipi_dphy_rx0 { + status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + #address-cells = <1>; + #size-cells = <0>; + + mipi_in_ucam0: endpoint@1 { + reg = <1>; + remote-endpoint = <&ucam_out0>; + data-lanes = <1 2>; + }; + }; + + port@1 { + reg = <1>; + #address-cells = <1>; + #size-cells = <0>; + + dphy_rx0_out: endpoint@0 { + reg = <0>; + remote-endpoint = <&isp0_mipi_in>; + }; + }; + }; +}; + +&mipi_dphy_tx1rx1 { + status = "disabled"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + #address-cells = <1>; + #size-cells = <0>; + + mipi_in_ucam1: endpoint@1 { + reg = <1>; + remote-endpoint = <&ucam_out1>; + data-lanes = <1 2>; + }; + }; + + port@1 { + reg = <1>; + #address-cells = <1>; + #size-cells = <0>; + + dphy_tx1rx1_out: endpoint@0 { + reg = <0>; + remote-endpoint = <&isp1_mipi_in>; + }; + }; + }; +}; + +&vopb { + assigned-clocks = <&cru DCLK_VOP0_DIV>; + assigned-clock-parents = <&cru PLL_CPLL>; +}; + +&vopl { + assigned-clocks = <&cru DCLK_VOP1_DIV>; + assigned-clock-parents = <&cru PLL_VPLL>; +}; + +&pcie_phy { + status = "okay"; +}; + +&pcie0 { + status = "okay"; +}; + +&rkisp1_0 { + status = "disabled"; + + port { + #address-cells = <1>; + #size-cells = <0>; + + isp0_mipi_in: endpoint@0 { + reg = <0>; + remote-endpoint = <&dphy_rx0_out>; + }; + }; +}; + +&rkisp1_1 { + status = "disabled"; + + port { + #address-cells = <1>; + #size-cells = <0>; + + isp1_mipi_in: endpoint@0 { + reg = <0>; + remote-endpoint = <&dphy_tx1rx1_out>; + }; + }; +}; + +&route_edp { + status = "okay"; +}; + +&pinctrl { + lcd-panel { + lcd_panel_reset: lcd-panel-reset { + rockchip,pins = <4 30 RK_FUNC_GPIO &pcfg_pull_up>; + }; + }; + + hdmiin { + hdmiin_gpios: hdmiin_gpios { + rockchip,pins = + <2 5 RK_FUNC_GPIO &pcfg_pull_none>, + <2 6 RK_FUNC_GPIO &pcfg_pull_none>, + <2 7 RK_FUNC_GPIO &pcfg_pull_none>, + <2 8 RK_FUNC_GPIO &pcfg_pull_none>, + <2 9 RK_FUNC_GPIO &pcfg_pull_none>, + <2 12 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; +}; + diff --git a/arch/arm64/boot/dts/rockchip/rk3399-tve1030g.dts b/arch/arm64/boot/dts/rockchip/rk3399-tve1030g.dts index ebf7a8f23877..d7ef165ba7a4 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-tve1030g.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-tve1030g.dts @@ -341,6 +341,27 @@ status = "okay"; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + &gpu { status = "okay"; mali-supply = <&vdd_gpu>; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-tve1205g.dts b/arch/arm64/boot/dts/rockchip/rk3399-tve1205g.dts index 08b6444fbbd1..21e33fae2cf7 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-tve1205g.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-tve1205g.dts @@ -435,6 +435,27 @@ status = "okay"; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + &gpu { status = "okay"; mali-supply = <&vdd_gpu>; diff --git a/arch/arm64/boot/dts/rockchip/rk3399pro-evb-v10.dts b/arch/arm64/boot/dts/rockchip/rk3399pro-evb-v10.dts index c565d489711f..2e42a2183196 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399pro-evb-v10.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399pro-evb-v10.dts @@ -283,6 +283,27 @@ pinctrl-0 = <&uart2a_xfer>; }; +&firmware_android { + compatible = "android,firmware"; + fstab { + compatible = "android,fstab"; + system { + compatible = "android,system"; + dev = "/dev/block/by-name/system"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + vendor { + compatible = "android,vendor"; + dev = "/dev/block/by-name/vendor"; + type = "ext4"; + mnt_flags = "ro,barrier=1,inode_readahead_blks=8"; + fsmgr_flags = "wait,verify"; + }; + }; +}; + &gmac { phy-supply = <&vcc_phy>; phy-mode = "rgmii";