From 7dad8551b5c3f09c06936f0704e593380b43db79 Mon Sep 17 00:00:00 2001 From: Zorro Liu Date: Mon, 4 Jul 2016 09:16:43 +0800 Subject: [PATCH] ARM64: dts: rockchip: add sensor mpu6500 node for rk3399 mid board Change-Id: If78d74fccf3195e3e81b91dc6d5981929ca16319 Signed-off-by: Zorro Liu --- .../dts/rockchip/rk3399-mid-818-android.dts | 54 ++++++++++++++++++- 1 file changed, 53 insertions(+), 1 deletion(-) 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 b8931afe4552..bd873a093ce1 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-mid-818-android.dts @@ -546,6 +546,29 @@ }; }; +&i2c4 { + status = "okay"; + i2c-scl-rising-time-ns = <345>; + i2c-scl-falling-time-ns = <11>; + clock-frequency = <400000>; + + mpu6500@68 { + status = "okay"; + compatible = "invensense,mpu6500"; + pinctrl-names = "default"; + pinctrl-0 = <&mpu6500_irq_gpio>; + reg = <0x68>; + irq-gpio = <&gpio2 27 IRQ_TYPE_EDGE_RISING>; + mpu-int_config = <0x10>; + mpu-level_shifter = <0>; + mpu-orientation = <1 0 0 0 1 0 0 0 1>; + orientation-x= <1>; + orientation-y= <1>; + orientation-z= <0>; + mpu-debug = <1>; + }; +}; + &i2c5 { status = "okay"; i2c-scl-rising-time-ns = <150>; @@ -597,6 +620,29 @@ status = "okay"; }; +&spi1 { + status = "disabled"; + max-freq = <50000000>; + mpu6500@0 { + status = "disabled"; + compatible = "inv-spi,mpu6500"; + pinctrl-names = "default"; + pinctrl-0 = <&mpu6500_irq_gpio>; + irq-gpio = <&gpio2 27 IRQ_TYPE_EDGE_RISING>; + reg = <0>; + spi-max-frequency = <1000000>; + spi-cpha; + spi-cpol; + mpu-int_config = <0x00>; + mpu-level_shifter = <0>; + mpu-orientation = <1 0 0 0 1 0 0 0 1>; + orientation-x= <1>; + orientation-y= <0>; + orientation-z= <1>; + mpu-debug = <1>; + }; +}; + &tsadc { rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */ rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */ @@ -697,6 +743,12 @@ rockchip,pins = <3 8 RK_FUNC_GPIO &pcfg_pull_up>; }; }; + + mpu6500 { + mpu6500_irq_gpio: mpu6500-irq-gpio { + rockchip,pins = <2 27 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; }; &rk_screen { @@ -724,4 +776,4 @@ &edp_rk_fb { status = "okay"; -}; \ No newline at end of file +}; -- 2.34.1