]> git.ipfire.org Git - thirdparty/qemu.git/commit
hw/arm/virt: Register two redistributor regions when necessary
authorEric Auger <eric.auger@redhat.com>
Fri, 22 Jun 2018 12:28:37 +0000 (13:28 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Fri, 22 Jun 2018 12:28:37 +0000 (13:28 +0100)
commit03d72fa13cef2454aeaedea387a2e505c77481b4
tree53a69301e1167c0973e6626016d8af9fbd78ca7e
parenta1de312f5690a1a4f3ff37319045f6ec7bdfcd31
hw/arm/virt: Register two redistributor regions when necessary

With a VGICv3 KVM device, if the number of vcpus exceeds the
capacity of the legacy redistributor region (123 redistributors),
we now attempt to register a second redistributor region. Up to
512 redistributors can fit in this latter on top of the 123 allowed
by the legacy redistributor region.

Registering this second redistributor region is possible if the
host kernel supports the following VGICv3 KVM device group/attribute:
KVM_DEV_ARM_VGIC_GRP_ADDR/KVM_VGIC_V3_ADDR_TYPE_REDIST_REGION.

In case the host kernel does not support the registration of several
redistributor regions and the requested number of vcpus exceeds the
capacity of the legacy redistributor region, the GICv3 device
initialization fails with a proper error message and qemu exits.

At the moment the max number of vcpus still is capped by the
virt machine class max_cpus.

Signed-off-by: Eric Auger <eric.auger@redhat.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Message-id: 1529072910-16156-8-git-send-email-eric.auger@redhat.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
hw/arm/virt.c