From: Zhang Xiantao <[EMAIL PROTECTED]>
Date: Sat, 8 Dec 2007 10:38:04 +0800
Subject: [PATCH] kvm: qemu : Changing memory align size to
TARGET_PAGE_SIZE.

Since other cpus may use big page size, allocated memory must
bed aligned with host page size. Otherwise, it will block userspace
memory allocatoin mechanism.
Signed-off-by: Zhang Xiantao <[EMAIL PROTECTED]>
---
 qemu/osdep.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/qemu/osdep.c b/qemu/osdep.c
index 0eaf2ba..195eefc 100644
--- a/qemu/osdep.c
+++ b/qemu/osdep.c
@@ -183,7 +183,7 @@ void *qemu_vmalloc(size_t size)
 #ifdef _BSD
     return valloc(size);
 #else
-    return memalign(4096, size);
+    return memalign(TARGET_PAGE_SIZE, size);
 #endif
 }
 
-- 
1.5.2

Attachment: 0022-kvm-qemu-Changing-memory-align-size-to-TARGET_PAG.patch
Description: 0022-kvm-qemu-Changing-memory-align-size-to-TARGET_PAG.patch

-------------------------------------------------------------------------
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

Reply via email to