0001 // SPDX-License-Identifier: BSD-3-Clause
0002 /*
0003 * Copyright (c) 2021, Linaro Limited
0004 */
0005
0006 #include <dt-bindings/input/input.h>
0007 #include <dt-bindings/interrupt-controller/irq.h>
0008 #include <dt-bindings/spmi/spmi.h>
0009 #include <dt-bindings/iio/qcom,spmi-vadc.h>
0010
0011 / {
0012 thermal-zones {
0013 pmm8155au-1-thermal {
0014 polling-delay-passive = <100>;
0015 polling-delay = <0>;
0016
0017 thermal-sensors = <&pmm8155au_1_temp>;
0018
0019 trips {
0020 trip0 {
0021 temperature = <95000>;
0022 hysteresis = <0>;
0023 type = "passive";
0024 };
0025
0026 trip1 {
0027 temperature = <115000>;
0028 hysteresis = <0>;
0029 type = "hot";
0030 };
0031
0032 trip2 {
0033 temperature = <145000>;
0034 hysteresis = <0>;
0035 type = "critical";
0036 };
0037 };
0038 };
0039 };
0040 };
0041
0042 &spmi_bus {
0043 pmic@0 {
0044 compatible = "qcom,pmm8155au", "qcom,spmi-pmic";
0045 reg = <0x0 SPMI_USID>;
0046 #address-cells = <1>;
0047 #size-cells = <0>;
0048
0049 pon: power-on@800 {
0050 compatible = "qcom,pm8916-pon";
0051 reg = <0x0800>;
0052 pwrkey {
0053 compatible = "qcom,pm8941-pwrkey";
0054 interrupts = <0x0 0x8 0x0 IRQ_TYPE_EDGE_BOTH>;
0055 debounce = <15625>;
0056 bias-pull-up;
0057 linux,code = <KEY_POWER>;
0058
0059 status = "disabled";
0060 };
0061 };
0062
0063 pmm8155au_1_temp: temp-alarm@2400 {
0064 compatible = "qcom,spmi-temp-alarm";
0065 reg = <0x2400>;
0066 interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_BOTH>;
0067 io-channels = <&pmm8155au_1_adc ADC5_DIE_TEMP>;
0068 io-channel-names = "thermal";
0069 #thermal-sensor-cells = <0>;
0070 };
0071
0072 pmm8155au_1_adc: adc@3100 {
0073 compatible = "qcom,spmi-adc5";
0074 reg = <0x3100>;
0075 #address-cells = <1>;
0076 #size-cells = <0>;
0077 #io-channel-cells = <1>;
0078 interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>;
0079
0080 ref-gnd@0 {
0081 reg = <ADC5_REF_GND>;
0082 qcom,pre-scaling = <1 1>;
0083 label = "ref_gnd";
0084 };
0085
0086 vref-1p25@1 {
0087 reg = <ADC5_1P25VREF>;
0088 qcom,pre-scaling = <1 1>;
0089 label = "vref_1p25";
0090 };
0091
0092 die-temp@6 {
0093 reg = <ADC5_DIE_TEMP>;
0094 qcom,pre-scaling = <1 1>;
0095 label = "die_temp";
0096 };
0097 };
0098
0099 pmm8155au_1_adc_tm: adc-tm@3500 {
0100 compatible = "qcom,spmi-adc-tm5";
0101 reg = <0x3500>;
0102 interrupts = <0x0 0x35 0x0 IRQ_TYPE_EDGE_RISING>;
0103 #thermal-sensor-cells = <1>;
0104 #address-cells = <1>;
0105 #size-cells = <0>;
0106 status = "disabled";
0107 };
0108
0109 pmm8155au_1_rtc: rtc@6000 {
0110 compatible = "qcom,pm8941-rtc";
0111 reg = <0x6000>;
0112 reg-names = "rtc", "alarm";
0113 interrupts = <0x0 0x61 0x1 IRQ_TYPE_NONE>;
0114
0115 status = "disabled";
0116 };
0117
0118 pmm8155au_1_gpios: gpio@c000 {
0119 compatible = "qcom,pmm8155au-gpio", "qcom,spmi-gpio";
0120 reg = <0xc000>;
0121 gpio-controller;
0122 #gpio-cells = <2>;
0123 gpio-ranges = <&pmm8155au_1_gpios 0 0 10>;
0124 interrupt-controller;
0125 #interrupt-cells = <2>;
0126 };
0127 };
0128
0129 pmic@1 {
0130 compatible = "qcom,pmm8155au", "qcom,spmi-pmic";
0131 reg = <0x1 SPMI_USID>;
0132 #address-cells = <1>;
0133 #size-cells = <0>;
0134 };
0135 };