diff options
author | David S. Miller <davem@davemloft.net> | 2009-03-05 02:06:47 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-03-05 02:06:47 -0800 |
commit | 508827ff0ac3981d420edac64a70de7f4e304d38 (patch) | |
tree | b0cee8ddef9f0ceab68c388e4ae46b7295eb2cb5 /drivers/net/tokenring | |
parent | 2c3c3d02f28801d7ad2da4952b2c7ca6621ef221 (diff) | |
parent | 72e2240f181871675d3a979766330c91d48a1673 (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts:
drivers/net/tokenring/tmspci.c
drivers/net/ucc_geth_mii.c
Diffstat (limited to 'drivers/net/tokenring')
-rw-r--r-- | drivers/net/tokenring/tmspci.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/net/tokenring/tmspci.c b/drivers/net/tokenring/tmspci.c index b397e8785d6..f92fe86fdca 100644 --- a/drivers/net/tokenring/tmspci.c +++ b/drivers/net/tokenring/tmspci.c @@ -121,11 +121,6 @@ static int __devinit tms_pci_attach(struct pci_dev *pdev, const struct pci_devic goto err_out_trdev; } - ret = request_irq(pdev->irq, tms380tr_interrupt, IRQF_SHARED, - dev->name, dev); - if (ret) - goto err_out_region; - dev->base_addr = pci_ioaddr; dev->irq = pci_irq_line; dev->dma = 0; @@ -142,7 +137,7 @@ static int __devinit tms_pci_attach(struct pci_dev *pdev, const struct pci_devic ret = tmsdev_init(dev, &pdev->dev); if (ret) { printk("%s: unable to get memory for dev->priv.\n", dev->name); - goto err_out_irq; + goto err_out_region; } tp = netdev_priv(dev); @@ -159,20 +154,25 @@ static int __devinit tms_pci_attach(struct pci_dev *pdev, const struct pci_devic dev->netdev_ops = &tms380tr_netdev_ops; + ret = request_irq(pdev->irq, tms380tr_interrupt, IRQF_SHARED, + dev->name, dev); + if (ret) + goto err_out_tmsdev; + pci_set_drvdata(pdev, dev); SET_NETDEV_DEV(dev, &pdev->dev); ret = register_netdev(dev); if (ret) - goto err_out_tmsdev; + goto err_out_irq; return 0; +err_out_irq: + free_irq(pdev->irq, dev); err_out_tmsdev: pci_set_drvdata(pdev, NULL); tmsdev_term(dev); -err_out_irq: - free_irq(pdev->irq, dev); err_out_region: release_region(pci_ioaddr, TMS_PCI_IO_EXTENT); err_out_trdev: |