diff options
author | Francois Romieu <romieu@electric-eye.fr.zoreil.com> | 2006-02-16 16:17:00 -0500 |
---|---|---|
committer | Francois Romieu <romieu@electric-eye.fr.zoreil.com> | 2006-02-16 16:17:00 -0500 |
commit | 10487fbd74f2f9c9b5fb2d77efd50eab48db191a (patch) | |
tree | 034764d5b871717b543b7236369876ba2b6c5aaf /drivers/net/sis190.c | |
parent | 26d451b603e754ded83f0e5becab2a78253ad100 (diff) |
sis190: early setting of the pci driver private data
Below this point, the error path will proceed through
sis190_release_board(). It will happily oops if
pci_set_drvdata() has not been issued.
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Diffstat (limited to 'drivers/net/sis190.c')
-rw-r--r-- | drivers/net/sis190.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/sis190.c b/drivers/net/sis190.c index b420182eec4b..ed4bc91638d2 100644 --- a/drivers/net/sis190.c +++ b/drivers/net/sis190.c | |||
@@ -1791,6 +1791,8 @@ static int __devinit sis190_init_one(struct pci_dev *pdev, | |||
1791 | goto out; | 1791 | goto out; |
1792 | } | 1792 | } |
1793 | 1793 | ||
1794 | pci_set_drvdata(pdev, dev); | ||
1795 | |||
1794 | tp = netdev_priv(dev); | 1796 | tp = netdev_priv(dev); |
1795 | ioaddr = tp->mmio_addr; | 1797 | ioaddr = tp->mmio_addr; |
1796 | 1798 | ||
@@ -1827,8 +1829,6 @@ static int __devinit sis190_init_one(struct pci_dev *pdev, | |||
1827 | if (rc < 0) | 1829 | if (rc < 0) |
1828 | goto err_remove_mii; | 1830 | goto err_remove_mii; |
1829 | 1831 | ||
1830 | pci_set_drvdata(pdev, dev); | ||
1831 | |||
1832 | net_probe(tp, KERN_INFO "%s: %s at %p (IRQ: %d), " | 1832 | net_probe(tp, KERN_INFO "%s: %s at %p (IRQ: %d), " |
1833 | "%2.2x:%2.2x:%2.2x:%2.2x:%2.2x:%2.2x\n", | 1833 | "%2.2x:%2.2x:%2.2x:%2.2x:%2.2x:%2.2x\n", |
1834 | pci_name(pdev), sis_chip_info[ent->driver_data].name, | 1834 | pci_name(pdev), sis_chip_info[ent->driver_data].name, |