projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fe56097
)
KVM: Stop checking rmap to see if slot is being created
author
Takuya Yoshikawa
<
[email protected]
>
Wed, 1 Aug 2012 09:01:10 +0000
(18:01 +0900)
committer
Avi Kivity
<
[email protected]
>
Mon, 6 Aug 2012 09:47:02 +0000
(12:47 +0300)
Instead, check npages consistently. This helps to make rmap
architecture specific in a later patch.
Signed-off-by: Takuya Yoshikawa <
[email protected]
>
Signed-off-by: Avi Kivity <
[email protected]
>
arch/x86/kvm/x86.c
patch
|
blob
|
history
diff --git
a/arch/x86/kvm/x86.c
b/arch/x86/kvm/x86.c
index 3ca90d74711dc244afe36ca3f01595a1a69b0fda..abc039d7842882f5695d2835a94a87c83a24c93e 100644
(file)
--- a/
arch/x86/kvm/x86.c
+++ b/
arch/x86/kvm/x86.c
@@
-6385,7
+6385,7
@@
int kvm_arch_prepare_memory_region(struct kvm *kvm,
*x86 needs to handle !user_alloc case.
*/
if (!user_alloc) {
- if (npages && !old.
rmap
) {
+ if (npages && !old.
npages
) {
unsigned long userspace_addr;
userspace_addr = vm_mmap(NULL, 0,
@@
-6413,7
+6413,7
@@
void kvm_arch_commit_memory_region(struct kvm *kvm,
int nr_mmu_pages = 0, npages = mem->memory_size >> PAGE_SHIFT;
- if (!user_alloc && !old.user_alloc && old.
rmap
&& !npages) {
+ if (!user_alloc && !old.user_alloc && old.
npages
&& !npages) {
int ret;
ret = vm_munmap(old.userspace_addr,