1. 10 6月, 2021 1 次提交
  2. 07 4月, 2021 2 次提交
  3. 18 3月, 2021 1 次提交
  4. 04 2月, 2021 2 次提交
  5. 28 1月, 2021 1 次提交
  6. 07 1月, 2021 2 次提交
  7. 18 11月, 2020 1 次提交
  8. 18 9月, 2020 2 次提交
  9. 16 9月, 2020 1 次提交
    • T
      iommm/vt-d: Store irq domain in struct device · 85a8dfc5
      Thomas Gleixner 提交于
      As a first step to make X86 utilize the direct MSI irq domain operations
      store the irq domain pointer in the device struct when a device is probed.
      
      This is done from dmar_pci_bus_add_dev() because it has to work even when
      DMA remapping is disabled. It only overrides the irqdomain of devices which
      are handled by a regular PCI/MSI irq domain which protects PCI devices
      behind special busses like VMD which have their own irq domain.
      
      No functional change. It just avoids the redirection through
      arch_*_msi_irqs() and allows the PCI/MSI core to directly invoke the irq
      domain alloc/free functions instead of having to look up the irq domain for
      every single MSI interupt.
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      Acked-by: NJoerg Roedel <jroedel@suse.de>
      Link: https://lore.kernel.org/r/20200826112333.714566121@linutronix.de
      85a8dfc5
  10. 04 9月, 2020 1 次提交
  11. 24 7月, 2020 5 次提交
  12. 23 6月, 2020 1 次提交
  13. 29 5月, 2020 1 次提交
  14. 18 5月, 2020 10 次提交
  15. 13 3月, 2020 1 次提交
  16. 07 1月, 2020 4 次提交
    • L
      iommu/vt-d: debugfs: Add support to show page table internals · e2726dae
      Lu Baolu 提交于
      Export page table internals of the domain attached to each device.
      Example of such dump on a Skylake machine:
      
      $ sudo cat /sys/kernel/debug/iommu/intel/domain_translation_struct
      [ ... ]
      Device 0000:00:14.0 with pasid 0 @0x15f3d9000
      IOVA_PFN                PML5E                   PML4E
      0x000000008ced0 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced1 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced2 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced3 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced4 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced5 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced6 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced7 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced8 |       0x0000000000000000      0x000000015f3da003
      0x000000008ced9 |       0x0000000000000000      0x000000015f3da003
      
      PDPE                    PDE                     PTE
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced0003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced1003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced2003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced3003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced4003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced5003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced6003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced7003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced8003
      0x000000015f3db003      0x000000015f3dc003      0x000000008ced9003
      [ ... ]
      Signed-off-by: NLu Baolu <baolu.lu@linux.intel.com>
      Signed-off-by: NJoerg Roedel <jroedel@suse.de>
      e2726dae
    • L
      iommu/vt-d: Flush PASID-based iotlb for iova over first level · 33cd6e64
      Lu Baolu 提交于
      When software has changed first-level tables, it should invalidate
      the affected IOTLB and the paging-structure-caches using the PASID-
      based-IOTLB Invalidate Descriptor defined in spec 6.5.2.4.
      Signed-off-by: NLu Baolu <baolu.lu@linux.intel.com>
      Signed-off-by: NJoerg Roedel <jroedel@suse.de>
      33cd6e64
    • L
      iommu/vt-d: Setup pasid entries for iova over first level · ddf09b6d
      Lu Baolu 提交于
      Intel VT-d in scalable mode supports two types of page tables for
      IOVA translation: first level and second level. The IOMMU driver
      can choose one from both for IOVA translation according to the use
      case. This sets up the pasid entry if a domain is selected to use
      the first-level page table for iova translation.
      Signed-off-by: NLu Baolu <baolu.lu@linux.intel.com>
      Signed-off-by: NJoerg Roedel <jroedel@suse.de>
      ddf09b6d
    • J
      iommu/vt-d: Fix CPU and IOMMU SVM feature matching checks · ff3dc652
      Jacob Pan 提交于
      Shared Virtual Memory(SVM) is based on a collective set of hardware
      features detected at runtime. There are requirements for matching CPU
      and IOMMU capabilities.
      
      The current code checks CPU and IOMMU feature set for SVM support but
      the result is never stored nor used. Therefore, SVM can still be used
      even when these checks failed. The consequences can be:
      1. CPU uses 5-level paging mode for virtual address of 57 bits, but
      IOMMU can only support 4-level paging mode with 48 bits address for DMA.
      2. 1GB page size is used by CPU but IOMMU does not support it. VT-d
      unrecoverable faults may be generated.
      
      The best solution to fix these problems is to prevent them in the first
      place.
      
      This patch consolidates code for checking PASID, CPU vs. IOMMU paging
      mode compatibility, as well as provides specific error messages for
      each failed checks. On sane hardware configurations, these error message
      shall never appear in kernel log.
      Signed-off-by: NJacob Pan <jacob.jun.pan@linux.intel.com>
      Reviewed-by: NEric Auger <eric.auger@redhat.com>
      Signed-off-by: NLu Baolu <baolu.lu@linux.intel.com>
      Signed-off-by: NJoerg Roedel <jroedel@suse.de>
      ff3dc652
  17. 11 11月, 2019 1 次提交
  18. 11 9月, 2019 1 次提交
  19. 03 9月, 2019 1 次提交
    • J
      iommu/vt-d: Remove global page flush support · 8744daf4
      Jacob Pan 提交于
      Global pages support is removed from VT-d spec 3.0. Since global pages G
      flag only affects first-level paging structures and because DMA request
      with PASID are only supported by VT-d spec. 3.0 and onward, we can
      safely remove global pages support.
      
      For kernel shared virtual address IOTLB invalidation, PASID
      granularity and page selective within PASID will be used. There is
      no global granularity supported. Without this fix, IOTLB invalidation
      will cause invalid descriptor error in the queued invalidation (QI)
      interface.
      
      Fixes: 1c4f88b7 ("iommu/vt-d: Shared virtual address in scalable mode")
      Reported-by: NSanjay K Kumar <sanjay.k.kumar@intel.com>
      Signed-off-by: NJacob Pan <jacob.jun.pan@linux.intel.com>
      Signed-off-by: NJoerg Roedel <jroedel@suse.de>
      8744daf4
  20. 05 6月, 2019 1 次提交