Back to home page

OSCL-LXR

 
 

    


0001 // SPDX-License-Identifier: BSD-3-Clause
0002 /* Copyright (c) 2022, The Linux Foundation. All rights reserved. */
0003 
0004 #include <dt-bindings/iio/qcom,spmi-vadc.h>
0005 #include <dt-bindings/interrupt-controller/irq.h>
0006 #include <dt-bindings/input/linux-event-codes.h>
0007 #include <dt-bindings/spmi/spmi.h>
0008 
0009 &spmi_bus {
0010         pmic@0 {
0011                 compatible = "qcom,pm8953", "qcom,spmi-pmic";
0012                 reg = <0 SPMI_USID>;
0013                 #address-cells = <1>;
0014                 #size-cells = <0>;
0015 
0016                 pm8953_pon: pon@800 {
0017                         compatible = "qcom,pm8916-pon";
0018                         reg = <0x800>;
0019                         mode-bootloader = <0x2>;
0020                         mode-recovery = <0x1>;
0021 
0022                         pwrkey {
0023                                 compatible = "qcom,pm8941-pwrkey";
0024                                 interrupts = <0x00 0x08 0 IRQ_TYPE_EDGE_BOTH>;
0025                                 debounce = <15625>;
0026                                 bias-pull-up;
0027                                 linux,code = <KEY_POWER>;
0028                         };
0029 
0030                         pm8953_resin: resin {
0031                                 compatible = "qcom,pm8941-resin";
0032                                 interrupts = <0x00 0x08 1 IRQ_TYPE_EDGE_BOTH>;
0033                                 debounce = <15625>;
0034                                 bias-pull-up;
0035                                 status = "disabled";
0036                         };
0037                 };
0038 
0039                 temp-alarm@2400 {
0040                         compatible = "qcom,spmi-temp-alarm";
0041                         reg = <0x2400>;
0042                         interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_RISING>;
0043                         io-channels = <&pm8953_vadc VADC_DIE_TEMP>;
0044                         io-channel-names = "thermal";
0045                         #thermal-sensor-cells = <0>;
0046                 };
0047 
0048                 pm8953_vadc: vadc@3100 {
0049                         compatible = "qcom,spmi-vadc";
0050                         reg = <0x3100>;
0051                         interrupts = <0x00 0x31 0x00 0x01>;
0052                         #address-cells = <1>;
0053                         #size-cells = <0>;
0054                         #io-channel-cells = <1>;
0055 
0056                         adc-chan@8 {
0057                                 reg = <VADC_DIE_TEMP>;
0058                         };
0059                         adc-chan@9 {
0060                                 reg = <VADC_REF_625MV>;
0061                         };
0062                         adc-chan@a {
0063                                 reg = <VADC_REF_1250MV>;
0064                         };
0065                         adc-chan@c {
0066                                 reg = <VADC_SPARE1>;
0067                         };
0068                         adc-chan@e {
0069                                 reg = <VADC_GND_REF>;
0070                         };
0071                         adc-chan@f {
0072                                 reg = <VADC_VDD_VADC>;
0073                         };
0074                 };
0075 
0076                 rtc@6000 {
0077                         compatible = "qcom,pm8941-rtc";
0078                         reg = <0x6000>, <0x6100>;
0079                         reg-names = "rtc", "alarm";
0080                         interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>;
0081                 };
0082         };
0083 
0084         pmic@1 {
0085                 compatible = "qcom,pm8953", "qcom,spmi-pmic";
0086                 reg = <1 SPMI_USID>;
0087                 #address-cells = <1>;
0088                 #size-cells = <0>;
0089         };
0090 };