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: <d1eaa5606177087682d822c7d7b35c1079ea2e9a.camel@intel.com>
Date:   Tue, 24 Jan 2023 06:38:17 +0000
From:   "Zhang, Rui" <rui.zhang@...el.com>
To:     "rafael@...nel.org" <rafael@...nel.org>,
        "daniel.lezcano@...aro.org" <daniel.lezcano@...aro.org>
CC:     "linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "amitk@...nel.org" <amitk@...nel.org>
Subject: Re: [PATCH v2 2/3] thermal/core: Remove unneeded ida_destroy()

On Mon, 2023-01-23 at 16:27 +0100, Daniel Lezcano wrote:
> As per documentation for the ida_destroy() function: "If the IDA is
> already empty, there is no need to call this function."
> 
> The thermal framework is in the init sequence, so the ida was not yet
> used and consequently it is empty in case of error.
> 
> There is no need to call ida_destroy(), let's remove the calls.
> 
> Signed-off-by: Daniel Lezcano <daniel.lezcano@...aro.org>

Reviewed-by: Zhang Rui <rui.zhang@...el.com>

thanks,
rui
> ---
>  drivers/thermal/thermal_core.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/thermal/thermal_core.c
> b/drivers/thermal/thermal_core.c
> index fddafcee5e6f..fad0c4a07d16 100644
> --- a/drivers/thermal/thermal_core.c
> +++ b/drivers/thermal/thermal_core.c
> @@ -1624,8 +1624,6 @@ static int __init thermal_init(void)
>  unregister_netlink:
>  	thermal_netlink_exit();
>  error:
> -	ida_destroy(&thermal_tz_ida);
> -	ida_destroy(&thermal_cdev_ida);
>  	mutex_destroy(&thermal_list_lock);
>  	mutex_destroy(&thermal_governor_lock);
>  	return result;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ