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]
Date:   Sat, 28 Mar 2020 12:22:11 +0100
From:   Thomas Gleixner <tglx@...utronix.de>
To:     Jules Irenge <jbi.octave@...il.com>, julia.lawall@...6.fr
Cc:     boqun.feng@...il.com, Armijn Hemel <armijn@...ldur.nl>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Muchun Song <smuchun@...il.com>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 05/10] softirq: Replace BUG() after if statement with BUG_ON

Jules,

Jules Irenge <jbi.octave@...il.com> writes:
> Coccinelle reports a warning tasklet_action_common()
>
> WARNING: Use BUG_ON instead of if condition followed by BUG
>
> To fix this, BUG() is replaced by BUG_ON() with the recommended
> suggestion

Well, the suggestion is wrong to begin with. The suggestion should be:

      Is this BUG() actually necessary and is this the only way to deal
      with this problem?

Only if that question can be answered with yes, then the recommended
replacement is ok.

BUG() is the last resort and each and every instance wants to be looked
at and not mechanically changed to some 'better' version of it.

Thanks,

        tglx

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ