[PATCH net] net: sparx5: make ports inherit the switch base mac address type

Quentin Freimanis quentin at q-lab.dev
Wed Sep 30 01:00:42 PDT 2026


Hi Jakub,

On 9/29/26 6:59 PM, Jakub Kicinski wrote:
> On Sun, 27 Sep 2026 21:50:12 -0700 Quentin Freimanis wrote:
>> 0 is NET_ADDR_PERM, so userspace thinks this is a stable address.
> 
> Could you please explain the end-user impact of this?
> Unclear to me from the commit msg if this is something that broke
> your deployment / scripts or maybe you simply noticed it from code
> inspection / LLM scan.
> 
> No need to repost, just explain, I'll add it when applying.
> 

With a random MAC reported as NET_ADDR_PERM, systemd's 
MACAddressPolicy=persistent [1] leaves it unchanged, so a DHCP client 
gets a new IP address every boot and a static reservation can't be used. 
Reporting it as NET_ADDR_RANDOM makes systemd replace it with a stable 
address derived from the interface name and machine-id.

(this is my use case, and how I found the bug)

>> Fix by tracking the base MAC address assign type in the sparx5 struct
>> and applying it to each port's netdev.
> 
> Generally no need to repeat what an average reader can easily grok
> from the diff.

Ack.

- Quentin

[1] 
https://www.freedesktop.org/software/systemd/man/latest/systemd.link.html#MACAddressPolicy=



More information about the linux-arm-kernel mailing list