lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CABikg9x4LbOR25aLJ_=EE5SxDQJXj5_dod6rCgmeQXxmKAR+SA@mail.gmail.com>
Date:   Wed, 17 Aug 2022 20:09:55 +0300
From:   Sergei Antonov <saproj@...il.com>
To:     Andrew Lunn <andrew@...n.ch>
Cc:     Vladimir Oltean <olteanv@...il.com>, netdev@...r.kernel.org,
        Florian Fainelli <f.fainelli@...il.com>
Subject: Re: [PATCH] net: dsa: mv88e6060: report max mtu 1536

On Thu, 11 Aug 2022 at 17:12, Andrew Lunn <andrew@...n.ch> wrote:
> > The driver does not know its MAC address initially. On my hardware it
> > is stored in a flash memory chip, so I assign it using "ip link set
> > ..." either manually or from an /etc/init.d script. A solution with
> > early MAC assignment in the moxart_mac_probe() function is doable. Do
> > you think I should implement it?
>
> I would suggest a few patches:
>
> 1) Use eth_hw_addr_random() to assign a random MAC address during probe.
> 2) Remove is_valid_ether_addr() from moxart_mac_open()
> 3) Add a call to platform_get_ethdev_address() during probe
> 4) Remove is_valid_ether_addr() from moxart_set_mac_address(). The core does this
>
> platform_get_ethdev_address() will call of_get_mac_addr_nvmem() which
> might be able to get your MAC address out of flash, without user space
> being involved.

Great suggestions! So I am submitting a patch named
"net: moxa: MAC address reading, generating, validity checking"

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ