diff options
author | Hiroshi Doyu <hdoyu@nvidia.com> | 2013-04-03 15:50:44 +0300 |
---|---|---|
committer | Harshada Kale <hkale@nvidia.com> | 2013-06-10 03:51:05 -0700 |
commit | 2fa899cea85450ffda872115c5c931089bd1d14f (patch) | |
tree | 803052bc1bd78b5124c2ec637b9b8b1330f1dc05 /include/linux | |
parent | 0774cef9ef1f7aef2a97369a28687b1bedd6d50f (diff) |
iommu/core: Add new API iommu_map_pages()
Add new API iommu_map_pages() to call iommu_ops->map_pages()
internally.
bug 1286500
Change-Id: I37605703def34bba774e480b29506c459d6391bd
(cherry picked from commit 11ed57ffcbd908e12c1fd836211beed4fc577833)
Signed-off-by: Hiroshi Doyu <hdoyu@nvidia.com>
Reviewed-on: http://git-master/r/234131
Reviewed-by: Krishna Reddy <vdumpa@nvidia.com>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/iommu.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/iommu.h b/include/linux/iommu.h index d937580417ba..79a21e2f03b6 100644 --- a/include/linux/iommu.h +++ b/include/linux/iommu.h @@ -68,6 +68,8 @@ struct iommu_ops { void (*detach_dev)(struct iommu_domain *domain, struct device *dev); int (*map)(struct iommu_domain *domain, unsigned long iova, phys_addr_t paddr, size_t size, int prot); + int (*map_pages)(struct iommu_domain *domain, unsigned long iova, + struct page **pages, size_t count, int prot); size_t (*unmap)(struct iommu_domain *domain, unsigned long iova, size_t size); phys_addr_t (*iova_to_phys)(struct iommu_domain *domain, @@ -88,6 +90,8 @@ extern void iommu_detach_device(struct iommu_domain *domain, struct device *dev); extern int iommu_map(struct iommu_domain *domain, unsigned long iova, phys_addr_t paddr, size_t size, int prot); +extern int iommu_map_pages(struct iommu_domain *domain, unsigned long iova, + struct page **pages, size_t count, int prot); extern size_t iommu_unmap(struct iommu_domain *domain, unsigned long iova, size_t size); extern phys_addr_t iommu_iova_to_phys(struct iommu_domain *domain, |