WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [linux-2.6.18-xen] Setup memory zones in the same way as

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] Setup memory zones in the same way as native instead of putting all
From: "Xen patchbot-linux-2.6.18-xen" <patchbot-linux-2.6.18-xen@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 10 Dec 2007 08:10:17 -0800
Delivery-date: Mon, 10 Dec 2007 08:11:12 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Ian Campbell <ian.campbell@xxxxxxxxxx>
# Date 1197299089 0
# Node ID b865b15fb54b35e08940b8143c0e3392effc07e9
# Parent  c3ff0b26f664b46a542505c98ea418b0268b516d
Setup memory zones in the same way as native instead of putting all
low memory in ZONE_DMA. There is no real benefit from diverging from
native in this respect.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxxxxx>
---
 arch/i386/kernel/setup-xen.c |    9 +--------
 arch/x86_64/mm/init-xen.c    |    8 --------
 2 files changed, 1 insertion(+), 16 deletions(-)

diff -r c3ff0b26f664 -r b865b15fb54b arch/i386/kernel/setup-xen.c
--- a/arch/i386/kernel/setup-xen.c      Mon Dec 10 13:52:47 2007 +0000
+++ b/arch/i386/kernel/setup-xen.c      Mon Dec 10 15:04:49 2007 +0000
@@ -1305,14 +1305,7 @@ void __init zone_sizes_init(void)
        unsigned long zones_size[MAX_NR_ZONES] = {0, 0, 0};
        unsigned int max_dma, low;
 
-       /*
-        * XEN: Our notion of "DMA memory" is fake when running over Xen.
-        * We simply put all RAM in the DMA zone so that those drivers which
-        * needlessly specify GFP_DMA do not get starved of RAM unnecessarily.
-        * Those drivers that *do* require lowmem are screwed anyway when
-        * running over Xen!
-        */
-       max_dma = max_low_pfn;
+       max_dma = virt_to_phys((char *)MAX_DMA_ADDRESS) >> PAGE_SHIFT;
        low = max_low_pfn;
 
        if (low < max_dma)
diff -r c3ff0b26f664 -r b865b15fb54b arch/x86_64/mm/init-xen.c
--- a/arch/x86_64/mm/init-xen.c Mon Dec 10 13:52:47 2007 +0000
+++ b/arch/x86_64/mm/init-xen.c Mon Dec 10 15:04:49 2007 +0000
@@ -775,14 +775,11 @@ size_zones(unsigned long *z, unsigned lo
           unsigned long start_pfn, unsigned long end_pfn)
 {
        int i;
-#ifndef CONFIG_XEN
        unsigned long w;
-#endif
 
        for (i = 0; i < MAX_NR_ZONES; i++)
                z[i] = 0;
 
-#ifndef CONFIG_XEN
        if (start_pfn < MAX_DMA_PFN)
                z[ZONE_DMA] = MAX_DMA_PFN - start_pfn;
        if (start_pfn < MAX_DMA32_PFN) {
@@ -823,11 +820,6 @@ size_zones(unsigned long *z, unsigned lo
                        h[ZONE_DMA] = z[ZONE_DMA];
                }
        }
-#else
-       z[ZONE_DMA] = end_pfn;
-       for (i = 0; i < MAX_NR_ZONES; i++)
-               h[i] = 0;
-#endif
 }
 
 #ifndef CONFIG_NUMA

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [linux-2.6.18-xen] Setup memory zones in the same way as native instead of putting all, Xen patchbot-linux-2.6.18-xen <=