summaryrefslogtreecommitdiff
path: root/Documentation/virt/kvm/devices/xive.txt
diff options
context:
space:
mode:
authorGreg Kurz <groug@kaod.org>2019-09-27 13:54:07 +0200
committerPaul Mackerras <paulus@ozlabs.org>2019-10-22 16:29:02 +1100
commitefe5ddcae496b7c7307805d31815df23ba69bf7c (patch)
tree34417d20e68a6ae70435a7b6651d70972c3fed1b /Documentation/virt/kvm/devices/xive.txt
parent062cfab7069fcb55d77ad5552f29e24178728fa2 (diff)
downloadlwn-efe5ddcae496b7c7307805d31815df23ba69bf7c.tar.gz
lwn-efe5ddcae496b7c7307805d31815df23ba69bf7c.zip
KVM: PPC: Book3S HV: XIVE: Allow userspace to set the # of VPs
Add a new attribute to both XIVE and XICS-on-XIVE KVM devices so that userspace can tell how many interrupt servers it needs. If a VM needs less than the current default of KVM_MAX_VCPUS (2048), we can allocate less VPs in OPAL. Combined with a core stride (VSMT) that matches the number of guest threads per core, this may substantially increases the number of VMs that can run concurrently with an in-kernel XIVE device. Since the legacy XIVE KVM device is exposed to userspace through the XICS KVM API, a new attribute group is added to it for this purpose. While here, fix the syntax of the existing KVM_DEV_XICS_GRP_SOURCES in the XICS documentation. Signed-off-by: Greg Kurz <groug@kaod.org> Reviewed-by: Cédric Le Goater <clg@kaod.org> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
Diffstat (limited to 'Documentation/virt/kvm/devices/xive.txt')
-rw-r--r--Documentation/virt/kvm/devices/xive.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/Documentation/virt/kvm/devices/xive.txt b/Documentation/virt/kvm/devices/xive.txt
index 9a24a4525253..f5d1d6b5af61 100644
--- a/Documentation/virt/kvm/devices/xive.txt
+++ b/Documentation/virt/kvm/devices/xive.txt
@@ -78,6 +78,14 @@ the legacy interrupt mode, referred as XICS (POWER7/8).
migrating the VM.
Errors: none
+ 1.3 KVM_DEV_XIVE_NR_SERVERS (write only)
+ The kvm_device_attr.addr points to a __u32 value which is the number of
+ interrupt server numbers (ie, highest possible vcpu id plus one).
+ Errors:
+ -EINVAL: Value greater than KVM_MAX_VCPU_ID.
+ -EFAULT: Invalid user pointer for attr->addr.
+ -EBUSY: A vCPU is already connected to the device.
+
2. KVM_DEV_XIVE_GRP_SOURCE (write only)
Initializes a new source in the XIVE device and mask it.
Attributes: