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] Eliminate hard coded items from i386 __xen_guest section

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Eliminate hard coded items from i386 __xen_guest section
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 20 Feb 2006 17:30:11 +0000
Delivery-date: Mon, 20 Feb 2006 17:44:50 +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-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User cl349@xxxxxxxxxxxxxxxxxxxx
# Node ID c93c6b392ce54e1f6e6b95529a90741b6b8b41e1
# Parent  946a45f07351a4ed399f96eb3d6867bfa28af6a2
Eliminate hard coded items from i386 __xen_guest section
to allow the new VMSPLIT_* Kconfig options to work, and to
avoid problems when the position of the hypercall page
changes.

From: Jan Beulich <JBeulich@xxxxxxxxxx>
Signed-off-by: Christian Limpach <Christian.Limpach@xxxxxxxxxxxx>

diff -r 946a45f07351 -r c93c6b392ce5 
linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S
--- a/linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S  Mon Feb 20 15:18:38 2006
+++ b/linux-2.6-xen-sparse/arch/i386/kernel/head-xen.S  Mon Feb 20 16:08:27 2006
@@ -1,23 +1,11 @@
 
+
+.text
 #include <linux/config.h>
-
-.section __xen_guest
-       .ascii  "GUEST_OS=linux,GUEST_VER=2.6"
-       .ascii  ",XEN_VER=xen-3.0"
-       .ascii  ",VIRT_BASE=0xC0000000"
-       .ascii  ",HYPERCALL_PAGE=0x104" /* __pa(hypercall_page) >> 12 */
-#ifdef CONFIG_X86_PAE
-       .ascii  ",PAE=yes"
-#else
-       .ascii  ",PAE=no"
-#endif
-       .ascii  ",LOADER=generic"
-       .byte   0
-
-.text
 #include <linux/threads.h>
 #include <linux/linkage.h>
 #include <asm/segment.h>
+#include <asm/page.h>
 #include <asm/thread_info.h>
 #include <asm/asm-offsets.h>
 #include <xen/interface/arch-x86_32.h>
@@ -190,12 +178,47 @@
 .org 0x3000
 ENTRY(default_ldt)
 
-.org 0x4000
+#define HYPERCALL_PAGE_OFFSET 0x4000
+.org HYPERCALL_PAGE_OFFSET
 ENTRY(hypercall_page)
-
-.org 0x5000
+.skip 0x1000
+
 /*
  * Real beginning of normal "text" segment
  */
 ENTRY(stext)
 ENTRY(_stext)
+
+
+/*
+ * __xen_guest information
+ */
+.macro bigutoa value
+       utoa (\value) >> 12
+       .ascii "000"
+.endm
+.macro utoa value
+ .if (\value) >= 16
+       utoa (\value) >> 4
+ .endif
+ .if (\value) % 16 < 10
+  .byte '0' + (\value) % 16
+ .else
+  .byte 'A' + (\value) % 16 - 10
+ .endif
+.endm
+
+.section __xen_guest
+       .ascii  "GUEST_OS=linux,GUEST_VER=2.6"
+       .ascii  ",XEN_VER=xen-3.0"
+       .ascii  ",VIRT_BASE=0x"
+                bigutoa __PAGE_OFFSET
+       .ascii  ",HYPERCALL_PAGE=0x"
+               utoa ((__PHYSICAL_START+HYPERCALL_PAGE_OFFSET)>>PAGE_SHIFT)
+#ifdef CONFIG_X86_PAE
+       .ascii  ",PAE=yes"
+#else
+       .ascii  ",PAE=no"
+#endif
+       .ascii  ",LOADER=generic"
+       .byte   0

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Eliminate hard coded items from i386 __xen_guest section, Xen patchbot -unstable <=