Re: [PATCH v5 11/41] KVM: arm64: Force guest EL1 to use user-space's partid configuration
From: Marc Zyngier
Date: Mon Mar 02 2026 - 12:59:12 EST
On Tue, 24 Feb 2026 17:56:50 +0000,
Ben Horgan <ben.horgan@xxxxxxx> wrote:
>
> From: James Morse <james.morse@xxxxxxx>
>
> While we trap the guest's attempts to read/write the MPAM control
> registers, the hardware continues to use them. Guest-EL0 uses KVM's
> user-space's configuration, as the value is left in the register, and
> guest-EL1 uses either the host kernel's configuration, or in the case of
> VHE, the UNKNOWN reset value of MPAM1_EL1.
>
> We want to force the guest-EL1 to use KVM's user-space's MPAM
> configuration. On nVHE rely on MPAM0_EL1 and MPAM1_EL1 always being
> programmed the same and on VHE copy MPAM0_EL1 into the guest's
> MPAM1_EL1. There is no need to restore as this is out of context once TGE
> is set.
>
> Tested-by: Gavin Shan <gshan@xxxxxxxxxx>
> Tested-by: Shaopeng Tan <tan.shaopeng@xxxxxxxxxxxxxx>
> Tested-by: Peter Newman <peternewman@xxxxxxxxxx>
> Tested-by: Zeng Heng <zengheng4@xxxxxxxxxx>
> Reviewed-by: Shaopeng Tan <tan.shaopeng@xxxxxxxxxxxxxx>
> Reviewed-by: Jonathan Cameron <jonathan.cameron@xxxxxxxxxx>
> Signed-off-by: James Morse <james.morse@xxxxxxx>
> Signed-off-by: Ben Horgan <ben.horgan@xxxxxxx>
Acked-by: Marc Zyngier <maz@xxxxxxxxxx>
M.
--
Without deviation from the norm, progress is not possible.