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-=wjMLb30d0WT_RyKBCX+JBkg3QQU6pCYkrV8f58Ya4Rgzw@mail.gmail.com>
Date:   Tue, 23 Aug 2022 16:18:34 -0700
From:   Linus Torvalds <torvalds@...ux-foundation.org>
To:     Bart Van Assche <bvanassche@....org>
Cc:     Rasmus Villemoes <linux@...musvillemoes.dk>,
        Steven Rostedt <rostedt@...dmis.org>,
        linux-kernel@...r.kernel.org, Ingo Molnar <mingo@...nel.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Christoph Hellwig <hch@....de>,
        Luc Van Oostenryck <luc.vanoostenryck@...il.com>,
        Jens Axboe <axboe@...nel.dk>
Subject: Re: [for-linus][PATCH 01/10] tracing: Suppress sparse warnings
 triggered by is_signed_type()

On Tue, Aug 23, 2022 at 3:05 PM Bart Van Assche <bvanassche@....org> wrote:
>
> Thank you Rasmus for having shared this information. Since sparse will
> have to be modified anyway, how about extending it such that the bitwise
> attribute can be removed from a type, e.g. via a new no_bitwise
> attribute?

I think it's actually easier to just make sparse happy.

Can you try the sparse version at

   git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/sparse.git

which I just set up temporarily with some patches of mine. It also
makes that '__cond_acquires' thing work that refcount_dec_and_lock()
uses.

It does require that kernel change to make

  #define is_signed_type(type)   (((type)(-1)) <= (type)0)

in both places, since only "no bits set" and "all bits set" are
special values for bitwise types.

Those patches of mine are fairly hacky, and I think Luc would probably
do it differently, but apart from the very last one, they aren't
actively disgusting.

                Linus

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ