aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2009-03-20 15:35:46 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-21 22:33:50 -0400
commit0c818a6273218f5a827fe5f41f01caeb679b469e (patch)
tree8d9507a47fe373f46b1573c3f42a7505aa699138
parent9b634007d5694178c4e142fbc5f9dbcd767eafbd (diff)
irda: convert ksdazzle device to net_device_ops
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/irda/ksdazzle-sir.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/net/irda/ksdazzle-sir.c b/drivers/net/irda/ksdazzle-sir.c
index 5b327b09acd8..64df27f2bfd4 100644
--- a/drivers/net/irda/ksdazzle-sir.c
+++ b/drivers/net/irda/ksdazzle-sir.c
@@ -562,6 +562,13 @@ static int ksdazzle_net_ioctl(struct net_device *netdev, struct ifreq *rq,
562 return ret; 562 return ret;
563} 563}
564 564
565static const struct net_device_ops ksdazzle_ops = {
566 .ndo_start_xmit = ksdazzle_hard_xmit,
567 .ndo_open = ksdazzle_net_open,
568 .ndo_stop = ksdazzle_net_close,
569 .ndo_do_ioctl = ksdazzle_net_ioctl,
570};
571
565/* 572/*
566 * This routine is called by the USB subsystem for each new device 573 * This routine is called by the USB subsystem for each new device
567 * in the system. We need to check if the device is ours, and in 574 * in the system. We need to check if the device is ours, and in
@@ -684,10 +691,7 @@ static int ksdazzle_probe(struct usb_interface *intf,
684 irda_qos_bits_to_value(&kingsun->qos); 691 irda_qos_bits_to_value(&kingsun->qos);
685 692
686 /* Override the network functions we need to use */ 693 /* Override the network functions we need to use */
687 net->hard_start_xmit = ksdazzle_hard_xmit; 694 net->netdev_ops = &ksdazzle_ops;
688 net->open = ksdazzle_net_open;
689 net->stop = ksdazzle_net_close;
690 net->do_ioctl = ksdazzle_net_ioctl;
691 695
692 ret = register_netdev(net); 696 ret = register_netdev(net);
693 if (ret != 0) 697 if (ret != 0)