Awesome patch!
On 01.05.2009 0:22 Uhr, Myles Watson wrote:
if (!eeprom_valid) { unsigned long mac_pos; mac_pos = 0xffffffd0; /* See romstrap.inc and romstrap.lds. */
mac_l = readl(mac_pos) + nic_index;
mac_h = readl(mac_pos + 4);
mac_l = readl((uint8_t*)mac_pos) + nic_index;
}mac_h = readl((uint8_t*)mac_pos + 4);
One could put that slightly simpler as
if (!eeprom_valid) { u8 *mac_pos; mac_pos = 0xffffffd0; /* See romstrap.inc and romstrap.lds. */ mac_l = readl(mac_pos) + nic_index; mac_h = readl(mac_pos + 4); }
since mac_pos seems never used as unsigned long.