aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Roedel <jroedel@suse.de>2014-09-05 04:57:11 -0400
committerJoerg Roedel <jroedel@suse.de>2014-09-25 09:48:09 -0400
commit24278a24d88ae730229417e5d3bd452d7545fbcc (patch)
treeed0536259ad5ba49f4571012a2fd5e42bc85022d
parent6f952710917cfb801664333a491e4a120451a9ff (diff)
iommu: Remove iommu_domain_has_cap() API function
Signed-off-by: Joerg Roedel <jroedel@suse.de>
-rw-r--r--drivers/iommu/iommu.c13
-rw-r--r--include/linux/iommu.h11
2 files changed, 0 insertions, 24 deletions
diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c
index aeb243f46332..d2d242fcaa3d 100644
--- a/drivers/iommu/iommu.c
+++ b/drivers/iommu/iommu.c
@@ -956,19 +956,6 @@ phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova)
956} 956}
957EXPORT_SYMBOL_GPL(iommu_iova_to_phys); 957EXPORT_SYMBOL_GPL(iommu_iova_to_phys);
958 958
959int iommu_domain_has_cap(struct iommu_domain *domain,
960 enum iommu_cap cap)
961{
962 if (domain->ops->domain_has_cap != NULL)
963 return domain->ops->domain_has_cap(domain, cap);
964
965 if (domain->ops->capable != NULL)
966 return domain->ops->capable(cap);
967
968 return 0;
969}
970EXPORT_SYMBOL_GPL(iommu_domain_has_cap);
971
972static size_t iommu_pgsize(struct iommu_domain *domain, 959static size_t iommu_pgsize(struct iommu_domain *domain,
973 unsigned long addr_merge, size_t size) 960 unsigned long addr_merge, size_t size)
974{ 961{
diff --git a/include/linux/iommu.h b/include/linux/iommu.h
index d5534d554693..379a6179fd96 100644
--- a/include/linux/iommu.h
+++ b/include/linux/iommu.h
@@ -97,7 +97,6 @@ enum iommu_attr {
97 * @map: map a physically contiguous memory region to an iommu domain 97 * @map: map a physically contiguous memory region to an iommu domain
98 * @unmap: unmap a physically contiguous memory region from an iommu domain 98 * @unmap: unmap a physically contiguous memory region from an iommu domain
99 * @iova_to_phys: translate iova to physical address 99 * @iova_to_phys: translate iova to physical address
100 * @domain_has_cap: domain capabilities query
101 * @add_device: add device to iommu grouping 100 * @add_device: add device to iommu grouping
102 * @remove_device: remove device from iommu grouping 101 * @remove_device: remove device from iommu grouping
103 * @domain_get_attr: Query domain attributes 102 * @domain_get_attr: Query domain attributes
@@ -115,8 +114,6 @@ struct iommu_ops {
115 size_t (*unmap)(struct iommu_domain *domain, unsigned long iova, 114 size_t (*unmap)(struct iommu_domain *domain, unsigned long iova,
116 size_t size); 115 size_t size);
117 phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, dma_addr_t iova); 116 phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, dma_addr_t iova);
118 int (*domain_has_cap)(struct iommu_domain *domain,
119 unsigned long cap);
120 int (*add_device)(struct device *dev); 117 int (*add_device)(struct device *dev);
121 void (*remove_device)(struct device *dev); 118 void (*remove_device)(struct device *dev);
122 int (*device_group)(struct device *dev, unsigned int *groupid); 119 int (*device_group)(struct device *dev, unsigned int *groupid);
@@ -159,8 +156,6 @@ extern int iommu_map(struct iommu_domain *domain, unsigned long iova,
159extern size_t iommu_unmap(struct iommu_domain *domain, unsigned long iova, 156extern size_t iommu_unmap(struct iommu_domain *domain, unsigned long iova,
160 size_t size); 157 size_t size);
161extern phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova); 158extern phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova);
162extern int iommu_domain_has_cap(struct iommu_domain *domain,
163 enum iommu_cap cap);
164extern void iommu_set_fault_handler(struct iommu_domain *domain, 159extern void iommu_set_fault_handler(struct iommu_domain *domain,
165 iommu_fault_handler_t handler, void *token); 160 iommu_fault_handler_t handler, void *token);
166 161
@@ -314,12 +309,6 @@ static inline phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_ad
314 return 0; 309 return 0;
315} 310}
316 311
317static inline int iommu_domain_has_cap(struct iommu_domain *domain,
318 enum iommu_cap cap)
319{
320 return 0;
321}
322
323static inline void iommu_set_fault_handler(struct iommu_domain *domain, 312static inline void iommu_set_fault_handler(struct iommu_domain *domain,
324 iommu_fault_handler_t handler, void *token) 313 iommu_fault_handler_t handler, void *token)
325{ 314{