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: <496223C4.20307@gmail.com>
Date:	Mon, 05 Jan 2009 16:14:12 +0100
From:	Jiri Slaby <jirislaby@...il.com>
To:	Cyrill Gorcunov <gorcunov@...il.com>
CC:	Andi Kleen <andi@...stfloor.org>,
	Johannes Weiner <hannes@...xchg.org>,
	Robert Hancock <hancockr@...w.ca>,
	linux-kernel@...r.kernel.org, david@...g.hm,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: early exception error

On 01/05/2009 04:01 PM, Cyrill Gorcunov wrote:
> [Jiri Slaby - Mon, Jan 05, 2009 at 03:51:26PM +0100]
> | On 01/05/2009 02:08 PM, Andi Kleen wrote:
> | > +#define EARLY_BUG_ON(x) do { if (unlikely(!(x))) EARLY_BUG(); } while (0)
> | 
> | I think unintentionally inverted logic.
> 
> just second ! is missed :)

None is needed, two '!' are added in the macro itself while it passes the
parameter to the builtin.

> | 
> | > +#define EARLY_BUG_ON(x) do {} while(0)
> | 
> | Shouldn't be x referenced here?
> |
> 
> but for what?

I know, core devs are sane, but e.g. for reasons such as

{'a' is used here already}
EARLY_BUG_ON(!(a = readl(...)))
{use 'a' again}

to stay on the safe side.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ