arm64: dts: qcom: msm8916-wingtech-wt88047: Add IMU
authorStephan Gerhold <stephan@gerhold.net>
Mon, 12 Jul 2021 13:37:35 +0000 (15:37 +0200)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Mon, 19 Jul 2021 19:54:06 +0000 (14:54 -0500)
The Xiaomi Redmi 2 has an InvenSense MPU-6880 supported by the
inv_mpu6050 driver in Linux. Add it to the device tree.

Signed-off-by: Stephan Gerhold <stephan@gerhold.net>
Link: https://lore.kernel.org/r/20210712133735.318250-4-stephan@gerhold.net
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
arch/arm64/boot/dts/qcom/msm8916-wingtech-wt88047.dts

index 9d9e85e..4e20cc0 100644 (file)
        };
 };
 
+&blsp_i2c2 {
+       status = "okay";
+
+       imu@68 {
+               compatible = "invensense,mpu6880";
+               reg = <0x68>;
+
+               interrupt-parent = <&msmgpio>;
+               interrupts = <115 IRQ_TYPE_EDGE_RISING>;
+
+               vdd-supply = <&pm8916_l17>;
+               vddio-supply = <&pm8916_l6>;
+
+               pinctrl-names = "default";
+               pinctrl-0 = <&imu_default>;
+
+               mount-matrix = "1",  "0", "0",
+                              "0", "-1", "0",
+                              "0",  "0", "1";
+       };
+};
+
 &blsp_i2c5 {
        status = "okay";
 
                bias-pull-up;
        };
 
+       imu_default: imu-default {
+               pins = "gpio115";
+               function = "gpio";
+
+               drive-strength = <2>;
+               bias-disable;
+       };
+
        touchscreen_default: touchscreen-default {
                pins = "gpio13";
                function = "gpio";