[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-id: <1539791563-5959-8-git-send-email-b.zolnierkie@samsung.com>
Date: Wed, 17 Oct 2018 17:52:33 +0200
From: Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>
To: Zhang Rui <rui.zhang@...el.com>,
Eduardo Valentin <edubezval@...il.com>
Cc: Amit kucheria <amit.kucheria@...aro.org>,
Eric Anholt <eric@...olt.net>,
Stefan Wahren <stefan.wahren@...e.com>,
Markus Mayer <mmayer@...adcom.com>,
bcm-kernel-feedback-list@...adcom.com,
Heiko Stuebner <heiko@...ech.de>,
Thierry Reding <thierry.reding@...il.com>,
Jonathan Hunter <jonathanh@...dia.com>,
Keerthy <j-keerthy@...com>,
Masahiro Yamada <yamada.masahiro@...ionext.com>,
Jun Nie <jun.nie@...aro.org>,
Baoyou Xie <baoyou.xie@...aro.org>,
Shawn Guo <shawnguo@...nel.org>, linux-pm@...r.kernel.org,
linux-kernel@...r.kernel.org, b.zolnierkie@...sung.com
Subject: [PATCH v2 07/17] thermal: hisi_thermal: enable+check sensor after
its setup is finished
* Enable+check sensor after checking ntrips and doing chipset specific
enable operation.
* Remove superfluous second sensor enable+check attempt.
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>
---
drivers/thermal/hisi_thermal.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/thermal/hisi_thermal.c b/drivers/thermal/hisi_thermal.c
index cc4e2ca..370696c 100644
--- a/drivers/thermal/hisi_thermal.c
+++ b/drivers/thermal/hisi_thermal.c
@@ -488,9 +488,6 @@ static int hisi_thermal_register_sensor(struct platform_device *pdev,
return ret;
}
- thermal_zone_set_mode(sensor->tzd, THERMAL_DEVICE_ENABLED);
- thermal_zone_device_check(sensor->tzd);
-
trip = of_thermal_get_trip_points(sensor->tzd);
for (i = 0; i < of_thermal_get_ntrips(sensor->tzd); i++) {
@@ -553,6 +550,9 @@ static int hisi_thermal_probe(struct platform_device *pdev)
return ret;
}
+ thermal_zone_set_mode((&data->sensor)->tzd, THERMAL_DEVICE_ENABLED);
+ thermal_zone_device_check((&data->sensor)->tzd);
+
if (data->irq) {
ret = devm_request_threaded_irq(dev, data->irq, NULL,
hisi_thermal_alarm_irq_thread,
@@ -563,9 +563,6 @@ static int hisi_thermal_probe(struct platform_device *pdev)
}
}
- thermal_zone_set_mode((&data->sensor)->tzd, THERMAL_DEVICE_ENABLED);
- thermal_zone_device_check((&data->sensor)->tzd);
-
return 0;
}
--
1.9.1
Powered by blists - more mailing lists