Files
android_kernel_samsung_sm87…/qcom/pm8550.dtsi
Manaf Meethalavalappu Pallikunhi 79a44b80b6 ARM: dts: qcom: update thermal zone shutdown trip type for sun
Use "hot" trip type for thermal zone software shutdown trip
for all thermal zones. It just notifies userspace thermal
manager which in turn triggers a graceful shutdown.

Change-Id: Icf7aa1f1da57a22b96ede18fcee75ebebb92830b
Signed-off-by: Manaf Meethalavalappu Pallikunhi <quic_manafm@quicinc.com>
2024-03-25 23:48:04 +05:30

260 lines
5.7 KiB
Plaintext

// SPDX-License-Identifier: BSD-3-Clause
/*
* Copyright (c) 2022-2024 Qualcomm Innovation Center, Inc. All rights reserved.
*/
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/leds/common.h>
#include <dt-bindings/spmi/spmi.h>
&spmi_bus {
#address-cells = <2>;
#size-cells = <0>;
interrupt-controller;
#interrupt-cells = <4>;
qcom,pm8550@1 {
compatible = "qcom,spmi-pmic";
reg = <0x1 SPMI_USID>;
#address-cells = <1>;
#size-cells = <0>;
pm8550_tz: pm8550-temp-alarm@a00 {
compatible = "qcom,spmi-temp-alarm";
reg = <0xa00>;
interrupts = <0x1 0xa 0x0 IRQ_TYPE_EDGE_BOTH>;
#thermal-sensor-cells = <0>;
};
pm8550_gpios: pinctrl@8800 {
compatible = "qcom,pm8550-gpio";
reg = <0x8800>;
gpio-controller;
#gpio-cells = <2>;
interrupt-controller;
#interrupt-cells = <2>;
};
led-controller {
compatible = "qcom,pm8350c-pwm";
#address-cells = <1>;
#size-cells = <0>;
#pwm-cells = <2>;
nvmem = <&pmk8550_sdam_21>,< &pmk8550_sdam_22>;
nvmem-names = "lpg_chan_sdam", "lut_sdam";
led@1 {
reg = <1>;
color = <LED_COLOR_ID_RED>;
label = "red";
};
led@2 {
reg = <2>;
color = <LED_COLOR_ID_GREEN>;
label = "green";
};
led@3 {
reg = <3>;
color = <LED_COLOR_ID_BLUE>;
label = "blue";
};
};
pm8550_bcl: bcl@4700 {
compatible = "qcom,bcl-v5";
reg = <0x4700 0x100>;
interrupts = <0x1 0x47 0x0 IRQ_TYPE_NONE>,
<0x1 0x47 0x1 IRQ_TYPE_NONE>,
<0x1 0x47 0x2 IRQ_TYPE_NONE>;
interrupt-names = "bcl-lvl0",
"bcl-lvl1",
"bcl-lvl2";
qcom,pmic7-threshold;
#thermal-sensor-cells = <1>;
};
pm8550_flash: qcom,flash_led@ee00 {
compatible = "qcom,qti-pm8350c-flash-led";
reg = <0xee00>;
interrupts = <0x1 0xee 0x0 IRQ_TYPE_EDGE_RISING>,
<0x1 0xee 0x3 IRQ_TYPE_EDGE_RISING>,
<0x1 0xee 0x4 IRQ_TYPE_EDGE_RISING>;
interrupt-names = "led-fault-irq",
"all-ramp-down-done-irq",
"all-ramp-up-done-irq";
qcom,thermal-derate-current = <200 500>;
status = "disabled";
pm8550_flash0: qcom,flash_0 {
label = "flash";
qcom,led-name = "led:flash_0";
qcom,max-current-ma = <1500>;
qcom,default-led-trigger = "flash0_trigger";
qcom,id = <0>;
qcom,duration-ms = <1280>;
qcom,ires-ua = <12500>;
};
pm8550_flash1: qcom,flash_1 {
label = "flash";
qcom,led-name = "led:flash_1";
qcom,max-current-ma = <1500>;
qcom,default-led-trigger = "flash1_trigger";
qcom,id = <1>;
qcom,duration-ms = <1280>;
qcom,ires-ua = <12500>;
};
pm8550_flash2: qcom,flash_2 {
label = "flash";
qcom,led-name = "led:flash_2";
qcom,max-current-ma = <1500>;
qcom,default-led-trigger = "flash2_trigger";
qcom,id = <2>;
qcom,duration-ms = <1280>;
qcom,ires-ua = <12500>;
};
pm8550_flash3: qcom,flash_3 {
label = "flash";
qcom,led-name = "led:flash_3";
qcom,max-current-ma = <1500>;
qcom,default-led-trigger = "flash3_trigger";
qcom,id = <3>;
qcom,duration-ms = <1280>;
qcom,ires-ua = <12500>;
};
pm8550_torch0: qcom,torch_0 {
label = "torch";
qcom,led-name = "led:torch_0";
qcom,max-current-ma = <500>;
qcom,default-led-trigger = "torch0_trigger";
qcom,id = <0>;
qcom,ires-ua = <12500>;
};
pm8550_torch1: qcom,torch_1 {
label = "torch";
qcom,led-name = "led:torch_1";
qcom,max-current-ma = <500>;
qcom,default-led-trigger = "torch1_trigger";
qcom,id = <1>;
qcom,ires-ua = <12500>;
};
pm8550_torch2: qcom,torch_2 {
label = "torch";
qcom,led-name = "led:torch_2";
qcom,max-current-ma = <500>;
qcom,default-led-trigger = "torch2_trigger";
qcom,id = <2>;
qcom,ires-ua = <12500>;
};
pm8550_torch3: qcom,torch_3 {
label = "torch";
qcom,led-name = "led:torch_3";
qcom,max-current-ma = <500>;
qcom,default-led-trigger = "torch3_trigger";
qcom,id = <3>;
qcom,ires-ua = <12500>;
};
pm8550_switch0: qcom,led_switch_0 {
label = "switch";
qcom,led-name = "led:switch_0";
qcom,default-led-trigger = "switch0_trigger";
};
pm8550_switch1: qcom,led_switch_1 {
label = "switch";
qcom,led-name = "led:switch_1";
qcom,default-led-trigger = "switch1_trigger";
};
pm8550_switch2: qcom,led_switch_2 {
label = "switch";
qcom,led-name = "led:switch_2";
qcom,default-led-trigger = "switch2_trigger";
};
};
};
};
&thermal_zones {
pm8550_temp_alarm: pm8550_tz {
polling-delay-passive = <100>;
polling-delay = <0>;
thermal-governor = "step_wise";
thermal-sensors = <&pm8550_tz>;
trips {
pm8550_trip0: trip0 {
temperature = <95000>;
hysteresis = <0>;
type = "passive";
};
pm8550_trip1: trip1 {
temperature = <115000>;
hysteresis = <0>;
type = "hot";
};
pm8550_trip2: trip2 {
temperature = <145000>;
hysteresis = <0>;
type = "critical";
};
};
};
pm8550-bcl-lvl0 {
polling-delay-passive = <100>;
polling-delay = <0>;
thermal-governor = "step_wise";
thermal-sensors = <&pm8550_bcl 5>;
trips {
bcl_lvl0: bcl-lvl0 {
temperature = <1>;
hysteresis = <1>;
type = "passive";
};
};
};
pm8550-bcl-lvl1 {
polling-delay-passive = <100>;
polling-delay = <0>;
thermal-governor = "step_wise";
thermal-sensors = <&pm8550_bcl 6>;
trips {
bcl_lvl1: bcl-lvl1 {
temperature = <1>;
hysteresis = <1>;
type = "passive";
};
};
};
pm8550-bcl-lvl2 {
polling-delay-passive = <100>;
polling-delay = <0>;
thermal-governor = "step_wise";
thermal-sensors = <&pm8550_bcl 7>;
trips {
bcl_lvl2: bcl-lvl2 {
temperature = <1>;
hysteresis = <1>;
type = "passive";
};
};
};
};