#include "srom.h"
extern int eepro100_write_eeprom (struct eth_device* dev,
- int location, int addr_len, unsigned short data);
+ int location, int addr_len, unsigned short data);
/*----------------------------------------------------------------------------*/
for (i = 0; i < (EE_SIZE-1); i++)
{
- sum += sromdata[i];
+ sum += sromdata[i];
}
return (EE_CHECKSUM - sum);
}
/* get onboard network iobase */
pci_read_config_dword(PCI_BDF(0,0x10,0), PCI_BASE_ADDRESS_0,
- &onboard_dev.iobase);
+ &onboard_dev.iobase);
onboard_dev.iobase &= ~0xf;
source[63] = eepro100_srom_checksum (source);
for (count=0; count < EE_SIZE; count++)
{
if ( eepro100_write_eeprom ((struct eth_device*)&onboard_dev,
- count, EE_ADDR_BITS, SROM_SHORT(source)) == -1 )
- return -1;
+ count, EE_ADDR_BITS, SROM_SHORT(source)) == -1 )
+ return -1;
source++;
}
return 0;
/* get onboard network iobase */
pci_read_config_dword(PCI_BDF(0,0x10,0), PCI_BASE_ADDRESS_0,
- &onboard_dev.iobase);
+ &onboard_dev.iobase);
onboard_dev.iobase &= ~0xf;
memset (destination, 0x65, 128);
for (count=0; count < 0x40; count++)
{
- *destination++ = read_eeprom (struct eth_device*)&onboard_dev,
- count, EE_ADDR_BITS);
+ *destination++ = read_eeprom (struct eth_device*)&onboard_dev,
+ count, EE_ADDR_BITS);
#ifdef DEBUG
- printf ("%04x ", *(destination - 1));
- if (lr++ == 7)
- {
- printf("\n");
- lr = 0;
- }
+ printf ("%04x ", *(destination - 1));
+ if (lr++ == 7)
+ {
+ printf("\n");
+ lr = 0;
+ }
#endif
}
}