On Thu, Apr 10, 2014 at 01:16:44PM +0200, Christian Borntraeger wrote:
> From: Dominik Dingel <din...@linux.vnet.ibm.com>
> 
> To enable CMMA and to reset its state we use the vm kvm_device ioctls,
> encapsulating attributes within the KVM_S390_VM_MEM_CTRL group.
> 
> Signed-off-by: Dominik Dingel <din...@linux.vnet.ibm.com>
> Signed-off-by: Christian Borntraeger <borntrae...@de.ibm.com>
> ---
>  Documentation/virtual/kvm/devices/vm.txt | 18 ++++++++++++++
>  arch/s390/include/uapi/asm/kvm.h         |  7 ++++++
>  arch/s390/kvm/kvm-s390.c                 | 42 
> ++++++++++++++++++++++++++++++++
>  3 files changed, 67 insertions(+)

Sounds awkward to use these three ioctls for something not 
returned by KVM_CREATE_DEVICE.

/* ioctls for fds returned by KVM_CREATE_DEVICE */
#define KVM_SET_DEVICE_ATTR       _IOW(KVMIO,  0xe1, struct kvm_device_attr)
#define KVM_GET_DEVICE_ATTR       _IOW(KVMIO,  0xe2, struct kvm_device_attr)
#define KVM_HAS_DEVICE_ATTR       _IOW(KVMIO,  0xe3, struct kvm_device_attr)

Is that much of a problem to introduce

struct kvm_vm_attr and

/* ioctls for fds returned by KVM_CREATE_VM */
#define KVM_SET_VM_ATTR       _IOW(KVMIO,  0xa, struct kvm_vm_attr)
#define KVM_GET_VM_ATTR       _IOW(KVMIO,  0xb, struct kvm_vm_attr)
#define KVM_HAS_VM_ATTR       _IOW(KVMIO,  0xc, struct kvm_vm_attr)

?

Other than that (which would be mostly organizational issue) per-vm
attributes seem fine to me.

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to