adapter->port[i].dev->name);
                        goto error;
                }
-               memcpy(adapter->port[i].dev->dev_addr, hw_addr, ETH_ALEN);
+               eth_hw_addr_set(adapter->port[i].dev, hw_addr);
                init_link_config(&adapter->port[i].link_config, bi);
        }
 
 
  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  * SOFTWARE.
  */
+#include <linux/etherdevice.h>
 #include "common.h"
 #include "regs.h"
 #include "sge_defs.h"
                memcpy(hw_addr, adapter->params.vpd.eth_base, 5);
                hw_addr[5] = adapter->params.vpd.eth_base[5] + i;
 
-               memcpy(adapter->port[i]->dev_addr, hw_addr,
-                      ETH_ALEN);
+               eth_hw_addr_set(adapter->port[i], hw_addr);
                init_link_config(&p->link_config, p->phy.caps);
                p->phy.ops->power_down(&p->phy, 1);
 
 
 static inline void t4_set_hw_addr(struct adapter *adapter, int port_idx,
                                  u8 hw_addr[])
 {
-       ether_addr_copy(adapter->port[port_idx]->dev_addr, hw_addr);
+       eth_hw_addr_set(adapter->port[port_idx], hw_addr);
        ether_addr_copy(adapter->port[port_idx]->perm_addr, hw_addr);
 }
 
 
                if (ret)
                        return ret;
 
-               memcpy(adap->port[i]->dev_addr, addr, ETH_ALEN);
+               eth_hw_addr_set(adap->port[i], addr);
                j++;
        }
        return 0;
 
 #ifndef __CXGB4VF_ADAPTER_H__
 #define __CXGB4VF_ADAPTER_H__
 
+#include <linux/etherdevice.h>
 #include <linux/interrupt.h>
 #include <linux/pci.h>
 #include <linux/spinlock.h>
 static inline void t4_os_set_hw_addr(struct adapter *adapter, int pidx,
                                     u8 hw_addr[])
 {
-       memcpy(adapter->port[pidx]->dev_addr, hw_addr, ETH_ALEN);
+       eth_hw_addr_set(adapter->port[pidx], hw_addr);
 }
 
 /**