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: <CAHk-=wghAQs4eAeR7fnUwUUBUq6J_1UpQ5EWjyTW4L-JJ6LjEg@mail.gmail.com>
Date: Fri, 15 Nov 2024 13:57:04 -0800
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Philipp Reisner <philipp.reisner@...bit.com>
Cc: Kees Cook <keescook@...omium.org>, Luc Van Oostenryck <luc.vanoostenryck@...il.com>, 
	linux-sparse@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] compiler.h: Fix undefined BUILD_BUG_ON_ZERO()

On Fri, 15 Nov 2024 at 12:46, Philipp Reisner
<philipp.reisner@...bit.com> wrote:
>
> Fix that by defining __BUILD_BUG_ON_ZERO_MSG() in <linux/compiler.h>
> and using that for __must_be_array() and __must_be_cstr().

Ack, that cast to 'int' seems good too, to make sure the
__BUILD_BUG_ON_ZERO_MSG() test doesn't unintentionally change the type
of the expression it is in.

I do wonder if we actually need that "#ifdef __CHECKER__"? I think
sparse is perfectly fine with a _Static_assert(). Or does the checking
cause some other issues?

            Linus

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ