Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 329831
b: refs/heads/master
c: aab2eb7
h: refs/heads/master
i:
  329829: 9b8c232
  329827: d65ca09
  329823: 5d77b50
v: v3
  • Loading branch information
Takuya Yoshikawa authored and Avi Kivity committed Aug 6, 2012
1 parent dc80d3c commit 52281b0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fe56097b23b1303b894eefd91582e4a64247d03f
refs/heads/master: aab2eb7a38e0e510874acca01838f5badbca6c7e
4 changes: 2 additions & 2 deletions trunk/arch/x86/kvm/x86.c
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down Expand Up @@ -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,
Expand Down

0 comments on commit 52281b0

Please sign in to comment.