The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Lubomir Rintel <lkundrak@v3.sk>
Cc: linux-rpi-kernel@lists.infradead.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, Eric Anholt <eric@anholt.net>,
	Lee Jones <lee@kernel.org>,
	Stephen Warren <swarren@wwwdotorg.org>,
	Peter Chen <peter.chen@freescale.com>
Subject: Re: [PATCH 1/2] net/smscx5xx: use the device tree for mac address
Date: Wed, 03 Feb 2016 16:23:59 +0100	[thread overview]
Message-ID: <2240729.oauKHqo53h@wuerfel> (raw)
In-Reply-To: <1454511759-24827-2-git-send-email-lkundrak@v3.sk>

On Wednesday 03 February 2016 16:02:38 Lubomir Rintel wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> This takes the MAC address for smsc75xx/smsc95xx USB network devices
> from a the device tree. This is required to get a usable persistent
> address on the popular beagleboard, whose hardware designers
> accidentally forgot that an ethernet device really requires an a
> MAC address to be functional.
> 
> The smsc75xx and smsc95xx drivers are just two copies of the
> same code, so better fix both.
> 
> Tested-by: Lubomir Rintel <lkundrak@v3.sk>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> 

I have no memory of writing this patch, where did you find it?

The changelog sounds like I wrote it, so I assume it was me after all.

> +       address = of_get_property(dev->udev->dev.of_node,
> +                                 "local-mac-address", NULL);
> +       if (address) {
> +               memcpy(dev->net->dev_addr, address, ETH_ALEN);
> +               return;
> +       }

This should use of_get_mac_address(), not an open-coded property
lookup. The function was probably added after I wrote the
the original patch.

	Arnd

  reply	other threads:[~2016-02-03 15:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-03 15:02 [PATCH 0/2] Set the Raspberry Pi Ethernet MAC address Lubomir Rintel
2016-02-03 15:02 ` [PATCH 1/2] net/smscx5xx: use the device tree for mac address Lubomir Rintel
2016-02-03 15:23   ` Arnd Bergmann [this message]
2016-02-03 15:42     ` Lubomir Rintel
2016-02-03 15:02 ` [PATCH 2/2] ARM: bcm2835: dt: Add the ethernet to the device tree Lubomir Rintel
2016-02-03 15:11   ` Lubomir Rintel
2016-02-03 16:11   ` Stephen Warren
2016-02-03 16:32     ` Lubomir Rintel
2016-02-03 23:41   ` Olivier Blin
2016-02-04  6:28     ` Peter Chen
2016-02-04  7:18       ` Lubomir Rintel
2016-02-07 10:10   ` kbuild test robot

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=2240729.oauKHqo53h@wuerfel \
    --to=arnd@arndb.de \
    --cc=devicetree@vger.kernel.org \
    --cc=eric@anholt.net \
    --cc=lee@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rpi-kernel@lists.infradead.org \
    --cc=lkundrak@v3.sk \
    --cc=peter.chen@freescale.com \
    --cc=swarren@wwwdotorg.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