Thread (23 messages) 23 messages, 4 authors, 2023-08-19

Re: [PATCH v12 2/7] iommu/mediatek: Fix two IOMMU share pagetable issue

From: Alexandre Mergnat <hidden>
Date: 2023-06-06 13:59:41
Also in: linux-devicetree, linux-iommu, linux-mediatek, lkml

On 02/06/2023 11:02, Yong Wu wrote:
Prepare for mt8188 to fix a two IOMMU HWs share pagetable issue.

We have two MM IOMMU HWs in mt8188, one is VPP-IOMMU, the other is
VDO-IOMMU. The 2 MM IOMMU HWs share pagetable don't work in this case:
  a) VPP-IOMMU probe firstly.
  b) VDO-IOMMU probe.
  c) The master for VDO-IOMMU probe (means frstdata is vpp-iommu).
  d) The master in another domain probe. No matter it is vdo or vpp.
Then it still create a new pagetable in step d). The problem is
"frstdata->bank[0]->m4u_dom" was not initialized. Then when d) enter, it
still create a new one.

In this patch, we create a new variable "share_dom" for this share
pgtable case, it should be helpful for readable. and put all the share
pgtable logic in the mtk_iommu_domain_finalise.

In mt8195, the master of VPP-IOMMU probes before than VDO-IOMMU
from its dtsi node sequence, we don't see this issue in it. Prepare for
mt8188.
Reviewed-by: Alexandre Mergnat <redacted>

-- 
Regards,
Alexandre


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help