* [PATCH] arm64: dts: qcom: msm8916-asus-z00l: Add sensors
@ 2021-10-10 3:37 J.R. Divya Antony
0 siblings, 0 replies; only message in thread
From: J.R. Divya Antony @ 2021-10-10 3:37 UTC (permalink / raw)
To: bjorn.andersson; +Cc: linux-arm-msm, J.R. Divya Antony
This device has MPU-6515 imu and Asahi Kasei AK09911 magnetometer.
Add support for it.
Signed-off-by: J.R. Divya Antony <d.antony.jr@gmail.com>
---
.../arm64/boot/dts/qcom/msm8916-asus-z00l.dts | 51 +++++++++++++++++++
1 file changed, 51 insertions(+)
diff --git a/arch/arm64/boot/dts/qcom/msm8916-asus-z00l.dts b/arch/arm64/boot/dts/qcom/msm8916-asus-z00l.dts
index cee451e59385..f43ad0b306f0 100644
--- a/arch/arm64/boot/dts/qcom/msm8916-asus-z00l.dts
+++ b/arch/arm64/boot/dts/qcom/msm8916-asus-z00l.dts
@@ -48,6 +48,41 @@ usb_id: usb-id {
};
};
+&blsp_i2c2 {
+ status = "okay";
+
+ magnetometer@c {
+ compatible = "asahi-kasei,ak09911";
+ reg = <0x0c>;
+
+ vdd-supply = <&pm8916_l8>;
+ vid-supply = <&pm8916_l6>;
+
+ reset-gpios = <&msmgpio 112 GPIO_ACTIVE_LOW>;
+
+ pinctrl-names = "default";
+ pinctrl-0 = <&mag_reset_default>;
+ };
+
+ imu@68 {
+ compatible = "invensense,mpu6515";
+ reg = <0x68>;
+
+ interrupt-parent = <&msmgpio>;
+ interrupts = <36 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";
+ };
+};
+
&blsp1_uart2 {
status = "okay";
};
@@ -185,6 +220,22 @@ gpio_keys_default: gpio-keys-default {
bias-pull-up;
};
+ imu_default: imu-default {
+ pins = "gpio36";
+ function = "gpio";
+
+ drive-strength = <2>;
+ bias-disable;
+ };
+
+ mag_reset_default: mag-reset-default {
+ pins = "gpio112";
+ function = "gpio";
+
+ drive-strength = <2>;
+ bias-disable;
+ };
+
usb_id_default: usb-id-default {
pins = "gpio110";
function = "gpio";
--
2.33.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2021-10-10 3:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-10 3:37 [PATCH] arm64: dts: qcom: msm8916-asus-z00l: Add sensors J.R. Divya Antony
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).