[PATCH] ixgb: support ETHTOOL_GPERMADDR
authorJohn W. Linville <linville@tuxdriver.com>
Mon, 12 Sep 2005 14:48:56 +0000 (10:48 -0400)
committerJeff Garzik <jgarzik@pobox.com>
Wed, 14 Sep 2005 12:29:32 +0000 (08:29 -0400)
Add support for ETHTOOL_GPERMADDR to ixgb.

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
drivers/net/ixgb/ixgb_ethtool.c
drivers/net/ixgb/ixgb_main.c

index 9d026ed77ddd4250660ad117d76c2e319e6d3eda..319ee4cd70d85cab7b0a1832115f4bfedbc9e368 100644 (file)
@@ -723,6 +723,7 @@ struct ethtool_ops ixgb_ethtool_ops = {
        .phys_id = ixgb_phys_id,
        .get_stats_count = ixgb_get_stats_count,
        .get_ethtool_stats = ixgb_get_ethtool_stats,
+       .get_perm_addr = ethtool_op_get_perm_addr,
 };
 
 void ixgb_set_ethtool_ops(struct net_device *netdev)
index 5c555373adbe5802054b2ed3558219269d0e9ca5..5015eaf4e20a5472c594d49212b2349d2c9120f3 100644 (file)
@@ -460,8 +460,9 @@ ixgb_probe(struct pci_dev *pdev,
        }
 
        ixgb_get_ee_mac_addr(&adapter->hw, netdev->dev_addr);
+       memcpy(netdev->perm_addr, netdev->dev_addr, netdev->addr_len);
 
-       if(!is_valid_ether_addr(netdev->dev_addr)) {
+       if(!is_valid_ether_addr(netdev->perm_addr)) {
                err = -EIO;
                goto err_eeprom;
        }