xref: /freebsd-src/sys/contrib/device-tree/src/arm/qcom/qcom-pma8084.dtsi (revision aa1a8ff2d6dbc51ef058f46f3db5a8bb77967145)
1f126890aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0
2f126890aSEmmanuel Vadot#include <dt-bindings/iio/qcom,spmi-vadc.h>
3f126890aSEmmanuel Vadot#include <dt-bindings/interrupt-controller/irq.h>
4f126890aSEmmanuel Vadot#include <dt-bindings/spmi/spmi.h>
5f126890aSEmmanuel Vadot
6f126890aSEmmanuel Vadot&spmi_bus {
7f126890aSEmmanuel Vadot
8f126890aSEmmanuel Vadot	pma8084_0: pma8084@0 {
9f126890aSEmmanuel Vadot		compatible = "qcom,pma8084", "qcom,spmi-pmic";
10f126890aSEmmanuel Vadot		reg = <0x0 SPMI_USID>;
11f126890aSEmmanuel Vadot		#address-cells = <1>;
12f126890aSEmmanuel Vadot		#size-cells = <0>;
13f126890aSEmmanuel Vadot
14f126890aSEmmanuel Vadot		rtc@6000 {
15f126890aSEmmanuel Vadot			compatible = "qcom,pm8941-rtc";
16f126890aSEmmanuel Vadot			reg = <0x6000>,
17f126890aSEmmanuel Vadot			      <0x6100>;
18f126890aSEmmanuel Vadot			reg-names = "rtc", "alarm";
19f126890aSEmmanuel Vadot			interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>;
20f126890aSEmmanuel Vadot		};
21f126890aSEmmanuel Vadot
22f126890aSEmmanuel Vadot		pwrkey@800 {
23f126890aSEmmanuel Vadot			compatible = "qcom,pm8941-pwrkey";
24f126890aSEmmanuel Vadot			reg = <0x800>;
25f126890aSEmmanuel Vadot			interrupts = <0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>;
26f126890aSEmmanuel Vadot			debounce = <15625>;
27f126890aSEmmanuel Vadot			bias-pull-up;
28f126890aSEmmanuel Vadot		};
29f126890aSEmmanuel Vadot
30f126890aSEmmanuel Vadot		pma8084_gpios: gpio@c000 {
31f126890aSEmmanuel Vadot			compatible = "qcom,pma8084-gpio", "qcom,spmi-gpio";
32f126890aSEmmanuel Vadot			reg = <0xc000>;
33f126890aSEmmanuel Vadot			gpio-controller;
34f126890aSEmmanuel Vadot			gpio-ranges = <&pma8084_gpios 0 0 22>;
35f126890aSEmmanuel Vadot			#gpio-cells = <2>;
36f126890aSEmmanuel Vadot			interrupt-controller;
37f126890aSEmmanuel Vadot			#interrupt-cells = <2>;
38f126890aSEmmanuel Vadot		};
39f126890aSEmmanuel Vadot
40f126890aSEmmanuel Vadot		pma8084_mpps: mpps@a000 {
41f126890aSEmmanuel Vadot			compatible = "qcom,pma8084-mpp", "qcom,spmi-mpp";
42f126890aSEmmanuel Vadot			reg = <0xa000>;
43f126890aSEmmanuel Vadot			gpio-controller;
44f126890aSEmmanuel Vadot			#gpio-cells = <2>;
45f126890aSEmmanuel Vadot			gpio-ranges = <&pma8084_mpps 0 0 8>;
46f126890aSEmmanuel Vadot			interrupt-controller;
47f126890aSEmmanuel Vadot			#interrupt-cells = <2>;
48f126890aSEmmanuel Vadot		};
49f126890aSEmmanuel Vadot
50f126890aSEmmanuel Vadot		pma8084_temp: temp-alarm@2400 {
51f126890aSEmmanuel Vadot			compatible = "qcom,spmi-temp-alarm";
52f126890aSEmmanuel Vadot			reg = <0x2400>;
53f126890aSEmmanuel Vadot			interrupts = <0 0x24 0 IRQ_TYPE_EDGE_RISING>;
54f126890aSEmmanuel Vadot			#thermal-sensor-cells = <0>;
55f126890aSEmmanuel Vadot			io-channels = <&pma8084_vadc VADC_DIE_TEMP>;
56f126890aSEmmanuel Vadot			io-channel-names = "thermal";
57f126890aSEmmanuel Vadot		};
58f126890aSEmmanuel Vadot
59f126890aSEmmanuel Vadot		pma8084_vadc: adc@3100 {
60f126890aSEmmanuel Vadot			compatible = "qcom,spmi-vadc";
61f126890aSEmmanuel Vadot			reg = <0x3100>;
62f126890aSEmmanuel Vadot			interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>;
63f126890aSEmmanuel Vadot			#address-cells = <1>;
64f126890aSEmmanuel Vadot			#size-cells = <0>;
65f126890aSEmmanuel Vadot			#io-channel-cells = <1>;
66f126890aSEmmanuel Vadot
67*aa1a8ff2SEmmanuel Vadot			channel@8 {
68f126890aSEmmanuel Vadot				reg = <VADC_DIE_TEMP>;
69f126890aSEmmanuel Vadot			};
70f126890aSEmmanuel Vadot
71*aa1a8ff2SEmmanuel Vadot			channel@9 {
72f126890aSEmmanuel Vadot				reg = <VADC_REF_625MV>;
73f126890aSEmmanuel Vadot			};
74f126890aSEmmanuel Vadot
75*aa1a8ff2SEmmanuel Vadot			channel@a {
76f126890aSEmmanuel Vadot				reg = <VADC_REF_1250MV>;
77f126890aSEmmanuel Vadot			};
78f126890aSEmmanuel Vadot
79*aa1a8ff2SEmmanuel Vadot			channel@c {
80f126890aSEmmanuel Vadot				reg = <VADC_SPARE1>;
81f126890aSEmmanuel Vadot			};
82f126890aSEmmanuel Vadot
83*aa1a8ff2SEmmanuel Vadot			channel@e {
84f126890aSEmmanuel Vadot				reg = <VADC_GND_REF>;
85f126890aSEmmanuel Vadot			};
86f126890aSEmmanuel Vadot
87*aa1a8ff2SEmmanuel Vadot			channel@f {
88f126890aSEmmanuel Vadot				reg = <VADC_VDD_VADC>;
89f126890aSEmmanuel Vadot			};
90f126890aSEmmanuel Vadot		};
91f126890aSEmmanuel Vadot	};
92f126890aSEmmanuel Vadot
93f126890aSEmmanuel Vadot	pma8084_1: pma8084@1 {
94f126890aSEmmanuel Vadot		compatible = "qcom,pma8084", "qcom,spmi-pmic";
95f126890aSEmmanuel Vadot		reg = <0x1 SPMI_USID>;
96f126890aSEmmanuel Vadot		#address-cells = <1>;
97f126890aSEmmanuel Vadot		#size-cells = <0>;
98f126890aSEmmanuel Vadot	};
99f126890aSEmmanuel Vadot};
100