Re: [PATCH v3] arm64: mpam: Document when to set arm64.nompam
From: Ben Horgan
Date: Fri Sep 25 2026 - 05:26:36 EST
Hi Fuad,
On 08/09/2026 15:56, Fuad Tabba wrote:
> arm64.nompam skips the MPAM2_EL2 and MPAMHCR_EL2 writes in
> finalise_el2_state and leaves the ARM64_MPAM cpucap unset. Where EL3
> firmware has cleared MPAM3_EL3.TRAPLOWER, the EL2 trap controls are
> left unwritten, at reset values that are UNKNOWN, and KVM still hides
> MPAM from the guest but no longer enables the traps that stop a guest
> from using it. KVM never saves or restores MPAM0_EL1, MPAM1_EL1 and
> MPAMSM_EL1, so what one guest writes reaches the next guest and the
> host. Nor can the kernel make the EL2 writes unconditionally: they trap
> to EL3 on the firmware the option exists for, and TRAPLOWER cannot be
> read below EL3.
>
> Say so in mpam.rst, and add the rule and a pointer to the
> kernel-parameters entry.
>
> Suggested-by: Ben Horgan <ben.horgan@xxxxxxx>
> Link: https://lore.kernel.org/all/CA+EHjTxeWxZiuSmnKLGLxTBXP4oJT7-LuffbPAyCSZZ5TW=5Ew@xxxxxxxxxxxxxx/
> Reviewed-by: Bradley Morgan <brads@xxxxxxxxxxxxxx>
> Signed-off-by: Fuad Tabba <fuad.tabba@xxxxxxxxx>
Reviewed-by: Ben Horgan <ben.horgan@xxxxxxx>
Thanks,
Ben