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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 16 Oct 2023 13:15:10 +0300
From:   Vladimir Oltean <olteanv@...il.com>
To:     Florian Fainelli <f.fainelli@...il.com>
Cc:     Oleksij Rempel <o.rempel@...gutronix.de>,
        "David S. Miller" <davem@...emloft.net>,
        Andrew Lunn <andrew@...n.ch>,
        Eric Dumazet <edumazet@...gle.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Paolo Abeni <pabeni@...hat.com>,
        Woojung Huh <woojung.huh@...rochip.com>,
        Arun Ramadoss <arun.ramadoss@...rochip.com>,
        Conor Dooley <conor+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Rob Herring <robh+dt@...nel.org>, kernel@...gutronix.de,
        linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
        UNGLinuxDriver@...rochip.com,
        "Russell King (Oracle)" <linux@...linux.org.uk>,
        devicetree@...r.kernel.org
Subject: Re: [PATCH net-next v3 2/7] net: dsa: microchip: Set unique MAC at
 startup for WoL support

On Sun, Oct 15, 2023 at 02:18:43PM -0700, Florian Fainelli wrote:
> 
> 
> On 10/13/2023 5:32 AM, Vladimir Oltean wrote:
> > On Fri, Oct 13, 2023 at 02:24:00PM +0200, Oleksij Rempel wrote:
> > > Set a unique global MAC address for each switch on the network at system
> > > startup by syncing the switch's global MAC address with the Ethernet
> > > address of the DSA master interface. This is crucial for supporting
> > > Wake-on-LAN (WoL) functionality, as it requires a unique address for
> > > each switch.
> > > 
> > > Although the operation is performed only at system start and won't sync
> > > if the master Ethernet address changes dynamically, it lays the
> > > groundwork for WoL support by ensuring a unique MAC address for each
> > > switch.
> > > 
> > > Signed-off-by: Oleksij Rempel <o.rempel@...gutronix.de>
> > > ---
> > 
> > Why not take the MAC address of the user port at ksz9477_set_wol() time,
> > and use the existing ksz_switch_macaddr_get() API that was just added so
> > that this use case could work?
> 
> Agreed we do that in a number of Ethernet MAC and PHY drivers FWIW
> (net_device::dev_addr).
> -- 
> Florian

To be clear (to Oleksij), the request is for WoL to use the same runtime
management of the global MAC address (ksz_switch_macaddr_get) as HSR,
and also extend ksz_port_set_mac_address() to deny address changes to a
port with WoL active. Thus, multiple user ports could have WoL enabled
as long as they share the same MAC address. MAC address changes are also
possible while WoL is not enabled. I guess wol->supported should only
get set on those user ports which have the same MAC address as the
global MAC address (if a global MAC address is configured), or on all
user ports (if there is none).

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ