summaryrefslogtreecommitdiff
path: root/drivers/iommu/mtk_iommu.h
diff options
context:
space:
mode:
authorYong Wu <yong.wu@mediatek.com>2021-01-11 14:19:07 +0300
committerWill Deacon <will@kernel.org>2021-02-01 14:31:19 +0300
commit585e58f498a2855dc7a8d351df34dd645447f337 (patch)
treedffb0d35ef5e7622c2d56f39c869f2cc8d20e527 /drivers/iommu/mtk_iommu.h
parentb7875eb9458983ade0c780276b21cfbc0c22d70b (diff)
downloadlinux-585e58f498a2855dc7a8d351df34dd645447f337.tar.xz
iommu/mediatek: Add iova_region structure
Add a new structure for the iova_region. Each a region will be a independent iommu domain. For the previous SoC, there is single iova region(0~4G). For the SoC that need support multi-domains, there will be several regions. Signed-off-by: Yong Wu <yong.wu@mediatek.com> Reviewed-by: Tomasz Figa <tfiga@chromium.org> Link: https://lore.kernel.org/r/20210111111914.22211-27-yong.wu@mediatek.com Signed-off-by: Will Deacon <will@kernel.org>
Diffstat (limited to 'drivers/iommu/mtk_iommu.h')
-rw-r--r--drivers/iommu/mtk_iommu.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/iommu/mtk_iommu.h b/drivers/iommu/mtk_iommu.h
index a9b79e118f02..118170af1974 100644
--- a/drivers/iommu/mtk_iommu.h
+++ b/drivers/iommu/mtk_iommu.h
@@ -45,10 +45,15 @@ enum mtk_iommu_plat {
M4U_MT8183,
};
+struct mtk_iommu_iova_region;
+
struct mtk_iommu_plat_data {
enum mtk_iommu_plat m4u_plat;
u32 flags;
u32 inv_sel_reg;
+
+ unsigned int iova_region_nr;
+ const struct mtk_iommu_iova_region *iova_region;
unsigned char larbid_remap[MTK_LARB_COM_MAX][MTK_LARB_SUBCOM_MAX];
};