From: Jan Kiszka <[email protected]>

No need to run this sequence for every SID the cell owned.

Signed-off-by: Jan Kiszka <[email protected]>
---
 hypervisor/arch/arm64/smmu.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/hypervisor/arch/arm64/smmu.c b/hypervisor/arch/arm64/smmu.c
index 34f2b821..acfe0cd9 100644
--- a/hypervisor/arch/arm64/smmu.c
+++ b/hypervisor/arch/arm64/smmu.c
@@ -596,11 +596,11 @@ static void arm_smmu_cell_exit(struct cell *cell)
                                arm_smmu_write_smr(smmu, idx);
                        }
                        arm_smmu_write_s2cr(smmu, idx, S2CR_TYPE_FAULT, 0);
-
-                       smmu->cbs[id].cfg = NULL;
-                       arm_smmu_write_context_bank(smmu, id);
                }
 
+               smmu->cbs[id].cfg = NULL;
+               arm_smmu_write_context_bank(smmu, id);
+
                mmio_write32(ARM_SMMU_GR0(smmu) + ARM_SMMU_GR0_TLBIVMID, id);
                arm_smmu_tlb_sync_global(smmu);
        }
-- 
2.26.2

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jailhouse-dev/c4da54daafe45071e6d769b63a8293eb86bda741.1601838005.git.jan.kiszka%40siemens.com.

Reply via email to