summaryrefslogtreecommitdiff
path: root/gxp-dma-iommu.c
diff options
context:
space:
mode:
authorAurora zuma automerger <aurora-zuma-automerger@google.com>2023-02-04 12:03:14 +0800
committerCopybara-Service <copybara-worker@google.com>2023-02-07 03:50:05 -0800
commit34333c35377d6625f6019644c2bbb31fa704ea52 (patch)
tree6e266243c82b34c34072616dcfb95924c439c252 /gxp-dma-iommu.c
parent95097f5e8e99026600f5055d389c4bc4fcb4c827 (diff)
downloadzuma-34333c35377d6625f6019644c2bbb31fa704ea52.tar.gz
gxp: [Copybara Auto Merge] Merge branch 'zuma' into 'android14-gs-pixel-5.15'
gcip: Add a new KCI code for thermal control Bug: 266837631 GCIP_HEADERS_REV_ID: f4bfe07c37ad5c61abca721151d5ab5bfc4d3ad2 gxp: temporarily ignore img cfg dup mapping Bug: 268151565 gxp: define and use common interface for iommu_map Bug: 248436918 gxp: Merge identical parts in [callisto|europa]-platform.c. Bug: 249918544 GitOrigin-RevId: d31f54ad547e6020bef3af0b555219fec4bb7ef8 Change-Id: I426400c5abec897e18b80b5aed09aae3935191e9
Diffstat (limited to 'gxp-dma-iommu.c')
-rw-r--r--gxp-dma-iommu.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gxp-dma-iommu.c b/gxp-dma-iommu.c
index 3dfd70b..94a78b3 100644
--- a/gxp-dma-iommu.c
+++ b/gxp-dma-iommu.c
@@ -201,6 +201,18 @@ struct gxp_iommu_domain *gxp_iommu_get_domain_for_dev(struct gxp_dev *gxp)
return gdomain;
}
+int gxp_iommu_map(struct gxp_dev *gxp, struct gxp_iommu_domain *gdomain,
+ unsigned long iova, phys_addr_t paddr, size_t size, int prot)
+{
+ return iommu_map(gdomain->domain, iova, paddr, size, prot);
+}
+
+void gxp_iommu_unmap(struct gxp_dev *gxp, struct gxp_iommu_domain *gdomain,
+ unsigned long iova, size_t size)
+{
+ iommu_unmap(gdomain->domain, iova, size);
+}
+
int gxp_dma_init(struct gxp_dev *gxp)
{
struct gxp_dma_iommu_manager *mgr;