Skip to contentSkip to conversation

Replace pci_find_device with pci_dev_present

PATCH New [email protected] 1 participant 1 message Jun 20, 2005 libata

lore
Share & tools
lore
#0 lore raw

PATCH 2/6 Replace pci_find_device with pci_dev_present

From: Hanna Linder <[email protected]>

The dev returned from pci_find_device was not used so it can be replaced with pci_dev_present. Has been compile tested.

Hanna Linder
IBM Linux Technology Center

---
 alim15x3.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletion(-)
drivers/ide/pci/alim15x3.c +6 -1
Index: quilt/drivers/ide/pci/alim15x3.c
===================================================================
@@ -876,9 +876,14 @@ static ide_pci_device_t ali15x3_chipset 
  
 static int __devinit alim15x3_init_one(struct pci_dev *dev, const struct pci_device_id *id)
 {
+	static struct pci_device_id ati_rs100[] = {
+		{ PCI_DEVICE(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_RS100) },
+		{ },
+	};
+
 	ide_pci_device_t *d = &ali15x3_chipset;
 
-	if(pci_find_device(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_RS100, NULL))
+	if(pci_dev_present(ati_rs100))
 		printk(KERN_ERR "Warning: ATI Radeon IGP Northbridge is not yet fully tested.\n");
 
 #if defined(CONFIG_SPARC64)

--