|
|
|
|
|
|
|
|
|
|
xen-ia64-devel
[Xen-ia64-devel] [PATCH] change layout of p2m table from xenheap to domh
Hi,
Current xen can not fully utilize 64GB memory since xenheap is
exhausted by p2m tables.
This patch changes the layout of p2m table from xenheap to domheap.
The side effect is subtle performance down due to TLB miss.
A new boot option 'p2m_xenheap' enables the previous setting that p2m
table is allocated in xenheap.
I dare to change the default for the future.
If there are no objections, please apply.
Thanks,
Kouya
Signed-off-by: Kouya Shimura <kouya@xxxxxxxxxxxxxx>
diff -r 9fbaf07d3f67 xen/arch/ia64/xen/mm.c
--- a/xen/arch/ia64/xen/mm.c Thu Mar 08 09:50:25 2007 -0700
+++ b/xen/arch/ia64/xen/mm.c Mon Mar 12 17:45:56 2007 +0900
@@ -1903,9 +1903,20 @@ void __free_pages(struct page_info *page
free_xenheap_page(page);
}
+static int opt_p2m_xenheap;
+boolean_param("p2m_xenheap", opt_p2m_xenheap);
+
void *pgtable_quicklist_alloc(void)
{
void *p;
+ if (!opt_p2m_xenheap) {
+ struct page_info *page = alloc_domheap_page(NULL);
+ if (page == NULL)
+ return NULL;
+ p = page_to_virt(page);
+ clear_page(p);
+ return p;
+ }
p = alloc_xenheap_pages(0);
if (p)
clear_page(p);
@@ -1914,7 +1925,10 @@ void *pgtable_quicklist_alloc(void)
void pgtable_quicklist_free(void *pgtable_entry)
{
- free_xenheap_page(pgtable_entry);
+ if (!opt_p2m_xenheap)
+ free_domheap_page(virt_to_page(pgtable_entry));
+ else
+ free_xenheap_page(pgtable_entry);
}
void put_page_type(struct page_info *page)
_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- [Xen-ia64-devel] [PATCH] change layout of p2m table from xenheap to domheap,
Kouya SHIMURA <=
|
|
|
|
|