OSDN Git Service

s390/PCI: Use generic pci_enable_resources()
authorBjorn Helgaas <bhelgaas@google.com>
Wed, 26 Feb 2014 22:30:24 +0000 (15:30 -0700)
committerBjorn Helgaas <bhelgaas@google.com>
Wed, 19 Mar 2014 21:00:15 +0000 (15:00 -0600)
commitd75332325389a95c4ddbfa0f0cd7e5e08a54aa43
tree215ffeb7ab4e87b15d94cd22af1a4542c1d50a9e
parent05d58f6075bfab1f4ef424c6e5a3e22ecc09f015
s390/PCI: Use generic pci_enable_resources()

The generic pci_enable_resources() does essentially the same thing as the
code in the s390 version of pcibios_enable_device().

There are differences, but I don't think any of them are a problem.  The
generic code:

  - Checks everything up to PCI_NUM_RESOURCES, not PCI_BAR_COUNT (6), so
    we'll now check the ROM resource, IOV resources, and bridge windows.

  - Checks for res->flags & IORESOURCE_UNSET.  The s390 code never sets
    IORESOURCE_UNSET, so this isn't a problem.

  - Checks res->parent.  The s390 pcibios_add_device() calls
    pci_claim_resource() on all BARs (except ROM, IOV, and bridge windows)
    so this isn't a problem either.

Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
arch/s390/pci/pci.c