diff options
author | Stephen Hemminger <shemminger@linux-foundation.org> | 2009-03-26 15:11:23 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-03-27 00:46:43 -0700 |
commit | 79f8ae3aa27f2f17a50ad1deee1e16ff02be01bb (patch) | |
tree | fe2c958bc84d06f00c2eb6b7df42e925bcdafa46 /drivers/net/tokenring/madgemc.c | |
parent | ddec2c89f89b9f2d15ddff07f01570123e95f544 (diff) | |
download | talos-op-linux-79f8ae3aa27f2f17a50ad1deee1e16ff02be01bb.tar.gz talos-op-linux-79f8ae3aa27f2f17a50ad1deee1e16ff02be01bb.zip |
tokenring: convert drivers to net_device_ops
Convert madge and proteon drivers which are really just subclasses
of tms380.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tokenring/madgemc.c')
-rw-r--r-- | drivers/net/tokenring/madgemc.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/net/tokenring/madgemc.c b/drivers/net/tokenring/madgemc.c index 193308118f95..456f8bff40be 100644 --- a/drivers/net/tokenring/madgemc.c +++ b/drivers/net/tokenring/madgemc.c @@ -142,7 +142,7 @@ static void madgemc_sifwritew(struct net_device *dev, unsigned short val, unsign return; } - +static struct net_device_ops madgemc_netdev_ops __read_mostly; static int __devinit madgemc_probe(struct device *device) { @@ -168,7 +168,7 @@ static int __devinit madgemc_probe(struct device *device) goto getout; } - dev->dma = 0; + dev->netdev_ops = &madgemc_netdev_ops; card = kmalloc(sizeof(struct card_info), GFP_KERNEL); if (card==NULL) { @@ -348,9 +348,6 @@ static int __devinit madgemc_probe(struct device *device) memcpy(tp->ProductID, "Madge MCA 16/4 ", PROD_ID_SIZE + 1); - dev->open = madgemc_open; - dev->stop = madgemc_close; - tp->tmspriv = card; dev_set_drvdata(device, dev); @@ -758,6 +755,10 @@ static struct mca_driver madgemc_driver = { static int __init madgemc_init (void) { + madgemc_netdev_ops = tms380tr_netdev_ops; + madgemc_netdev_ops.ndo_open = madgemc_open; + madgemc_netdev_ops.ndo_stop = madgemc_close; + return mca_register_driver (&madgemc_driver); } |