netdev: add missing set_mac_address hook
authorStephen Hemminger <shemminger@vyatta.com>
Fri, 9 Jan 2009 11:13:14 +0000 (11:13 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 11 Jan 2009 08:06:36 +0000 (00:06 -0800)
Many drivers lost the ability to set ethernet address accidently
during the net_device_ops conversion.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
27 files changed:
drivers/net/3c503.c
drivers/net/8139cp.c
drivers/net/8139too.c
drivers/net/8390.c
drivers/net/8390p.c
drivers/net/arm/etherh.c
drivers/net/e2100.c
drivers/net/enic/enic_main.c
drivers/net/hamachi.c
drivers/net/hp-plus.c
drivers/net/hydra.c
drivers/net/mac8390.c
drivers/net/ne-h8300.c
drivers/net/ne2k-pci.c
drivers/net/ns83820.c
drivers/net/r6040.c
drivers/net/sc92031.c
drivers/net/sis900.c
drivers/net/smc-mca.c
drivers/net/smc-ultra.c
drivers/net/smsc911x.c
drivers/net/smsc9420.c
drivers/net/via-rhine.c
drivers/net/via-velocity.c
drivers/net/wd.c
drivers/net/yellowfin.c
drivers/net/zorro8390.c

index c092c39..5b91a85 100644 (file)
@@ -177,6 +177,7 @@ static const struct net_device_ops el2_netdev_ops = {
        .ndo_get_stats          = eip_get_stats,
        .ndo_set_multicast_list = eip_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = eip_poll,
index dd7ac82..4e19ae3 100644 (file)
@@ -1821,6 +1821,7 @@ static const struct net_device_ops cp_netdev_ops = {
        .ndo_open               = cp_open,
        .ndo_stop               = cp_close,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_set_multicast_list = cp_set_rx_mode,
        .ndo_get_stats          = cp_get_stats,
        .ndo_do_ioctl           = cp_ioctl,
@@ -1832,6 +1833,7 @@ static const struct net_device_ops cp_netdev_ops = {
 #ifdef BROKEN
        .ndo_change_mtu         = cp_change_mtu,
 #endif
+
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = cp_poll_controller,
 #endif
index fe370f8..a5b2420 100644 (file)
@@ -917,6 +917,7 @@ static const struct net_device_ops rtl8139_netdev_ops = {
        .ndo_stop               = rtl8139_close,
        .ndo_get_stats          = rtl8139_get_stats,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_start_xmit         = rtl8139_start_xmit,
        .ndo_set_multicast_list = rtl8139_set_rx_mode,
        .ndo_do_ioctl           = netdev_ioctl,
@@ -924,7 +925,6 @@ static const struct net_device_ops rtl8139_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = rtl8139_poll_controller,
 #endif
-
 };
 
 static int __devinit rtl8139_init_one (struct pci_dev *pdev,
index fbe609a..ec3e22e 100644 (file)
@@ -63,6 +63,7 @@ const struct net_device_ops ei_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index ee70b35..da863c9 100644 (file)
@@ -68,6 +68,7 @@ const struct net_device_ops eip_netdev_ops = {
        .ndo_get_stats          = eip_get_stats,
        .ndo_set_multicast_list = eip_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = eip_poll,
index 6278606..745ac18 100644 (file)
@@ -646,6 +646,7 @@ static const struct net_device_ops etherh_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_addr       = eth_set_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index 20eb05c..b07ba19 100644 (file)
@@ -169,6 +169,7 @@ static const struct net_device_ops e21_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index d039e16..7d60551 100644 (file)
@@ -1599,6 +1599,7 @@ static const struct net_device_ops enic_netdev_ops = {
        .ndo_start_xmit         = enic_hard_start_xmit,
        .ndo_get_stats          = enic_get_stats,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_set_multicast_list = enic_set_multicast_list,
        .ndo_change_mtu         = enic_change_mtu,
        .ndo_vlan_rx_register   = enic_vlan_rx_register,
index 3220022..7e8b3c5 100644 (file)
@@ -576,6 +576,7 @@ static const struct net_device_ops hamachi_netdev_ops = {
        .ndo_set_multicast_list = set_rx_mode,
        .ndo_change_mtu         = eth_change_mtu,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_tx_timeout         = hamachi_tx_timeout,
        .ndo_do_ioctl           = netdev_ioctl,
 };
index b507dbc..5e070f4 100644 (file)
@@ -166,6 +166,7 @@ static const struct net_device_ops hpp_netdev_ops = {
        .ndo_get_stats          = eip_get_stats,
        .ndo_set_multicast_list = eip_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = eip_poll,
index 9cb38a8..8ac0930 100644 (file)
@@ -103,6 +103,7 @@ static const struct net_device_ops hydra_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index 57716e2..8e88486 100644 (file)
@@ -486,6 +486,7 @@ static const struct net_device_ops mac8390_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index b572391..7bd6662 100644 (file)
@@ -202,6 +202,7 @@ static const struct net_device_ops ne_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index 62f20ba..f090d3b 100644 (file)
@@ -208,6 +208,7 @@ static const struct net_device_ops ne2k_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller = ei_poll,
index 42021ac..e80294d 100644 (file)
@@ -1956,6 +1956,7 @@ static const struct net_device_ops netdev_ops = {
        .ndo_change_mtu         = ns83820_change_mtu,
        .ndo_set_multicast_list = ns83820_set_multicast,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_tx_timeout         = ns83820_tx_timeout,
 #ifdef NS83820_VLAN_ACCEL_SUPPORT
        .ndo_vlan_rx_register   = ns83820_vlan_rx_register,
index 454e7de..72fd9e9 100644 (file)
@@ -1059,6 +1059,7 @@ static const struct net_device_ops r6040_netdev_ops = {
        .ndo_set_multicast_list = r6040_multicast_list,
        .ndo_change_mtu         = eth_change_mtu,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_do_ioctl           = r6040_ioctl,
        .ndo_tx_timeout         = r6040_tx_timeout,
 #ifdef CONFIG_NET_POLL_CONTROLLER
index 42fd312..8b75bef 100644 (file)
@@ -1408,6 +1408,7 @@ static const struct net_device_ops sc92031_netdev_ops = {
        .ndo_set_multicast_list = sc92031_set_multicast_list,
        .ndo_change_mtu         = eth_change_mtu,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_tx_timeout         = sc92031_tx_timeout,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = sc92031_poll_controller,
index 4acd41a..6cbefca 100644 (file)
@@ -389,6 +389,7 @@ static const struct net_device_ops sis900_netdev_ops = {
        .ndo_set_multicast_list = set_rx_mode,
        .ndo_change_mtu         = eth_change_mtu,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_do_ioctl           = mii_ioctl,
        .ndo_tx_timeout         = sis900_tx_timeout,
 #ifdef CONFIG_NET_POLL_CONTROLLER
index 404b80e..8d36d40 100644 (file)
@@ -192,6 +192,7 @@ static const struct net_device_ops ultramca_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index b386608..2033fee 100644 (file)
@@ -196,6 +196,7 @@ static const struct net_device_ops ultra_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index dc3f110..020c583 100644 (file)
@@ -1740,6 +1740,7 @@ static const struct net_device_ops smsc911x_netdev_ops = {
        .ndo_set_multicast_list = smsc911x_set_multicast_list,
        .ndo_do_ioctl           = smsc911x_do_ioctl,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = smsc911x_poll_controller,
 #endif
index 27e017d..c14a4c6 100644 (file)
@@ -1551,6 +1551,7 @@ static const struct net_device_ops smsc9420_netdev_ops = {
        .ndo_set_multicast_list = smsc9420_set_multicast_list,
        .ndo_do_ioctl           = smsc9420_do_ioctl,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = smsc9420_poll_controller,
 #endif /* CONFIG_NET_POLL_CONTROLLER */
index ac07cc6..3b8e632 100644 (file)
@@ -622,6 +622,7 @@ static const struct net_device_ops rhine_netdev_ops = {
        .ndo_get_stats           = rhine_get_stats,
        .ndo_set_multicast_list  = rhine_set_rx_mode,
        .ndo_validate_addr       = eth_validate_addr,
+       .ndo_set_mac_address     = eth_mac_addr,
        .ndo_do_ioctl            = netdev_ioctl,
        .ndo_tx_timeout          = rhine_tx_timeout,
 #ifdef CONFIG_NET_POLL_CONTROLLER
index 58e25d0..a75f91d 100644 (file)
@@ -855,6 +855,7 @@ static const struct net_device_ops velocity_netdev_ops = {
        .ndo_start_xmit         = velocity_xmit,
        .ndo_get_stats          = velocity_get_stats,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_set_multicast_list = velocity_set_multi,
        .ndo_change_mtu         = velocity_change_mtu,
        .ndo_do_ioctl           = velocity_ioctl,
index 3c1edda..d8322d2 100644 (file)
@@ -155,6 +155,7 @@ static const struct net_device_ops wd_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,
index cf97129..2f1645d 100644 (file)
@@ -362,6 +362,7 @@ static const struct net_device_ops netdev_ops = {
        .ndo_set_multicast_list = set_rx_mode,
        .ndo_change_mtu         = eth_change_mtu,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_do_ioctl           = netdev_ioctl,
        .ndo_tx_timeout         = yellowfin_tx_timeout,
 };
index affd904..37c84e3 100644 (file)
@@ -147,6 +147,7 @@ static const struct net_device_ops zorro8390_netdev_ops = {
        .ndo_get_stats          = ei_get_stats,
        .ndo_set_multicast_list = ei_set_multicast_list,
        .ndo_validate_addr      = eth_validate_addr,
+       .ndo_set_mac_address    = eth_mac_addr,
        .ndo_change_mtu         = eth_change_mtu,
 #ifdef CONFIG_NET_POLL_CONTROLLER
        .ndo_poll_controller    = ei_poll,