Lines Matching +full:pci +full:- +full:iommu
1 // SPDX-License-Identifier: GPL-2.0-only
13 #include <linux/pci.h>
14 #include <linux/pci-ats.h>
22 #include "iommu.h"
25 #include "../iommu-pages.h"
28 void intel_svm_check(struct intel_iommu *iommu) in intel_svm_check() argument
30 if (!pasid_supported(iommu)) in intel_svm_check()
34 !cap_fl1gp_support(iommu->cap)) { in intel_svm_check()
36 iommu->name); in intel_svm_check()
41 !cap_fl5lp_support(iommu->cap)) { in intel_svm_check()
43 iommu->name); in intel_svm_check()
47 iommu->flags |= VTD_FLAG_SVM_CAPABLE; in intel_svm_check()
64 * different from IOMMU subsystem using the last address of an address in intel_arch_invalidate_secondary_tlbs()
67 cache_tag_flush_range(domain, start, end - 1, 0); in intel_arch_invalidate_secondary_tlbs()
89 spin_lock_irqsave(&domain->lock, flags); in intel_mm_release()
90 list_for_each_entry(dev_pasid, &domain->dev_pasids, link_domain) { in intel_mm_release()
91 info = dev_iommu_priv_get(dev_pasid->dev); in intel_mm_release()
92 intel_pasid_tear_down_entry(info->iommu, dev_pasid->dev, in intel_mm_release()
93 dev_pasid->pasid, true); in intel_mm_release()
95 spin_unlock_irqrestore(&domain->lock, flags); in intel_mm_release()
103 kfree(domain->qi_batch); in intel_mm_free_notifier()
118 struct intel_iommu *iommu = info->iommu; in intel_svm_set_dev_pasid() local
119 struct mm_struct *mm = domain->mm; in intel_svm_set_dev_pasid()
130 ret = __domain_setup_first_level(iommu, dev, pasid, in intel_svm_set_dev_pasid()
131 FLPT_DEFAULT_DID, mm->pgd, in intel_svm_set_dev_pasid()
150 mmu_notifier_put(&dmar_domain->notifier); in intel_svm_domain_free()
166 return ERR_PTR(-ENOMEM); in intel_svm_domain_alloc()
168 domain->domain.ops = &intel_svm_domain_ops; in intel_svm_domain_alloc()
169 domain->use_first_level = true; in intel_svm_domain_alloc()
170 INIT_LIST_HEAD(&domain->dev_pasids); in intel_svm_domain_alloc()
171 INIT_LIST_HEAD(&domain->cache_tags); in intel_svm_domain_alloc()
172 spin_lock_init(&domain->cache_lock); in intel_svm_domain_alloc()
173 spin_lock_init(&domain->lock); in intel_svm_domain_alloc()
175 domain->notifier.ops = &intel_mmuops; in intel_svm_domain_alloc()
176 ret = mmu_notifier_register(&domain->notifier, mm); in intel_svm_domain_alloc()
182 return &domain->domain; in intel_svm_domain_alloc()