Reading serial EEPROM

Hello all,
Do anybody know how to read the data from serial eeprom ?
I want to read the MAC address and other details from on board EEPROM from
intelpro100 ethernet card(82559).

Any source code will help me a lot…

Waiting for your reply…
Thanks
Umesh

Umesh Suryawanshi <umesh.suryawanshi@tatainfotech.com> wrote:

Hello all,
Do anybody know how to read the data from serial eeprom ?
I want to read the MAC address and other details from on board EEPROM from
intelpro100 ethernet card(82559).

Any source code will help me a lot…

Take a look at sys/nic.h and sys/dcmd_io-net.h for the type Nic_t, you
will find a help devctl named DCMD_IO_NET_NICINFO. Open a fd to the
device in question and send the devctl.

http://www.qnx.com/developer/docs/momentics_nc_docs/neutrino/lib_ref/d/devctl.html

for a devctl example.


regards,
Tom

Reading info straight out an Intel NIC EEPROM is a bit of a pain in the ass,
but with a bit of help from the OpenBSD kernel, it is much easier…
the function you would be most interested in is fxp_read_eeprom() in the
fxp.c file found here: http://www.openbsd.org/cgi-bin/cvsweb/src/sys/dev/ic/

it took me a few reads of the function and it’s surrounding code to figure
out what is going on, the Linux source may be a bit nicer, but i never
looked (gotta be careful with GPL’ed code in proprietary projects).
Unfortuneatly you won’t get much help from Intel, they are crazy secretive
about giving out manuals to their NICs.


Jim
“Umesh Suryawanshi” <umesh.suryawanshi@tatainfotech.com> wrote in message
news:agbp7m$sdf$1@inn.qnx.com

Hello all,
Do anybody know how to read the data from serial eeprom ?
I want to read the MAC address and other details from on board EEPROM from
intelpro100 ethernet card(82559).

Any source code will help me a lot…

Waiting for your reply…
Thanks
Umesh