[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 4 Apr 2013 11:25:50 -0500
From: Linas Vepstas <linasvepstas@...il.com>
To: Richard Kuo <rkuo@...eaurora.org>
Cc: linux-arch@...r.kernel.org, linux-hexagon@...r.kernel.org,
linux-kernel@...r.kernel.org, viro@...iv.linux.org.uk
Subject: Re: [PATCH 4/6] Hexagon: check to if we will overflow the signal stack
On 3 April 2013 19:02, Richard Kuo <rkuo@...eaurora.org> wrote:
> + /* check if we would overflow the alt stack */
> + if (on_sig_stack(sp) && !likely(on_sig_stack(sp - frame_size)))
> + return (void __user __force *)-1UL;
I found the !likely construction confusing, as its doing both a
'unlikely' (right?) and inverting the argument. It seems clearer,
to idiots like me, to write this as:
if (on_sig_stack(sp) && unlikely(!on_sig_stack(sp - frame_size)))
since where checking for overflow, and its unlikely that the overflow happened.
-- Linas
--
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