FreeBSD/sys/dev/cxgb/common/cxgb_xgmac.c
/**
 *	t3_mac_set_address - set one of the station's unicast MAC addresses
 *	@mac: the MAC handle
 *	@idx: index of the exact address match filter to use
 *	@addr: the Ethernet address
 *
 *	Set one of the station's unicast MAC addresses.
 */
set one of the station's unicast MAC addresses
@mac: the MAC handle
@idx: index of the exact address match filter to use
@addr: the Ethernet address

Set one of the station's unicast MAC addresses.
set one of the station ' s unicast MAC addresses @mac : the MAC handle @idx : index of the exact address match filter to use @addr : the Ethernet address Set one of the station ' s unicast MAC addresses .
int t3_mac_set_address(struct cmac *mac, unsigned int idx, u8 addr[6])
{
	if (mac->multiport)
		idx = mac->ext_port + idx * mac->adapter->params.nports;
	if (idx >= mac->nucast)
		return -EINVAL;
	set_addr_filter(mac, idx, addr);
	if (mac->multiport && idx < mac->adapter->params.nports)
		t3_vsc7323_set_addr(mac->adapter, addr, idx);
	return 0;
}
int t3_mac_set_address ( struct cmac * mac , unsigned int idx , u8 addr [ 6 ] ) { if ( mac -> multiport ) idx = mac -> ext_port + idx * mac -> adapter -> params . nports ; if ( idx >= mac -> nucast ) return - EINVAL ; set_addr_filter ( mac , idx , addr ) ; if ( mac -> multiport && idx < mac -> adapter -> params . nports ) t3_vsc7323_set_addr ( mac -> adapter , addr , idx ) ; return 0 ; }
t3_mac_set_address - set one of the station's unicast MAC addresses
      @mac: the MAC handle
      @idx: index of the exact address match filter to use
      @addr: the Ethernet address
t3_mac_set_address - set one of the station ' s unicast MAC addresses @mac : the MAC handle @idx : index of the exact address match filter to use @addr : the Ethernet address