By default, the Ethernet driver reads the burned-in MAC address. If there is no MAC address in the hardware, the MAC will read all zeros, making the MAC malfunction. The kernel will then generate one random MAC address, which we can burn in hardware, but be careful – you can only burn it once. If you burn it the second time, the result is unpredictable.

Attention: this setup option will fuse the OTP hardware. You can do it only once. If you write it the second time, the result is unknown.

You can use the “echo” command in the console to flash the MAC address in the OTP hardware.


Example (Add MAC addr: 1e:ed:19:27:1a:b5):

# echo 0x1eed > /sys/fsl_otp/HW_OCOTP_MAC1 // high 16 bits of MAC address

# echo 0x19271ab5 > /sys/fsl_otp/HW_OCOTP_MAC0 // low 32 bits of MAC address

When you’re done, reboot your board. You will find your MAC address is 1e:ed:19:27:1a:b5