linux_dsm_epyc7002/arch/arm64/kvm
Marc Zyngier 5107000faa KVM: arm64: Make KVM_CAP_MAX_VCPUS compatible with the selected GIC version
KVM_CAP_MAX_VCPUS always return the maximum possible number of
VCPUs, irrespective of the selected interrupt controller. This
is pretty misleading for userspace that selects a GICv2 on a GICv3
system that supports v2 compat: It always gets a maximum of 512
VCPUs, even if the effective limit is 8. The 9th VCPU will fail
to be created, which is unexpected as far as userspace is concerned.

Fortunately, we already have the right information stashed in the
kvm structure, and we can return it as requested.

Reported-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Tested-by: Alexandru Elisei <alexandru.elisei@arm.com>
Reviewed-by: Alexandru Elisei <alexandru.elisei@arm.com>
Link: https://lore.kernel.org/r/20200427141507.284985-1-maz@kernel.org
2020-05-16 15:05:02 +01:00
..
hyp KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
vgic KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
aarch32.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
arch_timer.c KVM: arm64: Simplify __kvm_timer_set_cntvoff implementation 2020-05-16 15:04:18 +01:00
arm.c KVM: arm64: Make KVM_CAP_MAX_VCPUS compatible with the selected GIC version 2020-05-16 15:05:02 +01:00
debug.c KVM: arm64: Write arch.mdcr_el2 changes since last vcpu_load on VHE 2020-01-22 18:38:04 +00:00
fpsimd.c KVM: Remove unnecessary asm/kvm_host.h includes 2020-03-16 17:57:34 +01:00
guest.c KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
handle_exit.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
hyp-init.S arm64: use mov_q instead of literal ldr 2020-03-24 11:48:24 +00:00
hyp.S arm64: kvm: Annotate assembly using modern annoations 2020-03-09 17:35:29 +00:00
hypercalls.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
inject_fault.c KVM: arm64: Correct PSTATE on exception entry 2020-01-19 18:06:13 +00:00
irq.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 422 2019-06-05 17:37:15 +02:00
Kconfig KVM: arm64: Change CONFIG_KVM to a menuconfig entry 2020-05-16 15:04:18 +01:00
Makefile KVM: arm64: Clean up kvm makefiles 2020-05-16 15:04:18 +01:00
mmio.c KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
mmu.c KVM: arm64: Support enabling dirty log gradually in small chunks 2020-05-16 15:05:02 +01:00
perf.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
pmu-emul.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
pmu.c KVM: arm64: Move pmu hyp code under hyp's Makefile to avoid instrumentation 2019-05-24 14:53:20 +01:00
psci.c KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
pvtime.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
regmap.c arm64: KVM: regmap: Fix unexpected switch fall-through 2019-07-26 15:33:41 +01:00
reset.c KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
sys_regs_generic_v8.c KVM: Remove unnecessary asm/kvm_host.h includes 2020-03-16 17:57:34 +01:00
sys_regs.c KVM: Fix spelling in code comments 2020-05-16 15:05:01 +01:00
sys_regs.h KVM: arm64: Sanely ratelimit sysreg messages 2019-12-06 11:41:45 +00:00
trace_arm.h KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
trace_handle_exit.h KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
trace.h KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00
va_layout.c arm64: kvm: Fix IDMAP overlap with HYP VA 2020-01-19 16:05:23 +00:00
vgic-sys-reg-v3.c KVM: arm64: Move virt/kvm/arm to arch/arm64 2020-05-16 15:03:59 +01:00