Skip to content

Commit 0f8861c

Browse files
mlehtimaandersson
authored andcommitted
ARM: dts: qcom: msm8226: Add tsens node and related nvmem cells
Specify pre-parsed per-sensor calibration nvmem cells in the qfprom device node rather than parsing the whole data blob in the driver. Signed-off-by: Matti Lehtimäki <matti.lehtimaki@gmail.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Luca Weiss <luca@z3ntu.xyz> Signed-off-by: Bjorn Andersson <andersson@kernel.org> Link: https://lore.kernel.org/r/20230507201225.89694-6-matti.lehtimaki@gmail.com
1 parent 16a9fa7 commit 0f8861c

1 file changed

Lines changed: 113 additions & 0 deletions

File tree

arch/arm/boot/dts/qcom-msm8226.dtsi

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,34 @@
528528
};
529529
};
530530

531+
tsens: thermal-sensor@fc4a9000 {
532+
compatible = "qcom,msm8226-tsens", "qcom,tsens-v0_1";
533+
reg = <0xfc4a9000 0x1000>, /* TM */
534+
<0xfc4a8000 0x1000>; /* SROT */
535+
nvmem-cells = <&tsens_mode>,
536+
<&tsens_base1>, <&tsens_base2>,
537+
<&tsens_s0_p1>, <&tsens_s0_p2>,
538+
<&tsens_s1_p1>, <&tsens_s1_p2>,
539+
<&tsens_s2_p1>, <&tsens_s2_p2>,
540+
<&tsens_s3_p1>, <&tsens_s3_p2>,
541+
<&tsens_s4_p1>, <&tsens_s4_p2>,
542+
<&tsens_s5_p1>, <&tsens_s5_p2>,
543+
<&tsens_s6_p1>, <&tsens_s6_p2>;
544+
nvmem-cell-names = "mode",
545+
"base1", "base2",
546+
"s0_p1", "s0_p2",
547+
"s1_p1", "s1_p2",
548+
"s2_p1", "s2_p2",
549+
"s3_p1", "s3_p2",
550+
"s4_p1", "s4_p2",
551+
"s5_p1", "s5_p2",
552+
"s6_p1", "s6_p2";
553+
#qcom,sensors = <6>;
554+
interrupts = <GIC_SPI 184 IRQ_TYPE_LEVEL_HIGH>;
555+
interrupt-names = "uplow";
556+
#thermal-sensor-cells = <1>;
557+
};
558+
531559
restart@fc4ab000 {
532560
compatible = "qcom,pshold";
533561
reg = <0xfc4ab000 0x4>;
@@ -538,6 +566,91 @@
538566
reg = <0xfc4bc000 0x1000>;
539567
#address-cells = <1>;
540568
#size-cells = <1>;
569+
570+
tsens_base1: base1@1c1 {
571+
reg = <0x1c1 0x2>;
572+
bits = <5 8>;
573+
};
574+
575+
tsens_s0_p1: s0-p1@1c2 {
576+
reg = <0x1c2 0x2>;
577+
bits = <5 6>;
578+
};
579+
580+
tsens_s1_p1: s1-p1@1c4 {
581+
reg = <0x1c4 0x1>;
582+
bits = <0 6>;
583+
};
584+
585+
tsens_s2_p1: s2-p1@1c4 {
586+
reg = <0x1c4 0x2>;
587+
bits = <6 6>;
588+
};
589+
590+
tsens_s3_p1: s3-p1@1c5 {
591+
reg = <0x1c5 0x2>;
592+
bits = <4 6>;
593+
};
594+
595+
tsens_s4_p1: s4-p1@1c6 {
596+
reg = <0x1c6 0x1>;
597+
bits = <2 6>;
598+
};
599+
600+
tsens_s5_p1: s5-p1@1c7 {
601+
reg = <0x1c7 0x1>;
602+
bits = <0 6>;
603+
};
604+
605+
tsens_s6_p1: s6-p1@1ca {
606+
reg = <0x1ca 0x2>;
607+
bits = <4 6>;
608+
};
609+
610+
tsens_base2: base2@1cc {
611+
reg = <0x1cc 0x1>;
612+
bits = <0 8>;
613+
};
614+
615+
tsens_s0_p2: s0-p2@1cd {
616+
reg = <0x1cd 0x1>;
617+
bits = <0 6>;
618+
};
619+
620+
tsens_s1_p2: s1-p2@1cd {
621+
reg = <0x1cd 0x2>;
622+
bits = <6 6>;
623+
};
624+
625+
tsens_s2_p2: s2-p2@1ce {
626+
reg = <0x1ce 0x2>;
627+
bits = <4 6>;
628+
};
629+
630+
tsens_s3_p2: s3-p2@1cf {
631+
reg = <0x1cf 0x1>;
632+
bits = <2 6>;
633+
};
634+
635+
tsens_s4_p2: s4-p2@446 {
636+
reg = <0x446 0x2>;
637+
bits = <4 6>;
638+
};
639+
640+
tsens_s5_p2: s5-p2@447 {
641+
reg = <0x447 0x1>;
642+
bits = <2 6>;
643+
};
644+
645+
tsens_s6_p2: s6-p2@44e {
646+
reg = <0x44e 0x1>;
647+
bits = <1 6>;
648+
};
649+
650+
tsens_mode: mode@44f {
651+
reg = <0x44f 0x1>;
652+
bits = <5 3>;
653+
};
541654
};
542655

543656
spmi_bus: spmi@fc4cf000 {

0 commit comments

Comments
 (0)