Merge tag 'ceph-for-4.9-rc1' of git://github.com/ceph/ceph-client
[cascardo/linux.git] / Documentation / virtual / kvm / devices / vcpu.txt
1 Generic vcpu interface
2 ====================================
3
4 The virtual cpu "device" also accepts the ioctls KVM_SET_DEVICE_ATTR,
5 KVM_GET_DEVICE_ATTR, and KVM_HAS_DEVICE_ATTR. The interface uses the same struct
6 kvm_device_attr as other devices, but targets VCPU-wide settings and controls.
7
8 The groups and attributes per virtual cpu, if any, are architecture specific.
9
10 1. GROUP: KVM_ARM_VCPU_PMU_V3_CTRL
11 Architectures: ARM64
12
13 1.1. ATTRIBUTE: KVM_ARM_VCPU_PMU_V3_IRQ
14 Parameters: in kvm_device_attr.addr the address for PMU overflow interrupt is a
15             pointer to an int
16 Returns: -EBUSY: The PMU overflow interrupt is already set
17          -ENXIO: The overflow interrupt not set when attempting to get it
18          -ENODEV: PMUv3 not supported
19          -EINVAL: Invalid PMU overflow interrupt number supplied
20
21 A value describing the PMUv3 (Performance Monitor Unit v3) overflow interrupt
22 number for this vcpu. This interrupt could be a PPI or SPI, but the interrupt
23 type must be same for each vcpu. As a PPI, the interrupt number is the same for
24 all vcpus, while as an SPI it must be a separate number per vcpu.
25
26 1.2 ATTRIBUTE: KVM_ARM_VCPU_PMU_V3_INIT
27 Parameters: no additional parameter in kvm_device_attr.addr
28 Returns: -ENODEV: PMUv3 not supported
29          -ENXIO: PMUv3 not properly configured as required prior to calling this
30                  attribute
31          -EBUSY: PMUv3 already initialized
32
33 Request the initialization of the PMUv3.  This must be done after creating the
34 in-kernel irqchip.  Creating a PMU with a userspace irqchip is currently not
35 supported.