xref: /openbmc/linux/arch/arm64/boot/dts/qcom/pm8953.dtsi (revision ca637c0e)
1// SPDX-License-Identifier: BSD-3-Clause
2/* Copyright (c) 2022, The Linux Foundation. All rights reserved. */
3
4#include <dt-bindings/iio/qcom,spmi-vadc.h>
5#include <dt-bindings/interrupt-controller/irq.h>
6#include <dt-bindings/input/linux-event-codes.h>
7#include <dt-bindings/spmi/spmi.h>
8
9&spmi_bus {
10	pmic@0 {
11		compatible = "qcom,pm8953", "qcom,spmi-pmic";
12		reg = <0 SPMI_USID>;
13		#address-cells = <1>;
14		#size-cells = <0>;
15
16		pm8953_pon: pon@800 {
17			compatible = "qcom,pm8916-pon";
18			reg = <0x800>;
19			mode-bootloader = <0x2>;
20			mode-recovery = <0x1>;
21
22			pwrkey {
23				compatible = "qcom,pm8941-pwrkey";
24				interrupts = <0x00 0x08 0 IRQ_TYPE_EDGE_BOTH>;
25				debounce = <15625>;
26				bias-pull-up;
27				linux,code = <KEY_POWER>;
28			};
29
30			pm8953_resin: resin {
31				compatible = "qcom,pm8941-resin";
32				interrupts = <0x00 0x08 1 IRQ_TYPE_EDGE_BOTH>;
33				debounce = <15625>;
34				bias-pull-up;
35				status = "disabled";
36			};
37		};
38
39		temp-alarm@2400 {
40			compatible = "qcom,spmi-temp-alarm";
41			reg = <0x2400>;
42			interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_RISING>;
43			io-channels = <&pm8953_vadc VADC_DIE_TEMP>;
44			io-channel-names = "thermal";
45			#thermal-sensor-cells = <0>;
46		};
47
48		pm8953_vadc: adc@3100 {
49			compatible = "qcom,spmi-vadc";
50			reg = <0x3100>;
51			interrupts = <0x00 0x31 0x00 0x01>;
52			#address-cells = <1>;
53			#size-cells = <0>;
54			#io-channel-cells = <1>;
55
56			adc-chan@8 {
57				reg = <VADC_DIE_TEMP>;
58			};
59			adc-chan@9 {
60				reg = <VADC_REF_625MV>;
61			};
62			adc-chan@a {
63				reg = <VADC_REF_1250MV>;
64			};
65			adc-chan@c {
66				reg = <VADC_SPARE1>;
67			};
68			adc-chan@e {
69				reg = <VADC_GND_REF>;
70			};
71			adc-chan@f {
72				reg = <VADC_VDD_VADC>;
73			};
74		};
75
76		rtc@6000 {
77			compatible = "qcom,pm8941-rtc";
78			reg = <0x6000>, <0x6100>;
79			reg-names = "rtc", "alarm";
80			interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>;
81		};
82	};
83
84	pmic@1 {
85		compatible = "qcom,pm8953", "qcom,spmi-pmic";
86		reg = <1 SPMI_USID>;
87		#address-cells = <1>;
88		#size-cells = <0>;
89	};
90};
91