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] [day] [month] [year] [list]
Message-ID: <7abab768-359e-4067-9587-6ca6caabc7f9@portwell.com.tw>
Date: Tue, 29 Apr 2025 10:03:04 +0800
From: jesse huang <jesse.huang@...twell.com.tw>
To: Linus Walleij <linus.walleij@...aro.org>
Cc: hdegoede@...hat.com, ilpo.jarvinen@...ux.intel.com, brgl@...ev.pl,
 wim@...ux-watchdog.org, linux@...ck-us.net, linux-kernel@...r.kernel.org,
 platform-driver-x86@...r.kernel.org, linux-gpio@...r.kernel.org,
 linux-watchdog@...r.kernel.org, jay.chen@...onical.com
Subject: Re: [PATCH v5] platform/x86: portwell-ec: Add GPIO and WDT driver for
 Portwell EC

Hi Linus,

Thank you for your review and for the Reviewed-by tag.

I will use BIT macro in v6.

Best regards,
Yen-Chi Huang

On 23/04/2025 4:38 pm, Linus Walleij wrote:
(...)

>> +static int pwec_gpio_get(struct gpio_chip *chip, unsigned int offset)
>> +{
>> +       return (pwec_read(PORTWELL_GPIO_VAL_REG) & (1 << offset)) ? 1 : 0;
> I would use BIT(offset) instead of open-coding (1 << offset) in all of these
> instances.
> 
> The main reason we use it is that the BIT() macro hardwires U (unsigned)
> to the parameter so no mistakes can be made (even if you have
> no mistakes here obviously, it's a good habit).
> 
> Either way this is not a big deal so:
> Reviewed-by: Linus Walleij <linus.walleij@...aro.org>
> 
> Yours,
> Linus Walleij
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ