From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: rafael@kernel.org, daniel.lezcano@linaro.org
Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
"Amit Kucheria" <amitk@kernel.org>,
"Zhang Rui" <rui.zhang@intel.com>,
"Thierry Reding" <thierry.reding@gmail.com>,
"Jonathan Hunter" <jonathanh@nvidia.com>,
"Niklas Söderlund" <niklas.soderlund+renesas@ragnatech.se>,
"Gregory Greenman" <gregory.greenman@intel.com>,
"Martin Blumenstingl" <martin.blumenstingl@googlemail.com>,
"Balsam CHIHI" <bchihi@baylibre.com>,
linux-tegra@vger.kernel.org (open list:TEGRA ARCHITECTURE
SUPPORT)
Subject: [PATCH v2 13/16] thermal/tegra: Do not enable the thermal zone, it is already enabled
Date: Tue, 21 Feb 2023 19:07:07 +0100 [thread overview]
Message-ID: <20230221180710.2781027-14-daniel.lezcano@linaro.org> (raw)
In-Reply-To: <20230221180710.2781027-1-daniel.lezcano@linaro.org>
The code enables the thermal zone after setting it up. But the thermal
zone is already enabled by thermal_of_zone_register() function.
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
---
drivers/thermal/tegra/tegra30-tsensor.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/thermal/tegra/tegra30-tsensor.c b/drivers/thermal/tegra/tegra30-tsensor.c
index 3506c3f3c474..e38902abf207 100644
--- a/drivers/thermal/tegra/tegra30-tsensor.c
+++ b/drivers/thermal/tegra/tegra30-tsensor.c
@@ -346,7 +346,7 @@ static int tegra_tsensor_enable_hw_channel(const struct tegra_tsensor *ts,
{
const struct tegra_tsensor_channel *tsc = &ts->ch[id];
struct thermal_zone_device *tzd = tsc->tzd;
- int err, hot_trip = 0, crit_trip = 0;
+ int hot_trip = 0, crit_trip = 0;
u32 val;
if (!tzd) {
@@ -401,12 +401,6 @@ static int tegra_tsensor_enable_hw_channel(const struct tegra_tsensor *ts,
val |= FIELD_PREP(TSENSOR_SENSOR0_CONFIG0_INTR_THERMAL_RST_EN, 1);
writel_relaxed(val, tsc->regs + TSENSOR_SENSOR0_CONFIG0);
- err = thermal_zone_device_enable(tzd);
- if (err) {
- dev_err(ts->dev, "ch%u: failed to enable zone: %d\n", id, err);
- return err;
- }
-
return 0;
}
--
2.34.1
next prev parent reply other threads:[~2023-02-21 18:10 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-21 18:06 [PATCH v2 00/17] Self-encapsulate the thermal zone device structure Daniel Lezcano
2023-02-21 18:06 ` [PATCH v2 01/16] thermal/core: Add a thermal zone 'devdata' accessor Daniel Lezcano
2023-02-21 18:20 ` Jernej Škrabec
2023-02-22 19:19 ` Rafael J. Wysocki
2023-02-22 19:20 ` Florian Fainelli
2023-02-21 18:06 ` [PATCH v2 02/16] thermal/core: Show a debug message when get_temp() fails Daniel Lezcano
2023-02-22 19:25 ` Rafael J. Wysocki
2023-02-21 18:06 ` [PATCH v2 03/16] thermal: Remove debug or error messages in get_temp() ops Daniel Lezcano
2023-02-22 19:23 ` Florian Fainelli
2023-02-21 18:06 ` [PATCH v2 04/16] thermal/hwmon: Do not set no_hwmon before calling thermal_add_hwmon_sysfs() Daniel Lezcano
2023-02-22 19:23 ` Florian Fainelli
2023-02-21 18:06 ` [PATCH v2 05/16] thermal/hwmon: Use the right device for devm_thermal_add_hwmon_sysfs() Daniel Lezcano
2023-02-21 18:22 ` Jernej Škrabec
2023-02-22 9:31 ` AngeloGioacchino Del Regno
2023-02-21 18:07 ` [PATCH v2 06/16] thermal: Don't use 'device' internal thermal zone structure field Daniel Lezcano
2023-02-22 9:31 ` AngeloGioacchino Del Regno
2023-02-22 19:43 ` Rafael J. Wysocki
2023-02-22 20:00 ` Daniel Lezcano
2023-02-22 20:06 ` Rafael J. Wysocki
2023-02-23 9:56 ` Daniel Lezcano
2023-02-23 11:43 ` Rafael J. Wysocki
2023-02-23 14:35 ` Daniel Lezcano
2023-02-21 18:07 ` [PATCH v2 07/16] thermal/drivers/spear: Don't use tz->device but pdev->dev Daniel Lezcano
2023-02-21 18:07 ` [PATCH v2 08/16] thermal: Add a thermal zone id accessor Daniel Lezcano
2023-02-22 19:45 ` Rafael J. Wysocki
2023-02-21 18:07 ` [PATCH v2 09/16] thermal: Do not access 'type' field, use the tz id instead Daniel Lezcano
2023-02-22 9:31 ` AngeloGioacchino Del Regno
2023-02-22 19:47 ` Rafael J. Wysocki
2023-02-21 18:07 ` [PATCH v2 10/16] thermal/drivers/da9062: Don't access the thermal zone device fields Daniel Lezcano
2023-02-21 18:07 ` [PATCH v2 11/16] thermal/hwmon: Use the thermal_core.h header Daniel Lezcano
2023-02-21 18:37 ` Guenter Roeck
2023-02-21 18:07 ` [PATCH v2 12/16] thermal/drivers/tegra: Remove unneeded lock when setting a trip point Daniel Lezcano
2023-02-21 18:07 ` Daniel Lezcano [this message]
2023-02-21 18:07 ` [PATCH v2 14/16] thermal/drivers/acerhdf: Make interval setting only at module load time Daniel Lezcano
2023-02-21 20:07 ` Hans de Goede
2023-02-21 18:07 ` [PATCH v2 15/16] thermal/drivers/acerhdf: Remove pointless governor test Daniel Lezcano
2023-02-21 20:07 ` Hans de Goede
2023-02-21 18:07 ` [PATCH v2 16/16] thermal/traces: Replace the thermal zone structure parameter with the field value Daniel Lezcano
2023-02-22 19:51 ` Rafael J. Wysocki
2023-02-22 20:02 ` Daniel Lezcano
2023-02-22 20:07 ` Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230221180710.2781027-14-daniel.lezcano@linaro.org \
--to=daniel.lezcano@linaro.org \
--cc=amitk@kernel.org \
--cc=bchihi@baylibre.com \
--cc=gregory.greenman@intel.com \
--cc=jonathanh@nvidia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=martin.blumenstingl@googlemail.com \
--cc=niklas.soderlund+renesas@ragnatech.se \
--cc=rafael@kernel.org \
--cc=rui.zhang@intel.com \
--cc=thierry.reding@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox