From: "Dale Farnsworth" <dale@farnsworth.org>
To: Stephen Hemminger <shemminger@linux-foundation.org>
Cc: Jeff Garzik <jgarzik@pobox.com>,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
linux-mips@linux-mips.org, Ralf Baechle <ralf@linux-mips.org>
Subject: Re: [PATCH 1/2] mv643xx_eth: move mac_addr inside of mv643xx_eth_platform_data
Date: Wed, 28 Feb 2007 16:40:23 -0700 [thread overview]
Message-ID: <20070228234023.GA15081@xyzzy.farnsworth.org> (raw)
In-Reply-To: <20070228151103.0c5a320d@freekitty>
On Wed, Feb 28, 2007 at 03:11:03PM -0800, Stephen Hemminger wrote:
> On Wed, 28 Feb 2007 15:40:31 -0700
> "Dale Farnsworth" <dale@farnsworth.org> wrote:
>
> > The information contained within platform_data should be self-contained.
> > Replace the pointer to a MAC address with the actual MAC address in
> > struct mv643xx_eth_platform_data.
> >
> > Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
> >
> > Index: b/drivers/net/mv643xx_eth.c
> > ===================================================================
> > --- a/drivers/net/mv643xx_eth.c
> > +++ b/drivers/net/mv643xx_eth.c
> > @@ -1380,7 +1380,9 @@ static int mv643xx_eth_probe(struct plat
> >
> > pd = pdev->dev.platform_data;
> > if (pd) {
> > - if (pd->mac_addr)
> > + static u8 zero_mac_addr[6] = { 0 };
> > +
> > + if (memcmp(pd->mac_addr, zero_mac_addr, 6) != 0)
> > memcpy(dev->dev_addr, pd->mac_addr, 6);
>
>
> is_zero_ether_addr() is faster/cleaner for this
Thanks. I follow up with a modified patch in a day or two.
-Dale
prev parent reply other threads:[~2007-02-28 23:40 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-28 22:40 [PATCH 1/2] mv643xx_eth: move mac_addr inside of mv643xx_eth_platform_data Dale Farnsworth
2007-02-28 22:47 ` [PATCH 2/2] mv643xx_eth: Place explicit port number in mv643xx_eth_platform_data Dale Farnsworth
2007-02-28 23:11 ` [PATCH 1/2] mv643xx_eth: move mac_addr inside of mv643xx_eth_platform_data Stephen Hemminger
2007-02-28 23:40 ` Dale Farnsworth [this message]
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=20070228234023.GA15081@xyzzy.farnsworth.org \
--to=dale@farnsworth.org \
--cc=jgarzik@pobox.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@linux-mips.org \
--cc=netdev@vger.kernel.org \
--cc=ralf@linux-mips.org \
--cc=shemminger@linux-foundation.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).