From a8b948f89f888b82ddc1b83105b2cc582c7dced7 Mon Sep 17 00:00:00 2001 From: Elaine Zhang Date: Tue, 26 Apr 2016 20:49:35 +0800 Subject: [PATCH] ARM64: dts: rk3399: support for evb rev1 and evb rev2 For evb1 - rk3399-evb-rev1-android.dts - rk3399-evb-rev1-cros.dts For evb2 - rk3399-evb-rev2-android.dts - rk3399-evb-rev2-cros.dts Change-Id: I95a2d4229c0a7581ca5ae777340f4d26e86503ba Signed-off-by: Elaine Zhang Signed-off-by: Jianqun Xu --- arch/arm64/boot/dts/rockchip/Makefile | 6 +- .../{rk3399-fb.dtsi => rk3399-android.dtsi} | 113 ++++++- .../dts/rockchip/rk3399-evb-rev1-android.dts | 61 ++++ ...evb1-cros.dts => rk3399-evb-rev1-cros.dts} | 8 +- .../boot/dts/rockchip/rk3399-evb-rev1.dtsi | 291 +++++++++++++++++ .../dts/rockchip/rk3399-evb-rev2-android.dts | 56 ++++ ...evb2-cros.dts => rk3399-evb-rev2-cros.dts} | 8 +- .../boot/dts/rockchip/rk3399-evb-rev2.dtsi | 305 ++++++++++++++++++ arch/arm64/boot/dts/rockchip/rk3399-evb.dtsi | 290 ++--------------- .../boot/dts/rockchip/rk3399-evb1-android.dts | 220 ------------- .../boot/dts/rockchip/rk3399-evb2-android.dts | 216 ------------- arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 4 +- arch/arm64/boot/dts/rockchip/rk3399.dtsi | 34 +- 13 files changed, 864 insertions(+), 748 deletions(-) rename arch/arm64/boot/dts/rockchip/{rk3399-fb.dtsi => rk3399-android.dtsi} (80%) create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts rename arch/arm64/boot/dts/rockchip/{rk3399-evb1-cros.dts => rk3399-evb-rev1-cros.dts} (94%) create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-evb-rev1.dtsi create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts rename arch/arm64/boot/dts/rockchip/{rk3399-evb2-cros.dts => rk3399-evb-rev2-cros.dts} (94%) create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-evb-rev2.dtsi delete mode 100644 arch/arm64/boot/dts/rockchip/rk3399-evb1-android.dts delete mode 100644 arch/arm64/boot/dts/rockchip/rk3399-evb2-android.dts diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile index 6563eaa2029f..b49430168a38 100644 --- a/arch/arm64/boot/dts/rockchip/Makefile +++ b/arch/arm64/boot/dts/rockchip/Makefile @@ -2,8 +2,10 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3366-fpga.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3366-tb.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3368-r88.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3368-tb-sheep.dtb -dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-evb1-android.dtb -dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-evb1-cros.dtb +dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-evb-rev1-android.dtb +dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-evb-rev1-cros.dtb +dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-evb-rev2-android.dtb +dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-evb-rev2-cros.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-fpga.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-gru-gru.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-gru-kevin-r0.dtb diff --git a/arch/arm64/boot/dts/rockchip/rk3399-fb.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-android.dtsi similarity index 80% rename from arch/arm64/boot/dts/rockchip/rk3399-fb.dtsi rename to arch/arm64/boot/dts/rockchip/rk3399-android.dtsi index 1679a0ee27d0..49edcbbf9c96 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-fb.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-android.dtsi @@ -43,6 +43,103 @@ #include / { + compatible = "rockchip,android", "rockchip,rk3399"; + + chosen { + bootargs = "console=uart,mmio32,0xff1a0000"; + }; + + ramoops_mem: ramoops_mem { + reg = <0x0 0x100000 0x0 0x100000>; + reg-names = "ramoops_mem"; + }; + + ramoops { + compatible = "ramoops"; + record-size = <0x0 0x20000>; + console-size = <0x0 0x80000>; + ftrace-size = <0x0 0x10000>; + pmsg-size = <0x0 0x50000>; + memory-region = <&ramoops_mem>; + }; + + reserved-memory { + #address-cells = <2>; + #size-cells = <2>; + ranges; + + /* global autoconfigured region for contiguous allocations */ + linux,cma { + compatible = "shared-dma-pool"; + reusable; + size = <0x0 0x8000000>; + linux,cma-default; + }; + }; + + ion { + compatible = "rockchip,ion"; + #address-cells = <1>; + #size-cells = <0>; + + cma-heap { + reg = <0x00000000 0x02000000>; + }; + + system-heap { + }; + }; + + rk_key: rockchip-key { + compatible = "rockchip,key"; + status = "okay"; + + io-channels = <&saradc 1>; + + vol-up-key { + linux,code = <115>; + label = "volume up"; + rockchip,adc_value = <1>; + }; + + vol-down-key { + linux,code = <114>; + label = "volume down"; + rockchip,adc_value = <170>; + }; + + power-key { + gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; + linux,code = <116>; + label = "power"; + gpio-key,wakeup; + }; + + menu-key { + linux,code = <59>; + label = "menu"; + rockchip,adc_value = <746>; + }; + + home-key { + linux,code = <102>; + label = "home"; + rockchip,adc_value = <355>; + }; + + back-key { + linux,code = <158>; + label = "back"; + rockchip,adc_value = <560>; + }; + + camera-key { + linux,code = <212>; + label = "camera"; + rockchip,adc_value = <450>; + }; + }; + vpu: vpu_service@ff650000 { compatible = "rockchip,vpu_service"; rockchip,grf = <&grf>; @@ -57,7 +154,6 @@ reset-names = "video_h", "video_a"; name = "vpu_service"; dev_mode = <0>; - status = "disabled"; }; vpu_mmu: vpu_mmu { @@ -66,7 +162,6 @@ reg = <0x0 0xff650800 0x0 0x40>; interrupts = ; interrupt-names = "vpu_mmu"; - status = "disabled"; }; rkvdec: rkvdec@ff660000 { @@ -82,7 +177,6 @@ reset-names = "video_h", "video_a"; dev_mode = <2>; name = "rkvdec"; - status = "disabled"; }; vdec_mmu: vdec_mmu { @@ -92,7 +186,6 @@ <0x0 0xff6604c0 0x0 0x40>; interrupts = ; interrupt-names = "vdec_mmu"; - status = "disabled"; }; iep: iep@ff670000 { @@ -103,7 +196,6 @@ clocks = <&cru ACLK_IEP>, <&cru HCLK_IEP>; clock-names = "aclk_iep", "hclk_iep"; version = <2>; - status = "disabled"; }; iep_mmu: iep-mmu { @@ -112,7 +204,6 @@ reg = <0x0 0xff670800 0x0 0x40>; interrupts = ; interrupt-names = "iep_mmu"; - status = "disabled"; }; rga: rga@ff680000 { @@ -122,22 +213,19 @@ interrupts = ; clocks = <&cru ACLK_RGA>, <&cru HCLK_RGA>, <&cru SCLK_RGA_CORE>; clock-names = "aclk_rga", "hclk_rga", "clk_rga"; - status = "disabled"; }; fb: fb { compatible = "rockchip,rk-fb"; rockchip,disp-mode = ; - status = "disabled"; }; rk_screen: screen { compatible = "rockchip,screen"; - status = "disabled"; + #include }; vopb_rk_fb: vop-rk-fb@ff900000 { - status = "disabled"; compatible = "rockchip,rk3399-lcdc"; rockchip,prop = ; reg = <0x0 0xff900000 0x0 0x3efc>; @@ -178,7 +266,6 @@ reg = <0x0 0xff903f00 0x0 0x100>; interrupts = ; interrupt-names = "vopb_mmu"; - status = "okay"; }; vopl_rk_fb: vop-rk-fb@ff8f0000 { @@ -193,7 +280,6 @@ rockchip,grf = <&grf>; rockchip,pwr18 = <0>; rockchip,iommu-enabled = <1>; - status = "disabled"; }; vopl_mmu_rk_fb: vopl-mmu { @@ -202,7 +288,6 @@ reg = <0x0 0xff8f3f00 0x0 0x100>; interrupts = ; interrupt-names = "vopl_mmu"; - status = "okay"; }; hdmi_rk_fb: hdmi-rk-fb@ff940000 { @@ -219,7 +304,6 @@ interrupts = ; clocks = <&cru SCLK_MIPIDPHY_REF>, <&cru PCLK_MIPI_DSI0>, <&cru SCLK_MIPIDPHY_CFG>; clock-names = "clk_mipi_24m", "pclk_mipi_dsi", "mipi_dphy_cfg"; - status = "disabled"; }; mipi1_rk_fb: mipi-rk-fb@ff968000 { @@ -229,6 +313,5 @@ interrupts = ; clocks = <&cru SCLK_MIPIDPHY_REF>, <&cru PCLK_MIPI_DSI1>, <&cru SCLK_MIPIDPHY_CFG>; clock-names = "clk_mipi_24m", "pclk_mipi_dsi", "mipi_dphy_cfg"; - status = "disabled"; }; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts new file mode 100644 index 000000000000..f048f6c2787c --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-android.dts @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2016 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-evb-rev1.dtsi" +#include "rk3399-android.dtsi" + +/ { + model = "Rockchip RK3399 Evaluation Board v1 (Android)"; + compatible = "rockchip,android", "rockchip,rk3399-evb-rev1", "rockchip,rk3399"; +}; + +&vdd_log { + rockchip,pwm_id= <2>; + rockchip,pwm_voltage = <900000>; +}; + +&vdd_center { + rockchip,pwm_id= <3>; + rockchip,pwm_voltage = <900000>; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb1-cros.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-cros.dts similarity index 94% rename from arch/arm64/boot/dts/rockchip/rk3399-evb1-cros.dts rename to arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-cros.dts index f5601e454f73..758aa5da505c 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb1-cros.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1-cros.dts @@ -41,14 +41,12 @@ */ /dts-v1/; -#include "rk3399-evb.dtsi" + +#include "rk3399-evb-rev1.dtsi" / { model = "Rockchip RK3399 Evaluation Board v1 (Chrome OS)"; - compatible = "google,rk3399evb-rev1", "rockchip,chrome", "rockchip,evb1", "rockchip,rk3399"; - - /delete-node/ vdd-log; - /delete-node/ vdd-center; + compatible = "google,rk3399evb-rev1", "rockchip,rk3399-evb-rev1", "rockchip,rk3399"; edp_panel: edp-panel { compatible = "lg,lp097qx1-spa1", "panel-simple"; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1.dtsi new file mode 100644 index 000000000000..2d68c158d6d3 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev1.dtsi @@ -0,0 +1,291 @@ +/* + * Copyright (c) 2016 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. + */ + +#include "rk3399-evb.dtsi" + +/ { + compatible = "rockchip,rk3399-evb-rev1", "rockchip,rk3399"; + + vdd_log: vdd-log { + compatible = "pwm-regulator"; + pwms = <&pwm2 0 25000 0>; + regulator-name = "vdd_log"; + regulator-min-microvolt = <800000>; + regulator-max-microvolt = <1400000>; + regulator-always-on; + regulator-boot-on; + }; +}; + +&i2c0 { + mp8865: mp8865@68 { + compatible = "mps,mp8865"; + reg = <0x68>; + regulators { + vdd_gpu: mp8865_dcdc1 { + regulator-name = "vdd_gpu"; + regulator-min-microvolt = <712500>; + regulator-max-microvolt = <1500000>; + regulator-always-on; + regulator-boot-on; + }; + }; + }; + + rk808: pmic@1b { + compatible = "rockchip,rk808"; + reg = <0x1b>; + interrupt-parent = <&gpio1>; + interrupts = <21 IRQ_TYPE_LEVEL_LOW>; + pinctrl-names = "default"; + pinctrl-0 = <&pmic_int_l &pmic_dvs2>; + rockchip,system-power-controller; + wakeup-source; + #clock-cells = <1>; + clock-output-names = "xin32k", "rk808-clkout2"; + + vcc1-supply = <&vcc3v3_sys>; + vcc2-supply = <&vcc3v3_sys>; + vcc3-supply = <&vcc3v3_sys>; + vcc4-supply = <&vcc3v3_sys>; + vcc6-supply = <&vcc3v3_sys>; + vcc7-supply = <&vcc3v3_sys>; + vcc8-supply = <&vcc3v3_sys>; + vcc9-supply = <&vcc3v3_sys>; + vcc10-supply = <&vcc3v3_sys>; + vcc11-supply = <&vcc3v3_sys>; + vcc12-supply = <&vcc3v3_sys>; + vddio-supply = <&vcc1v8_pmu>; + + regulators { + vdd_cpu_b: DCDC_REG1 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <750000>; + regulator-max-microvolt = <1350000>; + regulator-name = "vdd_cpu_b"; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + vdd_cpu_l: DCDC_REG2 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <750000>; + regulator-max-microvolt = <1350000>; + regulator-name = "vdd_cpu_l"; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + vcc_ddr: DCDC_REG3 { + regulator-always-on; + regulator-boot-on; + regulator-name = "vcc_ddr"; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + + vcc_1v8: DCDC_REG4 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcc_1v8"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc1v8_dvp: LDO_REG1 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcc1v8_dvp"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc3v0_tp: LDO_REG2 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "vcc3v0_tp"; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + vcc1v8_pmu: LDO_REG3 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcc1v8_pmu"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc_sd: LDO_REG4 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + regulator-name = "vcc_sd"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <3300000>; + }; + }; + + vcca3v0_codec: LDO_REG5 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "vcca3v0_codec"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <3000000>; + }; + }; + + vcc_1v5: LDO_REG6 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1500000>; + regulator-max-microvolt = <1500000>; + regulator-name = "vcc_1v5"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1500000>; + }; + }; + + vcca1v8_codec: LDO_REG7 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcca1v8_codec"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc_3v0: LDO_REG8 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "vcc_3v0"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <3000000>; + }; + }; + + vcc3v3_s3: SWITCH_REG1 { + regulator-always-on; + regulator-boot-on; + regulator-name = "vcc3v3_s3"; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + + vcc3v3_s0: SWITCH_REG2 { + regulator-always-on; + regulator-boot-on; + regulator-name = "vcc3v3_s0"; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + }; + }; +}; + +&cpu_l0 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_l1 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_l2 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_l3 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_b0 { + cpu-supply = <&vdd_cpu_b>; +}; + +&cpu_b1 { + cpu-supply = <&vdd_cpu_b>; +}; + +&gpu { + status = "okay"; + mali-supply = <&vdd_gpu>; +}; + +&pwm2 { + status = "okay"; +}; + diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts new file mode 100644 index 000000000000..d7cd846c215f --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-android.dts @@ -0,0 +1,56 @@ +/* + * Copyright (c) 2016 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-evb-rev2.dtsi" +#include "rk3399-android.dtsi" + +/ { + model = "Rockchip RK3399 Evaluation Board v2 (Android)"; + compatible = "rockchip,android", "rockchip,rk3399-evb-rev2", "rockchip,rk3399"; +}; + +&vdd_center { + rockchip,pwm_id= <3>; + rockchip,pwm_voltage = <900000>; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb2-cros.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-cros.dts similarity index 94% rename from arch/arm64/boot/dts/rockchip/rk3399-evb2-cros.dts rename to arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-cros.dts index be9ecacbab95..b0113d91b729 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb2-cros.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2-cros.dts @@ -41,14 +41,12 @@ */ /dts-v1/; -#include "rk3399-evb.dtsi" + +#include "rk3399-evb-rev2.dtsi" / { model = "Rockchip RK3399 Evaluation Board v2 (Chrome OS)"; - compatible = "google,rk3399evb-rev2", "rockchip,chrome", "rockchip,evb2", "rockchip,rk3399"; - - /delete-node/ vdd-log; - /delete-node/ vdd-center; + compatible = "google,rk3399evb-rev2", "rockchip,rk3399-evb-rev2", "rockchip,rk3399"; edp_panel: edp-panel { compatible = "lg,lp097qx1-spa1", "panel-simple"; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2.dtsi new file mode 100644 index 000000000000..8331e889ccd5 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb-rev2.dtsi @@ -0,0 +1,305 @@ +/* + * Copyright (c) 2016 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. + */ + +#include "rk3399-evb.dtsi" + +/ { + compatible = "rockchip,rk3399-evb-rev2", "rockchip,rk3399"; + + vcc5v0_sys: vcc5v0-sys { + compatible = "regulator-fixed"; + regulator-name = "vcc5v0_sys"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + }; +}; + +&i2c0 { + vdd_cpu_b: syr827@40 { + compatible = "silergy,syr827"; + reg = <0x40>; + vin-supply = <&vcc5v0_sys>; + regulator-compatible = "fan53555-reg"; + regulator-name = "vdd_cpu_b"; + regulator-min-microvolt = <712500>; + regulator-max-microvolt = <1500000>; + regulator-ramp-delay = <1000>; + fcs,suspend-voltage-selector = <1>; + regulator-always-on; + regulator-boot-on; + regulator-initial-state = <3>; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + lp8752: lp8752@60 { + compatible = "ti,lp8752"; + reg = <0x60>; + vin0-supply = <&vcc5v0_sys>; + regulators { + vdd_gpu: lp8752_buck0 { + regulator-name = "vdd_gpu"; + regulator-min-microvolt = <735000>; + regulator-max-microvolt = <1400000>; + regulator-always-on; + regulator-boot-on; + }; + }; + }; + + rk808: pmic@1b { + compatible = "rockchip,rk808"; + reg = <0x1b>; + interrupt-parent = <&gpio1>; + interrupts = <21 IRQ_TYPE_LEVEL_LOW>; + pinctrl-names = "default"; + pinctrl-0 = <&pmic_int_l &pmic_dvs2>; + rockchip,system-power-controller; + wakeup-source; + #clock-cells = <1>; + clock-output-names = "xin32k", "rk808-clkout2"; + + vcc1-supply = <&vcc3v3_sys>; + vcc2-supply = <&vcc3v3_sys>; + vcc3-supply = <&vcc3v3_sys>; + vcc4-supply = <&vcc3v3_sys>; + vcc6-supply = <&vcc3v3_sys>; + vcc7-supply = <&vcc3v3_sys>; + vcc8-supply = <&vcc3v3_sys>; + vcc9-supply = <&vcc3v3_sys>; + vcc10-supply = <&vcc3v3_sys>; + vcc11-supply = <&vcc3v3_sys>; + vcc12-supply = <&vcc3v3_sys>; + vddio-supply = <&vcc1v8_pmu>; + + regulators { + vdd_log: DCDC_REG1 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <750000>; + regulator-max-microvolt = <1350000>; + regulator-name = "vdd_log"; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + vdd_cpu_l: DCDC_REG2 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <750000>; + regulator-max-microvolt = <1350000>; + regulator-name = "vdd_cpu_l"; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + vcc_ddr: DCDC_REG3 { + regulator-always-on; + regulator-boot-on; + regulator-name = "vcc_ddr"; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + + vcc_1v8: DCDC_REG4 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcc_1v8"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc1v8_dvp: LDO_REG1 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcc1v8_dvp"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc3v0_tp: LDO_REG2 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "vcc3v0_tp"; + regulator-state-mem { + regulator-off-in-suspend; + }; + }; + + vcc1v8_pmu: LDO_REG3 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcc1v8_pmu"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc_sd: LDO_REG4 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + regulator-name = "vcc_sd"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <3300000>; + }; + }; + + vcca3v0_codec: LDO_REG5 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "vcca3v0_codec"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <3000000>; + }; + }; + + vcc_1v5: LDO_REG6 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1500000>; + regulator-max-microvolt = <1500000>; + regulator-name = "vcc_1v5"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1500000>; + }; + }; + + vcca1v8_codec: LDO_REG7 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-name = "vcca1v8_codec"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <1800000>; + }; + }; + + vcc_3v0: LDO_REG8 { + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "vcc_3v0"; + regulator-state-mem { + regulator-on-in-suspend; + regulator-suspend-microvolt = <3000000>; + }; + }; + + vcc3v3_s3: SWITCH_REG1 { + regulator-always-on; + regulator-boot-on; + regulator-name = "vcc3v3_s3"; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + + vcc3v3_s0: SWITCH_REG2 { + regulator-always-on; + regulator-boot-on; + regulator-name = "vcc3v3_s0"; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + }; + }; +}; + +&cpu_l0 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_l1 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_l2 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_l3 { + cpu-supply = <&vdd_cpu_l>; +}; + +&cpu_b0 { + cpu-supply = <&vdd_cpu_b>; +}; + +&cpu_b1 { + cpu-supply = <&vdd_cpu_b>; +}; + +&gpu { + status = "okay"; + mali-supply = <&vdd_gpu>; +}; + diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-evb.dtsi index d0549f7d10c9..8af39d8891e8 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-evb.dtsi @@ -44,18 +44,7 @@ #include "rk3399.dtsi" / { - compatible = "rockchip,evb", "rockchip,rk3399"; - - vdd_log: vdd-log { - compatible = "pwm-regulator"; - pwms = <&pwm2 0 25000 0>; - regulator-name = "vdd_log"; - regulator-min-microvolt = <800000>; - regulator-max-microvolt = <1400000>; - regulator-always-on; - regulator-boot-on; - status = "okay"; - }; + compatible = "rockchip,rk3399-evb", "rockchip,rk3399"; vdd_center: vdd-center { compatible = "pwm-regulator"; @@ -65,7 +54,6 @@ regulator-max-microvolt = <1400000>; regulator-always-on; regulator-boot-on; - status = "okay"; }; vcc3v3_sys: vcc3v3-sys { @@ -211,26 +199,6 @@ }; }; -&pinctrl { - sdio-pwrseq { - wifi_enable_h: wifi-enable-h { - rockchip,pins = <0 10 RK_FUNC_GPIO &pcfg_pull_none>; - }; - }; - - pmic { - pmic_int_l: pmic-int-l { - rockchip,pins = - <1 21 RK_FUNC_GPIO &pcfg_pull_up>; - }; - - pmic_dvs2: pmic-dvs2 { - rockchip,pins = - <1 18 RK_FUNC_GPIO &pcfg_pull_down>; - }; - }; -}; - &sdmmc { clock-frequency = <37500000>; clock-freq-min-max = <400000 37500000>; @@ -296,205 +264,6 @@ status = "okay"; i2c-scl-rising-time-ns = <450>; i2c-scl-falling-time-ns = <15>; - - mp8865: mp8865@68 { - compatible = "mps,mp8865"; - reg = <0x68>; - status = "okay"; - regulators { - vdd_gpu: mp8865_dcdc1 { - regulator-name = "vdd_gpu"; - regulator-min-microvolt = <712500>; - regulator-max-microvolt = <1500000>; - regulator-always-on; - regulator-boot-on; - }; - }; - }; - - rk808: pmic@1b { - compatible = "rockchip,rk808"; - reg = <0x1b>; - interrupt-parent = <&gpio1>; - interrupts = <21 IRQ_TYPE_LEVEL_LOW>; - pinctrl-names = "default"; - pinctrl-0 = <&pmic_int_l &pmic_dvs2>; - rockchip,system-power-controller; - wakeup-source; - #clock-cells = <1>; - clock-output-names = "xin32k", "rk808-clkout2"; - - vcc1-supply = <&vcc3v3_sys>; - vcc2-supply = <&vcc3v3_sys>; - vcc3-supply = <&vcc3v3_sys>; - vcc4-supply = <&vcc3v3_sys>; - vcc6-supply = <&vcc3v3_sys>; - vcc7-supply = <&vcc3v3_sys>; - vcc8-supply = <&vcc3v3_sys>; - vcc9-supply = <&vcc3v3_sys>; - vcc10-supply = <&vcc3v3_sys>; - vcc11-supply = <&vcc3v3_sys>; - vcc12-supply = <&vcc3v3_sys>; - vddio-supply = <&vcc1v8_pmu>; - - regulators { - vdd_cpu_b: DCDC_REG1 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <750000>; - regulator-max-microvolt = <1350000>; - regulator-name = "vdd_cpu_b"; - regulator-state-mem { - regulator-off-in-suspend; - }; - }; - - vdd_cpu_l: DCDC_REG2 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <750000>; - regulator-max-microvolt = <1350000>; - regulator-name = "vdd_cpu_l"; - regulator-state-mem { - regulator-off-in-suspend; - }; - }; - - vcc_ddr: DCDC_REG3 { - regulator-always-on; - regulator-boot-on; - regulator-name = "vcc_ddr"; - regulator-state-mem { - regulator-on-in-suspend; - }; - }; - - vcc_1v8: DCDC_REG4 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; - regulator-name = "vcc_1v8"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <1800000>; - }; - }; - - vcc1v8_dvp: LDO_REG1 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; - regulator-name = "vcc1v8_dvp"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <1800000>; - }; - }; - - vcc3v0_tp: LDO_REG2 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <3000000>; - regulator-max-microvolt = <3000000>; - regulator-name = "vcc3v0_tp"; - regulator-state-mem { - regulator-off-in-suspend; - }; - }; - - vcc1v8_pmu: LDO_REG3 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; - regulator-name = "vcc1v8_pmu"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <1800000>; - }; - }; - - vcc_sd: LDO_REG4 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <3300000>; - regulator-name = "vcc_sd"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <3300000>; - }; - }; - - vcca3v0_codec: LDO_REG5 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <3000000>; - regulator-max-microvolt = <3000000>; - regulator-name = "vcca3v0_codec"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <3000000>; - }; - }; - - vcc_1v5: LDO_REG6 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1500000>; - regulator-max-microvolt = <1500000>; - regulator-name = "vcc_1v5"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <1500000>; - }; - }; - - vcca1v8_codec: LDO_REG7 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; - regulator-name = "vcca1v8_codec"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <1800000>; - }; - }; - - vcc_3v0: LDO_REG8 { - regulator-always-on; - regulator-boot-on; - regulator-min-microvolt = <3000000>; - regulator-max-microvolt = <3000000>; - regulator-name = "vcc_3v0"; - regulator-state-mem { - regulator-on-in-suspend; - regulator-suspend-microvolt = <3000000>; - }; - }; - - vcc3v3_s3: SWITCH_REG1 { - regulator-always-on; - regulator-boot-on; - regulator-name = "vcc3v3_s3"; - regulator-state-mem { - regulator-on-in-suspend; - }; - }; - - vcc3v3_s0: SWITCH_REG2 { - regulator-always-on; - regulator-boot-on; - regulator-name = "vcc3v3_s0"; - regulator-state-mem { - regulator-on-in-suspend; - }; - }; - }; - }; }; &i2c4 { @@ -530,14 +299,6 @@ }; }; -&pwm2 { - status = "okay"; -}; - -&pwm3 { - status = "okay"; -}; - &tsadc { rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */ rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */ @@ -552,7 +313,7 @@ vbus_drv-gpio = <&gpio4 25 GPIO_ACTIVE_HIGH>; }; -&usb_host0_echi { +&usb_host0_ehci { status = "okay"; }; @@ -560,7 +321,7 @@ status = "okay"; }; -&usb_host1_echi { +&usb_host1_ehci { status = "okay"; }; @@ -588,28 +349,8 @@ status = "okay"; }; -&cpu_l0 { - cpu-supply = <&vdd_cpu_l>; -}; - -&cpu_l1 { - cpu-supply = <&vdd_cpu_l>; -}; - -&cpu_l2 { - cpu-supply = <&vdd_cpu_l>; -}; - -&cpu_l3 { - cpu-supply = <&vdd_cpu_l>; -}; - -&cpu_b0 { - cpu-supply = <&vdd_cpu_b>; -}; - -&cpu_b1 { - cpu-supply = <&vdd_cpu_b>; +&pwm3 { + status = "okay"; }; &gmac { @@ -628,7 +369,22 @@ status = "okay"; }; -&gpu { - mali-supply = <&vdd_gpu>; - status = "okay"; +&pinctrl { + sdio-pwrseq { + wifi_enable_h: wifi-enable-h { + rockchip,pins = <0 10 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + pmic { + pmic_int_l: pmic-int-l { + rockchip,pins = + <1 21 RK_FUNC_GPIO &pcfg_pull_up>; + }; + + pmic_dvs2: pmic-dvs2 { + rockchip,pins = + <1 18 RK_FUNC_GPIO &pcfg_pull_down>; + }; + }; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb1-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb1-android.dts deleted file mode 100644 index 05da8bbd0f6a..000000000000 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb1-android.dts +++ /dev/null @@ -1,220 +0,0 @@ -/* - * Copyright (c) 2016 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-evb.dtsi" -#include "rk3399-fb.dtsi" - -/ { - model = "Rockchip RK3399 Evaluation Board v1 (Android)"; - compatible = "rockchip,android", "rockchip,rk3399-evb1", "rockchip,rk3399"; - - chosen { - bootargs = "console=uart,mmio32,0xff1a0000"; - }; - - ramoops_mem: ramoops_mem { - reg = <0x0 0x100000 0x0 0x100000>; - reg-names = "ramoops_mem"; - }; - - ramoops { - compatible = "ramoops"; - record-size = <0x0 0x20000>; - console-size = <0x0 0x80000>; - ftrace-size = <0x0 0x10000>; - pmsg-size = <0x0 0x50000>; - memory-region = <&ramoops_mem>; - }; - - reserved-memory { - #address-cells = <2>; - #size-cells = <2>; - ranges; - - /* global autoconfigured region for contiguous allocations */ - linux,cma { - compatible = "shared-dma-pool"; - reusable; - size = <0x0 0x8000000>; - linux,cma-default; - }; - }; - - ion { - compatible = "rockchip,ion"; - #address-cells = <1>; - #size-cells = <0>; - - cma-heap { - reg = <0x00000000 0x02000000>; - }; - - system-heap { - }; - }; - - rk_key: rockchip-key { - compatible = "rockchip,key"; - status = "okay"; - - io-channels = <&saradc 1>; - - vol-up-key { - linux,code = <115>; - label = "volume up"; - rockchip,adc_value = <1>; - }; - - vol-down-key { - linux,code = <114>; - label = "volume down"; - rockchip,adc_value = <170>; - }; - - power-key { - gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; - linux,code = <116>; - label = "power"; - gpio-key,wakeup; - }; - - menu-key { - linux,code = <59>; - label = "menu"; - rockchip,adc_value = <746>; - }; - - home-key { - linux,code = <102>; - label = "home"; - rockchip,adc_value = <355>; - }; - - back-key { - linux,code = <158>; - label = "back"; - rockchip,adc_value = <560>; - }; - - camera-key { - linux,code = <212>; - label = "camera"; - rockchip,adc_value = <450>; - }; - }; -}; - -&vdd_log { - rockchip,pwm_id= <2>; - rockchip,pwm_voltage = <900000>; -}; - -&vdd_center { - rockchip,pwm_id= <3>; - rockchip,pwm_voltage = <900000>; -}; - -&fb { - status = "okay"; -}; - -&rk_screen { - status = "okay"; - #include -}; - -&vopl_rk_fb { - status = "okay"; -}; - -&vopb_rk_fb { - status = "okay"; -}; - -&rga { - status = "okay"; -}; - -&hdmi_rk_fb { - status = "disabled"; -}; - -&mipi0_rk_fb { - status = "okay"; -}; - -&mipi1_rk_fb{ - status = "disabled"; -}; - -&saradc { - status = "okay"; -}; - -&usbdrd_dwc3_0 { - dr_mode = "peripheral"; -}; - -&vpu { - status = "okay"; -}; - -&rkvdec { - status = "okay"; -}; - -&vpu_mmu { - status = "okay"; -}; - -&vdec_mmu { - status = "okay"; -}; - -&iep { - status = "okay"; -}; - -&iep_mmu { - status = "okay"; -}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-evb2-android.dts b/arch/arm64/boot/dts/rockchip/rk3399-evb2-android.dts deleted file mode 100644 index e0469ede64df..000000000000 --- a/arch/arm64/boot/dts/rockchip/rk3399-evb2-android.dts +++ /dev/null @@ -1,216 +0,0 @@ -/* - * Copyright (c) 2016 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-evb.dtsi" -#include "rk3399-fb.dtsi" - -/ { - model = "Rockchip RK3399 Evaluation Board v2 (Android)"; - compatible = "rockchip,android", "rockchip,rk3399-evb2", "rockchip,rk3399"; - - chosen { - bootargs = "console=uart,mmio32,0xff1a0000"; - }; - - ramoops_mem: ramoops_mem { - reg = <0x0 0x100000 0x0 0x100000>; - reg-names = "ramoops_mem"; - }; - - ramoops { - compatible = "ramoops"; - record-size = <0x0 0x20000>; - console-size = <0x0 0x80000>; - ftrace-size = <0x0 0x10000>; - pmsg-size = <0x0 0x50000>; - memory-region = <&ramoops_mem>; - }; - - reserved-memory { - #address-cells = <2>; - #size-cells = <2>; - ranges; - - /* global autoconfigured region for contiguous allocations */ - linux,cma { - compatible = "shared-dma-pool"; - reusable; - size = <0x0 0x8000000>; - linux,cma-default; - }; - }; - - ion { - compatible = "rockchip,ion"; - #address-cells = <1>; - #size-cells = <0>; - - cma-heap { - reg = <0x00000000 0x02000000>; - }; - - system-heap { - }; - }; - - rk_key: rockchip-key { - compatible = "rockchip,key"; - status = "okay"; - - io-channels = <&saradc 1>; - - vol-up-key { - linux,code = <115>; - label = "volume up"; - rockchip,adc_value = <1>; - }; - - vol-down-key { - linux,code = <114>; - label = "volume down"; - rockchip,adc_value = <170>; - }; - - power-key { - gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; - linux,code = <116>; - label = "power"; - gpio-key,wakeup; - }; - - menu-key { - linux,code = <59>; - label = "menu"; - rockchip,adc_value = <746>; - }; - - home-key { - linux,code = <102>; - label = "home"; - rockchip,adc_value = <355>; - }; - - back-key { - linux,code = <158>; - label = "back"; - rockchip,adc_value = <560>; - }; - - camera-key { - linux,code = <212>; - label = "camera"; - rockchip,adc_value = <450>; - }; - }; -}; - -&vdd_log { - rockchip,pwm_id= <2>; - rockchip,pwm_voltage = <900000>; -}; - -&vdd_center { - rockchip,pwm_id= <3>; - rockchip,pwm_voltage = <900000>; -}; - -&fb { - status = "okay"; -}; - -&rk_screen { - status = "okay"; - #include -}; - -&vopl_rk_fb { - status = "okay"; -}; - -&vopb_rk_fb { - status = "okay"; -}; - -&hdmi_rk_fb { - status = "disabled"; -}; - -&mipi0_rk_fb { - status = "okay"; -}; - -&mipi1_rk_fb{ - status = "disabled"; -}; - -&saradc { - status = "okay"; -}; - -&usbdrd_dwc3_0 { - dr_mode = "peripheral"; -}; - -&vpu { - status = "okay"; -}; - -&rkvdec { - status = "okay"; -}; - -&vpu_mmu { - status = "okay"; -}; - -&vdec_mmu { - status = "okay"; -}; - -&iep { - status = "okay"; -}; - -&iep_mmu { - status = "okay"; -}; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi index 43d3fa8df8d8..485d59b25364 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi @@ -810,7 +810,7 @@ ap_i2c_audio: &i2c8 { status = "okay"; }; -&usb_host0_echi { +&usb_host0_ehci { status = "okay"; }; @@ -818,7 +818,7 @@ ap_i2c_audio: &i2c8 { status = "okay"; }; -&usb_host1_echi { +&usb_host1_ehci { status = "okay"; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi index 83fbc863c42d..5bccc6c1a8c3 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi @@ -50,6 +50,7 @@ / { compatible = "rockchip,rk3399"; + interrupt-parent = <&gic>; #address-cells = <2>; #size-cells = <2>; @@ -314,7 +315,8 @@ }; sdio0: dwmmc@fe310000 { - compatible = "rockchip,rk3399-dw-mshc", "rockchip,rk3288-dw-mshc"; + compatible = "rockchip,rk3399-dw-mshc", + "rockchip,rk3288-dw-mshc"; reg = <0x0 0xfe310000 0x0 0x4000>; interrupts = ; clock-freq-min-max = <400000 150000000>; @@ -326,7 +328,8 @@ }; sdmmc: dwmmc@fe320000 { - compatible = "rockchip,rk3399-dw-mshc", "rockchip,rk3288-dw-mshc"; + compatible = "rockchip,rk3399-dw-mshc", + "rockchip,rk3288-dw-mshc"; reg = <0x0 0xfe320000 0x0 0x4000>; interrupts = ; clock-freq-min-max = <400000 150000000>; @@ -338,7 +341,7 @@ }; sdhci: sdhci@fe330000 { - compatible = "arasan,sdhci-5.1"; + compatible = "rockchip,rk3399-sdhci-5.1", "arasan,sdhci-5.1"; reg = <0x0 0xfe330000 0x0 0x10000>; interrupts = ; clocks = <&cru SCLK_EMMC>, <&cru ACLK_EMMC>; @@ -370,7 +373,7 @@ }; }; - usb_host0_echi: usb@fe380000 { + usb_host0_ehci: usb@fe380000 { compatible = "generic-ehci"; reg = <0x0 0xfe380000 0x0 0x20000>; interrupts = ; @@ -390,7 +393,7 @@ status = "disabled"; }; - usb_host1_echi: usb@fe3c0000 { + usb_host1_ehci: usb@fe3c0000 { compatible = "generic-ehci"; reg = <0x0 0xfe3c0000 0x0 0x20000>; interrupts = ; @@ -592,8 +595,8 @@ interrupts = ; reg-shift = <2>; reg-io-width = <4>; - pinctrl-names = "default"; - pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>; + pinctrl-names = "default"; + pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>; status = "disabled"; }; @@ -605,8 +608,8 @@ interrupts = ; reg-shift = <2>; reg-io-width = <4>; - pinctrl-names = "default"; - pinctrl-0 = <&uart1_xfer>; + pinctrl-names = "default"; + pinctrl-0 = <&uart1_xfer>; status = "disabled"; }; @@ -618,8 +621,8 @@ interrupts = ; reg-shift = <2>; reg-io-width = <4>; - pinctrl-names = "default"; - pinctrl-0 = <&uart2c_xfer>; + pinctrl-names = "default"; + pinctrl-0 = <&uart2c_xfer>; status = "disabled"; }; @@ -631,8 +634,8 @@ interrupts = ; reg-shift = <2>; reg-io-width = <4>; - pinctrl-names = "default"; - pinctrl-0 = <&uart3_xfer &uart3_cts &uart3_rts>; + pinctrl-names = "default"; + pinctrl-0 = <&uart3_xfer &uart3_cts &uart3_rts>; status = "disabled"; }; @@ -790,7 +793,7 @@ status = "disabled"; }; - pmu: power-management@ff31000 { + pmu: power-management@ff310000 { compatible = "rockchip,rk3399-pmu", "syscon", "simple-mfd"; reg = <0x0 0xff310000 0x0 0x1000>; @@ -1008,12 +1011,11 @@ reg = <0x0 0xff770000 0x0 0x10000>; }; - wdt0: watchdog@ff840000 { + watchdog@ff840000 { compatible = "snps,dw-wdt"; reg = <0x0 0xff840000 0x0 0x100>; clocks = <&cru PCLK_WDT>; interrupts = ; - status = "disabled"; }; spdif: spdif@ff870000 { -- 2.34.1