aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/via-rhine.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2005-06-23 20:35:56 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-06-28 00:52:47 -0400
commitd18c3db58bc544fce6662ca7edba616ca9788a70 (patch)
treedd4c2d2c0bef6d47a32452112a9396a3137d8c10 /drivers/net/via-rhine.c
parent4002307d2b563a6ab317ca4d7eb1d201a6673d37 (diff)
[PATCH] PCI: make drivers use the pci shutdown callback instead of the driver core callback.
Now we can change the pci core to always set this pointer, as pci drivers should use it, not the driver core callback. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/net/via-rhine.c')
-rw-r--r--drivers/net/via-rhine.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/via-rhine.c b/drivers/net/via-rhine.c
index 6200cfc4244e..16212e69a49e 100644
--- a/drivers/net/via-rhine.c
+++ b/drivers/net/via-rhine.c
@@ -507,7 +507,7 @@ static struct net_device_stats *rhine_get_stats(struct net_device *dev);
507static int netdev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); 507static int netdev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd);
508static struct ethtool_ops netdev_ethtool_ops; 508static struct ethtool_ops netdev_ethtool_ops;
509static int rhine_close(struct net_device *dev); 509static int rhine_close(struct net_device *dev);
510static void rhine_shutdown (struct device *gdev); 510static void rhine_shutdown (struct pci_dev *pdev);
511 511
512#define RHINE_WAIT_FOR(condition) do { \ 512#define RHINE_WAIT_FOR(condition) do { \
513 int i=1024; \ 513 int i=1024; \
@@ -1895,9 +1895,8 @@ static void __devexit rhine_remove_one(struct pci_dev *pdev)
1895 pci_set_drvdata(pdev, NULL); 1895 pci_set_drvdata(pdev, NULL);
1896} 1896}
1897 1897
1898static void rhine_shutdown (struct device *gendev) 1898static void rhine_shutdown (struct pci_dev *pdev)
1899{ 1899{
1900 struct pci_dev *pdev = to_pci_dev(gendev);
1901 struct net_device *dev = pci_get_drvdata(pdev); 1900 struct net_device *dev = pci_get_drvdata(pdev);
1902 struct rhine_private *rp = netdev_priv(dev); 1901 struct rhine_private *rp = netdev_priv(dev);
1903 void __iomem *ioaddr = rp->base; 1902 void __iomem *ioaddr = rp->base;
@@ -1956,7 +1955,7 @@ static int rhine_suspend(struct pci_dev *pdev, pm_message_t state)
1956 pci_save_state(pdev); 1955 pci_save_state(pdev);
1957 1956
1958 spin_lock_irqsave(&rp->lock, flags); 1957 spin_lock_irqsave(&rp->lock, flags);
1959 rhine_shutdown(&pdev->dev); 1958 rhine_shutdown(pdev);
1960 spin_unlock_irqrestore(&rp->lock, flags); 1959 spin_unlock_irqrestore(&rp->lock, flags);
1961 1960
1962 free_irq(dev->irq, dev); 1961 free_irq(dev->irq, dev);
@@ -2010,9 +2009,7 @@ static struct pci_driver rhine_driver = {
2010 .suspend = rhine_suspend, 2009 .suspend = rhine_suspend,
2011 .resume = rhine_resume, 2010 .resume = rhine_resume,
2012#endif /* CONFIG_PM */ 2011#endif /* CONFIG_PM */
2013 .driver = { 2012 .shutdown = rhine_shutdown,
2014 .shutdown = rhine_shutdown,
2015 }
2016}; 2013};
2017 2014
2018 2015