]> git.baikalelectronics.ru Git - kernel.git/commit
RISC-V: KVM: Reduce KVM_MAX_VCPUS value
authorAnup Patel <apatel@ventanamicro.com>
Mon, 9 May 2022 05:14:00 +0000 (10:44 +0530)
committerAnup Patel <anup@brainfault.org>
Fri, 20 May 2022 03:39:12 +0000 (09:09 +0530)
commitf2fff290ee43874299c55862a297a3dc4d977522
tree7a62d69d14f2069724df553c36a6864a8dd3f097
parentb678acd14ed44e1a612bbbbf6820ba0c6d4fcbbf
RISC-V: KVM: Reduce KVM_MAX_VCPUS value

Currently, the KVM_MAX_VCPUS value is 16384 for RV64 and 128
for RV32.

The KVM_MAX_VCPUS value is too high for RV64 and too low for
RV32 compared to other architectures (e.g. x86 sets it to 1024
and ARM64 sets it to 512). The too high value of KVM_MAX_VCPUS
on RV64 also leads to VCPU mask on stack consuming 2KB.

We set KVM_MAX_VCPUS to 1024 for both RV64 and RV32 to be
aligned other architectures.

Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Atish Patra <atishp@rivosinc.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
arch/riscv/include/asm/kvm_host.h