ia64/xen-unstable

changeset 10769:ccf11affc545

Change the qemu to allow no network arguments, removing the
"-net nic -net user" default.

Based on a patch from: Daniel Stekloff <dsteklof@us.ibm.com>
Signed-off-by: Christian Limpach <Christian.Limpach@xensource.com>
author chris@kneesaa.uk.xensource.com
date Fri Jul 14 15:59:24 2006 +0100 (2006-07-14)
parents 4e2eb1947728
children ecb8ff1fcf1f
files tools/ioemu/patches/domain-timeoffset tools/ioemu/patches/qemu-dm tools/ioemu/patches/qemu-logging tools/ioemu/patches/vnc-fixes tools/ioemu/patches/xen-mm tools/ioemu/vl.c
line diff
     1.1 --- a/tools/ioemu/patches/domain-timeoffset	Fri Jul 14 14:18:39 2006 +0100
     1.2 +++ b/tools/ioemu/patches/domain-timeoffset	Fri Jul 14 15:59:24 2006 +0100
     1.3 @@ -1,7 +1,7 @@
     1.4  Index: ioemu/hw/mc146818rtc.c
     1.5  ===================================================================
     1.6 ---- ioemu.orig/hw/mc146818rtc.c	2006-07-12 11:33:54.096180895 +0100
     1.7 -+++ ioemu/hw/mc146818rtc.c	2006-07-12 11:35:03.205515168 +0100
     1.8 +--- ioemu.orig/hw/mc146818rtc.c	2006-07-14 15:55:55.450963213 +0100
     1.9 ++++ ioemu/hw/mc146818rtc.c	2006-07-14 15:56:02.195195680 +0100
    1.10  @@ -178,10 +178,27 @@
    1.11       }
    1.12   }
    1.13 @@ -46,8 +46,8 @@ Index: ioemu/hw/mc146818rtc.c
    1.14   static void rtc_copy_date(RTCState *s)
    1.15  Index: ioemu/hw/pc.c
    1.16  ===================================================================
    1.17 ---- ioemu.orig/hw/pc.c	2006-07-12 11:35:02.876556380 +0100
    1.18 -+++ ioemu/hw/pc.c	2006-07-12 11:35:03.205515168 +0100
    1.19 +--- ioemu.orig/hw/pc.c	2006-07-14 15:56:01.774243586 +0100
    1.20 ++++ ioemu/hw/pc.c	2006-07-14 15:56:02.196195566 +0100
    1.21  @@ -151,7 +151,7 @@
    1.22   }
    1.23   
    1.24 @@ -117,8 +117,8 @@ Index: ioemu/hw/pc.c
    1.25   QEMUMachine pc_machine = {
    1.26  Index: ioemu/vl.c
    1.27  ===================================================================
    1.28 ---- ioemu.orig/vl.c	2006-07-12 11:35:03.004540346 +0100
    1.29 -+++ ioemu/vl.c	2006-07-12 11:35:03.208514792 +0100
    1.30 +--- ioemu.orig/vl.c	2006-07-14 15:56:02.010216731 +0100
    1.31 ++++ ioemu/vl.c	2006-07-14 15:56:02.198195338 +0100
    1.32  @@ -164,6 +164,8 @@
    1.33   
    1.34   int xc_handle;
    1.35 @@ -162,7 +162,7 @@ Index: ioemu/vl.c
    1.36               }
    1.37           }
    1.38       }
    1.39 -@@ -5961,7 +5969,8 @@
    1.40 +@@ -5963,7 +5971,8 @@
    1.41   
    1.42       machine->init(ram_size, vga_ram_size, boot_device,
    1.43                     ds, fd_filename, snapshot,
    1.44 @@ -174,8 +174,8 @@ Index: ioemu/vl.c
    1.45       qemu_mod_timer(gui_timer, qemu_get_clock(rt_clock));
    1.46  Index: ioemu/vl.h
    1.47  ===================================================================
    1.48 ---- ioemu.orig/vl.h	2006-07-12 11:35:02.881555754 +0100
    1.49 -+++ ioemu/vl.h	2006-07-12 11:35:03.209514667 +0100
    1.50 +--- ioemu.orig/vl.h	2006-07-14 15:56:01.779243017 +0100
    1.51 ++++ ioemu/vl.h	2006-07-14 15:56:02.199195224 +0100
    1.52  @@ -556,7 +556,7 @@
    1.53                                    int boot_device,
    1.54                DisplayState *ds, const char **fd_filename, int snapshot,
     2.1 --- a/tools/ioemu/patches/qemu-dm	Fri Jul 14 14:18:39 2006 +0100
     2.2 +++ b/tools/ioemu/patches/qemu-dm	Fri Jul 14 15:59:24 2006 +0100
     2.3 @@ -1,7 +1,7 @@
     2.4  Index: ioemu/Makefile.target
     2.5  ===================================================================
     2.6 ---- ioemu.orig/Makefile.target	2006-07-12 11:35:00.382868802 +0100
     2.7 -+++ ioemu/Makefile.target	2006-07-12 11:35:00.452860033 +0100
     2.8 +--- ioemu.orig/Makefile.target	2006-07-14 15:50:41.320748096 +0100
     2.9 ++++ ioemu/Makefile.target	2006-07-14 15:55:04.753733845 +0100
    2.10  @@ -285,7 +285,7 @@
    2.11   endif
    2.12   
    2.13 @@ -13,8 +13,8 @@ Index: ioemu/Makefile.target
    2.14   VL_OBJS+=tap-win32.o
    2.15  Index: ioemu/configure
    2.16  ===================================================================
    2.17 ---- ioemu.orig/configure	2006-07-12 11:35:00.383868677 +0100
    2.18 -+++ ioemu/configure	2006-07-12 11:35:00.453859908 +0100
    2.19 +--- ioemu.orig/configure	2006-07-14 15:50:41.320748096 +0100
    2.20 ++++ ioemu/configure	2006-07-14 15:55:04.753733845 +0100
    2.21  @@ -75,8 +75,8 @@
    2.22   bigendian="no"
    2.23   mingw32="no"
    2.24 @@ -37,8 +37,8 @@ Index: ioemu/configure
    2.25     target_user_only="yes"
    2.26  Index: ioemu/cpu-all.h
    2.27  ===================================================================
    2.28 ---- ioemu.orig/cpu-all.h	2006-07-12 11:33:54.968071470 +0100
    2.29 -+++ ioemu/cpu-all.h	2006-07-12 11:35:00.453859908 +0100
    2.30 +--- ioemu.orig/cpu-all.h	2006-07-14 15:50:30.488983278 +0100
    2.31 ++++ ioemu/cpu-all.h	2006-07-14 15:55:04.544757636 +0100
    2.32  @@ -690,7 +690,9 @@
    2.33   void page_set_flags(target_ulong start, target_ulong end, int flags);
    2.34   void page_unprotect_range(target_ulong data, target_ulong data_size);
    2.35 @@ -64,8 +64,8 @@ Index: ioemu/cpu-all.h
    2.36   void cpu_dump_state(CPUState *env, FILE *f, 
    2.37  Index: ioemu/disas.h
    2.38  ===================================================================
    2.39 ---- ioemu.orig/disas.h	2006-07-12 11:33:54.968071470 +0100
    2.40 -+++ ioemu/disas.h	2006-07-12 11:35:00.453859908 +0100
    2.41 +--- ioemu.orig/disas.h	2006-07-14 15:50:30.489983164 +0100
    2.42 ++++ ioemu/disas.h	2006-07-14 15:50:41.334746500 +0100
    2.43  @@ -1,6 +1,7 @@
    2.44   #ifndef _QEMU_DISAS_H
    2.45   #define _QEMU_DISAS_H
    2.46 @@ -83,8 +83,8 @@ Index: ioemu/disas.h
    2.47   #endif /* _QEMU_DISAS_H */
    2.48  Index: ioemu/exec-all.h
    2.49  ===================================================================
    2.50 ---- ioemu.orig/exec-all.h	2006-07-12 11:33:54.968071470 +0100
    2.51 -+++ ioemu/exec-all.h	2006-07-12 11:35:00.454859782 +0100
    2.52 +--- ioemu.orig/exec-all.h	2006-07-14 15:50:30.490983050 +0100
    2.53 ++++ ioemu/exec-all.h	2006-07-14 15:50:41.335746386 +0100
    2.54  @@ -509,7 +509,7 @@
    2.55   
    2.56   extern int tb_invalidated_flag;
    2.57 @@ -105,8 +105,8 @@ Index: ioemu/exec-all.h
    2.58       return addr;
    2.59  Index: ioemu/hw/pc.c
    2.60  ===================================================================
    2.61 ---- ioemu.orig/hw/pc.c	2006-07-12 11:33:54.967071596 +0100
    2.62 -+++ ioemu/hw/pc.c	2006-07-12 11:35:00.455859657 +0100
    2.63 +--- ioemu.orig/hw/pc.c	2006-07-14 15:50:30.491982936 +0100
    2.64 ++++ ioemu/hw/pc.c	2006-07-14 15:55:04.543757750 +0100
    2.65  @@ -65,6 +65,7 @@
    2.66       return qemu_get_clock(vm_clock);
    2.67   }
    2.68 @@ -184,8 +184,8 @@ Index: ioemu/hw/pc.c
    2.69           if (serial_hds[i]) {
    2.70  Index: ioemu/hw/vga_int.h
    2.71  ===================================================================
    2.72 ---- ioemu.orig/hw/vga_int.h	2006-07-12 11:33:54.967071596 +0100
    2.73 -+++ ioemu/hw/vga_int.h	2006-07-12 11:35:00.455859657 +0100
    2.74 +--- ioemu.orig/hw/vga_int.h	2006-07-14 15:50:30.491982936 +0100
    2.75 ++++ ioemu/hw/vga_int.h	2006-07-14 15:55:02.931941245 +0100
    2.76  @@ -28,7 +28,7 @@
    2.77   #define ST01_DISP_ENABLE    0x01
    2.78   
    2.79 @@ -197,8 +197,8 @@ Index: ioemu/hw/vga_int.h
    2.80   #define VBE_DISPI_MAX_YRES              768
    2.81  Index: ioemu/monitor.c
    2.82  ===================================================================
    2.83 ---- ioemu.orig/monitor.c	2006-07-12 11:33:54.968071470 +0100
    2.84 -+++ ioemu/monitor.c	2006-07-12 11:35:00.456859532 +0100
    2.85 +--- ioemu.orig/monitor.c	2006-07-14 15:50:30.493982708 +0100
    2.86 ++++ ioemu/monitor.c	2006-07-14 15:55:04.754733732 +0100
    2.87  @@ -68,6 +68,12 @@
    2.88   
    2.89   void term_flush(void)
    2.90 @@ -429,8 +429,8 @@ Index: ioemu/monitor.c
    2.91   {
    2.92  Index: ioemu/vl.c
    2.93  ===================================================================
    2.94 ---- ioemu.orig/vl.c	2006-07-12 11:33:54.967071596 +0100
    2.95 -+++ ioemu/vl.c	2006-07-12 11:35:00.459859156 +0100
    2.96 +--- ioemu.orig/vl.c	2006-07-14 15:50:30.496982366 +0100
    2.97 ++++ ioemu/vl.c	2006-07-14 15:55:07.676401124 +0100
    2.98  @@ -423,12 +423,15 @@
    2.99   void hw_error(const char *fmt, ...)
   2.100   {
   2.101 @@ -489,3 +489,19 @@ Index: ioemu/vl.c
   2.102   
   2.103   /***********************************************************/
   2.104   /* machine registration */
   2.105 +@@ -5481,6 +5505,7 @@
   2.106 +     socket_init();
   2.107 + #endif
   2.108 + 
   2.109 ++#ifndef CONFIG_DM
   2.110 +     /* init network clients */
   2.111 +     if (nb_net_clients == 0) {
   2.112 +         /* if no clients, we use a default config */
   2.113 +@@ -5490,6 +5515,7 @@
   2.114 +                 "user");
   2.115 +         nb_net_clients = 2;
   2.116 +     }
   2.117 ++#endif /* !CONFIG_DM */
   2.118 + 
   2.119 +     for(i = 0;i < nb_net_clients; i++) {
   2.120 +         if (net_client_init(net_clients[i]) < 0)
     3.1 --- a/tools/ioemu/patches/qemu-logging	Fri Jul 14 14:18:39 2006 +0100
     3.2 +++ b/tools/ioemu/patches/qemu-logging	Fri Jul 14 15:59:24 2006 +0100
     3.3 @@ -1,7 +1,7 @@
     3.4  Index: ioemu/vl.c
     3.5  ===================================================================
     3.6 ---- ioemu.orig/vl.c	2006-07-12 11:35:00.955797021 +0100
     3.7 -+++ ioemu/vl.c	2006-07-12 11:35:01.094779608 +0100
     3.8 +--- ioemu.orig/vl.c	2006-07-14 15:55:59.491503372 +0100
     3.9 ++++ ioemu/vl.c	2006-07-14 15:55:59.693480386 +0100
    3.10  @@ -4697,7 +4697,7 @@
    3.11              "-S              freeze CPU at startup (use 'c' to start execution)\n"
    3.12              "-s              wait gdb connection to port %d\n"
    3.13 @@ -59,7 +59,7 @@ Index: ioemu/vl.c
    3.14                   {
    3.15                       int mask;
    3.16                       CPULogItem *item;
    3.17 -@@ -5698,7 +5705,7 @@
    3.18 +@@ -5700,7 +5707,7 @@
    3.19           stk.ss_flags = 0;
    3.20   
    3.21           if (sigaltstack(&stk, NULL) < 0) {
     4.1 --- a/tools/ioemu/patches/vnc-fixes	Fri Jul 14 14:18:39 2006 +0100
     4.2 +++ b/tools/ioemu/patches/vnc-fixes	Fri Jul 14 15:59:24 2006 +0100
     4.3 @@ -1,8 +1,8 @@
     4.4  Index: ioemu/vl.c
     4.5  ===================================================================
     4.6 ---- ioemu.orig/vl.c	2006-07-13 10:09:33.965343475 +0100
     4.7 -+++ ioemu/vl.c	2006-07-13 10:10:11.141134364 +0100
     4.8 -@@ -5972,8 +5972,10 @@
     4.9 +--- ioemu.orig/vl.c	2006-07-14 15:56:03.043099185 +0100
    4.10 ++++ ioemu/vl.c	2006-07-14 15:56:03.123090082 +0100
    4.11 +@@ -5974,8 +5974,10 @@
    4.12                     kernel_filename, kernel_cmdline, initrd_filename,
    4.13                     timeoffset);
    4.14   
    4.15 @@ -17,8 +17,8 @@ Index: ioemu/vl.c
    4.16       if (use_gdbstub) {
    4.17  Index: ioemu/vnc.c
    4.18  ===================================================================
    4.19 ---- ioemu.orig/vnc.c	2006-07-13 10:09:33.963343701 +0100
    4.20 -+++ ioemu/vnc.c	2006-07-13 10:09:34.025336681 +0100
    4.21 +--- ioemu.orig/vnc.c	2006-07-14 15:56:03.040099527 +0100
    4.22 ++++ ioemu/vnc.c	2006-07-14 15:56:03.124089968 +0100
    4.23  @@ -3,6 +3,7 @@
    4.24    * 
    4.25    * Copyright (C) 2006 Anthony Liguori <anthony@codemonkey.ws>
     5.1 --- a/tools/ioemu/patches/xen-mm	Fri Jul 14 14:18:39 2006 +0100
     5.2 +++ b/tools/ioemu/patches/xen-mm	Fri Jul 14 15:59:24 2006 +0100
     5.3 @@ -1,7 +1,8 @@
     5.4 -diff -r f36cde91babe hw/pc.c
     5.5 ---- a/hw/pc.c	Mon Jun 26 15:16:50 2006 +0100
     5.6 -+++ b/hw/pc.c	Mon Jun 26 15:18:19 2006 +0100
     5.7 -@@ -639,7 +639,9 @@ static void pc_init1(uint64_t ram_size, 
     5.8 +Index: ioemu/hw/pc.c
     5.9 +===================================================================
    5.10 +--- ioemu.orig/hw/pc.c	2006-07-14 15:55:59.489503600 +0100
    5.11 ++++ ioemu/hw/pc.c	2006-07-14 15:56:00.354405169 +0100
    5.12 +@@ -639,7 +639,9 @@
    5.13       }
    5.14   
    5.15       /* allocate RAM */
    5.16 @@ -11,7 +12,7 @@ diff -r f36cde91babe hw/pc.c
    5.17   
    5.18       /* BIOS load */
    5.19       bios_offset = ram_size + vga_ram_size;
    5.20 -@@ -671,8 +673,10 @@ static void pc_init1(uint64_t ram_size, 
    5.21 +@@ -671,8 +673,10 @@
    5.22       ret = load_image(buf, phys_ram_base + vga_bios_offset);
    5.23       
    5.24       /* setup basic memory access */
    5.25 @@ -22,19 +23,20 @@ diff -r f36cde91babe hw/pc.c
    5.26   
    5.27       /* map the last 128KB of the BIOS in ISA space */
    5.28       isa_bios_size = bios_size;
    5.29 -diff -r f36cde91babe vl.c
    5.30 ---- a/vl.c	Mon Jun 26 15:16:50 2006 +0100
    5.31 -+++ b/vl.c	Mon Jun 26 15:18:19 2006 +0100
    5.32 -@@ -158,6 +158,8 @@ int vnc_display = -1;
    5.33 - #else
    5.34 +Index: ioemu/vl.c
    5.35 +===================================================================
    5.36 +--- ioemu.orig/vl.c	2006-07-14 15:56:00.271414614 +0100
    5.37 ++++ ioemu/vl.c	2006-07-14 15:56:00.358404714 +0100
    5.38 +@@ -159,6 +159,8 @@
    5.39   #define MAX_CPUS 1
    5.40   #endif
    5.41 -+
    5.42 + 
    5.43  +int xc_handle;
    5.44 - 
    5.45 ++
    5.46   char domain_name[1024] = { 'H','V', 'M', 'X', 'E', 'N', '-'};
    5.47   extern int domid;
    5.48 -@@ -5105,6 +5107,9 @@ int main(int argc, char **argv)
    5.49 + 
    5.50 +@@ -5105,6 +5107,9 @@
    5.51       QEMUMachine *machine;
    5.52       char usb_devices[MAX_VM_USB_PORTS][128];
    5.53       int usb_devices_index;
    5.54 @@ -44,7 +46,7 @@ diff -r f36cde91babe vl.c
    5.55   
    5.56       char qemu_dm_logfilename[64];
    5.57   
    5.58 -@@ -5341,11 +5346,13 @@ int main(int argc, char **argv)
    5.59 +@@ -5341,11 +5346,13 @@
    5.60                   ram_size = atol(optarg) * 1024 * 1024;
    5.61                   if (ram_size <= 0)
    5.62                       help();
    5.63 @@ -58,7 +60,7 @@ diff -r f36cde91babe vl.c
    5.64                   break;
    5.65               case QEMU_OPTION_l:
    5.66                   {
    5.67 -@@ -5557,6 +5564,39 @@ int main(int argc, char **argv)
    5.68 +@@ -5559,6 +5566,39 @@
    5.69       /* init the memory */
    5.70       phys_ram_size = ram_size + vga_ram_size + bios_size;
    5.71   
    5.72 @@ -98,12 +100,12 @@ diff -r f36cde91babe vl.c
    5.73   #ifdef CONFIG_SOFTMMU
    5.74       phys_ram_base = qemu_vmalloc(phys_ram_size);
    5.75       if (!phys_ram_base) {
    5.76 -@@ -5596,6 +5636,8 @@ int main(int argc, char **argv)
    5.77 -         }
    5.78 +@@ -5599,6 +5639,8 @@
    5.79       }
    5.80   #endif
    5.81 -+
    5.82 + 
    5.83  +#endif /* !CONFIG_DM */
    5.84 - 
    5.85 ++
    5.86       /* we always create the cdrom drive, even if no disk is there */
    5.87       bdrv_init();
    5.88 +     if (cdrom_index >= 0) {
     6.1 --- a/tools/ioemu/vl.c	Fri Jul 14 14:18:39 2006 +0100
     6.2 +++ b/tools/ioemu/vl.c	Fri Jul 14 15:59:24 2006 +0100
     6.3 @@ -5715,6 +5715,7 @@ int main(int argc, char **argv)
     6.4      socket_init();
     6.5  #endif
     6.6  
     6.7 +#ifndef CONFIG_DM
     6.8      /* init network clients */
     6.9      if (nb_net_clients == 0) {
    6.10          /* if no clients, we use a default config */
    6.11 @@ -5724,6 +5725,7 @@ int main(int argc, char **argv)
    6.12                  "user");
    6.13          nb_net_clients = 2;
    6.14      }
    6.15 +#endif /* !CONFIG_DM */
    6.16  
    6.17      for(i = 0;i < nb_net_clients; i++) {
    6.18          if (net_client_init(net_clients[i]) < 0)