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: <664613c5-eee7-4130-8b21-0e47e7024636@kernel.org>
Date: Sat, 20 Dec 2025 11:53:29 +0100
From: Vincent Mailhol <mailhol@...nel.org>
To: David Laight <david.laight.linux@...il.com>
Cc: Nathan Chancellor <nathan@...nel.org>, Nicolas Schier <nsc@...nel.org>,
 Nick Desaulniers <nick.desaulniers+lkml@...il.com>,
 Bill Wendling <morbo@...gle.com>, Justin Stitt <justinstitt@...gle.com>,
 Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>,
 Maxime Ripard <mripard@...nel.org>, Thomas Zimmermann <tzimmermann@...e.de>,
 David Airlie <airlied@...il.com>, Simona Vetter <simona@...ll.ch>,
 Chris Mason <clm@...com>, David Sterba <dsterba@...e.com>,
 Kees Cook <kees@...nel.org>, "Gustavo A. R. Silva" <gustavoars@...nel.org>,
 Linus Torvalds <torvalds@...ux-foundation.org>,
 linux-kbuild@...r.kernel.org, linux-sparse@...r.kernel.org,
 linux-kernel@...r.kernel.org, llvm@...ts.linux.dev,
 dri-devel@...ts.freedesktop.org, linux-btrfs@...r.kernel.org,
 linux-hardening@...r.kernel.org
Subject: Re: [PATCH v2 4/4] minmax: remove useless cast in __is_nonneg()

On 20/12/2025 at 11:02, David Laight wrote:
> On Fri, 19 Dec 2025 23:39:48 +0100
> Vincent Mailhol <mailhol@...nel.org> wrote:
> 
>> The function like macro __is_nonneg() casts its argument to (long long)
>> in an attempt to silence -Wtype-limits warnings on unsigned values.
> 
> nak.
> 
> The cast is needed for pointer types, not for -Wtype-limits.
> which is why the '#if __SIZEOF_POINTER__ == __SIZEOF_LONG_LONG__'
> test is there.

OK. I will remove that fourth patch in v3.


Yours sincerely,
Vincent Mailhol


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ