mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
KVM: s390: Per-vm kvm device controls
We sometimes need to get/set attributes specific to a virtual machine and so need something else than ONE_REG. Let's copy the KVM_DEVICE approach, and define the respective ioctls for the vm file descriptor. Signed-off-by: Dominik Dingel <[email protected]> Reviewed-by: Cornelia Huck <[email protected]> Acked-by: Alexander Graf <[email protected]> Signed-off-by: Christian Borntraeger <[email protected]>
This commit is contained in:
parent
15f36ebd34
commit
f206165620
4 changed files with 69 additions and 4 deletions
|
|
@ -2314,8 +2314,8 @@ struct kvm_create_device {
|
|||
|
||||
4.80 KVM_SET_DEVICE_ATTR/KVM_GET_DEVICE_ATTR
|
||||
|
||||
Capability: KVM_CAP_DEVICE_CTRL
|
||||
Type: device ioctl
|
||||
Capability: KVM_CAP_DEVICE_CTRL, KVM_CAP_VM_ATTRIBUTES for vm device
|
||||
Type: device ioctl, vm ioctl
|
||||
Parameters: struct kvm_device_attr
|
||||
Returns: 0 on success, -1 on error
|
||||
Errors:
|
||||
|
|
@ -2340,8 +2340,8 @@ struct kvm_device_attr {
|
|||
|
||||
4.81 KVM_HAS_DEVICE_ATTR
|
||||
|
||||
Capability: KVM_CAP_DEVICE_CTRL
|
||||
Type: device ioctl
|
||||
Capability: KVM_CAP_DEVICE_CTRL, KVM_CAP_VM_ATTRIBUTES for vm device
|
||||
Type: device ioctl, vm ioctl
|
||||
Parameters: struct kvm_device_attr
|
||||
Returns: 0 on success, -1 on error
|
||||
Errors:
|
||||
|
|
|
|||
10
Documentation/virtual/kvm/devices/vm.txt
Normal file
10
Documentation/virtual/kvm/devices/vm.txt
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
Generic vm interface
|
||||
====================================
|
||||
|
||||
The virtual machine "device" also accepts the ioctls KVM_SET_DEVICE_ATTR,
|
||||
KVM_GET_DEVICE_ATTR, and KVM_HAS_DEVICE_ATTR. The interface uses the same
|
||||
struct kvm_device_attr as other devices, but targets VM-wide settings
|
||||
and controls.
|
||||
|
||||
The groups and attributes per virtual machine, if any, are architecture
|
||||
specific.
|
||||
Loading…
Reference in a new issue