From patchwork Mon Jan 18 14:52:00 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 365550 Delivered-To: patch@linaro.org Received: by 2002:a02:ccad:0:0:0:0:0 with SMTP id t13csp30671jap; Mon, 18 Jan 2021 06:54:59 -0800 (PST) X-Google-Smtp-Source: ABdhPJwDFqeJUvfuSDT3ZoH8ZuwUyFsIBFndzf2HMttM/qNKEh5aaZiUyp68SbxOjNffnod1Zkk+ X-Received: by 2002:a17:906:2414:: with SMTP id z20mr65272eja.364.1610981699447; Mon, 18 Jan 2021 06:54:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610981699; cv=none; d=google.com; s=arc-20160816; b=QczdJtdWQ3uVfFILkbNskdXadinS5voEzKEWzPVCO2uiu8UpphU2Q7nW5LeMXVopTY hjzuWiJHnPavvhLaRDqUzHnGjOBug/8XRG3WjCcwC+tVzJVI2pS5ffe2rqhdfjvgWFzB w1UURv+2NUYQ/eOsgZk45CfXIBuivK4oma3Qknj9FGsIWdeumH7sPjL5PxZb8xdA2sMW POsbuIvhYkeEOsDjmi0ab7MasG+VoZj6u+EnlTi7t7ZmPtYzRXJWgUopA/s5Ds66mb/8 c1FCnU+/wFIEXm4GOWXDIN3MeTMcH7rcOHib40ZZkGZyaVMkFjGR6bWaTjVwJUnFxr+Y jJjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=xYwmrtz/QU6RpO5QbrehkEFuAsa7SlsbStjo8EQedtw=; b=cMc9JpOoHyM8A8sBl3B7wZePL1MSXaRPUATCfB0nax1xNJx0xUrt3kIg67ruZ33MV+ REVS1SRp3t8Xuc0MWAvaEo6GK0zjSf9eQee3pBeAE4tlM0CI/8uMA8tWiWXIdwfylEnM nK1v0vgp7XIDpnzCHqIFGg7uVkmfsfAaOAc3bI4J7dmRmayA91uGrPA9kQ+am9/dHMg1 LqJYcdr+tXnXDpviLsiqbzh0tESKyhMro1QdhZExCM0gIxfhyk3z2vCtVHVE/m5EREgy 4e/GCZLYNwoNnF/pE1QN1Wx+Bqpy95AK8ekzwXXfoUs1r+62nRCC/SvHZri3J/QJ0k8O d6eg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ujDw7ido; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f12si7754199ejl.311.2021.01.18.06.54.57; Mon, 18 Jan 2021 06:54:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ujDw7ido; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405311AbhAROyf (ORCPT + 15 others); Mon, 18 Jan 2021 09:54:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59246 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405333AbhAROya (ORCPT ); Mon, 18 Jan 2021 09:54:30 -0500 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 26C78C0617A1 for ; Mon, 18 Jan 2021 06:52:14 -0800 (PST) Received: by mail-lf1-x12f.google.com with SMTP id m25so24415400lfc.11 for ; Mon, 18 Jan 2021 06:52:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=xYwmrtz/QU6RpO5QbrehkEFuAsa7SlsbStjo8EQedtw=; b=ujDw7idogA7ubtCSw3Pua5Bqbvx9JmkO80LBhL8vrBdDBdrx2urUN92KMUlBkqNsFo JuCu6wGdT+6ULvsB1a/3HtgMykEatbSXqLmMNYOXJ5miRdG7Vr/Hi2yJYw600WxkoxWo c9Q9fy/GXO96GDapcaioKyZZNLtzgGYy7zVubgy5gobhXh1R9B9mhUcLYJW8y5pYajJH hSaFH5fkPeJ3w0+LHmM7vI9U28GbwiZJ6Gge57oqS1fsX5HwsRgP856wjf1LcG4eALVs 2lR3SvP7jzbm1py4EyPrn8C12I80tr9ps+nZ71mo5/vJUHCP1BxHYZTe1bQlHK6EP07K kixg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=xYwmrtz/QU6RpO5QbrehkEFuAsa7SlsbStjo8EQedtw=; b=nMhlAoPQHVhLWTPE0OT4bKa5tVFFwJ6CzlVJqOvrX2j3kHTDaInKQZvpkLg+QSCe+/ i+Cu/xh8vjvxEjEWepOWPASGJITEXCH6sk7ykdaHRXZsMAzvYm1HGRSbdFGPUW6dKsTh JUvoFflkDmM/kgQb80ZjPjGt3vahK8qzPl75bGWf12MVQKGHZGNgIykgutOh1k7pt35D dqbRBNVfBT2xOywOeGlx1Db2mpD5jKxyPqaSHM8BVUwJKjhJtko2yyQuxzDxRHKD2J1A 3HC4Fijx/wcGbLeeKaXG/SEbm+1FrDsoixO3Owmb0r9ZFIdvx70+YyfzB+va4znpg+/u xlTA== X-Gm-Message-State: AOAM5318UvYYeeYjWdgOE1uBIS4CtMzWgJsACl86LOpt8/FTMuQqtH8N AYLEYi/BojRHCJURBtO/KjUKig== X-Received: by 2002:ac2:43a4:: with SMTP id t4mr11750936lfl.197.1610981532713; Mon, 18 Jan 2021 06:52:12 -0800 (PST) Received: from eriador.lumag.spb.ru ([188.162.64.4]) by smtp.gmail.com with ESMTPSA id h13sm1969697lfj.110.2021.01.18.06.52.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Jan 2021 06:52:12 -0800 (PST) From: Dmitry Baryshkov To: Andy Gross , Bjorn Andersson , Rob Herring , Zhang Rui , Daniel Lezcano , Amit Kucheria , Jonathan Cameron , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald-Stadler Cc: linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-iio@vger.kernel.org, Manivannan Sadhasivam , Jishnu Prakash Subject: [PATCH v11 5/5] arm64: dts: qrb5165-rb5: port thermal zone definitions Date: Mon, 18 Jan 2021 17:52:00 +0300 Message-Id: <20210118145200.504951-6-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210118145200.504951-1-dmitry.baryshkov@linaro.org> References: <20210118145200.504951-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add thermal zones definitions basing on the downstream kernel. Signed-off-by: Dmitry Baryshkov --- arch/arm64/boot/dts/qcom/qrb5165-rb5.dts | 155 +++++++++++++++++++++++ 1 file changed, 155 insertions(+) -- 2.29.2 diff --git a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts index ce22d4fa383e..ef9452f0c6b2 100644 --- a/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts +++ b/arch/arm64/boot/dts/qcom/qrb5165-rb5.dts @@ -66,6 +66,78 @@ bt { }; + thermal-zones { + conn-thermal { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm8150b_adc_tm 0>; + + trips { + active-config0 { + temperature = <125000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + }; + + pm8150l-thermal { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm8150l_adc_tm 1>; + + trips { + active-config0 { + temperature = <50000>; + hysteresis = <4000>; + type = "passive"; + }; + }; + }; + + skin-msm-thermal { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm8150l_adc_tm 0>; + + trips { + active-config0 { + temperature = <50000>; + hysteresis = <4000>; + type = "passive"; + }; + }; + }; + + wifi-thermal { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm8150_adc_tm 1>; + + trips { + active-config0 { + temperature = <52000>; + hysteresis = <4000>; + type = "passive"; + }; + }; + }; + + xo-thermal { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&pm8150_adc_tm 0>; + + trips { + active-config0 { + temperature = <50000>; + hysteresis = <4000>; + type = "passive"; + }; + }; + }; + }; + vbat: vbat-regulator { compatible = "regulator-fixed"; regulator-name = "VBAT"; @@ -420,6 +492,38 @@ &i2c15 { status = "okay"; }; +&pm8150_adc { + xo-therm@4c { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; + + wifi-therm@4e { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; +}; + +&pm8150_adc_tm { + status = "okay"; + + xo-therm@0 { + reg = <0>; + io-channels = <&pm8150_adc ADC5_XO_THERM_100K_PU>; + qcom,ratiometric; + qcom,hw-settle-time-us = <200>; + }; + + wifi-therm@1 { + reg = <1>; + io-channels = <&pm8150_adc ADC5_AMUX_THM2_100K_PU>; + qcom,ratiometric; + qcom,hw-settle-time-us = <200>; + }; +}; + &pm8150_gpios { gpio-reserved-ranges = <1 1>, <3 2>, <7 1>; gpio-line-names = @@ -435,6 +539,25 @@ &pm8150_gpios { "GPIO_10_P"; /* Green LED */ }; +&pm8150b_adc { + conn-therm@4f { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; +}; + +&pm8150b_adc_tm { + status = "okay"; + + conn-therm@0 { + reg = <0>; + io-channels = <&pm8150b_adc ADC5_AMUX_THM3_100K_PU>; + qcom,ratiometric; + qcom,hw-settle-time-us = <200>; + }; +}; + &pm8150b_gpios { gpio-line-names = "NC", @@ -451,6 +574,38 @@ &pm8150b_gpios { "NC"; }; +&pm8150l_adc { + skin-msm-therm@4e { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; + + pm8150l-therm@4f { + reg = ; + qcom,ratiometric; + qcom,hw-settle-time = <200>; + }; +}; + +&pm8150l_adc_tm { + status = "okay"; + + skin-msm-therm@0 { + reg = <0>; + io-channels = <&pm8150l_adc ADC5_AMUX_THM2_100K_PU>; + qcom,ratiometric; + qcom,hw-settle-time-us = <200>; + }; + + pm8150l-therm@1 { + reg = <1>; + io-channels = <&pm8150l_adc ADC5_AMUX_THM3_100K_PU>; + qcom,ratiometric; + qcom,hw-settle-time-us = <200>; + }; +}; + &pm8150l_gpios { gpio-line-names = "NC",