xref: /freebsd/sys/contrib/device-tree/src/arm64/qcom/pm2250.dtsi (revision fac71e4e09885bb2afa3d984a0c239a52e1a7418)
1*fac71e4eSEmmanuel Vadot// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
2*fac71e4eSEmmanuel Vadot/*
3*fac71e4eSEmmanuel Vadot * Copyright (c) 2023, Linaro Ltd
4*fac71e4eSEmmanuel Vadot */
5*fac71e4eSEmmanuel Vadot
6*fac71e4eSEmmanuel Vadot#include <dt-bindings/iio/qcom,spmi-vadc.h>
7*fac71e4eSEmmanuel Vadot#include <dt-bindings/input/input.h>
8*fac71e4eSEmmanuel Vadot#include <dt-bindings/interrupt-controller/irq.h>
9*fac71e4eSEmmanuel Vadot#include <dt-bindings/spmi/spmi.h>
10*fac71e4eSEmmanuel Vadot
11*fac71e4eSEmmanuel Vadot&spmi_bus {
12*fac71e4eSEmmanuel Vadot	pmic@0 {
13*fac71e4eSEmmanuel Vadot		compatible = "qcom,pm2250", "qcom,spmi-pmic";
14*fac71e4eSEmmanuel Vadot		reg = <0x0 SPMI_USID>;
15*fac71e4eSEmmanuel Vadot		#address-cells = <1>;
16*fac71e4eSEmmanuel Vadot		#size-cells = <0>;
17*fac71e4eSEmmanuel Vadot
18*fac71e4eSEmmanuel Vadot		pon@800 {
19*fac71e4eSEmmanuel Vadot			compatible = "qcom,pm8916-pon";
20*fac71e4eSEmmanuel Vadot			reg = <0x800>;
21*fac71e4eSEmmanuel Vadot
22*fac71e4eSEmmanuel Vadot			pm2250_pwrkey: pwrkey {
23*fac71e4eSEmmanuel Vadot				compatible = "qcom,pm8941-pwrkey";
24*fac71e4eSEmmanuel Vadot				interrupts-extended = <&spmi_bus 0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>;
25*fac71e4eSEmmanuel Vadot				linux,code = <KEY_POWER>;
26*fac71e4eSEmmanuel Vadot				debounce = <15625>;
27*fac71e4eSEmmanuel Vadot				bias-pull-up;
28*fac71e4eSEmmanuel Vadot			};
29*fac71e4eSEmmanuel Vadot
30*fac71e4eSEmmanuel Vadot			pm2250_resin: resin {
31*fac71e4eSEmmanuel Vadot				compatible = "qcom,pm8941-resin";
32*fac71e4eSEmmanuel Vadot				interrupts-extended = <&spmi_bus 0x0 0x8 1 IRQ_TYPE_EDGE_BOTH>;
33*fac71e4eSEmmanuel Vadot				debounce = <15625>;
34*fac71e4eSEmmanuel Vadot				bias-pull-up;
35*fac71e4eSEmmanuel Vadot				status = "disabled";
36*fac71e4eSEmmanuel Vadot			};
37*fac71e4eSEmmanuel Vadot		};
38*fac71e4eSEmmanuel Vadot
39*fac71e4eSEmmanuel Vadot		rtc@6000 {
40*fac71e4eSEmmanuel Vadot			compatible = "qcom,pm8941-rtc";
41*fac71e4eSEmmanuel Vadot			reg = <0x6000>, <0x6100>;
42*fac71e4eSEmmanuel Vadot			reg-names = "rtc", "alarm";
43*fac71e4eSEmmanuel Vadot			interrupts-extended = <&spmi_bus 0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>;
44*fac71e4eSEmmanuel Vadot		};
45*fac71e4eSEmmanuel Vadot
46*fac71e4eSEmmanuel Vadot		pm2250_gpios: gpio@c000 {
47*fac71e4eSEmmanuel Vadot			compatible = "qcom,pm2250-gpio", "qcom,spmi-gpio";
48*fac71e4eSEmmanuel Vadot			reg = <0xc000>;
49*fac71e4eSEmmanuel Vadot			gpio-controller;
50*fac71e4eSEmmanuel Vadot			gpio-ranges = <&pm2250_gpios 0 0 10>;
51*fac71e4eSEmmanuel Vadot			#gpio-cells = <2>;
52*fac71e4eSEmmanuel Vadot			interrupt-controller;
53*fac71e4eSEmmanuel Vadot			#interrupt-cells = <2>;
54*fac71e4eSEmmanuel Vadot		};
55*fac71e4eSEmmanuel Vadot	};
56*fac71e4eSEmmanuel Vadot
57*fac71e4eSEmmanuel Vadot	pmic@1 {
58*fac71e4eSEmmanuel Vadot		compatible = "qcom,pm2250", "qcom,spmi-pmic";
59*fac71e4eSEmmanuel Vadot		reg = <0x1 SPMI_USID>;
60*fac71e4eSEmmanuel Vadot		#address-cells = <1>;
61*fac71e4eSEmmanuel Vadot		#size-cells = <0>;
62*fac71e4eSEmmanuel Vadot	};
63*fac71e4eSEmmanuel Vadot};
64