diff options
author | Alexander Beregalov <a.beregalov@gmail.com> | 2009-04-15 08:52:51 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-04-16 05:20:18 -0400 |
commit | d6771e0b895f04e8bbd12f12fb3a97e130a4a5f4 (patch) | |
tree | ac818aae98d8cce4d704ca9cfaf28d907eea2e34 | |
parent | d53bc2df189f1e11a947eed077f0360bfadf9986 (diff) |
mipsnet: convert to net_device_ops
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/mipsnet.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/drivers/net/mipsnet.c b/drivers/net/mipsnet.c index 664835b822fb..b3b9a147d09a 100644 --- a/drivers/net/mipsnet.c +++ b/drivers/net/mipsnet.c | |||
@@ -237,6 +237,16 @@ static void mipsnet_set_mclist(struct net_device *dev) | |||
237 | { | 237 | { |
238 | } | 238 | } |
239 | 239 | ||
240 | static const struct net_device_ops mipsnet_netdev_ops = { | ||
241 | .ndo_open = mipsnet_open, | ||
242 | .ndo_stop = mipsnet_close, | ||
243 | .ndo_start_xmit = mipsnet_xmit, | ||
244 | .ndo_set_multicast_list = mipsnet_set_mclist, | ||
245 | .ndo_change_mtu = eth_change_mtu, | ||
246 | .ndo_validate_addr = eth_validate_addr, | ||
247 | .ndo_set_mac_address = eth_mac_addr, | ||
248 | }; | ||
249 | |||
240 | static int __init mipsnet_probe(struct platform_device *dev) | 250 | static int __init mipsnet_probe(struct platform_device *dev) |
241 | { | 251 | { |
242 | struct net_device *netdev; | 252 | struct net_device *netdev; |
@@ -250,10 +260,7 @@ static int __init mipsnet_probe(struct platform_device *dev) | |||
250 | 260 | ||
251 | platform_set_drvdata(dev, netdev); | 261 | platform_set_drvdata(dev, netdev); |
252 | 262 | ||
253 | netdev->open = mipsnet_open; | 263 | netdev->netdev_ops = &mipsnet_netdev_ops; |
254 | netdev->stop = mipsnet_close; | ||
255 | netdev->hard_start_xmit = mipsnet_xmit; | ||
256 | netdev->set_multicast_list = mipsnet_set_mclist; | ||
257 | 264 | ||
258 | /* | 265 | /* |
259 | * TODO: probe for these or load them from PARAM | 266 | * TODO: probe for these or load them from PARAM |