Re: [PATCH v22 10/23] KVM: arm64: Consolidate stage2 unmap range into kvm_stage2_unmap_range
From: Gavin Shan
Date: Mon Oct 05 2026 - 22:38:17 EST
On 10/5/26 7:07 PM, Suzuki K Poulose wrote:
In preparation for adding VM specific backends for stage2 operations,
nuke __unmap_stage2_range() and fold the logic into
kvm_stage2_unmap_range(). Also, make kvm_unmap_gfn_range(), the only other
user of the __unmap_stage2_range() call the kvm_stage2_unmap_range(). Also,
while at it fix the comment to make it clear that mmu_lock must always be
held while unmapping. The code already mandates that and the two call paths
do have the write mmu_lock held.
Later we would replace the logic in kvm_stage2_unmap_range() with VM
specific backends.
No functional changes intended.
Signed-off-by: Suzuki K Poulose <suzuki.poulose@xxxxxxx>
---
Change since v21:
- Nuke __unmap_stage2_range and consolidate the stage2_unmap_range logic
into kvm_stage2_unmap_range(), in preparation for removing the KVM_PGT_FN()
for stage2_unmap
---
arch/arm64/kvm/mmu.c | 38 ++++++++++++++++----------------------
1 file changed, 16 insertions(+), 22 deletions(-)
Reviewed-by: Gavin Shan <gshan@xxxxxxxxxx>