From 34333c35377d6625f6019644c2bbb31fa704ea52 Mon Sep 17 00:00:00 2001 From: Aurora zuma automerger Date: Sat, 4 Feb 2023 12:03:14 +0800 Subject: 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 --- gxp-dma-iommu.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'gxp-dma-iommu.c') 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; -- cgit v1.2.3