1. 17 4月, 2013 4 次提交
    • B
      Merge branch 'pci/jiang-subdrivers' into next · a3b6bbd5
      Bjorn Helgaas 提交于
      * pci/jiang-subdrivers:
        PCI/ACPI: Remove support of ACPI PCI subdrivers
        PCI: acpiphp: Protect acpiphp data structures from concurrent updates
        PCI: acpiphp: Use normal list to simplify implementation
        PCI: acpiphp: Do not use ACPI PCI subdriver mechanism
        PCI: acpiphp: Convert acpiphp to be builtin only, not modular
        PCI/ACPI: Handle PCI slot devices when creating/destroying PCI buses
        x86/PCI: Implement pcibios_{add|remove}_bus() hooks
        ia64/PCI: Implement pcibios_{add|remove}_bus() hooks
        PCI/ACPI: Prepare stub functions to handle ACPI PCI (hotplug) slots
        PCI: Add pcibios hooks for adding and removing PCI buses
        PCI: acpiphp: Replace local macros with standard ACPI macros
        PCI: acpiphp: Remove all functions even if function 0 doesn't exist
        PCI: acpiphp: Use list_for_each_entry_safe() in acpiphp_sanitize_bus()
        PCI: Clean up usages of pci_bus->is_added
        PCI: When removing bus, always remove legacy files & unregister
      a3b6bbd5
    • M
      PCI/ACPI: Remove support of ACPI PCI subdrivers · c309dbb4
      Myron Stowe 提交于
      Both sub-drivers of the "PCI Root Bridge ("pci_bridge")" driver, "acpiphp"
      and "pci_slot", have been converted to hook directly into the PCI core.
      
      With the conversions there are no remaining usages of the 'struct
      acpi_pci_driver' list based infrastructure.  This patch removes it.
      Signed-off-by: NMyron Stowe <myron.stowe@redhat.com>
      Signed-off-by: NJiang Liu <jiang.liu@huawei.com>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      Reviewed-by: NYinghai Lu <yinghai@kernel.org>
      Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
      Cc: Toshi Kani <toshi.kani@hp.com>
      c309dbb4
    • J
      PCI: acpiphp: Protect acpiphp data structures from concurrent updates · 3d54a316
      Jiang Liu 提交于
      Now acpiphp_enumerate_slots() and acpiphp_remove_slots() may be invoked
      concurrently by the PCI core, so add a bridge_mutex and reference count
      mechanism to protect acpiphp bridge/slot/function data structures.
      
      To avoid deadlock, handle_hotplug_event_bridge() will requeue the
      hotplug event onto the kacpi_hotplug_wq by calling alloc_acpi_hp_work().
      But the workaround has introduced a minor race window because the
      'bridge' passed to _handle_hotplug_event_bridge() may have already been
      destroyed when _handle_hotplug_event_bridge() is actually executed by
      the kacpi_hotplug_wq.  So hold a reference count on the passed 'bridge'.
      Fix the same issue for handle_hotplug_event_func() too.
      Signed-off-by: NJiang Liu <jiang.liu@huawei.com>
      Signed-off-by: NYijing Wang <wangyijing@huawei.com>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      Reviewed-by: NYinghai Lu <yinghai@kernel.org>
      Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
      Cc: Toshi Kani <toshi.kani@hp.com>
      3d54a316
    • Y
      PCI: acpiphp: Use normal list to simplify implementation · ad41dd9d
      Yijing Wang 提交于
      Use normal list for struct acpiphp_slot to simplify implementation.
      Signed-off-by: NYijing Wang <wangyijing@huawei.com>
      Signed-off-by: NJiang Liu <jiang.liu@huawei.com>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      Reviewed-by: NYinghai Lu <yinghai@kernel.org>
      Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
      Cc: Toshi Kani <toshi.kani@hp.com>
      ad41dd9d
  2. 16 4月, 2013 15 次提交
  3. 13 4月, 2013 12 次提交
  4. 11 4月, 2013 1 次提交
    • G
      MIPS/PCI: Implement pcibios_get_phb_of_node · 9a97cd43
      Gabor Juhos 提交于
      The of_node field of the device assigned to a
      PCI bus is used during scanning of the PCI bus.
      However on MIPS, the of_node field is assigned
      only after the bus has been scanned.
      
      Implement the architecture specific version of
      'pcibios_get_phb_of_node'. Which ensures that the
      PCI driver core will initialize the of_node field
      before starting the scan.
      
      Also remove the local assignment of bus->dev.of_node,
      it is not needed after the patch.
      Signed-off-by: NGabor Juhos <juhosg@openwrt.org>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      9a97cd43
  5. 10 4月, 2013 1 次提交
    • B
      PCI: Remove __weak annotation from pcibios_get_phb_of_node decl · 10629d71
      Bjorn Helgaas 提交于
      The __weak annotation on the pcibios_get_phb_of_node() declaration
      causes *every* definition to be marked "weak."  The linker then
      selects one based on link order, which may be the wrong one.
      
      Gabor found that on MIPS, the linker selected the generic implementation
      from drivers/pci even though arch/mips supplied a definition without the
      __weak annotation:
      
      $ mipsel-openwrt-linux-readelf -s arch/mips/pci/built-in.o \
          drivers/pci/built-in.o vmlinux.o | grep pcibios_get_phb_of_node
            86: 0000046c    12 FUNC    WEAK   DEFAULT    2 pcibios_get_phb_of_node
          1430: 00012e2c   104 FUNC    WEAK   DEFAULT    2 pcibios_get_phb_of_node
         31898: 0017e4ec   104 FUNC    WEAK   DEFAULT    2 pcibios_get_phb_of_node
      
      This removes the __weak annotation from the pcibios_get_phb_of_node()
      declaration so arch-specific non-weak implementations work reliably.
      Suggested-by: NGabor Juhos <juhosg@openwrt.org>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      10629d71
  6. 05 4月, 2013 1 次提交
  7. 04 4月, 2013 1 次提交
  8. 29 3月, 2013 1 次提交
    • B
      Merge branch 'pci/shuah-defines' into next · 83326063
      Bjorn Helgaas 提交于
      * pci/shuah-defines:
        iommu/amd: Remove calc_devid() and use PCI_DEVID() from PCI
        iommu/amd: Remove local PCI_BUS() define and use PCI_BUS_NUM() from PCI
        PCI/AER: Remove local PCI_BUS() define and use PCI_BUS_NUM() from PCI
        PCI: Add PCI_BUS_NUM() and PCI_DEVID() interfaces
      83326063
  9. 27 3月, 2013 4 次提交