[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20240605201049.94826-1-trintaeoitogc@gmail.com>
Date: Wed, 5 Jun 2024 17:10:48 -0300
From: Guilherme Giacomo Simoes <trintaeoitogc@...il.com>
To: miriam.rachel.korenblit@...el.com,
kvalo@...nel.org,
rafael.j.wysocki@...el.com,
daniel.lezcano@...aro.org,
johannes.berg@...el.com,
dmantipov@...dex.ru
Cc: Guilherme Giacomo Simoes <trintaeoitogc@...il.com>,
linux-wireless@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH v4] iwlwifi: mvm: adding check if the thermal firmware is running
In the dmesg is showing the message "failed to read out thermal zone"
as if the temperature read is failed by don't find the thermal zone.
After researching and debugging, I see that this specific error is
occurrenced because the thermal try read the temperature when is started,
but the firmware is not running yet.
For more legibiliti i change the tt.c for return EAGAIN when this was occurrence.
After this change, in my computer I compile and install kernel in /boot
and in my dmesg the message "failed to read out thermal zone" is not show
any more.
I would like to thanks for Rafael Wysocki <refael.j.wysocki@...el.com> ,
Kalle Valo <kvalo@...nel.org> and Johannes Berg <johannes@...solutions.net>
for your suggestions in my previous patch.
Signed-off-by: Guilherme Giacomo Simoes <trintaeoitogc@...il.com>
---
drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/tt.c b/drivers/net/wireless/intel/iwlwifi/mvm/tt.c
index 8083c4b2ab6b..d1dd334b5049 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/tt.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/tt.c
@@ -620,8 +620,12 @@ static int iwl_mvm_tzone_get_temp(struct thermal_zone_device *device,
mutex_lock(&mvm->mutex);
- if (!iwl_mvm_firmware_running(mvm) ||
- mvm->fwrt.cur_fw_img != IWL_UCODE_REGULAR) {
+ if (!iwl_mvm_firmware_running(mvm)) {
+ ret = -EAGAIN;
+ goto out;
+ }
+
+ if (mvm->fwrt.cur_fw_img != IWL_UCODE_REGULAR) {
ret = -ENODATA;
goto out;
}
--
2.45.2
Powered by blists - more mailing lists