Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1191720 > unrolled thread
| Started by | Dan Carpenter <dan.carpenter@oracle.com> |
|---|---|
| First post | 2015-07-24 13:00 +0200 |
| Last post | 2015-07-24 15:10 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH 5/5] staging: rtl8712: style fix: Dan Carpenter <dan.carpenter@oracle.com> - 2015-07-24 13:00 +0200
Re: [PATCH 5/5] staging: rtl8712: style fix: Joshua Clayton <stillcompiling@gmail.com> - 2015-07-24 15:10 +0200
| From | Dan Carpenter <dan.carpenter@oracle.com> |
|---|---|
| Date | 2015-07-24 13:00 +0200 |
| Subject | Re: [PATCH 5/5] staging: rtl8712: style fix: |
| Message-ID | <pPIRQ-3xl-35@gated-at.bofh.it> |
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.
> - 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) {
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.
regards,
dan carpenter
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Joshua Clayton <stillcompiling@gmail.com> |
|---|---|
| Date | 2015-07-24 15:10 +0200 |
| Message-ID | <pPKTD-6EB-5@gated-at.bofh.it> |
| In reply to | #1191720 |
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
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web