Debian: MAC address keeps changing on every reboot
#11
(08-20-2017, 03:06 AM)dlu Wrote: Can someone explain the solution please?

- If the mac address resides in the "SPI flash", then 00:...:00 and FF:...:FF are both invalid addresses. Which software part corrected the zeroes, and why didn't it correct the FFs?
- Where does the new value for the stable mac address come from? Is it the same code path as seen in rontants loglines (random_ether_addr in rk_get_eth_addr)? Or somewhere else?


I've been playing with this most of the night.  If you write to the SPI with anything ( I placed my name in the SPI at offset 4000 ) and boot, then something  takes over on the next boot and starts to keep track of the mac addy ;  but, with a twist;  when there is all mostly 0xFF there, um, it gets very confused;  

I finally went back and wrote 0x00's to the SPI and rebooted;  will update later ... it takes at least two boots and not sure in my case what will happen.  I'm not really happy about the way that the image is using the SPI flash !!  This is NOT what the SPI flash was intended for, and it prevents me from experimenting with the SPI flash booting. So ayufan and I need to have a talk about this.

At this time,  the mac addy appears to be written to the SPI flash at offset 400 with some other junk at the heading;

example

Code:
rock64@Rock64-A:~/work/spi_flash$ hexdump spi_flash.003
0000000 5644 524b 0002 0000 0001 0001 0040 fbb8
0000010 0003 0000 0006 0000 0000 0000 0000 0000
0000020 0000 0000 0000 0000 0000 0000 0000 0000
*
0000400 493e babb 3156 0000 0000 0000 0000 0000
0000410 0000 0000 0000 0000 0000 0000 0000 0000
*
000fff0 0000 0000 0000 0000 0000 0000 0002 0000
0010000 0000 0000 0000 0000 0000 0000 0000 0000
*
0040000
There is another small baby bug;  on the xenial-mate image eth1 and eth0 show up;  eth1 is the internal PHY which does not show up on the xenial-minimal image;  anyway,  both of the interfaces eth0 and eth1 have the same mac addy after this "change" which will be a problem once we get the magjacks mounted and have the 10|100 interface going...  the addys must be unique !

Note:  spoke with ayufan;  /dev/mtd3 is a partition;  SPI flash is a lot of data and partitions.  See  /proc/mtd
marcushh777    Cool

please join us for a chat @  irc.pine64.xyz:6667   or ssl  irc.pine64.xyz:6697

( I regret that I am not able to respond to personal messages;  let's meet on irc! )
  Reply


Messages In This Thread
RE: Debian: MAC address keeps changing on every reboot - by MarkHaysHarris777 - 08-20-2017, 03:27 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  How to update/compile Debian 12.5? Wizardknight 3 461 03-29-2024, 05:01 AM
Last Post: gedas07
  Rock64 Debian 11 (Bullseye) install problem jbize 15 8,493 10-12-2023, 05:14 PM
Last Post: tpaul
  rock64-debian-mrfixit-190531.img.xz : missing /usr/lib/dri/rockchip_dri.so popi 5 5,296 08-12-2021, 04:55 AM
Last Post: igorp
  Debian build from mrfixit2001 Luke 18 27,370 05-17-2021, 02:35 AM
Last Post: Wizzard
  Debian kernel stuck at 4.4.167 Enig123 5 5,670 12-29-2020, 12:57 PM
Last Post: kwinz
  Debian (Vanilla) on Rock64 and eMMC - how ? as365n4 4 5,298 09-21-2020, 04:33 AM
Last Post: as365n4
  pcsx rearmed on rock64 debian stretch does not go fullscreen RockyBoulder 2 4,247 05-09-2020, 03:15 AM
Last Post: lawrencejd
  Fedora 31 crosscompilation fdt problem mimics debian 888789 kf5zmi 2 4,187 01-20-2020, 12:25 PM
Last Post: kf5zmi
  Upgrading Debian Stretch image to Buster cosuhi 2 4,746 08-27-2019, 02:42 AM
Last Post: Malmgren
  Ayufan Debian Stretch Openmediavault 4 5G Wifi Not Connecting Poincare 0 2,279 03-26-2019, 07:28 PM
Last Post: Poincare

Forum Jump:


Users browsing this thread: 1 Guest(s)