Revert "ANDROID: KVM: arm64: pkvm: Share memory with non-protected guests"

This reverts commit 8d6a327d52.

Bug: 233587962
Signed-off-by: Will Deacon <willdeacon@google.com>
Change-Id: I09b2c8ab0cca2e02680c1194d403b6eb04fc565c
This commit is contained in:
Will Deacon
2022-07-07 15:51:18 +01:00
parent 4a8d2c41f1
commit effcb9d307

View File

@@ -734,12 +734,8 @@ static void handle___pkvm_host_donate_guest(struct kvm_cpu_context *host_ctxt)
/* Topup shadow memcache with the host's */
ret = pkvm_refill_memcache(state->vcpu, vcpu);
if (!ret) {
if (state->is_protected)
ret = __pkvm_host_donate_guest(pfn, gfn, state->vcpu);
else
ret = __pkvm_host_share_guest(pfn, gfn, state->vcpu);
}
if (!ret)
ret = __pkvm_host_donate_guest(pfn, gfn, state->vcpu);
out:
cpu_reg(host_ctxt, 1) = ret;
}