ia64/xen-unstable

changeset 11003:88a42cf59f46

[qemu patches] Update patches for changeset 10974:415614d3a1ee.

Signed-off-by: Christian Limpach <Christian.Limpach@xensource.com>
author chris@kneesaa.uk.xensource.com
date Tue Aug 08 11:27:12 2006 +0100 (2006-08-08)
parents 415614d3a1ee
children 9aac8db168b4
files tools/ioemu/patches/qemu-target-i386-dm
line diff
     1.1 --- a/tools/ioemu/patches/qemu-target-i386-dm	Tue Aug 08 11:19:29 2006 +0100
     1.2 +++ b/tools/ioemu/patches/qemu-target-i386-dm	Tue Aug 08 11:27:12 2006 +0100
     1.3 @@ -1,7 +1,7 @@
     1.4  Index: ioemu/Makefile.target
     1.5  ===================================================================
     1.6 ---- ioemu.orig/Makefile.target	2006-08-06 02:14:09.794902973 +0100
     1.7 -+++ ioemu/Makefile.target	2006-08-06 02:21:42.270461924 +0100
     1.8 +--- ioemu.orig/Makefile.target	2006-08-08 11:24:33.479955101 +0100
     1.9 ++++ ioemu/Makefile.target	2006-08-08 11:24:39.008338255 +0100
    1.10  @@ -62,6 +62,8 @@
    1.11   QEMU_SYSTEM=qemu-fast
    1.12   endif
    1.13 @@ -32,8 +32,8 @@ Index: ioemu/Makefile.target
    1.14   DEFINES += -DHAS_AUDIO
    1.15  Index: ioemu/configure
    1.16  ===================================================================
    1.17 ---- ioemu.orig/configure	2006-08-06 02:14:09.795902861 +0100
    1.18 -+++ ioemu/configure	2006-08-06 02:15:01.771108621 +0100
    1.19 +--- ioemu.orig/configure	2006-08-08 11:24:33.480954990 +0100
    1.20 ++++ ioemu/configure	2006-08-08 11:24:38.122437102 +0100
    1.21  @@ -373,6 +373,8 @@
    1.22       if [ "$user" = "yes" ] ; then
    1.23           target_list="i386-user arm-user armeb-user sparc-user ppc-user mips-user mipsel-user $target_list"
    1.24 @@ -45,8 +45,8 @@ Index: ioemu/configure
    1.25   fi
    1.26  Index: ioemu/monitor.c
    1.27  ===================================================================
    1.28 ---- ioemu.orig/monitor.c	2006-08-06 02:14:49.574468309 +0100
    1.29 -+++ ioemu/monitor.c	2006-08-06 02:21:16.172371202 +0100
    1.30 +--- ioemu.orig/monitor.c	2006-08-08 11:24:33.484954543 +0100
    1.31 ++++ ioemu/monitor.c	2006-08-08 11:24:39.253310921 +0100
    1.32  @@ -1262,6 +1262,10 @@
    1.33         "", "show profiling information", },
    1.34       { "capture", "", do_info_capture,
    1.35 @@ -60,8 +60,8 @@ Index: ioemu/monitor.c
    1.36   
    1.37  Index: ioemu/vl.c
    1.38  ===================================================================
    1.39 ---- ioemu.orig/vl.c	2006-08-06 02:14:09.802902081 +0100
    1.40 -+++ ioemu/vl.c	2006-08-06 02:21:16.369349244 +0100
    1.41 +--- ioemu.orig/vl.c	2006-08-08 11:24:33.486954320 +0100
    1.42 ++++ ioemu/vl.c	2006-08-08 11:24:39.454288496 +0100
    1.43  @@ -87,7 +87,7 @@
    1.44   
    1.45   #include "exec-all.h"
    1.46 @@ -98,8 +98,8 @@ Index: ioemu/vl.c
    1.47   {
    1.48  Index: ioemu/vl.h
    1.49  ===================================================================
    1.50 ---- ioemu.orig/vl.h	2006-08-06 02:13:56.733359091 +0100
    1.51 -+++ ioemu/vl.h	2006-08-06 02:21:16.369349244 +0100
    1.52 +--- ioemu.orig/vl.h	2006-08-08 11:24:31.082222636 +0100
    1.53 ++++ ioemu/vl.h	2006-08-08 11:24:39.454288496 +0100
    1.54  @@ -37,6 +37,8 @@
    1.55   #include <unistd.h>
    1.56   #include <fcntl.h>
    1.57 @@ -132,7 +132,7 @@ Index: ioemu/vl.h
    1.58  Index: ioemu/target-i386-dm/cpu.h
    1.59  ===================================================================
    1.60  --- /dev/null	1970-01-01 00:00:00.000000000 +0000
    1.61 -+++ ioemu/target-i386-dm/cpu.h	2006-08-06 02:21:16.023387810 +0100
    1.62 ++++ ioemu/target-i386-dm/cpu.h	2006-08-08 11:24:39.099328102 +0100
    1.63  @@ -0,0 +1,86 @@
    1.64  +/*
    1.65  + * i386 virtual CPU header
    1.66 @@ -223,7 +223,7 @@ Index: ioemu/target-i386-dm/cpu.h
    1.67  Index: ioemu/target-i386-dm/exec-dm.c
    1.68  ===================================================================
    1.69  --- /dev/null	1970-01-01 00:00:00.000000000 +0000
    1.70 -+++ ioemu/target-i386-dm/exec-dm.c	2006-08-06 02:21:16.024387698 +0100
    1.71 ++++ ioemu/target-i386-dm/exec-dm.c	2006-08-08 11:24:39.099328102 +0100
    1.72  @@ -0,0 +1,516 @@
    1.73  +/*
    1.74  + *  virtual page mapping and translated block handling
    1.75 @@ -744,8 +744,8 @@ Index: ioemu/target-i386-dm/exec-dm.c
    1.76  Index: ioemu/target-i386-dm/helper2.c
    1.77  ===================================================================
    1.78  --- /dev/null	1970-01-01 00:00:00.000000000 +0000
    1.79 -+++ ioemu/target-i386-dm/helper2.c	2006-08-06 02:21:15.779415007 +0100
    1.80 -@@ -0,0 +1,464 @@
    1.81 ++++ ioemu/target-i386-dm/helper2.c	2006-08-08 11:24:44.888682140 +0100
    1.82 +@@ -0,0 +1,469 @@
    1.83  +/*
    1.84  + *  i386 helpers (without register variable usage)
    1.85  + *
    1.86 @@ -830,6 +830,10 @@ Index: ioemu/target-i386-dm/helper2.c
    1.87  +/* which vcpu we are serving */
    1.88  +int send_vcpu = 0;
    1.89  +
    1.90 ++//the evtchn port for polling the notification,
    1.91 ++#define NR_CPUS 32
    1.92 ++evtchn_port_t ioreq_local_port[NR_CPUS];
    1.93 ++
    1.94  +CPUX86State *cpu_x86_init(void)
    1.95  +{
    1.96  +    CPUX86State *env;
    1.97 @@ -861,7 +865,7 @@ Index: ioemu/target-i386-dm/helper2.c
    1.98  +                fprintf(logfile, "bind interdomain ioctl error %d\n", errno);
    1.99  +                return NULL;
   1.100  +            }
   1.101 -+            shared_page->vcpu_iodata[i].dm_eport = rc;
   1.102 ++            ioreq_local_port[i] = rc;
   1.103  +        }
   1.104  +    }
   1.105  +
   1.106 @@ -913,8 +917,7 @@ Index: ioemu/target-i386-dm/helper2.c
   1.107  +
   1.108  +    for (i = 0; i < vcpus; i++) {
   1.109  +        req = &(shared_page->vcpu_iodata[i].vp_ioreq);
   1.110 -+        term_printf("vcpu %d: event port %d\n", i,
   1.111 -+                    shared_page->vcpu_iodata[i].vp_eport);
   1.112 ++        term_printf("vcpu %d: event port %d\n", i, ioreq_local_port[i]);
   1.113  +        term_printf("  req state: %x, pvalid: %x, addr: %"PRIx64", "
   1.114  +                    "data: %"PRIx64", count: %"PRIx64", size: %"PRIx64"\n",
   1.115  +                    req->state, req->pdata_valid, req->addr,
   1.116 @@ -933,6 +936,7 @@ Index: ioemu/target-i386-dm/helper2.c
   1.117  +
   1.118  +    if (req->state == STATE_IOREQ_READY) {
   1.119  +        req->state = STATE_IOREQ_INPROCESS;
   1.120 ++        rmb();
   1.121  +        return req;
   1.122  +    }
   1.123  +
   1.124 @@ -955,7 +959,7 @@ Index: ioemu/target-i386-dm/helper2.c
   1.125  +    port = xc_evtchn_pending(xce_handle);
   1.126  +    if (port != -1) {
   1.127  +        for ( i = 0; i < vcpus; i++ )
   1.128 -+            if ( shared_page->vcpu_iodata[i].dm_eport == port )
   1.129 ++            if ( ioreq_local_port[i] == port )
   1.130  +                break;
   1.131  +
   1.132  +        if ( i == vcpus ) {
   1.133 @@ -1176,8 +1180,10 @@ Index: ioemu/target-i386-dm/helper2.c
   1.134  +        }
   1.135  +
   1.136  +        /* No state change if state = STATE_IORESP_HOOK */
   1.137 -+        if (req->state == STATE_IOREQ_INPROCESS)
   1.138 ++        if (req->state == STATE_IOREQ_INPROCESS) {
   1.139 ++            mb();
   1.140  +            req->state = STATE_IORESP_READY;
   1.141 ++        }
   1.142  +        env->send_event = 1;
   1.143  +    }
   1.144  +}
   1.145 @@ -1204,8 +1210,7 @@ Index: ioemu/target-i386-dm/helper2.c
   1.146  +
   1.147  +        if (env->send_event) {
   1.148  +            env->send_event = 0;
   1.149 -+            xc_evtchn_notify(xce_handle,
   1.150 -+                             shared_page->vcpu_iodata[send_vcpu].dm_eport);
   1.151 ++            xc_evtchn_notify(xce_handle, ioreq_local_port[send_vcpu]);
   1.152  +        }
   1.153  +    }
   1.154  +    return 0;
   1.155 @@ -1213,7 +1218,7 @@ Index: ioemu/target-i386-dm/helper2.c
   1.156  Index: ioemu/target-i386-dm/i8259-dm.c
   1.157  ===================================================================
   1.158  --- /dev/null	1970-01-01 00:00:00.000000000 +0000
   1.159 -+++ ioemu/target-i386-dm/i8259-dm.c	2006-08-06 02:15:01.777107952 +0100
   1.160 ++++ ioemu/target-i386-dm/i8259-dm.c	2006-08-08 11:24:33.505952200 +0100
   1.161  @@ -0,0 +1,107 @@
   1.162  +/* Xen 8259 stub for interrupt controller emulation
   1.163  + * 
   1.164 @@ -1325,7 +1330,7 @@ Index: ioemu/target-i386-dm/i8259-dm.c
   1.165  Index: ioemu/target-i386-dm/qemu-dm.debug
   1.166  ===================================================================
   1.167  --- /dev/null	1970-01-01 00:00:00.000000000 +0000
   1.168 -+++ ioemu/target-i386-dm/qemu-dm.debug	2006-08-06 02:15:01.778107841 +0100
   1.169 ++++ ioemu/target-i386-dm/qemu-dm.debug	2006-08-08 11:24:33.505952200 +0100
   1.170  @@ -0,0 +1,5 @@
   1.171  +#!/bin/sh
   1.172  +
   1.173 @@ -1335,7 +1340,7 @@ Index: ioemu/target-i386-dm/qemu-dm.debu
   1.174  Index: ioemu/target-i386-dm/qemu-ifup
   1.175  ===================================================================
   1.176  --- /dev/null	1970-01-01 00:00:00.000000000 +0000
   1.177 -+++ ioemu/target-i386-dm/qemu-ifup	2006-08-06 02:15:01.778107841 +0100
   1.178 ++++ ioemu/target-i386-dm/qemu-ifup	2006-08-08 11:24:33.505952200 +0100
   1.179  @@ -0,0 +1,10 @@
   1.180  +#!/bin/sh
   1.181  +