This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM3352: CPSW MAC Address Always Stuck at 70:00:00:00:00:00 on Kernel 4.14

Part Number: AM3352

Tool/software:

Hello ,

I’m working on a TI processor AM3352 running Linux kernel 4.14. I’ve encountered an issue where the CPSW driver always reports a default MAC address of 70:00:00:00:00:00 instead of reading the correct address from the hardware (eFuse/EEPROM) or from the Device Tree. Below are some logs from the boot process and my current DTS snippets. Any guidance on how to properly configure or retrieve the MAC address would be greatly appreciated.

Kernel Log:

[   10.222944] cpsw 4a100000.ethernet: No slave[1] phy_id, phy-handle, or fixed-link property
[   10.231774] cpsw 4a100000.ethernet: Missing dual_emac_res_vlan in DT.
[   10.238601] cpsw 4a100000.ethernet: Using 2 as Reserved VLAN for 1 slave
[   10.245655] cpsw 4a100000.ethernet: Detected MACID = 70:00:00:00:00:00
[   10.252678] cpsw 4a100000.ethernet: initialized cpsw ale version 1.4
[   10.259379] cpsw 4a100000.ethernet: ALE Table size 1024
[   10.264932] cpsw 4a100000.ethernet: cpts: overflow check period 1250 (jiffies)
[   10.273691] cpsw 4a100000.ethernet: cpsw: Detected MACID = 70:00:00:00:00:00
[   40.854687] net eth0: initializing cpsw version 1.12 (0)
[   43.099783] cpsw 4a100000.ethernet eth0: Link is Up - 100Mbps/Full - flow control off
[   47.194398] cpsw 4a100000.ethernet eth0: Link is Down
[   49.242399] cpsw 4a100000.ethernet eth0: Link is Up - 10Mbps/Full - flow control off

DTS:

  mac: ethernet@4a100000 {
   compatible = "ti,am335x-cpsw","ti,cpsw";
   ti,hwmods = "cpgmac0";
   clocks = <&cpsw_125mhz_gclk>, <&cpsw_cpts_rft_clk>;
   clock-names = "fck", "cpts";
   cpdma_channels = <8>;
   ale_entries = <1024>;
   bd_ram_size = <0x2000>;
   mac_control = <0x20>;
   slaves = <2>;
   active_slave = <0>;
   cpts_clock_mult = <0x80000000>;
   cpts_clock_shift = <29>;
   reg = <0x4a100000 0x800
          0x4a101200 0x100>;
   #address-cells = <1>;
   #size-cells = <1>;
   interrupts = <40 41 42 43>;
   ranges;
   syscon = <&scm_conf>;
   status = "disabled";

   davinci_mdio: mdio@4a101000 {
    compatible = "ti,cpsw-mdio","ti,davinci_mdio";
    #address-cells = <1>;
    #size-cells = <0>;
    ti,hwmods = "davinci_mdio";
    bus_freq = <1000000>;
    reg = <0x4a101000 0x100>;
    status = "disabled";
   };

   cpsw_emac0: slave@4a100200 {

    mac-address = [ 00 00 00 00 00 00 ];
   };

   cpsw_emac1: slave@4a100300 {

    mac-address = [ 00 00 00 00 00 00 ];
   };

   phy_sel: cpsw-phy-sel@44e10650 {
    compatible = "ti,am3352-cpsw-phy-sel";
    reg= <0x44e10650 0x4>;
    reg-names = "gmii-sel";
   };
  };

&mac {
        pinctrl-names = "default", "sleep";
        //pinctrl-0 = <&cpsw_default>;
        //pinctrl-1 = <&cpsw_sleep>;
        dual_emac = <1>;
        status = "okay";
};

&cpsw_emac0 {
        phy_id = <&davinci_mdio>, <0>;
        phy-mode = "rgmii";
        phy-handle = <&vsc8531_0>;
        dual_emac_res_vlan = <0>;
};

&davinci_mdio {
        pinctrl-names = "default", "sleep";
        pinctrl-0 = <&mdio_pins_default>;
        //pinctrl-1 = <&mdio_pins_sleep>;
        status = "okay";
        vsc8531_0: ethernet-phy@0 {
                        reg = <0>;
                        compatible="ethernet-phy-id0007.0572";
           };
        
};

HW Design: