diff options
Diffstat (limited to 'include/linux/iommu.h')
-rw-r--r-- | include/linux/iommu.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/include/linux/iommu.h b/include/linux/iommu.h index f9c1b6d0f2e4..f28dff313b07 100644 --- a/include/linux/iommu.h +++ b/include/linux/iommu.h | |||
@@ -81,6 +81,7 @@ struct iommu_domain { | |||
81 | iommu_fault_handler_t handler; | 81 | iommu_fault_handler_t handler; |
82 | void *handler_token; | 82 | void *handler_token; |
83 | struct iommu_domain_geometry geometry; | 83 | struct iommu_domain_geometry geometry; |
84 | void *iova_cookie; | ||
84 | }; | 85 | }; |
85 | 86 | ||
86 | enum iommu_cap { | 87 | enum iommu_cap { |
@@ -167,7 +168,7 @@ struct iommu_ops { | |||
167 | phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, dma_addr_t iova); | 168 | phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, dma_addr_t iova); |
168 | int (*add_device)(struct device *dev); | 169 | int (*add_device)(struct device *dev); |
169 | void (*remove_device)(struct device *dev); | 170 | void (*remove_device)(struct device *dev); |
170 | int (*device_group)(struct device *dev, unsigned int *groupid); | 171 | struct iommu_group *(*device_group)(struct device *dev); |
171 | int (*domain_get_attr)(struct iommu_domain *domain, | 172 | int (*domain_get_attr)(struct iommu_domain *domain, |
172 | enum iommu_attr attr, void *data); | 173 | enum iommu_attr attr, void *data); |
173 | int (*domain_set_attr)(struct iommu_domain *domain, | 174 | int (*domain_set_attr)(struct iommu_domain *domain, |
@@ -316,6 +317,11 @@ static inline size_t iommu_map_sg(struct iommu_domain *domain, | |||
316 | return domain->ops->map_sg(domain, iova, sg, nents, prot); | 317 | return domain->ops->map_sg(domain, iova, sg, nents, prot); |
317 | } | 318 | } |
318 | 319 | ||
320 | /* PCI device grouping function */ | ||
321 | extern struct iommu_group *pci_device_group(struct device *dev); | ||
322 | /* Generic device grouping function */ | ||
323 | extern struct iommu_group *generic_device_group(struct device *dev); | ||
324 | |||
319 | #else /* CONFIG_IOMMU_API */ | 325 | #else /* CONFIG_IOMMU_API */ |
320 | 326 | ||
321 | struct iommu_ops {}; | 327 | struct iommu_ops {}; |