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: <fd8729ab-85ba-4cbb-80f2-c5e188987d62@arm.com>
Date: Tue, 22 Oct 2024 23:25:23 +0100
From: Lukasz Luba <lukasz.luba@....com>
To: "Rafael J. Wysocki" <rafael@...nel.org>,
 "Rafael J. Wysocki" <rjw@...ysocki.net>
Cc: Linux PM <linux-pm@...r.kernel.org>, LKML <linux-kernel@...r.kernel.org>,
 Daniel Lezcano <daniel.lezcano@...aro.org>, Zhang Rui <rui.zhang@...el.com>,
 Srinivas Pandruvada <srinivas.pandruvada@...ux.intel.com>
Subject: Re: [PATCH v2 09/11] thermal: core: Add and use cooling device guard



On 10/14/24 13:26, Rafael J. Wysocki wrote:
> On Fri, Oct 11, 2024 at 12:22 AM Rafael J. Wysocki <rjw@...ysocki.net> wrote:
>>
>> From: Rafael J. Wysocki <rafael.j.wysocki@...el.com>
>>
>> Add and use a special guard for cooling devices.
>>
>> This allows quite a few error code paths to be simplified among
>> other things and brings in code size reduction for a good measure.
>>
>> No intentional functional impact.
>>
>> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>
>> ---
>>
>> This is a new iteration of
>>
>> https://lore.kernel.org/linux-pm/1890654.atdPhlSkOF@rjwysocki.net/
>>
>> v1 -> v2: Rearrange cur_state_store()
>>
>> ---
>>   drivers/thermal/gov_power_allocator.c |   21 +++++++--------
>>   drivers/thermal/gov_step_wise.c       |    6 ++--
>>   drivers/thermal/thermal_core.c        |   17 +++---------
>>   drivers/thermal/thermal_debugfs.c     |   25 +++++++++++-------
>>   drivers/thermal/thermal_helpers.c     |   19 +++-----------
>>   drivers/thermal/thermal_sysfs.c       |   45 ++++++++++++----------------------
>>   include/linux/thermal.h               |    3 ++
>>   7 files changed, 57 insertions(+), 79 deletions(-)
>>

[snip]

>>
>>          stats = cdev->stats;
>> -       if (!stats) {
>> -               len = -ENODATA;
>> -               goto unlock;
>> -       }
>> +       if (!stats)
>> +               return -ENODATA;
>>
>>          len += snprintf(buf + len, PAGE_SIZE - len, " From  :    To\n");
>>          len += snprintf(buf + len, PAGE_SIZE - len, "       : ");
> 
> There is one more "goto unlock" statement in this function that needs
> to be replaced with "return".
> 
> I'll send an update of it shortly.
> 

OK, I will review that when it's ready.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ