From 6327d32463ab9d5aadcbce7a3fbb1f3ce7220324 Mon Sep 17 00:00:00 2001 From: Ved Shanbhogue Date: Tue, 15 Aug 2023 12:56:42 -0500 Subject: [PATCH] clarify Bare translations, if created, dont need explicit invalidations --- iommu_in_memory_queues.adoc | 5 +++++ iommu_sw_guidelines.adoc | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/iommu_in_memory_queues.adoc b/iommu_in_memory_queues.adoc index 6fdf4c4c..49e3f05a 100644 --- a/iommu_in_memory_queues.adoc +++ b/iommu_in_memory_queues.adoc @@ -270,6 +270,11 @@ match the `GSCID` argument, regardless of the address argument. Simpler implementations may ignore the operand of `IOTINVAL.VMA` and/or `IOTINVAL.GVMA` and always perform a global invalidation of all address-translation entries. + +Some implementations may choose to cache an identity-mapped translation for the +stage of address translation that is in `Bare` mode. The 'IOTINVAL' commands do +not apply to such identity-mapped translations, as these identity mappings are +always correct. As a result, there is no need for explicit invalidation. ==== [NOTE] diff --git a/iommu_sw_guidelines.adoc b/iommu_sw_guidelines.adoc index e1bf172f..0f9c2321 100644 --- a/iommu_sw_guidelines.adoc +++ b/iommu_sw_guidelines.adoc @@ -149,9 +149,9 @@ device with `device_id = D`) then the following invalidations must be performed: ** `IOTINVAL.VMA` with `GV=1`, `AV=PSCV=0`, and `GSCID=DC.iohgatp.GSCID` ** `IOTINVAL.GVMA` with `GV=1`, `AV=0`, and `GSCID=DC.iohgatp.GSCID` * else -** If `DC.tc.PDTV==1 || DC.tc.PDTV == 0 && DC.fsc.MODE == Bare` +** If `DC.tc.PDTV==1` *** `IOTINVAL.VMA` with `GV=AV=PSCV=0` -** else +** else if `DC.fsc.MODE != Bare` *** `IOTINVAL.VMA` with `GV=AV=0` and `PSCV=1`, and `PSCID=DC.ta.PSCID` If software changes a non-leaf-level DDT entry the following invalidations