From patchwork Wed Sep 11 07:16:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173590 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374131ilq; Wed, 11 Sep 2019 00:16:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqxSLjIETLC0UAMhdGU/iIBMqkovV52xG/JgcLYvVkF3exA4BGvGdXluXGc0/in+VX7JAvPs X-Received: by 2002:a17:906:3293:: with SMTP id 19mr28305203ejw.265.1568186210006; Wed, 11 Sep 2019 00:16:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186210; cv=none; d=google.com; s=arc-20160816; b=rTMhn+V9yZjW6M4YywwvGvsM2DteAPx8uo0+W8l+XmGf5hy4wdCxTygDZN8heaoiPL y1VcnPhxcsbwyOhuqGxaF9q71jsGjdhrJYm1yDxEBNFleaXcnCuV8KRnSr3m5o/aIeob +VEo8wWJXv0P+9RqnqAwkCWEiZolUTTFjrZhHcaqyvtN1EFXOKgjJTu5t3IlZ3oFPtqL ZR7kLpIiX4vvgwhJ/mUD43qLi2XH2lIt7SYgh5VSPg2pngQpFyW+/DsEIKjSglaODYAQ iS0q07QW53OnojVqpBR4P2PPdhvPxpVSjZlEvJdcaDx8aOw40kLpJfmxpMnoZuNmiQDS W82Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=BcKGfqptsJMIyqg8m+kdv7mwKKvvYfua8/fbCWYYrS8=; b=cocgesLcn0+MOi3wKIiGz/34F4wXpWpYWgLi9NV7N9Sw8ttwiqv0SVpe9Lq9rwLklC x2wp4etciDY14KAFEO/PfX0mrqx9oWKyRdGimvBlL/2nnQomN4I5juTzJUmdZYAcRFwV FQS+288JD5dUVbMd63RtMUJY4wPMIsE0A/Fxhu16rSXh3e/Io5KmWhmQxn1ZwG1QMO2c qAVKP7Kczbt2IT2favSSgj/gT+oiQa5C3E5F7KN1hxEu8LuEf8th2fcaBzothOll4odY bcmthSgIvEhnyvyvuHf73aQ5ONa7Q4q8Kb9nU8n6ONQYFw7AthqyNu+cdcl0BgtEJ9Hs i9yw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="o7pSB/lB"; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id u2si2623689edp.191.2019.09.11.00.16.49; Wed, 11 Sep 2019 00:16:49 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="o7pSB/lB"; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1726988AbfIKHQt (ORCPT + 15 others); Wed, 11 Sep 2019 03:16:49 -0400 Received: from mail-pg1-f195.google.com ([209.85.215.195]:44826 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726838AbfIKHQs (ORCPT ); Wed, 11 Sep 2019 03:16:48 -0400 Received: by mail-pg1-f195.google.com with SMTP id i18so11038989pgl.11 for ; Wed, 11 Sep 2019 00:16:48 -0700 (PDT) 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 :in-reply-to:references; bh=BcKGfqptsJMIyqg8m+kdv7mwKKvvYfua8/fbCWYYrS8=; b=o7pSB/lBJepCsIAK9wwEl+41gBqxhzj1JE5Xk93Xw+PiLLGCJiaRXIgX89oRURyZnw l3RtJSgM55DVzGJjWn4+MDNVoP63T55tIwc6Q5UURuq4/Y3FFS5V23mHe1sVX1K7hWed oQ2vD5nDD4cKYHQMqs1ShVZ7s1ZcieLRdx12COreB9e9vazjIAfQH0qkMOxgbAvMis7H /3XEpCvRHuhZx7j6J3FmzwjCMwDqLMzZd/sIa4LxZhl+TIQWHZbDva4KqVoad2s5xT7S x0eDDX5jO85RYBiiXqBTADEBhZwbO15EZfMLKNsiNqF+bExaugY7uXjyl2+5UEzDL894 EKzw== 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:in-reply-to:references; bh=BcKGfqptsJMIyqg8m+kdv7mwKKvvYfua8/fbCWYYrS8=; b=TXg0U8v03XE8QmoCLBKWdvxZjUmSEoABJ4QSv8Eh+7nmMPMl+h3nwBd1cary/I4uvf WKw4Vw1bfCkP7E7lthz/DiSQ6n5t/Hjxs7HL0QxEMTd8nuS46dvi/YBLpiDWDvZDPf0s LP/58QADXMtj1nERhjCGwd85EHS1oV7GXsONHOATt+Im7nYCcHbDk9NQI5dsc+aKD+b0 sWrkeOLM2UP1KFecpiOLFUhtGvpHosKkjSLv2r3KAPj9uXAcqgCSUygm9vwFSRCfokvA EO7HXqGc6HVkvhQGkCteq8UMmKv5CoP19ufQ2pojUMJnxUDFSPdbHWKq22RwaohAm5de P7bA== X-Gm-Message-State: APjAAAXHwoes879nRDM8ZUwVAkp7aeyGLISrucaZ0TddR0AnRhDzD1aE M9xSXWR40ujzJzTNhbCRWob5pQ== X-Received: by 2002:a62:e508:: with SMTP id n8mr20353567pff.199.1568186207721; Wed, 11 Sep 2019 00:16:47 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id 20sm24094678pfh.72.2019.09.11.00.16.46 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:16:47 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: linux-pm@vger.kernel.org Subject: [PATCH v3 02/15] drivers: thermal: tsens: Simplify code flow in tsens_probe Date: Wed, 11 Sep 2019 12:46:19 +0530 Message-Id: X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Move platform_set_drvdata up to avoid an extra 'if (ret)' check after the call to tsens_register. Signed-off-by: Amit Kucheria Reviewed-by: Stephen Boyd Reviewed-by: Daniel Lezcano --- drivers/thermal/qcom/tsens.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) -- 2.17.1 diff --git a/drivers/thermal/qcom/tsens.c b/drivers/thermal/qcom/tsens.c index 6ed687a6e53c..542a7f8c3d96 100644 --- a/drivers/thermal/qcom/tsens.c +++ b/drivers/thermal/qcom/tsens.c @@ -149,6 +149,8 @@ static int tsens_probe(struct platform_device *pdev) priv->feat = data->feat; priv->fields = data->fields; + platform_set_drvdata(pdev, priv); + if (!priv->ops || !priv->ops->init || !priv->ops->get_temp) return -EINVAL; @@ -167,11 +169,7 @@ static int tsens_probe(struct platform_device *pdev) } } - ret = tsens_register(priv); - - platform_set_drvdata(pdev, priv); - - return ret; + return tsens_register(priv); } static int tsens_remove(struct platform_device *pdev) From patchwork Wed Sep 11 07:16:20 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173591 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374207ilq; Wed, 11 Sep 2019 00:16:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqydBab9LZD/3dG8g/91hewd3gF5DE3UpZSMj6EZtYlFvMksJitqdNv7Igz+5Yul+gjOB99r X-Received: by 2002:a17:907:1048:: with SMTP id oy8mr28343471ejb.17.1568186214678; Wed, 11 Sep 2019 00:16:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186214; cv=none; d=google.com; s=arc-20160816; b=QmAZ3neg61NvnpJHAovrz4QxR3QQW47qqWfpOTZlwSkUdO8+Y2O41xXvNIses8TdYA occ3Mt4h0wRQaZgWYwMzRocRqU8NiN9X9Rodc8m86yXYqJAL31xpbQhp7CAJpeCeXbOc IvYqMPZfr1lMRkR1xrls69bY8sxNnLUf013xxPucl1ndg8rCXbspMioDhoaeJ4pihgFw J0jO7vozvaCZXYCHJ2cvwaUOI1Np3/CKTNI15ElraZB5RjhfMXjZ6+k4zz8wIRjC/XP6 K4QSblbLB51VkUAKbjjQUiWwQaxpyg7QwVd7yTXNCXozY8ORH6BK9vGN08FFN03SIOWw c3HQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=4RhmNFrAjG8zCFd7O6KRoEzlzkP2xNrQ5XZHUG6WYMo=; b=QYrmJnpJDKZBtSC8OXnFSEZOLxHv6Ss7v8LgG9YxC5jrTwCZn1hgHP0GbmI2c3t1Ci lzxX2PMmPQSEmJjv8i/48gGLfvt4rW1lMUed5oNHgDOJ7s0demI6irg32nIgCIYXOOP8 gEqAHoanerMf+IfiGApXLFDWcgn1P92tPWlCrPQUB12RLp1Rk7B6WVk7fDFLMdSRkMQ3 ulF94T9eft8u5IW3CAxKLqMq3c+OOxI/8S8H418yCo6n2SuUawHk+lceANNA7Q6xZ7hi 6iW3n+bCrX3maoO0w85LXFo5QMp8P6f9tfefPYqx73T/5smT45/uQDgjJyQjy8U6v89q GAOg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hfjY3QEN; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id b33si11659121edc.265.2019.09.11.00.16.54; Wed, 11 Sep 2019 00:16:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hfjY3QEN; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1727039AbfIKHQw (ORCPT + 15 others); Wed, 11 Sep 2019 03:16:52 -0400 Received: from mail-pl1-f196.google.com ([209.85.214.196]:40823 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726928AbfIKHQw (ORCPT ); Wed, 11 Sep 2019 03:16:52 -0400 Received: by mail-pl1-f196.google.com with SMTP id y10so9754980pll.7 for ; Wed, 11 Sep 2019 00:16:52 -0700 (PDT) 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 :in-reply-to:references; bh=4RhmNFrAjG8zCFd7O6KRoEzlzkP2xNrQ5XZHUG6WYMo=; b=hfjY3QENwOjtr0x1P9FLoxQ8HbWVvFtCTxs4dBSSCRszuxmG6vDUnB2snJ2wLMwaiy PxWA9K/x4lGty5FbGIw3uvXc0zFpQXNjZTAjjroE1ORwjN456I+yq/koVopZfVNXYMV9 GsPpNlQa3w92QLUg0IsVmNglJeczEIwAPjpIIJW+Qq/m41zd8tlIRetY4oxp2Duzhr+v 83QKhXI5MGAevWXXUE+nNqBOUbqTzzw54fjbAm+bXGv78Enxem3zqEizWqaid5Tq1alq AJhuUssClO1jk+CYY2EUuMGVxe0U9K3u2LUUn3sXVYhoi1HF1iNz5GpA7jqmkxfZDn92 CgTQ== 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:in-reply-to:references; bh=4RhmNFrAjG8zCFd7O6KRoEzlzkP2xNrQ5XZHUG6WYMo=; b=f7oLkcR3WG6xL/a0rFWZQ8yxAGU6NSzmGH7GAOf0raweYdw3OWQy9P5CGsvHsT+kvb NLcJWFtxk0DNYVK4ZEJ/gR6qFuZEoS2QiCcDlZJq/GP5U9ui3TnFnx8Hbr5AF1C8rcM4 obttTHi6GWfyvXbA6qjD6HIp2I5SIYhTwwH9bfz8cpQEaurDhvJ1LP9y+IVwp8n5rC/b LIEElgu4j/YVOxiUSzLcOv3zj8gIznQvpn2ZnRfO5I4rcDsdxGMbJWs8/6PyhUmauoMW WxTfEGLy9HfjBM1GdNZdmyZ1Ujjw4ty4P2jIUhSYFmpEyBl9dM+AOBt7Gj0K7Za9pVnn u/9A== X-Gm-Message-State: APjAAAX7LBYUfRoJf/yXpmWOczolGdiCu3QrpDRg6WJvfaMvsRV6Ft+y HctNoP9QPXwATu6cleEQgqPCKw== X-Received: by 2002:a17:902:8f97:: with SMTP id z23mr19935097plo.299.1568186211616; Wed, 11 Sep 2019 00:16:51 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id a1sm19631901pgd.74.2019.09.11.00.16.50 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:16:50 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: linux-pm@vger.kernel.org Subject: [PATCH v3 03/15] drivers: thermal: tsens: Add __func__ identifier to debug statements Date: Wed, 11 Sep 2019 12:46:20 +0530 Message-Id: X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Printing the function name when enabling debugging makes logs easier to read. Signed-off-by: Amit Kucheria Reviewed-by: Stephen Boyd Reviewed-by: Daniel Lezcano --- drivers/thermal/qcom/tsens-common.c | 8 ++++---- drivers/thermal/qcom/tsens.c | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) -- 2.17.1 diff --git a/drivers/thermal/qcom/tsens-common.c b/drivers/thermal/qcom/tsens-common.c index c037bdf92c66..7437bfe196e5 100644 --- a/drivers/thermal/qcom/tsens-common.c +++ b/drivers/thermal/qcom/tsens-common.c @@ -42,8 +42,8 @@ void compute_intercept_slope(struct tsens_priv *priv, u32 *p1, for (i = 0; i < priv->num_sensors; i++) { dev_dbg(priv->dev, - "sensor%d - data_point1:%#x data_point2:%#x\n", - i, p1[i], p2[i]); + "%s: sensor%d - data_point1:%#x data_point2:%#x\n", + __func__, i, p1[i], p2[i]); priv->sensor[i].slope = SLOPE_DEFAULT; if (mode == TWO_PT_CALIB) { @@ -60,7 +60,7 @@ void compute_intercept_slope(struct tsens_priv *priv, u32 *p1, priv->sensor[i].offset = (p1[i] * SLOPE_FACTOR) - (CAL_DEGC_PT1 * priv->sensor[i].slope); - dev_dbg(priv->dev, "offset:%d\n", priv->sensor[i].offset); + dev_dbg(priv->dev, "%s: offset:%d\n", __func__, priv->sensor[i].offset); } } @@ -209,7 +209,7 @@ int __init init_common(struct tsens_priv *priv) if (ret) goto err_put_device; if (!enabled) { - dev_err(dev, "tsens device is not enabled\n"); + dev_err(dev, "%s: device not enabled\n", __func__); ret = -ENODEV; goto err_put_device; } diff --git a/drivers/thermal/qcom/tsens.c b/drivers/thermal/qcom/tsens.c index 542a7f8c3d96..06c6bbd69a1a 100644 --- a/drivers/thermal/qcom/tsens.c +++ b/drivers/thermal/qcom/tsens.c @@ -127,7 +127,7 @@ static int tsens_probe(struct platform_device *pdev) of_property_read_u32(np, "#qcom,sensors", &num_sensors); if (num_sensors <= 0) { - dev_err(dev, "invalid number of sensors\n"); + dev_err(dev, "%s: invalid number of sensors\n", __func__); return -EINVAL; } @@ -156,7 +156,7 @@ static int tsens_probe(struct platform_device *pdev) ret = priv->ops->init(priv); if (ret < 0) { - dev_err(dev, "tsens init failed\n"); + dev_err(dev, "%s: init failed\n", __func__); return ret; } @@ -164,7 +164,7 @@ static int tsens_probe(struct platform_device *pdev) ret = priv->ops->calibrate(priv); if (ret < 0) { if (ret != -EPROBE_DEFER) - dev_err(dev, "tsens calibration failed\n"); + dev_err(dev, "%s: calibration failed\n", __func__); return ret; } } From patchwork Wed Sep 11 07:16:21 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173592 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374273ilq; Wed, 11 Sep 2019 00:16:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqzb3CbuogsVkyU5LFIA290uIbzHGy147Th35xOZWKufEDhab/i0X3OXIpUApPPGrAVODuPa X-Received: by 2002:a17:906:480b:: with SMTP id w11mr28768377ejq.137.1568186218959; Wed, 11 Sep 2019 00:16:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186218; cv=none; d=google.com; s=arc-20160816; b=xZ9lm1YLRg6Y63ukMnkTiSTHs8khtGkCXj33mu1i3cJ/JHrxIWBLBixnTZNBSzNAz4 8RWpxxcHatglu4ddDEmZvU6SoCZHmXOGWHoKwIs83+/Aoafj9z87WlFVNKo/vdYZYs8l VWcC4Nkv7Qg7CjuXT6odQsq/2NUTrW+6dxOj2JEQ5bTLfkVF1AidiH95MHs9yV3B9+ue F17WWfK3O+6z1TmIPRtN802FXJ5sq6E2+8f/CyJMQZYAxkk+r5HJOJLlVdoN/fxF8FSx 698sDHwwzbceH2mipkr4lJUL9DTncCniOeh4zx7tFLwNz7zFC02KLdReQdBiPOAiDFbE 2VyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=GhiEdPc2a74wJTsECxjn5PPZJWIyvNu4x7DC2dya90E=; b=v7c1XQCKFRcIwN37WCTTTlK3IsGBB9a/O6ULyjD/qykDcUvL2q1dNKCzE5ihqWkcxh J+PATzUNek6SfZtGSME/M04wGbnzuH9n/tfjAyWJ71ZFWy5+Ti8Zxh39OR3zxHTrk11/ RvMnN0h1jtWApzniurOJ9A1gNm3VQPS1CnrAS3a82+TRQzIS3XK3F5OGyA3J/aKw+KZk xzxc3ShhfJ0XPKhew3WZ634Of0BIqkjzv/79inuzy0sF46ypIeffTz/2sFujpcPDUHfS g6kqXP3bjWywRsphLtWLWdxshfkIO3nfQry/8YafEJB88jMe8zKFCvJbH+FfcbAmrufM pHyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="N/QIyJ/W"; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id b15si13950401eda.152.2019.09.11.00.16.58; Wed, 11 Sep 2019 00:16:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="N/QIyJ/W"; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1727090AbfIKHQ5 (ORCPT + 15 others); Wed, 11 Sep 2019 03:16:57 -0400 Received: from mail-pf1-f195.google.com ([209.85.210.195]:34845 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727072AbfIKHQ4 (ORCPT ); Wed, 11 Sep 2019 03:16:56 -0400 Received: by mail-pf1-f195.google.com with SMTP id 205so13098177pfw.2 for ; Wed, 11 Sep 2019 00:16:55 -0700 (PDT) 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 :in-reply-to:references; bh=GhiEdPc2a74wJTsECxjn5PPZJWIyvNu4x7DC2dya90E=; b=N/QIyJ/WXEc1iBsfLQyDROFokBA6ARR4Qc3H3HUYWh4CPutDhlY5CdY1MATbWcCoBI z1OQd6EHlkNXk8z91+4Tl47+ldJGfygsNw+WRfyhHMHJqN5o7/E2R0DzNfwx9LFJajlV 8cNxQhL/3T3uRmlp3I6KANueL28n559AdDpmZpqBUX0eZAteMpSNE1vVyEU6cac0IFYk L3BykqM6+TG0fOeywQGF2LKnBN5ElipkOXa+n2DlPYK4dx8YwiGT2HJA5xhWsur7vDNm 0jI/tmTrmkzGQDcuoLNFGWkoC69neUQmq8ESPn+J8UlNFhC7icLWfCo6q3GX4NLLMW42 GKTA== 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:in-reply-to:references; bh=GhiEdPc2a74wJTsECxjn5PPZJWIyvNu4x7DC2dya90E=; b=iMWJkL+IxBkyyHasm46j0S/nGTZzK9lSIhFJ4cZWJJw8qMIZWjlX2wVD4ixwIN4JUq TtpK1LLwQD5RenykSTQ3fWbK2rai+hX7hnKA4L20NLKdzmxCk5FAmG43XgUKAhv+sSaT h7Yu1ylvWc45fHBbPcNiZS8LY5OCd53q5KeRxu7eVEMvtcy2YjfpU8RXh2r6LnmLnldW y1jCkwHIhugvPOdpmLQbibN+M2VRgXquT+Xnb0knnNSaRf1RPe1HlCogsOO5Hz8uso8x UQfiHG6y5jUuzSX8A51WXNFWebgK6wehFR8kP4cI1H1dWwrTb1ujXsTA59PPDbhSJ46m scxA== X-Gm-Message-State: APjAAAUT3M03HRaYedXv3s+bc2SYotpj6NFaPqYb8lqLjy809l6+gjC8 ij09GkI01jAsAenViRBKwNEHuA== X-Received: by 2002:a17:90a:c597:: with SMTP id l23mr3970989pjt.62.1568186215426; Wed, 11 Sep 2019 00:16:55 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id d20sm28426227pfq.88.2019.09.11.00.16.54 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:16:54 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: linux-pm@vger.kernel.org Subject: [PATCH v3 04/15] drivers: thermal: tsens: Add debugfs support Date: Wed, 11 Sep 2019 12:46:21 +0530 Message-Id: X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Dump some basic version info and sensor details into debugfs. Example from qcs404 below: --(/sys/kernel/debug) $ ls tsens/ 4a9000.thermal-sensor version --(/sys/kernel/debug) $ cat tsens/version 1.4.0 --(/sys/kernel/debug) $ cat tsens/4a9000.thermal-sensor/sensors max: 11 num: 10 id slope offset ------------------------ 0 3200 404000 1 3200 404000 2 3200 404000 3 3200 404000 4 3200 404000 5 3200 404000 6 3200 404000 7 3200 404000 8 3200 404000 9 3200 404000 Signed-off-by: Amit Kucheria Reviewed-by: Stephen Boyd --- drivers/thermal/qcom/tsens-common.c | 83 +++++++++++++++++++++++++++++ drivers/thermal/qcom/tsens.c | 2 + drivers/thermal/qcom/tsens.h | 6 +++ 3 files changed, 91 insertions(+) -- 2.17.1 diff --git a/drivers/thermal/qcom/tsens-common.c b/drivers/thermal/qcom/tsens-common.c index 7437bfe196e5..ea2c46cc6a66 100644 --- a/drivers/thermal/qcom/tsens-common.c +++ b/drivers/thermal/qcom/tsens-common.c @@ -3,6 +3,7 @@ * Copyright (c) 2015, The Linux Foundation. All rights reserved. */ +#include #include #include #include @@ -139,6 +140,77 @@ int get_temp_common(struct tsens_sensor *s, int *temp) return 0; } +#ifdef CONFIG_DEBUG_FS +static int dbg_sensors_show(struct seq_file *s, void *data) +{ + struct platform_device *pdev = s->private; + struct tsens_priv *priv = platform_get_drvdata(pdev); + int i; + + seq_printf(s, "max: %2d\nnum: %2d\n\n", + priv->feat->max_sensors, priv->num_sensors); + + seq_puts(s, " id slope offset\n--------------------------\n"); + for (i = 0; i < priv->num_sensors; i++) { + seq_printf(s, "%8d %8d %8d\n", priv->sensor[i].hw_id, + priv->sensor[i].slope, priv->sensor[i].offset); + } + + return 0; +} + +static int dbg_version_show(struct seq_file *s, void *data) +{ + struct platform_device *pdev = s->private; + struct tsens_priv *priv = platform_get_drvdata(pdev); + u32 maj_ver, min_ver, step_ver; + int ret; + + if (tsens_ver(priv) > VER_0_1) { + ret = regmap_field_read(priv->rf[VER_MAJOR], &maj_ver); + if (ret) + return ret; + ret = regmap_field_read(priv->rf[VER_MINOR], &min_ver); + if (ret) + return ret; + ret = regmap_field_read(priv->rf[VER_STEP], &step_ver); + if (ret) + return ret; + seq_printf(s, "%d.%d.%d\n", maj_ver, min_ver, step_ver); + } else { + seq_puts(s, "0.1.0\n"); + } + + return 0; +} + +DEFINE_SHOW_ATTRIBUTE(dbg_version); +DEFINE_SHOW_ATTRIBUTE(dbg_sensors); + +static void tsens_debug_init(struct platform_device *pdev) +{ + struct tsens_priv *priv = platform_get_drvdata(pdev); + struct dentry *root, *file; + + root = debugfs_lookup("tsens", NULL); + if (!root) + priv->debug_root = debugfs_create_dir("tsens", NULL); + else + priv->debug_root = root; + + file = debugfs_lookup("version", priv->debug_root); + if (!file) + debugfs_create_file("version", 0444, priv->debug_root, + pdev, &dbg_version_fops); + + /* A directory for each instance of the TSENS IP */ + priv->debug = debugfs_create_dir(dev_name(&pdev->dev), priv->debug_root); + debugfs_create_file("sensors", 0444, priv->debug, pdev, &dbg_sensors_fops); +} +#else +static inline void tsens_debug_init(struct platform_device *pdev) {} +#endif + static const struct regmap_config tsens_config = { .name = "tm", .reg_bits = 32, @@ -199,6 +271,15 @@ int __init init_common(struct tsens_priv *priv) goto err_put_device; } + if (tsens_ver(priv) > VER_0_1) { + for (i = VER_MAJOR; i <= VER_STEP; i++) { + priv->rf[i] = devm_regmap_field_alloc(dev, priv->srot_map, + priv->fields[i]); + if (IS_ERR(priv->rf[i])) + return PTR_ERR(priv->rf[i]); + } + } + priv->rf[TSENS_EN] = devm_regmap_field_alloc(dev, priv->srot_map, priv->fields[TSENS_EN]); if (IS_ERR(priv->rf[TSENS_EN])) { @@ -238,6 +319,8 @@ int __init init_common(struct tsens_priv *priv) } } + tsens_debug_init(op); + return 0; err_put_device: diff --git a/drivers/thermal/qcom/tsens.c b/drivers/thermal/qcom/tsens.c index 06c6bbd69a1a..772aa76b50e1 100644 --- a/drivers/thermal/qcom/tsens.c +++ b/drivers/thermal/qcom/tsens.c @@ -3,6 +3,7 @@ * Copyright (c) 2015, The Linux Foundation. All rights reserved. */ +#include #include #include #include @@ -176,6 +177,7 @@ static int tsens_remove(struct platform_device *pdev) { struct tsens_priv *priv = platform_get_drvdata(pdev); + debugfs_remove_recursive(priv->debug_root); if (priv->ops->disable) priv->ops->disable(priv); diff --git a/drivers/thermal/qcom/tsens.h b/drivers/thermal/qcom/tsens.h index d022e726d074..e1d6af71b2b9 100644 --- a/drivers/thermal/qcom/tsens.h +++ b/drivers/thermal/qcom/tsens.h @@ -292,6 +292,8 @@ struct tsens_context { * @feat: features of the IP * @fields: bitfield locations * @ops: pointer to list of callbacks supported by this device + * @debug_root: pointer to debugfs dentry for all tsens + * @debug: pointer to debugfs dentry for tsens controller * @sensor: list of sensors attached to this device */ struct tsens_priv { @@ -305,6 +307,10 @@ struct tsens_priv { const struct tsens_features *feat; const struct reg_field *fields; const struct tsens_ops *ops; + + struct dentry *debug_root; + struct dentry *debug; + struct tsens_sensor sensor[0]; }; From patchwork Wed Sep 11 07:16:23 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173594 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374423ilq; Wed, 11 Sep 2019 00:17:07 -0700 (PDT) X-Google-Smtp-Source: APXvYqy0Hz0r1uWuDANMWHWooGH/RF/NvNC8FkizwZQbBsv47F8xPqIWIQj5PoEjPa9iJHlTO09H X-Received: by 2002:a50:99da:: with SMTP id n26mr18796537edb.293.1568186227252; Wed, 11 Sep 2019 00:17:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186227; cv=none; d=google.com; s=arc-20160816; b=Na/PH/0iqvwErPVBOYDvqd+2c/0REvpTo7fI6jSK+yTfiZHHVEr/NZae9C32zbfH6X N7fC1mqH53/d9OjV+GaYK8NsbXhRakNM7HBEXHdxjHsWlLhWoRBVBgUhztVq//hItwYO 5peC/UC48THB7GLMU/cmfM4syDRhLt6rNy7zDTWDgIs6IV7ZWKaUvlkj8XpfjrHleF3x 0RwXHF6+42vQMyIj/qIbbw2FScYkjHN2Jw3WMPo3bBXQ18zZqJxRalZPOv/v7vmTCbfU 4KUp1fTkMvDi/xoxCR2oJq+AAUrAoUheUP6M5Gy9baWCak8n1CKDV6fdIaO9GUYQ/BU5 uzbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=3aqllZnhirWen18NJ9rLavBCP+/YOWA9zZa8CCtZyTg=; b=rH/8TSJ9ucva40maHT3urCt2Ze1zsNJj2weeGl3cBN8Qp6Gxkecl+JE55Vll8UA6rl tApEZep59dvRLgEXI6qlBPCV1mRDdxKOzjfcTdmtfPHxh1LADzy680eh/nQrCxkMCrY4 QUItsygKKQqxG8tYS+4QZlzB06jW+JSABpfv3rMxvpm8wHQx9XxFbTnT4fb4/gLVC3yw iVc6PNAUZe5oAE8A2VzPTmN8J5HaXzQ9Ii5feY6ll8amTKdpfBFBn6WxXXbcDgN15V65 wHjVH6KjE7IKiBR+1/JZFC203pxC3AH5LJWYnJHvV0/dJfMzVy393cl5nNnXFNllaLIX a1ww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=L3wGd7LB; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id d12si984869eds.351.2019.09.11.00.17.07; Wed, 11 Sep 2019 00:17:07 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=L3wGd7LB; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1727137AbfIKHRE (ORCPT + 15 others); Wed, 11 Sep 2019 03:17:04 -0400 Received: from mail-pg1-f196.google.com ([209.85.215.196]:33809 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727109AbfIKHRD (ORCPT ); Wed, 11 Sep 2019 03:17:03 -0400 Received: by mail-pg1-f196.google.com with SMTP id n9so11080863pgc.1 for ; Wed, 11 Sep 2019 00:17:03 -0700 (PDT) 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 :in-reply-to:references; bh=3aqllZnhirWen18NJ9rLavBCP+/YOWA9zZa8CCtZyTg=; b=L3wGd7LB0bierPG9sbQdy13pJdxcVz2jCSo3BbxJYYWTs+0POADWJOxwUle/17TUzo nqLzYwD7X/sDwdnvK0tGeWCUrP5jVynB9yFyIiRf+/k46QIGkYxJmLeiedtivkGraazl i3nqMnWRkTPMiDBcLXyLkP+HbwVzO+u2wLRHtnzRxLKNkO5MHbk/k2q9v118eDi/ikPt zHlHdbNtsXVBE0hkfKlWJsAG5RlNxGxH72czlbwKJBqh0gVWQDsB+dVFrNhRiVqgmu0c +Z1d9pdiyZA+uVLxRAKVFrGN1NJohaQMQlasvruHAqtTBXLiFWOBJKSD6X+8gUiKo/NS ZBnQ== 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:in-reply-to:references; bh=3aqllZnhirWen18NJ9rLavBCP+/YOWA9zZa8CCtZyTg=; b=JozUkQINKN5SidRAmdIjB6GZYdEqXEB4SBhRFW/VZR5tcCsTRQ+11GR7mktPi8mX7H IHKI+SM46MEz184Dt2CaxY370H8pAfzuZ6OVciZSyswAQw7hpSEqAjZ9AyTUDwViseoW KhBFVRLNxNExJaJqPpF0ZKdPr0F8xylEoOCLcJOHRKAddUUeBnrsFKbAgN2/AUOutRUq XlAzZqUXyh9+sEwqA1qym/F5va/+T8j5nApHtoirNBmRn/hLCW1nt+Xpc5VXCm+0IXAY 2QlYgGnP1INgWprGHmmwE21Z3jce7+4AImo/Wj4E4GXK6ySh4QsQV2N9yQ8Mlp674y1i aOVg== X-Gm-Message-State: APjAAAUrmxqM205wH1o4YhgpATVcN9k9p1RvVg6GiT6vFJxN/QYbzGAp xaN98FlAy8rliyO/lhs3kGwL/g== X-Received: by 2002:a62:15c7:: with SMTP id 190mr39946864pfv.107.1568186222731; Wed, 11 Sep 2019 00:17:02 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id b10sm152893pjo.1.2019.09.11.00.17.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:17:02 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: devicetree@vger.kernel.org Subject: [PATCH v3 06/15] arm64: dts: msm8916: thermal: Fixup HW ids for cpu sensors Date: Wed, 11 Sep 2019 12:46:23 +0530 Message-Id: <47305ec06a4b76a79aa073e4c0202a27a853a700.1568185732.git.amit.kucheria@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org msm8916 uses sensors 0, 1, 2, 4 and 5. Sensor 3 is NOT used. Fixup the device tree so that the correct sensor ID is used and as a result we can actually check the temperature for the cpu2_3 sensor. Signed-off-by: Amit Kucheria Reviewed-by: Daniel Lezcano Reviewed-by: Stephen Boyd --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.17.1 diff --git a/arch/arm64/boot/dts/qcom/msm8916.dtsi b/arch/arm64/boot/dts/qcom/msm8916.dtsi index 5ea9fb8f2f87..8686e101905c 100644 --- a/arch/arm64/boot/dts/qcom/msm8916.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8916.dtsi @@ -179,7 +179,7 @@ polling-delay-passive = <250>; polling-delay = <1000>; - thermal-sensors = <&tsens 4>; + thermal-sensors = <&tsens 5>; trips { cpu0_1_alert0: trip-point@0 { @@ -209,7 +209,7 @@ polling-delay-passive = <250>; polling-delay = <1000>; - thermal-sensors = <&tsens 3>; + thermal-sensors = <&tsens 4>; trips { cpu2_3_alert0: trip-point@0 { From patchwork Wed Sep 11 07:16:24 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173595 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374470ilq; Wed, 11 Sep 2019 00:17:10 -0700 (PDT) X-Google-Smtp-Source: APXvYqy2qjNnwkdMgbq+g1ohXR6DwCHZ+CDxdZYDEMW8jBTau8iDaXsCxFE3vsYofm9w775V+zMs X-Received: by 2002:a17:906:3746:: with SMTP id e6mr29328908ejc.35.1568186230175; Wed, 11 Sep 2019 00:17:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186230; cv=none; d=google.com; s=arc-20160816; b=YT1oUim4jAm2goZFs5ts4hGgkRnbnzLSOgv9pjcRgbgyGCafDcseE4Mr3OCNrhgtW0 4AI75aVz8g5xM5yt/pb/kBZmimbHGPjfd3Pe7F95vJZzFo86we8cuKSIsZV+a7NAU/hg BBz25nOn3IACq3de7w8nuJxupHekbhN/VYN+x7MQenQrFV2uF9+Rtoav+A1AWCiWvvN/ q1HHQGWAZbAUIv+EUXuGsyomINVPOeGkoeKx8pn4IAz4xq8JE6ufKRPZxC2Hbu5nmNSB BfDrYZlvRShQJXY10I5r69VIM22c8lrYsJqLXGaMOfrh5JEiSlvHxya16zgoK86ZNfbz VVXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=5U8Xn1q8Z74Mq83nqRSGd/n/boLzuvzoaz5vn7lXR3A=; b=ajteOWbRPjOJ+HyzOrPaTCr4WE9BTB8tvlqWge4gfdGEGHHiPFFAFBLlobt+OIzXDh PIaaD7xZyJ5Nd89TDBS1rILvANcCz2AwllrYV0Kx1AnWP6SGgdPGkJKLdaynC8/NlrRp G5jyHAZpD4SDnLQkQZHywnMmTmlqYowGTpe0Qp8K/A6KFVs/ER9mdWBw2c/nzIz9Ljqn RVG2pBSkzS9B6e0RAYR+Pu/H+FnpsSngZx9d3jUT16oEIXoUz/PkkJLj8c1JrAqh+jci xIfiMDItznzn2wreZimYEgNbpJmf4iOh5lMw0lweLHpfrjLyPOV+q3pe8uXkfWuk6z+b HqyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VALWmmTy; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id d12si984869eds.351.2019.09.11.00.17.09; Wed, 11 Sep 2019 00:17:10 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VALWmmTy; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1727165AbfIKHRJ (ORCPT + 15 others); Wed, 11 Sep 2019 03:17:09 -0400 Received: from mail-pg1-f195.google.com ([209.85.215.195]:39751 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727135AbfIKHRI (ORCPT ); Wed, 11 Sep 2019 03:17:08 -0400 Received: by mail-pg1-f195.google.com with SMTP id u17so11054434pgi.6 for ; Wed, 11 Sep 2019 00:17:07 -0700 (PDT) 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 :in-reply-to:references; bh=5U8Xn1q8Z74Mq83nqRSGd/n/boLzuvzoaz5vn7lXR3A=; b=VALWmmTyhWFVGeo1L9W3RX6Rm0TiRbc0V4xIZFeyqY+h1FBE5fd1JcnpYUWlJzsXPy GN6TM8X8BnGUIpjQhpomFsNOfeOrSO+vhhGGK9KtVwEUx6yKOzjWjD3UgBn+1YCKr7WE kuGeXfn54h7EueUtXLRx+XKGYM69e2euYIMd7VDXVwWHJfOCsuR9F30ClsQhIYse2p7H F9BZR0wG2gQ5S4Jb54DX9bih+M7w/wLlX6jhu4mCjLE8Fd1xlCHR/PTKwB32vG+aBXPq UToJQmzMy+4wFO6nvrN62tqAPlTZf8o7sNStlrAuQqxCoiDVrI4rXCw6Q0CXS1hrj49K Cz4g== 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:in-reply-to:references; bh=5U8Xn1q8Z74Mq83nqRSGd/n/boLzuvzoaz5vn7lXR3A=; b=jgmLwT6fiP2ZvPosp1k4kNlC4uEneaZ1BKxMolhTuTc/K9JkCwLjiLVLlsfwhaTlmv 69IfRy9ON7JCUHDWkTrhZX4Vt2hEHs11WMa+VStyPMnaa+WSZchb9vfHhvcd1w+KdXnM qe3Hwk5i7eeO597QWVF5zuH2w05YfDxkygIKzj7m/imv6M5O30AFerGmuWt9/AfIobEP Haowf4qRMeBDzkPTL7MaT8uRrxUj5GqQaMMc8mR1mmqi4Qi3UG84vVl1V+u42TBauSYM kQJCesLhzY/mU5g0dKd+I2jhNZv7H8nLKRNJwvZ5ydAzis90JN0XKt9QRChaVXpGX0G1 5eaQ== X-Gm-Message-State: APjAAAUack4vJXL+qOTAVr6oJiVeu1t3p5Juq9SwmU+hhI4dKtdEpsc7 /8UM5iob2/tVtwbWuK+v24H/yA== X-Received: by 2002:a65:5cca:: with SMTP id b10mr32444613pgt.365.1568186226553; Wed, 11 Sep 2019 00:17:06 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id f188sm25569788pfa.170.2019.09.11.00.17.05 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:17:05 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v3 07/15] dt-bindings: thermal: tsens: Convert over to a yaml schema Date: Wed, 11 Sep 2019 12:46:24 +0530 Message-Id: <933f033298cbd7726a6c0b4b3b6cc7adc81784ba.1568185732.git.amit.kucheria@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Document interrupt support in the tsens driver by converting over to a YAML schema. Suggested-by: Stephen Boyd Signed-off-by: Amit Kucheria --- .../bindings/thermal/qcom-tsens.txt | 55 ------ .../bindings/thermal/qcom-tsens.yaml | 174 ++++++++++++++++++ MAINTAINERS | 1 + 3 files changed, 175 insertions(+), 55 deletions(-) delete mode 100644 Documentation/devicetree/bindings/thermal/qcom-tsens.txt create mode 100644 Documentation/devicetree/bindings/thermal/qcom-tsens.yaml -- 2.17.1 diff --git a/Documentation/devicetree/bindings/thermal/qcom-tsens.txt b/Documentation/devicetree/bindings/thermal/qcom-tsens.txt deleted file mode 100644 index 673cc1831ee9..000000000000 --- a/Documentation/devicetree/bindings/thermal/qcom-tsens.txt +++ /dev/null @@ -1,55 +0,0 @@ -* QCOM SoC Temperature Sensor (TSENS) - -Required properties: -- compatible: - Must be one of the following: - - "qcom,msm8916-tsens" (MSM8916) - - "qcom,msm8974-tsens" (MSM8974) - - "qcom,msm8996-tsens" (MSM8996) - - "qcom,qcs404-tsens", "qcom,tsens-v1" (QCS404) - - "qcom,msm8998-tsens", "qcom,tsens-v2" (MSM8998) - - "qcom,sdm845-tsens", "qcom,tsens-v2" (SDM845) - The generic "qcom,tsens-v2" property must be used as a fallback for any SoC - with version 2 of the TSENS IP. MSM8996 is the only exception because the - generic property did not exist when support was added. - Similarly, the generic "qcom,tsens-v1" property must be used as a fallback for - any SoC with version 1 of the TSENS IP. - -- reg: Address range of the thermal registers. - New platforms containing v2.x.y of the TSENS IP must specify the SROT and TM - register spaces separately, with order being TM before SROT. - See Example 2, below. - -- #thermal-sensor-cells : Should be 1. See ./thermal.txt for a description. -- #qcom,sensors: Number of sensors in tsens block -- Refer to Documentation/devicetree/bindings/nvmem/nvmem.txt to know how to specify -nvmem cells - -Example 1 (legacy support before a fallback tsens-v2 property was introduced): -tsens: thermal-sensor@900000 { - compatible = "qcom,msm8916-tsens"; - reg = <0x4a8000 0x2000>; - nvmem-cells = <&tsens_caldata>, <&tsens_calsel>; - nvmem-cell-names = "caldata", "calsel"; - #thermal-sensor-cells = <1>; - }; - -Example 2 (for any platform containing v2 of the TSENS IP): -tsens0: thermal-sensor@c263000 { - compatible = "qcom,sdm845-tsens", "qcom,tsens-v2"; - reg = <0xc263000 0x1ff>, /* TM */ - <0xc222000 0x1ff>; /* SROT */ - #qcom,sensors = <13>; - #thermal-sensor-cells = <1>; - }; - -Example 3 (for any platform containing v1 of the TSENS IP): -tsens: thermal-sensor@4a9000 { - compatible = "qcom,qcs404-tsens", "qcom,tsens-v1"; - reg = <0x004a9000 0x1000>, /* TM */ - <0x004a8000 0x1000>; /* SROT */ - nvmem-cells = <&tsens_caldata>; - nvmem-cell-names = "calib"; - #qcom,sensors = <10>; - #thermal-sensor-cells = <1>; - }; diff --git a/Documentation/devicetree/bindings/thermal/qcom-tsens.yaml b/Documentation/devicetree/bindings/thermal/qcom-tsens.yaml new file mode 100644 index 000000000000..6784766fe58f --- /dev/null +++ b/Documentation/devicetree/bindings/thermal/qcom-tsens.yaml @@ -0,0 +1,174 @@ +# SPDX-License-Identifier: (GPL-2.0 OR MIT) +# Copyright 2019 Linaro Ltd. +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/thermal/qcom-tsens.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: QCOM SoC Temperature Sensor (TSENS) + +maintainers: + - Amit Kucheria + +description: | + QCOM SoCs have TSENS IP to allow temperature measurement. There are currently + three distinct major versions of the IP that is supported by a single driver. + The IP versions are named v0.1, v1 and v2 in the driver, where v0.1 captures + everything before v1 when there was no versioning information. + +properties: + compatible: + oneOf: + - description: v0.1 of TSENS + items: + - enum: + - qcom,msm8916-tsens + - qcom,msm8974-tsens + - const: qcom,tsens-v0_1 + + - description: v1 of TSENS + items: + - enum: + - qcom,qcs404-tsens + - const: qcom,tsens-v1 + + - description: v2 of TSENS + items: + - enum: + - qcom,msm8996-tsens + - qcom,msm8998-tsens + - qcom,sdm845-tsens + - const: qcom,tsens-v2 + + reg: + maxItems: 2 + items: + - description: TM registers + - description: SROT registers + + nvmem-cells: + minItems: 1 + maxItems: 2 + description: + Reference to an nvmem node for the calibration data + + nvmem-cells-names: + items: + - enum: + - caldata + - calsel + + "#qcom,sensors": + allOf: + - $ref: /schemas/types.yaml#/definitions/uint32 + - minimum: 1 + - maximum: 16 + description: + Number of sensors enabled on this platform + + "#thermal-sensor-cells": + const: 1 + description: + Number of cells required to uniquely identify the thermal sensors. Since + we have multiple sensors this is set to 1 + +allOf: + - if: + properties: + compatible: + contains: + enum: + - qcom,msm8916-tsens + - qcom,msm8974-tsens + - qcom,qcs404-tsens + - qcom,tsens-v0_1 + - qcom,tsens-v1 + then: + properties: + interrupts: + minItems: 1 + maxItems: 1 + items: + - description: Combined interrupt if upper or lower threshold crossed + interrupt-names: + minItems: 1 + maxItems: 1 + items: + - const: uplow + + else: + properties: + interrupts: + minItems: 2 + maxItems: 2 + items: + - description: Combined interrupt if upper or lower threshold crossed + - description: Interrupt if critical threshold crossed + interrupt-names: + minItems: 2 + maxItems: 2 + items: + - const: uplow + - const: critical + +required: + - compatible + - reg + - "#qcom,sensors" + - interrupts + - interrupt-names + - "#thermal-sensor-cells" + +examples: + - | + #include + // Example 1 (legacy: for pre v1 IP): + tsens1: thermal-sensor@900000 { + compatible = "qcom,msm8916-tsens", "qcom,tsens-v0_1"; + reg = <0x4a9000 0x1000>, /* TM */ + <0x4a8000 0x1000>; /* SROT */ + + nvmem-cells = <&tsens_caldata>, <&tsens_calsel>; + nvmem-cell-names = "caldata", "calsel"; + + interrupts = ; + interrupt-names = "uplow"; + + #qcom,sensors = <5>; + #thermal-sensor-cells = <1>; + }; + + - | + #include + // Example 2 (for any platform containing v1 of the TSENS IP): + tsens2: thermal-sensor@4a9000 { + compatible = "qcom,qcs404-tsens", "qcom,tsens-v1"; + reg = <0x004a9000 0x1000>, /* TM */ + <0x004a8000 0x1000>; /* SROT */ + + nvmem-cells = <&tsens_caldata>; + nvmem-cell-names = "calib"; + + interrupts = ; + interrupt-names = "uplow"; + + #qcom,sensors = <10>; + #thermal-sensor-cells = <1>; + }; + + - | + #include + // Example 3 (for any platform containing v2 of the TSENS IP): + tsens3: thermal-sensor@c263000 { + compatible = "qcom,sdm845-tsens", "qcom,tsens-v2"; + reg = <0xc263000 0x1ff>, + <0xc222000 0x1ff>; + + interrupts = , + ; + interrupt-names = "uplow", "critical"; + + #qcom,sensors = <13>; + #thermal-sensor-cells = <1>; + }; +... diff --git a/MAINTAINERS b/MAINTAINERS index e7a47b5210fd..ff757a4a060c 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -13360,6 +13360,7 @@ L: linux-pm@vger.kernel.org L: linux-arm-msm@vger.kernel.org S: Maintained F: drivers/thermal/qcom/ +F: Documentation/devicetree/bindings/thermal/qcom-tsens.yaml QUALCOMM VENUS VIDEO ACCELERATOR DRIVER M: Stanimir Varbanov From patchwork Wed Sep 11 07:16:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173598 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374600ilq; Wed, 11 Sep 2019 00:17:20 -0700 (PDT) X-Google-Smtp-Source: APXvYqzGqkxeFWmDTZGyh6uU0VwH280cTFE0XRbxF0q+gxmm+LEM23rEylv+lgSAoTc6254DO7TX X-Received: by 2002:a05:6402:b11:: with SMTP id bm17mr34887964edb.31.1568186239978; Wed, 11 Sep 2019 00:17:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186239; cv=none; d=google.com; s=arc-20160816; b=RxG8Tzf3n1EKq4fLRbhhE2AddpZbhGB0ABRezqTVXbGWFR52zCMf28CNTMUfr2E5ou m5cVF1wXcJMSvuZjCvkgtEzwz/4uA8zdqhQVd+jTxN7jykdPPo2C+loEBARVlKNpDYpJ TQZkBSMgTpO+zAC6BunTvpB3l/bfGS5ypnEUlzFP3e7xBglVV+nj2ht7X2YBar+28A+o nwmdeX0uCFr7VqT0iFjlK6IsnbmXrAo9jD/7GI6HO8hx6+Og+eZanFFPxRY+LLVqZ2+P Aehc3Dt9DstuccGOSckZNSUgPN6rcOc1UAN3AmhScB1eGxd+Ntsz+T3EOUJB2Rf2tp5g ckNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=Isun0qOvFl5yGlh0uKDNBw1zhfxGw2RqA1bx4RtUflg=; b=AbPSxUMlRwrcVziEhYIV6+blOJ/YfLdZQ/ti8V3yPCTCYVhjQY/V3UUauw2lItOf+e dgiGBMUWdx6U5HCBHCrWf98Kd2qXA4u0tAtgI4s9rXzhNCByo13buJwt1doCG0Ozf7KR 0QSKET8wXPm1tKBtkn7nQFKRbdKwloNN1zA3vzeAjPJCpFGoQyyXsOe/xJ6iP5xIcXTB otAxinVQPMitoBWuyrM9SRi9cE/+qO5sIBU0eSgN3FvS5TK03yP8Jy18XGmJysOHU9DK RnxcrdHnUB7i5tYQfR10uNILrZvBWmgi3CW3x+/T1ACsvPUxRakIsKcHFK4g9Oa2vsrK ZUyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=YAUxOmJe; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id z10si10468766ejx.208.2019.09.11.00.17.19; Wed, 11 Sep 2019 00:17:19 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=YAUxOmJe; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1727225AbfIKHRT (ORCPT + 15 others); Wed, 11 Sep 2019 03:17:19 -0400 Received: from mail-pf1-f193.google.com ([209.85.210.193]:34063 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727202AbfIKHRS (ORCPT ); Wed, 11 Sep 2019 03:17:18 -0400 Received: by mail-pf1-f193.google.com with SMTP id r12so13125735pfh.1 for ; Wed, 11 Sep 2019 00:17:17 -0700 (PDT) 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 :in-reply-to:references; bh=Isun0qOvFl5yGlh0uKDNBw1zhfxGw2RqA1bx4RtUflg=; b=YAUxOmJeI9KLrUmca9+NWCeoPCj3RF/waTLmQf0yICEsgHjqydKmegBFITkPWh98AH uz/YTVExmePi5aTC/c10AIJO9KDFSpWxB/2qpXI2DK6YaqIcqA/7QjSo6o2fgqo9tbAb qeYG326DmJGQeuHGjcsoTJ0pLoAi8HYvSJ+M43uLlc+GXlQUGJxysOWyq+eBgVAyMTTE najdLheiHNUDI6Qr478JHgIn9gpVjEDTPpHNkhm6/tofuSMSlp9g3dMDq4TBAPmfy8+2 iJZ6aG2nRjrPFMhrUqJqM5IZbTPJ3sadeB1O6IC3cPZ7bO0vhTDGEx7sMHBsCQgW1Oal /h8g== 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:in-reply-to:references; bh=Isun0qOvFl5yGlh0uKDNBw1zhfxGw2RqA1bx4RtUflg=; b=erGeZEPfrogXs5iDJ5B2JVSzcLz/hSoa7nIqdok3Jj9xyHP3a7uLJIHvKpk1ZDB6kT fhAf7m4VSZF0GXTOR4aicnIkJ3a8Xo3NxBFEE6Dbdt9fldafua9u61LaDHHSKZsV8voo NUzq1QmeDGG0ACPUYdIJIOAst6jsSIha2QFKa/2BZx34TafwIBNxCdfIFUSa66taMqdS 7ojVt2LC5zIFWKPQ2sApRl5s3bNyImfd7ea7VSBDN5m27RGQnFsV6Ci7vWZklk6eIRX/ /0GTZLmItrItjLMHlNrjd+GRHmQlSzypkUYfEyAL+nH6ziNVi6p9UTCYsyzabM+A6Gk0 wLUg== X-Gm-Message-State: APjAAAXQxsefMNacKSV/sWkgdxZ/ZuBykJVHHnaQkVUDDYgkHE4/u4g1 CrCY2tQhzSP/li2eg05IVW4fMg== X-Received: by 2002:a62:e10f:: with SMTP id q15mr40671117pfh.34.1568186237110; Wed, 11 Sep 2019 00:17:17 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id k4sm3048323pfa.95.2019.09.11.00.17.16 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:17:16 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: devicetree@vger.kernel.org Subject: [PATCH v3 10/15] arm64: dts: msm8998: thermal: Add interrupt support Date: Wed, 11 Sep 2019 12:46:27 +0530 Message-Id: <9ebdef6e64db5840d69d9b2f66c5ecda274bbc0b.1568185732.git.amit.kucheria@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Register upper-lower interrupts for each of the two tsens controllers. Signed-off-by: Amit Kucheria --- arch/arm64/boot/dts/qcom/msm8998.dtsi | 82 ++++++++++++++------------- 1 file changed, 42 insertions(+), 40 deletions(-) -- 2.17.1 diff --git a/arch/arm64/boot/dts/qcom/msm8998.dtsi b/arch/arm64/boot/dts/qcom/msm8998.dtsi index c13ed7aeb1e0..1e2f77b38f2c 100644 --- a/arch/arm64/boot/dts/qcom/msm8998.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8998.dtsi @@ -440,8 +440,8 @@ thermal-zones { cpu0-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 1>; @@ -461,8 +461,8 @@ }; cpu1-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 2>; @@ -482,8 +482,8 @@ }; cpu2-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 3>; @@ -503,8 +503,8 @@ }; cpu3-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 4>; @@ -524,8 +524,8 @@ }; cpu4-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 7>; @@ -545,8 +545,8 @@ }; cpu5-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 8>; @@ -566,8 +566,8 @@ }; cpu6-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 9>; @@ -587,8 +587,8 @@ }; cpu7-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 10>; @@ -608,8 +608,8 @@ }; gpu-thermal-bottom { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 12>; @@ -623,8 +623,8 @@ }; gpu-thermal-top { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 13>; @@ -638,8 +638,8 @@ }; clust0-mhm-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 5>; @@ -653,8 +653,8 @@ }; clust1-mhm-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 6>; @@ -668,8 +668,8 @@ }; cluster1-l2-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens0 11>; @@ -683,8 +683,8 @@ }; modem-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens1 1>; @@ -698,8 +698,8 @@ }; mem-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens1 2>; @@ -713,8 +713,8 @@ }; wlan-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens1 3>; @@ -728,8 +728,8 @@ }; q6-dsp-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens1 4>; @@ -743,8 +743,8 @@ }; camera-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens1 5>; @@ -758,8 +758,8 @@ }; multimedia-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens1 6>; @@ -845,8 +845,9 @@ compatible = "qcom,msm8998-tsens", "qcom,tsens-v2"; reg = <0x10ab000 0x1000>, /* TM */ <0x10aa000 0x1000>; /* SROT */ - #qcom,sensors = <14>; + interrupts = ; + interrupt-names = "uplow"; #thermal-sensor-cells = <1>; }; @@ -854,8 +855,9 @@ compatible = "qcom,msm8998-tsens", "qcom,tsens-v2"; reg = <0x10ae000 0x1000>, /* TM */ <0x10ad000 0x1000>; /* SROT */ - #qcom,sensors = <8>; + interrupts = ; + interrupt-names = "uplow"; #thermal-sensor-cells = <1>; }; From patchwork Wed Sep 11 07:16:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173599 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374686ilq; Wed, 11 Sep 2019 00:17:25 -0700 (PDT) X-Google-Smtp-Source: APXvYqyelK+kXuywSULOoIr1wRyRuOqkPty/TCS9WjdriEIRSJRhCUrs2FrGz8SJ9W6dEu1ASxsb X-Received: by 2002:a50:ce53:: with SMTP id k19mr34920472edj.2.1568186245087; Wed, 11 Sep 2019 00:17:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186245; cv=none; d=google.com; s=arc-20160816; b=pGvMFZmK8UCMNdou+GOqytAvgjiRsCSyUqD1xN4qHsQSszEVnfRCssJoIrerV+jX8J AaAlccaD1s8iS0ssgYOXgR0lM9fWpo6bTIS+fzgt1zgGJVgCMXFV+gaqom6f1JMHJuU2 hfs65RLtG2e840RvLmlwDa7yeMSFLNfXhI5jx9a0EnNC9WfyRAqiv2UA/lw4gnxiHuEs ODgH63zL/a4Du/Ecby0K1f2HO56dzShTULx8lsGskeX1oxdvwFrIcexqFv+AnSJuh4Q6 xm5kYyKMBPgCKBWC5337gPgR4Vffg/SGz14MurNnzUE5HGBjJWlEFmnYd3JPs0h1ALhm NTuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=5TuJ7l2iIRIYYnmGHtrUFLK2P8yt4NpAavFl0VahGaY=; b=PEZ/1zF48ddkuJhsoOcI/Yxw1fK2VXaIl5uMVs8vts+2KC+D5z4m4gubI/8Jmmq+SS pQVnpsoJ+iBv/Sz1EnwR+KTC4CXuvubq4i+TIwrwkFLEaxXOWlTsshsoo/k6oWt3jf+O fmdM4UIZL7ivEgoXhT5+PtebwK6SLP0wZUHHh/H6bm7SzedBiOFUCg5iMAzxmPJF1iWd fjOeGn21Z33Jf6ZJ8NGRw+AQzGA1rbwo75pWS7kUmZzDsjFx4WOAsPxHArH7eWuXXwdG HqEjg0vMPSOiih5OE2PteYul75+MCqDwDddjBIAgM6fxRRoGzFKcVwVxfDLiv3pFeMoX +SWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PyKtk7de; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id p14si12808331eda.411.2019.09.11.00.17.24; Wed, 11 Sep 2019 00:17:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PyKtk7de; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1727248AbfIKHRV (ORCPT + 15 others); Wed, 11 Sep 2019 03:17:21 -0400 Received: from mail-pl1-f193.google.com ([209.85.214.193]:37061 "EHLO mail-pl1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727130AbfIKHRV (ORCPT ); Wed, 11 Sep 2019 03:17:21 -0400 Received: by mail-pl1-f193.google.com with SMTP id b10so9801709plr.4 for ; Wed, 11 Sep 2019 00:17:21 -0700 (PDT) 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 :in-reply-to:references; bh=5TuJ7l2iIRIYYnmGHtrUFLK2P8yt4NpAavFl0VahGaY=; b=PyKtk7de5zMYaWrjwmA4Z4W/TOdZ8yI884Mx5qmvGu1pQKoA3pALakGP9q+sinnB5V QUmIPdYJBTsxLKSDGN8Rw5wYysUXYXQ3G7IJNDFdejiilV2z33OMuUvzHy9r6Js8ZzAF 4XE9qnrvLZQLT0kVDv2phstvkgrGfnAKl30xf8eNUF3PZbJUcXQ4yQkTjE/XH/SzwsuY Tu+mh0IwNOEujR2a+ssZlEM0VVhvJT2puT+m80alLLrMslWj3ux63HlKObNJISSlO9e3 4uFodycMHq45FSILRkbZt2ZYK79Wbnj4Kine9aVejdaVM5W+sZKkBGFtEIyaAhPmLJGS xVQw== 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:in-reply-to:references; bh=5TuJ7l2iIRIYYnmGHtrUFLK2P8yt4NpAavFl0VahGaY=; b=B0wVS66dIi8EP3oa4W/xE1oMQk+KPZWuYzoxwhSvQ2DNXTeyqK+DN4zlNz6pDT4p+n x/Mh/gsXzCQ0cVOO1cv7ZG0oAXaO8KdVEgK/NylseoMAO5kV8at1+xOQTvC1ek7M6061 s8voEb6S3yWnGtGZ02PIAoXzRocO6VCmiut8SPOUk82lKjDE4u/ltIiryT50IEFahBkJ R2H4uM/loL22AlUPWkSiqex2ctuTveQ+FlF7A1ziZyS6jBhOfkQieVPTdNgzu81E29pn Qd0vP0HWDk2uj2bBneVh0VAGqgT3WzsTtwNIC1SPr2Po1odCzLJqe4hm4mSvX61edeRA aQ7Q== X-Gm-Message-State: APjAAAVKSOVpgiLpyqsdNGRXJfk7qEYi1DgZetZl2SkVwVcWt3XC8Far grLnDZQBmFQ6As+WVbhxQi8xbQ== X-Received: by 2002:a17:902:7596:: with SMTP id j22mr22859410pll.280.1568186240549; Wed, 11 Sep 2019 00:17:20 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id h12sm20705800pgr.8.2019.09.11.00.17.19 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:17:20 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: devicetree@vger.kernel.org Subject: [PATCH v3 11/15] arm64: dts: qcs404: thermal: Add interrupt support Date: Wed, 11 Sep 2019 12:46:28 +0530 Message-Id: X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Register upper-lower interrupt for the tsens controller. Signed-off-by: Amit Kucheria --- arch/arm64/boot/dts/qcom/qcs404.dtsi | 42 +++++++++++++++------------- 1 file changed, 22 insertions(+), 20 deletions(-) -- 2.17.1 diff --git a/arch/arm64/boot/dts/qcom/qcs404.dtsi b/arch/arm64/boot/dts/qcom/qcs404.dtsi index 3d0789775009..065a60d50a07 100644 --- a/arch/arm64/boot/dts/qcom/qcs404.dtsi +++ b/arch/arm64/boot/dts/qcom/qcs404.dtsi @@ -280,6 +280,8 @@ nvmem-cells = <&tsens_caldata>; nvmem-cell-names = "calib"; #qcom,sensors = <10>; + interrupts = ; + interrupt-names = "uplow"; #thermal-sensor-cells = <1>; }; @@ -1071,8 +1073,8 @@ thermal-zones { aoss-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 0>; @@ -1086,8 +1088,8 @@ }; q6-hvx-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 1>; @@ -1101,8 +1103,8 @@ }; lpass-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 2>; @@ -1116,8 +1118,8 @@ }; wlan-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 3>; @@ -1131,8 +1133,8 @@ }; cluster-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 4>; @@ -1165,8 +1167,8 @@ }; cpu0-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 5>; @@ -1199,8 +1201,8 @@ }; cpu1-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 6>; @@ -1233,8 +1235,8 @@ }; cpu2-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 7>; @@ -1267,8 +1269,8 @@ }; cpu3-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 8>; @@ -1301,8 +1303,8 @@ }; gpu-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 9>; From patchwork Wed Sep 11 07:16:29 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kucheria X-Patchwork-Id: 173600 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp374743ilq; Wed, 11 Sep 2019 00:17:29 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvqh8pJycqSQrX9c1sw4AJBAj8zDvHq/gq3KD7xrxr2nd6v7fqbA5mOSOEOiKoRH1AvARh X-Received: by 2002:aa7:c355:: with SMTP id j21mr34334114edr.210.1568186249132; Wed, 11 Sep 2019 00:17:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568186249; cv=none; d=google.com; s=arc-20160816; b=JIrytd5OD5rtoot3ypEGynJ+9hp7JplgUoed4wutrrKJa0DgMhoV+M3Lw8ArhRTXht Rlr7nd3yjCA2nowhmpBXY311t3X5BFdBTcHlvn/VX7aIeTc4/XFdXJ+N5GEKeZgivDOH RD0pYx2cawTRkybck8eNT2G0RAosE+AD2VoyX1nJz9vb/zrY5E4AiOJXqFtDnPrk+ye8 8I4tVaNO6lAxUm8n+VRZz0b3wRtr4qmSzjOfwYF2vBKILJsJUt5CX+VwW1brjmhRz2Jf uqZER50o7DZ/iRNcB3/ss/OssAtuBhPOyoTRRkQCTKB27IjcmgR1QOGVBSk03jj4xDca Lb+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=VrMMAxmAWCoF+Z0mK+KREcF/roJedPfia4jPAm5aT6w=; b=hWiknU/LgbcVH2Ncw+fkai5mWko9ycFGm8jJSPYKKeQj5AgqixFzCymWvSBW6Iisag v7LrGiwbA7YyVVNgNY1YL7ISFkW8+uRJDnXBdvd/vk8eGPam9nPdKI9hU2aKG7a26ieA iwgd0RekPCCVaAfd+QGgnHW/StjXrv4JsiifPce0EDsaTTgqoHm5zRr1ZQVbyXc7j0X5 I2fale3Rx+GSxT4YQ/0DY3nbxqiUVkzSXzTnFvPsdh1zmlFU1rWA/PqyprTgeEMnyK4c oO0dF6mLxKhV+eh2BIeuszadTgF5IVgykbaJUQ5l4e12DsQvtDm2nmwt8XYHQ1RdrvKP 0eOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=v+z7bmUE; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id ay26si11025390ejb.244.2019.09.11.00.17.28; Wed, 11 Sep 2019 00:17:29 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=v+z7bmUE; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 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 S1726889AbfIKHRZ (ORCPT + 15 others); Wed, 11 Sep 2019 03:17:25 -0400 Received: from mail-pf1-f194.google.com ([209.85.210.194]:43347 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727260AbfIKHRY (ORCPT ); Wed, 11 Sep 2019 03:17:24 -0400 Received: by mail-pf1-f194.google.com with SMTP id d15so13071463pfo.10 for ; Wed, 11 Sep 2019 00:17:24 -0700 (PDT) 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 :in-reply-to:references; bh=VrMMAxmAWCoF+Z0mK+KREcF/roJedPfia4jPAm5aT6w=; b=v+z7bmUEVGgVLbs+h47tvjcjMgAGwHIKfunE2271dciJlZKtk8SNzuvz3qUAZNzEfT 8ZnK9qEzhlC6QfbJr8c3LeIGgbGFkX6r58OoxXhO8jMdTeD9iWwrISs2FYO23HjHe/RU QceXow+wIojTbrW1Yj8JTaDTEQ97sl9W2hZE5mm/BlbmEzSE9ALLN0a0nWX8eBNXsYs6 yFHsY7zXzfB+xxHIM4iypJgU72m3OT6jqG3pmMYwBjf7GAlvKIQzSQBg/hNqtf9guBol FksEj6ZdqxPuVlG3JKzz6iw7ikNWiqZcwvwxFzkHUv0iFsoO/pUe7aq+OIq+whiAEpFC hmfg== 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:in-reply-to:references; bh=VrMMAxmAWCoF+Z0mK+KREcF/roJedPfia4jPAm5aT6w=; b=oizCgkU/BJluAkEwebBdqlzP3TMMiLPgwID7t1XHaueQAwMycrtY8X22AH9MHmElUg PV+Hu5pm8AYXqWRTe+JP3nW4HEg6faKhkkfcmSHvs7+2oFmE10EscYlOo32O0C/SFnI0 zYCLtY8O9EzgvXKSw9eDQkyLgrpe/AHsWdsEq35l7MwFZBdwS/ZhNo520jGXFWVrxy9v BeeMCRiFA6XBcoUMMul2kudcX8FHE8WuE0dOSYtTZdEpBxlQ4qGLlXO9d/+4M8p8ch6q VctRUcovOpKFSRhBoH749Kp+mTJy+zH/NnbjInZkvM3yjWz5KBM8x00LM4r63a8J72F6 PKHA== X-Gm-Message-State: APjAAAViVJs3R2NjKierdyrnc8fNtPQN/KBJP7MdqP5uo9qrJxOR88rq KcVIB0faPvZhF1HX9KFbo1KiwnszMVD+sA== X-Received: by 2002:a17:90a:1903:: with SMTP id 3mr3822034pjg.80.1568186243994; Wed, 11 Sep 2019 00:17:23 -0700 (PDT) Received: from localhost ([49.248.201.118]) by smtp.gmail.com with ESMTPSA id x24sm18955736pgl.84.2019.09.11.00.17.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Sep 2019 00:17:23 -0700 (PDT) From: Amit Kucheria To: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, edubezval@gmail.com, agross@kernel.org, masneyb@onstation.org, swboyd@chromium.org, Daniel Lezcano , Mark Rutland , Rob Herring , Zhang Rui Cc: devicetree@vger.kernel.org Subject: [PATCH v3 12/15] arm: dts: msm8974: thermal: Add interrupt support Date: Wed, 11 Sep 2019 12:46:29 +0530 Message-Id: <8d4fba37e8aa1a7511d22f5e53f78ab2e720d97a.1568185732.git.amit.kucheria@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Register upper-lower interrupt for the tsens controller. Signed-off-by: Amit Kucheria Tested-by: Brian Masney --- arch/arm/boot/dts/qcom-msm8974.dtsi | 36 +++++++++++++++-------------- 1 file changed, 19 insertions(+), 17 deletions(-) -- 2.17.1 diff --git a/arch/arm/boot/dts/qcom-msm8974.dtsi b/arch/arm/boot/dts/qcom-msm8974.dtsi index d32f639505f1..290f7c3827d4 100644 --- a/arch/arm/boot/dts/qcom-msm8974.dtsi +++ b/arch/arm/boot/dts/qcom-msm8974.dtsi @@ -139,8 +139,8 @@ thermal-zones { cpu-thermal0 { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 5>; @@ -159,8 +159,8 @@ }; cpu-thermal1 { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 6>; @@ -179,8 +179,8 @@ }; cpu-thermal2 { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 7>; @@ -199,8 +199,8 @@ }; cpu-thermal3 { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 8>; @@ -219,8 +219,8 @@ }; q6-dsp-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 1>; @@ -234,8 +234,8 @@ }; modemtx-thermal { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 2>; @@ -250,7 +250,7 @@ video-thermal { polling-delay-passive = <0>; - polling-delay = <1000>; + polling-delay = <0>; thermal-sensors = <&tsens 3>; @@ -279,8 +279,8 @@ }; gpu-thermal-top { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 9>; @@ -294,8 +294,8 @@ }; gpu-thermal-bottom { - polling-delay-passive = <250>; - polling-delay = <1000>; + polling-delay-passive = <0>; + polling-delay = <0>; thermal-sensors = <&tsens 10>; @@ -531,6 +531,8 @@ nvmem-cells = <&tsens_calib>, <&tsens_backup>; nvmem-cell-names = "calib", "calib_backup"; #qcom,sensors = <11>; + interrupts = ; + interrupt-names = "uplow"; #thermal-sensor-cells = <1>; };