[PATCH v3 0/3] KVM: arm64: fix pKVM mapping cache corner cases

From: Bradley Morgan

Date: Wed Jun 24 2026 - 12:01:06 EST


This is a standalone v3.

Patch 1 fixes pKVM cache maintenance for non cacheable mappings without
growing struct pkvm_mapping.

Patch 2 fixes a pKVM mapping cache topup bug on permission faults that
replace page mappings with a PMD mapping.

Patch 3 fixes the generic dirty logging case where a permission fault
can still need a page table allocation to split a block mapping.

Changes in v3:
- Send as a standalone series with a cover letter.
- Store the pKVM cacheable bit in nr_pages instead of adding a bool.
- Drop stable from patch 1.
- Add patch 3 for dirty logging permission faults.

Changes in v2:
- Add patch 2 for the pKVM permission fault mapping cache bug.

Bradley Morgan (3):
KVM: arm64: skip pKVM cache flushes for non cacheable mappings
KVM: arm64: top up pKVM mapping cache for permission faults
KVM: arm64: top up stage 2 memcache for dirty logging faults

arch/arm64/kvm/mmu.c | 32 +++++++++++++++++++--------
arch/arm64/kvm/pkvm.c | 51 ++++++++++++++++++++++++++++++++++---------
2 files changed, 64 insertions(+), 19 deletions(-)

--
2.53.0