Lines Matching full:mmu

30 static struct msm_iommu_pagetable *to_pagetable(struct msm_mmu *mmu)  in to_pagetable()  argument
32 return container_of(mmu, struct msm_iommu_pagetable, base); in to_pagetable()
91 static int msm_iommu_pagetable_unmap(struct msm_mmu *mmu, u64 iova, in msm_iommu_pagetable_unmap() argument
94 struct msm_iommu_pagetable *pagetable = to_pagetable(mmu); in msm_iommu_pagetable_unmap()
115 static int msm_iommu_pagetable_map(struct msm_mmu *mmu, u64 iova, in msm_iommu_pagetable_map() argument
118 struct msm_iommu_pagetable *pagetable = to_pagetable(mmu); in msm_iommu_pagetable_map()
145 msm_iommu_pagetable_unmap(mmu, iova, addr - iova); in msm_iommu_pagetable_map()
154 static void msm_iommu_pagetable_destroy(struct msm_mmu *mmu) in msm_iommu_pagetable_destroy() argument
156 struct msm_iommu_pagetable *pagetable = to_pagetable(mmu); in msm_iommu_pagetable_destroy()
172 int msm_iommu_pagetable_params(struct msm_mmu *mmu, in msm_iommu_pagetable_params() argument
177 if (mmu->type != MSM_MMU_IOMMU_PAGETABLE) in msm_iommu_pagetable_params()
180 pagetable = to_pagetable(mmu); in msm_iommu_pagetable_params()
191 struct iommu_domain_geometry *msm_iommu_get_geometry(struct msm_mmu *mmu) in msm_iommu_get_geometry() argument
193 struct msm_iommu *iommu = to_msm_iommu(mmu); in msm_iommu_get_geometry()
199 msm_iommu_pagetable_walk(struct msm_mmu *mmu, unsigned long iova, uint64_t ptes[4]) in msm_iommu_pagetable_walk() argument
204 if (mmu->type != MSM_MMU_IOMMU_PAGETABLE) in msm_iommu_pagetable_walk()
207 pagetable = to_pagetable(mmu); in msm_iommu_pagetable_walk()
348 struct msm_mmu *mmu = &iommu->base; in msm_gpu_fault_handler() local
362 if (mmu->funcs->resume_translation) in msm_gpu_fault_handler()
363 mmu->funcs->resume_translation(mmu); in msm_gpu_fault_handler()
379 static void msm_iommu_resume_translation(struct msm_mmu *mmu) in msm_iommu_resume_translation() argument
381 struct adreno_smmu_priv *adreno_smmu = dev_get_drvdata(mmu->dev); in msm_iommu_resume_translation()
387 static void msm_iommu_detach(struct msm_mmu *mmu) in msm_iommu_detach() argument
389 struct msm_iommu *iommu = to_msm_iommu(mmu); in msm_iommu_detach()
391 iommu_detach_device(iommu->domain, mmu->dev); in msm_iommu_detach()
394 static int msm_iommu_map(struct msm_mmu *mmu, uint64_t iova, in msm_iommu_map() argument
397 struct msm_iommu *iommu = to_msm_iommu(mmu); in msm_iommu_map()
410 static int msm_iommu_unmap(struct msm_mmu *mmu, uint64_t iova, size_t len) in msm_iommu_unmap() argument
412 struct msm_iommu *iommu = to_msm_iommu(mmu); in msm_iommu_unmap()
422 static void msm_iommu_destroy(struct msm_mmu *mmu) in msm_iommu_destroy() argument
424 struct msm_iommu *iommu = to_msm_iommu(mmu); in msm_iommu_destroy()
476 struct msm_mmu *mmu; in msm_iommu_disp_new() local
478 mmu = msm_iommu_new(dev, quirks); in msm_iommu_disp_new()
479 if (IS_ERR_OR_NULL(mmu)) in msm_iommu_disp_new()
480 return mmu; in msm_iommu_disp_new()
482 iommu = to_msm_iommu(mmu); in msm_iommu_disp_new()
485 return mmu; in msm_iommu_disp_new()
492 struct msm_mmu *mmu; in msm_iommu_gpu_new() local
494 mmu = msm_iommu_new(dev, quirks); in msm_iommu_gpu_new()
495 if (IS_ERR_OR_NULL(mmu)) in msm_iommu_gpu_new()
496 return mmu; in msm_iommu_gpu_new()
498 iommu = to_msm_iommu(mmu); in msm_iommu_gpu_new()
505 return mmu; in msm_iommu_gpu_new()