[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180601174553.GB23669@mailbox.org>
Date: Fri, 1 Jun 2018 19:45:53 +0200
From: Christian Brauner <christian@...uner.io>
To: Oleg Nesterov <oleg@...hat.com>
Cc: linux-kernel@...r.kernel.org, ebiederm@...ssion.com,
gregkh@...uxfoundation.org, mingo@...nel.org,
james.morris@...rosoft.com, keescook@...omium.org,
peterz@...radead.org, sds@...ho.nsa.gov, viro@...iv.linux.org.uk,
akpm@...ux-foundation.org
Subject: Re: [PATCH v2 10/17] signal: make has_pending_signals() return bool
On Fri, Jun 01, 2018 at 06:16:58PM +0200, Oleg Nesterov wrote:
> On 06/01, Christian Brauner wrote:
> >
> > has_pending_signals() already behaves like a boolean function. Let's
> > actually declare it as such too.
>
> But this patch does more.
>
> > - case 4: ready = signal->sig[3] &~ blocked->sig[3];
> > - ready |= signal->sig[2] &~ blocked->sig[2];
> > - ready |= signal->sig[1] &~ blocked->sig[1];
> > - ready |= signal->sig[0] &~ blocked->sig[0];
> > + case 4:
> > + ready = signal->sig[3] & ~blocked->sig[3];
> > + ready |= signal->sig[2] & ~blocked->sig[2];
> > + ready |= signal->sig[1] & ~blocked->sig[1];
> > + ready |= signal->sig[0] & ~blocked->sig[0];
> > break;
>
> Again, personally I do not care at all. But why do you think the code looks
> better after re-formatting? This is subjective, but to me it does not.
>
> In particular, note the extra space before "=" removed by this patch. I guess
> it was added on purpose, and to me
>
> ready = signal->sig[3] &~ blocked->sig[3];
> ready |= signal->sig[2] &~ blocked->sig[2];
>
> actually looks better thab
>
> ready = signal->sig[3] &~ blocked->sig[3];
> ready |= signal->sig[2] &~ blocked->sig[2];
>
> after your patch.
I can drop the changes in v3.
Thanks!
Christian
>
> Oleg.
>
Powered by blists - more mailing lists