[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHdPZaNbMA+0FsiArG2WdO-izrV44hQZo6ibTwZcHgeftGNPpQ@mail.gmail.com>
Date: Sat, 23 Jun 2012 23:59:57 +0530
From: "devendra.aaru" <devendra.aaru@...il.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: "Justin P. Mattock" <justinmattock@...il.com>,
devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH V2 1/3] staging/rtl8192u: fix coding style problems
On Thu, Jun 21, 2012 at 4:38 AM, Greg Kroah-Hartman
<gregkh@...uxfoundation.org> wrote:
> On Wed, Jun 20, 2012 at 12:35:42AM +0530, Devendra Naga wrote:
>> - bit=(read_nic_byte_E(dev, EPROM_CMD) & (1<<EPROM_R_SHIFT) );
>> + bit = (read_nic_byte_E(dev, EPROM_CMD) & (1<<EPROM_R_SHIFT));
>> udelay(EPROM_DELAY);
>>
>> - if(bit) return 1;
>> - return 0;
>> + return !!bit;
>
> Oh come on, really? !! is more "clear" here?
>
It looks ok to me,
> No, please be painfully obvious, that's the only way to write kernel
> code. Not like this.
>
Ok, so no !!'s ? and just that if (bit) thingy?
> greg k-h
--
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