1. 30 9月, 2014 2 次提交
  2. 05 8月, 2014 2 次提交
    • G
      powerpc/powernv: Handle compound PE · 49dec922
      Gavin Shan 提交于
      The patch introduces 3 PHB callbacks: compound PE state retrieval,
      force freezing and unfreezing compound PE. The PCI config accessors
      and PowerNV EEH backend can use them in subsequent patches.
      
      We don't export the capability of compound PE to EEH core, which
      helps avoiding more complexity to EEH core.
      Signed-off-by: NGavin Shan <gwshan@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      49dec922
    • G
      powerpc/powernv: Enable M64 aperatus for PHB3 · 262af557
      Guo Chao 提交于
      This patch enables M64 aperatus for PHB3.
      
      We already had platform hook (ppc_md.pcibios_window_alignment) to affect
      the PCI resource assignment done in PCI core so that each PE's M32 resource
      was built on basis of M32 segment size. Similarly, we're using that for
      M64 assignment on basis of M64 segment size.
      
         * We're using last M64 BAR to cover M64 aperatus, and it's shared by all
           256 PEs.
         * We don't support P7IOC yet. However, some function callbacks are added
           to (struct pnv_phb) so that we can reuse them on P7IOC in future.
         * PE, corresponding to PCI bus with large M64 BAR device attached, might
           span multiple M64 segments. We introduce "compound" PE to cover the case.
           The compound PE is a list of PEs and the master PE is used as before.
           The slave PEs are just for MMIO isolation.
      Signed-off-by: NGuo Chao <yan@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      262af557
  3. 11 7月, 2014 1 次提交
  4. 28 4月, 2014 5 次提交
  5. 11 2月, 2014 1 次提交
    • B
      powerpc/powernv: Add iommu DMA bypass support for IODA2 · cd15b048
      Benjamin Herrenschmidt 提交于
      This patch adds the support for to create a direct iommu "bypass"
      window on IODA2 bridges (such as Power8) allowing to bypass iommu
      page translation completely for 64-bit DMA capable devices, thus
      significantly improving DMA performances.
      
      Additionally, this adds a hook to the struct iommu_table so that
      the IOMMU API / VFIO can disable the bypass when external ownership
      is requested, since in that case, the device will be used by an
      environment such as userspace or a KVM guest which must not be
      allowed to bypass translations.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      cd15b048
  6. 30 12月, 2013 1 次提交
  7. 05 12月, 2013 1 次提交
    • G
      powerpc/powernv: Move PHB-diag dump functions around · 93aef2a7
      Gavin Shan 提交于
      Prior to the completion of PCI enumeration, we actively detects
      EEH errors on PCI config cycles and dump PHB diag-data if necessary.
      The EEH backend also dumps PHB diag-data in case of frozen PE or
      fenced PHB. However, we are using different functions to dump the
      PHB diag-data for those 2 cases.
      
      The patch merges the functions for dumping PHB diag-data to one so
      that we can avoid duplicate code. Also, we never dump PHB3 diag-data
      during PCI config cycles with frozen PE. The patch fixes it as well.
      Signed-off-by: NGavin Shan <shangw@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      93aef2a7
  8. 06 11月, 2013 1 次提交
    • G
      powerpc/powernv: Reserve the correct PE number · 36954dc7
      Gavin Shan 提交于
      We're assigning PE numbers after the completion of PCI probe. During
      the PCI probe, we had PE#0 as the super container to encompass all
      PCI devices. However, that's inappropriate since PELTM has ascending
      order of priority on search on P7IOC. So we need PE#127 takes the
      role that PE#0 has previously. For PHB3, we still have PE#0 as the
      reserved PE.
      
      The patch supposes that the underly firmware has built the RID to
      PE# mapping after resetting IODA tables: all PELTM entries except
      last one has invalid mapping on P7IOC, but all RTEs have binding
      to PE#0. The reserved PE# is being exported by firmware by device
      tree.
      Signed-off-by: NGavin Shan <shangw@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      36954dc7
  9. 11 10月, 2013 3 次提交
  10. 01 7月, 2013 2 次提交
  11. 21 6月, 2013 1 次提交
  12. 20 6月, 2013 2 次提交
  13. 10 5月, 2013 1 次提交
  14. 26 4月, 2013 3 次提交
  15. 18 4月, 2013 1 次提交
  16. 17 9月, 2012 2 次提交
  17. 07 12月, 2011 1 次提交
  18. 25 11月, 2011 1 次提交
    • B
      powerpc/powernv: PCI support for p7IOC under OPAL v2 · 184cd4a3
      Benjamin Herrenschmidt 提交于
      This adds support for p7IOC (and possibly other IODA v1 IO Hubs)
      using OPAL v2 interfaces.
      
      We completely take over resource assignment and assign them using an
      algorithm that hands out device BARs in a way that makes them fit in
      individual segments of the M32 window of the bridge, which enables us
      to assign individual PEs to devices and functions.
      
      The current implementation gives out a PE per functions on PCIe, and a
      PE for the entire bridge for PCIe to PCI-X bridges.
      
      This can be adjusted / fine tuned later.
      
      We also setup DMA resources (32-bit only for now) and MSIs (both 32-bit
      and 64-bit MSI are supported).
      
      The DMA allocation tries to divide the available 256M segments of the
      32-bit DMA address space "fairly" among PEs. This is done using a
      "weight" heuristic which assigns less value to things like OHCI USB
      controllers than, for example SCSI RAID controllers. This algorithm
      will probably want some fine tuning for specific devices or device
      types.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      184cd4a3
  19. 20 9月, 2011 2 次提交