Re: [PATCH 06/30] KVM: arm64: Remove pointless is_protected_kvm_enabled() checks from hyp

Quentin Perret
2026-01-06T14:40:53Z

On Monday 05 Jan 2026 at 15:49:14 (+0000), Will Deacon wrote:
> When pKVM is not enabled, the host shouldn't issue pKVM-specific
> hypercalls and so there's no point checking for this in the EL2
> hypercall handling code.
>
> Remove the redundant is_protected_kvm_enabled() checks.

That made me wonder if we should further divide the HVC space to have a
'pKVM only' range in addition to the privileged/unprivileged split, so
we could WARN in the core HVC handler in the pretty unlikely event that
we take a pKVM-only call in {n,h}VHE.

But yes there is no point in littering the code with is_protected_kvm_enabled()
checks all over, so:

Reviewed-by: Quentin Perret <qperret@google.com>

Thanks,
Quentin