aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wan/farsync.c
diff options
context:
space:
mode:
authorKrzysztof Hałasa <khc@pm.waw.pl>2009-01-08 16:52:11 -0500
committerDavid S. Miller <davem@davemloft.net>2009-01-21 17:03:37 -0500
commit991990a12de42281f81b4e3a6471586d2d0caf6a (patch)
tree7b7ad34cf8218dab2ddd882a87b7c7a687b7d2ee /drivers/net/wan/farsync.c
parentdff3fde7be8f08c78914fca3d25e1cffe7625faa (diff)
WAN: Convert generic HDLC drivers to netdev_ops.
Also remove unneeded last_rx update from Synclink drivers. Synclink part mostly by Stephen Hemminger. Signed-off-by: Krzysztof Hałasa <khc@pm.waw.pl> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wan/farsync.c')
-rw-r--r--drivers/net/wan/farsync.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/drivers/net/wan/farsync.c b/drivers/net/wan/farsync.c
index 48a2c9d28950..00945f7c1e9b 100644
--- a/drivers/net/wan/farsync.c
+++ b/drivers/net/wan/farsync.c
@@ -2424,6 +2424,15 @@ fst_init_card(struct fst_card_info *card)
2424 type_strings[card->type], card->irq, card->nports); 2424 type_strings[card->type], card->irq, card->nports);
2425} 2425}
2426 2426
2427static const struct net_device_ops fst_ops = {
2428 .ndo_open = fst_open,
2429 .ndo_stop = fst_close,
2430 .ndo_change_mtu = hdlc_change_mtu,
2431 .ndo_start_xmit = hdlc_start_xmit,
2432 .ndo_do_ioctl = fst_ioctl,
2433 .ndo_tx_timeout = fst_tx_timeout,
2434};
2435
2427/* 2436/*
2428 * Initialise card when detected. 2437 * Initialise card when detected.
2429 * Returns 0 to indicate success, or errno otherwise. 2438 * Returns 0 to indicate success, or errno otherwise.
@@ -2565,12 +2574,9 @@ fst_add_one(struct pci_dev *pdev, const struct pci_device_id *ent)
2565 dev->base_addr = card->pci_conf; 2574 dev->base_addr = card->pci_conf;
2566 dev->irq = card->irq; 2575 dev->irq = card->irq;
2567 2576
2568 dev->tx_queue_len = FST_TX_QUEUE_LEN; 2577 dev->netdev_ops = &fst_ops;
2569 dev->open = fst_open; 2578 dev->tx_queue_len = FST_TX_QUEUE_LEN;
2570 dev->stop = fst_close; 2579 dev->watchdog_timeo = FST_TX_TIMEOUT;
2571 dev->do_ioctl = fst_ioctl;
2572 dev->watchdog_timeo = FST_TX_TIMEOUT;
2573 dev->tx_timeout = fst_tx_timeout;
2574 hdlc->attach = fst_attach; 2580 hdlc->attach = fst_attach;
2575 hdlc->xmit = fst_start_xmit; 2581 hdlc->xmit = fst_start_xmit;
2576 } 2582 }