Add initial device-tree for the OnePlus 8T. Downstream reference is [1].

[1] 
https://github.com/LineageOS/android_kernel_oneplus_sm8250/blob/lineage-23.2/arch/arm64/boot/dts/vendor/oplus/kona-kebab-overlay.dts

Signed-off-by: Frieder Hannenheim <[email protected]>
Co-developed-by: Robert Oscilowski <[email protected]>
Signed-off-by: Robert Oscilowski <[email protected]>
---
 arch/arm64/boot/dts/qcom/Makefile                 |   1 +
 arch/arm64/boot/dts/qcom/sm8250-oneplus-kebab.dts | 124 ++++++++++++++++++++++
 2 files changed, 125 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/Makefile 
b/arch/arm64/boot/dts/qcom/Makefile
index 6f33c4e2f09c..d8292f681e71 100644
--- a/arch/arm64/boot/dts/qcom/Makefile
+++ b/arch/arm64/boot/dts/qcom/Makefile
@@ -356,6 +356,7 @@ dtb-$(CONFIG_ARCH_QCOM)     += 
sm8150-sony-xperia-kumano-bahamut.dtb
 dtb-$(CONFIG_ARCH_QCOM)        += sm8150-sony-xperia-kumano-griffin.dtb
 dtb-$(CONFIG_ARCH_QCOM)        += sm8250-hdk.dtb
 dtb-$(CONFIG_ARCH_QCOM)        += sm8250-mtp.dtb
+dtb-$(CONFIG_ARCH_QCOM)        += sm8250-oneplus-kebab.dtb
 dtb-$(CONFIG_ARCH_QCOM)        += sm8250-samsung-r8q.dtb
 dtb-$(CONFIG_ARCH_QCOM)        += sm8250-samsung-x1q.dtb
 dtb-$(CONFIG_ARCH_QCOM)        += sm8250-sony-xperia-edo-pdx203.dtb
diff --git a/arch/arm64/boot/dts/qcom/sm8250-oneplus-kebab.dts 
b/arch/arm64/boot/dts/qcom/sm8250-oneplus-kebab.dts
new file mode 100644
index 000000000000..3e9802db1464
--- /dev/null
+++ b/arch/arm64/boot/dts/qcom/sm8250-oneplus-kebab.dts
@@ -0,0 +1,124 @@
+// SPDX-License-Identifier: GPL-2.0-only
+
+/dts-v1/;
+
+#include "sm8250-oneplus-common.dtsi"
+
+/ {
+       model = "OnePlus 8T";
+       compatible = "oneplus,kebab", "qcom,sm8250", "qcom,kona";
+};
+
+&battery {
+       charge-full-design-microamp-hours = <4500000>;
+       energy-full-design-microwatt-hours = <19575000>;
+       voltage-max-design-microvolt = <4350000>;
+};
+
+&framebuffer {
+       width = <1080>;
+       height = <2400>;
+       stride = <(1080 * 4)>;
+};
+
+&i2c2 {
+       pm8008: pmic@8 {
+               compatible = "qcom,pm8008";
+               reg = <0x8>;
+
+               interrupt-parent = <&tlmm>;
+               interrupts = <112 IRQ_TYPE_EDGE_RISING>;
+
+               reset-gpios = <&tlmm 93 GPIO_ACTIVE_LOW>;
+
+               vdd-l1-l2-supply = <&vreg_s8c_1p3>;
+               vdd-l3-l4-supply = <&vreg_bob>;
+               vdd-l5-supply = <&vreg_bob>;
+               vdd-l6-supply = <&vreg_bob>;
+               vdd-l7-supply = <&vreg_bob>;
+
+               gpio-controller;
+               #gpio-cells = <2>;
+               gpio-ranges = <&pm8008 0 0 2>;
+
+               interrupt-controller;
+               #interrupt-cells = <2>;
+
+               #thermal-sensor-cells = <0>;
+
+               pinctrl {
+                       gpio-keys-state {
+                               pins = "gpio1";
+                               function = "normal";
+                       };
+               };
+
+               regulators {
+                       ldo1 {
+                               regulator-name = "vreg_l1p";
+                               regulator-min-microvolt = <528000>;
+                               regulator-max-microvolt = <1504000>;
+                       };
+
+                       ldo2 {
+                               regulator-name = "vreg_l2p";
+                               regulator-min-microvolt = <528000>;
+                               regulator-max-microvolt = <1300000>;
+                       };
+
+                       ldo3 {
+                               regulator-name = "vreg_l3p";
+                               regulator-min-microvolt = <1500000>;
+                               regulator-max-microvolt = <3400000>;
+                       };
+
+                       ldo4 {
+                               regulator-name = "vreg_l4p";
+                               regulator-min-microvolt = <1800000>;
+                               regulator-max-microvolt = <1800000>;
+                       };
+
+                       ldo5 {
+                               regulator-name = "vreg_l5p";
+                               regulator-min-microvolt = <1500000>;
+                               regulator-max-microvolt = <3400000>;
+                       };
+
+                       ldo6 {
+                               regulator-name = "vreg_l6p";
+                               regulator-min-microvolt = <1500000>;
+                               regulator-max-microvolt = <3400000>;
+                       };
+
+                       ldo7 {
+                               regulator-name = "vreg_l7p";
+                               regulator-min-microvolt = <1500000>;
+                               regulator-max-microvolt = <3400000>;
+                       };
+               };
+       };
+};
+
+&i2c16 {
+       status = "okay";
+
+       fuel-gauge@55 {
+               compatible = "ti,bq28z610";
+               reg = <0x55>;
+               monitored-battery = <&battery>;
+       };
+};
+
+&tlmm {
+       pm8008_default: pm8008-default-state {
+               pins = "gpio93";
+               function = "gpio";
+               bias-pull-up;
+               output-high;
+               drive-strength = <2>;
+       };
+};
+
+&vreg_f {
+       status = "disabled";
+};

-- 
2.54.0


Reply via email to