All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oliver Upton <oliver.upton@linux.dev>
To: Joey Gouly <joey.gouly@arm.com>
Cc: linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev,
	anshuman.khandual@arm.com, gshan@redhat.com, james.morse@arm.com,
	shameerali.kolothum.thodi@huawei.com,
	Marc Zyngier <maz@kernel.org>,
	Suzuki K Poulose <suzuki.poulose@arm.com>,
	Zenghui Yu <yuzenghui@huawei.com>,
	Jing Zhang <jingzhangos@google.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will@kernel.org>
Subject: Re: [PATCH v6 0/7] KVM: arm64: Hide unsupported MPAM from the guest
Date: Wed, 30 Oct 2024 19:38:15 -0700	[thread overview]
Message-ID: <ZyLtl6lLSEczqHjF@linux.dev> (raw)
In-Reply-To: <20241030160317.2528209-1-joey.gouly@arm.com>

Hi,

Thanks for respinning this Joey.

On Wed, Oct 30, 2024 at 04:03:10PM +0000, Joey Gouly wrote:
> Hi,
> 
> changes since v5 [1]:
> 	- Removed Kconfig option, the KVM traps shouldn't rely on host kernel support
> 	- Renamed cpus_support_* to system_supports_* since that matches other functions
> 	- Replace static branch arm64_mpam_has_hcr with a normal cpufeature capability
> 	- Add MPAM*_EL2 regs to KVM (undef_access)
> 	- Use constants in the test, instead of hardcoded values
> 	- Added R-b and T-b tags
> 	- Rebased on v6.12-rc5
>
> James wrote:
> 	This series fixes up a long standing bug where MPAM was accidentally exposed
> 	to a guest, but the feature was not otherwise trapped or context switched.
> 	This could result in KVM warning about unexpected traps, and injecting an
> 	undef into the guest contradicting the ID registers.
> 	This would prevent an MPAM aware kernel from booting - fortunately, there
> 	aren't any of those.
> 
> 	Ideally, we'd take the MPAM feature away from the ID registers, but that
> 	would leave existing guests unable to migrate to a newer kernel. Instead,
> 	just ignore that field when it matches the hardware. KVM wasn't going to
> 	expose MPAM anyway. The guest will not see MPAM in the id registers.
> 
> 	This series includes the head.S and KVM changes to enable/disable traps. If
> 	MPAM is neither enabled nor emulated by EL3 firmware, these system register
> 	accesses will trap to EL3.
> 	If your kernel doesn't boot, and the problem bisects here - please update
> 	your firmware. MPAM has been supported by trusted firmware since v1.6 in
> 	2018. (also noted on patch 3).

This is looking pretty good to me, and I'd really like to have it in for
6.13.

Will/Catalin, first 3 patches look OK to you?

-- 
Thanks,
Oliver

  parent reply	other threads:[~2024-10-31  2:38 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-30 16:03 [PATCH v6 0/7] KVM: arm64: Hide unsupported MPAM from the guest Joey Gouly
2024-10-30 16:03 ` [PATCH v6 1/7] arm64/sysreg: Convert existing MPAM sysregs and add the remaining entries Joey Gouly
2024-10-31 11:49   ` Catalin Marinas
2024-10-30 16:03 ` [PATCH v6 2/7] arm64: head.S: Initialise MPAM EL2 registers and disable traps Joey Gouly
2024-10-31 11:49   ` Catalin Marinas
2024-10-30 16:03 ` [PATCH v6 3/7] arm64: cpufeature: discover CPU support for MPAM Joey Gouly
2024-10-31 11:44   ` Catalin Marinas
2024-10-30 16:03 ` [PATCH v6 4/7] KVM: arm64: Fix missing traps of guest accesses to the MPAM registers Joey Gouly
2024-10-30 16:03 ` [PATCH v6 5/7] KVM: arm64: Add a macro for creating filtered sys_reg_descs entries Joey Gouly
2024-10-31 13:10   ` Marc Zyngier
2024-10-30 16:03 ` [PATCH v6 6/7] KVM: arm64: Disable MPAM visibility by default and ignore VMM writes Joey Gouly
2024-10-30 16:03 ` [PATCH v6 7/7] KVM: arm64: selftests: Test ID_AA64PFR0.MPAM isn't completely ignored Joey Gouly
2024-10-31  3:13   ` Gavin Shan
2024-10-31  2:38 ` Oliver Upton [this message]
2024-10-31 13:11 ` [PATCH v6 0/7] KVM: arm64: Hide unsupported MPAM from the guest Marc Zyngier
2024-10-31 18:42 ` Oliver Upton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZyLtl6lLSEczqHjF@linux.dev \
    --to=oliver.upton@linux.dev \
    --cc=anshuman.khandual@arm.com \
    --cc=catalin.marinas@arm.com \
    --cc=gshan@redhat.com \
    --cc=james.morse@arm.com \
    --cc=jingzhangos@google.com \
    --cc=joey.gouly@arm.com \
    --cc=kvmarm@lists.linux.dev \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=maz@kernel.org \
    --cc=shameerali.kolothum.thodi@huawei.com \
    --cc=suzuki.poulose@arm.com \
    --cc=will@kernel.org \
    --cc=yuzenghui@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.