1. 06 12月, 2011 1 次提交
  2. 15 11月, 2011 1 次提交
  3. 12 11月, 2011 2 次提交
  4. 08 11月, 2011 1 次提交
  5. 01 11月, 2011 5 次提交
  6. 28 10月, 2011 4 次提交
  7. 15 10月, 2011 10 次提交
    • J
      PCI: Add support for PASID capability · 086ac11f
      Joerg Roedel 提交于
      Devices supporting Process Address Space Identifiers
      (PASIDs) can use an IOMMU to access multiple IO address
      spaces at the same time. A PCIe device indicates support for
      this feature by implementing the PASID capability. This
      patch adds support for the capability to the Linux kernel.
      Reviewed-by: NBjorn Helgaas <bhelgaas@google.com>
      Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      086ac11f
    • J
      PCI: Add implementation for PRI capability · c320b976
      Joerg Roedel 提交于
      Implement the necessary functions to handle PRI capabilities
      on PCIe devices. With PRI devices behind an IOMMU can signal
      page fault conditions to software and recover from such
      faults.
      Reviewed-by: NBjorn Helgaas <bhelgaas@google.com>
      Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      c320b976
    • J
      PCI: Export ATS functions to modules · d4c0636c
      Joerg Roedel 提交于
      This patch makes the ATS functions usable for modules.
      They will be used by a module implementing some advanced
      AMD IOMMU features.
      Reviewed-by: NBjorn Helgaas <bhelgaas@google.com>
      Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      d4c0636c
    • J
      PCI: Move ATS implementation into own file · db3c33c6
      Joerg Roedel 提交于
      ATS does not depend on IOV support, so move the code into
      its own file. This file will also include support for the
      PRI and PASID capabilities later.
      Also give ATS its own Kconfig variable to allow selecting it
      without IOV support.
      Reviewed-by: NBjorn Helgaas <bhelgaas@google.com>
      Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      db3c33c6
    • R
      PCI / PM: Remove unnecessary error variable from acpi_dev_run_wake() · 78d090b0
      Rafael J. Wysocki 提交于
      The result returned by acpi_dev_run_wake() is always either -EINVAL
      or -ENODEV, while obviously it should return 0 on success.  The
      problem is that the leftover error variable, that's not really used
      in the function, is initialized with -ENODEV and then returned
      without modification.
      
      To fix this issue remove the error variable from acpi_dev_run_wake()
      and make the function return 0 on success as appropriate.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      78d090b0
    • P
      PCI hotplug: acpiphp: Prevent deadlock on PCI-to-PCI bridge remove · 6af8bef1
      Prarit Bhargava 提交于
      I originally submitted a patch to workaround this by pushing all Ejection
      Requests and Device Checks onto the kacpi_hotplug queue.
      
      http://marc.info/?l=linux-acpi&m=131678270930105&w=2
      
      The patch is still insufficient in that Bus Checks also need to be added.
      
      Rather than add all events, including non-PCI-hotplug events, to the
      hotplug queue, mjg suggested that a better approach would be to modify
      the acpiphp driver so only acpiphp events would be added to the
      kacpi_hotplug queue.
      
      It's a longer patch, but at least we maintain the benefit of having separate
      queues in ACPI.  This, of course, is still only a workaround the problem.
      As Bjorn and mjg pointed out, we have to refactor a lot of this code to do
      the right thing but at this point it is a better to have this code working.
      
      The acpi core places all events on the kacpi_notify queue.  When the acpiphp
      driver is loaded and a PCI card with a PCI-to-PCI bridge is removed the
      following call sequence occurs:
      
      cleanup_p2p_bridge()
      	    -> cleanup_bridge()
      		    -> acpi_remove_notify_handler()
      			    -> acpi_os_wait_events_complete()
      				    -> flush_workqueue(kacpi_notify_wq)
      
      which is the queue we are currently executing on and the process will hang.
      
      Move all hotplug acpiphp events onto the kacpi_hotplug workqueue.  In
      handle_hotplug_event_bridge() and handle_hotplug_event_func() we can simply
      push the rest of the work onto the kacpi_hotplug queue and then avoid the
      deadlock.
      Signed-off-by: NPrarit Bhargava <prarit@redhat.com>
      Cc: mjg@redhat.com
      Cc: bhelgaas@google.com
      Cc: linux-acpi@vger.kernel.org
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      6af8bef1
    • R
      PCI / PM: Extend PME polling to all PCI devices · 379021d5
      Rafael J. Wysocki 提交于
      The land of PCI power management is a land of sorrow and ugliness,
      especially in the area of signaling events by devices.  There are
      devices that set their PME Status bits, but don't really bother
      to send a PME message or assert PME#.  There are hardware vendors
      who don't connect PME# lines to the system core logic (they know
      who they are).  There are PCI Express Root Ports that don't bother
      to trigger interrupts when they receive PME messages from the devices
      below.  There are ACPI BIOSes that forget to provide _PRW methods for
      devices capable of signaling wakeup.  Finally, there are BIOSes that
      do provide _PRW methods for such devices, but then don't bother to
      call Notify() for those devices from the corresponding _Lxx/_Exx
      GPE-handling methods.  In all of these cases the kernel doesn't have
      a chance to receive a proper notification that it should wake up a
      device, so devices stay in low-power states forever.  Worse yet, in
      some cases they continuously send PME Messages that are silently
      ignored, because the kernel simply doesn't know that it should clear
      the device's PME Status bit.
      
      This problem was first observed for "parallel" (non-Express) PCI
      devices on add-on cards and Matthew Garrett addressed it by adding
      code that polls PME Status bits of such devices, if they are enabled
      to signal PME, to the kernel.  Recently, however, it has turned out
      that PCI Express devices are also affected by this issue and that it
      is not limited to add-on devices, so it seems necessary to extend
      the PME polling to all PCI devices, including PCI Express and planar
      ones.  Still, it would be wasteful to poll the PME Status bits of
      devices that are known to receive proper PME notifications, so make
      the kernel (1) poll the PME Status bits of all PCI and PCIe devices
      enabled to signal PME and (2) disable the PME Status polling for
      devices for which correct PME notifications are received.
      Tested-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      379021d5
    • J
      PCI quirk: mmc: Always check for lower base frequency quirk for Ricoh 1180:e823 · 3e309cdf
      Josh Boyer 提交于
      Commit 15bed0f2 added a quirk for the e823 Ricoh card reader to lower the
      base frequency.  However, the quirk first checks to see if the proprietary
      MMC controller is disabled, and returns if so.  On some devices, such as the
      Lenovo X220, the MMC controller is already disabled by firmware it seems,
      but the frequency change is still needed so sdhci-pci can talk to the cards.
      Since the MMC controller is disabled, the frequency fixup was never being run
      on these machines.
      
      This moves the e823 check above the MMC controller check so that it always
      gets run.
      
      This fixes https://bugzilla.redhat.com/show_bug.cgi?id=722509Signed-off-by: NJosh Boyer <jwboyer@redhat.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      3e309cdf
    • B
      PCI: Make pci_setup_bridge() non-static for use by arch code · e2444273
      Benjamin Herrenschmidt 提交于
      The "powernv" platform of the powerpc architecture needs to assign PCI
      resources using a specific algorithm to fit some HW constraints of
      the IBM "IODA" architecture (related to the ability to create error
      handling domains that encompass specific segments of MMIO space).
      
      For doing so, it wants to call pci_setup_bridge() from architecture
      specific resource management in order to configure bridges after all
      resources have been assigned. So make it non-static.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      e2444273
    • B
      PCI: Add quirk for known incorrect MPSS · a94d072b
      Ben Hutchings 提交于
      Using legacy interrupts and TLPs > 256 bytes on the SFC4000 (all
      revisions) may cause interrupt messages to be replayed.  In some
      systems this results in a non-recoverable MCE.  Early boards using the
      SFC4000 set the maximum payload size supported (MPSS) to 1024 bytes
      and we should override that.
      
      There are probably other devices with similar issues, so give this
      quirk a generic name.
      Signed-off-by: NBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      a94d072b
  8. 05 10月, 2011 1 次提交
  9. 21 9月, 2011 1 次提交
  10. 14 9月, 2011 1 次提交
  11. 10 9月, 2011 2 次提交
  12. 27 8月, 2011 1 次提交
    • K
      xen-pcifront: Update warning comment to use 'e820_host' option. · 917e3e65
      Konrad Rzeszutek Wilk 提交于
      With Xen changeset 23428 "libxl: Add 'e820_host' option to config file"
      the E820 as seen from the host can now be passed into the guest.
      This means that a PV guest can now:
       - Use the correct PCI I/O gap. Before these patches, Linux guest would
         boot up and would tell:
         [    0.000000] Allocating PCI resources starting at 40000000 (gap: 40000000:c0000000)
         while in actuality the PCI I/O gap should have been:
         [    0.000000] Allocating PCI resources starting at b0000000 (gap: b0000000:4c000000)
      
       - The PV domain with PCI devices was limited to 3GB. It now can be booted
         with 4GB, 8GB, or whatever number you want. The PCI devices will now _not_ conflict
         with System RAM. Meaning the drivers can load.
      
      CC: Jesse Barnes <jbarnes@virtuousgeek.org>
      CC: linux-pci@vger.kernel.org
      CC: stable@kernel.org
      [v2: Made the string less broken up. Suggested by Joe Perches]
      Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
      917e3e65
  13. 21 8月, 2011 1 次提交
  14. 19 8月, 2011 1 次提交
  15. 02 8月, 2011 7 次提交
    • J
      PCI: export pcie_bus_configure_settings symbol · debc3b77
      Jon Mason 提交于
      pcie_bus_configure_settings needs to be exported if the PCI hotplug
      driver is being compiled as a module.
      Reported-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NJon Mason <mason@myri.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      debc3b77
    • R
      PCI: code and comments cleanup · 9e8bf93a
      Ram Pai 提交于
      a) adjust_resource_sorted() is now called reassign_resource_sorted()
      b) nice-to-have is now called optional
      c) add_list is now called realloc_list.
      Signed-off-by: NRam Pai <linuxram@us.ibm.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      9e8bf93a
    • R
      PCI: make cardbus-bridge resources optional · 0a2daa1c
      Ram Pai 提交于
      Allocate resources to cardbus bridge only after all other genuine
      resources requests are satisfied. Dont retry if resource allocation
      for cardbus-bridges fail.
      Signed-off-by: NRam Pai <linuxram@us.ibm.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      0a2daa1c
    • Y
      PCI: make SRIOV resources optional · 2aceefcb
      Yinghai Lu 提交于
      From: Yinghai Lu <yinghai@kernel.org>
      
      Allocate resources to SRIOV BARs only after all other required
      resource-requests are satisfied. Dont retry if resource allocation for SRIOV
      BARs fail.
      Signed-off-by: NRam Pai <linuxram@us.ibm.com>
      Signed-off-by: NYinghai Lu <yinghai@kernel.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      2aceefcb
    • R
      PCI : ability to relocate assigned pci-resources · 2bbc6942
      Ram Pai 提交于
      Currently pci-bridges are allocated enough resources to satisfy their immediate
      requirements.  Any additional resource-requests fail if additional free space,
      contiguous to the one already allocated, is not available. This behavior is not
      reasonable since sufficient contiguous resources, that can satisfy the request,
      are available at a different location.
      
      This patch provides the ability to expand and relocate a allocated resource.
      
      	v2: Changelog: Fixed size calculation in pci_reassign_resource()
      	v3: Changelog : Split this patch. The resource.c changes are already
      			upstream. All the pci driver changes are in here.
      Signed-off-by: NRam Pai <linuxram@us.ibm.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      2bbc6942
    • Y
      PCI: honor child buses add_size in hot plug configuration · be768912
      Yinghai Lu 提交于
      git commit c8adf9a3
          "PCI: pre-allocate additional resources to devices only after
      	successful allocation of essential resources."
      
      fails to take into consideration the optional-resources needed by children
      devices while calculating the optional-resource needed by the bridge.
      
      This can be a problem on some setup. For example, if a hotplug bridge has 8
      children hotplug bridges, the bridge should have enough resources to accomodate
      the hotplug requirements for each of its children hotplug bridges.  Currently
      this is not the case.
      
      This patch fixes the problem.
      Signed-off-by: NYinghai Lu <yinghai@kernel.org>
      Reviewed-by: NRam Pai <linuxram@us.ibm.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      be768912
    • J
      PCI: Set PCI-E Max Payload Size on fabric · b03e7495
      Jon Mason 提交于
      On a given PCI-E fabric, each device, bridge, and root port can have a
      different PCI-E maximum payload size.  There is a sizable performance
      boost for having the largest possible maximum payload size on each PCI-E
      device.  However, if improperly configured, fatal bus errors can occur.
      Thus, it is important to ensure that PCI-E payloads sends by a device
      are never larger than the MPS setting of all devices on the way to the
      destination.
      
      This can be achieved two ways:
      
      - A conservative approach is to use the smallest common denominator of
        the entire tree below a root complex for every device on that fabric.
      
      This means for example that having a 128 bytes MPS USB controller on one
      leg of a switch will dramatically reduce performances of a video card or
      10GE adapter on another leg of that same switch.
      
      It also means that any hierarchy supporting hotplug slots (including
      expresscard or thunderbolt I suppose, dbl check that) will have to be
      entirely clamped to 128 bytes since we cannot predict what will be
      plugged into those slots, and we cannot change the MPS on a "live"
      system.
      
      - A more optimal way is possible, if it falls within a couple of
        constraints:
      * The top-level host bridge will never generate packets larger than the
        smallest TLP (or if it can be controlled independently from its MPS at
        least)
      * The device will never generate packets larger than MPS (which can be
        configured via MRRS)
      * No support of direct PCI-E <-> PCI-E transfers between devices without
        some additional code to specifically deal with that case
      
      Then we can use an approach that basically ignores downstream requests
      and focuses exclusively on upstream requests. In that case, all we need
      to care about is that a device MPS is no larger than its parent MPS,
      which allows us to keep all switches/bridges to the max MPS supported by
      their parent and eventually the PHB.
      
      In this case, your USB controller would no longer "starve" your 10GE
      Ethernet and your hotplug slots won't affect your global MPS.
      Additionally, the hotplugged devices themselves can be configured to a
      larger MPS up to the value configured in the hotplug bridge.
      
      To choose between the two available options, two PCI kernel boot args
      have been added to the PCI calls.  "pcie_bus_safe" will provide the
      former behavior, while "pcie_bus_perf" will perform the latter behavior.
      By default, the latter behavior is used.
      
      NOTE: due to the location of the enablement, each arch will need to add
      calls to this function.  This patch only enables x86.
      
      This patch includes a number of changes recommended by Benjamin
      Herrenschmidt.
      
      Tested-by: Jordan_Hargrave@dell.com
      Signed-off-by: NJon Mason <mason@myri.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      b03e7495
  16. 27 7月, 2011 1 次提交