Commit 4113a1a6 authored by Stephen Hemminger's avatar Stephen Hemminger Committed by David S. Miller

irda: convert w83977af_ir to net_device_ops

Signed-off-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 66ee279f
...@@ -140,6 +140,13 @@ static void __exit w83977af_cleanup(void) ...@@ -140,6 +140,13 @@ static void __exit w83977af_cleanup(void)
} }
} }
static const struct net_device_ops w83977_netdev_ops = {
.ndo_open = w83977af_net_open,
.ndo_stop = w83977af_net_close,
.ndo_start_xmit = w83977af_hard_xmit,
.ndo_do_ioctl = w83977af_net_ioctl,
};
/* /*
* Function w83977af_open (iobase, irq) * Function w83977af_open (iobase, irq)
* *
...@@ -231,11 +238,7 @@ static int w83977af_open(int i, unsigned int iobase, unsigned int irq, ...@@ -231,11 +238,7 @@ static int w83977af_open(int i, unsigned int iobase, unsigned int irq,
self->rx_buff.data = self->rx_buff.head; self->rx_buff.data = self->rx_buff.head;
self->netdev = dev; self->netdev = dev;
/* Override the network functions we need to use */ dev->netdev_ops = &w83977_netdev_ops;
dev->hard_start_xmit = w83977af_hard_xmit;
dev->open = w83977af_net_open;
dev->stop = w83977af_net_close;
dev->do_ioctl = w83977af_net_ioctl;
err = register_netdev(dev); err = register_netdev(dev);
if (err) { if (err) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment