aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAlexander Beregalov <a.beregalov@gmail.com>2009-04-15 08:52:40 -0400
committerDavid S. Miller <davem@davemloft.net>2009-04-16 05:20:11 -0400
commit602355a03508bf54dbf113234ef72d75080a492d (patch)
tree43c3fdccda4867a2e3959bc0b4ebc4218d2b30b3 /drivers
parente186d174e04a7c79606e1ee57abb7470861b3b00 (diff)
irda/au1k_ir: convert to net_device_ops
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/irda/au1k_ir.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/drivers/net/irda/au1k_ir.c b/drivers/net/irda/au1k_ir.c
index 941164076a2b..204def0f6451 100644
--- a/drivers/net/irda/au1k_ir.c
+++ b/drivers/net/irda/au1k_ir.c
@@ -198,6 +198,17 @@ static int au1k_irda_init_iobuf(iobuff_t *io, int size)
198 return io->head ? 0 : -ENOMEM; 198 return io->head ? 0 : -ENOMEM;
199} 199}
200 200
201static const struct net_device_ops au1k_irda_netdev_ops = {
202 .ndo_open = au1k_irda_start,
203 .ndo_stop = au1k_irda_stop,
204 .ndo_start_xmit = au1k_irda_hard_xmit,
205 .ndo_tx_timeout = au1k_tx_timeout,
206 .ndo_do_ioctl = au1k_irda_ioctl,
207 .ndo_change_mtu = eth_change_mtu,
208 .ndo_validate_addr = eth_validate_addr,
209 .ndo_set_mac_address = eth_mac_addr,
210};
211
201static int au1k_irda_net_init(struct net_device *dev) 212static int au1k_irda_net_init(struct net_device *dev)
202{ 213{
203 struct au1k_private *aup = netdev_priv(dev); 214 struct au1k_private *aup = netdev_priv(dev);
@@ -209,11 +220,7 @@ static int au1k_irda_net_init(struct net_device *dev)
209 if (err) 220 if (err)
210 goto out1; 221 goto out1;
211 222
212 dev->open = au1k_irda_start; 223 dev->netdev_ops = &au1k_irda_netdev_ops;
213 dev->hard_start_xmit = au1k_irda_hard_xmit;
214 dev->stop = au1k_irda_stop;
215 dev->do_ioctl = au1k_irda_ioctl;
216 dev->tx_timeout = au1k_tx_timeout;
217 224
218 irda_init_max_qos_capabilies(&aup->qos); 225 irda_init_max_qos_capabilies(&aup->qos);
219 226