diff options
author | Alexander Beregalov <a.beregalov@gmail.com> | 2009-04-15 08:52:49 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-04-16 05:20:16 -0400 |
commit | 0d3936a8b11b72e1387923342e33fdad553271d4 (patch) | |
tree | cce71e949a77ff69beec70491f4ce2a0d4dd6a95 | |
parent | 488b4abcd750c0a600eefa4d9ab42aad980ace11 (diff) |
macmace: 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/macmace.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/drivers/net/macmace.c b/drivers/net/macmace.c index 274e99bb63ac..44f3c2896f20 100644 --- a/drivers/net/macmace.c +++ b/drivers/net/macmace.c | |||
@@ -180,6 +180,17 @@ static void mace_dma_off(struct net_device *dev) | |||
180 | psc_write_word(PSC_ENETWR_CMD + PSC_SET1, 0x1100); | 180 | psc_write_word(PSC_ENETWR_CMD + PSC_SET1, 0x1100); |
181 | } | 181 | } |
182 | 182 | ||
183 | static const struct net_device_ops mace_netdev_ops = { | ||
184 | .ndo_open = mace_open, | ||
185 | .ndo_stop = mace_close, | ||
186 | .ndo_start_xmit = mace_xmit_start, | ||
187 | .ndo_tx_timeout = mace_tx_timeout, | ||
188 | .ndo_set_multicast_list = mace_set_multicast, | ||
189 | .ndo_set_mac_address = mace_set_address, | ||
190 | .ndo_change_mtu = eth_change_mtu, | ||
191 | .ndo_validate_addr = eth_validate_addr, | ||
192 | }; | ||
193 | |||
183 | /* | 194 | /* |
184 | * Not really much of a probe. The hardware table tells us if this | 195 | * Not really much of a probe. The hardware table tells us if this |
185 | * model of Macintrash has a MACE (AV macintoshes) | 196 | * model of Macintrash has a MACE (AV macintoshes) |
@@ -240,13 +251,8 @@ static int __devinit mace_probe(struct platform_device *pdev) | |||
240 | return -ENODEV; | 251 | return -ENODEV; |
241 | } | 252 | } |
242 | 253 | ||
243 | dev->open = mace_open; | 254 | dev->netdev_ops = &mace_netdev_ops; |
244 | dev->stop = mace_close; | ||
245 | dev->hard_start_xmit = mace_xmit_start; | ||
246 | dev->tx_timeout = mace_tx_timeout; | ||
247 | dev->watchdog_timeo = TX_TIMEOUT; | 255 | dev->watchdog_timeo = TX_TIMEOUT; |
248 | dev->set_multicast_list = mace_set_multicast; | ||
249 | dev->set_mac_address = mace_set_address; | ||
250 | 256 | ||
251 | printk(KERN_INFO "%s: 68K MACE, hardware address %pM\n", | 257 | printk(KERN_INFO "%s: 68K MACE, hardware address %pM\n", |
252 | dev->name, dev->dev_addr); | 258 | dev->name, dev->dev_addr); |