aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/macb.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-04-16 07:41:56 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-16 07:41:56 -0700
commitcd97824994042b809493807ea644ba26c0c23290 (patch)
tree705d9d069130330d4d9d2a23cd9ff99ec8187f28 /drivers/net/macb.c
parent3307f19f634dfb134b370c59a778fdb2d574c17b (diff)
parent3664090e199f10cb0282097faae8f8ca58c1e4ae (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (64 commits) phylib: Fix delay argument of schedule_delayed_work NET/ixgbe: Fix powering off during shutdown NET/e1000e: Fix powering off during shutdown NET/e1000: Fix powering off during shutdown packet: avoid warnings when high-order page allocation fails gianfar: stop send queue before resetting gianfar myr10ge: again fix lro_gen_skb() alignment declance: convert to net_device_ops bfin_mac: convert to net_device_ops au1000: convert to net_device_ops atarilance: convert to net_device_ops a2065: convert to net_device_ops ixgbe: update real_num_tx_queues on changing num_rx_queues ixgbe: fix tx queue index Revert "rose: zero length frame filtering in af_rose.c" sfc: Use correct macro to set event bitfield sfc: Match calls to netif_napi_add() and netif_napi_del() bonding: Remove debug printk e1000/e1000: fix compile warning ehea: Fix incomplete conversion to net_device_ops ...
Diffstat (limited to 'drivers/net/macb.c')
-rw-r--r--drivers/net/macb.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/net/macb.c b/drivers/net/macb.c
index f50501013b1..46073de290c 100644
--- a/drivers/net/macb.c
+++ b/drivers/net/macb.c
@@ -1100,6 +1100,18 @@ static int macb_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
return phy_mii_ioctl(phydev, if_mii(rq), cmd);
}
+static const struct net_device_ops macb_netdev_ops = {
+ .ndo_open = macb_open,
+ .ndo_stop = macb_close,
+ .ndo_start_xmit = macb_start_xmit,
+ .ndo_set_multicast_list = macb_set_rx_mode,
+ .ndo_get_stats = macb_get_stats,
+ .ndo_do_ioctl = macb_ioctl,
+ .ndo_validate_addr = eth_validate_addr,
+ .ndo_change_mtu = eth_change_mtu,
+ .ndo_set_mac_address = eth_mac_addr,
+};
+
static int __init macb_probe(struct platform_device *pdev)
{
struct eth_platform_data *pdata;
@@ -1175,12 +1187,7 @@ static int __init macb_probe(struct platform_device *pdev)
goto err_out_iounmap;
}
- dev->open = macb_open;
- dev->stop = macb_close;
- dev->hard_start_xmit = macb_start_xmit;
- dev->get_stats = macb_get_stats;
- dev->set_multicast_list = macb_set_rx_mode;
- dev->do_ioctl = macb_ioctl;
+ dev->netdev_ops = &macb_netdev_ops;
netif_napi_add(dev, &bp->napi, macb_poll, 64);
dev->ethtool_ops = &macb_ethtool_ops;