Lines Matching refs:iommu_domain

44 struct iommu_domain;
53 typedef int (*iommu_fault_handler_t)(struct iommu_domain *,
89 struct iommu_domain { struct
253 struct iommu_domain *(*domain_alloc)(unsigned iommu_domain_type);
254 void (*domain_free)(struct iommu_domain *);
256 int (*attach_dev)(struct iommu_domain *domain, struct device *dev);
257 void (*detach_dev)(struct iommu_domain *domain, struct device *dev);
258 int (*map)(struct iommu_domain *domain, unsigned long iova,
260 size_t (*unmap)(struct iommu_domain *domain, unsigned long iova,
262 void (*flush_iotlb_all)(struct iommu_domain *domain);
263 void (*iotlb_sync_map)(struct iommu_domain *domain);
264 void (*iotlb_sync)(struct iommu_domain *domain,
266 phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, dma_addr_t iova);
270 int (*domain_get_attr)(struct iommu_domain *domain,
272 int (*domain_set_attr)(struct iommu_domain *domain,
279 struct iommu_domain *domain,
283 int (*domain_window_enable)(struct iommu_domain *domain, u32 wnd_nr,
285 void (*domain_window_disable)(struct iommu_domain *domain, u32 wnd_nr);
288 bool (*is_attach_deferred)(struct iommu_domain *domain, struct device *dev);
297 int (*aux_attach_dev)(struct iommu_domain *domain, struct device *dev);
298 void (*aux_detach_dev)(struct iommu_domain *domain, struct device *dev);
299 int (*aux_get_pasid)(struct iommu_domain *domain, struct device *dev);
413 extern struct iommu_domain *iommu_domain_alloc(struct bus_type *bus);
415 extern void iommu_domain_free(struct iommu_domain *domain);
416 extern int iommu_attach_device(struct iommu_domain *domain,
418 extern void iommu_detach_device(struct iommu_domain *domain,
420 extern struct iommu_domain *iommu_get_domain_for_dev(struct device *dev);
421 extern struct iommu_domain *iommu_get_dma_domain(struct device *dev);
422 extern int iommu_map(struct iommu_domain *domain, unsigned long iova,
424 extern size_t iommu_unmap(struct iommu_domain *domain, unsigned long iova,
426 extern size_t iommu_unmap_fast(struct iommu_domain *domain,
429 extern size_t iommu_map_sg(struct iommu_domain *domain, unsigned long iova,
431 extern phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova);
432 extern void iommu_set_fault_handler(struct iommu_domain *domain,
448 extern int iommu_attach_group(struct iommu_domain *domain,
450 extern void iommu_detach_group(struct iommu_domain *domain,
483 extern struct iommu_domain *iommu_group_default_domain(struct iommu_group *);
485 extern int iommu_domain_get_attr(struct iommu_domain *domain, enum iommu_attr,
487 extern int iommu_domain_set_attr(struct iommu_domain *domain, enum iommu_attr,
491 extern int iommu_domain_window_enable(struct iommu_domain *domain, u32 wnd_nr,
494 extern void iommu_domain_window_disable(struct iommu_domain *domain, u32 wnd_nr);
496 extern int report_iommu_fault(struct iommu_domain *domain, struct device *dev,
499 static inline void iommu_flush_tlb_all(struct iommu_domain *domain) in iommu_flush_tlb_all()
505 static inline void iommu_tlb_sync(struct iommu_domain *domain, in iommu_tlb_sync()
514 static inline void iommu_iotlb_gather_add_page(struct iommu_domain *domain, in iommu_iotlb_gather_add_page()
598 int iommu_aux_attach_device(struct iommu_domain *domain, struct device *dev);
599 void iommu_aux_detach_device(struct iommu_domain *domain, struct device *dev);
600 int iommu_aux_get_pasid(struct iommu_domain *domain, struct device *dev);
629 static inline struct iommu_domain *iommu_domain_alloc(struct bus_type *bus) in iommu_domain_alloc()
639 static inline void iommu_domain_free(struct iommu_domain *domain) in iommu_domain_free()
643 static inline int iommu_attach_device(struct iommu_domain *domain, in iommu_attach_device()
649 static inline void iommu_detach_device(struct iommu_domain *domain, in iommu_detach_device()
654 static inline struct iommu_domain *iommu_get_domain_for_dev(struct device *dev) in iommu_get_domain_for_dev()
659 static inline int iommu_map(struct iommu_domain *domain, unsigned long iova, in iommu_map()
665 static inline size_t iommu_unmap(struct iommu_domain *domain, in iommu_unmap()
671 static inline size_t iommu_unmap_fast(struct iommu_domain *domain, in iommu_unmap_fast()
678 static inline size_t iommu_map_sg(struct iommu_domain *domain, in iommu_map_sg()
685 static inline void iommu_flush_tlb_all(struct iommu_domain *domain) in iommu_flush_tlb_all()
689 static inline void iommu_tlb_sync(struct iommu_domain *domain, in iommu_tlb_sync()
694 static inline int iommu_domain_window_enable(struct iommu_domain *domain, in iommu_domain_window_enable()
701 static inline void iommu_domain_window_disable(struct iommu_domain *domain, in iommu_domain_window_disable()
706 static inline phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova) in iommu_iova_to_phys()
711 static inline void iommu_set_fault_handler(struct iommu_domain *domain, in iommu_set_fault_handler()
755 static inline int iommu_attach_group(struct iommu_domain *domain, in iommu_attach_group()
761 static inline void iommu_detach_group(struct iommu_domain *domain, in iommu_detach_group()
856 static inline int iommu_domain_get_attr(struct iommu_domain *domain, in iommu_domain_get_attr()
862 static inline int iommu_domain_set_attr(struct iommu_domain *domain, in iommu_domain_set_attr()
892 static inline void iommu_iotlb_gather_add_page(struct iommu_domain *domain, in iommu_iotlb_gather_add_page()
971 iommu_aux_attach_device(struct iommu_domain *domain, struct device *dev) in iommu_aux_attach_device()
977 iommu_aux_detach_device(struct iommu_domain *domain, struct device *dev) in iommu_aux_detach_device()
982 iommu_aux_get_pasid(struct iommu_domain *domain, struct device *dev) in iommu_aux_get_pasid()