Skip to content

Commit

Permalink
[PATCH] sis5513: Switch to pci refcounting
Browse files Browse the repository at this point in the history
Mirrors the drivers/ata version, hold a reference to the host bridge while we
are doing setup.

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Alan Cox authored and Linus Torvalds committed Oct 1, 2006
1 parent 970a613 commit 40cddf2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/ide/pci/sis5513.c
Original file line number Diff line number Diff line change
Expand Up @@ -739,7 +739,7 @@ static unsigned int __devinit init_chipset_sis5513 (struct pci_dev *dev, const c

for (i = 0; i < ARRAY_SIZE(SiSHostChipInfo) && !chipset_family; i++) {

host = pci_find_device(PCI_VENDOR_ID_SI, SiSHostChipInfo[i].host_id, NULL);
host = pci_get_device(PCI_VENDOR_ID_SI, SiSHostChipInfo[i].host_id, NULL);

if (!host)
continue;
Expand All @@ -753,6 +753,7 @@ static unsigned int __devinit init_chipset_sis5513 (struct pci_dev *dev, const c
if (hostrev >= 0x30)
chipset_family = ATA_100a;
}
pci_dev_put(host);

printk(KERN_INFO "SIS5513: %s %s controller\n",
SiSHostChipInfo[i].name, chipset_capability[chipset_family]);
Expand Down

0 comments on commit 40cddf2

Please sign in to comment.