diff options
author | Stephen Hemminger <shemminger@linux-foundation.org> | 2009-01-09 08:01:25 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-01-21 17:02:30 -0500 |
commit | f1608f859a3fba95a3b0ae70f2528b81c6928d77 (patch) | |
tree | 4cb19e2f821c5c868c21b1e63ba208b21fd6c62a /drivers/net/tokenring/abyss.c | |
parent | efda072393fb4213e43d92bdd20cf180a06a8eb0 (diff) |
tms380tr: convert to net_device_ops
Conver this related group of drivers to new API
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tokenring/abyss.c')
-rw-r--r-- | drivers/net/tokenring/abyss.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/net/tokenring/abyss.c b/drivers/net/tokenring/abyss.c index b566d6d79ecd..b9db1b5a58a3 100644 --- a/drivers/net/tokenring/abyss.c +++ b/drivers/net/tokenring/abyss.c | |||
@@ -92,6 +92,8 @@ static void abyss_sifwritew(struct net_device *dev, unsigned short val, unsigned | |||
92 | outw(val, dev->base_addr + reg); | 92 | outw(val, dev->base_addr + reg); |
93 | } | 93 | } |
94 | 94 | ||
95 | static struct net_device_ops abyss_netdev_ops; | ||
96 | |||
95 | static int __devinit abyss_attach(struct pci_dev *pdev, const struct pci_device_id *ent) | 97 | static int __devinit abyss_attach(struct pci_dev *pdev, const struct pci_device_id *ent) |
96 | { | 98 | { |
97 | static int versionprinted; | 99 | static int versionprinted; |
@@ -157,8 +159,7 @@ static int __devinit abyss_attach(struct pci_dev *pdev, const struct pci_device_ | |||
157 | 159 | ||
158 | memcpy(tp->ProductID, "Madge PCI 16/4 Mk2", PROD_ID_SIZE + 1); | 160 | memcpy(tp->ProductID, "Madge PCI 16/4 Mk2", PROD_ID_SIZE + 1); |
159 | 161 | ||
160 | dev->open = abyss_open; | 162 | dev->netdev_ops = &abyss_netdev_ops; |
161 | dev->stop = abyss_close; | ||
162 | 163 | ||
163 | pci_set_drvdata(pdev, dev); | 164 | pci_set_drvdata(pdev, dev); |
164 | SET_NETDEV_DEV(dev, &pdev->dev); | 165 | SET_NETDEV_DEV(dev, &pdev->dev); |
@@ -450,6 +451,11 @@ static struct pci_driver abyss_driver = { | |||
450 | 451 | ||
451 | static int __init abyss_init (void) | 452 | static int __init abyss_init (void) |
452 | { | 453 | { |
454 | abyss_netdev_ops = tms380tr_netdev_ops; | ||
455 | |||
456 | abyss_netdev_ops.ndo_open = abyss_open; | ||
457 | abyss_netdev_ops.ndo_stop = abyss_close; | ||
458 | |||
453 | return pci_register_driver(&abyss_driver); | 459 | return pci_register_driver(&abyss_driver); |
454 | } | 460 | } |
455 | 461 | ||