Dear NXP Support Team,
I am currently working with an i.MX8MP board and would like to fuse MAC addresses directly in the kernel, similar to the process used in U-Boot.
In U-Boot, the following commands are used to fuse the MAC addresses:
fuse prog 9 0 33445567
fuse prog 9 1 55661122
fuse prog 9 2 11223344
These commands set the MAC addresses for Ethernet interfaces eth0 and eth1. I would like to achieve the same functionality in the Linux kernel, specifically in the context of the i.MX8MP.
Could you please provide guidance on how to fuse MAC addresses in the kernel using the One-Time Programmable (OCOTP) memory, and how to program the specific fuses for eth0 and eth1 in a similar manner as the U-Boot commands listed above?
I would appreciate any kernel-specific commands or examples to help me achieve this.
Thank you for your assistance.
Solved! Go to Solution.
already give the example in the user guide, you can read and write the mac address according to this address and offset,
0x640 (offset 0x90): MAC1[2:5]
0x650 (offset 0x94): MAC2[4:5] + MAC1[0:1]
0x660 (offset 0x98): MAC2[0:3]
this is from my board,
one can refer to the link as below:
https://www.digi.com/resources/documentation/digidocs/embedded/dey/3.0/cc6/bsp_r_otp_cc6cc6qp
and also can refer to the chapter 13.4 Examples to read/write the raw NVMEM file in user space of linux user guide
Hello,
Thank you for the reference you have shared regarding the process. It was helpful in understanding the basics. However, I still have some doubts that I would like to clarify.
Specifically, in the provided Python script, the following line is unclear:
f.write(pack('<L', 0x30445011))
Since this involves fusing data into OTP memor a process that is irreversibl I want to proceed cautiously. Could you please clarify the following:
already give the example in the user guide, you can read and write the mac address according to this address and offset,
0x640 (offset 0x90): MAC1[2:5]
0x650 (offset 0x94): MAC2[4:5] + MAC1[0:1]
0x660 (offset 0x98): MAC2[0:3]
this is from my board,