lkml.org 
[lkml]   [2020]   [Feb]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 03/14] net: davicom: dm9000: allow to pass MAC address through mac_addr module parameter
From
Date

> Am 12.02.2020 um 09:07 schrieb Geert Uytterhoeven <geert@linux-m68k.org>:
>
> On Tue, Feb 11, 2020 at 11:25 PM Andrew Lunn <andrew@lunn.ch> wrote:
>> On Tue, Feb 11, 2020 at 10:41:20PM +0100, H. Nikolaus Schaller wrote:
>>> This is needed to give the MIPS Ingenic CI20 board a stable MAC address
>>> which can be optionally provided by vendor U-Boot.
>>>
>>> For get_mac_addr() we use an adapted copy of from ksz884x.c which
>>> has very similar functionality.
>>>
>>> Signed-off-by: H. Nikolaus Schaller <hns@goldelico.com>
>>
>> Hi Nikolaus
>>
>> Please split these patches by subsystem. So this one patch needs to go
>> via netdev.
>>
>>> +static char *mac_addr = ":";
>>> +module_param(mac_addr, charp, 0);
>>> +MODULE_PARM_DESC(mac_addr, "MAC address");
>>
>> Module parameters are not liked.
>>
>> Can it be passed via device tree? The driver already has code to get
>> it out of the device tree.
>
> Yep, typically U-Boot adds an appropriate "local-mac-address" property to the
> network device's device node, based on the "ethernet0" alias.
>
> However, the real clue here may be "vendor U-Boot", i.e. no support for the
> above?

Yes. It is a fallback solution like it is implemented for ksz884x.c to make it
work with existing (older) U-Boot installation.

Maybe I should better clarify this in the commit message for v2 (which goes
to netdev only).

BR and thanks,
Nikolaus

\
 
 \ /
  Last update: 2020-02-12 09:15    [W:0.074 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site