All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Jakub Kicinski <kuba@kernel.org>,
	Colin Ian King <colin.king@canonical.com>
Cc: Siva Reddy Kallam <siva.kallam@broadcom.com>,
	Prashant Sreedharan <prashant@broadcom.com>,
	Michael Chan <mchan@broadcom.com>,
	"David S . Miller" <davem@davemloft.net>,
	netdev@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: tg3: tidy up loop, remove need to compute off with a multiply
Date: Fri, 08 May 2020 19:31:48 -0700	[thread overview]
Message-ID: <fbd61323358554b00460c97ec303572189f99544.camel@perches.com> (raw)
In-Reply-To: <20200508184814.45e10c12@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>

On Fri, 2020-05-08 at 18:48 -0700, Jakub Kicinski wrote:
> On Sat, 9 May 2020 00:31:03 +0100 Colin Ian King wrote:
> > > My preference would be for
> > > 
> > > {
> > > 	int i;
> > > 	u32 off = 0;
> > > 
> > > 	for (i = 0; i < TG3_SD_NUM_RECS; i++) {
> > > 		tg3_ape_scratchpad_read(tp, (u32 *)ocir, off, TC3_OCIR_LEN);
> > > 
> > > 		if (ocir->signature != TG3_OCIR_SIG_MAGIC ||
> > > 		    !(ocir->version_flags & TG3_OCIR_FLAG_ACTIVE))
> > > 			memset(ocir, 0, TG3_OCIR_LEN);
> > > 
> > > 		off += TG3_OCIR_LEN;
> > > 		ocir++;
> > > 	}
> > >   
> > OK, I'll send a V3 tomorrow.
> 
> I already reviewed and applied v2, just waiting for builds to finish,
> let's leave it.


I think clarity should be preferred.
Are you a maintainer of this file?

$ ./scripts/get_maintainer.pl -f drivers/net/ethernet/broadcom/tg3.c
Siva Reddy Kallam <siva.kallam@broadcom.com> (supporter:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
Prashant Sreedharan <prashant@broadcom.com> (supporter:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
Michael Chan <mchan@broadcom.com> (supporter:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
"David S. Miller" <davem@davemloft.net> (odd fixer:NETWORKING DRIVERS)
netdev@vger.kernel.org (open list:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
linux-kernel@vger.kernel.org (open list)



WARNING: multiple messages have this Message-ID (diff)
From: Joe Perches <joe@perches.com>
To: Jakub Kicinski <kuba@kernel.org>,
	Colin Ian King <colin.king@canonical.com>
Cc: Siva Reddy Kallam <siva.kallam@broadcom.com>,
	Prashant Sreedharan <prashant@broadcom.com>,
	Michael Chan <mchan@broadcom.com>,
	"David S . Miller" <davem@davemloft.net>,
	netdev@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: tg3: tidy up loop, remove need to compute off with a multiply
Date: Sat, 09 May 2020 02:31:48 +0000	[thread overview]
Message-ID: <fbd61323358554b00460c97ec303572189f99544.camel@perches.com> (raw)
In-Reply-To: <20200508184814.45e10c12@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>

On Fri, 2020-05-08 at 18:48 -0700, Jakub Kicinski wrote:
> On Sat, 9 May 2020 00:31:03 +0100 Colin Ian King wrote:
> > > My preference would be for
> > > 
> > > {
> > > 	int i;
> > > 	u32 off = 0;
> > > 
> > > 	for (i = 0; i < TG3_SD_NUM_RECS; i++) {
> > > 		tg3_ape_scratchpad_read(tp, (u32 *)ocir, off, TC3_OCIR_LEN);
> > > 
> > > 		if (ocir->signature != TG3_OCIR_SIG_MAGIC ||
> > > 		    !(ocir->version_flags & TG3_OCIR_FLAG_ACTIVE))
> > > 			memset(ocir, 0, TG3_OCIR_LEN);
> > > 
> > > 		off += TG3_OCIR_LEN;
> > > 		ocir++;
> > > 	}
> > >   
> > OK, I'll send a V3 tomorrow.
> 
> I already reviewed and applied v2, just waiting for builds to finish,
> let's leave it.


I think clarity should be preferred.
Are you a maintainer of this file?

$ ./scripts/get_maintainer.pl -f drivers/net/ethernet/broadcom/tg3.c
Siva Reddy Kallam <siva.kallam@broadcom.com> (supporter:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
Prashant Sreedharan <prashant@broadcom.com> (supporter:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
Michael Chan <mchan@broadcom.com> (supporter:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
"David S. Miller" <davem@davemloft.net> (odd fixer:NETWORKING DRIVERS)
netdev@vger.kernel.org (open list:BROADCOM TG3 GIGABIT ETHERNET DRIVER)
linux-kernel@vger.kernel.org (open list)

  reply	other threads:[~2020-05-09  2:31 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-08 22:53 [PATCH] net: tg3: tidy up loop, remove need to compute off with a multiply Colin King
2020-05-08 22:53 ` Colin King
2020-05-08 23:04 ` Michael Chan
2020-05-08 23:04   ` Michael Chan
2020-05-08 23:21 ` Joe Perches
2020-05-08 23:21   ` Joe Perches
2020-05-08 23:31   ` Colin Ian King
2020-05-08 23:31     ` Colin Ian King
2020-05-09  1:48     ` Jakub Kicinski
2020-05-09  1:48       ` Jakub Kicinski
2020-05-09  2:31       ` Joe Perches [this message]
2020-05-09  2:31         ` Joe Perches
2020-05-09  4:48         ` Michael Chan
2020-05-09  4:48           ` Michael Chan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fbd61323358554b00460c97ec303572189f99544.camel@perches.com \
    --to=joe@perches.com \
    --cc=colin.king@canonical.com \
    --cc=davem@davemloft.net \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mchan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=prashant@broadcom.com \
    --cc=siva.kallam@broadcom.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.