From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753947AbbGXNG2 (ORCPT ); Fri, 24 Jul 2015 09:06:28 -0400 Received: from mail-yk0-f176.google.com ([209.85.160.176]:35186 "EHLO mail-yk0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752563AbbGXNG0 (ORCPT ); Fri, 24 Jul 2015 09:06:26 -0400 From: Joshua Clayton To: Dan Carpenter Cc: Larry Finger , Florian Schilhabel , Greg Kroah-Hartman , devel@driverdev.osuosl.org, Tapasweni Pathak , Vaishali Thakkar , Nitin Kuppelur , linux-kernel@vger.kernel.org, Sudip Mukherjee Subject: Re: [PATCH 5/5] staging: rtl8712: style fix: Date: Fri, 24 Jul 2015 06:06:21 -0700 Message-ID: <11148480.vLBgj4Zjpg@diplodocus> User-Agent: KMail/4.14.10 (Linux/4.2.0-rc3-next-20150722-00005-gf1d4451; KDE/4.14.10; x86_64; ; ) In-Reply-To: <20150724105227.GW5371@mwanda> References: <1437712717-7287-1-git-send-email-stillcompiling@gmail.com> <1437713598-7657-1-git-send-email-stillcompiling@gmail.com> <20150724105227.GW5371@mwanda> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Dan, On Friday, July 24, 2015 01:52:27 PM Dan Carpenter wrote: > Write a better subject line. > > On Thu, Jul 23, 2015 at 09:53:18PM -0700, Joshua Clayton wrote: > > change instances SupportedRates to compliant and sane "rates" > > This change in no way harms readability, and brings several lines > > under the 80 character limit. > > Yeah, but it does a some other stuff as well like removing casts. I apologize. I thought it would make sense to double up (while I'm in there I'll just...). > > > - while ((pcur_bss->SupportedRates[i] != 0) && > > - (pcur_bss->SupportedRates[i] != 0xFF)) { > > - rate = pcur_bss->SupportedRates[i] & 0x7F; > > + while (pcur_bss->rates[i] && (pcur_bss->rates[i] != 0xFF)) { > > + rate = pcur_bss->rates[i] & 0x7F; > > > > if (rate > max_rate) > > > > max_rate = rate; > > > > wrqu->bitrate.fixed = 0; /* no auto select */ > > I actually like the != 0 here because we're talking about the number > zero. It should look like this: > > while (pcur_bss->rates[i] != 0 && > pcur_bss->rates[i] != 0xFF) { OK. > > But removing the parens is something for a different patch. I use a > script to help review these so when you mix different changes together > it means there is more manual review work for me. Sorry about that. I'll split or drop it in the next version > > regards, > dan carpenter Joshua