Re: [PATCH 5/5] riscv: dts: spacemit: k3-com260: Set Ethernet MAC from EEPROM
From: Yixun Lan
Date: Tue Nov 24 2026 - 07:29:52 EST
On 08:23 Thu 05 Nov , Troy Mitchell wrote:
> The EEPROM on the K3 CoM260 module stores the board MAC address in its
> ONIE TLV data. Assign it to the module's Ethernet controller, so that
> every carrier board using the module gets a stable MAC address instead
> of a random one.
>
> Signed-off-by: Troy Mitchell <troy.mitchell@xxxxxxxxxxxxxxxxxx>
Reviewed-by: Yixun Lan <dlan@xxxxxxxxxx>
> ---
> arch/riscv/boot/dts/spacemit/k3-com260.dtsi | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/arch/riscv/boot/dts/spacemit/k3-com260.dtsi b/arch/riscv/boot/dts/spacemit/k3-com260.dtsi
> index f94607cb2eeb..1f5c958c9d6d 100644
> --- a/arch/riscv/boot/dts/spacemit/k3-com260.dtsi
> +++ b/arch/riscv/boot/dts/spacemit/k3-com260.dtsi
> @@ -42,7 +42,7 @@ eeprom@50 {
> nvmem-layout {
> compatible = "onie,tlv-layout";
>
> - mac-address {
> + mac_address: mac-address {
> #nvmem-cell-cells = <1>;
> };
>
> @@ -216,6 +216,8 @@ dldo7: dldo7 {
> };
>
> ð1 {
> + nvmem-cells = <&mac_address 0>;
> + nvmem-cell-names = "mac-address";
> pinctrl-names = "default";
> pinctrl-0 = <&gmac1_rgmii_0_cfg>, <&gmac1_phy_0_cfg>;
> phy-mode = "rgmii-id";
>
> --
> 2.56.0
>
--
Yixun Lan (dlan)