Frage

I'm trying to figure out how I can read, write, and update memory addresses for eeprom on a pci network card using c language on ubuntu.

Can some please point me in the right direction to get started? Thank you

War es hilfreich?

Lösung

After some research, it appears ethtool can be used to read and write to the eeprom (http://manpages.ubuntu.com/manpages/hardy/en/man8/ethtool.8.html):

   ethtool -d|--register-dump ethX [raw on|off] [hex on|off] [file name]

   ethtool -e|--eeprom-dump ethX [raw on|off] [offset N] [length N]

   ethtool -E|--change-eeprom ethX [magic N] [offset N] [value N]

To dump eeprom, you can do ethtool -e ethX raw <on|off> offset <N> length <N>.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top