This commit is contained in:
committed by
Git OBS Bridge
parent
241ee9df04
commit
d7002a96b9
@@ -1,7 +1,7 @@
|
||||
Index: xen-unstable/xen/arch/x86/x86_32/mm.c
|
||||
Index: xen-3.0.4-testing/xen/arch/x86/x86_32/mm.c
|
||||
===================================================================
|
||||
--- xen-unstable.orig/xen/arch/x86/x86_32/mm.c
|
||||
+++ xen-unstable/xen/arch/x86/x86_32/mm.c
|
||||
--- xen-3.0.4-testing.orig/xen/arch/x86/x86_32/mm.c
|
||||
+++ xen-3.0.4-testing/xen/arch/x86/x86_32/mm.c
|
||||
@@ -62,6 +62,8 @@ l2_pgentry_t *virt_to_xen_l2e(unsigned l
|
||||
return &idle_pg_table_l2[l2_linear_offset(v)];
|
||||
}
|
||||
@@ -11,37 +11,49 @@ Index: xen-unstable/xen/arch/x86/x86_32/mm.c
|
||||
void __init paging_init(void)
|
||||
{
|
||||
void *ioremap_pt;
|
||||
@@ -129,6 +131,20 @@ void __init setup_idle_pagetable(void)
|
||||
l2e_from_page(virt_to_page(idle_vcpu[0]->domain->
|
||||
arch.mm_perdomain_pt) + i,
|
||||
__PAGE_HYPERVISOR);
|
||||
@@ -130,6 +132,20 @@ void __init setup_idle_pagetable(void)
|
||||
l2e_from_page(virt_to_page(idle_vcpu[0]->domain->
|
||||
arch.mm_perdomain_pt) + i,
|
||||
__PAGE_HYPERVISOR));
|
||||
+
|
||||
+ /*
|
||||
+ * Size the lowmem_emergency_pool based on the total memory on the box
|
||||
+ * This pool is needed only on 32 bit PAE configurations (4g to 16g).
|
||||
+ */
|
||||
+ if (lowmem_emergency_pool_pages)
|
||||
+ return;
|
||||
+ return;
|
||||
+
|
||||
+ if (total_pages > (4 * 1024 * 1024))
|
||||
+ lowmem_emergency_pool_pages = 12000;
|
||||
+ lowmem_emergency_pool_pages = 12000;
|
||||
+ else if (total_pages > (2 * 1024 * 1024))
|
||||
+ lowmem_emergency_pool_pages = 8000;
|
||||
+ lowmem_emergency_pool_pages = 8000;
|
||||
+ else if (total_pages > (1 * 1024 * 1024) || max_page >= (1 * 1024 * 1024))
|
||||
+ lowmem_emergency_pool_pages = 4000;
|
||||
+ lowmem_emergency_pool_pages = 4000;
|
||||
}
|
||||
|
||||
void __init zap_low_mappings(l2_pgentry_t *base)
|
||||
Index: xen-unstable/xen/common/page_alloc.c
|
||||
Index: xen-3.0.4-testing/xen/common/page_alloc.c
|
||||
===================================================================
|
||||
--- xen-unstable.orig/xen/common/page_alloc.c
|
||||
+++ xen-unstable/xen/common/page_alloc.c
|
||||
@@ -47,7 +47,7 @@ string_param("badpage", opt_badpage);
|
||||
* allocation requests. Ordinary requests will not fall back to the
|
||||
* lowmem emergency pool.
|
||||
*/
|
||||
-static unsigned long lowmem_emergency_pool_pages;
|
||||
--- xen-3.0.4-testing.orig/xen/common/page_alloc.c
|
||||
+++ xen-3.0.4-testing/xen/common/page_alloc.c
|
||||
@@ -46,6 +46,20 @@ static char opt_badpage[100] = "";
|
||||
string_param("badpage", opt_badpage);
|
||||
|
||||
/*
|
||||
+ * Amount of memory to reserve in a low-memory (<4GB) pool for specific
|
||||
+ * allocation requests. Ordinary requests will not fall back to the
|
||||
+ * lowmem emergency pool.
|
||||
+ */
|
||||
+unsigned long lowmem_emergency_pool_pages;
|
||||
static void parse_lowmem_emergency_pool(char *s)
|
||||
{
|
||||
unsigned long long bytes;
|
||||
+static void parse_lowmem_emergency_pool(char *s)
|
||||
+{
|
||||
+ unsigned long long bytes;
|
||||
+ bytes = parse_size_and_unit(s, NULL);
|
||||
+ lowmem_emergency_pool_pages = bytes >> PAGE_SHIFT;
|
||||
+}
|
||||
+custom_param("lowmem_emergency_pool", parse_lowmem_emergency_pool);
|
||||
+
|
||||
+/*
|
||||
* Bit width of the DMA heap.
|
||||
*/
|
||||
unsigned int dma_bitsize = CONFIG_DMA_BITSIZE;
|
||||
|
Reference in New Issue
Block a user