From 30ed75c6a16f60cdaab24c662956d806ce2ca562 Mon Sep 17 00:00:00 2001 From: Zhou weixin Date: Fri, 19 Jan 2018 14:24:43 +0800 Subject: [PATCH] arm64: dts: rockchip: add some peripheral configuration for px30-evb-ddr4-v10.dts Change-Id: Ib06470461d3fb70c57c0f88724c29dec28237600 Signed-off-by: Weixin Zhou --- .../devicetree/bindings/arm/rockchip.txt | 4 + .../boot/dts/rockchip/px30-evb-ddr4-v10.dts | 157 ++++++++++++++++++ 2 files changed, 161 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/rockchip.txt b/Documentation/devicetree/bindings/arm/rockchip.txt index 00f7c632db8c..a53100998463 100644 --- a/Documentation/devicetree/bindings/arm/rockchip.txt +++ b/Documentation/devicetree/bindings/arm/rockchip.txt @@ -126,3 +126,7 @@ Rockchip platforms device tree bindings - Rockchip PX30 evb ddr3 board: Required root node properties: - compatible = "rockchip,px30-evb-ddr3-v10", "rockchip,px30"; + +- Rockchip PX30 evb ddr4 board: + Required root node properties: + - compatible = "rockchip,px30-evb-ddr4-v10", "rockchip,px30"; diff --git a/arch/arm64/boot/dts/rockchip/px30-evb-ddr4-v10.dts b/arch/arm64/boot/dts/rockchip/px30-evb-ddr4-v10.dts index c031ce5c25fb..4d786ce4d099 100644 --- a/arch/arm64/boot/dts/rockchip/px30-evb-ddr4-v10.dts +++ b/arch/arm64/boot/dts/rockchip/px30-evb-ddr4-v10.dts @@ -6,11 +6,54 @@ /dts-v1/; #include +#include +#include +#include #include #include "px30.dtsi" #include "px30-android.dtsi" / { + model = "Rockchip PX30 evb ddr4 board"; + compatible = "rockchip,px30-evb-ddr4-v10", "rockchip,px30"; + + adc-keys { + compatible = "adc-keys"; + io-channels = <&saradc 2>; + io-channel-names = "buttons"; + keyup-threshold-microvolt = <1800000>; + + esc-key { + linux,code = ; + label = "esc"; + press-threshold-microvolt = <614000>; + }; + + home-key { + linux,code = ; + label = "home"; + press-threshold-microvolt = <254000>; + }; + + menu-key { + linux,code = ; + label = "menu"; + press-threshold-microvolt = <414000>; + }; + + vol-up-key { + linux,code = ; + label = "volume up"; + press-threshold-microvolt = <10000>; + }; + + vol-down-key { + linux,code = ; + label = "volume down"; + press-threshold-microvolt = <170000>; + }; + }; + backlight: backlight { compatible = "pwm-backlight"; pwms = <&pwm1 0 25000 0>; @@ -50,12 +93,49 @@ default-brightness-level = <200>; }; + sdio_pwrseq: sdio-pwrseq { + compatible = "mmc-pwrseq-simple"; + /*clocks = <&rk809 1>;*/ + /*clock-names = "ext_clock";*/ + pinctrl-names = "default"; + pinctrl-0 = <&wifi_enable_h>; + + /* + * On the module itself this is one of these (depending + * on the actual card populated): + * - SDIO_RESET_L_WL_REG_ON + * - PDN (power down when low) + */ + reset-gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_LOW>; /* GPIO3_A4 */ + }; + vcc_phy: vcc-phy-regulator { compatible = "regulator-fixed"; regulator-name = "vcc_phy"; regulator-always-on; regulator-boot-on; }; + + wireless-wlan { + compatible = "wlan-platdata"; + wifi_chip_type = "AP6210"; + WIFI,host_wake_irq = <&gpio0 RK_PB2 GPIO_ACTIVE_HIGH>; + status = "okay"; + }; + + wireless-bluetooth { + compatible = "bluetooth-platdata"; + /*clocks = <&rk809 1>;*/ + /*clock-names = "ext_clock";*/ + uart_rts_gpios = <&gpio1 RK_PC3 GPIO_ACTIVE_LOW>; + pinctrl-names = "default","rts_gpio"; + pinctrl-0 = <&uart1_rts>; + pinctrl-1 = <&uart1_rts_gpio>; + BT,reset_gpio = <&gpio0 RK_PC1 GPIO_ACTIVE_HIGH>; + BT,wake_gpio = <&gpio0 RK_PA1 GPIO_ACTIVE_HIGH>; + BT,wake_host_irq = <&gpio0 RK_PB3 GPIO_ACTIVE_HIGH>; + status = "okay"; + }; }; &display_subsystem { @@ -185,6 +265,19 @@ status = "disabled"; }; +&emmc { + bus-width = <8>; + cap-mmc-highspeed; + mmc-hs200-1_8v; + supports-emmc; + disable-wp; + non-removable; + num-slots = <1>; + pinctrl-names = "default"; + pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_bus8>; + status = "okay"; +}; + &gmac { phy-supply = <&vcc_phy>; clock_in_out = "output"; @@ -194,10 +287,42 @@ status = "okay"; }; +&i2c1 { + status = "okay"; + + ts@40 { + status = "okay"; + compatible = "GT1X"; + reg = <0x14>; + irq_gpio_number = <&gpio0 RK_PA5 IRQ_TYPE_LEVEL_LOW>; + rst_gpio_number = <&gpio0 RK_PB4 GPIO_ACTIVE_HIGH>; + }; + + sensor@4c { + status = "okay"; + compatible = "gs_mma7660"; + reg = <0x4c>; + type = ; + irq-gpio = <&gpio0 RK_PB5 IRQ_TYPE_LEVEL_LOW>; + irq_enable = <0>; + poll_delay_ms = <30>; + layout = <6>; + reprobe_en = <1>; + }; +}; + &mipi_dphy { status = "okay"; }; +&pinctrl { + sdio-pwrseq { + wifi_enable_h: wifi-enable-h { + rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; +}; + &pwm1 { status = "okay"; }; @@ -206,6 +331,38 @@ status = "okay"; }; +&saradc { + status = "okay"; +}; + +&sdmmc { + cap-mmc-highspeed; + supports-sd; + broken-cd; + card-detect-delay = <800>; + ignore-pm-notify; + keep-power-in-suspend; + /*cd-gpios = <&gpio2 4 GPIO_ACTIVE_HIGH>; [> CD GPIO <]*/ + status = "disabled"; +}; + +&sdio { + max-frequency = <50000000>; + cap-sd-highspeed; + supports-sdio; + ignore-pm-notify; + keep-power-in-suspend; + non-removable; + mmc-pwrseq = <&sdio_pwrseq>; + status = "okay"; +}; + +&uart1 { + pinctrl-names = "default"; + pinctrl-0 = <&uart1_xfer &uart1_cts>; + status = "okay"; +}; + &vopb { status = "okay"; };