[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <201211292316.55305.PeterHuewe@gmx.de>
Date: Thu, 29 Nov 2012 23:16:55 +0100
From: Peter Hüwe <PeterHuewe@....de>
To: Kent Yoder <key@...ux.vnet.ibm.com>
Cc: Joe Perches <joe@...ches.com>, Rajiv Andrade <mail@...jiv.net>,
Marcel Selhorst <tpmdd@...horst.net>,
Sirrix AG <tpmdd@...rix.com>,
tpmdd-devel@...ts.sourceforge.net, linux-kernel@...r.kernel.org,
Al Viro <viro@...iv.linux.org.uk>
Subject: Re: [PATCH v3] char/tpm: Use true and false for bools
Am Donnerstag, 29. November 2012, 23:08:11 schrieb Kent Yoder:
> On Thu, Nov 29, 2012 at 01:54:52PM -0800, Joe Perches wrote:
> > >
> > > - itpm = (probe == 0) ? 0 : 1;
> > > + itpm = !!probe;
> >
> > Even more trivia:
> >
> > This !! isn't necessary as ints assigned to bool are converted
> > by the compiler to 0 or 1.
>
> Good to know, thanks Joe!
So v2 is fine.
Peter
--
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