lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <00555ae56b4193f47d32550440829d1c542534f6.camel@sipsolutions.net>
Date: Wed, 05 Jun 2024 20:39:39 +0200
From: Johannes Berg <johannes@...solutions.net>
To: Guilherme Giacomo Simoes <trintaeoitogc@...il.com>, 
 miriam.rachel.korenblit@...el.com, kvalo@...nel.org,
 rafael.j.wysocki@...el.com,  daniel.lezcano@...aro.org, dmantipov@...dex.ru
Cc: linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [RESEND PATCH v2] iwlwifi: mvm: adding check if the thermal
 firmware is running

On Wed, 2024-06-05 at 15:37 -0300, Guilherme Giacomo Simoes wrote:
> 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> and
> Kalle Valo <kvalo@...nel.org> for your suggestions in my first patch.
> 
> Signed-off-by: Guilherme Giacomo Simoes <trintaeoitogc@...il.com>
> ---
>  drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 10 ++++++++--
>  1 file changed, 8 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..68ab9966330c 100644
> --- a/drivers/net/wireless/intel/iwlwifi/mvm/tt.c
> +++ b/drivers/net/wireless/intel/iwlwifi/mvm/tt.c
> @@ -620,8 +620,14 @@ 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) {
> +	const int res = iwl_mvm_firmware_running(mvm);

const is useless, but you should not have variable declarations in the
middle of the function (per kernel convention)

johannes


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ