aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/irda
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2009-03-20 15:35:41 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-21 22:33:47 -0400
commit30a5d7f7e3c77e3b00b8c981b7af4e5adc331353 (patch)
treedc29b4ec1cdec19907de58d5f1c13a0de1d76aa3 /drivers/net/irda
parent2d44a22254c1c4ad35a58e6d9d15a547d8841efc (diff)
irda: convert vlsi driver to net_device_ops
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/irda')
-rw-r--r--drivers/net/irda/vlsi_ir.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/drivers/net/irda/vlsi_ir.c b/drivers/net/irda/vlsi_ir.c
index 723c4588c803..1243bc8e0035 100644
--- a/drivers/net/irda/vlsi_ir.c
+++ b/drivers/net/irda/vlsi_ir.c
@@ -1573,6 +1573,14 @@ static int vlsi_close(struct net_device *ndev)
1573 return 0; 1573 return 0;
1574} 1574}
1575 1575
1576static const struct net_device_ops vlsi_netdev_ops = {
1577 .ndo_open = vlsi_open,
1578 .ndo_stop = vlsi_close,
1579 .ndo_start_xmit = vlsi_hard_start_xmit,
1580 .ndo_do_ioctl = vlsi_ioctl,
1581 .ndo_tx_timeout = vlsi_tx_timeout,
1582};
1583
1576static int vlsi_irda_init(struct net_device *ndev) 1584static int vlsi_irda_init(struct net_device *ndev)
1577{ 1585{
1578 vlsi_irda_dev_t *idev = netdev_priv(ndev); 1586 vlsi_irda_dev_t *idev = netdev_priv(ndev);
@@ -1608,11 +1616,7 @@ static int vlsi_irda_init(struct net_device *ndev)
1608 ndev->flags |= IFF_PORTSEL | IFF_AUTOMEDIA; 1616 ndev->flags |= IFF_PORTSEL | IFF_AUTOMEDIA;
1609 ndev->if_port = IF_PORT_UNKNOWN; 1617 ndev->if_port = IF_PORT_UNKNOWN;
1610 1618
1611 ndev->open = vlsi_open; 1619 ndev->netdev_ops = &vlsi_netdev_ops;
1612 ndev->stop = vlsi_close;
1613 ndev->hard_start_xmit = vlsi_hard_start_xmit;
1614 ndev->do_ioctl = vlsi_ioctl;
1615 ndev->tx_timeout = vlsi_tx_timeout;
1616 ndev->watchdog_timeo = 500*HZ/1000; /* max. allowed turn time for IrLAP */ 1620 ndev->watchdog_timeo = 500*HZ/1000; /* max. allowed turn time for IrLAP */
1617 1621
1618 SET_NETDEV_DEV(ndev, &pdev->dev); 1622 SET_NETDEV_DEV(ndev, &pdev->dev);