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] Fix the fake e820 map for dom0 and unpriv domains, reque

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Fix the fake e820 map for dom0 and unpriv domains, request certain
From: BitKeeper Bot <riel@xxxxxxxxxxx>
Date: Thu, 12 May 2005 00:59:33 +0000
Delivery-date: Thu, 12 May 2005 16:03:39 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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 Development List <xen-devel@xxxxxxxxxxxxxxxxxxx>
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
ChangeSet 1.1428.1.21, 2005/05/12 01:59:33+01:00, mwilli2@xxxxxxxxxxxxxxxxxxxx

        Fix the fake e820 map for dom0 and unpriv domains, request certain
        resources only when in dom0.
        
        This makes /proc/iomem look "more" normal and makes kernel IO memory
        resource tree more accurate.
        
        Signed-off-by: mark.williamson@xxxxxxxxxxxx



 arch/xen/i386/kernel/setup.c                        |    9 +++++++--
 include/asm-xen/asm-i386/mach-xen/setup_arch_post.h |    7 ++++++-
 2 files changed, 13 insertions(+), 3 deletions(-)


diff -Nru a/linux-2.6.11-xen-sparse/arch/xen/i386/kernel/setup.c 
b/linux-2.6.11-xen-sparse/arch/xen/i386/kernel/setup.c
--- a/linux-2.6.11-xen-sparse/arch/xen/i386/kernel/setup.c      2005-05-12 
12:04:09 -04:00
+++ b/linux-2.6.11-xen-sparse/arch/xen/i386/kernel/setup.c      2005-05-12 
12:04:09 -04:00
@@ -289,6 +289,10 @@
        unsigned char *rom;
        int           i;
 
+        /* Nothing to do if not running in dom0. */
+       if ( !(xen_start_info.flags & SIF_INITDOMAIN) )
+                return;
+
        /* video rom */
        upper = adapter_rom_resources[0].start;
        for (start = video_rom_resource.start; start < upper; start += 2048) {
@@ -1213,8 +1217,9 @@
        else
                legacy_init_iomem_resources(&code_resource, &data_resource);
 
-       /* EFI systems may still have VGA */
-       request_resource(&iomem_resource, &video_ram_resource);
+       if ( xen_start_info.flags & SIF_INITDOMAIN )
+                /* EFI systems may still have VGA */
+                request_resource(&iomem_resource, &video_ram_resource);
 
        /* request I/O space for devices used on all i[345]86 PCs */
        for (i = 0; i < STANDARD_IO_RESOURCES; i++)
diff -Nru 
a/linux-2.6.11-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h 
b/linux-2.6.11-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h
--- 
a/linux-2.6.11-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h   
    2005-05-12 12:04:09 -04:00
+++ 
b/linux-2.6.11-xen-sparse/include/asm-xen/asm-i386/mach-xen/setup_arch_post.h   
    2005-05-12 12:04:09 -04:00
@@ -13,7 +13,12 @@
 
        who = "Xen";
 
-       start_pfn = 0;
+        /* In dom0, we have to start the fake e820 map above the first 1MB, in
+         * other domains, it can start at 0. */
+       if ( xen_start_info.flags & SIF_INITDOMAIN )
+                start_pfn = 0x100;
+        else
+                start_pfn = 0;
        max_pfn = xen_start_info.nr_pages;
 
        e820.nr_map = 0;

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Fix the fake e820 map for dom0 and unpriv domains, request certain, BitKeeper Bot <=