FreeBSD/sys/mips/nlm/dev/net/xlpge.c
/*
 * Read the MAC address from FDT or board eeprom.
 */
Read the MAC address from FDT or board eeprom.
Read the MAC address from FDT or board eeprom .
static void
xlpge_read_mac_addr(struct nlm_xlpge_softc *sc)
{
	xlpge_get_macaddr(sc->dev_addr);
	sc->dev_addr[5] += (sc->block * 4) + sc->port;
	if (sc->type == SGMIIC)
		nlm_nae_setup_mac_addr_sgmii(sc->base_addr, sc->block,
		    sc->port, sc->type, sc->dev_addr);
	else if (sc->type == XAUIC)
		nlm_nae_setup_mac_addr_xaui(sc->base_addr, sc->block,
		    sc->port, sc->type, sc->dev_addr);
}
static void xlpge_read_mac_addr ( struct nlm_xlpge_softc * sc ) { xlpge_get_macaddr ( sc -> dev_addr ) ; sc -> dev_addr [ 5 ] += ( sc -> block * 4 ) + sc -> port ; if ( sc -> type == SGMIIC ) nlm_nae_setup_mac_addr_sgmii ( sc -> base_addr , sc -> block , sc -> port , sc -> type , sc -> dev_addr ) ; else if ( sc -> type == XAUIC ) nlm_nae_setup_mac_addr_xaui ( sc -> base_addr , sc -> block , sc -> port , sc -> type , sc -> dev_addr ) ; }
Read the MAC address from FDT or board eeprom.
Read the MAC address from FDT or board eeprom .
/* last octet is port specific */