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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <29bd1baf-f1cb-4c74-9d31-051c2b8efae6@linaro.org>
Date: Wed, 15 Jan 2025 09:10:08 +0100
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Stanislav Jakubek <stano.jakubek@...il.com>
Cc: Michael Turquette <mturquette@...libre.com>,
 Stephen Boyd <sboyd@...nel.org>,
 Florian Fainelli <florian.fainelli@...adcom.com>, Ray Jui
 <rjui@...adcom.com>, Scott Branden <sbranden@...adcom.com>,
 Broadcom internal kernel review list
 <bcm-kernel-feedback-list@...adcom.com>,
 Linus Walleij <linus.walleij@...aro.org>,
 Bjorn Andersson <andersson@...nel.org>, linux-clk@...r.kernel.org,
 linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
 linux-arm-msm@...r.kernel.org
Subject: Re: [PATCH v2] clk: Use str_enable_disable-like helpers

On 15/01/2025 08:21, Stanislav Jakubek wrote:
> Hi Krzysztof, 1 note below.
> 
> On Tue, Jan 14, 2025 at 08:06:12PM +0100, Krzysztof Kozlowski wrote:
>> Replace ternary (condition ? "enable" : "disable") syntax with helpers
>> from string_choices.h because:
> 
> [snip]
> 
>> diff --git a/drivers/clk/clk-nomadik.c b/drivers/clk/clk-nomadik.c
>> index 06245681dac7..f3a73ac5a1b9 100644
>> --- a/drivers/clk/clk-nomadik.c
>> +++ b/drivers/clk/clk-nomadik.c
>> @@ -17,6 +17,7 @@
>>  #include <linux/debugfs.h>
>>  #include <linux/seq_file.h>
>>  #include <linux/spinlock.h>
>> +#include <linux/string_choices.h>
>>  #include <linux/reboot.h>
>>  
>>  /*
>> @@ -116,9 +117,9 @@ static void __init nomadik_src_init(void)
>>  
>>  	val = readl(src_base + SRC_XTALCR);
>>  	pr_info("SXTALO is %s\n",
>> -		(val & SRC_XTALCR_SXTALDIS) ? "disabled" : "enabled");
>> +		str_enabled_disabled(val & SRC_XTALCR_SXTALDIS));
> 
> It seems like you flipped the logic here. Was this intentional?
No, overlook. Thanks for noticing.

Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ