Loading
KVM: arm64: Split teardown hypercall into two phases
In preparation for reclaiming protected guest VM pages from the host during teardown, split the current 'pkvm_teardown_vm' hypercall into separate 'start' and 'finalise' calls. The 'pkvm_start_teardown_vm' hypercall puts the VM into a new 'is_dying' state, which is a point of no return past which no vCPU of the pVM is allowed to run any more. Once in this new state, 'pkvm_finalize_teardown_vm' can be used to reclaim meta-data and page-table pages from the VM. A subsequent patch will add support for reclaiming the individual guest memory pages. Reviewed-by:Fuad Tabba <tabba@google.com> Tested-by:
Fuad Tabba <tabba@google.com> Tested-by:
Mostafa Saleh <smostafa@google.com> Co-developed-by:
Quentin Perret <qperret@google.com> Signed-off-by:
Quentin Perret <qperret@google.com> Signed-off-by:
Will Deacon <will@kernel.org> Link: https://patch.msgid.link/20260330144841.26181-12-will@kernel.org Signed-off-by:
Marc Zyngier <maz@kernel.org>