xref: /freebsd-src/sys/contrib/device-tree/src/arm64/qcom/pmk8550.dtsi (revision f126890ac5386406dadf7c4cfa9566cbb56537c5)
1cb7aa33aSEmmanuel Vadot// SPDX-License-Identifier: BSD-3-Clause
2cb7aa33aSEmmanuel Vadot/*
3cb7aa33aSEmmanuel Vadot * Copyright (c) 2022, Linaro Limited
4cb7aa33aSEmmanuel Vadot */
5cb7aa33aSEmmanuel Vadot
6cb7aa33aSEmmanuel Vadot#include <dt-bindings/input/input.h>
7cb7aa33aSEmmanuel Vadot#include <dt-bindings/input/linux-event-codes.h>
8cb7aa33aSEmmanuel Vadot#include <dt-bindings/interrupt-controller/irq.h>
9cb7aa33aSEmmanuel Vadot#include <dt-bindings/spmi/spmi.h>
10cb7aa33aSEmmanuel Vadot
11*f126890aSEmmanuel Vadot/ {
12*f126890aSEmmanuel Vadot	reboot-mode {
13*f126890aSEmmanuel Vadot		compatible = "nvmem-reboot-mode";
14*f126890aSEmmanuel Vadot		nvmem-cells = <&reboot_reason>;
15*f126890aSEmmanuel Vadot		nvmem-cell-names = "reboot-mode";
16*f126890aSEmmanuel Vadot		mode-recovery = <0x01>;
17*f126890aSEmmanuel Vadot		mode-bootloader = <0x02>;
18*f126890aSEmmanuel Vadot	};
19*f126890aSEmmanuel Vadot};
20*f126890aSEmmanuel Vadot
21cb7aa33aSEmmanuel Vadot&spmi_bus {
22cb7aa33aSEmmanuel Vadot	pmk8550: pmic@0 {
23cb7aa33aSEmmanuel Vadot		compatible = "qcom,pm8550", "qcom,spmi-pmic";
24cb7aa33aSEmmanuel Vadot		reg = <0x0 SPMI_USID>;
25cb7aa33aSEmmanuel Vadot		#address-cells = <1>;
26cb7aa33aSEmmanuel Vadot		#size-cells = <0>;
27cb7aa33aSEmmanuel Vadot
28cb7aa33aSEmmanuel Vadot		pmk8550_pon: pon@1300 {
29cb7aa33aSEmmanuel Vadot			compatible = "qcom,pmk8350-pon";
30cb7aa33aSEmmanuel Vadot			reg = <0x1300>, <0x800>;
31cb7aa33aSEmmanuel Vadot			reg-names = "hlos", "pbs";
32cb7aa33aSEmmanuel Vadot
33cb7aa33aSEmmanuel Vadot			pon_pwrkey: pwrkey {
34cb7aa33aSEmmanuel Vadot				compatible = "qcom,pmk8350-pwrkey";
35cb7aa33aSEmmanuel Vadot				interrupts = <0x0 0x13 0x7 IRQ_TYPE_EDGE_BOTH>;
36cb7aa33aSEmmanuel Vadot				linux,code = <KEY_POWER>;
37cb7aa33aSEmmanuel Vadot				status = "disabled";
38cb7aa33aSEmmanuel Vadot			};
39cb7aa33aSEmmanuel Vadot
40cb7aa33aSEmmanuel Vadot			pon_resin: resin {
41cb7aa33aSEmmanuel Vadot				compatible = "qcom,pmk8350-resin";
42cb7aa33aSEmmanuel Vadot				interrupts = <0x0 0x13 0x6 IRQ_TYPE_EDGE_BOTH>;
43cb7aa33aSEmmanuel Vadot				status = "disabled";
44cb7aa33aSEmmanuel Vadot			};
45cb7aa33aSEmmanuel Vadot		};
46cb7aa33aSEmmanuel Vadot
47cb7aa33aSEmmanuel Vadot		pmk8550_rtc: rtc@6100 {
48cb7aa33aSEmmanuel Vadot			compatible = "qcom,pmk8350-rtc";
49cb7aa33aSEmmanuel Vadot			reg = <0x6100>, <0x6200>;
50cb7aa33aSEmmanuel Vadot			reg-names = "rtc", "alarm";
51cb7aa33aSEmmanuel Vadot			interrupts = <0x0 0x62 0x1 IRQ_TYPE_EDGE_RISING>;
52*f126890aSEmmanuel Vadot		};
53*f126890aSEmmanuel Vadot
54*f126890aSEmmanuel Vadot		pmk8550_sdam_2: nvram@7100 {
55*f126890aSEmmanuel Vadot			compatible = "qcom,spmi-sdam";
56*f126890aSEmmanuel Vadot			reg = <0x7100>;
57*f126890aSEmmanuel Vadot			#address-cells = <1>;
58*f126890aSEmmanuel Vadot			#size-cells = <1>;
59*f126890aSEmmanuel Vadot			ranges = <0 0x7100 0x100>;
60*f126890aSEmmanuel Vadot
61*f126890aSEmmanuel Vadot			reboot_reason: reboot-reason@48 {
62*f126890aSEmmanuel Vadot				reg = <0x48 0x1>;
63*f126890aSEmmanuel Vadot				bits = <1 7>;
64*f126890aSEmmanuel Vadot			};
65cb7aa33aSEmmanuel Vadot		};
66cb7aa33aSEmmanuel Vadot
67cb7aa33aSEmmanuel Vadot		pmk8550_gpios: gpio@8800 {
68cb7aa33aSEmmanuel Vadot			compatible = "qcom,pmk8550-gpio", "qcom,spmi-gpio";
69cb7aa33aSEmmanuel Vadot			reg = <0xb800>;
70cb7aa33aSEmmanuel Vadot			gpio-controller;
71cb7aa33aSEmmanuel Vadot			gpio-ranges = <&pmk8550_gpios 0 0 6>;
72cb7aa33aSEmmanuel Vadot			#gpio-cells = <2>;
73cb7aa33aSEmmanuel Vadot			interrupt-controller;
74cb7aa33aSEmmanuel Vadot			#interrupt-cells = <2>;
75cb7aa33aSEmmanuel Vadot		};
76cb7aa33aSEmmanuel Vadot	};
77cb7aa33aSEmmanuel Vadot};
78