[PATCH 2/4] arm64/fpsimd: Discover maximum vector length implemented by any CPU

Mark Brown broonie at kernel.org
Wed Jun 5 05:31:38 PDT 2024


On Wed, Jun 05, 2024 at 01:13:20PM +0100, Marc Zyngier wrote:
> Mark Brown <broonie at kernel.org> wrote:

> > +	/*
> > +	 * pKVM allocates and uses storage for host state based on the
> > +	 * largest per-PE VL, reject new PEs with a larger maximum.
> > +	 */
> > +	if (is_protected_kvm_enabled()) {
> > +		if (max_vl > info->max_cpu_vl) {
> > +			pr_warn("%s: cpu%d: would increase maximum VL\n",
> > +				info->name, smp_processor_id());
> > +			return -EINVAL;
> > +		}
> > +	}

> Once protected mode is enabled, no new CPU can be booted (see
> psci_relay.c::psci_cpu_on()).

Ah, that's a bit easier.  Might still be worth keeping the check just in
case that changes or we acquire some further use of this value but it's
not currently needed and the comment could be updated.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20240605/90b7a9e0/attachment.sig>


More information about the linux-arm-kernel mailing list