On 27 Jul 2016, at 17:45, Alexander Duyck <[email protected]> wrote:
> Other than that I can't think of too many other ways to modify the
> EEPROM without actually going in and modifying it yourself. I believe
> the e1000e driver supports modifying an EEPROM via ethtool, so one
> possible fix would be to disable the EEPROM protection and read/write
> the same value from some offset on the EEPROM. For example byte
> offsets 0x10 through 0x13 in your dump below should represent the PBA
> number. If you were to either rewrite it as 0xFF or even alter the
> data it should cause no harm since the PBA number is currently unused
> anyway, note the "PBA No: FFFFFF-0FF" from your driver load. The key
> bit being that we want to trigger e1000e_update_nvm_checksum which
> will occur with any write as long as it is in a checksummed region.
Alexander, thanks a lot, it worked!
For the record, here is what i did, more or less.
I noted the checksum before writing to the EEPROM (not really, i just looked it
up in the dump afterwards):
$ sudo ethtool -e enp0s31f6 offset 0x7e length 2
Offset Values
------ ------
0x007e: 60 13
Checked again a value which is a part of PBA:
$ sudo ethtool -e enp0s31f6 offset 0x10 length 1
Offset Values
------ ------
0x0010: ff
Determined the "magic" key 0x15708086 for writing to my EEPROM with ethtool,
after reading
http://blog.vodkamelone.de/archives/146-Unbricking-an-Intel-Pro1000-e1000-network-interface.html
:
$ lspci -nn | grep Ethernet
00:1f.6 Ethernet controller [0200]: Intel Corporation Ethernet Connection
I219-V [8086:1570] (rev 21)
Wrote to EEPROM:
$ sudo ethtool -E enp0s31f6 magic 0x15708086 offset 0x10 value 0xff
Checked the new checksum:
$ sudo ethtool -e enp0s31f6 offset 0x7e length 2
Offset Values
------ ------
0x007e: 60 93
(I also checked the whole dump. Naturally, there were no other differences.)
I booted a kernel with an unpatched e1000e, and the Ethernet worked fine.
What is strange, is that the checksum was off by one bit, apparently the
highest one...
- Alexey.
------------------------------------------------------------------------------
_______________________________________________
E1000-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/e1000-devel
To learn more about Intel® Ethernet, visit
http://communities.intel.com/community/wired