From ee5f6afa3e5557dd9007e6691f73599eb96480b0 Mon Sep 17 00:00:00 2001 From: Takuya Yoshikawa Date: Wed, 27 Feb 2013 19:43:44 +0900 Subject: [PATCH] --- yaml --- r: 372959 b: refs/heads/master c: 74d0727cb7aaaea48a6353209093be26abc8d160 h: refs/heads/master i: 372957: 4b6a424b0d8757e2cc63b488c54736a6e5685d2f 372955: 9f4eabe6899644238e21acfb9832a4877c090ff5 372951: 88f87ad8d072698902bf52b24d45e4f5ab66e5eb 372943: 06f0f4f1fd483fff14f3849d4bcebedac901b977 372927: 12083299421ec3194a893fc73814fae5dd4e7b88 v: v3 --- [refs] | 2 +- trunk/include/linux/kvm_host.h | 18 ++++++++++++++++++ trunk/virt/kvm/kvm_main.c | 18 ------------------ 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/[refs] b/[refs] index 1e41cba95464..cfc7694ba874 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 47ae31e257c548abdb199e0d26723139a9a967ba +refs/heads/master: 74d0727cb7aaaea48a6353209093be26abc8d160 diff --git a/trunk/include/linux/kvm_host.h b/trunk/include/linux/kvm_host.h index 84a994c7a5c5..8eaf61f7b02d 100644 --- a/trunk/include/linux/kvm_host.h +++ b/trunk/include/linux/kvm_host.h @@ -452,6 +452,24 @@ id_to_memslot(struct kvm_memslots *slots, int id) return slot; } +/* + * KVM_SET_USER_MEMORY_REGION ioctl allows the following operations: + * - create a new memory slot + * - delete an existing memory slot + * - modify an existing memory slot + * -- move it in the guest physical memory space + * -- just change its flags + * + * Since flags can be changed by some of these operations, the following + * differentiation is the best we can do for __kvm_set_memory_region(): + */ +enum kvm_mr_change { + KVM_MR_CREATE, + KVM_MR_DELETE, + KVM_MR_MOVE, + KVM_MR_FLAGS_ONLY, +}; + int kvm_set_memory_region(struct kvm *kvm, struct kvm_userspace_memory_region *mem); int __kvm_set_memory_region(struct kvm *kvm, diff --git a/trunk/virt/kvm/kvm_main.c b/trunk/virt/kvm/kvm_main.c index 5b3e41b81f0d..c7979ed41923 100644 --- a/trunk/virt/kvm/kvm_main.c +++ b/trunk/virt/kvm/kvm_main.c @@ -718,24 +718,6 @@ static struct kvm_memslots *install_new_memslots(struct kvm *kvm, return old_memslots; } -/* - * KVM_SET_USER_MEMORY_REGION ioctl allows the following operations: - * - create a new memory slot - * - delete an existing memory slot - * - modify an existing memory slot - * -- move it in the guest physical memory space - * -- just change its flags - * - * Since flags can be changed by some of these operations, the following - * differentiation is the best we can do for __kvm_set_memory_region(): - */ -enum kvm_mr_change { - KVM_MR_CREATE, - KVM_MR_DELETE, - KVM_MR_MOVE, - KVM_MR_FLAGS_ONLY, -}; - /* * Allocate some memory and give it an address in the guest physical address * space.