90 | | For Linux here are some gory details that you should be aware of if |
91 | | you stray from our kernel/BSP: |
92 | | In Linux things can be a bit more complicated depending on if you have |
93 | | systemd/udev changing device names or not. Linux will register |
94 | | on-board network devices as 'eth%d' starting at 0 and incrementing in |
95 | | the order the device is registered which depends greatly on the kernel |
96 | | (linking order, modules vs static drivers etc) and the kernel makes NO |
97 | | attempt to make this consistent across reboots. Therefore there is a |
98 | | concept in Linux where a userspace process like systemd/udev will |
99 | | rename the network interfaces as they get registered to use |
100 | | bus/port/path specific names that are consistent across boots. This |
101 | | produces pretty confusing names to most users so we disable this |
102 | | feature in our default build by passing 'net.ifnames=0' on the kernel |
103 | | command line which confusing enough is not at all a kernel option but |
104 | | systemd/udev parses the kernel cmdline to look for this. To make |
105 | | things worse DSA drivers (which modern switch devices are) get their |
106 | | port names from device-tree so Linux will name those 'lan1', 'lan2'. |
107 | | And to make things really worse because the IMX8MM FEC and EQOS |
108 | | network devices are different MAC's (both inside the IMX8MP) they have |
109 | | different drivers and those drivers can register in either order so |
110 | | eth0/eth1 can flip around across boots. I added a kernel patch (a |
111 | | controversial one that will never make it upstream) to our kernel to |
112 | | avoid this and make them consistent. |