Lines Matching refs:iommu_domain

51 struct iommu_domain;
60 typedef int (*iommu_fault_handler_t)(struct iommu_domain *,
94 struct iommu_domain { struct
254 struct iommu_domain *(*domain_alloc)(unsigned iommu_domain_type);
255 void (*domain_free)(struct iommu_domain *);
257 int (*attach_dev)(struct iommu_domain *domain, struct device *dev);
258 void (*detach_dev)(struct iommu_domain *domain, struct device *dev);
259 int (*map)(struct iommu_domain *domain, unsigned long iova,
261 int (*map_pages)(struct iommu_domain *domain, unsigned long iova,
264 int (*map_sg)(struct iommu_domain *domain, unsigned long iova,
267 size_t (*unmap)(struct iommu_domain *domain, unsigned long iova,
269 size_t (*unmap_pages)(struct iommu_domain *domain, unsigned long iova,
272 void (*flush_iotlb_all)(struct iommu_domain *domain);
273 void (*iotlb_sync_map)(struct iommu_domain *domain, unsigned long iova,
275 void (*iotlb_sync)(struct iommu_domain *domain,
277 phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, dma_addr_t iova);
282 int (*domain_get_attr)(struct iommu_domain *domain,
284 int (*domain_set_attr)(struct iommu_domain *domain,
291 struct iommu_domain *domain,
295 int (*domain_window_enable)(struct iommu_domain *domain, u32 wnd_nr,
297 void (*domain_window_disable)(struct iommu_domain *domain, u32 wnd_nr);
300 bool (*is_attach_deferred)(struct iommu_domain *domain, struct device *dev);
309 int (*aux_attach_dev)(struct iommu_domain *domain, struct device *dev);
310 void (*aux_detach_dev)(struct iommu_domain *domain, struct device *dev);
311 int (*aux_get_pasid)(struct iommu_domain *domain, struct device *dev);
321 int (*cache_invalidate)(struct iommu_domain *domain, struct device *dev,
323 int (*sva_bind_gpasid)(struct iommu_domain *domain,
447 extern struct iommu_domain *iommu_domain_alloc(struct bus_type *bus);
449 extern void iommu_domain_free(struct iommu_domain *domain);
450 extern int iommu_attach_device(struct iommu_domain *domain,
452 extern void iommu_detach_device(struct iommu_domain *domain,
454 extern int iommu_uapi_cache_invalidate(struct iommu_domain *domain,
458 extern int iommu_uapi_sva_bind_gpasid(struct iommu_domain *domain,
460 extern int iommu_uapi_sva_unbind_gpasid(struct iommu_domain *domain,
462 extern int iommu_sva_unbind_gpasid(struct iommu_domain *domain,
464 extern struct iommu_domain *iommu_get_domain_for_dev(struct device *dev);
465 extern struct iommu_domain *iommu_get_dma_domain(struct device *dev);
466 extern int iommu_map(struct iommu_domain *domain, unsigned long iova,
468 extern int iommu_map_atomic(struct iommu_domain *domain, unsigned long iova,
470 extern size_t iommu_unmap(struct iommu_domain *domain, unsigned long iova,
472 extern size_t iommu_unmap_fast(struct iommu_domain *domain,
475 extern size_t iommu_map_sg(struct iommu_domain *domain, unsigned long iova,
477 extern size_t iommu_map_sg_atomic(struct iommu_domain *domain,
480 extern phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova);
481 extern void iommu_set_fault_handler(struct iommu_domain *domain,
497 extern int iommu_attach_group(struct iommu_domain *domain,
499 extern void iommu_detach_group(struct iommu_domain *domain,
531 extern struct iommu_domain *iommu_group_default_domain(struct iommu_group *);
533 extern int iommu_domain_get_attr(struct iommu_domain *domain, enum iommu_attr,
535 extern int iommu_domain_set_attr(struct iommu_domain *domain, enum iommu_attr,
539 extern int iommu_domain_window_enable(struct iommu_domain *domain, u32 wnd_nr,
542 extern void iommu_domain_window_disable(struct iommu_domain *domain, u32 wnd_nr);
544 extern int report_iommu_fault(struct iommu_domain *domain, struct device *dev,
547 static inline void iommu_flush_iotlb_all(struct iommu_domain *domain) in iommu_flush_iotlb_all()
553 static inline void iommu_iotlb_sync(struct iommu_domain *domain, in iommu_iotlb_sync()
562 static inline void iommu_iotlb_gather_add_page(struct iommu_domain *domain, in iommu_iotlb_gather_add_page()
662 int iommu_aux_attach_device(struct iommu_domain *domain, struct device *dev);
663 void iommu_aux_detach_device(struct iommu_domain *domain, struct device *dev);
664 int iommu_aux_get_pasid(struct iommu_domain *domain, struct device *dev);
691 static inline struct iommu_domain *iommu_domain_alloc(struct bus_type *bus) in iommu_domain_alloc()
701 static inline void iommu_domain_free(struct iommu_domain *domain) in iommu_domain_free()
705 static inline int iommu_attach_device(struct iommu_domain *domain, in iommu_attach_device()
711 static inline void iommu_detach_device(struct iommu_domain *domain, in iommu_detach_device()
716 static inline struct iommu_domain *iommu_get_domain_for_dev(struct device *dev) in iommu_get_domain_for_dev()
721 static inline int iommu_map(struct iommu_domain *domain, unsigned long iova, in iommu_map()
727 static inline int iommu_map_atomic(struct iommu_domain *domain, in iommu_map_atomic()
734 static inline size_t iommu_unmap(struct iommu_domain *domain, in iommu_unmap()
740 static inline size_t iommu_unmap_fast(struct iommu_domain *domain, in iommu_unmap_fast()
747 static inline size_t iommu_map_sg(struct iommu_domain *domain, in iommu_map_sg()
754 static inline size_t iommu_map_sg_atomic(struct iommu_domain *domain, in iommu_map_sg_atomic()
761 static inline void iommu_flush_iotlb_all(struct iommu_domain *domain) in iommu_flush_iotlb_all()
765 static inline void iommu_iotlb_sync(struct iommu_domain *domain, in iommu_iotlb_sync()
770 static inline int iommu_domain_window_enable(struct iommu_domain *domain, in iommu_domain_window_enable()
777 static inline void iommu_domain_window_disable(struct iommu_domain *domain, in iommu_domain_window_disable()
782 static inline phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, dma_addr_t iova) in iommu_iova_to_phys()
787 static inline void iommu_set_fault_handler(struct iommu_domain *domain, in iommu_set_fault_handler()
821 static inline int iommu_attach_group(struct iommu_domain *domain, in iommu_attach_group()
827 static inline void iommu_detach_group(struct iommu_domain *domain, in iommu_detach_group()
922 static inline int iommu_domain_get_attr(struct iommu_domain *domain, in iommu_domain_get_attr()
928 static inline int iommu_domain_set_attr(struct iommu_domain *domain, in iommu_domain_set_attr()
958 static inline void iommu_iotlb_gather_add_page(struct iommu_domain *domain, in iommu_iotlb_gather_add_page()
1037 iommu_aux_attach_device(struct iommu_domain *domain, struct device *dev) in iommu_aux_attach_device()
1043 iommu_aux_detach_device(struct iommu_domain *domain, struct device *dev) in iommu_aux_detach_device()
1048 iommu_aux_get_pasid(struct iommu_domain *domain, struct device *dev) in iommu_aux_get_pasid()
1069 iommu_uapi_cache_invalidate(struct iommu_domain *domain, in iommu_uapi_cache_invalidate()
1076 static inline int iommu_uapi_sva_bind_gpasid(struct iommu_domain *domain, in iommu_uapi_sva_bind_gpasid()
1082 static inline int iommu_uapi_sva_unbind_gpasid(struct iommu_domain *domain, in iommu_uapi_sva_unbind_gpasid()
1088 static inline int iommu_sva_unbind_gpasid(struct iommu_domain *domain, in iommu_sva_unbind_gpasid()
1111 static inline size_t iommu_map_sgtable(struct iommu_domain *domain, in iommu_map_sgtable()