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] [xen-unstable] [IA64] Fix qemu memory access on IA64

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [IA64] Fix qemu memory access on IA64
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 03 Mar 2008 07:30:07 -0800
Delivery-date: Mon, 03 Mar 2008 07:30:02 -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 Alex Williamson <alex.williamson@xxxxxx>
# Date 1203694832 25200
# Node ID 3d6e463d08a27f14c6d7bcef0f20cb03d18fb4cb
# Parent  8338290757c56c507d6e705e5dee3510fccdc484
[IA64] Fix qemu memory access on IA64

- Correct a parameter to xc_map_foreign_batch(). skipping vga hole.
- sync_icache() might overrun a page boundary. qemu-dm will die.

This re-enables HVM support after cset
99478ffd81ee8685e6376210a1bd654c3790bf8d in linux-2.6.18-xen.hg

Signed-off-by: Kouya Shimura <kouya@xxxxxxxxxxxxxx>
---
 tools/ioemu/hw/xen_machine_fv.c      |   10 ++++++++--
 tools/ioemu/target-i386-dm/exec-dm.c |   13 +++++++------
 2 files changed, 15 insertions(+), 8 deletions(-)

diff -r 8338290757c5 -r 3d6e463d08a2 tools/ioemu/hw/xen_machine_fv.c
--- a/tools/ioemu/hw/xen_machine_fv.c   Fri Feb 22 10:52:27 2008 +0000
+++ b/tools/ioemu/hw/xen_machine_fv.c   Fri Feb 22 08:40:32 2008 -0700
@@ -246,12 +246,18 @@ static void xen_init_fv(uint64_t ram_siz
 
     for (i = 0; i < nr_pages; i++)
         page_array[i] = i;
-       
+
     /* VTI will not use memory between 3G~4G, so we just pass a legal pfn
        to make QEMU map continuous virtual memory space */
-    if (ram_size > MMIO_START) {       
+    if (ram_size > MMIO_START) {
         for (i = 0 ; i < (MEM_G >> XC_PAGE_SHIFT); i++)
             page_array[(MMIO_START >> XC_PAGE_SHIFT) + i] =
+                (STORE_PAGE_START >> XC_PAGE_SHIFT); 
+    }
+    /* skipping VGA hole, same as above */
+    if (ram_size > VGA_IO_START) {
+        for (i = 0 ; i < (VGA_IO_SIZE >> XC_PAGE_SHIFT); i++)
+            page_array[(VGA_IO_START >> XC_PAGE_SHIFT) + i] =
                 (STORE_PAGE_START >> XC_PAGE_SHIFT); 
     }
 
diff -r 8338290757c5 -r 3d6e463d08a2 tools/ioemu/target-i386-dm/exec-dm.c
--- a/tools/ioemu/target-i386-dm/exec-dm.c      Fri Feb 22 10:52:27 2008 +0000
+++ b/tools/ioemu/target-i386-dm/exec-dm.c      Fri Feb 22 08:40:32 2008 -0700
@@ -350,12 +350,13 @@ CPUReadMemoryFunc **cpu_get_io_memory_re
  * So to emulate right behavior that guest OS is assumed, we need to flush
  * I/D cache here.
  */
-static void sync_icache(unsigned long address, int len)
-{
-    int l;
-
-    for(l = 0; l < (len + 32); l += 32)
-        __ia64_fc(address + l);
+static void sync_icache(uint8_t *address, int len)
+{
+    unsigned long addr = (unsigned long)address;
+    unsigned long end = addr + len;
+
+    for (addr &= ~(32UL-1); addr < end; addr += 32UL)
+        __ia64_fc(addr);
 
     ia64_sync_i();
     ia64_srlz_i();

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] [IA64] Fix qemu memory access on IA64, Xen patchbot-unstable <=