linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 1/2] thermal: qcom-spmi-temp-alarm: Don't suppress negative temp
@ 2020-07-29 16:52 Guru Das Srinagesh
  2020-07-29 16:52 ` [PATCH v2 2/2] thermal: qcom-spmi-temp-alarm: add support for GEN2 rev 1 PMIC peripherals Guru Das Srinagesh
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Guru Das Srinagesh @ 2020-07-29 16:52 UTC (permalink / raw)
  To: Amit Kucheria, Stephen Boyd, linux-pm, linux-arm-msm
  Cc: Subbaraman Narayanamurthy, David Collins, linux-kernel,
	Veera Vegivada, Guru Das Srinagesh

From: Veera Vegivada <vvegivad@codeaurora.org>

Currently driver is suppressing the negative temperature
readings from the vadc. Consumers of the thermal zones need
to read the negative temperature too. Don't suppress the
readings.

Fixes: c610afaa21d3c6e ("thermal: Add QPNP PMIC temperature alarm driver")
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
Signed-off-by: Guru Das Srinagesh <gurus@codeaurora.org>
---
 drivers/thermal/qcom/qcom-spmi-temp-alarm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/thermal/qcom/qcom-spmi-temp-alarm.c b/drivers/thermal/qcom/qcom-spmi-temp-alarm.c
index bf7bae4..6dc879f 100644
--- a/drivers/thermal/qcom/qcom-spmi-temp-alarm.c
+++ b/drivers/thermal/qcom/qcom-spmi-temp-alarm.c
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0-only
 /*
- * Copyright (c) 2011-2015, 2017, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2011-2015, 2017, 2020, The Linux Foundation. All rights reserved.
  */
 
 #include <linux/bitops.h>
@@ -191,7 +191,7 @@ static int qpnp_tm_get_temp(void *data, int *temp)
 		chip->temp = mili_celsius;
 	}
 
-	*temp = chip->temp < 0 ? 0 : chip->temp;
+	*temp = chip->temp;
 
 	return 0;
 }
-- 
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-03-30 18:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-29 16:52 [PATCH v2 1/2] thermal: qcom-spmi-temp-alarm: Don't suppress negative temp Guru Das Srinagesh
2020-07-29 16:52 ` [PATCH v2 2/2] thermal: qcom-spmi-temp-alarm: add support for GEN2 rev 1 PMIC peripherals Guru Das Srinagesh
2020-08-05  6:48   ` Stephen Boyd
2021-03-30 17:49     ` Guru Das Srinagesh
2021-03-30 18:00       ` Daniel Lezcano
2020-08-05  6:48 ` [PATCH v2 1/2] thermal: qcom-spmi-temp-alarm: Don't suppress negative temp Stephen Boyd
2020-08-24  7:15 ` Daniel Lezcano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).