]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
PCI: Use pci_find_ht_capability() in drivers/pci/htirq.c
authorMichael Ellerman <michael@ellerman.id.au>
Wed, 22 Nov 2006 07:26:19 +0000 (18:26 +1100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 20 Dec 2006 18:54:42 +0000 (10:54 -0800)
Use pci_find_ht_capability() in drivers/pci/htirq.c

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/pci/htirq.c

index 0a8d1cce9fa09c733601f142436a7b39f231e3ff..279c940a00397444a8d49e03e1ec68386f78fc3c 100644 (file)
@@ -99,14 +99,7 @@ int __ht_create_irq(struct pci_dev *dev, int idx, ht_irq_update_t *update)
        int pos;
        int irq;
 
-       pos = pci_find_capability(dev, PCI_CAP_ID_HT);
-       while (pos) {
-               u8 subtype;
-               pci_read_config_byte(dev, pos + 3, &subtype);
-               if (subtype == HT_CAPTYPE_IRQ)
-                       break;
-               pos = pci_find_next_capability(dev, pos, PCI_CAP_ID_HT);
-       }
+       pos = pci_find_ht_capability(dev, HT_CAPTYPE_IRQ);
        if (!pos)
                return -EINVAL;