KVM: arm64: MMIO guard PV services
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest16 patches 12 repliesIn review
- v116 patches 45 repliesSuperseded
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/16 | KVM: arm64: Generalise VM features into a set of flagsarch/ arch/ arch/ | +12 | 1 reply | |
| 2/16 | KVM: arm64: Check for PTE valitity when checking for executable/cacheablearch/ | +4 | 1 reply | |
| 3/16 | KVM: arm64: Turn kvm_pgtable_stage2_set_owner into kvm_pgtable_stage2_annotatearch/ arch/ arch/ +2 more | +27 | 2 replies | |
| 4/16 | KVM: arm64: Add MMIO checking infrastructurearch/ arch/ arch/ | +116 | 1 reply | |
| 5/16 | KVM: arm64: Plumb MMIO checking into the fault handlingarch/ | +17 | 0 replies | |
| 6/16 | KVM: arm64: Force a full unmap on vpcu reinitarch/ | +8 | 1 reply | |
| 7/16 | KVM: arm64: Wire MMIO guard hypercallsarch/ include/ | +56 | 1 reply | |
| 8/16 | KVM: arm64: Add tracepoint for failed MMIO guard checkarch/ arch/ | +20 | 0 replies | |
| 9/16 | KVM: arm64: Advertise a capability for MMIO guardarch/ arch/ include/ | +31 | 1 reply | |
| 10/16 | KVM: arm64: Add some documentation for the MMIO guard featureDocumentation/ Documentation/ | +75 | 2 replies | |
| 11/16 | firmware/smccc: Call arch-specific hook on discovering KVM servicesarch/ arch/ drivers/ | +6 | 0 replies | |
| 12/16 | mm/vmalloc: Add arch-specific callbacks to track io{remap,unmap} physical pagesinclude/ mm/ mm/ | +18 | 0 replies | |
| 13/16 | arm64: Implement ioremap/iounmap hooks calling into KVM's MMIO guardarch/ | +112 | 1 reply | |
| 14/16 | arm64: Enroll into KVM's MMIO guard if requiredDocumentation/ arch/ arch/ +2 more | +49 | 0 replies | |
| 15/16 | arm64: Add a helper to retrieve the PTE of a fixmaparch/ arch/ | +17 | 0 replies | |
| 16/16 | arm64: Register earlycon fixmap with the MMIO guardarch/ | +12 | 0 replies |
Reviews trailers per patch
7 of 16 patches have a Reviewed-by or Acked-by.
| Patch | Andrew Jones |
|---|---|
| 1/16 | R-b |
| 2/16 | R-b |
| 3/16 | R-b |
| 4/16 | R-b |
| 5/16 | |
| 6/16 | R-b |
| 7/16 | R-b |
| 8/16 | |
| 9/16 | |
| 10/16 | R-b |
| 11/16 | |
| 12/16 | |
| 13/16 | |
| 14/16 | |
| 15/16 | |
| 16/16 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 00/16] KVM: arm64: MMIO guard PV services
This is the second version of this series initially posted at [1] that aims at letting a guest express what it considers as MMIO, and only let this through to userspace. Together with the guest memory made (mostly) inaccessible to the host kernel and userspace, this allows an implementation of a hardened IO subsystem.
A lot has been fixed/revamped/improved since the initial posting, although I am still not pleased with the ioremap plugging on the guest side. I'll take any idea to get rid of it!
The series is based on 5.15-rc3.
[1] https://lore.kernel.org/kvmarm/[email protected]
Marc Zyngier (16):
KVM: arm64: Generalise VM features into a set of flags
KVM: arm64: Check for PTE valitity when checking for
executable/cacheable
KVM: arm64: Turn kvm_pgtable_stage2_set_owner into
kvm_pgtable_stage2_annotate
KVM: arm64: Add MMIO checking infrastructure
KVM: arm64: Plumb MMIO checking into the fault handling
KVM: arm64: Force a full unmap on vpcu reinit
KVM: arm64: Wire MMIO guard hypercalls
KVM: arm64: Add tracepoint for failed MMIO guard check
KVM: arm64: Advertise a capability for MMIO guard
KVM: arm64: Add some documentation for the MMIO guard feature firmware/smccc: Call arch-specific hook on discovering KVM services mm/vmalloc: Add arch-specific callbacks to track io{remap,unmap}
physical pages
arm64: Implement ioremap/iounmap hooks calling into KVM's MMIO guard
arm64: Enroll into KVM's MMIO guard if required
arm64: Add a helper to retrieve the PTE of a fixmap
arm64: Register earlycon fixmap with the MMIO guard
.../admin-guide/kernel-parameters.txt | 3 + Documentation/virt/kvm/arm/index.rst | 1 + Documentation/virt/kvm/arm/mmio-guard.rst | 74 ++++++++ arch/arm/include/asm/hypervisor.h | 1 + arch/arm64/Kconfig | 1 + arch/arm64/include/asm/fixmap.h | 2 + arch/arm64/include/asm/hypervisor.h | 2 + arch/arm64/include/asm/kvm_host.h | 14 +- arch/arm64/include/asm/kvm_mmu.h | 5 + arch/arm64/include/asm/kvm_pgtable.h | 12 +- arch/arm64/kernel/setup.c | 6 + arch/arm64/kvm/arm.c | 30 ++-- arch/arm64/kvm/hyp/include/nvhe/mem_protect.h | 2 +- arch/arm64/kvm/hyp/nvhe/mem_protect.c | 11 +- arch/arm64/kvm/hyp/nvhe/setup.c | 10 +- arch/arm64/kvm/hyp/pgtable.c | 29 ++-- arch/arm64/kvm/hypercalls.c | 38 ++++ arch/arm64/kvm/mmio.c | 20 ++- arch/arm64/kvm/mmu.c | 111 ++++++++++++ arch/arm64/kvm/psci.c | 8 + arch/arm64/kvm/trace_arm.h | 17 ++ arch/arm64/mm/ioremap.c | 162 ++++++++++++++++++ arch/arm64/mm/mmu.c | 15 ++ drivers/firmware/smccc/kvm_guest.c | 4 + include/linux/arm-smccc.h | 28 +++ include/linux/io.h | 2 + include/uapi/linux/kvm.h | 1 + mm/Kconfig | 5 + mm/vmalloc.c | 12 +- 29 files changed, 575 insertions(+), 51 deletions(-) create mode 100644 Documentation/virt/kvm/arm/mmio-guard.rst
Signature · 1 line
2.30.2